diff --git a/.github/workflows/compile-examples.yml b/.github/workflows/compile-examples.yml new file mode 100644 index 0000000..094b60c --- /dev/null +++ b/.github/workflows/compile-examples.yml @@ -0,0 +1,254 @@ +name: Compile Examples + +on: + pull_request: + paths: + - ".github/workflows/compile-examples.yml" + - "cores/**" + - "libraries/**" + - "variants/**" + - "boards.txt" + - "platform.txt" + push: + paths: + - ".github/workflows/compile-examples.yml" + - "cores/**" + - "libraries/**" + - "variants/**" + - "boards.txt" + - "platform.txt" + +jobs: + compile-test: + runs-on: ubuntu-latest + + env: + # sketch paths to compile (recursive) for all boards + UNIVERSAL_SKETCH_PATHS: | + - extras/examples + - libraries/Wire + - libraries/USBHost + - libraries/SPI + - libraries/SFU/examples/SFU_LoadBinary + - libraries/SAMD_AnalogCorrection + - ~/Arduino/libraries/Servo/examples + - ~/Arduino/libraries/LiquidCrystal/examples + - ~/Arduino/libraries/Ethernet/examples + - ~/Arduino/libraries/SD/examples + - ~/Arduino/libraries/WiFi/examples + - ~/Arduino/libraries/Arduino_LSM9DS1/examples + - ~/Arduino/libraries/Arduino_JSON/examples + - ~/Arduino/libraries/MFRC522/examples/ChangeUID + - ~/Arduino/libraries/MFRC522/examples/DumpInfo + - ~/Arduino/libraries/MFRC522/examples/FixBrickedUID + - ~/Arduino/libraries/MFRC522/examples/MifareClassicValueBlock + - ~/Arduino/libraries/MFRC522/examples/MinimalInterrupt + - ~/Arduino/libraries/MFRC522/examples/Ntag216_AUTH + - ~/Arduino/libraries/MFRC522/examples/RFID-Cloner + - ~/Arduino/libraries/MFRC522/examples/ReadAndWrite + - ~/Arduino/libraries/MFRC522/examples/ReadNUID + - ~/Arduino/libraries/MFRC522/examples/ReadUidMultiReader + - ~/Arduino/libraries/MFRC522/examples/firmware_check + - ~/Arduino/libraries/MFRC522/examples/rfid_default_keys + - ~/Arduino/libraries/MFRC522/examples/rfid_read_personal_data + - ~/Arduino/libraries/MFRC522/examples/rfid_write_personal_data + - ~/Arduino/libraries/WiFi101/examples + + strategy: + fail-fast: false + + matrix: + board: [ + {"fqbn": "mysensors:samd:mysensors_gw_native", "type": "usb", "WAN": "false"}, + ] + + # make board type-specific customizations to the matrix jobs + include: + # Normal USB boards with all the general libraries + - board: + type: "usb" + additional-sketch-paths: | + - ~/Arduino/libraries/Firmata/examples/StandardFirmataPlus + - ~/Arduino/libraries/Firmata/examples/StandardFirmataEthernet + - ~/Arduino/libraries/Firmata/examples/StandardFirmata + - ~/Arduino/libraries/Firmata/examples/SimpleDigitalFirmata + - ~/Arduino/libraries/Firmata/examples/SimpleAnalogFirmata + - ~/Arduino/libraries/Firmata/examples/ServoFirmata + - ~/Arduino/libraries/Firmata/examples/EchoString + - ~/Arduino/libraries/Firmata/examples/AnalogFirmata + - ~/Arduino/libraries/Firmata/examples/AllInputsFirmata + - libraries/I2S/examples + - libraries/SDU/examples + # Vidor board + - board: + type: "vidor" + additional-sketch-paths: | + - libraries/SAMD_BootloaderUpdater/examples + - libraries/I2S/examples + - ~/Arduino/libraries/VidorPeripherals/examples + # mkrwifi1010 + - board: + type: "mkrWiFi1010" + additional-sketch-paths: | + - libraries/I2S/examples + - libraries/SDU/examples + - ~/Arduino/libraries/WiFiNINA/examples + # mkrnb1500 boards + - board: + type: "mkrNB1500" + additional-sketch-paths: | + - libraries/I2S/examples + - libraries/SDU/examples + - ~/Arduino/libraries/MKRNB/examples + # nano_33_iot + - board: + type: "nano33IoT" + additional-sketch-paths: | + - libraries/I2S/examples + - ~/Arduino/libraries/WiFiNINA/examples + # mkrwan1310 + - board: + type: "mkrwan1310" + additional-sketch-paths: | + - libraries/I2S/examples + # adafruit_cicrcuitplayground board + - board: + type: "adafruit_playg" + additional-sketch-paths: | + - libraries/SDU/examples + # mzero boards + - board: + type: "mzero" + additional-sketch-paths: | + - ~/Arduino/libraries/Firmata/examples/StandardFirmataPlus + - ~/Arduino/libraries/Firmata/examples/StandardFirmataEthernet + - ~/Arduino/libraries/Firmata/examples/StandardFirmata + - ~/Arduino/libraries/Firmata/examples/SimpleDigitalFirmata + - ~/Arduino/libraries/Firmata/examples/SimpleAnalogFirmata + - ~/Arduino/libraries/Firmata/examples/ServoFirmata + - ~/Arduino/libraries/Firmata/examples/EchoString + - ~/Arduino/libraries/Firmata/examples/AnalogFirmata + - ~/Arduino/libraries/Firmata/examples/AllInputsFirmata + - libraries/SDU/examples + # tian board + - board: + type: "tian" + additional-sketch-paths: | + - ~/Arduino/libraries/Firmata/examples/StandardFirmataPlus + - ~/Arduino/libraries/Firmata/examples/StandardFirmataEthernet + - ~/Arduino/libraries/Firmata/examples/StandardFirmata + - ~/Arduino/libraries/Firmata/examples/SimpleDigitalFirmata + - ~/Arduino/libraries/Firmata/examples/SimpleAnalogFirmata + - ~/Arduino/libraries/Firmata/examples/ServoFirmata + - ~/Arduino/libraries/Firmata/examples/EchoString + - ~/Arduino/libraries/Firmata/examples/AnalogFirmata + - ~/Arduino/libraries/Firmata/examples/AllInputsFirmata + # MKRGSM1400 board + - board: + fqbn: "arduino:samd:mkrgsm1400" + mkrgsm1400-sketch-paths: | + - ~/Arduino/libraries/MKRGSM/examples + # MKRWAN board + - board: + WAN: "true" + wan-sketch-paths: | + - ~/Arduino/libraries/MKRWAN/examples + + steps: + - name: Checkout repository + uses: actions/checkout@v2 + + # The source files are in a subfolder of the ArduinoCore-API repository, so it's not possible to clone it directly to the final destination in the core + - name: Checkout ArduinoCore-API + uses: actions/checkout@v2 + with: + repository: arduino/ArduinoCore-API + path: extras/ArduinoCore-API + + - name: Check if API should be compiled in the core + id: checkapi + run: | + if [[ $(grep -r api platform.txt) ]]; then echo "::set-output name=IS_API::true"; fi + + - name: Install ArduinoCore-API + run: mv "$GITHUB_WORKSPACE/extras/ArduinoCore-API/api" "$GITHUB_WORKSPACE/cores/arduino" + if: steps.checkapi.outputs.IS_API == 'true' + + - name: Checkout Basic examples + uses: actions/checkout@v2 + with: + repository: arduino/arduino-examples + path: extras + + - name: Compile examples + uses: arduino/compile-sketches@main + with: + fqbn: ${{ matrix.board.fqbn }} + libraries: | + - source-url: https://github.com/arduino-libraries/WiFi101.git + - name: MFRC522 + - name: Arduino_MKRMEM + - name: FlashStorage + - name: Keyboard + - name: Mouse + - name: Servo + - name: LiquidCrystal + - name: CapacitiveSensor + - name: Ethernet + - name: ArduinoBearSSL + - name: Arduino_APDS9960 + - name: Arduino_LSM9DS1 + - name: ArduinoHttpClient + - name: NTPClient + - name: TFT + - name: ArduinoMqttClient + - name: Arduino_CRC32 + - name: Arduino_LSM6DS3 + - name: Stepper + - name: SD + - name: Arduino_JSON + - name: Arduino_HTS221 + - name: Firmata + - name: ArduinoMotorCarrier + - name: ArduinoCloudThing + - name: Arduino_DebugUtils + - name: WiFi Link + - name: Arduino_LPS22HB + - name: CTC GO MOTIONS + - name: ArduinoModbus + - name: ArduinoIoTCloudBearSSL + - name: ArduinoDMX + - name: ArduinoRS485 + - name: Arduino_OAuth + - name: CTC GO CORE + - name: WiFi + - name: Bridge + - name: Temboo + - name: ArduinoIoTCloud + - name: Madgwick + - name: MKRGSM + - name: MKRNB + - name: LoRa + - name: MKRWAN + - name: WiFiNINA + - source-url: https://github.com/vidor-libraries/VidorPeripherals.git + platforms: | + # Use Board Manager to install the latest release of Arduino SAMD Boards to get the toolchain + - name: "arduino:samd" + # Overwrite the Board Manager installation with the local platform + - source-path: "./" + name: "arduino:samd" + sketch-paths: | + ${{ env.UNIVERSAL_SKETCH_PATHS }} + ${{ matrix.additional-sketch-paths }} + ${{ matrix.mkrgsm1400-sketch-paths }} + ${{ matrix.wan-sketch-paths }} + enable-deltas-report: 'true' + verbose: 'false' + github-token: ${{ secrets.GITHUB_TOKEN }} + + - name: Save memory usage change report as artifact + uses: actions/upload-artifact@v1 + with: + name: sketches-reports + path: sketches-reports diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml new file mode 100644 index 0000000..84ff482 --- /dev/null +++ b/.github/workflows/release.yaml @@ -0,0 +1,108 @@ +name: release + +on: + push: + tags: + - "[0-9]+.[0-9]+.[0-9]+*" + +jobs: + core-pre-release-from-tag: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v2 + + - name: Checkout ArduinoCore-API + uses: actions/checkout@v2 + with: + repository: arduino/ArduinoCore-API + path: extras/ArduinoCore-API + + - name: Check if API should be compiled in the core + id: checkapi + run: | + if [[ $(grep -r api platform.txt) ]]; then echo "::set-output name=IS_API::true"; fi + + - name: Checkout latest tag of ArduinoCore-API and add it to the core + run: | + cd extras/ArduinoCore-API + git fetch --tags + git checkout $(git describe --tags $(git rev-list --tags --max-count=1)) + cd ../.. + mv "$GITHUB_WORKSPACE/extras/ArduinoCore-API/api" "$GITHUB_WORKSPACE/cores/arduino" + if: steps.checkapi.outputs.IS_API == 'true' + + - name: Remove ArduinoCore-API + run: rm -r "$GITHUB_WORKSPACE/extras/ArduinoCore-API" + + - name: Set env + run: echo "TAG_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV + + - name: Get repo name + run: echo "REPOSITORY_NAME=$(echo ${{ github.repository }} | cut -d "/" -f2-)" >> $GITHUB_ENV + + - name: Package the new core + run: | + extras/pack.release.bash $TAG_VERSION $REPOSITORY_NAME + cd extras + mkdir staging + echo $PWD + mv ../*.json staging/ + mv ../*.tar.bz2 staging/ + cd .. + + - name: Get architecture name + run: | + echo "ARCHITECTURE=$(cat extras/package_index.json.NewTag.template | jq ".packages[0].platforms[0].architecture" | sed 's/\"//g')" >> $GITHUB_ENV + + - name: Upload package_*_index.json and *.tar.bz2 file to Arduino downloads servers + env: + AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} + AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} + AWS_REGION: "us-east-1" # or https://github.com/aws/aws-cli/issues/5623 + run: | + aws s3 sync extras/staging/ s3://${{ secrets.ARDUINO_DOWNLOADS_BUCKET }}/packages/staging/ --exclude "*" --include *.json + aws s3 sync extras/staging/ s3://${{ secrets.ARDUINO_DOWNLOADS_BUCKET }}/cores/staging/ --exclude "*" --include *.tar.bz2 + + - name: Checkout Basic examples + uses: actions/checkout@v2 + with: + repository: arduino/arduino-examples + path: extras/arduino-examples + + - name: Install Arduino CLI + uses: arduino/setup-arduino-cli@v1.1.1 + with: + version: "0.14.0" + + - name: Download and verify new core + run: | + export PATH=$PATH:$PWD + arduino-cli version + cp extras/staging/package_${REPOSITORY_NAME}_${TAG_VERSION}_index.json . + export ARDUINO_DIRECTORIES_DATA=$PWD + export ARDUINO_BOARD_MANAGER_ADDITIONAL_URLS=file://$PWD/package_${REPOSITORY_NAME}_${TAG_VERSION}_index.json + arduino-cli config init + arduino-cli config dump -v + arduino-cli core update-index -v + arduino-cli core install arduino:${ARCHITECTURE}@${TAG_VERSION} + INDEX=0 + arduino-cli board listall --format=json > boardlist.json + N=$(jq '.boards | length' boardlist.json) + let N=N-1 + echo $N + for INDEX in $(seq 0 1 $N); do arduino-cli compile --fqbn $(cat boardlist.json | jq ".boards[$INDEX].FQBN" | sed 's/\"//g') $PWD/extras/arduino-examples/examples/01.Basics/Blink; done + + # See: https://github.com/rtCamp/action-slack-notify + - name: Slack notification of core pre-release + uses: rtCamp/action-slack-notify@v2.1.0 + env: + SLACK_CHANNEL: core_releases + SLACK_COLOR: good + SLACK_USERNAME: ArduinoBot + SLACK_ICON: https://github.com/arduino.png?size=48 + SLACK_TITLE: Arduino core pre-release + SLACK_MESSAGE: 'Version ${{ env.TAG_VERSION }} of core ${{ env.REPOSITORY_NAME }} is now available' + SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} + MSG_MINIMAL: true diff --git a/.github/workflows/report-size-deltas.yml b/.github/workflows/report-size-deltas.yml new file mode 100644 index 0000000..4a7c2ba --- /dev/null +++ b/.github/workflows/report-size-deltas.yml @@ -0,0 +1,13 @@ +name: Report PR Size Deltas + +on: + schedule: + - cron: '*/5 * * * *' + +jobs: + report: + runs-on: ubuntu-latest + + steps: + - name: Comment size deltas reports to PRs + uses: arduino/report-size-deltas@main diff --git a/.gitignore b/.gitignore index 09ba154..acad84b 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,5 @@ *.bak -*~ \ No newline at end of file +*~ +*.bz2 + +bootloaders/*/build/ diff --git a/CHANGELOG b/CHANGELOG new file mode 100644 index 0000000..754034c --- /dev/null +++ b/CHANGELOG @@ -0,0 +1,227 @@ +SAMD CORE ?.?.?? ????.??.?? + +SAMD CORE 1.6.21 2019.04.01 + +* MKR boards: changed I2C to sercom2, SPI1 + Serial2 to sercom4 +* Improved accuracy of delay() function. Thanks @BenF +* MKR 1500: Changed SARA module to be powered off on boot + +SAMD CORE 1.6.20 2018.11.28 + +* Replaced boolean type with bool in examples. Thanks @per1234 +* Added c++ linker command to allow to include libstdc++ when linking. Thanks @helmut64 +* CPX driver fixes. Thanks @dhalbert +* I2S: Changed library to use 8 MHz oscillator source if 48MHz divider does not fit in 8 bits +* UART: Added frame error handling +* USB: Fixed memory leak on reconnects +* SDU: Added support for Arduino M0. Thanks @jandrassy +* Added arduinoOTA upload keys for Arduino M0. Thanks @jandrassy +* USB: Fixed USB Host failures and fixed memory overwrite in USBHost. Thanks @gdsports +* USB: Added method to return USB error code. Thanks @MarkFischer +* CDC: Clear line state on end() +* USB: Added USB device end() method +* Removed requirement that the DAC is on A0. Thanks @GabrielNotman +* Added alternate ports 44, 45 to make the SWCLK and SWDIO pins available on the Zero. Thanks @helmut64 +* Added defines for MKR pin layout +* Fixed freeze in tone() +* Added MKR NB 1500 variant and bootloader +* Increased the default serial buffer size to 256 + +SAMD CORE 1.6.19 2018.07.11 + +* Fixed bootloader tools for .org boards +* M0: Updated pin definitions for D6, D7 and D13 to match Zero +* SPI: Fixed interrupt mask to block. Thanks @ggajoch +* Added MKR WiFi 1010 variant and bootloader +* Updated Windows Drivers to 1.4.0 and re-signed Adafruit_Circuit_Playground_Express.inf + +SAMD CORE 1.6.18 2018.03.05 + +* Wire: Added support for general call (broadcast) +* SPI: Added SPI.notUsingInterrupt(...) API +* Fixed build errors if variant disabled USB +* Wire: TX and RX buffers are now 256 bytes (previously was 64 bytes) +* Added samd21e sercom compatibility. Thanks @mitchellpontague +* Fixed lock ups when outputting to UART during ISR +* Wire: correct I2C frequency calculations, and allow variant to overide default pull up resistor rise time +* USB: Fixed build errors when CDC_ENABLED was not set. Thanks @gdsports + +SAMD CORE 1.6.17 2017.11.29 + +* More accurate approximation for multiplication factor of PLL to make 48Mhz. Thanks @joverbee +* Fix changing trigger mode (RISING/FALLING/...) in attachInterrupt(..) during runtime. Thanks @joverbee +* Improved ISR response time. Thanks @joverbee +* USB power current can now be overridden in the variant. Thanks @awatterott +* UART's now support optional RTS and CTS pins defined in the variant. +* Added support for MKR GSM 1400 and MKR WAN 1300 + +SAMD CORE 1.6.16 2017.08.23 + +* Is now possible to use PWM on D7 (though it can't be used with PWM on D12 at the same time). Thanks @Adminius +* PWMs now can perform real 16-bit resolution if analogWriteResolution(16) is set. Thanks @Adminius +* USB CDC: fixed issue of available() getting stuck when receiving ZLP's +* Serial (UART) tx is now buffered. +* Improved CRYSTALLESS stability. Thanks @tannewt +* Some fixes to Adafruit Circuit Playground Express variant. Thanks @ladyada +* Updated Stream and Print class +* Native USB now supports USB Serial Number +* Fixed pgm_read_ptr compatibility macro. Thanks @nkrkv + +SAMD CORE 1.6.15 2017.04.27 + +* Added missing Windows driver for MKRFox1200 +* Added SDU support for MKRFox1200 + +SAMD CORE 1.6.14 2017.04.04 + +* Fixed platform definition for openocd +* Added bootloader definitions for MKRFox1200 +* Added lowpower function on USB subsystem + +SAMD CORE 1.6.13 2017.03.31 + +* Added SDU (SD card Updater) library. +* Fixed 8MHz clock being generated incorrectly. Thanks @keestux + +SAMD CORE 1.6.12 2017.02.07 + +* Fixed type conflict of utoa function. Thanks @kbumsik +* Fixed pinMode(pin, OUTPUT) not working after analogRead(pin) +* Reenabled support for Tian +* Fixed signature for Adafruit Circuit Playground Express board +* Added CMSIS headers for SAML21 chip series. Thanks @aethaniel + +SAMD CORE 1.6.11 2016.12.23 + +* Temporarily disabled support for Arduino Tian until an upload issue is fixed + +SAMD CORE 1.6.10 2016.12.23 + +* Added .org boards +* Fixed MKRZero `build.board` property +* linker: .data section is now aligned to 16 bytes address +* Added support for CRYSTALLESS configurations (thanks @ladyada) +* Added Circuits Playground board +* Added method to automatically retrieve sketch start via linker variable + (see https://github.com/arduino/ArduinoCore-samd/pull/185) +* Fixed USBDevice.epBank1EnableTransferComplete method +* Adapted bootloader source code to CMSIS 4.5 + +SAMD CORE 1.6.9 2016.12.12 + +* MKR1000: Enabled PWM on pin 11, it is shared with pin A4 +* SPI: Optimized SPI.transfer(...) +* Added linker flags for the ARM Math library +* Added new I2S library +* Bootloader: Check sketch vectors before waiting for double tap +* Upgraded CMSIS version to 4.5.0, and use new CMSIS-Atmel package +* Added Arduino MKRZero board. + +SAMD CORE 1.6.8 2016.10.12 + +* Fixed regression on analogWrite. Thanks @bose-mdellisanti! +* Fixed regression on SerialUSB.available() +* C++ global constructors (if any) are now run after hardware initalization. + +SAMD CORE 1.6.7 2016.09.28 + +* Fixed Serial.flush() blocking before any writes. Thanks @hangmoh +* Added snprintf_P to avr/pgmspace.h stub. Thanks @jantje +* Another small fix to String iterators. Thanks @Ivan-Perez @Chris--A +* Fixes SerialUSB.write(...) returning 0 instead of byte written +* Added Uart::availableForWrite() +* Added defines for RAMSTART, RAMSIZE, RAMEND +* Fixed writing LOW to a digital input pin blocking subsequent digitalRead attempts +* Fixed digitalWrite() unnecessarily activating the pull-up resistor +* Wire: Slave writes now use TX buffer +* Added getTimeout() method to Stream. +* Fixed glitch in PWM generation that may happen when calling analogWrite() +* PWM frequency is now 732.4Hz (before it was 187500.0Hz) +* Fixed PWM/analogwrite() not working on pin 13 on the Zero +* Improved reliability of SerialUSB under heavy load (this should solve + all issues with MKR1000/WiFi101 firmware updater on MacOSX) +* Improved SerialUSB.read() performance +* Added String::toDouble() +* Bootloader: LED now pulses and USB TX/RX blink on transfer (like Leonardo) +* Bootloader: enabled USB string descriptors + +SAMD CORE 1.6.6 2016.05.19 + +* Fixed digitalPinToInterrupt() macro, now it works as documented. +* Added analogInputToDigitalPin macro +* Fixed NUM_DIGITAL_PINS for Zero Board. +* On-board RX-TX LEDs now blinks when there is activity on the native USB port +* Fixed platform.txt, the core now compiles again with Arduino IDE <=1.6.5. Thanks @per1234 +* Fixed Wire.write(0x00) "ambiguos method" error +* String class now supports iterators. Thanks @Chris--A +* Remove enabling bootloader protection when burning bootloader. This enables WDT, so sketches do not work. +* Added remote upload for Yun-Shield + +SAMD CORE 1.6.5 2016.04.02 + +* Added Arduino/Genuino MKR1000 board +* Set NVMCTRL.MANW bit to 1 (default is 0). This prevents accidental writes on program memory. +* Bootloader: Fixed wrong UART speed (regression) +* Fixed incorrect return value from Wire.available() when the receive buffer is not fully read. +* Added DAC0 definition in Arduino/Genuino Zero variant file. +* Enabled bootloader protection after "Burn bootloader". + +SAMD CORE 1.6.4 2016.02.19 + +* Fixed Wire address setup when running as slave. +* Fixed String constructor when using floating point numbers. +* USBHost: fixed blocking USBHost.Task(). Thanks @bbx10 +* USBHost: fixed some ASCII Control codes in keyboard controller. Thanks @bbx10 +* USBHost: ported some minor fix from upstream UHS2. Thanks @bbx10 +* USBHost: fixed wrong library initialization. Thanks @bbx10 @ladyada +* better interrupt handling in Serial::accept() + +SAMD CORE 1.6.3 2016.02.15 + +* Added drivers for Arduino/Genuino MKR1000 board +* Fixed Wire master repeated start behaviour +* Added SerialUSB methods: readBreak(), baud(), stopbits(), paritytype(), numbits(), dtr(), rts() +* Added SPI.transfer16(..) method +* Bugfix: added missing Serial.begin(baud, config) method. Thanks @tuxedo0801 +* Fixed Serial baudrate calculations for 1200bps. Thanks @TomKeddie +* Fixed Serial.flush() that now waits until the last bit has been sent. Thanks @TomKeddie +* Fixed Serial configuration for data-bit. Thanks @TomKeddie +* Bootloader: 32Khz external oscillator is now used, improves USB clock. Thanks @aethaniel +* Bootloader: Clean up of makefiles and file organization. Thanks @aethaniel +* Added PWM capability to pins A1/A2 of Arduino Zero. +* variant.h/cpp: PWM capability is now determined by PIN_ATTR_PWM combined with + PIN_ATTR_TIMER or PIN_ATTR_TIMER_ALT for timer selection. +* Small fix to USBHost example "USB_desc.ino". Thanks @bbx10 +* USBHost: USB-Keyboard right shift key was ignored. Thanks @bbx10 +* Wire library now support multiple instances in variant. Thanks @spiderkeys +* Ported some SerialUSB API (readBreak(), baud(), stopbits(), paritytype(), numbits(), dtr(), rts()) + +SAMD CORE 1.6.2 2015.11.03 + +* Fixed bug in delay calculations +* Fixed deadlock conditions in Wire. Thanks Erin Tomson +* Print not aborting on write() failure. Thanks @stickbreaker +* SPI can now be configured in variants. Thanks @aethaniel +* Implemented Wire.end +* Fixed external interrupt for pin 8 and 9 +* Implemented Wire.setClock. Thanks @PaoloP74 +* Wire: allow scanning bus via beginTransmission-endTransmission +* USB Device: big refactoring and bug fix +* USB Device: added PluggableUSB interface +* updated bossac to version 1.6.1-arduino + +SAMD CORE 1.6.1 2015.07.21 + +* Added missing ATN pin definition +* Added missing bootloader key/value pair in boards.txt (this allows to burn bootloader with Sam-ICE too) +* Fixed min/max functions +* Fixed hooks for Cortex-M RTOS +* Fixed acknowledge of UART errors +* Enabled C11/C++11 +* Fixed initialization in USB Device +* Updated bossac to version 1.6-arduino + +SAMD CORE 1.6.0 2015.06.15 + +* First public release. + diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..8000a6f --- /dev/null +++ b/LICENSE @@ -0,0 +1,504 @@ + GNU LESSER GENERAL PUBLIC LICENSE + Version 2.1, February 1999 + + Copyright (C) 1991, 1999 Free Software Foundation, Inc. + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + +[This is the first released version of the Lesser GPL. It also counts + as the successor of the GNU Library Public License, version 2, hence + the version number 2.1.] + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +Licenses are intended to guarantee your freedom to share and change +free software--to make sure the software is free for all its users. + + This license, the Lesser General Public License, applies to some +specially designated software packages--typically libraries--of the +Free Software Foundation and other authors who decide to use it. You +can use it too, but we suggest you first think carefully about whether +this license or the ordinary General Public License is the better +strategy to use in any particular case, based on the explanations below. + + When we speak of free software, we are referring to freedom of use, +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 this service if you wish); that you receive source code or can get +it if you want it; that you can change the software and use pieces of +it in new free programs; and that you are informed that you can do +these things. + + To protect your rights, we need to make restrictions that forbid +distributors to deny you these rights or to ask you to surrender these +rights. These restrictions translate to certain responsibilities for +you if you distribute copies of the library or if you modify it. + + For example, if you distribute copies of the library, whether gratis +or for a fee, you must give the recipients all the rights that we gave +you. You must make sure that they, too, receive or can get the source +code. If you link other code with the library, you must provide +complete object files to the recipients, so that they can relink them +with the library after making changes to the library and recompiling +it. And you must show them these terms so they know their rights. + + We protect your rights with a two-step method: (1) we copyright the +library, and (2) we offer you this license, which gives you legal +permission to copy, distribute and/or modify the library. + + To protect each distributor, we want to make it very clear that +there is no warranty for the free library. Also, if the library is +modified by someone else and passed on, the recipients should know +that what they have is not the original version, so that the original +author's reputation will not be affected by problems that might be +introduced by others. + + Finally, software patents pose a constant threat to the existence of +any free program. We wish to make sure that a company cannot +effectively restrict the users of a free program by obtaining a +restrictive license from a patent holder. Therefore, we insist that +any patent license obtained for a version of the library must be +consistent with the full freedom of use specified in this license. + + Most GNU software, including some libraries, is covered by the +ordinary GNU General Public License. This license, the GNU Lesser +General Public License, applies to certain designated libraries, and +is quite different from the ordinary General Public License. We use +this license for certain libraries in order to permit linking those +libraries into non-free programs. + + When a program is linked with a library, whether statically or using +a shared library, the combination of the two is legally speaking a +combined work, a derivative of the original library. The ordinary +General Public License therefore permits such linking only if the +entire combination fits its criteria of freedom. The Lesser General +Public License permits more lax criteria for linking other code with +the library. + + We call this license the "Lesser" General Public License because it +does Less to protect the user's freedom than the ordinary General +Public License. It also provides other free software developers Less +of an advantage over competing non-free programs. These disadvantages +are the reason we use the ordinary General Public License for many +libraries. However, the Lesser license provides advantages in certain +special circumstances. + + For example, on rare occasions, there may be a special need to +encourage the widest possible use of a certain library, so that it becomes +a de-facto standard. To achieve this, non-free programs must be +allowed to use the library. A more frequent case is that a free +library does the same job as widely used non-free libraries. In this +case, there is little to gain by limiting the free library to free +software only, so we use the Lesser General Public License. + + In other cases, permission to use a particular library in non-free +programs enables a greater number of people to use a large body of +free software. For example, permission to use the GNU C Library in +non-free programs enables many more people to use the whole GNU +operating system, as well as its variant, the GNU/Linux operating +system. + + Although the Lesser General Public License is Less protective of the +users' freedom, it does ensure that the user of a program that is +linked with the Library has the freedom and the wherewithal to run +that program using a modified version of the Library. + + The precise terms and conditions for copying, distribution and +modification follow. Pay close attention to the difference between a +"work based on the library" and a "work that uses the library". The +former contains code derived from the library, whereas the latter must +be combined with the library in order to run. + + GNU LESSER GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License Agreement applies to any software library or other +program which contains a notice placed by the copyright holder or +other authorized party saying it may be distributed under the terms of +this Lesser General Public License (also called "this License"). +Each licensee is addressed as "you". + + A "library" means a collection of software functions and/or data +prepared so as to be conveniently linked with application programs +(which use some of those functions and data) to form executables. + + The "Library", below, refers to any such software library or work +which has been distributed under these terms. A "work based on the +Library" means either the Library or any derivative work under +copyright law: that is to say, a work containing the Library or a +portion of it, either verbatim or with modifications and/or translated +straightforwardly into another language. (Hereinafter, translation is +included without limitation in the term "modification".) + + "Source code" for a work means the preferred form of the work for +making modifications to it. For a library, complete source code means +all the source code for all modules it contains, plus any associated +interface definition files, plus the scripts used to control compilation +and installation of the library. + + Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running a program using the Library is not restricted, and output from +such a program is covered only if its contents constitute a work based +on the Library (independent of the use of the Library in a tool for +writing it). Whether that is true depends on what the Library does +and what the program that uses the Library does. + + 1. You may copy and distribute verbatim copies of the Library's +complete source code as you receive it, in any medium, provided that +you conspicuously and appropriately publish on each copy an +appropriate copyright notice and disclaimer of warranty; keep intact +all the notices that refer to this License and to the absence of any +warranty; and distribute a copy of this License along with the +Library. + + You may charge a fee for the physical act of transferring a copy, +and you may at your option offer warranty protection in exchange for a +fee. + + 2. You may modify your copy or copies of the Library or any portion +of it, thus forming a work based on the Library, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) The modified work must itself be a software library. + + b) You must cause the files modified to carry prominent notices + stating that you changed the files and the date of any change. + + c) You must cause the whole of the work to be licensed at no + charge to all third parties under the terms of this License. + + d) If a facility in the modified Library refers to a function or a + table of data to be supplied by an application program that uses + the facility, other than as an argument passed when the facility + is invoked, then you must make a good faith effort to ensure that, + in the event an application does not supply such function or + table, the facility still operates, and performs whatever part of + its purpose remains meaningful. + + (For example, a function in a library to compute square roots has + a purpose that is entirely well-defined independent of the + application. Therefore, Subsection 2d requires that any + application-supplied function or table used by this function must + be optional: if the application does not supply it, the square + root function must still compute square roots.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Library, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Library, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote +it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Library. + +In addition, mere aggregation of another work not based on the Library +with the Library (or with a work based on the Library) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may opt to apply the terms of the ordinary GNU General Public +License instead of this License to a given copy of the Library. To do +this, you must alter all the notices that refer to this License, so +that they refer to the ordinary GNU General Public License, version 2, +instead of to this License. (If a newer version than version 2 of the +ordinary GNU General Public License has appeared, then you can specify +that version instead if you wish.) Do not make any other change in +these notices. + + Once this change is made in a given copy, it is irreversible for +that copy, so the ordinary GNU General Public License applies to all +subsequent copies and derivative works made from that copy. + + This option is useful when you wish to copy part of the code of +the Library into a program that is not a library. + + 4. You may copy and distribute the Library (or a portion or +derivative of it, under Section 2) in object code or executable form +under the terms of Sections 1 and 2 above provided that you accompany +it with the complete corresponding machine-readable source code, which +must be distributed under the terms of Sections 1 and 2 above on a +medium customarily used for software interchange. + + If distribution of object code is made by offering access to copy +from a designated place, then offering equivalent access to copy the +source code from the same place satisfies the requirement to +distribute the source code, even though third parties are not +compelled to copy the source along with the object code. + + 5. A program that contains no derivative of any portion of the +Library, but is designed to work with the Library by being compiled or +linked with it, is called a "work that uses the Library". Such a +work, in isolation, is not a derivative work of the Library, and +therefore falls outside the scope of this License. + + However, linking a "work that uses the Library" with the Library +creates an executable that is a derivative of the Library (because it +contains portions of the Library), rather than a "work that uses the +library". The executable is therefore covered by this License. +Section 6 states terms for distribution of such executables. + + When a "work that uses the Library" uses material from a header file +that is part of the Library, the object code for the work may be a +derivative work of the Library even though the source code is not. +Whether this is true is especially significant if the work can be +linked without the Library, or if the work is itself a library. The +threshold for this to be true is not precisely defined by law. + + If such an object file uses only numerical parameters, data +structure layouts and accessors, and small macros and small inline +functions (ten lines or less in length), then the use of the object +file is unrestricted, regardless of whether it is legally a derivative +work. (Executables containing this object code plus portions of the +Library will still fall under Section 6.) + + Otherwise, if the work is a derivative of the Library, you may +distribute the object code for the work under the terms of Section 6. +Any executables containing that work also fall under Section 6, +whether or not they are linked directly with the Library itself. + + 6. As an exception to the Sections above, you may also combine or +link a "work that uses the Library" with the Library to produce a +work containing portions of the Library, and distribute that work +under terms of your choice, provided that the terms permit +modification of the work for the customer's own use and reverse +engineering for debugging such modifications. + + You must give prominent notice with each copy of the work that the +Library is used in it and that the Library and its use are covered by +this License. You must supply a copy of this License. If the work +during execution displays copyright notices, you must include the +copyright notice for the Library among them, as well as a reference +directing the user to the copy of this License. Also, you must do one +of these things: + + a) Accompany the work with the complete corresponding + machine-readable source code for the Library including whatever + changes were used in the work (which must be distributed under + Sections 1 and 2 above); and, if the work is an executable linked + with the Library, with the complete machine-readable "work that + uses the Library", as object code and/or source code, so that the + user can modify the Library and then relink to produce a modified + executable containing the modified Library. (It is understood + that the user who changes the contents of definitions files in the + Library will not necessarily be able to recompile the application + to use the modified definitions.) + + b) Use a suitable shared library mechanism for linking with the + Library. A suitable mechanism is one that (1) uses at run time a + copy of the library already present on the user's computer system, + rather than copying library functions into the executable, and (2) + will operate properly with a modified version of the library, if + the user installs one, as long as the modified version is + interface-compatible with the version that the work was made with. + + c) Accompany the work with a written offer, valid for at + least three years, to give the same user the materials + specified in Subsection 6a, above, for a charge no more + than the cost of performing this distribution. + + d) If distribution of the work is made by offering access to copy + from a designated place, offer equivalent access to copy the above + specified materials from the same place. + + e) Verify that the user has already received a copy of these + materials or that you have already sent this user a copy. + + For an executable, the required form of the "work that uses the +Library" must include any data and utility programs needed for +reproducing the executable from it. However, as a special exception, +the materials to be distributed need not include anything that is +normally distributed (in either source or binary form) with the major +components (compiler, kernel, and so on) of the operating system on +which the executable runs, unless that component itself accompanies +the executable. + + It may happen that this requirement contradicts the license +restrictions of other proprietary libraries that do not normally +accompany the operating system. Such a contradiction means you cannot +use both them and the Library together in an executable that you +distribute. + + 7. 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 not covered by this License, and distribute such a combined +library, provided that the separate distribution of the work based on +the Library and of the other library facilities is otherwise +permitted, and provided that you do these two things: + + a) Accompany the combined library with a copy of the same work + based on the Library, uncombined with any other library + facilities. This must be distributed under the terms of the + Sections above. + + b) Give prominent notice with the combined library of the fact + that part of it is a work based on the Library, and explaining + where to find the accompanying uncombined form of the same work. + + 8. You may not copy, modify, sublicense, link with, or distribute +the Library except as expressly provided under this License. Any +attempt otherwise to copy, modify, sublicense, link with, or +distribute the Library is void, and will automatically terminate your +rights under this License. However, parties who have received copies, +or rights, from you under this License will not have their licenses +terminated so long as such parties remain in full compliance. + + 9. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Library or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Library (or any work based on the +Library), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Library or works based on it. + + 10. Each time you redistribute the Library (or any work based on the +Library), the recipient automatically receives a license from the +original licensor to copy, distribute, link with or modify the Library +subject to these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties with +this License. + + 11. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +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 +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Library at all. For example, if a patent +license would not permit royalty-free redistribution of the Library by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Library. + +If any portion of this section is held invalid or unenforceable under any +particular circumstance, the balance of the section is intended to apply, +and the section as a whole is intended to apply in other circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 12. If the distribution and/or use of the Library is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Library under this License may add +an explicit geographical distribution limitation excluding those countries, +so that distribution is permitted only in or among countries not thus +excluded. In such case, this License incorporates the limitation as if +written in the body of this License. + + 13. The Free Software Foundation may publish revised and/or new +versions of the 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 +specifies a version number of this License which applies to it and +"any later version", you have the option of following the terms and +conditions either of that version or of any later version published by +the Free Software Foundation. If the Library does not specify a +license version number, you may choose any version ever published by +the Free Software Foundation. + + 14. If you wish to incorporate parts of the Library into other free +programs whose distribution conditions are incompatible with these, +write to the author to ask for permission. For software which is +copyrighted by the Free Software Foundation, write to the Free +Software Foundation; we sometimes make exceptions for this. Our +decision will be guided by the two goals of preserving the free status +of all derivatives of our free software and of promoting the sharing +and reuse of software generally. + + NO WARRANTY + + 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO +WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. +EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR +OTHER PARTIES PROVIDE THE LIBRARY "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 +LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME +THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN +WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY +AND/OR REDISTRIBUTE THE LIBRARY 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 +LIBRARY (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 LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF +SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH +DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Libraries + + If you develop a new library, and you want it to be of the greatest +possible use to the public, we recommend making it free software that +everyone can redistribute and change. You can do so by permitting +redistribution under these terms (or, alternatively, under the terms of the +ordinary General Public License). + + To apply these terms, attach the following notices to the library. It is +safest to attach them to the start of each source file to most effectively +convey 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 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 Street, Fifth Floor, Boston, MA 02110-1301 + USA + +Also add information on how to contact you by electronic and paper mail. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the library, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the + library `Frob' (a library for tweaking knobs) written by James Random + Hacker. + + , 1 April 1990 + Ty Coon, President of Vice + +That's all there is to it! diff --git a/VARIANT_COMPLIANCE_CHANGELOG b/VARIANT_COMPLIANCE_CHANGELOG new file mode 100644 index 0000000..001fda6 --- /dev/null +++ b/VARIANT_COMPLIANCE_CHANGELOG @@ -0,0 +1,13 @@ +SAMD CORE 1.6.10 + +* The linker script must define `__text_start__` symbol at the beginning of .text section. + This symbol is used to automatically determine the bootloader size. + +SAMD CORE 1.6.6 + +* `digitalPinToInterrupt` #define moved to Arduino.h, variant.h must no longer define it. + +SAMD CORE 1.6.3 + +* Timer for pin PWM selected based on value of `PIN_ATTR_TIMER_ALT` or `PIN_ATTR_TIMER`. + Prior to this "pin type" (ulPinType) was used. diff --git a/boards.txt b/boards.txt index dda295b..ac1a60c 100644 --- a/boards.txt +++ b/boards.txt @@ -1,4 +1,4 @@ -# Copyright (c) 2014-2015 Arduino LLC. All right reserved. +# Copyright (c) 2014-2017 Arduino LLC. 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 diff --git a/bootloaders/circuitplay/circuitplay_m0_samd21g18_sam_ba.bin b/bootloaders/circuitplay/circuitplay_m0_samd21g18_sam_ba.bin new file mode 100644 index 0000000..b3dc715 Binary files /dev/null and b/bootloaders/circuitplay/circuitplay_m0_samd21g18_sam_ba.bin differ diff --git a/bootloaders/mkr1000/README.md b/bootloaders/mkr1000/README.md new file mode 100644 index 0000000..7a30bd7 --- /dev/null +++ b/bootloaders/mkr1000/README.md @@ -0,0 +1,6 @@ + +The source code of the bootloader is in the folder: + + bootloader/zero/ + + diff --git a/bootloaders/mkr1000/samd21_sam_ba_arduino_mkr1000.bin b/bootloaders/mkr1000/samd21_sam_ba_arduino_mkr1000.bin new file mode 100755 index 0000000..ba434fe Binary files /dev/null and b/bootloaders/mkr1000/samd21_sam_ba_arduino_mkr1000.bin differ diff --git a/bootloaders/mkr1000/samd21_sam_ba_arduino_mkr1000.hex b/bootloaders/mkr1000/samd21_sam_ba_arduino_mkr1000.hex new file mode 100644 index 0000000..02d3d78 --- /dev/null +++ b/bootloaders/mkr1000/samd21_sam_ba_arduino_mkr1000.hex @@ -0,0 +1,403 @@ +:10000000FC7F00200D060000FD0500000106000039 +:1000100000000000000000000000000000000000E0 +:1000200000000000000000000000000005060000C5 +:100030000000000000000000090600004D0700005D +:1000400010B5064C2378002B07D1054B002B02D0AE +:10005000044800E000BF0123237010BD5C000020B5 +:1000600000000000A818000008B5084B002B03D0C2 +:100070000748084900E000BF07480368002B03D089 +:10008000064B002B00D0984708BDC046000000007A +:10009000A8180000600000205800002000000000A8 +:1000A000154A164B1178002909D115491878097895 +:1000B0004118C9B21970802012494003C8611178F3 +:1000C0000131C9B211701978F02902D819780929BB +:1000D00009D80B4908784042C0B2087018780978EE +:1000E0004118C9B2197012781B789A4203D1802244 +:1000F000044B5203DA6170477800002001000020B1 +:10010000000000200044004110B5C3699C07FCD4E6 +:1001100003680224A3430360C46901231C42FBD18A +:100120000468234303600368DC07FCD4C46901232B +:100130001C42FBD1C469DC401C42F7D1084B1A4376 +:100140000260C3695A07FCD4C0239B0243608181CB +:10015000C3699C07FCD4036802221343036010BDEB +:1001600004000040037EDA07FCD5018570470000DB +:10017000027E01235107FBD5428B1A4207D1428BE5 +:10018000DA401A4203D1428B92081A4202D0034B42 +:1001900001221A70008DC0B27047C046790000205D +:1001A00070B50368041C988B1A1C0821FF320842A2 +:1001B00026D0802099839872112353704021144BCC +:1001C000917150715E68134DC0202E40800506432A +:1001D0005E605E693540284358610F4818600F48DB +:1001E00018615D680E4828408025AD02284358609C +:1001F0005868800B8003586000235171237105E01B +:10020000137ADA0602D5201C00F0DAFA207970BDE4 +:1002100098010020FFFFFF8F9800002018010020A8 +:10022000FF3F00F0002303714371044B01608360C2 +:100230000B78022213430B707047C046A1010000E7 +:1002400038B5364B2021DA6901200A43DA61344B94 +:1002500006241A7802431A70324B0F221978914300 +:1002600019701978214319702F490C7820430870B0 +:1002700019780A401A701A7860210A431A702B4BB9 +:100280002B4A5A805A7852B2002AFBDB294B0121B3 +:100290001A780A431A709A78D107FCD42648026863 +:1002A000510B1F221140914200D1052111408C01B8 +:1002B0001D8D22492940214319850468A10C0A405B +:1002C0001F2A00D11D221C8D1F210A408C4322436E +:1002D0001A8502680721D20D0A408A4200D1032202 +:1002E0000A40188D1103164A02400A431A851978EC +:1002F0007F220A401A701A78042112480A431A70A1 +:1003000058621A890C218A431A811A8901218A4369 +:100310001A810021802201F046F938BD0004004016 +:10032000584400413C44004159440041000C004005 +:100330000640000000500041246080003FF8FFFFAD +:10034000FF8FFFFF98010020F7B5141C1F4A5F01C3 +:1003500001971D1CD319061C5869271C4000400F2B +:1003600003301033C74006D00F1C80225968120694 +:100370000A435A6009E02F1C7B1E9F41144BBF01AA +:10038000FF18381C221C01F005F901990F480835A7 +:1003900042181761131C5269A104920B890C920335 +:1003A0000A435A6159690B4A0A405A616B01F318B2 +:1003B0000222DA715979802252420A435A716B0142 +:1003C000F318DB799A07FAD5201CFEBD98010020AE +:1003D00018010020FF3F00F0F8B51A4E051C3378D5 +:1003E000141C002B12D1184B184A1A645A6C920B29 +:1003F00092035A64586C164A02405A64A2235B0066 +:10040000EA5C40200243EA54012333704827FF3757 +:10041000EA5D0123134012D00B4B5A6C9204920CEC +:10042000A24202D25C6CA404A40C081C221C074942 +:1004300001F0B0F80123EB550023337000E01C1CE1 +:10044000201CF8BD7A00002098010020D800002070 +:10045000FF3F00F0FF3083792022002900D11022D5 +:100460001343837170470000084BFF305A69920BA9 +:1004700092035A6102230372827980235B42134301 +:100480008371037A9A07FCD57047C0469801002013 +:1004900080235B421943C9B28172704770B5A023B3 +:1004A00003225B00C254134B134A5C6CC0211440FE +:1004B00089050C4346255C64FF35402444550F4DA7 +:1004C00030261D6490256D0046555D6B154029430F +:1004D000922559636D0080214155094D1D63B0255A +:1004E0006D0044555C6F22405A67B2235B00C154D3 +:1004F00070BDC04698010020FFFFFF8FD80000208C +:1005000058010020024B5B785BB2002BFADB70478E +:10051000000C0040024BDB68DA06FBD57047C04692 +:1005200000080040F8B52A4B1E2259689143022268 +:1005300011435960274B28491E1C9982998A0A4306 +:100540009A82F3680227234C3B42FAD0234D0123C1 +:10055000AB60FFF7D7FF224B6B60FFF7D3FF82231F +:10056000DB016B80FFF7CEFFA38C80229343A38433 +:10057000FFF7D0FF1B4BE362FFF7CCFFA38C1A4AB7 +:100580001343A384FFF7C6FFA38C1F43A784F3681C +:100590001A06FCD50F4BDB685A06F8D50024FFF786 +:1005A000B9FFAC60FFF7AEFF104B6B60FFF7AAFF1F +:1005B0000F4B104AC0215A600F4A0906106A000208 +:1005C000000A0143116207229C601A60F8BDC04610 +:1005D00000400041000800400C060000000C0040F4 +:1005E00001050100B805FF7D040A000000070300B3 +:1005F00010E000E0E703000000ED00E00EBEFEE7C3 +:100600000DBEFEE705BEFEE702BEFEE70E4A0F483E +:1006100038B5824204D10E4A0E4B93420ED10AE005 +:100620000D4C9442F7D00023D1188842F3D9E558F5 +:1006300004330D60F8E700F011F804E09342FAD2B9 +:10064000002102C3FAE7FEE7000000205C00002062 +:10065000A80300205C000020AC18000038B5304B27 +:100660001A681C1C013221D02E4A191D1160D9B202 +:1006700000291BD12C4A1078012210402B4A0AD1A4 +:1006800015682B498D4201D110600FE01160294996 +:1006900001390029FCD11160226882F30888FF2209 +:1006A0009343254A93601E4B5B681847FFF73AFF58 +:1006B00062B600F09DFD00F04FF8204B80225203FF +:1006C0009A601F4B1F4A041C5A601B4AC021106AC3 +:1006D00009060002000A0143116200229A60072203 +:1006E0001A60A368201C9847174B002801D00122EC +:1006F0001A701A78002A05D0002000F08BFA00F05A +:1007000003FBFCE71B78002BEBD100F0E5FD002894 +:10071000E7D0012000F07EFA00F0F6FAFCE7C046D0 +:10072000002000001802002038040040FC7F002058 +:100730003581730748E8010000ED00E00044004106 +:1007400010E000E0E70300007B00002008B5FFF7A1 +:10075000A7FC00F0C3FA08BD10B5054B054C23609B +:10076000FFF76EFD201C2168FFF75CFD201C10BD0B +:10077000005000411C02002070B5051CC0B0081CD0 +:10078000161C0C1C00F017FF40006A4603230230C1 +:100790005370107076080123E218013A11785A005C +:1007A000002906D1281C69460023FFF7CDFD40B083 +:1007B00070BDB342F6DA684681520133ECE70000BF +:1007C000F7B5BA4A04681378B949271CFF37051CE6 +:1007D000102038720B705378B648B74E0370937878 +:1007E0003380D178338809020B4333801179B34BBE +:1007F0001980517918880902084318809079B04906 +:100800000880D2790888120202430A8040227A7155 +:10081000A84F3A78A64F120238780F1C0243A94815 +:100820008446181C624500D1C2E020DC80214900CA +:100830008A4200D16EE109DC812A00D192E0822A4D +:1008400000D195E0802A00D064E18BE081235B0039 +:100850009A4200D1CFE000DA58E1C0239B009A42CF +:1008600000D157E1984B9A4200D14FE152E19023D9 +:100870001B019A4269D015DCD023DB009A4222D0BA +:1008800088231B019A4269D0A023DB009A4200D042 +:1008900040E1201CFFF7E8FD3188286889B2FFF7A6 +:1008A000F7FD3BE1894B9A4200D12FE100DC31E1B9 +:1008B000874B9A4200D11DE1864B9A4200D029E134 +:1008C00033886B7122E133881B0A012B08D10B8816 +:1008D00012222868934201D80A8892B27E4911E117 +:1008E00033881B0A022B08D10B88432228689342C5 +:1008F00001D80A8892B2794904E133881B0A032B94 +:1009000000D007E13388DBB2012B17D0002B07D0D2 +:10091000022B00D0FEE00A882868D2B2704911E0AC +:10092000042201A86F4900F035FE3B8804222868A4 +:10093000934201D83A8892B201A9E3E00A88286874 +:100940006949D2B2FFF718FFE8E03388201C2B7109 +:10095000FFF78AFD201CFFF7A1FDDFE0291C01C97C +:100960000122CFE0614900230B8028680222CAE0FF +:100970005E4900220A801888502210405C4A10709C +:100980001E880F20304018801888032800D9C1E045 +:1009900012781B8808335B01E418A379002A01D080 +:1009A0009B0600E0DB06DB0F0B8028680222A9E033 +:1009B00019887F2291434E4AC9B2117018880F21BD +:1009C000014019803188002900D0A3E0198800294E +:1009D00000D19FE01988032900D99BE012781B8879 +:1009E00008335B01E318002A02D020225A718DE0FF +:1009F000102159718AE002887F239A433C4BD2B27E +:100A00001A7001880F220A4002803288002A00D022 +:100A100080E00288002A00D17CE00288032A00D905 +:100A200078E01B78002B1FD0038808335B01E318A4 +:100A30009B799A066AD50388202208335B01E31864 +:100A40001A71038808335B01E318DB795F065DD513 +:100A50000388402208335B01E318DA71038802221D +:100A600008335B01E3181EE0038808335B01E318D9 +:100A70009B79D9064AD50388102208335B01E31815 +:100A80001A71038808335B01E318DB799A063DD5B8 +:100A90000388202208335B01E318DA7103880122FE +:100AA00008335B01E3181A7130E0C046980000205B +:100AB0007D000020820000208400002086000020AD +:100AC000800000200203000001030000212000003C +:100AD000A121000021220000FC15000004000020DC +:100AE000EC150000DC150000E01500007E00002081 +:100AF0007C0000200B8808222868934201D80A88CD +:100B000092B207490023FFF71FFC07E0201CFFF704 +:100B1000ABFC03E0201C0121FFF79CFCF7BDC046A5 +:100B20004800002007B5054B0122019001A9186873 +:100B3000131CFFF709FC01200EBDC0461C0200205B +:100B400013B5054B6C4607341868211C0122FFF7CA +:100B500043FC207816BDC0461C02002010B5074C8F +:100B6000201CFFF71DFB031C0020834205D02268D8 +:100B70004823FF33D05C0123184010BD1C02002025 +:100B800010B5054A0C1C031C191C10680123221CFB +:100B9000FFF7DAFB201C10BD1C02002070B5084CCA +:100BA000061C201C0D1CFFF7FBFA0023984205D001 +:100BB0002068311C2A1CFFF70FFC031C181C70BD99 +:100BC0001C020020F8B50C4C051C201C0E1CFFF765 +:100BD000E7FA0023271C341C98420AD0002C07D0C7 +:100BE000291C221C3868FFF7F7FB241A2D18F5E79B +:100BF000331C181CF8BDC0461C02002008B5031C9D +:100C0000081C111C9847024B64221A8008BDC0467C +:100C10008C000020012805D1054B064A1A60064BBE +:100C2000187004E0002802D1044A014B1A60704792 +:100C30008C02002030160000940000207C1600007A +:100C400030B50A1C1C4985B00978031C00292AD03C +:100C5000042A01D1006804E0022A01D1008800E0E2 +:100C60000078520004A98B180B3B9C1AA3420BD0AE +:100C70000F210140092902D83025294300E03731EE +:100C800019700009013BF1E701A930230B707823AB +:100C90004B700A208B1898700D20D870074B0432C7 +:100CA0001B68D86803E005490968C868191CFFF784 +:100CB000A5FF05B030BDC046880000208C02002092 +:100CC00072B6EFF30883044A1360036883F308885D +:100CD000436818477047C04690020020084B1A88A6 +:100CE000002A03D01A88013A92B21A80054B1A885A +:100CF000002A03D01A88013A92B21A807047C0467F +:100D00008C0000208A000020F0B591B008A9CC4AE0 +:100D10000B1C31CA31C351CA51C360CA60C3C94B2D +:100D2000C9489A687A255203520F92005258C7490F +:100D300002609C68A4B262430C60C54900240A604A +:100D4000C44A1460C44C2570C44CC54D2368281C8B +:100D50001B6940219847002802D0C24B64221A80A8 +:100D6000C14B00221860C14B1D60C14BC04DBE4F2E +:100D70001A602A683B689A42E6D2BC4B1B681A7814 +:100D8000FF2A00D114E2232A00D0EBE1B94E3378D8 +:100D9000002B06D0B14BB8491B680222D868FFF778 +:100DA0002DFFAD4B1B78532B3CD13B682A689342F7 +:100DB0001ED9AE4801322A609A1AB04B01681B68EE +:100DC00001310160AE4E9A4201D2326000E03360E0 +:100DD000A04832680068049000F0DCFB33682968A2 +:100DE0005A182A60A14A1668F1181160A54A1370B2 +:100DF0002B68013B2B609D4B1A68013A1A60A14B8E +:100E00009E4A1B7811688B420AD222689148C91AFF +:100E1000006892699047002802D0924B64221A80A1 +:100E2000C0468DE1522B0AD18A48944A2368006853 +:100E300011685B69039098476422934B0DE04F2B38 +:100E400005D1844B8D4A1B6812681A7078E1482BD3 +:100E500005D1804B894A1B6812681A8070E1572BB4 +:100E600005D17C4B854A1B6812681A6068E16F2BBC +:100E700003D1784B0121186807E0682B08D1754B26 +:100E80007E481B6802211B880360FFF7D9FE57E1EB +:100E9000772B06D16F4B79481B6804211B680360D0 +:100EA000F3E7472B13D1754B1868FFF709FF774B12 +:100EB0001B6883F3088862B6754B1B78002B00D142 +:100EC0003EE1664B06201B681B68984738E1542BAF +:100ED00004D101233370614B1B6864E04E2B0CD1AD +:100EE0003378002B06D15D4B63491B680222D8681A +:100EF000FFF784FE0023337022E1562B57D123687D +:100F00006449D8680122FFF779FE23686249D868EE +:100F10000322FFF773FE614D2368291CD868012264 +:100F2000FFF76CFE23685E49D8680D22FFF766FE66 +:100F30002368291CD8680122FFF760FE4B4F4C4DF7 +:100F40005849002339602B603A1C281C13685E1C2A +:100F500016601B780593002B03D0036801330360F0 +:100F6000F4E73E4E2A683368D868FFF747FE3368D7 +:100F70004A49D8680122FFF741FE059929604A498C +:100F800039603A4A1368581C10601B78002B04D053 +:100F9000374B1A6801321A60F3E733682A68D86859 +:100FA000FFF72CFE3368D86833490222C6E0334A83 +:100FB000582B17D1244E264D366813682A68B10085 +:100FC00093420AD21F4D5808E861384828801D4DC9 +:100FD000287DC607FBD55B18F2E7204B34491B6818 +:100FE000D868AAE0592B79D112681A4B3149002AE6 +:100FF00002D11B680B606CE0124D086819686B68C1 +:10100000104E8025AB4392087360002A61D02A4BB2 +:101010000C4D2B800B4E337DDD07FBD500230A4D95 +:101020002D680195AD08AB4203D3244D054E3580A4 +:1010300046E09342F9D09D00465901334E51EEE708 +:101040001016000000400041440200203C02002035 +:101050003802002088020020340200208C02002088 +:10106000480200208A0000202C02002030020020CC +:10107000400200208800002070160000940200202A +:1010800098020020280200208C00002090020020FE +:10109000940000204C160000751600004E1600004B +:1010A00098160000501600005C16000002A5FFFF15 +:1010B000651600009000002044A5FFFF04A5FFFF77 +:1010C0003F4E357DEE07FBD59D0049194019D21AD8 +:1010D0009BE73C4B3C491B68D8682EE05A2B2FD12C +:1010E0003A4B17681D680026EF19BD4206D02878D4 +:1010F000311C00F013F90135061CF6E7314B344979 +:101100001B680122D868FFF779FD07230F223240C0 +:10111000111C36093031092A00DD07311820C018AA +:101120006A468154013BF1D2236806A9D868082297 +:10113000FFF764FD23682749D8680322FFF75EFDA7 +:10114000254B7A221A70254B00221A60244B1B78FB +:1011500093422DD01B4B23491B680122D868FFF70F +:101160004DFD25E0111C3039C8B21C4B092804D8AC +:101170001D682A01114319601AE0111C4139052923 +:1011800003D81E68373A310106E0111C6139052980 +:1011900004D81868573A01010A4308E02C2A03D101 +:1011A0000A4A1968116001E00B490A7000221A60AE +:1011B0000D4B1A6801321A600C4B1A680132D5E5E2 +:1011C000004000418C0200206916000088020020C7 +:1011D0006D1600006F1600003402002094020020FB +:1011E000880000207316000040020020300200201A +:1011F00010B51C4B01201A78022402431A701A4BB6 +:101200000F221978914319701978214319701749E1 +:101210000C782043087019780A401A701A78202137 +:101220000A431A70124B04211A6A0A431A62114BBC +:10123000114A5A805A7852B2002AFBDBC4220F4866 +:101240000F499203FEF760FF0E4A002313700E4A07 +:1012500013700E4A13700E4A13700E4A13700E4A22 +:10126000137010BD4A440041354400414B440041D5 +:1012700000040040000C0040144000000008004240 +:101280002AF600009C020020230300209D0200207B +:10129000A0020020240300202103002008B5C1B2D1 +:1012A0000248FEF75FFF012008BDC046000800426B +:1012B000024B187E4007C00F7047C046000800422E +:1012C00008B5FFF7F5FF0028FBD00248FEF750FFF6 +:1012D00008BDC0460008004208B5FFF7E9FF00233B +:1012E000984205D0FFF7ECFF031C233B5A425341C1 +:1012F000181C08BD70B5041C0D1C4618B44204D05F +:101300002078FFF7CBFF0134F8E7281C70BD10B53B +:10131000041CFFF7D5FF2070012010BD0B0A5840B8 +:10132000034B4000C05A0902484080B27047C04693 +:10133000A6160000F7B50024051C0F1C261CBC4295 +:1013400020D0FFF7BDFF114BC0B21B780190002BDE +:101350001AD1311CFFF7E2FF0D4B061C1A88002A38 +:1013600004D10C4A11782A1C002907D001996A1C63 +:101370002970802F02D11988013919800134A4B253 +:10138000151CDCE7301C00E00120FEBD210300201D +:101390009E02002022030020F0B53E4E85B00022C0 +:1013A00003900C1C32703C4B914201D1012201E0B0 +:1013B0003A490C801A707F231C4201D080349C4330 +:1013C000FFF77EFF3378C0B2002B07D000253570C1 +:1013D000FFF776FF3378C0B2AB4236D1432803D053 +:1013E000712853D01528EBD1012300930120FFF77A +:1013F00055FF0098FFF752FF00998025C843C0B2FF +:10140000FFF74CFF039B00270293244A1388002B0D +:101410001DD1214901930978002918D10198FFF7BE +:101420003DFF391C0198FFF779FF013D071C002D96 +:10143000EBD1000AC0B2FFF731FFF8B2FFF72EFF81 +:10144000FFF73EFF3378002B0AD035701FE002997A +:10145000013B09781380029B019101330293DDE780 +:10146000C0B2062807D1009B03990133DBB280315B +:101470000093803C0391002CB8D10420FFF70EFFAD +:10148000FFF71EFF044B01251C7000E00025281CFF +:1014900005B0F0BD21030020220300209E020020A1 +:1014A000F0B5384C87B0002301902370994201D1E8 +:1014B000012301E0344A1180344A6426137043202A +:1014C000FFF7ECFE324FFFF7F3FE002803D1002FA9 +:1014D00003D0013FF7E7002F03D1013E002EEED1EC +:1014E0004DE00125FFF7ECFE2378002B38D1C0B288 +:1014F0000290012805D004283DD10620FFF7CEFE3A +:1015000039E005AE0221301CFFF714FF019880215D +:10151000FFF710FF23780390002B18D1FFF7D0FEC0 +:101520000702FFF7CDFEBFB223783F18BFB2012BF1 +:101530000DD0039B9F4207D13378AB4204D1EB43DC +:101540007278DBB29A4204D01820FFF7A7FE00237E +:1015500003E00620FFF7A2FE029B2278002A02D0B9 +:10156000002626700BE0012B05D1019A6B1C8032FE +:10157000DDB20192B6E7054A002313700126301C44 +:1015800007B0F0BD210300209E02002022030020AE +:1015900000350C0010B50023934203D0CC5CC4543A +:1015A0000133F9E710BD031C8218934202D0197071 +:1015B0000133FAE770470023C25C0133002AFBD1F4 +:1015C000581E7047F8B5C046F8BC08BC9E46704728 +:1015D000F8B5C046F8BC08BC9E4670470403090431 +:1015E00041726475696E6F204C4C430041726475A2 +:1015F000696E6F204D4B52313030300012010002C5 +:101600000200004041234E000002010200010000E0 +:101610000800000010000000200000004000000052 +:101620008000000000010000000200000004000033 +:101630009D120000C1120000B1120000F51200005E +:101640000F13000099130000A11400007600200081 +:1016500041707220313120323031390031333A302B +:10166000393A353100580A0D00590A0D005A002345 +:101670000A0D003E00322E3000000000250B000055 +:10168000410B00005D0B0000810B00009D0B000072 +:10169000810B0000C50B00005B41726475696E6FC1 +:1016A0003A58595A5D0000002110422063308440AE +:1016B000A550C660E770088129914AA16BB18CC121 +:1016C000ADD1CEE1EFF13112100273325222B55298 +:1016D0009442F772D662399318837BB35AA3BDD371 +:1016E0009CC3FFF3DEE36224433420040114E66468 +:1016F000C774A44485546AA54BB528850995EEE5C1 +:10170000CFF5ACC58DD55336722611163006D77677 +:10171000F6669556B4465BB77AA719973887DFF710 +:10172000FEE79DD7BCC7C448E5588668A77840083F +:10173000611802282338CCC9EDD98EE9AFF9488960 +:1017400069990AA92BB9F55AD44AB77A966A711AD7 +:10175000500A333A122AFDDBDCCBBFFB9EEB799BB0 +:10176000588B3BBB1AABA66C877CE44CC55C222C27 +:10177000033C600C411CAEED8FFDECCDCDDD2AAD00 +:101780000BBD688D499D977EB66ED55EF44E133EB7 +:10179000322E511E700E9FFFBEEFDDDFFCCF1BBF50 +:1017A0003AAF599F788F8891A981CAB1EBA10CD12A +:1017B0002DC14EF16FE18010A100C230E320045032 +:1017C000254046706760B9839893FBA3DAB33DC3A5 +:1017D0001CD37FE35EF3B1029012F322D232354282 +:1017E000145277625672EAB5CBA5A89589856EF535 +:1017F0004FE52CD50DC5E234C324A01481046674D2 +:10180000476424540544DBA7FAB79987B8975FE784 +:101810007EF71DC73CD7D326F2369106B016576621 +:101820007676154634564CD96DC90EF92FE9C8990C +:10183000E9898AB9ABA94458654806782768C01871 +:10184000E1088238A3287DCB5CDB3FEB1EFBF98BE4 +:10185000D89BBBAB9ABB754A545A376A167AF10AC1 +:10186000D01AB32A923A2EFD0FED6CDD4DCDAABDF4 +:101870008BADE89DC98D267C076C645C454CA23C11 +:10188000832CE01CC10C1FEF3EFF5DCF7CDF9BAFC4 +:10189000BABFD98FF89F176E367E554E745E932E61 +:0C18A000B23ED10EF01E0000000000005F +:1018AC000114000009024300020100803209040007 +:1018BC0000010202000005240010010424020005AE +:1018CC00240600010524010001070583030800FF1D +:1018DC0009040100020A0000000705810240000013 +:1018EC00070502024000000000C2010000000800D1 +:0C18FC0069000000410000000000000036 +:040000030000060DE6 +:00000001FF diff --git a/bootloaders/mkrfox1200/samd21_sam_ba_arduino_mkrfox1200.bin b/bootloaders/mkrfox1200/samd21_sam_ba_arduino_mkrfox1200.bin new file mode 100755 index 0000000..7764b89 Binary files /dev/null and b/bootloaders/mkrfox1200/samd21_sam_ba_arduino_mkrfox1200.bin differ diff --git a/bootloaders/mkrfox1200/samd21_sam_ba_arduino_mkrfox1200.hex b/bootloaders/mkrfox1200/samd21_sam_ba_arduino_mkrfox1200.hex new file mode 100644 index 0000000..0365585 --- /dev/null +++ b/bootloaders/mkrfox1200/samd21_sam_ba_arduino_mkrfox1200.hex @@ -0,0 +1,404 @@ +:10000000FC7F00200D060000FD0500000106000039 +:1000100000000000000000000000000000000000E0 +:1000200000000000000000000000000005060000C5 +:100030000000000000000000090600004D0700005D +:1000400010B5064C2378002B07D1054B002B02D0AE +:10005000044800E000BF0123237010BD5C000020B5 +:1000600000000000B018000008B5084B002B03D0BA +:100070000748084900E000BF07480368002B03D089 +:10008000064B002B00D0984708BDC046000000007A +:10009000B0180000600000205800002000000000A0 +:1000A000154A164B1178002909D115491878097895 +:1000B0004118C9B21970802012494003C8611178F3 +:1000C0000131C9B211701978F02902D819780929BB +:1000D00009D80B4908784042C0B2087018780978EE +:1000E0004118C9B2197012781B789A4203D1802244 +:1000F000044B5203DA6170477800002001000020B1 +:10010000000000200044004110B5C3699C07FCD4E6 +:1001100003680224A3430360C46901231C42FBD18A +:100120000468234303600368DC07FCD4C46901232B +:100130001C42FBD1C469DC401C42F7D1084B1A4376 +:100140000260C3695A07FCD4C0239B0243608181CB +:10015000C3699C07FCD4036802221343036010BDEB +:1001600004000040037EDA07FCD5018570470000DB +:10017000027E01235107FBD5428B1A4207D1428BE5 +:10018000DA401A4203D1428B92081A4202D0034B42 +:1001900001221A70008DC0B27047C046790000205D +:1001A00070B50368041C988B1A1C0821FF320842A2 +:1001B00026D0802099839872112353704021144BCC +:1001C000917150715E68134DC0202E40800506432A +:1001D0005E605E693540284358610F4818600F48DB +:1001E00018615D680E4828408025AD02284358609C +:1001F0005868800B8003586000235171237105E01B +:10020000137ADA0602D5201C00F0DAFA207970BDE4 +:1002100098010020FFFFFF8F9800002018010020A8 +:10022000FF3F00F0002303714371044B01608360C2 +:100230000B78022213430B707047C046A1010000E7 +:1002400038B5364B2021DA6901200A43DA61344B94 +:1002500006241A7802431A70324B0F221978914300 +:1002600019701978214319702F490C7820430870B0 +:1002700019780A401A701A7860210A431A702B4BB9 +:100280002B4A5A805A7852B2002AFBDB294B0121B3 +:100290001A780A431A709A78D107FCD42648026863 +:1002A000510B1F221140914200D1052111408C01B8 +:1002B0001D8D22492940214319850468A10C0A405B +:1002C0001F2A00D11D221C8D1F210A408C4322436E +:1002D0001A8502680721D20D0A408A4200D1032202 +:1002E0000A40188D1103164A02400A431A851978EC +:1002F0007F220A401A701A78042112480A431A70A1 +:1003000058621A890C218A431A811A8901218A4369 +:100310001A810021802201F046F938BD0004004016 +:10032000584400413C44004159440041000C004005 +:100330000640000000500041246080003FF8FFFFAD +:10034000FF8FFFFF98010020F7B5141C1F4A5F01C3 +:1003500001971D1CD319061C5869271C4000400F2B +:1003600003301033C74006D00F1C80225968120694 +:100370000A435A6009E02F1C7B1E9F41144BBF01AA +:10038000FF18381C221C01F005F901990F480835A7 +:1003900042181761131C5269A104920B890C920335 +:1003A0000A435A6159690B4A0A405A616B01F318B2 +:1003B0000222DA715979802252420A435A716B0142 +:1003C000F318DB799A07FAD5201CFEBD98010020AE +:1003D00018010020FF3F00F0F8B51A4E051C3378D5 +:1003E000141C002B12D1184B184A1A645A6C920B29 +:1003F00092035A64586C164A02405A64A2235B0066 +:10040000EA5C40200243EA54012333704827FF3757 +:10041000EA5D0123134012D00B4B5A6C9204920CEC +:10042000A24202D25C6CA404A40C081C221C074942 +:1004300001F0B0F80123EB550023337000E01C1CE1 +:10044000201CF8BD7A00002098010020D800002070 +:10045000FF3F00F0FF3083792022002900D11022D5 +:100460001343837170470000084BFF305A69920BA9 +:1004700092035A6102230372827980235B42134301 +:100480008371037A9A07FCD57047C0469801002013 +:1004900080235B421943C9B28172704770B5A023B3 +:1004A00003225B00C254134B134A5C6CC0211440FE +:1004B00089050C4346255C64FF35402444550F4DA7 +:1004C00030261D6490256D0046555D6B154029430F +:1004D000922559636D0080214155094D1D63B0255A +:1004E0006D0044555C6F22405A67B2235B00C154D3 +:1004F00070BDC04698010020FFFFFF8FD80000208C +:1005000058010020024B5B785BB2002BFADB70478E +:10051000000C0040024BDB68DA06FBD57047C04692 +:1005200000080040F8B52A4B1E2259689143022268 +:1005300011435960274B28491E1C9982998A0A4306 +:100540009A82F3680227234C3B42FAD0234D0123C1 +:10055000AB60FFF7D7FF224B6B60FFF7D3FF82231F +:10056000DB016B80FFF7CEFFA38C80229343A38433 +:10057000FFF7D0FF1B4BE362FFF7CCFFA38C1A4AB7 +:100580001343A384FFF7C6FFA38C1F43A784F3681C +:100590001A06FCD50F4BDB685A06F8D50024FFF786 +:1005A000B9FFAC60FFF7AEFF104B6B60FFF7AAFF1F +:1005B0000F4B104AC0215A600F4A0906106A000208 +:1005C000000A0143116207229C601A60F8BDC04610 +:1005D00000400041000800400C060000000C0040F4 +:1005E00001050100B805FF7D040A000000070300B3 +:1005F00010E000E0E703000000ED00E00EBEFEE7C3 +:100600000DBEFEE705BEFEE702BEFEE70E4A0F483E +:1006100038B5824204D10E4A0E4B93420ED10AE005 +:100620000D4C9442F7D00023D1188842F3D9E558F5 +:1006300004330D60F8E700F011F804E09342FAD2B9 +:10064000002102C3FAE7FEE7000000205C00002062 +:10065000A80300205C000020B418000038B5304B1F +:100660001A681C1C013221D02E4A191D1160D9B202 +:1006700000291BD12C4A1078012210402B4A0AD1A4 +:1006800015682B498D4201D110600FE01160294996 +:1006900001390029FCD11160226882F30888FF2209 +:1006A0009343254A93601E4B5B681847FFF73AFF58 +:1006B00062B600F09DFD00F04FF8204B80225203FF +:1006C0009A601F4B1F4A041C5A601B4AC021106AC3 +:1006D00009060002000A0143116200229A60072203 +:1006E0001A60A368201C9847174B002801D00122EC +:1006F0001A701A78002A05D0002000F08BFA00F05A +:1007000003FBFCE71B78002BEBD100F0E5FD002894 +:10071000E7D0012000F07EFA00F0F6FAFCE7C046D0 +:10072000002000001802002038040040FC7F002058 +:100730003581730748E8010000ED00E00044004106 +:1007400010E000E0E70300007B00002008B5FFF7A1 +:10075000A7FC00F0C3FA08BD10B5054B054C23609B +:10076000FFF76EFD201C2168FFF75CFD201C10BD0B +:10077000005000411C02002070B5051CC0B0081CD0 +:10078000161C0C1C00F017FF40006A4603230230C1 +:100790005370107076080123E218013A11785A005C +:1007A000002906D1281C69460023FFF7CDFD40B083 +:1007B00070BDB342F6DA684681520133ECE70000BF +:1007C000F7B5BA4A04681378B949271CFF37051CE6 +:1007D000102038720B705378B648B74E0370937878 +:1007E0003380D178338809020B4333801179B34BBE +:1007F0001980517918880902084318809079B04906 +:100800000880D2790888120202430A8040227A7155 +:10081000A84F3A78A64F120238780F1C0243A94815 +:100820008446181C624500D1C2E020DC80214900CA +:100830008A4200D16EE109DC812A00D192E0822A4D +:1008400000D195E0802A00D064E18BE081235B0039 +:100850009A4200D1CFE000DA58E1C0239B009A42CF +:1008600000D157E1984B9A4200D14FE152E19023D9 +:100870001B019A4269D015DCD023DB009A4222D0BA +:1008800088231B019A4269D0A023DB009A4200D042 +:1008900040E1201CFFF7E8FD3188286889B2FFF7A6 +:1008A000F7FD3BE1894B9A4200D12FE100DC31E1B9 +:1008B000874B9A4200D11DE1864B9A4200D029E134 +:1008C00033886B7122E133881B0A012B08D10B8816 +:1008D00012222868934201D80A8892B27E4911E117 +:1008E00033881B0A022B08D10B88432228689342C5 +:1008F00001D80A8892B2794904E133881B0A032B94 +:1009000000D007E13388DBB2012B17D0002B07D0D2 +:10091000022B00D0FEE00A882868D2B2704911E0AC +:10092000042201A86F4900F035FE3B8804222868A4 +:10093000934201D83A8892B201A9E3E00A88286874 +:100940006949D2B2FFF718FFE8E03388201C2B7109 +:10095000FFF78AFD201CFFF7A1FDDFE0291C01C97C +:100960000122CFE0614900230B8028680222CAE0FF +:100970005E4900220A801888502210405C4A10709C +:100980001E880F20304018801888032800D9C1E045 +:1009900012781B8808335B01E418A379002A01D080 +:1009A0009B0600E0DB06DB0F0B8028680222A9E033 +:1009B00019887F2291434E4AC9B2117018880F21BD +:1009C000014019803188002900D0A3E0198800294E +:1009D00000D19FE01988032900D99BE012781B8879 +:1009E00008335B01E318002A02D020225A718DE0FF +:1009F000102159718AE002887F239A433C4BD2B27E +:100A00001A7001880F220A4002803288002A00D022 +:100A100080E00288002A00D17CE00288032A00D905 +:100A200078E01B78002B1FD0038808335B01E318A4 +:100A30009B799A066AD50388202208335B01E31864 +:100A40001A71038808335B01E318DB795F065DD513 +:100A50000388402208335B01E318DA71038802221D +:100A600008335B01E3181EE0038808335B01E318D9 +:100A70009B79D9064AD50388102208335B01E31815 +:100A80001A71038808335B01E318DB799A063DD5B8 +:100A90000388202208335B01E318DA7103880122FE +:100AA00008335B01E3181A7130E0C046980000205B +:100AB0007D000020820000208400002086000020AD +:100AC000800000200203000001030000212000003C +:100AD000A1210000212200000416000004000020D3 +:100AE000EC150000DC150000E01500007E00002081 +:100AF0007C0000200B8808222868934201D80A88CD +:100B000092B207490023FFF71FFC07E0201CFFF704 +:100B1000ABFC03E0201C0121FFF79CFCF7BDC046A5 +:100B20004800002007B5054B0122019001A9186873 +:100B3000131CFFF709FC01200EBDC0461C0200205B +:100B400013B5054B6C4607341868211C0122FFF7CA +:100B500043FC207816BDC0461C02002010B5074C8F +:100B6000201CFFF71DFB031C0020834205D02268D8 +:100B70004823FF33D05C0123184010BD1C02002025 +:100B800010B5054A0C1C031C191C10680123221CFB +:100B9000FFF7DAFB201C10BD1C02002070B5084CCA +:100BA000061C201C0D1CFFF7FBFA0023984205D001 +:100BB0002068311C2A1CFFF70FFC031C181C70BD99 +:100BC0001C020020F8B50C4C051C201C0E1CFFF765 +:100BD000E7FA0023271C341C98420AD0002C07D0C7 +:100BE000291C221C3868FFF7F7FB241A2D18F5E79B +:100BF000331C181CF8BDC0461C02002008B5031C9D +:100C0000081C111C9847024B64221A8008BDC0467C +:100C10008C000020012805D1054B064A1A60064BBE +:100C2000187004E0002802D1044A014B1A60704792 +:100C30008C0200203816000094000020841600006A +:100C400030B50A1C1C4985B00978031C00292AD03C +:100C5000042A01D1006804E0022A01D1008800E0E2 +:100C60000078520004A98B180B3B9C1AA3420BD0AE +:100C70000F210140092902D83025294300E03731EE +:100C800019700009013BF1E701A930230B707823AB +:100C90004B700A208B1898700D20D870074B0432C7 +:100CA0001B68D86803E005490968C868191CFFF784 +:100CB000A5FF05B030BDC046880000208C02002092 +:100CC00072B6EFF30883044A1360036883F308885D +:100CD000436818477047C04690020020084B1A88A6 +:100CE000002A03D01A88013A92B21A80054B1A885A +:100CF000002A03D01A88013A92B21A807047C0467F +:100D00008C0000208A000020F0B591B008A9CC4AE0 +:100D10000B1C31CA31C351CA51C360CA60C3C94B2D +:100D2000C9489A687A255203520F92005258C7490F +:100D300002609C68A4B262430C60C54900240A604A +:100D4000C44A1460C44C2570C44CC54D2368281C8B +:100D50001B6940219847002802D0C24B64221A80A8 +:100D6000C14B00221860C14B1D60C14BC04DBE4F2E +:100D70001A602A683B689A42E6D2BC4B1B681A7814 +:100D8000FF2A00D114E2232A00D0EBE1B94E3378D8 +:100D9000002B06D0B14BB8491B680222D868FFF778 +:100DA0002DFFAD4B1B78532B3CD13B682A689342F7 +:100DB0001ED9AE4801322A609A1AB04B01681B68EE +:100DC00001310160AE4E9A4201D2326000E03360E0 +:100DD000A04832680068049000F0DCFB33682968A2 +:100DE0005A182A60A14A1668F1181160A54A1370B2 +:100DF0002B68013B2B609D4B1A68013A1A60A14B8E +:100E00009E4A1B7811688B420AD222689148C91AFF +:100E1000006892699047002802D0924B64221A80A1 +:100E2000C0468DE1522B0AD18A48944A2368006853 +:100E300011685B69039098476422934B0DE04F2B38 +:100E400005D1844B8D4A1B6812681A7078E1482BD3 +:100E500005D1804B894A1B6812681A8070E1572BB4 +:100E600005D17C4B854A1B6812681A6068E16F2BBC +:100E700003D1784B0121186807E0682B08D1754B26 +:100E80007E481B6802211B880360FFF7D9FE57E1EB +:100E9000772B06D16F4B79481B6804211B680360D0 +:100EA000F3E7472B13D1754B1868FFF709FF774B12 +:100EB0001B6883F3088862B6754B1B78002B00D142 +:100EC0003EE1664B06201B681B68984738E1542BAF +:100ED00004D101233370614B1B6864E04E2B0CD1AD +:100EE0003378002B06D15D4B63491B680222D8681A +:100EF000FFF784FE0023337022E1562B57D123687D +:100F00006449D8680122FFF779FE23686249D868EE +:100F10000322FFF773FE614D2368291CD868012264 +:100F2000FFF76CFE23685E49D8680D22FFF766FE66 +:100F30002368291CD8680122FFF760FE4B4F4C4DF7 +:100F40005849002339602B603A1C281C13685E1C2A +:100F500016601B780593002B03D0036801330360F0 +:100F6000F4E73E4E2A683368D868FFF747FE3368D7 +:100F70004A49D8680122FFF741FE059929604A498C +:100F800039603A4A1368581C10601B78002B04D053 +:100F9000374B1A6801321A60F3E733682A68D86859 +:100FA000FFF72CFE3368D86833490222C6E0334A83 +:100FB000582B17D1244E264D366813682A68B10085 +:100FC00093420AD21F4D5808E861384828801D4DC9 +:100FD000287DC607FBD55B18F2E7204B34491B6818 +:100FE000D868AAE0592B79D112681A4B3149002AE6 +:100FF00002D11B680B606CE0124D086819686B68C1 +:10100000104E8025AB4392087360002A61D02A4BB2 +:101010000C4D2B800B4E337DDD07FBD500230A4D95 +:101020002D680195AD08AB4203D3244D054E3580A4 +:1010300046E09342F9D09D00465901334E51EEE708 +:101040001816000000400041440200203C0200202D +:101050003802002088020020340200208C02002088 +:10106000480200208A0000202C02002030020020CC +:101070004002002088000020781600009402002022 +:1010800098020020280200208C00002090020020FE +:1010900094000020541600007D1600005616000033 +:1010A000A0160000581600006416000002A5FFFFFD +:1010B0006D1600009000002044A5FFFF04A5FFFF6F +:1010C0003F4E357DEE07FBD59D0049194019D21AD8 +:1010D0009BE73C4B3C491B68D8682EE05A2B2FD12C +:1010E0003A4B17681D680026EF19BD4206D02878D4 +:1010F000311C00F013F90135061CF6E7314B344979 +:101100001B680122D868FFF779FD07230F223240C0 +:10111000111C36093031092A00DD07311820C018AA +:101120006A468154013BF1D2236806A9D868082297 +:10113000FFF764FD23682749D8680322FFF75EFDA7 +:10114000254B7A221A70254B00221A60244B1B78FB +:1011500093422DD01B4B23491B680122D868FFF70F +:101160004DFD25E0111C3039C8B21C4B092804D8AC +:101170001D682A01114319601AE0111C4139052923 +:1011800003D81E68373A310106E0111C6139052980 +:1011900004D81868573A01010A4308E02C2A03D101 +:1011A0000A4A1968116001E00B490A7000221A60AE +:1011B0000D4B1A6801321A600C4B1A680132D5E5E2 +:1011C000004000418C0200207116000088020020BF +:1011D00075160000771600003402002094020020EB +:1011E000880000207B160000400200203002002012 +:1011F00010B51C4B01201A78032402431A701A4BB5 +:101200000F221978914319701978214319701749E1 +:101210000C782043087019780A401A701A78302127 +:101220000A431A70124B80211A6A0A431A62114B40 +:10123000114A5A805A7852B2002AFBDBC4220F4866 +:101240000F499203FEF760FF0E4A002313700E4A07 +:1012500013700E4A13700E4A13700E4A13700E4A22 +:10126000137010BDD6440041BB440041D744004137 +:1012700000040040000C004019400000001C004227 +:101280002AF600009C020020230300209D0200207B +:10129000A0020020240300202103002008B5C1B2D1 +:1012A0000248FEF75FFF012008BDC046001C004257 +:1012B000024B187E4007C00F7047C046001C00421A +:1012C00008B5FFF7F5FF0028FBD00248FEF750FFF6 +:1012D00008BDC046001C004208B5FFF7E9FF002327 +:1012E000984205D0FFF7ECFF031C233B5A425341C1 +:1012F000181C08BD70B5041C0D1C4618B44204D05F +:101300002078FFF7CBFF0134F8E7281C70BD10B53B +:10131000041CFFF7D5FF2070012010BD0B0A5840B8 +:10132000034B4000C05A0902484080B27047C04693 +:10133000AE160000F7B50024051C0F1C261CBC428D +:1013400020D0FFF7BDFF114BC0B21B780190002BDE +:101350001AD1311CFFF7E2FF0D4B061C1A88002A38 +:1013600004D10C4A11782A1C002907D001996A1C63 +:101370002970802F02D11988013919800134A4B253 +:10138000151CDCE7301C00E00120FEBD210300201D +:101390009E02002022030020F0B53E4E85B00022C0 +:1013A00003900C1C32703C4B914201D1012201E0B0 +:1013B0003A490C801A707F231C4201D080349C4330 +:1013C000FFF77EFF3378C0B2002B07D000253570C1 +:1013D000FFF776FF3378C0B2AB4236D1432803D053 +:1013E000712853D01528EBD1012300930120FFF77A +:1013F00055FF0098FFF752FF00998025C843C0B2FF +:10140000FFF74CFF039B00270293244A1388002B0D +:101410001DD1214901930978002918D10198FFF7BE +:101420003DFF391C0198FFF779FF013D071C002D96 +:10143000EBD1000AC0B2FFF731FFF8B2FFF72EFF81 +:10144000FFF73EFF3378002B0AD035701FE002997A +:10145000013B09781380029B019101330293DDE780 +:10146000C0B2062807D1009B03990133DBB280315B +:101470000093803C0391002CB8D10420FFF70EFFAD +:10148000FFF71EFF044B01251C7000E00025281CFF +:1014900005B0F0BD21030020220300209E020020A1 +:1014A000F0B5384C87B0002301902370994201D1E8 +:1014B000012301E0344A1180344A6426137043202A +:1014C000FFF7ECFE324FFFF7F3FE002803D1002FA9 +:1014D00003D0013FF7E7002F03D1013E002EEED1EC +:1014E0004DE00125FFF7ECFE2378002B38D1C0B288 +:1014F0000290012805D004283DD10620FFF7CEFE3A +:1015000039E005AE0221301CFFF714FF019880215D +:10151000FFF710FF23780390002B18D1FFF7D0FEC0 +:101520000702FFF7CDFEBFB223783F18BFB2012BF1 +:101530000DD0039B9F4207D13378AB4204D1EB43DC +:101540007278DBB29A4204D01820FFF7A7FE00237E +:1015500003E00620FFF7A2FE029B2278002A02D0B9 +:10156000002626700BE0012B05D1019A6B1C8032FE +:10157000DDB20192B6E7054A002313700126301C44 +:1015800007B0F0BD210300209E02002022030020AE +:1015900000350C0010B50023934203D0CC5CC4543A +:1015A0000133F9E710BD031C8218934202D0197071 +:1015B0000133FAE770470023C25C0133002AFBD1F4 +:1015C000581E7047F8B5C046F8BC08BC9E46704728 +:1015D000F8B5C046F8BC08BC9E4670470403090431 +:1015E00041726475696E6F204C4C430041726475A2 +:1015F000696E6F204D4B5220464F582031323030AB +:1016000000000000120100020200004041235000CF +:1016100000020102000100000800000010000000AC +:1016200020000000400000008000000000010000D9 +:1016300000020000000400009D120000C112000022 +:10164000B1120000F51200000F1300009913000002 +:10165000A114000076002000417072203131203248 +:101660003031390031333A30393A353300580A0DC8 +:1016700000590A0D005A00230A0D003E00322E3098 +:1016800000000000250B0000410B00005D0B000076 +:10169000810B00009D0B0000810B0000C50B0000BA +:1016A0005B41726475696E6F3A58595A5D0000006B +:1016B0002110422063308440A550C660E770088145 +:1016C00029914AA16BB18CC1ADD1CEE1EFF13112BC +:1016D000100273325222B5529442F772D662399395 +:1016E00018837BB35AA3BDD39CC3FFF3DEE362240C +:1016F000433420040114E664C774A44485546AA5E5 +:101700004BB528850995EEE5CFF5ACC58DD553369B +:10171000722611163006D776F6669556B4465BB734 +:101720007AA719973887DFF7FEE79DD7BCC7C4486B +:10173000E5588668A7784008611802282338CCC984 +:10174000EDD98EE9AFF9488969990AA92BB9F55AFB +:10175000D44AB77A966A711A500A333A122AFDDBD4 +:10176000DCCBBFFB9EEB799B588B3BBB1AABA66CCB +:10177000877CE44CC55C222C033C600C411CAEED24 +:101780008FFDECCDCDDD2AAD0BBD688D499D977EDB +:10179000B66ED55EF44E133E322E511E700E9FFF74 +:1017A000BEEFDDDFFCCF1BBF3AAF599F788F88912A +:1017B000A981CAB1EBA10CD12DC14EF16FE180100E +:1017C000A100C230E3200450254046706760B98311 +:1017D0009893FBA3DAB33DC31CD37FE35EF3B1025E +:1017E0009012F322D2323542145277625672EAB521 +:1017F000CBA5A89589856EF54FE52CD50DC5E234AE +:10180000C324A01481046674476424540544DBA7F0 +:10181000FAB79987B8975FE77EF71DC73CD7D326FD +:10182000F2369106B01657667676154634564CD980 +:101830006DC90EF92FE9C899E9898AB9ABA944584D +:10184000654806782768C018E1088238A3287DCB50 +:101850005CDB3FEB1EFBF98BD89BBBAB9ABB754A9D +:10186000545A376A167AF10AD01AB32A923A2EFDE0 +:101870000FED6CDD4DCDAABD8BADE89DC98D267CED +:10188000076C645C454CA23C832CE01CC10C1FEF30 +:101890003EFF5DCF7CDF9BAFBABFD98FF89F176E3D +:1018A000367E554E745E932EB23ED10EF01E000071 +:0418B0000000000034 +:1018B40001140000090243000201008032090400FF +:1018C40000010202000005240010010424020005A6 +:1018D400240600010524010001070583030800FF15 +:1018E40009040100020A000000070581024000000B +:1018F400070502024000000000C2010000000800C9 +:0C1904006900000041000000000000002D +:040000030000060DE6 +:00000001FF diff --git a/bootloaders/mkrgsm1400/samd21_sam_ba_arduino_mkrgsm1400.bin b/bootloaders/mkrgsm1400/samd21_sam_ba_arduino_mkrgsm1400.bin new file mode 100755 index 0000000..5bd1f63 Binary files /dev/null and b/bootloaders/mkrgsm1400/samd21_sam_ba_arduino_mkrgsm1400.bin differ diff --git a/bootloaders/mkrgsm1400/samd21_sam_ba_arduino_mkrgsm1400.hex b/bootloaders/mkrgsm1400/samd21_sam_ba_arduino_mkrgsm1400.hex new file mode 100644 index 0000000..21fdb4e --- /dev/null +++ b/bootloaders/mkrgsm1400/samd21_sam_ba_arduino_mkrgsm1400.hex @@ -0,0 +1,502 @@ +:10000000FC7F0020790B0000690B00006D0B0000E5 +:1000100000000000000000000000000000000000E0 +:10002000000000000000000000000000710B000054 +:100030000000000000000000750B0000CD0C000067 +:1000400010B5064C2378002B07D1054B002B02D0AE +:10005000044800E000BF0123237010BD5C000020B5 +:1000600000000000D01E000008B5084B002B03D094 +:100070000748084900E000BF07480368002B03D089 +:10008000064B002B00D0984708BDC046000000007A +:10009000D01E00006000002058000020000000007A +:1000A000064B0322104002040549586808401043DB +:1000B0005860DA695107FCD47047C0460008004216 +:1000C000FFFFFCFF38B5284A284B5A805A7852B2B5 +:1000D000002AFBDB264B04211A6A264D0A431A62CA +:1000E0002B68012213432B602A680123214C1A42FA +:1000F000FAD1E2691A42F7D11423236041001E4865 +:1001000001F008FD421EE068FF231A4098431043A7 +:10011000E0602368022213432360EA69154B9107CC +:10012000FBD45A8B30218A4310210A435A83EB694E +:1001300001205A07FBD4114B02241A7802431A708B +:100140000F4B0F22197891431970197821431970B8 +:100150000C490C782043087019780A401A701A78F4 +:1001600020210A431A7038BD14400000000C0040E2 +:100170000004004000080042006CDC0248440041DA +:100180003444004149440041F7B500230F1C01925B +:100190001D1C994254D001212A4E4000084333705F +:1001A000C1B2294B0322588B1C1C000910400128A6 +:1001B00004D05B8B1B091A40022AF2D1606AC00A84 +:1001C000C00208436062217E1F4B0122880708D4C9 +:1001D000197E1142F7D05968C02292020A435A6030 +:1001E00003E05B8B9B08134201D0002528E03270AE +:1001F000237E9907FCD5154A154B117801251970F6 +:100200006268BD4212D0134B022013406360FFF7B7 +:1002100047FF33785A1C3270227E9007FCD50B4979 +:100220000B480A780135C254EDB2E9E78023DB02BE +:10023000134363600199002902D00320FFF730FFC8 +:10024000281CFEBD7800002000080042280800425B +:1002500099000020FFFFFBFF024B00221870024BA9 +:100260001A7070477A00002079000020F8B5274BFB +:100270001C786400E4B2264B03215D8B1A1C2D0907 +:100280000D40012D04D05B8B1B0919400229F2D1CE +:10029000536ADB0ADB0223435362117E01231942B6 +:1002A000FBD01B49498B8908194204D00320FFF772 +:1002B000F7FE022427E017490D782B1C002B11D0E4 +:1002C000154EEC1A365D154C2670114E177E012422 +:1002D000768B274202D12642F7D00BE0B6082642A1 +:1002E0000ED007E00B701C1C00280CD00320FFF779 +:1002F000D7FE08E003200B700324FFF7D1FE02E0D5 +:10030000013BDBB2DAE7201CF8BDC0467A000020D2 +:1003100000080042790000207B00002028080042ED +:10032000034A1378591C1170024AD05401207047B7 +:10033000790000207B000020154A164B1178002917 +:1003400009D11549187809784118C9B21970802067 +:1003500012494003C86111780131C9B2117019788E +:10036000F02902D81978092909D80B4908784042A0 +:10037000C0B20870187809784118C9B2197012789B +:100380001B789A4203D18022044B5203DA617047F2 +:100390007D000020010000200000002000440041FA +:1003A00010B5041C6B20FFF757FF201CFFF7B8FFA8 +:1003B0000120FFF75BFF01210A1C6B20FFF7E4FE21 +:1003C000014B187810BDC0469900002038B5051CB7 +:1003D0006B200C1CFFF740FF281CFFF7A1FF201C1F +:1003E000FFF79EFF0120FFF741FF022038BD08B54F +:1003F0000520FFF7D5FFCE23011C19400520FFF78C +:10040000E5FF012008BD000010B5041C0020FFF727 +:10041000C7FF78232D4A9843C1B2944242D018D8DE +:100420002B4B9C4238D009D82A4B9C4230D02A4BC7 +:100430009C422FD0294B9C4245D13FE0284B9C4207 +:100440002CD0284B9C422BD0274B9C423BD12023C5 +:1004500033E0264A94422BD00AD8254B9C4223D025 +:10046000244B9C4222D0244B9C422CD1402324E09C +:10047000224A94421ED004D8214B9C4223D16023AF +:100480001BE0204A944217D01F4A944215D01AE02C +:10049000082312E0102310E018230EE028230CE0BC +:1004A00030230AE0382308E0482306E0502304E024 +:1004B000582302E0682300E0702319430020FFF76F +:1004C00085FF012000E0002010BDC046581100004B +:1004D00018100000780F0000C80F0000280F00005F +:1004E000B810000008110000681000009812000009 +:1004F000F811000048120000A81100003813000095 +:10050000E812000088130000D813000010B5041C86 +:100510000020FFF745FF07239843E122C1B2920074 +:10052000944220D008D8962C18D0FA235B009C4225 +:1005300017D0642C22D11CE0114A944215D005D862 +:100540009623DB009C4219D1042311E0FA22D20049 +:1005500094420CD00B4A94420AD00FE0012421436C +:1005600007E0022304E0032302E0052300E0062362 +:1005700019430020FFF72AFF012000E0002010BDF2 +:10058000DC050000B80B000070B504AC267805ACA3 +:100590002578441EA041C401002901D040210C430C +:1005A000002A01D020221443002B01D010231C4329 +:1005B000002E01D008231C43002D01D004231C432E +:1005C0000220FFF7EDFE0125011C294021430220F6 +:1005D000FFF7FCFE281C70BD10B5041C0420FFF7BB +:1005E000DFFE03231840084B9C4204D0074B9C427B +:1005F00008D1B02100E0982101430420FFF7E6FE76 +:10060000012000E0002010BD10100000701000005C +:1006100008B50120FFF7C4FECF23011C19400120BB +:10062000FFF7D4FE012008BD07B5FFF7E0FEFFF796 +:10063000EFFF0948FFF7E8FEFA20C000FFF766FF6A +:10064000002300930193181C191C1A1CFFF79CFF30 +:100650000248FFF7C1FF07BD08110000101000009D +:1006600008B50348FFF72EFDFFF7DEFF08BDC046C3 +:10067000A086010010B5C3699C07FCD4036802245E +:10068000A3430360C46901231C42FBD104682343D4 +:1006900003600368DC07FCD4C46901231C42FBD15E +:1006A000C469DC401C42F7D1084B1A430260C3699D +:1006B0005A07FCD4C0239B0243608181C3699C0715 +:1006C000FCD4036802221343036010BD0400004001 +:1006D000037EDA07FCD5018570470000027E012306 +:1006E0005107FBD5428B1A4207D1428BDA401A429E +:1006F00003D1428B92081A4202D0034B01221A7096 +:10070000008DC0B27047C0467E00002070B50368FF +:10071000041C988B1A1C0821FF32084226D0802026 +:1007200099839872112353704021144B9171507129 +:100730005E68134DC0202E40800506435E605E69F2 +:100740003540284358610F4818600F4818615D68AC +:100750000E4828408025AD02284358605868800B19 +:100760008003586000235171237105E0137ADA0683 +:1007700002D5201C00F0E4FA207970BD9C01002015 +:10078000FFFFFF8F9C0000201C010020FF3F00F0B6 +:10079000002303714371044B016083600B780222D4 +:1007A00013430B707047C0460D07000038B5364B39 +:1007B0002021DA6901200A43DA61344B06241A78D1 +:1007C00002431A70324B0F2219789143197019782D +:1007D000214319702F490C782043087019780A407A +:1007E0001A701A7860210A431A702B4B2B4A5A80D0 +:1007F0005A7852B2002AFBDB294B01211A780A43AE +:100800001A709A78D107FCD426480268510B1F222F +:100810001140914200D1052111408C011D8D2249CA +:100820002940214319850468A10C0A401F2A00D1E0 +:100830001D221C8D1F210A408C4322431A85026809 +:100840000721D20D0A408A4200D103220A40188DA6 +:100850001103164A02400A431A8519787F220A407A +:100860001A701A78042112480A431A7058621A89B9 +:100870000C218A431A811A8901218A431A81002195 +:10088000802201F0A0F938BD000400405844004126 +:100890003C44004159440041000C00400640000027 +:1008A00000500041246080003FF8FFFFFF8FFFFFF2 +:1008B0009C010020F7B5141C1F4A5F0101971D1C05 +:1008C000D319061C5869271C4000400F0330103311 +:1008D000C74006D00F1C8022596812060A435A608E +:1008E00009E02F1C7B1E9F41144BBF01FF18381CD1 +:1008F000221C01F05FF901990F4808354218176171 +:10090000131C5269A104920B890C92030A435A6189 +:1009100059690B4A0A405A616B01F3180222DA71D5 +:100920005979802252420A435A716B01F318DB79DC +:100930009A07FAD5201CFEBD9C0100201C01002056 +:10094000FF3F00F0F8B51A4E051C3378141C002B3D +:1009500012D1184B184A1A645A6C920B92035A64BB +:10096000586C164A02405A64A2235B00EA5C40209D +:100970000243EA54012333704827FF37EA5D01231D +:10098000134012D00B4B5A6C9204920CA24202D22A +:100990005C6CA404A40C081C221C074901F00AF991 +:1009A0000123EB550023337000E01C1C201CF8BD14 +:1009B0007F0000209C010020DC000020FF3F00F0B1 +:1009C000FF3083792022002900D110221343837144 +:1009D00070470000084BFF305A69920B92035A612E +:1009E00002230372827980235B4213438371037A6B +:1009F0009A07FCD57047C0469C01002080235B42CB +:100A00001943C9B28172704770B5A02303225B00FD +:100A1000C254134B134A5C6CC021144089050C432B +:100A200046255C64FF35402444550F4D30261D6437 +:100A300090256D0046555D6B1540294392255963FD +:100A40006D0080214155094D1D63B0256D00445551 +:100A50005C6F22405A67B2235B00C15470BDC04630 +:100A60009C010020FFFFFF8FDC0000205C010020C4 +:100A7000024B5B785BB2002BFADB7047000C004046 +:100A8000024BDB68DA06FBD57047C0460008004021 +:100A9000F8B52A4B1E22596891430222114359602E +:100AA000274B28491E1C9982998A0A439A82F36827 +:100AB0000227234C3B42FAD0234D0123AB60FFF7C2 +:100AC000D7FF224B6B60FFF7D3FF8223DB016B80E4 +:100AD000FFF7CEFFA38C80229343A384FFF7D0FFC0 +:100AE0001B4BE362FFF7CCFFA38C1A4A1343A3848A +:100AF000FFF7C6FFA38C1F43A784F3681A06FCD533 +:100B00000F4BDB685A06F8D50024FFF7B9FFAC603D +:100B1000FFF7AEFF104B6B60FFF7AAFF0F4B104AB9 +:100B2000C0215A600F4A0906106A0002000A0143F8 +:100B3000116207229C601A60F8BDC0460040004167 +:100B4000000800400C060000000C004001050100F8 +:100B5000B805FF7D040A00000007030010E000E074 +:100B6000E703000000ED00E00EBEFEE70DBEFEE76D +:100B700005BEFEE702BEFEE70E4A0F4838B58242C8 +:100B800004D10E4A0E4B93420ED10AE00D4C944212 +:100B9000F7D00023D1188842F3D9E55804330D600B +:100BA000F8E700F011F804E09342FAD2002102C302 +:100BB000FAE7FEE7000000205C000020AC03002004 +:100BC0005C000020D41E000038B5344D2B68013382 +:100BD0001AD0334B2A1D1A60EAB2002A14D1314BC5 +:100BE000197801231940304B0AD118682F4A9042D6 +:100BF00001D1196008E01A602D4A013A002AFCD19F +:100C00001A602C4B01221A70FFF742FF62B6FFF701 +:100C100027FD284B284C1B78002B0AD02B6883F328 +:100C200008881E4BFF229343A3601D4B1B681B6863 +:100C3000184700F09DFD00F04FF8204B8022520332 +:100C40009A601F4B1F4A051C5A60216AC022090284 +:100C5000090A12060A43226200229A6007221A60D9 +:100C6000AB68281C9847184B002801D001221A7045 +:100C70001A78002A05D0002000F08CFA00F004FB5E +:100C8000FCE71B78002BEBD100F0E6FD0028E7D055 +:100C9000012000F07FFA00F0F7FAFCE700200000E6 +:100CA0001C02002038040040FC7F002035817307BF +:100CB00048E801008000002000ED00E00044004111 +:100CC00010E000E0E70300008100002008B5FFF716 +:100CD00033FB00F0C3FA08BD10B5054B054C23608B +:100CE000FFF764FD201C2168FFF752FD201C10BD9A +:100CF000005000412002002070B5051CC0B0081C47 +:100D0000161C0C1C00F067FF40006A4603230230EB +:100D10005370107076080123E218013A11785A00D6 +:100D2000002906D1281C69460023FFF7C3FD40B007 +:100D300070BDB342F6DA684681520133ECE7000039 +:100D4000F7B5BA4A04681378B949271CFF37051C60 +:100D5000102038720B705378B648B74E03709378F2 +:100D60003380D178338809020B4333801179B34B38 +:100D70001980517918880902084318809079B04980 +:100D80000880D2790888120202430A8040227A71D0 +:100D9000A84F3A78A64F120238780F1C0243A94890 +:100DA0008446181C624500D1C2E020DC8021490045 +:100DB0008A4200D16EE109DC812A00D192E0822AC8 +:100DC00000D195E0802A00D064E18BE081235B00B4 +:100DD0009A4200D1CFE000DA58E1C0239B009A424A +:100DE00000D157E1984B9A4200D14FE152E1902354 +:100DF0001B019A4269D015DCD023DB009A4222D035 +:100E000088231B019A4269D0A023DB009A4200D0BC +:100E100040E1201CFFF7DEFD3188286889B2FFF72A +:100E2000EDFD3BE1894B9A4200D12FE100DC31E13D +:100E3000874B9A4200D11DE1864B9A4200D029E1AE +:100E400033886B7122E133881B0A012B08D10B8890 +:100E500012222868934201D80A8892B27E4911E191 +:100E600033881B0A022B08D10B884322286893423F +:100E700001D80A8892B2794904E133881B0A032B0E +:100E800000D007E13388DBB2012B17D0002B07D04D +:100E9000022B00D0FEE00A882868D2B2704911E027 +:100EA000042201A86F4900F085FE3B8804222868CF +:100EB000934201D83A8892B201A9E3E00A882868EF +:100EC0006949D2B2FFF718FFE8E03388201C2B7184 +:100ED000FFF780FD201CFFF797FDDFE0291C01C90B +:100EE0000122CFE0614900230B8028680222CAE07A +:100EF0005E4900220A801888502210405C4A107017 +:100F00001E880F20304018801888032800D9C1E0BF +:100F100012781B8808335B01E418A379002A01D0FA +:100F20009B0600E0DB06DB0F0B8028680222A9E0AD +:100F300019887F2291434E4AC9B2117018880F2137 +:100F4000014019803188002900D0A3E019880029C8 +:100F500000D19FE01988032900D99BE012781B88F3 +:100F600008335B01E318002A02D020225A718DE079 +:100F7000102159718AE002887F239A433C4BD2B2F8 +:100F80001A7001880F220A4002803288002A00D09D +:100F900080E00288002A00D17CE00288032A00D980 +:100FA00078E01B78002B1FD0038808335B01E3181F +:100FB0009B799A066AD50388202208335B01E318DF +:100FC0001A71038808335B01E318DB795F065DD58E +:100FD0000388402208335B01E318DA710388022298 +:100FE00008335B01E3181EE0038808335B01E31854 +:100FF0009B79D9064AD50388102208335B01E31890 +:101000001A71038808335B01E318DB799A063DD532 +:101010000388202208335B01E318DA710388012278 +:1010200008335B01E3181A7130E0C0469C000020D1 +:1010300083000020880000208A0000208C0000200F +:1010400086000020020300000103000021200000B0 +:10105000A121000021220000241C00000400002027 +:101060000C1C0000FC1B0000001C00008400002081 +:10107000820000200B8808222868934201D80A8841 +:1010800092B207490023FFF715FC07E0201CFFF789 +:10109000A1FC03E0201C0121FFF792FCF7BDC04634 +:1010A0004800002007B5054B0122019001A91868EE +:1010B000131CFFF7FFFB01200EBDC04620020020DD +:1010C00013B5054B6C4607341868211C0122FFF745 +:1010D00039FC207816BDC0462002002010B5074C10 +:1010E000201CFFF713FB031C0020834205D022685D +:1010F0004823FF33D05C0123184010BD200200209C +:1011000010B5054A0C1C031C191C10680123221C75 +:10111000FFF7D0FB201C10BD2002002070B5084C4A +:10112000061C201C0D1CFFF7F1FA0023984205D085 +:101130002068311C2A1CFFF705FC031C181C70BD1D +:1011400020020020F8B50C4C051C201C0E1CFFF7DB +:10115000DDFA0023271C341C98420AD0002C07D04B +:10116000291C221C3868FFF7EDFB241A2D18F5E71F +:10117000331C181CF8BDC0462002002008B5031C13 +:10118000081C111C9847024B64221A8008BDC046F7 +:1011900092000020012805D1054B064A1A60064B33 +:1011A000187004E0002802D1044A014B1A6070470D +:1011B00090020020581C000098000020A41C000091 +:1011C00030B50A1C1C4985B00978031C00292AD0B7 +:1011D000042A01D1006804E0022A01D1008800E05D +:1011E0000078520004A98B180B3B9C1AA3420BD029 +:1011F0000F210140092902D83025294300E0373169 +:1012000019700009013BF1E701A930230B70782325 +:101210004B700A208B1898700D20D870074B043241 +:101220001B68D86803E005490968C868191CFFF7FE +:10123000A5FF05B030BDC0468E0000209002002002 +:1012400072B6EFF30883044A1360036883F30888D7 +:10125000436818477047C04694020020084B1A881C +:10126000002A03D01A88013A92B21A80054B1A88D4 +:10127000002A03D01A88013A92B21A807047C046F9 +:101280009200002090000020F0B591B008A9CC4A4F +:101290000B1C31CA31C351CA51C360CA60C3C94BA8 +:1012A000C9489A687A255203520F92005258C7498A +:1012B00002609C68A4B262430C60C54900240A60C5 +:1012C000C44A1460C44C2570C44CC54D2368281C06 +:1012D0001B6940219847002802D0C24B64221A8023 +:1012E000C14B00221860C14B1D60C14BC04DBE4FA9 +:1012F0001A602A683B689A42E6D2BC4B1B681A788F +:10130000FF2A00D114E2232A00D0EBE1B94E337852 +:10131000002B06D0B14BB8491B680222D868FFF7F2 +:101320002DFFAD4B1B78532B3CD13B682A68934271 +:101330001ED9AE4801322A609A1AB04B01681B6868 +:1013400001310160AE4E9A4201D2326000E033605A +:10135000A04832680068049000F02CFC33682968CB +:101360005A182A60A14A1668F1181160A54A13702C +:101370002B68013B2B609D4B1A68013A1A60A14B08 +:101380009E4A1B7811688B420AD222689148C91A7A +:10139000006892699047002802D0924B64221A801C +:1013A000C0468DE1522B0AD18A48944A23680068CE +:1013B00011685B69039098476422934B0DE04F2BB3 +:1013C00005D1844B8D4A1B6812681A7078E1482B4E +:1013D00005D1804B894A1B6812681A8070E1572B2F +:1013E00005D17C4B854A1B6812681A6068E16F2B37 +:1013F00003D1784B0121186807E0682B08D1754BA1 +:101400007E481B6802211B880360FFF7D9FE57E165 +:10141000772B06D16F4B79481B6804211B6803604A +:10142000F3E7472B13D1754B1868FFF709FF774B8C +:101430001B6883F3088862B6754B1B78002B00D1BC +:101440003EE1664B06201B681B68984738E1542B29 +:1014500004D101233370614B1B6864E04E2B0CD127 +:101460003378002B06D15D4B63491B680222D86894 +:10147000FFF784FE0023337022E1562B57D12368F7 +:101480006449D8680122FFF779FE23686249D86869 +:101490000322FFF773FE614D2368291CD8680122DF +:1014A000FFF76CFE23685E49D8680D22FFF766FEE1 +:1014B0002368291CD8680122FFF760FE4B4F4C4D72 +:1014C0005849002339602B603A1C281C13685E1CA5 +:1014D00016601B780593002B03D00368013303606B +:1014E000F4E73E4E2A683368D868FFF747FE336852 +:1014F0004A49D8680122FFF741FE059929604A4907 +:1015000039603A4A1368581C10601B78002B04D0CD +:10151000374B1A6801321A60F3E733682A68D868D3 +:10152000FFF72CFE3368D86833490222C6E0334AFD +:10153000582B17D1244E264D366813682A68B100FF +:1015400093420AD21F4D5808E861384828801D4D43 +:10155000287DC607FBD55B18F2E7204B34491B6892 +:10156000D868AAE0592B79D112681A4B3149002A60 +:1015700002D11B680B606CE0124D086819686B683B +:10158000104E8025AB4392087360002A61D02A4B2D +:101590000C4D2B800B4E337DDD07FBD500230A4D10 +:1015A0002D680195AD08AB4203D3244D054E35801F +:1015B00046E09342F9D09D00465901334E51EEE783 +:1015C000381C00000040004148020020400200207A +:1015D0003C0200208C0200203802002090020020F3 +:1015E0004C02002090000020300200203402002035 +:1015F000440200208E000020981C00009802002069 +:101600009C0200202C020020920000209402002066 +:1016100098000020741C00009D1C0000761C000037 +:10162000C01C0000781C0000841C000002A5FFFF05 +:101630008D1C00009400002044A5FFFF04A5FFFFBF +:101640003F4E357DEE07FBD59D0049194019D21A52 +:101650009BE73C4B3C491B68D8682EE05A2B2FD1A6 +:101660003A4B17681D680026EF19BD4206D028784E +:10167000311C00F013F90135061CF6E7314B3449F3 +:101680001B680122D868FFF779FD07230F2232403B +:10169000111C36093031092A00DD07311820C01825 +:1016A0006A468154013BF1D2236806A9D868082212 +:1016B000FFF764FD23682749D8680322FFF75EFD22 +:1016C000254B7A221A70254B00221A60244B1B7876 +:1016D00093422DD01B4B23491B680122D868FFF78A +:1016E0004DFD25E0111C3039C8B21C4B092804D827 +:1016F0001D682A01114319601AE0111C413905299E +:1017000003D81E68373A310106E0111C61390529FA +:1017100004D81868573A01010A4308E02C2A03D17B +:101720000A4A1968116001E00B490A7000221A6028 +:101730000D4B1A6801321A600C4B1A680132D5E55C +:101740000040004190020020911C00008C0200200B +:10175000951C0000971C0000380200209802002011 +:101760008E0000209B1C0000440200203402002058 +:1017700010B51C4B01201A78032402431A701A4B2F +:101780000F2219789143197019782143197017495C +:101790000C782043087019780A401A701A783021A2 +:1017A0000A431A70124B80211A6A0A431A62114BBB +:1017B000114A5A805A7852B2002AFBDBC4220F48E1 +:1017C0000F499203FEF756FF0E4A002313700E4A8C +:1017D00013700E4A13700E4A13700E4A13700E4A9D +:1017E000137010BDD6440041BB440041D7440041B2 +:1017F00000040040000C004019400000001C0042A2 +:101800002AF60000A002002027030020A1020020E9 +:10181000A4020020280300202503002008B5C1B23F +:101820000248FEF755FF012008BDC046001C0042DB +:10183000024B187E4007C00F7047C046001C004294 +:1018400008B5FFF7F5FF0028FBD00248FEF746FF7A +:1018500008BDC046001C004208B5FFF7E9FF0023A1 +:10186000984205D0FFF7ECFF031C233B5A4253413B +:10187000181C08BD70B5041C0D1C4618B44204D0D9 +:101880002078FFF7CBFF0134F8E7281C70BD10B5B6 +:10189000041CFFF7D5FF2070012010BD0B0A584033 +:1018A000034B4000C05A0902484080B27047C0460E +:1018B000CE1C0000F7B50024051C0F1C261CBC42E2 +:1018C00020D0FFF7BDFF114BC0B21B780190002B59 +:1018D0001AD1311CFFF7E2FF0D4B061C1A88002AB3 +:1018E00004D10C4A11782A1C002907D001996A1CDE +:1018F0002970802F02D11988013919800134A4B2CE +:10190000151CDCE7301C00E00120FEBD2503002093 +:10191000A202002026030020F0B53E4E85B0002232 +:1019200003900C1C32703C4B914201D1012201E02A +:101930003A490C801A707F231C4201D080349C43AA +:10194000FFF77EFF3378C0B2002B07D0002535703B +:10195000FFF776FF3378C0B2AB4236D1432803D0CD +:10196000712853D01528EBD1012300930120FFF7F4 +:1019700055FF0098FFF752FF00998025C843C0B279 +:10198000FFF74CFF039B00270293244A1388002B88 +:101990001DD1214901930978002918D10198FFF739 +:1019A0003DFF391C0198FFF779FF013D071C002D11 +:1019B000EBD1000AC0B2FFF731FFF8B2FFF72EFFFC +:1019C000FFF73EFF3378002B0AD035701FE00299F5 +:1019D000013B09781380029B019101330293DDE7FB +:1019E000C0B2062807D1009B03990133DBB28031D6 +:1019F0000093803C0391002CB8D10420FFF70EFF28 +:101A0000FFF71EFF044B01251C7000E00025281C79 +:101A100005B0F0BD2503002026030020A20200200F +:101A2000F0B5384C87B0002301902370994201D162 +:101A3000012301E0344A1180344A642613704320A4 +:101A4000FFF7ECFE324FFFF7F3FE002803D1002F23 +:101A500003D0013FF7E7002F03D1013E002EEED166 +:101A60004DE00125FFF7ECFE2378002B38D1C0B202 +:101A70000290012805D004283DD10620FFF7CEFEB4 +:101A800039E005AE0221301CFFF714FF01988021D8 +:101A9000FFF710FF23780390002B18D1FFF7D0FE3B +:101AA0000702FFF7CDFEBFB223783F18BFB2012B6C +:101AB0000DD0039B9F4207D13378AB4204D1EB4357 +:101AC0007278DBB29A4204D01820FFF7A7FE0023F9 +:101AD00003E00620FFF7A2FE029B2278002A02D034 +:101AE000002626700BE0012B05D1019A6B1C803279 +:101AF000DDB20192B6E7054A002313700126301CBF +:101B000007B0F0BD25030020A2020020260300201C +:101B100000350C00002934D00123002210B4884283 +:101B20002CD301242407A14204D2814202D209010C +:101B30001B01F8E7E400A14204D2814202D249002D +:101B40005B00F8E7884201D3401A1A434C08A042D0 +:101B500002D3001B5C0822438C08A04202D3001B66 +:101B60009C082243CC08A04202D3001BDC0822437D +:101B7000002803D01B0901D00909E3E7101C10BCA1 +:101B80007047002801D00020C04307B4024802A1DA +:101B90004018029003BDC046190000000029F0D093 +:101BA00003B5FFF7B9FF0EBC4243891A1847C04678 +:101BB0007047C04610B50023934203D0CC5CC45498 +:101BC0000133F9E710BD031C8218934202D019704B +:101BD0000133FAE770470023C25C0133002AFBD1CE +:101BE000581E7047F8B5C046F8BC08BC9E46704702 +:101BF000F8B5C046F8BC08BC9E467047040309040B +:101C000041726475696E6F204C4C4300417264757B +:101C1000696E6F204D4B522047534D203134303088 +:101C200000000000120100020200004041235200A7 +:101C30000002010200010000080000001000000086 +:101C400020000000400000008000000000010000B3 +:101C500000020000000400001D18000041180000F0 +:101C600031180000751800008F18000019190000C5 +:101C7000211A00007600200041707220313120329C +:101C80003031390031333A30393A353400580A0DA1 +:101C900000590A0D005A00230A0D003E00322E3072 +:101CA00000000000A5100000C1100000DD100000C1 +:101CB000011100001D11000001110000451100007C +:101CC0005B41726475696E6F3A58595A5D00000045 +:101CD0002110422063308440A550C660E77008811F +:101CE00029914AA16BB18CC1ADD1CEE1EFF1311296 +:101CF000100273325222B5529442F772D66239936F +:101D000018837BB35AA3BDD39CC3FFF3DEE36224E5 +:101D1000433420040114E664C774A44485546AA5BE +:101D20004BB528850995EEE5CFF5ACC58DD5533675 +:101D3000722611163006D776F6669556B4465BB70E +:101D40007AA719973887DFF7FEE79DD7BCC7C44845 +:101D5000E5588668A7784008611802282338CCC95E +:101D6000EDD98EE9AFF9488969990AA92BB9F55AD5 +:101D7000D44AB77A966A711A500A333A122AFDDBAE +:101D8000DCCBBFFB9EEB799B588B3BBB1AABA66CA5 +:101D9000877CE44CC55C222C033C600C411CAEEDFE +:101DA0008FFDECCDCDDD2AAD0BBD688D499D977EB5 +:101DB000B66ED55EF44E133E322E511E700E9FFF4E +:101DC000BEEFDDDFFCCF1BBF3AAF599F788F889104 +:101DD000A981CAB1EBA10CD12DC14EF16FE18010E8 +:101DE000A100C230E3200450254046706760B983EB +:101DF0009893FBA3DAB33DC31CD37FE35EF3B10238 +:101E00009012F322D2323542145277625672EAB5FA +:101E1000CBA5A89589856EF54FE52CD50DC5E23487 +:101E2000C324A01481046674476424540544DBA7CA +:101E3000FAB79987B8975FE77EF71DC73CD7D326D7 +:101E4000F2369106B01657667676154634564CD95A +:101E50006DC90EF92FE9C899E9898AB9ABA9445827 +:101E6000654806782768C018E1088238A3287DCB2A +:101E70005CDB3FEB1EFBF98BD89BBBAB9ABB754A77 +:101E8000545A376A167AF10AD01AB32A923A2EFDBA +:101E90000FED6CDD4DCDAABD8BADE89DC98D267CC7 +:101EA000076C645C454CA23C832CE01CC10C1FEF0A +:101EB0003EFF5DCF7CDF9BAFBABFD98FF89F176E17 +:101EC000367E554E745E932EB23ED10EF01E00004B +:041ED000000000000E +:101ED40001140000090243000201008032090400D9 +:101EE4000001020200000524001001042402000580 +:101EF400240600010524010001070583030800FFEF +:101F040009040100020A00000007058102400000E4 +:101F1400070502024000000000C2010000000800A2 +:0C1F240069000000410000000000000007 +:0400000300000B7975 +:00000001FF diff --git a/bootloaders/mkrnb1500/samd21_sam_ba_arduino_mkrnb1500.bin b/bootloaders/mkrnb1500/samd21_sam_ba_arduino_mkrnb1500.bin new file mode 100755 index 0000000..ca66efe Binary files /dev/null and b/bootloaders/mkrnb1500/samd21_sam_ba_arduino_mkrnb1500.bin differ diff --git a/bootloaders/mkrnb1500/samd21_sam_ba_arduino_mkrnb1500.hex b/bootloaders/mkrnb1500/samd21_sam_ba_arduino_mkrnb1500.hex new file mode 100644 index 0000000..0f1612a --- /dev/null +++ b/bootloaders/mkrnb1500/samd21_sam_ba_arduino_mkrnb1500.hex @@ -0,0 +1,501 @@ +:10000000FC7F0020790B0000690B00006D0B0000E5 +:1000100000000000000000000000000000000000E0 +:10002000000000000000000000000000710B000054 +:100030000000000000000000750B0000CD0C000067 +:1000400010B5064C2378002B07D1054B002B02D0AE +:10005000044800E000BF0123237010BD5C000020B5 +:1000600000000000CC1E000008B5084B002B03D098 +:100070000748084900E000BF07480368002B03D089 +:10008000064B002B00D0984708BDC046000000007A +:10009000CC1E00006000002058000020000000007E +:1000A000064B0322104002040549586808401043DB +:1000B0005860DA695107FCD47047C0460008004216 +:1000C000FFFFFCFF38B5284A284B5A805A7852B2B5 +:1000D000002AFBDB264B04211A6A264D0A431A62CA +:1000E0002B68012213432B602A680123214C1A42FA +:1000F000FAD1E2691A42F7D11423236041001E4865 +:1001000001F008FD421EE068FF231A4098431043A7 +:10011000E0602368022213432360EA69154B9107CC +:10012000FBD45A8B30218A4310210A435A83EB694E +:1001300001205A07FBD4114B02241A7802431A708B +:100140000F4B0F22197891431970197821431970B8 +:100150000C490C782043087019780A401A701A78F4 +:1001600020210A431A7038BD14400000000C0040E2 +:100170000004004000080042006CDC0248440041DA +:100180003444004149440041F7B500230F1C01925B +:100190001D1C994254D001212A4E4000084333705F +:1001A000C1B2294B0322588B1C1C000910400128A6 +:1001B00004D05B8B1B091A40022AF2D1606AC00A84 +:1001C000C00208436062217E1F4B0122880708D4C9 +:1001D000197E1142F7D05968C02292020A435A6030 +:1001E00003E05B8B9B08134201D0002528E03270AE +:1001F000237E9907FCD5154A154B117801251970F6 +:100200006268BD4212D0134B022013406360FFF7B7 +:1002100047FF33785A1C3270227E9007FCD50B4979 +:100220000B480A780135C254EDB2E9E78023DB02BE +:10023000134363600199002902D00320FFF730FFC8 +:10024000281CFEBD7800002000080042280800425B +:1002500099000020FFFFFBFF024B00221870024BA9 +:100260001A7070477A00002079000020F8B5274BFB +:100270001C786400E4B2264B03215D8B1A1C2D0907 +:100280000D40012D04D05B8B1B0919400229F2D1CE +:10029000536ADB0ADB0223435362117E01231942B6 +:1002A000FBD01B49498B8908194204D00320FFF772 +:1002B000F7FE022427E017490D782B1C002B11D0E4 +:1002C000154EEC1A365D154C2670114E177E012422 +:1002D000768B274202D12642F7D00BE0B6082642A1 +:1002E0000ED007E00B701C1C00280CD00320FFF779 +:1002F000D7FE08E003200B700324FFF7D1FE02E0D5 +:10030000013BDBB2DAE7201CF8BDC0467A000020D2 +:1003100000080042790000207B00002028080042ED +:10032000034A1378591C1170024AD05401207047B7 +:10033000790000207B000020154A164B1178002917 +:1003400009D11549187809784118C9B21970802067 +:1003500012494003C86111780131C9B2117019788E +:10036000F02902D81978092909D80B4908784042A0 +:10037000C0B20870187809784118C9B2197012789B +:100380001B789A4203D18022044B5203DA617047F2 +:100390007D000020010000200000002000440041FA +:1003A00010B5041C6B20FFF757FF201CFFF7B8FFA8 +:1003B0000120FFF75BFF01210A1C6B20FFF7E4FE21 +:1003C000014B187810BDC0469900002038B5051CB7 +:1003D0006B200C1CFFF740FF281CFFF7A1FF201C1F +:1003E000FFF79EFF0120FFF741FF022038BD08B54F +:1003F0000520FFF7D5FFCE23011C19400520FFF78C +:10040000E5FF012008BD000010B5041C0020FFF727 +:10041000C7FF78232D4A9843C1B2944242D018D8DE +:100420002B4B9C4238D009D82A4B9C4230D02A4BC7 +:100430009C422FD0294B9C4245D13FE0284B9C4207 +:100440002CD0284B9C422BD0274B9C423BD12023C5 +:1004500033E0264A94422BD00AD8254B9C4223D025 +:10046000244B9C4222D0244B9C422CD1402324E09C +:10047000224A94421ED004D8214B9C4223D16023AF +:100480001BE0204A944217D01F4A944215D01AE02C +:10049000082312E0102310E018230EE028230CE0BC +:1004A00030230AE0382308E0482306E0502304E024 +:1004B000582302E0682300E0702319430020FFF76F +:1004C00085FF012000E0002010BDC046581100004B +:1004D00018100000780F0000C80F0000280F00005F +:1004E000B810000008110000681000009812000009 +:1004F000F811000048120000A81100003813000095 +:10050000E812000088130000D813000010B5041C86 +:100510000020FFF745FF07239843E122C1B2920074 +:10052000944220D008D8962C18D0FA235B009C4225 +:1005300017D0642C22D11CE0114A944215D005D862 +:100540009623DB009C4219D1042311E0FA22D20049 +:1005500094420CD00B4A94420AD00FE0012421436C +:1005600007E0022304E0032302E0052300E0062362 +:1005700019430020FFF72AFF012000E0002010BDF2 +:10058000DC050000B80B000070B504AC267805ACA3 +:100590002578441EA041C401002901D040210C430C +:1005A000002A01D020221443002B01D010231C4329 +:1005B000002E01D008231C43002D01D004231C432E +:1005C0000220FFF7EDFE0125011C294021430220F6 +:1005D000FFF7FCFE281C70BD10B5041C0420FFF7BB +:1005E000DFFE03231840084B9C4204D0074B9C427B +:1005F00008D1B02100E0982101430420FFF7E6FE76 +:10060000012000E0002010BD10100000701000005C +:1006100008B50120FFF7C4FECF23011C19400120BB +:10062000FFF7D4FE012008BD07B5FFF7E0FEFFF796 +:10063000EFFF0948FFF7E8FEFA20C000FFF766FF6A +:10064000002300930193181C191C1A1CFFF79CFF30 +:100650000248FFF7C1FF07BD08110000101000009D +:1006600008B50348FFF72EFDFFF7DEFF08BDC046C3 +:10067000A086010010B5C3699C07FCD4036802245E +:10068000A3430360C46901231C42FBD104682343D4 +:1006900003600368DC07FCD4C46901231C42FBD15E +:1006A000C469DC401C42F7D1084B1A430260C3699D +:1006B0005A07FCD4C0239B0243608181C3699C0715 +:1006C000FCD4036802221343036010BD0400004001 +:1006D000037EDA07FCD5018570470000027E012306 +:1006E0005107FBD5428B1A4207D1428BDA401A429E +:1006F00003D1428B92081A4202D0034B01221A7096 +:10070000008DC0B27047C0467E00002070B50368FF +:10071000041C988B1A1C0821FF32084226D0802026 +:1007200099839872112353704021144B9171507129 +:100730005E68134DC0202E40800506435E605E69F2 +:100740003540284358610F4818600F4818615D68AC +:100750000E4828408025AD02284358605868800B19 +:100760008003586000235171237105E0137ADA0683 +:1007700002D5201C00F0E4FA207970BD9C01002015 +:10078000FFFFFF8F9C0000201C010020FF3F00F0B6 +:10079000002303714371044B016083600B780222D4 +:1007A00013430B707047C0460D07000038B5364B39 +:1007B0002021DA6901200A43DA61344B06241A78D1 +:1007C00002431A70324B0F2219789143197019782D +:1007D000214319702F490C782043087019780A407A +:1007E0001A701A7860210A431A702B4B2B4A5A80D0 +:1007F0005A7852B2002AFBDB294B01211A780A43AE +:100800001A709A78D107FCD426480268510B1F222F +:100810001140914200D1052111408C011D8D2249CA +:100820002940214319850468A10C0A401F2A00D1E0 +:100830001D221C8D1F210A408C4322431A85026809 +:100840000721D20D0A408A4200D103220A40188DA6 +:100850001103164A02400A431A8519787F220A407A +:100860001A701A78042112480A431A7058621A89B9 +:100870000C218A431A811A8901218A431A81002195 +:10088000802201F0A0F938BD000400405844004126 +:100890003C44004159440041000C00400640000027 +:1008A00000500041246080003FF8FFFFFF8FFFFFF2 +:1008B0009C010020F7B5141C1F4A5F0101971D1C05 +:1008C000D319061C5869271C4000400F0330103311 +:1008D000C74006D00F1C8022596812060A435A608E +:1008E00009E02F1C7B1E9F41144BBF01FF18381CD1 +:1008F000221C01F05FF901990F4808354218176171 +:10090000131C5269A104920B890C92030A435A6189 +:1009100059690B4A0A405A616B01F3180222DA71D5 +:100920005979802252420A435A716B01F318DB79DC +:100930009A07FAD5201CFEBD9C0100201C01002056 +:10094000FF3F00F0F8B51A4E051C3378141C002B3D +:1009500012D1184B184A1A645A6C920B92035A64BB +:10096000586C164A02405A64A2235B00EA5C40209D +:100970000243EA54012333704827FF37EA5D01231D +:10098000134012D00B4B5A6C9204920CA24202D22A +:100990005C6CA404A40C081C221C074901F00AF991 +:1009A0000123EB550023337000E01C1C201CF8BD14 +:1009B0007F0000209C010020DC000020FF3F00F0B1 +:1009C000FF3083792022002900D110221343837144 +:1009D00070470000084BFF305A69920B92035A612E +:1009E00002230372827980235B4213438371037A6B +:1009F0009A07FCD57047C0469C01002080235B42CB +:100A00001943C9B28172704770B5A02303225B00FD +:100A1000C254134B134A5C6CC021144089050C432B +:100A200046255C64FF35402444550F4D30261D6437 +:100A300090256D0046555D6B1540294392255963FD +:100A40006D0080214155094D1D63B0256D00445551 +:100A50005C6F22405A67B2235B00C15470BDC04630 +:100A60009C010020FFFFFF8FDC0000205C010020C4 +:100A7000024B5B785BB2002BFADB7047000C004046 +:100A8000024BDB68DA06FBD57047C0460008004021 +:100A9000F8B52A4B1E22596891430222114359602E +:100AA000274B28491E1C9982998A0A439A82F36827 +:100AB0000227234C3B42FAD0234D0123AB60FFF7C2 +:100AC000D7FF224B6B60FFF7D3FF8223DB016B80E4 +:100AD000FFF7CEFFA38C80229343A384FFF7D0FFC0 +:100AE0001B4BE362FFF7CCFFA38C1A4A1343A3848A +:100AF000FFF7C6FFA38C1F43A784F3681A06FCD533 +:100B00000F4BDB685A06F8D50024FFF7B9FFAC603D +:100B1000FFF7AEFF104B6B60FFF7AAFF0F4B104AB9 +:100B2000C0215A600F4A0906106A0002000A0143F8 +:100B3000116207229C601A60F8BDC0460040004167 +:100B4000000800400C060000000C004001050100F8 +:100B5000B805FF7D040A00000007030010E000E074 +:100B6000E703000000ED00E00EBEFEE70DBEFEE76D +:100B700005BEFEE702BEFEE70E4A0F4838B58242C8 +:100B800004D10E4A0E4B93420ED10AE00D4C944212 +:100B9000F7D00023D1188842F3D9E55804330D600B +:100BA000F8E700F011F804E09342FAD2002102C302 +:100BB000FAE7FEE7000000205C000020AC03002004 +:100BC0005C000020D01E000038B5344D2B68013386 +:100BD0001AD0334B2A1D1A60EAB2002A14D1314BC5 +:100BE000197801231940304B0AD118682F4A9042D6 +:100BF00001D1196008E01A602D4A013A002AFCD19F +:100C00001A602C4B01221A70FFF742FF62B6FFF701 +:100C100027FD284B284C1B78002B0AD02B6883F328 +:100C200008881E4BFF229343A3601D4B1B681B6863 +:100C3000184700F09DFD00F04FF8204B8022520332 +:100C40009A601F4B1F4A051C5A60216AC022090284 +:100C5000090A12060A43226200229A6007221A60D9 +:100C6000AB68281C9847184B002801D001221A7045 +:100C70001A78002A05D0002000F08CFA00F004FB5E +:100C8000FCE71B78002BEBD100F0E6FD0028E7D055 +:100C9000012000F07FFA00F0F7FAFCE700200000E6 +:100CA0001C02002038040040FC7F002035817307BF +:100CB00048E801008000002000ED00E00044004111 +:100CC00010E000E0E70300008100002008B5FFF716 +:100CD00033FB00F0C3FA08BD10B5054B054C23608B +:100CE000FFF764FD201C2168FFF752FD201C10BD9A +:100CF000005000412002002070B5051CC0B0081C47 +:100D0000161C0C1C00F067FF40006A4603230230EB +:100D10005370107076080123E218013A11785A00D6 +:100D2000002906D1281C69460023FFF7C3FD40B007 +:100D300070BDB342F6DA684681520133ECE7000039 +:100D4000F7B5BA4A04681378B949271CFF37051C60 +:100D5000102038720B705378B648B74E03709378F2 +:100D60003380D178338809020B4333801179B34B38 +:100D70001980517918880902084318809079B04980 +:100D80000880D2790888120202430A8040227A71D0 +:100D9000A84F3A78A64F120238780F1C0243A94890 +:100DA0008446181C624500D1C2E020DC8021490045 +:100DB0008A4200D16EE109DC812A00D192E0822AC8 +:100DC00000D195E0802A00D064E18BE081235B00B4 +:100DD0009A4200D1CFE000DA58E1C0239B009A424A +:100DE00000D157E1984B9A4200D14FE152E1902354 +:100DF0001B019A4269D015DCD023DB009A4222D035 +:100E000088231B019A4269D0A023DB009A4200D0BC +:100E100040E1201CFFF7DEFD3188286889B2FFF72A +:100E2000EDFD3BE1894B9A4200D12FE100DC31E13D +:100E3000874B9A4200D11DE1864B9A4200D029E1AE +:100E400033886B7122E133881B0A012B08D10B8890 +:100E500012222868934201D80A8892B27E4911E191 +:100E600033881B0A022B08D10B884322286893423F +:100E700001D80A8892B2794904E133881B0A032B0E +:100E800000D007E13388DBB2012B17D0002B07D04D +:100E9000022B00D0FEE00A882868D2B2704911E027 +:100EA000042201A86F4900F085FE3B8804222868CF +:100EB000934201D83A8892B201A9E3E00A882868EF +:100EC0006949D2B2FFF718FFE8E03388201C2B7184 +:100ED000FFF780FD201CFFF797FDDFE0291C01C90B +:100EE0000122CFE0614900230B8028680222CAE07A +:100EF0005E4900220A801888502210405C4A107017 +:100F00001E880F20304018801888032800D9C1E0BF +:100F100012781B8808335B01E418A379002A01D0FA +:100F20009B0600E0DB06DB0F0B8028680222A9E0AD +:100F300019887F2291434E4AC9B2117018880F2137 +:100F4000014019803188002900D0A3E019880029C8 +:100F500000D19FE01988032900D99BE012781B88F3 +:100F600008335B01E318002A02D020225A718DE079 +:100F7000102159718AE002887F239A433C4BD2B2F8 +:100F80001A7001880F220A4002803288002A00D09D +:100F900080E00288002A00D17CE00288032A00D980 +:100FA00078E01B78002B1FD0038808335B01E3181F +:100FB0009B799A066AD50388202208335B01E318DF +:100FC0001A71038808335B01E318DB795F065DD58E +:100FD0000388402208335B01E318DA710388022298 +:100FE00008335B01E3181EE0038808335B01E31854 +:100FF0009B79D9064AD50388102208335B01E31890 +:101000001A71038808335B01E318DB799A063DD532 +:101010000388202208335B01E318DA710388012278 +:1010200008335B01E3181A7130E0C0469C000020D1 +:1010300083000020880000208A0000208C0000200F +:1010400086000020020300000103000021200000B0 +:10105000A121000021220000201C0000040000202B +:101060000C1C0000FC1B0000001C00008400002081 +:10107000820000200B8808222868934201D80A8841 +:1010800092B207490023FFF715FC07E0201CFFF789 +:10109000A1FC03E0201C0121FFF792FCF7BDC04634 +:1010A0004800002007B5054B0122019001A91868EE +:1010B000131CFFF7FFFB01200EBDC04620020020DD +:1010C00013B5054B6C4607341868211C0122FFF745 +:1010D00039FC207816BDC0462002002010B5074C10 +:1010E000201CFFF713FB031C0020834205D022685D +:1010F0004823FF33D05C0123184010BD200200209C +:1011000010B5054A0C1C031C191C10680123221C75 +:10111000FFF7D0FB201C10BD2002002070B5084C4A +:10112000061C201C0D1CFFF7F1FA0023984205D085 +:101130002068311C2A1CFFF705FC031C181C70BD1D +:1011400020020020F8B50C4C051C201C0E1CFFF7DB +:10115000DDFA0023271C341C98420AD0002C07D04B +:10116000291C221C3868FFF7EDFB241A2D18F5E71F +:10117000331C181CF8BDC0462002002008B5031C13 +:10118000081C111C9847024B64221A8008BDC046F7 +:1011900092000020012805D1054B064A1A60064B33 +:1011A000187004E0002802D1044A014B1A6070470D +:1011B00090020020541C000098000020A01C000099 +:1011C00030B50A1C1C4985B00978031C00292AD0B7 +:1011D000042A01D1006804E0022A01D1008800E05D +:1011E0000078520004A98B180B3B9C1AA3420BD029 +:1011F0000F210140092902D83025294300E0373169 +:1012000019700009013BF1E701A930230B70782325 +:101210004B700A208B1898700D20D870074B043241 +:101220001B68D86803E005490968C868191CFFF7FE +:10123000A5FF05B030BDC0468E0000209002002002 +:1012400072B6EFF30883044A1360036883F30888D7 +:10125000436818477047C04694020020084B1A881C +:10126000002A03D01A88013A92B21A80054B1A88D4 +:10127000002A03D01A88013A92B21A807047C046F9 +:101280009200002090000020F0B591B008A9CC4A4F +:101290000B1C31CA31C351CA51C360CA60C3C94BA8 +:1012A000C9489A687A255203520F92005258C7498A +:1012B00002609C68A4B262430C60C54900240A60C5 +:1012C000C44A1460C44C2570C44CC54D2368281C06 +:1012D0001B6940219847002802D0C24B64221A8023 +:1012E000C14B00221860C14B1D60C14BC04DBE4FA9 +:1012F0001A602A683B689A42E6D2BC4B1B681A788F +:10130000FF2A00D114E2232A00D0EBE1B94E337852 +:10131000002B06D0B14BB8491B680222D868FFF7F2 +:101320002DFFAD4B1B78532B3CD13B682A68934271 +:101330001ED9AE4801322A609A1AB04B01681B6868 +:1013400001310160AE4E9A4201D2326000E033605A +:10135000A04832680068049000F02CFC33682968CB +:101360005A182A60A14A1668F1181160A54A13702C +:101370002B68013B2B609D4B1A68013A1A60A14B08 +:101380009E4A1B7811688B420AD222689148C91A7A +:10139000006892699047002802D0924B64221A801C +:1013A000C0468DE1522B0AD18A48944A23680068CE +:1013B00011685B69039098476422934B0DE04F2BB3 +:1013C00005D1844B8D4A1B6812681A7078E1482B4E +:1013D00005D1804B894A1B6812681A8070E1572B2F +:1013E00005D17C4B854A1B6812681A6068E16F2B37 +:1013F00003D1784B0121186807E0682B08D1754BA1 +:101400007E481B6802211B880360FFF7D9FE57E165 +:10141000772B06D16F4B79481B6804211B6803604A +:10142000F3E7472B13D1754B1868FFF709FF774B8C +:101430001B6883F3088862B6754B1B78002B00D1BC +:101440003EE1664B06201B681B68984738E1542B29 +:1014500004D101233370614B1B6864E04E2B0CD127 +:101460003378002B06D15D4B63491B680222D86894 +:10147000FFF784FE0023337022E1562B57D12368F7 +:101480006449D8680122FFF779FE23686249D86869 +:101490000322FFF773FE614D2368291CD8680122DF +:1014A000FFF76CFE23685E49D8680D22FFF766FEE1 +:1014B0002368291CD8680122FFF760FE4B4F4C4D72 +:1014C0005849002339602B603A1C281C13685E1CA5 +:1014D00016601B780593002B03D00368013303606B +:1014E000F4E73E4E2A683368D868FFF747FE336852 +:1014F0004A49D8680122FFF741FE059929604A4907 +:1015000039603A4A1368581C10601B78002B04D0CD +:10151000374B1A6801321A60F3E733682A68D868D3 +:10152000FFF72CFE3368D86833490222C6E0334AFD +:10153000582B17D1244E264D366813682A68B100FF +:1015400093420AD21F4D5808E861384828801D4D43 +:10155000287DC607FBD55B18F2E7204B34491B6892 +:10156000D868AAE0592B79D112681A4B3149002A60 +:1015700002D11B680B606CE0124D086819686B683B +:10158000104E8025AB4392087360002A61D02A4B2D +:101590000C4D2B800B4E337DDD07FBD500230A4D10 +:1015A0002D680195AD08AB4203D3244D054E35801F +:1015B00046E09342F9D09D00465901334E51EEE783 +:1015C000341C00000040004148020020400200207E +:1015D0003C0200208C0200203802002090020020F3 +:1015E0004C02002090000020300200203402002035 +:1015F000440200208E000020941C0000980200206D +:101600009C0200202C020020920000209402002066 +:1016100098000020701C0000991C0000721C000043 +:10162000BC1C0000741C0000801C000002A5FFFF11 +:10163000891C00009400002044A5FFFF04A5FFFFC3 +:101640003F4E357DEE07FBD59D0049194019D21A52 +:101650009BE73C4B3C491B68D8682EE05A2B2FD1A6 +:101660003A4B17681D680026EF19BD4206D028784E +:10167000311C00F013F90135061CF6E7314B3449F3 +:101680001B680122D868FFF779FD07230F2232403B +:10169000111C36093031092A00DD07311820C01825 +:1016A0006A468154013BF1D2236806A9D868082212 +:1016B000FFF764FD23682749D8680322FFF75EFD22 +:1016C000254B7A221A70254B00221A60244B1B7876 +:1016D00093422DD01B4B23491B680122D868FFF78A +:1016E0004DFD25E0111C3039C8B21C4B092804D827 +:1016F0001D682A01114319601AE0111C413905299E +:1017000003D81E68373A310106E0111C61390529FA +:1017100004D81868573A01010A4308E02C2A03D17B +:101720000A4A1968116001E00B490A7000221A6028 +:101730000D4B1A6801321A600C4B1A680132D5E55C +:1017400000400041900200208D1C00008C0200200F +:10175000911C0000931C0000380200209802002019 +:101760008E000020971C000044020020340200205C +:1017700010B51C4B01201A78032402431A701A4B2F +:101780000F2219789143197019782143197017495C +:101790000C782043087019780A401A701A783021A2 +:1017A0000A431A70124B80211A6A0A431A62114BBB +:1017B000114A5A805A7852B2002AFBDBC4220F48E1 +:1017C0000F499203FEF756FF0E4A002313700E4A8C +:1017D00013700E4A13700E4A13700E4A13700E4A9D +:1017E000137010BDD6440041BB440041D7440041B2 +:1017F00000040040000C004019400000001C0042A2 +:101800002AF60000A002002027030020A1020020E9 +:10181000A4020020280300202503002008B5C1B23F +:101820000248FEF755FF012008BDC046001C0042DB +:10183000024B187E4007C00F7047C046001C004294 +:1018400008B5FFF7F5FF0028FBD00248FEF746FF7A +:1018500008BDC046001C004208B5FFF7E9FF0023A1 +:10186000984205D0FFF7ECFF031C233B5A4253413B +:10187000181C08BD70B5041C0D1C4618B44204D0D9 +:101880002078FFF7CBFF0134F8E7281C70BD10B5B6 +:10189000041CFFF7D5FF2070012010BD0B0A584033 +:1018A000034B4000C05A0902484080B27047C0460E +:1018B000CA1C0000F7B50024051C0F1C261CBC42E6 +:1018C00020D0FFF7BDFF114BC0B21B780190002B59 +:1018D0001AD1311CFFF7E2FF0D4B061C1A88002AB3 +:1018E00004D10C4A11782A1C002907D001996A1CDE +:1018F0002970802F02D11988013919800134A4B2CE +:10190000151CDCE7301C00E00120FEBD2503002093 +:10191000A202002026030020F0B53E4E85B0002232 +:1019200003900C1C32703C4B914201D1012201E02A +:101930003A490C801A707F231C4201D080349C43AA +:10194000FFF77EFF3378C0B2002B07D0002535703B +:10195000FFF776FF3378C0B2AB4236D1432803D0CD +:10196000712853D01528EBD1012300930120FFF7F4 +:1019700055FF0098FFF752FF00998025C843C0B279 +:10198000FFF74CFF039B00270293244A1388002B88 +:101990001DD1214901930978002918D10198FFF739 +:1019A0003DFF391C0198FFF779FF013D071C002D11 +:1019B000EBD1000AC0B2FFF731FFF8B2FFF72EFFFC +:1019C000FFF73EFF3378002B0AD035701FE00299F5 +:1019D000013B09781380029B019101330293DDE7FB +:1019E000C0B2062807D1009B03990133DBB28031D6 +:1019F0000093803C0391002CB8D10420FFF70EFF28 +:101A0000FFF71EFF044B01251C7000E00025281C79 +:101A100005B0F0BD2503002026030020A20200200F +:101A2000F0B5384C87B0002301902370994201D162 +:101A3000012301E0344A1180344A642613704320A4 +:101A4000FFF7ECFE324FFFF7F3FE002803D1002F23 +:101A500003D0013FF7E7002F03D1013E002EEED166 +:101A60004DE00125FFF7ECFE2378002B38D1C0B202 +:101A70000290012805D004283DD10620FFF7CEFEB4 +:101A800039E005AE0221301CFFF714FF01988021D8 +:101A9000FFF710FF23780390002B18D1FFF7D0FE3B +:101AA0000702FFF7CDFEBFB223783F18BFB2012B6C +:101AB0000DD0039B9F4207D13378AB4204D1EB4357 +:101AC0007278DBB29A4204D01820FFF7A7FE0023F9 +:101AD00003E00620FFF7A2FE029B2278002A02D034 +:101AE000002626700BE0012B05D1019A6B1C803279 +:101AF000DDB20192B6E7054A002313700126301CBF +:101B000007B0F0BD25030020A2020020260300201C +:101B100000350C00002934D00123002210B4884283 +:101B20002CD301242407A14204D2814202D209010C +:101B30001B01F8E7E400A14204D2814202D249002D +:101B40005B00F8E7884201D3401A1A434C08A042D0 +:101B500002D3001B5C0822438C08A04202D3001B66 +:101B60009C082243CC08A04202D3001BDC0822437D +:101B7000002803D01B0901D00909E3E7101C10BCA1 +:101B80007047002801D00020C04307B4024802A1DA +:101B90004018029003BDC046190000000029F0D093 +:101BA00003B5FFF7B9FF0EBC4243891A1847C04678 +:101BB0007047C04610B50023934203D0CC5CC45498 +:101BC0000133F9E710BD031C8218934202D019704B +:101BD0000133FAE770470023C25C0133002AFBD1CE +:101BE000581E7047F8B5C046F8BC08BC9E46704702 +:101BF000F8B5C046F8BC08BC9E467047040309040B +:101C000041726475696E6F204C4C4300417264757B +:101C1000696E6F204D4B52204E42203135303000DE +:101C2000120100020200004041235500000201029F +:101C3000000100000800000010000000200000006B +:101C400040000000800000000001000000020000D1 +:101C5000000400001D1800004118000031180000A9 +:101C6000751800008F18000019190000211A0000D3 +:101C7000760020004170722031312032303139003D +:101C800031333A30393A353700580A0D00590A0DC8 +:101C9000005A00230A0D003E00322E3000000000E2 +:101CA000A5100000C1100000DD10000001110000AF +:101CB0001D11000001110000451100005B4172641C +:101CC00075696E6F3A58595A5D0000002110422024 +:101CD00063308440A550C660E770088129914AA10D +:101CE0006BB18CC1ADD1CEE1EFF131121002733284 +:101CF0005222B5529442F772D662399318837BB35D +:101D00005AA3BDD39CC3FFF3DEE362244334200413 +:101D10000114E664C774A44485546AA54BB52885AC +:101D20000995EEE5CFF5ACC58DD553367226111663 +:101D30003006D776F6669556B4465BB77AA71997FC +:101D40003887DFF7FEE79DD7BCC7C448E5588668EB +:101D5000A7784008611802282338CCC9EDD98EE94C +:101D6000AFF9488969990AA92BB9F55AD44AB77AC3 +:101D7000966A711A500A333A122AFDDBDCCBBFFB9C +:101D80009EEB799B588B3BBB1AABA66C877CE44CD3 +:101D9000C55C222C033C600C411CAEED8FFDECCDEC +:101DA000CDDD2AAD0BBD688D499D977EB66ED55EA3 +:101DB000F44E133E322E511E700E9FFFBEEFDDDF3C +:101DC000FCCF1BBF3AAF599F788F8891A981CAB1C8 +:101DD000EBA10CD12DC14EF16FE18010A100C230FA +:101DE000E3200450254046706760B9839893FBA3B5 +:101DF000DAB33DC31CD37FE35EF3B1029012F3224A +:101E0000D2323542145277625672EAB5CBA5A89504 +:101E100089856EF54FE52CD50DC5E234C324A01499 +:101E200081046674476424540544DBA7FAB7998794 +:101E3000B8975FE77EF71DC73CD7D326F2369106E9 +:101E4000B01657667676154634564CD96DC90EF9DC +:101E50002FE9C899E9898AB9ABA944586548067839 +:101E60002768C018E1088238A3287DCB5CDB3FEBF4 +:101E70001EFBF98BD89BBBAB9ABB754A545A376A89 +:101E8000167AF10AD01AB32A923A2EFD0FED6CDDC4 +:101E90004DCDAABD8BADE89DC98D267C076C645CD9 +:101EA000454CA23C832CE01CC10C1FEF3EFF5DCFD4 +:101EB0007CDF9BAFBABFD98FF89F176E367E554E29 +:101EC000745E932EB23ED10EF01E000000000000A2 +:101ED00001140000090243000201008032090400DD +:101EE0000001020200000524001001042402000584 +:101EF000240600010524010001070583030800FFF3 +:101F000009040100020A00000007058102400000E8 +:101F1000070502024000000000C2010000000800A6 +:0C1F20006900000041000000000000000B +:0400000300000B7975 +:00000001FF diff --git a/bootloaders/mkrvidor4000/samd21_sam_ba_arduino_mkrvidor4000.bin b/bootloaders/mkrvidor4000/samd21_sam_ba_arduino_mkrvidor4000.bin new file mode 100755 index 0000000..ef73ac3 Binary files /dev/null and b/bootloaders/mkrvidor4000/samd21_sam_ba_arduino_mkrvidor4000.bin differ diff --git a/bootloaders/mkrvidor4000/samd21_sam_ba_arduino_mkrvidor4000.elf.ltrans.out b/bootloaders/mkrvidor4000/samd21_sam_ba_arduino_mkrvidor4000.elf.ltrans.out new file mode 100644 index 0000000..75ea02c --- /dev/null +++ b/bootloaders/mkrvidor4000/samd21_sam_ba_arduino_mkrvidor4000.elf.ltrans.out @@ -0,0 +1 @@ +samd21_sam_ba_arduino_mkrvidor4000.elf.ltrans0.o diff --git a/bootloaders/mkrvidor4000/samd21_sam_ba_arduino_mkrvidor4000.hex b/bootloaders/mkrvidor4000/samd21_sam_ba_arduino_mkrvidor4000.hex new file mode 100644 index 0000000..8c2cac4 --- /dev/null +++ b/bootloaders/mkrvidor4000/samd21_sam_ba_arduino_mkrvidor4000.hex @@ -0,0 +1,512 @@ +:10000000FC7F0020C516000099010000950100004A +:1000100000000000000000000000000000000000E0 +:10002000000000000000000000000000910100003E +:1000300000000000000000008D0100001101000020 +:1000400010B5064C2378002B07D1054B002B02D0AE +:10005000044800E000BF0123237010BD5C000020B5 +:10006000000000007C1F0000044B10B5002B03D0E3 +:100070000349044800E000BF10BDC0460000000076 +:10008000600000207C1F0000030010B50800110074 +:1000900098476422014B1A8010BDC04678000020AA +:1000A000F0B5194B0A00997885B05C68002929D011 +:1000B000042A1FD100680F263027520004AB9B187A +:1000C0000B3B9D1A01003140092919D83943197099 +:1000D000013B00099D42F5D10A200C4B01A90B8080 +:1000E0008B1898700330D8700432E068FFF7CCFFAB +:1000F00005B0F0BD022A01D10088DCE70078DAE71C +:100100003731E4E70100F0E77800002030780000A4 +:100110001B4A1C4B117A002908D119785878091804 +:100120008020C9B25970184940000860117A013125 +:10013000C9B211725978F02902D85978092908D81A +:100140001978494249B21970197858780918C9B212 +:100150005970117A5B78994203D180210A4B49008A +:1001600019601388002B03D01388013B9BB21380C6 +:100170005389002B03D05389013B9BB253817047B5 +:1001800078000020000000209C44004102BEFEE7F1 +:1001900005BEFEE70DBEFEE70EBEFEE7074AFF30D6 +:1001A00053699B0B9B035361022303728279823B49 +:1001B00013438371037A9B07FCD570472C02002000 +:1001C000802102000A4BC90100280ED099618021CC +:1001D000890199615961074B187B40008018064AD4 +:1001E000800080581873C0B270475961EFE7C0466D +:1001F0000044004178000020AC1C00000C4B10B5FE +:100200001B7B082B10D00F2B0ED00120FFF7D8FF3F +:100210000120FFF7D5FF0120FFF7D2FF0120FFF7F4 +:10022000CFFF0120FFF7CCFF0020FFF7C9FF10BD73 +:10023000780000200D4B10B51B7B0F2B0AD0082B2C +:1002400008D00124A3420FD80020FFF7B9FF0020F7 +:10025000FFF7B6FF0120FFF7B3FF0020FFF7B0FF65 +:100260000020FFF7ADFF0024200010BD7800002023 +:10027000074B10B51B7B01240B2B06D12000FFF789 +:100280009FFF2000FFF79CFF0024200010BDC04608 +:1002900078000020F0B587B003900020012604000C +:1002A0000700B4465E4001920596039B9F4201D130 +:1002B00007B0F0BD002C04D1FF25002901D00D7836 +:1002C00001316246184B40081E6AF60B1640F601D3 +:1002D00030436646039A2E400496561E62460292AA +:1002E000BE4201D1059A0292049A002A18D08022B7 +:1002F00052019A61029A002A03D08026B6019E61BB +:100300005E6107236D080134EDB21C4006D1019BEC +:10031000002B03D018702000013301930137C4E78C +:10032000802252015A61E5E700440041F7B50124FB +:100330006240019280220023520106009446180078 +:10034000B34200D1FEBD0F4A2700156AED0B2540D0 +:100350009D4028430D0025400095751E9D4200D10B +:10036000019F009D002D0AD065469561002F03D0A6 +:100370008025AD019561556149100133E0E765467F +:100380005561F3E700440041154B10B51B7B040099 +:10039000012B01D9FFF732FF0020FFF711FF0120E9 +:1003A000FFF70EFF0120FFF70BFF0020FFF708FF0C +:1003B0000020FFF705FF012221000A20FFF7B6FF0A +:1003C0005623FF33984207D10120FFF7F9FE0120A1 +:1003D000FFF7F6FE002010BD01204042FBE7C046BB +:1003E00078000020F7B50D4D0700EB7B0E202C7C2C +:1003F0000193FFF7C9FF061E0EDBFFF71BFF019BF2 +:10040000611C9940E87BAB7B3943C0180122FFF7A0 +:100410008DFFFFF72DFF6F743000FEBD78000020C8 +:1004200037B505000020124B01905B7C0C00834225 +:1004300018D10C20FFF7A8FFFFF7FCFE019B01A9D4 +:100440009A00032313430193002320201A00FFF78F +:1004500021FF0023600102301A002900FFF71AFF74 +:1004600020003EBDFFF7BEFF0028FADBE1E7C046F3 +:10047000780000200222634BF0B51A708023624C92 +:100480008027802680251B026360002385B0AD0194 +:10049000FF017601A7600121A66003A8A560039370 +:1004A000FFF7BEFF80235B05A3606361A761A661C0 +:1004B0006561FFF7A3FE554D2B7B012B01D9FFF79B +:1004C0009DFE0020FFF77CFE0120FFF779FE012052 +:1004D000FFF776FE0020FFF773FE0020FFF770FEA7 +:1004E000012204210A20FFF721FF0120FFF768FE07 +:1004F0000120FFF765FE9A27FFF79CFE80228023EC +:10050000FF3752019B01013F6261A3616361002FCC +:10051000F9D13A0039000120FFF708FF0400FFF786 +:10052000A7FEFFF76BFE002C03D10120404205B06F +:10053000F0BD0E20FFF728FFFFF77CFE3A003900E0 +:100540004020FFF7F3FEFFF793FE0C20FFF71CFFA0 +:1005500008263C00FFF76EFE002204201100FFF782 +:10056000E5FE24090007013E0443FFF781FEFFF783 +:1005700045FE002EEED1FF2362032B746B74520DE7 +:100580006E2AD2D131000120E20C009313406A732D +:10059000AE7301933200009BF7B21A4094460200FA +:1005A00063469A40019B0136934226DA002900D027 +:1005B000AF730027EC736B7B9F42B6DA08260024EA +:1005C000FFF738FE002204201100FFF7AFFE2409D8 +:1005D0000007013E0443FFF74BFEFFF70FFE002E1E +:1005E000EED1FF22E30C1340842B08D16403640D89 +:1005F0006E2C04D12F74300099E70100CAE701374F +:10060000D9E7C0464F440041004400417800002033 +:1006100003210A4B01405A68094809041040084365 +:10062000084A5860D8694007C00F00D17047013AA6 +:10063000002AF7D101204042F8E7C04600080042F6 +:10064000FFFFFCFF52C30000F8B52A4D2A4A2900DB +:10065000937C2A485B00DCB26B8B9B069B0F012BC3 +:1006600004D06B8B9B069B0F022B17D14B6ADB0AC6 +:10067000DB0223434B620B7EDB0718D54B8B5B07FA +:10068000DB0F0ED118000127D47C002C13D10028D9 +:1006900000D0D4740320FFF7BBFF06E00138831CB1 +:1006A000DAD10320FFF7B4FF02242000F8BD01389F +:1006B000831CE0D1F5E7124D124E5D5D3570124D91 +:1006C0000E7EF60707D54D8B01336D0706D4013C2E +:1006D000E4B23800D9E7013D002D07D1002800D051 +:1006E000D4740320FFF794FF0324DEE74E8BF60754 +:1006F000E6D5F3E7000800427800002050C3000070 +:100700008C0000202808004252C3000010B56B2264 +:100710000224044B9A741875DC745975FFF794FF22 +:10072000200010BD780000206B2310B5234CA3746B +:100730006A3BE3742075FFF787FF002398422ED1B0 +:10074000A0751F481F4A0300418B8906890F0129A4 +:100750001CD1D720596AC90AC90201435962197EBE +:1007600089071ED55A8B520718D40122A2751A7E0A +:100770009207FCD5144A03201278E275802259684A +:10078000D2020A435A60FFF743FF07E0418B890614 +:10079000890F0229DDD0013A911CD5D1E37D1800E3 +:1007A00010BD013A911CF9D0197EC907D7D5C022D6 +:1007B000596892020A435A60F0E7C0467800002068 +:1007C0000008004250C300002808004237B5194C09 +:1007D0000190637C0D00002B1FD10C20FFF7D4FD8E +:1007E000FFF728FD019B01A99A00032313430193FE +:1007F000002320201A00FFF74DFD637C012B12D14E +:100800000C20FFF7C1FDFFF715FD002320202A0073 +:100810001900FFF73FFD002004E00020FFF7E2FD94 +:100820000028DADA3EBD0120FFF7DCFD0028F9DB05 +:10083000E6E7C0467800002013B50C00FFF7F0FD96 +:100840000190A04215D180220C4B52050C4C9A61AC +:100850005A61013C002C0FD001A90020FFF7B6FF20 +:10086000019B002BF5D101A90120FFF7AFFF0198F3 +:1008700016BD0A204042FBE70120FBE7004400418F +:10088000EA030000F0B5124C0D00A544114B019095 +:10089000029168460321160000930227FFF7CCFF60 +:1008A000EC1CA4080134B90038006944FFF78EFF3E +:1008B0007B1E01379C42F6DC00231A006A44127B3F +:1008C000F2540133AB42F8D1034B9D44F0BDC04616 +:1008D000FCFBFFFF0500000104040000F8B51A4FFF +:1008E00006003B7E08001400002B12D1174B184A5B +:1008F00018491A645A6C920B92035A645A6C0A4053 +:100900005A64A22240235200B15C0B43B35401232A +:100910003B764825FF35735DDB07DB0F12D00B4AB2 +:10092000536C9B049B0C9C4202D9546CA404A40CF1 +:100930002200074901F069F90123735500233B7632 +:100940002000F8BD1C00FBE7780000202C020020EE +:10095000EC010020FF3F00F013B56B46DC1D044B9B +:1009600001222100D869FFF7B9FF207816BDC046E3 +:1009700078000020F7B5009001201C4D1C005B01A1 +:1009800016000193EA18536910325B005B0F0333C2 +:100990009840B04221D8802350681B06034353601F +:1009A0006301ED1829616B69B1049B0B890C9B03F2 +:1009B0000B436B616B690E4908340B406B61009B04 +:1009C00064011C190223E3716279823B1343637152 +:1009D000E3799B07FCD53000FEBD064BA701FF184D +:1009E0003200380001F011F93900D9E72C0200205B +:1009F000FF3F00F02C01002010B50C000A000100A0 +:100A000003480123C069FFF7B5FF200010BDC046B1 +:100A100078000020012307B5019004481A0001A9BD +:100A2000C069FFF7A7FF01200EBDC0467800002077 +:100A300010B50B4C0B4BA5440C000190110003A802 +:100A400022000093029401F0E0F8E11C89080331D0 +:100A50006846FFF7F1FE8023DB009D4410BDC046D1 +:100A600000FCFFFF04000001F0B5CB4BCB4CCA48A3 +:100A70005B68A54400AF28301B69402198470028D7 +:100A800002D06423C44A5381C34BC34A98662833B7 +:100A9000D36600231367C04B1B6FFB60BE4B9B6E7E +:100AA000BB60BA68FB68934200D3B2E1BA4BDB6E1D +:100AB000FB601B78FF2B63D0232B00D05CE3B64B8D +:100AC0009B78002B06D0B44B02225B68B449D868EF +:100AD000FFF7DAFAB04874300378532B5DD1AE4B90 +:100AE000AD4A9B6E146FA3421FD9AB49926FC96E7A +:100AF00001344D1CF960A8491B1BCD660C6793425D +:100B000048D2CB67A44BA74EDB6F29001A00306890 +:100B1000FB6001F07AF8FB68E4189F4B1C67FB68E8 +:100B2000ED189D4BDD663B7B33719B4B9A4A1B6FE7 +:100B30009949013B1367D36E896FFB60013BD36614 +:100B4000984B1A798A420AD2891A934A18685268CD +:100B500092699047002802D064238F4A5381C0468F +:100B60007A228D4B74331A7000238B4A93679378E3 +:100B7000002B05D053688C490122D868FFF784FA0E +:100B8000854B854A1B6F01331367D36EFB600133BE +:100B9000D36680E7804BDA67B4E7522B09D17E4BEE +:100BA0007D4A5B687F49926F09685869FFF76CFA64 +:100BB000D6E74F2B07D1784A7A4B926F1B68FA60C1 +:100BC0003A7B1A70CCE7482B07D1734A754B926F6A +:100BD0001B68FA60BA891A80C2E7572B06D1714B9D +:100BE0006D4A1B68926FFA601A60B9E76F2B05D1E6 +:100BF00001216C4B1868FFF753FAB1E7682B07D156 +:100C0000684B654A1B6804301B8802219367F2E732 +:100C1000772B09D1634B04301B6804211B68FB60F0 +:100C2000FA685D4B9A67E6E7472B19D15A4B996FE3 +:100C300072B6EFF308825B4B9A600A6882F3088809 +:100C40004A6810479A6882F3088862B61B7B002BBB +:100C500000D185E7504B06205B681B6898477FE70B +:100C6000542B0AD14C4A533B9370130002225B6809 +:100C70004B49D868FFF708FA72E74E2B0ED1464B66 +:100C80009B78002B06D1444B02225B684449D8680C +:100C9000FFF7FAF90023404A937061E7562B62D1BF +:100CA0003D4B01225B684149D868FFF7EDF93A4BAB +:100CB0003F4D5B6803222900D868FFF7E5F9364B02 +:100CC0003C4C5B6801222100D868FFF7DDF9324B0C +:100CD000291D5B680D22D868FFF7D6F92E4B01223B +:100CE0005B682100D868FFF7CFF9002301202A4A6A +:100CF000844613671A0030494E1C8D5CB018002DD5 +:100D00002BD1002B01D0244B1A67234B224AD866E3 +:100D10005B68126FD868FFF7B7F91F4B01225B6859 +:100D20002100D868FFF7B0F900231B4A012613679A +:100D30001A0022494D1C8C5CA818002C10D1002BE5 +:100D400001D0154B1A67144B134AD8665B68126FB3 +:100D5000D868FFF799F9104B88E701326346CCE772 +:100D600001323300E7E7582B30D10E4A0A4B1069A5 +:100D700052699B6F1249134C9200984204D8064B5B +:100D800003225B68104974E75D08CD610C800D7D1E +:100D9000ED07FCD59B18F0E7780000205CEFFFFF23 +:100DA000541F0000F8000020571F00002C1F0000F7 +:100DB000441C00002E1F0000301F00003C1F0000DC +:100DC0000040004102A5FFFF451F0000592B00D045 +:100DD00041E1C94BC94A9B6F1468002B05D194614E +:100DE000C54B03225B68C64943E79B08FB609369D8 +:100DF000BB608023DB029C4200D0C6E0FFF73AFBD9 +:100E0000051E0AD0BC4B03225B68BE49D868FFF7B9 +:100E10003BF9BD46BC4B9D44F0BD1023FE1832008B +:100E20009021BA48FFF72EFD08233E60BC68B84EFB +:100E30007B60220023002D322C3312781B781202A3 +:100E40001A4323002E331B781B041A4323002F332D +:100E50001B781B06134351D06278237812021A4381 +:100E6000A3781B041A43E3781B061343A84A536074 +:100E70000122A24B1A770024BB6819190A000B0043 +:100E80002932283312781B7812021A430B002A33B6 +:100E90001B781B041A430B002B331B781B061343D0 +:100EA000013305D01023FB181819302200F0ADFED5 +:100EB0003034902CE0D110219022964B791889186B +:100EC00010200B60942102233818411810200B6069 +:100ED000FF239821381841185B030B608018032109 +:100EE000FFF7AAFC7134FF34FB68AB4240D81023F3 +:100EF0009021FA188548FFF79BFD71E77A683B68F7 +:100F00009B182200196A23002932283312781B7893 +:100F100012021A4323002A331B781B041A432300AE +:100F20002B331B781B061343994201D04B1C17D15E +:100F30006278237812021A43A3781B041A43E378D9 +:100F40001B0613437268934200D2736021007A68D3 +:100F50003B6808319818202200F048FE002887D10D +:100F60007B68303430337B60982B00D061E782E7B8 +:100F7000FF23DB02E818684B8000C218BB68210021 +:100F80009A18FFF755FD8035AEE7644B9C4239D97E +:100F9000137F002B00D123E75D4B614A5B689B18F0 +:100FA0001C19A3B2002B12D110219022594B791891 +:100FB000891810200B6094210223381841180B6007 +:100FC0009633C318032180181C60FFF735FCFB68BB +:100FD00080267F33DB095A02802320009B00E31820 +:100FE000D318FB60B60080239B00C518FB689D42A8 +:100FF00000D1F5E6BB6831001A18121BFFF718FD87 +:101000002800F0E78020474B5968814359605169B7 +:10101000454A89089446FA68002A00D1E0E6434A26 +:101020001A801A7DD207FCD520000022BD6804007A +:10103000BD60914202D0FE68964208D16046188099 +:10104000187DC007FCD5F868821AFA60E3E710CD76 +:10105000013210C0EBE75A2B00D081E5264B9D6F83 +:10106000264B1C688023DB029C423FD18026002453 +:1010700076000CE010229023BA18D3181A19FF2317 +:101080005B03E0183100FFF7FDFB0134FF34A5429C +:10109000F0D810229023BA18D4180026244A6519D3 +:1010A000AC425FD1144B01225B682249D868FEF73D +:1010B000EBFF0F24072332002240D0B20100360993 +:1010C0003031092A00DD07311022BA18D154013B12 +:1010D000F1D21021084B08225B687918D868FEF716 +:1010E000D3FF054B03225B681349C2E50B4B9C42BF +:1010F000D3D9002633E0C04678000020F800002055 +:101100004D1F0000491F0000A410000000F01F0048 +:1011100000000020030000010020E0FFFF0F04009A +:1011200000F0FBFF0040004104A5FFFF44A5FFFFC6 +:101130002C1D0000511F0000531F0000102290239F +:101140008021BA18D3189A19244B49005868244BA7 +:10115000C01820188019FFF795FB0136FF36AE4204 +:10116000ECD396E72178330A4B405B0031029E5A5C +:1011700001344E40B6B293E71A00303AD1B2092991 +:1011800007D8184B9B6FFB601B011343154A9367ED +:10119000F6E41A00413A052A05D8124A373B926F05 +:1011A000FA601201F1E71A00613A052A05D80D4AE2 +:1011B000573B926FFA601201E7E700222C2B08D10F +:1011C000084B9B6FFB60F968074B1960054B9A67EA +:1011D000D6E4044974310B70F8E7C04600000020E3 +:1011E00000F0FBFF78000020F800002070B505003B +:1011F000C0B0080016000C0000F010FD6B46400067 +:10120000023018706A46032376085370023B5A1E58 +:10121000A15C5A00002901D09E4206DC00236946E9 +:101220002800FFF7A7FB40B070BD6846013381522C +:10123000EDE7F7B5056808222900AB8B06001340DF +:10124000FF31002B27D080234020C024AA830932FD +:10125000AB724A7088714B71B34BB44D5A68A40598 +:101260002A4022435A605A692A401443B04A5C61BA +:101270001A60B04AB04C1A615A6814408022920237 +:1012800022435A605A68920B92035A6000234871B5 +:1012900033713079FEBD10200A7A0242F9D0A44A97 +:1012A000A64C1778087267775778A77797782784BE +:1012B000278CBC466046D7783F02074327841779BE +:1012C00067845779608C3F02074367849779A784C6 +:1012D000D279A78C12023A434027A2844F71A27F91 +:1012E000607F120202439648824200D1F2E026DC7F +:1012F0008020400082421CD00BDC812A04D0822A4C +:1013000000D1BEE0802A14D12100E38426310222DC +:101310004EE081235B009A4200D127E100DAF8E039 +:10132000FF33FF339A4200D1CFE0864B9A4200D17F +:10133000EFE02023FF35AA791343AB71A9E7902191 +:1013400009018A426CD017DCD021C9008A4222D020 +:10135000882109018A4200D190E0A023DB009A4253 +:10136000E7D12800FEF71AFF8023228C5B4213434B +:101370003268DBB293728CE7734B9A4200D1C8E0BB +:10138000D7DD724B9A4200D14DE1714B9A42D0D1D8 +:10139000238C7371BDE0238C1B0A012B0CD112220C +:1013A000A38C934201D8A28C92B2002369491431D4 +:1013B0002800FFF7DFFA6CE7238C1B0A022B09D108 +:1013C0004322A38C934201D8A28C92B2624900239B +:1013D0000831EDE7238C1B0A032BAAD1238CDBB247 +:1013E000012B16D0002B05D0022BA2D1A28C5B4979 +:1013F000D2B211E057490422263101A800F005FCC1 +:101400000422A38C934201D8A28C92B2002301A99A +:10141000CEE7A28C5249D2B22800FFF7E7FE38E7A8 +:10142000238C28003371FEF7B9FEA0230322C021CC +:101430005B00EA543C4B3D485A6C890502400A4324 +:101440005A644622FF32AF54464A30241A6490222E +:101450005200AC545A6B02401143922259638021CE +:101460005200A954404A1A63B0225200AF545A6F36 +:1014700010405867B2235B00E9540AE7311D01228E +:1014800096E75022E384638C0F2013402200283219 +:101490001370638C03406384638C032B15D813781B +:1014A000002B0BD0638C08335B01EB189B799B06F8 +:1014B0002100DB0FE3842631002328E7638C083307 +:1014C0005B01EB189B79DB06F2E720238A79134353 +:1014D0008B71DEE68022638C0F21134022002832BC +:1014E0001370638C0B406384238C002B00D020E7A7 +:1014F000638C002B00D11CE7638C032B00D918E709 +:101500001378002B09D02022638C08335B01EB1881 +:101510005A712800FEF742FEBBE6638C10220833A6 +:101520005B01EB18F4E7C0462C020020FFFFFF8FA1 +:10153000AC0100202C010020FF3F00F0F80000204B +:10154000020300000103000021200000A12100008F +:1015500021220000441C000000000020651F000044 +:10156000591F0000EC0100206C0100208022638CD8 +:1015700013402200283213700F22638C13406384BF +:10158000238C002B00D0D4E6638C002B00D1D0E656 +:10159000638C032B00D9CCE6230028331B78002B67 +:1015A00020D0638C08335B01EB189B799B06B0D588 +:1015B000638C113208335B01EB181A71638C0833AA +:1015C0005B01EB18DB795B06A3D5638C2032083313 +:1015D0005B01EB18DA71638C3E3A08335B01EB1860 +:1015E0001A7196E7638C08335B01EB189B79DB0675 +:1015F0008FD51022638C08335B01EB181A71638C52 +:1016000008335B01EB18DB799B0600D481E7638C20 +:10161000921808335B01EB18DA71638C1F3A0833B8 +:101620005B01EB18DCE70822A38C934201D8A28C63 +:1016300092B2024900234C31BAE6C04600000020B5 +:10164000F8B50B4F060038001C300D00FFF7F1FD18 +:101650002C00002808D1050008E022003100F869BC +:10166000FFF73CF9241A3618002CF6D12800F8BDF3 +:101670007800002070B5084C050020001C300E00DA +:10168000FFF7D7FD03000020834204D03200290079 +:10169000E069FFF723F970BD7800002010B5084C11 +:1016A00020001C30FFF7C5FD03000020834205D059 +:1016B0004823E269FF33D05CC007C00F10BDC046AD +:1016C000780000200D4A0E4870B5824206D10D4ABE +:1016D0000D4B002193420DD100F01AF80B4C002362 +:1016E0009442F4D0D1188842F1D9E55804330D6002 +:1016F000F8E702C39342FCD3EEE7C04600000020A7 +:101700005C000020AC0200205C000020801F000074 +:10171000F0B50B498BB00B6800AF013320D00948FE +:10172000094BC9B2C36200291AD1084B084A1B7879 +:10173000DB07DB0F0ED011600123303003700FE0A8 +:1017400000200000F80000200420000038040040C1 +:10175000FC7F00201468DA498C4200D028E2136034 +:101760001E22D8494B6893431C3A13434B6008230D +:10177000D549886903438B61D448D54B9882988AB0 +:1017800010439882D8681042FCD00122D1480270E0 +:101790000478144203D0447864B2002CF8DB0122B0 +:1017A0008260427852B2002AFBDBCB4A4260427828 +:1017B00052B2002AFBDB8222D2014280427852B22E +:1017C000002AFBDB80249A8CA2439A841022DC68D6 +:1017D0001442FCD0C14ADA621022DC681442FCD008 +:1017E0009C8CBF4A22439A841022DC681442FCD0AD +:1017F00002229C8C802522439A844022DC682C4261 +:10180000FCD0DC681442F9D01022DC681442FCD011 +:101810000023836043785BB2002BFBDBB14B43605A +:101820007B6043785BB2002BFBDB00230B724B72B7 +:101830008B72CB7262B6AC4B438043785BB2002BA9 +:10184000FBDB04230A6AA94C13430B6201232268C1 +:10185000134323602368DB07FCD4E369DB07F9D477 +:101860001423FF222360E36893431A00EF231343FA +:10187000E3600223226813432360E3699B07FCD4DF +:101880003022638B93431A00102313436383E5696B +:101890006D07ED0FFBD101260F200221944A13782A +:1018A00033431370934B1A7882431A701A780A43A1 +:1018B0001A70914A1178314311701A7802401A70E7 +:1018C000202219780A380A431A70FEF72DFF0028E3 +:1018D0003BD0CE2101400520FEF718FF3000FEF777 +:1018E00023FF30239843C1B23000FEF70FFF2800DA +:1018F000FEF71AFF782301009943483B1943C9B208 +:101900002800FEF703FF2800FEF70EFF0721014322 +:10191000C9B22800FEF7FAFE0220FEF705FF01001B +:1019200002203140FEF7F2FE0420FEF7FDFE032107 +:101930000140982001439438FEF7E8FE0222236814 +:1019400093432360E3699B07FCD40F226B49012575 +:101950000B78604C1A4070231343694A0B7013785C +:101960002B43137080235B00A36080237A681B03E2 +:1019700013436360FEF77EFD08232900F818BD605D +:10198000FEF75AFF000EB02804D02800FEF7FCFC3A +:10199000FEF750FC5B4D2B0030331B78002B0AD038 +:1019A000594B1A6882F30888FF229343574A936081 +:1019B000EB6A1B6818472023434A0F20D1690B4369 +:1019C000D361012352490A781A430A70514A1178A7 +:1019D0008143117006211678314311704E490E78FB +:1019E00033430B70137803401370602311780B435B +:1019F00013704A4B638063785BB2002BFBDB0123DF +:101A0000474E327813433370B378DB07FCD41F2181 +:101A1000444A13685B0B0B408B4200D10523308D89 +:101A2000414C0B409B0120400343338513689B0CC2 +:101A30000B401F2B00D1023B1F20318D03408143FF +:101A40000B43338513680722DB0D13407A60934202 +:101A500000D103230721328D0B4034491B030A4078 +:101A600013437F2233853378314813403370042386 +:101A70003278002113430C22337070623389934310 +:101A8000338133890B3A934333817F3200F0A6F8D8 +:101A90000021284C284BE6616362022321843278BE +:101AA0001A48134380223370C026244B52001A6018 +:101AB000234A244B36065360036A1B021B0A43E089 +:101AC0003581730700400041000400400C0600000F +:101AD00000080040000C004001050100B805FF7D32 +:101AE000040A000000070300144000000008004240 +:101AF0004844004134440041494400413D440041D0 +:101B00005B440041F80000200020000000ED00E0F0 +:101B1000584400413C440041594400410640000003 +:101B200000500041246080003FF8FFFFFF8FFFFF5F +:101B30002C0200207800002033120000884400416D +:101B400010E000E0E70300003343036207230126AF +:101B5000916013602000636A1C309847002801D010 +:101B6000194B1E70184B1B78002BF3D0174B1A0023 +:101B70002C32626008224833BA1843CB43C243CBAD +:101B800043C203CB03C20821114A79189368743405 +:101B90005B035B0F9B00CB586B61926892B253431F +:101BA0002B6100232B607A332370FEF75DFFFCE787 +:101BB000084B013B002BFCD1074B1160013B002B74 +:101BC000FCD11360B8E5C04629010020441C000088 +:101BD00000400041C409000048E801000300121859 +:101BE000934200D1704719700133F9E730B50024F2 +:101BF000A24201D1002005E0035D651C0C5DA342FB +:101C000001D0181B30BD2C00F2E7002310B59A421A +:101C100000D110BDCC5CC4540133F8E70023C25C92 +:101C20000133002AFBD1581E70470000F8B5C046AA +:101C3000F8BC08BC9E467047F8B5C046F8BC08BC66 +:101C40009E467047322E30005B41726475696E6F3C +:101C50003A58595A5D00000012010002020000408B +:101C600041235600000201020001040309040000A0 +:101C7000150A0000590900009D160000F90900002E +:101C800075160000F9090000411600000800000068 +:101C90001000000020000000400000008000000054 +:101CA000000100000002000000040000010000002C +:101CB0000000000001000000090000000300000017 +:101CC0000000000004000000050000000400000007 +:101CD00005000000060000000800000006000000EB +:101CE00007000000040000000800000001000000E0 +:101CF000090000000A000000020000000B000000C4 +:101D00000C0000000B0000000C0000000D000000A3 +:101D10000F0000000D0000000E0000000B0000008E +:101D20000F00000001000000090000000000211069 +:101D3000422063308440A550C660E7700881299135 +:101D40004AA16BB18CC1ADD1CEE1EFF131121002DD +:101D500073325222B5529442F772D6623993188385 +:101D60007BB35AA3BDD39CC3FFF3DEE362244334A9 +:101D700020040114E664C774A44485546AA54BB5D5 +:101D800028850995EEE5CFF5ACC58DD5533672267D +:101D900011163006D776F6669556B4465BB77AA725 +:101DA00019973887DFF7FEE79DD7BCC7C448E558C9 +:101DB0008668A7784008611802282338CCC9EDD975 +:101DC0008EE9AFF9488969990AA92BB9F55AD44A1D +:101DD000B77A966A711A500A333A122AFDDBDCCBC5 +:101DE000BFFB9EEB799B588B3BBB1AABA66C877CE9 +:101DF000E44CC55C222C033C600C411CAEED8FFD15 +:101E0000ECCDCDDD2AAD0BBD688D499D977EB66EBC +:101E1000D55EF44E133E322E511E700E9FFFBEEF64 +:101E2000DDDFFCCF1BBF3AAF599F788F8891A98126 +:101E3000CAB1EBA10CD12DC14EF16FE18010A10010 +:101E4000C230E3200450254046706760B983989300 +:101E5000FBA3DAB33DC31CD37FE35EF3B102901260 +:101E6000F322D2323542145277625672EAB5CBA5CC +:101E7000A89589856EF54FE52CD50DC5E234C324B0 +:101E8000A01481046674476424540544DBA7FAB7A0 +:101E90009987B8975FE77EF71DC73CD7D326F23600 +:101EA0009106B01657667676154634564CD96DC9EC +:101EB0000EF92FE9C899E9898AB9ABA94458654850 +:101EC00006782768C018E1088238A3287DCB5CDB40 +:101ED0003FEB1EFBF98BD89BBBAB9ABB754A545AA0 +:101EE000376A167AF10AD01AB32A923A2EFD0FED0C +:101EF0006CDD4DCDAABD8BADE89DC98D267C076CF0 +:101F0000645C454CA23C832CE01CC10C1FEF3EFFDF +:101F10005DCF7CDF9BAFBABFD98FF89F176E367E3F +:101F2000554E745E932EB23ED10EF01E7600200008 +:101F300041756720203920323031380031313A3153 +:101F4000373A333000580A0D00790A0D00590A0D4E +:101F5000005A00230A0D003E0041726475696E6FDD +:101F6000204C4C430041726475696E6F204D4B529A +:101F7000205669646F722034303030000000000059 +:101F800001140000FFFFFFFF09024300020100806F +:101F9000FA090400000102020000052400100104F7 +:101FA0002402000524060001052401000107058321 +:101FB000030800FF09040100020A00000007058170 +:101FC00002400000070502024000000000C20100BC +:0C1FD00000000800690000004100000053 +:04000003000016C51E +:00000001FF diff --git a/bootloaders/mkrwan1300/samd21_sam_ba_arduino_mkrwan1300.bin b/bootloaders/mkrwan1300/samd21_sam_ba_arduino_mkrwan1300.bin new file mode 100755 index 0000000..b49ec8b Binary files /dev/null and b/bootloaders/mkrwan1300/samd21_sam_ba_arduino_mkrwan1300.bin differ diff --git a/bootloaders/mkrwan1300/samd21_sam_ba_arduino_mkrwan1300.hex b/bootloaders/mkrwan1300/samd21_sam_ba_arduino_mkrwan1300.hex new file mode 100644 index 0000000..bff8576 --- /dev/null +++ b/bootloaders/mkrwan1300/samd21_sam_ba_arduino_mkrwan1300.hex @@ -0,0 +1,404 @@ +:10000000FC7F00200D060000FD0500000106000039 +:1000100000000000000000000000000000000000E0 +:1000200000000000000000000000000005060000C5 +:100030000000000000000000090600004D0700005D +:1000400010B5064C2378002B07D1054B002B02D0AE +:10005000044800E000BF0123237010BD5C000020B5 +:1000600000000000B018000008B5084B002B03D0BA +:100070000748084900E000BF07480368002B03D089 +:10008000064B002B00D0984708BDC046000000007A +:10009000B0180000600000205800002000000000A0 +:1000A000154A164B1178002909D115491878097895 +:1000B0004118C9B21970802012494003C8611178F3 +:1000C0000131C9B211701978F02902D819780929BB +:1000D00009D80B4908784042C0B2087018780978EE +:1000E0004118C9B2197012781B789A4203D1802244 +:1000F000044B5203DA6170477800002001000020B1 +:10010000000000200044004110B5C3699C07FCD4E6 +:1001100003680224A3430360C46901231C42FBD18A +:100120000468234303600368DC07FCD4C46901232B +:100130001C42FBD1C469DC401C42F7D1084B1A4376 +:100140000260C3695A07FCD4C0239B0243608181CB +:10015000C3699C07FCD4036802221343036010BDEB +:1001600004000040037EDA07FCD5018570470000DB +:10017000027E01235107FBD5428B1A4207D1428BE5 +:10018000DA401A4203D1428B92081A4202D0034B42 +:1001900001221A70008DC0B27047C046790000205D +:1001A00070B50368041C988B1A1C0821FF320842A2 +:1001B00026D0802099839872112353704021144BCC +:1001C000917150715E68134DC0202E40800506432A +:1001D0005E605E693540284358610F4818600F48DB +:1001E00018615D680E4828408025AD02284358609C +:1001F0005868800B8003586000235171237105E01B +:10020000137ADA0602D5201C00F0DAFA207970BDE4 +:1002100098010020FFFFFF8F9800002018010020A8 +:10022000FF3F00F0002303714371044B01608360C2 +:100230000B78022213430B707047C046A1010000E7 +:1002400038B5364B2021DA6901200A43DA61344B94 +:1002500006241A7802431A70324B0F221978914300 +:1002600019701978214319702F490C7820430870B0 +:1002700019780A401A701A7860210A431A702B4BB9 +:100280002B4A5A805A7852B2002AFBDB294B0121B3 +:100290001A780A431A709A78D107FCD42648026863 +:1002A000510B1F221140914200D1052111408C01B8 +:1002B0001D8D22492940214319850468A10C0A405B +:1002C0001F2A00D11D221C8D1F210A408C4322436E +:1002D0001A8502680721D20D0A408A4200D1032202 +:1002E0000A40188D1103164A02400A431A851978EC +:1002F0007F220A401A701A78042112480A431A70A1 +:1003000058621A890C218A431A811A8901218A4369 +:100310001A810021802201F046F938BD0004004016 +:10032000584400413C44004159440041000C004005 +:100330000640000000500041246080003FF8FFFFAD +:10034000FF8FFFFF98010020F7B5141C1F4A5F01C3 +:1003500001971D1CD319061C5869271C4000400F2B +:1003600003301033C74006D00F1C80225968120694 +:100370000A435A6009E02F1C7B1E9F41144BBF01AA +:10038000FF18381C221C01F005F901990F480835A7 +:1003900042181761131C5269A104920B890C920335 +:1003A0000A435A6159690B4A0A405A616B01F318B2 +:1003B0000222DA715979802252420A435A716B0142 +:1003C000F318DB799A07FAD5201CFEBD98010020AE +:1003D00018010020FF3F00F0F8B51A4E051C3378D5 +:1003E000141C002B12D1184B184A1A645A6C920B29 +:1003F00092035A64586C164A02405A64A2235B0066 +:10040000EA5C40200243EA54012333704827FF3757 +:10041000EA5D0123134012D00B4B5A6C9204920CEC +:10042000A24202D25C6CA404A40C081C221C074942 +:1004300001F0B0F80123EB550023337000E01C1CE1 +:10044000201CF8BD7A00002098010020D800002070 +:10045000FF3F00F0FF3083792022002900D11022D5 +:100460001343837170470000084BFF305A69920BA9 +:1004700092035A6102230372827980235B42134301 +:100480008371037A9A07FCD57047C0469801002013 +:1004900080235B421943C9B28172704770B5A023B3 +:1004A00003225B00C254134B134A5C6CC0211440FE +:1004B00089050C4346255C64FF35402444550F4DA7 +:1004C00030261D6490256D0046555D6B154029430F +:1004D000922559636D0080214155094D1D63B0255A +:1004E0006D0044555C6F22405A67B2235B00C154D3 +:1004F00070BDC04698010020FFFFFF8FD80000208C +:1005000058010020024B5B785BB2002BFADB70478E +:10051000000C0040024BDB68DA06FBD57047C04692 +:1005200000080040F8B52A4B1E2259689143022268 +:1005300011435960274B28491E1C9982998A0A4306 +:100540009A82F3680227234C3B42FAD0234D0123C1 +:10055000AB60FFF7D7FF224B6B60FFF7D3FF82231F +:10056000DB016B80FFF7CEFFA38C80229343A38433 +:10057000FFF7D0FF1B4BE362FFF7CCFFA38C1A4AB7 +:100580001343A384FFF7C6FFA38C1F43A784F3681C +:100590001A06FCD50F4BDB685A06F8D50024FFF786 +:1005A000B9FFAC60FFF7AEFF104B6B60FFF7AAFF1F +:1005B0000F4B104AC0215A600F4A0906106A000208 +:1005C000000A0143116207229C601A60F8BDC04610 +:1005D00000400041000800400C060000000C0040F4 +:1005E00001050100B805FF7D040A000000070300B3 +:1005F00010E000E0E703000000ED00E00EBEFEE7C3 +:100600000DBEFEE705BEFEE702BEFEE70E4A0F483E +:1006100038B5824204D10E4A0E4B93420ED10AE005 +:100620000D4C9442F7D00023D1188842F3D9E558F5 +:1006300004330D60F8E700F011F804E09342FAD2B9 +:10064000002102C3FAE7FEE7000000205C00002062 +:10065000A80300205C000020B418000038B5304B1F +:100660001A681C1C013221D02E4A191D1160D9B202 +:1006700000291BD12C4A1078012210402B4A0AD1A4 +:1006800015682B498D4201D110600FE01160294996 +:1006900001390029FCD11160226882F30888FF2209 +:1006A0009343254A93601E4B5B681847FFF73AFF58 +:1006B00062B600F09DFD00F04FF8204B80225203FF +:1006C0009A601F4B1F4A041C5A601B4AC021106AC3 +:1006D00009060002000A0143116200229A60072203 +:1006E0001A60A368201C9847174B002801D00122EC +:1006F0001A701A78002A05D0002000F08BFA00F05A +:1007000003FBFCE71B78002BEBD100F0E5FD002894 +:10071000E7D0012000F07EFA00F0F6FAFCE7C046D0 +:10072000002000001802002038040040FC7F002058 +:100730003581730748E8010000ED00E00044004106 +:1007400010E000E0E70300007B00002008B5FFF7A1 +:10075000A7FC00F0C3FA08BD10B5054B054C23609B +:10076000FFF76EFD201C2168FFF75CFD201C10BD0B +:10077000005000411C02002070B5051CC0B0081CD0 +:10078000161C0C1C00F017FF40006A4603230230C1 +:100790005370107076080123E218013A11785A005C +:1007A000002906D1281C69460023FFF7CDFD40B083 +:1007B00070BDB342F6DA684681520133ECE70000BF +:1007C000F7B5BA4A04681378B949271CFF37051CE6 +:1007D000102038720B705378B648B74E0370937878 +:1007E0003380D178338809020B4333801179B34BBE +:1007F0001980517918880902084318809079B04906 +:100800000880D2790888120202430A8040227A7155 +:10081000A84F3A78A64F120238780F1C0243A94815 +:100820008446181C624500D1C2E020DC80214900CA +:100830008A4200D16EE109DC812A00D192E0822A4D +:1008400000D195E0802A00D064E18BE081235B0039 +:100850009A4200D1CFE000DA58E1C0239B009A42CF +:1008600000D157E1984B9A4200D14FE152E19023D9 +:100870001B019A4269D015DCD023DB009A4222D0BA +:1008800088231B019A4269D0A023DB009A4200D042 +:1008900040E1201CFFF7E8FD3188286889B2FFF7A6 +:1008A000F7FD3BE1894B9A4200D12FE100DC31E1B9 +:1008B000874B9A4200D11DE1864B9A4200D029E134 +:1008C00033886B7122E133881B0A012B08D10B8816 +:1008D00012222868934201D80A8892B27E4911E117 +:1008E00033881B0A022B08D10B88432228689342C5 +:1008F00001D80A8892B2794904E133881B0A032B94 +:1009000000D007E13388DBB2012B17D0002B07D0D2 +:10091000022B00D0FEE00A882868D2B2704911E0AC +:10092000042201A86F4900F035FE3B8804222868A4 +:10093000934201D83A8892B201A9E3E00A88286874 +:100940006949D2B2FFF718FFE8E03388201C2B7109 +:10095000FFF78AFD201CFFF7A1FDDFE0291C01C97C +:100960000122CFE0614900230B8028680222CAE0FF +:100970005E4900220A801888502210405C4A10709C +:100980001E880F20304018801888032800D9C1E045 +:1009900012781B8808335B01E418A379002A01D080 +:1009A0009B0600E0DB06DB0F0B8028680222A9E033 +:1009B00019887F2291434E4AC9B2117018880F21BD +:1009C000014019803188002900D0A3E0198800294E +:1009D00000D19FE01988032900D99BE012781B8879 +:1009E00008335B01E318002A02D020225A718DE0FF +:1009F000102159718AE002887F239A433C4BD2B27E +:100A00001A7001880F220A4002803288002A00D022 +:100A100080E00288002A00D17CE00288032A00D905 +:100A200078E01B78002B1FD0038808335B01E318A4 +:100A30009B799A066AD50388202208335B01E31864 +:100A40001A71038808335B01E318DB795F065DD513 +:100A50000388402208335B01E318DA71038802221D +:100A600008335B01E3181EE0038808335B01E318D9 +:100A70009B79D9064AD50388102208335B01E31815 +:100A80001A71038808335B01E318DB799A063DD5B8 +:100A90000388202208335B01E318DA7103880122FE +:100AA00008335B01E3181A7130E0C046980000205B +:100AB0007D000020820000208400002086000020AD +:100AC000800000200203000001030000212000003C +:100AD000A1210000212200000416000004000020D3 +:100AE000EC150000DC150000E01500007E00002081 +:100AF0007C0000200B8808222868934201D80A88CD +:100B000092B207490023FFF71FFC07E0201CFFF704 +:100B1000ABFC03E0201C0121FFF79CFCF7BDC046A5 +:100B20004800002007B5054B0122019001A9186873 +:100B3000131CFFF709FC01200EBDC0461C0200205B +:100B400013B5054B6C4607341868211C0122FFF7CA +:100B500043FC207816BDC0461C02002010B5074C8F +:100B6000201CFFF71DFB031C0020834205D02268D8 +:100B70004823FF33D05C0123184010BD1C02002025 +:100B800010B5054A0C1C031C191C10680123221CFB +:100B9000FFF7DAFB201C10BD1C02002070B5084CCA +:100BA000061C201C0D1CFFF7FBFA0023984205D001 +:100BB0002068311C2A1CFFF70FFC031C181C70BD99 +:100BC0001C020020F8B50C4C051C201C0E1CFFF765 +:100BD000E7FA0023271C341C98420AD0002C07D0C7 +:100BE000291C221C3868FFF7F7FB241A2D18F5E79B +:100BF000331C181CF8BDC0461C02002008B5031C9D +:100C0000081C111C9847024B64221A8008BDC0467C +:100C10008C000020012805D1054B064A1A60064BBE +:100C2000187004E0002802D1044A014B1A60704792 +:100C30008C0200203816000094000020841600006A +:100C400030B50A1C1C4985B00978031C00292AD03C +:100C5000042A01D1006804E0022A01D1008800E0E2 +:100C60000078520004A98B180B3B9C1AA3420BD0AE +:100C70000F210140092902D83025294300E03731EE +:100C800019700009013BF1E701A930230B707823AB +:100C90004B700A208B1898700D20D870074B0432C7 +:100CA0001B68D86803E005490968C868191CFFF784 +:100CB000A5FF05B030BDC046880000208C02002092 +:100CC00072B6EFF30883044A1360036883F308885D +:100CD000436818477047C04690020020084B1A88A6 +:100CE000002A03D01A88013A92B21A80054B1A885A +:100CF000002A03D01A88013A92B21A807047C0467F +:100D00008C0000208A000020F0B591B008A9CC4AE0 +:100D10000B1C31CA31C351CA51C360CA60C3C94B2D +:100D2000C9489A687A255203520F92005258C7490F +:100D300002609C68A4B262430C60C54900240A604A +:100D4000C44A1460C44C2570C44CC54D2368281C8B +:100D50001B6940219847002802D0C24B64221A80A8 +:100D6000C14B00221860C14B1D60C14BC04DBE4F2E +:100D70001A602A683B689A42E6D2BC4B1B681A7814 +:100D8000FF2A00D114E2232A00D0EBE1B94E3378D8 +:100D9000002B06D0B14BB8491B680222D868FFF778 +:100DA0002DFFAD4B1B78532B3CD13B682A689342F7 +:100DB0001ED9AE4801322A609A1AB04B01681B68EE +:100DC00001310160AE4E9A4201D2326000E03360E0 +:100DD000A04832680068049000F0DCFB33682968A2 +:100DE0005A182A60A14A1668F1181160A54A1370B2 +:100DF0002B68013B2B609D4B1A68013A1A60A14B8E +:100E00009E4A1B7811688B420AD222689148C91AFF +:100E1000006892699047002802D0924B64221A80A1 +:100E2000C0468DE1522B0AD18A48944A2368006853 +:100E300011685B69039098476422934B0DE04F2B38 +:100E400005D1844B8D4A1B6812681A7078E1482BD3 +:100E500005D1804B894A1B6812681A8070E1572BB4 +:100E600005D17C4B854A1B6812681A6068E16F2BBC +:100E700003D1784B0121186807E0682B08D1754B26 +:100E80007E481B6802211B880360FFF7D9FE57E1EB +:100E9000772B06D16F4B79481B6804211B680360D0 +:100EA000F3E7472B13D1754B1868FFF709FF774B12 +:100EB0001B6883F3088862B6754B1B78002B00D142 +:100EC0003EE1664B06201B681B68984738E1542BAF +:100ED00004D101233370614B1B6864E04E2B0CD1AD +:100EE0003378002B06D15D4B63491B680222D8681A +:100EF000FFF784FE0023337022E1562B57D123687D +:100F00006449D8680122FFF779FE23686249D868EE +:100F10000322FFF773FE614D2368291CD868012264 +:100F2000FFF76CFE23685E49D8680D22FFF766FE66 +:100F30002368291CD8680122FFF760FE4B4F4C4DF7 +:100F40005849002339602B603A1C281C13685E1C2A +:100F500016601B780593002B03D0036801330360F0 +:100F6000F4E73E4E2A683368D868FFF747FE3368D7 +:100F70004A49D8680122FFF741FE059929604A498C +:100F800039603A4A1368581C10601B78002B04D053 +:100F9000374B1A6801321A60F3E733682A68D86859 +:100FA000FFF72CFE3368D86833490222C6E0334A83 +:100FB000582B17D1244E264D366813682A68B10085 +:100FC00093420AD21F4D5808E861384828801D4DC9 +:100FD000287DC607FBD55B18F2E7204B34491B6818 +:100FE000D868AAE0592B79D112681A4B3149002AE6 +:100FF00002D11B680B606CE0124D086819686B68C1 +:10100000104E8025AB4392087360002A61D02A4BB2 +:101010000C4D2B800B4E337DDD07FBD500230A4D95 +:101020002D680195AD08AB4203D3244D054E3580A4 +:1010300046E09342F9D09D00465901334E51EEE708 +:101040001816000000400041440200203C0200202D +:101050003802002088020020340200208C02002088 +:10106000480200208A0000202C02002030020020CC +:101070004002002088000020781600009402002022 +:1010800098020020280200208C00002090020020FE +:1010900094000020541600007D1600005616000033 +:1010A000A0160000581600006416000002A5FFFFFD +:1010B0006D1600009000002044A5FFFF04A5FFFF6F +:1010C0003F4E357DEE07FBD59D0049194019D21AD8 +:1010D0009BE73C4B3C491B68D8682EE05A2B2FD12C +:1010E0003A4B17681D680026EF19BD4206D02878D4 +:1010F000311C00F013F90135061CF6E7314B344979 +:101100001B680122D868FFF779FD07230F223240C0 +:10111000111C36093031092A00DD07311820C018AA +:101120006A468154013BF1D2236806A9D868082297 +:10113000FFF764FD23682749D8680322FFF75EFDA7 +:10114000254B7A221A70254B00221A60244B1B78FB +:1011500093422DD01B4B23491B680122D868FFF70F +:101160004DFD25E0111C3039C8B21C4B092804D8AC +:101170001D682A01114319601AE0111C4139052923 +:1011800003D81E68373A310106E0111C6139052980 +:1011900004D81868573A01010A4308E02C2A03D101 +:1011A0000A4A1968116001E00B490A7000221A60AE +:1011B0000D4B1A6801321A600C4B1A680132D5E5E2 +:1011C000004000418C0200207116000088020020BF +:1011D00075160000771600003402002094020020EB +:1011E000880000207B160000400200203002002012 +:1011F00010B51C4B01201A78032402431A701A4BB5 +:101200000F221978914319701978214319701749E1 +:101210000C782043087019780A401A701A78302127 +:101220000A431A70124B80211A6A0A431A62114B40 +:10123000114A5A805A7852B2002AFBDBC4220F4866 +:101240000F499203FEF760FF0E4A002313700E4A07 +:1012500013700E4A13700E4A13700E4A13700E4A22 +:10126000137010BDD6440041BB440041D744004137 +:1012700000040040000C004019400000001C004227 +:101280002AF600009C020020230300209D0200207B +:10129000A0020020240300202103002008B5C1B2D1 +:1012A0000248FEF75FFF012008BDC046001C004257 +:1012B000024B187E4007C00F7047C046001C00421A +:1012C00008B5FFF7F5FF0028FBD00248FEF750FFF6 +:1012D00008BDC046001C004208B5FFF7E9FF002327 +:1012E000984205D0FFF7ECFF031C233B5A425341C1 +:1012F000181C08BD70B5041C0D1C4618B44204D05F +:101300002078FFF7CBFF0134F8E7281C70BD10B53B +:10131000041CFFF7D5FF2070012010BD0B0A5840B8 +:10132000034B4000C05A0902484080B27047C04693 +:10133000AE160000F7B50024051C0F1C261CBC428D +:1013400020D0FFF7BDFF114BC0B21B780190002BDE +:101350001AD1311CFFF7E2FF0D4B061C1A88002A38 +:1013600004D10C4A11782A1C002907D001996A1C63 +:101370002970802F02D11988013919800134A4B253 +:10138000151CDCE7301C00E00120FEBD210300201D +:101390009E02002022030020F0B53E4E85B00022C0 +:1013A00003900C1C32703C4B914201D1012201E0B0 +:1013B0003A490C801A707F231C4201D080349C4330 +:1013C000FFF77EFF3378C0B2002B07D000253570C1 +:1013D000FFF776FF3378C0B2AB4236D1432803D053 +:1013E000712853D01528EBD1012300930120FFF77A +:1013F00055FF0098FFF752FF00998025C843C0B2FF +:10140000FFF74CFF039B00270293244A1388002B0D +:101410001DD1214901930978002918D10198FFF7BE +:101420003DFF391C0198FFF779FF013D071C002D96 +:10143000EBD1000AC0B2FFF731FFF8B2FFF72EFF81 +:10144000FFF73EFF3378002B0AD035701FE002997A +:10145000013B09781380029B019101330293DDE780 +:10146000C0B2062807D1009B03990133DBB280315B +:101470000093803C0391002CB8D10420FFF70EFFAD +:10148000FFF71EFF044B01251C7000E00025281CFF +:1014900005B0F0BD21030020220300209E020020A1 +:1014A000F0B5384C87B0002301902370994201D1E8 +:1014B000012301E0344A1180344A6426137043202A +:1014C000FFF7ECFE324FFFF7F3FE002803D1002FA9 +:1014D00003D0013FF7E7002F03D1013E002EEED1EC +:1014E0004DE00125FFF7ECFE2378002B38D1C0B288 +:1014F0000290012805D004283DD10620FFF7CEFE3A +:1015000039E005AE0221301CFFF714FF019880215D +:10151000FFF710FF23780390002B18D1FFF7D0FEC0 +:101520000702FFF7CDFEBFB223783F18BFB2012BF1 +:101530000DD0039B9F4207D13378AB4204D1EB43DC +:101540007278DBB29A4204D01820FFF7A7FE00237E +:1015500003E00620FFF7A2FE029B2278002A02D0B9 +:10156000002626700BE0012B05D1019A6B1C8032FE +:10157000DDB20192B6E7054A002313700126301C44 +:1015800007B0F0BD210300209E02002022030020AE +:1015900000350C0010B50023934203D0CC5CC4543A +:1015A0000133F9E710BD031C8218934202D0197071 +:1015B0000133FAE770470023C25C0133002AFBD1F4 +:1015C000581E7047F8B5C046F8BC08BC9E46704728 +:1015D000F8B5C046F8BC08BC9E4670470403090431 +:1015E00041726475696E6F204C4C430041726475A2 +:1015F000696E6F204D4B522057414E2031333030B1 +:1016000000000000120100020200004041235300CC +:1016100000020102000100000800000010000000AC +:1016200020000000400000008000000000010000D9 +:1016300000020000000400009D120000C112000022 +:10164000B1120000F51200000F1300009913000002 +:10165000A114000076002000417072203131203248 +:101660003031390031333A30393A353500580A0DC6 +:1016700000590A0D005A00230A0D003E00322E3098 +:1016800000000000250B0000410B00005D0B000076 +:10169000810B00009D0B0000810B0000C50B0000BA +:1016A0005B41726475696E6F3A58595A5D0000006B +:1016B0002110422063308440A550C660E770088145 +:1016C00029914AA16BB18CC1ADD1CEE1EFF13112BC +:1016D000100273325222B5529442F772D662399395 +:1016E00018837BB35AA3BDD39CC3FFF3DEE362240C +:1016F000433420040114E664C774A44485546AA5E5 +:101700004BB528850995EEE5CFF5ACC58DD553369B +:10171000722611163006D776F6669556B4465BB734 +:101720007AA719973887DFF7FEE79DD7BCC7C4486B +:10173000E5588668A7784008611802282338CCC984 +:10174000EDD98EE9AFF9488969990AA92BB9F55AFB +:10175000D44AB77A966A711A500A333A122AFDDBD4 +:10176000DCCBBFFB9EEB799B588B3BBB1AABA66CCB +:10177000877CE44CC55C222C033C600C411CAEED24 +:101780008FFDECCDCDDD2AAD0BBD688D499D977EDB +:10179000B66ED55EF44E133E322E511E700E9FFF74 +:1017A000BEEFDDDFFCCF1BBF3AAF599F788F88912A +:1017B000A981CAB1EBA10CD12DC14EF16FE180100E +:1017C000A100C230E3200450254046706760B98311 +:1017D0009893FBA3DAB33DC31CD37FE35EF3B1025E +:1017E0009012F322D2323542145277625672EAB521 +:1017F000CBA5A89589856EF54FE52CD50DC5E234AE +:10180000C324A01481046674476424540544DBA7F0 +:10181000FAB79987B8975FE77EF71DC73CD7D326FD +:10182000F2369106B01657667676154634564CD980 +:101830006DC90EF92FE9C899E9898AB9ABA944584D +:10184000654806782768C018E1088238A3287DCB50 +:101850005CDB3FEB1EFBF98BD89BBBAB9ABB754A9D +:10186000545A376A167AF10AD01AB32A923A2EFDE0 +:101870000FED6CDD4DCDAABD8BADE89DC98D267CED +:10188000076C645C454CA23C832CE01CC10C1FEF30 +:101890003EFF5DCF7CDF9BAFBABFD98FF89F176E3D +:1018A000367E554E745E932EB23ED10EF01E000071 +:0418B0000000000034 +:1018B40001140000090243000201008032090400FF +:1018C40000010202000005240010010424020005A6 +:1018D400240600010524010001070583030800FF15 +:1018E40009040100020A000000070581024000000B +:1018F400070502024000000000C2010000000800C9 +:0C1904006900000041000000000000002D +:040000030000060DE6 +:00000001FF diff --git a/bootloaders/mkrwan1300/samd21_sam_ba_arduino_mkrwan1310.bin b/bootloaders/mkrwan1300/samd21_sam_ba_arduino_mkrwan1310.bin new file mode 100755 index 0000000..42b95bb Binary files /dev/null and b/bootloaders/mkrwan1300/samd21_sam_ba_arduino_mkrwan1310.bin differ diff --git a/bootloaders/mkrwan1300/samd21_sam_ba_arduino_mkrwan1310.hex b/bootloaders/mkrwan1300/samd21_sam_ba_arduino_mkrwan1310.hex new file mode 100644 index 0000000..7979333 --- /dev/null +++ b/bootloaders/mkrwan1300/samd21_sam_ba_arduino_mkrwan1310.hex @@ -0,0 +1,508 @@ +:10000000FC7F0020E10B0000D10B0000D50B0000AD +:1000100000000000000000000000000000000000E0 +:10002000000000000000000000000000D90B0000EC +:100030000000000000000000DD0B0000350D000096 +:1000400010B5064C2378002B07D1054B002B02D0AE +:10005000044800E000BF0123237010BD5C000020B5 +:1000600000000000381F000008B5084B002B03D02B +:100070000748084900E000BF07480368002B03D089 +:10008000064B002B00D0984708BDC046000000007A +:10009000381F000060000020580000200000000011 +:1000A000094A0323184003040849506808401843CC +:1000B000074B5060D0694007C00F04D0013B002BB4 +:1000C000F8D101204042704700080042FFFFFCFFCA +:1000D00052C3000070B5400008431D4BC0B21D4C18 +:1000E0000325668B221C36092E40012E07D1546A47 +:1000F000E40AE4022043506200290DD010E0648B32 +:1001000024092540022DF2D0013B9A1CE7D10020A2 +:100110001CE0013B581CFAD4117EC807F9D511E048 +:10012000107E012440080B4920400BD1002BEEDB50 +:100130000D7E013B2542F3D04A68C0239B02134346 +:100140004B6003E0538B01209B08984370BDC04671 +:1001500050C300000008004238B5284A284B5A8096 +:100160005A7852B2002AFBDB264B04211A6A264D2C +:100170000A431A622B68012213432B602A68012369 +:10018000214C1A42FAD1E2691A42F7D114232360B2 +:1001900041001E4801F0F2FC421EE068FF231A40B5 +:1001A00098431043E0602368022213432360EA6906 +:1001B000154B9107FBD45A8B30218A4310210A43F7 +:1001C0005A83EB6901205A07FBD4114B02241A7899 +:1001D00002431A700F4B0F22197891431970197846 +:1001E000214319700C490C782043087019780A4093 +:1001F0001A701A7820210A431A7038BD1440000082 +:10020000000C00400004004000080042006CDC02CA +:10021000484400413444004149440041044B022118 +:100220001A688A431A60DA699107FCD47047C0469D +:1002300000080042F7B50D1C019234D01B4F00237B +:1002400001213B70FFF746FF00282BD001233B70B4 +:10025000174C237E9907FBD5164A174B11780126B8 +:1002600019706268AE4212D0144B022013406360D2 +:10027000FFF716FF3B785A1C3A70227E9107FCD597 +:100280000C4901360A780C49F6B2CA54E9E78023D2 +:10029000DB0213436360019A002A04D00320FFF7B6 +:1002A000FFFE00E0051C281CFEBDC04678000020B3 +:1002B00000080042280800429D000020FFFFFBFFCD +:1002C000024B00221870024B1A7070477A0000200F +:1002D00079000020F8B51E4B051C00211878FFF7A7 +:1002E000F9FE002804D10320FFF7DAFE02242CE0F7 +:1002F000184A1678331C002B16D01748F11A405CA8 +:100300001649174C087017480121077E0F4206D185 +:10031000013C002C10D0408B0842F4D00CE0408B04 +:10032000800808420ED007E013701C1C002D0CD072 +:100330000320FFF7B5FE08E0032013700324FFF746 +:10034000AFFE02E0013BDBB2D5E7201CF8BDC046A2 +:100350007A000020790000207B000020280800425D +:1003600052C3000000080042034A1378591C117060 +:10037000024AD05401207047790000207B00002001 +:10038000154A164B1178002909D1154918780978B2 +:100390004118C9B21970802012494003C861117810 +:1003A0000131C9B211701978F02902D819780929D8 +:1003B00009D80B4908784042C0B20870187809780B +:1003C0004118C9B2197012781B789A4203D1802261 +:1003D000044B5203DA6170477D00002001000020C9 +:1003E000000000200044004110B5041C6B20FFF702 +:1003F00067FF201CFFF7B8FF0120FFF76BFF00230A +:10040000984206D101216B200A1CFFF713FF024B13 +:100410001B78181C10BDC0469D00002038B5051C77 +:100420006B200C1CFFF74CFF281CFFF79DFF201CC6 +:10043000FFF79AFF0120FFF74DFF022038BD08B5F6 +:100440000520FFF7D1FF0023984205D0CE210140BF +:100450000520FFF7E3FF0123181C08BD10B5041C9D +:100460000020FFF7C1FF78232D4A9843C1B2944280 +:1004700042D018D82B4B9C4238D009D82A4B9C42EA +:1004800030D02A4B9C422FD0294B9C4245D13FE093 +:10049000284B9C422CD0284B9C422BD0274B9C4273 +:1004A0003BD1202333E0264A94422BD00AD8254B57 +:1004B0009C4223D0244B9C4222D0244B9C422CD1E2 +:1004C000402324E0224A94421ED004D8214B9C426F +:1004D00023D160231BE0204A944217D01F4A944244 +:1004E00015D01AE0082312E0102310E018230EE0C4 +:1004F00028230CE030230AE0382308E0482306E0F4 +:10050000502304E0582302E0682300E070231943DD +:100510000020FFF783FF012000E0002010BDC0464F +:100520005811000018100000780F0000C80F0000DC +:10053000280F0000B810000008110000681000002B +:1005400098120000F811000048120000A8110000E5 +:1005500038130000E812000088130000D8130000D0 +:1005600010B5041C0020FFF73FFF07239843E1224A +:10057000C1B29200944220D008D8962C18D0FA2309 +:100580005B009C4217D0642C22D11CE0114A94429B +:1005900015D005D89623DB009C4219D1042311E025 +:1005A000FA22D20094420CD00B4A94420AD00FE0B7 +:1005B0000124214307E0022304E0032302E0052392 +:1005C00000E0062319430020FFF728FF012000E088 +:1005D000002010BDDC050000B80B000070B504ACB5 +:1005E000267805AC2578441EA041C401002901D01D +:1005F00040210C43002A01D020221443002B01D0BB +:1006000010231C43002E01D008231C43002D01D0D1 +:1006100004231C430220FFF7E7FE0125011C2940AB +:1006200021430220FFF7FAFE281C70BD10B5041C00 +:100630000420FFF7D9FE03231840084B9C4204D046 +:10064000074B9C4208D1B02100E0982101430420CF +:10065000FFF7E4FE012000E0002010BD10100000B4 +:100660007010000008B50120FFF7BEFECF23011C6B +:1006700019400120FFF7D2FE012008BD13B5FFF796 +:10068000DEFE002817D0FFF7EDFF0C480024FFF72F +:10069000E5FE0B48FFF764FF211C221C231C00947D +:1006A0000194201CFFF79AFF0648FFF7BFFFFFF7F2 +:1006B000B5FD201C01E00120404216BD08110000DC +:1006C000B80B00001010000008B50348FFF744FD08 +:1006D000FFF7D4FF08BDC046A086010010B5C3696E +:1006E0009C07FCD403680224A3430360C46901236C +:1006F0001C42FBD10468234303600368DC07FCD47D +:10070000C46901231C42FBD1C469DC401C42F7D1FF +:10071000084B1A430260C3695A07FCD4C0239B02EA +:1007200043608181C3699C07FCD4036802221343A0 +:10073000036010BD04000040037EDA07FCD501858C +:1007400070470000027E01235107FBD5428B1A42FD +:1007500007D1428BDA401A4203D1428B92081A42E7 +:1007600002D0034B01221A70008DC0B27047C04600 +:100770007E00002070B50368041C988B1A1C0821A9 +:10078000FF32084226D0802099839872112353703B +:100790004021144B917150715E68134DC0202E4062 +:1007A000800506435E605E693540284358610F4806 +:1007B00018600F4818615D680E4828408025AD021A +:1007C000284358605868800B80035860002351719B +:1007D000237105E0137ADA0602D5201C00F0E4FA52 +:1007E000207970BDA0010020FFFFFF8FA000002036 +:1007F00020010020FF3F00F0002303714371044BF0 +:10080000016083600B78022213430B707047C0466F +:100810007507000038B5364B2021DA6901200A43FC +:10082000DA61344B06241A7802431A70324B0F22D5 +:100830001978914319701978214319702F490C7850 +:100840002043087019780A401A701A7860210A4308 +:100850001A702B4B2B4A5A805A7852B2002AFBDB73 +:10086000294B01211A780A431A709A78D107FCD4CF +:1008700026480268510B1F221140914200D10521E8 +:1008800011408C011D8D224929402143198504689E +:10089000A10C0A401F2A00D11D221C8D1F210A40D5 +:1008A0008C4322431A8502680721D20D0A408A42EE +:1008B00000D103220A40188D1103164A02400A4350 +:1008C0001A8519787F220A401A701A780421124872 +:1008D0000A431A7058621A890C218A431A811A89AC +:1008E00001218A431A810021802201F0A0F938BD3C +:1008F00000040040584400413C4400415944004138 +:10090000000C0040064000000050004124608000C0 +:100910003FF8FFFFFF8FFFFFA0010020F7B5141C79 +:100920001F4A5F0101971D1CD319061C5869271C1B +:100930004000400F03301033C74006D00F1C802208 +:10094000596812060A435A6009E02F1C7B1E9F411A +:10095000144BBF01FF18381C221C01F05FF90199EC +:100960000F48083542181761131C5269A104920BF5 +:10097000890C92030A435A6159690B4A0A405A6129 +:100980006B01F3180222DA715979802252420A432C +:100990005A716B01F318DB799A07FAD5201CFEBD5A +:1009A000A001002020010020FF3F00F0F8B51A4E02 +:1009B000051C3378141C002B12D1184B184A1A64EA +:1009C0005A6C920B92035A64586C164A02405A644D +:1009D000A2235B00EA5C40200243EA540123337007 +:1009E0004827FF37EA5D0123134012D00B4B5A6CA6 +:1009F0009204920CA24202D25C6CA404A40C081CC7 +:100A0000221C074901F00AF90123EB55002333703A +:100A100000E01C1C201CF8BD7F000020A00100206D +:100A2000E0000020FF3F00F0FF3083792022002902 +:100A300000D110221343837170470000084BFF3030 +:100A40005A69920B92035A610223037282798023BE +:100A50005B4213438371037A9A07FCD57047C04603 +:100A6000A001002080235B421943C9B28172704704 +:100A700070B5A02303225B00C254134B134A5C6C75 +:100A8000C021144089050C4346255C64FF35402491 +:100A900044550F4D30261D6490256D0046555D6B05 +:100AA00015402943922559636D0080214155094D18 +:100AB0001D63B0256D0044555C6F22405A67B22318 +:100AC0005B00C15470BDC046A0010020FFFFFF8F36 +:100AD000E000002060010020024B5B785BB2002B3D +:100AE000FADB7047000C0040024BDB68DA06FBD5EE +:100AF0007047C04600080040F8B52A4B1E225968CE +:100B00009143022211435960274B28491E1C9982A8 +:100B1000998A0A439A82F3680227234C3B42FAD00F +:100B2000234D0123AB60FFF7D7FF224B6B60FFF72C +:100B3000D3FF8223DB016B80FFF7CEFFA38C8022E3 +:100B40009343A384FFF7D0FF1B4BE362FFF7CCFF77 +:100B5000A38C1A4A1343A384FFF7C6FFA38C1F4339 +:100B6000A784F3681A06FCD50F4BDB685A06F8D544 +:100B70000024FFF7B9FFAC60FFF7AEFF104B6B60CE +:100B8000FFF7AAFF0F4B104AC0215A600F4A09060F +:100B9000106A0002000A0143116207229C601A6079 +:100BA000F8BDC04600400041000800400C060000AF +:100BB000000C004001050100B805FF7D040A00009B +:100BC0000007030010E000E0E703000000ED00E094 +:100BD0000EBEFEE70DBEFEE705BEFEE702BEFEE767 +:100BE0000E4A0F4838B5824204D10E4A0E4B93424A +:100BF0000ED10AE00D4C9442F7D00023D118884260 +:100C0000F3D9E55804330D60F8E700F011F804E07B +:100C10009342FAD2002102C3FAE7FEE70000002067 +:100C20005C000020B00300205C0000203C1F00009E +:100C300038B5344D2B6801331AD0334B2A1D1A6056 +:100C4000EAB2002A14D1314B197801231940304BF4 +:100C50000AD118682F4A904201D1196008E01A6041 +:100C60002D4A013A002AFCD11A602C4B01221A703D +:100C7000FFF742FF62B6FFF727FD284B284C1B7891 +:100C8000002B0AD02B6883F308881E4BFF22934366 +:100C9000A3601D4B1B681B68184700F09DFD00F00A +:100CA0004FF8204B802252039A601F4B1F4A051CAD +:100CB0005A60216AC0220902090A12060A43226206 +:100CC00000229A6007221A60AB68281C9847184BCC +:100CD000002801D001221A701A78002A05D00020BD +:100CE00000F08CFA00F004FBFCE71B78002BEBD142 +:100CF00000F0E6FD0028E7D0012000F07FFA00F0C8 +:100D0000F7FAFCE700200000200200203804004031 +:100D1000FC7F00203581730748E801008000002037 +:100D200000ED00E00044004110E000E0E7030000B7 +:100D30008100002008B5FFF723FB00F0C3FA08BDCF +:100D400010B5054B054C2360FFF764FD201C21689E +:100D5000FFF752FD201C10BD00500041240200206E +:100D600070B5051CC0B0081C161C0C1C00F067FFF9 +:100D700040006A4603230230537010707608012346 +:100D8000E218013A11785A00002906D1281C694658 +:100D90000023FFF7C3FD40B070BDB342F6DA6846EA +:100DA00081520133ECE70000F7B5BA4A04681378C2 +:100DB000B949271CFF37051C102038720B70537877 +:100DC000B648B74E037093783380D17833880902E0 +:100DD0000B4333801179B34B19805179188809027C +:100DE000084318809079B0490880D27908881202A7 +:100DF00002430A8040227A71A84F3A78A64F120225 +:100E000038780F1C0243A9488446181C624500D15B +:100E1000C2E020DC802149008A4200D16EE109DC79 +:100E2000812A00D192E0822A00D195E0802A00D068 +:100E300064E18BE081235B009A4200D1CFE000DACD +:100E400058E1C0239B009A4200D157E1984B9A4247 +:100E500000D14FE152E190231B019A4269D015DC89 +:100E6000D023DB009A4222D088231B019A4269D00A +:100E7000A023DB009A4200D040E1201CFFF7DEFDFA +:100E80003188286889B2FFF7EDFD3BE1894B9A4232 +:100E900000D12FE100DC31E1874B9A4200D11DE106 +:100EA000864B9A4200D029E133886B7122E1338866 +:100EB0001B0A012B08D10B8812222868934201D803 +:100EC0000A8892B27E4911E133881B0A022B08D1AD +:100ED0000B8843222868934201D80A8892B2794944 +:100EE00004E133881B0A032B00D007E13388DBB20F +:100EF000012B17D0002B07D0022B00D0FEE00A8870 +:100F00002868D2B2704911E0042201A86F4900F0AC +:100F100085FE3B8804222868934201D83A8892B221 +:100F200001A9E3E00A8828686949D2B2FFF718FFEF +:100F3000E8E03388201C2B71FFF780FD201CFFF7B1 +:100F400097FDDFE0291C01C90122CFE061490023A0 +:100F50000B8028680222CAE05E4900220A801888B5 +:100F6000502210405C4A10701E880F2030401880BC +:100F70001888032800D9C1E012781B8808335B0168 +:100F8000E418A379002A01D09B0600E0DB06DB0F02 +:100F90000B8028680222A9E019887F2291434E4ADB +:100FA000C9B2117018880F210140198031880029B9 +:100FB00000D0A3E01988002900D19FE019880329F7 +:100FC00000D99BE012781B8808335B01E318002AE4 +:100FD00002D020225A718DE0102159718AE00288D6 +:100FE0007F239A433C4BD2B21A7001880F220A40E9 +:100FF00002803288002A00D080E00288002A00D1D6 +:101000007CE00288032A00D978E01B78002B1FD0EF +:10101000038808335B01E3189B799A066AD5038835 +:10102000202208335B01E3181A71038808335B013F +:10103000E318DB795F065DD50388402208335B0146 +:10104000E318DA710388022208335B01E3181EE01B +:10105000038808335B01E3189B79D9064AD50388D6 +:10106000102208335B01E3181A71038808335B010F +:10107000E318DB799A063DD50388202208335B010B +:10108000E318DA710388012208335B01E3181A714F +:1010900030E0C046A000002083000020880000202F +:1010A0008A0000208C00002086000020020300003F +:1010B0000103000021200000A121000021220000E6 +:1010C0008C1C000004000020741C0000641C000044 +:1010D000681C000084000020820000200B88082289 +:1010E0002868934201D80A8892B207490023FFF783 +:1010F00015FC07E0201CFFF7A1FC03E0201C0121E8 +:10110000FFF792FCF7BDC0464800002007B5054B2D +:101110000122019001A91868131CFFF7FFFB0120B1 +:101120000EBDC0462402002013B5054B6C460734A3 +:101130001868211C0122FFF739FC207816BDC04633 +:101140002402002010B5074C201CFFF713FB031CE2 +:101150000020834205D022684823FF33D05C01235E +:10116000184010BD2402002010B5054A0C1C031CB9 +:10117000191C10680123221CFFF7D0FB201C10BD96 +:101180002402002070B5084C061C201C0D1CFFF723 +:10119000F1FA0023984205D02068311C2A1CFFF781 +:1011A00005FC031C181C70BD24020020F8B50C4C73 +:1011B000051C201C0E1CFFF7DDFA0023271C341C25 +:1011C00098420AD0002C07D0291C221C3868FFF74F +:1011D000EDFB241A2D18F5E7331C181CF8BDC0468A +:1011E0002402002008B5031C081C111C9847024B60 +:1011F00064221A8008BDC04692000020012805D153 +:10120000054B064A1A60064B187004E0002802D10C +:10121000044A014B1A60704794020020C01C000071 +:10122000940000200C1D000030B50A1C1C4985B03C +:101230000978031C00292AD0042A01D1006804E09F +:10124000022A01D1008800E00078520004A98B181E +:101250000B3B9C1AA3420BD00F210140092902D855 +:101260003025294300E0373119700009013BF1E7CF +:1012700001A930230B7078234B700A208B189870CB +:101280000D20D870074B04321B68D86803E005496D +:101290000968C868191CFFF7A5FF05B030BDC04636 +:1012A0008E0000209402002072B6EFF30883044AF7 +:1012B0001360036883F30888436818477047C04683 +:1012C00098020020084B1A88002A03D01A88013A95 +:1012D00092B21A80054B1A88002A03D01A88013A64 +:1012E00092B21A807047C046920000209000002001 +:1012F000F0B591B008A9CC4A0B1C31CA31C351CA10 +:1013000051C360CA60C3C94BC9489A687A25520361 +:10131000520F92005258C74902609C68A4B26243BF +:101320000C60C54900240A60C44A1460C44C25708E +:10133000C44CC54D2368281C1B69402198470028D0 +:1013400002D0C24B64221A80C14B00221860C14BEC +:101350001D60C14BC04DBE4F1A602A683B689A425F +:10136000E6D2BC4B1B681A78FF2A00D114E2232A6C +:1013700000D0EBE1B94E3378002B06D0B14BB84921 +:101380001B680222D868FFF72DFFAD4B1B78532B4B +:101390003CD13B682A6893421ED9AE4801322A608C +:1013A0009A1AB04B01681B6801310160AE4E9A4237 +:1013B00001D2326000E03360A048326800680490D7 +:1013C00000F02CFC336829685A182A60A14A166874 +:1013D000F1181160A54A13702B68013B2B609D4BDF +:1013E0001A68013A1A60A14B9E4A1B7811688B4219 +:1013F0000AD222689148C91A006892699047002869 +:1014000002D0924B64221A80C0468DE1522B0AD141 +:101410008A48944A2368006811685B69039098477A +:101420006422934B0DE04F2B05D1844B8D4A1B68F2 +:1014300012681A7078E1482B05D1804B894A1B68E5 +:1014400012681A8070E1572B05D17C4B854A1B68C6 +:1014500012681A6068E16F2B03D1784B012118687C +:1014600007E0682B08D1754B7E481B6802211B885A +:101470000360FFF7D9FE57E1772B06D16F4B794810 +:101480001B6804211B680360F3E7472B13D1754BDE +:101490001868FFF709FF774B1B6883F3088862B66B +:1014A000754B1B78002B00D13EE1664B06201B6874 +:1014B0001B68984738E1542B04D101233370614BEA +:1014C0001B6864E04E2B0CD13378002B06D15D4BAA +:1014D00063491B680222D868FFF784FE002333703B +:1014E00022E1562B57D123686449D8680122FFF7BF +:1014F00079FE23686249D8680322FFF773FE614DC5 +:101500002368291CD8680122FFF76CFE23685E4916 +:10151000D8680D22FFF766FE2368291CD8680122CF +:10152000FFF760FE4B4F4C4D5849002339602B604C +:101530003A1C281C13685E1C16601B780593002B50 +:1015400003D0036801330360F4E73E4E2A68336832 +:10155000D868FFF747FE33684A49D8680122FFF789 +:1015600041FE059929604A4939603A4A1368581C76 +:1015700010601B78002B04D0374B1A6801321A60B8 +:10158000F3E733682A68D868FFF72CFE3368D86819 +:1015900033490222C6E0334A582B17D1244E264D38 +:1015A000366813682A68B10093420AD21F4D580862 +:1015B000E861384828801D4D287DC607FBD55B189B +:1015C000F2E7204B34491B68D868AAE0592B79D13F +:1015D00012681A4B3149002A02D11B680B606CE07B +:1015E000124D086819686B68104E8025AB4392084D +:1015F0007360002A61D02A4B0C4D2B800B4E337D3B +:10160000DD07FBD500230A4D2D680195AD08AB42DF +:1016100003D3244D054E358046E09342F9D09D001A +:10162000465901334E51EEE7A01C00000040004136 +:101630004C020020440200204002002090020020C2 +:101640003C02002094020020500200209000002064 +:101650003402002038020020480200208E000020C2 +:10166000001D00009C020020A0020020300200208B +:10167000920000209802002094000020DC1C000052 +:10168000051D0000DE1C0000281D0000E01C0000FD +:10169000EC1C000002A5FFFFF51C000098000020D4 +:1016A00044A5FFFF04A5FFFF3F4E357DEE07FBD5A8 +:1016B0009D0049194019D21A9BE73C4B3C491B68D5 +:1016C000D8682EE05A2B2FD13A4B17681D68002698 +:1016D000EF19BD4206D02878311C00F013F901350E +:1016E000061CF6E7314B34491B680122D868FFF726 +:1016F00079FD07230F223240111C36093031092AA7 +:1017000000DD07311820C0186A468154013BF1D230 +:10171000236806A9D8680822FFF764FD23682749D3 +:10172000D8680322FFF75EFD254B7A221A70254BFD +:1017300000221A60244B1B7893422DD01B4B234967 +:101740001B680122D868FFF74DFD25E0111C3039D8 +:10175000C8B21C4B092804D81D682A01114319601E +:101760001AE0111C4139052903D81E68373A3101A6 +:1017700006E0111C6139052904D81868573A01019F +:101780000A4308E02C2A03D10A4A1968116001E0D3 +:101790000B490A7000221A600D4B1A6801321A6058 +:1017A0000C4B1A680132D5E500400041940200203C +:1017B000F91C000090020020FD1C0000FF1C00002E +:1017C0003C0200209C0200208E000020031D00002F +:1017D000480200203802002010B51C4B01201A7866 +:1017E000032402431A701A4B0F221978914319707F +:1017F00019782143197017490C782043087019781B +:101800000A401A701A7830210A431A70124B80214C +:101810001A6A0A431A62114B114A5A805A7852B214 +:10182000002AFBDBC4220F480F499203FEF756FF44 +:101830000E4A002313700E4A13700E4A13700E4A9C +:1018400013700E4A13700E4A137010BDD644004137 +:10185000BB440041D744004100040040000C00405C +:1018600019400000001C00422AF60000A4020020DB +:101870002B030020A5020020A80200202C0300203A +:101880002903002008B5C1B20248FEF755FF012028 +:1018900008BDC046001C0042024B187E4007C00F26 +:1018A0007047C046001C004208B5FFF7F5FF00284E +:1018B000FBD00248FEF746FF08BDC046001C0042B0 +:1018C00008B5FFF7E9FF0023984205D0FFF7ECFFCA +:1018D000031C233B5A425341181C08BD70B5041C1D +:1018E0000D1C4618B44204D02078FFF7CBFF01341A +:1018F000F8E7281C70BD10B5041CFFF7D5FF207059 +:10190000012010BD0B0A5840034B4000C05A090289 +:10191000484080B27047C046361D0000F0B53E4ECC +:1019200085B0002203900C1C32703C4B914201D1D7 +:10193000012201E03A490C801A707F231C4201D039 +:1019400080349C43FFF7B0FF3378C0B2002B07D040 +:1019500000253570FFF7A8FF3378C0B2AB4236D10F +:10196000432803D0712853D01528EBD101230093CD +:101970000120FFF787FF0098FFF784FF009980257B +:10198000C843C0B2FFF77EFF039B00270293244A9F +:101990001388002B1DD1214901930978002918D102 +:1019A0000198FFF76FFF391C0198FFF7ABFF013D6E +:1019B000071C002DEBD1000AC0B2FFF763FFF8B29D +:1019C000FFF760FFFFF770FF3378002B0AD0357008 +:1019D0001FE00299013B09781380029B01910133BA +:1019E0000293DDE7C0B2062807D1009B03990133BB +:1019F000DBB280310093803C0391002CB8D10420ED +:101A0000FFF740FFFFF750FF044B01251C7000E07B +:101A10000025281C05B0F0BD290300202A03002062 +:101A2000A6020020F7B50024051C0F1C261CBC4292 +:101A300020D0FFF739FF114BC0B21B780190002B6B +:101A40001AD1311CFFF75EFF0D4B061C1A88002AC5 +:101A500004D10C4A11782A1C002907D001996A1C6C +:101A60002970802F02D11988013919800134A4B25C +:101A7000151CDCE7301C00E00120FEBD290300201E +:101A8000A60200202A030020F0B5384C87B00023BE +:101A900001902370994201D1012301E0344A118061 +:101AA000344A642613704320FFF7ECFE324FFFF7F1 +:101AB000F3FE002803D1002F03D0013FF7E7002FEA +:101AC00003D1013E002EEED14DE00125FFF7ECFEE3 +:101AD0002378002B38D1C0B20290012805D0042809 +:101AE0003DD10620FFF7CEFE39E005AE0221301CC5 +:101AF000FFF798FF01988021FFF794FF2378039068 +:101B0000002B18D1FFF7D0FE0702FFF7CDFEBFB2C2 +:101B100023783F18BFB2012B0DD0039B9F4207D102 +:101B20003378AB4204D1EB437278DBB29A4204D0F3 +:101B30001820FFF7A7FE002303E00620FFF7A2FE10 +:101B4000029B2278002A02D0002626700BE0012B8F +:101B500005D1019A6B1C8032DDB20192B6E7054ACD +:101B6000002313700126301C07B0F0BD29030020AC +:101B7000A60200202A03002000350C00002934D0E2 +:101B80000123002210B488422CD301242407A1424F +:101B900004D2814202D209011B01F8E7E400A1420C +:101BA00004D2814202D249005B00F8E7884201D3A7 +:101BB000401A1A434C08A04202D3001B5C0822437F +:101BC0008C08A04202D3001B9C082243CC08A042F0 +:101BD00002D3001BDC082243002803D01B0901D0DC +:101BE0000909E3E7101C10BC7047002801D0002051 +:101BF000C04307B4024802A14018029003BDC0468A +:101C0000190000000029F0D003B5FFF7B9FF0EBCA2 +:101C10004243891A1847C0467047C04610B5002392 +:101C2000934203D0CC5CC4540133F9E710BD031CCC +:101C30008218934202D019700133FAE770470023EB +:101C4000C25C0133002AFBD1581E7047F8B5C0466C +:101C5000F8BC08BC9E467047F8B5C046F8BC08BC46 +:101C60009E4670470403090441726475696E6F20D3 +:101C70004C4C430041726475696E6F204D4B52208D +:101C800057414E2031333130000000001201000274 +:101C9000020000404123590000020102000100003F +:101CA00008000000100000002000000040000000BC +:101CB000800000000001000000020000000400009D +:101CC00085180000A918000099180000DD18000010 +:101CD000F71800001D190000891A00007600200086 +:101CE00041707220333020323031390031323A3491 +:101CF000313A353700580A0D00590A0D005A0023B1 +:101D00000A0D003E00322E30000000000D110000D0 +:101D10002911000045110000691100008511000023 +:101D200069110000AD1100005B41726475696E6F4E +:101D30003A58595A5D000000211042206330844017 +:101D4000A550C660E770088129914AA16BB18CC18A +:101D5000ADD1CEE1EFF13112100273325222B55201 +:101D60009442F772D662399318837BB35AA3BDD3DA +:101D70009CC3FFF3DEE36224433420040114E664D1 +:101D8000C774A44485546AA54BB528850995EEE52A +:101D9000CFF5ACC58DD55336722611163006D776E1 +:101DA000F6669556B4465BB77AA719973887DFF77A +:101DB000FEE79DD7BCC7C448E5588668A7784008A9 +:101DC000611802282338CCC9EDD98EE9AFF94889CA +:101DD00069990AA92BB9F55AD44AB77A966A711A41 +:101DE000500A333A122AFDDBDCCBBFFB9EEB799B1A +:101DF000588B3BBB1AABA66C877CE44CC55C222C91 +:101E0000033C600C411CAEED8FFDECCDCDDD2AAD69 +:101E10000BBD688D499D977EB66ED55EF44E133E20 +:101E2000322E511E700E9FFFBEEFDDDFFCCF1BBFB9 +:101E30003AAF599F788F8891A981CAB1EBA10CD193 +:101E40002DC14EF16FE18010A100C230E32004509B +:101E5000254046706760B9839893FBA3DAB33DC30E +:101E60001CD37FE35EF3B1029012F322D2323542EB +:101E7000145277625672EAB5CBA5A89589856EF59E +:101E80004FE52CD50DC5E234C324A014810466743B +:101E9000476424540544DBA7FAB79987B8975FE7EE +:101EA0007EF71DC73CD7D326F2369106B01657668B +:101EB0007676154634564CD96DC90EF92FE9C89976 +:101EC000E9898AB9ABA94458654806782768C018DB +:101ED000E1088238A3287DCB5CDB3FEB1EFBF98B4E +:101EE000D89BBBAB9ABB754A545A376A167AF10A2B +:101EF000D01AB32A923A2EFD0FED6CDD4DCDAABD5E +:101F00008BADE89DC98D267C076C645C454CA23C7A +:101F1000832CE01CC10C1FEF3EFF5DCF7CDF9BAF2D +:101F2000BABFD98FF89F176E367E554E745E932ECA +:0C1F3000B23ED10EF01E000000000000C8 +:101F3C000114000009024300020100803209040070 +:101F4C000001020200000524001001042402000517 +:101F5C00240600010524010001070583030800FF86 +:101F6C0009040100020A000000070581024000007C +:101F7C00070502024000000000C20100000008003A +:0C1F8C006900000041000000000000009F +:0400000300000BE10D +:00000001FF diff --git a/bootloaders/mkrwifi1010/samd21_sam_ba_arduino_mkrwifi1010.bin b/bootloaders/mkrwifi1010/samd21_sam_ba_arduino_mkrwifi1010.bin new file mode 100755 index 0000000..6cbc244 Binary files /dev/null and b/bootloaders/mkrwifi1010/samd21_sam_ba_arduino_mkrwifi1010.bin differ diff --git a/bootloaders/mkrwifi1010/samd21_sam_ba_arduino_mkrwifi1010.hex b/bootloaders/mkrwifi1010/samd21_sam_ba_arduino_mkrwifi1010.hex new file mode 100644 index 0000000..29b8635 --- /dev/null +++ b/bootloaders/mkrwifi1010/samd21_sam_ba_arduino_mkrwifi1010.hex @@ -0,0 +1,502 @@ +:10000000FC7F0020790B0000690B00006D0B0000E5 +:1000100000000000000000000000000000000000E0 +:10002000000000000000000000000000710B000054 +:100030000000000000000000750B0000CD0C000067 +:1000400010B5064C2378002B07D1054B002B02D0AE +:10005000044800E000BF0123237010BD5C000020B5 +:1000600000000000D01E000008B5084B002B03D094 +:100070000748084900E000BF07480368002B03D089 +:10008000064B002B00D0984708BDC046000000007A +:10009000D01E00006000002058000020000000007A +:1000A000064B0322104002040549586808401043DB +:1000B0005860DA695107FCD47047C0460008004216 +:1000C000FFFFFCFF38B5284A284B5A805A7852B2B5 +:1000D000002AFBDB264B04211A6A264D0A431A62CA +:1000E0002B68012213432B602A680123214C1A42FA +:1000F000FAD1E2691A42F7D11423236041001E4865 +:1001000001F008FD421EE068FF231A4098431043A7 +:10011000E0602368022213432360EA69154B9107CC +:10012000FBD45A8B30218A4310210A435A83EB694E +:1001300001205A07FBD4114B02241A7802431A708B +:100140000F4B0F22197891431970197821431970B8 +:100150000C490C782043087019780A401A701A78F4 +:1001600020210A431A7038BD14400000000C0040E2 +:100170000004004000080042006CDC0248440041DA +:100180003444004149440041F7B500230F1C01925B +:100190001D1C994254D001212A4E4000084333705F +:1001A000C1B2294B0322588B1C1C000910400128A6 +:1001B00004D05B8B1B091A40022AF2D1606AC00A84 +:1001C000C00208436062217E1F4B0122880708D4C9 +:1001D000197E1142F7D05968C02292020A435A6030 +:1001E00003E05B8B9B08134201D0002528E03270AE +:1001F000237E9907FCD5154A154B117801251970F6 +:100200006268BD4212D0134B022013406360FFF7B7 +:1002100047FF33785A1C3270227E9007FCD50B4979 +:100220000B480A780135C254EDB2E9E78023DB02BE +:10023000134363600199002902D00320FFF730FFC8 +:10024000281CFEBD7800002000080042280800425B +:1002500099000020FFFFFBFF024B00221870024BA9 +:100260001A7070477A00002079000020F8B5274BFB +:100270001C786400E4B2264B03215D8B1A1C2D0907 +:100280000D40012D04D05B8B1B0919400229F2D1CE +:10029000536ADB0ADB0223435362117E01231942B6 +:1002A000FBD01B49498B8908194204D00320FFF772 +:1002B000F7FE022427E017490D782B1C002B11D0E4 +:1002C000154EEC1A365D154C2670114E177E012422 +:1002D000768B274202D12642F7D00BE0B6082642A1 +:1002E0000ED007E00B701C1C00280CD00320FFF779 +:1002F000D7FE08E003200B700324FFF7D1FE02E0D5 +:10030000013BDBB2DAE7201CF8BDC0467A000020D2 +:1003100000080042790000207B00002028080042ED +:10032000034A1378591C1170024AD05401207047B7 +:10033000790000207B000020154A164B1178002917 +:1003400009D11549187809784118C9B21970802067 +:1003500012494003C86111780131C9B2117019788E +:10036000F02902D81978092909D80B4908784042A0 +:10037000C0B20870187809784118C9B2197012789B +:100380001B789A4203D18022044B5203DA617047F2 +:100390007D000020010000200000002000440041FA +:1003A00010B5041C6B20FFF757FF201CFFF7B8FFA8 +:1003B0000120FFF75BFF01210A1C6B20FFF7E4FE21 +:1003C000014B187810BDC0469900002038B5051CB7 +:1003D0006B200C1CFFF740FF281CFFF7A1FF201C1F +:1003E000FFF79EFF0120FFF741FF022038BD08B54F +:1003F0000520FFF7D5FFCE23011C19400520FFF78C +:10040000E5FF012008BD000010B5041C0020FFF727 +:10041000C7FF78232D4A9843C1B2944242D018D8DE +:100420002B4B9C4238D009D82A4B9C4230D02A4BC7 +:100430009C422FD0294B9C4245D13FE0284B9C4207 +:100440002CD0284B9C422BD0274B9C423BD12023C5 +:1004500033E0264A94422BD00AD8254B9C4223D025 +:10046000244B9C4222D0244B9C422CD1402324E09C +:10047000224A94421ED004D8214B9C4223D16023AF +:100480001BE0204A944217D01F4A944215D01AE02C +:10049000082312E0102310E018230EE028230CE0BC +:1004A00030230AE0382308E0482306E0502304E024 +:1004B000582302E0682300E0702319430020FFF76F +:1004C00085FF012000E0002010BDC046581100004B +:1004D00018100000780F0000C80F0000280F00005F +:1004E000B810000008110000681000009812000009 +:1004F000F811000048120000A81100003813000095 +:10050000E812000088130000D813000010B5041C86 +:100510000020FFF745FF07239843E122C1B2920074 +:10052000944220D008D8962C18D0FA235B009C4225 +:1005300017D0642C22D11CE0114A944215D005D862 +:100540009623DB009C4219D1042311E0FA22D20049 +:1005500094420CD00B4A94420AD00FE0012421436C +:1005600007E0022304E0032302E0052300E0062362 +:1005700019430020FFF72AFF012000E0002010BDF2 +:10058000DC050000B80B000070B504AC267805ACA3 +:100590002578441EA041C401002901D040210C430C +:1005A000002A01D020221443002B01D010231C4329 +:1005B000002E01D008231C43002D01D004231C432E +:1005C0000220FFF7EDFE0125011C294021430220F6 +:1005D000FFF7FCFE281C70BD10B5041C0420FFF7BB +:1005E000DFFE03231840084B9C4204D0074B9C427B +:1005F00008D1B02100E0982101430420FFF7E6FE76 +:10060000012000E0002010BD10100000701000005C +:1006100008B50120FFF7C4FECF23011C19400120BB +:10062000FFF7D4FE012008BD07B5FFF7E0FEFFF796 +:10063000EFFF0948FFF7E8FEFA20C000FFF766FF6A +:10064000002300930193181C191C1A1CFFF79CFF30 +:100650000248FFF7C1FF07BD08110000101000009D +:1006600008B50348FFF72EFDFFF7DEFF08BDC046C3 +:10067000A086010010B5C3699C07FCD4036802245E +:10068000A3430360C46901231C42FBD104682343D4 +:1006900003600368DC07FCD4C46901231C42FBD15E +:1006A000C469DC401C42F7D1084B1A430260C3699D +:1006B0005A07FCD4C0239B0243608181C3699C0715 +:1006C000FCD4036802221343036010BD0400004001 +:1006D000037EDA07FCD5018570470000027E012306 +:1006E0005107FBD5428B1A4207D1428BDA401A429E +:1006F00003D1428B92081A4202D0034B01221A7096 +:10070000008DC0B27047C0467E00002070B50368FF +:10071000041C988B1A1C0821FF32084226D0802026 +:1007200099839872112353704021144B9171507129 +:100730005E68134DC0202E40800506435E605E69F2 +:100740003540284358610F4818600F4818615D68AC +:100750000E4828408025AD02284358605868800B19 +:100760008003586000235171237105E0137ADA0683 +:1007700002D5201C00F0E4FA207970BD9C01002015 +:10078000FFFFFF8F9C0000201C010020FF3F00F0B6 +:10079000002303714371044B016083600B780222D4 +:1007A00013430B707047C0460D07000038B5364B39 +:1007B0002021DA6901200A43DA61344B06241A78D1 +:1007C00002431A70324B0F2219789143197019782D +:1007D000214319702F490C782043087019780A407A +:1007E0001A701A7860210A431A702B4B2B4A5A80D0 +:1007F0005A7852B2002AFBDB294B01211A780A43AE +:100800001A709A78D107FCD426480268510B1F222F +:100810001140914200D1052111408C011D8D2249CA +:100820002940214319850468A10C0A401F2A00D1E0 +:100830001D221C8D1F210A408C4322431A85026809 +:100840000721D20D0A408A4200D103220A40188DA6 +:100850001103164A02400A431A8519787F220A407A +:100860001A701A78042112480A431A7058621A89B9 +:100870000C218A431A811A8901218A431A81002195 +:10088000802201F0A0F938BD000400405844004126 +:100890003C44004159440041000C00400640000027 +:1008A00000500041246080003FF8FFFFFF8FFFFFF2 +:1008B0009C010020F7B5141C1F4A5F0101971D1C05 +:1008C000D319061C5869271C4000400F0330103311 +:1008D000C74006D00F1C8022596812060A435A608E +:1008E00009E02F1C7B1E9F41144BBF01FF18381CD1 +:1008F000221C01F05FF901990F4808354218176171 +:10090000131C5269A104920B890C92030A435A6189 +:1009100059690B4A0A405A616B01F3180222DA71D5 +:100920005979802252420A435A716B01F318DB79DC +:100930009A07FAD5201CFEBD9C0100201C01002056 +:10094000FF3F00F0F8B51A4E051C3378141C002B3D +:1009500012D1184B184A1A645A6C920B92035A64BB +:10096000586C164A02405A64A2235B00EA5C40209D +:100970000243EA54012333704827FF37EA5D01231D +:10098000134012D00B4B5A6C9204920CA24202D22A +:100990005C6CA404A40C081C221C074901F00AF991 +:1009A0000123EB550023337000E01C1C201CF8BD14 +:1009B0007F0000209C010020DC000020FF3F00F0B1 +:1009C000FF3083792022002900D110221343837144 +:1009D00070470000084BFF305A69920B92035A612E +:1009E00002230372827980235B4213438371037A6B +:1009F0009A07FCD57047C0469C01002080235B42CB +:100A00001943C9B28172704770B5A02303225B00FD +:100A1000C254134B134A5C6CC021144089050C432B +:100A200046255C64FF35402444550F4D30261D6437 +:100A300090256D0046555D6B1540294392255963FD +:100A40006D0080214155094D1D63B0256D00445551 +:100A50005C6F22405A67B2235B00C15470BDC04630 +:100A60009C010020FFFFFF8FDC0000205C010020C4 +:100A7000024B5B785BB2002BFADB7047000C004046 +:100A8000024BDB68DA06FBD57047C0460008004021 +:100A9000F8B52A4B1E22596891430222114359602E +:100AA000274B28491E1C9982998A0A439A82F36827 +:100AB0000227234C3B42FAD0234D0123AB60FFF7C2 +:100AC000D7FF224B6B60FFF7D3FF8223DB016B80E4 +:100AD000FFF7CEFFA38C80229343A384FFF7D0FFC0 +:100AE0001B4BE362FFF7CCFFA38C1A4A1343A3848A +:100AF000FFF7C6FFA38C1F43A784F3681A06FCD533 +:100B00000F4BDB685A06F8D50024FFF7B9FFAC603D +:100B1000FFF7AEFF104B6B60FFF7AAFF0F4B104AB9 +:100B2000C0215A600F4A0906106A0002000A0143F8 +:100B3000116207229C601A60F8BDC0460040004167 +:100B4000000800400C060000000C004001050100F8 +:100B5000B805FF7D040A00000007030010E000E074 +:100B6000E703000000ED00E00EBEFEE70DBEFEE76D +:100B700005BEFEE702BEFEE70E4A0F4838B58242C8 +:100B800004D10E4A0E4B93420ED10AE00D4C944212 +:100B9000F7D00023D1188842F3D9E55804330D600B +:100BA000F8E700F011F804E09342FAD2002102C302 +:100BB000FAE7FEE7000000205C000020AC03002004 +:100BC0005C000020D41E000038B5344D2B68013382 +:100BD0001AD0334B2A1D1A60EAB2002A14D1314BC5 +:100BE000197801231940304B0AD118682F4A9042D6 +:100BF00001D1196008E01A602D4A013A002AFCD19F +:100C00001A602C4B01221A70FFF742FF62B6FFF701 +:100C100027FD284B284C1B78002B0AD02B6883F328 +:100C200008881E4BFF229343A3601D4B1B681B6863 +:100C3000184700F09DFD00F04FF8204B8022520332 +:100C40009A601F4B1F4A051C5A60216AC022090284 +:100C5000090A12060A43226200229A6007221A60D9 +:100C6000AB68281C9847184B002801D001221A7045 +:100C70001A78002A05D0002000F08CFA00F004FB5E +:100C8000FCE71B78002BEBD100F0E6FD0028E7D055 +:100C9000012000F07FFA00F0F7FAFCE700200000E6 +:100CA0001C02002038040040FC7F002035817307BF +:100CB00048E801008000002000ED00E00044004111 +:100CC00010E000E0E70300008100002008B5FFF716 +:100CD00033FB00F0C3FA08BD10B5054B054C23608B +:100CE000FFF764FD201C2168FFF752FD201C10BD9A +:100CF000005000412002002070B5051CC0B0081C47 +:100D0000161C0C1C00F067FF40006A4603230230EB +:100D10005370107076080123E218013A11785A00D6 +:100D2000002906D1281C69460023FFF7C3FD40B007 +:100D300070BDB342F6DA684681520133ECE7000039 +:100D4000F7B5BA4A04681378B949271CFF37051C60 +:100D5000102038720B705378B648B74E03709378F2 +:100D60003380D178338809020B4333801179B34B38 +:100D70001980517918880902084318809079B04980 +:100D80000880D2790888120202430A8040227A71D0 +:100D9000A84F3A78A64F120238780F1C0243A94890 +:100DA0008446181C624500D1C2E020DC8021490045 +:100DB0008A4200D16EE109DC812A00D192E0822AC8 +:100DC00000D195E0802A00D064E18BE081235B00B4 +:100DD0009A4200D1CFE000DA58E1C0239B009A424A +:100DE00000D157E1984B9A4200D14FE152E1902354 +:100DF0001B019A4269D015DCD023DB009A4222D035 +:100E000088231B019A4269D0A023DB009A4200D0BC +:100E100040E1201CFFF7DEFD3188286889B2FFF72A +:100E2000EDFD3BE1894B9A4200D12FE100DC31E13D +:100E3000874B9A4200D11DE1864B9A4200D029E1AE +:100E400033886B7122E133881B0A012B08D10B8890 +:100E500012222868934201D80A8892B27E4911E191 +:100E600033881B0A022B08D10B884322286893423F +:100E700001D80A8892B2794904E133881B0A032B0E +:100E800000D007E13388DBB2012B17D0002B07D04D +:100E9000022B00D0FEE00A882868D2B2704911E027 +:100EA000042201A86F4900F085FE3B8804222868CF +:100EB000934201D83A8892B201A9E3E00A882868EF +:100EC0006949D2B2FFF718FFE8E03388201C2B7184 +:100ED000FFF780FD201CFFF797FDDFE0291C01C90B +:100EE0000122CFE0614900230B8028680222CAE07A +:100EF0005E4900220A801888502210405C4A107017 +:100F00001E880F20304018801888032800D9C1E0BF +:100F100012781B8808335B01E418A379002A01D0FA +:100F20009B0600E0DB06DB0F0B8028680222A9E0AD +:100F300019887F2291434E4AC9B2117018880F2137 +:100F4000014019803188002900D0A3E019880029C8 +:100F500000D19FE01988032900D99BE012781B88F3 +:100F600008335B01E318002A02D020225A718DE079 +:100F7000102159718AE002887F239A433C4BD2B2F8 +:100F80001A7001880F220A4002803288002A00D09D +:100F900080E00288002A00D17CE00288032A00D980 +:100FA00078E01B78002B1FD0038808335B01E3181F +:100FB0009B799A066AD50388202208335B01E318DF +:100FC0001A71038808335B01E318DB795F065DD58E +:100FD0000388402208335B01E318DA710388022298 +:100FE00008335B01E3181EE0038808335B01E31854 +:100FF0009B79D9064AD50388102208335B01E31890 +:101000001A71038808335B01E318DB799A063DD532 +:101010000388202208335B01E318DA710388012278 +:1010200008335B01E3181A7130E0C0469C000020D1 +:1010300083000020880000208A0000208C0000200F +:1010400086000020020300000103000021200000B0 +:10105000A121000021220000241C00000400002027 +:101060000C1C0000FC1B0000001C00008400002081 +:10107000820000200B8808222868934201D80A8841 +:1010800092B207490023FFF715FC07E0201CFFF789 +:10109000A1FC03E0201C0121FFF792FCF7BDC04634 +:1010A0004800002007B5054B0122019001A91868EE +:1010B000131CFFF7FFFB01200EBDC04620020020DD +:1010C00013B5054B6C4607341868211C0122FFF745 +:1010D00039FC207816BDC0462002002010B5074C10 +:1010E000201CFFF713FB031C0020834205D022685D +:1010F0004823FF33D05C0123184010BD200200209C +:1011000010B5054A0C1C031C191C10680123221C75 +:10111000FFF7D0FB201C10BD2002002070B5084C4A +:10112000061C201C0D1CFFF7F1FA0023984205D085 +:101130002068311C2A1CFFF705FC031C181C70BD1D +:1011400020020020F8B50C4C051C201C0E1CFFF7DB +:10115000DDFA0023271C341C98420AD0002C07D04B +:10116000291C221C3868FFF7EDFB241A2D18F5E71F +:10117000331C181CF8BDC0462002002008B5031C13 +:10118000081C111C9847024B64221A8008BDC046F7 +:1011900092000020012805D1054B064A1A60064B33 +:1011A000187004E0002802D1044A014B1A6070470D +:1011B00090020020581C000098000020A41C000091 +:1011C00030B50A1C1C4985B00978031C00292AD0B7 +:1011D000042A01D1006804E0022A01D1008800E05D +:1011E0000078520004A98B180B3B9C1AA3420BD029 +:1011F0000F210140092902D83025294300E0373169 +:1012000019700009013BF1E701A930230B70782325 +:101210004B700A208B1898700D20D870074B043241 +:101220001B68D86803E005490968C868191CFFF7FE +:10123000A5FF05B030BDC0468E0000209002002002 +:1012400072B6EFF30883044A1360036883F30888D7 +:10125000436818477047C04694020020084B1A881C +:10126000002A03D01A88013A92B21A80054B1A88D4 +:10127000002A03D01A88013A92B21A807047C046F9 +:101280009200002090000020F0B591B008A9CC4A4F +:101290000B1C31CA31C351CA51C360CA60C3C94BA8 +:1012A000C9489A687A255203520F92005258C7498A +:1012B00002609C68A4B262430C60C54900240A60C5 +:1012C000C44A1460C44C2570C44CC54D2368281C06 +:1012D0001B6940219847002802D0C24B64221A8023 +:1012E000C14B00221860C14B1D60C14BC04DBE4FA9 +:1012F0001A602A683B689A42E6D2BC4B1B681A788F +:10130000FF2A00D114E2232A00D0EBE1B94E337852 +:10131000002B06D0B14BB8491B680222D868FFF7F2 +:101320002DFFAD4B1B78532B3CD13B682A68934271 +:101330001ED9AE4801322A609A1AB04B01681B6868 +:1013400001310160AE4E9A4201D2326000E033605A +:10135000A04832680068049000F02CFC33682968CB +:101360005A182A60A14A1668F1181160A54A13702C +:101370002B68013B2B609D4B1A68013A1A60A14B08 +:101380009E4A1B7811688B420AD222689148C91A7A +:10139000006892699047002802D0924B64221A801C +:1013A000C0468DE1522B0AD18A48944A23680068CE +:1013B00011685B69039098476422934B0DE04F2BB3 +:1013C00005D1844B8D4A1B6812681A7078E1482B4E +:1013D00005D1804B894A1B6812681A8070E1572B2F +:1013E00005D17C4B854A1B6812681A6068E16F2B37 +:1013F00003D1784B0121186807E0682B08D1754BA1 +:101400007E481B6802211B880360FFF7D9FE57E165 +:10141000772B06D16F4B79481B6804211B6803604A +:10142000F3E7472B13D1754B1868FFF709FF774B8C +:101430001B6883F3088862B6754B1B78002B00D1BC +:101440003EE1664B06201B681B68984738E1542B29 +:1014500004D101233370614B1B6864E04E2B0CD127 +:101460003378002B06D15D4B63491B680222D86894 +:10147000FFF784FE0023337022E1562B57D12368F7 +:101480006449D8680122FFF779FE23686249D86869 +:101490000322FFF773FE614D2368291CD8680122DF +:1014A000FFF76CFE23685E49D8680D22FFF766FEE1 +:1014B0002368291CD8680122FFF760FE4B4F4C4D72 +:1014C0005849002339602B603A1C281C13685E1CA5 +:1014D00016601B780593002B03D00368013303606B +:1014E000F4E73E4E2A683368D868FFF747FE336852 +:1014F0004A49D8680122FFF741FE059929604A4907 +:1015000039603A4A1368581C10601B78002B04D0CD +:10151000374B1A6801321A60F3E733682A68D868D3 +:10152000FFF72CFE3368D86833490222C6E0334AFD +:10153000582B17D1244E264D366813682A68B100FF +:1015400093420AD21F4D5808E861384828801D4D43 +:10155000287DC607FBD55B18F2E7204B34491B6892 +:10156000D868AAE0592B79D112681A4B3149002A60 +:1015700002D11B680B606CE0124D086819686B683B +:10158000104E8025AB4392087360002A61D02A4B2D +:101590000C4D2B800B4E337DDD07FBD500230A4D10 +:1015A0002D680195AD08AB4203D3244D054E35801F +:1015B00046E09342F9D09D00465901334E51EEE783 +:1015C000381C00000040004148020020400200207A +:1015D0003C0200208C0200203802002090020020F3 +:1015E0004C02002090000020300200203402002035 +:1015F000440200208E000020981C00009802002069 +:101600009C0200202C020020920000209402002066 +:1016100098000020741C00009D1C0000761C000037 +:10162000C01C0000781C0000841C000002A5FFFF05 +:101630008D1C00009400002044A5FFFF04A5FFFFBF +:101640003F4E357DEE07FBD59D0049194019D21A52 +:101650009BE73C4B3C491B68D8682EE05A2B2FD1A6 +:101660003A4B17681D680026EF19BD4206D028784E +:10167000311C00F013F90135061CF6E7314B3449F3 +:101680001B680122D868FFF779FD07230F2232403B +:10169000111C36093031092A00DD07311820C01825 +:1016A0006A468154013BF1D2236806A9D868082212 +:1016B000FFF764FD23682749D8680322FFF75EFD22 +:1016C000254B7A221A70254B00221A60244B1B7876 +:1016D00093422DD01B4B23491B680122D868FFF78A +:1016E0004DFD25E0111C3039C8B21C4B092804D827 +:1016F0001D682A01114319601AE0111C413905299E +:1017000003D81E68373A310106E0111C61390529FA +:1017100004D81868573A01010A4308E02C2A03D17B +:101720000A4A1968116001E00B490A7000221A6028 +:101730000D4B1A6801321A600C4B1A680132D5E55C +:101740000040004190020020911C00008C0200200B +:10175000951C0000971C0000380200209802002011 +:101760008E0000209B1C0000440200203402002058 +:1017700010B51C4B01201A78032402431A701A4B2F +:101780000F2219789143197019782143197017495C +:101790000C782043087019780A401A701A783021A2 +:1017A0000A431A70124B80211A6A0A431A62114BBB +:1017B000114A5A805A7852B2002AFBDBC4220F48E1 +:1017C0000F499203FEF756FF0E4A002313700E4A8C +:1017D00013700E4A13700E4A13700E4A13700E4A9D +:1017E000137010BDD6440041BB440041D7440041B2 +:1017F00000040040000C004019400000001C0042A2 +:101800002AF60000A002002027030020A1020020E9 +:10181000A4020020280300202503002008B5C1B23F +:101820000248FEF755FF012008BDC046001C0042DB +:10183000024B187E4007C00F7047C046001C004294 +:1018400008B5FFF7F5FF0028FBD00248FEF746FF7A +:1018500008BDC046001C004208B5FFF7E9FF0023A1 +:10186000984205D0FFF7ECFF031C233B5A4253413B +:10187000181C08BD70B5041C0D1C4618B44204D0D9 +:101880002078FFF7CBFF0134F8E7281C70BD10B5B6 +:10189000041CFFF7D5FF2070012010BD0B0A584033 +:1018A000034B4000C05A0902484080B27047C0460E +:1018B000CE1C0000F7B50024051C0F1C261CBC42E2 +:1018C00020D0FFF7BDFF114BC0B21B780190002B59 +:1018D0001AD1311CFFF7E2FF0D4B061C1A88002AB3 +:1018E00004D10C4A11782A1C002907D001996A1CDE +:1018F0002970802F02D11988013919800134A4B2CE +:10190000151CDCE7301C00E00120FEBD2503002093 +:10191000A202002026030020F0B53E4E85B0002232 +:1019200003900C1C32703C4B914201D1012201E02A +:101930003A490C801A707F231C4201D080349C43AA +:10194000FFF77EFF3378C0B2002B07D0002535703B +:10195000FFF776FF3378C0B2AB4236D1432803D0CD +:10196000712853D01528EBD1012300930120FFF7F4 +:1019700055FF0098FFF752FF00998025C843C0B279 +:10198000FFF74CFF039B00270293244A1388002B88 +:101990001DD1214901930978002918D10198FFF739 +:1019A0003DFF391C0198FFF779FF013D071C002D11 +:1019B000EBD1000AC0B2FFF731FFF8B2FFF72EFFFC +:1019C000FFF73EFF3378002B0AD035701FE00299F5 +:1019D000013B09781380029B019101330293DDE7FB +:1019E000C0B2062807D1009B03990133DBB28031D6 +:1019F0000093803C0391002CB8D10420FFF70EFF28 +:101A0000FFF71EFF044B01251C7000E00025281C79 +:101A100005B0F0BD2503002026030020A20200200F +:101A2000F0B5384C87B0002301902370994201D162 +:101A3000012301E0344A1180344A642613704320A4 +:101A4000FFF7ECFE324FFFF7F3FE002803D1002F23 +:101A500003D0013FF7E7002F03D1013E002EEED166 +:101A60004DE00125FFF7ECFE2378002B38D1C0B202 +:101A70000290012805D004283DD10620FFF7CEFEB4 +:101A800039E005AE0221301CFFF714FF01988021D8 +:101A9000FFF710FF23780390002B18D1FFF7D0FE3B +:101AA0000702FFF7CDFEBFB223783F18BFB2012B6C +:101AB0000DD0039B9F4207D13378AB4204D1EB4357 +:101AC0007278DBB29A4204D01820FFF7A7FE0023F9 +:101AD00003E00620FFF7A2FE029B2278002A02D034 +:101AE000002626700BE0012B05D1019A6B1C803279 +:101AF000DDB20192B6E7054A002313700126301CBF +:101B000007B0F0BD25030020A2020020260300201C +:101B100000350C00002934D00123002210B4884283 +:101B20002CD301242407A14204D2814202D209010C +:101B30001B01F8E7E400A14204D2814202D249002D +:101B40005B00F8E7884201D3401A1A434C08A042D0 +:101B500002D3001B5C0822438C08A04202D3001B66 +:101B60009C082243CC08A04202D3001BDC0822437D +:101B7000002803D01B0901D00909E3E7101C10BCA1 +:101B80007047002801D00020C04307B4024802A1DA +:101B90004018029003BDC046190000000029F0D093 +:101BA00003B5FFF7B9FF0EBC4243891A1847C04678 +:101BB0007047C04610B50023934203D0CC5CC45498 +:101BC0000133F9E710BD031C8218934202D019704B +:101BD0000133FAE770470023C25C0133002AFBD1CE +:101BE000581E7047F8B5C046F8BC08BC9E46704702 +:101BF000F8B5C046F8BC08BC9E467047040309040B +:101C000041726475696E6F204C4C4300417264757B +:101C1000696E6F204D4B5220576946692031303133 +:101C20003000000012010002020000404123540075 +:101C30000002010200010000080000001000000086 +:101C400020000000400000008000000000010000B3 +:101C500000020000000400001D18000041180000F0 +:101C600031180000751800008F18000019190000C5 +:101C7000211A00007600200041707220313120329C +:101C80003031390031333A30393A353600580A0D9F +:101C900000590A0D005A00230A0D003E00322E3072 +:101CA00000000000A5100000C1100000DD100000C1 +:101CB000011100001D11000001110000451100007C +:101CC0005B41726475696E6F3A58595A5D00000045 +:101CD0002110422063308440A550C660E77008811F +:101CE00029914AA16BB18CC1ADD1CEE1EFF1311296 +:101CF000100273325222B5529442F772D66239936F +:101D000018837BB35AA3BDD39CC3FFF3DEE36224E5 +:101D1000433420040114E664C774A44485546AA5BE +:101D20004BB528850995EEE5CFF5ACC58DD5533675 +:101D3000722611163006D776F6669556B4465BB70E +:101D40007AA719973887DFF7FEE79DD7BCC7C44845 +:101D5000E5588668A7784008611802282338CCC95E +:101D6000EDD98EE9AFF9488969990AA92BB9F55AD5 +:101D7000D44AB77A966A711A500A333A122AFDDBAE +:101D8000DCCBBFFB9EEB799B588B3BBB1AABA66CA5 +:101D9000877CE44CC55C222C033C600C411CAEEDFE +:101DA0008FFDECCDCDDD2AAD0BBD688D499D977EB5 +:101DB000B66ED55EF44E133E322E511E700E9FFF4E +:101DC000BEEFDDDFFCCF1BBF3AAF599F788F889104 +:101DD000A981CAB1EBA10CD12DC14EF16FE18010E8 +:101DE000A100C230E3200450254046706760B983EB +:101DF0009893FBA3DAB33DC31CD37FE35EF3B10238 +:101E00009012F322D2323542145277625672EAB5FA +:101E1000CBA5A89589856EF54FE52CD50DC5E23487 +:101E2000C324A01481046674476424540544DBA7CA +:101E3000FAB79987B8975FE77EF71DC73CD7D326D7 +:101E4000F2369106B01657667676154634564CD95A +:101E50006DC90EF92FE9C899E9898AB9ABA9445827 +:101E6000654806782768C018E1088238A3287DCB2A +:101E70005CDB3FEB1EFBF98BD89BBBAB9ABB754A77 +:101E8000545A376A167AF10AD01AB32A923A2EFDBA +:101E90000FED6CDD4DCDAABD8BADE89DC98D267CC7 +:101EA000076C645C454CA23C832CE01CC10C1FEF0A +:101EB0003EFF5DCF7CDF9BAFBABFD98FF89F176E17 +:101EC000367E554E745E932EB23ED10EF01E00004B +:041ED000000000000E +:101ED40001140000090243000201008032090400D9 +:101EE4000001020200000524001001042402000580 +:101EF400240600010524010001070583030800FFEF +:101F040009040100020A00000007058102400000E4 +:101F1400070502024000000000C2010000000800A2 +:0C1F240069000000410000000000000007 +:0400000300000B7975 +:00000001FF diff --git a/bootloaders/mkrzero/samd21_sam_ba_arduino_mkrzero.bin b/bootloaders/mkrzero/samd21_sam_ba_arduino_mkrzero.bin new file mode 100755 index 0000000..d8897ee Binary files /dev/null and b/bootloaders/mkrzero/samd21_sam_ba_arduino_mkrzero.bin differ diff --git a/bootloaders/mkrzero/samd21_sam_ba_arduino_mkrzero.hex b/bootloaders/mkrzero/samd21_sam_ba_arduino_mkrzero.hex new file mode 100644 index 0000000..a78c00e --- /dev/null +++ b/bootloaders/mkrzero/samd21_sam_ba_arduino_mkrzero.hex @@ -0,0 +1,403 @@ +:10000000FC7F00200D060000FD0500000106000039 +:1000100000000000000000000000000000000000E0 +:1000200000000000000000000000000005060000C5 +:100030000000000000000000090600004D0700005D +:1000400010B5064C2378002B07D1054B002B02D0AE +:10005000044800E000BF0123237010BD5C000020B5 +:1000600000000000A818000008B5084B002B03D0C2 +:100070000748084900E000BF07480368002B03D089 +:10008000064B002B00D0984708BDC046000000007A +:10009000A8180000600000205800002000000000A8 +:1000A000154A164B1178002909D115491878097895 +:1000B0004118C9B2197080201249400008601178B7 +:1000C0000131C9B211701978F02902D819780929BB +:1000D00009D80B4908784042C0B2087018780978EE +:1000E0004118C9B2197012781B789A4203D1802244 +:1000F000044B52001A607047780000200100002075 +:10010000000000209C44004110B5C3699C07FCD44A +:1001100003680224A3430360C46901231C42FBD18A +:100120000468234303600368DC07FCD4C46901232B +:100130001C42FBD1C469DC401C42F7D1084B1A4376 +:100140000260C3695A07FCD4C0239B0243608181CB +:10015000C3699C07FCD4036802221343036010BDEB +:1001600004000040037EDA07FCD5018570470000DB +:10017000027E01235107FBD5428B1A4207D1428BE5 +:10018000DA401A4203D1428B92081A4202D0034B42 +:1001900001221A70008DC0B27047C046790000205D +:1001A00070B50368041C988B1A1C0821FF320842A2 +:1001B00026D0802099839872112353704021144BCC +:1001C000917150715E68134DC0202E40800506432A +:1001D0005E605E693540284358610F4818600F48DB +:1001E00018615D680E4828408025AD02284358609C +:1001F0005868800B8003586000235171237105E01B +:10020000137ADA0602D5201C00F0DAFA207970BDE4 +:1002100098010020FFFFFF8F9800002018010020A8 +:10022000FF3F00F0002303714371044B01608360C2 +:100230000B78022213430B707047C046A1010000E7 +:1002400038B5364B2021DA6901200A43DA61344B94 +:1002500006241A7802431A70324B0F221978914300 +:1002600019701978214319702F490C7820430870B0 +:1002700019780A401A701A7860210A431A702B4BB9 +:100280002B4A5A805A7852B2002AFBDB294B0121B3 +:100290001A780A431A709A78D107FCD42648026863 +:1002A000510B1F221140914200D1052111408C01B8 +:1002B0001D8D22492940214319850468A10C0A405B +:1002C0001F2A00D11D221C8D1F210A408C4322436E +:1002D0001A8502680721D20D0A408A4200D1032202 +:1002E0000A40188D1103164A02400A431A851978EC +:1002F0007F220A401A701A78042112480A431A70A1 +:1003000058621A890C218A431A811A8901218A4369 +:100310001A810021802201F046F938BD0004004016 +:10032000584400413C44004159440041000C004005 +:100330000640000000500041246080003FF8FFFFAD +:10034000FF8FFFFF98010020F7B5141C1F4A5F01C3 +:1003500001971D1CD319061C5869271C4000400F2B +:1003600003301033C74006D00F1C80225968120694 +:100370000A435A6009E02F1C7B1E9F41144BBF01AA +:10038000FF18381C221C01F005F901990F480835A7 +:1003900042181761131C5269A104920B890C920335 +:1003A0000A435A6159690B4A0A405A616B01F318B2 +:1003B0000222DA715979802252420A435A716B0142 +:1003C000F318DB799A07FAD5201CFEBD98010020AE +:1003D00018010020FF3F00F0F8B51A4E051C3378D5 +:1003E000141C002B12D1184B184A1A645A6C920B29 +:1003F00092035A64586C164A02405A64A2235B0066 +:10040000EA5C40200243EA54012333704827FF3757 +:10041000EA5D0123134012D00B4B5A6C9204920CEC +:10042000A24202D25C6CA404A40C081C221C074942 +:1004300001F0B0F80123EB550023337000E01C1CE1 +:10044000201CF8BD7A00002098010020D800002070 +:10045000FF3F00F0FF3083792022002900D11022D5 +:100460001343837170470000084BFF305A69920BA9 +:1004700092035A6102230372827980235B42134301 +:100480008371037A9A07FCD57047C0469801002013 +:1004900080235B421943C9B28172704770B5A023B3 +:1004A00003225B00C254134B134A5C6CC0211440FE +:1004B00089050C4346255C64FF35402444550F4DA7 +:1004C00030261D6490256D0046555D6B154029430F +:1004D000922559636D0080214155094D1D63B0255A +:1004E0006D0044555C6F22405A67B2235B00C154D3 +:1004F00070BDC04698010020FFFFFF8FD80000208C +:1005000058010020024B5B785BB2002BFADB70478E +:10051000000C0040024BDB68DA06FBD57047C04692 +:1005200000080040F8B52A4B1E2259689143022268 +:1005300011435960274B28491E1C9982998A0A4306 +:100540009A82F3680227234C3B42FAD0234D0123C1 +:10055000AB60FFF7D7FF224B6B60FFF7D3FF82231F +:10056000DB016B80FFF7CEFFA38C80229343A38433 +:10057000FFF7D0FF1B4BE362FFF7CCFFA38C1A4AB7 +:100580001343A384FFF7C6FFA38C1F43A784F3681C +:100590001A06FCD50F4BDB685A06F8D50024FFF786 +:1005A000B9FFAC60FFF7AEFF104B6B60FFF7AAFF1F +:1005B0000F4B104AC0215A600F4A0906106A000208 +:1005C000000A0143116207229C601A60F8BDC04610 +:1005D00000400041000800400C060000000C0040F4 +:1005E00001050100B805FF7D040A000000070300B3 +:1005F00010E000E0E703000000ED00E00EBEFEE7C3 +:100600000DBEFEE705BEFEE702BEFEE70E4A0F483E +:1006100038B5824204D10E4A0E4B93420ED10AE005 +:100620000D4C9442F7D00023D1188842F3D9E558F5 +:1006300004330D60F8E700F011F804E09342FAD2B9 +:10064000002102C3FAE7FEE7000000205C00002062 +:10065000A80300205C000020AC18000038B5304B27 +:100660001A681C1C013221D02E4A191D1160D9B202 +:1006700000291BD12C4A1078012210402B4A0AD1A4 +:1006800015682B498D4201D110600FE01160294996 +:1006900001390029FCD11160226882F30888FF2209 +:1006A0009343254A93601E4B5B681847FFF73AFF58 +:1006B00062B600F09DFD00F04FF8204B8022520002 +:1006C0001A601F4B1F4A041C5A601B4AC021106A43 +:1006D00009060002000A0143116200229A60072203 +:1006E0001A60A368201C9847174B002801D00122EC +:1006F0001A701A78002A05D0002000F08BFA00F05A +:1007000003FBFCE71B78002BEBD100F0E5FD002894 +:10071000E7D0012000F07EFA00F0F6FAFCE7C046D0 +:10072000002000001802002038040040FC7F002058 +:100730003581730748E8010000ED00E0884400417E +:1007400010E000E0E70300007B00002008B5FFF7A1 +:10075000A7FC00F0C3FA08BD10B5054B054C23609B +:10076000FFF76EFD201C2168FFF75CFD201C10BD0B +:10077000005000411C02002070B5051CC0B0081CD0 +:10078000161C0C1C00F017FF40006A4603230230C1 +:100790005370107076080123E218013A11785A005C +:1007A000002906D1281C69460023FFF7CDFD40B083 +:1007B00070BDB342F6DA684681520133ECE70000BF +:1007C000F7B5BA4A04681378B949271CFF37051CE6 +:1007D000102038720B705378B648B74E0370937878 +:1007E0003380D178338809020B4333801179B34BBE +:1007F0001980517918880902084318809079B04906 +:100800000880D2790888120202430A8040227A7155 +:10081000A84F3A78A64F120238780F1C0243A94815 +:100820008446181C624500D1C2E020DC80214900CA +:100830008A4200D16EE109DC812A00D192E0822A4D +:1008400000D195E0802A00D064E18BE081235B0039 +:100850009A4200D1CFE000DA58E1C0239B009A42CF +:1008600000D157E1984B9A4200D14FE152E19023D9 +:100870001B019A4269D015DCD023DB009A4222D0BA +:1008800088231B019A4269D0A023DB009A4200D042 +:1008900040E1201CFFF7E8FD3188286889B2FFF7A6 +:1008A000F7FD3BE1894B9A4200D12FE100DC31E1B9 +:1008B000874B9A4200D11DE1864B9A4200D029E134 +:1008C00033886B7122E133881B0A012B08D10B8816 +:1008D00012222868934201D80A8892B27E4911E117 +:1008E00033881B0A022B08D10B88432228689342C5 +:1008F00001D80A8892B2794904E133881B0A032B94 +:1009000000D007E13388DBB2012B17D0002B07D0D2 +:10091000022B00D0FEE00A882868D2B2704911E0AC +:10092000042201A86F4900F035FE3B8804222868A4 +:10093000934201D83A8892B201A9E3E00A88286874 +:100940006949D2B2FFF718FFE8E03388201C2B7109 +:10095000FFF78AFD201CFFF7A1FDDFE0291C01C97C +:100960000122CFE0614900230B8028680222CAE0FF +:100970005E4900220A801888502210405C4A10709C +:100980001E880F20304018801888032800D9C1E045 +:1009900012781B8808335B01E418A379002A01D080 +:1009A0009B0600E0DB06DB0F0B8028680222A9E033 +:1009B00019887F2291434E4AC9B2117018880F21BD +:1009C000014019803188002900D0A3E0198800294E +:1009D00000D19FE01988032900D99BE012781B8879 +:1009E00008335B01E318002A02D020225A718DE0FF +:1009F000102159718AE002887F239A433C4BD2B27E +:100A00001A7001880F220A4002803288002A00D022 +:100A100080E00288002A00D17CE00288032A00D905 +:100A200078E01B78002B1FD0038808335B01E318A4 +:100A30009B799A066AD50388202208335B01E31864 +:100A40001A71038808335B01E318DB795F065DD513 +:100A50000388402208335B01E318DA71038802221D +:100A600008335B01E3181EE0038808335B01E318D9 +:100A70009B79D9064AD50388102208335B01E31815 +:100A80001A71038808335B01E318DB799A063DD5B8 +:100A90000388202208335B01E318DA7103880122FE +:100AA00008335B01E3181A7130E0C046980000205B +:100AB0007D000020820000208400002086000020AD +:100AC000800000200203000001030000212000003C +:100AD000A121000021220000FC15000004000020DC +:100AE000EC150000DC150000E01500007E00002081 +:100AF0007C0000200B8808222868934201D80A88CD +:100B000092B207490023FFF71FFC07E0201CFFF704 +:100B1000ABFC03E0201C0121FFF79CFCF7BDC046A5 +:100B20004800002007B5054B0122019001A9186873 +:100B3000131CFFF709FC01200EBDC0461C0200205B +:100B400013B5054B6C4607341868211C0122FFF7CA +:100B500043FC207816BDC0461C02002010B5074C8F +:100B6000201CFFF71DFB031C0020834205D02268D8 +:100B70004823FF33D05C0123184010BD1C02002025 +:100B800010B5054A0C1C031C191C10680123221CFB +:100B9000FFF7DAFB201C10BD1C02002070B5084CCA +:100BA000061C201C0D1CFFF7FBFA0023984205D001 +:100BB0002068311C2A1CFFF70FFC031C181C70BD99 +:100BC0001C020020F8B50C4C051C201C0E1CFFF765 +:100BD000E7FA0023271C341C98420AD0002C07D0C7 +:100BE000291C221C3868FFF7F7FB241A2D18F5E79B +:100BF000331C181CF8BDC0461C02002008B5031C9D +:100C0000081C111C9847024B64221A8008BDC0467C +:100C10008C000020012805D1054B064A1A60064BBE +:100C2000187004E0002802D1044A014B1A60704792 +:100C30008C02002030160000940000207C1600007A +:100C400030B50A1C1C4985B00978031C00292AD03C +:100C5000042A01D1006804E0022A01D1008800E0E2 +:100C60000078520004A98B180B3B9C1AA3420BD0AE +:100C70000F210140092902D83025294300E03731EE +:100C800019700009013BF1E701A930230B707823AB +:100C90004B700A208B1898700D20D870074B0432C7 +:100CA0001B68D86803E005490968C868191CFFF784 +:100CB000A5FF05B030BDC046880000208C02002092 +:100CC00072B6EFF30883044A1360036883F308885D +:100CD000436818477047C04690020020084B1A88A6 +:100CE000002A03D01A88013A92B21A80054B1A885A +:100CF000002A03D01A88013A92B21A807047C0467F +:100D00008C0000208A000020F0B591B008A9CC4AE0 +:100D10000B1C31CA31C351CA51C360CA60C3C94B2D +:100D2000C9489A687A255203520F92005258C7490F +:100D300002609C68A4B262430C60C54900240A604A +:100D4000C44A1460C44C2570C44CC54D2368281C8B +:100D50001B6940219847002802D0C24B64221A80A8 +:100D6000C14B00221860C14B1D60C14BC04DBE4F2E +:100D70001A602A683B689A42E6D2BC4B1B681A7814 +:100D8000FF2A00D114E2232A00D0EBE1B94E3378D8 +:100D9000002B06D0B14BB8491B680222D868FFF778 +:100DA0002DFFAD4B1B78532B3CD13B682A689342F7 +:100DB0001ED9AE4801322A609A1AB04B01681B68EE +:100DC00001310160AE4E9A4201D2326000E03360E0 +:100DD000A04832680068049000F0DCFB33682968A2 +:100DE0005A182A60A14A1668F1181160A54A1370B2 +:100DF0002B68013B2B609D4B1A68013A1A60A14B8E +:100E00009E4A1B7811688B420AD222689148C91AFF +:100E1000006892699047002802D0924B64221A80A1 +:100E2000C0468DE1522B0AD18A48944A2368006853 +:100E300011685B69039098476422934B0DE04F2B38 +:100E400005D1844B8D4A1B6812681A7078E1482BD3 +:100E500005D1804B894A1B6812681A8070E1572BB4 +:100E600005D17C4B854A1B6812681A6068E16F2BBC +:100E700003D1784B0121186807E0682B08D1754B26 +:100E80007E481B6802211B880360FFF7D9FE57E1EB +:100E9000772B06D16F4B79481B6804211B680360D0 +:100EA000F3E7472B13D1754B1868FFF709FF774B12 +:100EB0001B6883F3088862B6754B1B78002B00D142 +:100EC0003EE1664B06201B681B68984738E1542BAF +:100ED00004D101233370614B1B6864E04E2B0CD1AD +:100EE0003378002B06D15D4B63491B680222D8681A +:100EF000FFF784FE0023337022E1562B57D123687D +:100F00006449D8680122FFF779FE23686249D868EE +:100F10000322FFF773FE614D2368291CD868012264 +:100F2000FFF76CFE23685E49D8680D22FFF766FE66 +:100F30002368291CD8680122FFF760FE4B4F4C4DF7 +:100F40005849002339602B603A1C281C13685E1C2A +:100F500016601B780593002B03D0036801330360F0 +:100F6000F4E73E4E2A683368D868FFF747FE3368D7 +:100F70004A49D8680122FFF741FE059929604A498C +:100F800039603A4A1368581C10601B78002B04D053 +:100F9000374B1A6801321A60F3E733682A68D86859 +:100FA000FFF72CFE3368D86833490222C6E0334A83 +:100FB000582B17D1244E264D366813682A68B10085 +:100FC00093420AD21F4D5808E861384828801D4DC9 +:100FD000287DC607FBD55B18F2E7204B34491B6818 +:100FE000D868AAE0592B79D112681A4B3149002AE6 +:100FF00002D11B680B606CE0124D086819686B68C1 +:10100000104E8025AB4392087360002A61D02A4BB2 +:101010000C4D2B800B4E337DDD07FBD500230A4D95 +:101020002D680195AD08AB4203D3244D054E3580A4 +:1010300046E09342F9D09D00465901334E51EEE708 +:101040001016000000400041440200203C02002035 +:101050003802002088020020340200208C02002088 +:10106000480200208A0000202C02002030020020CC +:10107000400200208800002070160000940200202A +:1010800098020020280200208C00002090020020FE +:10109000940000204C160000751600004E1600004B +:1010A00098160000501600005C16000002A5FFFF15 +:1010B000651600009000002044A5FFFF04A5FFFF77 +:1010C0003F4E357DEE07FBD59D0049194019D21AD8 +:1010D0009BE73C4B3C491B68D8682EE05A2B2FD12C +:1010E0003A4B17681D680026EF19BD4206D02878D4 +:1010F000311C00F013F90135061CF6E7314B344979 +:101100001B680122D868FFF779FD07230F223240C0 +:10111000111C36093031092A00DD07311820C018AA +:101120006A468154013BF1D2236806A9D868082297 +:10113000FFF764FD23682749D8680322FFF75EFDA7 +:10114000254B7A221A70254B00221A60244B1B78FB +:1011500093422DD01B4B23491B680122D868FFF70F +:101160004DFD25E0111C3039C8B21C4B092804D8AC +:101170001D682A01114319601AE0111C4139052923 +:1011800003D81E68373A310106E0111C6139052980 +:1011900004D81868573A01010A4308E02C2A03D101 +:1011A0000A4A1968116001E00B490A7000221A60AE +:1011B0000D4B1A6801321A600C4B1A680132D5E5E2 +:1011C000004000418C0200206916000088020020C7 +:1011D0006D1600006F1600003402002094020020FB +:1011E000880000207316000040020020300200201A +:1011F00010B51C4B01201A78032402431A701A4BB5 +:101200000F221978914319701978214319701749E1 +:101210000C782043087019780A401A701A78302127 +:101220000A431A70124B80211A6A0A431A62114B40 +:10123000114A5A805A7852B2002AFBDBC4220F4866 +:101240000F499203FEF760FF0E4A002313700E4A07 +:1012500013700E4A13700E4A13700E4A13700E4A22 +:10126000137010BDD6440041BB440041D744004137 +:1012700000040040000C004019400000001C004227 +:101280002AF600009C020020230300209D0200207B +:10129000A0020020240300202103002008B5C1B2D1 +:1012A0000248FEF75FFF012008BDC046001C004257 +:1012B000024B187E4007C00F7047C046001C00421A +:1012C00008B5FFF7F5FF0028FBD00248FEF750FFF6 +:1012D00008BDC046001C004208B5FFF7E9FF002327 +:1012E000984205D0FFF7ECFF031C233B5A425341C1 +:1012F000181C08BD70B5041C0D1C4618B44204D05F +:101300002078FFF7CBFF0134F8E7281C70BD10B53B +:10131000041CFFF7D5FF2070012010BD0B0A5840B8 +:10132000034B4000C05A0902484080B27047C04693 +:10133000A6160000F7B50024051C0F1C261CBC4295 +:1013400020D0FFF7BDFF114BC0B21B780190002BDE +:101350001AD1311CFFF7E2FF0D4B061C1A88002A38 +:1013600004D10C4A11782A1C002907D001996A1C63 +:101370002970802F02D11988013919800134A4B253 +:10138000151CDCE7301C00E00120FEBD210300201D +:101390009E02002022030020F0B53E4E85B00022C0 +:1013A00003900C1C32703C4B914201D1012201E0B0 +:1013B0003A490C801A707F231C4201D080349C4330 +:1013C000FFF77EFF3378C0B2002B07D000253570C1 +:1013D000FFF776FF3378C0B2AB4236D1432803D053 +:1013E000712853D01528EBD1012300930120FFF77A +:1013F00055FF0098FFF752FF00998025C843C0B2FF +:10140000FFF74CFF039B00270293244A1388002B0D +:101410001DD1214901930978002918D10198FFF7BE +:101420003DFF391C0198FFF779FF013D071C002D96 +:10143000EBD1000AC0B2FFF731FFF8B2FFF72EFF81 +:10144000FFF73EFF3378002B0AD035701FE002997A +:10145000013B09781380029B019101330293DDE780 +:10146000C0B2062807D1009B03990133DBB280315B +:101470000093803C0391002CB8D10420FFF70EFFAD +:10148000FFF71EFF044B01251C7000E00025281CFF +:1014900005B0F0BD21030020220300209E020020A1 +:1014A000F0B5384C87B0002301902370994201D1E8 +:1014B000012301E0344A1180344A6426137043202A +:1014C000FFF7ECFE324FFFF7F3FE002803D1002FA9 +:1014D00003D0013FF7E7002F03D1013E002EEED1EC +:1014E0004DE00125FFF7ECFE2378002B38D1C0B288 +:1014F0000290012805D004283DD10620FFF7CEFE3A +:1015000039E005AE0221301CFFF714FF019880215D +:10151000FFF710FF23780390002B18D1FFF7D0FEC0 +:101520000702FFF7CDFEBFB223783F18BFB2012BF1 +:101530000DD0039B9F4207D13378AB4204D1EB43DC +:101540007278DBB29A4204D01820FFF7A7FE00237E +:1015500003E00620FFF7A2FE029B2278002A02D0B9 +:10156000002626700BE0012B05D1019A6B1C8032FE +:10157000DDB20192B6E7054A002313700126301C44 +:1015800007B0F0BD210300209E02002022030020AE +:1015900000350C0010B50023934203D0CC5CC4543A +:1015A0000133F9E710BD031C8218934202D0197071 +:1015B0000133FAE770470023C25C0133002AFBD1F4 +:1015C000581E7047F8B5C046F8BC08BC9E46704728 +:1015D000F8B5C046F8BC08BC9E4670470403090431 +:1015E00041726475696E6F204C4C430041726475A2 +:1015F000696E6F204D4B525A65726F0012010002E6 +:101600000200004041234F000002010200010000DF +:101610000800000010000000200000004000000052 +:101620008000000000010000000200000004000033 +:101630009D120000C1120000B1120000F51200005E +:101640000F13000099130000A11400007600200081 +:1016500041707220313120323031390031333A302B +:10166000393A353300580A0D00590A0D005A002343 +:101670000A0D003E00322E3000000000250B000055 +:10168000410B00005D0B0000810B00009D0B000072 +:10169000810B0000C50B00005B41726475696E6FC1 +:1016A0003A58595A5D0000002110422063308440AE +:1016B000A550C660E770088129914AA16BB18CC121 +:1016C000ADD1CEE1EFF13112100273325222B55298 +:1016D0009442F772D662399318837BB35AA3BDD371 +:1016E0009CC3FFF3DEE36224433420040114E66468 +:1016F000C774A44485546AA54BB528850995EEE5C1 +:10170000CFF5ACC58DD55336722611163006D77677 +:10171000F6669556B4465BB77AA719973887DFF710 +:10172000FEE79DD7BCC7C448E5588668A77840083F +:10173000611802282338CCC9EDD98EE9AFF9488960 +:1017400069990AA92BB9F55AD44AB77A966A711AD7 +:10175000500A333A122AFDDBDCCBBFFB9EEB799BB0 +:10176000588B3BBB1AABA66C877CE44CC55C222C27 +:10177000033C600C411CAEED8FFDECCDCDDD2AAD00 +:101780000BBD688D499D977EB66ED55EF44E133EB7 +:10179000322E511E700E9FFFBEEFDDDFFCCF1BBF50 +:1017A0003AAF599F788F8891A981CAB1EBA10CD12A +:1017B0002DC14EF16FE18010A100C230E320045032 +:1017C000254046706760B9839893FBA3DAB33DC3A5 +:1017D0001CD37FE35EF3B1029012F322D232354282 +:1017E000145277625672EAB5CBA5A89589856EF535 +:1017F0004FE52CD50DC5E234C324A01481046674D2 +:10180000476424540544DBA7FAB79987B8975FE784 +:101810007EF71DC73CD7D326F2369106B016576621 +:101820007676154634564CD96DC90EF92FE9C8990C +:10183000E9898AB9ABA94458654806782768C01871 +:10184000E1088238A3287DCB5CDB3FEB1EFBF98BE4 +:10185000D89BBBAB9ABB754A545A376A167AF10AC1 +:10186000D01AB32A923A2EFD0FED6CDD4DCDAABDF4 +:101870008BADE89DC98D267C076C645C454CA23C11 +:10188000832CE01CC10C1FEF3EFF5DCF7CDF9BAFC4 +:10189000BABFD98FF89F176E367E554E745E932E61 +:0C18A000B23ED10EF01E0000000000005F +:1018AC000114000009024300020100803209040007 +:1018BC0000010202000005240010010424020005AE +:1018CC00240600010524010001070583030800FF1D +:1018DC0009040100020A0000000705810240000013 +:1018EC00070502024000000000C2010000000800D1 +:0C18FC0069000000410000000000000036 +:040000030000060DE6 +:00000001FF diff --git a/bootloaders/mzero/Bootloader_D21/Bootloader_D21.atsln b/bootloaders/mzero/Bootloader_D21/Bootloader_D21.atsln new file mode 100644 index 0000000..1fa7e55 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/Bootloader_D21.atsln @@ -0,0 +1,20 @@ + +Microsoft Visual Studio Solution File, Format Version 11.00 +# Atmel Studio Solution File, Format Version 11.00 +Project("{54F91283-7BC4-4236-8FF9-10F437C3AD48}") = "Bootloader_D21", "Bootloader_D21.cproj", "{7ABD2862-543D-4184-845E-8DC3E340E2CC}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|ARM = Debug|ARM + Release|ARM = Release|ARM + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {7ABD2862-543D-4184-845E-8DC3E340E2CC}.Debug|ARM.ActiveCfg = Debug|ARM + {7ABD2862-543D-4184-845E-8DC3E340E2CC}.Debug|ARM.Build.0 = Debug|ARM + {7ABD2862-543D-4184-845E-8DC3E340E2CC}.Release|ARM.ActiveCfg = Release|ARM + {7ABD2862-543D-4184-845E-8DC3E340E2CC}.Release|ARM.Build.0 = Release|ARM + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/bootloaders/mzero/Bootloader_D21/Bootloader_D21.atsuo b/bootloaders/mzero/Bootloader_D21/Bootloader_D21.atsuo new file mode 100644 index 0000000..654158d Binary files /dev/null and b/bootloaders/mzero/Bootloader_D21/Bootloader_D21.atsuo differ diff --git a/bootloaders/mzero/Bootloader_D21/Bootloader_D21.cproj b/bootloaders/mzero/Bootloader_D21/Bootloader_D21.cproj new file mode 100644 index 0000000..093bc1c --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/Bootloader_D21.cproj @@ -0,0 +1,1033 @@ + + + + 2.0 + 6.2 + com.Atmel.ARMGCC.C + {7abd2862-543d-4184-845e-8dc3e340e2cc} + ATSAMD21G18A + samd21 + Executable + C + $(MSBuildProjectName) + .elf + $(MSBuildProjectDirectory)\$(Configuration) + bootloader_stk500v2_beta + Bootloader_D21 + bootloader_stk500v2_beta + Native + true + false + true + true + 0x20000000 + + exception_table + 2 + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + com.atmel.avrdbg.tool.edbg + SWD + + + + 2000000 + + SWD + + com.atmel.avrdbg.tool.edbg + FFFFFFFFFFFFFFFFFFFF + EDBG + + true + + + + + True + True + True + True + True + + + NDEBUG + BOARD=SAMD21_XPLAINED_PRO + __SAMD21J18A__ + ARM_MATH_CM0=true + USB_DEVICE_LPM_SUPPORT + UDD_ENABLE + EXTINT_CALLBACK_MODE=true + RTC_COUNT_ASYNC=true + + + False + + + ../common2/applications/xplained_pro_user_application/samd21j18a_samd21_xplained_pro/config + ../src/ASF/sam0/utils/header_files + ../src/ASF/thirdparty/CMSIS/Lib/GCC + ../src/config + ../src/ASF/sam0/drivers/system/interrupt/system_interrupt_samd21 + ../src/ASF/common/utils + ../src/ASF/sam0/boards/samd21_xplained_pro + ../src/ASF/sam0/drivers/system/pinmux + ../src + ../src/ASF/sam0/utils/preprocessor + ../src/ASF/sam0/utils/cmsis/samd21/include + ../src/ASF/sam0/drivers/system + ../src/ASF/common/boards + ../src/ASF/sam0/drivers/port + ../src/ASF/sam0/utils/cmsis/samd21/source + ../src/ASF/sam0/drivers/system/clock/clock_samd21_r21 + ../src/ASF/sam0/drivers/system/clock + ../src/ASF/sam0/boards + ../src/ASF/sam0/drivers/system/interrupt + ../src/ASF/sam0/utils + ../src/ASF/thirdparty/CMSIS/Include + ../src/ASF/common/services/sleepmgr + ../src/ASF/common/services/usb + ../src/ASF/common/services/usb/class/cdc + ../src/ASF/common/services/usb/class/cdc/device + ../src/ASF/common/services/usb/udc + ../src/ASF/sam0/drivers/usb + ../src/ASF/sam0/drivers/usb/stack_interface + ../src/ASF/sam0/drivers/nvm + ../src/ASF/sam0/drivers/rtc + + + Optimize for size (-Os) + -fdata-sections + True + True + -pipe -fno-strict-aliasing -Wall -Wstrict-prototypes -Wmissing-prototypes -Werror-implicit-function-declaration -Wpointer-arith -std=gnu99 -ffunction-sections -fdata-sections -Wchar-subscripts -Wcomment -Wformat=2 -Wimplicit-int -Wmain -Wparentheses -Wsequence-point -Wreturn-type -Wswitch -Wtrigraphs -Wunused -Wuninitialized -Wunknown-pragmas -Wfloat-equal -Wundef -Wshadow -Wbad-function-cast -Wwrite-strings -Wsign-compare -Waggregate-return -Wmissing-declarations -Wformat -Wmissing-format-attribute -Wno-deprecated-declarations -Wpacked -Wredundant-decls -Wnested-externs -Wlong-long -Wunreachable-code -Wcast-align --param max-inline-insns-single=500 + True + + + libarm_cortexM0l_math + libm + + + + + ../cmsis/linkerScripts + ../src/ASF/thirdparty/CMSIS/Lib/GCC + + + True + -Wl,--entry=Reset_Handler -Wl,--cref -mthumb -T../src/ASF/sam0/utils/linker_scripts/samd21/gcc/samd21j18a_flash.ld + -DARM_MATH_CM0=true -DBOARD=SAMD21_XPLAINED_PRO -D__SAMD21J18A__ -DUSB_DEVICE_LPM_SUPPORT -DUDD_ENABLE -DEXTINT_CALLBACK_MODE=true -DRTC_COUNT_ASYNC=true + False + + + ../common2/applications/xplained_pro_user_application/samd21j18a_samd21_xplained_pro/config + ../src/ASF/sam0/utils/header_files + ../src/ASF/thirdparty/CMSIS/Lib/GCC + ../src/config + ../src/ASF/sam0/drivers/system/interrupt/system_interrupt_samd21 + ../src/ASF/common/utils + ../src/ASF/sam0/boards/samd21_xplained_pro + ../src/ASF/sam0/drivers/system/pinmux + ../src + ../src/ASF/sam0/utils/preprocessor + ../src/ASF/sam0/utils/cmsis/samd21/include + ../src/ASF/sam0/drivers/system + ../src/ASF/common/boards + ../src/ASF/sam0/drivers/port + ../src/ASF/sam0/utils/cmsis/samd21/source + ../src/ASF/sam0/drivers/system/clock/clock_samd21_r21 + ../src/ASF/sam0/drivers/system/clock + ../src/ASF/sam0/boards + ../src/ASF/sam0/drivers/system/interrupt + ../src/ASF/sam0/utils + ../src/ASF/thirdparty/CMSIS/Include + ../src/ASF/common/services/sleepmgr + ../src/ASF/common/services/usb + ../src/ASF/common/services/usb/class/cdc + ../src/ASF/common/services/usb/class/cdc/device + ../src/ASF/common/services/usb/udc + ../src/ASF/sam0/drivers/usb + ../src/ASF/sam0/drivers/usb/stack_interface + ../src/ASF/sam0/drivers/nvm + ../src/ASF/sam0/drivers/rtc + + + + + + + + + True + True + True + True + True + + + DEBUG + BOARD=SAMD21_XPLAINED_PRO + __SAMD21J18A__ + ARM_MATH_CM0=true + USB_DEVICE_LPM_SUPPORT + UDD_ENABLE + EXTINT_CALLBACK_MODE=true + RTC_COUNT_ASYNC=true + + + False + + + ../common2/applications/xplained_pro_user_application/samd21j18a_samd21_xplained_pro/config + ../src/ASF/sam0/utils/header_files + ../src/ASF/thirdparty/CMSIS/Lib/GCC + ../src/config + ../src/ASF/sam0/drivers/system/interrupt/system_interrupt_samd21 + ../src/ASF/common/utils + ../src/ASF/sam0/boards/samd21_xplained_pro + ../src/ASF/sam0/drivers/system/pinmux + ../src + ../src/ASF/sam0/utils/preprocessor + ../src/ASF/sam0/utils/cmsis/samd21/include + ../src/ASF/sam0/drivers/system + ../src/ASF/common/boards + ../src/ASF/sam0/drivers/port + ../src/ASF/sam0/utils/cmsis/samd21/source + ../src/ASF/sam0/drivers/system/clock/clock_samd21_r21 + ../src/ASF/sam0/drivers/system/clock + ../src/ASF/sam0/boards + ../src/ASF/sam0/drivers/system/interrupt + ../src/ASF/sam0/utils + ../src/ASF/thirdparty/CMSIS/Include + ../src/ASF/common/services/sleepmgr + ../src/ASF/common/services/usb + ../src/ASF/common/services/usb/class/cdc + ../src/ASF/common/services/usb/class/cdc/device + ../src/ASF/common/services/usb/udc + ../src/ASF/sam0/drivers/usb + ../src/ASF/sam0/drivers/usb/stack_interface + ../src/ASF/sam0/drivers/extint + ../src/ASF/sam0/drivers/nvm + ../src/ASF/sam0/drivers/rtc + + + Optimize for size (-Os) + -fdata-sections -ffunction-sections + True + True + True + Maximum (-g3) + True + -pipe -fno-strict-aliasing -Wall -Wstrict-prototypes -Wmissing-prototypes -Werror-implicit-function-declaration -Wpointer-arith -std=gnu99 -ffunction-sections -fdata-sections -Wchar-subscripts -Wcomment -Wformat=2 -Wimplicit-int -Wmain -Wparentheses -Wsequence-point -Wreturn-type -Wswitch -Wtrigraphs -Wunused -Wuninitialized -Wunknown-pragmas -Wfloat-equal -Wundef -Wshadow -Wbad-function-cast -Wwrite-strings -Wsign-compare -Waggregate-return -Wmissing-declarations -Wformat -Wmissing-format-attribute -Wno-deprecated-declarations -Wpacked -Wredundant-decls -Wnested-externs -Wlong-long -Wunreachable-code -Wcast-align --param max-inline-insns-single=500 + True + + + libarm_cortexM0l_math + libm + + + + + ../cmsis/linkerScripts + ../src/ASF/thirdparty/CMSIS/Lib/GCC + + + True + + -Wl,--entry=Reset_Handler -Wl,--cref -mthumb -T../src/ASF/sam0/utils/linker_scripts/samd21/gcc/samd21j18a_flash.ld + Default (-g) + -DARM_MATH_CM0=true -DBOARD=SAMD21_XPLAINED_PRO -D__SAMD21J18A__ -DUSB_DEVICE_LPM_SUPPORT -DUDD_ENABLE -DEXTINT_CALLBACK_MODE=true -DRTC_COUNT_ASYNC=true + False + + + ../common2/applications/xplained_pro_user_application/samd21j18a_samd21_xplained_pro/config + ../src/ASF/sam0/utils/header_files + ../src/ASF/thirdparty/CMSIS/Lib/GCC + ../src/config + ../src/ASF/sam0/drivers/system/interrupt/system_interrupt_samd21 + ../src/ASF/common/utils + ../src/ASF/sam0/boards/samd21_xplained_pro + ../src/ASF/sam0/drivers/system/pinmux + ../src + ../src/ASF/sam0/utils/preprocessor + ../src/ASF/sam0/utils/cmsis/samd21/include + ../src/ASF/sam0/drivers/system + ../src/ASF/common/boards + ../src/ASF/sam0/drivers/port + ../src/ASF/sam0/utils/cmsis/samd21/source + ../src/ASF/sam0/drivers/system/clock/clock_samd21_r21 + ../src/ASF/sam0/drivers/system/clock + ../src/ASF/sam0/boards + ../src/ASF/sam0/drivers/system/interrupt + ../src/ASF/sam0/utils + ../src/ASF/thirdparty/CMSIS/Include + ../src/ASF/common/services/sleepmgr + ../src/ASF/common/services/usb + ../src/ASF/common/services/usb/class/cdc + ../src/ASF/common/services/usb/class/cdc/device + ../src/ASF/common/services/usb/udc + ../src/ASF/sam0/drivers/usb + ../src/ASF/sam0/drivers/usb/stack_interface + ../src/ASF/sam0/drivers/nvm + ../src/ASF/sam0/drivers/rtc + + + Default (-Wa,-g) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + + \ No newline at end of file diff --git a/bootloaders/mzero/Bootloader_D21/atmel_devices_cdc.cat b/bootloaders/mzero/Bootloader_D21/atmel_devices_cdc.cat new file mode 100644 index 0000000..09a0673 Binary files /dev/null and b/bootloaders/mzero/Bootloader_D21/atmel_devices_cdc.cat differ diff --git a/bootloaders/mzero/Bootloader_D21/atmel_devices_cdc.inf b/bootloaders/mzero/Bootloader_D21/atmel_devices_cdc.inf new file mode 100644 index 0000000..1be33f7 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/atmel_devices_cdc.inf @@ -0,0 +1,182 @@ +; Windows 2000, XP, Vista, 7 and 8 (x32 and x64) setup file for Atmel CDC Devices +; Copyright (c) 2000-2013 ATMEL, Inc. + +[Version] +Signature = "$Windows NT$" +Class = Ports +ClassGuid = {4D36E978-E325-11CE-BFC1-08002BE10318} + +Provider = %Manufacturer% +LayoutFile = layout.inf +CatalogFile = atmel_devices_cdc.cat +DriverVer = 01/08/2013,6.0.0.0 + +;---------------------------------------------------------- +; Targets +;---------------------------------------------------------- +[Manufacturer] +%Manufacturer%=DeviceList, NTAMD64, NTIA64, NT + +[DeviceList] +%ATMEL_CDC_XPLAINED%=DriverInstall, USB\VID_03EB&PID_2122 +%ATMEL_CDC_USB_ZIGBIT_Sub%=DriverInstall, USB\VID_03EB&PID_214B +%ATMEL_CDC_USB_ZIGBIT_2_4%=DriverInstall, USB\VID_03EB&PID_214A +%ATMEL_CDC_SFW_EXAMPLE%=DriverInstall, USB\VID_03EB&PID_2307 +%ATMEL_CDC_EVK1XXX%=DriverInstall, USB\VID_03EB&PID_2310 +%ATMEL_CDC_ASF_EXAMPLE%=DriverInstall, USB\VID_03EB&PID_2404 +%ATMEL_CDC_ASF_COMPOSITE_EXAMPLE2%=DriverInstall, USB\VID_03EB&PID_2421&MI_00 +%ATMEL_CDC_ASF_COMPOSITE_EXAMPLE4%=DriverInstall, USB\VID_03EB&PID_2424&MI_00 +%ATMEL_CDC_ASF_EXAMPLE2_COM1%=DriverInstall, USB\VID_03EB&PID_2425&MI_00 +%ATMEL_CDC_ASF_EXAMPLE2_COM2%=DriverInstall, USB\VID_03EB&PID_2425&MI_02 +%ATMEL_CDC_ASF_EXAMPLE3_COM1%=DriverInstall, USB\VID_03EB&PID_2426&MI_00 +%ATMEL_CDC_ASF_EXAMPLE3_COM2%=DriverInstall, USB\VID_03EB&PID_2426&MI_02 +%ATMEL_CDC_ASF_EXAMPLE3_COM3%=DriverInstall, USB\VID_03EB&PID_2426&MI_04 +%ATMEL_CDC_ASF_EXAMPLE3_COM4%=DriverInstall, USB\VID_03EB&PID_2426&MI_06 +%ATMEL_CDC_ASF_EXAMPLE3_COM5%=DriverInstall, USB\VID_03EB&PID_2426&MI_08 +%ATMEL_CDC_ASF_EXAMPLE3_COM6%=DriverInstall, USB\VID_03EB&PID_2426&MI_0A +%ATMEL_CDC_ASF_EXAMPLE3_COM7%=DriverInstall, USB\VID_03EB&PID_2426&MI_0C + +[DeviceList.NTAMD64] +%ATMEL_CDC_XPLAINED%=DriverInstall.NTamd64, USB\VID_03EB&PID_2122 +%ATMEL_CDC_USB_ZIGBIT_Sub%=DriverInstall.NTamd64, USB\VID_03EB&PID_214B +%ATMEL_CDC_USB_ZIGBIT_2_4%=DriverInstall.NTamd64, USB\VID_03EB&PID_214A +%ATMEL_CDC_SFW_EXAMPLE%=DriverInstall.NTamd64, USB\VID_03EB&PID_2307 +%ATMEL_CDC_EVK1XXX%=DriverInstall.NTamd64, USB\VID_03EB&PID_2310 +%ATMEL_CDC_ASF_EXAMPLE%=DriverInstall.NTamd64, USB\VID_03EB&PID_2404 +%ATMEL_CDC_ASF_COMPOSITE_EXAMPLE2%=DriverInstall.NTamd64, USB\VID_03EB&PID_2421&MI_00 +%ATMEL_CDC_ASF_COMPOSITE_EXAMPLE4%=DriverInstall.NTamd64, USB\VID_03EB&PID_2424&MI_00 +%ATMEL_CDC_ASF_EXAMPLE2_COM1%=DriverInstall.NTamd64, USB\VID_03EB&PID_2425&MI_00 +%ATMEL_CDC_ASF_EXAMPLE2_COM2%=DriverInstall.NTamd64, USB\VID_03EB&PID_2425&MI_02 +%ATMEL_CDC_ASF_EXAMPLE3_COM1%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_00 +%ATMEL_CDC_ASF_EXAMPLE3_COM2%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_02 +%ATMEL_CDC_ASF_EXAMPLE3_COM3%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_04 +%ATMEL_CDC_ASF_EXAMPLE3_COM4%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_06 +%ATMEL_CDC_ASF_EXAMPLE3_COM5%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_08 +%ATMEL_CDC_ASF_EXAMPLE3_COM6%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_0A +%ATMEL_CDC_ASF_EXAMPLE3_COM7%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_0C + +[DeviceList.NTIA64] +%ATMEL_CDC_XPLAINED%=DriverInstall.NTamd64, USB\VID_03EB&PID_2122 +%ATMEL_CDC_USB_ZIGBIT_Sub%=DriverInstall.NTamd64, USB\VID_03EB&PID_214B +%ATMEL_CDC_USB_ZIGBIT_2_4%=DriverInstall.NTamd64, USB\VID_03EB&PID_214A +%ATMEL_CDC_SFW_EXAMPLE%=DriverInstall.NTamd64, USB\VID_03EB&PID_2307 +%ATMEL_CDC_EVK1XXX%=DriverInstall.NTamd64, USB\VID_03EB&PID_2310 +%ATMEL_CDC_ASF_EXAMPLE%=DriverInstall.NTamd64, USB\VID_03EB&PID_2404 +%ATMEL_CDC_ASF_COMPOSITE_EXAMPLE2%=DriverInstall.NTamd64, USB\VID_03EB&PID_2421&MI_00 +%ATMEL_CDC_ASF_COMPOSITE_EXAMPLE4%=DriverInstall.NTamd64, USB\VID_03EB&PID_2424&MI_00 +%ATMEL_CDC_ASF_EXAMPLE2_COM1%=DriverInstall.NTamd64, USB\VID_03EB&PID_2425&MI_00 +%ATMEL_CDC_ASF_EXAMPLE2_COM2%=DriverInstall.NTamd64, USB\VID_03EB&PID_2425&MI_02 +%ATMEL_CDC_ASF_EXAMPLE3_COM1%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_00 +%ATMEL_CDC_ASF_EXAMPLE3_COM2%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_02 +%ATMEL_CDC_ASF_EXAMPLE3_COM3%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_04 +%ATMEL_CDC_ASF_EXAMPLE3_COM4%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_06 +%ATMEL_CDC_ASF_EXAMPLE3_COM5%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_08 +%ATMEL_CDC_ASF_EXAMPLE3_COM6%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_0A +%ATMEL_CDC_ASF_EXAMPLE3_COM7%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_0C + +[DeviceList.NT] +%ATMEL_CDC_XPLAINED%=DriverInstall.NT, USB\VID_03EB&PID_2122 +%ATMEL_CDC_USB_ZIGBIT_Sub%=DriverInstall.NT, USB\VID_03EB&PID_214B +%ATMEL_CDC_USB_ZIGBIT_2_4%=DriverInstall.NT, USB\VID_03EB&PID_214A +%ATMEL_CDC_SFW_EXAMPLE%=DriverInstall.NT, USB\VID_03EB&PID_2307 +%ATMEL_CDC_EVK1XXX%=DriverInstall.NT, USB\VID_03EB&PID_2310 +%ATMEL_CDC_ASF_EXAMPLE%=DriverInstall.NT, USB\VID_03EB&PID_2404 +%ATMEL_CDC_ASF_COMPOSITE_EXAMPLE2%=DriverInstall.NT, USB\VID_03EB&PID_2421&MI_00 +%ATMEL_CDC_ASF_COMPOSITE_EXAMPLE4%=DriverInstall.NT, USB\VID_03EB&PID_2424&MI_00 +%ATMEL_CDC_ASF_EXAMPLE2_COM1%=DriverInstall.NT, USB\VID_03EB&PID_2425&MI_00 +%ATMEL_CDC_ASF_EXAMPLE2_COM2%=DriverInstall.NT, USB\VID_03EB&PID_2425&MI_02 +%ATMEL_CDC_ASF_EXAMPLE3_COM1%=DriverInstall.NT, USB\VID_03EB&PID_2426&MI_00 +%ATMEL_CDC_ASF_EXAMPLE3_COM2%=DriverInstall.NT, USB\VID_03EB&PID_2426&MI_02 +%ATMEL_CDC_ASF_EXAMPLE3_COM3%=DriverInstall.NT, USB\VID_03EB&PID_2426&MI_04 +%ATMEL_CDC_ASF_EXAMPLE3_COM4%=DriverInstall.NT, USB\VID_03EB&PID_2426&MI_06 +%ATMEL_CDC_ASF_EXAMPLE3_COM5%=DriverInstall.NT, USB\VID_03EB&PID_2426&MI_08 +%ATMEL_CDC_ASF_EXAMPLE3_COM6%=DriverInstall.NT, USB\VID_03EB&PID_2426&MI_0A +%ATMEL_CDC_ASF_EXAMPLE3_COM7%=DriverInstall.NT, USB\VID_03EB&PID_2426&MI_0C + +;---------------------------------------------------------- +; Windows 2000, XP, Vista, Windows 7, Windows 8 - 32bit +;---------------------------------------------------------- +[Reader_Install.NTx86] + + +[DestinationDirs] +DefaultDestDir=12 +DriverInstall.NT.Copy=12 + +[DriverInstall.NT] +include=mdmcpq.inf +CopyFiles=DriverInstall.NT.Copy +AddReg=DriverInstall.NT.AddReg + +[DriverInstall.NT.Copy] +usbser.sys + +[DriverInstall.NT.AddReg] +HKR,,DevLoader,,*ntkern +HKR,,NTMPDriver,,usbser.sys +HKR,,EnumPropPages32,,"MsPorts.dll,SerialPortPropPageProvider" + +[DriverInstall.NT.Services] +AddService = usbser, 0x00000002, DriverService.NT + +[DriverService.NT] +DisplayName = %Serial.SvcDesc% +ServiceType = 1 ; SERVICE_KERNEL_DRIVER +StartType = 3 ; SERVICE_DEMAND_START +ErrorControl = 1 ; SERVICE_ERROR_NORMAL +ServiceBinary = %12%\usbser.sys +LoadOrderGroup = Base + +;---------------------------------------------------------- +; Windows XP, Vista, Windows 7, Windows 8 - 64bit +;---------------------------------------------------------- + +[DriverInstall.NTamd64] +include=mdmcpq.inf +CopyFiles=DriverCopyFiles.NTamd64 +AddReg=DriverInstall.NTamd64.AddReg + +[DriverCopyFiles.NTamd64] +usbser.sys,,,0x20 + +[DriverInstall.NTamd64.AddReg] +HKR,,DevLoader,,*ntkern +HKR,,NTMPDriver,,usbser.sys +HKR,,EnumPropPages32,,"MsPorts.dll,SerialPortPropPageProvider" + +[DriverInstall.NTamd64.Services] +AddService=usbser, 0x00000002, DriverService.NTamd64 + +[DriverService.NTamd64] +DisplayName=%Serial.SvcDesc% +ServiceType=1 +StartType=3 +ErrorControl=1 +ServiceBinary=%12%\usbser.sys + +;---------------------------------------------------------- +; String +;---------------------------------------------------------- + +[Strings] +Manufacturer = "ATMEL, Inc." +ATMEL_CDC_XPLAINED = "XPLAINED Virtual Com Port" +ATMEL_CDC_USB_ZIGBIT_Sub = "ZigBit SubGHz USBstick Com Port" +ATMEL_CDC_USB_ZIGBIT_2_4 = "ZigBit 2.4GHz USBstick Com Port" +ATMEL_CDC_SFW_EXAMPLE = "Communication Device Class SFW example" +ATMEL_CDC_EVK1XXX = "EVK1XXX Virtual Com Port" +ATMEL_CDC_ASF_EXAMPLE = "Communication Device Class ASF example" +ATMEL_CDC_ASF_COMPOSITE_EXAMPLE2 = "Communication Device Class ASF composite example 2" +ATMEL_CDC_ASF_COMPOSITE_EXAMPLE4 = "Communication Device Class ASF composite example 4" +ATMEL_CDC_ASF_EXAMPLE2_COM1 = "Communication Device Class ASF example2, COM1" +ATMEL_CDC_ASF_EXAMPLE2_COM2 = "Communication Device Class ASF example2, COM2" +ATMEL_CDC_ASF_EXAMPLE3_COM1 = "Communication Device Class ASF example3, COM1" +ATMEL_CDC_ASF_EXAMPLE3_COM2 = "Communication Device Class ASF example3, COM2" +ATMEL_CDC_ASF_EXAMPLE3_COM3 = "Communication Device Class ASF example3, COM3" +ATMEL_CDC_ASF_EXAMPLE3_COM4 = "Communication Device Class ASF example3, COM4" +ATMEL_CDC_ASF_EXAMPLE3_COM5 = "Communication Device Class ASF example3, COM5" +ATMEL_CDC_ASF_EXAMPLE3_COM6 = "Communication Device Class ASF example3, COM6" +ATMEL_CDC_ASF_EXAMPLE3_COM7 = "Communication Device Class ASF example3, COM7" + +Serial.SvcDesc = "USB Serial emulation driver" + diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/boards/board.h b/bootloaders/mzero/Bootloader_D21/src/ASF/common/boards/board.h new file mode 100644 index 0000000..4de2e81 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/boards/board.h @@ -0,0 +1,383 @@ +/** + * \file + * + * \brief Standard board header file. + * + * This file includes the appropriate board header file according to the + * defined board (parameter BOARD). + * + * Copyright (c) 2009-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _BOARD_H_ +#define _BOARD_H_ + +/** + * \defgroup group_common_boards Generic board support + * + * The generic board support module includes board-specific definitions + * and function prototypes, such as the board initialization function. + * + * \{ + */ + +#include "compiler.h" + +#ifdef __cplusplus +extern "C" { +#endif + + +/*! \name Base Boards + */ +//! @{ +#define EVK1100 1 //!< AT32UC3A EVK1100 board. +#define EVK1101 2 //!< AT32UC3B EVK1101 board. +#define UC3C_EK 3 //!< AT32UC3C UC3C-EK board. +#define EVK1104 4 //!< AT32UC3A3 EVK1104 board. +#define EVK1105 5 //!< AT32UC3A EVK1105 board. +#define STK600_RCUC3L0 6 //!< STK600 RCUC3L0 board. +#define UC3L_EK 7 //!< AT32UC3L-EK board. +#define XPLAIN 8 //!< ATxmega128A1 Xplain board. +#define STK600_RC064X 10 //!< ATxmega256A3 STK600 board. +#define STK600_RC100X 11 //!< ATxmega128A1 STK600 board. +#define UC3_A3_XPLAINED 13 //!< ATUC3A3 UC3-A3 Xplained board. +#define UC3_L0_XPLAINED 15 //!< ATUC3L0 UC3-L0 Xplained board. +#define STK600_RCUC3D 16 //!< STK600 RCUC3D board. +#define STK600_RCUC3C0 17 //!< STK600 RCUC3C board. +#define XMEGA_B1_XPLAINED 18 //!< ATxmega128B1 Xplained board. +#define XMEGA_A1_XPLAINED 19 //!< ATxmega128A1 Xplain-A1 board. +#define XMEGA_A1U_XPLAINED_PRO 20 //!< ATxmega128A1U XMEGA-A1U Xplained Pro board. +#define STK600_RCUC3L4 21 //!< ATUCL4 STK600 board +#define UC3_L0_XPLAINED_BC 22 //!< ATUC3L0 UC3-L0 Xplained board controller board +#define MEGA1284P_XPLAINED_BC 23 //!< ATmega1284P-Xplained board controller board +#define STK600_RC044X 24 //!< STK600 with RC044X routing card board. +#define STK600_RCUC3B0 25 //!< STK600 RCUC3B0 board. +#define UC3_L0_QT600 26 //!< QT600 UC3L0 MCU board. +#define XMEGA_A3BU_XPLAINED 27 //!< ATxmega256A3BU Xplained board. +#define STK600_RC064X_LCDX 28 //!< XMEGAB3 STK600 RC064X LCDX board. +#define STK600_RC100X_LCDX 29 //!< XMEGAB1 STK600 RC100X LCDX board. +#define UC3B_BOARD_CONTROLLER 30 //!< AT32UC3B1 board controller for Atmel boards +#define RZ600 31 //!< AT32UC3A RZ600 MCU board +#define SAM3S_EK 32 //!< SAM3S-EK board. +#define SAM3U_EK 33 //!< SAM3U-EK board. +#define SAM3X_EK 34 //!< SAM3X-EK board. +#define SAM3N_EK 35 //!< SAM3N-EK board. +#define SAM3S_EK2 36 //!< SAM3S-EK2 board. +#define SAM4S_EK 37 //!< SAM4S-EK board. +#define STK600_RCUC3A0 38 //!< STK600 RCUC3A0 board. +#define STK600_MEGA 39 //!< STK600 MEGA board. +#define MEGA_1284P_XPLAINED 40 //!< ATmega1284P Xplained board. +#define SAM4S_XPLAINED 41 //!< SAM4S Xplained board. +#define ATXMEGA128A1_QT600 42 //!< QT600 ATXMEGA128A1 MCU board. +#define ARDUINO_DUE_X 43 //!< Arduino Due/X board. +#define STK600_RCUC3L3 44 //!< ATUCL3 STK600 board +#define SAM4L_EK 45 //!< SAM4L-EK board. +#define STK600_MEGA_RF 46 //!< STK600 MEGA RF EVK board. +#define XMEGA_C3_XPLAINED 47 //!< ATxmega384C3 Xplained board. +#define STK600_RC032X 48 //!< STK600 with RC032X routing card board. +#define SAM4S_EK2 49 //!< SAM4S-EK2 board. +#define XMEGA_E5_XPLAINED 50 //!< ATxmega32E5 Xplained board. +#define SAM4E_EK 51 //!< SAM4E-EK board. +#define ATMEGA256RFR2_XPLAINED_PRO 52 //!< ATmega256RFR2 Xplained Pro board. +#define SAM4S_XPLAINED_PRO 53 //!< SAM4S Xplained Pro board. +#define SAM4L_XPLAINED_PRO 54 //!< SAM4L Xplained Pro board. +#define ATMEGA256RFR2_ZIGBIT 55 //!< ATmega256RFR2 zigbit +#define XMEGA_RF233_ZIGBIT 56 //!< ATxmega256A3U with AT86RF233 Zigbit +#define XMEGA_RF212B_ZIGBIT 57 //!< ATxmega256A3U with AT86RF212B Zigbit +#define SAM4S_WPIR_RD 58 //!< SAM4S-WPIR-RD board. +#define SAMD20_XPLAINED_PRO 59 //!< SAM D20 Xplained Pro board +#define SAM4L8_XPLAINED_PRO 60 //!< SAM4L8 Xplained Pro board. +#define SAM4N_XPLAINED_PRO 61 //!< SAM4N Xplained Pro board. +#define XMEGA_A3_REB_CBB 62 //!< XMEGA REB Controller Base board. +#define ATMEGARFX_RCB 63 //!< RFR2 & RFA1 RCB +#define SAM4C_EK 64 //!< SAM4C-EK board. +#define RCB256RFR2_XPRO 65 //!< RFR2 RCB Xplained Pro board. +#define SAMG53_XPLAINED_PRO 66 //!< SAMG53 Xplained Pro board. +#define SAM4CP16BMB 67 //!< SAM4CP16BMB board. +#define SAM4E_XPLAINED_PRO 68 //!< SAM4E Xplained Pro board. +#define SAMD21_XPLAINED_PRO 69 //!< SAM D21 Xplained Pro board. +#define SAMR21_XPLAINED_PRO 70 //!< SAM R21 Xplained Pro board. +#define SAM4CMP_DB 71 //!< SAM4CMP demo board. +#define SAM4CMS_DB 72 //!< SAM4CMS demo board. +#define ATPL230AMB 73 //!< ATPL230AMB board. +#define SAMD11_XPLAINED_PRO 74 //!< SAM D11 Xplained Pro board. +#define SIMULATOR_XMEGA_A1 97 //!< Simulator for XMEGA A1 devices +#define AVR_SIMULATOR_UC3 98 //!< Simulator for the AVR UC3 device family. +#define USER_BOARD 99 //!< User-reserved board (if any). +#define DUMMY_BOARD 100 //!< Dummy board to support board-independent applications (e.g. bootloader) +//! @} + +/*! \name Extension Boards + */ +//! @{ +#define EXT1102 1 //!< AT32UC3B EXT1102 board +#define MC300 2 //!< AT32UC3 MC300 board +#define SENSORS_XPLAINED_INERTIAL_1 3 //!< Xplained inertial sensor board 1 +#define SENSORS_XPLAINED_INERTIAL_2 4 //!< Xplained inertial sensor board 2 +#define SENSORS_XPLAINED_PRESSURE_1 5 //!< Xplained pressure sensor board +#define SENSORS_XPLAINED_LIGHTPROX_1 6 //!< Xplained light & proximity sensor board +#define SENSORS_XPLAINED_INERTIAL_A1 7 //!< Xplained inertial sensor board "A" +#define RZ600_AT86RF231 8 //!< AT86RF231 RF board in RZ600 +#define RZ600_AT86RF230B 9 //!< AT86RF230B RF board in RZ600 +#define RZ600_AT86RF212 10 //!< AT86RF212 RF board in RZ600 +#define SENSORS_XPLAINED_BREADBOARD 11 //!< Xplained sensor development breadboard +#define SECURITY_XPLAINED 12 //!< Xplained ATSHA204 board +#define USER_EXT_BOARD 99 //!< User-reserved extension board (if any). +//! @} + +#if BOARD == EVK1100 +# include "evk1100/evk1100.h" +#elif BOARD == EVK1101 +# include "evk1101/evk1101.h" +#elif BOARD == UC3C_EK +# include "uc3c_ek/uc3c_ek.h" +#elif BOARD == EVK1104 +# include "evk1104/evk1104.h" +#elif BOARD == EVK1105 +# include "evk1105/evk1105.h" +#elif BOARD == STK600_RCUC3L0 +# include "stk600/rcuc3l0/stk600_rcuc3l0.h" +#elif BOARD == UC3L_EK +# include "uc3l_ek/uc3l_ek.h" +#elif BOARD == STK600_RCUC3L4 +# include "stk600/rcuc3l4/stk600_rcuc3l4.h" +#elif BOARD == XPLAIN +# include "xplain/xplain.h" +#elif BOARD == STK600_MEGA + /*No header-file to include*/ +#elif BOARD == STK600_MEGA_RF +# include "stk600.h" +#elif BOARD == ATMEGA256RFR2_XPLAINED_PRO +# include "atmega256rfr2_xplained_pro/atmega256rfr2_xplained_pro.h" +#elif BOARD == ATMEGA256RFR2_ZIGBIT +# include "atmega256rfr2_zigbit/atmega256rfr2_zigbit.h" +#elif BOARD == STK600_RC032X +# include "stk600/rc032x/stk600_rc032x.h" +#elif BOARD == STK600_RC044X +# include "stk600/rc044x/stk600_rc044x.h" +#elif BOARD == STK600_RC064X +# include "stk600/rc064x/stk600_rc064x.h" +#elif BOARD == STK600_RC100X +# include "stk600/rc100x/stk600_rc100x.h" +#elif BOARD == UC3_A3_XPLAINED +# include "uc3_a3_xplained/uc3_a3_xplained.h" +#elif BOARD == UC3_L0_XPLAINED +# include "uc3_l0_xplained/uc3_l0_xplained.h" +#elif BOARD == STK600_RCUC3B0 +# include "stk600/rcuc3b0/stk600_rcuc3b0.h" +#elif BOARD == STK600_RCUC3D +# include "stk600/rcuc3d/stk600_rcuc3d.h" +#elif BOARD == STK600_RCUC3C0 +# include "stk600/rcuc3c0/stk600_rcuc3c0.h" +#elif BOARD == SAMG53_XPLAINED_PRO +# include "samg53_xplained_pro/samg53_xplained_pro.h" +#elif BOARD == XMEGA_B1_XPLAINED +# include "xmega_b1_xplained/xmega_b1_xplained.h" +#elif BOARD == STK600_RC064X_LCDX +# include "stk600/rc064x_lcdx/stk600_rc064x_lcdx.h" +#elif BOARD == STK600_RC100X_LCDX +# include "stk600/rc100x_lcdx/stk600_rc100x_lcdx.h" +#elif BOARD == XMEGA_A1_XPLAINED +# include "xmega_a1_xplained/xmega_a1_xplained.h" +#elif BOARD == XMEGA_A1U_XPLAINED_PRO +# include "xmega_a1u_xplained_pro/xmega_a1u_xplained_pro.h" +#elif BOARD == UC3_L0_XPLAINED_BC +# include "uc3_l0_xplained_bc/uc3_l0_xplained_bc.h" +#elif BOARD == SAM3S_EK +# include "sam3s_ek/sam3s_ek.h" +# include "system_sam3s.h" +#elif BOARD == SAM3S_EK2 +# include "sam3s_ek2/sam3s_ek2.h" +# include "system_sam3sd8.h" +#elif BOARD == SAM3U_EK +# include "sam3u_ek/sam3u_ek.h" +# include "system_sam3u.h" +#elif BOARD == SAM3X_EK +# include "sam3x_ek/sam3x_ek.h" +# include "system_sam3x.h" +#elif BOARD == SAM3N_EK +# include "sam3n_ek/sam3n_ek.h" +# include "system_sam3n.h" +#elif BOARD == SAM4S_EK +# include "sam4s_ek/sam4s_ek.h" +# include "system_sam4s.h" +#elif BOARD == SAM4S_WPIR_RD +# include "sam4s_wpir_rd/sam4s_wpir_rd.h" +# include "system_sam4s.h" +#elif BOARD == SAM4S_XPLAINED +# include "sam4s_xplained/sam4s_xplained.h" +# include "system_sam4s.h" +#elif BOARD == SAM4S_EK2 +# include "sam4s_ek2/sam4s_ek2.h" +# include "system_sam4s.h" +#elif BOARD == MEGA_1284P_XPLAINED + /*No header-file to include*/ +#elif BOARD == ARDUINO_DUE_X +# include "arduino_due_x/arduino_due_x.h" +# include "system_sam3x.h" +#elif BOARD == SAM4L_EK +# include "sam4l_ek/sam4l_ek.h" +#elif BOARD == SAM4E_EK +# include "sam4e_ek/sam4e_ek.h" +#elif BOARD == SAMD20_XPLAINED_PRO +# include "samd20_xplained_pro/samd20_xplained_pro.h" +#elif BOARD == SAMD21_XPLAINED_PRO +# include "samd21_xplained_pro/samd21_xplained_pro.h" +#elif BOARD == SAMR21_XPLAINED_PRO +# include "samr21_xplained_pro/samr21_xplained_pro.h" +#elif BOARD == SAMD11_XPLAINED_PRO +# include "samd11_xplained_pro/samd11_xplained_pro.h" +#elif BOARD == SAM4N_XPLAINED_PRO +# include "sam4n_xplained_pro/sam4n_xplained_pro.h" +#elif BOARD == MEGA1284P_XPLAINED_BC +# include "mega1284p_xplained_bc/mega1284p_xplained_bc.h" +#elif BOARD == UC3_L0_QT600 +# include "uc3_l0_qt600/uc3_l0_qt600.h" +#elif BOARD == XMEGA_A3BU_XPLAINED +# include "xmega_a3bu_xplained/xmega_a3bu_xplained.h" +#elif BOARD == XMEGA_E5_XPLAINED +# include "xmega_e5_xplained/xmega_e5_xplained.h" +#elif BOARD == UC3B_BOARD_CONTROLLER +# include "uc3b_board_controller/uc3b_board_controller.h" +#elif BOARD == RZ600 +# include "rz600/rz600.h" +#elif BOARD == STK600_RCUC3A0 +# include "stk600/rcuc3a0/stk600_rcuc3a0.h" +#elif BOARD == ATXMEGA128A1_QT600 +# include "atxmega128a1_qt600/atxmega128a1_qt600.h" +#elif BOARD == STK600_RCUC3L3 +# include "stk600/rcuc3l3/stk600_rcuc3l3.h" +#elif BOARD == SAM4S_XPLAINED_PRO +# include "sam4s_xplained_pro/sam4s_xplained_pro.h" +#elif BOARD == SAM4L_XPLAINED_PRO +# include "sam4l_xplained_pro/sam4l_xplained_pro.h" +#elif BOARD == SAM4L8_XPLAINED_PRO +# include "sam4l8_xplained_pro/sam4l8_xplained_pro.h" +#elif BOARD == SAM4C_EK +# include "sam4c_ek/sam4c_ek.h" +#elif BOARD == SAM4CMP_DB +# include "sam4cmp_db/sam4cmp_db.h" +#elif BOARD == SAM4CMS_DB +# include "sam4cms_db/sam4cms_db.h" +#elif BOARD == SAM4CP16BMB +# include "sam4cp16bmb/sam4cp16bmb.h" +#elif BOARD == ATPL230AMB +# include "atpl230amb/atpl230amb.h" +#elif BOARD == SIMULATOR_XMEGA_A1 +# include "simulator/xmega_a1/simulator_xmega_a1.h" +#elif BOARD == XMEGA_C3_XPLAINED +# include "xmega_c3_xplained/xmega_c3_xplained.h" +#elif BOARD == XMEGA_RF233_ZIGBIT +# include "xmega_rf233_zigbit/xmega_rf233_zigbit.h" +#elif BOARD == XMEGA_A3_REB_CBB +# include "xmega_a3_reb_cbb/xmega_a3_reb_cbb.h" +#elif BOARD == ATMEGARFX_RCB +# include "atmegarfx_rcb/atmegarfx_rcb.h" +#elif BOARD == RCB256RFR2_XPRO +# include "atmega256rfr2_rcb_xpro/atmega256rfr2_rcb_xpro.h" +#elif BOARD == XMEGA_RF212B_ZIGBIT +# include "xmega_rf212b_zigbit/xmega_rf212b_zigbit.h" +#elif BOARD == SAM4E_XPLAINED_PRO +# include "sam4e_xplained_pro/sam4e_xplained_pro.h" +#elif BOARD == AVR_SIMULATOR_UC3 +# include "avr_simulator_uc3/avr_simulator_uc3.h" +#elif BOARD == USER_BOARD + // User-reserved area: #include the header file of your board here (if any). +# include "user_board.h" +#elif BOARD == DUMMY_BOARD +# include "dummy/dummy_board.h" +#else +# error No known Atmel board defined +#endif + +#if (defined EXT_BOARD) +# if EXT_BOARD == MC300 +# include "mc300/mc300.h" +# elif (EXT_BOARD == SENSORS_XPLAINED_INERTIAL_1) || \ + (EXT_BOARD == SENSORS_XPLAINED_INERTIAL_2) || \ + (EXT_BOARD == SENSORS_XPLAINED_INERTIAL_A1) || \ + (EXT_BOARD == SENSORS_XPLAINED_PRESSURE_1) || \ + (EXT_BOARD == SENSORS_XPLAINED_LIGHTPROX_1) || \ + (EXT_BOARD == SENSORS_XPLAINED_BREADBOARD) +# include "sensors_xplained/sensors_xplained.h" +# elif EXT_BOARD == RZ600_AT86RF231 +# include "at86rf231/at86rf231.h" +# elif EXT_BOARD == RZ600_AT86RF230B +# include "at86rf230b/at86rf230b.h" +# elif EXT_BOARD == RZ600_AT86RF212 +# include "at86rf212/at86rf212.h" +# elif EXT_BOARD == SECURITY_XPLAINED +# include "security_xplained.h" +# elif EXT_BOARD == USER_EXT_BOARD + // User-reserved area: #include the header file of your extension board here + // (if any). +# endif +#endif + + +#if (defined(__GNUC__) && defined(__AVR32__)) || (defined(__ICCAVR32__) || defined(__AAVR32__)) +#ifdef __AVR32_ABI_COMPILER__ // Automatically defined when compiling for AVR32, not when assembling. + +/*! \brief This function initializes the board target resources + * + * This function should be called to ensure proper initialization of the target + * board hardware connected to the part. + */ +extern void board_init(void); + +#endif // #ifdef __AVR32_ABI_COMPILER__ +#else +/*! \brief This function initializes the board target resources + * + * This function should be called to ensure proper initialization of the target + * board hardware connected to the part. + */ +extern void board_init(void); +#endif + + +#ifdef __cplusplus +} +#endif + +/** + * \} + */ + +#endif // _BOARD_H_ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/sleepmgr/samd/sleepmgr.c b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/sleepmgr/samd/sleepmgr.c new file mode 100644 index 0000000..cc6dbcf --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/sleepmgr/samd/sleepmgr.c @@ -0,0 +1,50 @@ +/** + * \file + * + * \brief Chip-specific sleep manager configuration + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include +#include + +#if defined(CONFIG_SLEEPMGR_ENABLE) || defined(__DOXYGEN__) + +uint8_t sleepmgr_locks[SLEEPMGR_NR_OF_MODES]; + +#endif /* CONFIG_SLEEPMGR_ENABLE */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/sleepmgr/samd/sleepmgr.h b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/sleepmgr/samd/sleepmgr.h new file mode 100644 index 0000000..2603add --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/sleepmgr/samd/sleepmgr.h @@ -0,0 +1,125 @@ +/** + * \file + * + * \brief Chip-specific sleep manager configuration + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef SAM_SLEEPMGR_INCLUDED +#define SAM_SLEEPMGR_INCLUDED + +#ifdef __cplusplus +extern "C" { +#endif + +#include +#include +#include +#include "system.h" + +/** + * \weakgroup sleepmgr_group + * @{ + */ + +enum sleepmgr_mode { + /** Active mode. */ + SLEEPMGR_ACTIVE = 0, + + /** + * Idle 0 mode. + * Potential Wake Up sources: Synchronous(APB, AHB), asynchronous. + */ + SLEEPMGR_IDLE_0, + + /** + * Idle 1 mode. + * Potential Wake Up sources: Synchronous (APB), asynchronous + */ + SLEEPMGR_IDLE_1, + + /** + * Idle 2 mode. + * Potential Wake Up sources: Asynchronous + */ + SLEEPMGR_IDLE_2, + + /** + * Standby mode. + * Potential Wake Up sources: Asynchronous + */ + SLEEPMGR_STANDBY, + + SLEEPMGR_NR_OF_MODES, +}; + +/** + * \internal + * \name Internal arrays + * @{ + */ +#if defined(CONFIG_SLEEPMGR_ENABLE) || defined(__DOXYGEN__) +/** Sleep mode lock counters */ +extern uint8_t sleepmgr_locks[]; +#endif /* CONFIG_SLEEPMGR_ENABLE */ +/** @} */ + +static inline void sleepmgr_sleep(const enum sleepmgr_mode sleep_mode) +{ + Assert(sleep_mode != SLEEPMGR_ACTIVE); +#ifdef CONFIG_SLEEPMGR_ENABLE + cpu_irq_disable(); + + /* Enter the sleep mode. */ + system_set_sleepmode((enum system_sleepmode)(sleep_mode - 1)); + cpu_irq_enable(); + system_sleep(); +#else + UNUSED(sleep_mode); + cpu_irq_enable(); +#endif /* CONFIG_SLEEPMGR_ENABLE */ +} + +/** @} */ + +#ifdef __cplusplus +} +#endif + +#endif /* SAM_SLEEPMGR_INCLUDED */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/sleepmgr/sleepmgr.h b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/sleepmgr/sleepmgr.h new file mode 100644 index 0000000..cd8a519 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/sleepmgr/sleepmgr.h @@ -0,0 +1,256 @@ +/** + * \file + * + * \brief Sleep manager + * + * Copyright (c) 2010 - 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef SLEEPMGR_H +#define SLEEPMGR_H + +#include +#include + +#if (SAM3S || SAM3U || SAM3N || SAM3XA || SAM4S || SAM4E || SAM4N || SAM4C || SAMG || SAM4CP || SAM4CM) +# include "sam/sleepmgr.h" +#elif XMEGA +# include "xmega/sleepmgr.h" +#elif UC3 +# include "uc3/sleepmgr.h" +#elif SAM4L +# include "sam4l/sleepmgr.h" +#elif MEGA +# include "mega/sleepmgr.h" +#elif (SAMD20 || SAMD21 || SAMR21 || SAMD11) +# include "samd/sleepmgr.h" +#else +# error Unsupported device. +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \defgroup sleepmgr_group Sleep manager + * + * The sleep manager is a service for ensuring that the device is not put to + * sleep in deeper sleep modes than the system (e.g., peripheral drivers, + * services or the application) allows at any given time. + * + * It is based on the use of lock counting for the individual sleep modes, and + * will put the device to sleep in the shallowest sleep mode that has a non-zero + * lock count. The drivers/services/application can change these counts by use + * of \ref sleepmgr_lock_mode and \ref sleepmgr_unlock_mode. + * Refer to \ref sleepmgr_mode for a list of the sleep modes available for + * locking, and the device datasheet for information on their effect. + * + * The application must supply the file \ref conf_sleepmgr.h. + * + * For the sleep manager to be enabled, the symbol \ref CONFIG_SLEEPMGR_ENABLE + * must be defined, e.g., in \ref conf_sleepmgr.h. If this symbol is not + * defined, the functions are replaced with dummy functions and no RAM is used. + * + * @{ + */ + +/** + * \def CONFIG_SLEEPMGR_ENABLE + * \brief Configuration symbol for enabling the sleep manager + * + * If this symbol is not defined, the functions of this service are replaced + * with dummy functions. This is useful for reducing code size and execution + * time if the sleep manager is not needed in the application. + * + * This symbol may be defined in \ref conf_sleepmgr.h. + */ +#if defined(__DOXYGEN__) && !defined(CONFIG_SLEEPMGR_ENABLE) +# define CONFIG_SLEEPMGR_ENABLE +#endif + +/** + * \enum sleepmgr_mode + * \brief Sleep mode locks + * + * Identifiers for the different sleep mode locks. + */ + +/** + * \brief Initialize the lock counts + * + * Sets all lock counts to 0, except the very last one, which is set to 1. This + * is done to simplify the algorithm for finding the deepest allowable sleep + * mode in \ref sleepmgr_enter_sleep. + */ +static inline void sleepmgr_init(void) +{ +#ifdef CONFIG_SLEEPMGR_ENABLE + uint8_t i; + + for (i = 0; i < SLEEPMGR_NR_OF_MODES - 1; i++) { + sleepmgr_locks[i] = 0; + } + sleepmgr_locks[SLEEPMGR_NR_OF_MODES - 1] = 1; +#endif /* CONFIG_SLEEPMGR_ENABLE */ +} + +/** + * \brief Increase lock count for a sleep mode + * + * Increases the lock count for \a mode to ensure that the sleep manager does + * not put the device to sleep in the deeper sleep modes. + * + * \param mode Sleep mode to lock. + */ +static inline void sleepmgr_lock_mode(enum sleepmgr_mode mode) +{ +#ifdef CONFIG_SLEEPMGR_ENABLE + irqflags_t flags; + + Assert(sleepmgr_locks[mode] < 0xff); + + // Enter a critical section + flags = cpu_irq_save(); + + ++sleepmgr_locks[mode]; + + // Leave the critical section + cpu_irq_restore(flags); +#else + UNUSED(mode); +#endif /* CONFIG_SLEEPMGR_ENABLE */ +} + +/** + * \brief Decrease lock count for a sleep mode + * + * Decreases the lock count for \a mode. If the lock count reaches 0, the sleep + * manager can put the device to sleep in the deeper sleep modes. + * + * \param mode Sleep mode to unlock. + */ +static inline void sleepmgr_unlock_mode(enum sleepmgr_mode mode) +{ +#ifdef CONFIG_SLEEPMGR_ENABLE + irqflags_t flags; + + Assert(sleepmgr_locks[mode]); + + // Enter a critical section + flags = cpu_irq_save(); + + --sleepmgr_locks[mode]; + + // Leave the critical section + cpu_irq_restore(flags); +#else + UNUSED(mode); +#endif /* CONFIG_SLEEPMGR_ENABLE */ +} + + /** + * \brief Retrieves the deepest allowable sleep mode + * + * Searches through the sleep mode lock counts, starting at the shallowest sleep + * mode, until the first non-zero lock count is found. The deepest allowable + * sleep mode is then returned. + */ +static inline enum sleepmgr_mode sleepmgr_get_sleep_mode(void) +{ + enum sleepmgr_mode sleep_mode = SLEEPMGR_ACTIVE; + +#ifdef CONFIG_SLEEPMGR_ENABLE + uint8_t *lock_ptr = sleepmgr_locks; + + // Find first non-zero lock count, starting with the shallowest modes. + while (!(*lock_ptr)) { + lock_ptr++; + sleep_mode = (enum sleepmgr_mode)(sleep_mode + 1); + } + + // Catch the case where one too many sleepmgr_unlock_mode() call has been + // performed on the deepest sleep mode. + Assert((uintptr_t)(lock_ptr - sleepmgr_locks) < SLEEPMGR_NR_OF_MODES); + +#endif /* CONFIG_SLEEPMGR_ENABLE */ + + return sleep_mode; +} + +/** + * \fn sleepmgr_enter_sleep + * \brief Go to sleep in the deepest allowed mode + * + * Searches through the sleep mode lock counts, starting at the shallowest sleep + * mode, until the first non-zero lock count is found. The device is then put to + * sleep in the sleep mode that corresponds to the lock. + * + * \note This function enables interrupts before going to sleep, and will leave + * them enabled upon return. This also applies if sleep is skipped due to ACTIVE + * mode being locked. + */ + +static inline void sleepmgr_enter_sleep(void) +{ +#ifdef CONFIG_SLEEPMGR_ENABLE + enum sleepmgr_mode sleep_mode; + + cpu_irq_disable(); + + // Find the deepest allowable sleep mode + sleep_mode = sleepmgr_get_sleep_mode(); + // Return right away if first mode (ACTIVE) is locked. + if (sleep_mode==SLEEPMGR_ACTIVE) { + cpu_irq_enable(); + return; + } + // Enter the deepest allowable sleep mode with interrupts enabled + sleepmgr_sleep(sleep_mode); +#else + cpu_irq_enable(); +#endif /* CONFIG_SLEEPMGR_ENABLE */ +} + + +//! @} + +#ifdef __cplusplus +} +#endif + +#endif /* SLEEPMGR_H */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/class/cdc/device/udi_cdc.c b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/class/cdc/device/udi_cdc.c new file mode 100644 index 0000000..409e33a --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/class/cdc/device/udi_cdc.c @@ -0,0 +1,1100 @@ +/** + * \file + * + * \brief USB Device Communication Device Class (CDC) interface. + * + * Copyright (c) 2009 - 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include "conf_usb.h" +#include "usb_protocol.h" +#include "usb_protocol_cdc.h" +#include "udd.h" +#include "udc.h" +#include "udi_cdc.h" +#include + +#ifdef UDI_CDC_LOW_RATE +# ifdef USB_DEVICE_HS_SUPPORT +# define UDI_CDC_TX_BUFFERS (UDI_CDC_DATA_EPS_HS_SIZE) +# define UDI_CDC_RX_BUFFERS (UDI_CDC_DATA_EPS_HS_SIZE) +# else +# define UDI_CDC_TX_BUFFERS (UDI_CDC_DATA_EPS_FS_SIZE) +# define UDI_CDC_RX_BUFFERS (UDI_CDC_DATA_EPS_FS_SIZE) +# endif +#else +# ifdef USB_DEVICE_HS_SUPPORT +# define UDI_CDC_TX_BUFFERS (UDI_CDC_DATA_EPS_HS_SIZE) +# define UDI_CDC_RX_BUFFERS (UDI_CDC_DATA_EPS_HS_SIZE) +# else +# define UDI_CDC_TX_BUFFERS (5*UDI_CDC_DATA_EPS_FS_SIZE) +# define UDI_CDC_RX_BUFFERS (5*UDI_CDC_DATA_EPS_FS_SIZE) +# endif +#endif + +#ifndef UDI_CDC_TX_EMPTY_NOTIFY +# define UDI_CDC_TX_EMPTY_NOTIFY(port) +#endif + +/** + * \ingroup udi_cdc_group + * \defgroup udi_cdc_group_udc Interface with USB Device Core (UDC) + * + * Structures and functions required by UDC. + * + * @{ + */ +bool udi_cdc_comm_enable(void); +void udi_cdc_comm_disable(void); +bool udi_cdc_comm_setup(void); +bool udi_cdc_data_enable(void); +void udi_cdc_data_disable(void); +bool udi_cdc_data_setup(void); +uint8_t udi_cdc_getsetting(void); +void udi_cdc_data_sof_notify(void); +UDC_DESC_STORAGE udi_api_t udi_api_cdc_comm = { + .enable = udi_cdc_comm_enable, + .disable = udi_cdc_comm_disable, + .setup = udi_cdc_comm_setup, + .getsetting = udi_cdc_getsetting, +}; +UDC_DESC_STORAGE udi_api_t udi_api_cdc_data = { + .enable = udi_cdc_data_enable, + .disable = udi_cdc_data_disable, + .setup = udi_cdc_data_setup, + .getsetting = udi_cdc_getsetting, + .sof_notify = udi_cdc_data_sof_notify, +}; +//@} + +/** + * \ingroup udi_cdc_group + * \defgroup udi_cdc_group_internal Implementation of UDI CDC + * + * Class internal implementation + * @{ + */ + +/** + * \name Internal routines + */ +//@{ + +/** + * \name Routines to control serial line + */ +//@{ + +/** + * \brief Returns the port number corresponding at current setup request + * + * \return port number + */ +static uint8_t udi_cdc_setup_to_port(void); + +/** + * \brief Sends line coding to application + * + * Called after SETUP request when line coding data is received. + */ +static void udi_cdc_line_coding_received(void); + +/** + * \brief Records new state + * + * \param port Communication port number to manage + * \param b_set State is enabled if true, else disabled + * \param bit_mask Field to process (see CDC_SERIAL_STATE_ defines) + */ +static void udi_cdc_ctrl_state_change(uint8_t port, bool b_set, le16_t bit_mask); + +/** + * \brief Check and eventually notify the USB host of new state + * + * \param port Communication port number to manage + * \param ep Port communication endpoint + */ +static void udi_cdc_ctrl_state_notify(uint8_t port, udd_ep_id_t ep); + +/** + * \brief Ack sent of serial state message + * Callback called after serial state message sent + * + * \param status UDD_EP_TRANSFER_OK, if transfer finished + * \param status UDD_EP_TRANSFER_ABORT, if transfer aborted + * \param n number of data transfered + */ +static void udi_cdc_serial_state_msg_sent(udd_ep_status_t status, iram_size_t n, udd_ep_id_t ep); + +//@} + +/** + * \name Routines to process data transfer + */ +//@{ + +/** + * \brief Enable the reception of data from the USB host + * + * The value udi_cdc_rx_trans_sel indicate the RX buffer to fill. + * + * \param port Communication port number to manage + * + * \return \c 1 if function was successfully done, otherwise \c 0. + */ +static bool udi_cdc_rx_start(uint8_t port); + +/** + * \brief Update rx buffer management with a new data + * Callback called after data reception on USB line + * + * \param status UDD_EP_TRANSFER_OK, if transfer finish + * \param status UDD_EP_TRANSFER_ABORT, if transfer aborted + * \param n number of data received + */ +static void udi_cdc_data_received(udd_ep_status_t status, iram_size_t n, udd_ep_id_t ep); + +/** + * \brief Ack sent of tx buffer + * Callback called after data transfer on USB line + * + * \param status UDD_EP_TRANSFER_OK, if transfer finished + * \param status UDD_EP_TRANSFER_ABORT, if transfer aborted + * \param n number of data transfered + */ +static void udi_cdc_data_sent(udd_ep_status_t status, iram_size_t n, udd_ep_id_t ep); + +/** + * \brief Send buffer on line or wait a SOF event + * + * \param port Communication port number to manage + */ +static void udi_cdc_tx_send(uint8_t port); + +//@} + +//@} + +/** + * \name Information about configuration of communication line + */ +//@{ +COMPILER_WORD_ALIGNED + static usb_cdc_line_coding_t udi_cdc_line_coding[UDI_CDC_PORT_NB]; +static bool udi_cdc_serial_state_msg_ongoing[UDI_CDC_PORT_NB]; +static volatile le16_t udi_cdc_state[UDI_CDC_PORT_NB]; +COMPILER_WORD_ALIGNED static usb_cdc_notify_serial_state_t uid_cdc_state_msg[UDI_CDC_PORT_NB]; + +//! Status of CDC COMM interfaces +static volatile uint8_t udi_cdc_nb_comm_enabled = 0; +//@} + +/** + * \name Variables to manage RX/TX transfer requests + * Two buffers for each sense are used to optimize the speed. + */ +//@{ + +//! Status of CDC DATA interfaces +static volatile uint8_t udi_cdc_nb_data_enabled = 0; +static volatile bool udi_cdc_data_running = false; +//! Buffer to receive data +COMPILER_WORD_ALIGNED static uint8_t udi_cdc_rx_buf[UDI_CDC_PORT_NB][2][UDI_CDC_RX_BUFFERS]; +//! Data available in RX buffers +static uint16_t udi_cdc_rx_buf_nb[UDI_CDC_PORT_NB][2]; +//! Give the current RX buffer used (rx0 if 0, rx1 if 1) +static volatile uint8_t udi_cdc_rx_buf_sel[UDI_CDC_PORT_NB]; +//! Read position in current RX buffer +static volatile uint16_t udi_cdc_rx_pos[UDI_CDC_PORT_NB]; +//! Signal a transfer on-going +static volatile bool udi_cdc_rx_trans_ongoing[UDI_CDC_PORT_NB]; + +//! Define a transfer halted +#define UDI_CDC_TRANS_HALTED 2 + +//! Buffer to send data +COMPILER_WORD_ALIGNED static uint8_t udi_cdc_tx_buf[UDI_CDC_PORT_NB][2][UDI_CDC_TX_BUFFERS]; +//! Data available in TX buffers +static uint16_t udi_cdc_tx_buf_nb[UDI_CDC_PORT_NB][2]; +//! Give current TX buffer used (tx0 if 0, tx1 if 1) +static volatile uint8_t udi_cdc_tx_buf_sel[UDI_CDC_PORT_NB]; +//! Value of SOF during last TX transfer +static uint16_t udi_cdc_tx_sof_num[UDI_CDC_PORT_NB]; +//! Signal a transfer on-going +static volatile bool udi_cdc_tx_trans_ongoing[UDI_CDC_PORT_NB]; +//! Signal that both buffer content data to send +static volatile bool udi_cdc_tx_both_buf_to_send[UDI_CDC_PORT_NB]; + +//@} + +bool udi_cdc_comm_enable(void) +{ + uint8_t port; + uint8_t iface_comm_num; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; + udi_cdc_nb_comm_enabled = 0; +#else + if (udi_cdc_nb_comm_enabled > UDI_CDC_PORT_NB) { + udi_cdc_nb_comm_enabled = 0; + } + port = udi_cdc_nb_comm_enabled; +#endif + + // Initialize control signal management + udi_cdc_state[port] = CPU_TO_LE16(0); + + uid_cdc_state_msg[port].header.bmRequestType = + USB_REQ_DIR_IN | USB_REQ_TYPE_CLASS | + USB_REQ_RECIP_INTERFACE; + uid_cdc_state_msg[port].header.bNotification = USB_REQ_CDC_NOTIFY_SERIAL_STATE; + uid_cdc_state_msg[port].header.wValue = LE16(0); + + switch (port) { +#define UDI_CDC_PORT_TO_IFACE_COMM(index, unused) \ + case index: \ + iface_comm_num = UDI_CDC_COMM_IFACE_NUMBER_##index; \ + break; + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_PORT_TO_IFACE_COMM, ~) +#undef UDI_CDC_PORT_TO_IFACE_COMM + default: + iface_comm_num = UDI_CDC_COMM_IFACE_NUMBER_0; + break; + } + + uid_cdc_state_msg[port].header.wIndex = LE16(iface_comm_num); + uid_cdc_state_msg[port].header.wLength = LE16(2); + uid_cdc_state_msg[port].value = CPU_TO_LE16(0); + + udi_cdc_line_coding[port].dwDTERate = CPU_TO_LE32(UDI_CDC_DEFAULT_RATE); + udi_cdc_line_coding[port].bCharFormat = UDI_CDC_DEFAULT_STOPBITS; + udi_cdc_line_coding[port].bParityType = UDI_CDC_DEFAULT_PARITY; + udi_cdc_line_coding[port].bDataBits = UDI_CDC_DEFAULT_DATABITS; + // Call application callback + // to initialize memories or indicate that interface is enabled + UDI_CDC_SET_CODING_EXT(port,(&udi_cdc_line_coding[port])); + if (!UDI_CDC_ENABLE_EXT(port)) { + return false; + } + udi_cdc_nb_comm_enabled++; + return true; +} + +bool udi_cdc_data_enable(void) +{ + uint8_t port; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; + udi_cdc_nb_data_enabled = 0; +#else + if (udi_cdc_nb_data_enabled > UDI_CDC_PORT_NB) { + udi_cdc_nb_data_enabled = 0; + } + port = udi_cdc_nb_data_enabled; +#endif + + // Initialize TX management + udi_cdc_tx_trans_ongoing[port] = false; + udi_cdc_tx_both_buf_to_send[port] = false; + udi_cdc_tx_buf_sel[port] = 0; + udi_cdc_tx_buf_nb[port][0] = 0; + udi_cdc_tx_buf_nb[port][1] = 0; + udi_cdc_tx_sof_num[port] = 0; + udi_cdc_tx_send(port); + + // Initialize RX management + udi_cdc_rx_trans_ongoing[port] = false; + udi_cdc_rx_buf_sel[port] = 0; + udi_cdc_rx_buf_nb[port][0] = 0; + udi_cdc_rx_pos[port] = 0; + if (!udi_cdc_rx_start(port)) { + return false; + } + udi_cdc_nb_data_enabled++; + if (udi_cdc_nb_data_enabled == UDI_CDC_PORT_NB) { + udi_cdc_data_running = true; + } + return true; +} + +void udi_cdc_comm_disable(void) +{ + Assert(udi_cdc_nb_comm_enabled != 0); + udi_cdc_nb_comm_enabled--; +} + +void udi_cdc_data_disable(void) +{ + uint8_t port; + UNUSED(port); + + Assert(udi_cdc_nb_data_enabled != 0); + udi_cdc_nb_data_enabled--; + port = udi_cdc_nb_data_enabled; + UDI_CDC_DISABLE_EXT(port); + udi_cdc_data_running = false; +} + +bool udi_cdc_comm_setup(void) +{ + uint8_t port = udi_cdc_setup_to_port(); + + if (Udd_setup_is_in()) { + // GET Interface Requests + if (Udd_setup_type() == USB_REQ_TYPE_CLASS) { + // Requests Class Interface Get + switch (udd_g_ctrlreq.req.bRequest) { + case USB_REQ_CDC_GET_LINE_CODING: + // Get configuration of CDC line + if (sizeof(usb_cdc_line_coding_t) != + udd_g_ctrlreq.req.wLength) + return false; // Error for USB host + udd_g_ctrlreq.payload = + (uint8_t *) & + udi_cdc_line_coding[port]; + udd_g_ctrlreq.payload_size = + sizeof(usb_cdc_line_coding_t); + return true; + } + } + } + if (Udd_setup_is_out()) { + // SET Interface Requests + if (Udd_setup_type() == USB_REQ_TYPE_CLASS) { + // Requests Class Interface Set + switch (udd_g_ctrlreq.req.bRequest) { + case USB_REQ_CDC_SET_LINE_CODING: + // Change configuration of CDC line + if (sizeof(usb_cdc_line_coding_t) != + udd_g_ctrlreq.req.wLength) + return false; // Error for USB host + udd_g_ctrlreq.callback = + udi_cdc_line_coding_received; + udd_g_ctrlreq.payload = + (uint8_t *) & + udi_cdc_line_coding[port]; + udd_g_ctrlreq.payload_size = + sizeof(usb_cdc_line_coding_t); + return true; + case USB_REQ_CDC_SET_CONTROL_LINE_STATE: + // According cdc spec 1.1 chapter 6.2.14 + UDI_CDC_SET_DTR_EXT(port, (0 != + (udd_g_ctrlreq.req.wValue + & CDC_CTRL_SIGNAL_DTE_PRESENT))); + UDI_CDC_SET_RTS_EXT(port, (0 != + (udd_g_ctrlreq.req.wValue + & CDC_CTRL_SIGNAL_ACTIVATE_CARRIER))); + return true; + } + } + } + return false; // request Not supported +} + +bool udi_cdc_data_setup(void) +{ + return false; // request Not supported +} + +uint8_t udi_cdc_getsetting(void) +{ + return 0; // CDC don't have multiple alternate setting +} + +void udi_cdc_data_sof_notify(void) +{ + static uint8_t port_notify = 0; + + // A call of udi_cdc_data_sof_notify() is done for each port + udi_cdc_tx_send(port_notify); +#if UDI_CDC_PORT_NB != 1 // To optimize code + port_notify++; + if (port_notify >= UDI_CDC_PORT_NB) { + port_notify = 0; + } +#endif +} + + +//------------------------------------------------- +//------- Internal routines to control serial line + +static uint8_t udi_cdc_setup_to_port(void) +{ + uint8_t port; + + switch (udd_g_ctrlreq.req.wIndex & 0xFF) { +#define UDI_CDC_IFACE_COMM_TO_PORT(iface, unused) \ + case UDI_CDC_COMM_IFACE_NUMBER_##iface: \ + port = iface; \ + break; + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_IFACE_COMM_TO_PORT, ~) +#undef UDI_CDC_IFACE_COMM_TO_PORT + default: + port = 0; + break; + } + return port; +} + +static void udi_cdc_line_coding_received(void) +{ + uint8_t port = udi_cdc_setup_to_port(); + UNUSED(port); + + UDI_CDC_SET_CODING_EXT(port, (&udi_cdc_line_coding[port])); +} + +static void udi_cdc_ctrl_state_change(uint8_t port, bool b_set, le16_t bit_mask) +{ + irqflags_t flags; + udd_ep_id_t ep_comm; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + + // Update state + flags = cpu_irq_save(); // Protect udi_cdc_state + if (b_set) { + udi_cdc_state[port] |= bit_mask; + } else { + udi_cdc_state[port] &= ~(unsigned)bit_mask; + } + cpu_irq_restore(flags); + + // Send it if possible and state changed + switch (port) { +#define UDI_CDC_PORT_TO_COMM_EP(index, unused) \ + case index: \ + ep_comm = UDI_CDC_COMM_EP_##index; \ + break; + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_PORT_TO_COMM_EP, ~) +#undef UDI_CDC_PORT_TO_COMM_EP + default: + ep_comm = UDI_CDC_COMM_EP_0; + break; + } + udi_cdc_ctrl_state_notify(port, ep_comm); +} + + +static void udi_cdc_ctrl_state_notify(uint8_t port, udd_ep_id_t ep) +{ +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + + // Send it if possible and state changed + if ((!udi_cdc_serial_state_msg_ongoing[port]) + && (udi_cdc_state[port] != uid_cdc_state_msg[port].value)) { + // Fill notification message + uid_cdc_state_msg[port].value = udi_cdc_state[port]; + // Send notification message + udi_cdc_serial_state_msg_ongoing[port] = + udd_ep_run(ep, + false, + (uint8_t *) & uid_cdc_state_msg[port], + sizeof(uid_cdc_state_msg[0]), + udi_cdc_serial_state_msg_sent); + } +} + + +static void udi_cdc_serial_state_msg_sent(udd_ep_status_t status, iram_size_t n, udd_ep_id_t ep) +{ + uint8_t port; + UNUSED(n); + UNUSED(status); + + switch (ep) { +#define UDI_CDC_GET_PORT_FROM_COMM_EP(iface, unused) \ + case UDI_CDC_COMM_EP_##iface: \ + port = iface; \ + break; + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_GET_PORT_FROM_COMM_EP, ~) +#undef UDI_CDC_GET_PORT_FROM_COMM_EP + default: + port = 0; + break; + } + + udi_cdc_serial_state_msg_ongoing[port] = false; + + // For the irregular signals like break, the incoming ring signal, + // or the overrun error state, this will reset their values to zero + // and again will not send another notification until their state changes. + udi_cdc_state[port] &= ~(CDC_SERIAL_STATE_BREAK | + CDC_SERIAL_STATE_RING | + CDC_SERIAL_STATE_FRAMING | + CDC_SERIAL_STATE_PARITY | CDC_SERIAL_STATE_OVERRUN); + uid_cdc_state_msg[port].value &= ~(CDC_SERIAL_STATE_BREAK | + CDC_SERIAL_STATE_RING | + CDC_SERIAL_STATE_FRAMING | + CDC_SERIAL_STATE_PARITY | CDC_SERIAL_STATE_OVERRUN); + // Send it if possible and state changed + udi_cdc_ctrl_state_notify(port, ep); +} + + +//------------------------------------------------- +//------- Internal routines to process data transfer + + +static bool udi_cdc_rx_start(uint8_t port) +{ + irqflags_t flags; + uint8_t buf_sel_trans; + udd_ep_id_t ep; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + + flags = cpu_irq_save(); + buf_sel_trans = udi_cdc_rx_buf_sel[port]; + if (udi_cdc_rx_trans_ongoing[port] || + (udi_cdc_rx_pos[port] < udi_cdc_rx_buf_nb[port][buf_sel_trans])) { + // Transfer already on-going or current buffer no empty + cpu_irq_restore(flags); + return false; + } + + // Change current buffer + udi_cdc_rx_pos[port] = 0; + udi_cdc_rx_buf_sel[port] = (buf_sel_trans==0)?1:0; + + // Start transfer on RX + udi_cdc_rx_trans_ongoing[port] = true; + cpu_irq_restore(flags); + + if (udi_cdc_multi_is_rx_ready(port)) { + UDI_CDC_RX_NOTIFY(port); + } + // Send the buffer with enable of short packet + switch (port) { +#define UDI_CDC_PORT_TO_DATA_EP_OUT(index, unused) \ + case index: \ + ep = UDI_CDC_DATA_EP_OUT_##index; \ + break; + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_PORT_TO_DATA_EP_OUT, ~) +#undef UDI_CDC_PORT_TO_DATA_EP_OUT + default: + ep = UDI_CDC_DATA_EP_OUT_0; + break; + } + return udd_ep_run(ep, + true, + udi_cdc_rx_buf[port][buf_sel_trans], + UDI_CDC_RX_BUFFERS, + udi_cdc_data_received); +} + + +static void udi_cdc_data_received(udd_ep_status_t status, iram_size_t n, udd_ep_id_t ep) +{ + uint8_t buf_sel_trans; + uint8_t port; + + switch (ep) { +#define UDI_CDC_DATA_EP_OUT_TO_PORT(index, unused) \ + case UDI_CDC_DATA_EP_OUT_##index: \ + port = index; \ + break; + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_DATA_EP_OUT_TO_PORT, ~) +#undef UDI_CDC_DATA_EP_OUT_TO_PORT + default: + port = 0; + break; + } + + if (UDD_EP_TRANSFER_OK != status) { + // Abort reception + return; + } + buf_sel_trans = (udi_cdc_rx_buf_sel[port]==0)?1:0; + if (!n) { + udd_ep_run( ep, + true, + udi_cdc_rx_buf[port][buf_sel_trans], + UDI_CDC_RX_BUFFERS, + udi_cdc_data_received); + return; + } + udi_cdc_rx_buf_nb[port][buf_sel_trans] = n; + udi_cdc_rx_trans_ongoing[port] = false; + udi_cdc_rx_start(port); +} + + +static void udi_cdc_data_sent(udd_ep_status_t status, iram_size_t n, udd_ep_id_t ep) +{ + uint8_t port; + UNUSED(n); + + switch (ep) { +#define UDI_CDC_DATA_EP_IN_TO_PORT(index, unused) \ + case UDI_CDC_DATA_EP_IN_##index: \ + port = index; \ + break; + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_DATA_EP_IN_TO_PORT, ~) +#undef UDI_CDC_DATA_EP_IN_TO_PORT + default: + port = 0; + break; + } + + if (UDD_EP_TRANSFER_OK != status) { + // Abort transfer + return; + } + udi_cdc_tx_buf_nb[port][(udi_cdc_tx_buf_sel[port]==0)?1:0] = 0; + udi_cdc_tx_both_buf_to_send[port] = false; + udi_cdc_tx_trans_ongoing[port] = false; + + if (n != 0) { + UDI_CDC_TX_EMPTY_NOTIFY(port); + } + udi_cdc_tx_send(port); +} + + +static void udi_cdc_tx_send(uint8_t port) +{ + irqflags_t flags; + uint8_t buf_sel_trans; + bool b_short_packet; + udd_ep_id_t ep; + static uint16_t sof_zlp_counter = 0; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + + if (udi_cdc_tx_trans_ongoing[port]) { + return; // Already on going or wait next SOF to send next data + } + if (udd_is_high_speed()) { + if (udi_cdc_tx_sof_num[port] == udd_get_micro_frame_number()) { + return; // Wait next SOF to send next data + } + }else{ + if (udi_cdc_tx_sof_num[port] == udd_get_frame_number()) { + return; // Wait next SOF to send next data + } + } + + flags = cpu_irq_save(); // to protect udi_cdc_tx_buf_sel + buf_sel_trans = udi_cdc_tx_buf_sel[port]; + if (udi_cdc_tx_buf_nb[port][buf_sel_trans] == 0) { + sof_zlp_counter++; + if (((!udd_is_high_speed()) && (sof_zlp_counter < 100)) + || (udd_is_high_speed() && (sof_zlp_counter < 800))) { + cpu_irq_restore(flags); + return; + } + } + sof_zlp_counter = 0; + + if (!udi_cdc_tx_both_buf_to_send[port]) { + // Send current Buffer + // and switch the current buffer + udi_cdc_tx_buf_sel[port] = (buf_sel_trans==0)?1:0; + }else{ + // Send the other Buffer + // and no switch the current buffer + buf_sel_trans = (buf_sel_trans==0)?1:0; + } + udi_cdc_tx_trans_ongoing[port] = true; + cpu_irq_restore(flags); + + b_short_packet = (udi_cdc_tx_buf_nb[port][buf_sel_trans] != UDI_CDC_TX_BUFFERS); + if (b_short_packet) { + if (udd_is_high_speed()) { + udi_cdc_tx_sof_num[port] = udd_get_micro_frame_number(); + }else{ + udi_cdc_tx_sof_num[port] = udd_get_frame_number(); + } + }else{ + udi_cdc_tx_sof_num[port] = 0; // Force next transfer without wait SOF + } + + // Send the buffer with enable of short packet + switch (port) { +#define UDI_CDC_PORT_TO_DATA_EP_IN(index, unused) \ + case index: \ + ep = UDI_CDC_DATA_EP_IN_##index; \ + break; + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_PORT_TO_DATA_EP_IN, ~) +#undef UDI_CDC_PORT_TO_DATA_EP_IN + default: + ep = UDI_CDC_DATA_EP_IN_0; + break; + } + udd_ep_run( ep, + b_short_packet, + udi_cdc_tx_buf[port][buf_sel_trans], + udi_cdc_tx_buf_nb[port][buf_sel_trans], + udi_cdc_data_sent); +} + + +//--------------------------------------------- +//------- Application interface + + +//------- Application interface + +void udi_cdc_ctrl_signal_dcd(bool b_set) +{ + udi_cdc_ctrl_state_change(0, b_set, CDC_SERIAL_STATE_DCD); +} + +void udi_cdc_ctrl_signal_dsr(bool b_set) +{ + udi_cdc_ctrl_state_change(0, b_set, CDC_SERIAL_STATE_DSR); +} + +void udi_cdc_signal_framing_error(void) +{ + udi_cdc_ctrl_state_change(0, true, CDC_SERIAL_STATE_FRAMING); +} + +void udi_cdc_signal_parity_error(void) +{ + udi_cdc_ctrl_state_change(0, true, CDC_SERIAL_STATE_PARITY); +} + +void udi_cdc_signal_overrun(void) +{ + udi_cdc_ctrl_state_change(0, true, CDC_SERIAL_STATE_OVERRUN); +} + +void udi_cdc_multi_ctrl_signal_dcd(uint8_t port, bool b_set) +{ + udi_cdc_ctrl_state_change(port, b_set, CDC_SERIAL_STATE_DCD); +} + +void udi_cdc_multi_ctrl_signal_dsr(uint8_t port, bool b_set) +{ + udi_cdc_ctrl_state_change(port, b_set, CDC_SERIAL_STATE_DSR); +} + +void udi_cdc_multi_signal_framing_error(uint8_t port) +{ + udi_cdc_ctrl_state_change(port, true, CDC_SERIAL_STATE_FRAMING); +} + +void udi_cdc_multi_signal_parity_error(uint8_t port) +{ + udi_cdc_ctrl_state_change(port, true, CDC_SERIAL_STATE_PARITY); +} + +void udi_cdc_multi_signal_overrun(uint8_t port) +{ + udi_cdc_ctrl_state_change(port, true, CDC_SERIAL_STATE_OVERRUN); +} + +iram_size_t udi_cdc_multi_get_nb_received_data(uint8_t port) +{ + irqflags_t flags; + uint16_t pos; + iram_size_t nb_received; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + flags = cpu_irq_save(); + pos = udi_cdc_rx_pos[port]; + nb_received = udi_cdc_rx_buf_nb[port][udi_cdc_rx_buf_sel[port]] - pos; + cpu_irq_restore(flags); + return nb_received; +} + +iram_size_t udi_cdc_get_nb_received_data(void) +{ + return udi_cdc_multi_get_nb_received_data(0); +} + +bool udi_cdc_multi_is_rx_ready(uint8_t port) +{ + return (udi_cdc_multi_get_nb_received_data(port) > 0); +} + +bool udi_cdc_is_rx_ready(void) +{ + return udi_cdc_multi_is_rx_ready(0); +} + +int udi_cdc_multi_getc(uint8_t port) +{ + irqflags_t flags; + int rx_data = 0; + bool b_databit_9; + uint16_t pos; + uint8_t buf_sel; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + + b_databit_9 = (9 == udi_cdc_line_coding[port].bDataBits); + +udi_cdc_getc_process_one_byte: + // Check available data + flags = cpu_irq_save(); + pos = udi_cdc_rx_pos[port]; + buf_sel = udi_cdc_rx_buf_sel[port]; + cpu_irq_restore(flags); + while (pos >= udi_cdc_rx_buf_nb[port][buf_sel]) { + if (!udi_cdc_data_running) { + return 0; + } + goto udi_cdc_getc_process_one_byte; + } + + // Read data + rx_data |= udi_cdc_rx_buf[port][buf_sel][pos]; + udi_cdc_rx_pos[port] = pos+1; + + udi_cdc_rx_start(port); + + if (b_databit_9) { + // Receive MSB + b_databit_9 = false; + rx_data = rx_data << 8; + goto udi_cdc_getc_process_one_byte; + } + return rx_data; +} + +int udi_cdc_getc(void) +{ + return udi_cdc_multi_getc(0); +} + +iram_size_t udi_cdc_multi_read_buf(uint8_t port, void* buf, iram_size_t size) +{ + irqflags_t flags; + uint8_t *ptr_buf = (uint8_t *)buf; + iram_size_t copy_nb; + uint16_t pos; + uint8_t buf_sel; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + +udi_cdc_read_buf_loop_wait: + // Check available data + flags = cpu_irq_save(); + pos = udi_cdc_rx_pos[port]; + buf_sel = udi_cdc_rx_buf_sel[port]; + cpu_irq_restore(flags); + while (pos >= udi_cdc_rx_buf_nb[port][buf_sel]) { + if (!udi_cdc_data_running) { + return size; + } + goto udi_cdc_read_buf_loop_wait; + } + + // Read data + copy_nb = udi_cdc_rx_buf_nb[port][buf_sel] - pos; + if (copy_nb>size) { + copy_nb = size; + } + memcpy(ptr_buf, &udi_cdc_rx_buf[port][buf_sel][pos], copy_nb); + udi_cdc_rx_pos[port] += copy_nb; + ptr_buf += copy_nb; + size -= copy_nb; + udi_cdc_rx_start(port); + + if (size) { + goto udi_cdc_read_buf_loop_wait; + } + return 0; +} + +iram_size_t udi_cdc_read_buf(void* buf, iram_size_t size) +{ + return udi_cdc_multi_read_buf(0, buf, size); +} + +iram_size_t udi_cdc_multi_get_free_tx_buffer(uint8_t port) +{ + irqflags_t flags; + iram_size_t buf_sel_nb, buf_nosel_nb, retval; + uint8_t buf_sel; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + + flags = cpu_irq_save(); + buf_sel = udi_cdc_tx_buf_sel[port]; + buf_sel_nb = udi_cdc_tx_buf_nb[port][buf_sel]; + buf_nosel_nb = udi_cdc_tx_buf_nb[port][(buf_sel == 0)? 1 : 0]; + if (buf_sel_nb == UDI_CDC_TX_BUFFERS) { + if ((!udi_cdc_tx_trans_ongoing[port]) + && (!udi_cdc_tx_both_buf_to_send[port])) { + /* One buffer is full, but the other buffer is not used. + * (not used = transfer on-going) + * then move to the other buffer to store data */ + udi_cdc_tx_both_buf_to_send[port] = true; + udi_cdc_tx_buf_sel[port] = (buf_sel == 0)? 1 : 0; + buf_sel_nb = 0; + buf_nosel_nb = UDI_CDC_TX_BUFFERS; + } + } + retval = UDI_CDC_TX_BUFFERS - buf_sel_nb; + cpu_irq_restore(flags); + return retval; +} + +iram_size_t udi_cdc_get_free_tx_buffer(void) +{ + return udi_cdc_multi_get_free_tx_buffer(0); +} + +bool udi_cdc_multi_is_tx_ready(uint8_t port) +{ + return (udi_cdc_multi_get_free_tx_buffer(port) != 0); +} + +bool udi_cdc_is_tx_ready(void) +{ + return udi_cdc_multi_is_tx_ready(0); +} + +int udi_cdc_multi_putc(uint8_t port, int value) +{ + irqflags_t flags; + bool b_databit_9; + uint8_t buf_sel; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + + b_databit_9 = (9 == udi_cdc_line_coding[port].bDataBits); + +udi_cdc_putc_process_one_byte: + // Check available space + if (!udi_cdc_multi_is_tx_ready(port)) { + if (!udi_cdc_data_running) { + return false; + } + goto udi_cdc_putc_process_one_byte; + } + + // Write value + flags = cpu_irq_save(); + buf_sel = udi_cdc_tx_buf_sel[port]; + udi_cdc_tx_buf[port][buf_sel][udi_cdc_tx_buf_nb[port][buf_sel]++] = value; + cpu_irq_restore(flags); + + if (b_databit_9) { + // Send MSB + b_databit_9 = false; + value = value >> 8; + goto udi_cdc_putc_process_one_byte; + } + return true; +} + +int udi_cdc_putc(int value) +{ + return udi_cdc_multi_putc(0, value); +} + +iram_size_t udi_cdc_multi_write_buf(uint8_t port, const void* buf, iram_size_t size) +{ + irqflags_t flags; + uint8_t buf_sel; + uint16_t buf_nb; + iram_size_t copy_nb; + uint8_t *ptr_buf = (uint8_t *)buf; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + + if (9 == udi_cdc_line_coding[port].bDataBits) { + size *=2; + } + +udi_cdc_write_buf_loop_wait: + // Check available space + if (!udi_cdc_multi_is_tx_ready(port)) { + if (!udi_cdc_data_running) { + return size; + } + goto udi_cdc_write_buf_loop_wait; + } + + // Write values + flags = cpu_irq_save(); + buf_sel = udi_cdc_tx_buf_sel[port]; + buf_nb = udi_cdc_tx_buf_nb[port][buf_sel]; + copy_nb = UDI_CDC_TX_BUFFERS - buf_nb; + if (copy_nb > size) { + copy_nb = size; + } + memcpy(&udi_cdc_tx_buf[port][buf_sel][buf_nb], ptr_buf, copy_nb); + udi_cdc_tx_buf_nb[port][buf_sel] = buf_nb + copy_nb; + cpu_irq_restore(flags); + + // Update buffer pointer + ptr_buf = ptr_buf + copy_nb; + size -= copy_nb; + + if (size) { + goto udi_cdc_write_buf_loop_wait; + } + + return 0; +} + +iram_size_t udi_cdc_write_buf(const void* buf, iram_size_t size) +{ + return udi_cdc_multi_write_buf(0, buf, size); +} + +//@} diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/class/cdc/device/udi_cdc.h b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/class/cdc/device/udi_cdc.h new file mode 100644 index 0000000..ebe9313 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/class/cdc/device/udi_cdc.h @@ -0,0 +1,796 @@ +/** + * \file + * + * \brief USB Device Communication Device Class (CDC) interface definitions. + * + * Copyright (c) 2009 - 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _UDI_CDC_H_ +#define _UDI_CDC_H_ + +#include "conf_usb.h" +#include "usb_protocol.h" +#include "usb_protocol_cdc.h" +#include "udd.h" +#include "udc_desc.h" +#include "udi.h" + +// Check the number of port +#ifndef UDI_CDC_PORT_NB +# define UDI_CDC_PORT_NB 1 +#endif +#if (UDI_CDC_PORT_NB < 1) || (UDI_CDC_PORT_NB > 7) +# error UDI_CDC_PORT_NB must be between 1 and 7 +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \addtogroup udi_cdc_group_udc + * @{ + */ + +//! Global structure which contains standard UDI API for UDC +extern UDC_DESC_STORAGE udi_api_t udi_api_cdc_comm; +extern UDC_DESC_STORAGE udi_api_t udi_api_cdc_data; +//@} + +/** + * \ingroup udi_cdc_group + * \defgroup udi_cdc_group_desc USB interface descriptors + * + * The following structures provide predefined USB interface descriptors. + * It must be used to define the final USB descriptors. + */ +//@{ + +/** + * \brief Communication Class interface descriptor + * + * Interface descriptor with associated functional and endpoint + * descriptors for the CDC Communication Class interface. + */ +typedef struct { + //! Standard interface descriptor + usb_iface_desc_t iface; + //! CDC Header functional descriptor + usb_cdc_hdr_desc_t header; + //! CDC Abstract Control Model functional descriptor + usb_cdc_acm_desc_t acm; + //! CDC Union functional descriptor + usb_cdc_union_desc_t union_desc; + //! CDC Call Management functional descriptor + usb_cdc_call_mgmt_desc_t call_mgmt; + //! Notification endpoint descriptor + usb_ep_desc_t ep_notify; +} udi_cdc_comm_desc_t; + + +/** + * \brief Data Class interface descriptor + * + * Interface descriptor with associated endpoint descriptors for the + * CDC Data Class interface. + */ +typedef struct { + //! Standard interface descriptor + usb_iface_desc_t iface; + //! Data IN/OUT endpoint descriptors + usb_ep_desc_t ep_in; + usb_ep_desc_t ep_out; +} udi_cdc_data_desc_t; + + +//! CDC communication endpoints size for all speeds +#define UDI_CDC_COMM_EP_SIZE 64 +//! CDC data endpoints size for FS speed (8B, 16B, 32B, 64B) +#define UDI_CDC_DATA_EPS_FS_SIZE 64 +//! CDC data endpoints size for HS speed (512B only) +#define UDI_CDC_DATA_EPS_HS_SIZE 512 + +/** + * \name Content of interface descriptors + * Up to 7 CDC interfaces can be implemented on a USB device. + */ +//@{ +//! By default no string associated to these interfaces +#ifndef UDI_CDC_IAD_STRING_ID_0 +#define UDI_CDC_IAD_STRING_ID_0 0 +#endif +#ifndef UDI_CDC_COMM_STRING_ID_0 +#define UDI_CDC_COMM_STRING_ID_0 0 +#endif +#ifndef UDI_CDC_DATA_STRING_ID_0 +#define UDI_CDC_DATA_STRING_ID_0 0 +#endif +#define UDI_CDC_IAD_DESC_0 UDI_CDC_IAD_DESC(0) +#define UDI_CDC_COMM_DESC_0 UDI_CDC_COMM_DESC(0) +#define UDI_CDC_DATA_DESC_0_FS UDI_CDC_DATA_DESC_FS(0) +#define UDI_CDC_DATA_DESC_0_HS UDI_CDC_DATA_DESC_HS(0) + +//! By default no string associated to these interfaces +#ifndef UDI_CDC_IAD_STRING_ID_1 +#define UDI_CDC_IAD_STRING_ID_1 0 +#endif +#ifndef UDI_CDC_COMM_STRING_ID_1 +#define UDI_CDC_COMM_STRING_ID_1 0 +#endif +#ifndef UDI_CDC_DATA_STRING_ID_1 +#define UDI_CDC_DATA_STRING_ID_1 0 +#endif +#define UDI_CDC_IAD_DESC_1 UDI_CDC_IAD_DESC(1) +#define UDI_CDC_COMM_DESC_1 UDI_CDC_COMM_DESC(1) +#define UDI_CDC_DATA_DESC_1_FS UDI_CDC_DATA_DESC_FS(1) +#define UDI_CDC_DATA_DESC_1_HS UDI_CDC_DATA_DESC_HS(1) + +//! By default no string associated to these interfaces +#ifndef UDI_CDC_IAD_STRING_ID_2 +#define UDI_CDC_IAD_STRING_ID_2 0 +#endif +#ifndef UDI_CDC_COMM_STRING_ID_2 +#define UDI_CDC_COMM_STRING_ID_2 0 +#endif +#ifndef UDI_CDC_DATA_STRING_ID_2 +#define UDI_CDC_DATA_STRING_ID_2 0 +#endif +#define UDI_CDC_IAD_DESC_2 UDI_CDC_IAD_DESC(2) +#define UDI_CDC_COMM_DESC_2 UDI_CDC_COMM_DESC(2) +#define UDI_CDC_DATA_DESC_2_FS UDI_CDC_DATA_DESC_FS(2) +#define UDI_CDC_DATA_DESC_2_HS UDI_CDC_DATA_DESC_HS(2) + +//! By default no string associated to these interfaces +#ifndef UDI_CDC_IAD_STRING_ID_3 +#define UDI_CDC_IAD_STRING_ID_3 0 +#endif +#ifndef UDI_CDC_COMM_STRING_ID_3 +#define UDI_CDC_COMM_STRING_ID_3 0 +#endif +#ifndef UDI_CDC_DATA_STRING_ID_3 +#define UDI_CDC_DATA_STRING_ID_3 0 +#endif +#define UDI_CDC_IAD_DESC_3 UDI_CDC_IAD_DESC(3) +#define UDI_CDC_COMM_DESC_3 UDI_CDC_COMM_DESC(3) +#define UDI_CDC_DATA_DESC_3_FS UDI_CDC_DATA_DESC_FS(3) +#define UDI_CDC_DATA_DESC_3_HS UDI_CDC_DATA_DESC_HS(3) + +//! By default no string associated to these interfaces +#ifndef UDI_CDC_IAD_STRING_ID_4 +#define UDI_CDC_IAD_STRING_ID_4 0 +#endif +#ifndef UDI_CDC_COMM_STRING_ID_4 +#define UDI_CDC_COMM_STRING_ID_4 0 +#endif +#ifndef UDI_CDC_DATA_STRING_ID_4 +#define UDI_CDC_DATA_STRING_ID_4 0 +#endif +#define UDI_CDC_IAD_DESC_4 UDI_CDC_IAD_DESC(4) +#define UDI_CDC_COMM_DESC_4 UDI_CDC_COMM_DESC(4) +#define UDI_CDC_DATA_DESC_4_FS UDI_CDC_DATA_DESC_FS(4) +#define UDI_CDC_DATA_DESC_4_HS UDI_CDC_DATA_DESC_HS(4) + +//! By default no string associated to these interfaces +#ifndef UDI_CDC_IAD_STRING_ID_5 +#define UDI_CDC_IAD_STRING_ID_5 0 +#endif +#ifndef UDI_CDC_COMM_STRING_ID_5 +#define UDI_CDC_COMM_STRING_ID_5 0 +#endif +#ifndef UDI_CDC_DATA_STRING_ID_5 +#define UDI_CDC_DATA_STRING_ID_5 0 +#endif +#define UDI_CDC_IAD_DESC_5 UDI_CDC_IAD_DESC(5) +#define UDI_CDC_COMM_DESC_5 UDI_CDC_COMM_DESC(5) +#define UDI_CDC_DATA_DESC_5_FS UDI_CDC_DATA_DESC_FS(5) +#define UDI_CDC_DATA_DESC_5_HS UDI_CDC_DATA_DESC_HS(5) + +//! By default no string associated to these interfaces +#ifndef UDI_CDC_IAD_STRING_ID_6 +#define UDI_CDC_IAD_STRING_ID_6 0 +#endif +#ifndef UDI_CDC_COMM_STRING_ID_6 +#define UDI_CDC_COMM_STRING_ID_6 0 +#endif +#ifndef UDI_CDC_DATA_STRING_ID_6 +#define UDI_CDC_DATA_STRING_ID_6 0 +#endif +#define UDI_CDC_IAD_DESC_6 UDI_CDC_IAD_DESC(6) +#define UDI_CDC_COMM_DESC_6 UDI_CDC_COMM_DESC(6) +#define UDI_CDC_DATA_DESC_6_FS UDI_CDC_DATA_DESC_FS(6) +#define UDI_CDC_DATA_DESC_6_HS UDI_CDC_DATA_DESC_HS(6) +//@} + + +//! Content of CDC IAD interface descriptor for all speeds +#define UDI_CDC_IAD_DESC(port) { \ + .bLength = sizeof(usb_iad_desc_t),\ + .bDescriptorType = USB_DT_IAD,\ + .bInterfaceCount = 2,\ + .bFunctionClass = CDC_CLASS_COMM,\ + .bFunctionSubClass = CDC_SUBCLASS_ACM,\ + .bFunctionProtocol = CDC_PROTOCOL_V25TER,\ + .bFirstInterface = UDI_CDC_COMM_IFACE_NUMBER_##port,\ + .iFunction = UDI_CDC_IAD_STRING_ID_##port,\ + } + +//! Content of CDC COMM interface descriptor for all speeds +#define UDI_CDC_COMM_DESC(port) { \ + .iface.bLength = sizeof(usb_iface_desc_t),\ + .iface.bDescriptorType = USB_DT_INTERFACE,\ + .iface.bAlternateSetting = 0,\ + .iface.bNumEndpoints = 1,\ + .iface.bInterfaceClass = CDC_CLASS_COMM,\ + .iface.bInterfaceSubClass = CDC_SUBCLASS_ACM,\ + .iface.bInterfaceProtocol = CDC_PROTOCOL_V25TER,\ + .header.bFunctionLength = sizeof(usb_cdc_hdr_desc_t),\ + .header.bDescriptorType = CDC_CS_INTERFACE,\ + .header.bDescriptorSubtype = CDC_SCS_HEADER,\ + .header.bcdCDC = LE16(0x0110),\ + .call_mgmt.bFunctionLength = sizeof(usb_cdc_call_mgmt_desc_t),\ + .call_mgmt.bDescriptorType = CDC_CS_INTERFACE,\ + .call_mgmt.bDescriptorSubtype = CDC_SCS_CALL_MGMT,\ + .call_mgmt.bmCapabilities = \ + CDC_CALL_MGMT_SUPPORTED | CDC_CALL_MGMT_OVER_DCI,\ + .acm.bFunctionLength = sizeof(usb_cdc_acm_desc_t),\ + .acm.bDescriptorType = CDC_CS_INTERFACE,\ + .acm.bDescriptorSubtype = CDC_SCS_ACM,\ + .acm.bmCapabilities = CDC_ACM_SUPPORT_LINE_REQUESTS,\ + .union_desc.bFunctionLength = sizeof(usb_cdc_union_desc_t),\ + .union_desc.bDescriptorType = CDC_CS_INTERFACE,\ + .union_desc.bDescriptorSubtype= CDC_SCS_UNION,\ + .ep_notify.bLength = sizeof(usb_ep_desc_t),\ + .ep_notify.bDescriptorType = USB_DT_ENDPOINT,\ + .ep_notify.bmAttributes = USB_EP_TYPE_INTERRUPT,\ + .ep_notify.wMaxPacketSize = LE16(UDI_CDC_COMM_EP_SIZE),\ + .ep_notify.bInterval = 0x10,\ + .ep_notify.bEndpointAddress = UDI_CDC_COMM_EP_##port,\ + .iface.bInterfaceNumber = UDI_CDC_COMM_IFACE_NUMBER_##port,\ + .call_mgmt.bDataInterface = UDI_CDC_DATA_IFACE_NUMBER_##port,\ + .union_desc.bMasterInterface = UDI_CDC_COMM_IFACE_NUMBER_##port,\ + .union_desc.bSlaveInterface0 = UDI_CDC_DATA_IFACE_NUMBER_##port,\ + .iface.iInterface = UDI_CDC_COMM_STRING_ID_##port,\ + } + +//! Content of CDC DATA interface descriptors +#define UDI_CDC_DATA_DESC_COMMON \ + .iface.bLength = sizeof(usb_iface_desc_t),\ + .iface.bDescriptorType = USB_DT_INTERFACE,\ + .iface.bAlternateSetting = 0,\ + .iface.bNumEndpoints = 2,\ + .iface.bInterfaceClass = CDC_CLASS_DATA,\ + .iface.bInterfaceSubClass = 0,\ + .iface.bInterfaceProtocol = 0,\ + .ep_in.bLength = sizeof(usb_ep_desc_t),\ + .ep_in.bDescriptorType = USB_DT_ENDPOINT,\ + .ep_in.bmAttributes = USB_EP_TYPE_BULK,\ + .ep_in.bInterval = 0,\ + .ep_out.bLength = sizeof(usb_ep_desc_t),\ + .ep_out.bDescriptorType = USB_DT_ENDPOINT,\ + .ep_out.bmAttributes = USB_EP_TYPE_BULK,\ + .ep_out.bInterval = 0, + +#define UDI_CDC_DATA_DESC_FS(port) { \ + UDI_CDC_DATA_DESC_COMMON \ + .ep_in.wMaxPacketSize = LE16(UDI_CDC_DATA_EPS_FS_SIZE),\ + .ep_out.wMaxPacketSize = LE16(UDI_CDC_DATA_EPS_FS_SIZE),\ + .ep_in.bEndpointAddress = UDI_CDC_DATA_EP_IN_##port,\ + .ep_out.bEndpointAddress = UDI_CDC_DATA_EP_OUT_##port,\ + .iface.bInterfaceNumber = UDI_CDC_DATA_IFACE_NUMBER_##port,\ + .iface.iInterface = UDI_CDC_DATA_STRING_ID_##port,\ + } + +#define UDI_CDC_DATA_DESC_HS(port) { \ + UDI_CDC_DATA_DESC_COMMON \ + .ep_in.wMaxPacketSize = LE16(UDI_CDC_DATA_EPS_HS_SIZE),\ + .ep_out.wMaxPacketSize = LE16(UDI_CDC_DATA_EPS_HS_SIZE),\ + .ep_in.bEndpointAddress = UDI_CDC_DATA_EP_IN_##port,\ + .ep_out.bEndpointAddress = UDI_CDC_DATA_EP_OUT_##port,\ + .iface.bInterfaceNumber = UDI_CDC_DATA_IFACE_NUMBER_##port,\ + .iface.iInterface = UDI_CDC_DATA_STRING_ID_##port,\ + } + +//@} + +/** + * \ingroup udi_group + * \defgroup udi_cdc_group USB Device Interface (UDI) for Communication Class Device (CDC) + * + * Common APIs used by high level application to use this USB class. + * + * These routines are used to transfer and control data + * to/from USB CDC endpoint. + * + * See \ref udi_cdc_quickstart. + * @{ + */ + +/** + * \name Interface for application with single CDC interface support + */ +//@{ + +/** + * \brief Notify a state change of DCD signal + * + * \param b_set DCD is enabled if true, else disabled + */ +void udi_cdc_ctrl_signal_dcd(bool b_set); + +/** + * \brief Notify a state change of DSR signal + * + * \param b_set DSR is enabled if true, else disabled + */ +void udi_cdc_ctrl_signal_dsr(bool b_set); + +/** + * \brief Notify a framing error + */ +void udi_cdc_signal_framing_error(void); + +/** + * \brief Notify a parity error + */ +void udi_cdc_signal_parity_error(void); + +/** + * \brief Notify a overrun + */ +void udi_cdc_signal_overrun(void); + +/** + * \brief Gets the number of byte received + * + * \return the number of data available + */ +iram_size_t udi_cdc_get_nb_received_data(void); + +/** + * \brief This function checks if a character has been received on the CDC line + * + * \return \c 1 if a byte is ready to be read. + */ +bool udi_cdc_is_rx_ready(void); + +/** + * \brief Waits and gets a value on CDC line + * + * \return value read on CDC line + */ +int udi_cdc_getc(void); + +/** + * \brief Reads a RAM buffer on CDC line + * + * \param buf Values read + * \param size Number of value read + * + * \return the number of data remaining + */ +iram_size_t udi_cdc_read_buf(void* buf, iram_size_t size); + +/** + * \brief Gets the number of free byte in TX buffer + * + * \return the number of free byte in TX buffer + */ +iram_size_t udi_cdc_get_free_tx_buffer(void); + +/** + * \brief This function checks if a new character sent is possible + * The type int is used to support scanf redirection from compiler LIB. + * + * \return \c 1 if a new character can be sent + */ +bool udi_cdc_is_tx_ready(void); + +/** + * \brief Puts a byte on CDC line + * The type int is used to support printf redirection from compiler LIB. + * + * \param value Value to put + * + * \return \c 1 if function was successfully done, otherwise \c 0. + */ +int udi_cdc_putc(int value); + +/** + * \brief Writes a RAM buffer on CDC line + * + * \param buf Values to write + * \param size Number of value to write + * + * \return the number of data remaining + */ +iram_size_t udi_cdc_write_buf(const void* buf, iram_size_t size); +//@} + +/** + * \name Interface for application with multi CDC interfaces support + */ +//@{ + +/** + * \brief Notify a state change of DCD signal + * + * \param port Communication port number to manage + * \param b_set DCD is enabled if true, else disabled + */ +void udi_cdc_multi_ctrl_signal_dcd(uint8_t port, bool b_set); + +/** + * \brief Notify a state change of DSR signal + * + * \param port Communication port number to manage + * \param b_set DSR is enabled if true, else disabled + */ +void udi_cdc_multi_ctrl_signal_dsr(uint8_t port, bool b_set); + +/** + * \brief Notify a framing error + * + * \param port Communication port number to manage + */ +void udi_cdc_multi_signal_framing_error(uint8_t port); + +/** + * \brief Notify a parity error + * + * \param port Communication port number to manage + */ +void udi_cdc_multi_signal_parity_error(uint8_t port); + +/** + * \brief Notify a overrun + * + * \param port Communication port number to manage + */ +void udi_cdc_multi_signal_overrun(uint8_t port); + +/** + * \brief Gets the number of byte received + * + * \param port Communication port number to manage + * + * \return the number of data available + */ +iram_size_t udi_cdc_multi_get_nb_received_data(uint8_t port); + +/** + * \brief This function checks if a character has been received on the CDC line + * + * \param port Communication port number to manage + * + * \return \c 1 if a byte is ready to be read. + */ +bool udi_cdc_multi_is_rx_ready(uint8_t port); + +/** + * \brief Waits and gets a value on CDC line + * + * \param port Communication port number to manage + * + * \return value read on CDC line + */ +int udi_cdc_multi_getc(uint8_t port); + +/** + * \brief Reads a RAM buffer on CDC line + * + * \param port Communication port number to manage + * \param buf Values read + * \param size Number of values read + * + * \return the number of data remaining + */ +iram_size_t udi_cdc_multi_read_buf(uint8_t port, void* buf, iram_size_t size); + +/** + * \brief Gets the number of free byte in TX buffer + * + * \param port Communication port number to manage + * + * \return the number of free byte in TX buffer + */ +iram_size_t udi_cdc_multi_get_free_tx_buffer(uint8_t port); + +/** + * \brief This function checks if a new character sent is possible + * The type int is used to support scanf redirection from compiler LIB. + * + * \param port Communication port number to manage + * + * \return \c 1 if a new character can be sent + */ +bool udi_cdc_multi_is_tx_ready(uint8_t port); + +/** + * \brief Puts a byte on CDC line + * The type int is used to support printf redirection from compiler LIB. + * + * \param port Communication port number to manage + * \param value Value to put + * + * \return \c 1 if function was successfully done, otherwise \c 0. + */ +int udi_cdc_multi_putc(uint8_t port, int value); + +/** + * \brief Writes a RAM buffer on CDC line + * + * \param port Communication port number to manage + * \param buf Values to write + * \param size Number of value to write + * + * \return the number of data remaining + */ +iram_size_t udi_cdc_multi_write_buf(uint8_t port, const void* buf, iram_size_t size); +//@} + +//@} + +/** + * \page udi_cdc_quickstart Quick start guide for USB device Communication Class Device module (UDI CDC) + * + * This is the quick start guide for the \ref udi_cdc_group + * "USB device interface CDC module (UDI CDC)" with step-by-step instructions on + * how to configure and use the modules in a selection of use cases. + * + * The use cases contain several code fragments. The code fragments in the + * steps for setup can be copied into a custom initialization function, while + * the steps for usage can be copied into, e.g., the main application function. + * + * \section udi_cdc_basic_use_case Basic use case + * In this basic use case, the "USB CDC (Single Interface Device)" module is used + * with only one communication port. + * The "USB CDC (Composite Device)" module usage is described in \ref udi_cdc_use_cases + * "Advanced use cases". + * + * \section udi_cdc_basic_use_case_setup Setup steps + * \subsection udi_cdc_basic_use_case_setup_prereq Prerequisites + * \copydetails udc_basic_use_case_setup_prereq + * \subsection udi_cdc_basic_use_case_setup_code Example code + * \copydetails udc_basic_use_case_setup_code + * \subsection udi_cdc_basic_use_case_setup_flow Workflow + * \copydetails udc_basic_use_case_setup_flow + * + * \section udi_cdc_basic_use_case_usage Usage steps + * + * \subsection udi_cdc_basic_use_case_usage_code Example code + * Content of conf_usb.h: + * \code + #define UDI_CDC_ENABLE_EXT(port) my_callback_cdc_enable() + extern bool my_callback_cdc_enable(void); + #define UDI_CDC_DISABLE_EXT(port) my_callback_cdc_disable() + extern void my_callback_cdc_disable(void); + #define UDI_CDC_LOW_RATE + + #define UDI_CDC_DEFAULT_RATE 115200 + #define UDI_CDC_DEFAULT_STOPBITS CDC_STOP_BITS_1 + #define UDI_CDC_DEFAULT_PARITY CDC_PAR_NONE + #define UDI_CDC_DEFAULT_DATABITS 8 + + #include "udi_cdc_conf.h" // At the end of conf_usb.h file +\endcode + * + * Add to application C-file: + * \code + static bool my_flag_autorize_cdc_transfert = false; + bool my_callback_cdc_enable(void) + { + my_flag_autorize_cdc_transfert = true; + return true; + } + void my_callback_cdc_disable(void) + { + my_flag_autorize_cdc_transfert = false; + } + + void task(void) + { + if (my_flag_autorize_cdc_transfert) { + udi_cdc_putc('A'); + udi_cdc_getc(); + } + } +\endcode + * + * \subsection udi_cdc_basic_use_case_setup_flow Workflow + * -# Ensure that conf_usb.h is available and contains the following configuration + * which is the USB device CDC configuration: + * - \code #define USB_DEVICE_SERIAL_NAME "12...EF" // Disk SN for CDC \endcode + * \note The USB serial number is mandatory when a CDC interface is used. + * - \code #define UDI_CDC_ENABLE_EXT(port) my_callback_cdc_enable() + extern bool my_callback_cdc_enable(void); \endcode + * \note After the device enumeration (detecting and identifying USB devices), + * the USB host starts the device configuration. When the USB CDC interface + * from the device is accepted by the host, the USB host enables this interface and the + * UDI_CDC_ENABLE_EXT() callback function is called and return true. + * Thus, when this event is received, the data transfer on CDC interface are authorized. + * - \code #define UDI_CDC_DISABLE_EXT(port) my_callback_cdc_disable() + extern void my_callback_cdc_disable(void); \endcode + * \note When the USB device is unplugged or is reset by the USB host, the USB + * interface is disabled and the UDI_CDC_DISABLE_EXT() callback function + * is called. Thus, the data transfer must be stopped on CDC interface. + * - \code #define UDI_CDC_LOW_RATE \endcode + * \note Define it when the transfer CDC Device to Host is a low rate + * (<512000 bauds) to reduce CDC buffers size. + * - \code #define UDI_CDC_DEFAULT_RATE 115200 + #define UDI_CDC_DEFAULT_STOPBITS CDC_STOP_BITS_1 + #define UDI_CDC_DEFAULT_PARITY CDC_PAR_NONE + #define UDI_CDC_DEFAULT_DATABITS 8 \endcode + * \note Default configuration of communication port at startup. + * -# Send or wait data on CDC line: + * - \code // Waits and gets a value on CDC line + int udi_cdc_getc(void); + // Reads a RAM buffer on CDC line + iram_size_t udi_cdc_read_buf(int* buf, iram_size_t size); + // Puts a byte on CDC line + int udi_cdc_putc(int value); + // Writes a RAM buffer on CDC line + iram_size_t udi_cdc_write_buf(const int* buf, iram_size_t size); \endcode + * + * \section udi_cdc_use_cases Advanced use cases + * For more advanced use of the UDI CDC module, see the following use cases: + * - \subpage udi_cdc_use_case_composite + * - \subpage udc_use_case_1 + * - \subpage udc_use_case_2 + * - \subpage udc_use_case_3 + * - \subpage udc_use_case_4 + * - \subpage udc_use_case_5 + * - \subpage udc_use_case_6 + */ + +/** + * \page udi_cdc_use_case_composite CDC in a composite device + * + * A USB Composite Device is a USB Device which uses more than one USB class. + * In this use case, the "USB CDC (Composite Device)" module is used to + * create a USB composite device. Thus, this USB module can be associated with + * another "Composite Device" module, like "USB HID Mouse (Composite Device)". + * + * Also, you can refer to application note + * + * AVR4902 ASF - USB Composite Device. + * + * \section udi_cdc_use_case_composite_setup Setup steps + * For the setup code of this use case to work, the + * \ref udi_cdc_basic_use_case "basic use case" must be followed. + * + * \section udi_cdc_use_case_composite_usage Usage steps + * + * \subsection udi_cdc_use_case_composite_usage_code Example code + * Content of conf_usb.h: + * \code + #define USB_DEVICE_EP_CTRL_SIZE 64 + #define USB_DEVICE_NB_INTERFACE (X+2) + #define USB_DEVICE_MAX_EP (X+3) + + #define UDI_CDC_DATA_EP_IN_0 (1 | USB_EP_DIR_IN) // TX + #define UDI_CDC_DATA_EP_OUT_0 (2 | USB_EP_DIR_OUT) // RX + #define UDI_CDC_COMM_EP_0 (3 | USB_EP_DIR_IN) // Notify endpoint + #define UDI_CDC_COMM_IFACE_NUMBER_0 X+0 + #define UDI_CDC_DATA_IFACE_NUMBER_0 X+1 + + #define UDI_COMPOSITE_DESC_T \ + usb_iad_desc_t udi_cdc_iad; \ + udi_cdc_comm_desc_t udi_cdc_comm; \ + udi_cdc_data_desc_t udi_cdc_data; \ + ... + #define UDI_COMPOSITE_DESC_FS \ + .udi_cdc_iad = UDI_CDC_IAD_DESC_0, \ + .udi_cdc_comm = UDI_CDC_COMM_DESC_0, \ + .udi_cdc_data = UDI_CDC_DATA_DESC_0_FS, \ + ... + #define UDI_COMPOSITE_DESC_HS \ + .udi_cdc_iad = UDI_CDC_IAD_DESC_0, \ + .udi_cdc_comm = UDI_CDC_COMM_DESC_0, \ + .udi_cdc_data = UDI_CDC_DATA_DESC_0_HS, \ + ... + #define UDI_COMPOSITE_API \ + &udi_api_cdc_comm, \ + &udi_api_cdc_data, \ + ... +\endcode + * + * \subsection udi_cdc_use_case_composite_usage_flow Workflow + * -# Ensure that conf_usb.h is available and contains the following parameters + * required for a USB composite device configuration: + * - \code // Endpoint control size, This must be: + // - 8, 16, 32 or 64 for full speed device (8 is recommended to save RAM) + // - 64 for a high speed device + #define USB_DEVICE_EP_CTRL_SIZE 64 + // Total Number of interfaces on this USB device. + // Add 2 for CDC. + #define USB_DEVICE_NB_INTERFACE (X+2) + // Total number of endpoints on this USB device. + // This must include each endpoint for each interface. + // Add 3 for CDC. + #define USB_DEVICE_MAX_EP (X+3) \endcode + * -# Ensure that conf_usb.h contains the description of + * composite device: + * - \code // The endpoint numbers chosen by you for the CDC. + // The endpoint numbers starting from 1. + #define UDI_CDC_DATA_EP_IN_0 (1 | USB_EP_DIR_IN) // TX + #define UDI_CDC_DATA_EP_OUT_0 (2 | USB_EP_DIR_OUT) // RX + #define UDI_CDC_COMM_EP_0 (3 | USB_EP_DIR_IN) // Notify endpoint + // The interface index of an interface starting from 0 + #define UDI_CDC_COMM_IFACE_NUMBER_0 X+0 + #define UDI_CDC_DATA_IFACE_NUMBER_0 X+1 \endcode + * -# Ensure that conf_usb.h contains the following parameters + * required for a USB composite device configuration: + * - \code // USB Interfaces descriptor structure + #define UDI_COMPOSITE_DESC_T \ + ... + usb_iad_desc_t udi_cdc_iad; \ + udi_cdc_comm_desc_t udi_cdc_comm; \ + udi_cdc_data_desc_t udi_cdc_data; \ + ... + // USB Interfaces descriptor value for Full Speed + #define UDI_COMPOSITE_DESC_FS \ + ... + .udi_cdc_iad = UDI_CDC_IAD_DESC_0, \ + .udi_cdc_comm = UDI_CDC_COMM_DESC_0, \ + .udi_cdc_data = UDI_CDC_DATA_DESC_0_FS, \ + ... + // USB Interfaces descriptor value for High Speed + #define UDI_COMPOSITE_DESC_HS \ + ... + .udi_cdc_iad = UDI_CDC_IAD_DESC_0, \ + .udi_cdc_comm = UDI_CDC_COMM_DESC_0, \ + .udi_cdc_data = UDI_CDC_DATA_DESC_0_HS, \ + ... + // USB Interface APIs + #define UDI_COMPOSITE_API \ + ... + &udi_api_cdc_comm, \ + &udi_api_cdc_data, \ + ... \endcode + * - \note The descriptors order given in the four lists above must be the + * same as the order defined by all interface indexes. The interface index + * orders are defined through UDI_X_IFACE_NUMBER defines.\n + * Also, the CDC requires a USB Interface Association Descriptor (IAD) for + * composite device. + */ + +#ifdef __cplusplus +} +#endif +#endif // _UDI_CDC_H_ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/class/cdc/device/udi_cdc_conf.h b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/class/cdc/device/udi_cdc_conf.h new file mode 100644 index 0000000..1123522 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/class/cdc/device/udi_cdc_conf.h @@ -0,0 +1,152 @@ +/** + * \file + * + * \brief Default CDC configuration for a USB Device with a single interface + * + * Copyright (c) 2009 - 2013 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _UDI_CDC_CONF_H_ +#define _UDI_CDC_CONF_H_ + +#include "usb_protocol_cdc.h" +#include "conf_usb.h" + +#ifndef UDI_CDC_PORT_NB +# define UDI_CDC_PORT_NB 1 +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \addtogroup udi_cdc_group_single_desc + * @{ + */ + +//! Control endpoint size (Endpoint 0) +#define USB_DEVICE_EP_CTRL_SIZE 64 + +#if XMEGA +/** + * \name Endpoint configuration on XMEGA + * The XMEGA supports a IN and OUT endpoint with the same number endpoint, + * thus XMEGA can support up to 7 CDC interfaces. + */ +//@{ +#define UDI_CDC_DATA_EP_IN_0 ( 1 | USB_EP_DIR_IN) // TX +#define UDI_CDC_DATA_EP_OUT_0 ( 2 | USB_EP_DIR_OUT) // RX +#define UDI_CDC_COMM_EP_0 ( 2 | USB_EP_DIR_IN) // Notify endpoint +#define UDI_CDC_DATA_EP_IN_1 ( 3 | USB_EP_DIR_IN) // TX +#define UDI_CDC_DATA_EP_OUT_1 ( 4 | USB_EP_DIR_OUT) // RX +#define UDI_CDC_COMM_EP_1 ( 4 | USB_EP_DIR_IN) // Notify endpoint +#define UDI_CDC_DATA_EP_IN_2 ( 5 | USB_EP_DIR_IN) // TX +#define UDI_CDC_DATA_EP_OUT_2 ( 6 | USB_EP_DIR_OUT) // RX +#define UDI_CDC_COMM_EP_2 ( 6 | USB_EP_DIR_IN) // Notify endpoint +#define UDI_CDC_DATA_EP_IN_3 ( 7 | USB_EP_DIR_IN) // TX +#define UDI_CDC_DATA_EP_OUT_3 ( 8 | USB_EP_DIR_OUT) // RX +#define UDI_CDC_COMM_EP_3 ( 8 | USB_EP_DIR_IN) // Notify endpoint +#define UDI_CDC_DATA_EP_IN_4 ( 9 | USB_EP_DIR_IN) // TX +#define UDI_CDC_DATA_EP_OUT_4 (10 | USB_EP_DIR_OUT) // RX +#define UDI_CDC_COMM_EP_4 (10 | USB_EP_DIR_IN) // Notify endpoint +#define UDI_CDC_DATA_EP_IN_5 (11 | USB_EP_DIR_IN) // TX +#define UDI_CDC_DATA_EP_OUT_5 (12 | USB_EP_DIR_OUT) // RX +#define UDI_CDC_COMM_EP_5 (12 | USB_EP_DIR_IN) // Notify endpoint +#define UDI_CDC_DATA_EP_IN_6 (13 | USB_EP_DIR_IN) // TX +#define UDI_CDC_DATA_EP_OUT_6 (14 | USB_EP_DIR_OUT) // RX +#define UDI_CDC_COMM_EP_6 (14 | USB_EP_DIR_IN) // Notify endpoint +//! 2 endpoints numbers used per CDC interface +#define USB_DEVICE_MAX_EP (2*UDI_CDC_PORT_NB) +//@} + +#else + +/** + * \name Default endpoint configuration + * The USBB, UDP, UDPHS and UOTGHS interfaces can support up to 2 CDC interfaces. + */ +//@{ +# if UDI_CDC_PORT_NB > 2 +# error USBB, UDP, UDPHS and UOTGHS interfaces have not enought endpoints. +# endif +#define UDI_CDC_DATA_EP_IN_0 (1 | USB_EP_DIR_IN) // TX +#define UDI_CDC_DATA_EP_OUT_0 (2 | USB_EP_DIR_OUT) // RX +#define UDI_CDC_COMM_EP_0 (3 | USB_EP_DIR_IN) // Notify endpoint +# if SAM3U + /* For 3U max endpoint size of 4 is 64, use 5 and 6 as bulk tx and rx */ +# define UDI_CDC_DATA_EP_IN_1 (6 | USB_EP_DIR_IN) // TX +# define UDI_CDC_DATA_EP_OUT_1 (5 | USB_EP_DIR_OUT) // RX +# define UDI_CDC_COMM_EP_1 (4 | USB_EP_DIR_IN) // Notify +# else +# define UDI_CDC_DATA_EP_IN_1 (4 | USB_EP_DIR_IN) // TX +# define UDI_CDC_DATA_EP_OUT_1 (5 | USB_EP_DIR_OUT) // RX +# define UDI_CDC_COMM_EP_1 (6 | USB_EP_DIR_IN) // Notify +# endif +//! 3 endpoints used per CDC interface +#define USB_DEVICE_MAX_EP (3*UDI_CDC_PORT_NB) +//@} + +#endif + +/** + * \name Default Interface numbers + */ +//@{ +#define UDI_CDC_COMM_IFACE_NUMBER_0 0 +#define UDI_CDC_DATA_IFACE_NUMBER_0 1 +#define UDI_CDC_COMM_IFACE_NUMBER_1 2 +#define UDI_CDC_DATA_IFACE_NUMBER_1 3 +#define UDI_CDC_COMM_IFACE_NUMBER_2 4 +#define UDI_CDC_DATA_IFACE_NUMBER_2 5 +#define UDI_CDC_COMM_IFACE_NUMBER_3 6 +#define UDI_CDC_DATA_IFACE_NUMBER_3 7 +#define UDI_CDC_COMM_IFACE_NUMBER_4 8 +#define UDI_CDC_DATA_IFACE_NUMBER_4 9 +#define UDI_CDC_COMM_IFACE_NUMBER_5 10 +#define UDI_CDC_DATA_IFACE_NUMBER_5 11 +#define UDI_CDC_COMM_IFACE_NUMBER_6 12 +#define UDI_CDC_DATA_IFACE_NUMBER_6 13 +//@} + +//@} + +#ifdef __cplusplus +} +#endif +#endif // _UDI_CDC_CONF_H_ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/class/cdc/device/udi_cdc_desc.c b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/class/cdc/device/udi_cdc_desc.c new file mode 100644 index 0000000..1f11f38 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/class/cdc/device/udi_cdc_desc.c @@ -0,0 +1,251 @@ +/** + * \file + * + * \brief Default descriptors for a USB Device with a single interface CDC + * + * Copyright (c) 2009-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include "conf_usb.h" +#include "udd.h" +#include "udc_desc.h" +#include "udi_cdc.h" + + +/** + * \defgroup udi_cdc_group_single_desc USB device descriptors for a single interface + * + * The following structures provide the USB device descriptors required for + * USB Device with a single interface CDC. + * + * It is ready to use and do not require more definition. + * + * @{ + */ + +//! Two interfaces for a CDC device +#define USB_DEVICE_NB_INTERFACE (2*UDI_CDC_PORT_NB) + +#ifdef USB_DEVICE_LPM_SUPPORT +# define USB_VERSION USB_V2_1 +#else +# define USB_VERSION USB_V2_0 +#endif + +//! USB Device Descriptor +COMPILER_WORD_ALIGNED +UDC_DESC_STORAGE usb_dev_desc_t udc_device_desc = { + .bLength = sizeof(usb_dev_desc_t), + .bDescriptorType = USB_DT_DEVICE, + .bcdUSB = LE16(USB_VERSION), +#if UDI_CDC_PORT_NB > 1 + .bDeviceClass = 0, +#else + .bDeviceClass = CDC_CLASS_DEVICE, +#endif + .bDeviceSubClass = 0, + .bDeviceProtocol = 0, + .bMaxPacketSize0 = USB_DEVICE_EP_CTRL_SIZE, + .idVendor = LE16(USB_DEVICE_VENDOR_ID), + .idProduct = LE16(USB_DEVICE_PRODUCT_ID), + .bcdDevice = LE16((USB_DEVICE_MAJOR_VERSION << 8) + | USB_DEVICE_MINOR_VERSION), +#ifdef USB_DEVICE_MANUFACTURE_NAME + .iManufacturer = 1, +#else + .iManufacturer = 0, // No manufacture string +#endif +#ifdef USB_DEVICE_PRODUCT_NAME + .iProduct = 2, +#else + .iProduct = 0, // No product string +#endif +#ifdef USB_DEVICE_SERIAL_NAME + .iSerialNumber = 3, +#else + .iSerialNumber = 0, // No serial string +#endif + .bNumConfigurations = 1 +}; + + +#ifdef USB_DEVICE_HS_SUPPORT +//! USB Device Qualifier Descriptor for HS +COMPILER_WORD_ALIGNED +UDC_DESC_STORAGE usb_dev_qual_desc_t udc_device_qual = { + .bLength = sizeof(usb_dev_qual_desc_t), + .bDescriptorType = USB_DT_DEVICE_QUALIFIER, + .bcdUSB = LE16(USB_VERSION), +#if UDI_CDC_PORT_NB > 1 + .bDeviceClass = 0, +#else + .bDeviceClass = CDC_CLASS_DEVICE, +#endif + .bDeviceSubClass = 0, + .bDeviceProtocol = 0, + .bMaxPacketSize0 = USB_DEVICE_EP_CTRL_SIZE, + .bNumConfigurations = 1 +}; +#endif + +#ifdef USB_DEVICE_LPM_SUPPORT +//! USB Device Qualifier Descriptor +COMPILER_WORD_ALIGNED +UDC_DESC_STORAGE usb_dev_lpm_desc_t udc_device_lpm = { + .bos.bLength = sizeof(usb_dev_bos_desc_t), + .bos.bDescriptorType = USB_DT_BOS, + .bos.wTotalLength = LE16(sizeof(usb_dev_bos_desc_t) + sizeof(usb_dev_capa_ext_desc_t)), + .bos.bNumDeviceCaps = 1, + .capa_ext.bLength = sizeof(usb_dev_capa_ext_desc_t), + .capa_ext.bDescriptorType = USB_DT_DEVICE_CAPABILITY, + .capa_ext.bDevCapabilityType = USB_DC_USB20_EXTENSION, + .capa_ext.bmAttributes = USB_DC_EXT_LPM, // alfran: modified to fix ASF USB 3.0 incompatibility +}; +#endif + +//! Structure for USB Device Configuration Descriptor +COMPILER_PACK_SET(1) +typedef struct { + usb_conf_desc_t conf; +#if UDI_CDC_PORT_NB == 1 + udi_cdc_comm_desc_t udi_cdc_comm_0; + udi_cdc_data_desc_t udi_cdc_data_0; +#else +# define UDI_CDC_DESC_STRUCTURE(index, unused) \ + usb_iad_desc_t udi_cdc_iad_##index; \ + udi_cdc_comm_desc_t udi_cdc_comm_##index; \ + udi_cdc_data_desc_t udi_cdc_data_##index; + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_DESC_STRUCTURE, ~) +# undef UDI_CDC_DESC_STRUCTURE +#endif +} udc_desc_t; +COMPILER_PACK_RESET() + +//! USB Device Configuration Descriptor filled for full and high speed +COMPILER_WORD_ALIGNED +UDC_DESC_STORAGE udc_desc_t udc_desc_fs = { + .conf.bLength = sizeof(usb_conf_desc_t), + .conf.bDescriptorType = USB_DT_CONFIGURATION, + .conf.wTotalLength = LE16(sizeof(udc_desc_t)), + .conf.bNumInterfaces = USB_DEVICE_NB_INTERFACE, + .conf.bConfigurationValue = 1, + .conf.iConfiguration = 0, + .conf.bmAttributes = USB_CONFIG_ATTR_MUST_SET | USB_DEVICE_ATTR, + .conf.bMaxPower = USB_CONFIG_MAX_POWER(USB_DEVICE_POWER), +#if UDI_CDC_PORT_NB == 1 + .udi_cdc_comm_0 = UDI_CDC_COMM_DESC_0, + .udi_cdc_data_0 = UDI_CDC_DATA_DESC_0_FS, +#else +# define UDI_CDC_DESC_FS(index, unused) \ + .udi_cdc_iad_##index = UDI_CDC_IAD_DESC_##index,\ + .udi_cdc_comm_##index = UDI_CDC_COMM_DESC_##index,\ + .udi_cdc_data_##index = UDI_CDC_DATA_DESC_##index##_FS, + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_DESC_FS, ~) +# undef UDI_CDC_DESC_FS +#endif +}; + +#ifdef USB_DEVICE_HS_SUPPORT +COMPILER_WORD_ALIGNED +UDC_DESC_STORAGE udc_desc_t udc_desc_hs = { + .conf.bLength = sizeof(usb_conf_desc_t), + .conf.bDescriptorType = USB_DT_CONFIGURATION, + .conf.wTotalLength = LE16(sizeof(udc_desc_t)), + .conf.bNumInterfaces = USB_DEVICE_NB_INTERFACE, + .conf.bConfigurationValue = 1, + .conf.iConfiguration = 0, + .conf.bmAttributes = USB_CONFIG_ATTR_MUST_SET | USB_DEVICE_ATTR, + .conf.bMaxPower = USB_CONFIG_MAX_POWER(USB_DEVICE_POWER), +#if UDI_CDC_PORT_NB == 1 + .udi_cdc_comm_0 = UDI_CDC_COMM_DESC_0, + .udi_cdc_data_0 = UDI_CDC_DATA_DESC_0_HS, +#else +# define UDI_CDC_DESC_HS(index, unused) \ + .udi_cdc_iad_##index = UDI_CDC_IAD_DESC_##index, \ + .udi_cdc_comm_##index = UDI_CDC_COMM_DESC_##index, \ + .udi_cdc_data_##index = UDI_CDC_DATA_DESC_##index##_HS, + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_DESC_HS, ~) +# undef UDI_CDC_DESC_HS +#endif +}; +#endif + +/** + * \name UDC structures which content all USB Device definitions + */ +//@{ + +//! Associate an UDI for each USB interface +UDC_DESC_STORAGE udi_api_t *udi_apis[USB_DEVICE_NB_INTERFACE] = { +# define UDI_CDC_API(index, unused) \ + &udi_api_cdc_comm, \ + &udi_api_cdc_data, + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_API, ~) +# undef UDI_CDC_API +}; + +//! Add UDI with USB Descriptors FS & HS +UDC_DESC_STORAGE udc_config_speed_t udc_config_fs[1] = { { + .desc = (usb_conf_desc_t UDC_DESC_STORAGE*)&udc_desc_fs, + .udi_apis = udi_apis, +}}; +#ifdef USB_DEVICE_HS_SUPPORT +UDC_DESC_STORAGE udc_config_speed_t udc_config_hs[1] = { { + .desc = (usb_conf_desc_t UDC_DESC_STORAGE*)&udc_desc_hs, + .udi_apis = udi_apis, +}}; +#endif + +//! Add all information about USB Device in global structure for UDC +UDC_DESC_STORAGE udc_config_t udc_config = { + .confdev_lsfs = &udc_device_desc, + .conf_lsfs = udc_config_fs, +#ifdef USB_DEVICE_HS_SUPPORT + .confdev_hs = &udc_device_desc, + .qualifier = &udc_device_qual, + .conf_hs = udc_config_hs, +#endif +#ifdef USB_DEVICE_LPM_SUPPORT + .conf_bos = &udc_device_lpm.bos, +#else + .conf_bos = NULL, +#endif +}; + +//@} +//@} diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/class/cdc/usb_protocol_cdc.h b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/class/cdc/usb_protocol_cdc.h new file mode 100644 index 0000000..97250e1 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/class/cdc/usb_protocol_cdc.h @@ -0,0 +1,315 @@ +/** + * \file + * + * \brief USB Communication Device Class (CDC) protocol definitions + * + * Copyright (c) 2009-2012 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef _USB_PROTOCOL_CDC_H_ +#define _USB_PROTOCOL_CDC_H_ + +#include "compiler.h" + +/** + * \ingroup usb_protocol_group + * \defgroup cdc_protocol_group Communication Device Class Definitions + * @{ + */ + +/** + * \name Possible values of class + */ +//@{ +#define CDC_CLASS_DEVICE 0x02 //!< USB Communication Device Class +#define CDC_CLASS_COMM 0x02 //!< CDC Communication Class Interface +#define CDC_CLASS_DATA 0x0A //!< CDC Data Class Interface +//@} + +//! \name USB CDC Subclass IDs +//@{ +#define CDC_SUBCLASS_DLCM 0x01 //!< Direct Line Control Model +#define CDC_SUBCLASS_ACM 0x02 //!< Abstract Control Model +#define CDC_SUBCLASS_TCM 0x03 //!< Telephone Control Model +#define CDC_SUBCLASS_MCCM 0x04 //!< Multi-Channel Control Model +#define CDC_SUBCLASS_CCM 0x05 //!< CAPI Control Model +#define CDC_SUBCLASS_ETH 0x06 //!< Ethernet Networking Control Model +#define CDC_SUBCLASS_ATM 0x07 //!< ATM Networking Control Model +//@} + +//! \name USB CDC Communication Interface Protocol IDs +//@{ +#define CDC_PROTOCOL_V25TER 0x01 //!< Common AT commands +//@} + +//! \name USB CDC Data Interface Protocol IDs +//@{ +#define CDC_PROTOCOL_I430 0x30 //!< ISDN BRI +#define CDC_PROTOCOL_HDLC 0x31 //!< HDLC +#define CDC_PROTOCOL_TRANS 0x32 //!< Transparent +#define CDC_PROTOCOL_Q921M 0x50 //!< Q.921 management protocol +#define CDC_PROTOCOL_Q921 0x51 //!< Q.931 [sic] Data link protocol +#define CDC_PROTOCOL_Q921TM 0x52 //!< Q.921 TEI-multiplexor +#define CDC_PROTOCOL_V42BIS 0x90 //!< Data compression procedures +#define CDC_PROTOCOL_Q931 0x91 //!< Euro-ISDN protocol control +#define CDC_PROTOCOL_V120 0x92 //!< V.24 rate adaption to ISDN +#define CDC_PROTOCOL_CAPI20 0x93 //!< CAPI Commands +#define CDC_PROTOCOL_HOST 0xFD //!< Host based driver +/** + * \brief Describes the Protocol Unit Functional Descriptors [sic] + * on Communication Class Interface + */ +#define CDC_PROTOCOL_PUFD 0xFE +//@} + +//! \name USB CDC Functional Descriptor Types +//@{ +#define CDC_CS_INTERFACE 0x24 //!< Interface Functional Descriptor +#define CDC_CS_ENDPOINT 0x25 //!< Endpoint Functional Descriptor +//@} + +//! \name USB CDC Functional Descriptor Subtypes +//@{ +#define CDC_SCS_HEADER 0x00 //!< Header Functional Descriptor +#define CDC_SCS_CALL_MGMT 0x01 //!< Call Management +#define CDC_SCS_ACM 0x02 //!< Abstract Control Management +#define CDC_SCS_UNION 0x06 //!< Union Functional Descriptor +//@} + +//! \name USB CDC Request IDs +//@{ +#define USB_REQ_CDC_SEND_ENCAPSULATED_COMMAND 0x00 +#define USB_REQ_CDC_GET_ENCAPSULATED_RESPONSE 0x01 +#define USB_REQ_CDC_SET_COMM_FEATURE 0x02 +#define USB_REQ_CDC_GET_COMM_FEATURE 0x03 +#define USB_REQ_CDC_CLEAR_COMM_FEATURE 0x04 +#define USB_REQ_CDC_SET_AUX_LINE_STATE 0x10 +#define USB_REQ_CDC_SET_HOOK_STATE 0x11 +#define USB_REQ_CDC_PULSE_SETUP 0x12 +#define USB_REQ_CDC_SEND_PULSE 0x13 +#define USB_REQ_CDC_SET_PULSE_TIME 0x14 +#define USB_REQ_CDC_RING_AUX_JACK 0x15 +#define USB_REQ_CDC_SET_LINE_CODING 0x20 +#define USB_REQ_CDC_GET_LINE_CODING 0x21 +#define USB_REQ_CDC_SET_CONTROL_LINE_STATE 0x22 +#define USB_REQ_CDC_SEND_BREAK 0x23 +#define USB_REQ_CDC_SET_RINGER_PARMS 0x30 +#define USB_REQ_CDC_GET_RINGER_PARMS 0x31 +#define USB_REQ_CDC_SET_OPERATION_PARMS 0x32 +#define USB_REQ_CDC_GET_OPERATION_PARMS 0x33 +#define USB_REQ_CDC_SET_LINE_PARMS 0x34 +#define USB_REQ_CDC_GET_LINE_PARMS 0x35 +#define USB_REQ_CDC_DIAL_DIGITS 0x36 +#define USB_REQ_CDC_SET_UNIT_PARAMETER 0x37 +#define USB_REQ_CDC_GET_UNIT_PARAMETER 0x38 +#define USB_REQ_CDC_CLEAR_UNIT_PARAMETER 0x39 +#define USB_REQ_CDC_GET_PROFILE 0x3A +#define USB_REQ_CDC_SET_ETHERNET_MULTICAST_FILTERS 0x40 +#define USB_REQ_CDC_SET_ETHERNET_POWER_MANAGEMENT_PATTERNFILTER 0x41 +#define USB_REQ_CDC_GET_ETHERNET_POWER_MANAGEMENT_PATTERNFILTER 0x42 +#define USB_REQ_CDC_SET_ETHERNET_PACKET_FILTER 0x43 +#define USB_REQ_CDC_GET_ETHERNET_STATISTIC 0x44 +#define USB_REQ_CDC_SET_ATM_DATA_FORMAT 0x50 +#define USB_REQ_CDC_GET_ATM_DEVICE_STATISTICS 0x51 +#define USB_REQ_CDC_SET_ATM_DEFAULT_VC 0x52 +#define USB_REQ_CDC_GET_ATM_VC_STATISTICS 0x53 +// Added bNotification codes according cdc spec 1.1 chapter 6.3 +#define USB_REQ_CDC_NOTIFY_RING_DETECT 0x09 +#define USB_REQ_CDC_NOTIFY_SERIAL_STATE 0x20 +#define USB_REQ_CDC_NOTIFY_CALL_STATE_CHANGE 0x28 +#define USB_REQ_CDC_NOTIFY_LINE_STATE_CHANGE 0x29 +//@} + +/* + * Need to pack structures tightly, or the compiler might insert padding + * and violate the spec-mandated layout. + */ +COMPILER_PACK_SET(1) + +//! \name USB CDC Descriptors +//@{ + + +//! CDC Header Functional Descriptor +typedef struct { + uint8_t bFunctionLength; + uint8_t bDescriptorType; + uint8_t bDescriptorSubtype; + le16_t bcdCDC; +} usb_cdc_hdr_desc_t; + +//! CDC Call Management Functional Descriptor +typedef struct { + uint8_t bFunctionLength; + uint8_t bDescriptorType; + uint8_t bDescriptorSubtype; + uint8_t bmCapabilities; + uint8_t bDataInterface; +} usb_cdc_call_mgmt_desc_t; + +//! CDC ACM Functional Descriptor +typedef struct { + uint8_t bFunctionLength; + uint8_t bDescriptorType; + uint8_t bDescriptorSubtype; + uint8_t bmCapabilities; +} usb_cdc_acm_desc_t; + +//! CDC Union Functional Descriptor +typedef struct { + uint8_t bFunctionLength; + uint8_t bDescriptorType; + uint8_t bDescriptorSubtype; + uint8_t bMasterInterface; + uint8_t bSlaveInterface0; +} usb_cdc_union_desc_t; + + +//! \name USB CDC Call Management Capabilities +//@{ +//! Device handles call management itself +#define CDC_CALL_MGMT_SUPPORTED (1 << 0) +//! Device can send/receive call management info over a Data Class interface +#define CDC_CALL_MGMT_OVER_DCI (1 << 1) +//@} + +//! \name USB CDC ACM Capabilities +//@{ +//! Device supports the request combination of +//! Set_Comm_Feature, Clear_Comm_Feature, and Get_Comm_Feature. +#define CDC_ACM_SUPPORT_FEATURE_REQUESTS (1 << 0) +//! Device supports the request combination of +//! Set_Line_Coding, Set_Control_Line_State, Get_Line_Coding, +//! and the notification Serial_State. +#define CDC_ACM_SUPPORT_LINE_REQUESTS (1 << 1) +//! Device supports the request Send_Break +#define CDC_ACM_SUPPORT_SENDBREAK_REQUESTS (1 << 2) +//! Device supports the notification Network_Connection. +#define CDC_ACM_SUPPORT_NOTIFY_REQUESTS (1 << 3) +//@} +//@} + +//! \name USB CDC line control +//@{ + +//! \name USB CDC line coding +//@{ +//! Line Coding structure +typedef struct { + le32_t dwDTERate; + uint8_t bCharFormat; + uint8_t bParityType; + uint8_t bDataBits; +} usb_cdc_line_coding_t; +//! Possible values of bCharFormat +enum cdc_char_format { + CDC_STOP_BITS_1 = 0, //!< 1 stop bit + CDC_STOP_BITS_1_5 = 1, //!< 1.5 stop bits + CDC_STOP_BITS_2 = 2, //!< 2 stop bits +}; +//! Possible values of bParityType +enum cdc_parity { + CDC_PAR_NONE = 0, //!< No parity + CDC_PAR_ODD = 1, //!< Odd parity + CDC_PAR_EVEN = 2, //!< Even parity + CDC_PAR_MARK = 3, //!< Parity forced to 0 (space) + CDC_PAR_SPACE = 4, //!< Parity forced to 1 (mark) +}; +//@} + +//! \name USB CDC control signals +//! spec 1.1 chapter 6.2.14 +//@{ + +//! Control signal structure +typedef struct { + uint16_t value; +} usb_cdc_control_signal_t; + +//! \name Possible values in usb_cdc_control_signal_t +//@{ +//! Carrier control for half duplex modems. +//! This signal corresponds to V.24 signal 105 and RS-232 signal RTS. +//! The device ignores the value of this bit +//! when operating in full duplex mode. +#define CDC_CTRL_SIGNAL_ACTIVATE_CARRIER (1 << 1) +//! Indicates to DCE if DTE is present or not. +//! This signal corresponds to V.24 signal 108/2 and RS-232 signal DTR. +#define CDC_CTRL_SIGNAL_DTE_PRESENT (1 << 0) +//@} +//@} + + +//! \name USB CDC notification message +//@{ + +typedef struct { + uint8_t bmRequestType; + uint8_t bNotification; + le16_t wValue; + le16_t wIndex; + le16_t wLength; +} usb_cdc_notify_msg_t; + +//! \name USB CDC serial state +//@{* + +//! Hardware handshake support (cdc spec 1.1 chapter 6.3.5) +typedef struct { + usb_cdc_notify_msg_t header; + le16_t value; +} usb_cdc_notify_serial_state_t; + +//! \name Possible values in usb_cdc_notify_serial_state_t +//@{ +#define CDC_SERIAL_STATE_DCD CPU_TO_LE16((1<<0)) +#define CDC_SERIAL_STATE_DSR CPU_TO_LE16((1<<1)) +#define CDC_SERIAL_STATE_BREAK CPU_TO_LE16((1<<2)) +#define CDC_SERIAL_STATE_RING CPU_TO_LE16((1<<3)) +#define CDC_SERIAL_STATE_FRAMING CPU_TO_LE16((1<<4)) +#define CDC_SERIAL_STATE_PARITY CPU_TO_LE16((1<<5)) +#define CDC_SERIAL_STATE_OVERRUN CPU_TO_LE16((1<<6)) +//@} +//! @} + +//! @} + +COMPILER_PACK_RESET() + +//! @} + +#endif // _USB_PROTOCOL_CDC_H_ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/udc/udc.c b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/udc/udc.c new file mode 100644 index 0000000..8db57b1 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/udc/udc.c @@ -0,0 +1,1138 @@ +/** + * \file + * + * \brief USB Device Controller (UDC) + * + * Copyright (c) 2009 - 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include "conf_usb.h" +#include "usb_protocol.h" +#include "udd.h" +#include "udc_desc.h" +#include "udi.h" +#include "udc.h" + +/** + * \ingroup udc_group + * \defgroup udc_group_interne Implementation of UDC + * + * Internal implementation + * @{ + */ + +//! \name Internal variables to manage the USB device +//! @{ + +//! Device status state (see enum usb_device_status in usb_protocol.h) +static le16_t udc_device_status; + +//! Device Configuration number selected by the USB host +static uint8_t udc_num_configuration = 0; + +//! Pointer on the selected speed device configuration +static udc_config_speed_t UDC_DESC_STORAGE *udc_ptr_conf; + +//! Pointer on interface descriptor used by SETUP request. +static usb_iface_desc_t UDC_DESC_STORAGE *udc_ptr_iface; + +//! @} + + +//! \name Internal structure to store the USB device main strings +//! @{ + +/** + * \brief Language ID of USB device (US ID by default) + */ +COMPILER_WORD_ALIGNED +static UDC_DESC_STORAGE usb_str_lgid_desc_t udc_string_desc_languageid = { + .desc.bLength = sizeof(usb_str_lgid_desc_t), + .desc.bDescriptorType = USB_DT_STRING, + .string = {LE16(USB_LANGID_EN_US)} +}; + +/** + * \brief USB device manufacture name storage + * String is allocated only if USB_DEVICE_MANUFACTURE_NAME is declared + * by usb application configuration + */ +#ifdef USB_DEVICE_MANUFACTURE_NAME +static uint8_t udc_string_manufacturer_name[] = USB_DEVICE_MANUFACTURE_NAME; +# define USB_DEVICE_MANUFACTURE_NAME_SIZE \ + (sizeof(udc_string_manufacturer_name)-1) +#else +# define USB_DEVICE_MANUFACTURE_NAME_SIZE 0 +#endif + +/** + * \brief USB device product name storage + * String is allocated only if USB_DEVICE_PRODUCT_NAME is declared + * by usb application configuration + */ +#ifdef USB_DEVICE_PRODUCT_NAME +static uint8_t udc_string_product_name[] = USB_DEVICE_PRODUCT_NAME; +# define USB_DEVICE_PRODUCT_NAME_SIZE (sizeof(udc_string_product_name)-1) +#else +# define USB_DEVICE_PRODUCT_NAME_SIZE 0 +#endif + +/** + * \brief Get USB device serial number + * + * Use the define USB_DEVICE_SERIAL_NAME to set static serial number. + * + * For dynamic serial number set the define USB_DEVICE_GET_SERIAL_NAME_POINTER + * to a suitable pointer. This will also require the serial number length + * define USB_DEVICE_GET_SERIAL_NAME_LENGTH. + */ +#if defined USB_DEVICE_GET_SERIAL_NAME_POINTER + static const uint8_t *udc_get_string_serial_name(void) + { + return (const uint8_t *)USB_DEVICE_GET_SERIAL_NAME_POINTER; + } +# define USB_DEVICE_SERIAL_NAME_SIZE \ + USB_DEVICE_GET_SERIAL_NAME_LENGTH +#elif defined USB_DEVICE_SERIAL_NAME + static const uint8_t *udc_get_string_serial_name(void) + { + return (const uint8_t *)USB_DEVICE_SERIAL_NAME; + } +# define USB_DEVICE_SERIAL_NAME_SIZE \ + (sizeof(USB_DEVICE_SERIAL_NAME)-1) +#else +# define USB_DEVICE_SERIAL_NAME_SIZE 0 +#endif + +/** + * \brief USB device string descriptor + * Structure used to transfer ASCII strings to USB String descriptor structure. + */ +struct udc_string_desc_t { + usb_str_desc_t header; + le16_t string[Max(Max(USB_DEVICE_MANUFACTURE_NAME_SIZE, \ + USB_DEVICE_PRODUCT_NAME_SIZE), USB_DEVICE_SERIAL_NAME_SIZE)]; +}; +COMPILER_WORD_ALIGNED +static UDC_DESC_STORAGE struct udc_string_desc_t udc_string_desc = { + .header.bDescriptorType = USB_DT_STRING +}; +//! @} + +usb_iface_desc_t UDC_DESC_STORAGE *udc_get_interface_desc(void) +{ + return udc_ptr_iface; +} + +/** + * \brief Returns a value to check the end of USB Configuration descriptor + * + * \return address after the last byte of USB Configuration descriptor + */ +static usb_conf_desc_t UDC_DESC_STORAGE *udc_get_eof_conf(void) +{ + return (UDC_DESC_STORAGE usb_conf_desc_t *) ((uint8_t *) + udc_ptr_conf->desc + + le16_to_cpu(udc_ptr_conf->desc->wTotalLength)); +} + +#if (0!=USB_DEVICE_MAX_EP) +/** + * \brief Search specific descriptor in global interface descriptor + * + * \param desc Address of interface descriptor + * or previous specific descriptor found + * \param desc_id Descriptor ID to search + * + * \return address of specific descriptor found + * \return NULL if it is the end of global interface descriptor + */ +static usb_conf_desc_t UDC_DESC_STORAGE *udc_next_desc_in_iface(usb_conf_desc_t + UDC_DESC_STORAGE * desc, uint8_t desc_id) +{ + usb_conf_desc_t UDC_DESC_STORAGE *ptr_eof_desc; + + ptr_eof_desc = udc_get_eof_conf(); + // Go to next descriptor + desc = (UDC_DESC_STORAGE usb_conf_desc_t *) ((uint8_t *) desc + + desc->bLength); + // Check the end of configuration descriptor + while (ptr_eof_desc > desc) { + // If new interface descriptor is found, + // then it is the end of the current global interface descriptor + if (USB_DT_INTERFACE == desc->bDescriptorType) { + break; // End of global interface descriptor + } + if (desc_id == desc->bDescriptorType) { + return desc; // Specific descriptor found + } + // Go to next descriptor + desc = (UDC_DESC_STORAGE usb_conf_desc_t *) ((uint8_t *) desc + + desc->bLength); + } + return NULL; // No specific descriptor found +} +#endif + +/** + * \brief Search an interface descriptor + * This routine updates the internal pointer udc_ptr_iface. + * + * \param iface_num Interface number to find in Configuration Descriptor + * \param setting_num Setting number of interface to find + * + * \return 1 if found or 0 if not found + */ +static bool udc_update_iface_desc(uint8_t iface_num, uint8_t setting_num) +{ + usb_conf_desc_t UDC_DESC_STORAGE *ptr_end_desc; + + if (0 == udc_num_configuration) { + return false; + } + + if (iface_num >= udc_ptr_conf->desc->bNumInterfaces) { + return false; + } + + // Start at the beginning of configuration descriptor + udc_ptr_iface = (UDC_DESC_STORAGE usb_iface_desc_t *) + udc_ptr_conf->desc; + + // Check the end of configuration descriptor + ptr_end_desc = udc_get_eof_conf(); + while (ptr_end_desc > + (UDC_DESC_STORAGE usb_conf_desc_t *) udc_ptr_iface) { + if (USB_DT_INTERFACE == udc_ptr_iface->bDescriptorType) { + // A interface descriptor is found + // Check interface and alternate setting number + if ((iface_num == udc_ptr_iface->bInterfaceNumber) && + (setting_num == + udc_ptr_iface->bAlternateSetting)) { + return true; // Interface found + } + } + // Go to next descriptor + udc_ptr_iface = (UDC_DESC_STORAGE usb_iface_desc_t *) ( + (uint8_t *) udc_ptr_iface + + udc_ptr_iface->bLength); + } + return false; // Interface not found +} + +/** + * \brief Disables an usb device interface (UDI) + * This routine call the UDI corresponding to interface number + * + * \param iface_num Interface number to disable + * + * \return 1 if it is done or 0 if interface is not found + */ +static bool udc_iface_disable(uint8_t iface_num) +{ + udi_api_t UDC_DESC_STORAGE *udi_api; + + // Select first alternate setting of the interface + // to update udc_ptr_iface before call iface->getsetting() + if (!udc_update_iface_desc(iface_num, 0)) { + return false; + } + + // Select the interface with the current alternate setting + udi_api = udc_ptr_conf->udi_apis[iface_num]; + +#if (0!=USB_DEVICE_MAX_EP) + if (!udc_update_iface_desc(iface_num, udi_api->getsetting())) { + return false; + } + + // Start at the beginning of interface descriptor + { + usb_ep_desc_t UDC_DESC_STORAGE *ep_desc; + ep_desc = (UDC_DESC_STORAGE usb_ep_desc_t *) udc_ptr_iface; + while (1) { + // Search Endpoint descriptor included in global interface descriptor + ep_desc = (UDC_DESC_STORAGE usb_ep_desc_t *) + udc_next_desc_in_iface((UDC_DESC_STORAGE + usb_conf_desc_t *) + ep_desc, USB_DT_ENDPOINT); + if (NULL == ep_desc) { + break; + } + // Free the endpoint used by the interface + udd_ep_free(ep_desc->bEndpointAddress); + } + } +#endif + + // Disable interface + udi_api->disable(); + return true; +} + +/** + * \brief Enables an usb device interface (UDI) + * This routine calls the UDI corresponding + * to the interface and setting number. + * + * \param iface_num Interface number to enable + * \param setting_num Setting number to enable + * + * \return 1 if it is done or 0 if interface is not found + */ +static bool udc_iface_enable(uint8_t iface_num, uint8_t setting_num) +{ + // Select the interface descriptor + if (!udc_update_iface_desc(iface_num, setting_num)) { + return false; + } + +#if (0!=USB_DEVICE_MAX_EP) + usb_ep_desc_t UDC_DESC_STORAGE *ep_desc; + + // Start at the beginning of the global interface descriptor + ep_desc = (UDC_DESC_STORAGE usb_ep_desc_t *) udc_ptr_iface; + while (1) { + // Search Endpoint descriptor included in the global interface descriptor + ep_desc = (UDC_DESC_STORAGE usb_ep_desc_t *) + udc_next_desc_in_iface((UDC_DESC_STORAGE + usb_conf_desc_t *) ep_desc, + USB_DT_ENDPOINT); + if (NULL == ep_desc) + break; + // Alloc the endpoint used by the interface + if (!udd_ep_alloc(ep_desc->bEndpointAddress, + ep_desc->bmAttributes, + le16_to_cpu + (ep_desc->wMaxPacketSize))) { + return false; + } + } +#endif + // Enable the interface + return udc_ptr_conf->udi_apis[iface_num]->enable(); +} + +/*! \brief Start the USB Device stack + */ +void udc_start(void) +{ + udd_enable(); +} + +/*! \brief Stop the USB Device stack + */ +void udc_stop(void) +{ + udd_disable(); + udc_reset(); +} + +/** + * \brief Reset the current configuration of the USB device, + * This routines can be called by UDD when a RESET on the USB line occurs. + */ +void udc_reset(void) +{ + uint8_t iface_num; + + if (udc_num_configuration) { + for (iface_num = 0; + iface_num < udc_ptr_conf->desc->bNumInterfaces; + iface_num++) { + udc_iface_disable(iface_num); + } + } + udc_num_configuration = 0; +#if (USB_CONFIG_ATTR_REMOTE_WAKEUP \ + == (USB_DEVICE_ATTR & USB_CONFIG_ATTR_REMOTE_WAKEUP)) + if (CPU_TO_LE16(USB_DEV_STATUS_REMOTEWAKEUP) & udc_device_status) { + // Remote wakeup is enabled then disable it + UDC_REMOTEWAKEUP_DISABLE(); + } +#endif + udc_device_status = +#if (USB_DEVICE_ATTR & USB_CONFIG_ATTR_SELF_POWERED) + CPU_TO_LE16(USB_DEV_STATUS_SELF_POWERED); +#else + CPU_TO_LE16(USB_DEV_STATUS_BUS_POWERED); +#endif +} + +void udc_sof_notify(void) +{ + uint8_t iface_num; + + if (udc_num_configuration) { + for (iface_num = 0; + iface_num < udc_ptr_conf->desc->bNumInterfaces; + iface_num++) { + if (udc_ptr_conf->udi_apis[iface_num]->sof_notify != NULL) { + udc_ptr_conf->udi_apis[iface_num]->sof_notify(); + } + } + } +} + +/** + * \brief Standard device request to get device status + * + * \return true if success + */ +static bool udc_req_std_dev_get_status(void) +{ + if (udd_g_ctrlreq.req.wLength != sizeof(udc_device_status)) { + return false; + } + + udd_set_setup_payload( (uint8_t *) & udc_device_status, + sizeof(udc_device_status)); + return true; +} + +#if (0!=USB_DEVICE_MAX_EP) +/** + * \brief Standard endpoint request to get endpoint status + * + * \return true if success + */ +static bool udc_req_std_ep_get_status(void) +{ + static le16_t udc_ep_status; + + if (udd_g_ctrlreq.req.wLength != sizeof(udc_ep_status)) { + return false; + } + + udc_ep_status = udd_ep_is_halted(udd_g_ctrlreq.req. + wIndex & 0xFF) ? CPU_TO_LE16(USB_EP_STATUS_HALTED) : 0; + + udd_set_setup_payload( (uint8_t *) & udc_ep_status, + sizeof(udc_ep_status)); + return true; +} +#endif + +/** + * \brief Standard device request to change device status + * + * \return true if success + */ +static bool udc_req_std_dev_clear_feature(void) +{ + if (udd_g_ctrlreq.req.wLength) { + return false; + } + + if (udd_g_ctrlreq.req.wValue == USB_DEV_FEATURE_REMOTE_WAKEUP) { + udc_device_status &= CPU_TO_LE16(~(uint32_t)USB_DEV_STATUS_REMOTEWAKEUP); +#if (USB_CONFIG_ATTR_REMOTE_WAKEUP \ + == (USB_DEVICE_ATTR & USB_CONFIG_ATTR_REMOTE_WAKEUP)) + UDC_REMOTEWAKEUP_DISABLE(); +#endif + return true; + } + return false; +} + +#if (0!=USB_DEVICE_MAX_EP) +/** + * \brief Standard endpoint request to clear endpoint feature + * + * \return true if success + */ +static bool udc_req_std_ep_clear_feature(void) +{ + if (udd_g_ctrlreq.req.wLength) { + return false; + } + + if (udd_g_ctrlreq.req.wValue == USB_EP_FEATURE_HALT) { + return udd_ep_clear_halt(udd_g_ctrlreq.req.wIndex & 0xFF); + } + return false; +} +#endif + +/** + * \brief Standard device request to set a feature + * + * \return true if success + */ +static bool udc_req_std_dev_set_feature(void) +{ + if (udd_g_ctrlreq.req.wLength) { + return false; + } + + switch (udd_g_ctrlreq.req.wValue) { + + case USB_DEV_FEATURE_REMOTE_WAKEUP: +#if (USB_CONFIG_ATTR_REMOTE_WAKEUP \ + == (USB_DEVICE_ATTR & USB_CONFIG_ATTR_REMOTE_WAKEUP)) + udc_device_status |= CPU_TO_LE16(USB_DEV_STATUS_REMOTEWAKEUP); + UDC_REMOTEWAKEUP_ENABLE(); + return true; +#else + return false; +#endif + +#ifdef USB_DEVICE_HS_SUPPORT + case USB_DEV_FEATURE_TEST_MODE: + if (!udd_is_high_speed()) { + break; + } + if (udd_g_ctrlreq.req.wIndex & 0xff) { + break; + } + // Unconfigure the device, terminating all ongoing requests + udc_reset(); + switch ((udd_g_ctrlreq.req.wIndex >> 8) & 0xFF) { + case USB_DEV_TEST_MODE_J: + udd_g_ctrlreq.callback = udd_test_mode_j; + return true; + + case USB_DEV_TEST_MODE_K: + udd_g_ctrlreq.callback = udd_test_mode_k; + return true; + + case USB_DEV_TEST_MODE_SE0_NAK: + udd_g_ctrlreq.callback = udd_test_mode_se0_nak; + return true; + + case USB_DEV_TEST_MODE_PACKET: + udd_g_ctrlreq.callback = udd_test_mode_packet; + return true; + + case USB_DEV_TEST_MODE_FORCE_ENABLE: // Only for downstream facing hub ports + default: + break; + } + break; +#endif + default: + break; + } + return false; +} + +/** + * \brief Standard endpoint request to halt an endpoint + * + * \return true if success + */ +#if (0!=USB_DEVICE_MAX_EP) +static bool udc_req_std_ep_set_feature(void) +{ + if (udd_g_ctrlreq.req.wLength) { + return false; + } + if (udd_g_ctrlreq.req.wValue == USB_EP_FEATURE_HALT) { + udd_ep_abort(udd_g_ctrlreq.req.wIndex & 0xFF); + return udd_ep_set_halt(udd_g_ctrlreq.req.wIndex & 0xFF); + } + return false; +} +#endif + +/** + * \brief Change the address of device + * Callback called at the end of request set address + */ +static void udc_valid_address(void) +{ + udd_set_address(udd_g_ctrlreq.req.wValue & 0x7F); +} + +/** + * \brief Standard device request to set device address + * + * \return true if success + */ +static bool udc_req_std_dev_set_address(void) +{ + if (udd_g_ctrlreq.req.wLength) { + return false; + } + + // The address must be changed at the end of setup request after the handshake + // then we use a callback to change address + udd_g_ctrlreq.callback = udc_valid_address; + return true; +} + +/** + * \brief Standard device request to get device string descriptor + * + * \return true if success + */ +static bool udc_req_std_dev_get_str_desc(void) +{ + uint8_t i; + const uint8_t *str; + uint8_t str_length = 0; + + // Link payload pointer to the string corresponding at request + switch (udd_g_ctrlreq.req.wValue & 0xff) { + case 0: + udd_set_setup_payload((uint8_t *) &udc_string_desc_languageid, + sizeof(udc_string_desc_languageid)); + break; + +#ifdef USB_DEVICE_MANUFACTURE_NAME + case 1: + str_length = USB_DEVICE_MANUFACTURE_NAME_SIZE; + str = udc_string_manufacturer_name; + break; +#endif +#ifdef USB_DEVICE_PRODUCT_NAME + case 2: + str_length = USB_DEVICE_PRODUCT_NAME_SIZE; + str = udc_string_product_name; + break; +#endif +#if defined USB_DEVICE_SERIAL_NAME || defined USB_DEVICE_GET_SERIAL_NAME_POINTER + case 3: + str_length = USB_DEVICE_SERIAL_NAME_SIZE; + str = udc_get_string_serial_name(); + break; +#endif + default: +#ifdef UDC_GET_EXTRA_STRING + if (UDC_GET_EXTRA_STRING()) { + break; + } +#endif + return false; + } + + if (str_length) { + for(i = 0; i < str_length; i++) { + udc_string_desc.string[i] = cpu_to_le16((le16_t)str[i]); + } + + udc_string_desc.header.bLength = 2 + (str_length) * 2; + udd_set_setup_payload( + (uint8_t *) &udc_string_desc, + udc_string_desc.header.bLength); + } + + return true; +} + +/** + * \brief Standard device request to get descriptors about USB device + * + * \return true if success + */ +static bool udc_req_std_dev_get_descriptor(void) +{ + uint8_t conf_num; + + conf_num = udd_g_ctrlreq.req.wValue & 0xff; + + // Check descriptor ID + switch ((uint8_t) (udd_g_ctrlreq.req.wValue >> 8)) { + case USB_DT_DEVICE: + // Device descriptor requested +#ifdef USB_DEVICE_HS_SUPPORT + if (!udd_is_high_speed()) { + udd_set_setup_payload( + (uint8_t *) udc_config.confdev_hs, + udc_config.confdev_hs->bLength); + } else +#endif + { + udd_set_setup_payload( + (uint8_t *) udc_config.confdev_lsfs, + udc_config.confdev_lsfs->bLength); + } + break; + + case USB_DT_CONFIGURATION: + // Configuration descriptor requested +#ifdef USB_DEVICE_HS_SUPPORT + if (udd_is_high_speed()) { + // HS descriptor + if (conf_num >= udc_config.confdev_hs-> + bNumConfigurations) { + return false; + } + udd_set_setup_payload( + (uint8_t *)udc_config.conf_hs[conf_num].desc, + le16_to_cpu(udc_config.conf_hs[conf_num].desc->wTotalLength)); + } else +#endif + { + // FS descriptor + if (conf_num >= udc_config.confdev_lsfs-> + bNumConfigurations) { + return false; + } + udd_set_setup_payload( + (uint8_t *)udc_config.conf_lsfs[conf_num].desc, + le16_to_cpu(udc_config.conf_lsfs[conf_num].desc->wTotalLength)); + } + ((usb_conf_desc_t *) udd_g_ctrlreq.payload)->bDescriptorType = + USB_DT_CONFIGURATION; + break; + +#ifdef USB_DEVICE_HS_SUPPORT + case USB_DT_DEVICE_QUALIFIER: + // Device qualifier descriptor requested + udd_set_setup_payload( (uint8_t *) udc_config.qualifier, + udc_config.qualifier->bLength); + break; + + case USB_DT_OTHER_SPEED_CONFIGURATION: + // Other configuration descriptor requested + if (!udd_is_high_speed()) { + // HS descriptor + if (conf_num >= udc_config.confdev_hs-> + bNumConfigurations) { + return false; + } + udd_set_setup_payload( + (uint8_t *)udc_config.conf_hs[conf_num].desc, + le16_to_cpu(udc_config.conf_hs[conf_num].desc->wTotalLength)); + } else { + // FS descriptor + if (conf_num >= udc_config.confdev_lsfs-> + bNumConfigurations) { + return false; + } + udd_set_setup_payload( + (uint8_t *)udc_config.conf_lsfs[conf_num].desc, + le16_to_cpu(udc_config.conf_lsfs[conf_num].desc->wTotalLength)); + } + ((usb_conf_desc_t *) udd_g_ctrlreq.payload)->bDescriptorType = + USB_DT_OTHER_SPEED_CONFIGURATION; + break; +#endif + + case USB_DT_BOS: + // Device BOS descriptor requested + if (udc_config.conf_bos == NULL) { + return false; + } + udd_set_setup_payload( (uint8_t *) udc_config.conf_bos, + udc_config.conf_bos->wTotalLength); + break; + + case USB_DT_STRING: + // String descriptor requested + if (!udc_req_std_dev_get_str_desc()) { + return false; + } + break; + + default: + // Unknown descriptor requested + return false; + } + // if the descriptor is larger than length requested, then reduce it + if (udd_g_ctrlreq.req.wLength < udd_g_ctrlreq.payload_size) { + udd_g_ctrlreq.payload_size = udd_g_ctrlreq.req.wLength; + } + return true; +} + +/** + * \brief Standard device request to get configuration number + * + * \return true if success + */ +static bool udc_req_std_dev_get_configuration(void) +{ + if (udd_g_ctrlreq.req.wLength != 1) { + return false; + } + + udd_set_setup_payload(&udc_num_configuration,1); + return true; +} + +/** + * \brief Standard device request to enable a configuration + * + * \return true if success + */ +static bool udc_req_std_dev_set_configuration(void) +{ + uint8_t iface_num; + + // Check request length + if (udd_g_ctrlreq.req.wLength) { + return false; + } + // Authorize configuration only if the address is valid + if (!udd_getaddress()) { + return false; + } + // Check the configuration number requested +#ifdef USB_DEVICE_HS_SUPPORT + if (udd_is_high_speed()) { + // HS descriptor + if ((udd_g_ctrlreq.req.wValue & 0xFF) > + udc_config.confdev_hs->bNumConfigurations) { + return false; + } + } else +#endif + { + // FS descriptor + if ((udd_g_ctrlreq.req.wValue & 0xFF) > + udc_config.confdev_lsfs->bNumConfigurations) { + return false; + } + } + + // Reset current configuration + udc_reset(); + + // Enable new configuration + udc_num_configuration = udd_g_ctrlreq.req.wValue & 0xFF; + if (udc_num_configuration == 0) { + return true; // Default empty configuration requested + } + // Update pointer of the configuration descriptor +#ifdef USB_DEVICE_HS_SUPPORT + if (udd_is_high_speed()) { + // HS descriptor + udc_ptr_conf = &udc_config.conf_hs[udc_num_configuration - 1]; + } else +#endif + { + // FS descriptor + udc_ptr_conf = &udc_config.conf_lsfs[udc_num_configuration - 1]; + } + // Enable all interfaces of the selected configuration + for (iface_num = 0; iface_num < udc_ptr_conf->desc->bNumInterfaces; + iface_num++) { + if (!udc_iface_enable(iface_num, 0)) { + return false; + } + } + return true; +} + +/** + * \brief Standard interface request + * to get the alternate setting number of an interface + * + * \return true if success + */ +static bool udc_req_std_iface_get_setting(void) +{ + static uint8_t udc_iface_setting; + uint8_t iface_num; + udi_api_t UDC_DESC_STORAGE *udi_api; + + if (udd_g_ctrlreq.req.wLength != 1) { + return false; // Error in request + } + if (!udc_num_configuration) { + return false; // The device is not is configured state yet + } + + // Check the interface number included in the request + iface_num = udd_g_ctrlreq.req.wIndex & 0xFF; + if (iface_num >= udc_ptr_conf->desc->bNumInterfaces) { + return false; + } + + // Select first alternate setting of the interface to update udc_ptr_iface + // before call iface->getsetting() + if (!udc_update_iface_desc(iface_num, 0)) { + return false; + } + // Get alternate setting from UDI + udi_api = udc_ptr_conf->udi_apis[iface_num]; + udc_iface_setting = udi_api->getsetting(); + + // Link value to payload pointer of request + udd_set_setup_payload(&udc_iface_setting,1); + return true; +} + +/** + * \brief Standard interface request + * to set an alternate setting of an interface + * + * \return true if success + */ +static bool udc_req_std_iface_set_setting(void) +{ + uint8_t iface_num, setting_num; + + if (udd_g_ctrlreq.req.wLength) { + return false; // Error in request + } + if (!udc_num_configuration) { + return false; // The device is not is configured state yet + } + + iface_num = udd_g_ctrlreq.req.wIndex & 0xFF; + setting_num = udd_g_ctrlreq.req.wValue & 0xFF; + + // Disable current setting + if (!udc_iface_disable(iface_num)) { + return false; + } + + // Enable new setting + return udc_iface_enable(iface_num, setting_num); +} + +/** + * \brief Main routine to manage the standard USB SETUP request + * + * \return true if the request is supported + */ +static bool udc_reqstd(void) +{ + if (Udd_setup_is_in()) { + // GET Standard Requests + if (udd_g_ctrlreq.req.wLength == 0) { + return false; // Error for USB host + } + + if (USB_REQ_RECIP_DEVICE == Udd_setup_recipient()) { + // Standard Get Device request + switch (udd_g_ctrlreq.req.bRequest) { + case USB_REQ_GET_STATUS: + return udc_req_std_dev_get_status(); + case USB_REQ_GET_DESCRIPTOR: + return udc_req_std_dev_get_descriptor(); + case USB_REQ_GET_CONFIGURATION: + return udc_req_std_dev_get_configuration(); + default: + break; + } + } + + if (USB_REQ_RECIP_INTERFACE == Udd_setup_recipient()) { + // Standard Get Interface request + switch (udd_g_ctrlreq.req.bRequest) { + case USB_REQ_GET_INTERFACE: + return udc_req_std_iface_get_setting(); + default: + break; + } + } +#if (0!=USB_DEVICE_MAX_EP) + if (USB_REQ_RECIP_ENDPOINT == Udd_setup_recipient()) { + // Standard Get Endpoint request + switch (udd_g_ctrlreq.req.bRequest) { + case USB_REQ_GET_STATUS: + return udc_req_std_ep_get_status(); + default: + break; + } + } +#endif + } else { + // SET Standard Requests + if (USB_REQ_RECIP_DEVICE == Udd_setup_recipient()) { + // Standard Set Device request + switch (udd_g_ctrlreq.req.bRequest) { + case USB_REQ_SET_ADDRESS: + return udc_req_std_dev_set_address(); + case USB_REQ_CLEAR_FEATURE: + return udc_req_std_dev_clear_feature(); + case USB_REQ_SET_FEATURE: + return udc_req_std_dev_set_feature(); + case USB_REQ_SET_CONFIGURATION: + return udc_req_std_dev_set_configuration(); + case USB_REQ_SET_DESCRIPTOR: + /* Not supported (defined as optional by the USB 2.0 spec) */ + break; + default: + break; + } + } + + if (USB_REQ_RECIP_INTERFACE == Udd_setup_recipient()) { + // Standard Set Interface request + switch (udd_g_ctrlreq.req.bRequest) { + case USB_REQ_SET_INTERFACE: + return udc_req_std_iface_set_setting(); + default: + break; + } + } +#if (0!=USB_DEVICE_MAX_EP) + if (USB_REQ_RECIP_ENDPOINT == Udd_setup_recipient()) { + // Standard Set Endpoint request + switch (udd_g_ctrlreq.req.bRequest) { + case USB_REQ_CLEAR_FEATURE: + return udc_req_std_ep_clear_feature(); + case USB_REQ_SET_FEATURE: + return udc_req_std_ep_set_feature(); + default: + break; + } + } +#endif + } + return false; +} + +/** + * \brief Send the SETUP interface request to UDI + * + * \return true if the request is supported + */ +static bool udc_req_iface(void) +{ + uint8_t iface_num; + udi_api_t UDC_DESC_STORAGE *udi_api; + + if (0 == udc_num_configuration) { + return false; // The device is not is configured state yet + } + // Check interface number + iface_num = udd_g_ctrlreq.req.wIndex & 0xFF; + if (iface_num >= udc_ptr_conf->desc->bNumInterfaces) { + return false; + } + + //* To update udc_ptr_iface with the selected interface in request + // Select first alternate setting of interface to update udc_ptr_iface + // before calling udi_api->getsetting() + if (!udc_update_iface_desc(iface_num, 0)) { + return false; + } + // Select the interface with the current alternate setting + udi_api = udc_ptr_conf->udi_apis[iface_num]; + if (!udc_update_iface_desc(iface_num, udi_api->getsetting())) { + return false; + } + + // Send the SETUP request to the UDI corresponding to the interface number + return udi_api->setup(); +} + +/** + * \brief Send the SETUP interface request to UDI + * + * \return true if the request is supported + */ +static bool udc_req_ep(void) +{ + uint8_t iface_num; + udi_api_t UDC_DESC_STORAGE *udi_api; + + if (0 == udc_num_configuration) { + return false; // The device is not is configured state yet + } + // Send this request on all enabled interfaces + iface_num = udd_g_ctrlreq.req.wIndex & 0xFF; + for (iface_num = 0; iface_num < udc_ptr_conf->desc->bNumInterfaces; + iface_num++) { + // Select the interface with the current alternate setting + udi_api = udc_ptr_conf->udi_apis[iface_num]; + if (!udc_update_iface_desc(iface_num, udi_api->getsetting())) { + return false; + } + + // Send the SETUP request to the UDI + if (udi_api->setup()) { + return true; + } + } + return false; +} + +/** + * \brief Main routine to manage the USB SETUP request. + * + * This function parses a USB SETUP request and submits an appropriate + * response back to the host or, in the case of SETUP OUT requests + * with data, sets up a buffer for receiving the data payload. + * + * The main standard requests defined by the USB 2.0 standard are handled + * internally. The interface requests are sent to UDI, and the specific request + * sent to a specific application callback. + * + * \return true if the request is supported, else the request is stalled by UDD + */ +bool udc_process_setup(void) +{ + // By default no data (receive/send) and no callbacks registered + udd_g_ctrlreq.payload_size = 0; + udd_g_ctrlreq.callback = NULL; + udd_g_ctrlreq.over_under_run = NULL; + + if (Udd_setup_is_in()) { + if (udd_g_ctrlreq.req.wLength == 0) { + return false; // Error from USB host + } + } + + // If standard request then try to decode it in UDC + if (Udd_setup_type() == USB_REQ_TYPE_STANDARD) { + if (udc_reqstd()) { + return true; + } + } + + // If interface request then try to decode it in UDI + if (Udd_setup_recipient() == USB_REQ_RECIP_INTERFACE) { + if (udc_req_iface()) { + return true; + } + } + + // If endpoint request then try to decode it in UDI + if (Udd_setup_recipient() == USB_REQ_RECIP_ENDPOINT) { + if (udc_req_ep()) { + return true; + } + } + + // Here SETUP request unknown by UDC and UDIs +#ifdef USB_DEVICE_SPECIFIC_REQUEST + // Try to decode it in specific callback + return USB_DEVICE_SPECIFIC_REQUEST(); // Ex: Vendor request,... +#else + return false; +#endif +} + +//! @} diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/udc/udc.h b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/udc/udc.h new file mode 100644 index 0000000..b8cb451 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/udc/udc.h @@ -0,0 +1,694 @@ +/** + * \file + * + * \brief Interface of the USB Device Controller (UDC) + * + * Copyright (c) 2009 - 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _UDC_H_ +#define _UDC_H_ + +#include "conf_usb.h" +#include "usb_protocol.h" +#include "udc_desc.h" +#include "udd.h" + +#if USB_DEVICE_VENDOR_ID == 0 +# error USB_DEVICE_VENDOR_ID cannot be equal to 0 +#endif + +#if USB_DEVICE_PRODUCT_ID == 0 +# error USB_DEVICE_PRODUCT_ID cannot be equal to 0 +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \ingroup usb_device_group + * \defgroup udc_group USB Device Controller (UDC) + * + * The UDC provides a high-level abstraction of the usb device. + * You can use these functions to control the main device state + * (start/attach/wakeup). + * + * \section USB_DEVICE_CONF USB Device Custom configuration + * The following USB Device configuration must be included in the conf_usb.h + * file of the application. + * + * USB_DEVICE_VENDOR_ID (Word)
+ * Vendor ID provided by USB org (ATMEL 0x03EB). + * + * USB_DEVICE_PRODUCT_ID (Word)
+ * Product ID (Referenced in usb_atmel.h). + * + * USB_DEVICE_MAJOR_VERSION (Byte)
+ * Major version of the device + * + * USB_DEVICE_MINOR_VERSION (Byte)
+ * Minor version of the device + * + * USB_DEVICE_MANUFACTURE_NAME (string)
+ * ASCII name for the manufacture + * + * USB_DEVICE_PRODUCT_NAME (string)
+ * ASCII name for the product + * + * USB_DEVICE_SERIAL_NAME (string)
+ * ASCII name to enable and set a serial number + * + * USB_DEVICE_POWER (Numeric)
+ * (unit mA) Maximum device power + * + * USB_DEVICE_ATTR (Byte)
+ * USB attributes available: + * - USB_CONFIG_ATTR_SELF_POWERED + * - USB_CONFIG_ATTR_REMOTE_WAKEUP + * Note: if remote wake enabled then defines remotewakeup callbacks, + * see Table 5-2. External API from UDC - Callback + * + * USB_DEVICE_LOW_SPEED (Only defined)
+ * Force the USB Device to run in low speed + * + * USB_DEVICE_HS_SUPPORT (Only defined)
+ * Authorize the USB Device to run in high speed + * + * USB_DEVICE_MAX_EP (Byte)
+ * Define the maximum endpoint number used by the USB Device.
+ * This one is already defined in UDI default configuration. + * Ex: + * - When endpoint control 0x00, endpoint 0x01 and + * endpoint 0x82 is used then USB_DEVICE_MAX_EP=2 + * - When only endpoint control 0x00 is used then USB_DEVICE_MAX_EP=0 + * - When endpoint 0x01 and endpoint 0x81 is used then USB_DEVICE_MAX_EP=1
+ * (configuration not possible on USBB interface) + * @{ + */ + +/** + * \brief Authorizes the VBUS event + * + * \return true, if the VBUS monitoring is possible. + * + * \section udc_vbus_monitoring VBus monitoring used cases + * + * The VBus monitoring is used only for USB SELF Power application. + * + * - By default the USB device is automatically attached when Vbus is high + * or when USB is start for devices without internal Vbus monitoring. + * conf_usb.h file does not contains define USB_DEVICE_ATTACH_AUTO_DISABLE. + * \code //#define USB_DEVICE_ATTACH_AUTO_DISABLE \endcode + * + * - Add custom VBUS monitoring. conf_usb.h file contains define + * USB_DEVICE_ATTACH_AUTO_DISABLE: + * \code #define USB_DEVICE_ATTACH_AUTO_DISABLE \endcode + * User C file contains: + * \code + // Authorize VBUS monitoring + if (!udc_include_vbus_monitoring()) { + // Implement custom VBUS monitoring via GPIO or other + } + Event_VBUS_present() // VBUS interrupt or GPIO interrupt or other + { + // Attach USB Device + udc_attach(); + } +\endcode + * + * - Case of battery charging. conf_usb.h file contains define + * USB_DEVICE_ATTACH_AUTO_DISABLE: + * \code #define USB_DEVICE_ATTACH_AUTO_DISABLE \endcode + * User C file contains: + * \code + Event VBUS present() // VBUS interrupt or GPIO interrupt or .. + { + // Authorize battery charging, but wait key press to start USB. + } + Event Key press() + { + // Stop batteries charging + // Start USB + udc_attach(); + } +\endcode + */ +static inline bool udc_include_vbus_monitoring(void) +{ + return udd_include_vbus_monitoring(); +} + +/*! \brief Start the USB Device stack + */ +void udc_start(void); + +/*! \brief Stop the USB Device stack + */ +void udc_stop(void); + +/** + * \brief Attach device to the bus when possible + * + * \warning If a VBus control is included in driver, + * then it will attach device when an acceptable Vbus + * level from the host is detected. + */ +static inline void udc_attach(void) +{ + udd_attach(); +} + + +/** + * \brief Detaches the device from the bus + * + * The driver must remove pull-up on USB line D- or D+. + */ +static inline void udc_detach(void) +{ + udd_detach(); +} + + +/*! \brief The USB driver sends a resume signal called \e "Upstream Resume" + * This is authorized only when the remote wakeup feature is enabled by host. + */ +static inline void udc_remotewakeup(void) +{ + udd_send_remotewakeup(); +} + + +/** + * \brief Returns a pointer on the current interface descriptor + * + * \return pointer on the current interface descriptor. + */ +usb_iface_desc_t UDC_DESC_STORAGE *udc_get_interface_desc(void); + +//@} + +/** + * \ingroup usb_group + * \defgroup usb_device_group USB Stack Device + * + * This module includes USB Stack Device implementation. + * The stack is divided in three parts: + * - USB Device Controller (UDC) provides USB chapter 9 compliance + * - USB Device Interface (UDI) provides USB Class compliance + * - USB Device Driver (UDD) provides USB Driver for each Atmel MCU + + * Many USB Device applications can be implemented on Atmel MCU. + * Atmel provides many application notes for different applications: + * - AVR4900, provides general information about Device Stack + * - AVR4901, explains how to create a new class + * - AVR4902, explains how to create a composite device + * - AVR49xx, all device classes provided in ASF have an application note + * + * A basic USB knowledge is required to understand the USB Device + * Class application notes (HID,MS,CDC,PHDC,...). + * Then, to create an USB device with + * only one class provided by ASF, refer directly to the application note + * corresponding to this USB class. The USB Device application note for + * New Class and Composite is dedicated to advanced USB users. + * + * @{ + */ + +//! @} + +#ifdef __cplusplus +} +#endif + +/** + * \ingroup udc_group + * \defgroup udc_basic_use_case_setup_prereq USB Device Controller (UDC) - Prerequisites + * Common prerequisites for all USB devices. + * + * This module is based on USB device stack full interrupt driven, and supporting + * \ref sleepmgr_group sleepmgr. For AVR and SAM3/4 devices the \ref clk_group clock services + * is supported. For SAMD devices the \ref asfdoc_sam0_system_clock_group clock driver is supported. + * + * The following procedure must be executed to setup the project correctly: + * - Specify the clock configuration: + * - XMEGA USB devices need 48MHz clock input.\n + * XMEGA USB devices need CPU frequency higher than 12MHz.\n + * You can use either an internal RC48MHz auto calibrated by Start of Frames + * or an external OSC. + * - UC3 and SAM3/4 devices without USB high speed support need 48MHz clock input.\n + * You must use a PLL and an external OSC. + * - UC3 and SAM3/4 devices with USB high speed support need 12MHz clock input.\n + * You must use an external OSC. + * - UC3 devices with USBC hardware need CPU frequency higher than 25MHz. + * - SAMD devices without USB high speed support need 48MHz clock input.\n + * You should use DFLL with USBCRM. + * - In conf_board.h, the define CONF_BOARD_USB_PORT must be added to enable USB lines. + * (Not mandatory for all boards) + * - Enable interrupts + * - Initialize the clock service + * + * The usage of \ref sleepmgr_group sleepmgr service is optional, but recommended to reduce power + * consumption: + * - Initialize the sleep manager service + * - Activate sleep mode when the application is in IDLE state + * + * \subpage udc_conf_clock. + * + * for AVR and SAM3/4 devices, add to the initialization code: + * \code + sysclk_init(); + irq_initialize_vectors(); + cpu_irq_enable(); + board_init(); + sleepmgr_init(); // Optional +\endcode + * + * For SAMD devices, add to the initialization code: + * \code + system_init(); + irq_initialize_vectors(); + cpu_irq_enable(); + sleepmgr_init(); // Optional +\endcode + * Add to the main IDLE loop: + * \code + sleepmgr_enter_sleep(); // Optional +\endcode + * + */ + +/** + * \ingroup udc_group + * \defgroup udc_basic_use_case_setup_code USB Device Controller (UDC) - Example code + * Common example code for all USB devices. + * + * Content of conf_usb.h: + * \code + #define USB_DEVICE_VENDOR_ID 0x03EB + #define USB_DEVICE_PRODUCT_ID 0xXXXX + #define USB_DEVICE_MAJOR_VERSION 1 + #define USB_DEVICE_MINOR_VERSION 0 + #define USB_DEVICE_POWER 100 + #define USB_DEVICE_ATTR USB_CONFIG_ATTR_BUS_POWERED +\endcode + * + * Add to application C-file: + * \code + void usb_init(void) + { + udc_start(); + } +\endcode + */ + +/** + * \ingroup udc_group + * \defgroup udc_basic_use_case_setup_flow USB Device Controller (UDC) - Workflow + * Common workflow for all USB devices. + * + * -# Ensure that conf_usb.h is available and contains the following configuration + * which is the main USB device configuration: + * - \code // Vendor ID provided by USB org (ATMEL 0x03EB) + #define USB_DEVICE_VENDOR_ID 0x03EB // Type Word + // Product ID (Atmel PID referenced in usb_atmel.h) + #define USB_DEVICE_PRODUCT_ID 0xXXXX // Type Word + // Major version of the device + #define USB_DEVICE_MAJOR_VERSION 1 // Type Byte + // Minor version of the device + #define USB_DEVICE_MINOR_VERSION 0 // Type Byte + // Maximum device power (mA) + #define USB_DEVICE_POWER 100 // Type 9-bits + // USB attributes to enable features + #define USB_DEVICE_ATTR USB_CONFIG_ATTR_BUS_POWERED // Flags \endcode + * -# Call the USB device stack start function to enable stack and start USB: + * - \code udc_start(); \endcode + * \note In case of USB dual roles (Device and Host) managed through USB OTG connector + * (USB ID pin), the call of udc_start() must be removed and replaced by uhc_start(). + * SeRefer to "AVR4950 section 6.1 Dual roles" for further information about dual roles. + */ + +/** + * \page udc_conf_clock conf_clock.h examples with USB support + * + * Content of XMEGA conf_clock.h: + * \code + // Configuration based on internal RC: + // USB clock need of 48Mhz + #define CONFIG_USBCLK_SOURCE USBCLK_SRC_RCOSC + #define CONFIG_OSC_RC32_CAL 48000000UL + #define CONFIG_OSC_AUTOCAL_RC32MHZ_REF_OSC OSC_ID_USBSOF + // CPU clock need of clock > 12MHz to run with USB (Here 24MHz) + #define CONFIG_SYSCLK_SOURCE SYSCLK_SRC_RC32MHZ + #define CONFIG_SYSCLK_PSADIV SYSCLK_PSADIV_2 + #define CONFIG_SYSCLK_PSBCDIV SYSCLK_PSBCDIV_1_1 +\endcode + * + * Content of conf_clock.h for AT32UC3A0, AT32UC3A1, AT32UC3B devices (USBB): + * \code + // Configuration based on 12MHz external OSC: + #define CONFIG_PLL1_SOURCE PLL_SRC_OSC0 + #define CONFIG_PLL1_MUL 8 + #define CONFIG_PLL1_DIV 2 + #define CONFIG_USBCLK_SOURCE USBCLK_SRC_PLL1 + #define CONFIG_USBCLK_DIV 1 // Fusb = Fsys/(2 ^ USB_div) +\endcode + * + * Content of conf_clock.h for AT32UC3A3, AT32UC3A4 devices (USBB with high speed support): + * \code + // Configuration based on 12MHz external OSC: + #define CONFIG_USBCLK_SOURCE USBCLK_SRC_OSC0 + #define CONFIG_USBCLK_DIV 1 // Fusb = Fsys/(2 ^ USB_div) +\endcode + * + * Content of conf_clock.h for AT32UC3C, ATUCXXD, ATUCXXL3U, ATUCXXL4U devices (USBC): + * \code + // Configuration based on 12MHz external OSC: + #define CONFIG_PLL1_SOURCE PLL_SRC_OSC0 + #define CONFIG_PLL1_MUL 8 + #define CONFIG_PLL1_DIV 2 + #define CONFIG_USBCLK_SOURCE USBCLK_SRC_PLL1 + #define CONFIG_USBCLK_DIV 1 // Fusb = Fsys/(2 ^ USB_div) + // CPU clock need of clock > 25MHz to run with USBC + #define CONFIG_SYSCLK_SOURCE SYSCLK_SRC_PLL1 +\endcode + * + * Content of conf_clock.h for SAM3S, SAM3SD, SAM4S devices (UPD: USB Peripheral Device): + * \code + // PLL1 (B) Options (Fpll = (Fclk * PLL_mul) / PLL_div) + #define CONFIG_PLL1_SOURCE PLL_SRC_MAINCK_XTAL + #define CONFIG_PLL1_MUL 16 + #define CONFIG_PLL1_DIV 2 + // USB Clock Source Options (Fusb = FpllX / USB_div) + #define CONFIG_USBCLK_SOURCE USBCLK_SRC_PLL1 + #define CONFIG_USBCLK_DIV 2 +\endcode + * + * Content of conf_clock.h for SAM3U device (UPDHS: USB Peripheral Device High Speed): + * \code + // USB Clock Source fixed at UPLL. +\endcode + * + * Content of conf_clock.h for SAM3X, SAM3A devices (UOTGHS: USB OTG High Speed): + * \code + // USB Clock Source fixed at UPLL. + #define CONFIG_USBCLK_SOURCE USBCLK_SRC_UPLL + #define CONFIG_USBCLK_DIV 1 +\endcode + * + * Content of conf_clocks.h for SAMD devices (USB): + * \code + // System clock bus configuration + # define CONF_CLOCK_FLASH_WAIT_STATES 2 + + // USB Clock Source fixed at DFLL. + // SYSTEM_CLOCK_SOURCE_DFLL configuration - Digital Frequency Locked Loop + # define CONF_CLOCK_DFLL_ENABLE true + # define CONF_CLOCK_DFLL_LOOP_MODE SYSTEM_CLOCK_DFLL_LOOP_MODE_USB_RECOVERY + # define CONF_CLOCK_DFLL_ON_DEMAND true + + // Set this to true to configure the GCLK when running clocks_init. + // If set to false, none of the GCLK generators will be configured in clocks_init(). + # define CONF_CLOCK_CONFIGURE_GCLK true + + // Configure GCLK generator 0 (Main Clock) + # define CONF_CLOCK_GCLK_0_ENABLE true + # define CONF_CLOCK_GCLK_0_RUN_IN_STANDBY true + # define CONF_CLOCK_GCLK_0_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_DFLL + # define CONF_CLOCK_GCLK_0_PRESCALER 1 + # define CONF_CLOCK_GCLK_0_OUTPUT_ENABLE false +\endcode + */ + +/** + * \page udc_use_case_1 Change USB speed + * + * In this use case, the USB device is used with different USB speeds. + * + * \section udc_use_case_1_setup Setup steps + * + * Prior to implement this use case, be sure to have already + * apply the UDI module "basic use case". + * + * \section udc_use_case_1_usage Usage steps + * + * \subsection udc_use_case_1_usage_code Example code + * Content of conf_usb.h: + * \code + #if // Low speed + #define USB_DEVICE_LOW_SPEED + // #define USB_DEVICE_HS_SUPPORT + + #elif // Full speed + // #define USB_DEVICE_LOW_SPEED + // #define USB_DEVICE_HS_SUPPORT + + #elif // High speed + // #define USB_DEVICE_LOW_SPEED + #define USB_DEVICE_HS_SUPPORT + + #endif +\endcode + * + * \subsection udc_use_case_1_usage_flow Workflow + * -# Ensure that conf_usb.h is available and contains the following parameters + * required for a USB device low speed (1.5Mbit/s): + * - \code #define USB_DEVICE_LOW_SPEED + //#define USB_DEVICE_HS_SUPPORT \endcode + * -# Ensure that conf_usb.h contains the following parameters + * required for a USB device full speed (12Mbit/s): + * - \code //#define USB_DEVICE_LOW_SPEED + //#define USB_DEVICE_HS_SUPPORT \endcode + * -# Ensure that conf_usb.h contains the following parameters + * required for a USB device high speed (480Mbit/s): + * - \code //#define USB_DEVICE_LOW_SPEED + #define USB_DEVICE_HS_SUPPORT \endcode + */ + +/** + * \page udc_use_case_2 Use USB strings + * + * In this use case, the usual USB strings is added in the USB device. + * + * \section udc_use_case_2_setup Setup steps + * Prior to implement this use case, be sure to have already + * apply the UDI module "basic use case". + * + * \section udc_use_case_2_usage Usage steps + * + * \subsection udc_use_case_2_usage_code Example code + * Content of conf_usb.h: + * \code + #define USB_DEVICE_MANUFACTURE_NAME "Manufacture name" + #define USB_DEVICE_PRODUCT_NAME "Product name" + #define USB_DEVICE_SERIAL_NAME "12...EF" +\endcode + * + * \subsection udc_use_case_2_usage_flow Workflow + * -# Ensure that conf_usb.h is available and contains the following parameters + * required to enable different USB strings: + * - \code // Static ASCII name for the manufacture + #define USB_DEVICE_MANUFACTURE_NAME "Manufacture name" \endcode + * - \code // Static ASCII name for the product + #define USB_DEVICE_PRODUCT_NAME "Product name" \endcode + * - \code // Static ASCII name to enable and set a serial number + #define USB_DEVICE_SERIAL_NAME "12...EF" \endcode + */ + +/** + * \page udc_use_case_3 Use USB remote wakeup feature + * + * In this use case, the USB remote wakeup feature is enabled. + * + * \section udc_use_case_3_setup Setup steps + * Prior to implement this use case, be sure to have already + * apply the UDI module "basic use case". + * + * \section udc_use_case_3_usage Usage steps + * + * \subsection udc_use_case_3_usage_code Example code + * Content of conf_usb.h: + * \code + #define USB_DEVICE_ATTR \ + (USB_CONFIG_ATTR_REMOTE_WAKEUP | USB_CONFIG_ATTR_..._POWERED) + #define UDC_REMOTEWAKEUP_ENABLE() my_callback_remotewakeup_enable() + extern void my_callback_remotewakeup_enable(void); + #define UDC_REMOTEWAKEUP_DISABLE() my_callback_remotewakeup_disable() + extern void my_callback_remotewakeup_disable(void); +\endcode + * + * Add to application C-file: + * \code + void my_callback_remotewakeup_enable(void) + { + // Enable application wakeup events (e.g. enable GPIO interrupt) + } + void my_callback_remotewakeup_disable(void) + { + // Disable application wakeup events (e.g. disable GPIO interrupt) + } + + void my_interrupt_event(void) + { + udc_remotewakeup(); + } +\endcode + * + * \subsection udc_use_case_3_usage_flow Workflow + * -# Ensure that conf_usb.h is available and contains the following parameters + * required to enable remote wakeup feature: + * - \code // Authorizes the remote wakeup feature + #define USB_DEVICE_ATTR (USB_CONFIG_ATTR_REMOTE_WAKEUP | USB_CONFIG_ATTR_..._POWERED) \endcode + * - \code // Define callback called when the host enables the remotewakeup feature + #define UDC_REMOTEWAKEUP_ENABLE() my_callback_remotewakeup_enable() + extern void my_callback_remotewakeup_enable(void); \endcode + * - \code // Define callback called when the host disables the remotewakeup feature + #define UDC_REMOTEWAKEUP_DISABLE() my_callback_remotewakeup_disable() + extern void my_callback_remotewakeup_disable(void); \endcode + * -# Send a remote wakeup (USB upstream): + * - \code udc_remotewakeup(); \endcode + */ + +/** + * \page udc_use_case_5 Bus power application recommendations + * + * In this use case, the USB device BUS power feature is enabled. + * This feature requires a correct power consumption management. + * + * \section udc_use_case_5_setup Setup steps + * Prior to implement this use case, be sure to have already + * apply the UDI module "basic use case". + * + * \section udc_use_case_5_usage Usage steps + * + * \subsection udc_use_case_5_usage_code Example code + * Content of conf_usb.h: + * \code + #define USB_DEVICE_ATTR (USB_CONFIG_ATTR_BUS_POWERED) + #define UDC_SUSPEND_EVENT() user_callback_suspend_action() + extern void user_callback_suspend_action(void) + #define UDC_RESUME_EVENT() user_callback_resume_action() + extern void user_callback_resume_action(void) +\endcode + * + * Add to application C-file: + * \code + void user_callback_suspend_action(void) + { + // Disable hardware component to reduce power consumption + } + void user_callback_resume_action(void) + { + // Re-enable hardware component + } +\endcode + * + * \subsection udc_use_case_5_usage_flow Workflow + * -# Ensure that conf_usb.h is available and contains the following parameters: + * - \code // Authorizes the BUS power feature + #define USB_DEVICE_ATTR (USB_CONFIG_ATTR_BUS_POWERED) \endcode + * - \code // Define callback called when the host suspend the USB line + #define UDC_SUSPEND_EVENT() user_callback_suspend_action() + extern void user_callback_suspend_action(void); \endcode + * - \code // Define callback called when the host or device resume the USB line + #define UDC_RESUME_EVENT() user_callback_resume_action() + extern void user_callback_resume_action(void); \endcode + * -# Reduce power consumption in suspend mode (max. 2.5mA on Vbus): + * - \code void user_callback_suspend_action(void) + { + turn_off_components(); + } \endcode + */ + +/** + * \page udc_use_case_6 USB dynamic serial number + * + * In this use case, the USB serial strings is dynamic. + * For a static serial string refer to \ref udc_use_case_2. + * + * \section udc_use_case_6_setup Setup steps + * Prior to implement this use case, be sure to have already + * apply the UDI module "basic use case". + * + * \section udc_use_case_6_usage Usage steps + * + * \subsection udc_use_case_6_usage_code Example code + * Content of conf_usb.h: + * \code + #define USB_DEVICE_SERIAL_NAME + #define USB_DEVICE_GET_SERIAL_NAME_POINTER serial_number + #define USB_DEVICE_GET_SERIAL_NAME_LENGTH 12 + extern uint8_t serial_number[]; +\endcode + * + * Add to application C-file: + * \code + uint8_t serial_number[USB_DEVICE_GET_SERIAL_NAME_LENGTH]; + + void init_build_usb_serial_number(void) + { + serial_number[0] = 'A'; + serial_number[1] = 'B'; + ... + serial_number[USB_DEVICE_GET_SERIAL_NAME_LENGTH-1] = 'C'; + } \endcode + * + * \subsection udc_use_case_6_usage_flow Workflow + * -# Ensure that conf_usb.h is available and contains the following parameters + * required to enable a USB serial number strings dynamically: + * - \code #define USB_DEVICE_SERIAL_NAME // Define this empty + #define USB_DEVICE_GET_SERIAL_NAME_POINTER serial_number // Give serial array pointer + #define USB_DEVICE_GET_SERIAL_NAME_LENGTH 12 // Give size of serial array + extern uint8_t serial_number[]; // Declare external serial array \endcode + * -# Before start USB stack, initialize the serial array + * - \code + uint8_t serial_number[USB_DEVICE_GET_SERIAL_NAME_LENGTH]; + + void init_build_usb_serial_number(void) + { + serial_number[0] = 'A'; + serial_number[1] = 'B'; + ... + serial_number[USB_DEVICE_GET_SERIAL_NAME_LENGTH-1] = 'C'; + } \endcode + */ + + + +#endif // _UDC_H_ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/udc/udc_desc.h b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/udc/udc_desc.h new file mode 100644 index 0000000..6e403c6 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/udc/udc_desc.h @@ -0,0 +1,132 @@ +/** + * \file + * + * \brief Common API for USB Device Interface + * + * Copyright (c) 2009-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _UDC_DESC_H_ +#define _UDC_DESC_H_ + +#include "conf_usb.h" +#include "usb_protocol.h" +#include "udi.h" + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \ingroup udc_group + * \defgroup udc_desc_group USB Device Descriptor + * + * @{ + */ + +/** + * \brief Defines the memory's location of USB descriptors + * + * By default the Descriptor is stored in RAM + * (UDC_DESC_STORAGE is defined empty). + * + * If you have need to free RAM space, + * it is possible to put descriptor in flash in following case: + * - USB driver authorize flash transfer (USBB on UC3 and USB on Mega) + * - USB Device is not high speed (UDC no need to change USB descriptors) + * + * For UC3 application used "const". + * + * For Mega application used "code". + */ +#define UDC_DESC_STORAGE + // Descriptor storage in internal RAM +#if (defined UDC_DATA_USE_HRAM_SUPPORT) +# if defined(__GNUC__) +# define UDC_DATA(x) COMPILER_WORD_ALIGNED __attribute__((__section__(".data_hram0"))) +# define UDC_BSS(x) COMPILER_ALIGNED(x) __attribute__((__section__(".bss_hram0"))) +# elif defined(__ICCAVR32__) +# define UDC_DATA(x) COMPILER_ALIGNED(x) __data32 +# define UDC_BSS(x) COMPILER_ALIGNED(x) __data32 +# endif +#else +# define UDC_DATA(x) COMPILER_ALIGNED(x) +# define UDC_BSS(x) COMPILER_ALIGNED(x) +#endif + + + +/** + * \brief Configuration descriptor and UDI link for one USB speed + */ +typedef struct { + //! USB configuration descriptor + usb_conf_desc_t UDC_DESC_STORAGE *desc; + //! Array of UDI API pointer + udi_api_t UDC_DESC_STORAGE *UDC_DESC_STORAGE * udi_apis; +} udc_config_speed_t; + + +/** + * \brief All information about the USB Device + */ +typedef struct { + //! USB device descriptor for low or full speed + usb_dev_desc_t UDC_DESC_STORAGE *confdev_lsfs; + //! USB configuration descriptor and UDI API pointers for low or full speed + udc_config_speed_t UDC_DESC_STORAGE *conf_lsfs; +#ifdef USB_DEVICE_HS_SUPPORT + //! USB device descriptor for high speed + usb_dev_desc_t UDC_DESC_STORAGE *confdev_hs; + //! USB device qualifier, only use in high speed mode + usb_dev_qual_desc_t UDC_DESC_STORAGE *qualifier; + //! USB configuration descriptor and UDI API pointers for high speed + udc_config_speed_t UDC_DESC_STORAGE *conf_hs; +#endif + usb_dev_bos_desc_t UDC_DESC_STORAGE *conf_bos; +} udc_config_t; + +//! Global variables of USB Device Descriptor and UDI links +extern UDC_DESC_STORAGE udc_config_t udc_config; + +//@} + +#ifdef __cplusplus +} +#endif +#endif // _UDC_DESC_H_ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/udc/udd.h b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/udc/udd.h new file mode 100644 index 0000000..8155846 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/udc/udd.h @@ -0,0 +1,393 @@ +/** + * \file + * + * \brief Common API for USB Device Drivers (UDD) + * + * Copyright (c) 2009 - 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _UDD_H_ +#define _UDD_H_ + +#include "usb_protocol.h" +#include "udc_desc.h" + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \ingroup usb_device_group + * \defgroup udd_group USB Device Driver (UDD) + * + * The UDD driver provides a low-level abstraction of the device + * controller hardware. Most events coming from the hardware such as + * interrupts, which may cause the UDD to call into the UDC and UDI. + * + * @{ + */ + +//! \brief Endpoint identifier +typedef uint8_t udd_ep_id_t; + +//! \brief Endpoint transfer status +//! Returned in parameters of callback register via udd_ep_run routine. +typedef enum { + UDD_EP_TRANSFER_OK = 0, + UDD_EP_TRANSFER_ABORT = 1, +} udd_ep_status_t; + +/** + * \brief Global variable to give and record information of the setup request management + * + * This global variable allows to decode and response a setup request. + * It can be updated by udc_process_setup() from UDC or *setup() from UDIs. + */ +typedef struct { + //! Data received in USB SETUP packet + //! Note: The swap of "req.wValues" from uin16_t to le16_t is done by UDD. + usb_setup_req_t req; + + //! Point to buffer to send or fill with data following SETUP packet + //! This buffer must be word align for DATA IN phase (use prefix COMPILER_WORD_ALIGNED for buffer) + uint8_t *payload; + + //! Size of buffer to send or fill, and content the number of byte transfered + uint16_t payload_size; + + //! Callback called after reception of ZLP from setup request + void (*callback) (void); + + //! Callback called when the buffer given (.payload) is full or empty. + //! This one return false to abort data transfer, or true with a new buffer in .payload. + bool(*over_under_run) (void); +} udd_ctrl_request_t; +extern udd_ctrl_request_t udd_g_ctrlreq; + +//! Return true if the setup request \a udd_g_ctrlreq indicates IN data transfer +#define Udd_setup_is_in() \ + (USB_REQ_DIR_IN == (udd_g_ctrlreq.req.bmRequestType & USB_REQ_DIR_MASK)) + +//! Return true if the setup request \a udd_g_ctrlreq indicates OUT data transfer +#define Udd_setup_is_out() \ + (USB_REQ_DIR_OUT == (udd_g_ctrlreq.req.bmRequestType & USB_REQ_DIR_MASK)) + +//! Return the type of the SETUP request \a udd_g_ctrlreq. \see usb_reqtype. +#define Udd_setup_type() \ + (udd_g_ctrlreq.req.bmRequestType & USB_REQ_TYPE_MASK) + +//! Return the recipient of the SETUP request \a udd_g_ctrlreq. \see usb_recipient +#define Udd_setup_recipient() \ + (udd_g_ctrlreq.req.bmRequestType & USB_REQ_RECIP_MASK) + +/** + * \brief End of halt callback function type. + * Registered by routine udd_ep_wait_stall_clear() + * Callback called when endpoint stall is cleared. + */ +typedef void (*udd_callback_halt_cleared_t) (void); + +/** + * \brief End of transfer callback function type. + * Registered by routine udd_ep_run() + * Callback called by USB interrupt after data transfer or abort (reset,...). + * + * \param status UDD_EP_TRANSFER_OK, if transfer is complete + * \param status UDD_EP_TRANSFER_ABORT, if transfer is aborted + * \param n number of data transfered + */ +typedef void (*udd_callback_trans_t) (udd_ep_status_t status, + iram_size_t nb_transfered, udd_ep_id_t ep); + +/** + * \brief Authorizes the VBUS event + * + * \return true, if the VBUS monitoring is possible. + */ +bool udd_include_vbus_monitoring(void); + +/** + * \brief Enables the USB Device mode + */ +void udd_enable(void); + +/** + * \brief Disables the USB Device mode + */ +void udd_disable(void); + +/** + * \brief Attach device to the bus when possible + * + * \warning If a VBus control is included in driver, + * then it will attach device when an acceptable Vbus + * level from the host is detected. + */ +void udd_attach(void); + +/** + * \brief Detaches the device from the bus + * + * The driver must remove pull-up on USB line D- or D+. + */ +void udd_detach(void); + +/** + * \brief Test whether the USB Device Controller is running at high + * speed or not. + * + * \return \c true if the Device is running at high speed mode, otherwise \c false. + */ +bool udd_is_high_speed(void); + +/** + * \brief Changes the USB address of device + * + * \param address New USB address + */ +void udd_set_address(uint8_t address); + +/** + * \brief Returns the USB address of device + * + * \return USB address + */ +uint8_t udd_getaddress(void); + +/** + * \brief Returns the current start of frame number + * + * \return current start of frame number. + */ +uint16_t udd_get_frame_number(void); + +/** + * \brief Returns the current micro start of frame number + * + * \return current micro start of frame number required in high speed mode. + */ +uint16_t udd_get_micro_frame_number(void); + +/*! \brief The USB driver sends a resume signal called Upstream Resume + */ +void udd_send_remotewakeup(void); + +/** + * \brief Load setup payload + * + * \param payload Pointer on payload + * \param payload_size Size of payload + */ +void udd_set_setup_payload( uint8_t *payload, uint16_t payload_size ); + + +/** + * \name Endpoint Management + * + * The following functions allow drivers to create and remove + * endpoints, as well as set, clear and query their "halted" and + * "wedged" states. + */ +//@{ + +#if (USB_DEVICE_MAX_EP != 0) + +/** + * \brief Configures and enables an endpoint + * + * \param ep Endpoint number including direction (USB_EP_DIR_IN/USB_EP_DIR_OUT). + * \param bmAttributes Attributes of endpoint declared in the descriptor. + * \param MaxEndpointSize Endpoint maximum size + * + * \return \c 1 if the endpoint is enabled, otherwise \c 0. + */ +bool udd_ep_alloc(udd_ep_id_t ep, uint8_t bmAttributes, + uint16_t MaxEndpointSize); + +/** + * \brief Disables an endpoint + * + * \param ep Endpoint number including direction (USB_EP_DIR_IN/USB_EP_DIR_OUT). + */ +void udd_ep_free(udd_ep_id_t ep); + +/** + * \brief Check if the endpoint \a ep is halted. + * + * \param ep The ID of the endpoint to check. + * + * \return \c 1 if \a ep is halted, otherwise \c 0. + */ +bool udd_ep_is_halted(udd_ep_id_t ep); + +/** + * \brief Set the halted state of the endpoint \a ep + * + * After calling this function, any transaction on \a ep will result + * in a STALL handshake being sent. Any pending transactions will be + * performed first, however. + * + * \param ep The ID of the endpoint to be halted + * + * \return \c 1 if \a ep is halted, otherwise \c 0. + */ +bool udd_ep_set_halt(udd_ep_id_t ep); + +/** + * \brief Clear the halted state of the endpoint \a ep + * + * After calling this function, any transaction on \a ep will + * be handled normally, i.e. a STALL handshake will not be sent, and + * the data toggle sequence will start at DATA0. + * + * \param ep The ID of the endpoint to be un-halted + * + * \return \c 1 if function was successfully done, otherwise \c 0. + */ +bool udd_ep_clear_halt(udd_ep_id_t ep); + +/** + * \brief Registers a callback to call when endpoint halt is cleared + * + * \param ep The ID of the endpoint to use + * \param callback NULL or function to call when endpoint halt is cleared + * + * \warning if the endpoint is not halted then the \a callback is called immediately. + * + * \return \c 1 if the register is accepted, otherwise \c 0. + */ +bool udd_ep_wait_stall_clear(udd_ep_id_t ep, + udd_callback_halt_cleared_t callback); + +/** + * \brief Allows to receive or send data on an endpoint + * + * The driver uses a specific DMA USB to transfer data + * from internal RAM to endpoint, if this one is available. + * When the transfer is finished or aborted (stall, reset, ...), the \a callback is called. + * The \a callback returns the transfer status and eventually the number of byte transfered. + * Note: The control endpoint is not authorized. + * + * \param ep The ID of the endpoint to use + * \param b_shortpacket Enabled automatic short packet + * \param buf Buffer on Internal RAM to send or fill. + * It must be align, then use COMPILER_WORD_ALIGNED. + * \param buf_size Buffer size to send or fill + * \param callback NULL or function to call at the end of transfer + * + * \warning About \a b_shortpacket, for IN endpoint it means that a short packet + * (or a Zero Length Packet) will be sent to the USB line to properly close the usb + * transfer at the end of the data transfer. + * For Bulk and Interrupt OUT endpoint, it will automatically stop the transfer + * at the end of the data transfer (received short packet). + * + * \return \c 1 if function was successfully done, otherwise \c 0. + */ +bool udd_ep_run(udd_ep_id_t ep, bool b_shortpacket, + uint8_t * buf, iram_size_t buf_size, + udd_callback_trans_t callback); +/** + * \brief Aborts transfer on going on endpoint + * + * If a transfer is on going, then it is stopped and + * the callback registered is called to signal the end of transfer. + * Note: The control endpoint is not authorized. + * + * \param ep Endpoint to abort + */ +void udd_ep_abort(udd_ep_id_t ep); + +#endif + +//@} + + +/** + * \name High speed test mode management + * + * The following functions allow the device to jump to a specific test mode required in high speed mode. + */ +//@{ +void udd_test_mode_j(void); +void udd_test_mode_k(void); +void udd_test_mode_se0_nak(void); +void udd_test_mode_packet(void); +//@} + + +/** + * \name UDC callbacks to provide for UDD + * + * The following callbacks are used by UDD. + */ +//@{ + +/** + * \brief Decodes and manages a setup request + * + * The driver call it when a SETUP packet is received. + * The \c udd_g_ctrlreq contains the data of SETUP packet. + * If this callback accepts the setup request then it must + * return \c 1 and eventually update \c udd_g_ctrlreq to send or receive data. + * + * \return \c 1 if the request is accepted, otherwise \c 0. + */ +extern bool udc_process_setup(void); + +/** + * \brief Reset the UDC + * + * The UDC must reset all configuration. + */ +extern void udc_reset(void); + +/** + * \brief To signal that a SOF is occurred + * + * The UDC must send the signal to all UDIs enabled + */ +extern void udc_sof_notify(void); + +//@} + +//@} + +#ifdef __cplusplus +} +#endif +#endif // _UDD_H_ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/udc/udi.h b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/udc/udi.h new file mode 100644 index 0000000..2c16444 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/udc/udi.h @@ -0,0 +1,130 @@ +/** + * \file + * + * \brief Common API for USB Device Interface + * + * Copyright (c) 2009 - 2012 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _UDI_H_ +#define _UDI_H_ + +#include "conf_usb.h" +#include "usb_protocol.h" + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \ingroup usb_device_group + * \defgroup udi_group USB Device Interface (UDI) + * The UDI provides a common API for all classes, + * and this is used by UDC for the main control of USB Device interface. + * @{ + */ + +/** + * \brief UDI API. + * + * The callbacks within this structure are called only by + * USB Device Controller (UDC) + * + * The udc_get_interface_desc() can be use by UDI to know the interface descriptor + * selected by UDC. + */ +typedef struct { + /** + * \brief Enable the interface. + * + * This function is called when the host selects a configuration + * to which this interface belongs through a Set Configuration + * request, and when the host selects an alternate setting of + * this interface through a Set Interface request. + * + * \return \c 1 if function was successfully done, otherwise \c 0. + */ + bool(*enable) (void); + + /** + * \brief Disable the interface. + * + * This function is called when this interface is currently + * active, and + * - the host selects any configuration through a Set + * Configuration request, or + * - the host issues a USB reset, or + * - the device is detached from the host (i.e. Vbus is no + * longer present) + */ + void (*disable) (void); + + /** + * \brief Handle a control request directed at an interface. + * + * This function is called when this interface is currently + * active and the host sends a SETUP request + * with this interface as the recipient. + * + * Use udd_g_ctrlreq to decode and response to SETUP request. + * + * \return \c 1 if this interface supports the SETUP request, otherwise \c 0. + */ + bool(*setup) (void); + + /** + * \brief Returns the current setting of the selected interface. + * + * This function is called when UDC when know alternate setting of selected interface. + * + * \return alternate setting of selected interface + */ + uint8_t(*getsetting) (void); + + /** + * \brief To signal that a SOF is occurred + */ + void(*sof_notify) (void); +} udi_api_t; + +//@} + +#ifdef __cplusplus +} +#endif +#endif // _UDI_H_ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/usb_atmel.h b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/usb_atmel.h new file mode 100644 index 0000000..f31a9c7 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/usb_atmel.h @@ -0,0 +1,187 @@ +/** + * \file + * + * \brief All USB VIDs and PIDs from Atmel USB applications + * + * Copyright (c) 2009-2013 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _USB_ATMEL_H_ +#define _USB_ATMEL_H_ + +/** + * \defgroup usb_group USB Stack + * + * This stack includes the USB Device Stack, USB Host Stack and common + * definitions. + * @{ + */ + +//! @} + +/** + * \ingroup usb_group + * \defgroup usb_atmel_ids_group Atmel USB Identifiers + * + * This module defines Atmel PID and VIDs constants. + * + * @{ + */ + +//! \name Vendor Identifier assigned by USB org to ATMEL +#define USB_VID_ATMEL 0x03EB + + +//! \name Product Identifier assigned by ATMEL to AVR applications +//! @{ + +//! \name The range from 2000h to 20FFh is reserved to the old PID for C51, MEGA, and others. +//! @{ +#define USB_PID_ATMEL_MEGA_HIDGENERIC 0x2013 +#define USB_PID_ATMEL_MEGA_HIDKEYBOARD 0x2017 +#define USB_PID_ATMEL_MEGA_CDC 0x2018 +#define USB_PID_ATMEL_MEGA_AUDIO_IN 0x2019 +#define USB_PID_ATMEL_MEGA_MS 0x201A +#define USB_PID_ATMEL_MEGA_AUDIO_IN_OUT 0x201B +#define USB_PID_ATMEL_MEGA_HIDMOUSE 0x201C +#define USB_PID_ATMEL_MEGA_HIDMOUSE_CERTIF_U4 0x201D +#define USB_PID_ATMEL_MEGA_CDC_MULTI 0x201E +#define USB_PID_ATMEL_MEGA_MS_HIDMS_HID_USBKEY 0x2022 +#define USB_PID_ATMEL_MEGA_MS_HIDMS_HID_STK525 0x2023 +#define USB_PID_ATMEL_MEGA_MS_2 0x2029 +#define USB_PID_ATMEL_MEGA_MS_HIDMS 0x202A +#define USB_PID_ATMEL_MEGA_MS_3 0x2032 +#define USB_PID_ATMEL_MEGA_LIBUSB 0x2050 +//! @} + +//! \name The range 2100h to 21FFh is reserved to PIDs for AVR Tools. +//! @{ +#define USB_PID_ATMEL_XPLAINED 0x2122 +#define USB_PID_ATMEL_XMEGA_USB_ZIGBIT_2_4GHZ 0x214A +#define USB_PID_ATMEL_XMEGA_USB_ZIGBIT_SUBGHZ 0x214B +//! @} + +//! \name The range 2300h to 23FFh is reserved to PIDs for demo from ASF1.7=> +//! @{ +#define USB_PID_ATMEL_UC3_ENUM 0x2300 +#define USB_PID_ATMEL_UC3_MS 0x2301 +#define USB_PID_ATMEL_UC3_MS_SDRAM_LOADER 0x2302 +#define USB_PID_ATMEL_UC3_EVK1100_CTRLPANEL 0x2303 +#define USB_PID_ATMEL_UC3_HID 0x2304 +#define USB_PID_ATMEL_UC3_EVK1101_CTRLPANEL_HID 0x2305 +#define USB_PID_ATMEL_UC3_EVK1101_CTRLPANEL_HID_MS 0x2306 +#define USB_PID_ATMEL_UC3_CDC 0x2307 +#define USB_PID_ATMEL_UC3_AUDIO_MICRO 0x2308 +#define USB_PID_ATMEL_UC3_CDC_DEBUG 0x2310 // Virtual Com (debug interface) on EVK11xx +#define USB_PID_ATMEL_UC3_AUDIO_SPEAKER_MICRO 0x2311 +#define USB_PID_ATMEL_UC3_CDC_MSC 0x2312 +//! @} + +//! \name The range 2400h to 24FFh is reserved to PIDs for ASF applications +//! @{ +#define USB_PID_ATMEL_ASF_HIDMOUSE 0x2400 +#define USB_PID_ATMEL_ASF_HIDKEYBOARD 0x2401 +#define USB_PID_ATMEL_ASF_HIDGENERIC 0x2402 +#define USB_PID_ATMEL_ASF_MSC 0x2403 +#define USB_PID_ATMEL_ASF_CDC 0x2404 +#define USB_PID_ATMEL_ASF_PHDC 0x2405 +#define USB_PID_ATMEL_ASF_MSC_HIDMOUSE 0x2420 +#define USB_PID_ATMEL_ASF_MSC_HIDS_CDC 0x2421 +#define USB_PID_ATMEL_ASF_MSC_HIDKEYBOARD 0x2422 +#define USB_PID_ATMEL_ASF_VENDOR_CLASS 0x2423 +#define USB_PID_ATMEL_ASF_MSC_CDC 0x2424 +#define USB_PID_ATMEL_ASF_TWO_CDC 0x2425 +#define USB_PID_ATMEL_ASF_SEVEN_CDC 0x2426 +#define USB_PID_ATMEL_ASF_XPLAIN_BC_POWERONLY 0x2430 +#define USB_PID_ATMEL_ASF_XPLAIN_BC_TERMINAL 0x2431 +#define USB_PID_ATMEL_ASF_XPLAIN_BC_TOUCH 0x2432 +#define USB_PID_ATMEL_ASF_AUDIO_SPEAKER 0x2433 +#define USB_PID_ATMEL_ASF_XMEGA_B1_XPLAINED 0x2434 +//! @} + +//! \name The range 2F00h to 2FFFh is reserved to official PIDs for AVR bootloaders +//! Note, !!!! don't use this range for demos or examples !!!! +//! @{ +#define USB_PID_ATMEL_DFU_ATXMEGA64C3 0x2FD6 +#define USB_PID_ATMEL_DFU_ATXMEGA128C3 0x2FD7 +#define USB_PID_ATMEL_DFU_ATXMEGA16C4 0x2FD8 +#define USB_PID_ATMEL_DFU_ATXMEGA32C4 0x2FD9 +#define USB_PID_ATMEL_DFU_ATXMEGA256C3 0x2FDA +#define USB_PID_ATMEL_DFU_ATXMEGA384C3 0x2FDB +#define USB_PID_ATMEL_DFU_ATUCL3_L4 0x2FDC +#define USB_PID_ATMEL_DFU_ATXMEGA64A4U 0x2FDD +#define USB_PID_ATMEL_DFU_ATXMEGA128A4U 0x2FDE + +#define USB_PID_ATMEL_DFU_ATXMEGA64B3 0x2FDF +#define USB_PID_ATMEL_DFU_ATXMEGA128B3 0x2FE0 +#define USB_PID_ATMEL_DFU_ATXMEGA64B1 0x2FE1 +#define USB_PID_ATMEL_DFU_ATXMEGA256A3BU 0x2FE2 +#define USB_PID_ATMEL_DFU_ATXMEGA16A4U 0x2FE3 +#define USB_PID_ATMEL_DFU_ATXMEGA32A4U 0x2FE4 +#define USB_PID_ATMEL_DFU_ATXMEGA64A3U 0x2FE5 +#define USB_PID_ATMEL_DFU_ATXMEGA128A3U 0x2FE6 +#define USB_PID_ATMEL_DFU_ATXMEGA192A3U 0x2FE7 +#define USB_PID_ATMEL_DFU_ATXMEGA64A1U 0x2FE8 +#define USB_PID_ATMEL_DFU_ATUC3D 0x2FE9 +#define USB_PID_ATMEL_DFU_ATXMEGA128B1 0x2FEA +#define USB_PID_ATMEL_DFU_AT32UC3C 0x2FEB +#define USB_PID_ATMEL_DFU_ATXMEGA256A3U 0x2FEC +#define USB_PID_ATMEL_DFU_ATXMEGA128A1U 0x2FED +#define USB_PID_ATMEL_DFU_ATMEGA8U2 0x2FEE +#define USB_PID_ATMEL_DFU_ATMEGA16U2 0x2FEF +#define USB_PID_ATMEL_DFU_ATMEGA32U2 0x2FF0 +#define USB_PID_ATMEL_DFU_AT32UC3A3 0x2FF1 +#define USB_PID_ATMEL_DFU_ATMEGA32U6 0x2FF2 +#define USB_PID_ATMEL_DFU_ATMEGA16U4 0x2FF3 +#define USB_PID_ATMEL_DFU_ATMEGA32U4 0x2FF4 +#define USB_PID_ATMEL_DFU_AT32AP7200 0x2FF5 +#define USB_PID_ATMEL_DFU_AT32UC3B 0x2FF6 +#define USB_PID_ATMEL_DFU_AT90USB82 0x2FF7 +#define USB_PID_ATMEL_DFU_AT32UC3A 0x2FF8 +#define USB_PID_ATMEL_DFU_AT90USB64 0x2FF9 +#define USB_PID_ATMEL_DFU_AT90USB162 0x2FFA +#define USB_PID_ATMEL_DFU_AT90USB128 0x2FFB +// 2FFCh to 2FFFh used by C51 family products +//! @} + +//! @} + +//! @} + + +#endif // _USB_ATMEL_H_ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/usb_protocol.h b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/usb_protocol.h new file mode 100644 index 0000000..d703337 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/services/usb/usb_protocol.h @@ -0,0 +1,502 @@ +/** + * \file + * + * \brief USB protocol definitions. + * + * This file contains the USB definitions and data structures provided by the + * USB 2.0 specification. + * + * Copyright (c) 2009-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _USB_PROTOCOL_H_ +#define _USB_PROTOCOL_H_ + +#include "usb_atmel.h" + +/** + * \ingroup usb_group + * \defgroup usb_protocol_group USB Protocol Definitions + * + * This module defines constants and data structures provided by the USB + * 2.0 specification. + * + * @{ + */ + +//! Value for field bcdUSB +#define USB_V2_0 0x0200 //!< USB Specification version 2.00 +#define USB_V2_1 0x0201 //!< USB Specification version 2.01 + +/*! \name Generic definitions (Class, subclass and protocol) + */ +//! @{ +#define NO_CLASS 0x00 +#define CLASS_VENDOR_SPECIFIC 0xFF +#define NO_SUBCLASS 0x00 +#define NO_PROTOCOL 0x00 +//! @} + +//! \name IAD (Interface Association Descriptor) constants +//! @{ +#define CLASS_IAD 0xEF +#define SUB_CLASS_IAD 0x02 +#define PROTOCOL_IAD 0x01 +//! @} + +/** + * \brief USB request data transfer direction (bmRequestType) + */ +#define USB_REQ_DIR_OUT (0<<7) //!< Host to device +#define USB_REQ_DIR_IN (1<<7) //!< Device to host +#define USB_REQ_DIR_MASK (1<<7) //!< Mask + +/** + * \brief USB request types (bmRequestType) + */ +#define USB_REQ_TYPE_STANDARD (0<<5) //!< Standard request +#define USB_REQ_TYPE_CLASS (1<<5) //!< Class-specific request +#define USB_REQ_TYPE_VENDOR (2<<5) //!< Vendor-specific request +#define USB_REQ_TYPE_MASK (3<<5) //!< Mask + +/** + * \brief USB recipient codes (bmRequestType) + */ +#define USB_REQ_RECIP_DEVICE (0<<0) //!< Recipient device +#define USB_REQ_RECIP_INTERFACE (1<<0) //!< Recipient interface +#define USB_REQ_RECIP_ENDPOINT (2<<0) //!< Recipient endpoint +#define USB_REQ_RECIP_OTHER (3<<0) //!< Recipient other +#define USB_REQ_RECIP_MASK (0x1F) //!< Mask + +/** + * \brief Standard USB requests (bRequest) + */ +enum usb_reqid { + USB_REQ_GET_STATUS = 0, + USB_REQ_CLEAR_FEATURE = 1, + USB_REQ_SET_FEATURE = 3, + USB_REQ_SET_ADDRESS = 5, + USB_REQ_GET_DESCRIPTOR = 6, + USB_REQ_SET_DESCRIPTOR = 7, + USB_REQ_GET_CONFIGURATION = 8, + USB_REQ_SET_CONFIGURATION = 9, + USB_REQ_GET_INTERFACE = 10, + USB_REQ_SET_INTERFACE = 11, + USB_REQ_SYNCH_FRAME = 12, +}; + +/** + * \brief Standard USB device status flags + * + */ +enum usb_device_status { + USB_DEV_STATUS_BUS_POWERED = 0, + USB_DEV_STATUS_SELF_POWERED = 1, + USB_DEV_STATUS_REMOTEWAKEUP = 2 +}; + +/** + * \brief Standard USB Interface status flags + * + */ +enum usb_interface_status { + USB_IFACE_STATUS_RESERVED = 0 +}; + +/** + * \brief Standard USB endpoint status flags + * + */ +enum usb_endpoint_status { + USB_EP_STATUS_HALTED = 1, +}; + +/** + * \brief Standard USB device feature flags + * + * \note valid for SetFeature request. + */ +enum usb_device_feature { + USB_DEV_FEATURE_REMOTE_WAKEUP = 1, //!< Remote wakeup enabled + USB_DEV_FEATURE_TEST_MODE = 2, //!< USB test mode + USB_DEV_FEATURE_OTG_B_HNP_ENABLE = 3, + USB_DEV_FEATURE_OTG_A_HNP_SUPPORT = 4, + USB_DEV_FEATURE_OTG_A_ALT_HNP_SUPPORT = 5 +}; + +/** + * \brief Test Mode possible on HS USB device + * + * \note valid for USB_DEV_FEATURE_TEST_MODE request. + */ +enum usb_device_hs_test_mode { + USB_DEV_TEST_MODE_J = 1, + USB_DEV_TEST_MODE_K = 2, + USB_DEV_TEST_MODE_SE0_NAK = 3, + USB_DEV_TEST_MODE_PACKET = 4, + USB_DEV_TEST_MODE_FORCE_ENABLE = 5, +}; + +/** + * \brief Standard USB endpoint feature/status flags + */ +enum usb_endpoint_feature { + USB_EP_FEATURE_HALT = 0, +}; + +/** + * \brief Standard USB Test Mode Selectors + */ +enum usb_test_mode_selector { + USB_TEST_J = 0x01, + USB_TEST_K = 0x02, + USB_TEST_SE0_NAK = 0x03, + USB_TEST_PACKET = 0x04, + USB_TEST_FORCE_ENABLE = 0x05, +}; + +/** + * \brief Standard USB descriptor types + */ +enum usb_descriptor_type { + USB_DT_DEVICE = 1, + USB_DT_CONFIGURATION = 2, + USB_DT_STRING = 3, + USB_DT_INTERFACE = 4, + USB_DT_ENDPOINT = 5, + USB_DT_DEVICE_QUALIFIER = 6, + USB_DT_OTHER_SPEED_CONFIGURATION = 7, + USB_DT_INTERFACE_POWER = 8, + USB_DT_OTG = 9, + USB_DT_IAD = 0x0B, + USB_DT_BOS = 0x0F, + USB_DT_DEVICE_CAPABILITY = 0x10, +}; + +/** + * \brief USB Device Capability types + */ +enum usb_capability_type { + USB_DC_USB20_EXTENSION = 0x02, +}; + +/** + * \brief USB Device Capability - USB 2.0 Extension + * To fill bmAttributes field of usb_capa_ext_desc_t structure. + */ +enum usb_capability_extension_attr { + USB_DC_EXT_LPM = 0x00000002, + USB_DC_EXT_BESL = 0x00000004, + USB_DC_EXT_BESL_BASELINE_VALID = 0x00000008, + USB_DC_EXT_BESL_DEEP_VALID = 0x00000010, +}; +#define USB_DC_EXT_BESL_DEEP_OFFSET 8 +#define USB_DC_EXT_BESL_DEEP(besl) ((besl & 0xF) << USB_DC_EXT_BESL_DEEP_OFFSET) +#define USB_DC_EXT_BESL_BASELINE_OFFSET 12 +#define USB_DC_EXT_BESL_BASELINE(besl) ((besl & 0xF) << USB_DC_EXT_BESL_BASELINE_OFFSET) + +#define BESL_125_US 0 +#define BESL_150_US 1 +#define BESL_200_US 2 +#define BESL_300_US 3 +#define BESL_400_US 4 +#define BESL_500_US 5 +#define BESL_1000_US 6 +#define BESL_2000_US 7 +#define BESL_3000_US 8 +#define BESL_4000_US 9 +#define BESL_5000_US 10 +#define BESL_6000_US 11 +#define BESL_7000_US 12 +#define BESL_8000_US 13 +#define BESL_9000_US 14 +#define BESL_10000_US 15 + +/** Fields definition from a LPM TOKEN */ +#define USB_LPM_ATTRIBUT_BLINKSTATE_MASK (0xF << 0) +#define USB_LPM_ATTRIBUT_BESL_MASK (0xF << 4) +#define USB_LPM_ATTRIBUT_REMOTEWAKE_MASK (1 << 8) +#define USB_LPM_ATTRIBUT_BLINKSTATE(value) ((value & 0xF) << 0) +#define USB_LPM_ATTRIBUT_BESL(value) ((value & 0xF) << 4) +#define USB_LPM_ATTRIBUT_REMOTEWAKE(value) ((value & 1) << 8) +#define USB_LPM_ATTRIBUT_BLINKSTATE_L1 USB_LPM_ATTRIBUT_BLINKSTATE(1) + +/** + * \brief Standard USB endpoint transfer types + */ +enum usb_ep_type { + USB_EP_TYPE_CONTROL = 0x00, + USB_EP_TYPE_ISOCHRONOUS = 0x01, + USB_EP_TYPE_BULK = 0x02, + USB_EP_TYPE_INTERRUPT = 0x03, + USB_EP_TYPE_MASK = 0x03, +}; + +/** + * \brief Standard USB language IDs for string descriptors + */ +enum usb_langid { + USB_LANGID_EN_US = 0x0409, //!< English (United States) +}; + +/** + * \brief Mask selecting the index part of an endpoint address + */ +#define USB_EP_ADDR_MASK 0x0f + +//! \brief USB address identifier +typedef uint8_t usb_add_t; + +/** + * \brief Endpoint transfer direction is IN + */ +#define USB_EP_DIR_IN 0x80 + +/** + * \brief Endpoint transfer direction is OUT + */ +#define USB_EP_DIR_OUT 0x00 + +//! \brief Endpoint identifier +typedef uint8_t usb_ep_t; + +/** + * \brief Maximum length in bytes of a USB descriptor + * + * The maximum length of a USB descriptor is limited by the 8-bit + * bLength field. + */ +#define USB_MAX_DESC_LEN 255 + +/* + * 2-byte alignment requested for all USB structures. + */ +COMPILER_PACK_SET(1) + +/** + * \brief A USB Device SETUP request + * + * The data payload of SETUP packets always follows this structure. + */ +typedef struct { + uint8_t bmRequestType; + uint8_t bRequest; + le16_t wValue; + le16_t wIndex; + le16_t wLength; +} usb_setup_req_t; + +/** + * \brief Standard USB device descriptor structure + */ +typedef struct { + uint8_t bLength; + uint8_t bDescriptorType; + le16_t bcdUSB; + uint8_t bDeviceClass; + uint8_t bDeviceSubClass; + uint8_t bDeviceProtocol; + uint8_t bMaxPacketSize0; + le16_t idVendor; + le16_t idProduct; + le16_t bcdDevice; + uint8_t iManufacturer; + uint8_t iProduct; + uint8_t iSerialNumber; + uint8_t bNumConfigurations; +} usb_dev_desc_t; + +/** + * \brief Standard USB device qualifier descriptor structure + * + * This descriptor contains information about the device when running at + * the "other" speed (i.e. if the device is currently operating at high + * speed, this descriptor can be used to determine what would change if + * the device was operating at full speed.) + */ +typedef struct { + uint8_t bLength; + uint8_t bDescriptorType; + le16_t bcdUSB; + uint8_t bDeviceClass; + uint8_t bDeviceSubClass; + uint8_t bDeviceProtocol; + uint8_t bMaxPacketSize0; + uint8_t bNumConfigurations; + uint8_t bReserved; +} usb_dev_qual_desc_t; + +/** + * \brief USB Device BOS descriptor structure + * + * The BOS descriptor (Binary device Object Store) defines a root + * descriptor that is similar to the configuration descriptor, and is + * the base descriptor for accessing a family of related descriptors. + * A host can read a BOS descriptor and learn from the wTotalLength field + * the entire size of the device-level descriptor set, or it can read in + * the entire BOS descriptor set of device capabilities. + * The host accesses this descriptor using the GetDescriptor() request. + * The descriptor type in the GetDescriptor() request is set to BOS. + */ +typedef struct { + uint8_t bLength; + uint8_t bDescriptorType; + le16_t wTotalLength; + uint8_t bNumDeviceCaps; +} usb_dev_bos_desc_t; + + +/** + * \brief USB Device Capabilities - USB 2.0 Extension Descriptor structure + * + * Defines the set of USB 1.1-specific device level capabilities. + */ +typedef struct { + uint8_t bLength; + uint8_t bDescriptorType; + uint8_t bDevCapabilityType; + le32_t bmAttributes; +} usb_dev_capa_ext_desc_t; + +/** + * \brief USB Device LPM Descriptor structure + * + * The BOS descriptor and capabilities descriptors for LPM. + */ +typedef struct { + usb_dev_bos_desc_t bos; + usb_dev_capa_ext_desc_t capa_ext; +} usb_dev_lpm_desc_t; + +/** + * \brief Standard USB Interface Association Descriptor structure + */ +typedef struct { + uint8_t bLength; //!< size of this descriptor in bytes + uint8_t bDescriptorType; //!< INTERFACE descriptor type + uint8_t bFirstInterface; //!< Number of interface + uint8_t bInterfaceCount; //!< value to select alternate setting + uint8_t bFunctionClass; //!< Class code assigned by the USB + uint8_t bFunctionSubClass;//!< Sub-class code assigned by the USB + uint8_t bFunctionProtocol;//!< Protocol code assigned by the USB + uint8_t iFunction; //!< Index of string descriptor +} usb_association_desc_t; + + +/** + * \brief Standard USB configuration descriptor structure + */ +typedef struct { + uint8_t bLength; + uint8_t bDescriptorType; + le16_t wTotalLength; + uint8_t bNumInterfaces; + uint8_t bConfigurationValue; + uint8_t iConfiguration; + uint8_t bmAttributes; + uint8_t bMaxPower; +} usb_conf_desc_t; + + +#define USB_CONFIG_ATTR_MUST_SET (1 << 7) //!< Must always be set +#define USB_CONFIG_ATTR_BUS_POWERED (0 << 6) //!< Bus-powered +#define USB_CONFIG_ATTR_SELF_POWERED (1 << 6) //!< Self-powered +#define USB_CONFIG_ATTR_REMOTE_WAKEUP (1 << 5) //!< remote wakeup supported + +#define USB_CONFIG_MAX_POWER(ma) (((ma) + 1) / 2) //!< Max power in mA + +/** + * \brief Standard USB association descriptor structure + */ +typedef struct { + uint8_t bLength; //!< Size of this descriptor in bytes + uint8_t bDescriptorType; //!< Interface descriptor type + uint8_t bFirstInterface; //!< Number of interface + uint8_t bInterfaceCount; //!< value to select alternate setting + uint8_t bFunctionClass; //!< Class code assigned by the USB + uint8_t bFunctionSubClass; //!< Sub-class code assigned by the USB + uint8_t bFunctionProtocol; //!< Protocol code assigned by the USB + uint8_t iFunction; //!< Index of string descriptor +} usb_iad_desc_t; + +/** + * \brief Standard USB interface descriptor structure + */ +typedef struct { + uint8_t bLength; + uint8_t bDescriptorType; + uint8_t bInterfaceNumber; + uint8_t bAlternateSetting; + uint8_t bNumEndpoints; + uint8_t bInterfaceClass; + uint8_t bInterfaceSubClass; + uint8_t bInterfaceProtocol; + uint8_t iInterface; +} usb_iface_desc_t; + +/** + * \brief Standard USB endpoint descriptor structure + */ +typedef struct { + uint8_t bLength; + uint8_t bDescriptorType; + uint8_t bEndpointAddress; + uint8_t bmAttributes; + le16_t wMaxPacketSize; + uint8_t bInterval; +} usb_ep_desc_t; + + +/** + * \brief A standard USB string descriptor structure + */ +typedef struct { + uint8_t bLength; + uint8_t bDescriptorType; +} usb_str_desc_t; + +typedef struct { + usb_str_desc_t desc; + le16_t string[1]; +} usb_str_lgid_desc_t; + +COMPILER_PACK_RESET() + +//! @} + +#endif /* _USB_PROTOCOL_H_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/utils/interrupt.h b/bootloaders/mzero/Bootloader_D21/src/ASF/common/utils/interrupt.h new file mode 100644 index 0000000..33ae884 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/utils/interrupt.h @@ -0,0 +1,139 @@ +/** + * \file + * + * \brief Global interrupt management for 8- and 32-bit AVR + * + * Copyright (c) 2010-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef UTILS_INTERRUPT_H +#define UTILS_INTERRUPT_H + +#include + +#if XMEGA || MEGA || TINY +# include "interrupt/interrupt_avr8.h" +#elif UC3 +# include "interrupt/interrupt_avr32.h" +#elif SAM +# include "interrupt/interrupt_sam_nvic.h" +#else +# error Unsupported device. +#endif + +/** + * \defgroup interrupt_group Global interrupt management + * + * This is a driver for global enabling and disabling of interrupts. + * + * @{ + */ + +#if defined(__DOXYGEN__) +/** + * \def CONFIG_INTERRUPT_FORCE_INTC + * \brief Force usage of the ASF INTC driver + * + * Predefine this symbol when preprocessing to force the use of the ASF INTC driver. + * This is useful to ensure compatibility across compilers and shall be used only when required + * by the application needs. + */ +# define CONFIG_INTERRUPT_FORCE_INTC +#endif + +//! \name Global interrupt flags +//@{ +/** + * \typedef irqflags_t + * \brief Type used for holding state of interrupt flag + */ + +/** + * \def cpu_irq_enable + * \brief Enable interrupts globally + */ + +/** + * \def cpu_irq_disable + * \brief Disable interrupts globally + */ + +/** + * \fn irqflags_t cpu_irq_save(void) + * \brief Get and clear the global interrupt flags + * + * Use in conjunction with \ref cpu_irq_restore. + * + * \return Current state of interrupt flags. + * + * \note This function leaves interrupts disabled. + */ + +/** + * \fn void cpu_irq_restore(irqflags_t flags) + * \brief Restore global interrupt flags + * + * Use in conjunction with \ref cpu_irq_save. + * + * \param flags State to set interrupt flag to. + */ + +/** + * \fn bool cpu_irq_is_enabled_flags(irqflags_t flags) + * \brief Check if interrupts are globally enabled in supplied flags + * + * \param flags Currents state of interrupt flags. + * + * \return True if interrupts are enabled. + */ + +/** + * \def cpu_irq_is_enabled + * \brief Check if interrupts are globally enabled + * + * \return True if interrupts are enabled. + */ +//@} + +//! @} + +/** + * \ingroup interrupt_group + * \defgroup interrupt_deprecated_group Deprecated interrupt definitions + */ + +#endif /* UTILS_INTERRUPT_H */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/utils/interrupt/interrupt_sam_nvic.c b/bootloaders/mzero/Bootloader_D21/src/ASF/common/utils/interrupt/interrupt_sam_nvic.c new file mode 100644 index 0000000..37dd083 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/utils/interrupt/interrupt_sam_nvic.c @@ -0,0 +1,83 @@ +/** + * \file + * + * \brief Global interrupt management for SAM D20, SAM3 and SAM4 (NVIC based) + * + * Copyright (c) 2012-2013 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include "interrupt_sam_nvic.h" + +#if !defined(__DOXYGEN__) +/* Deprecated - global flag to determine the global interrupt state. Required by + * QTouch library, however new applications should use cpu_irq_is_enabled() + * which probes the true global interrupt state from the CPU special registers. + */ +volatile bool g_interrupt_enabled = true; +#endif + +void cpu_irq_enter_critical(void) +{ + if (cpu_irq_critical_section_counter == 0) { + if (cpu_irq_is_enabled()) { + cpu_irq_disable(); + cpu_irq_prev_interrupt_state = true; + } else { + /* Make sure the to save the prev state as false */ + cpu_irq_prev_interrupt_state = false; + } + + } + + cpu_irq_critical_section_counter++; +} + +void cpu_irq_leave_critical(void) +{ + /* Check if the user is trying to leave a critical section when not in a critical section */ + Assert(cpu_irq_critical_section_counter > 0); + + cpu_irq_critical_section_counter--; + + /* Only enable global interrupts when the counter reaches 0 and the state of the global interrupt flag + was enabled when entering critical state */ + if ((cpu_irq_critical_section_counter == 0) && (cpu_irq_prev_interrupt_state)) { + cpu_irq_enable(); + } +} + diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/utils/interrupt/interrupt_sam_nvic.h b/bootloaders/mzero/Bootloader_D21/src/ASF/common/utils/interrupt/interrupt_sam_nvic.h new file mode 100644 index 0000000..ed5ed8b --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/utils/interrupt/interrupt_sam_nvic.h @@ -0,0 +1,186 @@ +/** + * \file + * + * \brief Global interrupt management for SAM D20, SAM3 and SAM4 (NVIC based) + * + * Copyright (c) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef UTILS_INTERRUPT_INTERRUPT_H +#define UTILS_INTERRUPT_INTERRUPT_H + +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \weakgroup interrupt_group + * + * @{ + */ + +/** + * \name Interrupt Service Routine definition + * + * @{ + */ + +/** + * \brief Define service routine + * + * \note For NVIC devices the interrupt service routines are predefined to + * add to vector table in binary generation, so there is no service + * register at run time. The routine collections are in exceptions.h. + * + * Usage: + * \code + ISR(foo_irq_handler) + { + // Function definition + ... + } +\endcode + * + * \param func Name for the function. + */ +# define ISR(func) \ + void func (void) + +/** + * \brief Initialize interrupt vectors + * + * For NVIC the interrupt vectors are put in vector table. So nothing + * to do to initialize them, except defined the vector function with + * right name. + * + * This must be called prior to \ref irq_register_handler. + */ +# define irq_initialize_vectors() \ + do { \ + } while(0) + +/** + * \brief Register handler for interrupt + * + * For NVIC the interrupt vectors are put in vector table. So nothing + * to do to register them, except defined the vector function with + * right name. + * + * Usage: + * \code + irq_initialize_vectors(); + irq_register_handler(foo_irq_handler); +\endcode + * + * \note The function \a func must be defined with the \ref ISR macro. + * \note The functions prototypes can be found in the device exception header + * files (exceptions.h). + */ +# define irq_register_handler(int_num, int_prio) \ + NVIC_ClearPendingIRQ( (IRQn_Type)int_num); \ + NVIC_SetPriority( (IRQn_Type)int_num, int_prio); \ + NVIC_EnableIRQ( (IRQn_Type)int_num); \ + +//@} + +# define cpu_irq_enable() \ + do { \ + g_interrupt_enabled = true; \ + __DMB(); \ + __enable_irq(); \ + } while (0) +# define cpu_irq_disable() \ + do { \ + __disable_irq(); \ + __DMB(); \ + g_interrupt_enabled = false; \ + } while (0) + +typedef uint32_t irqflags_t; + +#if !defined(__DOXYGEN__) +extern volatile bool g_interrupt_enabled; +#endif + +#define cpu_irq_is_enabled() (__get_PRIMASK() == 0) + +static volatile uint32_t cpu_irq_critical_section_counter; +static volatile bool cpu_irq_prev_interrupt_state; + +static inline irqflags_t cpu_irq_save(void) +{ + irqflags_t flags = cpu_irq_is_enabled(); + cpu_irq_disable(); + return flags; +} + +static inline bool cpu_irq_is_enabled_flags(irqflags_t flags) +{ + return (flags); +} + +static inline void cpu_irq_restore(irqflags_t flags) +{ + if (cpu_irq_is_enabled_flags(flags)) + cpu_irq_enable(); +} + +void cpu_irq_enter_critical(void); +void cpu_irq_leave_critical(void); + +/** + * \weakgroup interrupt_deprecated_group + * @{ + */ + +#define Enable_global_interrupt() cpu_irq_enable() +#define Disable_global_interrupt() cpu_irq_disable() +#define Is_global_interrupt_enabled() cpu_irq_is_enabled() + +//@} + +//@} + +#ifdef __cplusplus +} +#endif + +#endif /* UTILS_INTERRUPT_INTERRUPT_H */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/common/utils/parts.h b/bootloaders/mzero/Bootloader_D21/src/ASF/common/utils/parts.h new file mode 100644 index 0000000..d2319ae --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/common/utils/parts.h @@ -0,0 +1,1242 @@ +/** + * \file + * + * \brief Atmel part identification macros + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef ATMEL_PARTS_H +#define ATMEL_PARTS_H + +/** + * \defgroup part_macros_group Atmel part identification macros + * + * This collection of macros identify which series and families that the various + * Atmel parts belong to. These can be used to select part-dependent sections of + * code at compile time. + * + * @{ + */ + +/** + * \name Convenience macros for part checking + * @{ + */ +/* ! Check GCC and IAR part definition for 8-bit AVR */ +#define AVR8_PART_IS_DEFINED(part) \ + (defined(__ ## part ## __) || defined(__AVR_ ## part ## __)) + +/* ! Check GCC and IAR part definition for 32-bit AVR */ +#define AVR32_PART_IS_DEFINED(part) \ + (defined(__AT32 ## part ## __) || defined(__AVR32_ ## part ## __)) + +/* ! Check GCC and IAR part definition for SAM */ +#define SAM_PART_IS_DEFINED(part) (defined(__ ## part ## __)) +/** @} */ + +/** + * \defgroup uc3_part_macros_group AVR UC3 parts + * @{ + */ + +/** + * \name AVR UC3 A series + * @{ + */ +#define UC3A0 ( \ + AVR32_PART_IS_DEFINED(UC3A0128) || \ + AVR32_PART_IS_DEFINED(UC3A0256) || \ + AVR32_PART_IS_DEFINED(UC3A0512) \ + ) + +#define UC3A1 ( \ + AVR32_PART_IS_DEFINED(UC3A1128) || \ + AVR32_PART_IS_DEFINED(UC3A1256) || \ + AVR32_PART_IS_DEFINED(UC3A1512) \ + ) + +#define UC3A3 ( \ + AVR32_PART_IS_DEFINED(UC3A364) || \ + AVR32_PART_IS_DEFINED(UC3A364S) || \ + AVR32_PART_IS_DEFINED(UC3A3128) || \ + AVR32_PART_IS_DEFINED(UC3A3128S) || \ + AVR32_PART_IS_DEFINED(UC3A3256) || \ + AVR32_PART_IS_DEFINED(UC3A3256S) \ + ) + +#define UC3A4 ( \ + AVR32_PART_IS_DEFINED(UC3A464) || \ + AVR32_PART_IS_DEFINED(UC3A464S) || \ + AVR32_PART_IS_DEFINED(UC3A4128) || \ + AVR32_PART_IS_DEFINED(UC3A4128S) || \ + AVR32_PART_IS_DEFINED(UC3A4256) || \ + AVR32_PART_IS_DEFINED(UC3A4256S) \ + ) +/** @} */ + +/** + * \name AVR UC3 B series + * @{ + */ +#define UC3B0 ( \ + AVR32_PART_IS_DEFINED(UC3B064) || \ + AVR32_PART_IS_DEFINED(UC3B0128) || \ + AVR32_PART_IS_DEFINED(UC3B0256) || \ + AVR32_PART_IS_DEFINED(UC3B0512) \ + ) + +#define UC3B1 ( \ + AVR32_PART_IS_DEFINED(UC3B164) || \ + AVR32_PART_IS_DEFINED(UC3B1128) || \ + AVR32_PART_IS_DEFINED(UC3B1256) || \ + AVR32_PART_IS_DEFINED(UC3B1512) \ + ) +/** @} */ + +/** + * \name AVR UC3 C series + * @{ + */ +#define UC3C0 ( \ + AVR32_PART_IS_DEFINED(UC3C064C) || \ + AVR32_PART_IS_DEFINED(UC3C0128C) || \ + AVR32_PART_IS_DEFINED(UC3C0256C) || \ + AVR32_PART_IS_DEFINED(UC3C0512C) \ + ) + +#define UC3C1 ( \ + AVR32_PART_IS_DEFINED(UC3C164C) || \ + AVR32_PART_IS_DEFINED(UC3C1128C) || \ + AVR32_PART_IS_DEFINED(UC3C1256C) || \ + AVR32_PART_IS_DEFINED(UC3C1512C) \ + ) + +#define UC3C2 ( \ + AVR32_PART_IS_DEFINED(UC3C264C) || \ + AVR32_PART_IS_DEFINED(UC3C2128C) || \ + AVR32_PART_IS_DEFINED(UC3C2256C) || \ + AVR32_PART_IS_DEFINED(UC3C2512C) \ + ) +/** @} */ + +/** + * \name AVR UC3 D series + * @{ + */ +#define UC3D3 ( \ + AVR32_PART_IS_DEFINED(UC64D3) || \ + AVR32_PART_IS_DEFINED(UC128D3) \ + ) + +#define UC3D4 ( \ + AVR32_PART_IS_DEFINED(UC64D4) || \ + AVR32_PART_IS_DEFINED(UC128D4) \ + ) +/** @} */ + +/** + * \name AVR UC3 L series + * @{ + */ +#define UC3L0 ( \ + AVR32_PART_IS_DEFINED(UC3L016) || \ + AVR32_PART_IS_DEFINED(UC3L032) || \ + AVR32_PART_IS_DEFINED(UC3L064) \ + ) + +#define UC3L0128 ( \ + AVR32_PART_IS_DEFINED(UC3L0128) \ + ) + +#define UC3L0256 ( \ + AVR32_PART_IS_DEFINED(UC3L0256) \ + ) + +#define UC3L3 ( \ + AVR32_PART_IS_DEFINED(UC64L3U) || \ + AVR32_PART_IS_DEFINED(UC128L3U) || \ + AVR32_PART_IS_DEFINED(UC256L3U) \ + ) + +#define UC3L4 ( \ + AVR32_PART_IS_DEFINED(UC64L4U) || \ + AVR32_PART_IS_DEFINED(UC128L4U) || \ + AVR32_PART_IS_DEFINED(UC256L4U) \ + ) + +#define UC3L3_L4 (UC3L3 || UC3L4) +/** @} */ + +/** + * \name AVR UC3 families + * @{ + */ +/** AVR UC3 A family */ +#define UC3A (UC3A0 || UC3A1 || UC3A3 || UC3A4) + +/** AVR UC3 B family */ +#define UC3B (UC3B0 || UC3B1) + +/** AVR UC3 C family */ +#define UC3C (UC3C0 || UC3C1 || UC3C2) + +/** AVR UC3 D family */ +#define UC3D (UC3D3 || UC3D4) + +/** AVR UC3 L family */ +#define UC3L (UC3L0 || UC3L0128 || UC3L0256 || UC3L3_L4) +/** @} */ + +/** AVR UC3 product line */ +#define UC3 (UC3A || UC3B || UC3C || UC3D || UC3L) + +/** @} */ + +/** + * \defgroup xmega_part_macros_group AVR XMEGA parts + * @{ + */ + +/** + * \name AVR XMEGA A series + * @{ + */ +#define XMEGA_A1 ( \ + AVR8_PART_IS_DEFINED(ATxmega64A1) || \ + AVR8_PART_IS_DEFINED(ATxmega128A1) \ + ) + +#define XMEGA_A3 ( \ + AVR8_PART_IS_DEFINED(ATxmega64A3) || \ + AVR8_PART_IS_DEFINED(ATxmega128A3) || \ + AVR8_PART_IS_DEFINED(ATxmega192A3) || \ + AVR8_PART_IS_DEFINED(ATxmega256A3) \ + ) + +#define XMEGA_A3B ( \ + AVR8_PART_IS_DEFINED(ATxmega256A3B) \ + ) + +#define XMEGA_A4 ( \ + AVR8_PART_IS_DEFINED(ATxmega16A4) || \ + AVR8_PART_IS_DEFINED(ATxmega32A4) \ + ) +/** @} */ + +/** + * \name AVR XMEGA AU series + * @{ + */ +#define XMEGA_A1U ( \ + AVR8_PART_IS_DEFINED(ATxmega64A1U) || \ + AVR8_PART_IS_DEFINED(ATxmega128A1U) \ + ) + +#define XMEGA_A3U ( \ + AVR8_PART_IS_DEFINED(ATxmega64A3U) || \ + AVR8_PART_IS_DEFINED(ATxmega128A3U) || \ + AVR8_PART_IS_DEFINED(ATxmega192A3U) || \ + AVR8_PART_IS_DEFINED(ATxmega256A3U) \ + ) + +#define XMEGA_A3BU ( \ + AVR8_PART_IS_DEFINED(ATxmega256A3BU) \ + ) + +#define XMEGA_A4U ( \ + AVR8_PART_IS_DEFINED(ATxmega16A4U) || \ + AVR8_PART_IS_DEFINED(ATxmega32A4U) || \ + AVR8_PART_IS_DEFINED(ATxmega64A4U) || \ + AVR8_PART_IS_DEFINED(ATxmega128A4U) \ + ) +/** @} */ + +/** + * \name AVR XMEGA B series + * @{ + */ +#define XMEGA_B1 ( \ + AVR8_PART_IS_DEFINED(ATxmega64B1) || \ + AVR8_PART_IS_DEFINED(ATxmega128B1) \ + ) + +#define XMEGA_B3 ( \ + AVR8_PART_IS_DEFINED(ATxmega64B3) || \ + AVR8_PART_IS_DEFINED(ATxmega128B3) \ + ) +/** @} */ + +/** + * \name AVR XMEGA C series + * @{ + */ +#define XMEGA_C3 ( \ + AVR8_PART_IS_DEFINED(ATxmega384C3) || \ + AVR8_PART_IS_DEFINED(ATxmega256C3) || \ + AVR8_PART_IS_DEFINED(ATxmega192C3) || \ + AVR8_PART_IS_DEFINED(ATxmega128C3) || \ + AVR8_PART_IS_DEFINED(ATxmega64C3) || \ + AVR8_PART_IS_DEFINED(ATxmega32C3) \ + ) + +#define XMEGA_C4 ( \ + AVR8_PART_IS_DEFINED(ATxmega32C4) || \ + AVR8_PART_IS_DEFINED(ATxmega16C4) \ + ) +/** @} */ + +/** + * \name AVR XMEGA D series + * @{ + */ +#define XMEGA_D3 ( \ + AVR8_PART_IS_DEFINED(ATxmega32D3) || \ + AVR8_PART_IS_DEFINED(ATxmega64D3) || \ + AVR8_PART_IS_DEFINED(ATxmega128D3) || \ + AVR8_PART_IS_DEFINED(ATxmega192D3) || \ + AVR8_PART_IS_DEFINED(ATxmega256D3) || \ + AVR8_PART_IS_DEFINED(ATxmega384D3) \ + ) + +#define XMEGA_D4 ( \ + AVR8_PART_IS_DEFINED(ATxmega16D4) || \ + AVR8_PART_IS_DEFINED(ATxmega32D4) || \ + AVR8_PART_IS_DEFINED(ATxmega64D4) || \ + AVR8_PART_IS_DEFINED(ATxmega128D4) \ + ) +/** @} */ + +/** + * \name AVR XMEGA E series + * @{ + */ +#define XMEGA_E5 ( \ + AVR8_PART_IS_DEFINED(ATxmega8E5) || \ + AVR8_PART_IS_DEFINED(ATxmega16E5) || \ + AVR8_PART_IS_DEFINED(ATxmega32E5) \ + ) +/** @} */ + + +/** + * \name AVR XMEGA families + * @{ + */ +/** AVR XMEGA A family */ +#define XMEGA_A (XMEGA_A1 || XMEGA_A3 || XMEGA_A3B || XMEGA_A4) + +/** AVR XMEGA AU family */ +#define XMEGA_AU (XMEGA_A1U || XMEGA_A3U || XMEGA_A3BU || XMEGA_A4U) + +/** AVR XMEGA B family */ +#define XMEGA_B (XMEGA_B1 || XMEGA_B3) + +/** AVR XMEGA C family */ +#define XMEGA_C (XMEGA_C3 || XMEGA_C4) + +/** AVR XMEGA D family */ +#define XMEGA_D (XMEGA_D3 || XMEGA_D4) + +/** AVR XMEGA E family */ +#define XMEGA_E (XMEGA_E5) +/** @} */ + + +/** AVR XMEGA product line */ +#define XMEGA (XMEGA_A || XMEGA_AU || XMEGA_B || XMEGA_C || XMEGA_D || XMEGA_E) + +/** @} */ + +/** + * \defgroup mega_part_macros_group megaAVR parts + * + * \note These megaAVR groupings are based on the groups in AVR Libc for the + * part header files. They are not names of official megaAVR device series or + * families. + * + * @{ + */ + +/** + * \name ATmegaxx0/xx1 subgroups + * @{ + */ +#define MEGA_XX0 ( \ + AVR8_PART_IS_DEFINED(ATmega640) || \ + AVR8_PART_IS_DEFINED(ATmega1280) || \ + AVR8_PART_IS_DEFINED(ATmega2560) \ + ) + +#define MEGA_XX1 ( \ + AVR8_PART_IS_DEFINED(ATmega1281) || \ + AVR8_PART_IS_DEFINED(ATmega2561) \ + ) +/** @} */ + +/** + * \name megaAVR groups + * @{ + */ +/** ATmegaxx0/xx1 group */ +#define MEGA_XX0_1 (MEGA_XX0 || MEGA_XX1) + +/** ATmegaxx4 group */ +#define MEGA_XX4 ( \ + AVR8_PART_IS_DEFINED(ATmega164A) || \ + AVR8_PART_IS_DEFINED(ATmega164PA) || \ + AVR8_PART_IS_DEFINED(ATmega324A) || \ + AVR8_PART_IS_DEFINED(ATmega324PA) || \ + AVR8_PART_IS_DEFINED(ATmega644) || \ + AVR8_PART_IS_DEFINED(ATmega644A) || \ + AVR8_PART_IS_DEFINED(ATmega644PA) || \ + AVR8_PART_IS_DEFINED(ATmega1284P) || \ + AVR8_PART_IS_DEFINED(ATmega128RFA1) \ + ) + +/** ATmegaxx4 group */ +#define MEGA_XX4_A ( \ + AVR8_PART_IS_DEFINED(ATmega164A) || \ + AVR8_PART_IS_DEFINED(ATmega164PA) || \ + AVR8_PART_IS_DEFINED(ATmega324A) || \ + AVR8_PART_IS_DEFINED(ATmega324PA) || \ + AVR8_PART_IS_DEFINED(ATmega644A) || \ + AVR8_PART_IS_DEFINED(ATmega644PA) || \ + AVR8_PART_IS_DEFINED(ATmega1284P) \ + ) + +/** ATmegaxx8 group */ +#define MEGA_XX8 ( \ + AVR8_PART_IS_DEFINED(ATmega48) || \ + AVR8_PART_IS_DEFINED(ATmega48A) || \ + AVR8_PART_IS_DEFINED(ATmega48PA) || \ + AVR8_PART_IS_DEFINED(ATmega88) || \ + AVR8_PART_IS_DEFINED(ATmega88A) || \ + AVR8_PART_IS_DEFINED(ATmega88PA) || \ + AVR8_PART_IS_DEFINED(ATmega168) || \ + AVR8_PART_IS_DEFINED(ATmega168A) || \ + AVR8_PART_IS_DEFINED(ATmega168PA) || \ + AVR8_PART_IS_DEFINED(ATmega328) || \ + AVR8_PART_IS_DEFINED(ATmega328P) \ + ) + +/** ATmegaxx8A/P/PA group */ +#define MEGA_XX8_A ( \ + AVR8_PART_IS_DEFINED(ATmega48A) || \ + AVR8_PART_IS_DEFINED(ATmega48PA) || \ + AVR8_PART_IS_DEFINED(ATmega88A) || \ + AVR8_PART_IS_DEFINED(ATmega88PA) || \ + AVR8_PART_IS_DEFINED(ATmega168A) || \ + AVR8_PART_IS_DEFINED(ATmega168PA) || \ + AVR8_PART_IS_DEFINED(ATmega328P) \ + ) + +/** ATmegaxx group */ +#define MEGA_XX ( \ + AVR8_PART_IS_DEFINED(ATmega16) || \ + AVR8_PART_IS_DEFINED(ATmega16A) || \ + AVR8_PART_IS_DEFINED(ATmega32) || \ + AVR8_PART_IS_DEFINED(ATmega32A) || \ + AVR8_PART_IS_DEFINED(ATmega64) || \ + AVR8_PART_IS_DEFINED(ATmega64A) || \ + AVR8_PART_IS_DEFINED(ATmega128) || \ + AVR8_PART_IS_DEFINED(ATmega128A) \ + ) + +/** ATmegaxxA/P/PA group */ +#define MEGA_XX_A ( \ + AVR8_PART_IS_DEFINED(ATmega16A) || \ + AVR8_PART_IS_DEFINED(ATmega32A) || \ + AVR8_PART_IS_DEFINED(ATmega64A) || \ + AVR8_PART_IS_DEFINED(ATmega128A) \ + ) +/** ATmegaxxRFA1 group */ +#define MEGA_RFA1 ( \ + AVR8_PART_IS_DEFINED(ATmega128RFA1) \ + ) + +/** ATmegaxxRFR2 group */ +#define MEGA_RFR2 ( \ + AVR8_PART_IS_DEFINED(ATmega64RFR2) || \ + AVR8_PART_IS_DEFINED(ATmega128RFR2) || \ + AVR8_PART_IS_DEFINED(ATmega256RFR2) || \ + AVR8_PART_IS_DEFINED(ATmega644RFR2) || \ + AVR8_PART_IS_DEFINED(ATmega1284RFR2) || \ + AVR8_PART_IS_DEFINED(ATmega2564RFR2) \ + ) + + +/** ATmegaxxRFxx group */ +#define MEGA_RF (MEGA_RFA1 || MEGA_RFR2) + +/** + * \name ATmegaxx_un0/un1/un2 subgroups + * @{ + */ +#define MEGA_XX_UN0 ( \ + AVR8_PART_IS_DEFINED(ATmega16) || \ + AVR8_PART_IS_DEFINED(ATmega16A) || \ + AVR8_PART_IS_DEFINED(ATmega32) || \ + AVR8_PART_IS_DEFINED(ATmega32A) \ + ) + +/** ATmegaxx group without power reduction and + * And interrupt sense register. + */ +#define MEGA_XX_UN1 ( \ + AVR8_PART_IS_DEFINED(ATmega64) || \ + AVR8_PART_IS_DEFINED(ATmega64A) || \ + AVR8_PART_IS_DEFINED(ATmega128) || \ + AVR8_PART_IS_DEFINED(ATmega128A) \ + ) + +/** ATmegaxx group without power reduction and + * And interrupt sense register. + */ +#define MEGA_XX_UN2 ( \ + AVR8_PART_IS_DEFINED(ATmega169P) || \ + AVR8_PART_IS_DEFINED(ATmega169PA) || \ + AVR8_PART_IS_DEFINED(ATmega329P) || \ + AVR8_PART_IS_DEFINED(ATmega329PA) \ + ) + +/** Devices added to complete megaAVR offering. + * Please do not use this group symbol as it is not intended + * to be permanent: the devices should be regrouped. + */ +#define MEGA_UNCATEGORIZED ( \ + AVR8_PART_IS_DEFINED(AT90CAN128) || \ + AVR8_PART_IS_DEFINED(AT90CAN32) || \ + AVR8_PART_IS_DEFINED(AT90CAN64) || \ + AVR8_PART_IS_DEFINED(AT90PWM1) || \ + AVR8_PART_IS_DEFINED(AT90PWM216) || \ + AVR8_PART_IS_DEFINED(AT90PWM2B) || \ + AVR8_PART_IS_DEFINED(AT90PWM316) || \ + AVR8_PART_IS_DEFINED(AT90PWM3B) || \ + AVR8_PART_IS_DEFINED(AT90PWM81) || \ + AVR8_PART_IS_DEFINED(AT90USB1286) || \ + AVR8_PART_IS_DEFINED(AT90USB1287) || \ + AVR8_PART_IS_DEFINED(AT90USB162) || \ + AVR8_PART_IS_DEFINED(AT90USB646) || \ + AVR8_PART_IS_DEFINED(AT90USB647) || \ + AVR8_PART_IS_DEFINED(AT90USB82) || \ + AVR8_PART_IS_DEFINED(ATmega1284) || \ + AVR8_PART_IS_DEFINED(ATmega162) || \ + AVR8_PART_IS_DEFINED(ATmega164P) || \ + AVR8_PART_IS_DEFINED(ATmega165A) || \ + AVR8_PART_IS_DEFINED(ATmega165P) || \ + AVR8_PART_IS_DEFINED(ATmega165PA) || \ + AVR8_PART_IS_DEFINED(ATmega168P) || \ + AVR8_PART_IS_DEFINED(ATmega169A) || \ + AVR8_PART_IS_DEFINED(ATmega16M1) || \ + AVR8_PART_IS_DEFINED(ATmega16U2) || \ + AVR8_PART_IS_DEFINED(ATmega16U4) || \ + AVR8_PART_IS_DEFINED(ATmega256RFA2) || \ + AVR8_PART_IS_DEFINED(ATmega324P) || \ + AVR8_PART_IS_DEFINED(ATmega325) || \ + AVR8_PART_IS_DEFINED(ATmega3250) || \ + AVR8_PART_IS_DEFINED(ATmega3250A) || \ + AVR8_PART_IS_DEFINED(ATmega3250P) || \ + AVR8_PART_IS_DEFINED(ATmega3250PA) || \ + AVR8_PART_IS_DEFINED(ATmega325A) || \ + AVR8_PART_IS_DEFINED(ATmega325P) || \ + AVR8_PART_IS_DEFINED(ATmega325PA) || \ + AVR8_PART_IS_DEFINED(ATmega329) || \ + AVR8_PART_IS_DEFINED(ATmega3290) || \ + AVR8_PART_IS_DEFINED(ATmega3290A) || \ + AVR8_PART_IS_DEFINED(ATmega3290P) || \ + AVR8_PART_IS_DEFINED(ATmega3290PA) || \ + AVR8_PART_IS_DEFINED(ATmega329A) || \ + AVR8_PART_IS_DEFINED(ATmega32M1) || \ + AVR8_PART_IS_DEFINED(ATmega32U2) || \ + AVR8_PART_IS_DEFINED(ATmega32U4) || \ + AVR8_PART_IS_DEFINED(ATmega48P) || \ + AVR8_PART_IS_DEFINED(ATmega644P) || \ + AVR8_PART_IS_DEFINED(ATmega645) || \ + AVR8_PART_IS_DEFINED(ATmega6450) || \ + AVR8_PART_IS_DEFINED(ATmega6450A) || \ + AVR8_PART_IS_DEFINED(ATmega6450P) || \ + AVR8_PART_IS_DEFINED(ATmega645A) || \ + AVR8_PART_IS_DEFINED(ATmega645P) || \ + AVR8_PART_IS_DEFINED(ATmega649) || \ + AVR8_PART_IS_DEFINED(ATmega6490) || \ + AVR8_PART_IS_DEFINED(ATmega6490A) || \ + AVR8_PART_IS_DEFINED(ATmega6490P) || \ + AVR8_PART_IS_DEFINED(ATmega649A) || \ + AVR8_PART_IS_DEFINED(ATmega649P) || \ + AVR8_PART_IS_DEFINED(ATmega64M1) || \ + AVR8_PART_IS_DEFINED(ATmega64RFA2) || \ + AVR8_PART_IS_DEFINED(ATmega8) || \ + AVR8_PART_IS_DEFINED(ATmega8515) || \ + AVR8_PART_IS_DEFINED(ATmega8535) || \ + AVR8_PART_IS_DEFINED(ATmega88P) || \ + AVR8_PART_IS_DEFINED(ATmega8A) || \ + AVR8_PART_IS_DEFINED(ATmega8U2) \ + ) + +/** Unspecified group */ +#define MEGA_UNSPECIFIED (MEGA_XX_UN0 || MEGA_XX_UN1 || MEGA_XX_UN2 || \ + MEGA_UNCATEGORIZED) + +/** @} */ + +/** megaAVR product line */ +#define MEGA (MEGA_XX0_1 || MEGA_XX4 || MEGA_XX8 || MEGA_XX || MEGA_RF || \ + MEGA_UNSPECIFIED) + +/** @} */ + +/** + * \defgroup tiny_part_macros_group tinyAVR parts + * + * @{ + */ + +/** + * \name tinyAVR groups + * @{ + */ + +/** Devices added to complete tinyAVR offering. + * Please do not use this group symbol as it is not intended + * to be permanent: the devices should be regrouped. + */ +#define TINY_UNCATEGORIZED ( \ + AVR8_PART_IS_DEFINED(ATtiny10) || \ + AVR8_PART_IS_DEFINED(ATtiny13) || \ + AVR8_PART_IS_DEFINED(ATtiny13A) || \ + AVR8_PART_IS_DEFINED(ATtiny1634) || \ + AVR8_PART_IS_DEFINED(ATtiny167) || \ + AVR8_PART_IS_DEFINED(ATtiny20) || \ + AVR8_PART_IS_DEFINED(ATtiny2313) || \ + AVR8_PART_IS_DEFINED(ATtiny2313A) || \ + AVR8_PART_IS_DEFINED(ATtiny24) || \ + AVR8_PART_IS_DEFINED(ATtiny24A) || \ + AVR8_PART_IS_DEFINED(ATtiny25) || \ + AVR8_PART_IS_DEFINED(ATtiny26) || \ + AVR8_PART_IS_DEFINED(ATtiny261) || \ + AVR8_PART_IS_DEFINED(ATtiny261A) || \ + AVR8_PART_IS_DEFINED(ATtiny4) || \ + AVR8_PART_IS_DEFINED(ATtiny40) || \ + AVR8_PART_IS_DEFINED(ATtiny4313) || \ + AVR8_PART_IS_DEFINED(ATtiny43U) || \ + AVR8_PART_IS_DEFINED(ATtiny44) || \ + AVR8_PART_IS_DEFINED(ATtiny44A) || \ + AVR8_PART_IS_DEFINED(ATtiny45) || \ + AVR8_PART_IS_DEFINED(ATtiny461) || \ + AVR8_PART_IS_DEFINED(ATtiny461A) || \ + AVR8_PART_IS_DEFINED(ATtiny48) || \ + AVR8_PART_IS_DEFINED(ATtiny5) || \ + AVR8_PART_IS_DEFINED(ATtiny828) || \ + AVR8_PART_IS_DEFINED(ATtiny84) || \ + AVR8_PART_IS_DEFINED(ATtiny84A) || \ + AVR8_PART_IS_DEFINED(ATtiny85) || \ + AVR8_PART_IS_DEFINED(ATtiny861) || \ + AVR8_PART_IS_DEFINED(ATtiny861A) || \ + AVR8_PART_IS_DEFINED(ATtiny87) || \ + AVR8_PART_IS_DEFINED(ATtiny88) || \ + AVR8_PART_IS_DEFINED(ATtiny9) \ + ) + +/** @} */ + +/** tinyAVR product line */ +#define TINY (TINY_UNCATEGORIZED) + +/** @} */ + +/** + * \defgroup sam_part_macros_group SAM parts + * @{ + */ + +/** + * \name SAM3S series + * @{ + */ +#define SAM3S1 ( \ + SAM_PART_IS_DEFINED(SAM3S1A) || \ + SAM_PART_IS_DEFINED(SAM3S1B) || \ + SAM_PART_IS_DEFINED(SAM3S1C) \ + ) + +#define SAM3S2 ( \ + SAM_PART_IS_DEFINED(SAM3S2A) || \ + SAM_PART_IS_DEFINED(SAM3S2B) || \ + SAM_PART_IS_DEFINED(SAM3S2C) \ + ) + +#define SAM3S4 ( \ + SAM_PART_IS_DEFINED(SAM3S4A) || \ + SAM_PART_IS_DEFINED(SAM3S4B) || \ + SAM_PART_IS_DEFINED(SAM3S4C) \ + ) + +#define SAM3S8 ( \ + SAM_PART_IS_DEFINED(SAM3S8B) || \ + SAM_PART_IS_DEFINED(SAM3S8C) \ + ) + +#define SAM3SD8 ( \ + SAM_PART_IS_DEFINED(SAM3SD8B) || \ + SAM_PART_IS_DEFINED(SAM3SD8C) \ + ) +/** @} */ + +/** + * \name SAM3U series + * @{ + */ +#define SAM3U1 ( \ + SAM_PART_IS_DEFINED(SAM3U1C) || \ + SAM_PART_IS_DEFINED(SAM3U1E) \ + ) + +#define SAM3U2 ( \ + SAM_PART_IS_DEFINED(SAM3U2C) || \ + SAM_PART_IS_DEFINED(SAM3U2E) \ + ) + +#define SAM3U4 ( \ + SAM_PART_IS_DEFINED(SAM3U4C) || \ + SAM_PART_IS_DEFINED(SAM3U4E) \ + ) +/** @} */ + +/** + * \name SAM3N series + * @{ + */ +#define SAM3N00 ( \ + SAM_PART_IS_DEFINED(SAM3N00A) || \ + SAM_PART_IS_DEFINED(SAM3N00B) \ + ) + +#define SAM3N0 ( \ + SAM_PART_IS_DEFINED(SAM3N0A) || \ + SAM_PART_IS_DEFINED(SAM3N0B) || \ + SAM_PART_IS_DEFINED(SAM3N0C) \ + ) + +#define SAM3N1 ( \ + SAM_PART_IS_DEFINED(SAM3N1A) || \ + SAM_PART_IS_DEFINED(SAM3N1B) || \ + SAM_PART_IS_DEFINED(SAM3N1C) \ + ) + +#define SAM3N2 ( \ + SAM_PART_IS_DEFINED(SAM3N2A) || \ + SAM_PART_IS_DEFINED(SAM3N2B) || \ + SAM_PART_IS_DEFINED(SAM3N2C) \ + ) + +#define SAM3N4 ( \ + SAM_PART_IS_DEFINED(SAM3N4A) || \ + SAM_PART_IS_DEFINED(SAM3N4B) || \ + SAM_PART_IS_DEFINED(SAM3N4C) \ + ) +/** @} */ + +/** + * \name SAM3X series + * @{ + */ +#define SAM3X4 ( \ + SAM_PART_IS_DEFINED(SAM3X4C) || \ + SAM_PART_IS_DEFINED(SAM3X4E) \ + ) + +#define SAM3X8 ( \ + SAM_PART_IS_DEFINED(SAM3X8C) || \ + SAM_PART_IS_DEFINED(SAM3X8E) || \ + SAM_PART_IS_DEFINED(SAM3X8H) \ + ) +/** @} */ + +/** + * \name SAM3A series + * @{ + */ +#define SAM3A4 ( \ + SAM_PART_IS_DEFINED(SAM3A4C) \ + ) + +#define SAM3A8 ( \ + SAM_PART_IS_DEFINED(SAM3A8C) \ + ) +/** @} */ + +/** + * \name SAM4S series + * @{ + */ +#define SAM4S2 ( \ + SAM_PART_IS_DEFINED(SAM4S2A) || \ + SAM_PART_IS_DEFINED(SAM4S2B) || \ + SAM_PART_IS_DEFINED(SAM4S2C) \ + ) + +#define SAM4S4 ( \ + SAM_PART_IS_DEFINED(SAM4S4A) || \ + SAM_PART_IS_DEFINED(SAM4S4B) || \ + SAM_PART_IS_DEFINED(SAM4S4C) \ + ) + +#define SAM4S8 ( \ + SAM_PART_IS_DEFINED(SAM4S8B) || \ + SAM_PART_IS_DEFINED(SAM4S8C) \ + ) + +#define SAM4S16 ( \ + SAM_PART_IS_DEFINED(SAM4S16B) || \ + SAM_PART_IS_DEFINED(SAM4S16C) \ + ) + +#define SAM4SA16 ( \ + SAM_PART_IS_DEFINED(SAM4SA16B) || \ + SAM_PART_IS_DEFINED(SAM4SA16C) \ + ) + +#define SAM4SD16 ( \ + SAM_PART_IS_DEFINED(SAM4SD16B) || \ + SAM_PART_IS_DEFINED(SAM4SD16C) \ + ) + +#define SAM4SD32 ( \ + SAM_PART_IS_DEFINED(SAM4SD32B) || \ + SAM_PART_IS_DEFINED(SAM4SD32C) \ + ) +/** @} */ + +/** + * \name SAM4L series + * @{ + */ +#define SAM4LS ( \ + SAM_PART_IS_DEFINED(SAM4LS2A) || \ + SAM_PART_IS_DEFINED(SAM4LS2B) || \ + SAM_PART_IS_DEFINED(SAM4LS2C) || \ + SAM_PART_IS_DEFINED(SAM4LS4A) || \ + SAM_PART_IS_DEFINED(SAM4LS4B) || \ + SAM_PART_IS_DEFINED(SAM4LS4C) || \ + SAM_PART_IS_DEFINED(SAM4LS8A) || \ + SAM_PART_IS_DEFINED(SAM4LS8B) || \ + SAM_PART_IS_DEFINED(SAM4LS8C) \ + ) + +#define SAM4LC ( \ + SAM_PART_IS_DEFINED(SAM4LC2A) || \ + SAM_PART_IS_DEFINED(SAM4LC2B) || \ + SAM_PART_IS_DEFINED(SAM4LC2C) || \ + SAM_PART_IS_DEFINED(SAM4LC4A) || \ + SAM_PART_IS_DEFINED(SAM4LC4B) || \ + SAM_PART_IS_DEFINED(SAM4LC4C) || \ + SAM_PART_IS_DEFINED(SAM4LC8A) || \ + SAM_PART_IS_DEFINED(SAM4LC8B) || \ + SAM_PART_IS_DEFINED(SAM4LC8C) \ + ) +/** @} */ + +/** + * \name SAMD20 series + * @{ + */ +#define SAMD20J ( \ + SAM_PART_IS_DEFINED(SAMD20J14) || \ + SAM_PART_IS_DEFINED(SAMD20J15) || \ + SAM_PART_IS_DEFINED(SAMD20J16) || \ + SAM_PART_IS_DEFINED(SAMD20J17) || \ + SAM_PART_IS_DEFINED(SAMD20J18) \ + ) + +#define SAMD20G ( \ + SAM_PART_IS_DEFINED(SAMD20G14) || \ + SAM_PART_IS_DEFINED(SAMD20G15) || \ + SAM_PART_IS_DEFINED(SAMD20G16) || \ + SAM_PART_IS_DEFINED(SAMD20G17) || \ + SAM_PART_IS_DEFINED(SAMD20G17U) || \ + SAM_PART_IS_DEFINED(SAMD20G18) || \ + SAM_PART_IS_DEFINED(SAMD20G18U) \ + ) + +#define SAMD20E ( \ + SAM_PART_IS_DEFINED(SAMD20E14) || \ + SAM_PART_IS_DEFINED(SAMD20E15) || \ + SAM_PART_IS_DEFINED(SAMD20E16) || \ + SAM_PART_IS_DEFINED(SAMD20E17) || \ + SAM_PART_IS_DEFINED(SAMD20E18) || \ + SAM_PART_IS_DEFINED(SAMD20E1F) \ + ) +/** @} */ + +/** + * \name SAMD21 series + * @{ + */ +#define SAMD21J ( \ + SAM_PART_IS_DEFINED(SAMD21J15A) || \ + SAM_PART_IS_DEFINED(SAMD21J16A) || \ + SAM_PART_IS_DEFINED(SAMD21J17A) || \ + SAM_PART_IS_DEFINED(SAMD21J18A) \ + ) + +#define SAMD21G ( \ + SAM_PART_IS_DEFINED(SAMD21G15A) || \ + SAM_PART_IS_DEFINED(SAMD21G16A) || \ + SAM_PART_IS_DEFINED(SAMD21G17A) || \ + SAM_PART_IS_DEFINED(SAMD21G18A) \ + ) + +#define SAMD21E ( \ + SAM_PART_IS_DEFINED(SAMD21E15A) || \ + SAM_PART_IS_DEFINED(SAMD21E16A) || \ + SAM_PART_IS_DEFINED(SAMD21E17A) || \ + SAM_PART_IS_DEFINED(SAMD21E18A) \ + ) +/** @} */ + +/** + * \name SAMR21 series + * @{ + */ +#define SAMR21G ( \ + SAM_PART_IS_DEFINED(SAMR21G16A) || \ + SAM_PART_IS_DEFINED(SAMR21G17A) || \ + SAM_PART_IS_DEFINED(SAMR21G18A) \ + ) + +#define SAMR21E ( \ + SAM_PART_IS_DEFINED(SAMR21E16A) || \ + SAM_PART_IS_DEFINED(SAMR21E17A) || \ + SAM_PART_IS_DEFINED(SAMR21E18A) \ + ) +/** @} */ + +/** + * \name SAMD10 series + * @{ + */ +#define SAMD10C ( \ + SAM_PART_IS_DEFINED(SAMD10C12A) || \ + SAM_PART_IS_DEFINED(SAMD10C13A) || \ + SAM_PART_IS_DEFINED(SAMD10C14A) \ + ) + +#define SAMD10DS ( \ + SAM_PART_IS_DEFINED(SAMD10D12AS) || \ + SAM_PART_IS_DEFINED(SAMD10D13AS) || \ + SAM_PART_IS_DEFINED(SAMD10D14AS) \ + ) + +#define SAMD10DM ( \ + SAM_PART_IS_DEFINED(SAMD10D12AM) || \ + SAM_PART_IS_DEFINED(SAMD10D13AM) || \ + SAM_PART_IS_DEFINED(SAMD10D14AM) \ + ) +/** @} */ + +/** + * \name SAMD11 series + * @{ + */ +#define SAMD11C ( \ + SAM_PART_IS_DEFINED(SAMD11C14A) \ + ) + +#define SAMD11DS ( \ + SAM_PART_IS_DEFINED(SAMD11D14AS) \ + ) + +#define SAMD11DM ( \ + SAM_PART_IS_DEFINED(SAMD11D14AM) \ + ) +/** @} */ + +/** + * \name SAM4E series + * @{ + */ +#define SAM4E8 ( \ + SAM_PART_IS_DEFINED(SAM4E8C) || \ + SAM_PART_IS_DEFINED(SAM4E8E) \ + ) + +#define SAM4E16 ( \ + SAM_PART_IS_DEFINED(SAM4E16C) || \ + SAM_PART_IS_DEFINED(SAM4E16E) \ + ) +/** @} */ + +/** + * \name SAM4N series + * @{ + */ +#define SAM4N8 ( \ + SAM_PART_IS_DEFINED(SAM4N8A) || \ + SAM_PART_IS_DEFINED(SAM4N8B) || \ + SAM_PART_IS_DEFINED(SAM4N8C) \ + ) + +#define SAM4N16 ( \ + SAM_PART_IS_DEFINED(SAM4N16B) || \ + SAM_PART_IS_DEFINED(SAM4N16C) \ + ) +/** @} */ + +/** + * \name SAM4C series + * @{ + */ +#define SAM4C8_0 ( \ + SAM_PART_IS_DEFINED(SAM4C8C_0) \ + ) + +#define SAM4C8_1 ( \ + SAM_PART_IS_DEFINED(SAM4C8C_1) \ + ) + +#define SAM4C8 (SAM4C8_0 || SAM4C8_1) + +#define SAM4C16_0 ( \ + SAM_PART_IS_DEFINED(SAM4C16C_0) \ + ) + +#define SAM4C16_1 ( \ + SAM_PART_IS_DEFINED(SAM4C16C_1) \ + ) + +#define SAM4C16 (SAM4C16_0 || SAM4C16_1) + +#define SAM4C32_0 ( \ + SAM_PART_IS_DEFINED(SAM4C32C_0) ||\ + SAM_PART_IS_DEFINED(SAM4C32E_0) \ + ) + +#define SAM4C32_1 ( \ + SAM_PART_IS_DEFINED(SAM4C32C_1) ||\ + SAM_PART_IS_DEFINED(SAM4C32E_1) \ + ) + + +#define SAM4C32 (SAM4C32_0 || SAM4C32_1) + +/** @} */ + +/** + * \name SAM4CM series + * @{ + */ +#define SAM4CMP8_0 ( \ + SAM_PART_IS_DEFINED(SAM4CMP8C_0) \ + ) + +#define SAM4CMP8_1 ( \ + SAM_PART_IS_DEFINED(SAM4CMP8C_1) \ + ) + +#define SAM4CMP8 (SAM4CMP8_0 || SAM4CMP8_1) + +#define SAM4CMP16_0 ( \ + SAM_PART_IS_DEFINED(SAM4CMP16C_0) \ + ) + +#define SAM4CMP16_1 ( \ + SAM_PART_IS_DEFINED(SAM4CMP16C_1) \ + ) + +#define SAM4CMP16 (SAM4CMP16_0 || SAM4CMP16_1) + +#define SAM4CMP32_0 ( \ + SAM_PART_IS_DEFINED(SAM4CMP32C_0) \ + ) + +#define SAM4CMP32_1 ( \ + SAM_PART_IS_DEFINED(SAM4CMP32C_1) \ + ) + +#define SAM4CMP32 (SAM4CMP32_0 || SAM4CMP32_1) + +#define SAM4CMS8_0 ( \ + SAM_PART_IS_DEFINED(SAM4CMS8C_0) \ + ) + +#define SAM4CMS8_1 ( \ + SAM_PART_IS_DEFINED(SAM4CMS8C_1) \ + ) + +#define SAM4CMS8 (SAM4CMS8_0 || SAM4CMS8_1) + +#define SAM4CMS16_0 ( \ + SAM_PART_IS_DEFINED(SAM4CMS16C_0) \ + ) + +#define SAM4CMS16_1 ( \ + SAM_PART_IS_DEFINED(SAM4CMS16C_1) \ + ) + +#define SAM4CMS16 (SAM4CMS16_0 || SAM4CMS16_1) + +#define SAM4CMS32_0 ( \ + SAM_PART_IS_DEFINED(SAM4CMS32C_0) \ + ) + +#define SAM4CMS32_1 ( \ + SAM_PART_IS_DEFINED(SAM4CMS32C_1) \ + ) + +#define SAM4CMS32 (SAM4CMS32_0 || SAM4CMS32_1) + +/** @} */ + +/** + * \name SAM4CP series + * @{ + */ +#define SAM4CP16_0 ( \ + SAM_PART_IS_DEFINED(SAM4CP16B_0) \ + ) + +#define SAM4CP16_1 ( \ + SAM_PART_IS_DEFINED(SAM4CP16B_1) \ + ) + +#define SAM4CP16 (SAM4CP16_0 || SAM4CP16_1) +/** @} */ + +/** + * \name SAMG series + * @{ + */ +#define SAMG51 ( \ + SAM_PART_IS_DEFINED(SAMG51G18) \ + ) + +#define SAMG53 ( \ + SAM_PART_IS_DEFINED(SAMG53G19) ||\ + SAM_PART_IS_DEFINED(SAMG53N19) \ + ) + +#define SAMG54 ( \ + SAM_PART_IS_DEFINED(SAMG54G19) ||\ + SAM_PART_IS_DEFINED(SAMG54J19) ||\ + SAM_PART_IS_DEFINED(SAMG54N19) \ +) +/** @} */ +/** + * \name SAM families + * @{ + */ +/** SAM3S Family */ +#define SAM3S (SAM3S1 || SAM3S2 || SAM3S4 || SAM3S8 || SAM3SD8) + +/** SAM3U Family */ +#define SAM3U (SAM3U1 || SAM3U2 || SAM3U4) + +/** SAM3N Family */ +#define SAM3N (SAM3N00 || SAM3N0 || SAM3N1 || SAM3N2 || SAM3N4) + +/** SAM3XA Family */ +#define SAM3XA (SAM3X4 || SAM3X8 || SAM3A4 || SAM3A8) + +/** SAM4S Family */ +#define SAM4S (SAM4S2 || SAM4S4 || SAM4S8 || SAM4S16 || SAM4SA16 || SAM4SD16 || SAM4SD32) + +/** SAM4L Family */ +#define SAM4L (SAM4LS || SAM4LC) + +/** SAMD20 Family */ +#define SAMD20 (SAMD20J || SAMD20G || SAMD20E) + +/** SAMD21 Family */ +#define SAMD21 (SAMD21J || SAMD21G || SAMD21E) + +/** SAMD10 Family */ +#define SAMD10 (SAMD10C || SAMD10DS || SAMD10DM) + +/** SAMD11 Family */ +#define SAMD11 (SAMD11C || SAMD11DS || SAMD11DM) + +/** SAMD Family */ +#define SAMD (SAMD20 || SAMD21 || SAMD10 || SAMD11) + +/** SAMR21 Family */ +#define SAMR21 (SAMR21G || SAMR21E) + +/** SAM4E Family */ +#define SAM4E (SAM4E8 || SAM4E16) + +/** SAM4N Family */ +#define SAM4N (SAM4N8 || SAM4N16) + +/** SAM4C Family */ +#define SAM4C_0 (SAM4C8_0 || SAM4C16_0 || SAM4C32_0) +#define SAM4C_1 (SAM4C8_1 || SAM4C16_1 || SAM4C32_1) +#define SAM4C (SAM4C8 || SAM4C16 || SAM4C32) + +/** SAM4CM Family */ +#define SAM4CM_0 (SAM4CMP8_0 || SAM4CMP16_0 || SAM4CMP32_0 || SAM4CMS8_0 || \ + SAM4CMS16_0 || SAM4CMS32_0) +#define SAM4CM_1 (SAM4CMP8_1 || SAM4CMP16_1 || SAM4CMP32_1 || SAM4CMS8_1 || \ + SAM4CMS16_1 || SAM4CMS32_1) +#define SAM4CM (SAM4CMP8 || SAM4CMP16 || SAM4CMP32 || SAM4CMS8 || \ + SAM4CMS16 || SAM4CMS32) + +/** SAM4CP Family */ +#define SAM4CP_0 (SAM4CP16_0) +#define SAM4CP_1 (SAM4CP16_1) +#define SAM4CP (SAM4CP16) + +/** SAMG Family */ +#define SAMG (SAMG51 || SAMG53 || SAMG54) + +/** SAM0 product line (cortex-m0+) */ +#define SAM0 (SAMD20 || SAMD21 || SAMR21 || SAMD10 || SAMD11) + +/** @} */ + +/** SAM product line */ +#define SAM (SAM3S || SAM3U || SAM3N || SAM3XA || SAM4S || SAM4L || SAM4E || \ + SAM0 || SAM4N || SAM4C || SAM4CM || SAM4CP || SAMG) + +/** @} */ + +/** @} */ + +/** @} */ + +#endif /* ATMEL_PARTS_H */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/boards/samd21_xplained_pro/board_init.c b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/boards/samd21_xplained_pro/board_init.c new file mode 100644 index 0000000..f599a6b --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/boards/samd21_xplained_pro/board_init.c @@ -0,0 +1,99 @@ +/** + * \file + * + * \brief SAM D21 Xplained Pro board initialization + * + * Copyright (c) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include +#include +#include +#include + +#if defined(__GNUC__) +void board_init(void) WEAK __attribute__((alias("system_board_init"))); +#elif defined(__ICCARM__) +void board_init(void); +# pragma weak board_init=system_board_init +#endif + +void system_board_init(void) +{ + struct port_config pin_conf; + port_get_config_defaults(&pin_conf); + + /* Configure LEDs as outputs, turn them off */ + pin_conf.direction = PORT_PIN_DIR_OUTPUT; + port_pin_set_config(LED_0_PIN, &pin_conf); + port_pin_set_output_level(LED_0_PIN, LED_0_INACTIVE); + + pin_conf.direction = PORT_PIN_DIR_OUTPUT; + port_pin_set_config(LED_L_PIN, &pin_conf); + port_pin_set_output_level(LED_L_PIN, LED_0_INACTIVE); + + pin_conf.direction = PORT_PIN_DIR_OUTPUT; + port_pin_set_config(LED_RX_PIN, &pin_conf); + port_pin_set_output_level(LED_RX_PIN, LED_RX_INACTIVE); + + pin_conf.direction = PORT_PIN_DIR_OUTPUT; + port_pin_set_config(LED_TX_PIN, &pin_conf); + port_pin_set_output_level(LED_RX_PIN, LED_RX_INACTIVE); + + /* Set buttons as inputs */ + pin_conf.direction = PORT_PIN_DIR_INPUT; + pin_conf.input_pull = PORT_PIN_PULL_UP; + port_pin_set_config(BUTTON_0_PIN, &pin_conf); + +#ifdef CONF_BOARD_AT86RFX + port_get_config_defaults(&pin_conf); + pin_conf.direction = PORT_PIN_DIR_OUTPUT; + port_pin_set_config(AT86RFX_SPI_SCK, &pin_conf); + port_pin_set_config(AT86RFX_SPI_MOSI, &pin_conf); + port_pin_set_config(AT86RFX_SPI_CS, &pin_conf); + port_pin_set_config(AT86RFX_RST_PIN, &pin_conf); + port_pin_set_config(AT86RFX_SLP_PIN, &pin_conf); + port_pin_set_output_level(AT86RFX_SPI_SCK, true); + port_pin_set_output_level(AT86RFX_SPI_MOSI, true); + port_pin_set_output_level(AT86RFX_SPI_CS, true); + port_pin_set_output_level(AT86RFX_RST_PIN, true); + port_pin_set_output_level(AT86RFX_SLP_PIN, true); + pin_conf.direction = PORT_PIN_DIR_INPUT; + port_pin_set_config(AT86RFX_SPI_MISO, &pin_conf); +#endif +} diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/boards/samd21_xplained_pro/samd21_xplained_pro.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/boards/samd21_xplained_pro/samd21_xplained_pro.h new file mode 100644 index 0000000..0024c65 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/boards/samd21_xplained_pro/samd21_xplained_pro.h @@ -0,0 +1,756 @@ +/** + * \file + * + * \brief SAM D21 Xplained Pro board definition + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef SAMD21_XPLAINED_PRO_H_INCLUDED +#define SAMD21_XPLAINED_PRO_H_INCLUDED + +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \ingroup group_common_boards + * \defgroup samd21_xplained_pro_group SAM D21 Xplained Pro board + * + * @{ + */ + +void system_board_init(void); + +/** + * \defgroup samd21_xplained_pro_features_group Features + * + * Symbols that describe features and capabilities of the board. + * + * @{ + */ + +/** Name string macro */ +#define BOARD_NAME "SAMD21_XPLAINED_PRO" + +/** \name Resonator definitions + * @{ */ +#define BOARD_FREQ_SLCK_XTAL (32768U) +#define BOARD_FREQ_SLCK_BYPASS (32768U) +#define BOARD_FREQ_MAINCK_XTAL 0 /* Not Mounted */ +#define BOARD_FREQ_MAINCK_BYPASS 0 /* Not Mounted */ +#define BOARD_MCK CHIP_FREQ_CPU_MAX +#define BOARD_OSC_STARTUP_US 15625 +/** @} */ + +/** \name LED definitions + * @{ */ +#define LED0_PIN PIN_PA17 // only for compatibility, this pin is used also by L LED +#define LED0_ACTIVE false +#define LED0_INACTIVE !LED0_ACTIVE + +#define LEDL_PIN PIN_PA17 //defining LED L PORT PIN +#define LEDL_ACTIVE false +#define LEDL_INACTIVE !LEDL_ACTIVE + +#define LEDRX_PIN PIN_PB03 //defining LED RX PORT PIN +#define LEDRX_ACTIVE false +#define LEDRX_INACTIVE !LEDL_ACTIVE + +#define LEDTX_PIN PIN_PA27 //defining LED TX PORT PIN +#define LEDTX_ACTIVE false +#define LEDTX_INACTIVE !LEDL_ACTIVE + +/** @} */ + +/** \name SW0 definitions + * @{ */ +#define SW0_PIN PIN_PA15 +#define SW0_ACTIVE false +#define SW0_INACTIVE !SW0_ACTIVE +#define SW0_EIC_PIN PIN_PA15A_EIC_EXTINT15 +#define SW0_EIC_MUX MUX_PA15A_EIC_EXTINT15 +#define SW0_EIC_PINMUX PINMUX_PA15A_EIC_EXTINT15 +#define SW0_EIC_LINE 15 +/** @} */ + +/** + * \name LED #0 definitions + * + * Wrapper macros for LED0, to ensure common naming across all Xplained Pro + * boards. + * + * LED L, LED RX and LED TX are used by Arduino srl SAM D21 based boards. LED 0 remain only for compatibility. + * + * @{ */ +#define LED_0_NAME "LED0 (yellow)" +#define LED_0_PIN LED0_PIN +#define LED_0_ACTIVE LED0_ACTIVE +#define LED_0_INACTIVE LED0_INACTIVE +#define LED0_GPIO LED0_PIN +#define LED0 LED0_PIN + +#define LED_L_NAME "LED L" +#define LED_L_PIN LEDL_PIN +#define LED_L_ACTIVE LEDL_ACTIVE +#define LED_L_INACTIVE LEDL_INACTIVE +#define LEDL_GPIO LEDL_PIN +#define LEDL LEDL_PIN + +#define LED_RX_NAME "LED RX" +#define LED_RX_PIN LEDRX_PIN +#define LED_RX_ACTIVE LEDRX_ACTIVE +#define LED_RX_INACTIVE LEDRX_INACTIVE +#define LEDRX_GPIO LEDRX_PIN +#define LEDRX LEDRX_PIN + +#define LED_TX_NAME "LED L" +#define LED_TX_PIN LEDTX_PIN +#define LED_TX_ACTIVE LEDTX_ACTIVE +#define LED_TX_INACTIVE LEDTX_INACTIVE +#define LEDTX_GPIO LEDTX_PIN +#define LEDTX LEDTX_PIN + +#define LED_0_PWM4CTRL_MODULE TCC0 +#define LED_0_PWM4CTRL_CHANNEL 0 +#define LED_0_PWM4CTRL_OUTPUT 0 +#define LED_0_PWM4CTRL_PIN PIN_PB30E_TCC0_WO0 +#define LED_0_PWM4CTRL_MUX MUX_PB30E_TCC0_WO0 +#define LED_0_PWM4CTRL_PINMUX PINMUX_PB30E_TCC0_WO0 +/** @} */ + +/** Number of on-board LEDs */ +#define LED_COUNT 1 + +/** + * \name Serialflash definitions + * + * On board Serialflash definitions. + * + * @{ */ +#define SERIALFLASH_SPI_MODULE SERCOM5 +#define SERIALFLASH_SPI_MUX_SETTING SPI_SIGNAL_MUX_SETTING_E +#define SERIALFLASH_SPI_PINMUX_PAD0 PINMUX_PB16C_SERCOM5_PAD0 +#define SERIALFLASH_SPI_PINMUX_PAD1 PINMUX_UNUSED +#define SERIALFLASH_SPI_PINMUX_PAD2 PINMUX_PB22D_SERCOM5_PAD2 +#define SERIALFLASH_SPI_PINMUX_PAD3 PINMUX_PB23D_SERCOM5_PAD3 +#define SERIALFLASH_SPI_CS PIN_PA13 +/** @} */ + +/** + * \name Button #0 definitions + * + * Wrapper macros for SW0, to ensure common naming across all Xplained Pro + * boards. + * + * button 0 is used only for compatibility purpose, and are not used in Arduino srl SAM D21 Based Boards. + * @{ */ +#define BUTTON_0_NAME "SW0" +#define BUTTON_0_PIN SW0_PIN +#define BUTTON_0_ACTIVE SW0_ACTIVE +#define BUTTON_0_INACTIVE SW0_INACTIVE +#define BUTTON_0_EIC_PIN SW0_EIC_PIN +#define BUTTON_0_EIC_MUX SW0_EIC_MUX +#define BUTTON_0_EIC_PINMUX SW0_EIC_PINMUX +#define BUTTON_0_EIC_LINE SW0_EIC_LINE +/** @} */ + +/** Number of on-board buttons */ +#define BUTTON_COUNT 1 + +/** \name Extension header #1 pin definitions + * @{ + */ +#define EXT1_PIN_3 PIN_PB00 +#define EXT1_PIN_4 PIN_PB01 +#define EXT1_PIN_5 PIN_PB06 +#define EXT1_PIN_6 PIN_PB07 +#define EXT1_PIN_7 PIN_PB02 +#define EXT1_PIN_8 PIN_PB03 +#define EXT1_PIN_9 PIN_PB04 +#define EXT1_PIN_10 PIN_PB05 +#define EXT1_PIN_11 PIN_PA08 +#define EXT1_PIN_12 PIN_PA09 +#define EXT1_PIN_13 PIN_PB09 +#define EXT1_PIN_14 PIN_PB08 +#define EXT1_PIN_15 PIN_PA05 +#define EXT1_PIN_16 PIN_PA06 +#define EXT1_PIN_17 PIN_PA04 +#define EXT1_PIN_18 PIN_PA07 +/** @} */ + +/** \name Extension header #1 pin definitions by function + * @{ + */ +#define EXT1_PIN_ADC_0 EXT1_PIN_3 +#define EXT1_PIN_ADC_1 EXT1_PIN_4 +#define EXT1_PIN_GPIO_0 EXT1_PIN_5 +#define EXT1_PIN_GPIO_1 EXT1_PIN_6 +#define EXT1_PIN_PWM_0 EXT1_PIN_7 +#define EXT1_PIN_PWM_1 EXT1_PIN_8 +#define EXT1_PIN_IRQ EXT1_PIN_9 +#define EXT1_PIN_I2C_SDA EXT1_PIN_11 +#define EXT1_PIN_I2C_SCL EXT1_PIN_12 +#define EXT1_PIN_UART_RX EXT1_PIN_13 +#define EXT1_PIN_UART_TX EXT1_PIN_14 +#define EXT1_PIN_SPI_SS_1 EXT1_PIN_10 +#define EXT1_PIN_SPI_SS_0 EXT1_PIN_15 +#define EXT1_PIN_SPI_MOSI EXT1_PIN_16 +#define EXT1_PIN_SPI_MISO EXT1_PIN_17 +#define EXT1_PIN_SPI_SCK EXT1_PIN_18 +/** @} */ + +/** \name Extension header #1 ADC definitions + * @{ + */ +#define EXT1_ADC_MODULE ADC +#define EXT1_ADC_0_CHANNEL 8 +#define EXT1_ADC_0_PIN PIN_PB00B_ADC_AIN8 +#define EXT1_ADC_0_MUX MUX_PB00B_ADC_AIN8 +#define EXT1_ADC_0_PINMUX PINMUX_PB00B_ADC_AIN8 +#define EXT1_ADC_1_CHANNEL 9 +#define EXT1_ADC_1_PIN PIN_PB01B_ADC_AIN9 +#define EXT1_ADC_1_MUX MUX_PB01B_ADC_AIN9 +#define EXT1_ADC_1_PINMUX PINMUX_PB01B_ADC_AIN9 +/** @} */ + +/** \name Extension header #1 PWM definitions + * @{ + */ +#define EXT1_PWM_MODULE TC6 +#define EXT1_PWM_0_CHANNEL 0 +#define EXT1_PWM_0_PIN PIN_PB02E_TC6_WO0 +#define EXT1_PWM_0_MUX MUX_PB02E_TC6_WO0 +#define EXT1_PWM_0_PINMUX PINMUX_PB02E_TC6_WO0 +#define EXT1_PWM_1_CHANNEL 1 +#define EXT1_PWM_1_PIN PIN_PB03E_TC6_WO1 +#define EXT1_PWM_1_MUX MUX_PB03E_TC6_WO1 +#define EXT1_PWM_1_PINMUX PINMUX_PB03E_TC6_WO1 +/** @} */ + +/** \name Extension header #1 IRQ/External interrupt definitions + * @{ + */ +#define EXT1_IRQ_MODULE EIC +#define EXT1_IRQ_INPUT 4 +#define EXT1_IRQ_PIN PIN_PB04A_EIC_EXTINT4 +#define EXT1_IRQ_MUX MUX_PB04A_EIC_EXTINT4 +#define EXT1_IRQ_PINMUX PINMUX_PB04A_EIC_EXTINT4 +/** @} */ + +/** \name Extension header #1 I2C definitions + * @{ + */ +#define EXT1_I2C_MODULE SERCOM2 +#define EXT1_I2C_SERCOM_PINMUX_PAD0 PINMUX_PA08D_SERCOM2_PAD0 +#define EXT1_I2C_SERCOM_PINMUX_PAD1 PINMUX_PA09D_SERCOM2_PAD1 +#define EXT1_I2C_SERCOM_DMAC_ID_TX SERCOM2_DMAC_ID_TX +#define EXT1_I2C_SERCOM_DMAC_ID_RX SERCOM2_DMAC_ID_RX +/** @} */ + +/** \name Extension header #1 UART definitions + * @{ + */ +#define EXT1_UART_MODULE SERCOM4 +#define EXT1_UART_SERCOM_MUX_SETTING USART_RX_1_TX_0_XCK_1 +#define EXT1_UART_SERCOM_PINMUX_PAD0 PINMUX_PB08D_SERCOM4_PAD0 +#define EXT1_UART_SERCOM_PINMUX_PAD1 PINMUX_PB09D_SERCOM4_PAD1 +#define EXT1_UART_SERCOM_PINMUX_PAD2 PINMUX_UNUSED +#define EXT1_UART_SERCOM_PINMUX_PAD3 PINMUX_UNUSED +#define EXT1_UART_SERCOM_DMAC_ID_TX SERCOM4_DMAC_ID_TX +#define EXT1_UART_SERCOM_DMAC_ID_RX SERCOM4_DMAC_ID_RX +/** @} */ + +/** \name Extension header #1 SPI definitions + * @{ + */ +#define EXT1_SPI_MODULE SERCOM0 +#define EXT1_SPI_SERCOM_MUX_SETTING SPI_SIGNAL_MUX_SETTING_E +#define EXT1_SPI_SERCOM_PINMUX_PAD0 PINMUX_PA04D_SERCOM0_PAD0 +#define EXT1_SPI_SERCOM_PINMUX_PAD1 PINMUX_PA05D_SERCOM0_PAD1 +#define EXT1_SPI_SERCOM_PINMUX_PAD2 PINMUX_PA06D_SERCOM0_PAD2 +#define EXT1_SPI_SERCOM_PINMUX_PAD3 PINMUX_PA07D_SERCOM0_PAD3 +#define EXT1_SPI_SERCOM_DMAC_ID_TX SERCOM0_DMAC_ID_TX +#define EXT1_SPI_SERCOM_DMAC_ID_RX SERCOM0_DMAC_ID_RX +/** @} */ + +/** \name Extension header #2 pin definitions + * @{ + */ +#define EXT2_PIN_3 PIN_PA10 +#define EXT2_PIN_4 PIN_PA11 +#define EXT2_PIN_5 PIN_PA20 +#define EXT2_PIN_6 PIN_PA21 +#define EXT2_PIN_7 PIN_PB12 +#define EXT2_PIN_8 PIN_PB13 +#define EXT2_PIN_9 PIN_PB14 +#define EXT2_PIN_10 PIN_PB15 +#define EXT2_PIN_11 PIN_PA08 +#define EXT2_PIN_12 PIN_PA09 +#define EXT2_PIN_13 PIN_PB11 +#define EXT2_PIN_14 PIN_PB10 +#define EXT2_PIN_15 PIN_PA17 +#define EXT2_PIN_16 PIN_PA18 +#define EXT2_PIN_17 PIN_PA16 +#define EXT2_PIN_18 PIN_PA19 +/** @} */ + +/** \name Extension header #2 pin definitions by function + * @{ + */ +#define EXT2_PIN_ADC_0 EXT2_PIN_3 +#define EXT2_PIN_ADC_1 EXT2_PIN_4 +#define EXT2_PIN_GPIO_0 EXT2_PIN_5 +#define EXT2_PIN_GPIO_1 EXT2_PIN_6 +#define EXT2_PIN_PWM_0 EXT2_PIN_7 +#define EXT2_PIN_PWM_1 EXT2_PIN_8 +#define EXT2_PIN_IRQ EXT2_PIN_9 +#define EXT2_PIN_I2C_SDA EXT2_PIN_11 +#define EXT2_PIN_I2C_SCL EXT2_PIN_12 +#define EXT2_PIN_UART_RX EXT2_PIN_13 +#define EXT2_PIN_UART_TX EXT2_PIN_14 +#define EXT2_PIN_SPI_SS_1 EXT2_PIN_10 +#define EXT2_PIN_SPI_SS_0 EXT2_PIN_15 +#define EXT2_PIN_SPI_MOSI EXT2_PIN_16 +#define EXT2_PIN_SPI_MISO EXT2_PIN_17 +#define EXT2_PIN_SPI_SCK EXT2_PIN_18 +/** @} */ + +/** \name Extension header #2 ADC definitions + * @{ + */ +#define EXT2_ADC_MODULE ADC +#define EXT2_ADC_0_CHANNEL 18 +#define EXT2_ADC_0_PIN PIN_PA10B_ADC_AIN18 +#define EXT2_ADC_0_MUX MUX_PA10B_ADC_AIN18 +#define EXT2_ADC_0_PINMUX PINMUX_PA10B_ADC_AIN18 +#define EXT2_ADC_1_CHANNEL 19 +#define EXT2_ADC_1_PIN PIN_PA11B_ADC_AIN19 +#define EXT2_ADC_1_MUX MUX_PA11B_ADC_AIN19 +#define EXT2_ADC_1_PINMUX PINMUX_PA11B_ADC_AIN19 +/** @} */ + +/** \name Extension header #2 PWM definitions + * @{ + */ +#define EXT2_PWM_MODULE TC4 +#define EXT2_PWM_0_CHANNEL 0 +#define EXT2_PWM_0_PIN PIN_PB12E_TC4_WO0 +#define EXT2_PWM_0_MUX MUX_PB12E_TC4_WO0 +#define EXT2_PWM_0_PINMUX PINMUX_PB12E_TC4_WO0 +#define EXT2_PWM_1_CHANNEL 1 +#define EXT2_PWM_1_PIN PIN_PB13E_TC4_WO1 +#define EXT2_PWM_1_MUX MUX_PB13E_TC4_WO1 +#define EXT2_PWM_1_PINMUX PINMUX_PB13E_TC4_WO1 +/** @} */ + +/** \name Extension header #2 PWM for Control definitions + * @{ + */ +#define EXT2_PWM4CTRL_MODULE TCC0 +#define EXT2_PWM4CTRL_0_CHANNEL 2 +#define EXT2_PWM4CTRL_0_OUTPUT 6 +#define EXT2_PWM4CTRL_0_PIN PIN_PB12F_TCC0_WO6 +#define EXT2_PWM4CTRL_0_MUX MUX_PB12F_TCC0_WO6 +#define EXT2_PWM4CTRL_0_PINMUX PINMUX_PB12F_TCC0_WO6 +#define EXT2_PWM4CTRL_1_CHANNEL 3 +#define EXT2_PWM4CTRL_1_OUTPUT 7 +#define EXT2_PWM4CTRL_1_PIN PIN_PB13F_TCC0_WO7 +#define EXT2_PWM4CTRL_1_MUX MUX_PB13F_TCC0_WO7 +#define EXT2_PWM4CTRL_1_PINMUX PINMUX_PB13F_TCC0_WO7 +/** @} */ + +/** \name Extension header #2 IRQ/External interrupt definitions + * @{ + */ +#define EXT2_IRQ_MODULE EIC +#define EXT2_IRQ_INPUT 14 +#define EXT2_IRQ_PIN PIN_PB14A_EIC_EXTINT14 +#define EXT2_IRQ_MUX MUX_PB14A_EIC_EXTINT14 +#define EXT2_IRQ_PINMUX PINMUX_PB14A_EIC_EXTINT14 +/** @} */ + + /** \name Extension header #2 I2C definitions + * @{ + */ +#define EXT2_I2C_MODULE SERCOM2 +#define EXT2_I2C_SERCOM_PINMUX_PAD0 PINMUX_PA08D_SERCOM2_PAD0 +#define EXT2_I2C_SERCOM_PINMUX_PAD1 PINMUX_PA09D_SERCOM2_PAD1 +#define EXT2_I2C_SERCOM_DMAC_ID_TX SERCOM2_DMAC_ID_TX +#define EXT2_I2C_SERCOM_DMAC_ID_RX SERCOM2_DMAC_ID_RX +/** @} */ + +/** \name Extension header #2 UART definitions + * @{ + */ +#define EXT2_UART_MODULE SERCOM4 +#define EXT2_UART_SERCOM_MUX_SETTING USART_RX_1_TX_0_XCK_1 +#define EXT2_UART_SERCOM_PINMUX_PAD0 PINMUX_PB12C_SERCOM4_PAD0 +#define EXT2_UART_SERCOM_PINMUX_PAD1 PINMUX_PB13C_SERCOM4_PAD1 +#define EXT2_UART_SERCOM_PINMUX_PAD2 PINMUX_UNUSED +#define EXT2_UART_SERCOM_PINMUX_PAD3 PINMUX_UNUSED +#define EXT2_UART_SERCOM_DMAC_ID_TX SERCOM4_DMAC_ID_TX +#define EXT2_UART_SERCOM_DMAC_ID_RX SERCOM4_DMAC_ID_RX +/** @} */ + +/** \name Extension header #2 SPI definitions + * @{ + */ +#define EXT2_SPI_MODULE SERCOM1 +#define EXT2_SPI_SERCOM_MUX_SETTING SPI_SIGNAL_MUX_SETTING_E +#define EXT2_SPI_SERCOM_PINMUX_PAD0 PINMUX_PA16C_SERCOM1_PAD0 +#define EXT2_SPI_SERCOM_PINMUX_PAD1 PINMUX_PA17C_SERCOM1_PAD1 +#define EXT2_SPI_SERCOM_PINMUX_PAD2 PINMUX_PA18C_SERCOM1_PAD2 +#define EXT2_SPI_SERCOM_PINMUX_PAD3 PINMUX_PA19C_SERCOM1_PAD3 +#define EXT2_SPI_SERCOM_DMAC_ID_TX SERCOM1_DMAC_ID_TX +#define EXT2_SPI_SERCOM_DMAC_ID_RX SERCOM1_DMAC_ID_RX +/** @} */ + +/** \name Extension header #3 pin definitions + * @{ + */ +#define EXT3_PIN_3 PIN_PA02 +#define EXT3_PIN_4 PIN_PA03 +#define EXT3_PIN_5 PIN_PB30 +#define EXT3_PIN_6 PIN_PA15 +#define EXT3_PIN_7 PIN_PA12 +#define EXT3_PIN_8 PIN_PA13 +#define EXT3_PIN_9 PIN_PA28 +#define EXT3_PIN_10 PIN_PA27 +#define EXT3_PIN_11 PIN_PA08 +#define EXT3_PIN_12 PIN_PA09 +#define EXT3_PIN_13 PIN_PB11 +#define EXT3_PIN_14 PIN_PB10 +#define EXT3_PIN_15 PIN_PB17 +#define EXT3_PIN_16 PIN_PB22 +#define EXT3_PIN_17 PIN_PB16 +#define EXT3_PIN_18 PIN_PB23 +/** @} */ + +/** \name Extension header #3 pin definitions by function + * @{ + */ +#define EXT3_PIN_ADC_0 EXT3_PIN_3 +#define EXT3_PIN_ADC_1 EXT3_PIN_4 +#define EXT3_PIN_GPIO_0 EXT3_PIN_5 +#define EXT3_PIN_GPIO_1 EXT3_PIN_6 +#define EXT3_PIN_PWM_0 EXT3_PIN_7 +#define EXT3_PIN_PWM_1 EXT3_PIN_8 +#define EXT3_PIN_IRQ EXT3_PIN_9 +#define EXT3_PIN_I2C_SDA EXT3_PIN_11 +#define EXT3_PIN_I2C_SCL EXT3_PIN_12 +#define EXT3_PIN_UART_RX EXT3_PIN_13 +#define EXT3_PIN_UART_TX EXT3_PIN_14 +#define EXT3_PIN_SPI_SS_1 EXT3_PIN_10 +#define EXT3_PIN_SPI_SS_0 EXT3_PIN_15 +#define EXT3_PIN_SPI_MOSI EXT3_PIN_16 +#define EXT3_PIN_SPI_MISO EXT3_PIN_17 +#define EXT3_PIN_SPI_SCK EXT3_PIN_18 +/** @} */ + +/** \name Extension header #3 ADC definitions + * @{ + */ +#define EXT3_ADC_MODULE ADC +#define EXT3_ADC_0_CHANNEL 0 +#define EXT3_ADC_0_PIN PIN_PA02B_ADC_AIN0 +#define EXT3_ADC_0_MUX MUX_PA02B_ADC_AIN0 +#define EXT3_ADC_0_PINMUX PINMUX_PA02B_ADC_AIN0 +#define EXT3_ADC_1_CHANNEL 1 +#define EXT3_ADC_1_PIN PIN_PA03B_ADC_AIN1 +#define EXT3_ADC_1_MUX MUX_PA03B_ADC_AIN1 +#define EXT3_ADC_1_PINMUX PINMUX_PA03B_ADC_AIN1 +/** @} */ + +/** \name Extension header #3 PWM for Control definitions + * @{ + */ +#define EXT3_PWM4CTRL_MODULE TCC2 +#define EXT3_PWM4CTRL_0_CHANNEL 0 +#define EXT3_PWM4CTRL_0_OUTPUT 0 +#define EXT3_PWM4CTRL_0_PIN PIN_PA12E_TCC2_WO0 +#define EXT3_PWM4CTRL_0_MUX MUX_PA12E_TCC2_WO0 +#define EXT3_PWM4CTRL_0_PINMUX PINMUX_PA12E_TCC2_WO0 +#define EXT3_PWM4CTRL_1_CHANNEL 1 +#define EXT3_PWM4CTRL_1_OUTPUT 1 +#define EXT3_PWM4CTRL_1_PIN PIN_PA13E_TCC2_WO1 +#define EXT3_PWM4CTRL_1_MUX MUX_PA13E_TCC2_WO1 +#define EXT3_PWM4CTRL_1_PINMUX PINMUX_PA13E_TCC2_WO1 +/** @} */ + +/** \name Extension header #3 IRQ/External interrupt definitions + * @{ + */ +#define EXT3_IRQ_MODULE EIC +#define EXT3_IRQ_INPUT 8 +#define EXT3_IRQ_PIN PIN_PA28A_EIC_EXTINT8 +#define EXT3_IRQ_MUX MUX_PA28A_EIC_EXTINT8 +#define EXT3_IRQ_PINMUX PINMUX_PA28A_EIC_EXTINT8 +/** @} */ + +/** \name Extension header #3 I2C definitions + * @{ + */ +#define EXT3_I2C_MODULE SERCOM2 +#define EXT3_I2C_SERCOM_PINMUX_PAD0 PINMUX_PA08D_SERCOM2_PAD0 +#define EXT3_I2C_SERCOM_PINMUX_PAD1 PINMUX_PA09D_SERCOM2_PAD1 +#define EXT3_I2C_SERCOM_DMAC_ID_TX SERCOM2_DMAC_ID_TX +#define EXT3_I2C_SERCOM_DMAC_ID_RX SERCOM2_DMAC_ID_RX +/** @} */ + +/** \name Extension header #3 UART definitions + * @{ + */ +#define EXT3_UART_MODULE SERCOM4 +#define EXT3_UART_SERCOM_MUX_SETTING USART_RX_3_TX_2_XCK_3 +#define EXT3_UART_SERCOM_PINMUX_PAD0 PINMUX_UNUSED +#define EXT3_UART_SERCOM_PINMUX_PAD1 PINMUX_UNUSED +#define EXT3_UART_SERCOM_PINMUX_PAD2 PINMUX_PB10D_SERCOM4_PAD2 +#define EXT3_UART_SERCOM_PINMUX_PAD3 PINMUX_PB11D_SERCOM4_PAD3 +#define EXT3_UART_SERCOM_DMAC_ID_TX SERCOM4_DMAC_ID_TX +#define EXT3_UART_SERCOM_DMAC_ID_RX SERCOM4_DMAC_ID_RX +/** @} */ + +/** \name Extension header #3 SPI definitions + * @{ + */ +#define EXT3_SPI_MODULE SERCOM5 +#define EXT3_SPI_SERCOM_MUX_SETTING SPI_SIGNAL_MUX_SETTING_E +#define EXT3_SPI_SERCOM_PINMUX_PAD0 PINMUX_PB16C_SERCOM5_PAD0 +#define EXT3_SPI_SERCOM_PINMUX_PAD1 PINMUX_PB17C_SERCOM5_PAD1 +#define EXT3_SPI_SERCOM_PINMUX_PAD2 PINMUX_PB22D_SERCOM5_PAD2 +#define EXT3_SPI_SERCOM_PINMUX_PAD3 PINMUX_PB23D_SERCOM5_PAD3 +#define EXT3_SPI_SERCOM_DMAC_ID_TX SERCOM5_DMAC_ID_TX +#define EXT3_SPI_SERCOM_DMAC_ID_RX SERCOM5_DMAC_ID_RX +/** @} */ + +/** \name Extension header #3 Dataflash + * @{ + */ +#define EXT3_DATAFLASH_SPI_MODULE EXT3_SPI_MODULE +#define EXT3_DATAFLASH_SPI_MUX_SETTING EXT3_SPI_SERCOM_MUX_SETTING +#define EXT3_DATAFLASH_SPI_PINMUX_PAD0 EXT3_SPI_SERCOM_PINMUX_PAD0 +#define EXT3_DATAFLASH_SPI_PINMUX_PAD1 EXT3_SPI_SERCOM_PINMUX_PAD1 +#define EXT3_DATAFLASH_SPI_PINMUX_PAD2 EXT3_SPI_SERCOM_PINMUX_PAD2 +#define EXT3_DATAFLASH_SPI_PINMUX_PAD3 EXT3_SPI_SERCOM_PINMUX_PAD3 +/** @} */ + +/** \name USB definitions + * @{ + */ +#define USB_ID +#define USB_TARGET_DP_PIN PIN_PA25G_USB_DP +#define USB_TARGET_DP_MUX MUX_PA25G_USB_DP +#define USB_TARGET_DP_PINMUX PINMUX_PA25G_USB_DP +#define USB_TARGET_DM_PIN PIN_PA24G_USB_DM +#define USB_TARGET_DM_MUX MUX_PA24G_USB_DM +#define USB_TARGET_DM_PINMUX PINMUX_PA24G_USB_DM +#define USB_VBUS_PIN PIN_PA14 +#define USB_VBUS_EIC_LINE 14 +#define USB_VBUS_EIC_MUX MUX_PA14A_EIC_EXTINT14 +#define USB_VBUS_EIC_PINMUX PINMUX_PA14A_EIC_EXTINT14 +//#define USB_ID_PIN PIN_PA03 +#define USB_ID_EIC_LINE 3 +#define USB_ID_EIC_MUX MUX_PA03A_EIC_EXTINT3 +#define USB_ID_EIC_PINMUX PINMUX_PA03A_EIC_EXTINT3 +/** @} */ + +/** \name Embedded debugger GPIO interface definitions + * @{ + */ +#define EDBG_GPIO0_PIN PIN_PA27 +#define EDBG_GPIO1_PIN PIN_PA28 +#define EDBG_GPIO2_PIN PIN_PA20 +#define EDBG_GPIO3_PIN PIN_PA21 +/** @} */ + +/** \name Embedded debugger USART interface definitions + * @{ + */ +#define EDBG_UART_MODULE -1 /* Not available on this board */ +#define EDBG_UART_RX_PIN -1 /* Not available on this board */ +#define EDBG_UART_RX_MUX -1 /* Not available on this board */ +#define EDBG_UART_RX_PINMUX -1 /* Not available on this board */ +#define EDBG_UART_RX_SERCOM_PAD -1 /* Not available on this board */ +#define EDBG_UART_TX_PIN -1 /* Not available on this board */ +#define EDBG_UART_TX_MUX -1 /* Not available on this board */ +#define EDBG_UART_TX_PINMUX -1 /* Not available on this board */ +#define EDBG_UART_TX_SERCOM_PAD -1 /* Not available on this board */ +/** @} */ + +/** \name Embedded debugger I2C interface definitions + * @{ + */ +#define EDBG_I2C_MODULE SERCOM2 +#define EDBG_I2C_SERCOM_PINMUX_PAD0 PINMUX_PA08D_SERCOM2_PAD0 +#define EDBG_I2C_SERCOM_PINMUX_PAD1 PINMUX_PA09D_SERCOM2_PAD1 +#define EDBG_I2C_SERCOM_DMAC_ID_TX SERCOM2_DMAC_ID_TX +#define EDBG_I2C_SERCOM_DMAC_ID_RX SERCOM2_DMAC_ID_RX +/** @} */ + +/** \name Embedded debugger SPI interface definitions + * @{ + */ +#define EDBG_SPI_MODULE SERCOM5 +#define EDBG_SPI_SERCOM_MUX_SETTING SPI_SIGNAL_MUX_SETTING_E +#define EDBG_SPI_SERCOM_PINMUX_PAD0 PINMUX_PB16C_SERCOM5_PAD0 +#define EDBG_SPI_SERCOM_PINMUX_PAD1 PINMUX_PB31D_SERCOM5_PAD1 +#define EDBG_SPI_SERCOM_PINMUX_PAD2 PINMUX_PB22D_SERCOM5_PAD2 +#define EDBG_SPI_SERCOM_PINMUX_PAD3 PINMUX_PB23D_SERCOM5_PAD3 +#define EDBG_SPI_SERCOM_DMAC_ID_TX SERCOM5_DMAC_ID_TX +#define EDBG_SPI_SERCOM_DMAC_ID_RX SERCOM5_DMAC_ID_RX +/** @} */ + +/** \name Embedded debugger CDC Gateway USART interface definitions + * @{ + */ +#define EDBG_CDC_MODULE SERCOM3 +#define EDBG_CDC_SERCOM_MUX_SETTING USART_RX_1_TX_0_XCK_1 +#define EDBG_CDC_SERCOM_PINMUX_PAD0 PINMUX_PA22C_SERCOM3_PAD0 +#define EDBG_CDC_SERCOM_PINMUX_PAD1 PINMUX_PA23C_SERCOM3_PAD1 +#define EDBG_CDC_SERCOM_PINMUX_PAD2 PINMUX_UNUSED +#define EDBG_CDC_SERCOM_PINMUX_PAD3 PINMUX_UNUSED +#define EDBG_CDC_SERCOM_DMAC_ID_TX SERCOM3_DMAC_ID_TX +#define EDBG_CDC_SERCOM_DMAC_ID_RX SERCOM3_DMAC_ID_RX +/** @} */ + +/** @} */ + +/** \name 802.15.4 TRX Interface definitions + * @{ + */ + +#define AT86RFX_SPI EXT1_SPI_MODULE +#define AT86RFX_RST_PIN EXT1_PIN_7 +#define AT86RFX_MISC_PIN EXT1_PIN_12 +#define AT86RFX_IRQ_PIN EXT1_PIN_9 +#define AT86RFX_SLP_PIN EXT1_PIN_10 +#define AT86RFX_SPI_CS EXT1_PIN_15 +#define AT86RFX_SPI_MOSI EXT1_PIN_16 +#define AT86RFX_SPI_MISO EXT1_PIN_17 +#define AT86RFX_SPI_SCK EXT1_PIN_18 +#define AT86RFX_CSD EXT1_PIN_5 +#define AT86RFX_CPS EXT1_PIN_8 + + +#define AT86RFX_SPI_CONFIG(config) \ + config.mux_setting = EXT1_SPI_SERCOM_MUX_SETTING; \ + config.mode_specific.master.baudrate = AT86RFX_SPI_BAUDRATE; \ + config.pinmux_pad0 = EXT1_SPI_SERCOM_PINMUX_PAD0; \ + config.pinmux_pad1 = PINMUX_UNUSED; \ + config.pinmux_pad2 = EXT1_SPI_SERCOM_PINMUX_PAD2; \ + config.pinmux_pad3 = EXT1_SPI_SERCOM_PINMUX_PAD3; + +#define AT86RFX_IRQ_CHAN EXT1_IRQ_INPUT +#define AT86RFX_INTC_INIT() \ + struct extint_chan_conf eint_chan_conf; \ + extint_chan_get_config_defaults(&eint_chan_conf); \ + eint_chan_conf.gpio_pin = AT86RFX_IRQ_PIN; \ + eint_chan_conf.gpio_pin_mux = EXT1_IRQ_PINMUX; \ + eint_chan_conf.gpio_pin_pull = EXTINT_PULL_NONE; \ + eint_chan_conf.wake_if_sleeping = true; \ + eint_chan_conf.filter_input_signal = false; \ + eint_chan_conf.detection_criteria = EXTINT_DETECT_RISING; \ + extint_chan_set_config(AT86RFX_IRQ_CHAN, &eint_chan_conf); \ + extint_register_callback(AT86RFX_ISR, AT86RFX_IRQ_CHAN, EXTINT_CALLBACK_TYPE_DETECT);\ + extint_chan_enable_callback(AT86RFX_IRQ_CHAN, EXTINT_CALLBACK_TYPE_DETECT); + + +/** Enables the transceiver main interrupt. */ +#define ENABLE_TRX_IRQ() \ + extint_chan_enable_callback(AT86RFX_IRQ_CHAN, EXTINT_CALLBACK_TYPE_DETECT) + +/** Disables the transceiver main interrupt. */ +#define DISABLE_TRX_IRQ() \ + extint_chan_disable_callback(AT86RFX_IRQ_CHAN, EXTINT_CALLBACK_TYPE_DETECT) + +/** Clears the transceiver main interrupt. */ +#define CLEAR_TRX_IRQ() \ + extint_chan_clear_detected(AT86RFX_IRQ_CHAN); + +/* + * This macro saves the trx interrupt status and disables the trx interrupt. + */ +#define ENTER_TRX_REGION() \ + { extint_chan_disable_callback(AT86RFX_IRQ_CHAN, EXTINT_CALLBACK_TYPE_DETECT) + +/* + * This macro restores the transceiver interrupt status + */ +#define LEAVE_TRX_REGION() \ + extint_chan_enable_callback(AT86RFX_IRQ_CHAN, EXTINT_CALLBACK_TYPE_DETECT); } + +/** @} */ + +/** + * \brief Turns off the specified LEDs. + * + * \param led_gpio LED to turn off (LEDx_GPIO). + * + * \note The pins of the specified LEDs are set to GPIO output mode. + */ +#define LED_Off(led_gpio) port_pin_set_output_level(led_gpio,true) + +/** + * \brief Turns on the specified LEDs. + * + * \param led_gpio LED to turn on (LEDx_GPIO). + * + * \note The pins of the specified LEDs are set to GPIO output mode. + */ +#define LED_On(led_gpio) port_pin_set_output_level(led_gpio,false) + +/** + * \brief Toggles the specified LEDs. + * + * \param led_gpio LED to toggle (LEDx_GPIO). + * + * \note The pins of the specified LEDs are set to GPIO output mode. + */ +#define LED_Toggle(led_gpio) port_pin_toggle_output_level(led_gpio) + +/** @} */ + +#ifdef __cplusplus +} +#endif + +#endif /* SAMD21_XPLAINED_PRO_H_INCLUDED */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/port/port.c b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/port/port.c new file mode 100644 index 0000000..3841973 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/port/port.c @@ -0,0 +1,106 @@ +/** + * \file + * + * \brief SAM GPIO Port Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include + +/** + * \brief Writes a Port pin configuration to the hardware module. + * + * Writes out a given configuration of a Port pin configuration to the hardware + * module. + * + * \note If the pin direction is set as an output, the pull-up/pull-down input + * configuration setting is ignored. + * + * \param[in] gpio_pin Index of the GPIO pin to configure. + * \param[in] config Configuration settings for the pin. + */ +void port_pin_set_config( + const uint8_t gpio_pin, + const struct port_config *const config) +{ + /* Sanity check arguments */ + Assert(config); + + struct system_pinmux_config pinmux_config; + system_pinmux_get_config_defaults(&pinmux_config); + + pinmux_config.mux_position = SYSTEM_PINMUX_GPIO; + pinmux_config.direction = (enum system_pinmux_pin_dir)config->direction; + pinmux_config.input_pull = (enum system_pinmux_pin_pull)config->input_pull; + pinmux_config.powersave = config->powersave; + + system_pinmux_pin_set_config(gpio_pin, &pinmux_config); +} + +/** + * \brief Writes a Port group configuration group to the hardware module. + * + * Writes out a given configuration of a Port group configuration to the + * hardware module. + * + * \note If the pin direction is set as an output, the pull-up/pull-down input + * configuration setting is ignored. + * + * \param[out] port Base of the PORT module to write to. + * \param[in] mask Mask of the port pin(s) to configure. + * \param[in] config Configuration settings for the pin group. + */ +void port_group_set_config( + PortGroup *const port, + const uint32_t mask, + const struct port_config *const config) +{ + /* Sanity check arguments */ + Assert(port); + Assert(config); + + struct system_pinmux_config pinmux_config; + system_pinmux_get_config_defaults(&pinmux_config); + + pinmux_config.mux_position = SYSTEM_PINMUX_GPIO; + pinmux_config.direction = (enum system_pinmux_pin_dir)config->direction; + pinmux_config.input_pull = (enum system_pinmux_pin_pull)config->input_pull; + pinmux_config.powersave = config->powersave; + + system_pinmux_group_set_config(port, mask, &pinmux_config); +} diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/port/port.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/port/port.h new file mode 100644 index 0000000..87495b5 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/port/port.h @@ -0,0 +1,564 @@ +/** + * \file + * + * \brief SAM GPIO Port Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef PORT_H_INCLUDED +#define PORT_H_INCLUDED + +/** + * \defgroup asfdoc_sam0_port_group SAM Port Driver (PORT) + * + * This driver for SAM devices provides an interface for the configuration + * and management of the device's General Purpose Input/Output (GPIO) pin + * functionality, for manual pin state reading and writing. + * + * The following peripherals are used by this module: + * - PORT (GPIO Management) + * + * The following devices can use this module: + * - SAM D20/D21 + * - SAM R21 + * - SAM D10/D11 + * + * The outline of this documentation is as follows: + * - \ref asfdoc_sam0_port_prerequisites + * - \ref asfdoc_sam0_port_module_overview + * - \ref asfdoc_sam0_port_special_considerations + * - \ref asfdoc_sam0_port_extra_info + * - \ref asfdoc_sam0_port_examples + * - \ref asfdoc_sam0_port_api_overview + * + * + * \section asfdoc_sam0_port_prerequisites Prerequisites + * + * There are no prerequisites for this module. + * + * + * \section asfdoc_sam0_port_module_overview Module Overview + * + * The device GPIO (PORT) module provides an interface between the user + * application logic and external hardware peripherals, when general pin state + * manipulation is required. This driver provides an easy-to-use interface to + * the physical pin input samplers and output drivers, so that pins can be read + * from or written to for general purpose external hardware control. + * + * \subsection asfdoc_sam0_port_module_overview_pin_numbering Physical and Logical GPIO Pins + * SAM devices use two naming conventions for the I/O pins in the device; one + * physical, and one logical. Each physical pin on a device package is assigned + * both a physical port and pin identifier (e.g. "PORTA.0") as well as a + * monotonically incrementing logical GPIO number (e.g. "GPIO0"). While the + * former is used to map physical pins to their physical internal device module + * counterparts, for simplicity the design of this driver uses the logical GPIO + * numbers instead. + * + * \subsection asfdoc_sam0_port_module_overview_physical Physical Connection + * + * \ref asfdoc_sam0_port_module_int_connections "The diagram below" shows how + * this module is interconnected within the device. + * + * \anchor asfdoc_sam0_port_module_int_connections + * \dot + * digraph overview { + * node [label="Port Pad" shape=square] pad; + * + * subgraph driver { + * node [label="Peripheral Mux" shape=trapezium] pinmux; + * node [label="GPIO Module" shape=ellipse] gpio; + * node [label="Other Peripheral Modules" shape=ellipse style=filled fillcolor=lightgray] peripherals; + * } + * + * pinmux -> gpio; + * pad -> pinmux; + * pinmux -> peripherals; + * } + * \enddot + * + * + * \section asfdoc_sam0_port_special_considerations Special Considerations + * + * The SAM port pin input sampler can be disabled when the pin is configured + * in pure output mode to save power; reading the pin state of a pin configured + * in output-only mode will read the logical output state that was last set. + * + * \section asfdoc_sam0_port_extra_info Extra Information + * + * For extra information see \ref asfdoc_sam0_port_extra. This includes: + * - \ref asfdoc_sam0_port_extra_acronyms + * - \ref asfdoc_sam0_port_extra_dependencies + * - \ref asfdoc_sam0_port_extra_errata + * - \ref asfdoc_sam0_port_extra_history + * + * + * \section asfdoc_sam0_port_examples Examples + * + * For a list of examples related to this driver, see + * \ref asfdoc_sam0_port_exqsg. + * + * + * \section asfdoc_sam0_port_api_overview API Overview + * @{ + */ + +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** \name PORT Alias Macros + * @{ + */ + +/** Convenience definition for GPIO module group A on the device (if + * available). */ +#if (PORT_GROUPS > 0) || defined(__DOXYGEN__) +# define PORTA PORT->Group[0] +#endif + +#if (PORT_GROUPS > 1) || defined(__DOXYGEN__) +/** Convenience definition for GPIO module group B on the device (if + * available). */ +# define PORTB PORT->Group[1] +#endif + +#if (PORT_GROUPS > 2) || defined(__DOXYGEN__) +/** Convenience definition for GPIO module group C on the device (if + * available). */ +# define PORTC PORT->Group[2] +#endif + +#if (PORT_GROUPS > 3) || defined(__DOXYGEN__) +/** Convenience definition for GPIO module group D on the device (if + * available). */ +# define PORTD PORT->Group[3] +#endif + +/** @} */ + +/** + * \brief Port pin direction configuration enum. + * + * Enum for the possible pin direction settings of the port pin configuration + * structure, to indicate the direction the pin should use. + */ +enum port_pin_dir { + /** The pin's input buffer should be enabled, so that the pin state can + * be read. */ + PORT_PIN_DIR_INPUT = SYSTEM_PINMUX_PIN_DIR_INPUT, + /** The pin's output buffer should be enabled, so that the pin state can + * be set. */ + PORT_PIN_DIR_OUTPUT = SYSTEM_PINMUX_PIN_DIR_OUTPUT, + /** The pin's output and input buffers should be enabled, so that the pin + * state can be set and read back. */ + PORT_PIN_DIR_OUTPUT_WTH_READBACK = SYSTEM_PINMUX_PIN_DIR_OUTPUT_WITH_READBACK, +}; + +/** + * \brief Port pin input pull configuration enum. + * + * Enum for the possible pin pull settings of the port pin configuration + * structure, to indicate the type of logic level pull the pin should use. + */ +enum port_pin_pull { + /** No logical pull should be applied to the pin. */ + PORT_PIN_PULL_NONE = SYSTEM_PINMUX_PIN_PULL_NONE, + /** Pin should be pulled up when idle. */ + PORT_PIN_PULL_UP = SYSTEM_PINMUX_PIN_PULL_UP, + /** Pin should be pulled down when idle. */ + PORT_PIN_PULL_DOWN = SYSTEM_PINMUX_PIN_PULL_DOWN, +}; + +/** + * \brief Port pin configuration structure. + * + * Configuration structure for a port pin instance. This structure should be + * initialized by the \ref port_get_config_defaults() function before being + * modified by the user application. + */ +struct port_config { + /** Port buffer input/output direction. */ + enum port_pin_dir direction; + + /** Port pull-up/pull-down for input pins. */ + enum port_pin_pull input_pull; + + /** Enable lowest possible powerstate on the pin + * + * \note All other configurations will be ignored, the pin will be disabled + */ + bool powersave; +}; + +/** \name State reading/writing (physical group orientated) + * @{ + */ + +/** + * \brief Retrieves the PORT module group instance from a given GPIO pin number. + * + * Retrieves the PORT module group instance associated with a given logical + * GPIO pin number. + * + * \param[in] gpio_pin Index of the GPIO pin to convert. + * + * \return Base address of the associated PORT module. + */ +static inline PortGroup* port_get_group_from_gpio_pin( + const uint8_t gpio_pin) +{ + return system_pinmux_get_group_from_gpio_pin(gpio_pin); +} + +/** + * \brief Retrieves the state of a group of port pins that are configured as inputs. + * + * Reads the current logic level of a port module's pins and returns the + * current levels as a bitmask. + * + * \param[in] port Base of the PORT module to read from. + * \param[in] mask Mask of the port pin(s) to read. + * + * \return Status of the port pin(s) input buffers. + */ +static inline uint32_t port_group_get_input_level( + const PortGroup *const port, + const uint32_t mask) +{ + /* Sanity check arguments */ + Assert(port); + + return (port->IN.reg & mask); +} + +/** + * \brief Retrieves the state of a group of port pins that are configured as outputs. + * + * Reads the current logical output level of a port module's pins and returns + * the current levels as a bitmask. + * + * \param[in] port Base of the PORT module to read from. + * \param[in] mask Mask of the port pin(s) to read. + * + * \return Status of the port pin(s) output buffers. + */ +static inline uint32_t port_group_get_output_level( + const PortGroup *const port, + const uint32_t mask) +{ + /* Sanity check arguments */ + Assert(port); + + return (port->OUT.reg & mask); +} + +/** + * \brief Sets the state of a group of port pins that are configured as outputs. + * + * Sets the current output level of a port module's pins to a given logic + * level. + * + * \param[out] port Base of the PORT module to write to. + * \param[in] mask Mask of the port pin(s) to change. + * \param[in] level_mask Mask of the port level(s) to set. + */ +static inline void port_group_set_output_level( + PortGroup *const port, + const uint32_t mask, + const uint32_t level_mask) +{ + /* Sanity check arguments */ + Assert(port); + + port->OUTSET.reg = (mask & level_mask); + port->OUTCLR.reg = (mask & ~level_mask); +} + +/** + * \brief Toggles the state of a group of port pins that are configured as an outputs. + * + * Toggles the current output levels of a port module's pins. + * + * \param[out] port Base of the PORT module to write to. + * \param[in] mask Mask of the port pin(s) to toggle. + */ +static inline void port_group_toggle_output_level( + PortGroup *const port, + const uint32_t mask) +{ + /* Sanity check arguments */ + Assert(port); + + port->OUTTGL.reg = mask; +} + +/** @} */ + +/** \name Configuration and initialization + * @{ + */ + +/** + * \brief Initializes a Port pin/group configuration structure to defaults. + * + * Initializes a given Port pin/group configuration structure to a set of + * known default values. This function should be called on all new + * instances of these configuration structures before being modified by the + * user application. + * + * The default configuration is as follows: + * \li Input mode with internal pullup enabled + * + * \param[out] config Configuration structure to initialize to default values. + */ +static inline void port_get_config_defaults( + struct port_config *const config) +{ + /* Sanity check arguments */ + Assert(config); + + /* Default configuration values */ + config->direction = PORT_PIN_DIR_INPUT; + config->input_pull = PORT_PIN_PULL_UP; + config->powersave = false; +} + +void port_pin_set_config( + const uint8_t gpio_pin, + const struct port_config *const config); + +void port_group_set_config( + PortGroup *const port, + const uint32_t mask, + const struct port_config *const config); + +/** @} */ + +/** \name State reading/writing (logical pin orientated) + * @{ + */ + +/** + * \brief Retrieves the state of a port pin that is configured as an input. + * + * Reads the current logic level of a port pin and returns the current + * level as a boolean value. + * + * \param[in] gpio_pin Index of the GPIO pin to read. + * + * \return Status of the port pin's input buffer. + */ +static inline bool port_pin_get_input_level( + const uint8_t gpio_pin) +{ + PortGroup *const port_base = port_get_group_from_gpio_pin(gpio_pin); + uint32_t pin_mask = (1UL << (gpio_pin % 32)); + + return (port_base->IN.reg & pin_mask); +} + +/** + * \brief Retrieves the state of a port pin that is configured as an output. + * + * Reads the current logical output level of a port pin and returns the current + * level as a boolean value. + * + * \param[in] gpio_pin Index of the GPIO pin to read. + * + * \return Status of the port pin's output buffer. + */ +static inline bool port_pin_get_output_level( + const uint8_t gpio_pin) +{ + PortGroup *const port_base = port_get_group_from_gpio_pin(gpio_pin); + uint32_t pin_mask = (1UL << (gpio_pin % 32)); + + return (port_base->OUT.reg & pin_mask); +} + +/** + * \brief Sets the state of a port pin that is configured as an output. + * + * Sets the current output level of a port pin to a given logic level. + * + * \param[in] gpio_pin Index of the GPIO pin to write to. + * \param[in] level Logical level to set the given pin to. + */ +static inline void port_pin_set_output_level( + const uint8_t gpio_pin, + const bool level) +{ + PortGroup *const port_base = port_get_group_from_gpio_pin(gpio_pin); + uint32_t pin_mask = (1UL << (gpio_pin % 32)); + + /* Set the pin to high or low atomically based on the requested level */ + if (level) { + port_base->OUTSET.reg = pin_mask; + } else { + port_base->OUTCLR.reg = pin_mask; + } +} + +/** + * \brief Toggles the state of a port pin that is configured as an output. + * + * Toggles the current output level of a port pin. + * + * \param[in] gpio_pin Index of the GPIO pin to toggle. + */ +static inline void port_pin_toggle_output_level( + const uint8_t gpio_pin) +{ + PortGroup *const port_base = port_get_group_from_gpio_pin(gpio_pin); + uint32_t pin_mask = (1UL << (gpio_pin % 32)); + + /* Toggle pin output level */ + port_base->OUTTGL.reg = pin_mask; +} + +/** @} */ + +#ifdef __cplusplus +} +#endif + +/** @} */ + +/** + * \page asfdoc_sam0_port_extra Extra Information for PORT Driver + * + * \section asfdoc_sam0_port_extra_acronyms Acronyms + * Below is a table listing the acronyms used in this module, along with their + * intended meanings. + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
AcronymDescription
GPIOGeneral Purpose Input/Output
MUXMultiplexer
+ * + * + * \section asfdoc_sam0_port_extra_dependencies Dependencies + * This driver has the following dependencies: + * + * - \ref asfdoc_sam0_system_pinmux_group "System Pin Multiplexer Driver" + * + * + * \section asfdoc_sam0_port_extra_errata Errata + * There are no errata related to this driver. + * + * + * \section asfdoc_sam0_port_extra_history Module History + * An overview of the module history is presented in the table below, with + * details on the enhancements and fixes made to the module since its first + * release. The current version of this corresponds to the newest version in + * the table. + * + * + * + * + * + * + * + * + * + * + * + *
Changelog
Added support for SAMD21
Initial Release
+ */ + +/** + * \page asfdoc_sam0_port_exqsg Examples for PORT Driver + * + * This is a list of the available Quick Start guides (QSGs) and example + * applications for \ref asfdoc_sam0_port_group. QSGs are simple examples with + * step-by-step instructions to configure and use this driver in a selection of + * use cases. Note that QSGs can be compiled as a standalone application or be + * added to the user application. + * + * - \subpage asfdoc_sam0_port_basic_use_case + * + * \page asfdoc_sam0_port_document_revision_history Document Revision History + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Doc. Rev. + * Date + * Comments + *
E04/2014Added support for SAMD10/D11.
D02/2014Added support for SAMR21.
C01/2014Added support for SAMD21.
B06/2013Corrected documentation typos.
A06/2013Initial release
+ */ + +#endif diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/port/quick_start/qs_port_basic.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/port/quick_start/qs_port_basic.h new file mode 100644 index 0000000..70f3845 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/port/quick_start/qs_port_basic.h @@ -0,0 +1,105 @@ +/** + * \file + * + * \brief SAM GPIO Port Driver Quick Start + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +/** + * \page asfdoc_sam0_port_basic_use_case Quick Start Guide for PORT - Basic + * + * In this use case, the PORT module is configured for: + * \li One pin in input mode, with pull-up enabled + * \li One pin in output mode + * + * This use case sets up the PORT to read the current state of a GPIO pin set as + * an input, and mirrors the opposite logical state on a pin configured as an + * output. + * + * \section asfdoc_sam0_port_basic_use_case_setup Setup + * + * \subsection asfdoc_sam0_port_basic_use_case_setup_prereq Prerequisites + * There are no special setup requirements for this use-case. + * + * \subsection asfdoc_sam0_port_basic_use_case_setup_code Code + * Copy-paste the following setup code to your user application: + * \snippet qs_port_basic.c setup + * + * Add to user application initialization (typically the start of \c main()): + * \snippet qs_port_basic.c setup_init + * + * \subsection asfdoc_sam0_port_basic_use_case_setup_flow Workflow + * -# Create a PORT module pin configuration struct, which can be filled out to + * adjust the configuration of a single port pin. + * \snippet qs_port_basic.c setup_1 + * -# Initialize the pin configuration struct with the module's default values. + * \snippet qs_port_basic.c setup_2 + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Adjust the configuration struct to request an input pin. + * \snippet qs_port_basic.c setup_3 + * -# Configure push button pin with the initialized pin configuration struct, to enable + * the input sampler on the pin. + * \snippet qs_port_basic.c setup_4 + * -# Adjust the configuration struct to request an output pin. + * \snippet qs_port_basic.c setup_5 + * \note The existing configuration struct may be re-used, as long as any + * values that have been altered from the default settings are taken + * into account by the user application. + * + * -# Configure LED pin with the initialized pin configuration struct, to enable + * the output driver on the pin. + * \snippet qs_port_basic.c setup_6 + * + * \section asfdoc_sam0_port_basic_use_case_use_main Use Case + * + * \subsection asfdoc_sam0_port_basic_use_case_code Code + * Copy-paste the following code to your user application: + * \snippet qs_port_basic.c main + * + * \subsection asfdoc_sam0_port_basic_use_case_flow Workflow + * -# Read in the current input sampler state of push button pin, which has been + * configured as an input in the use-case setup code. + * \snippet qs_port_basic.c main_1 + * -# Write the inverted pin level state to LED pin, which has been configured as + * an output in the use-case setup code. + * \snippet qs_port_basic.c main_2 + */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/rtc/quick_start_count/qs_rtc_count_basic.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/rtc/quick_start_count/qs_rtc_count_basic.h new file mode 100644 index 0000000..a29d544 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/rtc/quick_start_count/qs_rtc_count_basic.h @@ -0,0 +1,117 @@ +/** + * \file + * + * \brief SAM RTC Count Quick Start + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +/** + * \page asfdoc_sam0_rtc_count_basic_use_case Quick Start Guide for RTC (COUNT) - Basic + * In this use case, the RTC is set up in count mode. The example configures the + * RTC in 16 bit mode, with continuous updates to the COUNT register, together + * with a set compare register value. Every 2000ms a LED on the board is + * toggled. + * + * \section asfdoc_sam0_rtc_count_basic_use_case_prereq Prerequisites + * The Generic Clock Generator for the RTC should be configured and enabled; if + * you are using the System Clock driver, this may be done via \c conf_clocks.h. + * + * \subsection asfdoc_sam0_rtc_count_basic_use_case_setup_clocks Clocks and Oscillators + * The \c conf_clock.h file needs to be changed with the following values to + * configure the clocks and oscillators for the module. + * + * The following oscillator settings are needed: + * \snippet conf_clocks.h oscillator_settings + * The following generic clock settings are needed: + * \snippet conf_clocks.h gclk_settings + * + * \section asfdoc_sam0_rtc_count_basic_use_case_setup Setup + * + * \subsection asfdoc_sam0_rtc_count_basic_use_case_init_code Initialization Code + * Create a rtc_module struct and add to the main application source file, + * outside of any functions: + * \snippet qs_rtc_count_basic.c rtc_module_instance + * + * Copy-paste the following setup code to your applications \c main(): + * \snippet qs_rtc_count_basic.c initiate + * + * \subsection asfdoc_sam0_rtc_count_basic_use_case_main_code Add to Main + * Add the following to your \c main(). + * \snippet qs_rtc_count_basic.c add_main + * + * \subsection rtc_count_basic_use_workflow Workflow + * -# Create a RTC configuration structure to hold the desired RTC driver + * settings. + * \snippet qs_rtc_count_basic.c set_conf + * -# Fill the configuration structure with the default driver configuration. + * \snippet qs_rtc_count_basic.c get_default + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Alter the RTC driver configuration to run in 16-bit counting mode, with + * continuous counter register updates. + * \snippet qs_rtc_count_basic.c set_config + * -# Initialize the RTC module. + * \snippet qs_rtc_count_basic.c init_rtc + * -# Enable the RTC module, so that it may begin counting. + * \snippet qs_rtc_count_basic.c enable + * + * \section asfdoc_sam0_rtc_count_basic_use_case_implement Implementation + * Code used to implement the initialized module. + * + * \subsection asfdoc_sam0_rtc_count_basic_use_case_imp_code Code + * Add after initialization in main(). + * \snippet qs_rtc_count_basic.c implementation_code + * + * \subsection asfdoc_sam0_rtc_count_basic_use_case_imp_workflow Workflow + * -# Set RTC period to 2000ms (2 seconds) so that it will overflow and reset + * back to zero every two seconds. + * \snippet qs_rtc_count_basic.c period + * -# Enter an infinite loop to poll the RTC driver to check when a comparison + * match occurs. + * \snippet qs_rtc_count_basic.c main_loop + * -# Check if the RTC driver has found a match on compare channel 0 against the + * current RTC count value. + * \snippet qs_rtc_count_basic.c check_match + * -# Once a compare match occurs, perform the desired user action. + * \snippet qs_rtc_count_basic.c compare_match_action + * -# Clear the compare match, so that future matches may occur. + * \snippet qs_rtc_count_basic.c clear_compare_match + */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/rtc/quick_start_count_callback/qs_rtc_count_callback.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/rtc/quick_start_count_callback/qs_rtc_count_callback.h new file mode 100644 index 0000000..4f80d7b --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/rtc/quick_start_count_callback/qs_rtc_count_callback.h @@ -0,0 +1,128 @@ +/** + * \file + * + * \brief SAM RTC Count Quick Start + * + * Copyright (C) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +/** + * \page asfdoc_sam0_rtc_count_callback_use_case Quick Start Guide for RTC (COUNT) - Callback + * + * In this use case, the RTC is set up in count mode. The quick start + * configures the RTC in 16 bit mode and to continuously update COUNT register. + * The rest of the configuration is according to the + * \ref rtc_count_get_config_defaults "default". + * A callback is implemented for when the RTC overflows. + * + * \section asfdoc_sam0_rtc_count_callback_use_case_prereq Prerequisites + * The Generic Clock Generator for the RTC should be configured and enabled; if + * you are using the System Clock driver, this may be done via \c conf_clocks.h. + * + * \subsection asfdoc_sam0_rtc_count_callback_use_case_setup_clocks Clocks and Oscillators + * The \c conf_clock.h file needs to be changed with the following values to + * configure the clocks and oscillators for the module. + * + * The following oscillator settings are needed: + * \snippet conf_clocks.h oscillator_settings + * The following generic clock settings are needed: + * \snippet conf_clocks.h gclk_settings + * + * \section asfdoc_sam0_rtc_count_callback_use_case_setup Setup + * + * \subsection asfdoc_sam0_rtc_count_callback_use_case_setup_code Code + * Create a rtc_module struct and add to the main application source file, + * outside of any functions: + * \snippet qs_rtc_count_callback.c rtc_module_instance + * The following must be added to the user application: + * + * Function for setting up the module: + * \snippet qs_rtc_count_callback.c initialize_rtc + * + * Callback function: + * \snippet qs_rtc_count_callback.c callback + * + * Function for setting up the callback functionality of the driver: + * \snippet qs_rtc_count_callback.c setup_callback +* + * Add to user application main(): + * \snippet qs_rtc_count_callback.c run_initialize_rtc + * + * \subsection asfdoc_sam0_rtc_count_callback_use_case_setup_workflow Workflow + * -# Initialize system. + * \snippet qs_rtc_count_callback.c system_init + * -# Configure and enable module. + * \snippet qs_rtc_count_callback.c run_conf + * -# Create a RTC configuration structure to hold the desired RTC driver + * settings and fill it with the default driver configuration values. + * \snippet qs_rtc_count_callback.c init_conf + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Alter the RTC driver configuration to run in 16-bit counting mode, with + * continuous counter register updates and a compare value of 1000ms. + * \snippet qs_rtc_count_callback.c set_config + * -# Initialize the RTC module. + * \snippet qs_rtc_count_callback.c init_rtc + * -# Enable the RTC module, so that it may begin counting. + * \snippet qs_rtc_count_callback.c enable + * -# Configure callback functionality. + * \snippet qs_rtc_count_callback.c run_callback + * -# Register overflow callback. + * \snippet qs_rtc_count_callback.c reg_callback + * -# Enable overflow callback. + * \snippet qs_rtc_count_callback.c en_callback + * -# Set period. + * \snippet qs_rtc_count_callback.c period + * + * \section asfdoc_sam0_rtc_count_callback_use_case_implementation Implementation + * + * \subsection asfdoc_sam0_rtc_count_callback_use_case_implementation_code Code + * Add to user application main: + * \snippet qs_rtc_count_callback.c while + * \subsection asfdoc_sam0_rtc_count_callback_use_case_implementation_workflow Workflow + * -# Infinite while loop while waiting for callbacks. + * \snippet qs_rtc_count_callback.c while + * + * \section asfdoc_sam0_rtc_count_callback_use_case_callback Callback + * Each time the RTC counter overflows, the callback function will be called. + * \subsection asfdoc_sam0_rtc_count_callback_use_case_callback_workflow Workflow + * -# Perform the desired user action for each RTC overflow: + * \snippet qs_rtc_count_callback.c overflow_act + */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/rtc/rtc_count.c b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/rtc/rtc_count.c new file mode 100644 index 0000000..3e3f2d0 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/rtc/rtc_count.c @@ -0,0 +1,684 @@ +/** + * \file + * + * \brief SAM RTC Driver (Count Mode) + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include "rtc_count.h" +#include + +#if !defined(__DOXYGEN__) +struct rtc_module *_rtc_instance[RTC_INST_NUM]; +#endif + +/** + * \brief Resets the RTC module. + * Resets the RTC to hardware defaults. + * + * \param[in,out] module Pointer to the software instance struct + */ +void rtc_count_reset(struct rtc_module *const module) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Disable module before reset. */ + rtc_count_disable(module); + +#if RTC_COUNT_ASYNC == true + module->registered_callback = 0; + module->enabled_callback = 0; +#endif + + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + + /* Initiate software reset. */ + rtc_module->MODE0.CTRL.reg |= RTC_MODE0_CTRL_SWRST; +} + +/** + * \internal Applies the given configuration. + * + * Sets the configurations given from the configuration structure to the + * hardware module + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] config Pointer to the configuration structure. + * + * \return Status of the configuration procedure. + * \retval STATUS_OK RTC configurations was set successfully. + * \retval STATUS_ERR_INVALID_ARG If invalid argument(s) were given. + */ +static enum status_code _rtc_count_set_config( + struct rtc_module *const module, + const struct rtc_count_config *const config) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + rtc_module->MODE0.CTRL.reg = RTC_MODE0_CTRL_MODE(0) | config->prescaler; + + /* Set mode and clear on match if applicable. */ + switch (config->mode) { + case RTC_COUNT_MODE_32BIT: + /* Set 32bit mode and clear on match if applicable. */ + rtc_module->MODE0.CTRL.reg |= RTC_MODE0_CTRL_MODE(0); + + /* Check if clear on compare match should be set. */ + if (config->clear_on_match) { + /* Set clear on match. */ + rtc_module->MODE0.CTRL.reg |= RTC_MODE0_CTRL_MATCHCLR; + } + /* Set compare values. */ + for (uint8_t i = 0; i < RTC_NUM_OF_COMP32; i++) { + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + + rtc_count_set_compare(module, config->compare_values[i], + (enum rtc_count_compare)i); + } + break; + + case RTC_COUNT_MODE_16BIT: + /* Set 16bit mode. */ + rtc_module->MODE1.CTRL.reg |= RTC_MODE1_CTRL_MODE(1); + + /* Check if match on clear is set, and return invalid + * argument if set. */ + if (config->clear_on_match) { + Assert(false); + return STATUS_ERR_INVALID_ARG; + } + /* Set compare values. */ + for (uint8_t i = 0; i < RTC_NUM_OF_COMP16; i++) { + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + + rtc_count_set_compare(module, config->compare_values[i], + (enum rtc_count_compare)i); + } + break; + default: + Assert(false); + return STATUS_ERR_INVALID_ARG; + } + + /* Check to set continuously clock read update mode. */ + if (config->continuously_update) { + /* Set continuously mode. */ + rtc_module->MODE0.READREQ.reg |= RTC_READREQ_RCONT; + } + + /* Return status OK if everything was configured. */ + return STATUS_OK; +} + +/** + * \brief Initializes the RTC module with given configurations. + * + * Initializes the module, setting up all given configurations to provide + * the desired functionality of the RTC. + * + * \param[out] module Pointer to the software instance struct + * \param[in] hw Pointer to hardware instance + * \param[in] config Pointer to the configuration structure. + * + * \return Status of the initialization procedure. + * \retval STATUS_OK If the initialization was run stressfully. + * \retval STATUS_ERR_INVALID_ARG If invalid argument(s) were given. + */ +enum status_code rtc_count_init( + struct rtc_module *const module, + Rtc *const hw, + const struct rtc_count_config *const config) +{ + /* Sanity check arguments */ + Assert(module); + Assert(hw); + Assert(config); + + /* Initialize device instance */ + module->hw = hw; + + /* Turn on the digital interface clock */ + system_apb_clock_set_mask(SYSTEM_CLOCK_APB_APBA, PM_APBAMASK_RTC); + + /* Set up GCLK */ + struct system_gclk_chan_config gclk_chan_conf; + system_gclk_chan_get_config_defaults(&gclk_chan_conf); + gclk_chan_conf.source_generator = GCLK_GENERATOR_2; + system_gclk_chan_set_config(RTC_GCLK_ID, &gclk_chan_conf); + system_gclk_chan_enable(RTC_GCLK_ID); + + /* Reset module to hardware defaults. */ + rtc_count_reset(module); + + /* Save conf_struct internally for continued use. */ + module->mode = config->mode; + module->continuously_update = config->continuously_update; + +# if (RTC_INST_NUM == 1) + _rtc_instance[0] = module; +# else + /* Register this instance for callbacks*/ + _rtc_instance[_rtc_get_inst_index(hw)] = module; +# endif + + /* Set config and return status. */ + return _rtc_count_set_config(module, config); +} + +/** + * \brief Set the current count value to desired value. + * + * Sets the value of the counter to the specified value. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] count_value The value to be set in count register. + * + * \return Status of setting the register. + * \retval STATUS_OK If everything was executed correctly. + * \retval STATUS_ERR_INVALID_ARG If invalid argument(s) were provided. + */ +enum status_code rtc_count_set_count( + struct rtc_module *const module, + const uint32_t count_value) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + + /* Set count according to mode */ + switch(module->mode){ + case RTC_COUNT_MODE_32BIT: + /* Write value to register. */ + rtc_module->MODE0.COUNT.reg = count_value; + + break; + + case RTC_COUNT_MODE_16BIT: + /* Check if 16 bit value is provided. */ + if(count_value > 0xffff){ + return STATUS_ERR_INVALID_ARG; + } + + /* Write value to register. */ + rtc_module->MODE1.COUNT.reg = (uint32_t)count_value; + + break; + + default: + Assert(false); + return STATUS_ERR_INVALID_ARG; + } + return STATUS_OK; +} + +/** + * \brief Get the current count value. + * + * \param[in,out] module Pointer to the software instance struct + * + * Returns the current count value. + * + * \return The current counter value as a 32 bit unsigned integer. + */ +uint32_t rtc_count_get_count(struct rtc_module *const module) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Initialize return value. */ + uint32_t ret_val; + + /* Change of read method based on value of continuously_update value in + * the configuration structure. */ + if(!(module->continuously_update)) { + /* Request read on count register. */ + rtc_module->MODE0.READREQ.reg = RTC_READREQ_RREQ; + + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + } + + /* Read value based on mode. */ + switch (module->mode) { + case RTC_COUNT_MODE_32BIT: + /* Return count value in 32 bit mode. */ + ret_val = rtc_module->MODE0.COUNT.reg; + + break; + + case RTC_COUNT_MODE_16BIT: + /* Return count value in 16 bit mode. */ + ret_val = (uint32_t)rtc_module->MODE1.COUNT.reg; + + break; + + default: + Assert(false); + /* Counter not initialized. Assume counter value 0.*/ + ret_val = 0; + break; + } + + return ret_val; +} + +/** + * \brief Set the compare value for the specified compare. + * + * Sets the value specified by the implementer to the requested compare. + * + * \note Compare 4 and 5 are only available in 16 bit mode. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] comp_value The value to be written to the compare. + * \param[in] comp_index Index of the compare to set. + * + * \return Status indicating if compare was successfully set. + * \retval STATUS_OK If compare was successfully set. + * \retval STATUS_ERR_INVALID_ARG If invalid argument(s) were provided. + * \retval STATUS_ERR_BAD_FORMAT If the module was not initialized in a mode. + */ +enum status_code rtc_count_set_compare( + struct rtc_module *const module, + const uint32_t comp_value, + const enum rtc_count_compare comp_index) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + + /* Set compare values based on operation mode. */ + switch (module->mode) { + case RTC_COUNT_MODE_32BIT: + /* Check sanity of comp_index. */ + if ((uint32_t)comp_index > RTC_NUM_OF_COMP32) { + return STATUS_ERR_INVALID_ARG; + } + + /* Set compare value for COMP. */ + rtc_module->MODE0.COMP[comp_index].reg = comp_value; + + break; + + case RTC_COUNT_MODE_16BIT: + /* Check sanity of comp_index. */ + if ((uint32_t)comp_index > RTC_NUM_OF_COMP16) { + return STATUS_ERR_INVALID_ARG; + } + + /* Check that 16 bit value is provided. */ + if (comp_value > 0xffff) { + Assert(false); + return STATUS_ERR_INVALID_ARG; + } + + /* Set compare value for COMP. */ + rtc_module->MODE1.COMP[comp_index].reg = comp_value & 0xffff; + + break; + + default: + Assert(false); + return STATUS_ERR_BAD_FORMAT; + } + + /* Return status if everything is OK. */ + return STATUS_OK; +} + +/** + * \brief Get the current compare value of specified compare. + * + * Retrieves the current value of the specified compare. + * + * \note Compare 4 and 5 are only available in 16 bit mode. + * + * \param[in,out] module Pointer to the software instance struct + * \param[out] comp_value Pointer to 32 bit integer that will be populated with + * the current compare value. + * \param[in] comp_index Index of compare to check. + * + * \return Status of the reading procedure. + * \retval STATUS_OK If the value was read correctly. + * \retval STATUS_ERR_INVALID_ARG If invalid argument(s) were provided. + * \retval STATUS_ERR_BAD_FORMAT If the module was not initialized in a mode. + */ +enum status_code rtc_count_get_compare( + struct rtc_module *const module, + uint32_t *const comp_value, + const enum rtc_count_compare comp_index) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + switch (module->mode) { + case RTC_COUNT_MODE_32BIT: + /* Check sanity of comp_index. */ + if ((uint32_t)comp_index > RTC_NUM_OF_COMP32) { + return STATUS_ERR_INVALID_ARG; + } + + /* Get compare value for COMP. */ + *comp_value = rtc_module->MODE0.COMP[comp_index].reg; + + break; + + case RTC_COUNT_MODE_16BIT: + /* Check sanity of comp_index. */ + if ((uint32_t)comp_index > RTC_NUM_OF_COMP16) { + return STATUS_ERR_INVALID_ARG; + } + + /* Get compare value for COMP. */ + *comp_value = (uint32_t)rtc_module->MODE1.COMP[comp_index].reg; + + break; + + default: + Assert(false); + return STATUS_ERR_BAD_FORMAT; + } + /* Return status showing everything is OK. */ + return STATUS_OK; +} + +/** + * \brief Retrieves the value of period. + * + * Retrieves the value of the period for the 16 bit mode counter. + * + * \note Only available in 16 bit mode. + * + * \param[in,out] module Pointer to the software instance struct + * \param[out] period_value Pointer to value for return argument. + * + * \return Status of getting the period value. + * \retval STATUS_OK If the period value was read correctly. + * \retval STATUS_ERR_UNSUPPORTED_DEV If incorrect mode was set. + */ +enum status_code rtc_count_get_period( + struct rtc_module *const module, + uint16_t *const period_value) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Check that correct mode is set. */ + if (module->mode != RTC_COUNT_MODE_16BIT) { + return STATUS_ERR_UNSUPPORTED_DEV; + } + + /* Returns the value. */ + *period_value = rtc_module->MODE1.PER.reg; + + return STATUS_OK; +} + +/** + * \brief Set the given value to the period. + * + * Sets the given value to the period. + * + * \note Only available in 16 bit mode. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] period_value The value to set to the period. + * + * \return Status of setting the period value. + * \retval STATUS_OK If the period was set correctly. + * \retval STATUS_ERR_UNSUPPORTED_DEV If module is not operated in 16 bit mode. + */ +enum status_code rtc_count_set_period( + struct rtc_module *const module, + const uint16_t period_value) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Check that correct mode is set. */ + if (module->mode != RTC_COUNT_MODE_16BIT) { + return STATUS_ERR_UNSUPPORTED_DEV; + } + + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + + /* Write value to register. */ + rtc_module->MODE1.PER.reg = period_value; + + return STATUS_OK; +} + +/** + * \brief Check if RTC compare match has occurred. + * + * Checks the compare flag to see if a match has occurred. The compare flag is + * set when there is a compare match between counter and the compare. + * + * \note Compare 4 and 5 are only available in 16 bit mode. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] comp_index Index of compare to check current flag. + */ +bool rtc_count_is_compare_match( + struct rtc_module *const module, + const enum rtc_count_compare comp_index) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Check sanity. */ + switch (module->mode) { + case RTC_COUNT_MODE_32BIT: + /* Check sanity for 32 bit mode. */ + if (comp_index > RTC_NUM_OF_COMP32) { + return false; + } + + break; + + case RTC_COUNT_MODE_16BIT: + /* Check sanity for 16 bit mode. */ + if (comp_index > RTC_NUM_OF_COMP16) { + return false; + } + + break; + + default: + Assert(false); + return false; + } + + /* Set status of INTFLAG as return argument. */ + return (rtc_module->MODE0.INTFLAG.reg & (1 << comp_index)); +} + +/** + * \brief Clears RTC compare match flag. + * + * Clears the compare flag. The compare flag is set when there is a compare + * match between the counter and the compare. + * + * \note Compare 4 and 5 are only available in 16 bit mode. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] comp_index Index of compare to check current flag. + * + * \return Status indicating if flag was successfully cleared. + * \retval STATUS_OK If flag was successfully cleared. + * \retval STATUS_ERR_INVALID_ARG If invalid argument(s) were provided. + * \retval STATUS_ERR_BAD_FORMAT If the module was not initialized in a mode. + */ +enum status_code rtc_count_clear_compare_match( + struct rtc_module *const module, + const enum rtc_count_compare comp_index) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Check sanity. */ + switch (module->mode){ + case RTC_COUNT_MODE_32BIT: + /* Check sanity for 32 bit mode. */ + if (comp_index > RTC_NUM_OF_COMP32) { + return STATUS_ERR_INVALID_ARG; + } + + break; + + case RTC_COUNT_MODE_16BIT: + /* Check sanity for 16 bit mode. */ + if (comp_index > RTC_NUM_OF_COMP16) { + return STATUS_ERR_INVALID_ARG; + } + + break; + + default: + Assert(false); + return STATUS_ERR_BAD_FORMAT; + } + + /* Clear INTFLAG. */ + rtc_module->MODE0.INTFLAG.reg = RTC_MODE1_INTFLAG_CMP(1 << comp_index); + + return STATUS_OK; +} + +/** + * \brief Calibrate for too-slow or too-fast oscillator. + * + * When used, the RTC will compensate for an inaccurate oscillator. The + * RTC module will add or subtract cycles from the RTC prescaler to adjust the + * frequency in approximately 1 PPM steps. The provided correction value should + * be between 0 and 127, allowing for a maximum 127 PPM correction. + * + * If no correction is needed, set value to zero. + * + * \note Can only be used when the RTC is operated in 1Hz. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] value Ranging from -127 to 127 used for the correction. + * + * \return Status of the calibration procedure. + * \retval STATUS_OK If calibration was executed correctly. + * \retval STATUS_ERR_INVALID_ARG If invalid argument(s) were provided. + */ +enum status_code rtc_count_frequency_correction( + struct rtc_module *const module, + const int8_t value) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Check if valid argument. */ + if (abs(value) > 0x7F) { + /* Value bigger than allowed, return invalid argument. */ + return STATUS_ERR_INVALID_ARG; + } + + uint32_t new_correction_value; + + /* Load the new correction value as a positive value, sign added later */ + new_correction_value = abs(value); + + /* Convert to positive value and adjust register sign bit. */ + if (value < 0) { + new_correction_value |= RTC_FREQCORR_SIGN; + } + + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + + /* Set value. */ + rtc_module->MODE0.FREQCORR.reg = new_correction_value; + + return STATUS_OK; +} + diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/rtc/rtc_count.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/rtc/rtc_count.h new file mode 100644 index 0000000..b7bf010 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/rtc/rtc_count.h @@ -0,0 +1,935 @@ +/** + * \file + * + * \brief SAM RTC Driver (Count Mode) + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef RTC_COUNT_H_INCLUDED +#define RTC_COUNT_H_INCLUDED + +/** + * \defgroup asfdoc_sam0_rtc_count_group SAM RTC Count Driver (RTC COUNT) + * + * This driver for SAM devices provides an interface for the configuration + * and management of the device's Real Time Clock functionality in Count + * operating mode, for the configuration and retrieval of the current RTC + * counter value. The following driver API modes are covered by this + * manual: + * + * - Polled APIs + * \if RTC_COUNT_CALLBACK_MODE + * - Callback APIs + * \endif + * + * The following peripherals are used by this module: + * - RTC (Real Time Clock) + * + * The following devices can use this module: + * - SAM D20/D21 + * - SAM R21 + * - SAM D10/D11 + * + * The outline of this documentation is as follows: + * - \ref asfdoc_sam0_rtc_count_prerequisites + * - \ref asfdoc_sam0_rtc_count_module_overview + * - \ref asfdoc_sam0_rtc_count_special_considerations + * - \ref asfdoc_sam0_rtc_count_extra_info + * - \ref asfdoc_sam0_rtc_count_examples + * - \ref asfdoc_sam0_rtc_count_api_overview + * + * + * \section asfdoc_sam0_rtc_count_prerequisites Prerequisites + * + * There are no prerequisites for this module. + * + * + * \section asfdoc_sam0_rtc_count_module_overview Module Overview + * + * The RTC module in the SAM devices is a 32-bit counter, with a 10-bit + * programmable prescaler. Typically, the RTC clock is run continuously, + * including in the device's low-power sleep modes, to track the current time + * and date information. The RTC can be used as a source to wake up the system + * at a scheduled time or periodically using the alarm functions. + * + * In this driver, the RTC is operated in Count mode. This allows for an + * easy integration of an asynchronous counter into a user application, which is + * capable of operating while the device is in sleep mode. + * + * Whilst operating in Count mode, the RTC features: + * - 16-bit counter mode + * - Selectable counter period + * - Up to 6 configurable compare values + * - 32-bit counter mode + * - Clear counter value on match + * - Up to 4 configurable compare values + * + * + * \section asfdoc_sam0_rtc_count_module_overview_compares Compare and Overflow + * The RTC can be used with up to 4/6 compare values (depending on selected + * operation mode). These compare values will trigger on match with the current + * RTC counter value, and can be set up to trigger an interrupt, event, or both. + * The RTC can also be configured to clear the counter value on compare match + * in 32-bit mode, resetting the count value back to zero. + * + * If the RTC is operated without the Clear on Match option enabled, or in + * 16-bit mode, the RTC counter value will instead be cleared on overflow once + * the maximum count value has been reached: + * + * \f[ COUNT_{MAX} = 2^{32}-1 \f] for 32-bit counter mode, and + * \f[ COUNT_{MAX} = 2^{16}-1 \f] for 16-bit counter mode. + * + * When running in 16-bit mode, the overflow value is selectable with a period + * value. The counter overflow will then occur when the counter value reaches + * the specified period value. + * + * \subsection asfdoc_sam0_rtc_count_module_overview_periodic Periodic Events + * The RTC can generate events at periodic intervals, allowing for direct + * peripheral actions without CPU intervention. The periodic events can be + * generated on the upper 8 bits of the RTC prescaler, and will be generated on + * the rising edge transition of the specified bit. The resulting periodic + * frequency can be calculated by the following formula: + * + * \f[ f_{PERIODIC}=\frac{f_{ASY}}{2^{n+3}} \f] + * + * Where \f$f_{ASY}\f$ refers to the \e asynchronous clock set up in the RTC + * module configuration. The \b n parameter is the event source generator index + * of the RTC module. If the asynchronous clock is operated at the recommended + * frequency of 1 KHz, the formula results in the values shown in + * \ref asfdoc_sam0_rtc_count_module_rtc_hz "the table below". + * + * \anchor asfdoc_sam0_rtc_count_module_rtc_hz + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
RTC event frequencies for each prescaler bit using a 1KHz clock
n Periodic event
7 1 Hz
6 2 Hz
5 4 Hz
4 8 Hz
3 16 Hz
2 32 Hz
1 64 Hz
0 128 Hz
+ * + * \note The connection of events between modules requires the use of the + * \ref asfdoc_sam0_events_group "SAM Event System Driver (EVENTS)" + * to route output event of one module to the the input event of another. + * For more information on event routing, refer to the event driver + * documentation. + * + * \subsection asfdoc_sam0_rtc_count_module_overview_correction Digital Frequency Correction + * The RTC module contains Digital Frequency Correction logic to compensate for + * inaccurate source clock frequencies which would otherwise result in skewed + * time measurements. The correction scheme requires that at least two bits + * in the RTC module prescaler are reserved by the correction logic. As a + * result of this implementation, frequency correction is only available when + * the RTC is running from a 1 Hz reference clock. + * + * The correction procedure is implemented by subtracting or adding a single + * cycle from the RTC prescaler every 1024 RTC GCLK cycles. The adjustment is + * applied the specified number of time (max 127) over 976 of these periods. The + * corresponding correction in PPM will be given by: + * + * \f[ Correction(PPM) = \frac{VALUE}{999424}10^6 \f] + * + * The RTC clock will tick faster if provided with a positive correction value, + * and slower when given a negative correction value. + * + * + * \section asfdoc_sam0_rtc_count_special_considerations Special Considerations + * + * \subsection asfdoc_sam0_rtc_count_special_considerations_clock Clock Setup + * The RTC is typically clocked by a specialized GCLK generator that has a + * smaller prescaler than the others. By default the RTC clock is on, selected + * to use the internal 32 KHz RC-oscillator with a prescaler of 32, giving a + * resulting clock frequency of 1 KHz to the RTC. When the internal RTC + * prescaler is set to 1024, this yields an end-frequency of 1 Hz. + * + * The implementer also has the option to set other end-frequencies. + * \ref asfdoc_sam0_rtc_count_rtc_out_freq "The table below" lists the + * available RTC frequencies for each possible GCLK and RTC input prescaler + * options. + * + * \anchor asfdoc_sam0_rtc_count_rtc_out_freq + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
RTC output frequencies from allowable input clocks
End-frequencyGCLK prescalerRTC Prescaler
32 KHz11
1 KHz321
1 Hz321024
+ * + * The overall RTC module clocking scheme is shown in + * \ref asfdoc_sam0_rtc_count_rtc_clock_fig "the figure below". + * + * \anchor asfdoc_sam0_rtc_count_rtc_clock_fig + * \dot + * digraph clocking_scheme { + * rankdir=LR; + * GCLK [shape="record", label=" GCLK | RTC_GCLK", + * bgcolor="lightgray", style="filled"]; + * RTCPRE [shape="record" label=" RTC | RTC PRESCALER"]; + * RTC [shape="record", label=" RTC | RTC CLOCK"]; + * + * GCLK:f1 -> RTCPRE:f1; + * RTCPRE:f1 -> RTC:f1; + * } + * \enddot + * + * + * \section asfdoc_sam0_rtc_count_extra_info Extra Information + * + * For extra information see \ref asfdoc_sam0_rtc_count_extra. This includes: + * - \ref asfdoc_sam0_rtc_count_extra_acronyms + * - \ref asfdoc_sam0_rtc_count_extra_dependencies + * - \ref asfdoc_sam0_rtc_count_extra_errata + * - \ref asfdoc_sam0_rtc_count_extra_history + * + * + * \section asfdoc_sam0_rtc_count_examples Examples + * + * For a list of examples related to this driver, see + * \ref asfdoc_sam0_rtc_count_exqsg. + * + * + * \section asfdoc_sam0_rtc_count_api_overview API Overview + * @{ + */ + +#include +#include + +#if RTC_COUNT_ASYNC == true +# include +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \brief Available operation modes for the RTC. + * + * RTC Count operating modes, to select the counting width and associated module + * operation. + */ +enum rtc_count_mode { + /** RTC Count module operates in 16-bit mode. */ + RTC_COUNT_MODE_16BIT = 0, + /** RTC Count module operates in 32-bit mode. */ + RTC_COUNT_MODE_32BIT = 1, +}; + +/** + * \brief Available compare channels. + * + * \note Not all compare channels are available in all devices and modes. + */ +enum rtc_count_compare { + /** Compare channel 0. */ + RTC_COUNT_COMPARE_0 = 0, +#if (RTC_NUM_OF_COMP16 > 1) || defined(__DOXYGEN__) + /** Compare channel 1. */ + RTC_COUNT_COMPARE_1 = 1, +#endif +#if (RTC_NUM_OF_COMP16 > 2) || defined(__DOXYGEN__) + /** Compare channel 2. */ + RTC_COUNT_COMPARE_2 = 2, +#endif +#if (RTC_NUM_OF_COMP16 > 3) || defined(__DOXYGEN__) + /** Compare channel 3. */ + RTC_COUNT_COMPARE_3 = 3, +#endif +#if (RTC_NUM_OF_COMP16 > 4) || defined(__DOXYGEN__) + /** Compare channel 4. */ + RTC_COUNT_COMPARE_4 = 4, +#endif +#if (RTC_NUM_OF_COMP16 > 5) || defined(__DOXYGEN__) + /** Compare channel 5. */ + RTC_COUNT_COMPARE_5 = 5, +#endif +}; + +#if RTC_COUNT_ASYNC == true +/** + * \brief Callback types + * + * The available callback types for the RTC count module. + */ +enum rtc_count_callback { + /** Callback for compare channel 0 */ + RTC_COUNT_CALLBACK_COMPARE_0 = 0, +# if (RTC_NUM_OF_COMP16 > 1) || defined(__DOXYGEN__) + /** Callback for compare channel 1 */ + RTC_COUNT_CALLBACK_COMPARE_1, +# endif +# if (RTC_NUM_OF_COMP16 > 2) || defined(__DOXYGEN__) + /** Callback for compare channel 2 */ + RTC_COUNT_CALLBACK_COMPARE_2, +# endif +# if (RTC_NUM_OF_COMP16 > 3) || defined(__DOXYGEN__) + /** Callback for compare channel 3 */ + RTC_COUNT_CALLBACK_COMPARE_3, +# endif +# if (RTC_NUM_OF_COMP16 > 4) || defined(__DOXYGEN__) + /** Callback for compare channel 4 */ + RTC_COUNT_CALLBACK_COMPARE_4, +# endif +# if (RTC_NUM_OF_COMP16 > 5) || defined(__DOXYGEN__) + /** Callback for compare channel 5 */ + RTC_COUNT_CALLBACK_COMPARE_5, +# endif + /** Callback for overflow */ + RTC_COUNT_CALLBACK_OVERFLOW, +# if !defined(__DOXYGEN__) + /** Total number of callbacks */ + _RTC_COUNT_CALLBACK_N +# endif +}; + +# if !defined(__DOXYGEN__) +typedef void (*rtc_count_callback_t)(void); +# endif +#endif + +/** + * \brief RTC input clock prescaler settings + * + * The available input clock prescaler values for the RTC count module. + */ +enum rtc_count_prescaler { + /** RTC input clock frequency is prescaled by a factor of 1. */ + RTC_COUNT_PRESCALER_DIV_1 = RTC_MODE0_CTRL_PRESCALER_DIV1, + /** RTC input clock frequency is prescaled by a factor of 2. */ + RTC_COUNT_PRESCALER_DIV_2 = RTC_MODE0_CTRL_PRESCALER_DIV2, + /** RTC input clock frequency is prescaled by a factor of 4. */ + RTC_COUNT_PRESCALER_DIV_4 = RTC_MODE0_CTRL_PRESCALER_DIV4, + /** RTC input clock frequency is prescaled by a factor of 8. */ + RTC_COUNT_PRESCALER_DIV_8 = RTC_MODE0_CTRL_PRESCALER_DIV8, + /** RTC input clock frequency is prescaled by a factor of 16. */ + RTC_COUNT_PRESCALER_DIV_16 = RTC_MODE0_CTRL_PRESCALER_DIV16, + /** RTC input clock frequency is prescaled by a factor of 32. */ + RTC_COUNT_PRESCALER_DIV_32 = RTC_MODE0_CTRL_PRESCALER_DIV32, + /** RTC input clock frequency is prescaled by a factor of 64. */ + RTC_COUNT_PRESCALER_DIV_64 = RTC_MODE0_CTRL_PRESCALER_DIV64, + /** RTC input clock frequency is prescaled by a factor of 128. */ + RTC_COUNT_PRESCALER_DIV_128 = RTC_MODE0_CTRL_PRESCALER_DIV128, + /** RTC input clock frequency is prescaled by a factor of 256. */ + RTC_COUNT_PRESCALER_DIV_256 = RTC_MODE0_CTRL_PRESCALER_DIV256, + /** RTC input clock frequency is prescaled by a factor of 512. */ + RTC_COUNT_PRESCALER_DIV_512 = RTC_MODE0_CTRL_PRESCALER_DIV512, + /** RTC input clock frequency is prescaled by a factor of 1024. */ + RTC_COUNT_PRESCALER_DIV_1024 = RTC_MODE0_CTRL_PRESCALER_DIV1024, +}; + +/** + * \brief RTC Count event enable/disable structure. + * + * Event flags for the \ref rtc_count_enable_events() and + * \ref rtc_count_disable_events(). + */ +struct rtc_count_events { + /** Generate an output event on each overflow of the RTC count. */ + bool generate_event_on_overflow; + /** Generate an output event on a compare channel match against the RTC + * count. */ + bool generate_event_on_compare[RTC_NUM_OF_COMP16]; + /** Generate an output event periodically at a binary division of the RTC + * counter frequency (see + * \ref asfdoc_sam0_rtc_count_module_overview_periodic). + */ + bool generate_event_on_periodic[8]; +}; + +#if !defined(__DOXYGEN__) +/** + * \brief Device structure. + */ +struct rtc_module { + /** RTC hardware module */ + Rtc *hw; + /** Operation mode of count. */ + enum rtc_count_mode mode; + /** Set if counter value should be continuously updated. */ + bool continuously_update; +# if RTC_COUNT_ASYNC == true + /** Pointers to callback functions */ + volatile rtc_count_callback_t callbacks[_RTC_COUNT_CALLBACK_N]; + /** Mask for registered callbacks */ + volatile uint8_t registered_callback; + /** Mask for enabled callbacks */ + volatile uint8_t enabled_callback; +# endif +}; +#endif + +/** + * \brief RTC Count configuration structure + * + * Configuration structure for the RTC instance. This structure should + * be initialized using the \ref rtc_count_get_config_defaults() before any + * user configurations are set. + */ +struct rtc_count_config { + /** Input clock prescaler for the RTC module. */ + enum rtc_count_prescaler prescaler; + /** Select the operation mode of the RTC.*/ + enum rtc_count_mode mode; + /** If true, clears the counter value on compare match. Only available + * whilst running in 32-bit mode. */ + bool clear_on_match; + /** Continuously update the counter value so no synchronization is + * needed for reading. */ + bool continuously_update; + /** Array of Compare values. Not all Compare values are available in 32-bit + * mode. */ + uint32_t compare_values[RTC_NUM_OF_COMP16]; +}; + + +/** + * \name Configuration and initialization + * @{ + */ + +/** + * \brief Determines if the hardware module(s) are currently synchronizing to the bus. + * + * Checks to see if the underlying hardware peripheral module(s) are currently + * synchronizing across multiple clock domains to the hardware bus, This + * function can be used to delay further operations on a module until such time + * that it is ready, to prevent blocking delays for synchronization in the + * user application. + * + * \param[in] module RTC hardware module + * + * \return Synchronization status of the underlying hardware module(s). + * + * \retval true if the module has completed synchronization + * \retval false if the module synchronization is ongoing + */ +static inline bool rtc_count_is_syncing(struct rtc_module *const module) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + if (rtc_module->MODE0.STATUS.reg & RTC_STATUS_SYNCBUSY) { + return true; + } + + return false; +} + +/** + * \brief Gets the RTC default configurations. + * + * Initializes the configuration structure to default values. This + * function should be called at the start of any RTC initialization. + * + * The default configuration is as follows: + * - Input clock divided by a factor of 1024. + * - RTC in 32 bit mode. + * - Clear on compare match off. + * - Continuously sync count register off. + * - No event source on. + * - All compare values equal 0. + * + * \param[out] config Configuration structure to be initialized to default + * values. + */ +static inline void rtc_count_get_config_defaults( + struct rtc_count_config *const config) +{ + /* Sanity check argument */ + Assert(config); + + /* Set default into configuration structure */ + config->prescaler = RTC_COUNT_PRESCALER_DIV_1024; + config->mode = RTC_COUNT_MODE_32BIT; + config->clear_on_match = false; + config->continuously_update = false; + for (uint8_t i = 0; i < RTC_NUM_OF_COMP16; i++) { + config->compare_values[i] = 0; + } +} + +void rtc_count_reset(struct rtc_module *const module); + +/** + * \brief Enables the RTC module. + * + * Enables the RTC module once it has been configured, ready for use. Most + * module configuration parameters cannot be altered while the module is enabled. + * + * \param[in,out] module RTC hardware module + */ +static inline void rtc_count_enable(struct rtc_module *const module) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + +#if RTC_COUNT_ASYNC == true + system_interrupt_enable(SYSTEM_INTERRUPT_MODULE_RTC); +#endif + + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + + /* Enable RTC module. */ + rtc_module->MODE0.CTRL.reg |= RTC_MODE0_CTRL_ENABLE; +} + +/** + * \brief Disables the RTC module. + * + * Disables the RTC module. + * + * \param[in,out] module RTC hardware module + */ +static inline void rtc_count_disable(struct rtc_module *const module) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + +#if RTC_COUNT_ASYNC == true + system_interrupt_disable(SYSTEM_INTERRUPT_MODULE_RTC); +#endif + + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + + /* Disable RTC module. */ + rtc_module->MODE0.CTRL.reg &= ~RTC_MODE0_CTRL_ENABLE; +} + +#if (RTC_INST_NUM > 1) && !defined(__DOXYGEN__) +/** + * \internal Find the index of given RTC module instance. + * + * \param[in] RTC module instance pointer. + * + * \return Index of the given AC module instance. + */ +uint8_t _rtc_get_inst_index( + Rtc *const hw) +{ + /* List of available RTC modules. */ + static Rtc *const rtc_modules[RTC_INST_NUM] = RTC_INSTS; + + /* Find index for RTC instance. */ + for (uint32_t i = 0; i < RTC_INST_NUM; i++) { + if (hw == rtc_modules[i]) { + return i; + } + } + + /* Invalid data given. */ + Assert(false); + return 0; +} +#endif /* (RTC_INST_NUM > 1) && !defined(__DOXYGEN__) */ + +enum status_code rtc_count_init( + struct rtc_module *const module, + Rtc *const hw, + const struct rtc_count_config *const config); + +enum status_code rtc_count_frequency_correction( + struct rtc_module *const module, + const int8_t value); + +/** @} */ + +/** \name Count and compare value management + * @{ + */ +enum status_code rtc_count_set_count( + struct rtc_module *const module, + const uint32_t count_value); + +uint32_t rtc_count_get_count(struct rtc_module *const module); + +enum status_code rtc_count_set_compare( + struct rtc_module *const module, + const uint32_t comp_value, + const enum rtc_count_compare comp_index); + +enum status_code rtc_count_get_compare( + struct rtc_module *const module, + uint32_t *const comp_value, + const enum rtc_count_compare comp_index); + +enum status_code rtc_count_set_period( + struct rtc_module *const module, + uint16_t period_value); + +enum status_code rtc_count_get_period( + struct rtc_module *const module, + uint16_t *const period_value); + +/** @} */ + + +/** \name Status management + * @{ + */ + +/** + * \brief Check if an RTC overflow has occurred. + * + * Checks the overflow flag in the RTC. The flag is set when there + * is an overflow in the clock. + * + * \param[in,out] module RTC hardware module + * + * \return Overflow state of the RTC module. + * + * \retval true If the RTC count value has overflowed + * \retval false If the RTC count value has not overflowed + */ + +static inline bool rtc_count_is_overflow(struct rtc_module *const module) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Return status of flag */ + return (rtc_module->MODE0.INTFLAG.reg & RTC_MODE0_INTFLAG_OVF); +} + +/** + * \brief Clears the RTC overflow flag. + * + * Clears the RTC module counter overflow flag, so that new overflow conditions + * can be detected. + * + * \param[in,out] module RTC hardware module + */ +static inline void rtc_count_clear_overflow(struct rtc_module *const module) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Clear OVF flag */ + rtc_module->MODE0.INTFLAG.reg = RTC_MODE0_INTFLAG_OVF; +} + +bool rtc_count_is_compare_match( + struct rtc_module *const module, + const enum rtc_count_compare comp_index); + +enum status_code rtc_count_clear_compare_match( + struct rtc_module *const module, + const enum rtc_count_compare comp_index); + +/** @} */ + + +/** + * \name Event management + * @{ + */ + +/** + * \brief Enables a RTC event output. + * + * Enables one or more output events from the RTC module. See + * \ref rtc_count_events for a list of events this module supports. + * + * \note Events cannot be altered while the module is enabled. + * + * \param[in,out] module RTC hardware module + * \param[in] events Struct containing flags of events to enable + */ +static inline void rtc_count_enable_events( + struct rtc_module *const module, + struct rtc_count_events *const events) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + uint32_t event_mask = 0; + + /* Check if the user has requested an overflow event. */ + if (events->generate_event_on_overflow) { + event_mask |= RTC_MODE0_EVCTRL_OVFEO; + } + + /* Check if the user has requested any compare events. */ + for (uint8_t i = 0; i < RTC_NUM_OF_COMP16; i++) { + if (events->generate_event_on_compare[i]) { + event_mask |= RTC_MODE0_EVCTRL_CMPEO(1 << i); + } + } + + /* Check if the user has requested any periodic events. */ + for (uint8_t i = 0; i < 8; i++) { + if (events->generate_event_on_periodic[i]) { + event_mask |= RTC_MODE0_EVCTRL_PEREO(1 << i); + } + } + + /* Enable given event(s). */ + rtc_module->MODE0.EVCTRL.reg |= event_mask; +} + +/** + * \brief Disables a RTC event output. + * + * Disabled one or more output events from the RTC module. See + * \ref rtc_count_events for a list of events this module supports. + * + * \note Events cannot be altered while the module is enabled. + * + * \param[in,out] module RTC hardware module + * \param[in] events Struct containing flags of events to disable + */ +static inline void rtc_count_disable_events( + struct rtc_module *const module, + struct rtc_count_events *const events) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + uint32_t event_mask = 0; + + /* Check if the user has requested an overflow event. */ + if (events->generate_event_on_overflow) { + event_mask |= RTC_MODE0_EVCTRL_OVFEO; + } + + /* Check if the user has requested any compare events. */ + for (uint8_t i = 0; i < RTC_NUM_OF_COMP16; i++) { + if (events->generate_event_on_compare[i]) { + event_mask |= RTC_MODE0_EVCTRL_CMPEO(1 << i); + } + } + + /* Check if the user has requested any periodic events. */ + for (uint8_t i = 0; i < 8; i++) { + if (events->generate_event_on_periodic[i]) { + event_mask |= RTC_MODE0_EVCTRL_PEREO(1 << i); + } + } + + /* Disable given event(s). */ + rtc_module->MODE0.EVCTRL.reg &= ~event_mask; +} + +/** @} */ + +/** @} */ + +#ifdef __cplusplus +} +#endif + +/** + * \page asfdoc_sam0_rtc_count_extra Extra Information for RTC COUNT Driver + * + * \section asfdoc_sam0_rtc_count_extra_acronyms Acronyms + * Below is a table listing the acronyms used in this module, along with their + * intended meanings. + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Acronym + * Description + *
RTCReal Time Counter
PPMPart Per Million
RCResistor/Capacitor
+ * + * + * \section asfdoc_sam0_rtc_count_extra_dependencies Dependencies + * This driver has the following dependencies: + * + * - None + * + * + * \section asfdoc_sam0_rtc_count_extra_errata Errata + * There are no errata related to this driver. + * + * + * \section asfdoc_sam0_rtc_count_extra_history Module History + * An overview of the module history is presented in the table below, with + * details on the enhancements and fixes made to the module since its first + * release. The current version of this corresponds to the newest version in + * the table. + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Changelog
+ * Added support for SAMD21 and added driver instance parameter to all + * API function calls, except get_config_defaults. + *
Updated initialization function to also enable the digital interface + * clock to the module if it is disabled.
Initial Release
+ */ + +/** + * \page asfdoc_sam0_rtc_count_exqsg Examples for RTC (COUNT) Driver + * + * This is a list of the available Quick Start guides (QSGs) and example + * applications for \ref asfdoc_sam0_rtc_count_group. QSGs are simple + * examples with step-by-step instructions to configure and use this driver in a + * selection of use cases. Note that QSGs can be compiled as a standalone + * application or be added to the user application. + * + * - \subpage asfdoc_sam0_rtc_count_basic_use_case + * \if RTC_COUNT_CALLBACK_MODE + * - \subpage asfdoc_sam0_rtc_count_callback_use_case + * \endif + * + * \page asfdoc_sam0_rtc_count_document_revision_history Document Revision History + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Doc. Rev. + * Date + * Comments + *
E05/2014Added support for SAMD10/D11.
D03/2014Added support for SAMR21.
C01/2014Added support for SAMD21.
B06/2013Added additional documentation on the event system. Corrected + * documentation typos.
A06/2013Initial release
+ */ + +#endif /* RTC_COUNT_H_INCLUDED */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/rtc/rtc_count_interrupt.c b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/rtc/rtc_count_interrupt.c new file mode 100644 index 0000000..eec6e96 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/rtc/rtc_count_interrupt.c @@ -0,0 +1,317 @@ +/** + * \file + * + * \brief SAM RTC Driver (Count Interrupt Mode) + * + * Copyright (C) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include "rtc_count_interrupt.h" + +extern struct rtc_module *_rtc_instance[RTC_INST_NUM]; + +/** + * \brief Registers callback for the specified callback type + * + * Associates the given callback function with the + * specified callback type. + * To enable the callback, the \ref rtc_count_enable_callback function + * must be used. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] callback Pointer to the function desired for the specified + * callback + * \param[in] callback_type Callback type to register + * + * \return Status of registering callback + * \retval STATUS_OK Registering was done successfully + * \retval STATUS_ERR_INVALID_ARG If trying to register a callback not available + */ +enum status_code rtc_count_register_callback( + struct rtc_module *const module, + rtc_count_callback_t callback, + enum rtc_count_callback callback_type) +{ + + enum status_code status = STATUS_OK; + + /* Overflow callback */ + if (callback_type == RTC_COUNT_CALLBACK_OVERFLOW) { + status = STATUS_OK; + } else { + /* Make sure callback type can be registered */ + switch (module->mode) { + case RTC_COUNT_MODE_32BIT: + /* Check sanity for 32-bit mode. */ + if (callback_type > RTC_NUM_OF_COMP32) { + status = STATUS_ERR_INVALID_ARG; + } + + break; + case RTC_COUNT_MODE_16BIT: + /* Check sanity for 16-bit mode. */ + if (callback_type > RTC_NUM_OF_COMP16) { + status = STATUS_ERR_INVALID_ARG; + } + break; + default: + status = STATUS_ERR_INVALID_ARG; + } + } + + if (status == STATUS_OK) { + /* Register callback */ + module->callbacks[callback_type] = callback; + /* Set corresponding bit to set callback as registered */ + module->registered_callback |= (1 << callback_type); + } + + return status; +} + +/** + * \brief Unregisters callback for the specified callback type + * + * When called, the currently registered callback for the given callback type + * will be removed. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] callback_type Specifies the callback type to unregister + * + * \return Status of unregistering callback + * \retval STATUS_OK Unregistering was done successfully + * \retval STATUS_ERR_INVALID_ARG If trying to unregister a callback not available + */ +enum status_code rtc_count_unregister_callback( + struct rtc_module *const module, + enum rtc_count_callback callback_type) +{ + enum status_code status = STATUS_OK; + + /* Overflow callback */ + if (callback_type == RTC_COUNT_CALLBACK_OVERFLOW) { + status = STATUS_OK; + } else { + /* Make sure callback type can be unregistered */ + switch (module->mode) { + case RTC_COUNT_MODE_32BIT: + /* Check sanity for 32-bit mode. */ + if (callback_type > RTC_NUM_OF_COMP32) { + status = STATUS_ERR_INVALID_ARG; + } + break; + case RTC_COUNT_MODE_16BIT: + /* Check sanity for 16-bit mode. */ + if (callback_type > RTC_NUM_OF_COMP16) { + status = STATUS_ERR_INVALID_ARG; + } + break; + default: + status = STATUS_ERR_INVALID_ARG; + } + } + if (status == STATUS_OK) { + /* Unregister callback */ + module->callbacks[callback_type] = NULL; + + /* Clear corresponding bit to set callback as unregistered */ + module->registered_callback &= ~(1 << callback_type); + } + return status; +} + +/** + * \brief Enables callback + * + * Enables the callback specified by the callback_type. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] callback_type Callback type to enable + */ +void rtc_count_enable_callback( + struct rtc_module *const module, + enum rtc_count_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + if (callback_type == RTC_COUNT_CALLBACK_OVERFLOW) { + rtc_module->MODE0.INTENSET.reg = RTC_MODE0_INTFLAG_OVF; + } else { + rtc_module->MODE0.INTENSET.reg = RTC_MODE1_INTFLAG_CMP(1 << callback_type); + } + /* Mark callback as enabled. */ + module->enabled_callback |= (1 << callback_type); +} + +/** + * \brief Disables callback + * + * Disables the callback specified by the callback_type. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] callback_type Callback type to disable + */ +void rtc_count_disable_callback( + struct rtc_module *const module, + enum rtc_count_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Disable interrupt */ + if (callback_type == RTC_COUNT_CALLBACK_OVERFLOW) { + rtc_module->MODE0.INTENCLR.reg = RTC_MODE0_INTFLAG_OVF; + } else { + rtc_module->MODE0.INTENCLR.reg = RTC_MODE1_INTFLAG_CMP(1 << callback_type); + } + + /* Mark callback as disabled. */ + module->enabled_callback &= ~(1 << callback_type); +} + +/** + * \internal Interrupt handler for RTC + * + * \param [in] instance_index Default value 0 + */ +static void _rtc_interrupt_handler(const uint32_t instance_index) +{ + struct rtc_module *module = _rtc_instance[instance_index]; + + Rtc *const rtc_module = module->hw; + + /* Combine callback registered and enabled masks */ + uint8_t callback_mask = module->enabled_callback; + callback_mask &= module->registered_callback; + + /* Read and mask interrupt flag register */ + uint16_t interrupt_status = rtc_module->MODE0.INTFLAG.reg; + interrupt_status &= rtc_module->MODE0.INTENSET.reg; + + if (interrupt_status & RTC_MODE0_INTFLAG_OVF) { + /* Overflow interrupt */ + if (callback_mask & (1 << RTC_COUNT_CALLBACK_OVERFLOW)) { + module->callbacks[RTC_COUNT_CALLBACK_OVERFLOW](); + } + + /* Clear interrupt flag */ + rtc_module->MODE0.INTFLAG.reg = RTC_MODE0_INTFLAG_OVF; + + } else if (interrupt_status & RTC_MODE1_INTFLAG_CMP(1 << 0)) { + /* Compare 0 interrupt */ + if (callback_mask & (1 << RTC_COUNT_CALLBACK_COMPARE_0)) { + module->callbacks[RTC_COUNT_CALLBACK_COMPARE_0](); + } + /* Clear interrupt flag */ + rtc_module->MODE0.INTFLAG.reg = RTC_MODE1_INTFLAG_CMP(1 << 0); + + } else if (interrupt_status & RTC_MODE1_INTFLAG_CMP(1 << 1)) { + #if (RTC_NUM_OF_COMP16 > 1) || defined(__DOXYGEN__) + /* Compare 1 interrupt */ + if (callback_mask & (1 << RTC_COUNT_CALLBACK_COMPARE_1)) { + module->callbacks[RTC_COUNT_CALLBACK_COMPARE_1](); + } + /* Clear interrupt flag */ + rtc_module->MODE0.INTFLAG.reg = RTC_MODE1_INTFLAG_CMP(1 << 1); + #endif + + } else if (interrupt_status & RTC_MODE1_INTFLAG_CMP(1 << 2)) { + #if (RTC_NUM_OF_COMP16 > 2) || defined(__DOXYGEN__) + /* Compare 2 interrupt */ + if (callback_mask & (1 << RTC_COUNT_CALLBACK_COMPARE_2)) { + module->callbacks[RTC_COUNT_CALLBACK_COMPARE_2](); + } + /* Clear interrupt flag */ + rtc_module->MODE0.INTFLAG.reg = RTC_MODE1_INTFLAG_CMP(1 << 2); + #endif + + } else if (interrupt_status & RTC_MODE1_INTFLAG_CMP(1 << 3)) { + #if (RTC_NUM_OF_COMP16 > 3) || defined(__DOXYGEN__) + /* Compare 3 interrupt */ + if (callback_mask & (1 << RTC_COUNT_CALLBACK_COMPARE_3)) { + module->callbacks[RTC_COUNT_CALLBACK_COMPARE_3](); + } + /* Clear interrupt flag */ + rtc_module->MODE0.INTFLAG.reg = RTC_MODE1_INTFLAG_CMP(1 << 3); + #endif + + } else if (interrupt_status & RTC_MODE1_INTFLAG_CMP(1 << 4)) { + #if (RTC_NUM_OF_COMP16 > 4) || defined(__DOXYGEN__) + /* Compare 4 interrupt */ + if (callback_mask & (1 << RTC_COUNT_CALLBACK_COMPARE_4)) { + module->callbacks[RTC_COUNT_CALLBACK_COMPARE_4](); + } + /* Clear interrupt flag */ + rtc_module->MODE0.INTFLAG.reg = RTC_MODE1_INTFLAG_CMP(1 << 4); + #endif + + } else if (interrupt_status & RTC_MODE1_INTFLAG_CMP(1 << 5)) { + #if (RTC_NUM_OF_COMP16 > 5) || defined(__DOXYGEN__) + /* Compare 5 interrupt */ + if (callback_mask & (1 << RTC_COUNT_CALLBACK_COMPARE_5)) { + module->callbacks[RTC_COUNT_CALLBACK_COMPARE_5](); + } + /* Clear interrupt flag */ + rtc_module->MODE0.INTFLAG.reg = RTC_MODE1_INTFLAG_CMP(1 << 5); + #endif + } +} + +/** + * \internal ISR handler for RTC + */ +#if (RTC_INST_NUM == 1) +void RTC_Handler(void) +{ + _rtc_interrupt_handler(0); +} +#elif (RTC_INST_NUM > 1) +# define _RTC_INTERRUPT_HANDLER(n, unused) \ + void RTC##n##_Handler(void) \ + { \ + _rtc_interrupt_handler(n); \ + } + +MREPEAT(RTC_INST_NUM, _RTC_INTERRUPT_HANDLER, ~) +#endif /* (RTC_INST_NUM > 1) */ \ No newline at end of file diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/rtc/rtc_count_interrupt.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/rtc/rtc_count_interrupt.h new file mode 100644 index 0000000..0a05d42 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/rtc/rtc_count_interrupt.h @@ -0,0 +1,87 @@ +/** + * \file + * + * \brief SAM RTC Driver (Count Interrupt Mode) + * + * Copyright (C) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef RTC_COUNT_INTERRUPT_H_INCLUDED +#define RTC_COUNT_INTERRUPT_H_INCLUDED + +#include "rtc_count.h" + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \addtogroup asfdoc_sam0_rtc_count_group + * @{ + */ + + /** + * \name Callbacks + * @{ + */ +enum status_code rtc_count_register_callback( + struct rtc_module *const module, + rtc_count_callback_t callback, + enum rtc_count_callback callback_type); + +enum status_code rtc_count_unregister_callback( + struct rtc_module *const module, + enum rtc_count_callback callback_type); + +void rtc_count_enable_callback( + struct rtc_module *const module, + enum rtc_count_callback callback_type); + +void rtc_count_disable_callback( + struct rtc_module *const module, + enum rtc_count_callback callback_type); + +/** @} */ + +/** @} */ + +#ifdef __cplusplus +} +#endif + +#endif /* RTC_COUNT_INTERRUPT_H_INCLUDED */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/clock.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/clock.h new file mode 100644 index 0000000..65fd475 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/clock.h @@ -0,0 +1,1526 @@ +/** + * \file + * + * \brief SAM Clock Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef SYSTEM_CLOCK_H_INCLUDED +#define SYSTEM_CLOCK_H_INCLUDED + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \defgroup asfdoc_sam0_system_clock_group SAM System Clock Management Driver (SYSTEM CLOCK) + * + * This driver for SAM devices provides an interface for the configuration + * and management of the device's clocking related functions. This includes + * the various clock sources, bus clocks and generic clocks within the device, + * with functions to manage the enabling, disabling, source selection and + * prescaling of clocks to various internal peripherals. + * + * The following peripherals are used by this module: + * + * - GCLK (Generic Clock Management) + * - PM (Power Management) + * - SYSCTRL (Clock Source Control) + * + * The following devices can use this module: + * - SAM D20/D21 + * - SAM R21 + * - SAM D10/D11 + * + * The outline of this documentation is as follows: + * - \ref asfdoc_sam0_system_clock_prerequisites + * - \ref asfdoc_sam0_system_clock_module_overview + * - \ref asfdoc_sam0_system_clock_special_considerations + * - \ref asfdoc_sam0_system_clock_extra_info + * - \ref asfdoc_sam0_system_clock_examples + * - \ref asfdoc_sam0_system_clock_api_overview + * + * + * \section asfdoc_sam0_system_clock_prerequisites Prerequisites + * + * There are no prerequisites for this module. + * + * + * \section asfdoc_sam0_system_clock_module_overview Module Overview + * The SAM devices contain a sophisticated clocking system, which is designed + * to give the maximum flexibility to the user application. This system allows + * a system designer to tune the performance and power consumption of the device + * in a dynamic manner, to achieve the best trade-off between the two for a + * particular application. + * + * This driver provides a set of functions for the configuration and management + * of the various clock related functionality within the device. + * + * \subsection asfdoc_sam0_system_clock_module_features Driver Feature Macro Definition + * + * + * + * + * + * + * + * + * + *
Driver Feature MacroSupported devices
FEATURE_SYSTEM_CLOCK_DPLLSAMD21, SAMR21, SAMD10, SAMD11
+ * \note The specific features are only available in the driver when the + * selected device supports those features. + * + * \subsection asfdoc_sam0_system_clock_module_overview_clock_sources Clock Sources + * The SAM devices have a number of master clock source modules, each of + * which being capable of producing a stabilized output frequency which can then + * be fed into the various peripherals and modules within the device. + * + * Possible clock source modules include internal R/C oscillators, internal + * DFLL modules, as well as external crystal oscillators and/or clock inputs. + * + * \subsection asfdoc_sam0_system_clock_module_overview_cpu_clock CPU / Bus Clocks + * The CPU and AHB/APBx buses are clocked by the same physical clock source + * (referred in this module as the Main Clock), however the APBx buses may + * have additional prescaler division ratios set to give each peripheral bus a + * different clock speed. + * + * The general main clock tree for the CPU and associated buses is shown in + * \ref asfdoc_sam0_system_clock_module_clock_tree "the figure below". + * + * \anchor asfdoc_sam0_system_clock_module_clock_tree + * \dot + * digraph overview { + * rankdir=LR; + * clk_src [label="Clock Sources", shape=none, height=0]; + * node [label="CPU Bus" shape=ellipse] cpu_bus; + * node [label="AHB Bus" shape=ellipse] ahb_bus; + * node [label="APBA Bus" shape=ellipse] apb_a_bus; + * node [label="APBB Bus" shape=ellipse] apb_b_bus; + * node [label="APBC Bus" shape=ellipse] apb_c_bus; + * node [label="Main Bus\nPrescaler" shape=square] main_prescaler; + * node [label="APBA Bus\nPrescaler" shape=square] apb_a_prescaler; + * node [label="APBB Bus\nPrescaler" shape=square] apb_b_prescaler; + * node [label="APBC Bus\nPrescaler" shape=square] apb_c_prescaler; + * node [label="", shape=polygon, sides=4, distortion=0.6, orientation=90, style=filled, fillcolor=black, height=0.9, width=0.2] main_clock_mux; + * + * clk_src -> main_clock_mux; + * main_clock_mux -> main_prescaler; + * main_prescaler -> cpu_bus; + * main_prescaler -> ahb_bus; + * main_prescaler -> apb_a_prescaler; + * main_prescaler -> apb_b_prescaler; + * main_prescaler -> apb_c_prescaler; + * apb_a_prescaler -> apb_a_bus; + * apb_b_prescaler -> apb_b_bus; + * apb_c_prescaler -> apb_c_bus; + * } + * \enddot + * + * \subsection asfdoc_sam0_system_clock_module_overview_clock_masking Clock Masking + * To save power, the input clock to one or more peripherals on the AHB and APBx + * buses can be masked away - when masked, no clock is passed into the module. + * Disabling of clocks of unused modules will prevent all access to the masked + * module, but will reduce the overall device power consumption. + * + * \subsection asfdoc_sam0_system_clock_module_overview_gclk Generic Clocks + * Within the SAM devices are a number of Generic Clocks; these are used to + * provide clocks to the various peripheral clock domains in the device in a + * standardized manner. One or more master source clocks can be selected as the + * input clock to a Generic Clock Generator, which can prescale down the input + * frequency to a slower rate for use in a peripheral. + * + * Additionally, a number of individually selectable Generic Clock Channels are + * provided, which multiplex and gate the various generator outputs for one or + * more peripherals within the device. This setup allows for a single common + * generator to feed one or more channels, which can then be enabled or disabled + * individually as required. + * + * \anchor asfdoc_sam0_system_clock_module_chain_overview + * \dot + * digraph overview { + * rankdir=LR; + * node [label="Clock\nSource a" shape=square] system_clock_source; + * node [label="Generator 1" shape=square] clock_gen; + * node [label="Channel x" shape=square] clock_chan0; + * node [label="Channel y" shape=square] clock_chan1; + * node [label="Peripheral x" shape=ellipse style=filled fillcolor=lightgray] peripheral0; + * node [label="Peripheral y" shape=ellipse style=filled fillcolor=lightgray] peripheral1; + * + * system_clock_source -> clock_gen; + * clock_gen -> clock_chan0; + * clock_chan0 -> peripheral0; + * clock_gen -> clock_chan1; + * clock_chan1 -> peripheral1; + * } + * \enddot + * + * \subsubsection asfdoc_sam0_system_clock_module_chain_example Clock Chain Example + * An example setup of a complete clock chain within the device is shown in + * \ref asfdoc_sam0_system_clock_module_chain_example_fig "the figure below". + * + * \anchor asfdoc_sam0_system_clock_module_chain_example_fig + * \dot + * digraph overview { + * rankdir=LR; + * node [label="External\nOscillator" shape=square] system_clock_source0; + * node [label="Generator 0" shape=square] clock_gen0; + * node [label="Channel x" shape=square] clock_chan0; + * node [label="Core CPU" shape=ellipse style=filled fillcolor=lightgray] peripheral0; + * + * system_clock_source0 -> clock_gen0; + * clock_gen0 -> clock_chan0; + * clock_chan0 -> peripheral0; + * node [label="8MHz R/C\nOscillator (OSC8M)" shape=square fillcolor=white] system_clock_source1; + * node [label="Generator 1" shape=square] clock_gen1; + * node [label="Channel y" shape=square] clock_chan1; + * node [label="Channel z" shape=square] clock_chan2; + * node [label="SERCOM\nModule" shape=ellipse style=filled fillcolor=lightgray] peripheral1; + * node [label="Timer\nModule" shape=ellipse style=filled fillcolor=lightgray] peripheral2; + * + * system_clock_source1 -> clock_gen1; + * clock_gen1 -> clock_chan1; + * clock_gen1 -> clock_chan2; + * clock_chan1 -> peripheral1; + * clock_chan2 -> peripheral2; + * } + * \enddot + * + * \subsubsection asfdoc_sam0_system_clock_module_overview_gclk_generators Generic Clock Generators + * Each Generic Clock generator within the device can source its input clock + * from one of the provided Source Clocks, and prescale the output for one or + * more Generic Clock Channels in a one-to-many relationship. The generators + * thus allow for several clocks to be generated of different frequencies, + * power usages and accuracies, which can be turned on and off individually to + * disable the clocks to multiple peripherals as a group. + * + * \subsubsection asfdoc_sam0_system_clock_module_overview_gclk_channels Generic Clock Channels + * To connect a Generic Clock Generator to a peripheral within the + * device, a Generic Clock Channel is used. Each peripheral or + * peripheral group has an associated Generic Clock Channel, which serves as the + * clock input for the peripheral(s). To supply a clock to the peripheral + * module(s), the associated channel must be connected to a running Generic + * Clock Generator and the channel enabled. + * + * \section asfdoc_sam0_system_clock_special_considerations Special Considerations + * + * There are no special considerations for this module. + * + * + * \section asfdoc_sam0_system_clock_extra_info Extra Information + * + * For extra information see \ref asfdoc_sam0_system_clock_extra. This includes: + * - \ref asfdoc_sam0_system_clock_extra_acronyms + * - \ref asfdoc_sam0_system_clock_extra_dependencies + * - \ref asfdoc_sam0_system_clock_extra_errata + * - \ref asfdoc_sam0_system_clock_extra_history + * + * + * \section asfdoc_sam0_system_clock_examples Examples + * + * For a list of examples related to this driver, see + * \ref asfdoc_sam0_system_clock_exqsg. + * + * + * \section asfdoc_sam0_system_clock_api_overview API Overview + * @{ + */ + +#include +#include + +/** + * \name Driver feature definition + * Define system clock features set according to different device family. + * @{ + */ +#if (SAMD21) || (SAMR21) || (SAMD11) || (SAMD10) || defined(__DOXYGEN__) +/** Digital Phase Locked Loop (DPLL) feature support */ +# define FEATURE_SYSTEM_CLOCK_DPLL +#endif +/*@}*/ + +/** + * \brief Available start-up times for the XOSC32K + * + * Available external 32KHz oscillator start-up times, as a number of external + * clock cycles. + */ +enum system_xosc32k_startup { + /** Wait 0 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC32K_STARTUP_0, + /** Wait 32 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC32K_STARTUP_32, + /** Wait 2048 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC32K_STARTUP_2048, + /** Wait 4096 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC32K_STARTUP_4096, + /** Wait 16384 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC32K_STARTUP_16384, + /** Wait 32768 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC32K_STARTUP_32768, + /** Wait 65536 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC32K_STARTUP_65536, + /** Wait 131072 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC32K_STARTUP_131072, +}; + +/** + * \brief Available start-up times for the XOSC + * + * Available external oscillator start-up times, as a number of external clock + * cycles. + */ +enum system_xosc_startup { + /** Wait 1 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_1, + /** Wait 2 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_2, + /** Wait 4 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_4, + /** Wait 8 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_8, + /** Wait 16 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_16, + /** Wait 32 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_32, + /** Wait 64 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_64, + /** Wait 128 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_128, + /** Wait 256 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_256, + /** Wait 512 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_512, + /** Wait 1024 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_1024, + /** Wait 2048 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_2048, + /** Wait 4096 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_4096, + /** Wait 8192 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_8192, + /** Wait 16384 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_16384, + /** Wait 32768 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_32768, +}; + +/** + * \brief Available start-up times for the OSC32K + * + * Available internal 32KHz oscillator start-up times, as a number of internal + * OSC32K clock cycles. + */ +enum system_osc32k_startup { + /** Wait 3 clock cycles until the clock source is considered stable */ + SYSTEM_OSC32K_STARTUP_3, + /** Wait 4 clock cycles until the clock source is considered stable */ + SYSTEM_OSC32K_STARTUP_4, + /** Wait 6 clock cycles until the clock source is considered stable */ + SYSTEM_OSC32K_STARTUP_6, + /** Wait 10 clock cycles until the clock source is considered stable */ + SYSTEM_OSC32K_STARTUP_10, + /** Wait 18 clock cycles until the clock source is considered stable */ + SYSTEM_OSC32K_STARTUP_18, + /** Wait 34 clock cycles until the clock source is considered stable */ + SYSTEM_OSC32K_STARTUP_34, + /** Wait 66 clock cycles until the clock source is considered stable */ + SYSTEM_OSC32K_STARTUP_66, + /** Wait 130 clock cycles until the clock source is considered stable */ + SYSTEM_OSC32K_STARTUP_130, +}; + +/** + * \brief Division prescalers for the internal 8MHz system clock + * + * Available prescalers for the internal 8MHz (nominal) system clock. + */ +enum system_osc8m_div { + /** Do not divide the 8MHz RC oscillator output */ + SYSTEM_OSC8M_DIV_1, + /** Divide the 8MHz RC oscillator output by 2 */ + SYSTEM_OSC8M_DIV_2, + /** Divide the 8MHz RC oscillator output by 4 */ + SYSTEM_OSC8M_DIV_4, + /** Divide the 8MHz RC oscillator output by 8 */ + SYSTEM_OSC8M_DIV_8, +}; + +/** + * \brief Frequency range for the internal 8Mhz RC oscillator + * + * Internal 8Mhz RC oscillator frequency range setting + */ +enum system_osc8m_frequency_range { + /** Frequency range 4 Mhz to 6 Mhz */ + SYSTEM_OSC8M_FREQUENCY_RANGE_4_TO_6, + /** Frequency range 6 Mhz to 8 Mhz */ + SYSTEM_OSC8M_FREQUENCY_RANGE_6_TO_8, + /** Frequency range 8 Mhz to 11 Mhz */ + SYSTEM_OSC8M_FREQUENCY_RANGE_8_TO_11, + /** Frequency range 11 Mhz to 15 Mhz */ + SYSTEM_OSC8M_FREQUENCY_RANGE_11_TO_15, +}; + +/** + * \brief Main CPU and APB/AHB bus clock source prescaler values + * + * Available division ratios for the CPU and APB/AHB bus clocks. + */ +enum system_main_clock_div { + /** Divide Main clock by 1 */ + SYSTEM_MAIN_CLOCK_DIV_1, + /** Divide Main clock by 2 */ + SYSTEM_MAIN_CLOCK_DIV_2, + /** Divide Main clock by 4 */ + SYSTEM_MAIN_CLOCK_DIV_4, + /** Divide Main clock by 8 */ + SYSTEM_MAIN_CLOCK_DIV_8, + /** Divide Main clock by 16 */ + SYSTEM_MAIN_CLOCK_DIV_16, + /** Divide Main clock by 32 */ + SYSTEM_MAIN_CLOCK_DIV_32, + /** Divide Main clock by 64 */ + SYSTEM_MAIN_CLOCK_DIV_64, + /** Divide Main clock by 128 */ + SYSTEM_MAIN_CLOCK_DIV_128, +}; + +/** + * \brief External clock source types. + * + * Available external clock source types. + */ +enum system_clock_external { + /** The external clock source is a crystal oscillator */ + SYSTEM_CLOCK_EXTERNAL_CRYSTAL, + /** The connected clock source is an external logic level clock signal */ + SYSTEM_CLOCK_EXTERNAL_CLOCK, +}; + +/** + * \brief Operating modes of the DFLL clock source. + * + * Available operating modes of the DFLL clock source module, + */ +enum system_clock_dfll_loop_mode { + /** The DFLL is operating in open loop mode with no feedback */ + SYSTEM_CLOCK_DFLL_LOOP_MODE_OPEN, + /** The DFLL is operating in closed loop mode with frequency feedback from + * a low frequency reference clock + */ + SYSTEM_CLOCK_DFLL_LOOP_MODE_CLOSED = SYSCTRL_DFLLCTRL_MODE, + +#ifdef SYSCTRL_DFLLCTRL_USBCRM + /** The DFLL is operating in USB recovery mode with frequency feedback + * from USB SOF + */ + SYSTEM_CLOCK_DFLL_LOOP_MODE_USB_RECOVERY = SYSCTRL_DFLLCTRL_USBCRM, +#endif +}; + +/** + * \brief Locking behavior for the DFLL during device wake-up + * + * DFLL lock behavior modes on device wake-up from sleep. + */ +enum system_clock_dfll_wakeup_lock { + /** Keep DFLL lock when the device wakes from sleep */ + SYSTEM_CLOCK_DFLL_WAKEUP_LOCK_KEEP, + /** Lose DFLL lock when the devices wakes from sleep */ + SYSTEM_CLOCK_DFLL_WAKEUP_LOCK_LOSE = SYSCTRL_DFLLCTRL_LLAW, +}; + +/** + * \brief Fine tracking behavior for the DFLL once a lock has been acquired + * + * DFLL fine tracking behavior modes after a lock has been acquired. + */ +enum system_clock_dfll_stable_tracking { + /** Keep tracking after the DFLL has gotten a fine lock */ + SYSTEM_CLOCK_DFLL_STABLE_TRACKING_TRACK_AFTER_LOCK, + /** Stop tracking after the DFLL has gotten a fine lock */ + SYSTEM_CLOCK_DFLL_STABLE_TRACKING_FIX_AFTER_LOCK = SYSCTRL_DFLLCTRL_STABLE, +}; + +/** + * \brief Chill-cycle behavior of the DFLL module + * + * DFLL chill-cycle behavior modes of the DFLL module. A chill cycle is a period + * of time when the DFLL output frequency is not measured by the unit, to allow + * the output to stabilize after a change in the input clock source. + */ +enum system_clock_dfll_chill_cycle { + /** Enable a chill cycle, where the DFLL output frequency is not measured */ + SYSTEM_CLOCK_DFLL_CHILL_CYCLE_ENABLE, + /** Disable a chill cycle, where the DFLL output frequency is not measured */ + SYSTEM_CLOCK_DFLL_CHILL_CYCLE_DISABLE = SYSCTRL_DFLLCTRL_CCDIS, +}; + +/** + * \brief QuickLock settings for the DFLL module + * + * DFLL QuickLock settings for the DFLL module, to allow for a faster lock of + * the DFLL output frequency at the expense of accuracy. + */ +enum system_clock_dfll_quick_lock { + /** Enable the QuickLock feature for looser lock requirements on the DFLL */ + SYSTEM_CLOCK_DFLL_QUICK_LOCK_ENABLE, + /** Disable the QuickLock feature for strict lock requirements on the DFLL */ + SYSTEM_CLOCK_DFLL_QUICK_LOCK_DISABLE = SYSCTRL_DFLLCTRL_QLDIS, +}; + +/** + * \brief Available clock sources in the system + * + * Clock sources available to the GCLK generators + */ +enum system_clock_source { + /** Internal 8MHz RC oscillator */ + SYSTEM_CLOCK_SOURCE_OSC8M = GCLK_SOURCE_OSC8M, + /** Internal 32kHz RC oscillator */ + SYSTEM_CLOCK_SOURCE_OSC32K = GCLK_SOURCE_OSC32K, + /** External oscillator */ + SYSTEM_CLOCK_SOURCE_XOSC = GCLK_SOURCE_XOSC , + /** External 32kHz oscillator */ + SYSTEM_CLOCK_SOURCE_XOSC32K = GCLK_SOURCE_XOSC32K, + /** Digital Frequency Locked Loop (DFLL) */ + SYSTEM_CLOCK_SOURCE_DFLL = GCLK_SOURCE_DFLL48M, + /** Internal Ultra Low Power 32kHz oscillator */ + SYSTEM_CLOCK_SOURCE_ULP32K = GCLK_SOURCE_OSCULP32K, + /** Generator input pad */ + SYSTEM_CLOCK_SOURCE_GCLKIN = GCLK_SOURCE_GCLKIN, + /** Generic clock generator 1 output */ + SYSTEM_CLOCK_SOURCE_GCLKGEN1 = GCLK_SOURCE_GCLKGEN1, +#ifdef FEATURE_SYSTEM_CLOCK_DPLL + /** Digital Phase Locked Loop (DPLL). + * Check \c FEATURE_SYSTEM_CLOCK_DPLL for which device support it. + */ + SYSTEM_CLOCK_SOURCE_DPLL = GCLK_SOURCE_FDPLL, +#endif +}; + +/** + * \brief List of APB peripheral buses + * + * Available bus clock domains on the APB bus. + */ +enum system_clock_apb_bus { + /** Peripheral bus A on the APB bus. */ + SYSTEM_CLOCK_APB_APBA, + /** Peripheral bus B on the APB bus. */ + SYSTEM_CLOCK_APB_APBB, + /** Peripheral bus C on the APB bus. */ + SYSTEM_CLOCK_APB_APBC, +}; + +/** + * \brief Configuration structure for XOSC + * + * External oscillator clock configuration structure. + */ +struct system_clock_source_xosc_config { + /** External clock type */ + enum system_clock_external external_clock; + /** Crystal oscillator start-up time */ + enum system_xosc_startup startup_time; + /** Enable automatic amplitude gain control */ + bool auto_gain_control; + /** External clock/crystal frequency */ + uint32_t frequency; + /** Keep the XOSC enabled in standby sleep mode */ + bool run_in_standby; + /** Run On Demand. If this is set the XOSC won't run + * until requested by a peripheral */ + bool on_demand; +}; + +/** + * \brief Configuration structure for XOSC32K + * + * External 32KHz oscillator clock configuration structure. + */ +struct system_clock_source_xosc32k_config { + /** External clock type */ + enum system_clock_external external_clock; + /** Crystal oscillator start-up time */ + enum system_xosc32k_startup startup_time; + /** Enable automatic amplitude control */ + bool auto_gain_control; + /** Enable 1kHz output */ + bool enable_1khz_output; + /** Enable 32kHz output */ + bool enable_32khz_output; + /** External clock/crystal frequency */ + uint32_t frequency; + /** Keep the XOSC32K enabled in standby sleep mode */ + bool run_in_standby; + /** Run On Demand. If this is set the XOSC32K won't run + * until requested by a peripheral */ + bool on_demand; + /** Lock configuration after it has been written, + * a device reset will release the lock */ + bool write_once; +}; + +/** + * \brief Configuration structure for OSC8M + * + * Internal 8MHz (nominal) oscillator configuration structure. + */ +struct system_clock_source_osc8m_config { + /* Internal 8MHz RC oscillator prescaler */ + enum system_osc8m_div prescaler; + /** Keep the OSC8M enabled in standby sleep mode */ + bool run_in_standby; + /** Run On Demand. If this is set the OSC8M won't run + * until requested by a peripheral */ + bool on_demand; +}; + +/** + * \brief Configuration structure for OSC32K + * + * Internal 32KHz (nominal) oscillator configuration structure. + */ +struct system_clock_source_osc32k_config { + /** Startup time */ + enum system_osc32k_startup startup_time; + /** Enable 1kHz output */ + bool enable_1khz_output; + /** Enable 32kHz output */ + bool enable_32khz_output; + /** Keep the OSC32K enabled in standby sleep mode */ + bool run_in_standby; + /** Run On Demand. If this is set the OSC32K won't run + * until requested by a peripheral */ + bool on_demand; + /** Lock configuration after it has been written, + * a device reset will release the lock */ + bool write_once; +}; + +/** + * \brief Configuration structure for DFLL + * + * DFLL oscillator configuration structure. + */ +struct system_clock_source_dfll_config { + /** Loop mode */ + enum system_clock_dfll_loop_mode loop_mode; + /** Run On Demand. If this is set the DFLL won't run + * until requested by a peripheral */ + bool on_demand; + /** Enable Quick Lock */ + enum system_clock_dfll_quick_lock quick_lock; + /** Enable Chill Cycle */ + enum system_clock_dfll_chill_cycle chill_cycle; + /** DFLL lock state on wakeup */ + enum system_clock_dfll_wakeup_lock wakeup_lock; + /** DFLL tracking after fine lock */ + enum system_clock_dfll_stable_tracking stable_tracking; + /** Coarse calibration value (Open loop mode) */ + uint8_t coarse_value; + /** Fine calibration value (Open loop mode) */ + uint16_t fine_value; + /** Coarse adjustment max step size (Closed loop mode) */ + uint8_t coarse_max_step; + /** Fine adjustment max step size (Closed loop mode) */ + uint16_t fine_max_step; + /** DFLL multiply factor (Closed loop mode */ + uint16_t multiply_factor; +}; + +/** + * \name External Oscillator management + * @{ + */ + +/** + * \brief Retrieve the default configuration for XOSC + * + * Fills a configuration structure with the default configuration for an + * external oscillator module: + * - External Crystal + * - Start-up time of 16384 external clock cycles + * - Automatic crystal gain control mode enabled + * - Frequency of 12MHz + * - Don't run in STANDBY sleep mode + * - Run only when requested by peripheral (on demand) + * + * \param[out] config Configuration structure to fill with default values + */ +static inline void system_clock_source_xosc_get_config_defaults( + struct system_clock_source_xosc_config *const config) +{ + Assert(config); + + config->external_clock = SYSTEM_CLOCK_EXTERNAL_CRYSTAL; + config->startup_time = SYSTEM_XOSC_STARTUP_16384; + config->auto_gain_control = true; + config->frequency = 12000000UL; + config->run_in_standby = false; + config->on_demand = true; +} + +void system_clock_source_xosc_set_config( + struct system_clock_source_xosc_config *const config); + +/** + * @} + */ + + +/** + * \name External 32KHz Oscillator management + * @{ + */ + +/** + * \brief Retrieve the default configuration for XOSC32K + * + * Fills a configuration structure with the default configuration for an + * external 32KHz oscillator module: + * - External Crystal + * - Start-up time of 16384 external clock cycles + * - Automatic crystal gain control mode disabled + * - Frequency of 32.768KHz + * - 1KHz clock output disabled + * - 32KHz clock output enabled + * - Don't run in STANDBY sleep mode + * - Run only when requested by peripheral (on demand) + * - Don't lock registers after configuration has been written + * + * \param[out] config Configuration structure to fill with default values + */ +static inline void system_clock_source_xosc32k_get_config_defaults( + struct system_clock_source_xosc32k_config *const config) +{ + Assert(config); + + config->external_clock = SYSTEM_CLOCK_EXTERNAL_CRYSTAL; + config->startup_time = SYSTEM_XOSC32K_STARTUP_16384; + config->auto_gain_control = false; + config->frequency = 32768UL; + config->enable_1khz_output = false; + config->enable_32khz_output = true; + config->run_in_standby = false; + config->on_demand = true; + config->write_once = false; +} + +void system_clock_source_xosc32k_set_config( + struct system_clock_source_xosc32k_config *const config); +/** + * @} + */ + + +/** + * \name Internal 32KHz Oscillator management + * @{ + */ + +/** + * \brief Retrieve the default configuration for OSC32K + * + * Fills a configuration structure with the default configuration for an + * internal 32KHz oscillator module: + * - 1KHz clock output enabled + * - 32KHz clock output enabled + * - Don't run in STANDBY sleep mode + * - Run only when requested by peripheral (on demand) + * - Set startup time to 130 cycles + * - Don't lock registers after configuration has been written + * + * \param[out] config Configuration structure to fill with default values + */ +static inline void system_clock_source_osc32k_get_config_defaults( + struct system_clock_source_osc32k_config *const config) +{ + Assert(config); + + config->enable_1khz_output = true; + config->enable_32khz_output = true; + config->run_in_standby = false; + config->on_demand = true; + config->startup_time = SYSTEM_OSC32K_STARTUP_130; + config->write_once = false; +} + +void system_clock_source_osc32k_set_config( + struct system_clock_source_osc32k_config *const config); + +/** + * @} + */ + + +/** + * \name Internal 8MHz Oscillator management + * @{ + */ + +/** + * \brief Retrieve the default configuration for OSC8M + * + * Fills a configuration structure with the default configuration for an + * internal 8MHz (nominal) oscillator module: + * - Clock output frequency divided by a factor of 8 + * - Don't run in STANDBY sleep mode + * - Run only when requested by peripheral (on demand) + * + * \param[out] config Configuration structure to fill with default values + */ +static inline void system_clock_source_osc8m_get_config_defaults( + struct system_clock_source_osc8m_config *const config) +{ + Assert(config); + + config->prescaler = SYSTEM_OSC8M_DIV_8; + config->run_in_standby = false; + config->on_demand = true; +} + +void system_clock_source_osc8m_set_config( + struct system_clock_source_osc8m_config *const config); + +/** + * @} + */ + + +/** + * \name Internal DFLL management + * @{ + */ + +/** + * \brief Retrieve the default configuration for DFLL + * + * Fills a configuration structure with the default configuration for a + * DFLL oscillator module: + * - Open loop mode + * - QuickLock mode enabled + * - Chill cycle enabled + * - Output frequency lock maintained during device wake-up + * - Continuous tracking of the output frequency + * - Default tracking values at the mid-points for both coarse and fine + * tracking parameters + * - Don't run in STANDBY sleep mode + * - Run only when requested by peripheral (on demand) + * + * \param[out] config Configuration structure to fill with default values + */ +static inline void system_clock_source_dfll_get_config_defaults( + struct system_clock_source_dfll_config *const config) +{ + Assert(config); + + config->loop_mode = SYSTEM_CLOCK_DFLL_LOOP_MODE_OPEN; + config->quick_lock = SYSTEM_CLOCK_DFLL_QUICK_LOCK_ENABLE; + config->chill_cycle = SYSTEM_CLOCK_DFLL_CHILL_CYCLE_ENABLE; + config->wakeup_lock = SYSTEM_CLOCK_DFLL_WAKEUP_LOCK_KEEP; + config->stable_tracking = SYSTEM_CLOCK_DFLL_STABLE_TRACKING_TRACK_AFTER_LOCK; + config->on_demand = true; + + /* Open loop mode calibration value */ + config->coarse_value = 0x1f / 4; /* Midpoint */ + config->fine_value = 0xff / 4; /* Midpoint */ + + /* Closed loop mode */ + config->coarse_max_step = 1; + config->fine_max_step = 1; + config->multiply_factor = 6; /* Multiply 8MHz by 6 to get 48MHz */ +} + +void system_clock_source_dfll_set_config( + struct system_clock_source_dfll_config *const config); + +/** + * @} + */ + +/** + * \name Clock source management + * @{ + */ +enum status_code system_clock_source_write_calibration( + const enum system_clock_source system_clock_source, + const uint16_t calibration_value, + const uint8_t freq_range); + +enum status_code system_clock_source_enable( + const enum system_clock_source system_clock_source); + +enum status_code system_clock_source_disable( + const enum system_clock_source clk_source); + +bool system_clock_source_is_ready( + const enum system_clock_source clk_source); + +uint32_t system_clock_source_get_hz( + const enum system_clock_source clk_source); + +/** + * @} + */ + +/** + * \name Main clock management + * @{ + */ + +#ifdef FEATURE_SYSTEM_CLOCK_FAILURE_DETECT +/** + * \brief Enable or disable the main clock failure detection. + * + * This mechanism allows switching automatically the main clock to the safe + * RCSYS clock, when the main clock source is considered off. + * + * This may happen for instance when an external crystal is selected as the + * clock source of the main clock and the crystal dies. The mechanism is to + * detect, during a RCSYS period, at least one rising edge of the main clock. + * If no rising edge is seen the clock is considered failed. + * As soon as the detector is enabled, the clock failure detector + * CFD) will monitor the divided main clock. When a clock failure is detected, + * the main clock automatically switches to the RCSYS clock and the CFD + * interrupt is generated if enabled. + * + * \note The failure detect must be disabled if the system clock is the same or + * slower than 32kHz as it will believe the system clock has failed with + * a too-slow clock. + * + * \param[in] enable Boolean \c true to enable, \c false to disable detection + */ +static inline void system_main_clock_set_failure_detect( + const bool enable) +{ + if (enable) { + PM->CTRL.reg |= PM_CTRL_CFDEN; + } else { + PM->CTRL.reg &= ~PM_CTRL_CFDEN; + } +} +#endif + +/** + * \brief Set main CPU clock divider. + * + * Sets the clock divider used on the main clock to provide the CPU clock. + * + * \param[in] divider CPU clock divider to set + */ +static inline void system_cpu_clock_set_divider( + const enum system_main_clock_div divider) +{ + Assert(((uint32_t)divider & PM_CPUSEL_CPUDIV_Msk) == divider); + PM->CPUSEL.reg = (uint32_t)divider; +} + +/** + * \brief Retrieves the current frequency of the CPU core. + * + * Retrieves the operating frequency of the CPU core, obtained from the main + * generic clock and the set CPU bus divider. + * + * \return Current CPU frequency in Hz. + */ +static inline uint32_t system_cpu_clock_get_hz(void) +{ + return (system_gclk_gen_get_hz(GCLK_GENERATOR_0) >> PM->CPUSEL.reg); +} + +/** + * \brief Set APBx clock divider. + * + * Set the clock divider used on the main clock to provide the clock for the + * given APBx bus. + * + * \param[in] divider APBx bus divider to set + * \param[in] bus APBx bus to set divider for + * + * \returns Status of the clock division change operation. + * + * \retval STATUS_ERR_INVALID_ARG Invalid bus ID was given + * \retval STATUS_OK The APBx clock was set successfully + */ +static inline enum status_code system_apb_clock_set_divider( + const enum system_clock_apb_bus bus, + const enum system_main_clock_div divider) +{ + switch (bus) { + case SYSTEM_CLOCK_APB_APBA: + PM->APBASEL.reg = (uint32_t)divider; + break; + case SYSTEM_CLOCK_APB_APBB: + PM->APBBSEL.reg = (uint32_t)divider; + break; + case SYSTEM_CLOCK_APB_APBC: + PM->APBCSEL.reg = (uint32_t)divider; + break; + default: + Assert(false); + return STATUS_ERR_INVALID_ARG; + } + + return STATUS_OK; +} + +/** + * \brief Retrieves the current frequency of a ABPx. + * + * Retrieves the operating frequency of an APBx bus, obtained from the main + * generic clock and the set APBx bus divider. + * + * \return Current APBx bus frequency in Hz. + */ +static inline uint32_t system_apb_clock_get_hz( + const enum system_clock_apb_bus bus) +{ + uint16_t bus_divider = 0; + + switch (bus) { + case SYSTEM_CLOCK_APB_APBA: + bus_divider = PM->APBASEL.reg; + break; + case SYSTEM_CLOCK_APB_APBB: + bus_divider = PM->APBBSEL.reg; + break; + case SYSTEM_CLOCK_APB_APBC: + bus_divider = PM->APBCSEL.reg; + break; + default: + Assert(false); + return 0; + } + + return (system_gclk_gen_get_hz(GCLK_GENERATOR_0) >> bus_divider); +} + + +/** + * @} + */ + +/** + * \name Bus clock masking + * @{ + */ + +/** + * \brief Set bits in the clock mask for the AHB bus. + * + * This function will set bits in the clock mask for the AHB bus. + * Any bits set to 1 will enable that clock, 0 bits in the mask + * will be ignored + * + * \param[in] ahb_mask AHB clock mask to enable + */ +static inline void system_ahb_clock_set_mask( + const uint32_t ahb_mask) +{ + PM->AHBMASK.reg |= ahb_mask; +} + +/** + * \brief Clear bits in the clock mask for the AHB bus. + * + * This function will clear bits in the clock mask for the AHB bus. + * Any bits set to 1 will disable that clock, 0 bits in the mask + * will be ignored. + * + * \param[in] ahb_mask AHB clock mask to disable + */ +static inline void system_ahb_clock_clear_mask( + const uint32_t ahb_mask) +{ + PM->AHBMASK.reg &= ~ahb_mask; +} + +/** + * \brief Set bits in the clock mask for an APBx bus. + * + * This function will set bits in the clock mask for an APBx bus. + * Any bits set to 1 will enable the corresponding module clock, zero bits in + * the mask will be ignored. + * + * \param[in] mask APBx clock mask, a \c SYSTEM_CLOCK_APB_APBx constant from + * the device header files + * \param[in] bus Bus to set clock mask bits for, a mask of \c PM_APBxMASK_* + * constants from the device header files + * + * \returns Status indicating the result of the clock mask change operation. + * + * \retval STATUS_ERR_INVALID_ARG Invalid bus given + * \retval STATUS_OK The clock mask was set successfully + */ +static inline enum status_code system_apb_clock_set_mask( + const enum system_clock_apb_bus bus, + const uint32_t mask) +{ + switch (bus) { + case SYSTEM_CLOCK_APB_APBA: + PM->APBAMASK.reg |= mask; + break; + + case SYSTEM_CLOCK_APB_APBB: + PM->APBBMASK.reg |= mask; + break; + + case SYSTEM_CLOCK_APB_APBC: + PM->APBCMASK.reg |= mask; + break; + + default: + Assert(false); + return STATUS_ERR_INVALID_ARG; + + } + + return STATUS_OK; +} + +/** + * \brief Clear bits in the clock mask for an APBx bus. + * + * This function will clear bits in the clock mask for an APBx bus. + * Any bits set to 1 will disable the corresponding module clock, zero bits in + * the mask will be ignored. + * + * \param[in] mask APBx clock mask, a \c SYSTEM_CLOCK_APB_APBx constant from + * the device header files + * \param[in] bus Bus to clear clock mask bits for + * + * \returns Status indicating the result of the clock mask change operation. + * + * \retval STATUS_ERR_INVALID_ARG Invalid bus ID was given. + * \retval STATUS_OK The clock mask was changed successfully. + */ +static inline enum status_code system_apb_clock_clear_mask( + const enum system_clock_apb_bus bus, + const uint32_t mask) +{ + switch (bus) { + case SYSTEM_CLOCK_APB_APBA: + PM->APBAMASK.reg &= ~mask; + break; + + case SYSTEM_CLOCK_APB_APBB: + PM->APBBMASK.reg &= ~mask; + break; + + case SYSTEM_CLOCK_APB_APBC: + PM->APBCMASK.reg &= ~mask; + break; + + default: + Assert(false); + return STATUS_ERR_INVALID_ARG; + } + + return STATUS_OK; +} + +/** + * @} + */ + +#ifdef FEATURE_SYSTEM_CLOCK_DPLL +/** + * \brief Reference clock source of the DPLL module + */ +enum system_clock_source_dpll_reference_clock { + /** Select CLK_DPLL_REF0 as clock reference */ + SYSTEM_CLOCK_SOURCE_DPLL_REFERENCE_CLOCK_REF0, + /** Select CLK_DPLL_REF1 as clock reference */ + SYSTEM_CLOCK_SOURCE_DPLL_REFERENCE_CLOCK_REF1, + /** Select GCLK_DPLL as clock reference */ + SYSTEM_CLOCK_SOURCE_DPLL_REFERENCE_CLOCK_GCLK, +}; + +/** + * \brief Lock time-out value of the DPLL module + */ +enum system_clock_source_dpll_lock_time { + /** Set no time-out as default */ + SYSTEM_CLOCK_SOURCE_DPLL_LOCK_TIME_DEFAULT, + /** Set time-out if no lock within 8 ms */ + SYSTEM_CLOCK_SOURCE_DPLL_LOCK_TIME_8MS = 0x04, + /** Set time-out if no lock within 9 ms */ + SYSTEM_CLOCK_SOURCE_DPLL_LOCK_TIME_9MS, + /** Set time-out if no lock within 10 ms */ + SYSTEM_CLOCK_SOURCE_DPLL_LOCK_TIME_10MS, + /** Set time-out if no lock within 11 ms */ + SYSTEM_CLOCK_SOURCE_DPLL_LOCK_TIME_11MS, +}; + +/** + * \brief Filter type of the DPLL module + */ +enum system_clock_source_dpll_filter { + /** Default filter mode */ + SYSTEM_CLOCK_SOURCE_DPLL_FILTER_DEFAULT, + /** Low bandwidth filter */ + SYSTEM_CLOCK_SOURCE_DPLL_FILTER_LOW_BANDWIDTH_FILTER, + /** High bandwidth filter */ + SYSTEM_CLOCK_SOURCE_DPLL_FILTER_HIGH_BANDWIDTH_FILTER, + /** High damping filter */ + SYSTEM_CLOCK_SOURCE_DPLL_FILTER_HIGH_DAMPING_FILTER, +}; + +/** + * \brief Configuration structure for DPLL + * + * DPLL oscillator configuration structure. + */ +struct system_clock_source_dpll_config { + /** Run On Demand. If this is set the DPLL won't run + * until requested by a peripheral */ + bool on_demand; + /** Keep the DPLL enabled in standby sleep mode */ + bool run_in_standby; + /** Bypass lock signal */ + bool lock_bypass; + /** Wake up fast. If this is set DPLL output clock is enabled after + * the startup time */ + bool wake_up_fast; + /** Enable low power mode */ + bool low_power_enable; + + /** Output frequency of the clock */ + uint32_t output_frequency; + /** Reference frequency of the clock */ + uint32_t reference_frequency; + /** Devider of reference clock */ + uint16_t reference_divider; + + /** Filter type of the DPLL module */ + enum system_clock_source_dpll_filter filter; + /** Lock time-out value of the DPLL module */ + enum system_clock_source_dpll_lock_time lock_time; + /** Reference clock source of the DPLL module */ + enum system_clock_source_dpll_reference_clock reference_clock; +}; + +/** + * \name Internal DPLL management + * @{ + */ + +/** + * \brief Retrieve the default configuration for DPLL + * + * Fills a configuration structure with the default configuration for a + * DPLL oscillator module: + * - Run only when requested by peripheral (on demand) + * - Don't run in STANDBY sleep mode + * - Lock bypass disabled + * - Fast wake up disabled + * - Low power mode disabled + * - Output frequency is 48MHz + * - Reference clock frequency is 32768Hz + * - Not divide reference clock + * - Select REF0 as reference clock + * - Set lock time to default mode + * - Use default filter + * + * \param[out] config Configuration structure to fill with default values + */ +static inline void system_clock_source_dpll_get_config_defaults( + struct system_clock_source_dpll_config *const config) +{ + config->on_demand = true; + config->run_in_standby = false; + config->lock_bypass = false; + config->wake_up_fast = false; + config->low_power_enable = false; + + config->output_frequency = 48000000; + config->reference_frequency = 32768; + config->reference_divider = 1; + config->reference_clock = SYSTEM_CLOCK_SOURCE_DPLL_REFERENCE_CLOCK_REF0; + + config->lock_time = SYSTEM_CLOCK_SOURCE_DPLL_LOCK_TIME_DEFAULT; + config->filter = SYSTEM_CLOCK_SOURCE_DPLL_FILTER_DEFAULT; +}; + +void system_clock_source_dpll_set_config( + struct system_clock_source_dpll_config *const config); + +/* @} */ +#endif + +/** + * \name System Clock Initialization + * @{ + */ + +void system_clock_init(void); + +/** + * @} + */ + +/** + * \name System Flash Wait States + * @{ + */ + +/** + * \brief Set flash controller wait states + * + * Will set the number of wait states that are used by the onboard + * flash memory. The number of wait states depend on both device + * supply voltage and CPU speed. The required number of wait states + * can be found in the electrical characteristics of the device. + * + * \param[in] wait_states Number of wait states to use for internal flash + */ +static inline void system_flash_set_waitstates(uint8_t wait_states) +{ + Assert(NVMCTRL_CTRLB_RWS((uint32_t)wait_states) == + ((uint32_t)wait_states << NVMCTRL_CTRLB_RWS_Pos)); + + NVMCTRL->CTRLB.bit.RWS = wait_states; +} +/** + * @} + */ + +/** + * @} + */ + +/** + * \page asfdoc_sam0_system_clock_extra Extra Information for SYSTEM CLOCK Driver + * + * \section asfdoc_sam0_system_clock_extra_acronyms Acronyms + * Below is a table listing the acronyms used in this module, along with their + * intended meanings. + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
AcronymDescription
DFLLDigital Frequency Locked Loop
MUXMultiplexer
OSC32KInternal 32KHz Oscillator
OSC8MInternal 8MHz Oscillator
PLLPhase Locked Loop
OSCOscillator
XOSCExternal Oscillator
XOSC32KExternal 32KHz Oscillator
AHBAdvanced High-performance Bus
APBAdvanced Peripheral Bus
DPLLDigital Phase Locked Loop
+ * + * + * \section asfdoc_sam0_system_clock_extra_dependencies Dependencies + * This driver has the following dependencies: + * + * - None + * + * + * \section asfdoc_sam0_system_clock_extra_errata Errata + * + * - This driver implements workaround for errata 10558 + * + * "Several reset values of SYSCTRL.INTFLAG are wrong (BOD and DFLL)" + * When system_init is called it will reset these interrupts flags before they are used. + + * - This driver implements experimental workaround for errata 9905 + * + * "The DFLL clock must be requested before being configured otherwise a + * write access to a DFLL register can freeze the device." + * This driver will enable and configure the DFLL before the ONDEMAND bit is set. + * + * + * \section asfdoc_sam0_system_clock_extra_history Module History + * An overview of the module history is presented in the table below, with + * details on the enhancements and fixes made to the module since its first + * release. The current version of this corresponds to the newest version in + * the table. + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Changelog
+ * \li Corrected OSC32K startup time definitions. + * \li Support locking of OSC32K and XOSC32K config register (default: false). + * \li Added DPLL support, functions added: + * \c system_clock_source_dpll_get_config_defaults() and + * \c system_clock_source_dpll_set_config(). + * \li Moved gclk channel locking feature out of the config struct, + * functions added: + * \c system_gclk_chan_lock(), + * \c system_gclk_chan_is_locked(), + * \c system_gclk_chan_is_enabled() and + * \c system_gclk_gen_is_enabled(). + *
Fixed \c system_gclk_chan_disable() deadlocking if a channel is enabled + * and configured to a failed/not running clock generator.
+ * \li Changed default value for CONF_CLOCK_DFLL_ON_DEMAND from \c true to \c false. + * \li Fixed system_flash_set_waitstates() failing with an assertion + * if an odd number of wait states provided. + *
+ * \li Updated dfll configuration function to implement workaround for + * errata 9905 in the DFLL module. + * \li Updated \c system_clock_init() to reset interrupt flags before + * they are used, errata 10558. + * \li Fixed \c system_clock_source_get_hz() to return correcy DFLL + * frequency number. + *
\li Fixed \c system_clock_source_is_ready not returning the correct + * state for \c SYSTEM_CLOCK_SOURCE_OSC8M. + * \li Renamed the various \c system_clock_source_*_get_default_config() + * functions to \c system_clock_source_*_get_config_defaults() to + * match the remainder of ASF. + * \li Added OSC8M calibration constant loading from the device signature + * row when the oscillator is initialized. + * \li Updated default configuration of the XOSC32 to disable Automatic + * Gain Control due to silicon errata. + *
Initial Release
+ */ + +/** + * \page asfdoc_sam0_system_clock_exqsg Examples for System Clock Driver + * + * This is a list of the available Quick Start guides (QSGs) and example + * applications for \ref asfdoc_sam0_system_clock_group. QSGs are simple + * examples with step-by-step instructions to configure and use this driver in + * a selection of use cases. Note that QSGs can be compiled as a standalone + * application or be added to the user application. + * + * - \subpage asfdoc_sam0_system_clock_basic_use_case + * - \subpage asfdoc_sam0_system_gclk_basic_use_case + * + * \page asfdoc_sam0_system_clock_document_revision_history Document Revision History + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Doc. Rev. + * Date + * Comments + *
E04/2014Added support for SAMD10/D11.
D02/2014Added support for SAMR21.
C01/2014Added support for SAMD21.
B06/2013Corrected documentation typos. Fixed missing steps in the Basic + * Use Case Quick Start Guide.
A06/2013Initial release
+ */ + +#ifdef __cplusplus +} +#endif + +#endif /* SYSTEM_CLOCK_H_INCLUDED */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/clock_samd21_r21/clock.c b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/clock_samd21_r21/clock.c new file mode 100644 index 0000000..e8c9c3b --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/clock_samd21_r21/clock.c @@ -0,0 +1,963 @@ +/** + * \file + * + * \brief SAM D21/R21 Clock Driver + * + * Copyright (C) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include +#include +#include + +#ifndef SYSCTRL_FUSES_OSC32K_ADDR +# define SYSCTRL_FUSES_OSC32K_ADDR SYSCTRL_FUSES_OSC32K_CAL_ADDR +# define SYSCTRL_FUSES_OSC32K_Pos SYSCTRL_FUSES_OSC32K_CAL_Pos +#endif + +/** + * \internal + * \brief DFLL-specific data container + */ +struct _system_clock_dfll_config { + uint32_t control; + uint32_t val; + uint32_t mul; +}; + +/** + * \internal + * \brief DPLL-specific data container + */ +struct _system_clock_dpll_config { + uint32_t frequency; +}; + + +/** + * \internal + * \brief XOSC-specific data container + */ +struct _system_clock_xosc_config { + uint32_t frequency; +}; + +/** + * \internal + * \brief System clock module data container + */ +struct _system_clock_module { + volatile struct _system_clock_dfll_config dfll; + +#ifdef FEATURE_SYSTEM_CLOCK_DPLL + volatile struct _system_clock_dpll_config dpll; +#endif + + volatile struct _system_clock_xosc_config xosc; + volatile struct _system_clock_xosc_config xosc32k; +}; + +/** + * \internal + * \brief Internal module instance to cache configuration values + */ +static struct _system_clock_module _system_clock_inst = { + .dfll = { + .control = 0, + .val = 0, + .mul = 0, + }, + +#ifdef FEATURE_SYSTEM_CLOCK_DPLL + .dpll = { + .frequency = 0, + }, +#endif + .xosc = { + .frequency = 0, + }, + .xosc32k = { + .frequency = 0, + }, + }; + +/** + * \internal + * \brief Wait for sync to the DFLL control registers + */ +static inline void _system_dfll_wait_for_sync(void) +{ + while (!(SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_DFLLRDY)) { + /* Wait for DFLL sync */ + } +} + +/** + * \internal + * \brief Wait for sync to the OSC32K control registers + */ +static inline void _system_osc32k_wait_for_sync(void) +{ + while (!(SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_OSC32KRDY)) { + /* Wait for OSC32K sync */ + } +} + +static inline void _system_clock_source_dfll_set_config_errata_9905(void) +{ + + /* Disable ONDEMAND mode while writing configurations */ + SYSCTRL->DFLLCTRL.reg = _system_clock_inst.dfll.control & ~SYSCTRL_DFLLCTRL_ONDEMAND; + _system_dfll_wait_for_sync(); + + SYSCTRL->DFLLMUL.reg = _system_clock_inst.dfll.mul; + SYSCTRL->DFLLVAL.reg = _system_clock_inst.dfll.val; + + /* Write full configuration to DFLL control register */ + SYSCTRL->DFLLCTRL.reg = _system_clock_inst.dfll.control; +} + +/** + * \brief Retrieve the frequency of a clock source + * + * Determines the current operating frequency of a given clock source. + * + * \param[in] clock_source Clock source to get the frequency of + * + * \returns Frequency of the given clock source, in Hz + */ +uint32_t system_clock_source_get_hz( + const enum system_clock_source clock_source) +{ + switch (clock_source) { + case SYSTEM_CLOCK_SOURCE_XOSC: + return _system_clock_inst.xosc.frequency; + + case SYSTEM_CLOCK_SOURCE_OSC8M: + return 8000000UL >> SYSCTRL->OSC8M.bit.PRESC; + + case SYSTEM_CLOCK_SOURCE_OSC32K: + return 32768UL; + + case SYSTEM_CLOCK_SOURCE_ULP32K: + return 32768UL; + + case SYSTEM_CLOCK_SOURCE_XOSC32K: + return _system_clock_inst.xosc32k.frequency; + + case SYSTEM_CLOCK_SOURCE_DFLL: + + /* Check if the DFLL has been configured */ + if (!(_system_clock_inst.dfll.control & SYSCTRL_DFLLCTRL_ENABLE)) + return 0; + + /* Make sure that the DFLL module is ready */ + _system_dfll_wait_for_sync(); + + /* Check if operating in closed loop mode */ + if (_system_clock_inst.dfll.control & SYSCTRL_DFLLCTRL_MODE) { + return system_gclk_chan_get_hz(SYSCTRL_GCLK_ID_DFLL48) * + (_system_clock_inst.dfll.mul & 0xffff); + } + + return 48000000UL; + +#ifdef FEATURE_SYSTEM_CLOCK_DPLL + case SYSTEM_CLOCK_SOURCE_DPLL: + if (!(SYSCTRL->DPLLSTATUS.reg & SYSCTRL_DPLLSTATUS_ENABLE)) { + return 0; + } + + return _system_clock_inst.dpll.frequency; +#endif + + default: + return 0; + } +} + +/** + * \brief Configure the internal OSC8M oscillator clock source + * + * Configures the 8MHz (nominal) internal RC oscillator with the given + * configuration settings. + * + * \param[in] config OSC8M configuration structure containing the new config + */ +void system_clock_source_osc8m_set_config( + struct system_clock_source_osc8m_config *const config) +{ + SYSCTRL_OSC8M_Type temp = SYSCTRL->OSC8M; + + /* Use temporary struct to reduce register access */ + temp.bit.PRESC = config->prescaler; + temp.bit.ONDEMAND = config->on_demand; + temp.bit.RUNSTDBY = config->run_in_standby; + + SYSCTRL->OSC8M = temp; +} + +/** + * \brief Configure the internal OSC32K oscillator clock source + * + * Configures the 32KHz (nominal) internal RC oscillator with the given + * configuration settings. + * + * \param[in] config OSC32K configuration structure containing the new config + */ +void system_clock_source_osc32k_set_config( + struct system_clock_source_osc32k_config *const config) +{ + SYSCTRL_OSC32K_Type temp = SYSCTRL->OSC32K; + + /* Update settings via a temporary struct to reduce register access */ + temp.bit.EN1K = config->enable_1khz_output; + temp.bit.EN32K = config->enable_32khz_output; + temp.bit.STARTUP = config->startup_time; + temp.bit.ONDEMAND = config->on_demand; + temp.bit.RUNSTDBY = config->run_in_standby; + temp.bit.WRTLOCK = config->write_once; + + SYSCTRL->OSC32K = temp; +} + +/** + * \brief Configure the external oscillator clock source + * + * Configures the external oscillator clock source with the given configuration + * settings. + * + * \param[in] config External oscillator configuration structure containing + * the new config + */ +void system_clock_source_xosc_set_config( + struct system_clock_source_xosc_config *const config) +{ + SYSCTRL_XOSC_Type temp = SYSCTRL->XOSC; + + temp.bit.STARTUP = config->startup_time; + + if (config->external_clock == SYSTEM_CLOCK_EXTERNAL_CRYSTAL) { + temp.bit.XTALEN = 1; + } else { + temp.bit.XTALEN = 0; + } + + temp.bit.AMPGC = config->auto_gain_control; + + /* Set gain if automatic gain control is not selected */ + if (!config->auto_gain_control) { + if (config->frequency <= 2000000) { + temp.bit.GAIN = 0; + } else if (config->frequency <= 4000000) { + temp.bit.GAIN = 1; + } else if (config->frequency <= 8000000) { + temp.bit.GAIN = 2; + } else if (config->frequency <= 16000000) { + temp.bit.GAIN = 3; + } else if (config->frequency <= 30000000) { + temp.bit.GAIN = 4; + } + + } + + temp.bit.ONDEMAND = config->on_demand; + temp.bit.RUNSTDBY = config->run_in_standby; + + /* Store XOSC frequency for internal use */ + _system_clock_inst.xosc.frequency = config->frequency; + + SYSCTRL->XOSC = temp; +} + +/** + * \brief Configure the XOSC32K external 32KHz oscillator clock source + * + * Configures the external 32KHz oscillator clock source with the given + * configuration settings. + * + * \param[in] config XOSC32K configuration structure containing the new config + */ +void system_clock_source_xosc32k_set_config( + struct system_clock_source_xosc32k_config *const config) +{ + SYSCTRL_XOSC32K_Type temp = SYSCTRL->XOSC32K; + + temp.bit.STARTUP = config->startup_time; + + if (config->external_clock == SYSTEM_CLOCK_EXTERNAL_CRYSTAL) { + temp.bit.XTALEN = 1; + } else { + temp.bit.XTALEN = 0; + } + + temp.bit.AAMPEN = config->auto_gain_control; + temp.bit.EN1K = config->enable_1khz_output; + temp.bit.EN32K = config->enable_32khz_output; + + temp.bit.ONDEMAND = config->on_demand; + temp.bit.RUNSTDBY = config->run_in_standby; + temp.bit.WRTLOCK = config->write_once; + + /* Cache the new frequency in case the user needs to check the current + * operating frequency later */ + _system_clock_inst.xosc32k.frequency = config->frequency; + + SYSCTRL->XOSC32K = temp; +} + +/** + * \brief Configure the DFLL clock source + * + * Configures the Digital Frequency Locked Loop clock source with the given + * configuration settings. + * + * \note The DFLL will be running when this function returns, as the DFLL module + * needs to be enabled in order to perform the module configuration. + * + * \param[in] config DFLL configuration structure containing the new config + */ +void system_clock_source_dfll_set_config( + struct system_clock_source_dfll_config *const config) +{ + _system_clock_inst.dfll.val = + SYSCTRL_DFLLVAL_COARSE(config->coarse_value) | + SYSCTRL_DFLLVAL_FINE(config->fine_value); + + _system_clock_inst.dfll.control = + (uint32_t)config->wakeup_lock | + (uint32_t)config->stable_tracking | + (uint32_t)config->quick_lock | + (uint32_t)config->chill_cycle | + ((uint32_t)config->on_demand << SYSCTRL_DFLLCTRL_ONDEMAND_Pos); + + if (config->loop_mode == SYSTEM_CLOCK_DFLL_LOOP_MODE_CLOSED) { + + _system_clock_inst.dfll.mul = + SYSCTRL_DFLLMUL_CSTEP(config->coarse_max_step) | + SYSCTRL_DFLLMUL_FSTEP(config->fine_max_step) | + SYSCTRL_DFLLMUL_MUL(config->multiply_factor); + + /* Enable the closed loop mode */ + _system_clock_inst.dfll.control |= config->loop_mode; + } + if (config->loop_mode == SYSTEM_CLOCK_DFLL_LOOP_MODE_USB_RECOVERY) { + + _system_clock_inst.dfll.mul = + SYSCTRL_DFLLMUL_MUL(config->multiply_factor); + + /* Enable the USB recovery mode */ + _system_clock_inst.dfll.control |= config->loop_mode | + SYSCTRL_DFLLCTRL_BPLCKC; + } +} + +#ifdef FEATURE_SYSTEM_CLOCK_DPLL +/** + * \brief Configure the DPLL clock source + * + * Configures the Digital Phase-Locked Loop clock source with the given + * configuration settings. + * + * \note The DPLL will be running when this function returns, as the DPLL module + * needs to be enabled in order to perform the module configuration. + * + * \param[in] config DPLL configuration structure containing the new config + */ +void system_clock_source_dpll_set_config( + struct system_clock_source_dpll_config *const config) +{ + + uint32_t tmpldr; + uint8_t tmpldrfrac; + uint32_t refclk; + + refclk = config->reference_frequency; + + /* Only reference clock REF1 can be divided */ + if (config->reference_clock == SYSTEM_CLOCK_SOURCE_DPLL_REFERENCE_CLOCK_REF1) { + refclk = refclk / config->reference_divider; + } + + /* Calculate LDRFRAC and LDR */ + tmpldr = (config->output_frequency << 4) / refclk; + tmpldrfrac = tmpldr & 0x0f; + tmpldr = (tmpldr >> 4) - 1; + + SYSCTRL->DPLLCTRLA.reg = + ((uint32_t)config->on_demand << SYSCTRL_DPLLCTRLA_ONDEMAND_Pos) | + ((uint32_t)config->run_in_standby << SYSCTRL_DPLLCTRLA_RUNSTDBY_Pos); + + SYSCTRL->DPLLRATIO.reg = + SYSCTRL_DPLLRATIO_LDRFRAC(tmpldrfrac) | + SYSCTRL_DPLLRATIO_LDR(tmpldr); + + SYSCTRL->DPLLCTRLB.reg = + SYSCTRL_DPLLCTRLB_DIV(config->reference_divider) | + ((uint32_t)config->lock_bypass << SYSCTRL_DPLLCTRLB_LBYPASS_Pos) | + SYSCTRL_DPLLCTRLB_LTIME(config->lock_time) | + SYSCTRL_DPLLCTRLB_REFCLK(config->reference_clock) | + ((uint32_t)config->wake_up_fast << SYSCTRL_DPLLCTRLB_WUF_Pos) | + ((uint32_t)config->low_power_enable << SYSCTRL_DPLLCTRLB_LPEN_Pos) | + SYSCTRL_DPLLCTRLB_FILTER(config->filter); + + /* + * Fck = Fckrx * (LDR + 1 + LDRFRAC / 16) + */ + _system_clock_inst.dpll.frequency = + (config->reference_frequency * + (((tmpldr + 1) << 4) + tmpldrfrac) + ) >> 4; +} +#endif + +/** + * \brief Writes the calibration values for a given oscillator clock source + * + * Writes an oscillator calibration value to the given oscillator control + * registers. The acceptable ranges are: + * + * For OSC32K: + * - 7 bits (max value 128) + * For OSC8MHZ: + * - 8 bits (Max value 255) + * For OSCULP: + * - 5 bits (Max value 32) + * + * \note The frequency range parameter applies only when configuring the 8MHz + * oscillator and will be ignored for the other oscillators. + * + * \param[in] clock_source Clock source to calibrate + * \param[in] calibration_value Calibration value to write + * \param[in] freq_range Frequency range (8MHz oscillator only) + * + * \retval STATUS_OK The calibration value was written + * successfully. + * \retval STATUS_ERR_INVALID_ARG The setting is not valid for selected clock + * source. + */ +enum status_code system_clock_source_write_calibration( + const enum system_clock_source clock_source, + const uint16_t calibration_value, + const uint8_t freq_range) +{ + switch (clock_source) { + case SYSTEM_CLOCK_SOURCE_OSC8M: + + if (calibration_value > 0xfff || freq_range > 4) { + return STATUS_ERR_INVALID_ARG; + } + + SYSCTRL->OSC8M.bit.CALIB = calibration_value; + SYSCTRL->OSC8M.bit.FRANGE = freq_range; + break; + + case SYSTEM_CLOCK_SOURCE_OSC32K: + + if (calibration_value > 128) { + return STATUS_ERR_INVALID_ARG; + } + + _system_osc32k_wait_for_sync(); + SYSCTRL->OSC32K.bit.CALIB = calibration_value; + break; + + case SYSTEM_CLOCK_SOURCE_ULP32K: + + if (calibration_value > 32) { + return STATUS_ERR_INVALID_ARG; + } + + SYSCTRL->OSCULP32K.bit.CALIB = calibration_value; + break; + + default: + Assert(false); + return STATUS_ERR_INVALID_ARG; + break; + } + + return STATUS_OK; +} + +/** + * \brief Enables a clock source + * + * Enables a clock source which has been previously configured. + * + * \param[in] clock_source Clock source to enable + * + * \retval STATUS_OK Clock source was enabled successfully and + * is ready + * \retval STATUS_ERR_INVALID_ARG The clock source is not available on this + * device + */ +enum status_code system_clock_source_enable( + const enum system_clock_source clock_source) +{ + switch (clock_source) { + case SYSTEM_CLOCK_SOURCE_OSC8M: + SYSCTRL->OSC8M.reg |= SYSCTRL_OSC8M_ENABLE; + return STATUS_OK; + + case SYSTEM_CLOCK_SOURCE_OSC32K: + SYSCTRL->OSC32K.reg |= SYSCTRL_OSC32K_ENABLE; + break; + + case SYSTEM_CLOCK_SOURCE_XOSC: + SYSCTRL->XOSC.reg |= SYSCTRL_XOSC_ENABLE; + break; + + case SYSTEM_CLOCK_SOURCE_XOSC32K: + SYSCTRL->XOSC32K.reg |= SYSCTRL_XOSC32K_ENABLE; + break; + + case SYSTEM_CLOCK_SOURCE_DFLL: + _system_clock_inst.dfll.control |= SYSCTRL_DFLLCTRL_ENABLE; + _system_clock_source_dfll_set_config_errata_9905(); + break; + +#ifdef FEATURE_SYSTEM_CLOCK_DPLL + case SYSTEM_CLOCK_SOURCE_DPLL: + SYSCTRL->DPLLCTRLA.reg |= SYSCTRL_DPLLCTRLA_ENABLE; + break; +#endif + + case SYSTEM_CLOCK_SOURCE_ULP32K: + /* Always enabled */ + return STATUS_OK; + + default: + Assert(false); + return STATUS_ERR_INVALID_ARG; + } + + return STATUS_OK; +} + +/** + * \brief Disables a clock source + * + * Disables a clock source that was previously enabled. + * + * \param[in] clock_source Clock source to disable + * + * \retval STATUS_OK Clock source was disabled successfully + * \retval STATUS_ERR_INVALID_ARG An invalid or unavailable clock source was + * given + */ +enum status_code system_clock_source_disable( + const enum system_clock_source clock_source) +{ + switch (clock_source) { + case SYSTEM_CLOCK_SOURCE_OSC8M: + SYSCTRL->OSC8M.reg &= ~SYSCTRL_OSC8M_ENABLE; + break; + + case SYSTEM_CLOCK_SOURCE_OSC32K: + SYSCTRL->OSC32K.reg &= ~SYSCTRL_OSC32K_ENABLE; + break; + + case SYSTEM_CLOCK_SOURCE_XOSC: + SYSCTRL->XOSC.reg &= ~SYSCTRL_XOSC_ENABLE; + break; + + case SYSTEM_CLOCK_SOURCE_XOSC32K: + SYSCTRL->XOSC32K.reg &= ~SYSCTRL_XOSC32K_ENABLE; + break; + + case SYSTEM_CLOCK_SOURCE_DFLL: + _system_clock_inst.dfll.control &= ~SYSCTRL_DFLLCTRL_ENABLE; + SYSCTRL->DFLLCTRL.reg = _system_clock_inst.dfll.control; + break; + +#ifdef FEATURE_SYSTEM_CLOCK_DPLL + case SYSTEM_CLOCK_SOURCE_DPLL: + SYSCTRL->DPLLCTRLA.reg &= ~SYSCTRL_DPLLCTRLA_ENABLE; + break; +#endif + + case SYSTEM_CLOCK_SOURCE_ULP32K: + /* Not possible to disable */ + + default: + Assert(false); + return STATUS_ERR_INVALID_ARG; + + } + + return STATUS_OK; +} + +/** + * \brief Checks if a clock source is ready + * + * Checks if a given clock source is ready to be used. + * + * \param[in] clock_source Clock source to check if ready + * + * \returns Ready state of the given clock source. + * + * \retval true Clock source is enabled and ready + * \retval false Clock source is disabled or not yet ready + */ +bool system_clock_source_is_ready( + const enum system_clock_source clock_source) +{ + uint32_t mask = 0; + + switch (clock_source) { + case SYSTEM_CLOCK_SOURCE_OSC8M: + mask = SYSCTRL_PCLKSR_OSC8MRDY; + break; + + case SYSTEM_CLOCK_SOURCE_OSC32K: + mask = SYSCTRL_PCLKSR_OSC32KRDY; + break; + + case SYSTEM_CLOCK_SOURCE_XOSC: + mask = SYSCTRL_PCLKSR_XOSCRDY; + break; + + case SYSTEM_CLOCK_SOURCE_XOSC32K: + mask = SYSCTRL_PCLKSR_XOSC32KRDY; + break; + + case SYSTEM_CLOCK_SOURCE_DFLL: + if (CONF_CLOCK_DFLL_LOOP_MODE == SYSTEM_CLOCK_DFLL_LOOP_MODE_CLOSED) { + mask = (SYSCTRL_PCLKSR_DFLLRDY | + SYSCTRL_PCLKSR_DFLLLCKF | SYSCTRL_PCLKSR_DFLLLCKC); + } else { + mask = SYSCTRL_PCLKSR_DFLLRDY; + } + break; + +#ifdef FEATURE_SYSTEM_CLOCK_DPLL + case SYSTEM_CLOCK_SOURCE_DPLL: + return ((SYSCTRL->DPLLSTATUS.reg & + (SYSCTRL_DPLLSTATUS_CLKRDY | SYSCTRL_DPLLSTATUS_LOCK)) == + (SYSCTRL_DPLLSTATUS_CLKRDY | SYSCTRL_DPLLSTATUS_LOCK)); +#endif + + case SYSTEM_CLOCK_SOURCE_ULP32K: + /* Not possible to disable */ + return true; + + default: + return false; + } + + return ((SYSCTRL->PCLKSR.reg & mask) == mask); +} + +/* Include some checks for conf_clocks.h validation */ +#include "clock_config_check.h" + +#if !defined(__DOXYGEN__) +/** \internal + * + * Configures a Generic Clock Generator with the configuration from \c conf_clocks.h. + */ +# define _CONF_CLOCK_GCLK_CONFIG(n, unused) \ + if (CONF_CLOCK_GCLK_##n##_ENABLE == true) { \ + struct system_gclk_gen_config gclk_conf; \ + system_gclk_gen_get_config_defaults(&gclk_conf); \ + gclk_conf.source_clock = CONF_CLOCK_GCLK_##n##_CLOCK_SOURCE; \ + gclk_conf.division_factor = CONF_CLOCK_GCLK_##n##_PRESCALER; \ + gclk_conf.run_in_standby = CONF_CLOCK_GCLK_##n##_RUN_IN_STANDBY; \ + gclk_conf.output_enable = CONF_CLOCK_GCLK_##n##_OUTPUT_ENABLE; \ + system_gclk_gen_set_config(GCLK_GENERATOR_##n, &gclk_conf); \ + system_gclk_gen_enable(GCLK_GENERATOR_##n); \ + } + +/** \internal + * + * Configures a Generic Clock Generator with the configuration from \c conf_clocks.h, + * provided that it is not the main Generic Clock Generator channel. + */ +# define _CONF_CLOCK_GCLK_CONFIG_NONMAIN(n, unused) \ + if (n > 0) { _CONF_CLOCK_GCLK_CONFIG(n, unused); } +#endif + +/** + * \brief Initialize clock system based on the configuration in conf_clocks.h + * + * This function will apply the settings in conf_clocks.h when run from the user + * application. All clock sources and GCLK generators are running when this function + * returns. + */ +void system_clock_init(void) +{ + /* Various bits in the INTFLAG register can be set to one at startup. + This will ensure that these bits are cleared */ + SYSCTRL->INTFLAG.reg = SYSCTRL_INTFLAG_BOD33RDY | SYSCTRL_INTFLAG_BOD33DET | + SYSCTRL_INTFLAG_DFLLRDY; + + system_flash_set_waitstates(CONF_CLOCK_FLASH_WAIT_STATES); + + /* XOSC */ +#if CONF_CLOCK_XOSC_ENABLE == true + struct system_clock_source_xosc_config xosc_conf; + system_clock_source_xosc_get_config_defaults(&xosc_conf); + + xosc_conf.external_clock = CONF_CLOCK_XOSC_EXTERNAL_CRYSTAL; + xosc_conf.startup_time = CONF_CLOCK_XOSC_STARTUP_TIME; + xosc_conf.auto_gain_control = CONF_CLOCK_XOSC_AUTO_GAIN_CONTROL; + xosc_conf.frequency = CONF_CLOCK_XOSC_EXTERNAL_FREQUENCY; + xosc_conf.on_demand = CONF_CLOCK_XOSC_ON_DEMAND; + xosc_conf.run_in_standby = CONF_CLOCK_XOSC_RUN_IN_STANDBY; + + system_clock_source_xosc_set_config(&xosc_conf); + system_clock_source_enable(SYSTEM_CLOCK_SOURCE_XOSC); +#endif + + + /* XOSC32K */ +#if CONF_CLOCK_XOSC32K_ENABLE == true + struct system_clock_source_xosc32k_config xosc32k_conf; + system_clock_source_xosc32k_get_config_defaults(&xosc32k_conf); + + xosc32k_conf.frequency = 32768UL; + xosc32k_conf.external_clock = CONF_CLOCK_XOSC32K_EXTERNAL_CRYSTAL; + xosc32k_conf.startup_time = CONF_CLOCK_XOSC32K_STARTUP_TIME; + xosc32k_conf.auto_gain_control = CONF_CLOCK_XOSC32K_AUTO_AMPLITUDE_CONTROL; + xosc32k_conf.enable_1khz_output = CONF_CLOCK_XOSC32K_ENABLE_1KHZ_OUPUT; + xosc32k_conf.enable_32khz_output = CONF_CLOCK_XOSC32K_ENABLE_32KHZ_OUTPUT; + xosc32k_conf.on_demand = false; + xosc32k_conf.run_in_standby = CONF_CLOCK_XOSC32K_RUN_IN_STANDBY; + + system_clock_source_xosc32k_set_config(&xosc32k_conf); + system_clock_source_enable(SYSTEM_CLOCK_SOURCE_XOSC32K); + while(!system_clock_source_is_ready(SYSTEM_CLOCK_SOURCE_XOSC32K)); + if (CONF_CLOCK_XOSC32K_ON_DEMAND) { + SYSCTRL->XOSC32K.bit.ONDEMAND = 1; + } +#endif + + + /* OSCK32K */ +#if CONF_CLOCK_OSC32K_ENABLE == true + SYSCTRL->OSC32K.bit.CALIB = + (*(uint32_t *)SYSCTRL_FUSES_OSC32K_ADDR >> SYSCTRL_FUSES_OSC32K_Pos); + + struct system_clock_source_osc32k_config osc32k_conf; + system_clock_source_osc32k_get_config_defaults(&osc32k_conf); + + osc32k_conf.startup_time = CONF_CLOCK_OSC32K_STARTUP_TIME; + osc32k_conf.enable_1khz_output = CONF_CLOCK_OSC32K_ENABLE_1KHZ_OUTPUT; + osc32k_conf.enable_32khz_output = CONF_CLOCK_OSC32K_ENABLE_32KHZ_OUTPUT; + osc32k_conf.on_demand = CONF_CLOCK_OSC32K_ON_DEMAND; + osc32k_conf.run_in_standby = CONF_CLOCK_OSC32K_RUN_IN_STANDBY; + + system_clock_source_osc32k_set_config(&osc32k_conf); + system_clock_source_enable(SYSTEM_CLOCK_SOURCE_OSC32K); +#endif + + + /* DFLL Config (Open and Closed Loop) */ +#if CONF_CLOCK_DFLL_ENABLE == true + struct system_clock_source_dfll_config dfll_conf; + system_clock_source_dfll_get_config_defaults(&dfll_conf); + + dfll_conf.loop_mode = CONF_CLOCK_DFLL_LOOP_MODE; + dfll_conf.on_demand = false; + + if (CONF_CLOCK_DFLL_LOOP_MODE == SYSTEM_CLOCK_DFLL_LOOP_MODE_OPEN) { + dfll_conf.coarse_value = CONF_CLOCK_DFLL_COARSE_VALUE; + dfll_conf.fine_value = CONF_CLOCK_DFLL_FINE_VALUE; + } + +# if CONF_CLOCK_DFLL_QUICK_LOCK == true + dfll_conf.quick_lock = SYSTEM_CLOCK_DFLL_QUICK_LOCK_ENABLE; +# else + dfll_conf.quick_lock = SYSTEM_CLOCK_DFLL_QUICK_LOCK_DISABLE; +# endif + +# if CONF_CLOCK_DFLL_TRACK_AFTER_FINE_LOCK == true + dfll_conf.stable_tracking = SYSTEM_CLOCK_DFLL_STABLE_TRACKING_TRACK_AFTER_LOCK; +# else + dfll_conf.stable_tracking = SYSTEM_CLOCK_DFLL_STABLE_TRACKING_FIX_AFTER_LOCK; +# endif + +# if CONF_CLOCK_DFLL_KEEP_LOCK_ON_WAKEUP == true + dfll_conf.wakeup_lock = SYSTEM_CLOCK_DFLL_WAKEUP_LOCK_KEEP; +# else + dfll_conf.wakeup_lock = SYSTEM_CLOCK_DFLL_WAKEUP_LOCK_LOSE; +# endif + +# if CONF_CLOCK_DFLL_ENABLE_CHILL_CYCLE == true + dfll_conf.chill_cycle = SYSTEM_CLOCK_DFLL_CHILL_CYCLE_ENABLE; +# else + dfll_conf.chill_cycle = SYSTEM_CLOCK_DFLL_CHILL_CYCLE_DISABLE; +# endif + + if (CONF_CLOCK_DFLL_LOOP_MODE == SYSTEM_CLOCK_DFLL_LOOP_MODE_CLOSED) { + dfll_conf.multiply_factor = CONF_CLOCK_DFLL_MULTIPLY_FACTOR; + } + + dfll_conf.coarse_max_step = CONF_CLOCK_DFLL_MAX_COARSE_STEP_SIZE; + dfll_conf.fine_max_step = CONF_CLOCK_DFLL_MAX_FINE_STEP_SIZE; + + if (CONF_CLOCK_DFLL_LOOP_MODE == SYSTEM_CLOCK_DFLL_LOOP_MODE_USB_RECOVERY) { +#define NVM_DFLL_COARSE_POS 58 +#define NVM_DFLL_COARSE_SIZE 6 +#define NVM_DFLL_FINE_POS 64 +#define NVM_DFLL_FINE_SIZE 10 + uint32_t coarse =( *((uint32_t *)(NVMCTRL_OTP4) + + (NVM_DFLL_COARSE_POS / 32)) + >> (NVM_DFLL_COARSE_POS % 32)) + & ((1 << NVM_DFLL_COARSE_SIZE) - 1); + if (coarse == 0x3f) { + coarse = 0x1f; + } + uint32_t fine =( *((uint32_t *)(NVMCTRL_OTP4) + + (NVM_DFLL_FINE_POS / 32)) + >> (NVM_DFLL_FINE_POS % 32)) + & ((1 << NVM_DFLL_FINE_SIZE) - 1); + if (fine == 0x3ff) { + fine = 0x1ff; + } + dfll_conf.coarse_value = coarse; + dfll_conf.fine_value = fine; + + dfll_conf.quick_lock = SYSTEM_CLOCK_DFLL_QUICK_LOCK_ENABLE; + dfll_conf.stable_tracking = SYSTEM_CLOCK_DFLL_STABLE_TRACKING_FIX_AFTER_LOCK; + dfll_conf.wakeup_lock = SYSTEM_CLOCK_DFLL_WAKEUP_LOCK_KEEP; + dfll_conf.chill_cycle = SYSTEM_CLOCK_DFLL_CHILL_CYCLE_DISABLE; + + dfll_conf.multiply_factor = 48000; + } + + system_clock_source_dfll_set_config(&dfll_conf); +#endif + + + /* OSC8M */ + struct system_clock_source_osc8m_config osc8m_conf; + system_clock_source_osc8m_get_config_defaults(&osc8m_conf); + + osc8m_conf.prescaler = CONF_CLOCK_OSC8M_PRESCALER; + osc8m_conf.on_demand = CONF_CLOCK_OSC8M_ON_DEMAND; + osc8m_conf.run_in_standby = CONF_CLOCK_OSC8M_RUN_IN_STANDBY; + + system_clock_source_osc8m_set_config(&osc8m_conf); + system_clock_source_enable(SYSTEM_CLOCK_SOURCE_OSC8M); + + + /* GCLK */ +#if CONF_CLOCK_CONFIGURE_GCLK == true + system_gclk_init(); + + /* Configure all GCLK generators except for the main generator, which + * is configured later after all other clock systems are set up */ + MREPEAT(8, _CONF_CLOCK_GCLK_CONFIG_NONMAIN, ~); + +# if CONF_CLOCK_DFLL_ENABLE == true + /* Enable DFLL reference clock if in closed loop mode */ + if (CONF_CLOCK_DFLL_LOOP_MODE == SYSTEM_CLOCK_DFLL_LOOP_MODE_CLOSED) { + struct system_gclk_chan_config dfll_gclk_chan_conf; + + system_gclk_chan_get_config_defaults(&dfll_gclk_chan_conf); + dfll_gclk_chan_conf.source_generator = CONF_CLOCK_DFLL_SOURCE_GCLK_GENERATOR; + system_gclk_chan_set_config(SYSCTRL_GCLK_ID_DFLL48, &dfll_gclk_chan_conf); + system_gclk_chan_enable(SYSCTRL_GCLK_ID_DFLL48); + } +# endif +#endif + + + /* DFLL Enable (Open and Closed Loop) */ +#if CONF_CLOCK_DFLL_ENABLE == true + system_clock_source_enable(SYSTEM_CLOCK_SOURCE_DFLL); + while(!system_clock_source_is_ready(SYSTEM_CLOCK_SOURCE_DFLL)); + if (CONF_CLOCK_DFLL_ON_DEMAND) { + SYSCTRL->DFLLCTRL.bit.ONDEMAND = 1; + } +#endif + + /* DPLL */ +#ifdef FEATURE_SYSTEM_CLOCK_DPLL +# if (CONF_CLOCK_DPLL_ENABLE == true) + + /* Enable DPLL reference clock */ + if (CONF_CLOCK_DPLL_REFERENCE_CLOCK == SYSTEM_CLOCK_SOURCE_DPLL_REFERENCE_CLOCK_REF0) { + /* XOSC32K should have been enabled for DPLL_REF0 */ + Assert(CONF_CLOCK_XOSC32K_ENABLE); + } + + struct system_clock_source_dpll_config dpll_config; + system_clock_source_dpll_get_config_defaults(&dpll_config); + + dpll_config.on_demand = false; + dpll_config.run_in_standby = CONF_CLOCK_DPLL_RUN_IN_STANDBY; + dpll_config.lock_bypass = CONF_CLOCK_DPLL_LOCK_BYPASS; + dpll_config.wake_up_fast = CONF_CLOCK_DPLL_WAKE_UP_FAST; + dpll_config.low_power_enable = CONF_CLOCK_DPLL_LOW_POWER_ENABLE; + + dpll_config.filter = CONF_CLOCK_DPLL_FILTER; + + dpll_config.reference_clock = CONF_CLOCK_DPLL_REFERENCE_CLOCK; + dpll_config.reference_frequency = CONF_CLOCK_DPLL_REFERENCE_FREQUENCY; + dpll_config.reference_divider = CONF_CLOCK_DPLL_REFEREMCE_DIVIDER; + dpll_config.output_frequency = CONF_CLOCK_DPLL_OUTPUT_FREQUENCY; + + system_clock_source_dpll_set_config(&dpll_config); + system_clock_source_enable(SYSTEM_CLOCK_SOURCE_DPLL); + while(!system_clock_source_is_ready(SYSTEM_CLOCK_SOURCE_DPLL)); + if (CONF_CLOCK_DPLL_ON_DEMAND) { + SYSCTRL->DPLLCTRLA.bit.ONDEMAND = 1; + } + +# endif +#endif + + /* CPU and BUS clocks */ + system_cpu_clock_set_divider(CONF_CLOCK_CPU_DIVIDER); + +#ifdef FEATURE_SYSTEM_CLOCK_FAILURE_DETECT + system_main_clock_set_failure_detect(CONF_CLOCK_CPU_CLOCK_FAILURE_DETECT); +#endif + + system_apb_clock_set_divider(SYSTEM_CLOCK_APB_APBA, CONF_CLOCK_APBA_DIVIDER); + system_apb_clock_set_divider(SYSTEM_CLOCK_APB_APBB, CONF_CLOCK_APBB_DIVIDER); + + /* GCLK 0 */ +#if CONF_CLOCK_CONFIGURE_GCLK == true + /* Configure the main GCLK last as it might depend on other generators */ + _CONF_CLOCK_GCLK_CONFIG(0, ~); +#endif +} diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/clock_samd21_r21/clock_config_check.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/clock_samd21_r21/clock_config_check.h new file mode 100644 index 0000000..7f80f91 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/clock_samd21_r21/clock_config_check.h @@ -0,0 +1,423 @@ +/** + * \file + * + * \brief SAM D21/R21 Clock Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef CLOCK_CONFIG_CHECK_H +# define CLOCK_CONFIG_CHECK_H + +#if !defined(CONF_CLOCK_FLASH_WAIT_STATES) +# error CONF_CLOCK_FLASH_WAIT_STATES not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_CPU_DIVIDER) +# error CONF_CLOCK_CPU_DIVIDER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_APBA_DIVIDER) +# error CONF_CLOCK_APBA_DIVIDER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_APBB_DIVIDER) +# error CONF_CLOCK_APBB_DIVIDER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_OSC8M_PRESCALER) +# error CONF_CLOCK_OSC8M_PRESCALER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_OSC8M_ON_DEMAND) +# error CONF_CLOCK_OSC8M_ON_DEMAND not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_OSC8M_RUN_IN_STANDBY) +# error CONF_CLOCK_OSC8M_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC_ENABLE) +# error CONF_CLOCK_XOSC_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC_EXTERNAL_CRYSTAL) +# error CONF_CLOCK_XOSC_EXTERNAL_CRYSTAL not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC_EXTERNAL_FREQUENCY) +# error CONF_CLOCK_XOSC_EXTERNAL_FREQUENCY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC_STARTUP_TIME) +# error CONF_CLOCK_XOSC_STARTUP_TIME not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC_AUTO_GAIN_CONTROL) +# error CONF_CLOCK_XOSC_AUTO_GAIN_CONTROL not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC_ON_DEMAND) +# error CONF_CLOCK_XOSC_ON_DEMAND not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC_RUN_IN_STANDBY) +# error CONF_CLOCK_XOSC_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC32K_ENABLE) +# error CONF_CLOCK_XOSC32K_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC32K_EXTERNAL_CRYSTAL) +# error CONF_CLOCK_XOSC32K_EXTERNAL_CRYSTAL not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC32K_STARTUP_TIME) +# error CONF_CLOCK_XOSC32K_STARTUP_TIME not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC32K_AUTO_AMPLITUDE_CONTROL) +# error CONF_CLOCK_XOSC32K_AUTO_AMPLITUDE_CONTROL not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC32K_ENABLE_1KHZ_OUPUT) +# error CONF_CLOCK_XOSC32K_ENABLE_1KHZ_OUPUT not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC32K_ENABLE_32KHZ_OUTPUT) +# error CONF_CLOCK_XOSC32K_ENABLE_32KHZ_OUTPUT not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC32K_ON_DEMAND) +# error CONF_CLOCK_XOSC32K_ON_DEMAND not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC32K_RUN_IN_STANDBY) +# error CONF_CLOCK_XOSC32K_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_OSC32K_ENABLE) +# error CONF_CLOCK_OSC32K_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_OSC32K_STARTUP_TIME) +# error CONF_CLOCK_OSC32K_STARTUP_TIME not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_OSC32K_ENABLE_1KHZ_OUTPUT) +# error CONF_CLOCK_OSC32K_ENABLE_1KHZ_OUTPUT not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_OSC32K_ENABLE_32KHZ_OUTPUT) +# error CONF_CLOCK_OSC32K_ENABLE_32KHZ_OUTPUT not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_OSC32K_ON_DEMAND) +# error CONF_CLOCK_OSC32K_ON_DEMAND not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_OSC32K_RUN_IN_STANDBY) +# error CONF_CLOCK_OSC32K_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_ENABLE) +# error CONF_CLOCK_DFLL_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_LOOP_MODE) +# error CONF_CLOCK_DFLL_LOOP_MODE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_ON_DEMAND) +# error CONF_CLOCK_DFLL_ON_DEMAND not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_COARSE_VALUE) +# error CONF_CLOCK_DFLL_COARSE_VALUE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_FINE_VALUE) +# error CONF_CLOCK_DFLL_FINE_VALUE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_SOURCE_GCLK_GENERATOR) +# error CONF_CLOCK_DFLL_SOURCE_GCLK_GENERATOR not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_MULTIPLY_FACTOR) +# error CONF_CLOCK_DFLL_MULTIPLY_FACTOR not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_QUICK_LOCK) +# error CONF_CLOCK_DFLL_QUICK_LOCK not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_TRACK_AFTER_FINE_LOCK) +# error CONF_CLOCK_DFLL_TRACK_AFTER_FINE_LOCK not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_KEEP_LOCK_ON_WAKEUP) +# error CONF_CLOCK_DFLL_KEEP_LOCK_ON_WAKEUP not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_ENABLE_CHILL_CYCLE) +# error CONF_CLOCK_DFLL_ENABLE_CHILL_CYCLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_MAX_COARSE_STEP_SIZE) +# error CONF_CLOCK_DFLL_MAX_COARSE_STEP_SIZE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_MAX_FINE_STEP_SIZE) +# error CONF_CLOCK_DFLL_MAX_FINE_STEP_SIZE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_ENABLE) +# error CONF_CLOCK_DPLL_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_ON_DEMAND) +# error CONF_CLOCK_DPLL_ON_DEMAND not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_RUN_IN_STANDBY) +# error CONF_CLOCK_DPLL_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_LOCK_BYPASS) +# error CONF_CLOCK_DPLL_LOCK_BYPASS not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_WAKE_UP_FAST) +# error CONF_CLOCK_DPLL_WAKE_UP_FAST not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_LOW_POWER_ENABLE) +# error CONF_CLOCK_DPLL_LOW_POWER_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_LOCK_TIME) +# error CONF_CLOCK_DPLL_LOCK_TIME not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_REFERENCE_CLOCK) +# error CONF_CLOCK_DPLL_REFERENCE_CLOCK not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_FILTER) +# error CONF_CLOCK_DPLL_FILTER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_REFERENCE_FREQUENCY) +# error CONF_CLOCK_DPLL_REFERENCE_FREQUENCY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_REFEREMCE_DIVIDER) +# error CONF_CLOCK_DPLL_REFEREMCE_DIVIDER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_OUTPUT_FREQUENCY) +# error CONF_CLOCK_DPLL_OUTPUT_FREQUENCY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_CONFIGURE_GCLK) +# error CONF_CLOCK_CONFIGURE_GCLK not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_0_ENABLE) +# error CONF_CLOCK_GCLK_0_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_0_RUN_IN_STANDBY) +# error CONF_CLOCK_GCLK_0_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_0_CLOCK_SOURCE) +# error CONF_CLOCK_GCLK_0_CLOCK_SOURCE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_0_PRESCALER) +# error CONF_CLOCK_GCLK_0_PRESCALER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_0_OUTPUT_ENABLE) +# error CONF_CLOCK_GCLK_0_OUTPUT_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_1_ENABLE) +# error CONF_CLOCK_GCLK_1_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_1_RUN_IN_STANDBY) +# error CONF_CLOCK_GCLK_1_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_1_CLOCK_SOURCE) +# error CONF_CLOCK_GCLK_1_CLOCK_SOURCE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_1_PRESCALER) +# error CONF_CLOCK_GCLK_1_PRESCALER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_1_OUTPUT_ENABLE) +# error CONF_CLOCK_GCLK_1_OUTPUT_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_2_ENABLE) +# error CONF_CLOCK_GCLK_2_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_2_RUN_IN_STANDBY) +# error CONF_CLOCK_GCLK_2_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_2_CLOCK_SOURCE) +# error CONF_CLOCK_GCLK_2_CLOCK_SOURCE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_2_PRESCALER) +# error CONF_CLOCK_GCLK_2_PRESCALER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_2_OUTPUT_ENABLE) +# error CONF_CLOCK_GCLK_2_OUTPUT_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_3_ENABLE) +# error CONF_CLOCK_GCLK_3_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_3_RUN_IN_STANDBY) +# error CONF_CLOCK_GCLK_3_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_3_CLOCK_SOURCE) +# error CONF_CLOCK_GCLK_3_CLOCK_SOURCE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_3_PRESCALER) +# error CONF_CLOCK_GCLK_3_PRESCALER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_3_OUTPUT_ENABLE) +# error CONF_CLOCK_GCLK_3_OUTPUT_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_4_ENABLE) +# error CONF_CLOCK_GCLK_4_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_4_RUN_IN_STANDBY) +# error CONF_CLOCK_GCLK_4_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_4_CLOCK_SOURCE) +# error CONF_CLOCK_GCLK_4_CLOCK_SOURCE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_4_PRESCALER) +# error CONF_CLOCK_GCLK_4_PRESCALER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_4_OUTPUT_ENABLE) +# error CONF_CLOCK_GCLK_4_OUTPUT_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_5_ENABLE) +# error CONF_CLOCK_GCLK_5_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_5_RUN_IN_STANDBY) +# error CONF_CLOCK_GCLK_5_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_5_CLOCK_SOURCE) +# error CONF_CLOCK_GCLK_5_CLOCK_SOURCE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_5_PRESCALER) +# error CONF_CLOCK_GCLK_5_PRESCALER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_5_OUTPUT_ENABLE) +# error CONF_CLOCK_GCLK_5_OUTPUT_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_6_ENABLE) +# error CONF_CLOCK_GCLK_6_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_6_RUN_IN_STANDBY) +# error CONF_CLOCK_GCLK_6_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_6_CLOCK_SOURCE) +# error CONF_CLOCK_GCLK_6_CLOCK_SOURCE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_6_PRESCALER) +# error CONF_CLOCK_GCLK_6_PRESCALER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_6_OUTPUT_ENABLE) +# error CONF_CLOCK_GCLK_6_OUTPUT_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_7_ENABLE) +# error CONF_CLOCK_GCLK_7_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_7_RUN_IN_STANDBY) +# error CONF_CLOCK_GCLK_7_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_7_CLOCK_SOURCE) +# error CONF_CLOCK_GCLK_7_CLOCK_SOURCE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_7_PRESCALER) +# error CONF_CLOCK_GCLK_7_PRESCALER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_7_OUTPUT_ENABLE) +# error CONF_CLOCK_GCLK_7_OUTPUT_ENABLE not defined in conf_clock.h +#endif + +#endif /* CLOCK_CONFIG_CHECK_H */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/clock_samd21_r21/gclk.c b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/clock_samd21_r21/gclk.c new file mode 100644 index 0000000..03bcd67 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/clock_samd21_r21/gclk.c @@ -0,0 +1,496 @@ +/** + * \file + * + * \brief SAM D21/R21 Generic Clock Driver + * + * Copyright (C) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include +#include +#include + +/** + * \brief Initializes the GCLK driver. + * + * Initializes the Generic Clock module, disabling and resetting all active + * Generic Clock Generators and Channels to their power-on default values. + */ +void system_gclk_init(void) +{ + /* Turn on the digital interface clock */ + system_apb_clock_set_mask(SYSTEM_CLOCK_APB_APBA, PM_APBAMASK_GCLK); + + /* Software reset the module to ensure it is re-initialized correctly */ + GCLK->CTRL.reg = GCLK_CTRL_SWRST; + while (GCLK->CTRL.reg & GCLK_CTRL_SWRST) { + /* Wait for reset to complete */ + } +} + +/** + * \brief Writes a Generic Clock Generator configuration to the hardware module. + * + * Writes out a given configuration of a Generic Clock Generator configuration + * to the hardware module. + * + * \note Changing the clock source on the fly (on a running + * generator) can take additional time if the clock source is configured + * to only run on-demand (ONDEMAND bit is set) and it is not currently + * running (no peripheral is requesting the clock source). In this case + * the GCLK will request the new clock while still keeping a request to + * the old clock source until the new clock source is ready. + * + * \note This function will not start a generator that is not already running; + * to start the generator, call \ref system_gclk_gen_enable() + * after configuring a generator. + * + * \param[in] generator Generic Clock Generator index to configure + * \param[in] config Configuration settings for the generator + */ +void system_gclk_gen_set_config( + const uint8_t generator, + struct system_gclk_gen_config *const config) +{ + /* Sanity check arguments */ + Assert(config); + + /* Cache new register configurations to minimize sync requirements. */ + uint32_t new_genctrl_config = (generator << GCLK_GENCTRL_ID_Pos); + uint32_t new_gendiv_config = (generator << GCLK_GENDIV_ID_Pos); + + /* Select the requested source clock for the generator */ + new_genctrl_config |= config->source_clock << GCLK_GENCTRL_SRC_Pos; + + /* Configure the clock to be either high or low when disabled */ + if (config->high_when_disabled) { + new_genctrl_config |= GCLK_GENCTRL_OOV; + } + + /* Configure if the clock output to I/O pin should be enabled. */ + if (config->output_enable) { + new_genctrl_config |= GCLK_GENCTRL_OE; + } + + /* Set division factor */ + if (config->division_factor > 1) { + /* Check if division is a power of two */ + if (((config->division_factor & (config->division_factor - 1)) == 0)) { + /* Determine the index of the highest bit set to get the + * division factor that must be loaded into the division + * register */ + + uint32_t div2_count = 0; + + uint32_t mask; + for (mask = (1UL << 1); mask < config->division_factor; + mask <<= 1) { + div2_count++; + } + + /* Set binary divider power of 2 division factor */ + new_gendiv_config |= div2_count << GCLK_GENDIV_DIV_Pos; + new_genctrl_config |= GCLK_GENCTRL_DIVSEL; + } else { + /* Set integer division factor */ + + new_gendiv_config |= + (config->division_factor) << GCLK_GENDIV_DIV_Pos; + + /* Enable non-binary division with increased duty cycle accuracy */ + new_genctrl_config |= GCLK_GENCTRL_IDC; + } + + } + + /* Enable or disable the clock in standby mode */ + if (config->run_in_standby) { + new_genctrl_config |= GCLK_GENCTRL_RUNSTDBY; + } + + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + + system_interrupt_enter_critical_section(); + + /* Select the correct generator */ + *((uint8_t*)&GCLK->GENDIV.reg) = generator; + + /* Write the new generator configuration */ + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + GCLK->GENDIV.reg = new_gendiv_config; + + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + GCLK->GENCTRL.reg = new_genctrl_config | (GCLK->GENCTRL.reg & GCLK_GENCTRL_GENEN); + + system_interrupt_leave_critical_section(); +} + +/** + * \brief Enables a Generic Clock Generator that was previously configured. + * + * Starts the clock generation of a Generic Clock Generator that was previously + * configured via a call to \ref system_gclk_gen_set_config(). + * + * \param[in] generator Generic Clock Generator index to enable + */ +void system_gclk_gen_enable( + const uint8_t generator) +{ + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + + system_interrupt_enter_critical_section(); + + /* Select the requested generator */ + *((uint8_t*)&GCLK->GENCTRL.reg) = generator; + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + + /* Enable generator */ + GCLK->GENCTRL.reg |= GCLK_GENCTRL_GENEN; + + system_interrupt_leave_critical_section(); +} + +/** + * \brief Disables a Generic Clock Generator that was previously enabled. + * + * Stops the clock generation of a Generic Clock Generator that was previously + * started via a call to \ref system_gclk_gen_enable(). + * + * \param[in] generator Generic Clock Generator index to disable + */ +void system_gclk_gen_disable( + const uint8_t generator) +{ + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + + system_interrupt_enter_critical_section(); + + /* Select the requested generator */ + *((uint8_t*)&GCLK->GENCTRL.reg) = generator; + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + + /* Disable generator */ + GCLK->GENCTRL.reg &= ~GCLK_GENCTRL_GENEN; + while (GCLK->GENCTRL.reg & GCLK_GENCTRL_GENEN) { + /* Wait for clock to become disabled */ + } + + system_interrupt_leave_critical_section(); +} + +/** + * \brief Determins if the specified Generic Clock Generator is enabled + * + * \param[in] generator Generic Clock Generator index to check + * + * \return The enabled status. + * \retval true The Generic Clock Generator is enabled; + * \retval false The Generic Clock Generator is disabled. + */ +bool system_gclk_gen_is_enabled( + const uint8_t generator) +{ + bool enabled; + + system_interrupt_enter_critical_section(); + + /* Select the requested generator */ + *((uint8_t*)&GCLK->GENCTRL.reg) = generator; + /* Obtain the enabled status */ + enabled = (GCLK->GENCTRL.reg & GCLK_GENCTRL_GENEN); + + system_interrupt_leave_critical_section(); + + return enabled; +} + +/** + * \brief Retrieves the clock frequency of a Generic Clock generator. + * + * Determines the clock frequency (in Hz) of a specified Generic Clock + * generator, used as a source to a Generic Clock Channel module. + * + * \param[in] generator Generic Clock Generator index + * + * \return The frequency of the generic clock generator, in Hz. + */ +uint32_t system_gclk_gen_get_hz( + const uint8_t generator) +{ + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + + system_interrupt_enter_critical_section(); + + /* Select the appropriate generator */ + *((uint8_t*)&GCLK->GENCTRL.reg) = generator; + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + + /* Get the frequency of the source connected to the GCLK generator */ + uint32_t gen_input_hz = system_clock_source_get_hz( + (enum system_clock_source)GCLK->GENCTRL.bit.SRC); + + *((uint8_t*)&GCLK->GENCTRL.reg) = generator; + + uint8_t divsel = GCLK->GENCTRL.bit.DIVSEL; + + /* Select the appropriate generator division register */ + *((uint8_t*)&GCLK->GENDIV.reg) = generator; + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + + uint32_t divider = GCLK->GENDIV.bit.DIV; + + system_interrupt_leave_critical_section(); + + /* Check if the generator is using fractional or binary division */ + if (!divsel && divider > 1) { + gen_input_hz /= divider; + } else if (divsel) { + gen_input_hz >>= (divider+1); + } + + return gen_input_hz; +} + +/** + * \brief Writes a Generic Clock configuration to the hardware module. + * + * Writes out a given configuration of a Generic Clock configuration to the + * hardware module. If the clock is currently running, it will be stopped. + * + * \note Once called the clock will not be running; to start the clock, + * call \ref system_gclk_chan_enable() after configuring a clock channel. + * + * \param[in] channel Generic Clock channel to configure + * \param[in] config Configuration settings for the clock + * + */ +void system_gclk_chan_set_config( + const uint8_t channel, + struct system_gclk_chan_config *const config) +{ + /* Sanity check arguments */ + Assert(config); + + /* Cache the new config to reduce sync requirements */ + uint32_t new_clkctrl_config = (channel << GCLK_CLKCTRL_ID_Pos); + + /* Select the desired generic clock generator */ + new_clkctrl_config |= config->source_generator << GCLK_CLKCTRL_GEN_Pos; + + /* Disable generic clock channel */ + system_gclk_chan_disable(channel); + + /* Write the new configuration */ + GCLK->CLKCTRL.reg = new_clkctrl_config; +} + +/** + * \brief Enables a Generic Clock that was previously configured. + * + * Starts the clock generation of a Generic Clock that was previously + * configured via a call to \ref system_gclk_chan_set_config(). + * + * \param[in] channel Generic Clock channel to enable + */ +void system_gclk_chan_enable( + const uint8_t channel) +{ + system_interrupt_enter_critical_section(); + + /* Select the requested generator channel */ + *((uint8_t*)&GCLK->CLKCTRL.reg) = channel; + + /* Enable the generic clock */ + GCLK->CLKCTRL.reg |= GCLK_CLKCTRL_CLKEN; + + system_interrupt_leave_critical_section(); +} + +/** + * \brief Disables a Generic Clock that was previously enabled. + * + * Stops the clock generation of a Generic Clock that was previously started + * via a call to \ref system_gclk_chan_enable(). + * + * \param[in] channel Generic Clock channel to disable + */ +void system_gclk_chan_disable( + const uint8_t channel) +{ + system_interrupt_enter_critical_section(); + + /* Select the requested generator channel */ + *((uint8_t*)&GCLK->CLKCTRL.reg) = channel; + + /* Sanity check WRTLOCK */ + Assert(!GCLK->CLKCTRL.bit.WRTLOCK); + + /* Switch to known-working source so that the channel can be disabled */ + uint32_t prev_gen_id = GCLK->CLKCTRL.bit.GEN; + GCLK->CLKCTRL.bit.GEN = 0; + + /* Disable the generic clock */ + GCLK->CLKCTRL.reg &= ~GCLK_CLKCTRL_CLKEN; + while (GCLK->CLKCTRL.reg & GCLK_CLKCTRL_CLKEN) { + /* Wait for clock to become disabled */ + } + + /* Restore previous configured clock generator */ + GCLK->CLKCTRL.bit.GEN = prev_gen_id; + + system_interrupt_leave_critical_section(); +} + +/** + * \brief Determins if the specified Generic Clock channel is enabled + * + * \param[in] channel Generic Clock Channel index + * + * \return The enabled status. + * \retval true The Generic Clock channel is enabled; + * \retval false The Generic Clock channel is disabled. + */ +bool system_gclk_chan_is_enabled( + const uint8_t channel) +{ + bool enabled; + + system_interrupt_enter_critical_section(); + + /* Select the requested generic clock channel */ + *((uint8_t*)&GCLK->CLKCTRL.reg) = channel; + enabled = GCLK->CLKCTRL.bit.CLKEN; + + system_interrupt_leave_critical_section(); + + return enabled; +} + +/** + * \brief Locks a Generic Clock channel from further configuration writes. + * + * Locks a generic clock channel from further configuration writes. It is only + * possible to unlock the channel configuration through a power on reset. + * + * \param[in] channel Generic Clock channel to enable + */ +void system_gclk_chan_lock( + const uint8_t channel) +{ + system_interrupt_enter_critical_section(); + + /* Select the requested generator channel */ + *((uint8_t*)&GCLK->CLKCTRL.reg) = channel; + + /* Enable the generic clock */ + GCLK->CLKCTRL.reg |= GCLK_CLKCTRL_CLKEN; + + system_interrupt_leave_critical_section(); +} + +/** + * \brief Determins if the specified Generic Clock channel is locked + * + * \param[in] channel Generic Clock Channel index + * + * \return The lock status. + * \retval true The Generic Clock channel is locked; + * \retval false The Generic Clock channel is not locked. + */ +bool system_gclk_chan_is_locked( + const uint8_t channel) +{ + bool locked; + + system_interrupt_enter_critical_section(); + + /* Select the requested generic clock channel */ + *((uint8_t*)&GCLK->CLKCTRL.reg) = channel; + locked = GCLK->CLKCTRL.bit.WRTLOCK; + + system_interrupt_leave_critical_section(); + + return locked; +} + +/** + * \brief Retrieves the clock frequency of a Generic Clock channel. + * + * Determines the clock frequency (in Hz) of a specified Generic Clock + * channel, used as a source to a device peripheral module. + * + * \param[in] channel Generic Clock Channel index + * + * \return The frequency of the generic clock channel, in Hz. + */ +uint32_t system_gclk_chan_get_hz( + const uint8_t channel) +{ + uint8_t gen_id; + + system_interrupt_enter_critical_section(); + + /* Select the requested generic clock channel */ + *((uint8_t*)&GCLK->CLKCTRL.reg) = channel; + gen_id = GCLK->CLKCTRL.bit.GEN; + + system_interrupt_leave_critical_section(); + + /* Return the clock speed of the associated GCLK generator */ + return system_gclk_gen_get_hz(gen_id); +} diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/gclk.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/gclk.h new file mode 100644 index 0000000..884a999 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/gclk.h @@ -0,0 +1,322 @@ +/** + * \file + * + * \brief SAM Generic Clock Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef SYSTEM_CLOCK_GCLK_H_INCLUDED +#define SYSTEM_CLOCK_GCLK_H_INCLUDED + +/** + * \addtogroup asfdoc_sam0_system_clock_group + * + * @{ + */ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \brief List of available GCLK generators. + * + * List of Available GCLK generators. This enum is used in the peripheral + * device drivers to select the GCLK generator to be used for its operation. + * + * The number of GCLK generators available is device dependent. + */ +enum gclk_generator { + /** GCLK generator channel 0. */ + GCLK_GENERATOR_0, +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 0) + /** GCLK generator channel 1. */ + GCLK_GENERATOR_1, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 1) + /** GCLK generator channel 2. */ + GCLK_GENERATOR_2, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 2) + /** GCLK generator channel 3. */ + GCLK_GENERATOR_3, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 3) + /** GCLK generator channel 4. */ + GCLK_GENERATOR_4, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 4) + /** GCLK generator channel 5. */ + GCLK_GENERATOR_5, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 5) + /** GCLK generator channel 6. */ + GCLK_GENERATOR_6, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 6) + /** GCLK generator channel 7. */ + GCLK_GENERATOR_7, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 7) + /** GCLK generator channel 8. */ + GCLK_GENERATOR_8, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 8) + /** GCLK generator channel 9. */ + GCLK_GENERATOR_9, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 9) + /** GCLK generator channel 10. */ + GCLK_GENERATOR_10, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 10) + /** GCLK generator channel 11. */ + GCLK_GENERATOR_11, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 11) + /** GCLK generator channel 12. */ + GCLK_GENERATOR_12, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 12) + /** GCLK generator channel 13. */ + GCLK_GENERATOR_13, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 13) + /** GCLK generator channel 14. */ + GCLK_GENERATOR_14, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 14) + /** GCLK generator channel 15. */ + GCLK_GENERATOR_15, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 15) + /** GCLK generator channel 16. */ + GCLK_GENERATOR_16, +#endif +}; + +/** + * \brief Generic Clock Generator configuration structure. + * + * Configuration structure for a Generic Clock Generator channel. This + * structure should be initialized by the + * \ref system_gclk_gen_get_config_defaults() function before being modified by + * the user application. + */ +struct system_gclk_gen_config { + /** Source clock input channel index, please see the \ref system_clock_source. */ + uint8_t source_clock; + /** If \c true, the generator output level is high when disabled. */ + bool high_when_disabled; + /** Integer division factor of the clock output compared to the input. */ + uint32_t division_factor; + /** If \c true, the clock is kept enabled during device standby mode. */ + bool run_in_standby; + /** If \c true, enables GCLK generator clock output to a GPIO pin. */ + bool output_enable; +}; + +/** + * \brief Generic Clock configuration structure. + * + * Configuration structure for a Generic Clock channel. This structure + * should be initialized by the \ref system_gclk_chan_get_config_defaults() + * function before being modified by the user application. + */ +struct system_gclk_chan_config { + /** Generic Clock Generator source channel. */ + enum gclk_generator source_generator; +}; + +/** \name Generic Clock management + * @{ + */ + +/** + * \brief Determines if the hardware module(s) are currently synchronizing to the bus. + * + * Checks to see if the underlying hardware peripheral module(s) are currently + * synchronizing across multiple clock domains to the hardware bus, This + * function can be used to delay further operations on a module until such time + * that it is ready, to prevent blocking delays for synchronization in the + * user application. + * + * \return Synchronization status of the underlying hardware module(s). + * + * \retval true if the module has completed synchronization + * \retval false if the module synchronization is ongoing + */ +static inline bool system_gclk_is_syncing(void) +{ + if (GCLK->STATUS.reg & GCLK_STATUS_SYNCBUSY) { + return true; + } + + return false; +} + +void system_gclk_init(void); + +/** @} */ + + +/** + * \name Generic Clock management (Generators) + * @{ + */ + +/** + * \brief Initializes a Generic Clock Generator configuration structure to defaults. + * + * Initializes a given Generic Clock Generator configuration structure to + * a set of known default values. This function should be called on all + * new instances of these configuration structures before being modified + * by the user application. + * + * The default configuration is as follows: + * \li Clock is generated undivided from the source frequency + * \li Clock generator output is low when the generator is disabled + * \li The input clock is sourced from input clock channel 0 + * \li Clock will be disabled during sleep + * \li The clock output will not be routed to a physical GPIO pin + * + * \param[out] config Configuration structure to initialize to default values + */ +static inline void system_gclk_gen_get_config_defaults( + struct system_gclk_gen_config *const config) +{ + /* Sanity check arguments */ + Assert(config); + + /* Default configuration values */ + config->division_factor = 1; + config->high_when_disabled = false; + config->source_clock = GCLK_SOURCE_OSC8M; + config->run_in_standby = false; + config->output_enable = false; +} + +void system_gclk_gen_set_config( + const uint8_t generator, + struct system_gclk_gen_config *const config); + +void system_gclk_gen_enable( + const uint8_t generator); + +void system_gclk_gen_disable( + const uint8_t generator); + +bool system_gclk_gen_is_enabled( + const uint8_t generator); + +/** @} */ + + +/** + * \name Generic Clock management (Channels) + * @{ + */ + +/** + * \brief Initializes a Generic Clock configuration structure to defaults. + * + * Initializes a given Generic Clock configuration structure to a set of + * known default values. This function should be called on all new + * instances of these configuration structures before being modified by the + * user application. + * + * The default configuration is as follows: + * \li Clock is sourced from the Generic Clock Generator channel 0 + * \li Clock configuration will not be write-locked when set + * + * \param[out] config Configuration structure to initialize to default values + */ +static inline void system_gclk_chan_get_config_defaults( + struct system_gclk_chan_config *const config) +{ + /* Sanity check arguments */ + Assert(config); + + /* Default configuration values */ + config->source_generator = GCLK_GENERATOR_0; +} + +void system_gclk_chan_set_config( + const uint8_t channel, + struct system_gclk_chan_config *const config); + +void system_gclk_chan_enable( + const uint8_t channel); + +void system_gclk_chan_disable( + const uint8_t channel); + +bool system_gclk_chan_is_enabled( + const uint8_t channel); + +void system_gclk_chan_lock( + const uint8_t channel); + +bool system_gclk_chan_is_locked( + const uint8_t channel); + +/** @} */ + + +/** + * \name Generic Clock frequency retrieval + * @{ + */ + +uint32_t system_gclk_gen_get_hz( + const uint8_t generator); + +uint32_t system_gclk_chan_get_hz( + const uint8_t channel); + +/** @} */ + +#ifdef __cplusplus +} +#endif + +/** @} */ + +#endif diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/quick_start_clock/qs_clock_source.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/quick_start_clock/qs_clock_source.h new file mode 100644 index 0000000..e5b6778 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/quick_start_clock/qs_clock_source.h @@ -0,0 +1,129 @@ +/** + * \file + * + * \brief SAM System Clock Driver Quick Start + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + */ + +/** + * \page asfdoc_sam0_system_clock_basic_use_case Quick Start Guide for SYSTEM CLOCK - Basic + * + * In this case we apply the following configuration: + * - RC8MHz (internal 8MHz RC oscillator) + * - Divide by 4, giving a frequency of 2MHz + * - DFLL (Digital frequency locked loop) + * - Open loop mode + * - 48MHz frequency + * - CPU clock + * - Use two wait states when reading from flash memory + * - Use the DFLL, configured to 48MHz + * + * \section asfdoc_sam0_system_clock_basic_use_case_setup Setup + * + * \subsection asfdoc_sam0_system_clock_basic_use_case_setup_prereq Prerequisites + * There are no special setup requirements for this use-case. + * + * \subsection asfdoc_sam0_system_clock_basic_use_case_setup_code Code + * Copy-paste the following setup code to your application: + * \snippet qs_clock_source.c setup + * + * \subsection asfdoc_sam0_system_clock_basic_use_case_setup_flow Workflow + * -# Create a EXTOSC32K module configuration struct, which can be filled + * out to adjust the configuration of the external 32KHz oscillator channel. + * \snippet qs_clock_source.c config_extosc32k_config + * + * -# Initialize the oscillator configuration struct with the module's default + * values. + * \snippet qs_clock_source.c config_extosc32k_get_defaults + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Alter the EXTOSC32K module configuration struct to require a start-up time + * of 4096 clock cycles. + * \snippet qs_clock_source.c config_extosc32k_change_defaults + * + * -# Write the new configuration to the EXTOSC32K module. + * \snippet qs_clock_source.c config_extosc32k_set_config + * + * -# Create a DFLL module configuration struct, which can be filled + * out to adjust the configuration of the external 32KHz oscillator channel. + * \snippet qs_clock_source.c config_dfll_config + * + * -# Initialize the DFLL oscillator configuration struct with the module's + * default values. + * \snippet qs_clock_source.c config_dfll_get_defaults + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Write the new configuration to the DFLL module. + * \snippet qs_clock_source.c config_dfll_set_config + * + * + * \section asfdoc_sam0_system_clock_basic_use_case_use_main Use Case + * + * \subsection asfdoc_sam0_system_clock_basic_use_case_code Code + * + * Copy-paste the following code to your user application: + * \snippet qs_clock_source.c main + * + * \subsection asfdoc_sam0_system_clock_basic_use_case_flow Workflow + * -# Configure the external 32KHz oscillator source using the previously + * defined setup function. + * \snippet qs_clock_source.c config_extosc32k_main + * + * -# Enable the configured external 32KHz oscillator source. + * \snippet qs_clock_source.c enable_extosc32k_main + * + * -# Configure the DFLL oscillator source using the previously defined setup + * function. + * \snippet qs_clock_source.c config_dfll_main + * + * -# Enable the configured DFLL oscillator source. + * \snippet qs_clock_source.c enable_dfll_main + * + * -# Configure the flash wait states to have two wait states per read, as the + * high speed DFLL will be used as the system clock. If insufficient wait + * states are used, the device may crash randomly due to misread instructions. + * \snippet qs_clock_source.c set_sys_wait_states + * + * -# Switch the system clock source to the DFLL, by reconfiguring the main + * clock generator. + * \snippet qs_clock_source.c set_sys_clk_src + */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/quick_start_gclk/qs_gclk_basic.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/quick_start_gclk/qs_gclk_basic.h new file mode 100644 index 0000000..8b36a98 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/clock/quick_start_gclk/qs_gclk_basic.h @@ -0,0 +1,126 @@ +/** + * \file + * + * \brief SAM Generic Clock Driver Quick Start + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +/** + * \page asfdoc_sam0_system_gclk_basic_use_case Quick Start Guide for SYSTEM CLOCK - GCLK Configuration + * + * In this use case, the GCLK module is configured for: + * \li One generator attached to the internal 8MHz RC oscillator clock source + * \li Generator output equal to input frequency divided by a factor of 128 + * \li One channel (connected to the TC0 module) enabled with the enabled generator selected + * + * This use case configures a clock channel to output a clock for a peripheral + * within the device, by first setting up a clock generator from a master clock + * source, and then linking the generator to the desired channel. This clock + * can then be used to clock a module within the device. + * + * \section asfdoc_sam0_system_gclk_basic_use_case_setup Setup + * + * \subsection asfdoc_sam0_system_gclk_basic_use_case_setup_prereq Prerequisites + * There are no special setup requirements for this use-case. + * + * \subsection asfdoc_sam0_system_gclk_basic_use_case_setup_code Code + * Copy-paste the following setup code to your user application: + * \snippet qs_gclk_basic.c setup + * + * Add to user application initialization (typically the start of \c main()): + * \snippet qs_gclk_basic.c setup_init + * + * \subsection asfdoc_sam0_system_gclk_basic_use_case_setup_flow Workflow + * -# Create a GCLK generator configuration struct, which can be filled out to + * adjust the configuration of a single clock generator. + * \snippet qs_gclk_basic.c setup_1 + * -# Initialize the generator configuration struct with the module's default + * values. + * \snippet qs_gclk_basic.c setup_2 + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Adjust the configuration struct to request that the master clock source + * channel 0 be used as the source of the generator, and set the generator + * output prescaler to divide the input clock by a factor of 128. + * \snippet qs_gclk_basic.c setup_3 + * -# Configure the generator using the configuration structure. + * \snippet qs_gclk_basic.c setup_4 + * \note The existing configuration struct may be re-used, as long as any + * values that have been altered from the default settings are taken + * into account by the user application. + * + * -# Enable the generator once it has been properly configured, to begin clock + * generation. + * \snippet qs_gclk_basic.c setup_5 + * + * -# Create a GCLK channel configuration struct, which can be filled out to + * adjust the configuration of a single generic clock channel. + * \snippet qs_gclk_basic.c setup_6 + * -# Initialize the channel configuration struct with the module's default + * values. + * \snippet qs_gclk_basic.c setup_7 + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Adjust the configuration struct to request that the previously configured + * and enabled clock generator be used as the clock source for the channel. + * \snippet qs_gclk_basic.c setup_8 + * -# Configure the channel using the configuration structure. + * \snippet qs_gclk_basic.c setup_9 + * \note The existing configuration struct may be re-used, as long as any + * values that have been altered from the default settings are taken + * into account by the user application. + * + * -# Enable the channel once it has been properly configured, to output the + * clock to the channel's peripheral module consumers. + * \snippet qs_gclk_basic.c setup_10 + * + * \section asfdoc_sam0_system_gclk_basic_use_case_main Use Case + * + * \subsection asfdoc_sam0_system_gclk_basic_use_case_code Code + * Copy-paste the following code to your user application: + * \snippet qs_gclk_basic.c main + * + * \subsection asfdoc_sam0_system_gclk_basic_use_case_flow Workflow + * -# As the clock is generated asynchronously to the system core, no special + * extra application code is required. + */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/interrupt/quick_start/qs_system_interrupt.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/interrupt/quick_start/qs_system_interrupt.h new file mode 100644 index 0000000..308b511 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/interrupt/quick_start/qs_system_interrupt.h @@ -0,0 +1,102 @@ +/** + * \file + * + * \brief SAM System Interrupt Driver Quick Start + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +/** + * \page asfdoc_sam0_system_interrupt_critsec_use_case Quick Start Guide for SYSTEM INTERRUPT - Critical Section Use Case + * + * In this case we perform a critical piece of code, disabling all interrupts + * while a global shared flag is read. During the critical section, no interrupts + * may occur. + * + * \section asfdoc_sam0_system_interrupt_critsec_use_case_setup Setup + * + * \subsection asfdoc_sam0_system_interrupt_critsec_use_case_setup_prereq Prerequisites + * There are no special setup requirements for this use-case. + * + * \section asfdoc_sam0_system_interrupt_critsec_use_case_use_main Use Case + * + * \subsection asfdoc_sam0_system_interrupt_critsec_use_case_code Code + * Copy-paste the following code to your user application: + * \snippet qs_system_interrupt.c main_1 + * + * \subsection asfdoc_sam0_system_interrupt_critsec_use_case_flow Workflow + * -# Enter a critical section to disable global interrupts. + * \snippet qs_system_interrupt.c critical_section_start + * \note Critical sections may be nested if desired; if nested, global + * interrupts will only be re-enabled once the outer-most critical + * section has completed. + * + * -# Check a global shared flag and perform a response. This code may be any + * critical code that requires exclusive access to all resources without the + * possibility of interruption. + * \snippet qs_system_interrupt.c do_critical_code + * + * -# Exit the critical section to re-enable global interrupts. + * \snippet qs_system_interrupt.c critical_section_end + */ + +/** + * \page asfdoc_sam0_system_interrupt_enablemodint_use_case Quick Start Guide for SYSTEM INTERRUPT - Enable Module Interrupt Use Case + * + * In this case we enable interrupt handling for a specific module, as well as + * enable interrupts globally for the device. + * + * \section asfdoc_sam0_system_interrupt_enablemodint_use_case_setup Setup + * + * \subsection asfdoc_sam0_system_interrupt_enablemodint_use_case_setup_prereq Prerequisites + * There are no special setup requirements for this use-case. + * + * \section asfdoc_sam0_system_interrupt_enablemodint_use_case_use_main Use Case + * + * \subsection asfdoc_sam0_system_interrupt_enablemodint_use_case_code Code + * Copy-paste the following code to your user application: + * \snippet qs_system_interrupt.c main_2 + * + * \subsection asfdoc_sam0_system_interrupt_enablemodint_use_case_flow Workflow + * -# Enable interrupt handling for the device's RTC peripheral. + * \snippet qs_system_interrupt.c module_int_enable + * + * -# Enable global interrupts, so that any enabled and active interrupt sources + * can trigger their respective handler functions. + * \snippet qs_system_interrupt.c global_int_enable + */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/interrupt/system_interrupt.c b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/interrupt/system_interrupt.c new file mode 100644 index 0000000..569ce64 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/interrupt/system_interrupt.c @@ -0,0 +1,214 @@ +/** + * \file + * + * \brief SAM System Interrupt Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include "system_interrupt.h" + +/** + * \brief Check if a interrupt line is pending + * + * Checks if the requested interrupt vector is pending. + * + * \param[in] vector Interrupt vector number to check + * + * \returns A boolean identifying if the requested interrupt vector is pending. + * + * \retval true Specified interrupt vector is pending + * \retval false Specified interrupt vector is not pending + * + */ +bool system_interrupt_is_pending( + const enum system_interrupt_vector vector) +{ + bool result; + + if (vector >= _SYSTEM_INTERRUPT_EXTERNAL_VECTOR_START) { + result = ((NVIC->ISPR[0] & (1 << vector)) != 0); + } else if (vector == SYSTEM_INTERRUPT_SYSTICK) { + result = ((SCB->ICSR & SCB_ICSR_PENDSTSET_Msk) != 0); + } else { + Assert(false); + result = false; + } + + return result; +} + +/** + * \brief Set a interrupt vector as pending + * + * Set the requested interrupt vector as pending (i.e issues a software + * interrupt request for the specified vector). The software handler will be + * handled (if enabled) in a priority order based on vector number and + * configured priority settings. + * + * \param[in] vector Interrupt vector number which is set as pending + * + * \returns Status code identifying if the vector was successfully set as + * pending. + * + * \retval STATUS_OK If no error was detected + * \retval STATUS_INVALID_ARG If an unsupported interrupt vector number was given + */ +enum status_code system_interrupt_set_pending( + const enum system_interrupt_vector vector) +{ + enum status_code status = STATUS_OK; + + if (vector >= _SYSTEM_INTERRUPT_EXTERNAL_VECTOR_START) { + NVIC->ISPR[0] = (1 << vector); + } else if (vector == SYSTEM_INTERRUPT_NON_MASKABLE) { + /* Note: Because NMI has highest priority it will be executed + * immediately after it has been set pending */ + SCB->ICSR = SCB_ICSR_NMIPENDSET_Msk; + } else if (vector == SYSTEM_INTERRUPT_SYSTICK) { + SCB->ICSR = SCB_ICSR_PENDSTSET_Msk; + } else { + /* The user want to set something unsupported as pending */ + Assert(false); + status = STATUS_ERR_INVALID_ARG; + } + + return status; +} + +/** + * \brief Clear pending interrupt vector + * + * Clear a pending interrupt vector, so the software handler is not executed. + * + * \param[in] vector Interrupt vector number to clear + * + * \returns A status code identifying if the interrupt pending state was + * successfully cleared. + * + * \retval STATUS_OK If no error was detected + * \retval STATUS_INVALID_ARG If an unsupported interrupt vector number was given + */ +enum status_code system_interrupt_clear_pending( + const enum system_interrupt_vector vector) +{ + enum status_code status = STATUS_OK; + + if (vector >= _SYSTEM_INTERRUPT_EXTERNAL_VECTOR_START) { + NVIC->ICPR[0] = (1 << vector); + } else if (vector == SYSTEM_INTERRUPT_NON_MASKABLE) { + /* Note: Clearing of NMI pending interrupts does not make sense and is + * not supported by the device, as it has the highest priority and will + * always be executed at the moment it is set */ + return STATUS_ERR_INVALID_ARG; + } else if (vector == SYSTEM_INTERRUPT_SYSTICK) { + SCB->ICSR = SCB_ICSR_PENDSTCLR_Msk; + } else { + Assert(false); + status = STATUS_ERR_INVALID_ARG; + } + + return status; +} + +/** + * \brief Set interrupt vector priority level + * + * Set the priority level of an external interrupt or exception. + * + * \param[in] vector Interrupt vector to change + * \param[in] priority_level New vector priority level to set + * + * \returns Status code indicating if the priority level of the interrupt was + * successfully set. + * + * \retval STATUS_OK If no error was detected + * \retval STATUS_INVALID_ARG If an unsupported interrupt vector number was given + */ +enum status_code system_interrupt_set_priority( + const enum system_interrupt_vector vector, + const enum system_interrupt_priority_level priority_level) +{ + enum status_code status = STATUS_OK; + + if (vector >= _SYSTEM_INTERRUPT_EXTERNAL_VECTOR_START) { + uint8_t register_num = vector / 4; + uint8_t priority_pos = ((vector % 4) * 8) + (8 - __NVIC_PRIO_BITS); + + NVIC->IP[register_num] = + (NVIC->IP[register_num] & ~(0x3 << priority_pos)) | + (priority_level << priority_pos); + + } else if (vector == SYSTEM_INTERRUPT_SYSTICK) { + SCB->SHP[1] = (priority_level << _SYSTEM_INTERRUPT_SYSTICK_PRI_POS); + } else { + Assert(false); + status = STATUS_ERR_INVALID_ARG; + } + + return status; +} + +/** + * \brief Get interrupt vector priority level + * + * Retrieves the priority level of the requested external interrupt or exception. + * + * \param[in] vector Interrupt vector of which the priority level will be read + * + * \return Currently configured interrupt priority level of the given interrupt + * vector. + */ +enum system_interrupt_priority_level system_interrupt_get_priority( + const enum system_interrupt_vector vector) +{ + uint8_t register_num = vector / 4; + uint8_t priority_pos = ((vector % 4) * 8) + (8 - __NVIC_PRIO_BITS); + + enum system_interrupt_priority_level priority = SYSTEM_INTERRUPT_PRIORITY_LEVEL_0; + + if (vector >= 0) { + priority = (enum system_interrupt_priority_level) + ((NVIC->IP[register_num] >> priority_pos) & _SYSTEM_INTERRUPT_PRIORITY_MASK); + } else if (vector == SYSTEM_INTERRUPT_SYSTICK) { + priority = (enum system_interrupt_priority_level) + ((SCB->SHP[1] >> _SYSTEM_INTERRUPT_SYSTICK_PRI_POS) & _SYSTEM_INTERRUPT_PRIORITY_MASK); + } + + return priority; +} + diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/interrupt/system_interrupt.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/interrupt/system_interrupt.h new file mode 100644 index 0000000..1298993 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/interrupt/system_interrupt.h @@ -0,0 +1,431 @@ +/** + * \file + * + * \brief SAM System Interrupt Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef SYSTEM_INTERRUPT_H_INCLUDED +#define SYSTEM_INTERRUPT_H_INCLUDED + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \defgroup asfdoc_sam0_system_interrupt_group SAM System Interrupt Driver (SYSTEM INTERRUPT) + * + * This driver for SAM devices provides an interface for the configuration + * and management of internal software and hardware interrupts/exceptions. + * + * The following peripherals are used by this module: + * - NVIC (Nested Vector Interrupt Controller) + * + * The following devices can use this module: + * - SAM D20/D21 + * - SAM R21 + * - SAM D10/D11 + * + * The outline of this documentation is as follows: + * - \ref asfdoc_sam0_system_interrupt_prerequisites + * - \ref asfdoc_sam0_system_interrupt_module_overview + * - \ref asfdoc_sam0_system_interrupt_special_considerations + * - \ref asfdoc_sam0_system_interrupt_extra_info + * - \ref asfdoc_sam0_system_interrupt_examples + * - \ref asfdoc_sam0_system_interrupt_api_overview + * + * + * \section asfdoc_sam0_system_interrupt_prerequisites Prerequisites + * + * There are no prerequisites for this module. + * + * + * \section asfdoc_sam0_system_interrupt_module_overview Module Overview + * + * The ARM® Cortex® M0+ core contains an interrupt an exception vector table, which + * can be used to configure the device's interrupt handlers; individual + * interrupts and exceptions can be enabled and disabled, as well as configured + * with a variable priority. + * + * This driver provides a set of wrappers around the core interrupt functions, + * to expose a simple API for the management of global and individual interrupts + * within the device. + * + * \subsection asfdoc_sam0_system_interrupt_module_overview_criticalsec Critical Sections + * In some applications it is important to ensure that no interrupts may be + * executed by the system whilst a critical portion of code is being run; for + * example, a buffer may be copied from one context to another - during which + * interrupts must be disabled to avoid corruption of the source buffer contents + * until the copy has completed. This driver provides a basic API to enter and + * exit nested critical sections, so that global interrupts can be kept disabled + * for as long as necessary to complete a critical application code section. + * + * \subsection asfdoc_sam0_system_interrupt_module_overview_softints Software Interrupts + * For some applications, it may be desirable to raise a module or core + * interrupt via software. For this reason, a set of APIs to set an interrupt or + * exception as pending are provided to the user application. + * + * \section asfdoc_sam0_system_interrupt_special_considerations Special Considerations + * + * Interrupts from peripherals in the SAM devices are on a per-module basis; + * an interrupt raised from any source within a module will cause a single, + * module-common handler to execute. It is the user application or driver's + * responsibility to de-multiplex the module-common interrupt to determine the + * exact interrupt cause. + * + * \section asfdoc_sam0_system_interrupt_extra_info Extra Information + * + * For extra information see \ref asfdoc_sam0_system_interrupt_extra. This includes: + * - \ref asfdoc_sam0_system_interrupt_extra_acronyms + * - \ref asfdoc_sam0_system_interrupt_extra_dependencies + * - \ref asfdoc_sam0_system_interrupt_extra_errata + * - \ref asfdoc_sam0_system_interrupt_extra_history + * + * + * \section asfdoc_sam0_system_interrupt_examples Examples + * + * For a list of examples related to this driver, see + * \ref asfdoc_sam0_system_interrupt_exqsg. + * + * \section asfdoc_sam0_system_interrupt_api_overview API Overview + * @{ + */ + +#include +#include +#include "system_interrupt_features.h" + +/** + * \brief Table of possible system interrupt/exception vector priorities. + * + * Table of all possible interrupt and exception vector priorities within the + * device. + */ +enum system_interrupt_priority_level { + /** Priority level 0, the highest possible interrupt priority. */ + SYSTEM_INTERRUPT_PRIORITY_LEVEL_0 = 0, + /** Priority level 1. */ + SYSTEM_INTERRUPT_PRIORITY_LEVEL_1 = 1, + /** Priority level 2. */ + SYSTEM_INTERRUPT_PRIORITY_LEVEL_2 = 2, + /** Priority level 3, the lowest possible interrupt priority. */ + SYSTEM_INTERRUPT_PRIORITY_LEVEL_3 = 3, +}; + +/** + * \name Critical Section Management + * @{ + */ + +/** + * \brief Enters a critical section + * + * Disables global interrupts. To support nested critical sections, an internal + * count of the critical section nesting will be kept, so that global interrupts + * are only re-enabled upon leaving the outermost nested critical section. + * + */ +static inline void system_interrupt_enter_critical_section(void) +{ + cpu_irq_enter_critical(); +} + +/** + * \brief Leaves a critical section + * + * Enables global interrupts. To support nested critical sections, an internal + * count of the critical section nesting will be kept, so that global interrupts + * are only re-enabled upon leaving the outermost nested critical section. + * + */ +static inline void system_interrupt_leave_critical_section(void) +{ + cpu_irq_leave_critical(); +} + +/** @} */ + +/** + * \name Interrupt Enabling/Disabling + * @{ + */ + +/** + * \brief Check if global interrupts are enabled + * + * Checks if global interrupts are currently enabled. + * + * \returns A boolean that identifies if the global interrupts are enabled or not. + * + * \retval true Global interrupts are currently enabled + * \retval false Global interrupts are currently disabled + * + */ +static inline bool system_interrupt_is_global_enabled(void) +{ + return cpu_irq_is_enabled(); +} + +/** + * \brief Enables global interrupts + * + * Enables global interrupts in the device to fire any enabled interrupt handlers. + */ +static inline void system_interrupt_enable_global(void) +{ + cpu_irq_enable(); +} + +/** + * \brief Disables global interrupts + * + * Disabled global interrupts in the device, preventing any enabled interrupt + * handlers from executing. + */ +static inline void system_interrupt_disable_global(void) +{ + cpu_irq_disable(); +} + +/** + * \brief Checks if an interrupt vector is enabled or not + * + * Checks if a specific interrupt vector is currently enabled. + * + * \param[in] vector Interrupt vector number to check + * + * \returns A variable identifying if the requested interrupt vector is enabled + * + * \retval true Specified interrupt vector is currently enabled + * \retval false Specified interrupt vector is currently disabled + * + */ +static inline bool system_interrupt_is_enabled( + const enum system_interrupt_vector vector) +{ + return (bool)((NVIC->ISER[0] >> (uint32_t)vector) & 0x00000001); +} + +/** + * \brief Enable interrupt vector + * + * Enables execution of the software handler for the requested interrupt vector. + * + * \param[in] vector Interrupt vector to enable + */ +static inline void system_interrupt_enable( + const enum system_interrupt_vector vector) +{ + NVIC->ISER[0] = (uint32_t)(1 << ((uint32_t)vector & 0x0000001f)); +} + +/** + * \brief Disable interrupt vector + * + * Disables execution of the software handler for the requested interrupt vector. + * + * \param[in] vector Interrupt vector to disable + */ +static inline void system_interrupt_disable( + const enum system_interrupt_vector vector) +{ + NVIC->ICER[0] = (uint32_t)(1 << ((uint32_t)vector & 0x0000001f)); +} + +/** @} */ + +/** + * \name Interrupt State Management + * @{ + */ + +/** + * \brief Get active interrupt (if any) + * + * Return the vector number for the current executing software handler, if any. + * + * \return Interrupt number that is currently executing. + */ +static inline enum system_interrupt_vector system_interrupt_get_active(void) +{ + uint32_t IPSR = __get_IPSR(); + + return (enum system_interrupt_vector)(IPSR & _SYSTEM_INTERRUPT_IPSR_MASK); +} + +bool system_interrupt_is_pending( + const enum system_interrupt_vector vector); + +enum status_code system_interrupt_set_pending( + const enum system_interrupt_vector vector); + +enum status_code system_interrupt_clear_pending( + const enum system_interrupt_vector vector); + +/** @} */ + +/** + * \name Interrupt Priority Management + * @{ + */ + +enum status_code system_interrupt_set_priority( + const enum system_interrupt_vector vector, + const enum system_interrupt_priority_level priority_level); + +enum system_interrupt_priority_level system_interrupt_get_priority( + const enum system_interrupt_vector vector); + +/** @} */ + +/** @} */ + +/** + * \page asfdoc_sam0_system_interrupt_extra Extra Information for SYSTEM INTERRUPT Driver + * + * \section asfdoc_sam0_system_interrupt_extra_acronyms Acronyms + * The table below presents the acronyms used in this module: + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
AcronymDescription
ISRInterrupt Service Routine
NMINon-maskable interrupt
SERCOMSerial Communication Interface
+ * + * + * \section asfdoc_sam0_system_interrupt_extra_dependencies Dependencies + * This driver has the following dependencies: + * + * - None + * + * + * \section asfdoc_sam0_system_interrupt_extra_errata Errata + * There are no errata related to this driver. + * + * + * \section asfdoc_sam0_system_interrupt_extra_history Module History + * An overview of the module history is presented in the table below, with + * details on the enhancements and fixes made to the module since its first + * release. The current version of this corresponds to the newest version in + * the table. + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Changelog
Added support for SAMD10/D11
Added support for SAMR21
Added support for SAMD21
Initial Release
+ */ + +/** + * \page asfdoc_sam0_system_interrupt_exqsg Examples for SYSTEM INTERRUPT Driver + * + * This is a list of the available Quick Start guides (QSGs) and example + * applications for \ref asfdoc_sam0_system_interrupt_group. QSGs are simple examples with + * step-by-step instructions to configure and use this driver in a selection of + * use cases. Note that QSGs can be compiled as a standalone application or be + * added to the user application. + * + * - \subpage asfdoc_sam0_system_interrupt_critsec_use_case + * - \subpage asfdoc_sam0_system_interrupt_enablemodint_use_case + * + * \page asfdoc_sam0_system_interrupt_document_revision_history Document Revision History + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Doc. Rev. + * Date + * Comments + *
E04/2014Add support for SAMD10/D11.
D02/2014Add support for SAMR21.
C01/2014Add support for SAMD21.
B06/2013Corrected documentation typos.
A06/2013Initial release
+ */ + +#ifdef __cplusplus +} +#endif + +#endif // #ifndef SYSTEM_INTERRUPT_H_INCLUDED diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/interrupt/system_interrupt_samd21/system_interrupt_features.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/interrupt/system_interrupt_samd21/system_interrupt_features.h new file mode 100644 index 0000000..d558a5c --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/interrupt/system_interrupt_samd21/system_interrupt_features.h @@ -0,0 +1,170 @@ +/** + * \file + * + * \brief SAM D21 System Interrupt Driver + * + * Copyright (C) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef SYSTEM_INTERRUPT_FEATURES_H_INCLUDED +#define SYSTEM_INTERRUPT_FEATURES_H_INCLUDED + +#if !defined(__DOXYGEN__) + +/* Generates a interrupt vector table enum list entry for a given module type + and index (e.g. "SYSTEM_INTERRUPT_MODULE_TC0 = TC0_IRQn,"). */ +# define _MODULE_IRQn(n, module) \ + SYSTEM_INTERRUPT_MODULE_##module##n = module##n##_IRQn, + +/* Generates interrupt vector table enum list entries for all instances of a + given module type on the selected device. */ +# define _SYSTEM_INTERRUPT_MODULES(name) \ + MREPEAT(name##_INST_NUM, _MODULE_IRQn, name) + +# define _SYSTEM_INTERRUPT_IPSR_MASK 0x0000003f +# define _SYSTEM_INTERRUPT_PRIORITY_MASK 0x00000007 + +# define _SYSTEM_INTERRUPT_EXTERNAL_VECTOR_START 0 + +# define _SYSTEM_INTERRUPT_SYSTICK_PRI_POS 29 +#endif + +/** + * \addtogroup asfdoc_sam0_system_interrupt_group + * @{ + */ + +/** + * \brief Table of possible system interrupt/exception vector numbers. + * + * Table of all possible interrupt and exception vector indexes within the + * SAMD21 device. + */ +#if defined(__DOXYGEN__) +/** \note The actual enumeration name is "system_interrupt_vector". */ +enum system_interrupt_vector_samd21 { +#else +enum system_interrupt_vector { +#endif + /** Interrupt vector index for a NMI interrupt. */ + SYSTEM_INTERRUPT_NON_MASKABLE = NonMaskableInt_IRQn, + /** Interrupt vector index for a Hard Fault memory access exception. */ + SYSTEM_INTERRUPT_HARD_FAULT = HardFault_IRQn, + /** Interrupt vector index for a Supervisor Call exception. */ + SYSTEM_INTERRUPT_SV_CALL = SVCall_IRQn, + /** Interrupt vector index for a Pending Supervisor interrupt. */ + SYSTEM_INTERRUPT_PENDING_SV = PendSV_IRQn, + /** Interrupt vector index for a System Tick interrupt. */ + SYSTEM_INTERRUPT_SYSTICK = SysTick_IRQn, + + /** Interrupt vector index for a Power Manager peripheral interrupt. */ + SYSTEM_INTERRUPT_MODULE_PM = PM_IRQn, + /** Interrupt vector index for a System Control peripheral interrupt. */ + SYSTEM_INTERRUPT_MODULE_SYSCTRL = SYSCTRL_IRQn, + /** Interrupt vector index for a Watch Dog peripheral interrupt. */ + SYSTEM_INTERRUPT_MODULE_WDT = WDT_IRQn, + /** Interrupt vector index for a Real Time Clock peripheral interrupt. */ + SYSTEM_INTERRUPT_MODULE_RTC = RTC_IRQn, + /** Interrupt vector index for an External Interrupt peripheral interrupt. */ + SYSTEM_INTERRUPT_MODULE_EIC = EIC_IRQn, + /** Interrupt vector index for a Non Volatile Memory Controller interrupt. */ + SYSTEM_INTERRUPT_MODULE_NVMCTRL = NVMCTRL_IRQn, + /** Interrupt vector index for a Direct Memory Access interrupt. */ + SYSTEM_INTERRUPT_MODULE_DMA = DMAC_IRQn, + /** Interrupt vector index for a Universal Serial Bus interrupt. */ + SYSTEM_INTERRUPT_MODULE_USB = USB_IRQn, + /** Interrupt vector index for an Event System interrupt. */ + SYSTEM_INTERRUPT_MODULE_EVSYS = EVSYS_IRQn, +#if defined(__DOXYGEN__) + /** Interrupt vector index for a SERCOM peripheral interrupt. + * + * Each specific device may contain several SERCOM peripherals; each module + * instance will have its own entry in the table, with the instance number + * substituted for "n" in the entry name (e.g. + * \c SYSTEM_INTERRUPT_MODULE_SERCOM0). + */ + SYSTEM_INTERRUPT_MODULE_SERCOMn = SERCOMn_IRQn, + + /** Interrupt vector index for a Timer/Counter Control peripheral interrupt. + * + * Each specific device may contain several TCC peripherals; each module + * instance will have its own entry in the table, with the instance number + * substituted for "n" in the entry name (e.g. + * \c SYSTEM_INTERRUPT_MODULE_TCC0). + */ + SYSTEM_INTERRUPT_MODULE_TCCn = TCCn_IRQn, + + /** Interrupt vector index for a Timer/Counter peripheral interrupt. + * + * Each specific device may contain several TC peripherals; each module + * instance will have its own entry in the table, with the instance number + * substituted for "n" in the entry name (e.g. + * \c SYSTEM_INTERRUPT_MODULE_TC3). + */ + SYSTEM_INTERRUPT_MODULE_TCn = TCn_IRQn, +#else + _SYSTEM_INTERRUPT_MODULES(SERCOM) + + _SYSTEM_INTERRUPT_MODULES(TCC) + + SYSTEM_INTERRUPT_MODULE_TC3 = TC3_IRQn, + SYSTEM_INTERRUPT_MODULE_TC4 = TC4_IRQn, + SYSTEM_INTERRUPT_MODULE_TC5 = TC5_IRQn, +# if (SAMD21J) + //SYSTEM_INTERRUPT_MODULE_TC6 = TC6_IRQn, + //SYSTEM_INTERRUPT_MODULE_TC7 = TC7_IRQn, +# endif +#endif + + /** Interrupt vector index for an Analog Comparator peripheral interrupt. */ + SYSTEM_INTERRUPT_MODULE_AC = AC_IRQn, + /** Interrupt vector index for an Analog-to-Digital peripheral interrupt. */ + SYSTEM_INTERRUPT_MODULE_ADC = ADC_IRQn, + /** Interrupt vector index for a Digital-to-Analog peripheral interrupt. */ + SYSTEM_INTERRUPT_MODULE_DAC = DAC_IRQn, + /** Interrupt vector index for a Peripheral Touch Controller peripheral + * interrupt. */ + SYSTEM_INTERRUPT_MODULE_PTC = PTC_IRQn, + /** Interrupt vector index for a Inter-IC Sound Interface peripheral + * interrupt. */ + SYSTEM_INTERRUPT_MODULE_I2S = I2S_IRQn, +}; + +/** @} */ + +#endif diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/pinmux/pinmux.c b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/pinmux/pinmux.c new file mode 100644 index 0000000..a47e559 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/pinmux/pinmux.c @@ -0,0 +1,215 @@ +/** + * \file + * + * \brief SAM Pin Multiplexer Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include + +/** + * \internal + * Writes out a given configuration of a Port pin configuration to the + * hardware module. + * + * \note If the pin direction is set as an output, the pull-up/pull-down input + * configuration setting is ignored. + * + * \param[in] port Base of the PORT module to configure. + * \param[in] pin_mask Mask of the port pin to configure. + * \param[in] config Configuration settings for the pin. + */ +static void _system_pinmux_config( + PortGroup *const port, + const uint32_t pin_mask, + const struct system_pinmux_config *const config) +{ + Assert(port); + Assert(config); + + /* Track the configuration bits into a temporary variable before writing */ + uint32_t pin_cfg = 0; + + /* Enabled powersave mode, don't create configuration */ + if (!config->powersave) { + /* Enable the pin peripheral mux flag if non-GPIO selected (pin mux will + * be written later) and store the new mux mask */ + if (config->mux_position != SYSTEM_PINMUX_GPIO) { + pin_cfg |= PORT_WRCONFIG_PMUXEN; + pin_cfg |= (config->mux_position << PORT_WRCONFIG_PMUX_Pos); + } + + /* Check if the user has requested that the input buffer be enabled */ + if ((config->direction == SYSTEM_PINMUX_PIN_DIR_INPUT) || + (config->direction == SYSTEM_PINMUX_PIN_DIR_OUTPUT_WITH_READBACK)) { + /* Enable input buffer flag */ + pin_cfg |= PORT_WRCONFIG_INEN; + + /* Enable pull-up/pull-down control flag if requested */ + if (config->input_pull != SYSTEM_PINMUX_PIN_PULL_NONE) { + pin_cfg |= PORT_WRCONFIG_PULLEN; + } + + /* Clear the port DIR bits to disable the output buffer */ + port->DIRCLR.reg = pin_mask; + } + + /* Check if the user has requested that the output buffer be enabled */ + if ((config->direction == SYSTEM_PINMUX_PIN_DIR_OUTPUT) || + (config->direction == SYSTEM_PINMUX_PIN_DIR_OUTPUT_WITH_READBACK)) { + /* Cannot use a pullup if the output driver is enabled, + * if requested the input buffer can only sample the current + * output state */ + pin_cfg &= ~PORT_WRCONFIG_PULLEN; + } + } + + /* The Write Configuration register (WRCONFIG) requires the + * pins to to grouped into two 16-bit half-words - split them out here */ + uint32_t lower_pin_mask = (pin_mask & 0xFFFF); + uint32_t upper_pin_mask = (pin_mask >> 16); + + /* Configure the lower 16-bits of the port to the desired configuration, + * including the pin peripheral multiplexer just in case it is enabled */ + port->WRCONFIG.reg + = (lower_pin_mask << PORT_WRCONFIG_PINMASK_Pos) | + pin_cfg | PORT_WRCONFIG_WRPMUX | PORT_WRCONFIG_WRPINCFG; + + /* Configure the upper 16-bits of the port to the desired configuration, + * including the pin peripheral multiplexer just in case it is enabled */ + port->WRCONFIG.reg + = (upper_pin_mask << PORT_WRCONFIG_PINMASK_Pos) | + pin_cfg | PORT_WRCONFIG_WRPMUX | PORT_WRCONFIG_WRPINCFG | + PORT_WRCONFIG_HWSEL; + + if(!config->powersave) { + /* Set the pull-up state once the port pins are configured if one was + * requested and it does not violate the valid set of port + * configurations */ + if (pin_cfg & PORT_WRCONFIG_PULLEN) { + /* Set the OUT register bits to enable the pullup if requested, + * clear to enable pull-down */ + if (config->input_pull == SYSTEM_PINMUX_PIN_PULL_UP) { + port->OUTSET.reg = pin_mask; + } else { + port->OUTCLR.reg = pin_mask; + } + } + + /* Check if the user has requested that the output buffer be enabled */ + if ((config->direction == SYSTEM_PINMUX_PIN_DIR_OUTPUT) || + (config->direction == SYSTEM_PINMUX_PIN_DIR_OUTPUT_WITH_READBACK)) { + /* Set the port DIR bits to enable the output buffer */ + port->DIRSET.reg = pin_mask; + } + } +} + +/** + * \brief Writes a Port pin configuration to the hardware module. + * + * Writes out a given configuration of a Port pin configuration to the hardware + * module. + * + * \note If the pin direction is set as an output, the pull-up/pull-down input + * configuration setting is ignored. + * + * \param[in] gpio_pin Index of the GPIO pin to configure. + * \param[in] config Configuration settings for the pin. + */ +void system_pinmux_pin_set_config( + const uint8_t gpio_pin, + const struct system_pinmux_config *const config) +{ + PortGroup *const port = system_pinmux_get_group_from_gpio_pin(gpio_pin); + uint32_t pin_mask = (1UL << (gpio_pin % 32)); + + _system_pinmux_config(port, pin_mask, config); +} + +/** + * \brief Writes a Port pin group configuration to the hardware module. + * + * Writes out a given configuration of a Port pin group configuration to the + * hardware module. + * + * \note If the pin direction is set as an output, the pull-up/pull-down input + * configuration setting is ignored. + * + * \param[in] port Base of the PORT module to configure. + * \param[in] mask Mask of the port pin(s) to configure. + * \param[in] config Configuration settings for the pin. + */ +void system_pinmux_group_set_config( + PortGroup *const port, + const uint32_t mask, + const struct system_pinmux_config *const config) +{ + Assert(port); + + for (int i = 0; i < 32; i++) { + if (mask & (1UL << i)) { + _system_pinmux_config(port, (1UL << i), config); + } + } +} + +/** + * \brief Configures the input sampling mode for a group of pins. + * + * Configures the input sampling mode for a group of pins, to + * control when the physical I/O pin value is sampled and + * stored inside the microcontroller. + * + * \param[in] port Base of the PORT module to configure. + * \param[in] mask Mask of the port pin(s) to configure. + * \param[in] mode New pin sampling mode to configure. + */ +void system_pinmux_group_set_input_sample_mode( + PortGroup *const port, + const uint32_t mask, + const enum system_pinmux_pin_sample mode) +{ + Assert(port); + + if (mode == SYSTEM_PINMUX_PIN_SAMPLE_ONDEMAND) { + port->CTRL.reg |= mask; + } else { + port->CTRL.reg &= ~mask; + } +} diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/pinmux/pinmux.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/pinmux/pinmux.h new file mode 100644 index 0000000..a5f35ec --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/pinmux/pinmux.h @@ -0,0 +1,517 @@ +/** + * \file + * + * \brief SAM Pin Multiplexer Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef PINMUX_H_INCLUDED +#define PINMUX_H_INCLUDED + +/** + * \defgroup asfdoc_sam0_system_pinmux_group SAM System Pin Multiplexer Driver (SYSTEM PINMUX) + * + * This driver for SAM devices provides an interface for the configuration + * and management of the device's physical I/O Pins, to alter the direction and + * input/drive characteristics as well as to configure the pin peripheral + * multiplexer selection. + * + * The following peripherals are used by this module: + * - PORT (Port I/O Management) + * + * The following devices can use this module: + * - SAM D20/D21 + * - SAM R21 + * - SAM D10/D11 + * + * Physically, the modules are interconnected within the device as shown in the + * following diagram: + * + * The outline of this documentation is as follows: + * - \ref asfdoc_sam0_system_pinmux_prerequisites + * - \ref asfdoc_sam0_system_pinmux_module_overview + * - \ref asfdoc_sam0_system_pinmux_special_considerations + * - \ref asfdoc_sam0_system_pinmux_extra_info + * - \ref asfdoc_sam0_system_pinmux_examples + * - \ref asfdoc_sam0_system_pinmux_api_overview + * + * + * \section asfdoc_sam0_system_pinmux_prerequisites Prerequisites + * + * There are no prerequisites for this module. + * + * + * \section asfdoc_sam0_system_pinmux_module_overview Module Overview + * + * The SAM devices contain a number of General Purpose I/O pins, used to + * interface the user application logic and internal hardware peripherals to + * an external system. The Pin Multiplexer (PINMUX) driver provides a method + * of configuring the individual pin peripheral multiplexers to select + * alternate pin functions. + * + * \subsection asfdoc_sam0_system_pinmux_physical_logical_pins Physical and Logical GPIO Pins + * SAM devices use two naming conventions for the I/O pins in the device; one + * physical, and one logical. Each physical pin on a device package is assigned + * both a physical port and pin identifier (e.g. "PORTA.0") as well as a + * monotonically incrementing logical GPIO number (e.g. "GPIO0"). While the + * former is used to map physical pins to their physical internal device module + * counterparts, for simplicity the design of this driver uses the logical GPIO + * numbers instead. + * + * \subsection asfdoc_sam0_system_pinmux_peripheral_muxing Peripheral Multiplexing + * SAM devices contain a peripheral MUX, which is individually controllable + * for each I/O pin of the device. The peripheral MUX allows you to select the + * function of a physical package pin - whether it will be controlled as a user + * controllable GPIO pin, or whether it will be connected internally to one of + * several peripheral modules (such as an I2C module). When a pin is + * configured in GPIO mode, other peripherals connected to the same pin will be + * disabled. + * + * \subsection asfdoc_sam0_system_pinmux_pad_characteristics Special Pad Characteristics + * There are several special modes that can be selected on one or more I/O pins + * of the device, which alter the input and output characteristics of the pad: + * + * \subsubsection asfdoc_sam0_system_pinmux_drive_strength Drive Strength + * The Drive Strength configures the strength of the output driver on the + * pad. Normally, there is a fixed current limit that each I/O pin can safely + * drive, however some I/O pads offer a higher drive mode which increases this + * limit for that I/O pin at the expense of an increased power consumption. + * + * \subsubsection asfdoc_sam0_system_pinmux_slew_rate Slew Rate + * The Slew Rate configures the slew rate of the output driver, limiting the + * rate at which the pad output voltage can change with time. + * + * \subsubsection asfdoc_sam0_system_pinmux_input_sample_mode Input Sample Mode + * The Input Sample Mode configures the input sampler buffer of the pad. By + * default, the input buffer is only sampled "on-demand", i.e. when the user + * application attempts to read from the input buffer. This mode is the most + * power efficient, but increases the latency of the input sample by two clock + * cycles of the port clock. To reduce latency, the input sampler can instead + * be configured to always sample the input buffer on each port clock cycle, at + * the expense of an increased power consumption. + * + * \subsection asfdoc_sam0_system_pinmux_module_overview_physical Physical Connection + * + * \ref asfdoc_sam0_system_pinmux_intconnections "The diagram below" shows + * how this module is interconnected within the device: + * + * \anchor asfdoc_sam0_system_pinmux_intconnections + * \dot + * digraph overview { + * node [label="Port Pad" shape=square] pad; + * + * subgraph driver { + * node [label="Peripheral Mux" shape=trapezium] pinmux; + * node [label="GPIO Module" shape=ellipse shape=ellipse style=filled fillcolor=lightgray] gpio; + * node [label="Other Peripheral Modules" shape=ellipse style=filled fillcolor=lightgray] peripherals; + * } + * + * pinmux -> gpio; + * pad -> pinmux; + * pinmux -> peripherals; + * } + * \enddot + * + * \section asfdoc_sam0_system_pinmux_special_considerations Special Considerations + * + * The SAM port pin input sampling mode is set in groups of four physical + * pins; setting the sampling mode of any pin in a sub-group of eight I/O pins + * will configure the sampling mode of the entire sub-group. + * + * High Drive Strength output driver mode is not available on all device pins - + * refer to your device specific datasheet. + * + * + * \section asfdoc_sam0_system_pinmux_extra_info Extra Information + * + * For extra information see \ref asfdoc_sam0_system_pinmux_extra. This includes: + * - \ref asfdoc_sam0_system_pinmux_extra_acronyms + * - \ref asfdoc_sam0_system_pinmux_extra_dependencies + * - \ref asfdoc_sam0_system_pinmux_extra_errata + * - \ref asfdoc_sam0_system_pinmux_extra_history + * + * + * \section asfdoc_sam0_system_pinmux_examples Examples + * + * For a list of examples related to this driver, see + * \ref asfdoc_sam0_system_pinmux_exqsg. + * + * + * \section asfdoc_sam0_system_pinmux_api_overview API Overview + * @{ + */ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** Peripheral multiplexer index to select GPIO mode for a pin. */ +#define SYSTEM_PINMUX_GPIO (1 << 7) + +/** + * \brief Port pin direction configuration enum. + * + * Enum for the possible pin direction settings of the port pin configuration + * structure, to indicate the direction the pin should use. + */ +enum system_pinmux_pin_dir { + /** The pin's input buffer should be enabled, so that the pin state can + * be read. */ + SYSTEM_PINMUX_PIN_DIR_INPUT, + /** The pin's output buffer should be enabled, so that the pin state can + * be set (but not read back). */ + SYSTEM_PINMUX_PIN_DIR_OUTPUT, + /** The pin's output and input buffers should both be enabled, so that the + * pin state can be set and read back. */ + SYSTEM_PINMUX_PIN_DIR_OUTPUT_WITH_READBACK, +}; + +/** + * \brief Port pin input pull configuration enum. + * + * Enum for the possible pin pull settings of the port pin configuration + * structure, to indicate the type of logic level pull the pin should use. + */ +enum system_pinmux_pin_pull { + /** No logical pull should be applied to the pin. */ + SYSTEM_PINMUX_PIN_PULL_NONE, + /** Pin should be pulled up when idle. */ + SYSTEM_PINMUX_PIN_PULL_UP, + /** Pin should be pulled down when idle. */ + SYSTEM_PINMUX_PIN_PULL_DOWN, +}; + +/** + * \brief Port pin digital input sampling mode enum. + * + * Enum for the possible input sampling modes for the port pin configuration + * structure, to indicate the type of sampling a port pin should use. + */ +enum system_pinmux_pin_sample { + /** Pin input buffer should continuously sample the pin state. */ + SYSTEM_PINMUX_PIN_SAMPLE_CONTINUOUS, + /** Pin input buffer should be enabled when the IN register is read. */ + SYSTEM_PINMUX_PIN_SAMPLE_ONDEMAND, +}; + +/** + * \brief Port pin configuration structure. + * + * Configuration structure for a port pin instance. This structure should be + * structure should be initialized by the + * \ref system_pinmux_get_config_defaults() function before being modified by + * the user application. + */ +struct system_pinmux_config { + /** MUX index of the peripheral that should control the pin, if peripheral + * control is desired. For GPIO use, this should be set to + * \ref SYSTEM_PINMUX_GPIO. */ + uint8_t mux_position; + + /** Port buffer input/output direction. */ + enum system_pinmux_pin_dir direction; + + /** Logic level pull of the input buffer. */ + enum system_pinmux_pin_pull input_pull; + + /** Enable lowest possible powerstate on the pin + * + * \note All other configurations will be ignored, the pin will be disabled + */ + bool powersave; +}; + +/** \name Configuration and initialization + * @{ + */ + +/** + * \brief Initializes a Port pin configuration structure to defaults. + * + * Initializes a given Port pin configuration structure to a set of + * known default values. This function should be called on all new + * instances of these configuration structures before being modified by the + * user application. + * + * The default configuration is as follows: + * \li Non peripheral (i.e. GPIO) controlled + * \li Input mode with internal pull-up enabled + * + * \param[out] config Configuration structure to initialize to default values + */ +static inline void system_pinmux_get_config_defaults( + struct system_pinmux_config *const config) +{ + /* Sanity check arguments */ + Assert(config); + + /* Default configuration values */ + config->mux_position = SYSTEM_PINMUX_GPIO; + config->direction = SYSTEM_PINMUX_PIN_DIR_INPUT; + config->input_pull = SYSTEM_PINMUX_PIN_PULL_UP; + config->powersave = false; +} + +void system_pinmux_pin_set_config( + const uint8_t gpio_pin, + const struct system_pinmux_config *const config); + +void system_pinmux_group_set_config( + PortGroup *const port, + const uint32_t mask, + const struct system_pinmux_config *const config); + +/** @} */ + +/** \name Special mode configuration (physical group orientated) + * @{ + */ + +/** + * \brief Retrieves the PORT module group instance from a given GPIO pin number. + * + * Retrieves the PORT module group instance associated with a given logical + * GPIO pin number. + * + * \param[in] gpio_pin Index of the GPIO pin to convert. + * + * \return Base address of the associated PORT module. + */ +static inline PortGroup* system_pinmux_get_group_from_gpio_pin( + const uint8_t gpio_pin) +{ + uint8_t port_index = (gpio_pin / 128); + uint8_t group_index = (gpio_pin / 32); + + /* Array of available ports. */ + Port *const ports[PORT_INST_NUM] = PORT_INSTS; + + if (port_index < PORT_INST_NUM) { + return &(ports[port_index]->Group[group_index]); + } else { + Assert(false); + return NULL; + } +} + +void system_pinmux_group_set_input_sample_mode( + PortGroup *const port, + const uint32_t mask, + const enum system_pinmux_pin_sample mode); + +/** @} */ + +/** \name Special mode configuration (logical pin orientated) + * @{ + */ + +/** + * \brief Retrieves the currently selected MUX position of a logical pin. + * + * Retrieves the selected MUX peripheral on a given logical GPIO pin. + * + * \param[in] gpio_pin Index of the GPIO pin to configure. + * + * \return Currently selected peripheral index on the specified pin. + */ +static inline uint8_t system_pinmux_pin_get_mux_position( + const uint8_t gpio_pin) +{ + PortGroup *const port = system_pinmux_get_group_from_gpio_pin(gpio_pin); + uint32_t pin_index = (gpio_pin % 32); + + if (!(port->PINCFG[pin_index].reg & PORT_PINCFG_PMUXEN)) { + return SYSTEM_PINMUX_GPIO; + } + + uint32_t pmux_reg = port->PMUX[pin_index / 2].reg; + + if (pin_index & 1) { + return (pmux_reg & PORT_PMUX_PMUXO_Msk) >> PORT_PMUX_PMUXO_Pos; + } + else { + return (pmux_reg & PORT_PMUX_PMUXE_Msk) >> PORT_PMUX_PMUXE_Pos; + } +} + +/** + * \brief Configures the input sampling mode for a GPIO pin. + * + * Configures the input sampling mode for a GPIO input, to + * control when the physical I/O pin value is sampled and + * stored inside the microcontroller. + * + * \param[in] gpio_pin Index of the GPIO pin to configure. + * \param[in] mode New pin sampling mode to configure. + */ +static inline void system_pinmux_pin_set_input_sample_mode( + const uint8_t gpio_pin, + const enum system_pinmux_pin_sample mode) +{ + PortGroup* const port = system_pinmux_get_group_from_gpio_pin(gpio_pin); + uint32_t pin_index = (gpio_pin % 32); + + if (mode == SYSTEM_PINMUX_PIN_SAMPLE_ONDEMAND) { + port->CTRL.reg |= (1 << pin_index); + } else { + port->CTRL.reg &= ~(1 << pin_index); + } +} + +/** @} */ + +#ifdef __cplusplus +} +#endif + +/** @} */ + +/** + * \page asfdoc_sam0_system_pinmux_extra Extra Information for SYSTEM PINMUX Driver + * + * \section asfdoc_sam0_system_pinmux_extra_acronyms Acronyms + * The table below presents the acronyms used in this module: + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
AcronymDescription
GPIOGeneral Purpose Input/Output
MUXMultiplexer
+ * + * + * \section asfdoc_sam0_system_pinmux_extra_dependencies Dependencies + * This driver has the following dependencies: + * + * - None + * + * + * \section asfdoc_sam0_system_pinmux_extra_errata Errata + * There are no errata related to this driver. + * + * + * \section asfdoc_sam0_system_pinmux_extra_history Module History + * An overview of the module history is presented in the table below, with + * details on the enhancements and fixes made to the module since its first + * release. The current version of this corresponds to the newest version in + * the table. + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Changelog
Removed code of open drain, slew limit and drive strength + * features.
Fixed broken sampling mode function implementations, which wrote + * corrupt configuration values to the device registers.
Added missing NULL pointer asserts to the PORT driver functions.
Initial Release
+ */ + +/** + * \page asfdoc_sam0_system_pinmux_exqsg Examples for SYSTEM PINMUX Driver + * + * This is a list of the available Quick Start guides (QSGs) and example + * applications for \ref asfdoc_sam0_system_pinmux_group. QSGs are simple + * examples with step-by-step instructions to configure and use this driver in a + * selection of use cases. Note that QSGs can be compiled as a standalone + * application or be added to the user application. + * + * - \subpage asfdoc_sam0_system_pinmux_basic_use_case + * + * \page asfdoc_sam0_system_pinmux_document_revision_history Document Revision History + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Doc. Rev. + * Date + * Comments + *
F04/2014Add support for SAMD10/D11
E02/2014Add support for SAMR21
D01/2014Add support for SAMD21
C09/2013Fixed incorrect documentation for the device pin sampling mode.
B06/2013Corrected documentation typos.
A06/2013Initial release
+ */ + +#endif diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/pinmux/quick_start/qs_pinmux_basic.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/pinmux/quick_start/qs_pinmux_basic.h new file mode 100644 index 0000000..d86ab4e --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/pinmux/quick_start/qs_pinmux_basic.h @@ -0,0 +1,93 @@ +/** + * \file + * + * \brief SAM PINMUX Driver Quick Start + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +/** + * \page asfdoc_sam0_system_pinmux_basic_use_case Quick Start Guide for SYSTEM PINMUX - Basic + * + * In this use case, the PINMUX module is configured for: + * \li One pin in input mode, with pull-up enabled, connected to the GPIO + * module + * \li Sampling mode of the pin changed to sample on demand + * + * This use case sets up the PINMUX to configure a physical I/O pin set as + * an input with pull-up. and changes the sampling mode of the pin to reduce + * power by only sampling the physical pin state when the user application + * attempts to read it. + * + * \section asfdoc_sam0_system_pinmux_basic_use_case_setup Setup + * + * \subsection asfdoc_sam0_system_pinmux_basic_use_case_setup_prereq Prerequisites + * There are no special setup requirements for this use-case. + * + * \subsection asfdoc_sam0_system_pinmux_basic_use_case_setup_code Code + * Copy-paste the following setup code to your application: + * \snippet qs_pinmux_basic.c setup + * + * \subsection asfdoc_sam0_system_pinmux_basic_use_case_setup_flow Workflow + * -# Create a PINMUX module pin configuration struct, which can be filled out + * to adjust the configuration of a single port pin. + * \snippet qs_pinmux_basic.c pinmux_config + * -# Initialize the pin configuration struct with the module's default values. + * \snippet qs_pinmux_basic.c pinmux_config_defaults + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Adjust the configuration struct to request an input pin with pullup + * connected to the GPIO peripheral. + * \snippet qs_pinmux_basic.c pinmux_update_config_values + * -# Configure GPIO10 with the initialized pin configuration struct, to enable + * the input sampler on the pin. + * \snippet qs_pinmux_basic.c pinmux_set_config + * + * \section asfdoc_sam0_system_pinmux_basic_use_case_use_main Use Case + * + * \subsection asfdoc_sam0_system_pinmux_basic_use_case_code Code + * Copy-paste the following code to your user application: + * \snippet qs_pinmux_basic.c main + * + * \subsection asfdoc_sam0_system_pinmux_basic_use_case_flow Workflow + + * -# Adjust the configuration of the pin to enable on-demand sampling mode. + * \snippet qs_pinmux_basic.c pinmux_change_input_sampling + */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/system.c b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/system.c new file mode 100644 index 0000000..7a052e8 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/system.c @@ -0,0 +1,102 @@ +/** + * \file + * + * \brief SAM System related functionality + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include + +/** + * \internal + * Dummy initialization function, used as a weak alias target for the various + * init functions called by \ref system_init(). + */ +void _system_dummy_init(void); +void _system_dummy_init(void) +{ + return; +} + +#if !defined(__DOXYGEN__) +# if defined(__GNUC__) +void system_clock_init(void) WEAK __attribute__((alias("_system_dummy_init"))); +void system_board_init(void) WEAK __attribute__((alias("_system_dummy_init"))); +void _system_events_init(void) WEAK __attribute__((alias("_system_dummy_init"))); +void _system_extint_init(void) WEAK __attribute__((alias("_system_dummy_init"))); +# elif defined(__ICCARM__) +void system_clock_init(void); +void system_board_init(void); +void _system_events_init(void); +void _system_extint_init(void); +# pragma weak system_clock_init=_system_dummy_init +# pragma weak system_board_init=_system_dummy_init +# pragma weak _system_events_init=_system_dummy_init +# pragma weak _system_extint_init=_system_dummy_init +# endif +#endif + +/** + * \brief Initialize system + * + * This function will call the various initialization functions within the + * system namespace. If a given optional system module is not available, the + * associated call will effectively be a NOP (No Operation). + * + * Currently the following initialization functions are supported: + * - System clock initialization (via the SYSTEM CLOCK sub-module) + * - Board hardware initialization (via the Board module) + * - Event system driver initialization (via the EVSYS module) + * - External Interrupt driver initialization (via the EXTINT module) + */ +void system_init(void) +{ + /* Configure GCLK and clock sources according to conf_clocks.h */ + system_clock_init(); + + /* Initialize board hardware */ + system_board_init(); + + /* Initialize EVSYS hardware */ + _system_events_init(); + + /* Initialize External hardware */ + _system_extint_init(); +} + diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/system.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/system.h new file mode 100644 index 0000000..d35df61 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/system/system.h @@ -0,0 +1,577 @@ +/** + * \file + * + * \brief SAM System related functionality + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef SYSTEM_H_INCLUDED +#define SYSTEM_H_INCLUDED + +#include +#include +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \defgroup asfdoc_sam0_system_group SAM System Driver (SYSTEM) + * + * This driver for SAM devices provides an interface for the configuration + * and management of the device's system relation functionality, necessary for + * the basic device operation. This is not limited to a single peripheral, but + * extends across multiple hardware peripherals, + * + * The following peripherals are used by this module: + * - SYSCTRL (System Control) + * - PM (Power Manager) + * + * The following devices can use this module: + * - SAM D20/D21 + * - SAM R21 + * - SAM D10/D11 + * + * The outline of this documentation is as follows: + * - \ref asfdoc_sam0_system_prerequisites + * - \ref asfdoc_sam0_system_module_overview + * - \ref asfdoc_sam0_system_special_considerations + * - \ref asfdoc_sam0_system_extra_info + * - \ref asfdoc_sam0_system_examples + * - \ref asfdoc_sam0_system_api_overview + * + * + * \section asfdoc_sam0_system_prerequisites Prerequisites + * + * There are no prerequisites for this module. + * + * + * \section asfdoc_sam0_system_module_overview Module Overview + * + * The System driver provides a collection of interfaces between the user + * application logic, and the core device functionality (such as clocks, reset + * cause determination, etc.) that is required for all applications. It contains + * a number of sub-modules that control one specific aspect of the device: + * + * - System Core (this module) + * - \ref asfdoc_sam0_system_clock_group "System Clock Control" (sub-module) + * - \ref asfdoc_sam0_system_interrupt_group "System Interrupt Control" (sub-module) + * - \ref asfdoc_sam0_system_pinmux_group "System Pin Multiplexer Control" (sub-module) + * + * + * \subsection asfdoc_sam0_system_module_overview_vref Voltage References + * The various analog modules within the SAM devices (such as AC, ADC and + * DAC) require a voltage reference to be configured to act as a reference point + * for comparisons and conversions. + * + * The SAM devices contain multiple references, including an internal + * temperature sensor, and a fixed band-gap voltage source. When enabled, the + * associated voltage reference can be selected within the desired peripheral + * where applicable. + * + * \subsection asfdoc_sam0_system_module_overview_reset_cause System Reset Cause + * In some application there may be a need to execute a different program + * flow based on how the device was reset. For example, if the cause of reset + * was the Watchdog timer (WDT), this might indicate an error in the application + * and a form of error handling or error logging might be needed. + * + * For this reason, an API is provided to retrieve the cause of the last system + * reset, so that appropriate action can be taken. + * + * \subsection asfdoc_sam0_system_module_overview_sleep_mode Sleep Modes + * The SAM devices have several sleep modes, where the sleep mode controls + * which clock systems on the device will remain enabled or disabled when the + * device enters a low power sleep mode. + * \ref asfdoc_sam0_system_module_sleep_mode_table "The table below" lists the + * clock settings of the different sleep modes. + * + * \anchor asfdoc_sam0_system_module_sleep_mode_table + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
SAM Device Sleep Modes
Sleep modeCPU clockAHB clockAPB clocksClock sourcesSystem clock32KHzReg modeRAM mode
IDLE 0StopRunRunRunRunRunNormalNormal
IDLE 1StopStopRunRunRunRunNormalNormal
IDLE 2StopStopStopRunRunRunNormalNormal
STANDBYStopStopStopStopStopStopLow PowerSource/Drain biasing
+ * + * To enter device sleep, one of the available sleep modes must be set, and the + * function to enter sleep called. The device will automatically wake up in + * response to an interrupt being generated or other device event. + * + * Some peripheral clocks will remain enabled during sleep, depending on their + * configuration; if desired, modules can remain clocked during sleep to allow + * them to continue to operate while other parts of the system are powered down + * to save power. + * + * + * \section asfdoc_sam0_system_special_considerations Special Considerations + * + * Most of the functions in this driver have device specific restrictions and + * caveats; refer to your device datasheet. + * + * + * \section asfdoc_sam0_system_extra_info Extra Information + * + * For extra information see \ref asfdoc_sam0_system_extra. This includes: + * - \ref asfdoc_sam0_system_extra_acronyms + * - \ref asfdoc_sam0_system_extra_dependencies + * - \ref asfdoc_sam0_system_extra_errata + * - \ref asfdoc_sam0_system_extra_history + * + * + * \section asfdoc_sam0_system_examples Examples + * + * For SYSTEM module related examples, please refer to the sub-modules listed in + * the \ref asfdoc_sam0_system_module_overview "system module overview". + * + * + * \section asfdoc_sam0_system_api_overview API Overview + * @{ + */ + +/** + * \brief Voltage references within the device. + * + * List of available voltage references (VREF) that may be used within the + * device. + */ +enum system_voltage_reference { + /** Temperature sensor voltage reference. */ + SYSTEM_VOLTAGE_REFERENCE_TEMPSENSE, + /** Bandgap voltage reference. */ + SYSTEM_VOLTAGE_REFERENCE_BANDGAP, +}; + +/** + * \brief Device sleep modes. + * + * List of available sleep modes in the device. A table of clocks available in + * different sleep modes can be found in \ref asfdoc_sam0_system_module_overview_sleep_mode. + */ +enum system_sleepmode { + /** IDLE 0 sleep mode. */ + SYSTEM_SLEEPMODE_IDLE_0, + /** IDLE 1 sleep mode. */ + SYSTEM_SLEEPMODE_IDLE_1, + /** IDLE 2 sleep mode. */ + SYSTEM_SLEEPMODE_IDLE_2, + /** Standby sleep mode. */ + SYSTEM_SLEEPMODE_STANDBY, +}; + +/** + * \brief Reset causes of the system. + * + * List of possible reset causes of the system. + */ +enum system_reset_cause { + /** The system was last reset by a software reset. */ + SYSTEM_RESET_CAUSE_SOFTWARE = PM_RCAUSE_SYST, + /** The system was last reset by the watchdog timer. */ + SYSTEM_RESET_CAUSE_WDT = PM_RCAUSE_WDT, + /** The system was last reset because the external reset line was pulled low. */ + SYSTEM_RESET_CAUSE_EXTERNAL_RESET = PM_RCAUSE_EXT, + /** The system was last reset by the BOD33. */ + SYSTEM_RESET_CAUSE_BOD33 = PM_RCAUSE_BOD33, + /** The system was last reset by the BOD12. */ + SYSTEM_RESET_CAUSE_BOD12 = PM_RCAUSE_BOD12, + /** The system was last reset by the POR (Power on reset). */ + SYSTEM_RESET_CAUSE_POR = PM_RCAUSE_POR, +}; + +/** + * \name System identification + * @{ + */ + +/** + * \brief Retrieve the device identification signature + * + * Retrieves the signature of the current device. + * + * \return Device ID signature as a 32-bit integer. + */ +static inline uint32_t system_get_device_id(void) +{ + return DSU->DID.reg; +} + +/** + * @} + */ + + +/** + * \name Voltage references + * @{ + */ + +/** + * \brief Enable the selected voltage reference + * + * Enables the selected voltage reference source, making the voltage reference + * available on a pin as well as an input source to the analog peripherals. + * + * \param[in] vref Voltage reference to enable + */ +static inline void system_voltage_reference_enable( + const enum system_voltage_reference vref) +{ + switch (vref) { + case SYSTEM_VOLTAGE_REFERENCE_TEMPSENSE: + SYSCTRL->VREF.reg |= SYSCTRL_VREF_TSEN; + break; + + case SYSTEM_VOLTAGE_REFERENCE_BANDGAP: + SYSCTRL->VREF.reg |= SYSCTRL_VREF_BGOUTEN; + break; + + default: + Assert(false); + return; + } +} + +/** + * \brief Disable the selected voltage reference + * + * Disables the selected voltage reference source. + * + * \param[in] vref Voltage reference to disable + */ +static inline void system_voltage_reference_disable( + const enum system_voltage_reference vref) +{ + switch (vref) { + case SYSTEM_VOLTAGE_REFERENCE_TEMPSENSE: + SYSCTRL->VREF.reg &= ~SYSCTRL_VREF_TSEN; + break; + + case SYSTEM_VOLTAGE_REFERENCE_BANDGAP: + SYSCTRL->VREF.reg &= ~SYSCTRL_VREF_BGOUTEN; + break; + + default: + Assert(false); + return; + } +} + +/** + * @} + */ + + +/** + * \name Device sleep + * @{ + */ + +/** + * \brief Set the sleep mode of the device + * + * Sets the sleep mode of the device; the configured sleep mode will be entered + * upon the next call of the \ref system_sleep() function. + * + * For an overview of which systems are disabled in sleep for the different + * sleep modes, see \ref asfdoc_sam0_system_module_overview_sleep_mode. + * + * \param[in] sleep_mode Sleep mode to configure for the next sleep operation + * + * \retval STATUS_OK Operation completed successfully + * \retval STATUS_ERR_INVALID_ARG The requested sleep mode was invalid or not + * available + */ +static inline enum status_code system_set_sleepmode( + const enum system_sleepmode sleep_mode) +{ + switch (sleep_mode) { + case SYSTEM_SLEEPMODE_IDLE_0: + case SYSTEM_SLEEPMODE_IDLE_1: + case SYSTEM_SLEEPMODE_IDLE_2: + SCB->SCR &= ~SCB_SCR_SLEEPDEEP_Msk; + PM->SLEEP.reg = sleep_mode; + break; + + case SYSTEM_SLEEPMODE_STANDBY: + SCB->SCR |= SCB_SCR_SLEEPDEEP_Msk; + break; + + default: + return STATUS_ERR_INVALID_ARG; + } + + return STATUS_OK; +} + +/** + * \brief Put the system to sleep waiting for interrupt + * + * Executes a device DSB (Data Synchronization Barrier) instruction to ensure + * all ongoing memory accesses have completed, then a WFI (Wait For Interrupt) + * instruction to place the device into the sleep mode specified by + * \ref system_set_sleepmode until woken by an interrupt. + */ +static inline void system_sleep(void) +{ + __DSB(); + __WFI(); +} + +/** + * @} + */ + +/** + * \name Reset control + * @{ + */ + +/** + * \brief Check if bugger is present + * + * Check if debugger is connected to the onboard debug system (DAP) + * + * \return A bool identifying if a debugger is present + * + * \retval true Debugger is connected to the system + * \retval false Debugger is not connected to the system + * + */ +static inline bool system_is_debugger_present(void) +{ + return DSU->STATUSB.reg & DSU_STATUSB_DBGPRES; +} + +/** + * \brief Reset the MCU + * + * Resets the MCU and all associated peripherals and registers, except RTC, all 32kHz sources, + * WDT (if ALWAYSON is set) and GCLK (if WRTLOCK is set). + * + */ +static inline void system_reset(void) +{ + NVIC_SystemReset(); +} + +/** + * \brief Return the reset cause + * + * Retrieves the cause of the last system reset. + * + * \return An enum value indicating the cause of the last system reset. + */ +static inline enum system_reset_cause system_get_reset_cause(void) +{ + return (enum system_reset_cause)PM->RCAUSE.reg; +} + +/** + * @} + */ + + +/** + * \name System initialization + * @{ + */ + +void system_init(void); + +/** + * @} + */ + + +/** + * @} + */ + +/** + * \page asfdoc_sam0_system_extra Extra Information for SYSTEM Driver + * + * \section asfdoc_sam0_system_extra_acronyms Acronyms + * Below is a table listing the acronyms used in this module, along with their + * intended meanings. + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
AcronymDefinition
PMPower Manager
SYSCTRLSystem control interface
+ * + * + * \section asfdoc_sam0_system_extra_dependencies Dependencies + * This driver has the following dependencies: + * + * - None + * + * + * \section asfdoc_sam0_system_extra_errata Errata + * There are no errata related to this driver. + * + * + * \section asfdoc_sam0_system_extra_history Module History + * An overview of the module history is presented in the table below, with + * details on the enhancements and fixes made to the module since its first + * release. The current version of this corresponds to the newest version in + * the table. + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Changelog
Added support for SAMD21
Added new \c system_reset() to reset the complete MCU with some exceptions
Added new \c system_get_device_id() function to retrieved the device + * ID.
Initial Release
+ * + * \page asfdoc_sam0_system_document_revision_history Document Revision History + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Doc. Rev. + * Date + * Comments + *
E04/2014Added support for SAMD10/D11.
D02/2014Added support for SAMR21.
C01/2014Added support for SAMD21.
B06/2013Corrected documentation typos.
A06/2013Initial release
+ */ + +#ifdef __cplusplus +} +#endif + +#endif /* SYSTEM_H_INCLUDED */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/usb/stack_interface/usb_device_udd.c b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/usb/stack_interface/usb_device_udd.c new file mode 100644 index 0000000..7312da8 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/usb/stack_interface/usb_device_udd.c @@ -0,0 +1,1242 @@ +/** + * \file + * + * \brief USB Device wrapper layer for compliance with common driver UDD + * + * Copyright (C) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include +#include + +// Get USB device configuration +#include "conf_usb.h" +#include "udd.h" +#include "usb.h" +#include "usb_dual.h" +#include "sleepmgr.h" + +/** + * \ingroup usb_device_group + * \defgroup usb_device_udd_group USB Device Driver Implement (UDD) + * USB low-level driver for USB device mode + * @{ + */ +// Check USB device configuration +#ifdef USB_DEVICE_HS_SUPPORT +# error The High speed mode is not supported on this part, please remove USB_DEVICE_HS_SUPPORT in conf_usb.h +#endif + +#if !(SAMD21) && !(SAMR21) && !(SAMD11) +# error The current USB Device Driver supports only SAMD21/R21/D11 +#endif + +#ifndef UDC_REMOTEWAKEUP_LPM_ENABLE +#define UDC_REMOTEWAKEUP_LPM_ENABLE() +#endif +#ifndef UDC_REMOTEWAKEUP_LPM_DISABLE +#define UDC_REMOTEWAKEUP_LPM_DISABLE() +#endif +#ifndef UDC_SUSPEND_LPM_EVENT +#define UDC_SUSPEND_LPM_EVENT() +#endif + +/* for debug text */ +#ifdef USB_DEBUG +# define dbg_print printf +#else +# define dbg_print(...) +#endif + +/** Maximum size of a transfer in multi-packet mode */ +#define UDD_ENDPOINT_MAX_TRANS ((8*1024)-1) + +/** USB software device instance structure */ +struct usb_module usb_device; + +/** + * \name Clock management + * + * @{ + */ +#ifndef UDD_CLOCK_GEN +# define UDD_CLOCK_GEN GCLK_GENERATOR_0 +#endif +#ifndef UDD_CLOCK_SOURCE +# define UDD_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_DFLL +#endif +static inline void udd_wait_clock_ready(void) +{ + + if (UDD_CLOCK_SOURCE == SYSTEM_CLOCK_SOURCE_DPLL) { +#define DPLL_READY_FLAG (SYSCTRL_DPLLSTATUS_ENABLE | \ + SYSCTRL_DPLLSTATUS_CLKRDY | SYSCTRL_DPLLSTATUS_LOCK) + + while((SYSCTRL->DPLLSTATUS.reg & DPLL_READY_FLAG) != DPLL_READY_FLAG); + } + + if (UDD_CLOCK_SOURCE == SYSTEM_CLOCK_SOURCE_DFLL) { +#define DFLL_READY_FLAG (SYSCTRL_PCLKSR_DFLLRDY | \ + SYSCTRL_PCLKSR_DFLLLCKF | SYSCTRL_PCLKSR_DFLLLCKC) + + /* In USB recovery mode the status is not checked */ + if (!(SYSCTRL->DFLLCTRL.reg & SYSCTRL_DFLLCTRL_USBCRM)) { + while((SYSCTRL->PCLKSR.reg & DFLL_READY_FLAG) != DFLL_READY_FLAG); + } else { + while((SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_DFLLRDY) != SYSCTRL_PCLKSR_DFLLRDY); + } + } + +} +/** @} */ + +/** + * \name Power management + * + * @{ + */ +#ifndef UDD_NO_SLEEP_MGR + +#include "sleepmgr.h" +/** States of USB interface */ +enum udd_usb_state_enum { + UDD_STATE_OFF, + UDD_STATE_SUSPEND, + UDD_STATE_SUSPEND_LPM, + UDD_STATE_IDLE, +}; + +/** \brief Manages the sleep mode following the USB state + * + * \param new_state New USB state + */ +static void udd_sleep_mode(enum udd_usb_state_enum new_state) +{ + enum sleepmgr_mode sleep_mode[] = { + SLEEPMGR_ACTIVE, /* UDD_STATE_OFF (not used) */ + SLEEPMGR_IDLE_2, /* UDD_STATE_SUSPEND */ + SLEEPMGR_IDLE_1, /* UDD_STATE_SUSPEND_LPM */ + SLEEPMGR_IDLE_0, /* UDD_STATE_IDLE */ + }; + + static enum udd_usb_state_enum udd_state = UDD_STATE_OFF; + + if (udd_state == new_state) { + return; // No change + } + if (new_state != UDD_STATE_OFF) { + /* Lock new limit */ + sleepmgr_lock_mode(sleep_mode[new_state]); + } + if (udd_state != UDD_STATE_OFF) { + /* Unlock old limit */ + sleepmgr_unlock_mode(sleep_mode[udd_state]); + } + udd_state = new_state; +} + +#else +# define udd_sleep_mode(arg) +#endif +/** @} */ + +/** + * \name Control endpoint low level management routine. + * + * This function performs control endpoint management. + * It handles the SETUP/DATA/HANDSHAKE phases of a control transaction. + * + * @{ + */ + +/** + * \brief Buffer to store the data received on control endpoint (SETUP/OUT endpoint 0) + * + * Used to avoid a RAM buffer overflow in case of the payload buffer + * is smaller than control endpoint size + */ +UDC_BSS(4) +uint8_t udd_ctrl_buffer[USB_DEVICE_EP_CTRL_SIZE]; + +/** Bit definitions about endpoint control state machine for udd_ep_control_state */ +typedef enum { + UDD_EPCTRL_SETUP = 0, //!< Wait a SETUP packet + UDD_EPCTRL_DATA_OUT = 1, //!< Wait a OUT data packet + UDD_EPCTRL_DATA_IN = 2, //!< Wait a IN data packet + UDD_EPCTRL_HANDSHAKE_WAIT_IN_ZLP = 3, //!< Wait a IN ZLP packet + UDD_EPCTRL_HANDSHAKE_WAIT_OUT_ZLP = 4, //!< Wait a OUT ZLP packet + UDD_EPCTRL_STALL_REQ = 5, //!< STALL enabled on IN & OUT packet +} udd_ctrl_ep_state_t; + +/** Global variable to give and record information of the set up request management */ +udd_ctrl_request_t udd_g_ctrlreq; + +/** State of the endpoint control management */ +static udd_ctrl_ep_state_t udd_ep_control_state; + +/** Total number of data received/sent during data packet phase with previous payload buffers */ +static uint16_t udd_ctrl_prev_payload_nb_trans; + +/** Number of data received/sent to/from udd_g_ctrlreq.payload buffer */ +static uint16_t udd_ctrl_payload_nb_trans; + +/** @} */ + +/** + * \name Management of bulk/interrupt/isochronous endpoints + * + * The UDD manages the data transfer on endpoints: + * - Start data transfer on endpoint with USB Device DMA + * - Send a ZLP packet if requested + * - Call callback registered to signal end of transfer + * The transfer abort and stall feature are supported. + * + * @{ + */ + +/** + * \brief Buffer to store the data received on bulk/interrupt endpoints + * + * Used to avoid a RAM buffer overflow in case of the user buffer + * is smaller than endpoint size + * + * \warning The protected interrupt endpoint size is 512 bytes maximum. + * \warning The isochronous and endpoint is not protected by this system and + * the user must always use a buffer corresponding at endpoint size. + */ +#if (defined USB_DEVICE_LOW_SPEED) +UDC_BSS(4) uint8_t udd_ep_out_cache_buffer[USB_DEVICE_MAX_EP][8]; +#elif (defined USB_DEVICE_HS_SUPPORT) +UDC_BSS(4) uint8_t udd_ep_out_cache_buffer[USB_DEVICE_MAX_EP][512]; +#else +UDC_BSS(4) uint8_t udd_ep_out_cache_buffer[USB_DEVICE_MAX_EP][64]; +#endif + +/** Structure definition about job registered on an endpoint */ +typedef struct { + union { + //! Callback to call at the end of transfer + udd_callback_trans_t call_trans; + //! Callback to call when the endpoint halt is cleared + udd_callback_halt_cleared_t call_nohalt; + }; + //! Buffer located in internal RAM to send or fill during job + uint8_t *buf; + //! Size of buffer to send or fill + iram_size_t buf_size; + //! Total number of data transferred on endpoint + iram_size_t nb_trans; + //! Endpoint size + uint16_t ep_size; + //! A job is registered on this endpoint + uint8_t busy:1; + //! A short packet is requested for this job on endpoint IN + uint8_t b_shortpacket:1; + //! The cache buffer is currently used on endpoint OUT + uint8_t b_use_out_cache_buffer:1; +} udd_ep_job_t; + +/** Array to register a job on bulk/interrupt/isochronous endpoint */ +static udd_ep_job_t udd_ep_job[2 * USB_DEVICE_MAX_EP]; + +/** @} */ + +/** + * \brief Get the detailed job by endpoint number + * \param[in] ep Endpoint Address + * \retval pointer to an udd_ep_job_t structure instance + */ +static udd_ep_job_t* udd_ep_get_job(udd_ep_id_t ep) +{ + return &udd_ep_job[(2 * (ep & USB_EP_ADDR_MASK) + ((ep & USB_EP_DIR_IN) ? 1 : 0)) - 2]; +} + +/** + * \brief Endpoint IN process, continue to send packets or zero length packet + * \param[in] pointer Pointer to the endpoint transfer status parameter struct from driver layer. + */ +static void udd_ep_trans_in_next(void* pointer) +{ + struct usb_endpoint_callback_parameter *ep_callback_para = (struct usb_endpoint_callback_parameter*)pointer; + udd_ep_id_t ep = ep_callback_para->endpoint_address; + uint16_t ep_size, nb_trans; + uint16_t next_trans; + udd_ep_id_t ep_num; + udd_ep_job_t *ptr_job; + + ptr_job = udd_ep_get_job(ep); + ep_num = ep & USB_EP_ADDR_MASK; + + ep_size = ptr_job->ep_size; + /* Update number of data transferred */ + nb_trans = ep_callback_para->sent_bytes; + ptr_job->nb_trans += nb_trans; + + /* Need to send other data */ + if (ptr_job->nb_trans != ptr_job->buf_size) { + next_trans = ptr_job->buf_size - ptr_job->nb_trans; + if (UDD_ENDPOINT_MAX_TRANS < next_trans) { + /* The USB hardware support a maximum + * transfer size of UDD_ENDPOINT_MAX_TRANS Bytes */ + next_trans = UDD_ENDPOINT_MAX_TRANS -(UDD_ENDPOINT_MAX_TRANS % ep_size); + } + /* Need ZLP, if requested and last packet is not a short packet */ + ptr_job->b_shortpacket = ptr_job->b_shortpacket && (0 == (next_trans % ep_size)); + usb_device_endpoint_write_buffer_job(&usb_device,ep_num,&ptr_job->buf[ptr_job->nb_trans],next_trans); + return; + } + + /* Need to send a ZLP after all data transfer */ + if (ptr_job->b_shortpacket) { + ptr_job->b_shortpacket = false; + /* Start new transfer */ + usb_device_endpoint_write_buffer_job(&usb_device,ep_num,&ptr_job->buf[ptr_job->nb_trans],0); + return; + } + + /* Job complete then call callback */ + ptr_job->busy = false; + if (NULL != ptr_job->call_trans) { + ptr_job->call_trans(UDD_EP_TRANSFER_OK, ptr_job->nb_trans, ep); + } +} + +/** + * \brief Endpoint OUT process, continue to receive packets or zero length packet + * \param[in] pointer Pointer to the endpoint transfer status parameter struct from driver layer. + */ +static void udd_ep_trans_out_next(void* pointer) +{ + struct usb_endpoint_callback_parameter *ep_callback_para = (struct usb_endpoint_callback_parameter*)pointer; + udd_ep_id_t ep = ep_callback_para->endpoint_address; + uint16_t ep_size, nb_trans; + uint16_t next_trans; + udd_ep_id_t ep_num; + udd_ep_job_t *ptr_job; + + ptr_job = udd_ep_get_job(ep); + ep_num = ep & USB_EP_ADDR_MASK; + + ep_size = ptr_job->ep_size; + /* Update number of data transferred */ + nb_trans = ep_callback_para->received_bytes; + + /* Can be necessary to copy data receive from cache buffer to user buffer */ + if (ptr_job->b_use_out_cache_buffer) { + memcpy(&ptr_job->buf[ptr_job->nb_trans], udd_ep_out_cache_buffer[ep_num - 1], ptr_job->buf_size % ep_size); + } + + /* Update number of data transferred */ + ptr_job->nb_trans += nb_trans; + if (ptr_job->nb_trans > ptr_job->buf_size) { + ptr_job->nb_trans = ptr_job->buf_size; + } + + /* If all previous data requested are received and user buffer not full + * then need to receive other data */ + if ((nb_trans == ep_callback_para->out_buffer_size) && (ptr_job->nb_trans != ptr_job->buf_size)) { + next_trans = ptr_job->buf_size - ptr_job->nb_trans; + if (UDD_ENDPOINT_MAX_TRANS < next_trans) { + /* The USB hardware support a maximum transfer size + * of UDD_ENDPOINT_MAX_TRANS Bytes */ + next_trans = UDD_ENDPOINT_MAX_TRANS - (UDD_ENDPOINT_MAX_TRANS % ep_size); + } else { + next_trans -= next_trans % ep_size; + } + + if (next_trans < ep_size) { + /* Use the cache buffer for Bulk or Interrupt size endpoint */ + ptr_job->b_use_out_cache_buffer = true; + usb_device_endpoint_read_buffer_job(&usb_device,ep_num,udd_ep_out_cache_buffer[ep_num - 1],ep_size); + } else { + usb_device_endpoint_read_buffer_job(&usb_device,ep_num,&ptr_job->buf[ptr_job->nb_trans],next_trans); + } + return; + } + + /* Job complete then call callback */ + ptr_job->busy = false; + if (NULL != ptr_job->call_trans) { + ptr_job->call_trans(UDD_EP_TRANSFER_OK, ptr_job->nb_trans, ep); + } +} + +/** + * \brief Endpoint Transfer Complete callback function, to do the next transfer depends on the direction(IN or OUT) + * \param[in] module_inst Pointer to USB module instance + * \param[in] pointer Pointer to the endpoint transfer status parameter struct from driver layer. + */ +static void udd_ep_transfer_process(struct usb_module *module_inst, void* pointer) +{ + struct usb_endpoint_callback_parameter *ep_callback_para = (struct usb_endpoint_callback_parameter*)pointer; + udd_ep_id_t ep = ep_callback_para->endpoint_address; + + if (ep & USB_EP_DIR_IN) { + udd_ep_trans_in_next(pointer); + } else { + udd_ep_trans_out_next(pointer); + } +} + +void udd_ep_abort(udd_ep_id_t ep) +{ + udd_ep_job_t *ptr_job; + + usb_device_endpoint_abort_job(&usb_device, ep); + + /* Job complete then call callback */ + ptr_job = udd_ep_get_job(ep); + if (!ptr_job->busy) { + return; + } + ptr_job->busy = false; + if (NULL != ptr_job->call_trans) { + /* It can be a Transfer or stall callback */ + ptr_job->call_trans(UDD_EP_TRANSFER_ABORT, ptr_job->nb_trans, ep); + } +} + +bool udd_is_high_speed(void) +{ +#if SAMD21 || SAMR21 || SAMD11 + return false; +#endif +} + +uint16_t udd_get_frame_number(void) +{ + return usb_device_get_frame_number(&usb_device); +} + +uint16_t udd_get_micro_frame_number(void) +{ + return usb_device_get_micro_frame_number(&usb_device); +} + +void udd_ep_free(udd_ep_id_t ep) +{ + struct usb_device_endpoint_config config_ep; + usb_device_endpoint_get_config_defaults(&config_ep); + + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + udd_ep_abort(ep); + + config_ep.ep_address = ep; + config_ep.ep_type = USB_DEVICE_ENDPOINT_TYPE_DISABLE; + usb_device_endpoint_set_config(&usb_device, &config_ep); + usb_device_endpoint_unregister_callback(&usb_device,ep_num,USB_DEVICE_ENDPOINT_CALLBACK_TRCPT); + usb_device_endpoint_disable_callback(&usb_device,ep,USB_DEVICE_ENDPOINT_CALLBACK_TRCPT); +} + +bool udd_ep_alloc(udd_ep_id_t ep, uint8_t bmAttributes, uint16_t MaxEndpointSize) +{ + struct usb_device_endpoint_config config_ep; + usb_device_endpoint_get_config_defaults(&config_ep); + + config_ep.ep_address = ep; + + if(MaxEndpointSize <= 8) { + config_ep.ep_size = USB_ENDPOINT_8_BYTE; + } else if(MaxEndpointSize <= 16) { + config_ep.ep_size = USB_ENDPOINT_16_BYTE; + } else if(MaxEndpointSize <= 32) { + config_ep.ep_size = USB_ENDPOINT_32_BYTE; + } else if(MaxEndpointSize <= 64) { + config_ep.ep_size = USB_ENDPOINT_64_BYTE; + } else if(MaxEndpointSize <= 128) { + config_ep.ep_size = USB_ENDPOINT_128_BYTE; + } else if(MaxEndpointSize <= 256) { + config_ep.ep_size = USB_ENDPOINT_256_BYTE; + } else if(MaxEndpointSize <= 512) { + config_ep.ep_size = USB_ENDPOINT_512_BYTE; + } else if(MaxEndpointSize <= 1023) { + config_ep.ep_size = USB_ENDPOINT_1023_BYTE; + } else { + return false; + } + udd_ep_job_t *ptr_job = udd_ep_get_job(ep); + ptr_job->ep_size = MaxEndpointSize; + + bmAttributes = bmAttributes & USB_EP_TYPE_MASK; + + /* Check endpoint type */ + if(USB_EP_TYPE_ISOCHRONOUS == bmAttributes) { + config_ep.ep_type = USB_DEVICE_ENDPOINT_TYPE_ISOCHRONOUS; + } else if (USB_EP_TYPE_BULK == bmAttributes) { + config_ep.ep_type = USB_DEVICE_ENDPOINT_TYPE_BULK; + } else if (USB_EP_TYPE_INTERRUPT == bmAttributes) { + config_ep.ep_type = USB_DEVICE_ENDPOINT_TYPE_INTERRUPT; + } else { + return false; + } + + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + + if (STATUS_OK != usb_device_endpoint_set_config(&usb_device, &config_ep)) { + return false; + } + usb_device_endpoint_register_callback(&usb_device,ep_num,USB_DEVICE_ENDPOINT_CALLBACK_TRCPT,udd_ep_transfer_process); + usb_device_endpoint_enable_callback(&usb_device,ep,USB_DEVICE_ENDPOINT_CALLBACK_TRCPT); + usb_device_endpoint_enable_callback(&usb_device,ep,USB_DEVICE_ENDPOINT_CALLBACK_TRFAIL); + + return true; +} + +bool udd_ep_is_halted(udd_ep_id_t ep) +{ + return usb_device_endpoint_is_halted(&usb_device, ep); +} + +bool udd_ep_set_halt(udd_ep_id_t ep) +{ + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + + if (USB_DEVICE_MAX_EP < ep_num) { + return false; + } + + usb_device_endpoint_set_halt(&usb_device, ep); + + udd_ep_abort(ep); + return true; +} + +bool udd_ep_clear_halt(udd_ep_id_t ep) +{ + udd_ep_job_t *ptr_job; + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + + if (USB_DEVICE_MAX_EP < ep_num) { + return false; + } + ptr_job = udd_ep_get_job(ep); + + usb_device_endpoint_clear_halt(&usb_device, ep); + + /* If a job is register on clear halt action then execute callback */ + if (ptr_job->busy == true) { + ptr_job->busy = false; + ptr_job->call_nohalt(); + } + + return true; +} + +bool udd_ep_wait_stall_clear(udd_ep_id_t ep, udd_callback_halt_cleared_t callback) +{ + udd_ep_id_t ep_num; + udd_ep_job_t *ptr_job; + + ep_num = ep & USB_EP_ADDR_MASK; + if (USB_DEVICE_MAX_EP < ep_num) { + return false; + } + + ptr_job = udd_ep_get_job(ep); + if (ptr_job->busy == true) { + return false; /* Job already on going */ + } + + /* Wait clear halt endpoint */ + if (usb_device_endpoint_is_halted(&usb_device, ep)) { + /* Endpoint halted then registers the callback */ + ptr_job->busy = true; + ptr_job->call_nohalt = callback; + return true; + } else if (usb_device_endpoint_is_configured(&usb_device, ep)) { + callback(); /* Endpoint not halted then call directly callback */ + return true; + } else { + return false; + } +} + +/** + * \brief Control Endpoint stall sending data + */ +static void udd_ctrl_stall_data(void) +{ + udd_ep_control_state = UDD_EPCTRL_STALL_REQ; + + usb_device_endpoint_set_halt(&usb_device, USB_EP_DIR_IN); + usb_device_endpoint_clear_halt(&usb_device, USB_EP_DIR_OUT); +} + +bool udd_ep_run(udd_ep_id_t ep, bool b_shortpacket, uint8_t * buf, iram_size_t buf_size, udd_callback_trans_t callback) +{ + udd_ep_id_t ep_num; + udd_ep_job_t *ptr_job; + irqflags_t flags; + + ep_num = ep & USB_EP_ADDR_MASK; + + if ((USB_DEVICE_MAX_EP < ep_num) || (udd_ep_is_halted(ep))) { + return false; + } + + ptr_job = udd_ep_get_job(ep); + + flags = cpu_irq_save(); + if (ptr_job->busy == true) { + cpu_irq_restore(flags); + return false; /* Job already on going */ + } + ptr_job->busy = true; + cpu_irq_restore(flags); + + /* No job running, set up a new one */ + ptr_job->buf = buf; + ptr_job->buf_size = buf_size; + ptr_job->nb_trans = 0; + ptr_job->call_trans = callback; + ptr_job->b_shortpacket = b_shortpacket; + ptr_job->b_use_out_cache_buffer = false; + + /* Initialize value to simulate a empty transfer */ + uint16_t next_trans; + + if (ep & USB_EP_DIR_IN) { + if (0 != ptr_job->buf_size) { + next_trans = ptr_job->buf_size; + if (UDD_ENDPOINT_MAX_TRANS < next_trans) { + next_trans = UDD_ENDPOINT_MAX_TRANS - + (UDD_ENDPOINT_MAX_TRANS % ptr_job->ep_size); + } + ptr_job->b_shortpacket = ptr_job->b_shortpacket && + (0 == (next_trans % ptr_job->ep_size)); + } else if (true == ptr_job->b_shortpacket) { + ptr_job->b_shortpacket = false; /* avoid to send zero length packet again */ + next_trans = 0; + } else { + ptr_job->busy = false; + if (NULL != ptr_job->call_trans) { + ptr_job->call_trans(UDD_EP_TRANSFER_OK, 0, ep); + } + return true; + } + return (STATUS_OK == + usb_device_endpoint_write_buffer_job(&usb_device, + ep_num,&ptr_job->buf[0],next_trans)); + } else { + if (0 != ptr_job->buf_size) { + next_trans = ptr_job->buf_size; + if (UDD_ENDPOINT_MAX_TRANS < next_trans) { + /* The USB hardware support a maximum transfer size + * of UDD_ENDPOINT_MAX_TRANS Bytes */ + next_trans = UDD_ENDPOINT_MAX_TRANS - + (UDD_ENDPOINT_MAX_TRANS % ptr_job->ep_size); + } else { + next_trans -= next_trans % ptr_job->ep_size; + } + if (next_trans < ptr_job->ep_size) { + ptr_job->b_use_out_cache_buffer = true; + return (STATUS_OK == + usb_device_endpoint_read_buffer_job(&usb_device, ep_num, + udd_ep_out_cache_buffer[ep_num - 1], + ptr_job->ep_size)); + } else { + return (STATUS_OK == + usb_device_endpoint_read_buffer_job(&usb_device, ep_num, + &ptr_job->buf[0],next_trans)); + } + } else { + ptr_job->busy = false; + if (NULL != ptr_job->call_trans) { + ptr_job->call_trans(UDD_EP_TRANSFER_OK, 0, ep); + } + return true; + } + } +} + +void udd_set_address(uint8_t address) +{ + usb_device_set_address(&usb_device,address); +} + +uint8_t udd_getaddress(void) +{ + return usb_device_get_address(&usb_device); +} + +void udd_send_remotewakeup(void) +{ + uint32_t try = 5; + udd_wait_clock_ready(); + udd_sleep_mode(UDD_STATE_IDLE); + while(2 != usb_get_state_machine_status(&usb_device) && try --) { + usb_device_send_remote_wake_up(&usb_device); + } +} + +void udd_set_setup_payload( uint8_t *payload, uint16_t payload_size ) +{ + udd_g_ctrlreq.payload = payload; + udd_g_ctrlreq.payload_size = payload_size; +} + +/** + * \brief Control Endpoint translate the data in buffer into Device Request Struct + */ +static void udd_ctrl_fetch_ram(void) +{ + udd_g_ctrlreq.req.bmRequestType = udd_ctrl_buffer[0]; + udd_g_ctrlreq.req.bRequest = udd_ctrl_buffer[1]; + udd_g_ctrlreq.req.wValue = ((uint16_t)(udd_ctrl_buffer[3]) << 8) + udd_ctrl_buffer[2]; + udd_g_ctrlreq.req.wIndex = ((uint16_t)(udd_ctrl_buffer[5]) << 8) + udd_ctrl_buffer[4]; + udd_g_ctrlreq.req.wLength = ((uint16_t)(udd_ctrl_buffer[7]) << 8) + udd_ctrl_buffer[6]; +} + +/** + * \brief Control Endpoint send out zero length packet + */ +static void udd_ctrl_send_zlp_in(void) +{ + udd_ep_control_state = UDD_EPCTRL_HANDSHAKE_WAIT_IN_ZLP; + usb_device_endpoint_setup_buffer_job(&usb_device,udd_ctrl_buffer); + usb_device_endpoint_write_buffer_job(&usb_device,0,udd_g_ctrlreq.payload,0); +} + +/** + * \brief Process control endpoint IN transaction + */ +static void udd_ctrl_in_sent(void) +{ + static bool b_shortpacket = false; + uint16_t nb_remain; + + nb_remain = udd_g_ctrlreq.payload_size - udd_ctrl_payload_nb_trans; + + if (0 == nb_remain) { + /* All content of current buffer payload are sent Update number of total data sending by previous payload buffer */ + udd_ctrl_prev_payload_nb_trans += udd_ctrl_payload_nb_trans; + if ((udd_g_ctrlreq.req.wLength == udd_ctrl_prev_payload_nb_trans) || b_shortpacket) { + /* All data requested are transferred or a short packet has been sent, then it is the end of data phase. + * Generate an OUT ZLP for handshake phase */ + udd_ep_control_state = UDD_EPCTRL_HANDSHAKE_WAIT_OUT_ZLP; + usb_device_endpoint_setup_buffer_job(&usb_device,udd_ctrl_buffer); + return; + } + /* Need of new buffer because the data phase is not complete */ + if ((!udd_g_ctrlreq.over_under_run) || (!udd_g_ctrlreq.over_under_run())) { + /* Under run then send zlp on IN + * Here nb_remain=0, this allows to send a IN ZLP */ + } else { + /* A new payload buffer is given */ + udd_ctrl_payload_nb_trans = 0; + nb_remain = udd_g_ctrlreq.payload_size; + } + } + + /* Continue transfer and send next data */ + if (nb_remain >= USB_DEVICE_EP_CTRL_SIZE) { + nb_remain = USB_DEVICE_EP_CTRL_SIZE; + b_shortpacket = false; + } else { + b_shortpacket = true; + } + + /* Link payload buffer directly on USB hardware */ + usb_device_endpoint_write_buffer_job(&usb_device,0,udd_g_ctrlreq.payload + udd_ctrl_payload_nb_trans,nb_remain); + + udd_ctrl_payload_nb_trans += nb_remain; +} + +/** + * \brief Process control endpoint OUT transaction + * \param[in] pointer Pointer to the endpoint transfer status parameter struct from driver layer. + */ +static void udd_ctrl_out_received(void* pointer) +{ + struct usb_endpoint_callback_parameter *ep_callback_para = (struct usb_endpoint_callback_parameter*)pointer; + + uint16_t nb_data; + nb_data = ep_callback_para->received_bytes; /* Read data received during OUT phase */ + + if (udd_g_ctrlreq.payload_size < (udd_ctrl_payload_nb_trans + nb_data)) { + /* Payload buffer too small */ + nb_data = udd_g_ctrlreq.payload_size - udd_ctrl_payload_nb_trans; + } + + memcpy((uint8_t *) (udd_g_ctrlreq.payload + udd_ctrl_payload_nb_trans), udd_ctrl_buffer, nb_data); + udd_ctrl_payload_nb_trans += nb_data; + + if ((USB_DEVICE_EP_CTRL_SIZE != nb_data) || \ + (udd_g_ctrlreq.req.wLength <= (udd_ctrl_prev_payload_nb_trans + udd_ctrl_payload_nb_trans))) { + /* End of reception because it is a short packet + * or all data are transferred */ + + /* Before send ZLP, call intermediate callback + * in case of data receive generate a stall */ + udd_g_ctrlreq.payload_size = udd_ctrl_payload_nb_trans; + if (NULL != udd_g_ctrlreq.over_under_run) { + if (!udd_g_ctrlreq.over_under_run()) { + /* Stall ZLP */ + udd_ep_control_state = UDD_EPCTRL_STALL_REQ; + /* Stall all packets on IN & OUT control endpoint */ + udd_ep_set_halt(0); + /* Ack reception of OUT to replace NAK by a STALL */ + return; + } + } + /* Send IN ZLP to ACK setup request */ + udd_ctrl_send_zlp_in(); + return; + } + + if (udd_g_ctrlreq.payload_size == udd_ctrl_payload_nb_trans) { + /* Overrun then request a new payload buffer */ + if (!udd_g_ctrlreq.over_under_run) { + /* No callback available to request a new payload buffer + * Stall ZLP */ + udd_ep_control_state = UDD_EPCTRL_STALL_REQ; + /* Stall all packets on IN & OUT control endpoint */ + udd_ep_set_halt(0); + return; + } + if (!udd_g_ctrlreq.over_under_run()) { + /* No new payload buffer delivered + * Stall ZLP */ + udd_ep_control_state = UDD_EPCTRL_STALL_REQ; + /* Stall all packets on IN & OUT control endpoint */ + udd_ep_set_halt(0); + return; + } + /* New payload buffer available + * Update number of total data received */ + udd_ctrl_prev_payload_nb_trans += udd_ctrl_payload_nb_trans; + + /* Reinitialize reception on payload buffer */ + udd_ctrl_payload_nb_trans = 0; + } + usb_device_endpoint_read_buffer_job(&usb_device,0,udd_ctrl_buffer,USB_DEVICE_EP_CTRL_SIZE); +} + +/** + * \internal + * \brief Endpoint 0 (control) SETUP received callback + * \param[in] module_inst pointer to USB module instance + * \param[in] pointer Pointer to the endpoint transfer status parameter struct from driver layer. + */ +static void _usb_ep0_on_setup(struct usb_module *module_inst, void* pointer) +{ + struct usb_endpoint_callback_parameter *ep_callback_para = (struct usb_endpoint_callback_parameter*)pointer; + + if (UDD_EPCTRL_SETUP != udd_ep_control_state) { + if (NULL != udd_g_ctrlreq.callback) { + udd_g_ctrlreq.callback(); + } + udd_ep_control_state = UDD_EPCTRL_SETUP; + } + if ( 8 != ep_callback_para->received_bytes) { + udd_ctrl_stall_data(); + return; + } else { + udd_ctrl_fetch_ram(); + if (false == udc_process_setup()) { + udd_ctrl_stall_data(); + return; + } else if (Udd_setup_is_in()) { + udd_ctrl_prev_payload_nb_trans = 0; + udd_ctrl_payload_nb_trans = 0; + udd_ep_control_state = UDD_EPCTRL_DATA_IN; + usb_device_endpoint_read_buffer_job(&usb_device,0,udd_ctrl_buffer,USB_DEVICE_EP_CTRL_SIZE); + udd_ctrl_in_sent(); + } else { + if(0 == udd_g_ctrlreq.req.wLength) { + udd_ctrl_send_zlp_in(); + return; + } else { + udd_ctrl_prev_payload_nb_trans = 0; + udd_ctrl_payload_nb_trans = 0; + udd_ep_control_state = UDD_EPCTRL_DATA_OUT; + /* Initialize buffer size and enable OUT bank */ + usb_device_endpoint_read_buffer_job(&usb_device,0,udd_ctrl_buffer,USB_DEVICE_EP_CTRL_SIZE); + } + } + } +} + +/** + * \brief Control Endpoint Process when underflow condition has occurred + * \param[in] pointer Pointer to the endpoint transfer status parameter struct from driver layer. + */ +static void udd_ctrl_underflow(void* pointer) +{ + struct usb_endpoint_callback_parameter *ep_callback_para = (struct usb_endpoint_callback_parameter*)pointer; + + if (UDD_EPCTRL_DATA_OUT == udd_ep_control_state) { + /* Host want to stop OUT transaction + * then stop to wait OUT data phase and wait IN ZLP handshake */ + udd_ctrl_send_zlp_in(); + } else if (UDD_EPCTRL_HANDSHAKE_WAIT_OUT_ZLP == udd_ep_control_state) { + /* A OUT handshake is waiting by device, + * but host want extra IN data then stall extra IN data */ + usb_device_endpoint_set_halt(&usb_device, ep_callback_para->endpoint_address); + } +} + +/** + * \brief Control Endpoint Process when overflow condition has occurred + * \param[in] pointer Pointer to the endpoint transfer status parameter struct from driver layer. + */ +static void udd_ctrl_overflow(void* pointer) +{ + struct usb_endpoint_callback_parameter *ep_callback_para = (struct usb_endpoint_callback_parameter*)pointer; + + if (UDD_EPCTRL_DATA_IN == udd_ep_control_state) { + /* Host want to stop IN transaction + * then stop to wait IN data phase and wait OUT ZLP handshake */ + udd_ep_control_state = UDD_EPCTRL_HANDSHAKE_WAIT_OUT_ZLP; + } else if (UDD_EPCTRL_HANDSHAKE_WAIT_IN_ZLP == udd_ep_control_state) { + /* A IN handshake is waiting by device, + * but host want extra OUT data then stall extra OUT data and following status stage */ + usb_device_endpoint_set_halt(&usb_device, ep_callback_para->endpoint_address); + } +} + +/** + * \internal + * \brief Control endpoint transfer fail callback function + * \param[in] module_inst Pointer to USB module instance + * \param[in] pointer Pointer to the endpoint transfer status parameter struct from driver layer. + */ +static void _usb_ep0_on_tansfer_fail(struct usb_module *module_inst, void* pointer) +{ + struct usb_endpoint_callback_parameter *ep_callback_para = (struct usb_endpoint_callback_parameter*)pointer; + + if(ep_callback_para->endpoint_address & USB_EP_DIR_IN) { + udd_ctrl_underflow(pointer); + } else { + udd_ctrl_overflow(pointer); + } +} + +/** + * \internal + * \brief Control endpoint transfer complete callback function + * \param[in] module_inst Pointer to USB module instance + * \param[in] pointer Pointer to the endpoint transfer status parameter struct from driver layer. + */ +static void _usb_ep0_on_tansfer_ok(struct usb_module *module_inst, void * pointer) +{ + if (UDD_EPCTRL_DATA_OUT == udd_ep_control_state) { /* handshake Out for status stage */ + udd_ctrl_out_received(pointer); + } else if (UDD_EPCTRL_DATA_IN == udd_ep_control_state) { /* handshake In for status stage */ + udd_ctrl_in_sent(); + } else { + if (NULL != udd_g_ctrlreq.callback) { + udd_g_ctrlreq.callback(); + } + udd_ep_control_state = UDD_EPCTRL_SETUP; + } +} + +/** + * \brief Enable Control Endpoint + * \param[in] module_inst Pointer to USB module instance + */ +static void udd_ctrl_ep_enable(struct usb_module *module_inst) +{ + /* USB Device Endpoint0 Configuration */ + struct usb_device_endpoint_config config_ep0; + + usb_device_endpoint_get_config_defaults(&config_ep0); + config_ep0.ep_size = (enum usb_endpoint_size)(32 - clz(((uint32_t)Min(Max(USB_DEVICE_EP_CTRL_SIZE, 8), 1024) << 1) - 1) - 1 - 3); + usb_device_endpoint_set_config(module_inst,&config_ep0); + + usb_device_endpoint_setup_buffer_job(module_inst,udd_ctrl_buffer); + + usb_device_endpoint_register_callback(module_inst,0,USB_DEVICE_ENDPOINT_CALLBACK_RXSTP, _usb_ep0_on_setup ); + usb_device_endpoint_register_callback(module_inst,0,USB_DEVICE_ENDPOINT_CALLBACK_TRCPT,_usb_ep0_on_tansfer_ok ); + usb_device_endpoint_register_callback(module_inst,0,USB_DEVICE_ENDPOINT_CALLBACK_TRFAIL,_usb_ep0_on_tansfer_fail ); + usb_device_endpoint_enable_callback(module_inst,0,USB_DEVICE_ENDPOINT_CALLBACK_RXSTP); + usb_device_endpoint_enable_callback(module_inst,0,USB_DEVICE_ENDPOINT_CALLBACK_TRCPT); + usb_device_endpoint_enable_callback(module_inst,0,USB_DEVICE_ENDPOINT_CALLBACK_TRFAIL); + +#ifdef USB_DEVICE_LPM_SUPPORT + // Enable LPM feature + usb_device_set_lpm_mode(module_inst, USB_DEVICE_LPM_ACK); +#endif + + udd_ep_control_state = UDD_EPCTRL_SETUP; +} + +/** + * \internal + * \brief Control endpoint Suspend callback function + * \param[in] module_inst Pointer to USB module instance + * \param[in] pointer Pointer to the callback parameter from driver layer. + */ +static void _usb_on_suspend(struct usb_module *module_inst, void *pointer) +{ + usb_device_disable_callback(&usb_device, USB_DEVICE_CALLBACK_SUSPEND); + usb_device_enable_callback(&usb_device, USB_DEVICE_CALLBACK_WAKEUP); + udd_sleep_mode(UDD_STATE_SUSPEND); +#ifdef UDC_SUSPEND_EVENT + UDC_SUSPEND_EVENT(); +#endif +} + +#ifdef USB_DEVICE_LPM_SUPPORT +static void _usb_device_lpm_suspend(struct usb_module *module_inst, void *pointer) +{ + dbg_print("LPM_SUSP\n"); + + uint32_t *lpm_wakeup_enable; + lpm_wakeup_enable = (uint32_t *)pointer; + + usb_device_disable_callback(&usb_device, USB_DEVICE_CALLBACK_LPMSUSP); + usb_device_disable_callback(&usb_device, USB_DEVICE_CALLBACK_SUSPEND); + usb_device_enable_callback(&usb_device, USB_DEVICE_CALLBACK_WAKEUP); + +//#warning Here the sleep mode must be choose to have a DFLL startup time < bmAttribut.BESL + udd_sleep_mode(UDD_STATE_SUSPEND_LPM); // Enter in LPM SUSPEND mode + if ((*lpm_wakeup_enable)) { + UDC_REMOTEWAKEUP_LPM_ENABLE(); + } + if (!(*lpm_wakeup_enable)) { + UDC_REMOTEWAKEUP_LPM_DISABLE(); + } + UDC_SUSPEND_LPM_EVENT(); +} +#endif + +/** + * \internal + * \brief Control endpoint SOF callback function + * \param[in] module_inst Pointer to USB module instance + * \param[in] pointer Pointer to the callback parameter from driver layer. + */ +static void _usb_on_sof_notify(struct usb_module *module_inst, void *pointer) +{ + udc_sof_notify(); +#ifdef UDC_SOF_EVENT + UDC_SOF_EVENT(); +#endif +} + +/** + * \internal + * \brief Control endpoint Reset callback function + * \param[in] module_inst Pointer to USB module instance + * \param[in] pointer Pointer to the callback parameter from driver layer. + */ +static void _usb_on_bus_reset(struct usb_module *module_inst, void *pointer) +{ + // Reset USB Device Stack Core + udc_reset(); + usb_device_set_address(module_inst,0); + udd_ctrl_ep_enable(module_inst); +} + +/** + * \internal + * \brief Control endpoint Wakeup callback function + * \param[in] module_inst Pointer to USB module instance + * \param[in] pointer Pointer to the callback parameter from driver layer. + */ +static void _usb_on_wakeup(struct usb_module *module_inst, void *pointer) +{ + udd_wait_clock_ready(); + + usb_device_disable_callback(&usb_device, USB_DEVICE_CALLBACK_WAKEUP); + usb_device_enable_callback(&usb_device, USB_DEVICE_CALLBACK_SUSPEND); +#ifdef USB_DEVICE_LPM_SUPPORT + usb_device_register_callback(&usb_device, USB_DEVICE_CALLBACK_LPMSUSP, _usb_device_lpm_suspend); + usb_device_enable_callback(&usb_device, USB_DEVICE_CALLBACK_LPMSUSP); +#endif + udd_sleep_mode(UDD_STATE_IDLE); +#ifdef UDC_RESUME_EVENT + UDC_RESUME_EVENT(); +#endif +} + +void udd_detach(void) +{ + usb_device_detach(&usb_device); + udd_sleep_mode(UDD_STATE_SUSPEND); +} + +void udd_attach(void) +{ + udd_sleep_mode(UDD_STATE_IDLE); + usb_device_attach(&usb_device); + + usb_device_register_callback(&usb_device, USB_DEVICE_CALLBACK_SUSPEND, _usb_on_suspend); + usb_device_register_callback(&usb_device, USB_DEVICE_CALLBACK_SOF, _usb_on_sof_notify); + usb_device_register_callback(&usb_device, USB_DEVICE_CALLBACK_RESET, _usb_on_bus_reset); + usb_device_register_callback(&usb_device, USB_DEVICE_CALLBACK_WAKEUP, _usb_on_wakeup); + + usb_device_enable_callback(&usb_device, USB_DEVICE_CALLBACK_SUSPEND); + usb_device_enable_callback(&usb_device, USB_DEVICE_CALLBACK_SOF); + usb_device_enable_callback(&usb_device, USB_DEVICE_CALLBACK_RESET); + usb_device_enable_callback(&usb_device, USB_DEVICE_CALLBACK_WAKEUP); +#ifdef USB_DEVICE_LPM_SUPPORT + usb_device_register_callback(&usb_device, USB_DEVICE_CALLBACK_LPMSUSP, _usb_device_lpm_suspend); + usb_device_enable_callback(&usb_device, USB_DEVICE_CALLBACK_LPMSUSP); +#endif +} + +#if USB_VBUS_EIC +/** + * \name USB VBUS PAD management + * + * @{ + */ + + /** Check if USB VBus is available */ +# define is_usb_vbus_high() port_pin_get_input_level(USB_VBUS_PIN) + +/** + * \internal + * \brief USB VBUS pin change handler + */ +static void _uhd_vbus_handler(void) +{ + extint_chan_disable_callback(USB_VBUS_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); +# ifndef USB_DEVICE_ATTACH_AUTO_DISABLE + if (is_usb_vbus_high()) { + udd_attach(); + } else { + udd_detach(); + } +# endif +# ifdef UDC_VBUS_EVENT + UDC_VBUS_EVENT(is_usb_vbus_high()); +# endif + extint_chan_enable_callback(USB_VBUS_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); +} + +/** + * \internal + * \brief USB VBUS pin configuration + */ +static void _usb_vbus_config(void) +{ + + /* Initialize EIC for vbus checking */ + struct extint_chan_conf eint_chan_conf; + extint_chan_get_config_defaults(&eint_chan_conf); + + eint_chan_conf.gpio_pin = USB_VBUS_PIN; + eint_chan_conf.gpio_pin_mux = USB_VBUS_EIC_MUX; + eint_chan_conf.gpio_pin_pull = EXTINT_PULL_NONE; + eint_chan_conf.detection_criteria = EXTINT_DETECT_BOTH; + eint_chan_conf.filter_input_signal = true; + + extint_chan_disable_callback(USB_VBUS_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); + extint_chan_set_config(USB_VBUS_EIC_LINE, &eint_chan_conf); + extint_register_callback(_uhd_vbus_handler, + USB_VBUS_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); + extint_chan_enable_callback(USB_VBUS_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); +} +/** @} */ +#endif + +bool udd_include_vbus_monitoring(void) +{ +#if USB_VBUS_EIC + return true; +#else + return false; +#endif +} + +void udd_enable(void) +{ + irqflags_t flags; + + /* To avoid USB interrupt before end of initialization */ + flags = cpu_irq_save(); + +#if USB_ID_EIC + if (usb_dual_enable()) { + /* The current mode has been started by otg_dual_enable() */ + cpu_irq_restore(flags); + return; + } +#endif + struct usb_config config_usb; + + /* USB Module configuration */ + usb_get_config_defaults(&config_usb); + config_usb.source_generator = UDD_CLOCK_GEN; + usb_init(&usb_device, USB, &config_usb); + + /* USB Module Enable */ + usb_enable(&usb_device); + + /* Check clock after enable module, request the clock */ + udd_wait_clock_ready(); + + udd_sleep_mode(UDD_STATE_SUSPEND); + +#if USB_VBUS_EIC + _usb_vbus_config(); + if (is_usb_vbus_high()) { + /* USB Attach */ + _uhd_vbus_handler(); + } +#else + // No VBus detect, assume always high +# ifndef USB_DEVICE_ATTACH_AUTO_DISABLE + udd_attach(); +# endif +#endif + + cpu_irq_restore(flags); +} + +void udd_disable(void) +{ + irqflags_t flags; + + udd_detach(); + + udd_sleep_mode(UDD_STATE_OFF); + + flags = cpu_irq_save(); + usb_dual_disable(); + cpu_irq_restore(flags); +} +/** @} */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/usb/stack_interface/usb_dual.c b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/usb/stack_interface/usb_dual.c new file mode 100644 index 0000000..89e5aff --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/usb/stack_interface/usb_dual.c @@ -0,0 +1,175 @@ +/** + * \file + * + * \brief SAM USB Dual Role driver file. + * + * Copyright (C) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include +#include "usb_dual.h" + +#ifndef UDD_ENABLE +# define udc_start() +# define udc_stop() +#else +#include +#endif + +#ifndef UHD_ENABLE +# define uhc_start(void) +# define uhc_stop(b_id_stop) +#else +#include +#endif + +/* State of USB dual role initialization */ +static bool _initialized = false; + +#define _usb_is_id_device() port_pin_get_input_level(USB_ID_PIN) + +#if USB_ID_EIC +static void usb_id_handler(void); + +/** + * \name USB ID PAD management + * + * @{ + */ + +/** + * USB ID pin configuration + */ +static void usb_id_config(void) +{ + struct extint_chan_conf eint_chan_conf; + extint_chan_get_config_defaults(&eint_chan_conf); + + eint_chan_conf.gpio_pin = USB_ID_PIN; + eint_chan_conf.gpio_pin_mux = USB_ID_EIC_MUX; + eint_chan_conf.detection_criteria = EXTINT_DETECT_BOTH; + eint_chan_conf.filter_input_signal = true; + + extint_chan_disable_callback(USB_ID_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); + extint_chan_set_config(USB_ID_EIC_LINE, &eint_chan_conf); + extint_register_callback(usb_id_handler, + USB_ID_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); + extint_chan_enable_callback(USB_ID_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); +} + +/** + * USB ID pin change handler + */ +static void usb_id_handler(void) +{ + extint_chan_disable_callback(USB_ID_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); + if (_usb_is_id_device()) { + uhc_stop(false); + UHC_MODE_CHANGE(false); + udc_start(); + } else { + udc_stop(); + UHC_MODE_CHANGE(true); + uhc_start(); + } + extint_chan_enable_callback(USB_ID_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); +} +#endif +/** @} */ + +/** + * \brief Initialize the USB peripheral and set right role according to ID pin + * + * \return \c true if the ID pin management has been started, otherwise \c false. + */ +bool usb_dual_enable(void) +{ + if (_initialized) { + return false; // Dual role already initialized + } + +#if USB_ID_EIC + _initialized = true; + + struct port_config pin_conf; + port_get_config_defaults(&pin_conf); + + /* Set USB ID Pin as inputs */ + pin_conf.direction = PORT_PIN_DIR_INPUT; + pin_conf.input_pull = PORT_PIN_PULL_UP; + port_pin_set_config(USB_ID_PIN, &pin_conf); + + usb_id_config(); + if (_usb_is_id_device()) { + UHC_MODE_CHANGE(false); + udc_start(); + } else { + UHC_MODE_CHANGE(true); + uhc_start(); + } + + /** + * End of host or device startup, + * the current mode selected is already started now + */ + return true; // ID pin management has been enabled +#else + return false; // ID pin management has not been enabled +#endif +} + +/** + * \brief Deinitialize the dual role driver + */ +void usb_dual_disable(void) +{ + if (!_initialized) { + return; // Dual role not initialized + } + _initialized = false; + +#if USB_ID_EIC + extint_chan_disable_callback(USB_ID_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); +#endif +} + diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/usb/stack_interface/usb_dual.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/usb/stack_interface/usb_dual.h new file mode 100644 index 0000000..ced2b97 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/usb/stack_interface/usb_dual.h @@ -0,0 +1,110 @@ +/** + * \file + * + * \brief SAM USB Dual Role driver header file. + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _USB_DUAL_H_ +#define _USB_DUAL_H_ + +#include "compiler.h" +#include "preprocessor.h" + +/* Get USB pads pins configuration in board configuration */ +#include "conf_board.h" +#include "board.h" +//#include +#include "port.h" + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \ingroup usb_group + * \defgroup usb_dual_group USB dual role driver + * USB low-level driver for dual role features + * + * @{ + */ + +bool usb_dual_enable(void); +void usb_dual_disable(void); + +/** + * @name USB ID pin management + * + * The ID pin come from the USB connector (A and B receptable) and + * allows to select the USB mode between host or device. + * The ID pin can be managed through EIC pin. + * This feature is optional, and it is enabled if USB_ID_PIN + * is defined in board.h and CONF_BOARD_USB_ID_DETECT defined in + * conf_board.h. +* +* @{ +*/ +#ifdef BOOTLOADER_USES_HOST +#define USB_ID_DETECT (defined(CONF_BOARD_USB_ID_DETECT)) +#define USB_ID_EIC (defined(USB_ID_PIN) && USB_ID_DETECT) +/** @} */ + +/** + * @name USB Vbus management + * + * The VBus line can be monitored through a EIC pin and + * a basic resistor voltage divider. + * This feature is optional, and it is enabled if USB_VBUS_PIN + * is defined in board.h and CONF_BOARD_USB_VBUS_DETECT defined in + * conf_board.h. + * + * @{ + */ +#define USB_VBUS_DETECT (defined(CONF_BOARD_USB_VBUS_DETECT)) +#define USB_VBUS_EIC (defined(USB_VBUS_PIN) && USB_VBUS_DETECT) +#endif //BOOTLOADER_USES_HOST +/** @} */ + +/** @} */ + +#ifdef __cplusplus +} +#endif + +#endif // _USB_DUAL_H_ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/usb/usb.c b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/usb/usb.c new file mode 100644 index 0000000..f98d674 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/usb/usb.c @@ -0,0 +1,2066 @@ +/** + * \file + * + * \brief SAM USB Driver. + * + * Copyright (C) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include +#include "usb.h" + +/** Fields definition from a LPM TOKEN */ +#define USB_LPM_ATTRIBUT_BLINKSTATE_MASK (0xF << 0) +#define USB_LPM_ATTRIBUT_BESL_MASK (0xF << 4) +#define USB_LPM_ATTRIBUT_REMOTEWAKE_MASK (1 << 8) +#define USB_LPM_ATTRIBUT_BLINKSTATE(value) ((value & 0xF) << 0) +#define USB_LPM_ATTRIBUT_BESL(value) ((value & 0xF) << 4) +#define USB_LPM_ATTRIBUT_REMOTEWAKE(value) ((value & 1) << 8) +#define USB_LPM_ATTRIBUT_BLINKSTATE_L1 USB_LPM_ATTRIBUT_BLINKSTATE(1) + +/** + * \brief Mask selecting the index part of an endpoint address + */ +#define USB_EP_ADDR_MASK 0x0f + +/** + * \brief Endpoint transfer direction is IN + */ +#define USB_EP_DIR_IN 0x80 + +/** + * \brief Endpoint transfer direction is OUT + */ +#define USB_EP_DIR_OUT 0x00 + +#if SAMD21 || SAMD11 +/** + * \name Macros for USB device those are not realized in head file + * + * @{ + */ +#define USB_DEVICE_EPINTENCLR_TRCPT0 USB_DEVICE_EPINTENCLR_TRCPT(1) +#define USB_DEVICE_EPINTENCLR_TRCPT1 USB_DEVICE_EPINTENCLR_TRCPT(2) +#define USB_DEVICE_EPINTENCLR_TRFAIL0 USB_DEVICE_EPINTENCLR_TRFAIL(1) +#define USB_DEVICE_EPINTENCLR_TRFAIL1 USB_DEVICE_EPINTENCLR_TRFAIL(2) +#define USB_DEVICE_EPINTENCLR_STALL0 USB_DEVICE_EPINTENCLR_STALL(1) +#define USB_DEVICE_EPINTENCLR_STALL1 USB_DEVICE_EPINTENCLR_STALL(2) + +#define USB_DEVICE_EPINTENSET_TRCPT0 USB_DEVICE_EPINTENSET_TRCPT(1) +#define USB_DEVICE_EPINTENSET_TRCPT1 USB_DEVICE_EPINTENSET_TRCPT(2) +#define USB_DEVICE_EPINTENSET_TRFAIL0 USB_DEVICE_EPINTENSET_TRFAIL(1) +#define USB_DEVICE_EPINTENSET_TRFAIL1 USB_DEVICE_EPINTENSET_TRFAIL(2) +#define USB_DEVICE_EPINTENSET_STALL0 USB_DEVICE_EPINTENSET_STALL(1) +#define USB_DEVICE_EPINTENSET_STALL1 USB_DEVICE_EPINTENSET_STALL(2) + +#define USB_DEVICE_EPINTFLAG_TRCPT0 USB_DEVICE_EPINTFLAG_TRCPT(1) +#define USB_DEVICE_EPINTFLAG_TRCPT1 USB_DEVICE_EPINTFLAG_TRCPT(2) +#define USB_DEVICE_EPINTFLAG_TRFAIL0 USB_DEVICE_EPINTFLAG_TRFAIL(1) +#define USB_DEVICE_EPINTFLAG_TRFAIL1 USB_DEVICE_EPINTFLAG_TRFAIL(2) +#define USB_DEVICE_EPINTFLAG_STALL0 USB_DEVICE_EPINTFLAG_STALL(1) +#define USB_DEVICE_EPINTFLAG_STALL1 USB_DEVICE_EPINTFLAG_STALL(2) + +#define USB_DEVICE_EPSTATUSSET_STALLRQ0 USB_DEVICE_EPSTATUSSET_STALLRQ(1) +#define USB_DEVICE_EPSTATUSSET_STALLRQ1 USB_DEVICE_EPSTATUSSET_STALLRQ(2) +#define USB_DEVICE_EPSTATUSCLR_STALLRQ0 USB_DEVICE_EPSTATUSCLR_STALLRQ(1) +#define USB_DEVICE_EPSTATUSCLR_STALLRQ1 USB_DEVICE_EPSTATUSCLR_STALLRQ(2) +/** @} */ +#endif + +/** + * \name USB SRAM data containing pipe descriptor table + * The content of the USB SRAM can be : + * - modified by USB hardware interface to update pipe status. + * Thereby, it is read by software. + * - modified by USB software to control pipe. + * Thereby, it is read by hardware. + * This data section is volatile. + * + * @{ + */ +COMPILER_PACK_SET(1) +COMPILER_WORD_ALIGNED +union { + UsbDeviceDescriptor usb_endpoint_table[USB_EPT_NUM]; + UsbHostDescriptor usb_pipe_table[USB_PIPE_NUM]; +} usb_descriptor_table; +COMPILER_PACK_RESET() +/** @} */ + +/** + * \brief Local USB module instance + */ +static struct usb_module *_usb_instances; + +#if !SAMD11 +/** + * \brief Host pipe callback structure variable + */ +static struct usb_pipe_callback_parameter pipe_callback_para; +#endif + +/* Device LPM callback variable */ +static uint32_t device_callback_lpm_wakeup_enable; + +/** + * \brief Device endpoint callback parameter variable, used to transfer info to UDD wrapper layer + */ +static struct usb_endpoint_callback_parameter ep_callback_para; + +/** + * \internal USB Device IRQ Mask Bits Map + */ +static const uint16_t _usb_device_irq_bits[USB_DEVICE_CALLBACK_N] = { + USB_DEVICE_INTFLAG_SOF, + USB_DEVICE_INTFLAG_EORST, + USB_DEVICE_INTFLAG_WAKEUP | USB_DEVICE_INTFLAG_EORSM | USB_DEVICE_INTFLAG_UPRSM, + USB_DEVICE_INTFLAG_RAMACER, + USB_DEVICE_INTFLAG_SUSPEND, + USB_DEVICE_INTFLAG_LPMNYET, + USB_DEVICE_INTFLAG_LPMSUSP, +}; + +/** + * \internal USB Device IRQ Mask Bits Map + */ +static const uint8_t _usb_endpoint_irq_bits[USB_DEVICE_EP_CALLBACK_N] = { + USB_DEVICE_EPINTFLAG_TRCPT_Msk, + USB_DEVICE_EPINTFLAG_TRFAIL_Msk, + USB_DEVICE_EPINTFLAG_RXSTP, + USB_DEVICE_EPINTFLAG_STALL_Msk +}; + +#if !SAMD11 +/** + * \brief Bit mask for pipe job busy status + */ +uint32_t host_pipe_job_busy_status = 0; + +/** + * \brief Registers a USB host callback + * + * Registers a callback function which is implemented by the user. + * + * \note The callback must be enabled by \ref usb_host_enable_callback, + * in order for the interrupt handler to call it when the conditions for the + * callback type is met. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] callback_type Callback type given by an enum + * \param[in] callback_func Pointer to callback function + * + * \return Status of the registration operation. + * \retval STATUS_OK The callback was registered successfully. + */ +enum status_code usb_host_register_callback(struct usb_module *module_inst, + enum usb_host_callback callback_type, + usb_host_callback_t callback_func) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(callback_func); + + /* Register callback function */ + module_inst->host_callback[callback_type] = callback_func; + + /* Set the bit corresponding to the callback_type */ + module_inst->host_registered_callback_mask |= (1 << callback_type); + + return STATUS_OK; +} + +/** + * \brief Unregisters a USB host callback + * + * Unregisters an asynchronous callback implemented by the user. Removing it + * from the internal callback registration table. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the de-registration operation. + * \retval STATUS_OK The callback was unregistered successfully. + */ +enum status_code usb_host_unregister_callback(struct usb_module *module_inst, + enum usb_host_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + + /* Unregister callback function */ + module_inst->host_callback[callback_type] = NULL; + + /* Clear the bit corresponding to the callback_type */ + module_inst->host_registered_callback_mask &= ~(1 << callback_type); + + return STATUS_OK; +} + +/** + * \brief Enables USB host callback generation for a given type. + * + * Enables asynchronous callbacks for a given logical type. + * This must be called before USB host generate callback events. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the callback enable operation. + * \retval STATUS_OK The callback was enabled successfully. + */ +enum status_code usb_host_enable_callback(struct usb_module *module_inst, + enum usb_host_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + /* Enable callback */ + module_inst->host_enabled_callback_mask |= (1 << callback_type); + + if (callback_type == USB_HOST_CALLBACK_SOF) { + module_inst->hw->HOST.INTENSET.reg = USB_HOST_INTENSET_HSOF; + } + if (callback_type == USB_HOST_CALLBACK_RESET) { + module_inst->hw->HOST.INTENSET.reg = USB_HOST_INTENSET_RST; + } + if (callback_type == USB_HOST_CALLBACK_WAKEUP) { + module_inst->hw->HOST.INTENSET.reg = USB_HOST_INTENSET_WAKEUP; + } + if (callback_type == USB_HOST_CALLBACK_DNRSM) { + module_inst->hw->HOST.INTENSET.reg = USB_HOST_INTENSET_DNRSM; + } + if (callback_type == USB_HOST_CALLBACK_UPRSM) { + module_inst->hw->HOST.INTENSET.reg = USB_HOST_INTENSET_UPRSM; + } + if (callback_type == USB_HOST_CALLBACK_RAMACER) { + module_inst->hw->HOST.INTENSET.reg = USB_HOST_INTENSET_RAMACER; + } + if (callback_type == USB_HOST_CALLBACK_CONNECT) { + module_inst->hw->HOST.INTENSET.reg = USB_HOST_INTENSET_DCONN; + } + if (callback_type == USB_HOST_CALLBACK_DISCONNECT) { + module_inst->hw->HOST.INTENSET.reg = USB_HOST_INTENSET_DDISC; + } + + return STATUS_OK; +} + +/** + * \brief Disables USB host callback generation for a given type. + * + * Disables asynchronous callbacks for a given logical type. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the callback disable operation. + * \retval STATUS_OK The callback was disabled successfully. + */ +enum status_code usb_host_disable_callback(struct usb_module *module_inst, + enum usb_host_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + /* Disable callback */ + module_inst->host_enabled_callback_mask &= ~(1 << callback_type); + + if (callback_type == USB_HOST_CALLBACK_SOF) { + module_inst->hw->HOST.INTENCLR.reg = USB_HOST_INTENCLR_HSOF; + } + if (callback_type == USB_HOST_CALLBACK_RESET) { + module_inst->hw->HOST.INTENCLR.reg = USB_HOST_INTENCLR_RST; + } + if (callback_type == USB_HOST_CALLBACK_WAKEUP) { + module_inst->hw->HOST.INTENCLR.reg = USB_HOST_INTENCLR_WAKEUP; + } + if (callback_type == USB_HOST_CALLBACK_DNRSM) { + module_inst->hw->HOST.INTENCLR.reg = USB_HOST_INTENCLR_DNRSM; + } + if (callback_type == USB_HOST_CALLBACK_UPRSM) { + module_inst->hw->HOST.INTENCLR.reg = USB_HOST_INTENCLR_UPRSM; + } + if (callback_type == USB_HOST_CALLBACK_RAMACER) { + module_inst->hw->HOST.INTENCLR.reg = USB_HOST_INTENCLR_RAMACER; + } + if (callback_type == USB_HOST_CALLBACK_CONNECT) { + module_inst->hw->HOST.INTENCLR.reg = USB_HOST_INTENCLR_DCONN; + } + if (callback_type == USB_HOST_CALLBACK_DISCONNECT) { + module_inst->hw->HOST.INTENCLR.reg = USB_HOST_INTENCLR_DDISC; + } + + return STATUS_OK; +} + +/** + * \brief Initializes an USB host pipe configuration structure to defaults. + * + * Initializes a given USB host pipe configuration structure to a + * set of known default values. This function should be called on all new + * instances of these configuration structures before being modified by the + * user application. + * + * The default configuration is as follows: + * \li device address is 0 + * \li endpoint address is 0 + * \li pipe type is control + * \li interval is 0 + * \li pipe size is 8 + * + * \param[out] ep_config Configuration structure to initialize to default values + */ +void usb_host_pipe_get_config_defaults(struct usb_host_pipe_config *ep_config) +{ + /* Sanity check arguments */ + Assert(ep_config); + /* Write default config to config struct */ + ep_config->device_address = 0; + ep_config->endpoint_address = 0; + ep_config->pipe_type = USB_HOST_PIPE_TYPE_CONTROL; + ep_config->binterval = 0; + ep_config->size = 8; +} + +/** + * \brief Writes an USB host pipe configuration to the hardware module. + * + * Writes out a given configuration of an USB host pipe + * configuration to the hardware module. If the pipe is already configured, + * the new configuration will replace the existing one. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] ep_config Configuration settings for the pipe + * + * \return Status of the host pipe configuration operation. + * \retval STATUS_OK The host pipe was configured successfully. + */ +enum status_code usb_host_pipe_set_config(struct usb_module *module_inst, uint8_t pipe_num, + struct usb_host_pipe_config *ep_config) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(pipe_num < USB_PIPE_NUM); + Assert(ep_config); + + /* set pipe config */ + module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.BK = 0; + module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTYPE = ep_config->pipe_type; + module_inst->hw->HOST.HostPipe[pipe_num].BINTERVAL.reg = + ep_config->binterval; + if (ep_config->endpoint_address == 0) { + module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTOKEN = + USB_HOST_PIPE_TOKEN_SETUP; + } else if (ep_config->endpoint_address & USB_EP_DIR_IN) { + module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTOKEN = + USB_HOST_PIPE_TOKEN_IN; + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSSET.reg = + USB_HOST_PSTATUSSET_BK0RDY; + } else { + module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTOKEN = + USB_HOST_PIPE_TOKEN_OUT; + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSCLR.reg = + USB_HOST_PSTATUSCLR_BK0RDY; + } + + memset((uint8_t *)&usb_descriptor_table.usb_pipe_table[pipe_num], 0, + sizeof(usb_descriptor_table.usb_pipe_table[0])); + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].CTRL_PIPE.bit.PDADDR = + ep_config->device_address; + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].CTRL_PIPE.bit.PEPNUM = + ep_config->endpoint_address & USB_EP_ADDR_MASK; + if (ep_config->size == 1023) { + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.SIZE = 0x07; + } else { + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.SIZE = + (32 - clz(((uint32_t)min(max(ep_config->size, 8), 1024) << 1) - 1) - 1 - 3); + } + + /* Clear busy status */ + host_pipe_job_busy_status &= ~(1 << pipe_num); + + return STATUS_OK; +} + +/** + * \brief Gets an USB host pipe configuration. + * + * Gets out the configuration of an USB host pipe from the hardware module. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[out] ep_config Configuration settings for the pipe + * + * \return Status of the get host pipe configuration operation. + * \retval STATUS_OK The host pipe configuration was read successfully. + */ +enum status_code usb_host_pipe_get_config(struct usb_module *module_inst, uint8_t pipe_num, + struct usb_host_pipe_config *ep_config) +{ + uint32_t size; + + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(pipe_num < USB_PIPE_NUM); + Assert(ep_config); + /* get pipe config from setting register */ + ep_config->device_address = + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].CTRL_PIPE.bit.PDADDR; + ep_config->endpoint_address = + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].CTRL_PIPE.bit.PEPNUM; + + if (module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTOKEN == + USB_HOST_PIPE_TOKEN_IN) { + ep_config->endpoint_address |= USB_EP_DIR_IN; + } + + ep_config->pipe_type = (enum usb_host_pipe_type)module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTYPE; + ep_config->binterval = + module_inst->hw->HOST.HostPipe[pipe_num].BINTERVAL.reg; + size = usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.SIZE; + if (size == 0x07) { + ep_config->size = 1023; + } else { + ep_config->size = (8 << size); + } + + return STATUS_OK; +} + +/** + * \brief Registers a USB host pipe callback + * + * Registers a callback function which is implemented by the user. + * + * \note The callback must be enabled by \ref usb_host_pipe_enable_callback, + * in order for the interrupt handler to call it when the conditions for the + * callback type is met. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] callback_type Callback type given by an enum + * \param[in] callback_func Pointer to callback function + * + * \return Status of the registration operation. + * \retval STATUS_OK The callback was registered successfully. + */ +enum status_code usb_host_pipe_register_callback( + struct usb_module *module_inst, uint8_t pipe_num, + enum usb_host_pipe_callback callback_type, + usb_host_pipe_callback_t callback_func) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(pipe_num < USB_PIPE_NUM); + Assert(callback_func); + + /* Register callback function */ + module_inst->host_pipe_callback[pipe_num][callback_type] = callback_func; + + /* Set the bit corresponding to the callback_type */ + module_inst->host_pipe_registered_callback_mask[pipe_num] |= (1 << callback_type); + + return STATUS_OK; +} + +/** + * \brief Unregisters a USB host pipe callback + * + * Unregisters an asynchronous callback implemented by the user. Removing it + * from the internal callback registration table. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the de-registration operation. + * \retval STATUS_OK The callback was unregistered successfully. + */ +enum status_code usb_host_pipe_unregister_callback( + struct usb_module *module_inst, uint8_t pipe_num, + enum usb_host_pipe_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(pipe_num < USB_PIPE_NUM); + + /* Unregister callback function */ + module_inst->host_pipe_callback[pipe_num][callback_type] = NULL; + + /* Clear the bit corresponding to the callback_type */ + module_inst->host_pipe_registered_callback_mask[pipe_num] &= ~(1 << callback_type); + + return STATUS_OK; +} + +/** + * \brief Enables USB host pipe callback generation for a given type. + * + * Enables asynchronous callbacks for a given logical type. + * This must be called before USB host pipe generate callback events. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the callback enable operation. + * \retval STATUS_OK The callback was enabled successfully. + */ +enum status_code usb_host_pipe_enable_callback( + struct usb_module *module_inst, uint8_t pipe_num, + enum usb_host_pipe_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(pipe_num < USB_PIPE_NUM); + + /* Enable callback */ + module_inst->host_pipe_enabled_callback_mask[pipe_num] |= (1 << callback_type); + + if (callback_type == USB_HOST_PIPE_CALLBACK_TRANSFER_COMPLETE) { + module_inst->hw->HOST.HostPipe[pipe_num].PINTENSET.reg = USB_HOST_PINTENSET_TRCPT_Msk; + } + if (callback_type == USB_HOST_PIPE_CALLBACK_ERROR) { + module_inst->hw->HOST.HostPipe[pipe_num].PINTENSET.reg = + USB_HOST_PINTENSET_TRFAIL | USB_HOST_PINTENSET_PERR; + } + if (callback_type == USB_HOST_PIPE_CALLBACK_SETUP) { + module_inst->hw->HOST.HostPipe[pipe_num].PINTENSET.reg = USB_HOST_PINTENSET_TXSTP; + } + if (callback_type == USB_HOST_PIPE_CALLBACK_STALL) { + module_inst->hw->HOST.HostPipe[pipe_num].PINTENSET.reg = USB_HOST_PINTENSET_STALL; + } + + return STATUS_OK; +} + +/** + * \brief Disables USB host callback generation for a given type. + * + * Disables asynchronous callbacks for a given logical type. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the callback disable operation. + * \retval STATUS_OK The callback was disabled successfully. + */ +enum status_code usb_host_pipe_disable_callback( + struct usb_module *module_inst, uint8_t pipe_num, + enum usb_host_pipe_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(pipe_num < USB_PIPE_NUM); + + /* Enable callback */ + module_inst->host_pipe_enabled_callback_mask[pipe_num] &= ~(1 << callback_type); + + if (callback_type == USB_HOST_PIPE_CALLBACK_TRANSFER_COMPLETE) { + module_inst->hw->HOST.HostPipe[pipe_num].PINTENCLR.reg = USB_HOST_PINTENCLR_TRCPT_Msk; + } + if (callback_type == USB_HOST_PIPE_CALLBACK_ERROR) { + module_inst->hw->HOST.HostPipe[pipe_num].PINTENCLR.reg = + USB_HOST_PINTENCLR_TRFAIL| USB_HOST_PINTENCLR_PERR; + } + if (callback_type == USB_HOST_PIPE_CALLBACK_SETUP) { + module_inst->hw->HOST.HostPipe[pipe_num].PINTENCLR.reg = USB_HOST_PINTENCLR_TXSTP; + } + if (callback_type == USB_HOST_PIPE_CALLBACK_STALL) { + module_inst->hw->HOST.HostPipe[pipe_num].PINTENCLR.reg = USB_HOST_PINTENCLR_STALL; + } + + return STATUS_OK; +} + +/** + * \brief Sends the setup package. + * + * Sends the setup package. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] buf Pointer to data buffer + * + * \return Status of the setup operation. + * \retval STATUS_OK The setup job was set successfully. + * \retval STATUS_BUSY The pipe is busy. + * \retval STATUS_ERR_NOT_INITIALIZED The pipe has not been configured. + */ +enum status_code usb_host_pipe_setup_job(struct usb_module *module_inst, + uint8_t pipe_num, uint8_t *buf) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(pipe_num < USB_PIPE_NUM); + + if (host_pipe_job_busy_status & (1 << pipe_num)) { + return STATUS_BUSY; + } + + /* Set busy status */ + host_pipe_job_busy_status |= 1 << pipe_num; + + if (module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTYPE == + USB_HOST_PIPE_TYPE_DISABLE) { + return STATUS_ERR_NOT_INITIALIZED; + } + + /* get pipe config from setting register */ + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].ADDR.reg = (uint32_t)buf; + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.BYTE_COUNT = + 8; + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE = + 0; + module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTOKEN = + USB_HOST_PIPE_TOKEN_SETUP; + + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSSET.reg = USB_HOST_PSTATUSSET_BK0RDY; + usb_host_pipe_unfreeze(module_inst, pipe_num); + + return STATUS_OK; +} + +/** + * \brief USB host pipe read job. + * + * USB host pipe read job by set and start an in transaction transfer. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] buf Pointer to data buffer + * \param[in] buf_size Data buffer size + * \note The buffer length should not larger than 0x3FFF + * + * \return Status of the setting operation. + * \retval STATUS_OK The read job was set successfully. + * \retval STATUS_BUSY The pipe is busy. + * \retval STATUS_ERR_NOT_INITIALIZED The pipe has not been configured. + */ +enum status_code usb_host_pipe_read_job(struct usb_module *module_inst, + uint8_t pipe_num, uint8_t *buf, uint32_t buf_size) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(pipe_num < USB_PIPE_NUM); + + if (host_pipe_job_busy_status & (1 << pipe_num)) { + return STATUS_BUSY; + } + + /* Set busy status */ + host_pipe_job_busy_status |= 1 << pipe_num; + + if (module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTYPE == + USB_HOST_PIPE_TYPE_DISABLE) { + return STATUS_ERR_NOT_INITIALIZED; + } + + /* get pipe config from setting register */ + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].ADDR.reg = (uint32_t)buf; + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.BYTE_COUNT = + 0; + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE = + buf_size; + module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTOKEN = + USB_HOST_PIPE_TOKEN_IN; + + /* Start transfer */ + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSCLR.reg = USB_HOST_PSTATUSCLR_BK0RDY; + usb_host_pipe_unfreeze(module_inst, pipe_num); + + return STATUS_OK; +} + +/** + * \brief USB host pipe write job. + * + * USB host pipe write job by set and start an out transaction transfer. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] buf Pointer to data buffer + * \param[in] buf_size Data buffer size + * \note The buffer length should not larger than 0x3FFF + * + * \return Status of the setting operation. + * \retval STATUS_OK The write job was set successfully. + * \retval STATUS_BUSY The pipe is busy. + * \retval STATUS_ERR_NOT_INITIALIZED The pipe has not been configured. + */ +enum status_code usb_host_pipe_write_job(struct usb_module *module_inst, + uint8_t pipe_num, uint8_t *buf, uint32_t buf_size) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(pipe_num < USB_PIPE_NUM); + + if (host_pipe_job_busy_status & (1 << pipe_num)) { + return STATUS_BUSY; + } + + /* Set busy status */ + host_pipe_job_busy_status |= 1 << pipe_num; + + if (module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTYPE == + USB_HOST_PIPE_TYPE_DISABLE) { + return STATUS_ERR_NOT_INITIALIZED; + } + + /* get pipe config from setting register */ + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].ADDR.reg = (uint32_t)buf; + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.BYTE_COUNT = + buf_size; + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE = + 0; + module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTOKEN = + USB_HOST_PIPE_TOKEN_OUT; + + /* Start transfer */ + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSSET.reg = USB_HOST_PSTATUSSET_BK0RDY; + usb_host_pipe_unfreeze(module_inst, pipe_num); + + return STATUS_OK; +} + +/** + * \brief USB host abort a pipe job. + * + * USB host pipe abort job by freeze the pipe. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * + * \return Status of the setting operation. + * \retval STATUS_OK The abort job was set successfully. + * \retval STATUS_ERR_NOT_INITIALIZED The pipe has not been configured. + */ +enum status_code usb_host_pipe_abort_job(struct usb_module *module_inst, uint8_t pipe_num) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(pipe_num < USB_PIPE_NUM); + + if (module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTYPE == + USB_HOST_PIPE_TYPE_DISABLE) { + return STATUS_ERR_NOT_INITIALIZED; + } + + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSSET.reg = USB_HOST_PSTATUSSET_PFREEZE; + + /* Clear busy status */ + host_pipe_job_busy_status &= ~(1 << pipe_num); + + return STATUS_OK; +} + +/** + * \brief Sends the LPM package. + * + * Sends the LPM package. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] buf Pointer to data buffer + * + * \return Status of the setup operation. + * \retval STATUS_OK The setup job was set successfully. + * \retval STATUS_BUSY The pipe is busy. + * \retval STATUS_ERR_NOT_INITIALIZED The pipe has not been configured. + */ +enum status_code usb_host_pipe_lpm_job(struct usb_module *module_inst, + uint8_t pipe_num, bool b_remotewakeup, uint8_t besl) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(pipe_num < USB_PIPE_NUM); + + if (host_pipe_job_busy_status & (1 << pipe_num)) { + return STATUS_BUSY; + } + + /* Set busy status */ + host_pipe_job_busy_status |= 1 << pipe_num; + + if (module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTYPE == + USB_HOST_PIPE_TYPE_DISABLE) { + return STATUS_ERR_NOT_INITIALIZED; + } + + module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTYPE = + USB_HOST_PIPE_TYPE_EXTENDED; + + /* get pipe config from setting register */ + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].EXTREG.bit.SUBPID = 0x3; + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].EXTREG.bit.VARIABLE = + USB_LPM_ATTRIBUT_REMOTEWAKE(b_remotewakeup) | + USB_LPM_ATTRIBUT_BESL(besl) | + USB_LPM_ATTRIBUT_BLINKSTATE_L1; + + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSSET.reg = USB_HOST_PSTATUSSET_BK0RDY; + usb_host_pipe_unfreeze(module_inst, pipe_num); + + return STATUS_OK; +} + +/** + * \internal + * \brief Function called by USB interrupt to manage USB host interrupts + * + * USB host interrupt events are split into four sections: + * - USB line events + * (Device dis/connection, SOF, reset, resume, wakeup, error) + * - Pipe events + * (End of data transfer, setup, stall, error) + */ +static void _usb_host_interrupt_handler(void) +{ +#if BOOTLOADER_USES_HOST + + uint32_t pipe_int; + uint32_t flags; + + /* Manage pipe interrupts */ + pipe_int = ctz(_usb_instances->hw->HOST.PINTSMRY.reg); + if (pipe_int < 32) { + /* pipe interrupts */ + + /* get interrupt flags */ + flags = _usb_instances->hw->HOST.HostPipe[pipe_int].PINTFLAG.reg; + + /* host pipe transfer complete interrupt */ + if (flags & USB_HOST_PINTFLAG_TRCPT_Msk) { + /* Clear busy status */ + host_pipe_job_busy_status &= ~(1 << pipe_int); + /* clear the flag */ + _usb_instances->hw->HOST.HostPipe[pipe_int].PINTFLAG.reg = + USB_HOST_PINTFLAG_TRCPT_Msk; + if(_usb_instances->host_pipe_enabled_callback_mask[pipe_int] & + (1 << USB_HOST_PIPE_CALLBACK_TRANSFER_COMPLETE)) { + pipe_callback_para.pipe_num = pipe_int; + if (_usb_instances->hw->HOST.HostPipe[pipe_int].PCFG.bit.PTOKEN == + USB_HOST_PIPE_TOKEN_IN) { + /* in */ + pipe_callback_para.transfered_size = usb_descriptor_table.usb_pipe_table[pipe_int].HostDescBank[0].PCKSIZE.bit.BYTE_COUNT; + pipe_callback_para.required_size = usb_descriptor_table.usb_pipe_table[pipe_int].HostDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE; + usb_descriptor_table.usb_pipe_table[pipe_int].HostDescBank[0].PCKSIZE.bit.BYTE_COUNT = 0; + } else { + /* out */ + pipe_callback_para.transfered_size = usb_descriptor_table.usb_pipe_table[pipe_int].HostDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE; + pipe_callback_para.required_size = usb_descriptor_table.usb_pipe_table[pipe_int].HostDescBank[0].PCKSIZE.bit.BYTE_COUNT; + usb_descriptor_table.usb_pipe_table[pipe_int].HostDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE = 0; + if (0 == pipe_callback_para.transfered_size) { + pipe_callback_para.transfered_size = usb_descriptor_table.usb_pipe_table[pipe_int].HostDescBank[0].PCKSIZE.bit.BYTE_COUNT; + } + } + (_usb_instances->host_pipe_callback[pipe_int] + [USB_HOST_PIPE_CALLBACK_TRANSFER_COMPLETE])(_usb_instances, &pipe_callback_para); + } + } + + /* host pipe transfer fail interrupt */ + if (flags & USB_HOST_PINTFLAG_TRFAIL) { + /* Clear busy status */ + host_pipe_job_busy_status &= ~(1 << pipe_int); + /* clear the flag */ + _usb_instances->hw->HOST.HostPipe[pipe_int].PINTFLAG.reg = + USB_HOST_PINTFLAG_TRFAIL; + } + + /* host pipe error interrupt */ + if (flags & USB_HOST_PINTFLAG_PERR) { + /* Clear busy status */ + host_pipe_job_busy_status &= ~(1 << pipe_int); + /* clear the flag */ + _usb_instances->hw->HOST.HostPipe[pipe_int].PINTFLAG.reg = + USB_HOST_PINTFLAG_PERR; + if(_usb_instances->host_pipe_enabled_callback_mask[pipe_int] & + (1 << USB_HOST_PIPE_CALLBACK_ERROR)) { + pipe_callback_para.pipe_num = pipe_int; + pipe_callback_para.pipe_error_status = + usb_descriptor_table.usb_pipe_table[pipe_int].HostDescBank[0].STATUS_PIPE.reg & 0x1F; + (_usb_instances->host_pipe_callback[pipe_int] + [USB_HOST_PIPE_CALLBACK_ERROR])(_usb_instances, &pipe_callback_para); + } + } + + /* host pipe transmitted setup interrupt */ + if (flags & USB_HOST_PINTFLAG_TXSTP) { + /* Clear busy status */ + host_pipe_job_busy_status &= ~(1 << pipe_int); + /* clear the flag */ + _usb_instances->hw->HOST.HostPipe[pipe_int].PINTFLAG.reg = + USB_HOST_PINTFLAG_TXSTP; + if(_usb_instances->host_pipe_enabled_callback_mask[pipe_int] & + (1 << USB_HOST_PIPE_CALLBACK_SETUP)) { + pipe_callback_para.pipe_num = pipe_int; + pipe_callback_para.transfered_size = usb_descriptor_table.usb_pipe_table[pipe_int].HostDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE; + (_usb_instances->host_pipe_callback[pipe_int] + [USB_HOST_PIPE_CALLBACK_SETUP])(_usb_instances, NULL); + } + } + + /* host pipe stall interrupt */ + if (flags & USB_HOST_PINTFLAG_STALL) { + /* Clear busy status */ + host_pipe_job_busy_status &= ~(1 << pipe_int); + /* clear the flag */ + _usb_instances->hw->HOST.HostPipe[pipe_int].PINTFLAG.reg = + USB_HOST_PINTFLAG_STALL; + if(_usb_instances->host_pipe_enabled_callback_mask[pipe_int] & + (1 << USB_HOST_PIPE_CALLBACK_STALL)) { + pipe_callback_para.pipe_num = pipe_int; + (_usb_instances->host_pipe_callback[pipe_int] + [USB_HOST_PIPE_CALLBACK_STALL])(_usb_instances, &pipe_callback_para); + } + } + + } else { + /* host interrupts */ + + /* get interrupt flags */ + flags = _usb_instances->hw->HOST.INTFLAG.reg; + + /* host SOF interrupt */ + if (flags & USB_HOST_INTFLAG_HSOF) { + /* clear the flag */ + _usb_instances->hw->HOST.INTFLAG.reg = USB_HOST_INTFLAG_HSOF; + if(_usb_instances->host_enabled_callback_mask & (1 << USB_HOST_CALLBACK_SOF)) { + (_usb_instances->host_callback[USB_HOST_CALLBACK_SOF])(_usb_instances); + } + } + + /* host reset interrupt */ + if (flags & USB_HOST_INTFLAG_RST) { + /* Clear busy status */ + host_pipe_job_busy_status = 0; + /* clear the flag */ + _usb_instances->hw->HOST.INTFLAG.reg = USB_HOST_INTFLAG_RST; + if(_usb_instances->host_enabled_callback_mask & (1 << USB_HOST_CALLBACK_RESET)) { + (_usb_instances->host_callback[USB_HOST_CALLBACK_RESET])(_usb_instances); + } + } + + /* host upstream resume interrupts */ + if (flags & USB_HOST_INTFLAG_UPRSM) { + /* clear the flags */ + _usb_instances->hw->HOST.INTFLAG.reg = USB_HOST_INTFLAG_UPRSM; + if(_usb_instances->host_enabled_callback_mask & (1 << USB_HOST_CALLBACK_UPRSM)) { + (_usb_instances->host_callback[USB_HOST_CALLBACK_UPRSM])(_usb_instances); + } + } + + /* host downstream resume interrupts */ + if (flags & USB_HOST_INTFLAG_DNRSM) { + /* clear the flags */ + _usb_instances->hw->HOST.INTFLAG.reg = USB_HOST_INTFLAG_DNRSM; + if(_usb_instances->host_enabled_callback_mask & (1 << USB_HOST_CALLBACK_DNRSM)) { + (_usb_instances->host_callback[USB_HOST_CALLBACK_DNRSM])(_usb_instances); + } + } + + /* host wakeup interrupts */ + if (flags & USB_HOST_INTFLAG_WAKEUP) { + /* clear the flags */ + _usb_instances->hw->HOST.INTFLAG.reg = USB_HOST_INTFLAG_WAKEUP; + if(_usb_instances->host_enabled_callback_mask & (1 << USB_HOST_CALLBACK_WAKEUP)) { + (_usb_instances->host_callback[USB_HOST_CALLBACK_WAKEUP])(_usb_instances); + } + } + + /* host ram access interrupt */ + if (flags & USB_HOST_INTFLAG_RAMACER) { + /* Clear busy status */ + host_pipe_job_busy_status = 0; + /* clear the flag */ + _usb_instances->hw->HOST.INTFLAG.reg = USB_HOST_INTFLAG_RAMACER; + if(_usb_instances->host_enabled_callback_mask & (1 << USB_HOST_CALLBACK_RAMACER)) { + (_usb_instances->host_callback[USB_HOST_CALLBACK_RAMACER])(_usb_instances); + } + } + + /* host connect interrupt */ + if (flags & USB_HOST_INTFLAG_DCONN) { + /* Clear busy status */ + host_pipe_job_busy_status = 0; + /* clear the flag */ + _usb_instances->hw->HOST.INTFLAG.reg = USB_HOST_INTFLAG_DCONN; + if(_usb_instances->host_enabled_callback_mask & (1 << USB_HOST_CALLBACK_CONNECT)) { + (_usb_instances->host_callback[USB_HOST_CALLBACK_CONNECT])(_usb_instances); + } + } + + /* host disconnect interrupt */ + if (flags & USB_HOST_INTFLAG_DDISC) { + /* Clear busy status */ + host_pipe_job_busy_status = 0; + /* clear the flag */ + _usb_instances->hw->HOST.INTFLAG.reg = USB_HOST_INTFLAG_DDISC; + if(_usb_instances->host_enabled_callback_mask & (1 << USB_HOST_CALLBACK_DISCONNECT)) { + (_usb_instances->host_callback[USB_HOST_CALLBACK_DISCONNECT])(_usb_instances); + } + } + + } +#endif +} + +/** + * \brief Sets USB host pipe auto ZLP setting value + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] value Auto ZLP setting value, \c true to enable + * + */ +void usb_host_pipe_set_auto_zlp(struct usb_module *module_inst, uint8_t pipe_num, bool value) +{ + Assert(module_inst); + + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.AUTO_ZLP = value; +} +#endif + +/** + * \brief Registers a USB device callback + * + * Registers a callback function which is implemented by the user. + * + * \note The callback must be enabled by \ref usb_host_enable_callback, + * in order for the interrupt handler to call it when the conditions for the + * callback type is met. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] callback_type Callback type given by an enum + * \param[in] callback_func Pointer to callback function + * + * \return Status of the registration operation. + * \retval STATUS_OK The callback was registered successfully. + */ +enum status_code usb_device_register_callback(struct usb_module *module_inst, + enum usb_device_callback callback_type, + usb_device_callback_t callback_func) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(callback_func); + + /* Register callback function */ + module_inst->device_callback[callback_type] = callback_func; + + /* Set the bit corresponding to the callback_type */ + module_inst->device_registered_callback_mask |= _usb_device_irq_bits[callback_type]; + + return STATUS_OK; +} + +/** + * \brief Unregisters a USB device callback + * + * Unregisters an asynchronous callback implemented by the user. Removing it + * from the internal callback registration table. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the de-registration operation. + * \retval STATUS_OK The callback was unregistered successfully. + */ +enum status_code usb_device_unregister_callback(struct usb_module *module_inst, + enum usb_device_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + + /* Unregister callback function */ + module_inst->device_callback[callback_type] = NULL; + + /* Clear the bit corresponding to the callback_type */ + module_inst->device_registered_callback_mask &= ~_usb_device_irq_bits[callback_type]; + + return STATUS_OK; +} + +/** + * \brief Enables USB device callback generation for a given type. + * + * Enables asynchronous callbacks for a given logical type. + * This must be called before USB host generate callback events. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the callback enable operation. + * \retval STATUS_OK The callback was enabled successfully. + */ +enum status_code usb_device_enable_callback(struct usb_module *module_inst, + enum usb_device_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + /* clear related flag */ + module_inst->hw->DEVICE.INTFLAG.reg = _usb_device_irq_bits[callback_type]; + + /* Enable callback */ + module_inst->device_enabled_callback_mask |= _usb_device_irq_bits[callback_type]; + + module_inst->hw->DEVICE.INTENSET.reg = _usb_device_irq_bits[callback_type]; + + return STATUS_OK; +} + +/** + * \brief Disables USB device callback generation for a given type. + * + * Disables asynchronous callbacks for a given logical type. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the callback disable operation. + * \retval STATUS_OK The callback was disabled successfully. + */ +enum status_code usb_device_disable_callback(struct usb_module *module_inst, + enum usb_device_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + /* Disable callback */ + module_inst->device_enabled_callback_mask &= ~_usb_device_irq_bits[callback_type]; + + module_inst->hw->DEVICE.INTENCLR.reg = _usb_device_irq_bits[callback_type]; + + return STATUS_OK; +} + +/** + * \brief Registers a USB device endpoint callback + * + * Registers a callback function which is implemented by the user. + * + * \note The callback must be enabled by \ref usb_device_endpoint_enable_callback, + * in order for the interrupt handler to call it when the conditions for the + * callback type is met. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] ep_num Endpoint to configure + * \param[in] callback_type Callback type given by an enum + * \param[in] callback_func Pointer to callback function + * + * \return Status of the registration operation. + * \retval STATUS_OK The callback was registered successfully. + */ +enum status_code usb_device_endpoint_register_callback( + struct usb_module *module_inst, uint8_t ep_num, + enum usb_device_endpoint_callback callback_type, + usb_device_endpoint_callback_t callback_func) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(ep_num < USB_EPT_NUM); + Assert(callback_func); + + /* Register callback function */ + module_inst->device_endpoint_callback[ep_num][callback_type] = callback_func; + + /* Set the bit corresponding to the callback_type */ + module_inst->deivce_endpoint_registered_callback_mask[ep_num] |= _usb_endpoint_irq_bits[callback_type]; + + return STATUS_OK; +} + +/** + * \brief Unregisters a USB device endpoint callback + * + * Unregisters an callback implemented by the user. Removing it + * from the internal callback registration table. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] ep_num Endpoint to configure + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the de-registration operation. + * \retval STATUS_OK The callback was unregistered successfully. + */ +enum status_code usb_device_endpoint_unregister_callback( + struct usb_module *module_inst, uint8_t ep_num, + enum usb_device_endpoint_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(ep_num < USB_EPT_NUM); + + /* Unregister callback function */ + module_inst->device_endpoint_callback[ep_num][callback_type] = NULL; + + /* Clear the bit corresponding to the callback_type */ + module_inst->deivce_endpoint_registered_callback_mask[ep_num] &= ~_usb_endpoint_irq_bits[callback_type]; + + return STATUS_OK; +} + +/** + * \brief Enables USB device endpoint callback generation for a given type. + * + * Enables callbacks for a given logical type. + * This must be called before USB host pipe generate callback events. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] ep Endpoint to configure + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the callback enable operation. + * \retval STATUS_OK The callback was enabled successfully. + */ +enum status_code usb_device_endpoint_enable_callback( + struct usb_module *module_inst, uint8_t ep, + enum usb_device_endpoint_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + Assert(ep_num < USB_EPT_NUM); + + /* Enable callback */ + module_inst->device_endpoint_enabled_callback_mask[ep_num] |= _usb_endpoint_irq_bits[callback_type]; + + if (callback_type == USB_DEVICE_ENDPOINT_CALLBACK_TRCPT) { + if (ep_num == 0) { // control endpoint + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENSET.reg = USB_DEVICE_EPINTENSET_TRCPT0 | USB_DEVICE_EPINTENSET_TRCPT1; + } else if (ep & USB_EP_DIR_IN) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENSET.reg = USB_DEVICE_EPINTENSET_TRCPT1; + } else { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENSET.reg = USB_DEVICE_EPINTENSET_TRCPT0; + } + } + + if (callback_type == USB_DEVICE_ENDPOINT_CALLBACK_TRFAIL) { + if (ep_num == 0) { // control endpoint + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENSET.reg = USB_DEVICE_EPINTENSET_TRFAIL0 | USB_DEVICE_EPINTENSET_TRFAIL1; + } else if (ep & USB_EP_DIR_IN) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENSET.reg = USB_DEVICE_EPINTENSET_TRFAIL1; + } else { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENSET.reg = USB_DEVICE_EPINTENSET_TRFAIL0; + } + } + + if (callback_type == USB_DEVICE_ENDPOINT_CALLBACK_RXSTP) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENSET.reg = USB_DEVICE_EPINTENSET_RXSTP; + } + + if (callback_type == USB_DEVICE_ENDPOINT_CALLBACK_STALL) { + if (ep & USB_EP_DIR_IN) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENSET.reg = USB_DEVICE_EPINTENSET_STALL1; + } else { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENSET.reg = USB_DEVICE_EPINTENSET_STALL0; + } + } + + return STATUS_OK; +} + +/** + * \brief Disables USB device endpoint callback generation for a given type. + * + * Disables callbacks for a given logical type. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] ep Endpoint to configure + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the callback disable operation. + * \retval STATUS_OK The callback was disabled successfully. + */ +enum status_code usb_device_endpoint_disable_callback( + struct usb_module *module_inst, uint8_t ep, + enum usb_device_endpoint_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + Assert(ep_num < USB_EPT_NUM); + + /* Enable callback */ + module_inst->device_endpoint_enabled_callback_mask[ep_num] &= ~_usb_endpoint_irq_bits[callback_type]; + + if (callback_type == USB_DEVICE_ENDPOINT_CALLBACK_TRCPT) { + if (ep_num == 0) { // control endpoint + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENCLR.reg = USB_DEVICE_EPINTENCLR_TRCPT0 | USB_DEVICE_EPINTENCLR_TRCPT1; + } else if (ep & USB_EP_DIR_IN) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENCLR.reg = USB_DEVICE_EPINTENCLR_TRCPT1; + } else { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENCLR.reg = USB_DEVICE_EPINTENCLR_TRCPT0; + } + } + + if (callback_type == USB_DEVICE_ENDPOINT_CALLBACK_TRFAIL) { + if (ep_num == 0) { // control endpoint + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENCLR.reg = USB_DEVICE_EPINTENCLR_TRFAIL0 | USB_DEVICE_EPINTENCLR_TRFAIL1; + } else if (ep & USB_EP_DIR_IN) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENCLR.reg = USB_DEVICE_EPINTENCLR_TRFAIL1; + } else { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENCLR.reg = USB_DEVICE_EPINTENCLR_TRFAIL0; + } + } + + if (callback_type == USB_DEVICE_ENDPOINT_CALLBACK_RXSTP) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENCLR.reg = USB_DEVICE_EPINTENCLR_RXSTP; + } + + if (callback_type == USB_DEVICE_ENDPOINT_CALLBACK_STALL) { + if (ep & USB_EP_DIR_IN) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENCLR.reg = USB_DEVICE_EPINTENCLR_STALL1; + } else { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENCLR.reg = USB_DEVICE_EPINTENCLR_STALL0; + } + } + + return STATUS_OK; +} + +/** + * \brief Initializes an USB device endpoint configuration structure to defaults. + * + * Initializes a given USB device endpoint configuration structure to a + * set of known default values. This function should be called on all new + * instances of these configuration structures before being modified by the + * user application. + * + * The default configuration is as follows: + * \li endpoint address is 0 + * \li endpoint size is 8 bytes + * \li auto_zlp is false + * \li endpoint type is control + * + * \param[out] ep_config Configuration structure to initialize to default values + */ +void usb_device_endpoint_get_config_defaults(struct usb_device_endpoint_config *ep_config) +{ + /* Sanity check arguments */ + Assert(ep_config); + + /* Write default config to config struct */ + ep_config->ep_address = 0; + ep_config->ep_size = USB_ENDPOINT_8_BYTE; + ep_config->auto_zlp = false; + ep_config->ep_type = USB_DEVICE_ENDPOINT_TYPE_CONTROL; +} + +/** + * \brief Writes an USB device endpoint configuration to the hardware module. + * + * Writes out a given configuration of an USB device endpoint + * configuration to the hardware module. If the pipe is already configured, + * the new configuration will replace the existing one. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] ep_config Configuration settings for the endpoint + * + * \return Status of the device endpoint configuration operation + * \retval STATUS_OK The device endpoint was configured successfully + * \retval STATUS_ERR_DENIED The endpoint address is already configured + */ +enum status_code usb_device_endpoint_set_config(struct usb_module *module_inst, + struct usb_device_endpoint_config *ep_config) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(ep_config); + + uint8_t ep_num = ep_config->ep_address & USB_EP_ADDR_MASK; + uint8_t ep_bank = (ep_config->ep_address & USB_EP_DIR_IN) ? 1 : 0; + + switch (ep_config->ep_type) { + case USB_DEVICE_ENDPOINT_TYPE_DISABLE: + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg = USB_DEVICE_EPCFG_EPTYPE0(0) | USB_DEVICE_EPCFG_EPTYPE1(0); + return STATUS_OK; + + case USB_DEVICE_ENDPOINT_TYPE_CONTROL: + if ((module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg & USB_DEVICE_EPCFG_EPTYPE0_Msk) == 0 && \ + (module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg & USB_DEVICE_EPCFG_EPTYPE1_Msk) == 0) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg = USB_DEVICE_EPCFG_EPTYPE0(1) | USB_DEVICE_EPCFG_EPTYPE1(1); + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_BK0RDY; + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_BK1RDY; + } else { + return STATUS_ERR_DENIED; + } + if (true == ep_config->auto_zlp) { + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[0].PCKSIZE.reg |= USB_DEVICE_PCKSIZE_AUTO_ZLP; + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[1].PCKSIZE.reg |= USB_DEVICE_PCKSIZE_AUTO_ZLP; + } else { + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[0].PCKSIZE.reg &= ~USB_DEVICE_PCKSIZE_AUTO_ZLP; + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[1].PCKSIZE.reg &= ~USB_DEVICE_PCKSIZE_AUTO_ZLP; + } + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[0].PCKSIZE.bit.SIZE = ep_config->ep_size; + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[1].PCKSIZE.bit.SIZE = ep_config->ep_size; + return STATUS_OK; + + case USB_DEVICE_ENDPOINT_TYPE_ISOCHRONOUS: + if (ep_bank) { + if ((module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg & USB_DEVICE_EPCFG_EPTYPE1_Msk) == 0){ + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg |= USB_DEVICE_EPCFG_EPTYPE1(2); + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_BK1RDY; + } else { + return STATUS_ERR_DENIED; + } + } else { + if ((module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg & USB_DEVICE_EPCFG_EPTYPE0_Msk) == 0){ + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg |= USB_DEVICE_EPCFG_EPTYPE0(2); + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_BK0RDY; + } else { + return STATUS_ERR_DENIED; + } + } + break; + + case USB_DEVICE_ENDPOINT_TYPE_BULK: + if (ep_bank) { + if ((module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg & USB_DEVICE_EPCFG_EPTYPE1_Msk) == 0){ + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg |= USB_DEVICE_EPCFG_EPTYPE1(3); + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_BK1RDY; + } else { + return STATUS_ERR_DENIED; + } + } else { + if ((module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg & USB_DEVICE_EPCFG_EPTYPE0_Msk) == 0){ + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg |= USB_DEVICE_EPCFG_EPTYPE0(3); + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_BK0RDY; + } else { + return STATUS_ERR_DENIED; + } + } + break; + + case USB_DEVICE_ENDPOINT_TYPE_INTERRUPT: + if (ep_bank) { + if ((module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg & USB_DEVICE_EPCFG_EPTYPE1_Msk) == 0){ + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg |= USB_DEVICE_EPCFG_EPTYPE1(4); + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_BK1RDY; + } else { + return STATUS_ERR_DENIED; + } + } else { + if ((module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg & USB_DEVICE_EPCFG_EPTYPE0_Msk) == 0){ + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg |= USB_DEVICE_EPCFG_EPTYPE0(4); + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_BK0RDY; + } else { + return STATUS_ERR_DENIED; + } + } + break; + + default: + break; + } + + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[ep_bank].PCKSIZE.bit.SIZE = ep_config->ep_size; + + if (true == ep_config->auto_zlp) { + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[ep_bank].PCKSIZE.reg |= USB_DEVICE_PCKSIZE_AUTO_ZLP; + } else { + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[ep_bank].PCKSIZE.reg &= ~USB_DEVICE_PCKSIZE_AUTO_ZLP; + } + + return STATUS_OK; +} + +/** + * \brief Check if current endpoint is configured + * + * \param module_inst Pointer to USB software instance struct + * \param ep Endpoint address (direction & number) + * + * \return \c true if endpoint is configured and ready to use + */ +bool usb_device_endpoint_is_configured(struct usb_module *module_inst, uint8_t ep) +{ + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + uint8_t flag; + + if (ep & USB_EP_DIR_IN) { + flag = (uint8_t)(module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.bit.EPTYPE1); + } else { + flag = (uint8_t)(module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.bit.EPTYPE0); + } + return ((enum usb_device_endpoint_type)(flag) != USB_DEVICE_ENDPOINT_TYPE_DISABLE); +} + + +/** + * \brief Abort ongoing job on the endpoint + * + * \param module_inst Pointer to USB software instance struct + * \param ep Endpoint address + */ +void usb_device_endpoint_abort_job(struct usb_module *module_inst, uint8_t ep) +{ + uint8_t ep_num; + ep_num = ep & USB_EP_ADDR_MASK; + + // Stop transfer + if (ep & USB_EP_DIR_IN) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_BK1RDY; + // Eventually ack a transfer occur during abort + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRCPT1; + } else { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_BK0RDY; + // Eventually ack a transfer occur during abort + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRCPT0; + } +} + +/** + * \brief Check if endpoint is halted + * + * \param module_inst Pointer to USB software instance struct + * \param ep Endpoint address + * + * \return \c true if the endpoint is halted + */ +bool usb_device_endpoint_is_halted(struct usb_module *module_inst, uint8_t ep) +{ + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + + if (ep & USB_EP_DIR_IN) { + return (module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUS.reg & USB_DEVICE_EPSTATUSSET_STALLRQ1); + } else { + return (module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUS.reg & USB_DEVICE_EPSTATUSSET_STALLRQ0); + } +} + +/** + * \brief Halt the endpoint (send STALL) + * + * \param module_inst Pointer to USB software instance struct + * \param ep Endpoint address + */ +void usb_device_endpoint_set_halt(struct usb_module *module_inst, uint8_t ep) +{ + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + + // Stall endpoint + if (ep & USB_EP_DIR_IN) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_STALLRQ1; + } else { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_STALLRQ0; + } +} + +/** + * \brief Clear endpoint halt state + * + * \param module_inst Pointer to USB software instance struct + * \param ep Endpoint address + */ +void usb_device_endpoint_clear_halt(struct usb_module *module_inst, uint8_t ep) +{ + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + + if (ep & USB_EP_DIR_IN) { + if (module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUS.reg & USB_DEVICE_EPSTATUSSET_STALLRQ1) { + // Remove stall request + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_STALLRQ1; + if (module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_STALL1) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_STALL1; + // The Stall has occurred, then reset data toggle + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSSET_DTGLIN; + } + } + } else { + if (module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUS.reg & USB_DEVICE_EPSTATUSSET_STALLRQ0) { + // Remove stall request + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_STALLRQ0; + if (module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_STALL0) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_STALL0; + // The Stall has occurred, then reset data toggle + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSSET_DTGLOUT; + } + } + } +} + +/** + * \brief Start write buffer job on a endpoint + * + * \param module_inst Pointer to USB module instance + * \param ep_num Endpoint number + * \param pbuf Pointer to buffer + * \param buf_size Size of buffer + * + * \return Status of procedure + * \retval STATUS_OK Job started successfully + * \retval STATUS_ERR_DENIED Endpoint is not ready + */ +enum status_code usb_device_endpoint_write_buffer_job(struct usb_module *module_inst,uint8_t ep_num, + uint8_t* pbuf, uint32_t buf_size) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(ep_num < USB_EPT_NUM); + + uint8_t flag; + flag = (uint8_t)(module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.bit.EPTYPE1); + if ((enum usb_device_endpoint_type)(flag) == USB_DEVICE_ENDPOINT_TYPE_DISABLE) { + return STATUS_ERR_DENIED; + }; + + /* get endpoint configuration from setting register */ + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[1].ADDR.reg = (uint32_t)pbuf; + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[1].PCKSIZE.bit.MULTI_PACKET_SIZE = 0; + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[1].PCKSIZE.bit.BYTE_COUNT = buf_size; + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_BK1RDY; + + return STATUS_OK; +} + +/** + * \brief Start read buffer job on a endpoint + * + * \param module_inst Pointer to USB module instance + * \param ep_num Endpoint number + * \param pbuf Pointer to buffer + * \param buf_size Size of buffer + * + * \return Status of procedure + * \retval STATUS_OK Job started successfully + * \retval STATUS_ERR_DENIED Endpoint is not ready + */ +enum status_code usb_device_endpoint_read_buffer_job(struct usb_module *module_inst,uint8_t ep_num, + uint8_t* pbuf, uint32_t buf_size) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(ep_num < USB_EPT_NUM); + + uint8_t flag; + flag = (uint8_t)(module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.bit.EPTYPE0); + if ((enum usb_device_endpoint_type)(flag) == USB_DEVICE_ENDPOINT_TYPE_DISABLE) { + return STATUS_ERR_DENIED; + }; + + /* get endpoint configuration from setting register */ + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[0].ADDR.reg = (uint32_t)pbuf; + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE = buf_size; + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[0].PCKSIZE.bit.BYTE_COUNT = 0; + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_BK0RDY; + + return STATUS_OK; +} + +/** + * \brief Start setup packet read job on a endpoint + * + * \param module_inst Pointer to USB device module instance + * \param pbuf Pointer to buffer + * + * \return Status of procedure + * \retval STATUS_OK Job started successfully + * \retval STATUS_ERR_DENIED Endpoint is not ready + */ +enum status_code usb_device_endpoint_setup_buffer_job(struct usb_module *module_inst, + uint8_t* pbuf) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + /* get endpoint configuration from setting register */ + usb_descriptor_table.usb_endpoint_table[0].DeviceDescBank[0].ADDR.reg = (uint32_t)pbuf; + usb_descriptor_table.usb_endpoint_table[0].DeviceDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE = 8; + usb_descriptor_table.usb_endpoint_table[0].DeviceDescBank[0].PCKSIZE.bit.BYTE_COUNT = 0; + module_inst->hw->DEVICE.DeviceEndpoint[0].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_BK0RDY; + + return STATUS_OK; +} + +static void _usb_device_interrupt_handler(void) +{ + uint16_t ep_inst; + uint16_t flags, flags_run; + ep_inst = _usb_instances->hw->DEVICE.EPINTSMRY.reg; + + /* device interrupt */ + if (0 == ep_inst) { + int i; + + /* get interrupt flags */ + flags = _usb_instances->hw->DEVICE.INTFLAG.reg; + flags_run = flags & + _usb_instances->device_enabled_callback_mask & + _usb_instances->device_registered_callback_mask; + + for (i = 0; i < USB_DEVICE_CALLBACK_N; i ++) { + if (flags & _usb_device_irq_bits[i]) { + _usb_instances->hw->DEVICE.INTFLAG.reg = + _usb_device_irq_bits[i]; + } + if (flags_run & _usb_device_irq_bits[i]) { + if (i == USB_DEVICE_CALLBACK_LPMSUSP) { + device_callback_lpm_wakeup_enable = + usb_descriptor_table.usb_endpoint_table[0].DeviceDescBank[0].EXTREG.bit.VARIABLE + & USB_LPM_ATTRIBUT_REMOTEWAKE_MASK; + } + (_usb_instances->device_callback[i])(_usb_instances, &device_callback_lpm_wakeup_enable); + } + } + + } else { + /* endpoint interrupt */ + + for (uint8_t i = 0; i < USB_EPT_NUM; i++) { + + if (ep_inst & (1 << i)) { + flags = _usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg; + flags_run = flags & + _usb_instances->device_endpoint_enabled_callback_mask[i] & + _usb_instances->deivce_endpoint_registered_callback_mask[i]; + + // endpoint transfer stall interrupt + if (flags & USB_DEVICE_EPINTFLAG_STALL_Msk) { + if (_usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_STALL1) { + _usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_STALL1; + ep_callback_para.endpoint_address = USB_EP_DIR_IN | i; + } else if (_usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_STALL0) { + _usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_STALL0; + ep_callback_para.endpoint_address = USB_EP_DIR_OUT | i; + } + + if (flags_run & USB_DEVICE_EPINTFLAG_STALL_Msk) { + (_usb_instances->device_endpoint_callback[i][USB_DEVICE_ENDPOINT_CALLBACK_STALL])(_usb_instances,&ep_callback_para); + } + return; + } + + // endpoint received setup interrupt + if (flags & USB_DEVICE_EPINTFLAG_RXSTP) { + _usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_RXSTP; + if(_usb_instances->device_endpoint_enabled_callback_mask[i] & _usb_endpoint_irq_bits[USB_DEVICE_ENDPOINT_CALLBACK_RXSTP]) { + ep_callback_para.received_bytes = (uint16_t)(usb_descriptor_table.usb_endpoint_table[i].DeviceDescBank[0].PCKSIZE.bit.BYTE_COUNT); + (_usb_instances->device_endpoint_callback[i][USB_DEVICE_ENDPOINT_CALLBACK_RXSTP])(_usb_instances,&ep_callback_para); + } + return; + } + + // endpoint transfer fail interrupt + if (flags & USB_DEVICE_EPINTFLAG_TRFAIL_Msk) { + if (_usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_TRFAIL1) { + _usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRFAIL1; + if (usb_descriptor_table.usb_endpoint_table[i].DeviceDescBank[1].STATUS_BK.reg & USB_DEVICE_STATUS_BK_ERRORFLOW) { + usb_descriptor_table.usb_endpoint_table[i].DeviceDescBank[1].STATUS_BK.reg &= ~USB_DEVICE_STATUS_BK_ERRORFLOW; + } + ep_callback_para.endpoint_address = USB_EP_DIR_IN | i; + if (_usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_TRCPT1) { + return; + } + } else if(_usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_TRFAIL0) { + _usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRFAIL0; + if (usb_descriptor_table.usb_endpoint_table[i].DeviceDescBank[0].STATUS_BK.reg & USB_DEVICE_STATUS_BK_ERRORFLOW) { + usb_descriptor_table.usb_endpoint_table[i].DeviceDescBank[0].STATUS_BK.reg &= ~USB_DEVICE_STATUS_BK_ERRORFLOW; + } + ep_callback_para.endpoint_address = USB_EP_DIR_OUT | i; + if (_usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_TRCPT0) { + return; + } + } + + if(flags_run & USB_DEVICE_EPINTFLAG_TRFAIL_Msk) { + (_usb_instances->device_endpoint_callback[i][USB_DEVICE_ENDPOINT_CALLBACK_TRFAIL])(_usb_instances,&ep_callback_para); + } + return; + } + + // endpoint transfer complete interrupt + if (flags & USB_DEVICE_EPINTFLAG_TRCPT_Msk) { + if (_usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_TRCPT1) { + _usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRCPT1; + ep_callback_para.endpoint_address = USB_EP_DIR_IN | i; + ep_callback_para.sent_bytes = (uint16_t)(usb_descriptor_table.usb_endpoint_table[i].DeviceDescBank[1].PCKSIZE.bit.BYTE_COUNT); + + } else if (_usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_TRCPT0) { + _usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRCPT0; + ep_callback_para.endpoint_address = USB_EP_DIR_OUT | i; + ep_callback_para.received_bytes = (uint16_t)(usb_descriptor_table.usb_endpoint_table[i].DeviceDescBank[0].PCKSIZE.bit.BYTE_COUNT); + ep_callback_para.out_buffer_size = (uint16_t)(usb_descriptor_table.usb_endpoint_table[i].DeviceDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE); + } + if(flags_run & USB_DEVICE_EPINTFLAG_TRCPT_Msk) { + (_usb_instances->device_endpoint_callback[i][USB_DEVICE_ENDPOINT_CALLBACK_TRCPT])(_usb_instances,&ep_callback_para); + } + return; + } + } + } + } +} + +/** + * \brief Enable the USB module peripheral + * + * \param module_inst pointer to USB module instance + */ +void usb_enable(struct usb_module *module_inst) +{ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.CTRLA.reg |= USB_CTRLA_ENABLE; + while (module_inst->hw->HOST.SYNCBUSY.reg == USB_SYNCBUSY_ENABLE); +} + +/** + * \brief Disable the USB module peripheral + * + * \param module_inst pointer to USB module instance + */ +void usb_disable(struct usb_module *module_inst) +{ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.CTRLA.reg &= ~USB_CTRLA_ENABLE; + while (module_inst->hw->HOST.SYNCBUSY.reg == USB_SYNCBUSY_ENABLE); +} + +/** + * \brief Interrupt handler for the USB module. + */ +void USB_Handler(void) +{ + if (_usb_instances->hw->HOST.CTRLA.bit.MODE) { +#if !SAMD11 + /*host mode ISR */ + _usb_host_interrupt_handler(); +#endif + } else { + /*device mode ISR */ + _usb_device_interrupt_handler(); + } +} + +/** + * \brief Get the default USB module settings + * + * \param[out] module_config Configuration structure to initialize to default values + */ +void usb_get_config_defaults(struct usb_config *module_config) +{ + Assert(module_config); + + /* Sanity check arguments */ + Assert(module_config); + /* Write default configuration to config struct */ + module_config->select_host_mode = 0; + module_config->run_in_standby = 1; + module_config->source_generator = GCLK_GENERATOR_0; + module_config->speed_mode = USB_SPEED_FULL; +} + +#define NVM_USB_PAD_TRANSN_POS 45 +#define NVM_USB_PAD_TRANSN_SIZE 5 +#define NVM_USB_PAD_TRANSP_POS 50 +#define NVM_USB_PAD_TRANSP_SIZE 5 +#define NVM_USB_PAD_TRIM_POS 55 +#define NVM_USB_PAD_TRIM_SIZE 3 + +/** + * \brief Initializes USB module instance + * + * Enables the clock and initializes the USB module, based on the given + * configuration values. + * + * \param[in,out] module_inst Pointer to the software module instance struct + * \param[in] hw Pointer to the USB hardware module + * \param[in] module_config Pointer to the USB configuration options struct + * + * \return Status of the initialization procedure. + * + * \retval STATUS_OK The module was initialized successfully + */ +enum status_code usb_init(struct usb_module *module_inst, Usb *const hw, + struct usb_config *module_config) +{ + /* Sanity check arguments */ + Assert(hw); + Assert(module_inst); + Assert(module_config); + + uint32_t i,j; + uint32_t pad_transn, pad_transp, pad_trim; + struct system_pinmux_config pin_config; + struct system_gclk_chan_config gclk_chan_config; + +#if !SAMD11 + host_pipe_job_busy_status = 0; +#endif + + _usb_instances = module_inst; + + /* Associate the software module instance with the hardware module */ + module_inst->hw = hw; + + /* Turn on the digital interface clock */ + system_apb_clock_set_mask(SYSTEM_CLOCK_APB_APBB, PM_APBBMASK_USB); + + /* Set up the USB DP/DN pins */ + system_pinmux_get_config_defaults(&pin_config); + pin_config.mux_position = MUX_PA24G_USB_DM; + system_pinmux_pin_set_config(PIN_PA24G_USB_DM, &pin_config); + pin_config.mux_position = MUX_PA25G_USB_DP; + system_pinmux_pin_set_config(PIN_PA25G_USB_DP, &pin_config); + + /* Setup clock for module */ + system_gclk_chan_get_config_defaults(&gclk_chan_config); + gclk_chan_config.source_generator = module_config->source_generator; + system_gclk_chan_set_config(USB_GCLK_ID, &gclk_chan_config); + system_gclk_chan_enable(USB_GCLK_ID); + + /* Reset */ + hw->HOST.CTRLA.bit.SWRST = 1; + while (hw->HOST.SYNCBUSY.bit.SWRST) { + /* Sync wait */ + } + + /* Load Pad Calibration */ + pad_transn =( *((uint32_t *)(NVMCTRL_OTP4) + + (NVM_USB_PAD_TRANSN_POS / 32)) + >> (NVM_USB_PAD_TRANSN_POS % 32)) + & ((1 << NVM_USB_PAD_TRANSN_SIZE) - 1); + + if (pad_transn == 0x1F) { + pad_transn = 5; + } + + hw->HOST.PADCAL.bit.TRANSN = pad_transn; + + pad_transp =( *((uint32_t *)(NVMCTRL_OTP4) + + (NVM_USB_PAD_TRANSP_POS / 32)) + >> (NVM_USB_PAD_TRANSP_POS % 32)) + & ((1 << NVM_USB_PAD_TRANSP_SIZE) - 1); + + if (pad_transp == 0x1F) { + pad_transp = 29; + } + + hw->HOST.PADCAL.bit.TRANSP = pad_transp; + + pad_trim =( *((uint32_t *)(NVMCTRL_OTP4) + + (NVM_USB_PAD_TRIM_POS / 32)) + >> (NVM_USB_PAD_TRIM_POS % 32)) + & ((1 << NVM_USB_PAD_TRIM_SIZE) - 1); + + if (pad_trim == 0x7) { + pad_trim = 3; + } + + hw->HOST.PADCAL.bit.TRIM = pad_trim; + + /* Set the configuration */ + hw->HOST.CTRLA.bit.MODE = module_config->select_host_mode; + hw->HOST.CTRLA.bit.RUNSTDBY = module_config->run_in_standby; + hw->HOST.DESCADD.reg = (uint32_t)(&usb_descriptor_table.usb_endpoint_table[0]); + if (USB_SPEED_FULL == module_config->speed_mode) { + module_inst->hw->DEVICE.CTRLB.bit.SPDCONF = USB_DEVICE_CTRLB_SPDCONF_0_Val; + } else if(USB_SPEED_LOW == module_config->speed_mode) { + module_inst->hw->DEVICE.CTRLB.bit.SPDCONF = USB_DEVICE_CTRLB_SPDCONF_1_Val; + } + + memset((uint8_t *)(&usb_descriptor_table.usb_endpoint_table[0]), 0, + sizeof(usb_descriptor_table.usb_endpoint_table)); + +#if !SAMD11 + /* callback related init */ + for (i = 0; i < USB_HOST_CALLBACK_N; i++) { + module_inst->host_callback[i] = NULL; + }; + for (i = 0; i < USB_PIPE_NUM; i++) { + for (j = 0; j < USB_HOST_PIPE_CALLBACK_N; j++) { + module_inst->host_pipe_callback[i][j] = NULL; + } + }; + module_inst->host_registered_callback_mask = 0; + module_inst->host_enabled_callback_mask = 0; + for (i = 0; i < USB_PIPE_NUM; i++) { + module_inst->host_pipe_registered_callback_mask[i] = 0; + module_inst->host_pipe_enabled_callback_mask[i] = 0; + } +#endif + + /* device callback related */ + for (i = 0; i < USB_DEVICE_CALLBACK_N; i++) { + module_inst->device_callback[i] = NULL; + } + for (i = 0; i < USB_EPT_NUM; i++) { + for(j = 0; j < USB_DEVICE_EP_CALLBACK_N; j++) { + module_inst->device_endpoint_callback[i][j] = NULL; + } + } + module_inst->device_registered_callback_mask = 0; + module_inst->device_enabled_callback_mask = 0; + for (j = 0; j < USB_EPT_NUM; j++) { + module_inst->deivce_endpoint_registered_callback_mask[j] = 0; + module_inst->device_endpoint_enabled_callback_mask[j] = 0; + } + + /* Enable interrupts for this USB module */ + system_interrupt_enable(SYSTEM_INTERRUPT_MODULE_USB); + + return STATUS_OK; +} + + diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/usb/usb.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/usb/usb.h new file mode 100644 index 0000000..6273435 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/drivers/usb/usb.h @@ -0,0 +1,820 @@ +/** + * \file + * + * \brief SAM USB Driver + * + * Copyright (C) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef USB_H_INCLUDED +#define USB_H_INCLUDED + +#include +#include +#include +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \defgroup asfdoc_sam0_usb_group SAM Universal Serial Bus (USB) + * + * The Universal Serial Bus (USB) module complies with the USB 2.1 specification. + * + * The following peripherals are used by this module: + * - USB (Universal Serial Bus) + * + * The following devices can use this module: + * - SAM D21 + * - SAM R21 + * - SAM D11 + * + * The USB module covers following mode: + * \if USB_DEVICE_MODE + * - USB Device Mode + * \endif + * \if USB_HOST_MODE + * - USB Host Mode + * \endif + * + * The USB module covers following speed: + * \if USB_HS_MODE + * - USB High Speed (480Mbit/s) + * \endif + * - USB Full Speed (12Mbit/s) + * \if USB_LS_MODE + * - USB Low Speed (1.5Mbit/s) + * \endif + * + * \if USB_LPM_MODE + * The USB module supports Link Power Management (LPM-L1) protocol. + * \endif + * + * USB support needs whole set of enumeration process, to make the device + * recognizable and usable. The USB driver is designed to interface to the + * USB Stack in Atmel Software Framework (ASF). + * + * \if USB_DEVICE_MODE + * \section asfdoc_sam0_usb_device USB Device Mode + * The ASF USB Device Stack has defined the USB Device Driver (UDD) interface, + * to support USB device operations. The USB module device driver complies with + * this interface, so that the USB Device Stack can work based on the + * USB module. + * + * Refer to + * "ASF - USB Device Stack" for more details. + * \endif + * + * \if USB_HOST_MODE + * \section adfdoc_sam0_usb_host USB Host Mode + * The ASF USB Host Stack has defined the USB Host Driver (UHD) interface, + * to support USB host operations. The USB module host driver complies with + * this interface, so that the USB Host Stack can work based on the USB module. + * + * Refer to + * "ASF - USB Host Stack" for more details. + * \endif + */ + +/** Enum for the speed status for the USB module */ +enum usb_speed { + USB_SPEED_LOW, + USB_SPEED_FULL, +}; + +/** Enum for the possible callback types for the USB in host module */ +enum usb_host_callback { + USB_HOST_CALLBACK_SOF, + USB_HOST_CALLBACK_RESET, + USB_HOST_CALLBACK_WAKEUP, + USB_HOST_CALLBACK_DNRSM, + USB_HOST_CALLBACK_UPRSM, + USB_HOST_CALLBACK_RAMACER, + USB_HOST_CALLBACK_CONNECT, + USB_HOST_CALLBACK_DISCONNECT, + USB_HOST_CALLBACK_N, +}; + +/** Enum for the possible callback types for the USB pipe in host module */ +enum usb_host_pipe_callback { + USB_HOST_PIPE_CALLBACK_TRANSFER_COMPLETE, + USB_HOST_PIPE_CALLBACK_ERROR, + USB_HOST_PIPE_CALLBACK_SETUP, + USB_HOST_PIPE_CALLBACK_STALL, + USB_HOST_PIPE_CALLBACK_N, +}; + +/** + * \brief Host pipe types. + */ +enum usb_host_pipe_type { + USB_HOST_PIPE_TYPE_DISABLE, + USB_HOST_PIPE_TYPE_CONTROL, + USB_HOST_PIPE_TYPE_ISO, + USB_HOST_PIPE_TYPE_BULK, + USB_HOST_PIPE_TYPE_INTERRUPT, + USB_HOST_PIPE_TYPE_EXTENDED, +}; + +/** + * \brief Host pipe token types. + */ +enum usb_host_pipe_token { + USB_HOST_PIPE_TOKEN_SETUP, + USB_HOST_PIPE_TOKEN_IN, + USB_HOST_PIPE_TOKEN_OUT, +}; + +/** + * \brief Enumeration for the possible callback types for the USB in device module + */ +enum usb_device_callback { + USB_DEVICE_CALLBACK_SOF, + USB_DEVICE_CALLBACK_RESET, + USB_DEVICE_CALLBACK_WAKEUP, + USB_DEVICE_CALLBACK_RAMACER, + USB_DEVICE_CALLBACK_SUSPEND, + USB_DEVICE_CALLBACK_LPMNYET, + USB_DEVICE_CALLBACK_LPMSUSP, + USB_DEVICE_CALLBACK_N, +}; + +/** + * \brief Enumeration for the possible callback types for the USB endpoint in device module + */ +enum usb_device_endpoint_callback { + USB_DEVICE_ENDPOINT_CALLBACK_TRCPT, + USB_DEVICE_ENDPOINT_CALLBACK_TRFAIL, + USB_DEVICE_ENDPOINT_CALLBACK_RXSTP, + USB_DEVICE_ENDPOINT_CALLBACK_STALL, + USB_DEVICE_EP_CALLBACK_N, +}; + +/** + * \brief Device Endpoint types. + */ +enum usb_device_endpoint_type { + USB_DEVICE_ENDPOINT_TYPE_DISABLE, + USB_DEVICE_ENDPOINT_TYPE_CONTROL, + USB_DEVICE_ENDPOINT_TYPE_ISOCHRONOUS, + USB_DEVICE_ENDPOINT_TYPE_BULK, + USB_DEVICE_ENDPOINT_TYPE_INTERRUPT, +}; + +/** + * \brief Endpoint Size + */ +enum usb_endpoint_size { + USB_ENDPOINT_8_BYTE, + USB_ENDPOINT_16_BYTE, + USB_ENDPOINT_32_BYTE, + USB_ENDPOINT_64_BYTE, + USB_ENDPOINT_128_BYTE, + USB_ENDPOINT_256_BYTE, + USB_ENDPOINT_512_BYTE, + USB_ENDPOINT_1023_BYTE, +}; + +/** + * \brief Link Power Management Handshake. + */ +enum usb_device_lpm_mode { + USB_DEVICE_LPM_NOT_SUPPORT, + USB_DEVICE_LPM_ACK, + USB_DEVICE_LPM_NYET, +}; + +/** + * \brief Module structure + */ +struct usb_module; + +/** + * \name Host callback functions types + * @{ + */ +typedef void (*usb_host_callback_t)(struct usb_module *module_inst); +typedef void (*usb_host_pipe_callback_t)(struct usb_module *module_inst, void *); +/** @} */ + +/** + * \name Device callback functions types + * @{ + */ +typedef void (*usb_device_callback_t)(struct usb_module *module_inst, void* pointer); +typedef void (*usb_device_endpoint_callback_t)(struct usb_module *module_inst, void* pointer); +/** @} */ + + +/** USB configurations */ +struct usb_config { + /** \c true for host, \c false for device. */ + bool select_host_mode; + /** When \c true the module is enabled during standby. */ + bool run_in_standby; + /** Generic Clock Generator source channel. */ + enum gclk_generator source_generator; + /** Speed mode */ + enum usb_speed speed_mode; +}; + +/** + * \brief USB software module instance structure. + * + * USB software module instance structure, used to retain software state + * information of an associated hardware module instance. + * + */ +struct usb_module { + /** Hardware module pointer of the associated USB peripheral. */ + Usb *hw; + + /** Array to store host related callback functions */ + usb_host_callback_t host_callback[USB_HOST_CALLBACK_N]; + usb_host_pipe_callback_t host_pipe_callback[USB_PIPE_NUM][USB_HOST_PIPE_CALLBACK_N]; + /** Bit mask for host callbacks registered */ + uint8_t host_registered_callback_mask; + /** Bit mask for host callbacks enabled */ + uint8_t host_enabled_callback_mask; + /** Bit mask for host pipe callbacks registered */ + uint8_t host_pipe_registered_callback_mask[USB_PIPE_NUM]; + /** Bit mask for host pipe callbacks enabled */ + uint8_t host_pipe_enabled_callback_mask[USB_PIPE_NUM]; + + /** Array to store device related callback functions */ + usb_device_callback_t device_callback[USB_DEVICE_CALLBACK_N]; + usb_device_endpoint_callback_t device_endpoint_callback[USB_EPT_NUM][USB_DEVICE_EP_CALLBACK_N]; + /** Bit mask for device callbacks registered */ + uint16_t device_registered_callback_mask; + /** Bit mask for device callbacks enabled */ + uint16_t device_enabled_callback_mask; + /** Bit mask for device endpoint callbacks registered */ + uint8_t deivce_endpoint_registered_callback_mask[USB_EPT_NUM]; + /** Bit mask for device endpoint callbacks enabled */ + uint8_t device_endpoint_enabled_callback_mask[USB_EPT_NUM]; +}; + +/** USB host pipe configurations */ +struct usb_host_pipe_config { + /** device address */ + uint8_t device_address; + /** endpoint address */ + uint8_t endpoint_address; + /** Pipe type */ + enum usb_host_pipe_type pipe_type; + /** interval */ + uint8_t binterval; + /** pipe size */ + uint16_t size; +}; + +/** USB device endpoint configurations */ +struct usb_device_endpoint_config { + /** device address */ + uint8_t ep_address; + /** endpoint size */ + enum usb_endpoint_size ep_size; + /** automatic zero length packet mode, \c true to enable */ + bool auto_zlp; + /** type of endpoint with Bank */ + enum usb_device_endpoint_type ep_type; +}; + +/** USB host pipe callback status parameter structure */ +struct usb_pipe_callback_parameter { + /** current pipe number */ + uint8_t pipe_num; + /** pipe error status */ + uint8_t pipe_error_status; + /** actual transferred data size */ + uint16_t transfered_size; + /** required data size */ + uint16_t required_size; +}; + +/** USB device endpoint callback status parameter structure */ +struct usb_endpoint_callback_parameter { + uint16_t received_bytes; + uint16_t sent_bytes; + uint16_t out_buffer_size; + uint8_t endpoint_address; +}; + +void usb_enable(struct usb_module *module_inst); +void usb_disable(struct usb_module *module_inst); +/** + * \brief Get the status of USB module's state machine + * + * \param module_inst Pointer to USB module instance + */ +static inline uint8_t usb_get_state_machine_status(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + return module_inst->hw->HOST.FSMSTATUS.reg; +} + +void usb_get_config_defaults(struct usb_config *module_config); +enum status_code usb_init(struct usb_module *module_inst, Usb *const hw, + struct usb_config *module_config); + +/** + * \brief Enable the USB host by setting the VBUS OK + * + * \param module_inst Pointer to USB software instance struct + */ +static inline void usb_host_enable(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.CTRLB.bit.VBUSOK = 1; +} + +/** + * \brief Send the USB reset + * + * \param module_inst Pointer to USB software instance struct + */ +static inline void usb_host_send_reset(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.CTRLB.bit.BUSRESET = 1; +} + +/** + * \brief Enable the USB SOF generation + * + * \param module_inst Pointer to USB software instance struct + */ +static inline void usb_host_enable_sof(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.CTRLB.bit.SOFE = 1; +} + +/** + * \brief Disable the USB SOF generation + * + * \param module_inst Pointer to USB software instance struct + */ +static inline void usb_host_disable_sof(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.CTRLB.bit.SOFE = 0; +} + +/** + * \brief Check the USB SOF generation status + * + * \param module_inst Pointer to USB software instance struct + * + * \return USB SOF generation status, \c true if SOF generation is ON. + */ +static inline bool usb_host_is_sof_enabled(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + return module_inst->hw->HOST.CTRLB.bit.SOFE; +} + +/** + * \brief Send the USB host resume + * + * \param module_inst Pointer to USB software instance struct + */ +static inline void usb_host_send_resume(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.CTRLB.bit.RESUME= 1; +} + +/** + * \brief Send the USB host LPM resume + * + * \param module_inst Pointer to USB software instance struct + */ +static inline void usb_host_send_l1_resume(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.CTRLB.bit.L1RESUME = 1; +} + +/** + * \brief Get the speed mode of USB host + * + * \param module_inst Pointer to USB module instance struct + * + * \return USB speed mode (\ref usb_speed) + */ +static inline enum usb_speed usb_host_get_speed(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + if (module_inst->hw->HOST.STATUS.bit.SPEED == 0) { + return USB_SPEED_FULL; + } else { + return USB_SPEED_LOW; + } +} + +/** + * \brief Get the frame number + * + * \param module_inst Pointer to USB software instance struct + * + * \return frame number value + */ +static inline uint16_t usb_host_get_frame_number(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + return (uint16_t)(module_inst->hw->HOST.FNUM.bit.FNUM); +} + +/** + * \brief Attach USB device to the bus + * + * \param module_inst Pointer to USB device module instance + */ +static inline void usb_device_attach(struct usb_module *module_inst) +{ + module_inst->hw->DEVICE.CTRLB.reg &= ~USB_DEVICE_CTRLB_DETACH; +} + +/** + * \brief Detach USB device from the bus + * + * \param module_inst Pointer to USB device module instance + */ +static inline void usb_device_detach(struct usb_module *module_inst) +{ + module_inst->hw->DEVICE.CTRLB.reg |= USB_DEVICE_CTRLB_DETACH; +} + +/** + * \brief Get the speed mode of USB device + * + * \param module_inst Pointer to USB device module instance + * \return USB Speed mode (\ref usb_speed) + */ +static inline enum usb_speed usb_device_get_speed(struct usb_module *module_inst) +{ + if (!(module_inst->hw->DEVICE.STATUS.reg & USB_DEVICE_STATUS_SPEED_Msk)) { + return USB_SPEED_FULL; + } else { + return USB_SPEED_LOW; + } +} + +/** + * \brief Get the address of USB device + * + * \param module_inst Pointer to USB device module instance + * \return USB device address value + */ +static inline uint8_t usb_device_get_address(struct usb_module *module_inst) +{ + return ((uint8_t)(module_inst->hw->DEVICE.DADD.bit.DADD)); +} + +/** + * \brief Set the speed mode of USB device + * + * \param module_inst Pointer to USB device module instance + * \param address USB device address value + */ +static inline void usb_device_set_address(struct usb_module *module_inst, uint8_t address) +{ + module_inst->hw->DEVICE.DADD.reg = USB_DEVICE_DADD_ADDEN | address; +} + +/** + * \brief Get the frame number of USB device + * + * \param module_inst Pointer to USB device module instance + * \return USB device frame number value + */ +static inline uint16_t usb_device_get_frame_number(struct usb_module *module_inst) +{ + return ((uint16_t)(module_inst->hw->DEVICE.FNUM.bit.FNUM)); +} + +/** + * \brief Get the micro-frame number of USB device + * + * \param module_inst Pointer to USB device module instance + * \return USB device micro-frame number value + */ +static inline uint16_t usb_device_get_micro_frame_number(struct usb_module *module_inst) +{ + return ((uint16_t)(module_inst->hw->DEVICE.FNUM.reg)); +} + +/** + * \brief USB device send the resume wakeup + * + * \param module_inst Pointer to USB device module instance + */ +static inline void usb_device_send_remote_wake_up(struct usb_module *module_inst) +{ + module_inst->hw->DEVICE.CTRLB.reg |= USB_DEVICE_CTRLB_UPRSM; +} + +/** + * \brief USB device set the LPM mode + * + * \param module_inst Pointer to USB device module instance + * \param lpm_mode LPM mode + */ +static inline void usb_device_set_lpm_mode(struct usb_module *module_inst, + enum usb_device_lpm_mode lpm_mode) +{ + module_inst->hw->DEVICE.CTRLB.bit.LPMHDSK = lpm_mode; +} + +/** + * \name USB Host Callback management + * @{ + */ +enum status_code usb_host_register_callback(struct usb_module *module_inst, + enum usb_host_callback callback_type, + usb_host_callback_t callback_func); +enum status_code usb_host_unregister_callback(struct usb_module *module_inst, + enum usb_host_callback callback_type); +enum status_code usb_host_enable_callback(struct usb_module *module_inst, + enum usb_host_callback callback_type); +enum status_code usb_host_disable_callback(struct usb_module *module_inst, + enum usb_host_callback callback_type); +/** @} */ + +/** + * \name USB Device Callback management + * @{ + */ +enum status_code usb_device_register_callback(struct usb_module *module_inst, + enum usb_device_callback callback_type, + usb_device_callback_t callback_func); +enum status_code usb_device_unregister_callback(struct usb_module *module_inst, + enum usb_device_callback callback_type); +enum status_code usb_device_enable_callback(struct usb_module *module_inst, + enum usb_device_callback callback_type); +enum status_code usb_device_disable_callback(struct usb_module *module_inst, + enum usb_device_callback callback_type); +/** @} */ + +/** + * \name USB Host Pipe configuration + * @{ + */ +void usb_host_pipe_get_config_defaults(struct usb_host_pipe_config *ep_config); +enum status_code usb_host_pipe_set_config(struct usb_module *module_inst, uint8_t pipe_num, + struct usb_host_pipe_config *ep_config); +enum status_code usb_host_pipe_get_config(struct usb_module *module_inst, uint8_t pipe_num, + struct usb_host_pipe_config *ep_config); +/** @} */ + +/** + * \name USB Device Endpoint Configuration + * @{ + */ +void usb_device_endpoint_get_config_defaults(struct usb_device_endpoint_config *ep_config); +enum status_code usb_device_endpoint_set_config(struct usb_module *module_inst, + struct usb_device_endpoint_config *ep_config); +bool usb_device_endpoint_is_configured(struct usb_module *module_inst, uint8_t ep); +/** @} */ + +/** + * \name USB Host Pipe Callback management + * @{ + */ +enum status_code usb_host_pipe_register_callback( + struct usb_module *module_inst, uint8_t pipe_num, + enum usb_host_pipe_callback callback_type, + usb_host_pipe_callback_t callback_func); +enum status_code usb_host_pipe_unregister_callback( + struct usb_module *module_inst, uint8_t pipe_num, + enum usb_host_pipe_callback callback_type); +enum status_code usb_host_pipe_enable_callback( + struct usb_module *module_inst, uint8_t pipe_num, + enum usb_host_pipe_callback callback_type); +enum status_code usb_host_pipe_disable_callback( + struct usb_module *module_inst, uint8_t pipe_num, + enum usb_host_pipe_callback callback_type); +/** @} */ + +/** + * \name USB Device Endpoint Callback management + * @{ + */ +enum status_code usb_device_endpoint_register_callback( + struct usb_module *module_inst, uint8_t ep_num, + enum usb_device_endpoint_callback callback_type, + usb_device_endpoint_callback_t callback_func); +enum status_code usb_device_endpoint_unregister_callback( + struct usb_module *module_inst, uint8_t ep_num, + enum usb_device_endpoint_callback callback_type); +enum status_code usb_device_endpoint_enable_callback( + struct usb_module *module_inst, uint8_t ep, + enum usb_device_endpoint_callback callback_type); +enum status_code usb_device_endpoint_disable_callback( + struct usb_module *module_inst, uint8_t ep, + enum usb_device_endpoint_callback callback_type); +/** @} */ + +/** + * \name USB Host Pipe Job management + * @{ + */ +enum status_code usb_host_pipe_setup_job(struct usb_module *module_inst, + uint8_t pipe_num, uint8_t *buf); +enum status_code usb_host_pipe_read_job(struct usb_module *module_inst, + uint8_t pipe_num, uint8_t *buf, uint32_t buf_size); +enum status_code usb_host_pipe_write_job(struct usb_module *module_inst, + uint8_t pipe_num, uint8_t *buf, uint32_t buf_size); +enum status_code usb_host_pipe_abort_job(struct usb_module *module_inst, uint8_t pipe_num); +enum status_code usb_host_pipe_lpm_job(struct usb_module *module_inst, + uint8_t pipe_num, bool b_remotewakeup, uint8_t besl); +/** @} */ + +/** + * \name USB Device Endpoint Job management + * @{ + */ +enum status_code usb_device_endpoint_write_buffer_job(struct usb_module *module_inst,uint8_t ep_num, + uint8_t* pbuf, uint32_t buf_size); +enum status_code usb_device_endpoint_read_buffer_job(struct usb_module *module_inst,uint8_t ep_num, + uint8_t* pbuf, uint32_t buf_size); +enum status_code usb_device_endpoint_setup_buffer_job(struct usb_module *module_inst, + uint8_t* pbuf); +void usb_device_endpoint_abort_job(struct usb_module *module_inst, uint8_t ep); +/** @} */ + +/** + * \name USB Host Pipe Operations + * @{ + */ + +/** + * \brief Freeze a pipe + * + * \param module_inst Pointer to USB module instance + * \param pipe_num Pipe number + */ +static inline void usb_host_pipe_freeze(struct usb_module *module_inst, uint8_t pipe_num) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSSET.reg = USB_HOST_PSTATUSSET_PFREEZE; +} + +/** + * \brief Unfreeze a pipe + * + * \param module_inst Pointer to USB module instance + * \param pipe_num Pipe number + */ +static inline void usb_host_pipe_unfreeze(struct usb_module *module_inst, uint8_t pipe_num) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSCLR.reg = USB_HOST_PSTATUSCLR_PFREEZE; +} + +/** + * \brief Check if the pipe is frozen + * + * \param module_inst Pointer to USB module instance + * \param pipe_num Pipe number + */ +static inline bool usb_host_pipe_is_frozen(struct usb_module *module_inst, uint8_t pipe_num) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + return (module_inst->hw->HOST.HostPipe[pipe_num].PSTATUS.bit.PFREEZE == 1); +} + +/** + * \brief Set the data toggle bit of pipe + * + * \param module_inst Pointer to USB module instance + * \param pipe_num Pipe number + */ +static inline void usb_host_pipe_set_toggle(struct usb_module *module_inst, uint8_t pipe_num) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSSET.reg = USB_HOST_PSTATUSSET_DTGL; +} + +/** + * \brief Clear the data toggle bit of pipe + * + * \param module_inst Pointer to USB module instance + * \param pipe_num Pipe number + */ +static inline void usb_host_pipe_clear_toggle(struct usb_module *module_inst, uint8_t pipe_num) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSCLR.reg = USB_HOST_PSTATUSCLR_DTGL; +} + +/** + * \brief Set the auto zero length packet of pipe + * + * \param module_inst Pointer to USB module instance + * \param pipe_num Pipe number + * \param value \c true to enable auto ZLP and \c false to disable + */ +void usb_host_pipe_set_auto_zlp(struct usb_module *module_inst, uint8_t pipe_num, bool value); + +/** @} */ + +/** + * \name USB Device Endpoint Operations + * @{ + */ + +bool usb_device_endpoint_is_halted(struct usb_module *module_inst, uint8_t ep); +void usb_device_endpoint_set_halt(struct usb_module *module_inst, uint8_t ep); +void usb_device_endpoint_clear_halt(struct usb_module *module_inst, uint8_t ep); + +/** @} */ + +#ifdef __cplusplus +} +#endif + +#endif /* USB_H_INCLUDED */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/ac.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/ac.h new file mode 100644 index 0000000..6b12da1 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/ac.h @@ -0,0 +1,559 @@ +/** + * \file + * + * \brief Component description for AC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_AC_COMPONENT_ +#define _SAMD21_AC_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR AC */ +/* ========================================================================== */ +/** \addtogroup SAMD21_AC Analog Comparators */ +/*@{*/ + +#define AC_U2205 +#define REV_AC 0x111 + +/* -------- AC_CTRLA : (AC Offset: 0x00) (R/W 8) Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset */ + uint8_t ENABLE:1; /*!< bit: 1 Enable */ + uint8_t RUNSTDBY:1; /*!< bit: 2 Run in Standby */ + uint8_t :4; /*!< bit: 3.. 6 Reserved */ + uint8_t LPMUX:1; /*!< bit: 7 Low-Power Mux */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} AC_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_CTRLA_OFFSET 0x00 /**< \brief (AC_CTRLA offset) Control A */ +#define AC_CTRLA_RESETVALUE 0x00 /**< \brief (AC_CTRLA reset_value) Control A */ + +#define AC_CTRLA_SWRST_Pos 0 /**< \brief (AC_CTRLA) Software Reset */ +#define AC_CTRLA_SWRST (0x1u << AC_CTRLA_SWRST_Pos) +#define AC_CTRLA_ENABLE_Pos 1 /**< \brief (AC_CTRLA) Enable */ +#define AC_CTRLA_ENABLE (0x1u << AC_CTRLA_ENABLE_Pos) +#define AC_CTRLA_RUNSTDBY_Pos 2 /**< \brief (AC_CTRLA) Run in Standby */ +#define AC_CTRLA_RUNSTDBY_Msk (0x1u << AC_CTRLA_RUNSTDBY_Pos) +#define AC_CTRLA_RUNSTDBY(value) ((AC_CTRLA_RUNSTDBY_Msk & ((value) << AC_CTRLA_RUNSTDBY_Pos))) +#define AC_CTRLA_LPMUX_Pos 7 /**< \brief (AC_CTRLA) Low-Power Mux */ +#define AC_CTRLA_LPMUX (0x1u << AC_CTRLA_LPMUX_Pos) +#define AC_CTRLA_MASK 0x87u /**< \brief (AC_CTRLA) MASK Register */ + +/* -------- AC_CTRLB : (AC Offset: 0x01) ( /W 8) Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t START0:1; /*!< bit: 0 Comparator 0 Start Comparison */ + uint8_t START1:1; /*!< bit: 1 Comparator 1 Start Comparison */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t START:2; /*!< bit: 0.. 1 Comparator x Start Comparison */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} AC_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_CTRLB_OFFSET 0x01 /**< \brief (AC_CTRLB offset) Control B */ +#define AC_CTRLB_RESETVALUE 0x00 /**< \brief (AC_CTRLB reset_value) Control B */ + +#define AC_CTRLB_START0_Pos 0 /**< \brief (AC_CTRLB) Comparator 0 Start Comparison */ +#define AC_CTRLB_START0 (1 << AC_CTRLB_START0_Pos) +#define AC_CTRLB_START1_Pos 1 /**< \brief (AC_CTRLB) Comparator 1 Start Comparison */ +#define AC_CTRLB_START1 (1 << AC_CTRLB_START1_Pos) +#define AC_CTRLB_START_Pos 0 /**< \brief (AC_CTRLB) Comparator x Start Comparison */ +#define AC_CTRLB_START_Msk (0x3u << AC_CTRLB_START_Pos) +#define AC_CTRLB_START(value) ((AC_CTRLB_START_Msk & ((value) << AC_CTRLB_START_Pos))) +#define AC_CTRLB_MASK 0x03u /**< \brief (AC_CTRLB) MASK Register */ + +/* -------- AC_EVCTRL : (AC Offset: 0x02) (R/W 16) Event Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t COMPEO0:1; /*!< bit: 0 Comparator 0 Event Output Enable */ + uint16_t COMPEO1:1; /*!< bit: 1 Comparator 1 Event Output Enable */ + uint16_t :2; /*!< bit: 2.. 3 Reserved */ + uint16_t WINEO0:1; /*!< bit: 4 Window 0 Event Output Enable */ + uint16_t :3; /*!< bit: 5.. 7 Reserved */ + uint16_t COMPEI0:1; /*!< bit: 8 Comparator 0 Event Input */ + uint16_t COMPEI1:1; /*!< bit: 9 Comparator 1 Event Input */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t COMPEO:2; /*!< bit: 0.. 1 Comparator x Event Output Enable */ + uint16_t :2; /*!< bit: 2.. 3 Reserved */ + uint16_t WINEO:1; /*!< bit: 4 Window x Event Output Enable */ + uint16_t :3; /*!< bit: 5.. 7 Reserved */ + uint16_t COMPEI:2; /*!< bit: 8.. 9 Comparator x Event Input */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} AC_EVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_EVCTRL_OFFSET 0x02 /**< \brief (AC_EVCTRL offset) Event Control */ +#define AC_EVCTRL_RESETVALUE 0x0000 /**< \brief (AC_EVCTRL reset_value) Event Control */ + +#define AC_EVCTRL_COMPEO0_Pos 0 /**< \brief (AC_EVCTRL) Comparator 0 Event Output Enable */ +#define AC_EVCTRL_COMPEO0 (1 << AC_EVCTRL_COMPEO0_Pos) +#define AC_EVCTRL_COMPEO1_Pos 1 /**< \brief (AC_EVCTRL) Comparator 1 Event Output Enable */ +#define AC_EVCTRL_COMPEO1 (1 << AC_EVCTRL_COMPEO1_Pos) +#define AC_EVCTRL_COMPEO_Pos 0 /**< \brief (AC_EVCTRL) Comparator x Event Output Enable */ +#define AC_EVCTRL_COMPEO_Msk (0x3u << AC_EVCTRL_COMPEO_Pos) +#define AC_EVCTRL_COMPEO(value) ((AC_EVCTRL_COMPEO_Msk & ((value) << AC_EVCTRL_COMPEO_Pos))) +#define AC_EVCTRL_WINEO0_Pos 4 /**< \brief (AC_EVCTRL) Window 0 Event Output Enable */ +#define AC_EVCTRL_WINEO0 (1 << AC_EVCTRL_WINEO0_Pos) +#define AC_EVCTRL_WINEO_Pos 4 /**< \brief (AC_EVCTRL) Window x Event Output Enable */ +#define AC_EVCTRL_WINEO_Msk (0x1u << AC_EVCTRL_WINEO_Pos) +#define AC_EVCTRL_WINEO(value) ((AC_EVCTRL_WINEO_Msk & ((value) << AC_EVCTRL_WINEO_Pos))) +#define AC_EVCTRL_COMPEI0_Pos 8 /**< \brief (AC_EVCTRL) Comparator 0 Event Input */ +#define AC_EVCTRL_COMPEI0 (1 << AC_EVCTRL_COMPEI0_Pos) +#define AC_EVCTRL_COMPEI1_Pos 9 /**< \brief (AC_EVCTRL) Comparator 1 Event Input */ +#define AC_EVCTRL_COMPEI1 (1 << AC_EVCTRL_COMPEI1_Pos) +#define AC_EVCTRL_COMPEI_Pos 8 /**< \brief (AC_EVCTRL) Comparator x Event Input */ +#define AC_EVCTRL_COMPEI_Msk (0x3u << AC_EVCTRL_COMPEI_Pos) +#define AC_EVCTRL_COMPEI(value) ((AC_EVCTRL_COMPEI_Msk & ((value) << AC_EVCTRL_COMPEI_Pos))) +#define AC_EVCTRL_MASK 0x0313u /**< \brief (AC_EVCTRL) MASK Register */ + +/* -------- AC_INTENCLR : (AC Offset: 0x04) (R/W 8) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t COMP0:1; /*!< bit: 0 Comparator 0 Interrupt Enable */ + uint8_t COMP1:1; /*!< bit: 1 Comparator 1 Interrupt Enable */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t WIN0:1; /*!< bit: 4 Window 0 Interrupt Enable */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t COMP:2; /*!< bit: 0.. 1 Comparator x Interrupt Enable */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t WIN:1; /*!< bit: 4 Window x Interrupt Enable */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} AC_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_INTENCLR_OFFSET 0x04 /**< \brief (AC_INTENCLR offset) Interrupt Enable Clear */ +#define AC_INTENCLR_RESETVALUE 0x00 /**< \brief (AC_INTENCLR reset_value) Interrupt Enable Clear */ + +#define AC_INTENCLR_COMP0_Pos 0 /**< \brief (AC_INTENCLR) Comparator 0 Interrupt Enable */ +#define AC_INTENCLR_COMP0 (1 << AC_INTENCLR_COMP0_Pos) +#define AC_INTENCLR_COMP1_Pos 1 /**< \brief (AC_INTENCLR) Comparator 1 Interrupt Enable */ +#define AC_INTENCLR_COMP1 (1 << AC_INTENCLR_COMP1_Pos) +#define AC_INTENCLR_COMP_Pos 0 /**< \brief (AC_INTENCLR) Comparator x Interrupt Enable */ +#define AC_INTENCLR_COMP_Msk (0x3u << AC_INTENCLR_COMP_Pos) +#define AC_INTENCLR_COMP(value) ((AC_INTENCLR_COMP_Msk & ((value) << AC_INTENCLR_COMP_Pos))) +#define AC_INTENCLR_WIN0_Pos 4 /**< \brief (AC_INTENCLR) Window 0 Interrupt Enable */ +#define AC_INTENCLR_WIN0 (1 << AC_INTENCLR_WIN0_Pos) +#define AC_INTENCLR_WIN_Pos 4 /**< \brief (AC_INTENCLR) Window x Interrupt Enable */ +#define AC_INTENCLR_WIN_Msk (0x1u << AC_INTENCLR_WIN_Pos) +#define AC_INTENCLR_WIN(value) ((AC_INTENCLR_WIN_Msk & ((value) << AC_INTENCLR_WIN_Pos))) +#define AC_INTENCLR_MASK 0x13u /**< \brief (AC_INTENCLR) MASK Register */ + +/* -------- AC_INTENSET : (AC Offset: 0x05) (R/W 8) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t COMP0:1; /*!< bit: 0 Comparator 0 Interrupt Enable */ + uint8_t COMP1:1; /*!< bit: 1 Comparator 1 Interrupt Enable */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t WIN0:1; /*!< bit: 4 Window 0 Interrupt Enable */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t COMP:2; /*!< bit: 0.. 1 Comparator x Interrupt Enable */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t WIN:1; /*!< bit: 4 Window x Interrupt Enable */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} AC_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_INTENSET_OFFSET 0x05 /**< \brief (AC_INTENSET offset) Interrupt Enable Set */ +#define AC_INTENSET_RESETVALUE 0x00 /**< \brief (AC_INTENSET reset_value) Interrupt Enable Set */ + +#define AC_INTENSET_COMP0_Pos 0 /**< \brief (AC_INTENSET) Comparator 0 Interrupt Enable */ +#define AC_INTENSET_COMP0 (1 << AC_INTENSET_COMP0_Pos) +#define AC_INTENSET_COMP1_Pos 1 /**< \brief (AC_INTENSET) Comparator 1 Interrupt Enable */ +#define AC_INTENSET_COMP1 (1 << AC_INTENSET_COMP1_Pos) +#define AC_INTENSET_COMP_Pos 0 /**< \brief (AC_INTENSET) Comparator x Interrupt Enable */ +#define AC_INTENSET_COMP_Msk (0x3u << AC_INTENSET_COMP_Pos) +#define AC_INTENSET_COMP(value) ((AC_INTENSET_COMP_Msk & ((value) << AC_INTENSET_COMP_Pos))) +#define AC_INTENSET_WIN0_Pos 4 /**< \brief (AC_INTENSET) Window 0 Interrupt Enable */ +#define AC_INTENSET_WIN0 (1 << AC_INTENSET_WIN0_Pos) +#define AC_INTENSET_WIN_Pos 4 /**< \brief (AC_INTENSET) Window x Interrupt Enable */ +#define AC_INTENSET_WIN_Msk (0x1u << AC_INTENSET_WIN_Pos) +#define AC_INTENSET_WIN(value) ((AC_INTENSET_WIN_Msk & ((value) << AC_INTENSET_WIN_Pos))) +#define AC_INTENSET_MASK 0x13u /**< \brief (AC_INTENSET) MASK Register */ + +/* -------- AC_INTFLAG : (AC Offset: 0x06) (R/W 8) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t COMP0:1; /*!< bit: 0 Comparator 0 */ + uint8_t COMP1:1; /*!< bit: 1 Comparator 1 */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t WIN0:1; /*!< bit: 4 Window 0 */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t COMP:2; /*!< bit: 0.. 1 Comparator x */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t WIN:1; /*!< bit: 4 Window x */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} AC_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_INTFLAG_OFFSET 0x06 /**< \brief (AC_INTFLAG offset) Interrupt Flag Status and Clear */ +#define AC_INTFLAG_RESETVALUE 0x00 /**< \brief (AC_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define AC_INTFLAG_COMP0_Pos 0 /**< \brief (AC_INTFLAG) Comparator 0 */ +#define AC_INTFLAG_COMP0 (1 << AC_INTFLAG_COMP0_Pos) +#define AC_INTFLAG_COMP1_Pos 1 /**< \brief (AC_INTFLAG) Comparator 1 */ +#define AC_INTFLAG_COMP1 (1 << AC_INTFLAG_COMP1_Pos) +#define AC_INTFLAG_COMP_Pos 0 /**< \brief (AC_INTFLAG) Comparator x */ +#define AC_INTFLAG_COMP_Msk (0x3u << AC_INTFLAG_COMP_Pos) +#define AC_INTFLAG_COMP(value) ((AC_INTFLAG_COMP_Msk & ((value) << AC_INTFLAG_COMP_Pos))) +#define AC_INTFLAG_WIN0_Pos 4 /**< \brief (AC_INTFLAG) Window 0 */ +#define AC_INTFLAG_WIN0 (1 << AC_INTFLAG_WIN0_Pos) +#define AC_INTFLAG_WIN_Pos 4 /**< \brief (AC_INTFLAG) Window x */ +#define AC_INTFLAG_WIN_Msk (0x1u << AC_INTFLAG_WIN_Pos) +#define AC_INTFLAG_WIN(value) ((AC_INTFLAG_WIN_Msk & ((value) << AC_INTFLAG_WIN_Pos))) +#define AC_INTFLAG_MASK 0x13u /**< \brief (AC_INTFLAG) MASK Register */ + +/* -------- AC_STATUSA : (AC Offset: 0x08) (R/ 8) Status A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t STATE0:1; /*!< bit: 0 Comparator 0 Current State */ + uint8_t STATE1:1; /*!< bit: 1 Comparator 1 Current State */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t WSTATE0:2; /*!< bit: 4.. 5 Window 0 Current State */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t STATE:2; /*!< bit: 0.. 1 Comparator x Current State */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} AC_STATUSA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_STATUSA_OFFSET 0x08 /**< \brief (AC_STATUSA offset) Status A */ +#define AC_STATUSA_RESETVALUE 0x00 /**< \brief (AC_STATUSA reset_value) Status A */ + +#define AC_STATUSA_STATE0_Pos 0 /**< \brief (AC_STATUSA) Comparator 0 Current State */ +#define AC_STATUSA_STATE0 (1 << AC_STATUSA_STATE0_Pos) +#define AC_STATUSA_STATE1_Pos 1 /**< \brief (AC_STATUSA) Comparator 1 Current State */ +#define AC_STATUSA_STATE1 (1 << AC_STATUSA_STATE1_Pos) +#define AC_STATUSA_STATE_Pos 0 /**< \brief (AC_STATUSA) Comparator x Current State */ +#define AC_STATUSA_STATE_Msk (0x3u << AC_STATUSA_STATE_Pos) +#define AC_STATUSA_STATE(value) ((AC_STATUSA_STATE_Msk & ((value) << AC_STATUSA_STATE_Pos))) +#define AC_STATUSA_WSTATE0_Pos 4 /**< \brief (AC_STATUSA) Window 0 Current State */ +#define AC_STATUSA_WSTATE0_Msk (0x3u << AC_STATUSA_WSTATE0_Pos) +#define AC_STATUSA_WSTATE0(value) ((AC_STATUSA_WSTATE0_Msk & ((value) << AC_STATUSA_WSTATE0_Pos))) +#define AC_STATUSA_WSTATE0_ABOVE_Val 0x0u /**< \brief (AC_STATUSA) Signal is above window */ +#define AC_STATUSA_WSTATE0_INSIDE_Val 0x1u /**< \brief (AC_STATUSA) Signal is inside window */ +#define AC_STATUSA_WSTATE0_BELOW_Val 0x2u /**< \brief (AC_STATUSA) Signal is below window */ +#define AC_STATUSA_WSTATE0_ABOVE (AC_STATUSA_WSTATE0_ABOVE_Val << AC_STATUSA_WSTATE0_Pos) +#define AC_STATUSA_WSTATE0_INSIDE (AC_STATUSA_WSTATE0_INSIDE_Val << AC_STATUSA_WSTATE0_Pos) +#define AC_STATUSA_WSTATE0_BELOW (AC_STATUSA_WSTATE0_BELOW_Val << AC_STATUSA_WSTATE0_Pos) +#define AC_STATUSA_MASK 0x33u /**< \brief (AC_STATUSA) MASK Register */ + +/* -------- AC_STATUSB : (AC Offset: 0x09) (R/ 8) Status B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t READY0:1; /*!< bit: 0 Comparator 0 Ready */ + uint8_t READY1:1; /*!< bit: 1 Comparator 1 Ready */ + uint8_t :5; /*!< bit: 2.. 6 Reserved */ + uint8_t SYNCBUSY:1; /*!< bit: 7 Synchronization Busy */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t READY:2; /*!< bit: 0.. 1 Comparator x Ready */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} AC_STATUSB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_STATUSB_OFFSET 0x09 /**< \brief (AC_STATUSB offset) Status B */ +#define AC_STATUSB_RESETVALUE 0x00 /**< \brief (AC_STATUSB reset_value) Status B */ + +#define AC_STATUSB_READY0_Pos 0 /**< \brief (AC_STATUSB) Comparator 0 Ready */ +#define AC_STATUSB_READY0 (1 << AC_STATUSB_READY0_Pos) +#define AC_STATUSB_READY1_Pos 1 /**< \brief (AC_STATUSB) Comparator 1 Ready */ +#define AC_STATUSB_READY1 (1 << AC_STATUSB_READY1_Pos) +#define AC_STATUSB_READY_Pos 0 /**< \brief (AC_STATUSB) Comparator x Ready */ +#define AC_STATUSB_READY_Msk (0x3u << AC_STATUSB_READY_Pos) +#define AC_STATUSB_READY(value) ((AC_STATUSB_READY_Msk & ((value) << AC_STATUSB_READY_Pos))) +#define AC_STATUSB_SYNCBUSY_Pos 7 /**< \brief (AC_STATUSB) Synchronization Busy */ +#define AC_STATUSB_SYNCBUSY (0x1u << AC_STATUSB_SYNCBUSY_Pos) +#define AC_STATUSB_MASK 0x83u /**< \brief (AC_STATUSB) MASK Register */ + +/* -------- AC_STATUSC : (AC Offset: 0x0A) (R/ 8) Status C -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t STATE0:1; /*!< bit: 0 Comparator 0 Current State */ + uint8_t STATE1:1; /*!< bit: 1 Comparator 1 Current State */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t WSTATE0:2; /*!< bit: 4.. 5 Window 0 Current State */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t STATE:2; /*!< bit: 0.. 1 Comparator x Current State */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} AC_STATUSC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_STATUSC_OFFSET 0x0A /**< \brief (AC_STATUSC offset) Status C */ +#define AC_STATUSC_RESETVALUE 0x00 /**< \brief (AC_STATUSC reset_value) Status C */ + +#define AC_STATUSC_STATE0_Pos 0 /**< \brief (AC_STATUSC) Comparator 0 Current State */ +#define AC_STATUSC_STATE0 (1 << AC_STATUSC_STATE0_Pos) +#define AC_STATUSC_STATE1_Pos 1 /**< \brief (AC_STATUSC) Comparator 1 Current State */ +#define AC_STATUSC_STATE1 (1 << AC_STATUSC_STATE1_Pos) +#define AC_STATUSC_STATE_Pos 0 /**< \brief (AC_STATUSC) Comparator x Current State */ +#define AC_STATUSC_STATE_Msk (0x3u << AC_STATUSC_STATE_Pos) +#define AC_STATUSC_STATE(value) ((AC_STATUSC_STATE_Msk & ((value) << AC_STATUSC_STATE_Pos))) +#define AC_STATUSC_WSTATE0_Pos 4 /**< \brief (AC_STATUSC) Window 0 Current State */ +#define AC_STATUSC_WSTATE0_Msk (0x3u << AC_STATUSC_WSTATE0_Pos) +#define AC_STATUSC_WSTATE0(value) ((AC_STATUSC_WSTATE0_Msk & ((value) << AC_STATUSC_WSTATE0_Pos))) +#define AC_STATUSC_WSTATE0_ABOVE_Val 0x0u /**< \brief (AC_STATUSC) Signal is above window */ +#define AC_STATUSC_WSTATE0_INSIDE_Val 0x1u /**< \brief (AC_STATUSC) Signal is inside window */ +#define AC_STATUSC_WSTATE0_BELOW_Val 0x2u /**< \brief (AC_STATUSC) Signal is below window */ +#define AC_STATUSC_WSTATE0_ABOVE (AC_STATUSC_WSTATE0_ABOVE_Val << AC_STATUSC_WSTATE0_Pos) +#define AC_STATUSC_WSTATE0_INSIDE (AC_STATUSC_WSTATE0_INSIDE_Val << AC_STATUSC_WSTATE0_Pos) +#define AC_STATUSC_WSTATE0_BELOW (AC_STATUSC_WSTATE0_BELOW_Val << AC_STATUSC_WSTATE0_Pos) +#define AC_STATUSC_MASK 0x33u /**< \brief (AC_STATUSC) MASK Register */ + +/* -------- AC_WINCTRL : (AC Offset: 0x0C) (R/W 8) Window Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t WEN0:1; /*!< bit: 0 Window 0 Mode Enable */ + uint8_t WINTSEL0:2; /*!< bit: 1.. 2 Window 0 Interrupt Selection */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} AC_WINCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_WINCTRL_OFFSET 0x0C /**< \brief (AC_WINCTRL offset) Window Control */ +#define AC_WINCTRL_RESETVALUE 0x00 /**< \brief (AC_WINCTRL reset_value) Window Control */ + +#define AC_WINCTRL_WEN0_Pos 0 /**< \brief (AC_WINCTRL) Window 0 Mode Enable */ +#define AC_WINCTRL_WEN0 (0x1u << AC_WINCTRL_WEN0_Pos) +#define AC_WINCTRL_WINTSEL0_Pos 1 /**< \brief (AC_WINCTRL) Window 0 Interrupt Selection */ +#define AC_WINCTRL_WINTSEL0_Msk (0x3u << AC_WINCTRL_WINTSEL0_Pos) +#define AC_WINCTRL_WINTSEL0(value) ((AC_WINCTRL_WINTSEL0_Msk & ((value) << AC_WINCTRL_WINTSEL0_Pos))) +#define AC_WINCTRL_WINTSEL0_ABOVE_Val 0x0u /**< \brief (AC_WINCTRL) Interrupt on signal above window */ +#define AC_WINCTRL_WINTSEL0_INSIDE_Val 0x1u /**< \brief (AC_WINCTRL) Interrupt on signal inside window */ +#define AC_WINCTRL_WINTSEL0_BELOW_Val 0x2u /**< \brief (AC_WINCTRL) Interrupt on signal below window */ +#define AC_WINCTRL_WINTSEL0_OUTSIDE_Val 0x3u /**< \brief (AC_WINCTRL) Interrupt on signal outside window */ +#define AC_WINCTRL_WINTSEL0_ABOVE (AC_WINCTRL_WINTSEL0_ABOVE_Val << AC_WINCTRL_WINTSEL0_Pos) +#define AC_WINCTRL_WINTSEL0_INSIDE (AC_WINCTRL_WINTSEL0_INSIDE_Val << AC_WINCTRL_WINTSEL0_Pos) +#define AC_WINCTRL_WINTSEL0_BELOW (AC_WINCTRL_WINTSEL0_BELOW_Val << AC_WINCTRL_WINTSEL0_Pos) +#define AC_WINCTRL_WINTSEL0_OUTSIDE (AC_WINCTRL_WINTSEL0_OUTSIDE_Val << AC_WINCTRL_WINTSEL0_Pos) +#define AC_WINCTRL_MASK 0x07u /**< \brief (AC_WINCTRL) MASK Register */ + +/* -------- AC_COMPCTRL : (AC Offset: 0x10) (R/W 32) Comparator Control n -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t ENABLE:1; /*!< bit: 0 Enable */ + uint32_t SINGLE:1; /*!< bit: 1 Single-Shot Mode */ + uint32_t SPEED:2; /*!< bit: 2.. 3 Speed Selection */ + uint32_t :1; /*!< bit: 4 Reserved */ + uint32_t INTSEL:2; /*!< bit: 5.. 6 Interrupt Selection */ + uint32_t :1; /*!< bit: 7 Reserved */ + uint32_t MUXNEG:3; /*!< bit: 8..10 Negative Input Mux Selection */ + uint32_t :1; /*!< bit: 11 Reserved */ + uint32_t MUXPOS:2; /*!< bit: 12..13 Positive Input Mux Selection */ + uint32_t :1; /*!< bit: 14 Reserved */ + uint32_t SWAP:1; /*!< bit: 15 Swap Inputs and Invert */ + uint32_t OUT:2; /*!< bit: 16..17 Output */ + uint32_t :1; /*!< bit: 18 Reserved */ + uint32_t HYST:1; /*!< bit: 19 Hysteresis Enable */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t FLEN:3; /*!< bit: 24..26 Filter Length */ + uint32_t :5; /*!< bit: 27..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} AC_COMPCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_COMPCTRL_OFFSET 0x10 /**< \brief (AC_COMPCTRL offset) Comparator Control n */ +#define AC_COMPCTRL_RESETVALUE 0x00000000 /**< \brief (AC_COMPCTRL reset_value) Comparator Control n */ + +#define AC_COMPCTRL_ENABLE_Pos 0 /**< \brief (AC_COMPCTRL) Enable */ +#define AC_COMPCTRL_ENABLE (0x1u << AC_COMPCTRL_ENABLE_Pos) +#define AC_COMPCTRL_SINGLE_Pos 1 /**< \brief (AC_COMPCTRL) Single-Shot Mode */ +#define AC_COMPCTRL_SINGLE (0x1u << AC_COMPCTRL_SINGLE_Pos) +#define AC_COMPCTRL_SPEED_Pos 2 /**< \brief (AC_COMPCTRL) Speed Selection */ +#define AC_COMPCTRL_SPEED_Msk (0x3u << AC_COMPCTRL_SPEED_Pos) +#define AC_COMPCTRL_SPEED(value) ((AC_COMPCTRL_SPEED_Msk & ((value) << AC_COMPCTRL_SPEED_Pos))) +#define AC_COMPCTRL_SPEED_LOW_Val 0x0u /**< \brief (AC_COMPCTRL) Low speed */ +#define AC_COMPCTRL_SPEED_HIGH_Val 0x1u /**< \brief (AC_COMPCTRL) High speed */ +#define AC_COMPCTRL_SPEED_LOW (AC_COMPCTRL_SPEED_LOW_Val << AC_COMPCTRL_SPEED_Pos) +#define AC_COMPCTRL_SPEED_HIGH (AC_COMPCTRL_SPEED_HIGH_Val << AC_COMPCTRL_SPEED_Pos) +#define AC_COMPCTRL_INTSEL_Pos 5 /**< \brief (AC_COMPCTRL) Interrupt Selection */ +#define AC_COMPCTRL_INTSEL_Msk (0x3u << AC_COMPCTRL_INTSEL_Pos) +#define AC_COMPCTRL_INTSEL(value) ((AC_COMPCTRL_INTSEL_Msk & ((value) << AC_COMPCTRL_INTSEL_Pos))) +#define AC_COMPCTRL_INTSEL_TOGGLE_Val 0x0u /**< \brief (AC_COMPCTRL) Interrupt on comparator output toggle */ +#define AC_COMPCTRL_INTSEL_RISING_Val 0x1u /**< \brief (AC_COMPCTRL) Interrupt on comparator output rising */ +#define AC_COMPCTRL_INTSEL_FALLING_Val 0x2u /**< \brief (AC_COMPCTRL) Interrupt on comparator output falling */ +#define AC_COMPCTRL_INTSEL_EOC_Val 0x3u /**< \brief (AC_COMPCTRL) Interrupt on end of comparison (single-shot mode only) */ +#define AC_COMPCTRL_INTSEL_TOGGLE (AC_COMPCTRL_INTSEL_TOGGLE_Val << AC_COMPCTRL_INTSEL_Pos) +#define AC_COMPCTRL_INTSEL_RISING (AC_COMPCTRL_INTSEL_RISING_Val << AC_COMPCTRL_INTSEL_Pos) +#define AC_COMPCTRL_INTSEL_FALLING (AC_COMPCTRL_INTSEL_FALLING_Val << AC_COMPCTRL_INTSEL_Pos) +#define AC_COMPCTRL_INTSEL_EOC (AC_COMPCTRL_INTSEL_EOC_Val << AC_COMPCTRL_INTSEL_Pos) +#define AC_COMPCTRL_MUXNEG_Pos 8 /**< \brief (AC_COMPCTRL) Negative Input Mux Selection */ +#define AC_COMPCTRL_MUXNEG_Msk (0x7u << AC_COMPCTRL_MUXNEG_Pos) +#define AC_COMPCTRL_MUXNEG(value) ((AC_COMPCTRL_MUXNEG_Msk & ((value) << AC_COMPCTRL_MUXNEG_Pos))) +#define AC_COMPCTRL_MUXNEG_PIN0_Val 0x0u /**< \brief (AC_COMPCTRL) I/O pin 0 */ +#define AC_COMPCTRL_MUXNEG_PIN1_Val 0x1u /**< \brief (AC_COMPCTRL) I/O pin 1 */ +#define AC_COMPCTRL_MUXNEG_PIN2_Val 0x2u /**< \brief (AC_COMPCTRL) I/O pin 2 */ +#define AC_COMPCTRL_MUXNEG_PIN3_Val 0x3u /**< \brief (AC_COMPCTRL) I/O pin 3 */ +#define AC_COMPCTRL_MUXNEG_GND_Val 0x4u /**< \brief (AC_COMPCTRL) Ground */ +#define AC_COMPCTRL_MUXNEG_VSCALE_Val 0x5u /**< \brief (AC_COMPCTRL) VDD scaler */ +#define AC_COMPCTRL_MUXNEG_BANDGAP_Val 0x6u /**< \brief (AC_COMPCTRL) Internal bandgap voltage */ +#define AC_COMPCTRL_MUXNEG_DAC_Val 0x7u /**< \brief (AC_COMPCTRL) DAC output */ +#define AC_COMPCTRL_MUXNEG_PIN0 (AC_COMPCTRL_MUXNEG_PIN0_Val << AC_COMPCTRL_MUXNEG_Pos) +#define AC_COMPCTRL_MUXNEG_PIN1 (AC_COMPCTRL_MUXNEG_PIN1_Val << AC_COMPCTRL_MUXNEG_Pos) +#define AC_COMPCTRL_MUXNEG_PIN2 (AC_COMPCTRL_MUXNEG_PIN2_Val << AC_COMPCTRL_MUXNEG_Pos) +#define AC_COMPCTRL_MUXNEG_PIN3 (AC_COMPCTRL_MUXNEG_PIN3_Val << AC_COMPCTRL_MUXNEG_Pos) +#define AC_COMPCTRL_MUXNEG_GND (AC_COMPCTRL_MUXNEG_GND_Val << AC_COMPCTRL_MUXNEG_Pos) +#define AC_COMPCTRL_MUXNEG_VSCALE (AC_COMPCTRL_MUXNEG_VSCALE_Val << AC_COMPCTRL_MUXNEG_Pos) +#define AC_COMPCTRL_MUXNEG_BANDGAP (AC_COMPCTRL_MUXNEG_BANDGAP_Val << AC_COMPCTRL_MUXNEG_Pos) +#define AC_COMPCTRL_MUXNEG_DAC (AC_COMPCTRL_MUXNEG_DAC_Val << AC_COMPCTRL_MUXNEG_Pos) +#define AC_COMPCTRL_MUXPOS_Pos 12 /**< \brief (AC_COMPCTRL) Positive Input Mux Selection */ +#define AC_COMPCTRL_MUXPOS_Msk (0x3u << AC_COMPCTRL_MUXPOS_Pos) +#define AC_COMPCTRL_MUXPOS(value) ((AC_COMPCTRL_MUXPOS_Msk & ((value) << AC_COMPCTRL_MUXPOS_Pos))) +#define AC_COMPCTRL_MUXPOS_PIN0_Val 0x0u /**< \brief (AC_COMPCTRL) I/O pin 0 */ +#define AC_COMPCTRL_MUXPOS_PIN1_Val 0x1u /**< \brief (AC_COMPCTRL) I/O pin 1 */ +#define AC_COMPCTRL_MUXPOS_PIN2_Val 0x2u /**< \brief (AC_COMPCTRL) I/O pin 2 */ +#define AC_COMPCTRL_MUXPOS_PIN3_Val 0x3u /**< \brief (AC_COMPCTRL) I/O pin 3 */ +#define AC_COMPCTRL_MUXPOS_PIN0 (AC_COMPCTRL_MUXPOS_PIN0_Val << AC_COMPCTRL_MUXPOS_Pos) +#define AC_COMPCTRL_MUXPOS_PIN1 (AC_COMPCTRL_MUXPOS_PIN1_Val << AC_COMPCTRL_MUXPOS_Pos) +#define AC_COMPCTRL_MUXPOS_PIN2 (AC_COMPCTRL_MUXPOS_PIN2_Val << AC_COMPCTRL_MUXPOS_Pos) +#define AC_COMPCTRL_MUXPOS_PIN3 (AC_COMPCTRL_MUXPOS_PIN3_Val << AC_COMPCTRL_MUXPOS_Pos) +#define AC_COMPCTRL_SWAP_Pos 15 /**< \brief (AC_COMPCTRL) Swap Inputs and Invert */ +#define AC_COMPCTRL_SWAP (0x1u << AC_COMPCTRL_SWAP_Pos) +#define AC_COMPCTRL_OUT_Pos 16 /**< \brief (AC_COMPCTRL) Output */ +#define AC_COMPCTRL_OUT_Msk (0x3u << AC_COMPCTRL_OUT_Pos) +#define AC_COMPCTRL_OUT(value) ((AC_COMPCTRL_OUT_Msk & ((value) << AC_COMPCTRL_OUT_Pos))) +#define AC_COMPCTRL_OUT_OFF_Val 0x0u /**< \brief (AC_COMPCTRL) The output of COMPn is not routed to the COMPn I/O port */ +#define AC_COMPCTRL_OUT_ASYNC_Val 0x1u /**< \brief (AC_COMPCTRL) The asynchronous output of COMPn is routed to the COMPn I/O port */ +#define AC_COMPCTRL_OUT_SYNC_Val 0x2u /**< \brief (AC_COMPCTRL) The synchronous output (including filtering) of COMPn is routed to the COMPn I/O port */ +#define AC_COMPCTRL_OUT_OFF (AC_COMPCTRL_OUT_OFF_Val << AC_COMPCTRL_OUT_Pos) +#define AC_COMPCTRL_OUT_ASYNC (AC_COMPCTRL_OUT_ASYNC_Val << AC_COMPCTRL_OUT_Pos) +#define AC_COMPCTRL_OUT_SYNC (AC_COMPCTRL_OUT_SYNC_Val << AC_COMPCTRL_OUT_Pos) +#define AC_COMPCTRL_HYST_Pos 19 /**< \brief (AC_COMPCTRL) Hysteresis Enable */ +#define AC_COMPCTRL_HYST (0x1u << AC_COMPCTRL_HYST_Pos) +#define AC_COMPCTRL_FLEN_Pos 24 /**< \brief (AC_COMPCTRL) Filter Length */ +#define AC_COMPCTRL_FLEN_Msk (0x7u << AC_COMPCTRL_FLEN_Pos) +#define AC_COMPCTRL_FLEN(value) ((AC_COMPCTRL_FLEN_Msk & ((value) << AC_COMPCTRL_FLEN_Pos))) +#define AC_COMPCTRL_FLEN_OFF_Val 0x0u /**< \brief (AC_COMPCTRL) No filtering */ +#define AC_COMPCTRL_FLEN_MAJ3_Val 0x1u /**< \brief (AC_COMPCTRL) 3-bit majority function (2 of 3) */ +#define AC_COMPCTRL_FLEN_MAJ5_Val 0x2u /**< \brief (AC_COMPCTRL) 5-bit majority function (3 of 5) */ +#define AC_COMPCTRL_FLEN_OFF (AC_COMPCTRL_FLEN_OFF_Val << AC_COMPCTRL_FLEN_Pos) +#define AC_COMPCTRL_FLEN_MAJ3 (AC_COMPCTRL_FLEN_MAJ3_Val << AC_COMPCTRL_FLEN_Pos) +#define AC_COMPCTRL_FLEN_MAJ5 (AC_COMPCTRL_FLEN_MAJ5_Val << AC_COMPCTRL_FLEN_Pos) +#define AC_COMPCTRL_MASK 0x070BB76Fu /**< \brief (AC_COMPCTRL) MASK Register */ + +/* -------- AC_SCALER : (AC Offset: 0x20) (R/W 8) Scaler n -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t VALUE:6; /*!< bit: 0.. 5 Scaler Value */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} AC_SCALER_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_SCALER_OFFSET 0x20 /**< \brief (AC_SCALER offset) Scaler n */ +#define AC_SCALER_RESETVALUE 0x00 /**< \brief (AC_SCALER reset_value) Scaler n */ + +#define AC_SCALER_VALUE_Pos 0 /**< \brief (AC_SCALER) Scaler Value */ +#define AC_SCALER_VALUE_Msk (0x3Fu << AC_SCALER_VALUE_Pos) +#define AC_SCALER_VALUE(value) ((AC_SCALER_VALUE_Msk & ((value) << AC_SCALER_VALUE_Pos))) +#define AC_SCALER_MASK 0x3Fu /**< \brief (AC_SCALER) MASK Register */ + +/** \brief AC hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO AC_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 8) Control A */ + __O AC_CTRLB_Type CTRLB; /**< \brief Offset: 0x01 ( /W 8) Control B */ + __IO AC_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x02 (R/W 16) Event Control */ + __IO AC_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x04 (R/W 8) Interrupt Enable Clear */ + __IO AC_INTENSET_Type INTENSET; /**< \brief Offset: 0x05 (R/W 8) Interrupt Enable Set */ + __IO AC_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x06 (R/W 8) Interrupt Flag Status and Clear */ + RoReg8 Reserved1[0x1]; + __I AC_STATUSA_Type STATUSA; /**< \brief Offset: 0x08 (R/ 8) Status A */ + __I AC_STATUSB_Type STATUSB; /**< \brief Offset: 0x09 (R/ 8) Status B */ + __I AC_STATUSC_Type STATUSC; /**< \brief Offset: 0x0A (R/ 8) Status C */ + RoReg8 Reserved2[0x1]; + __IO AC_WINCTRL_Type WINCTRL; /**< \brief Offset: 0x0C (R/W 8) Window Control */ + RoReg8 Reserved3[0x3]; + __IO AC_COMPCTRL_Type COMPCTRL[2]; /**< \brief Offset: 0x10 (R/W 32) Comparator Control n */ + RoReg8 Reserved4[0x8]; + __IO AC_SCALER_Type SCALER[2]; /**< \brief Offset: 0x20 (R/W 8) Scaler n */ +} Ac; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_AC_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/adc.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/adc.h new file mode 100644 index 0000000..44a94c0 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/adc.h @@ -0,0 +1,699 @@ +/** + * \file + * + * \brief Component description for ADC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_ADC_COMPONENT_ +#define _SAMD21_ADC_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR ADC */ +/* ========================================================================== */ +/** \addtogroup SAMD21_ADC Analog Digital Converter */ +/*@{*/ + +#define ADC_U2204 +#define REV_ADC 0x120 + +/* -------- ADC_CTRLA : (ADC Offset: 0x00) (R/W 8) Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset */ + uint8_t ENABLE:1; /*!< bit: 1 Enable */ + uint8_t RUNSTDBY:1; /*!< bit: 2 Run in Standby */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_CTRLA_OFFSET 0x00 /**< \brief (ADC_CTRLA offset) Control A */ +#define ADC_CTRLA_RESETVALUE 0x00 /**< \brief (ADC_CTRLA reset_value) Control A */ + +#define ADC_CTRLA_SWRST_Pos 0 /**< \brief (ADC_CTRLA) Software Reset */ +#define ADC_CTRLA_SWRST (0x1u << ADC_CTRLA_SWRST_Pos) +#define ADC_CTRLA_ENABLE_Pos 1 /**< \brief (ADC_CTRLA) Enable */ +#define ADC_CTRLA_ENABLE (0x1u << ADC_CTRLA_ENABLE_Pos) +#define ADC_CTRLA_RUNSTDBY_Pos 2 /**< \brief (ADC_CTRLA) Run in Standby */ +#define ADC_CTRLA_RUNSTDBY (0x1u << ADC_CTRLA_RUNSTDBY_Pos) +#define ADC_CTRLA_MASK 0x07u /**< \brief (ADC_CTRLA) MASK Register */ + +/* -------- ADC_REFCTRL : (ADC Offset: 0x01) (R/W 8) Reference Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t REFSEL:4; /*!< bit: 0.. 3 Reference Selection */ + uint8_t :3; /*!< bit: 4.. 6 Reserved */ + uint8_t REFCOMP:1; /*!< bit: 7 Reference Buffer Offset Compensation Enable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_REFCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_REFCTRL_OFFSET 0x01 /**< \brief (ADC_REFCTRL offset) Reference Control */ +#define ADC_REFCTRL_RESETVALUE 0x00 /**< \brief (ADC_REFCTRL reset_value) Reference Control */ + +#define ADC_REFCTRL_REFSEL_Pos 0 /**< \brief (ADC_REFCTRL) Reference Selection */ +#define ADC_REFCTRL_REFSEL_Msk (0xFu << ADC_REFCTRL_REFSEL_Pos) +#define ADC_REFCTRL_REFSEL(value) ((ADC_REFCTRL_REFSEL_Msk & ((value) << ADC_REFCTRL_REFSEL_Pos))) +#define ADC_REFCTRL_REFSEL_INT1V_Val 0x0u /**< \brief (ADC_REFCTRL) 1.0V voltage reference */ +#define ADC_REFCTRL_REFSEL_INTVCC0_Val 0x1u /**< \brief (ADC_REFCTRL) 1/1.48 VDDANA */ +#define ADC_REFCTRL_REFSEL_INTVCC1_Val 0x2u /**< \brief (ADC_REFCTRL) 1/2 VDDANA (only for VDDANA > 2.0V) */ +#define ADC_REFCTRL_REFSEL_AREFA_Val 0x3u /**< \brief (ADC_REFCTRL) External reference */ +#define ADC_REFCTRL_REFSEL_AREFB_Val 0x4u /**< \brief (ADC_REFCTRL) External reference */ +#define ADC_REFCTRL_REFSEL_INT1V (ADC_REFCTRL_REFSEL_INT1V_Val << ADC_REFCTRL_REFSEL_Pos) +#define ADC_REFCTRL_REFSEL_INTVCC0 (ADC_REFCTRL_REFSEL_INTVCC0_Val << ADC_REFCTRL_REFSEL_Pos) +#define ADC_REFCTRL_REFSEL_INTVCC1 (ADC_REFCTRL_REFSEL_INTVCC1_Val << ADC_REFCTRL_REFSEL_Pos) +#define ADC_REFCTRL_REFSEL_AREFA (ADC_REFCTRL_REFSEL_AREFA_Val << ADC_REFCTRL_REFSEL_Pos) +#define ADC_REFCTRL_REFSEL_AREFB (ADC_REFCTRL_REFSEL_AREFB_Val << ADC_REFCTRL_REFSEL_Pos) +#define ADC_REFCTRL_REFCOMP_Pos 7 /**< \brief (ADC_REFCTRL) Reference Buffer Offset Compensation Enable */ +#define ADC_REFCTRL_REFCOMP (0x1u << ADC_REFCTRL_REFCOMP_Pos) +#define ADC_REFCTRL_MASK 0x8Fu /**< \brief (ADC_REFCTRL) MASK Register */ + +/* -------- ADC_AVGCTRL : (ADC Offset: 0x02) (R/W 8) Average Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SAMPLENUM:4; /*!< bit: 0.. 3 Number of Samples to be Collected */ + uint8_t ADJRES:3; /*!< bit: 4.. 6 Adjusting Result / Division Coefficient */ + uint8_t :1; /*!< bit: 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_AVGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_AVGCTRL_OFFSET 0x02 /**< \brief (ADC_AVGCTRL offset) Average Control */ +#define ADC_AVGCTRL_RESETVALUE 0x00 /**< \brief (ADC_AVGCTRL reset_value) Average Control */ + +#define ADC_AVGCTRL_SAMPLENUM_Pos 0 /**< \brief (ADC_AVGCTRL) Number of Samples to be Collected */ +#define ADC_AVGCTRL_SAMPLENUM_Msk (0xFu << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM(value) ((ADC_AVGCTRL_SAMPLENUM_Msk & ((value) << ADC_AVGCTRL_SAMPLENUM_Pos))) +#define ADC_AVGCTRL_SAMPLENUM_1_Val 0x0u /**< \brief (ADC_AVGCTRL) 1 sample */ +#define ADC_AVGCTRL_SAMPLENUM_2_Val 0x1u /**< \brief (ADC_AVGCTRL) 2 samples */ +#define ADC_AVGCTRL_SAMPLENUM_4_Val 0x2u /**< \brief (ADC_AVGCTRL) 4 samples */ +#define ADC_AVGCTRL_SAMPLENUM_8_Val 0x3u /**< \brief (ADC_AVGCTRL) 8 samples */ +#define ADC_AVGCTRL_SAMPLENUM_16_Val 0x4u /**< \brief (ADC_AVGCTRL) 16 samples */ +#define ADC_AVGCTRL_SAMPLENUM_32_Val 0x5u /**< \brief (ADC_AVGCTRL) 32 samples */ +#define ADC_AVGCTRL_SAMPLENUM_64_Val 0x6u /**< \brief (ADC_AVGCTRL) 64 samples */ +#define ADC_AVGCTRL_SAMPLENUM_128_Val 0x7u /**< \brief (ADC_AVGCTRL) 128 samples */ +#define ADC_AVGCTRL_SAMPLENUM_256_Val 0x8u /**< \brief (ADC_AVGCTRL) 256 samples */ +#define ADC_AVGCTRL_SAMPLENUM_512_Val 0x9u /**< \brief (ADC_AVGCTRL) 512 samples */ +#define ADC_AVGCTRL_SAMPLENUM_1024_Val 0xAu /**< \brief (ADC_AVGCTRL) 1024 samples */ +#define ADC_AVGCTRL_SAMPLENUM_1 (ADC_AVGCTRL_SAMPLENUM_1_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_2 (ADC_AVGCTRL_SAMPLENUM_2_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_4 (ADC_AVGCTRL_SAMPLENUM_4_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_8 (ADC_AVGCTRL_SAMPLENUM_8_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_16 (ADC_AVGCTRL_SAMPLENUM_16_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_32 (ADC_AVGCTRL_SAMPLENUM_32_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_64 (ADC_AVGCTRL_SAMPLENUM_64_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_128 (ADC_AVGCTRL_SAMPLENUM_128_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_256 (ADC_AVGCTRL_SAMPLENUM_256_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_512 (ADC_AVGCTRL_SAMPLENUM_512_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_1024 (ADC_AVGCTRL_SAMPLENUM_1024_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_ADJRES_Pos 4 /**< \brief (ADC_AVGCTRL) Adjusting Result / Division Coefficient */ +#define ADC_AVGCTRL_ADJRES_Msk (0x7u << ADC_AVGCTRL_ADJRES_Pos) +#define ADC_AVGCTRL_ADJRES(value) ((ADC_AVGCTRL_ADJRES_Msk & ((value) << ADC_AVGCTRL_ADJRES_Pos))) +#define ADC_AVGCTRL_MASK 0x7Fu /**< \brief (ADC_AVGCTRL) MASK Register */ + +/* -------- ADC_SAMPCTRL : (ADC Offset: 0x03) (R/W 8) Sampling Time Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SAMPLEN:6; /*!< bit: 0.. 5 Sampling Time Length */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_SAMPCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_SAMPCTRL_OFFSET 0x03 /**< \brief (ADC_SAMPCTRL offset) Sampling Time Control */ +#define ADC_SAMPCTRL_RESETVALUE 0x00 /**< \brief (ADC_SAMPCTRL reset_value) Sampling Time Control */ + +#define ADC_SAMPCTRL_SAMPLEN_Pos 0 /**< \brief (ADC_SAMPCTRL) Sampling Time Length */ +#define ADC_SAMPCTRL_SAMPLEN_Msk (0x3Fu << ADC_SAMPCTRL_SAMPLEN_Pos) +#define ADC_SAMPCTRL_SAMPLEN(value) ((ADC_SAMPCTRL_SAMPLEN_Msk & ((value) << ADC_SAMPCTRL_SAMPLEN_Pos))) +#define ADC_SAMPCTRL_MASK 0x3Fu /**< \brief (ADC_SAMPCTRL) MASK Register */ + +/* -------- ADC_CTRLB : (ADC Offset: 0x04) (R/W 16) Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t DIFFMODE:1; /*!< bit: 0 Differential Mode */ + uint16_t LEFTADJ:1; /*!< bit: 1 Left-Adjusted Result */ + uint16_t FREERUN:1; /*!< bit: 2 Free Running Mode */ + uint16_t CORREN:1; /*!< bit: 3 Digital Correction Logic Enabled */ + uint16_t RESSEL:2; /*!< bit: 4.. 5 Conversion Result Resolution */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t PRESCALER:3; /*!< bit: 8..10 Prescaler Configuration */ + uint16_t :5; /*!< bit: 11..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} ADC_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_CTRLB_OFFSET 0x04 /**< \brief (ADC_CTRLB offset) Control B */ +#define ADC_CTRLB_RESETVALUE 0x0000 /**< \brief (ADC_CTRLB reset_value) Control B */ + +#define ADC_CTRLB_DIFFMODE_Pos 0 /**< \brief (ADC_CTRLB) Differential Mode */ +#define ADC_CTRLB_DIFFMODE (0x1u << ADC_CTRLB_DIFFMODE_Pos) +#define ADC_CTRLB_LEFTADJ_Pos 1 /**< \brief (ADC_CTRLB) Left-Adjusted Result */ +#define ADC_CTRLB_LEFTADJ (0x1u << ADC_CTRLB_LEFTADJ_Pos) +#define ADC_CTRLB_FREERUN_Pos 2 /**< \brief (ADC_CTRLB) Free Running Mode */ +#define ADC_CTRLB_FREERUN (0x1u << ADC_CTRLB_FREERUN_Pos) +#define ADC_CTRLB_CORREN_Pos 3 /**< \brief (ADC_CTRLB) Digital Correction Logic Enabled */ +#define ADC_CTRLB_CORREN (0x1u << ADC_CTRLB_CORREN_Pos) +#define ADC_CTRLB_RESSEL_Pos 4 /**< \brief (ADC_CTRLB) Conversion Result Resolution */ +#define ADC_CTRLB_RESSEL_Msk (0x3u << ADC_CTRLB_RESSEL_Pos) +#define ADC_CTRLB_RESSEL(value) ((ADC_CTRLB_RESSEL_Msk & ((value) << ADC_CTRLB_RESSEL_Pos))) +#define ADC_CTRLB_RESSEL_12BIT_Val 0x0u /**< \brief (ADC_CTRLB) 12-bit result */ +#define ADC_CTRLB_RESSEL_16BIT_Val 0x1u /**< \brief (ADC_CTRLB) For averaging mode output */ +#define ADC_CTRLB_RESSEL_10BIT_Val 0x2u /**< \brief (ADC_CTRLB) 10-bit result */ +#define ADC_CTRLB_RESSEL_8BIT_Val 0x3u /**< \brief (ADC_CTRLB) 8-bit result */ +#define ADC_CTRLB_RESSEL_12BIT (ADC_CTRLB_RESSEL_12BIT_Val << ADC_CTRLB_RESSEL_Pos) +#define ADC_CTRLB_RESSEL_16BIT (ADC_CTRLB_RESSEL_16BIT_Val << ADC_CTRLB_RESSEL_Pos) +#define ADC_CTRLB_RESSEL_10BIT (ADC_CTRLB_RESSEL_10BIT_Val << ADC_CTRLB_RESSEL_Pos) +#define ADC_CTRLB_RESSEL_8BIT (ADC_CTRLB_RESSEL_8BIT_Val << ADC_CTRLB_RESSEL_Pos) +#define ADC_CTRLB_PRESCALER_Pos 8 /**< \brief (ADC_CTRLB) Prescaler Configuration */ +#define ADC_CTRLB_PRESCALER_Msk (0x7u << ADC_CTRLB_PRESCALER_Pos) +#define ADC_CTRLB_PRESCALER(value) ((ADC_CTRLB_PRESCALER_Msk & ((value) << ADC_CTRLB_PRESCALER_Pos))) +#define ADC_CTRLB_PRESCALER_DIV4_Val 0x0u /**< \brief (ADC_CTRLB) Peripheral clock divided by 4 */ +#define ADC_CTRLB_PRESCALER_DIV8_Val 0x1u /**< \brief (ADC_CTRLB) Peripheral clock divided by 8 */ +#define ADC_CTRLB_PRESCALER_DIV16_Val 0x2u /**< \brief (ADC_CTRLB) Peripheral clock divided by 16 */ +#define ADC_CTRLB_PRESCALER_DIV32_Val 0x3u /**< \brief (ADC_CTRLB) Peripheral clock divided by 32 */ +#define ADC_CTRLB_PRESCALER_DIV64_Val 0x4u /**< \brief (ADC_CTRLB) Peripheral clock divided by 64 */ +#define ADC_CTRLB_PRESCALER_DIV128_Val 0x5u /**< \brief (ADC_CTRLB) Peripheral clock divided by 128 */ +#define ADC_CTRLB_PRESCALER_DIV256_Val 0x6u /**< \brief (ADC_CTRLB) Peripheral clock divided by 256 */ +#define ADC_CTRLB_PRESCALER_DIV512_Val 0x7u /**< \brief (ADC_CTRLB) Peripheral clock divided by 512 */ +#define ADC_CTRLB_PRESCALER_DIV4 (ADC_CTRLB_PRESCALER_DIV4_Val << ADC_CTRLB_PRESCALER_Pos) +#define ADC_CTRLB_PRESCALER_DIV8 (ADC_CTRLB_PRESCALER_DIV8_Val << ADC_CTRLB_PRESCALER_Pos) +#define ADC_CTRLB_PRESCALER_DIV16 (ADC_CTRLB_PRESCALER_DIV16_Val << ADC_CTRLB_PRESCALER_Pos) +#define ADC_CTRLB_PRESCALER_DIV32 (ADC_CTRLB_PRESCALER_DIV32_Val << ADC_CTRLB_PRESCALER_Pos) +#define ADC_CTRLB_PRESCALER_DIV64 (ADC_CTRLB_PRESCALER_DIV64_Val << ADC_CTRLB_PRESCALER_Pos) +#define ADC_CTRLB_PRESCALER_DIV128 (ADC_CTRLB_PRESCALER_DIV128_Val << ADC_CTRLB_PRESCALER_Pos) +#define ADC_CTRLB_PRESCALER_DIV256 (ADC_CTRLB_PRESCALER_DIV256_Val << ADC_CTRLB_PRESCALER_Pos) +#define ADC_CTRLB_PRESCALER_DIV512 (ADC_CTRLB_PRESCALER_DIV512_Val << ADC_CTRLB_PRESCALER_Pos) +#define ADC_CTRLB_MASK 0x073Fu /**< \brief (ADC_CTRLB) MASK Register */ + +/* -------- ADC_WINCTRL : (ADC Offset: 0x08) (R/W 8) Window Monitor Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t WINMODE:3; /*!< bit: 0.. 2 Window Monitor Mode */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_WINCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_WINCTRL_OFFSET 0x08 /**< \brief (ADC_WINCTRL offset) Window Monitor Control */ +#define ADC_WINCTRL_RESETVALUE 0x00 /**< \brief (ADC_WINCTRL reset_value) Window Monitor Control */ + +#define ADC_WINCTRL_WINMODE_Pos 0 /**< \brief (ADC_WINCTRL) Window Monitor Mode */ +#define ADC_WINCTRL_WINMODE_Msk (0x7u << ADC_WINCTRL_WINMODE_Pos) +#define ADC_WINCTRL_WINMODE(value) ((ADC_WINCTRL_WINMODE_Msk & ((value) << ADC_WINCTRL_WINMODE_Pos))) +#define ADC_WINCTRL_WINMODE_DISABLE_Val 0x0u /**< \brief (ADC_WINCTRL) No window mode (default) */ +#define ADC_WINCTRL_WINMODE_MODE1_Val 0x1u /**< \brief (ADC_WINCTRL) Mode 1: RESULT > WINLT */ +#define ADC_WINCTRL_WINMODE_MODE2_Val 0x2u /**< \brief (ADC_WINCTRL) Mode 2: RESULT < WINUT */ +#define ADC_WINCTRL_WINMODE_MODE3_Val 0x3u /**< \brief (ADC_WINCTRL) Mode 3: WINLT < RESULT < WINUT */ +#define ADC_WINCTRL_WINMODE_MODE4_Val 0x4u /**< \brief (ADC_WINCTRL) Mode 4: !(WINLT < RESULT < WINUT) */ +#define ADC_WINCTRL_WINMODE_DISABLE (ADC_WINCTRL_WINMODE_DISABLE_Val << ADC_WINCTRL_WINMODE_Pos) +#define ADC_WINCTRL_WINMODE_MODE1 (ADC_WINCTRL_WINMODE_MODE1_Val << ADC_WINCTRL_WINMODE_Pos) +#define ADC_WINCTRL_WINMODE_MODE2 (ADC_WINCTRL_WINMODE_MODE2_Val << ADC_WINCTRL_WINMODE_Pos) +#define ADC_WINCTRL_WINMODE_MODE3 (ADC_WINCTRL_WINMODE_MODE3_Val << ADC_WINCTRL_WINMODE_Pos) +#define ADC_WINCTRL_WINMODE_MODE4 (ADC_WINCTRL_WINMODE_MODE4_Val << ADC_WINCTRL_WINMODE_Pos) +#define ADC_WINCTRL_MASK 0x07u /**< \brief (ADC_WINCTRL) MASK Register */ + +/* -------- ADC_SWTRIG : (ADC Offset: 0x0C) (R/W 8) Software Trigger -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t FLUSH:1; /*!< bit: 0 ADC Conversion Flush */ + uint8_t START:1; /*!< bit: 1 ADC Start Conversion */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_SWTRIG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_SWTRIG_OFFSET 0x0C /**< \brief (ADC_SWTRIG offset) Software Trigger */ +#define ADC_SWTRIG_RESETVALUE 0x00 /**< \brief (ADC_SWTRIG reset_value) Software Trigger */ + +#define ADC_SWTRIG_FLUSH_Pos 0 /**< \brief (ADC_SWTRIG) ADC Conversion Flush */ +#define ADC_SWTRIG_FLUSH (0x1u << ADC_SWTRIG_FLUSH_Pos) +#define ADC_SWTRIG_START_Pos 1 /**< \brief (ADC_SWTRIG) ADC Start Conversion */ +#define ADC_SWTRIG_START (0x1u << ADC_SWTRIG_START_Pos) +#define ADC_SWTRIG_MASK 0x03u /**< \brief (ADC_SWTRIG) MASK Register */ + +/* -------- ADC_INPUTCTRL : (ADC Offset: 0x10) (R/W 32) Input Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t MUXPOS:5; /*!< bit: 0.. 4 Positive Mux Input Selection */ + uint32_t :3; /*!< bit: 5.. 7 Reserved */ + uint32_t MUXNEG:5; /*!< bit: 8..12 Negative Mux Input Selection */ + uint32_t :3; /*!< bit: 13..15 Reserved */ + uint32_t INPUTSCAN:4; /*!< bit: 16..19 Number of Input Channels Included in Scan */ + uint32_t INPUTOFFSET:4; /*!< bit: 20..23 Positive Mux Setting Offset */ + uint32_t GAIN:4; /*!< bit: 24..27 Gain Factor Selection */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} ADC_INPUTCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_INPUTCTRL_OFFSET 0x10 /**< \brief (ADC_INPUTCTRL offset) Input Control */ +#define ADC_INPUTCTRL_RESETVALUE 0x00000000 /**< \brief (ADC_INPUTCTRL reset_value) Input Control */ + +#define ADC_INPUTCTRL_MUXPOS_Pos 0 /**< \brief (ADC_INPUTCTRL) Positive Mux Input Selection */ +#define ADC_INPUTCTRL_MUXPOS_Msk (0x1Fu << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS(value) ((ADC_INPUTCTRL_MUXPOS_Msk & ((value) << ADC_INPUTCTRL_MUXPOS_Pos))) +#define ADC_INPUTCTRL_MUXPOS_PIN0_Val 0x0u /**< \brief (ADC_INPUTCTRL) ADC AIN0 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN1_Val 0x1u /**< \brief (ADC_INPUTCTRL) ADC AIN1 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN2_Val 0x2u /**< \brief (ADC_INPUTCTRL) ADC AIN2 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN3_Val 0x3u /**< \brief (ADC_INPUTCTRL) ADC AIN3 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN4_Val 0x4u /**< \brief (ADC_INPUTCTRL) ADC AIN4 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN5_Val 0x5u /**< \brief (ADC_INPUTCTRL) ADC AIN5 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN6_Val 0x6u /**< \brief (ADC_INPUTCTRL) ADC AIN6 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN7_Val 0x7u /**< \brief (ADC_INPUTCTRL) ADC AIN7 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN8_Val 0x8u /**< \brief (ADC_INPUTCTRL) ADC AIN8 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN9_Val 0x9u /**< \brief (ADC_INPUTCTRL) ADC AIN9 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN10_Val 0xAu /**< \brief (ADC_INPUTCTRL) ADC AIN10 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN11_Val 0xBu /**< \brief (ADC_INPUTCTRL) ADC AIN11 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN12_Val 0xCu /**< \brief (ADC_INPUTCTRL) ADC AIN12 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN13_Val 0xDu /**< \brief (ADC_INPUTCTRL) ADC AIN13 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN14_Val 0xEu /**< \brief (ADC_INPUTCTRL) ADC AIN14 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN15_Val 0xFu /**< \brief (ADC_INPUTCTRL) ADC AIN15 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN16_Val 0x10u /**< \brief (ADC_INPUTCTRL) ADC AIN16 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN17_Val 0x11u /**< \brief (ADC_INPUTCTRL) ADC AIN17 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN18_Val 0x12u /**< \brief (ADC_INPUTCTRL) ADC AIN18 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN19_Val 0x13u /**< \brief (ADC_INPUTCTRL) ADC AIN19 Pin */ +#define ADC_INPUTCTRL_MUXPOS_TEMP_Val 0x18u /**< \brief (ADC_INPUTCTRL) Temperature Reference */ +#define ADC_INPUTCTRL_MUXPOS_BANDGAP_Val 0x19u /**< \brief (ADC_INPUTCTRL) Bandgap Voltage */ +#define ADC_INPUTCTRL_MUXPOS_SCALEDCOREVCC_Val 0x1Au /**< \brief (ADC_INPUTCTRL) 1/4 Scaled Core Supply */ +#define ADC_INPUTCTRL_MUXPOS_SCALEDIOVCC_Val 0x1Bu /**< \brief (ADC_INPUTCTRL) 1/4 Scaled I/O Supply */ +#define ADC_INPUTCTRL_MUXPOS_DAC_Val 0x1Cu /**< \brief (ADC_INPUTCTRL) DAC Output */ +#define ADC_INPUTCTRL_MUXPOS_PIN0 (ADC_INPUTCTRL_MUXPOS_PIN0_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN1 (ADC_INPUTCTRL_MUXPOS_PIN1_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN2 (ADC_INPUTCTRL_MUXPOS_PIN2_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN3 (ADC_INPUTCTRL_MUXPOS_PIN3_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN4 (ADC_INPUTCTRL_MUXPOS_PIN4_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN5 (ADC_INPUTCTRL_MUXPOS_PIN5_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN6 (ADC_INPUTCTRL_MUXPOS_PIN6_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN7 (ADC_INPUTCTRL_MUXPOS_PIN7_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN8 (ADC_INPUTCTRL_MUXPOS_PIN8_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN9 (ADC_INPUTCTRL_MUXPOS_PIN9_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN10 (ADC_INPUTCTRL_MUXPOS_PIN10_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN11 (ADC_INPUTCTRL_MUXPOS_PIN11_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN12 (ADC_INPUTCTRL_MUXPOS_PIN12_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN13 (ADC_INPUTCTRL_MUXPOS_PIN13_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN14 (ADC_INPUTCTRL_MUXPOS_PIN14_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN15 (ADC_INPUTCTRL_MUXPOS_PIN15_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN16 (ADC_INPUTCTRL_MUXPOS_PIN16_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN17 (ADC_INPUTCTRL_MUXPOS_PIN17_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN18 (ADC_INPUTCTRL_MUXPOS_PIN18_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN19 (ADC_INPUTCTRL_MUXPOS_PIN19_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_TEMP (ADC_INPUTCTRL_MUXPOS_TEMP_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_BANDGAP (ADC_INPUTCTRL_MUXPOS_BANDGAP_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_SCALEDCOREVCC (ADC_INPUTCTRL_MUXPOS_SCALEDCOREVCC_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_SCALEDIOVCC (ADC_INPUTCTRL_MUXPOS_SCALEDIOVCC_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_DAC (ADC_INPUTCTRL_MUXPOS_DAC_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXNEG_Pos 8 /**< \brief (ADC_INPUTCTRL) Negative Mux Input Selection */ +#define ADC_INPUTCTRL_MUXNEG_Msk (0x1Fu << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG(value) ((ADC_INPUTCTRL_MUXNEG_Msk & ((value) << ADC_INPUTCTRL_MUXNEG_Pos))) +#define ADC_INPUTCTRL_MUXNEG_PIN0_Val 0x0u /**< \brief (ADC_INPUTCTRL) ADC AIN0 Pin */ +#define ADC_INPUTCTRL_MUXNEG_PIN1_Val 0x1u /**< \brief (ADC_INPUTCTRL) ADC AIN1 Pin */ +#define ADC_INPUTCTRL_MUXNEG_PIN2_Val 0x2u /**< \brief (ADC_INPUTCTRL) ADC AIN2 Pin */ +#define ADC_INPUTCTRL_MUXNEG_PIN3_Val 0x3u /**< \brief (ADC_INPUTCTRL) ADC AIN3 Pin */ +#define ADC_INPUTCTRL_MUXNEG_PIN4_Val 0x4u /**< \brief (ADC_INPUTCTRL) ADC AIN4 Pin */ +#define ADC_INPUTCTRL_MUXNEG_PIN5_Val 0x5u /**< \brief (ADC_INPUTCTRL) ADC AIN5 Pin */ +#define ADC_INPUTCTRL_MUXNEG_PIN6_Val 0x6u /**< \brief (ADC_INPUTCTRL) ADC AIN6 Pin */ +#define ADC_INPUTCTRL_MUXNEG_PIN7_Val 0x7u /**< \brief (ADC_INPUTCTRL) ADC AIN7 Pin */ +#define ADC_INPUTCTRL_MUXNEG_GND_Val 0x18u /**< \brief (ADC_INPUTCTRL) Internal Ground */ +#define ADC_INPUTCTRL_MUXNEG_IOGND_Val 0x19u /**< \brief (ADC_INPUTCTRL) I/O Ground */ +#define ADC_INPUTCTRL_MUXNEG_PIN0 (ADC_INPUTCTRL_MUXNEG_PIN0_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG_PIN1 (ADC_INPUTCTRL_MUXNEG_PIN1_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG_PIN2 (ADC_INPUTCTRL_MUXNEG_PIN2_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG_PIN3 (ADC_INPUTCTRL_MUXNEG_PIN3_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG_PIN4 (ADC_INPUTCTRL_MUXNEG_PIN4_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG_PIN5 (ADC_INPUTCTRL_MUXNEG_PIN5_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG_PIN6 (ADC_INPUTCTRL_MUXNEG_PIN6_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG_PIN7 (ADC_INPUTCTRL_MUXNEG_PIN7_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG_GND (ADC_INPUTCTRL_MUXNEG_GND_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG_IOGND (ADC_INPUTCTRL_MUXNEG_IOGND_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_INPUTSCAN_Pos 16 /**< \brief (ADC_INPUTCTRL) Number of Input Channels Included in Scan */ +#define ADC_INPUTCTRL_INPUTSCAN_Msk (0xFu << ADC_INPUTCTRL_INPUTSCAN_Pos) +#define ADC_INPUTCTRL_INPUTSCAN(value) ((ADC_INPUTCTRL_INPUTSCAN_Msk & ((value) << ADC_INPUTCTRL_INPUTSCAN_Pos))) +#define ADC_INPUTCTRL_INPUTOFFSET_Pos 20 /**< \brief (ADC_INPUTCTRL) Positive Mux Setting Offset */ +#define ADC_INPUTCTRL_INPUTOFFSET_Msk (0xFu << ADC_INPUTCTRL_INPUTOFFSET_Pos) +#define ADC_INPUTCTRL_INPUTOFFSET(value) ((ADC_INPUTCTRL_INPUTOFFSET_Msk & ((value) << ADC_INPUTCTRL_INPUTOFFSET_Pos))) +#define ADC_INPUTCTRL_GAIN_Pos 24 /**< \brief (ADC_INPUTCTRL) Gain Factor Selection */ +#define ADC_INPUTCTRL_GAIN_Msk (0xFu << ADC_INPUTCTRL_GAIN_Pos) +#define ADC_INPUTCTRL_GAIN(value) ((ADC_INPUTCTRL_GAIN_Msk & ((value) << ADC_INPUTCTRL_GAIN_Pos))) +#define ADC_INPUTCTRL_GAIN_1X_Val 0x0u /**< \brief (ADC_INPUTCTRL) 1x */ +#define ADC_INPUTCTRL_GAIN_2X_Val 0x1u /**< \brief (ADC_INPUTCTRL) 2x */ +#define ADC_INPUTCTRL_GAIN_4X_Val 0x2u /**< \brief (ADC_INPUTCTRL) 4x */ +#define ADC_INPUTCTRL_GAIN_8X_Val 0x3u /**< \brief (ADC_INPUTCTRL) 8x */ +#define ADC_INPUTCTRL_GAIN_16X_Val 0x4u /**< \brief (ADC_INPUTCTRL) 16x */ +#define ADC_INPUTCTRL_GAIN_DIV2_Val 0xFu /**< \brief (ADC_INPUTCTRL) 1/2x */ +#define ADC_INPUTCTRL_GAIN_1X (ADC_INPUTCTRL_GAIN_1X_Val << ADC_INPUTCTRL_GAIN_Pos) +#define ADC_INPUTCTRL_GAIN_2X (ADC_INPUTCTRL_GAIN_2X_Val << ADC_INPUTCTRL_GAIN_Pos) +#define ADC_INPUTCTRL_GAIN_4X (ADC_INPUTCTRL_GAIN_4X_Val << ADC_INPUTCTRL_GAIN_Pos) +#define ADC_INPUTCTRL_GAIN_8X (ADC_INPUTCTRL_GAIN_8X_Val << ADC_INPUTCTRL_GAIN_Pos) +#define ADC_INPUTCTRL_GAIN_16X (ADC_INPUTCTRL_GAIN_16X_Val << ADC_INPUTCTRL_GAIN_Pos) +#define ADC_INPUTCTRL_GAIN_DIV2 (ADC_INPUTCTRL_GAIN_DIV2_Val << ADC_INPUTCTRL_GAIN_Pos) +#define ADC_INPUTCTRL_MASK 0x0FFF1F1Fu /**< \brief (ADC_INPUTCTRL) MASK Register */ + +/* -------- ADC_EVCTRL : (ADC Offset: 0x14) (R/W 8) Event Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t STARTEI:1; /*!< bit: 0 Start Conversion Event In */ + uint8_t SYNCEI:1; /*!< bit: 1 Synchronization Event In */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t RESRDYEO:1; /*!< bit: 4 Result Ready Event Out */ + uint8_t WINMONEO:1; /*!< bit: 5 Window Monitor Event Out */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_EVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_EVCTRL_OFFSET 0x14 /**< \brief (ADC_EVCTRL offset) Event Control */ +#define ADC_EVCTRL_RESETVALUE 0x00 /**< \brief (ADC_EVCTRL reset_value) Event Control */ + +#define ADC_EVCTRL_STARTEI_Pos 0 /**< \brief (ADC_EVCTRL) Start Conversion Event In */ +#define ADC_EVCTRL_STARTEI (0x1u << ADC_EVCTRL_STARTEI_Pos) +#define ADC_EVCTRL_SYNCEI_Pos 1 /**< \brief (ADC_EVCTRL) Synchronization Event In */ +#define ADC_EVCTRL_SYNCEI (0x1u << ADC_EVCTRL_SYNCEI_Pos) +#define ADC_EVCTRL_RESRDYEO_Pos 4 /**< \brief (ADC_EVCTRL) Result Ready Event Out */ +#define ADC_EVCTRL_RESRDYEO (0x1u << ADC_EVCTRL_RESRDYEO_Pos) +#define ADC_EVCTRL_WINMONEO_Pos 5 /**< \brief (ADC_EVCTRL) Window Monitor Event Out */ +#define ADC_EVCTRL_WINMONEO (0x1u << ADC_EVCTRL_WINMONEO_Pos) +#define ADC_EVCTRL_MASK 0x33u /**< \brief (ADC_EVCTRL) MASK Register */ + +/* -------- ADC_INTENCLR : (ADC Offset: 0x16) (R/W 8) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t RESRDY:1; /*!< bit: 0 Result Ready Interrupt Enable */ + uint8_t OVERRUN:1; /*!< bit: 1 Overrun Interrupt Enable */ + uint8_t WINMON:1; /*!< bit: 2 Window Monitor Interrupt Enable */ + uint8_t SYNCRDY:1; /*!< bit: 3 Synchronization Ready Interrupt Enable */ + uint8_t :4; /*!< bit: 4.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_INTENCLR_OFFSET 0x16 /**< \brief (ADC_INTENCLR offset) Interrupt Enable Clear */ +#define ADC_INTENCLR_RESETVALUE 0x00 /**< \brief (ADC_INTENCLR reset_value) Interrupt Enable Clear */ + +#define ADC_INTENCLR_RESRDY_Pos 0 /**< \brief (ADC_INTENCLR) Result Ready Interrupt Enable */ +#define ADC_INTENCLR_RESRDY (0x1u << ADC_INTENCLR_RESRDY_Pos) +#define ADC_INTENCLR_OVERRUN_Pos 1 /**< \brief (ADC_INTENCLR) Overrun Interrupt Enable */ +#define ADC_INTENCLR_OVERRUN (0x1u << ADC_INTENCLR_OVERRUN_Pos) +#define ADC_INTENCLR_WINMON_Pos 2 /**< \brief (ADC_INTENCLR) Window Monitor Interrupt Enable */ +#define ADC_INTENCLR_WINMON (0x1u << ADC_INTENCLR_WINMON_Pos) +#define ADC_INTENCLR_SYNCRDY_Pos 3 /**< \brief (ADC_INTENCLR) Synchronization Ready Interrupt Enable */ +#define ADC_INTENCLR_SYNCRDY (0x1u << ADC_INTENCLR_SYNCRDY_Pos) +#define ADC_INTENCLR_MASK 0x0Fu /**< \brief (ADC_INTENCLR) MASK Register */ + +/* -------- ADC_INTENSET : (ADC Offset: 0x17) (R/W 8) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t RESRDY:1; /*!< bit: 0 Result Ready Interrupt Enable */ + uint8_t OVERRUN:1; /*!< bit: 1 Overrun Interrupt Enable */ + uint8_t WINMON:1; /*!< bit: 2 Window Monitor Interrupt Enable */ + uint8_t SYNCRDY:1; /*!< bit: 3 Synchronization Ready Interrupt Enable */ + uint8_t :4; /*!< bit: 4.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_INTENSET_OFFSET 0x17 /**< \brief (ADC_INTENSET offset) Interrupt Enable Set */ +#define ADC_INTENSET_RESETVALUE 0x00 /**< \brief (ADC_INTENSET reset_value) Interrupt Enable Set */ + +#define ADC_INTENSET_RESRDY_Pos 0 /**< \brief (ADC_INTENSET) Result Ready Interrupt Enable */ +#define ADC_INTENSET_RESRDY (0x1u << ADC_INTENSET_RESRDY_Pos) +#define ADC_INTENSET_OVERRUN_Pos 1 /**< \brief (ADC_INTENSET) Overrun Interrupt Enable */ +#define ADC_INTENSET_OVERRUN (0x1u << ADC_INTENSET_OVERRUN_Pos) +#define ADC_INTENSET_WINMON_Pos 2 /**< \brief (ADC_INTENSET) Window Monitor Interrupt Enable */ +#define ADC_INTENSET_WINMON (0x1u << ADC_INTENSET_WINMON_Pos) +#define ADC_INTENSET_SYNCRDY_Pos 3 /**< \brief (ADC_INTENSET) Synchronization Ready Interrupt Enable */ +#define ADC_INTENSET_SYNCRDY (0x1u << ADC_INTENSET_SYNCRDY_Pos) +#define ADC_INTENSET_MASK 0x0Fu /**< \brief (ADC_INTENSET) MASK Register */ + +/* -------- ADC_INTFLAG : (ADC Offset: 0x18) (R/W 8) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t RESRDY:1; /*!< bit: 0 Result Ready */ + uint8_t OVERRUN:1; /*!< bit: 1 Overrun */ + uint8_t WINMON:1; /*!< bit: 2 Window Monitor */ + uint8_t SYNCRDY:1; /*!< bit: 3 Synchronization Ready */ + uint8_t :4; /*!< bit: 4.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_INTFLAG_OFFSET 0x18 /**< \brief (ADC_INTFLAG offset) Interrupt Flag Status and Clear */ +#define ADC_INTFLAG_RESETVALUE 0x00 /**< \brief (ADC_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define ADC_INTFLAG_RESRDY_Pos 0 /**< \brief (ADC_INTFLAG) Result Ready */ +#define ADC_INTFLAG_RESRDY (0x1u << ADC_INTFLAG_RESRDY_Pos) +#define ADC_INTFLAG_OVERRUN_Pos 1 /**< \brief (ADC_INTFLAG) Overrun */ +#define ADC_INTFLAG_OVERRUN (0x1u << ADC_INTFLAG_OVERRUN_Pos) +#define ADC_INTFLAG_WINMON_Pos 2 /**< \brief (ADC_INTFLAG) Window Monitor */ +#define ADC_INTFLAG_WINMON (0x1u << ADC_INTFLAG_WINMON_Pos) +#define ADC_INTFLAG_SYNCRDY_Pos 3 /**< \brief (ADC_INTFLAG) Synchronization Ready */ +#define ADC_INTFLAG_SYNCRDY (0x1u << ADC_INTFLAG_SYNCRDY_Pos) +#define ADC_INTFLAG_MASK 0x0Fu /**< \brief (ADC_INTFLAG) MASK Register */ + +/* -------- ADC_STATUS : (ADC Offset: 0x19) (R/ 8) Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :7; /*!< bit: 0.. 6 Reserved */ + uint8_t SYNCBUSY:1; /*!< bit: 7 Synchronization Busy */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_STATUS_OFFSET 0x19 /**< \brief (ADC_STATUS offset) Status */ +#define ADC_STATUS_RESETVALUE 0x00 /**< \brief (ADC_STATUS reset_value) Status */ + +#define ADC_STATUS_SYNCBUSY_Pos 7 /**< \brief (ADC_STATUS) Synchronization Busy */ +#define ADC_STATUS_SYNCBUSY (0x1u << ADC_STATUS_SYNCBUSY_Pos) +#define ADC_STATUS_MASK 0x80u /**< \brief (ADC_STATUS) MASK Register */ + +/* -------- ADC_RESULT : (ADC Offset: 0x1A) (R/ 16) Result -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t RESULT:16; /*!< bit: 0..15 Result Conversion Value */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} ADC_RESULT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_RESULT_OFFSET 0x1A /**< \brief (ADC_RESULT offset) Result */ +#define ADC_RESULT_RESETVALUE 0x0000 /**< \brief (ADC_RESULT reset_value) Result */ + +#define ADC_RESULT_RESULT_Pos 0 /**< \brief (ADC_RESULT) Result Conversion Value */ +#define ADC_RESULT_RESULT_Msk (0xFFFFu << ADC_RESULT_RESULT_Pos) +#define ADC_RESULT_RESULT(value) ((ADC_RESULT_RESULT_Msk & ((value) << ADC_RESULT_RESULT_Pos))) +#define ADC_RESULT_MASK 0xFFFFu /**< \brief (ADC_RESULT) MASK Register */ + +/* -------- ADC_WINLT : (ADC Offset: 0x1C) (R/W 16) Window Monitor Lower Threshold -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t WINLT:16; /*!< bit: 0..15 Window Lower Threshold */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} ADC_WINLT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_WINLT_OFFSET 0x1C /**< \brief (ADC_WINLT offset) Window Monitor Lower Threshold */ +#define ADC_WINLT_RESETVALUE 0x0000 /**< \brief (ADC_WINLT reset_value) Window Monitor Lower Threshold */ + +#define ADC_WINLT_WINLT_Pos 0 /**< \brief (ADC_WINLT) Window Lower Threshold */ +#define ADC_WINLT_WINLT_Msk (0xFFFFu << ADC_WINLT_WINLT_Pos) +#define ADC_WINLT_WINLT(value) ((ADC_WINLT_WINLT_Msk & ((value) << ADC_WINLT_WINLT_Pos))) +#define ADC_WINLT_MASK 0xFFFFu /**< \brief (ADC_WINLT) MASK Register */ + +/* -------- ADC_WINUT : (ADC Offset: 0x20) (R/W 16) Window Monitor Upper Threshold -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t WINUT:16; /*!< bit: 0..15 Window Upper Threshold */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} ADC_WINUT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_WINUT_OFFSET 0x20 /**< \brief (ADC_WINUT offset) Window Monitor Upper Threshold */ +#define ADC_WINUT_RESETVALUE 0x0000 /**< \brief (ADC_WINUT reset_value) Window Monitor Upper Threshold */ + +#define ADC_WINUT_WINUT_Pos 0 /**< \brief (ADC_WINUT) Window Upper Threshold */ +#define ADC_WINUT_WINUT_Msk (0xFFFFu << ADC_WINUT_WINUT_Pos) +#define ADC_WINUT_WINUT(value) ((ADC_WINUT_WINUT_Msk & ((value) << ADC_WINUT_WINUT_Pos))) +#define ADC_WINUT_MASK 0xFFFFu /**< \brief (ADC_WINUT) MASK Register */ + +/* -------- ADC_GAINCORR : (ADC Offset: 0x24) (R/W 16) Gain Correction -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t GAINCORR:12; /*!< bit: 0..11 Gain Correction Value */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} ADC_GAINCORR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_GAINCORR_OFFSET 0x24 /**< \brief (ADC_GAINCORR offset) Gain Correction */ +#define ADC_GAINCORR_RESETVALUE 0x0000 /**< \brief (ADC_GAINCORR reset_value) Gain Correction */ + +#define ADC_GAINCORR_GAINCORR_Pos 0 /**< \brief (ADC_GAINCORR) Gain Correction Value */ +#define ADC_GAINCORR_GAINCORR_Msk (0xFFFu << ADC_GAINCORR_GAINCORR_Pos) +#define ADC_GAINCORR_GAINCORR(value) ((ADC_GAINCORR_GAINCORR_Msk & ((value) << ADC_GAINCORR_GAINCORR_Pos))) +#define ADC_GAINCORR_MASK 0x0FFFu /**< \brief (ADC_GAINCORR) MASK Register */ + +/* -------- ADC_OFFSETCORR : (ADC Offset: 0x26) (R/W 16) Offset Correction -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t OFFSETCORR:12; /*!< bit: 0..11 Offset Correction Value */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} ADC_OFFSETCORR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_OFFSETCORR_OFFSET 0x26 /**< \brief (ADC_OFFSETCORR offset) Offset Correction */ +#define ADC_OFFSETCORR_RESETVALUE 0x0000 /**< \brief (ADC_OFFSETCORR reset_value) Offset Correction */ + +#define ADC_OFFSETCORR_OFFSETCORR_Pos 0 /**< \brief (ADC_OFFSETCORR) Offset Correction Value */ +#define ADC_OFFSETCORR_OFFSETCORR_Msk (0xFFFu << ADC_OFFSETCORR_OFFSETCORR_Pos) +#define ADC_OFFSETCORR_OFFSETCORR(value) ((ADC_OFFSETCORR_OFFSETCORR_Msk & ((value) << ADC_OFFSETCORR_OFFSETCORR_Pos))) +#define ADC_OFFSETCORR_MASK 0x0FFFu /**< \brief (ADC_OFFSETCORR) MASK Register */ + +/* -------- ADC_CALIB : (ADC Offset: 0x28) (R/W 16) Calibration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t LINEARITY_CAL:8; /*!< bit: 0.. 7 Linearity Calibration Value */ + uint16_t BIAS_CAL:3; /*!< bit: 8..10 Bias Calibration Value */ + uint16_t :5; /*!< bit: 11..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} ADC_CALIB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_CALIB_OFFSET 0x28 /**< \brief (ADC_CALIB offset) Calibration */ +#define ADC_CALIB_RESETVALUE 0x0000 /**< \brief (ADC_CALIB reset_value) Calibration */ + +#define ADC_CALIB_LINEARITY_CAL_Pos 0 /**< \brief (ADC_CALIB) Linearity Calibration Value */ +#define ADC_CALIB_LINEARITY_CAL_Msk (0xFFu << ADC_CALIB_LINEARITY_CAL_Pos) +#define ADC_CALIB_LINEARITY_CAL(value) ((ADC_CALIB_LINEARITY_CAL_Msk & ((value) << ADC_CALIB_LINEARITY_CAL_Pos))) +#define ADC_CALIB_BIAS_CAL_Pos 8 /**< \brief (ADC_CALIB) Bias Calibration Value */ +#define ADC_CALIB_BIAS_CAL_Msk (0x7u << ADC_CALIB_BIAS_CAL_Pos) +#define ADC_CALIB_BIAS_CAL(value) ((ADC_CALIB_BIAS_CAL_Msk & ((value) << ADC_CALIB_BIAS_CAL_Pos))) +#define ADC_CALIB_MASK 0x07FFu /**< \brief (ADC_CALIB) MASK Register */ + +/* -------- ADC_DBGCTRL : (ADC Offset: 0x2A) (R/W 8) Debug Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DBGRUN:1; /*!< bit: 0 Debug Run */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_DBGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_DBGCTRL_OFFSET 0x2A /**< \brief (ADC_DBGCTRL offset) Debug Control */ +#define ADC_DBGCTRL_RESETVALUE 0x00 /**< \brief (ADC_DBGCTRL reset_value) Debug Control */ + +#define ADC_DBGCTRL_DBGRUN_Pos 0 /**< \brief (ADC_DBGCTRL) Debug Run */ +#define ADC_DBGCTRL_DBGRUN (0x1u << ADC_DBGCTRL_DBGRUN_Pos) +#define ADC_DBGCTRL_MASK 0x01u /**< \brief (ADC_DBGCTRL) MASK Register */ + +/** \brief ADC hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO ADC_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 8) Control A */ + __IO ADC_REFCTRL_Type REFCTRL; /**< \brief Offset: 0x01 (R/W 8) Reference Control */ + __IO ADC_AVGCTRL_Type AVGCTRL; /**< \brief Offset: 0x02 (R/W 8) Average Control */ + __IO ADC_SAMPCTRL_Type SAMPCTRL; /**< \brief Offset: 0x03 (R/W 8) Sampling Time Control */ + __IO ADC_CTRLB_Type CTRLB; /**< \brief Offset: 0x04 (R/W 16) Control B */ + RoReg8 Reserved1[0x2]; + __IO ADC_WINCTRL_Type WINCTRL; /**< \brief Offset: 0x08 (R/W 8) Window Monitor Control */ + RoReg8 Reserved2[0x3]; + __IO ADC_SWTRIG_Type SWTRIG; /**< \brief Offset: 0x0C (R/W 8) Software Trigger */ + RoReg8 Reserved3[0x3]; + __IO ADC_INPUTCTRL_Type INPUTCTRL; /**< \brief Offset: 0x10 (R/W 32) Input Control */ + __IO ADC_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x14 (R/W 8) Event Control */ + RoReg8 Reserved4[0x1]; + __IO ADC_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x16 (R/W 8) Interrupt Enable Clear */ + __IO ADC_INTENSET_Type INTENSET; /**< \brief Offset: 0x17 (R/W 8) Interrupt Enable Set */ + __IO ADC_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x18 (R/W 8) Interrupt Flag Status and Clear */ + __I ADC_STATUS_Type STATUS; /**< \brief Offset: 0x19 (R/ 8) Status */ + __I ADC_RESULT_Type RESULT; /**< \brief Offset: 0x1A (R/ 16) Result */ + __IO ADC_WINLT_Type WINLT; /**< \brief Offset: 0x1C (R/W 16) Window Monitor Lower Threshold */ + RoReg8 Reserved5[0x2]; + __IO ADC_WINUT_Type WINUT; /**< \brief Offset: 0x20 (R/W 16) Window Monitor Upper Threshold */ + RoReg8 Reserved6[0x2]; + __IO ADC_GAINCORR_Type GAINCORR; /**< \brief Offset: 0x24 (R/W 16) Gain Correction */ + __IO ADC_OFFSETCORR_Type OFFSETCORR; /**< \brief Offset: 0x26 (R/W 16) Offset Correction */ + __IO ADC_CALIB_Type CALIB; /**< \brief Offset: 0x28 (R/W 16) Calibration */ + __IO ADC_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x2A (R/W 8) Debug Control */ +} Adc; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_ADC_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/dac.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/dac.h new file mode 100644 index 0000000..3df13f8 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/dac.h @@ -0,0 +1,286 @@ +/** + * \file + * + * \brief Component description for DAC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_DAC_COMPONENT_ +#define _SAMD21_DAC_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR DAC */ +/* ========================================================================== */ +/** \addtogroup SAMD21_DAC Digital Analog Converter */ +/*@{*/ + +#define DAC_U2214 +#define REV_DAC 0x110 + +/* -------- DAC_CTRLA : (DAC Offset: 0x0) (R/W 8) Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset */ + uint8_t ENABLE:1; /*!< bit: 1 Enable */ + uint8_t RUNSTDBY:1; /*!< bit: 2 Run in Standby */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DAC_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DAC_CTRLA_OFFSET 0x0 /**< \brief (DAC_CTRLA offset) Control A */ +#define DAC_CTRLA_RESETVALUE 0x00 /**< \brief (DAC_CTRLA reset_value) Control A */ + +#define DAC_CTRLA_SWRST_Pos 0 /**< \brief (DAC_CTRLA) Software Reset */ +#define DAC_CTRLA_SWRST (0x1u << DAC_CTRLA_SWRST_Pos) +#define DAC_CTRLA_ENABLE_Pos 1 /**< \brief (DAC_CTRLA) Enable */ +#define DAC_CTRLA_ENABLE (0x1u << DAC_CTRLA_ENABLE_Pos) +#define DAC_CTRLA_RUNSTDBY_Pos 2 /**< \brief (DAC_CTRLA) Run in Standby */ +#define DAC_CTRLA_RUNSTDBY (0x1u << DAC_CTRLA_RUNSTDBY_Pos) +#define DAC_CTRLA_MASK 0x07u /**< \brief (DAC_CTRLA) MASK Register */ + +/* -------- DAC_CTRLB : (DAC Offset: 0x1) (R/W 8) Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t EOEN:1; /*!< bit: 0 External Output Enable */ + uint8_t IOEN:1; /*!< bit: 1 Internal Output Enable */ + uint8_t LEFTADJ:1; /*!< bit: 2 Left Adjusted Data */ + uint8_t VPD:1; /*!< bit: 3 Voltage Pump Disable */ + uint8_t BDWP:1; /*!< bit: 4 Bypass DATABUF Write Protection */ + uint8_t :1; /*!< bit: 5 Reserved */ + uint8_t REFSEL:2; /*!< bit: 6.. 7 Reference Selection */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DAC_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DAC_CTRLB_OFFSET 0x1 /**< \brief (DAC_CTRLB offset) Control B */ +#define DAC_CTRLB_RESETVALUE 0x00 /**< \brief (DAC_CTRLB reset_value) Control B */ + +#define DAC_CTRLB_EOEN_Pos 0 /**< \brief (DAC_CTRLB) External Output Enable */ +#define DAC_CTRLB_EOEN (0x1u << DAC_CTRLB_EOEN_Pos) +#define DAC_CTRLB_IOEN_Pos 1 /**< \brief (DAC_CTRLB) Internal Output Enable */ +#define DAC_CTRLB_IOEN (0x1u << DAC_CTRLB_IOEN_Pos) +#define DAC_CTRLB_LEFTADJ_Pos 2 /**< \brief (DAC_CTRLB) Left Adjusted Data */ +#define DAC_CTRLB_LEFTADJ (0x1u << DAC_CTRLB_LEFTADJ_Pos) +#define DAC_CTRLB_VPD_Pos 3 /**< \brief (DAC_CTRLB) Voltage Pump Disable */ +#define DAC_CTRLB_VPD (0x1u << DAC_CTRLB_VPD_Pos) +#define DAC_CTRLB_BDWP_Pos 4 /**< \brief (DAC_CTRLB) Bypass DATABUF Write Protection */ +#define DAC_CTRLB_BDWP (0x1u << DAC_CTRLB_BDWP_Pos) +#define DAC_CTRLB_REFSEL_Pos 6 /**< \brief (DAC_CTRLB) Reference Selection */ +#define DAC_CTRLB_REFSEL_Msk (0x3u << DAC_CTRLB_REFSEL_Pos) +#define DAC_CTRLB_REFSEL(value) ((DAC_CTRLB_REFSEL_Msk & ((value) << DAC_CTRLB_REFSEL_Pos))) +#define DAC_CTRLB_REFSEL_INT1V_Val 0x0u /**< \brief (DAC_CTRLB) Internal 1.0V reference */ +#define DAC_CTRLB_REFSEL_AVCC_Val 0x1u /**< \brief (DAC_CTRLB) AVCC */ +#define DAC_CTRLB_REFSEL_VREFP_Val 0x2u /**< \brief (DAC_CTRLB) External reference */ +#define DAC_CTRLB_REFSEL_INT1V (DAC_CTRLB_REFSEL_INT1V_Val << DAC_CTRLB_REFSEL_Pos) +#define DAC_CTRLB_REFSEL_AVCC (DAC_CTRLB_REFSEL_AVCC_Val << DAC_CTRLB_REFSEL_Pos) +#define DAC_CTRLB_REFSEL_VREFP (DAC_CTRLB_REFSEL_VREFP_Val << DAC_CTRLB_REFSEL_Pos) +#define DAC_CTRLB_MASK 0xDFu /**< \brief (DAC_CTRLB) MASK Register */ + +/* -------- DAC_EVCTRL : (DAC Offset: 0x2) (R/W 8) Event Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t STARTEI:1; /*!< bit: 0 Start Conversion Event Input */ + uint8_t EMPTYEO:1; /*!< bit: 1 Data Buffer Empty Event Output */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DAC_EVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DAC_EVCTRL_OFFSET 0x2 /**< \brief (DAC_EVCTRL offset) Event Control */ +#define DAC_EVCTRL_RESETVALUE 0x00 /**< \brief (DAC_EVCTRL reset_value) Event Control */ + +#define DAC_EVCTRL_STARTEI_Pos 0 /**< \brief (DAC_EVCTRL) Start Conversion Event Input */ +#define DAC_EVCTRL_STARTEI (0x1u << DAC_EVCTRL_STARTEI_Pos) +#define DAC_EVCTRL_EMPTYEO_Pos 1 /**< \brief (DAC_EVCTRL) Data Buffer Empty Event Output */ +#define DAC_EVCTRL_EMPTYEO (0x1u << DAC_EVCTRL_EMPTYEO_Pos) +#define DAC_EVCTRL_MASK 0x03u /**< \brief (DAC_EVCTRL) MASK Register */ + +/* -------- DAC_INTENCLR : (DAC Offset: 0x4) (R/W 8) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t UNDERRUN:1; /*!< bit: 0 Underrun Interrupt Enable */ + uint8_t EMPTY:1; /*!< bit: 1 Data Buffer Empty Interrupt Enable */ + uint8_t SYNCRDY:1; /*!< bit: 2 Synchronization Ready Interrupt Enable */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DAC_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DAC_INTENCLR_OFFSET 0x4 /**< \brief (DAC_INTENCLR offset) Interrupt Enable Clear */ +#define DAC_INTENCLR_RESETVALUE 0x00 /**< \brief (DAC_INTENCLR reset_value) Interrupt Enable Clear */ + +#define DAC_INTENCLR_UNDERRUN_Pos 0 /**< \brief (DAC_INTENCLR) Underrun Interrupt Enable */ +#define DAC_INTENCLR_UNDERRUN (0x1u << DAC_INTENCLR_UNDERRUN_Pos) +#define DAC_INTENCLR_EMPTY_Pos 1 /**< \brief (DAC_INTENCLR) Data Buffer Empty Interrupt Enable */ +#define DAC_INTENCLR_EMPTY (0x1u << DAC_INTENCLR_EMPTY_Pos) +#define DAC_INTENCLR_SYNCRDY_Pos 2 /**< \brief (DAC_INTENCLR) Synchronization Ready Interrupt Enable */ +#define DAC_INTENCLR_SYNCRDY (0x1u << DAC_INTENCLR_SYNCRDY_Pos) +#define DAC_INTENCLR_MASK 0x07u /**< \brief (DAC_INTENCLR) MASK Register */ + +/* -------- DAC_INTENSET : (DAC Offset: 0x5) (R/W 8) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t UNDERRUN:1; /*!< bit: 0 Underrun Interrupt Enable */ + uint8_t EMPTY:1; /*!< bit: 1 Data Buffer Empty Interrupt Enable */ + uint8_t SYNCRDY:1; /*!< bit: 2 Synchronization Ready Interrupt Enable */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DAC_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DAC_INTENSET_OFFSET 0x5 /**< \brief (DAC_INTENSET offset) Interrupt Enable Set */ +#define DAC_INTENSET_RESETVALUE 0x00 /**< \brief (DAC_INTENSET reset_value) Interrupt Enable Set */ + +#define DAC_INTENSET_UNDERRUN_Pos 0 /**< \brief (DAC_INTENSET) Underrun Interrupt Enable */ +#define DAC_INTENSET_UNDERRUN (0x1u << DAC_INTENSET_UNDERRUN_Pos) +#define DAC_INTENSET_EMPTY_Pos 1 /**< \brief (DAC_INTENSET) Data Buffer Empty Interrupt Enable */ +#define DAC_INTENSET_EMPTY (0x1u << DAC_INTENSET_EMPTY_Pos) +#define DAC_INTENSET_SYNCRDY_Pos 2 /**< \brief (DAC_INTENSET) Synchronization Ready Interrupt Enable */ +#define DAC_INTENSET_SYNCRDY (0x1u << DAC_INTENSET_SYNCRDY_Pos) +#define DAC_INTENSET_MASK 0x07u /**< \brief (DAC_INTENSET) MASK Register */ + +/* -------- DAC_INTFLAG : (DAC Offset: 0x6) (R/W 8) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t UNDERRUN:1; /*!< bit: 0 Underrun */ + uint8_t EMPTY:1; /*!< bit: 1 Data Buffer Empty */ + uint8_t SYNCRDY:1; /*!< bit: 2 Synchronization Ready */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DAC_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DAC_INTFLAG_OFFSET 0x6 /**< \brief (DAC_INTFLAG offset) Interrupt Flag Status and Clear */ +#define DAC_INTFLAG_RESETVALUE 0x00 /**< \brief (DAC_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define DAC_INTFLAG_UNDERRUN_Pos 0 /**< \brief (DAC_INTFLAG) Underrun */ +#define DAC_INTFLAG_UNDERRUN (0x1u << DAC_INTFLAG_UNDERRUN_Pos) +#define DAC_INTFLAG_EMPTY_Pos 1 /**< \brief (DAC_INTFLAG) Data Buffer Empty */ +#define DAC_INTFLAG_EMPTY (0x1u << DAC_INTFLAG_EMPTY_Pos) +#define DAC_INTFLAG_SYNCRDY_Pos 2 /**< \brief (DAC_INTFLAG) Synchronization Ready */ +#define DAC_INTFLAG_SYNCRDY (0x1u << DAC_INTFLAG_SYNCRDY_Pos) +#define DAC_INTFLAG_MASK 0x07u /**< \brief (DAC_INTFLAG) MASK Register */ + +/* -------- DAC_STATUS : (DAC Offset: 0x7) (R/ 8) Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :7; /*!< bit: 0.. 6 Reserved */ + uint8_t SYNCBUSY:1; /*!< bit: 7 Synchronization Busy Status */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DAC_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DAC_STATUS_OFFSET 0x7 /**< \brief (DAC_STATUS offset) Status */ +#define DAC_STATUS_RESETVALUE 0x00 /**< \brief (DAC_STATUS reset_value) Status */ + +#define DAC_STATUS_SYNCBUSY_Pos 7 /**< \brief (DAC_STATUS) Synchronization Busy Status */ +#define DAC_STATUS_SYNCBUSY (0x1u << DAC_STATUS_SYNCBUSY_Pos) +#define DAC_STATUS_MASK 0x80u /**< \brief (DAC_STATUS) MASK Register */ + +/* -------- DAC_DATA : (DAC Offset: 0x8) (R/W 16) Data -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t DATA:16; /*!< bit: 0..15 Data value to be converted */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} DAC_DATA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DAC_DATA_OFFSET 0x8 /**< \brief (DAC_DATA offset) Data */ +#define DAC_DATA_RESETVALUE 0x0000 /**< \brief (DAC_DATA reset_value) Data */ + +#define DAC_DATA_DATA_Pos 0 /**< \brief (DAC_DATA) Data value to be converted */ +#define DAC_DATA_DATA_Msk (0xFFFFu << DAC_DATA_DATA_Pos) +#define DAC_DATA_DATA(value) ((DAC_DATA_DATA_Msk & ((value) << DAC_DATA_DATA_Pos))) +#define DAC_DATA_MASK 0xFFFFu /**< \brief (DAC_DATA) MASK Register */ + +/* -------- DAC_DATABUF : (DAC Offset: 0xC) (R/W 16) Data Buffer -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t DATABUF:16; /*!< bit: 0..15 Data Buffer */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} DAC_DATABUF_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DAC_DATABUF_OFFSET 0xC /**< \brief (DAC_DATABUF offset) Data Buffer */ +#define DAC_DATABUF_RESETVALUE 0x0000 /**< \brief (DAC_DATABUF reset_value) Data Buffer */ + +#define DAC_DATABUF_DATABUF_Pos 0 /**< \brief (DAC_DATABUF) Data Buffer */ +#define DAC_DATABUF_DATABUF_Msk (0xFFFFu << DAC_DATABUF_DATABUF_Pos) +#define DAC_DATABUF_DATABUF(value) ((DAC_DATABUF_DATABUF_Msk & ((value) << DAC_DATABUF_DATABUF_Pos))) +#define DAC_DATABUF_MASK 0xFFFFu /**< \brief (DAC_DATABUF) MASK Register */ + +/** \brief DAC hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO DAC_CTRLA_Type CTRLA; /**< \brief Offset: 0x0 (R/W 8) Control A */ + __IO DAC_CTRLB_Type CTRLB; /**< \brief Offset: 0x1 (R/W 8) Control B */ + __IO DAC_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x2 (R/W 8) Event Control */ + RoReg8 Reserved1[0x1]; + __IO DAC_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x4 (R/W 8) Interrupt Enable Clear */ + __IO DAC_INTENSET_Type INTENSET; /**< \brief Offset: 0x5 (R/W 8) Interrupt Enable Set */ + __IO DAC_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x6 (R/W 8) Interrupt Flag Status and Clear */ + __I DAC_STATUS_Type STATUS; /**< \brief Offset: 0x7 (R/ 8) Status */ + __IO DAC_DATA_Type DATA; /**< \brief Offset: 0x8 (R/W 16) Data */ + RoReg8 Reserved2[0x2]; + __IO DAC_DATABUF_Type DATABUF; /**< \brief Offset: 0xC (R/W 16) Data Buffer */ +} Dac; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_DAC_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/dmac.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/dmac.h new file mode 100644 index 0000000..bab1e66 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/dmac.h @@ -0,0 +1,1033 @@ +/** + * \file + * + * \brief Component description for DMAC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_DMAC_COMPONENT_ +#define _SAMD21_DMAC_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR DMAC */ +/* ========================================================================== */ +/** \addtogroup SAMD21_DMAC Direct Memory Access Controller */ +/*@{*/ + +#define DMAC_U2223 +#define REV_DMAC 0x100 + +/* -------- DMAC_CTRL : (DMAC Offset: 0x00) (R/W 16) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SWRST:1; /*!< bit: 0 Software Reset */ + uint16_t DMAENABLE:1; /*!< bit: 1 DMA Enable */ + uint16_t CRCENABLE:1; /*!< bit: 2 CRC Enable */ + uint16_t :5; /*!< bit: 3.. 7 Reserved */ + uint16_t LVLEN0:1; /*!< bit: 8 Priority Level 0 Enable */ + uint16_t LVLEN1:1; /*!< bit: 9 Priority Level 1 Enable */ + uint16_t LVLEN2:1; /*!< bit: 10 Priority Level 2 Enable */ + uint16_t LVLEN3:1; /*!< bit: 11 Priority Level 3 Enable */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t :8; /*!< bit: 0.. 7 Reserved */ + uint16_t LVLEN:4; /*!< bit: 8..11 Priority Level x Enable */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} DMAC_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CTRL_OFFSET 0x00 /**< \brief (DMAC_CTRL offset) Control */ +#define DMAC_CTRL_RESETVALUE 0x0000 /**< \brief (DMAC_CTRL reset_value) Control */ + +#define DMAC_CTRL_SWRST_Pos 0 /**< \brief (DMAC_CTRL) Software Reset */ +#define DMAC_CTRL_SWRST (0x1u << DMAC_CTRL_SWRST_Pos) +#define DMAC_CTRL_DMAENABLE_Pos 1 /**< \brief (DMAC_CTRL) DMA Enable */ +#define DMAC_CTRL_DMAENABLE (0x1u << DMAC_CTRL_DMAENABLE_Pos) +#define DMAC_CTRL_CRCENABLE_Pos 2 /**< \brief (DMAC_CTRL) CRC Enable */ +#define DMAC_CTRL_CRCENABLE (0x1u << DMAC_CTRL_CRCENABLE_Pos) +#define DMAC_CTRL_LVLEN0_Pos 8 /**< \brief (DMAC_CTRL) Priority Level 0 Enable */ +#define DMAC_CTRL_LVLEN0 (1 << DMAC_CTRL_LVLEN0_Pos) +#define DMAC_CTRL_LVLEN1_Pos 9 /**< \brief (DMAC_CTRL) Priority Level 1 Enable */ +#define DMAC_CTRL_LVLEN1 (1 << DMAC_CTRL_LVLEN1_Pos) +#define DMAC_CTRL_LVLEN2_Pos 10 /**< \brief (DMAC_CTRL) Priority Level 2 Enable */ +#define DMAC_CTRL_LVLEN2 (1 << DMAC_CTRL_LVLEN2_Pos) +#define DMAC_CTRL_LVLEN3_Pos 11 /**< \brief (DMAC_CTRL) Priority Level 3 Enable */ +#define DMAC_CTRL_LVLEN3 (1 << DMAC_CTRL_LVLEN3_Pos) +#define DMAC_CTRL_LVLEN_Pos 8 /**< \brief (DMAC_CTRL) Priority Level x Enable */ +#define DMAC_CTRL_LVLEN_Msk (0xFu << DMAC_CTRL_LVLEN_Pos) +#define DMAC_CTRL_LVLEN(value) ((DMAC_CTRL_LVLEN_Msk & ((value) << DMAC_CTRL_LVLEN_Pos))) +#define DMAC_CTRL_MASK 0x0F07u /**< \brief (DMAC_CTRL) MASK Register */ + +/* -------- DMAC_CRCCTRL : (DMAC Offset: 0x02) (R/W 16) CRC Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t CRCBEATSIZE:2; /*!< bit: 0.. 1 CRC Beat Size */ + uint16_t CRCPOLY:2; /*!< bit: 2.. 3 CRC Polynomial Type */ + uint16_t :4; /*!< bit: 4.. 7 Reserved */ + uint16_t CRCSRC:6; /*!< bit: 8..13 CRC Input Source */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} DMAC_CRCCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CRCCTRL_OFFSET 0x02 /**< \brief (DMAC_CRCCTRL offset) CRC Control */ +#define DMAC_CRCCTRL_RESETVALUE 0x0000 /**< \brief (DMAC_CRCCTRL reset_value) CRC Control */ + +#define DMAC_CRCCTRL_CRCBEATSIZE_Pos 0 /**< \brief (DMAC_CRCCTRL) CRC Beat Size */ +#define DMAC_CRCCTRL_CRCBEATSIZE_Msk (0x3u << DMAC_CRCCTRL_CRCBEATSIZE_Pos) +#define DMAC_CRCCTRL_CRCBEATSIZE(value) ((DMAC_CRCCTRL_CRCBEATSIZE_Msk & ((value) << DMAC_CRCCTRL_CRCBEATSIZE_Pos))) +#define DMAC_CRCCTRL_CRCBEATSIZE_BYTE_Val 0x0u /**< \brief (DMAC_CRCCTRL) Byte bus access */ +#define DMAC_CRCCTRL_CRCBEATSIZE_HWORD_Val 0x1u /**< \brief (DMAC_CRCCTRL) Half-word bus access */ +#define DMAC_CRCCTRL_CRCBEATSIZE_WORD_Val 0x2u /**< \brief (DMAC_CRCCTRL) Word bus access */ +#define DMAC_CRCCTRL_CRCBEATSIZE_BYTE (DMAC_CRCCTRL_CRCBEATSIZE_BYTE_Val << DMAC_CRCCTRL_CRCBEATSIZE_Pos) +#define DMAC_CRCCTRL_CRCBEATSIZE_HWORD (DMAC_CRCCTRL_CRCBEATSIZE_HWORD_Val << DMAC_CRCCTRL_CRCBEATSIZE_Pos) +#define DMAC_CRCCTRL_CRCBEATSIZE_WORD (DMAC_CRCCTRL_CRCBEATSIZE_WORD_Val << DMAC_CRCCTRL_CRCBEATSIZE_Pos) +#define DMAC_CRCCTRL_CRCPOLY_Pos 2 /**< \brief (DMAC_CRCCTRL) CRC Polynomial Type */ +#define DMAC_CRCCTRL_CRCPOLY_Msk (0x3u << DMAC_CRCCTRL_CRCPOLY_Pos) +#define DMAC_CRCCTRL_CRCPOLY(value) ((DMAC_CRCCTRL_CRCPOLY_Msk & ((value) << DMAC_CRCCTRL_CRCPOLY_Pos))) +#define DMAC_CRCCTRL_CRCPOLY_CRC16_Val 0x0u /**< \brief (DMAC_CRCCTRL) CRC-16 (CRC-CCITT) */ +#define DMAC_CRCCTRL_CRCPOLY_CRC32_Val 0x1u /**< \brief (DMAC_CRCCTRL) CRC32 (IEEE 802.3) */ +#define DMAC_CRCCTRL_CRCPOLY_CRC16 (DMAC_CRCCTRL_CRCPOLY_CRC16_Val << DMAC_CRCCTRL_CRCPOLY_Pos) +#define DMAC_CRCCTRL_CRCPOLY_CRC32 (DMAC_CRCCTRL_CRCPOLY_CRC32_Val << DMAC_CRCCTRL_CRCPOLY_Pos) +#define DMAC_CRCCTRL_CRCSRC_Pos 8 /**< \brief (DMAC_CRCCTRL) CRC Input Source */ +#define DMAC_CRCCTRL_CRCSRC_Msk (0x3Fu << DMAC_CRCCTRL_CRCSRC_Pos) +#define DMAC_CRCCTRL_CRCSRC(value) ((DMAC_CRCCTRL_CRCSRC_Msk & ((value) << DMAC_CRCCTRL_CRCSRC_Pos))) +#define DMAC_CRCCTRL_CRCSRC_NOACT_Val 0x0u /**< \brief (DMAC_CRCCTRL) No action */ +#define DMAC_CRCCTRL_CRCSRC_IO_Val 0x1u /**< \brief (DMAC_CRCCTRL) I/O interface */ +#define DMAC_CRCCTRL_CRCSRC_NOACT (DMAC_CRCCTRL_CRCSRC_NOACT_Val << DMAC_CRCCTRL_CRCSRC_Pos) +#define DMAC_CRCCTRL_CRCSRC_IO (DMAC_CRCCTRL_CRCSRC_IO_Val << DMAC_CRCCTRL_CRCSRC_Pos) +#define DMAC_CRCCTRL_MASK 0x3F0Fu /**< \brief (DMAC_CRCCTRL) MASK Register */ + +/* -------- DMAC_CRCDATAIN : (DMAC Offset: 0x04) (R/W 32) CRC Data Input -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CRCDATAIN:32; /*!< bit: 0..31 CRC Data Input */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_CRCDATAIN_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CRCDATAIN_OFFSET 0x04 /**< \brief (DMAC_CRCDATAIN offset) CRC Data Input */ +#define DMAC_CRCDATAIN_RESETVALUE 0x00000000 /**< \brief (DMAC_CRCDATAIN reset_value) CRC Data Input */ + +#define DMAC_CRCDATAIN_CRCDATAIN_Pos 0 /**< \brief (DMAC_CRCDATAIN) CRC Data Input */ +#define DMAC_CRCDATAIN_CRCDATAIN_Msk (0xFFFFFFFFu << DMAC_CRCDATAIN_CRCDATAIN_Pos) +#define DMAC_CRCDATAIN_CRCDATAIN(value) ((DMAC_CRCDATAIN_CRCDATAIN_Msk & ((value) << DMAC_CRCDATAIN_CRCDATAIN_Pos))) +#define DMAC_CRCDATAIN_MASK 0xFFFFFFFFu /**< \brief (DMAC_CRCDATAIN) MASK Register */ + +/* -------- DMAC_CRCCHKSUM : (DMAC Offset: 0x08) (R/W 32) CRC Checksum -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CRCCHKSUM:32; /*!< bit: 0..31 CRC Checksum */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_CRCCHKSUM_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CRCCHKSUM_OFFSET 0x08 /**< \brief (DMAC_CRCCHKSUM offset) CRC Checksum */ +#define DMAC_CRCCHKSUM_RESETVALUE 0x00000000 /**< \brief (DMAC_CRCCHKSUM reset_value) CRC Checksum */ + +#define DMAC_CRCCHKSUM_CRCCHKSUM_Pos 0 /**< \brief (DMAC_CRCCHKSUM) CRC Checksum */ +#define DMAC_CRCCHKSUM_CRCCHKSUM_Msk (0xFFFFFFFFu << DMAC_CRCCHKSUM_CRCCHKSUM_Pos) +#define DMAC_CRCCHKSUM_CRCCHKSUM(value) ((DMAC_CRCCHKSUM_CRCCHKSUM_Msk & ((value) << DMAC_CRCCHKSUM_CRCCHKSUM_Pos))) +#define DMAC_CRCCHKSUM_MASK 0xFFFFFFFFu /**< \brief (DMAC_CRCCHKSUM) MASK Register */ + +/* -------- DMAC_CRCSTATUS : (DMAC Offset: 0x0C) (R/W 8) CRC Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CRCBUSY:1; /*!< bit: 0 CRC Module Busy */ + uint8_t CRCZERO:1; /*!< bit: 1 CRC Zero */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DMAC_CRCSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CRCSTATUS_OFFSET 0x0C /**< \brief (DMAC_CRCSTATUS offset) CRC Status */ +#define DMAC_CRCSTATUS_RESETVALUE 0x00 /**< \brief (DMAC_CRCSTATUS reset_value) CRC Status */ + +#define DMAC_CRCSTATUS_CRCBUSY_Pos 0 /**< \brief (DMAC_CRCSTATUS) CRC Module Busy */ +#define DMAC_CRCSTATUS_CRCBUSY (0x1u << DMAC_CRCSTATUS_CRCBUSY_Pos) +#define DMAC_CRCSTATUS_CRCZERO_Pos 1 /**< \brief (DMAC_CRCSTATUS) CRC Zero */ +#define DMAC_CRCSTATUS_CRCZERO (0x1u << DMAC_CRCSTATUS_CRCZERO_Pos) +#define DMAC_CRCSTATUS_MASK 0x03u /**< \brief (DMAC_CRCSTATUS) MASK Register */ + +/* -------- DMAC_DBGCTRL : (DMAC Offset: 0x0D) (R/W 8) Debug Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DBGRUN:1; /*!< bit: 0 Debug Run */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DMAC_DBGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_DBGCTRL_OFFSET 0x0D /**< \brief (DMAC_DBGCTRL offset) Debug Control */ +#define DMAC_DBGCTRL_RESETVALUE 0x00 /**< \brief (DMAC_DBGCTRL reset_value) Debug Control */ + +#define DMAC_DBGCTRL_DBGRUN_Pos 0 /**< \brief (DMAC_DBGCTRL) Debug Run */ +#define DMAC_DBGCTRL_DBGRUN (0x1u << DMAC_DBGCTRL_DBGRUN_Pos) +#define DMAC_DBGCTRL_MASK 0x01u /**< \brief (DMAC_DBGCTRL) MASK Register */ + +/* -------- DMAC_SWTRIGCTRL : (DMAC Offset: 0x10) (R/W 32) Software Trigger Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWTRIG0:1; /*!< bit: 0 Channel 0 Software Trigger */ + uint32_t SWTRIG1:1; /*!< bit: 1 Channel 1 Software Trigger */ + uint32_t SWTRIG2:1; /*!< bit: 2 Channel 2 Software Trigger */ + uint32_t SWTRIG3:1; /*!< bit: 3 Channel 3 Software Trigger */ + uint32_t SWTRIG4:1; /*!< bit: 4 Channel 4 Software Trigger */ + uint32_t SWTRIG5:1; /*!< bit: 5 Channel 5 Software Trigger */ + uint32_t SWTRIG6:1; /*!< bit: 6 Channel 6 Software Trigger */ + uint32_t SWTRIG7:1; /*!< bit: 7 Channel 7 Software Trigger */ + uint32_t SWTRIG8:1; /*!< bit: 8 Channel 8 Software Trigger */ + uint32_t SWTRIG9:1; /*!< bit: 9 Channel 9 Software Trigger */ + uint32_t SWTRIG10:1; /*!< bit: 10 Channel 10 Software Trigger */ + uint32_t SWTRIG11:1; /*!< bit: 11 Channel 11 Software Trigger */ + uint32_t :20; /*!< bit: 12..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t SWTRIG:12; /*!< bit: 0..11 Channel x Software Trigger */ + uint32_t :20; /*!< bit: 12..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_SWTRIGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_SWTRIGCTRL_OFFSET 0x10 /**< \brief (DMAC_SWTRIGCTRL offset) Software Trigger Control */ +#define DMAC_SWTRIGCTRL_RESETVALUE 0x00000000 /**< \brief (DMAC_SWTRIGCTRL reset_value) Software Trigger Control */ + +#define DMAC_SWTRIGCTRL_SWTRIG0_Pos 0 /**< \brief (DMAC_SWTRIGCTRL) Channel 0 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG0 (1 << DMAC_SWTRIGCTRL_SWTRIG0_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG1_Pos 1 /**< \brief (DMAC_SWTRIGCTRL) Channel 1 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG1 (1 << DMAC_SWTRIGCTRL_SWTRIG1_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG2_Pos 2 /**< \brief (DMAC_SWTRIGCTRL) Channel 2 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG2 (1 << DMAC_SWTRIGCTRL_SWTRIG2_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG3_Pos 3 /**< \brief (DMAC_SWTRIGCTRL) Channel 3 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG3 (1 << DMAC_SWTRIGCTRL_SWTRIG3_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG4_Pos 4 /**< \brief (DMAC_SWTRIGCTRL) Channel 4 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG4 (1 << DMAC_SWTRIGCTRL_SWTRIG4_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG5_Pos 5 /**< \brief (DMAC_SWTRIGCTRL) Channel 5 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG5 (1 << DMAC_SWTRIGCTRL_SWTRIG5_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG6_Pos 6 /**< \brief (DMAC_SWTRIGCTRL) Channel 6 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG6 (1 << DMAC_SWTRIGCTRL_SWTRIG6_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG7_Pos 7 /**< \brief (DMAC_SWTRIGCTRL) Channel 7 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG7 (1 << DMAC_SWTRIGCTRL_SWTRIG7_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG8_Pos 8 /**< \brief (DMAC_SWTRIGCTRL) Channel 8 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG8 (1 << DMAC_SWTRIGCTRL_SWTRIG8_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG9_Pos 9 /**< \brief (DMAC_SWTRIGCTRL) Channel 9 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG9 (1 << DMAC_SWTRIGCTRL_SWTRIG9_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG10_Pos 10 /**< \brief (DMAC_SWTRIGCTRL) Channel 10 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG10 (1 << DMAC_SWTRIGCTRL_SWTRIG10_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG11_Pos 11 /**< \brief (DMAC_SWTRIGCTRL) Channel 11 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG11 (1 << DMAC_SWTRIGCTRL_SWTRIG11_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG_Pos 0 /**< \brief (DMAC_SWTRIGCTRL) Channel x Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG_Msk (0xFFFu << DMAC_SWTRIGCTRL_SWTRIG_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG(value) ((DMAC_SWTRIGCTRL_SWTRIG_Msk & ((value) << DMAC_SWTRIGCTRL_SWTRIG_Pos))) +#define DMAC_SWTRIGCTRL_MASK 0x00000FFFu /**< \brief (DMAC_SWTRIGCTRL) MASK Register */ + +/* -------- DMAC_PRICTRL0 : (DMAC Offset: 0x14) (R/W 32) Priority Control 0 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t LVLPRI0:4; /*!< bit: 0.. 3 Level 0 Channel Priority Number */ + uint32_t :3; /*!< bit: 4.. 6 Reserved */ + uint32_t RRLVLEN0:1; /*!< bit: 7 Level 0 Round-Robin Scheduling Enable */ + uint32_t LVLPRI1:4; /*!< bit: 8..11 Level 1 Channel Priority Number */ + uint32_t :3; /*!< bit: 12..14 Reserved */ + uint32_t RRLVLEN1:1; /*!< bit: 15 Level 1 Round-Robin Scheduling Enable */ + uint32_t LVLPRI2:4; /*!< bit: 16..19 Level 2 Channel Priority Number */ + uint32_t :3; /*!< bit: 20..22 Reserved */ + uint32_t RRLVLEN2:1; /*!< bit: 23 Level 2 Round-Robin Scheduling Enable */ + uint32_t LVLPRI3:4; /*!< bit: 24..27 Level 3 Channel Priority Number */ + uint32_t :3; /*!< bit: 28..30 Reserved */ + uint32_t RRLVLEN3:1; /*!< bit: 31 Level 3 Round-Robin Scheduling Enable */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_PRICTRL0_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_PRICTRL0_OFFSET 0x14 /**< \brief (DMAC_PRICTRL0 offset) Priority Control 0 */ +#define DMAC_PRICTRL0_RESETVALUE 0x00000000 /**< \brief (DMAC_PRICTRL0 reset_value) Priority Control 0 */ + +#define DMAC_PRICTRL0_LVLPRI0_Pos 0 /**< \brief (DMAC_PRICTRL0) Level 0 Channel Priority Number */ +#define DMAC_PRICTRL0_LVLPRI0_Msk (0xFu << DMAC_PRICTRL0_LVLPRI0_Pos) +#define DMAC_PRICTRL0_LVLPRI0(value) ((DMAC_PRICTRL0_LVLPRI0_Msk & ((value) << DMAC_PRICTRL0_LVLPRI0_Pos))) +#define DMAC_PRICTRL0_RRLVLEN0_Pos 7 /**< \brief (DMAC_PRICTRL0) Level 0 Round-Robin Scheduling Enable */ +#define DMAC_PRICTRL0_RRLVLEN0 (0x1u << DMAC_PRICTRL0_RRLVLEN0_Pos) +#define DMAC_PRICTRL0_LVLPRI1_Pos 8 /**< \brief (DMAC_PRICTRL0) Level 1 Channel Priority Number */ +#define DMAC_PRICTRL0_LVLPRI1_Msk (0xFu << DMAC_PRICTRL0_LVLPRI1_Pos) +#define DMAC_PRICTRL0_LVLPRI1(value) ((DMAC_PRICTRL0_LVLPRI1_Msk & ((value) << DMAC_PRICTRL0_LVLPRI1_Pos))) +#define DMAC_PRICTRL0_RRLVLEN1_Pos 15 /**< \brief (DMAC_PRICTRL0) Level 1 Round-Robin Scheduling Enable */ +#define DMAC_PRICTRL0_RRLVLEN1 (0x1u << DMAC_PRICTRL0_RRLVLEN1_Pos) +#define DMAC_PRICTRL0_LVLPRI2_Pos 16 /**< \brief (DMAC_PRICTRL0) Level 2 Channel Priority Number */ +#define DMAC_PRICTRL0_LVLPRI2_Msk (0xFu << DMAC_PRICTRL0_LVLPRI2_Pos) +#define DMAC_PRICTRL0_LVLPRI2(value) ((DMAC_PRICTRL0_LVLPRI2_Msk & ((value) << DMAC_PRICTRL0_LVLPRI2_Pos))) +#define DMAC_PRICTRL0_RRLVLEN2_Pos 23 /**< \brief (DMAC_PRICTRL0) Level 2 Round-Robin Scheduling Enable */ +#define DMAC_PRICTRL0_RRLVLEN2 (0x1u << DMAC_PRICTRL0_RRLVLEN2_Pos) +#define DMAC_PRICTRL0_LVLPRI3_Pos 24 /**< \brief (DMAC_PRICTRL0) Level 3 Channel Priority Number */ +#define DMAC_PRICTRL0_LVLPRI3_Msk (0xFu << DMAC_PRICTRL0_LVLPRI3_Pos) +#define DMAC_PRICTRL0_LVLPRI3(value) ((DMAC_PRICTRL0_LVLPRI3_Msk & ((value) << DMAC_PRICTRL0_LVLPRI3_Pos))) +#define DMAC_PRICTRL0_RRLVLEN3_Pos 31 /**< \brief (DMAC_PRICTRL0) Level 3 Round-Robin Scheduling Enable */ +#define DMAC_PRICTRL0_RRLVLEN3 (0x1u << DMAC_PRICTRL0_RRLVLEN3_Pos) +#define DMAC_PRICTRL0_MASK 0x8F8F8F8Fu /**< \brief (DMAC_PRICTRL0) MASK Register */ + +/* -------- DMAC_INTPEND : (DMAC Offset: 0x20) (R/W 16) Interrupt Pending -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t ID:4; /*!< bit: 0.. 3 Channel ID */ + uint16_t :4; /*!< bit: 4.. 7 Reserved */ + uint16_t TERR:1; /*!< bit: 8 Transfer Error */ + uint16_t TCMPL:1; /*!< bit: 9 Transfer Complete */ + uint16_t SUSP:1; /*!< bit: 10 Channel Suspend */ + uint16_t :2; /*!< bit: 11..12 Reserved */ + uint16_t FERR:1; /*!< bit: 13 Fetch Error */ + uint16_t BUSY:1; /*!< bit: 14 Busy */ + uint16_t PEND:1; /*!< bit: 15 Pending */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} DMAC_INTPEND_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_INTPEND_OFFSET 0x20 /**< \brief (DMAC_INTPEND offset) Interrupt Pending */ +#define DMAC_INTPEND_RESETVALUE 0x0000 /**< \brief (DMAC_INTPEND reset_value) Interrupt Pending */ + +#define DMAC_INTPEND_ID_Pos 0 /**< \brief (DMAC_INTPEND) Channel ID */ +#define DMAC_INTPEND_ID_Msk (0xFu << DMAC_INTPEND_ID_Pos) +#define DMAC_INTPEND_ID(value) ((DMAC_INTPEND_ID_Msk & ((value) << DMAC_INTPEND_ID_Pos))) +#define DMAC_INTPEND_TERR_Pos 8 /**< \brief (DMAC_INTPEND) Transfer Error */ +#define DMAC_INTPEND_TERR (0x1u << DMAC_INTPEND_TERR_Pos) +#define DMAC_INTPEND_TCMPL_Pos 9 /**< \brief (DMAC_INTPEND) Transfer Complete */ +#define DMAC_INTPEND_TCMPL (0x1u << DMAC_INTPEND_TCMPL_Pos) +#define DMAC_INTPEND_SUSP_Pos 10 /**< \brief (DMAC_INTPEND) Channel Suspend */ +#define DMAC_INTPEND_SUSP (0x1u << DMAC_INTPEND_SUSP_Pos) +#define DMAC_INTPEND_FERR_Pos 13 /**< \brief (DMAC_INTPEND) Fetch Error */ +#define DMAC_INTPEND_FERR (0x1u << DMAC_INTPEND_FERR_Pos) +#define DMAC_INTPEND_BUSY_Pos 14 /**< \brief (DMAC_INTPEND) Busy */ +#define DMAC_INTPEND_BUSY (0x1u << DMAC_INTPEND_BUSY_Pos) +#define DMAC_INTPEND_PEND_Pos 15 /**< \brief (DMAC_INTPEND) Pending */ +#define DMAC_INTPEND_PEND (0x1u << DMAC_INTPEND_PEND_Pos) +#define DMAC_INTPEND_MASK 0xE70Fu /**< \brief (DMAC_INTPEND) MASK Register */ + +/* -------- DMAC_INTSTATUS : (DMAC Offset: 0x24) (R/ 32) Interrupt Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CHINT0:1; /*!< bit: 0 Channel 0 Pending Interrupt */ + uint32_t CHINT1:1; /*!< bit: 1 Channel 1 Pending Interrupt */ + uint32_t CHINT2:1; /*!< bit: 2 Channel 2 Pending Interrupt */ + uint32_t CHINT3:1; /*!< bit: 3 Channel 3 Pending Interrupt */ + uint32_t CHINT4:1; /*!< bit: 4 Channel 4 Pending Interrupt */ + uint32_t CHINT5:1; /*!< bit: 5 Channel 5 Pending Interrupt */ + uint32_t CHINT6:1; /*!< bit: 6 Channel 6 Pending Interrupt */ + uint32_t CHINT7:1; /*!< bit: 7 Channel 7 Pending Interrupt */ + uint32_t CHINT8:1; /*!< bit: 8 Channel 8 Pending Interrupt */ + uint32_t CHINT9:1; /*!< bit: 9 Channel 9 Pending Interrupt */ + uint32_t CHINT10:1; /*!< bit: 10 Channel 10 Pending Interrupt */ + uint32_t CHINT11:1; /*!< bit: 11 Channel 11 Pending Interrupt */ + uint32_t :20; /*!< bit: 12..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t CHINT:12; /*!< bit: 0..11 Channel x Pending Interrupt */ + uint32_t :20; /*!< bit: 12..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_INTSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_INTSTATUS_OFFSET 0x24 /**< \brief (DMAC_INTSTATUS offset) Interrupt Status */ +#define DMAC_INTSTATUS_RESETVALUE 0x00000000 /**< \brief (DMAC_INTSTATUS reset_value) Interrupt Status */ + +#define DMAC_INTSTATUS_CHINT0_Pos 0 /**< \brief (DMAC_INTSTATUS) Channel 0 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT0 (1 << DMAC_INTSTATUS_CHINT0_Pos) +#define DMAC_INTSTATUS_CHINT1_Pos 1 /**< \brief (DMAC_INTSTATUS) Channel 1 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT1 (1 << DMAC_INTSTATUS_CHINT1_Pos) +#define DMAC_INTSTATUS_CHINT2_Pos 2 /**< \brief (DMAC_INTSTATUS) Channel 2 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT2 (1 << DMAC_INTSTATUS_CHINT2_Pos) +#define DMAC_INTSTATUS_CHINT3_Pos 3 /**< \brief (DMAC_INTSTATUS) Channel 3 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT3 (1 << DMAC_INTSTATUS_CHINT3_Pos) +#define DMAC_INTSTATUS_CHINT4_Pos 4 /**< \brief (DMAC_INTSTATUS) Channel 4 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT4 (1 << DMAC_INTSTATUS_CHINT4_Pos) +#define DMAC_INTSTATUS_CHINT5_Pos 5 /**< \brief (DMAC_INTSTATUS) Channel 5 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT5 (1 << DMAC_INTSTATUS_CHINT5_Pos) +#define DMAC_INTSTATUS_CHINT6_Pos 6 /**< \brief (DMAC_INTSTATUS) Channel 6 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT6 (1 << DMAC_INTSTATUS_CHINT6_Pos) +#define DMAC_INTSTATUS_CHINT7_Pos 7 /**< \brief (DMAC_INTSTATUS) Channel 7 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT7 (1 << DMAC_INTSTATUS_CHINT7_Pos) +#define DMAC_INTSTATUS_CHINT8_Pos 8 /**< \brief (DMAC_INTSTATUS) Channel 8 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT8 (1 << DMAC_INTSTATUS_CHINT8_Pos) +#define DMAC_INTSTATUS_CHINT9_Pos 9 /**< \brief (DMAC_INTSTATUS) Channel 9 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT9 (1 << DMAC_INTSTATUS_CHINT9_Pos) +#define DMAC_INTSTATUS_CHINT10_Pos 10 /**< \brief (DMAC_INTSTATUS) Channel 10 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT10 (1 << DMAC_INTSTATUS_CHINT10_Pos) +#define DMAC_INTSTATUS_CHINT11_Pos 11 /**< \brief (DMAC_INTSTATUS) Channel 11 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT11 (1 << DMAC_INTSTATUS_CHINT11_Pos) +#define DMAC_INTSTATUS_CHINT_Pos 0 /**< \brief (DMAC_INTSTATUS) Channel x Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT_Msk (0xFFFu << DMAC_INTSTATUS_CHINT_Pos) +#define DMAC_INTSTATUS_CHINT(value) ((DMAC_INTSTATUS_CHINT_Msk & ((value) << DMAC_INTSTATUS_CHINT_Pos))) +#define DMAC_INTSTATUS_MASK 0x00000FFFu /**< \brief (DMAC_INTSTATUS) MASK Register */ + +/* -------- DMAC_BUSYCH : (DMAC Offset: 0x28) (R/ 32) Busy Channels -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t BUSYCH0:1; /*!< bit: 0 Busy Channel 0 */ + uint32_t BUSYCH1:1; /*!< bit: 1 Busy Channel 1 */ + uint32_t BUSYCH2:1; /*!< bit: 2 Busy Channel 2 */ + uint32_t BUSYCH3:1; /*!< bit: 3 Busy Channel 3 */ + uint32_t BUSYCH4:1; /*!< bit: 4 Busy Channel 4 */ + uint32_t BUSYCH5:1; /*!< bit: 5 Busy Channel 5 */ + uint32_t BUSYCH6:1; /*!< bit: 6 Busy Channel 6 */ + uint32_t BUSYCH7:1; /*!< bit: 7 Busy Channel 7 */ + uint32_t BUSYCH8:1; /*!< bit: 8 Busy Channel 8 */ + uint32_t BUSYCH9:1; /*!< bit: 9 Busy Channel 9 */ + uint32_t BUSYCH10:1; /*!< bit: 10 Busy Channel 10 */ + uint32_t BUSYCH11:1; /*!< bit: 11 Busy Channel 11 */ + uint32_t :20; /*!< bit: 12..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t BUSYCH:12; /*!< bit: 0..11 Busy Channel x */ + uint32_t :20; /*!< bit: 12..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_BUSYCH_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_BUSYCH_OFFSET 0x28 /**< \brief (DMAC_BUSYCH offset) Busy Channels */ +#define DMAC_BUSYCH_RESETVALUE 0x00000000 /**< \brief (DMAC_BUSYCH reset_value) Busy Channels */ + +#define DMAC_BUSYCH_BUSYCH0_Pos 0 /**< \brief (DMAC_BUSYCH) Busy Channel 0 */ +#define DMAC_BUSYCH_BUSYCH0 (1 << DMAC_BUSYCH_BUSYCH0_Pos) +#define DMAC_BUSYCH_BUSYCH1_Pos 1 /**< \brief (DMAC_BUSYCH) Busy Channel 1 */ +#define DMAC_BUSYCH_BUSYCH1 (1 << DMAC_BUSYCH_BUSYCH1_Pos) +#define DMAC_BUSYCH_BUSYCH2_Pos 2 /**< \brief (DMAC_BUSYCH) Busy Channel 2 */ +#define DMAC_BUSYCH_BUSYCH2 (1 << DMAC_BUSYCH_BUSYCH2_Pos) +#define DMAC_BUSYCH_BUSYCH3_Pos 3 /**< \brief (DMAC_BUSYCH) Busy Channel 3 */ +#define DMAC_BUSYCH_BUSYCH3 (1 << DMAC_BUSYCH_BUSYCH3_Pos) +#define DMAC_BUSYCH_BUSYCH4_Pos 4 /**< \brief (DMAC_BUSYCH) Busy Channel 4 */ +#define DMAC_BUSYCH_BUSYCH4 (1 << DMAC_BUSYCH_BUSYCH4_Pos) +#define DMAC_BUSYCH_BUSYCH5_Pos 5 /**< \brief (DMAC_BUSYCH) Busy Channel 5 */ +#define DMAC_BUSYCH_BUSYCH5 (1 << DMAC_BUSYCH_BUSYCH5_Pos) +#define DMAC_BUSYCH_BUSYCH6_Pos 6 /**< \brief (DMAC_BUSYCH) Busy Channel 6 */ +#define DMAC_BUSYCH_BUSYCH6 (1 << DMAC_BUSYCH_BUSYCH6_Pos) +#define DMAC_BUSYCH_BUSYCH7_Pos 7 /**< \brief (DMAC_BUSYCH) Busy Channel 7 */ +#define DMAC_BUSYCH_BUSYCH7 (1 << DMAC_BUSYCH_BUSYCH7_Pos) +#define DMAC_BUSYCH_BUSYCH8_Pos 8 /**< \brief (DMAC_BUSYCH) Busy Channel 8 */ +#define DMAC_BUSYCH_BUSYCH8 (1 << DMAC_BUSYCH_BUSYCH8_Pos) +#define DMAC_BUSYCH_BUSYCH9_Pos 9 /**< \brief (DMAC_BUSYCH) Busy Channel 9 */ +#define DMAC_BUSYCH_BUSYCH9 (1 << DMAC_BUSYCH_BUSYCH9_Pos) +#define DMAC_BUSYCH_BUSYCH10_Pos 10 /**< \brief (DMAC_BUSYCH) Busy Channel 10 */ +#define DMAC_BUSYCH_BUSYCH10 (1 << DMAC_BUSYCH_BUSYCH10_Pos) +#define DMAC_BUSYCH_BUSYCH11_Pos 11 /**< \brief (DMAC_BUSYCH) Busy Channel 11 */ +#define DMAC_BUSYCH_BUSYCH11 (1 << DMAC_BUSYCH_BUSYCH11_Pos) +#define DMAC_BUSYCH_BUSYCH_Pos 0 /**< \brief (DMAC_BUSYCH) Busy Channel x */ +#define DMAC_BUSYCH_BUSYCH_Msk (0xFFFu << DMAC_BUSYCH_BUSYCH_Pos) +#define DMAC_BUSYCH_BUSYCH(value) ((DMAC_BUSYCH_BUSYCH_Msk & ((value) << DMAC_BUSYCH_BUSYCH_Pos))) +#define DMAC_BUSYCH_MASK 0x00000FFFu /**< \brief (DMAC_BUSYCH) MASK Register */ + +/* -------- DMAC_PENDCH : (DMAC Offset: 0x2C) (R/ 32) Pending Channels -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PENDCH0:1; /*!< bit: 0 Pending Channel 0 */ + uint32_t PENDCH1:1; /*!< bit: 1 Pending Channel 1 */ + uint32_t PENDCH2:1; /*!< bit: 2 Pending Channel 2 */ + uint32_t PENDCH3:1; /*!< bit: 3 Pending Channel 3 */ + uint32_t PENDCH4:1; /*!< bit: 4 Pending Channel 4 */ + uint32_t PENDCH5:1; /*!< bit: 5 Pending Channel 5 */ + uint32_t PENDCH6:1; /*!< bit: 6 Pending Channel 6 */ + uint32_t PENDCH7:1; /*!< bit: 7 Pending Channel 7 */ + uint32_t PENDCH8:1; /*!< bit: 8 Pending Channel 8 */ + uint32_t PENDCH9:1; /*!< bit: 9 Pending Channel 9 */ + uint32_t PENDCH10:1; /*!< bit: 10 Pending Channel 10 */ + uint32_t PENDCH11:1; /*!< bit: 11 Pending Channel 11 */ + uint32_t :20; /*!< bit: 12..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t PENDCH:12; /*!< bit: 0..11 Pending Channel x */ + uint32_t :20; /*!< bit: 12..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_PENDCH_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_PENDCH_OFFSET 0x2C /**< \brief (DMAC_PENDCH offset) Pending Channels */ +#define DMAC_PENDCH_RESETVALUE 0x00000000 /**< \brief (DMAC_PENDCH reset_value) Pending Channels */ + +#define DMAC_PENDCH_PENDCH0_Pos 0 /**< \brief (DMAC_PENDCH) Pending Channel 0 */ +#define DMAC_PENDCH_PENDCH0 (1 << DMAC_PENDCH_PENDCH0_Pos) +#define DMAC_PENDCH_PENDCH1_Pos 1 /**< \brief (DMAC_PENDCH) Pending Channel 1 */ +#define DMAC_PENDCH_PENDCH1 (1 << DMAC_PENDCH_PENDCH1_Pos) +#define DMAC_PENDCH_PENDCH2_Pos 2 /**< \brief (DMAC_PENDCH) Pending Channel 2 */ +#define DMAC_PENDCH_PENDCH2 (1 << DMAC_PENDCH_PENDCH2_Pos) +#define DMAC_PENDCH_PENDCH3_Pos 3 /**< \brief (DMAC_PENDCH) Pending Channel 3 */ +#define DMAC_PENDCH_PENDCH3 (1 << DMAC_PENDCH_PENDCH3_Pos) +#define DMAC_PENDCH_PENDCH4_Pos 4 /**< \brief (DMAC_PENDCH) Pending Channel 4 */ +#define DMAC_PENDCH_PENDCH4 (1 << DMAC_PENDCH_PENDCH4_Pos) +#define DMAC_PENDCH_PENDCH5_Pos 5 /**< \brief (DMAC_PENDCH) Pending Channel 5 */ +#define DMAC_PENDCH_PENDCH5 (1 << DMAC_PENDCH_PENDCH5_Pos) +#define DMAC_PENDCH_PENDCH6_Pos 6 /**< \brief (DMAC_PENDCH) Pending Channel 6 */ +#define DMAC_PENDCH_PENDCH6 (1 << DMAC_PENDCH_PENDCH6_Pos) +#define DMAC_PENDCH_PENDCH7_Pos 7 /**< \brief (DMAC_PENDCH) Pending Channel 7 */ +#define DMAC_PENDCH_PENDCH7 (1 << DMAC_PENDCH_PENDCH7_Pos) +#define DMAC_PENDCH_PENDCH8_Pos 8 /**< \brief (DMAC_PENDCH) Pending Channel 8 */ +#define DMAC_PENDCH_PENDCH8 (1 << DMAC_PENDCH_PENDCH8_Pos) +#define DMAC_PENDCH_PENDCH9_Pos 9 /**< \brief (DMAC_PENDCH) Pending Channel 9 */ +#define DMAC_PENDCH_PENDCH9 (1 << DMAC_PENDCH_PENDCH9_Pos) +#define DMAC_PENDCH_PENDCH10_Pos 10 /**< \brief (DMAC_PENDCH) Pending Channel 10 */ +#define DMAC_PENDCH_PENDCH10 (1 << DMAC_PENDCH_PENDCH10_Pos) +#define DMAC_PENDCH_PENDCH11_Pos 11 /**< \brief (DMAC_PENDCH) Pending Channel 11 */ +#define DMAC_PENDCH_PENDCH11 (1 << DMAC_PENDCH_PENDCH11_Pos) +#define DMAC_PENDCH_PENDCH_Pos 0 /**< \brief (DMAC_PENDCH) Pending Channel x */ +#define DMAC_PENDCH_PENDCH_Msk (0xFFFu << DMAC_PENDCH_PENDCH_Pos) +#define DMAC_PENDCH_PENDCH(value) ((DMAC_PENDCH_PENDCH_Msk & ((value) << DMAC_PENDCH_PENDCH_Pos))) +#define DMAC_PENDCH_MASK 0x00000FFFu /**< \brief (DMAC_PENDCH) MASK Register */ + +/* -------- DMAC_ACTIVE : (DMAC Offset: 0x30) (R/ 32) Active Channel and Levels -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t LVLEX0:1; /*!< bit: 0 Level 0 Channel Trigger Request Executing */ + uint32_t LVLEX1:1; /*!< bit: 1 Level 1 Channel Trigger Request Executing */ + uint32_t LVLEX2:1; /*!< bit: 2 Level 2 Channel Trigger Request Executing */ + uint32_t LVLEX3:1; /*!< bit: 3 Level 3 Channel Trigger Request Executing */ + uint32_t :4; /*!< bit: 4.. 7 Reserved */ + uint32_t ID:5; /*!< bit: 8..12 Active Channel ID */ + uint32_t :2; /*!< bit: 13..14 Reserved */ + uint32_t ABUSY:1; /*!< bit: 15 Active Channel Busy */ + uint32_t BTCNT:16; /*!< bit: 16..31 Active Channel Block Transfer Count */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t LVLEX:4; /*!< bit: 0.. 3 Level x Channel Trigger Request Executing */ + uint32_t :28; /*!< bit: 4..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_ACTIVE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_ACTIVE_OFFSET 0x30 /**< \brief (DMAC_ACTIVE offset) Active Channel and Levels */ +#define DMAC_ACTIVE_RESETVALUE 0x00000000 /**< \brief (DMAC_ACTIVE reset_value) Active Channel and Levels */ + +#define DMAC_ACTIVE_LVLEX0_Pos 0 /**< \brief (DMAC_ACTIVE) Level 0 Channel Trigger Request Executing */ +#define DMAC_ACTIVE_LVLEX0 (1 << DMAC_ACTIVE_LVLEX0_Pos) +#define DMAC_ACTIVE_LVLEX1_Pos 1 /**< \brief (DMAC_ACTIVE) Level 1 Channel Trigger Request Executing */ +#define DMAC_ACTIVE_LVLEX1 (1 << DMAC_ACTIVE_LVLEX1_Pos) +#define DMAC_ACTIVE_LVLEX2_Pos 2 /**< \brief (DMAC_ACTIVE) Level 2 Channel Trigger Request Executing */ +#define DMAC_ACTIVE_LVLEX2 (1 << DMAC_ACTIVE_LVLEX2_Pos) +#define DMAC_ACTIVE_LVLEX3_Pos 3 /**< \brief (DMAC_ACTIVE) Level 3 Channel Trigger Request Executing */ +#define DMAC_ACTIVE_LVLEX3 (1 << DMAC_ACTIVE_LVLEX3_Pos) +#define DMAC_ACTIVE_LVLEX_Pos 0 /**< \brief (DMAC_ACTIVE) Level x Channel Trigger Request Executing */ +#define DMAC_ACTIVE_LVLEX_Msk (0xFu << DMAC_ACTIVE_LVLEX_Pos) +#define DMAC_ACTIVE_LVLEX(value) ((DMAC_ACTIVE_LVLEX_Msk & ((value) << DMAC_ACTIVE_LVLEX_Pos))) +#define DMAC_ACTIVE_ID_Pos 8 /**< \brief (DMAC_ACTIVE) Active Channel ID */ +#define DMAC_ACTIVE_ID_Msk (0x1Fu << DMAC_ACTIVE_ID_Pos) +#define DMAC_ACTIVE_ID(value) ((DMAC_ACTIVE_ID_Msk & ((value) << DMAC_ACTIVE_ID_Pos))) +#define DMAC_ACTIVE_ABUSY_Pos 15 /**< \brief (DMAC_ACTIVE) Active Channel Busy */ +#define DMAC_ACTIVE_ABUSY (0x1u << DMAC_ACTIVE_ABUSY_Pos) +#define DMAC_ACTIVE_BTCNT_Pos 16 /**< \brief (DMAC_ACTIVE) Active Channel Block Transfer Count */ +#define DMAC_ACTIVE_BTCNT_Msk (0xFFFFu << DMAC_ACTIVE_BTCNT_Pos) +#define DMAC_ACTIVE_BTCNT(value) ((DMAC_ACTIVE_BTCNT_Msk & ((value) << DMAC_ACTIVE_BTCNT_Pos))) +#define DMAC_ACTIVE_MASK 0xFFFF9F0Fu /**< \brief (DMAC_ACTIVE) MASK Register */ + +/* -------- DMAC_BASEADDR : (DMAC Offset: 0x34) (R/W 32) Descriptor Memory Section Base Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t BASEADDR:32; /*!< bit: 0..31 Descriptor Memory Base Address */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_BASEADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_BASEADDR_OFFSET 0x34 /**< \brief (DMAC_BASEADDR offset) Descriptor Memory Section Base Address */ +#define DMAC_BASEADDR_RESETVALUE 0x00000000 /**< \brief (DMAC_BASEADDR reset_value) Descriptor Memory Section Base Address */ + +#define DMAC_BASEADDR_BASEADDR_Pos 0 /**< \brief (DMAC_BASEADDR) Descriptor Memory Base Address */ +#define DMAC_BASEADDR_BASEADDR_Msk (0xFFFFFFFFu << DMAC_BASEADDR_BASEADDR_Pos) +#define DMAC_BASEADDR_BASEADDR(value) ((DMAC_BASEADDR_BASEADDR_Msk & ((value) << DMAC_BASEADDR_BASEADDR_Pos))) +#define DMAC_BASEADDR_MASK 0xFFFFFFFFu /**< \brief (DMAC_BASEADDR) MASK Register */ + +/* -------- DMAC_WRBADDR : (DMAC Offset: 0x38) (R/W 32) Write-Back Memory Section Base Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t WRBADDR:32; /*!< bit: 0..31 Write-Back Memory Base Address */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_WRBADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_WRBADDR_OFFSET 0x38 /**< \brief (DMAC_WRBADDR offset) Write-Back Memory Section Base Address */ +#define DMAC_WRBADDR_RESETVALUE 0x00000000 /**< \brief (DMAC_WRBADDR reset_value) Write-Back Memory Section Base Address */ + +#define DMAC_WRBADDR_WRBADDR_Pos 0 /**< \brief (DMAC_WRBADDR) Write-Back Memory Base Address */ +#define DMAC_WRBADDR_WRBADDR_Msk (0xFFFFFFFFu << DMAC_WRBADDR_WRBADDR_Pos) +#define DMAC_WRBADDR_WRBADDR(value) ((DMAC_WRBADDR_WRBADDR_Msk & ((value) << DMAC_WRBADDR_WRBADDR_Pos))) +#define DMAC_WRBADDR_MASK 0xFFFFFFFFu /**< \brief (DMAC_WRBADDR) MASK Register */ + +/* -------- DMAC_CHID : (DMAC Offset: 0x3F) (R/W 8) Channel ID -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t ID:4; /*!< bit: 0.. 3 Channel ID */ + uint8_t :4; /*!< bit: 4.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DMAC_CHID_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CHID_OFFSET 0x3F /**< \brief (DMAC_CHID offset) Channel ID */ +#define DMAC_CHID_RESETVALUE 0x00 /**< \brief (DMAC_CHID reset_value) Channel ID */ + +#define DMAC_CHID_ID_Pos 0 /**< \brief (DMAC_CHID) Channel ID */ +#define DMAC_CHID_ID_Msk (0xFu << DMAC_CHID_ID_Pos) +#define DMAC_CHID_ID(value) ((DMAC_CHID_ID_Msk & ((value) << DMAC_CHID_ID_Pos))) +#define DMAC_CHID_MASK 0x0Fu /**< \brief (DMAC_CHID) MASK Register */ + +/* -------- DMAC_CHCTRLA : (DMAC Offset: 0x40) (R/W 8) Channel Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Channel Software Reset */ + uint8_t ENABLE:1; /*!< bit: 1 Channel Enable */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DMAC_CHCTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CHCTRLA_OFFSET 0x40 /**< \brief (DMAC_CHCTRLA offset) Channel Control A */ +#define DMAC_CHCTRLA_RESETVALUE 0x00 /**< \brief (DMAC_CHCTRLA reset_value) Channel Control A */ + +#define DMAC_CHCTRLA_SWRST_Pos 0 /**< \brief (DMAC_CHCTRLA) Channel Software Reset */ +#define DMAC_CHCTRLA_SWRST (0x1u << DMAC_CHCTRLA_SWRST_Pos) +#define DMAC_CHCTRLA_ENABLE_Pos 1 /**< \brief (DMAC_CHCTRLA) Channel Enable */ +#define DMAC_CHCTRLA_ENABLE (0x1u << DMAC_CHCTRLA_ENABLE_Pos) +#define DMAC_CHCTRLA_MASK 0x03u /**< \brief (DMAC_CHCTRLA) MASK Register */ + +/* -------- DMAC_CHCTRLB : (DMAC Offset: 0x44) (R/W 32) Channel Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t EVACT:3; /*!< bit: 0.. 2 Event Input Action */ + uint32_t EVIE:1; /*!< bit: 3 Channel Event Input Enable */ + uint32_t EVOE:1; /*!< bit: 4 Channel Event Output Enable */ + uint32_t LVL:2; /*!< bit: 5.. 6 Channel Arbitration Level */ + uint32_t :1; /*!< bit: 7 Reserved */ + uint32_t TRIGSRC:6; /*!< bit: 8..13 Peripheral Trigger Source */ + uint32_t :8; /*!< bit: 14..21 Reserved */ + uint32_t TRIGACT:2; /*!< bit: 22..23 Trigger Action */ + uint32_t CMD:2; /*!< bit: 24..25 Software Command */ + uint32_t :6; /*!< bit: 26..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_CHCTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CHCTRLB_OFFSET 0x44 /**< \brief (DMAC_CHCTRLB offset) Channel Control B */ +#define DMAC_CHCTRLB_RESETVALUE 0x00000000 /**< \brief (DMAC_CHCTRLB reset_value) Channel Control B */ + +#define DMAC_CHCTRLB_EVACT_Pos 0 /**< \brief (DMAC_CHCTRLB) Event Input Action */ +#define DMAC_CHCTRLB_EVACT_Msk (0x7u << DMAC_CHCTRLB_EVACT_Pos) +#define DMAC_CHCTRLB_EVACT(value) ((DMAC_CHCTRLB_EVACT_Msk & ((value) << DMAC_CHCTRLB_EVACT_Pos))) +#define DMAC_CHCTRLB_EVACT_NOACT_Val 0x0u /**< \brief (DMAC_CHCTRLB) No action */ +#define DMAC_CHCTRLB_EVACT_TRIG_Val 0x1u /**< \brief (DMAC_CHCTRLB) Transfer and periodic transfer trigger */ +#define DMAC_CHCTRLB_EVACT_CTRIG_Val 0x2u /**< \brief (DMAC_CHCTRLB) Conditional transfer trigger */ +#define DMAC_CHCTRLB_EVACT_CBLOCK_Val 0x3u /**< \brief (DMAC_CHCTRLB) Conditional block transfer */ +#define DMAC_CHCTRLB_EVACT_SUSPEND_Val 0x4u /**< \brief (DMAC_CHCTRLB) Channel suspend operation */ +#define DMAC_CHCTRLB_EVACT_RESUME_Val 0x5u /**< \brief (DMAC_CHCTRLB) Channel resume operation */ +#define DMAC_CHCTRLB_EVACT_SSKIP_Val 0x6u /**< \brief (DMAC_CHCTRLB) Skip next block suspend action */ +#define DMAC_CHCTRLB_EVACT_NOACT (DMAC_CHCTRLB_EVACT_NOACT_Val << DMAC_CHCTRLB_EVACT_Pos) +#define DMAC_CHCTRLB_EVACT_TRIG (DMAC_CHCTRLB_EVACT_TRIG_Val << DMAC_CHCTRLB_EVACT_Pos) +#define DMAC_CHCTRLB_EVACT_CTRIG (DMAC_CHCTRLB_EVACT_CTRIG_Val << DMAC_CHCTRLB_EVACT_Pos) +#define DMAC_CHCTRLB_EVACT_CBLOCK (DMAC_CHCTRLB_EVACT_CBLOCK_Val << DMAC_CHCTRLB_EVACT_Pos) +#define DMAC_CHCTRLB_EVACT_SUSPEND (DMAC_CHCTRLB_EVACT_SUSPEND_Val << DMAC_CHCTRLB_EVACT_Pos) +#define DMAC_CHCTRLB_EVACT_RESUME (DMAC_CHCTRLB_EVACT_RESUME_Val << DMAC_CHCTRLB_EVACT_Pos) +#define DMAC_CHCTRLB_EVACT_SSKIP (DMAC_CHCTRLB_EVACT_SSKIP_Val << DMAC_CHCTRLB_EVACT_Pos) +#define DMAC_CHCTRLB_EVIE_Pos 3 /**< \brief (DMAC_CHCTRLB) Channel Event Input Enable */ +#define DMAC_CHCTRLB_EVIE (0x1u << DMAC_CHCTRLB_EVIE_Pos) +#define DMAC_CHCTRLB_EVOE_Pos 4 /**< \brief (DMAC_CHCTRLB) Channel Event Output Enable */ +#define DMAC_CHCTRLB_EVOE (0x1u << DMAC_CHCTRLB_EVOE_Pos) +#define DMAC_CHCTRLB_LVL_Pos 5 /**< \brief (DMAC_CHCTRLB) Channel Arbitration Level */ +#define DMAC_CHCTRLB_LVL_Msk (0x3u << DMAC_CHCTRLB_LVL_Pos) +#define DMAC_CHCTRLB_LVL(value) ((DMAC_CHCTRLB_LVL_Msk & ((value) << DMAC_CHCTRLB_LVL_Pos))) +#define DMAC_CHCTRLB_LVL_LVL0_Val 0x0u /**< \brief (DMAC_CHCTRLB) Channel Priority Level 0 */ +#define DMAC_CHCTRLB_LVL_LVL1_Val 0x1u /**< \brief (DMAC_CHCTRLB) Channel Priority Level 1 */ +#define DMAC_CHCTRLB_LVL_LVL2_Val 0x2u /**< \brief (DMAC_CHCTRLB) Channel Priority Level 2 */ +#define DMAC_CHCTRLB_LVL_LVL3_Val 0x3u /**< \brief (DMAC_CHCTRLB) Channel Priority Level 3 */ +#define DMAC_CHCTRLB_LVL_LVL0 (DMAC_CHCTRLB_LVL_LVL0_Val << DMAC_CHCTRLB_LVL_Pos) +#define DMAC_CHCTRLB_LVL_LVL1 (DMAC_CHCTRLB_LVL_LVL1_Val << DMAC_CHCTRLB_LVL_Pos) +#define DMAC_CHCTRLB_LVL_LVL2 (DMAC_CHCTRLB_LVL_LVL2_Val << DMAC_CHCTRLB_LVL_Pos) +#define DMAC_CHCTRLB_LVL_LVL3 (DMAC_CHCTRLB_LVL_LVL3_Val << DMAC_CHCTRLB_LVL_Pos) +#define DMAC_CHCTRLB_TRIGSRC_Pos 8 /**< \brief (DMAC_CHCTRLB) Peripheral Trigger Source */ +#define DMAC_CHCTRLB_TRIGSRC_Msk (0x3Fu << DMAC_CHCTRLB_TRIGSRC_Pos) +#define DMAC_CHCTRLB_TRIGSRC(value) ((DMAC_CHCTRLB_TRIGSRC_Msk & ((value) << DMAC_CHCTRLB_TRIGSRC_Pos))) +#define DMAC_CHCTRLB_TRIGSRC_DISABLE_Val 0x0u /**< \brief (DMAC_CHCTRLB) Only software/event triggers */ +#define DMAC_CHCTRLB_TRIGSRC_DISABLE (DMAC_CHCTRLB_TRIGSRC_DISABLE_Val << DMAC_CHCTRLB_TRIGSRC_Pos) +#define DMAC_CHCTRLB_TRIGACT_Pos 22 /**< \brief (DMAC_CHCTRLB) Trigger Action */ +#define DMAC_CHCTRLB_TRIGACT_Msk (0x3u << DMAC_CHCTRLB_TRIGACT_Pos) +#define DMAC_CHCTRLB_TRIGACT(value) ((DMAC_CHCTRLB_TRIGACT_Msk & ((value) << DMAC_CHCTRLB_TRIGACT_Pos))) +#define DMAC_CHCTRLB_TRIGACT_BLOCK_Val 0x0u /**< \brief (DMAC_CHCTRLB) One trigger required for each block transfer */ +#define DMAC_CHCTRLB_TRIGACT_BEAT_Val 0x2u /**< \brief (DMAC_CHCTRLB) One trigger required for each beat transfer */ +#define DMAC_CHCTRLB_TRIGACT_TRANSACTION_Val 0x3u /**< \brief (DMAC_CHCTRLB) One trigger required for each transaction */ +#define DMAC_CHCTRLB_TRIGACT_BLOCK (DMAC_CHCTRLB_TRIGACT_BLOCK_Val << DMAC_CHCTRLB_TRIGACT_Pos) +#define DMAC_CHCTRLB_TRIGACT_BEAT (DMAC_CHCTRLB_TRIGACT_BEAT_Val << DMAC_CHCTRLB_TRIGACT_Pos) +#define DMAC_CHCTRLB_TRIGACT_TRANSACTION (DMAC_CHCTRLB_TRIGACT_TRANSACTION_Val << DMAC_CHCTRLB_TRIGACT_Pos) +#define DMAC_CHCTRLB_CMD_Pos 24 /**< \brief (DMAC_CHCTRLB) Software Command */ +#define DMAC_CHCTRLB_CMD_Msk (0x3u << DMAC_CHCTRLB_CMD_Pos) +#define DMAC_CHCTRLB_CMD(value) ((DMAC_CHCTRLB_CMD_Msk & ((value) << DMAC_CHCTRLB_CMD_Pos))) +#define DMAC_CHCTRLB_CMD_NOACT_Val 0x0u /**< \brief (DMAC_CHCTRLB) No action */ +#define DMAC_CHCTRLB_CMD_SUSPEND_Val 0x1u /**< \brief (DMAC_CHCTRLB) Channel suspend operation */ +#define DMAC_CHCTRLB_CMD_RESUME_Val 0x2u /**< \brief (DMAC_CHCTRLB) Channel resume operation */ +#define DMAC_CHCTRLB_CMD_NOACT (DMAC_CHCTRLB_CMD_NOACT_Val << DMAC_CHCTRLB_CMD_Pos) +#define DMAC_CHCTRLB_CMD_SUSPEND (DMAC_CHCTRLB_CMD_SUSPEND_Val << DMAC_CHCTRLB_CMD_Pos) +#define DMAC_CHCTRLB_CMD_RESUME (DMAC_CHCTRLB_CMD_RESUME_Val << DMAC_CHCTRLB_CMD_Pos) +#define DMAC_CHCTRLB_MASK 0x03C03F7Fu /**< \brief (DMAC_CHCTRLB) MASK Register */ + +/* -------- DMAC_CHINTENCLR : (DMAC Offset: 0x4C) (R/W 8) Channel Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t TERR:1; /*!< bit: 0 Transfer Error Interrupt Enable */ + uint8_t TCMPL:1; /*!< bit: 1 Transfer Complete Interrupt Enable */ + uint8_t SUSP:1; /*!< bit: 2 Channel Suspend Interrupt Enable */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DMAC_CHINTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CHINTENCLR_OFFSET 0x4C /**< \brief (DMAC_CHINTENCLR offset) Channel Interrupt Enable Clear */ +#define DMAC_CHINTENCLR_RESETVALUE 0x00 /**< \brief (DMAC_CHINTENCLR reset_value) Channel Interrupt Enable Clear */ + +#define DMAC_CHINTENCLR_TERR_Pos 0 /**< \brief (DMAC_CHINTENCLR) Transfer Error Interrupt Enable */ +#define DMAC_CHINTENCLR_TERR (0x1u << DMAC_CHINTENCLR_TERR_Pos) +#define DMAC_CHINTENCLR_TCMPL_Pos 1 /**< \brief (DMAC_CHINTENCLR) Transfer Complete Interrupt Enable */ +#define DMAC_CHINTENCLR_TCMPL (0x1u << DMAC_CHINTENCLR_TCMPL_Pos) +#define DMAC_CHINTENCLR_SUSP_Pos 2 /**< \brief (DMAC_CHINTENCLR) Channel Suspend Interrupt Enable */ +#define DMAC_CHINTENCLR_SUSP (0x1u << DMAC_CHINTENCLR_SUSP_Pos) +#define DMAC_CHINTENCLR_MASK 0x07u /**< \brief (DMAC_CHINTENCLR) MASK Register */ + +/* -------- DMAC_CHINTENSET : (DMAC Offset: 0x4D) (R/W 8) Channel Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t TERR:1; /*!< bit: 0 Transfer Error Interrupt Enable */ + uint8_t TCMPL:1; /*!< bit: 1 Transfer Complete Interrupt Enable */ + uint8_t SUSP:1; /*!< bit: 2 Channel Suspend Interrupt Enable */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DMAC_CHINTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CHINTENSET_OFFSET 0x4D /**< \brief (DMAC_CHINTENSET offset) Channel Interrupt Enable Set */ +#define DMAC_CHINTENSET_RESETVALUE 0x00 /**< \brief (DMAC_CHINTENSET reset_value) Channel Interrupt Enable Set */ + +#define DMAC_CHINTENSET_TERR_Pos 0 /**< \brief (DMAC_CHINTENSET) Transfer Error Interrupt Enable */ +#define DMAC_CHINTENSET_TERR (0x1u << DMAC_CHINTENSET_TERR_Pos) +#define DMAC_CHINTENSET_TCMPL_Pos 1 /**< \brief (DMAC_CHINTENSET) Transfer Complete Interrupt Enable */ +#define DMAC_CHINTENSET_TCMPL (0x1u << DMAC_CHINTENSET_TCMPL_Pos) +#define DMAC_CHINTENSET_SUSP_Pos 2 /**< \brief (DMAC_CHINTENSET) Channel Suspend Interrupt Enable */ +#define DMAC_CHINTENSET_SUSP (0x1u << DMAC_CHINTENSET_SUSP_Pos) +#define DMAC_CHINTENSET_MASK 0x07u /**< \brief (DMAC_CHINTENSET) MASK Register */ + +/* -------- DMAC_CHINTFLAG : (DMAC Offset: 0x4E) (R/W 8) Channel Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t TERR:1; /*!< bit: 0 Transfer Error */ + uint8_t TCMPL:1; /*!< bit: 1 Transfer Complete */ + uint8_t SUSP:1; /*!< bit: 2 Channel Suspend */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DMAC_CHINTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CHINTFLAG_OFFSET 0x4E /**< \brief (DMAC_CHINTFLAG offset) Channel Interrupt Flag Status and Clear */ +#define DMAC_CHINTFLAG_RESETVALUE 0x00 /**< \brief (DMAC_CHINTFLAG reset_value) Channel Interrupt Flag Status and Clear */ + +#define DMAC_CHINTFLAG_TERR_Pos 0 /**< \brief (DMAC_CHINTFLAG) Transfer Error */ +#define DMAC_CHINTFLAG_TERR (0x1u << DMAC_CHINTFLAG_TERR_Pos) +#define DMAC_CHINTFLAG_TCMPL_Pos 1 /**< \brief (DMAC_CHINTFLAG) Transfer Complete */ +#define DMAC_CHINTFLAG_TCMPL (0x1u << DMAC_CHINTFLAG_TCMPL_Pos) +#define DMAC_CHINTFLAG_SUSP_Pos 2 /**< \brief (DMAC_CHINTFLAG) Channel Suspend */ +#define DMAC_CHINTFLAG_SUSP (0x1u << DMAC_CHINTFLAG_SUSP_Pos) +#define DMAC_CHINTFLAG_MASK 0x07u /**< \brief (DMAC_CHINTFLAG) MASK Register */ + +/* -------- DMAC_CHSTATUS : (DMAC Offset: 0x4F) (R/ 8) Channel Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PEND:1; /*!< bit: 0 Channel Pending */ + uint8_t BUSY:1; /*!< bit: 1 Channel Busy */ + uint8_t FERR:1; /*!< bit: 2 Fetch Error */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DMAC_CHSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CHSTATUS_OFFSET 0x4F /**< \brief (DMAC_CHSTATUS offset) Channel Status */ +#define DMAC_CHSTATUS_RESETVALUE 0x00 /**< \brief (DMAC_CHSTATUS reset_value) Channel Status */ + +#define DMAC_CHSTATUS_PEND_Pos 0 /**< \brief (DMAC_CHSTATUS) Channel Pending */ +#define DMAC_CHSTATUS_PEND (0x1u << DMAC_CHSTATUS_PEND_Pos) +#define DMAC_CHSTATUS_BUSY_Pos 1 /**< \brief (DMAC_CHSTATUS) Channel Busy */ +#define DMAC_CHSTATUS_BUSY (0x1u << DMAC_CHSTATUS_BUSY_Pos) +#define DMAC_CHSTATUS_FERR_Pos 2 /**< \brief (DMAC_CHSTATUS) Fetch Error */ +#define DMAC_CHSTATUS_FERR (0x1u << DMAC_CHSTATUS_FERR_Pos) +#define DMAC_CHSTATUS_MASK 0x07u /**< \brief (DMAC_CHSTATUS) MASK Register */ + +/* -------- DMAC_BTCTRL : (DMAC Offset: 0x00) (R/W 16) Block Transfer Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t VALID:1; /*!< bit: 0 Descriptor Valid */ + uint16_t EVOSEL:2; /*!< bit: 1.. 2 Event Output Selection */ + uint16_t BLOCKACT:2; /*!< bit: 3.. 4 Block Action */ + uint16_t :3; /*!< bit: 5.. 7 Reserved */ + uint16_t BEATSIZE:2; /*!< bit: 8.. 9 Beat Size */ + uint16_t SRCINC:1; /*!< bit: 10 Source Address Increment Enable */ + uint16_t DSTINC:1; /*!< bit: 11 Destination Address Increment Enable */ + uint16_t STEPSEL:1; /*!< bit: 12 Step Selection */ + uint16_t STEPSIZE:3; /*!< bit: 13..15 Address Increment Step Size */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} DMAC_BTCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_BTCTRL_OFFSET 0x00 /**< \brief (DMAC_BTCTRL offset) Block Transfer Control */ + +#define DMAC_BTCTRL_VALID_Pos 0 /**< \brief (DMAC_BTCTRL) Descriptor Valid */ +#define DMAC_BTCTRL_VALID (0x1u << DMAC_BTCTRL_VALID_Pos) +#define DMAC_BTCTRL_EVOSEL_Pos 1 /**< \brief (DMAC_BTCTRL) Event Output Selection */ +#define DMAC_BTCTRL_EVOSEL_Msk (0x3u << DMAC_BTCTRL_EVOSEL_Pos) +#define DMAC_BTCTRL_EVOSEL(value) ((DMAC_BTCTRL_EVOSEL_Msk & ((value) << DMAC_BTCTRL_EVOSEL_Pos))) +#define DMAC_BTCTRL_EVOSEL_DISABLE_Val 0x0u /**< \brief (DMAC_BTCTRL) Event generation disabled */ +#define DMAC_BTCTRL_EVOSEL_BLOCK_Val 0x1u /**< \brief (DMAC_BTCTRL) Event strobe when block transfer complete */ +#define DMAC_BTCTRL_EVOSEL_BEAT_Val 0x3u /**< \brief (DMAC_BTCTRL) Event strobe when beat transfer complete */ +#define DMAC_BTCTRL_EVOSEL_DISABLE (DMAC_BTCTRL_EVOSEL_DISABLE_Val << DMAC_BTCTRL_EVOSEL_Pos) +#define DMAC_BTCTRL_EVOSEL_BLOCK (DMAC_BTCTRL_EVOSEL_BLOCK_Val << DMAC_BTCTRL_EVOSEL_Pos) +#define DMAC_BTCTRL_EVOSEL_BEAT (DMAC_BTCTRL_EVOSEL_BEAT_Val << DMAC_BTCTRL_EVOSEL_Pos) +#define DMAC_BTCTRL_BLOCKACT_Pos 3 /**< \brief (DMAC_BTCTRL) Block Action */ +#define DMAC_BTCTRL_BLOCKACT_Msk (0x3u << DMAC_BTCTRL_BLOCKACT_Pos) +#define DMAC_BTCTRL_BLOCKACT(value) ((DMAC_BTCTRL_BLOCKACT_Msk & ((value) << DMAC_BTCTRL_BLOCKACT_Pos))) +#define DMAC_BTCTRL_BLOCKACT_NOACT_Val 0x0u /**< \brief (DMAC_BTCTRL) No action */ +#define DMAC_BTCTRL_BLOCKACT_INT_Val 0x1u /**< \brief (DMAC_BTCTRL) Channel in normal operation and block interrupt */ +#define DMAC_BTCTRL_BLOCKACT_SUSPEND_Val 0x2u /**< \brief (DMAC_BTCTRL) Channel suspend operation is completed */ +#define DMAC_BTCTRL_BLOCKACT_BOTH_Val 0x3u /**< \brief (DMAC_BTCTRL) Both channel suspend operation and block interrupt */ +#define DMAC_BTCTRL_BLOCKACT_NOACT (DMAC_BTCTRL_BLOCKACT_NOACT_Val << DMAC_BTCTRL_BLOCKACT_Pos) +#define DMAC_BTCTRL_BLOCKACT_INT (DMAC_BTCTRL_BLOCKACT_INT_Val << DMAC_BTCTRL_BLOCKACT_Pos) +#define DMAC_BTCTRL_BLOCKACT_SUSPEND (DMAC_BTCTRL_BLOCKACT_SUSPEND_Val << DMAC_BTCTRL_BLOCKACT_Pos) +#define DMAC_BTCTRL_BLOCKACT_BOTH (DMAC_BTCTRL_BLOCKACT_BOTH_Val << DMAC_BTCTRL_BLOCKACT_Pos) +#define DMAC_BTCTRL_BEATSIZE_Pos 8 /**< \brief (DMAC_BTCTRL) Beat Size */ +#define DMAC_BTCTRL_BEATSIZE_Msk (0x3u << DMAC_BTCTRL_BEATSIZE_Pos) +#define DMAC_BTCTRL_BEATSIZE(value) ((DMAC_BTCTRL_BEATSIZE_Msk & ((value) << DMAC_BTCTRL_BEATSIZE_Pos))) +#define DMAC_BTCTRL_BEATSIZE_BYTE_Val 0x0u /**< \brief (DMAC_BTCTRL) 8-bit access */ +#define DMAC_BTCTRL_BEATSIZE_HWORD_Val 0x1u /**< \brief (DMAC_BTCTRL) 16-bit access */ +#define DMAC_BTCTRL_BEATSIZE_WORD_Val 0x2u /**< \brief (DMAC_BTCTRL) 32-bit access */ +#define DMAC_BTCTRL_BEATSIZE_BYTE (DMAC_BTCTRL_BEATSIZE_BYTE_Val << DMAC_BTCTRL_BEATSIZE_Pos) +#define DMAC_BTCTRL_BEATSIZE_HWORD (DMAC_BTCTRL_BEATSIZE_HWORD_Val << DMAC_BTCTRL_BEATSIZE_Pos) +#define DMAC_BTCTRL_BEATSIZE_WORD (DMAC_BTCTRL_BEATSIZE_WORD_Val << DMAC_BTCTRL_BEATSIZE_Pos) +#define DMAC_BTCTRL_SRCINC_Pos 10 /**< \brief (DMAC_BTCTRL) Source Address Increment Enable */ +#define DMAC_BTCTRL_SRCINC (0x1u << DMAC_BTCTRL_SRCINC_Pos) +#define DMAC_BTCTRL_DSTINC_Pos 11 /**< \brief (DMAC_BTCTRL) Destination Address Increment Enable */ +#define DMAC_BTCTRL_DSTINC (0x1u << DMAC_BTCTRL_DSTINC_Pos) +#define DMAC_BTCTRL_STEPSEL_Pos 12 /**< \brief (DMAC_BTCTRL) Step Selection */ +#define DMAC_BTCTRL_STEPSEL (0x1u << DMAC_BTCTRL_STEPSEL_Pos) +#define DMAC_BTCTRL_STEPSEL_DST_Val 0x0u /**< \brief (DMAC_BTCTRL) Step size settings apply to the destination address */ +#define DMAC_BTCTRL_STEPSEL_SRC_Val 0x1u /**< \brief (DMAC_BTCTRL) Step size settings apply to the source address */ +#define DMAC_BTCTRL_STEPSEL_DST (DMAC_BTCTRL_STEPSEL_DST_Val << DMAC_BTCTRL_STEPSEL_Pos) +#define DMAC_BTCTRL_STEPSEL_SRC (DMAC_BTCTRL_STEPSEL_SRC_Val << DMAC_BTCTRL_STEPSEL_Pos) +#define DMAC_BTCTRL_STEPSIZE_Pos 13 /**< \brief (DMAC_BTCTRL) Address Increment Step Size */ +#define DMAC_BTCTRL_STEPSIZE_Msk (0x7u << DMAC_BTCTRL_STEPSIZE_Pos) +#define DMAC_BTCTRL_STEPSIZE(value) ((DMAC_BTCTRL_STEPSIZE_Msk & ((value) << DMAC_BTCTRL_STEPSIZE_Pos))) +#define DMAC_BTCTRL_STEPSIZE_X1_Val 0x0u /**< \brief (DMAC_BTCTRL) Next ADDR <- ADDR + BEATSIZE * 1 */ +#define DMAC_BTCTRL_STEPSIZE_X2_Val 0x1u /**< \brief (DMAC_BTCTRL) Next ADDR <- ADDR + BEATSIZE * 2 */ +#define DMAC_BTCTRL_STEPSIZE_X4_Val 0x2u /**< \brief (DMAC_BTCTRL) Next ADDR <- ADDR + BEATSIZE * 4 */ +#define DMAC_BTCTRL_STEPSIZE_X8_Val 0x3u /**< \brief (DMAC_BTCTRL) Next ADDR <- ADDR + BEATSIZE * 8 */ +#define DMAC_BTCTRL_STEPSIZE_X16_Val 0x4u /**< \brief (DMAC_BTCTRL) Next ADDR <- ADDR + BEATSIZE * 16 */ +#define DMAC_BTCTRL_STEPSIZE_X32_Val 0x5u /**< \brief (DMAC_BTCTRL) Next ADDR <- ADDR + BEATSIZE * 32 */ +#define DMAC_BTCTRL_STEPSIZE_X64_Val 0x6u /**< \brief (DMAC_BTCTRL) Next ADDR <- ADDR + BEATSIZE * 64 */ +#define DMAC_BTCTRL_STEPSIZE_X128_Val 0x7u /**< \brief (DMAC_BTCTRL) Next ADDR <- ADDR + BEATSIZE * 128 */ +#define DMAC_BTCTRL_STEPSIZE_X1 (DMAC_BTCTRL_STEPSIZE_X1_Val << DMAC_BTCTRL_STEPSIZE_Pos) +#define DMAC_BTCTRL_STEPSIZE_X2 (DMAC_BTCTRL_STEPSIZE_X2_Val << DMAC_BTCTRL_STEPSIZE_Pos) +#define DMAC_BTCTRL_STEPSIZE_X4 (DMAC_BTCTRL_STEPSIZE_X4_Val << DMAC_BTCTRL_STEPSIZE_Pos) +#define DMAC_BTCTRL_STEPSIZE_X8 (DMAC_BTCTRL_STEPSIZE_X8_Val << DMAC_BTCTRL_STEPSIZE_Pos) +#define DMAC_BTCTRL_STEPSIZE_X16 (DMAC_BTCTRL_STEPSIZE_X16_Val << DMAC_BTCTRL_STEPSIZE_Pos) +#define DMAC_BTCTRL_STEPSIZE_X32 (DMAC_BTCTRL_STEPSIZE_X32_Val << DMAC_BTCTRL_STEPSIZE_Pos) +#define DMAC_BTCTRL_STEPSIZE_X64 (DMAC_BTCTRL_STEPSIZE_X64_Val << DMAC_BTCTRL_STEPSIZE_Pos) +#define DMAC_BTCTRL_STEPSIZE_X128 (DMAC_BTCTRL_STEPSIZE_X128_Val << DMAC_BTCTRL_STEPSIZE_Pos) +#define DMAC_BTCTRL_MASK 0xFF1Fu /**< \brief (DMAC_BTCTRL) MASK Register */ + +/* -------- DMAC_BTCNT : (DMAC Offset: 0x02) (R/W 16) Block Transfer Count -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t BTCNT:16; /*!< bit: 0..15 Block Transfer Count */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} DMAC_BTCNT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_BTCNT_OFFSET 0x02 /**< \brief (DMAC_BTCNT offset) Block Transfer Count */ + +#define DMAC_BTCNT_BTCNT_Pos 0 /**< \brief (DMAC_BTCNT) Block Transfer Count */ +#define DMAC_BTCNT_BTCNT_Msk (0xFFFFu << DMAC_BTCNT_BTCNT_Pos) +#define DMAC_BTCNT_BTCNT(value) ((DMAC_BTCNT_BTCNT_Msk & ((value) << DMAC_BTCNT_BTCNT_Pos))) +#define DMAC_BTCNT_MASK 0xFFFFu /**< \brief (DMAC_BTCNT) MASK Register */ + +/* -------- DMAC_SRCADDR : (DMAC Offset: 0x04) (R/W 32) Transfer Source Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SRCADDR:32; /*!< bit: 0..31 Transfer Source Address */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_SRCADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_SRCADDR_OFFSET 0x04 /**< \brief (DMAC_SRCADDR offset) Transfer Source Address */ + +#define DMAC_SRCADDR_SRCADDR_Pos 0 /**< \brief (DMAC_SRCADDR) Transfer Source Address */ +#define DMAC_SRCADDR_SRCADDR_Msk (0xFFFFFFFFu << DMAC_SRCADDR_SRCADDR_Pos) +#define DMAC_SRCADDR_SRCADDR(value) ((DMAC_SRCADDR_SRCADDR_Msk & ((value) << DMAC_SRCADDR_SRCADDR_Pos))) +#define DMAC_SRCADDR_MASK 0xFFFFFFFFu /**< \brief (DMAC_SRCADDR) MASK Register */ + +/* -------- DMAC_DSTADDR : (DMAC Offset: 0x08) (R/W 32) Transfer Destination Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DSTADDR:32; /*!< bit: 0..31 Transfer Destination Address */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_DSTADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_DSTADDR_OFFSET 0x08 /**< \brief (DMAC_DSTADDR offset) Transfer Destination Address */ + +#define DMAC_DSTADDR_DSTADDR_Pos 0 /**< \brief (DMAC_DSTADDR) Transfer Destination Address */ +#define DMAC_DSTADDR_DSTADDR_Msk (0xFFFFFFFFu << DMAC_DSTADDR_DSTADDR_Pos) +#define DMAC_DSTADDR_DSTADDR(value) ((DMAC_DSTADDR_DSTADDR_Msk & ((value) << DMAC_DSTADDR_DSTADDR_Pos))) +#define DMAC_DSTADDR_MASK 0xFFFFFFFFu /**< \brief (DMAC_DSTADDR) MASK Register */ + +/* -------- DMAC_DESCADDR : (DMAC Offset: 0x0C) (R/W 32) Next Descriptor Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DESCADDR:32; /*!< bit: 0..31 Next Descriptor Address */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_DESCADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_DESCADDR_OFFSET 0x0C /**< \brief (DMAC_DESCADDR offset) Next Descriptor Address */ + +#define DMAC_DESCADDR_DESCADDR_Pos 0 /**< \brief (DMAC_DESCADDR) Next Descriptor Address */ +#define DMAC_DESCADDR_DESCADDR_Msk (0xFFFFFFFFu << DMAC_DESCADDR_DESCADDR_Pos) +#define DMAC_DESCADDR_DESCADDR(value) ((DMAC_DESCADDR_DESCADDR_Msk & ((value) << DMAC_DESCADDR_DESCADDR_Pos))) +#define DMAC_DESCADDR_MASK 0xFFFFFFFFu /**< \brief (DMAC_DESCADDR) MASK Register */ + +/** \brief DMAC APB hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO DMAC_CTRL_Type CTRL; /**< \brief Offset: 0x00 (R/W 16) Control */ + __IO DMAC_CRCCTRL_Type CRCCTRL; /**< \brief Offset: 0x02 (R/W 16) CRC Control */ + __IO DMAC_CRCDATAIN_Type CRCDATAIN; /**< \brief Offset: 0x04 (R/W 32) CRC Data Input */ + __IO DMAC_CRCCHKSUM_Type CRCCHKSUM; /**< \brief Offset: 0x08 (R/W 32) CRC Checksum */ + __IO DMAC_CRCSTATUS_Type CRCSTATUS; /**< \brief Offset: 0x0C (R/W 8) CRC Status */ + __IO DMAC_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x0D (R/W 8) Debug Control */ + RoReg8 Reserved1[0x2]; + __IO DMAC_SWTRIGCTRL_Type SWTRIGCTRL; /**< \brief Offset: 0x10 (R/W 32) Software Trigger Control */ + __IO DMAC_PRICTRL0_Type PRICTRL0; /**< \brief Offset: 0x14 (R/W 32) Priority Control 0 */ + RoReg8 Reserved2[0x8]; + __IO DMAC_INTPEND_Type INTPEND; /**< \brief Offset: 0x20 (R/W 16) Interrupt Pending */ + RoReg8 Reserved3[0x2]; + __I DMAC_INTSTATUS_Type INTSTATUS; /**< \brief Offset: 0x24 (R/ 32) Interrupt Status */ + __I DMAC_BUSYCH_Type BUSYCH; /**< \brief Offset: 0x28 (R/ 32) Busy Channels */ + __I DMAC_PENDCH_Type PENDCH; /**< \brief Offset: 0x2C (R/ 32) Pending Channels */ + __I DMAC_ACTIVE_Type ACTIVE; /**< \brief Offset: 0x30 (R/ 32) Active Channel and Levels */ + __IO DMAC_BASEADDR_Type BASEADDR; /**< \brief Offset: 0x34 (R/W 32) Descriptor Memory Section Base Address */ + __IO DMAC_WRBADDR_Type WRBADDR; /**< \brief Offset: 0x38 (R/W 32) Write-Back Memory Section Base Address */ + RoReg8 Reserved4[0x3]; + __IO DMAC_CHID_Type CHID; /**< \brief Offset: 0x3F (R/W 8) Channel ID */ + __IO DMAC_CHCTRLA_Type CHCTRLA; /**< \brief Offset: 0x40 (R/W 8) Channel Control A */ + RoReg8 Reserved5[0x3]; + __IO DMAC_CHCTRLB_Type CHCTRLB; /**< \brief Offset: 0x44 (R/W 32) Channel Control B */ + RoReg8 Reserved6[0x4]; + __IO DMAC_CHINTENCLR_Type CHINTENCLR; /**< \brief Offset: 0x4C (R/W 8) Channel Interrupt Enable Clear */ + __IO DMAC_CHINTENSET_Type CHINTENSET; /**< \brief Offset: 0x4D (R/W 8) Channel Interrupt Enable Set */ + __IO DMAC_CHINTFLAG_Type CHINTFLAG; /**< \brief Offset: 0x4E (R/W 8) Channel Interrupt Flag Status and Clear */ + __I DMAC_CHSTATUS_Type CHSTATUS; /**< \brief Offset: 0x4F (R/ 8) Channel Status */ +} Dmac; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief DMAC Descriptor SRAM registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO DMAC_BTCTRL_Type BTCTRL; /**< \brief Offset: 0x00 (R/W 16) Block Transfer Control */ + __IO DMAC_BTCNT_Type BTCNT; /**< \brief Offset: 0x02 (R/W 16) Block Transfer Count */ + __IO DMAC_SRCADDR_Type SRCADDR; /**< \brief Offset: 0x04 (R/W 32) Transfer Source Address */ + __IO DMAC_DSTADDR_Type DSTADDR; /**< \brief Offset: 0x08 (R/W 32) Transfer Destination Address */ + __IO DMAC_DESCADDR_Type DESCADDR; /**< \brief Offset: 0x0C (R/W 32) Next Descriptor Address */ +} DmacDescriptor +#ifdef __GNUC__ + __attribute__ ((aligned (8))) +#endif +; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +#define SECTION_DMAC_DESCRIPTOR + +/*@}*/ + +#endif /* _SAMD21_DMAC_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/dsu.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/dsu.h new file mode 100644 index 0000000..2a08ea2 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/dsu.h @@ -0,0 +1,551 @@ +/** + * \file + * + * \brief Component description for DSU + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_DSU_COMPONENT_ +#define _SAMD21_DSU_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR DSU */ +/* ========================================================================== */ +/** \addtogroup SAMD21_DSU Device Service Unit */ +/*@{*/ + +#define DSU_U2209 +#define REV_DSU 0x200 + +/* -------- DSU_CTRL : (DSU Offset: 0x0000) ( /W 8) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset */ + uint8_t :1; /*!< bit: 1 Reserved */ + uint8_t CRC:1; /*!< bit: 2 32-bit Cyclic Redundancy Check */ + uint8_t MBIST:1; /*!< bit: 3 Memory Built-In Self-Test */ + uint8_t CE:1; /*!< bit: 4 Chip Erase */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DSU_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_CTRL_OFFSET 0x0000 /**< \brief (DSU_CTRL offset) Control */ +#define DSU_CTRL_RESETVALUE 0x00 /**< \brief (DSU_CTRL reset_value) Control */ + +#define DSU_CTRL_SWRST_Pos 0 /**< \brief (DSU_CTRL) Software Reset */ +#define DSU_CTRL_SWRST (0x1u << DSU_CTRL_SWRST_Pos) +#define DSU_CTRL_CRC_Pos 2 /**< \brief (DSU_CTRL) 32-bit Cyclic Redundancy Check */ +#define DSU_CTRL_CRC (0x1u << DSU_CTRL_CRC_Pos) +#define DSU_CTRL_MBIST_Pos 3 /**< \brief (DSU_CTRL) Memory Built-In Self-Test */ +#define DSU_CTRL_MBIST (0x1u << DSU_CTRL_MBIST_Pos) +#define DSU_CTRL_CE_Pos 4 /**< \brief (DSU_CTRL) Chip Erase */ +#define DSU_CTRL_CE (0x1u << DSU_CTRL_CE_Pos) +#define DSU_CTRL_MASK 0x1Du /**< \brief (DSU_CTRL) MASK Register */ + +/* -------- DSU_STATUSA : (DSU Offset: 0x0001) (R/W 8) Status A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DONE:1; /*!< bit: 0 Done */ + uint8_t CRSTEXT:1; /*!< bit: 1 CPU Reset Phase Extension */ + uint8_t BERR:1; /*!< bit: 2 Bus Error */ + uint8_t FAIL:1; /*!< bit: 3 Failure */ + uint8_t PERR:1; /*!< bit: 4 Protection Error */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DSU_STATUSA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_STATUSA_OFFSET 0x0001 /**< \brief (DSU_STATUSA offset) Status A */ +#define DSU_STATUSA_RESETVALUE 0x00 /**< \brief (DSU_STATUSA reset_value) Status A */ + +#define DSU_STATUSA_DONE_Pos 0 /**< \brief (DSU_STATUSA) Done */ +#define DSU_STATUSA_DONE (0x1u << DSU_STATUSA_DONE_Pos) +#define DSU_STATUSA_CRSTEXT_Pos 1 /**< \brief (DSU_STATUSA) CPU Reset Phase Extension */ +#define DSU_STATUSA_CRSTEXT (0x1u << DSU_STATUSA_CRSTEXT_Pos) +#define DSU_STATUSA_BERR_Pos 2 /**< \brief (DSU_STATUSA) Bus Error */ +#define DSU_STATUSA_BERR (0x1u << DSU_STATUSA_BERR_Pos) +#define DSU_STATUSA_FAIL_Pos 3 /**< \brief (DSU_STATUSA) Failure */ +#define DSU_STATUSA_FAIL (0x1u << DSU_STATUSA_FAIL_Pos) +#define DSU_STATUSA_PERR_Pos 4 /**< \brief (DSU_STATUSA) Protection Error */ +#define DSU_STATUSA_PERR (0x1u << DSU_STATUSA_PERR_Pos) +#define DSU_STATUSA_MASK 0x1Fu /**< \brief (DSU_STATUSA) MASK Register */ + +/* -------- DSU_STATUSB : (DSU Offset: 0x0002) (R/ 8) Status B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PROT:1; /*!< bit: 0 Protected */ + uint8_t DBGPRES:1; /*!< bit: 1 Debugger Present */ + uint8_t DCCD0:1; /*!< bit: 2 Debug Communication Channel 0 Dirty */ + uint8_t DCCD1:1; /*!< bit: 3 Debug Communication Channel 1 Dirty */ + uint8_t HPE:1; /*!< bit: 4 Hot-Plugging Enable */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t :2; /*!< bit: 0.. 1 Reserved */ + uint8_t DCCD:2; /*!< bit: 2.. 3 Debug Communication Channel x Dirty */ + uint8_t :4; /*!< bit: 4.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} DSU_STATUSB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_STATUSB_OFFSET 0x0002 /**< \brief (DSU_STATUSB offset) Status B */ +#define DSU_STATUSB_RESETVALUE 0x10 /**< \brief (DSU_STATUSB reset_value) Status B */ + +#define DSU_STATUSB_PROT_Pos 0 /**< \brief (DSU_STATUSB) Protected */ +#define DSU_STATUSB_PROT (0x1u << DSU_STATUSB_PROT_Pos) +#define DSU_STATUSB_DBGPRES_Pos 1 /**< \brief (DSU_STATUSB) Debugger Present */ +#define DSU_STATUSB_DBGPRES (0x1u << DSU_STATUSB_DBGPRES_Pos) +#define DSU_STATUSB_DCCD0_Pos 2 /**< \brief (DSU_STATUSB) Debug Communication Channel 0 Dirty */ +#define DSU_STATUSB_DCCD0 (1 << DSU_STATUSB_DCCD0_Pos) +#define DSU_STATUSB_DCCD1_Pos 3 /**< \brief (DSU_STATUSB) Debug Communication Channel 1 Dirty */ +#define DSU_STATUSB_DCCD1 (1 << DSU_STATUSB_DCCD1_Pos) +#define DSU_STATUSB_DCCD_Pos 2 /**< \brief (DSU_STATUSB) Debug Communication Channel x Dirty */ +#define DSU_STATUSB_DCCD_Msk (0x3u << DSU_STATUSB_DCCD_Pos) +#define DSU_STATUSB_DCCD(value) ((DSU_STATUSB_DCCD_Msk & ((value) << DSU_STATUSB_DCCD_Pos))) +#define DSU_STATUSB_HPE_Pos 4 /**< \brief (DSU_STATUSB) Hot-Plugging Enable */ +#define DSU_STATUSB_HPE (0x1u << DSU_STATUSB_HPE_Pos) +#define DSU_STATUSB_MASK 0x1Fu /**< \brief (DSU_STATUSB) MASK Register */ + +/* -------- DSU_ADDR : (DSU Offset: 0x0004) (R/W 32) Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :2; /*!< bit: 0.. 1 Reserved */ + uint32_t ADDR:30; /*!< bit: 2..31 Address */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_ADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_ADDR_OFFSET 0x0004 /**< \brief (DSU_ADDR offset) Address */ +#define DSU_ADDR_RESETVALUE 0x00000000 /**< \brief (DSU_ADDR reset_value) Address */ + +#define DSU_ADDR_ADDR_Pos 2 /**< \brief (DSU_ADDR) Address */ +#define DSU_ADDR_ADDR_Msk (0x3FFFFFFFu << DSU_ADDR_ADDR_Pos) +#define DSU_ADDR_ADDR(value) ((DSU_ADDR_ADDR_Msk & ((value) << DSU_ADDR_ADDR_Pos))) +#define DSU_ADDR_MASK 0xFFFFFFFCu /**< \brief (DSU_ADDR) MASK Register */ + +/* -------- DSU_LENGTH : (DSU Offset: 0x0008) (R/W 32) Length -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :2; /*!< bit: 0.. 1 Reserved */ + uint32_t LENGTH:30; /*!< bit: 2..31 Length */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_LENGTH_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_LENGTH_OFFSET 0x0008 /**< \brief (DSU_LENGTH offset) Length */ +#define DSU_LENGTH_RESETVALUE 0x00000000 /**< \brief (DSU_LENGTH reset_value) Length */ + +#define DSU_LENGTH_LENGTH_Pos 2 /**< \brief (DSU_LENGTH) Length */ +#define DSU_LENGTH_LENGTH_Msk (0x3FFFFFFFu << DSU_LENGTH_LENGTH_Pos) +#define DSU_LENGTH_LENGTH(value) ((DSU_LENGTH_LENGTH_Msk & ((value) << DSU_LENGTH_LENGTH_Pos))) +#define DSU_LENGTH_MASK 0xFFFFFFFCu /**< \brief (DSU_LENGTH) MASK Register */ + +/* -------- DSU_DATA : (DSU Offset: 0x000C) (R/W 32) Data -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DATA:32; /*!< bit: 0..31 Data */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_DATA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_DATA_OFFSET 0x000C /**< \brief (DSU_DATA offset) Data */ +#define DSU_DATA_RESETVALUE 0x00000000 /**< \brief (DSU_DATA reset_value) Data */ + +#define DSU_DATA_DATA_Pos 0 /**< \brief (DSU_DATA) Data */ +#define DSU_DATA_DATA_Msk (0xFFFFFFFFu << DSU_DATA_DATA_Pos) +#define DSU_DATA_DATA(value) ((DSU_DATA_DATA_Msk & ((value) << DSU_DATA_DATA_Pos))) +#define DSU_DATA_MASK 0xFFFFFFFFu /**< \brief (DSU_DATA) MASK Register */ + +/* -------- DSU_DCC : (DSU Offset: 0x0010) (R/W 32) Debug Communication Channel n -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DATA:32; /*!< bit: 0..31 Data */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_DCC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_DCC_OFFSET 0x0010 /**< \brief (DSU_DCC offset) Debug Communication Channel n */ +#define DSU_DCC_RESETVALUE 0x00000000 /**< \brief (DSU_DCC reset_value) Debug Communication Channel n */ + +#define DSU_DCC_DATA_Pos 0 /**< \brief (DSU_DCC) Data */ +#define DSU_DCC_DATA_Msk (0xFFFFFFFFu << DSU_DCC_DATA_Pos) +#define DSU_DCC_DATA(value) ((DSU_DCC_DATA_Msk & ((value) << DSU_DCC_DATA_Pos))) +#define DSU_DCC_MASK 0xFFFFFFFFu /**< \brief (DSU_DCC) MASK Register */ + +/* -------- DSU_DID : (DSU Offset: 0x0018) (R/ 32) Device Identification -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DEVSEL:8; /*!< bit: 0.. 7 Device Select */ + uint32_t REVISION:4; /*!< bit: 8..11 Revision */ + uint32_t DIE:4; /*!< bit: 12..15 Die Identification */ + uint32_t SERIES:6; /*!< bit: 16..21 Product Series */ + uint32_t :1; /*!< bit: 22 Reserved */ + uint32_t FAMILY:5; /*!< bit: 23..27 Product Family */ + uint32_t PROCESSOR:4; /*!< bit: 28..31 Processor */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_DID_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_DID_OFFSET 0x0018 /**< \brief (DSU_DID offset) Device Identification */ + +#define DSU_DID_DEVSEL_Pos 0 /**< \brief (DSU_DID) Device Select */ +#define DSU_DID_DEVSEL_Msk (0xFFu << DSU_DID_DEVSEL_Pos) +#define DSU_DID_DEVSEL(value) ((DSU_DID_DEVSEL_Msk & ((value) << DSU_DID_DEVSEL_Pos))) +#define DSU_DID_REVISION_Pos 8 /**< \brief (DSU_DID) Revision */ +#define DSU_DID_REVISION_Msk (0xFu << DSU_DID_REVISION_Pos) +#define DSU_DID_REVISION(value) ((DSU_DID_REVISION_Msk & ((value) << DSU_DID_REVISION_Pos))) +#define DSU_DID_DIE_Pos 12 /**< \brief (DSU_DID) Die Identification */ +#define DSU_DID_DIE_Msk (0xFu << DSU_DID_DIE_Pos) +#define DSU_DID_DIE(value) ((DSU_DID_DIE_Msk & ((value) << DSU_DID_DIE_Pos))) +#define DSU_DID_SERIES_Pos 16 /**< \brief (DSU_DID) Product Series */ +#define DSU_DID_SERIES_Msk (0x3Fu << DSU_DID_SERIES_Pos) +#define DSU_DID_SERIES(value) ((DSU_DID_SERIES_Msk & ((value) << DSU_DID_SERIES_Pos))) +#define DSU_DID_FAMILY_Pos 23 /**< \brief (DSU_DID) Product Family */ +#define DSU_DID_FAMILY_Msk (0x1Fu << DSU_DID_FAMILY_Pos) +#define DSU_DID_FAMILY(value) ((DSU_DID_FAMILY_Msk & ((value) << DSU_DID_FAMILY_Pos))) +#define DSU_DID_PROCESSOR_Pos 28 /**< \brief (DSU_DID) Processor */ +#define DSU_DID_PROCESSOR_Msk (0xFu << DSU_DID_PROCESSOR_Pos) +#define DSU_DID_PROCESSOR(value) ((DSU_DID_PROCESSOR_Msk & ((value) << DSU_DID_PROCESSOR_Pos))) +#define DSU_DID_MASK 0xFFBFFFFFu /**< \brief (DSU_DID) MASK Register */ + +/* -------- DSU_ENTRY : (DSU Offset: 0x1000) (R/ 32) Coresight ROM Table Entry n -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t EPRES:1; /*!< bit: 0 Entry Present */ + uint32_t FMT:1; /*!< bit: 1 Format */ + uint32_t :10; /*!< bit: 2..11 Reserved */ + uint32_t ADDOFF:20; /*!< bit: 12..31 Address Offset */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_ENTRY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_ENTRY_OFFSET 0x1000 /**< \brief (DSU_ENTRY offset) Coresight ROM Table Entry n */ +#define DSU_ENTRY_RESETVALUE 0x00000002 /**< \brief (DSU_ENTRY reset_value) Coresight ROM Table Entry n */ + +#define DSU_ENTRY_EPRES_Pos 0 /**< \brief (DSU_ENTRY) Entry Present */ +#define DSU_ENTRY_EPRES (0x1u << DSU_ENTRY_EPRES_Pos) +#define DSU_ENTRY_FMT_Pos 1 /**< \brief (DSU_ENTRY) Format */ +#define DSU_ENTRY_FMT (0x1u << DSU_ENTRY_FMT_Pos) +#define DSU_ENTRY_ADDOFF_Pos 12 /**< \brief (DSU_ENTRY) Address Offset */ +#define DSU_ENTRY_ADDOFF_Msk (0xFFFFFu << DSU_ENTRY_ADDOFF_Pos) +#define DSU_ENTRY_ADDOFF(value) ((DSU_ENTRY_ADDOFF_Msk & ((value) << DSU_ENTRY_ADDOFF_Pos))) +#define DSU_ENTRY_MASK 0xFFFFF003u /**< \brief (DSU_ENTRY) MASK Register */ + +/* -------- DSU_END : (DSU Offset: 0x1008) (R/ 32) Coresight ROM Table End -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t END:32; /*!< bit: 0..31 End Marker */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_END_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_END_OFFSET 0x1008 /**< \brief (DSU_END offset) Coresight ROM Table End */ +#define DSU_END_RESETVALUE 0x00000000 /**< \brief (DSU_END reset_value) Coresight ROM Table End */ + +#define DSU_END_END_Pos 0 /**< \brief (DSU_END) End Marker */ +#define DSU_END_END_Msk (0xFFFFFFFFu << DSU_END_END_Pos) +#define DSU_END_END(value) ((DSU_END_END_Msk & ((value) << DSU_END_END_Pos))) +#define DSU_END_MASK 0xFFFFFFFFu /**< \brief (DSU_END) MASK Register */ + +/* -------- DSU_MEMTYPE : (DSU Offset: 0x1FCC) (R/ 32) Coresight ROM Table Memory Type -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SMEMP:1; /*!< bit: 0 System Memory Present */ + uint32_t :31; /*!< bit: 1..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_MEMTYPE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_MEMTYPE_OFFSET 0x1FCC /**< \brief (DSU_MEMTYPE offset) Coresight ROM Table Memory Type */ +#define DSU_MEMTYPE_RESETVALUE 0x00000000 /**< \brief (DSU_MEMTYPE reset_value) Coresight ROM Table Memory Type */ + +#define DSU_MEMTYPE_SMEMP_Pos 0 /**< \brief (DSU_MEMTYPE) System Memory Present */ +#define DSU_MEMTYPE_SMEMP (0x1u << DSU_MEMTYPE_SMEMP_Pos) +#define DSU_MEMTYPE_MASK 0x00000001u /**< \brief (DSU_MEMTYPE) MASK Register */ + +/* -------- DSU_PID4 : (DSU Offset: 0x1FD0) (R/ 32) Peripheral Identification 4 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t JEPCC:4; /*!< bit: 0.. 3 JEP-106 Continuation Code */ + uint32_t FKBC:4; /*!< bit: 4.. 7 4KB Count */ + uint32_t :24; /*!< bit: 8..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_PID4_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_PID4_OFFSET 0x1FD0 /**< \brief (DSU_PID4 offset) Peripheral Identification 4 */ +#define DSU_PID4_RESETVALUE 0x00000000 /**< \brief (DSU_PID4 reset_value) Peripheral Identification 4 */ + +#define DSU_PID4_JEPCC_Pos 0 /**< \brief (DSU_PID4) JEP-106 Continuation Code */ +#define DSU_PID4_JEPCC_Msk (0xFu << DSU_PID4_JEPCC_Pos) +#define DSU_PID4_JEPCC(value) ((DSU_PID4_JEPCC_Msk & ((value) << DSU_PID4_JEPCC_Pos))) +#define DSU_PID4_FKBC_Pos 4 /**< \brief (DSU_PID4) 4KB Count */ +#define DSU_PID4_FKBC_Msk (0xFu << DSU_PID4_FKBC_Pos) +#define DSU_PID4_FKBC(value) ((DSU_PID4_FKBC_Msk & ((value) << DSU_PID4_FKBC_Pos))) +#define DSU_PID4_MASK 0x000000FFu /**< \brief (DSU_PID4) MASK Register */ + +/* -------- DSU_PID0 : (DSU Offset: 0x1FE0) (R/ 32) Peripheral Identification 0 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PARTNBL:8; /*!< bit: 0.. 7 Part Number Low */ + uint32_t :24; /*!< bit: 8..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_PID0_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_PID0_OFFSET 0x1FE0 /**< \brief (DSU_PID0 offset) Peripheral Identification 0 */ +#define DSU_PID0_RESETVALUE 0x000000D0 /**< \brief (DSU_PID0 reset_value) Peripheral Identification 0 */ + +#define DSU_PID0_PARTNBL_Pos 0 /**< \brief (DSU_PID0) Part Number Low */ +#define DSU_PID0_PARTNBL_Msk (0xFFu << DSU_PID0_PARTNBL_Pos) +#define DSU_PID0_PARTNBL(value) ((DSU_PID0_PARTNBL_Msk & ((value) << DSU_PID0_PARTNBL_Pos))) +#define DSU_PID0_MASK 0x000000FFu /**< \brief (DSU_PID0) MASK Register */ + +/* -------- DSU_PID1 : (DSU Offset: 0x1FE4) (R/ 32) Peripheral Identification 1 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PARTNBH:4; /*!< bit: 0.. 3 Part Number High */ + uint32_t JEPIDCL:4; /*!< bit: 4.. 7 Low part of the JEP-106 Identity Code */ + uint32_t :24; /*!< bit: 8..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_PID1_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_PID1_OFFSET 0x1FE4 /**< \brief (DSU_PID1 offset) Peripheral Identification 1 */ +#define DSU_PID1_RESETVALUE 0x000000FC /**< \brief (DSU_PID1 reset_value) Peripheral Identification 1 */ + +#define DSU_PID1_PARTNBH_Pos 0 /**< \brief (DSU_PID1) Part Number High */ +#define DSU_PID1_PARTNBH_Msk (0xFu << DSU_PID1_PARTNBH_Pos) +#define DSU_PID1_PARTNBH(value) ((DSU_PID1_PARTNBH_Msk & ((value) << DSU_PID1_PARTNBH_Pos))) +#define DSU_PID1_JEPIDCL_Pos 4 /**< \brief (DSU_PID1) Low part of the JEP-106 Identity Code */ +#define DSU_PID1_JEPIDCL_Msk (0xFu << DSU_PID1_JEPIDCL_Pos) +#define DSU_PID1_JEPIDCL(value) ((DSU_PID1_JEPIDCL_Msk & ((value) << DSU_PID1_JEPIDCL_Pos))) +#define DSU_PID1_MASK 0x000000FFu /**< \brief (DSU_PID1) MASK Register */ + +/* -------- DSU_PID2 : (DSU Offset: 0x1FE8) (R/ 32) Peripheral Identification 2 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t JEPIDCH:3; /*!< bit: 0.. 2 JEP-106 Identity Code High */ + uint32_t JEPU:1; /*!< bit: 3 JEP-106 Identity Code is used */ + uint32_t REVISION:4; /*!< bit: 4.. 7 Revision Number */ + uint32_t :24; /*!< bit: 8..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_PID2_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_PID2_OFFSET 0x1FE8 /**< \brief (DSU_PID2 offset) Peripheral Identification 2 */ +#define DSU_PID2_RESETVALUE 0x00000009 /**< \brief (DSU_PID2 reset_value) Peripheral Identification 2 */ + +#define DSU_PID2_JEPIDCH_Pos 0 /**< \brief (DSU_PID2) JEP-106 Identity Code High */ +#define DSU_PID2_JEPIDCH_Msk (0x7u << DSU_PID2_JEPIDCH_Pos) +#define DSU_PID2_JEPIDCH(value) ((DSU_PID2_JEPIDCH_Msk & ((value) << DSU_PID2_JEPIDCH_Pos))) +#define DSU_PID2_JEPU_Pos 3 /**< \brief (DSU_PID2) JEP-106 Identity Code is used */ +#define DSU_PID2_JEPU (0x1u << DSU_PID2_JEPU_Pos) +#define DSU_PID2_REVISION_Pos 4 /**< \brief (DSU_PID2) Revision Number */ +#define DSU_PID2_REVISION_Msk (0xFu << DSU_PID2_REVISION_Pos) +#define DSU_PID2_REVISION(value) ((DSU_PID2_REVISION_Msk & ((value) << DSU_PID2_REVISION_Pos))) +#define DSU_PID2_MASK 0x000000FFu /**< \brief (DSU_PID2) MASK Register */ + +/* -------- DSU_PID3 : (DSU Offset: 0x1FEC) (R/ 32) Peripheral Identification 3 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CUSMOD:4; /*!< bit: 0.. 3 ARM CUSMOD */ + uint32_t REVAND:4; /*!< bit: 4.. 7 Revision Number */ + uint32_t :24; /*!< bit: 8..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_PID3_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_PID3_OFFSET 0x1FEC /**< \brief (DSU_PID3 offset) Peripheral Identification 3 */ +#define DSU_PID3_RESETVALUE 0x00000000 /**< \brief (DSU_PID3 reset_value) Peripheral Identification 3 */ + +#define DSU_PID3_CUSMOD_Pos 0 /**< \brief (DSU_PID3) ARM CUSMOD */ +#define DSU_PID3_CUSMOD_Msk (0xFu << DSU_PID3_CUSMOD_Pos) +#define DSU_PID3_CUSMOD(value) ((DSU_PID3_CUSMOD_Msk & ((value) << DSU_PID3_CUSMOD_Pos))) +#define DSU_PID3_REVAND_Pos 4 /**< \brief (DSU_PID3) Revision Number */ +#define DSU_PID3_REVAND_Msk (0xFu << DSU_PID3_REVAND_Pos) +#define DSU_PID3_REVAND(value) ((DSU_PID3_REVAND_Msk & ((value) << DSU_PID3_REVAND_Pos))) +#define DSU_PID3_MASK 0x000000FFu /**< \brief (DSU_PID3) MASK Register */ + +/* -------- DSU_CID0 : (DSU Offset: 0x1FF0) (R/ 32) Component Identification 0 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PREAMBLEB0:8; /*!< bit: 0.. 7 Preamble Byte 0 */ + uint32_t :24; /*!< bit: 8..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_CID0_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_CID0_OFFSET 0x1FF0 /**< \brief (DSU_CID0 offset) Component Identification 0 */ +#define DSU_CID0_RESETVALUE 0x0000000D /**< \brief (DSU_CID0 reset_value) Component Identification 0 */ + +#define DSU_CID0_PREAMBLEB0_Pos 0 /**< \brief (DSU_CID0) Preamble Byte 0 */ +#define DSU_CID0_PREAMBLEB0_Msk (0xFFu << DSU_CID0_PREAMBLEB0_Pos) +#define DSU_CID0_PREAMBLEB0(value) ((DSU_CID0_PREAMBLEB0_Msk & ((value) << DSU_CID0_PREAMBLEB0_Pos))) +#define DSU_CID0_MASK 0x000000FFu /**< \brief (DSU_CID0) MASK Register */ + +/* -------- DSU_CID1 : (DSU Offset: 0x1FF4) (R/ 32) Component Identification 1 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PREAMBLE:4; /*!< bit: 0.. 3 Preamble */ + uint32_t CCLASS:4; /*!< bit: 4.. 7 Component Class */ + uint32_t :24; /*!< bit: 8..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_CID1_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_CID1_OFFSET 0x1FF4 /**< \brief (DSU_CID1 offset) Component Identification 1 */ +#define DSU_CID1_RESETVALUE 0x00000010 /**< \brief (DSU_CID1 reset_value) Component Identification 1 */ + +#define DSU_CID1_PREAMBLE_Pos 0 /**< \brief (DSU_CID1) Preamble */ +#define DSU_CID1_PREAMBLE_Msk (0xFu << DSU_CID1_PREAMBLE_Pos) +#define DSU_CID1_PREAMBLE(value) ((DSU_CID1_PREAMBLE_Msk & ((value) << DSU_CID1_PREAMBLE_Pos))) +#define DSU_CID1_CCLASS_Pos 4 /**< \brief (DSU_CID1) Component Class */ +#define DSU_CID1_CCLASS_Msk (0xFu << DSU_CID1_CCLASS_Pos) +#define DSU_CID1_CCLASS(value) ((DSU_CID1_CCLASS_Msk & ((value) << DSU_CID1_CCLASS_Pos))) +#define DSU_CID1_MASK 0x000000FFu /**< \brief (DSU_CID1) MASK Register */ + +/* -------- DSU_CID2 : (DSU Offset: 0x1FF8) (R/ 32) Component Identification 2 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PREAMBLEB2:8; /*!< bit: 0.. 7 Preamble Byte 2 */ + uint32_t :24; /*!< bit: 8..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_CID2_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_CID2_OFFSET 0x1FF8 /**< \brief (DSU_CID2 offset) Component Identification 2 */ +#define DSU_CID2_RESETVALUE 0x00000005 /**< \brief (DSU_CID2 reset_value) Component Identification 2 */ + +#define DSU_CID2_PREAMBLEB2_Pos 0 /**< \brief (DSU_CID2) Preamble Byte 2 */ +#define DSU_CID2_PREAMBLEB2_Msk (0xFFu << DSU_CID2_PREAMBLEB2_Pos) +#define DSU_CID2_PREAMBLEB2(value) ((DSU_CID2_PREAMBLEB2_Msk & ((value) << DSU_CID2_PREAMBLEB2_Pos))) +#define DSU_CID2_MASK 0x000000FFu /**< \brief (DSU_CID2) MASK Register */ + +/* -------- DSU_CID3 : (DSU Offset: 0x1FFC) (R/ 32) Component Identification 3 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PREAMBLEB3:8; /*!< bit: 0.. 7 Preamble Byte 3 */ + uint32_t :24; /*!< bit: 8..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_CID3_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_CID3_OFFSET 0x1FFC /**< \brief (DSU_CID3 offset) Component Identification 3 */ +#define DSU_CID3_RESETVALUE 0x000000B1 /**< \brief (DSU_CID3 reset_value) Component Identification 3 */ + +#define DSU_CID3_PREAMBLEB3_Pos 0 /**< \brief (DSU_CID3) Preamble Byte 3 */ +#define DSU_CID3_PREAMBLEB3_Msk (0xFFu << DSU_CID3_PREAMBLEB3_Pos) +#define DSU_CID3_PREAMBLEB3(value) ((DSU_CID3_PREAMBLEB3_Msk & ((value) << DSU_CID3_PREAMBLEB3_Pos))) +#define DSU_CID3_MASK 0x000000FFu /**< \brief (DSU_CID3) MASK Register */ + +/** \brief DSU hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __O DSU_CTRL_Type CTRL; /**< \brief Offset: 0x0000 ( /W 8) Control */ + __IO DSU_STATUSA_Type STATUSA; /**< \brief Offset: 0x0001 (R/W 8) Status A */ + __I DSU_STATUSB_Type STATUSB; /**< \brief Offset: 0x0002 (R/ 8) Status B */ + RoReg8 Reserved1[0x1]; + __IO DSU_ADDR_Type ADDR; /**< \brief Offset: 0x0004 (R/W 32) Address */ + __IO DSU_LENGTH_Type LENGTH; /**< \brief Offset: 0x0008 (R/W 32) Length */ + __IO DSU_DATA_Type DATA; /**< \brief Offset: 0x000C (R/W 32) Data */ + __IO DSU_DCC_Type DCC[2]; /**< \brief Offset: 0x0010 (R/W 32) Debug Communication Channel n */ + __I DSU_DID_Type DID; /**< \brief Offset: 0x0018 (R/ 32) Device Identification */ + RoReg8 Reserved2[0xFE4]; + __I DSU_ENTRY_Type ENTRY[2]; /**< \brief Offset: 0x1000 (R/ 32) Coresight ROM Table Entry n */ + __I DSU_END_Type END; /**< \brief Offset: 0x1008 (R/ 32) Coresight ROM Table End */ + RoReg8 Reserved3[0xFC0]; + __I DSU_MEMTYPE_Type MEMTYPE; /**< \brief Offset: 0x1FCC (R/ 32) Coresight ROM Table Memory Type */ + __I DSU_PID4_Type PID4; /**< \brief Offset: 0x1FD0 (R/ 32) Peripheral Identification 4 */ + RoReg8 Reserved4[0xC]; + __I DSU_PID0_Type PID0; /**< \brief Offset: 0x1FE0 (R/ 32) Peripheral Identification 0 */ + __I DSU_PID1_Type PID1; /**< \brief Offset: 0x1FE4 (R/ 32) Peripheral Identification 1 */ + __I DSU_PID2_Type PID2; /**< \brief Offset: 0x1FE8 (R/ 32) Peripheral Identification 2 */ + __I DSU_PID3_Type PID3; /**< \brief Offset: 0x1FEC (R/ 32) Peripheral Identification 3 */ + __I DSU_CID0_Type CID0; /**< \brief Offset: 0x1FF0 (R/ 32) Component Identification 0 */ + __I DSU_CID1_Type CID1; /**< \brief Offset: 0x1FF4 (R/ 32) Component Identification 1 */ + __I DSU_CID2_Type CID2; /**< \brief Offset: 0x1FF8 (R/ 32) Component Identification 2 */ + __I DSU_CID3_Type CID3; /**< \brief Offset: 0x1FFC (R/ 32) Component Identification 3 */ +} Dsu; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_DSU_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/eic.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/eic.h new file mode 100644 index 0000000..91b10b9 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/eic.h @@ -0,0 +1,681 @@ +/** + * \file + * + * \brief Component description for EIC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_EIC_COMPONENT_ +#define _SAMD21_EIC_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR EIC */ +/* ========================================================================== */ +/** \addtogroup SAMD21_EIC External Interrupt Controller */ +/*@{*/ + +#define EIC_U2217 +#define REV_EIC 0x101 + +/* -------- EIC_CTRL : (EIC Offset: 0x00) (R/W 8) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset */ + uint8_t ENABLE:1; /*!< bit: 1 Enable */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} EIC_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_CTRL_OFFSET 0x00 /**< \brief (EIC_CTRL offset) Control */ +#define EIC_CTRL_RESETVALUE 0x00 /**< \brief (EIC_CTRL reset_value) Control */ + +#define EIC_CTRL_SWRST_Pos 0 /**< \brief (EIC_CTRL) Software Reset */ +#define EIC_CTRL_SWRST (0x1u << EIC_CTRL_SWRST_Pos) +#define EIC_CTRL_ENABLE_Pos 1 /**< \brief (EIC_CTRL) Enable */ +#define EIC_CTRL_ENABLE (0x1u << EIC_CTRL_ENABLE_Pos) +#define EIC_CTRL_MASK 0x03u /**< \brief (EIC_CTRL) MASK Register */ + +/* -------- EIC_STATUS : (EIC Offset: 0x01) (R/ 8) Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :7; /*!< bit: 0.. 6 Reserved */ + uint8_t SYNCBUSY:1; /*!< bit: 7 Synchronization Busy */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} EIC_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_STATUS_OFFSET 0x01 /**< \brief (EIC_STATUS offset) Status */ +#define EIC_STATUS_RESETVALUE 0x00 /**< \brief (EIC_STATUS reset_value) Status */ + +#define EIC_STATUS_SYNCBUSY_Pos 7 /**< \brief (EIC_STATUS) Synchronization Busy */ +#define EIC_STATUS_SYNCBUSY (0x1u << EIC_STATUS_SYNCBUSY_Pos) +#define EIC_STATUS_MASK 0x80u /**< \brief (EIC_STATUS) MASK Register */ + +/* -------- EIC_NMICTRL : (EIC Offset: 0x02) (R/W 8) Non-Maskable Interrupt Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t NMISENSE:3; /*!< bit: 0.. 2 Non-Maskable Interrupt Sense */ + uint8_t NMIFILTEN:1; /*!< bit: 3 Non-Maskable Interrupt Filter Enable */ + uint8_t :4; /*!< bit: 4.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} EIC_NMICTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_NMICTRL_OFFSET 0x02 /**< \brief (EIC_NMICTRL offset) Non-Maskable Interrupt Control */ +#define EIC_NMICTRL_RESETVALUE 0x00 /**< \brief (EIC_NMICTRL reset_value) Non-Maskable Interrupt Control */ + +#define EIC_NMICTRL_NMISENSE_Pos 0 /**< \brief (EIC_NMICTRL) Non-Maskable Interrupt Sense */ +#define EIC_NMICTRL_NMISENSE_Msk (0x7u << EIC_NMICTRL_NMISENSE_Pos) +#define EIC_NMICTRL_NMISENSE(value) ((EIC_NMICTRL_NMISENSE_Msk & ((value) << EIC_NMICTRL_NMISENSE_Pos))) +#define EIC_NMICTRL_NMISENSE_NONE_Val 0x0u /**< \brief (EIC_NMICTRL) No detection */ +#define EIC_NMICTRL_NMISENSE_RISE_Val 0x1u /**< \brief (EIC_NMICTRL) Rising-edge detection */ +#define EIC_NMICTRL_NMISENSE_FALL_Val 0x2u /**< \brief (EIC_NMICTRL) Falling-edge detection */ +#define EIC_NMICTRL_NMISENSE_BOTH_Val 0x3u /**< \brief (EIC_NMICTRL) Both-edges detection */ +#define EIC_NMICTRL_NMISENSE_HIGH_Val 0x4u /**< \brief (EIC_NMICTRL) High-level detection */ +#define EIC_NMICTRL_NMISENSE_LOW_Val 0x5u /**< \brief (EIC_NMICTRL) Low-level detection */ +#define EIC_NMICTRL_NMISENSE_NONE (EIC_NMICTRL_NMISENSE_NONE_Val << EIC_NMICTRL_NMISENSE_Pos) +#define EIC_NMICTRL_NMISENSE_RISE (EIC_NMICTRL_NMISENSE_RISE_Val << EIC_NMICTRL_NMISENSE_Pos) +#define EIC_NMICTRL_NMISENSE_FALL (EIC_NMICTRL_NMISENSE_FALL_Val << EIC_NMICTRL_NMISENSE_Pos) +#define EIC_NMICTRL_NMISENSE_BOTH (EIC_NMICTRL_NMISENSE_BOTH_Val << EIC_NMICTRL_NMISENSE_Pos) +#define EIC_NMICTRL_NMISENSE_HIGH (EIC_NMICTRL_NMISENSE_HIGH_Val << EIC_NMICTRL_NMISENSE_Pos) +#define EIC_NMICTRL_NMISENSE_LOW (EIC_NMICTRL_NMISENSE_LOW_Val << EIC_NMICTRL_NMISENSE_Pos) +#define EIC_NMICTRL_NMIFILTEN_Pos 3 /**< \brief (EIC_NMICTRL) Non-Maskable Interrupt Filter Enable */ +#define EIC_NMICTRL_NMIFILTEN (0x1u << EIC_NMICTRL_NMIFILTEN_Pos) +#define EIC_NMICTRL_MASK 0x0Fu /**< \brief (EIC_NMICTRL) MASK Register */ + +/* -------- EIC_NMIFLAG : (EIC Offset: 0x03) (R/W 8) Non-Maskable Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t NMI:1; /*!< bit: 0 Non-Maskable Interrupt */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} EIC_NMIFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_NMIFLAG_OFFSET 0x03 /**< \brief (EIC_NMIFLAG offset) Non-Maskable Interrupt Flag Status and Clear */ +#define EIC_NMIFLAG_RESETVALUE 0x00 /**< \brief (EIC_NMIFLAG reset_value) Non-Maskable Interrupt Flag Status and Clear */ + +#define EIC_NMIFLAG_NMI_Pos 0 /**< \brief (EIC_NMIFLAG) Non-Maskable Interrupt */ +#define EIC_NMIFLAG_NMI (0x1u << EIC_NMIFLAG_NMI_Pos) +#define EIC_NMIFLAG_MASK 0x01u /**< \brief (EIC_NMIFLAG) MASK Register */ + +/* -------- EIC_EVCTRL : (EIC Offset: 0x04) (R/W 32) Event Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t EXTINTEO0:1; /*!< bit: 0 External Interrupt 0 Event Output Enable */ + uint32_t EXTINTEO1:1; /*!< bit: 1 External Interrupt 1 Event Output Enable */ + uint32_t EXTINTEO2:1; /*!< bit: 2 External Interrupt 2 Event Output Enable */ + uint32_t EXTINTEO3:1; /*!< bit: 3 External Interrupt 3 Event Output Enable */ + uint32_t EXTINTEO4:1; /*!< bit: 4 External Interrupt 4 Event Output Enable */ + uint32_t EXTINTEO5:1; /*!< bit: 5 External Interrupt 5 Event Output Enable */ + uint32_t EXTINTEO6:1; /*!< bit: 6 External Interrupt 6 Event Output Enable */ + uint32_t EXTINTEO7:1; /*!< bit: 7 External Interrupt 7 Event Output Enable */ + uint32_t EXTINTEO8:1; /*!< bit: 8 External Interrupt 8 Event Output Enable */ + uint32_t EXTINTEO9:1; /*!< bit: 9 External Interrupt 9 Event Output Enable */ + uint32_t EXTINTEO10:1; /*!< bit: 10 External Interrupt 10 Event Output Enable */ + uint32_t EXTINTEO11:1; /*!< bit: 11 External Interrupt 11 Event Output Enable */ + uint32_t EXTINTEO12:1; /*!< bit: 12 External Interrupt 12 Event Output Enable */ + uint32_t EXTINTEO13:1; /*!< bit: 13 External Interrupt 13 Event Output Enable */ + uint32_t EXTINTEO14:1; /*!< bit: 14 External Interrupt 14 Event Output Enable */ + uint32_t EXTINTEO15:1; /*!< bit: 15 External Interrupt 15 Event Output Enable */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t EXTINTEO:16; /*!< bit: 0..15 External Interrupt x Event Output Enable */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} EIC_EVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_EVCTRL_OFFSET 0x04 /**< \brief (EIC_EVCTRL offset) Event Control */ +#define EIC_EVCTRL_RESETVALUE 0x00000000 /**< \brief (EIC_EVCTRL reset_value) Event Control */ + +#define EIC_EVCTRL_EXTINTEO0_Pos 0 /**< \brief (EIC_EVCTRL) External Interrupt 0 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO0 (1 << EIC_EVCTRL_EXTINTEO0_Pos) +#define EIC_EVCTRL_EXTINTEO1_Pos 1 /**< \brief (EIC_EVCTRL) External Interrupt 1 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO1 (1 << EIC_EVCTRL_EXTINTEO1_Pos) +#define EIC_EVCTRL_EXTINTEO2_Pos 2 /**< \brief (EIC_EVCTRL) External Interrupt 2 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO2 (1 << EIC_EVCTRL_EXTINTEO2_Pos) +#define EIC_EVCTRL_EXTINTEO3_Pos 3 /**< \brief (EIC_EVCTRL) External Interrupt 3 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO3 (1 << EIC_EVCTRL_EXTINTEO3_Pos) +#define EIC_EVCTRL_EXTINTEO4_Pos 4 /**< \brief (EIC_EVCTRL) External Interrupt 4 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO4 (1 << EIC_EVCTRL_EXTINTEO4_Pos) +#define EIC_EVCTRL_EXTINTEO5_Pos 5 /**< \brief (EIC_EVCTRL) External Interrupt 5 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO5 (1 << EIC_EVCTRL_EXTINTEO5_Pos) +#define EIC_EVCTRL_EXTINTEO6_Pos 6 /**< \brief (EIC_EVCTRL) External Interrupt 6 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO6 (1 << EIC_EVCTRL_EXTINTEO6_Pos) +#define EIC_EVCTRL_EXTINTEO7_Pos 7 /**< \brief (EIC_EVCTRL) External Interrupt 7 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO7 (1 << EIC_EVCTRL_EXTINTEO7_Pos) +#define EIC_EVCTRL_EXTINTEO8_Pos 8 /**< \brief (EIC_EVCTRL) External Interrupt 8 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO8 (1 << EIC_EVCTRL_EXTINTEO8_Pos) +#define EIC_EVCTRL_EXTINTEO9_Pos 9 /**< \brief (EIC_EVCTRL) External Interrupt 9 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO9 (1 << EIC_EVCTRL_EXTINTEO9_Pos) +#define EIC_EVCTRL_EXTINTEO10_Pos 10 /**< \brief (EIC_EVCTRL) External Interrupt 10 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO10 (1 << EIC_EVCTRL_EXTINTEO10_Pos) +#define EIC_EVCTRL_EXTINTEO11_Pos 11 /**< \brief (EIC_EVCTRL) External Interrupt 11 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO11 (1 << EIC_EVCTRL_EXTINTEO11_Pos) +#define EIC_EVCTRL_EXTINTEO12_Pos 12 /**< \brief (EIC_EVCTRL) External Interrupt 12 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO12 (1 << EIC_EVCTRL_EXTINTEO12_Pos) +#define EIC_EVCTRL_EXTINTEO13_Pos 13 /**< \brief (EIC_EVCTRL) External Interrupt 13 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO13 (1 << EIC_EVCTRL_EXTINTEO13_Pos) +#define EIC_EVCTRL_EXTINTEO14_Pos 14 /**< \brief (EIC_EVCTRL) External Interrupt 14 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO14 (1 << EIC_EVCTRL_EXTINTEO14_Pos) +#define EIC_EVCTRL_EXTINTEO15_Pos 15 /**< \brief (EIC_EVCTRL) External Interrupt 15 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO15 (1 << EIC_EVCTRL_EXTINTEO15_Pos) +#define EIC_EVCTRL_EXTINTEO_Pos 0 /**< \brief (EIC_EVCTRL) External Interrupt x Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO_Msk (0xFFFFu << EIC_EVCTRL_EXTINTEO_Pos) +#define EIC_EVCTRL_EXTINTEO(value) ((EIC_EVCTRL_EXTINTEO_Msk & ((value) << EIC_EVCTRL_EXTINTEO_Pos))) +#define EIC_EVCTRL_MASK 0x0000FFFFu /**< \brief (EIC_EVCTRL) MASK Register */ + +/* -------- EIC_INTENCLR : (EIC Offset: 0x08) (R/W 32) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t EXTINT0:1; /*!< bit: 0 External Interrupt 0 Enable */ + uint32_t EXTINT1:1; /*!< bit: 1 External Interrupt 1 Enable */ + uint32_t EXTINT2:1; /*!< bit: 2 External Interrupt 2 Enable */ + uint32_t EXTINT3:1; /*!< bit: 3 External Interrupt 3 Enable */ + uint32_t EXTINT4:1; /*!< bit: 4 External Interrupt 4 Enable */ + uint32_t EXTINT5:1; /*!< bit: 5 External Interrupt 5 Enable */ + uint32_t EXTINT6:1; /*!< bit: 6 External Interrupt 6 Enable */ + uint32_t EXTINT7:1; /*!< bit: 7 External Interrupt 7 Enable */ + uint32_t EXTINT8:1; /*!< bit: 8 External Interrupt 8 Enable */ + uint32_t EXTINT9:1; /*!< bit: 9 External Interrupt 9 Enable */ + uint32_t EXTINT10:1; /*!< bit: 10 External Interrupt 10 Enable */ + uint32_t EXTINT11:1; /*!< bit: 11 External Interrupt 11 Enable */ + uint32_t EXTINT12:1; /*!< bit: 12 External Interrupt 12 Enable */ + uint32_t EXTINT13:1; /*!< bit: 13 External Interrupt 13 Enable */ + uint32_t EXTINT14:1; /*!< bit: 14 External Interrupt 14 Enable */ + uint32_t EXTINT15:1; /*!< bit: 15 External Interrupt 15 Enable */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t EXTINT:16; /*!< bit: 0..15 External Interrupt x Enable */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} EIC_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_INTENCLR_OFFSET 0x08 /**< \brief (EIC_INTENCLR offset) Interrupt Enable Clear */ +#define EIC_INTENCLR_RESETVALUE 0x00000000 /**< \brief (EIC_INTENCLR reset_value) Interrupt Enable Clear */ + +#define EIC_INTENCLR_EXTINT0_Pos 0 /**< \brief (EIC_INTENCLR) External Interrupt 0 Enable */ +#define EIC_INTENCLR_EXTINT0 (1 << EIC_INTENCLR_EXTINT0_Pos) +#define EIC_INTENCLR_EXTINT1_Pos 1 /**< \brief (EIC_INTENCLR) External Interrupt 1 Enable */ +#define EIC_INTENCLR_EXTINT1 (1 << EIC_INTENCLR_EXTINT1_Pos) +#define EIC_INTENCLR_EXTINT2_Pos 2 /**< \brief (EIC_INTENCLR) External Interrupt 2 Enable */ +#define EIC_INTENCLR_EXTINT2 (1 << EIC_INTENCLR_EXTINT2_Pos) +#define EIC_INTENCLR_EXTINT3_Pos 3 /**< \brief (EIC_INTENCLR) External Interrupt 3 Enable */ +#define EIC_INTENCLR_EXTINT3 (1 << EIC_INTENCLR_EXTINT3_Pos) +#define EIC_INTENCLR_EXTINT4_Pos 4 /**< \brief (EIC_INTENCLR) External Interrupt 4 Enable */ +#define EIC_INTENCLR_EXTINT4 (1 << EIC_INTENCLR_EXTINT4_Pos) +#define EIC_INTENCLR_EXTINT5_Pos 5 /**< \brief (EIC_INTENCLR) External Interrupt 5 Enable */ +#define EIC_INTENCLR_EXTINT5 (1 << EIC_INTENCLR_EXTINT5_Pos) +#define EIC_INTENCLR_EXTINT6_Pos 6 /**< \brief (EIC_INTENCLR) External Interrupt 6 Enable */ +#define EIC_INTENCLR_EXTINT6 (1 << EIC_INTENCLR_EXTINT6_Pos) +#define EIC_INTENCLR_EXTINT7_Pos 7 /**< \brief (EIC_INTENCLR) External Interrupt 7 Enable */ +#define EIC_INTENCLR_EXTINT7 (1 << EIC_INTENCLR_EXTINT7_Pos) +#define EIC_INTENCLR_EXTINT8_Pos 8 /**< \brief (EIC_INTENCLR) External Interrupt 8 Enable */ +#define EIC_INTENCLR_EXTINT8 (1 << EIC_INTENCLR_EXTINT8_Pos) +#define EIC_INTENCLR_EXTINT9_Pos 9 /**< \brief (EIC_INTENCLR) External Interrupt 9 Enable */ +#define EIC_INTENCLR_EXTINT9 (1 << EIC_INTENCLR_EXTINT9_Pos) +#define EIC_INTENCLR_EXTINT10_Pos 10 /**< \brief (EIC_INTENCLR) External Interrupt 10 Enable */ +#define EIC_INTENCLR_EXTINT10 (1 << EIC_INTENCLR_EXTINT10_Pos) +#define EIC_INTENCLR_EXTINT11_Pos 11 /**< \brief (EIC_INTENCLR) External Interrupt 11 Enable */ +#define EIC_INTENCLR_EXTINT11 (1 << EIC_INTENCLR_EXTINT11_Pos) +#define EIC_INTENCLR_EXTINT12_Pos 12 /**< \brief (EIC_INTENCLR) External Interrupt 12 Enable */ +#define EIC_INTENCLR_EXTINT12 (1 << EIC_INTENCLR_EXTINT12_Pos) +#define EIC_INTENCLR_EXTINT13_Pos 13 /**< \brief (EIC_INTENCLR) External Interrupt 13 Enable */ +#define EIC_INTENCLR_EXTINT13 (1 << EIC_INTENCLR_EXTINT13_Pos) +#define EIC_INTENCLR_EXTINT14_Pos 14 /**< \brief (EIC_INTENCLR) External Interrupt 14 Enable */ +#define EIC_INTENCLR_EXTINT14 (1 << EIC_INTENCLR_EXTINT14_Pos) +#define EIC_INTENCLR_EXTINT15_Pos 15 /**< \brief (EIC_INTENCLR) External Interrupt 15 Enable */ +#define EIC_INTENCLR_EXTINT15 (1 << EIC_INTENCLR_EXTINT15_Pos) +#define EIC_INTENCLR_EXTINT_Pos 0 /**< \brief (EIC_INTENCLR) External Interrupt x Enable */ +#define EIC_INTENCLR_EXTINT_Msk (0xFFFFu << EIC_INTENCLR_EXTINT_Pos) +#define EIC_INTENCLR_EXTINT(value) ((EIC_INTENCLR_EXTINT_Msk & ((value) << EIC_INTENCLR_EXTINT_Pos))) +#define EIC_INTENCLR_MASK 0x0000FFFFu /**< \brief (EIC_INTENCLR) MASK Register */ + +/* -------- EIC_INTENSET : (EIC Offset: 0x0C) (R/W 32) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t EXTINT0:1; /*!< bit: 0 External Interrupt 0 Enable */ + uint32_t EXTINT1:1; /*!< bit: 1 External Interrupt 1 Enable */ + uint32_t EXTINT2:1; /*!< bit: 2 External Interrupt 2 Enable */ + uint32_t EXTINT3:1; /*!< bit: 3 External Interrupt 3 Enable */ + uint32_t EXTINT4:1; /*!< bit: 4 External Interrupt 4 Enable */ + uint32_t EXTINT5:1; /*!< bit: 5 External Interrupt 5 Enable */ + uint32_t EXTINT6:1; /*!< bit: 6 External Interrupt 6 Enable */ + uint32_t EXTINT7:1; /*!< bit: 7 External Interrupt 7 Enable */ + uint32_t EXTINT8:1; /*!< bit: 8 External Interrupt 8 Enable */ + uint32_t EXTINT9:1; /*!< bit: 9 External Interrupt 9 Enable */ + uint32_t EXTINT10:1; /*!< bit: 10 External Interrupt 10 Enable */ + uint32_t EXTINT11:1; /*!< bit: 11 External Interrupt 11 Enable */ + uint32_t EXTINT12:1; /*!< bit: 12 External Interrupt 12 Enable */ + uint32_t EXTINT13:1; /*!< bit: 13 External Interrupt 13 Enable */ + uint32_t EXTINT14:1; /*!< bit: 14 External Interrupt 14 Enable */ + uint32_t EXTINT15:1; /*!< bit: 15 External Interrupt 15 Enable */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t EXTINT:16; /*!< bit: 0..15 External Interrupt x Enable */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} EIC_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_INTENSET_OFFSET 0x0C /**< \brief (EIC_INTENSET offset) Interrupt Enable Set */ +#define EIC_INTENSET_RESETVALUE 0x00000000 /**< \brief (EIC_INTENSET reset_value) Interrupt Enable Set */ + +#define EIC_INTENSET_EXTINT0_Pos 0 /**< \brief (EIC_INTENSET) External Interrupt 0 Enable */ +#define EIC_INTENSET_EXTINT0 (1 << EIC_INTENSET_EXTINT0_Pos) +#define EIC_INTENSET_EXTINT1_Pos 1 /**< \brief (EIC_INTENSET) External Interrupt 1 Enable */ +#define EIC_INTENSET_EXTINT1 (1 << EIC_INTENSET_EXTINT1_Pos) +#define EIC_INTENSET_EXTINT2_Pos 2 /**< \brief (EIC_INTENSET) External Interrupt 2 Enable */ +#define EIC_INTENSET_EXTINT2 (1 << EIC_INTENSET_EXTINT2_Pos) +#define EIC_INTENSET_EXTINT3_Pos 3 /**< \brief (EIC_INTENSET) External Interrupt 3 Enable */ +#define EIC_INTENSET_EXTINT3 (1 << EIC_INTENSET_EXTINT3_Pos) +#define EIC_INTENSET_EXTINT4_Pos 4 /**< \brief (EIC_INTENSET) External Interrupt 4 Enable */ +#define EIC_INTENSET_EXTINT4 (1 << EIC_INTENSET_EXTINT4_Pos) +#define EIC_INTENSET_EXTINT5_Pos 5 /**< \brief (EIC_INTENSET) External Interrupt 5 Enable */ +#define EIC_INTENSET_EXTINT5 (1 << EIC_INTENSET_EXTINT5_Pos) +#define EIC_INTENSET_EXTINT6_Pos 6 /**< \brief (EIC_INTENSET) External Interrupt 6 Enable */ +#define EIC_INTENSET_EXTINT6 (1 << EIC_INTENSET_EXTINT6_Pos) +#define EIC_INTENSET_EXTINT7_Pos 7 /**< \brief (EIC_INTENSET) External Interrupt 7 Enable */ +#define EIC_INTENSET_EXTINT7 (1 << EIC_INTENSET_EXTINT7_Pos) +#define EIC_INTENSET_EXTINT8_Pos 8 /**< \brief (EIC_INTENSET) External Interrupt 8 Enable */ +#define EIC_INTENSET_EXTINT8 (1 << EIC_INTENSET_EXTINT8_Pos) +#define EIC_INTENSET_EXTINT9_Pos 9 /**< \brief (EIC_INTENSET) External Interrupt 9 Enable */ +#define EIC_INTENSET_EXTINT9 (1 << EIC_INTENSET_EXTINT9_Pos) +#define EIC_INTENSET_EXTINT10_Pos 10 /**< \brief (EIC_INTENSET) External Interrupt 10 Enable */ +#define EIC_INTENSET_EXTINT10 (1 << EIC_INTENSET_EXTINT10_Pos) +#define EIC_INTENSET_EXTINT11_Pos 11 /**< \brief (EIC_INTENSET) External Interrupt 11 Enable */ +#define EIC_INTENSET_EXTINT11 (1 << EIC_INTENSET_EXTINT11_Pos) +#define EIC_INTENSET_EXTINT12_Pos 12 /**< \brief (EIC_INTENSET) External Interrupt 12 Enable */ +#define EIC_INTENSET_EXTINT12 (1 << EIC_INTENSET_EXTINT12_Pos) +#define EIC_INTENSET_EXTINT13_Pos 13 /**< \brief (EIC_INTENSET) External Interrupt 13 Enable */ +#define EIC_INTENSET_EXTINT13 (1 << EIC_INTENSET_EXTINT13_Pos) +#define EIC_INTENSET_EXTINT14_Pos 14 /**< \brief (EIC_INTENSET) External Interrupt 14 Enable */ +#define EIC_INTENSET_EXTINT14 (1 << EIC_INTENSET_EXTINT14_Pos) +#define EIC_INTENSET_EXTINT15_Pos 15 /**< \brief (EIC_INTENSET) External Interrupt 15 Enable */ +#define EIC_INTENSET_EXTINT15 (1 << EIC_INTENSET_EXTINT15_Pos) +#define EIC_INTENSET_EXTINT_Pos 0 /**< \brief (EIC_INTENSET) External Interrupt x Enable */ +#define EIC_INTENSET_EXTINT_Msk (0xFFFFu << EIC_INTENSET_EXTINT_Pos) +#define EIC_INTENSET_EXTINT(value) ((EIC_INTENSET_EXTINT_Msk & ((value) << EIC_INTENSET_EXTINT_Pos))) +#define EIC_INTENSET_MASK 0x0000FFFFu /**< \brief (EIC_INTENSET) MASK Register */ + +/* -------- EIC_INTFLAG : (EIC Offset: 0x10) (R/W 32) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t EXTINT0:1; /*!< bit: 0 External Interrupt 0 */ + uint32_t EXTINT1:1; /*!< bit: 1 External Interrupt 1 */ + uint32_t EXTINT2:1; /*!< bit: 2 External Interrupt 2 */ + uint32_t EXTINT3:1; /*!< bit: 3 External Interrupt 3 */ + uint32_t EXTINT4:1; /*!< bit: 4 External Interrupt 4 */ + uint32_t EXTINT5:1; /*!< bit: 5 External Interrupt 5 */ + uint32_t EXTINT6:1; /*!< bit: 6 External Interrupt 6 */ + uint32_t EXTINT7:1; /*!< bit: 7 External Interrupt 7 */ + uint32_t EXTINT8:1; /*!< bit: 8 External Interrupt 8 */ + uint32_t EXTINT9:1; /*!< bit: 9 External Interrupt 9 */ + uint32_t EXTINT10:1; /*!< bit: 10 External Interrupt 10 */ + uint32_t EXTINT11:1; /*!< bit: 11 External Interrupt 11 */ + uint32_t EXTINT12:1; /*!< bit: 12 External Interrupt 12 */ + uint32_t EXTINT13:1; /*!< bit: 13 External Interrupt 13 */ + uint32_t EXTINT14:1; /*!< bit: 14 External Interrupt 14 */ + uint32_t EXTINT15:1; /*!< bit: 15 External Interrupt 15 */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t EXTINT:16; /*!< bit: 0..15 External Interrupt x */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} EIC_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_INTFLAG_OFFSET 0x10 /**< \brief (EIC_INTFLAG offset) Interrupt Flag Status and Clear */ +#define EIC_INTFLAG_RESETVALUE 0x00000000 /**< \brief (EIC_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define EIC_INTFLAG_EXTINT0_Pos 0 /**< \brief (EIC_INTFLAG) External Interrupt 0 */ +#define EIC_INTFLAG_EXTINT0 (1 << EIC_INTFLAG_EXTINT0_Pos) +#define EIC_INTFLAG_EXTINT1_Pos 1 /**< \brief (EIC_INTFLAG) External Interrupt 1 */ +#define EIC_INTFLAG_EXTINT1 (1 << EIC_INTFLAG_EXTINT1_Pos) +#define EIC_INTFLAG_EXTINT2_Pos 2 /**< \brief (EIC_INTFLAG) External Interrupt 2 */ +#define EIC_INTFLAG_EXTINT2 (1 << EIC_INTFLAG_EXTINT2_Pos) +#define EIC_INTFLAG_EXTINT3_Pos 3 /**< \brief (EIC_INTFLAG) External Interrupt 3 */ +#define EIC_INTFLAG_EXTINT3 (1 << EIC_INTFLAG_EXTINT3_Pos) +#define EIC_INTFLAG_EXTINT4_Pos 4 /**< \brief (EIC_INTFLAG) External Interrupt 4 */ +#define EIC_INTFLAG_EXTINT4 (1 << EIC_INTFLAG_EXTINT4_Pos) +#define EIC_INTFLAG_EXTINT5_Pos 5 /**< \brief (EIC_INTFLAG) External Interrupt 5 */ +#define EIC_INTFLAG_EXTINT5 (1 << EIC_INTFLAG_EXTINT5_Pos) +#define EIC_INTFLAG_EXTINT6_Pos 6 /**< \brief (EIC_INTFLAG) External Interrupt 6 */ +#define EIC_INTFLAG_EXTINT6 (1 << EIC_INTFLAG_EXTINT6_Pos) +#define EIC_INTFLAG_EXTINT7_Pos 7 /**< \brief (EIC_INTFLAG) External Interrupt 7 */ +#define EIC_INTFLAG_EXTINT7 (1 << EIC_INTFLAG_EXTINT7_Pos) +#define EIC_INTFLAG_EXTINT8_Pos 8 /**< \brief (EIC_INTFLAG) External Interrupt 8 */ +#define EIC_INTFLAG_EXTINT8 (1 << EIC_INTFLAG_EXTINT8_Pos) +#define EIC_INTFLAG_EXTINT9_Pos 9 /**< \brief (EIC_INTFLAG) External Interrupt 9 */ +#define EIC_INTFLAG_EXTINT9 (1 << EIC_INTFLAG_EXTINT9_Pos) +#define EIC_INTFLAG_EXTINT10_Pos 10 /**< \brief (EIC_INTFLAG) External Interrupt 10 */ +#define EIC_INTFLAG_EXTINT10 (1 << EIC_INTFLAG_EXTINT10_Pos) +#define EIC_INTFLAG_EXTINT11_Pos 11 /**< \brief (EIC_INTFLAG) External Interrupt 11 */ +#define EIC_INTFLAG_EXTINT11 (1 << EIC_INTFLAG_EXTINT11_Pos) +#define EIC_INTFLAG_EXTINT12_Pos 12 /**< \brief (EIC_INTFLAG) External Interrupt 12 */ +#define EIC_INTFLAG_EXTINT12 (1 << EIC_INTFLAG_EXTINT12_Pos) +#define EIC_INTFLAG_EXTINT13_Pos 13 /**< \brief (EIC_INTFLAG) External Interrupt 13 */ +#define EIC_INTFLAG_EXTINT13 (1 << EIC_INTFLAG_EXTINT13_Pos) +#define EIC_INTFLAG_EXTINT14_Pos 14 /**< \brief (EIC_INTFLAG) External Interrupt 14 */ +#define EIC_INTFLAG_EXTINT14 (1 << EIC_INTFLAG_EXTINT14_Pos) +#define EIC_INTFLAG_EXTINT15_Pos 15 /**< \brief (EIC_INTFLAG) External Interrupt 15 */ +#define EIC_INTFLAG_EXTINT15 (1 << EIC_INTFLAG_EXTINT15_Pos) +#define EIC_INTFLAG_EXTINT_Pos 0 /**< \brief (EIC_INTFLAG) External Interrupt x */ +#define EIC_INTFLAG_EXTINT_Msk (0xFFFFu << EIC_INTFLAG_EXTINT_Pos) +#define EIC_INTFLAG_EXTINT(value) ((EIC_INTFLAG_EXTINT_Msk & ((value) << EIC_INTFLAG_EXTINT_Pos))) +#define EIC_INTFLAG_MASK 0x0000FFFFu /**< \brief (EIC_INTFLAG) MASK Register */ + +/* -------- EIC_WAKEUP : (EIC Offset: 0x14) (R/W 32) Wake-Up Enable -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t WAKEUPEN0:1; /*!< bit: 0 External Interrupt 0 Wake-up Enable */ + uint32_t WAKEUPEN1:1; /*!< bit: 1 External Interrupt 1 Wake-up Enable */ + uint32_t WAKEUPEN2:1; /*!< bit: 2 External Interrupt 2 Wake-up Enable */ + uint32_t WAKEUPEN3:1; /*!< bit: 3 External Interrupt 3 Wake-up Enable */ + uint32_t WAKEUPEN4:1; /*!< bit: 4 External Interrupt 4 Wake-up Enable */ + uint32_t WAKEUPEN5:1; /*!< bit: 5 External Interrupt 5 Wake-up Enable */ + uint32_t WAKEUPEN6:1; /*!< bit: 6 External Interrupt 6 Wake-up Enable */ + uint32_t WAKEUPEN7:1; /*!< bit: 7 External Interrupt 7 Wake-up Enable */ + uint32_t WAKEUPEN8:1; /*!< bit: 8 External Interrupt 8 Wake-up Enable */ + uint32_t WAKEUPEN9:1; /*!< bit: 9 External Interrupt 9 Wake-up Enable */ + uint32_t WAKEUPEN10:1; /*!< bit: 10 External Interrupt 10 Wake-up Enable */ + uint32_t WAKEUPEN11:1; /*!< bit: 11 External Interrupt 11 Wake-up Enable */ + uint32_t WAKEUPEN12:1; /*!< bit: 12 External Interrupt 12 Wake-up Enable */ + uint32_t WAKEUPEN13:1; /*!< bit: 13 External Interrupt 13 Wake-up Enable */ + uint32_t WAKEUPEN14:1; /*!< bit: 14 External Interrupt 14 Wake-up Enable */ + uint32_t WAKEUPEN15:1; /*!< bit: 15 External Interrupt 15 Wake-up Enable */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t WAKEUPEN:16; /*!< bit: 0..15 External Interrupt x Wake-up Enable */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} EIC_WAKEUP_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_WAKEUP_OFFSET 0x14 /**< \brief (EIC_WAKEUP offset) Wake-Up Enable */ +#define EIC_WAKEUP_RESETVALUE 0x00000000 /**< \brief (EIC_WAKEUP reset_value) Wake-Up Enable */ + +#define EIC_WAKEUP_WAKEUPEN0_Pos 0 /**< \brief (EIC_WAKEUP) External Interrupt 0 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN0 (1 << EIC_WAKEUP_WAKEUPEN0_Pos) +#define EIC_WAKEUP_WAKEUPEN1_Pos 1 /**< \brief (EIC_WAKEUP) External Interrupt 1 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN1 (1 << EIC_WAKEUP_WAKEUPEN1_Pos) +#define EIC_WAKEUP_WAKEUPEN2_Pos 2 /**< \brief (EIC_WAKEUP) External Interrupt 2 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN2 (1 << EIC_WAKEUP_WAKEUPEN2_Pos) +#define EIC_WAKEUP_WAKEUPEN3_Pos 3 /**< \brief (EIC_WAKEUP) External Interrupt 3 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN3 (1 << EIC_WAKEUP_WAKEUPEN3_Pos) +#define EIC_WAKEUP_WAKEUPEN4_Pos 4 /**< \brief (EIC_WAKEUP) External Interrupt 4 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN4 (1 << EIC_WAKEUP_WAKEUPEN4_Pos) +#define EIC_WAKEUP_WAKEUPEN5_Pos 5 /**< \brief (EIC_WAKEUP) External Interrupt 5 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN5 (1 << EIC_WAKEUP_WAKEUPEN5_Pos) +#define EIC_WAKEUP_WAKEUPEN6_Pos 6 /**< \brief (EIC_WAKEUP) External Interrupt 6 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN6 (1 << EIC_WAKEUP_WAKEUPEN6_Pos) +#define EIC_WAKEUP_WAKEUPEN7_Pos 7 /**< \brief (EIC_WAKEUP) External Interrupt 7 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN7 (1 << EIC_WAKEUP_WAKEUPEN7_Pos) +#define EIC_WAKEUP_WAKEUPEN8_Pos 8 /**< \brief (EIC_WAKEUP) External Interrupt 8 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN8 (1 << EIC_WAKEUP_WAKEUPEN8_Pos) +#define EIC_WAKEUP_WAKEUPEN9_Pos 9 /**< \brief (EIC_WAKEUP) External Interrupt 9 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN9 (1 << EIC_WAKEUP_WAKEUPEN9_Pos) +#define EIC_WAKEUP_WAKEUPEN10_Pos 10 /**< \brief (EIC_WAKEUP) External Interrupt 10 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN10 (1 << EIC_WAKEUP_WAKEUPEN10_Pos) +#define EIC_WAKEUP_WAKEUPEN11_Pos 11 /**< \brief (EIC_WAKEUP) External Interrupt 11 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN11 (1 << EIC_WAKEUP_WAKEUPEN11_Pos) +#define EIC_WAKEUP_WAKEUPEN12_Pos 12 /**< \brief (EIC_WAKEUP) External Interrupt 12 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN12 (1 << EIC_WAKEUP_WAKEUPEN12_Pos) +#define EIC_WAKEUP_WAKEUPEN13_Pos 13 /**< \brief (EIC_WAKEUP) External Interrupt 13 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN13 (1 << EIC_WAKEUP_WAKEUPEN13_Pos) +#define EIC_WAKEUP_WAKEUPEN14_Pos 14 /**< \brief (EIC_WAKEUP) External Interrupt 14 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN14 (1 << EIC_WAKEUP_WAKEUPEN14_Pos) +#define EIC_WAKEUP_WAKEUPEN15_Pos 15 /**< \brief (EIC_WAKEUP) External Interrupt 15 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN15 (1 << EIC_WAKEUP_WAKEUPEN15_Pos) +#define EIC_WAKEUP_WAKEUPEN_Pos 0 /**< \brief (EIC_WAKEUP) External Interrupt x Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN_Msk (0xFFFFu << EIC_WAKEUP_WAKEUPEN_Pos) +#define EIC_WAKEUP_WAKEUPEN(value) ((EIC_WAKEUP_WAKEUPEN_Msk & ((value) << EIC_WAKEUP_WAKEUPEN_Pos))) +#define EIC_WAKEUP_MASK 0x0000FFFFu /**< \brief (EIC_WAKEUP) MASK Register */ + +/* -------- EIC_CONFIG : (EIC Offset: 0x18) (R/W 32) Configuration n -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SENSE0:3; /*!< bit: 0.. 2 Input Sense 0 Configuration */ + uint32_t FILTEN0:1; /*!< bit: 3 Filter 0 Enable */ + uint32_t SENSE1:3; /*!< bit: 4.. 6 Input Sense 1 Configuration */ + uint32_t FILTEN1:1; /*!< bit: 7 Filter 1 Enable */ + uint32_t SENSE2:3; /*!< bit: 8..10 Input Sense 2 Configuration */ + uint32_t FILTEN2:1; /*!< bit: 11 Filter 2 Enable */ + uint32_t SENSE3:3; /*!< bit: 12..14 Input Sense 3 Configuration */ + uint32_t FILTEN3:1; /*!< bit: 15 Filter 3 Enable */ + uint32_t SENSE4:3; /*!< bit: 16..18 Input Sense 4 Configuration */ + uint32_t FILTEN4:1; /*!< bit: 19 Filter 4 Enable */ + uint32_t SENSE5:3; /*!< bit: 20..22 Input Sense 5 Configuration */ + uint32_t FILTEN5:1; /*!< bit: 23 Filter 5 Enable */ + uint32_t SENSE6:3; /*!< bit: 24..26 Input Sense 6 Configuration */ + uint32_t FILTEN6:1; /*!< bit: 27 Filter 6 Enable */ + uint32_t SENSE7:3; /*!< bit: 28..30 Input Sense 7 Configuration */ + uint32_t FILTEN7:1; /*!< bit: 31 Filter 7 Enable */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} EIC_CONFIG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_CONFIG_OFFSET 0x18 /**< \brief (EIC_CONFIG offset) Configuration n */ +#define EIC_CONFIG_RESETVALUE 0x00000000 /**< \brief (EIC_CONFIG reset_value) Configuration n */ + +#define EIC_CONFIG_SENSE0_Pos 0 /**< \brief (EIC_CONFIG) Input Sense 0 Configuration */ +#define EIC_CONFIG_SENSE0_Msk (0x7u << EIC_CONFIG_SENSE0_Pos) +#define EIC_CONFIG_SENSE0(value) ((EIC_CONFIG_SENSE0_Msk & ((value) << EIC_CONFIG_SENSE0_Pos))) +#define EIC_CONFIG_SENSE0_NONE_Val 0x0u /**< \brief (EIC_CONFIG) No detection */ +#define EIC_CONFIG_SENSE0_RISE_Val 0x1u /**< \brief (EIC_CONFIG) Rising-edge detection */ +#define EIC_CONFIG_SENSE0_FALL_Val 0x2u /**< \brief (EIC_CONFIG) Falling-edge detection */ +#define EIC_CONFIG_SENSE0_BOTH_Val 0x3u /**< \brief (EIC_CONFIG) Both-edges detection */ +#define EIC_CONFIG_SENSE0_HIGH_Val 0x4u /**< \brief (EIC_CONFIG) High-level detection */ +#define EIC_CONFIG_SENSE0_LOW_Val 0x5u /**< \brief (EIC_CONFIG) Low-level detection */ +#define EIC_CONFIG_SENSE0_NONE (EIC_CONFIG_SENSE0_NONE_Val << EIC_CONFIG_SENSE0_Pos) +#define EIC_CONFIG_SENSE0_RISE (EIC_CONFIG_SENSE0_RISE_Val << EIC_CONFIG_SENSE0_Pos) +#define EIC_CONFIG_SENSE0_FALL (EIC_CONFIG_SENSE0_FALL_Val << EIC_CONFIG_SENSE0_Pos) +#define EIC_CONFIG_SENSE0_BOTH (EIC_CONFIG_SENSE0_BOTH_Val << EIC_CONFIG_SENSE0_Pos) +#define EIC_CONFIG_SENSE0_HIGH (EIC_CONFIG_SENSE0_HIGH_Val << EIC_CONFIG_SENSE0_Pos) +#define EIC_CONFIG_SENSE0_LOW (EIC_CONFIG_SENSE0_LOW_Val << EIC_CONFIG_SENSE0_Pos) +#define EIC_CONFIG_FILTEN0_Pos 3 /**< \brief (EIC_CONFIG) Filter 0 Enable */ +#define EIC_CONFIG_FILTEN0 (0x1u << EIC_CONFIG_FILTEN0_Pos) +#define EIC_CONFIG_SENSE1_Pos 4 /**< \brief (EIC_CONFIG) Input Sense 1 Configuration */ +#define EIC_CONFIG_SENSE1_Msk (0x7u << EIC_CONFIG_SENSE1_Pos) +#define EIC_CONFIG_SENSE1(value) ((EIC_CONFIG_SENSE1_Msk & ((value) << EIC_CONFIG_SENSE1_Pos))) +#define EIC_CONFIG_SENSE1_NONE_Val 0x0u /**< \brief (EIC_CONFIG) No detection */ +#define EIC_CONFIG_SENSE1_RISE_Val 0x1u /**< \brief (EIC_CONFIG) Rising edge detection */ +#define EIC_CONFIG_SENSE1_FALL_Val 0x2u /**< \brief (EIC_CONFIG) Falling edge detection */ +#define EIC_CONFIG_SENSE1_BOTH_Val 0x3u /**< \brief (EIC_CONFIG) Both edges detection */ +#define EIC_CONFIG_SENSE1_HIGH_Val 0x4u /**< \brief (EIC_CONFIG) High level detection */ +#define EIC_CONFIG_SENSE1_LOW_Val 0x5u /**< \brief (EIC_CONFIG) Low level detection */ +#define EIC_CONFIG_SENSE1_NONE (EIC_CONFIG_SENSE1_NONE_Val << EIC_CONFIG_SENSE1_Pos) +#define EIC_CONFIG_SENSE1_RISE (EIC_CONFIG_SENSE1_RISE_Val << EIC_CONFIG_SENSE1_Pos) +#define EIC_CONFIG_SENSE1_FALL (EIC_CONFIG_SENSE1_FALL_Val << EIC_CONFIG_SENSE1_Pos) +#define EIC_CONFIG_SENSE1_BOTH (EIC_CONFIG_SENSE1_BOTH_Val << EIC_CONFIG_SENSE1_Pos) +#define EIC_CONFIG_SENSE1_HIGH (EIC_CONFIG_SENSE1_HIGH_Val << EIC_CONFIG_SENSE1_Pos) +#define EIC_CONFIG_SENSE1_LOW (EIC_CONFIG_SENSE1_LOW_Val << EIC_CONFIG_SENSE1_Pos) +#define EIC_CONFIG_FILTEN1_Pos 7 /**< \brief (EIC_CONFIG) Filter 1 Enable */ +#define EIC_CONFIG_FILTEN1 (0x1u << EIC_CONFIG_FILTEN1_Pos) +#define EIC_CONFIG_SENSE2_Pos 8 /**< \brief (EIC_CONFIG) Input Sense 2 Configuration */ +#define EIC_CONFIG_SENSE2_Msk (0x7u << EIC_CONFIG_SENSE2_Pos) +#define EIC_CONFIG_SENSE2(value) ((EIC_CONFIG_SENSE2_Msk & ((value) << EIC_CONFIG_SENSE2_Pos))) +#define EIC_CONFIG_SENSE2_NONE_Val 0x0u /**< \brief (EIC_CONFIG) No detection */ +#define EIC_CONFIG_SENSE2_RISE_Val 0x1u /**< \brief (EIC_CONFIG) Rising edge detection */ +#define EIC_CONFIG_SENSE2_FALL_Val 0x2u /**< \brief (EIC_CONFIG) Falling edge detection */ +#define EIC_CONFIG_SENSE2_BOTH_Val 0x3u /**< \brief (EIC_CONFIG) Both edges detection */ +#define EIC_CONFIG_SENSE2_HIGH_Val 0x4u /**< \brief (EIC_CONFIG) High level detection */ +#define EIC_CONFIG_SENSE2_LOW_Val 0x5u /**< \brief (EIC_CONFIG) Low level detection */ +#define EIC_CONFIG_SENSE2_NONE (EIC_CONFIG_SENSE2_NONE_Val << EIC_CONFIG_SENSE2_Pos) +#define EIC_CONFIG_SENSE2_RISE (EIC_CONFIG_SENSE2_RISE_Val << EIC_CONFIG_SENSE2_Pos) +#define EIC_CONFIG_SENSE2_FALL (EIC_CONFIG_SENSE2_FALL_Val << EIC_CONFIG_SENSE2_Pos) +#define EIC_CONFIG_SENSE2_BOTH (EIC_CONFIG_SENSE2_BOTH_Val << EIC_CONFIG_SENSE2_Pos) +#define EIC_CONFIG_SENSE2_HIGH (EIC_CONFIG_SENSE2_HIGH_Val << EIC_CONFIG_SENSE2_Pos) +#define EIC_CONFIG_SENSE2_LOW (EIC_CONFIG_SENSE2_LOW_Val << EIC_CONFIG_SENSE2_Pos) +#define EIC_CONFIG_FILTEN2_Pos 11 /**< \brief (EIC_CONFIG) Filter 2 Enable */ +#define EIC_CONFIG_FILTEN2 (0x1u << EIC_CONFIG_FILTEN2_Pos) +#define EIC_CONFIG_SENSE3_Pos 12 /**< \brief (EIC_CONFIG) Input Sense 3 Configuration */ +#define EIC_CONFIG_SENSE3_Msk (0x7u << EIC_CONFIG_SENSE3_Pos) +#define EIC_CONFIG_SENSE3(value) ((EIC_CONFIG_SENSE3_Msk & ((value) << EIC_CONFIG_SENSE3_Pos))) +#define EIC_CONFIG_SENSE3_NONE_Val 0x0u /**< \brief (EIC_CONFIG) No detection */ +#define EIC_CONFIG_SENSE3_RISE_Val 0x1u /**< \brief (EIC_CONFIG) Rising edge detection */ +#define EIC_CONFIG_SENSE3_FALL_Val 0x2u /**< \brief (EIC_CONFIG) Falling edge detection */ +#define EIC_CONFIG_SENSE3_BOTH_Val 0x3u /**< \brief (EIC_CONFIG) Both edges detection */ +#define EIC_CONFIG_SENSE3_HIGH_Val 0x4u /**< \brief (EIC_CONFIG) High level detection */ +#define EIC_CONFIG_SENSE3_LOW_Val 0x5u /**< \brief (EIC_CONFIG) Low level detection */ +#define EIC_CONFIG_SENSE3_NONE (EIC_CONFIG_SENSE3_NONE_Val << EIC_CONFIG_SENSE3_Pos) +#define EIC_CONFIG_SENSE3_RISE (EIC_CONFIG_SENSE3_RISE_Val << EIC_CONFIG_SENSE3_Pos) +#define EIC_CONFIG_SENSE3_FALL (EIC_CONFIG_SENSE3_FALL_Val << EIC_CONFIG_SENSE3_Pos) +#define EIC_CONFIG_SENSE3_BOTH (EIC_CONFIG_SENSE3_BOTH_Val << EIC_CONFIG_SENSE3_Pos) +#define EIC_CONFIG_SENSE3_HIGH (EIC_CONFIG_SENSE3_HIGH_Val << EIC_CONFIG_SENSE3_Pos) +#define EIC_CONFIG_SENSE3_LOW (EIC_CONFIG_SENSE3_LOW_Val << EIC_CONFIG_SENSE3_Pos) +#define EIC_CONFIG_FILTEN3_Pos 15 /**< \brief (EIC_CONFIG) Filter 3 Enable */ +#define EIC_CONFIG_FILTEN3 (0x1u << EIC_CONFIG_FILTEN3_Pos) +#define EIC_CONFIG_SENSE4_Pos 16 /**< \brief (EIC_CONFIG) Input Sense 4 Configuration */ +#define EIC_CONFIG_SENSE4_Msk (0x7u << EIC_CONFIG_SENSE4_Pos) +#define EIC_CONFIG_SENSE4(value) ((EIC_CONFIG_SENSE4_Msk & ((value) << EIC_CONFIG_SENSE4_Pos))) +#define EIC_CONFIG_SENSE4_NONE_Val 0x0u /**< \brief (EIC_CONFIG) No detection */ +#define EIC_CONFIG_SENSE4_RISE_Val 0x1u /**< \brief (EIC_CONFIG) Rising edge detection */ +#define EIC_CONFIG_SENSE4_FALL_Val 0x2u /**< \brief (EIC_CONFIG) Falling edge detection */ +#define EIC_CONFIG_SENSE4_BOTH_Val 0x3u /**< \brief (EIC_CONFIG) Both edges detection */ +#define EIC_CONFIG_SENSE4_HIGH_Val 0x4u /**< \brief (EIC_CONFIG) High level detection */ +#define EIC_CONFIG_SENSE4_LOW_Val 0x5u /**< \brief (EIC_CONFIG) Low level detection */ +#define EIC_CONFIG_SENSE4_NONE (EIC_CONFIG_SENSE4_NONE_Val << EIC_CONFIG_SENSE4_Pos) +#define EIC_CONFIG_SENSE4_RISE (EIC_CONFIG_SENSE4_RISE_Val << EIC_CONFIG_SENSE4_Pos) +#define EIC_CONFIG_SENSE4_FALL (EIC_CONFIG_SENSE4_FALL_Val << EIC_CONFIG_SENSE4_Pos) +#define EIC_CONFIG_SENSE4_BOTH (EIC_CONFIG_SENSE4_BOTH_Val << EIC_CONFIG_SENSE4_Pos) +#define EIC_CONFIG_SENSE4_HIGH (EIC_CONFIG_SENSE4_HIGH_Val << EIC_CONFIG_SENSE4_Pos) +#define EIC_CONFIG_SENSE4_LOW (EIC_CONFIG_SENSE4_LOW_Val << EIC_CONFIG_SENSE4_Pos) +#define EIC_CONFIG_FILTEN4_Pos 19 /**< \brief (EIC_CONFIG) Filter 4 Enable */ +#define EIC_CONFIG_FILTEN4 (0x1u << EIC_CONFIG_FILTEN4_Pos) +#define EIC_CONFIG_SENSE5_Pos 20 /**< \brief (EIC_CONFIG) Input Sense 5 Configuration */ +#define EIC_CONFIG_SENSE5_Msk (0x7u << EIC_CONFIG_SENSE5_Pos) +#define EIC_CONFIG_SENSE5(value) ((EIC_CONFIG_SENSE5_Msk & ((value) << EIC_CONFIG_SENSE5_Pos))) +#define EIC_CONFIG_SENSE5_NONE_Val 0x0u /**< \brief (EIC_CONFIG) No detection */ +#define EIC_CONFIG_SENSE5_RISE_Val 0x1u /**< \brief (EIC_CONFIG) Rising edge detection */ +#define EIC_CONFIG_SENSE5_FALL_Val 0x2u /**< \brief (EIC_CONFIG) Falling edge detection */ +#define EIC_CONFIG_SENSE5_BOTH_Val 0x3u /**< \brief (EIC_CONFIG) Both edges detection */ +#define EIC_CONFIG_SENSE5_HIGH_Val 0x4u /**< \brief (EIC_CONFIG) High level detection */ +#define EIC_CONFIG_SENSE5_LOW_Val 0x5u /**< \brief (EIC_CONFIG) Low level detection */ +#define EIC_CONFIG_SENSE5_NONE (EIC_CONFIG_SENSE5_NONE_Val << EIC_CONFIG_SENSE5_Pos) +#define EIC_CONFIG_SENSE5_RISE (EIC_CONFIG_SENSE5_RISE_Val << EIC_CONFIG_SENSE5_Pos) +#define EIC_CONFIG_SENSE5_FALL (EIC_CONFIG_SENSE5_FALL_Val << EIC_CONFIG_SENSE5_Pos) +#define EIC_CONFIG_SENSE5_BOTH (EIC_CONFIG_SENSE5_BOTH_Val << EIC_CONFIG_SENSE5_Pos) +#define EIC_CONFIG_SENSE5_HIGH (EIC_CONFIG_SENSE5_HIGH_Val << EIC_CONFIG_SENSE5_Pos) +#define EIC_CONFIG_SENSE5_LOW (EIC_CONFIG_SENSE5_LOW_Val << EIC_CONFIG_SENSE5_Pos) +#define EIC_CONFIG_FILTEN5_Pos 23 /**< \brief (EIC_CONFIG) Filter 5 Enable */ +#define EIC_CONFIG_FILTEN5 (0x1u << EIC_CONFIG_FILTEN5_Pos) +#define EIC_CONFIG_SENSE6_Pos 24 /**< \brief (EIC_CONFIG) Input Sense 6 Configuration */ +#define EIC_CONFIG_SENSE6_Msk (0x7u << EIC_CONFIG_SENSE6_Pos) +#define EIC_CONFIG_SENSE6(value) ((EIC_CONFIG_SENSE6_Msk & ((value) << EIC_CONFIG_SENSE6_Pos))) +#define EIC_CONFIG_SENSE6_NONE_Val 0x0u /**< \brief (EIC_CONFIG) No detection */ +#define EIC_CONFIG_SENSE6_RISE_Val 0x1u /**< \brief (EIC_CONFIG) Rising edge detection */ +#define EIC_CONFIG_SENSE6_FALL_Val 0x2u /**< \brief (EIC_CONFIG) Falling edge detection */ +#define EIC_CONFIG_SENSE6_BOTH_Val 0x3u /**< \brief (EIC_CONFIG) Both edges detection */ +#define EIC_CONFIG_SENSE6_HIGH_Val 0x4u /**< \brief (EIC_CONFIG) High level detection */ +#define EIC_CONFIG_SENSE6_LOW_Val 0x5u /**< \brief (EIC_CONFIG) Low level detection */ +#define EIC_CONFIG_SENSE6_NONE (EIC_CONFIG_SENSE6_NONE_Val << EIC_CONFIG_SENSE6_Pos) +#define EIC_CONFIG_SENSE6_RISE (EIC_CONFIG_SENSE6_RISE_Val << EIC_CONFIG_SENSE6_Pos) +#define EIC_CONFIG_SENSE6_FALL (EIC_CONFIG_SENSE6_FALL_Val << EIC_CONFIG_SENSE6_Pos) +#define EIC_CONFIG_SENSE6_BOTH (EIC_CONFIG_SENSE6_BOTH_Val << EIC_CONFIG_SENSE6_Pos) +#define EIC_CONFIG_SENSE6_HIGH (EIC_CONFIG_SENSE6_HIGH_Val << EIC_CONFIG_SENSE6_Pos) +#define EIC_CONFIG_SENSE6_LOW (EIC_CONFIG_SENSE6_LOW_Val << EIC_CONFIG_SENSE6_Pos) +#define EIC_CONFIG_FILTEN6_Pos 27 /**< \brief (EIC_CONFIG) Filter 6 Enable */ +#define EIC_CONFIG_FILTEN6 (0x1u << EIC_CONFIG_FILTEN6_Pos) +#define EIC_CONFIG_SENSE7_Pos 28 /**< \brief (EIC_CONFIG) Input Sense 7 Configuration */ +#define EIC_CONFIG_SENSE7_Msk (0x7u << EIC_CONFIG_SENSE7_Pos) +#define EIC_CONFIG_SENSE7(value) ((EIC_CONFIG_SENSE7_Msk & ((value) << EIC_CONFIG_SENSE7_Pos))) +#define EIC_CONFIG_SENSE7_NONE_Val 0x0u /**< \brief (EIC_CONFIG) No detection */ +#define EIC_CONFIG_SENSE7_RISE_Val 0x1u /**< \brief (EIC_CONFIG) Rising edge detection */ +#define EIC_CONFIG_SENSE7_FALL_Val 0x2u /**< \brief (EIC_CONFIG) Falling edge detection */ +#define EIC_CONFIG_SENSE7_BOTH_Val 0x3u /**< \brief (EIC_CONFIG) Both edges detection */ +#define EIC_CONFIG_SENSE7_HIGH_Val 0x4u /**< \brief (EIC_CONFIG) High level detection */ +#define EIC_CONFIG_SENSE7_LOW_Val 0x5u /**< \brief (EIC_CONFIG) Low level detection */ +#define EIC_CONFIG_SENSE7_NONE (EIC_CONFIG_SENSE7_NONE_Val << EIC_CONFIG_SENSE7_Pos) +#define EIC_CONFIG_SENSE7_RISE (EIC_CONFIG_SENSE7_RISE_Val << EIC_CONFIG_SENSE7_Pos) +#define EIC_CONFIG_SENSE7_FALL (EIC_CONFIG_SENSE7_FALL_Val << EIC_CONFIG_SENSE7_Pos) +#define EIC_CONFIG_SENSE7_BOTH (EIC_CONFIG_SENSE7_BOTH_Val << EIC_CONFIG_SENSE7_Pos) +#define EIC_CONFIG_SENSE7_HIGH (EIC_CONFIG_SENSE7_HIGH_Val << EIC_CONFIG_SENSE7_Pos) +#define EIC_CONFIG_SENSE7_LOW (EIC_CONFIG_SENSE7_LOW_Val << EIC_CONFIG_SENSE7_Pos) +#define EIC_CONFIG_FILTEN7_Pos 31 /**< \brief (EIC_CONFIG) Filter 7 Enable */ +#define EIC_CONFIG_FILTEN7 (0x1u << EIC_CONFIG_FILTEN7_Pos) +#define EIC_CONFIG_MASK 0xFFFFFFFFu /**< \brief (EIC_CONFIG) MASK Register */ + +/** \brief EIC hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO EIC_CTRL_Type CTRL; /**< \brief Offset: 0x00 (R/W 8) Control */ + __I EIC_STATUS_Type STATUS; /**< \brief Offset: 0x01 (R/ 8) Status */ + __IO EIC_NMICTRL_Type NMICTRL; /**< \brief Offset: 0x02 (R/W 8) Non-Maskable Interrupt Control */ + __IO EIC_NMIFLAG_Type NMIFLAG; /**< \brief Offset: 0x03 (R/W 8) Non-Maskable Interrupt Flag Status and Clear */ + __IO EIC_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x04 (R/W 32) Event Control */ + __IO EIC_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x08 (R/W 32) Interrupt Enable Clear */ + __IO EIC_INTENSET_Type INTENSET; /**< \brief Offset: 0x0C (R/W 32) Interrupt Enable Set */ + __IO EIC_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x10 (R/W 32) Interrupt Flag Status and Clear */ + __IO EIC_WAKEUP_Type WAKEUP; /**< \brief Offset: 0x14 (R/W 32) Wake-Up Enable */ + __IO EIC_CONFIG_Type CONFIG[2]; /**< \brief Offset: 0x18 (R/W 32) Configuration n */ +} Eic; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_EIC_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/evsys.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/evsys.h new file mode 100644 index 0000000..20d6704 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/evsys.h @@ -0,0 +1,604 @@ +/** + * \file + * + * \brief Component description for EVSYS + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_EVSYS_COMPONENT_ +#define _SAMD21_EVSYS_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR EVSYS */ +/* ========================================================================== */ +/** \addtogroup SAMD21_EVSYS Event System Interface */ +/*@{*/ + +#define EVSYS_U2208 +#define REV_EVSYS 0x101 + +/* -------- EVSYS_CTRL : (EVSYS Offset: 0x00) ( /W 8) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset */ + uint8_t :3; /*!< bit: 1.. 3 Reserved */ + uint8_t GCLKREQ:1; /*!< bit: 4 Generic Clock Requests */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} EVSYS_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EVSYS_CTRL_OFFSET 0x00 /**< \brief (EVSYS_CTRL offset) Control */ +#define EVSYS_CTRL_RESETVALUE 0x00 /**< \brief (EVSYS_CTRL reset_value) Control */ + +#define EVSYS_CTRL_SWRST_Pos 0 /**< \brief (EVSYS_CTRL) Software Reset */ +#define EVSYS_CTRL_SWRST (0x1u << EVSYS_CTRL_SWRST_Pos) +#define EVSYS_CTRL_GCLKREQ_Pos 4 /**< \brief (EVSYS_CTRL) Generic Clock Requests */ +#define EVSYS_CTRL_GCLKREQ (0x1u << EVSYS_CTRL_GCLKREQ_Pos) +#define EVSYS_CTRL_MASK 0x11u /**< \brief (EVSYS_CTRL) MASK Register */ + +/* -------- EVSYS_CHANNEL : (EVSYS Offset: 0x04) (R/W 32) Channel -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CHANNEL:4; /*!< bit: 0.. 3 Channel Selection */ + uint32_t :4; /*!< bit: 4.. 7 Reserved */ + uint32_t SWEVT:1; /*!< bit: 8 Software Event */ + uint32_t :7; /*!< bit: 9..15 Reserved */ + uint32_t EVGEN:7; /*!< bit: 16..22 Event Generator Selection */ + uint32_t :1; /*!< bit: 23 Reserved */ + uint32_t PATH:2; /*!< bit: 24..25 Path Selection */ + uint32_t EDGSEL:2; /*!< bit: 26..27 Edge Detection Selection */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} EVSYS_CHANNEL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EVSYS_CHANNEL_OFFSET 0x04 /**< \brief (EVSYS_CHANNEL offset) Channel */ +#define EVSYS_CHANNEL_RESETVALUE 0x00000000 /**< \brief (EVSYS_CHANNEL reset_value) Channel */ + +#define EVSYS_CHANNEL_CHANNEL_Pos 0 /**< \brief (EVSYS_CHANNEL) Channel Selection */ +#define EVSYS_CHANNEL_CHANNEL_Msk (0xFu << EVSYS_CHANNEL_CHANNEL_Pos) +#define EVSYS_CHANNEL_CHANNEL(value) ((EVSYS_CHANNEL_CHANNEL_Msk & ((value) << EVSYS_CHANNEL_CHANNEL_Pos))) +#define EVSYS_CHANNEL_SWEVT_Pos 8 /**< \brief (EVSYS_CHANNEL) Software Event */ +#define EVSYS_CHANNEL_SWEVT (0x1u << EVSYS_CHANNEL_SWEVT_Pos) +#define EVSYS_CHANNEL_EVGEN_Pos 16 /**< \brief (EVSYS_CHANNEL) Event Generator Selection */ +#define EVSYS_CHANNEL_EVGEN_Msk (0x7Fu << EVSYS_CHANNEL_EVGEN_Pos) +#define EVSYS_CHANNEL_EVGEN(value) ((EVSYS_CHANNEL_EVGEN_Msk & ((value) << EVSYS_CHANNEL_EVGEN_Pos))) +#define EVSYS_CHANNEL_PATH_Pos 24 /**< \brief (EVSYS_CHANNEL) Path Selection */ +#define EVSYS_CHANNEL_PATH_Msk (0x3u << EVSYS_CHANNEL_PATH_Pos) +#define EVSYS_CHANNEL_PATH(value) ((EVSYS_CHANNEL_PATH_Msk & ((value) << EVSYS_CHANNEL_PATH_Pos))) +#define EVSYS_CHANNEL_PATH_SYNCHRONOUS_Val 0x0u /**< \brief (EVSYS_CHANNEL) Synchronous path */ +#define EVSYS_CHANNEL_PATH_RESYNCHRONIZED_Val 0x1u /**< \brief (EVSYS_CHANNEL) Resynchronized path */ +#define EVSYS_CHANNEL_PATH_ASYNCHRONOUS_Val 0x2u /**< \brief (EVSYS_CHANNEL) Asynchronous path */ +#define EVSYS_CHANNEL_PATH_SYNCHRONOUS (EVSYS_CHANNEL_PATH_SYNCHRONOUS_Val << EVSYS_CHANNEL_PATH_Pos) +#define EVSYS_CHANNEL_PATH_RESYNCHRONIZED (EVSYS_CHANNEL_PATH_RESYNCHRONIZED_Val << EVSYS_CHANNEL_PATH_Pos) +#define EVSYS_CHANNEL_PATH_ASYNCHRONOUS (EVSYS_CHANNEL_PATH_ASYNCHRONOUS_Val << EVSYS_CHANNEL_PATH_Pos) +#define EVSYS_CHANNEL_EDGSEL_Pos 26 /**< \brief (EVSYS_CHANNEL) Edge Detection Selection */ +#define EVSYS_CHANNEL_EDGSEL_Msk (0x3u << EVSYS_CHANNEL_EDGSEL_Pos) +#define EVSYS_CHANNEL_EDGSEL(value) ((EVSYS_CHANNEL_EDGSEL_Msk & ((value) << EVSYS_CHANNEL_EDGSEL_Pos))) +#define EVSYS_CHANNEL_EDGSEL_NO_EVT_OUTPUT_Val 0x0u /**< \brief (EVSYS_CHANNEL) No event output when using the resynchronized or synchronous path */ +#define EVSYS_CHANNEL_EDGSEL_RISING_EDGE_Val 0x1u /**< \brief (EVSYS_CHANNEL) Event detection only on the rising edge of the signal from the event generator when using the resynchronized or synchronous path */ +#define EVSYS_CHANNEL_EDGSEL_FALLING_EDGE_Val 0x2u /**< \brief (EVSYS_CHANNEL) Event detection only on the falling edge of the signal from the event generator when using the resynchronized or synchronous path */ +#define EVSYS_CHANNEL_EDGSEL_BOTH_EDGES_Val 0x3u /**< \brief (EVSYS_CHANNEL) Event detection on rising and falling edges of the signal from the event generator when using the resynchronized or synchronous path */ +#define EVSYS_CHANNEL_EDGSEL_NO_EVT_OUTPUT (EVSYS_CHANNEL_EDGSEL_NO_EVT_OUTPUT_Val << EVSYS_CHANNEL_EDGSEL_Pos) +#define EVSYS_CHANNEL_EDGSEL_RISING_EDGE (EVSYS_CHANNEL_EDGSEL_RISING_EDGE_Val << EVSYS_CHANNEL_EDGSEL_Pos) +#define EVSYS_CHANNEL_EDGSEL_FALLING_EDGE (EVSYS_CHANNEL_EDGSEL_FALLING_EDGE_Val << EVSYS_CHANNEL_EDGSEL_Pos) +#define EVSYS_CHANNEL_EDGSEL_BOTH_EDGES (EVSYS_CHANNEL_EDGSEL_BOTH_EDGES_Val << EVSYS_CHANNEL_EDGSEL_Pos) +#define EVSYS_CHANNEL_MASK 0x0F7F010Fu /**< \brief (EVSYS_CHANNEL) MASK Register */ + +/* -------- EVSYS_USER : (EVSYS Offset: 0x08) (R/W 16) User Multiplexer -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t USER:5; /*!< bit: 0.. 4 User Multiplexer Selection */ + uint16_t :3; /*!< bit: 5.. 7 Reserved */ + uint16_t CHANNEL:5; /*!< bit: 8..12 Channel Event Selection */ + uint16_t :3; /*!< bit: 13..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} EVSYS_USER_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EVSYS_USER_OFFSET 0x08 /**< \brief (EVSYS_USER offset) User Multiplexer */ +#define EVSYS_USER_RESETVALUE 0x0000 /**< \brief (EVSYS_USER reset_value) User Multiplexer */ + +#define EVSYS_USER_USER_Pos 0 /**< \brief (EVSYS_USER) User Multiplexer Selection */ +#define EVSYS_USER_USER_Msk (0x1Fu << EVSYS_USER_USER_Pos) +#define EVSYS_USER_USER(value) ((EVSYS_USER_USER_Msk & ((value) << EVSYS_USER_USER_Pos))) +#define EVSYS_USER_CHANNEL_Pos 8 /**< \brief (EVSYS_USER) Channel Event Selection */ +#define EVSYS_USER_CHANNEL_Msk (0x1Fu << EVSYS_USER_CHANNEL_Pos) +#define EVSYS_USER_CHANNEL(value) ((EVSYS_USER_CHANNEL_Msk & ((value) << EVSYS_USER_CHANNEL_Pos))) +#define EVSYS_USER_CHANNEL_0_Val 0x0u /**< \brief (EVSYS_USER) No Channel Output Selected */ +#define EVSYS_USER_CHANNEL_0 (EVSYS_USER_CHANNEL_0_Val << EVSYS_USER_CHANNEL_Pos) +#define EVSYS_USER_MASK 0x1F1Fu /**< \brief (EVSYS_USER) MASK Register */ + +/* -------- EVSYS_CHSTATUS : (EVSYS Offset: 0x0C) (R/ 32) Channel Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t USRRDY0:1; /*!< bit: 0 Channel 0 User Ready */ + uint32_t USRRDY1:1; /*!< bit: 1 Channel 1 User Ready */ + uint32_t USRRDY2:1; /*!< bit: 2 Channel 2 User Ready */ + uint32_t USRRDY3:1; /*!< bit: 3 Channel 3 User Ready */ + uint32_t USRRDY4:1; /*!< bit: 4 Channel 4 User Ready */ + uint32_t USRRDY5:1; /*!< bit: 5 Channel 5 User Ready */ + uint32_t USRRDY6:1; /*!< bit: 6 Channel 6 User Ready */ + uint32_t USRRDY7:1; /*!< bit: 7 Channel 7 User Ready */ + uint32_t CHBUSY0:1; /*!< bit: 8 Channel 0 Busy */ + uint32_t CHBUSY1:1; /*!< bit: 9 Channel 1 Busy */ + uint32_t CHBUSY2:1; /*!< bit: 10 Channel 2 Busy */ + uint32_t CHBUSY3:1; /*!< bit: 11 Channel 3 Busy */ + uint32_t CHBUSY4:1; /*!< bit: 12 Channel 4 Busy */ + uint32_t CHBUSY5:1; /*!< bit: 13 Channel 5 Busy */ + uint32_t CHBUSY6:1; /*!< bit: 14 Channel 6 Busy */ + uint32_t CHBUSY7:1; /*!< bit: 15 Channel 7 Busy */ + uint32_t USRRDY8:1; /*!< bit: 16 Channel 8 User Ready */ + uint32_t USRRDY9:1; /*!< bit: 17 Channel 9 User Ready */ + uint32_t USRRDY10:1; /*!< bit: 18 Channel 10 User Ready */ + uint32_t USRRDY11:1; /*!< bit: 19 Channel 11 User Ready */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t CHBUSY8:1; /*!< bit: 24 Channel 8 Busy */ + uint32_t CHBUSY9:1; /*!< bit: 25 Channel 9 Busy */ + uint32_t CHBUSY10:1; /*!< bit: 26 Channel 10 Busy */ + uint32_t CHBUSY11:1; /*!< bit: 27 Channel 11 Busy */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t USRRDY:8; /*!< bit: 0.. 7 Channel x User Ready */ + uint32_t CHBUSY:8; /*!< bit: 8..15 Channel x Busy */ + uint32_t USRRDYp8:4; /*!< bit: 16..19 Channel x+8 User Ready */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t CHBUSYp8:4; /*!< bit: 24..27 Channel x+8 Busy */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} EVSYS_CHSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EVSYS_CHSTATUS_OFFSET 0x0C /**< \brief (EVSYS_CHSTATUS offset) Channel Status */ +#define EVSYS_CHSTATUS_RESETVALUE 0x000F00FF /**< \brief (EVSYS_CHSTATUS reset_value) Channel Status */ + +#define EVSYS_CHSTATUS_USRRDY0_Pos 0 /**< \brief (EVSYS_CHSTATUS) Channel 0 User Ready */ +#define EVSYS_CHSTATUS_USRRDY0 (1 << EVSYS_CHSTATUS_USRRDY0_Pos) +#define EVSYS_CHSTATUS_USRRDY1_Pos 1 /**< \brief (EVSYS_CHSTATUS) Channel 1 User Ready */ +#define EVSYS_CHSTATUS_USRRDY1 (1 << EVSYS_CHSTATUS_USRRDY1_Pos) +#define EVSYS_CHSTATUS_USRRDY2_Pos 2 /**< \brief (EVSYS_CHSTATUS) Channel 2 User Ready */ +#define EVSYS_CHSTATUS_USRRDY2 (1 << EVSYS_CHSTATUS_USRRDY2_Pos) +#define EVSYS_CHSTATUS_USRRDY3_Pos 3 /**< \brief (EVSYS_CHSTATUS) Channel 3 User Ready */ +#define EVSYS_CHSTATUS_USRRDY3 (1 << EVSYS_CHSTATUS_USRRDY3_Pos) +#define EVSYS_CHSTATUS_USRRDY4_Pos 4 /**< \brief (EVSYS_CHSTATUS) Channel 4 User Ready */ +#define EVSYS_CHSTATUS_USRRDY4 (1 << EVSYS_CHSTATUS_USRRDY4_Pos) +#define EVSYS_CHSTATUS_USRRDY5_Pos 5 /**< \brief (EVSYS_CHSTATUS) Channel 5 User Ready */ +#define EVSYS_CHSTATUS_USRRDY5 (1 << EVSYS_CHSTATUS_USRRDY5_Pos) +#define EVSYS_CHSTATUS_USRRDY6_Pos 6 /**< \brief (EVSYS_CHSTATUS) Channel 6 User Ready */ +#define EVSYS_CHSTATUS_USRRDY6 (1 << EVSYS_CHSTATUS_USRRDY6_Pos) +#define EVSYS_CHSTATUS_USRRDY7_Pos 7 /**< \brief (EVSYS_CHSTATUS) Channel 7 User Ready */ +#define EVSYS_CHSTATUS_USRRDY7 (1 << EVSYS_CHSTATUS_USRRDY7_Pos) +#define EVSYS_CHSTATUS_USRRDY_Pos 0 /**< \brief (EVSYS_CHSTATUS) Channel x User Ready */ +#define EVSYS_CHSTATUS_USRRDY_Msk (0xFFu << EVSYS_CHSTATUS_USRRDY_Pos) +#define EVSYS_CHSTATUS_USRRDY(value) ((EVSYS_CHSTATUS_USRRDY_Msk & ((value) << EVSYS_CHSTATUS_USRRDY_Pos))) +#define EVSYS_CHSTATUS_CHBUSY0_Pos 8 /**< \brief (EVSYS_CHSTATUS) Channel 0 Busy */ +#define EVSYS_CHSTATUS_CHBUSY0 (1 << EVSYS_CHSTATUS_CHBUSY0_Pos) +#define EVSYS_CHSTATUS_CHBUSY1_Pos 9 /**< \brief (EVSYS_CHSTATUS) Channel 1 Busy */ +#define EVSYS_CHSTATUS_CHBUSY1 (1 << EVSYS_CHSTATUS_CHBUSY1_Pos) +#define EVSYS_CHSTATUS_CHBUSY2_Pos 10 /**< \brief (EVSYS_CHSTATUS) Channel 2 Busy */ +#define EVSYS_CHSTATUS_CHBUSY2 (1 << EVSYS_CHSTATUS_CHBUSY2_Pos) +#define EVSYS_CHSTATUS_CHBUSY3_Pos 11 /**< \brief (EVSYS_CHSTATUS) Channel 3 Busy */ +#define EVSYS_CHSTATUS_CHBUSY3 (1 << EVSYS_CHSTATUS_CHBUSY3_Pos) +#define EVSYS_CHSTATUS_CHBUSY4_Pos 12 /**< \brief (EVSYS_CHSTATUS) Channel 4 Busy */ +#define EVSYS_CHSTATUS_CHBUSY4 (1 << EVSYS_CHSTATUS_CHBUSY4_Pos) +#define EVSYS_CHSTATUS_CHBUSY5_Pos 13 /**< \brief (EVSYS_CHSTATUS) Channel 5 Busy */ +#define EVSYS_CHSTATUS_CHBUSY5 (1 << EVSYS_CHSTATUS_CHBUSY5_Pos) +#define EVSYS_CHSTATUS_CHBUSY6_Pos 14 /**< \brief (EVSYS_CHSTATUS) Channel 6 Busy */ +#define EVSYS_CHSTATUS_CHBUSY6 (1 << EVSYS_CHSTATUS_CHBUSY6_Pos) +#define EVSYS_CHSTATUS_CHBUSY7_Pos 15 /**< \brief (EVSYS_CHSTATUS) Channel 7 Busy */ +#define EVSYS_CHSTATUS_CHBUSY7 (1 << EVSYS_CHSTATUS_CHBUSY7_Pos) +#define EVSYS_CHSTATUS_CHBUSY_Pos 8 /**< \brief (EVSYS_CHSTATUS) Channel x Busy */ +#define EVSYS_CHSTATUS_CHBUSY_Msk (0xFFu << EVSYS_CHSTATUS_CHBUSY_Pos) +#define EVSYS_CHSTATUS_CHBUSY(value) ((EVSYS_CHSTATUS_CHBUSY_Msk & ((value) << EVSYS_CHSTATUS_CHBUSY_Pos))) +#define EVSYS_CHSTATUS_USRRDY8_Pos 16 /**< \brief (EVSYS_CHSTATUS) Channel 8 User Ready */ +#define EVSYS_CHSTATUS_USRRDY8 (1 << EVSYS_CHSTATUS_USRRDY8_Pos) +#define EVSYS_CHSTATUS_USRRDY9_Pos 17 /**< \brief (EVSYS_CHSTATUS) Channel 9 User Ready */ +#define EVSYS_CHSTATUS_USRRDY9 (1 << EVSYS_CHSTATUS_USRRDY9_Pos) +#define EVSYS_CHSTATUS_USRRDY10_Pos 18 /**< \brief (EVSYS_CHSTATUS) Channel 10 User Ready */ +#define EVSYS_CHSTATUS_USRRDY10 (1 << EVSYS_CHSTATUS_USRRDY10_Pos) +#define EVSYS_CHSTATUS_USRRDY11_Pos 19 /**< \brief (EVSYS_CHSTATUS) Channel 11 User Ready */ +#define EVSYS_CHSTATUS_USRRDY11 (1 << EVSYS_CHSTATUS_USRRDY11_Pos) +#define EVSYS_CHSTATUS_USRRDYp8_Pos 16 /**< \brief (EVSYS_CHSTATUS) Channel x+8 User Ready */ +#define EVSYS_CHSTATUS_USRRDYp8_Msk (0xFu << EVSYS_CHSTATUS_USRRDYp8_Pos) +#define EVSYS_CHSTATUS_USRRDYp8(value) ((EVSYS_CHSTATUS_USRRDYp8_Msk & ((value) << EVSYS_CHSTATUS_USRRDYp8_Pos))) +#define EVSYS_CHSTATUS_CHBUSY8_Pos 24 /**< \brief (EVSYS_CHSTATUS) Channel 8 Busy */ +#define EVSYS_CHSTATUS_CHBUSY8 (1 << EVSYS_CHSTATUS_CHBUSY8_Pos) +#define EVSYS_CHSTATUS_CHBUSY9_Pos 25 /**< \brief (EVSYS_CHSTATUS) Channel 9 Busy */ +#define EVSYS_CHSTATUS_CHBUSY9 (1 << EVSYS_CHSTATUS_CHBUSY9_Pos) +#define EVSYS_CHSTATUS_CHBUSY10_Pos 26 /**< \brief (EVSYS_CHSTATUS) Channel 10 Busy */ +#define EVSYS_CHSTATUS_CHBUSY10 (1 << EVSYS_CHSTATUS_CHBUSY10_Pos) +#define EVSYS_CHSTATUS_CHBUSY11_Pos 27 /**< \brief (EVSYS_CHSTATUS) Channel 11 Busy */ +#define EVSYS_CHSTATUS_CHBUSY11 (1 << EVSYS_CHSTATUS_CHBUSY11_Pos) +#define EVSYS_CHSTATUS_CHBUSYp8_Pos 24 /**< \brief (EVSYS_CHSTATUS) Channel x+8 Busy */ +#define EVSYS_CHSTATUS_CHBUSYp8_Msk (0xFu << EVSYS_CHSTATUS_CHBUSYp8_Pos) +#define EVSYS_CHSTATUS_CHBUSYp8(value) ((EVSYS_CHSTATUS_CHBUSYp8_Msk & ((value) << EVSYS_CHSTATUS_CHBUSYp8_Pos))) +#define EVSYS_CHSTATUS_MASK 0x0F0FFFFFu /**< \brief (EVSYS_CHSTATUS) MASK Register */ + +/* -------- EVSYS_INTENCLR : (EVSYS Offset: 0x10) (R/W 32) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OVR0:1; /*!< bit: 0 Channel 0 Overrun Interrupt Enable */ + uint32_t OVR1:1; /*!< bit: 1 Channel 1 Overrun Interrupt Enable */ + uint32_t OVR2:1; /*!< bit: 2 Channel 2 Overrun Interrupt Enable */ + uint32_t OVR3:1; /*!< bit: 3 Channel 3 Overrun Interrupt Enable */ + uint32_t OVR4:1; /*!< bit: 4 Channel 4 Overrun Interrupt Enable */ + uint32_t OVR5:1; /*!< bit: 5 Channel 5 Overrun Interrupt Enable */ + uint32_t OVR6:1; /*!< bit: 6 Channel 6 Overrun Interrupt Enable */ + uint32_t OVR7:1; /*!< bit: 7 Channel 7 Overrun Interrupt Enable */ + uint32_t EVD0:1; /*!< bit: 8 Channel 0 Event Detection Interrupt Enable */ + uint32_t EVD1:1; /*!< bit: 9 Channel 1 Event Detection Interrupt Enable */ + uint32_t EVD2:1; /*!< bit: 10 Channel 2 Event Detection Interrupt Enable */ + uint32_t EVD3:1; /*!< bit: 11 Channel 3 Event Detection Interrupt Enable */ + uint32_t EVD4:1; /*!< bit: 12 Channel 4 Event Detection Interrupt Enable */ + uint32_t EVD5:1; /*!< bit: 13 Channel 5 Event Detection Interrupt Enable */ + uint32_t EVD6:1; /*!< bit: 14 Channel 6 Event Detection Interrupt Enable */ + uint32_t EVD7:1; /*!< bit: 15 Channel 7 Event Detection Interrupt Enable */ + uint32_t OVR8:1; /*!< bit: 16 Channel 8 Overrun Interrupt Enable */ + uint32_t OVR9:1; /*!< bit: 17 Channel 9 Overrun Interrupt Enable */ + uint32_t OVR10:1; /*!< bit: 18 Channel 10 Overrun Interrupt Enable */ + uint32_t OVR11:1; /*!< bit: 19 Channel 11 Overrun Interrupt Enable */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t EVD8:1; /*!< bit: 24 Channel 8 Event Detection Interrupt Enable */ + uint32_t EVD9:1; /*!< bit: 25 Channel 9 Event Detection Interrupt Enable */ + uint32_t EVD10:1; /*!< bit: 26 Channel 10 Event Detection Interrupt Enable */ + uint32_t EVD11:1; /*!< bit: 27 Channel 11 Event Detection Interrupt Enable */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t OVR:8; /*!< bit: 0.. 7 Channel x Overrun Interrupt Enable */ + uint32_t EVD:8; /*!< bit: 8..15 Channel x Event Detection Interrupt Enable */ + uint32_t OVRp8:4; /*!< bit: 16..19 Channel x+8 Overrun Interrupt Enable */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t EVDp8:4; /*!< bit: 24..27 Channel x+8 Event Detection Interrupt Enable */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} EVSYS_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EVSYS_INTENCLR_OFFSET 0x10 /**< \brief (EVSYS_INTENCLR offset) Interrupt Enable Clear */ +#define EVSYS_INTENCLR_RESETVALUE 0x00000000 /**< \brief (EVSYS_INTENCLR reset_value) Interrupt Enable Clear */ + +#define EVSYS_INTENCLR_OVR0_Pos 0 /**< \brief (EVSYS_INTENCLR) Channel 0 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR0 (1 << EVSYS_INTENCLR_OVR0_Pos) +#define EVSYS_INTENCLR_OVR1_Pos 1 /**< \brief (EVSYS_INTENCLR) Channel 1 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR1 (1 << EVSYS_INTENCLR_OVR1_Pos) +#define EVSYS_INTENCLR_OVR2_Pos 2 /**< \brief (EVSYS_INTENCLR) Channel 2 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR2 (1 << EVSYS_INTENCLR_OVR2_Pos) +#define EVSYS_INTENCLR_OVR3_Pos 3 /**< \brief (EVSYS_INTENCLR) Channel 3 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR3 (1 << EVSYS_INTENCLR_OVR3_Pos) +#define EVSYS_INTENCLR_OVR4_Pos 4 /**< \brief (EVSYS_INTENCLR) Channel 4 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR4 (1 << EVSYS_INTENCLR_OVR4_Pos) +#define EVSYS_INTENCLR_OVR5_Pos 5 /**< \brief (EVSYS_INTENCLR) Channel 5 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR5 (1 << EVSYS_INTENCLR_OVR5_Pos) +#define EVSYS_INTENCLR_OVR6_Pos 6 /**< \brief (EVSYS_INTENCLR) Channel 6 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR6 (1 << EVSYS_INTENCLR_OVR6_Pos) +#define EVSYS_INTENCLR_OVR7_Pos 7 /**< \brief (EVSYS_INTENCLR) Channel 7 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR7 (1 << EVSYS_INTENCLR_OVR7_Pos) +#define EVSYS_INTENCLR_OVR_Pos 0 /**< \brief (EVSYS_INTENCLR) Channel x Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR_Msk (0xFFu << EVSYS_INTENCLR_OVR_Pos) +#define EVSYS_INTENCLR_OVR(value) ((EVSYS_INTENCLR_OVR_Msk & ((value) << EVSYS_INTENCLR_OVR_Pos))) +#define EVSYS_INTENCLR_EVD0_Pos 8 /**< \brief (EVSYS_INTENCLR) Channel 0 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD0 (1 << EVSYS_INTENCLR_EVD0_Pos) +#define EVSYS_INTENCLR_EVD1_Pos 9 /**< \brief (EVSYS_INTENCLR) Channel 1 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD1 (1 << EVSYS_INTENCLR_EVD1_Pos) +#define EVSYS_INTENCLR_EVD2_Pos 10 /**< \brief (EVSYS_INTENCLR) Channel 2 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD2 (1 << EVSYS_INTENCLR_EVD2_Pos) +#define EVSYS_INTENCLR_EVD3_Pos 11 /**< \brief (EVSYS_INTENCLR) Channel 3 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD3 (1 << EVSYS_INTENCLR_EVD3_Pos) +#define EVSYS_INTENCLR_EVD4_Pos 12 /**< \brief (EVSYS_INTENCLR) Channel 4 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD4 (1 << EVSYS_INTENCLR_EVD4_Pos) +#define EVSYS_INTENCLR_EVD5_Pos 13 /**< \brief (EVSYS_INTENCLR) Channel 5 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD5 (1 << EVSYS_INTENCLR_EVD5_Pos) +#define EVSYS_INTENCLR_EVD6_Pos 14 /**< \brief (EVSYS_INTENCLR) Channel 6 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD6 (1 << EVSYS_INTENCLR_EVD6_Pos) +#define EVSYS_INTENCLR_EVD7_Pos 15 /**< \brief (EVSYS_INTENCLR) Channel 7 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD7 (1 << EVSYS_INTENCLR_EVD7_Pos) +#define EVSYS_INTENCLR_EVD_Pos 8 /**< \brief (EVSYS_INTENCLR) Channel x Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD_Msk (0xFFu << EVSYS_INTENCLR_EVD_Pos) +#define EVSYS_INTENCLR_EVD(value) ((EVSYS_INTENCLR_EVD_Msk & ((value) << EVSYS_INTENCLR_EVD_Pos))) +#define EVSYS_INTENCLR_OVR8_Pos 16 /**< \brief (EVSYS_INTENCLR) Channel 8 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR8 (1 << EVSYS_INTENCLR_OVR8_Pos) +#define EVSYS_INTENCLR_OVR9_Pos 17 /**< \brief (EVSYS_INTENCLR) Channel 9 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR9 (1 << EVSYS_INTENCLR_OVR9_Pos) +#define EVSYS_INTENCLR_OVR10_Pos 18 /**< \brief (EVSYS_INTENCLR) Channel 10 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR10 (1 << EVSYS_INTENCLR_OVR10_Pos) +#define EVSYS_INTENCLR_OVR11_Pos 19 /**< \brief (EVSYS_INTENCLR) Channel 11 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR11 (1 << EVSYS_INTENCLR_OVR11_Pos) +#define EVSYS_INTENCLR_OVRp8_Pos 16 /**< \brief (EVSYS_INTENCLR) Channel x+8 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVRp8_Msk (0xFu << EVSYS_INTENCLR_OVRp8_Pos) +#define EVSYS_INTENCLR_OVRp8(value) ((EVSYS_INTENCLR_OVRp8_Msk & ((value) << EVSYS_INTENCLR_OVRp8_Pos))) +#define EVSYS_INTENCLR_EVD8_Pos 24 /**< \brief (EVSYS_INTENCLR) Channel 8 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD8 (1 << EVSYS_INTENCLR_EVD8_Pos) +#define EVSYS_INTENCLR_EVD9_Pos 25 /**< \brief (EVSYS_INTENCLR) Channel 9 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD9 (1 << EVSYS_INTENCLR_EVD9_Pos) +#define EVSYS_INTENCLR_EVD10_Pos 26 /**< \brief (EVSYS_INTENCLR) Channel 10 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD10 (1 << EVSYS_INTENCLR_EVD10_Pos) +#define EVSYS_INTENCLR_EVD11_Pos 27 /**< \brief (EVSYS_INTENCLR) Channel 11 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD11 (1 << EVSYS_INTENCLR_EVD11_Pos) +#define EVSYS_INTENCLR_EVDp8_Pos 24 /**< \brief (EVSYS_INTENCLR) Channel x+8 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVDp8_Msk (0xFu << EVSYS_INTENCLR_EVDp8_Pos) +#define EVSYS_INTENCLR_EVDp8(value) ((EVSYS_INTENCLR_EVDp8_Msk & ((value) << EVSYS_INTENCLR_EVDp8_Pos))) +#define EVSYS_INTENCLR_MASK 0x0F0FFFFFu /**< \brief (EVSYS_INTENCLR) MASK Register */ + +/* -------- EVSYS_INTENSET : (EVSYS Offset: 0x14) (R/W 32) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OVR0:1; /*!< bit: 0 Channel 0 Overrun Interrupt Enable */ + uint32_t OVR1:1; /*!< bit: 1 Channel 1 Overrun Interrupt Enable */ + uint32_t OVR2:1; /*!< bit: 2 Channel 2 Overrun Interrupt Enable */ + uint32_t OVR3:1; /*!< bit: 3 Channel 3 Overrun Interrupt Enable */ + uint32_t OVR4:1; /*!< bit: 4 Channel 4 Overrun Interrupt Enable */ + uint32_t OVR5:1; /*!< bit: 5 Channel 5 Overrun Interrupt Enable */ + uint32_t OVR6:1; /*!< bit: 6 Channel 6 Overrun Interrupt Enable */ + uint32_t OVR7:1; /*!< bit: 7 Channel 7 Overrun Interrupt Enable */ + uint32_t EVD0:1; /*!< bit: 8 Channel 0 Event Detection Interrupt Enable */ + uint32_t EVD1:1; /*!< bit: 9 Channel 1 Event Detection Interrupt Enable */ + uint32_t EVD2:1; /*!< bit: 10 Channel 2 Event Detection Interrupt Enable */ + uint32_t EVD3:1; /*!< bit: 11 Channel 3 Event Detection Interrupt Enable */ + uint32_t EVD4:1; /*!< bit: 12 Channel 4 Event Detection Interrupt Enable */ + uint32_t EVD5:1; /*!< bit: 13 Channel 5 Event Detection Interrupt Enable */ + uint32_t EVD6:1; /*!< bit: 14 Channel 6 Event Detection Interrupt Enable */ + uint32_t EVD7:1; /*!< bit: 15 Channel 7 Event Detection Interrupt Enable */ + uint32_t OVR8:1; /*!< bit: 16 Channel 8 Overrun Interrupt Enable */ + uint32_t OVR9:1; /*!< bit: 17 Channel 9 Overrun Interrupt Enable */ + uint32_t OVR10:1; /*!< bit: 18 Channel 10 Overrun Interrupt Enable */ + uint32_t OVR11:1; /*!< bit: 19 Channel 11 Overrun Interrupt Enable */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t EVD8:1; /*!< bit: 24 Channel 8 Event Detection Interrupt Enable */ + uint32_t EVD9:1; /*!< bit: 25 Channel 9 Event Detection Interrupt Enable */ + uint32_t EVD10:1; /*!< bit: 26 Channel 10 Event Detection Interrupt Enable */ + uint32_t EVD11:1; /*!< bit: 27 Channel 11 Event Detection Interrupt Enable */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t OVR:8; /*!< bit: 0.. 7 Channel x Overrun Interrupt Enable */ + uint32_t EVD:8; /*!< bit: 8..15 Channel x Event Detection Interrupt Enable */ + uint32_t OVRp8:4; /*!< bit: 16..19 Channel x+8 Overrun Interrupt Enable */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t EVDp8:4; /*!< bit: 24..27 Channel x+8 Event Detection Interrupt Enable */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} EVSYS_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EVSYS_INTENSET_OFFSET 0x14 /**< \brief (EVSYS_INTENSET offset) Interrupt Enable Set */ +#define EVSYS_INTENSET_RESETVALUE 0x00000000 /**< \brief (EVSYS_INTENSET reset_value) Interrupt Enable Set */ + +#define EVSYS_INTENSET_OVR0_Pos 0 /**< \brief (EVSYS_INTENSET) Channel 0 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR0 (1 << EVSYS_INTENSET_OVR0_Pos) +#define EVSYS_INTENSET_OVR1_Pos 1 /**< \brief (EVSYS_INTENSET) Channel 1 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR1 (1 << EVSYS_INTENSET_OVR1_Pos) +#define EVSYS_INTENSET_OVR2_Pos 2 /**< \brief (EVSYS_INTENSET) Channel 2 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR2 (1 << EVSYS_INTENSET_OVR2_Pos) +#define EVSYS_INTENSET_OVR3_Pos 3 /**< \brief (EVSYS_INTENSET) Channel 3 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR3 (1 << EVSYS_INTENSET_OVR3_Pos) +#define EVSYS_INTENSET_OVR4_Pos 4 /**< \brief (EVSYS_INTENSET) Channel 4 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR4 (1 << EVSYS_INTENSET_OVR4_Pos) +#define EVSYS_INTENSET_OVR5_Pos 5 /**< \brief (EVSYS_INTENSET) Channel 5 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR5 (1 << EVSYS_INTENSET_OVR5_Pos) +#define EVSYS_INTENSET_OVR6_Pos 6 /**< \brief (EVSYS_INTENSET) Channel 6 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR6 (1 << EVSYS_INTENSET_OVR6_Pos) +#define EVSYS_INTENSET_OVR7_Pos 7 /**< \brief (EVSYS_INTENSET) Channel 7 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR7 (1 << EVSYS_INTENSET_OVR7_Pos) +#define EVSYS_INTENSET_OVR_Pos 0 /**< \brief (EVSYS_INTENSET) Channel x Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR_Msk (0xFFu << EVSYS_INTENSET_OVR_Pos) +#define EVSYS_INTENSET_OVR(value) ((EVSYS_INTENSET_OVR_Msk & ((value) << EVSYS_INTENSET_OVR_Pos))) +#define EVSYS_INTENSET_EVD0_Pos 8 /**< \brief (EVSYS_INTENSET) Channel 0 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD0 (1 << EVSYS_INTENSET_EVD0_Pos) +#define EVSYS_INTENSET_EVD1_Pos 9 /**< \brief (EVSYS_INTENSET) Channel 1 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD1 (1 << EVSYS_INTENSET_EVD1_Pos) +#define EVSYS_INTENSET_EVD2_Pos 10 /**< \brief (EVSYS_INTENSET) Channel 2 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD2 (1 << EVSYS_INTENSET_EVD2_Pos) +#define EVSYS_INTENSET_EVD3_Pos 11 /**< \brief (EVSYS_INTENSET) Channel 3 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD3 (1 << EVSYS_INTENSET_EVD3_Pos) +#define EVSYS_INTENSET_EVD4_Pos 12 /**< \brief (EVSYS_INTENSET) Channel 4 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD4 (1 << EVSYS_INTENSET_EVD4_Pos) +#define EVSYS_INTENSET_EVD5_Pos 13 /**< \brief (EVSYS_INTENSET) Channel 5 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD5 (1 << EVSYS_INTENSET_EVD5_Pos) +#define EVSYS_INTENSET_EVD6_Pos 14 /**< \brief (EVSYS_INTENSET) Channel 6 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD6 (1 << EVSYS_INTENSET_EVD6_Pos) +#define EVSYS_INTENSET_EVD7_Pos 15 /**< \brief (EVSYS_INTENSET) Channel 7 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD7 (1 << EVSYS_INTENSET_EVD7_Pos) +#define EVSYS_INTENSET_EVD_Pos 8 /**< \brief (EVSYS_INTENSET) Channel x Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD_Msk (0xFFu << EVSYS_INTENSET_EVD_Pos) +#define EVSYS_INTENSET_EVD(value) ((EVSYS_INTENSET_EVD_Msk & ((value) << EVSYS_INTENSET_EVD_Pos))) +#define EVSYS_INTENSET_OVR8_Pos 16 /**< \brief (EVSYS_INTENSET) Channel 8 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR8 (1 << EVSYS_INTENSET_OVR8_Pos) +#define EVSYS_INTENSET_OVR9_Pos 17 /**< \brief (EVSYS_INTENSET) Channel 9 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR9 (1 << EVSYS_INTENSET_OVR9_Pos) +#define EVSYS_INTENSET_OVR10_Pos 18 /**< \brief (EVSYS_INTENSET) Channel 10 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR10 (1 << EVSYS_INTENSET_OVR10_Pos) +#define EVSYS_INTENSET_OVR11_Pos 19 /**< \brief (EVSYS_INTENSET) Channel 11 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR11 (1 << EVSYS_INTENSET_OVR11_Pos) +#define EVSYS_INTENSET_OVRp8_Pos 16 /**< \brief (EVSYS_INTENSET) Channel x+8 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVRp8_Msk (0xFu << EVSYS_INTENSET_OVRp8_Pos) +#define EVSYS_INTENSET_OVRp8(value) ((EVSYS_INTENSET_OVRp8_Msk & ((value) << EVSYS_INTENSET_OVRp8_Pos))) +#define EVSYS_INTENSET_EVD8_Pos 24 /**< \brief (EVSYS_INTENSET) Channel 8 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD8 (1 << EVSYS_INTENSET_EVD8_Pos) +#define EVSYS_INTENSET_EVD9_Pos 25 /**< \brief (EVSYS_INTENSET) Channel 9 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD9 (1 << EVSYS_INTENSET_EVD9_Pos) +#define EVSYS_INTENSET_EVD10_Pos 26 /**< \brief (EVSYS_INTENSET) Channel 10 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD10 (1 << EVSYS_INTENSET_EVD10_Pos) +#define EVSYS_INTENSET_EVD11_Pos 27 /**< \brief (EVSYS_INTENSET) Channel 11 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD11 (1 << EVSYS_INTENSET_EVD11_Pos) +#define EVSYS_INTENSET_EVDp8_Pos 24 /**< \brief (EVSYS_INTENSET) Channel x+8 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVDp8_Msk (0xFu << EVSYS_INTENSET_EVDp8_Pos) +#define EVSYS_INTENSET_EVDp8(value) ((EVSYS_INTENSET_EVDp8_Msk & ((value) << EVSYS_INTENSET_EVDp8_Pos))) +#define EVSYS_INTENSET_MASK 0x0F0FFFFFu /**< \brief (EVSYS_INTENSET) MASK Register */ + +/* -------- EVSYS_INTFLAG : (EVSYS Offset: 0x18) (R/W 32) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OVR0:1; /*!< bit: 0 Channel 0 Overrun */ + uint32_t OVR1:1; /*!< bit: 1 Channel 1 Overrun */ + uint32_t OVR2:1; /*!< bit: 2 Channel 2 Overrun */ + uint32_t OVR3:1; /*!< bit: 3 Channel 3 Overrun */ + uint32_t OVR4:1; /*!< bit: 4 Channel 4 Overrun */ + uint32_t OVR5:1; /*!< bit: 5 Channel 5 Overrun */ + uint32_t OVR6:1; /*!< bit: 6 Channel 6 Overrun */ + uint32_t OVR7:1; /*!< bit: 7 Channel 7 Overrun */ + uint32_t EVD0:1; /*!< bit: 8 Channel 0 Event Detection */ + uint32_t EVD1:1; /*!< bit: 9 Channel 1 Event Detection */ + uint32_t EVD2:1; /*!< bit: 10 Channel 2 Event Detection */ + uint32_t EVD3:1; /*!< bit: 11 Channel 3 Event Detection */ + uint32_t EVD4:1; /*!< bit: 12 Channel 4 Event Detection */ + uint32_t EVD5:1; /*!< bit: 13 Channel 5 Event Detection */ + uint32_t EVD6:1; /*!< bit: 14 Channel 6 Event Detection */ + uint32_t EVD7:1; /*!< bit: 15 Channel 7 Event Detection */ + uint32_t OVR8:1; /*!< bit: 16 Channel 8 Overrun */ + uint32_t OVR9:1; /*!< bit: 17 Channel 9 Overrun */ + uint32_t OVR10:1; /*!< bit: 18 Channel 10 Overrun */ + uint32_t OVR11:1; /*!< bit: 19 Channel 11 Overrun */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t EVD8:1; /*!< bit: 24 Channel 8 Event Detection */ + uint32_t EVD9:1; /*!< bit: 25 Channel 9 Event Detection */ + uint32_t EVD10:1; /*!< bit: 26 Channel 10 Event Detection */ + uint32_t EVD11:1; /*!< bit: 27 Channel 11 Event Detection */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t OVR:8; /*!< bit: 0.. 7 Channel x Overrun */ + uint32_t EVD:8; /*!< bit: 8..15 Channel x Event Detection */ + uint32_t OVRp8:4; /*!< bit: 16..19 Channel x+8 Overrun */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t EVDp8:4; /*!< bit: 24..27 Channel x+8 Event Detection */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} EVSYS_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EVSYS_INTFLAG_OFFSET 0x18 /**< \brief (EVSYS_INTFLAG offset) Interrupt Flag Status and Clear */ +#define EVSYS_INTFLAG_RESETVALUE 0x00000000 /**< \brief (EVSYS_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define EVSYS_INTFLAG_OVR0_Pos 0 /**< \brief (EVSYS_INTFLAG) Channel 0 Overrun */ +#define EVSYS_INTFLAG_OVR0 (1 << EVSYS_INTFLAG_OVR0_Pos) +#define EVSYS_INTFLAG_OVR1_Pos 1 /**< \brief (EVSYS_INTFLAG) Channel 1 Overrun */ +#define EVSYS_INTFLAG_OVR1 (1 << EVSYS_INTFLAG_OVR1_Pos) +#define EVSYS_INTFLAG_OVR2_Pos 2 /**< \brief (EVSYS_INTFLAG) Channel 2 Overrun */ +#define EVSYS_INTFLAG_OVR2 (1 << EVSYS_INTFLAG_OVR2_Pos) +#define EVSYS_INTFLAG_OVR3_Pos 3 /**< \brief (EVSYS_INTFLAG) Channel 3 Overrun */ +#define EVSYS_INTFLAG_OVR3 (1 << EVSYS_INTFLAG_OVR3_Pos) +#define EVSYS_INTFLAG_OVR4_Pos 4 /**< \brief (EVSYS_INTFLAG) Channel 4 Overrun */ +#define EVSYS_INTFLAG_OVR4 (1 << EVSYS_INTFLAG_OVR4_Pos) +#define EVSYS_INTFLAG_OVR5_Pos 5 /**< \brief (EVSYS_INTFLAG) Channel 5 Overrun */ +#define EVSYS_INTFLAG_OVR5 (1 << EVSYS_INTFLAG_OVR5_Pos) +#define EVSYS_INTFLAG_OVR6_Pos 6 /**< \brief (EVSYS_INTFLAG) Channel 6 Overrun */ +#define EVSYS_INTFLAG_OVR6 (1 << EVSYS_INTFLAG_OVR6_Pos) +#define EVSYS_INTFLAG_OVR7_Pos 7 /**< \brief (EVSYS_INTFLAG) Channel 7 Overrun */ +#define EVSYS_INTFLAG_OVR7 (1 << EVSYS_INTFLAG_OVR7_Pos) +#define EVSYS_INTFLAG_OVR_Pos 0 /**< \brief (EVSYS_INTFLAG) Channel x Overrun */ +#define EVSYS_INTFLAG_OVR_Msk (0xFFu << EVSYS_INTFLAG_OVR_Pos) +#define EVSYS_INTFLAG_OVR(value) ((EVSYS_INTFLAG_OVR_Msk & ((value) << EVSYS_INTFLAG_OVR_Pos))) +#define EVSYS_INTFLAG_EVD0_Pos 8 /**< \brief (EVSYS_INTFLAG) Channel 0 Event Detection */ +#define EVSYS_INTFLAG_EVD0 (1 << EVSYS_INTFLAG_EVD0_Pos) +#define EVSYS_INTFLAG_EVD1_Pos 9 /**< \brief (EVSYS_INTFLAG) Channel 1 Event Detection */ +#define EVSYS_INTFLAG_EVD1 (1 << EVSYS_INTFLAG_EVD1_Pos) +#define EVSYS_INTFLAG_EVD2_Pos 10 /**< \brief (EVSYS_INTFLAG) Channel 2 Event Detection */ +#define EVSYS_INTFLAG_EVD2 (1 << EVSYS_INTFLAG_EVD2_Pos) +#define EVSYS_INTFLAG_EVD3_Pos 11 /**< \brief (EVSYS_INTFLAG) Channel 3 Event Detection */ +#define EVSYS_INTFLAG_EVD3 (1 << EVSYS_INTFLAG_EVD3_Pos) +#define EVSYS_INTFLAG_EVD4_Pos 12 /**< \brief (EVSYS_INTFLAG) Channel 4 Event Detection */ +#define EVSYS_INTFLAG_EVD4 (1 << EVSYS_INTFLAG_EVD4_Pos) +#define EVSYS_INTFLAG_EVD5_Pos 13 /**< \brief (EVSYS_INTFLAG) Channel 5 Event Detection */ +#define EVSYS_INTFLAG_EVD5 (1 << EVSYS_INTFLAG_EVD5_Pos) +#define EVSYS_INTFLAG_EVD6_Pos 14 /**< \brief (EVSYS_INTFLAG) Channel 6 Event Detection */ +#define EVSYS_INTFLAG_EVD6 (1 << EVSYS_INTFLAG_EVD6_Pos) +#define EVSYS_INTFLAG_EVD7_Pos 15 /**< \brief (EVSYS_INTFLAG) Channel 7 Event Detection */ +#define EVSYS_INTFLAG_EVD7 (1 << EVSYS_INTFLAG_EVD7_Pos) +#define EVSYS_INTFLAG_EVD_Pos 8 /**< \brief (EVSYS_INTFLAG) Channel x Event Detection */ +#define EVSYS_INTFLAG_EVD_Msk (0xFFu << EVSYS_INTFLAG_EVD_Pos) +#define EVSYS_INTFLAG_EVD(value) ((EVSYS_INTFLAG_EVD_Msk & ((value) << EVSYS_INTFLAG_EVD_Pos))) +#define EVSYS_INTFLAG_OVR8_Pos 16 /**< \brief (EVSYS_INTFLAG) Channel 8 Overrun */ +#define EVSYS_INTFLAG_OVR8 (1 << EVSYS_INTFLAG_OVR8_Pos) +#define EVSYS_INTFLAG_OVR9_Pos 17 /**< \brief (EVSYS_INTFLAG) Channel 9 Overrun */ +#define EVSYS_INTFLAG_OVR9 (1 << EVSYS_INTFLAG_OVR9_Pos) +#define EVSYS_INTFLAG_OVR10_Pos 18 /**< \brief (EVSYS_INTFLAG) Channel 10 Overrun */ +#define EVSYS_INTFLAG_OVR10 (1 << EVSYS_INTFLAG_OVR10_Pos) +#define EVSYS_INTFLAG_OVR11_Pos 19 /**< \brief (EVSYS_INTFLAG) Channel 11 Overrun */ +#define EVSYS_INTFLAG_OVR11 (1 << EVSYS_INTFLAG_OVR11_Pos) +#define EVSYS_INTFLAG_OVRp8_Pos 16 /**< \brief (EVSYS_INTFLAG) Channel x+8 Overrun */ +#define EVSYS_INTFLAG_OVRp8_Msk (0xFu << EVSYS_INTFLAG_OVRp8_Pos) +#define EVSYS_INTFLAG_OVRp8(value) ((EVSYS_INTFLAG_OVRp8_Msk & ((value) << EVSYS_INTFLAG_OVRp8_Pos))) +#define EVSYS_INTFLAG_EVD8_Pos 24 /**< \brief (EVSYS_INTFLAG) Channel 8 Event Detection */ +#define EVSYS_INTFLAG_EVD8 (1 << EVSYS_INTFLAG_EVD8_Pos) +#define EVSYS_INTFLAG_EVD9_Pos 25 /**< \brief (EVSYS_INTFLAG) Channel 9 Event Detection */ +#define EVSYS_INTFLAG_EVD9 (1 << EVSYS_INTFLAG_EVD9_Pos) +#define EVSYS_INTFLAG_EVD10_Pos 26 /**< \brief (EVSYS_INTFLAG) Channel 10 Event Detection */ +#define EVSYS_INTFLAG_EVD10 (1 << EVSYS_INTFLAG_EVD10_Pos) +#define EVSYS_INTFLAG_EVD11_Pos 27 /**< \brief (EVSYS_INTFLAG) Channel 11 Event Detection */ +#define EVSYS_INTFLAG_EVD11 (1 << EVSYS_INTFLAG_EVD11_Pos) +#define EVSYS_INTFLAG_EVDp8_Pos 24 /**< \brief (EVSYS_INTFLAG) Channel x+8 Event Detection */ +#define EVSYS_INTFLAG_EVDp8_Msk (0xFu << EVSYS_INTFLAG_EVDp8_Pos) +#define EVSYS_INTFLAG_EVDp8(value) ((EVSYS_INTFLAG_EVDp8_Msk & ((value) << EVSYS_INTFLAG_EVDp8_Pos))) +#define EVSYS_INTFLAG_MASK 0x0F0FFFFFu /**< \brief (EVSYS_INTFLAG) MASK Register */ + +/** \brief EVSYS hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __O EVSYS_CTRL_Type CTRL; /**< \brief Offset: 0x00 ( /W 8) Control */ + RoReg8 Reserved1[0x3]; + __IO EVSYS_CHANNEL_Type CHANNEL; /**< \brief Offset: 0x04 (R/W 32) Channel */ + __IO EVSYS_USER_Type USER; /**< \brief Offset: 0x08 (R/W 16) User Multiplexer */ + RoReg8 Reserved2[0x2]; + __I EVSYS_CHSTATUS_Type CHSTATUS; /**< \brief Offset: 0x0C (R/ 32) Channel Status */ + __IO EVSYS_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x10 (R/W 32) Interrupt Enable Clear */ + __IO EVSYS_INTENSET_Type INTENSET; /**< \brief Offset: 0x14 (R/W 32) Interrupt Enable Set */ + __IO EVSYS_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x18 (R/W 32) Interrupt Flag Status and Clear */ +} Evsys; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_EVSYS_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/gclk.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/gclk.h new file mode 100644 index 0000000..e3dce07 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/gclk.h @@ -0,0 +1,234 @@ +/** + * \file + * + * \brief Component description for GCLK + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_GCLK_COMPONENT_ +#define _SAMD21_GCLK_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR GCLK */ +/* ========================================================================== */ +/** \addtogroup SAMD21_GCLK Generic Clock Generator */ +/*@{*/ + +#define GCLK_U2102 +#define REV_GCLK 0x210 + +/* -------- GCLK_CTRL : (GCLK Offset: 0x0) (R/W 8) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} GCLK_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define GCLK_CTRL_OFFSET 0x0 /**< \brief (GCLK_CTRL offset) Control */ +#define GCLK_CTRL_RESETVALUE 0x00 /**< \brief (GCLK_CTRL reset_value) Control */ + +#define GCLK_CTRL_SWRST_Pos 0 /**< \brief (GCLK_CTRL) Software Reset */ +#define GCLK_CTRL_SWRST (0x1u << GCLK_CTRL_SWRST_Pos) +#define GCLK_CTRL_MASK 0x01u /**< \brief (GCLK_CTRL) MASK Register */ + +/* -------- GCLK_STATUS : (GCLK Offset: 0x1) (R/ 8) Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :7; /*!< bit: 0.. 6 Reserved */ + uint8_t SYNCBUSY:1; /*!< bit: 7 Synchronization Busy Status */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} GCLK_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define GCLK_STATUS_OFFSET 0x1 /**< \brief (GCLK_STATUS offset) Status */ +#define GCLK_STATUS_RESETVALUE 0x00 /**< \brief (GCLK_STATUS reset_value) Status */ + +#define GCLK_STATUS_SYNCBUSY_Pos 7 /**< \brief (GCLK_STATUS) Synchronization Busy Status */ +#define GCLK_STATUS_SYNCBUSY (0x1u << GCLK_STATUS_SYNCBUSY_Pos) +#define GCLK_STATUS_MASK 0x80u /**< \brief (GCLK_STATUS) MASK Register */ + +/* -------- GCLK_CLKCTRL : (GCLK Offset: 0x2) (R/W 16) Generic Clock Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t ID:6; /*!< bit: 0.. 5 Generic Clock Selection ID */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t GEN:4; /*!< bit: 8..11 Generic Clock Generator */ + uint16_t :2; /*!< bit: 12..13 Reserved */ + uint16_t CLKEN:1; /*!< bit: 14 Clock Enable */ + uint16_t WRTLOCK:1; /*!< bit: 15 Write Lock */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} GCLK_CLKCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define GCLK_CLKCTRL_OFFSET 0x2 /**< \brief (GCLK_CLKCTRL offset) Generic Clock Control */ +#define GCLK_CLKCTRL_RESETVALUE 0x0000 /**< \brief (GCLK_CLKCTRL reset_value) Generic Clock Control */ + +#define GCLK_CLKCTRL_ID_Pos 0 /**< \brief (GCLK_CLKCTRL) Generic Clock Selection ID */ +#define GCLK_CLKCTRL_ID_Msk (0x3Fu << GCLK_CLKCTRL_ID_Pos) +#define GCLK_CLKCTRL_ID(value) ((GCLK_CLKCTRL_ID_Msk & ((value) << GCLK_CLKCTRL_ID_Pos))) +#define GCLK_CLKCTRL_GEN_Pos 8 /**< \brief (GCLK_CLKCTRL) Generic Clock Generator */ +#define GCLK_CLKCTRL_GEN_Msk (0xFu << GCLK_CLKCTRL_GEN_Pos) +#define GCLK_CLKCTRL_GEN(value) ((GCLK_CLKCTRL_GEN_Msk & ((value) << GCLK_CLKCTRL_GEN_Pos))) +#define GCLK_CLKCTRL_GEN_GCLK0_Val 0x0u /**< \brief (GCLK_CLKCTRL) Generic clock generator 0 */ +#define GCLK_CLKCTRL_GEN_GCLK1_Val 0x1u /**< \brief (GCLK_CLKCTRL) Generic clock generator 1 */ +#define GCLK_CLKCTRL_GEN_GCLK2_Val 0x2u /**< \brief (GCLK_CLKCTRL) Generic clock generator 2 */ +#define GCLK_CLKCTRL_GEN_GCLK3_Val 0x3u /**< \brief (GCLK_CLKCTRL) Generic clock generator 3 */ +#define GCLK_CLKCTRL_GEN_GCLK4_Val 0x4u /**< \brief (GCLK_CLKCTRL) Generic clock generator 4 */ +#define GCLK_CLKCTRL_GEN_GCLK5_Val 0x5u /**< \brief (GCLK_CLKCTRL) Generic clock generator 5 */ +#define GCLK_CLKCTRL_GEN_GCLK6_Val 0x6u /**< \brief (GCLK_CLKCTRL) Generic clock generator 6 */ +#define GCLK_CLKCTRL_GEN_GCLK7_Val 0x7u /**< \brief (GCLK_CLKCTRL) Generic clock generator 7 */ +#define GCLK_CLKCTRL_GEN_GCLK0 (GCLK_CLKCTRL_GEN_GCLK0_Val << GCLK_CLKCTRL_GEN_Pos) +#define GCLK_CLKCTRL_GEN_GCLK1 (GCLK_CLKCTRL_GEN_GCLK1_Val << GCLK_CLKCTRL_GEN_Pos) +#define GCLK_CLKCTRL_GEN_GCLK2 (GCLK_CLKCTRL_GEN_GCLK2_Val << GCLK_CLKCTRL_GEN_Pos) +#define GCLK_CLKCTRL_GEN_GCLK3 (GCLK_CLKCTRL_GEN_GCLK3_Val << GCLK_CLKCTRL_GEN_Pos) +#define GCLK_CLKCTRL_GEN_GCLK4 (GCLK_CLKCTRL_GEN_GCLK4_Val << GCLK_CLKCTRL_GEN_Pos) +#define GCLK_CLKCTRL_GEN_GCLK5 (GCLK_CLKCTRL_GEN_GCLK5_Val << GCLK_CLKCTRL_GEN_Pos) +#define GCLK_CLKCTRL_GEN_GCLK6 (GCLK_CLKCTRL_GEN_GCLK6_Val << GCLK_CLKCTRL_GEN_Pos) +#define GCLK_CLKCTRL_GEN_GCLK7 (GCLK_CLKCTRL_GEN_GCLK7_Val << GCLK_CLKCTRL_GEN_Pos) +#define GCLK_CLKCTRL_CLKEN_Pos 14 /**< \brief (GCLK_CLKCTRL) Clock Enable */ +#define GCLK_CLKCTRL_CLKEN (0x1u << GCLK_CLKCTRL_CLKEN_Pos) +#define GCLK_CLKCTRL_WRTLOCK_Pos 15 /**< \brief (GCLK_CLKCTRL) Write Lock */ +#define GCLK_CLKCTRL_WRTLOCK (0x1u << GCLK_CLKCTRL_WRTLOCK_Pos) +#define GCLK_CLKCTRL_MASK 0xCF3Fu /**< \brief (GCLK_CLKCTRL) MASK Register */ + +/* -------- GCLK_GENCTRL : (GCLK Offset: 0x4) (R/W 32) Generic Clock Generator Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t ID:4; /*!< bit: 0.. 3 Generic Clock Generator Selection */ + uint32_t :4; /*!< bit: 4.. 7 Reserved */ + uint32_t SRC:5; /*!< bit: 8..12 Source Select */ + uint32_t :3; /*!< bit: 13..15 Reserved */ + uint32_t GENEN:1; /*!< bit: 16 Generic Clock Generator Enable */ + uint32_t IDC:1; /*!< bit: 17 Improve Duty Cycle */ + uint32_t OOV:1; /*!< bit: 18 Output Off Value */ + uint32_t OE:1; /*!< bit: 19 Output Enable */ + uint32_t DIVSEL:1; /*!< bit: 20 Divide Selection */ + uint32_t RUNSTDBY:1; /*!< bit: 21 Run in Standby */ + uint32_t :10; /*!< bit: 22..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} GCLK_GENCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define GCLK_GENCTRL_OFFSET 0x4 /**< \brief (GCLK_GENCTRL offset) Generic Clock Generator Control */ +#define GCLK_GENCTRL_RESETVALUE 0x00000000 /**< \brief (GCLK_GENCTRL reset_value) Generic Clock Generator Control */ + +#define GCLK_GENCTRL_ID_Pos 0 /**< \brief (GCLK_GENCTRL) Generic Clock Generator Selection */ +#define GCLK_GENCTRL_ID_Msk (0xFu << GCLK_GENCTRL_ID_Pos) +#define GCLK_GENCTRL_ID(value) ((GCLK_GENCTRL_ID_Msk & ((value) << GCLK_GENCTRL_ID_Pos))) +#define GCLK_GENCTRL_SRC_Pos 8 /**< \brief (GCLK_GENCTRL) Source Select */ +#define GCLK_GENCTRL_SRC_Msk (0x1Fu << GCLK_GENCTRL_SRC_Pos) +#define GCLK_GENCTRL_SRC(value) ((GCLK_GENCTRL_SRC_Msk & ((value) << GCLK_GENCTRL_SRC_Pos))) +#define GCLK_GENCTRL_SRC_XOSC_Val 0x0u /**< \brief (GCLK_GENCTRL) XOSC oscillator output */ +#define GCLK_GENCTRL_SRC_GCLKIN_Val 0x1u /**< \brief (GCLK_GENCTRL) Generator input pad */ +#define GCLK_GENCTRL_SRC_GCLKGEN1_Val 0x2u /**< \brief (GCLK_GENCTRL) Generic clock generator 1 output */ +#define GCLK_GENCTRL_SRC_OSCULP32K_Val 0x3u /**< \brief (GCLK_GENCTRL) OSCULP32K oscillator output */ +#define GCLK_GENCTRL_SRC_OSC32K_Val 0x4u /**< \brief (GCLK_GENCTRL) OSC32K oscillator output */ +#define GCLK_GENCTRL_SRC_XOSC32K_Val 0x5u /**< \brief (GCLK_GENCTRL) XOSC32K oscillator output */ +#define GCLK_GENCTRL_SRC_OSC8M_Val 0x6u /**< \brief (GCLK_GENCTRL) OSC8M oscillator output */ +#define GCLK_GENCTRL_SRC_DFLL48M_Val 0x7u /**< \brief (GCLK_GENCTRL) DFLL48M output */ +#define GCLK_GENCTRL_SRC_XOSC (GCLK_GENCTRL_SRC_XOSC_Val << GCLK_GENCTRL_SRC_Pos) +#define GCLK_GENCTRL_SRC_GCLKIN (GCLK_GENCTRL_SRC_GCLKIN_Val << GCLK_GENCTRL_SRC_Pos) +#define GCLK_GENCTRL_SRC_GCLKGEN1 (GCLK_GENCTRL_SRC_GCLKGEN1_Val << GCLK_GENCTRL_SRC_Pos) +#define GCLK_GENCTRL_SRC_OSCULP32K (GCLK_GENCTRL_SRC_OSCULP32K_Val << GCLK_GENCTRL_SRC_Pos) +#define GCLK_GENCTRL_SRC_OSC32K (GCLK_GENCTRL_SRC_OSC32K_Val << GCLK_GENCTRL_SRC_Pos) +#define GCLK_GENCTRL_SRC_XOSC32K (GCLK_GENCTRL_SRC_XOSC32K_Val << GCLK_GENCTRL_SRC_Pos) +#define GCLK_GENCTRL_SRC_OSC8M (GCLK_GENCTRL_SRC_OSC8M_Val << GCLK_GENCTRL_SRC_Pos) +#define GCLK_GENCTRL_SRC_DFLL48M (GCLK_GENCTRL_SRC_DFLL48M_Val << GCLK_GENCTRL_SRC_Pos) +#define GCLK_GENCTRL_GENEN_Pos 16 /**< \brief (GCLK_GENCTRL) Generic Clock Generator Enable */ +#define GCLK_GENCTRL_GENEN (0x1u << GCLK_GENCTRL_GENEN_Pos) +#define GCLK_GENCTRL_IDC_Pos 17 /**< \brief (GCLK_GENCTRL) Improve Duty Cycle */ +#define GCLK_GENCTRL_IDC (0x1u << GCLK_GENCTRL_IDC_Pos) +#define GCLK_GENCTRL_OOV_Pos 18 /**< \brief (GCLK_GENCTRL) Output Off Value */ +#define GCLK_GENCTRL_OOV (0x1u << GCLK_GENCTRL_OOV_Pos) +#define GCLK_GENCTRL_OE_Pos 19 /**< \brief (GCLK_GENCTRL) Output Enable */ +#define GCLK_GENCTRL_OE (0x1u << GCLK_GENCTRL_OE_Pos) +#define GCLK_GENCTRL_DIVSEL_Pos 20 /**< \brief (GCLK_GENCTRL) Divide Selection */ +#define GCLK_GENCTRL_DIVSEL (0x1u << GCLK_GENCTRL_DIVSEL_Pos) +#define GCLK_GENCTRL_RUNSTDBY_Pos 21 /**< \brief (GCLK_GENCTRL) Run in Standby */ +#define GCLK_GENCTRL_RUNSTDBY (0x1u << GCLK_GENCTRL_RUNSTDBY_Pos) +#define GCLK_GENCTRL_MASK 0x003F1F0Fu /**< \brief (GCLK_GENCTRL) MASK Register */ + +/* -------- GCLK_GENDIV : (GCLK Offset: 0x8) (R/W 32) Generic Clock Generator Division -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t ID:4; /*!< bit: 0.. 3 Generic Clock Generator Selection */ + uint32_t :4; /*!< bit: 4.. 7 Reserved */ + uint32_t DIV:16; /*!< bit: 8..23 Division Factor */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} GCLK_GENDIV_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define GCLK_GENDIV_OFFSET 0x8 /**< \brief (GCLK_GENDIV offset) Generic Clock Generator Division */ +#define GCLK_GENDIV_RESETVALUE 0x00000000 /**< \brief (GCLK_GENDIV reset_value) Generic Clock Generator Division */ + +#define GCLK_GENDIV_ID_Pos 0 /**< \brief (GCLK_GENDIV) Generic Clock Generator Selection */ +#define GCLK_GENDIV_ID_Msk (0xFu << GCLK_GENDIV_ID_Pos) +#define GCLK_GENDIV_ID(value) ((GCLK_GENDIV_ID_Msk & ((value) << GCLK_GENDIV_ID_Pos))) +#define GCLK_GENDIV_DIV_Pos 8 /**< \brief (GCLK_GENDIV) Division Factor */ +#define GCLK_GENDIV_DIV_Msk (0xFFFFu << GCLK_GENDIV_DIV_Pos) +#define GCLK_GENDIV_DIV(value) ((GCLK_GENDIV_DIV_Msk & ((value) << GCLK_GENDIV_DIV_Pos))) +#define GCLK_GENDIV_MASK 0x00FFFF0Fu /**< \brief (GCLK_GENDIV) MASK Register */ + +/** \brief GCLK hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO GCLK_CTRL_Type CTRL; /**< \brief Offset: 0x0 (R/W 8) Control */ + __I GCLK_STATUS_Type STATUS; /**< \brief Offset: 0x1 (R/ 8) Status */ + __IO GCLK_CLKCTRL_Type CLKCTRL; /**< \brief Offset: 0x2 (R/W 16) Generic Clock Control */ + __IO GCLK_GENCTRL_Type GENCTRL; /**< \brief Offset: 0x4 (R/W 32) Generic Clock Generator Control */ + __IO GCLK_GENDIV_Type GENDIV; /**< \brief Offset: 0x8 (R/W 32) Generic Clock Generator Division */ +} Gclk; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_GCLK_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/i2s.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/i2s.h new file mode 100644 index 0000000..119b109 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/i2s.h @@ -0,0 +1,639 @@ +/** + * \file + * + * \brief Component description for I2S + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_I2S_COMPONENT_ +#define _SAMD21_I2S_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR I2S */ +/* ========================================================================== */ +/** \addtogroup SAMD21_I2S Inter-IC Sound Interface */ +/*@{*/ + +#define I2S_U2224 +#define REV_I2S 0x101 + +/* -------- I2S_CTRLA : (I2S Offset: 0x00) (R/W 8) Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset */ + uint8_t ENABLE:1; /*!< bit: 1 Enable */ + uint8_t CKEN0:1; /*!< bit: 2 Clock Unit 0 Enable */ + uint8_t CKEN1:1; /*!< bit: 3 Clock Unit 1 Enable */ + uint8_t SEREN0:1; /*!< bit: 4 Serializer 0 Enable */ + uint8_t SEREN1:1; /*!< bit: 5 Serializer 1 Enable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t :2; /*!< bit: 0.. 1 Reserved */ + uint8_t CKEN:2; /*!< bit: 2.. 3 Clock Unit x Enable */ + uint8_t SEREN:2; /*!< bit: 4.. 5 Serializer x Enable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} I2S_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define I2S_CTRLA_OFFSET 0x00 /**< \brief (I2S_CTRLA offset) Control A */ +#define I2S_CTRLA_RESETVALUE 0x00 /**< \brief (I2S_CTRLA reset_value) Control A */ + +#define I2S_CTRLA_SWRST_Pos 0 /**< \brief (I2S_CTRLA) Software Reset */ +#define I2S_CTRLA_SWRST (0x1u << I2S_CTRLA_SWRST_Pos) +#define I2S_CTRLA_ENABLE_Pos 1 /**< \brief (I2S_CTRLA) Enable */ +#define I2S_CTRLA_ENABLE (0x1u << I2S_CTRLA_ENABLE_Pos) +#define I2S_CTRLA_CKEN0_Pos 2 /**< \brief (I2S_CTRLA) Clock Unit 0 Enable */ +#define I2S_CTRLA_CKEN0 (1 << I2S_CTRLA_CKEN0_Pos) +#define I2S_CTRLA_CKEN1_Pos 3 /**< \brief (I2S_CTRLA) Clock Unit 1 Enable */ +#define I2S_CTRLA_CKEN1 (1 << I2S_CTRLA_CKEN1_Pos) +#define I2S_CTRLA_CKEN_Pos 2 /**< \brief (I2S_CTRLA) Clock Unit x Enable */ +#define I2S_CTRLA_CKEN_Msk (0x3u << I2S_CTRLA_CKEN_Pos) +#define I2S_CTRLA_CKEN(value) ((I2S_CTRLA_CKEN_Msk & ((value) << I2S_CTRLA_CKEN_Pos))) +#define I2S_CTRLA_SEREN0_Pos 4 /**< \brief (I2S_CTRLA) Serializer 0 Enable */ +#define I2S_CTRLA_SEREN0 (1 << I2S_CTRLA_SEREN0_Pos) +#define I2S_CTRLA_SEREN1_Pos 5 /**< \brief (I2S_CTRLA) Serializer 1 Enable */ +#define I2S_CTRLA_SEREN1 (1 << I2S_CTRLA_SEREN1_Pos) +#define I2S_CTRLA_SEREN_Pos 4 /**< \brief (I2S_CTRLA) Serializer x Enable */ +#define I2S_CTRLA_SEREN_Msk (0x3u << I2S_CTRLA_SEREN_Pos) +#define I2S_CTRLA_SEREN(value) ((I2S_CTRLA_SEREN_Msk & ((value) << I2S_CTRLA_SEREN_Pos))) +#define I2S_CTRLA_MASK 0x3Fu /**< \brief (I2S_CTRLA) MASK Register */ + +/* -------- I2S_CLKCTRL : (I2S Offset: 0x04) (R/W 32) Clock Unit n Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SLOTSIZE:2; /*!< bit: 0.. 1 Slot Size */ + uint32_t NBSLOTS:3; /*!< bit: 2.. 4 Number of Slots in Frame */ + uint32_t FSWIDTH:2; /*!< bit: 5.. 6 Frame Sync Width */ + uint32_t BITDELAY:1; /*!< bit: 7 Data Delay from Frame Sync */ + uint32_t FSSEL:1; /*!< bit: 8 Frame Sync Select */ + uint32_t :2; /*!< bit: 9..10 Reserved */ + uint32_t FSINV:1; /*!< bit: 11 Frame Sync Invert */ + uint32_t SCKSEL:1; /*!< bit: 12 Serial Clock Select */ + uint32_t :3; /*!< bit: 13..15 Reserved */ + uint32_t MCKSEL:1; /*!< bit: 16 Master Clock Select */ + uint32_t :1; /*!< bit: 17 Reserved */ + uint32_t MCKEN:1; /*!< bit: 18 Master Clock Enable */ + uint32_t MCKDIV:5; /*!< bit: 19..23 Master Clock Division Factor */ + uint32_t MCKOUTDIV:5; /*!< bit: 24..28 Master Clock Output Division Factor */ + uint32_t FSOUTINV:1; /*!< bit: 29 Frame Sync Output Invert */ + uint32_t SCKOUTINV:1; /*!< bit: 30 Serial Clock Output Invert */ + uint32_t MCKOUTINV:1; /*!< bit: 31 Master Clock Output Invert */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} I2S_CLKCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define I2S_CLKCTRL_OFFSET 0x04 /**< \brief (I2S_CLKCTRL offset) Clock Unit n Control */ +#define I2S_CLKCTRL_RESETVALUE 0x00000000 /**< \brief (I2S_CLKCTRL reset_value) Clock Unit n Control */ + +#define I2S_CLKCTRL_SLOTSIZE_Pos 0 /**< \brief (I2S_CLKCTRL) Slot Size */ +#define I2S_CLKCTRL_SLOTSIZE_Msk (0x3u << I2S_CLKCTRL_SLOTSIZE_Pos) +#define I2S_CLKCTRL_SLOTSIZE(value) ((I2S_CLKCTRL_SLOTSIZE_Msk & ((value) << I2S_CLKCTRL_SLOTSIZE_Pos))) +#define I2S_CLKCTRL_SLOTSIZE_8_Val 0x0u /**< \brief (I2S_CLKCTRL) 8-bit Slot for Clock Unit n */ +#define I2S_CLKCTRL_SLOTSIZE_16_Val 0x1u /**< \brief (I2S_CLKCTRL) 16-bit Slot for Clock Unit n */ +#define I2S_CLKCTRL_SLOTSIZE_24_Val 0x2u /**< \brief (I2S_CLKCTRL) 24-bit Slot for Clock Unit n */ +#define I2S_CLKCTRL_SLOTSIZE_32_Val 0x3u /**< \brief (I2S_CLKCTRL) 32-bit Slot for Clock Unit n */ +#define I2S_CLKCTRL_SLOTSIZE_8 (I2S_CLKCTRL_SLOTSIZE_8_Val << I2S_CLKCTRL_SLOTSIZE_Pos) +#define I2S_CLKCTRL_SLOTSIZE_16 (I2S_CLKCTRL_SLOTSIZE_16_Val << I2S_CLKCTRL_SLOTSIZE_Pos) +#define I2S_CLKCTRL_SLOTSIZE_24 (I2S_CLKCTRL_SLOTSIZE_24_Val << I2S_CLKCTRL_SLOTSIZE_Pos) +#define I2S_CLKCTRL_SLOTSIZE_32 (I2S_CLKCTRL_SLOTSIZE_32_Val << I2S_CLKCTRL_SLOTSIZE_Pos) +#define I2S_CLKCTRL_NBSLOTS_Pos 2 /**< \brief (I2S_CLKCTRL) Number of Slots in Frame */ +#define I2S_CLKCTRL_NBSLOTS_Msk (0x7u << I2S_CLKCTRL_NBSLOTS_Pos) +#define I2S_CLKCTRL_NBSLOTS(value) ((I2S_CLKCTRL_NBSLOTS_Msk & ((value) << I2S_CLKCTRL_NBSLOTS_Pos))) +#define I2S_CLKCTRL_FSWIDTH_Pos 5 /**< \brief (I2S_CLKCTRL) Frame Sync Width */ +#define I2S_CLKCTRL_FSWIDTH_Msk (0x3u << I2S_CLKCTRL_FSWIDTH_Pos) +#define I2S_CLKCTRL_FSWIDTH(value) ((I2S_CLKCTRL_FSWIDTH_Msk & ((value) << I2S_CLKCTRL_FSWIDTH_Pos))) +#define I2S_CLKCTRL_FSWIDTH_SLOT_Val 0x0u /**< \brief (I2S_CLKCTRL) Frame Sync Pulse is 1 Slot wide (default for I2S protocol) */ +#define I2S_CLKCTRL_FSWIDTH_HALF_Val 0x1u /**< \brief (I2S_CLKCTRL) Frame Sync Pulse is half a Frame wide */ +#define I2S_CLKCTRL_FSWIDTH_BIT_Val 0x2u /**< \brief (I2S_CLKCTRL) Frame Sync Pulse is 1 Bit wide */ +#define I2S_CLKCTRL_FSWIDTH_BURST_Val 0x3u /**< \brief (I2S_CLKCTRL) Clock Unit n operates in Burst mode, with a 1-bit wide Frame Sync pulse per Data sample, only when Data transfer is requested */ +#define I2S_CLKCTRL_FSWIDTH_SLOT (I2S_CLKCTRL_FSWIDTH_SLOT_Val << I2S_CLKCTRL_FSWIDTH_Pos) +#define I2S_CLKCTRL_FSWIDTH_HALF (I2S_CLKCTRL_FSWIDTH_HALF_Val << I2S_CLKCTRL_FSWIDTH_Pos) +#define I2S_CLKCTRL_FSWIDTH_BIT (I2S_CLKCTRL_FSWIDTH_BIT_Val << I2S_CLKCTRL_FSWIDTH_Pos) +#define I2S_CLKCTRL_FSWIDTH_BURST (I2S_CLKCTRL_FSWIDTH_BURST_Val << I2S_CLKCTRL_FSWIDTH_Pos) +#define I2S_CLKCTRL_BITDELAY_Pos 7 /**< \brief (I2S_CLKCTRL) Data Delay from Frame Sync */ +#define I2S_CLKCTRL_BITDELAY (0x1u << I2S_CLKCTRL_BITDELAY_Pos) +#define I2S_CLKCTRL_BITDELAY_LJ_Val 0x0u /**< \brief (I2S_CLKCTRL) Left Justified (0 Bit Delay) */ +#define I2S_CLKCTRL_BITDELAY_I2S_Val 0x1u /**< \brief (I2S_CLKCTRL) I2S (1 Bit Delay) */ +#define I2S_CLKCTRL_BITDELAY_LJ (I2S_CLKCTRL_BITDELAY_LJ_Val << I2S_CLKCTRL_BITDELAY_Pos) +#define I2S_CLKCTRL_BITDELAY_I2S (I2S_CLKCTRL_BITDELAY_I2S_Val << I2S_CLKCTRL_BITDELAY_Pos) +#define I2S_CLKCTRL_FSSEL_Pos 8 /**< \brief (I2S_CLKCTRL) Frame Sync Select */ +#define I2S_CLKCTRL_FSSEL (0x1u << I2S_CLKCTRL_FSSEL_Pos) +#define I2S_CLKCTRL_FSSEL_SCKDIV_Val 0x0u /**< \brief (I2S_CLKCTRL) Divided Serial Clock n is used as Frame Sync n source */ +#define I2S_CLKCTRL_FSSEL_FSPIN_Val 0x1u /**< \brief (I2S_CLKCTRL) FSn input pin is used as Frame Sync n source */ +#define I2S_CLKCTRL_FSSEL_SCKDIV (I2S_CLKCTRL_FSSEL_SCKDIV_Val << I2S_CLKCTRL_FSSEL_Pos) +#define I2S_CLKCTRL_FSSEL_FSPIN (I2S_CLKCTRL_FSSEL_FSPIN_Val << I2S_CLKCTRL_FSSEL_Pos) +#define I2S_CLKCTRL_FSINV_Pos 11 /**< \brief (I2S_CLKCTRL) Frame Sync Invert */ +#define I2S_CLKCTRL_FSINV (0x1u << I2S_CLKCTRL_FSINV_Pos) +#define I2S_CLKCTRL_SCKSEL_Pos 12 /**< \brief (I2S_CLKCTRL) Serial Clock Select */ +#define I2S_CLKCTRL_SCKSEL (0x1u << I2S_CLKCTRL_SCKSEL_Pos) +#define I2S_CLKCTRL_SCKSEL_MCKDIV_Val 0x0u /**< \brief (I2S_CLKCTRL) Divided Master Clock n is used as Serial Clock n source */ +#define I2S_CLKCTRL_SCKSEL_SCKPIN_Val 0x1u /**< \brief (I2S_CLKCTRL) SCKn input pin is used as Serial Clock n source */ +#define I2S_CLKCTRL_SCKSEL_MCKDIV (I2S_CLKCTRL_SCKSEL_MCKDIV_Val << I2S_CLKCTRL_SCKSEL_Pos) +#define I2S_CLKCTRL_SCKSEL_SCKPIN (I2S_CLKCTRL_SCKSEL_SCKPIN_Val << I2S_CLKCTRL_SCKSEL_Pos) +#define I2S_CLKCTRL_MCKSEL_Pos 16 /**< \brief (I2S_CLKCTRL) Master Clock Select */ +#define I2S_CLKCTRL_MCKSEL (0x1u << I2S_CLKCTRL_MCKSEL_Pos) +#define I2S_CLKCTRL_MCKSEL_GCLK_Val 0x0u /**< \brief (I2S_CLKCTRL) GCLK_I2S_n is used as Master Clock n source */ +#define I2S_CLKCTRL_MCKSEL_MCKPIN_Val 0x1u /**< \brief (I2S_CLKCTRL) MCKn input pin is used as Master Clock n source */ +#define I2S_CLKCTRL_MCKSEL_GCLK (I2S_CLKCTRL_MCKSEL_GCLK_Val << I2S_CLKCTRL_MCKSEL_Pos) +#define I2S_CLKCTRL_MCKSEL_MCKPIN (I2S_CLKCTRL_MCKSEL_MCKPIN_Val << I2S_CLKCTRL_MCKSEL_Pos) +#define I2S_CLKCTRL_MCKEN_Pos 18 /**< \brief (I2S_CLKCTRL) Master Clock Enable */ +#define I2S_CLKCTRL_MCKEN (0x1u << I2S_CLKCTRL_MCKEN_Pos) +#define I2S_CLKCTRL_MCKDIV_Pos 19 /**< \brief (I2S_CLKCTRL) Master Clock Division Factor */ +#define I2S_CLKCTRL_MCKDIV_Msk (0x1Fu << I2S_CLKCTRL_MCKDIV_Pos) +#define I2S_CLKCTRL_MCKDIV(value) ((I2S_CLKCTRL_MCKDIV_Msk & ((value) << I2S_CLKCTRL_MCKDIV_Pos))) +#define I2S_CLKCTRL_MCKOUTDIV_Pos 24 /**< \brief (I2S_CLKCTRL) Master Clock Output Division Factor */ +#define I2S_CLKCTRL_MCKOUTDIV_Msk (0x1Fu << I2S_CLKCTRL_MCKOUTDIV_Pos) +#define I2S_CLKCTRL_MCKOUTDIV(value) ((I2S_CLKCTRL_MCKOUTDIV_Msk & ((value) << I2S_CLKCTRL_MCKOUTDIV_Pos))) +#define I2S_CLKCTRL_FSOUTINV_Pos 29 /**< \brief (I2S_CLKCTRL) Frame Sync Output Invert */ +#define I2S_CLKCTRL_FSOUTINV (0x1u << I2S_CLKCTRL_FSOUTINV_Pos) +#define I2S_CLKCTRL_SCKOUTINV_Pos 30 /**< \brief (I2S_CLKCTRL) Serial Clock Output Invert */ +#define I2S_CLKCTRL_SCKOUTINV (0x1u << I2S_CLKCTRL_SCKOUTINV_Pos) +#define I2S_CLKCTRL_MCKOUTINV_Pos 31 /**< \brief (I2S_CLKCTRL) Master Clock Output Invert */ +#define I2S_CLKCTRL_MCKOUTINV (0x1u << I2S_CLKCTRL_MCKOUTINV_Pos) +#define I2S_CLKCTRL_MASK 0xFFFD19FFu /**< \brief (I2S_CLKCTRL) MASK Register */ + +/* -------- I2S_INTENCLR : (I2S Offset: 0x0C) (R/W 16) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t RXRDY0:1; /*!< bit: 0 Receive Ready 0 Interrupt Enable */ + uint16_t RXRDY1:1; /*!< bit: 1 Receive Ready 1 Interrupt Enable */ + uint16_t :2; /*!< bit: 2.. 3 Reserved */ + uint16_t RXOR0:1; /*!< bit: 4 Receive Overrun 0 Interrupt Enable */ + uint16_t RXOR1:1; /*!< bit: 5 Receive Overrun 1 Interrupt Enable */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t TXRDY0:1; /*!< bit: 8 Transmit Ready 0 Interrupt Enable */ + uint16_t TXRDY1:1; /*!< bit: 9 Transmit Ready 1 Interrupt Enable */ + uint16_t :2; /*!< bit: 10..11 Reserved */ + uint16_t TXUR0:1; /*!< bit: 12 Transmit Underrun 0 Interrupt Enable */ + uint16_t TXUR1:1; /*!< bit: 13 Transmit Underrun 1 Interrupt Enable */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t RXRDY:2; /*!< bit: 0.. 1 Receive Ready x Interrupt Enable */ + uint16_t :2; /*!< bit: 2.. 3 Reserved */ + uint16_t RXOR:2; /*!< bit: 4.. 5 Receive Overrun x Interrupt Enable */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t TXRDY:2; /*!< bit: 8.. 9 Transmit Ready x Interrupt Enable */ + uint16_t :2; /*!< bit: 10..11 Reserved */ + uint16_t TXUR:2; /*!< bit: 12..13 Transmit Underrun x Interrupt Enable */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} I2S_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define I2S_INTENCLR_OFFSET 0x0C /**< \brief (I2S_INTENCLR offset) Interrupt Enable Clear */ +#define I2S_INTENCLR_RESETVALUE 0x0000 /**< \brief (I2S_INTENCLR reset_value) Interrupt Enable Clear */ + +#define I2S_INTENCLR_RXRDY0_Pos 0 /**< \brief (I2S_INTENCLR) Receive Ready 0 Interrupt Enable */ +#define I2S_INTENCLR_RXRDY0 (1 << I2S_INTENCLR_RXRDY0_Pos) +#define I2S_INTENCLR_RXRDY1_Pos 1 /**< \brief (I2S_INTENCLR) Receive Ready 1 Interrupt Enable */ +#define I2S_INTENCLR_RXRDY1 (1 << I2S_INTENCLR_RXRDY1_Pos) +#define I2S_INTENCLR_RXRDY_Pos 0 /**< \brief (I2S_INTENCLR) Receive Ready x Interrupt Enable */ +#define I2S_INTENCLR_RXRDY_Msk (0x3u << I2S_INTENCLR_RXRDY_Pos) +#define I2S_INTENCLR_RXRDY(value) ((I2S_INTENCLR_RXRDY_Msk & ((value) << I2S_INTENCLR_RXRDY_Pos))) +#define I2S_INTENCLR_RXOR0_Pos 4 /**< \brief (I2S_INTENCLR) Receive Overrun 0 Interrupt Enable */ +#define I2S_INTENCLR_RXOR0 (1 << I2S_INTENCLR_RXOR0_Pos) +#define I2S_INTENCLR_RXOR1_Pos 5 /**< \brief (I2S_INTENCLR) Receive Overrun 1 Interrupt Enable */ +#define I2S_INTENCLR_RXOR1 (1 << I2S_INTENCLR_RXOR1_Pos) +#define I2S_INTENCLR_RXOR_Pos 4 /**< \brief (I2S_INTENCLR) Receive Overrun x Interrupt Enable */ +#define I2S_INTENCLR_RXOR_Msk (0x3u << I2S_INTENCLR_RXOR_Pos) +#define I2S_INTENCLR_RXOR(value) ((I2S_INTENCLR_RXOR_Msk & ((value) << I2S_INTENCLR_RXOR_Pos))) +#define I2S_INTENCLR_TXRDY0_Pos 8 /**< \brief (I2S_INTENCLR) Transmit Ready 0 Interrupt Enable */ +#define I2S_INTENCLR_TXRDY0 (1 << I2S_INTENCLR_TXRDY0_Pos) +#define I2S_INTENCLR_TXRDY1_Pos 9 /**< \brief (I2S_INTENCLR) Transmit Ready 1 Interrupt Enable */ +#define I2S_INTENCLR_TXRDY1 (1 << I2S_INTENCLR_TXRDY1_Pos) +#define I2S_INTENCLR_TXRDY_Pos 8 /**< \brief (I2S_INTENCLR) Transmit Ready x Interrupt Enable */ +#define I2S_INTENCLR_TXRDY_Msk (0x3u << I2S_INTENCLR_TXRDY_Pos) +#define I2S_INTENCLR_TXRDY(value) ((I2S_INTENCLR_TXRDY_Msk & ((value) << I2S_INTENCLR_TXRDY_Pos))) +#define I2S_INTENCLR_TXUR0_Pos 12 /**< \brief (I2S_INTENCLR) Transmit Underrun 0 Interrupt Enable */ +#define I2S_INTENCLR_TXUR0 (1 << I2S_INTENCLR_TXUR0_Pos) +#define I2S_INTENCLR_TXUR1_Pos 13 /**< \brief (I2S_INTENCLR) Transmit Underrun 1 Interrupt Enable */ +#define I2S_INTENCLR_TXUR1 (1 << I2S_INTENCLR_TXUR1_Pos) +#define I2S_INTENCLR_TXUR_Pos 12 /**< \brief (I2S_INTENCLR) Transmit Underrun x Interrupt Enable */ +#define I2S_INTENCLR_TXUR_Msk (0x3u << I2S_INTENCLR_TXUR_Pos) +#define I2S_INTENCLR_TXUR(value) ((I2S_INTENCLR_TXUR_Msk & ((value) << I2S_INTENCLR_TXUR_Pos))) +#define I2S_INTENCLR_MASK 0x3333u /**< \brief (I2S_INTENCLR) MASK Register */ + +/* -------- I2S_INTENSET : (I2S Offset: 0x10) (R/W 16) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t RXRDY0:1; /*!< bit: 0 Receive Ready 0 Interrupt Enable */ + uint16_t RXRDY1:1; /*!< bit: 1 Receive Ready 1 Interrupt Enable */ + uint16_t :2; /*!< bit: 2.. 3 Reserved */ + uint16_t RXOR0:1; /*!< bit: 4 Receive Overrun 0 Interrupt Enable */ + uint16_t RXOR1:1; /*!< bit: 5 Receive Overrun 1 Interrupt Enable */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t TXRDY0:1; /*!< bit: 8 Transmit Ready 0 Interrupt Enable */ + uint16_t TXRDY1:1; /*!< bit: 9 Transmit Ready 1 Interrupt Enable */ + uint16_t :2; /*!< bit: 10..11 Reserved */ + uint16_t TXUR0:1; /*!< bit: 12 Transmit Underrun 0 Interrupt Enable */ + uint16_t TXUR1:1; /*!< bit: 13 Transmit Underrun 1 Interrupt Enable */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t RXRDY:2; /*!< bit: 0.. 1 Receive Ready x Interrupt Enable */ + uint16_t :2; /*!< bit: 2.. 3 Reserved */ + uint16_t RXOR:2; /*!< bit: 4.. 5 Receive Overrun x Interrupt Enable */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t TXRDY:2; /*!< bit: 8.. 9 Transmit Ready x Interrupt Enable */ + uint16_t :2; /*!< bit: 10..11 Reserved */ + uint16_t TXUR:2; /*!< bit: 12..13 Transmit Underrun x Interrupt Enable */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} I2S_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define I2S_INTENSET_OFFSET 0x10 /**< \brief (I2S_INTENSET offset) Interrupt Enable Set */ +#define I2S_INTENSET_RESETVALUE 0x0000 /**< \brief (I2S_INTENSET reset_value) Interrupt Enable Set */ + +#define I2S_INTENSET_RXRDY0_Pos 0 /**< \brief (I2S_INTENSET) Receive Ready 0 Interrupt Enable */ +#define I2S_INTENSET_RXRDY0 (1 << I2S_INTENSET_RXRDY0_Pos) +#define I2S_INTENSET_RXRDY1_Pos 1 /**< \brief (I2S_INTENSET) Receive Ready 1 Interrupt Enable */ +#define I2S_INTENSET_RXRDY1 (1 << I2S_INTENSET_RXRDY1_Pos) +#define I2S_INTENSET_RXRDY_Pos 0 /**< \brief (I2S_INTENSET) Receive Ready x Interrupt Enable */ +#define I2S_INTENSET_RXRDY_Msk (0x3u << I2S_INTENSET_RXRDY_Pos) +#define I2S_INTENSET_RXRDY(value) ((I2S_INTENSET_RXRDY_Msk & ((value) << I2S_INTENSET_RXRDY_Pos))) +#define I2S_INTENSET_RXOR0_Pos 4 /**< \brief (I2S_INTENSET) Receive Overrun 0 Interrupt Enable */ +#define I2S_INTENSET_RXOR0 (1 << I2S_INTENSET_RXOR0_Pos) +#define I2S_INTENSET_RXOR1_Pos 5 /**< \brief (I2S_INTENSET) Receive Overrun 1 Interrupt Enable */ +#define I2S_INTENSET_RXOR1 (1 << I2S_INTENSET_RXOR1_Pos) +#define I2S_INTENSET_RXOR_Pos 4 /**< \brief (I2S_INTENSET) Receive Overrun x Interrupt Enable */ +#define I2S_INTENSET_RXOR_Msk (0x3u << I2S_INTENSET_RXOR_Pos) +#define I2S_INTENSET_RXOR(value) ((I2S_INTENSET_RXOR_Msk & ((value) << I2S_INTENSET_RXOR_Pos))) +#define I2S_INTENSET_TXRDY0_Pos 8 /**< \brief (I2S_INTENSET) Transmit Ready 0 Interrupt Enable */ +#define I2S_INTENSET_TXRDY0 (1 << I2S_INTENSET_TXRDY0_Pos) +#define I2S_INTENSET_TXRDY1_Pos 9 /**< \brief (I2S_INTENSET) Transmit Ready 1 Interrupt Enable */ +#define I2S_INTENSET_TXRDY1 (1 << I2S_INTENSET_TXRDY1_Pos) +#define I2S_INTENSET_TXRDY_Pos 8 /**< \brief (I2S_INTENSET) Transmit Ready x Interrupt Enable */ +#define I2S_INTENSET_TXRDY_Msk (0x3u << I2S_INTENSET_TXRDY_Pos) +#define I2S_INTENSET_TXRDY(value) ((I2S_INTENSET_TXRDY_Msk & ((value) << I2S_INTENSET_TXRDY_Pos))) +#define I2S_INTENSET_TXUR0_Pos 12 /**< \brief (I2S_INTENSET) Transmit Underrun 0 Interrupt Enable */ +#define I2S_INTENSET_TXUR0 (1 << I2S_INTENSET_TXUR0_Pos) +#define I2S_INTENSET_TXUR1_Pos 13 /**< \brief (I2S_INTENSET) Transmit Underrun 1 Interrupt Enable */ +#define I2S_INTENSET_TXUR1 (1 << I2S_INTENSET_TXUR1_Pos) +#define I2S_INTENSET_TXUR_Pos 12 /**< \brief (I2S_INTENSET) Transmit Underrun x Interrupt Enable */ +#define I2S_INTENSET_TXUR_Msk (0x3u << I2S_INTENSET_TXUR_Pos) +#define I2S_INTENSET_TXUR(value) ((I2S_INTENSET_TXUR_Msk & ((value) << I2S_INTENSET_TXUR_Pos))) +#define I2S_INTENSET_MASK 0x3333u /**< \brief (I2S_INTENSET) MASK Register */ + +/* -------- I2S_INTFLAG : (I2S Offset: 0x14) (R/W 16) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t RXRDY0:1; /*!< bit: 0 Receive Ready 0 */ + uint16_t RXRDY1:1; /*!< bit: 1 Receive Ready 1 */ + uint16_t :2; /*!< bit: 2.. 3 Reserved */ + uint16_t RXOR0:1; /*!< bit: 4 Receive Overrun 0 */ + uint16_t RXOR1:1; /*!< bit: 5 Receive Overrun 1 */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t TXRDY0:1; /*!< bit: 8 Transmit Ready 0 */ + uint16_t TXRDY1:1; /*!< bit: 9 Transmit Ready 1 */ + uint16_t :2; /*!< bit: 10..11 Reserved */ + uint16_t TXUR0:1; /*!< bit: 12 Transmit Underrun 0 */ + uint16_t TXUR1:1; /*!< bit: 13 Transmit Underrun 1 */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t RXRDY:2; /*!< bit: 0.. 1 Receive Ready x */ + uint16_t :2; /*!< bit: 2.. 3 Reserved */ + uint16_t RXOR:2; /*!< bit: 4.. 5 Receive Overrun x */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t TXRDY:2; /*!< bit: 8.. 9 Transmit Ready x */ + uint16_t :2; /*!< bit: 10..11 Reserved */ + uint16_t TXUR:2; /*!< bit: 12..13 Transmit Underrun x */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} I2S_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define I2S_INTFLAG_OFFSET 0x14 /**< \brief (I2S_INTFLAG offset) Interrupt Flag Status and Clear */ +#define I2S_INTFLAG_RESETVALUE 0x0000 /**< \brief (I2S_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define I2S_INTFLAG_RXRDY0_Pos 0 /**< \brief (I2S_INTFLAG) Receive Ready 0 */ +#define I2S_INTFLAG_RXRDY0 (1 << I2S_INTFLAG_RXRDY0_Pos) +#define I2S_INTFLAG_RXRDY1_Pos 1 /**< \brief (I2S_INTFLAG) Receive Ready 1 */ +#define I2S_INTFLAG_RXRDY1 (1 << I2S_INTFLAG_RXRDY1_Pos) +#define I2S_INTFLAG_RXRDY_Pos 0 /**< \brief (I2S_INTFLAG) Receive Ready x */ +#define I2S_INTFLAG_RXRDY_Msk (0x3u << I2S_INTFLAG_RXRDY_Pos) +#define I2S_INTFLAG_RXRDY(value) ((I2S_INTFLAG_RXRDY_Msk & ((value) << I2S_INTFLAG_RXRDY_Pos))) +#define I2S_INTFLAG_RXOR0_Pos 4 /**< \brief (I2S_INTFLAG) Receive Overrun 0 */ +#define I2S_INTFLAG_RXOR0 (1 << I2S_INTFLAG_RXOR0_Pos) +#define I2S_INTFLAG_RXOR1_Pos 5 /**< \brief (I2S_INTFLAG) Receive Overrun 1 */ +#define I2S_INTFLAG_RXOR1 (1 << I2S_INTFLAG_RXOR1_Pos) +#define I2S_INTFLAG_RXOR_Pos 4 /**< \brief (I2S_INTFLAG) Receive Overrun x */ +#define I2S_INTFLAG_RXOR_Msk (0x3u << I2S_INTFLAG_RXOR_Pos) +#define I2S_INTFLAG_RXOR(value) ((I2S_INTFLAG_RXOR_Msk & ((value) << I2S_INTFLAG_RXOR_Pos))) +#define I2S_INTFLAG_TXRDY0_Pos 8 /**< \brief (I2S_INTFLAG) Transmit Ready 0 */ +#define I2S_INTFLAG_TXRDY0 (1 << I2S_INTFLAG_TXRDY0_Pos) +#define I2S_INTFLAG_TXRDY1_Pos 9 /**< \brief (I2S_INTFLAG) Transmit Ready 1 */ +#define I2S_INTFLAG_TXRDY1 (1 << I2S_INTFLAG_TXRDY1_Pos) +#define I2S_INTFLAG_TXRDY_Pos 8 /**< \brief (I2S_INTFLAG) Transmit Ready x */ +#define I2S_INTFLAG_TXRDY_Msk (0x3u << I2S_INTFLAG_TXRDY_Pos) +#define I2S_INTFLAG_TXRDY(value) ((I2S_INTFLAG_TXRDY_Msk & ((value) << I2S_INTFLAG_TXRDY_Pos))) +#define I2S_INTFLAG_TXUR0_Pos 12 /**< \brief (I2S_INTFLAG) Transmit Underrun 0 */ +#define I2S_INTFLAG_TXUR0 (1 << I2S_INTFLAG_TXUR0_Pos) +#define I2S_INTFLAG_TXUR1_Pos 13 /**< \brief (I2S_INTFLAG) Transmit Underrun 1 */ +#define I2S_INTFLAG_TXUR1 (1 << I2S_INTFLAG_TXUR1_Pos) +#define I2S_INTFLAG_TXUR_Pos 12 /**< \brief (I2S_INTFLAG) Transmit Underrun x */ +#define I2S_INTFLAG_TXUR_Msk (0x3u << I2S_INTFLAG_TXUR_Pos) +#define I2S_INTFLAG_TXUR(value) ((I2S_INTFLAG_TXUR_Msk & ((value) << I2S_INTFLAG_TXUR_Pos))) +#define I2S_INTFLAG_MASK 0x3333u /**< \brief (I2S_INTFLAG) MASK Register */ + +/* -------- I2S_SYNCBUSY : (I2S Offset: 0x18) (R/ 16) Synchronization Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SWRST:1; /*!< bit: 0 Software Reset Synchronization Status */ + uint16_t ENABLE:1; /*!< bit: 1 Enable Synchronization Status */ + uint16_t CKEN0:1; /*!< bit: 2 Clock Unit 0 Enable Synchronization Status */ + uint16_t CKEN1:1; /*!< bit: 3 Clock Unit 1 Enable Synchronization Status */ + uint16_t SEREN0:1; /*!< bit: 4 Serializer 0 Enable Synchronization Status */ + uint16_t SEREN1:1; /*!< bit: 5 Serializer 1 Enable Synchronization Status */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t DATA0:1; /*!< bit: 8 Data 0 Synchronization Status */ + uint16_t DATA1:1; /*!< bit: 9 Data 1 Synchronization Status */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t :2; /*!< bit: 0.. 1 Reserved */ + uint16_t CKEN:2; /*!< bit: 2.. 3 Clock Unit x Enable Synchronization Status */ + uint16_t SEREN:2; /*!< bit: 4.. 5 Serializer x Enable Synchronization Status */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t DATA:2; /*!< bit: 8.. 9 Data x Synchronization Status */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} I2S_SYNCBUSY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define I2S_SYNCBUSY_OFFSET 0x18 /**< \brief (I2S_SYNCBUSY offset) Synchronization Status */ +#define I2S_SYNCBUSY_RESETVALUE 0x0000 /**< \brief (I2S_SYNCBUSY reset_value) Synchronization Status */ + +#define I2S_SYNCBUSY_SWRST_Pos 0 /**< \brief (I2S_SYNCBUSY) Software Reset Synchronization Status */ +#define I2S_SYNCBUSY_SWRST (0x1u << I2S_SYNCBUSY_SWRST_Pos) +#define I2S_SYNCBUSY_ENABLE_Pos 1 /**< \brief (I2S_SYNCBUSY) Enable Synchronization Status */ +#define I2S_SYNCBUSY_ENABLE (0x1u << I2S_SYNCBUSY_ENABLE_Pos) +#define I2S_SYNCBUSY_CKEN0_Pos 2 /**< \brief (I2S_SYNCBUSY) Clock Unit 0 Enable Synchronization Status */ +#define I2S_SYNCBUSY_CKEN0 (1 << I2S_SYNCBUSY_CKEN0_Pos) +#define I2S_SYNCBUSY_CKEN1_Pos 3 /**< \brief (I2S_SYNCBUSY) Clock Unit 1 Enable Synchronization Status */ +#define I2S_SYNCBUSY_CKEN1 (1 << I2S_SYNCBUSY_CKEN1_Pos) +#define I2S_SYNCBUSY_CKEN_Pos 2 /**< \brief (I2S_SYNCBUSY) Clock Unit x Enable Synchronization Status */ +#define I2S_SYNCBUSY_CKEN_Msk (0x3u << I2S_SYNCBUSY_CKEN_Pos) +#define I2S_SYNCBUSY_CKEN(value) ((I2S_SYNCBUSY_CKEN_Msk & ((value) << I2S_SYNCBUSY_CKEN_Pos))) +#define I2S_SYNCBUSY_SEREN0_Pos 4 /**< \brief (I2S_SYNCBUSY) Serializer 0 Enable Synchronization Status */ +#define I2S_SYNCBUSY_SEREN0 (1 << I2S_SYNCBUSY_SEREN0_Pos) +#define I2S_SYNCBUSY_SEREN1_Pos 5 /**< \brief (I2S_SYNCBUSY) Serializer 1 Enable Synchronization Status */ +#define I2S_SYNCBUSY_SEREN1 (1 << I2S_SYNCBUSY_SEREN1_Pos) +#define I2S_SYNCBUSY_SEREN_Pos 4 /**< \brief (I2S_SYNCBUSY) Serializer x Enable Synchronization Status */ +#define I2S_SYNCBUSY_SEREN_Msk (0x3u << I2S_SYNCBUSY_SEREN_Pos) +#define I2S_SYNCBUSY_SEREN(value) ((I2S_SYNCBUSY_SEREN_Msk & ((value) << I2S_SYNCBUSY_SEREN_Pos))) +#define I2S_SYNCBUSY_DATA0_Pos 8 /**< \brief (I2S_SYNCBUSY) Data 0 Synchronization Status */ +#define I2S_SYNCBUSY_DATA0 (1 << I2S_SYNCBUSY_DATA0_Pos) +#define I2S_SYNCBUSY_DATA1_Pos 9 /**< \brief (I2S_SYNCBUSY) Data 1 Synchronization Status */ +#define I2S_SYNCBUSY_DATA1 (1 << I2S_SYNCBUSY_DATA1_Pos) +#define I2S_SYNCBUSY_DATA_Pos 8 /**< \brief (I2S_SYNCBUSY) Data x Synchronization Status */ +#define I2S_SYNCBUSY_DATA_Msk (0x3u << I2S_SYNCBUSY_DATA_Pos) +#define I2S_SYNCBUSY_DATA(value) ((I2S_SYNCBUSY_DATA_Msk & ((value) << I2S_SYNCBUSY_DATA_Pos))) +#define I2S_SYNCBUSY_MASK 0x033Fu /**< \brief (I2S_SYNCBUSY) MASK Register */ + +/* -------- I2S_SERCTRL : (I2S Offset: 0x20) (R/W 32) Serializer n Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SERMODE:2; /*!< bit: 0.. 1 Serializer Mode */ + uint32_t TXDEFAULT:2; /*!< bit: 2.. 3 Line Default Line when Slot Disabled */ + uint32_t TXSAME:1; /*!< bit: 4 Transmit Data when Underrun */ + uint32_t CLKSEL:1; /*!< bit: 5 Clock Unit Selection */ + uint32_t :1; /*!< bit: 6 Reserved */ + uint32_t SLOTADJ:1; /*!< bit: 7 Data Slot Formatting Adjust */ + uint32_t DATASIZE:3; /*!< bit: 8..10 Data Word Size */ + uint32_t :1; /*!< bit: 11 Reserved */ + uint32_t WORDADJ:1; /*!< bit: 12 Data Word Formatting Adjust */ + uint32_t EXTEND:2; /*!< bit: 13..14 Data Formatting Bit Extension */ + uint32_t BITREV:1; /*!< bit: 15 Data Formatting Bit Reverse */ + uint32_t SLOTDIS0:1; /*!< bit: 16 Slot 0 Disabled for this Serializer */ + uint32_t SLOTDIS1:1; /*!< bit: 17 Slot 1 Disabled for this Serializer */ + uint32_t SLOTDIS2:1; /*!< bit: 18 Slot 2 Disabled for this Serializer */ + uint32_t SLOTDIS3:1; /*!< bit: 19 Slot 3 Disabled for this Serializer */ + uint32_t SLOTDIS4:1; /*!< bit: 20 Slot 4 Disabled for this Serializer */ + uint32_t SLOTDIS5:1; /*!< bit: 21 Slot 5 Disabled for this Serializer */ + uint32_t SLOTDIS6:1; /*!< bit: 22 Slot 6 Disabled for this Serializer */ + uint32_t SLOTDIS7:1; /*!< bit: 23 Slot 7 Disabled for this Serializer */ + uint32_t MONO:1; /*!< bit: 24 Mono Mode */ + uint32_t DMA:1; /*!< bit: 25 Single or Multiple DMA Channels */ + uint32_t RXLOOP:1; /*!< bit: 26 Loop-back Test Mode */ + uint32_t :5; /*!< bit: 27..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :16; /*!< bit: 0..15 Reserved */ + uint32_t SLOTDIS:8; /*!< bit: 16..23 Slot x Disabled for this Serializer */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} I2S_SERCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define I2S_SERCTRL_OFFSET 0x20 /**< \brief (I2S_SERCTRL offset) Serializer n Control */ +#define I2S_SERCTRL_RESETVALUE 0x00000000 /**< \brief (I2S_SERCTRL reset_value) Serializer n Control */ + +#define I2S_SERCTRL_SERMODE_Pos 0 /**< \brief (I2S_SERCTRL) Serializer Mode */ +#define I2S_SERCTRL_SERMODE_Msk (0x3u << I2S_SERCTRL_SERMODE_Pos) +#define I2S_SERCTRL_SERMODE(value) ((I2S_SERCTRL_SERMODE_Msk & ((value) << I2S_SERCTRL_SERMODE_Pos))) +#define I2S_SERCTRL_SERMODE_RX_Val 0x0u /**< \brief (I2S_SERCTRL) Receive */ +#define I2S_SERCTRL_SERMODE_TX_Val 0x1u /**< \brief (I2S_SERCTRL) Transmit */ +#define I2S_SERCTRL_SERMODE_PDM2_Val 0x2u /**< \brief (I2S_SERCTRL) Receive one PDM data on each serial clock edge */ +#define I2S_SERCTRL_SERMODE_RX (I2S_SERCTRL_SERMODE_RX_Val << I2S_SERCTRL_SERMODE_Pos) +#define I2S_SERCTRL_SERMODE_TX (I2S_SERCTRL_SERMODE_TX_Val << I2S_SERCTRL_SERMODE_Pos) +#define I2S_SERCTRL_SERMODE_PDM2 (I2S_SERCTRL_SERMODE_PDM2_Val << I2S_SERCTRL_SERMODE_Pos) +#define I2S_SERCTRL_TXDEFAULT_Pos 2 /**< \brief (I2S_SERCTRL) Line Default Line when Slot Disabled */ +#define I2S_SERCTRL_TXDEFAULT_Msk (0x3u << I2S_SERCTRL_TXDEFAULT_Pos) +#define I2S_SERCTRL_TXDEFAULT(value) ((I2S_SERCTRL_TXDEFAULT_Msk & ((value) << I2S_SERCTRL_TXDEFAULT_Pos))) +#define I2S_SERCTRL_TXDEFAULT_ZERO_Val 0x0u /**< \brief (I2S_SERCTRL) Output Default Value is 0 */ +#define I2S_SERCTRL_TXDEFAULT_ONE_Val 0x1u /**< \brief (I2S_SERCTRL) Output Default Value is 1 */ +#define I2S_SERCTRL_TXDEFAULT_HIZ_Val 0x3u /**< \brief (I2S_SERCTRL) Output Default Value is high impedance */ +#define I2S_SERCTRL_TXDEFAULT_ZERO (I2S_SERCTRL_TXDEFAULT_ZERO_Val << I2S_SERCTRL_TXDEFAULT_Pos) +#define I2S_SERCTRL_TXDEFAULT_ONE (I2S_SERCTRL_TXDEFAULT_ONE_Val << I2S_SERCTRL_TXDEFAULT_Pos) +#define I2S_SERCTRL_TXDEFAULT_HIZ (I2S_SERCTRL_TXDEFAULT_HIZ_Val << I2S_SERCTRL_TXDEFAULT_Pos) +#define I2S_SERCTRL_TXSAME_Pos 4 /**< \brief (I2S_SERCTRL) Transmit Data when Underrun */ +#define I2S_SERCTRL_TXSAME (0x1u << I2S_SERCTRL_TXSAME_Pos) +#define I2S_SERCTRL_TXSAME_ZERO_Val 0x0u /**< \brief (I2S_SERCTRL) Zero data transmitted in case of underrun */ +#define I2S_SERCTRL_TXSAME_SAME_Val 0x1u /**< \brief (I2S_SERCTRL) Last data transmitted in case of underrun */ +#define I2S_SERCTRL_TXSAME_ZERO (I2S_SERCTRL_TXSAME_ZERO_Val << I2S_SERCTRL_TXSAME_Pos) +#define I2S_SERCTRL_TXSAME_SAME (I2S_SERCTRL_TXSAME_SAME_Val << I2S_SERCTRL_TXSAME_Pos) +#define I2S_SERCTRL_CLKSEL_Pos 5 /**< \brief (I2S_SERCTRL) Clock Unit Selection */ +#define I2S_SERCTRL_CLKSEL (0x1u << I2S_SERCTRL_CLKSEL_Pos) +#define I2S_SERCTRL_CLKSEL_CLK0_Val 0x0u /**< \brief (I2S_SERCTRL) Use Clock Unit 0 */ +#define I2S_SERCTRL_CLKSEL_CLK1_Val 0x1u /**< \brief (I2S_SERCTRL) Use Clock Unit 1 */ +#define I2S_SERCTRL_CLKSEL_CLK0 (I2S_SERCTRL_CLKSEL_CLK0_Val << I2S_SERCTRL_CLKSEL_Pos) +#define I2S_SERCTRL_CLKSEL_CLK1 (I2S_SERCTRL_CLKSEL_CLK1_Val << I2S_SERCTRL_CLKSEL_Pos) +#define I2S_SERCTRL_SLOTADJ_Pos 7 /**< \brief (I2S_SERCTRL) Data Slot Formatting Adjust */ +#define I2S_SERCTRL_SLOTADJ (0x1u << I2S_SERCTRL_SLOTADJ_Pos) +#define I2S_SERCTRL_SLOTADJ_RIGHT_Val 0x0u /**< \brief (I2S_SERCTRL) Data is right adjusted in slot */ +#define I2S_SERCTRL_SLOTADJ_LEFT_Val 0x1u /**< \brief (I2S_SERCTRL) Data is left adjusted in slot */ +#define I2S_SERCTRL_SLOTADJ_RIGHT (I2S_SERCTRL_SLOTADJ_RIGHT_Val << I2S_SERCTRL_SLOTADJ_Pos) +#define I2S_SERCTRL_SLOTADJ_LEFT (I2S_SERCTRL_SLOTADJ_LEFT_Val << I2S_SERCTRL_SLOTADJ_Pos) +#define I2S_SERCTRL_DATASIZE_Pos 8 /**< \brief (I2S_SERCTRL) Data Word Size */ +#define I2S_SERCTRL_DATASIZE_Msk (0x7u << I2S_SERCTRL_DATASIZE_Pos) +#define I2S_SERCTRL_DATASIZE(value) ((I2S_SERCTRL_DATASIZE_Msk & ((value) << I2S_SERCTRL_DATASIZE_Pos))) +#define I2S_SERCTRL_DATASIZE_32_Val 0x0u /**< \brief (I2S_SERCTRL) 32 bits */ +#define I2S_SERCTRL_DATASIZE_24_Val 0x1u /**< \brief (I2S_SERCTRL) 24 bits */ +#define I2S_SERCTRL_DATASIZE_20_Val 0x2u /**< \brief (I2S_SERCTRL) 20 bits */ +#define I2S_SERCTRL_DATASIZE_18_Val 0x3u /**< \brief (I2S_SERCTRL) 18 bits */ +#define I2S_SERCTRL_DATASIZE_16_Val 0x4u /**< \brief (I2S_SERCTRL) 16 bits */ +#define I2S_SERCTRL_DATASIZE_16C_Val 0x5u /**< \brief (I2S_SERCTRL) 16 bits compact stereo */ +#define I2S_SERCTRL_DATASIZE_8_Val 0x6u /**< \brief (I2S_SERCTRL) 8 bits */ +#define I2S_SERCTRL_DATASIZE_8C_Val 0x7u /**< \brief (I2S_SERCTRL) 8 bits compact stereo */ +#define I2S_SERCTRL_DATASIZE_32 (I2S_SERCTRL_DATASIZE_32_Val << I2S_SERCTRL_DATASIZE_Pos) +#define I2S_SERCTRL_DATASIZE_24 (I2S_SERCTRL_DATASIZE_24_Val << I2S_SERCTRL_DATASIZE_Pos) +#define I2S_SERCTRL_DATASIZE_20 (I2S_SERCTRL_DATASIZE_20_Val << I2S_SERCTRL_DATASIZE_Pos) +#define I2S_SERCTRL_DATASIZE_18 (I2S_SERCTRL_DATASIZE_18_Val << I2S_SERCTRL_DATASIZE_Pos) +#define I2S_SERCTRL_DATASIZE_16 (I2S_SERCTRL_DATASIZE_16_Val << I2S_SERCTRL_DATASIZE_Pos) +#define I2S_SERCTRL_DATASIZE_16C (I2S_SERCTRL_DATASIZE_16C_Val << I2S_SERCTRL_DATASIZE_Pos) +#define I2S_SERCTRL_DATASIZE_8 (I2S_SERCTRL_DATASIZE_8_Val << I2S_SERCTRL_DATASIZE_Pos) +#define I2S_SERCTRL_DATASIZE_8C (I2S_SERCTRL_DATASIZE_8C_Val << I2S_SERCTRL_DATASIZE_Pos) +#define I2S_SERCTRL_WORDADJ_Pos 12 /**< \brief (I2S_SERCTRL) Data Word Formatting Adjust */ +#define I2S_SERCTRL_WORDADJ (0x1u << I2S_SERCTRL_WORDADJ_Pos) +#define I2S_SERCTRL_WORDADJ_RIGHT_Val 0x0u /**< \brief (I2S_SERCTRL) Data is right adjusted in word */ +#define I2S_SERCTRL_WORDADJ_LEFT_Val 0x1u /**< \brief (I2S_SERCTRL) Data is left adjusted in word */ +#define I2S_SERCTRL_WORDADJ_RIGHT (I2S_SERCTRL_WORDADJ_RIGHT_Val << I2S_SERCTRL_WORDADJ_Pos) +#define I2S_SERCTRL_WORDADJ_LEFT (I2S_SERCTRL_WORDADJ_LEFT_Val << I2S_SERCTRL_WORDADJ_Pos) +#define I2S_SERCTRL_EXTEND_Pos 13 /**< \brief (I2S_SERCTRL) Data Formatting Bit Extension */ +#define I2S_SERCTRL_EXTEND_Msk (0x3u << I2S_SERCTRL_EXTEND_Pos) +#define I2S_SERCTRL_EXTEND(value) ((I2S_SERCTRL_EXTEND_Msk & ((value) << I2S_SERCTRL_EXTEND_Pos))) +#define I2S_SERCTRL_EXTEND_ZERO_Val 0x0u /**< \brief (I2S_SERCTRL) Extend with zeroes */ +#define I2S_SERCTRL_EXTEND_ONE_Val 0x1u /**< \brief (I2S_SERCTRL) Extend with ones */ +#define I2S_SERCTRL_EXTEND_MSBIT_Val 0x2u /**< \brief (I2S_SERCTRL) Extend with Most Significant Bit */ +#define I2S_SERCTRL_EXTEND_LSBIT_Val 0x3u /**< \brief (I2S_SERCTRL) Extend with Least Significant Bit */ +#define I2S_SERCTRL_EXTEND_ZERO (I2S_SERCTRL_EXTEND_ZERO_Val << I2S_SERCTRL_EXTEND_Pos) +#define I2S_SERCTRL_EXTEND_ONE (I2S_SERCTRL_EXTEND_ONE_Val << I2S_SERCTRL_EXTEND_Pos) +#define I2S_SERCTRL_EXTEND_MSBIT (I2S_SERCTRL_EXTEND_MSBIT_Val << I2S_SERCTRL_EXTEND_Pos) +#define I2S_SERCTRL_EXTEND_LSBIT (I2S_SERCTRL_EXTEND_LSBIT_Val << I2S_SERCTRL_EXTEND_Pos) +#define I2S_SERCTRL_BITREV_Pos 15 /**< \brief (I2S_SERCTRL) Data Formatting Bit Reverse */ +#define I2S_SERCTRL_BITREV (0x1u << I2S_SERCTRL_BITREV_Pos) +#define I2S_SERCTRL_BITREV_MSBIT_Val 0x0u /**< \brief (I2S_SERCTRL) Transfer Data Most Significant Bit (MSB) first (default for I2S protocol) */ +#define I2S_SERCTRL_BITREV_LSBIT_Val 0x1u /**< \brief (I2S_SERCTRL) Transfer Data Least Significant Bit (LSB) first */ +#define I2S_SERCTRL_BITREV_MSBIT (I2S_SERCTRL_BITREV_MSBIT_Val << I2S_SERCTRL_BITREV_Pos) +#define I2S_SERCTRL_BITREV_LSBIT (I2S_SERCTRL_BITREV_LSBIT_Val << I2S_SERCTRL_BITREV_Pos) +#define I2S_SERCTRL_SLOTDIS0_Pos 16 /**< \brief (I2S_SERCTRL) Slot 0 Disabled for this Serializer */ +#define I2S_SERCTRL_SLOTDIS0 (1 << I2S_SERCTRL_SLOTDIS0_Pos) +#define I2S_SERCTRL_SLOTDIS1_Pos 17 /**< \brief (I2S_SERCTRL) Slot 1 Disabled for this Serializer */ +#define I2S_SERCTRL_SLOTDIS1 (1 << I2S_SERCTRL_SLOTDIS1_Pos) +#define I2S_SERCTRL_SLOTDIS2_Pos 18 /**< \brief (I2S_SERCTRL) Slot 2 Disabled for this Serializer */ +#define I2S_SERCTRL_SLOTDIS2 (1 << I2S_SERCTRL_SLOTDIS2_Pos) +#define I2S_SERCTRL_SLOTDIS3_Pos 19 /**< \brief (I2S_SERCTRL) Slot 3 Disabled for this Serializer */ +#define I2S_SERCTRL_SLOTDIS3 (1 << I2S_SERCTRL_SLOTDIS3_Pos) +#define I2S_SERCTRL_SLOTDIS4_Pos 20 /**< \brief (I2S_SERCTRL) Slot 4 Disabled for this Serializer */ +#define I2S_SERCTRL_SLOTDIS4 (1 << I2S_SERCTRL_SLOTDIS4_Pos) +#define I2S_SERCTRL_SLOTDIS5_Pos 21 /**< \brief (I2S_SERCTRL) Slot 5 Disabled for this Serializer */ +#define I2S_SERCTRL_SLOTDIS5 (1 << I2S_SERCTRL_SLOTDIS5_Pos) +#define I2S_SERCTRL_SLOTDIS6_Pos 22 /**< \brief (I2S_SERCTRL) Slot 6 Disabled for this Serializer */ +#define I2S_SERCTRL_SLOTDIS6 (1 << I2S_SERCTRL_SLOTDIS6_Pos) +#define I2S_SERCTRL_SLOTDIS7_Pos 23 /**< \brief (I2S_SERCTRL) Slot 7 Disabled for this Serializer */ +#define I2S_SERCTRL_SLOTDIS7 (1 << I2S_SERCTRL_SLOTDIS7_Pos) +#define I2S_SERCTRL_SLOTDIS_Pos 16 /**< \brief (I2S_SERCTRL) Slot x Disabled for this Serializer */ +#define I2S_SERCTRL_SLOTDIS_Msk (0xFFu << I2S_SERCTRL_SLOTDIS_Pos) +#define I2S_SERCTRL_SLOTDIS(value) ((I2S_SERCTRL_SLOTDIS_Msk & ((value) << I2S_SERCTRL_SLOTDIS_Pos))) +#define I2S_SERCTRL_MONO_Pos 24 /**< \brief (I2S_SERCTRL) Mono Mode */ +#define I2S_SERCTRL_MONO (0x1u << I2S_SERCTRL_MONO_Pos) +#define I2S_SERCTRL_MONO_STEREO_Val 0x0u /**< \brief (I2S_SERCTRL) Normal mode */ +#define I2S_SERCTRL_MONO_MONO_Val 0x1u /**< \brief (I2S_SERCTRL) Left channel data is duplicated to right channel */ +#define I2S_SERCTRL_MONO_STEREO (I2S_SERCTRL_MONO_STEREO_Val << I2S_SERCTRL_MONO_Pos) +#define I2S_SERCTRL_MONO_MONO (I2S_SERCTRL_MONO_MONO_Val << I2S_SERCTRL_MONO_Pos) +#define I2S_SERCTRL_DMA_Pos 25 /**< \brief (I2S_SERCTRL) Single or Multiple DMA Channels */ +#define I2S_SERCTRL_DMA (0x1u << I2S_SERCTRL_DMA_Pos) +#define I2S_SERCTRL_DMA_SINGLE_Val 0x0u /**< \brief (I2S_SERCTRL) Single DMA channel */ +#define I2S_SERCTRL_DMA_MULTIPLE_Val 0x1u /**< \brief (I2S_SERCTRL) One DMA channel per data channel */ +#define I2S_SERCTRL_DMA_SINGLE (I2S_SERCTRL_DMA_SINGLE_Val << I2S_SERCTRL_DMA_Pos) +#define I2S_SERCTRL_DMA_MULTIPLE (I2S_SERCTRL_DMA_MULTIPLE_Val << I2S_SERCTRL_DMA_Pos) +#define I2S_SERCTRL_RXLOOP_Pos 26 /**< \brief (I2S_SERCTRL) Loop-back Test Mode */ +#define I2S_SERCTRL_RXLOOP (0x1u << I2S_SERCTRL_RXLOOP_Pos) +#define I2S_SERCTRL_MASK 0x07FFF7BFu /**< \brief (I2S_SERCTRL) MASK Register */ + +/* -------- I2S_DATA : (I2S Offset: 0x30) (R/W 32) Data n -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DATA:32; /*!< bit: 0..31 Sample Data */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} I2S_DATA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define I2S_DATA_OFFSET 0x30 /**< \brief (I2S_DATA offset) Data n */ +#define I2S_DATA_RESETVALUE 0x00000000 /**< \brief (I2S_DATA reset_value) Data n */ + +#define I2S_DATA_DATA_Pos 0 /**< \brief (I2S_DATA) Sample Data */ +#define I2S_DATA_DATA_Msk (0xFFFFFFFFu << I2S_DATA_DATA_Pos) +#define I2S_DATA_DATA(value) ((I2S_DATA_DATA_Msk & ((value) << I2S_DATA_DATA_Pos))) +#define I2S_DATA_MASK 0xFFFFFFFFu /**< \brief (I2S_DATA) MASK Register */ + +/** \brief I2S hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO I2S_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 8) Control A */ + RoReg8 Reserved1[0x3]; + __IO I2S_CLKCTRL_Type CLKCTRL[2]; /**< \brief Offset: 0x04 (R/W 32) Clock Unit n Control */ + __IO I2S_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x0C (R/W 16) Interrupt Enable Clear */ + RoReg8 Reserved2[0x2]; + __IO I2S_INTENSET_Type INTENSET; /**< \brief Offset: 0x10 (R/W 16) Interrupt Enable Set */ + RoReg8 Reserved3[0x2]; + __IO I2S_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x14 (R/W 16) Interrupt Flag Status and Clear */ + RoReg8 Reserved4[0x2]; + __I I2S_SYNCBUSY_Type SYNCBUSY; /**< \brief Offset: 0x18 (R/ 16) Synchronization Status */ + RoReg8 Reserved5[0x6]; + __IO I2S_SERCTRL_Type SERCTRL[2]; /**< \brief Offset: 0x20 (R/W 32) Serializer n Control */ + RoReg8 Reserved6[0x8]; + __IO I2S_DATA_Type DATA[2]; /**< \brief Offset: 0x30 (R/W 32) Data n */ +} I2s; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_I2S_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/mtb.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/mtb.h new file mode 100644 index 0000000..c8a745c --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/mtb.h @@ -0,0 +1,396 @@ +/** + * \file + * + * \brief Component description for MTB + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_MTB_COMPONENT_ +#define _SAMD21_MTB_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR MTB */ +/* ========================================================================== */ +/** \addtogroup SAMD21_MTB Cortex-M0+ Micro-Trace Buffer */ +/*@{*/ + +#define MTB_U2002 +#define REV_MTB 0x100 + +/* -------- MTB_POSITION : (MTB Offset: 0x000) (R/W 32) MTB Position -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :2; /*!< bit: 0.. 1 Reserved */ + uint32_t WRAP:1; /*!< bit: 2 Pointer Value Wraps */ + uint32_t POINTER:29; /*!< bit: 3..31 Trace Packet Location Pointer */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} MTB_POSITION_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_POSITION_OFFSET 0x000 /**< \brief (MTB_POSITION offset) MTB Position */ + +#define MTB_POSITION_WRAP_Pos 2 /**< \brief (MTB_POSITION) Pointer Value Wraps */ +#define MTB_POSITION_WRAP (0x1u << MTB_POSITION_WRAP_Pos) +#define MTB_POSITION_POINTER_Pos 3 /**< \brief (MTB_POSITION) Trace Packet Location Pointer */ +#define MTB_POSITION_POINTER_Msk (0x1FFFFFFFu << MTB_POSITION_POINTER_Pos) +#define MTB_POSITION_POINTER(value) ((MTB_POSITION_POINTER_Msk & ((value) << MTB_POSITION_POINTER_Pos))) +#define MTB_POSITION_MASK 0xFFFFFFFCu /**< \brief (MTB_POSITION) MASK Register */ + +/* -------- MTB_MASTER : (MTB Offset: 0x004) (R/W 32) MTB Master -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t MASK:5; /*!< bit: 0.. 4 Maximum Value of the Trace Buffer in SRAM */ + uint32_t TSTARTEN:1; /*!< bit: 5 Trace Start Input Enable */ + uint32_t TSTOPEN:1; /*!< bit: 6 Trace Stop Input Enable */ + uint32_t SFRWPRIV:1; /*!< bit: 7 Special Function Register Write Privilege */ + uint32_t RAMPRIV:1; /*!< bit: 8 SRAM Privilege */ + uint32_t HALTREQ:1; /*!< bit: 9 Halt Request */ + uint32_t :21; /*!< bit: 10..30 Reserved */ + uint32_t EN:1; /*!< bit: 31 Main Trace Enable */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} MTB_MASTER_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_MASTER_OFFSET 0x004 /**< \brief (MTB_MASTER offset) MTB Master */ +#define MTB_MASTER_RESETVALUE 0x00000000 /**< \brief (MTB_MASTER reset_value) MTB Master */ + +#define MTB_MASTER_MASK_Pos 0 /**< \brief (MTB_MASTER) Maximum Value of the Trace Buffer in SRAM */ +#define MTB_MASTER_MASK_Msk (0x1Fu << MTB_MASTER_MASK_Pos) +#define MTB_MASTER_MASK(value) ((MTB_MASTER_MASK_Msk & ((value) << MTB_MASTER_MASK_Pos))) +#define MTB_MASTER_TSTARTEN_Pos 5 /**< \brief (MTB_MASTER) Trace Start Input Enable */ +#define MTB_MASTER_TSTARTEN (0x1u << MTB_MASTER_TSTARTEN_Pos) +#define MTB_MASTER_TSTOPEN_Pos 6 /**< \brief (MTB_MASTER) Trace Stop Input Enable */ +#define MTB_MASTER_TSTOPEN (0x1u << MTB_MASTER_TSTOPEN_Pos) +#define MTB_MASTER_SFRWPRIV_Pos 7 /**< \brief (MTB_MASTER) Special Function Register Write Privilege */ +#define MTB_MASTER_SFRWPRIV (0x1u << MTB_MASTER_SFRWPRIV_Pos) +#define MTB_MASTER_RAMPRIV_Pos 8 /**< \brief (MTB_MASTER) SRAM Privilege */ +#define MTB_MASTER_RAMPRIV (0x1u << MTB_MASTER_RAMPRIV_Pos) +#define MTB_MASTER_HALTREQ_Pos 9 /**< \brief (MTB_MASTER) Halt Request */ +#define MTB_MASTER_HALTREQ (0x1u << MTB_MASTER_HALTREQ_Pos) +#define MTB_MASTER_EN_Pos 31 /**< \brief (MTB_MASTER) Main Trace Enable */ +#define MTB_MASTER_EN (0x1u << MTB_MASTER_EN_Pos) +#define MTB_MASTER_MASK_ 0x800003FFu /**< \brief (MTB_MASTER) MASK Register */ + +/* -------- MTB_FLOW : (MTB Offset: 0x008) (R/W 32) MTB Flow -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t AUTOSTOP:1; /*!< bit: 0 Auto Stop Tracing */ + uint32_t AUTOHALT:1; /*!< bit: 1 Auto Halt Request */ + uint32_t :1; /*!< bit: 2 Reserved */ + uint32_t WATERMARK:29; /*!< bit: 3..31 Watermark value */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} MTB_FLOW_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_FLOW_OFFSET 0x008 /**< \brief (MTB_FLOW offset) MTB Flow */ +#define MTB_FLOW_RESETVALUE 0x00000000 /**< \brief (MTB_FLOW reset_value) MTB Flow */ + +#define MTB_FLOW_AUTOSTOP_Pos 0 /**< \brief (MTB_FLOW) Auto Stop Tracing */ +#define MTB_FLOW_AUTOSTOP (0x1u << MTB_FLOW_AUTOSTOP_Pos) +#define MTB_FLOW_AUTOHALT_Pos 1 /**< \brief (MTB_FLOW) Auto Halt Request */ +#define MTB_FLOW_AUTOHALT (0x1u << MTB_FLOW_AUTOHALT_Pos) +#define MTB_FLOW_WATERMARK_Pos 3 /**< \brief (MTB_FLOW) Watermark value */ +#define MTB_FLOW_WATERMARK_Msk (0x1FFFFFFFu << MTB_FLOW_WATERMARK_Pos) +#define MTB_FLOW_WATERMARK(value) ((MTB_FLOW_WATERMARK_Msk & ((value) << MTB_FLOW_WATERMARK_Pos))) +#define MTB_FLOW_MASK 0xFFFFFFFBu /**< \brief (MTB_FLOW) MASK Register */ + +/* -------- MTB_BASE : (MTB Offset: 0x00C) (R/ 32) MTB Base -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_BASE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_BASE_OFFSET 0x00C /**< \brief (MTB_BASE offset) MTB Base */ +#define MTB_BASE_MASK 0xFFFFFFFFu /**< \brief (MTB_BASE) MASK Register */ + +/* -------- MTB_ITCTRL : (MTB Offset: 0xF00) (R/W 32) MTB Integration Mode Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_ITCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_ITCTRL_OFFSET 0xF00 /**< \brief (MTB_ITCTRL offset) MTB Integration Mode Control */ +#define MTB_ITCTRL_MASK 0xFFFFFFFFu /**< \brief (MTB_ITCTRL) MASK Register */ + +/* -------- MTB_CLAIMSET : (MTB Offset: 0xFA0) (R/W 32) MTB Claim Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_CLAIMSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_CLAIMSET_OFFSET 0xFA0 /**< \brief (MTB_CLAIMSET offset) MTB Claim Set */ +#define MTB_CLAIMSET_MASK 0xFFFFFFFFu /**< \brief (MTB_CLAIMSET) MASK Register */ + +/* -------- MTB_CLAIMCLR : (MTB Offset: 0xFA4) (R/W 32) MTB Claim Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_CLAIMCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_CLAIMCLR_OFFSET 0xFA4 /**< \brief (MTB_CLAIMCLR offset) MTB Claim Clear */ +#define MTB_CLAIMCLR_MASK 0xFFFFFFFFu /**< \brief (MTB_CLAIMCLR) MASK Register */ + +/* -------- MTB_LOCKACCESS : (MTB Offset: 0xFB0) (R/W 32) MTB Lock Access -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_LOCKACCESS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_LOCKACCESS_OFFSET 0xFB0 /**< \brief (MTB_LOCKACCESS offset) MTB Lock Access */ +#define MTB_LOCKACCESS_MASK 0xFFFFFFFFu /**< \brief (MTB_LOCKACCESS) MASK Register */ + +/* -------- MTB_LOCKSTATUS : (MTB Offset: 0xFB4) (R/ 32) MTB Lock Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_LOCKSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_LOCKSTATUS_OFFSET 0xFB4 /**< \brief (MTB_LOCKSTATUS offset) MTB Lock Status */ +#define MTB_LOCKSTATUS_MASK 0xFFFFFFFFu /**< \brief (MTB_LOCKSTATUS) MASK Register */ + +/* -------- MTB_AUTHSTATUS : (MTB Offset: 0xFB8) (R/ 32) MTB Authentication Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_AUTHSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_AUTHSTATUS_OFFSET 0xFB8 /**< \brief (MTB_AUTHSTATUS offset) MTB Authentication Status */ +#define MTB_AUTHSTATUS_MASK 0xFFFFFFFFu /**< \brief (MTB_AUTHSTATUS) MASK Register */ + +/* -------- MTB_DEVARCH : (MTB Offset: 0xFBC) (R/ 32) MTB Device Architecture -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_DEVARCH_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_DEVARCH_OFFSET 0xFBC /**< \brief (MTB_DEVARCH offset) MTB Device Architecture */ +#define MTB_DEVARCH_MASK 0xFFFFFFFFu /**< \brief (MTB_DEVARCH) MASK Register */ + +/* -------- MTB_DEVID : (MTB Offset: 0xFC8) (R/ 32) MTB Device Configuration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_DEVID_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_DEVID_OFFSET 0xFC8 /**< \brief (MTB_DEVID offset) MTB Device Configuration */ +#define MTB_DEVID_MASK 0xFFFFFFFFu /**< \brief (MTB_DEVID) MASK Register */ + +/* -------- MTB_DEVTYPE : (MTB Offset: 0xFCC) (R/ 32) MTB Device Type -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_DEVTYPE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_DEVTYPE_OFFSET 0xFCC /**< \brief (MTB_DEVTYPE offset) MTB Device Type */ +#define MTB_DEVTYPE_MASK 0xFFFFFFFFu /**< \brief (MTB_DEVTYPE) MASK Register */ + +/* -------- MTB_PID4 : (MTB Offset: 0xFD0) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_PID4_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_PID4_OFFSET 0xFD0 /**< \brief (MTB_PID4 offset) CoreSight */ +#define MTB_PID4_MASK 0xFFFFFFFFu /**< \brief (MTB_PID4) MASK Register */ + +/* -------- MTB_PID5 : (MTB Offset: 0xFD4) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_PID5_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_PID5_OFFSET 0xFD4 /**< \brief (MTB_PID5 offset) CoreSight */ +#define MTB_PID5_MASK 0xFFFFFFFFu /**< \brief (MTB_PID5) MASK Register */ + +/* -------- MTB_PID6 : (MTB Offset: 0xFD8) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_PID6_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_PID6_OFFSET 0xFD8 /**< \brief (MTB_PID6 offset) CoreSight */ +#define MTB_PID6_MASK 0xFFFFFFFFu /**< \brief (MTB_PID6) MASK Register */ + +/* -------- MTB_PID7 : (MTB Offset: 0xFDC) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_PID7_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_PID7_OFFSET 0xFDC /**< \brief (MTB_PID7 offset) CoreSight */ +#define MTB_PID7_MASK 0xFFFFFFFFu /**< \brief (MTB_PID7) MASK Register */ + +/* -------- MTB_PID0 : (MTB Offset: 0xFE0) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_PID0_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_PID0_OFFSET 0xFE0 /**< \brief (MTB_PID0 offset) CoreSight */ +#define MTB_PID0_MASK 0xFFFFFFFFu /**< \brief (MTB_PID0) MASK Register */ + +/* -------- MTB_PID1 : (MTB Offset: 0xFE4) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_PID1_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_PID1_OFFSET 0xFE4 /**< \brief (MTB_PID1 offset) CoreSight */ +#define MTB_PID1_MASK 0xFFFFFFFFu /**< \brief (MTB_PID1) MASK Register */ + +/* -------- MTB_PID2 : (MTB Offset: 0xFE8) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_PID2_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_PID2_OFFSET 0xFE8 /**< \brief (MTB_PID2 offset) CoreSight */ +#define MTB_PID2_MASK 0xFFFFFFFFu /**< \brief (MTB_PID2) MASK Register */ + +/* -------- MTB_PID3 : (MTB Offset: 0xFEC) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_PID3_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_PID3_OFFSET 0xFEC /**< \brief (MTB_PID3 offset) CoreSight */ +#define MTB_PID3_MASK 0xFFFFFFFFu /**< \brief (MTB_PID3) MASK Register */ + +/* -------- MTB_CID0 : (MTB Offset: 0xFF0) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_CID0_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_CID0_OFFSET 0xFF0 /**< \brief (MTB_CID0 offset) CoreSight */ +#define MTB_CID0_MASK 0xFFFFFFFFu /**< \brief (MTB_CID0) MASK Register */ + +/* -------- MTB_CID1 : (MTB Offset: 0xFF4) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_CID1_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_CID1_OFFSET 0xFF4 /**< \brief (MTB_CID1 offset) CoreSight */ +#define MTB_CID1_MASK 0xFFFFFFFFu /**< \brief (MTB_CID1) MASK Register */ + +/* -------- MTB_CID2 : (MTB Offset: 0xFF8) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_CID2_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_CID2_OFFSET 0xFF8 /**< \brief (MTB_CID2 offset) CoreSight */ +#define MTB_CID2_MASK 0xFFFFFFFFu /**< \brief (MTB_CID2) MASK Register */ + +/* -------- MTB_CID3 : (MTB Offset: 0xFFC) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_CID3_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_CID3_OFFSET 0xFFC /**< \brief (MTB_CID3 offset) CoreSight */ +#define MTB_CID3_MASK 0xFFFFFFFFu /**< \brief (MTB_CID3) MASK Register */ + +/** \brief MTB hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO MTB_POSITION_Type POSITION; /**< \brief Offset: 0x000 (R/W 32) MTB Position */ + __IO MTB_MASTER_Type MASTER; /**< \brief Offset: 0x004 (R/W 32) MTB Master */ + __IO MTB_FLOW_Type FLOW; /**< \brief Offset: 0x008 (R/W 32) MTB Flow */ + __I MTB_BASE_Type BASE; /**< \brief Offset: 0x00C (R/ 32) MTB Base */ + RoReg8 Reserved1[0xEF0]; + __IO MTB_ITCTRL_Type ITCTRL; /**< \brief Offset: 0xF00 (R/W 32) MTB Integration Mode Control */ + RoReg8 Reserved2[0x9C]; + __IO MTB_CLAIMSET_Type CLAIMSET; /**< \brief Offset: 0xFA0 (R/W 32) MTB Claim Set */ + __IO MTB_CLAIMCLR_Type CLAIMCLR; /**< \brief Offset: 0xFA4 (R/W 32) MTB Claim Clear */ + RoReg8 Reserved3[0x8]; + __IO MTB_LOCKACCESS_Type LOCKACCESS; /**< \brief Offset: 0xFB0 (R/W 32) MTB Lock Access */ + __I MTB_LOCKSTATUS_Type LOCKSTATUS; /**< \brief Offset: 0xFB4 (R/ 32) MTB Lock Status */ + __I MTB_AUTHSTATUS_Type AUTHSTATUS; /**< \brief Offset: 0xFB8 (R/ 32) MTB Authentication Status */ + __I MTB_DEVARCH_Type DEVARCH; /**< \brief Offset: 0xFBC (R/ 32) MTB Device Architecture */ + RoReg8 Reserved4[0x8]; + __I MTB_DEVID_Type DEVID; /**< \brief Offset: 0xFC8 (R/ 32) MTB Device Configuration */ + __I MTB_DEVTYPE_Type DEVTYPE; /**< \brief Offset: 0xFCC (R/ 32) MTB Device Type */ + __I MTB_PID4_Type PID4; /**< \brief Offset: 0xFD0 (R/ 32) CoreSight */ + __I MTB_PID5_Type PID5; /**< \brief Offset: 0xFD4 (R/ 32) CoreSight */ + __I MTB_PID6_Type PID6; /**< \brief Offset: 0xFD8 (R/ 32) CoreSight */ + __I MTB_PID7_Type PID7; /**< \brief Offset: 0xFDC (R/ 32) CoreSight */ + __I MTB_PID0_Type PID0; /**< \brief Offset: 0xFE0 (R/ 32) CoreSight */ + __I MTB_PID1_Type PID1; /**< \brief Offset: 0xFE4 (R/ 32) CoreSight */ + __I MTB_PID2_Type PID2; /**< \brief Offset: 0xFE8 (R/ 32) CoreSight */ + __I MTB_PID3_Type PID3; /**< \brief Offset: 0xFEC (R/ 32) CoreSight */ + __I MTB_CID0_Type CID0; /**< \brief Offset: 0xFF0 (R/ 32) CoreSight */ + __I MTB_CID1_Type CID1; /**< \brief Offset: 0xFF4 (R/ 32) CoreSight */ + __I MTB_CID2_Type CID2; /**< \brief Offset: 0xFF8 (R/ 32) CoreSight */ + __I MTB_CID3_Type CID3; /**< \brief Offset: 0xFFC (R/ 32) CoreSight */ +} Mtb; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_MTB_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/nvmctrl.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/nvmctrl.h new file mode 100644 index 0000000..4e3856c --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/nvmctrl.h @@ -0,0 +1,530 @@ +/** + * \file + * + * \brief Component description for NVMCTRL + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_NVMCTRL_COMPONENT_ +#define _SAMD21_NVMCTRL_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR NVMCTRL */ +/* ========================================================================== */ +/** \addtogroup SAMD21_NVMCTRL Non-Volatile Memory Controller */ +/*@{*/ + +#define NVMCTRL_U2207 +#define REV_NVMCTRL 0x106 + +/* -------- NVMCTRL_CTRLA : (NVMCTRL Offset: 0x00) (R/W 16) Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t CMD:7; /*!< bit: 0.. 6 Command */ + uint16_t :1; /*!< bit: 7 Reserved */ + uint16_t CMDEX:8; /*!< bit: 8..15 Command Execution */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} NVMCTRL_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define NVMCTRL_CTRLA_OFFSET 0x00 /**< \brief (NVMCTRL_CTRLA offset) Control A */ +#define NVMCTRL_CTRLA_RESETVALUE 0x0000 /**< \brief (NVMCTRL_CTRLA reset_value) Control A */ + +#define NVMCTRL_CTRLA_CMD_Pos 0 /**< \brief (NVMCTRL_CTRLA) Command */ +#define NVMCTRL_CTRLA_CMD_Msk (0x7Fu << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD(value) ((NVMCTRL_CTRLA_CMD_Msk & ((value) << NVMCTRL_CTRLA_CMD_Pos))) +#define NVMCTRL_CTRLA_CMD_ER_Val 0x2u /**< \brief (NVMCTRL_CTRLA) Erase Row - Erases the row addressed by the ADDR register. */ +#define NVMCTRL_CTRLA_CMD_WP_Val 0x4u /**< \brief (NVMCTRL_CTRLA) Write Page - Writes the contents of the page buffer to the page addressed by the ADDR register. */ +#define NVMCTRL_CTRLA_CMD_EAR_Val 0x5u /**< \brief (NVMCTRL_CTRLA) Erase Auxiliary Row - Erases the auxiliary row addressed by the ADDR register. This command can be given only when the security bit is not set and only to the user configuration row. */ +#define NVMCTRL_CTRLA_CMD_WAP_Val 0x6u /**< \brief (NVMCTRL_CTRLA) Write Auxiliary Page - Writes the contents of the page buffer to the page addressed by the ADDR register. This command can be given only when the security bit is not set and only to the user configuration row. */ +#define NVMCTRL_CTRLA_CMD_SF_Val 0xAu /**< \brief (NVMCTRL_CTRLA) Security Flow Command */ +#define NVMCTRL_CTRLA_CMD_WL_Val 0xFu /**< \brief (NVMCTRL_CTRLA) Write lockbits */ +#define NVMCTRL_CTRLA_CMD_LR_Val 0x40u /**< \brief (NVMCTRL_CTRLA) Lock Region - Locks the region containing the address location in the ADDR register. */ +#define NVMCTRL_CTRLA_CMD_UR_Val 0x41u /**< \brief (NVMCTRL_CTRLA) Unlock Region - Unlocks the region containing the address location in the ADDR register. */ +#define NVMCTRL_CTRLA_CMD_SPRM_Val 0x42u /**< \brief (NVMCTRL_CTRLA) Sets the power reduction mode. */ +#define NVMCTRL_CTRLA_CMD_CPRM_Val 0x43u /**< \brief (NVMCTRL_CTRLA) Clears the power reduction mode. */ +#define NVMCTRL_CTRLA_CMD_PBC_Val 0x44u /**< \brief (NVMCTRL_CTRLA) Page Buffer Clear - Clears the page buffer. */ +#define NVMCTRL_CTRLA_CMD_SSB_Val 0x45u /**< \brief (NVMCTRL_CTRLA) Set Security Bit - Sets the security bit by writing 0x00 to the first byte in the lockbit row. */ +#define NVMCTRL_CTRLA_CMD_INVALL_Val 0x46u /**< \brief (NVMCTRL_CTRLA) Invalidates all cache lines. */ +#define NVMCTRL_CTRLA_CMD_ER (NVMCTRL_CTRLA_CMD_ER_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_WP (NVMCTRL_CTRLA_CMD_WP_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_EAR (NVMCTRL_CTRLA_CMD_EAR_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_WAP (NVMCTRL_CTRLA_CMD_WAP_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_SF (NVMCTRL_CTRLA_CMD_SF_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_WL (NVMCTRL_CTRLA_CMD_WL_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_LR (NVMCTRL_CTRLA_CMD_LR_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_UR (NVMCTRL_CTRLA_CMD_UR_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_SPRM (NVMCTRL_CTRLA_CMD_SPRM_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_CPRM (NVMCTRL_CTRLA_CMD_CPRM_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_PBC (NVMCTRL_CTRLA_CMD_PBC_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_SSB (NVMCTRL_CTRLA_CMD_SSB_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_INVALL (NVMCTRL_CTRLA_CMD_INVALL_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMDEX_Pos 8 /**< \brief (NVMCTRL_CTRLA) Command Execution */ +#define NVMCTRL_CTRLA_CMDEX_Msk (0xFFu << NVMCTRL_CTRLA_CMDEX_Pos) +#define NVMCTRL_CTRLA_CMDEX(value) ((NVMCTRL_CTRLA_CMDEX_Msk & ((value) << NVMCTRL_CTRLA_CMDEX_Pos))) +#define NVMCTRL_CTRLA_CMDEX_KEY_Val 0xA5u /**< \brief (NVMCTRL_CTRLA) Execution Key */ +#define NVMCTRL_CTRLA_CMDEX_KEY (NVMCTRL_CTRLA_CMDEX_KEY_Val << NVMCTRL_CTRLA_CMDEX_Pos) +#define NVMCTRL_CTRLA_MASK 0xFF7Fu /**< \brief (NVMCTRL_CTRLA) MASK Register */ + +/* -------- NVMCTRL_CTRLB : (NVMCTRL Offset: 0x04) (R/W 32) Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :1; /*!< bit: 0 Reserved */ + uint32_t RWS:4; /*!< bit: 1.. 4 NVM Read Wait States */ + uint32_t :2; /*!< bit: 5.. 6 Reserved */ + uint32_t MANW:1; /*!< bit: 7 Manual Write */ + uint32_t SLEEPPRM:2; /*!< bit: 8.. 9 Power Reduction Mode during Sleep */ + uint32_t :6; /*!< bit: 10..15 Reserved */ + uint32_t READMODE:2; /*!< bit: 16..17 NVMCTRL Read Mode */ + uint32_t CACHEDIS:1; /*!< bit: 18 Cache Disable */ + uint32_t :13; /*!< bit: 19..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} NVMCTRL_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define NVMCTRL_CTRLB_OFFSET 0x04 /**< \brief (NVMCTRL_CTRLB offset) Control B */ +#define NVMCTRL_CTRLB_RESETVALUE 0x00000000 /**< \brief (NVMCTRL_CTRLB reset_value) Control B */ + +#define NVMCTRL_CTRLB_RWS_Pos 1 /**< \brief (NVMCTRL_CTRLB) NVM Read Wait States */ +#define NVMCTRL_CTRLB_RWS_Msk (0xFu << NVMCTRL_CTRLB_RWS_Pos) +#define NVMCTRL_CTRLB_RWS(value) ((NVMCTRL_CTRLB_RWS_Msk & ((value) << NVMCTRL_CTRLB_RWS_Pos))) +#define NVMCTRL_CTRLB_RWS_SINGLE_Val 0x0u /**< \brief (NVMCTRL_CTRLB) Single Auto Wait State */ +#define NVMCTRL_CTRLB_RWS_HALF_Val 0x1u /**< \brief (NVMCTRL_CTRLB) Half Auto Wait State */ +#define NVMCTRL_CTRLB_RWS_DUAL_Val 0x2u /**< \brief (NVMCTRL_CTRLB) Dual Auto Wait State */ +#define NVMCTRL_CTRLB_RWS_SINGLE (NVMCTRL_CTRLB_RWS_SINGLE_Val << NVMCTRL_CTRLB_RWS_Pos) +#define NVMCTRL_CTRLB_RWS_HALF (NVMCTRL_CTRLB_RWS_HALF_Val << NVMCTRL_CTRLB_RWS_Pos) +#define NVMCTRL_CTRLB_RWS_DUAL (NVMCTRL_CTRLB_RWS_DUAL_Val << NVMCTRL_CTRLB_RWS_Pos) +#define NVMCTRL_CTRLB_MANW_Pos 7 /**< \brief (NVMCTRL_CTRLB) Manual Write */ +#define NVMCTRL_CTRLB_MANW (0x1u << NVMCTRL_CTRLB_MANW_Pos) +#define NVMCTRL_CTRLB_SLEEPPRM_Pos 8 /**< \brief (NVMCTRL_CTRLB) Power Reduction Mode during Sleep */ +#define NVMCTRL_CTRLB_SLEEPPRM_Msk (0x3u << NVMCTRL_CTRLB_SLEEPPRM_Pos) +#define NVMCTRL_CTRLB_SLEEPPRM(value) ((NVMCTRL_CTRLB_SLEEPPRM_Msk & ((value) << NVMCTRL_CTRLB_SLEEPPRM_Pos))) +#define NVMCTRL_CTRLB_SLEEPPRM_WAKEONACCESS_Val 0x0u /**< \brief (NVMCTRL_CTRLB) NVM block enters low-power mode when entering sleep.NVM block exits low-power mode upon first access. */ +#define NVMCTRL_CTRLB_SLEEPPRM_WAKEUPINSTANT_Val 0x1u /**< \brief (NVMCTRL_CTRLB) NVM block enters low-power mode when entering sleep.NVM block exits low-power mode when exiting sleep. */ +#define NVMCTRL_CTRLB_SLEEPPRM_DISABLED_Val 0x3u /**< \brief (NVMCTRL_CTRLB) Auto power reduction disabled. */ +#define NVMCTRL_CTRLB_SLEEPPRM_WAKEONACCESS (NVMCTRL_CTRLB_SLEEPPRM_WAKEONACCESS_Val << NVMCTRL_CTRLB_SLEEPPRM_Pos) +#define NVMCTRL_CTRLB_SLEEPPRM_WAKEUPINSTANT (NVMCTRL_CTRLB_SLEEPPRM_WAKEUPINSTANT_Val << NVMCTRL_CTRLB_SLEEPPRM_Pos) +#define NVMCTRL_CTRLB_SLEEPPRM_DISABLED (NVMCTRL_CTRLB_SLEEPPRM_DISABLED_Val << NVMCTRL_CTRLB_SLEEPPRM_Pos) +#define NVMCTRL_CTRLB_READMODE_Pos 16 /**< \brief (NVMCTRL_CTRLB) NVMCTRL Read Mode */ +#define NVMCTRL_CTRLB_READMODE_Msk (0x3u << NVMCTRL_CTRLB_READMODE_Pos) +#define NVMCTRL_CTRLB_READMODE(value) ((NVMCTRL_CTRLB_READMODE_Msk & ((value) << NVMCTRL_CTRLB_READMODE_Pos))) +#define NVMCTRL_CTRLB_READMODE_NO_MISS_PENALTY_Val 0x0u /**< \brief (NVMCTRL_CTRLB) The NVM Controller (cache system) does not insert wait states on a cache miss. Gives the best system performance. */ +#define NVMCTRL_CTRLB_READMODE_LOW_POWER_Val 0x1u /**< \brief (NVMCTRL_CTRLB) Reduces power consumption of the cache system, but inserts a wait state each time there is a cache miss. This mode may not be relevant if CPU performance is required, as the application will be stalled and may lead to increase run time. */ +#define NVMCTRL_CTRLB_READMODE_DETERMINISTIC_Val 0x2u /**< \brief (NVMCTRL_CTRLB) The cache system ensures that a cache hit or miss takes the same amount of time, determined by the number of programmed flash wait states. This mode can be used for real-time applications that require deterministic execution timings. */ +#define NVMCTRL_CTRLB_READMODE_NO_MISS_PENALTY (NVMCTRL_CTRLB_READMODE_NO_MISS_PENALTY_Val << NVMCTRL_CTRLB_READMODE_Pos) +#define NVMCTRL_CTRLB_READMODE_LOW_POWER (NVMCTRL_CTRLB_READMODE_LOW_POWER_Val << NVMCTRL_CTRLB_READMODE_Pos) +#define NVMCTRL_CTRLB_READMODE_DETERMINISTIC (NVMCTRL_CTRLB_READMODE_DETERMINISTIC_Val << NVMCTRL_CTRLB_READMODE_Pos) +#define NVMCTRL_CTRLB_CACHEDIS_Pos 18 /**< \brief (NVMCTRL_CTRLB) Cache Disable */ +#define NVMCTRL_CTRLB_CACHEDIS (0x1u << NVMCTRL_CTRLB_CACHEDIS_Pos) +#define NVMCTRL_CTRLB_MASK 0x0007039Eu /**< \brief (NVMCTRL_CTRLB) MASK Register */ + +/* -------- NVMCTRL_PARAM : (NVMCTRL Offset: 0x08) (R/W 32) NVM Parameter -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t NVMP:16; /*!< bit: 0..15 NVM Pages */ + uint32_t PSZ:3; /*!< bit: 16..18 Page Size */ + uint32_t :13; /*!< bit: 19..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} NVMCTRL_PARAM_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define NVMCTRL_PARAM_OFFSET 0x08 /**< \brief (NVMCTRL_PARAM offset) NVM Parameter */ +#define NVMCTRL_PARAM_RESETVALUE 0x00000000 /**< \brief (NVMCTRL_PARAM reset_value) NVM Parameter */ + +#define NVMCTRL_PARAM_NVMP_Pos 0 /**< \brief (NVMCTRL_PARAM) NVM Pages */ +#define NVMCTRL_PARAM_NVMP_Msk (0xFFFFu << NVMCTRL_PARAM_NVMP_Pos) +#define NVMCTRL_PARAM_NVMP(value) ((NVMCTRL_PARAM_NVMP_Msk & ((value) << NVMCTRL_PARAM_NVMP_Pos))) +#define NVMCTRL_PARAM_PSZ_Pos 16 /**< \brief (NVMCTRL_PARAM) Page Size */ +#define NVMCTRL_PARAM_PSZ_Msk (0x7u << NVMCTRL_PARAM_PSZ_Pos) +#define NVMCTRL_PARAM_PSZ(value) ((NVMCTRL_PARAM_PSZ_Msk & ((value) << NVMCTRL_PARAM_PSZ_Pos))) +#define NVMCTRL_PARAM_PSZ_8_Val 0x0u /**< \brief (NVMCTRL_PARAM) 8 bytes */ +#define NVMCTRL_PARAM_PSZ_16_Val 0x1u /**< \brief (NVMCTRL_PARAM) 16 bytes */ +#define NVMCTRL_PARAM_PSZ_32_Val 0x2u /**< \brief (NVMCTRL_PARAM) 32 bytes */ +#define NVMCTRL_PARAM_PSZ_64_Val 0x3u /**< \brief (NVMCTRL_PARAM) 64 bytes */ +#define NVMCTRL_PARAM_PSZ_128_Val 0x4u /**< \brief (NVMCTRL_PARAM) 128 bytes */ +#define NVMCTRL_PARAM_PSZ_256_Val 0x5u /**< \brief (NVMCTRL_PARAM) 256 bytes */ +#define NVMCTRL_PARAM_PSZ_512_Val 0x6u /**< \brief (NVMCTRL_PARAM) 512 bytes */ +#define NVMCTRL_PARAM_PSZ_1024_Val 0x7u /**< \brief (NVMCTRL_PARAM) 1024 bytes */ +#define NVMCTRL_PARAM_PSZ_8 (NVMCTRL_PARAM_PSZ_8_Val << NVMCTRL_PARAM_PSZ_Pos) +#define NVMCTRL_PARAM_PSZ_16 (NVMCTRL_PARAM_PSZ_16_Val << NVMCTRL_PARAM_PSZ_Pos) +#define NVMCTRL_PARAM_PSZ_32 (NVMCTRL_PARAM_PSZ_32_Val << NVMCTRL_PARAM_PSZ_Pos) +#define NVMCTRL_PARAM_PSZ_64 (NVMCTRL_PARAM_PSZ_64_Val << NVMCTRL_PARAM_PSZ_Pos) +#define NVMCTRL_PARAM_PSZ_128 (NVMCTRL_PARAM_PSZ_128_Val << NVMCTRL_PARAM_PSZ_Pos) +#define NVMCTRL_PARAM_PSZ_256 (NVMCTRL_PARAM_PSZ_256_Val << NVMCTRL_PARAM_PSZ_Pos) +#define NVMCTRL_PARAM_PSZ_512 (NVMCTRL_PARAM_PSZ_512_Val << NVMCTRL_PARAM_PSZ_Pos) +#define NVMCTRL_PARAM_PSZ_1024 (NVMCTRL_PARAM_PSZ_1024_Val << NVMCTRL_PARAM_PSZ_Pos) +#define NVMCTRL_PARAM_MASK 0x0007FFFFu /**< \brief (NVMCTRL_PARAM) MASK Register */ + +/* -------- NVMCTRL_INTENCLR : (NVMCTRL Offset: 0x0C) (R/W 8) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t READY:1; /*!< bit: 0 NVM Ready Interrupt Enable */ + uint8_t ERROR:1; /*!< bit: 1 Error Interrupt Enable */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} NVMCTRL_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define NVMCTRL_INTENCLR_OFFSET 0x0C /**< \brief (NVMCTRL_INTENCLR offset) Interrupt Enable Clear */ +#define NVMCTRL_INTENCLR_RESETVALUE 0x00 /**< \brief (NVMCTRL_INTENCLR reset_value) Interrupt Enable Clear */ + +#define NVMCTRL_INTENCLR_READY_Pos 0 /**< \brief (NVMCTRL_INTENCLR) NVM Ready Interrupt Enable */ +#define NVMCTRL_INTENCLR_READY (0x1u << NVMCTRL_INTENCLR_READY_Pos) +#define NVMCTRL_INTENCLR_ERROR_Pos 1 /**< \brief (NVMCTRL_INTENCLR) Error Interrupt Enable */ +#define NVMCTRL_INTENCLR_ERROR (0x1u << NVMCTRL_INTENCLR_ERROR_Pos) +#define NVMCTRL_INTENCLR_MASK 0x03u /**< \brief (NVMCTRL_INTENCLR) MASK Register */ + +/* -------- NVMCTRL_INTENSET : (NVMCTRL Offset: 0x10) (R/W 8) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t READY:1; /*!< bit: 0 NVM Ready Interrupt Enable */ + uint8_t ERROR:1; /*!< bit: 1 Error Interrupt Enable */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} NVMCTRL_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define NVMCTRL_INTENSET_OFFSET 0x10 /**< \brief (NVMCTRL_INTENSET offset) Interrupt Enable Set */ +#define NVMCTRL_INTENSET_RESETVALUE 0x00 /**< \brief (NVMCTRL_INTENSET reset_value) Interrupt Enable Set */ + +#define NVMCTRL_INTENSET_READY_Pos 0 /**< \brief (NVMCTRL_INTENSET) NVM Ready Interrupt Enable */ +#define NVMCTRL_INTENSET_READY (0x1u << NVMCTRL_INTENSET_READY_Pos) +#define NVMCTRL_INTENSET_ERROR_Pos 1 /**< \brief (NVMCTRL_INTENSET) Error Interrupt Enable */ +#define NVMCTRL_INTENSET_ERROR (0x1u << NVMCTRL_INTENSET_ERROR_Pos) +#define NVMCTRL_INTENSET_MASK 0x03u /**< \brief (NVMCTRL_INTENSET) MASK Register */ + +/* -------- NVMCTRL_INTFLAG : (NVMCTRL Offset: 0x14) (R/W 8) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t READY:1; /*!< bit: 0 NVM Ready */ + uint8_t ERROR:1; /*!< bit: 1 Error */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} NVMCTRL_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define NVMCTRL_INTFLAG_OFFSET 0x14 /**< \brief (NVMCTRL_INTFLAG offset) Interrupt Flag Status and Clear */ +#define NVMCTRL_INTFLAG_RESETVALUE 0x00 /**< \brief (NVMCTRL_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define NVMCTRL_INTFLAG_READY_Pos 0 /**< \brief (NVMCTRL_INTFLAG) NVM Ready */ +#define NVMCTRL_INTFLAG_READY (0x1u << NVMCTRL_INTFLAG_READY_Pos) +#define NVMCTRL_INTFLAG_ERROR_Pos 1 /**< \brief (NVMCTRL_INTFLAG) Error */ +#define NVMCTRL_INTFLAG_ERROR (0x1u << NVMCTRL_INTFLAG_ERROR_Pos) +#define NVMCTRL_INTFLAG_MASK 0x03u /**< \brief (NVMCTRL_INTFLAG) MASK Register */ + +/* -------- NVMCTRL_STATUS : (NVMCTRL Offset: 0x18) (R/W 16) Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t PRM:1; /*!< bit: 0 Power Reduction Mode */ + uint16_t LOAD:1; /*!< bit: 1 NVM Page Buffer Active Loading */ + uint16_t PROGE:1; /*!< bit: 2 Programming Error Status */ + uint16_t LOCKE:1; /*!< bit: 3 Lock Error Status */ + uint16_t NVME:1; /*!< bit: 4 NVM Error */ + uint16_t :3; /*!< bit: 5.. 7 Reserved */ + uint16_t SB:1; /*!< bit: 8 Security Bit Status */ + uint16_t :7; /*!< bit: 9..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} NVMCTRL_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define NVMCTRL_STATUS_OFFSET 0x18 /**< \brief (NVMCTRL_STATUS offset) Status */ +#define NVMCTRL_STATUS_RESETVALUE 0x0000 /**< \brief (NVMCTRL_STATUS reset_value) Status */ + +#define NVMCTRL_STATUS_PRM_Pos 0 /**< \brief (NVMCTRL_STATUS) Power Reduction Mode */ +#define NVMCTRL_STATUS_PRM (0x1u << NVMCTRL_STATUS_PRM_Pos) +#define NVMCTRL_STATUS_LOAD_Pos 1 /**< \brief (NVMCTRL_STATUS) NVM Page Buffer Active Loading */ +#define NVMCTRL_STATUS_LOAD (0x1u << NVMCTRL_STATUS_LOAD_Pos) +#define NVMCTRL_STATUS_PROGE_Pos 2 /**< \brief (NVMCTRL_STATUS) Programming Error Status */ +#define NVMCTRL_STATUS_PROGE (0x1u << NVMCTRL_STATUS_PROGE_Pos) +#define NVMCTRL_STATUS_LOCKE_Pos 3 /**< \brief (NVMCTRL_STATUS) Lock Error Status */ +#define NVMCTRL_STATUS_LOCKE (0x1u << NVMCTRL_STATUS_LOCKE_Pos) +#define NVMCTRL_STATUS_NVME_Pos 4 /**< \brief (NVMCTRL_STATUS) NVM Error */ +#define NVMCTRL_STATUS_NVME (0x1u << NVMCTRL_STATUS_NVME_Pos) +#define NVMCTRL_STATUS_SB_Pos 8 /**< \brief (NVMCTRL_STATUS) Security Bit Status */ +#define NVMCTRL_STATUS_SB (0x1u << NVMCTRL_STATUS_SB_Pos) +#define NVMCTRL_STATUS_MASK 0x011Fu /**< \brief (NVMCTRL_STATUS) MASK Register */ + +/* -------- NVMCTRL_ADDR : (NVMCTRL Offset: 0x1C) (R/W 32) Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t ADDR:22; /*!< bit: 0..21 NVM Address */ + uint32_t :10; /*!< bit: 22..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} NVMCTRL_ADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define NVMCTRL_ADDR_OFFSET 0x1C /**< \brief (NVMCTRL_ADDR offset) Address */ +#define NVMCTRL_ADDR_RESETVALUE 0x00000000 /**< \brief (NVMCTRL_ADDR reset_value) Address */ + +#define NVMCTRL_ADDR_ADDR_Pos 0 /**< \brief (NVMCTRL_ADDR) NVM Address */ +#define NVMCTRL_ADDR_ADDR_Msk (0x3FFFFFu << NVMCTRL_ADDR_ADDR_Pos) +#define NVMCTRL_ADDR_ADDR(value) ((NVMCTRL_ADDR_ADDR_Msk & ((value) << NVMCTRL_ADDR_ADDR_Pos))) +#define NVMCTRL_ADDR_MASK 0x003FFFFFu /**< \brief (NVMCTRL_ADDR) MASK Register */ + +/* -------- NVMCTRL_LOCK : (NVMCTRL Offset: 0x20) (R/W 16) Lock Section -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t LOCK:16; /*!< bit: 0..15 Region Lock Bits */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} NVMCTRL_LOCK_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define NVMCTRL_LOCK_OFFSET 0x20 /**< \brief (NVMCTRL_LOCK offset) Lock Section */ + +#define NVMCTRL_LOCK_LOCK_Pos 0 /**< \brief (NVMCTRL_LOCK) Region Lock Bits */ +#define NVMCTRL_LOCK_LOCK_Msk (0xFFFFu << NVMCTRL_LOCK_LOCK_Pos) +#define NVMCTRL_LOCK_LOCK(value) ((NVMCTRL_LOCK_LOCK_Msk & ((value) << NVMCTRL_LOCK_LOCK_Pos))) +#define NVMCTRL_LOCK_MASK 0xFFFFu /**< \brief (NVMCTRL_LOCK) MASK Register */ + +/** \brief NVMCTRL APB hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO NVMCTRL_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 16) Control A */ + RoReg8 Reserved1[0x2]; + __IO NVMCTRL_CTRLB_Type CTRLB; /**< \brief Offset: 0x04 (R/W 32) Control B */ + __IO NVMCTRL_PARAM_Type PARAM; /**< \brief Offset: 0x08 (R/W 32) NVM Parameter */ + __IO NVMCTRL_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x0C (R/W 8) Interrupt Enable Clear */ + RoReg8 Reserved2[0x3]; + __IO NVMCTRL_INTENSET_Type INTENSET; /**< \brief Offset: 0x10 (R/W 8) Interrupt Enable Set */ + RoReg8 Reserved3[0x3]; + __IO NVMCTRL_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x14 (R/W 8) Interrupt Flag Status and Clear */ + RoReg8 Reserved4[0x3]; + __IO NVMCTRL_STATUS_Type STATUS; /**< \brief Offset: 0x18 (R/W 16) Status */ + RoReg8 Reserved5[0x2]; + __IO NVMCTRL_ADDR_Type ADDR; /**< \brief Offset: 0x1C (R/W 32) Address */ + __IO NVMCTRL_LOCK_Type LOCK; /**< \brief Offset: 0x20 (R/W 16) Lock Section */ +} Nvmctrl; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +#define SECTION_NVMCTRL_CAL +#define SECTION_NVMCTRL_LOCKBIT +#define SECTION_NVMCTRL_OTP1 +#define SECTION_NVMCTRL_OTP2 +#define SECTION_NVMCTRL_OTP4 +#define SECTION_NVMCTRL_TEMP_LOG +#define SECTION_NVMCTRL_USER + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR NON-VOLATILE FUSES */ +/* ************************************************************************** */ +/** \addtogroup fuses_api Peripheral Software API */ +/*@{*/ + + +#define ADC_FUSES_BIASCAL_ADDR (NVMCTRL_OTP4 + 4) +#define ADC_FUSES_BIASCAL_Pos 3 /**< \brief (NVMCTRL_OTP4) ADC Bias Calibration */ +#define ADC_FUSES_BIASCAL_Msk (0x7u << ADC_FUSES_BIASCAL_Pos) +#define ADC_FUSES_BIASCAL(value) ((ADC_FUSES_BIASCAL_Msk & ((value) << ADC_FUSES_BIASCAL_Pos))) + +#define ADC_FUSES_LINEARITY_0_ADDR NVMCTRL_OTP4 +#define ADC_FUSES_LINEARITY_0_Pos 27 /**< \brief (NVMCTRL_OTP4) ADC Linearity bits 4:0 */ +#define ADC_FUSES_LINEARITY_0_Msk (0x1Fu << ADC_FUSES_LINEARITY_0_Pos) +#define ADC_FUSES_LINEARITY_0(value) ((ADC_FUSES_LINEARITY_0_Msk & ((value) << ADC_FUSES_LINEARITY_0_Pos))) + +#define ADC_FUSES_LINEARITY_1_ADDR (NVMCTRL_OTP4 + 4) +#define ADC_FUSES_LINEARITY_1_Pos 0 /**< \brief (NVMCTRL_OTP4) ADC Linearity bits 7:5 */ +#define ADC_FUSES_LINEARITY_1_Msk (0x7u << ADC_FUSES_LINEARITY_1_Pos) +#define ADC_FUSES_LINEARITY_1(value) ((ADC_FUSES_LINEARITY_1_Msk & ((value) << ADC_FUSES_LINEARITY_1_Pos))) + +#define NVMCTRL_FUSES_BOOTPROT_ADDR NVMCTRL_USER +#define NVMCTRL_FUSES_BOOTPROT_Pos 0 /**< \brief (NVMCTRL_USER) Bootloader Size */ +#define NVMCTRL_FUSES_BOOTPROT_Msk (0x7u << NVMCTRL_FUSES_BOOTPROT_Pos) +#define NVMCTRL_FUSES_BOOTPROT(value) ((NVMCTRL_FUSES_BOOTPROT_Msk & ((value) << NVMCTRL_FUSES_BOOTPROT_Pos))) + +#define NVMCTRL_FUSES_EEPROM_SIZE_ADDR NVMCTRL_USER +#define NVMCTRL_FUSES_EEPROM_SIZE_Pos 4 /**< \brief (NVMCTRL_USER) EEPROM Size */ +#define NVMCTRL_FUSES_EEPROM_SIZE_Msk (0x7u << NVMCTRL_FUSES_EEPROM_SIZE_Pos) +#define NVMCTRL_FUSES_EEPROM_SIZE(value) ((NVMCTRL_FUSES_EEPROM_SIZE_Msk & ((value) << NVMCTRL_FUSES_EEPROM_SIZE_Pos))) + +#define NVMCTRL_FUSES_HOT_ADC_VAL_ADDR (NVMCTRL_TEMP_LOG + 4) +#define NVMCTRL_FUSES_HOT_ADC_VAL_Pos 20 /**< \brief (NVMCTRL_TEMP_LOG) 12-bit ADC conversion at hot temperature */ +#define NVMCTRL_FUSES_HOT_ADC_VAL_Msk (0xFFFu << NVMCTRL_FUSES_HOT_ADC_VAL_Pos) +#define NVMCTRL_FUSES_HOT_ADC_VAL(value) ((NVMCTRL_FUSES_HOT_ADC_VAL_Msk & ((value) << NVMCTRL_FUSES_HOT_ADC_VAL_Pos))) + +#define NVMCTRL_FUSES_HOT_INT1V_VAL_ADDR (NVMCTRL_TEMP_LOG + 4) +#define NVMCTRL_FUSES_HOT_INT1V_VAL_Pos 0 /**< \brief (NVMCTRL_TEMP_LOG) 2's complement of the internal 1V reference drift at hot temperature (versus a 1.0 centered value) */ +#define NVMCTRL_FUSES_HOT_INT1V_VAL_Msk (0xFFu << NVMCTRL_FUSES_HOT_INT1V_VAL_Pos) +#define NVMCTRL_FUSES_HOT_INT1V_VAL(value) ((NVMCTRL_FUSES_HOT_INT1V_VAL_Msk & ((value) << NVMCTRL_FUSES_HOT_INT1V_VAL_Pos))) + +#define NVMCTRL_FUSES_HOT_TEMP_VAL_DEC_ADDR NVMCTRL_TEMP_LOG +#define NVMCTRL_FUSES_HOT_TEMP_VAL_DEC_Pos 20 /**< \brief (NVMCTRL_TEMP_LOG) Decimal part of hot temperature */ +#define NVMCTRL_FUSES_HOT_TEMP_VAL_DEC_Msk (0xFu << NVMCTRL_FUSES_HOT_TEMP_VAL_DEC_Pos) +#define NVMCTRL_FUSES_HOT_TEMP_VAL_DEC(value) ((NVMCTRL_FUSES_HOT_TEMP_VAL_DEC_Msk & ((value) << NVMCTRL_FUSES_HOT_TEMP_VAL_DEC_Pos))) + +#define NVMCTRL_FUSES_HOT_TEMP_VAL_INT_ADDR NVMCTRL_TEMP_LOG +#define NVMCTRL_FUSES_HOT_TEMP_VAL_INT_Pos 12 /**< \brief (NVMCTRL_TEMP_LOG) Integer part of hot temperature in oC */ +#define NVMCTRL_FUSES_HOT_TEMP_VAL_INT_Msk (0xFFu << NVMCTRL_FUSES_HOT_TEMP_VAL_INT_Pos) +#define NVMCTRL_FUSES_HOT_TEMP_VAL_INT(value) ((NVMCTRL_FUSES_HOT_TEMP_VAL_INT_Msk & ((value) << NVMCTRL_FUSES_HOT_TEMP_VAL_INT_Pos))) + +#define NVMCTRL_FUSES_NVMP_ADDR NVMCTRL_OTP1 +#define NVMCTRL_FUSES_NVMP_Pos 16 /**< \brief (NVMCTRL_OTP1) Number of NVM Pages */ +#define NVMCTRL_FUSES_NVMP_Msk (0xFFFFu << NVMCTRL_FUSES_NVMP_Pos) +#define NVMCTRL_FUSES_NVMP(value) ((NVMCTRL_FUSES_NVMP_Msk & ((value) << NVMCTRL_FUSES_NVMP_Pos))) + +#define NVMCTRL_FUSES_NVM_LOCK_ADDR NVMCTRL_OTP1 +#define NVMCTRL_FUSES_NVM_LOCK_Pos 0 /**< \brief (NVMCTRL_OTP1) NVM Lock */ +#define NVMCTRL_FUSES_NVM_LOCK_Msk (0xFFu << NVMCTRL_FUSES_NVM_LOCK_Pos) +#define NVMCTRL_FUSES_NVM_LOCK(value) ((NVMCTRL_FUSES_NVM_LOCK_Msk & ((value) << NVMCTRL_FUSES_NVM_LOCK_Pos))) + +#define NVMCTRL_FUSES_PSZ_ADDR NVMCTRL_OTP1 +#define NVMCTRL_FUSES_PSZ_Pos 8 /**< \brief (NVMCTRL_OTP1) NVM Page Size */ +#define NVMCTRL_FUSES_PSZ_Msk (0xFu << NVMCTRL_FUSES_PSZ_Pos) +#define NVMCTRL_FUSES_PSZ(value) ((NVMCTRL_FUSES_PSZ_Msk & ((value) << NVMCTRL_FUSES_PSZ_Pos))) + +#define NVMCTRL_FUSES_REGION_LOCKS_ADDR (NVMCTRL_USER + 4) +#define NVMCTRL_FUSES_REGION_LOCKS_Pos 16 /**< \brief (NVMCTRL_USER) NVM Region Locks */ +#define NVMCTRL_FUSES_REGION_LOCKS_Msk (0xFFFFu << NVMCTRL_FUSES_REGION_LOCKS_Pos) +#define NVMCTRL_FUSES_REGION_LOCKS(value) ((NVMCTRL_FUSES_REGION_LOCKS_Msk & ((value) << NVMCTRL_FUSES_REGION_LOCKS_Pos))) + +#define NVMCTRL_FUSES_ROOM_ADC_VAL_ADDR (NVMCTRL_TEMP_LOG + 4) +#define NVMCTRL_FUSES_ROOM_ADC_VAL_Pos 8 /**< \brief (NVMCTRL_TEMP_LOG) 12-bit ADC conversion at room temperature */ +#define NVMCTRL_FUSES_ROOM_ADC_VAL_Msk (0xFFFu << NVMCTRL_FUSES_ROOM_ADC_VAL_Pos) +#define NVMCTRL_FUSES_ROOM_ADC_VAL(value) ((NVMCTRL_FUSES_ROOM_ADC_VAL_Msk & ((value) << NVMCTRL_FUSES_ROOM_ADC_VAL_Pos))) + +#define NVMCTRL_FUSES_ROOM_INT1V_VAL_ADDR NVMCTRL_TEMP_LOG +#define NVMCTRL_FUSES_ROOM_INT1V_VAL_Pos 24 /**< \brief (NVMCTRL_TEMP_LOG) 2's complement of the internal 1V reference drift at room temperature (versus a 1.0 centered value) */ +#define NVMCTRL_FUSES_ROOM_INT1V_VAL_Msk (0xFFu << NVMCTRL_FUSES_ROOM_INT1V_VAL_Pos) +#define NVMCTRL_FUSES_ROOM_INT1V_VAL(value) ((NVMCTRL_FUSES_ROOM_INT1V_VAL_Msk & ((value) << NVMCTRL_FUSES_ROOM_INT1V_VAL_Pos))) + +#define NVMCTRL_FUSES_ROOM_TEMP_VAL_DEC_ADDR NVMCTRL_TEMP_LOG +#define NVMCTRL_FUSES_ROOM_TEMP_VAL_DEC_Pos 8 /**< \brief (NVMCTRL_TEMP_LOG) Decimal part of room temperature */ +#define NVMCTRL_FUSES_ROOM_TEMP_VAL_DEC_Msk (0xFu << NVMCTRL_FUSES_ROOM_TEMP_VAL_DEC_Pos) +#define NVMCTRL_FUSES_ROOM_TEMP_VAL_DEC(value) ((NVMCTRL_FUSES_ROOM_TEMP_VAL_DEC_Msk & ((value) << NVMCTRL_FUSES_ROOM_TEMP_VAL_DEC_Pos))) + +#define NVMCTRL_FUSES_ROOM_TEMP_VAL_INT_ADDR NVMCTRL_TEMP_LOG +#define NVMCTRL_FUSES_ROOM_TEMP_VAL_INT_Pos 0 /**< \brief (NVMCTRL_TEMP_LOG) Integer part of room temperature in oC */ +#define NVMCTRL_FUSES_ROOM_TEMP_VAL_INT_Msk (0xFFu << NVMCTRL_FUSES_ROOM_TEMP_VAL_INT_Pos) +#define NVMCTRL_FUSES_ROOM_TEMP_VAL_INT(value) ((NVMCTRL_FUSES_ROOM_TEMP_VAL_INT_Msk & ((value) << NVMCTRL_FUSES_ROOM_TEMP_VAL_INT_Pos))) + +#define SYSCTRL_FUSES_BOD33USERLEVEL_ADDR NVMCTRL_USER +#define SYSCTRL_FUSES_BOD33USERLEVEL_Pos 8 /**< \brief (NVMCTRL_USER) BOD33 User Level */ +#define SYSCTRL_FUSES_BOD33USERLEVEL_Msk (0x3Fu << SYSCTRL_FUSES_BOD33USERLEVEL_Pos) +#define SYSCTRL_FUSES_BOD33USERLEVEL(value) ((SYSCTRL_FUSES_BOD33USERLEVEL_Msk & ((value) << SYSCTRL_FUSES_BOD33USERLEVEL_Pos))) + +#define SYSCTRL_FUSES_BOD33_ACTION_ADDR NVMCTRL_USER +#define SYSCTRL_FUSES_BOD33_ACTION_Pos 15 /**< \brief (NVMCTRL_USER) BOD33 Action */ +#define SYSCTRL_FUSES_BOD33_ACTION_Msk (0x3u << SYSCTRL_FUSES_BOD33_ACTION_Pos) +#define SYSCTRL_FUSES_BOD33_ACTION(value) ((SYSCTRL_FUSES_BOD33_ACTION_Msk & ((value) << SYSCTRL_FUSES_BOD33_ACTION_Pos))) + +#define SYSCTRL_FUSES_BOD33_EN_ADDR NVMCTRL_USER +#define SYSCTRL_FUSES_BOD33_EN_Pos 14 /**< \brief (NVMCTRL_USER) BOD33 Enable */ +#define SYSCTRL_FUSES_BOD33_EN_Msk (0x1u << SYSCTRL_FUSES_BOD33_EN_Pos) + +#define SYSCTRL_FUSES_BOD33_HYST_ADDR (NVMCTRL_USER + 4) +#define SYSCTRL_FUSES_BOD33_HYST_Pos 8 /**< \brief (NVMCTRL_USER) BOD33 Hysteresis */ +#define SYSCTRL_FUSES_BOD33_HYST_Msk (0x1u << SYSCTRL_FUSES_BOD33_HYST_Pos) + +#define SYSCTRL_FUSES_DFLL48M_COARSE_CAL_ADDR (NVMCTRL_OTP4 + 4) +#define SYSCTRL_FUSES_DFLL48M_COARSE_CAL_Pos 26 /**< \brief (NVMCTRL_OTP4) DFLL48M Coarse Calibration */ +#define SYSCTRL_FUSES_DFLL48M_COARSE_CAL_Msk (0x3Fu << SYSCTRL_FUSES_DFLL48M_COARSE_CAL_Pos) +#define SYSCTRL_FUSES_DFLL48M_COARSE_CAL(value) ((SYSCTRL_FUSES_DFLL48M_COARSE_CAL_Msk & ((value) << SYSCTRL_FUSES_DFLL48M_COARSE_CAL_Pos))) + +#define SYSCTRL_FUSES_OSC32K_CAL_ADDR (NVMCTRL_OTP4 + 4) +#define SYSCTRL_FUSES_OSC32K_CAL_Pos 6 /**< \brief (NVMCTRL_OTP4) OSC32K Calibration */ +#define SYSCTRL_FUSES_OSC32K_CAL_Msk (0x7Fu << SYSCTRL_FUSES_OSC32K_CAL_Pos) +#define SYSCTRL_FUSES_OSC32K_CAL(value) ((SYSCTRL_FUSES_OSC32K_CAL_Msk & ((value) << SYSCTRL_FUSES_OSC32K_CAL_Pos))) + +#define USB_FUSES_TRANSN_ADDR (NVMCTRL_OTP4 + 4) +#define USB_FUSES_TRANSN_Pos 13 /**< \brief (NVMCTRL_OTP4) USB pad Transn calibration */ +#define USB_FUSES_TRANSN_Msk (0x1Fu << USB_FUSES_TRANSN_Pos) +#define USB_FUSES_TRANSN(value) ((USB_FUSES_TRANSN_Msk & ((value) << USB_FUSES_TRANSN_Pos))) + +#define USB_FUSES_TRANSP_ADDR (NVMCTRL_OTP4 + 4) +#define USB_FUSES_TRANSP_Pos 18 /**< \brief (NVMCTRL_OTP4) USB pad Transp calibration */ +#define USB_FUSES_TRANSP_Msk (0x1Fu << USB_FUSES_TRANSP_Pos) +#define USB_FUSES_TRANSP(value) ((USB_FUSES_TRANSP_Msk & ((value) << USB_FUSES_TRANSP_Pos))) + +#define USB_FUSES_TRIM_ADDR (NVMCTRL_OTP4 + 4) +#define USB_FUSES_TRIM_Pos 23 /**< \brief (NVMCTRL_OTP4) USB pad Trim calibration */ +#define USB_FUSES_TRIM_Msk (0x7u << USB_FUSES_TRIM_Pos) +#define USB_FUSES_TRIM(value) ((USB_FUSES_TRIM_Msk & ((value) << USB_FUSES_TRIM_Pos))) + +#define WDT_FUSES_ALWAYSON_ADDR NVMCTRL_USER +#define WDT_FUSES_ALWAYSON_Pos 26 /**< \brief (NVMCTRL_USER) WDT Always On */ +#define WDT_FUSES_ALWAYSON_Msk (0x1u << WDT_FUSES_ALWAYSON_Pos) + +#define WDT_FUSES_ENABLE_ADDR NVMCTRL_USER +#define WDT_FUSES_ENABLE_Pos 25 /**< \brief (NVMCTRL_USER) WDT Enable */ +#define WDT_FUSES_ENABLE_Msk (0x1u << WDT_FUSES_ENABLE_Pos) + +#define WDT_FUSES_EWOFFSET_ADDR (NVMCTRL_USER + 4) +#define WDT_FUSES_EWOFFSET_Pos 3 /**< \brief (NVMCTRL_USER) WDT Early Warning Offset */ +#define WDT_FUSES_EWOFFSET_Msk (0xFu << WDT_FUSES_EWOFFSET_Pos) +#define WDT_FUSES_EWOFFSET(value) ((WDT_FUSES_EWOFFSET_Msk & ((value) << WDT_FUSES_EWOFFSET_Pos))) + +#define WDT_FUSES_PER_ADDR NVMCTRL_USER +#define WDT_FUSES_PER_Pos 27 /**< \brief (NVMCTRL_USER) WDT Period */ +#define WDT_FUSES_PER_Msk (0xFu << WDT_FUSES_PER_Pos) +#define WDT_FUSES_PER(value) ((WDT_FUSES_PER_Msk & ((value) << WDT_FUSES_PER_Pos))) + +#define WDT_FUSES_WEN_ADDR (NVMCTRL_USER + 4) +#define WDT_FUSES_WEN_Pos 7 /**< \brief (NVMCTRL_USER) WDT Window Mode Enable */ +#define WDT_FUSES_WEN_Msk (0x1u << WDT_FUSES_WEN_Pos) + +#define WDT_FUSES_WINDOW_0_ADDR NVMCTRL_USER +#define WDT_FUSES_WINDOW_0_Pos 31 /**< \brief (NVMCTRL_USER) WDT Window bit 0 */ +#define WDT_FUSES_WINDOW_0_Msk (0x1u << WDT_FUSES_WINDOW_0_Pos) + +#define WDT_FUSES_WINDOW_1_ADDR (NVMCTRL_USER + 4) +#define WDT_FUSES_WINDOW_1_Pos 0 /**< \brief (NVMCTRL_USER) WDT Window bits 3:1 */ +#define WDT_FUSES_WINDOW_1_Msk (0x7u << WDT_FUSES_WINDOW_1_Pos) +#define WDT_FUSES_WINDOW_1(value) ((WDT_FUSES_WINDOW_1_Msk & ((value) << WDT_FUSES_WINDOW_1_Pos))) + +/*@}*/ + +#endif /* _SAMD21_NVMCTRL_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/pac.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/pac.h new file mode 100644 index 0000000..c8d2c78 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/pac.h @@ -0,0 +1,104 @@ +/** + * \file + * + * \brief Component description for PAC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_PAC_COMPONENT_ +#define _SAMD21_PAC_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR PAC */ +/* ========================================================================== */ +/** \addtogroup SAMD21_PAC Peripheral Access Controller */ +/*@{*/ + +#define PAC_U2211 +#define REV_PAC 0x101 + +/* -------- PAC_WPCLR : (PAC Offset: 0x0) (R/W 32) Write Protection Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :1; /*!< bit: 0 Reserved */ + uint32_t WP:31; /*!< bit: 1..31 Write Protection Clear */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PAC_WPCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PAC_WPCLR_OFFSET 0x0 /**< \brief (PAC_WPCLR offset) Write Protection Clear */ +#define PAC_WPCLR_RESETVALUE 0x00000000 /**< \brief (PAC_WPCLR reset_value) Write Protection Clear */ + +#define PAC_WPCLR_WP_Pos 1 /**< \brief (PAC_WPCLR) Write Protection Clear */ +#define PAC_WPCLR_WP_Msk (0x7FFFFFFFu << PAC_WPCLR_WP_Pos) +#define PAC_WPCLR_WP(value) ((PAC_WPCLR_WP_Msk & ((value) << PAC_WPCLR_WP_Pos))) +#define PAC_WPCLR_MASK 0xFFFFFFFEu /**< \brief (PAC_WPCLR) MASK Register */ + +/* -------- PAC_WPSET : (PAC Offset: 0x4) (R/W 32) Write Protection Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :1; /*!< bit: 0 Reserved */ + uint32_t WP:31; /*!< bit: 1..31 Write Protection Set */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PAC_WPSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PAC_WPSET_OFFSET 0x4 /**< \brief (PAC_WPSET offset) Write Protection Set */ +#define PAC_WPSET_RESETVALUE 0x00000000 /**< \brief (PAC_WPSET reset_value) Write Protection Set */ + +#define PAC_WPSET_WP_Pos 1 /**< \brief (PAC_WPSET) Write Protection Set */ +#define PAC_WPSET_WP_Msk (0x7FFFFFFFu << PAC_WPSET_WP_Pos) +#define PAC_WPSET_WP(value) ((PAC_WPSET_WP_Msk & ((value) << PAC_WPSET_WP_Pos))) +#define PAC_WPSET_MASK 0xFFFFFFFEu /**< \brief (PAC_WPSET) MASK Register */ + +/** \brief PAC hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO PAC_WPCLR_Type WPCLR; /**< \brief Offset: 0x0 (R/W 32) Write Protection Clear */ + __IO PAC_WPSET_Type WPSET; /**< \brief Offset: 0x4 (R/W 32) Write Protection Set */ +} Pac; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_PAC_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/pm.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/pm.h new file mode 100644 index 0000000..a7bdc4f --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/pm.h @@ -0,0 +1,530 @@ +/** + * \file + * + * \brief Component description for PM + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_PM_COMPONENT_ +#define _SAMD21_PM_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR PM */ +/* ========================================================================== */ +/** \addtogroup SAMD21_PM Power Manager */ +/*@{*/ + +#define PM_U2206 +#define REV_PM 0x201 + +/* -------- PM_CTRL : (PM Offset: 0x00) (R/W 8) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint8_t reg; /*!< Type used for register access */ +} PM_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_CTRL_OFFSET 0x00 /**< \brief (PM_CTRL offset) Control */ +#define PM_CTRL_RESETVALUE 0x00 /**< \brief (PM_CTRL reset_value) Control */ + +#define PM_CTRL_MASK 0x00u /**< \brief (PM_CTRL) MASK Register */ + +/* -------- PM_SLEEP : (PM Offset: 0x01) (R/W 8) Sleep Mode -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t IDLE:2; /*!< bit: 0.. 1 Idle Mode Configuration */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PM_SLEEP_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_SLEEP_OFFSET 0x01 /**< \brief (PM_SLEEP offset) Sleep Mode */ +#define PM_SLEEP_RESETVALUE 0x00 /**< \brief (PM_SLEEP reset_value) Sleep Mode */ + +#define PM_SLEEP_IDLE_Pos 0 /**< \brief (PM_SLEEP) Idle Mode Configuration */ +#define PM_SLEEP_IDLE_Msk (0x3u << PM_SLEEP_IDLE_Pos) +#define PM_SLEEP_IDLE(value) ((PM_SLEEP_IDLE_Msk & ((value) << PM_SLEEP_IDLE_Pos))) +#define PM_SLEEP_IDLE_CPU_Val 0x0u /**< \brief (PM_SLEEP) The CPU clock domain is stopped */ +#define PM_SLEEP_IDLE_AHB_Val 0x1u /**< \brief (PM_SLEEP) The CPU and AHB clock domains are stopped */ +#define PM_SLEEP_IDLE_APB_Val 0x2u /**< \brief (PM_SLEEP) The CPU, AHB and APB clock domains are stopped */ +#define PM_SLEEP_IDLE_CPU (PM_SLEEP_IDLE_CPU_Val << PM_SLEEP_IDLE_Pos) +#define PM_SLEEP_IDLE_AHB (PM_SLEEP_IDLE_AHB_Val << PM_SLEEP_IDLE_Pos) +#define PM_SLEEP_IDLE_APB (PM_SLEEP_IDLE_APB_Val << PM_SLEEP_IDLE_Pos) +#define PM_SLEEP_MASK 0x03u /**< \brief (PM_SLEEP) MASK Register */ + +/* -------- PM_CPUSEL : (PM Offset: 0x08) (R/W 8) CPU Clock Select -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CPUDIV:3; /*!< bit: 0.. 2 CPU Prescaler Selection */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PM_CPUSEL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_CPUSEL_OFFSET 0x08 /**< \brief (PM_CPUSEL offset) CPU Clock Select */ +#define PM_CPUSEL_RESETVALUE 0x00 /**< \brief (PM_CPUSEL reset_value) CPU Clock Select */ + +#define PM_CPUSEL_CPUDIV_Pos 0 /**< \brief (PM_CPUSEL) CPU Prescaler Selection */ +#define PM_CPUSEL_CPUDIV_Msk (0x7u << PM_CPUSEL_CPUDIV_Pos) +#define PM_CPUSEL_CPUDIV(value) ((PM_CPUSEL_CPUDIV_Msk & ((value) << PM_CPUSEL_CPUDIV_Pos))) +#define PM_CPUSEL_CPUDIV_DIV1_Val 0x0u /**< \brief (PM_CPUSEL) Divide by 1 */ +#define PM_CPUSEL_CPUDIV_DIV2_Val 0x1u /**< \brief (PM_CPUSEL) Divide by 2 */ +#define PM_CPUSEL_CPUDIV_DIV4_Val 0x2u /**< \brief (PM_CPUSEL) Divide by 4 */ +#define PM_CPUSEL_CPUDIV_DIV8_Val 0x3u /**< \brief (PM_CPUSEL) Divide by 8 */ +#define PM_CPUSEL_CPUDIV_DIV16_Val 0x4u /**< \brief (PM_CPUSEL) Divide by 16 */ +#define PM_CPUSEL_CPUDIV_DIV32_Val 0x5u /**< \brief (PM_CPUSEL) Divide by 32 */ +#define PM_CPUSEL_CPUDIV_DIV64_Val 0x6u /**< \brief (PM_CPUSEL) Divide by 64 */ +#define PM_CPUSEL_CPUDIV_DIV128_Val 0x7u /**< \brief (PM_CPUSEL) Divide by 128 */ +#define PM_CPUSEL_CPUDIV_DIV1 (PM_CPUSEL_CPUDIV_DIV1_Val << PM_CPUSEL_CPUDIV_Pos) +#define PM_CPUSEL_CPUDIV_DIV2 (PM_CPUSEL_CPUDIV_DIV2_Val << PM_CPUSEL_CPUDIV_Pos) +#define PM_CPUSEL_CPUDIV_DIV4 (PM_CPUSEL_CPUDIV_DIV4_Val << PM_CPUSEL_CPUDIV_Pos) +#define PM_CPUSEL_CPUDIV_DIV8 (PM_CPUSEL_CPUDIV_DIV8_Val << PM_CPUSEL_CPUDIV_Pos) +#define PM_CPUSEL_CPUDIV_DIV16 (PM_CPUSEL_CPUDIV_DIV16_Val << PM_CPUSEL_CPUDIV_Pos) +#define PM_CPUSEL_CPUDIV_DIV32 (PM_CPUSEL_CPUDIV_DIV32_Val << PM_CPUSEL_CPUDIV_Pos) +#define PM_CPUSEL_CPUDIV_DIV64 (PM_CPUSEL_CPUDIV_DIV64_Val << PM_CPUSEL_CPUDIV_Pos) +#define PM_CPUSEL_CPUDIV_DIV128 (PM_CPUSEL_CPUDIV_DIV128_Val << PM_CPUSEL_CPUDIV_Pos) +#define PM_CPUSEL_MASK 0x07u /**< \brief (PM_CPUSEL) MASK Register */ + +/* -------- PM_APBASEL : (PM Offset: 0x09) (R/W 8) APBA Clock Select -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t APBADIV:3; /*!< bit: 0.. 2 APBA Prescaler Selection */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PM_APBASEL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_APBASEL_OFFSET 0x09 /**< \brief (PM_APBASEL offset) APBA Clock Select */ +#define PM_APBASEL_RESETVALUE 0x00 /**< \brief (PM_APBASEL reset_value) APBA Clock Select */ + +#define PM_APBASEL_APBADIV_Pos 0 /**< \brief (PM_APBASEL) APBA Prescaler Selection */ +#define PM_APBASEL_APBADIV_Msk (0x7u << PM_APBASEL_APBADIV_Pos) +#define PM_APBASEL_APBADIV(value) ((PM_APBASEL_APBADIV_Msk & ((value) << PM_APBASEL_APBADIV_Pos))) +#define PM_APBASEL_APBADIV_DIV1_Val 0x0u /**< \brief (PM_APBASEL) Divide by 1 */ +#define PM_APBASEL_APBADIV_DIV2_Val 0x1u /**< \brief (PM_APBASEL) Divide by 2 */ +#define PM_APBASEL_APBADIV_DIV4_Val 0x2u /**< \brief (PM_APBASEL) Divide by 4 */ +#define PM_APBASEL_APBADIV_DIV8_Val 0x3u /**< \brief (PM_APBASEL) Divide by 8 */ +#define PM_APBASEL_APBADIV_DIV16_Val 0x4u /**< \brief (PM_APBASEL) Divide by 16 */ +#define PM_APBASEL_APBADIV_DIV32_Val 0x5u /**< \brief (PM_APBASEL) Divide by 32 */ +#define PM_APBASEL_APBADIV_DIV64_Val 0x6u /**< \brief (PM_APBASEL) Divide by 64 */ +#define PM_APBASEL_APBADIV_DIV128_Val 0x7u /**< \brief (PM_APBASEL) Divide by 128 */ +#define PM_APBASEL_APBADIV_DIV1 (PM_APBASEL_APBADIV_DIV1_Val << PM_APBASEL_APBADIV_Pos) +#define PM_APBASEL_APBADIV_DIV2 (PM_APBASEL_APBADIV_DIV2_Val << PM_APBASEL_APBADIV_Pos) +#define PM_APBASEL_APBADIV_DIV4 (PM_APBASEL_APBADIV_DIV4_Val << PM_APBASEL_APBADIV_Pos) +#define PM_APBASEL_APBADIV_DIV8 (PM_APBASEL_APBADIV_DIV8_Val << PM_APBASEL_APBADIV_Pos) +#define PM_APBASEL_APBADIV_DIV16 (PM_APBASEL_APBADIV_DIV16_Val << PM_APBASEL_APBADIV_Pos) +#define PM_APBASEL_APBADIV_DIV32 (PM_APBASEL_APBADIV_DIV32_Val << PM_APBASEL_APBADIV_Pos) +#define PM_APBASEL_APBADIV_DIV64 (PM_APBASEL_APBADIV_DIV64_Val << PM_APBASEL_APBADIV_Pos) +#define PM_APBASEL_APBADIV_DIV128 (PM_APBASEL_APBADIV_DIV128_Val << PM_APBASEL_APBADIV_Pos) +#define PM_APBASEL_MASK 0x07u /**< \brief (PM_APBASEL) MASK Register */ + +/* -------- PM_APBBSEL : (PM Offset: 0x0A) (R/W 8) APBB Clock Select -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t APBBDIV:3; /*!< bit: 0.. 2 APBB Prescaler Selection */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PM_APBBSEL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_APBBSEL_OFFSET 0x0A /**< \brief (PM_APBBSEL offset) APBB Clock Select */ +#define PM_APBBSEL_RESETVALUE 0x00 /**< \brief (PM_APBBSEL reset_value) APBB Clock Select */ + +#define PM_APBBSEL_APBBDIV_Pos 0 /**< \brief (PM_APBBSEL) APBB Prescaler Selection */ +#define PM_APBBSEL_APBBDIV_Msk (0x7u << PM_APBBSEL_APBBDIV_Pos) +#define PM_APBBSEL_APBBDIV(value) ((PM_APBBSEL_APBBDIV_Msk & ((value) << PM_APBBSEL_APBBDIV_Pos))) +#define PM_APBBSEL_APBBDIV_DIV1_Val 0x0u /**< \brief (PM_APBBSEL) Divide by 1 */ +#define PM_APBBSEL_APBBDIV_DIV2_Val 0x1u /**< \brief (PM_APBBSEL) Divide by 2 */ +#define PM_APBBSEL_APBBDIV_DIV4_Val 0x2u /**< \brief (PM_APBBSEL) Divide by 4 */ +#define PM_APBBSEL_APBBDIV_DIV8_Val 0x3u /**< \brief (PM_APBBSEL) Divide by 8 */ +#define PM_APBBSEL_APBBDIV_DIV16_Val 0x4u /**< \brief (PM_APBBSEL) Divide by 16 */ +#define PM_APBBSEL_APBBDIV_DIV32_Val 0x5u /**< \brief (PM_APBBSEL) Divide by 32 */ +#define PM_APBBSEL_APBBDIV_DIV64_Val 0x6u /**< \brief (PM_APBBSEL) Divide by 64 */ +#define PM_APBBSEL_APBBDIV_DIV128_Val 0x7u /**< \brief (PM_APBBSEL) Divide by 128 */ +#define PM_APBBSEL_APBBDIV_DIV1 (PM_APBBSEL_APBBDIV_DIV1_Val << PM_APBBSEL_APBBDIV_Pos) +#define PM_APBBSEL_APBBDIV_DIV2 (PM_APBBSEL_APBBDIV_DIV2_Val << PM_APBBSEL_APBBDIV_Pos) +#define PM_APBBSEL_APBBDIV_DIV4 (PM_APBBSEL_APBBDIV_DIV4_Val << PM_APBBSEL_APBBDIV_Pos) +#define PM_APBBSEL_APBBDIV_DIV8 (PM_APBBSEL_APBBDIV_DIV8_Val << PM_APBBSEL_APBBDIV_Pos) +#define PM_APBBSEL_APBBDIV_DIV16 (PM_APBBSEL_APBBDIV_DIV16_Val << PM_APBBSEL_APBBDIV_Pos) +#define PM_APBBSEL_APBBDIV_DIV32 (PM_APBBSEL_APBBDIV_DIV32_Val << PM_APBBSEL_APBBDIV_Pos) +#define PM_APBBSEL_APBBDIV_DIV64 (PM_APBBSEL_APBBDIV_DIV64_Val << PM_APBBSEL_APBBDIV_Pos) +#define PM_APBBSEL_APBBDIV_DIV128 (PM_APBBSEL_APBBDIV_DIV128_Val << PM_APBBSEL_APBBDIV_Pos) +#define PM_APBBSEL_MASK 0x07u /**< \brief (PM_APBBSEL) MASK Register */ + +/* -------- PM_APBCSEL : (PM Offset: 0x0B) (R/W 8) APBC Clock Select -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t APBCDIV:3; /*!< bit: 0.. 2 APBC Prescaler Selection */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PM_APBCSEL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_APBCSEL_OFFSET 0x0B /**< \brief (PM_APBCSEL offset) APBC Clock Select */ +#define PM_APBCSEL_RESETVALUE 0x00 /**< \brief (PM_APBCSEL reset_value) APBC Clock Select */ + +#define PM_APBCSEL_APBCDIV_Pos 0 /**< \brief (PM_APBCSEL) APBC Prescaler Selection */ +#define PM_APBCSEL_APBCDIV_Msk (0x7u << PM_APBCSEL_APBCDIV_Pos) +#define PM_APBCSEL_APBCDIV(value) ((PM_APBCSEL_APBCDIV_Msk & ((value) << PM_APBCSEL_APBCDIV_Pos))) +#define PM_APBCSEL_APBCDIV_DIV1_Val 0x0u /**< \brief (PM_APBCSEL) Divide by 1 */ +#define PM_APBCSEL_APBCDIV_DIV2_Val 0x1u /**< \brief (PM_APBCSEL) Divide by 2 */ +#define PM_APBCSEL_APBCDIV_DIV4_Val 0x2u /**< \brief (PM_APBCSEL) Divide by 4 */ +#define PM_APBCSEL_APBCDIV_DIV8_Val 0x3u /**< \brief (PM_APBCSEL) Divide by 8 */ +#define PM_APBCSEL_APBCDIV_DIV16_Val 0x4u /**< \brief (PM_APBCSEL) Divide by 16 */ +#define PM_APBCSEL_APBCDIV_DIV32_Val 0x5u /**< \brief (PM_APBCSEL) Divide by 32 */ +#define PM_APBCSEL_APBCDIV_DIV64_Val 0x6u /**< \brief (PM_APBCSEL) Divide by 64 */ +#define PM_APBCSEL_APBCDIV_DIV128_Val 0x7u /**< \brief (PM_APBCSEL) Divide by 128 */ +#define PM_APBCSEL_APBCDIV_DIV1 (PM_APBCSEL_APBCDIV_DIV1_Val << PM_APBCSEL_APBCDIV_Pos) +#define PM_APBCSEL_APBCDIV_DIV2 (PM_APBCSEL_APBCDIV_DIV2_Val << PM_APBCSEL_APBCDIV_Pos) +#define PM_APBCSEL_APBCDIV_DIV4 (PM_APBCSEL_APBCDIV_DIV4_Val << PM_APBCSEL_APBCDIV_Pos) +#define PM_APBCSEL_APBCDIV_DIV8 (PM_APBCSEL_APBCDIV_DIV8_Val << PM_APBCSEL_APBCDIV_Pos) +#define PM_APBCSEL_APBCDIV_DIV16 (PM_APBCSEL_APBCDIV_DIV16_Val << PM_APBCSEL_APBCDIV_Pos) +#define PM_APBCSEL_APBCDIV_DIV32 (PM_APBCSEL_APBCDIV_DIV32_Val << PM_APBCSEL_APBCDIV_Pos) +#define PM_APBCSEL_APBCDIV_DIV64 (PM_APBCSEL_APBCDIV_DIV64_Val << PM_APBCSEL_APBCDIV_Pos) +#define PM_APBCSEL_APBCDIV_DIV128 (PM_APBCSEL_APBCDIV_DIV128_Val << PM_APBCSEL_APBCDIV_Pos) +#define PM_APBCSEL_MASK 0x07u /**< \brief (PM_APBCSEL) MASK Register */ + +/* -------- PM_AHBMASK : (PM Offset: 0x14) (R/W 32) AHB Mask -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t HPB0:1; /*!< bit: 0 HPB0 AHB Clock Mask */ + uint32_t HPB1:1; /*!< bit: 1 HPB1 AHB Clock Mask */ + uint32_t HPB2:1; /*!< bit: 2 HPB2 AHB Clock Mask */ + uint32_t DSU:1; /*!< bit: 3 DSU AHB Clock Mask */ + uint32_t NVMCTRL:1; /*!< bit: 4 NVMCTRL AHB Clock Mask */ + uint32_t DMAC:1; /*!< bit: 5 DMAC AHB Clock Mask */ + uint32_t USB:1; /*!< bit: 6 USB AHB Clock Mask */ + uint32_t :25; /*!< bit: 7..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PM_AHBMASK_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_AHBMASK_OFFSET 0x14 /**< \brief (PM_AHBMASK offset) AHB Mask */ +#define PM_AHBMASK_RESETVALUE 0x0000007F /**< \brief (PM_AHBMASK reset_value) AHB Mask */ + +#define PM_AHBMASK_HPB0_Pos 0 /**< \brief (PM_AHBMASK) HPB0 AHB Clock Mask */ +#define PM_AHBMASK_HPB0 (0x1u << PM_AHBMASK_HPB0_Pos) +#define PM_AHBMASK_HPB1_Pos 1 /**< \brief (PM_AHBMASK) HPB1 AHB Clock Mask */ +#define PM_AHBMASK_HPB1 (0x1u << PM_AHBMASK_HPB1_Pos) +#define PM_AHBMASK_HPB2_Pos 2 /**< \brief (PM_AHBMASK) HPB2 AHB Clock Mask */ +#define PM_AHBMASK_HPB2 (0x1u << PM_AHBMASK_HPB2_Pos) +#define PM_AHBMASK_DSU_Pos 3 /**< \brief (PM_AHBMASK) DSU AHB Clock Mask */ +#define PM_AHBMASK_DSU (0x1u << PM_AHBMASK_DSU_Pos) +#define PM_AHBMASK_NVMCTRL_Pos 4 /**< \brief (PM_AHBMASK) NVMCTRL AHB Clock Mask */ +#define PM_AHBMASK_NVMCTRL (0x1u << PM_AHBMASK_NVMCTRL_Pos) +#define PM_AHBMASK_DMAC_Pos 5 /**< \brief (PM_AHBMASK) DMAC AHB Clock Mask */ +#define PM_AHBMASK_DMAC (0x1u << PM_AHBMASK_DMAC_Pos) +#define PM_AHBMASK_USB_Pos 6 /**< \brief (PM_AHBMASK) USB AHB Clock Mask */ +#define PM_AHBMASK_USB (0x1u << PM_AHBMASK_USB_Pos) +#define PM_AHBMASK_MASK 0x0000007Fu /**< \brief (PM_AHBMASK) MASK Register */ + +/* -------- PM_APBAMASK : (PM Offset: 0x18) (R/W 32) APBA Mask -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PAC0:1; /*!< bit: 0 PAC0 APB Clock Enable */ + uint32_t PM:1; /*!< bit: 1 PM APB Clock Enable */ + uint32_t SYSCTRL:1; /*!< bit: 2 SYSCTRL APB Clock Enable */ + uint32_t GCLK:1; /*!< bit: 3 GCLK APB Clock Enable */ + uint32_t WDT:1; /*!< bit: 4 WDT APB Clock Enable */ + uint32_t RTC:1; /*!< bit: 5 RTC APB Clock Enable */ + uint32_t EIC:1; /*!< bit: 6 EIC APB Clock Enable */ + uint32_t :25; /*!< bit: 7..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PM_APBAMASK_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_APBAMASK_OFFSET 0x18 /**< \brief (PM_APBAMASK offset) APBA Mask */ +#define PM_APBAMASK_RESETVALUE 0x0000007F /**< \brief (PM_APBAMASK reset_value) APBA Mask */ + +#define PM_APBAMASK_PAC0_Pos 0 /**< \brief (PM_APBAMASK) PAC0 APB Clock Enable */ +#define PM_APBAMASK_PAC0 (0x1u << PM_APBAMASK_PAC0_Pos) +#define PM_APBAMASK_PM_Pos 1 /**< \brief (PM_APBAMASK) PM APB Clock Enable */ +#define PM_APBAMASK_PM (0x1u << PM_APBAMASK_PM_Pos) +#define PM_APBAMASK_SYSCTRL_Pos 2 /**< \brief (PM_APBAMASK) SYSCTRL APB Clock Enable */ +#define PM_APBAMASK_SYSCTRL (0x1u << PM_APBAMASK_SYSCTRL_Pos) +#define PM_APBAMASK_GCLK_Pos 3 /**< \brief (PM_APBAMASK) GCLK APB Clock Enable */ +#define PM_APBAMASK_GCLK (0x1u << PM_APBAMASK_GCLK_Pos) +#define PM_APBAMASK_WDT_Pos 4 /**< \brief (PM_APBAMASK) WDT APB Clock Enable */ +#define PM_APBAMASK_WDT (0x1u << PM_APBAMASK_WDT_Pos) +#define PM_APBAMASK_RTC_Pos 5 /**< \brief (PM_APBAMASK) RTC APB Clock Enable */ +#define PM_APBAMASK_RTC (0x1u << PM_APBAMASK_RTC_Pos) +#define PM_APBAMASK_EIC_Pos 6 /**< \brief (PM_APBAMASK) EIC APB Clock Enable */ +#define PM_APBAMASK_EIC (0x1u << PM_APBAMASK_EIC_Pos) +#define PM_APBAMASK_MASK 0x0000007Fu /**< \brief (PM_APBAMASK) MASK Register */ + +/* -------- PM_APBBMASK : (PM Offset: 0x1C) (R/W 32) APBB Mask -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PAC1:1; /*!< bit: 0 PAC1 APB Clock Enable */ + uint32_t DSU:1; /*!< bit: 1 DSU APB Clock Enable */ + uint32_t NVMCTRL:1; /*!< bit: 2 NVMCTRL APB Clock Enable */ + uint32_t PORT:1; /*!< bit: 3 PORT APB Clock Enable */ + uint32_t DMAC:1; /*!< bit: 4 DMAC APB Clock Enable */ + uint32_t USB:1; /*!< bit: 5 USB APB Clock Enable */ + uint32_t :26; /*!< bit: 6..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PM_APBBMASK_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_APBBMASK_OFFSET 0x1C /**< \brief (PM_APBBMASK offset) APBB Mask */ +#define PM_APBBMASK_RESETVALUE 0x0000007F /**< \brief (PM_APBBMASK reset_value) APBB Mask */ + +#define PM_APBBMASK_PAC1_Pos 0 /**< \brief (PM_APBBMASK) PAC1 APB Clock Enable */ +#define PM_APBBMASK_PAC1 (0x1u << PM_APBBMASK_PAC1_Pos) +#define PM_APBBMASK_DSU_Pos 1 /**< \brief (PM_APBBMASK) DSU APB Clock Enable */ +#define PM_APBBMASK_DSU (0x1u << PM_APBBMASK_DSU_Pos) +#define PM_APBBMASK_NVMCTRL_Pos 2 /**< \brief (PM_APBBMASK) NVMCTRL APB Clock Enable */ +#define PM_APBBMASK_NVMCTRL (0x1u << PM_APBBMASK_NVMCTRL_Pos) +#define PM_APBBMASK_PORT_Pos 3 /**< \brief (PM_APBBMASK) PORT APB Clock Enable */ +#define PM_APBBMASK_PORT (0x1u << PM_APBBMASK_PORT_Pos) +#define PM_APBBMASK_DMAC_Pos 4 /**< \brief (PM_APBBMASK) DMAC APB Clock Enable */ +#define PM_APBBMASK_DMAC (0x1u << PM_APBBMASK_DMAC_Pos) +#define PM_APBBMASK_USB_Pos 5 /**< \brief (PM_APBBMASK) USB APB Clock Enable */ +#define PM_APBBMASK_USB (0x1u << PM_APBBMASK_USB_Pos) +#define PM_APBBMASK_MASK 0x0000003Fu /**< \brief (PM_APBBMASK) MASK Register */ + +/* -------- PM_APBCMASK : (PM Offset: 0x20) (R/W 32) APBC Mask -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PAC2:1; /*!< bit: 0 PAC2 APB Clock Enable */ + uint32_t EVSYS:1; /*!< bit: 1 EVSYS APB Clock Enable */ + uint32_t SERCOM0:1; /*!< bit: 2 SERCOM0 APB Clock Enable */ + uint32_t SERCOM1:1; /*!< bit: 3 SERCOM1 APB Clock Enable */ + uint32_t SERCOM2:1; /*!< bit: 4 SERCOM2 APB Clock Enable */ + uint32_t SERCOM3:1; /*!< bit: 5 SERCOM3 APB Clock Enable */ + uint32_t SERCOM4:1; /*!< bit: 6 SERCOM4 APB Clock Enable */ + uint32_t SERCOM5:1; /*!< bit: 7 SERCOM5 APB Clock Enable */ + uint32_t TCC0:1; /*!< bit: 8 TCC0 APB Clock Enable */ + uint32_t TCC1:1; /*!< bit: 9 TCC1 APB Clock Enable */ + uint32_t TCC2:1; /*!< bit: 10 TCC2 APB Clock Enable */ + uint32_t TC3:1; /*!< bit: 11 TC3 APB Clock Enable */ + uint32_t TC4:1; /*!< bit: 12 TC4 APB Clock Enable */ + uint32_t TC5:1; /*!< bit: 13 TC5 APB Clock Enable */ + uint32_t TC6:1; /*!< bit: 14 TC6 APB Clock Enable */ + uint32_t TC7:1; /*!< bit: 15 TC7 APB Clock Enable */ + uint32_t ADC:1; /*!< bit: 16 ADC APB Clock Enable */ + uint32_t AC:1; /*!< bit: 17 AC APB Clock Enable */ + uint32_t DAC:1; /*!< bit: 18 DAC APB Clock Enable */ + uint32_t PTC:1; /*!< bit: 19 PTC APB Clock Enable */ + uint32_t I2S:1; /*!< bit: 20 I2S APB Clock Enable */ + uint32_t :11; /*!< bit: 21..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PM_APBCMASK_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_APBCMASK_OFFSET 0x20 /**< \brief (PM_APBCMASK offset) APBC Mask */ +#define PM_APBCMASK_RESETVALUE 0x00010000 /**< \brief (PM_APBCMASK reset_value) APBC Mask */ + +#define PM_APBCMASK_PAC2_Pos 0 /**< \brief (PM_APBCMASK) PAC2 APB Clock Enable */ +#define PM_APBCMASK_PAC2 (0x1u << PM_APBCMASK_PAC2_Pos) +#define PM_APBCMASK_EVSYS_Pos 1 /**< \brief (PM_APBCMASK) EVSYS APB Clock Enable */ +#define PM_APBCMASK_EVSYS (0x1u << PM_APBCMASK_EVSYS_Pos) +#define PM_APBCMASK_SERCOM0_Pos 2 /**< \brief (PM_APBCMASK) SERCOM0 APB Clock Enable */ +#define PM_APBCMASK_SERCOM0 (0x1u << PM_APBCMASK_SERCOM0_Pos) +#define PM_APBCMASK_SERCOM1_Pos 3 /**< \brief (PM_APBCMASK) SERCOM1 APB Clock Enable */ +#define PM_APBCMASK_SERCOM1 (0x1u << PM_APBCMASK_SERCOM1_Pos) +#define PM_APBCMASK_SERCOM2_Pos 4 /**< \brief (PM_APBCMASK) SERCOM2 APB Clock Enable */ +#define PM_APBCMASK_SERCOM2 (0x1u << PM_APBCMASK_SERCOM2_Pos) +#define PM_APBCMASK_SERCOM3_Pos 5 /**< \brief (PM_APBCMASK) SERCOM3 APB Clock Enable */ +#define PM_APBCMASK_SERCOM3 (0x1u << PM_APBCMASK_SERCOM3_Pos) +#define PM_APBCMASK_SERCOM4_Pos 6 /**< \brief (PM_APBCMASK) SERCOM4 APB Clock Enable */ +#define PM_APBCMASK_SERCOM4 (0x1u << PM_APBCMASK_SERCOM4_Pos) +#define PM_APBCMASK_SERCOM5_Pos 7 /**< \brief (PM_APBCMASK) SERCOM5 APB Clock Enable */ +#define PM_APBCMASK_SERCOM5 (0x1u << PM_APBCMASK_SERCOM5_Pos) +#define PM_APBCMASK_TCC0_Pos 8 /**< \brief (PM_APBCMASK) TCC0 APB Clock Enable */ +#define PM_APBCMASK_TCC0 (0x1u << PM_APBCMASK_TCC0_Pos) +#define PM_APBCMASK_TCC1_Pos 9 /**< \brief (PM_APBCMASK) TCC1 APB Clock Enable */ +#define PM_APBCMASK_TCC1 (0x1u << PM_APBCMASK_TCC1_Pos) +#define PM_APBCMASK_TCC2_Pos 10 /**< \brief (PM_APBCMASK) TCC2 APB Clock Enable */ +#define PM_APBCMASK_TCC2 (0x1u << PM_APBCMASK_TCC2_Pos) +#define PM_APBCMASK_TC3_Pos 11 /**< \brief (PM_APBCMASK) TC3 APB Clock Enable */ +#define PM_APBCMASK_TC3 (0x1u << PM_APBCMASK_TC3_Pos) +#define PM_APBCMASK_TC4_Pos 12 /**< \brief (PM_APBCMASK) TC4 APB Clock Enable */ +#define PM_APBCMASK_TC4 (0x1u << PM_APBCMASK_TC4_Pos) +#define PM_APBCMASK_TC5_Pos 13 /**< \brief (PM_APBCMASK) TC5 APB Clock Enable */ +#define PM_APBCMASK_TC5 (0x1u << PM_APBCMASK_TC5_Pos) +#define PM_APBCMASK_TC6_Pos 14 /**< \brief (PM_APBCMASK) TC6 APB Clock Enable */ +#define PM_APBCMASK_TC6 (0x1u << PM_APBCMASK_TC6_Pos) +#define PM_APBCMASK_TC7_Pos 15 /**< \brief (PM_APBCMASK) TC7 APB Clock Enable */ +#define PM_APBCMASK_TC7 (0x1u << PM_APBCMASK_TC7_Pos) +#define PM_APBCMASK_ADC_Pos 16 /**< \brief (PM_APBCMASK) ADC APB Clock Enable */ +#define PM_APBCMASK_ADC (0x1u << PM_APBCMASK_ADC_Pos) +#define PM_APBCMASK_AC_Pos 17 /**< \brief (PM_APBCMASK) AC APB Clock Enable */ +#define PM_APBCMASK_AC (0x1u << PM_APBCMASK_AC_Pos) +#define PM_APBCMASK_DAC_Pos 18 /**< \brief (PM_APBCMASK) DAC APB Clock Enable */ +#define PM_APBCMASK_DAC (0x1u << PM_APBCMASK_DAC_Pos) +#define PM_APBCMASK_PTC_Pos 19 /**< \brief (PM_APBCMASK) PTC APB Clock Enable */ +#define PM_APBCMASK_PTC (0x1u << PM_APBCMASK_PTC_Pos) +#define PM_APBCMASK_I2S_Pos 20 /**< \brief (PM_APBCMASK) I2S APB Clock Enable */ +#define PM_APBCMASK_I2S (0x1u << PM_APBCMASK_I2S_Pos) +#define PM_APBCMASK_MASK 0x001FFFFFu /**< \brief (PM_APBCMASK) MASK Register */ + +/* -------- PM_INTENCLR : (PM Offset: 0x34) (R/W 8) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CKRDY:1; /*!< bit: 0 Clock Ready Interrupt Enable */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PM_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_INTENCLR_OFFSET 0x34 /**< \brief (PM_INTENCLR offset) Interrupt Enable Clear */ +#define PM_INTENCLR_RESETVALUE 0x00 /**< \brief (PM_INTENCLR reset_value) Interrupt Enable Clear */ + +#define PM_INTENCLR_CKRDY_Pos 0 /**< \brief (PM_INTENCLR) Clock Ready Interrupt Enable */ +#define PM_INTENCLR_CKRDY (0x1u << PM_INTENCLR_CKRDY_Pos) +#define PM_INTENCLR_MASK 0x01u /**< \brief (PM_INTENCLR) MASK Register */ + +/* -------- PM_INTENSET : (PM Offset: 0x35) (R/W 8) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CKRDY:1; /*!< bit: 0 Clock Ready Interrupt Enable */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PM_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_INTENSET_OFFSET 0x35 /**< \brief (PM_INTENSET offset) Interrupt Enable Set */ +#define PM_INTENSET_RESETVALUE 0x00 /**< \brief (PM_INTENSET reset_value) Interrupt Enable Set */ + +#define PM_INTENSET_CKRDY_Pos 0 /**< \brief (PM_INTENSET) Clock Ready Interrupt Enable */ +#define PM_INTENSET_CKRDY (0x1u << PM_INTENSET_CKRDY_Pos) +#define PM_INTENSET_MASK 0x01u /**< \brief (PM_INTENSET) MASK Register */ + +/* -------- PM_INTFLAG : (PM Offset: 0x36) (R/W 8) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CKRDY:1; /*!< bit: 0 Clock Ready */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PM_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_INTFLAG_OFFSET 0x36 /**< \brief (PM_INTFLAG offset) Interrupt Flag Status and Clear */ +#define PM_INTFLAG_RESETVALUE 0x00 /**< \brief (PM_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define PM_INTFLAG_CKRDY_Pos 0 /**< \brief (PM_INTFLAG) Clock Ready */ +#define PM_INTFLAG_CKRDY (0x1u << PM_INTFLAG_CKRDY_Pos) +#define PM_INTFLAG_MASK 0x01u /**< \brief (PM_INTFLAG) MASK Register */ + +/* -------- PM_RCAUSE : (PM Offset: 0x38) (R/ 8) Reset Cause -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t POR:1; /*!< bit: 0 Power On Reset */ + uint8_t BOD12:1; /*!< bit: 1 Brown Out 12 Detector Reset */ + uint8_t BOD33:1; /*!< bit: 2 Brown Out 33 Detector Reset */ + uint8_t :1; /*!< bit: 3 Reserved */ + uint8_t EXT:1; /*!< bit: 4 External Reset */ + uint8_t WDT:1; /*!< bit: 5 Watchdog Reset */ + uint8_t SYST:1; /*!< bit: 6 System Reset Request */ + uint8_t :1; /*!< bit: 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PM_RCAUSE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_RCAUSE_OFFSET 0x38 /**< \brief (PM_RCAUSE offset) Reset Cause */ +#define PM_RCAUSE_RESETVALUE 0x01 /**< \brief (PM_RCAUSE reset_value) Reset Cause */ + +#define PM_RCAUSE_POR_Pos 0 /**< \brief (PM_RCAUSE) Power On Reset */ +#define PM_RCAUSE_POR (0x1u << PM_RCAUSE_POR_Pos) +#define PM_RCAUSE_BOD12_Pos 1 /**< \brief (PM_RCAUSE) Brown Out 12 Detector Reset */ +#define PM_RCAUSE_BOD12 (0x1u << PM_RCAUSE_BOD12_Pos) +#define PM_RCAUSE_BOD33_Pos 2 /**< \brief (PM_RCAUSE) Brown Out 33 Detector Reset */ +#define PM_RCAUSE_BOD33 (0x1u << PM_RCAUSE_BOD33_Pos) +#define PM_RCAUSE_EXT_Pos 4 /**< \brief (PM_RCAUSE) External Reset */ +#define PM_RCAUSE_EXT (0x1u << PM_RCAUSE_EXT_Pos) +#define PM_RCAUSE_WDT_Pos 5 /**< \brief (PM_RCAUSE) Watchdog Reset */ +#define PM_RCAUSE_WDT (0x1u << PM_RCAUSE_WDT_Pos) +#define PM_RCAUSE_SYST_Pos 6 /**< \brief (PM_RCAUSE) System Reset Request */ +#define PM_RCAUSE_SYST (0x1u << PM_RCAUSE_SYST_Pos) +#define PM_RCAUSE_MASK 0x77u /**< \brief (PM_RCAUSE) MASK Register */ + +/** \brief PM hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO PM_CTRL_Type CTRL; /**< \brief Offset: 0x00 (R/W 8) Control */ + __IO PM_SLEEP_Type SLEEP; /**< \brief Offset: 0x01 (R/W 8) Sleep Mode */ + RoReg8 Reserved1[0x6]; + __IO PM_CPUSEL_Type CPUSEL; /**< \brief Offset: 0x08 (R/W 8) CPU Clock Select */ + __IO PM_APBASEL_Type APBASEL; /**< \brief Offset: 0x09 (R/W 8) APBA Clock Select */ + __IO PM_APBBSEL_Type APBBSEL; /**< \brief Offset: 0x0A (R/W 8) APBB Clock Select */ + __IO PM_APBCSEL_Type APBCSEL; /**< \brief Offset: 0x0B (R/W 8) APBC Clock Select */ + RoReg8 Reserved2[0x8]; + __IO PM_AHBMASK_Type AHBMASK; /**< \brief Offset: 0x14 (R/W 32) AHB Mask */ + __IO PM_APBAMASK_Type APBAMASK; /**< \brief Offset: 0x18 (R/W 32) APBA Mask */ + __IO PM_APBBMASK_Type APBBMASK; /**< \brief Offset: 0x1C (R/W 32) APBB Mask */ + __IO PM_APBCMASK_Type APBCMASK; /**< \brief Offset: 0x20 (R/W 32) APBC Mask */ + RoReg8 Reserved3[0x10]; + __IO PM_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x34 (R/W 8) Interrupt Enable Clear */ + __IO PM_INTENSET_Type INTENSET; /**< \brief Offset: 0x35 (R/W 8) Interrupt Enable Set */ + __IO PM_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x36 (R/W 8) Interrupt Flag Status and Clear */ + RoReg8 Reserved4[0x1]; + __I PM_RCAUSE_Type RCAUSE; /**< \brief Offset: 0x38 (R/ 8) Reset Cause */ +} Pm; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_PM_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/port.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/port.h new file mode 100644 index 0000000..5adf686 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/port.h @@ -0,0 +1,395 @@ +/** + * \file + * + * \brief Component description for PORT + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_PORT_COMPONENT_ +#define _SAMD21_PORT_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR PORT */ +/* ========================================================================== */ +/** \addtogroup SAMD21_PORT Port Module */ +/*@{*/ + +#define PORT_U2210 +#define REV_PORT 0x100 + +/* -------- PORT_DIR : (PORT Offset: 0x00) (R/W 32) GROUP Data Direction -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DIR:32; /*!< bit: 0..31 Port Data Direction */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_DIR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_DIR_OFFSET 0x00 /**< \brief (PORT_DIR offset) Data Direction */ +#define PORT_DIR_RESETVALUE 0x00000000 /**< \brief (PORT_DIR reset_value) Data Direction */ + +#define PORT_DIR_DIR_Pos 0 /**< \brief (PORT_DIR) Port Data Direction */ +#define PORT_DIR_DIR_Msk (0xFFFFFFFFu << PORT_DIR_DIR_Pos) +#define PORT_DIR_DIR(value) ((PORT_DIR_DIR_Msk & ((value) << PORT_DIR_DIR_Pos))) +#define PORT_DIR_MASK 0xFFFFFFFFu /**< \brief (PORT_DIR) MASK Register */ + +/* -------- PORT_DIRCLR : (PORT Offset: 0x04) (R/W 32) GROUP Data Direction Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DIRCLR:32; /*!< bit: 0..31 Port Data Direction Clear */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_DIRCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_DIRCLR_OFFSET 0x04 /**< \brief (PORT_DIRCLR offset) Data Direction Clear */ +#define PORT_DIRCLR_RESETVALUE 0x00000000 /**< \brief (PORT_DIRCLR reset_value) Data Direction Clear */ + +#define PORT_DIRCLR_DIRCLR_Pos 0 /**< \brief (PORT_DIRCLR) Port Data Direction Clear */ +#define PORT_DIRCLR_DIRCLR_Msk (0xFFFFFFFFu << PORT_DIRCLR_DIRCLR_Pos) +#define PORT_DIRCLR_DIRCLR(value) ((PORT_DIRCLR_DIRCLR_Msk & ((value) << PORT_DIRCLR_DIRCLR_Pos))) +#define PORT_DIRCLR_MASK 0xFFFFFFFFu /**< \brief (PORT_DIRCLR) MASK Register */ + +/* -------- PORT_DIRSET : (PORT Offset: 0x08) (R/W 32) GROUP Data Direction Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DIRSET:32; /*!< bit: 0..31 Port Data Direction Set */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_DIRSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_DIRSET_OFFSET 0x08 /**< \brief (PORT_DIRSET offset) Data Direction Set */ +#define PORT_DIRSET_RESETVALUE 0x00000000 /**< \brief (PORT_DIRSET reset_value) Data Direction Set */ + +#define PORT_DIRSET_DIRSET_Pos 0 /**< \brief (PORT_DIRSET) Port Data Direction Set */ +#define PORT_DIRSET_DIRSET_Msk (0xFFFFFFFFu << PORT_DIRSET_DIRSET_Pos) +#define PORT_DIRSET_DIRSET(value) ((PORT_DIRSET_DIRSET_Msk & ((value) << PORT_DIRSET_DIRSET_Pos))) +#define PORT_DIRSET_MASK 0xFFFFFFFFu /**< \brief (PORT_DIRSET) MASK Register */ + +/* -------- PORT_DIRTGL : (PORT Offset: 0x0C) (R/W 32) GROUP Data Direction Toggle -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DIRTGL:32; /*!< bit: 0..31 Port Data Direction Toggle */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_DIRTGL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_DIRTGL_OFFSET 0x0C /**< \brief (PORT_DIRTGL offset) Data Direction Toggle */ +#define PORT_DIRTGL_RESETVALUE 0x00000000 /**< \brief (PORT_DIRTGL reset_value) Data Direction Toggle */ + +#define PORT_DIRTGL_DIRTGL_Pos 0 /**< \brief (PORT_DIRTGL) Port Data Direction Toggle */ +#define PORT_DIRTGL_DIRTGL_Msk (0xFFFFFFFFu << PORT_DIRTGL_DIRTGL_Pos) +#define PORT_DIRTGL_DIRTGL(value) ((PORT_DIRTGL_DIRTGL_Msk & ((value) << PORT_DIRTGL_DIRTGL_Pos))) +#define PORT_DIRTGL_MASK 0xFFFFFFFFu /**< \brief (PORT_DIRTGL) MASK Register */ + +/* -------- PORT_OUT : (PORT Offset: 0x10) (R/W 32) GROUP Data Output Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OUT:32; /*!< bit: 0..31 Port Data Output Value */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_OUT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_OUT_OFFSET 0x10 /**< \brief (PORT_OUT offset) Data Output Value */ +#define PORT_OUT_RESETVALUE 0x00000000 /**< \brief (PORT_OUT reset_value) Data Output Value */ + +#define PORT_OUT_OUT_Pos 0 /**< \brief (PORT_OUT) Port Data Output Value */ +#define PORT_OUT_OUT_Msk (0xFFFFFFFFu << PORT_OUT_OUT_Pos) +#define PORT_OUT_OUT(value) ((PORT_OUT_OUT_Msk & ((value) << PORT_OUT_OUT_Pos))) +#define PORT_OUT_MASK 0xFFFFFFFFu /**< \brief (PORT_OUT) MASK Register */ + +/* -------- PORT_OUTCLR : (PORT Offset: 0x14) (R/W 32) GROUP Data Output Value Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OUTCLR:32; /*!< bit: 0..31 Port Data Output Value Clear */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_OUTCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_OUTCLR_OFFSET 0x14 /**< \brief (PORT_OUTCLR offset) Data Output Value Clear */ +#define PORT_OUTCLR_RESETVALUE 0x00000000 /**< \brief (PORT_OUTCLR reset_value) Data Output Value Clear */ + +#define PORT_OUTCLR_OUTCLR_Pos 0 /**< \brief (PORT_OUTCLR) Port Data Output Value Clear */ +#define PORT_OUTCLR_OUTCLR_Msk (0xFFFFFFFFu << PORT_OUTCLR_OUTCLR_Pos) +#define PORT_OUTCLR_OUTCLR(value) ((PORT_OUTCLR_OUTCLR_Msk & ((value) << PORT_OUTCLR_OUTCLR_Pos))) +#define PORT_OUTCLR_MASK 0xFFFFFFFFu /**< \brief (PORT_OUTCLR) MASK Register */ + +/* -------- PORT_OUTSET : (PORT Offset: 0x18) (R/W 32) GROUP Data Output Value Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OUTSET:32; /*!< bit: 0..31 Port Data Output Value Set */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_OUTSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_OUTSET_OFFSET 0x18 /**< \brief (PORT_OUTSET offset) Data Output Value Set */ +#define PORT_OUTSET_RESETVALUE 0x00000000 /**< \brief (PORT_OUTSET reset_value) Data Output Value Set */ + +#define PORT_OUTSET_OUTSET_Pos 0 /**< \brief (PORT_OUTSET) Port Data Output Value Set */ +#define PORT_OUTSET_OUTSET_Msk (0xFFFFFFFFu << PORT_OUTSET_OUTSET_Pos) +#define PORT_OUTSET_OUTSET(value) ((PORT_OUTSET_OUTSET_Msk & ((value) << PORT_OUTSET_OUTSET_Pos))) +#define PORT_OUTSET_MASK 0xFFFFFFFFu /**< \brief (PORT_OUTSET) MASK Register */ + +/* -------- PORT_OUTTGL : (PORT Offset: 0x1C) (R/W 32) GROUP Data Output Value Toggle -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OUTTGL:32; /*!< bit: 0..31 Port Data Output Value Toggle */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_OUTTGL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_OUTTGL_OFFSET 0x1C /**< \brief (PORT_OUTTGL offset) Data Output Value Toggle */ +#define PORT_OUTTGL_RESETVALUE 0x00000000 /**< \brief (PORT_OUTTGL reset_value) Data Output Value Toggle */ + +#define PORT_OUTTGL_OUTTGL_Pos 0 /**< \brief (PORT_OUTTGL) Port Data Output Value Toggle */ +#define PORT_OUTTGL_OUTTGL_Msk (0xFFFFFFFFu << PORT_OUTTGL_OUTTGL_Pos) +#define PORT_OUTTGL_OUTTGL(value) ((PORT_OUTTGL_OUTTGL_Msk & ((value) << PORT_OUTTGL_OUTTGL_Pos))) +#define PORT_OUTTGL_MASK 0xFFFFFFFFu /**< \brief (PORT_OUTTGL) MASK Register */ + +/* -------- PORT_IN : (PORT Offset: 0x20) (R/ 32) GROUP Data Input Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t IN:32; /*!< bit: 0..31 Port Data Input Value */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_IN_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_IN_OFFSET 0x20 /**< \brief (PORT_IN offset) Data Input Value */ +#define PORT_IN_RESETVALUE 0x00000000 /**< \brief (PORT_IN reset_value) Data Input Value */ + +#define PORT_IN_IN_Pos 0 /**< \brief (PORT_IN) Port Data Input Value */ +#define PORT_IN_IN_Msk (0xFFFFFFFFu << PORT_IN_IN_Pos) +#define PORT_IN_IN(value) ((PORT_IN_IN_Msk & ((value) << PORT_IN_IN_Pos))) +#define PORT_IN_MASK 0xFFFFFFFFu /**< \brief (PORT_IN) MASK Register */ + +/* -------- PORT_CTRL : (PORT Offset: 0x24) (R/W 32) GROUP Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SAMPLING:32; /*!< bit: 0..31 Input Sampling Mode */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_CTRL_OFFSET 0x24 /**< \brief (PORT_CTRL offset) Control */ +#define PORT_CTRL_RESETVALUE 0x00000000 /**< \brief (PORT_CTRL reset_value) Control */ + +#define PORT_CTRL_SAMPLING_Pos 0 /**< \brief (PORT_CTRL) Input Sampling Mode */ +#define PORT_CTRL_SAMPLING_Msk (0xFFFFFFFFu << PORT_CTRL_SAMPLING_Pos) +#define PORT_CTRL_SAMPLING(value) ((PORT_CTRL_SAMPLING_Msk & ((value) << PORT_CTRL_SAMPLING_Pos))) +#define PORT_CTRL_MASK 0xFFFFFFFFu /**< \brief (PORT_CTRL) MASK Register */ + +/* -------- PORT_WRCONFIG : (PORT Offset: 0x28) ( /W 32) GROUP Write Configuration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PINMASK:16; /*!< bit: 0..15 Pin Mask for Multiple Pin Configuration */ + uint32_t PMUXEN:1; /*!< bit: 16 Peripheral Multiplexer Enable */ + uint32_t INEN:1; /*!< bit: 17 Input Enable */ + uint32_t PULLEN:1; /*!< bit: 18 Pull Enable */ + uint32_t :3; /*!< bit: 19..21 Reserved */ + uint32_t DRVSTR:1; /*!< bit: 22 Output Driver Strength Selection */ + uint32_t :1; /*!< bit: 23 Reserved */ + uint32_t PMUX:4; /*!< bit: 24..27 Peripheral Multiplexing */ + uint32_t WRPMUX:1; /*!< bit: 28 Write PMUX */ + uint32_t :1; /*!< bit: 29 Reserved */ + uint32_t WRPINCFG:1; /*!< bit: 30 Write PINCFG */ + uint32_t HWSEL:1; /*!< bit: 31 Half-Word Select */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_WRCONFIG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_WRCONFIG_OFFSET 0x28 /**< \brief (PORT_WRCONFIG offset) Write Configuration */ +#define PORT_WRCONFIG_RESETVALUE 0x00000000 /**< \brief (PORT_WRCONFIG reset_value) Write Configuration */ + +#define PORT_WRCONFIG_PINMASK_Pos 0 /**< \brief (PORT_WRCONFIG) Pin Mask for Multiple Pin Configuration */ +#define PORT_WRCONFIG_PINMASK_Msk (0xFFFFu << PORT_WRCONFIG_PINMASK_Pos) +#define PORT_WRCONFIG_PINMASK(value) ((PORT_WRCONFIG_PINMASK_Msk & ((value) << PORT_WRCONFIG_PINMASK_Pos))) +#define PORT_WRCONFIG_PMUXEN_Pos 16 /**< \brief (PORT_WRCONFIG) Peripheral Multiplexer Enable */ +#define PORT_WRCONFIG_PMUXEN (0x1u << PORT_WRCONFIG_PMUXEN_Pos) +#define PORT_WRCONFIG_INEN_Pos 17 /**< \brief (PORT_WRCONFIG) Input Enable */ +#define PORT_WRCONFIG_INEN (0x1u << PORT_WRCONFIG_INEN_Pos) +#define PORT_WRCONFIG_PULLEN_Pos 18 /**< \brief (PORT_WRCONFIG) Pull Enable */ +#define PORT_WRCONFIG_PULLEN (0x1u << PORT_WRCONFIG_PULLEN_Pos) +#define PORT_WRCONFIG_DRVSTR_Pos 22 /**< \brief (PORT_WRCONFIG) Output Driver Strength Selection */ +#define PORT_WRCONFIG_DRVSTR (0x1u << PORT_WRCONFIG_DRVSTR_Pos) +#define PORT_WRCONFIG_PMUX_Pos 24 /**< \brief (PORT_WRCONFIG) Peripheral Multiplexing */ +#define PORT_WRCONFIG_PMUX_Msk (0xFu << PORT_WRCONFIG_PMUX_Pos) +#define PORT_WRCONFIG_PMUX(value) ((PORT_WRCONFIG_PMUX_Msk & ((value) << PORT_WRCONFIG_PMUX_Pos))) +#define PORT_WRCONFIG_WRPMUX_Pos 28 /**< \brief (PORT_WRCONFIG) Write PMUX */ +#define PORT_WRCONFIG_WRPMUX (0x1u << PORT_WRCONFIG_WRPMUX_Pos) +#define PORT_WRCONFIG_WRPINCFG_Pos 30 /**< \brief (PORT_WRCONFIG) Write PINCFG */ +#define PORT_WRCONFIG_WRPINCFG (0x1u << PORT_WRCONFIG_WRPINCFG_Pos) +#define PORT_WRCONFIG_HWSEL_Pos 31 /**< \brief (PORT_WRCONFIG) Half-Word Select */ +#define PORT_WRCONFIG_HWSEL (0x1u << PORT_WRCONFIG_HWSEL_Pos) +#define PORT_WRCONFIG_MASK 0xDF47FFFFu /**< \brief (PORT_WRCONFIG) MASK Register */ + +/* -------- PORT_PMUX : (PORT Offset: 0x30) (R/W 8) GROUP Peripheral Multiplexing n -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PMUXE:4; /*!< bit: 0.. 3 Peripheral Multiplexing Even */ + uint8_t PMUXO:4; /*!< bit: 4.. 7 Peripheral Multiplexing Odd */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PORT_PMUX_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_PMUX_OFFSET 0x30 /**< \brief (PORT_PMUX offset) Peripheral Multiplexing n */ +#define PORT_PMUX_RESETVALUE 0x00 /**< \brief (PORT_PMUX reset_value) Peripheral Multiplexing n */ + +#define PORT_PMUX_PMUXE_Pos 0 /**< \brief (PORT_PMUX) Peripheral Multiplexing Even */ +#define PORT_PMUX_PMUXE_Msk (0xFu << PORT_PMUX_PMUXE_Pos) +#define PORT_PMUX_PMUXE(value) ((PORT_PMUX_PMUXE_Msk & ((value) << PORT_PMUX_PMUXE_Pos))) +#define PORT_PMUX_PMUXE_A_Val 0x0u /**< \brief (PORT_PMUX) Peripheral function A selected */ +#define PORT_PMUX_PMUXE_B_Val 0x1u /**< \brief (PORT_PMUX) Peripheral function B selected */ +#define PORT_PMUX_PMUXE_C_Val 0x2u /**< \brief (PORT_PMUX) Peripheral function C selected */ +#define PORT_PMUX_PMUXE_D_Val 0x3u /**< \brief (PORT_PMUX) Peripheral function D selected */ +#define PORT_PMUX_PMUXE_E_Val 0x4u /**< \brief (PORT_PMUX) Peripheral function E selected */ +#define PORT_PMUX_PMUXE_F_Val 0x5u /**< \brief (PORT_PMUX) Peripheral function F selected */ +#define PORT_PMUX_PMUXE_G_Val 0x6u /**< \brief (PORT_PMUX) Peripheral function G selected */ +#define PORT_PMUX_PMUXE_H_Val 0x7u /**< \brief (PORT_PMUX) Peripheral function H selected */ +#define PORT_PMUX_PMUXE_A (PORT_PMUX_PMUXE_A_Val << PORT_PMUX_PMUXE_Pos) +#define PORT_PMUX_PMUXE_B (PORT_PMUX_PMUXE_B_Val << PORT_PMUX_PMUXE_Pos) +#define PORT_PMUX_PMUXE_C (PORT_PMUX_PMUXE_C_Val << PORT_PMUX_PMUXE_Pos) +#define PORT_PMUX_PMUXE_D (PORT_PMUX_PMUXE_D_Val << PORT_PMUX_PMUXE_Pos) +#define PORT_PMUX_PMUXE_E (PORT_PMUX_PMUXE_E_Val << PORT_PMUX_PMUXE_Pos) +#define PORT_PMUX_PMUXE_F (PORT_PMUX_PMUXE_F_Val << PORT_PMUX_PMUXE_Pos) +#define PORT_PMUX_PMUXE_G (PORT_PMUX_PMUXE_G_Val << PORT_PMUX_PMUXE_Pos) +#define PORT_PMUX_PMUXE_H (PORT_PMUX_PMUXE_H_Val << PORT_PMUX_PMUXE_Pos) +#define PORT_PMUX_PMUXO_Pos 4 /**< \brief (PORT_PMUX) Peripheral Multiplexing Odd */ +#define PORT_PMUX_PMUXO_Msk (0xFu << PORT_PMUX_PMUXO_Pos) +#define PORT_PMUX_PMUXO(value) ((PORT_PMUX_PMUXO_Msk & ((value) << PORT_PMUX_PMUXO_Pos))) +#define PORT_PMUX_PMUXO_A_Val 0x0u /**< \brief (PORT_PMUX) Peripheral function A selected */ +#define PORT_PMUX_PMUXO_B_Val 0x1u /**< \brief (PORT_PMUX) Peripheral function B selected */ +#define PORT_PMUX_PMUXO_C_Val 0x2u /**< \brief (PORT_PMUX) Peripheral function C selected */ +#define PORT_PMUX_PMUXO_D_Val 0x3u /**< \brief (PORT_PMUX) Peripheral function D selected */ +#define PORT_PMUX_PMUXO_E_Val 0x4u /**< \brief (PORT_PMUX) Peripheral function E selected */ +#define PORT_PMUX_PMUXO_F_Val 0x5u /**< \brief (PORT_PMUX) Peripheral function F selected */ +#define PORT_PMUX_PMUXO_G_Val 0x6u /**< \brief (PORT_PMUX) Peripheral function G selected */ +#define PORT_PMUX_PMUXO_H_Val 0x7u /**< \brief (PORT_PMUX) Peripheral function H selected */ +#define PORT_PMUX_PMUXO_A (PORT_PMUX_PMUXO_A_Val << PORT_PMUX_PMUXO_Pos) +#define PORT_PMUX_PMUXO_B (PORT_PMUX_PMUXO_B_Val << PORT_PMUX_PMUXO_Pos) +#define PORT_PMUX_PMUXO_C (PORT_PMUX_PMUXO_C_Val << PORT_PMUX_PMUXO_Pos) +#define PORT_PMUX_PMUXO_D (PORT_PMUX_PMUXO_D_Val << PORT_PMUX_PMUXO_Pos) +#define PORT_PMUX_PMUXO_E (PORT_PMUX_PMUXO_E_Val << PORT_PMUX_PMUXO_Pos) +#define PORT_PMUX_PMUXO_F (PORT_PMUX_PMUXO_F_Val << PORT_PMUX_PMUXO_Pos) +#define PORT_PMUX_PMUXO_G (PORT_PMUX_PMUXO_G_Val << PORT_PMUX_PMUXO_Pos) +#define PORT_PMUX_PMUXO_H (PORT_PMUX_PMUXO_H_Val << PORT_PMUX_PMUXO_Pos) +#define PORT_PMUX_MASK 0xFFu /**< \brief (PORT_PMUX) MASK Register */ + +/* -------- PORT_PINCFG : (PORT Offset: 0x40) (R/W 8) GROUP Pin Configuration n -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PMUXEN:1; /*!< bit: 0 Peripheral Multiplexer Enable */ + uint8_t INEN:1; /*!< bit: 1 Input Enable */ + uint8_t PULLEN:1; /*!< bit: 2 Pull Enable */ + uint8_t :3; /*!< bit: 3.. 5 Reserved */ + uint8_t DRVSTR:1; /*!< bit: 6 Output Driver Strength Selection */ + uint8_t :1; /*!< bit: 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PORT_PINCFG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_PINCFG_OFFSET 0x40 /**< \brief (PORT_PINCFG offset) Pin Configuration n */ +#define PORT_PINCFG_RESETVALUE 0x00 /**< \brief (PORT_PINCFG reset_value) Pin Configuration n */ + +#define PORT_PINCFG_PMUXEN_Pos 0 /**< \brief (PORT_PINCFG) Peripheral Multiplexer Enable */ +#define PORT_PINCFG_PMUXEN (0x1u << PORT_PINCFG_PMUXEN_Pos) +#define PORT_PINCFG_INEN_Pos 1 /**< \brief (PORT_PINCFG) Input Enable */ +#define PORT_PINCFG_INEN (0x1u << PORT_PINCFG_INEN_Pos) +#define PORT_PINCFG_PULLEN_Pos 2 /**< \brief (PORT_PINCFG) Pull Enable */ +#define PORT_PINCFG_PULLEN (0x1u << PORT_PINCFG_PULLEN_Pos) +#define PORT_PINCFG_DRVSTR_Pos 6 /**< \brief (PORT_PINCFG) Output Driver Strength Selection */ +#define PORT_PINCFG_DRVSTR (0x1u << PORT_PINCFG_DRVSTR_Pos) +#define PORT_PINCFG_MASK 0x47u /**< \brief (PORT_PINCFG) MASK Register */ + +/** \brief PortGroup hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO PORT_DIR_Type DIR; /**< \brief Offset: 0x00 (R/W 32) Data Direction */ + __IO PORT_DIRCLR_Type DIRCLR; /**< \brief Offset: 0x04 (R/W 32) Data Direction Clear */ + __IO PORT_DIRSET_Type DIRSET; /**< \brief Offset: 0x08 (R/W 32) Data Direction Set */ + __IO PORT_DIRTGL_Type DIRTGL; /**< \brief Offset: 0x0C (R/W 32) Data Direction Toggle */ + __IO PORT_OUT_Type OUT; /**< \brief Offset: 0x10 (R/W 32) Data Output Value */ + __IO PORT_OUTCLR_Type OUTCLR; /**< \brief Offset: 0x14 (R/W 32) Data Output Value Clear */ + __IO PORT_OUTSET_Type OUTSET; /**< \brief Offset: 0x18 (R/W 32) Data Output Value Set */ + __IO PORT_OUTTGL_Type OUTTGL; /**< \brief Offset: 0x1C (R/W 32) Data Output Value Toggle */ + __I PORT_IN_Type IN; /**< \brief Offset: 0x20 (R/ 32) Data Input Value */ + __IO PORT_CTRL_Type CTRL; /**< \brief Offset: 0x24 (R/W 32) Control */ + __O PORT_WRCONFIG_Type WRCONFIG; /**< \brief Offset: 0x28 ( /W 32) Write Configuration */ + RoReg8 Reserved1[0x4]; + __IO PORT_PMUX_Type PMUX[16]; /**< \brief Offset: 0x30 (R/W 8) Peripheral Multiplexing n */ + __IO PORT_PINCFG_Type PINCFG[32]; /**< \brief Offset: 0x40 (R/W 8) Pin Configuration n */ + RoReg8 Reserved2[0x20]; +} PortGroup; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief PORT APB hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + PortGroup Group[2]; /**< \brief Offset: 0x00 PortGroup groups [GROUPS] */ +} Port; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +#define SECTION_PORT_IOBUS + +/*@}*/ + +#endif /* _SAMD21_PORT_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/rtc.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/rtc.h new file mode 100644 index 0000000..73c717c --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/rtc.h @@ -0,0 +1,1062 @@ +/** + * \file + * + * \brief Component description for RTC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_RTC_COMPONENT_ +#define _SAMD21_RTC_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR RTC */ +/* ========================================================================== */ +/** \addtogroup SAMD21_RTC Real-Time Counter */ +/*@{*/ + +#define RTC_U2202 +#define REV_RTC 0x101 + +/* -------- RTC_MODE0_CTRL : (RTC Offset: 0x00) (R/W 16) MODE0 MODE0 Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SWRST:1; /*!< bit: 0 Software Reset */ + uint16_t ENABLE:1; /*!< bit: 1 Enable */ + uint16_t MODE:2; /*!< bit: 2.. 3 Operating Mode */ + uint16_t :3; /*!< bit: 4.. 6 Reserved */ + uint16_t MATCHCLR:1; /*!< bit: 7 Clear on Match */ + uint16_t PRESCALER:4; /*!< bit: 8..11 Prescaler */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_MODE0_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE0_CTRL_OFFSET 0x00 /**< \brief (RTC_MODE0_CTRL offset) MODE0 Control */ +#define RTC_MODE0_CTRL_RESETVALUE 0x0000 /**< \brief (RTC_MODE0_CTRL reset_value) MODE0 Control */ + +#define RTC_MODE0_CTRL_SWRST_Pos 0 /**< \brief (RTC_MODE0_CTRL) Software Reset */ +#define RTC_MODE0_CTRL_SWRST (0x1u << RTC_MODE0_CTRL_SWRST_Pos) +#define RTC_MODE0_CTRL_ENABLE_Pos 1 /**< \brief (RTC_MODE0_CTRL) Enable */ +#define RTC_MODE0_CTRL_ENABLE (0x1u << RTC_MODE0_CTRL_ENABLE_Pos) +#define RTC_MODE0_CTRL_MODE_Pos 2 /**< \brief (RTC_MODE0_CTRL) Operating Mode */ +#define RTC_MODE0_CTRL_MODE_Msk (0x3u << RTC_MODE0_CTRL_MODE_Pos) +#define RTC_MODE0_CTRL_MODE(value) ((RTC_MODE0_CTRL_MODE_Msk & ((value) << RTC_MODE0_CTRL_MODE_Pos))) +#define RTC_MODE0_CTRL_MODE_COUNT32_Val 0x0u /**< \brief (RTC_MODE0_CTRL) Mode 0: 32-bit Counter */ +#define RTC_MODE0_CTRL_MODE_COUNT16_Val 0x1u /**< \brief (RTC_MODE0_CTRL) Mode 1: 16-bit Counter */ +#define RTC_MODE0_CTRL_MODE_CLOCK_Val 0x2u /**< \brief (RTC_MODE0_CTRL) Mode 2: Clock/Calendar */ +#define RTC_MODE0_CTRL_MODE_COUNT32 (RTC_MODE0_CTRL_MODE_COUNT32_Val << RTC_MODE0_CTRL_MODE_Pos) +#define RTC_MODE0_CTRL_MODE_COUNT16 (RTC_MODE0_CTRL_MODE_COUNT16_Val << RTC_MODE0_CTRL_MODE_Pos) +#define RTC_MODE0_CTRL_MODE_CLOCK (RTC_MODE0_CTRL_MODE_CLOCK_Val << RTC_MODE0_CTRL_MODE_Pos) +#define RTC_MODE0_CTRL_MATCHCLR_Pos 7 /**< \brief (RTC_MODE0_CTRL) Clear on Match */ +#define RTC_MODE0_CTRL_MATCHCLR (0x1u << RTC_MODE0_CTRL_MATCHCLR_Pos) +#define RTC_MODE0_CTRL_PRESCALER_Pos 8 /**< \brief (RTC_MODE0_CTRL) Prescaler */ +#define RTC_MODE0_CTRL_PRESCALER_Msk (0xFu << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER(value) ((RTC_MODE0_CTRL_PRESCALER_Msk & ((value) << RTC_MODE0_CTRL_PRESCALER_Pos))) +#define RTC_MODE0_CTRL_PRESCALER_DIV1_Val 0x0u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/1 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV2_Val 0x1u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/2 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV4_Val 0x2u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/4 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV8_Val 0x3u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/8 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV16_Val 0x4u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/16 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV32_Val 0x5u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/32 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV64_Val 0x6u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/64 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV128_Val 0x7u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/128 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV256_Val 0x8u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/256 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV512_Val 0x9u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/512 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV1024_Val 0xAu /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/1024 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV1 (RTC_MODE0_CTRL_PRESCALER_DIV1_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV2 (RTC_MODE0_CTRL_PRESCALER_DIV2_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV4 (RTC_MODE0_CTRL_PRESCALER_DIV4_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV8 (RTC_MODE0_CTRL_PRESCALER_DIV8_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV16 (RTC_MODE0_CTRL_PRESCALER_DIV16_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV32 (RTC_MODE0_CTRL_PRESCALER_DIV32_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV64 (RTC_MODE0_CTRL_PRESCALER_DIV64_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV128 (RTC_MODE0_CTRL_PRESCALER_DIV128_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV256 (RTC_MODE0_CTRL_PRESCALER_DIV256_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV512 (RTC_MODE0_CTRL_PRESCALER_DIV512_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV1024 (RTC_MODE0_CTRL_PRESCALER_DIV1024_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_MASK 0x0F8Fu /**< \brief (RTC_MODE0_CTRL) MASK Register */ + +/* -------- RTC_MODE1_CTRL : (RTC Offset: 0x00) (R/W 16) MODE1 MODE1 Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SWRST:1; /*!< bit: 0 Software Reset */ + uint16_t ENABLE:1; /*!< bit: 1 Enable */ + uint16_t MODE:2; /*!< bit: 2.. 3 Operating Mode */ + uint16_t :4; /*!< bit: 4.. 7 Reserved */ + uint16_t PRESCALER:4; /*!< bit: 8..11 Prescaler */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_MODE1_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE1_CTRL_OFFSET 0x00 /**< \brief (RTC_MODE1_CTRL offset) MODE1 Control */ +#define RTC_MODE1_CTRL_RESETVALUE 0x0000 /**< \brief (RTC_MODE1_CTRL reset_value) MODE1 Control */ + +#define RTC_MODE1_CTRL_SWRST_Pos 0 /**< \brief (RTC_MODE1_CTRL) Software Reset */ +#define RTC_MODE1_CTRL_SWRST (0x1u << RTC_MODE1_CTRL_SWRST_Pos) +#define RTC_MODE1_CTRL_ENABLE_Pos 1 /**< \brief (RTC_MODE1_CTRL) Enable */ +#define RTC_MODE1_CTRL_ENABLE (0x1u << RTC_MODE1_CTRL_ENABLE_Pos) +#define RTC_MODE1_CTRL_MODE_Pos 2 /**< \brief (RTC_MODE1_CTRL) Operating Mode */ +#define RTC_MODE1_CTRL_MODE_Msk (0x3u << RTC_MODE1_CTRL_MODE_Pos) +#define RTC_MODE1_CTRL_MODE(value) ((RTC_MODE1_CTRL_MODE_Msk & ((value) << RTC_MODE1_CTRL_MODE_Pos))) +#define RTC_MODE1_CTRL_MODE_COUNT32_Val 0x0u /**< \brief (RTC_MODE1_CTRL) Mode 0: 32-bit Counter */ +#define RTC_MODE1_CTRL_MODE_COUNT16_Val 0x1u /**< \brief (RTC_MODE1_CTRL) Mode 1: 16-bit Counter */ +#define RTC_MODE1_CTRL_MODE_CLOCK_Val 0x2u /**< \brief (RTC_MODE1_CTRL) Mode 2: Clock/Calendar */ +#define RTC_MODE1_CTRL_MODE_COUNT32 (RTC_MODE1_CTRL_MODE_COUNT32_Val << RTC_MODE1_CTRL_MODE_Pos) +#define RTC_MODE1_CTRL_MODE_COUNT16 (RTC_MODE1_CTRL_MODE_COUNT16_Val << RTC_MODE1_CTRL_MODE_Pos) +#define RTC_MODE1_CTRL_MODE_CLOCK (RTC_MODE1_CTRL_MODE_CLOCK_Val << RTC_MODE1_CTRL_MODE_Pos) +#define RTC_MODE1_CTRL_PRESCALER_Pos 8 /**< \brief (RTC_MODE1_CTRL) Prescaler */ +#define RTC_MODE1_CTRL_PRESCALER_Msk (0xFu << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER(value) ((RTC_MODE1_CTRL_PRESCALER_Msk & ((value) << RTC_MODE1_CTRL_PRESCALER_Pos))) +#define RTC_MODE1_CTRL_PRESCALER_DIV1_Val 0x0u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/1 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV2_Val 0x1u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/2 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV4_Val 0x2u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/4 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV8_Val 0x3u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/8 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV16_Val 0x4u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/16 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV32_Val 0x5u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/32 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV64_Val 0x6u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/64 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV128_Val 0x7u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/128 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV256_Val 0x8u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/256 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV512_Val 0x9u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/512 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV1024_Val 0xAu /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/1024 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV1 (RTC_MODE1_CTRL_PRESCALER_DIV1_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV2 (RTC_MODE1_CTRL_PRESCALER_DIV2_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV4 (RTC_MODE1_CTRL_PRESCALER_DIV4_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV8 (RTC_MODE1_CTRL_PRESCALER_DIV8_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV16 (RTC_MODE1_CTRL_PRESCALER_DIV16_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV32 (RTC_MODE1_CTRL_PRESCALER_DIV32_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV64 (RTC_MODE1_CTRL_PRESCALER_DIV64_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV128 (RTC_MODE1_CTRL_PRESCALER_DIV128_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV256 (RTC_MODE1_CTRL_PRESCALER_DIV256_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV512 (RTC_MODE1_CTRL_PRESCALER_DIV512_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV1024 (RTC_MODE1_CTRL_PRESCALER_DIV1024_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_MASK 0x0F0Fu /**< \brief (RTC_MODE1_CTRL) MASK Register */ + +/* -------- RTC_MODE2_CTRL : (RTC Offset: 0x00) (R/W 16) MODE2 MODE2 Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SWRST:1; /*!< bit: 0 Software Reset */ + uint16_t ENABLE:1; /*!< bit: 1 Enable */ + uint16_t MODE:2; /*!< bit: 2.. 3 Operating Mode */ + uint16_t :2; /*!< bit: 4.. 5 Reserved */ + uint16_t CLKREP:1; /*!< bit: 6 Clock Representation */ + uint16_t MATCHCLR:1; /*!< bit: 7 Clear on Match */ + uint16_t PRESCALER:4; /*!< bit: 8..11 Prescaler */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_MODE2_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE2_CTRL_OFFSET 0x00 /**< \brief (RTC_MODE2_CTRL offset) MODE2 Control */ +#define RTC_MODE2_CTRL_RESETVALUE 0x0000 /**< \brief (RTC_MODE2_CTRL reset_value) MODE2 Control */ + +#define RTC_MODE2_CTRL_SWRST_Pos 0 /**< \brief (RTC_MODE2_CTRL) Software Reset */ +#define RTC_MODE2_CTRL_SWRST (0x1u << RTC_MODE2_CTRL_SWRST_Pos) +#define RTC_MODE2_CTRL_ENABLE_Pos 1 /**< \brief (RTC_MODE2_CTRL) Enable */ +#define RTC_MODE2_CTRL_ENABLE (0x1u << RTC_MODE2_CTRL_ENABLE_Pos) +#define RTC_MODE2_CTRL_MODE_Pos 2 /**< \brief (RTC_MODE2_CTRL) Operating Mode */ +#define RTC_MODE2_CTRL_MODE_Msk (0x3u << RTC_MODE2_CTRL_MODE_Pos) +#define RTC_MODE2_CTRL_MODE(value) ((RTC_MODE2_CTRL_MODE_Msk & ((value) << RTC_MODE2_CTRL_MODE_Pos))) +#define RTC_MODE2_CTRL_MODE_COUNT32_Val 0x0u /**< \brief (RTC_MODE2_CTRL) Mode 0: 32-bit Counter */ +#define RTC_MODE2_CTRL_MODE_COUNT16_Val 0x1u /**< \brief (RTC_MODE2_CTRL) Mode 1: 16-bit Counter */ +#define RTC_MODE2_CTRL_MODE_CLOCK_Val 0x2u /**< \brief (RTC_MODE2_CTRL) Mode 2: Clock/Calendar */ +#define RTC_MODE2_CTRL_MODE_COUNT32 (RTC_MODE2_CTRL_MODE_COUNT32_Val << RTC_MODE2_CTRL_MODE_Pos) +#define RTC_MODE2_CTRL_MODE_COUNT16 (RTC_MODE2_CTRL_MODE_COUNT16_Val << RTC_MODE2_CTRL_MODE_Pos) +#define RTC_MODE2_CTRL_MODE_CLOCK (RTC_MODE2_CTRL_MODE_CLOCK_Val << RTC_MODE2_CTRL_MODE_Pos) +#define RTC_MODE2_CTRL_CLKREP_Pos 6 /**< \brief (RTC_MODE2_CTRL) Clock Representation */ +#define RTC_MODE2_CTRL_CLKREP (0x1u << RTC_MODE2_CTRL_CLKREP_Pos) +#define RTC_MODE2_CTRL_MATCHCLR_Pos 7 /**< \brief (RTC_MODE2_CTRL) Clear on Match */ +#define RTC_MODE2_CTRL_MATCHCLR (0x1u << RTC_MODE2_CTRL_MATCHCLR_Pos) +#define RTC_MODE2_CTRL_PRESCALER_Pos 8 /**< \brief (RTC_MODE2_CTRL) Prescaler */ +#define RTC_MODE2_CTRL_PRESCALER_Msk (0xFu << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER(value) ((RTC_MODE2_CTRL_PRESCALER_Msk & ((value) << RTC_MODE2_CTRL_PRESCALER_Pos))) +#define RTC_MODE2_CTRL_PRESCALER_DIV1_Val 0x0u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/1 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV2_Val 0x1u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/2 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV4_Val 0x2u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/4 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV8_Val 0x3u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/8 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV16_Val 0x4u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/16 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV32_Val 0x5u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/32 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV64_Val 0x6u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/64 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV128_Val 0x7u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/128 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV256_Val 0x8u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/256 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV512_Val 0x9u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/512 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV1024_Val 0xAu /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/1024 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV1 (RTC_MODE2_CTRL_PRESCALER_DIV1_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV2 (RTC_MODE2_CTRL_PRESCALER_DIV2_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV4 (RTC_MODE2_CTRL_PRESCALER_DIV4_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV8 (RTC_MODE2_CTRL_PRESCALER_DIV8_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV16 (RTC_MODE2_CTRL_PRESCALER_DIV16_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV32 (RTC_MODE2_CTRL_PRESCALER_DIV32_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV64 (RTC_MODE2_CTRL_PRESCALER_DIV64_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV128 (RTC_MODE2_CTRL_PRESCALER_DIV128_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV256 (RTC_MODE2_CTRL_PRESCALER_DIV256_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV512 (RTC_MODE2_CTRL_PRESCALER_DIV512_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV1024 (RTC_MODE2_CTRL_PRESCALER_DIV1024_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_MASK 0x0FCFu /**< \brief (RTC_MODE2_CTRL) MASK Register */ + +/* -------- RTC_READREQ : (RTC Offset: 0x02) (R/W 16) Read Request -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t ADDR:6; /*!< bit: 0.. 5 Address */ + uint16_t :8; /*!< bit: 6..13 Reserved */ + uint16_t RCONT:1; /*!< bit: 14 Read Continuously */ + uint16_t RREQ:1; /*!< bit: 15 Read Request */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_READREQ_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_READREQ_OFFSET 0x02 /**< \brief (RTC_READREQ offset) Read Request */ +#define RTC_READREQ_RESETVALUE 0x0010 /**< \brief (RTC_READREQ reset_value) Read Request */ + +#define RTC_READREQ_ADDR_Pos 0 /**< \brief (RTC_READREQ) Address */ +#define RTC_READREQ_ADDR_Msk (0x3Fu << RTC_READREQ_ADDR_Pos) +#define RTC_READREQ_ADDR(value) ((RTC_READREQ_ADDR_Msk & ((value) << RTC_READREQ_ADDR_Pos))) +#define RTC_READREQ_RCONT_Pos 14 /**< \brief (RTC_READREQ) Read Continuously */ +#define RTC_READREQ_RCONT (0x1u << RTC_READREQ_RCONT_Pos) +#define RTC_READREQ_RREQ_Pos 15 /**< \brief (RTC_READREQ) Read Request */ +#define RTC_READREQ_RREQ (0x1u << RTC_READREQ_RREQ_Pos) +#define RTC_READREQ_MASK 0xC03Fu /**< \brief (RTC_READREQ) MASK Register */ + +/* -------- RTC_MODE0_EVCTRL : (RTC Offset: 0x04) (R/W 16) MODE0 MODE0 Event Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t PEREO0:1; /*!< bit: 0 Periodic Interval 0 Event Output Enable */ + uint16_t PEREO1:1; /*!< bit: 1 Periodic Interval 1 Event Output Enable */ + uint16_t PEREO2:1; /*!< bit: 2 Periodic Interval 2 Event Output Enable */ + uint16_t PEREO3:1; /*!< bit: 3 Periodic Interval 3 Event Output Enable */ + uint16_t PEREO4:1; /*!< bit: 4 Periodic Interval 4 Event Output Enable */ + uint16_t PEREO5:1; /*!< bit: 5 Periodic Interval 5 Event Output Enable */ + uint16_t PEREO6:1; /*!< bit: 6 Periodic Interval 6 Event Output Enable */ + uint16_t PEREO7:1; /*!< bit: 7 Periodic Interval 7 Event Output Enable */ + uint16_t CMPEO0:1; /*!< bit: 8 Compare 0 Event Output Enable */ + uint16_t :6; /*!< bit: 9..14 Reserved */ + uint16_t OVFEO:1; /*!< bit: 15 Overflow Event Output Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t PEREO:8; /*!< bit: 0.. 7 Periodic Interval x Event Output Enable */ + uint16_t CMPEO:1; /*!< bit: 8 Compare x Event Output Enable */ + uint16_t :7; /*!< bit: 9..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_MODE0_EVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE0_EVCTRL_OFFSET 0x04 /**< \brief (RTC_MODE0_EVCTRL offset) MODE0 Event Control */ +#define RTC_MODE0_EVCTRL_RESETVALUE 0x0000 /**< \brief (RTC_MODE0_EVCTRL reset_value) MODE0 Event Control */ + +#define RTC_MODE0_EVCTRL_PEREO0_Pos 0 /**< \brief (RTC_MODE0_EVCTRL) Periodic Interval 0 Event Output Enable */ +#define RTC_MODE0_EVCTRL_PEREO0 (1 << RTC_MODE0_EVCTRL_PEREO0_Pos) +#define RTC_MODE0_EVCTRL_PEREO1_Pos 1 /**< \brief (RTC_MODE0_EVCTRL) Periodic Interval 1 Event Output Enable */ +#define RTC_MODE0_EVCTRL_PEREO1 (1 << RTC_MODE0_EVCTRL_PEREO1_Pos) +#define RTC_MODE0_EVCTRL_PEREO2_Pos 2 /**< \brief (RTC_MODE0_EVCTRL) Periodic Interval 2 Event Output Enable */ +#define RTC_MODE0_EVCTRL_PEREO2 (1 << RTC_MODE0_EVCTRL_PEREO2_Pos) +#define RTC_MODE0_EVCTRL_PEREO3_Pos 3 /**< \brief (RTC_MODE0_EVCTRL) Periodic Interval 3 Event Output Enable */ +#define RTC_MODE0_EVCTRL_PEREO3 (1 << RTC_MODE0_EVCTRL_PEREO3_Pos) +#define RTC_MODE0_EVCTRL_PEREO4_Pos 4 /**< \brief (RTC_MODE0_EVCTRL) Periodic Interval 4 Event Output Enable */ +#define RTC_MODE0_EVCTRL_PEREO4 (1 << RTC_MODE0_EVCTRL_PEREO4_Pos) +#define RTC_MODE0_EVCTRL_PEREO5_Pos 5 /**< \brief (RTC_MODE0_EVCTRL) Periodic Interval 5 Event Output Enable */ +#define RTC_MODE0_EVCTRL_PEREO5 (1 << RTC_MODE0_EVCTRL_PEREO5_Pos) +#define RTC_MODE0_EVCTRL_PEREO6_Pos 6 /**< \brief (RTC_MODE0_EVCTRL) Periodic Interval 6 Event Output Enable */ +#define RTC_MODE0_EVCTRL_PEREO6 (1 << RTC_MODE0_EVCTRL_PEREO6_Pos) +#define RTC_MODE0_EVCTRL_PEREO7_Pos 7 /**< \brief (RTC_MODE0_EVCTRL) Periodic Interval 7 Event Output Enable */ +#define RTC_MODE0_EVCTRL_PEREO7 (1 << RTC_MODE0_EVCTRL_PEREO7_Pos) +#define RTC_MODE0_EVCTRL_PEREO_Pos 0 /**< \brief (RTC_MODE0_EVCTRL) Periodic Interval x Event Output Enable */ +#define RTC_MODE0_EVCTRL_PEREO_Msk (0xFFu << RTC_MODE0_EVCTRL_PEREO_Pos) +#define RTC_MODE0_EVCTRL_PEREO(value) ((RTC_MODE0_EVCTRL_PEREO_Msk & ((value) << RTC_MODE0_EVCTRL_PEREO_Pos))) +#define RTC_MODE0_EVCTRL_CMPEO0_Pos 8 /**< \brief (RTC_MODE0_EVCTRL) Compare 0 Event Output Enable */ +#define RTC_MODE0_EVCTRL_CMPEO0 (1 << RTC_MODE0_EVCTRL_CMPEO0_Pos) +#define RTC_MODE0_EVCTRL_CMPEO_Pos 8 /**< \brief (RTC_MODE0_EVCTRL) Compare x Event Output Enable */ +#define RTC_MODE0_EVCTRL_CMPEO_Msk (0x1u << RTC_MODE0_EVCTRL_CMPEO_Pos) +#define RTC_MODE0_EVCTRL_CMPEO(value) ((RTC_MODE0_EVCTRL_CMPEO_Msk & ((value) << RTC_MODE0_EVCTRL_CMPEO_Pos))) +#define RTC_MODE0_EVCTRL_OVFEO_Pos 15 /**< \brief (RTC_MODE0_EVCTRL) Overflow Event Output Enable */ +#define RTC_MODE0_EVCTRL_OVFEO (0x1u << RTC_MODE0_EVCTRL_OVFEO_Pos) +#define RTC_MODE0_EVCTRL_MASK 0x81FFu /**< \brief (RTC_MODE0_EVCTRL) MASK Register */ + +/* -------- RTC_MODE1_EVCTRL : (RTC Offset: 0x04) (R/W 16) MODE1 MODE1 Event Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t PEREO0:1; /*!< bit: 0 Periodic Interval 0 Event Output Enable */ + uint16_t PEREO1:1; /*!< bit: 1 Periodic Interval 1 Event Output Enable */ + uint16_t PEREO2:1; /*!< bit: 2 Periodic Interval 2 Event Output Enable */ + uint16_t PEREO3:1; /*!< bit: 3 Periodic Interval 3 Event Output Enable */ + uint16_t PEREO4:1; /*!< bit: 4 Periodic Interval 4 Event Output Enable */ + uint16_t PEREO5:1; /*!< bit: 5 Periodic Interval 5 Event Output Enable */ + uint16_t PEREO6:1; /*!< bit: 6 Periodic Interval 6 Event Output Enable */ + uint16_t PEREO7:1; /*!< bit: 7 Periodic Interval 7 Event Output Enable */ + uint16_t CMPEO0:1; /*!< bit: 8 Compare 0 Event Output Enable */ + uint16_t CMPEO1:1; /*!< bit: 9 Compare 1 Event Output Enable */ + uint16_t :5; /*!< bit: 10..14 Reserved */ + uint16_t OVFEO:1; /*!< bit: 15 Overflow Event Output Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t PEREO:8; /*!< bit: 0.. 7 Periodic Interval x Event Output Enable */ + uint16_t CMPEO:2; /*!< bit: 8.. 9 Compare x Event Output Enable */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_MODE1_EVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE1_EVCTRL_OFFSET 0x04 /**< \brief (RTC_MODE1_EVCTRL offset) MODE1 Event Control */ +#define RTC_MODE1_EVCTRL_RESETVALUE 0x0000 /**< \brief (RTC_MODE1_EVCTRL reset_value) MODE1 Event Control */ + +#define RTC_MODE1_EVCTRL_PEREO0_Pos 0 /**< \brief (RTC_MODE1_EVCTRL) Periodic Interval 0 Event Output Enable */ +#define RTC_MODE1_EVCTRL_PEREO0 (1 << RTC_MODE1_EVCTRL_PEREO0_Pos) +#define RTC_MODE1_EVCTRL_PEREO1_Pos 1 /**< \brief (RTC_MODE1_EVCTRL) Periodic Interval 1 Event Output Enable */ +#define RTC_MODE1_EVCTRL_PEREO1 (1 << RTC_MODE1_EVCTRL_PEREO1_Pos) +#define RTC_MODE1_EVCTRL_PEREO2_Pos 2 /**< \brief (RTC_MODE1_EVCTRL) Periodic Interval 2 Event Output Enable */ +#define RTC_MODE1_EVCTRL_PEREO2 (1 << RTC_MODE1_EVCTRL_PEREO2_Pos) +#define RTC_MODE1_EVCTRL_PEREO3_Pos 3 /**< \brief (RTC_MODE1_EVCTRL) Periodic Interval 3 Event Output Enable */ +#define RTC_MODE1_EVCTRL_PEREO3 (1 << RTC_MODE1_EVCTRL_PEREO3_Pos) +#define RTC_MODE1_EVCTRL_PEREO4_Pos 4 /**< \brief (RTC_MODE1_EVCTRL) Periodic Interval 4 Event Output Enable */ +#define RTC_MODE1_EVCTRL_PEREO4 (1 << RTC_MODE1_EVCTRL_PEREO4_Pos) +#define RTC_MODE1_EVCTRL_PEREO5_Pos 5 /**< \brief (RTC_MODE1_EVCTRL) Periodic Interval 5 Event Output Enable */ +#define RTC_MODE1_EVCTRL_PEREO5 (1 << RTC_MODE1_EVCTRL_PEREO5_Pos) +#define RTC_MODE1_EVCTRL_PEREO6_Pos 6 /**< \brief (RTC_MODE1_EVCTRL) Periodic Interval 6 Event Output Enable */ +#define RTC_MODE1_EVCTRL_PEREO6 (1 << RTC_MODE1_EVCTRL_PEREO6_Pos) +#define RTC_MODE1_EVCTRL_PEREO7_Pos 7 /**< \brief (RTC_MODE1_EVCTRL) Periodic Interval 7 Event Output Enable */ +#define RTC_MODE1_EVCTRL_PEREO7 (1 << RTC_MODE1_EVCTRL_PEREO7_Pos) +#define RTC_MODE1_EVCTRL_PEREO_Pos 0 /**< \brief (RTC_MODE1_EVCTRL) Periodic Interval x Event Output Enable */ +#define RTC_MODE1_EVCTRL_PEREO_Msk (0xFFu << RTC_MODE1_EVCTRL_PEREO_Pos) +#define RTC_MODE1_EVCTRL_PEREO(value) ((RTC_MODE1_EVCTRL_PEREO_Msk & ((value) << RTC_MODE1_EVCTRL_PEREO_Pos))) +#define RTC_MODE1_EVCTRL_CMPEO0_Pos 8 /**< \brief (RTC_MODE1_EVCTRL) Compare 0 Event Output Enable */ +#define RTC_MODE1_EVCTRL_CMPEO0 (1 << RTC_MODE1_EVCTRL_CMPEO0_Pos) +#define RTC_MODE1_EVCTRL_CMPEO1_Pos 9 /**< \brief (RTC_MODE1_EVCTRL) Compare 1 Event Output Enable */ +#define RTC_MODE1_EVCTRL_CMPEO1 (1 << RTC_MODE1_EVCTRL_CMPEO1_Pos) +#define RTC_MODE1_EVCTRL_CMPEO_Pos 8 /**< \brief (RTC_MODE1_EVCTRL) Compare x Event Output Enable */ +#define RTC_MODE1_EVCTRL_CMPEO_Msk (0x3u << RTC_MODE1_EVCTRL_CMPEO_Pos) +#define RTC_MODE1_EVCTRL_CMPEO(value) ((RTC_MODE1_EVCTRL_CMPEO_Msk & ((value) << RTC_MODE1_EVCTRL_CMPEO_Pos))) +#define RTC_MODE1_EVCTRL_OVFEO_Pos 15 /**< \brief (RTC_MODE1_EVCTRL) Overflow Event Output Enable */ +#define RTC_MODE1_EVCTRL_OVFEO (0x1u << RTC_MODE1_EVCTRL_OVFEO_Pos) +#define RTC_MODE1_EVCTRL_MASK 0x83FFu /**< \brief (RTC_MODE1_EVCTRL) MASK Register */ + +/* -------- RTC_MODE2_EVCTRL : (RTC Offset: 0x04) (R/W 16) MODE2 MODE2 Event Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t PEREO0:1; /*!< bit: 0 Periodic Interval 0 Event Output Enable */ + uint16_t PEREO1:1; /*!< bit: 1 Periodic Interval 1 Event Output Enable */ + uint16_t PEREO2:1; /*!< bit: 2 Periodic Interval 2 Event Output Enable */ + uint16_t PEREO3:1; /*!< bit: 3 Periodic Interval 3 Event Output Enable */ + uint16_t PEREO4:1; /*!< bit: 4 Periodic Interval 4 Event Output Enable */ + uint16_t PEREO5:1; /*!< bit: 5 Periodic Interval 5 Event Output Enable */ + uint16_t PEREO6:1; /*!< bit: 6 Periodic Interval 6 Event Output Enable */ + uint16_t PEREO7:1; /*!< bit: 7 Periodic Interval 7 Event Output Enable */ + uint16_t ALARMEO0:1; /*!< bit: 8 Alarm 0 Event Output Enable */ + uint16_t :6; /*!< bit: 9..14 Reserved */ + uint16_t OVFEO:1; /*!< bit: 15 Overflow Event Output Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t PEREO:8; /*!< bit: 0.. 7 Periodic Interval x Event Output Enable */ + uint16_t ALARMEO:1; /*!< bit: 8 Alarm x Event Output Enable */ + uint16_t :7; /*!< bit: 9..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_MODE2_EVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE2_EVCTRL_OFFSET 0x04 /**< \brief (RTC_MODE2_EVCTRL offset) MODE2 Event Control */ +#define RTC_MODE2_EVCTRL_RESETVALUE 0x0000 /**< \brief (RTC_MODE2_EVCTRL reset_value) MODE2 Event Control */ + +#define RTC_MODE2_EVCTRL_PEREO0_Pos 0 /**< \brief (RTC_MODE2_EVCTRL) Periodic Interval 0 Event Output Enable */ +#define RTC_MODE2_EVCTRL_PEREO0 (1 << RTC_MODE2_EVCTRL_PEREO0_Pos) +#define RTC_MODE2_EVCTRL_PEREO1_Pos 1 /**< \brief (RTC_MODE2_EVCTRL) Periodic Interval 1 Event Output Enable */ +#define RTC_MODE2_EVCTRL_PEREO1 (1 << RTC_MODE2_EVCTRL_PEREO1_Pos) +#define RTC_MODE2_EVCTRL_PEREO2_Pos 2 /**< \brief (RTC_MODE2_EVCTRL) Periodic Interval 2 Event Output Enable */ +#define RTC_MODE2_EVCTRL_PEREO2 (1 << RTC_MODE2_EVCTRL_PEREO2_Pos) +#define RTC_MODE2_EVCTRL_PEREO3_Pos 3 /**< \brief (RTC_MODE2_EVCTRL) Periodic Interval 3 Event Output Enable */ +#define RTC_MODE2_EVCTRL_PEREO3 (1 << RTC_MODE2_EVCTRL_PEREO3_Pos) +#define RTC_MODE2_EVCTRL_PEREO4_Pos 4 /**< \brief (RTC_MODE2_EVCTRL) Periodic Interval 4 Event Output Enable */ +#define RTC_MODE2_EVCTRL_PEREO4 (1 << RTC_MODE2_EVCTRL_PEREO4_Pos) +#define RTC_MODE2_EVCTRL_PEREO5_Pos 5 /**< \brief (RTC_MODE2_EVCTRL) Periodic Interval 5 Event Output Enable */ +#define RTC_MODE2_EVCTRL_PEREO5 (1 << RTC_MODE2_EVCTRL_PEREO5_Pos) +#define RTC_MODE2_EVCTRL_PEREO6_Pos 6 /**< \brief (RTC_MODE2_EVCTRL) Periodic Interval 6 Event Output Enable */ +#define RTC_MODE2_EVCTRL_PEREO6 (1 << RTC_MODE2_EVCTRL_PEREO6_Pos) +#define RTC_MODE2_EVCTRL_PEREO7_Pos 7 /**< \brief (RTC_MODE2_EVCTRL) Periodic Interval 7 Event Output Enable */ +#define RTC_MODE2_EVCTRL_PEREO7 (1 << RTC_MODE2_EVCTRL_PEREO7_Pos) +#define RTC_MODE2_EVCTRL_PEREO_Pos 0 /**< \brief (RTC_MODE2_EVCTRL) Periodic Interval x Event Output Enable */ +#define RTC_MODE2_EVCTRL_PEREO_Msk (0xFFu << RTC_MODE2_EVCTRL_PEREO_Pos) +#define RTC_MODE2_EVCTRL_PEREO(value) ((RTC_MODE2_EVCTRL_PEREO_Msk & ((value) << RTC_MODE2_EVCTRL_PEREO_Pos))) +#define RTC_MODE2_EVCTRL_ALARMEO0_Pos 8 /**< \brief (RTC_MODE2_EVCTRL) Alarm 0 Event Output Enable */ +#define RTC_MODE2_EVCTRL_ALARMEO0 (1 << RTC_MODE2_EVCTRL_ALARMEO0_Pos) +#define RTC_MODE2_EVCTRL_ALARMEO_Pos 8 /**< \brief (RTC_MODE2_EVCTRL) Alarm x Event Output Enable */ +#define RTC_MODE2_EVCTRL_ALARMEO_Msk (0x1u << RTC_MODE2_EVCTRL_ALARMEO_Pos) +#define RTC_MODE2_EVCTRL_ALARMEO(value) ((RTC_MODE2_EVCTRL_ALARMEO_Msk & ((value) << RTC_MODE2_EVCTRL_ALARMEO_Pos))) +#define RTC_MODE2_EVCTRL_OVFEO_Pos 15 /**< \brief (RTC_MODE2_EVCTRL) Overflow Event Output Enable */ +#define RTC_MODE2_EVCTRL_OVFEO (0x1u << RTC_MODE2_EVCTRL_OVFEO_Pos) +#define RTC_MODE2_EVCTRL_MASK 0x81FFu /**< \brief (RTC_MODE2_EVCTRL) MASK Register */ + +/* -------- RTC_MODE0_INTENCLR : (RTC Offset: 0x06) (R/W 8) MODE0 MODE0 Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CMP0:1; /*!< bit: 0 Compare 0 Interrupt Enable */ + uint8_t :5; /*!< bit: 1.. 5 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 6 Synchronization Ready Interrupt Enable */ + uint8_t OVF:1; /*!< bit: 7 Overflow Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t CMP:1; /*!< bit: 0 Compare x Interrupt Enable */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE0_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE0_INTENCLR_OFFSET 0x06 /**< \brief (RTC_MODE0_INTENCLR offset) MODE0 Interrupt Enable Clear */ +#define RTC_MODE0_INTENCLR_RESETVALUE 0x00 /**< \brief (RTC_MODE0_INTENCLR reset_value) MODE0 Interrupt Enable Clear */ + +#define RTC_MODE0_INTENCLR_CMP0_Pos 0 /**< \brief (RTC_MODE0_INTENCLR) Compare 0 Interrupt Enable */ +#define RTC_MODE0_INTENCLR_CMP0 (1 << RTC_MODE0_INTENCLR_CMP0_Pos) +#define RTC_MODE0_INTENCLR_CMP_Pos 0 /**< \brief (RTC_MODE0_INTENCLR) Compare x Interrupt Enable */ +#define RTC_MODE0_INTENCLR_CMP_Msk (0x1u << RTC_MODE0_INTENCLR_CMP_Pos) +#define RTC_MODE0_INTENCLR_CMP(value) ((RTC_MODE0_INTENCLR_CMP_Msk & ((value) << RTC_MODE0_INTENCLR_CMP_Pos))) +#define RTC_MODE0_INTENCLR_SYNCRDY_Pos 6 /**< \brief (RTC_MODE0_INTENCLR) Synchronization Ready Interrupt Enable */ +#define RTC_MODE0_INTENCLR_SYNCRDY (0x1u << RTC_MODE0_INTENCLR_SYNCRDY_Pos) +#define RTC_MODE0_INTENCLR_OVF_Pos 7 /**< \brief (RTC_MODE0_INTENCLR) Overflow Interrupt Enable */ +#define RTC_MODE0_INTENCLR_OVF (0x1u << RTC_MODE0_INTENCLR_OVF_Pos) +#define RTC_MODE0_INTENCLR_MASK 0xC1u /**< \brief (RTC_MODE0_INTENCLR) MASK Register */ + +/* -------- RTC_MODE1_INTENCLR : (RTC Offset: 0x06) (R/W 8) MODE1 MODE1 Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CMP0:1; /*!< bit: 0 Compare 0 Interrupt Enable */ + uint8_t CMP1:1; /*!< bit: 1 Compare 1 Interrupt Enable */ + uint8_t :4; /*!< bit: 2.. 5 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 6 Synchronization Ready Interrupt Enable */ + uint8_t OVF:1; /*!< bit: 7 Overflow Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t CMP:2; /*!< bit: 0.. 1 Compare x Interrupt Enable */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE1_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE1_INTENCLR_OFFSET 0x06 /**< \brief (RTC_MODE1_INTENCLR offset) MODE1 Interrupt Enable Clear */ +#define RTC_MODE1_INTENCLR_RESETVALUE 0x00 /**< \brief (RTC_MODE1_INTENCLR reset_value) MODE1 Interrupt Enable Clear */ + +#define RTC_MODE1_INTENCLR_CMP0_Pos 0 /**< \brief (RTC_MODE1_INTENCLR) Compare 0 Interrupt Enable */ +#define RTC_MODE1_INTENCLR_CMP0 (1 << RTC_MODE1_INTENCLR_CMP0_Pos) +#define RTC_MODE1_INTENCLR_CMP1_Pos 1 /**< \brief (RTC_MODE1_INTENCLR) Compare 1 Interrupt Enable */ +#define RTC_MODE1_INTENCLR_CMP1 (1 << RTC_MODE1_INTENCLR_CMP1_Pos) +#define RTC_MODE1_INTENCLR_CMP_Pos 0 /**< \brief (RTC_MODE1_INTENCLR) Compare x Interrupt Enable */ +#define RTC_MODE1_INTENCLR_CMP_Msk (0x3u << RTC_MODE1_INTENCLR_CMP_Pos) +#define RTC_MODE1_INTENCLR_CMP(value) ((RTC_MODE1_INTENCLR_CMP_Msk & ((value) << RTC_MODE1_INTENCLR_CMP_Pos))) +#define RTC_MODE1_INTENCLR_SYNCRDY_Pos 6 /**< \brief (RTC_MODE1_INTENCLR) Synchronization Ready Interrupt Enable */ +#define RTC_MODE1_INTENCLR_SYNCRDY (0x1u << RTC_MODE1_INTENCLR_SYNCRDY_Pos) +#define RTC_MODE1_INTENCLR_OVF_Pos 7 /**< \brief (RTC_MODE1_INTENCLR) Overflow Interrupt Enable */ +#define RTC_MODE1_INTENCLR_OVF (0x1u << RTC_MODE1_INTENCLR_OVF_Pos) +#define RTC_MODE1_INTENCLR_MASK 0xC3u /**< \brief (RTC_MODE1_INTENCLR) MASK Register */ + +/* -------- RTC_MODE2_INTENCLR : (RTC Offset: 0x06) (R/W 8) MODE2 MODE2 Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t ALARM0:1; /*!< bit: 0 Alarm 0 Interrupt Enable */ + uint8_t :5; /*!< bit: 1.. 5 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 6 Synchronization Ready Interrupt Enable */ + uint8_t OVF:1; /*!< bit: 7 Overflow Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t ALARM:1; /*!< bit: 0 Alarm x Interrupt Enable */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE2_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE2_INTENCLR_OFFSET 0x06 /**< \brief (RTC_MODE2_INTENCLR offset) MODE2 Interrupt Enable Clear */ +#define RTC_MODE2_INTENCLR_RESETVALUE 0x00 /**< \brief (RTC_MODE2_INTENCLR reset_value) MODE2 Interrupt Enable Clear */ + +#define RTC_MODE2_INTENCLR_ALARM0_Pos 0 /**< \brief (RTC_MODE2_INTENCLR) Alarm 0 Interrupt Enable */ +#define RTC_MODE2_INTENCLR_ALARM0 (1 << RTC_MODE2_INTENCLR_ALARM0_Pos) +#define RTC_MODE2_INTENCLR_ALARM_Pos 0 /**< \brief (RTC_MODE2_INTENCLR) Alarm x Interrupt Enable */ +#define RTC_MODE2_INTENCLR_ALARM_Msk (0x1u << RTC_MODE2_INTENCLR_ALARM_Pos) +#define RTC_MODE2_INTENCLR_ALARM(value) ((RTC_MODE2_INTENCLR_ALARM_Msk & ((value) << RTC_MODE2_INTENCLR_ALARM_Pos))) +#define RTC_MODE2_INTENCLR_SYNCRDY_Pos 6 /**< \brief (RTC_MODE2_INTENCLR) Synchronization Ready Interrupt Enable */ +#define RTC_MODE2_INTENCLR_SYNCRDY (0x1u << RTC_MODE2_INTENCLR_SYNCRDY_Pos) +#define RTC_MODE2_INTENCLR_OVF_Pos 7 /**< \brief (RTC_MODE2_INTENCLR) Overflow Interrupt Enable */ +#define RTC_MODE2_INTENCLR_OVF (0x1u << RTC_MODE2_INTENCLR_OVF_Pos) +#define RTC_MODE2_INTENCLR_MASK 0xC1u /**< \brief (RTC_MODE2_INTENCLR) MASK Register */ + +/* -------- RTC_MODE0_INTENSET : (RTC Offset: 0x07) (R/W 8) MODE0 MODE0 Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CMP0:1; /*!< bit: 0 Compare 0 Interrupt Enable */ + uint8_t :5; /*!< bit: 1.. 5 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 6 Synchronization Ready Interrupt Enable */ + uint8_t OVF:1; /*!< bit: 7 Overflow Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t CMP:1; /*!< bit: 0 Compare x Interrupt Enable */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE0_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE0_INTENSET_OFFSET 0x07 /**< \brief (RTC_MODE0_INTENSET offset) MODE0 Interrupt Enable Set */ +#define RTC_MODE0_INTENSET_RESETVALUE 0x00 /**< \brief (RTC_MODE0_INTENSET reset_value) MODE0 Interrupt Enable Set */ + +#define RTC_MODE0_INTENSET_CMP0_Pos 0 /**< \brief (RTC_MODE0_INTENSET) Compare 0 Interrupt Enable */ +#define RTC_MODE0_INTENSET_CMP0 (1 << RTC_MODE0_INTENSET_CMP0_Pos) +#define RTC_MODE0_INTENSET_CMP_Pos 0 /**< \brief (RTC_MODE0_INTENSET) Compare x Interrupt Enable */ +#define RTC_MODE0_INTENSET_CMP_Msk (0x1u << RTC_MODE0_INTENSET_CMP_Pos) +#define RTC_MODE0_INTENSET_CMP(value) ((RTC_MODE0_INTENSET_CMP_Msk & ((value) << RTC_MODE0_INTENSET_CMP_Pos))) +#define RTC_MODE0_INTENSET_SYNCRDY_Pos 6 /**< \brief (RTC_MODE0_INTENSET) Synchronization Ready Interrupt Enable */ +#define RTC_MODE0_INTENSET_SYNCRDY (0x1u << RTC_MODE0_INTENSET_SYNCRDY_Pos) +#define RTC_MODE0_INTENSET_OVF_Pos 7 /**< \brief (RTC_MODE0_INTENSET) Overflow Interrupt Enable */ +#define RTC_MODE0_INTENSET_OVF (0x1u << RTC_MODE0_INTENSET_OVF_Pos) +#define RTC_MODE0_INTENSET_MASK 0xC1u /**< \brief (RTC_MODE0_INTENSET) MASK Register */ + +/* -------- RTC_MODE1_INTENSET : (RTC Offset: 0x07) (R/W 8) MODE1 MODE1 Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CMP0:1; /*!< bit: 0 Compare 0 Interrupt Enable */ + uint8_t CMP1:1; /*!< bit: 1 Compare 1 Interrupt Enable */ + uint8_t :4; /*!< bit: 2.. 5 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 6 Synchronization Ready Interrupt Enable */ + uint8_t OVF:1; /*!< bit: 7 Overflow Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t CMP:2; /*!< bit: 0.. 1 Compare x Interrupt Enable */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE1_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE1_INTENSET_OFFSET 0x07 /**< \brief (RTC_MODE1_INTENSET offset) MODE1 Interrupt Enable Set */ +#define RTC_MODE1_INTENSET_RESETVALUE 0x00 /**< \brief (RTC_MODE1_INTENSET reset_value) MODE1 Interrupt Enable Set */ + +#define RTC_MODE1_INTENSET_CMP0_Pos 0 /**< \brief (RTC_MODE1_INTENSET) Compare 0 Interrupt Enable */ +#define RTC_MODE1_INTENSET_CMP0 (1 << RTC_MODE1_INTENSET_CMP0_Pos) +#define RTC_MODE1_INTENSET_CMP1_Pos 1 /**< \brief (RTC_MODE1_INTENSET) Compare 1 Interrupt Enable */ +#define RTC_MODE1_INTENSET_CMP1 (1 << RTC_MODE1_INTENSET_CMP1_Pos) +#define RTC_MODE1_INTENSET_CMP_Pos 0 /**< \brief (RTC_MODE1_INTENSET) Compare x Interrupt Enable */ +#define RTC_MODE1_INTENSET_CMP_Msk (0x3u << RTC_MODE1_INTENSET_CMP_Pos) +#define RTC_MODE1_INTENSET_CMP(value) ((RTC_MODE1_INTENSET_CMP_Msk & ((value) << RTC_MODE1_INTENSET_CMP_Pos))) +#define RTC_MODE1_INTENSET_SYNCRDY_Pos 6 /**< \brief (RTC_MODE1_INTENSET) Synchronization Ready Interrupt Enable */ +#define RTC_MODE1_INTENSET_SYNCRDY (0x1u << RTC_MODE1_INTENSET_SYNCRDY_Pos) +#define RTC_MODE1_INTENSET_OVF_Pos 7 /**< \brief (RTC_MODE1_INTENSET) Overflow Interrupt Enable */ +#define RTC_MODE1_INTENSET_OVF (0x1u << RTC_MODE1_INTENSET_OVF_Pos) +#define RTC_MODE1_INTENSET_MASK 0xC3u /**< \brief (RTC_MODE1_INTENSET) MASK Register */ + +/* -------- RTC_MODE2_INTENSET : (RTC Offset: 0x07) (R/W 8) MODE2 MODE2 Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t ALARM0:1; /*!< bit: 0 Alarm 0 Interrupt Enable */ + uint8_t :5; /*!< bit: 1.. 5 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 6 Synchronization Ready Interrupt Enable */ + uint8_t OVF:1; /*!< bit: 7 Overflow Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t ALARM:1; /*!< bit: 0 Alarm x Interrupt Enable */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE2_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE2_INTENSET_OFFSET 0x07 /**< \brief (RTC_MODE2_INTENSET offset) MODE2 Interrupt Enable Set */ +#define RTC_MODE2_INTENSET_RESETVALUE 0x00 /**< \brief (RTC_MODE2_INTENSET reset_value) MODE2 Interrupt Enable Set */ + +#define RTC_MODE2_INTENSET_ALARM0_Pos 0 /**< \brief (RTC_MODE2_INTENSET) Alarm 0 Interrupt Enable */ +#define RTC_MODE2_INTENSET_ALARM0 (1 << RTC_MODE2_INTENSET_ALARM0_Pos) +#define RTC_MODE2_INTENSET_ALARM_Pos 0 /**< \brief (RTC_MODE2_INTENSET) Alarm x Interrupt Enable */ +#define RTC_MODE2_INTENSET_ALARM_Msk (0x1u << RTC_MODE2_INTENSET_ALARM_Pos) +#define RTC_MODE2_INTENSET_ALARM(value) ((RTC_MODE2_INTENSET_ALARM_Msk & ((value) << RTC_MODE2_INTENSET_ALARM_Pos))) +#define RTC_MODE2_INTENSET_SYNCRDY_Pos 6 /**< \brief (RTC_MODE2_INTENSET) Synchronization Ready Interrupt Enable */ +#define RTC_MODE2_INTENSET_SYNCRDY (0x1u << RTC_MODE2_INTENSET_SYNCRDY_Pos) +#define RTC_MODE2_INTENSET_OVF_Pos 7 /**< \brief (RTC_MODE2_INTENSET) Overflow Interrupt Enable */ +#define RTC_MODE2_INTENSET_OVF (0x1u << RTC_MODE2_INTENSET_OVF_Pos) +#define RTC_MODE2_INTENSET_MASK 0xC1u /**< \brief (RTC_MODE2_INTENSET) MASK Register */ + +/* -------- RTC_MODE0_INTFLAG : (RTC Offset: 0x08) (R/W 8) MODE0 MODE0 Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CMP0:1; /*!< bit: 0 Compare 0 */ + uint8_t :5; /*!< bit: 1.. 5 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 6 Synchronization Ready */ + uint8_t OVF:1; /*!< bit: 7 Overflow */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t CMP:1; /*!< bit: 0 Compare x */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE0_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE0_INTFLAG_OFFSET 0x08 /**< \brief (RTC_MODE0_INTFLAG offset) MODE0 Interrupt Flag Status and Clear */ +#define RTC_MODE0_INTFLAG_RESETVALUE 0x00 /**< \brief (RTC_MODE0_INTFLAG reset_value) MODE0 Interrupt Flag Status and Clear */ + +#define RTC_MODE0_INTFLAG_CMP0_Pos 0 /**< \brief (RTC_MODE0_INTFLAG) Compare 0 */ +#define RTC_MODE0_INTFLAG_CMP0 (1 << RTC_MODE0_INTFLAG_CMP0_Pos) +#define RTC_MODE0_INTFLAG_CMP_Pos 0 /**< \brief (RTC_MODE0_INTFLAG) Compare x */ +#define RTC_MODE0_INTFLAG_CMP_Msk (0x1u << RTC_MODE0_INTFLAG_CMP_Pos) +#define RTC_MODE0_INTFLAG_CMP(value) ((RTC_MODE0_INTFLAG_CMP_Msk & ((value) << RTC_MODE0_INTFLAG_CMP_Pos))) +#define RTC_MODE0_INTFLAG_SYNCRDY_Pos 6 /**< \brief (RTC_MODE0_INTFLAG) Synchronization Ready */ +#define RTC_MODE0_INTFLAG_SYNCRDY (0x1u << RTC_MODE0_INTFLAG_SYNCRDY_Pos) +#define RTC_MODE0_INTFLAG_OVF_Pos 7 /**< \brief (RTC_MODE0_INTFLAG) Overflow */ +#define RTC_MODE0_INTFLAG_OVF (0x1u << RTC_MODE0_INTFLAG_OVF_Pos) +#define RTC_MODE0_INTFLAG_MASK 0xC1u /**< \brief (RTC_MODE0_INTFLAG) MASK Register */ + +/* -------- RTC_MODE1_INTFLAG : (RTC Offset: 0x08) (R/W 8) MODE1 MODE1 Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CMP0:1; /*!< bit: 0 Compare 0 */ + uint8_t CMP1:1; /*!< bit: 1 Compare 1 */ + uint8_t :4; /*!< bit: 2.. 5 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 6 Synchronization Ready */ + uint8_t OVF:1; /*!< bit: 7 Overflow */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t CMP:2; /*!< bit: 0.. 1 Compare x */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE1_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE1_INTFLAG_OFFSET 0x08 /**< \brief (RTC_MODE1_INTFLAG offset) MODE1 Interrupt Flag Status and Clear */ +#define RTC_MODE1_INTFLAG_RESETVALUE 0x00 /**< \brief (RTC_MODE1_INTFLAG reset_value) MODE1 Interrupt Flag Status and Clear */ + +#define RTC_MODE1_INTFLAG_CMP0_Pos 0 /**< \brief (RTC_MODE1_INTFLAG) Compare 0 */ +#define RTC_MODE1_INTFLAG_CMP0 (1 << RTC_MODE1_INTFLAG_CMP0_Pos) +#define RTC_MODE1_INTFLAG_CMP1_Pos 1 /**< \brief (RTC_MODE1_INTFLAG) Compare 1 */ +#define RTC_MODE1_INTFLAG_CMP1 (1 << RTC_MODE1_INTFLAG_CMP1_Pos) +#define RTC_MODE1_INTFLAG_CMP_Pos 0 /**< \brief (RTC_MODE1_INTFLAG) Compare x */ +#define RTC_MODE1_INTFLAG_CMP_Msk (0x3u << RTC_MODE1_INTFLAG_CMP_Pos) +#define RTC_MODE1_INTFLAG_CMP(value) ((RTC_MODE1_INTFLAG_CMP_Msk & ((value) << RTC_MODE1_INTFLAG_CMP_Pos))) +#define RTC_MODE1_INTFLAG_SYNCRDY_Pos 6 /**< \brief (RTC_MODE1_INTFLAG) Synchronization Ready */ +#define RTC_MODE1_INTFLAG_SYNCRDY (0x1u << RTC_MODE1_INTFLAG_SYNCRDY_Pos) +#define RTC_MODE1_INTFLAG_OVF_Pos 7 /**< \brief (RTC_MODE1_INTFLAG) Overflow */ +#define RTC_MODE1_INTFLAG_OVF (0x1u << RTC_MODE1_INTFLAG_OVF_Pos) +#define RTC_MODE1_INTFLAG_MASK 0xC3u /**< \brief (RTC_MODE1_INTFLAG) MASK Register */ + +/* -------- RTC_MODE2_INTFLAG : (RTC Offset: 0x08) (R/W 8) MODE2 MODE2 Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t ALARM0:1; /*!< bit: 0 Alarm 0 */ + uint8_t :5; /*!< bit: 1.. 5 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 6 Synchronization Ready */ + uint8_t OVF:1; /*!< bit: 7 Overflow */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t ALARM:1; /*!< bit: 0 Alarm x */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE2_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE2_INTFLAG_OFFSET 0x08 /**< \brief (RTC_MODE2_INTFLAG offset) MODE2 Interrupt Flag Status and Clear */ +#define RTC_MODE2_INTFLAG_RESETVALUE 0x00 /**< \brief (RTC_MODE2_INTFLAG reset_value) MODE2 Interrupt Flag Status and Clear */ + +#define RTC_MODE2_INTFLAG_ALARM0_Pos 0 /**< \brief (RTC_MODE2_INTFLAG) Alarm 0 */ +#define RTC_MODE2_INTFLAG_ALARM0 (1 << RTC_MODE2_INTFLAG_ALARM0_Pos) +#define RTC_MODE2_INTFLAG_ALARM_Pos 0 /**< \brief (RTC_MODE2_INTFLAG) Alarm x */ +#define RTC_MODE2_INTFLAG_ALARM_Msk (0x1u << RTC_MODE2_INTFLAG_ALARM_Pos) +#define RTC_MODE2_INTFLAG_ALARM(value) ((RTC_MODE2_INTFLAG_ALARM_Msk & ((value) << RTC_MODE2_INTFLAG_ALARM_Pos))) +#define RTC_MODE2_INTFLAG_SYNCRDY_Pos 6 /**< \brief (RTC_MODE2_INTFLAG) Synchronization Ready */ +#define RTC_MODE2_INTFLAG_SYNCRDY (0x1u << RTC_MODE2_INTFLAG_SYNCRDY_Pos) +#define RTC_MODE2_INTFLAG_OVF_Pos 7 /**< \brief (RTC_MODE2_INTFLAG) Overflow */ +#define RTC_MODE2_INTFLAG_OVF (0x1u << RTC_MODE2_INTFLAG_OVF_Pos) +#define RTC_MODE2_INTFLAG_MASK 0xC1u /**< \brief (RTC_MODE2_INTFLAG) MASK Register */ + +/* -------- RTC_STATUS : (RTC Offset: 0x0A) (R/W 8) Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :7; /*!< bit: 0.. 6 Reserved */ + uint8_t SYNCBUSY:1; /*!< bit: 7 Synchronization Busy */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_STATUS_OFFSET 0x0A /**< \brief (RTC_STATUS offset) Status */ +#define RTC_STATUS_RESETVALUE 0x00 /**< \brief (RTC_STATUS reset_value) Status */ + +#define RTC_STATUS_SYNCBUSY_Pos 7 /**< \brief (RTC_STATUS) Synchronization Busy */ +#define RTC_STATUS_SYNCBUSY (0x1u << RTC_STATUS_SYNCBUSY_Pos) +#define RTC_STATUS_MASK 0x80u /**< \brief (RTC_STATUS) MASK Register */ + +/* -------- RTC_DBGCTRL : (RTC Offset: 0x0B) (R/W 8) Debug Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DBGRUN:1; /*!< bit: 0 Run During Debug */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_DBGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_DBGCTRL_OFFSET 0x0B /**< \brief (RTC_DBGCTRL offset) Debug Control */ +#define RTC_DBGCTRL_RESETVALUE 0x00 /**< \brief (RTC_DBGCTRL reset_value) Debug Control */ + +#define RTC_DBGCTRL_DBGRUN_Pos 0 /**< \brief (RTC_DBGCTRL) Run During Debug */ +#define RTC_DBGCTRL_DBGRUN (0x1u << RTC_DBGCTRL_DBGRUN_Pos) +#define RTC_DBGCTRL_MASK 0x01u /**< \brief (RTC_DBGCTRL) MASK Register */ + +/* -------- RTC_FREQCORR : (RTC Offset: 0x0C) (R/W 8) Frequency Correction -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t VALUE:7; /*!< bit: 0.. 6 Correction Value */ + uint8_t SIGN:1; /*!< bit: 7 Correction Sign */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_FREQCORR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_FREQCORR_OFFSET 0x0C /**< \brief (RTC_FREQCORR offset) Frequency Correction */ +#define RTC_FREQCORR_RESETVALUE 0x00 /**< \brief (RTC_FREQCORR reset_value) Frequency Correction */ + +#define RTC_FREQCORR_VALUE_Pos 0 /**< \brief (RTC_FREQCORR) Correction Value */ +#define RTC_FREQCORR_VALUE_Msk (0x7Fu << RTC_FREQCORR_VALUE_Pos) +#define RTC_FREQCORR_VALUE(value) ((RTC_FREQCORR_VALUE_Msk & ((value) << RTC_FREQCORR_VALUE_Pos))) +#define RTC_FREQCORR_SIGN_Pos 7 /**< \brief (RTC_FREQCORR) Correction Sign */ +#define RTC_FREQCORR_SIGN (0x1u << RTC_FREQCORR_SIGN_Pos) +#define RTC_FREQCORR_MASK 0xFFu /**< \brief (RTC_FREQCORR) MASK Register */ + +/* -------- RTC_MODE0_COUNT : (RTC Offset: 0x10) (R/W 32) MODE0 MODE0 Counter Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t COUNT:32; /*!< bit: 0..31 Counter Value */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} RTC_MODE0_COUNT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE0_COUNT_OFFSET 0x10 /**< \brief (RTC_MODE0_COUNT offset) MODE0 Counter Value */ +#define RTC_MODE0_COUNT_RESETVALUE 0x00000000 /**< \brief (RTC_MODE0_COUNT reset_value) MODE0 Counter Value */ + +#define RTC_MODE0_COUNT_COUNT_Pos 0 /**< \brief (RTC_MODE0_COUNT) Counter Value */ +#define RTC_MODE0_COUNT_COUNT_Msk (0xFFFFFFFFu << RTC_MODE0_COUNT_COUNT_Pos) +#define RTC_MODE0_COUNT_COUNT(value) ((RTC_MODE0_COUNT_COUNT_Msk & ((value) << RTC_MODE0_COUNT_COUNT_Pos))) +#define RTC_MODE0_COUNT_MASK 0xFFFFFFFFu /**< \brief (RTC_MODE0_COUNT) MASK Register */ + +/* -------- RTC_MODE1_COUNT : (RTC Offset: 0x10) (R/W 16) MODE1 MODE1 Counter Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t COUNT:16; /*!< bit: 0..15 Counter Value */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_MODE1_COUNT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE1_COUNT_OFFSET 0x10 /**< \brief (RTC_MODE1_COUNT offset) MODE1 Counter Value */ +#define RTC_MODE1_COUNT_RESETVALUE 0x0000 /**< \brief (RTC_MODE1_COUNT reset_value) MODE1 Counter Value */ + +#define RTC_MODE1_COUNT_COUNT_Pos 0 /**< \brief (RTC_MODE1_COUNT) Counter Value */ +#define RTC_MODE1_COUNT_COUNT_Msk (0xFFFFu << RTC_MODE1_COUNT_COUNT_Pos) +#define RTC_MODE1_COUNT_COUNT(value) ((RTC_MODE1_COUNT_COUNT_Msk & ((value) << RTC_MODE1_COUNT_COUNT_Pos))) +#define RTC_MODE1_COUNT_MASK 0xFFFFu /**< \brief (RTC_MODE1_COUNT) MASK Register */ + +/* -------- RTC_MODE2_CLOCK : (RTC Offset: 0x10) (R/W 32) MODE2 MODE2 Clock Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SECOND:6; /*!< bit: 0.. 5 Second */ + uint32_t MINUTE:6; /*!< bit: 6..11 Minute */ + uint32_t HOUR:5; /*!< bit: 12..16 Hour */ + uint32_t DAY:5; /*!< bit: 17..21 Day */ + uint32_t MONTH:4; /*!< bit: 22..25 Month */ + uint32_t YEAR:6; /*!< bit: 26..31 Year */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} RTC_MODE2_CLOCK_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE2_CLOCK_OFFSET 0x10 /**< \brief (RTC_MODE2_CLOCK offset) MODE2 Clock Value */ +#define RTC_MODE2_CLOCK_RESETVALUE 0x00000000 /**< \brief (RTC_MODE2_CLOCK reset_value) MODE2 Clock Value */ + +#define RTC_MODE2_CLOCK_SECOND_Pos 0 /**< \brief (RTC_MODE2_CLOCK) Second */ +#define RTC_MODE2_CLOCK_SECOND_Msk (0x3Fu << RTC_MODE2_CLOCK_SECOND_Pos) +#define RTC_MODE2_CLOCK_SECOND(value) ((RTC_MODE2_CLOCK_SECOND_Msk & ((value) << RTC_MODE2_CLOCK_SECOND_Pos))) +#define RTC_MODE2_CLOCK_MINUTE_Pos 6 /**< \brief (RTC_MODE2_CLOCK) Minute */ +#define RTC_MODE2_CLOCK_MINUTE_Msk (0x3Fu << RTC_MODE2_CLOCK_MINUTE_Pos) +#define RTC_MODE2_CLOCK_MINUTE(value) ((RTC_MODE2_CLOCK_MINUTE_Msk & ((value) << RTC_MODE2_CLOCK_MINUTE_Pos))) +#define RTC_MODE2_CLOCK_HOUR_Pos 12 /**< \brief (RTC_MODE2_CLOCK) Hour */ +#define RTC_MODE2_CLOCK_HOUR_Msk (0x1Fu << RTC_MODE2_CLOCK_HOUR_Pos) +#define RTC_MODE2_CLOCK_HOUR(value) ((RTC_MODE2_CLOCK_HOUR_Msk & ((value) << RTC_MODE2_CLOCK_HOUR_Pos))) +#define RTC_MODE2_CLOCK_HOUR_PM_Val 0x10u /**< \brief (RTC_MODE2_CLOCK) Afternoon Hour */ +#define RTC_MODE2_CLOCK_HOUR_PM (RTC_MODE2_CLOCK_HOUR_PM_Val << RTC_MODE2_CLOCK_HOUR_Pos) +#define RTC_MODE2_CLOCK_DAY_Pos 17 /**< \brief (RTC_MODE2_CLOCK) Day */ +#define RTC_MODE2_CLOCK_DAY_Msk (0x1Fu << RTC_MODE2_CLOCK_DAY_Pos) +#define RTC_MODE2_CLOCK_DAY(value) ((RTC_MODE2_CLOCK_DAY_Msk & ((value) << RTC_MODE2_CLOCK_DAY_Pos))) +#define RTC_MODE2_CLOCK_MONTH_Pos 22 /**< \brief (RTC_MODE2_CLOCK) Month */ +#define RTC_MODE2_CLOCK_MONTH_Msk (0xFu << RTC_MODE2_CLOCK_MONTH_Pos) +#define RTC_MODE2_CLOCK_MONTH(value) ((RTC_MODE2_CLOCK_MONTH_Msk & ((value) << RTC_MODE2_CLOCK_MONTH_Pos))) +#define RTC_MODE2_CLOCK_YEAR_Pos 26 /**< \brief (RTC_MODE2_CLOCK) Year */ +#define RTC_MODE2_CLOCK_YEAR_Msk (0x3Fu << RTC_MODE2_CLOCK_YEAR_Pos) +#define RTC_MODE2_CLOCK_YEAR(value) ((RTC_MODE2_CLOCK_YEAR_Msk & ((value) << RTC_MODE2_CLOCK_YEAR_Pos))) +#define RTC_MODE2_CLOCK_MASK 0xFFFFFFFFu /**< \brief (RTC_MODE2_CLOCK) MASK Register */ + +/* -------- RTC_MODE1_PER : (RTC Offset: 0x14) (R/W 16) MODE1 MODE1 Counter Period -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t PER:16; /*!< bit: 0..15 Counter Period */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_MODE1_PER_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE1_PER_OFFSET 0x14 /**< \brief (RTC_MODE1_PER offset) MODE1 Counter Period */ +#define RTC_MODE1_PER_RESETVALUE 0x0000 /**< \brief (RTC_MODE1_PER reset_value) MODE1 Counter Period */ + +#define RTC_MODE1_PER_PER_Pos 0 /**< \brief (RTC_MODE1_PER) Counter Period */ +#define RTC_MODE1_PER_PER_Msk (0xFFFFu << RTC_MODE1_PER_PER_Pos) +#define RTC_MODE1_PER_PER(value) ((RTC_MODE1_PER_PER_Msk & ((value) << RTC_MODE1_PER_PER_Pos))) +#define RTC_MODE1_PER_MASK 0xFFFFu /**< \brief (RTC_MODE1_PER) MASK Register */ + +/* -------- RTC_MODE0_COMP : (RTC Offset: 0x18) (R/W 32) MODE0 MODE0 Compare n Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t COMP:32; /*!< bit: 0..31 Compare Value */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} RTC_MODE0_COMP_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE0_COMP_OFFSET 0x18 /**< \brief (RTC_MODE0_COMP offset) MODE0 Compare n Value */ +#define RTC_MODE0_COMP_RESETVALUE 0x00000000 /**< \brief (RTC_MODE0_COMP reset_value) MODE0 Compare n Value */ + +#define RTC_MODE0_COMP_COMP_Pos 0 /**< \brief (RTC_MODE0_COMP) Compare Value */ +#define RTC_MODE0_COMP_COMP_Msk (0xFFFFFFFFu << RTC_MODE0_COMP_COMP_Pos) +#define RTC_MODE0_COMP_COMP(value) ((RTC_MODE0_COMP_COMP_Msk & ((value) << RTC_MODE0_COMP_COMP_Pos))) +#define RTC_MODE0_COMP_MASK 0xFFFFFFFFu /**< \brief (RTC_MODE0_COMP) MASK Register */ + +/* -------- RTC_MODE1_COMP : (RTC Offset: 0x18) (R/W 16) MODE1 MODE1 Compare n Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t COMP:16; /*!< bit: 0..15 Compare Value */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_MODE1_COMP_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE1_COMP_OFFSET 0x18 /**< \brief (RTC_MODE1_COMP offset) MODE1 Compare n Value */ +#define RTC_MODE1_COMP_RESETVALUE 0x0000 /**< \brief (RTC_MODE1_COMP reset_value) MODE1 Compare n Value */ + +#define RTC_MODE1_COMP_COMP_Pos 0 /**< \brief (RTC_MODE1_COMP) Compare Value */ +#define RTC_MODE1_COMP_COMP_Msk (0xFFFFu << RTC_MODE1_COMP_COMP_Pos) +#define RTC_MODE1_COMP_COMP(value) ((RTC_MODE1_COMP_COMP_Msk & ((value) << RTC_MODE1_COMP_COMP_Pos))) +#define RTC_MODE1_COMP_MASK 0xFFFFu /**< \brief (RTC_MODE1_COMP) MASK Register */ + +/* -------- RTC_MODE2_ALARM : (RTC Offset: 0x18) (R/W 32) MODE2 MODE2_ALARM Alarm n Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SECOND:6; /*!< bit: 0.. 5 Second */ + uint32_t MINUTE:6; /*!< bit: 6..11 Minute */ + uint32_t HOUR:5; /*!< bit: 12..16 Hour */ + uint32_t DAY:5; /*!< bit: 17..21 Day */ + uint32_t MONTH:4; /*!< bit: 22..25 Month */ + uint32_t YEAR:6; /*!< bit: 26..31 Year */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} RTC_MODE2_ALARM_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE2_ALARM_OFFSET 0x18 /**< \brief (RTC_MODE2_ALARM offset) MODE2_ALARM Alarm n Value */ +#define RTC_MODE2_ALARM_RESETVALUE 0x00000000 /**< \brief (RTC_MODE2_ALARM reset_value) MODE2_ALARM Alarm n Value */ + +#define RTC_MODE2_ALARM_SECOND_Pos 0 /**< \brief (RTC_MODE2_ALARM) Second */ +#define RTC_MODE2_ALARM_SECOND_Msk (0x3Fu << RTC_MODE2_ALARM_SECOND_Pos) +#define RTC_MODE2_ALARM_SECOND(value) ((RTC_MODE2_ALARM_SECOND_Msk & ((value) << RTC_MODE2_ALARM_SECOND_Pos))) +#define RTC_MODE2_ALARM_MINUTE_Pos 6 /**< \brief (RTC_MODE2_ALARM) Minute */ +#define RTC_MODE2_ALARM_MINUTE_Msk (0x3Fu << RTC_MODE2_ALARM_MINUTE_Pos) +#define RTC_MODE2_ALARM_MINUTE(value) ((RTC_MODE2_ALARM_MINUTE_Msk & ((value) << RTC_MODE2_ALARM_MINUTE_Pos))) +#define RTC_MODE2_ALARM_HOUR_Pos 12 /**< \brief (RTC_MODE2_ALARM) Hour */ +#define RTC_MODE2_ALARM_HOUR_Msk (0x1Fu << RTC_MODE2_ALARM_HOUR_Pos) +#define RTC_MODE2_ALARM_HOUR(value) ((RTC_MODE2_ALARM_HOUR_Msk & ((value) << RTC_MODE2_ALARM_HOUR_Pos))) +#define RTC_MODE2_ALARM_DAY_Pos 17 /**< \brief (RTC_MODE2_ALARM) Day */ +#define RTC_MODE2_ALARM_DAY_Msk (0x1Fu << RTC_MODE2_ALARM_DAY_Pos) +#define RTC_MODE2_ALARM_DAY(value) ((RTC_MODE2_ALARM_DAY_Msk & ((value) << RTC_MODE2_ALARM_DAY_Pos))) +#define RTC_MODE2_ALARM_MONTH_Pos 22 /**< \brief (RTC_MODE2_ALARM) Month */ +#define RTC_MODE2_ALARM_MONTH_Msk (0xFu << RTC_MODE2_ALARM_MONTH_Pos) +#define RTC_MODE2_ALARM_MONTH(value) ((RTC_MODE2_ALARM_MONTH_Msk & ((value) << RTC_MODE2_ALARM_MONTH_Pos))) +#define RTC_MODE2_ALARM_YEAR_Pos 26 /**< \brief (RTC_MODE2_ALARM) Year */ +#define RTC_MODE2_ALARM_YEAR_Msk (0x3Fu << RTC_MODE2_ALARM_YEAR_Pos) +#define RTC_MODE2_ALARM_YEAR(value) ((RTC_MODE2_ALARM_YEAR_Msk & ((value) << RTC_MODE2_ALARM_YEAR_Pos))) +#define RTC_MODE2_ALARM_MASK 0xFFFFFFFFu /**< \brief (RTC_MODE2_ALARM) MASK Register */ + +/* -------- RTC_MODE2_MASK : (RTC Offset: 0x1C) (R/W 8) MODE2 MODE2_ALARM Alarm n Mask -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SEL:3; /*!< bit: 0.. 2 Alarm Mask Selection */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE2_MASK_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE2_MASK_OFFSET 0x1C /**< \brief (RTC_MODE2_MASK offset) MODE2_ALARM Alarm n Mask */ +#define RTC_MODE2_MASK_RESETVALUE 0x00 /**< \brief (RTC_MODE2_MASK reset_value) MODE2_ALARM Alarm n Mask */ + +#define RTC_MODE2_MASK_SEL_Pos 0 /**< \brief (RTC_MODE2_MASK) Alarm Mask Selection */ +#define RTC_MODE2_MASK_SEL_Msk (0x7u << RTC_MODE2_MASK_SEL_Pos) +#define RTC_MODE2_MASK_SEL(value) ((RTC_MODE2_MASK_SEL_Msk & ((value) << RTC_MODE2_MASK_SEL_Pos))) +#define RTC_MODE2_MASK_SEL_OFF_Val 0x0u /**< \brief (RTC_MODE2_MASK) Alarm Disabled */ +#define RTC_MODE2_MASK_SEL_SS_Val 0x1u /**< \brief (RTC_MODE2_MASK) Match seconds only */ +#define RTC_MODE2_MASK_SEL_MMSS_Val 0x2u /**< \brief (RTC_MODE2_MASK) Match seconds and minutes only */ +#define RTC_MODE2_MASK_SEL_HHMMSS_Val 0x3u /**< \brief (RTC_MODE2_MASK) Match seconds, minutes, and hours only */ +#define RTC_MODE2_MASK_SEL_DDHHMMSS_Val 0x4u /**< \brief (RTC_MODE2_MASK) Match seconds, minutes, hours, and days only */ +#define RTC_MODE2_MASK_SEL_MMDDHHMMSS_Val 0x5u /**< \brief (RTC_MODE2_MASK) Match seconds, minutes, hours, days, and months only */ +#define RTC_MODE2_MASK_SEL_YYMMDDHHMMSS_Val 0x6u /**< \brief (RTC_MODE2_MASK) Match seconds, minutes, hours, days, months, and years */ +#define RTC_MODE2_MASK_SEL_OFF (RTC_MODE2_MASK_SEL_OFF_Val << RTC_MODE2_MASK_SEL_Pos) +#define RTC_MODE2_MASK_SEL_SS (RTC_MODE2_MASK_SEL_SS_Val << RTC_MODE2_MASK_SEL_Pos) +#define RTC_MODE2_MASK_SEL_MMSS (RTC_MODE2_MASK_SEL_MMSS_Val << RTC_MODE2_MASK_SEL_Pos) +#define RTC_MODE2_MASK_SEL_HHMMSS (RTC_MODE2_MASK_SEL_HHMMSS_Val << RTC_MODE2_MASK_SEL_Pos) +#define RTC_MODE2_MASK_SEL_DDHHMMSS (RTC_MODE2_MASK_SEL_DDHHMMSS_Val << RTC_MODE2_MASK_SEL_Pos) +#define RTC_MODE2_MASK_SEL_MMDDHHMMSS (RTC_MODE2_MASK_SEL_MMDDHHMMSS_Val << RTC_MODE2_MASK_SEL_Pos) +#define RTC_MODE2_MASK_SEL_YYMMDDHHMMSS (RTC_MODE2_MASK_SEL_YYMMDDHHMMSS_Val << RTC_MODE2_MASK_SEL_Pos) +#define RTC_MODE2_MASK_MASK 0x07u /**< \brief (RTC_MODE2_MASK) MASK Register */ + +/** \brief RtcMode2Alarm hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO RTC_MODE2_ALARM_Type ALARM; /**< \brief Offset: 0x00 (R/W 32) MODE2_ALARM Alarm n Value */ + __IO RTC_MODE2_MASK_Type MASK; /**< \brief Offset: 0x04 (R/W 8) MODE2_ALARM Alarm n Mask */ + RoReg8 Reserved1[0x3]; +} RtcMode2Alarm; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief RTC_MODE0 hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* 32-bit Counter with Single 32-bit Compare */ + __IO RTC_MODE0_CTRL_Type CTRL; /**< \brief Offset: 0x00 (R/W 16) MODE0 Control */ + __IO RTC_READREQ_Type READREQ; /**< \brief Offset: 0x02 (R/W 16) Read Request */ + __IO RTC_MODE0_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x04 (R/W 16) MODE0 Event Control */ + __IO RTC_MODE0_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x06 (R/W 8) MODE0 Interrupt Enable Clear */ + __IO RTC_MODE0_INTENSET_Type INTENSET; /**< \brief Offset: 0x07 (R/W 8) MODE0 Interrupt Enable Set */ + __IO RTC_MODE0_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x08 (R/W 8) MODE0 Interrupt Flag Status and Clear */ + RoReg8 Reserved1[0x1]; + __IO RTC_STATUS_Type STATUS; /**< \brief Offset: 0x0A (R/W 8) Status */ + __IO RTC_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x0B (R/W 8) Debug Control */ + __IO RTC_FREQCORR_Type FREQCORR; /**< \brief Offset: 0x0C (R/W 8) Frequency Correction */ + RoReg8 Reserved2[0x3]; + __IO RTC_MODE0_COUNT_Type COUNT; /**< \brief Offset: 0x10 (R/W 32) MODE0 Counter Value */ + RoReg8 Reserved3[0x4]; + __IO RTC_MODE0_COMP_Type COMP[1]; /**< \brief Offset: 0x18 (R/W 32) MODE0 Compare n Value */ +} RtcMode0; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief RTC_MODE1 hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* 16-bit Counter with Two 16-bit Compares */ + __IO RTC_MODE1_CTRL_Type CTRL; /**< \brief Offset: 0x00 (R/W 16) MODE1 Control */ + __IO RTC_READREQ_Type READREQ; /**< \brief Offset: 0x02 (R/W 16) Read Request */ + __IO RTC_MODE1_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x04 (R/W 16) MODE1 Event Control */ + __IO RTC_MODE1_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x06 (R/W 8) MODE1 Interrupt Enable Clear */ + __IO RTC_MODE1_INTENSET_Type INTENSET; /**< \brief Offset: 0x07 (R/W 8) MODE1 Interrupt Enable Set */ + __IO RTC_MODE1_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x08 (R/W 8) MODE1 Interrupt Flag Status and Clear */ + RoReg8 Reserved1[0x1]; + __IO RTC_STATUS_Type STATUS; /**< \brief Offset: 0x0A (R/W 8) Status */ + __IO RTC_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x0B (R/W 8) Debug Control */ + __IO RTC_FREQCORR_Type FREQCORR; /**< \brief Offset: 0x0C (R/W 8) Frequency Correction */ + RoReg8 Reserved2[0x3]; + __IO RTC_MODE1_COUNT_Type COUNT; /**< \brief Offset: 0x10 (R/W 16) MODE1 Counter Value */ + RoReg8 Reserved3[0x2]; + __IO RTC_MODE1_PER_Type PER; /**< \brief Offset: 0x14 (R/W 16) MODE1 Counter Period */ + RoReg8 Reserved4[0x2]; + __IO RTC_MODE1_COMP_Type COMP[2]; /**< \brief Offset: 0x18 (R/W 16) MODE1 Compare n Value */ +} RtcMode1; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief RTC_MODE2 hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* Clock/Calendar with Alarm */ + __IO RTC_MODE2_CTRL_Type CTRL; /**< \brief Offset: 0x00 (R/W 16) MODE2 Control */ + __IO RTC_READREQ_Type READREQ; /**< \brief Offset: 0x02 (R/W 16) Read Request */ + __IO RTC_MODE2_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x04 (R/W 16) MODE2 Event Control */ + __IO RTC_MODE2_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x06 (R/W 8) MODE2 Interrupt Enable Clear */ + __IO RTC_MODE2_INTENSET_Type INTENSET; /**< \brief Offset: 0x07 (R/W 8) MODE2 Interrupt Enable Set */ + __IO RTC_MODE2_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x08 (R/W 8) MODE2 Interrupt Flag Status and Clear */ + RoReg8 Reserved1[0x1]; + __IO RTC_STATUS_Type STATUS; /**< \brief Offset: 0x0A (R/W 8) Status */ + __IO RTC_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x0B (R/W 8) Debug Control */ + __IO RTC_FREQCORR_Type FREQCORR; /**< \brief Offset: 0x0C (R/W 8) Frequency Correction */ + RoReg8 Reserved2[0x3]; + __IO RTC_MODE2_CLOCK_Type CLOCK; /**< \brief Offset: 0x10 (R/W 32) MODE2 Clock Value */ + RoReg8 Reserved3[0x4]; + RtcMode2Alarm Mode2Alarm[1]; /**< \brief Offset: 0x18 RtcMode2Alarm groups [ALARM_NUM] */ +} RtcMode2; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + RtcMode0 MODE0; /**< \brief Offset: 0x00 32-bit Counter with Single 32-bit Compare */ + RtcMode1 MODE1; /**< \brief Offset: 0x00 16-bit Counter with Two 16-bit Compares */ + RtcMode2 MODE2; /**< \brief Offset: 0x00 Clock/Calendar with Alarm */ +} Rtc; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_RTC_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/sercom.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/sercom.h new file mode 100644 index 0000000..80c8f46 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/sercom.h @@ -0,0 +1,1508 @@ +/** + * \file + * + * \brief Component description for SERCOM + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_SERCOM_COMPONENT_ +#define _SAMD21_SERCOM_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR SERCOM */ +/* ========================================================================== */ +/** \addtogroup SAMD21_SERCOM Serial Communication Interface */ +/*@{*/ + +#define SERCOM_U2201 +#define REV_SERCOM 0x200 + +/* -------- SERCOM_I2CM_CTRLA : (SERCOM Offset: 0x00) (R/W 32) I2CM I2CM Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Software Reset */ + uint32_t ENABLE:1; /*!< bit: 1 Enable */ + uint32_t MODE:3; /*!< bit: 2.. 4 Operating Mode */ + uint32_t :2; /*!< bit: 5.. 6 Reserved */ + uint32_t RUNSTDBY:1; /*!< bit: 7 Run in Standby */ + uint32_t :8; /*!< bit: 8..15 Reserved */ + uint32_t PINOUT:1; /*!< bit: 16 Pin Usage */ + uint32_t :3; /*!< bit: 17..19 Reserved */ + uint32_t SDAHOLD:2; /*!< bit: 20..21 SDA Hold Time */ + uint32_t MEXTTOEN:1; /*!< bit: 22 Master SCL Low Extend Timeout */ + uint32_t SEXTTOEN:1; /*!< bit: 23 Slave SCL Low Extend Timeout */ + uint32_t SPEED:2; /*!< bit: 24..25 Transfer Speed */ + uint32_t :1; /*!< bit: 26 Reserved */ + uint32_t SCLSM:1; /*!< bit: 27 SCL Clock Stretch Mode */ + uint32_t INACTOUT:2; /*!< bit: 28..29 Inactive Time-Out */ + uint32_t LOWTOUTEN:1; /*!< bit: 30 SCL Low Timeout Enable */ + uint32_t :1; /*!< bit: 31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_CTRLA_OFFSET 0x00 /**< \brief (SERCOM_I2CM_CTRLA offset) I2CM Control A */ +#define SERCOM_I2CM_CTRLA_RESETVALUE 0x00000000 /**< \brief (SERCOM_I2CM_CTRLA reset_value) I2CM Control A */ + +#define SERCOM_I2CM_CTRLA_SWRST_Pos 0 /**< \brief (SERCOM_I2CM_CTRLA) Software Reset */ +#define SERCOM_I2CM_CTRLA_SWRST (0x1u << SERCOM_I2CM_CTRLA_SWRST_Pos) +#define SERCOM_I2CM_CTRLA_ENABLE_Pos 1 /**< \brief (SERCOM_I2CM_CTRLA) Enable */ +#define SERCOM_I2CM_CTRLA_ENABLE (0x1u << SERCOM_I2CM_CTRLA_ENABLE_Pos) +#define SERCOM_I2CM_CTRLA_MODE_Pos 2 /**< \brief (SERCOM_I2CM_CTRLA) Operating Mode */ +#define SERCOM_I2CM_CTRLA_MODE_Msk (0x7u << SERCOM_I2CM_CTRLA_MODE_Pos) +#define SERCOM_I2CM_CTRLA_MODE(value) ((SERCOM_I2CM_CTRLA_MODE_Msk & ((value) << SERCOM_I2CM_CTRLA_MODE_Pos))) +#define SERCOM_I2CM_CTRLA_MODE_USART_EXT_CLK_Val 0x0u /**< \brief (SERCOM_I2CM_CTRLA) USART mode with external clock */ +#define SERCOM_I2CM_CTRLA_MODE_USART_INT_CLK_Val 0x1u /**< \brief (SERCOM_I2CM_CTRLA) USART mode with internal clock */ +#define SERCOM_I2CM_CTRLA_MODE_SPI_SLAVE_Val 0x2u /**< \brief (SERCOM_I2CM_CTRLA) SPI mode with external clock */ +#define SERCOM_I2CM_CTRLA_MODE_SPI_MASTER_Val 0x3u /**< \brief (SERCOM_I2CM_CTRLA) SPI mode with internal clock */ +#define SERCOM_I2CM_CTRLA_MODE_I2C_SLAVE_Val 0x4u /**< \brief (SERCOM_I2CM_CTRLA) I2C mode with external clock */ +#define SERCOM_I2CM_CTRLA_MODE_I2C_MASTER_Val 0x5u /**< \brief (SERCOM_I2CM_CTRLA) I2C mode with internal clock */ +#define SERCOM_I2CM_CTRLA_MODE_USART_EXT_CLK (SERCOM_I2CM_CTRLA_MODE_USART_EXT_CLK_Val << SERCOM_I2CM_CTRLA_MODE_Pos) +#define SERCOM_I2CM_CTRLA_MODE_USART_INT_CLK (SERCOM_I2CM_CTRLA_MODE_USART_INT_CLK_Val << SERCOM_I2CM_CTRLA_MODE_Pos) +#define SERCOM_I2CM_CTRLA_MODE_SPI_SLAVE (SERCOM_I2CM_CTRLA_MODE_SPI_SLAVE_Val << SERCOM_I2CM_CTRLA_MODE_Pos) +#define SERCOM_I2CM_CTRLA_MODE_SPI_MASTER (SERCOM_I2CM_CTRLA_MODE_SPI_MASTER_Val << SERCOM_I2CM_CTRLA_MODE_Pos) +#define SERCOM_I2CM_CTRLA_MODE_I2C_SLAVE (SERCOM_I2CM_CTRLA_MODE_I2C_SLAVE_Val << SERCOM_I2CM_CTRLA_MODE_Pos) +#define SERCOM_I2CM_CTRLA_MODE_I2C_MASTER (SERCOM_I2CM_CTRLA_MODE_I2C_MASTER_Val << SERCOM_I2CM_CTRLA_MODE_Pos) +#define SERCOM_I2CM_CTRLA_RUNSTDBY_Pos 7 /**< \brief (SERCOM_I2CM_CTRLA) Run in Standby */ +#define SERCOM_I2CM_CTRLA_RUNSTDBY (0x1u << SERCOM_I2CM_CTRLA_RUNSTDBY_Pos) +#define SERCOM_I2CM_CTRLA_PINOUT_Pos 16 /**< \brief (SERCOM_I2CM_CTRLA) Pin Usage */ +#define SERCOM_I2CM_CTRLA_PINOUT (0x1u << SERCOM_I2CM_CTRLA_PINOUT_Pos) +#define SERCOM_I2CM_CTRLA_SDAHOLD_Pos 20 /**< \brief (SERCOM_I2CM_CTRLA) SDA Hold Time */ +#define SERCOM_I2CM_CTRLA_SDAHOLD_Msk (0x3u << SERCOM_I2CM_CTRLA_SDAHOLD_Pos) +#define SERCOM_I2CM_CTRLA_SDAHOLD(value) ((SERCOM_I2CM_CTRLA_SDAHOLD_Msk & ((value) << SERCOM_I2CM_CTRLA_SDAHOLD_Pos))) +#define SERCOM_I2CM_CTRLA_MEXTTOEN_Pos 22 /**< \brief (SERCOM_I2CM_CTRLA) Master SCL Low Extend Timeout */ +#define SERCOM_I2CM_CTRLA_MEXTTOEN (0x1u << SERCOM_I2CM_CTRLA_MEXTTOEN_Pos) +#define SERCOM_I2CM_CTRLA_SEXTTOEN_Pos 23 /**< \brief (SERCOM_I2CM_CTRLA) Slave SCL Low Extend Timeout */ +#define SERCOM_I2CM_CTRLA_SEXTTOEN (0x1u << SERCOM_I2CM_CTRLA_SEXTTOEN_Pos) +#define SERCOM_I2CM_CTRLA_SPEED_Pos 24 /**< \brief (SERCOM_I2CM_CTRLA) Transfer Speed */ +#define SERCOM_I2CM_CTRLA_SPEED_Msk (0x3u << SERCOM_I2CM_CTRLA_SPEED_Pos) +#define SERCOM_I2CM_CTRLA_SPEED(value) ((SERCOM_I2CM_CTRLA_SPEED_Msk & ((value) << SERCOM_I2CM_CTRLA_SPEED_Pos))) +#define SERCOM_I2CM_CTRLA_SCLSM_Pos 27 /**< \brief (SERCOM_I2CM_CTRLA) SCL Clock Stretch Mode */ +#define SERCOM_I2CM_CTRLA_SCLSM (0x1u << SERCOM_I2CM_CTRLA_SCLSM_Pos) +#define SERCOM_I2CM_CTRLA_INACTOUT_Pos 28 /**< \brief (SERCOM_I2CM_CTRLA) Inactive Time-Out */ +#define SERCOM_I2CM_CTRLA_INACTOUT_Msk (0x3u << SERCOM_I2CM_CTRLA_INACTOUT_Pos) +#define SERCOM_I2CM_CTRLA_INACTOUT(value) ((SERCOM_I2CM_CTRLA_INACTOUT_Msk & ((value) << SERCOM_I2CM_CTRLA_INACTOUT_Pos))) +#define SERCOM_I2CM_CTRLA_LOWTOUTEN_Pos 30 /**< \brief (SERCOM_I2CM_CTRLA) SCL Low Timeout Enable */ +#define SERCOM_I2CM_CTRLA_LOWTOUTEN (0x1u << SERCOM_I2CM_CTRLA_LOWTOUTEN_Pos) +#define SERCOM_I2CM_CTRLA_MASK 0x7BF1009Fu /**< \brief (SERCOM_I2CM_CTRLA) MASK Register */ + +/* -------- SERCOM_I2CS_CTRLA : (SERCOM Offset: 0x00) (R/W 32) I2CS I2CS Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Software Reset */ + uint32_t ENABLE:1; /*!< bit: 1 Enable */ + uint32_t MODE:3; /*!< bit: 2.. 4 Operating Mode */ + uint32_t :2; /*!< bit: 5.. 6 Reserved */ + uint32_t RUNSTDBY:1; /*!< bit: 7 Run during Standby */ + uint32_t :8; /*!< bit: 8..15 Reserved */ + uint32_t PINOUT:1; /*!< bit: 16 Pin Usage */ + uint32_t :3; /*!< bit: 17..19 Reserved */ + uint32_t SDAHOLD:2; /*!< bit: 20..21 SDA Hold Time */ + uint32_t :1; /*!< bit: 22 Reserved */ + uint32_t SEXTTOEN:1; /*!< bit: 23 Slave SCL Low Extend Timeout */ + uint32_t SPEED:2; /*!< bit: 24..25 Transfer Speed */ + uint32_t :1; /*!< bit: 26 Reserved */ + uint32_t SCLSM:1; /*!< bit: 27 SCL Clock Stretch Mode */ + uint32_t :2; /*!< bit: 28..29 Reserved */ + uint32_t LOWTOUTEN:1; /*!< bit: 30 SCL Low Timeout Enable */ + uint32_t :1; /*!< bit: 31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_I2CS_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CS_CTRLA_OFFSET 0x00 /**< \brief (SERCOM_I2CS_CTRLA offset) I2CS Control A */ +#define SERCOM_I2CS_CTRLA_RESETVALUE 0x00000000 /**< \brief (SERCOM_I2CS_CTRLA reset_value) I2CS Control A */ + +#define SERCOM_I2CS_CTRLA_SWRST_Pos 0 /**< \brief (SERCOM_I2CS_CTRLA) Software Reset */ +#define SERCOM_I2CS_CTRLA_SWRST (0x1u << SERCOM_I2CS_CTRLA_SWRST_Pos) +#define SERCOM_I2CS_CTRLA_ENABLE_Pos 1 /**< \brief (SERCOM_I2CS_CTRLA) Enable */ +#define SERCOM_I2CS_CTRLA_ENABLE (0x1u << SERCOM_I2CS_CTRLA_ENABLE_Pos) +#define SERCOM_I2CS_CTRLA_MODE_Pos 2 /**< \brief (SERCOM_I2CS_CTRLA) Operating Mode */ +#define SERCOM_I2CS_CTRLA_MODE_Msk (0x7u << SERCOM_I2CS_CTRLA_MODE_Pos) +#define SERCOM_I2CS_CTRLA_MODE(value) ((SERCOM_I2CS_CTRLA_MODE_Msk & ((value) << SERCOM_I2CS_CTRLA_MODE_Pos))) +#define SERCOM_I2CS_CTRLA_MODE_USART_EXT_CLK_Val 0x0u /**< \brief (SERCOM_I2CS_CTRLA) USART mode with external clock */ +#define SERCOM_I2CS_CTRLA_MODE_USART_INT_CLK_Val 0x1u /**< \brief (SERCOM_I2CS_CTRLA) USART mode with internal clock */ +#define SERCOM_I2CS_CTRLA_MODE_SPI_SLAVE_Val 0x2u /**< \brief (SERCOM_I2CS_CTRLA) SPI mode with external clock */ +#define SERCOM_I2CS_CTRLA_MODE_SPI_MASTER_Val 0x3u /**< \brief (SERCOM_I2CS_CTRLA) SPI mode with internal clock */ +#define SERCOM_I2CS_CTRLA_MODE_I2C_SLAVE_Val 0x4u /**< \brief (SERCOM_I2CS_CTRLA) I2C mode with external clock */ +#define SERCOM_I2CS_CTRLA_MODE_I2C_MASTER_Val 0x5u /**< \brief (SERCOM_I2CS_CTRLA) I2C mode with internal clock */ +#define SERCOM_I2CS_CTRLA_MODE_USART_EXT_CLK (SERCOM_I2CS_CTRLA_MODE_USART_EXT_CLK_Val << SERCOM_I2CS_CTRLA_MODE_Pos) +#define SERCOM_I2CS_CTRLA_MODE_USART_INT_CLK (SERCOM_I2CS_CTRLA_MODE_USART_INT_CLK_Val << SERCOM_I2CS_CTRLA_MODE_Pos) +#define SERCOM_I2CS_CTRLA_MODE_SPI_SLAVE (SERCOM_I2CS_CTRLA_MODE_SPI_SLAVE_Val << SERCOM_I2CS_CTRLA_MODE_Pos) +#define SERCOM_I2CS_CTRLA_MODE_SPI_MASTER (SERCOM_I2CS_CTRLA_MODE_SPI_MASTER_Val << SERCOM_I2CS_CTRLA_MODE_Pos) +#define SERCOM_I2CS_CTRLA_MODE_I2C_SLAVE (SERCOM_I2CS_CTRLA_MODE_I2C_SLAVE_Val << SERCOM_I2CS_CTRLA_MODE_Pos) +#define SERCOM_I2CS_CTRLA_MODE_I2C_MASTER (SERCOM_I2CS_CTRLA_MODE_I2C_MASTER_Val << SERCOM_I2CS_CTRLA_MODE_Pos) +#define SERCOM_I2CS_CTRLA_RUNSTDBY_Pos 7 /**< \brief (SERCOM_I2CS_CTRLA) Run during Standby */ +#define SERCOM_I2CS_CTRLA_RUNSTDBY (0x1u << SERCOM_I2CS_CTRLA_RUNSTDBY_Pos) +#define SERCOM_I2CS_CTRLA_PINOUT_Pos 16 /**< \brief (SERCOM_I2CS_CTRLA) Pin Usage */ +#define SERCOM_I2CS_CTRLA_PINOUT (0x1u << SERCOM_I2CS_CTRLA_PINOUT_Pos) +#define SERCOM_I2CS_CTRLA_SDAHOLD_Pos 20 /**< \brief (SERCOM_I2CS_CTRLA) SDA Hold Time */ +#define SERCOM_I2CS_CTRLA_SDAHOLD_Msk (0x3u << SERCOM_I2CS_CTRLA_SDAHOLD_Pos) +#define SERCOM_I2CS_CTRLA_SDAHOLD(value) ((SERCOM_I2CS_CTRLA_SDAHOLD_Msk & ((value) << SERCOM_I2CS_CTRLA_SDAHOLD_Pos))) +#define SERCOM_I2CS_CTRLA_SEXTTOEN_Pos 23 /**< \brief (SERCOM_I2CS_CTRLA) Slave SCL Low Extend Timeout */ +#define SERCOM_I2CS_CTRLA_SEXTTOEN (0x1u << SERCOM_I2CS_CTRLA_SEXTTOEN_Pos) +#define SERCOM_I2CS_CTRLA_SPEED_Pos 24 /**< \brief (SERCOM_I2CS_CTRLA) Transfer Speed */ +#define SERCOM_I2CS_CTRLA_SPEED_Msk (0x3u << SERCOM_I2CS_CTRLA_SPEED_Pos) +#define SERCOM_I2CS_CTRLA_SPEED(value) ((SERCOM_I2CS_CTRLA_SPEED_Msk & ((value) << SERCOM_I2CS_CTRLA_SPEED_Pos))) +#define SERCOM_I2CS_CTRLA_SCLSM_Pos 27 /**< \brief (SERCOM_I2CS_CTRLA) SCL Clock Stretch Mode */ +#define SERCOM_I2CS_CTRLA_SCLSM (0x1u << SERCOM_I2CS_CTRLA_SCLSM_Pos) +#define SERCOM_I2CS_CTRLA_LOWTOUTEN_Pos 30 /**< \brief (SERCOM_I2CS_CTRLA) SCL Low Timeout Enable */ +#define SERCOM_I2CS_CTRLA_LOWTOUTEN (0x1u << SERCOM_I2CS_CTRLA_LOWTOUTEN_Pos) +#define SERCOM_I2CS_CTRLA_MASK 0x4BB1009Fu /**< \brief (SERCOM_I2CS_CTRLA) MASK Register */ + +/* -------- SERCOM_SPI_CTRLA : (SERCOM Offset: 0x00) (R/W 32) SPI SPI Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Software Reset */ + uint32_t ENABLE:1; /*!< bit: 1 Enable */ + uint32_t MODE:3; /*!< bit: 2.. 4 Operating Mode */ + uint32_t :2; /*!< bit: 5.. 6 Reserved */ + uint32_t RUNSTDBY:1; /*!< bit: 7 Run during Standby */ + uint32_t IBON:1; /*!< bit: 8 Immediate Buffer Overflow Notification */ + uint32_t :7; /*!< bit: 9..15 Reserved */ + uint32_t DOPO:2; /*!< bit: 16..17 Data Out Pinout */ + uint32_t :2; /*!< bit: 18..19 Reserved */ + uint32_t DIPO:2; /*!< bit: 20..21 Data In Pinout */ + uint32_t :2; /*!< bit: 22..23 Reserved */ + uint32_t FORM:4; /*!< bit: 24..27 Frame Format */ + uint32_t CPHA:1; /*!< bit: 28 Clock Phase */ + uint32_t CPOL:1; /*!< bit: 29 Clock Polarity */ + uint32_t DORD:1; /*!< bit: 30 Data Order */ + uint32_t :1; /*!< bit: 31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_SPI_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_CTRLA_OFFSET 0x00 /**< \brief (SERCOM_SPI_CTRLA offset) SPI Control A */ +#define SERCOM_SPI_CTRLA_RESETVALUE 0x00000000 /**< \brief (SERCOM_SPI_CTRLA reset_value) SPI Control A */ + +#define SERCOM_SPI_CTRLA_SWRST_Pos 0 /**< \brief (SERCOM_SPI_CTRLA) Software Reset */ +#define SERCOM_SPI_CTRLA_SWRST (0x1u << SERCOM_SPI_CTRLA_SWRST_Pos) +#define SERCOM_SPI_CTRLA_ENABLE_Pos 1 /**< \brief (SERCOM_SPI_CTRLA) Enable */ +#define SERCOM_SPI_CTRLA_ENABLE (0x1u << SERCOM_SPI_CTRLA_ENABLE_Pos) +#define SERCOM_SPI_CTRLA_MODE_Pos 2 /**< \brief (SERCOM_SPI_CTRLA) Operating Mode */ +#define SERCOM_SPI_CTRLA_MODE_Msk (0x7u << SERCOM_SPI_CTRLA_MODE_Pos) +#define SERCOM_SPI_CTRLA_MODE(value) ((SERCOM_SPI_CTRLA_MODE_Msk & ((value) << SERCOM_SPI_CTRLA_MODE_Pos))) +#define SERCOM_SPI_CTRLA_MODE_USART_EXT_CLK_Val 0x0u /**< \brief (SERCOM_SPI_CTRLA) USART mode with external clock */ +#define SERCOM_SPI_CTRLA_MODE_USART_INT_CLK_Val 0x1u /**< \brief (SERCOM_SPI_CTRLA) USART mode with internal clock */ +#define SERCOM_SPI_CTRLA_MODE_SPI_SLAVE_Val 0x2u /**< \brief (SERCOM_SPI_CTRLA) SPI mode with external clock */ +#define SERCOM_SPI_CTRLA_MODE_SPI_MASTER_Val 0x3u /**< \brief (SERCOM_SPI_CTRLA) SPI mode with internal clock */ +#define SERCOM_SPI_CTRLA_MODE_I2C_SLAVE_Val 0x4u /**< \brief (SERCOM_SPI_CTRLA) I2C mode with external clock */ +#define SERCOM_SPI_CTRLA_MODE_I2C_MASTER_Val 0x5u /**< \brief (SERCOM_SPI_CTRLA) I2C mode with internal clock */ +#define SERCOM_SPI_CTRLA_MODE_USART_EXT_CLK (SERCOM_SPI_CTRLA_MODE_USART_EXT_CLK_Val << SERCOM_SPI_CTRLA_MODE_Pos) +#define SERCOM_SPI_CTRLA_MODE_USART_INT_CLK (SERCOM_SPI_CTRLA_MODE_USART_INT_CLK_Val << SERCOM_SPI_CTRLA_MODE_Pos) +#define SERCOM_SPI_CTRLA_MODE_SPI_SLAVE (SERCOM_SPI_CTRLA_MODE_SPI_SLAVE_Val << SERCOM_SPI_CTRLA_MODE_Pos) +#define SERCOM_SPI_CTRLA_MODE_SPI_MASTER (SERCOM_SPI_CTRLA_MODE_SPI_MASTER_Val << SERCOM_SPI_CTRLA_MODE_Pos) +#define SERCOM_SPI_CTRLA_MODE_I2C_SLAVE (SERCOM_SPI_CTRLA_MODE_I2C_SLAVE_Val << SERCOM_SPI_CTRLA_MODE_Pos) +#define SERCOM_SPI_CTRLA_MODE_I2C_MASTER (SERCOM_SPI_CTRLA_MODE_I2C_MASTER_Val << SERCOM_SPI_CTRLA_MODE_Pos) +#define SERCOM_SPI_CTRLA_RUNSTDBY_Pos 7 /**< \brief (SERCOM_SPI_CTRLA) Run during Standby */ +#define SERCOM_SPI_CTRLA_RUNSTDBY (0x1u << SERCOM_SPI_CTRLA_RUNSTDBY_Pos) +#define SERCOM_SPI_CTRLA_IBON_Pos 8 /**< \brief (SERCOM_SPI_CTRLA) Immediate Buffer Overflow Notification */ +#define SERCOM_SPI_CTRLA_IBON (0x1u << SERCOM_SPI_CTRLA_IBON_Pos) +#define SERCOM_SPI_CTRLA_DOPO_Pos 16 /**< \brief (SERCOM_SPI_CTRLA) Data Out Pinout */ +#define SERCOM_SPI_CTRLA_DOPO_Msk (0x3u << SERCOM_SPI_CTRLA_DOPO_Pos) +#define SERCOM_SPI_CTRLA_DOPO(value) ((SERCOM_SPI_CTRLA_DOPO_Msk & ((value) << SERCOM_SPI_CTRLA_DOPO_Pos))) +#define SERCOM_SPI_CTRLA_DIPO_Pos 20 /**< \brief (SERCOM_SPI_CTRLA) Data In Pinout */ +#define SERCOM_SPI_CTRLA_DIPO_Msk (0x3u << SERCOM_SPI_CTRLA_DIPO_Pos) +#define SERCOM_SPI_CTRLA_DIPO(value) ((SERCOM_SPI_CTRLA_DIPO_Msk & ((value) << SERCOM_SPI_CTRLA_DIPO_Pos))) +#define SERCOM_SPI_CTRLA_FORM_Pos 24 /**< \brief (SERCOM_SPI_CTRLA) Frame Format */ +#define SERCOM_SPI_CTRLA_FORM_Msk (0xFu << SERCOM_SPI_CTRLA_FORM_Pos) +#define SERCOM_SPI_CTRLA_FORM(value) ((SERCOM_SPI_CTRLA_FORM_Msk & ((value) << SERCOM_SPI_CTRLA_FORM_Pos))) +#define SERCOM_SPI_CTRLA_CPHA_Pos 28 /**< \brief (SERCOM_SPI_CTRLA) Clock Phase */ +#define SERCOM_SPI_CTRLA_CPHA (0x1u << SERCOM_SPI_CTRLA_CPHA_Pos) +#define SERCOM_SPI_CTRLA_CPOL_Pos 29 /**< \brief (SERCOM_SPI_CTRLA) Clock Polarity */ +#define SERCOM_SPI_CTRLA_CPOL (0x1u << SERCOM_SPI_CTRLA_CPOL_Pos) +#define SERCOM_SPI_CTRLA_DORD_Pos 30 /**< \brief (SERCOM_SPI_CTRLA) Data Order */ +#define SERCOM_SPI_CTRLA_DORD (0x1u << SERCOM_SPI_CTRLA_DORD_Pos) +#define SERCOM_SPI_CTRLA_MASK 0x7F33019Fu /**< \brief (SERCOM_SPI_CTRLA) MASK Register */ + +/* -------- SERCOM_USART_CTRLA : (SERCOM Offset: 0x00) (R/W 32) USART USART Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Software Reset */ + uint32_t ENABLE:1; /*!< bit: 1 Enable */ + uint32_t MODE:3; /*!< bit: 2.. 4 Operating Mode */ + uint32_t :2; /*!< bit: 5.. 6 Reserved */ + uint32_t RUNSTDBY:1; /*!< bit: 7 Run during Standby */ + uint32_t IBON:1; /*!< bit: 8 Immediate Buffer Overflow Notification */ + uint32_t :4; /*!< bit: 9..12 Reserved */ + uint32_t SAMPR:3; /*!< bit: 13..15 Sample */ + uint32_t TXPO:2; /*!< bit: 16..17 Transmit Data Pinout */ + uint32_t :2; /*!< bit: 18..19 Reserved */ + uint32_t RXPO:2; /*!< bit: 20..21 Receive Data Pinout */ + uint32_t SAMPA:2; /*!< bit: 22..23 Sample Adjustment */ + uint32_t FORM:4; /*!< bit: 24..27 Frame Format */ + uint32_t CMODE:1; /*!< bit: 28 Communication Mode */ + uint32_t CPOL:1; /*!< bit: 29 Clock Polarity */ + uint32_t DORD:1; /*!< bit: 30 Data Order */ + uint32_t :1; /*!< bit: 31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_USART_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_CTRLA_OFFSET 0x00 /**< \brief (SERCOM_USART_CTRLA offset) USART Control A */ +#define SERCOM_USART_CTRLA_RESETVALUE 0x00000000 /**< \brief (SERCOM_USART_CTRLA reset_value) USART Control A */ + +#define SERCOM_USART_CTRLA_SWRST_Pos 0 /**< \brief (SERCOM_USART_CTRLA) Software Reset */ +#define SERCOM_USART_CTRLA_SWRST (0x1u << SERCOM_USART_CTRLA_SWRST_Pos) +#define SERCOM_USART_CTRLA_ENABLE_Pos 1 /**< \brief (SERCOM_USART_CTRLA) Enable */ +#define SERCOM_USART_CTRLA_ENABLE (0x1u << SERCOM_USART_CTRLA_ENABLE_Pos) +#define SERCOM_USART_CTRLA_MODE_Pos 2 /**< \brief (SERCOM_USART_CTRLA) Operating Mode */ +#define SERCOM_USART_CTRLA_MODE_Msk (0x7u << SERCOM_USART_CTRLA_MODE_Pos) +#define SERCOM_USART_CTRLA_MODE(value) ((SERCOM_USART_CTRLA_MODE_Msk & ((value) << SERCOM_USART_CTRLA_MODE_Pos))) +#define SERCOM_USART_CTRLA_MODE_USART_EXT_CLK_Val 0x0u /**< \brief (SERCOM_USART_CTRLA) USART mode with external clock */ +#define SERCOM_USART_CTRLA_MODE_USART_INT_CLK_Val 0x1u /**< \brief (SERCOM_USART_CTRLA) USART mode with internal clock */ +#define SERCOM_USART_CTRLA_MODE_SPI_SLAVE_Val 0x2u /**< \brief (SERCOM_USART_CTRLA) SPI mode with external clock */ +#define SERCOM_USART_CTRLA_MODE_SPI_MASTER_Val 0x3u /**< \brief (SERCOM_USART_CTRLA) SPI mode with internal clock */ +#define SERCOM_USART_CTRLA_MODE_I2C_SLAVE_Val 0x4u /**< \brief (SERCOM_USART_CTRLA) I2C mode with external clock */ +#define SERCOM_USART_CTRLA_MODE_I2C_MASTER_Val 0x5u /**< \brief (SERCOM_USART_CTRLA) I2C mode with internal clock */ +#define SERCOM_USART_CTRLA_MODE_USART_EXT_CLK (SERCOM_USART_CTRLA_MODE_USART_EXT_CLK_Val << SERCOM_USART_CTRLA_MODE_Pos) +#define SERCOM_USART_CTRLA_MODE_USART_INT_CLK (SERCOM_USART_CTRLA_MODE_USART_INT_CLK_Val << SERCOM_USART_CTRLA_MODE_Pos) +#define SERCOM_USART_CTRLA_MODE_SPI_SLAVE (SERCOM_USART_CTRLA_MODE_SPI_SLAVE_Val << SERCOM_USART_CTRLA_MODE_Pos) +#define SERCOM_USART_CTRLA_MODE_SPI_MASTER (SERCOM_USART_CTRLA_MODE_SPI_MASTER_Val << SERCOM_USART_CTRLA_MODE_Pos) +#define SERCOM_USART_CTRLA_MODE_I2C_SLAVE (SERCOM_USART_CTRLA_MODE_I2C_SLAVE_Val << SERCOM_USART_CTRLA_MODE_Pos) +#define SERCOM_USART_CTRLA_MODE_I2C_MASTER (SERCOM_USART_CTRLA_MODE_I2C_MASTER_Val << SERCOM_USART_CTRLA_MODE_Pos) +#define SERCOM_USART_CTRLA_RUNSTDBY_Pos 7 /**< \brief (SERCOM_USART_CTRLA) Run during Standby */ +#define SERCOM_USART_CTRLA_RUNSTDBY (0x1u << SERCOM_USART_CTRLA_RUNSTDBY_Pos) +#define SERCOM_USART_CTRLA_IBON_Pos 8 /**< \brief (SERCOM_USART_CTRLA) Immediate Buffer Overflow Notification */ +#define SERCOM_USART_CTRLA_IBON (0x1u << SERCOM_USART_CTRLA_IBON_Pos) +#define SERCOM_USART_CTRLA_SAMPR_Pos 13 /**< \brief (SERCOM_USART_CTRLA) Sample */ +#define SERCOM_USART_CTRLA_SAMPR_Msk (0x7u << SERCOM_USART_CTRLA_SAMPR_Pos) +#define SERCOM_USART_CTRLA_SAMPR(value) ((SERCOM_USART_CTRLA_SAMPR_Msk & ((value) << SERCOM_USART_CTRLA_SAMPR_Pos))) +#define SERCOM_USART_CTRLA_TXPO_Pos 16 /**< \brief (SERCOM_USART_CTRLA) Transmit Data Pinout */ +#define SERCOM_USART_CTRLA_TXPO_Msk (0x3u << SERCOM_USART_CTRLA_TXPO_Pos) +#define SERCOM_USART_CTRLA_TXPO(value) ((SERCOM_USART_CTRLA_TXPO_Msk & ((value) << SERCOM_USART_CTRLA_TXPO_Pos))) +#define SERCOM_USART_CTRLA_RXPO_Pos 20 /**< \brief (SERCOM_USART_CTRLA) Receive Data Pinout */ +#define SERCOM_USART_CTRLA_RXPO_Msk (0x3u << SERCOM_USART_CTRLA_RXPO_Pos) +#define SERCOM_USART_CTRLA_RXPO(value) ((SERCOM_USART_CTRLA_RXPO_Msk & ((value) << SERCOM_USART_CTRLA_RXPO_Pos))) +#define SERCOM_USART_CTRLA_SAMPA_Pos 22 /**< \brief (SERCOM_USART_CTRLA) Sample Adjustment */ +#define SERCOM_USART_CTRLA_SAMPA_Msk (0x3u << SERCOM_USART_CTRLA_SAMPA_Pos) +#define SERCOM_USART_CTRLA_SAMPA(value) ((SERCOM_USART_CTRLA_SAMPA_Msk & ((value) << SERCOM_USART_CTRLA_SAMPA_Pos))) +#define SERCOM_USART_CTRLA_FORM_Pos 24 /**< \brief (SERCOM_USART_CTRLA) Frame Format */ +#define SERCOM_USART_CTRLA_FORM_Msk (0xFu << SERCOM_USART_CTRLA_FORM_Pos) +#define SERCOM_USART_CTRLA_FORM(value) ((SERCOM_USART_CTRLA_FORM_Msk & ((value) << SERCOM_USART_CTRLA_FORM_Pos))) +#define SERCOM_USART_CTRLA_CMODE_Pos 28 /**< \brief (SERCOM_USART_CTRLA) Communication Mode */ +#define SERCOM_USART_CTRLA_CMODE (0x1u << SERCOM_USART_CTRLA_CMODE_Pos) +#define SERCOM_USART_CTRLA_CPOL_Pos 29 /**< \brief (SERCOM_USART_CTRLA) Clock Polarity */ +#define SERCOM_USART_CTRLA_CPOL (0x1u << SERCOM_USART_CTRLA_CPOL_Pos) +#define SERCOM_USART_CTRLA_DORD_Pos 30 /**< \brief (SERCOM_USART_CTRLA) Data Order */ +#define SERCOM_USART_CTRLA_DORD (0x1u << SERCOM_USART_CTRLA_DORD_Pos) +#define SERCOM_USART_CTRLA_MASK 0x7FF3E19Fu /**< \brief (SERCOM_USART_CTRLA) MASK Register */ + +/* -------- SERCOM_I2CM_CTRLB : (SERCOM Offset: 0x04) (R/W 32) I2CM I2CM Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :8; /*!< bit: 0.. 7 Reserved */ + uint32_t SMEN:1; /*!< bit: 8 Smart Mode Enable */ + uint32_t QCEN:1; /*!< bit: 9 Quick Command Enable */ + uint32_t :6; /*!< bit: 10..15 Reserved */ + uint32_t CMD:2; /*!< bit: 16..17 Command */ + uint32_t ACKACT:1; /*!< bit: 18 Acknowledge Action */ + uint32_t :13; /*!< bit: 19..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_CTRLB_OFFSET 0x04 /**< \brief (SERCOM_I2CM_CTRLB offset) I2CM Control B */ +#define SERCOM_I2CM_CTRLB_RESETVALUE 0x00000000 /**< \brief (SERCOM_I2CM_CTRLB reset_value) I2CM Control B */ + +#define SERCOM_I2CM_CTRLB_SMEN_Pos 8 /**< \brief (SERCOM_I2CM_CTRLB) Smart Mode Enable */ +#define SERCOM_I2CM_CTRLB_SMEN (0x1u << SERCOM_I2CM_CTRLB_SMEN_Pos) +#define SERCOM_I2CM_CTRLB_QCEN_Pos 9 /**< \brief (SERCOM_I2CM_CTRLB) Quick Command Enable */ +#define SERCOM_I2CM_CTRLB_QCEN (0x1u << SERCOM_I2CM_CTRLB_QCEN_Pos) +#define SERCOM_I2CM_CTRLB_CMD_Pos 16 /**< \brief (SERCOM_I2CM_CTRLB) Command */ +#define SERCOM_I2CM_CTRLB_CMD_Msk (0x3u << SERCOM_I2CM_CTRLB_CMD_Pos) +#define SERCOM_I2CM_CTRLB_CMD(value) ((SERCOM_I2CM_CTRLB_CMD_Msk & ((value) << SERCOM_I2CM_CTRLB_CMD_Pos))) +#define SERCOM_I2CM_CTRLB_ACKACT_Pos 18 /**< \brief (SERCOM_I2CM_CTRLB) Acknowledge Action */ +#define SERCOM_I2CM_CTRLB_ACKACT (0x1u << SERCOM_I2CM_CTRLB_ACKACT_Pos) +#define SERCOM_I2CM_CTRLB_MASK 0x00070300u /**< \brief (SERCOM_I2CM_CTRLB) MASK Register */ + +/* -------- SERCOM_I2CS_CTRLB : (SERCOM Offset: 0x04) (R/W 32) I2CS I2CS Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :8; /*!< bit: 0.. 7 Reserved */ + uint32_t SMEN:1; /*!< bit: 8 Smart Mode Enable */ + uint32_t GCMD:1; /*!< bit: 9 PMBus Group Command */ + uint32_t AACKEN:1; /*!< bit: 10 Automatic Address Acknowledge */ + uint32_t :3; /*!< bit: 11..13 Reserved */ + uint32_t AMODE:2; /*!< bit: 14..15 Address Mode */ + uint32_t CMD:2; /*!< bit: 16..17 Command */ + uint32_t ACKACT:1; /*!< bit: 18 Acknowledge Action */ + uint32_t :13; /*!< bit: 19..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_I2CS_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CS_CTRLB_OFFSET 0x04 /**< \brief (SERCOM_I2CS_CTRLB offset) I2CS Control B */ +#define SERCOM_I2CS_CTRLB_RESETVALUE 0x00000000 /**< \brief (SERCOM_I2CS_CTRLB reset_value) I2CS Control B */ + +#define SERCOM_I2CS_CTRLB_SMEN_Pos 8 /**< \brief (SERCOM_I2CS_CTRLB) Smart Mode Enable */ +#define SERCOM_I2CS_CTRLB_SMEN (0x1u << SERCOM_I2CS_CTRLB_SMEN_Pos) +#define SERCOM_I2CS_CTRLB_GCMD_Pos 9 /**< \brief (SERCOM_I2CS_CTRLB) PMBus Group Command */ +#define SERCOM_I2CS_CTRLB_GCMD (0x1u << SERCOM_I2CS_CTRLB_GCMD_Pos) +#define SERCOM_I2CS_CTRLB_AACKEN_Pos 10 /**< \brief (SERCOM_I2CS_CTRLB) Automatic Address Acknowledge */ +#define SERCOM_I2CS_CTRLB_AACKEN (0x1u << SERCOM_I2CS_CTRLB_AACKEN_Pos) +#define SERCOM_I2CS_CTRLB_AMODE_Pos 14 /**< \brief (SERCOM_I2CS_CTRLB) Address Mode */ +#define SERCOM_I2CS_CTRLB_AMODE_Msk (0x3u << SERCOM_I2CS_CTRLB_AMODE_Pos) +#define SERCOM_I2CS_CTRLB_AMODE(value) ((SERCOM_I2CS_CTRLB_AMODE_Msk & ((value) << SERCOM_I2CS_CTRLB_AMODE_Pos))) +#define SERCOM_I2CS_CTRLB_CMD_Pos 16 /**< \brief (SERCOM_I2CS_CTRLB) Command */ +#define SERCOM_I2CS_CTRLB_CMD_Msk (0x3u << SERCOM_I2CS_CTRLB_CMD_Pos) +#define SERCOM_I2CS_CTRLB_CMD(value) ((SERCOM_I2CS_CTRLB_CMD_Msk & ((value) << SERCOM_I2CS_CTRLB_CMD_Pos))) +#define SERCOM_I2CS_CTRLB_ACKACT_Pos 18 /**< \brief (SERCOM_I2CS_CTRLB) Acknowledge Action */ +#define SERCOM_I2CS_CTRLB_ACKACT (0x1u << SERCOM_I2CS_CTRLB_ACKACT_Pos) +#define SERCOM_I2CS_CTRLB_MASK 0x0007C700u /**< \brief (SERCOM_I2CS_CTRLB) MASK Register */ + +/* -------- SERCOM_SPI_CTRLB : (SERCOM Offset: 0x04) (R/W 32) SPI SPI Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CHSIZE:3; /*!< bit: 0.. 2 Character Size */ + uint32_t :3; /*!< bit: 3.. 5 Reserved */ + uint32_t PLOADEN:1; /*!< bit: 6 Data Preload Enable */ + uint32_t :2; /*!< bit: 7.. 8 Reserved */ + uint32_t SSDE:1; /*!< bit: 9 Slave Select Low Detect Enable */ + uint32_t :3; /*!< bit: 10..12 Reserved */ + uint32_t MSSEN:1; /*!< bit: 13 Master Slave Select Enable */ + uint32_t AMODE:2; /*!< bit: 14..15 Address Mode */ + uint32_t :1; /*!< bit: 16 Reserved */ + uint32_t RXEN:1; /*!< bit: 17 Receiver Enable */ + uint32_t :14; /*!< bit: 18..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_SPI_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_CTRLB_OFFSET 0x04 /**< \brief (SERCOM_SPI_CTRLB offset) SPI Control B */ +#define SERCOM_SPI_CTRLB_RESETVALUE 0x00000000 /**< \brief (SERCOM_SPI_CTRLB reset_value) SPI Control B */ + +#define SERCOM_SPI_CTRLB_CHSIZE_Pos 0 /**< \brief (SERCOM_SPI_CTRLB) Character Size */ +#define SERCOM_SPI_CTRLB_CHSIZE_Msk (0x7u << SERCOM_SPI_CTRLB_CHSIZE_Pos) +#define SERCOM_SPI_CTRLB_CHSIZE(value) ((SERCOM_SPI_CTRLB_CHSIZE_Msk & ((value) << SERCOM_SPI_CTRLB_CHSIZE_Pos))) +#define SERCOM_SPI_CTRLB_PLOADEN_Pos 6 /**< \brief (SERCOM_SPI_CTRLB) Data Preload Enable */ +#define SERCOM_SPI_CTRLB_PLOADEN (0x1u << SERCOM_SPI_CTRLB_PLOADEN_Pos) +#define SERCOM_SPI_CTRLB_SSDE_Pos 9 /**< \brief (SERCOM_SPI_CTRLB) Slave Select Low Detect Enable */ +#define SERCOM_SPI_CTRLB_SSDE (0x1u << SERCOM_SPI_CTRLB_SSDE_Pos) +#define SERCOM_SPI_CTRLB_MSSEN_Pos 13 /**< \brief (SERCOM_SPI_CTRLB) Master Slave Select Enable */ +#define SERCOM_SPI_CTRLB_MSSEN (0x1u << SERCOM_SPI_CTRLB_MSSEN_Pos) +#define SERCOM_SPI_CTRLB_AMODE_Pos 14 /**< \brief (SERCOM_SPI_CTRLB) Address Mode */ +#define SERCOM_SPI_CTRLB_AMODE_Msk (0x3u << SERCOM_SPI_CTRLB_AMODE_Pos) +#define SERCOM_SPI_CTRLB_AMODE(value) ((SERCOM_SPI_CTRLB_AMODE_Msk & ((value) << SERCOM_SPI_CTRLB_AMODE_Pos))) +#define SERCOM_SPI_CTRLB_RXEN_Pos 17 /**< \brief (SERCOM_SPI_CTRLB) Receiver Enable */ +#define SERCOM_SPI_CTRLB_RXEN (0x1u << SERCOM_SPI_CTRLB_RXEN_Pos) +#define SERCOM_SPI_CTRLB_MASK 0x0002E247u /**< \brief (SERCOM_SPI_CTRLB) MASK Register */ + +/* -------- SERCOM_USART_CTRLB : (SERCOM Offset: 0x04) (R/W 32) USART USART Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CHSIZE:3; /*!< bit: 0.. 2 Character Size */ + uint32_t :3; /*!< bit: 3.. 5 Reserved */ + uint32_t SBMODE:1; /*!< bit: 6 Stop Bit Mode */ + uint32_t :1; /*!< bit: 7 Reserved */ + uint32_t COLDEN:1; /*!< bit: 8 Collision Detection Enable */ + uint32_t SFDE:1; /*!< bit: 9 Start of Frame Detection Enable */ + uint32_t ENC:1; /*!< bit: 10 Encoding Format */ + uint32_t :2; /*!< bit: 11..12 Reserved */ + uint32_t PMODE:1; /*!< bit: 13 Parity Mode */ + uint32_t :2; /*!< bit: 14..15 Reserved */ + uint32_t TXEN:1; /*!< bit: 16 Transmitter Enable */ + uint32_t RXEN:1; /*!< bit: 17 Receiver Enable */ + uint32_t :14; /*!< bit: 18..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_USART_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_CTRLB_OFFSET 0x04 /**< \brief (SERCOM_USART_CTRLB offset) USART Control B */ +#define SERCOM_USART_CTRLB_RESETVALUE 0x00000000 /**< \brief (SERCOM_USART_CTRLB reset_value) USART Control B */ + +#define SERCOM_USART_CTRLB_CHSIZE_Pos 0 /**< \brief (SERCOM_USART_CTRLB) Character Size */ +#define SERCOM_USART_CTRLB_CHSIZE_Msk (0x7u << SERCOM_USART_CTRLB_CHSIZE_Pos) +#define SERCOM_USART_CTRLB_CHSIZE(value) ((SERCOM_USART_CTRLB_CHSIZE_Msk & ((value) << SERCOM_USART_CTRLB_CHSIZE_Pos))) +#define SERCOM_USART_CTRLB_SBMODE_Pos 6 /**< \brief (SERCOM_USART_CTRLB) Stop Bit Mode */ +#define SERCOM_USART_CTRLB_SBMODE (0x1u << SERCOM_USART_CTRLB_SBMODE_Pos) +#define SERCOM_USART_CTRLB_COLDEN_Pos 8 /**< \brief (SERCOM_USART_CTRLB) Collision Detection Enable */ +#define SERCOM_USART_CTRLB_COLDEN (0x1u << SERCOM_USART_CTRLB_COLDEN_Pos) +#define SERCOM_USART_CTRLB_SFDE_Pos 9 /**< \brief (SERCOM_USART_CTRLB) Start of Frame Detection Enable */ +#define SERCOM_USART_CTRLB_SFDE (0x1u << SERCOM_USART_CTRLB_SFDE_Pos) +#define SERCOM_USART_CTRLB_ENC_Pos 10 /**< \brief (SERCOM_USART_CTRLB) Encoding Format */ +#define SERCOM_USART_CTRLB_ENC (0x1u << SERCOM_USART_CTRLB_ENC_Pos) +#define SERCOM_USART_CTRLB_PMODE_Pos 13 /**< \brief (SERCOM_USART_CTRLB) Parity Mode */ +#define SERCOM_USART_CTRLB_PMODE (0x1u << SERCOM_USART_CTRLB_PMODE_Pos) +#define SERCOM_USART_CTRLB_TXEN_Pos 16 /**< \brief (SERCOM_USART_CTRLB) Transmitter Enable */ +#define SERCOM_USART_CTRLB_TXEN (0x1u << SERCOM_USART_CTRLB_TXEN_Pos) +#define SERCOM_USART_CTRLB_RXEN_Pos 17 /**< \brief (SERCOM_USART_CTRLB) Receiver Enable */ +#define SERCOM_USART_CTRLB_RXEN (0x1u << SERCOM_USART_CTRLB_RXEN_Pos) +#define SERCOM_USART_CTRLB_MASK 0x00032747u /**< \brief (SERCOM_USART_CTRLB) MASK Register */ + +/* -------- SERCOM_I2CM_BAUD : (SERCOM Offset: 0x0C) (R/W 32) I2CM I2CM Baud Rate -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t BAUD:8; /*!< bit: 0.. 7 Baud Rate Value */ + uint32_t BAUDLOW:8; /*!< bit: 8..15 Baud Rate Value Low */ + uint32_t HSBAUD:8; /*!< bit: 16..23 High Speed Baud Rate Value */ + uint32_t HSBAUDLOW:8; /*!< bit: 24..31 High Speed Baud Rate Value Low */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_BAUD_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_BAUD_OFFSET 0x0C /**< \brief (SERCOM_I2CM_BAUD offset) I2CM Baud Rate */ +#define SERCOM_I2CM_BAUD_RESETVALUE 0x00000000 /**< \brief (SERCOM_I2CM_BAUD reset_value) I2CM Baud Rate */ + +#define SERCOM_I2CM_BAUD_BAUD_Pos 0 /**< \brief (SERCOM_I2CM_BAUD) Baud Rate Value */ +#define SERCOM_I2CM_BAUD_BAUD_Msk (0xFFu << SERCOM_I2CM_BAUD_BAUD_Pos) +#define SERCOM_I2CM_BAUD_BAUD(value) ((SERCOM_I2CM_BAUD_BAUD_Msk & ((value) << SERCOM_I2CM_BAUD_BAUD_Pos))) +#define SERCOM_I2CM_BAUD_BAUDLOW_Pos 8 /**< \brief (SERCOM_I2CM_BAUD) Baud Rate Value Low */ +#define SERCOM_I2CM_BAUD_BAUDLOW_Msk (0xFFu << SERCOM_I2CM_BAUD_BAUDLOW_Pos) +#define SERCOM_I2CM_BAUD_BAUDLOW(value) ((SERCOM_I2CM_BAUD_BAUDLOW_Msk & ((value) << SERCOM_I2CM_BAUD_BAUDLOW_Pos))) +#define SERCOM_I2CM_BAUD_HSBAUD_Pos 16 /**< \brief (SERCOM_I2CM_BAUD) High Speed Baud Rate Value */ +#define SERCOM_I2CM_BAUD_HSBAUD_Msk (0xFFu << SERCOM_I2CM_BAUD_HSBAUD_Pos) +#define SERCOM_I2CM_BAUD_HSBAUD(value) ((SERCOM_I2CM_BAUD_HSBAUD_Msk & ((value) << SERCOM_I2CM_BAUD_HSBAUD_Pos))) +#define SERCOM_I2CM_BAUD_HSBAUDLOW_Pos 24 /**< \brief (SERCOM_I2CM_BAUD) High Speed Baud Rate Value Low */ +#define SERCOM_I2CM_BAUD_HSBAUDLOW_Msk (0xFFu << SERCOM_I2CM_BAUD_HSBAUDLOW_Pos) +#define SERCOM_I2CM_BAUD_HSBAUDLOW(value) ((SERCOM_I2CM_BAUD_HSBAUDLOW_Msk & ((value) << SERCOM_I2CM_BAUD_HSBAUDLOW_Pos))) +#define SERCOM_I2CM_BAUD_MASK 0xFFFFFFFFu /**< \brief (SERCOM_I2CM_BAUD) MASK Register */ + +/* -------- SERCOM_SPI_BAUD : (SERCOM Offset: 0x0C) (R/W 8) SPI SPI Baud Rate -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t BAUD:8; /*!< bit: 0.. 7 Baud Rate Value */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_SPI_BAUD_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_BAUD_OFFSET 0x0C /**< \brief (SERCOM_SPI_BAUD offset) SPI Baud Rate */ +#define SERCOM_SPI_BAUD_RESETVALUE 0x00 /**< \brief (SERCOM_SPI_BAUD reset_value) SPI Baud Rate */ + +#define SERCOM_SPI_BAUD_BAUD_Pos 0 /**< \brief (SERCOM_SPI_BAUD) Baud Rate Value */ +#define SERCOM_SPI_BAUD_BAUD_Msk (0xFFu << SERCOM_SPI_BAUD_BAUD_Pos) +#define SERCOM_SPI_BAUD_BAUD(value) ((SERCOM_SPI_BAUD_BAUD_Msk & ((value) << SERCOM_SPI_BAUD_BAUD_Pos))) +#define SERCOM_SPI_BAUD_MASK 0xFFu /**< \brief (SERCOM_SPI_BAUD) MASK Register */ + +/* -------- SERCOM_USART_BAUD : (SERCOM Offset: 0x0C) (R/W 16) USART USART Baud Rate -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t BAUD:16; /*!< bit: 0..15 Baud Rate Value */ + } bit; /*!< Structure used for bit access */ + struct { // FRAC mode + uint16_t BAUD:13; /*!< bit: 0..12 Baud Rate Value */ + uint16_t FP:3; /*!< bit: 13..15 Fractional Part */ + } FRAC; /*!< Structure used for FRAC */ + struct { // FRACFP mode + uint16_t BAUD:13; /*!< bit: 0..12 Baud Rate Value */ + uint16_t FP:3; /*!< bit: 13..15 Fractional Part */ + } FRACFP; /*!< Structure used for FRACFP */ + struct { // USARTFP mode + uint16_t BAUD:16; /*!< bit: 0..15 Baud Rate Value */ + } USARTFP; /*!< Structure used for USARTFP */ + uint16_t reg; /*!< Type used for register access */ +} SERCOM_USART_BAUD_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_BAUD_OFFSET 0x0C /**< \brief (SERCOM_USART_BAUD offset) USART Baud Rate */ +#define SERCOM_USART_BAUD_RESETVALUE 0x0000 /**< \brief (SERCOM_USART_BAUD reset_value) USART Baud Rate */ + +#define SERCOM_USART_BAUD_BAUD_Pos 0 /**< \brief (SERCOM_USART_BAUD) Baud Rate Value */ +#define SERCOM_USART_BAUD_BAUD_Msk (0xFFFFu << SERCOM_USART_BAUD_BAUD_Pos) +#define SERCOM_USART_BAUD_BAUD(value) ((SERCOM_USART_BAUD_BAUD_Msk & ((value) << SERCOM_USART_BAUD_BAUD_Pos))) +#define SERCOM_USART_BAUD_MASK 0xFFFFu /**< \brief (SERCOM_USART_BAUD) MASK Register */ + +// FRAC mode +#define SERCOM_USART_BAUD_FRAC_BAUD_Pos 0 /**< \brief (SERCOM_USART_BAUD_FRAC) Baud Rate Value */ +#define SERCOM_USART_BAUD_FRAC_BAUD_Msk (0x1FFFu << SERCOM_USART_BAUD_FRAC_BAUD_Pos) +#define SERCOM_USART_BAUD_FRAC_BAUD(value) ((SERCOM_USART_BAUD_FRAC_BAUD_Msk & ((value) << SERCOM_USART_BAUD_FRAC_BAUD_Pos))) +#define SERCOM_USART_BAUD_FRAC_FP_Pos 13 /**< \brief (SERCOM_USART_BAUD_FRAC) Fractional Part */ +#define SERCOM_USART_BAUD_FRAC_FP_Msk (0x7u << SERCOM_USART_BAUD_FRAC_FP_Pos) +#define SERCOM_USART_BAUD_FRAC_FP(value) ((SERCOM_USART_BAUD_FRAC_FP_Msk & ((value) << SERCOM_USART_BAUD_FRAC_FP_Pos))) +#define SERCOM_USART_BAUD_FRAC_MASK 0xFFFFu /**< \brief (SERCOM_USART_BAUD_FRAC) MASK Register */ + +// FRACFP mode +#define SERCOM_USART_BAUD_FRACFP_BAUD_Pos 0 /**< \brief (SERCOM_USART_BAUD_FRACFP) Baud Rate Value */ +#define SERCOM_USART_BAUD_FRACFP_BAUD_Msk (0x1FFFu << SERCOM_USART_BAUD_FRACFP_BAUD_Pos) +#define SERCOM_USART_BAUD_FRACFP_BAUD(value) ((SERCOM_USART_BAUD_FRACFP_BAUD_Msk & ((value) << SERCOM_USART_BAUD_FRACFP_BAUD_Pos))) +#define SERCOM_USART_BAUD_FRACFP_FP_Pos 13 /**< \brief (SERCOM_USART_BAUD_FRACFP) Fractional Part */ +#define SERCOM_USART_BAUD_FRACFP_FP_Msk (0x7u << SERCOM_USART_BAUD_FRACFP_FP_Pos) +#define SERCOM_USART_BAUD_FRACFP_FP(value) ((SERCOM_USART_BAUD_FRACFP_FP_Msk & ((value) << SERCOM_USART_BAUD_FRACFP_FP_Pos))) +#define SERCOM_USART_BAUD_FRACFP_MASK 0xFFFFu /**< \brief (SERCOM_USART_BAUD_FRACFP) MASK Register */ + +// USARTFP mode +#define SERCOM_USART_BAUD_USARTFP_BAUD_Pos 0 /**< \brief (SERCOM_USART_BAUD_USARTFP) Baud Rate Value */ +#define SERCOM_USART_BAUD_USARTFP_BAUD_Msk (0xFFFFu << SERCOM_USART_BAUD_USARTFP_BAUD_Pos) +#define SERCOM_USART_BAUD_USARTFP_BAUD(value) ((SERCOM_USART_BAUD_USARTFP_BAUD_Msk & ((value) << SERCOM_USART_BAUD_USARTFP_BAUD_Pos))) +#define SERCOM_USART_BAUD_USARTFP_MASK 0xFFFFu /**< \brief (SERCOM_USART_BAUD_USARTFP) MASK Register */ + +/* -------- SERCOM_USART_RXPL : (SERCOM Offset: 0x0E) (R/W 8) USART USART Receive Pulse Length -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t RXPL:8; /*!< bit: 0.. 7 Receive Pulse Length */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_USART_RXPL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_RXPL_OFFSET 0x0E /**< \brief (SERCOM_USART_RXPL offset) USART Receive Pulse Length */ +#define SERCOM_USART_RXPL_RESETVALUE 0x00 /**< \brief (SERCOM_USART_RXPL reset_value) USART Receive Pulse Length */ + +#define SERCOM_USART_RXPL_RXPL_Pos 0 /**< \brief (SERCOM_USART_RXPL) Receive Pulse Length */ +#define SERCOM_USART_RXPL_RXPL_Msk (0xFFu << SERCOM_USART_RXPL_RXPL_Pos) +#define SERCOM_USART_RXPL_RXPL(value) ((SERCOM_USART_RXPL_RXPL_Msk & ((value) << SERCOM_USART_RXPL_RXPL_Pos))) +#define SERCOM_USART_RXPL_MASK 0xFFu /**< \brief (SERCOM_USART_RXPL) MASK Register */ + +/* -------- SERCOM_I2CM_INTENCLR : (SERCOM Offset: 0x14) (R/W 8) I2CM I2CM Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t MB:1; /*!< bit: 0 Master On Bus Interrupt Disable */ + uint8_t SB:1; /*!< bit: 1 Slave On Bus Interrupt Disable */ + uint8_t :5; /*!< bit: 2.. 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt Disable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_INTENCLR_OFFSET 0x14 /**< \brief (SERCOM_I2CM_INTENCLR offset) I2CM Interrupt Enable Clear */ +#define SERCOM_I2CM_INTENCLR_RESETVALUE 0x00 /**< \brief (SERCOM_I2CM_INTENCLR reset_value) I2CM Interrupt Enable Clear */ + +#define SERCOM_I2CM_INTENCLR_MB_Pos 0 /**< \brief (SERCOM_I2CM_INTENCLR) Master On Bus Interrupt Disable */ +#define SERCOM_I2CM_INTENCLR_MB (0x1u << SERCOM_I2CM_INTENCLR_MB_Pos) +#define SERCOM_I2CM_INTENCLR_SB_Pos 1 /**< \brief (SERCOM_I2CM_INTENCLR) Slave On Bus Interrupt Disable */ +#define SERCOM_I2CM_INTENCLR_SB (0x1u << SERCOM_I2CM_INTENCLR_SB_Pos) +#define SERCOM_I2CM_INTENCLR_ERROR_Pos 7 /**< \brief (SERCOM_I2CM_INTENCLR) Combined Error Interrupt Disable */ +#define SERCOM_I2CM_INTENCLR_ERROR (0x1u << SERCOM_I2CM_INTENCLR_ERROR_Pos) +#define SERCOM_I2CM_INTENCLR_MASK 0x83u /**< \brief (SERCOM_I2CM_INTENCLR) MASK Register */ + +/* -------- SERCOM_I2CS_INTENCLR : (SERCOM Offset: 0x14) (R/W 8) I2CS I2CS Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PREC:1; /*!< bit: 0 Stop Received Interrupt Disable */ + uint8_t AMATCH:1; /*!< bit: 1 Address Match Interrupt Disable */ + uint8_t DRDY:1; /*!< bit: 2 Data Interrupt Disable */ + uint8_t :4; /*!< bit: 3.. 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt Disable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_I2CS_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CS_INTENCLR_OFFSET 0x14 /**< \brief (SERCOM_I2CS_INTENCLR offset) I2CS Interrupt Enable Clear */ +#define SERCOM_I2CS_INTENCLR_RESETVALUE 0x00 /**< \brief (SERCOM_I2CS_INTENCLR reset_value) I2CS Interrupt Enable Clear */ + +#define SERCOM_I2CS_INTENCLR_PREC_Pos 0 /**< \brief (SERCOM_I2CS_INTENCLR) Stop Received Interrupt Disable */ +#define SERCOM_I2CS_INTENCLR_PREC (0x1u << SERCOM_I2CS_INTENCLR_PREC_Pos) +#define SERCOM_I2CS_INTENCLR_AMATCH_Pos 1 /**< \brief (SERCOM_I2CS_INTENCLR) Address Match Interrupt Disable */ +#define SERCOM_I2CS_INTENCLR_AMATCH (0x1u << SERCOM_I2CS_INTENCLR_AMATCH_Pos) +#define SERCOM_I2CS_INTENCLR_DRDY_Pos 2 /**< \brief (SERCOM_I2CS_INTENCLR) Data Interrupt Disable */ +#define SERCOM_I2CS_INTENCLR_DRDY (0x1u << SERCOM_I2CS_INTENCLR_DRDY_Pos) +#define SERCOM_I2CS_INTENCLR_ERROR_Pos 7 /**< \brief (SERCOM_I2CS_INTENCLR) Combined Error Interrupt Disable */ +#define SERCOM_I2CS_INTENCLR_ERROR (0x1u << SERCOM_I2CS_INTENCLR_ERROR_Pos) +#define SERCOM_I2CS_INTENCLR_MASK 0x87u /**< \brief (SERCOM_I2CS_INTENCLR) MASK Register */ + +/* -------- SERCOM_SPI_INTENCLR : (SERCOM Offset: 0x14) (R/W 8) SPI SPI Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DRE:1; /*!< bit: 0 Data Register Empty Interrupt Disable */ + uint8_t TXC:1; /*!< bit: 1 Transmit Complete Interrupt Disable */ + uint8_t RXC:1; /*!< bit: 2 Receive Complete Interrupt Disable */ + uint8_t SSL:1; /*!< bit: 3 Slave Select Low Interrupt Disable */ + uint8_t :3; /*!< bit: 4.. 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt Disable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_SPI_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_INTENCLR_OFFSET 0x14 /**< \brief (SERCOM_SPI_INTENCLR offset) SPI Interrupt Enable Clear */ +#define SERCOM_SPI_INTENCLR_RESETVALUE 0x00 /**< \brief (SERCOM_SPI_INTENCLR reset_value) SPI Interrupt Enable Clear */ + +#define SERCOM_SPI_INTENCLR_DRE_Pos 0 /**< \brief (SERCOM_SPI_INTENCLR) Data Register Empty Interrupt Disable */ +#define SERCOM_SPI_INTENCLR_DRE (0x1u << SERCOM_SPI_INTENCLR_DRE_Pos) +#define SERCOM_SPI_INTENCLR_TXC_Pos 1 /**< \brief (SERCOM_SPI_INTENCLR) Transmit Complete Interrupt Disable */ +#define SERCOM_SPI_INTENCLR_TXC (0x1u << SERCOM_SPI_INTENCLR_TXC_Pos) +#define SERCOM_SPI_INTENCLR_RXC_Pos 2 /**< \brief (SERCOM_SPI_INTENCLR) Receive Complete Interrupt Disable */ +#define SERCOM_SPI_INTENCLR_RXC (0x1u << SERCOM_SPI_INTENCLR_RXC_Pos) +#define SERCOM_SPI_INTENCLR_SSL_Pos 3 /**< \brief (SERCOM_SPI_INTENCLR) Slave Select Low Interrupt Disable */ +#define SERCOM_SPI_INTENCLR_SSL (0x1u << SERCOM_SPI_INTENCLR_SSL_Pos) +#define SERCOM_SPI_INTENCLR_ERROR_Pos 7 /**< \brief (SERCOM_SPI_INTENCLR) Combined Error Interrupt Disable */ +#define SERCOM_SPI_INTENCLR_ERROR (0x1u << SERCOM_SPI_INTENCLR_ERROR_Pos) +#define SERCOM_SPI_INTENCLR_MASK 0x8Fu /**< \brief (SERCOM_SPI_INTENCLR) MASK Register */ + +/* -------- SERCOM_USART_INTENCLR : (SERCOM Offset: 0x14) (R/W 8) USART USART Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DRE:1; /*!< bit: 0 Data Register Empty Interrupt Disable */ + uint8_t TXC:1; /*!< bit: 1 Transmit Complete Interrupt Disable */ + uint8_t RXC:1; /*!< bit: 2 Receive Complete Interrupt Disable */ + uint8_t RXS:1; /*!< bit: 3 Receive Start Interrupt Disable */ + uint8_t CTSIC:1; /*!< bit: 4 Clear To Send Input Change Interrupt Disable */ + uint8_t RXBRK:1; /*!< bit: 5 Break Received Interrupt Disable */ + uint8_t :1; /*!< bit: 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt Disable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_USART_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_INTENCLR_OFFSET 0x14 /**< \brief (SERCOM_USART_INTENCLR offset) USART Interrupt Enable Clear */ +#define SERCOM_USART_INTENCLR_RESETVALUE 0x00 /**< \brief (SERCOM_USART_INTENCLR reset_value) USART Interrupt Enable Clear */ + +#define SERCOM_USART_INTENCLR_DRE_Pos 0 /**< \brief (SERCOM_USART_INTENCLR) Data Register Empty Interrupt Disable */ +#define SERCOM_USART_INTENCLR_DRE (0x1u << SERCOM_USART_INTENCLR_DRE_Pos) +#define SERCOM_USART_INTENCLR_TXC_Pos 1 /**< \brief (SERCOM_USART_INTENCLR) Transmit Complete Interrupt Disable */ +#define SERCOM_USART_INTENCLR_TXC (0x1u << SERCOM_USART_INTENCLR_TXC_Pos) +#define SERCOM_USART_INTENCLR_RXC_Pos 2 /**< \brief (SERCOM_USART_INTENCLR) Receive Complete Interrupt Disable */ +#define SERCOM_USART_INTENCLR_RXC (0x1u << SERCOM_USART_INTENCLR_RXC_Pos) +#define SERCOM_USART_INTENCLR_RXS_Pos 3 /**< \brief (SERCOM_USART_INTENCLR) Receive Start Interrupt Disable */ +#define SERCOM_USART_INTENCLR_RXS (0x1u << SERCOM_USART_INTENCLR_RXS_Pos) +#define SERCOM_USART_INTENCLR_CTSIC_Pos 4 /**< \brief (SERCOM_USART_INTENCLR) Clear To Send Input Change Interrupt Disable */ +#define SERCOM_USART_INTENCLR_CTSIC (0x1u << SERCOM_USART_INTENCLR_CTSIC_Pos) +#define SERCOM_USART_INTENCLR_RXBRK_Pos 5 /**< \brief (SERCOM_USART_INTENCLR) Break Received Interrupt Disable */ +#define SERCOM_USART_INTENCLR_RXBRK (0x1u << SERCOM_USART_INTENCLR_RXBRK_Pos) +#define SERCOM_USART_INTENCLR_ERROR_Pos 7 /**< \brief (SERCOM_USART_INTENCLR) Combined Error Interrupt Disable */ +#define SERCOM_USART_INTENCLR_ERROR (0x1u << SERCOM_USART_INTENCLR_ERROR_Pos) +#define SERCOM_USART_INTENCLR_MASK 0xBFu /**< \brief (SERCOM_USART_INTENCLR) MASK Register */ + +/* -------- SERCOM_I2CM_INTENSET : (SERCOM Offset: 0x16) (R/W 8) I2CM I2CM Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t MB:1; /*!< bit: 0 Master On Bus Interrupt Enable */ + uint8_t SB:1; /*!< bit: 1 Slave On Bus Interrupt Enable */ + uint8_t :5; /*!< bit: 2.. 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_INTENSET_OFFSET 0x16 /**< \brief (SERCOM_I2CM_INTENSET offset) I2CM Interrupt Enable Set */ +#define SERCOM_I2CM_INTENSET_RESETVALUE 0x00 /**< \brief (SERCOM_I2CM_INTENSET reset_value) I2CM Interrupt Enable Set */ + +#define SERCOM_I2CM_INTENSET_MB_Pos 0 /**< \brief (SERCOM_I2CM_INTENSET) Master On Bus Interrupt Enable */ +#define SERCOM_I2CM_INTENSET_MB (0x1u << SERCOM_I2CM_INTENSET_MB_Pos) +#define SERCOM_I2CM_INTENSET_SB_Pos 1 /**< \brief (SERCOM_I2CM_INTENSET) Slave On Bus Interrupt Enable */ +#define SERCOM_I2CM_INTENSET_SB (0x1u << SERCOM_I2CM_INTENSET_SB_Pos) +#define SERCOM_I2CM_INTENSET_ERROR_Pos 7 /**< \brief (SERCOM_I2CM_INTENSET) Combined Error Interrupt Enable */ +#define SERCOM_I2CM_INTENSET_ERROR (0x1u << SERCOM_I2CM_INTENSET_ERROR_Pos) +#define SERCOM_I2CM_INTENSET_MASK 0x83u /**< \brief (SERCOM_I2CM_INTENSET) MASK Register */ + +/* -------- SERCOM_I2CS_INTENSET : (SERCOM Offset: 0x16) (R/W 8) I2CS I2CS Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PREC:1; /*!< bit: 0 Stop Received Interrupt Enable */ + uint8_t AMATCH:1; /*!< bit: 1 Address Match Interrupt Enable */ + uint8_t DRDY:1; /*!< bit: 2 Data Interrupt Enable */ + uint8_t :4; /*!< bit: 3.. 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_I2CS_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CS_INTENSET_OFFSET 0x16 /**< \brief (SERCOM_I2CS_INTENSET offset) I2CS Interrupt Enable Set */ +#define SERCOM_I2CS_INTENSET_RESETVALUE 0x00 /**< \brief (SERCOM_I2CS_INTENSET reset_value) I2CS Interrupt Enable Set */ + +#define SERCOM_I2CS_INTENSET_PREC_Pos 0 /**< \brief (SERCOM_I2CS_INTENSET) Stop Received Interrupt Enable */ +#define SERCOM_I2CS_INTENSET_PREC (0x1u << SERCOM_I2CS_INTENSET_PREC_Pos) +#define SERCOM_I2CS_INTENSET_AMATCH_Pos 1 /**< \brief (SERCOM_I2CS_INTENSET) Address Match Interrupt Enable */ +#define SERCOM_I2CS_INTENSET_AMATCH (0x1u << SERCOM_I2CS_INTENSET_AMATCH_Pos) +#define SERCOM_I2CS_INTENSET_DRDY_Pos 2 /**< \brief (SERCOM_I2CS_INTENSET) Data Interrupt Enable */ +#define SERCOM_I2CS_INTENSET_DRDY (0x1u << SERCOM_I2CS_INTENSET_DRDY_Pos) +#define SERCOM_I2CS_INTENSET_ERROR_Pos 7 /**< \brief (SERCOM_I2CS_INTENSET) Combined Error Interrupt Enable */ +#define SERCOM_I2CS_INTENSET_ERROR (0x1u << SERCOM_I2CS_INTENSET_ERROR_Pos) +#define SERCOM_I2CS_INTENSET_MASK 0x87u /**< \brief (SERCOM_I2CS_INTENSET) MASK Register */ + +/* -------- SERCOM_SPI_INTENSET : (SERCOM Offset: 0x16) (R/W 8) SPI SPI Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DRE:1; /*!< bit: 0 Data Register Empty Interrupt Enable */ + uint8_t TXC:1; /*!< bit: 1 Transmit Complete Interrupt Enable */ + uint8_t RXC:1; /*!< bit: 2 Receive Complete Interrupt Enable */ + uint8_t SSL:1; /*!< bit: 3 Slave Select Low Interrupt Enable */ + uint8_t :3; /*!< bit: 4.. 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_SPI_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_INTENSET_OFFSET 0x16 /**< \brief (SERCOM_SPI_INTENSET offset) SPI Interrupt Enable Set */ +#define SERCOM_SPI_INTENSET_RESETVALUE 0x00 /**< \brief (SERCOM_SPI_INTENSET reset_value) SPI Interrupt Enable Set */ + +#define SERCOM_SPI_INTENSET_DRE_Pos 0 /**< \brief (SERCOM_SPI_INTENSET) Data Register Empty Interrupt Enable */ +#define SERCOM_SPI_INTENSET_DRE (0x1u << SERCOM_SPI_INTENSET_DRE_Pos) +#define SERCOM_SPI_INTENSET_TXC_Pos 1 /**< \brief (SERCOM_SPI_INTENSET) Transmit Complete Interrupt Enable */ +#define SERCOM_SPI_INTENSET_TXC (0x1u << SERCOM_SPI_INTENSET_TXC_Pos) +#define SERCOM_SPI_INTENSET_RXC_Pos 2 /**< \brief (SERCOM_SPI_INTENSET) Receive Complete Interrupt Enable */ +#define SERCOM_SPI_INTENSET_RXC (0x1u << SERCOM_SPI_INTENSET_RXC_Pos) +#define SERCOM_SPI_INTENSET_SSL_Pos 3 /**< \brief (SERCOM_SPI_INTENSET) Slave Select Low Interrupt Enable */ +#define SERCOM_SPI_INTENSET_SSL (0x1u << SERCOM_SPI_INTENSET_SSL_Pos) +#define SERCOM_SPI_INTENSET_ERROR_Pos 7 /**< \brief (SERCOM_SPI_INTENSET) Combined Error Interrupt Enable */ +#define SERCOM_SPI_INTENSET_ERROR (0x1u << SERCOM_SPI_INTENSET_ERROR_Pos) +#define SERCOM_SPI_INTENSET_MASK 0x8Fu /**< \brief (SERCOM_SPI_INTENSET) MASK Register */ + +/* -------- SERCOM_USART_INTENSET : (SERCOM Offset: 0x16) (R/W 8) USART USART Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DRE:1; /*!< bit: 0 Data Register Empty Interrupt Enable */ + uint8_t TXC:1; /*!< bit: 1 Transmit Complete Interrupt Enable */ + uint8_t RXC:1; /*!< bit: 2 Receive Complete Interrupt Enable */ + uint8_t RXS:1; /*!< bit: 3 Receive Start Interrupt Enable */ + uint8_t CTSIC:1; /*!< bit: 4 Clear To Send Input Change Interrupt Enable */ + uint8_t RXBRK:1; /*!< bit: 5 Break Received Interrupt Enable */ + uint8_t :1; /*!< bit: 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_USART_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_INTENSET_OFFSET 0x16 /**< \brief (SERCOM_USART_INTENSET offset) USART Interrupt Enable Set */ +#define SERCOM_USART_INTENSET_RESETVALUE 0x00 /**< \brief (SERCOM_USART_INTENSET reset_value) USART Interrupt Enable Set */ + +#define SERCOM_USART_INTENSET_DRE_Pos 0 /**< \brief (SERCOM_USART_INTENSET) Data Register Empty Interrupt Enable */ +#define SERCOM_USART_INTENSET_DRE (0x1u << SERCOM_USART_INTENSET_DRE_Pos) +#define SERCOM_USART_INTENSET_TXC_Pos 1 /**< \brief (SERCOM_USART_INTENSET) Transmit Complete Interrupt Enable */ +#define SERCOM_USART_INTENSET_TXC (0x1u << SERCOM_USART_INTENSET_TXC_Pos) +#define SERCOM_USART_INTENSET_RXC_Pos 2 /**< \brief (SERCOM_USART_INTENSET) Receive Complete Interrupt Enable */ +#define SERCOM_USART_INTENSET_RXC (0x1u << SERCOM_USART_INTENSET_RXC_Pos) +#define SERCOM_USART_INTENSET_RXS_Pos 3 /**< \brief (SERCOM_USART_INTENSET) Receive Start Interrupt Enable */ +#define SERCOM_USART_INTENSET_RXS (0x1u << SERCOM_USART_INTENSET_RXS_Pos) +#define SERCOM_USART_INTENSET_CTSIC_Pos 4 /**< \brief (SERCOM_USART_INTENSET) Clear To Send Input Change Interrupt Enable */ +#define SERCOM_USART_INTENSET_CTSIC (0x1u << SERCOM_USART_INTENSET_CTSIC_Pos) +#define SERCOM_USART_INTENSET_RXBRK_Pos 5 /**< \brief (SERCOM_USART_INTENSET) Break Received Interrupt Enable */ +#define SERCOM_USART_INTENSET_RXBRK (0x1u << SERCOM_USART_INTENSET_RXBRK_Pos) +#define SERCOM_USART_INTENSET_ERROR_Pos 7 /**< \brief (SERCOM_USART_INTENSET) Combined Error Interrupt Enable */ +#define SERCOM_USART_INTENSET_ERROR (0x1u << SERCOM_USART_INTENSET_ERROR_Pos) +#define SERCOM_USART_INTENSET_MASK 0xBFu /**< \brief (SERCOM_USART_INTENSET) MASK Register */ + +/* -------- SERCOM_I2CM_INTFLAG : (SERCOM Offset: 0x18) (R/W 8) I2CM I2CM Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t MB:1; /*!< bit: 0 Master On Bus Interrupt */ + uint8_t SB:1; /*!< bit: 1 Slave On Bus Interrupt */ + uint8_t :5; /*!< bit: 2.. 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_INTFLAG_OFFSET 0x18 /**< \brief (SERCOM_I2CM_INTFLAG offset) I2CM Interrupt Flag Status and Clear */ +#define SERCOM_I2CM_INTFLAG_RESETVALUE 0x00 /**< \brief (SERCOM_I2CM_INTFLAG reset_value) I2CM Interrupt Flag Status and Clear */ + +#define SERCOM_I2CM_INTFLAG_MB_Pos 0 /**< \brief (SERCOM_I2CM_INTFLAG) Master On Bus Interrupt */ +#define SERCOM_I2CM_INTFLAG_MB (0x1u << SERCOM_I2CM_INTFLAG_MB_Pos) +#define SERCOM_I2CM_INTFLAG_SB_Pos 1 /**< \brief (SERCOM_I2CM_INTFLAG) Slave On Bus Interrupt */ +#define SERCOM_I2CM_INTFLAG_SB (0x1u << SERCOM_I2CM_INTFLAG_SB_Pos) +#define SERCOM_I2CM_INTFLAG_ERROR_Pos 7 /**< \brief (SERCOM_I2CM_INTFLAG) Combined Error Interrupt */ +#define SERCOM_I2CM_INTFLAG_ERROR (0x1u << SERCOM_I2CM_INTFLAG_ERROR_Pos) +#define SERCOM_I2CM_INTFLAG_MASK 0x83u /**< \brief (SERCOM_I2CM_INTFLAG) MASK Register */ + +/* -------- SERCOM_I2CS_INTFLAG : (SERCOM Offset: 0x18) (R/W 8) I2CS I2CS Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PREC:1; /*!< bit: 0 Stop Received Interrupt */ + uint8_t AMATCH:1; /*!< bit: 1 Address Match Interrupt */ + uint8_t DRDY:1; /*!< bit: 2 Data Interrupt */ + uint8_t :4; /*!< bit: 3.. 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_I2CS_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CS_INTFLAG_OFFSET 0x18 /**< \brief (SERCOM_I2CS_INTFLAG offset) I2CS Interrupt Flag Status and Clear */ +#define SERCOM_I2CS_INTFLAG_RESETVALUE 0x00 /**< \brief (SERCOM_I2CS_INTFLAG reset_value) I2CS Interrupt Flag Status and Clear */ + +#define SERCOM_I2CS_INTFLAG_PREC_Pos 0 /**< \brief (SERCOM_I2CS_INTFLAG) Stop Received Interrupt */ +#define SERCOM_I2CS_INTFLAG_PREC (0x1u << SERCOM_I2CS_INTFLAG_PREC_Pos) +#define SERCOM_I2CS_INTFLAG_AMATCH_Pos 1 /**< \brief (SERCOM_I2CS_INTFLAG) Address Match Interrupt */ +#define SERCOM_I2CS_INTFLAG_AMATCH (0x1u << SERCOM_I2CS_INTFLAG_AMATCH_Pos) +#define SERCOM_I2CS_INTFLAG_DRDY_Pos 2 /**< \brief (SERCOM_I2CS_INTFLAG) Data Interrupt */ +#define SERCOM_I2CS_INTFLAG_DRDY (0x1u << SERCOM_I2CS_INTFLAG_DRDY_Pos) +#define SERCOM_I2CS_INTFLAG_ERROR_Pos 7 /**< \brief (SERCOM_I2CS_INTFLAG) Combined Error Interrupt */ +#define SERCOM_I2CS_INTFLAG_ERROR (0x1u << SERCOM_I2CS_INTFLAG_ERROR_Pos) +#define SERCOM_I2CS_INTFLAG_MASK 0x87u /**< \brief (SERCOM_I2CS_INTFLAG) MASK Register */ + +/* -------- SERCOM_SPI_INTFLAG : (SERCOM Offset: 0x18) (R/W 8) SPI SPI Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DRE:1; /*!< bit: 0 Data Register Empty Interrupt */ + uint8_t TXC:1; /*!< bit: 1 Transmit Complete Interrupt */ + uint8_t RXC:1; /*!< bit: 2 Receive Complete Interrupt */ + uint8_t SSL:1; /*!< bit: 3 Slave Select Low Interrupt Flag */ + uint8_t :3; /*!< bit: 4.. 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_SPI_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_INTFLAG_OFFSET 0x18 /**< \brief (SERCOM_SPI_INTFLAG offset) SPI Interrupt Flag Status and Clear */ +#define SERCOM_SPI_INTFLAG_RESETVALUE 0x00 /**< \brief (SERCOM_SPI_INTFLAG reset_value) SPI Interrupt Flag Status and Clear */ + +#define SERCOM_SPI_INTFLAG_DRE_Pos 0 /**< \brief (SERCOM_SPI_INTFLAG) Data Register Empty Interrupt */ +#define SERCOM_SPI_INTFLAG_DRE (0x1u << SERCOM_SPI_INTFLAG_DRE_Pos) +#define SERCOM_SPI_INTFLAG_TXC_Pos 1 /**< \brief (SERCOM_SPI_INTFLAG) Transmit Complete Interrupt */ +#define SERCOM_SPI_INTFLAG_TXC (0x1u << SERCOM_SPI_INTFLAG_TXC_Pos) +#define SERCOM_SPI_INTFLAG_RXC_Pos 2 /**< \brief (SERCOM_SPI_INTFLAG) Receive Complete Interrupt */ +#define SERCOM_SPI_INTFLAG_RXC (0x1u << SERCOM_SPI_INTFLAG_RXC_Pos) +#define SERCOM_SPI_INTFLAG_SSL_Pos 3 /**< \brief (SERCOM_SPI_INTFLAG) Slave Select Low Interrupt Flag */ +#define SERCOM_SPI_INTFLAG_SSL (0x1u << SERCOM_SPI_INTFLAG_SSL_Pos) +#define SERCOM_SPI_INTFLAG_ERROR_Pos 7 /**< \brief (SERCOM_SPI_INTFLAG) Combined Error Interrupt */ +#define SERCOM_SPI_INTFLAG_ERROR (0x1u << SERCOM_SPI_INTFLAG_ERROR_Pos) +#define SERCOM_SPI_INTFLAG_MASK 0x8Fu /**< \brief (SERCOM_SPI_INTFLAG) MASK Register */ + +/* -------- SERCOM_USART_INTFLAG : (SERCOM Offset: 0x18) (R/W 8) USART USART Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DRE:1; /*!< bit: 0 Data Register Empty Interrupt */ + uint8_t TXC:1; /*!< bit: 1 Transmit Complete Interrupt */ + uint8_t RXC:1; /*!< bit: 2 Receive Complete Interrupt */ + uint8_t RXS:1; /*!< bit: 3 Receive Start Interrupt */ + uint8_t CTSIC:1; /*!< bit: 4 Clear To Send Input Change Interrupt */ + uint8_t RXBRK:1; /*!< bit: 5 Break Received Interrupt */ + uint8_t :1; /*!< bit: 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_USART_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_INTFLAG_OFFSET 0x18 /**< \brief (SERCOM_USART_INTFLAG offset) USART Interrupt Flag Status and Clear */ +#define SERCOM_USART_INTFLAG_RESETVALUE 0x00 /**< \brief (SERCOM_USART_INTFLAG reset_value) USART Interrupt Flag Status and Clear */ + +#define SERCOM_USART_INTFLAG_DRE_Pos 0 /**< \brief (SERCOM_USART_INTFLAG) Data Register Empty Interrupt */ +#define SERCOM_USART_INTFLAG_DRE (0x1u << SERCOM_USART_INTFLAG_DRE_Pos) +#define SERCOM_USART_INTFLAG_TXC_Pos 1 /**< \brief (SERCOM_USART_INTFLAG) Transmit Complete Interrupt */ +#define SERCOM_USART_INTFLAG_TXC (0x1u << SERCOM_USART_INTFLAG_TXC_Pos) +#define SERCOM_USART_INTFLAG_RXC_Pos 2 /**< \brief (SERCOM_USART_INTFLAG) Receive Complete Interrupt */ +#define SERCOM_USART_INTFLAG_RXC (0x1u << SERCOM_USART_INTFLAG_RXC_Pos) +#define SERCOM_USART_INTFLAG_RXS_Pos 3 /**< \brief (SERCOM_USART_INTFLAG) Receive Start Interrupt */ +#define SERCOM_USART_INTFLAG_RXS (0x1u << SERCOM_USART_INTFLAG_RXS_Pos) +#define SERCOM_USART_INTFLAG_CTSIC_Pos 4 /**< \brief (SERCOM_USART_INTFLAG) Clear To Send Input Change Interrupt */ +#define SERCOM_USART_INTFLAG_CTSIC (0x1u << SERCOM_USART_INTFLAG_CTSIC_Pos) +#define SERCOM_USART_INTFLAG_RXBRK_Pos 5 /**< \brief (SERCOM_USART_INTFLAG) Break Received Interrupt */ +#define SERCOM_USART_INTFLAG_RXBRK (0x1u << SERCOM_USART_INTFLAG_RXBRK_Pos) +#define SERCOM_USART_INTFLAG_ERROR_Pos 7 /**< \brief (SERCOM_USART_INTFLAG) Combined Error Interrupt */ +#define SERCOM_USART_INTFLAG_ERROR (0x1u << SERCOM_USART_INTFLAG_ERROR_Pos) +#define SERCOM_USART_INTFLAG_MASK 0xBFu /**< \brief (SERCOM_USART_INTFLAG) MASK Register */ + +/* -------- SERCOM_I2CM_STATUS : (SERCOM Offset: 0x1A) (R/W 16) I2CM I2CM Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t BUSERR:1; /*!< bit: 0 Bus Error */ + uint16_t ARBLOST:1; /*!< bit: 1 Arbitration Lost */ + uint16_t RXNACK:1; /*!< bit: 2 Received Not Acknowledge */ + uint16_t :1; /*!< bit: 3 Reserved */ + uint16_t BUSSTATE:2; /*!< bit: 4.. 5 Bus State */ + uint16_t LOWTOUT:1; /*!< bit: 6 SCL Low Timeout */ + uint16_t CLKHOLD:1; /*!< bit: 7 Clock Hold */ + uint16_t MEXTTOUT:1; /*!< bit: 8 Master SCL Low Extend Timeout */ + uint16_t SEXTTOUT:1; /*!< bit: 9 Slave SCL Low Extend Timeout */ + uint16_t LENERR:1; /*!< bit: 10 Length Error */ + uint16_t :5; /*!< bit: 11..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_STATUS_OFFSET 0x1A /**< \brief (SERCOM_I2CM_STATUS offset) I2CM Status */ +#define SERCOM_I2CM_STATUS_RESETVALUE 0x0000 /**< \brief (SERCOM_I2CM_STATUS reset_value) I2CM Status */ + +#define SERCOM_I2CM_STATUS_BUSERR_Pos 0 /**< \brief (SERCOM_I2CM_STATUS) Bus Error */ +#define SERCOM_I2CM_STATUS_BUSERR (0x1u << SERCOM_I2CM_STATUS_BUSERR_Pos) +#define SERCOM_I2CM_STATUS_ARBLOST_Pos 1 /**< \brief (SERCOM_I2CM_STATUS) Arbitration Lost */ +#define SERCOM_I2CM_STATUS_ARBLOST (0x1u << SERCOM_I2CM_STATUS_ARBLOST_Pos) +#define SERCOM_I2CM_STATUS_RXNACK_Pos 2 /**< \brief (SERCOM_I2CM_STATUS) Received Not Acknowledge */ +#define SERCOM_I2CM_STATUS_RXNACK (0x1u << SERCOM_I2CM_STATUS_RXNACK_Pos) +#define SERCOM_I2CM_STATUS_BUSSTATE_Pos 4 /**< \brief (SERCOM_I2CM_STATUS) Bus State */ +#define SERCOM_I2CM_STATUS_BUSSTATE_Msk (0x3u << SERCOM_I2CM_STATUS_BUSSTATE_Pos) +#define SERCOM_I2CM_STATUS_BUSSTATE(value) ((SERCOM_I2CM_STATUS_BUSSTATE_Msk & ((value) << SERCOM_I2CM_STATUS_BUSSTATE_Pos))) +#define SERCOM_I2CM_STATUS_LOWTOUT_Pos 6 /**< \brief (SERCOM_I2CM_STATUS) SCL Low Timeout */ +#define SERCOM_I2CM_STATUS_LOWTOUT (0x1u << SERCOM_I2CM_STATUS_LOWTOUT_Pos) +#define SERCOM_I2CM_STATUS_CLKHOLD_Pos 7 /**< \brief (SERCOM_I2CM_STATUS) Clock Hold */ +#define SERCOM_I2CM_STATUS_CLKHOLD (0x1u << SERCOM_I2CM_STATUS_CLKHOLD_Pos) +#define SERCOM_I2CM_STATUS_MEXTTOUT_Pos 8 /**< \brief (SERCOM_I2CM_STATUS) Master SCL Low Extend Timeout */ +#define SERCOM_I2CM_STATUS_MEXTTOUT (0x1u << SERCOM_I2CM_STATUS_MEXTTOUT_Pos) +#define SERCOM_I2CM_STATUS_SEXTTOUT_Pos 9 /**< \brief (SERCOM_I2CM_STATUS) Slave SCL Low Extend Timeout */ +#define SERCOM_I2CM_STATUS_SEXTTOUT (0x1u << SERCOM_I2CM_STATUS_SEXTTOUT_Pos) +#define SERCOM_I2CM_STATUS_LENERR_Pos 10 /**< \brief (SERCOM_I2CM_STATUS) Length Error */ +#define SERCOM_I2CM_STATUS_LENERR (0x1u << SERCOM_I2CM_STATUS_LENERR_Pos) +#define SERCOM_I2CM_STATUS_MASK 0x07F7u /**< \brief (SERCOM_I2CM_STATUS) MASK Register */ + +/* -------- SERCOM_I2CS_STATUS : (SERCOM Offset: 0x1A) (R/W 16) I2CS I2CS Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t BUSERR:1; /*!< bit: 0 Bus Error */ + uint16_t COLL:1; /*!< bit: 1 Transmit Collision */ + uint16_t RXNACK:1; /*!< bit: 2 Received Not Acknowledge */ + uint16_t DIR:1; /*!< bit: 3 Read/Write Direction */ + uint16_t SR:1; /*!< bit: 4 Repeated Start */ + uint16_t :1; /*!< bit: 5 Reserved */ + uint16_t LOWTOUT:1; /*!< bit: 6 SCL Low Timeout */ + uint16_t CLKHOLD:1; /*!< bit: 7 Clock Hold */ + uint16_t :1; /*!< bit: 8 Reserved */ + uint16_t SEXTTOUT:1; /*!< bit: 9 Slave SCL Low Extend Timeout */ + uint16_t HS:1; /*!< bit: 10 High Speed */ + uint16_t :5; /*!< bit: 11..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} SERCOM_I2CS_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CS_STATUS_OFFSET 0x1A /**< \brief (SERCOM_I2CS_STATUS offset) I2CS Status */ +#define SERCOM_I2CS_STATUS_RESETVALUE 0x0000 /**< \brief (SERCOM_I2CS_STATUS reset_value) I2CS Status */ + +#define SERCOM_I2CS_STATUS_BUSERR_Pos 0 /**< \brief (SERCOM_I2CS_STATUS) Bus Error */ +#define SERCOM_I2CS_STATUS_BUSERR (0x1u << SERCOM_I2CS_STATUS_BUSERR_Pos) +#define SERCOM_I2CS_STATUS_COLL_Pos 1 /**< \brief (SERCOM_I2CS_STATUS) Transmit Collision */ +#define SERCOM_I2CS_STATUS_COLL (0x1u << SERCOM_I2CS_STATUS_COLL_Pos) +#define SERCOM_I2CS_STATUS_RXNACK_Pos 2 /**< \brief (SERCOM_I2CS_STATUS) Received Not Acknowledge */ +#define SERCOM_I2CS_STATUS_RXNACK (0x1u << SERCOM_I2CS_STATUS_RXNACK_Pos) +#define SERCOM_I2CS_STATUS_DIR_Pos 3 /**< \brief (SERCOM_I2CS_STATUS) Read/Write Direction */ +#define SERCOM_I2CS_STATUS_DIR (0x1u << SERCOM_I2CS_STATUS_DIR_Pos) +#define SERCOM_I2CS_STATUS_SR_Pos 4 /**< \brief (SERCOM_I2CS_STATUS) Repeated Start */ +#define SERCOM_I2CS_STATUS_SR (0x1u << SERCOM_I2CS_STATUS_SR_Pos) +#define SERCOM_I2CS_STATUS_LOWTOUT_Pos 6 /**< \brief (SERCOM_I2CS_STATUS) SCL Low Timeout */ +#define SERCOM_I2CS_STATUS_LOWTOUT (0x1u << SERCOM_I2CS_STATUS_LOWTOUT_Pos) +#define SERCOM_I2CS_STATUS_CLKHOLD_Pos 7 /**< \brief (SERCOM_I2CS_STATUS) Clock Hold */ +#define SERCOM_I2CS_STATUS_CLKHOLD (0x1u << SERCOM_I2CS_STATUS_CLKHOLD_Pos) +#define SERCOM_I2CS_STATUS_SEXTTOUT_Pos 9 /**< \brief (SERCOM_I2CS_STATUS) Slave SCL Low Extend Timeout */ +#define SERCOM_I2CS_STATUS_SEXTTOUT (0x1u << SERCOM_I2CS_STATUS_SEXTTOUT_Pos) +#define SERCOM_I2CS_STATUS_HS_Pos 10 /**< \brief (SERCOM_I2CS_STATUS) High Speed */ +#define SERCOM_I2CS_STATUS_HS (0x1u << SERCOM_I2CS_STATUS_HS_Pos) +#define SERCOM_I2CS_STATUS_MASK 0x06DFu /**< \brief (SERCOM_I2CS_STATUS) MASK Register */ + +/* -------- SERCOM_SPI_STATUS : (SERCOM Offset: 0x1A) (R/W 16) SPI SPI Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t :2; /*!< bit: 0.. 1 Reserved */ + uint16_t BUFOVF:1; /*!< bit: 2 Buffer Overflow */ + uint16_t :13; /*!< bit: 3..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} SERCOM_SPI_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_STATUS_OFFSET 0x1A /**< \brief (SERCOM_SPI_STATUS offset) SPI Status */ +#define SERCOM_SPI_STATUS_RESETVALUE 0x0000 /**< \brief (SERCOM_SPI_STATUS reset_value) SPI Status */ + +#define SERCOM_SPI_STATUS_BUFOVF_Pos 2 /**< \brief (SERCOM_SPI_STATUS) Buffer Overflow */ +#define SERCOM_SPI_STATUS_BUFOVF (0x1u << SERCOM_SPI_STATUS_BUFOVF_Pos) +#define SERCOM_SPI_STATUS_MASK 0x0004u /**< \brief (SERCOM_SPI_STATUS) MASK Register */ + +/* -------- SERCOM_USART_STATUS : (SERCOM Offset: 0x1A) (R/W 16) USART USART Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t PERR:1; /*!< bit: 0 Parity Error */ + uint16_t FERR:1; /*!< bit: 1 Frame Error */ + uint16_t BUFOVF:1; /*!< bit: 2 Buffer Overflow */ + uint16_t CTS:1; /*!< bit: 3 Clear To Send */ + uint16_t ISF:1; /*!< bit: 4 Inconsistent Sync Field */ + uint16_t COLL:1; /*!< bit: 5 Collision Detected */ + uint16_t :10; /*!< bit: 6..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} SERCOM_USART_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_STATUS_OFFSET 0x1A /**< \brief (SERCOM_USART_STATUS offset) USART Status */ +#define SERCOM_USART_STATUS_RESETVALUE 0x0000 /**< \brief (SERCOM_USART_STATUS reset_value) USART Status */ + +#define SERCOM_USART_STATUS_PERR_Pos 0 /**< \brief (SERCOM_USART_STATUS) Parity Error */ +#define SERCOM_USART_STATUS_PERR (0x1u << SERCOM_USART_STATUS_PERR_Pos) +#define SERCOM_USART_STATUS_FERR_Pos 1 /**< \brief (SERCOM_USART_STATUS) Frame Error */ +#define SERCOM_USART_STATUS_FERR (0x1u << SERCOM_USART_STATUS_FERR_Pos) +#define SERCOM_USART_STATUS_BUFOVF_Pos 2 /**< \brief (SERCOM_USART_STATUS) Buffer Overflow */ +#define SERCOM_USART_STATUS_BUFOVF (0x1u << SERCOM_USART_STATUS_BUFOVF_Pos) +#define SERCOM_USART_STATUS_CTS_Pos 3 /**< \brief (SERCOM_USART_STATUS) Clear To Send */ +#define SERCOM_USART_STATUS_CTS (0x1u << SERCOM_USART_STATUS_CTS_Pos) +#define SERCOM_USART_STATUS_ISF_Pos 4 /**< \brief (SERCOM_USART_STATUS) Inconsistent Sync Field */ +#define SERCOM_USART_STATUS_ISF (0x1u << SERCOM_USART_STATUS_ISF_Pos) +#define SERCOM_USART_STATUS_COLL_Pos 5 /**< \brief (SERCOM_USART_STATUS) Collision Detected */ +#define SERCOM_USART_STATUS_COLL (0x1u << SERCOM_USART_STATUS_COLL_Pos) +#define SERCOM_USART_STATUS_MASK 0x003Fu /**< \brief (SERCOM_USART_STATUS) MASK Register */ + +/* -------- SERCOM_I2CM_SYNCBUSY : (SERCOM Offset: 0x1C) (R/ 32) I2CM I2CM Syncbusy -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Software Reset Synchronization Busy */ + uint32_t ENABLE:1; /*!< bit: 1 SERCOM Enable Synchronization Busy */ + uint32_t SYSOP:1; /*!< bit: 2 System Operation Synchronization Busy */ + uint32_t :29; /*!< bit: 3..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_SYNCBUSY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_SYNCBUSY_OFFSET 0x1C /**< \brief (SERCOM_I2CM_SYNCBUSY offset) I2CM Syncbusy */ +#define SERCOM_I2CM_SYNCBUSY_RESETVALUE 0x00000000 /**< \brief (SERCOM_I2CM_SYNCBUSY reset_value) I2CM Syncbusy */ + +#define SERCOM_I2CM_SYNCBUSY_SWRST_Pos 0 /**< \brief (SERCOM_I2CM_SYNCBUSY) Software Reset Synchronization Busy */ +#define SERCOM_I2CM_SYNCBUSY_SWRST (0x1u << SERCOM_I2CM_SYNCBUSY_SWRST_Pos) +#define SERCOM_I2CM_SYNCBUSY_ENABLE_Pos 1 /**< \brief (SERCOM_I2CM_SYNCBUSY) SERCOM Enable Synchronization Busy */ +#define SERCOM_I2CM_SYNCBUSY_ENABLE (0x1u << SERCOM_I2CM_SYNCBUSY_ENABLE_Pos) +#define SERCOM_I2CM_SYNCBUSY_SYSOP_Pos 2 /**< \brief (SERCOM_I2CM_SYNCBUSY) System Operation Synchronization Busy */ +#define SERCOM_I2CM_SYNCBUSY_SYSOP (0x1u << SERCOM_I2CM_SYNCBUSY_SYSOP_Pos) +#define SERCOM_I2CM_SYNCBUSY_MASK 0x00000007u /**< \brief (SERCOM_I2CM_SYNCBUSY) MASK Register */ + +/* -------- SERCOM_I2CS_SYNCBUSY : (SERCOM Offset: 0x1C) (R/ 32) I2CS I2CS Syncbusy -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Software Reset Synchronization Busy */ + uint32_t ENABLE:1; /*!< bit: 1 SERCOM Enable Synchronization Busy */ + uint32_t :30; /*!< bit: 2..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_I2CS_SYNCBUSY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CS_SYNCBUSY_OFFSET 0x1C /**< \brief (SERCOM_I2CS_SYNCBUSY offset) I2CS Syncbusy */ +#define SERCOM_I2CS_SYNCBUSY_RESETVALUE 0x00000000 /**< \brief (SERCOM_I2CS_SYNCBUSY reset_value) I2CS Syncbusy */ + +#define SERCOM_I2CS_SYNCBUSY_SWRST_Pos 0 /**< \brief (SERCOM_I2CS_SYNCBUSY) Software Reset Synchronization Busy */ +#define SERCOM_I2CS_SYNCBUSY_SWRST (0x1u << SERCOM_I2CS_SYNCBUSY_SWRST_Pos) +#define SERCOM_I2CS_SYNCBUSY_ENABLE_Pos 1 /**< \brief (SERCOM_I2CS_SYNCBUSY) SERCOM Enable Synchronization Busy */ +#define SERCOM_I2CS_SYNCBUSY_ENABLE (0x1u << SERCOM_I2CS_SYNCBUSY_ENABLE_Pos) +#define SERCOM_I2CS_SYNCBUSY_MASK 0x00000003u /**< \brief (SERCOM_I2CS_SYNCBUSY) MASK Register */ + +/* -------- SERCOM_SPI_SYNCBUSY : (SERCOM Offset: 0x1C) (R/ 32) SPI SPI Syncbusy -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Software Reset Synchronization Busy */ + uint32_t ENABLE:1; /*!< bit: 1 SERCOM Enable Synchronization Busy */ + uint32_t CTRLB:1; /*!< bit: 2 CTRLB Synchronization Busy */ + uint32_t :29; /*!< bit: 3..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_SPI_SYNCBUSY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_SYNCBUSY_OFFSET 0x1C /**< \brief (SERCOM_SPI_SYNCBUSY offset) SPI Syncbusy */ +#define SERCOM_SPI_SYNCBUSY_RESETVALUE 0x00000000 /**< \brief (SERCOM_SPI_SYNCBUSY reset_value) SPI Syncbusy */ + +#define SERCOM_SPI_SYNCBUSY_SWRST_Pos 0 /**< \brief (SERCOM_SPI_SYNCBUSY) Software Reset Synchronization Busy */ +#define SERCOM_SPI_SYNCBUSY_SWRST (0x1u << SERCOM_SPI_SYNCBUSY_SWRST_Pos) +#define SERCOM_SPI_SYNCBUSY_ENABLE_Pos 1 /**< \brief (SERCOM_SPI_SYNCBUSY) SERCOM Enable Synchronization Busy */ +#define SERCOM_SPI_SYNCBUSY_ENABLE (0x1u << SERCOM_SPI_SYNCBUSY_ENABLE_Pos) +#define SERCOM_SPI_SYNCBUSY_CTRLB_Pos 2 /**< \brief (SERCOM_SPI_SYNCBUSY) CTRLB Synchronization Busy */ +#define SERCOM_SPI_SYNCBUSY_CTRLB (0x1u << SERCOM_SPI_SYNCBUSY_CTRLB_Pos) +#define SERCOM_SPI_SYNCBUSY_MASK 0x00000007u /**< \brief (SERCOM_SPI_SYNCBUSY) MASK Register */ + +/* -------- SERCOM_USART_SYNCBUSY : (SERCOM Offset: 0x1C) (R/ 32) USART USART Syncbusy -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Software Reset Synchronization Busy */ + uint32_t ENABLE:1; /*!< bit: 1 SERCOM Enable Synchronization Busy */ + uint32_t CTRLB:1; /*!< bit: 2 CTRLB Synchronization Busy */ + uint32_t :29; /*!< bit: 3..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_USART_SYNCBUSY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_SYNCBUSY_OFFSET 0x1C /**< \brief (SERCOM_USART_SYNCBUSY offset) USART Syncbusy */ +#define SERCOM_USART_SYNCBUSY_RESETVALUE 0x00000000 /**< \brief (SERCOM_USART_SYNCBUSY reset_value) USART Syncbusy */ + +#define SERCOM_USART_SYNCBUSY_SWRST_Pos 0 /**< \brief (SERCOM_USART_SYNCBUSY) Software Reset Synchronization Busy */ +#define SERCOM_USART_SYNCBUSY_SWRST (0x1u << SERCOM_USART_SYNCBUSY_SWRST_Pos) +#define SERCOM_USART_SYNCBUSY_ENABLE_Pos 1 /**< \brief (SERCOM_USART_SYNCBUSY) SERCOM Enable Synchronization Busy */ +#define SERCOM_USART_SYNCBUSY_ENABLE (0x1u << SERCOM_USART_SYNCBUSY_ENABLE_Pos) +#define SERCOM_USART_SYNCBUSY_CTRLB_Pos 2 /**< \brief (SERCOM_USART_SYNCBUSY) CTRLB Synchronization Busy */ +#define SERCOM_USART_SYNCBUSY_CTRLB (0x1u << SERCOM_USART_SYNCBUSY_CTRLB_Pos) +#define SERCOM_USART_SYNCBUSY_MASK 0x00000007u /**< \brief (SERCOM_USART_SYNCBUSY) MASK Register */ + +/* -------- SERCOM_I2CM_ADDR : (SERCOM Offset: 0x24) (R/W 32) I2CM I2CM Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t ADDR:11; /*!< bit: 0..10 Address Value */ + uint32_t :2; /*!< bit: 11..12 Reserved */ + uint32_t LENEN:1; /*!< bit: 13 Length Enable */ + uint32_t HS:1; /*!< bit: 14 High Speed Mode */ + uint32_t TENBITEN:1; /*!< bit: 15 Ten Bit Addressing Enable */ + uint32_t LEN:8; /*!< bit: 16..23 Length */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_ADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_ADDR_OFFSET 0x24 /**< \brief (SERCOM_I2CM_ADDR offset) I2CM Address */ +#define SERCOM_I2CM_ADDR_RESETVALUE 0x00000000 /**< \brief (SERCOM_I2CM_ADDR reset_value) I2CM Address */ + +#define SERCOM_I2CM_ADDR_ADDR_Pos 0 /**< \brief (SERCOM_I2CM_ADDR) Address Value */ +#define SERCOM_I2CM_ADDR_ADDR_Msk (0x7FFu << SERCOM_I2CM_ADDR_ADDR_Pos) +#define SERCOM_I2CM_ADDR_ADDR(value) ((SERCOM_I2CM_ADDR_ADDR_Msk & ((value) << SERCOM_I2CM_ADDR_ADDR_Pos))) +#define SERCOM_I2CM_ADDR_LENEN_Pos 13 /**< \brief (SERCOM_I2CM_ADDR) Length Enable */ +#define SERCOM_I2CM_ADDR_LENEN (0x1u << SERCOM_I2CM_ADDR_LENEN_Pos) +#define SERCOM_I2CM_ADDR_HS_Pos 14 /**< \brief (SERCOM_I2CM_ADDR) High Speed Mode */ +#define SERCOM_I2CM_ADDR_HS (0x1u << SERCOM_I2CM_ADDR_HS_Pos) +#define SERCOM_I2CM_ADDR_TENBITEN_Pos 15 /**< \brief (SERCOM_I2CM_ADDR) Ten Bit Addressing Enable */ +#define SERCOM_I2CM_ADDR_TENBITEN (0x1u << SERCOM_I2CM_ADDR_TENBITEN_Pos) +#define SERCOM_I2CM_ADDR_LEN_Pos 16 /**< \brief (SERCOM_I2CM_ADDR) Length */ +#define SERCOM_I2CM_ADDR_LEN_Msk (0xFFu << SERCOM_I2CM_ADDR_LEN_Pos) +#define SERCOM_I2CM_ADDR_LEN(value) ((SERCOM_I2CM_ADDR_LEN_Msk & ((value) << SERCOM_I2CM_ADDR_LEN_Pos))) +#define SERCOM_I2CM_ADDR_MASK 0x00FFE7FFu /**< \brief (SERCOM_I2CM_ADDR) MASK Register */ + +/* -------- SERCOM_I2CS_ADDR : (SERCOM Offset: 0x24) (R/W 32) I2CS I2CS Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t GENCEN:1; /*!< bit: 0 General Call Address Enable */ + uint32_t ADDR:10; /*!< bit: 1..10 Address Value */ + uint32_t :4; /*!< bit: 11..14 Reserved */ + uint32_t TENBITEN:1; /*!< bit: 15 Ten Bit Addressing Enable */ + uint32_t :1; /*!< bit: 16 Reserved */ + uint32_t ADDRMASK:10; /*!< bit: 17..26 Address Mask */ + uint32_t :5; /*!< bit: 27..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_I2CS_ADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CS_ADDR_OFFSET 0x24 /**< \brief (SERCOM_I2CS_ADDR offset) I2CS Address */ +#define SERCOM_I2CS_ADDR_RESETVALUE 0x00000000 /**< \brief (SERCOM_I2CS_ADDR reset_value) I2CS Address */ + +#define SERCOM_I2CS_ADDR_GENCEN_Pos 0 /**< \brief (SERCOM_I2CS_ADDR) General Call Address Enable */ +#define SERCOM_I2CS_ADDR_GENCEN (0x1u << SERCOM_I2CS_ADDR_GENCEN_Pos) +#define SERCOM_I2CS_ADDR_ADDR_Pos 1 /**< \brief (SERCOM_I2CS_ADDR) Address Value */ +#define SERCOM_I2CS_ADDR_ADDR_Msk (0x3FFu << SERCOM_I2CS_ADDR_ADDR_Pos) +#define SERCOM_I2CS_ADDR_ADDR(value) ((SERCOM_I2CS_ADDR_ADDR_Msk & ((value) << SERCOM_I2CS_ADDR_ADDR_Pos))) +#define SERCOM_I2CS_ADDR_TENBITEN_Pos 15 /**< \brief (SERCOM_I2CS_ADDR) Ten Bit Addressing Enable */ +#define SERCOM_I2CS_ADDR_TENBITEN (0x1u << SERCOM_I2CS_ADDR_TENBITEN_Pos) +#define SERCOM_I2CS_ADDR_ADDRMASK_Pos 17 /**< \brief (SERCOM_I2CS_ADDR) Address Mask */ +#define SERCOM_I2CS_ADDR_ADDRMASK_Msk (0x3FFu << SERCOM_I2CS_ADDR_ADDRMASK_Pos) +#define SERCOM_I2CS_ADDR_ADDRMASK(value) ((SERCOM_I2CS_ADDR_ADDRMASK_Msk & ((value) << SERCOM_I2CS_ADDR_ADDRMASK_Pos))) +#define SERCOM_I2CS_ADDR_MASK 0x07FE87FFu /**< \brief (SERCOM_I2CS_ADDR) MASK Register */ + +/* -------- SERCOM_SPI_ADDR : (SERCOM Offset: 0x24) (R/W 32) SPI SPI Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t ADDR:8; /*!< bit: 0.. 7 Address Value */ + uint32_t :8; /*!< bit: 8..15 Reserved */ + uint32_t ADDRMASK:8; /*!< bit: 16..23 Address Mask */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_SPI_ADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_ADDR_OFFSET 0x24 /**< \brief (SERCOM_SPI_ADDR offset) SPI Address */ +#define SERCOM_SPI_ADDR_RESETVALUE 0x00000000 /**< \brief (SERCOM_SPI_ADDR reset_value) SPI Address */ + +#define SERCOM_SPI_ADDR_ADDR_Pos 0 /**< \brief (SERCOM_SPI_ADDR) Address Value */ +#define SERCOM_SPI_ADDR_ADDR_Msk (0xFFu << SERCOM_SPI_ADDR_ADDR_Pos) +#define SERCOM_SPI_ADDR_ADDR(value) ((SERCOM_SPI_ADDR_ADDR_Msk & ((value) << SERCOM_SPI_ADDR_ADDR_Pos))) +#define SERCOM_SPI_ADDR_ADDRMASK_Pos 16 /**< \brief (SERCOM_SPI_ADDR) Address Mask */ +#define SERCOM_SPI_ADDR_ADDRMASK_Msk (0xFFu << SERCOM_SPI_ADDR_ADDRMASK_Pos) +#define SERCOM_SPI_ADDR_ADDRMASK(value) ((SERCOM_SPI_ADDR_ADDRMASK_Msk & ((value) << SERCOM_SPI_ADDR_ADDRMASK_Pos))) +#define SERCOM_SPI_ADDR_MASK 0x00FF00FFu /**< \brief (SERCOM_SPI_ADDR) MASK Register */ + +/* -------- SERCOM_I2CM_DATA : (SERCOM Offset: 0x28) (R/W 8) I2CM I2CM Data -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DATA:8; /*!< bit: 0.. 7 Data Value */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_DATA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_DATA_OFFSET 0x28 /**< \brief (SERCOM_I2CM_DATA offset) I2CM Data */ +#define SERCOM_I2CM_DATA_RESETVALUE 0x00 /**< \brief (SERCOM_I2CM_DATA reset_value) I2CM Data */ + +#define SERCOM_I2CM_DATA_DATA_Pos 0 /**< \brief (SERCOM_I2CM_DATA) Data Value */ +#define SERCOM_I2CM_DATA_DATA_Msk (0xFFu << SERCOM_I2CM_DATA_DATA_Pos) +#define SERCOM_I2CM_DATA_DATA(value) ((SERCOM_I2CM_DATA_DATA_Msk & ((value) << SERCOM_I2CM_DATA_DATA_Pos))) +#define SERCOM_I2CM_DATA_MASK 0xFFu /**< \brief (SERCOM_I2CM_DATA) MASK Register */ + +/* -------- SERCOM_I2CS_DATA : (SERCOM Offset: 0x28) (R/W 8) I2CS I2CS Data -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DATA:8; /*!< bit: 0.. 7 Data Value */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_I2CS_DATA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CS_DATA_OFFSET 0x28 /**< \brief (SERCOM_I2CS_DATA offset) I2CS Data */ +#define SERCOM_I2CS_DATA_RESETVALUE 0x00 /**< \brief (SERCOM_I2CS_DATA reset_value) I2CS Data */ + +#define SERCOM_I2CS_DATA_DATA_Pos 0 /**< \brief (SERCOM_I2CS_DATA) Data Value */ +#define SERCOM_I2CS_DATA_DATA_Msk (0xFFu << SERCOM_I2CS_DATA_DATA_Pos) +#define SERCOM_I2CS_DATA_DATA(value) ((SERCOM_I2CS_DATA_DATA_Msk & ((value) << SERCOM_I2CS_DATA_DATA_Pos))) +#define SERCOM_I2CS_DATA_MASK 0xFFu /**< \brief (SERCOM_I2CS_DATA) MASK Register */ + +/* -------- SERCOM_SPI_DATA : (SERCOM Offset: 0x28) (R/W 32) SPI SPI Data -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DATA:9; /*!< bit: 0.. 8 Data Value */ + uint32_t :23; /*!< bit: 9..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_SPI_DATA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_DATA_OFFSET 0x28 /**< \brief (SERCOM_SPI_DATA offset) SPI Data */ +#define SERCOM_SPI_DATA_RESETVALUE 0x00000000 /**< \brief (SERCOM_SPI_DATA reset_value) SPI Data */ + +#define SERCOM_SPI_DATA_DATA_Pos 0 /**< \brief (SERCOM_SPI_DATA) Data Value */ +#define SERCOM_SPI_DATA_DATA_Msk (0x1FFu << SERCOM_SPI_DATA_DATA_Pos) +#define SERCOM_SPI_DATA_DATA(value) ((SERCOM_SPI_DATA_DATA_Msk & ((value) << SERCOM_SPI_DATA_DATA_Pos))) +#define SERCOM_SPI_DATA_MASK 0x000001FFu /**< \brief (SERCOM_SPI_DATA) MASK Register */ + +/* -------- SERCOM_USART_DATA : (SERCOM Offset: 0x28) (R/W 16) USART USART Data -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t DATA:9; /*!< bit: 0.. 8 Data Value */ + uint16_t :7; /*!< bit: 9..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} SERCOM_USART_DATA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_DATA_OFFSET 0x28 /**< \brief (SERCOM_USART_DATA offset) USART Data */ +#define SERCOM_USART_DATA_RESETVALUE 0x0000 /**< \brief (SERCOM_USART_DATA reset_value) USART Data */ + +#define SERCOM_USART_DATA_DATA_Pos 0 /**< \brief (SERCOM_USART_DATA) Data Value */ +#define SERCOM_USART_DATA_DATA_Msk (0x1FFu << SERCOM_USART_DATA_DATA_Pos) +#define SERCOM_USART_DATA_DATA(value) ((SERCOM_USART_DATA_DATA_Msk & ((value) << SERCOM_USART_DATA_DATA_Pos))) +#define SERCOM_USART_DATA_MASK 0x01FFu /**< \brief (SERCOM_USART_DATA) MASK Register */ + +/* -------- SERCOM_I2CM_DBGCTRL : (SERCOM Offset: 0x30) (R/W 8) I2CM I2CM Debug Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DBGSTOP:1; /*!< bit: 0 Debug Mode */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_DBGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_DBGCTRL_OFFSET 0x30 /**< \brief (SERCOM_I2CM_DBGCTRL offset) I2CM Debug Control */ +#define SERCOM_I2CM_DBGCTRL_RESETVALUE 0x00 /**< \brief (SERCOM_I2CM_DBGCTRL reset_value) I2CM Debug Control */ + +#define SERCOM_I2CM_DBGCTRL_DBGSTOP_Pos 0 /**< \brief (SERCOM_I2CM_DBGCTRL) Debug Mode */ +#define SERCOM_I2CM_DBGCTRL_DBGSTOP (0x1u << SERCOM_I2CM_DBGCTRL_DBGSTOP_Pos) +#define SERCOM_I2CM_DBGCTRL_MASK 0x01u /**< \brief (SERCOM_I2CM_DBGCTRL) MASK Register */ + +/* -------- SERCOM_SPI_DBGCTRL : (SERCOM Offset: 0x30) (R/W 8) SPI SPI Debug Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DBGSTOP:1; /*!< bit: 0 Debug Mode */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_SPI_DBGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_DBGCTRL_OFFSET 0x30 /**< \brief (SERCOM_SPI_DBGCTRL offset) SPI Debug Control */ +#define SERCOM_SPI_DBGCTRL_RESETVALUE 0x00 /**< \brief (SERCOM_SPI_DBGCTRL reset_value) SPI Debug Control */ + +#define SERCOM_SPI_DBGCTRL_DBGSTOP_Pos 0 /**< \brief (SERCOM_SPI_DBGCTRL) Debug Mode */ +#define SERCOM_SPI_DBGCTRL_DBGSTOP (0x1u << SERCOM_SPI_DBGCTRL_DBGSTOP_Pos) +#define SERCOM_SPI_DBGCTRL_MASK 0x01u /**< \brief (SERCOM_SPI_DBGCTRL) MASK Register */ + +/* -------- SERCOM_USART_DBGCTRL : (SERCOM Offset: 0x30) (R/W 8) USART USART Debug Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DBGSTOP:1; /*!< bit: 0 Debug Mode */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_USART_DBGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_DBGCTRL_OFFSET 0x30 /**< \brief (SERCOM_USART_DBGCTRL offset) USART Debug Control */ +#define SERCOM_USART_DBGCTRL_RESETVALUE 0x00 /**< \brief (SERCOM_USART_DBGCTRL reset_value) USART Debug Control */ + +#define SERCOM_USART_DBGCTRL_DBGSTOP_Pos 0 /**< \brief (SERCOM_USART_DBGCTRL) Debug Mode */ +#define SERCOM_USART_DBGCTRL_DBGSTOP (0x1u << SERCOM_USART_DBGCTRL_DBGSTOP_Pos) +#define SERCOM_USART_DBGCTRL_MASK 0x01u /**< \brief (SERCOM_USART_DBGCTRL) MASK Register */ + +/** \brief SERCOM_I2CM hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* I2C Master Mode */ + __IO SERCOM_I2CM_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 32) I2CM Control A */ + __IO SERCOM_I2CM_CTRLB_Type CTRLB; /**< \brief Offset: 0x04 (R/W 32) I2CM Control B */ + RoReg8 Reserved1[0x4]; + __IO SERCOM_I2CM_BAUD_Type BAUD; /**< \brief Offset: 0x0C (R/W 32) I2CM Baud Rate */ + RoReg8 Reserved2[0x4]; + __IO SERCOM_I2CM_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x14 (R/W 8) I2CM Interrupt Enable Clear */ + RoReg8 Reserved3[0x1]; + __IO SERCOM_I2CM_INTENSET_Type INTENSET; /**< \brief Offset: 0x16 (R/W 8) I2CM Interrupt Enable Set */ + RoReg8 Reserved4[0x1]; + __IO SERCOM_I2CM_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x18 (R/W 8) I2CM Interrupt Flag Status and Clear */ + RoReg8 Reserved5[0x1]; + __IO SERCOM_I2CM_STATUS_Type STATUS; /**< \brief Offset: 0x1A (R/W 16) I2CM Status */ + __I SERCOM_I2CM_SYNCBUSY_Type SYNCBUSY; /**< \brief Offset: 0x1C (R/ 32) I2CM Syncbusy */ + RoReg8 Reserved6[0x4]; + __IO SERCOM_I2CM_ADDR_Type ADDR; /**< \brief Offset: 0x24 (R/W 32) I2CM Address */ + __IO SERCOM_I2CM_DATA_Type DATA; /**< \brief Offset: 0x28 (R/W 8) I2CM Data */ + RoReg8 Reserved7[0x7]; + __IO SERCOM_I2CM_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x30 (R/W 8) I2CM Debug Control */ +} SercomI2cm; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief SERCOM_I2CS hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* I2C Slave Mode */ + __IO SERCOM_I2CS_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 32) I2CS Control A */ + __IO SERCOM_I2CS_CTRLB_Type CTRLB; /**< \brief Offset: 0x04 (R/W 32) I2CS Control B */ + RoReg8 Reserved1[0xC]; + __IO SERCOM_I2CS_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x14 (R/W 8) I2CS Interrupt Enable Clear */ + RoReg8 Reserved2[0x1]; + __IO SERCOM_I2CS_INTENSET_Type INTENSET; /**< \brief Offset: 0x16 (R/W 8) I2CS Interrupt Enable Set */ + RoReg8 Reserved3[0x1]; + __IO SERCOM_I2CS_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x18 (R/W 8) I2CS Interrupt Flag Status and Clear */ + RoReg8 Reserved4[0x1]; + __IO SERCOM_I2CS_STATUS_Type STATUS; /**< \brief Offset: 0x1A (R/W 16) I2CS Status */ + __I SERCOM_I2CS_SYNCBUSY_Type SYNCBUSY; /**< \brief Offset: 0x1C (R/ 32) I2CS Syncbusy */ + RoReg8 Reserved5[0x4]; + __IO SERCOM_I2CS_ADDR_Type ADDR; /**< \brief Offset: 0x24 (R/W 32) I2CS Address */ + __IO SERCOM_I2CS_DATA_Type DATA; /**< \brief Offset: 0x28 (R/W 8) I2CS Data */ +} SercomI2cs; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief SERCOM_SPI hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* SPI Mode */ + __IO SERCOM_SPI_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 32) SPI Control A */ + __IO SERCOM_SPI_CTRLB_Type CTRLB; /**< \brief Offset: 0x04 (R/W 32) SPI Control B */ + RoReg8 Reserved1[0x4]; + __IO SERCOM_SPI_BAUD_Type BAUD; /**< \brief Offset: 0x0C (R/W 8) SPI Baud Rate */ + RoReg8 Reserved2[0x7]; + __IO SERCOM_SPI_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x14 (R/W 8) SPI Interrupt Enable Clear */ + RoReg8 Reserved3[0x1]; + __IO SERCOM_SPI_INTENSET_Type INTENSET; /**< \brief Offset: 0x16 (R/W 8) SPI Interrupt Enable Set */ + RoReg8 Reserved4[0x1]; + __IO SERCOM_SPI_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x18 (R/W 8) SPI Interrupt Flag Status and Clear */ + RoReg8 Reserved5[0x1]; + __IO SERCOM_SPI_STATUS_Type STATUS; /**< \brief Offset: 0x1A (R/W 16) SPI Status */ + __I SERCOM_SPI_SYNCBUSY_Type SYNCBUSY; /**< \brief Offset: 0x1C (R/ 32) SPI Syncbusy */ + RoReg8 Reserved6[0x4]; + __IO SERCOM_SPI_ADDR_Type ADDR; /**< \brief Offset: 0x24 (R/W 32) SPI Address */ + __IO SERCOM_SPI_DATA_Type DATA; /**< \brief Offset: 0x28 (R/W 32) SPI Data */ + RoReg8 Reserved7[0x4]; + __IO SERCOM_SPI_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x30 (R/W 8) SPI Debug Control */ +} SercomSpi; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief SERCOM_USART hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* USART Mode */ + __IO SERCOM_USART_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 32) USART Control A */ + __IO SERCOM_USART_CTRLB_Type CTRLB; /**< \brief Offset: 0x04 (R/W 32) USART Control B */ + RoReg8 Reserved1[0x4]; + __IO SERCOM_USART_BAUD_Type BAUD; /**< \brief Offset: 0x0C (R/W 16) USART Baud Rate */ + __IO SERCOM_USART_RXPL_Type RXPL; /**< \brief Offset: 0x0E (R/W 8) USART Receive Pulse Length */ + RoReg8 Reserved2[0x5]; + __IO SERCOM_USART_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x14 (R/W 8) USART Interrupt Enable Clear */ + RoReg8 Reserved3[0x1]; + __IO SERCOM_USART_INTENSET_Type INTENSET; /**< \brief Offset: 0x16 (R/W 8) USART Interrupt Enable Set */ + RoReg8 Reserved4[0x1]; + __IO SERCOM_USART_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x18 (R/W 8) USART Interrupt Flag Status and Clear */ + RoReg8 Reserved5[0x1]; + __IO SERCOM_USART_STATUS_Type STATUS; /**< \brief Offset: 0x1A (R/W 16) USART Status */ + __I SERCOM_USART_SYNCBUSY_Type SYNCBUSY; /**< \brief Offset: 0x1C (R/ 32) USART Syncbusy */ + RoReg8 Reserved6[0x8]; + __IO SERCOM_USART_DATA_Type DATA; /**< \brief Offset: 0x28 (R/W 16) USART Data */ + RoReg8 Reserved7[0x6]; + __IO SERCOM_USART_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x30 (R/W 8) USART Debug Control */ +} SercomUsart; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + SercomI2cm I2CM; /**< \brief Offset: 0x00 I2C Master Mode */ + SercomI2cs I2CS; /**< \brief Offset: 0x00 I2C Slave Mode */ + SercomSpi SPI; /**< \brief Offset: 0x00 SPI Mode */ + SercomUsart USART; /**< \brief Offset: 0x00 USART Mode */ +} Sercom; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_SERCOM_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/sysctrl.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/sysctrl.h new file mode 100644 index 0000000..4bd9241 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/sysctrl.h @@ -0,0 +1,948 @@ +/** + * \file + * + * \brief Component description for SYSCTRL + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_SYSCTRL_COMPONENT_ +#define _SAMD21_SYSCTRL_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR SYSCTRL */ +/* ========================================================================== */ +/** \addtogroup SAMD21_SYSCTRL System Control */ +/*@{*/ + +#define SYSCTRL_U2100 +#define REV_SYSCTRL 0x201 + +/* -------- SYSCTRL_INTENCLR : (SYSCTRL Offset: 0x00) (R/W 32) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t XOSCRDY:1; /*!< bit: 0 XOSC Ready Interrupt Enable */ + uint32_t XOSC32KRDY:1; /*!< bit: 1 XOSC32K Ready Interrupt Enable */ + uint32_t OSC32KRDY:1; /*!< bit: 2 OSC32K Ready Interrupt Enable */ + uint32_t OSC8MRDY:1; /*!< bit: 3 OSC8M Ready Interrupt Enable */ + uint32_t DFLLRDY:1; /*!< bit: 4 DFLL Ready Interrupt Enable */ + uint32_t DFLLOOB:1; /*!< bit: 5 DFLL Out Of Bounds Interrupt Enable */ + uint32_t DFLLLCKF:1; /*!< bit: 6 DFLL Lock Fine Interrupt Enable */ + uint32_t DFLLLCKC:1; /*!< bit: 7 DFLL Lock Coarse Interrupt Enable */ + uint32_t DFLLRCS:1; /*!< bit: 8 DFLL Reference Clock Stopped Interrupt Enable */ + uint32_t BOD33RDY:1; /*!< bit: 9 BOD33 Ready Interrupt Enable */ + uint32_t BOD33DET:1; /*!< bit: 10 BOD33 Detection Interrupt Enable */ + uint32_t B33SRDY:1; /*!< bit: 11 BOD33 Synchronization Ready Interrupt Enable */ + uint32_t :3; /*!< bit: 12..14 Reserved */ + uint32_t DPLLLCKR:1; /*!< bit: 15 DPLL Lock Rise Interrupt Enable */ + uint32_t DPLLLCKF:1; /*!< bit: 16 DPLL Lock Fall Interrupt Enable */ + uint32_t DPLLLTO:1; /*!< bit: 17 DPLL Lock Timeout Interrupt Enable */ + uint32_t :14; /*!< bit: 18..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_INTENCLR_OFFSET 0x00 /**< \brief (SYSCTRL_INTENCLR offset) Interrupt Enable Clear */ +#define SYSCTRL_INTENCLR_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_INTENCLR reset_value) Interrupt Enable Clear */ + +#define SYSCTRL_INTENCLR_XOSCRDY_Pos 0 /**< \brief (SYSCTRL_INTENCLR) XOSC Ready Interrupt Enable */ +#define SYSCTRL_INTENCLR_XOSCRDY (0x1u << SYSCTRL_INTENCLR_XOSCRDY_Pos) +#define SYSCTRL_INTENCLR_XOSC32KRDY_Pos 1 /**< \brief (SYSCTRL_INTENCLR) XOSC32K Ready Interrupt Enable */ +#define SYSCTRL_INTENCLR_XOSC32KRDY (0x1u << SYSCTRL_INTENCLR_XOSC32KRDY_Pos) +#define SYSCTRL_INTENCLR_OSC32KRDY_Pos 2 /**< \brief (SYSCTRL_INTENCLR) OSC32K Ready Interrupt Enable */ +#define SYSCTRL_INTENCLR_OSC32KRDY (0x1u << SYSCTRL_INTENCLR_OSC32KRDY_Pos) +#define SYSCTRL_INTENCLR_OSC8MRDY_Pos 3 /**< \brief (SYSCTRL_INTENCLR) OSC8M Ready Interrupt Enable */ +#define SYSCTRL_INTENCLR_OSC8MRDY (0x1u << SYSCTRL_INTENCLR_OSC8MRDY_Pos) +#define SYSCTRL_INTENCLR_DFLLRDY_Pos 4 /**< \brief (SYSCTRL_INTENCLR) DFLL Ready Interrupt Enable */ +#define SYSCTRL_INTENCLR_DFLLRDY (0x1u << SYSCTRL_INTENCLR_DFLLRDY_Pos) +#define SYSCTRL_INTENCLR_DFLLOOB_Pos 5 /**< \brief (SYSCTRL_INTENCLR) DFLL Out Of Bounds Interrupt Enable */ +#define SYSCTRL_INTENCLR_DFLLOOB (0x1u << SYSCTRL_INTENCLR_DFLLOOB_Pos) +#define SYSCTRL_INTENCLR_DFLLLCKF_Pos 6 /**< \brief (SYSCTRL_INTENCLR) DFLL Lock Fine Interrupt Enable */ +#define SYSCTRL_INTENCLR_DFLLLCKF (0x1u << SYSCTRL_INTENCLR_DFLLLCKF_Pos) +#define SYSCTRL_INTENCLR_DFLLLCKC_Pos 7 /**< \brief (SYSCTRL_INTENCLR) DFLL Lock Coarse Interrupt Enable */ +#define SYSCTRL_INTENCLR_DFLLLCKC (0x1u << SYSCTRL_INTENCLR_DFLLLCKC_Pos) +#define SYSCTRL_INTENCLR_DFLLRCS_Pos 8 /**< \brief (SYSCTRL_INTENCLR) DFLL Reference Clock Stopped Interrupt Enable */ +#define SYSCTRL_INTENCLR_DFLLRCS (0x1u << SYSCTRL_INTENCLR_DFLLRCS_Pos) +#define SYSCTRL_INTENCLR_BOD33RDY_Pos 9 /**< \brief (SYSCTRL_INTENCLR) BOD33 Ready Interrupt Enable */ +#define SYSCTRL_INTENCLR_BOD33RDY (0x1u << SYSCTRL_INTENCLR_BOD33RDY_Pos) +#define SYSCTRL_INTENCLR_BOD33DET_Pos 10 /**< \brief (SYSCTRL_INTENCLR) BOD33 Detection Interrupt Enable */ +#define SYSCTRL_INTENCLR_BOD33DET (0x1u << SYSCTRL_INTENCLR_BOD33DET_Pos) +#define SYSCTRL_INTENCLR_B33SRDY_Pos 11 /**< \brief (SYSCTRL_INTENCLR) BOD33 Synchronization Ready Interrupt Enable */ +#define SYSCTRL_INTENCLR_B33SRDY (0x1u << SYSCTRL_INTENCLR_B33SRDY_Pos) +#define SYSCTRL_INTENCLR_DPLLLCKR_Pos 15 /**< \brief (SYSCTRL_INTENCLR) DPLL Lock Rise Interrupt Enable */ +#define SYSCTRL_INTENCLR_DPLLLCKR (0x1u << SYSCTRL_INTENCLR_DPLLLCKR_Pos) +#define SYSCTRL_INTENCLR_DPLLLCKF_Pos 16 /**< \brief (SYSCTRL_INTENCLR) DPLL Lock Fall Interrupt Enable */ +#define SYSCTRL_INTENCLR_DPLLLCKF (0x1u << SYSCTRL_INTENCLR_DPLLLCKF_Pos) +#define SYSCTRL_INTENCLR_DPLLLTO_Pos 17 /**< \brief (SYSCTRL_INTENCLR) DPLL Lock Timeout Interrupt Enable */ +#define SYSCTRL_INTENCLR_DPLLLTO (0x1u << SYSCTRL_INTENCLR_DPLLLTO_Pos) +#define SYSCTRL_INTENCLR_MASK 0x00038FFFu /**< \brief (SYSCTRL_INTENCLR) MASK Register */ + +/* -------- SYSCTRL_INTENSET : (SYSCTRL Offset: 0x04) (R/W 32) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t XOSCRDY:1; /*!< bit: 0 XOSC Ready Interrupt Enable */ + uint32_t XOSC32KRDY:1; /*!< bit: 1 XOSC32K Ready Interrupt Enable */ + uint32_t OSC32KRDY:1; /*!< bit: 2 OSC32K Ready Interrupt Enable */ + uint32_t OSC8MRDY:1; /*!< bit: 3 OSC8M Ready Interrupt Enable */ + uint32_t DFLLRDY:1; /*!< bit: 4 DFLL Ready Interrupt Enable */ + uint32_t DFLLOOB:1; /*!< bit: 5 DFLL Out Of Bounds Interrupt Enable */ + uint32_t DFLLLCKF:1; /*!< bit: 6 DFLL Lock Fine Interrupt Enable */ + uint32_t DFLLLCKC:1; /*!< bit: 7 DFLL Lock Coarse Interrupt Enable */ + uint32_t DFLLRCS:1; /*!< bit: 8 DFLL Reference Clock Stopped Interrupt Enable */ + uint32_t BOD33RDY:1; /*!< bit: 9 BOD33 Ready Interrupt Enable */ + uint32_t BOD33DET:1; /*!< bit: 10 BOD33 Detection Interrupt Enable */ + uint32_t B33SRDY:1; /*!< bit: 11 BOD33 Synchronization Ready Interrupt Enable */ + uint32_t :3; /*!< bit: 12..14 Reserved */ + uint32_t DPLLLCKR:1; /*!< bit: 15 DPLL Lock Rise Interrupt Enable */ + uint32_t DPLLLCKF:1; /*!< bit: 16 DPLL Lock Fall Interrupt Enable */ + uint32_t DPLLLTO:1; /*!< bit: 17 DPLL Lock Timeout Interrupt Enable */ + uint32_t :14; /*!< bit: 18..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_INTENSET_OFFSET 0x04 /**< \brief (SYSCTRL_INTENSET offset) Interrupt Enable Set */ +#define SYSCTRL_INTENSET_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_INTENSET reset_value) Interrupt Enable Set */ + +#define SYSCTRL_INTENSET_XOSCRDY_Pos 0 /**< \brief (SYSCTRL_INTENSET) XOSC Ready Interrupt Enable */ +#define SYSCTRL_INTENSET_XOSCRDY (0x1u << SYSCTRL_INTENSET_XOSCRDY_Pos) +#define SYSCTRL_INTENSET_XOSC32KRDY_Pos 1 /**< \brief (SYSCTRL_INTENSET) XOSC32K Ready Interrupt Enable */ +#define SYSCTRL_INTENSET_XOSC32KRDY (0x1u << SYSCTRL_INTENSET_XOSC32KRDY_Pos) +#define SYSCTRL_INTENSET_OSC32KRDY_Pos 2 /**< \brief (SYSCTRL_INTENSET) OSC32K Ready Interrupt Enable */ +#define SYSCTRL_INTENSET_OSC32KRDY (0x1u << SYSCTRL_INTENSET_OSC32KRDY_Pos) +#define SYSCTRL_INTENSET_OSC8MRDY_Pos 3 /**< \brief (SYSCTRL_INTENSET) OSC8M Ready Interrupt Enable */ +#define SYSCTRL_INTENSET_OSC8MRDY (0x1u << SYSCTRL_INTENSET_OSC8MRDY_Pos) +#define SYSCTRL_INTENSET_DFLLRDY_Pos 4 /**< \brief (SYSCTRL_INTENSET) DFLL Ready Interrupt Enable */ +#define SYSCTRL_INTENSET_DFLLRDY (0x1u << SYSCTRL_INTENSET_DFLLRDY_Pos) +#define SYSCTRL_INTENSET_DFLLOOB_Pos 5 /**< \brief (SYSCTRL_INTENSET) DFLL Out Of Bounds Interrupt Enable */ +#define SYSCTRL_INTENSET_DFLLOOB (0x1u << SYSCTRL_INTENSET_DFLLOOB_Pos) +#define SYSCTRL_INTENSET_DFLLLCKF_Pos 6 /**< \brief (SYSCTRL_INTENSET) DFLL Lock Fine Interrupt Enable */ +#define SYSCTRL_INTENSET_DFLLLCKF (0x1u << SYSCTRL_INTENSET_DFLLLCKF_Pos) +#define SYSCTRL_INTENSET_DFLLLCKC_Pos 7 /**< \brief (SYSCTRL_INTENSET) DFLL Lock Coarse Interrupt Enable */ +#define SYSCTRL_INTENSET_DFLLLCKC (0x1u << SYSCTRL_INTENSET_DFLLLCKC_Pos) +#define SYSCTRL_INTENSET_DFLLRCS_Pos 8 /**< \brief (SYSCTRL_INTENSET) DFLL Reference Clock Stopped Interrupt Enable */ +#define SYSCTRL_INTENSET_DFLLRCS (0x1u << SYSCTRL_INTENSET_DFLLRCS_Pos) +#define SYSCTRL_INTENSET_BOD33RDY_Pos 9 /**< \brief (SYSCTRL_INTENSET) BOD33 Ready Interrupt Enable */ +#define SYSCTRL_INTENSET_BOD33RDY (0x1u << SYSCTRL_INTENSET_BOD33RDY_Pos) +#define SYSCTRL_INTENSET_BOD33DET_Pos 10 /**< \brief (SYSCTRL_INTENSET) BOD33 Detection Interrupt Enable */ +#define SYSCTRL_INTENSET_BOD33DET (0x1u << SYSCTRL_INTENSET_BOD33DET_Pos) +#define SYSCTRL_INTENSET_B33SRDY_Pos 11 /**< \brief (SYSCTRL_INTENSET) BOD33 Synchronization Ready Interrupt Enable */ +#define SYSCTRL_INTENSET_B33SRDY (0x1u << SYSCTRL_INTENSET_B33SRDY_Pos) +#define SYSCTRL_INTENSET_DPLLLCKR_Pos 15 /**< \brief (SYSCTRL_INTENSET) DPLL Lock Rise Interrupt Enable */ +#define SYSCTRL_INTENSET_DPLLLCKR (0x1u << SYSCTRL_INTENSET_DPLLLCKR_Pos) +#define SYSCTRL_INTENSET_DPLLLCKF_Pos 16 /**< \brief (SYSCTRL_INTENSET) DPLL Lock Fall Interrupt Enable */ +#define SYSCTRL_INTENSET_DPLLLCKF (0x1u << SYSCTRL_INTENSET_DPLLLCKF_Pos) +#define SYSCTRL_INTENSET_DPLLLTO_Pos 17 /**< \brief (SYSCTRL_INTENSET) DPLL Lock Timeout Interrupt Enable */ +#define SYSCTRL_INTENSET_DPLLLTO (0x1u << SYSCTRL_INTENSET_DPLLLTO_Pos) +#define SYSCTRL_INTENSET_MASK 0x00038FFFu /**< \brief (SYSCTRL_INTENSET) MASK Register */ + +/* -------- SYSCTRL_INTFLAG : (SYSCTRL Offset: 0x08) (R/W 32) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t XOSCRDY:1; /*!< bit: 0 XOSC Ready */ + uint32_t XOSC32KRDY:1; /*!< bit: 1 XOSC32K Ready */ + uint32_t OSC32KRDY:1; /*!< bit: 2 OSC32K Ready */ + uint32_t OSC8MRDY:1; /*!< bit: 3 OSC8M Ready */ + uint32_t DFLLRDY:1; /*!< bit: 4 DFLL Ready */ + uint32_t DFLLOOB:1; /*!< bit: 5 DFLL Out Of Bounds */ + uint32_t DFLLLCKF:1; /*!< bit: 6 DFLL Lock Fine */ + uint32_t DFLLLCKC:1; /*!< bit: 7 DFLL Lock Coarse */ + uint32_t DFLLRCS:1; /*!< bit: 8 DFLL Reference Clock Stopped */ + uint32_t BOD33RDY:1; /*!< bit: 9 BOD33 Ready */ + uint32_t BOD33DET:1; /*!< bit: 10 BOD33 Detection */ + uint32_t B33SRDY:1; /*!< bit: 11 BOD33 Synchronization Ready */ + uint32_t :3; /*!< bit: 12..14 Reserved */ + uint32_t DPLLLCKR:1; /*!< bit: 15 DPLL Lock Rise */ + uint32_t DPLLLCKF:1; /*!< bit: 16 DPLL Lock Fall */ + uint32_t DPLLLTO:1; /*!< bit: 17 DPLL Lock Timeout */ + uint32_t :14; /*!< bit: 18..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_INTFLAG_OFFSET 0x08 /**< \brief (SYSCTRL_INTFLAG offset) Interrupt Flag Status and Clear */ +#define SYSCTRL_INTFLAG_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define SYSCTRL_INTFLAG_XOSCRDY_Pos 0 /**< \brief (SYSCTRL_INTFLAG) XOSC Ready */ +#define SYSCTRL_INTFLAG_XOSCRDY (0x1u << SYSCTRL_INTFLAG_XOSCRDY_Pos) +#define SYSCTRL_INTFLAG_XOSC32KRDY_Pos 1 /**< \brief (SYSCTRL_INTFLAG) XOSC32K Ready */ +#define SYSCTRL_INTFLAG_XOSC32KRDY (0x1u << SYSCTRL_INTFLAG_XOSC32KRDY_Pos) +#define SYSCTRL_INTFLAG_OSC32KRDY_Pos 2 /**< \brief (SYSCTRL_INTFLAG) OSC32K Ready */ +#define SYSCTRL_INTFLAG_OSC32KRDY (0x1u << SYSCTRL_INTFLAG_OSC32KRDY_Pos) +#define SYSCTRL_INTFLAG_OSC8MRDY_Pos 3 /**< \brief (SYSCTRL_INTFLAG) OSC8M Ready */ +#define SYSCTRL_INTFLAG_OSC8MRDY (0x1u << SYSCTRL_INTFLAG_OSC8MRDY_Pos) +#define SYSCTRL_INTFLAG_DFLLRDY_Pos 4 /**< \brief (SYSCTRL_INTFLAG) DFLL Ready */ +#define SYSCTRL_INTFLAG_DFLLRDY (0x1u << SYSCTRL_INTFLAG_DFLLRDY_Pos) +#define SYSCTRL_INTFLAG_DFLLOOB_Pos 5 /**< \brief (SYSCTRL_INTFLAG) DFLL Out Of Bounds */ +#define SYSCTRL_INTFLAG_DFLLOOB (0x1u << SYSCTRL_INTFLAG_DFLLOOB_Pos) +#define SYSCTRL_INTFLAG_DFLLLCKF_Pos 6 /**< \brief (SYSCTRL_INTFLAG) DFLL Lock Fine */ +#define SYSCTRL_INTFLAG_DFLLLCKF (0x1u << SYSCTRL_INTFLAG_DFLLLCKF_Pos) +#define SYSCTRL_INTFLAG_DFLLLCKC_Pos 7 /**< \brief (SYSCTRL_INTFLAG) DFLL Lock Coarse */ +#define SYSCTRL_INTFLAG_DFLLLCKC (0x1u << SYSCTRL_INTFLAG_DFLLLCKC_Pos) +#define SYSCTRL_INTFLAG_DFLLRCS_Pos 8 /**< \brief (SYSCTRL_INTFLAG) DFLL Reference Clock Stopped */ +#define SYSCTRL_INTFLAG_DFLLRCS (0x1u << SYSCTRL_INTFLAG_DFLLRCS_Pos) +#define SYSCTRL_INTFLAG_BOD33RDY_Pos 9 /**< \brief (SYSCTRL_INTFLAG) BOD33 Ready */ +#define SYSCTRL_INTFLAG_BOD33RDY (0x1u << SYSCTRL_INTFLAG_BOD33RDY_Pos) +#define SYSCTRL_INTFLAG_BOD33DET_Pos 10 /**< \brief (SYSCTRL_INTFLAG) BOD33 Detection */ +#define SYSCTRL_INTFLAG_BOD33DET (0x1u << SYSCTRL_INTFLAG_BOD33DET_Pos) +#define SYSCTRL_INTFLAG_B33SRDY_Pos 11 /**< \brief (SYSCTRL_INTFLAG) BOD33 Synchronization Ready */ +#define SYSCTRL_INTFLAG_B33SRDY (0x1u << SYSCTRL_INTFLAG_B33SRDY_Pos) +#define SYSCTRL_INTFLAG_DPLLLCKR_Pos 15 /**< \brief (SYSCTRL_INTFLAG) DPLL Lock Rise */ +#define SYSCTRL_INTFLAG_DPLLLCKR (0x1u << SYSCTRL_INTFLAG_DPLLLCKR_Pos) +#define SYSCTRL_INTFLAG_DPLLLCKF_Pos 16 /**< \brief (SYSCTRL_INTFLAG) DPLL Lock Fall */ +#define SYSCTRL_INTFLAG_DPLLLCKF (0x1u << SYSCTRL_INTFLAG_DPLLLCKF_Pos) +#define SYSCTRL_INTFLAG_DPLLLTO_Pos 17 /**< \brief (SYSCTRL_INTFLAG) DPLL Lock Timeout */ +#define SYSCTRL_INTFLAG_DPLLLTO (0x1u << SYSCTRL_INTFLAG_DPLLLTO_Pos) +#define SYSCTRL_INTFLAG_MASK 0x00038FFFu /**< \brief (SYSCTRL_INTFLAG) MASK Register */ + +/* -------- SYSCTRL_PCLKSR : (SYSCTRL Offset: 0x0C) (R/ 32) Power and Clocks Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t XOSCRDY:1; /*!< bit: 0 XOSC Ready */ + uint32_t XOSC32KRDY:1; /*!< bit: 1 XOSC32K Ready */ + uint32_t OSC32KRDY:1; /*!< bit: 2 OSC32K Ready */ + uint32_t OSC8MRDY:1; /*!< bit: 3 OSC8M Ready */ + uint32_t DFLLRDY:1; /*!< bit: 4 DFLL Ready */ + uint32_t DFLLOOB:1; /*!< bit: 5 DFLL Out Of Bounds */ + uint32_t DFLLLCKF:1; /*!< bit: 6 DFLL Lock Fine */ + uint32_t DFLLLCKC:1; /*!< bit: 7 DFLL Lock Coarse */ + uint32_t DFLLRCS:1; /*!< bit: 8 DFLL Reference Clock Stopped */ + uint32_t BOD33RDY:1; /*!< bit: 9 BOD33 Ready */ + uint32_t BOD33DET:1; /*!< bit: 10 BOD33 Detection */ + uint32_t B33SRDY:1; /*!< bit: 11 BOD33 Synchronization Ready */ + uint32_t :3; /*!< bit: 12..14 Reserved */ + uint32_t DPLLLCKR:1; /*!< bit: 15 DPLL Lock Rise */ + uint32_t DPLLLCKF:1; /*!< bit: 16 DPLL Lock Fall */ + uint32_t DPLLLTO:1; /*!< bit: 17 DPLL Lock Timeout */ + uint32_t :14; /*!< bit: 18..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_PCLKSR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_PCLKSR_OFFSET 0x0C /**< \brief (SYSCTRL_PCLKSR offset) Power and Clocks Status */ +#define SYSCTRL_PCLKSR_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_PCLKSR reset_value) Power and Clocks Status */ + +#define SYSCTRL_PCLKSR_XOSCRDY_Pos 0 /**< \brief (SYSCTRL_PCLKSR) XOSC Ready */ +#define SYSCTRL_PCLKSR_XOSCRDY (0x1u << SYSCTRL_PCLKSR_XOSCRDY_Pos) +#define SYSCTRL_PCLKSR_XOSC32KRDY_Pos 1 /**< \brief (SYSCTRL_PCLKSR) XOSC32K Ready */ +#define SYSCTRL_PCLKSR_XOSC32KRDY (0x1u << SYSCTRL_PCLKSR_XOSC32KRDY_Pos) +#define SYSCTRL_PCLKSR_OSC32KRDY_Pos 2 /**< \brief (SYSCTRL_PCLKSR) OSC32K Ready */ +#define SYSCTRL_PCLKSR_OSC32KRDY (0x1u << SYSCTRL_PCLKSR_OSC32KRDY_Pos) +#define SYSCTRL_PCLKSR_OSC8MRDY_Pos 3 /**< \brief (SYSCTRL_PCLKSR) OSC8M Ready */ +#define SYSCTRL_PCLKSR_OSC8MRDY (0x1u << SYSCTRL_PCLKSR_OSC8MRDY_Pos) +#define SYSCTRL_PCLKSR_DFLLRDY_Pos 4 /**< \brief (SYSCTRL_PCLKSR) DFLL Ready */ +#define SYSCTRL_PCLKSR_DFLLRDY (0x1u << SYSCTRL_PCLKSR_DFLLRDY_Pos) +#define SYSCTRL_PCLKSR_DFLLOOB_Pos 5 /**< \brief (SYSCTRL_PCLKSR) DFLL Out Of Bounds */ +#define SYSCTRL_PCLKSR_DFLLOOB (0x1u << SYSCTRL_PCLKSR_DFLLOOB_Pos) +#define SYSCTRL_PCLKSR_DFLLLCKF_Pos 6 /**< \brief (SYSCTRL_PCLKSR) DFLL Lock Fine */ +#define SYSCTRL_PCLKSR_DFLLLCKF (0x1u << SYSCTRL_PCLKSR_DFLLLCKF_Pos) +#define SYSCTRL_PCLKSR_DFLLLCKC_Pos 7 /**< \brief (SYSCTRL_PCLKSR) DFLL Lock Coarse */ +#define SYSCTRL_PCLKSR_DFLLLCKC (0x1u << SYSCTRL_PCLKSR_DFLLLCKC_Pos) +#define SYSCTRL_PCLKSR_DFLLRCS_Pos 8 /**< \brief (SYSCTRL_PCLKSR) DFLL Reference Clock Stopped */ +#define SYSCTRL_PCLKSR_DFLLRCS (0x1u << SYSCTRL_PCLKSR_DFLLRCS_Pos) +#define SYSCTRL_PCLKSR_BOD33RDY_Pos 9 /**< \brief (SYSCTRL_PCLKSR) BOD33 Ready */ +#define SYSCTRL_PCLKSR_BOD33RDY (0x1u << SYSCTRL_PCLKSR_BOD33RDY_Pos) +#define SYSCTRL_PCLKSR_BOD33DET_Pos 10 /**< \brief (SYSCTRL_PCLKSR) BOD33 Detection */ +#define SYSCTRL_PCLKSR_BOD33DET (0x1u << SYSCTRL_PCLKSR_BOD33DET_Pos) +#define SYSCTRL_PCLKSR_B33SRDY_Pos 11 /**< \brief (SYSCTRL_PCLKSR) BOD33 Synchronization Ready */ +#define SYSCTRL_PCLKSR_B33SRDY (0x1u << SYSCTRL_PCLKSR_B33SRDY_Pos) +#define SYSCTRL_PCLKSR_DPLLLCKR_Pos 15 /**< \brief (SYSCTRL_PCLKSR) DPLL Lock Rise */ +#define SYSCTRL_PCLKSR_DPLLLCKR (0x1u << SYSCTRL_PCLKSR_DPLLLCKR_Pos) +#define SYSCTRL_PCLKSR_DPLLLCKF_Pos 16 /**< \brief (SYSCTRL_PCLKSR) DPLL Lock Fall */ +#define SYSCTRL_PCLKSR_DPLLLCKF (0x1u << SYSCTRL_PCLKSR_DPLLLCKF_Pos) +#define SYSCTRL_PCLKSR_DPLLLTO_Pos 17 /**< \brief (SYSCTRL_PCLKSR) DPLL Lock Timeout */ +#define SYSCTRL_PCLKSR_DPLLLTO (0x1u << SYSCTRL_PCLKSR_DPLLLTO_Pos) +#define SYSCTRL_PCLKSR_MASK 0x00038FFFu /**< \brief (SYSCTRL_PCLKSR) MASK Register */ + +/* -------- SYSCTRL_XOSC : (SYSCTRL Offset: 0x10) (R/W 16) External Multipurpose Crystal Oscillator (XOSC) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t :1; /*!< bit: 0 Reserved */ + uint16_t ENABLE:1; /*!< bit: 1 Oscillator Enable */ + uint16_t XTALEN:1; /*!< bit: 2 Crystal Oscillator Enable */ + uint16_t :3; /*!< bit: 3.. 5 Reserved */ + uint16_t RUNSTDBY:1; /*!< bit: 6 Run in Standby */ + uint16_t ONDEMAND:1; /*!< bit: 7 On Demand Control */ + uint16_t GAIN:3; /*!< bit: 8..10 Oscillator Gain */ + uint16_t AMPGC:1; /*!< bit: 11 Automatic Amplitude Gain Control */ + uint16_t STARTUP:4; /*!< bit: 12..15 Start-Up Time */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} SYSCTRL_XOSC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_XOSC_OFFSET 0x10 /**< \brief (SYSCTRL_XOSC offset) External Multipurpose Crystal Oscillator (XOSC) Control */ +#define SYSCTRL_XOSC_RESETVALUE 0x0080 /**< \brief (SYSCTRL_XOSC reset_value) External Multipurpose Crystal Oscillator (XOSC) Control */ + +#define SYSCTRL_XOSC_ENABLE_Pos 1 /**< \brief (SYSCTRL_XOSC) Oscillator Enable */ +#define SYSCTRL_XOSC_ENABLE (0x1u << SYSCTRL_XOSC_ENABLE_Pos) +#define SYSCTRL_XOSC_XTALEN_Pos 2 /**< \brief (SYSCTRL_XOSC) Crystal Oscillator Enable */ +#define SYSCTRL_XOSC_XTALEN (0x1u << SYSCTRL_XOSC_XTALEN_Pos) +#define SYSCTRL_XOSC_RUNSTDBY_Pos 6 /**< \brief (SYSCTRL_XOSC) Run in Standby */ +#define SYSCTRL_XOSC_RUNSTDBY (0x1u << SYSCTRL_XOSC_RUNSTDBY_Pos) +#define SYSCTRL_XOSC_ONDEMAND_Pos 7 /**< \brief (SYSCTRL_XOSC) On Demand Control */ +#define SYSCTRL_XOSC_ONDEMAND (0x1u << SYSCTRL_XOSC_ONDEMAND_Pos) +#define SYSCTRL_XOSC_GAIN_Pos 8 /**< \brief (SYSCTRL_XOSC) Oscillator Gain */ +#define SYSCTRL_XOSC_GAIN_Msk (0x7u << SYSCTRL_XOSC_GAIN_Pos) +#define SYSCTRL_XOSC_GAIN(value) ((SYSCTRL_XOSC_GAIN_Msk & ((value) << SYSCTRL_XOSC_GAIN_Pos))) +#define SYSCTRL_XOSC_GAIN_0_Val 0x0u /**< \brief (SYSCTRL_XOSC) 2MHz */ +#define SYSCTRL_XOSC_GAIN_1_Val 0x1u /**< \brief (SYSCTRL_XOSC) 4MHz */ +#define SYSCTRL_XOSC_GAIN_2_Val 0x2u /**< \brief (SYSCTRL_XOSC) 8MHz */ +#define SYSCTRL_XOSC_GAIN_3_Val 0x3u /**< \brief (SYSCTRL_XOSC) 16MHz */ +#define SYSCTRL_XOSC_GAIN_4_Val 0x4u /**< \brief (SYSCTRL_XOSC) 30MHz */ +#define SYSCTRL_XOSC_GAIN_0 (SYSCTRL_XOSC_GAIN_0_Val << SYSCTRL_XOSC_GAIN_Pos) +#define SYSCTRL_XOSC_GAIN_1 (SYSCTRL_XOSC_GAIN_1_Val << SYSCTRL_XOSC_GAIN_Pos) +#define SYSCTRL_XOSC_GAIN_2 (SYSCTRL_XOSC_GAIN_2_Val << SYSCTRL_XOSC_GAIN_Pos) +#define SYSCTRL_XOSC_GAIN_3 (SYSCTRL_XOSC_GAIN_3_Val << SYSCTRL_XOSC_GAIN_Pos) +#define SYSCTRL_XOSC_GAIN_4 (SYSCTRL_XOSC_GAIN_4_Val << SYSCTRL_XOSC_GAIN_Pos) +#define SYSCTRL_XOSC_AMPGC_Pos 11 /**< \brief (SYSCTRL_XOSC) Automatic Amplitude Gain Control */ +#define SYSCTRL_XOSC_AMPGC (0x1u << SYSCTRL_XOSC_AMPGC_Pos) +#define SYSCTRL_XOSC_STARTUP_Pos 12 /**< \brief (SYSCTRL_XOSC) Start-Up Time */ +#define SYSCTRL_XOSC_STARTUP_Msk (0xFu << SYSCTRL_XOSC_STARTUP_Pos) +#define SYSCTRL_XOSC_STARTUP(value) ((SYSCTRL_XOSC_STARTUP_Msk & ((value) << SYSCTRL_XOSC_STARTUP_Pos))) +#define SYSCTRL_XOSC_MASK 0xFFC6u /**< \brief (SYSCTRL_XOSC) MASK Register */ + +/* -------- SYSCTRL_XOSC32K : (SYSCTRL Offset: 0x14) (R/W 16) 32kHz External Crystal Oscillator (XOSC32K) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t :1; /*!< bit: 0 Reserved */ + uint16_t ENABLE:1; /*!< bit: 1 Oscillator Enable */ + uint16_t XTALEN:1; /*!< bit: 2 Crystal Oscillator Enable */ + uint16_t EN32K:1; /*!< bit: 3 32kHz Output Enable */ + uint16_t EN1K:1; /*!< bit: 4 1kHz Output Enable */ + uint16_t AAMPEN:1; /*!< bit: 5 Automatic Amplitude Control Enable */ + uint16_t RUNSTDBY:1; /*!< bit: 6 Run in Standby */ + uint16_t ONDEMAND:1; /*!< bit: 7 On Demand Control */ + uint16_t STARTUP:3; /*!< bit: 8..10 Oscillator Start-Up Time */ + uint16_t :1; /*!< bit: 11 Reserved */ + uint16_t WRTLOCK:1; /*!< bit: 12 Write Lock */ + uint16_t :3; /*!< bit: 13..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} SYSCTRL_XOSC32K_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_XOSC32K_OFFSET 0x14 /**< \brief (SYSCTRL_XOSC32K offset) 32kHz External Crystal Oscillator (XOSC32K) Control */ +#define SYSCTRL_XOSC32K_RESETVALUE 0x0080 /**< \brief (SYSCTRL_XOSC32K reset_value) 32kHz External Crystal Oscillator (XOSC32K) Control */ + +#define SYSCTRL_XOSC32K_ENABLE_Pos 1 /**< \brief (SYSCTRL_XOSC32K) Oscillator Enable */ +#define SYSCTRL_XOSC32K_ENABLE (0x1u << SYSCTRL_XOSC32K_ENABLE_Pos) +#define SYSCTRL_XOSC32K_XTALEN_Pos 2 /**< \brief (SYSCTRL_XOSC32K) Crystal Oscillator Enable */ +#define SYSCTRL_XOSC32K_XTALEN (0x1u << SYSCTRL_XOSC32K_XTALEN_Pos) +#define SYSCTRL_XOSC32K_EN32K_Pos 3 /**< \brief (SYSCTRL_XOSC32K) 32kHz Output Enable */ +#define SYSCTRL_XOSC32K_EN32K (0x1u << SYSCTRL_XOSC32K_EN32K_Pos) +#define SYSCTRL_XOSC32K_EN1K_Pos 4 /**< \brief (SYSCTRL_XOSC32K) 1kHz Output Enable */ +#define SYSCTRL_XOSC32K_EN1K (0x1u << SYSCTRL_XOSC32K_EN1K_Pos) +#define SYSCTRL_XOSC32K_AAMPEN_Pos 5 /**< \brief (SYSCTRL_XOSC32K) Automatic Amplitude Control Enable */ +#define SYSCTRL_XOSC32K_AAMPEN (0x1u << SYSCTRL_XOSC32K_AAMPEN_Pos) +#define SYSCTRL_XOSC32K_RUNSTDBY_Pos 6 /**< \brief (SYSCTRL_XOSC32K) Run in Standby */ +#define SYSCTRL_XOSC32K_RUNSTDBY (0x1u << SYSCTRL_XOSC32K_RUNSTDBY_Pos) +#define SYSCTRL_XOSC32K_ONDEMAND_Pos 7 /**< \brief (SYSCTRL_XOSC32K) On Demand Control */ +#define SYSCTRL_XOSC32K_ONDEMAND (0x1u << SYSCTRL_XOSC32K_ONDEMAND_Pos) +#define SYSCTRL_XOSC32K_STARTUP_Pos 8 /**< \brief (SYSCTRL_XOSC32K) Oscillator Start-Up Time */ +#define SYSCTRL_XOSC32K_STARTUP_Msk (0x7u << SYSCTRL_XOSC32K_STARTUP_Pos) +#define SYSCTRL_XOSC32K_STARTUP(value) ((SYSCTRL_XOSC32K_STARTUP_Msk & ((value) << SYSCTRL_XOSC32K_STARTUP_Pos))) +#define SYSCTRL_XOSC32K_WRTLOCK_Pos 12 /**< \brief (SYSCTRL_XOSC32K) Write Lock */ +#define SYSCTRL_XOSC32K_WRTLOCK (0x1u << SYSCTRL_XOSC32K_WRTLOCK_Pos) +#define SYSCTRL_XOSC32K_MASK 0x17FEu /**< \brief (SYSCTRL_XOSC32K) MASK Register */ + +/* -------- SYSCTRL_OSC32K : (SYSCTRL Offset: 0x18) (R/W 32) 32kHz Internal Oscillator (OSC32K) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :1; /*!< bit: 0 Reserved */ + uint32_t ENABLE:1; /*!< bit: 1 Oscillator Enable */ + uint32_t EN32K:1; /*!< bit: 2 32kHz Output Enable */ + uint32_t EN1K:1; /*!< bit: 3 1kHz Output Enable */ + uint32_t :2; /*!< bit: 4.. 5 Reserved */ + uint32_t RUNSTDBY:1; /*!< bit: 6 Run in Standby */ + uint32_t ONDEMAND:1; /*!< bit: 7 On Demand Control */ + uint32_t STARTUP:3; /*!< bit: 8..10 Oscillator Start-Up Time */ + uint32_t :1; /*!< bit: 11 Reserved */ + uint32_t WRTLOCK:1; /*!< bit: 12 Write Lock */ + uint32_t :3; /*!< bit: 13..15 Reserved */ + uint32_t CALIB:7; /*!< bit: 16..22 Oscillator Calibration */ + uint32_t :9; /*!< bit: 23..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_OSC32K_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_OSC32K_OFFSET 0x18 /**< \brief (SYSCTRL_OSC32K offset) 32kHz Internal Oscillator (OSC32K) Control */ +#define SYSCTRL_OSC32K_RESETVALUE 0x003F0080 /**< \brief (SYSCTRL_OSC32K reset_value) 32kHz Internal Oscillator (OSC32K) Control */ + +#define SYSCTRL_OSC32K_ENABLE_Pos 1 /**< \brief (SYSCTRL_OSC32K) Oscillator Enable */ +#define SYSCTRL_OSC32K_ENABLE (0x1u << SYSCTRL_OSC32K_ENABLE_Pos) +#define SYSCTRL_OSC32K_EN32K_Pos 2 /**< \brief (SYSCTRL_OSC32K) 32kHz Output Enable */ +#define SYSCTRL_OSC32K_EN32K (0x1u << SYSCTRL_OSC32K_EN32K_Pos) +#define SYSCTRL_OSC32K_EN1K_Pos 3 /**< \brief (SYSCTRL_OSC32K) 1kHz Output Enable */ +#define SYSCTRL_OSC32K_EN1K (0x1u << SYSCTRL_OSC32K_EN1K_Pos) +#define SYSCTRL_OSC32K_RUNSTDBY_Pos 6 /**< \brief (SYSCTRL_OSC32K) Run in Standby */ +#define SYSCTRL_OSC32K_RUNSTDBY (0x1u << SYSCTRL_OSC32K_RUNSTDBY_Pos) +#define SYSCTRL_OSC32K_ONDEMAND_Pos 7 /**< \brief (SYSCTRL_OSC32K) On Demand Control */ +#define SYSCTRL_OSC32K_ONDEMAND (0x1u << SYSCTRL_OSC32K_ONDEMAND_Pos) +#define SYSCTRL_OSC32K_STARTUP_Pos 8 /**< \brief (SYSCTRL_OSC32K) Oscillator Start-Up Time */ +#define SYSCTRL_OSC32K_STARTUP_Msk (0x7u << SYSCTRL_OSC32K_STARTUP_Pos) +#define SYSCTRL_OSC32K_STARTUP(value) ((SYSCTRL_OSC32K_STARTUP_Msk & ((value) << SYSCTRL_OSC32K_STARTUP_Pos))) +#define SYSCTRL_OSC32K_WRTLOCK_Pos 12 /**< \brief (SYSCTRL_OSC32K) Write Lock */ +#define SYSCTRL_OSC32K_WRTLOCK (0x1u << SYSCTRL_OSC32K_WRTLOCK_Pos) +#define SYSCTRL_OSC32K_CALIB_Pos 16 /**< \brief (SYSCTRL_OSC32K) Oscillator Calibration */ +#define SYSCTRL_OSC32K_CALIB_Msk (0x7Fu << SYSCTRL_OSC32K_CALIB_Pos) +#define SYSCTRL_OSC32K_CALIB(value) ((SYSCTRL_OSC32K_CALIB_Msk & ((value) << SYSCTRL_OSC32K_CALIB_Pos))) +#define SYSCTRL_OSC32K_MASK 0x007F17CEu /**< \brief (SYSCTRL_OSC32K) MASK Register */ + +/* -------- SYSCTRL_OSCULP32K : (SYSCTRL Offset: 0x1C) (R/W 8) 32kHz Ultra Low Power Internal Oscillator (OSCULP32K) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CALIB:5; /*!< bit: 0.. 4 Oscillator Calibration */ + uint8_t :2; /*!< bit: 5.. 6 Reserved */ + uint8_t WRTLOCK:1; /*!< bit: 7 Write Lock */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SYSCTRL_OSCULP32K_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_OSCULP32K_OFFSET 0x1C /**< \brief (SYSCTRL_OSCULP32K offset) 32kHz Ultra Low Power Internal Oscillator (OSCULP32K) Control */ +#define SYSCTRL_OSCULP32K_RESETVALUE 0x1F /**< \brief (SYSCTRL_OSCULP32K reset_value) 32kHz Ultra Low Power Internal Oscillator (OSCULP32K) Control */ + +#define SYSCTRL_OSCULP32K_CALIB_Pos 0 /**< \brief (SYSCTRL_OSCULP32K) Oscillator Calibration */ +#define SYSCTRL_OSCULP32K_CALIB_Msk (0x1Fu << SYSCTRL_OSCULP32K_CALIB_Pos) +#define SYSCTRL_OSCULP32K_CALIB(value) ((SYSCTRL_OSCULP32K_CALIB_Msk & ((value) << SYSCTRL_OSCULP32K_CALIB_Pos))) +#define SYSCTRL_OSCULP32K_WRTLOCK_Pos 7 /**< \brief (SYSCTRL_OSCULP32K) Write Lock */ +#define SYSCTRL_OSCULP32K_WRTLOCK (0x1u << SYSCTRL_OSCULP32K_WRTLOCK_Pos) +#define SYSCTRL_OSCULP32K_MASK 0x9Fu /**< \brief (SYSCTRL_OSCULP32K) MASK Register */ + +/* -------- SYSCTRL_OSC8M : (SYSCTRL Offset: 0x20) (R/W 32) 8MHz Internal Oscillator (OSC8M) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :1; /*!< bit: 0 Reserved */ + uint32_t ENABLE:1; /*!< bit: 1 Oscillator Enable */ + uint32_t :4; /*!< bit: 2.. 5 Reserved */ + uint32_t RUNSTDBY:1; /*!< bit: 6 Run in Standby */ + uint32_t ONDEMAND:1; /*!< bit: 7 On Demand Control */ + uint32_t PRESC:2; /*!< bit: 8.. 9 Oscillator Prescaler */ + uint32_t :6; /*!< bit: 10..15 Reserved */ + uint32_t CALIB:12; /*!< bit: 16..27 Oscillator Calibration */ + uint32_t :2; /*!< bit: 28..29 Reserved */ + uint32_t FRANGE:2; /*!< bit: 30..31 Oscillator Frequency Range */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_OSC8M_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_OSC8M_OFFSET 0x20 /**< \brief (SYSCTRL_OSC8M offset) 8MHz Internal Oscillator (OSC8M) Control */ +#define SYSCTRL_OSC8M_RESETVALUE 0x87070382 /**< \brief (SYSCTRL_OSC8M reset_value) 8MHz Internal Oscillator (OSC8M) Control */ + +#define SYSCTRL_OSC8M_ENABLE_Pos 1 /**< \brief (SYSCTRL_OSC8M) Oscillator Enable */ +#define SYSCTRL_OSC8M_ENABLE (0x1u << SYSCTRL_OSC8M_ENABLE_Pos) +#define SYSCTRL_OSC8M_RUNSTDBY_Pos 6 /**< \brief (SYSCTRL_OSC8M) Run in Standby */ +#define SYSCTRL_OSC8M_RUNSTDBY (0x1u << SYSCTRL_OSC8M_RUNSTDBY_Pos) +#define SYSCTRL_OSC8M_ONDEMAND_Pos 7 /**< \brief (SYSCTRL_OSC8M) On Demand Control */ +#define SYSCTRL_OSC8M_ONDEMAND (0x1u << SYSCTRL_OSC8M_ONDEMAND_Pos) +#define SYSCTRL_OSC8M_PRESC_Pos 8 /**< \brief (SYSCTRL_OSC8M) Oscillator Prescaler */ +#define SYSCTRL_OSC8M_PRESC_Msk (0x3u << SYSCTRL_OSC8M_PRESC_Pos) +#define SYSCTRL_OSC8M_PRESC(value) ((SYSCTRL_OSC8M_PRESC_Msk & ((value) << SYSCTRL_OSC8M_PRESC_Pos))) +#define SYSCTRL_OSC8M_PRESC_0_Val 0x0u /**< \brief (SYSCTRL_OSC8M) 1 */ +#define SYSCTRL_OSC8M_PRESC_1_Val 0x1u /**< \brief (SYSCTRL_OSC8M) 2 */ +#define SYSCTRL_OSC8M_PRESC_2_Val 0x2u /**< \brief (SYSCTRL_OSC8M) 4 */ +#define SYSCTRL_OSC8M_PRESC_3_Val 0x3u /**< \brief (SYSCTRL_OSC8M) 8 */ +#define SYSCTRL_OSC8M_PRESC_0 (SYSCTRL_OSC8M_PRESC_0_Val << SYSCTRL_OSC8M_PRESC_Pos) +#define SYSCTRL_OSC8M_PRESC_1 (SYSCTRL_OSC8M_PRESC_1_Val << SYSCTRL_OSC8M_PRESC_Pos) +#define SYSCTRL_OSC8M_PRESC_2 (SYSCTRL_OSC8M_PRESC_2_Val << SYSCTRL_OSC8M_PRESC_Pos) +#define SYSCTRL_OSC8M_PRESC_3 (SYSCTRL_OSC8M_PRESC_3_Val << SYSCTRL_OSC8M_PRESC_Pos) +#define SYSCTRL_OSC8M_CALIB_Pos 16 /**< \brief (SYSCTRL_OSC8M) Oscillator Calibration */ +#define SYSCTRL_OSC8M_CALIB_Msk (0xFFFu << SYSCTRL_OSC8M_CALIB_Pos) +#define SYSCTRL_OSC8M_CALIB(value) ((SYSCTRL_OSC8M_CALIB_Msk & ((value) << SYSCTRL_OSC8M_CALIB_Pos))) +#define SYSCTRL_OSC8M_FRANGE_Pos 30 /**< \brief (SYSCTRL_OSC8M) Oscillator Frequency Range */ +#define SYSCTRL_OSC8M_FRANGE_Msk (0x3u << SYSCTRL_OSC8M_FRANGE_Pos) +#define SYSCTRL_OSC8M_FRANGE(value) ((SYSCTRL_OSC8M_FRANGE_Msk & ((value) << SYSCTRL_OSC8M_FRANGE_Pos))) +#define SYSCTRL_OSC8M_FRANGE_0_Val 0x0u /**< \brief (SYSCTRL_OSC8M) 4 to 6MHz */ +#define SYSCTRL_OSC8M_FRANGE_1_Val 0x1u /**< \brief (SYSCTRL_OSC8M) 6 to 8MHz */ +#define SYSCTRL_OSC8M_FRANGE_2_Val 0x2u /**< \brief (SYSCTRL_OSC8M) 8 to 11MHz */ +#define SYSCTRL_OSC8M_FRANGE_3_Val 0x3u /**< \brief (SYSCTRL_OSC8M) 11 to 15MHz */ +#define SYSCTRL_OSC8M_FRANGE_0 (SYSCTRL_OSC8M_FRANGE_0_Val << SYSCTRL_OSC8M_FRANGE_Pos) +#define SYSCTRL_OSC8M_FRANGE_1 (SYSCTRL_OSC8M_FRANGE_1_Val << SYSCTRL_OSC8M_FRANGE_Pos) +#define SYSCTRL_OSC8M_FRANGE_2 (SYSCTRL_OSC8M_FRANGE_2_Val << SYSCTRL_OSC8M_FRANGE_Pos) +#define SYSCTRL_OSC8M_FRANGE_3 (SYSCTRL_OSC8M_FRANGE_3_Val << SYSCTRL_OSC8M_FRANGE_Pos) +#define SYSCTRL_OSC8M_MASK 0xCFFF03C2u /**< \brief (SYSCTRL_OSC8M) MASK Register */ + +/* -------- SYSCTRL_DFLLCTRL : (SYSCTRL Offset: 0x24) (R/W 16) DFLL48M Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t :1; /*!< bit: 0 Reserved */ + uint16_t ENABLE:1; /*!< bit: 1 DFLL Enable */ + uint16_t MODE:1; /*!< bit: 2 Operating Mode Selection */ + uint16_t STABLE:1; /*!< bit: 3 Stable DFLL Frequency */ + uint16_t LLAW:1; /*!< bit: 4 Lose Lock After Wake */ + uint16_t USBCRM:1; /*!< bit: 5 USB Clock Recovery Mode */ + uint16_t RUNSTDBY:1; /*!< bit: 6 Run in Standby */ + uint16_t ONDEMAND:1; /*!< bit: 7 On Demand Control */ + uint16_t CCDIS:1; /*!< bit: 8 Chill Cycle Disable */ + uint16_t QLDIS:1; /*!< bit: 9 Quick Lock Disable */ + uint16_t BPLCKC:1; /*!< bit: 10 Bypass Coarse Lock */ + uint16_t WAITLOCK:1; /*!< bit: 11 Wait Lock */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} SYSCTRL_DFLLCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_DFLLCTRL_OFFSET 0x24 /**< \brief (SYSCTRL_DFLLCTRL offset) DFLL48M Control */ +#define SYSCTRL_DFLLCTRL_RESETVALUE 0x0080 /**< \brief (SYSCTRL_DFLLCTRL reset_value) DFLL48M Control */ + +#define SYSCTRL_DFLLCTRL_ENABLE_Pos 1 /**< \brief (SYSCTRL_DFLLCTRL) DFLL Enable */ +#define SYSCTRL_DFLLCTRL_ENABLE (0x1u << SYSCTRL_DFLLCTRL_ENABLE_Pos) +#define SYSCTRL_DFLLCTRL_MODE_Pos 2 /**< \brief (SYSCTRL_DFLLCTRL) Operating Mode Selection */ +#define SYSCTRL_DFLLCTRL_MODE (0x1u << SYSCTRL_DFLLCTRL_MODE_Pos) +#define SYSCTRL_DFLLCTRL_STABLE_Pos 3 /**< \brief (SYSCTRL_DFLLCTRL) Stable DFLL Frequency */ +#define SYSCTRL_DFLLCTRL_STABLE (0x1u << SYSCTRL_DFLLCTRL_STABLE_Pos) +#define SYSCTRL_DFLLCTRL_LLAW_Pos 4 /**< \brief (SYSCTRL_DFLLCTRL) Lose Lock After Wake */ +#define SYSCTRL_DFLLCTRL_LLAW (0x1u << SYSCTRL_DFLLCTRL_LLAW_Pos) +#define SYSCTRL_DFLLCTRL_USBCRM_Pos 5 /**< \brief (SYSCTRL_DFLLCTRL) USB Clock Recovery Mode */ +#define SYSCTRL_DFLLCTRL_USBCRM (0x1u << SYSCTRL_DFLLCTRL_USBCRM_Pos) +#define SYSCTRL_DFLLCTRL_RUNSTDBY_Pos 6 /**< \brief (SYSCTRL_DFLLCTRL) Run in Standby */ +#define SYSCTRL_DFLLCTRL_RUNSTDBY (0x1u << SYSCTRL_DFLLCTRL_RUNSTDBY_Pos) +#define SYSCTRL_DFLLCTRL_ONDEMAND_Pos 7 /**< \brief (SYSCTRL_DFLLCTRL) On Demand Control */ +#define SYSCTRL_DFLLCTRL_ONDEMAND (0x1u << SYSCTRL_DFLLCTRL_ONDEMAND_Pos) +#define SYSCTRL_DFLLCTRL_CCDIS_Pos 8 /**< \brief (SYSCTRL_DFLLCTRL) Chill Cycle Disable */ +#define SYSCTRL_DFLLCTRL_CCDIS (0x1u << SYSCTRL_DFLLCTRL_CCDIS_Pos) +#define SYSCTRL_DFLLCTRL_QLDIS_Pos 9 /**< \brief (SYSCTRL_DFLLCTRL) Quick Lock Disable */ +#define SYSCTRL_DFLLCTRL_QLDIS (0x1u << SYSCTRL_DFLLCTRL_QLDIS_Pos) +#define SYSCTRL_DFLLCTRL_BPLCKC_Pos 10 /**< \brief (SYSCTRL_DFLLCTRL) Bypass Coarse Lock */ +#define SYSCTRL_DFLLCTRL_BPLCKC (0x1u << SYSCTRL_DFLLCTRL_BPLCKC_Pos) +#define SYSCTRL_DFLLCTRL_WAITLOCK_Pos 11 /**< \brief (SYSCTRL_DFLLCTRL) Wait Lock */ +#define SYSCTRL_DFLLCTRL_WAITLOCK (0x1u << SYSCTRL_DFLLCTRL_WAITLOCK_Pos) +#define SYSCTRL_DFLLCTRL_MASK 0x0FFEu /**< \brief (SYSCTRL_DFLLCTRL) MASK Register */ + +/* -------- SYSCTRL_DFLLVAL : (SYSCTRL Offset: 0x28) (R/W 32) DFLL48M Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t FINE:10; /*!< bit: 0.. 9 Fine Value */ + uint32_t COARSE:6; /*!< bit: 10..15 Coarse Value */ + uint32_t DIFF:16; /*!< bit: 16..31 Multiplication Ratio Difference */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_DFLLVAL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_DFLLVAL_OFFSET 0x28 /**< \brief (SYSCTRL_DFLLVAL offset) DFLL48M Value */ +#define SYSCTRL_DFLLVAL_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_DFLLVAL reset_value) DFLL48M Value */ + +#define SYSCTRL_DFLLVAL_FINE_Pos 0 /**< \brief (SYSCTRL_DFLLVAL) Fine Value */ +#define SYSCTRL_DFLLVAL_FINE_Msk (0x3FFu << SYSCTRL_DFLLVAL_FINE_Pos) +#define SYSCTRL_DFLLVAL_FINE(value) ((SYSCTRL_DFLLVAL_FINE_Msk & ((value) << SYSCTRL_DFLLVAL_FINE_Pos))) +#define SYSCTRL_DFLLVAL_COARSE_Pos 10 /**< \brief (SYSCTRL_DFLLVAL) Coarse Value */ +#define SYSCTRL_DFLLVAL_COARSE_Msk (0x3Fu << SYSCTRL_DFLLVAL_COARSE_Pos) +#define SYSCTRL_DFLLVAL_COARSE(value) ((SYSCTRL_DFLLVAL_COARSE_Msk & ((value) << SYSCTRL_DFLLVAL_COARSE_Pos))) +#define SYSCTRL_DFLLVAL_DIFF_Pos 16 /**< \brief (SYSCTRL_DFLLVAL) Multiplication Ratio Difference */ +#define SYSCTRL_DFLLVAL_DIFF_Msk (0xFFFFu << SYSCTRL_DFLLVAL_DIFF_Pos) +#define SYSCTRL_DFLLVAL_DIFF(value) ((SYSCTRL_DFLLVAL_DIFF_Msk & ((value) << SYSCTRL_DFLLVAL_DIFF_Pos))) +#define SYSCTRL_DFLLVAL_MASK 0xFFFFFFFFu /**< \brief (SYSCTRL_DFLLVAL) MASK Register */ + +/* -------- SYSCTRL_DFLLMUL : (SYSCTRL Offset: 0x2C) (R/W 32) DFLL48M Multiplier -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t MUL:16; /*!< bit: 0..15 DFLL Multiply Factor */ + uint32_t FSTEP:10; /*!< bit: 16..25 Fine Maximum Step */ + uint32_t CSTEP:6; /*!< bit: 26..31 Coarse Maximum Step */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_DFLLMUL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_DFLLMUL_OFFSET 0x2C /**< \brief (SYSCTRL_DFLLMUL offset) DFLL48M Multiplier */ +#define SYSCTRL_DFLLMUL_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_DFLLMUL reset_value) DFLL48M Multiplier */ + +#define SYSCTRL_DFLLMUL_MUL_Pos 0 /**< \brief (SYSCTRL_DFLLMUL) DFLL Multiply Factor */ +#define SYSCTRL_DFLLMUL_MUL_Msk (0xFFFFu << SYSCTRL_DFLLMUL_MUL_Pos) +#define SYSCTRL_DFLLMUL_MUL(value) ((SYSCTRL_DFLLMUL_MUL_Msk & ((value) << SYSCTRL_DFLLMUL_MUL_Pos))) +#define SYSCTRL_DFLLMUL_FSTEP_Pos 16 /**< \brief (SYSCTRL_DFLLMUL) Fine Maximum Step */ +#define SYSCTRL_DFLLMUL_FSTEP_Msk (0x3FFu << SYSCTRL_DFLLMUL_FSTEP_Pos) +#define SYSCTRL_DFLLMUL_FSTEP(value) ((SYSCTRL_DFLLMUL_FSTEP_Msk & ((value) << SYSCTRL_DFLLMUL_FSTEP_Pos))) +#define SYSCTRL_DFLLMUL_CSTEP_Pos 26 /**< \brief (SYSCTRL_DFLLMUL) Coarse Maximum Step */ +#define SYSCTRL_DFLLMUL_CSTEP_Msk (0x3Fu << SYSCTRL_DFLLMUL_CSTEP_Pos) +#define SYSCTRL_DFLLMUL_CSTEP(value) ((SYSCTRL_DFLLMUL_CSTEP_Msk & ((value) << SYSCTRL_DFLLMUL_CSTEP_Pos))) +#define SYSCTRL_DFLLMUL_MASK 0xFFFFFFFFu /**< \brief (SYSCTRL_DFLLMUL) MASK Register */ + +/* -------- SYSCTRL_DFLLSYNC : (SYSCTRL Offset: 0x30) (R/W 8) DFLL48M Synchronization -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :7; /*!< bit: 0.. 6 Reserved */ + uint8_t READREQ:1; /*!< bit: 7 Read Request */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SYSCTRL_DFLLSYNC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_DFLLSYNC_OFFSET 0x30 /**< \brief (SYSCTRL_DFLLSYNC offset) DFLL48M Synchronization */ +#define SYSCTRL_DFLLSYNC_RESETVALUE 0x00 /**< \brief (SYSCTRL_DFLLSYNC reset_value) DFLL48M Synchronization */ + +#define SYSCTRL_DFLLSYNC_READREQ_Pos 7 /**< \brief (SYSCTRL_DFLLSYNC) Read Request */ +#define SYSCTRL_DFLLSYNC_READREQ (0x1u << SYSCTRL_DFLLSYNC_READREQ_Pos) +#define SYSCTRL_DFLLSYNC_MASK 0x80u /**< \brief (SYSCTRL_DFLLSYNC) MASK Register */ + +/* -------- SYSCTRL_BOD33 : (SYSCTRL Offset: 0x34) (R/W 32) 3.3V Brown-Out Detector (BOD33) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :1; /*!< bit: 0 Reserved */ + uint32_t ENABLE:1; /*!< bit: 1 Enable */ + uint32_t HYST:1; /*!< bit: 2 Hysteresis */ + uint32_t ACTION:2; /*!< bit: 3.. 4 BOD33 Action */ + uint32_t :1; /*!< bit: 5 Reserved */ + uint32_t RUNSTDBY:1; /*!< bit: 6 Run in Standby */ + uint32_t :1; /*!< bit: 7 Reserved */ + uint32_t MODE:1; /*!< bit: 8 Operation Mode */ + uint32_t CEN:1; /*!< bit: 9 Clock Enable */ + uint32_t :2; /*!< bit: 10..11 Reserved */ + uint32_t PSEL:4; /*!< bit: 12..15 Prescaler Select */ + uint32_t LEVEL:6; /*!< bit: 16..21 BOD33 Threshold Level */ + uint32_t :10; /*!< bit: 22..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_BOD33_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_BOD33_OFFSET 0x34 /**< \brief (SYSCTRL_BOD33 offset) 3.3V Brown-Out Detector (BOD33) Control */ +#define SYSCTRL_BOD33_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_BOD33 reset_value) 3.3V Brown-Out Detector (BOD33) Control */ + +#define SYSCTRL_BOD33_ENABLE_Pos 1 /**< \brief (SYSCTRL_BOD33) Enable */ +#define SYSCTRL_BOD33_ENABLE (0x1u << SYSCTRL_BOD33_ENABLE_Pos) +#define SYSCTRL_BOD33_HYST_Pos 2 /**< \brief (SYSCTRL_BOD33) Hysteresis */ +#define SYSCTRL_BOD33_HYST (0x1u << SYSCTRL_BOD33_HYST_Pos) +#define SYSCTRL_BOD33_ACTION_Pos 3 /**< \brief (SYSCTRL_BOD33) BOD33 Action */ +#define SYSCTRL_BOD33_ACTION_Msk (0x3u << SYSCTRL_BOD33_ACTION_Pos) +#define SYSCTRL_BOD33_ACTION(value) ((SYSCTRL_BOD33_ACTION_Msk & ((value) << SYSCTRL_BOD33_ACTION_Pos))) +#define SYSCTRL_BOD33_ACTION_NONE_Val 0x0u /**< \brief (SYSCTRL_BOD33) No action */ +#define SYSCTRL_BOD33_ACTION_RESET_Val 0x1u /**< \brief (SYSCTRL_BOD33) The BOD33 generates a reset */ +#define SYSCTRL_BOD33_ACTION_INTERRUPT_Val 0x2u /**< \brief (SYSCTRL_BOD33) The BOD33 generates an interrupt */ +#define SYSCTRL_BOD33_ACTION_NONE (SYSCTRL_BOD33_ACTION_NONE_Val << SYSCTRL_BOD33_ACTION_Pos) +#define SYSCTRL_BOD33_ACTION_RESET (SYSCTRL_BOD33_ACTION_RESET_Val << SYSCTRL_BOD33_ACTION_Pos) +#define SYSCTRL_BOD33_ACTION_INTERRUPT (SYSCTRL_BOD33_ACTION_INTERRUPT_Val << SYSCTRL_BOD33_ACTION_Pos) +#define SYSCTRL_BOD33_RUNSTDBY_Pos 6 /**< \brief (SYSCTRL_BOD33) Run in Standby */ +#define SYSCTRL_BOD33_RUNSTDBY (0x1u << SYSCTRL_BOD33_RUNSTDBY_Pos) +#define SYSCTRL_BOD33_MODE_Pos 8 /**< \brief (SYSCTRL_BOD33) Operation Mode */ +#define SYSCTRL_BOD33_MODE (0x1u << SYSCTRL_BOD33_MODE_Pos) +#define SYSCTRL_BOD33_CEN_Pos 9 /**< \brief (SYSCTRL_BOD33) Clock Enable */ +#define SYSCTRL_BOD33_CEN (0x1u << SYSCTRL_BOD33_CEN_Pos) +#define SYSCTRL_BOD33_PSEL_Pos 12 /**< \brief (SYSCTRL_BOD33) Prescaler Select */ +#define SYSCTRL_BOD33_PSEL_Msk (0xFu << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL(value) ((SYSCTRL_BOD33_PSEL_Msk & ((value) << SYSCTRL_BOD33_PSEL_Pos))) +#define SYSCTRL_BOD33_PSEL_DIV2_Val 0x0u /**< \brief (SYSCTRL_BOD33) Divide clock by 2 */ +#define SYSCTRL_BOD33_PSEL_DIV4_Val 0x1u /**< \brief (SYSCTRL_BOD33) Divide clock by 4 */ +#define SYSCTRL_BOD33_PSEL_DIV8_Val 0x2u /**< \brief (SYSCTRL_BOD33) Divide clock by 8 */ +#define SYSCTRL_BOD33_PSEL_DIV16_Val 0x3u /**< \brief (SYSCTRL_BOD33) Divide clock by 16 */ +#define SYSCTRL_BOD33_PSEL_DIV32_Val 0x4u /**< \brief (SYSCTRL_BOD33) Divide clock by 32 */ +#define SYSCTRL_BOD33_PSEL_DIV64_Val 0x5u /**< \brief (SYSCTRL_BOD33) Divide clock by 64 */ +#define SYSCTRL_BOD33_PSEL_DIV128_Val 0x6u /**< \brief (SYSCTRL_BOD33) Divide clock by 128 */ +#define SYSCTRL_BOD33_PSEL_DIV256_Val 0x7u /**< \brief (SYSCTRL_BOD33) Divide clock by 256 */ +#define SYSCTRL_BOD33_PSEL_DIV512_Val 0x8u /**< \brief (SYSCTRL_BOD33) Divide clock by 512 */ +#define SYSCTRL_BOD33_PSEL_DIV1K_Val 0x9u /**< \brief (SYSCTRL_BOD33) Divide clock by 1024 */ +#define SYSCTRL_BOD33_PSEL_DIV2K_Val 0xAu /**< \brief (SYSCTRL_BOD33) Divide clock by 2048 */ +#define SYSCTRL_BOD33_PSEL_DIV4K_Val 0xBu /**< \brief (SYSCTRL_BOD33) Divide clock by 4096 */ +#define SYSCTRL_BOD33_PSEL_DIV8K_Val 0xCu /**< \brief (SYSCTRL_BOD33) Divide clock by 8192 */ +#define SYSCTRL_BOD33_PSEL_DIV16K_Val 0xDu /**< \brief (SYSCTRL_BOD33) Divide clock by 16384 */ +#define SYSCTRL_BOD33_PSEL_DIV32K_Val 0xEu /**< \brief (SYSCTRL_BOD33) Divide clock by 32768 */ +#define SYSCTRL_BOD33_PSEL_DIV64K_Val 0xFu /**< \brief (SYSCTRL_BOD33) Divide clock by 65536 */ +#define SYSCTRL_BOD33_PSEL_DIV2 (SYSCTRL_BOD33_PSEL_DIV2_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV4 (SYSCTRL_BOD33_PSEL_DIV4_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV8 (SYSCTRL_BOD33_PSEL_DIV8_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV16 (SYSCTRL_BOD33_PSEL_DIV16_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV32 (SYSCTRL_BOD33_PSEL_DIV32_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV64 (SYSCTRL_BOD33_PSEL_DIV64_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV128 (SYSCTRL_BOD33_PSEL_DIV128_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV256 (SYSCTRL_BOD33_PSEL_DIV256_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV512 (SYSCTRL_BOD33_PSEL_DIV512_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV1K (SYSCTRL_BOD33_PSEL_DIV1K_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV2K (SYSCTRL_BOD33_PSEL_DIV2K_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV4K (SYSCTRL_BOD33_PSEL_DIV4K_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV8K (SYSCTRL_BOD33_PSEL_DIV8K_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV16K (SYSCTRL_BOD33_PSEL_DIV16K_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV32K (SYSCTRL_BOD33_PSEL_DIV32K_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV64K (SYSCTRL_BOD33_PSEL_DIV64K_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_LEVEL_Pos 16 /**< \brief (SYSCTRL_BOD33) BOD33 Threshold Level */ +#define SYSCTRL_BOD33_LEVEL_Msk (0x3Fu << SYSCTRL_BOD33_LEVEL_Pos) +#define SYSCTRL_BOD33_LEVEL(value) ((SYSCTRL_BOD33_LEVEL_Msk & ((value) << SYSCTRL_BOD33_LEVEL_Pos))) +#define SYSCTRL_BOD33_MASK 0x003FF35Eu /**< \brief (SYSCTRL_BOD33) MASK Register */ + +/* -------- SYSCTRL_VREG : (SYSCTRL Offset: 0x3C) (R/W 16) Voltage Regulator System (VREG) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t :6; /*!< bit: 0.. 5 Reserved */ + uint16_t RUNSTDBY:1; /*!< bit: 6 Run in Standby */ + uint16_t :6; /*!< bit: 7..12 Reserved */ + uint16_t FORCELDO:1; /*!< bit: 13 Force LDO Voltage Regulator */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} SYSCTRL_VREG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_VREG_OFFSET 0x3C /**< \brief (SYSCTRL_VREG offset) Voltage Regulator System (VREG) Control */ +#define SYSCTRL_VREG_RESETVALUE 0x0000 /**< \brief (SYSCTRL_VREG reset_value) Voltage Regulator System (VREG) Control */ + +#define SYSCTRL_VREG_RUNSTDBY_Pos 6 /**< \brief (SYSCTRL_VREG) Run in Standby */ +#define SYSCTRL_VREG_RUNSTDBY (0x1u << SYSCTRL_VREG_RUNSTDBY_Pos) +#define SYSCTRL_VREG_FORCELDO_Pos 13 /**< \brief (SYSCTRL_VREG) Force LDO Voltage Regulator */ +#define SYSCTRL_VREG_FORCELDO (0x1u << SYSCTRL_VREG_FORCELDO_Pos) +#define SYSCTRL_VREG_MASK 0x2040u /**< \brief (SYSCTRL_VREG) MASK Register */ + +/* -------- SYSCTRL_VREF : (SYSCTRL Offset: 0x40) (R/W 32) Voltage References System (VREF) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :1; /*!< bit: 0 Reserved */ + uint32_t TSEN:1; /*!< bit: 1 Temperature Sensor Enable */ + uint32_t BGOUTEN:1; /*!< bit: 2 Bandgap Output Enable */ + uint32_t :13; /*!< bit: 3..15 Reserved */ + uint32_t CALIB:11; /*!< bit: 16..26 Bandgap Voltage Generator Calibration */ + uint32_t :5; /*!< bit: 27..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_VREF_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_VREF_OFFSET 0x40 /**< \brief (SYSCTRL_VREF offset) Voltage References System (VREF) Control */ +#define SYSCTRL_VREF_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_VREF reset_value) Voltage References System (VREF) Control */ + +#define SYSCTRL_VREF_TSEN_Pos 1 /**< \brief (SYSCTRL_VREF) Temperature Sensor Enable */ +#define SYSCTRL_VREF_TSEN (0x1u << SYSCTRL_VREF_TSEN_Pos) +#define SYSCTRL_VREF_BGOUTEN_Pos 2 /**< \brief (SYSCTRL_VREF) Bandgap Output Enable */ +#define SYSCTRL_VREF_BGOUTEN (0x1u << SYSCTRL_VREF_BGOUTEN_Pos) +#define SYSCTRL_VREF_CALIB_Pos 16 /**< \brief (SYSCTRL_VREF) Bandgap Voltage Generator Calibration */ +#define SYSCTRL_VREF_CALIB_Msk (0x7FFu << SYSCTRL_VREF_CALIB_Pos) +#define SYSCTRL_VREF_CALIB(value) ((SYSCTRL_VREF_CALIB_Msk & ((value) << SYSCTRL_VREF_CALIB_Pos))) +#define SYSCTRL_VREF_MASK 0x07FF0006u /**< \brief (SYSCTRL_VREF) MASK Register */ + +/* -------- SYSCTRL_DPLLCTRLA : (SYSCTRL Offset: 0x44) (R/W 8) DPLL Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :1; /*!< bit: 0 Reserved */ + uint8_t ENABLE:1; /*!< bit: 1 DPLL Enable */ + uint8_t :4; /*!< bit: 2.. 5 Reserved */ + uint8_t RUNSTDBY:1; /*!< bit: 6 Run in Standby */ + uint8_t ONDEMAND:1; /*!< bit: 7 On Demand Clock Activation */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SYSCTRL_DPLLCTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_DPLLCTRLA_OFFSET 0x44 /**< \brief (SYSCTRL_DPLLCTRLA offset) DPLL Control A */ +#define SYSCTRL_DPLLCTRLA_RESETVALUE 0x80 /**< \brief (SYSCTRL_DPLLCTRLA reset_value) DPLL Control A */ + +#define SYSCTRL_DPLLCTRLA_ENABLE_Pos 1 /**< \brief (SYSCTRL_DPLLCTRLA) DPLL Enable */ +#define SYSCTRL_DPLLCTRLA_ENABLE (0x1u << SYSCTRL_DPLLCTRLA_ENABLE_Pos) +#define SYSCTRL_DPLLCTRLA_RUNSTDBY_Pos 6 /**< \brief (SYSCTRL_DPLLCTRLA) Run in Standby */ +#define SYSCTRL_DPLLCTRLA_RUNSTDBY (0x1u << SYSCTRL_DPLLCTRLA_RUNSTDBY_Pos) +#define SYSCTRL_DPLLCTRLA_ONDEMAND_Pos 7 /**< \brief (SYSCTRL_DPLLCTRLA) On Demand Clock Activation */ +#define SYSCTRL_DPLLCTRLA_ONDEMAND (0x1u << SYSCTRL_DPLLCTRLA_ONDEMAND_Pos) +#define SYSCTRL_DPLLCTRLA_MASK 0xC2u /**< \brief (SYSCTRL_DPLLCTRLA) MASK Register */ + +/* -------- SYSCTRL_DPLLRATIO : (SYSCTRL Offset: 0x48) (R/W 32) DPLL Ratio Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t LDR:12; /*!< bit: 0..11 Loop Divider Ratio */ + uint32_t :4; /*!< bit: 12..15 Reserved */ + uint32_t LDRFRAC:4; /*!< bit: 16..19 Loop Divider Ratio Fractional Part */ + uint32_t :12; /*!< bit: 20..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_DPLLRATIO_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_DPLLRATIO_OFFSET 0x48 /**< \brief (SYSCTRL_DPLLRATIO offset) DPLL Ratio Control */ +#define SYSCTRL_DPLLRATIO_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_DPLLRATIO reset_value) DPLL Ratio Control */ + +#define SYSCTRL_DPLLRATIO_LDR_Pos 0 /**< \brief (SYSCTRL_DPLLRATIO) Loop Divider Ratio */ +#define SYSCTRL_DPLLRATIO_LDR_Msk (0xFFFu << SYSCTRL_DPLLRATIO_LDR_Pos) +#define SYSCTRL_DPLLRATIO_LDR(value) ((SYSCTRL_DPLLRATIO_LDR_Msk & ((value) << SYSCTRL_DPLLRATIO_LDR_Pos))) +#define SYSCTRL_DPLLRATIO_LDRFRAC_Pos 16 /**< \brief (SYSCTRL_DPLLRATIO) Loop Divider Ratio Fractional Part */ +#define SYSCTRL_DPLLRATIO_LDRFRAC_Msk (0xFu << SYSCTRL_DPLLRATIO_LDRFRAC_Pos) +#define SYSCTRL_DPLLRATIO_LDRFRAC(value) ((SYSCTRL_DPLLRATIO_LDRFRAC_Msk & ((value) << SYSCTRL_DPLLRATIO_LDRFRAC_Pos))) +#define SYSCTRL_DPLLRATIO_MASK 0x000F0FFFu /**< \brief (SYSCTRL_DPLLRATIO) MASK Register */ + +/* -------- SYSCTRL_DPLLCTRLB : (SYSCTRL Offset: 0x4C) (R/W 32) DPLL Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t FILTER:2; /*!< bit: 0.. 1 Proportional Integral Filter Selection */ + uint32_t LPEN:1; /*!< bit: 2 Low-Power Enable */ + uint32_t WUF:1; /*!< bit: 3 Wake Up Fast */ + uint32_t REFCLK:2; /*!< bit: 4.. 5 Reference Clock Selection */ + uint32_t :2; /*!< bit: 6.. 7 Reserved */ + uint32_t LTIME:3; /*!< bit: 8..10 Lock Time */ + uint32_t :1; /*!< bit: 11 Reserved */ + uint32_t LBYPASS:1; /*!< bit: 12 Lock Bypass */ + uint32_t :3; /*!< bit: 13..15 Reserved */ + uint32_t DIV:11; /*!< bit: 16..26 Clock Divider */ + uint32_t :5; /*!< bit: 27..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_DPLLCTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_DPLLCTRLB_OFFSET 0x4C /**< \brief (SYSCTRL_DPLLCTRLB offset) DPLL Control B */ +#define SYSCTRL_DPLLCTRLB_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_DPLLCTRLB reset_value) DPLL Control B */ + +#define SYSCTRL_DPLLCTRLB_FILTER_Pos 0 /**< \brief (SYSCTRL_DPLLCTRLB) Proportional Integral Filter Selection */ +#define SYSCTRL_DPLLCTRLB_FILTER_Msk (0x3u << SYSCTRL_DPLLCTRLB_FILTER_Pos) +#define SYSCTRL_DPLLCTRLB_FILTER(value) ((SYSCTRL_DPLLCTRLB_FILTER_Msk & ((value) << SYSCTRL_DPLLCTRLB_FILTER_Pos))) +#define SYSCTRL_DPLLCTRLB_FILTER_DEFAULT_Val 0x0u /**< \brief (SYSCTRL_DPLLCTRLB) Default filter mode */ +#define SYSCTRL_DPLLCTRLB_FILTER_LBFILT_Val 0x1u /**< \brief (SYSCTRL_DPLLCTRLB) Low bandwidth filter */ +#define SYSCTRL_DPLLCTRLB_FILTER_HBFILT_Val 0x2u /**< \brief (SYSCTRL_DPLLCTRLB) High bandwidth filter */ +#define SYSCTRL_DPLLCTRLB_FILTER_HDFILT_Val 0x3u /**< \brief (SYSCTRL_DPLLCTRLB) High damping filter */ +#define SYSCTRL_DPLLCTRLB_FILTER_DEFAULT (SYSCTRL_DPLLCTRLB_FILTER_DEFAULT_Val << SYSCTRL_DPLLCTRLB_FILTER_Pos) +#define SYSCTRL_DPLLCTRLB_FILTER_LBFILT (SYSCTRL_DPLLCTRLB_FILTER_LBFILT_Val << SYSCTRL_DPLLCTRLB_FILTER_Pos) +#define SYSCTRL_DPLLCTRLB_FILTER_HBFILT (SYSCTRL_DPLLCTRLB_FILTER_HBFILT_Val << SYSCTRL_DPLLCTRLB_FILTER_Pos) +#define SYSCTRL_DPLLCTRLB_FILTER_HDFILT (SYSCTRL_DPLLCTRLB_FILTER_HDFILT_Val << SYSCTRL_DPLLCTRLB_FILTER_Pos) +#define SYSCTRL_DPLLCTRLB_LPEN_Pos 2 /**< \brief (SYSCTRL_DPLLCTRLB) Low-Power Enable */ +#define SYSCTRL_DPLLCTRLB_LPEN (0x1u << SYSCTRL_DPLLCTRLB_LPEN_Pos) +#define SYSCTRL_DPLLCTRLB_WUF_Pos 3 /**< \brief (SYSCTRL_DPLLCTRLB) Wake Up Fast */ +#define SYSCTRL_DPLLCTRLB_WUF (0x1u << SYSCTRL_DPLLCTRLB_WUF_Pos) +#define SYSCTRL_DPLLCTRLB_REFCLK_Pos 4 /**< \brief (SYSCTRL_DPLLCTRLB) Reference Clock Selection */ +#define SYSCTRL_DPLLCTRLB_REFCLK_Msk (0x3u << SYSCTRL_DPLLCTRLB_REFCLK_Pos) +#define SYSCTRL_DPLLCTRLB_REFCLK(value) ((SYSCTRL_DPLLCTRLB_REFCLK_Msk & ((value) << SYSCTRL_DPLLCTRLB_REFCLK_Pos))) +#define SYSCTRL_DPLLCTRLB_REFCLK_REF0_Val 0x0u /**< \brief (SYSCTRL_DPLLCTRLB) CLK_DPLL_REF0 clock reference */ +#define SYSCTRL_DPLLCTRLB_REFCLK_REF1_Val 0x1u /**< \brief (SYSCTRL_DPLLCTRLB) CLK_DPLL_REF1 clock reference */ +#define SYSCTRL_DPLLCTRLB_REFCLK_GCLK_Val 0x2u /**< \brief (SYSCTRL_DPLLCTRLB) GCLK_DPLL clock reference */ +#define SYSCTRL_DPLLCTRLB_REFCLK_REF0 (SYSCTRL_DPLLCTRLB_REFCLK_REF0_Val << SYSCTRL_DPLLCTRLB_REFCLK_Pos) +#define SYSCTRL_DPLLCTRLB_REFCLK_REF1 (SYSCTRL_DPLLCTRLB_REFCLK_REF1_Val << SYSCTRL_DPLLCTRLB_REFCLK_Pos) +#define SYSCTRL_DPLLCTRLB_REFCLK_GCLK (SYSCTRL_DPLLCTRLB_REFCLK_GCLK_Val << SYSCTRL_DPLLCTRLB_REFCLK_Pos) +#define SYSCTRL_DPLLCTRLB_LTIME_Pos 8 /**< \brief (SYSCTRL_DPLLCTRLB) Lock Time */ +#define SYSCTRL_DPLLCTRLB_LTIME_Msk (0x7u << SYSCTRL_DPLLCTRLB_LTIME_Pos) +#define SYSCTRL_DPLLCTRLB_LTIME(value) ((SYSCTRL_DPLLCTRLB_LTIME_Msk & ((value) << SYSCTRL_DPLLCTRLB_LTIME_Pos))) +#define SYSCTRL_DPLLCTRLB_LTIME_DEFAULT_Val 0x0u /**< \brief (SYSCTRL_DPLLCTRLB) No time-out */ +#define SYSCTRL_DPLLCTRLB_LTIME_8MS_Val 0x4u /**< \brief (SYSCTRL_DPLLCTRLB) Time-out if no lock within 8 ms */ +#define SYSCTRL_DPLLCTRLB_LTIME_9MS_Val 0x5u /**< \brief (SYSCTRL_DPLLCTRLB) Time-out if no lock within 9 ms */ +#define SYSCTRL_DPLLCTRLB_LTIME_10MS_Val 0x6u /**< \brief (SYSCTRL_DPLLCTRLB) Time-out if no lock within 10 ms */ +#define SYSCTRL_DPLLCTRLB_LTIME_11MS_Val 0x7u /**< \brief (SYSCTRL_DPLLCTRLB) Time-out if no lock within 11 ms */ +#define SYSCTRL_DPLLCTRLB_LTIME_DEFAULT (SYSCTRL_DPLLCTRLB_LTIME_DEFAULT_Val << SYSCTRL_DPLLCTRLB_LTIME_Pos) +#define SYSCTRL_DPLLCTRLB_LTIME_8MS (SYSCTRL_DPLLCTRLB_LTIME_8MS_Val << SYSCTRL_DPLLCTRLB_LTIME_Pos) +#define SYSCTRL_DPLLCTRLB_LTIME_9MS (SYSCTRL_DPLLCTRLB_LTIME_9MS_Val << SYSCTRL_DPLLCTRLB_LTIME_Pos) +#define SYSCTRL_DPLLCTRLB_LTIME_10MS (SYSCTRL_DPLLCTRLB_LTIME_10MS_Val << SYSCTRL_DPLLCTRLB_LTIME_Pos) +#define SYSCTRL_DPLLCTRLB_LTIME_11MS (SYSCTRL_DPLLCTRLB_LTIME_11MS_Val << SYSCTRL_DPLLCTRLB_LTIME_Pos) +#define SYSCTRL_DPLLCTRLB_LBYPASS_Pos 12 /**< \brief (SYSCTRL_DPLLCTRLB) Lock Bypass */ +#define SYSCTRL_DPLLCTRLB_LBYPASS (0x1u << SYSCTRL_DPLLCTRLB_LBYPASS_Pos) +#define SYSCTRL_DPLLCTRLB_DIV_Pos 16 /**< \brief (SYSCTRL_DPLLCTRLB) Clock Divider */ +#define SYSCTRL_DPLLCTRLB_DIV_Msk (0x7FFu << SYSCTRL_DPLLCTRLB_DIV_Pos) +#define SYSCTRL_DPLLCTRLB_DIV(value) ((SYSCTRL_DPLLCTRLB_DIV_Msk & ((value) << SYSCTRL_DPLLCTRLB_DIV_Pos))) +#define SYSCTRL_DPLLCTRLB_MASK 0x07FF173Fu /**< \brief (SYSCTRL_DPLLCTRLB) MASK Register */ + +/* -------- SYSCTRL_DPLLSTATUS : (SYSCTRL Offset: 0x50) (R/ 8) DPLL Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t LOCK:1; /*!< bit: 0 DPLL Lock Status */ + uint8_t CLKRDY:1; /*!< bit: 1 Output Clock Ready */ + uint8_t ENABLE:1; /*!< bit: 2 DPLL Enable */ + uint8_t DIV:1; /*!< bit: 3 Divider Enable */ + uint8_t :4; /*!< bit: 4.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SYSCTRL_DPLLSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_DPLLSTATUS_OFFSET 0x50 /**< \brief (SYSCTRL_DPLLSTATUS offset) DPLL Status */ +#define SYSCTRL_DPLLSTATUS_RESETVALUE 0x00 /**< \brief (SYSCTRL_DPLLSTATUS reset_value) DPLL Status */ + +#define SYSCTRL_DPLLSTATUS_LOCK_Pos 0 /**< \brief (SYSCTRL_DPLLSTATUS) DPLL Lock Status */ +#define SYSCTRL_DPLLSTATUS_LOCK (0x1u << SYSCTRL_DPLLSTATUS_LOCK_Pos) +#define SYSCTRL_DPLLSTATUS_CLKRDY_Pos 1 /**< \brief (SYSCTRL_DPLLSTATUS) Output Clock Ready */ +#define SYSCTRL_DPLLSTATUS_CLKRDY (0x1u << SYSCTRL_DPLLSTATUS_CLKRDY_Pos) +#define SYSCTRL_DPLLSTATUS_ENABLE_Pos 2 /**< \brief (SYSCTRL_DPLLSTATUS) DPLL Enable */ +#define SYSCTRL_DPLLSTATUS_ENABLE (0x1u << SYSCTRL_DPLLSTATUS_ENABLE_Pos) +#define SYSCTRL_DPLLSTATUS_DIV_Pos 3 /**< \brief (SYSCTRL_DPLLSTATUS) Divider Enable */ +#define SYSCTRL_DPLLSTATUS_DIV (0x1u << SYSCTRL_DPLLSTATUS_DIV_Pos) +#define SYSCTRL_DPLLSTATUS_MASK 0x0Fu /**< \brief (SYSCTRL_DPLLSTATUS) MASK Register */ + +/** \brief SYSCTRL hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO SYSCTRL_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x00 (R/W 32) Interrupt Enable Clear */ + __IO SYSCTRL_INTENSET_Type INTENSET; /**< \brief Offset: 0x04 (R/W 32) Interrupt Enable Set */ + __IO SYSCTRL_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x08 (R/W 32) Interrupt Flag Status and Clear */ + __I SYSCTRL_PCLKSR_Type PCLKSR; /**< \brief Offset: 0x0C (R/ 32) Power and Clocks Status */ + __IO SYSCTRL_XOSC_Type XOSC; /**< \brief Offset: 0x10 (R/W 16) External Multipurpose Crystal Oscillator (XOSC) Control */ + RoReg8 Reserved1[0x2]; + __IO SYSCTRL_XOSC32K_Type XOSC32K; /**< \brief Offset: 0x14 (R/W 16) 32kHz External Crystal Oscillator (XOSC32K) Control */ + RoReg8 Reserved2[0x2]; + __IO SYSCTRL_OSC32K_Type OSC32K; /**< \brief Offset: 0x18 (R/W 32) 32kHz Internal Oscillator (OSC32K) Control */ + __IO SYSCTRL_OSCULP32K_Type OSCULP32K; /**< \brief Offset: 0x1C (R/W 8) 32kHz Ultra Low Power Internal Oscillator (OSCULP32K) Control */ + RoReg8 Reserved3[0x3]; + __IO SYSCTRL_OSC8M_Type OSC8M; /**< \brief Offset: 0x20 (R/W 32) 8MHz Internal Oscillator (OSC8M) Control */ + __IO SYSCTRL_DFLLCTRL_Type DFLLCTRL; /**< \brief Offset: 0x24 (R/W 16) DFLL48M Control */ + RoReg8 Reserved4[0x2]; + __IO SYSCTRL_DFLLVAL_Type DFLLVAL; /**< \brief Offset: 0x28 (R/W 32) DFLL48M Value */ + __IO SYSCTRL_DFLLMUL_Type DFLLMUL; /**< \brief Offset: 0x2C (R/W 32) DFLL48M Multiplier */ + __IO SYSCTRL_DFLLSYNC_Type DFLLSYNC; /**< \brief Offset: 0x30 (R/W 8) DFLL48M Synchronization */ + RoReg8 Reserved5[0x3]; + __IO SYSCTRL_BOD33_Type BOD33; /**< \brief Offset: 0x34 (R/W 32) 3.3V Brown-Out Detector (BOD33) Control */ + RoReg8 Reserved6[0x4]; + __IO SYSCTRL_VREG_Type VREG; /**< \brief Offset: 0x3C (R/W 16) Voltage Regulator System (VREG) Control */ + RoReg8 Reserved7[0x2]; + __IO SYSCTRL_VREF_Type VREF; /**< \brief Offset: 0x40 (R/W 32) Voltage References System (VREF) Control */ + __IO SYSCTRL_DPLLCTRLA_Type DPLLCTRLA; /**< \brief Offset: 0x44 (R/W 8) DPLL Control A */ + RoReg8 Reserved8[0x3]; + __IO SYSCTRL_DPLLRATIO_Type DPLLRATIO; /**< \brief Offset: 0x48 (R/W 32) DPLL Ratio Control */ + __IO SYSCTRL_DPLLCTRLB_Type DPLLCTRLB; /**< \brief Offset: 0x4C (R/W 32) DPLL Control B */ + __I SYSCTRL_DPLLSTATUS_Type DPLLSTATUS; /**< \brief Offset: 0x50 (R/ 8) DPLL Status */ +} Sysctrl; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_SYSCTRL_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/tc.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/tc.h new file mode 100644 index 0000000..824ca55 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/tc.h @@ -0,0 +1,684 @@ +/** + * \file + * + * \brief Component description for TC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_TC_COMPONENT_ +#define _SAMD21_TC_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR TC */ +/* ========================================================================== */ +/** \addtogroup SAMD21_TC Basic Timer Counter */ +/*@{*/ + +#define TC_U2212 +#define REV_TC 0x121 + +/* -------- TC_CTRLA : (TC Offset: 0x00) (R/W 16) Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SWRST:1; /*!< bit: 0 Software Reset */ + uint16_t ENABLE:1; /*!< bit: 1 Enable */ + uint16_t MODE:2; /*!< bit: 2.. 3 TC Mode */ + uint16_t :1; /*!< bit: 4 Reserved */ + uint16_t WAVEGEN:2; /*!< bit: 5.. 6 Waveform Generation Operation */ + uint16_t :1; /*!< bit: 7 Reserved */ + uint16_t PRESCALER:3; /*!< bit: 8..10 Prescaler */ + uint16_t RUNSTDBY:1; /*!< bit: 11 Run in Standby */ + uint16_t PRESCSYNC:2; /*!< bit: 12..13 Prescaler and Counter Synchronization */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} TC_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_CTRLA_OFFSET 0x00 /**< \brief (TC_CTRLA offset) Control A */ +#define TC_CTRLA_RESETVALUE 0x0000 /**< \brief (TC_CTRLA reset_value) Control A */ + +#define TC_CTRLA_SWRST_Pos 0 /**< \brief (TC_CTRLA) Software Reset */ +#define TC_CTRLA_SWRST (0x1u << TC_CTRLA_SWRST_Pos) +#define TC_CTRLA_ENABLE_Pos 1 /**< \brief (TC_CTRLA) Enable */ +#define TC_CTRLA_ENABLE (0x1u << TC_CTRLA_ENABLE_Pos) +#define TC_CTRLA_MODE_Pos 2 /**< \brief (TC_CTRLA) TC Mode */ +#define TC_CTRLA_MODE_Msk (0x3u << TC_CTRLA_MODE_Pos) +#define TC_CTRLA_MODE(value) ((TC_CTRLA_MODE_Msk & ((value) << TC_CTRLA_MODE_Pos))) +#define TC_CTRLA_MODE_COUNT16_Val 0x0u /**< \brief (TC_CTRLA) Counter in 16-bit mode */ +#define TC_CTRLA_MODE_COUNT8_Val 0x1u /**< \brief (TC_CTRLA) Counter in 8-bit mode */ +#define TC_CTRLA_MODE_COUNT32_Val 0x2u /**< \brief (TC_CTRLA) Counter in 32-bit mode */ +#define TC_CTRLA_MODE_COUNT16 (TC_CTRLA_MODE_COUNT16_Val << TC_CTRLA_MODE_Pos) +#define TC_CTRLA_MODE_COUNT8 (TC_CTRLA_MODE_COUNT8_Val << TC_CTRLA_MODE_Pos) +#define TC_CTRLA_MODE_COUNT32 (TC_CTRLA_MODE_COUNT32_Val << TC_CTRLA_MODE_Pos) +#define TC_CTRLA_WAVEGEN_Pos 5 /**< \brief (TC_CTRLA) Waveform Generation Operation */ +#define TC_CTRLA_WAVEGEN_Msk (0x3u << TC_CTRLA_WAVEGEN_Pos) +#define TC_CTRLA_WAVEGEN(value) ((TC_CTRLA_WAVEGEN_Msk & ((value) << TC_CTRLA_WAVEGEN_Pos))) +#define TC_CTRLA_WAVEGEN_NFRQ_Val 0x0u /**< \brief (TC_CTRLA) */ +#define TC_CTRLA_WAVEGEN_MFRQ_Val 0x1u /**< \brief (TC_CTRLA) */ +#define TC_CTRLA_WAVEGEN_NPWM_Val 0x2u /**< \brief (TC_CTRLA) */ +#define TC_CTRLA_WAVEGEN_MPWM_Val 0x3u /**< \brief (TC_CTRLA) */ +#define TC_CTRLA_WAVEGEN_NFRQ (TC_CTRLA_WAVEGEN_NFRQ_Val << TC_CTRLA_WAVEGEN_Pos) +#define TC_CTRLA_WAVEGEN_MFRQ (TC_CTRLA_WAVEGEN_MFRQ_Val << TC_CTRLA_WAVEGEN_Pos) +#define TC_CTRLA_WAVEGEN_NPWM (TC_CTRLA_WAVEGEN_NPWM_Val << TC_CTRLA_WAVEGEN_Pos) +#define TC_CTRLA_WAVEGEN_MPWM (TC_CTRLA_WAVEGEN_MPWM_Val << TC_CTRLA_WAVEGEN_Pos) +#define TC_CTRLA_PRESCALER_Pos 8 /**< \brief (TC_CTRLA) Prescaler */ +#define TC_CTRLA_PRESCALER_Msk (0x7u << TC_CTRLA_PRESCALER_Pos) +#define TC_CTRLA_PRESCALER(value) ((TC_CTRLA_PRESCALER_Msk & ((value) << TC_CTRLA_PRESCALER_Pos))) +#define TC_CTRLA_PRESCALER_DIV1_Val 0x0u /**< \brief (TC_CTRLA) Prescaler: GCLK_TC */ +#define TC_CTRLA_PRESCALER_DIV2_Val 0x1u /**< \brief (TC_CTRLA) Prescaler: GCLK_TC/2 */ +#define TC_CTRLA_PRESCALER_DIV4_Val 0x2u /**< \brief (TC_CTRLA) Prescaler: GCLK_TC/4 */ +#define TC_CTRLA_PRESCALER_DIV8_Val 0x3u /**< \brief (TC_CTRLA) Prescaler: GCLK_TC/8 */ +#define TC_CTRLA_PRESCALER_DIV16_Val 0x4u /**< \brief (TC_CTRLA) Prescaler: GCLK_TC/16 */ +#define TC_CTRLA_PRESCALER_DIV64_Val 0x5u /**< \brief (TC_CTRLA) Prescaler: GCLK_TC/64 */ +#define TC_CTRLA_PRESCALER_DIV256_Val 0x6u /**< \brief (TC_CTRLA) Prescaler: GCLK_TC/256 */ +#define TC_CTRLA_PRESCALER_DIV1024_Val 0x7u /**< \brief (TC_CTRLA) Prescaler: GCLK_TC/1024 */ +#define TC_CTRLA_PRESCALER_DIV1 (TC_CTRLA_PRESCALER_DIV1_Val << TC_CTRLA_PRESCALER_Pos) +#define TC_CTRLA_PRESCALER_DIV2 (TC_CTRLA_PRESCALER_DIV2_Val << TC_CTRLA_PRESCALER_Pos) +#define TC_CTRLA_PRESCALER_DIV4 (TC_CTRLA_PRESCALER_DIV4_Val << TC_CTRLA_PRESCALER_Pos) +#define TC_CTRLA_PRESCALER_DIV8 (TC_CTRLA_PRESCALER_DIV8_Val << TC_CTRLA_PRESCALER_Pos) +#define TC_CTRLA_PRESCALER_DIV16 (TC_CTRLA_PRESCALER_DIV16_Val << TC_CTRLA_PRESCALER_Pos) +#define TC_CTRLA_PRESCALER_DIV64 (TC_CTRLA_PRESCALER_DIV64_Val << TC_CTRLA_PRESCALER_Pos) +#define TC_CTRLA_PRESCALER_DIV256 (TC_CTRLA_PRESCALER_DIV256_Val << TC_CTRLA_PRESCALER_Pos) +#define TC_CTRLA_PRESCALER_DIV1024 (TC_CTRLA_PRESCALER_DIV1024_Val << TC_CTRLA_PRESCALER_Pos) +#define TC_CTRLA_RUNSTDBY_Pos 11 /**< \brief (TC_CTRLA) Run in Standby */ +#define TC_CTRLA_RUNSTDBY (0x1u << TC_CTRLA_RUNSTDBY_Pos) +#define TC_CTRLA_PRESCSYNC_Pos 12 /**< \brief (TC_CTRLA) Prescaler and Counter Synchronization */ +#define TC_CTRLA_PRESCSYNC_Msk (0x3u << TC_CTRLA_PRESCSYNC_Pos) +#define TC_CTRLA_PRESCSYNC(value) ((TC_CTRLA_PRESCSYNC_Msk & ((value) << TC_CTRLA_PRESCSYNC_Pos))) +#define TC_CTRLA_PRESCSYNC_GCLK_Val 0x0u /**< \brief (TC_CTRLA) Reload or reset the counter on next generic clock */ +#define TC_CTRLA_PRESCSYNC_PRESC_Val 0x1u /**< \brief (TC_CTRLA) Reload or reset the counter on next prescaler clock */ +#define TC_CTRLA_PRESCSYNC_RESYNC_Val 0x2u /**< \brief (TC_CTRLA) Reload or reset the counter on next generic clock. Reset the prescaler counter */ +#define TC_CTRLA_PRESCSYNC_GCLK (TC_CTRLA_PRESCSYNC_GCLK_Val << TC_CTRLA_PRESCSYNC_Pos) +#define TC_CTRLA_PRESCSYNC_PRESC (TC_CTRLA_PRESCSYNC_PRESC_Val << TC_CTRLA_PRESCSYNC_Pos) +#define TC_CTRLA_PRESCSYNC_RESYNC (TC_CTRLA_PRESCSYNC_RESYNC_Val << TC_CTRLA_PRESCSYNC_Pos) +#define TC_CTRLA_MASK 0x3F6Fu /**< \brief (TC_CTRLA) MASK Register */ + +/* -------- TC_READREQ : (TC Offset: 0x02) (R/W 16) Read Request -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t ADDR:5; /*!< bit: 0.. 4 Address */ + uint16_t :9; /*!< bit: 5..13 Reserved */ + uint16_t RCONT:1; /*!< bit: 14 Read Continuously */ + uint16_t RREQ:1; /*!< bit: 15 Read Request */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} TC_READREQ_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_READREQ_OFFSET 0x02 /**< \brief (TC_READREQ offset) Read Request */ +#define TC_READREQ_RESETVALUE 0x0000 /**< \brief (TC_READREQ reset_value) Read Request */ + +#define TC_READREQ_ADDR_Pos 0 /**< \brief (TC_READREQ) Address */ +#define TC_READREQ_ADDR_Msk (0x1Fu << TC_READREQ_ADDR_Pos) +#define TC_READREQ_ADDR(value) ((TC_READREQ_ADDR_Msk & ((value) << TC_READREQ_ADDR_Pos))) +#define TC_READREQ_RCONT_Pos 14 /**< \brief (TC_READREQ) Read Continuously */ +#define TC_READREQ_RCONT (0x1u << TC_READREQ_RCONT_Pos) +#define TC_READREQ_RREQ_Pos 15 /**< \brief (TC_READREQ) Read Request */ +#define TC_READREQ_RREQ (0x1u << TC_READREQ_RREQ_Pos) +#define TC_READREQ_MASK 0xC01Fu /**< \brief (TC_READREQ) MASK Register */ + +/* -------- TC_CTRLBCLR : (TC Offset: 0x04) (R/W 8) Control B Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DIR:1; /*!< bit: 0 Counter Direction */ + uint8_t :1; /*!< bit: 1 Reserved */ + uint8_t ONESHOT:1; /*!< bit: 2 One-Shot */ + uint8_t :3; /*!< bit: 3.. 5 Reserved */ + uint8_t CMD:2; /*!< bit: 6.. 7 Command */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TC_CTRLBCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_CTRLBCLR_OFFSET 0x04 /**< \brief (TC_CTRLBCLR offset) Control B Clear */ +#define TC_CTRLBCLR_RESETVALUE 0x02 /**< \brief (TC_CTRLBCLR reset_value) Control B Clear */ + +#define TC_CTRLBCLR_DIR_Pos 0 /**< \brief (TC_CTRLBCLR) Counter Direction */ +#define TC_CTRLBCLR_DIR (0x1u << TC_CTRLBCLR_DIR_Pos) +#define TC_CTRLBCLR_ONESHOT_Pos 2 /**< \brief (TC_CTRLBCLR) One-Shot */ +#define TC_CTRLBCLR_ONESHOT (0x1u << TC_CTRLBCLR_ONESHOT_Pos) +#define TC_CTRLBCLR_CMD_Pos 6 /**< \brief (TC_CTRLBCLR) Command */ +#define TC_CTRLBCLR_CMD_Msk (0x3u << TC_CTRLBCLR_CMD_Pos) +#define TC_CTRLBCLR_CMD(value) ((TC_CTRLBCLR_CMD_Msk & ((value) << TC_CTRLBCLR_CMD_Pos))) +#define TC_CTRLBCLR_CMD_NONE_Val 0x0u /**< \brief (TC_CTRLBCLR) No action */ +#define TC_CTRLBCLR_CMD_RETRIGGER_Val 0x1u /**< \brief (TC_CTRLBCLR) Force a start, restart or retrigger */ +#define TC_CTRLBCLR_CMD_STOP_Val 0x2u /**< \brief (TC_CTRLBCLR) Force a stop */ +#define TC_CTRLBCLR_CMD_NONE (TC_CTRLBCLR_CMD_NONE_Val << TC_CTRLBCLR_CMD_Pos) +#define TC_CTRLBCLR_CMD_RETRIGGER (TC_CTRLBCLR_CMD_RETRIGGER_Val << TC_CTRLBCLR_CMD_Pos) +#define TC_CTRLBCLR_CMD_STOP (TC_CTRLBCLR_CMD_STOP_Val << TC_CTRLBCLR_CMD_Pos) +#define TC_CTRLBCLR_MASK 0xC5u /**< \brief (TC_CTRLBCLR) MASK Register */ + +/* -------- TC_CTRLBSET : (TC Offset: 0x05) (R/W 8) Control B Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DIR:1; /*!< bit: 0 Counter Direction */ + uint8_t :1; /*!< bit: 1 Reserved */ + uint8_t ONESHOT:1; /*!< bit: 2 One-Shot */ + uint8_t :3; /*!< bit: 3.. 5 Reserved */ + uint8_t CMD:2; /*!< bit: 6.. 7 Command */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TC_CTRLBSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_CTRLBSET_OFFSET 0x05 /**< \brief (TC_CTRLBSET offset) Control B Set */ +#define TC_CTRLBSET_RESETVALUE 0x00 /**< \brief (TC_CTRLBSET reset_value) Control B Set */ + +#define TC_CTRLBSET_DIR_Pos 0 /**< \brief (TC_CTRLBSET) Counter Direction */ +#define TC_CTRLBSET_DIR (0x1u << TC_CTRLBSET_DIR_Pos) +#define TC_CTRLBSET_ONESHOT_Pos 2 /**< \brief (TC_CTRLBSET) One-Shot */ +#define TC_CTRLBSET_ONESHOT (0x1u << TC_CTRLBSET_ONESHOT_Pos) +#define TC_CTRLBSET_CMD_Pos 6 /**< \brief (TC_CTRLBSET) Command */ +#define TC_CTRLBSET_CMD_Msk (0x3u << TC_CTRLBSET_CMD_Pos) +#define TC_CTRLBSET_CMD(value) ((TC_CTRLBSET_CMD_Msk & ((value) << TC_CTRLBSET_CMD_Pos))) +#define TC_CTRLBSET_CMD_NONE_Val 0x0u /**< \brief (TC_CTRLBSET) No action */ +#define TC_CTRLBSET_CMD_RETRIGGER_Val 0x1u /**< \brief (TC_CTRLBSET) Force a start, restart or retrigger */ +#define TC_CTRLBSET_CMD_STOP_Val 0x2u /**< \brief (TC_CTRLBSET) Force a stop */ +#define TC_CTRLBSET_CMD_NONE (TC_CTRLBSET_CMD_NONE_Val << TC_CTRLBSET_CMD_Pos) +#define TC_CTRLBSET_CMD_RETRIGGER (TC_CTRLBSET_CMD_RETRIGGER_Val << TC_CTRLBSET_CMD_Pos) +#define TC_CTRLBSET_CMD_STOP (TC_CTRLBSET_CMD_STOP_Val << TC_CTRLBSET_CMD_Pos) +#define TC_CTRLBSET_MASK 0xC5u /**< \brief (TC_CTRLBSET) MASK Register */ + +/* -------- TC_CTRLC : (TC Offset: 0x06) (R/W 8) Control C -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t INVEN0:1; /*!< bit: 0 Output Waveform 0 Invert Enable */ + uint8_t INVEN1:1; /*!< bit: 1 Output Waveform 1 Invert Enable */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t CPTEN0:1; /*!< bit: 4 Capture Channel 0 Enable */ + uint8_t CPTEN1:1; /*!< bit: 5 Capture Channel 1 Enable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t INVEN:2; /*!< bit: 0.. 1 Output Waveform x Invert Enable */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t CPTEN:2; /*!< bit: 4.. 5 Capture Channel x Enable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} TC_CTRLC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_CTRLC_OFFSET 0x06 /**< \brief (TC_CTRLC offset) Control C */ +#define TC_CTRLC_RESETVALUE 0x00 /**< \brief (TC_CTRLC reset_value) Control C */ + +#define TC_CTRLC_INVEN0_Pos 0 /**< \brief (TC_CTRLC) Output Waveform 0 Invert Enable */ +#define TC_CTRLC_INVEN0 (1 << TC_CTRLC_INVEN0_Pos) +#define TC_CTRLC_INVEN1_Pos 1 /**< \brief (TC_CTRLC) Output Waveform 1 Invert Enable */ +#define TC_CTRLC_INVEN1 (1 << TC_CTRLC_INVEN1_Pos) +#define TC_CTRLC_INVEN_Pos 0 /**< \brief (TC_CTRLC) Output Waveform x Invert Enable */ +#define TC_CTRLC_INVEN_Msk (0x3u << TC_CTRLC_INVEN_Pos) +#define TC_CTRLC_INVEN(value) ((TC_CTRLC_INVEN_Msk & ((value) << TC_CTRLC_INVEN_Pos))) +#define TC_CTRLC_CPTEN0_Pos 4 /**< \brief (TC_CTRLC) Capture Channel 0 Enable */ +#define TC_CTRLC_CPTEN0 (1 << TC_CTRLC_CPTEN0_Pos) +#define TC_CTRLC_CPTEN1_Pos 5 /**< \brief (TC_CTRLC) Capture Channel 1 Enable */ +#define TC_CTRLC_CPTEN1 (1 << TC_CTRLC_CPTEN1_Pos) +#define TC_CTRLC_CPTEN_Pos 4 /**< \brief (TC_CTRLC) Capture Channel x Enable */ +#define TC_CTRLC_CPTEN_Msk (0x3u << TC_CTRLC_CPTEN_Pos) +#define TC_CTRLC_CPTEN(value) ((TC_CTRLC_CPTEN_Msk & ((value) << TC_CTRLC_CPTEN_Pos))) +#define TC_CTRLC_MASK 0x33u /**< \brief (TC_CTRLC) MASK Register */ + +/* -------- TC_DBGCTRL : (TC Offset: 0x08) (R/W 8) Debug Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DBGRUN:1; /*!< bit: 0 Debug Run Mode */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TC_DBGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_DBGCTRL_OFFSET 0x08 /**< \brief (TC_DBGCTRL offset) Debug Control */ +#define TC_DBGCTRL_RESETVALUE 0x00 /**< \brief (TC_DBGCTRL reset_value) Debug Control */ + +#define TC_DBGCTRL_DBGRUN_Pos 0 /**< \brief (TC_DBGCTRL) Debug Run Mode */ +#define TC_DBGCTRL_DBGRUN (0x1u << TC_DBGCTRL_DBGRUN_Pos) +#define TC_DBGCTRL_MASK 0x01u /**< \brief (TC_DBGCTRL) MASK Register */ + +/* -------- TC_EVCTRL : (TC Offset: 0x0A) (R/W 16) Event Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t EVACT:3; /*!< bit: 0.. 2 Event Action */ + uint16_t :1; /*!< bit: 3 Reserved */ + uint16_t TCINV:1; /*!< bit: 4 TC Inverted Event Input */ + uint16_t TCEI:1; /*!< bit: 5 TC Event Input */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t OVFEO:1; /*!< bit: 8 Overflow/Underflow Event Output Enable */ + uint16_t :3; /*!< bit: 9..11 Reserved */ + uint16_t MCEO0:1; /*!< bit: 12 Match or Capture Channel 0 Event Output Enable */ + uint16_t MCEO1:1; /*!< bit: 13 Match or Capture Channel 1 Event Output Enable */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t :12; /*!< bit: 0..11 Reserved */ + uint16_t MCEO:2; /*!< bit: 12..13 Match or Capture Channel x Event Output Enable */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} TC_EVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_EVCTRL_OFFSET 0x0A /**< \brief (TC_EVCTRL offset) Event Control */ +#define TC_EVCTRL_RESETVALUE 0x0000 /**< \brief (TC_EVCTRL reset_value) Event Control */ + +#define TC_EVCTRL_EVACT_Pos 0 /**< \brief (TC_EVCTRL) Event Action */ +#define TC_EVCTRL_EVACT_Msk (0x7u << TC_EVCTRL_EVACT_Pos) +#define TC_EVCTRL_EVACT(value) ((TC_EVCTRL_EVACT_Msk & ((value) << TC_EVCTRL_EVACT_Pos))) +#define TC_EVCTRL_EVACT_OFF_Val 0x0u /**< \brief (TC_EVCTRL) Event action disabled */ +#define TC_EVCTRL_EVACT_RETRIGGER_Val 0x1u /**< \brief (TC_EVCTRL) Start, restart or retrigger TC on event */ +#define TC_EVCTRL_EVACT_COUNT_Val 0x2u /**< \brief (TC_EVCTRL) Count on event */ +#define TC_EVCTRL_EVACT_START_Val 0x3u /**< \brief (TC_EVCTRL) Start TC on event */ +#define TC_EVCTRL_EVACT_PPW_Val 0x5u /**< \brief (TC_EVCTRL) Period captured in CC0, pulse width in CC1 */ +#define TC_EVCTRL_EVACT_PWP_Val 0x6u /**< \brief (TC_EVCTRL) Period captured in CC1, pulse width in CC0 */ +#define TC_EVCTRL_EVACT_OFF (TC_EVCTRL_EVACT_OFF_Val << TC_EVCTRL_EVACT_Pos) +#define TC_EVCTRL_EVACT_RETRIGGER (TC_EVCTRL_EVACT_RETRIGGER_Val << TC_EVCTRL_EVACT_Pos) +#define TC_EVCTRL_EVACT_COUNT (TC_EVCTRL_EVACT_COUNT_Val << TC_EVCTRL_EVACT_Pos) +#define TC_EVCTRL_EVACT_START (TC_EVCTRL_EVACT_START_Val << TC_EVCTRL_EVACT_Pos) +#define TC_EVCTRL_EVACT_PPW (TC_EVCTRL_EVACT_PPW_Val << TC_EVCTRL_EVACT_Pos) +#define TC_EVCTRL_EVACT_PWP (TC_EVCTRL_EVACT_PWP_Val << TC_EVCTRL_EVACT_Pos) +#define TC_EVCTRL_TCINV_Pos 4 /**< \brief (TC_EVCTRL) TC Inverted Event Input */ +#define TC_EVCTRL_TCINV (0x1u << TC_EVCTRL_TCINV_Pos) +#define TC_EVCTRL_TCEI_Pos 5 /**< \brief (TC_EVCTRL) TC Event Input */ +#define TC_EVCTRL_TCEI (0x1u << TC_EVCTRL_TCEI_Pos) +#define TC_EVCTRL_OVFEO_Pos 8 /**< \brief (TC_EVCTRL) Overflow/Underflow Event Output Enable */ +#define TC_EVCTRL_OVFEO (0x1u << TC_EVCTRL_OVFEO_Pos) +#define TC_EVCTRL_MCEO0_Pos 12 /**< \brief (TC_EVCTRL) Match or Capture Channel 0 Event Output Enable */ +#define TC_EVCTRL_MCEO0 (1 << TC_EVCTRL_MCEO0_Pos) +#define TC_EVCTRL_MCEO1_Pos 13 /**< \brief (TC_EVCTRL) Match or Capture Channel 1 Event Output Enable */ +#define TC_EVCTRL_MCEO1 (1 << TC_EVCTRL_MCEO1_Pos) +#define TC_EVCTRL_MCEO_Pos 12 /**< \brief (TC_EVCTRL) Match or Capture Channel x Event Output Enable */ +#define TC_EVCTRL_MCEO_Msk (0x3u << TC_EVCTRL_MCEO_Pos) +#define TC_EVCTRL_MCEO(value) ((TC_EVCTRL_MCEO_Msk & ((value) << TC_EVCTRL_MCEO_Pos))) +#define TC_EVCTRL_MASK 0x3137u /**< \brief (TC_EVCTRL) MASK Register */ + +/* -------- TC_INTENCLR : (TC Offset: 0x0C) (R/W 8) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t OVF:1; /*!< bit: 0 Overflow Interrupt Enable */ + uint8_t ERR:1; /*!< bit: 1 Error Interrupt Enable */ + uint8_t :1; /*!< bit: 2 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 3 Synchronization Ready Interrupt Enable */ + uint8_t MC0:1; /*!< bit: 4 Match or Capture Channel 0 Interrupt Enable */ + uint8_t MC1:1; /*!< bit: 5 Match or Capture Channel 1 Interrupt Enable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t :4; /*!< bit: 0.. 3 Reserved */ + uint8_t MC:2; /*!< bit: 4.. 5 Match or Capture Channel x Interrupt Enable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} TC_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_INTENCLR_OFFSET 0x0C /**< \brief (TC_INTENCLR offset) Interrupt Enable Clear */ +#define TC_INTENCLR_RESETVALUE 0x00 /**< \brief (TC_INTENCLR reset_value) Interrupt Enable Clear */ + +#define TC_INTENCLR_OVF_Pos 0 /**< \brief (TC_INTENCLR) Overflow Interrupt Enable */ +#define TC_INTENCLR_OVF (0x1u << TC_INTENCLR_OVF_Pos) +#define TC_INTENCLR_ERR_Pos 1 /**< \brief (TC_INTENCLR) Error Interrupt Enable */ +#define TC_INTENCLR_ERR (0x1u << TC_INTENCLR_ERR_Pos) +#define TC_INTENCLR_SYNCRDY_Pos 3 /**< \brief (TC_INTENCLR) Synchronization Ready Interrupt Enable */ +#define TC_INTENCLR_SYNCRDY (0x1u << TC_INTENCLR_SYNCRDY_Pos) +#define TC_INTENCLR_MC0_Pos 4 /**< \brief (TC_INTENCLR) Match or Capture Channel 0 Interrupt Enable */ +#define TC_INTENCLR_MC0 (1 << TC_INTENCLR_MC0_Pos) +#define TC_INTENCLR_MC1_Pos 5 /**< \brief (TC_INTENCLR) Match or Capture Channel 1 Interrupt Enable */ +#define TC_INTENCLR_MC1 (1 << TC_INTENCLR_MC1_Pos) +#define TC_INTENCLR_MC_Pos 4 /**< \brief (TC_INTENCLR) Match or Capture Channel x Interrupt Enable */ +#define TC_INTENCLR_MC_Msk (0x3u << TC_INTENCLR_MC_Pos) +#define TC_INTENCLR_MC(value) ((TC_INTENCLR_MC_Msk & ((value) << TC_INTENCLR_MC_Pos))) +#define TC_INTENCLR_MASK 0x3Bu /**< \brief (TC_INTENCLR) MASK Register */ + +/* -------- TC_INTENSET : (TC Offset: 0x0D) (R/W 8) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t OVF:1; /*!< bit: 0 Overflow Interrupt Enable */ + uint8_t ERR:1; /*!< bit: 1 Error Interrupt Enable */ + uint8_t :1; /*!< bit: 2 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 3 Synchronization Ready Interrupt Enable */ + uint8_t MC0:1; /*!< bit: 4 Match or Capture Channel 0 Interrupt Enable */ + uint8_t MC1:1; /*!< bit: 5 Match or Capture Channel 1 Interrupt Enable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t :4; /*!< bit: 0.. 3 Reserved */ + uint8_t MC:2; /*!< bit: 4.. 5 Match or Capture Channel x Interrupt Enable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} TC_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_INTENSET_OFFSET 0x0D /**< \brief (TC_INTENSET offset) Interrupt Enable Set */ +#define TC_INTENSET_RESETVALUE 0x00 /**< \brief (TC_INTENSET reset_value) Interrupt Enable Set */ + +#define TC_INTENSET_OVF_Pos 0 /**< \brief (TC_INTENSET) Overflow Interrupt Enable */ +#define TC_INTENSET_OVF (0x1u << TC_INTENSET_OVF_Pos) +#define TC_INTENSET_ERR_Pos 1 /**< \brief (TC_INTENSET) Error Interrupt Enable */ +#define TC_INTENSET_ERR (0x1u << TC_INTENSET_ERR_Pos) +#define TC_INTENSET_SYNCRDY_Pos 3 /**< \brief (TC_INTENSET) Synchronization Ready Interrupt Enable */ +#define TC_INTENSET_SYNCRDY (0x1u << TC_INTENSET_SYNCRDY_Pos) +#define TC_INTENSET_MC0_Pos 4 /**< \brief (TC_INTENSET) Match or Capture Channel 0 Interrupt Enable */ +#define TC_INTENSET_MC0 (1 << TC_INTENSET_MC0_Pos) +#define TC_INTENSET_MC1_Pos 5 /**< \brief (TC_INTENSET) Match or Capture Channel 1 Interrupt Enable */ +#define TC_INTENSET_MC1 (1 << TC_INTENSET_MC1_Pos) +#define TC_INTENSET_MC_Pos 4 /**< \brief (TC_INTENSET) Match or Capture Channel x Interrupt Enable */ +#define TC_INTENSET_MC_Msk (0x3u << TC_INTENSET_MC_Pos) +#define TC_INTENSET_MC(value) ((TC_INTENSET_MC_Msk & ((value) << TC_INTENSET_MC_Pos))) +#define TC_INTENSET_MASK 0x3Bu /**< \brief (TC_INTENSET) MASK Register */ + +/* -------- TC_INTFLAG : (TC Offset: 0x0E) (R/W 8) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t OVF:1; /*!< bit: 0 Overflow */ + uint8_t ERR:1; /*!< bit: 1 Error */ + uint8_t :1; /*!< bit: 2 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 3 Synchronization Ready */ + uint8_t MC0:1; /*!< bit: 4 Match or Capture Channel 0 */ + uint8_t MC1:1; /*!< bit: 5 Match or Capture Channel 1 */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t :4; /*!< bit: 0.. 3 Reserved */ + uint8_t MC:2; /*!< bit: 4.. 5 Match or Capture Channel x */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} TC_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_INTFLAG_OFFSET 0x0E /**< \brief (TC_INTFLAG offset) Interrupt Flag Status and Clear */ +#define TC_INTFLAG_RESETVALUE 0x00 /**< \brief (TC_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define TC_INTFLAG_OVF_Pos 0 /**< \brief (TC_INTFLAG) Overflow */ +#define TC_INTFLAG_OVF (0x1u << TC_INTFLAG_OVF_Pos) +#define TC_INTFLAG_ERR_Pos 1 /**< \brief (TC_INTFLAG) Error */ +#define TC_INTFLAG_ERR (0x1u << TC_INTFLAG_ERR_Pos) +#define TC_INTFLAG_SYNCRDY_Pos 3 /**< \brief (TC_INTFLAG) Synchronization Ready */ +#define TC_INTFLAG_SYNCRDY (0x1u << TC_INTFLAG_SYNCRDY_Pos) +#define TC_INTFLAG_MC0_Pos 4 /**< \brief (TC_INTFLAG) Match or Capture Channel 0 */ +#define TC_INTFLAG_MC0 (1 << TC_INTFLAG_MC0_Pos) +#define TC_INTFLAG_MC1_Pos 5 /**< \brief (TC_INTFLAG) Match or Capture Channel 1 */ +#define TC_INTFLAG_MC1 (1 << TC_INTFLAG_MC1_Pos) +#define TC_INTFLAG_MC_Pos 4 /**< \brief (TC_INTFLAG) Match or Capture Channel x */ +#define TC_INTFLAG_MC_Msk (0x3u << TC_INTFLAG_MC_Pos) +#define TC_INTFLAG_MC(value) ((TC_INTFLAG_MC_Msk & ((value) << TC_INTFLAG_MC_Pos))) +#define TC_INTFLAG_MASK 0x3Bu /**< \brief (TC_INTFLAG) MASK Register */ + +/* -------- TC_STATUS : (TC Offset: 0x0F) (R/ 8) Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :3; /*!< bit: 0.. 2 Reserved */ + uint8_t STOP:1; /*!< bit: 3 Stop */ + uint8_t SLAVE:1; /*!< bit: 4 Slave */ + uint8_t :2; /*!< bit: 5.. 6 Reserved */ + uint8_t SYNCBUSY:1; /*!< bit: 7 Synchronization Busy */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TC_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_STATUS_OFFSET 0x0F /**< \brief (TC_STATUS offset) Status */ +#define TC_STATUS_RESETVALUE 0x08 /**< \brief (TC_STATUS reset_value) Status */ + +#define TC_STATUS_STOP_Pos 3 /**< \brief (TC_STATUS) Stop */ +#define TC_STATUS_STOP (0x1u << TC_STATUS_STOP_Pos) +#define TC_STATUS_SLAVE_Pos 4 /**< \brief (TC_STATUS) Slave */ +#define TC_STATUS_SLAVE (0x1u << TC_STATUS_SLAVE_Pos) +#define TC_STATUS_SYNCBUSY_Pos 7 /**< \brief (TC_STATUS) Synchronization Busy */ +#define TC_STATUS_SYNCBUSY (0x1u << TC_STATUS_SYNCBUSY_Pos) +#define TC_STATUS_MASK 0x98u /**< \brief (TC_STATUS) MASK Register */ + +/* -------- TC_COUNT16_COUNT : (TC Offset: 0x10) (R/W 16) COUNT16 COUNT16 Counter Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t COUNT:16; /*!< bit: 0..15 Count Value */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} TC_COUNT16_COUNT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_COUNT16_COUNT_OFFSET 0x10 /**< \brief (TC_COUNT16_COUNT offset) COUNT16 Counter Value */ +#define TC_COUNT16_COUNT_RESETVALUE 0x0000 /**< \brief (TC_COUNT16_COUNT reset_value) COUNT16 Counter Value */ + +#define TC_COUNT16_COUNT_COUNT_Pos 0 /**< \brief (TC_COUNT16_COUNT) Count Value */ +#define TC_COUNT16_COUNT_COUNT_Msk (0xFFFFu << TC_COUNT16_COUNT_COUNT_Pos) +#define TC_COUNT16_COUNT_COUNT(value) ((TC_COUNT16_COUNT_COUNT_Msk & ((value) << TC_COUNT16_COUNT_COUNT_Pos))) +#define TC_COUNT16_COUNT_MASK 0xFFFFu /**< \brief (TC_COUNT16_COUNT) MASK Register */ + +/* -------- TC_COUNT32_COUNT : (TC Offset: 0x10) (R/W 32) COUNT32 COUNT32 Counter Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t COUNT:32; /*!< bit: 0..31 Count Value */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} TC_COUNT32_COUNT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_COUNT32_COUNT_OFFSET 0x10 /**< \brief (TC_COUNT32_COUNT offset) COUNT32 Counter Value */ +#define TC_COUNT32_COUNT_RESETVALUE 0x00000000 /**< \brief (TC_COUNT32_COUNT reset_value) COUNT32 Counter Value */ + +#define TC_COUNT32_COUNT_COUNT_Pos 0 /**< \brief (TC_COUNT32_COUNT) Count Value */ +#define TC_COUNT32_COUNT_COUNT_Msk (0xFFFFFFFFu << TC_COUNT32_COUNT_COUNT_Pos) +#define TC_COUNT32_COUNT_COUNT(value) ((TC_COUNT32_COUNT_COUNT_Msk & ((value) << TC_COUNT32_COUNT_COUNT_Pos))) +#define TC_COUNT32_COUNT_MASK 0xFFFFFFFFu /**< \brief (TC_COUNT32_COUNT) MASK Register */ + +/* -------- TC_COUNT8_COUNT : (TC Offset: 0x10) (R/W 8) COUNT8 COUNT8 Counter Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t COUNT:8; /*!< bit: 0.. 7 Counter Value */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TC_COUNT8_COUNT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_COUNT8_COUNT_OFFSET 0x10 /**< \brief (TC_COUNT8_COUNT offset) COUNT8 Counter Value */ +#define TC_COUNT8_COUNT_RESETVALUE 0x00 /**< \brief (TC_COUNT8_COUNT reset_value) COUNT8 Counter Value */ + +#define TC_COUNT8_COUNT_COUNT_Pos 0 /**< \brief (TC_COUNT8_COUNT) Counter Value */ +#define TC_COUNT8_COUNT_COUNT_Msk (0xFFu << TC_COUNT8_COUNT_COUNT_Pos) +#define TC_COUNT8_COUNT_COUNT(value) ((TC_COUNT8_COUNT_COUNT_Msk & ((value) << TC_COUNT8_COUNT_COUNT_Pos))) +#define TC_COUNT8_COUNT_MASK 0xFFu /**< \brief (TC_COUNT8_COUNT) MASK Register */ + +/* -------- TC_COUNT8_PER : (TC Offset: 0x14) (R/W 8) COUNT8 COUNT8 Period Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PER:8; /*!< bit: 0.. 7 Period Value */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TC_COUNT8_PER_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_COUNT8_PER_OFFSET 0x14 /**< \brief (TC_COUNT8_PER offset) COUNT8 Period Value */ +#define TC_COUNT8_PER_RESETVALUE 0xFF /**< \brief (TC_COUNT8_PER reset_value) COUNT8 Period Value */ + +#define TC_COUNT8_PER_PER_Pos 0 /**< \brief (TC_COUNT8_PER) Period Value */ +#define TC_COUNT8_PER_PER_Msk (0xFFu << TC_COUNT8_PER_PER_Pos) +#define TC_COUNT8_PER_PER(value) ((TC_COUNT8_PER_PER_Msk & ((value) << TC_COUNT8_PER_PER_Pos))) +#define TC_COUNT8_PER_MASK 0xFFu /**< \brief (TC_COUNT8_PER) MASK Register */ + +/* -------- TC_COUNT16_CC : (TC Offset: 0x18) (R/W 16) COUNT16 COUNT16 Compare/Capture -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t CC:16; /*!< bit: 0..15 Compare/Capture Value */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} TC_COUNT16_CC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_COUNT16_CC_OFFSET 0x18 /**< \brief (TC_COUNT16_CC offset) COUNT16 Compare/Capture */ +#define TC_COUNT16_CC_RESETVALUE 0x0000 /**< \brief (TC_COUNT16_CC reset_value) COUNT16 Compare/Capture */ + +#define TC_COUNT16_CC_CC_Pos 0 /**< \brief (TC_COUNT16_CC) Compare/Capture Value */ +#define TC_COUNT16_CC_CC_Msk (0xFFFFu << TC_COUNT16_CC_CC_Pos) +#define TC_COUNT16_CC_CC(value) ((TC_COUNT16_CC_CC_Msk & ((value) << TC_COUNT16_CC_CC_Pos))) +#define TC_COUNT16_CC_MASK 0xFFFFu /**< \brief (TC_COUNT16_CC) MASK Register */ + +/* -------- TC_COUNT32_CC : (TC Offset: 0x18) (R/W 32) COUNT32 COUNT32 Compare/Capture -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CC:32; /*!< bit: 0..31 Compare/Capture Value */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} TC_COUNT32_CC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_COUNT32_CC_OFFSET 0x18 /**< \brief (TC_COUNT32_CC offset) COUNT32 Compare/Capture */ +#define TC_COUNT32_CC_RESETVALUE 0x00000000 /**< \brief (TC_COUNT32_CC reset_value) COUNT32 Compare/Capture */ + +#define TC_COUNT32_CC_CC_Pos 0 /**< \brief (TC_COUNT32_CC) Compare/Capture Value */ +#define TC_COUNT32_CC_CC_Msk (0xFFFFFFFFu << TC_COUNT32_CC_CC_Pos) +#define TC_COUNT32_CC_CC(value) ((TC_COUNT32_CC_CC_Msk & ((value) << TC_COUNT32_CC_CC_Pos))) +#define TC_COUNT32_CC_MASK 0xFFFFFFFFu /**< \brief (TC_COUNT32_CC) MASK Register */ + +/* -------- TC_COUNT8_CC : (TC Offset: 0x18) (R/W 8) COUNT8 COUNT8 Compare/Capture -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CC:8; /*!< bit: 0.. 7 Compare/Capture Value */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TC_COUNT8_CC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_COUNT8_CC_OFFSET 0x18 /**< \brief (TC_COUNT8_CC offset) COUNT8 Compare/Capture */ +#define TC_COUNT8_CC_RESETVALUE 0x00 /**< \brief (TC_COUNT8_CC reset_value) COUNT8 Compare/Capture */ + +#define TC_COUNT8_CC_CC_Pos 0 /**< \brief (TC_COUNT8_CC) Compare/Capture Value */ +#define TC_COUNT8_CC_CC_Msk (0xFFu << TC_COUNT8_CC_CC_Pos) +#define TC_COUNT8_CC_CC(value) ((TC_COUNT8_CC_CC_Msk & ((value) << TC_COUNT8_CC_CC_Pos))) +#define TC_COUNT8_CC_MASK 0xFFu /**< \brief (TC_COUNT8_CC) MASK Register */ + +/** \brief TC_COUNT8 hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* 8-bit Counter Mode */ + __IO TC_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 16) Control A */ + __IO TC_READREQ_Type READREQ; /**< \brief Offset: 0x02 (R/W 16) Read Request */ + __IO TC_CTRLBCLR_Type CTRLBCLR; /**< \brief Offset: 0x04 (R/W 8) Control B Clear */ + __IO TC_CTRLBSET_Type CTRLBSET; /**< \brief Offset: 0x05 (R/W 8) Control B Set */ + __IO TC_CTRLC_Type CTRLC; /**< \brief Offset: 0x06 (R/W 8) Control C */ + RoReg8 Reserved1[0x1]; + __IO TC_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x08 (R/W 8) Debug Control */ + RoReg8 Reserved2[0x1]; + __IO TC_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x0A (R/W 16) Event Control */ + __IO TC_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x0C (R/W 8) Interrupt Enable Clear */ + __IO TC_INTENSET_Type INTENSET; /**< \brief Offset: 0x0D (R/W 8) Interrupt Enable Set */ + __IO TC_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x0E (R/W 8) Interrupt Flag Status and Clear */ + __I TC_STATUS_Type STATUS; /**< \brief Offset: 0x0F (R/ 8) Status */ + __IO TC_COUNT8_COUNT_Type COUNT; /**< \brief Offset: 0x10 (R/W 8) COUNT8 Counter Value */ + RoReg8 Reserved3[0x3]; + __IO TC_COUNT8_PER_Type PER; /**< \brief Offset: 0x14 (R/W 8) COUNT8 Period Value */ + RoReg8 Reserved4[0x3]; + __IO TC_COUNT8_CC_Type CC[2]; /**< \brief Offset: 0x18 (R/W 8) COUNT8 Compare/Capture */ +} TcCount8; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief TC_COUNT16 hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* 16-bit Counter Mode */ + __IO TC_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 16) Control A */ + __IO TC_READREQ_Type READREQ; /**< \brief Offset: 0x02 (R/W 16) Read Request */ + __IO TC_CTRLBCLR_Type CTRLBCLR; /**< \brief Offset: 0x04 (R/W 8) Control B Clear */ + __IO TC_CTRLBSET_Type CTRLBSET; /**< \brief Offset: 0x05 (R/W 8) Control B Set */ + __IO TC_CTRLC_Type CTRLC; /**< \brief Offset: 0x06 (R/W 8) Control C */ + RoReg8 Reserved1[0x1]; + __IO TC_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x08 (R/W 8) Debug Control */ + RoReg8 Reserved2[0x1]; + __IO TC_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x0A (R/W 16) Event Control */ + __IO TC_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x0C (R/W 8) Interrupt Enable Clear */ + __IO TC_INTENSET_Type INTENSET; /**< \brief Offset: 0x0D (R/W 8) Interrupt Enable Set */ + __IO TC_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x0E (R/W 8) Interrupt Flag Status and Clear */ + __I TC_STATUS_Type STATUS; /**< \brief Offset: 0x0F (R/ 8) Status */ + __IO TC_COUNT16_COUNT_Type COUNT; /**< \brief Offset: 0x10 (R/W 16) COUNT16 Counter Value */ + RoReg8 Reserved3[0x6]; + __IO TC_COUNT16_CC_Type CC[2]; /**< \brief Offset: 0x18 (R/W 16) COUNT16 Compare/Capture */ +} TcCount16; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief TC_COUNT32 hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* 32-bit Counter Mode */ + __IO TC_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 16) Control A */ + __IO TC_READREQ_Type READREQ; /**< \brief Offset: 0x02 (R/W 16) Read Request */ + __IO TC_CTRLBCLR_Type CTRLBCLR; /**< \brief Offset: 0x04 (R/W 8) Control B Clear */ + __IO TC_CTRLBSET_Type CTRLBSET; /**< \brief Offset: 0x05 (R/W 8) Control B Set */ + __IO TC_CTRLC_Type CTRLC; /**< \brief Offset: 0x06 (R/W 8) Control C */ + RoReg8 Reserved1[0x1]; + __IO TC_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x08 (R/W 8) Debug Control */ + RoReg8 Reserved2[0x1]; + __IO TC_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x0A (R/W 16) Event Control */ + __IO TC_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x0C (R/W 8) Interrupt Enable Clear */ + __IO TC_INTENSET_Type INTENSET; /**< \brief Offset: 0x0D (R/W 8) Interrupt Enable Set */ + __IO TC_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x0E (R/W 8) Interrupt Flag Status and Clear */ + __I TC_STATUS_Type STATUS; /**< \brief Offset: 0x0F (R/ 8) Status */ + __IO TC_COUNT32_COUNT_Type COUNT; /**< \brief Offset: 0x10 (R/W 32) COUNT32 Counter Value */ + RoReg8 Reserved3[0x4]; + __IO TC_COUNT32_CC_Type CC[2]; /**< \brief Offset: 0x18 (R/W 32) COUNT32 Compare/Capture */ +} TcCount32; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + TcCount8 COUNT8; /**< \brief Offset: 0x00 8-bit Counter Mode */ + TcCount16 COUNT16; /**< \brief Offset: 0x00 16-bit Counter Mode */ + TcCount32 COUNT32; /**< \brief Offset: 0x00 32-bit Counter Mode */ +} Tc; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_TC_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/tcc.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/tcc.h new file mode 100644 index 0000000..24c55d8 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/tcc.h @@ -0,0 +1,1608 @@ +/** + * \file + * + * \brief Component description for TCC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_TCC_COMPONENT_ +#define _SAMD21_TCC_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR TCC */ +/* ========================================================================== */ +/** \addtogroup SAMD21_TCC Timer Counter Control */ +/*@{*/ + +#define TCC_U2213 +#define REV_TCC 0x101 + +/* -------- TCC_CTRLA : (TCC Offset: 0x00) (R/W 32) Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Software Reset */ + uint32_t ENABLE:1; /*!< bit: 1 Enable */ + uint32_t :3; /*!< bit: 2.. 4 Reserved */ + uint32_t RESOLUTION:2; /*!< bit: 5.. 6 Enhanced Resolution */ + uint32_t :1; /*!< bit: 7 Reserved */ + uint32_t PRESCALER:3; /*!< bit: 8..10 Prescaler */ + uint32_t RUNSTDBY:1; /*!< bit: 11 Run in Standby */ + uint32_t PRESCSYNC:2; /*!< bit: 12..13 Prescaler and Counter Synchronization Selection */ + uint32_t ALOCK:1; /*!< bit: 14 Auto Lock */ + uint32_t :9; /*!< bit: 15..23 Reserved */ + uint32_t CPTEN0:1; /*!< bit: 24 Capture Channel 0 Enable */ + uint32_t CPTEN1:1; /*!< bit: 25 Capture Channel 1 Enable */ + uint32_t CPTEN2:1; /*!< bit: 26 Capture Channel 2 Enable */ + uint32_t CPTEN3:1; /*!< bit: 27 Capture Channel 3 Enable */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :24; /*!< bit: 0..23 Reserved */ + uint32_t CPTEN:4; /*!< bit: 24..27 Capture Channel x Enable */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_CTRLA_OFFSET 0x00 /**< \brief (TCC_CTRLA offset) Control A */ +#define TCC_CTRLA_RESETVALUE 0x00000000 /**< \brief (TCC_CTRLA reset_value) Control A */ + +#define TCC_CTRLA_SWRST_Pos 0 /**< \brief (TCC_CTRLA) Software Reset */ +#define TCC_CTRLA_SWRST (0x1u << TCC_CTRLA_SWRST_Pos) +#define TCC_CTRLA_ENABLE_Pos 1 /**< \brief (TCC_CTRLA) Enable */ +#define TCC_CTRLA_ENABLE (0x1u << TCC_CTRLA_ENABLE_Pos) +#define TCC_CTRLA_RESOLUTION_Pos 5 /**< \brief (TCC_CTRLA) Enhanced Resolution */ +#define TCC_CTRLA_RESOLUTION_Msk (0x3u << TCC_CTRLA_RESOLUTION_Pos) +#define TCC_CTRLA_RESOLUTION(value) ((TCC_CTRLA_RESOLUTION_Msk & ((value) << TCC_CTRLA_RESOLUTION_Pos))) +#define TCC_CTRLA_RESOLUTION_NONE_Val 0x0u /**< \brief (TCC_CTRLA) Dithering is disabled */ +#define TCC_CTRLA_RESOLUTION_DITH4_Val 0x1u /**< \brief (TCC_CTRLA) Dithering is done every 16 PWM frames. PER[3:0] and CCx[3:0] contain dithering pattern selection. */ +#define TCC_CTRLA_RESOLUTION_DITH5_Val 0x2u /**< \brief (TCC_CTRLA) Dithering is done every 32 PWM frames. PER[4:0] and CCx[4:0] contain dithering pattern selection. */ +#define TCC_CTRLA_RESOLUTION_DITH6_Val 0x3u /**< \brief (TCC_CTRLA) Dithering is done every 64 PWM frames. PER[5:0] and CCx[5:0] contain dithering pattern selection. */ +#define TCC_CTRLA_RESOLUTION_NONE (TCC_CTRLA_RESOLUTION_NONE_Val << TCC_CTRLA_RESOLUTION_Pos) +#define TCC_CTRLA_RESOLUTION_DITH4 (TCC_CTRLA_RESOLUTION_DITH4_Val << TCC_CTRLA_RESOLUTION_Pos) +#define TCC_CTRLA_RESOLUTION_DITH5 (TCC_CTRLA_RESOLUTION_DITH5_Val << TCC_CTRLA_RESOLUTION_Pos) +#define TCC_CTRLA_RESOLUTION_DITH6 (TCC_CTRLA_RESOLUTION_DITH6_Val << TCC_CTRLA_RESOLUTION_Pos) +#define TCC_CTRLA_PRESCALER_Pos 8 /**< \brief (TCC_CTRLA) Prescaler */ +#define TCC_CTRLA_PRESCALER_Msk (0x7u << TCC_CTRLA_PRESCALER_Pos) +#define TCC_CTRLA_PRESCALER(value) ((TCC_CTRLA_PRESCALER_Msk & ((value) << TCC_CTRLA_PRESCALER_Pos))) +#define TCC_CTRLA_PRESCALER_DIV1_Val 0x0u /**< \brief (TCC_CTRLA) Prescaler: GCLK_TCC */ +#define TCC_CTRLA_PRESCALER_DIV2_Val 0x1u /**< \brief (TCC_CTRLA) Prescaler: GCLK_TCC/2 */ +#define TCC_CTRLA_PRESCALER_DIV4_Val 0x2u /**< \brief (TCC_CTRLA) Prescaler: GCLK_TCC/4 */ +#define TCC_CTRLA_PRESCALER_DIV8_Val 0x3u /**< \brief (TCC_CTRLA) Prescaler: GCLK_TCC/8 */ +#define TCC_CTRLA_PRESCALER_DIV16_Val 0x4u /**< \brief (TCC_CTRLA) Prescaler: GCLK_TCC/16 */ +#define TCC_CTRLA_PRESCALER_DIV64_Val 0x5u /**< \brief (TCC_CTRLA) Prescaler: GCLK_TCC/64 */ +#define TCC_CTRLA_PRESCALER_DIV256_Val 0x6u /**< \brief (TCC_CTRLA) Prescaler: GCLK_TCC/256 */ +#define TCC_CTRLA_PRESCALER_DIV1024_Val 0x7u /**< \brief (TCC_CTRLA) Prescaler: GCLK_TCC/1024 */ +#define TCC_CTRLA_PRESCALER_DIV1 (TCC_CTRLA_PRESCALER_DIV1_Val << TCC_CTRLA_PRESCALER_Pos) +#define TCC_CTRLA_PRESCALER_DIV2 (TCC_CTRLA_PRESCALER_DIV2_Val << TCC_CTRLA_PRESCALER_Pos) +#define TCC_CTRLA_PRESCALER_DIV4 (TCC_CTRLA_PRESCALER_DIV4_Val << TCC_CTRLA_PRESCALER_Pos) +#define TCC_CTRLA_PRESCALER_DIV8 (TCC_CTRLA_PRESCALER_DIV8_Val << TCC_CTRLA_PRESCALER_Pos) +#define TCC_CTRLA_PRESCALER_DIV16 (TCC_CTRLA_PRESCALER_DIV16_Val << TCC_CTRLA_PRESCALER_Pos) +#define TCC_CTRLA_PRESCALER_DIV64 (TCC_CTRLA_PRESCALER_DIV64_Val << TCC_CTRLA_PRESCALER_Pos) +#define TCC_CTRLA_PRESCALER_DIV256 (TCC_CTRLA_PRESCALER_DIV256_Val << TCC_CTRLA_PRESCALER_Pos) +#define TCC_CTRLA_PRESCALER_DIV1024 (TCC_CTRLA_PRESCALER_DIV1024_Val << TCC_CTRLA_PRESCALER_Pos) +#define TCC_CTRLA_RUNSTDBY_Pos 11 /**< \brief (TCC_CTRLA) Run in Standby */ +#define TCC_CTRLA_RUNSTDBY (0x1u << TCC_CTRLA_RUNSTDBY_Pos) +#define TCC_CTRLA_PRESCSYNC_Pos 12 /**< \brief (TCC_CTRLA) Prescaler and Counter Synchronization Selection */ +#define TCC_CTRLA_PRESCSYNC_Msk (0x3u << TCC_CTRLA_PRESCSYNC_Pos) +#define TCC_CTRLA_PRESCSYNC(value) ((TCC_CTRLA_PRESCSYNC_Msk & ((value) << TCC_CTRLA_PRESCSYNC_Pos))) +#define TCC_CTRLA_PRESCSYNC_GCLK_Val 0x0u /**< \brief (TCC_CTRLA) Reload or reset Counter on next GCLK */ +#define TCC_CTRLA_PRESCSYNC_PRESC_Val 0x1u /**< \brief (TCC_CTRLA) Reload or reset Counter on next prescaler clock */ +#define TCC_CTRLA_PRESCSYNC_RESYNC_Val 0x2u /**< \brief (TCC_CTRLA) Reload or reset Counter on next GCLK */ +#define TCC_CTRLA_PRESCSYNC_GCLK (TCC_CTRLA_PRESCSYNC_GCLK_Val << TCC_CTRLA_PRESCSYNC_Pos) +#define TCC_CTRLA_PRESCSYNC_PRESC (TCC_CTRLA_PRESCSYNC_PRESC_Val << TCC_CTRLA_PRESCSYNC_Pos) +#define TCC_CTRLA_PRESCSYNC_RESYNC (TCC_CTRLA_PRESCSYNC_RESYNC_Val << TCC_CTRLA_PRESCSYNC_Pos) +#define TCC_CTRLA_ALOCK_Pos 14 /**< \brief (TCC_CTRLA) Auto Lock */ +#define TCC_CTRLA_ALOCK (0x1u << TCC_CTRLA_ALOCK_Pos) +#define TCC_CTRLA_CPTEN0_Pos 24 /**< \brief (TCC_CTRLA) Capture Channel 0 Enable */ +#define TCC_CTRLA_CPTEN0 (1 << TCC_CTRLA_CPTEN0_Pos) +#define TCC_CTRLA_CPTEN1_Pos 25 /**< \brief (TCC_CTRLA) Capture Channel 1 Enable */ +#define TCC_CTRLA_CPTEN1 (1 << TCC_CTRLA_CPTEN1_Pos) +#define TCC_CTRLA_CPTEN2_Pos 26 /**< \brief (TCC_CTRLA) Capture Channel 2 Enable */ +#define TCC_CTRLA_CPTEN2 (1 << TCC_CTRLA_CPTEN2_Pos) +#define TCC_CTRLA_CPTEN3_Pos 27 /**< \brief (TCC_CTRLA) Capture Channel 3 Enable */ +#define TCC_CTRLA_CPTEN3 (1 << TCC_CTRLA_CPTEN3_Pos) +#define TCC_CTRLA_CPTEN_Pos 24 /**< \brief (TCC_CTRLA) Capture Channel x Enable */ +#define TCC_CTRLA_CPTEN_Msk (0xFu << TCC_CTRLA_CPTEN_Pos) +#define TCC_CTRLA_CPTEN(value) ((TCC_CTRLA_CPTEN_Msk & ((value) << TCC_CTRLA_CPTEN_Pos))) +#define TCC_CTRLA_MASK 0x0F007F63u /**< \brief (TCC_CTRLA) MASK Register */ + +/* -------- TCC_CTRLBCLR : (TCC Offset: 0x04) (R/W 8) Control B Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DIR:1; /*!< bit: 0 Counter Direction */ + uint8_t LUPD:1; /*!< bit: 1 Lock Update */ + uint8_t ONESHOT:1; /*!< bit: 2 One-Shot */ + uint8_t IDXCMD:2; /*!< bit: 3.. 4 Ramp Index Command */ + uint8_t CMD:3; /*!< bit: 5.. 7 TCC Command */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TCC_CTRLBCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_CTRLBCLR_OFFSET 0x04 /**< \brief (TCC_CTRLBCLR offset) Control B Clear */ +#define TCC_CTRLBCLR_RESETVALUE 0x00 /**< \brief (TCC_CTRLBCLR reset_value) Control B Clear */ + +#define TCC_CTRLBCLR_DIR_Pos 0 /**< \brief (TCC_CTRLBCLR) Counter Direction */ +#define TCC_CTRLBCLR_DIR (0x1u << TCC_CTRLBCLR_DIR_Pos) +#define TCC_CTRLBCLR_LUPD_Pos 1 /**< \brief (TCC_CTRLBCLR) Lock Update */ +#define TCC_CTRLBCLR_LUPD (0x1u << TCC_CTRLBCLR_LUPD_Pos) +#define TCC_CTRLBCLR_ONESHOT_Pos 2 /**< \brief (TCC_CTRLBCLR) One-Shot */ +#define TCC_CTRLBCLR_ONESHOT (0x1u << TCC_CTRLBCLR_ONESHOT_Pos) +#define TCC_CTRLBCLR_IDXCMD_Pos 3 /**< \brief (TCC_CTRLBCLR) Ramp Index Command */ +#define TCC_CTRLBCLR_IDXCMD_Msk (0x3u << TCC_CTRLBCLR_IDXCMD_Pos) +#define TCC_CTRLBCLR_IDXCMD(value) ((TCC_CTRLBCLR_IDXCMD_Msk & ((value) << TCC_CTRLBCLR_IDXCMD_Pos))) +#define TCC_CTRLBCLR_IDXCMD_DISABLE_Val 0x0u /**< \brief (TCC_CTRLBCLR) Command disabled: IDX toggles between cycles A and B */ +#define TCC_CTRLBCLR_IDXCMD_SET_Val 0x1u /**< \brief (TCC_CTRLBCLR) Set IDX: cycle B will be forced in the next cycle */ +#define TCC_CTRLBCLR_IDXCMD_CLEAR_Val 0x2u /**< \brief (TCC_CTRLBCLR) Clear IDX: cycle A will be forced in next cycle */ +#define TCC_CTRLBCLR_IDXCMD_HOLD_Val 0x3u /**< \brief (TCC_CTRLBCLR) Hold IDX: the next cycle will be the same as the current cycle. */ +#define TCC_CTRLBCLR_IDXCMD_DISABLE (TCC_CTRLBCLR_IDXCMD_DISABLE_Val << TCC_CTRLBCLR_IDXCMD_Pos) +#define TCC_CTRLBCLR_IDXCMD_SET (TCC_CTRLBCLR_IDXCMD_SET_Val << TCC_CTRLBCLR_IDXCMD_Pos) +#define TCC_CTRLBCLR_IDXCMD_CLEAR (TCC_CTRLBCLR_IDXCMD_CLEAR_Val << TCC_CTRLBCLR_IDXCMD_Pos) +#define TCC_CTRLBCLR_IDXCMD_HOLD (TCC_CTRLBCLR_IDXCMD_HOLD_Val << TCC_CTRLBCLR_IDXCMD_Pos) +#define TCC_CTRLBCLR_CMD_Pos 5 /**< \brief (TCC_CTRLBCLR) TCC Command */ +#define TCC_CTRLBCLR_CMD_Msk (0x7u << TCC_CTRLBCLR_CMD_Pos) +#define TCC_CTRLBCLR_CMD(value) ((TCC_CTRLBCLR_CMD_Msk & ((value) << TCC_CTRLBCLR_CMD_Pos))) +#define TCC_CTRLBCLR_CMD_NONE_Val 0x0u /**< \brief (TCC_CTRLBCLR) No action */ +#define TCC_CTRLBCLR_CMD_RETRIGGER_Val 0x1u /**< \brief (TCC_CTRLBCLR) Clear start, restart or retrigger */ +#define TCC_CTRLBCLR_CMD_STOP_Val 0x2u /**< \brief (TCC_CTRLBCLR) Force stop */ +#define TCC_CTRLBCLR_CMD_UPDATE_Val 0x3u /**< \brief (TCC_CTRLBCLR) Force update of double buffered registers */ +#define TCC_CTRLBCLR_CMD_READSYNC_Val 0x4u /**< \brief (TCC_CTRLBCLR) Force COUNT read synchronization */ +#define TCC_CTRLBCLR_CMD_NONE (TCC_CTRLBCLR_CMD_NONE_Val << TCC_CTRLBCLR_CMD_Pos) +#define TCC_CTRLBCLR_CMD_RETRIGGER (TCC_CTRLBCLR_CMD_RETRIGGER_Val << TCC_CTRLBCLR_CMD_Pos) +#define TCC_CTRLBCLR_CMD_STOP (TCC_CTRLBCLR_CMD_STOP_Val << TCC_CTRLBCLR_CMD_Pos) +#define TCC_CTRLBCLR_CMD_UPDATE (TCC_CTRLBCLR_CMD_UPDATE_Val << TCC_CTRLBCLR_CMD_Pos) +#define TCC_CTRLBCLR_CMD_READSYNC (TCC_CTRLBCLR_CMD_READSYNC_Val << TCC_CTRLBCLR_CMD_Pos) +#define TCC_CTRLBCLR_MASK 0xFFu /**< \brief (TCC_CTRLBCLR) MASK Register */ + +/* -------- TCC_CTRLBSET : (TCC Offset: 0x05) (R/W 8) Control B Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DIR:1; /*!< bit: 0 Counter Direction */ + uint8_t LUPD:1; /*!< bit: 1 Lock update */ + uint8_t ONESHOT:1; /*!< bit: 2 One-Shot */ + uint8_t IDXCMD:2; /*!< bit: 3.. 4 Ramp Index Command */ + uint8_t CMD:3; /*!< bit: 5.. 7 TCC Command */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TCC_CTRLBSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_CTRLBSET_OFFSET 0x05 /**< \brief (TCC_CTRLBSET offset) Control B Set */ +#define TCC_CTRLBSET_RESETVALUE 0x00 /**< \brief (TCC_CTRLBSET reset_value) Control B Set */ + +#define TCC_CTRLBSET_DIR_Pos 0 /**< \brief (TCC_CTRLBSET) Counter Direction */ +#define TCC_CTRLBSET_DIR (0x1u << TCC_CTRLBSET_DIR_Pos) +#define TCC_CTRLBSET_LUPD_Pos 1 /**< \brief (TCC_CTRLBSET) Lock update */ +#define TCC_CTRLBSET_LUPD (0x1u << TCC_CTRLBSET_LUPD_Pos) +#define TCC_CTRLBSET_ONESHOT_Pos 2 /**< \brief (TCC_CTRLBSET) One-Shot */ +#define TCC_CTRLBSET_ONESHOT (0x1u << TCC_CTRLBSET_ONESHOT_Pos) +#define TCC_CTRLBSET_IDXCMD_Pos 3 /**< \brief (TCC_CTRLBSET) Ramp Index Command */ +#define TCC_CTRLBSET_IDXCMD_Msk (0x3u << TCC_CTRLBSET_IDXCMD_Pos) +#define TCC_CTRLBSET_IDXCMD(value) ((TCC_CTRLBSET_IDXCMD_Msk & ((value) << TCC_CTRLBSET_IDXCMD_Pos))) +#define TCC_CTRLBSET_IDXCMD_DISABLE_Val 0x0u /**< \brief (TCC_CTRLBSET) */ +#define TCC_CTRLBSET_IDXCMD_SET_Val 0x1u /**< \brief (TCC_CTRLBSET) */ +#define TCC_CTRLBSET_IDXCMD_CLEAR_Val 0x2u /**< \brief (TCC_CTRLBSET) */ +#define TCC_CTRLBSET_IDXCMD_HOLD_Val 0x3u /**< \brief (TCC_CTRLBSET) */ +#define TCC_CTRLBSET_IDXCMD_DISABLE (TCC_CTRLBSET_IDXCMD_DISABLE_Val << TCC_CTRLBSET_IDXCMD_Pos) +#define TCC_CTRLBSET_IDXCMD_SET (TCC_CTRLBSET_IDXCMD_SET_Val << TCC_CTRLBSET_IDXCMD_Pos) +#define TCC_CTRLBSET_IDXCMD_CLEAR (TCC_CTRLBSET_IDXCMD_CLEAR_Val << TCC_CTRLBSET_IDXCMD_Pos) +#define TCC_CTRLBSET_IDXCMD_HOLD (TCC_CTRLBSET_IDXCMD_HOLD_Val << TCC_CTRLBSET_IDXCMD_Pos) +#define TCC_CTRLBSET_CMD_Pos 5 /**< \brief (TCC_CTRLBSET) TCC Command */ +#define TCC_CTRLBSET_CMD_Msk (0x7u << TCC_CTRLBSET_CMD_Pos) +#define TCC_CTRLBSET_CMD(value) ((TCC_CTRLBSET_CMD_Msk & ((value) << TCC_CTRLBSET_CMD_Pos))) +#define TCC_CTRLBSET_CMD_NONE_Val 0x0u /**< \brief (TCC_CTRLBSET) */ +#define TCC_CTRLBSET_CMD_RETRIGGER_Val 0x1u /**< \brief (TCC_CTRLBSET) */ +#define TCC_CTRLBSET_CMD_STOP_Val 0x2u /**< \brief (TCC_CTRLBSET) */ +#define TCC_CTRLBSET_CMD_UPDATE_Val 0x3u /**< \brief (TCC_CTRLBSET) */ +#define TCC_CTRLBSET_CMD_READSYNC_Val 0x4u /**< \brief (TCC_CTRLBSET) */ +#define TCC_CTRLBSET_CMD_NONE (TCC_CTRLBSET_CMD_NONE_Val << TCC_CTRLBSET_CMD_Pos) +#define TCC_CTRLBSET_CMD_RETRIGGER (TCC_CTRLBSET_CMD_RETRIGGER_Val << TCC_CTRLBSET_CMD_Pos) +#define TCC_CTRLBSET_CMD_STOP (TCC_CTRLBSET_CMD_STOP_Val << TCC_CTRLBSET_CMD_Pos) +#define TCC_CTRLBSET_CMD_UPDATE (TCC_CTRLBSET_CMD_UPDATE_Val << TCC_CTRLBSET_CMD_Pos) +#define TCC_CTRLBSET_CMD_READSYNC (TCC_CTRLBSET_CMD_READSYNC_Val << TCC_CTRLBSET_CMD_Pos) +#define TCC_CTRLBSET_MASK 0xFFu /**< \brief (TCC_CTRLBSET) MASK Register */ + +/* -------- TCC_SYNCBUSY : (TCC Offset: 0x08) (R/ 32) Synchronization Busy -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Swrst Busy */ + uint32_t ENABLE:1; /*!< bit: 1 Enable Busy */ + uint32_t CTRLB:1; /*!< bit: 2 Ctrlb Busy */ + uint32_t STATUS:1; /*!< bit: 3 Status Busy */ + uint32_t COUNT:1; /*!< bit: 4 Count Busy */ + uint32_t PATT:1; /*!< bit: 5 Pattern Busy */ + uint32_t WAVE:1; /*!< bit: 6 Wave Busy */ + uint32_t PER:1; /*!< bit: 7 Period busy */ + uint32_t CC0:1; /*!< bit: 8 Compare Channel Buffer 0 Busy */ + uint32_t CC1:1; /*!< bit: 9 Compare Channel Buffer 1 Busy */ + uint32_t CC2:1; /*!< bit: 10 Compare Channel Buffer 2 Busy */ + uint32_t CC3:1; /*!< bit: 11 Compare Channel Buffer 3 Busy */ + uint32_t :4; /*!< bit: 12..15 Reserved */ + uint32_t PATTB:1; /*!< bit: 16 Pattern Buffer Busy */ + uint32_t WAVEB:1; /*!< bit: 17 Wave Buffer Busy */ + uint32_t PERB:1; /*!< bit: 18 Period Buffer Busy */ + uint32_t CCB0:1; /*!< bit: 19 Compare Channel Buffer 0 Busy */ + uint32_t CCB1:1; /*!< bit: 20 Compare Channel Buffer 1 Busy */ + uint32_t CCB2:1; /*!< bit: 21 Compare Channel Buffer 2 Busy */ + uint32_t CCB3:1; /*!< bit: 22 Compare Channel Buffer 3 Busy */ + uint32_t :9; /*!< bit: 23..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :8; /*!< bit: 0.. 7 Reserved */ + uint32_t CC:4; /*!< bit: 8..11 Compare Channel Buffer x Busy */ + uint32_t :7; /*!< bit: 12..18 Reserved */ + uint32_t CCB:4; /*!< bit: 19..22 Compare Channel Buffer x Busy */ + uint32_t :9; /*!< bit: 23..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_SYNCBUSY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_SYNCBUSY_OFFSET 0x08 /**< \brief (TCC_SYNCBUSY offset) Synchronization Busy */ +#define TCC_SYNCBUSY_RESETVALUE 0x00000000 /**< \brief (TCC_SYNCBUSY reset_value) Synchronization Busy */ + +#define TCC_SYNCBUSY_SWRST_Pos 0 /**< \brief (TCC_SYNCBUSY) Swrst Busy */ +#define TCC_SYNCBUSY_SWRST (0x1u << TCC_SYNCBUSY_SWRST_Pos) +#define TCC_SYNCBUSY_ENABLE_Pos 1 /**< \brief (TCC_SYNCBUSY) Enable Busy */ +#define TCC_SYNCBUSY_ENABLE (0x1u << TCC_SYNCBUSY_ENABLE_Pos) +#define TCC_SYNCBUSY_CTRLB_Pos 2 /**< \brief (TCC_SYNCBUSY) Ctrlb Busy */ +#define TCC_SYNCBUSY_CTRLB (0x1u << TCC_SYNCBUSY_CTRLB_Pos) +#define TCC_SYNCBUSY_STATUS_Pos 3 /**< \brief (TCC_SYNCBUSY) Status Busy */ +#define TCC_SYNCBUSY_STATUS (0x1u << TCC_SYNCBUSY_STATUS_Pos) +#define TCC_SYNCBUSY_COUNT_Pos 4 /**< \brief (TCC_SYNCBUSY) Count Busy */ +#define TCC_SYNCBUSY_COUNT (0x1u << TCC_SYNCBUSY_COUNT_Pos) +#define TCC_SYNCBUSY_PATT_Pos 5 /**< \brief (TCC_SYNCBUSY) Pattern Busy */ +#define TCC_SYNCBUSY_PATT (0x1u << TCC_SYNCBUSY_PATT_Pos) +#define TCC_SYNCBUSY_WAVE_Pos 6 /**< \brief (TCC_SYNCBUSY) Wave Busy */ +#define TCC_SYNCBUSY_WAVE (0x1u << TCC_SYNCBUSY_WAVE_Pos) +#define TCC_SYNCBUSY_PER_Pos 7 /**< \brief (TCC_SYNCBUSY) Period busy */ +#define TCC_SYNCBUSY_PER (0x1u << TCC_SYNCBUSY_PER_Pos) +#define TCC_SYNCBUSY_CC0_Pos 8 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer 0 Busy */ +#define TCC_SYNCBUSY_CC0 (1 << TCC_SYNCBUSY_CC0_Pos) +#define TCC_SYNCBUSY_CC1_Pos 9 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer 1 Busy */ +#define TCC_SYNCBUSY_CC1 (1 << TCC_SYNCBUSY_CC1_Pos) +#define TCC_SYNCBUSY_CC2_Pos 10 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer 2 Busy */ +#define TCC_SYNCBUSY_CC2 (1 << TCC_SYNCBUSY_CC2_Pos) +#define TCC_SYNCBUSY_CC3_Pos 11 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer 3 Busy */ +#define TCC_SYNCBUSY_CC3 (1 << TCC_SYNCBUSY_CC3_Pos) +#define TCC_SYNCBUSY_CC_Pos 8 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer x Busy */ +#define TCC_SYNCBUSY_CC_Msk (0xFu << TCC_SYNCBUSY_CC_Pos) +#define TCC_SYNCBUSY_CC(value) ((TCC_SYNCBUSY_CC_Msk & ((value) << TCC_SYNCBUSY_CC_Pos))) +#define TCC_SYNCBUSY_PATTB_Pos 16 /**< \brief (TCC_SYNCBUSY) Pattern Buffer Busy */ +#define TCC_SYNCBUSY_PATTB (0x1u << TCC_SYNCBUSY_PATTB_Pos) +#define TCC_SYNCBUSY_WAVEB_Pos 17 /**< \brief (TCC_SYNCBUSY) Wave Buffer Busy */ +#define TCC_SYNCBUSY_WAVEB (0x1u << TCC_SYNCBUSY_WAVEB_Pos) +#define TCC_SYNCBUSY_PERB_Pos 18 /**< \brief (TCC_SYNCBUSY) Period Buffer Busy */ +#define TCC_SYNCBUSY_PERB (0x1u << TCC_SYNCBUSY_PERB_Pos) +#define TCC_SYNCBUSY_CCB0_Pos 19 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer 0 Busy */ +#define TCC_SYNCBUSY_CCB0 (1 << TCC_SYNCBUSY_CCB0_Pos) +#define TCC_SYNCBUSY_CCB1_Pos 20 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer 1 Busy */ +#define TCC_SYNCBUSY_CCB1 (1 << TCC_SYNCBUSY_CCB1_Pos) +#define TCC_SYNCBUSY_CCB2_Pos 21 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer 2 Busy */ +#define TCC_SYNCBUSY_CCB2 (1 << TCC_SYNCBUSY_CCB2_Pos) +#define TCC_SYNCBUSY_CCB3_Pos 22 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer 3 Busy */ +#define TCC_SYNCBUSY_CCB3 (1 << TCC_SYNCBUSY_CCB3_Pos) +#define TCC_SYNCBUSY_CCB_Pos 19 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer x Busy */ +#define TCC_SYNCBUSY_CCB_Msk (0xFu << TCC_SYNCBUSY_CCB_Pos) +#define TCC_SYNCBUSY_CCB(value) ((TCC_SYNCBUSY_CCB_Msk & ((value) << TCC_SYNCBUSY_CCB_Pos))) +#define TCC_SYNCBUSY_MASK 0x007F0FFFu /**< \brief (TCC_SYNCBUSY) MASK Register */ + +/* -------- TCC_FCTRLA : (TCC Offset: 0x0C) (R/W 32) Recoverable FaultA Configuration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SRC:2; /*!< bit: 0.. 1 FaultA Source */ + uint32_t :1; /*!< bit: 2 Reserved */ + uint32_t KEEP:1; /*!< bit: 3 FaultA Keeper */ + uint32_t QUAL:1; /*!< bit: 4 FaultA Qualification */ + uint32_t BLANK:2; /*!< bit: 5.. 6 FaultA Blanking Mode */ + uint32_t RESTART:1; /*!< bit: 7 FaultA Restart */ + uint32_t HALT:2; /*!< bit: 8.. 9 FaultA Halt Mode */ + uint32_t CHSEL:2; /*!< bit: 10..11 FaultA Capture Channel */ + uint32_t CAPTURE:3; /*!< bit: 12..14 FaultA Capture Action */ + uint32_t :1; /*!< bit: 15 Reserved */ + uint32_t BLANKVAL:8; /*!< bit: 16..23 FaultA Blanking Time */ + uint32_t FILTERVAL:4; /*!< bit: 24..27 FaultA Filter Value */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_FCTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_FCTRLA_OFFSET 0x0C /**< \brief (TCC_FCTRLA offset) Recoverable FaultA Configuration */ +#define TCC_FCTRLA_RESETVALUE 0x00000000 /**< \brief (TCC_FCTRLA reset_value) Recoverable FaultA Configuration */ + +#define TCC_FCTRLA_SRC_Pos 0 /**< \brief (TCC_FCTRLA) FaultA Source */ +#define TCC_FCTRLA_SRC_Msk (0x3u << TCC_FCTRLA_SRC_Pos) +#define TCC_FCTRLA_SRC(value) ((TCC_FCTRLA_SRC_Msk & ((value) << TCC_FCTRLA_SRC_Pos))) +#define TCC_FCTRLA_SRC_DISABLE_Val 0x0u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_SRC_ENABLE_Val 0x1u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_SRC_INVERT_Val 0x2u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_SRC_ALTFAULT_Val 0x3u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_SRC_DISABLE (TCC_FCTRLA_SRC_DISABLE_Val << TCC_FCTRLA_SRC_Pos) +#define TCC_FCTRLA_SRC_ENABLE (TCC_FCTRLA_SRC_ENABLE_Val << TCC_FCTRLA_SRC_Pos) +#define TCC_FCTRLA_SRC_INVERT (TCC_FCTRLA_SRC_INVERT_Val << TCC_FCTRLA_SRC_Pos) +#define TCC_FCTRLA_SRC_ALTFAULT (TCC_FCTRLA_SRC_ALTFAULT_Val << TCC_FCTRLA_SRC_Pos) +#define TCC_FCTRLA_KEEP_Pos 3 /**< \brief (TCC_FCTRLA) FaultA Keeper */ +#define TCC_FCTRLA_KEEP (0x1u << TCC_FCTRLA_KEEP_Pos) +#define TCC_FCTRLA_QUAL_Pos 4 /**< \brief (TCC_FCTRLA) FaultA Qualification */ +#define TCC_FCTRLA_QUAL (0x1u << TCC_FCTRLA_QUAL_Pos) +#define TCC_FCTRLA_BLANK_Pos 5 /**< \brief (TCC_FCTRLA) FaultA Blanking Mode */ +#define TCC_FCTRLA_BLANK_Msk (0x3u << TCC_FCTRLA_BLANK_Pos) +#define TCC_FCTRLA_BLANK(value) ((TCC_FCTRLA_BLANK_Msk & ((value) << TCC_FCTRLA_BLANK_Pos))) +#define TCC_FCTRLA_BLANK_DISABLE_Val 0x0u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_BLANK_RISE_Val 0x1u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_BLANK_FALL_Val 0x2u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_BLANK_BOTH_Val 0x3u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_BLANK_DISABLE (TCC_FCTRLA_BLANK_DISABLE_Val << TCC_FCTRLA_BLANK_Pos) +#define TCC_FCTRLA_BLANK_RISE (TCC_FCTRLA_BLANK_RISE_Val << TCC_FCTRLA_BLANK_Pos) +#define TCC_FCTRLA_BLANK_FALL (TCC_FCTRLA_BLANK_FALL_Val << TCC_FCTRLA_BLANK_Pos) +#define TCC_FCTRLA_BLANK_BOTH (TCC_FCTRLA_BLANK_BOTH_Val << TCC_FCTRLA_BLANK_Pos) +#define TCC_FCTRLA_RESTART_Pos 7 /**< \brief (TCC_FCTRLA) FaultA Restart */ +#define TCC_FCTRLA_RESTART (0x1u << TCC_FCTRLA_RESTART_Pos) +#define TCC_FCTRLA_HALT_Pos 8 /**< \brief (TCC_FCTRLA) FaultA Halt Mode */ +#define TCC_FCTRLA_HALT_Msk (0x3u << TCC_FCTRLA_HALT_Pos) +#define TCC_FCTRLA_HALT(value) ((TCC_FCTRLA_HALT_Msk & ((value) << TCC_FCTRLA_HALT_Pos))) +#define TCC_FCTRLA_HALT_DISABLE_Val 0x0u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_HALT_HW_Val 0x1u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_HALT_SW_Val 0x2u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_HALT_NR_Val 0x3u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_HALT_DISABLE (TCC_FCTRLA_HALT_DISABLE_Val << TCC_FCTRLA_HALT_Pos) +#define TCC_FCTRLA_HALT_HW (TCC_FCTRLA_HALT_HW_Val << TCC_FCTRLA_HALT_Pos) +#define TCC_FCTRLA_HALT_SW (TCC_FCTRLA_HALT_SW_Val << TCC_FCTRLA_HALT_Pos) +#define TCC_FCTRLA_HALT_NR (TCC_FCTRLA_HALT_NR_Val << TCC_FCTRLA_HALT_Pos) +#define TCC_FCTRLA_CHSEL_Pos 10 /**< \brief (TCC_FCTRLA) FaultA Capture Channel */ +#define TCC_FCTRLA_CHSEL_Msk (0x3u << TCC_FCTRLA_CHSEL_Pos) +#define TCC_FCTRLA_CHSEL(value) ((TCC_FCTRLA_CHSEL_Msk & ((value) << TCC_FCTRLA_CHSEL_Pos))) +#define TCC_FCTRLA_CHSEL_CC0_Val 0x0u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CHSEL_CC1_Val 0x1u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CHSEL_CC2_Val 0x2u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CHSEL_CC3_Val 0x3u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CHSEL_CC0 (TCC_FCTRLA_CHSEL_CC0_Val << TCC_FCTRLA_CHSEL_Pos) +#define TCC_FCTRLA_CHSEL_CC1 (TCC_FCTRLA_CHSEL_CC1_Val << TCC_FCTRLA_CHSEL_Pos) +#define TCC_FCTRLA_CHSEL_CC2 (TCC_FCTRLA_CHSEL_CC2_Val << TCC_FCTRLA_CHSEL_Pos) +#define TCC_FCTRLA_CHSEL_CC3 (TCC_FCTRLA_CHSEL_CC3_Val << TCC_FCTRLA_CHSEL_Pos) +#define TCC_FCTRLA_CAPTURE_Pos 12 /**< \brief (TCC_FCTRLA) FaultA Capture Action */ +#define TCC_FCTRLA_CAPTURE_Msk (0x7u << TCC_FCTRLA_CAPTURE_Pos) +#define TCC_FCTRLA_CAPTURE(value) ((TCC_FCTRLA_CAPTURE_Msk & ((value) << TCC_FCTRLA_CAPTURE_Pos))) +#define TCC_FCTRLA_CAPTURE_DISABLE_Val 0x0u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CAPTURE_CAPT_Val 0x1u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CAPTURE_CAPTMIN_Val 0x2u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CAPTURE_CAPTMAX_Val 0x3u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CAPTURE_LOCMIN_Val 0x4u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CAPTURE_LOCMAX_Val 0x5u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CAPTURE_DERIV0_Val 0x6u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CAPTURE_DISABLE (TCC_FCTRLA_CAPTURE_DISABLE_Val << TCC_FCTRLA_CAPTURE_Pos) +#define TCC_FCTRLA_CAPTURE_CAPT (TCC_FCTRLA_CAPTURE_CAPT_Val << TCC_FCTRLA_CAPTURE_Pos) +#define TCC_FCTRLA_CAPTURE_CAPTMIN (TCC_FCTRLA_CAPTURE_CAPTMIN_Val << TCC_FCTRLA_CAPTURE_Pos) +#define TCC_FCTRLA_CAPTURE_CAPTMAX (TCC_FCTRLA_CAPTURE_CAPTMAX_Val << TCC_FCTRLA_CAPTURE_Pos) +#define TCC_FCTRLA_CAPTURE_LOCMIN (TCC_FCTRLA_CAPTURE_LOCMIN_Val << TCC_FCTRLA_CAPTURE_Pos) +#define TCC_FCTRLA_CAPTURE_LOCMAX (TCC_FCTRLA_CAPTURE_LOCMAX_Val << TCC_FCTRLA_CAPTURE_Pos) +#define TCC_FCTRLA_CAPTURE_DERIV0 (TCC_FCTRLA_CAPTURE_DERIV0_Val << TCC_FCTRLA_CAPTURE_Pos) +#define TCC_FCTRLA_BLANKVAL_Pos 16 /**< \brief (TCC_FCTRLA) FaultA Blanking Time */ +#define TCC_FCTRLA_BLANKVAL_Msk (0xFFu << TCC_FCTRLA_BLANKVAL_Pos) +#define TCC_FCTRLA_BLANKVAL(value) ((TCC_FCTRLA_BLANKVAL_Msk & ((value) << TCC_FCTRLA_BLANKVAL_Pos))) +#define TCC_FCTRLA_FILTERVAL_Pos 24 /**< \brief (TCC_FCTRLA) FaultA Filter Value */ +#define TCC_FCTRLA_FILTERVAL_Msk (0xFu << TCC_FCTRLA_FILTERVAL_Pos) +#define TCC_FCTRLA_FILTERVAL(value) ((TCC_FCTRLA_FILTERVAL_Msk & ((value) << TCC_FCTRLA_FILTERVAL_Pos))) +#define TCC_FCTRLA_MASK 0x0FFF7FFBu /**< \brief (TCC_FCTRLA) MASK Register */ + +/* -------- TCC_FCTRLB : (TCC Offset: 0x10) (R/W 32) Recoverable FaultB Configuration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SRC:2; /*!< bit: 0.. 1 FaultB Source */ + uint32_t :1; /*!< bit: 2 Reserved */ + uint32_t KEEP:1; /*!< bit: 3 FaultB Keeper */ + uint32_t QUAL:1; /*!< bit: 4 FaultB Qualification */ + uint32_t BLANK:2; /*!< bit: 5.. 6 FaultB Blanking Mode */ + uint32_t RESTART:1; /*!< bit: 7 FaultB Restart */ + uint32_t HALT:2; /*!< bit: 8.. 9 FaultB Halt Mode */ + uint32_t CHSEL:2; /*!< bit: 10..11 FaultB Capture Channel */ + uint32_t CAPTURE:3; /*!< bit: 12..14 FaultB Capture Action */ + uint32_t :1; /*!< bit: 15 Reserved */ + uint32_t BLANKVAL:8; /*!< bit: 16..23 FaultB Blanking Time */ + uint32_t FILTERVAL:4; /*!< bit: 24..27 FaultB Filter Value */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_FCTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_FCTRLB_OFFSET 0x10 /**< \brief (TCC_FCTRLB offset) Recoverable FaultB Configuration */ +#define TCC_FCTRLB_RESETVALUE 0x00000000 /**< \brief (TCC_FCTRLB reset_value) Recoverable FaultB Configuration */ + +#define TCC_FCTRLB_SRC_Pos 0 /**< \brief (TCC_FCTRLB) FaultB Source */ +#define TCC_FCTRLB_SRC_Msk (0x3u << TCC_FCTRLB_SRC_Pos) +#define TCC_FCTRLB_SRC(value) ((TCC_FCTRLB_SRC_Msk & ((value) << TCC_FCTRLB_SRC_Pos))) +#define TCC_FCTRLB_SRC_DISABLE_Val 0x0u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_SRC_ENABLE_Val 0x1u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_SRC_INVERT_Val 0x2u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_SRC_ALTFAULT_Val 0x3u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_SRC_DISABLE (TCC_FCTRLB_SRC_DISABLE_Val << TCC_FCTRLB_SRC_Pos) +#define TCC_FCTRLB_SRC_ENABLE (TCC_FCTRLB_SRC_ENABLE_Val << TCC_FCTRLB_SRC_Pos) +#define TCC_FCTRLB_SRC_INVERT (TCC_FCTRLB_SRC_INVERT_Val << TCC_FCTRLB_SRC_Pos) +#define TCC_FCTRLB_SRC_ALTFAULT (TCC_FCTRLB_SRC_ALTFAULT_Val << TCC_FCTRLB_SRC_Pos) +#define TCC_FCTRLB_KEEP_Pos 3 /**< \brief (TCC_FCTRLB) FaultB Keeper */ +#define TCC_FCTRLB_KEEP (0x1u << TCC_FCTRLB_KEEP_Pos) +#define TCC_FCTRLB_QUAL_Pos 4 /**< \brief (TCC_FCTRLB) FaultB Qualification */ +#define TCC_FCTRLB_QUAL (0x1u << TCC_FCTRLB_QUAL_Pos) +#define TCC_FCTRLB_BLANK_Pos 5 /**< \brief (TCC_FCTRLB) FaultB Blanking Mode */ +#define TCC_FCTRLB_BLANK_Msk (0x3u << TCC_FCTRLB_BLANK_Pos) +#define TCC_FCTRLB_BLANK(value) ((TCC_FCTRLB_BLANK_Msk & ((value) << TCC_FCTRLB_BLANK_Pos))) +#define TCC_FCTRLB_BLANK_DISABLE_Val 0x0u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_BLANK_RISE_Val 0x1u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_BLANK_FALL_Val 0x2u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_BLANK_BOTH_Val 0x3u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_BLANK_DISABLE (TCC_FCTRLB_BLANK_DISABLE_Val << TCC_FCTRLB_BLANK_Pos) +#define TCC_FCTRLB_BLANK_RISE (TCC_FCTRLB_BLANK_RISE_Val << TCC_FCTRLB_BLANK_Pos) +#define TCC_FCTRLB_BLANK_FALL (TCC_FCTRLB_BLANK_FALL_Val << TCC_FCTRLB_BLANK_Pos) +#define TCC_FCTRLB_BLANK_BOTH (TCC_FCTRLB_BLANK_BOTH_Val << TCC_FCTRLB_BLANK_Pos) +#define TCC_FCTRLB_RESTART_Pos 7 /**< \brief (TCC_FCTRLB) FaultB Restart */ +#define TCC_FCTRLB_RESTART (0x1u << TCC_FCTRLB_RESTART_Pos) +#define TCC_FCTRLB_HALT_Pos 8 /**< \brief (TCC_FCTRLB) FaultB Halt Mode */ +#define TCC_FCTRLB_HALT_Msk (0x3u << TCC_FCTRLB_HALT_Pos) +#define TCC_FCTRLB_HALT(value) ((TCC_FCTRLB_HALT_Msk & ((value) << TCC_FCTRLB_HALT_Pos))) +#define TCC_FCTRLB_HALT_DISABLE_Val 0x0u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_HALT_HW_Val 0x1u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_HALT_SW_Val 0x2u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_HALT_NR_Val 0x3u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_HALT_DISABLE (TCC_FCTRLB_HALT_DISABLE_Val << TCC_FCTRLB_HALT_Pos) +#define TCC_FCTRLB_HALT_HW (TCC_FCTRLB_HALT_HW_Val << TCC_FCTRLB_HALT_Pos) +#define TCC_FCTRLB_HALT_SW (TCC_FCTRLB_HALT_SW_Val << TCC_FCTRLB_HALT_Pos) +#define TCC_FCTRLB_HALT_NR (TCC_FCTRLB_HALT_NR_Val << TCC_FCTRLB_HALT_Pos) +#define TCC_FCTRLB_CHSEL_Pos 10 /**< \brief (TCC_FCTRLB) FaultB Capture Channel */ +#define TCC_FCTRLB_CHSEL_Msk (0x3u << TCC_FCTRLB_CHSEL_Pos) +#define TCC_FCTRLB_CHSEL(value) ((TCC_FCTRLB_CHSEL_Msk & ((value) << TCC_FCTRLB_CHSEL_Pos))) +#define TCC_FCTRLB_CHSEL_CC0_Val 0x0u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CHSEL_CC1_Val 0x1u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CHSEL_CC2_Val 0x2u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CHSEL_CC3_Val 0x3u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CHSEL_CC0 (TCC_FCTRLB_CHSEL_CC0_Val << TCC_FCTRLB_CHSEL_Pos) +#define TCC_FCTRLB_CHSEL_CC1 (TCC_FCTRLB_CHSEL_CC1_Val << TCC_FCTRLB_CHSEL_Pos) +#define TCC_FCTRLB_CHSEL_CC2 (TCC_FCTRLB_CHSEL_CC2_Val << TCC_FCTRLB_CHSEL_Pos) +#define TCC_FCTRLB_CHSEL_CC3 (TCC_FCTRLB_CHSEL_CC3_Val << TCC_FCTRLB_CHSEL_Pos) +#define TCC_FCTRLB_CAPTURE_Pos 12 /**< \brief (TCC_FCTRLB) FaultB Capture Action */ +#define TCC_FCTRLB_CAPTURE_Msk (0x7u << TCC_FCTRLB_CAPTURE_Pos) +#define TCC_FCTRLB_CAPTURE(value) ((TCC_FCTRLB_CAPTURE_Msk & ((value) << TCC_FCTRLB_CAPTURE_Pos))) +#define TCC_FCTRLB_CAPTURE_DISABLE_Val 0x0u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CAPTURE_CAPT_Val 0x1u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CAPTURE_CAPTMIN_Val 0x2u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CAPTURE_CAPTMAX_Val 0x3u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CAPTURE_LOCMIN_Val 0x4u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CAPTURE_LOCMAX_Val 0x5u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CAPTURE_DERIV0_Val 0x6u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CAPTURE_DISABLE (TCC_FCTRLB_CAPTURE_DISABLE_Val << TCC_FCTRLB_CAPTURE_Pos) +#define TCC_FCTRLB_CAPTURE_CAPT (TCC_FCTRLB_CAPTURE_CAPT_Val << TCC_FCTRLB_CAPTURE_Pos) +#define TCC_FCTRLB_CAPTURE_CAPTMIN (TCC_FCTRLB_CAPTURE_CAPTMIN_Val << TCC_FCTRLB_CAPTURE_Pos) +#define TCC_FCTRLB_CAPTURE_CAPTMAX (TCC_FCTRLB_CAPTURE_CAPTMAX_Val << TCC_FCTRLB_CAPTURE_Pos) +#define TCC_FCTRLB_CAPTURE_LOCMIN (TCC_FCTRLB_CAPTURE_LOCMIN_Val << TCC_FCTRLB_CAPTURE_Pos) +#define TCC_FCTRLB_CAPTURE_LOCMAX (TCC_FCTRLB_CAPTURE_LOCMAX_Val << TCC_FCTRLB_CAPTURE_Pos) +#define TCC_FCTRLB_CAPTURE_DERIV0 (TCC_FCTRLB_CAPTURE_DERIV0_Val << TCC_FCTRLB_CAPTURE_Pos) +#define TCC_FCTRLB_BLANKVAL_Pos 16 /**< \brief (TCC_FCTRLB) FaultB Blanking Time */ +#define TCC_FCTRLB_BLANKVAL_Msk (0xFFu << TCC_FCTRLB_BLANKVAL_Pos) +#define TCC_FCTRLB_BLANKVAL(value) ((TCC_FCTRLB_BLANKVAL_Msk & ((value) << TCC_FCTRLB_BLANKVAL_Pos))) +#define TCC_FCTRLB_FILTERVAL_Pos 24 /**< \brief (TCC_FCTRLB) FaultB Filter Value */ +#define TCC_FCTRLB_FILTERVAL_Msk (0xFu << TCC_FCTRLB_FILTERVAL_Pos) +#define TCC_FCTRLB_FILTERVAL(value) ((TCC_FCTRLB_FILTERVAL_Msk & ((value) << TCC_FCTRLB_FILTERVAL_Pos))) +#define TCC_FCTRLB_MASK 0x0FFF7FFBu /**< \brief (TCC_FCTRLB) MASK Register */ + +/* -------- TCC_WEXCTRL : (TCC Offset: 0x14) (R/W 32) Waveform Extension Configuration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OTMX:2; /*!< bit: 0.. 1 Output Matrix */ + uint32_t :6; /*!< bit: 2.. 7 Reserved */ + uint32_t DTIEN0:1; /*!< bit: 8 Dead-time Insertion Generator 0 Enable */ + uint32_t DTIEN1:1; /*!< bit: 9 Dead-time Insertion Generator 1 Enable */ + uint32_t DTIEN2:1; /*!< bit: 10 Dead-time Insertion Generator 2 Enable */ + uint32_t DTIEN3:1; /*!< bit: 11 Dead-time Insertion Generator 3 Enable */ + uint32_t :4; /*!< bit: 12..15 Reserved */ + uint32_t DTLS:8; /*!< bit: 16..23 Dead-time Low Side Outputs Value */ + uint32_t DTHS:8; /*!< bit: 24..31 Dead-time High Side Outputs Value */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :8; /*!< bit: 0.. 7 Reserved */ + uint32_t DTIEN:4; /*!< bit: 8..11 Dead-time Insertion Generator x Enable */ + uint32_t :20; /*!< bit: 12..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_WEXCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_WEXCTRL_OFFSET 0x14 /**< \brief (TCC_WEXCTRL offset) Waveform Extension Configuration */ +#define TCC_WEXCTRL_RESETVALUE 0x00000000 /**< \brief (TCC_WEXCTRL reset_value) Waveform Extension Configuration */ + +#define TCC_WEXCTRL_OTMX_Pos 0 /**< \brief (TCC_WEXCTRL) Output Matrix */ +#define TCC_WEXCTRL_OTMX_Msk (0x3u << TCC_WEXCTRL_OTMX_Pos) +#define TCC_WEXCTRL_OTMX(value) ((TCC_WEXCTRL_OTMX_Msk & ((value) << TCC_WEXCTRL_OTMX_Pos))) +#define TCC_WEXCTRL_DTIEN0_Pos 8 /**< \brief (TCC_WEXCTRL) Dead-time Insertion Generator 0 Enable */ +#define TCC_WEXCTRL_DTIEN0 (1 << TCC_WEXCTRL_DTIEN0_Pos) +#define TCC_WEXCTRL_DTIEN1_Pos 9 /**< \brief (TCC_WEXCTRL) Dead-time Insertion Generator 1 Enable */ +#define TCC_WEXCTRL_DTIEN1 (1 << TCC_WEXCTRL_DTIEN1_Pos) +#define TCC_WEXCTRL_DTIEN2_Pos 10 /**< \brief (TCC_WEXCTRL) Dead-time Insertion Generator 2 Enable */ +#define TCC_WEXCTRL_DTIEN2 (1 << TCC_WEXCTRL_DTIEN2_Pos) +#define TCC_WEXCTRL_DTIEN3_Pos 11 /**< \brief (TCC_WEXCTRL) Dead-time Insertion Generator 3 Enable */ +#define TCC_WEXCTRL_DTIEN3 (1 << TCC_WEXCTRL_DTIEN3_Pos) +#define TCC_WEXCTRL_DTIEN_Pos 8 /**< \brief (TCC_WEXCTRL) Dead-time Insertion Generator x Enable */ +#define TCC_WEXCTRL_DTIEN_Msk (0xFu << TCC_WEXCTRL_DTIEN_Pos) +#define TCC_WEXCTRL_DTIEN(value) ((TCC_WEXCTRL_DTIEN_Msk & ((value) << TCC_WEXCTRL_DTIEN_Pos))) +#define TCC_WEXCTRL_DTLS_Pos 16 /**< \brief (TCC_WEXCTRL) Dead-time Low Side Outputs Value */ +#define TCC_WEXCTRL_DTLS_Msk (0xFFu << TCC_WEXCTRL_DTLS_Pos) +#define TCC_WEXCTRL_DTLS(value) ((TCC_WEXCTRL_DTLS_Msk & ((value) << TCC_WEXCTRL_DTLS_Pos))) +#define TCC_WEXCTRL_DTHS_Pos 24 /**< \brief (TCC_WEXCTRL) Dead-time High Side Outputs Value */ +#define TCC_WEXCTRL_DTHS_Msk (0xFFu << TCC_WEXCTRL_DTHS_Pos) +#define TCC_WEXCTRL_DTHS(value) ((TCC_WEXCTRL_DTHS_Msk & ((value) << TCC_WEXCTRL_DTHS_Pos))) +#define TCC_WEXCTRL_MASK 0xFFFF0F03u /**< \brief (TCC_WEXCTRL) MASK Register */ + +/* -------- TCC_DRVCTRL : (TCC Offset: 0x18) (R/W 32) Driver Configuration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t NRE0:1; /*!< bit: 0 Non-Recoverable State 0 Output Enable */ + uint32_t NRE1:1; /*!< bit: 1 Non-Recoverable State 1 Output Enable */ + uint32_t NRE2:1; /*!< bit: 2 Non-Recoverable State 2 Output Enable */ + uint32_t NRE3:1; /*!< bit: 3 Non-Recoverable State 3 Output Enable */ + uint32_t NRE4:1; /*!< bit: 4 Non-Recoverable State 4 Output Enable */ + uint32_t NRE5:1; /*!< bit: 5 Non-Recoverable State 5 Output Enable */ + uint32_t NRE6:1; /*!< bit: 6 Non-Recoverable State 6 Output Enable */ + uint32_t NRE7:1; /*!< bit: 7 Non-Recoverable State 7 Output Enable */ + uint32_t NRV0:1; /*!< bit: 8 Non-Recoverable State 0 Output Value */ + uint32_t NRV1:1; /*!< bit: 9 Non-Recoverable State 1 Output Value */ + uint32_t NRV2:1; /*!< bit: 10 Non-Recoverable State 2 Output Value */ + uint32_t NRV3:1; /*!< bit: 11 Non-Recoverable State 3 Output Value */ + uint32_t NRV4:1; /*!< bit: 12 Non-Recoverable State 4 Output Value */ + uint32_t NRV5:1; /*!< bit: 13 Non-Recoverable State 5 Output Value */ + uint32_t NRV6:1; /*!< bit: 14 Non-Recoverable State 6 Output Value */ + uint32_t NRV7:1; /*!< bit: 15 Non-Recoverable State 7 Output Value */ + uint32_t INVEN0:1; /*!< bit: 16 Output Waveform 0 Inversion */ + uint32_t INVEN1:1; /*!< bit: 17 Output Waveform 1 Inversion */ + uint32_t INVEN2:1; /*!< bit: 18 Output Waveform 2 Inversion */ + uint32_t INVEN3:1; /*!< bit: 19 Output Waveform 3 Inversion */ + uint32_t INVEN4:1; /*!< bit: 20 Output Waveform 4 Inversion */ + uint32_t INVEN5:1; /*!< bit: 21 Output Waveform 5 Inversion */ + uint32_t INVEN6:1; /*!< bit: 22 Output Waveform 6 Inversion */ + uint32_t INVEN7:1; /*!< bit: 23 Output Waveform 7 Inversion */ + uint32_t FILTERVAL0:4; /*!< bit: 24..27 Non-Recoverable Fault Input 0 Filter Value */ + uint32_t FILTERVAL1:4; /*!< bit: 28..31 Non-Recoverable Fault Input 1 Filter Value */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t NRE:8; /*!< bit: 0.. 7 Non-Recoverable State x Output Enable */ + uint32_t NRV:8; /*!< bit: 8..15 Non-Recoverable State x Output Value */ + uint32_t INVEN:8; /*!< bit: 16..23 Output Waveform x Inversion */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_DRVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_DRVCTRL_OFFSET 0x18 /**< \brief (TCC_DRVCTRL offset) Driver Configuration */ +#define TCC_DRVCTRL_RESETVALUE 0x00000000 /**< \brief (TCC_DRVCTRL reset_value) Driver Configuration */ + +#define TCC_DRVCTRL_NRE0_Pos 0 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 0 Output Enable */ +#define TCC_DRVCTRL_NRE0 (1 << TCC_DRVCTRL_NRE0_Pos) +#define TCC_DRVCTRL_NRE1_Pos 1 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 1 Output Enable */ +#define TCC_DRVCTRL_NRE1 (1 << TCC_DRVCTRL_NRE1_Pos) +#define TCC_DRVCTRL_NRE2_Pos 2 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 2 Output Enable */ +#define TCC_DRVCTRL_NRE2 (1 << TCC_DRVCTRL_NRE2_Pos) +#define TCC_DRVCTRL_NRE3_Pos 3 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 3 Output Enable */ +#define TCC_DRVCTRL_NRE3 (1 << TCC_DRVCTRL_NRE3_Pos) +#define TCC_DRVCTRL_NRE4_Pos 4 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 4 Output Enable */ +#define TCC_DRVCTRL_NRE4 (1 << TCC_DRVCTRL_NRE4_Pos) +#define TCC_DRVCTRL_NRE5_Pos 5 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 5 Output Enable */ +#define TCC_DRVCTRL_NRE5 (1 << TCC_DRVCTRL_NRE5_Pos) +#define TCC_DRVCTRL_NRE6_Pos 6 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 6 Output Enable */ +#define TCC_DRVCTRL_NRE6 (1 << TCC_DRVCTRL_NRE6_Pos) +#define TCC_DRVCTRL_NRE7_Pos 7 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 7 Output Enable */ +#define TCC_DRVCTRL_NRE7 (1 << TCC_DRVCTRL_NRE7_Pos) +#define TCC_DRVCTRL_NRE_Pos 0 /**< \brief (TCC_DRVCTRL) Non-Recoverable State x Output Enable */ +#define TCC_DRVCTRL_NRE_Msk (0xFFu << TCC_DRVCTRL_NRE_Pos) +#define TCC_DRVCTRL_NRE(value) ((TCC_DRVCTRL_NRE_Msk & ((value) << TCC_DRVCTRL_NRE_Pos))) +#define TCC_DRVCTRL_NRV0_Pos 8 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 0 Output Value */ +#define TCC_DRVCTRL_NRV0 (1 << TCC_DRVCTRL_NRV0_Pos) +#define TCC_DRVCTRL_NRV1_Pos 9 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 1 Output Value */ +#define TCC_DRVCTRL_NRV1 (1 << TCC_DRVCTRL_NRV1_Pos) +#define TCC_DRVCTRL_NRV2_Pos 10 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 2 Output Value */ +#define TCC_DRVCTRL_NRV2 (1 << TCC_DRVCTRL_NRV2_Pos) +#define TCC_DRVCTRL_NRV3_Pos 11 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 3 Output Value */ +#define TCC_DRVCTRL_NRV3 (1 << TCC_DRVCTRL_NRV3_Pos) +#define TCC_DRVCTRL_NRV4_Pos 12 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 4 Output Value */ +#define TCC_DRVCTRL_NRV4 (1 << TCC_DRVCTRL_NRV4_Pos) +#define TCC_DRVCTRL_NRV5_Pos 13 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 5 Output Value */ +#define TCC_DRVCTRL_NRV5 (1 << TCC_DRVCTRL_NRV5_Pos) +#define TCC_DRVCTRL_NRV6_Pos 14 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 6 Output Value */ +#define TCC_DRVCTRL_NRV6 (1 << TCC_DRVCTRL_NRV6_Pos) +#define TCC_DRVCTRL_NRV7_Pos 15 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 7 Output Value */ +#define TCC_DRVCTRL_NRV7 (1 << TCC_DRVCTRL_NRV7_Pos) +#define TCC_DRVCTRL_NRV_Pos 8 /**< \brief (TCC_DRVCTRL) Non-Recoverable State x Output Value */ +#define TCC_DRVCTRL_NRV_Msk (0xFFu << TCC_DRVCTRL_NRV_Pos) +#define TCC_DRVCTRL_NRV(value) ((TCC_DRVCTRL_NRV_Msk & ((value) << TCC_DRVCTRL_NRV_Pos))) +#define TCC_DRVCTRL_INVEN0_Pos 16 /**< \brief (TCC_DRVCTRL) Output Waveform 0 Inversion */ +#define TCC_DRVCTRL_INVEN0 (1 << TCC_DRVCTRL_INVEN0_Pos) +#define TCC_DRVCTRL_INVEN1_Pos 17 /**< \brief (TCC_DRVCTRL) Output Waveform 1 Inversion */ +#define TCC_DRVCTRL_INVEN1 (1 << TCC_DRVCTRL_INVEN1_Pos) +#define TCC_DRVCTRL_INVEN2_Pos 18 /**< \brief (TCC_DRVCTRL) Output Waveform 2 Inversion */ +#define TCC_DRVCTRL_INVEN2 (1 << TCC_DRVCTRL_INVEN2_Pos) +#define TCC_DRVCTRL_INVEN3_Pos 19 /**< \brief (TCC_DRVCTRL) Output Waveform 3 Inversion */ +#define TCC_DRVCTRL_INVEN3 (1 << TCC_DRVCTRL_INVEN3_Pos) +#define TCC_DRVCTRL_INVEN4_Pos 20 /**< \brief (TCC_DRVCTRL) Output Waveform 4 Inversion */ +#define TCC_DRVCTRL_INVEN4 (1 << TCC_DRVCTRL_INVEN4_Pos) +#define TCC_DRVCTRL_INVEN5_Pos 21 /**< \brief (TCC_DRVCTRL) Output Waveform 5 Inversion */ +#define TCC_DRVCTRL_INVEN5 (1 << TCC_DRVCTRL_INVEN5_Pos) +#define TCC_DRVCTRL_INVEN6_Pos 22 /**< \brief (TCC_DRVCTRL) Output Waveform 6 Inversion */ +#define TCC_DRVCTRL_INVEN6 (1 << TCC_DRVCTRL_INVEN6_Pos) +#define TCC_DRVCTRL_INVEN7_Pos 23 /**< \brief (TCC_DRVCTRL) Output Waveform 7 Inversion */ +#define TCC_DRVCTRL_INVEN7 (1 << TCC_DRVCTRL_INVEN7_Pos) +#define TCC_DRVCTRL_INVEN_Pos 16 /**< \brief (TCC_DRVCTRL) Output Waveform x Inversion */ +#define TCC_DRVCTRL_INVEN_Msk (0xFFu << TCC_DRVCTRL_INVEN_Pos) +#define TCC_DRVCTRL_INVEN(value) ((TCC_DRVCTRL_INVEN_Msk & ((value) << TCC_DRVCTRL_INVEN_Pos))) +#define TCC_DRVCTRL_FILTERVAL0_Pos 24 /**< \brief (TCC_DRVCTRL) Non-Recoverable Fault Input 0 Filter Value */ +#define TCC_DRVCTRL_FILTERVAL0_Msk (0xFu << TCC_DRVCTRL_FILTERVAL0_Pos) +#define TCC_DRVCTRL_FILTERVAL0(value) ((TCC_DRVCTRL_FILTERVAL0_Msk & ((value) << TCC_DRVCTRL_FILTERVAL0_Pos))) +#define TCC_DRVCTRL_FILTERVAL1_Pos 28 /**< \brief (TCC_DRVCTRL) Non-Recoverable Fault Input 1 Filter Value */ +#define TCC_DRVCTRL_FILTERVAL1_Msk (0xFu << TCC_DRVCTRL_FILTERVAL1_Pos) +#define TCC_DRVCTRL_FILTERVAL1(value) ((TCC_DRVCTRL_FILTERVAL1_Msk & ((value) << TCC_DRVCTRL_FILTERVAL1_Pos))) +#define TCC_DRVCTRL_MASK 0xFFFFFFFFu /**< \brief (TCC_DRVCTRL) MASK Register */ + +/* -------- TCC_DBGCTRL : (TCC Offset: 0x1E) (R/W 8) Debug Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DBGRUN:1; /*!< bit: 0 Debug Running Mode */ + uint8_t :1; /*!< bit: 1 Reserved */ + uint8_t FDDBD:1; /*!< bit: 2 Fault Detection on Debug Break Detection */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TCC_DBGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_DBGCTRL_OFFSET 0x1E /**< \brief (TCC_DBGCTRL offset) Debug Control */ +#define TCC_DBGCTRL_RESETVALUE 0x00 /**< \brief (TCC_DBGCTRL reset_value) Debug Control */ + +#define TCC_DBGCTRL_DBGRUN_Pos 0 /**< \brief (TCC_DBGCTRL) Debug Running Mode */ +#define TCC_DBGCTRL_DBGRUN (0x1u << TCC_DBGCTRL_DBGRUN_Pos) +#define TCC_DBGCTRL_FDDBD_Pos 2 /**< \brief (TCC_DBGCTRL) Fault Detection on Debug Break Detection */ +#define TCC_DBGCTRL_FDDBD (0x1u << TCC_DBGCTRL_FDDBD_Pos) +#define TCC_DBGCTRL_MASK 0x05u /**< \brief (TCC_DBGCTRL) MASK Register */ + +/* -------- TCC_EVCTRL : (TCC Offset: 0x20) (R/W 32) Event Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t EVACT0:3; /*!< bit: 0.. 2 Timer/counter Input Event0 Action */ + uint32_t EVACT1:3; /*!< bit: 3.. 5 Timer/counter Input Event1 Action */ + uint32_t CNTSEL:2; /*!< bit: 6.. 7 Timer/counter Output Event Mode */ + uint32_t OVFEO:1; /*!< bit: 8 Overflow/Underflow Output Event Enable */ + uint32_t TRGEO:1; /*!< bit: 9 Retrigger Output Event Enable */ + uint32_t CNTEO:1; /*!< bit: 10 Timer/counter Output Event Enable */ + uint32_t :1; /*!< bit: 11 Reserved */ + uint32_t TCINV0:1; /*!< bit: 12 Inverted Event 0 Input Enable */ + uint32_t TCINV1:1; /*!< bit: 13 Inverted Event 1 Input Enable */ + uint32_t TCEI0:1; /*!< bit: 14 Timer/counter Event 0 Input Enable */ + uint32_t TCEI1:1; /*!< bit: 15 Timer/counter Event 1 Input Enable */ + uint32_t MCEI0:1; /*!< bit: 16 Match or Capture Channel 0 Event Input Enable */ + uint32_t MCEI1:1; /*!< bit: 17 Match or Capture Channel 1 Event Input Enable */ + uint32_t MCEI2:1; /*!< bit: 18 Match or Capture Channel 2 Event Input Enable */ + uint32_t MCEI3:1; /*!< bit: 19 Match or Capture Channel 3 Event Input Enable */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t MCEO0:1; /*!< bit: 24 Match or Capture Channel 0 Event Output Enable */ + uint32_t MCEO1:1; /*!< bit: 25 Match or Capture Channel 1 Event Output Enable */ + uint32_t MCEO2:1; /*!< bit: 26 Match or Capture Channel 2 Event Output Enable */ + uint32_t MCEO3:1; /*!< bit: 27 Match or Capture Channel 3 Event Output Enable */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :12; /*!< bit: 0..11 Reserved */ + uint32_t TCINV:2; /*!< bit: 12..13 Inverted Event x Input Enable */ + uint32_t TCEI:2; /*!< bit: 14..15 Timer/counter Event x Input Enable */ + uint32_t MCEI:4; /*!< bit: 16..19 Match or Capture Channel x Event Input Enable */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t MCEO:4; /*!< bit: 24..27 Match or Capture Channel x Event Output Enable */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_EVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_EVCTRL_OFFSET 0x20 /**< \brief (TCC_EVCTRL offset) Event Control */ +#define TCC_EVCTRL_RESETVALUE 0x00000000 /**< \brief (TCC_EVCTRL reset_value) Event Control */ + +#define TCC_EVCTRL_EVACT0_Pos 0 /**< \brief (TCC_EVCTRL) Timer/counter Input Event0 Action */ +#define TCC_EVCTRL_EVACT0_Msk (0x7u << TCC_EVCTRL_EVACT0_Pos) +#define TCC_EVCTRL_EVACT0(value) ((TCC_EVCTRL_EVACT0_Msk & ((value) << TCC_EVCTRL_EVACT0_Pos))) +#define TCC_EVCTRL_EVACT0_OFF_Val 0x0u /**< \brief (TCC_EVCTRL) Event action disabled. */ +#define TCC_EVCTRL_EVACT0_RETRIGGER_Val 0x1u /**< \brief (TCC_EVCTRL) Start restart or re-trigger TC on event */ +#define TCC_EVCTRL_EVACT0_COUNTEV_Val 0x2u /**< \brief (TCC_EVCTRL) Count on event. Increment or decrement depending on count direction. */ +#define TCC_EVCTRL_EVACT0_START_Val 0x3u /**< \brief (TCC_EVCTRL) Count on event.Start counting on the event rising edge. Further events will not restart the counter; it keeps on counting using prescaled GCLK_TCCx, until it reaches TOP or Zero depending on the direction. */ +#define TCC_EVCTRL_EVACT0_INC_Val 0x4u /**< \brief (TCC_EVCTRL) Increment TC on EVENT. Increment the counter on event, irrespective of count direction */ +#define TCC_EVCTRL_EVACT0_COUNT_Val 0x5u /**< \brief (TCC_EVCTRL) Count on active state of asynchronous event */ +#define TCC_EVCTRL_EVACT0_FAULT_Val 0x7u /**< \brief (TCC_EVCTRL) Non-recoverable Fault */ +#define TCC_EVCTRL_EVACT0_OFF (TCC_EVCTRL_EVACT0_OFF_Val << TCC_EVCTRL_EVACT0_Pos) +#define TCC_EVCTRL_EVACT0_RETRIGGER (TCC_EVCTRL_EVACT0_RETRIGGER_Val << TCC_EVCTRL_EVACT0_Pos) +#define TCC_EVCTRL_EVACT0_COUNTEV (TCC_EVCTRL_EVACT0_COUNTEV_Val << TCC_EVCTRL_EVACT0_Pos) +#define TCC_EVCTRL_EVACT0_START (TCC_EVCTRL_EVACT0_START_Val << TCC_EVCTRL_EVACT0_Pos) +#define TCC_EVCTRL_EVACT0_INC (TCC_EVCTRL_EVACT0_INC_Val << TCC_EVCTRL_EVACT0_Pos) +#define TCC_EVCTRL_EVACT0_COUNT (TCC_EVCTRL_EVACT0_COUNT_Val << TCC_EVCTRL_EVACT0_Pos) +#define TCC_EVCTRL_EVACT0_FAULT (TCC_EVCTRL_EVACT0_FAULT_Val << TCC_EVCTRL_EVACT0_Pos) +#define TCC_EVCTRL_EVACT1_Pos 3 /**< \brief (TCC_EVCTRL) Timer/counter Input Event1 Action */ +#define TCC_EVCTRL_EVACT1_Msk (0x7u << TCC_EVCTRL_EVACT1_Pos) +#define TCC_EVCTRL_EVACT1(value) ((TCC_EVCTRL_EVACT1_Msk & ((value) << TCC_EVCTRL_EVACT1_Pos))) +#define TCC_EVCTRL_EVACT1_OFF_Val 0x0u /**< \brief (TCC_EVCTRL) Event action disabled. */ +#define TCC_EVCTRL_EVACT1_RETRIGGER_Val 0x1u /**< \brief (TCC_EVCTRL) Re-trigger TC on event */ +#define TCC_EVCTRL_EVACT1_DIR_Val 0x2u /**< \brief (TCC_EVCTRL) Direction control */ +#define TCC_EVCTRL_EVACT1_STOP_Val 0x3u /**< \brief (TCC_EVCTRL) Stop TC on event */ +#define TCC_EVCTRL_EVACT1_DEC_Val 0x4u /**< \brief (TCC_EVCTRL) Decrement TC on event */ +#define TCC_EVCTRL_EVACT1_PPW_Val 0x5u /**< \brief (TCC_EVCTRL) Period captured into CC0 Pulse Width on CC1 */ +#define TCC_EVCTRL_EVACT1_PWP_Val 0x6u /**< \brief (TCC_EVCTRL) Period captured into CC1 Pulse Width on CC0 */ +#define TCC_EVCTRL_EVACT1_FAULT_Val 0x7u /**< \brief (TCC_EVCTRL) Non-recoverable Fault */ +#define TCC_EVCTRL_EVACT1_OFF (TCC_EVCTRL_EVACT1_OFF_Val << TCC_EVCTRL_EVACT1_Pos) +#define TCC_EVCTRL_EVACT1_RETRIGGER (TCC_EVCTRL_EVACT1_RETRIGGER_Val << TCC_EVCTRL_EVACT1_Pos) +#define TCC_EVCTRL_EVACT1_DIR (TCC_EVCTRL_EVACT1_DIR_Val << TCC_EVCTRL_EVACT1_Pos) +#define TCC_EVCTRL_EVACT1_STOP (TCC_EVCTRL_EVACT1_STOP_Val << TCC_EVCTRL_EVACT1_Pos) +#define TCC_EVCTRL_EVACT1_DEC (TCC_EVCTRL_EVACT1_DEC_Val << TCC_EVCTRL_EVACT1_Pos) +#define TCC_EVCTRL_EVACT1_PPW (TCC_EVCTRL_EVACT1_PPW_Val << TCC_EVCTRL_EVACT1_Pos) +#define TCC_EVCTRL_EVACT1_PWP (TCC_EVCTRL_EVACT1_PWP_Val << TCC_EVCTRL_EVACT1_Pos) +#define TCC_EVCTRL_EVACT1_FAULT (TCC_EVCTRL_EVACT1_FAULT_Val << TCC_EVCTRL_EVACT1_Pos) +#define TCC_EVCTRL_CNTSEL_Pos 6 /**< \brief (TCC_EVCTRL) Timer/counter Output Event Mode */ +#define TCC_EVCTRL_CNTSEL_Msk (0x3u << TCC_EVCTRL_CNTSEL_Pos) +#define TCC_EVCTRL_CNTSEL(value) ((TCC_EVCTRL_CNTSEL_Msk & ((value) << TCC_EVCTRL_CNTSEL_Pos))) +#define TCC_EVCTRL_CNTSEL_START_Val 0x0u /**< \brief (TCC_EVCTRL) An interrupt/event is generated when a new counter cycle starts */ +#define TCC_EVCTRL_CNTSEL_END_Val 0x1u /**< \brief (TCC_EVCTRL) An interrupt/event is generated when a counter cycle ends */ +#define TCC_EVCTRL_CNTSEL_BETWEEN_Val 0x2u /**< \brief (TCC_EVCTRL) An interrupt/event is generated when a counter cycle ends, except for the first and last cycles. */ +#define TCC_EVCTRL_CNTSEL_BOUNDARY_Val 0x3u /**< \brief (TCC_EVCTRL) An interrupt/event is generated when a new counter cycle starts or a counter cycle ends */ +#define TCC_EVCTRL_CNTSEL_START (TCC_EVCTRL_CNTSEL_START_Val << TCC_EVCTRL_CNTSEL_Pos) +#define TCC_EVCTRL_CNTSEL_END (TCC_EVCTRL_CNTSEL_END_Val << TCC_EVCTRL_CNTSEL_Pos) +#define TCC_EVCTRL_CNTSEL_BETWEEN (TCC_EVCTRL_CNTSEL_BETWEEN_Val << TCC_EVCTRL_CNTSEL_Pos) +#define TCC_EVCTRL_CNTSEL_BOUNDARY (TCC_EVCTRL_CNTSEL_BOUNDARY_Val << TCC_EVCTRL_CNTSEL_Pos) +#define TCC_EVCTRL_OVFEO_Pos 8 /**< \brief (TCC_EVCTRL) Overflow/Underflow Output Event Enable */ +#define TCC_EVCTRL_OVFEO (0x1u << TCC_EVCTRL_OVFEO_Pos) +#define TCC_EVCTRL_TRGEO_Pos 9 /**< \brief (TCC_EVCTRL) Retrigger Output Event Enable */ +#define TCC_EVCTRL_TRGEO (0x1u << TCC_EVCTRL_TRGEO_Pos) +#define TCC_EVCTRL_CNTEO_Pos 10 /**< \brief (TCC_EVCTRL) Timer/counter Output Event Enable */ +#define TCC_EVCTRL_CNTEO (0x1u << TCC_EVCTRL_CNTEO_Pos) +#define TCC_EVCTRL_TCINV0_Pos 12 /**< \brief (TCC_EVCTRL) Inverted Event 0 Input Enable */ +#define TCC_EVCTRL_TCINV0 (1 << TCC_EVCTRL_TCINV0_Pos) +#define TCC_EVCTRL_TCINV1_Pos 13 /**< \brief (TCC_EVCTRL) Inverted Event 1 Input Enable */ +#define TCC_EVCTRL_TCINV1 (1 << TCC_EVCTRL_TCINV1_Pos) +#define TCC_EVCTRL_TCINV_Pos 12 /**< \brief (TCC_EVCTRL) Inverted Event x Input Enable */ +#define TCC_EVCTRL_TCINV_Msk (0x3u << TCC_EVCTRL_TCINV_Pos) +#define TCC_EVCTRL_TCINV(value) ((TCC_EVCTRL_TCINV_Msk & ((value) << TCC_EVCTRL_TCINV_Pos))) +#define TCC_EVCTRL_TCEI0_Pos 14 /**< \brief (TCC_EVCTRL) Timer/counter Event 0 Input Enable */ +#define TCC_EVCTRL_TCEI0 (1 << TCC_EVCTRL_TCEI0_Pos) +#define TCC_EVCTRL_TCEI1_Pos 15 /**< \brief (TCC_EVCTRL) Timer/counter Event 1 Input Enable */ +#define TCC_EVCTRL_TCEI1 (1 << TCC_EVCTRL_TCEI1_Pos) +#define TCC_EVCTRL_TCEI_Pos 14 /**< \brief (TCC_EVCTRL) Timer/counter Event x Input Enable */ +#define TCC_EVCTRL_TCEI_Msk (0x3u << TCC_EVCTRL_TCEI_Pos) +#define TCC_EVCTRL_TCEI(value) ((TCC_EVCTRL_TCEI_Msk & ((value) << TCC_EVCTRL_TCEI_Pos))) +#define TCC_EVCTRL_MCEI0_Pos 16 /**< \brief (TCC_EVCTRL) Match or Capture Channel 0 Event Input Enable */ +#define TCC_EVCTRL_MCEI0 (1 << TCC_EVCTRL_MCEI0_Pos) +#define TCC_EVCTRL_MCEI1_Pos 17 /**< \brief (TCC_EVCTRL) Match or Capture Channel 1 Event Input Enable */ +#define TCC_EVCTRL_MCEI1 (1 << TCC_EVCTRL_MCEI1_Pos) +#define TCC_EVCTRL_MCEI2_Pos 18 /**< \brief (TCC_EVCTRL) Match or Capture Channel 2 Event Input Enable */ +#define TCC_EVCTRL_MCEI2 (1 << TCC_EVCTRL_MCEI2_Pos) +#define TCC_EVCTRL_MCEI3_Pos 19 /**< \brief (TCC_EVCTRL) Match or Capture Channel 3 Event Input Enable */ +#define TCC_EVCTRL_MCEI3 (1 << TCC_EVCTRL_MCEI3_Pos) +#define TCC_EVCTRL_MCEI_Pos 16 /**< \brief (TCC_EVCTRL) Match or Capture Channel x Event Input Enable */ +#define TCC_EVCTRL_MCEI_Msk (0xFu << TCC_EVCTRL_MCEI_Pos) +#define TCC_EVCTRL_MCEI(value) ((TCC_EVCTRL_MCEI_Msk & ((value) << TCC_EVCTRL_MCEI_Pos))) +#define TCC_EVCTRL_MCEO0_Pos 24 /**< \brief (TCC_EVCTRL) Match or Capture Channel 0 Event Output Enable */ +#define TCC_EVCTRL_MCEO0 (1 << TCC_EVCTRL_MCEO0_Pos) +#define TCC_EVCTRL_MCEO1_Pos 25 /**< \brief (TCC_EVCTRL) Match or Capture Channel 1 Event Output Enable */ +#define TCC_EVCTRL_MCEO1 (1 << TCC_EVCTRL_MCEO1_Pos) +#define TCC_EVCTRL_MCEO2_Pos 26 /**< \brief (TCC_EVCTRL) Match or Capture Channel 2 Event Output Enable */ +#define TCC_EVCTRL_MCEO2 (1 << TCC_EVCTRL_MCEO2_Pos) +#define TCC_EVCTRL_MCEO3_Pos 27 /**< \brief (TCC_EVCTRL) Match or Capture Channel 3 Event Output Enable */ +#define TCC_EVCTRL_MCEO3 (1 << TCC_EVCTRL_MCEO3_Pos) +#define TCC_EVCTRL_MCEO_Pos 24 /**< \brief (TCC_EVCTRL) Match or Capture Channel x Event Output Enable */ +#define TCC_EVCTRL_MCEO_Msk (0xFu << TCC_EVCTRL_MCEO_Pos) +#define TCC_EVCTRL_MCEO(value) ((TCC_EVCTRL_MCEO_Msk & ((value) << TCC_EVCTRL_MCEO_Pos))) +#define TCC_EVCTRL_MASK 0x0F0FF7FFu /**< \brief (TCC_EVCTRL) MASK Register */ + +/* -------- TCC_INTENCLR : (TCC Offset: 0x24) (R/W 32) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OVF:1; /*!< bit: 0 Overflow Interrupt Enable */ + uint32_t TRG:1; /*!< bit: 1 Retrigger Interrupt Enable */ + uint32_t CNT:1; /*!< bit: 2 Counter Interrupt Enable */ + uint32_t ERR:1; /*!< bit: 3 Error Interrupt Enable */ + uint32_t :7; /*!< bit: 4..10 Reserved */ + uint32_t DFS:1; /*!< bit: 11 Non-recoverable Debug Fault Interrupt Enable */ + uint32_t FAULTA:1; /*!< bit: 12 Recoverable FaultA Interrupt Enable */ + uint32_t FAULTB:1; /*!< bit: 13 Recoverable FaultB Interrupt Enable */ + uint32_t FAULT0:1; /*!< bit: 14 Non-Recoverable Fault 0 Interrupt Enable */ + uint32_t FAULT1:1; /*!< bit: 15 Non-Recoverable Fault 1 Interrupt Enable */ + uint32_t MC0:1; /*!< bit: 16 Match or Capture Channel 0 Interrupt Enable */ + uint32_t MC1:1; /*!< bit: 17 Match or Capture Channel 1 Interrupt Enable */ + uint32_t MC2:1; /*!< bit: 18 Match or Capture Channel 2 Interrupt Enable */ + uint32_t MC3:1; /*!< bit: 19 Match or Capture Channel 3 Interrupt Enable */ + uint32_t :12; /*!< bit: 20..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :16; /*!< bit: 0..15 Reserved */ + uint32_t MC:4; /*!< bit: 16..19 Match or Capture Channel x Interrupt Enable */ + uint32_t :12; /*!< bit: 20..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_INTENCLR_OFFSET 0x24 /**< \brief (TCC_INTENCLR offset) Interrupt Enable Clear */ +#define TCC_INTENCLR_RESETVALUE 0x00000000 /**< \brief (TCC_INTENCLR reset_value) Interrupt Enable Clear */ + +#define TCC_INTENCLR_OVF_Pos 0 /**< \brief (TCC_INTENCLR) Overflow Interrupt Enable */ +#define TCC_INTENCLR_OVF (0x1u << TCC_INTENCLR_OVF_Pos) +#define TCC_INTENCLR_TRG_Pos 1 /**< \brief (TCC_INTENCLR) Retrigger Interrupt Enable */ +#define TCC_INTENCLR_TRG (0x1u << TCC_INTENCLR_TRG_Pos) +#define TCC_INTENCLR_CNT_Pos 2 /**< \brief (TCC_INTENCLR) Counter Interrupt Enable */ +#define TCC_INTENCLR_CNT (0x1u << TCC_INTENCLR_CNT_Pos) +#define TCC_INTENCLR_ERR_Pos 3 /**< \brief (TCC_INTENCLR) Error Interrupt Enable */ +#define TCC_INTENCLR_ERR (0x1u << TCC_INTENCLR_ERR_Pos) +#define TCC_INTENCLR_DFS_Pos 11 /**< \brief (TCC_INTENCLR) Non-recoverable Debug Fault Interrupt Enable */ +#define TCC_INTENCLR_DFS (0x1u << TCC_INTENCLR_DFS_Pos) +#define TCC_INTENCLR_FAULTA_Pos 12 /**< \brief (TCC_INTENCLR) Recoverable FaultA Interrupt Enable */ +#define TCC_INTENCLR_FAULTA (0x1u << TCC_INTENCLR_FAULTA_Pos) +#define TCC_INTENCLR_FAULTB_Pos 13 /**< \brief (TCC_INTENCLR) Recoverable FaultB Interrupt Enable */ +#define TCC_INTENCLR_FAULTB (0x1u << TCC_INTENCLR_FAULTB_Pos) +#define TCC_INTENCLR_FAULT0_Pos 14 /**< \brief (TCC_INTENCLR) Non-Recoverable Fault 0 Interrupt Enable */ +#define TCC_INTENCLR_FAULT0 (0x1u << TCC_INTENCLR_FAULT0_Pos) +#define TCC_INTENCLR_FAULT1_Pos 15 /**< \brief (TCC_INTENCLR) Non-Recoverable Fault 1 Interrupt Enable */ +#define TCC_INTENCLR_FAULT1 (0x1u << TCC_INTENCLR_FAULT1_Pos) +#define TCC_INTENCLR_MC0_Pos 16 /**< \brief (TCC_INTENCLR) Match or Capture Channel 0 Interrupt Enable */ +#define TCC_INTENCLR_MC0 (1 << TCC_INTENCLR_MC0_Pos) +#define TCC_INTENCLR_MC1_Pos 17 /**< \brief (TCC_INTENCLR) Match or Capture Channel 1 Interrupt Enable */ +#define TCC_INTENCLR_MC1 (1 << TCC_INTENCLR_MC1_Pos) +#define TCC_INTENCLR_MC2_Pos 18 /**< \brief (TCC_INTENCLR) Match or Capture Channel 2 Interrupt Enable */ +#define TCC_INTENCLR_MC2 (1 << TCC_INTENCLR_MC2_Pos) +#define TCC_INTENCLR_MC3_Pos 19 /**< \brief (TCC_INTENCLR) Match or Capture Channel 3 Interrupt Enable */ +#define TCC_INTENCLR_MC3 (1 << TCC_INTENCLR_MC3_Pos) +#define TCC_INTENCLR_MC_Pos 16 /**< \brief (TCC_INTENCLR) Match or Capture Channel x Interrupt Enable */ +#define TCC_INTENCLR_MC_Msk (0xFu << TCC_INTENCLR_MC_Pos) +#define TCC_INTENCLR_MC(value) ((TCC_INTENCLR_MC_Msk & ((value) << TCC_INTENCLR_MC_Pos))) +#define TCC_INTENCLR_MASK 0x000FF80Fu /**< \brief (TCC_INTENCLR) MASK Register */ + +/* -------- TCC_INTENSET : (TCC Offset: 0x28) (R/W 32) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OVF:1; /*!< bit: 0 Overflow Interrupt Enable */ + uint32_t TRG:1; /*!< bit: 1 Retrigger Interrupt Enable */ + uint32_t CNT:1; /*!< bit: 2 Counter Interrupt Enable */ + uint32_t ERR:1; /*!< bit: 3 Error Interrupt Enable */ + uint32_t :7; /*!< bit: 4..10 Reserved */ + uint32_t DFS:1; /*!< bit: 11 Non-Recoverable Debug Fault Interrupt Enable */ + uint32_t FAULTA:1; /*!< bit: 12 Recoverable FaultA Interrupt Enable */ + uint32_t FAULTB:1; /*!< bit: 13 Recoverable FaultB Interrupt Enable */ + uint32_t FAULT0:1; /*!< bit: 14 Non-Recoverable Fault 0 Interrupt Enable */ + uint32_t FAULT1:1; /*!< bit: 15 Non-Recoverable Fault 1 Interrupt Enabl */ + uint32_t MC0:1; /*!< bit: 16 Match or Capture Channel 0 Interrupt Enable */ + uint32_t MC1:1; /*!< bit: 17 Match or Capture Channel 1 Interrupt Enable */ + uint32_t MC2:1; /*!< bit: 18 Match or Capture Channel 2 Interrupt Enable */ + uint32_t MC3:1; /*!< bit: 19 Match or Capture Channel 3 Interrupt Enable */ + uint32_t :12; /*!< bit: 20..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :16; /*!< bit: 0..15 Reserved */ + uint32_t MC:4; /*!< bit: 16..19 Match or Capture Channel x Interrupt Enable */ + uint32_t :12; /*!< bit: 20..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_INTENSET_OFFSET 0x28 /**< \brief (TCC_INTENSET offset) Interrupt Enable Set */ +#define TCC_INTENSET_RESETVALUE 0x00000000 /**< \brief (TCC_INTENSET reset_value) Interrupt Enable Set */ + +#define TCC_INTENSET_OVF_Pos 0 /**< \brief (TCC_INTENSET) Overflow Interrupt Enable */ +#define TCC_INTENSET_OVF (0x1u << TCC_INTENSET_OVF_Pos) +#define TCC_INTENSET_TRG_Pos 1 /**< \brief (TCC_INTENSET) Retrigger Interrupt Enable */ +#define TCC_INTENSET_TRG (0x1u << TCC_INTENSET_TRG_Pos) +#define TCC_INTENSET_CNT_Pos 2 /**< \brief (TCC_INTENSET) Counter Interrupt Enable */ +#define TCC_INTENSET_CNT (0x1u << TCC_INTENSET_CNT_Pos) +#define TCC_INTENSET_ERR_Pos 3 /**< \brief (TCC_INTENSET) Error Interrupt Enable */ +#define TCC_INTENSET_ERR (0x1u << TCC_INTENSET_ERR_Pos) +#define TCC_INTENSET_DFS_Pos 11 /**< \brief (TCC_INTENSET) Non-Recoverable Debug Fault Interrupt Enable */ +#define TCC_INTENSET_DFS (0x1u << TCC_INTENSET_DFS_Pos) +#define TCC_INTENSET_FAULTA_Pos 12 /**< \brief (TCC_INTENSET) Recoverable FaultA Interrupt Enable */ +#define TCC_INTENSET_FAULTA (0x1u << TCC_INTENSET_FAULTA_Pos) +#define TCC_INTENSET_FAULTB_Pos 13 /**< \brief (TCC_INTENSET) Recoverable FaultB Interrupt Enable */ +#define TCC_INTENSET_FAULTB (0x1u << TCC_INTENSET_FAULTB_Pos) +#define TCC_INTENSET_FAULT0_Pos 14 /**< \brief (TCC_INTENSET) Non-Recoverable Fault 0 Interrupt Enable */ +#define TCC_INTENSET_FAULT0 (0x1u << TCC_INTENSET_FAULT0_Pos) +#define TCC_INTENSET_FAULT1_Pos 15 /**< \brief (TCC_INTENSET) Non-Recoverable Fault 1 Interrupt Enabl */ +#define TCC_INTENSET_FAULT1 (0x1u << TCC_INTENSET_FAULT1_Pos) +#define TCC_INTENSET_MC0_Pos 16 /**< \brief (TCC_INTENSET) Match or Capture Channel 0 Interrupt Enable */ +#define TCC_INTENSET_MC0 (1 << TCC_INTENSET_MC0_Pos) +#define TCC_INTENSET_MC1_Pos 17 /**< \brief (TCC_INTENSET) Match or Capture Channel 1 Interrupt Enable */ +#define TCC_INTENSET_MC1 (1 << TCC_INTENSET_MC1_Pos) +#define TCC_INTENSET_MC2_Pos 18 /**< \brief (TCC_INTENSET) Match or Capture Channel 2 Interrupt Enable */ +#define TCC_INTENSET_MC2 (1 << TCC_INTENSET_MC2_Pos) +#define TCC_INTENSET_MC3_Pos 19 /**< \brief (TCC_INTENSET) Match or Capture Channel 3 Interrupt Enable */ +#define TCC_INTENSET_MC3 (1 << TCC_INTENSET_MC3_Pos) +#define TCC_INTENSET_MC_Pos 16 /**< \brief (TCC_INTENSET) Match or Capture Channel x Interrupt Enable */ +#define TCC_INTENSET_MC_Msk (0xFu << TCC_INTENSET_MC_Pos) +#define TCC_INTENSET_MC(value) ((TCC_INTENSET_MC_Msk & ((value) << TCC_INTENSET_MC_Pos))) +#define TCC_INTENSET_MASK 0x000FF80Fu /**< \brief (TCC_INTENSET) MASK Register */ + +/* -------- TCC_INTFLAG : (TCC Offset: 0x2C) (R/W 32) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OVF:1; /*!< bit: 0 Overflow */ + uint32_t TRG:1; /*!< bit: 1 Retrigger */ + uint32_t CNT:1; /*!< bit: 2 Counter */ + uint32_t ERR:1; /*!< bit: 3 Error */ + uint32_t :7; /*!< bit: 4..10 Reserved */ + uint32_t DFS:1; /*!< bit: 11 Non-Recoverable Debug Fault */ + uint32_t FAULTA:1; /*!< bit: 12 Recoverable FaultA */ + uint32_t FAULTB:1; /*!< bit: 13 Recoverable FaultB */ + uint32_t FAULT0:1; /*!< bit: 14 Non-Recoverable Fault 0 */ + uint32_t FAULT1:1; /*!< bit: 15 Non-Recoverable Fault 1 */ + uint32_t MC0:1; /*!< bit: 16 Match or Capture 0 */ + uint32_t MC1:1; /*!< bit: 17 Match or Capture 1 */ + uint32_t MC2:1; /*!< bit: 18 Match or Capture 2 */ + uint32_t MC3:1; /*!< bit: 19 Match or Capture 3 */ + uint32_t :12; /*!< bit: 20..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :16; /*!< bit: 0..15 Reserved */ + uint32_t MC:4; /*!< bit: 16..19 Match or Capture x */ + uint32_t :12; /*!< bit: 20..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_INTFLAG_OFFSET 0x2C /**< \brief (TCC_INTFLAG offset) Interrupt Flag Status and Clear */ +#define TCC_INTFLAG_RESETVALUE 0x00000000 /**< \brief (TCC_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define TCC_INTFLAG_OVF_Pos 0 /**< \brief (TCC_INTFLAG) Overflow */ +#define TCC_INTFLAG_OVF (0x1u << TCC_INTFLAG_OVF_Pos) +#define TCC_INTFLAG_TRG_Pos 1 /**< \brief (TCC_INTFLAG) Retrigger */ +#define TCC_INTFLAG_TRG (0x1u << TCC_INTFLAG_TRG_Pos) +#define TCC_INTFLAG_CNT_Pos 2 /**< \brief (TCC_INTFLAG) Counter */ +#define TCC_INTFLAG_CNT (0x1u << TCC_INTFLAG_CNT_Pos) +#define TCC_INTFLAG_ERR_Pos 3 /**< \brief (TCC_INTFLAG) Error */ +#define TCC_INTFLAG_ERR (0x1u << TCC_INTFLAG_ERR_Pos) +#define TCC_INTFLAG_DFS_Pos 11 /**< \brief (TCC_INTFLAG) Non-Recoverable Debug Fault */ +#define TCC_INTFLAG_DFS (0x1u << TCC_INTFLAG_DFS_Pos) +#define TCC_INTFLAG_FAULTA_Pos 12 /**< \brief (TCC_INTFLAG) Recoverable FaultA */ +#define TCC_INTFLAG_FAULTA (0x1u << TCC_INTFLAG_FAULTA_Pos) +#define TCC_INTFLAG_FAULTB_Pos 13 /**< \brief (TCC_INTFLAG) Recoverable FaultB */ +#define TCC_INTFLAG_FAULTB (0x1u << TCC_INTFLAG_FAULTB_Pos) +#define TCC_INTFLAG_FAULT0_Pos 14 /**< \brief (TCC_INTFLAG) Non-Recoverable Fault 0 */ +#define TCC_INTFLAG_FAULT0 (0x1u << TCC_INTFLAG_FAULT0_Pos) +#define TCC_INTFLAG_FAULT1_Pos 15 /**< \brief (TCC_INTFLAG) Non-Recoverable Fault 1 */ +#define TCC_INTFLAG_FAULT1 (0x1u << TCC_INTFLAG_FAULT1_Pos) +#define TCC_INTFLAG_MC0_Pos 16 /**< \brief (TCC_INTFLAG) Match or Capture 0 */ +#define TCC_INTFLAG_MC0 (1 << TCC_INTFLAG_MC0_Pos) +#define TCC_INTFLAG_MC1_Pos 17 /**< \brief (TCC_INTFLAG) Match or Capture 1 */ +#define TCC_INTFLAG_MC1 (1 << TCC_INTFLAG_MC1_Pos) +#define TCC_INTFLAG_MC2_Pos 18 /**< \brief (TCC_INTFLAG) Match or Capture 2 */ +#define TCC_INTFLAG_MC2 (1 << TCC_INTFLAG_MC2_Pos) +#define TCC_INTFLAG_MC3_Pos 19 /**< \brief (TCC_INTFLAG) Match or Capture 3 */ +#define TCC_INTFLAG_MC3 (1 << TCC_INTFLAG_MC3_Pos) +#define TCC_INTFLAG_MC_Pos 16 /**< \brief (TCC_INTFLAG) Match or Capture x */ +#define TCC_INTFLAG_MC_Msk (0xFu << TCC_INTFLAG_MC_Pos) +#define TCC_INTFLAG_MC(value) ((TCC_INTFLAG_MC_Msk & ((value) << TCC_INTFLAG_MC_Pos))) +#define TCC_INTFLAG_MASK 0x000FF80Fu /**< \brief (TCC_INTFLAG) MASK Register */ + +/* -------- TCC_STATUS : (TCC Offset: 0x30) (R/W 32) Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t STOP:1; /*!< bit: 0 Stop */ + uint32_t IDX:1; /*!< bit: 1 Ramp */ + uint32_t :1; /*!< bit: 2 Reserved */ + uint32_t DFS:1; /*!< bit: 3 Non-Recoverable Debug Fault State */ + uint32_t :1; /*!< bit: 4 Reserved */ + uint32_t PATTBV:1; /*!< bit: 5 Pattern Buffer Valid */ + uint32_t WAVEBV:1; /*!< bit: 6 Wave Buffer Valid */ + uint32_t PERBV:1; /*!< bit: 7 Period Buffer Valid */ + uint32_t FAULTAIN:1; /*!< bit: 8 Recoverable FaultA Input */ + uint32_t FAULTBIN:1; /*!< bit: 9 Recoverable FaultB Input */ + uint32_t FAULT0IN:1; /*!< bit: 10 Non-Recoverable Fault0 Input */ + uint32_t FAULT1IN:1; /*!< bit: 11 Non-Recoverable Fault1 Input */ + uint32_t FAULTA:1; /*!< bit: 12 Recoverable FaultA State */ + uint32_t FAULTB:1; /*!< bit: 13 Recoverable FaultB State */ + uint32_t FAULT0:1; /*!< bit: 14 Non-Recoverable Fault 0 State */ + uint32_t FAULT1:1; /*!< bit: 15 Non-Recoverable Fault 1 State */ + uint32_t CCBV0:1; /*!< bit: 16 Compare Channel 0 Buffer Valid */ + uint32_t CCBV1:1; /*!< bit: 17 Compare Channel 1 Buffer Valid */ + uint32_t CCBV2:1; /*!< bit: 18 Compare Channel 2 Buffer Valid */ + uint32_t CCBV3:1; /*!< bit: 19 Compare Channel 3 Buffer Valid */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t CMP0:1; /*!< bit: 24 Compare Channel 0 Value */ + uint32_t CMP1:1; /*!< bit: 25 Compare Channel 1 Value */ + uint32_t CMP2:1; /*!< bit: 26 Compare Channel 2 Value */ + uint32_t CMP3:1; /*!< bit: 27 Compare Channel 3 Value */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :16; /*!< bit: 0..15 Reserved */ + uint32_t CCBV:4; /*!< bit: 16..19 Compare Channel x Buffer Valid */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t CMP:4; /*!< bit: 24..27 Compare Channel x Value */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_STATUS_OFFSET 0x30 /**< \brief (TCC_STATUS offset) Status */ +#define TCC_STATUS_RESETVALUE 0x00000001 /**< \brief (TCC_STATUS reset_value) Status */ + +#define TCC_STATUS_STOP_Pos 0 /**< \brief (TCC_STATUS) Stop */ +#define TCC_STATUS_STOP (0x1u << TCC_STATUS_STOP_Pos) +#define TCC_STATUS_IDX_Pos 1 /**< \brief (TCC_STATUS) Ramp */ +#define TCC_STATUS_IDX (0x1u << TCC_STATUS_IDX_Pos) +#define TCC_STATUS_DFS_Pos 3 /**< \brief (TCC_STATUS) Non-Recoverable Debug Fault State */ +#define TCC_STATUS_DFS (0x1u << TCC_STATUS_DFS_Pos) +#define TCC_STATUS_PATTBV_Pos 5 /**< \brief (TCC_STATUS) Pattern Buffer Valid */ +#define TCC_STATUS_PATTBV (0x1u << TCC_STATUS_PATTBV_Pos) +#define TCC_STATUS_WAVEBV_Pos 6 /**< \brief (TCC_STATUS) Wave Buffer Valid */ +#define TCC_STATUS_WAVEBV (0x1u << TCC_STATUS_WAVEBV_Pos) +#define TCC_STATUS_PERBV_Pos 7 /**< \brief (TCC_STATUS) Period Buffer Valid */ +#define TCC_STATUS_PERBV (0x1u << TCC_STATUS_PERBV_Pos) +#define TCC_STATUS_FAULTAIN_Pos 8 /**< \brief (TCC_STATUS) Recoverable FaultA Input */ +#define TCC_STATUS_FAULTAIN (0x1u << TCC_STATUS_FAULTAIN_Pos) +#define TCC_STATUS_FAULTBIN_Pos 9 /**< \brief (TCC_STATUS) Recoverable FaultB Input */ +#define TCC_STATUS_FAULTBIN (0x1u << TCC_STATUS_FAULTBIN_Pos) +#define TCC_STATUS_FAULT0IN_Pos 10 /**< \brief (TCC_STATUS) Non-Recoverable Fault0 Input */ +#define TCC_STATUS_FAULT0IN (0x1u << TCC_STATUS_FAULT0IN_Pos) +#define TCC_STATUS_FAULT1IN_Pos 11 /**< \brief (TCC_STATUS) Non-Recoverable Fault1 Input */ +#define TCC_STATUS_FAULT1IN (0x1u << TCC_STATUS_FAULT1IN_Pos) +#define TCC_STATUS_FAULTA_Pos 12 /**< \brief (TCC_STATUS) Recoverable FaultA State */ +#define TCC_STATUS_FAULTA (0x1u << TCC_STATUS_FAULTA_Pos) +#define TCC_STATUS_FAULTB_Pos 13 /**< \brief (TCC_STATUS) Recoverable FaultB State */ +#define TCC_STATUS_FAULTB (0x1u << TCC_STATUS_FAULTB_Pos) +#define TCC_STATUS_FAULT0_Pos 14 /**< \brief (TCC_STATUS) Non-Recoverable Fault 0 State */ +#define TCC_STATUS_FAULT0 (0x1u << TCC_STATUS_FAULT0_Pos) +#define TCC_STATUS_FAULT1_Pos 15 /**< \brief (TCC_STATUS) Non-Recoverable Fault 1 State */ +#define TCC_STATUS_FAULT1 (0x1u << TCC_STATUS_FAULT1_Pos) +#define TCC_STATUS_CCBV0_Pos 16 /**< \brief (TCC_STATUS) Compare Channel 0 Buffer Valid */ +#define TCC_STATUS_CCBV0 (1 << TCC_STATUS_CCBV0_Pos) +#define TCC_STATUS_CCBV1_Pos 17 /**< \brief (TCC_STATUS) Compare Channel 1 Buffer Valid */ +#define TCC_STATUS_CCBV1 (1 << TCC_STATUS_CCBV1_Pos) +#define TCC_STATUS_CCBV2_Pos 18 /**< \brief (TCC_STATUS) Compare Channel 2 Buffer Valid */ +#define TCC_STATUS_CCBV2 (1 << TCC_STATUS_CCBV2_Pos) +#define TCC_STATUS_CCBV3_Pos 19 /**< \brief (TCC_STATUS) Compare Channel 3 Buffer Valid */ +#define TCC_STATUS_CCBV3 (1 << TCC_STATUS_CCBV3_Pos) +#define TCC_STATUS_CCBV_Pos 16 /**< \brief (TCC_STATUS) Compare Channel x Buffer Valid */ +#define TCC_STATUS_CCBV_Msk (0xFu << TCC_STATUS_CCBV_Pos) +#define TCC_STATUS_CCBV(value) ((TCC_STATUS_CCBV_Msk & ((value) << TCC_STATUS_CCBV_Pos))) +#define TCC_STATUS_CMP0_Pos 24 /**< \brief (TCC_STATUS) Compare Channel 0 Value */ +#define TCC_STATUS_CMP0 (1 << TCC_STATUS_CMP0_Pos) +#define TCC_STATUS_CMP1_Pos 25 /**< \brief (TCC_STATUS) Compare Channel 1 Value */ +#define TCC_STATUS_CMP1 (1 << TCC_STATUS_CMP1_Pos) +#define TCC_STATUS_CMP2_Pos 26 /**< \brief (TCC_STATUS) Compare Channel 2 Value */ +#define TCC_STATUS_CMP2 (1 << TCC_STATUS_CMP2_Pos) +#define TCC_STATUS_CMP3_Pos 27 /**< \brief (TCC_STATUS) Compare Channel 3 Value */ +#define TCC_STATUS_CMP3 (1 << TCC_STATUS_CMP3_Pos) +#define TCC_STATUS_CMP_Pos 24 /**< \brief (TCC_STATUS) Compare Channel x Value */ +#define TCC_STATUS_CMP_Msk (0xFu << TCC_STATUS_CMP_Pos) +#define TCC_STATUS_CMP(value) ((TCC_STATUS_CMP_Msk & ((value) << TCC_STATUS_CMP_Pos))) +#define TCC_STATUS_MASK 0x0F0FFFEBu /**< \brief (TCC_STATUS) MASK Register */ + +/* -------- TCC_COUNT : (TCC Offset: 0x34) (R/W 32) Count -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t COUNT:24; /*!< bit: 0..23 Count Value */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_COUNT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_COUNT_OFFSET 0x34 /**< \brief (TCC_COUNT offset) Count */ +#define TCC_COUNT_RESETVALUE 0x00000000 /**< \brief (TCC_COUNT reset_value) Count */ + +#define TCC_COUNT_COUNT_Pos 0 /**< \brief (TCC_COUNT) Count Value */ +#define TCC_COUNT_COUNT_Msk (0xFFFFFFu << TCC_COUNT_COUNT_Pos) +#define TCC_COUNT_COUNT(value) ((TCC_COUNT_COUNT_Msk & ((value) << TCC_COUNT_COUNT_Pos))) +#define TCC_COUNT_MASK 0x00FFFFFFu /**< \brief (TCC_COUNT) MASK Register */ + +/* -------- TCC_PATT : (TCC Offset: 0x38) (R/W 16) Pattern -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t PGE0:1; /*!< bit: 0 Pattern Generator 0 Output Enable */ + uint16_t PGE1:1; /*!< bit: 1 Pattern Generator 1 Output Enable */ + uint16_t PGE2:1; /*!< bit: 2 Pattern Generator 2 Output Enable */ + uint16_t PGE3:1; /*!< bit: 3 Pattern Generator 3 Output Enable */ + uint16_t PGE4:1; /*!< bit: 4 Pattern Generator 4 Output Enable */ + uint16_t PGE5:1; /*!< bit: 5 Pattern Generator 5 Output Enable */ + uint16_t PGE6:1; /*!< bit: 6 Pattern Generator 6 Output Enable */ + uint16_t PGE7:1; /*!< bit: 7 Pattern Generator 7 Output Enable */ + uint16_t PGV0:1; /*!< bit: 8 Pattern Generator 0 Output Value */ + uint16_t PGV1:1; /*!< bit: 9 Pattern Generator 1 Output Value */ + uint16_t PGV2:1; /*!< bit: 10 Pattern Generator 2 Output Value */ + uint16_t PGV3:1; /*!< bit: 11 Pattern Generator 3 Output Value */ + uint16_t PGV4:1; /*!< bit: 12 Pattern Generator 4 Output Value */ + uint16_t PGV5:1; /*!< bit: 13 Pattern Generator 5 Output Value */ + uint16_t PGV6:1; /*!< bit: 14 Pattern Generator 6 Output Value */ + uint16_t PGV7:1; /*!< bit: 15 Pattern Generator 7 Output Value */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t PGE:8; /*!< bit: 0.. 7 Pattern Generator x Output Enable */ + uint16_t PGV:8; /*!< bit: 8..15 Pattern Generator x Output Value */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} TCC_PATT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_PATT_OFFSET 0x38 /**< \brief (TCC_PATT offset) Pattern */ +#define TCC_PATT_RESETVALUE 0x0000 /**< \brief (TCC_PATT reset_value) Pattern */ + +#define TCC_PATT_PGE0_Pos 0 /**< \brief (TCC_PATT) Pattern Generator 0 Output Enable */ +#define TCC_PATT_PGE0 (1 << TCC_PATT_PGE0_Pos) +#define TCC_PATT_PGE1_Pos 1 /**< \brief (TCC_PATT) Pattern Generator 1 Output Enable */ +#define TCC_PATT_PGE1 (1 << TCC_PATT_PGE1_Pos) +#define TCC_PATT_PGE2_Pos 2 /**< \brief (TCC_PATT) Pattern Generator 2 Output Enable */ +#define TCC_PATT_PGE2 (1 << TCC_PATT_PGE2_Pos) +#define TCC_PATT_PGE3_Pos 3 /**< \brief (TCC_PATT) Pattern Generator 3 Output Enable */ +#define TCC_PATT_PGE3 (1 << TCC_PATT_PGE3_Pos) +#define TCC_PATT_PGE4_Pos 4 /**< \brief (TCC_PATT) Pattern Generator 4 Output Enable */ +#define TCC_PATT_PGE4 (1 << TCC_PATT_PGE4_Pos) +#define TCC_PATT_PGE5_Pos 5 /**< \brief (TCC_PATT) Pattern Generator 5 Output Enable */ +#define TCC_PATT_PGE5 (1 << TCC_PATT_PGE5_Pos) +#define TCC_PATT_PGE6_Pos 6 /**< \brief (TCC_PATT) Pattern Generator 6 Output Enable */ +#define TCC_PATT_PGE6 (1 << TCC_PATT_PGE6_Pos) +#define TCC_PATT_PGE7_Pos 7 /**< \brief (TCC_PATT) Pattern Generator 7 Output Enable */ +#define TCC_PATT_PGE7 (1 << TCC_PATT_PGE7_Pos) +#define TCC_PATT_PGE_Pos 0 /**< \brief (TCC_PATT) Pattern Generator x Output Enable */ +#define TCC_PATT_PGE_Msk (0xFFu << TCC_PATT_PGE_Pos) +#define TCC_PATT_PGE(value) ((TCC_PATT_PGE_Msk & ((value) << TCC_PATT_PGE_Pos))) +#define TCC_PATT_PGV0_Pos 8 /**< \brief (TCC_PATT) Pattern Generator 0 Output Value */ +#define TCC_PATT_PGV0 (1 << TCC_PATT_PGV0_Pos) +#define TCC_PATT_PGV1_Pos 9 /**< \brief (TCC_PATT) Pattern Generator 1 Output Value */ +#define TCC_PATT_PGV1 (1 << TCC_PATT_PGV1_Pos) +#define TCC_PATT_PGV2_Pos 10 /**< \brief (TCC_PATT) Pattern Generator 2 Output Value */ +#define TCC_PATT_PGV2 (1 << TCC_PATT_PGV2_Pos) +#define TCC_PATT_PGV3_Pos 11 /**< \brief (TCC_PATT) Pattern Generator 3 Output Value */ +#define TCC_PATT_PGV3 (1 << TCC_PATT_PGV3_Pos) +#define TCC_PATT_PGV4_Pos 12 /**< \brief (TCC_PATT) Pattern Generator 4 Output Value */ +#define TCC_PATT_PGV4 (1 << TCC_PATT_PGV4_Pos) +#define TCC_PATT_PGV5_Pos 13 /**< \brief (TCC_PATT) Pattern Generator 5 Output Value */ +#define TCC_PATT_PGV5 (1 << TCC_PATT_PGV5_Pos) +#define TCC_PATT_PGV6_Pos 14 /**< \brief (TCC_PATT) Pattern Generator 6 Output Value */ +#define TCC_PATT_PGV6 (1 << TCC_PATT_PGV6_Pos) +#define TCC_PATT_PGV7_Pos 15 /**< \brief (TCC_PATT) Pattern Generator 7 Output Value */ +#define TCC_PATT_PGV7 (1 << TCC_PATT_PGV7_Pos) +#define TCC_PATT_PGV_Pos 8 /**< \brief (TCC_PATT) Pattern Generator x Output Value */ +#define TCC_PATT_PGV_Msk (0xFFu << TCC_PATT_PGV_Pos) +#define TCC_PATT_PGV(value) ((TCC_PATT_PGV_Msk & ((value) << TCC_PATT_PGV_Pos))) +#define TCC_PATT_MASK 0xFFFFu /**< \brief (TCC_PATT) MASK Register */ + +/* -------- TCC_WAVE : (TCC Offset: 0x3C) (R/W 32) Waveform Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t WAVEGEN:3; /*!< bit: 0.. 2 Waveform Generation */ + uint32_t :1; /*!< bit: 3 Reserved */ + uint32_t RAMP:2; /*!< bit: 4.. 5 Ramp Mode */ + uint32_t :1; /*!< bit: 6 Reserved */ + uint32_t CIPEREN:1; /*!< bit: 7 Circular period Enable */ + uint32_t CICCEN0:1; /*!< bit: 8 Circular Channel 0 Enable */ + uint32_t CICCEN1:1; /*!< bit: 9 Circular Channel 1 Enable */ + uint32_t CICCEN2:1; /*!< bit: 10 Circular Channel 2 Enable */ + uint32_t CICCEN3:1; /*!< bit: 11 Circular Channel 3 Enable */ + uint32_t :4; /*!< bit: 12..15 Reserved */ + uint32_t POL0:1; /*!< bit: 16 Channel 0 Polarity */ + uint32_t POL1:1; /*!< bit: 17 Channel 1 Polarity */ + uint32_t POL2:1; /*!< bit: 18 Channel 2 Polarity */ + uint32_t POL3:1; /*!< bit: 19 Channel 3 Polarity */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t SWAP0:1; /*!< bit: 24 Swap DTI Output Pair 0 */ + uint32_t SWAP1:1; /*!< bit: 25 Swap DTI Output Pair 1 */ + uint32_t SWAP2:1; /*!< bit: 26 Swap DTI Output Pair 2 */ + uint32_t SWAP3:1; /*!< bit: 27 Swap DTI Output Pair 3 */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :8; /*!< bit: 0.. 7 Reserved */ + uint32_t CICCEN:4; /*!< bit: 8..11 Circular Channel x Enable */ + uint32_t :4; /*!< bit: 12..15 Reserved */ + uint32_t POL:4; /*!< bit: 16..19 Channel x Polarity */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t SWAP:4; /*!< bit: 24..27 Swap DTI Output Pair x */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_WAVE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_WAVE_OFFSET 0x3C /**< \brief (TCC_WAVE offset) Waveform Control */ +#define TCC_WAVE_RESETVALUE 0x00000000 /**< \brief (TCC_WAVE reset_value) Waveform Control */ + +#define TCC_WAVE_WAVEGEN_Pos 0 /**< \brief (TCC_WAVE) Waveform Generation */ +#define TCC_WAVE_WAVEGEN_Msk (0x7u << TCC_WAVE_WAVEGEN_Pos) +#define TCC_WAVE_WAVEGEN(value) ((TCC_WAVE_WAVEGEN_Msk & ((value) << TCC_WAVE_WAVEGEN_Pos))) +#define TCC_WAVE_WAVEGEN_NFRQ_Val 0x0u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_WAVEGEN_MFRQ_Val 0x1u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_WAVEGEN_NPWM_Val 0x2u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_WAVEGEN_DSCRITICAL_Val 0x4u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_WAVEGEN_DSBOTTOM_Val 0x5u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_WAVEGEN_DSBOTH_Val 0x6u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_WAVEGEN_DSTOP_Val 0x7u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_WAVEGEN_NFRQ (TCC_WAVE_WAVEGEN_NFRQ_Val << TCC_WAVE_WAVEGEN_Pos) +#define TCC_WAVE_WAVEGEN_MFRQ (TCC_WAVE_WAVEGEN_MFRQ_Val << TCC_WAVE_WAVEGEN_Pos) +#define TCC_WAVE_WAVEGEN_NPWM (TCC_WAVE_WAVEGEN_NPWM_Val << TCC_WAVE_WAVEGEN_Pos) +#define TCC_WAVE_WAVEGEN_DSCRITICAL (TCC_WAVE_WAVEGEN_DSCRITICAL_Val << TCC_WAVE_WAVEGEN_Pos) +#define TCC_WAVE_WAVEGEN_DSBOTTOM (TCC_WAVE_WAVEGEN_DSBOTTOM_Val << TCC_WAVE_WAVEGEN_Pos) +#define TCC_WAVE_WAVEGEN_DSBOTH (TCC_WAVE_WAVEGEN_DSBOTH_Val << TCC_WAVE_WAVEGEN_Pos) +#define TCC_WAVE_WAVEGEN_DSTOP (TCC_WAVE_WAVEGEN_DSTOP_Val << TCC_WAVE_WAVEGEN_Pos) +#define TCC_WAVE_RAMP_Pos 4 /**< \brief (TCC_WAVE) Ramp Mode */ +#define TCC_WAVE_RAMP_Msk (0x3u << TCC_WAVE_RAMP_Pos) +#define TCC_WAVE_RAMP(value) ((TCC_WAVE_RAMP_Msk & ((value) << TCC_WAVE_RAMP_Pos))) +#define TCC_WAVE_RAMP_RAMP1_Val 0x0u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_RAMP_RAMP2A_Val 0x1u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_RAMP_RAMP2_Val 0x2u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_RAMP_RAMP1 (TCC_WAVE_RAMP_RAMP1_Val << TCC_WAVE_RAMP_Pos) +#define TCC_WAVE_RAMP_RAMP2A (TCC_WAVE_RAMP_RAMP2A_Val << TCC_WAVE_RAMP_Pos) +#define TCC_WAVE_RAMP_RAMP2 (TCC_WAVE_RAMP_RAMP2_Val << TCC_WAVE_RAMP_Pos) +#define TCC_WAVE_CIPEREN_Pos 7 /**< \brief (TCC_WAVE) Circular period Enable */ +#define TCC_WAVE_CIPEREN (0x1u << TCC_WAVE_CIPEREN_Pos) +#define TCC_WAVE_CICCEN0_Pos 8 /**< \brief (TCC_WAVE) Circular Channel 0 Enable */ +#define TCC_WAVE_CICCEN0 (1 << TCC_WAVE_CICCEN0_Pos) +#define TCC_WAVE_CICCEN1_Pos 9 /**< \brief (TCC_WAVE) Circular Channel 1 Enable */ +#define TCC_WAVE_CICCEN1 (1 << TCC_WAVE_CICCEN1_Pos) +#define TCC_WAVE_CICCEN2_Pos 10 /**< \brief (TCC_WAVE) Circular Channel 2 Enable */ +#define TCC_WAVE_CICCEN2 (1 << TCC_WAVE_CICCEN2_Pos) +#define TCC_WAVE_CICCEN3_Pos 11 /**< \brief (TCC_WAVE) Circular Channel 3 Enable */ +#define TCC_WAVE_CICCEN3 (1 << TCC_WAVE_CICCEN3_Pos) +#define TCC_WAVE_CICCEN_Pos 8 /**< \brief (TCC_WAVE) Circular Channel x Enable */ +#define TCC_WAVE_CICCEN_Msk (0xFu << TCC_WAVE_CICCEN_Pos) +#define TCC_WAVE_CICCEN(value) ((TCC_WAVE_CICCEN_Msk & ((value) << TCC_WAVE_CICCEN_Pos))) +#define TCC_WAVE_POL0_Pos 16 /**< \brief (TCC_WAVE) Channel 0 Polarity */ +#define TCC_WAVE_POL0 (1 << TCC_WAVE_POL0_Pos) +#define TCC_WAVE_POL1_Pos 17 /**< \brief (TCC_WAVE) Channel 1 Polarity */ +#define TCC_WAVE_POL1 (1 << TCC_WAVE_POL1_Pos) +#define TCC_WAVE_POL2_Pos 18 /**< \brief (TCC_WAVE) Channel 2 Polarity */ +#define TCC_WAVE_POL2 (1 << TCC_WAVE_POL2_Pos) +#define TCC_WAVE_POL3_Pos 19 /**< \brief (TCC_WAVE) Channel 3 Polarity */ +#define TCC_WAVE_POL3 (1 << TCC_WAVE_POL3_Pos) +#define TCC_WAVE_POL_Pos 16 /**< \brief (TCC_WAVE) Channel x Polarity */ +#define TCC_WAVE_POL_Msk (0xFu << TCC_WAVE_POL_Pos) +#define TCC_WAVE_POL(value) ((TCC_WAVE_POL_Msk & ((value) << TCC_WAVE_POL_Pos))) +#define TCC_WAVE_SWAP0_Pos 24 /**< \brief (TCC_WAVE) Swap DTI Output Pair 0 */ +#define TCC_WAVE_SWAP0 (1 << TCC_WAVE_SWAP0_Pos) +#define TCC_WAVE_SWAP1_Pos 25 /**< \brief (TCC_WAVE) Swap DTI Output Pair 1 */ +#define TCC_WAVE_SWAP1 (1 << TCC_WAVE_SWAP1_Pos) +#define TCC_WAVE_SWAP2_Pos 26 /**< \brief (TCC_WAVE) Swap DTI Output Pair 2 */ +#define TCC_WAVE_SWAP2 (1 << TCC_WAVE_SWAP2_Pos) +#define TCC_WAVE_SWAP3_Pos 27 /**< \brief (TCC_WAVE) Swap DTI Output Pair 3 */ +#define TCC_WAVE_SWAP3 (1 << TCC_WAVE_SWAP3_Pos) +#define TCC_WAVE_SWAP_Pos 24 /**< \brief (TCC_WAVE) Swap DTI Output Pair x */ +#define TCC_WAVE_SWAP_Msk (0xFu << TCC_WAVE_SWAP_Pos) +#define TCC_WAVE_SWAP(value) ((TCC_WAVE_SWAP_Msk & ((value) << TCC_WAVE_SWAP_Pos))) +#define TCC_WAVE_MASK 0x0F0F0FB7u /**< \brief (TCC_WAVE) MASK Register */ + +/* -------- TCC_PER : (TCC Offset: 0x40) (R/W 32) Period -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PER:24; /*!< bit: 0..23 Period Value */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_PER_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_PER_OFFSET 0x40 /**< \brief (TCC_PER offset) Period */ +#define TCC_PER_RESETVALUE 0xFFFFFFFF /**< \brief (TCC_PER reset_value) Period */ + +#define TCC_PER_PER_Pos 0 /**< \brief (TCC_PER) Period Value */ +#define TCC_PER_PER_Msk (0xFFFFFFu << TCC_PER_PER_Pos) +#define TCC_PER_PER(value) ((TCC_PER_PER_Msk & ((value) << TCC_PER_PER_Pos))) +#define TCC_PER_MASK 0x00FFFFFFu /**< \brief (TCC_PER) MASK Register */ + +/* -------- TCC_CC : (TCC Offset: 0x44) (R/W 32) Compare and Capture -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CC:24; /*!< bit: 0..23 Compare and Capture value */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_CC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_CC_OFFSET 0x44 /**< \brief (TCC_CC offset) Compare and Capture */ +#define TCC_CC_RESETVALUE 0x00000000 /**< \brief (TCC_CC reset_value) Compare and Capture */ + +#define TCC_CC_CC_Pos 0 /**< \brief (TCC_CC) Compare and Capture value */ +#define TCC_CC_CC_Msk (0xFFFFFFu << TCC_CC_CC_Pos) +#define TCC_CC_CC(value) ((TCC_CC_CC_Msk & ((value) << TCC_CC_CC_Pos))) +#define TCC_CC_MASK 0x00FFFFFFu /**< \brief (TCC_CC) MASK Register */ + +/* -------- TCC_PATTB : (TCC Offset: 0x64) (R/W 16) Pattern Buffer -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t PGEB0:1; /*!< bit: 0 Pattern Generator 0 Output Enable Buffer */ + uint16_t PGEB1:1; /*!< bit: 1 Pattern Generator 1 Output Enable Buffer */ + uint16_t PGEB2:1; /*!< bit: 2 Pattern Generator 2 Output Enable Buffer */ + uint16_t PGEB3:1; /*!< bit: 3 Pattern Generator 3 Output Enable Buffer */ + uint16_t PGEB4:1; /*!< bit: 4 Pattern Generator 4 Output Enable Buffer */ + uint16_t PGEB5:1; /*!< bit: 5 Pattern Generator 5 Output Enable Buffer */ + uint16_t PGEB6:1; /*!< bit: 6 Pattern Generator 6 Output Enable Buffer */ + uint16_t PGEB7:1; /*!< bit: 7 Pattern Generator 7 Output Enable Buffer */ + uint16_t PGVB0:1; /*!< bit: 8 Pattern Generator 0 Output Enable */ + uint16_t PGVB1:1; /*!< bit: 9 Pattern Generator 1 Output Enable */ + uint16_t PGVB2:1; /*!< bit: 10 Pattern Generator 2 Output Enable */ + uint16_t PGVB3:1; /*!< bit: 11 Pattern Generator 3 Output Enable */ + uint16_t PGVB4:1; /*!< bit: 12 Pattern Generator 4 Output Enable */ + uint16_t PGVB5:1; /*!< bit: 13 Pattern Generator 5 Output Enable */ + uint16_t PGVB6:1; /*!< bit: 14 Pattern Generator 6 Output Enable */ + uint16_t PGVB7:1; /*!< bit: 15 Pattern Generator 7 Output Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t PGEB:8; /*!< bit: 0.. 7 Pattern Generator x Output Enable Buffer */ + uint16_t PGVB:8; /*!< bit: 8..15 Pattern Generator x Output Enable */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} TCC_PATTB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_PATTB_OFFSET 0x64 /**< \brief (TCC_PATTB offset) Pattern Buffer */ +#define TCC_PATTB_RESETVALUE 0x0000 /**< \brief (TCC_PATTB reset_value) Pattern Buffer */ + +#define TCC_PATTB_PGEB0_Pos 0 /**< \brief (TCC_PATTB) Pattern Generator 0 Output Enable Buffer */ +#define TCC_PATTB_PGEB0 (1 << TCC_PATTB_PGEB0_Pos) +#define TCC_PATTB_PGEB1_Pos 1 /**< \brief (TCC_PATTB) Pattern Generator 1 Output Enable Buffer */ +#define TCC_PATTB_PGEB1 (1 << TCC_PATTB_PGEB1_Pos) +#define TCC_PATTB_PGEB2_Pos 2 /**< \brief (TCC_PATTB) Pattern Generator 2 Output Enable Buffer */ +#define TCC_PATTB_PGEB2 (1 << TCC_PATTB_PGEB2_Pos) +#define TCC_PATTB_PGEB3_Pos 3 /**< \brief (TCC_PATTB) Pattern Generator 3 Output Enable Buffer */ +#define TCC_PATTB_PGEB3 (1 << TCC_PATTB_PGEB3_Pos) +#define TCC_PATTB_PGEB4_Pos 4 /**< \brief (TCC_PATTB) Pattern Generator 4 Output Enable Buffer */ +#define TCC_PATTB_PGEB4 (1 << TCC_PATTB_PGEB4_Pos) +#define TCC_PATTB_PGEB5_Pos 5 /**< \brief (TCC_PATTB) Pattern Generator 5 Output Enable Buffer */ +#define TCC_PATTB_PGEB5 (1 << TCC_PATTB_PGEB5_Pos) +#define TCC_PATTB_PGEB6_Pos 6 /**< \brief (TCC_PATTB) Pattern Generator 6 Output Enable Buffer */ +#define TCC_PATTB_PGEB6 (1 << TCC_PATTB_PGEB6_Pos) +#define TCC_PATTB_PGEB7_Pos 7 /**< \brief (TCC_PATTB) Pattern Generator 7 Output Enable Buffer */ +#define TCC_PATTB_PGEB7 (1 << TCC_PATTB_PGEB7_Pos) +#define TCC_PATTB_PGEB_Pos 0 /**< \brief (TCC_PATTB) Pattern Generator x Output Enable Buffer */ +#define TCC_PATTB_PGEB_Msk (0xFFu << TCC_PATTB_PGEB_Pos) +#define TCC_PATTB_PGEB(value) ((TCC_PATTB_PGEB_Msk & ((value) << TCC_PATTB_PGEB_Pos))) +#define TCC_PATTB_PGVB0_Pos 8 /**< \brief (TCC_PATTB) Pattern Generator 0 Output Enable */ +#define TCC_PATTB_PGVB0 (1 << TCC_PATTB_PGVB0_Pos) +#define TCC_PATTB_PGVB1_Pos 9 /**< \brief (TCC_PATTB) Pattern Generator 1 Output Enable */ +#define TCC_PATTB_PGVB1 (1 << TCC_PATTB_PGVB1_Pos) +#define TCC_PATTB_PGVB2_Pos 10 /**< \brief (TCC_PATTB) Pattern Generator 2 Output Enable */ +#define TCC_PATTB_PGVB2 (1 << TCC_PATTB_PGVB2_Pos) +#define TCC_PATTB_PGVB3_Pos 11 /**< \brief (TCC_PATTB) Pattern Generator 3 Output Enable */ +#define TCC_PATTB_PGVB3 (1 << TCC_PATTB_PGVB3_Pos) +#define TCC_PATTB_PGVB4_Pos 12 /**< \brief (TCC_PATTB) Pattern Generator 4 Output Enable */ +#define TCC_PATTB_PGVB4 (1 << TCC_PATTB_PGVB4_Pos) +#define TCC_PATTB_PGVB5_Pos 13 /**< \brief (TCC_PATTB) Pattern Generator 5 Output Enable */ +#define TCC_PATTB_PGVB5 (1 << TCC_PATTB_PGVB5_Pos) +#define TCC_PATTB_PGVB6_Pos 14 /**< \brief (TCC_PATTB) Pattern Generator 6 Output Enable */ +#define TCC_PATTB_PGVB6 (1 << TCC_PATTB_PGVB6_Pos) +#define TCC_PATTB_PGVB7_Pos 15 /**< \brief (TCC_PATTB) Pattern Generator 7 Output Enable */ +#define TCC_PATTB_PGVB7 (1 << TCC_PATTB_PGVB7_Pos) +#define TCC_PATTB_PGVB_Pos 8 /**< \brief (TCC_PATTB) Pattern Generator x Output Enable */ +#define TCC_PATTB_PGVB_Msk (0xFFu << TCC_PATTB_PGVB_Pos) +#define TCC_PATTB_PGVB(value) ((TCC_PATTB_PGVB_Msk & ((value) << TCC_PATTB_PGVB_Pos))) +#define TCC_PATTB_MASK 0xFFFFu /**< \brief (TCC_PATTB) MASK Register */ + +/* -------- TCC_WAVEB : (TCC Offset: 0x68) (R/W 32) Waveform Control Buffer -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t WAVEGENB:3; /*!< bit: 0.. 2 Waveform Generation Buffer */ + uint32_t :1; /*!< bit: 3 Reserved */ + uint32_t RAMPB:2; /*!< bit: 4.. 5 Ramp Mode Buffer */ + uint32_t :1; /*!< bit: 6 Reserved */ + uint32_t CIPERENB:1; /*!< bit: 7 Circular Period Enable Buffer */ + uint32_t CICCENB0:1; /*!< bit: 8 Circular Channel 0 Enable Buffer */ + uint32_t CICCENB1:1; /*!< bit: 9 Circular Channel 1 Enable Buffer */ + uint32_t CICCENB2:1; /*!< bit: 10 Circular Channel 2 Enable Buffer */ + uint32_t CICCENB3:1; /*!< bit: 11 Circular Channel 3 Enable Buffer */ + uint32_t :4; /*!< bit: 12..15 Reserved */ + uint32_t POLB0:1; /*!< bit: 16 Channel 0 Polarity Buffer */ + uint32_t POLB1:1; /*!< bit: 17 Channel 1 Polarity Buffer */ + uint32_t POLB2:1; /*!< bit: 18 Channel 2 Polarity Buffer */ + uint32_t POLB3:1; /*!< bit: 19 Channel 3 Polarity Buffer */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t SWAPB0:1; /*!< bit: 24 Swap DTI Output Pair 0 Buffer */ + uint32_t SWAPB1:1; /*!< bit: 25 Swap DTI Output Pair 1 Buffer */ + uint32_t SWAPB2:1; /*!< bit: 26 Swap DTI Output Pair 2 Buffer */ + uint32_t SWAPB3:1; /*!< bit: 27 Swap DTI Output Pair 3 Buffer */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :8; /*!< bit: 0.. 7 Reserved */ + uint32_t CICCENB:4; /*!< bit: 8..11 Circular Channel x Enable Buffer */ + uint32_t :4; /*!< bit: 12..15 Reserved */ + uint32_t POLB:4; /*!< bit: 16..19 Channel x Polarity Buffer */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t SWAPB:4; /*!< bit: 24..27 Swap DTI Output Pair x Buffer */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_WAVEB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_WAVEB_OFFSET 0x68 /**< \brief (TCC_WAVEB offset) Waveform Control Buffer */ +#define TCC_WAVEB_RESETVALUE 0x00000000 /**< \brief (TCC_WAVEB reset_value) Waveform Control Buffer */ + +#define TCC_WAVEB_WAVEGENB_Pos 0 /**< \brief (TCC_WAVEB) Waveform Generation Buffer */ +#define TCC_WAVEB_WAVEGENB_Msk (0x7u << TCC_WAVEB_WAVEGENB_Pos) +#define TCC_WAVEB_WAVEGENB(value) ((TCC_WAVEB_WAVEGENB_Msk & ((value) << TCC_WAVEB_WAVEGENB_Pos))) +#define TCC_WAVEB_WAVEGENB_NFRQ_Val 0x0u /**< \brief (TCC_WAVEB) */ +#define TCC_WAVEB_WAVEGENB_MFRQ_Val 0x1u /**< \brief (TCC_WAVEB) */ +#define TCC_WAVEB_WAVEGENB_NPWM_Val 0x2u /**< \brief (TCC_WAVEB) */ +#define TCC_WAVEB_WAVEGENB_DSCRITICAL_Val 0x4u /**< \brief (TCC_WAVEB) */ +#define TCC_WAVEB_WAVEGENB_DSBOTTOM_Val 0x5u /**< \brief (TCC_WAVEB) */ +#define TCC_WAVEB_WAVEGENB_DSBOTH_Val 0x6u /**< \brief (TCC_WAVEB) */ +#define TCC_WAVEB_WAVEGENB_DSTOP_Val 0x7u /**< \brief (TCC_WAVEB) */ +#define TCC_WAVEB_WAVEGENB_NFRQ (TCC_WAVEB_WAVEGENB_NFRQ_Val << TCC_WAVEB_WAVEGENB_Pos) +#define TCC_WAVEB_WAVEGENB_MFRQ (TCC_WAVEB_WAVEGENB_MFRQ_Val << TCC_WAVEB_WAVEGENB_Pos) +#define TCC_WAVEB_WAVEGENB_NPWM (TCC_WAVEB_WAVEGENB_NPWM_Val << TCC_WAVEB_WAVEGENB_Pos) +#define TCC_WAVEB_WAVEGENB_DSCRITICAL (TCC_WAVEB_WAVEGENB_DSCRITICAL_Val << TCC_WAVEB_WAVEGENB_Pos) +#define TCC_WAVEB_WAVEGENB_DSBOTTOM (TCC_WAVEB_WAVEGENB_DSBOTTOM_Val << TCC_WAVEB_WAVEGENB_Pos) +#define TCC_WAVEB_WAVEGENB_DSBOTH (TCC_WAVEB_WAVEGENB_DSBOTH_Val << TCC_WAVEB_WAVEGENB_Pos) +#define TCC_WAVEB_WAVEGENB_DSTOP (TCC_WAVEB_WAVEGENB_DSTOP_Val << TCC_WAVEB_WAVEGENB_Pos) +#define TCC_WAVEB_RAMPB_Pos 4 /**< \brief (TCC_WAVEB) Ramp Mode Buffer */ +#define TCC_WAVEB_RAMPB_Msk (0x3u << TCC_WAVEB_RAMPB_Pos) +#define TCC_WAVEB_RAMPB(value) ((TCC_WAVEB_RAMPB_Msk & ((value) << TCC_WAVEB_RAMPB_Pos))) +#define TCC_WAVEB_CIPERENB_Pos 7 /**< \brief (TCC_WAVEB) Circular Period Enable Buffer */ +#define TCC_WAVEB_CIPERENB (0x1u << TCC_WAVEB_CIPERENB_Pos) +#define TCC_WAVEB_CICCENB0_Pos 8 /**< \brief (TCC_WAVEB) Circular Channel 0 Enable Buffer */ +#define TCC_WAVEB_CICCENB0 (1 << TCC_WAVEB_CICCENB0_Pos) +#define TCC_WAVEB_CICCENB1_Pos 9 /**< \brief (TCC_WAVEB) Circular Channel 1 Enable Buffer */ +#define TCC_WAVEB_CICCENB1 (1 << TCC_WAVEB_CICCENB1_Pos) +#define TCC_WAVEB_CICCENB2_Pos 10 /**< \brief (TCC_WAVEB) Circular Channel 2 Enable Buffer */ +#define TCC_WAVEB_CICCENB2 (1 << TCC_WAVEB_CICCENB2_Pos) +#define TCC_WAVEB_CICCENB3_Pos 11 /**< \brief (TCC_WAVEB) Circular Channel 3 Enable Buffer */ +#define TCC_WAVEB_CICCENB3 (1 << TCC_WAVEB_CICCENB3_Pos) +#define TCC_WAVEB_CICCENB_Pos 8 /**< \brief (TCC_WAVEB) Circular Channel x Enable Buffer */ +#define TCC_WAVEB_CICCENB_Msk (0xFu << TCC_WAVEB_CICCENB_Pos) +#define TCC_WAVEB_CICCENB(value) ((TCC_WAVEB_CICCENB_Msk & ((value) << TCC_WAVEB_CICCENB_Pos))) +#define TCC_WAVEB_POLB0_Pos 16 /**< \brief (TCC_WAVEB) Channel 0 Polarity Buffer */ +#define TCC_WAVEB_POLB0 (1 << TCC_WAVEB_POLB0_Pos) +#define TCC_WAVEB_POLB1_Pos 17 /**< \brief (TCC_WAVEB) Channel 1 Polarity Buffer */ +#define TCC_WAVEB_POLB1 (1 << TCC_WAVEB_POLB1_Pos) +#define TCC_WAVEB_POLB2_Pos 18 /**< \brief (TCC_WAVEB) Channel 2 Polarity Buffer */ +#define TCC_WAVEB_POLB2 (1 << TCC_WAVEB_POLB2_Pos) +#define TCC_WAVEB_POLB3_Pos 19 /**< \brief (TCC_WAVEB) Channel 3 Polarity Buffer */ +#define TCC_WAVEB_POLB3 (1 << TCC_WAVEB_POLB3_Pos) +#define TCC_WAVEB_POLB_Pos 16 /**< \brief (TCC_WAVEB) Channel x Polarity Buffer */ +#define TCC_WAVEB_POLB_Msk (0xFu << TCC_WAVEB_POLB_Pos) +#define TCC_WAVEB_POLB(value) ((TCC_WAVEB_POLB_Msk & ((value) << TCC_WAVEB_POLB_Pos))) +#define TCC_WAVEB_SWAPB0_Pos 24 /**< \brief (TCC_WAVEB) Swap DTI Output Pair 0 Buffer */ +#define TCC_WAVEB_SWAPB0 (1 << TCC_WAVEB_SWAPB0_Pos) +#define TCC_WAVEB_SWAPB1_Pos 25 /**< \brief (TCC_WAVEB) Swap DTI Output Pair 1 Buffer */ +#define TCC_WAVEB_SWAPB1 (1 << TCC_WAVEB_SWAPB1_Pos) +#define TCC_WAVEB_SWAPB2_Pos 26 /**< \brief (TCC_WAVEB) Swap DTI Output Pair 2 Buffer */ +#define TCC_WAVEB_SWAPB2 (1 << TCC_WAVEB_SWAPB2_Pos) +#define TCC_WAVEB_SWAPB3_Pos 27 /**< \brief (TCC_WAVEB) Swap DTI Output Pair 3 Buffer */ +#define TCC_WAVEB_SWAPB3 (1 << TCC_WAVEB_SWAPB3_Pos) +#define TCC_WAVEB_SWAPB_Pos 24 /**< \brief (TCC_WAVEB) Swap DTI Output Pair x Buffer */ +#define TCC_WAVEB_SWAPB_Msk (0xFu << TCC_WAVEB_SWAPB_Pos) +#define TCC_WAVEB_SWAPB(value) ((TCC_WAVEB_SWAPB_Msk & ((value) << TCC_WAVEB_SWAPB_Pos))) +#define TCC_WAVEB_MASK 0x0F0F0FB7u /**< \brief (TCC_WAVEB) MASK Register */ + +/* -------- TCC_PERB : (TCC Offset: 0x6C) (R/W 32) Period Buffer -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PERB:24; /*!< bit: 0..23 Period Value */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_PERB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_PERB_OFFSET 0x6C /**< \brief (TCC_PERB offset) Period Buffer */ +#define TCC_PERB_RESETVALUE 0xFFFFFFFF /**< \brief (TCC_PERB reset_value) Period Buffer */ + +#define TCC_PERB_PERB_Pos 0 /**< \brief (TCC_PERB) Period Value */ +#define TCC_PERB_PERB_Msk (0xFFFFFFu << TCC_PERB_PERB_Pos) +#define TCC_PERB_PERB(value) ((TCC_PERB_PERB_Msk & ((value) << TCC_PERB_PERB_Pos))) +#define TCC_PERB_MASK 0x00FFFFFFu /**< \brief (TCC_PERB) MASK Register */ + +/* -------- TCC_CCB : (TCC Offset: 0x70) (R/W 32) Compare and Capture Buffer -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CCB:24; /*!< bit: 0..23 Compare and Capture buffer value */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_CCB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_CCB_OFFSET 0x70 /**< \brief (TCC_CCB offset) Compare and Capture Buffer */ +#define TCC_CCB_RESETVALUE 0x00000000 /**< \brief (TCC_CCB reset_value) Compare and Capture Buffer */ + +#define TCC_CCB_CCB_Pos 0 /**< \brief (TCC_CCB) Compare and Capture buffer value */ +#define TCC_CCB_CCB_Msk (0xFFFFFFu << TCC_CCB_CCB_Pos) +#define TCC_CCB_CCB(value) ((TCC_CCB_CCB_Msk & ((value) << TCC_CCB_CCB_Pos))) +#define TCC_CCB_MASK 0x00FFFFFFu /**< \brief (TCC_CCB) MASK Register */ + +/** \brief TCC hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO TCC_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 32) Control A */ + __IO TCC_CTRLBCLR_Type CTRLBCLR; /**< \brief Offset: 0x04 (R/W 8) Control B Clear */ + __IO TCC_CTRLBSET_Type CTRLBSET; /**< \brief Offset: 0x05 (R/W 8) Control B Set */ + RoReg8 Reserved1[0x2]; + __I TCC_SYNCBUSY_Type SYNCBUSY; /**< \brief Offset: 0x08 (R/ 32) Synchronization Busy */ + __IO TCC_FCTRLA_Type FCTRLA; /**< \brief Offset: 0x0C (R/W 32) Recoverable FaultA Configuration */ + __IO TCC_FCTRLB_Type FCTRLB; /**< \brief Offset: 0x10 (R/W 32) Recoverable FaultB Configuration */ + __IO TCC_WEXCTRL_Type WEXCTRL; /**< \brief Offset: 0x14 (R/W 32) Waveform Extension Configuration */ + __IO TCC_DRVCTRL_Type DRVCTRL; /**< \brief Offset: 0x18 (R/W 32) Driver Configuration */ + RoReg8 Reserved2[0x2]; + __IO TCC_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x1E (R/W 8) Debug Control */ + RoReg8 Reserved3[0x1]; + __IO TCC_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x20 (R/W 32) Event Control */ + __IO TCC_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x24 (R/W 32) Interrupt Enable Clear */ + __IO TCC_INTENSET_Type INTENSET; /**< \brief Offset: 0x28 (R/W 32) Interrupt Enable Set */ + __IO TCC_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x2C (R/W 32) Interrupt Flag Status and Clear */ + __IO TCC_STATUS_Type STATUS; /**< \brief Offset: 0x30 (R/W 32) Status */ + __IO TCC_COUNT_Type COUNT; /**< \brief Offset: 0x34 (R/W 32) Count */ + __IO TCC_PATT_Type PATT; /**< \brief Offset: 0x38 (R/W 16) Pattern */ + RoReg8 Reserved4[0x2]; + __IO TCC_WAVE_Type WAVE; /**< \brief Offset: 0x3C (R/W 32) Waveform Control */ + __IO TCC_PER_Type PER; /**< \brief Offset: 0x40 (R/W 32) Period */ + __IO TCC_CC_Type CC[4]; /**< \brief Offset: 0x44 (R/W 32) Compare and Capture */ + RoReg8 Reserved5[0x10]; + __IO TCC_PATTB_Type PATTB; /**< \brief Offset: 0x64 (R/W 16) Pattern Buffer */ + RoReg8 Reserved6[0x2]; + __IO TCC_WAVEB_Type WAVEB; /**< \brief Offset: 0x68 (R/W 32) Waveform Control Buffer */ + __IO TCC_PERB_Type PERB; /**< \brief Offset: 0x6C (R/W 32) Period Buffer */ + __IO TCC_CCB_Type CCB[4]; /**< \brief Offset: 0x70 (R/W 32) Compare and Capture Buffer */ +} Tcc; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_TCC_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/usb.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/usb.h new file mode 100644 index 0000000..9b33f78 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/usb.h @@ -0,0 +1,1767 @@ +/** + * \file + * + * \brief Component description for USB + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_USB_COMPONENT_ +#define _SAMD21_USB_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR USB */ +/* ========================================================================== */ +/** \addtogroup SAMD21_USB Universal Serial Bus */ +/*@{*/ + +#define USB_U2222 +#define REV_USB 0x101 + +/* -------- USB_CTRLA : (USB Offset: 0x000) (R/W 8) Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset */ + uint8_t ENABLE:1; /*!< bit: 1 Enable */ + uint8_t RUNSTDBY:1; /*!< bit: 2 Run in Standby Mode */ + uint8_t :4; /*!< bit: 3.. 6 Reserved */ + uint8_t MODE:1; /*!< bit: 7 Operating Mode */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_CTRLA_OFFSET 0x000 /**< \brief (USB_CTRLA offset) Control A */ +#define USB_CTRLA_RESETVALUE 0x00 /**< \brief (USB_CTRLA reset_value) Control A */ + +#define USB_CTRLA_SWRST_Pos 0 /**< \brief (USB_CTRLA) Software Reset */ +#define USB_CTRLA_SWRST (0x1u << USB_CTRLA_SWRST_Pos) +#define USB_CTRLA_ENABLE_Pos 1 /**< \brief (USB_CTRLA) Enable */ +#define USB_CTRLA_ENABLE (0x1u << USB_CTRLA_ENABLE_Pos) +#define USB_CTRLA_RUNSTDBY_Pos 2 /**< \brief (USB_CTRLA) Run in Standby Mode */ +#define USB_CTRLA_RUNSTDBY (0x1u << USB_CTRLA_RUNSTDBY_Pos) +#define USB_CTRLA_MODE_Pos 7 /**< \brief (USB_CTRLA) Operating Mode */ +#define USB_CTRLA_MODE (0x1u << USB_CTRLA_MODE_Pos) +#define USB_CTRLA_MODE_DEVICE_Val 0x0u /**< \brief (USB_CTRLA) Device Mode */ +#define USB_CTRLA_MODE_HOST_Val 0x1u /**< \brief (USB_CTRLA) Host Mode */ +#define USB_CTRLA_MODE_DEVICE (USB_CTRLA_MODE_DEVICE_Val << USB_CTRLA_MODE_Pos) +#define USB_CTRLA_MODE_HOST (USB_CTRLA_MODE_HOST_Val << USB_CTRLA_MODE_Pos) +#define USB_CTRLA_MASK 0x87u /**< \brief (USB_CTRLA) MASK Register */ + +/* -------- USB_SYNCBUSY : (USB Offset: 0x002) (R/ 8) Synchronization Busy -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset Synchronization Busy */ + uint8_t ENABLE:1; /*!< bit: 1 Enable Synchronization Busy */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_SYNCBUSY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_SYNCBUSY_OFFSET 0x002 /**< \brief (USB_SYNCBUSY offset) Synchronization Busy */ +#define USB_SYNCBUSY_RESETVALUE 0x00 /**< \brief (USB_SYNCBUSY reset_value) Synchronization Busy */ + +#define USB_SYNCBUSY_SWRST_Pos 0 /**< \brief (USB_SYNCBUSY) Software Reset Synchronization Busy */ +#define USB_SYNCBUSY_SWRST (0x1u << USB_SYNCBUSY_SWRST_Pos) +#define USB_SYNCBUSY_ENABLE_Pos 1 /**< \brief (USB_SYNCBUSY) Enable Synchronization Busy */ +#define USB_SYNCBUSY_ENABLE (0x1u << USB_SYNCBUSY_ENABLE_Pos) +#define USB_SYNCBUSY_MASK 0x03u /**< \brief (USB_SYNCBUSY) MASK Register */ + +/* -------- USB_DEVICE_CTRLB : (USB Offset: 0x008) (R/W 16) DEVICE DEVICE Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t DETACH:1; /*!< bit: 0 Detach */ + uint16_t UPRSM:1; /*!< bit: 1 Upstream Resume */ + uint16_t SPDCONF:2; /*!< bit: 2.. 3 Speed Configuration */ + uint16_t NREPLY:1; /*!< bit: 4 No Reply */ + uint16_t TSTJ:1; /*!< bit: 5 Test mode J */ + uint16_t TSTK:1; /*!< bit: 6 Test mode K */ + uint16_t TSTPCKT:1; /*!< bit: 7 Test packet mode */ + uint16_t OPMODE2:1; /*!< bit: 8 Specific Operational Mode */ + uint16_t GNAK:1; /*!< bit: 9 Global NAK */ + uint16_t LPMHDSK:2; /*!< bit: 10..11 Link Power Management Handshake */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_DEVICE_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_CTRLB_OFFSET 0x008 /**< \brief (USB_DEVICE_CTRLB offset) DEVICE Control B */ +#define USB_DEVICE_CTRLB_RESETVALUE 0x0001 /**< \brief (USB_DEVICE_CTRLB reset_value) DEVICE Control B */ + +#define USB_DEVICE_CTRLB_DETACH_Pos 0 /**< \brief (USB_DEVICE_CTRLB) Detach */ +#define USB_DEVICE_CTRLB_DETACH (0x1u << USB_DEVICE_CTRLB_DETACH_Pos) +#define USB_DEVICE_CTRLB_UPRSM_Pos 1 /**< \brief (USB_DEVICE_CTRLB) Upstream Resume */ +#define USB_DEVICE_CTRLB_UPRSM (0x1u << USB_DEVICE_CTRLB_UPRSM_Pos) +#define USB_DEVICE_CTRLB_SPDCONF_Pos 2 /**< \brief (USB_DEVICE_CTRLB) Speed Configuration */ +#define USB_DEVICE_CTRLB_SPDCONF_Msk (0x3u << USB_DEVICE_CTRLB_SPDCONF_Pos) +#define USB_DEVICE_CTRLB_SPDCONF(value) ((USB_DEVICE_CTRLB_SPDCONF_Msk & ((value) << USB_DEVICE_CTRLB_SPDCONF_Pos))) +#define USB_DEVICE_CTRLB_SPDCONF_0_Val 0x0u /**< \brief (USB_DEVICE_CTRLB) FS : Full Speed */ +#define USB_DEVICE_CTRLB_SPDCONF_1_Val 0x1u /**< \brief (USB_DEVICE_CTRLB) LS : Low Speed */ +#define USB_DEVICE_CTRLB_SPDCONF_2_Val 0x2u /**< \brief (USB_DEVICE_CTRLB) HS : High Speed capable */ +#define USB_DEVICE_CTRLB_SPDCONF_3_Val 0x3u /**< \brief (USB_DEVICE_CTRLB) HSTM: High Speed Test Mode (force high-speed mode for test mode) */ +#define USB_DEVICE_CTRLB_SPDCONF_0 (USB_DEVICE_CTRLB_SPDCONF_0_Val << USB_DEVICE_CTRLB_SPDCONF_Pos) +#define USB_DEVICE_CTRLB_SPDCONF_1 (USB_DEVICE_CTRLB_SPDCONF_1_Val << USB_DEVICE_CTRLB_SPDCONF_Pos) +#define USB_DEVICE_CTRLB_SPDCONF_2 (USB_DEVICE_CTRLB_SPDCONF_2_Val << USB_DEVICE_CTRLB_SPDCONF_Pos) +#define USB_DEVICE_CTRLB_SPDCONF_3 (USB_DEVICE_CTRLB_SPDCONF_3_Val << USB_DEVICE_CTRLB_SPDCONF_Pos) +#define USB_DEVICE_CTRLB_NREPLY_Pos 4 /**< \brief (USB_DEVICE_CTRLB) No Reply */ +#define USB_DEVICE_CTRLB_NREPLY (0x1u << USB_DEVICE_CTRLB_NREPLY_Pos) +#define USB_DEVICE_CTRLB_TSTJ_Pos 5 /**< \brief (USB_DEVICE_CTRLB) Test mode J */ +#define USB_DEVICE_CTRLB_TSTJ (0x1u << USB_DEVICE_CTRLB_TSTJ_Pos) +#define USB_DEVICE_CTRLB_TSTK_Pos 6 /**< \brief (USB_DEVICE_CTRLB) Test mode K */ +#define USB_DEVICE_CTRLB_TSTK (0x1u << USB_DEVICE_CTRLB_TSTK_Pos) +#define USB_DEVICE_CTRLB_TSTPCKT_Pos 7 /**< \brief (USB_DEVICE_CTRLB) Test packet mode */ +#define USB_DEVICE_CTRLB_TSTPCKT (0x1u << USB_DEVICE_CTRLB_TSTPCKT_Pos) +#define USB_DEVICE_CTRLB_OPMODE2_Pos 8 /**< \brief (USB_DEVICE_CTRLB) Specific Operational Mode */ +#define USB_DEVICE_CTRLB_OPMODE2 (0x1u << USB_DEVICE_CTRLB_OPMODE2_Pos) +#define USB_DEVICE_CTRLB_GNAK_Pos 9 /**< \brief (USB_DEVICE_CTRLB) Global NAK */ +#define USB_DEVICE_CTRLB_GNAK (0x1u << USB_DEVICE_CTRLB_GNAK_Pos) +#define USB_DEVICE_CTRLB_LPMHDSK_Pos 10 /**< \brief (USB_DEVICE_CTRLB) Link Power Management Handshake */ +#define USB_DEVICE_CTRLB_LPMHDSK_Msk (0x3u << USB_DEVICE_CTRLB_LPMHDSK_Pos) +#define USB_DEVICE_CTRLB_LPMHDSK(value) ((USB_DEVICE_CTRLB_LPMHDSK_Msk & ((value) << USB_DEVICE_CTRLB_LPMHDSK_Pos))) +#define USB_DEVICE_CTRLB_LPMHDSK_NO_Val 0x0u /**< \brief (USB_DEVICE_CTRLB) No handshake. LPM is not supported */ +#define USB_DEVICE_CTRLB_LPMHDSK_ACK_Val 0x1u /**< \brief (USB_DEVICE_CTRLB) ACK */ +#define USB_DEVICE_CTRLB_LPMHDSK_NYET_Val 0x2u /**< \brief (USB_DEVICE_CTRLB) NYET */ +#define USB_DEVICE_CTRLB_LPMHDSK_STALL_Val 0x3u /**< \brief (USB_DEVICE_CTRLB) STALL */ +#define USB_DEVICE_CTRLB_LPMHDSK_NO (USB_DEVICE_CTRLB_LPMHDSK_NO_Val << USB_DEVICE_CTRLB_LPMHDSK_Pos) +#define USB_DEVICE_CTRLB_LPMHDSK_ACK (USB_DEVICE_CTRLB_LPMHDSK_ACK_Val << USB_DEVICE_CTRLB_LPMHDSK_Pos) +#define USB_DEVICE_CTRLB_LPMHDSK_NYET (USB_DEVICE_CTRLB_LPMHDSK_NYET_Val << USB_DEVICE_CTRLB_LPMHDSK_Pos) +#define USB_DEVICE_CTRLB_LPMHDSK_STALL (USB_DEVICE_CTRLB_LPMHDSK_STALL_Val << USB_DEVICE_CTRLB_LPMHDSK_Pos) +#define USB_DEVICE_CTRLB_MASK 0x0FFFu /**< \brief (USB_DEVICE_CTRLB) MASK Register */ + +/* -------- USB_HOST_CTRLB : (USB Offset: 0x008) (R/W 16) HOST HOST Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t :1; /*!< bit: 0 Reserved */ + uint16_t RESUME:1; /*!< bit: 1 Send USB Resume */ + uint16_t SPDCONF:2; /*!< bit: 2.. 3 Speed Configuration for Host */ + uint16_t :1; /*!< bit: 4 Reserved */ + uint16_t TSTJ:1; /*!< bit: 5 Test mode J */ + uint16_t TSTK:1; /*!< bit: 6 Test mode K */ + uint16_t :1; /*!< bit: 7 Reserved */ + uint16_t SOFE:1; /*!< bit: 8 Start of Frame Generation Enable */ + uint16_t BUSRESET:1; /*!< bit: 9 Send USB Reset */ + uint16_t VBUSOK:1; /*!< bit: 10 VBUS is OK */ + uint16_t L1RESUME:1; /*!< bit: 11 Send L1 Resume */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_HOST_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_CTRLB_OFFSET 0x008 /**< \brief (USB_HOST_CTRLB offset) HOST Control B */ +#define USB_HOST_CTRLB_RESETVALUE 0x0000 /**< \brief (USB_HOST_CTRLB reset_value) HOST Control B */ + +#define USB_HOST_CTRLB_RESUME_Pos 1 /**< \brief (USB_HOST_CTRLB) Send USB Resume */ +#define USB_HOST_CTRLB_RESUME (0x1u << USB_HOST_CTRLB_RESUME_Pos) +#define USB_HOST_CTRLB_SPDCONF_Pos 2 /**< \brief (USB_HOST_CTRLB) Speed Configuration for Host */ +#define USB_HOST_CTRLB_SPDCONF_Msk (0x3u << USB_HOST_CTRLB_SPDCONF_Pos) +#define USB_HOST_CTRLB_SPDCONF(value) ((USB_HOST_CTRLB_SPDCONF_Msk & ((value) << USB_HOST_CTRLB_SPDCONF_Pos))) +#define USB_HOST_CTRLB_SPDCONF_0_Val 0x0u /**< \brief (USB_HOST_CTRLB) Normal mode:the host starts in full-speed mode and performs a high-speed reset to switch to the high speed mode if the downstream peripheralis high-speed capable. */ +#define USB_HOST_CTRLB_SPDCONF_1_Val 0x1u /**< \brief (USB_HOST_CTRLB) reserved */ +#define USB_HOST_CTRLB_SPDCONF_2_Val 0x2u /**< \brief (USB_HOST_CTRLB) reserved */ +#define USB_HOST_CTRLB_SPDCONF_3_Val 0x3u /**< \brief (USB_HOST_CTRLB) Full-speed:the host remains in full-speed mode whatever is the peripheral speed capability. Releveant in UTMI mode only. */ +#define USB_HOST_CTRLB_SPDCONF_0 (USB_HOST_CTRLB_SPDCONF_0_Val << USB_HOST_CTRLB_SPDCONF_Pos) +#define USB_HOST_CTRLB_SPDCONF_1 (USB_HOST_CTRLB_SPDCONF_1_Val << USB_HOST_CTRLB_SPDCONF_Pos) +#define USB_HOST_CTRLB_SPDCONF_2 (USB_HOST_CTRLB_SPDCONF_2_Val << USB_HOST_CTRLB_SPDCONF_Pos) +#define USB_HOST_CTRLB_SPDCONF_3 (USB_HOST_CTRLB_SPDCONF_3_Val << USB_HOST_CTRLB_SPDCONF_Pos) +#define USB_HOST_CTRLB_TSTJ_Pos 5 /**< \brief (USB_HOST_CTRLB) Test mode J */ +#define USB_HOST_CTRLB_TSTJ (0x1u << USB_HOST_CTRLB_TSTJ_Pos) +#define USB_HOST_CTRLB_TSTK_Pos 6 /**< \brief (USB_HOST_CTRLB) Test mode K */ +#define USB_HOST_CTRLB_TSTK (0x1u << USB_HOST_CTRLB_TSTK_Pos) +#define USB_HOST_CTRLB_SOFE_Pos 8 /**< \brief (USB_HOST_CTRLB) Start of Frame Generation Enable */ +#define USB_HOST_CTRLB_SOFE (0x1u << USB_HOST_CTRLB_SOFE_Pos) +#define USB_HOST_CTRLB_BUSRESET_Pos 9 /**< \brief (USB_HOST_CTRLB) Send USB Reset */ +#define USB_HOST_CTRLB_BUSRESET (0x1u << USB_HOST_CTRLB_BUSRESET_Pos) +#define USB_HOST_CTRLB_VBUSOK_Pos 10 /**< \brief (USB_HOST_CTRLB) VBUS is OK */ +#define USB_HOST_CTRLB_VBUSOK (0x1u << USB_HOST_CTRLB_VBUSOK_Pos) +#define USB_HOST_CTRLB_L1RESUME_Pos 11 /**< \brief (USB_HOST_CTRLB) Send L1 Resume */ +#define USB_HOST_CTRLB_L1RESUME (0x1u << USB_HOST_CTRLB_L1RESUME_Pos) +#define USB_HOST_CTRLB_MASK 0x0F6Eu /**< \brief (USB_HOST_CTRLB) MASK Register */ + +/* -------- USB_DEVICE_DADD : (USB Offset: 0x00A) (R/W 8) DEVICE DEVICE Device Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DADD:7; /*!< bit: 0.. 6 Device Address */ + uint8_t ADDEN:1; /*!< bit: 7 Device Address Enable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_DADD_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_DADD_OFFSET 0x00A /**< \brief (USB_DEVICE_DADD offset) DEVICE Device Address */ +#define USB_DEVICE_DADD_RESETVALUE 0x00 /**< \brief (USB_DEVICE_DADD reset_value) DEVICE Device Address */ + +#define USB_DEVICE_DADD_DADD_Pos 0 /**< \brief (USB_DEVICE_DADD) Device Address */ +#define USB_DEVICE_DADD_DADD_Msk (0x7Fu << USB_DEVICE_DADD_DADD_Pos) +#define USB_DEVICE_DADD_DADD(value) ((USB_DEVICE_DADD_DADD_Msk & ((value) << USB_DEVICE_DADD_DADD_Pos))) +#define USB_DEVICE_DADD_ADDEN_Pos 7 /**< \brief (USB_DEVICE_DADD) Device Address Enable */ +#define USB_DEVICE_DADD_ADDEN (0x1u << USB_DEVICE_DADD_ADDEN_Pos) +#define USB_DEVICE_DADD_MASK 0xFFu /**< \brief (USB_DEVICE_DADD) MASK Register */ + +/* -------- USB_HOST_HSOFC : (USB Offset: 0x00A) (R/W 8) HOST HOST Host Start Of Frame Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t FLENC:4; /*!< bit: 0.. 3 Frame Length Control */ + uint8_t :3; /*!< bit: 4.. 6 Reserved */ + uint8_t FLENCE:1; /*!< bit: 7 Frame Length Control Enable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_HSOFC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_HSOFC_OFFSET 0x00A /**< \brief (USB_HOST_HSOFC offset) HOST Host Start Of Frame Control */ +#define USB_HOST_HSOFC_RESETVALUE 0x00 /**< \brief (USB_HOST_HSOFC reset_value) HOST Host Start Of Frame Control */ + +#define USB_HOST_HSOFC_FLENC_Pos 0 /**< \brief (USB_HOST_HSOFC) Frame Length Control */ +#define USB_HOST_HSOFC_FLENC_Msk (0xFu << USB_HOST_HSOFC_FLENC_Pos) +#define USB_HOST_HSOFC_FLENC(value) ((USB_HOST_HSOFC_FLENC_Msk & ((value) << USB_HOST_HSOFC_FLENC_Pos))) +#define USB_HOST_HSOFC_FLENCE_Pos 7 /**< \brief (USB_HOST_HSOFC) Frame Length Control Enable */ +#define USB_HOST_HSOFC_FLENCE (0x1u << USB_HOST_HSOFC_FLENCE_Pos) +#define USB_HOST_HSOFC_MASK 0x8Fu /**< \brief (USB_HOST_HSOFC) MASK Register */ + +/* -------- USB_DEVICE_STATUS : (USB Offset: 0x00C) (R/ 8) DEVICE DEVICE Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :2; /*!< bit: 0.. 1 Reserved */ + uint8_t SPEED:2; /*!< bit: 2.. 3 Speed Status */ + uint8_t :2; /*!< bit: 4.. 5 Reserved */ + uint8_t LINESTATE:2; /*!< bit: 6.. 7 USB Line State Status */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_STATUS_OFFSET 0x00C /**< \brief (USB_DEVICE_STATUS offset) DEVICE Status */ +#define USB_DEVICE_STATUS_RESETVALUE 0x40 /**< \brief (USB_DEVICE_STATUS reset_value) DEVICE Status */ + +#define USB_DEVICE_STATUS_SPEED_Pos 2 /**< \brief (USB_DEVICE_STATUS) Speed Status */ +#define USB_DEVICE_STATUS_SPEED_Msk (0x3u << USB_DEVICE_STATUS_SPEED_Pos) +#define USB_DEVICE_STATUS_SPEED(value) ((USB_DEVICE_STATUS_SPEED_Msk & ((value) << USB_DEVICE_STATUS_SPEED_Pos))) +#define USB_DEVICE_STATUS_SPEED_0_Val 0x0u /**< \brief (USB_DEVICE_STATUS) Full-speed mode */ +#define USB_DEVICE_STATUS_SPEED_1_Val 0x1u /**< \brief (USB_DEVICE_STATUS) High-speed mode */ +#define USB_DEVICE_STATUS_SPEED_2_Val 0x2u /**< \brief (USB_DEVICE_STATUS) Low-speed mode */ +#define USB_DEVICE_STATUS_SPEED_0 (USB_DEVICE_STATUS_SPEED_0_Val << USB_DEVICE_STATUS_SPEED_Pos) +#define USB_DEVICE_STATUS_SPEED_1 (USB_DEVICE_STATUS_SPEED_1_Val << USB_DEVICE_STATUS_SPEED_Pos) +#define USB_DEVICE_STATUS_SPEED_2 (USB_DEVICE_STATUS_SPEED_2_Val << USB_DEVICE_STATUS_SPEED_Pos) +#define USB_DEVICE_STATUS_LINESTATE_Pos 6 /**< \brief (USB_DEVICE_STATUS) USB Line State Status */ +#define USB_DEVICE_STATUS_LINESTATE_Msk (0x3u << USB_DEVICE_STATUS_LINESTATE_Pos) +#define USB_DEVICE_STATUS_LINESTATE(value) ((USB_DEVICE_STATUS_LINESTATE_Msk & ((value) << USB_DEVICE_STATUS_LINESTATE_Pos))) +#define USB_DEVICE_STATUS_LINESTATE_0_Val 0x0u /**< \brief (USB_DEVICE_STATUS) SE0/RESET */ +#define USB_DEVICE_STATUS_LINESTATE_1_Val 0x1u /**< \brief (USB_DEVICE_STATUS) FS-J or LS-K State */ +#define USB_DEVICE_STATUS_LINESTATE_2_Val 0x2u /**< \brief (USB_DEVICE_STATUS) FS-K or LS-J State */ +#define USB_DEVICE_STATUS_LINESTATE_0 (USB_DEVICE_STATUS_LINESTATE_0_Val << USB_DEVICE_STATUS_LINESTATE_Pos) +#define USB_DEVICE_STATUS_LINESTATE_1 (USB_DEVICE_STATUS_LINESTATE_1_Val << USB_DEVICE_STATUS_LINESTATE_Pos) +#define USB_DEVICE_STATUS_LINESTATE_2 (USB_DEVICE_STATUS_LINESTATE_2_Val << USB_DEVICE_STATUS_LINESTATE_Pos) +#define USB_DEVICE_STATUS_MASK 0xCCu /**< \brief (USB_DEVICE_STATUS) MASK Register */ + +/* -------- USB_HOST_STATUS : (USB Offset: 0x00C) (R/W 8) HOST HOST Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :2; /*!< bit: 0.. 1 Reserved */ + uint8_t SPEED:2; /*!< bit: 2.. 3 Speed Status */ + uint8_t :2; /*!< bit: 4.. 5 Reserved */ + uint8_t LINESTATE:2; /*!< bit: 6.. 7 USB Line State Status */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_STATUS_OFFSET 0x00C /**< \brief (USB_HOST_STATUS offset) HOST Status */ +#define USB_HOST_STATUS_RESETVALUE 0x00 /**< \brief (USB_HOST_STATUS reset_value) HOST Status */ + +#define USB_HOST_STATUS_SPEED_Pos 2 /**< \brief (USB_HOST_STATUS) Speed Status */ +#define USB_HOST_STATUS_SPEED_Msk (0x3u << USB_HOST_STATUS_SPEED_Pos) +#define USB_HOST_STATUS_SPEED(value) ((USB_HOST_STATUS_SPEED_Msk & ((value) << USB_HOST_STATUS_SPEED_Pos))) +#define USB_HOST_STATUS_LINESTATE_Pos 6 /**< \brief (USB_HOST_STATUS) USB Line State Status */ +#define USB_HOST_STATUS_LINESTATE_Msk (0x3u << USB_HOST_STATUS_LINESTATE_Pos) +#define USB_HOST_STATUS_LINESTATE(value) ((USB_HOST_STATUS_LINESTATE_Msk & ((value) << USB_HOST_STATUS_LINESTATE_Pos))) +#define USB_HOST_STATUS_MASK 0xCCu /**< \brief (USB_HOST_STATUS) MASK Register */ + +/* -------- USB_FSMSTATUS : (USB Offset: 0x00D) (R/ 8) Finite State Machine Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t FSMSTATE:6; /*!< bit: 0.. 5 Fine State Machine Status */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_FSMSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_FSMSTATUS_OFFSET 0x00D /**< \brief (USB_FSMSTATUS offset) Finite State Machine Status */ +#define USB_FSMSTATUS_RESETVALUE 0x01 /**< \brief (USB_FSMSTATUS reset_value) Finite State Machine Status */ + +#define USB_FSMSTATUS_FSMSTATE_Pos 0 /**< \brief (USB_FSMSTATUS) Fine State Machine Status */ +#define USB_FSMSTATUS_FSMSTATE_Msk (0x3Fu << USB_FSMSTATUS_FSMSTATE_Pos) +#define USB_FSMSTATUS_FSMSTATE(value) ((USB_FSMSTATUS_FSMSTATE_Msk & ((value) << USB_FSMSTATUS_FSMSTATE_Pos))) +#define USB_FSMSTATUS_FSMSTATE_1_Val 0x1u /**< \brief (USB_FSMSTATUS) OFF (L3). It corresponds to the powered-off, disconnected, and disabled state */ +#define USB_FSMSTATUS_FSMSTATE_2_Val 0x2u /**< \brief (USB_FSMSTATUS) ON (L0). It corresponds to the Idle and Active states */ +#define USB_FSMSTATUS_FSMSTATE_4_Val 0x4u /**< \brief (USB_FSMSTATUS) SUSPEND (L2) */ +#define USB_FSMSTATUS_FSMSTATE_8_Val 0x8u /**< \brief (USB_FSMSTATUS) SLEEP (L1) */ +#define USB_FSMSTATUS_FSMSTATE_16_Val 0x10u /**< \brief (USB_FSMSTATUS) DNRESUME. Down Stream Resume. */ +#define USB_FSMSTATUS_FSMSTATE_32_Val 0x20u /**< \brief (USB_FSMSTATUS) UPRESUME. Up Stream Resume. */ +#define USB_FSMSTATUS_FSMSTATE_64_Val 0x40u /**< \brief (USB_FSMSTATUS) RESET. USB lines Reset. */ +#define USB_FSMSTATUS_FSMSTATE_1 (USB_FSMSTATUS_FSMSTATE_1_Val << USB_FSMSTATUS_FSMSTATE_Pos) +#define USB_FSMSTATUS_FSMSTATE_2 (USB_FSMSTATUS_FSMSTATE_2_Val << USB_FSMSTATUS_FSMSTATE_Pos) +#define USB_FSMSTATUS_FSMSTATE_4 (USB_FSMSTATUS_FSMSTATE_4_Val << USB_FSMSTATUS_FSMSTATE_Pos) +#define USB_FSMSTATUS_FSMSTATE_8 (USB_FSMSTATUS_FSMSTATE_8_Val << USB_FSMSTATUS_FSMSTATE_Pos) +#define USB_FSMSTATUS_FSMSTATE_16 (USB_FSMSTATUS_FSMSTATE_16_Val << USB_FSMSTATUS_FSMSTATE_Pos) +#define USB_FSMSTATUS_FSMSTATE_32 (USB_FSMSTATUS_FSMSTATE_32_Val << USB_FSMSTATUS_FSMSTATE_Pos) +#define USB_FSMSTATUS_FSMSTATE_64 (USB_FSMSTATUS_FSMSTATE_64_Val << USB_FSMSTATUS_FSMSTATE_Pos) +#define USB_FSMSTATUS_MASK 0x3Fu /**< \brief (USB_FSMSTATUS) MASK Register */ + +/* -------- USB_DEVICE_FNUM : (USB Offset: 0x010) (R/ 16) DEVICE DEVICE Device Frame Number -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t MFNUM:3; /*!< bit: 0.. 2 Micro Frame Number */ + uint16_t FNUM:11; /*!< bit: 3..13 Frame Number */ + uint16_t :1; /*!< bit: 14 Reserved */ + uint16_t FNCERR:1; /*!< bit: 15 Frame Number CRC Error */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_DEVICE_FNUM_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_FNUM_OFFSET 0x010 /**< \brief (USB_DEVICE_FNUM offset) DEVICE Device Frame Number */ +#define USB_DEVICE_FNUM_RESETVALUE 0x0000 /**< \brief (USB_DEVICE_FNUM reset_value) DEVICE Device Frame Number */ + +#define USB_DEVICE_FNUM_MFNUM_Pos 0 /**< \brief (USB_DEVICE_FNUM) Micro Frame Number */ +#define USB_DEVICE_FNUM_MFNUM_Msk (0x7u << USB_DEVICE_FNUM_MFNUM_Pos) +#define USB_DEVICE_FNUM_MFNUM(value) ((USB_DEVICE_FNUM_MFNUM_Msk & ((value) << USB_DEVICE_FNUM_MFNUM_Pos))) +#define USB_DEVICE_FNUM_FNUM_Pos 3 /**< \brief (USB_DEVICE_FNUM) Frame Number */ +#define USB_DEVICE_FNUM_FNUM_Msk (0x7FFu << USB_DEVICE_FNUM_FNUM_Pos) +#define USB_DEVICE_FNUM_FNUM(value) ((USB_DEVICE_FNUM_FNUM_Msk & ((value) << USB_DEVICE_FNUM_FNUM_Pos))) +#define USB_DEVICE_FNUM_FNCERR_Pos 15 /**< \brief (USB_DEVICE_FNUM) Frame Number CRC Error */ +#define USB_DEVICE_FNUM_FNCERR (0x1u << USB_DEVICE_FNUM_FNCERR_Pos) +#define USB_DEVICE_FNUM_MASK 0xBFFFu /**< \brief (USB_DEVICE_FNUM) MASK Register */ + +/* -------- USB_HOST_FNUM : (USB Offset: 0x010) (R/W 16) HOST HOST Host Frame Number -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t MFNUM:3; /*!< bit: 0.. 2 Micro Frame Number */ + uint16_t FNUM:11; /*!< bit: 3..13 Frame Number */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_HOST_FNUM_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_FNUM_OFFSET 0x010 /**< \brief (USB_HOST_FNUM offset) HOST Host Frame Number */ +#define USB_HOST_FNUM_RESETVALUE 0x0000 /**< \brief (USB_HOST_FNUM reset_value) HOST Host Frame Number */ + +#define USB_HOST_FNUM_MFNUM_Pos 0 /**< \brief (USB_HOST_FNUM) Micro Frame Number */ +#define USB_HOST_FNUM_MFNUM_Msk (0x7u << USB_HOST_FNUM_MFNUM_Pos) +#define USB_HOST_FNUM_MFNUM(value) ((USB_HOST_FNUM_MFNUM_Msk & ((value) << USB_HOST_FNUM_MFNUM_Pos))) +#define USB_HOST_FNUM_FNUM_Pos 3 /**< \brief (USB_HOST_FNUM) Frame Number */ +#define USB_HOST_FNUM_FNUM_Msk (0x7FFu << USB_HOST_FNUM_FNUM_Pos) +#define USB_HOST_FNUM_FNUM(value) ((USB_HOST_FNUM_FNUM_Msk & ((value) << USB_HOST_FNUM_FNUM_Pos))) +#define USB_HOST_FNUM_MASK 0x3FFFu /**< \brief (USB_HOST_FNUM) MASK Register */ + +/* -------- USB_HOST_FLENHIGH : (USB Offset: 0x012) (R/ 8) HOST HOST Host Frame Length -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t FLENHIGH:8; /*!< bit: 0.. 7 Frame Length */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_FLENHIGH_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_FLENHIGH_OFFSET 0x012 /**< \brief (USB_HOST_FLENHIGH offset) HOST Host Frame Length */ +#define USB_HOST_FLENHIGH_RESETVALUE 0x00 /**< \brief (USB_HOST_FLENHIGH reset_value) HOST Host Frame Length */ + +#define USB_HOST_FLENHIGH_FLENHIGH_Pos 0 /**< \brief (USB_HOST_FLENHIGH) Frame Length */ +#define USB_HOST_FLENHIGH_FLENHIGH_Msk (0xFFu << USB_HOST_FLENHIGH_FLENHIGH_Pos) +#define USB_HOST_FLENHIGH_FLENHIGH(value) ((USB_HOST_FLENHIGH_FLENHIGH_Msk & ((value) << USB_HOST_FLENHIGH_FLENHIGH_Pos))) +#define USB_HOST_FLENHIGH_MASK 0xFFu /**< \brief (USB_HOST_FLENHIGH) MASK Register */ + +/* -------- USB_DEVICE_INTENCLR : (USB Offset: 0x014) (R/W 16) DEVICE DEVICE Device Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SUSPEND:1; /*!< bit: 0 Suspend Interrupt Enable */ + uint16_t MSOF:1; /*!< bit: 1 Micro Start of Frame Interrupt Enable in High Speed Mode */ + uint16_t SOF:1; /*!< bit: 2 Start Of Frame Interrupt Enable */ + uint16_t EORST:1; /*!< bit: 3 End of Reset Interrupt Enable */ + uint16_t WAKEUP:1; /*!< bit: 4 Wake Up Interrupt Enable */ + uint16_t EORSM:1; /*!< bit: 5 End Of Resume Interrupt Enable */ + uint16_t UPRSM:1; /*!< bit: 6 Upstream Resume Interrupt Enable */ + uint16_t RAMACER:1; /*!< bit: 7 Ram Access Interrupt Enable */ + uint16_t LPMNYET:1; /*!< bit: 8 Link Power Management Not Yet Interrupt Enable */ + uint16_t LPMSUSP:1; /*!< bit: 9 Link Power Management Suspend Interrupt Enable */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_DEVICE_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_INTENCLR_OFFSET 0x014 /**< \brief (USB_DEVICE_INTENCLR offset) DEVICE Device Interrupt Enable Clear */ +#define USB_DEVICE_INTENCLR_RESETVALUE 0x0000 /**< \brief (USB_DEVICE_INTENCLR reset_value) DEVICE Device Interrupt Enable Clear */ + +#define USB_DEVICE_INTENCLR_SUSPEND_Pos 0 /**< \brief (USB_DEVICE_INTENCLR) Suspend Interrupt Enable */ +#define USB_DEVICE_INTENCLR_SUSPEND (0x1u << USB_DEVICE_INTENCLR_SUSPEND_Pos) +#define USB_DEVICE_INTENCLR_MSOF_Pos 1 /**< \brief (USB_DEVICE_INTENCLR) Micro Start of Frame Interrupt Enable in High Speed Mode */ +#define USB_DEVICE_INTENCLR_MSOF (0x1u << USB_DEVICE_INTENCLR_MSOF_Pos) +#define USB_DEVICE_INTENCLR_SOF_Pos 2 /**< \brief (USB_DEVICE_INTENCLR) Start Of Frame Interrupt Enable */ +#define USB_DEVICE_INTENCLR_SOF (0x1u << USB_DEVICE_INTENCLR_SOF_Pos) +#define USB_DEVICE_INTENCLR_EORST_Pos 3 /**< \brief (USB_DEVICE_INTENCLR) End of Reset Interrupt Enable */ +#define USB_DEVICE_INTENCLR_EORST (0x1u << USB_DEVICE_INTENCLR_EORST_Pos) +#define USB_DEVICE_INTENCLR_WAKEUP_Pos 4 /**< \brief (USB_DEVICE_INTENCLR) Wake Up Interrupt Enable */ +#define USB_DEVICE_INTENCLR_WAKEUP (0x1u << USB_DEVICE_INTENCLR_WAKEUP_Pos) +#define USB_DEVICE_INTENCLR_EORSM_Pos 5 /**< \brief (USB_DEVICE_INTENCLR) End Of Resume Interrupt Enable */ +#define USB_DEVICE_INTENCLR_EORSM (0x1u << USB_DEVICE_INTENCLR_EORSM_Pos) +#define USB_DEVICE_INTENCLR_UPRSM_Pos 6 /**< \brief (USB_DEVICE_INTENCLR) Upstream Resume Interrupt Enable */ +#define USB_DEVICE_INTENCLR_UPRSM (0x1u << USB_DEVICE_INTENCLR_UPRSM_Pos) +#define USB_DEVICE_INTENCLR_RAMACER_Pos 7 /**< \brief (USB_DEVICE_INTENCLR) Ram Access Interrupt Enable */ +#define USB_DEVICE_INTENCLR_RAMACER (0x1u << USB_DEVICE_INTENCLR_RAMACER_Pos) +#define USB_DEVICE_INTENCLR_LPMNYET_Pos 8 /**< \brief (USB_DEVICE_INTENCLR) Link Power Management Not Yet Interrupt Enable */ +#define USB_DEVICE_INTENCLR_LPMNYET (0x1u << USB_DEVICE_INTENCLR_LPMNYET_Pos) +#define USB_DEVICE_INTENCLR_LPMSUSP_Pos 9 /**< \brief (USB_DEVICE_INTENCLR) Link Power Management Suspend Interrupt Enable */ +#define USB_DEVICE_INTENCLR_LPMSUSP (0x1u << USB_DEVICE_INTENCLR_LPMSUSP_Pos) +#define USB_DEVICE_INTENCLR_MASK 0x03FFu /**< \brief (USB_DEVICE_INTENCLR) MASK Register */ + +/* -------- USB_HOST_INTENCLR : (USB Offset: 0x014) (R/W 16) HOST HOST Host Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t :2; /*!< bit: 0.. 1 Reserved */ + uint16_t HSOF:1; /*!< bit: 2 Host Start Of Frame Interrupt Disable */ + uint16_t RST:1; /*!< bit: 3 BUS Reset Interrupt Disable */ + uint16_t WAKEUP:1; /*!< bit: 4 Wake Up Interrupt Disable */ + uint16_t DNRSM:1; /*!< bit: 5 DownStream to Device Interrupt Disable */ + uint16_t UPRSM:1; /*!< bit: 6 Upstream Resume from Device Interrupt Disable */ + uint16_t RAMACER:1; /*!< bit: 7 Ram Access Interrupt Disable */ + uint16_t DCONN:1; /*!< bit: 8 Device Connection Interrupt Disable */ + uint16_t DDISC:1; /*!< bit: 9 Device Disconnection Interrupt Disable */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_HOST_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_INTENCLR_OFFSET 0x014 /**< \brief (USB_HOST_INTENCLR offset) HOST Host Interrupt Enable Clear */ +#define USB_HOST_INTENCLR_RESETVALUE 0x0000 /**< \brief (USB_HOST_INTENCLR reset_value) HOST Host Interrupt Enable Clear */ + +#define USB_HOST_INTENCLR_HSOF_Pos 2 /**< \brief (USB_HOST_INTENCLR) Host Start Of Frame Interrupt Disable */ +#define USB_HOST_INTENCLR_HSOF (0x1u << USB_HOST_INTENCLR_HSOF_Pos) +#define USB_HOST_INTENCLR_RST_Pos 3 /**< \brief (USB_HOST_INTENCLR) BUS Reset Interrupt Disable */ +#define USB_HOST_INTENCLR_RST (0x1u << USB_HOST_INTENCLR_RST_Pos) +#define USB_HOST_INTENCLR_WAKEUP_Pos 4 /**< \brief (USB_HOST_INTENCLR) Wake Up Interrupt Disable */ +#define USB_HOST_INTENCLR_WAKEUP (0x1u << USB_HOST_INTENCLR_WAKEUP_Pos) +#define USB_HOST_INTENCLR_DNRSM_Pos 5 /**< \brief (USB_HOST_INTENCLR) DownStream to Device Interrupt Disable */ +#define USB_HOST_INTENCLR_DNRSM (0x1u << USB_HOST_INTENCLR_DNRSM_Pos) +#define USB_HOST_INTENCLR_UPRSM_Pos 6 /**< \brief (USB_HOST_INTENCLR) Upstream Resume from Device Interrupt Disable */ +#define USB_HOST_INTENCLR_UPRSM (0x1u << USB_HOST_INTENCLR_UPRSM_Pos) +#define USB_HOST_INTENCLR_RAMACER_Pos 7 /**< \brief (USB_HOST_INTENCLR) Ram Access Interrupt Disable */ +#define USB_HOST_INTENCLR_RAMACER (0x1u << USB_HOST_INTENCLR_RAMACER_Pos) +#define USB_HOST_INTENCLR_DCONN_Pos 8 /**< \brief (USB_HOST_INTENCLR) Device Connection Interrupt Disable */ +#define USB_HOST_INTENCLR_DCONN (0x1u << USB_HOST_INTENCLR_DCONN_Pos) +#define USB_HOST_INTENCLR_DDISC_Pos 9 /**< \brief (USB_HOST_INTENCLR) Device Disconnection Interrupt Disable */ +#define USB_HOST_INTENCLR_DDISC (0x1u << USB_HOST_INTENCLR_DDISC_Pos) +#define USB_HOST_INTENCLR_MASK 0x03FCu /**< \brief (USB_HOST_INTENCLR) MASK Register */ + +/* -------- USB_DEVICE_INTENSET : (USB Offset: 0x018) (R/W 16) DEVICE DEVICE Device Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SUSPEND:1; /*!< bit: 0 Suspend Interrupt Enable */ + uint16_t MSOF:1; /*!< bit: 1 Micro Start of Frame Interrupt Enable in High Speed Mode */ + uint16_t SOF:1; /*!< bit: 2 Start Of Frame Interrupt Enable */ + uint16_t EORST:1; /*!< bit: 3 End of Reset Interrupt Enable */ + uint16_t WAKEUP:1; /*!< bit: 4 Wake Up Interrupt Enable */ + uint16_t EORSM:1; /*!< bit: 5 End Of Resume Interrupt Enable */ + uint16_t UPRSM:1; /*!< bit: 6 Upstream Resume Interrupt Enable */ + uint16_t RAMACER:1; /*!< bit: 7 Ram Access Interrupt Enable */ + uint16_t LPMNYET:1; /*!< bit: 8 Link Power Management Not Yet Interrupt Enable */ + uint16_t LPMSUSP:1; /*!< bit: 9 Link Power Management Suspend Interrupt Enable */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_DEVICE_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_INTENSET_OFFSET 0x018 /**< \brief (USB_DEVICE_INTENSET offset) DEVICE Device Interrupt Enable Set */ +#define USB_DEVICE_INTENSET_RESETVALUE 0x0000 /**< \brief (USB_DEVICE_INTENSET reset_value) DEVICE Device Interrupt Enable Set */ + +#define USB_DEVICE_INTENSET_SUSPEND_Pos 0 /**< \brief (USB_DEVICE_INTENSET) Suspend Interrupt Enable */ +#define USB_DEVICE_INTENSET_SUSPEND (0x1u << USB_DEVICE_INTENSET_SUSPEND_Pos) +#define USB_DEVICE_INTENSET_MSOF_Pos 1 /**< \brief (USB_DEVICE_INTENSET) Micro Start of Frame Interrupt Enable in High Speed Mode */ +#define USB_DEVICE_INTENSET_MSOF (0x1u << USB_DEVICE_INTENSET_MSOF_Pos) +#define USB_DEVICE_INTENSET_SOF_Pos 2 /**< \brief (USB_DEVICE_INTENSET) Start Of Frame Interrupt Enable */ +#define USB_DEVICE_INTENSET_SOF (0x1u << USB_DEVICE_INTENSET_SOF_Pos) +#define USB_DEVICE_INTENSET_EORST_Pos 3 /**< \brief (USB_DEVICE_INTENSET) End of Reset Interrupt Enable */ +#define USB_DEVICE_INTENSET_EORST (0x1u << USB_DEVICE_INTENSET_EORST_Pos) +#define USB_DEVICE_INTENSET_WAKEUP_Pos 4 /**< \brief (USB_DEVICE_INTENSET) Wake Up Interrupt Enable */ +#define USB_DEVICE_INTENSET_WAKEUP (0x1u << USB_DEVICE_INTENSET_WAKEUP_Pos) +#define USB_DEVICE_INTENSET_EORSM_Pos 5 /**< \brief (USB_DEVICE_INTENSET) End Of Resume Interrupt Enable */ +#define USB_DEVICE_INTENSET_EORSM (0x1u << USB_DEVICE_INTENSET_EORSM_Pos) +#define USB_DEVICE_INTENSET_UPRSM_Pos 6 /**< \brief (USB_DEVICE_INTENSET) Upstream Resume Interrupt Enable */ +#define USB_DEVICE_INTENSET_UPRSM (0x1u << USB_DEVICE_INTENSET_UPRSM_Pos) +#define USB_DEVICE_INTENSET_RAMACER_Pos 7 /**< \brief (USB_DEVICE_INTENSET) Ram Access Interrupt Enable */ +#define USB_DEVICE_INTENSET_RAMACER (0x1u << USB_DEVICE_INTENSET_RAMACER_Pos) +#define USB_DEVICE_INTENSET_LPMNYET_Pos 8 /**< \brief (USB_DEVICE_INTENSET) Link Power Management Not Yet Interrupt Enable */ +#define USB_DEVICE_INTENSET_LPMNYET (0x1u << USB_DEVICE_INTENSET_LPMNYET_Pos) +#define USB_DEVICE_INTENSET_LPMSUSP_Pos 9 /**< \brief (USB_DEVICE_INTENSET) Link Power Management Suspend Interrupt Enable */ +#define USB_DEVICE_INTENSET_LPMSUSP (0x1u << USB_DEVICE_INTENSET_LPMSUSP_Pos) +#define USB_DEVICE_INTENSET_MASK 0x03FFu /**< \brief (USB_DEVICE_INTENSET) MASK Register */ + +/* -------- USB_HOST_INTENSET : (USB Offset: 0x018) (R/W 16) HOST HOST Host Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t :2; /*!< bit: 0.. 1 Reserved */ + uint16_t HSOF:1; /*!< bit: 2 Host Start Of Frame Interrupt Enable */ + uint16_t RST:1; /*!< bit: 3 Bus Reset Interrupt Enable */ + uint16_t WAKEUP:1; /*!< bit: 4 Wake Up Interrupt Enable */ + uint16_t DNRSM:1; /*!< bit: 5 DownStream to the Device Interrupt Enable */ + uint16_t UPRSM:1; /*!< bit: 6 Upstream Resume fromthe device Interrupt Enable */ + uint16_t RAMACER:1; /*!< bit: 7 Ram Access Interrupt Enable */ + uint16_t DCONN:1; /*!< bit: 8 Link Power Management Interrupt Enable */ + uint16_t DDISC:1; /*!< bit: 9 Device Disconnection Interrupt Enable */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_HOST_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_INTENSET_OFFSET 0x018 /**< \brief (USB_HOST_INTENSET offset) HOST Host Interrupt Enable Set */ +#define USB_HOST_INTENSET_RESETVALUE 0x0000 /**< \brief (USB_HOST_INTENSET reset_value) HOST Host Interrupt Enable Set */ + +#define USB_HOST_INTENSET_HSOF_Pos 2 /**< \brief (USB_HOST_INTENSET) Host Start Of Frame Interrupt Enable */ +#define USB_HOST_INTENSET_HSOF (0x1u << USB_HOST_INTENSET_HSOF_Pos) +#define USB_HOST_INTENSET_RST_Pos 3 /**< \brief (USB_HOST_INTENSET) Bus Reset Interrupt Enable */ +#define USB_HOST_INTENSET_RST (0x1u << USB_HOST_INTENSET_RST_Pos) +#define USB_HOST_INTENSET_WAKEUP_Pos 4 /**< \brief (USB_HOST_INTENSET) Wake Up Interrupt Enable */ +#define USB_HOST_INTENSET_WAKEUP (0x1u << USB_HOST_INTENSET_WAKEUP_Pos) +#define USB_HOST_INTENSET_DNRSM_Pos 5 /**< \brief (USB_HOST_INTENSET) DownStream to the Device Interrupt Enable */ +#define USB_HOST_INTENSET_DNRSM (0x1u << USB_HOST_INTENSET_DNRSM_Pos) +#define USB_HOST_INTENSET_UPRSM_Pos 6 /**< \brief (USB_HOST_INTENSET) Upstream Resume fromthe device Interrupt Enable */ +#define USB_HOST_INTENSET_UPRSM (0x1u << USB_HOST_INTENSET_UPRSM_Pos) +#define USB_HOST_INTENSET_RAMACER_Pos 7 /**< \brief (USB_HOST_INTENSET) Ram Access Interrupt Enable */ +#define USB_HOST_INTENSET_RAMACER (0x1u << USB_HOST_INTENSET_RAMACER_Pos) +#define USB_HOST_INTENSET_DCONN_Pos 8 /**< \brief (USB_HOST_INTENSET) Link Power Management Interrupt Enable */ +#define USB_HOST_INTENSET_DCONN (0x1u << USB_HOST_INTENSET_DCONN_Pos) +#define USB_HOST_INTENSET_DDISC_Pos 9 /**< \brief (USB_HOST_INTENSET) Device Disconnection Interrupt Enable */ +#define USB_HOST_INTENSET_DDISC (0x1u << USB_HOST_INTENSET_DDISC_Pos) +#define USB_HOST_INTENSET_MASK 0x03FCu /**< \brief (USB_HOST_INTENSET) MASK Register */ + +/* -------- USB_DEVICE_INTFLAG : (USB Offset: 0x01C) (R/W 16) DEVICE DEVICE Device Interrupt Flag -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SUSPEND:1; /*!< bit: 0 Suspend */ + uint16_t MSOF:1; /*!< bit: 1 Micro Start of Frame in High Speed Mode */ + uint16_t SOF:1; /*!< bit: 2 Start Of Frame */ + uint16_t EORST:1; /*!< bit: 3 End of Reset */ + uint16_t WAKEUP:1; /*!< bit: 4 Wake Up */ + uint16_t EORSM:1; /*!< bit: 5 End Of Resume */ + uint16_t UPRSM:1; /*!< bit: 6 Upstream Resume */ + uint16_t RAMACER:1; /*!< bit: 7 Ram Access */ + uint16_t LPMNYET:1; /*!< bit: 8 Link Power Management Not Yet */ + uint16_t LPMSUSP:1; /*!< bit: 9 Link Power Management Suspend */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_DEVICE_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_INTFLAG_OFFSET 0x01C /**< \brief (USB_DEVICE_INTFLAG offset) DEVICE Device Interrupt Flag */ +#define USB_DEVICE_INTFLAG_RESETVALUE 0x0000 /**< \brief (USB_DEVICE_INTFLAG reset_value) DEVICE Device Interrupt Flag */ + +#define USB_DEVICE_INTFLAG_SUSPEND_Pos 0 /**< \brief (USB_DEVICE_INTFLAG) Suspend */ +#define USB_DEVICE_INTFLAG_SUSPEND (0x1u << USB_DEVICE_INTFLAG_SUSPEND_Pos) +#define USB_DEVICE_INTFLAG_MSOF_Pos 1 /**< \brief (USB_DEVICE_INTFLAG) Micro Start of Frame in High Speed Mode */ +#define USB_DEVICE_INTFLAG_MSOF (0x1u << USB_DEVICE_INTFLAG_MSOF_Pos) +#define USB_DEVICE_INTFLAG_SOF_Pos 2 /**< \brief (USB_DEVICE_INTFLAG) Start Of Frame */ +#define USB_DEVICE_INTFLAG_SOF (0x1u << USB_DEVICE_INTFLAG_SOF_Pos) +#define USB_DEVICE_INTFLAG_EORST_Pos 3 /**< \brief (USB_DEVICE_INTFLAG) End of Reset */ +#define USB_DEVICE_INTFLAG_EORST (0x1u << USB_DEVICE_INTFLAG_EORST_Pos) +#define USB_DEVICE_INTFLAG_WAKEUP_Pos 4 /**< \brief (USB_DEVICE_INTFLAG) Wake Up */ +#define USB_DEVICE_INTFLAG_WAKEUP (0x1u << USB_DEVICE_INTFLAG_WAKEUP_Pos) +#define USB_DEVICE_INTFLAG_EORSM_Pos 5 /**< \brief (USB_DEVICE_INTFLAG) End Of Resume */ +#define USB_DEVICE_INTFLAG_EORSM (0x1u << USB_DEVICE_INTFLAG_EORSM_Pos) +#define USB_DEVICE_INTFLAG_UPRSM_Pos 6 /**< \brief (USB_DEVICE_INTFLAG) Upstream Resume */ +#define USB_DEVICE_INTFLAG_UPRSM (0x1u << USB_DEVICE_INTFLAG_UPRSM_Pos) +#define USB_DEVICE_INTFLAG_RAMACER_Pos 7 /**< \brief (USB_DEVICE_INTFLAG) Ram Access */ +#define USB_DEVICE_INTFLAG_RAMACER (0x1u << USB_DEVICE_INTFLAG_RAMACER_Pos) +#define USB_DEVICE_INTFLAG_LPMNYET_Pos 8 /**< \brief (USB_DEVICE_INTFLAG) Link Power Management Not Yet */ +#define USB_DEVICE_INTFLAG_LPMNYET (0x1u << USB_DEVICE_INTFLAG_LPMNYET_Pos) +#define USB_DEVICE_INTFLAG_LPMSUSP_Pos 9 /**< \brief (USB_DEVICE_INTFLAG) Link Power Management Suspend */ +#define USB_DEVICE_INTFLAG_LPMSUSP (0x1u << USB_DEVICE_INTFLAG_LPMSUSP_Pos) +#define USB_DEVICE_INTFLAG_MASK 0x03FFu /**< \brief (USB_DEVICE_INTFLAG) MASK Register */ + +/* -------- USB_HOST_INTFLAG : (USB Offset: 0x01C) (R/W 16) HOST HOST Host Interrupt Flag -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t :2; /*!< bit: 0.. 1 Reserved */ + uint16_t HSOF:1; /*!< bit: 2 Host Start Of Frame */ + uint16_t RST:1; /*!< bit: 3 Bus Reset */ + uint16_t WAKEUP:1; /*!< bit: 4 Wake Up */ + uint16_t DNRSM:1; /*!< bit: 5 Downstream */ + uint16_t UPRSM:1; /*!< bit: 6 Upstream Resume from the Device */ + uint16_t RAMACER:1; /*!< bit: 7 Ram Access */ + uint16_t DCONN:1; /*!< bit: 8 Device Connection */ + uint16_t DDISC:1; /*!< bit: 9 Device Disconnection */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_HOST_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_INTFLAG_OFFSET 0x01C /**< \brief (USB_HOST_INTFLAG offset) HOST Host Interrupt Flag */ +#define USB_HOST_INTFLAG_RESETVALUE 0x0000 /**< \brief (USB_HOST_INTFLAG reset_value) HOST Host Interrupt Flag */ + +#define USB_HOST_INTFLAG_HSOF_Pos 2 /**< \brief (USB_HOST_INTFLAG) Host Start Of Frame */ +#define USB_HOST_INTFLAG_HSOF (0x1u << USB_HOST_INTFLAG_HSOF_Pos) +#define USB_HOST_INTFLAG_RST_Pos 3 /**< \brief (USB_HOST_INTFLAG) Bus Reset */ +#define USB_HOST_INTFLAG_RST (0x1u << USB_HOST_INTFLAG_RST_Pos) +#define USB_HOST_INTFLAG_WAKEUP_Pos 4 /**< \brief (USB_HOST_INTFLAG) Wake Up */ +#define USB_HOST_INTFLAG_WAKEUP (0x1u << USB_HOST_INTFLAG_WAKEUP_Pos) +#define USB_HOST_INTFLAG_DNRSM_Pos 5 /**< \brief (USB_HOST_INTFLAG) Downstream */ +#define USB_HOST_INTFLAG_DNRSM (0x1u << USB_HOST_INTFLAG_DNRSM_Pos) +#define USB_HOST_INTFLAG_UPRSM_Pos 6 /**< \brief (USB_HOST_INTFLAG) Upstream Resume from the Device */ +#define USB_HOST_INTFLAG_UPRSM (0x1u << USB_HOST_INTFLAG_UPRSM_Pos) +#define USB_HOST_INTFLAG_RAMACER_Pos 7 /**< \brief (USB_HOST_INTFLAG) Ram Access */ +#define USB_HOST_INTFLAG_RAMACER (0x1u << USB_HOST_INTFLAG_RAMACER_Pos) +#define USB_HOST_INTFLAG_DCONN_Pos 8 /**< \brief (USB_HOST_INTFLAG) Device Connection */ +#define USB_HOST_INTFLAG_DCONN (0x1u << USB_HOST_INTFLAG_DCONN_Pos) +#define USB_HOST_INTFLAG_DDISC_Pos 9 /**< \brief (USB_HOST_INTFLAG) Device Disconnection */ +#define USB_HOST_INTFLAG_DDISC (0x1u << USB_HOST_INTFLAG_DDISC_Pos) +#define USB_HOST_INTFLAG_MASK 0x03FCu /**< \brief (USB_HOST_INTFLAG) MASK Register */ + +/* -------- USB_DEVICE_EPINTSMRY : (USB Offset: 0x020) (R/ 16) DEVICE DEVICE End Point Interrupt Summary -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t EPINT0:1; /*!< bit: 0 End Point 0 Interrupt */ + uint16_t EPINT1:1; /*!< bit: 1 End Point 1 Interrupt */ + uint16_t EPINT2:1; /*!< bit: 2 End Point 2 Interrupt */ + uint16_t EPINT3:1; /*!< bit: 3 End Point 3 Interrupt */ + uint16_t EPINT4:1; /*!< bit: 4 End Point 4 Interrupt */ + uint16_t EPINT5:1; /*!< bit: 5 End Point 5 Interrupt */ + uint16_t EPINT6:1; /*!< bit: 6 End Point 6 Interrupt */ + uint16_t EPINT7:1; /*!< bit: 7 End Point 7 Interrupt */ + uint16_t :8; /*!< bit: 8..15 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t EPINT:8; /*!< bit: 0.. 7 End Point x Interrupt */ + uint16_t :8; /*!< bit: 8..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} USB_DEVICE_EPINTSMRY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_EPINTSMRY_OFFSET 0x020 /**< \brief (USB_DEVICE_EPINTSMRY offset) DEVICE End Point Interrupt Summary */ +#define USB_DEVICE_EPINTSMRY_RESETVALUE 0x0000 /**< \brief (USB_DEVICE_EPINTSMRY reset_value) DEVICE End Point Interrupt Summary */ + +#define USB_DEVICE_EPINTSMRY_EPINT0_Pos 0 /**< \brief (USB_DEVICE_EPINTSMRY) End Point 0 Interrupt */ +#define USB_DEVICE_EPINTSMRY_EPINT0 (1 << USB_DEVICE_EPINTSMRY_EPINT0_Pos) +#define USB_DEVICE_EPINTSMRY_EPINT1_Pos 1 /**< \brief (USB_DEVICE_EPINTSMRY) End Point 1 Interrupt */ +#define USB_DEVICE_EPINTSMRY_EPINT1 (1 << USB_DEVICE_EPINTSMRY_EPINT1_Pos) +#define USB_DEVICE_EPINTSMRY_EPINT2_Pos 2 /**< \brief (USB_DEVICE_EPINTSMRY) End Point 2 Interrupt */ +#define USB_DEVICE_EPINTSMRY_EPINT2 (1 << USB_DEVICE_EPINTSMRY_EPINT2_Pos) +#define USB_DEVICE_EPINTSMRY_EPINT3_Pos 3 /**< \brief (USB_DEVICE_EPINTSMRY) End Point 3 Interrupt */ +#define USB_DEVICE_EPINTSMRY_EPINT3 (1 << USB_DEVICE_EPINTSMRY_EPINT3_Pos) +#define USB_DEVICE_EPINTSMRY_EPINT4_Pos 4 /**< \brief (USB_DEVICE_EPINTSMRY) End Point 4 Interrupt */ +#define USB_DEVICE_EPINTSMRY_EPINT4 (1 << USB_DEVICE_EPINTSMRY_EPINT4_Pos) +#define USB_DEVICE_EPINTSMRY_EPINT5_Pos 5 /**< \brief (USB_DEVICE_EPINTSMRY) End Point 5 Interrupt */ +#define USB_DEVICE_EPINTSMRY_EPINT5 (1 << USB_DEVICE_EPINTSMRY_EPINT5_Pos) +#define USB_DEVICE_EPINTSMRY_EPINT6_Pos 6 /**< \brief (USB_DEVICE_EPINTSMRY) End Point 6 Interrupt */ +#define USB_DEVICE_EPINTSMRY_EPINT6 (1 << USB_DEVICE_EPINTSMRY_EPINT6_Pos) +#define USB_DEVICE_EPINTSMRY_EPINT7_Pos 7 /**< \brief (USB_DEVICE_EPINTSMRY) End Point 7 Interrupt */ +#define USB_DEVICE_EPINTSMRY_EPINT7 (1 << USB_DEVICE_EPINTSMRY_EPINT7_Pos) +#define USB_DEVICE_EPINTSMRY_EPINT_Pos 0 /**< \brief (USB_DEVICE_EPINTSMRY) End Point x Interrupt */ +#define USB_DEVICE_EPINTSMRY_EPINT_Msk (0xFFu << USB_DEVICE_EPINTSMRY_EPINT_Pos) +#define USB_DEVICE_EPINTSMRY_EPINT(value) ((USB_DEVICE_EPINTSMRY_EPINT_Msk & ((value) << USB_DEVICE_EPINTSMRY_EPINT_Pos))) +#define USB_DEVICE_EPINTSMRY_MASK 0x00FFu /**< \brief (USB_DEVICE_EPINTSMRY) MASK Register */ + +/* -------- USB_HOST_PINTSMRY : (USB Offset: 0x020) (R/ 16) HOST HOST Pipe Interrupt Summary -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t EPINT0:1; /*!< bit: 0 Pipe 0 Interrupt */ + uint16_t EPINT1:1; /*!< bit: 1 Pipe 1 Interrupt */ + uint16_t EPINT2:1; /*!< bit: 2 Pipe 2 Interrupt */ + uint16_t EPINT3:1; /*!< bit: 3 Pipe 3 Interrupt */ + uint16_t EPINT4:1; /*!< bit: 4 Pipe 4 Interrupt */ + uint16_t EPINT5:1; /*!< bit: 5 Pipe 5 Interrupt */ + uint16_t EPINT6:1; /*!< bit: 6 Pipe 6 Interrupt */ + uint16_t EPINT7:1; /*!< bit: 7 Pipe 7 Interrupt */ + uint16_t :8; /*!< bit: 8..15 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t EPINT:8; /*!< bit: 0.. 7 Pipe x Interrupt */ + uint16_t :8; /*!< bit: 8..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} USB_HOST_PINTSMRY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_PINTSMRY_OFFSET 0x020 /**< \brief (USB_HOST_PINTSMRY offset) HOST Pipe Interrupt Summary */ +#define USB_HOST_PINTSMRY_RESETVALUE 0x0000 /**< \brief (USB_HOST_PINTSMRY reset_value) HOST Pipe Interrupt Summary */ + +#define USB_HOST_PINTSMRY_EPINT0_Pos 0 /**< \brief (USB_HOST_PINTSMRY) Pipe 0 Interrupt */ +#define USB_HOST_PINTSMRY_EPINT0 (1 << USB_HOST_PINTSMRY_EPINT0_Pos) +#define USB_HOST_PINTSMRY_EPINT1_Pos 1 /**< \brief (USB_HOST_PINTSMRY) Pipe 1 Interrupt */ +#define USB_HOST_PINTSMRY_EPINT1 (1 << USB_HOST_PINTSMRY_EPINT1_Pos) +#define USB_HOST_PINTSMRY_EPINT2_Pos 2 /**< \brief (USB_HOST_PINTSMRY) Pipe 2 Interrupt */ +#define USB_HOST_PINTSMRY_EPINT2 (1 << USB_HOST_PINTSMRY_EPINT2_Pos) +#define USB_HOST_PINTSMRY_EPINT3_Pos 3 /**< \brief (USB_HOST_PINTSMRY) Pipe 3 Interrupt */ +#define USB_HOST_PINTSMRY_EPINT3 (1 << USB_HOST_PINTSMRY_EPINT3_Pos) +#define USB_HOST_PINTSMRY_EPINT4_Pos 4 /**< \brief (USB_HOST_PINTSMRY) Pipe 4 Interrupt */ +#define USB_HOST_PINTSMRY_EPINT4 (1 << USB_HOST_PINTSMRY_EPINT4_Pos) +#define USB_HOST_PINTSMRY_EPINT5_Pos 5 /**< \brief (USB_HOST_PINTSMRY) Pipe 5 Interrupt */ +#define USB_HOST_PINTSMRY_EPINT5 (1 << USB_HOST_PINTSMRY_EPINT5_Pos) +#define USB_HOST_PINTSMRY_EPINT6_Pos 6 /**< \brief (USB_HOST_PINTSMRY) Pipe 6 Interrupt */ +#define USB_HOST_PINTSMRY_EPINT6 (1 << USB_HOST_PINTSMRY_EPINT6_Pos) +#define USB_HOST_PINTSMRY_EPINT7_Pos 7 /**< \brief (USB_HOST_PINTSMRY) Pipe 7 Interrupt */ +#define USB_HOST_PINTSMRY_EPINT7 (1 << USB_HOST_PINTSMRY_EPINT7_Pos) +#define USB_HOST_PINTSMRY_EPINT_Pos 0 /**< \brief (USB_HOST_PINTSMRY) Pipe x Interrupt */ +#define USB_HOST_PINTSMRY_EPINT_Msk (0xFFu << USB_HOST_PINTSMRY_EPINT_Pos) +#define USB_HOST_PINTSMRY_EPINT(value) ((USB_HOST_PINTSMRY_EPINT_Msk & ((value) << USB_HOST_PINTSMRY_EPINT_Pos))) +#define USB_HOST_PINTSMRY_MASK 0x00FFu /**< \brief (USB_HOST_PINTSMRY) MASK Register */ + +/* -------- USB_DESCADD : (USB Offset: 0x024) (R/W 32) Descriptor Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DESCADD:32; /*!< bit: 0..31 Descriptor Address Value */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} USB_DESCADD_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DESCADD_OFFSET 0x024 /**< \brief (USB_DESCADD offset) Descriptor Address */ +#define USB_DESCADD_RESETVALUE 0x00000000 /**< \brief (USB_DESCADD reset_value) Descriptor Address */ + +#define USB_DESCADD_DESCADD_Pos 0 /**< \brief (USB_DESCADD) Descriptor Address Value */ +#define USB_DESCADD_DESCADD_Msk (0xFFFFFFFFu << USB_DESCADD_DESCADD_Pos) +#define USB_DESCADD_DESCADD(value) ((USB_DESCADD_DESCADD_Msk & ((value) << USB_DESCADD_DESCADD_Pos))) +#define USB_DESCADD_MASK 0xFFFFFFFFu /**< \brief (USB_DESCADD) MASK Register */ + +/* -------- USB_PADCAL : (USB Offset: 0x028) (R/W 16) USB PAD Calibration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t TRANSP:5; /*!< bit: 0.. 4 USB Pad Transp calibration */ + uint16_t :1; /*!< bit: 5 Reserved */ + uint16_t TRANSN:5; /*!< bit: 6..10 USB Pad Transn calibration */ + uint16_t :1; /*!< bit: 11 Reserved */ + uint16_t TRIM:3; /*!< bit: 12..14 USB Pad Trim calibration */ + uint16_t :1; /*!< bit: 15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_PADCAL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_PADCAL_OFFSET 0x028 /**< \brief (USB_PADCAL offset) USB PAD Calibration */ +#define USB_PADCAL_RESETVALUE 0x0000 /**< \brief (USB_PADCAL reset_value) USB PAD Calibration */ + +#define USB_PADCAL_TRANSP_Pos 0 /**< \brief (USB_PADCAL) USB Pad Transp calibration */ +#define USB_PADCAL_TRANSP_Msk (0x1Fu << USB_PADCAL_TRANSP_Pos) +#define USB_PADCAL_TRANSP(value) ((USB_PADCAL_TRANSP_Msk & ((value) << USB_PADCAL_TRANSP_Pos))) +#define USB_PADCAL_TRANSN_Pos 6 /**< \brief (USB_PADCAL) USB Pad Transn calibration */ +#define USB_PADCAL_TRANSN_Msk (0x1Fu << USB_PADCAL_TRANSN_Pos) +#define USB_PADCAL_TRANSN(value) ((USB_PADCAL_TRANSN_Msk & ((value) << USB_PADCAL_TRANSN_Pos))) +#define USB_PADCAL_TRIM_Pos 12 /**< \brief (USB_PADCAL) USB Pad Trim calibration */ +#define USB_PADCAL_TRIM_Msk (0x7u << USB_PADCAL_TRIM_Pos) +#define USB_PADCAL_TRIM(value) ((USB_PADCAL_TRIM_Msk & ((value) << USB_PADCAL_TRIM_Pos))) +#define USB_PADCAL_MASK 0x77DFu /**< \brief (USB_PADCAL) MASK Register */ + +/* -------- USB_DEVICE_EPCFG : (USB Offset: 0x100) (R/W 8) DEVICE DEVICE_ENDPOINT End Point Configuration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t EPTYPE0:3; /*!< bit: 0.. 2 End Point Type0 */ + uint8_t :1; /*!< bit: 3 Reserved */ + uint8_t EPTYPE1:3; /*!< bit: 4.. 6 End Point Type1 */ + uint8_t NYETDIS:1; /*!< bit: 7 NYET Token Disable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_EPCFG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_EPCFG_OFFSET 0x100 /**< \brief (USB_DEVICE_EPCFG offset) DEVICE_ENDPOINT End Point Configuration */ +#define USB_DEVICE_EPCFG_RESETVALUE 0x00 /**< \brief (USB_DEVICE_EPCFG reset_value) DEVICE_ENDPOINT End Point Configuration */ + +#define USB_DEVICE_EPCFG_EPTYPE0_Pos 0 /**< \brief (USB_DEVICE_EPCFG) End Point Type0 */ +#define USB_DEVICE_EPCFG_EPTYPE0_Msk (0x7u << USB_DEVICE_EPCFG_EPTYPE0_Pos) +#define USB_DEVICE_EPCFG_EPTYPE0(value) ((USB_DEVICE_EPCFG_EPTYPE0_Msk & ((value) << USB_DEVICE_EPCFG_EPTYPE0_Pos))) +#define USB_DEVICE_EPCFG_EPTYPE1_Pos 4 /**< \brief (USB_DEVICE_EPCFG) End Point Type1 */ +#define USB_DEVICE_EPCFG_EPTYPE1_Msk (0x7u << USB_DEVICE_EPCFG_EPTYPE1_Pos) +#define USB_DEVICE_EPCFG_EPTYPE1(value) ((USB_DEVICE_EPCFG_EPTYPE1_Msk & ((value) << USB_DEVICE_EPCFG_EPTYPE1_Pos))) +#define USB_DEVICE_EPCFG_NYETDIS_Pos 7 /**< \brief (USB_DEVICE_EPCFG) NYET Token Disable */ +#define USB_DEVICE_EPCFG_NYETDIS (0x1u << USB_DEVICE_EPCFG_NYETDIS_Pos) +#define USB_DEVICE_EPCFG_MASK 0xF7u /**< \brief (USB_DEVICE_EPCFG) MASK Register */ + +/* -------- USB_HOST_PCFG : (USB Offset: 0x100) (R/W 8) HOST HOST_PIPE End Point Configuration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PTOKEN:2; /*!< bit: 0.. 1 Pipe Token */ + uint8_t BK:1; /*!< bit: 2 Pipe Bank */ + uint8_t PTYPE:3; /*!< bit: 3.. 5 Pipe Type */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_PCFG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_PCFG_OFFSET 0x100 /**< \brief (USB_HOST_PCFG offset) HOST_PIPE End Point Configuration */ +#define USB_HOST_PCFG_RESETVALUE 0x00 /**< \brief (USB_HOST_PCFG reset_value) HOST_PIPE End Point Configuration */ + +#define USB_HOST_PCFG_PTOKEN_Pos 0 /**< \brief (USB_HOST_PCFG) Pipe Token */ +#define USB_HOST_PCFG_PTOKEN_Msk (0x3u << USB_HOST_PCFG_PTOKEN_Pos) +#define USB_HOST_PCFG_PTOKEN(value) ((USB_HOST_PCFG_PTOKEN_Msk & ((value) << USB_HOST_PCFG_PTOKEN_Pos))) +#define USB_HOST_PCFG_BK_Pos 2 /**< \brief (USB_HOST_PCFG) Pipe Bank */ +#define USB_HOST_PCFG_BK (0x1u << USB_HOST_PCFG_BK_Pos) +#define USB_HOST_PCFG_PTYPE_Pos 3 /**< \brief (USB_HOST_PCFG) Pipe Type */ +#define USB_HOST_PCFG_PTYPE_Msk (0x7u << USB_HOST_PCFG_PTYPE_Pos) +#define USB_HOST_PCFG_PTYPE(value) ((USB_HOST_PCFG_PTYPE_Msk & ((value) << USB_HOST_PCFG_PTYPE_Pos))) +#define USB_HOST_PCFG_MASK 0x3Fu /**< \brief (USB_HOST_PCFG) MASK Register */ + +/* -------- USB_HOST_BINTERVAL : (USB Offset: 0x103) (R/W 8) HOST HOST_PIPE Bus Access Period of Pipe -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t BITINTERVAL:8; /*!< bit: 0.. 7 Bit Interval */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_BINTERVAL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_BINTERVAL_OFFSET 0x103 /**< \brief (USB_HOST_BINTERVAL offset) HOST_PIPE Bus Access Period of Pipe */ +#define USB_HOST_BINTERVAL_RESETVALUE 0x00 /**< \brief (USB_HOST_BINTERVAL reset_value) HOST_PIPE Bus Access Period of Pipe */ + +#define USB_HOST_BINTERVAL_BITINTERVAL_Pos 0 /**< \brief (USB_HOST_BINTERVAL) Bit Interval */ +#define USB_HOST_BINTERVAL_BITINTERVAL_Msk (0xFFu << USB_HOST_BINTERVAL_BITINTERVAL_Pos) +#define USB_HOST_BINTERVAL_BITINTERVAL(value) ((USB_HOST_BINTERVAL_BITINTERVAL_Msk & ((value) << USB_HOST_BINTERVAL_BITINTERVAL_Pos))) +#define USB_HOST_BINTERVAL_MASK 0xFFu /**< \brief (USB_HOST_BINTERVAL) MASK Register */ + +/* -------- USB_DEVICE_EPSTATUSCLR : (USB Offset: 0x104) ( /W 8) DEVICE DEVICE_ENDPOINT End Point Pipe Status Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DTGLOUT:1; /*!< bit: 0 Data Toggle OUT Clear */ + uint8_t DTGLIN:1; /*!< bit: 1 Data Toggle IN Clear */ + uint8_t CURBK:1; /*!< bit: 2 Curren Bank Clear */ + uint8_t :1; /*!< bit: 3 Reserved */ + uint8_t STALLRQ0:1; /*!< bit: 4 Stall 0 Request Clear */ + uint8_t STALLRQ1:1; /*!< bit: 5 Stall 1 Request Clear */ + uint8_t BK0RDY:1; /*!< bit: 6 Bank 0 Ready Clear */ + uint8_t BK1RDY:1; /*!< bit: 7 Bank 1 Ready Clear */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t :4; /*!< bit: 0.. 3 Reserved */ + uint8_t STALLRQ:2; /*!< bit: 4.. 5 Stall x Request Clear */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_EPSTATUSCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_EPSTATUSCLR_OFFSET 0x104 /**< \brief (USB_DEVICE_EPSTATUSCLR offset) DEVICE_ENDPOINT End Point Pipe Status Clear */ +#define USB_DEVICE_EPSTATUSCLR_RESETVALUE 0x00 /**< \brief (USB_DEVICE_EPSTATUSCLR reset_value) DEVICE_ENDPOINT End Point Pipe Status Clear */ + +#define USB_DEVICE_EPSTATUSCLR_DTGLOUT_Pos 0 /**< \brief (USB_DEVICE_EPSTATUSCLR) Data Toggle OUT Clear */ +#define USB_DEVICE_EPSTATUSCLR_DTGLOUT (0x1u << USB_DEVICE_EPSTATUSCLR_DTGLOUT_Pos) +#define USB_DEVICE_EPSTATUSCLR_DTGLIN_Pos 1 /**< \brief (USB_DEVICE_EPSTATUSCLR) Data Toggle IN Clear */ +#define USB_DEVICE_EPSTATUSCLR_DTGLIN (0x1u << USB_DEVICE_EPSTATUSCLR_DTGLIN_Pos) +#define USB_DEVICE_EPSTATUSCLR_CURBK_Pos 2 /**< \brief (USB_DEVICE_EPSTATUSCLR) Curren Bank Clear */ +#define USB_DEVICE_EPSTATUSCLR_CURBK (0x1u << USB_DEVICE_EPSTATUSCLR_CURBK_Pos) +#define USB_DEVICE_EPSTATUSCLR_STALLRQ0_Pos 4 /**< \brief (USB_DEVICE_EPSTATUSCLR) Stall 0 Request Clear */ +#define USB_DEVICE_EPSTATUSCLR_STALLRQ0 (1 << USB_DEVICE_EPSTATUSCLR_STALLRQ0_Pos) +#define USB_DEVICE_EPSTATUSCLR_STALLRQ1_Pos 5 /**< \brief (USB_DEVICE_EPSTATUSCLR) Stall 1 Request Clear */ +#define USB_DEVICE_EPSTATUSCLR_STALLRQ1 (1 << USB_DEVICE_EPSTATUSCLR_STALLRQ1_Pos) +#define USB_DEVICE_EPSTATUSCLR_STALLRQ_Pos 4 /**< \brief (USB_DEVICE_EPSTATUSCLR) Stall x Request Clear */ +#define USB_DEVICE_EPSTATUSCLR_STALLRQ_Msk (0x3u << USB_DEVICE_EPSTATUSCLR_STALLRQ_Pos) +#define USB_DEVICE_EPSTATUSCLR_STALLRQ(value) ((USB_DEVICE_EPSTATUSCLR_STALLRQ_Msk & ((value) << USB_DEVICE_EPSTATUSCLR_STALLRQ_Pos))) +#define USB_DEVICE_EPSTATUSCLR_BK0RDY_Pos 6 /**< \brief (USB_DEVICE_EPSTATUSCLR) Bank 0 Ready Clear */ +#define USB_DEVICE_EPSTATUSCLR_BK0RDY (0x1u << USB_DEVICE_EPSTATUSCLR_BK0RDY_Pos) +#define USB_DEVICE_EPSTATUSCLR_BK1RDY_Pos 7 /**< \brief (USB_DEVICE_EPSTATUSCLR) Bank 1 Ready Clear */ +#define USB_DEVICE_EPSTATUSCLR_BK1RDY (0x1u << USB_DEVICE_EPSTATUSCLR_BK1RDY_Pos) +#define USB_DEVICE_EPSTATUSCLR_MASK 0xF7u /**< \brief (USB_DEVICE_EPSTATUSCLR) MASK Register */ + +/* -------- USB_HOST_PSTATUSCLR : (USB Offset: 0x104) ( /W 8) HOST HOST_PIPE End Point Pipe Status Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DTGL:1; /*!< bit: 0 Data Toggle clear */ + uint8_t :1; /*!< bit: 1 Reserved */ + uint8_t CURBK:1; /*!< bit: 2 Curren Bank clear */ + uint8_t :1; /*!< bit: 3 Reserved */ + uint8_t PFREEZE:1; /*!< bit: 4 Pipe Freeze Clear */ + uint8_t :1; /*!< bit: 5 Reserved */ + uint8_t BK0RDY:1; /*!< bit: 6 Bank 0 Ready Clear */ + uint8_t BK1RDY:1; /*!< bit: 7 Bank 1 Ready Clear */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_PSTATUSCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_PSTATUSCLR_OFFSET 0x104 /**< \brief (USB_HOST_PSTATUSCLR offset) HOST_PIPE End Point Pipe Status Clear */ +#define USB_HOST_PSTATUSCLR_RESETVALUE 0x00 /**< \brief (USB_HOST_PSTATUSCLR reset_value) HOST_PIPE End Point Pipe Status Clear */ + +#define USB_HOST_PSTATUSCLR_DTGL_Pos 0 /**< \brief (USB_HOST_PSTATUSCLR) Data Toggle clear */ +#define USB_HOST_PSTATUSCLR_DTGL (0x1u << USB_HOST_PSTATUSCLR_DTGL_Pos) +#define USB_HOST_PSTATUSCLR_CURBK_Pos 2 /**< \brief (USB_HOST_PSTATUSCLR) Curren Bank clear */ +#define USB_HOST_PSTATUSCLR_CURBK (0x1u << USB_HOST_PSTATUSCLR_CURBK_Pos) +#define USB_HOST_PSTATUSCLR_PFREEZE_Pos 4 /**< \brief (USB_HOST_PSTATUSCLR) Pipe Freeze Clear */ +#define USB_HOST_PSTATUSCLR_PFREEZE (0x1u << USB_HOST_PSTATUSCLR_PFREEZE_Pos) +#define USB_HOST_PSTATUSCLR_BK0RDY_Pos 6 /**< \brief (USB_HOST_PSTATUSCLR) Bank 0 Ready Clear */ +#define USB_HOST_PSTATUSCLR_BK0RDY (0x1u << USB_HOST_PSTATUSCLR_BK0RDY_Pos) +#define USB_HOST_PSTATUSCLR_BK1RDY_Pos 7 /**< \brief (USB_HOST_PSTATUSCLR) Bank 1 Ready Clear */ +#define USB_HOST_PSTATUSCLR_BK1RDY (0x1u << USB_HOST_PSTATUSCLR_BK1RDY_Pos) +#define USB_HOST_PSTATUSCLR_MASK 0xD5u /**< \brief (USB_HOST_PSTATUSCLR) MASK Register */ + +/* -------- USB_DEVICE_EPSTATUSSET : (USB Offset: 0x105) ( /W 8) DEVICE DEVICE_ENDPOINT End Point Pipe Status Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DTGLOUT:1; /*!< bit: 0 Data Toggle OUT Set */ + uint8_t DTGLIN:1; /*!< bit: 1 Data Toggle IN Set */ + uint8_t CURBK:1; /*!< bit: 2 Current Bank Set */ + uint8_t :1; /*!< bit: 3 Reserved */ + uint8_t STALLRQ0:1; /*!< bit: 4 Stall 0 Request Set */ + uint8_t STALLRQ1:1; /*!< bit: 5 Stall 1 Request Set */ + uint8_t BK0RDY:1; /*!< bit: 6 Bank 0 Ready Set */ + uint8_t BK1RDY:1; /*!< bit: 7 Bank 1 Ready Set */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t :4; /*!< bit: 0.. 3 Reserved */ + uint8_t STALLRQ:2; /*!< bit: 4.. 5 Stall x Request Set */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_EPSTATUSSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_EPSTATUSSET_OFFSET 0x105 /**< \brief (USB_DEVICE_EPSTATUSSET offset) DEVICE_ENDPOINT End Point Pipe Status Set */ +#define USB_DEVICE_EPSTATUSSET_RESETVALUE 0x00 /**< \brief (USB_DEVICE_EPSTATUSSET reset_value) DEVICE_ENDPOINT End Point Pipe Status Set */ + +#define USB_DEVICE_EPSTATUSSET_DTGLOUT_Pos 0 /**< \brief (USB_DEVICE_EPSTATUSSET) Data Toggle OUT Set */ +#define USB_DEVICE_EPSTATUSSET_DTGLOUT (0x1u << USB_DEVICE_EPSTATUSSET_DTGLOUT_Pos) +#define USB_DEVICE_EPSTATUSSET_DTGLIN_Pos 1 /**< \brief (USB_DEVICE_EPSTATUSSET) Data Toggle IN Set */ +#define USB_DEVICE_EPSTATUSSET_DTGLIN (0x1u << USB_DEVICE_EPSTATUSSET_DTGLIN_Pos) +#define USB_DEVICE_EPSTATUSSET_CURBK_Pos 2 /**< \brief (USB_DEVICE_EPSTATUSSET) Current Bank Set */ +#define USB_DEVICE_EPSTATUSSET_CURBK (0x1u << USB_DEVICE_EPSTATUSSET_CURBK_Pos) +#define USB_DEVICE_EPSTATUSSET_STALLRQ0_Pos 4 /**< \brief (USB_DEVICE_EPSTATUSSET) Stall 0 Request Set */ +#define USB_DEVICE_EPSTATUSSET_STALLRQ0 (1 << USB_DEVICE_EPSTATUSSET_STALLRQ0_Pos) +#define USB_DEVICE_EPSTATUSSET_STALLRQ1_Pos 5 /**< \brief (USB_DEVICE_EPSTATUSSET) Stall 1 Request Set */ +#define USB_DEVICE_EPSTATUSSET_STALLRQ1 (1 << USB_DEVICE_EPSTATUSSET_STALLRQ1_Pos) +#define USB_DEVICE_EPSTATUSSET_STALLRQ_Pos 4 /**< \brief (USB_DEVICE_EPSTATUSSET) Stall x Request Set */ +#define USB_DEVICE_EPSTATUSSET_STALLRQ_Msk (0x3u << USB_DEVICE_EPSTATUSSET_STALLRQ_Pos) +#define USB_DEVICE_EPSTATUSSET_STALLRQ(value) ((USB_DEVICE_EPSTATUSSET_STALLRQ_Msk & ((value) << USB_DEVICE_EPSTATUSSET_STALLRQ_Pos))) +#define USB_DEVICE_EPSTATUSSET_BK0RDY_Pos 6 /**< \brief (USB_DEVICE_EPSTATUSSET) Bank 0 Ready Set */ +#define USB_DEVICE_EPSTATUSSET_BK0RDY (0x1u << USB_DEVICE_EPSTATUSSET_BK0RDY_Pos) +#define USB_DEVICE_EPSTATUSSET_BK1RDY_Pos 7 /**< \brief (USB_DEVICE_EPSTATUSSET) Bank 1 Ready Set */ +#define USB_DEVICE_EPSTATUSSET_BK1RDY (0x1u << USB_DEVICE_EPSTATUSSET_BK1RDY_Pos) +#define USB_DEVICE_EPSTATUSSET_MASK 0xF7u /**< \brief (USB_DEVICE_EPSTATUSSET) MASK Register */ + +/* -------- USB_HOST_PSTATUSSET : (USB Offset: 0x105) ( /W 8) HOST HOST_PIPE End Point Pipe Status Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DTGL:1; /*!< bit: 0 Data Toggle Set */ + uint8_t :1; /*!< bit: 1 Reserved */ + uint8_t CURBK:1; /*!< bit: 2 Current Bank Set */ + uint8_t :1; /*!< bit: 3 Reserved */ + uint8_t PFREEZE:1; /*!< bit: 4 Pipe Freeze Set */ + uint8_t :1; /*!< bit: 5 Reserved */ + uint8_t BK0RDY:1; /*!< bit: 6 Bank 0 Ready Set */ + uint8_t BK1RDY:1; /*!< bit: 7 Bank 1 Ready Set */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_PSTATUSSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_PSTATUSSET_OFFSET 0x105 /**< \brief (USB_HOST_PSTATUSSET offset) HOST_PIPE End Point Pipe Status Set */ +#define USB_HOST_PSTATUSSET_RESETVALUE 0x00 /**< \brief (USB_HOST_PSTATUSSET reset_value) HOST_PIPE End Point Pipe Status Set */ + +#define USB_HOST_PSTATUSSET_DTGL_Pos 0 /**< \brief (USB_HOST_PSTATUSSET) Data Toggle Set */ +#define USB_HOST_PSTATUSSET_DTGL (0x1u << USB_HOST_PSTATUSSET_DTGL_Pos) +#define USB_HOST_PSTATUSSET_CURBK_Pos 2 /**< \brief (USB_HOST_PSTATUSSET) Current Bank Set */ +#define USB_HOST_PSTATUSSET_CURBK (0x1u << USB_HOST_PSTATUSSET_CURBK_Pos) +#define USB_HOST_PSTATUSSET_PFREEZE_Pos 4 /**< \brief (USB_HOST_PSTATUSSET) Pipe Freeze Set */ +#define USB_HOST_PSTATUSSET_PFREEZE (0x1u << USB_HOST_PSTATUSSET_PFREEZE_Pos) +#define USB_HOST_PSTATUSSET_BK0RDY_Pos 6 /**< \brief (USB_HOST_PSTATUSSET) Bank 0 Ready Set */ +#define USB_HOST_PSTATUSSET_BK0RDY (0x1u << USB_HOST_PSTATUSSET_BK0RDY_Pos) +#define USB_HOST_PSTATUSSET_BK1RDY_Pos 7 /**< \brief (USB_HOST_PSTATUSSET) Bank 1 Ready Set */ +#define USB_HOST_PSTATUSSET_BK1RDY (0x1u << USB_HOST_PSTATUSSET_BK1RDY_Pos) +#define USB_HOST_PSTATUSSET_MASK 0xD5u /**< \brief (USB_HOST_PSTATUSSET) MASK Register */ + +/* -------- USB_DEVICE_EPSTATUS : (USB Offset: 0x106) (R/ 8) DEVICE DEVICE_ENDPOINT End Point Pipe Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DTGLOUT:1; /*!< bit: 0 Data Toggle Out */ + uint8_t DTGLIN:1; /*!< bit: 1 Data Toggle In */ + uint8_t CURBK:1; /*!< bit: 2 Current Bank */ + uint8_t :1; /*!< bit: 3 Reserved */ + uint8_t STALLRQ0:1; /*!< bit: 4 Stall 0 Request */ + uint8_t STALLRQ1:1; /*!< bit: 5 Stall 1 Request */ + uint8_t BK0RDY:1; /*!< bit: 6 Bank 0 ready */ + uint8_t BK1RDY:1; /*!< bit: 7 Bank 1 ready */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t :4; /*!< bit: 0.. 3 Reserved */ + uint8_t STALLRQ:2; /*!< bit: 4.. 5 Stall x Request */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_EPSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_EPSTATUS_OFFSET 0x106 /**< \brief (USB_DEVICE_EPSTATUS offset) DEVICE_ENDPOINT End Point Pipe Status */ +#define USB_DEVICE_EPSTATUS_RESETVALUE 0x00 /**< \brief (USB_DEVICE_EPSTATUS reset_value) DEVICE_ENDPOINT End Point Pipe Status */ + +#define USB_DEVICE_EPSTATUS_DTGLOUT_Pos 0 /**< \brief (USB_DEVICE_EPSTATUS) Data Toggle Out */ +#define USB_DEVICE_EPSTATUS_DTGLOUT (0x1u << USB_DEVICE_EPSTATUS_DTGLOUT_Pos) +#define USB_DEVICE_EPSTATUS_DTGLIN_Pos 1 /**< \brief (USB_DEVICE_EPSTATUS) Data Toggle In */ +#define USB_DEVICE_EPSTATUS_DTGLIN (0x1u << USB_DEVICE_EPSTATUS_DTGLIN_Pos) +#define USB_DEVICE_EPSTATUS_CURBK_Pos 2 /**< \brief (USB_DEVICE_EPSTATUS) Current Bank */ +#define USB_DEVICE_EPSTATUS_CURBK (0x1u << USB_DEVICE_EPSTATUS_CURBK_Pos) +#define USB_DEVICE_EPSTATUS_STALLRQ0_Pos 4 /**< \brief (USB_DEVICE_EPSTATUS) Stall 0 Request */ +#define USB_DEVICE_EPSTATUS_STALLRQ0 (1 << USB_DEVICE_EPSTATUS_STALLRQ0_Pos) +#define USB_DEVICE_EPSTATUS_STALLRQ1_Pos 5 /**< \brief (USB_DEVICE_EPSTATUS) Stall 1 Request */ +#define USB_DEVICE_EPSTATUS_STALLRQ1 (1 << USB_DEVICE_EPSTATUS_STALLRQ1_Pos) +#define USB_DEVICE_EPSTATUS_STALLRQ_Pos 4 /**< \brief (USB_DEVICE_EPSTATUS) Stall x Request */ +#define USB_DEVICE_EPSTATUS_STALLRQ_Msk (0x3u << USB_DEVICE_EPSTATUS_STALLRQ_Pos) +#define USB_DEVICE_EPSTATUS_STALLRQ(value) ((USB_DEVICE_EPSTATUS_STALLRQ_Msk & ((value) << USB_DEVICE_EPSTATUS_STALLRQ_Pos))) +#define USB_DEVICE_EPSTATUS_BK0RDY_Pos 6 /**< \brief (USB_DEVICE_EPSTATUS) Bank 0 ready */ +#define USB_DEVICE_EPSTATUS_BK0RDY (0x1u << USB_DEVICE_EPSTATUS_BK0RDY_Pos) +#define USB_DEVICE_EPSTATUS_BK1RDY_Pos 7 /**< \brief (USB_DEVICE_EPSTATUS) Bank 1 ready */ +#define USB_DEVICE_EPSTATUS_BK1RDY (0x1u << USB_DEVICE_EPSTATUS_BK1RDY_Pos) +#define USB_DEVICE_EPSTATUS_MASK 0xF7u /**< \brief (USB_DEVICE_EPSTATUS) MASK Register */ + +/* -------- USB_HOST_PSTATUS : (USB Offset: 0x106) (R/ 8) HOST HOST_PIPE End Point Pipe Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DTGL:1; /*!< bit: 0 Data Toggle */ + uint8_t :1; /*!< bit: 1 Reserved */ + uint8_t CURBK:1; /*!< bit: 2 Current Bank */ + uint8_t :1; /*!< bit: 3 Reserved */ + uint8_t PFREEZE:1; /*!< bit: 4 Pipe Freeze */ + uint8_t :1; /*!< bit: 5 Reserved */ + uint8_t BK0RDY:1; /*!< bit: 6 Bank 0 ready */ + uint8_t BK1RDY:1; /*!< bit: 7 Bank 1 ready */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_PSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_PSTATUS_OFFSET 0x106 /**< \brief (USB_HOST_PSTATUS offset) HOST_PIPE End Point Pipe Status */ +#define USB_HOST_PSTATUS_RESETVALUE 0x00 /**< \brief (USB_HOST_PSTATUS reset_value) HOST_PIPE End Point Pipe Status */ + +#define USB_HOST_PSTATUS_DTGL_Pos 0 /**< \brief (USB_HOST_PSTATUS) Data Toggle */ +#define USB_HOST_PSTATUS_DTGL (0x1u << USB_HOST_PSTATUS_DTGL_Pos) +#define USB_HOST_PSTATUS_CURBK_Pos 2 /**< \brief (USB_HOST_PSTATUS) Current Bank */ +#define USB_HOST_PSTATUS_CURBK (0x1u << USB_HOST_PSTATUS_CURBK_Pos) +#define USB_HOST_PSTATUS_PFREEZE_Pos 4 /**< \brief (USB_HOST_PSTATUS) Pipe Freeze */ +#define USB_HOST_PSTATUS_PFREEZE (0x1u << USB_HOST_PSTATUS_PFREEZE_Pos) +#define USB_HOST_PSTATUS_BK0RDY_Pos 6 /**< \brief (USB_HOST_PSTATUS) Bank 0 ready */ +#define USB_HOST_PSTATUS_BK0RDY (0x1u << USB_HOST_PSTATUS_BK0RDY_Pos) +#define USB_HOST_PSTATUS_BK1RDY_Pos 7 /**< \brief (USB_HOST_PSTATUS) Bank 1 ready */ +#define USB_HOST_PSTATUS_BK1RDY (0x1u << USB_HOST_PSTATUS_BK1RDY_Pos) +#define USB_HOST_PSTATUS_MASK 0xD5u /**< \brief (USB_HOST_PSTATUS) MASK Register */ + +/* -------- USB_DEVICE_EPINTFLAG : (USB Offset: 0x107) (R/W 8) DEVICE DEVICE_ENDPOINT End Point Interrupt Flag -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t TRCPT0:1; /*!< bit: 0 Transfer Complete 0 */ + uint8_t TRCPT1:1; /*!< bit: 1 Transfer Complete 1 */ + uint8_t TRFAIL0:1; /*!< bit: 2 Error Flow 0 */ + uint8_t TRFAIL1:1; /*!< bit: 3 Error Flow 1 */ + uint8_t RXSTP:1; /*!< bit: 4 Received Setup */ + uint8_t STALL0:1; /*!< bit: 5 Stall 0 In/out */ + uint8_t STALL1:1; /*!< bit: 6 Stall 1 In/out */ + uint8_t :1; /*!< bit: 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t TRCPT:2; /*!< bit: 0.. 1 Transfer Complete x */ + uint8_t TRFAIL:2; /*!< bit: 2.. 3 Error Flow x */ + uint8_t :1; /*!< bit: 4 Reserved */ + uint8_t STALL:2; /*!< bit: 5.. 6 Stall x In/out */ + uint8_t :1; /*!< bit: 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_EPINTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_EPINTFLAG_OFFSET 0x107 /**< \brief (USB_DEVICE_EPINTFLAG offset) DEVICE_ENDPOINT End Point Interrupt Flag */ +#define USB_DEVICE_EPINTFLAG_RESETVALUE 0x00 /**< \brief (USB_DEVICE_EPINTFLAG reset_value) DEVICE_ENDPOINT End Point Interrupt Flag */ + +#define USB_DEVICE_EPINTFLAG_TRCPT0_Pos 0 /**< \brief (USB_DEVICE_EPINTFLAG) Transfer Complete 0 */ +#define USB_DEVICE_EPINTFLAG_TRCPT0 (1 << USB_DEVICE_EPINTFLAG_TRCPT0_Pos) +#define USB_DEVICE_EPINTFLAG_TRCPT1_Pos 1 /**< \brief (USB_DEVICE_EPINTFLAG) Transfer Complete 1 */ +#define USB_DEVICE_EPINTFLAG_TRCPT1 (1 << USB_DEVICE_EPINTFLAG_TRCPT1_Pos) +#define USB_DEVICE_EPINTFLAG_TRCPT_Pos 0 /**< \brief (USB_DEVICE_EPINTFLAG) Transfer Complete x */ +#define USB_DEVICE_EPINTFLAG_TRCPT_Msk (0x3u << USB_DEVICE_EPINTFLAG_TRCPT_Pos) +#define USB_DEVICE_EPINTFLAG_TRCPT(value) ((USB_DEVICE_EPINTFLAG_TRCPT_Msk & ((value) << USB_DEVICE_EPINTFLAG_TRCPT_Pos))) +#define USB_DEVICE_EPINTFLAG_TRFAIL0_Pos 2 /**< \brief (USB_DEVICE_EPINTFLAG) Error Flow 0 */ +#define USB_DEVICE_EPINTFLAG_TRFAIL0 (1 << USB_DEVICE_EPINTFLAG_TRFAIL0_Pos) +#define USB_DEVICE_EPINTFLAG_TRFAIL1_Pos 3 /**< \brief (USB_DEVICE_EPINTFLAG) Error Flow 1 */ +#define USB_DEVICE_EPINTFLAG_TRFAIL1 (1 << USB_DEVICE_EPINTFLAG_TRFAIL1_Pos) +#define USB_DEVICE_EPINTFLAG_TRFAIL_Pos 2 /**< \brief (USB_DEVICE_EPINTFLAG) Error Flow x */ +#define USB_DEVICE_EPINTFLAG_TRFAIL_Msk (0x3u << USB_DEVICE_EPINTFLAG_TRFAIL_Pos) +#define USB_DEVICE_EPINTFLAG_TRFAIL(value) ((USB_DEVICE_EPINTFLAG_TRFAIL_Msk & ((value) << USB_DEVICE_EPINTFLAG_TRFAIL_Pos))) +#define USB_DEVICE_EPINTFLAG_RXSTP_Pos 4 /**< \brief (USB_DEVICE_EPINTFLAG) Received Setup */ +#define USB_DEVICE_EPINTFLAG_RXSTP (0x1u << USB_DEVICE_EPINTFLAG_RXSTP_Pos) +#define USB_DEVICE_EPINTFLAG_STALL0_Pos 5 /**< \brief (USB_DEVICE_EPINTFLAG) Stall 0 In/out */ +#define USB_DEVICE_EPINTFLAG_STALL0 (1 << USB_DEVICE_EPINTFLAG_STALL0_Pos) +#define USB_DEVICE_EPINTFLAG_STALL1_Pos 6 /**< \brief (USB_DEVICE_EPINTFLAG) Stall 1 In/out */ +#define USB_DEVICE_EPINTFLAG_STALL1 (1 << USB_DEVICE_EPINTFLAG_STALL1_Pos) +#define USB_DEVICE_EPINTFLAG_STALL_Pos 5 /**< \brief (USB_DEVICE_EPINTFLAG) Stall x In/out */ +#define USB_DEVICE_EPINTFLAG_STALL_Msk (0x3u << USB_DEVICE_EPINTFLAG_STALL_Pos) +#define USB_DEVICE_EPINTFLAG_STALL(value) ((USB_DEVICE_EPINTFLAG_STALL_Msk & ((value) << USB_DEVICE_EPINTFLAG_STALL_Pos))) +#define USB_DEVICE_EPINTFLAG_MASK 0x7Fu /**< \brief (USB_DEVICE_EPINTFLAG) MASK Register */ + +/* -------- USB_HOST_PINTFLAG : (USB Offset: 0x107) (R/W 8) HOST HOST_PIPE Pipe Interrupt Flag -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t TRCPT0:1; /*!< bit: 0 Transfer Complete 0 Interrupt Flag */ + uint8_t TRCPT1:1; /*!< bit: 1 Transfer Complete 1 Interrupt Flag */ + uint8_t TRFAIL:1; /*!< bit: 2 Error Flow Interrupt Flag */ + uint8_t PERR:1; /*!< bit: 3 Pipe Error Interrupt Flag */ + uint8_t TXSTP:1; /*!< bit: 4 Transmit Setup Interrupt Flag */ + uint8_t STALL:1; /*!< bit: 5 Stall Interrupt Flag */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t TRCPT:2; /*!< bit: 0.. 1 Transfer Complete x Interrupt Flag */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_PINTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_PINTFLAG_OFFSET 0x107 /**< \brief (USB_HOST_PINTFLAG offset) HOST_PIPE Pipe Interrupt Flag */ +#define USB_HOST_PINTFLAG_RESETVALUE 0x00 /**< \brief (USB_HOST_PINTFLAG reset_value) HOST_PIPE Pipe Interrupt Flag */ + +#define USB_HOST_PINTFLAG_TRCPT0_Pos 0 /**< \brief (USB_HOST_PINTFLAG) Transfer Complete 0 Interrupt Flag */ +#define USB_HOST_PINTFLAG_TRCPT0 (1 << USB_HOST_PINTFLAG_TRCPT0_Pos) +#define USB_HOST_PINTFLAG_TRCPT1_Pos 1 /**< \brief (USB_HOST_PINTFLAG) Transfer Complete 1 Interrupt Flag */ +#define USB_HOST_PINTFLAG_TRCPT1 (1 << USB_HOST_PINTFLAG_TRCPT1_Pos) +#define USB_HOST_PINTFLAG_TRCPT_Pos 0 /**< \brief (USB_HOST_PINTFLAG) Transfer Complete x Interrupt Flag */ +#define USB_HOST_PINTFLAG_TRCPT_Msk (0x3u << USB_HOST_PINTFLAG_TRCPT_Pos) +#define USB_HOST_PINTFLAG_TRCPT(value) ((USB_HOST_PINTFLAG_TRCPT_Msk & ((value) << USB_HOST_PINTFLAG_TRCPT_Pos))) +#define USB_HOST_PINTFLAG_TRFAIL_Pos 2 /**< \brief (USB_HOST_PINTFLAG) Error Flow Interrupt Flag */ +#define USB_HOST_PINTFLAG_TRFAIL (0x1u << USB_HOST_PINTFLAG_TRFAIL_Pos) +#define USB_HOST_PINTFLAG_PERR_Pos 3 /**< \brief (USB_HOST_PINTFLAG) Pipe Error Interrupt Flag */ +#define USB_HOST_PINTFLAG_PERR (0x1u << USB_HOST_PINTFLAG_PERR_Pos) +#define USB_HOST_PINTFLAG_TXSTP_Pos 4 /**< \brief (USB_HOST_PINTFLAG) Transmit Setup Interrupt Flag */ +#define USB_HOST_PINTFLAG_TXSTP (0x1u << USB_HOST_PINTFLAG_TXSTP_Pos) +#define USB_HOST_PINTFLAG_STALL_Pos 5 /**< \brief (USB_HOST_PINTFLAG) Stall Interrupt Flag */ +#define USB_HOST_PINTFLAG_STALL (0x1u << USB_HOST_PINTFLAG_STALL_Pos) +#define USB_HOST_PINTFLAG_MASK 0x3Fu /**< \brief (USB_HOST_PINTFLAG) MASK Register */ + +/* -------- USB_DEVICE_EPINTENCLR : (USB Offset: 0x108) (R/W 8) DEVICE DEVICE_ENDPOINT End Point Interrupt Clear Flag -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t TRCPT0:1; /*!< bit: 0 Transfer Complete 0 Interrupt Disable */ + uint8_t TRCPT1:1; /*!< bit: 1 Transfer Complete 1 Interrupt Disable */ + uint8_t TRFAIL0:1; /*!< bit: 2 Error Flow 0 Interrupt Disable */ + uint8_t TRFAIL1:1; /*!< bit: 3 Error Flow 1 Interrupt Disable */ + uint8_t RXSTP:1; /*!< bit: 4 Received Setup Interrupt Disable */ + uint8_t STALL0:1; /*!< bit: 5 Stall 0 In/Out Interrupt Disable */ + uint8_t STALL1:1; /*!< bit: 6 Stall 1 In/Out Interrupt Disable */ + uint8_t :1; /*!< bit: 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t TRCPT:2; /*!< bit: 0.. 1 Transfer Complete x Interrupt Disable */ + uint8_t TRFAIL:2; /*!< bit: 2.. 3 Error Flow x Interrupt Disable */ + uint8_t :1; /*!< bit: 4 Reserved */ + uint8_t STALL:2; /*!< bit: 5.. 6 Stall x In/Out Interrupt Disable */ + uint8_t :1; /*!< bit: 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_EPINTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_EPINTENCLR_OFFSET 0x108 /**< \brief (USB_DEVICE_EPINTENCLR offset) DEVICE_ENDPOINT End Point Interrupt Clear Flag */ +#define USB_DEVICE_EPINTENCLR_RESETVALUE 0x00 /**< \brief (USB_DEVICE_EPINTENCLR reset_value) DEVICE_ENDPOINT End Point Interrupt Clear Flag */ + +#define USB_DEVICE_EPINTENCLR_TRCPT0_Pos 0 /**< \brief (USB_DEVICE_EPINTENCLR) Transfer Complete 0 Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_TRCPT0 (1 << USB_DEVICE_EPINTENCLR_TRCPT0_Pos) +#define USB_DEVICE_EPINTENCLR_TRCPT1_Pos 1 /**< \brief (USB_DEVICE_EPINTENCLR) Transfer Complete 1 Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_TRCPT1 (1 << USB_DEVICE_EPINTENCLR_TRCPT1_Pos) +#define USB_DEVICE_EPINTENCLR_TRCPT_Pos 0 /**< \brief (USB_DEVICE_EPINTENCLR) Transfer Complete x Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_TRCPT_Msk (0x3u << USB_DEVICE_EPINTENCLR_TRCPT_Pos) +#define USB_DEVICE_EPINTENCLR_TRCPT(value) ((USB_DEVICE_EPINTENCLR_TRCPT_Msk & ((value) << USB_DEVICE_EPINTENCLR_TRCPT_Pos))) +#define USB_DEVICE_EPINTENCLR_TRFAIL0_Pos 2 /**< \brief (USB_DEVICE_EPINTENCLR) Error Flow 0 Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_TRFAIL0 (1 << USB_DEVICE_EPINTENCLR_TRFAIL0_Pos) +#define USB_DEVICE_EPINTENCLR_TRFAIL1_Pos 3 /**< \brief (USB_DEVICE_EPINTENCLR) Error Flow 1 Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_TRFAIL1 (1 << USB_DEVICE_EPINTENCLR_TRFAIL1_Pos) +#define USB_DEVICE_EPINTENCLR_TRFAIL_Pos 2 /**< \brief (USB_DEVICE_EPINTENCLR) Error Flow x Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_TRFAIL_Msk (0x3u << USB_DEVICE_EPINTENCLR_TRFAIL_Pos) +#define USB_DEVICE_EPINTENCLR_TRFAIL(value) ((USB_DEVICE_EPINTENCLR_TRFAIL_Msk & ((value) << USB_DEVICE_EPINTENCLR_TRFAIL_Pos))) +#define USB_DEVICE_EPINTENCLR_RXSTP_Pos 4 /**< \brief (USB_DEVICE_EPINTENCLR) Received Setup Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_RXSTP (0x1u << USB_DEVICE_EPINTENCLR_RXSTP_Pos) +#define USB_DEVICE_EPINTENCLR_STALL0_Pos 5 /**< \brief (USB_DEVICE_EPINTENCLR) Stall 0 In/Out Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_STALL0 (1 << USB_DEVICE_EPINTENCLR_STALL0_Pos) +#define USB_DEVICE_EPINTENCLR_STALL1_Pos 6 /**< \brief (USB_DEVICE_EPINTENCLR) Stall 1 In/Out Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_STALL1 (1 << USB_DEVICE_EPINTENCLR_STALL1_Pos) +#define USB_DEVICE_EPINTENCLR_STALL_Pos 5 /**< \brief (USB_DEVICE_EPINTENCLR) Stall x In/Out Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_STALL_Msk (0x3u << USB_DEVICE_EPINTENCLR_STALL_Pos) +#define USB_DEVICE_EPINTENCLR_STALL(value) ((USB_DEVICE_EPINTENCLR_STALL_Msk & ((value) << USB_DEVICE_EPINTENCLR_STALL_Pos))) +#define USB_DEVICE_EPINTENCLR_MASK 0x7Fu /**< \brief (USB_DEVICE_EPINTENCLR) MASK Register */ + +/* -------- USB_HOST_PINTENCLR : (USB Offset: 0x108) (R/W 8) HOST HOST_PIPE Pipe Interrupt Flag Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t TRCPT0:1; /*!< bit: 0 Transfer Complete 0 Disable */ + uint8_t TRCPT1:1; /*!< bit: 1 Transfer Complete 1 Disable */ + uint8_t TRFAIL:1; /*!< bit: 2 Error Flow Interrupt Disable */ + uint8_t PERR:1; /*!< bit: 3 Pipe Error Interrupt Disable */ + uint8_t TXSTP:1; /*!< bit: 4 Transmit Setup Interrupt Disable */ + uint8_t STALL:1; /*!< bit: 5 Stall Inetrrupt Disable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t TRCPT:2; /*!< bit: 0.. 1 Transfer Complete x Disable */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_PINTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_PINTENCLR_OFFSET 0x108 /**< \brief (USB_HOST_PINTENCLR offset) HOST_PIPE Pipe Interrupt Flag Clear */ +#define USB_HOST_PINTENCLR_RESETVALUE 0x00 /**< \brief (USB_HOST_PINTENCLR reset_value) HOST_PIPE Pipe Interrupt Flag Clear */ + +#define USB_HOST_PINTENCLR_TRCPT0_Pos 0 /**< \brief (USB_HOST_PINTENCLR) Transfer Complete 0 Disable */ +#define USB_HOST_PINTENCLR_TRCPT0 (1 << USB_HOST_PINTENCLR_TRCPT0_Pos) +#define USB_HOST_PINTENCLR_TRCPT1_Pos 1 /**< \brief (USB_HOST_PINTENCLR) Transfer Complete 1 Disable */ +#define USB_HOST_PINTENCLR_TRCPT1 (1 << USB_HOST_PINTENCLR_TRCPT1_Pos) +#define USB_HOST_PINTENCLR_TRCPT_Pos 0 /**< \brief (USB_HOST_PINTENCLR) Transfer Complete x Disable */ +#define USB_HOST_PINTENCLR_TRCPT_Msk (0x3u << USB_HOST_PINTENCLR_TRCPT_Pos) +#define USB_HOST_PINTENCLR_TRCPT(value) ((USB_HOST_PINTENCLR_TRCPT_Msk & ((value) << USB_HOST_PINTENCLR_TRCPT_Pos))) +#define USB_HOST_PINTENCLR_TRFAIL_Pos 2 /**< \brief (USB_HOST_PINTENCLR) Error Flow Interrupt Disable */ +#define USB_HOST_PINTENCLR_TRFAIL (0x1u << USB_HOST_PINTENCLR_TRFAIL_Pos) +#define USB_HOST_PINTENCLR_PERR_Pos 3 /**< \brief (USB_HOST_PINTENCLR) Pipe Error Interrupt Disable */ +#define USB_HOST_PINTENCLR_PERR (0x1u << USB_HOST_PINTENCLR_PERR_Pos) +#define USB_HOST_PINTENCLR_TXSTP_Pos 4 /**< \brief (USB_HOST_PINTENCLR) Transmit Setup Interrupt Disable */ +#define USB_HOST_PINTENCLR_TXSTP (0x1u << USB_HOST_PINTENCLR_TXSTP_Pos) +#define USB_HOST_PINTENCLR_STALL_Pos 5 /**< \brief (USB_HOST_PINTENCLR) Stall Inetrrupt Disable */ +#define USB_HOST_PINTENCLR_STALL (0x1u << USB_HOST_PINTENCLR_STALL_Pos) +#define USB_HOST_PINTENCLR_MASK 0x3Fu /**< \brief (USB_HOST_PINTENCLR) MASK Register */ + +/* -------- USB_DEVICE_EPINTENSET : (USB Offset: 0x109) (R/W 8) DEVICE DEVICE_ENDPOINT End Point Interrupt Set Flag -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t TRCPT0:1; /*!< bit: 0 Transfer Complete 0 Interrupt Enable */ + uint8_t TRCPT1:1; /*!< bit: 1 Transfer Complete 1 Interrupt Enable */ + uint8_t TRFAIL0:1; /*!< bit: 2 Error Flow 0 Interrupt Enable */ + uint8_t TRFAIL1:1; /*!< bit: 3 Error Flow 1 Interrupt Enable */ + uint8_t RXSTP:1; /*!< bit: 4 Received Setup Interrupt Enable */ + uint8_t STALL0:1; /*!< bit: 5 Stall 0 In/out Interrupt enable */ + uint8_t STALL1:1; /*!< bit: 6 Stall 1 In/out Interrupt enable */ + uint8_t :1; /*!< bit: 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t TRCPT:2; /*!< bit: 0.. 1 Transfer Complete x Interrupt Enable */ + uint8_t TRFAIL:2; /*!< bit: 2.. 3 Error Flow x Interrupt Enable */ + uint8_t :1; /*!< bit: 4 Reserved */ + uint8_t STALL:2; /*!< bit: 5.. 6 Stall x In/out Interrupt enable */ + uint8_t :1; /*!< bit: 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_EPINTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_EPINTENSET_OFFSET 0x109 /**< \brief (USB_DEVICE_EPINTENSET offset) DEVICE_ENDPOINT End Point Interrupt Set Flag */ +#define USB_DEVICE_EPINTENSET_RESETVALUE 0x00 /**< \brief (USB_DEVICE_EPINTENSET reset_value) DEVICE_ENDPOINT End Point Interrupt Set Flag */ + +#define USB_DEVICE_EPINTENSET_TRCPT0_Pos 0 /**< \brief (USB_DEVICE_EPINTENSET) Transfer Complete 0 Interrupt Enable */ +#define USB_DEVICE_EPINTENSET_TRCPT0 (1 << USB_DEVICE_EPINTENSET_TRCPT0_Pos) +#define USB_DEVICE_EPINTENSET_TRCPT1_Pos 1 /**< \brief (USB_DEVICE_EPINTENSET) Transfer Complete 1 Interrupt Enable */ +#define USB_DEVICE_EPINTENSET_TRCPT1 (1 << USB_DEVICE_EPINTENSET_TRCPT1_Pos) +#define USB_DEVICE_EPINTENSET_TRCPT_Pos 0 /**< \brief (USB_DEVICE_EPINTENSET) Transfer Complete x Interrupt Enable */ +#define USB_DEVICE_EPINTENSET_TRCPT_Msk (0x3u << USB_DEVICE_EPINTENSET_TRCPT_Pos) +#define USB_DEVICE_EPINTENSET_TRCPT(value) ((USB_DEVICE_EPINTENSET_TRCPT_Msk & ((value) << USB_DEVICE_EPINTENSET_TRCPT_Pos))) +#define USB_DEVICE_EPINTENSET_TRFAIL0_Pos 2 /**< \brief (USB_DEVICE_EPINTENSET) Error Flow 0 Interrupt Enable */ +#define USB_DEVICE_EPINTENSET_TRFAIL0 (1 << USB_DEVICE_EPINTENSET_TRFAIL0_Pos) +#define USB_DEVICE_EPINTENSET_TRFAIL1_Pos 3 /**< \brief (USB_DEVICE_EPINTENSET) Error Flow 1 Interrupt Enable */ +#define USB_DEVICE_EPINTENSET_TRFAIL1 (1 << USB_DEVICE_EPINTENSET_TRFAIL1_Pos) +#define USB_DEVICE_EPINTENSET_TRFAIL_Pos 2 /**< \brief (USB_DEVICE_EPINTENSET) Error Flow x Interrupt Enable */ +#define USB_DEVICE_EPINTENSET_TRFAIL_Msk (0x3u << USB_DEVICE_EPINTENSET_TRFAIL_Pos) +#define USB_DEVICE_EPINTENSET_TRFAIL(value) ((USB_DEVICE_EPINTENSET_TRFAIL_Msk & ((value) << USB_DEVICE_EPINTENSET_TRFAIL_Pos))) +#define USB_DEVICE_EPINTENSET_RXSTP_Pos 4 /**< \brief (USB_DEVICE_EPINTENSET) Received Setup Interrupt Enable */ +#define USB_DEVICE_EPINTENSET_RXSTP (0x1u << USB_DEVICE_EPINTENSET_RXSTP_Pos) +#define USB_DEVICE_EPINTENSET_STALL0_Pos 5 /**< \brief (USB_DEVICE_EPINTENSET) Stall 0 In/out Interrupt enable */ +#define USB_DEVICE_EPINTENSET_STALL0 (1 << USB_DEVICE_EPINTENSET_STALL0_Pos) +#define USB_DEVICE_EPINTENSET_STALL1_Pos 6 /**< \brief (USB_DEVICE_EPINTENSET) Stall 1 In/out Interrupt enable */ +#define USB_DEVICE_EPINTENSET_STALL1 (1 << USB_DEVICE_EPINTENSET_STALL1_Pos) +#define USB_DEVICE_EPINTENSET_STALL_Pos 5 /**< \brief (USB_DEVICE_EPINTENSET) Stall x In/out Interrupt enable */ +#define USB_DEVICE_EPINTENSET_STALL_Msk (0x3u << USB_DEVICE_EPINTENSET_STALL_Pos) +#define USB_DEVICE_EPINTENSET_STALL(value) ((USB_DEVICE_EPINTENSET_STALL_Msk & ((value) << USB_DEVICE_EPINTENSET_STALL_Pos))) +#define USB_DEVICE_EPINTENSET_MASK 0x7Fu /**< \brief (USB_DEVICE_EPINTENSET) MASK Register */ + +/* -------- USB_HOST_PINTENSET : (USB Offset: 0x109) (R/W 8) HOST HOST_PIPE Pipe Interrupt Flag Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t TRCPT0:1; /*!< bit: 0 Transfer Complete 0 Interrupt Enable */ + uint8_t TRCPT1:1; /*!< bit: 1 Transfer Complete 1 Interrupt Enable */ + uint8_t TRFAIL:1; /*!< bit: 2 Error Flow Interrupt Enable */ + uint8_t PERR:1; /*!< bit: 3 Pipe Error Interrupt Enable */ + uint8_t TXSTP:1; /*!< bit: 4 Transmit Setup Interrupt Enable */ + uint8_t STALL:1; /*!< bit: 5 Stall Interrupt Enable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t TRCPT:2; /*!< bit: 0.. 1 Transfer Complete x Interrupt Enable */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_PINTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_PINTENSET_OFFSET 0x109 /**< \brief (USB_HOST_PINTENSET offset) HOST_PIPE Pipe Interrupt Flag Set */ +#define USB_HOST_PINTENSET_RESETVALUE 0x00 /**< \brief (USB_HOST_PINTENSET reset_value) HOST_PIPE Pipe Interrupt Flag Set */ + +#define USB_HOST_PINTENSET_TRCPT0_Pos 0 /**< \brief (USB_HOST_PINTENSET) Transfer Complete 0 Interrupt Enable */ +#define USB_HOST_PINTENSET_TRCPT0 (1 << USB_HOST_PINTENSET_TRCPT0_Pos) +#define USB_HOST_PINTENSET_TRCPT1_Pos 1 /**< \brief (USB_HOST_PINTENSET) Transfer Complete 1 Interrupt Enable */ +#define USB_HOST_PINTENSET_TRCPT1 (1 << USB_HOST_PINTENSET_TRCPT1_Pos) +#define USB_HOST_PINTENSET_TRCPT_Pos 0 /**< \brief (USB_HOST_PINTENSET) Transfer Complete x Interrupt Enable */ +#define USB_HOST_PINTENSET_TRCPT_Msk (0x3u << USB_HOST_PINTENSET_TRCPT_Pos) +#define USB_HOST_PINTENSET_TRCPT(value) ((USB_HOST_PINTENSET_TRCPT_Msk & ((value) << USB_HOST_PINTENSET_TRCPT_Pos))) +#define USB_HOST_PINTENSET_TRFAIL_Pos 2 /**< \brief (USB_HOST_PINTENSET) Error Flow Interrupt Enable */ +#define USB_HOST_PINTENSET_TRFAIL (0x1u << USB_HOST_PINTENSET_TRFAIL_Pos) +#define USB_HOST_PINTENSET_PERR_Pos 3 /**< \brief (USB_HOST_PINTENSET) Pipe Error Interrupt Enable */ +#define USB_HOST_PINTENSET_PERR (0x1u << USB_HOST_PINTENSET_PERR_Pos) +#define USB_HOST_PINTENSET_TXSTP_Pos 4 /**< \brief (USB_HOST_PINTENSET) Transmit Setup Interrupt Enable */ +#define USB_HOST_PINTENSET_TXSTP (0x1u << USB_HOST_PINTENSET_TXSTP_Pos) +#define USB_HOST_PINTENSET_STALL_Pos 5 /**< \brief (USB_HOST_PINTENSET) Stall Interrupt Enable */ +#define USB_HOST_PINTENSET_STALL (0x1u << USB_HOST_PINTENSET_STALL_Pos) +#define USB_HOST_PINTENSET_MASK 0x3Fu /**< \brief (USB_HOST_PINTENSET) MASK Register */ + +/* -------- USB_DEVICE_ADDR : (USB Offset: 0x000) (R/W 32) DEVICE DEVICE_DESC_BANK Endpoint Bank, Adress of Data Buffer -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t ADDR:32; /*!< bit: 0..31 Adress of data buffer */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} USB_DEVICE_ADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_ADDR_OFFSET 0x000 /**< \brief (USB_DEVICE_ADDR offset) DEVICE_DESC_BANK Endpoint Bank, Adress of Data Buffer */ + +#define USB_DEVICE_ADDR_ADDR_Pos 0 /**< \brief (USB_DEVICE_ADDR) Adress of data buffer */ +#define USB_DEVICE_ADDR_ADDR_Msk (0xFFFFFFFFu << USB_DEVICE_ADDR_ADDR_Pos) +#define USB_DEVICE_ADDR_ADDR(value) ((USB_DEVICE_ADDR_ADDR_Msk & ((value) << USB_DEVICE_ADDR_ADDR_Pos))) +#define USB_DEVICE_ADDR_MASK 0xFFFFFFFFu /**< \brief (USB_DEVICE_ADDR) MASK Register */ + +/* -------- USB_HOST_ADDR : (USB Offset: 0x000) (R/W 32) HOST HOST_DESC_BANK Host Bank, Adress of Data Buffer -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t ADDR:32; /*!< bit: 0..31 Adress of data buffer */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} USB_HOST_ADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_ADDR_OFFSET 0x000 /**< \brief (USB_HOST_ADDR offset) HOST_DESC_BANK Host Bank, Adress of Data Buffer */ + +#define USB_HOST_ADDR_ADDR_Pos 0 /**< \brief (USB_HOST_ADDR) Adress of data buffer */ +#define USB_HOST_ADDR_ADDR_Msk (0xFFFFFFFFu << USB_HOST_ADDR_ADDR_Pos) +#define USB_HOST_ADDR_ADDR(value) ((USB_HOST_ADDR_ADDR_Msk & ((value) << USB_HOST_ADDR_ADDR_Pos))) +#define USB_HOST_ADDR_MASK 0xFFFFFFFFu /**< \brief (USB_HOST_ADDR) MASK Register */ + +/* -------- USB_DEVICE_PCKSIZE : (USB Offset: 0x004) (R/W 32) DEVICE DEVICE_DESC_BANK Endpoint Bank, Packet Size -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t BYTE_COUNT:14; /*!< bit: 0..13 Byte Count */ + uint32_t MULTI_PACKET_SIZE:14; /*!< bit: 14..27 Multi Packet In or Out size */ + uint32_t SIZE:3; /*!< bit: 28..30 Enpoint size */ + uint32_t AUTO_ZLP:1; /*!< bit: 31 Automatic Zero Length Packet */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} USB_DEVICE_PCKSIZE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_PCKSIZE_OFFSET 0x004 /**< \brief (USB_DEVICE_PCKSIZE offset) DEVICE_DESC_BANK Endpoint Bank, Packet Size */ + +#define USB_DEVICE_PCKSIZE_BYTE_COUNT_Pos 0 /**< \brief (USB_DEVICE_PCKSIZE) Byte Count */ +#define USB_DEVICE_PCKSIZE_BYTE_COUNT_Msk (0x3FFFu << USB_DEVICE_PCKSIZE_BYTE_COUNT_Pos) +#define USB_DEVICE_PCKSIZE_BYTE_COUNT(value) ((USB_DEVICE_PCKSIZE_BYTE_COUNT_Msk & ((value) << USB_DEVICE_PCKSIZE_BYTE_COUNT_Pos))) +#define USB_DEVICE_PCKSIZE_MULTI_PACKET_SIZE_Pos 14 /**< \brief (USB_DEVICE_PCKSIZE) Multi Packet In or Out size */ +#define USB_DEVICE_PCKSIZE_MULTI_PACKET_SIZE_Msk (0x3FFFu << USB_DEVICE_PCKSIZE_MULTI_PACKET_SIZE_Pos) +#define USB_DEVICE_PCKSIZE_MULTI_PACKET_SIZE(value) ((USB_DEVICE_PCKSIZE_MULTI_PACKET_SIZE_Msk & ((value) << USB_DEVICE_PCKSIZE_MULTI_PACKET_SIZE_Pos))) +#define USB_DEVICE_PCKSIZE_SIZE_Pos 28 /**< \brief (USB_DEVICE_PCKSIZE) Enpoint size */ +#define USB_DEVICE_PCKSIZE_SIZE_Msk (0x7u << USB_DEVICE_PCKSIZE_SIZE_Pos) +#define USB_DEVICE_PCKSIZE_SIZE(value) ((USB_DEVICE_PCKSIZE_SIZE_Msk & ((value) << USB_DEVICE_PCKSIZE_SIZE_Pos))) +#define USB_DEVICE_PCKSIZE_AUTO_ZLP_Pos 31 /**< \brief (USB_DEVICE_PCKSIZE) Automatic Zero Length Packet */ +#define USB_DEVICE_PCKSIZE_AUTO_ZLP (0x1u << USB_DEVICE_PCKSIZE_AUTO_ZLP_Pos) +#define USB_DEVICE_PCKSIZE_MASK 0xFFFFFFFFu /**< \brief (USB_DEVICE_PCKSIZE) MASK Register */ + +/* -------- USB_HOST_PCKSIZE : (USB Offset: 0x004) (R/W 32) HOST HOST_DESC_BANK Host Bank, Packet Size -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t BYTE_COUNT:14; /*!< bit: 0..13 Byte Count */ + uint32_t MULTI_PACKET_SIZE:14; /*!< bit: 14..27 Multi Packet In or Out size */ + uint32_t SIZE:3; /*!< bit: 28..30 Pipe size */ + uint32_t AUTO_ZLP:1; /*!< bit: 31 Automatic Zero Length Packet */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} USB_HOST_PCKSIZE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_PCKSIZE_OFFSET 0x004 /**< \brief (USB_HOST_PCKSIZE offset) HOST_DESC_BANK Host Bank, Packet Size */ + +#define USB_HOST_PCKSIZE_BYTE_COUNT_Pos 0 /**< \brief (USB_HOST_PCKSIZE) Byte Count */ +#define USB_HOST_PCKSIZE_BYTE_COUNT_Msk (0x3FFFu << USB_HOST_PCKSIZE_BYTE_COUNT_Pos) +#define USB_HOST_PCKSIZE_BYTE_COUNT(value) ((USB_HOST_PCKSIZE_BYTE_COUNT_Msk & ((value) << USB_HOST_PCKSIZE_BYTE_COUNT_Pos))) +#define USB_HOST_PCKSIZE_MULTI_PACKET_SIZE_Pos 14 /**< \brief (USB_HOST_PCKSIZE) Multi Packet In or Out size */ +#define USB_HOST_PCKSIZE_MULTI_PACKET_SIZE_Msk (0x3FFFu << USB_HOST_PCKSIZE_MULTI_PACKET_SIZE_Pos) +#define USB_HOST_PCKSIZE_MULTI_PACKET_SIZE(value) ((USB_HOST_PCKSIZE_MULTI_PACKET_SIZE_Msk & ((value) << USB_HOST_PCKSIZE_MULTI_PACKET_SIZE_Pos))) +#define USB_HOST_PCKSIZE_SIZE_Pos 28 /**< \brief (USB_HOST_PCKSIZE) Pipe size */ +#define USB_HOST_PCKSIZE_SIZE_Msk (0x7u << USB_HOST_PCKSIZE_SIZE_Pos) +#define USB_HOST_PCKSIZE_SIZE(value) ((USB_HOST_PCKSIZE_SIZE_Msk & ((value) << USB_HOST_PCKSIZE_SIZE_Pos))) +#define USB_HOST_PCKSIZE_AUTO_ZLP_Pos 31 /**< \brief (USB_HOST_PCKSIZE) Automatic Zero Length Packet */ +#define USB_HOST_PCKSIZE_AUTO_ZLP (0x1u << USB_HOST_PCKSIZE_AUTO_ZLP_Pos) +#define USB_HOST_PCKSIZE_MASK 0xFFFFFFFFu /**< \brief (USB_HOST_PCKSIZE) MASK Register */ + +/* -------- USB_DEVICE_EXTREG : (USB Offset: 0x008) (R/W 16) DEVICE DEVICE_DESC_BANK Endpoint Bank, Extended -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SUBPID:4; /*!< bit: 0.. 3 SUBPID field send with extended token */ + uint16_t VARIABLE:11; /*!< bit: 4..14 Variable field send with extended token */ + uint16_t :1; /*!< bit: 15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_DEVICE_EXTREG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_EXTREG_OFFSET 0x008 /**< \brief (USB_DEVICE_EXTREG offset) DEVICE_DESC_BANK Endpoint Bank, Extended */ + +#define USB_DEVICE_EXTREG_SUBPID_Pos 0 /**< \brief (USB_DEVICE_EXTREG) SUBPID field send with extended token */ +#define USB_DEVICE_EXTREG_SUBPID_Msk (0xFu << USB_DEVICE_EXTREG_SUBPID_Pos) +#define USB_DEVICE_EXTREG_SUBPID(value) ((USB_DEVICE_EXTREG_SUBPID_Msk & ((value) << USB_DEVICE_EXTREG_SUBPID_Pos))) +#define USB_DEVICE_EXTREG_VARIABLE_Pos 4 /**< \brief (USB_DEVICE_EXTREG) Variable field send with extended token */ +#define USB_DEVICE_EXTREG_VARIABLE_Msk (0x7FFu << USB_DEVICE_EXTREG_VARIABLE_Pos) +#define USB_DEVICE_EXTREG_VARIABLE(value) ((USB_DEVICE_EXTREG_VARIABLE_Msk & ((value) << USB_DEVICE_EXTREG_VARIABLE_Pos))) +#define USB_DEVICE_EXTREG_MASK 0x7FFFu /**< \brief (USB_DEVICE_EXTREG) MASK Register */ + +/* -------- USB_HOST_EXTREG : (USB Offset: 0x008) (R/W 16) HOST HOST_DESC_BANK Host Bank, Extended -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SUBPID:4; /*!< bit: 0.. 3 SUBPID field send with extended token */ + uint16_t VARIABLE:11; /*!< bit: 4..14 Variable field send with extended token */ + uint16_t :1; /*!< bit: 15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_HOST_EXTREG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_EXTREG_OFFSET 0x008 /**< \brief (USB_HOST_EXTREG offset) HOST_DESC_BANK Host Bank, Extended */ + +#define USB_HOST_EXTREG_SUBPID_Pos 0 /**< \brief (USB_HOST_EXTREG) SUBPID field send with extended token */ +#define USB_HOST_EXTREG_SUBPID_Msk (0xFu << USB_HOST_EXTREG_SUBPID_Pos) +#define USB_HOST_EXTREG_SUBPID(value) ((USB_HOST_EXTREG_SUBPID_Msk & ((value) << USB_HOST_EXTREG_SUBPID_Pos))) +#define USB_HOST_EXTREG_VARIABLE_Pos 4 /**< \brief (USB_HOST_EXTREG) Variable field send with extended token */ +#define USB_HOST_EXTREG_VARIABLE_Msk (0x7FFu << USB_HOST_EXTREG_VARIABLE_Pos) +#define USB_HOST_EXTREG_VARIABLE(value) ((USB_HOST_EXTREG_VARIABLE_Msk & ((value) << USB_HOST_EXTREG_VARIABLE_Pos))) +#define USB_HOST_EXTREG_MASK 0x7FFFu /**< \brief (USB_HOST_EXTREG) MASK Register */ + +/* -------- USB_DEVICE_STATUS_BK : (USB Offset: 0x00A) (R/W 8) DEVICE DEVICE_DESC_BANK Enpoint Bank, Status of Bank -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CRCERR:1; /*!< bit: 0 CRC Error Status */ + uint8_t ERRORFLOW:1; /*!< bit: 1 Error Flow Status */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_STATUS_BK_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_STATUS_BK_OFFSET 0x00A /**< \brief (USB_DEVICE_STATUS_BK offset) DEVICE_DESC_BANK Enpoint Bank, Status of Bank */ + +#define USB_DEVICE_STATUS_BK_CRCERR_Pos 0 /**< \brief (USB_DEVICE_STATUS_BK) CRC Error Status */ +#define USB_DEVICE_STATUS_BK_CRCERR (0x1u << USB_DEVICE_STATUS_BK_CRCERR_Pos) +#define USB_DEVICE_STATUS_BK_ERRORFLOW_Pos 1 /**< \brief (USB_DEVICE_STATUS_BK) Error Flow Status */ +#define USB_DEVICE_STATUS_BK_ERRORFLOW (0x1u << USB_DEVICE_STATUS_BK_ERRORFLOW_Pos) +#define USB_DEVICE_STATUS_BK_MASK 0x03u /**< \brief (USB_DEVICE_STATUS_BK) MASK Register */ + +/* -------- USB_HOST_STATUS_BK : (USB Offset: 0x00A) (R/W 8) HOST HOST_DESC_BANK Host Bank, Status of Bank -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CRCERR:1; /*!< bit: 0 CRC Error Status */ + uint8_t ERRORFLOW:1; /*!< bit: 1 Error Flow Status */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_STATUS_BK_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_STATUS_BK_OFFSET 0x00A /**< \brief (USB_HOST_STATUS_BK offset) HOST_DESC_BANK Host Bank, Status of Bank */ + +#define USB_HOST_STATUS_BK_CRCERR_Pos 0 /**< \brief (USB_HOST_STATUS_BK) CRC Error Status */ +#define USB_HOST_STATUS_BK_CRCERR (0x1u << USB_HOST_STATUS_BK_CRCERR_Pos) +#define USB_HOST_STATUS_BK_ERRORFLOW_Pos 1 /**< \brief (USB_HOST_STATUS_BK) Error Flow Status */ +#define USB_HOST_STATUS_BK_ERRORFLOW (0x1u << USB_HOST_STATUS_BK_ERRORFLOW_Pos) +#define USB_HOST_STATUS_BK_MASK 0x03u /**< \brief (USB_HOST_STATUS_BK) MASK Register */ + +/* -------- USB_HOST_CTRL_PIPE : (USB Offset: 0x00C) (R/W 16) HOST HOST_DESC_BANK Host Bank, Host Control Pipe -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t PDADDR:7; /*!< bit: 0.. 6 Pipe Device Adress */ + uint16_t :1; /*!< bit: 7 Reserved */ + uint16_t PEPNUM:4; /*!< bit: 8..11 Pipe Endpoint Number */ + uint16_t PERMAX:4; /*!< bit: 12..15 Pipe Error Max Number */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_HOST_CTRL_PIPE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_CTRL_PIPE_OFFSET 0x00C /**< \brief (USB_HOST_CTRL_PIPE offset) HOST_DESC_BANK Host Bank, Host Control Pipe */ +#define USB_HOST_CTRL_PIPE_RESETVALUE 0x0000 /**< \brief (USB_HOST_CTRL_PIPE reset_value) HOST_DESC_BANK Host Bank, Host Control Pipe */ + +#define USB_HOST_CTRL_PIPE_PDADDR_Pos 0 /**< \brief (USB_HOST_CTRL_PIPE) Pipe Device Adress */ +#define USB_HOST_CTRL_PIPE_PDADDR_Msk (0x7Fu << USB_HOST_CTRL_PIPE_PDADDR_Pos) +#define USB_HOST_CTRL_PIPE_PDADDR(value) ((USB_HOST_CTRL_PIPE_PDADDR_Msk & ((value) << USB_HOST_CTRL_PIPE_PDADDR_Pos))) +#define USB_HOST_CTRL_PIPE_PEPNUM_Pos 8 /**< \brief (USB_HOST_CTRL_PIPE) Pipe Endpoint Number */ +#define USB_HOST_CTRL_PIPE_PEPNUM_Msk (0xFu << USB_HOST_CTRL_PIPE_PEPNUM_Pos) +#define USB_HOST_CTRL_PIPE_PEPNUM(value) ((USB_HOST_CTRL_PIPE_PEPNUM_Msk & ((value) << USB_HOST_CTRL_PIPE_PEPNUM_Pos))) +#define USB_HOST_CTRL_PIPE_PERMAX_Pos 12 /**< \brief (USB_HOST_CTRL_PIPE) Pipe Error Max Number */ +#define USB_HOST_CTRL_PIPE_PERMAX_Msk (0xFu << USB_HOST_CTRL_PIPE_PERMAX_Pos) +#define USB_HOST_CTRL_PIPE_PERMAX(value) ((USB_HOST_CTRL_PIPE_PERMAX_Msk & ((value) << USB_HOST_CTRL_PIPE_PERMAX_Pos))) +#define USB_HOST_CTRL_PIPE_MASK 0xFF7Fu /**< \brief (USB_HOST_CTRL_PIPE) MASK Register */ + +/* -------- USB_HOST_STATUS_PIPE : (USB Offset: 0x00E) (R/W 16) HOST HOST_DESC_BANK Host Bank, Host Status Pipe -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t DTGLER:1; /*!< bit: 0 Data Toggle Error */ + uint16_t DAPIDER:1; /*!< bit: 1 Data PID Error */ + uint16_t PIDER:1; /*!< bit: 2 PID Error */ + uint16_t TOUTER:1; /*!< bit: 3 Time Out Error */ + uint16_t CRC16ER:1; /*!< bit: 4 CRC16 Error */ + uint16_t ERCNT:3; /*!< bit: 5.. 7 Pipe Error Count */ + uint16_t :8; /*!< bit: 8..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_HOST_STATUS_PIPE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_STATUS_PIPE_OFFSET 0x00E /**< \brief (USB_HOST_STATUS_PIPE offset) HOST_DESC_BANK Host Bank, Host Status Pipe */ + +#define USB_HOST_STATUS_PIPE_DTGLER_Pos 0 /**< \brief (USB_HOST_STATUS_PIPE) Data Toggle Error */ +#define USB_HOST_STATUS_PIPE_DTGLER (0x1u << USB_HOST_STATUS_PIPE_DTGLER_Pos) +#define USB_HOST_STATUS_PIPE_DAPIDER_Pos 1 /**< \brief (USB_HOST_STATUS_PIPE) Data PID Error */ +#define USB_HOST_STATUS_PIPE_DAPIDER (0x1u << USB_HOST_STATUS_PIPE_DAPIDER_Pos) +#define USB_HOST_STATUS_PIPE_PIDER_Pos 2 /**< \brief (USB_HOST_STATUS_PIPE) PID Error */ +#define USB_HOST_STATUS_PIPE_PIDER (0x1u << USB_HOST_STATUS_PIPE_PIDER_Pos) +#define USB_HOST_STATUS_PIPE_TOUTER_Pos 3 /**< \brief (USB_HOST_STATUS_PIPE) Time Out Error */ +#define USB_HOST_STATUS_PIPE_TOUTER (0x1u << USB_HOST_STATUS_PIPE_TOUTER_Pos) +#define USB_HOST_STATUS_PIPE_CRC16ER_Pos 4 /**< \brief (USB_HOST_STATUS_PIPE) CRC16 Error */ +#define USB_HOST_STATUS_PIPE_CRC16ER (0x1u << USB_HOST_STATUS_PIPE_CRC16ER_Pos) +#define USB_HOST_STATUS_PIPE_ERCNT_Pos 5 /**< \brief (USB_HOST_STATUS_PIPE) Pipe Error Count */ +#define USB_HOST_STATUS_PIPE_ERCNT_Msk (0x7u << USB_HOST_STATUS_PIPE_ERCNT_Pos) +#define USB_HOST_STATUS_PIPE_ERCNT(value) ((USB_HOST_STATUS_PIPE_ERCNT_Msk & ((value) << USB_HOST_STATUS_PIPE_ERCNT_Pos))) +#define USB_HOST_STATUS_PIPE_MASK 0x00FFu /**< \brief (USB_HOST_STATUS_PIPE) MASK Register */ + +/** \brief UsbDeviceDescBank SRAM registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO USB_DEVICE_ADDR_Type ADDR; /**< \brief Offset: 0x000 (R/W 32) DEVICE_DESC_BANK Endpoint Bank, Adress of Data Buffer */ + __IO USB_DEVICE_PCKSIZE_Type PCKSIZE; /**< \brief Offset: 0x004 (R/W 32) DEVICE_DESC_BANK Endpoint Bank, Packet Size */ + __IO USB_DEVICE_EXTREG_Type EXTREG; /**< \brief Offset: 0x008 (R/W 16) DEVICE_DESC_BANK Endpoint Bank, Extended */ + __IO USB_DEVICE_STATUS_BK_Type STATUS_BK; /**< \brief Offset: 0x00A (R/W 8) DEVICE_DESC_BANK Enpoint Bank, Status of Bank */ + RoReg8 Reserved1[0x5]; +} UsbDeviceDescBank; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief UsbHostDescBank SRAM registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO USB_HOST_ADDR_Type ADDR; /**< \brief Offset: 0x000 (R/W 32) HOST_DESC_BANK Host Bank, Adress of Data Buffer */ + __IO USB_HOST_PCKSIZE_Type PCKSIZE; /**< \brief Offset: 0x004 (R/W 32) HOST_DESC_BANK Host Bank, Packet Size */ + __IO USB_HOST_EXTREG_Type EXTREG; /**< \brief Offset: 0x008 (R/W 16) HOST_DESC_BANK Host Bank, Extended */ + __IO USB_HOST_STATUS_BK_Type STATUS_BK; /**< \brief Offset: 0x00A (R/W 8) HOST_DESC_BANK Host Bank, Status of Bank */ + RoReg8 Reserved1[0x1]; + __IO USB_HOST_CTRL_PIPE_Type CTRL_PIPE; /**< \brief Offset: 0x00C (R/W 16) HOST_DESC_BANK Host Bank, Host Control Pipe */ + __IO USB_HOST_STATUS_PIPE_Type STATUS_PIPE; /**< \brief Offset: 0x00E (R/W 16) HOST_DESC_BANK Host Bank, Host Status Pipe */ +} UsbHostDescBank; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief UsbDeviceEndpoint hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO USB_DEVICE_EPCFG_Type EPCFG; /**< \brief Offset: 0x000 (R/W 8) DEVICE_ENDPOINT End Point Configuration */ + RoReg8 Reserved1[0x3]; + __O USB_DEVICE_EPSTATUSCLR_Type EPSTATUSCLR; /**< \brief Offset: 0x004 ( /W 8) DEVICE_ENDPOINT End Point Pipe Status Clear */ + __O USB_DEVICE_EPSTATUSSET_Type EPSTATUSSET; /**< \brief Offset: 0x005 ( /W 8) DEVICE_ENDPOINT End Point Pipe Status Set */ + __I USB_DEVICE_EPSTATUS_Type EPSTATUS; /**< \brief Offset: 0x006 (R/ 8) DEVICE_ENDPOINT End Point Pipe Status */ + __IO USB_DEVICE_EPINTFLAG_Type EPINTFLAG; /**< \brief Offset: 0x007 (R/W 8) DEVICE_ENDPOINT End Point Interrupt Flag */ + __IO USB_DEVICE_EPINTENCLR_Type EPINTENCLR; /**< \brief Offset: 0x008 (R/W 8) DEVICE_ENDPOINT End Point Interrupt Clear Flag */ + __IO USB_DEVICE_EPINTENSET_Type EPINTENSET; /**< \brief Offset: 0x009 (R/W 8) DEVICE_ENDPOINT End Point Interrupt Set Flag */ + RoReg8 Reserved2[0x16]; +} UsbDeviceEndpoint; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief UsbHostPipe hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO USB_HOST_PCFG_Type PCFG; /**< \brief Offset: 0x000 (R/W 8) HOST_PIPE End Point Configuration */ + RoReg8 Reserved1[0x2]; + __IO USB_HOST_BINTERVAL_Type BINTERVAL; /**< \brief Offset: 0x003 (R/W 8) HOST_PIPE Bus Access Period of Pipe */ + __O USB_HOST_PSTATUSCLR_Type PSTATUSCLR; /**< \brief Offset: 0x004 ( /W 8) HOST_PIPE End Point Pipe Status Clear */ + __O USB_HOST_PSTATUSSET_Type PSTATUSSET; /**< \brief Offset: 0x005 ( /W 8) HOST_PIPE End Point Pipe Status Set */ + __I USB_HOST_PSTATUS_Type PSTATUS; /**< \brief Offset: 0x006 (R/ 8) HOST_PIPE End Point Pipe Status */ + __IO USB_HOST_PINTFLAG_Type PINTFLAG; /**< \brief Offset: 0x007 (R/W 8) HOST_PIPE Pipe Interrupt Flag */ + __IO USB_HOST_PINTENCLR_Type PINTENCLR; /**< \brief Offset: 0x008 (R/W 8) HOST_PIPE Pipe Interrupt Flag Clear */ + __IO USB_HOST_PINTENSET_Type PINTENSET; /**< \brief Offset: 0x009 (R/W 8) HOST_PIPE Pipe Interrupt Flag Set */ + RoReg8 Reserved2[0x16]; +} UsbHostPipe; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief USB_DEVICE APB hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* USB is Device */ + __IO USB_CTRLA_Type CTRLA; /**< \brief Offset: 0x000 (R/W 8) Control A */ + RoReg8 Reserved1[0x1]; + __I USB_SYNCBUSY_Type SYNCBUSY; /**< \brief Offset: 0x002 (R/ 8) Synchronization Busy */ + RoReg8 Reserved2[0x5]; + __IO USB_DEVICE_CTRLB_Type CTRLB; /**< \brief Offset: 0x008 (R/W 16) DEVICE Control B */ + __IO USB_DEVICE_DADD_Type DADD; /**< \brief Offset: 0x00A (R/W 8) DEVICE Device Address */ + RoReg8 Reserved3[0x1]; + __I USB_DEVICE_STATUS_Type STATUS; /**< \brief Offset: 0x00C (R/ 8) DEVICE Status */ + __I USB_FSMSTATUS_Type FSMSTATUS; /**< \brief Offset: 0x00D (R/ 8) Finite State Machine Status */ + RoReg8 Reserved4[0x2]; + __I USB_DEVICE_FNUM_Type FNUM; /**< \brief Offset: 0x010 (R/ 16) DEVICE Device Frame Number */ + RoReg8 Reserved5[0x2]; + __IO USB_DEVICE_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x014 (R/W 16) DEVICE Device Interrupt Enable Clear */ + RoReg8 Reserved6[0x2]; + __IO USB_DEVICE_INTENSET_Type INTENSET; /**< \brief Offset: 0x018 (R/W 16) DEVICE Device Interrupt Enable Set */ + RoReg8 Reserved7[0x2]; + __IO USB_DEVICE_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x01C (R/W 16) DEVICE Device Interrupt Flag */ + RoReg8 Reserved8[0x2]; + __I USB_DEVICE_EPINTSMRY_Type EPINTSMRY; /**< \brief Offset: 0x020 (R/ 16) DEVICE End Point Interrupt Summary */ + RoReg8 Reserved9[0x2]; + __IO USB_DESCADD_Type DESCADD; /**< \brief Offset: 0x024 (R/W 32) Descriptor Address */ + __IO USB_PADCAL_Type PADCAL; /**< \brief Offset: 0x028 (R/W 16) USB PAD Calibration */ + RoReg8 Reserved10[0xD6]; + UsbDeviceEndpoint DeviceEndpoint[8]; /**< \brief Offset: 0x100 UsbDeviceEndpoint groups [EPT_NUM] */ +} UsbDevice; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief USB_HOST hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* USB is Host */ + __IO USB_CTRLA_Type CTRLA; /**< \brief Offset: 0x000 (R/W 8) Control A */ + RoReg8 Reserved1[0x1]; + __I USB_SYNCBUSY_Type SYNCBUSY; /**< \brief Offset: 0x002 (R/ 8) Synchronization Busy */ + RoReg8 Reserved2[0x5]; + __IO USB_HOST_CTRLB_Type CTRLB; /**< \brief Offset: 0x008 (R/W 16) HOST Control B */ + __IO USB_HOST_HSOFC_Type HSOFC; /**< \brief Offset: 0x00A (R/W 8) HOST Host Start Of Frame Control */ + RoReg8 Reserved3[0x1]; + __IO USB_HOST_STATUS_Type STATUS; /**< \brief Offset: 0x00C (R/W 8) HOST Status */ + __I USB_FSMSTATUS_Type FSMSTATUS; /**< \brief Offset: 0x00D (R/ 8) Finite State Machine Status */ + RoReg8 Reserved4[0x2]; + __IO USB_HOST_FNUM_Type FNUM; /**< \brief Offset: 0x010 (R/W 16) HOST Host Frame Number */ + __I USB_HOST_FLENHIGH_Type FLENHIGH; /**< \brief Offset: 0x012 (R/ 8) HOST Host Frame Length */ + RoReg8 Reserved5[0x1]; + __IO USB_HOST_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x014 (R/W 16) HOST Host Interrupt Enable Clear */ + RoReg8 Reserved6[0x2]; + __IO USB_HOST_INTENSET_Type INTENSET; /**< \brief Offset: 0x018 (R/W 16) HOST Host Interrupt Enable Set */ + RoReg8 Reserved7[0x2]; + __IO USB_HOST_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x01C (R/W 16) HOST Host Interrupt Flag */ + RoReg8 Reserved8[0x2]; + __I USB_HOST_PINTSMRY_Type PINTSMRY; /**< \brief Offset: 0x020 (R/ 16) HOST Pipe Interrupt Summary */ + RoReg8 Reserved9[0x2]; + __IO USB_DESCADD_Type DESCADD; /**< \brief Offset: 0x024 (R/W 32) Descriptor Address */ + __IO USB_PADCAL_Type PADCAL; /**< \brief Offset: 0x028 (R/W 16) USB PAD Calibration */ + RoReg8 Reserved10[0xD6]; + UsbHostPipe HostPipe[8]; /**< \brief Offset: 0x100 UsbHostPipe groups [EPT_NUM] */ +} UsbHost; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief USB_DEVICE Descriptor SRAM registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* USB is Device */ + UsbDeviceDescBank DeviceDescBank[2]; /**< \brief Offset: 0x000 UsbDeviceDescBank groups */ +} UsbDeviceDescriptor; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief USB_HOST Descriptor SRAM registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* USB is Host */ + UsbHostDescBank HostDescBank[2]; /**< \brief Offset: 0x000 UsbHostDescBank groups */ +} UsbHostDescriptor; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +#define SECTION_USB_DESCRIPTOR + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + UsbDevice DEVICE; /**< \brief Offset: 0x000 USB is Device */ + UsbHost HOST; /**< \brief Offset: 0x000 USB is Host */ +} Usb; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_USB_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/wdt.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/wdt.h new file mode 100644 index 0000000..075600f --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/component/wdt.h @@ -0,0 +1,303 @@ +/** + * \file + * + * \brief Component description for WDT + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_WDT_COMPONENT_ +#define _SAMD21_WDT_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR WDT */ +/* ========================================================================== */ +/** \addtogroup SAMD21_WDT Watchdog Timer */ +/*@{*/ + +#define WDT_U2203 +#define REV_WDT 0x200 + +/* -------- WDT_CTRL : (WDT Offset: 0x0) (R/W 8) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :1; /*!< bit: 0 Reserved */ + uint8_t ENABLE:1; /*!< bit: 1 Enable */ + uint8_t WEN:1; /*!< bit: 2 Watchdog Timer Window Mode Enable */ + uint8_t :4; /*!< bit: 3.. 6 Reserved */ + uint8_t ALWAYSON:1; /*!< bit: 7 Always-On */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} WDT_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define WDT_CTRL_OFFSET 0x0 /**< \brief (WDT_CTRL offset) Control */ +#define WDT_CTRL_RESETVALUE 0x00 /**< \brief (WDT_CTRL reset_value) Control */ + +#define WDT_CTRL_ENABLE_Pos 1 /**< \brief (WDT_CTRL) Enable */ +#define WDT_CTRL_ENABLE (0x1u << WDT_CTRL_ENABLE_Pos) +#define WDT_CTRL_WEN_Pos 2 /**< \brief (WDT_CTRL) Watchdog Timer Window Mode Enable */ +#define WDT_CTRL_WEN (0x1u << WDT_CTRL_WEN_Pos) +#define WDT_CTRL_ALWAYSON_Pos 7 /**< \brief (WDT_CTRL) Always-On */ +#define WDT_CTRL_ALWAYSON (0x1u << WDT_CTRL_ALWAYSON_Pos) +#define WDT_CTRL_MASK 0x86u /**< \brief (WDT_CTRL) MASK Register */ + +/* -------- WDT_CONFIG : (WDT Offset: 0x1) (R/W 8) Configuration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PER:4; /*!< bit: 0.. 3 Time-Out Period */ + uint8_t WINDOW:4; /*!< bit: 4.. 7 Window Mode Time-Out Period */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} WDT_CONFIG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define WDT_CONFIG_OFFSET 0x1 /**< \brief (WDT_CONFIG offset) Configuration */ +#define WDT_CONFIG_RESETVALUE 0xBB /**< \brief (WDT_CONFIG reset_value) Configuration */ + +#define WDT_CONFIG_PER_Pos 0 /**< \brief (WDT_CONFIG) Time-Out Period */ +#define WDT_CONFIG_PER_Msk (0xFu << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER(value) ((WDT_CONFIG_PER_Msk & ((value) << WDT_CONFIG_PER_Pos))) +#define WDT_CONFIG_PER_0_Val 0x0u /**< \brief (WDT_CONFIG) 8 clock cycles */ +#define WDT_CONFIG_PER_1_Val 0x1u /**< \brief (WDT_CONFIG) 16 clock cycles */ +#define WDT_CONFIG_PER_2_Val 0x2u /**< \brief (WDT_CONFIG) 32 clock cycles */ +#define WDT_CONFIG_PER_3_Val 0x3u /**< \brief (WDT_CONFIG) 64 clock cycles */ +#define WDT_CONFIG_PER_4_Val 0x4u /**< \brief (WDT_CONFIG) 128 clock cycles */ +#define WDT_CONFIG_PER_5_Val 0x5u /**< \brief (WDT_CONFIG) 256 clock cycles */ +#define WDT_CONFIG_PER_6_Val 0x6u /**< \brief (WDT_CONFIG) 512 clock cycles */ +#define WDT_CONFIG_PER_7_Val 0x7u /**< \brief (WDT_CONFIG) 1024 clock cycles */ +#define WDT_CONFIG_PER_8_Val 0x8u /**< \brief (WDT_CONFIG) 2048 clock cycles */ +#define WDT_CONFIG_PER_9_Val 0x9u /**< \brief (WDT_CONFIG) 4096 clock cycles */ +#define WDT_CONFIG_PER_10_Val 0xAu /**< \brief (WDT_CONFIG) 8192 clock cycles */ +#define WDT_CONFIG_PER_11_Val 0xBu /**< \brief (WDT_CONFIG) 16384 clock cycles */ +#define WDT_CONFIG_PER_0 (WDT_CONFIG_PER_0_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_1 (WDT_CONFIG_PER_1_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_2 (WDT_CONFIG_PER_2_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_3 (WDT_CONFIG_PER_3_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_4 (WDT_CONFIG_PER_4_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_5 (WDT_CONFIG_PER_5_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_6 (WDT_CONFIG_PER_6_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_7 (WDT_CONFIG_PER_7_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_8 (WDT_CONFIG_PER_8_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_9 (WDT_CONFIG_PER_9_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_10 (WDT_CONFIG_PER_10_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_11 (WDT_CONFIG_PER_11_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_WINDOW_Pos 4 /**< \brief (WDT_CONFIG) Window Mode Time-Out Period */ +#define WDT_CONFIG_WINDOW_Msk (0xFu << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW(value) ((WDT_CONFIG_WINDOW_Msk & ((value) << WDT_CONFIG_WINDOW_Pos))) +#define WDT_CONFIG_WINDOW_0_Val 0x0u /**< \brief (WDT_CONFIG) 8 clock cycles */ +#define WDT_CONFIG_WINDOW_1_Val 0x1u /**< \brief (WDT_CONFIG) 16 clock cycles */ +#define WDT_CONFIG_WINDOW_2_Val 0x2u /**< \brief (WDT_CONFIG) 32 clock cycles */ +#define WDT_CONFIG_WINDOW_3_Val 0x3u /**< \brief (WDT_CONFIG) 64 clock cycles */ +#define WDT_CONFIG_WINDOW_4_Val 0x4u /**< \brief (WDT_CONFIG) 128 clock cycles */ +#define WDT_CONFIG_WINDOW_5_Val 0x5u /**< \brief (WDT_CONFIG) 256 clock cycles */ +#define WDT_CONFIG_WINDOW_6_Val 0x6u /**< \brief (WDT_CONFIG) 512 clock cycles */ +#define WDT_CONFIG_WINDOW_7_Val 0x7u /**< \brief (WDT_CONFIG) 1024 clock cycles */ +#define WDT_CONFIG_WINDOW_8_Val 0x8u /**< \brief (WDT_CONFIG) 2048 clock cycles */ +#define WDT_CONFIG_WINDOW_9_Val 0x9u /**< \brief (WDT_CONFIG) 4096 clock cycles */ +#define WDT_CONFIG_WINDOW_10_Val 0xAu /**< \brief (WDT_CONFIG) 8192 clock cycles */ +#define WDT_CONFIG_WINDOW_11_Val 0xBu /**< \brief (WDT_CONFIG) 16384 clock cycles */ +#define WDT_CONFIG_WINDOW_0 (WDT_CONFIG_WINDOW_0_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_1 (WDT_CONFIG_WINDOW_1_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_2 (WDT_CONFIG_WINDOW_2_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_3 (WDT_CONFIG_WINDOW_3_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_4 (WDT_CONFIG_WINDOW_4_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_5 (WDT_CONFIG_WINDOW_5_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_6 (WDT_CONFIG_WINDOW_6_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_7 (WDT_CONFIG_WINDOW_7_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_8 (WDT_CONFIG_WINDOW_8_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_9 (WDT_CONFIG_WINDOW_9_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_10 (WDT_CONFIG_WINDOW_10_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_11 (WDT_CONFIG_WINDOW_11_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_MASK 0xFFu /**< \brief (WDT_CONFIG) MASK Register */ + +/* -------- WDT_EWCTRL : (WDT Offset: 0x2) (R/W 8) Early Warning Interrupt Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t EWOFFSET:4; /*!< bit: 0.. 3 Early Warning Interrupt Time Offset */ + uint8_t :4; /*!< bit: 4.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} WDT_EWCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define WDT_EWCTRL_OFFSET 0x2 /**< \brief (WDT_EWCTRL offset) Early Warning Interrupt Control */ +#define WDT_EWCTRL_RESETVALUE 0x0B /**< \brief (WDT_EWCTRL reset_value) Early Warning Interrupt Control */ + +#define WDT_EWCTRL_EWOFFSET_Pos 0 /**< \brief (WDT_EWCTRL) Early Warning Interrupt Time Offset */ +#define WDT_EWCTRL_EWOFFSET_Msk (0xFu << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET(value) ((WDT_EWCTRL_EWOFFSET_Msk & ((value) << WDT_EWCTRL_EWOFFSET_Pos))) +#define WDT_EWCTRL_EWOFFSET_0_Val 0x0u /**< \brief (WDT_EWCTRL) 8 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_1_Val 0x1u /**< \brief (WDT_EWCTRL) 16 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_2_Val 0x2u /**< \brief (WDT_EWCTRL) 32 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_3_Val 0x3u /**< \brief (WDT_EWCTRL) 64 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_4_Val 0x4u /**< \brief (WDT_EWCTRL) 128 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_5_Val 0x5u /**< \brief (WDT_EWCTRL) 256 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_6_Val 0x6u /**< \brief (WDT_EWCTRL) 512 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_7_Val 0x7u /**< \brief (WDT_EWCTRL) 1024 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_8_Val 0x8u /**< \brief (WDT_EWCTRL) 2048 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_9_Val 0x9u /**< \brief (WDT_EWCTRL) 4096 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_10_Val 0xAu /**< \brief (WDT_EWCTRL) 8192 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_11_Val 0xBu /**< \brief (WDT_EWCTRL) 16384 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_0 (WDT_EWCTRL_EWOFFSET_0_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_1 (WDT_EWCTRL_EWOFFSET_1_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_2 (WDT_EWCTRL_EWOFFSET_2_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_3 (WDT_EWCTRL_EWOFFSET_3_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_4 (WDT_EWCTRL_EWOFFSET_4_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_5 (WDT_EWCTRL_EWOFFSET_5_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_6 (WDT_EWCTRL_EWOFFSET_6_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_7 (WDT_EWCTRL_EWOFFSET_7_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_8 (WDT_EWCTRL_EWOFFSET_8_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_9 (WDT_EWCTRL_EWOFFSET_9_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_10 (WDT_EWCTRL_EWOFFSET_10_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_11 (WDT_EWCTRL_EWOFFSET_11_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_MASK 0x0Fu /**< \brief (WDT_EWCTRL) MASK Register */ + +/* -------- WDT_INTENCLR : (WDT Offset: 0x4) (R/W 8) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t EW:1; /*!< bit: 0 Early Warning Interrupt Enable */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} WDT_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define WDT_INTENCLR_OFFSET 0x4 /**< \brief (WDT_INTENCLR offset) Interrupt Enable Clear */ +#define WDT_INTENCLR_RESETVALUE 0x00 /**< \brief (WDT_INTENCLR reset_value) Interrupt Enable Clear */ + +#define WDT_INTENCLR_EW_Pos 0 /**< \brief (WDT_INTENCLR) Early Warning Interrupt Enable */ +#define WDT_INTENCLR_EW (0x1u << WDT_INTENCLR_EW_Pos) +#define WDT_INTENCLR_MASK 0x01u /**< \brief (WDT_INTENCLR) MASK Register */ + +/* -------- WDT_INTENSET : (WDT Offset: 0x5) (R/W 8) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t EW:1; /*!< bit: 0 Early Warning Interrupt Enable */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} WDT_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define WDT_INTENSET_OFFSET 0x5 /**< \brief (WDT_INTENSET offset) Interrupt Enable Set */ +#define WDT_INTENSET_RESETVALUE 0x00 /**< \brief (WDT_INTENSET reset_value) Interrupt Enable Set */ + +#define WDT_INTENSET_EW_Pos 0 /**< \brief (WDT_INTENSET) Early Warning Interrupt Enable */ +#define WDT_INTENSET_EW (0x1u << WDT_INTENSET_EW_Pos) +#define WDT_INTENSET_MASK 0x01u /**< \brief (WDT_INTENSET) MASK Register */ + +/* -------- WDT_INTFLAG : (WDT Offset: 0x6) (R/W 8) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t EW:1; /*!< bit: 0 Early Warning */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} WDT_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define WDT_INTFLAG_OFFSET 0x6 /**< \brief (WDT_INTFLAG offset) Interrupt Flag Status and Clear */ +#define WDT_INTFLAG_RESETVALUE 0x00 /**< \brief (WDT_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define WDT_INTFLAG_EW_Pos 0 /**< \brief (WDT_INTFLAG) Early Warning */ +#define WDT_INTFLAG_EW (0x1u << WDT_INTFLAG_EW_Pos) +#define WDT_INTFLAG_MASK 0x01u /**< \brief (WDT_INTFLAG) MASK Register */ + +/* -------- WDT_STATUS : (WDT Offset: 0x7) (R/ 8) Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :7; /*!< bit: 0.. 6 Reserved */ + uint8_t SYNCBUSY:1; /*!< bit: 7 Synchronization Busy */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} WDT_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define WDT_STATUS_OFFSET 0x7 /**< \brief (WDT_STATUS offset) Status */ +#define WDT_STATUS_RESETVALUE 0x00 /**< \brief (WDT_STATUS reset_value) Status */ + +#define WDT_STATUS_SYNCBUSY_Pos 7 /**< \brief (WDT_STATUS) Synchronization Busy */ +#define WDT_STATUS_SYNCBUSY (0x1u << WDT_STATUS_SYNCBUSY_Pos) +#define WDT_STATUS_MASK 0x80u /**< \brief (WDT_STATUS) MASK Register */ + +/* -------- WDT_CLEAR : (WDT Offset: 0x8) ( /W 8) Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CLEAR:8; /*!< bit: 0.. 7 Watchdog Clear */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} WDT_CLEAR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define WDT_CLEAR_OFFSET 0x8 /**< \brief (WDT_CLEAR offset) Clear */ +#define WDT_CLEAR_RESETVALUE 0x00 /**< \brief (WDT_CLEAR reset_value) Clear */ + +#define WDT_CLEAR_CLEAR_Pos 0 /**< \brief (WDT_CLEAR) Watchdog Clear */ +#define WDT_CLEAR_CLEAR_Msk (0xFFu << WDT_CLEAR_CLEAR_Pos) +#define WDT_CLEAR_CLEAR(value) ((WDT_CLEAR_CLEAR_Msk & ((value) << WDT_CLEAR_CLEAR_Pos))) +#define WDT_CLEAR_CLEAR_KEY_Val 0xA5u /**< \brief (WDT_CLEAR) Clear Key */ +#define WDT_CLEAR_CLEAR_KEY (WDT_CLEAR_CLEAR_KEY_Val << WDT_CLEAR_CLEAR_Pos) +#define WDT_CLEAR_MASK 0xFFu /**< \brief (WDT_CLEAR) MASK Register */ + +/** \brief WDT hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO WDT_CTRL_Type CTRL; /**< \brief Offset: 0x0 (R/W 8) Control */ + __IO WDT_CONFIG_Type CONFIG; /**< \brief Offset: 0x1 (R/W 8) Configuration */ + __IO WDT_EWCTRL_Type EWCTRL; /**< \brief Offset: 0x2 (R/W 8) Early Warning Interrupt Control */ + RoReg8 Reserved1[0x1]; + __IO WDT_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x4 (R/W 8) Interrupt Enable Clear */ + __IO WDT_INTENSET_Type INTENSET; /**< \brief Offset: 0x5 (R/W 8) Interrupt Enable Set */ + __IO WDT_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x6 (R/W 8) Interrupt Flag Status and Clear */ + __I WDT_STATUS_Type STATUS; /**< \brief Offset: 0x7 (R/ 8) Status */ + __O WDT_CLEAR_Type CLEAR; /**< \brief Offset: 0x8 ( /W 8) Clear */ +} Wdt; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_WDT_COMPONENT_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/ac.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/ac.h new file mode 100644 index 0000000..2ca27ac --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/ac.h @@ -0,0 +1,87 @@ +/** + * \file + * + * \brief Instance description for AC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_AC_INSTANCE_ +#define _SAMD21_AC_INSTANCE_ + +/* ========== Register definition for AC peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_AC_CTRLA (0x42004400U) /**< \brief (AC) Control A */ +#define REG_AC_CTRLB (0x42004401U) /**< \brief (AC) Control B */ +#define REG_AC_EVCTRL (0x42004402U) /**< \brief (AC) Event Control */ +#define REG_AC_INTENCLR (0x42004404U) /**< \brief (AC) Interrupt Enable Clear */ +#define REG_AC_INTENSET (0x42004405U) /**< \brief (AC) Interrupt Enable Set */ +#define REG_AC_INTFLAG (0x42004406U) /**< \brief (AC) Interrupt Flag Status and Clear */ +#define REG_AC_STATUSA (0x42004408U) /**< \brief (AC) Status A */ +#define REG_AC_STATUSB (0x42004409U) /**< \brief (AC) Status B */ +#define REG_AC_STATUSC (0x4200440AU) /**< \brief (AC) Status C */ +#define REG_AC_WINCTRL (0x4200440CU) /**< \brief (AC) Window Control */ +#define REG_AC_COMPCTRL0 (0x42004410U) /**< \brief (AC) Comparator Control 0 */ +#define REG_AC_COMPCTRL1 (0x42004414U) /**< \brief (AC) Comparator Control 1 */ +#define REG_AC_SCALER0 (0x42004420U) /**< \brief (AC) Scaler 0 */ +#define REG_AC_SCALER1 (0x42004421U) /**< \brief (AC) Scaler 1 */ +#else +#define REG_AC_CTRLA (*(RwReg8 *)0x42004400U) /**< \brief (AC) Control A */ +#define REG_AC_CTRLB (*(WoReg8 *)0x42004401U) /**< \brief (AC) Control B */ +#define REG_AC_EVCTRL (*(RwReg16*)0x42004402U) /**< \brief (AC) Event Control */ +#define REG_AC_INTENCLR (*(RwReg8 *)0x42004404U) /**< \brief (AC) Interrupt Enable Clear */ +#define REG_AC_INTENSET (*(RwReg8 *)0x42004405U) /**< \brief (AC) Interrupt Enable Set */ +#define REG_AC_INTFLAG (*(RwReg8 *)0x42004406U) /**< \brief (AC) Interrupt Flag Status and Clear */ +#define REG_AC_STATUSA (*(RoReg8 *)0x42004408U) /**< \brief (AC) Status A */ +#define REG_AC_STATUSB (*(RoReg8 *)0x42004409U) /**< \brief (AC) Status B */ +#define REG_AC_STATUSC (*(RoReg8 *)0x4200440AU) /**< \brief (AC) Status C */ +#define REG_AC_WINCTRL (*(RwReg8 *)0x4200440CU) /**< \brief (AC) Window Control */ +#define REG_AC_COMPCTRL0 (*(RwReg *)0x42004410U) /**< \brief (AC) Comparator Control 0 */ +#define REG_AC_COMPCTRL1 (*(RwReg *)0x42004414U) /**< \brief (AC) Comparator Control 1 */ +#define REG_AC_SCALER0 (*(RwReg8 *)0x42004420U) /**< \brief (AC) Scaler 0 */ +#define REG_AC_SCALER1 (*(RwReg8 *)0x42004421U) /**< \brief (AC) Scaler 1 */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for AC peripheral ========== */ +#define AC_CMP_NUM 2 +#define AC_GCLK_ID_ANA 32 +#define AC_GCLK_ID_DIG 31 +#define AC_NUM_CMP AC_CMP_NUM +#define AC_PAIRS 1 + +#endif /* _SAMD21_AC_INSTANCE_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/adc.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/adc.h new file mode 100644 index 0000000..9ee8999 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/adc.h @@ -0,0 +1,99 @@ +/** + * \file + * + * \brief Instance description for ADC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_ADC_INSTANCE_ +#define _SAMD21_ADC_INSTANCE_ + +/* ========== Register definition for ADC peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_ADC_CTRLA (0x42004000U) /**< \brief (ADC) Control A */ +#define REG_ADC_REFCTRL (0x42004001U) /**< \brief (ADC) Reference Control */ +#define REG_ADC_AVGCTRL (0x42004002U) /**< \brief (ADC) Average Control */ +#define REG_ADC_SAMPCTRL (0x42004003U) /**< \brief (ADC) Sampling Time Control */ +#define REG_ADC_CTRLB (0x42004004U) /**< \brief (ADC) Control B */ +#define REG_ADC_WINCTRL (0x42004008U) /**< \brief (ADC) Window Monitor Control */ +#define REG_ADC_SWTRIG (0x4200400CU) /**< \brief (ADC) Software Trigger */ +#define REG_ADC_INPUTCTRL (0x42004010U) /**< \brief (ADC) Input Control */ +#define REG_ADC_EVCTRL (0x42004014U) /**< \brief (ADC) Event Control */ +#define REG_ADC_INTENCLR (0x42004016U) /**< \brief (ADC) Interrupt Enable Clear */ +#define REG_ADC_INTENSET (0x42004017U) /**< \brief (ADC) Interrupt Enable Set */ +#define REG_ADC_INTFLAG (0x42004018U) /**< \brief (ADC) Interrupt Flag Status and Clear */ +#define REG_ADC_STATUS (0x42004019U) /**< \brief (ADC) Status */ +#define REG_ADC_RESULT (0x4200401AU) /**< \brief (ADC) Result */ +#define REG_ADC_WINLT (0x4200401CU) /**< \brief (ADC) Window Monitor Lower Threshold */ +#define REG_ADC_WINUT (0x42004020U) /**< \brief (ADC) Window Monitor Upper Threshold */ +#define REG_ADC_GAINCORR (0x42004024U) /**< \brief (ADC) Gain Correction */ +#define REG_ADC_OFFSETCORR (0x42004026U) /**< \brief (ADC) Offset Correction */ +#define REG_ADC_CALIB (0x42004028U) /**< \brief (ADC) Calibration */ +#define REG_ADC_DBGCTRL (0x4200402AU) /**< \brief (ADC) Debug Control */ +#else +#define REG_ADC_CTRLA (*(RwReg8 *)0x42004000U) /**< \brief (ADC) Control A */ +#define REG_ADC_REFCTRL (*(RwReg8 *)0x42004001U) /**< \brief (ADC) Reference Control */ +#define REG_ADC_AVGCTRL (*(RwReg8 *)0x42004002U) /**< \brief (ADC) Average Control */ +#define REG_ADC_SAMPCTRL (*(RwReg8 *)0x42004003U) /**< \brief (ADC) Sampling Time Control */ +#define REG_ADC_CTRLB (*(RwReg16*)0x42004004U) /**< \brief (ADC) Control B */ +#define REG_ADC_WINCTRL (*(RwReg8 *)0x42004008U) /**< \brief (ADC) Window Monitor Control */ +#define REG_ADC_SWTRIG (*(RwReg8 *)0x4200400CU) /**< \brief (ADC) Software Trigger */ +#define REG_ADC_INPUTCTRL (*(RwReg *)0x42004010U) /**< \brief (ADC) Input Control */ +#define REG_ADC_EVCTRL (*(RwReg8 *)0x42004014U) /**< \brief (ADC) Event Control */ +#define REG_ADC_INTENCLR (*(RwReg8 *)0x42004016U) /**< \brief (ADC) Interrupt Enable Clear */ +#define REG_ADC_INTENSET (*(RwReg8 *)0x42004017U) /**< \brief (ADC) Interrupt Enable Set */ +#define REG_ADC_INTFLAG (*(RwReg8 *)0x42004018U) /**< \brief (ADC) Interrupt Flag Status and Clear */ +#define REG_ADC_STATUS (*(RoReg8 *)0x42004019U) /**< \brief (ADC) Status */ +#define REG_ADC_RESULT (*(RoReg16*)0x4200401AU) /**< \brief (ADC) Result */ +#define REG_ADC_WINLT (*(RwReg16*)0x4200401CU) /**< \brief (ADC) Window Monitor Lower Threshold */ +#define REG_ADC_WINUT (*(RwReg16*)0x42004020U) /**< \brief (ADC) Window Monitor Upper Threshold */ +#define REG_ADC_GAINCORR (*(RwReg16*)0x42004024U) /**< \brief (ADC) Gain Correction */ +#define REG_ADC_OFFSETCORR (*(RwReg16*)0x42004026U) /**< \brief (ADC) Offset Correction */ +#define REG_ADC_CALIB (*(RwReg16*)0x42004028U) /**< \brief (ADC) Calibration */ +#define REG_ADC_DBGCTRL (*(RwReg8 *)0x4200402AU) /**< \brief (ADC) Debug Control */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for ADC peripheral ========== */ +#define ADC_DMAC_ID_RESRDY 39 +#define ADC_EXTCHANNEL_MSB 19 +#define ADC_GCLK_ID 30 +#define ADC_RESULT_BITS 16 +#define ADC_RESULT_MSB (ADC_RESULT_BITS-1) + +#endif /* _SAMD21_ADC_INSTANCE_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/dac.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/dac.h new file mode 100644 index 0000000..f15486d --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/dac.h @@ -0,0 +1,74 @@ +/** + * \file + * + * \brief Instance description for DAC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_DAC_INSTANCE_ +#define _SAMD21_DAC_INSTANCE_ + +/* ========== Register definition for DAC peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_DAC_CTRLA (0x42004800U) /**< \brief (DAC) Control A */ +#define REG_DAC_CTRLB (0x42004801U) /**< \brief (DAC) Control B */ +#define REG_DAC_EVCTRL (0x42004802U) /**< \brief (DAC) Event Control */ +#define REG_DAC_INTENCLR (0x42004804U) /**< \brief (DAC) Interrupt Enable Clear */ +#define REG_DAC_INTENSET (0x42004805U) /**< \brief (DAC) Interrupt Enable Set */ +#define REG_DAC_INTFLAG (0x42004806U) /**< \brief (DAC) Interrupt Flag Status and Clear */ +#define REG_DAC_STATUS (0x42004807U) /**< \brief (DAC) Status */ +#define REG_DAC_DATA (0x42004808U) /**< \brief (DAC) Data */ +#define REG_DAC_DATABUF (0x4200480CU) /**< \brief (DAC) Data Buffer */ +#else +#define REG_DAC_CTRLA (*(RwReg8 *)0x42004800U) /**< \brief (DAC) Control A */ +#define REG_DAC_CTRLB (*(RwReg8 *)0x42004801U) /**< \brief (DAC) Control B */ +#define REG_DAC_EVCTRL (*(RwReg8 *)0x42004802U) /**< \brief (DAC) Event Control */ +#define REG_DAC_INTENCLR (*(RwReg8 *)0x42004804U) /**< \brief (DAC) Interrupt Enable Clear */ +#define REG_DAC_INTENSET (*(RwReg8 *)0x42004805U) /**< \brief (DAC) Interrupt Enable Set */ +#define REG_DAC_INTFLAG (*(RwReg8 *)0x42004806U) /**< \brief (DAC) Interrupt Flag Status and Clear */ +#define REG_DAC_STATUS (*(RoReg8 *)0x42004807U) /**< \brief (DAC) Status */ +#define REG_DAC_DATA (*(RwReg16*)0x42004808U) /**< \brief (DAC) Data */ +#define REG_DAC_DATABUF (*(RwReg16*)0x4200480CU) /**< \brief (DAC) Data Buffer */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for DAC peripheral ========== */ +#define DAC_DMAC_ID_EMPTY 40 +#define DAC_GCLK_ID 33 + +#endif /* _SAMD21_DAC_INSTANCE_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/dmac.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/dmac.h new file mode 100644 index 0000000..8a6909f --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/dmac.h @@ -0,0 +1,107 @@ +/** + * \file + * + * \brief Instance description for DMAC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_DMAC_INSTANCE_ +#define _SAMD21_DMAC_INSTANCE_ + +/* ========== Register definition for DMAC peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_DMAC_CTRL (0x41004800U) /**< \brief (DMAC) Control */ +#define REG_DMAC_CRCCTRL (0x41004802U) /**< \brief (DMAC) CRC Control */ +#define REG_DMAC_CRCDATAIN (0x41004804U) /**< \brief (DMAC) CRC Data Input */ +#define REG_DMAC_CRCCHKSUM (0x41004808U) /**< \brief (DMAC) CRC Checksum */ +#define REG_DMAC_CRCSTATUS (0x4100480CU) /**< \brief (DMAC) CRC Status */ +#define REG_DMAC_DBGCTRL (0x4100480DU) /**< \brief (DMAC) Debug Control */ +#define REG_DMAC_SWTRIGCTRL (0x41004810U) /**< \brief (DMAC) Software Trigger Control */ +#define REG_DMAC_PRICTRL0 (0x41004814U) /**< \brief (DMAC) Priority Control 0 */ +#define REG_DMAC_INTPEND (0x41004820U) /**< \brief (DMAC) Interrupt Pending */ +#define REG_DMAC_INTSTATUS (0x41004824U) /**< \brief (DMAC) Interrupt Status */ +#define REG_DMAC_BUSYCH (0x41004828U) /**< \brief (DMAC) Busy Channels */ +#define REG_DMAC_PENDCH (0x4100482CU) /**< \brief (DMAC) Pending Channels */ +#define REG_DMAC_ACTIVE (0x41004830U) /**< \brief (DMAC) Active Channel and Levels */ +#define REG_DMAC_BASEADDR (0x41004834U) /**< \brief (DMAC) Descriptor Memory Section Base Address */ +#define REG_DMAC_WRBADDR (0x41004838U) /**< \brief (DMAC) Write-Back Memory Section Base Address */ +#define REG_DMAC_CHID (0x4100483FU) /**< \brief (DMAC) Channel ID */ +#define REG_DMAC_CHCTRLA (0x41004840U) /**< \brief (DMAC) Channel Control A */ +#define REG_DMAC_CHCTRLB (0x41004844U) /**< \brief (DMAC) Channel Control B */ +#define REG_DMAC_CHINTENCLR (0x4100484CU) /**< \brief (DMAC) Channel Interrupt Enable Clear */ +#define REG_DMAC_CHINTENSET (0x4100484DU) /**< \brief (DMAC) Channel Interrupt Enable Set */ +#define REG_DMAC_CHINTFLAG (0x4100484EU) /**< \brief (DMAC) Channel Interrupt Flag Status and Clear */ +#define REG_DMAC_CHSTATUS (0x4100484FU) /**< \brief (DMAC) Channel Status */ +#else +#define REG_DMAC_CTRL (*(RwReg16*)0x41004800U) /**< \brief (DMAC) Control */ +#define REG_DMAC_CRCCTRL (*(RwReg16*)0x41004802U) /**< \brief (DMAC) CRC Control */ +#define REG_DMAC_CRCDATAIN (*(RwReg *)0x41004804U) /**< \brief (DMAC) CRC Data Input */ +#define REG_DMAC_CRCCHKSUM (*(RwReg *)0x41004808U) /**< \brief (DMAC) CRC Checksum */ +#define REG_DMAC_CRCSTATUS (*(RwReg8 *)0x4100480CU) /**< \brief (DMAC) CRC Status */ +#define REG_DMAC_DBGCTRL (*(RwReg8 *)0x4100480DU) /**< \brief (DMAC) Debug Control */ +#define REG_DMAC_SWTRIGCTRL (*(RwReg *)0x41004810U) /**< \brief (DMAC) Software Trigger Control */ +#define REG_DMAC_PRICTRL0 (*(RwReg *)0x41004814U) /**< \brief (DMAC) Priority Control 0 */ +#define REG_DMAC_INTPEND (*(RwReg16*)0x41004820U) /**< \brief (DMAC) Interrupt Pending */ +#define REG_DMAC_INTSTATUS (*(RoReg *)0x41004824U) /**< \brief (DMAC) Interrupt Status */ +#define REG_DMAC_BUSYCH (*(RoReg *)0x41004828U) /**< \brief (DMAC) Busy Channels */ +#define REG_DMAC_PENDCH (*(RoReg *)0x4100482CU) /**< \brief (DMAC) Pending Channels */ +#define REG_DMAC_ACTIVE (*(RoReg *)0x41004830U) /**< \brief (DMAC) Active Channel and Levels */ +#define REG_DMAC_BASEADDR (*(RwReg *)0x41004834U) /**< \brief (DMAC) Descriptor Memory Section Base Address */ +#define REG_DMAC_WRBADDR (*(RwReg *)0x41004838U) /**< \brief (DMAC) Write-Back Memory Section Base Address */ +#define REG_DMAC_CHID (*(RwReg8 *)0x4100483FU) /**< \brief (DMAC) Channel ID */ +#define REG_DMAC_CHCTRLA (*(RwReg8 *)0x41004840U) /**< \brief (DMAC) Channel Control A */ +#define REG_DMAC_CHCTRLB (*(RwReg *)0x41004844U) /**< \brief (DMAC) Channel Control B */ +#define REG_DMAC_CHINTENCLR (*(RwReg8 *)0x4100484CU) /**< \brief (DMAC) Channel Interrupt Enable Clear */ +#define REG_DMAC_CHINTENSET (*(RwReg8 *)0x4100484DU) /**< \brief (DMAC) Channel Interrupt Enable Set */ +#define REG_DMAC_CHINTFLAG (*(RwReg8 *)0x4100484EU) /**< \brief (DMAC) Channel Interrupt Flag Status and Clear */ +#define REG_DMAC_CHSTATUS (*(RoReg8 *)0x4100484FU) /**< \brief (DMAC) Channel Status */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for DMAC peripheral ========== */ +#define DMAC_CH_BITS len(bin(DMAC_CH_NUM - 1))-2 +#define DMAC_CH_NUM 12 +#define DMAC_CLK_AHB_ID 5 +#define DMAC_EVIN_NUM 4 +#define DMAC_EVOUT_NUM 4 +#define DMAC_LVL_BITS len(bin(DMAC_LVL_NUM - 1))-2 +#define DMAC_LVL_NUM 4 +#define DMAC_TRIG_BITS len(bin(DMAC_TRIG_NUM - 1))-2 +#define DMAC_TRIG_NUM 45 + +#endif /* _SAMD21_DMAC_INSTANCE_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/dsu.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/dsu.h new file mode 100644 index 0000000..a01289c --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/dsu.h @@ -0,0 +1,99 @@ +/** + * \file + * + * \brief Instance description for DSU + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_DSU_INSTANCE_ +#define _SAMD21_DSU_INSTANCE_ + +/* ========== Register definition for DSU peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_DSU_CTRL (0x41002000U) /**< \brief (DSU) Control */ +#define REG_DSU_STATUSA (0x41002001U) /**< \brief (DSU) Status A */ +#define REG_DSU_STATUSB (0x41002002U) /**< \brief (DSU) Status B */ +#define REG_DSU_ADDR (0x41002004U) /**< \brief (DSU) Address */ +#define REG_DSU_LENGTH (0x41002008U) /**< \brief (DSU) Length */ +#define REG_DSU_DATA (0x4100200CU) /**< \brief (DSU) Data */ +#define REG_DSU_DCC0 (0x41002010U) /**< \brief (DSU) Debug Communication Channel 0 */ +#define REG_DSU_DCC1 (0x41002014U) /**< \brief (DSU) Debug Communication Channel 1 */ +#define REG_DSU_DID (0x41002018U) /**< \brief (DSU) Device Identification */ +#define REG_DSU_ENTRY0 (0x41003000U) /**< \brief (DSU) Coresight ROM Table Entry 0 */ +#define REG_DSU_ENTRY1 (0x41003004U) /**< \brief (DSU) Coresight ROM Table Entry 1 */ +#define REG_DSU_END (0x41003008U) /**< \brief (DSU) Coresight ROM Table End */ +#define REG_DSU_MEMTYPE (0x41003FCCU) /**< \brief (DSU) Coresight ROM Table Memory Type */ +#define REG_DSU_PID4 (0x41003FD0U) /**< \brief (DSU) Peripheral Identification 4 */ +#define REG_DSU_PID0 (0x41003FE0U) /**< \brief (DSU) Peripheral Identification 0 */ +#define REG_DSU_PID1 (0x41003FE4U) /**< \brief (DSU) Peripheral Identification 1 */ +#define REG_DSU_PID2 (0x41003FE8U) /**< \brief (DSU) Peripheral Identification 2 */ +#define REG_DSU_PID3 (0x41003FECU) /**< \brief (DSU) Peripheral Identification 3 */ +#define REG_DSU_CID0 (0x41003FF0U) /**< \brief (DSU) Component Identification 0 */ +#define REG_DSU_CID1 (0x41003FF4U) /**< \brief (DSU) Component Identification 1 */ +#define REG_DSU_CID2 (0x41003FF8U) /**< \brief (DSU) Component Identification 2 */ +#define REG_DSU_CID3 (0x41003FFCU) /**< \brief (DSU) Component Identification 3 */ +#else +#define REG_DSU_CTRL (*(WoReg8 *)0x41002000U) /**< \brief (DSU) Control */ +#define REG_DSU_STATUSA (*(RwReg8 *)0x41002001U) /**< \brief (DSU) Status A */ +#define REG_DSU_STATUSB (*(RoReg8 *)0x41002002U) /**< \brief (DSU) Status B */ +#define REG_DSU_ADDR (*(RwReg *)0x41002004U) /**< \brief (DSU) Address */ +#define REG_DSU_LENGTH (*(RwReg *)0x41002008U) /**< \brief (DSU) Length */ +#define REG_DSU_DATA (*(RwReg *)0x4100200CU) /**< \brief (DSU) Data */ +#define REG_DSU_DCC0 (*(RwReg *)0x41002010U) /**< \brief (DSU) Debug Communication Channel 0 */ +#define REG_DSU_DCC1 (*(RwReg *)0x41002014U) /**< \brief (DSU) Debug Communication Channel 1 */ +#define REG_DSU_DID (*(RoReg *)0x41002018U) /**< \brief (DSU) Device Identification */ +#define REG_DSU_ENTRY0 (*(RoReg *)0x41003000U) /**< \brief (DSU) Coresight ROM Table Entry 0 */ +#define REG_DSU_ENTRY1 (*(RoReg *)0x41003004U) /**< \brief (DSU) Coresight ROM Table Entry 1 */ +#define REG_DSU_END (*(RoReg *)0x41003008U) /**< \brief (DSU) Coresight ROM Table End */ +#define REG_DSU_MEMTYPE (*(RoReg *)0x41003FCCU) /**< \brief (DSU) Coresight ROM Table Memory Type */ +#define REG_DSU_PID4 (*(RoReg *)0x41003FD0U) /**< \brief (DSU) Peripheral Identification 4 */ +#define REG_DSU_PID0 (*(RoReg *)0x41003FE0U) /**< \brief (DSU) Peripheral Identification 0 */ +#define REG_DSU_PID1 (*(RoReg *)0x41003FE4U) /**< \brief (DSU) Peripheral Identification 1 */ +#define REG_DSU_PID2 (*(RoReg *)0x41003FE8U) /**< \brief (DSU) Peripheral Identification 2 */ +#define REG_DSU_PID3 (*(RoReg *)0x41003FECU) /**< \brief (DSU) Peripheral Identification 3 */ +#define REG_DSU_CID0 (*(RoReg *)0x41003FF0U) /**< \brief (DSU) Component Identification 0 */ +#define REG_DSU_CID1 (*(RoReg *)0x41003FF4U) /**< \brief (DSU) Component Identification 1 */ +#define REG_DSU_CID2 (*(RoReg *)0x41003FF8U) /**< \brief (DSU) Component Identification 2 */ +#define REG_DSU_CID3 (*(RoReg *)0x41003FFCU) /**< \brief (DSU) Component Identification 3 */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for DSU peripheral ========== */ +#define DSU_CLK_HSB_ID 3 + +#endif /* _SAMD21_DSU_INSTANCE_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/eic.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/eic.h new file mode 100644 index 0000000..18315fd --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/eic.h @@ -0,0 +1,78 @@ +/** + * \file + * + * \brief Instance description for EIC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_EIC_INSTANCE_ +#define _SAMD21_EIC_INSTANCE_ + +/* ========== Register definition for EIC peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_EIC_CTRL (0x40001800U) /**< \brief (EIC) Control */ +#define REG_EIC_STATUS (0x40001801U) /**< \brief (EIC) Status */ +#define REG_EIC_NMICTRL (0x40001802U) /**< \brief (EIC) Non-Maskable Interrupt Control */ +#define REG_EIC_NMIFLAG (0x40001803U) /**< \brief (EIC) Non-Maskable Interrupt Flag Status and Clear */ +#define REG_EIC_EVCTRL (0x40001804U) /**< \brief (EIC) Event Control */ +#define REG_EIC_INTENCLR (0x40001808U) /**< \brief (EIC) Interrupt Enable Clear */ +#define REG_EIC_INTENSET (0x4000180CU) /**< \brief (EIC) Interrupt Enable Set */ +#define REG_EIC_INTFLAG (0x40001810U) /**< \brief (EIC) Interrupt Flag Status and Clear */ +#define REG_EIC_WAKEUP (0x40001814U) /**< \brief (EIC) Wake-Up Enable */ +#define REG_EIC_CONFIG0 (0x40001818U) /**< \brief (EIC) Configuration 0 */ +#define REG_EIC_CONFIG1 (0x4000181CU) /**< \brief (EIC) Configuration 1 */ +#else +#define REG_EIC_CTRL (*(RwReg8 *)0x40001800U) /**< \brief (EIC) Control */ +#define REG_EIC_STATUS (*(RoReg8 *)0x40001801U) /**< \brief (EIC) Status */ +#define REG_EIC_NMICTRL (*(RwReg8 *)0x40001802U) /**< \brief (EIC) Non-Maskable Interrupt Control */ +#define REG_EIC_NMIFLAG (*(RwReg8 *)0x40001803U) /**< \brief (EIC) Non-Maskable Interrupt Flag Status and Clear */ +#define REG_EIC_EVCTRL (*(RwReg *)0x40001804U) /**< \brief (EIC) Event Control */ +#define REG_EIC_INTENCLR (*(RwReg *)0x40001808U) /**< \brief (EIC) Interrupt Enable Clear */ +#define REG_EIC_INTENSET (*(RwReg *)0x4000180CU) /**< \brief (EIC) Interrupt Enable Set */ +#define REG_EIC_INTFLAG (*(RwReg *)0x40001810U) /**< \brief (EIC) Interrupt Flag Status and Clear */ +#define REG_EIC_WAKEUP (*(RwReg *)0x40001814U) /**< \brief (EIC) Wake-Up Enable */ +#define REG_EIC_CONFIG0 (*(RwReg *)0x40001818U) /**< \brief (EIC) Configuration 0 */ +#define REG_EIC_CONFIG1 (*(RwReg *)0x4000181CU) /**< \brief (EIC) Configuration 1 */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for EIC peripheral ========== */ +#define EIC_CONFIG_NUM ((EIC_EXTINT_NUM+7)/8) +#define EIC_GCLK_ID 5 + +#endif /* _SAMD21_EIC_INSTANCE_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/evsys.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/evsys.h new file mode 100644 index 0000000..ae16ead --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/evsys.h @@ -0,0 +1,197 @@ +/** + * \file + * + * \brief Instance description for EVSYS + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_EVSYS_INSTANCE_ +#define _SAMD21_EVSYS_INSTANCE_ + +/* ========== Register definition for EVSYS peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_EVSYS_CTRL (0x42000400U) /**< \brief (EVSYS) Control */ +#define REG_EVSYS_CHANNEL (0x42000404U) /**< \brief (EVSYS) Channel */ +#define REG_EVSYS_USER (0x42000408U) /**< \brief (EVSYS) User Multiplexer */ +#define REG_EVSYS_CHSTATUS (0x4200040CU) /**< \brief (EVSYS) Channel Status */ +#define REG_EVSYS_INTENCLR (0x42000410U) /**< \brief (EVSYS) Interrupt Enable Clear */ +#define REG_EVSYS_INTENSET (0x42000414U) /**< \brief (EVSYS) Interrupt Enable Set */ +#define REG_EVSYS_INTFLAG (0x42000418U) /**< \brief (EVSYS) Interrupt Flag Status and Clear */ +#else +#define REG_EVSYS_CTRL (*(WoReg8 *)0x42000400U) /**< \brief (EVSYS) Control */ +#define REG_EVSYS_CHANNEL (*(RwReg *)0x42000404U) /**< \brief (EVSYS) Channel */ +#define REG_EVSYS_USER (*(RwReg16*)0x42000408U) /**< \brief (EVSYS) User Multiplexer */ +#define REG_EVSYS_CHSTATUS (*(RoReg *)0x4200040CU) /**< \brief (EVSYS) Channel Status */ +#define REG_EVSYS_INTENCLR (*(RwReg *)0x42000410U) /**< \brief (EVSYS) Interrupt Enable Clear */ +#define REG_EVSYS_INTENSET (*(RwReg *)0x42000414U) /**< \brief (EVSYS) Interrupt Enable Set */ +#define REG_EVSYS_INTFLAG (*(RwReg *)0x42000418U) /**< \brief (EVSYS) Interrupt Flag Status and Clear */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for EVSYS peripheral ========== */ +#define EVSYS_CHANNELS 12 +#define EVSYS_CHANNELS_BITS (len(bin(EVSYS_CHANNELS-1))-2) +#define EVSYS_CHANNELS_MSB (EVSYS_CHANNELS-1) +#define EVSYS_EXTEVT_NUM 0 +#define EVSYS_GCLK_ID_0 7 +#define EVSYS_GCLK_ID_1 8 +#define EVSYS_GCLK_ID_2 9 +#define EVSYS_GCLK_ID_3 10 +#define EVSYS_GCLK_ID_4 11 +#define EVSYS_GCLK_ID_5 12 +#define EVSYS_GCLK_ID_6 13 +#define EVSYS_GCLK_ID_7 14 +#define EVSYS_GCLK_ID_8 15 +#define EVSYS_GCLK_ID_9 16 +#define EVSYS_GCLK_ID_10 17 +#define EVSYS_GCLK_ID_11 18 +#define EVSYS_GCLK_ID_LSB 7 +#define EVSYS_GCLK_ID_MSB 18 +#define EVSYS_GCLK_ID_SIZE 12 +#define EVSYS_GENERATORS 73 +#define EVSYS_GENERATORS_BITS (len(bin(EVSYS_GENERATORS-1))-2) +#define EVSYS_USERS 29 +#define EVSYS_USERS_BITS (len(bin(EVSYS_USERS-1))-2) + +// GENERATORS +#define EVSYS_ID_GEN_RTC_CMP_0 1 +#define EVSYS_ID_GEN_RTC_CMP_1 2 +#define EVSYS_ID_GEN_RTC_OVF 3 +#define EVSYS_ID_GEN_RTC_PER_0 4 +#define EVSYS_ID_GEN_RTC_PER_1 5 +#define EVSYS_ID_GEN_RTC_PER_2 6 +#define EVSYS_ID_GEN_RTC_PER_3 7 +#define EVSYS_ID_GEN_RTC_PER_4 8 +#define EVSYS_ID_GEN_RTC_PER_5 9 +#define EVSYS_ID_GEN_RTC_PER_6 10 +#define EVSYS_ID_GEN_RTC_PER_7 11 +#define EVSYS_ID_GEN_EIC_EXTINT_0 12 +#define EVSYS_ID_GEN_EIC_EXTINT_1 13 +#define EVSYS_ID_GEN_EIC_EXTINT_2 14 +#define EVSYS_ID_GEN_EIC_EXTINT_3 15 +#define EVSYS_ID_GEN_EIC_EXTINT_4 16 +#define EVSYS_ID_GEN_EIC_EXTINT_5 17 +#define EVSYS_ID_GEN_EIC_EXTINT_6 18 +#define EVSYS_ID_GEN_EIC_EXTINT_7 19 +#define EVSYS_ID_GEN_EIC_EXTINT_8 20 +#define EVSYS_ID_GEN_EIC_EXTINT_9 21 +#define EVSYS_ID_GEN_EIC_EXTINT_10 22 +#define EVSYS_ID_GEN_EIC_EXTINT_11 23 +#define EVSYS_ID_GEN_EIC_EXTINT_12 24 +#define EVSYS_ID_GEN_EIC_EXTINT_13 25 +#define EVSYS_ID_GEN_EIC_EXTINT_14 26 +#define EVSYS_ID_GEN_EIC_EXTINT_15 27 +#define EVSYS_ID_GEN_EIC_EXTINT_16 28 +#define EVSYS_ID_GEN_EIC_EXTINT_17 29 +#define EVSYS_ID_GEN_DMAC_CH_0 30 +#define EVSYS_ID_GEN_DMAC_CH_1 31 +#define EVSYS_ID_GEN_DMAC_CH_2 32 +#define EVSYS_ID_GEN_DMAC_CH_3 33 +#define EVSYS_ID_GEN_TCC0_OVF 34 +#define EVSYS_ID_GEN_TCC0_TRG 35 +#define EVSYS_ID_GEN_TCC0_CNT 36 +#define EVSYS_ID_GEN_TCC0_MCX_0 37 +#define EVSYS_ID_GEN_TCC0_MCX_1 38 +#define EVSYS_ID_GEN_TCC0_MCX_2 39 +#define EVSYS_ID_GEN_TCC0_MCX_3 40 +#define EVSYS_ID_GEN_TCC1_OVF 41 +#define EVSYS_ID_GEN_TCC1_TRG 42 +#define EVSYS_ID_GEN_TCC1_CNT 43 +#define EVSYS_ID_GEN_TCC1_MCX_0 44 +#define EVSYS_ID_GEN_TCC1_MCX_1 45 +#define EVSYS_ID_GEN_TCC2_OVF 46 +#define EVSYS_ID_GEN_TCC2_TRG 47 +#define EVSYS_ID_GEN_TCC2_CNT 48 +#define EVSYS_ID_GEN_TCC2_MCX_0 49 +#define EVSYS_ID_GEN_TCC2_MCX_1 50 +#define EVSYS_ID_GEN_TC3_OVF 51 +#define EVSYS_ID_GEN_TC3_MCX_0 52 +#define EVSYS_ID_GEN_TC3_MCX_1 53 +#define EVSYS_ID_GEN_TC4_OVF 54 +#define EVSYS_ID_GEN_TC4_MCX_0 55 +#define EVSYS_ID_GEN_TC4_MCX_1 56 +#define EVSYS_ID_GEN_TC5_OVF 57 +#define EVSYS_ID_GEN_TC5_MCX_0 58 +#define EVSYS_ID_GEN_TC5_MCX_1 59 +#define EVSYS_ID_GEN_TC6_OVF 60 +#define EVSYS_ID_GEN_TC6_MCX_0 61 +#define EVSYS_ID_GEN_TC6_MCX_1 62 +#define EVSYS_ID_GEN_TC7_OVF 63 +#define EVSYS_ID_GEN_TC7_MCX_0 64 +#define EVSYS_ID_GEN_TC7_MCX_1 65 +#define EVSYS_ID_GEN_ADC_RESRDY 66 +#define EVSYS_ID_GEN_ADC_WINMON 67 +#define EVSYS_ID_GEN_AC_COMP_0 68 +#define EVSYS_ID_GEN_AC_COMP_1 69 +#define EVSYS_ID_GEN_AC_WIN_0 70 +#define EVSYS_ID_GEN_DAC_EMPTY 71 +#define EVSYS_ID_GEN_PTC_EOC 72 +#define EVSYS_ID_GEN_PTC_WCOMP 73 + +// USERS +#define EVSYS_ID_USER_DMAC_CH_0 0 +#define EVSYS_ID_USER_DMAC_CH_1 1 +#define EVSYS_ID_USER_DMAC_CH_2 2 +#define EVSYS_ID_USER_DMAC_CH_3 3 +#define EVSYS_ID_USER_TCC0_EV_0 4 +#define EVSYS_ID_USER_TCC0_EV_1 5 +#define EVSYS_ID_USER_TCC0_MC_0 6 +#define EVSYS_ID_USER_TCC0_MC_1 7 +#define EVSYS_ID_USER_TCC0_MC_2 8 +#define EVSYS_ID_USER_TCC0_MC_3 9 +#define EVSYS_ID_USER_TCC1_EV_0 10 +#define EVSYS_ID_USER_TCC1_EV_1 11 +#define EVSYS_ID_USER_TCC1_MC_0 12 +#define EVSYS_ID_USER_TCC1_MC_1 13 +#define EVSYS_ID_USER_TCC2_EV_0 14 +#define EVSYS_ID_USER_TCC2_EV_1 15 +#define EVSYS_ID_USER_TCC2_MC_0 16 +#define EVSYS_ID_USER_TCC2_MC_1 17 +#define EVSYS_ID_USER_TC3_EVU 18 +#define EVSYS_ID_USER_TC4_EVU 19 +#define EVSYS_ID_USER_TC5_EVU 20 +#define EVSYS_ID_USER_TC6_EVU 21 +#define EVSYS_ID_USER_TC7_EVU 22 +#define EVSYS_ID_USER_ADC_START 23 +#define EVSYS_ID_USER_ADC_SYNC 24 +#define EVSYS_ID_USER_AC_SOC_0 25 +#define EVSYS_ID_USER_AC_SOC_1 26 +#define EVSYS_ID_USER_DAC_START 27 +#define EVSYS_ID_USER_PTC_STCONV 28 + +#endif /* _SAMD21_EVSYS_INSTANCE_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/gclk.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/gclk.h new file mode 100644 index 0000000..4c7cda5 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/gclk.h @@ -0,0 +1,79 @@ +/** + * \file + * + * \brief Instance description for GCLK + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_GCLK_INSTANCE_ +#define _SAMD21_GCLK_INSTANCE_ + +/* ========== Register definition for GCLK peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_GCLK_CTRL (0x40000C00U) /**< \brief (GCLK) Control */ +#define REG_GCLK_STATUS (0x40000C01U) /**< \brief (GCLK) Status */ +#define REG_GCLK_CLKCTRL (0x40000C02U) /**< \brief (GCLK) Generic Clock Control */ +#define REG_GCLK_GENCTRL (0x40000C04U) /**< \brief (GCLK) Generic Clock Generator Control */ +#define REG_GCLK_GENDIV (0x40000C08U) /**< \brief (GCLK) Generic Clock Generator Division */ +#else +#define REG_GCLK_CTRL (*(RwReg8 *)0x40000C00U) /**< \brief (GCLK) Control */ +#define REG_GCLK_STATUS (*(RoReg8 *)0x40000C01U) /**< \brief (GCLK) Status */ +#define REG_GCLK_CLKCTRL (*(RwReg16*)0x40000C02U) /**< \brief (GCLK) Generic Clock Control */ +#define REG_GCLK_GENCTRL (*(RwReg *)0x40000C04U) /**< \brief (GCLK) Generic Clock Generator Control */ +#define REG_GCLK_GENDIV (*(RwReg *)0x40000C08U) /**< \brief (GCLK) Generic Clock Generator Division */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for GCLK peripheral ========== */ +#define GCLK_GENDIV_BITS 16 +#define GCLK_GEN_NUM 9 +#define GCLK_GEN_NUM_MSB (GCLK_GEN_NUM-1) +#define GCLK_GEN_SOURCE_NUM_MSB (GCLK_SOURCE_NUM-1) +#define GCLK_NUM 37 +#define GCLK_SOURCE_DFLL48M 7 +#define GCLK_SOURCE_FDPLL 8 +#define GCLK_SOURCE_GCLKGEN1 2 +#define GCLK_SOURCE_GCLKIN 1 +#define GCLK_SOURCE_NUM 9 +#define GCLK_SOURCE_OSCULP32K 3 +#define GCLK_SOURCE_OSC8M 6 +#define GCLK_SOURCE_OSC32K 4 +#define GCLK_SOURCE_XOSC 0 +#define GCLK_SOURCE_XOSC32K 5 + +#endif /* _SAMD21_GCLK_INSTANCE_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/i2s.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/i2s.h new file mode 100644 index 0000000..b52062a --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/i2s.h @@ -0,0 +1,94 @@ +/** + * \file + * + * \brief Instance description for I2S + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_I2S_INSTANCE_ +#define _SAMD21_I2S_INSTANCE_ + +/* ========== Register definition for I2S peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_I2S_CTRLA (0x42005000U) /**< \brief (I2S) Control A */ +#define REG_I2S_CLKCTRL0 (0x42005004U) /**< \brief (I2S) Clock Unit 0 Control */ +#define REG_I2S_CLKCTRL1 (0x42005008U) /**< \brief (I2S) Clock Unit 1 Control */ +#define REG_I2S_INTENCLR (0x4200500CU) /**< \brief (I2S) Interrupt Enable Clear */ +#define REG_I2S_INTENSET (0x42005010U) /**< \brief (I2S) Interrupt Enable Set */ +#define REG_I2S_INTFLAG (0x42005014U) /**< \brief (I2S) Interrupt Flag Status and Clear */ +#define REG_I2S_SYNCBUSY (0x42005018U) /**< \brief (I2S) Synchronization Status */ +#define REG_I2S_SERCTRL0 (0x42005020U) /**< \brief (I2S) Serializer 0 Control */ +#define REG_I2S_SERCTRL1 (0x42005024U) /**< \brief (I2S) Serializer 1 Control */ +#define REG_I2S_DATA0 (0x42005030U) /**< \brief (I2S) Data 0 */ +#define REG_I2S_DATA1 (0x42005034U) /**< \brief (I2S) Data 1 */ +#else +#define REG_I2S_CTRLA (*(RwReg8 *)0x42005000U) /**< \brief (I2S) Control A */ +#define REG_I2S_CLKCTRL0 (*(RwReg *)0x42005004U) /**< \brief (I2S) Clock Unit 0 Control */ +#define REG_I2S_CLKCTRL1 (*(RwReg *)0x42005008U) /**< \brief (I2S) Clock Unit 1 Control */ +#define REG_I2S_INTENCLR (*(RwReg16*)0x4200500CU) /**< \brief (I2S) Interrupt Enable Clear */ +#define REG_I2S_INTENSET (*(RwReg16*)0x42005010U) /**< \brief (I2S) Interrupt Enable Set */ +#define REG_I2S_INTFLAG (*(RwReg16*)0x42005014U) /**< \brief (I2S) Interrupt Flag Status and Clear */ +#define REG_I2S_SYNCBUSY (*(RoReg16*)0x42005018U) /**< \brief (I2S) Synchronization Status */ +#define REG_I2S_SERCTRL0 (*(RwReg *)0x42005020U) /**< \brief (I2S) Serializer 0 Control */ +#define REG_I2S_SERCTRL1 (*(RwReg *)0x42005024U) /**< \brief (I2S) Serializer 1 Control */ +#define REG_I2S_DATA0 (*(RwReg *)0x42005030U) /**< \brief (I2S) Data 0 */ +#define REG_I2S_DATA1 (*(RwReg *)0x42005034U) /**< \brief (I2S) Data 1 */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for I2S peripheral ========== */ +#define I2S_CLK_NUM 2 +#define I2S_DMAC_ID_RX_0 41 +#define I2S_DMAC_ID_RX_1 42 +#define I2S_DMAC_ID_RX_LSB 41 +#define I2S_DMAC_ID_RX_MSB 42 +#define I2S_DMAC_ID_RX_SIZE 2 +#define I2S_DMAC_ID_TX_0 43 +#define I2S_DMAC_ID_TX_1 44 +#define I2S_DMAC_ID_TX_LSB 43 +#define I2S_DMAC_ID_TX_MSB 44 +#define I2S_DMAC_ID_TX_SIZE 2 +#define I2S_GCLK_ID_0 35 +#define I2S_GCLK_ID_1 36 +#define I2S_GCLK_ID_LSB 35 +#define I2S_GCLK_ID_MSB 36 +#define I2S_GCLK_ID_SIZE 2 +#define I2S_MAX_SLOTS 8 +#define I2S_SER_NUM 2 + +#endif /* _SAMD21_I2S_INSTANCE_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/mtb.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/mtb.h new file mode 100644 index 0000000..d996ba2 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/mtb.h @@ -0,0 +1,103 @@ +/** + * \file + * + * \brief Instance description for MTB + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_MTB_INSTANCE_ +#define _SAMD21_MTB_INSTANCE_ + +/* ========== Register definition for MTB peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_MTB_POSITION (0x41006000U) /**< \brief (MTB) MTB Position */ +#define REG_MTB_MASTER (0x41006004U) /**< \brief (MTB) MTB Master */ +#define REG_MTB_FLOW (0x41006008U) /**< \brief (MTB) MTB Flow */ +#define REG_MTB_BASE (0x4100600CU) /**< \brief (MTB) MTB Base */ +#define REG_MTB_ITCTRL (0x41006F00U) /**< \brief (MTB) MTB Integration Mode Control */ +#define REG_MTB_CLAIMSET (0x41006FA0U) /**< \brief (MTB) MTB Claim Set */ +#define REG_MTB_CLAIMCLR (0x41006FA4U) /**< \brief (MTB) MTB Claim Clear */ +#define REG_MTB_LOCKACCESS (0x41006FB0U) /**< \brief (MTB) MTB Lock Access */ +#define REG_MTB_LOCKSTATUS (0x41006FB4U) /**< \brief (MTB) MTB Lock Status */ +#define REG_MTB_AUTHSTATUS (0x41006FB8U) /**< \brief (MTB) MTB Authentication Status */ +#define REG_MTB_DEVARCH (0x41006FBCU) /**< \brief (MTB) MTB Device Architecture */ +#define REG_MTB_DEVID (0x41006FC8U) /**< \brief (MTB) MTB Device Configuration */ +#define REG_MTB_DEVTYPE (0x41006FCCU) /**< \brief (MTB) MTB Device Type */ +#define REG_MTB_PID4 (0x41006FD0U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID5 (0x41006FD4U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID6 (0x41006FD8U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID7 (0x41006FDCU) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID0 (0x41006FE0U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID1 (0x41006FE4U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID2 (0x41006FE8U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID3 (0x41006FECU) /**< \brief (MTB) CoreSight */ +#define REG_MTB_CID0 (0x41006FF0U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_CID1 (0x41006FF4U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_CID2 (0x41006FF8U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_CID3 (0x41006FFCU) /**< \brief (MTB) CoreSight */ +#else +#define REG_MTB_POSITION (*(RwReg *)0x41006000U) /**< \brief (MTB) MTB Position */ +#define REG_MTB_MASTER (*(RwReg *)0x41006004U) /**< \brief (MTB) MTB Master */ +#define REG_MTB_FLOW (*(RwReg *)0x41006008U) /**< \brief (MTB) MTB Flow */ +#define REG_MTB_BASE (*(RoReg *)0x4100600CU) /**< \brief (MTB) MTB Base */ +#define REG_MTB_ITCTRL (*(RwReg *)0x41006F00U) /**< \brief (MTB) MTB Integration Mode Control */ +#define REG_MTB_CLAIMSET (*(RwReg *)0x41006FA0U) /**< \brief (MTB) MTB Claim Set */ +#define REG_MTB_CLAIMCLR (*(RwReg *)0x41006FA4U) /**< \brief (MTB) MTB Claim Clear */ +#define REG_MTB_LOCKACCESS (*(RwReg *)0x41006FB0U) /**< \brief (MTB) MTB Lock Access */ +#define REG_MTB_LOCKSTATUS (*(RoReg *)0x41006FB4U) /**< \brief (MTB) MTB Lock Status */ +#define REG_MTB_AUTHSTATUS (*(RoReg *)0x41006FB8U) /**< \brief (MTB) MTB Authentication Status */ +#define REG_MTB_DEVARCH (*(RoReg *)0x41006FBCU) /**< \brief (MTB) MTB Device Architecture */ +#define REG_MTB_DEVID (*(RoReg *)0x41006FC8U) /**< \brief (MTB) MTB Device Configuration */ +#define REG_MTB_DEVTYPE (*(RoReg *)0x41006FCCU) /**< \brief (MTB) MTB Device Type */ +#define REG_MTB_PID4 (*(RoReg *)0x41006FD0U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID5 (*(RoReg *)0x41006FD4U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID6 (*(RoReg *)0x41006FD8U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID7 (*(RoReg *)0x41006FDCU) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID0 (*(RoReg *)0x41006FE0U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID1 (*(RoReg *)0x41006FE4U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID2 (*(RoReg *)0x41006FE8U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID3 (*(RoReg *)0x41006FECU) /**< \brief (MTB) CoreSight */ +#define REG_MTB_CID0 (*(RoReg *)0x41006FF0U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_CID1 (*(RoReg *)0x41006FF4U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_CID2 (*(RoReg *)0x41006FF8U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_CID3 (*(RoReg *)0x41006FFCU) /**< \brief (MTB) CoreSight */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + + +#endif /* _SAMD21_MTB_INSTANCE_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/nvmctrl.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/nvmctrl.h new file mode 100644 index 0000000..fc44048 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/instance/nvmctrl.h @@ -0,0 +1,92 @@ +/** + * \file + * + * \brief Instance description for NVMCTRL + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_NVMCTRL_INSTANCE_ +#define _SAMD21_NVMCTRL_INSTANCE_ + +/* ========== Register definition for NVMCTRL peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_NVMCTRL_CTRLA (0x41004000U) /**< \brief (NVMCTRL) Control A */ +#define REG_NVMCTRL_CTRLB (0x41004004U) /**< \brief (NVMCTRL) Control B */ +#define REG_NVMCTRL_PARAM (0x41004008U) /**< \brief (NVMCTRL) NVM Parameter */ +#define REG_NVMCTRL_INTENCLR (0x4100400CU) /**< \brief (NVMCTRL) Interrupt Enable Clear */ +#define REG_NVMCTRL_INTENSET (0x41004010U) /**< \brief (NVMCTRL) Interrupt Enable Set */ +#define REG_NVMCTRL_INTFLAG (0x41004014U) /**< \brief (NVMCTRL) Interrupt Flag Status and Clear */ +#define REG_NVMCTRL_STATUS (0x41004018U) /**< \brief (NVMCTRL) Status */ +#define REG_NVMCTRL_ADDR (0x4100401CU) /**< \brief (NVMCTRL) Address */ +#define REG_NVMCTRL_LOCK (0x41004020U) /**< \brief (NVMCTRL) Lock Section */ +#else +#define REG_NVMCTRL_CTRLA (*(RwReg16*)0x41004000U) /**< \brief (NVMCTRL) Control A */ +#define REG_NVMCTRL_CTRLB (*(RwReg *)0x41004004U) /**< \brief (NVMCTRL) Control B */ +#define REG_NVMCTRL_PARAM (*(RwReg *)0x41004008U) /**< \brief (NVMCTRL) NVM Parameter */ +#define REG_NVMCTRL_INTENCLR (*(RwReg8 *)0x4100400CU) /**< \brief (NVMCTRL) Interrupt Enable Clear */ +#define REG_NVMCTRL_INTENSET (*(RwReg8 *)0x41004010U) /**< \brief (NVMCTRL) Interrupt Enable Set */ +#define REG_NVMCTRL_INTFLAG (*(RwReg8 *)0x41004014U) /**< \brief (NVMCTRL) Interrupt Flag Status and Clear */ +#define REG_NVMCTRL_STATUS (*(RwReg16*)0x41004018U) /**< \brief (NVMCTRL) Status */ +#define REG_NVMCTRL_ADDR (*(RwReg *)0x4100401CU) /**< \brief (NVMCTRL) Address */ +#define REG_NVMCTRL_LOCK (*(RwReg16*)0x41004020U) /**< \brief (NVMCTRL) Lock Section */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for NVMCTRL peripheral ========== */ +#define NVMCTRL_AUX0_ADDRESS (NVMCTRL_USER_PAGE_ADDRESS + 0x00004000) +#define NVMCTRL_AUX1_ADDRESS (NVMCTRL_USER_PAGE_ADDRESS + 0x00006000) +#define NVMCTRL_AUX2_ADDRESS (NVMCTRL_USER_PAGE_ADDRESS + 0x00008000) +#define NVMCTRL_AUX3_ADDRESS (NVMCTRL_USER_PAGE_ADDRESS + 0x0000A000) +#define NVMCTRL_CLK_AHB_ID 4 +#define NVMCTRL_FACTORY_WORD_IMPLEMENTED_MASK 0xC0000007FFFFFFFF +#define NVMCTRL_FLASH_SIZE (NVMCTRL_PAGES*NVMCTRL_PAGE_SIZE) +#define NVMCTRL_LOCKBIT_ADDRESS (NVMCTRL_USER_PAGE_ADDRESS + 0x00002000) +#define NVMCTRL_PAGES 4096 +#define NVMCTRL_PAGE_HW (NVMCTRL_PAGE_SIZE/2) +#define NVMCTRL_PAGE_SIZE (1< +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21E15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E15A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21E15A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21E15A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21E15A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21E15A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21E15A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21E15A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21E15A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21E15A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21E15A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21E15A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21E15A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21E15A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21E15A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21E15A Serial Communication Interface 3 (SERCOM3) */ + TCC0_IRQn = 15, /**< 15 SAMD21E15A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21E15A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21E15A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21E15A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21E15A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21E15A Basic Timer Counter 5 (TC5) */ + ADC_IRQn = 23, /**< 23 SAMD21E15A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21E15A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21E15A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21E15A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21E15A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnReserved13; + void* pfnReserved14; + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnReserved21; + void* pfnReserved22; + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21E15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E15A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21E15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E15A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21E15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E15A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21E15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E15A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM_INST_NUM 4 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC_INST_NUM 3 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21E15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E15A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21e15a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21E15A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x8000 /* 32 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 512 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x1000 /* 4 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x1001000D +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 1 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21E15A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21E15A_H */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21e16a.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21e16a.h new file mode 100644 index 0000000..06bc201 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21e16a.h @@ -0,0 +1,543 @@ +/** + * \file + * + * \brief Header file for SAMD21E16A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21E16A_ +#define _SAMD21E16A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21E16A_definitions SAMD21E16A definitions + * This file defines all structures and symbols for SAMD21E16A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21E16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E16A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21E16A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21E16A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21E16A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21E16A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21E16A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21E16A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21E16A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21E16A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21E16A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21E16A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21E16A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21E16A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21E16A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21E16A Serial Communication Interface 3 (SERCOM3) */ + TCC0_IRQn = 15, /**< 15 SAMD21E16A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21E16A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21E16A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21E16A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21E16A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21E16A Basic Timer Counter 5 (TC5) */ + ADC_IRQn = 23, /**< 23 SAMD21E16A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21E16A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21E16A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21E16A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21E16A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnReserved13; + void* pfnReserved14; + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnReserved21; + void* pfnReserved22; + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21E16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E16A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21E16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E16A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21E16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E16A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21E16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E16A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM_INST_NUM 4 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC_INST_NUM 3 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21E16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E16A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21e16a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21E16A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x10000 /* 64 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 1024 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x2000 /* 8 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x1001000C +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 1 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21E16A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21E16A_H */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21e17a.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21e17a.h new file mode 100644 index 0000000..ab17fbe --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21e17a.h @@ -0,0 +1,543 @@ +/** + * \file + * + * \brief Header file for SAMD21E17A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21E17A_ +#define _SAMD21E17A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21E17A_definitions SAMD21E17A definitions + * This file defines all structures and symbols for SAMD21E17A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21E17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E17A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21E17A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21E17A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21E17A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21E17A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21E17A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21E17A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21E17A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21E17A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21E17A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21E17A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21E17A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21E17A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21E17A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21E17A Serial Communication Interface 3 (SERCOM3) */ + TCC0_IRQn = 15, /**< 15 SAMD21E17A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21E17A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21E17A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21E17A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21E17A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21E17A Basic Timer Counter 5 (TC5) */ + ADC_IRQn = 23, /**< 23 SAMD21E17A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21E17A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21E17A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21E17A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21E17A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnReserved13; + void* pfnReserved14; + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnReserved21; + void* pfnReserved22; + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21E17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E17A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21E17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E17A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21E17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E17A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21E17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E17A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM_INST_NUM 4 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC_INST_NUM 3 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21E17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E17A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21e17a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21E17A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x20000 /* 128 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 2048 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x4000 /* 16 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x1001000B +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 1 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21E17A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21E17A_H */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21e18a.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21e18a.h new file mode 100644 index 0000000..df36c13 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21e18a.h @@ -0,0 +1,543 @@ +/** + * \file + * + * \brief Header file for SAMD21E18A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21E18A_ +#define _SAMD21E18A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21E18A_definitions SAMD21E18A definitions + * This file defines all structures and symbols for SAMD21E18A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21E18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E18A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21E18A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21E18A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21E18A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21E18A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21E18A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21E18A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21E18A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21E18A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21E18A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21E18A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21E18A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21E18A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21E18A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21E18A Serial Communication Interface 3 (SERCOM3) */ + TCC0_IRQn = 15, /**< 15 SAMD21E18A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21E18A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21E18A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21E18A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21E18A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21E18A Basic Timer Counter 5 (TC5) */ + ADC_IRQn = 23, /**< 23 SAMD21E18A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21E18A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21E18A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21E18A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21E18A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnReserved13; + void* pfnReserved14; + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnReserved21; + void* pfnReserved22; + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21E18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E18A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21E18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E18A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21E18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E18A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21E18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E18A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM_INST_NUM 4 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC_INST_NUM 3 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21E18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E18A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21e18a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21E18A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x40000 /* 256 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 4096 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x8000 /* 32 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x1001000A +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 1 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21E18A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21E18A_H */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21g15a.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21g15a.h new file mode 100644 index 0000000..c8b43b4 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21g15a.h @@ -0,0 +1,555 @@ +/** + * \file + * + * \brief Header file for SAMD21G15A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21G15A_ +#define _SAMD21G15A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21G15A_definitions SAMD21G15A definitions + * This file defines all structures and symbols for SAMD21G15A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21G15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G15A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21G15A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21G15A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21G15A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21G15A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21G15A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21G15A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21G15A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21G15A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21G15A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21G15A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21G15A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21G15A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21G15A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21G15A Serial Communication Interface 3 (SERCOM3) */ + SERCOM4_IRQn = 13, /**< 13 SAMD21G15A Serial Communication Interface 4 (SERCOM4) */ + SERCOM5_IRQn = 14, /**< 14 SAMD21G15A Serial Communication Interface 5 (SERCOM5) */ + TCC0_IRQn = 15, /**< 15 SAMD21G15A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21G15A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21G15A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21G15A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21G15A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21G15A Basic Timer Counter 5 (TC5) */ + ADC_IRQn = 23, /**< 23 SAMD21G15A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21G15A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21G15A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21G15A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21G15A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnSERCOM4_Handler; /* 13 Serial Communication Interface 4 */ + void* pfnSERCOM5_Handler; /* 14 Serial Communication Interface 5 */ + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnReserved21; + void* pfnReserved22; + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void SERCOM4_Handler ( void ); +void SERCOM5_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21G15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G15A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21G15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G15A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sercom4.h" +#include "instance/sercom5.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21G15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G15A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_SERCOM4 70 /**< \brief Serial Communication Interface SERCOM (SERCOM4) */ +#define ID_SERCOM5 71 /**< \brief Serial Communication Interface SERCOM (SERCOM5) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21G15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G15A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 (0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 (0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 ((Sercom *)0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 ((Sercom *)0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SERCOM_INST_NUM 6 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3, SERCOM4, SERCOM5 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC_INST_NUM 3 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21G15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G15A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21g15a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21G15A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x8000 /* 32 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 512 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x1000 /* 4 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x10010008 +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 2 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21G15A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21G15A_H */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21g16a.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21g16a.h new file mode 100644 index 0000000..ee3957b --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21g16a.h @@ -0,0 +1,555 @@ +/** + * \file + * + * \brief Header file for SAMD21G16A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21G16A_ +#define _SAMD21G16A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21G16A_definitions SAMD21G16A definitions + * This file defines all structures and symbols for SAMD21G16A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21G16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G16A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21G16A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21G16A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21G16A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21G16A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21G16A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21G16A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21G16A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21G16A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21G16A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21G16A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21G16A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21G16A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21G16A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21G16A Serial Communication Interface 3 (SERCOM3) */ + SERCOM4_IRQn = 13, /**< 13 SAMD21G16A Serial Communication Interface 4 (SERCOM4) */ + SERCOM5_IRQn = 14, /**< 14 SAMD21G16A Serial Communication Interface 5 (SERCOM5) */ + TCC0_IRQn = 15, /**< 15 SAMD21G16A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21G16A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21G16A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21G16A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21G16A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21G16A Basic Timer Counter 5 (TC5) */ + ADC_IRQn = 23, /**< 23 SAMD21G16A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21G16A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21G16A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21G16A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21G16A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnSERCOM4_Handler; /* 13 Serial Communication Interface 4 */ + void* pfnSERCOM5_Handler; /* 14 Serial Communication Interface 5 */ + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnReserved21; + void* pfnReserved22; + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void SERCOM4_Handler ( void ); +void SERCOM5_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21G16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G16A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21G16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G16A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sercom4.h" +#include "instance/sercom5.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21G16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G16A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_SERCOM4 70 /**< \brief Serial Communication Interface SERCOM (SERCOM4) */ +#define ID_SERCOM5 71 /**< \brief Serial Communication Interface SERCOM (SERCOM5) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21G16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G16A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 (0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 (0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 ((Sercom *)0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 ((Sercom *)0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SERCOM_INST_NUM 6 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3, SERCOM4, SERCOM5 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC_INST_NUM 3 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21G16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G16A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21g16a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21G16A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x10000 /* 64 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 1024 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x2000 /* 8 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x10010007 +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 2 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21G16A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21G16A_H */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21g17a.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21g17a.h new file mode 100644 index 0000000..ca2edaf --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21g17a.h @@ -0,0 +1,555 @@ +/** + * \file + * + * \brief Header file for SAMD21G17A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21G17A_ +#define _SAMD21G17A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21G17A_definitions SAMD21G17A definitions + * This file defines all structures and symbols for SAMD21G17A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21G17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G17A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21G17A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21G17A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21G17A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21G17A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21G17A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21G17A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21G17A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21G17A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21G17A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21G17A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21G17A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21G17A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21G17A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21G17A Serial Communication Interface 3 (SERCOM3) */ + SERCOM4_IRQn = 13, /**< 13 SAMD21G17A Serial Communication Interface 4 (SERCOM4) */ + SERCOM5_IRQn = 14, /**< 14 SAMD21G17A Serial Communication Interface 5 (SERCOM5) */ + TCC0_IRQn = 15, /**< 15 SAMD21G17A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21G17A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21G17A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21G17A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21G17A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21G17A Basic Timer Counter 5 (TC5) */ + ADC_IRQn = 23, /**< 23 SAMD21G17A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21G17A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21G17A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21G17A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21G17A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnSERCOM4_Handler; /* 13 Serial Communication Interface 4 */ + void* pfnSERCOM5_Handler; /* 14 Serial Communication Interface 5 */ + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnReserved21; + void* pfnReserved22; + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void SERCOM4_Handler ( void ); +void SERCOM5_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21G17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G17A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21G17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G17A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sercom4.h" +#include "instance/sercom5.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21G17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G17A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_SERCOM4 70 /**< \brief Serial Communication Interface SERCOM (SERCOM4) */ +#define ID_SERCOM5 71 /**< \brief Serial Communication Interface SERCOM (SERCOM5) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21G17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G17A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 (0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 (0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 ((Sercom *)0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 ((Sercom *)0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SERCOM_INST_NUM 6 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3, SERCOM4, SERCOM5 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC_INST_NUM 3 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21G17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G17A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21g17a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21G17A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x20000 /* 128 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 2048 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x4000 /* 16 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x10010006 +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 2 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21G17A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21G17A_H */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21g18a.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21g18a.h new file mode 100644 index 0000000..db9b3aa --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21g18a.h @@ -0,0 +1,555 @@ +/** + * \file + * + * \brief Header file for SAMD21G18A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21G18A_ +#define _SAMD21G18A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21G18A_definitions SAMD21G18A definitions + * This file defines all structures and symbols for SAMD21G18A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21G18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G18A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21G18A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21G18A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21G18A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21G18A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21G18A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21G18A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21G18A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21G18A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21G18A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21G18A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21G18A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21G18A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21G18A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21G18A Serial Communication Interface 3 (SERCOM3) */ + SERCOM4_IRQn = 13, /**< 13 SAMD21G18A Serial Communication Interface 4 (SERCOM4) */ + SERCOM5_IRQn = 14, /**< 14 SAMD21G18A Serial Communication Interface 5 (SERCOM5) */ + TCC0_IRQn = 15, /**< 15 SAMD21G18A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21G18A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21G18A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21G18A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21G18A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21G18A Basic Timer Counter 5 (TC5) */ + ADC_IRQn = 23, /**< 23 SAMD21G18A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21G18A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21G18A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21G18A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21G18A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnSERCOM4_Handler; /* 13 Serial Communication Interface 4 */ + void* pfnSERCOM5_Handler; /* 14 Serial Communication Interface 5 */ + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnReserved21; + void* pfnReserved22; + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void SERCOM4_Handler ( void ); +void SERCOM5_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21G18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G18A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21G18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G18A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sercom4.h" +#include "instance/sercom5.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21G18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G18A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_SERCOM4 70 /**< \brief Serial Communication Interface SERCOM (SERCOM4) */ +#define ID_SERCOM5 71 /**< \brief Serial Communication Interface SERCOM (SERCOM5) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21G18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G18A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 (0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 (0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 ((Sercom *)0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 ((Sercom *)0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SERCOM_INST_NUM 6 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3, SERCOM4, SERCOM5 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC_INST_NUM 3 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21G18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G18A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21g18a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21G18A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x40000 /* 256 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 4096 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x8000 /* 32 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x10010005 +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 2 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21G18A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21G18A_H */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21j15a.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21j15a.h new file mode 100644 index 0000000..65dd3f4 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21j15a.h @@ -0,0 +1,567 @@ +/** + * \file + * + * \brief Header file for SAMD21J15A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21J15A_ +#define _SAMD21J15A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21J15A_definitions SAMD21J15A definitions + * This file defines all structures and symbols for SAMD21J15A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21J15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J15A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21J15A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21J15A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21J15A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21J15A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21J15A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21J15A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21J15A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21J15A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21J15A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21J15A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21J15A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21J15A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21J15A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21J15A Serial Communication Interface 3 (SERCOM3) */ + SERCOM4_IRQn = 13, /**< 13 SAMD21J15A Serial Communication Interface 4 (SERCOM4) */ + SERCOM5_IRQn = 14, /**< 14 SAMD21J15A Serial Communication Interface 5 (SERCOM5) */ + TCC0_IRQn = 15, /**< 15 SAMD21J15A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21J15A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21J15A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21J15A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21J15A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21J15A Basic Timer Counter 5 (TC5) */ + TC6_IRQn = 21, /**< 21 SAMD21J15A Basic Timer Counter 6 (TC6) */ + TC7_IRQn = 22, /**< 22 SAMD21J15A Basic Timer Counter 7 (TC7) */ + ADC_IRQn = 23, /**< 23 SAMD21J15A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21J15A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21J15A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21J15A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21J15A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnSERCOM4_Handler; /* 13 Serial Communication Interface 4 */ + void* pfnSERCOM5_Handler; /* 14 Serial Communication Interface 5 */ + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnTC6_Handler; /* 21 Basic Timer Counter 6 */ + void* pfnTC7_Handler; /* 22 Basic Timer Counter 7 */ + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void SERCOM4_Handler ( void ); +void SERCOM5_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void TC6_Handler ( void ); +void TC7_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21J15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J15A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21J15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J15A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sercom4.h" +#include "instance/sercom5.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tc6.h" +#include "instance/tc7.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21J15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J15A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_SERCOM4 70 /**< \brief Serial Communication Interface SERCOM (SERCOM4) */ +#define ID_SERCOM5 71 /**< \brief Serial Communication Interface SERCOM (SERCOM5) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_TC6 78 /**< \brief Basic Timer Counter TC (TC6) */ +#define ID_TC7 79 /**< \brief Basic Timer Counter TC (TC7) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21J15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J15A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 (0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 (0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC6 (0x42003800U) /**< \brief (TC6) APB Base Address */ +#define TC7 (0x42003C00U) /**< \brief (TC7) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 ((Sercom *)0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 ((Sercom *)0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SERCOM_INST_NUM 6 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3, SERCOM4, SERCOM5 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC6 ((Tc *)0x42003800U) /**< \brief (TC6) APB Base Address */ +#define TC7 ((Tc *)0x42003C00U) /**< \brief (TC7) APB Base Address */ +#define TC_INST_NUM 5 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5, TC6, TC7 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21J15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J15A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21j15a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21J15A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x8000 /* 32 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 512 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x1000 /* 4 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x10010003 +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 2 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21J15A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21J15A_H */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21j16a.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21j16a.h new file mode 100644 index 0000000..4606c9e --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21j16a.h @@ -0,0 +1,567 @@ +/** + * \file + * + * \brief Header file for SAMD21J16A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21J16A_ +#define _SAMD21J16A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21J16A_definitions SAMD21J16A definitions + * This file defines all structures and symbols for SAMD21J16A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21J16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J16A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21J16A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21J16A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21J16A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21J16A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21J16A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21J16A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21J16A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21J16A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21J16A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21J16A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21J16A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21J16A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21J16A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21J16A Serial Communication Interface 3 (SERCOM3) */ + SERCOM4_IRQn = 13, /**< 13 SAMD21J16A Serial Communication Interface 4 (SERCOM4) */ + SERCOM5_IRQn = 14, /**< 14 SAMD21J16A Serial Communication Interface 5 (SERCOM5) */ + TCC0_IRQn = 15, /**< 15 SAMD21J16A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21J16A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21J16A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21J16A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21J16A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21J16A Basic Timer Counter 5 (TC5) */ + TC6_IRQn = 21, /**< 21 SAMD21J16A Basic Timer Counter 6 (TC6) */ + TC7_IRQn = 22, /**< 22 SAMD21J16A Basic Timer Counter 7 (TC7) */ + ADC_IRQn = 23, /**< 23 SAMD21J16A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21J16A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21J16A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21J16A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21J16A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnSERCOM4_Handler; /* 13 Serial Communication Interface 4 */ + void* pfnSERCOM5_Handler; /* 14 Serial Communication Interface 5 */ + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnTC6_Handler; /* 21 Basic Timer Counter 6 */ + void* pfnTC7_Handler; /* 22 Basic Timer Counter 7 */ + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void SERCOM4_Handler ( void ); +void SERCOM5_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void TC6_Handler ( void ); +void TC7_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21J16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J16A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21J16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J16A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sercom4.h" +#include "instance/sercom5.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tc6.h" +#include "instance/tc7.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21J16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J16A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_SERCOM4 70 /**< \brief Serial Communication Interface SERCOM (SERCOM4) */ +#define ID_SERCOM5 71 /**< \brief Serial Communication Interface SERCOM (SERCOM5) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_TC6 78 /**< \brief Basic Timer Counter TC (TC6) */ +#define ID_TC7 79 /**< \brief Basic Timer Counter TC (TC7) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21J16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J16A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 (0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 (0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC6 (0x42003800U) /**< \brief (TC6) APB Base Address */ +#define TC7 (0x42003C00U) /**< \brief (TC7) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 ((Sercom *)0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 ((Sercom *)0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SERCOM_INST_NUM 6 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3, SERCOM4, SERCOM5 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC6 ((Tc *)0x42003800U) /**< \brief (TC6) APB Base Address */ +#define TC7 ((Tc *)0x42003C00U) /**< \brief (TC7) APB Base Address */ +#define TC_INST_NUM 5 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5, TC6, TC7 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21J16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J16A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21j16a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21J16A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x10000 /* 64 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 1024 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x2000 /* 8 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x10010002 +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 2 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21J16A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21J16A_H */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21j17a.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21j17a.h new file mode 100644 index 0000000..69393f6 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21j17a.h @@ -0,0 +1,567 @@ +/** + * \file + * + * \brief Header file for SAMD21J17A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21J17A_ +#define _SAMD21J17A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21J17A_definitions SAMD21J17A definitions + * This file defines all structures and symbols for SAMD21J17A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21J17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J17A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21J17A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21J17A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21J17A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21J17A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21J17A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21J17A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21J17A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21J17A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21J17A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21J17A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21J17A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21J17A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21J17A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21J17A Serial Communication Interface 3 (SERCOM3) */ + SERCOM4_IRQn = 13, /**< 13 SAMD21J17A Serial Communication Interface 4 (SERCOM4) */ + SERCOM5_IRQn = 14, /**< 14 SAMD21J17A Serial Communication Interface 5 (SERCOM5) */ + TCC0_IRQn = 15, /**< 15 SAMD21J17A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21J17A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21J17A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21J17A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21J17A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21J17A Basic Timer Counter 5 (TC5) */ + TC6_IRQn = 21, /**< 21 SAMD21J17A Basic Timer Counter 6 (TC6) */ + TC7_IRQn = 22, /**< 22 SAMD21J17A Basic Timer Counter 7 (TC7) */ + ADC_IRQn = 23, /**< 23 SAMD21J17A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21J17A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21J17A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21J17A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21J17A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnSERCOM4_Handler; /* 13 Serial Communication Interface 4 */ + void* pfnSERCOM5_Handler; /* 14 Serial Communication Interface 5 */ + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnTC6_Handler; /* 21 Basic Timer Counter 6 */ + void* pfnTC7_Handler; /* 22 Basic Timer Counter 7 */ + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void SERCOM4_Handler ( void ); +void SERCOM5_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void TC6_Handler ( void ); +void TC7_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21J17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J17A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21J17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J17A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sercom4.h" +#include "instance/sercom5.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tc6.h" +#include "instance/tc7.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21J17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J17A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_SERCOM4 70 /**< \brief Serial Communication Interface SERCOM (SERCOM4) */ +#define ID_SERCOM5 71 /**< \brief Serial Communication Interface SERCOM (SERCOM5) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_TC6 78 /**< \brief Basic Timer Counter TC (TC6) */ +#define ID_TC7 79 /**< \brief Basic Timer Counter TC (TC7) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21J17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J17A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 (0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 (0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC6 (0x42003800U) /**< \brief (TC6) APB Base Address */ +#define TC7 (0x42003C00U) /**< \brief (TC7) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 ((Sercom *)0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 ((Sercom *)0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SERCOM_INST_NUM 6 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3, SERCOM4, SERCOM5 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC6 ((Tc *)0x42003800U) /**< \brief (TC6) APB Base Address */ +#define TC7 ((Tc *)0x42003C00U) /**< \brief (TC7) APB Base Address */ +#define TC_INST_NUM 5 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5, TC6, TC7 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21J17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J17A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21j17a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21J17A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x20000 /* 128 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 2048 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x4000 /* 16 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x10010001 +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 2 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21J17A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21J17A_H */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21j18a.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21j18a.h new file mode 100644 index 0000000..3f621f8 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/include/samd21j18a.h @@ -0,0 +1,567 @@ +/** + * \file + * + * \brief Header file for SAMD21J18A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21J18A_ +#define _SAMD21J18A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21J18A_definitions SAMD21J18A definitions + * This file defines all structures and symbols for SAMD21J18A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21J18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J18A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21J18A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21J18A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21J18A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21J18A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21J18A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21J18A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21J18A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21J18A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21J18A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21J18A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21J18A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21J18A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21J18A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21J18A Serial Communication Interface 3 (SERCOM3) */ + SERCOM4_IRQn = 13, /**< 13 SAMD21J18A Serial Communication Interface 4 (SERCOM4) */ + SERCOM5_IRQn = 14, /**< 14 SAMD21J18A Serial Communication Interface 5 (SERCOM5) */ + TCC0_IRQn = 15, /**< 15 SAMD21J18A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21J18A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21J18A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21J18A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21J18A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21J18A Basic Timer Counter 5 (TC5) */ + TC6_IRQn = 21, /**< 21 SAMD21J18A Basic Timer Counter 6 (TC6) */ + TC7_IRQn = 22, /**< 22 SAMD21J18A Basic Timer Counter 7 (TC7) */ + ADC_IRQn = 23, /**< 23 SAMD21J18A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21J18A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21J18A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21J18A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21J18A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnSERCOM4_Handler; /* 13 Serial Communication Interface 4 */ + void* pfnSERCOM5_Handler; /* 14 Serial Communication Interface 5 */ + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnTC6_Handler; /* 21 Basic Timer Counter 6 */ + void* pfnTC7_Handler; /* 22 Basic Timer Counter 7 */ + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void SERCOM4_Handler ( void ); +void SERCOM5_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void TC6_Handler ( void ); +void TC7_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21J18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J18A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21J18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J18A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sercom4.h" +#include "instance/sercom5.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tc6.h" +#include "instance/tc7.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21J18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J18A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_SERCOM4 70 /**< \brief Serial Communication Interface SERCOM (SERCOM4) */ +#define ID_SERCOM5 71 /**< \brief Serial Communication Interface SERCOM (SERCOM5) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_TC6 78 /**< \brief Basic Timer Counter TC (TC6) */ +#define ID_TC7 79 /**< \brief Basic Timer Counter TC (TC7) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21J18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J18A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 (0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 (0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC6 (0x42003800U) /**< \brief (TC6) APB Base Address */ +#define TC7 (0x42003C00U) /**< \brief (TC7) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 ((Sercom *)0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 ((Sercom *)0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SERCOM_INST_NUM 6 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3, SERCOM4, SERCOM5 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC6 ((Tc *)0x42003800U) /**< \brief (TC6) APB Base Address */ +#define TC7 ((Tc *)0x42003C00U) /**< \brief (TC7) APB Base Address */ +#define TC_INST_NUM 5 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5, TC6, TC7 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21J18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J18A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21j18a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21J18A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x40000 /* 256 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 4096 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x8000 /* 32 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x10010000 +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 2 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21J18A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21J18A_H */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/source/gcc/startup_samd21.c b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/source/gcc/startup_samd21.c new file mode 100644 index 0000000..43ec7c9 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/source/gcc/startup_samd21.c @@ -0,0 +1,201 @@ +/** + * \file + * + * \brief gcc starttup file for SAMD21 + * + * Copyright (c) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include "samd21.h" + +/* Initialize segments */ +extern uint32_t _sfixed; +extern uint32_t _efixed; +extern uint32_t _etext; +extern uint32_t _srelocate; +extern uint32_t _erelocate; +extern uint32_t _szero; +extern uint32_t _ezero; +extern uint32_t _sstack; +extern uint32_t _estack; + +/** \cond DOXYGEN_SHOULD_SKIP_THIS */ +int main(void); +/** \endcond */ + +void __libc_init_array(void); + +/* Default empty handler */ +void Dummy_Handler(void); + +/* Cortex-M0+ core handlers */ +void NMI_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void HardFault_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void SVC_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void PendSV_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void SysTick_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); + +/* Peripherals handlers */ +void PM_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void SYSCTRL_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void WDT_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void RTC_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void EIC_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void NVMCTRL_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void DMAC_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void USB_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void EVSYS_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void SERCOM0_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void SERCOM1_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void SERCOM2_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void SERCOM3_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void SERCOM4_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void SERCOM5_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void TCC0_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void TCC1_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void TCC2_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void TC3_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void TC4_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void TC5_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void TC6_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void TC7_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void ADC_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void AC_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void DAC_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void PTC_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void I2S_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); + +/* Exception Table */ +__attribute__ ((section(".vectors"))) +const DeviceVectors exception_table = { + + /* Configure Initial Stack Pointer, using linker-generated symbols */ + (void*) (&_estack), + + (void*) Reset_Handler, + (void*) NMI_Handler, + (void*) HardFault_Handler, + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) SVC_Handler, + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) PendSV_Handler, + (void*) SysTick_Handler, + + /* Configurable interrupts */ + (void*) PM_Handler, /* 0 Power Manager */ + (void*) SYSCTRL_Handler, /* 1 System Control */ + (void*) WDT_Handler, /* 2 Watchdog Timer */ + (void*) RTC_Handler, /* 3 Real-Time Counter */ + (void*) EIC_Handler, /* 4 External Interrupt Controller */ + (void*) NVMCTRL_Handler, /* 5 Non-Volatile Memory Controller */ + (void*) DMAC_Handler, /* 6 Direct Memory Access Controller */ + (void*) USB_Handler, /* 7 Universal Serial Bus */ + (void*) EVSYS_Handler, /* 8 Event System Interface */ + (void*) SERCOM0_Handler, /* 9 Serial Communication Interface 0 */ + (void*) SERCOM1_Handler, /* 10 Serial Communication Interface 1 */ + (void*) SERCOM2_Handler, /* 11 Serial Communication Interface 2 */ + (void*) SERCOM3_Handler, /* 12 Serial Communication Interface 3 */ + (void*) SERCOM4_Handler, /* 13 Serial Communication Interface 4 */ + (void*) SERCOM5_Handler, /* 14 Serial Communication Interface 5 */ + (void*) TCC0_Handler, /* 15 Timer Counter Control 0 */ + (void*) TCC1_Handler, /* 16 Timer Counter Control 1 */ + (void*) TCC2_Handler, /* 17 Timer Counter Control 2 */ + (void*) TC3_Handler, /* 18 Basic Timer Counter 0 */ + (void*) TC4_Handler, /* 19 Basic Timer Counter 1 */ + (void*) TC5_Handler, /* 20 Basic Timer Counter 2 */ + (void*) TC6_Handler, /* 21 Basic Timer Counter 3 */ + (void*) TC7_Handler, /* 22 Basic Timer Counter 4 */ + (void*) ADC_Handler, /* 23 Analog Digital Converter */ + (void*) AC_Handler, /* 24 Analog Comparators */ + (void*) DAC_Handler, /* 25 Digital Analog Converter */ + (void*) PTC_Handler, /* 26 Peripheral Touch Controller */ + (void*) I2S_Handler /* 27 Inter-IC Sound Interface */ +}; + +/** + * \brief This is the code that gets called on processor reset. + * To initialize the device, and call the main() routine. + */ +void Reset_Handler(void) +{ + uint32_t *pSrc, *pDest; + + /* Initialize the relocate segment */ + pSrc = &_etext; + pDest = &_srelocate; + + if (pSrc != pDest) { + for (; pDest < &_erelocate;) { + *pDest++ = *pSrc++; + } + } + + /* Clear the zero segment */ + for (pDest = &_szero; pDest < &_ezero;) { + *pDest++ = 0; + } + + /* Set the vector table base address */ + pSrc = (uint32_t *) & _sfixed; + SCB->VTOR = ((uint32_t) pSrc & SCB_VTOR_TBLOFF_Msk); + + /* Initialize the C library */ + __libc_init_array(); + + /* Branch to main function */ + main(); + + /* Infinite loop */ + while (1); +} + +/** + * \brief Default interrupt handler for unused IRQs. + */ +void Dummy_Handler(void) +{ + while (1) { + } +} diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/source/system_samd21.c b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/source/system_samd21.c new file mode 100644 index 0000000..48eaa60 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/source/system_samd21.c @@ -0,0 +1,78 @@ +/** + * \file + * + * \brief Low-level initialization functions called upon chip startup. + * + * Copyright (c) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include "samd21.h" + +/** + * Initial system clock frequency. The System RC Oscillator (RCSYS) provides + * the source for the main clock at chip startup. + */ +#define __SYSTEM_CLOCK (1000000) + +uint32_t SystemCoreClock = __SYSTEM_CLOCK;/*!< System Clock Frequency (Core Clock)*/ + +/** + * Initialize the system + * + * @brief Setup the microcontroller system. + * Initialize the System and update the SystemCoreClock variable. + */ +void SystemInit(void) +{ + // Keep the default device state after reset + SystemCoreClock = __SYSTEM_CLOCK; + return; +} + +/** + * Update SystemCoreClock variable + * + * @brief Updates the SystemCoreClock with current core Clock + * retrieved from cpu registers. + */ +void SystemCoreClockUpdate(void) +{ + // Not implemented + SystemCoreClock = __SYSTEM_CLOCK; + return; +} diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/source/system_samd21.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/source/system_samd21.h new file mode 100644 index 0000000..5bb8c7a --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/cmsis/samd21/source/system_samd21.h @@ -0,0 +1,62 @@ +/** + * \file + * + * \brief Low-level initialization functions called upon chip startup + * + * Copyright (c) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SYSTEM_SAMD21_H_INCLUDED_ +#define _SYSTEM_SAMD21_H_INCLUDED_ + +#ifdef __cplusplus +extern "C" { +#endif + +#include + +extern uint32_t SystemCoreClock; /*!< System Clock Frequency (Core Clock) */ + +void SystemInit(void); +void SystemCoreClockUpdate(void); + +#ifdef __cplusplus +} +#endif + +#endif /* SYSTEM_SAMD21_H_INCLUDED */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/compiler.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/compiler.h new file mode 100644 index 0000000..5eef4b2 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/compiler.h @@ -0,0 +1,1169 @@ +/** + * \file + * + * \brief Commonly used includes, types and macros. + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef UTILS_COMPILER_H_INCLUDED +#define UTILS_COMPILER_H_INCLUDED + +/** + * \defgroup group_sam0_utils Compiler abstraction layer and code utilities + * + * Compiler abstraction layer and code utilities for Cortex-M0+ based Atmel SAM devices. + * This module provides various abstraction layers and utilities to make code compatible between different compilers. + * + * @{ + */ + +#if (defined __ICCARM__) +# include +#endif + +#include +#include +#include +#include +#include + +#ifndef __ASSEMBLY__ + +#include +#include +#include +#include + +/** + * \def UNUSED + * \brief Marking \a v as a unused parameter or value. + */ +#define UNUSED(v) (void)(v) + +/** + * \def barrier + * \brief Memory barrier + */ +#ifdef __GNUC__ +# define barrier() asm volatile("" ::: "memory") +#else +# define barrier() asm ("") +#endif + +/** + * \brief Emit the compiler pragma \a arg. + * + * \param[in] arg The pragma directive as it would appear after \e \#pragma + * (i.e. not stringified). + */ +#define COMPILER_PRAGMA(arg) _Pragma(#arg) + +/** + * \def COMPILER_PACK_SET(alignment) + * \brief Set maximum alignment for subsequent struct and union definitions to \a alignment. + */ +#define COMPILER_PACK_SET(alignment) COMPILER_PRAGMA(pack(alignment)) + +/** + * \def COMPILER_PACK_RESET() + * \brief Set default alignment for subsequent struct and union definitions. + */ +#define COMPILER_PACK_RESET() COMPILER_PRAGMA(pack()) + + +/** + * \brief Set aligned boundary. + */ +#if (defined __GNUC__) || (defined __CC_ARM) +# define COMPILER_ALIGNED(a) __attribute__((__aligned__(a))) +#elif (defined __ICCARM__) +# define COMPILER_ALIGNED(a) COMPILER_PRAGMA(data_alignment = a) +#endif + +/** + * \brief Set word-aligned boundary. + */ +#if (defined __GNUC__) || defined(__CC_ARM) +#define COMPILER_WORD_ALIGNED __attribute__((__aligned__(4))) +#elif (defined __ICCARM__) +#define COMPILER_WORD_ALIGNED COMPILER_PRAGMA(data_alignment = 4) +#endif + +/** + * \def __always_inline + * \brief The function should always be inlined. + * + * This annotation instructs the compiler to ignore its inlining + * heuristics and inline the function no matter how big it thinks it + * becomes. + */ +#if defined(__CC_ARM) +# define __always_inline __forceinline +#elif (defined __GNUC__) +# define __always_inline __attribute__((__always_inline__)) +#elif (defined __ICCARM__) +# define __always_inline _Pragma("inline=forced") +#endif + +/** + * \def __no_inline + * \brief The function should never be inlined + * + * This annotation instructs the compiler to ignore its inlining + * heuristics and not inline the function no matter how small it thinks it + * becomes. + */ +#if defined(__CC_ARM) +# define __no_inline __attribute__((noinline)) +#elif (defined __GNUC__) +# define __no_inline __attribute__((noinline)) +#elif (defined __ICCARM__) +# define __no_inline _Pragma("inline=never") +#endif + + +/** \brief This macro is used to test fatal errors. + * + * The macro tests if the expression is false. If it is, a fatal error is + * detected and the application hangs up. If \c TEST_SUITE_DEFINE_ASSERT_MACRO + * is defined, a unit test version of the macro is used, to allow execution + * of further tests after a false expression. + * + * \param[in] expr Expression to evaluate and supposed to be nonzero. + */ +#if defined(_ASSERT_ENABLE_) +# if defined(TEST_SUITE_DEFINE_ASSERT_MACRO) +# include "unit_test/suite.h" +# else +# undef TEST_SUITE_DEFINE_ASSERT_MACRO +# define Assert(expr) \ + {\ + if (!(expr)) asm("BKPT #0");\ + } +# endif +#else +# define Assert(expr) ((void) 0) +#endif + +/* Define WEAK attribute */ +#if defined ( __CC_ARM ) +# define WEAK __attribute__ ((weak)) +#elif defined ( __ICCARM__ ) +# define WEAK __weak +#elif defined ( __GNUC__ ) +# define WEAK __attribute__ ((weak)) +#endif + +/* Define NO_INIT attribute */ +#if defined ( __CC_ARM ) +# define NO_INIT __attribute__((zero_init)) +#elif defined ( __ICCARM__ ) +# define NO_INIT __no_init +#elif defined ( __GNUC__ ) +# define NO_INIT __attribute__((section(".no_init"))) +#endif + +#include "interrupt.h" + +/** \name Usual Types + * @{ */ +#ifndef __cplusplus +# if !defined(__bool_true_false_are_defined) +typedef unsigned char bool; +# endif +#endif +typedef uint16_t le16_t; +typedef uint16_t be16_t; +typedef uint32_t le32_t; +typedef uint32_t be32_t; +typedef uint32_t iram_size_t; +/** @} */ + +/** \name Aliasing Aggregate Types + * @{ */ + +/** 16-bit union. */ +typedef union +{ + int16_t s16; + uint16_t u16; + int8_t s8[2]; + uint8_t u8[2]; +} Union16; + +/** 32-bit union. */ +typedef union +{ + int32_t s32; + uint32_t u32; + int16_t s16[2]; + uint16_t u16[2]; + int8_t s8[4]; + uint8_t u8[4]; +} Union32; + +/** 64-bit union. */ +typedef union +{ + int64_t s64; + uint64_t u64; + int32_t s32[2]; + uint32_t u32[2]; + int16_t s16[4]; + uint16_t u16[4]; + int8_t s8[8]; + uint8_t u8[8]; +} Union64; + +/** Union of pointers to 64-, 32-, 16- and 8-bit unsigned integers. */ +typedef union +{ + int64_t *s64ptr; + uint64_t *u64ptr; + int32_t *s32ptr; + uint32_t *u32ptr; + int16_t *s16ptr; + uint16_t *u16ptr; + int8_t *s8ptr; + uint8_t *u8ptr; +} UnionPtr; + +/** Union of pointers to volatile 64-, 32-, 16- and 8-bit unsigned integers. */ +typedef union +{ + volatile int64_t *s64ptr; + volatile uint64_t *u64ptr; + volatile int32_t *s32ptr; + volatile uint32_t *u32ptr; + volatile int16_t *s16ptr; + volatile uint16_t *u16ptr; + volatile int8_t *s8ptr; + volatile uint8_t *u8ptr; +} UnionVPtr; + +/** Union of pointers to constant 64-, 32-, 16- and 8-bit unsigned integers. */ +typedef union +{ + const int64_t *s64ptr; + const uint64_t *u64ptr; + const int32_t *s32ptr; + const uint32_t *u32ptr; + const int16_t *s16ptr; + const uint16_t *u16ptr; + const int8_t *s8ptr; + const uint8_t *u8ptr; +} UnionCPtr; + +/** Union of pointers to constant volatile 64-, 32-, 16- and 8-bit unsigned integers. */ +typedef union +{ + const volatile int64_t *s64ptr; + const volatile uint64_t *u64ptr; + const volatile int32_t *s32ptr; + const volatile uint32_t *u32ptr; + const volatile int16_t *s16ptr; + const volatile uint16_t *u16ptr; + const volatile int8_t *s8ptr; + const volatile uint8_t *u8ptr; +} UnionCVPtr; + +/** Structure of pointers to 64-, 32-, 16- and 8-bit unsigned integers. */ +typedef struct +{ + int64_t *s64ptr; + uint64_t *u64ptr; + int32_t *s32ptr; + uint32_t *u32ptr; + int16_t *s16ptr; + uint16_t *u16ptr; + int8_t *s8ptr; + uint8_t *u8ptr; +} StructPtr; + +/** Structure of pointers to volatile 64-, 32-, 16- and 8-bit unsigned integers. */ +typedef struct +{ + volatile int64_t *s64ptr; + volatile uint64_t *u64ptr; + volatile int32_t *s32ptr; + volatile uint32_t *u32ptr; + volatile int16_t *s16ptr; + volatile uint16_t *u16ptr; + volatile int8_t *s8ptr; + volatile uint8_t *u8ptr; +} StructVPtr; + +/** Structure of pointers to constant 64-, 32-, 16- and 8-bit unsigned integers. */ +typedef struct +{ + const int64_t *s64ptr; + const uint64_t *u64ptr; + const int32_t *s32ptr; + const uint32_t *u32ptr; + const int16_t *s16ptr; + const uint16_t *u16ptr; + const int8_t *s8ptr; + const uint8_t *u8ptr; +} StructCPtr; + +/** Structure of pointers to constant volatile 64-, 32-, 16- and 8-bit unsigned integers. */ +typedef struct +{ + const volatile int64_t *s64ptr; + const volatile uint64_t *u64ptr; + const volatile int32_t *s32ptr; + const volatile uint32_t *u32ptr; + const volatile int16_t *s16ptr; + const volatile uint16_t *u16ptr; + const volatile int8_t *s8ptr; + const volatile uint8_t *u8ptr; +} StructCVPtr; + +/** @} */ + +#endif /* #ifndef __ASSEMBLY__ */ + +/** \name Usual Constants + * @{ */ +#define DISABLE 0 +#define ENABLE 1 + +#ifndef __cplusplus +# if !defined(__bool_true_false_are_defined) +# define false 0 +# define true 1 +# endif +#endif +/** @} */ + +#ifndef __ASSEMBLY__ + +/** \name Optimization Control + * @{ */ + +/** + * \def likely(exp) + * \brief The expression \a exp is likely to be true + */ +#if !defined(likely) || defined(__DOXYGEN__) +# define likely(exp) (exp) +#endif + +/** + * \def unlikely(exp) + * \brief The expression \a exp is unlikely to be true + */ +#if !defined(unlikely) || defined(__DOXYGEN__) +# define unlikely(exp) (exp) +#endif + +/** + * \def is_constant(exp) + * \brief Determine if an expression evaluates to a constant value. + * + * \param[in] exp Any expression + * + * \return true if \a exp is constant, false otherwise. + */ +#if (defined __GNUC__) || (defined __CC_ARM) +# define is_constant(exp) __builtin_constant_p(exp) +#else +# define is_constant(exp) (0) +#endif + +/** @} */ + +/** \name Bit-Field Handling + * @{ */ + +/** \brief Reads the bits of a value specified by a given bit-mask. + * + * \param[in] value Value to read bits from. + * \param[in] mask Bit-mask indicating bits to read. + * + * \return Read bits. + */ +#define Rd_bits( value, mask) ((value) & (mask)) + +/** \brief Writes the bits of a C lvalue specified by a given bit-mask. + * + * \param[in] lvalue C lvalue to write bits to. + * \param[in] mask Bit-mask indicating bits to write. + * \param[in] bits Bits to write. + * + * \return Resulting value with written bits. + */ +#define Wr_bits(lvalue, mask, bits) ((lvalue) = ((lvalue) & ~(mask)) |\ + ((bits ) & (mask))) + +/** \brief Tests the bits of a value specified by a given bit-mask. + * + * \param[in] value Value of which to test bits. + * \param[in] mask Bit-mask indicating bits to test. + * + * \return \c 1 if at least one of the tested bits is set, else \c 0. + */ +#define Tst_bits( value, mask) (Rd_bits(value, mask) != 0) + +/** \brief Clears the bits of a C lvalue specified by a given bit-mask. + * + * \param[in] lvalue C lvalue of which to clear bits. + * \param[in] mask Bit-mask indicating bits to clear. + * + * \return Resulting value with cleared bits. + */ +#define Clr_bits(lvalue, mask) ((lvalue) &= ~(mask)) + +/** \brief Sets the bits of a C lvalue specified by a given bit-mask. + * + * \param[in] lvalue C lvalue of which to set bits. + * \param[in] mask Bit-mask indicating bits to set. + * + * \return Resulting value with set bits. + */ +#define Set_bits(lvalue, mask) ((lvalue) |= (mask)) + +/** \brief Toggles the bits of a C lvalue specified by a given bit-mask. + * + * \param[in] lvalue C lvalue of which to toggle bits. + * \param[in] mask Bit-mask indicating bits to toggle. + * + * \return Resulting value with toggled bits. + */ +#define Tgl_bits(lvalue, mask) ((lvalue) ^= (mask)) + +/** \brief Reads the bit-field of a value specified by a given bit-mask. + * + * \param[in] value Value to read a bit-field from. + * \param[in] mask Bit-mask indicating the bit-field to read. + * + * \return Read bit-field. + */ +#define Rd_bitfield( value, mask) (Rd_bits( value, mask) >> ctz(mask)) + +/** \brief Writes the bit-field of a C lvalue specified by a given bit-mask. + * + * \param[in] lvalue C lvalue to write a bit-field to. + * \param[in] mask Bit-mask indicating the bit-field to write. + * \param[in] bitfield Bit-field to write. + * + * \return Resulting value with written bit-field. + */ +#define Wr_bitfield(lvalue, mask, bitfield) (Wr_bits(lvalue, mask, (uint32_t)(bitfield) << ctz(mask))) + +/** @} */ + + +/** \name Zero-Bit Counting + * + * Under GCC, __builtin_clz and __builtin_ctz behave like macros when + * applied to constant expressions (values known at compile time), so they are + * more optimized than the use of the corresponding assembly instructions and + * they can be used as constant expressions e.g. to initialize objects having + * static storage duration, and like the corresponding assembly instructions + * when applied to non-constant expressions (values unknown at compile time), so + * they are more optimized than an assembly periphrasis. Hence, clz and ctz + * ensure a possible and optimized behavior for both constant and non-constant + * expressions. + * + * @{ */ + +/** \brief Counts the leading zero bits of the given value considered as a 32-bit integer. + * + * \param[in] u Value of which to count the leading zero bits. + * + * \return The count of leading zero bits in \a u. + */ +#if (defined __GNUC__) || (defined __CC_ARM) +# define clz(u) __builtin_clz(u) +#else +# define clz(u) (((u) == 0) ? 32 : \ + ((u) & (1ul << 31)) ? 0 : \ + ((u) & (1ul << 30)) ? 1 : \ + ((u) & (1ul << 29)) ? 2 : \ + ((u) & (1ul << 28)) ? 3 : \ + ((u) & (1ul << 27)) ? 4 : \ + ((u) & (1ul << 26)) ? 5 : \ + ((u) & (1ul << 25)) ? 6 : \ + ((u) & (1ul << 24)) ? 7 : \ + ((u) & (1ul << 23)) ? 8 : \ + ((u) & (1ul << 22)) ? 9 : \ + ((u) & (1ul << 21)) ? 10 : \ + ((u) & (1ul << 20)) ? 11 : \ + ((u) & (1ul << 19)) ? 12 : \ + ((u) & (1ul << 18)) ? 13 : \ + ((u) & (1ul << 17)) ? 14 : \ + ((u) & (1ul << 16)) ? 15 : \ + ((u) & (1ul << 15)) ? 16 : \ + ((u) & (1ul << 14)) ? 17 : \ + ((u) & (1ul << 13)) ? 18 : \ + ((u) & (1ul << 12)) ? 19 : \ + ((u) & (1ul << 11)) ? 20 : \ + ((u) & (1ul << 10)) ? 21 : \ + ((u) & (1ul << 9)) ? 22 : \ + ((u) & (1ul << 8)) ? 23 : \ + ((u) & (1ul << 7)) ? 24 : \ + ((u) & (1ul << 6)) ? 25 : \ + ((u) & (1ul << 5)) ? 26 : \ + ((u) & (1ul << 4)) ? 27 : \ + ((u) & (1ul << 3)) ? 28 : \ + ((u) & (1ul << 2)) ? 29 : \ + ((u) & (1ul << 1)) ? 30 : \ + 31) +#endif + +/** \brief Counts the trailing zero bits of the given value considered as a 32-bit integer. + * + * \param[in] u Value of which to count the trailing zero bits. + * + * \return The count of trailing zero bits in \a u. + */ +#if (defined __GNUC__) || (defined __CC_ARM) +# define ctz(u) __builtin_ctz(u) +#else +# define ctz(u) ((u) & (1ul << 0) ? 0 : \ + (u) & (1ul << 1) ? 1 : \ + (u) & (1ul << 2) ? 2 : \ + (u) & (1ul << 3) ? 3 : \ + (u) & (1ul << 4) ? 4 : \ + (u) & (1ul << 5) ? 5 : \ + (u) & (1ul << 6) ? 6 : \ + (u) & (1ul << 7) ? 7 : \ + (u) & (1ul << 8) ? 8 : \ + (u) & (1ul << 9) ? 9 : \ + (u) & (1ul << 10) ? 10 : \ + (u) & (1ul << 11) ? 11 : \ + (u) & (1ul << 12) ? 12 : \ + (u) & (1ul << 13) ? 13 : \ + (u) & (1ul << 14) ? 14 : \ + (u) & (1ul << 15) ? 15 : \ + (u) & (1ul << 16) ? 16 : \ + (u) & (1ul << 17) ? 17 : \ + (u) & (1ul << 18) ? 18 : \ + (u) & (1ul << 19) ? 19 : \ + (u) & (1ul << 20) ? 20 : \ + (u) & (1ul << 21) ? 21 : \ + (u) & (1ul << 22) ? 22 : \ + (u) & (1ul << 23) ? 23 : \ + (u) & (1ul << 24) ? 24 : \ + (u) & (1ul << 25) ? 25 : \ + (u) & (1ul << 26) ? 26 : \ + (u) & (1ul << 27) ? 27 : \ + (u) & (1ul << 28) ? 28 : \ + (u) & (1ul << 29) ? 29 : \ + (u) & (1ul << 30) ? 30 : \ + (u) & (1ul << 31) ? 31 : \ + 32) +#endif + +/** @} */ + + +/** \name Bit Reversing + * @{ */ + +/** \brief Reverses the bits of \a u8. + * + * \param[in] u8 U8 of which to reverse the bits. + * + * \return Value resulting from \a u8 with reversed bits. + */ +#define bit_reverse8(u8) ((U8)(bit_reverse32((U8)(u8)) >> 24)) + +/** \brief Reverses the bits of \a u16. + * + * \param[in] u16 U16 of which to reverse the bits. + * + * \return Value resulting from \a u16 with reversed bits. + */ +#define bit_reverse16(u16) ((uint16_t)(bit_reverse32((uint16_t)(u16)) >> 16)) + +/** \brief Reverses the bits of \a u32. + * + * \param[in] u32 U32 of which to reverse the bits. + * + * \return Value resulting from \a u32 with reversed bits. + */ +#define bit_reverse32(u32) __RBIT(u32) + +/** \brief Reverses the bits of \a u64. + * + * \param[in] u64 U64 of which to reverse the bits. + * + * \return Value resulting from \a u64 with reversed bits. + */ +#define bit_reverse64(u64) ((uint64_t)(((uint64_t)bit_reverse32((uint64_t)(u64) >> 32)) |\ + ((uint64_t)bit_reverse32((uint64_t)(u64)) << 32))) + +/** @} */ + + +/** \name Alignment + * @{ */ + +/** \brief Tests alignment of the number \a val with the \a n boundary. + * + * \param[in] val Input value. + * \param[in] n Boundary. + * + * \return \c 1 if the number \a val is aligned with the \a n boundary, else \c 0. + */ +#define Test_align(val, n) (!Tst_bits( val, (n) - 1 ) ) + +/** \brief Gets alignment of the number \a val with respect to the \a n boundary. + * + * \param[in] val Input value. + * \param[in] n Boundary. + * + * \return Alignment of the number \a val with respect to the \a n boundary. + */ +#define Get_align(val, n) ( Rd_bits( val, (n) - 1 ) ) + +/** \brief Sets alignment of the lvalue number \a lval to \a alg with respect to the \a n boundary. + * + * \param[in] lval Input/output lvalue. + * \param[in] n Boundary. + * \param[in] alg Alignment. + * + * \return New value of \a lval resulting from its alignment set to \a alg with respect to the \a n boundary. + */ +#define Set_align(lval, n, alg) ( Wr_bits(lval, (n) - 1, alg) ) + +/** \brief Aligns the number \a val with the upper \a n boundary. + * + * \param[in] val Input value. + * \param[in] n Boundary. + * + * \return Value resulting from the number \a val aligned with the upper \a n boundary. + */ +#define Align_up( val, n) (((val) + ((n) - 1)) & ~((n) - 1)) + +/** \brief Aligns the number \a val with the lower \a n boundary. + * + * \param[in] val Input value. + * \param[in] n Boundary. + * + * \return Value resulting from the number \a val aligned with the lower \a n boundary. + */ +#define Align_down(val, n) ( (val) & ~((n) - 1)) + +/** @} */ + + +/** \name Mathematics + * + * The same considerations as for clz and ctz apply here but GCC does not + * provide built-in functions to access the assembly instructions abs, min and + * max and it does not produce them by itself in most cases, so two sets of + * macros are defined here: + * - Abs, Min and Max to apply to constant expressions (values known at + * compile time); + * - abs, min and max to apply to non-constant expressions (values unknown at + * compile time), abs is found in stdlib.h. + * + * @{ */ + +/** \brief Takes the absolute value of \a a. + * + * \param[in] a Input value. + * + * \return Absolute value of \a a. + * + * \note More optimized if only used with values known at compile time. + */ +#define Abs(a) (((a) < 0 ) ? -(a) : (a)) + +/** \brief Takes the minimal value of \a a and \a b. + * + * \param[in] a Input value. + * \param[in] b Input value. + * + * \return Minimal value of \a a and \a b. + * + * \note More optimized if only used with values known at compile time. + */ +#define Min(a, b) (((a) < (b)) ? (a) : (b)) + +/** \brief Takes the maximal value of \a a and \a b. + * + * \param[in] a Input value. + * \param[in] b Input value. + * + * \return Maximal value of \a a and \a b. + * + * \note More optimized if only used with values known at compile time. + */ +#define Max(a, b) (((a) > (b)) ? (a) : (b)) + +/** \brief Takes the minimal value of \a a and \a b. + * + * \param[in] a Input value. + * \param[in] b Input value. + * + * \return Minimal value of \a a and \a b. + * + * \note More optimized if only used with values unknown at compile time. + */ +#define min(a, b) Min(a, b) + +/** \brief Takes the maximal value of \a a and \a b. + * + * \param[in] a Input value. + * \param[in] b Input value. + * + * \return Maximal value of \a a and \a b. + * + * \note More optimized if only used with values unknown at compile time. + */ +#define max(a, b) Max(a, b) + +/** @} */ + + +/** \brief Calls the routine at address \a addr. + * + * It generates a long call opcode. + * + * For example, `Long_call(0x80000000)' generates a software reset on a UC3 if + * it is invoked from the CPU supervisor mode. + * + * \param[in] addr Address of the routine to call. + * + * \note It may be used as a long jump opcode in some special cases. + */ +#define Long_call(addr) ((*(void (*)(void))(addr))()) + + +/** \name MCU Endianism Handling + * ARM is MCU little endian. + * + * @{ */ +#define BE16(x) Swap16(x) +#define LE16(x) (x) + +#define le16_to_cpu(x) (x) +#define cpu_to_le16(x) (x) +#define LE16_TO_CPU(x) (x) +#define CPU_TO_LE16(x) (x) + +#define be16_to_cpu(x) Swap16(x) +#define cpu_to_be16(x) Swap16(x) +#define BE16_TO_CPU(x) Swap16(x) +#define CPU_TO_BE16(x) Swap16(x) + +#define le32_to_cpu(x) (x) +#define cpu_to_le32(x) (x) +#define LE32_TO_CPU(x) (x) +#define CPU_TO_LE32(x) (x) + +#define be32_to_cpu(x) swap32(x) +#define cpu_to_be32(x) swap32(x) +#define BE32_TO_CPU(x) swap32(x) +#define CPU_TO_BE32(x) swap32(x) +/** @} */ + + +/** \name Endianism Conversion + * + * The same considerations as for clz and ctz apply here but GCC's + * __builtin_bswap_32 and __builtin_bswap_64 do not behave like macros when + * applied to constant expressions, so two sets of macros are defined here: + * - Swap16, Swap32 and Swap64 to apply to constant expressions (values known + * at compile time); + * - swap16, swap32 and swap64 to apply to non-constant expressions (values + * unknown at compile time). + * + * @{ */ + +/** \brief Toggles the endianism of \a u16 (by swapping its bytes). + * + * \param[in] u16 U16 of which to toggle the endianism. + * + * \return Value resulting from \a u16 with toggled endianism. + * + * \note More optimized if only used with values known at compile time. + */ +#define Swap16(u16) ((uint16_t)(((uint16_t)(u16) >> 8) |\ + ((uint16_t)(u16) << 8))) + +/** \brief Toggles the endianism of \a u32 (by swapping its bytes). + * + * \param[in] u32 U32 of which to toggle the endianism. + * + * \return Value resulting from \a u32 with toggled endianism. + * + * \note More optimized if only used with values known at compile time. + */ +#define Swap32(u32) ((uint32_t)(((uint32_t)Swap16((uint32_t)(u32) >> 16)) |\ + ((uint32_t)Swap16((uint32_t)(u32)) << 16))) + +/** \brief Toggles the endianism of \a u64 (by swapping its bytes). + * + * \param[in] u64 U64 of which to toggle the endianism. + * + * \return Value resulting from \a u64 with toggled endianism. + * + * \note More optimized if only used with values known at compile time. + */ +#define Swap64(u64) ((uint64_t)(((uint64_t)Swap32((uint64_t)(u64) >> 32)) |\ + ((uint64_t)Swap32((uint64_t)(u64)) << 32))) + +/** \brief Toggles the endianism of \a u16 (by swapping its bytes). + * + * \param[in] u16 U16 of which to toggle the endianism. + * + * \return Value resulting from \a u16 with toggled endianism. + * + * \note More optimized if only used with values unknown at compile time. + */ +#define swap16(u16) Swap16(u16) + +/** \brief Toggles the endianism of \a u32 (by swapping its bytes). + * + * \param[in] u32 U32 of which to toggle the endianism. + * + * \return Value resulting from \a u32 with toggled endianism. + * + * \note More optimized if only used with values unknown at compile time. + */ +#if (defined __GNUC__) +# define swap32(u32) ((uint32_t)__builtin_bswap32((uint32_t)(u32))) +#else +# define swap32(u32) Swap32(u32) +#endif + +/** \brief Toggles the endianism of \a u64 (by swapping its bytes). + * + * \param[in] u64 U64 of which to toggle the endianism. + * + * \return Value resulting from \a u64 with toggled endianism. + * + * \note More optimized if only used with values unknown at compile time. + */ +#if (defined __GNUC__) +# define swap64(u64) ((uint64_t)__builtin_bswap64((uint64_t)(u64))) +#else +# define swap64(u64) ((uint64_t)(((uint64_t)swap32((uint64_t)(u64) >> 32)) |\ + ((uint64_t)swap32((uint64_t)(u64)) << 32))) +#endif + +/** @} */ + + +/** \name Target Abstraction + * + * @{ */ + +#define _GLOBEXT_ extern /**< extern storage-class specifier. */ +#define _CONST_TYPE_ const /**< const type qualifier. */ +#define _MEM_TYPE_SLOW_ /**< Slow memory type. */ +#define _MEM_TYPE_MEDFAST_ /**< Fairly fast memory type. */ +#define _MEM_TYPE_FAST_ /**< Fast memory type. */ + +#define memcmp_ram2ram memcmp /**< Target-specific memcmp of RAM to RAM. */ +#define memcmp_code2ram memcmp /**< Target-specific memcmp of RAM to NVRAM. */ +#define memcpy_ram2ram memcpy /**< Target-specific memcpy from RAM to RAM. */ +#define memcpy_code2ram memcpy /**< Target-specific memcpy from NVRAM to RAM. */ + +/** @} */ + +/** + * \brief Calculate \f$ \left\lceil \frac{a}{b} \right\rceil \f$ using + * integer arithmetic. + * + * \param[in] a An integer + * \param[in] b Another integer + * + * \return (\a a / \a b) rounded up to the nearest integer. + */ +#define div_ceil(a, b) (((a) + (b) - 1) / (b)) + +#endif /* #ifndef __ASSEMBLY__ */ +#ifdef __ICCARM__ +/** \name Compiler Keywords + * + * Port of some keywords from GCC to IAR Embedded Workbench. + * + * @{ */ + +#define __asm__ asm +#define __inline__ inline +#define __volatile__ + +/** @} */ + +#endif + +#define FUNC_PTR void * +/** + * \def unused + * \brief Marking \a v as a unused parameter or value. + */ +#define unused(v) do { (void)(v); } while(0) + +/* Define RAMFUNC attribute */ +#if defined ( __CC_ARM ) /* Keil uVision 4 */ +# define RAMFUNC __attribute__ ((section(".ramfunc"))) +#elif defined ( __ICCARM__ ) /* IAR Ewarm 5.41+ */ +# define RAMFUNC __ramfunc +#elif defined ( __GNUC__ ) /* GCC CS3 2009q3-68 */ +# define RAMFUNC __attribute__ ((section(".ramfunc"))) +#endif + +/* Define OPTIMIZE_HIGH attribute */ +#if defined ( __CC_ARM ) /* Keil uVision 4 */ +# define OPTIMIZE_HIGH _Pragma("O3") +#elif defined ( __ICCARM__ ) /* IAR Ewarm 5.41+ */ +# define OPTIMIZE_HIGH _Pragma("optimize=high") +#elif defined ( __GNUC__ ) /* GCC CS3 2009q3-68 */ +# define OPTIMIZE_HIGH __attribute__((optimize(s))) +#endif +#define PASS 0 +#define FAIL 1 +#define LOW 0 +#define HIGH 1 + +typedef int8_t S8 ; //!< 8-bit signed integer. +typedef uint8_t U8 ; //!< 8-bit unsigned integer. +typedef int16_t S16; //!< 16-bit signed integer. +typedef uint16_t U16; //!< 16-bit unsigned integer. +typedef int32_t S32; //!< 32-bit signed integer. +typedef uint32_t U32; //!< 32-bit unsigned integer. +typedef int64_t S64; //!< 64-bit signed integer. +typedef uint64_t U64; //!< 64-bit unsigned integer. +typedef float F32; //!< 32-bit floating-point number. +typedef double F64; //!< 64-bit floating-point number. + +#define MSB(u16) (((U8 *)&(u16))[1]) //!< Most significant byte of \a u16. +#define LSB(u16) (((U8 *)&(u16))[0]) //!< Least significant byte of \a u16. + +#define MSH(u32) (((U16 *)&(u32))[1]) //!< Most significant half-word of \a u32. +#define LSH(u32) (((U16 *)&(u32))[0]) //!< Least significant half-word of \a u32. +#define MSB0W(u32) (((U8 *)&(u32))[3]) //!< Most significant byte of 1st rank of \a u32. +#define MSB1W(u32) (((U8 *)&(u32))[2]) //!< Most significant byte of 2nd rank of \a u32. +#define MSB2W(u32) (((U8 *)&(u32))[1]) //!< Most significant byte of 3rd rank of \a u32. +#define MSB3W(u32) (((U8 *)&(u32))[0]) //!< Most significant byte of 4th rank of \a u32. +#define LSB3W(u32) MSB0W(u32) //!< Least significant byte of 4th rank of \a u32. +#define LSB2W(u32) MSB1W(u32) //!< Least significant byte of 3rd rank of \a u32. +#define LSB1W(u32) MSB2W(u32) //!< Least significant byte of 2nd rank of \a u32. +#define LSB0W(u32) MSB3W(u32) //!< Least significant byte of 1st rank of \a u32. + +#define MSW(u64) (((U32 *)&(u64))[1]) //!< Most significant word of \a u64. +#define LSW(u64) (((U32 *)&(u64))[0]) //!< Least significant word of \a u64. +#define MSH0(u64) (((U16 *)&(u64))[3]) //!< Most significant half-word of 1st rank of \a u64. +#define MSH1(u64) (((U16 *)&(u64))[2]) //!< Most significant half-word of 2nd rank of \a u64. +#define MSH2(u64) (((U16 *)&(u64))[1]) //!< Most significant half-word of 3rd rank of \a u64. +#define MSH3(u64) (((U16 *)&(u64))[0]) //!< Most significant half-word of 4th rank of \a u64. +#define LSH3(u64) MSH0(u64) //!< Least significant half-word of 4th rank of \a u64. +#define LSH2(u64) MSH1(u64) //!< Least significant half-word of 3rd rank of \a u64. +#define LSH1(u64) MSH2(u64) //!< Least significant half-word of 2nd rank of \a u64. +#define LSH0(u64) MSH3(u64) //!< Least significant half-word of 1st rank of \a u64. +#define MSB0D(u64) (((U8 *)&(u64))[7]) //!< Most significant byte of 1st rank of \a u64. +#define MSB1D(u64) (((U8 *)&(u64))[6]) //!< Most significant byte of 2nd rank of \a u64. +#define MSB2D(u64) (((U8 *)&(u64))[5]) //!< Most significant byte of 3rd rank of \a u64. +#define MSB3D(u64) (((U8 *)&(u64))[4]) //!< Most significant byte of 4th rank of \a u64. +#define MSB4D(u64) (((U8 *)&(u64))[3]) //!< Most significant byte of 5th rank of \a u64. +#define MSB5D(u64) (((U8 *)&(u64))[2]) //!< Most significant byte of 6th rank of \a u64. +#define MSB6D(u64) (((U8 *)&(u64))[1]) //!< Most significant byte of 7th rank of \a u64. +#define MSB7D(u64) (((U8 *)&(u64))[0]) //!< Most significant byte of 8th rank of \a u64. +#define LSB7D(u64) MSB0D(u64) //!< Least significant byte of 8th rank of \a u64. +#define LSB6D(u64) MSB1D(u64) //!< Least significant byte of 7th rank of \a u64. +#define LSB5D(u64) MSB2D(u64) //!< Least significant byte of 6th rank of \a u64. +#define LSB4D(u64) MSB3D(u64) //!< Least significant byte of 5th rank of \a u64. +#define LSB3D(u64) MSB4D(u64) //!< Least significant byte of 4th rank of \a u64. +#define LSB2D(u64) MSB5D(u64) //!< Least significant byte of 3rd rank of \a u64. +#define LSB1D(u64) MSB6D(u64) //!< Least significant byte of 2nd rank of \a u64. +#define LSB0D(u64) MSB7D(u64) //!< Least significant byte of 1st rank of \a u64. + +#define LSB0(u32) LSB0W(u32) //!< Least significant byte of 1st rank of \a u32. +#define LSB1(u32) LSB1W(u32) //!< Least significant byte of 2nd rank of \a u32. +#define LSB2(u32) LSB2W(u32) //!< Least significant byte of 3rd rank of \a u32. +#define LSB3(u32) LSB3W(u32) //!< Least significant byte of 4th rank of \a u32. +#define MSB3(u32) MSB3W(u32) //!< Most significant byte of 4th rank of \a u32. +#define MSB2(u32) MSB2W(u32) //!< Most significant byte of 3rd rank of \a u32. +#define MSB1(u32) MSB1W(u32) //!< Most significant byte of 2nd rank of \a u32. +#define MSB0(u32) MSB0W(u32) //!< Most significant byte of 1st rank of \a u32. + +#if defined(__ICCARM__) +#define SHORTENUM __packed +#elif defined(__GNUC__) +#define SHORTENUM __attribute__((packed)) +#endif + +/* No operation */ +#if defined(__ICCARM__) +#define nop() __no_operation() +#elif defined(__GNUC__) +#define nop() (__NOP()) +#endif + +#define FLASH_DECLARE(x) const x +#define FLASH_EXTERN(x) extern const x +#define PGM_READ_BYTE(x) *(x) +#define PGM_READ_WORD(x) *(x) +#define MEMCPY_ENDIAN memcpy +#define PGM_READ_BLOCK(dst, src, len) memcpy((dst), (src), (len)) + +/*Defines the Flash Storage for the request and response of MAC*/ +#define CMD_ID_OCTET (0) + +/* Converting of values from CPU endian to little endian. */ +#define CPU_ENDIAN_TO_LE16(x) (x) +#define CPU_ENDIAN_TO_LE32(x) (x) +#define CPU_ENDIAN_TO_LE64(x) (x) + +/* Converting of values from little endian to CPU endian. */ +#define LE16_TO_CPU_ENDIAN(x) (x) +#define LE32_TO_CPU_ENDIAN(x) (x) +#define LE64_TO_CPU_ENDIAN(x) (x) + +/* Converting of constants from little endian to CPU endian. */ +#define CLE16_TO_CPU_ENDIAN(x) (x) +#define CLE32_TO_CPU_ENDIAN(x) (x) +#define CLE64_TO_CPU_ENDIAN(x) (x) + +/* Converting of constants from CPU endian to little endian. */ +#define CCPU_ENDIAN_TO_LE16(x) (x) +#define CCPU_ENDIAN_TO_LE32(x) (x) +#define CCPU_ENDIAN_TO_LE64(x) (x) + +#define ADDR_COPY_DST_SRC_16(dst, src) ((dst) = (src)) +#define ADDR_COPY_DST_SRC_64(dst, src) ((dst) = (src)) + +/** + * @brief Converts a 64-Bit value into a 8 Byte array + * + * @param[in] value 64-Bit value + * @param[out] data Pointer to the 8 Byte array to be updated with 64-Bit value + * @ingroup apiPalApi + */ +static inline void convert_64_bit_to_byte_array(uint64_t value, uint8_t *data) +{ + uint8_t index = 0; + + while (index < 8) + { + data[index++] = value & 0xFF; + value = value >> 8; + } +} + +/** + * @brief Converts a 16-Bit value into a 2 Byte array + * + * @param[in] value 16-Bit value + * @param[out] data Pointer to the 2 Byte array to be updated with 16-Bit value + * @ingroup apiPalApi + */ +static inline void convert_16_bit_to_byte_array(uint16_t value, uint8_t *data) +{ + data[0] = value & 0xFF; + data[1] = (value >> 8) & 0xFF; +} + +/* Converts a 16-Bit value into a 2 Byte array */ +static inline void convert_spec_16_bit_to_byte_array(uint16_t value, uint8_t *data) +{ + data[0] = value & 0xFF; + data[1] = (value >> 8) & 0xFF; +} + +/* Converts a 16-Bit value into a 2 Byte array */ +static inline void convert_16_bit_to_byte_address(uint16_t value, uint8_t *data) +{ + data[0] = value & 0xFF; + data[1] = (value >> 8) & 0xFF; +} + +/* + * @brief Converts a 2 Byte array into a 16-Bit value + * + * @param data Specifies the pointer to the 2 Byte array + * + * @return 16-Bit value + * @ingroup apiPalApi + */ +static inline uint16_t convert_byte_array_to_16_bit(uint8_t *data) +{ + return (data[0] | ((uint16_t)data[1] << 8)); +} + +/* Converts a 4 Byte array into a 32-Bit value */ +static inline uint32_t convert_byte_array_to_32_bit(uint8_t *data) +{ + union + { + uint32_t u32; + uint8_t u8[4]; + }long_addr; + uint8_t index; + for (index = 0; index < 4; index++) + { + long_addr.u8[index] = *data++; + } + return long_addr.u32; +} + +/** + * @brief Converts a 8 Byte array into a 64-Bit value + * + * @param data Specifies the pointer to the 8 Byte array + * + * @return 64-Bit value + * @ingroup apiPalApi + */ +static inline uint64_t convert_byte_array_to_64_bit(uint8_t *data) +{ + union + { + uint64_t u64; + uint8_t u8[8]; + } long_addr; + + uint8_t index; + + for (index = 0; index < 8; index++) + { + long_addr.u8[index] = *data++; + } + + return long_addr.u64; +} + +/** @} */ + +#endif /* UTILS_COMPILER_H_INCLUDED */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/header_files/io.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/header_files/io.h new file mode 100644 index 0000000..d6e5aba --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/header_files/io.h @@ -0,0 +1,74 @@ +/** + * \file + * + * \brief Arch file for SAM0. + * + * This file defines common SAM0 series. + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAM_IO_ +#define _SAM_IO_ + +#include +#include +#include + +/* SAM D20 family */ +#if (SAMD20) +# include "samd20.h" +#endif + +#if (SAMD21) +# include "samd21.h" +#endif + +#if (SAMR21) +# include "samr21.h" +#endif + +#if (SAMD10) +# include "samd10.h" +#endif + +#if (SAMD11) +# include "samd11.h" +#endif + +#endif /* _SAM_IO_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/linker_scripts/samd21/gcc/samd21j18a_flash.ld b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/linker_scripts/samd21/gcc/samd21j18a_flash.ld new file mode 100644 index 0000000..0fb2443 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/linker_scripts/samd21/gcc/samd21j18a_flash.ld @@ -0,0 +1,157 @@ +/** + * \file + * + * \brief Linker script for running in internal FLASH on the SAMD21J18A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + + +OUTPUT_FORMAT("elf32-littlearm", "elf32-littlearm", "elf32-littlearm") +OUTPUT_ARCH(arm) +SEARCH_DIR(.) + +/* Memory Spaces Definitions */ +MEMORY +{ + rom (rx) : ORIGIN = 0x00000000, LENGTH = 0x00040000 + ram (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* The stack size used by the application. NOTE: you need to adjust according to your application. */ +STACK_SIZE = DEFINED(STACK_SIZE) ? STACK_SIZE : DEFINED(__stack_size__) ? __stack_size__ : 0x2000; + +/* Section Definitions */ +SECTIONS +{ + .text : + { + . = ALIGN(4); + _sfixed = .; + KEEP(*(.vectors .vectors.*)) + *(.text .text.* .gnu.linkonce.t.*) + *(.glue_7t) *(.glue_7) + *(.rodata .rodata* .gnu.linkonce.r.*) + *(.ARM.extab* .gnu.linkonce.armextab.*) + + /* Support C constructors, and C destructors in both user code + and the C library. This also provides support for C++ code. */ + . = ALIGN(4); + KEEP(*(.init)) + . = ALIGN(4); + __preinit_array_start = .; + KEEP (*(.preinit_array)) + __preinit_array_end = .; + + . = ALIGN(4); + __init_array_start = .; + KEEP (*(SORT(.init_array.*))) + KEEP (*(.init_array)) + __init_array_end = .; + + . = ALIGN(4); + KEEP (*crtbegin.o(.ctors)) + KEEP (*(EXCLUDE_FILE (*crtend.o) .ctors)) + KEEP (*(SORT(.ctors.*))) + KEEP (*crtend.o(.ctors)) + + . = ALIGN(4); + KEEP(*(.fini)) + + . = ALIGN(4); + __fini_array_start = .; + KEEP (*(.fini_array)) + KEEP (*(SORT(.fini_array.*))) + __fini_array_end = .; + + KEEP (*crtbegin.o(.dtors)) + KEEP (*(EXCLUDE_FILE (*crtend.o) .dtors)) + KEEP (*(SORT(.dtors.*))) + KEEP (*crtend.o(.dtors)) + + . = ALIGN(4); + _efixed = .; /* End of text section */ + } > rom + + /* .ARM.exidx is sorted, so has to go in its own output section. */ + PROVIDE_HIDDEN (__exidx_start = .); + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > rom + PROVIDE_HIDDEN (__exidx_end = .); + + . = ALIGN(4); + _etext = .; + + .relocate : AT (_etext) + { + . = ALIGN(4); + _srelocate = .; + *(.ramfunc .ramfunc.*); + *(.data .data.*); + . = ALIGN(4); + _erelocate = .; + } > ram + + /* .bss section which is used for uninitialized data */ + .bss (NOLOAD) : + { + . = ALIGN(4); + _sbss = . ; + _szero = .; + *(.bss .bss.*) + *(COMMON) + . = ALIGN(4); + _ebss = . ; + _ezero = .; + } > ram + + /* stack section */ + .stack (NOLOAD): + { + . = ALIGN(8); + _sstack = .; + . = . + STACK_SIZE; + . = ALIGN(8); + _estack = .; + } > ram + + . = ALIGN(4); + _end = . ; +} diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/make/Makefile.sam.in b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/make/Makefile.sam.in new file mode 100644 index 0000000..f184a62 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/make/Makefile.sam.in @@ -0,0 +1,502 @@ +# List of available make goals: +# +# all Default target, builds the project +# clean Clean up the project +# rebuild Rebuild the project +# debug_flash Builds the project and debug in flash +# debug_sram Builds the project and debug in sram +# +# doc Build the documentation +# cleandoc Clean up the documentation +# rebuilddoc Rebuild the documentation +# +# \file +# +# Copyright (c) 2011 - 2014 Atmel Corporation. All rights reserved. +# +# \asf_license_start +# +# \page License +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# 1. Redistributions of source code must retain the above copyright notice, +# this list of conditions and the following disclaimer. +# +# 2. Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# 3. The name of Atmel may not be used to endorse or promote products derived +# from this software without specific prior written permission. +# +# 4. This software may only be redistributed and used in connection with an +# Atmel microcontroller product. +# +# THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED +# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE +# EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. +# +# \asf_license_stop +# + +# Include the config.mk file from the current working path, e.g., where the +# user called make. +include config.mk + +# Tool to use to generate documentation from the source code +DOCGEN ?= doxygen + +# Look for source files relative to the top-level source directory +VPATH := $(PRJ_PATH) + +# Output target file +project_type := $(PROJECT_TYPE) + +# Output target file +ifeq ($(project_type),flash) +target := $(TARGET_FLASH) +linker_script := $(PRJ_PATH)/$(LINKER_SCRIPT_FLASH) +debug_script := $(PRJ_PATH)/$(DEBUG_SCRIPT_FLASH) +else +target := $(TARGET_SRAM) +linker_script := $(PRJ_PATH)/$(LINKER_SCRIPT_SRAM) +debug_script := $(PRJ_PATH)/$(DEBUG_SCRIPT_SRAM) +endif + +# Output project name (target name minus suffix) +project := $(basename $(target)) + +# Output target file (typically ELF or static library) +ifeq ($(suffix $(target)),.a) +target_type := lib +else +ifeq ($(suffix $(target)),.elf) +target_type := elf +else +$(error "Target type $(target_type) is not supported") +endif +endif + +# Allow override of operating system detection. The user can add OS=Linux or +# OS=Windows on the command line to explicit set the host OS. +# +# This allows to work around broken uname utility on certain systems. +ifdef OS + ifeq ($(strip $(OS)), Linux) + os_type := Linux + endif + ifeq ($(strip $(OS)), Windows) + os_type := windows32_64 + endif +endif + +os_type ?= $(strip $(shell uname)) + +ifeq ($(os_type),windows32) +os := Windows +else +ifeq ($(os_type),windows64) +os := Windows +else +ifeq ($(os_type),windows32_64) +os ?= Windows +else +ifeq ($(os_type),) +os := Windows +else +# Default to Linux style operating system. Both Cygwin and mingw are fully +# compatible (for this Makefile) with Linux. +os := Linux +endif +endif +endif +endif + +# Output documentation directory and configuration file. +docdir := ../doxygen/html +doccfg := ../doxygen/doxyfile.doxygen + +CROSS ?= arm-none-eabi- +AR := $(CROSS)ar +AS := $(CROSS)as +CC := $(CROSS)gcc +CPP := $(CROSS)gcc -E +CXX := $(CROSS)g++ +LD := $(CROSS)g++ +NM := $(CROSS)nm +OBJCOPY := $(CROSS)objcopy +OBJDUMP := $(CROSS)objdump +SIZE := $(CROSS)size +GDB := $(CROSS)gdb + +RM := rm +ifeq ($(os),Windows) +RMDIR := rmdir /S /Q +else +RMDIR := rmdir -p --ignore-fail-on-non-empty +endif + +# On Windows, we need to override the shell to force the use of cmd.exe +ifeq ($(os),Windows) +SHELL := cmd +endif + +# Strings for beautifying output +MSG_CLEAN_FILES = "RM *.o *.d" +MSG_CLEAN_DIRS = "RMDIR $(strip $(clean-dirs))" +MSG_CLEAN_DOC = "RMDIR $(docdir)" +MSG_MKDIR = "MKDIR $(dir $@)" + +MSG_INFO = "INFO " +MSG_PREBUILD = "PREBUILD $(PREBUILD_CMD)" +MSG_POSTBUILD = "POSTBUILD $(POSTBUILD_CMD)" + +MSG_ARCHIVING = "AR $@" +MSG_ASSEMBLING = "AS $@" +MSG_BINARY_IMAGE = "OBJCOPY $@" +MSG_COMPILING = "CC $@" +MSG_COMPILING_CXX = "CXX $@" +MSG_EXTENDED_LISTING = "OBJDUMP $@" +MSG_IHEX_IMAGE = "OBJCOPY $@" +MSG_LINKING = "LN $@" +MSG_PREPROCESSING = "CPP $@" +MSG_SIZE = "SIZE $@" +MSG_SYMBOL_TABLE = "NM $@" + +MSG_GENERATING_DOC = "DOXYGEN $(docdir)" + +# Don't use make's built-in rules and variables +MAKEFLAGS += -rR + +# Don't print 'Entering directory ...' +MAKEFLAGS += --no-print-directory + +# Function for reversing the order of a list +reverse = $(if $(1),$(call reverse,$(wordlist 2,$(words $(1)),$(1)))) $(firstword $(1)) + +# Hide command output by default, but allow the user to override this +# by adding V=1 on the command line. +# +# This is inspired by the Kbuild system used by the Linux kernel. +ifdef V + ifeq ("$(origin V)", "command line") + VERBOSE = $(V) + endif +endif +ifndef VERBOSE + VERBOSE = 0 +endif + +ifeq ($(VERBOSE), 1) + Q = +else + Q = @ +endif + +arflags-gnu-y := $(ARFLAGS) +asflags-gnu-y := $(ASFLAGS) +cflags-gnu-y := $(CFLAGS) +cxxflags-gnu-y := $(CXXFLAGS) +cppflags-gnu-y := $(CPPFLAGS) +cpuflags-gnu-y := +dbgflags-gnu-y := $(DBGFLAGS) +libflags-gnu-y := $(foreach LIB,$(LIBS),-l$(LIB)) +ldflags-gnu-y := $(LDFLAGS) +flashflags-gnu-y := +clean-files := +clean-dirs := + +clean-files += $(wildcard $(target) $(project).map) +clean-files += $(wildcard $(project).hex $(project).bin) +clean-files += $(wildcard $(project).lss $(project).sym) +clean-files += $(wildcard $(build)) + +# Use pipes instead of temporary files for communication between processes +cflags-gnu-y += -pipe +asflags-gnu-y += -pipe +ldflags-gnu-y += -pipe + +# Archiver flags. +arflags-gnu-y += rcs + +# Always enable warnings. And be very careful about implicit +# declarations. +cflags-gnu-y += -Wall -Wstrict-prototypes -Wmissing-prototypes +cflags-gnu-y += -Werror-implicit-function-declaration +cxxflags-gnu-y += -Wall +# IAR doesn't allow arithmetic on void pointers, so warn about that. +cflags-gnu-y += -Wpointer-arith +cxxflags-gnu-y += -Wpointer-arith + +# Preprocessor flags. +cppflags-gnu-y += $(foreach INC,$(addprefix $(PRJ_PATH)/,$(INC_PATH)),-I$(INC)) +asflags-gnu-y += $(foreach INC,$(addprefix $(PRJ_PATH)/,$(INC_PATH)),'-Wa,-I$(INC)') + +# CPU specific flags. +cpuflags-gnu-y += -mcpu=$(ARCH) -mthumb -D=__$(PART)__ + +# Dependency file flags. +depflags = -MD -MP -MQ $@ + +# Debug specific flags. +ifdef BUILD_DEBUG_LEVEL +dbgflags-gnu-y += -g$(BUILD_DEBUG_LEVEL) +else +dbgflags-gnu-y += -g3 +endif + +# Optimization specific flags. +ifdef BUILD_OPTIMIZATION +optflags-gnu-y = -O$(BUILD_OPTIMIZATION) +else +optflags-gnu-y = $(OPTIMIZATION) +endif + +# Always preprocess assembler files. +asflags-gnu-y += -x assembler-with-cpp +# Compile C files using the GNU99 standard. +cflags-gnu-y += -std=gnu99 +# Compile C++ files using the GNU++98 standard. +cxxflags-gnu-y += -std=gnu++98 + +# Don't use strict aliasing (very common in embedded applications). +cflags-gnu-y += -fno-strict-aliasing +cxxflags-gnu-y += -fno-strict-aliasing + +# Separate each function and data into its own separate section to allow +# garbage collection of unused sections. +cflags-gnu-y += -ffunction-sections -fdata-sections +cxxflags-gnu-y += -ffunction-sections -fdata-sections + +# Various cflags. +cflags-gnu-y += -Wchar-subscripts -Wcomment -Wformat=2 -Wimplicit-int +cflags-gnu-y += -Wmain -Wparentheses +cflags-gnu-y += -Wsequence-point -Wreturn-type -Wswitch -Wtrigraphs -Wunused +cflags-gnu-y += -Wuninitialized -Wunknown-pragmas -Wfloat-equal -Wundef +cflags-gnu-y += -Wshadow -Wbad-function-cast -Wwrite-strings +cflags-gnu-y += -Wsign-compare -Waggregate-return +cflags-gnu-y += -Wmissing-declarations +cflags-gnu-y += -Wformat -Wmissing-format-attribute -Wno-deprecated-declarations +cflags-gnu-y += -Wpacked -Wredundant-decls -Wnested-externs -Wlong-long +cflags-gnu-y += -Wunreachable-code +cflags-gnu-y += -Wcast-align +cflags-gnu-y += --param max-inline-insns-single=500 + +# To reduce application size use only integer printf function. +cflags-gnu-y += -Dprintf=iprintf + +# Use newlib-nano to reduce application size +ldflags-gnu-y += --specs=nano.specs + +# Garbage collect unreferred sections when linking. +ldflags-gnu-y += -Wl,--gc-sections + +# Use the linker script if provided by the project. +ifneq ($(strip $(linker_script)),) +ldflags-gnu-y += -Wl,-T $(linker_script) +endif + +# Output a link map file and a cross reference table +ldflags-gnu-y += -Wl,-Map=$(project).map,--cref + +# Add library search paths relative to the top level directory. +ldflags-gnu-y += $(foreach _LIB_PATH,$(addprefix $(PRJ_PATH)/,$(LIB_PATH)),-L$(_LIB_PATH)) + +a_flags = $(cpuflags-gnu-y) $(depflags) $(cppflags-gnu-y) $(asflags-gnu-y) -D__ASSEMBLY__ +c_flags = $(cpuflags-gnu-y) $(dbgflags-gnu-y) $(depflags) $(optflags-gnu-y) $(cppflags-gnu-y) $(cflags-gnu-y) +cxx_flags= $(cpuflags-gnu-y) $(dbgflags-gnu-y) $(depflags) $(optflags-gnu-y) $(cppflags-gnu-y) $(cxxflags-gnu-y) +l_flags = -Wl,--entry=Reset_Handler -Wl,--cref $(cpuflags-gnu-y) $(optflags-gnu-y) $(ldflags-gnu-y) +ar_flags = $(arflags-gnu-y) + +# Source files list and part informations must already be included before +# running this makefile + +# If a custom build directory is specified, use it -- force trailing / in directory name. +ifdef BUILD_DIR + build-dir := $(dir $(BUILD_DIR))$(if $(notdir $(BUILD_DIR)),$(notdir $(BUILD_DIR))/) +else + build-dir = +endif + +# Create object files list from source files list. +obj-y := $(addprefix $(build-dir), $(addsuffix .o,$(basename $(CSRCS) $(ASSRCS)))) +# Create dependency files list from source files list. +dep-files := $(wildcard $(foreach f,$(obj-y),$(basename $(f)).d)) + +clean-files += $(wildcard $(obj-y)) +clean-files += $(dep-files) + +clean-dirs += $(call reverse,$(sort $(wildcard $(dir $(obj-y))))) + +# Default target. +.PHONY: all +ifeq ($(project_type),all) +all: + $(MAKE) all PROJECT_TYPE=flash + $(MAKE) all PROJECT_TYPE=sram +else +ifeq ($(target_type),lib) +all: $(target) $(project).lss $(project).sym +else +ifeq ($(target_type),elf) +all: prebuild $(target) $(project).lss $(project).sym $(project).hex $(project).bin postbuild +endif +endif +endif + +prebuild: +ifneq ($(strip $(PREBUILD_CMD)),) + @echo $(MSG_PREBUILD) + $(Q)$(PREBUILD_CMD) +endif + +postbuild: +ifneq ($(strip $(POSTBUILD_CMD)),) + @echo $(MSG_POSTBUILD) + $(Q)$(POSTBUILD_CMD) +endif + +# Clean up the project. +.PHONY: clean +clean: + @$(if $(strip $(clean-files)),echo $(MSG_CLEAN_FILES)) + $(if $(strip $(clean-files)),$(Q)$(RM) $(clean-files),) + @$(if $(strip $(clean-dirs)),echo $(MSG_CLEAN_DIRS)) +# Remove created directories, and make sure we only remove existing +# directories, since recursive rmdir might help us a bit on the way. +ifeq ($(os),Windows) + $(Q)$(if $(strip $(clean-dirs)), \ + $(RMDIR) $(strip $(subst /,\,$(clean-dirs)))) +else + $(Q)$(if $(strip $(clean-dirs)), \ + for directory in $(strip $(clean-dirs)); do \ + if [ -d "$$directory" ]; then \ + $(RMDIR) $$directory; \ + fi \ + done \ + ) +endif + +# Rebuild the project. +.PHONY: rebuild +rebuild: clean all + +# Debug the project in flash. +.PHONY: debug_flash +debug_flash: all + $(GDB) -x "$(PRJ_PATH)/$(DEBUG_SCRIPT_FLASH)" -ex "reset" -readnow -se $(TARGET_FLASH) + +# Debug the project in sram. +.PHONY: debug_sram +debug_sram: all + $(GDB) -x "$(PRJ_PATH)/$(DEBUG_SCRIPT_SRAM)" -ex "reset" -readnow -se $(TARGET_SRAM) + +.PHONY: objfiles +objfiles: $(obj-y) + +# Create object files from C source files. +$(build-dir)%.o: %.c $(MAKEFILE_PATH) config.mk + $(Q)test -d $(dir $@) || echo $(MSG_MKDIR) +ifeq ($(os),Windows) + $(Q)test -d $(patsubst %/,%,$(dir $@)) || mkdir $(subst /,\,$(dir $@)) +else + $(Q)test -d $(dir $@) || mkdir -p $(dir $@) +endif + @echo $(MSG_COMPILING) + $(Q)$(CC) $(c_flags) -c $< -o $@ + +# Create object files from C++ source files. +$(build-dir)%.o: %.cpp $(MAKEFILE_PATH) config.mk + $(Q)test -d $(dir $@) || echo $(MSG_MKDIR) +ifeq ($(os),Windows) + $(Q)test -d $(patsubst %/,%,$(dir $@)) || mkdir $(subst /,\,$(dir $@)) +else + $(Q)test -d $(dir $@) || mkdir -p $(dir $@) +endif + @echo $(MSG_COMPILING_CXX) + $(Q)$(CXX) $(cxx_flags) -c $< -o $@ + +# Preprocess and assemble: create object files from assembler source files. +$(build-dir)%.o: %.S $(MAKEFILE_PATH) config.mk + $(Q)test -d $(dir $@) || echo $(MSG_MKDIR) +ifeq ($(os),Windows) + $(Q)test -d $(patsubst %/,%,$(dir $@)) || mkdir $(subst /,\,$(dir $@)) +else + $(Q)test -d $(dir $@) || mkdir -p $(dir $@) +endif + @echo $(MSG_ASSEMBLING) + $(Q)$(CC) $(a_flags) -c $< -o $@ + +# Include all dependency files to add depedency to all header files in use. +include $(dep-files) + +ifeq ($(target_type),lib) +# Archive object files into an archive +$(target): $(MAKEFILE_PATH) config.mk $(obj-y) + @echo $(MSG_ARCHIVING) + $(Q)$(AR) $(ar_flags) $@ $(obj-y) + @echo $(MSG_SIZE) + $(Q)$(SIZE) -Bxt $@ +else +ifeq ($(target_type),elf) +# Link the object files into an ELF file. Also make sure the target is rebuilt +# if the common Makefile.sam.in or project config.mk is changed. +$(target): $(linker_script) $(MAKEFILE_PATH) config.mk $(obj-y) + @echo $(MSG_LINKING) + $(Q)$(LD) $(l_flags) $(obj-y) $(libflags-gnu-y) -o $@ + @echo $(MSG_SIZE) + $(Q)$(SIZE) -Ax $@ + $(Q)$(SIZE) -Bx $@ +endif +endif + +# Create extended function listing from target output file. +%.lss: $(target) + @echo $(MSG_EXTENDED_LISTING) + $(Q)$(OBJDUMP) -h -S $< > $@ + +# Create symbol table from target output file. +%.sym: $(target) + @echo $(MSG_SYMBOL_TABLE) + $(Q)$(NM) -n $< > $@ + +# Create Intel HEX image from ELF output file. +%.hex: $(target) + @echo $(MSG_IHEX_IMAGE) + $(Q)$(OBJCOPY) -O ihex $(flashflags-gnu-y) $< $@ + +# Create binary image from ELF output file. +%.bin: $(target) + @echo $(MSG_BINARY_IMAGE) + $(Q)$(OBJCOPY) -O binary $< $@ + +# Provide information about the detected host operating system. +.SECONDARY: info-os +info-os: + @echo $(MSG_INFO)$(os) build host detected + +# Build Doxygen generated documentation. +.PHONY: doc +doc: + @echo $(MSG_GENERATING_DOC) + $(Q)cd $(dir $(doccfg)) && $(DOCGEN) $(notdir $(doccfg)) + +# Clean Doxygen generated documentation. +.PHONY: cleandoc +cleandoc: + @$(if $(wildcard $(docdir)),echo $(MSG_CLEAN_DOC)) + $(Q)$(if $(wildcard $(docdir)),$(RM) --recursive $(docdir)) + +# Rebuild the Doxygen generated documentation. +.PHONY: rebuilddoc +rebuilddoc: cleandoc doc diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/preprocessor/mrecursion.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/preprocessor/mrecursion.h new file mode 100644 index 0000000..21ba6d5 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/preprocessor/mrecursion.h @@ -0,0 +1,595 @@ +/** + * \file + * + * \brief Preprocessor macro recursion utils. + * + * Copyright (C) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _MRECURSION_H_ +#define _MRECURSION_H_ + +/** + * \defgroup group_sam0_utils_mrecursion Preprocessor - Macro Recursion + * + * \ingroup group_sam0_utils + * + * @{ + */ + +#include "preprocessor.h" + +#define DEC_256 255 +#define DEC_255 254 +#define DEC_254 253 +#define DEC_253 252 +#define DEC_252 251 +#define DEC_251 250 +#define DEC_250 249 +#define DEC_249 248 +#define DEC_248 247 +#define DEC_247 246 +#define DEC_246 245 +#define DEC_245 244 +#define DEC_244 243 +#define DEC_243 242 +#define DEC_242 241 +#define DEC_241 240 +#define DEC_240 239 +#define DEC_239 238 +#define DEC_238 237 +#define DEC_237 236 +#define DEC_236 235 +#define DEC_235 234 +#define DEC_234 233 +#define DEC_233 232 +#define DEC_232 231 +#define DEC_231 230 +#define DEC_230 229 +#define DEC_229 228 +#define DEC_228 227 +#define DEC_227 226 +#define DEC_226 225 +#define DEC_225 224 +#define DEC_224 223 +#define DEC_223 222 +#define DEC_222 221 +#define DEC_221 220 +#define DEC_220 219 +#define DEC_219 218 +#define DEC_218 217 +#define DEC_217 216 +#define DEC_216 215 +#define DEC_215 214 +#define DEC_214 213 +#define DEC_213 212 +#define DEC_212 211 +#define DEC_211 210 +#define DEC_210 209 +#define DEC_209 208 +#define DEC_208 207 +#define DEC_207 206 +#define DEC_206 205 +#define DEC_205 204 +#define DEC_204 203 +#define DEC_203 202 +#define DEC_202 201 +#define DEC_201 200 +#define DEC_200 199 +#define DEC_199 198 +#define DEC_198 197 +#define DEC_197 196 +#define DEC_196 195 +#define DEC_195 194 +#define DEC_194 193 +#define DEC_193 192 +#define DEC_192 191 +#define DEC_191 190 +#define DEC_190 189 +#define DEC_189 188 +#define DEC_188 187 +#define DEC_187 186 +#define DEC_186 185 +#define DEC_185 184 +#define DEC_184 183 +#define DEC_183 182 +#define DEC_182 181 +#define DEC_181 180 +#define DEC_180 179 +#define DEC_179 178 +#define DEC_178 177 +#define DEC_177 176 +#define DEC_176 175 +#define DEC_175 174 +#define DEC_174 173 +#define DEC_173 172 +#define DEC_172 171 +#define DEC_171 170 +#define DEC_170 169 +#define DEC_169 168 +#define DEC_168 167 +#define DEC_167 166 +#define DEC_166 165 +#define DEC_165 164 +#define DEC_164 163 +#define DEC_163 162 +#define DEC_162 161 +#define DEC_161 160 +#define DEC_160 159 +#define DEC_159 158 +#define DEC_158 157 +#define DEC_157 156 +#define DEC_156 155 +#define DEC_155 154 +#define DEC_154 153 +#define DEC_153 152 +#define DEC_152 151 +#define DEC_151 150 +#define DEC_150 149 +#define DEC_149 148 +#define DEC_148 147 +#define DEC_147 146 +#define DEC_146 145 +#define DEC_145 144 +#define DEC_144 143 +#define DEC_143 142 +#define DEC_142 141 +#define DEC_141 140 +#define DEC_140 139 +#define DEC_139 138 +#define DEC_138 137 +#define DEC_137 136 +#define DEC_136 135 +#define DEC_135 134 +#define DEC_134 133 +#define DEC_133 132 +#define DEC_132 131 +#define DEC_131 130 +#define DEC_130 129 +#define DEC_129 128 +#define DEC_128 127 +#define DEC_127 126 +#define DEC_126 125 +#define DEC_125 124 +#define DEC_124 123 +#define DEC_123 122 +#define DEC_122 121 +#define DEC_121 120 +#define DEC_120 119 +#define DEC_119 118 +#define DEC_118 117 +#define DEC_117 116 +#define DEC_116 115 +#define DEC_115 114 +#define DEC_114 113 +#define DEC_113 112 +#define DEC_112 111 +#define DEC_111 110 +#define DEC_110 109 +#define DEC_109 108 +#define DEC_108 107 +#define DEC_107 106 +#define DEC_106 105 +#define DEC_105 104 +#define DEC_104 103 +#define DEC_103 102 +#define DEC_102 101 +#define DEC_101 100 +#define DEC_100 99 +#define DEC_99 98 +#define DEC_98 97 +#define DEC_97 96 +#define DEC_96 95 +#define DEC_95 94 +#define DEC_94 93 +#define DEC_93 92 +#define DEC_92 91 +#define DEC_91 90 +#define DEC_90 89 +#define DEC_89 88 +#define DEC_88 87 +#define DEC_87 86 +#define DEC_86 85 +#define DEC_85 84 +#define DEC_84 83 +#define DEC_83 82 +#define DEC_82 81 +#define DEC_81 80 +#define DEC_80 79 +#define DEC_79 78 +#define DEC_78 77 +#define DEC_77 76 +#define DEC_76 75 +#define DEC_75 74 +#define DEC_74 73 +#define DEC_73 72 +#define DEC_72 71 +#define DEC_71 70 +#define DEC_70 69 +#define DEC_69 68 +#define DEC_68 67 +#define DEC_67 66 +#define DEC_66 65 +#define DEC_65 64 +#define DEC_64 63 +#define DEC_63 62 +#define DEC_62 61 +#define DEC_61 60 +#define DEC_60 59 +#define DEC_59 58 +#define DEC_58 57 +#define DEC_57 56 +#define DEC_56 55 +#define DEC_55 54 +#define DEC_54 53 +#define DEC_53 52 +#define DEC_52 51 +#define DEC_51 50 +#define DEC_50 49 +#define DEC_49 48 +#define DEC_48 47 +#define DEC_47 46 +#define DEC_46 45 +#define DEC_45 44 +#define DEC_44 43 +#define DEC_43 42 +#define DEC_42 41 +#define DEC_41 40 +#define DEC_40 39 +#define DEC_39 38 +#define DEC_38 37 +#define DEC_37 36 +#define DEC_36 35 +#define DEC_35 34 +#define DEC_34 33 +#define DEC_33 32 +#define DEC_32 31 +#define DEC_31 30 +#define DEC_30 29 +#define DEC_29 28 +#define DEC_28 27 +#define DEC_27 26 +#define DEC_26 25 +#define DEC_25 24 +#define DEC_24 23 +#define DEC_23 22 +#define DEC_22 21 +#define DEC_21 20 +#define DEC_20 19 +#define DEC_19 18 +#define DEC_18 17 +#define DEC_17 16 +#define DEC_16 15 +#define DEC_15 14 +#define DEC_14 13 +#define DEC_13 12 +#define DEC_12 11 +#define DEC_11 10 +#define DEC_10 9 +#define DEC_9 8 +#define DEC_8 7 +#define DEC_7 6 +#define DEC_6 5 +#define DEC_5 4 +#define DEC_4 3 +#define DEC_3 2 +#define DEC_2 1 +#define DEC_1 0 +#define DEC_(n) DEC_##n + + +/** Maximal number of repetitions supported by MRECURSION. */ +#define MRECURSION_LIMIT 256 + +/** \brief Macro recursion. + * + * This macro represents a horizontal repetition construct. + * + * \param[in] count The number of repetitious calls to macro. Valid values + * range from 0 to MRECURSION_LIMIT. + * \param[in] macro A binary operation of the form macro(data, n). This macro + * is expanded by MRECURSION with the current repetition number + * and the auxiliary data argument. + * \param[in] data A recursive threshold, building on this to decline by times + * defined with param count. + * + * \return macro(data-count+1,0) macro(data-count+2,1)...macro(data,count-1) + */ +#define MRECURSION(count, macro, data) TPASTE2(MRECURSION, count) (macro, data) + +#define MRECURSION0( macro, data) +#define MRECURSION1( macro, data) MRECURSION0( macro, DEC_(data)) macro(data, 0) +#define MRECURSION2( macro, data) MRECURSION1( macro, DEC_(data)) macro(data, 1) +#define MRECURSION3( macro, data) MRECURSION2( macro, DEC_(data)) macro(data, 2) +#define MRECURSION4( macro, data) MRECURSION3( macro, DEC_(data)) macro(data, 3) +#define MRECURSION5( macro, data) MRECURSION4( macro, DEC_(data)) macro(data, 4) +#define MRECURSION6( macro, data) MRECURSION5( macro, DEC_(data)) macro(data, 5) +#define MRECURSION7( macro, data) MRECURSION6( macro, DEC_(data)) macro(data, 6) +#define MRECURSION8( macro, data) MRECURSION7( macro, DEC_(data)) macro(data, 7) +#define MRECURSION9( macro, data) MRECURSION8( macro, DEC_(data)) macro(data, 8) +#define MRECURSION10( macro, data) MRECURSION9( macro, DEC_(data)) macro(data, 9) +#define MRECURSION11( macro, data) MRECURSION10( macro, DEC_(data)) macro(data, 10) +#define MRECURSION12( macro, data) MRECURSION11( macro, DEC_(data)) macro(data, 11) +#define MRECURSION13( macro, data) MRECURSION12( macro, DEC_(data)) macro(data, 12) +#define MRECURSION14( macro, data) MRECURSION13( macro, DEC_(data)) macro(data, 13) +#define MRECURSION15( macro, data) MRECURSION14( macro, DEC_(data)) macro(data, 14) +#define MRECURSION16( macro, data) MRECURSION15( macro, DEC_(data)) macro(data, 15) +#define MRECURSION17( macro, data) MRECURSION16( macro, DEC_(data)) macro(data, 16) +#define MRECURSION18( macro, data) MRECURSION17( macro, DEC_(data)) macro(data, 17) +#define MRECURSION19( macro, data) MRECURSION18( macro, DEC_(data)) macro(data, 18) +#define MRECURSION20( macro, data) MRECURSION19( macro, DEC_(data)) macro(data, 19) +#define MRECURSION21( macro, data) MRECURSION20( macro, DEC_(data)) macro(data, 20) +#define MRECURSION22( macro, data) MRECURSION21( macro, DEC_(data)) macro(data, 21) +#define MRECURSION23( macro, data) MRECURSION22( macro, DEC_(data)) macro(data, 22) +#define MRECURSION24( macro, data) MRECURSION23( macro, DEC_(data)) macro(data, 23) +#define MRECURSION25( macro, data) MRECURSION24( macro, DEC_(data)) macro(data, 24) +#define MRECURSION26( macro, data) MRECURSION25( macro, DEC_(data)) macro(data, 25) +#define MRECURSION27( macro, data) MRECURSION26( macro, DEC_(data)) macro(data, 26) +#define MRECURSION28( macro, data) MRECURSION27( macro, DEC_(data)) macro(data, 27) +#define MRECURSION29( macro, data) MRECURSION28( macro, DEC_(data)) macro(data, 28) +#define MRECURSION30( macro, data) MRECURSION29( macro, DEC_(data)) macro(data, 29) +#define MRECURSION31( macro, data) MRECURSION30( macro, DEC_(data)) macro(data, 30) +#define MRECURSION32( macro, data) MRECURSION31( macro, DEC_(data)) macro(data, 31) +#define MRECURSION33( macro, data) MRECURSION32( macro, DEC_(data)) macro(data, 32) +#define MRECURSION34( macro, data) MRECURSION33( macro, DEC_(data)) macro(data, 33) +#define MRECURSION35( macro, data) MRECURSION34( macro, DEC_(data)) macro(data, 34) +#define MRECURSION36( macro, data) MRECURSION35( macro, DEC_(data)) macro(data, 35) +#define MRECURSION37( macro, data) MRECURSION36( macro, DEC_(data)) macro(data, 36) +#define MRECURSION38( macro, data) MRECURSION37( macro, DEC_(data)) macro(data, 37) +#define MRECURSION39( macro, data) MRECURSION38( macro, DEC_(data)) macro(data, 38) +#define MRECURSION40( macro, data) MRECURSION39( macro, DEC_(data)) macro(data, 39) +#define MRECURSION41( macro, data) MRECURSION40( macro, DEC_(data)) macro(data, 40) +#define MRECURSION42( macro, data) MRECURSION41( macro, DEC_(data)) macro(data, 41) +#define MRECURSION43( macro, data) MRECURSION42( macro, DEC_(data)) macro(data, 42) +#define MRECURSION44( macro, data) MRECURSION43( macro, DEC_(data)) macro(data, 43) +#define MRECURSION45( macro, data) MRECURSION44( macro, DEC_(data)) macro(data, 44) +#define MRECURSION46( macro, data) MRECURSION45( macro, DEC_(data)) macro(data, 45) +#define MRECURSION47( macro, data) MRECURSION46( macro, DEC_(data)) macro(data, 46) +#define MRECURSION48( macro, data) MRECURSION47( macro, DEC_(data)) macro(data, 47) +#define MRECURSION49( macro, data) MRECURSION48( macro, DEC_(data)) macro(data, 48) +#define MRECURSION50( macro, data) MRECURSION49( macro, DEC_(data)) macro(data, 49) +#define MRECURSION51( macro, data) MRECURSION50( macro, DEC_(data)) macro(data, 50) +#define MRECURSION52( macro, data) MRECURSION51( macro, DEC_(data)) macro(data, 51) +#define MRECURSION53( macro, data) MRECURSION52( macro, DEC_(data)) macro(data, 52) +#define MRECURSION54( macro, data) MRECURSION53( macro, DEC_(data)) macro(data, 53) +#define MRECURSION55( macro, data) MRECURSION54( macro, DEC_(data)) macro(data, 54) +#define MRECURSION56( macro, data) MRECURSION55( macro, DEC_(data)) macro(data, 55) +#define MRECURSION57( macro, data) MRECURSION56( macro, DEC_(data)) macro(data, 56) +#define MRECURSION58( macro, data) MRECURSION57( macro, DEC_(data)) macro(data, 57) +#define MRECURSION59( macro, data) MRECURSION58( macro, DEC_(data)) macro(data, 58) +#define MRECURSION60( macro, data) MRECURSION59( macro, DEC_(data)) macro(data, 59) +#define MRECURSION61( macro, data) MRECURSION60( macro, DEC_(data)) macro(data, 60) +#define MRECURSION62( macro, data) MRECURSION61( macro, DEC_(data)) macro(data, 61) +#define MRECURSION63( macro, data) MRECURSION62( macro, DEC_(data)) macro(data, 62) +#define MRECURSION64( macro, data) MRECURSION63( macro, DEC_(data)) macro(data, 63) +#define MRECURSION65( macro, data) MRECURSION64( macro, DEC_(data)) macro(data, 64) +#define MRECURSION66( macro, data) MRECURSION65( macro, DEC_(data)) macro(data, 65) +#define MRECURSION67( macro, data) MRECURSION66( macro, DEC_(data)) macro(data, 66) +#define MRECURSION68( macro, data) MRECURSION67( macro, DEC_(data)) macro(data, 67) +#define MRECURSION69( macro, data) MRECURSION68( macro, DEC_(data)) macro(data, 68) +#define MRECURSION70( macro, data) MRECURSION69( macro, DEC_(data)) macro(data, 69) +#define MRECURSION71( macro, data) MRECURSION70( macro, DEC_(data)) macro(data, 70) +#define MRECURSION72( macro, data) MRECURSION71( macro, DEC_(data)) macro(data, 71) +#define MRECURSION73( macro, data) MRECURSION72( macro, DEC_(data)) macro(data, 72) +#define MRECURSION74( macro, data) MRECURSION73( macro, DEC_(data)) macro(data, 73) +#define MRECURSION75( macro, data) MRECURSION74( macro, DEC_(data)) macro(data, 74) +#define MRECURSION76( macro, data) MRECURSION75( macro, DEC_(data)) macro(data, 75) +#define MRECURSION77( macro, data) MRECURSION76( macro, DEC_(data)) macro(data, 76) +#define MRECURSION78( macro, data) MRECURSION77( macro, DEC_(data)) macro(data, 77) +#define MRECURSION79( macro, data) MRECURSION78( macro, DEC_(data)) macro(data, 78) +#define MRECURSION80( macro, data) MRECURSION79( macro, DEC_(data)) macro(data, 79) +#define MRECURSION81( macro, data) MRECURSION80( macro, DEC_(data)) macro(data, 80) +#define MRECURSION82( macro, data) MRECURSION81( macro, DEC_(data)) macro(data, 81) +#define MRECURSION83( macro, data) MRECURSION82( macro, DEC_(data)) macro(data, 82) +#define MRECURSION84( macro, data) MRECURSION83( macro, DEC_(data)) macro(data, 83) +#define MRECURSION85( macro, data) MRECURSION84( macro, DEC_(data)) macro(data, 84) +#define MRECURSION86( macro, data) MRECURSION85( macro, DEC_(data)) macro(data, 85) +#define MRECURSION87( macro, data) MRECURSION86( macro, DEC_(data)) macro(data, 86) +#define MRECURSION88( macro, data) MRECURSION87( macro, DEC_(data)) macro(data, 87) +#define MRECURSION89( macro, data) MRECURSION88( macro, DEC_(data)) macro(data, 88) +#define MRECURSION90( macro, data) MRECURSION89( macro, DEC_(data)) macro(data, 89) +#define MRECURSION91( macro, data) MRECURSION90( macro, DEC_(data)) macro(data, 90) +#define MRECURSION92( macro, data) MRECURSION91( macro, DEC_(data)) macro(data, 91) +#define MRECURSION93( macro, data) MRECURSION92( macro, DEC_(data)) macro(data, 92) +#define MRECURSION94( macro, data) MRECURSION93( macro, DEC_(data)) macro(data, 93) +#define MRECURSION95( macro, data) MRECURSION94( macro, DEC_(data)) macro(data, 94) +#define MRECURSION96( macro, data) MRECURSION95( macro, DEC_(data)) macro(data, 95) +#define MRECURSION97( macro, data) MRECURSION96( macro, DEC_(data)) macro(data, 96) +#define MRECURSION98( macro, data) MRECURSION97( macro, DEC_(data)) macro(data, 97) +#define MRECURSION99( macro, data) MRECURSION98( macro, DEC_(data)) macro(data, 98) +#define MRECURSION100(macro, data) MRECURSION99( macro, DEC_(data)) macro(data, 99) +#define MRECURSION101(macro, data) MRECURSION100( macro, DEC_(data)) macro(data, 100) +#define MRECURSION102(macro, data) MRECURSION101( macro, DEC_(data)) macro(data, 101) +#define MRECURSION103(macro, data) MRECURSION102( macro, DEC_(data)) macro(data, 102) +#define MRECURSION104(macro, data) MRECURSION103( macro, DEC_(data)) macro(data, 103) +#define MRECURSION105(macro, data) MRECURSION104( macro, DEC_(data)) macro(data, 104) +#define MRECURSION106(macro, data) MRECURSION105( macro, DEC_(data)) macro(data, 105) +#define MRECURSION107(macro, data) MRECURSION106( macro, DEC_(data)) macro(data, 106) +#define MRECURSION108(macro, data) MRECURSION107( macro, DEC_(data)) macro(data, 107) +#define MRECURSION109(macro, data) MRECURSION108( macro, DEC_(data)) macro(data, 108) +#define MRECURSION110(macro, data) MRECURSION109( macro, DEC_(data)) macro(data, 109) +#define MRECURSION111(macro, data) MRECURSION110( macro, DEC_(data)) macro(data, 110) +#define MRECURSION112(macro, data) MRECURSION111( macro, DEC_(data)) macro(data, 111) +#define MRECURSION113(macro, data) MRECURSION112( macro, DEC_(data)) macro(data, 112) +#define MRECURSION114(macro, data) MRECURSION113( macro, DEC_(data)) macro(data, 113) +#define MRECURSION115(macro, data) MRECURSION114( macro, DEC_(data)) macro(data, 114) +#define MRECURSION116(macro, data) MRECURSION115( macro, DEC_(data)) macro(data, 115) +#define MRECURSION117(macro, data) MRECURSION116( macro, DEC_(data)) macro(data, 116) +#define MRECURSION118(macro, data) MRECURSION117( macro, DEC_(data)) macro(data, 117) +#define MRECURSION119(macro, data) MRECURSION118( macro, DEC_(data)) macro(data, 118) +#define MRECURSION120(macro, data) MRECURSION119( macro, DEC_(data)) macro(data, 119) +#define MRECURSION121(macro, data) MRECURSION120( macro, DEC_(data)) macro(data, 120) +#define MRECURSION122(macro, data) MRECURSION121( macro, DEC_(data)) macro(data, 121) +#define MRECURSION123(macro, data) MRECURSION122( macro, DEC_(data)) macro(data, 122) +#define MRECURSION124(macro, data) MRECURSION123( macro, DEC_(data)) macro(data, 123) +#define MRECURSION125(macro, data) MRECURSION124( macro, DEC_(data)) macro(data, 124) +#define MRECURSION126(macro, data) MRECURSION125( macro, DEC_(data)) macro(data, 125) +#define MRECURSION127(macro, data) MRECURSION126( macro, DEC_(data)) macro(data, 126) +#define MRECURSION128(macro, data) MRECURSION127( macro, DEC_(data)) macro(data, 127) +#define MRECURSION129(macro, data) MRECURSION128( macro, DEC_(data)) macro(data, 128) +#define MRECURSION130(macro, data) MRECURSION129( macro, DEC_(data)) macro(data, 129) +#define MRECURSION131(macro, data) MRECURSION130( macro, DEC_(data)) macro(data, 130) +#define MRECURSION132(macro, data) MRECURSION131( macro, DEC_(data)) macro(data, 131) +#define MRECURSION133(macro, data) MRECURSION132( macro, DEC_(data)) macro(data, 132) +#define MRECURSION134(macro, data) MRECURSION133( macro, DEC_(data)) macro(data, 133) +#define MRECURSION135(macro, data) MRECURSION134( macro, DEC_(data)) macro(data, 134) +#define MRECURSION136(macro, data) MRECURSION135( macro, DEC_(data)) macro(data, 135) +#define MRECURSION137(macro, data) MRECURSION136( macro, DEC_(data)) macro(data, 136) +#define MRECURSION138(macro, data) MRECURSION137( macro, DEC_(data)) macro(data, 137) +#define MRECURSION139(macro, data) MRECURSION138( macro, DEC_(data)) macro(data, 138) +#define MRECURSION140(macro, data) MRECURSION139( macro, DEC_(data)) macro(data, 139) +#define MRECURSION141(macro, data) MRECURSION140( macro, DEC_(data)) macro(data, 140) +#define MRECURSION142(macro, data) MRECURSION141( macro, DEC_(data)) macro(data, 141) +#define MRECURSION143(macro, data) MRECURSION142( macro, DEC_(data)) macro(data, 142) +#define MRECURSION144(macro, data) MRECURSION143( macro, DEC_(data)) macro(data, 143) +#define MRECURSION145(macro, data) MRECURSION144( macro, DEC_(data)) macro(data, 144) +#define MRECURSION146(macro, data) MRECURSION145( macro, DEC_(data)) macro(data, 145) +#define MRECURSION147(macro, data) MRECURSION146( macro, DEC_(data)) macro(data, 146) +#define MRECURSION148(macro, data) MRECURSION147( macro, DEC_(data)) macro(data, 147) +#define MRECURSION149(macro, data) MRECURSION148( macro, DEC_(data)) macro(data, 148) +#define MRECURSION150(macro, data) MRECURSION149( macro, DEC_(data)) macro(data, 149) +#define MRECURSION151(macro, data) MRECURSION150( macro, DEC_(data)) macro(data, 150) +#define MRECURSION152(macro, data) MRECURSION151( macro, DEC_(data)) macro(data, 151) +#define MRECURSION153(macro, data) MRECURSION152( macro, DEC_(data)) macro(data, 152) +#define MRECURSION154(macro, data) MRECURSION153( macro, DEC_(data)) macro(data, 153) +#define MRECURSION155(macro, data) MRECURSION154( macro, DEC_(data)) macro(data, 154) +#define MRECURSION156(macro, data) MRECURSION155( macro, DEC_(data)) macro(data, 155) +#define MRECURSION157(macro, data) MRECURSION156( macro, DEC_(data)) macro(data, 156) +#define MRECURSION158(macro, data) MRECURSION157( macro, DEC_(data)) macro(data, 157) +#define MRECURSION159(macro, data) MRECURSION158( macro, DEC_(data)) macro(data, 158) +#define MRECURSION160(macro, data) MRECURSION159( macro, DEC_(data)) macro(data, 159) +#define MRECURSION161(macro, data) MRECURSION160( macro, DEC_(data)) macro(data, 160) +#define MRECURSION162(macro, data) MRECURSION161( macro, DEC_(data)) macro(data, 161) +#define MRECURSION163(macro, data) MRECURSION162( macro, DEC_(data)) macro(data, 162) +#define MRECURSION164(macro, data) MRECURSION163( macro, DEC_(data)) macro(data, 163) +#define MRECURSION165(macro, data) MRECURSION164( macro, DEC_(data)) macro(data, 164) +#define MRECURSION166(macro, data) MRECURSION165( macro, DEC_(data)) macro(data, 165) +#define MRECURSION167(macro, data) MRECURSION166( macro, DEC_(data)) macro(data, 166) +#define MRECURSION168(macro, data) MRECURSION167( macro, DEC_(data)) macro(data, 167) +#define MRECURSION169(macro, data) MRECURSION168( macro, DEC_(data)) macro(data, 168) +#define MRECURSION170(macro, data) MRECURSION169( macro, DEC_(data)) macro(data, 169) +#define MRECURSION171(macro, data) MRECURSION170( macro, DEC_(data)) macro(data, 170) +#define MRECURSION172(macro, data) MRECURSION171( macro, DEC_(data)) macro(data, 171) +#define MRECURSION173(macro, data) MRECURSION172( macro, DEC_(data)) macro(data, 172) +#define MRECURSION174(macro, data) MRECURSION173( macro, DEC_(data)) macro(data, 173) +#define MRECURSION175(macro, data) MRECURSION174( macro, DEC_(data)) macro(data, 174) +#define MRECURSION176(macro, data) MRECURSION175( macro, DEC_(data)) macro(data, 175) +#define MRECURSION177(macro, data) MRECURSION176( macro, DEC_(data)) macro(data, 176) +#define MRECURSION178(macro, data) MRECURSION177( macro, DEC_(data)) macro(data, 177) +#define MRECURSION179(macro, data) MRECURSION178( macro, DEC_(data)) macro(data, 178) +#define MRECURSION180(macro, data) MRECURSION179( macro, DEC_(data)) macro(data, 179) +#define MRECURSION181(macro, data) MRECURSION180( macro, DEC_(data)) macro(data, 180) +#define MRECURSION182(macro, data) MRECURSION181( macro, DEC_(data)) macro(data, 181) +#define MRECURSION183(macro, data) MRECURSION182( macro, DEC_(data)) macro(data, 182) +#define MRECURSION184(macro, data) MRECURSION183( macro, DEC_(data)) macro(data, 183) +#define MRECURSION185(macro, data) MRECURSION184( macro, DEC_(data)) macro(data, 184) +#define MRECURSION186(macro, data) MRECURSION185( macro, DEC_(data)) macro(data, 185) +#define MRECURSION187(macro, data) MRECURSION186( macro, DEC_(data)) macro(data, 186) +#define MRECURSION188(macro, data) MRECURSION187( macro, DEC_(data)) macro(data, 187) +#define MRECURSION189(macro, data) MRECURSION188( macro, DEC_(data)) macro(data, 188) +#define MRECURSION190(macro, data) MRECURSION189( macro, DEC_(data)) macro(data, 189) +#define MRECURSION191(macro, data) MRECURSION190( macro, DEC_(data)) macro(data, 190) +#define MRECURSION192(macro, data) MRECURSION191( macro, DEC_(data)) macro(data, 191) +#define MRECURSION193(macro, data) MRECURSION192( macro, DEC_(data)) macro(data, 192) +#define MRECURSION194(macro, data) MRECURSION193( macro, DEC_(data)) macro(data, 193) +#define MRECURSION195(macro, data) MRECURSION194( macro, DEC_(data)) macro(data, 194) +#define MRECURSION196(macro, data) MRECURSION195( macro, DEC_(data)) macro(data, 195) +#define MRECURSION197(macro, data) MRECURSION196( macro, DEC_(data)) macro(data, 196) +#define MRECURSION198(macro, data) MRECURSION197( macro, DEC_(data)) macro(data, 197) +#define MRECURSION199(macro, data) MRECURSION198( macro, DEC_(data)) macro(data, 198) +#define MRECURSION200(macro, data) MRECURSION199( macro, DEC_(data)) macro(data, 199) +#define MRECURSION201(macro, data) MRECURSION200( macro, DEC_(data)) macro(data, 200) +#define MRECURSION202(macro, data) MRECURSION201( macro, DEC_(data)) macro(data, 201) +#define MRECURSION203(macro, data) MRECURSION202( macro, DEC_(data)) macro(data, 202) +#define MRECURSION204(macro, data) MRECURSION203( macro, DEC_(data)) macro(data, 203) +#define MRECURSION205(macro, data) MRECURSION204( macro, DEC_(data)) macro(data, 204) +#define MRECURSION206(macro, data) MRECURSION205( macro, DEC_(data)) macro(data, 205) +#define MRECURSION207(macro, data) MRECURSION206( macro, DEC_(data)) macro(data, 206) +#define MRECURSION208(macro, data) MRECURSION207( macro, DEC_(data)) macro(data, 207) +#define MRECURSION209(macro, data) MRECURSION208( macro, DEC_(data)) macro(data, 208) +#define MRECURSION210(macro, data) MRECURSION209( macro, DEC_(data)) macro(data, 209) +#define MRECURSION211(macro, data) MRECURSION210( macro, DEC_(data)) macro(data, 210) +#define MRECURSION212(macro, data) MRECURSION211( macro, DEC_(data)) macro(data, 211) +#define MRECURSION213(macro, data) MRECURSION212( macro, DEC_(data)) macro(data, 212) +#define MRECURSION214(macro, data) MRECURSION213( macro, DEC_(data)) macro(data, 213) +#define MRECURSION215(macro, data) MRECURSION214( macro, DEC_(data)) macro(data, 214) +#define MRECURSION216(macro, data) MRECURSION215( macro, DEC_(data)) macro(data, 215) +#define MRECURSION217(macro, data) MRECURSION216( macro, DEC_(data)) macro(data, 216) +#define MRECURSION218(macro, data) MRECURSION217( macro, DEC_(data)) macro(data, 217) +#define MRECURSION219(macro, data) MRECURSION218( macro, DEC_(data)) macro(data, 218) +#define MRECURSION220(macro, data) MRECURSION219( macro, DEC_(data)) macro(data, 219) +#define MRECURSION221(macro, data) MRECURSION220( macro, DEC_(data)) macro(data, 220) +#define MRECURSION222(macro, data) MRECURSION221( macro, DEC_(data)) macro(data, 221) +#define MRECURSION223(macro, data) MRECURSION222( macro, DEC_(data)) macro(data, 222) +#define MRECURSION224(macro, data) MRECURSION223( macro, DEC_(data)) macro(data, 223) +#define MRECURSION225(macro, data) MRECURSION224( macro, DEC_(data)) macro(data, 224) +#define MRECURSION226(macro, data) MRECURSION225( macro, DEC_(data)) macro(data, 225) +#define MRECURSION227(macro, data) MRECURSION226( macro, DEC_(data)) macro(data, 226) +#define MRECURSION228(macro, data) MRECURSION227( macro, DEC_(data)) macro(data, 227) +#define MRECURSION229(macro, data) MRECURSION228( macro, DEC_(data)) macro(data, 228) +#define MRECURSION230(macro, data) MRECURSION229( macro, DEC_(data)) macro(data, 229) +#define MRECURSION231(macro, data) MRECURSION230( macro, DEC_(data)) macro(data, 230) +#define MRECURSION232(macro, data) MRECURSION231( macro, DEC_(data)) macro(data, 231) +#define MRECURSION233(macro, data) MRECURSION232( macro, DEC_(data)) macro(data, 232) +#define MRECURSION234(macro, data) MRECURSION233( macro, DEC_(data)) macro(data, 233) +#define MRECURSION235(macro, data) MRECURSION234( macro, DEC_(data)) macro(data, 234) +#define MRECURSION236(macro, data) MRECURSION235( macro, DEC_(data)) macro(data, 235) +#define MRECURSION237(macro, data) MRECURSION236( macro, DEC_(data)) macro(data, 236) +#define MRECURSION238(macro, data) MRECURSION237( macro, DEC_(data)) macro(data, 237) +#define MRECURSION239(macro, data) MRECURSION238( macro, DEC_(data)) macro(data, 238) +#define MRECURSION240(macro, data) MRECURSION239( macro, DEC_(data)) macro(data, 239) +#define MRECURSION241(macro, data) MRECURSION240( macro, DEC_(data)) macro(data, 240) +#define MRECURSION242(macro, data) MRECURSION241( macro, DEC_(data)) macro(data, 241) +#define MRECURSION243(macro, data) MRECURSION242( macro, DEC_(data)) macro(data, 242) +#define MRECURSION244(macro, data) MRECURSION243( macro, DEC_(data)) macro(data, 243) +#define MRECURSION245(macro, data) MRECURSION244( macro, DEC_(data)) macro(data, 244) +#define MRECURSION246(macro, data) MRECURSION245( macro, DEC_(data)) macro(data, 245) +#define MRECURSION247(macro, data) MRECURSION246( macro, DEC_(data)) macro(data, 246) +#define MRECURSION248(macro, data) MRECURSION247( macro, DEC_(data)) macro(data, 247) +#define MRECURSION249(macro, data) MRECURSION248( macro, DEC_(data)) macro(data, 248) +#define MRECURSION250(macro, data) MRECURSION249( macro, DEC_(data)) macro(data, 249) +#define MRECURSION251(macro, data) MRECURSION250( macro, DEC_(data)) macro(data, 250) +#define MRECURSION252(macro, data) MRECURSION251( macro, DEC_(data)) macro(data, 251) +#define MRECURSION253(macro, data) MRECURSION252( macro, DEC_(data)) macro(data, 252) +#define MRECURSION254(macro, data) MRECURSION253( macro, DEC_(data)) macro(data, 253) +#define MRECURSION255(macro, data) MRECURSION254( macro, DEC_(data)) macro(data, 254) +#define MRECURSION256(macro, data) MRECURSION255( macro, DEC_(data)) macro(data, 255) + +/** @} */ + +#endif /* _MRECURSION_H_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/preprocessor/mrepeat.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/preprocessor/mrepeat.h new file mode 100644 index 0000000..179e5c2 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/preprocessor/mrepeat.h @@ -0,0 +1,335 @@ +/** + * \file + * + * \brief Preprocessor macro repeating utils. + * + * Copyright (C) 2012-2013 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _MREPEAT_H_ +#define _MREPEAT_H_ + +/** + * \defgroup group_sam0_utils_mrepeat Preprocessor - Macro Repeat + * + * \ingroup group_sam0_utils + * + * @{ + */ + +#include "preprocessor.h" + +/** Maximal number of repetitions supported by MREPEAT. */ +#define MREPEAT_LIMIT 256 + +/** \brief Macro repeat. + * + * This macro represents a horizontal repetition construct. + * + * \param[in] count The number of repetitious calls to macro. Valid values + * range from 0 to MREPEAT_LIMIT. + * \param[in] macro A binary operation of the form macro(n, data). This macro + * is expanded by MREPEAT with the current repetition number + * and the auxiliary data argument. + * \param[in] data Auxiliary data passed to macro. + * + * \return macro(0, data) macro(1, data) ... macro(count - 1, data) + */ +#define MREPEAT(count, macro, data) TPASTE2(MREPEAT, count) (macro, data) + +#define MREPEAT0( macro, data) +#define MREPEAT1( macro, data) MREPEAT0( macro, data) macro( 0, data) +#define MREPEAT2( macro, data) MREPEAT1( macro, data) macro( 1, data) +#define MREPEAT3( macro, data) MREPEAT2( macro, data) macro( 2, data) +#define MREPEAT4( macro, data) MREPEAT3( macro, data) macro( 3, data) +#define MREPEAT5( macro, data) MREPEAT4( macro, data) macro( 4, data) +#define MREPEAT6( macro, data) MREPEAT5( macro, data) macro( 5, data) +#define MREPEAT7( macro, data) MREPEAT6( macro, data) macro( 6, data) +#define MREPEAT8( macro, data) MREPEAT7( macro, data) macro( 7, data) +#define MREPEAT9( macro, data) MREPEAT8( macro, data) macro( 8, data) +#define MREPEAT10( macro, data) MREPEAT9( macro, data) macro( 9, data) +#define MREPEAT11( macro, data) MREPEAT10( macro, data) macro( 10, data) +#define MREPEAT12( macro, data) MREPEAT11( macro, data) macro( 11, data) +#define MREPEAT13( macro, data) MREPEAT12( macro, data) macro( 12, data) +#define MREPEAT14( macro, data) MREPEAT13( macro, data) macro( 13, data) +#define MREPEAT15( macro, data) MREPEAT14( macro, data) macro( 14, data) +#define MREPEAT16( macro, data) MREPEAT15( macro, data) macro( 15, data) +#define MREPEAT17( macro, data) MREPEAT16( macro, data) macro( 16, data) +#define MREPEAT18( macro, data) MREPEAT17( macro, data) macro( 17, data) +#define MREPEAT19( macro, data) MREPEAT18( macro, data) macro( 18, data) +#define MREPEAT20( macro, data) MREPEAT19( macro, data) macro( 19, data) +#define MREPEAT21( macro, data) MREPEAT20( macro, data) macro( 20, data) +#define MREPEAT22( macro, data) MREPEAT21( macro, data) macro( 21, data) +#define MREPEAT23( macro, data) MREPEAT22( macro, data) macro( 22, data) +#define MREPEAT24( macro, data) MREPEAT23( macro, data) macro( 23, data) +#define MREPEAT25( macro, data) MREPEAT24( macro, data) macro( 24, data) +#define MREPEAT26( macro, data) MREPEAT25( macro, data) macro( 25, data) +#define MREPEAT27( macro, data) MREPEAT26( macro, data) macro( 26, data) +#define MREPEAT28( macro, data) MREPEAT27( macro, data) macro( 27, data) +#define MREPEAT29( macro, data) MREPEAT28( macro, data) macro( 28, data) +#define MREPEAT30( macro, data) MREPEAT29( macro, data) macro( 29, data) +#define MREPEAT31( macro, data) MREPEAT30( macro, data) macro( 30, data) +#define MREPEAT32( macro, data) MREPEAT31( macro, data) macro( 31, data) +#define MREPEAT33( macro, data) MREPEAT32( macro, data) macro( 32, data) +#define MREPEAT34( macro, data) MREPEAT33( macro, data) macro( 33, data) +#define MREPEAT35( macro, data) MREPEAT34( macro, data) macro( 34, data) +#define MREPEAT36( macro, data) MREPEAT35( macro, data) macro( 35, data) +#define MREPEAT37( macro, data) MREPEAT36( macro, data) macro( 36, data) +#define MREPEAT38( macro, data) MREPEAT37( macro, data) macro( 37, data) +#define MREPEAT39( macro, data) MREPEAT38( macro, data) macro( 38, data) +#define MREPEAT40( macro, data) MREPEAT39( macro, data) macro( 39, data) +#define MREPEAT41( macro, data) MREPEAT40( macro, data) macro( 40, data) +#define MREPEAT42( macro, data) MREPEAT41( macro, data) macro( 41, data) +#define MREPEAT43( macro, data) MREPEAT42( macro, data) macro( 42, data) +#define MREPEAT44( macro, data) MREPEAT43( macro, data) macro( 43, data) +#define MREPEAT45( macro, data) MREPEAT44( macro, data) macro( 44, data) +#define MREPEAT46( macro, data) MREPEAT45( macro, data) macro( 45, data) +#define MREPEAT47( macro, data) MREPEAT46( macro, data) macro( 46, data) +#define MREPEAT48( macro, data) MREPEAT47( macro, data) macro( 47, data) +#define MREPEAT49( macro, data) MREPEAT48( macro, data) macro( 48, data) +#define MREPEAT50( macro, data) MREPEAT49( macro, data) macro( 49, data) +#define MREPEAT51( macro, data) MREPEAT50( macro, data) macro( 50, data) +#define MREPEAT52( macro, data) MREPEAT51( macro, data) macro( 51, data) +#define MREPEAT53( macro, data) MREPEAT52( macro, data) macro( 52, data) +#define MREPEAT54( macro, data) MREPEAT53( macro, data) macro( 53, data) +#define MREPEAT55( macro, data) MREPEAT54( macro, data) macro( 54, data) +#define MREPEAT56( macro, data) MREPEAT55( macro, data) macro( 55, data) +#define MREPEAT57( macro, data) MREPEAT56( macro, data) macro( 56, data) +#define MREPEAT58( macro, data) MREPEAT57( macro, data) macro( 57, data) +#define MREPEAT59( macro, data) MREPEAT58( macro, data) macro( 58, data) +#define MREPEAT60( macro, data) MREPEAT59( macro, data) macro( 59, data) +#define MREPEAT61( macro, data) MREPEAT60( macro, data) macro( 60, data) +#define MREPEAT62( macro, data) MREPEAT61( macro, data) macro( 61, data) +#define MREPEAT63( macro, data) MREPEAT62( macro, data) macro( 62, data) +#define MREPEAT64( macro, data) MREPEAT63( macro, data) macro( 63, data) +#define MREPEAT65( macro, data) MREPEAT64( macro, data) macro( 64, data) +#define MREPEAT66( macro, data) MREPEAT65( macro, data) macro( 65, data) +#define MREPEAT67( macro, data) MREPEAT66( macro, data) macro( 66, data) +#define MREPEAT68( macro, data) MREPEAT67( macro, data) macro( 67, data) +#define MREPEAT69( macro, data) MREPEAT68( macro, data) macro( 68, data) +#define MREPEAT70( macro, data) MREPEAT69( macro, data) macro( 69, data) +#define MREPEAT71( macro, data) MREPEAT70( macro, data) macro( 70, data) +#define MREPEAT72( macro, data) MREPEAT71( macro, data) macro( 71, data) +#define MREPEAT73( macro, data) MREPEAT72( macro, data) macro( 72, data) +#define MREPEAT74( macro, data) MREPEAT73( macro, data) macro( 73, data) +#define MREPEAT75( macro, data) MREPEAT74( macro, data) macro( 74, data) +#define MREPEAT76( macro, data) MREPEAT75( macro, data) macro( 75, data) +#define MREPEAT77( macro, data) MREPEAT76( macro, data) macro( 76, data) +#define MREPEAT78( macro, data) MREPEAT77( macro, data) macro( 77, data) +#define MREPEAT79( macro, data) MREPEAT78( macro, data) macro( 78, data) +#define MREPEAT80( macro, data) MREPEAT79( macro, data) macro( 79, data) +#define MREPEAT81( macro, data) MREPEAT80( macro, data) macro( 80, data) +#define MREPEAT82( macro, data) MREPEAT81( macro, data) macro( 81, data) +#define MREPEAT83( macro, data) MREPEAT82( macro, data) macro( 82, data) +#define MREPEAT84( macro, data) MREPEAT83( macro, data) macro( 83, data) +#define MREPEAT85( macro, data) MREPEAT84( macro, data) macro( 84, data) +#define MREPEAT86( macro, data) MREPEAT85( macro, data) macro( 85, data) +#define MREPEAT87( macro, data) MREPEAT86( macro, data) macro( 86, data) +#define MREPEAT88( macro, data) MREPEAT87( macro, data) macro( 87, data) +#define MREPEAT89( macro, data) MREPEAT88( macro, data) macro( 88, data) +#define MREPEAT90( macro, data) MREPEAT89( macro, data) macro( 89, data) +#define MREPEAT91( macro, data) MREPEAT90( macro, data) macro( 90, data) +#define MREPEAT92( macro, data) MREPEAT91( macro, data) macro( 91, data) +#define MREPEAT93( macro, data) MREPEAT92( macro, data) macro( 92, data) +#define MREPEAT94( macro, data) MREPEAT93( macro, data) macro( 93, data) +#define MREPEAT95( macro, data) MREPEAT94( macro, data) macro( 94, data) +#define MREPEAT96( macro, data) MREPEAT95( macro, data) macro( 95, data) +#define MREPEAT97( macro, data) MREPEAT96( macro, data) macro( 96, data) +#define MREPEAT98( macro, data) MREPEAT97( macro, data) macro( 97, data) +#define MREPEAT99( macro, data) MREPEAT98( macro, data) macro( 98, data) +#define MREPEAT100(macro, data) MREPEAT99( macro, data) macro( 99, data) +#define MREPEAT101(macro, data) MREPEAT100(macro, data) macro(100, data) +#define MREPEAT102(macro, data) MREPEAT101(macro, data) macro(101, data) +#define MREPEAT103(macro, data) MREPEAT102(macro, data) macro(102, data) +#define MREPEAT104(macro, data) MREPEAT103(macro, data) macro(103, data) +#define MREPEAT105(macro, data) MREPEAT104(macro, data) macro(104, data) +#define MREPEAT106(macro, data) MREPEAT105(macro, data) macro(105, data) +#define MREPEAT107(macro, data) MREPEAT106(macro, data) macro(106, data) +#define MREPEAT108(macro, data) MREPEAT107(macro, data) macro(107, data) +#define MREPEAT109(macro, data) MREPEAT108(macro, data) macro(108, data) +#define MREPEAT110(macro, data) MREPEAT109(macro, data) macro(109, data) +#define MREPEAT111(macro, data) MREPEAT110(macro, data) macro(110, data) +#define MREPEAT112(macro, data) MREPEAT111(macro, data) macro(111, data) +#define MREPEAT113(macro, data) MREPEAT112(macro, data) macro(112, data) +#define MREPEAT114(macro, data) MREPEAT113(macro, data) macro(113, data) +#define MREPEAT115(macro, data) MREPEAT114(macro, data) macro(114, data) +#define MREPEAT116(macro, data) MREPEAT115(macro, data) macro(115, data) +#define MREPEAT117(macro, data) MREPEAT116(macro, data) macro(116, data) +#define MREPEAT118(macro, data) MREPEAT117(macro, data) macro(117, data) +#define MREPEAT119(macro, data) MREPEAT118(macro, data) macro(118, data) +#define MREPEAT120(macro, data) MREPEAT119(macro, data) macro(119, data) +#define MREPEAT121(macro, data) MREPEAT120(macro, data) macro(120, data) +#define MREPEAT122(macro, data) MREPEAT121(macro, data) macro(121, data) +#define MREPEAT123(macro, data) MREPEAT122(macro, data) macro(122, data) +#define MREPEAT124(macro, data) MREPEAT123(macro, data) macro(123, data) +#define MREPEAT125(macro, data) MREPEAT124(macro, data) macro(124, data) +#define MREPEAT126(macro, data) MREPEAT125(macro, data) macro(125, data) +#define MREPEAT127(macro, data) MREPEAT126(macro, data) macro(126, data) +#define MREPEAT128(macro, data) MREPEAT127(macro, data) macro(127, data) +#define MREPEAT129(macro, data) MREPEAT128(macro, data) macro(128, data) +#define MREPEAT130(macro, data) MREPEAT129(macro, data) macro(129, data) +#define MREPEAT131(macro, data) MREPEAT130(macro, data) macro(130, data) +#define MREPEAT132(macro, data) MREPEAT131(macro, data) macro(131, data) +#define MREPEAT133(macro, data) MREPEAT132(macro, data) macro(132, data) +#define MREPEAT134(macro, data) MREPEAT133(macro, data) macro(133, data) +#define MREPEAT135(macro, data) MREPEAT134(macro, data) macro(134, data) +#define MREPEAT136(macro, data) MREPEAT135(macro, data) macro(135, data) +#define MREPEAT137(macro, data) MREPEAT136(macro, data) macro(136, data) +#define MREPEAT138(macro, data) MREPEAT137(macro, data) macro(137, data) +#define MREPEAT139(macro, data) MREPEAT138(macro, data) macro(138, data) +#define MREPEAT140(macro, data) MREPEAT139(macro, data) macro(139, data) +#define MREPEAT141(macro, data) MREPEAT140(macro, data) macro(140, data) +#define MREPEAT142(macro, data) MREPEAT141(macro, data) macro(141, data) +#define MREPEAT143(macro, data) MREPEAT142(macro, data) macro(142, data) +#define MREPEAT144(macro, data) MREPEAT143(macro, data) macro(143, data) +#define MREPEAT145(macro, data) MREPEAT144(macro, data) macro(144, data) +#define MREPEAT146(macro, data) MREPEAT145(macro, data) macro(145, data) +#define MREPEAT147(macro, data) MREPEAT146(macro, data) macro(146, data) +#define MREPEAT148(macro, data) MREPEAT147(macro, data) macro(147, data) +#define MREPEAT149(macro, data) MREPEAT148(macro, data) macro(148, data) +#define MREPEAT150(macro, data) MREPEAT149(macro, data) macro(149, data) +#define MREPEAT151(macro, data) MREPEAT150(macro, data) macro(150, data) +#define MREPEAT152(macro, data) MREPEAT151(macro, data) macro(151, data) +#define MREPEAT153(macro, data) MREPEAT152(macro, data) macro(152, data) +#define MREPEAT154(macro, data) MREPEAT153(macro, data) macro(153, data) +#define MREPEAT155(macro, data) MREPEAT154(macro, data) macro(154, data) +#define MREPEAT156(macro, data) MREPEAT155(macro, data) macro(155, data) +#define MREPEAT157(macro, data) MREPEAT156(macro, data) macro(156, data) +#define MREPEAT158(macro, data) MREPEAT157(macro, data) macro(157, data) +#define MREPEAT159(macro, data) MREPEAT158(macro, data) macro(158, data) +#define MREPEAT160(macro, data) MREPEAT159(macro, data) macro(159, data) +#define MREPEAT161(macro, data) MREPEAT160(macro, data) macro(160, data) +#define MREPEAT162(macro, data) MREPEAT161(macro, data) macro(161, data) +#define MREPEAT163(macro, data) MREPEAT162(macro, data) macro(162, data) +#define MREPEAT164(macro, data) MREPEAT163(macro, data) macro(163, data) +#define MREPEAT165(macro, data) MREPEAT164(macro, data) macro(164, data) +#define MREPEAT166(macro, data) MREPEAT165(macro, data) macro(165, data) +#define MREPEAT167(macro, data) MREPEAT166(macro, data) macro(166, data) +#define MREPEAT168(macro, data) MREPEAT167(macro, data) macro(167, data) +#define MREPEAT169(macro, data) MREPEAT168(macro, data) macro(168, data) +#define MREPEAT170(macro, data) MREPEAT169(macro, data) macro(169, data) +#define MREPEAT171(macro, data) MREPEAT170(macro, data) macro(170, data) +#define MREPEAT172(macro, data) MREPEAT171(macro, data) macro(171, data) +#define MREPEAT173(macro, data) MREPEAT172(macro, data) macro(172, data) +#define MREPEAT174(macro, data) MREPEAT173(macro, data) macro(173, data) +#define MREPEAT175(macro, data) MREPEAT174(macro, data) macro(174, data) +#define MREPEAT176(macro, data) MREPEAT175(macro, data) macro(175, data) +#define MREPEAT177(macro, data) MREPEAT176(macro, data) macro(176, data) +#define MREPEAT178(macro, data) MREPEAT177(macro, data) macro(177, data) +#define MREPEAT179(macro, data) MREPEAT178(macro, data) macro(178, data) +#define MREPEAT180(macro, data) MREPEAT179(macro, data) macro(179, data) +#define MREPEAT181(macro, data) MREPEAT180(macro, data) macro(180, data) +#define MREPEAT182(macro, data) MREPEAT181(macro, data) macro(181, data) +#define MREPEAT183(macro, data) MREPEAT182(macro, data) macro(182, data) +#define MREPEAT184(macro, data) MREPEAT183(macro, data) macro(183, data) +#define MREPEAT185(macro, data) MREPEAT184(macro, data) macro(184, data) +#define MREPEAT186(macro, data) MREPEAT185(macro, data) macro(185, data) +#define MREPEAT187(macro, data) MREPEAT186(macro, data) macro(186, data) +#define MREPEAT188(macro, data) MREPEAT187(macro, data) macro(187, data) +#define MREPEAT189(macro, data) MREPEAT188(macro, data) macro(188, data) +#define MREPEAT190(macro, data) MREPEAT189(macro, data) macro(189, data) +#define MREPEAT191(macro, data) MREPEAT190(macro, data) macro(190, data) +#define MREPEAT192(macro, data) MREPEAT191(macro, data) macro(191, data) +#define MREPEAT193(macro, data) MREPEAT192(macro, data) macro(192, data) +#define MREPEAT194(macro, data) MREPEAT193(macro, data) macro(193, data) +#define MREPEAT195(macro, data) MREPEAT194(macro, data) macro(194, data) +#define MREPEAT196(macro, data) MREPEAT195(macro, data) macro(195, data) +#define MREPEAT197(macro, data) MREPEAT196(macro, data) macro(196, data) +#define MREPEAT198(macro, data) MREPEAT197(macro, data) macro(197, data) +#define MREPEAT199(macro, data) MREPEAT198(macro, data) macro(198, data) +#define MREPEAT200(macro, data) MREPEAT199(macro, data) macro(199, data) +#define MREPEAT201(macro, data) MREPEAT200(macro, data) macro(200, data) +#define MREPEAT202(macro, data) MREPEAT201(macro, data) macro(201, data) +#define MREPEAT203(macro, data) MREPEAT202(macro, data) macro(202, data) +#define MREPEAT204(macro, data) MREPEAT203(macro, data) macro(203, data) +#define MREPEAT205(macro, data) MREPEAT204(macro, data) macro(204, data) +#define MREPEAT206(macro, data) MREPEAT205(macro, data) macro(205, data) +#define MREPEAT207(macro, data) MREPEAT206(macro, data) macro(206, data) +#define MREPEAT208(macro, data) MREPEAT207(macro, data) macro(207, data) +#define MREPEAT209(macro, data) MREPEAT208(macro, data) macro(208, data) +#define MREPEAT210(macro, data) MREPEAT209(macro, data) macro(209, data) +#define MREPEAT211(macro, data) MREPEAT210(macro, data) macro(210, data) +#define MREPEAT212(macro, data) MREPEAT211(macro, data) macro(211, data) +#define MREPEAT213(macro, data) MREPEAT212(macro, data) macro(212, data) +#define MREPEAT214(macro, data) MREPEAT213(macro, data) macro(213, data) +#define MREPEAT215(macro, data) MREPEAT214(macro, data) macro(214, data) +#define MREPEAT216(macro, data) MREPEAT215(macro, data) macro(215, data) +#define MREPEAT217(macro, data) MREPEAT216(macro, data) macro(216, data) +#define MREPEAT218(macro, data) MREPEAT217(macro, data) macro(217, data) +#define MREPEAT219(macro, data) MREPEAT218(macro, data) macro(218, data) +#define MREPEAT220(macro, data) MREPEAT219(macro, data) macro(219, data) +#define MREPEAT221(macro, data) MREPEAT220(macro, data) macro(220, data) +#define MREPEAT222(macro, data) MREPEAT221(macro, data) macro(221, data) +#define MREPEAT223(macro, data) MREPEAT222(macro, data) macro(222, data) +#define MREPEAT224(macro, data) MREPEAT223(macro, data) macro(223, data) +#define MREPEAT225(macro, data) MREPEAT224(macro, data) macro(224, data) +#define MREPEAT226(macro, data) MREPEAT225(macro, data) macro(225, data) +#define MREPEAT227(macro, data) MREPEAT226(macro, data) macro(226, data) +#define MREPEAT228(macro, data) MREPEAT227(macro, data) macro(227, data) +#define MREPEAT229(macro, data) MREPEAT228(macro, data) macro(228, data) +#define MREPEAT230(macro, data) MREPEAT229(macro, data) macro(229, data) +#define MREPEAT231(macro, data) MREPEAT230(macro, data) macro(230, data) +#define MREPEAT232(macro, data) MREPEAT231(macro, data) macro(231, data) +#define MREPEAT233(macro, data) MREPEAT232(macro, data) macro(232, data) +#define MREPEAT234(macro, data) MREPEAT233(macro, data) macro(233, data) +#define MREPEAT235(macro, data) MREPEAT234(macro, data) macro(234, data) +#define MREPEAT236(macro, data) MREPEAT235(macro, data) macro(235, data) +#define MREPEAT237(macro, data) MREPEAT236(macro, data) macro(236, data) +#define MREPEAT238(macro, data) MREPEAT237(macro, data) macro(237, data) +#define MREPEAT239(macro, data) MREPEAT238(macro, data) macro(238, data) +#define MREPEAT240(macro, data) MREPEAT239(macro, data) macro(239, data) +#define MREPEAT241(macro, data) MREPEAT240(macro, data) macro(240, data) +#define MREPEAT242(macro, data) MREPEAT241(macro, data) macro(241, data) +#define MREPEAT243(macro, data) MREPEAT242(macro, data) macro(242, data) +#define MREPEAT244(macro, data) MREPEAT243(macro, data) macro(243, data) +#define MREPEAT245(macro, data) MREPEAT244(macro, data) macro(244, data) +#define MREPEAT246(macro, data) MREPEAT245(macro, data) macro(245, data) +#define MREPEAT247(macro, data) MREPEAT246(macro, data) macro(246, data) +#define MREPEAT248(macro, data) MREPEAT247(macro, data) macro(247, data) +#define MREPEAT249(macro, data) MREPEAT248(macro, data) macro(248, data) +#define MREPEAT250(macro, data) MREPEAT249(macro, data) macro(249, data) +#define MREPEAT251(macro, data) MREPEAT250(macro, data) macro(250, data) +#define MREPEAT252(macro, data) MREPEAT251(macro, data) macro(251, data) +#define MREPEAT253(macro, data) MREPEAT252(macro, data) macro(252, data) +#define MREPEAT254(macro, data) MREPEAT253(macro, data) macro(253, data) +#define MREPEAT255(macro, data) MREPEAT254(macro, data) macro(254, data) +#define MREPEAT256(macro, data) MREPEAT255(macro, data) macro(255, data) + +/** @} */ + +#endif /* _MREPEAT_H_ */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/preprocessor/preprocessor.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/preprocessor/preprocessor.h new file mode 100644 index 0000000..cfd65c5 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/preprocessor/preprocessor.h @@ -0,0 +1,52 @@ +/** + * \file + * + * \brief Preprocessor utils. + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _PREPROCESSOR_H_ +#define _PREPROCESSOR_H_ + +#include "tpaste.h" +#include "stringz.h" +#include "mrepeat.h" +#include "mrecursion.h" + +#endif // _PREPROCESSOR_H_ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/preprocessor/stringz.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/preprocessor/stringz.h new file mode 100644 index 0000000..eef3955 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/preprocessor/stringz.h @@ -0,0 +1,81 @@ +/** + * \file + * + * \brief Preprocessor stringizing utils. + * + * Copyright (C) 2012-2013 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _STRINGZ_H_ +#define _STRINGZ_H_ + +/** + * \defgroup group_sam0_utils_stringz Preprocessor - Stringize + * + * \ingroup group_sam0_utils + * + * @{ + */ + +/** \brief Stringize. + * + * Stringize a preprocessing token, this token being allowed to be \#defined. + * + * May be used only within macros with the token passed as an argument if the + * token is \#defined. + * + * For example, writing STRINGZ(PIN) within a macro \#defined by PIN_NAME(PIN) + * and invoked as PIN_NAME(PIN0) with PIN0 \#defined as A0 is equivalent to + * writing "A0". + */ +#define STRINGZ(x) #x + +/** \brief Absolute stringize. + * + * Stringize a preprocessing token, this token being allowed to be \#defined. + * + * No restriction of use if the token is \#defined. + * + * For example, writing ASTRINGZ(PIN0) anywhere with PIN0 \#defined as A0 is + * equivalent to writing "A0". + */ +#define ASTRINGZ(x) STRINGZ(x) + +/** @} */ + +#endif // _STRINGZ_H_ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/preprocessor/tpaste.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/preprocessor/tpaste.h new file mode 100644 index 0000000..cea9877 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/preprocessor/tpaste.h @@ -0,0 +1,100 @@ +/** + * \file + * + * \brief Preprocessor token pasting utils. + * + * Copyright (C) 2012-2013 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _TPASTE_H_ +#define _TPASTE_H_ + +/** + * \defgroup group_sam0_utils_tpaste Preprocessor - Token Paste + * + * \ingroup group_sam0_utils + * + * @{ + */ + +/** \name Token Paste + * + * Paste N preprocessing tokens together, these tokens being allowed to be \#defined. + * + * May be used only within macros with the tokens passed as arguments if the tokens are \#defined. + * + * For example, writing TPASTE2(U, WIDTH) within a macro \#defined by + * UTYPE(WIDTH) and invoked as UTYPE(UL_WIDTH) with UL_WIDTH \#defined as 32 is + * equivalent to writing U32. + * + * @{ */ +#define TPASTE2( a, b) a##b +#define TPASTE3( a, b, c) a##b##c +#define TPASTE4( a, b, c, d) a##b##c##d +#define TPASTE5( a, b, c, d, e) a##b##c##d##e +#define TPASTE6( a, b, c, d, e, f) a##b##c##d##e##f +#define TPASTE7( a, b, c, d, e, f, g) a##b##c##d##e##f##g +#define TPASTE8( a, b, c, d, e, f, g, h) a##b##c##d##e##f##g##h +#define TPASTE9( a, b, c, d, e, f, g, h, i) a##b##c##d##e##f##g##h##i +#define TPASTE10(a, b, c, d, e, f, g, h, i, j) a##b##c##d##e##f##g##h##i##j +/** @} */ + +/** \name Absolute Token Paste + * + * Paste N preprocessing tokens together, these tokens being allowed to be \#defined. + * + * No restriction of use if the tokens are \#defined. + * + * For example, writing ATPASTE2(U, UL_WIDTH) anywhere with UL_WIDTH \#defined + * as 32 is equivalent to writing U32. + * + * @{ */ +#define ATPASTE2( a, b) TPASTE2( a, b) +#define ATPASTE3( a, b, c) TPASTE3( a, b, c) +#define ATPASTE4( a, b, c, d) TPASTE4( a, b, c, d) +#define ATPASTE5( a, b, c, d, e) TPASTE5( a, b, c, d, e) +#define ATPASTE6( a, b, c, d, e, f) TPASTE6( a, b, c, d, e, f) +#define ATPASTE7( a, b, c, d, e, f, g) TPASTE7( a, b, c, d, e, f, g) +#define ATPASTE8( a, b, c, d, e, f, g, h) TPASTE8( a, b, c, d, e, f, g, h) +#define ATPASTE9( a, b, c, d, e, f, g, h, i) TPASTE9( a, b, c, d, e, f, g, h, i) +#define ATPASTE10(a, b, c, d, e, f, g, h, i, j) TPASTE10(a, b, c, d, e, f, g, h, i, j) +/** @} */ + +/** @} */ + +#endif // _TPASTE_H_ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/status_codes.h b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/status_codes.h new file mode 100644 index 0000000..d959288 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/status_codes.h @@ -0,0 +1,155 @@ +/** + * \file + * + * \brief Status code definitions. + * + * This file defines various status codes returned by functions, + * indicating success or failure as well as what kind of failure. + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef STATUS_CODES_H_INCLUDED +#define STATUS_CODES_H_INCLUDED + +#include + +/** + * \defgroup group_sam0_utils_status_codes Status Codes + * + * \ingroup group_sam0_utils + * + * @{ + */ + +/** Mask to retrieve the error category of a status code. */ +#define STATUS_CATEGORY_MASK 0xF0 + +/** Mask to retrieve the error code within the category of a status code. */ +#define STATUS_ERROR_MASK 0x0F + +/** Status code error categories. */ +enum status_categories { + STATUS_CATEGORY_OK = 0x00, + STATUS_CATEGORY_COMMON = 0x10, + STATUS_CATEGORY_ANALOG = 0x30, + STATUS_CATEGORY_COM = 0x40, + STATUS_CATEGORY_IO = 0x50, +}; + +/** + * Status code that may be returned by shell commands and protocol + * implementations. + * + * \note Any change to these status codes and the corresponding + * message strings is strictly forbidden. New codes can be added, + * however, but make sure that any message string tables are updated + * at the same time. + */ +enum status_code { + STATUS_OK = STATUS_CATEGORY_OK | 0x00, + STATUS_VALID_DATA = STATUS_CATEGORY_OK | 0x01, + STATUS_NO_CHANGE = STATUS_CATEGORY_OK | 0x02, + STATUS_ABORTED = STATUS_CATEGORY_OK | 0x04, + STATUS_BUSY = STATUS_CATEGORY_OK | 0x05, + STATUS_SUSPEND = STATUS_CATEGORY_OK | 0x06, + + STATUS_ERR_IO = STATUS_CATEGORY_COMMON | 0x00, + STATUS_ERR_REQ_FLUSHED = STATUS_CATEGORY_COMMON | 0x01, + STATUS_ERR_TIMEOUT = STATUS_CATEGORY_COMMON | 0x02, + STATUS_ERR_BAD_DATA = STATUS_CATEGORY_COMMON | 0x03, + STATUS_ERR_NOT_FOUND = STATUS_CATEGORY_COMMON | 0x04, + STATUS_ERR_UNSUPPORTED_DEV = STATUS_CATEGORY_COMMON | 0x05, + STATUS_ERR_NO_MEMORY = STATUS_CATEGORY_COMMON | 0x06, + STATUS_ERR_INVALID_ARG = STATUS_CATEGORY_COMMON | 0x07, + STATUS_ERR_BAD_ADDRESS = STATUS_CATEGORY_COMMON | 0x08, + STATUS_ERR_BAD_FORMAT = STATUS_CATEGORY_COMMON | 0x0A, + STATUS_ERR_BAD_FRQ = STATUS_CATEGORY_COMMON | 0x0B, + STATUS_ERR_DENIED = STATUS_CATEGORY_COMMON | 0x0c, + STATUS_ERR_ALREADY_INITIALIZED = STATUS_CATEGORY_COMMON | 0x0d, + STATUS_ERR_OVERFLOW = STATUS_CATEGORY_COMMON | 0x0e, + STATUS_ERR_NOT_INITIALIZED = STATUS_CATEGORY_COMMON | 0x0f, + + STATUS_ERR_SAMPLERATE_UNAVAILABLE = STATUS_CATEGORY_ANALOG | 0x00, + STATUS_ERR_RESOLUTION_UNAVAILABLE = STATUS_CATEGORY_ANALOG | 0x01, + + STATUS_ERR_BAUDRATE_UNAVAILABLE = STATUS_CATEGORY_COM | 0x00, + STATUS_ERR_PACKET_COLLISION = STATUS_CATEGORY_COM | 0x01, + STATUS_ERR_PROTOCOL = STATUS_CATEGORY_COM | 0x02, + + STATUS_ERR_PIN_MUX_INVALID = STATUS_CATEGORY_IO | 0x00, +}; +typedef enum status_code status_code_genare_t; + +/** + Status codes used by MAC stack. + */ +enum status_code_wireless { + //STATUS_OK = 0, //!< Success + ERR_IO_ERROR = -1, //!< I/O error + ERR_FLUSHED = -2, //!< Request flushed from queue + ERR_TIMEOUT = -3, //!< Operation timed out + ERR_BAD_DATA = -4, //!< Data integrity check failed + ERR_PROTOCOL = -5, //!< Protocol error + ERR_UNSUPPORTED_DEV = -6, //!< Unsupported device + ERR_NO_MEMORY = -7, //!< Insufficient memory + ERR_INVALID_ARG = -8, //!< Invalid argument + ERR_BAD_ADDRESS = -9, //!< Bad address + ERR_BUSY = -10, //!< Resource is busy + ERR_BAD_FORMAT = -11, //!< Data format not recognized + ERR_NO_TIMER = -12, //!< No timer available + ERR_TIMER_ALREADY_RUNNING = -13, //!< Timer already running + ERR_TIMER_NOT_RUNNING = -14, //!< Timer not running + + /** + * \brief Operation in progress + * + * This status code is for driver-internal use when an operation + * is currently being performed. + * + * \note Drivers should never return this status code to any + * callers. It is strictly for internal use. + */ + OPERATION_IN_PROGRESS = -128, +}; + +typedef enum status_code_wireless status_code_t; + +/** @} */ + +#endif /* STATUS_CODES_H_INCLUDED */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/syscalls/gcc/syscalls.c b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/syscalls/gcc/syscalls.c new file mode 100644 index 0000000..17f3870 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/sam0/utils/syscalls/gcc/syscalls.c @@ -0,0 +1,128 @@ +/** + * \file + * + * \brief Syscalls for SAM0 (GCC). + * + * Copyright (C) 2012-2013 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include +#include +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +#undef errno +extern int errno; +extern int _end; + +extern caddr_t _sbrk(int incr); +extern int link(char *old, char *new); +extern int _close(int file); +extern int _fstat(int file, struct stat *st); +extern int _isatty(int file); +extern int _lseek(int file, int ptr, int dir); +extern void _exit(int status); +extern void _kill(int pid, int sig); +extern int _getpid(void); + +extern caddr_t _sbrk(int incr) +{ + static unsigned char *heap = NULL; + unsigned char *prev_heap; + + if (heap == NULL) { + heap = (unsigned char *)&_end; + } + prev_heap = heap; + + heap += incr; + + return (caddr_t) prev_heap; +} + +extern int link(char *old, char *new) +{ + return -1; +} + +extern int _close(int file) +{ + return -1; +} + +extern int _fstat(int file, struct stat *st) +{ + st->st_mode = S_IFCHR; + + return 0; +} + +extern int _isatty(int file) +{ + return 1; +} + +extern int _lseek(int file, int ptr, int dir) +{ + return 0; +} + +extern void _exit(int status) +{ + printf("Exiting with status %d.\n", status); + + for (;;); +} + +extern void _kill(int pid, int sig) +{ + return; +} + +extern int _getpid(void) +{ + return -1; +} + +#ifdef __cplusplus +} +#endif diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/CMSIS END USER LICENCE AGREEMENT.pdf b/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/CMSIS END USER LICENCE AGREEMENT.pdf new file mode 100644 index 0000000..c8feab4 Binary files /dev/null and b/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/CMSIS END USER LICENCE AGREEMENT.pdf differ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/Include/arm_math.h b/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/Include/arm_math.h new file mode 100644 index 0000000..9277eab --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/Include/arm_math.h @@ -0,0 +1,7059 @@ +/* ---------------------------------------------------------------------- + * Copyright (C) 2010-2011 ARM Limited. All rights reserved. + * + * $Date: 15. July 2011 + * $Revision: V1.0.10 + * + * Project: CMSIS DSP Library + * Title: arm_math.h + * + * Description: Public header file for CMSIS DSP Library + * + * Target Processor: Cortex-M4/Cortex-M3/Cortex-M0 + * + * Version 1.0.10 2011/7/15 + * Big Endian support added and Merged M0 and M3/M4 Source code. + * + * Version 1.0.3 2010/11/29 + * Re-organized the CMSIS folders and updated documentation. + * + * Version 1.0.2 2010/11/11 + * Documentation updated. + * + * Version 1.0.1 2010/10/05 + * Production release and review comments incorporated. + * + * Version 1.0.0 2010/09/20 + * Production release and review comments incorporated. + * -------------------------------------------------------------------- */ + +/** + \mainpage CMSIS DSP Software Library + * + * Introduction + * + * This user manual describes the CMSIS DSP software library, + * a suite of common signal processing functions for use on Cortex-M processor based devices. + * + * The library is divided into a number of modules each covering a specific category: + * - Basic math functions + * - Fast math functions + * - Complex math functions + * - Filters + * - Matrix functions + * - Transforms + * - Motor control functions + * - Statistical functions + * - Support functions + * - Interpolation functions + * + * The library has separate functions for operating on 8-bit integers, 16-bit integers, + * 32-bit integer and 32-bit floating-point values. + * + * Processor Support + * + * The library is completely written in C and is fully CMSIS compliant. + * High performance is achieved through maximum use of Cortex-M4 intrinsics. + * + * The supplied library source code also builds and runs on the Cortex-M3 and Cortex-M0 processor, + * with the DSP intrinsics being emulated through software. + * + * + * Toolchain Support + * + * The library has been developed and tested with MDK-ARM version 4.21. + * The library is being tested in GCC and IAR toolchains and updates on this activity will be made available shortly. + * + * Using the Library + * + * The library installer contains prebuilt versions of the libraries in the Lib folder. + * - arm_cortexM4lf_math.lib (Little endian and Floating Point Unit on Cortex-M4) + * - arm_cortexM4bf_math.lib (Big endian and Floating Point Unit on Cortex-M4) + * - arm_cortexM4l_math.lib (Little endian on Cortex-M4) + * - arm_cortexM4b_math.lib (Big endian on Cortex-M4) + * - arm_cortexM3l_math.lib (Little endian on Cortex-M3) + * - arm_cortexM3b_math.lib (Big endian on Cortex-M3) + * - arm_cortexM0l_math.lib (Little endian on Cortex-M0) + * - arm_cortexM0b_math.lib (Big endian on Cortex-M3) + * + * The library functions are declared in the public file arm_math.h which is placed in the Include folder. + * Simply include this file and link the appropriate library in the application and begin calling the library functions. The Library supports single + * public header file arm_math.h for Cortex-M4/M3/M0 with little endian and big endian. Same header file will be used for floating point unit(FPU) variants. + * Define the appropriate pre processor MACRO ARM_MATH_CM4 or ARM_MATH_CM3 or + * ARM_MATH_CM0 depending on the target processor in the application. + * + * Examples + * + * The library ships with a number of examples which demonstrate how to use the library functions. + * + * Building the Library + * + * The library installer contains project files to re build libraries on MDK Tool chain in the CMSIS\\DSP_Lib\\Source\\ARM folder. + * - arm_cortexM0b_math.uvproj + * - arm_cortexM0l_math.uvproj + * - arm_cortexM3b_math.uvproj + * - arm_cortexM3l_math.uvproj + * - arm_cortexM4b_math.uvproj + * - arm_cortexM4l_math.uvproj + * - arm_cortexM4bf_math.uvproj + * - arm_cortexM4lf_math.uvproj + * + * Each library project have differant pre-processor macros. + * + * ARM_MATH_CMx: + * Define macro ARM_MATH_CM4 for building the library on Cortex-M4 target, ARM_MATH_CM3 for building library on Cortex-M3 target + * and ARM_MATH_CM0 for building library on cortex-M0 target. + * + * ARM_MATH_BIG_ENDIAN: + * Define macro ARM_MATH_BIG_ENDIAN to build the library for big endian targets. By default library builds for little endian targets. + * + * ARM_MATH_MATRIX_CHECK: + * Define macro for checking on the input and output sizes of matrices + * + * ARM_MATH_ROUNDING: + * Define macro for rounding on support functions + * + * __FPU_PRESENT: + * Initialize macro __FPU_PRESENT = 1 when building on FPU supported Targets. Enable this macro for M4bf and M4lf libraries + * + * + * The project can be built by opening the appropriate project in MDK-ARM 4.21 chain and defining the optional pre processor MACROs detailed above. + * + * Copyright Notice + * + * Copyright (C) 2010 ARM Limited. All rights reserved. + */ + + +/** + * @defgroup groupMath Basic Math Functions + */ + +/** + * @defgroup groupFastMath Fast Math Functions + * This set of functions provides a fast approximation to sine, cosine, and square root. + * As compared to most of the other functions in the CMSIS math library, the fast math functions + * operate on individual values and not arrays. + * There are separate functions for Q15, Q31, and floating-point data. + * + */ + +/** + * @defgroup groupCmplxMath Complex Math Functions + * This set of functions operates on complex data vectors. + * The data in the complex arrays is stored in an interleaved fashion + * (real, imag, real, imag, ...). + * In the API functions, the number of samples in a complex array refers + * to the number of complex values; the array contains twice this number of + * real values. + */ + +/** + * @defgroup groupFilters Filtering Functions + */ + +/** + * @defgroup groupMatrix Matrix Functions + * + * This set of functions provides basic matrix math operations. + * The functions operate on matrix data structures. For example, + * the type + * definition for the floating-point matrix structure is shown + * below: + *
+ *     typedef struct
+ *     {
+ *       uint16_t numRows;     // number of rows of the matrix.
+ *       uint16_t numCols;     // number of columns of the matrix.
+ *       float32_t *pData;     // points to the data of the matrix.
+ *     } arm_matrix_instance_f32;
+ * 
+ * There are similar definitions for Q15 and Q31 data types. + * + * The structure specifies the size of the matrix and then points to + * an array of data. The array is of size numRows X numCols + * and the values are arranged in row order. That is, the + * matrix element (i, j) is stored at: + *
+ *     pData[i*numCols + j]
+ * 
+ * + * \par Init Functions + * There is an associated initialization function for each type of matrix + * data structure. + * The initialization function sets the values of the internal structure fields. + * Refer to the function arm_mat_init_f32(), arm_mat_init_q31() + * and arm_mat_init_q15() for floating-point, Q31 and Q15 types, respectively. + * + * \par + * Use of the initialization function is optional. However, if initialization function is used + * then the instance structure cannot be placed into a const data section. + * To place the instance structure in a const data + * section, manually initialize the data structure. For example: + *
+ * arm_matrix_instance_f32 S = {nRows, nColumns, pData};
+ * arm_matrix_instance_q31 S = {nRows, nColumns, pData};
+ * arm_matrix_instance_q15 S = {nRows, nColumns, pData};
+ * 
+ * where nRows specifies the number of rows, nColumns + * specifies the number of columns, and pData points to the + * data array. + * + * \par Size Checking + * By default all of the matrix functions perform size checking on the input and + * output matrices. For example, the matrix addition function verifies that the + * two input matrices and the output matrix all have the same number of rows and + * columns. If the size check fails the functions return: + *
+ *     ARM_MATH_SIZE_MISMATCH
+ * 
+ * Otherwise the functions return + *
+ *     ARM_MATH_SUCCESS
+ * 
+ * There is some overhead associated with this matrix size checking. + * The matrix size checking is enabled via the \#define + *
+ *     ARM_MATH_MATRIX_CHECK
+ * 
+ * within the library project settings. By default this macro is defined + * and size checking is enabled. By changing the project settings and + * undefining this macro size checking is eliminated and the functions + * run a bit faster. With size checking disabled the functions always + * return ARM_MATH_SUCCESS. + */ + +/** + * @defgroup groupTransforms Transform Functions + */ + +/** + * @defgroup groupController Controller Functions + */ + +/** + * @defgroup groupStats Statistics Functions + */ +/** + * @defgroup groupSupport Support Functions + */ + +/** + * @defgroup groupInterpolation Interpolation Functions + * These functions perform 1- and 2-dimensional interpolation of data. + * Linear interpolation is used for 1-dimensional data and + * bilinear interpolation is used for 2-dimensional data. + */ + +/** + * @defgroup groupExamples Examples + */ +#ifndef _ARM_MATH_H +#define _ARM_MATH_H + +#include "compiler.h" + +#define __CMSIS_GENERIC /* disable NVIC and Systick functions */ + +#if defined (ARM_MATH_CM4) + #include "core_cm4.h" +#elif defined (ARM_MATH_CM3) + #include "core_cm3.h" +#elif defined (ARM_MATH_CM0) + #include "core_cm0.h" +#else +#include "ARMCM4.h" +#warning "Define either ARM_MATH_CM4 OR ARM_MATH_CM3...By Default building on ARM_MATH_CM4....." +#endif + +#undef __CMSIS_GENERIC /* enable NVIC and Systick functions */ +#include "string.h" + #include "math.h" +#ifdef __cplusplus +extern "C" +{ +#endif + + + /** + * @brief Macros required for reciprocal calculation in Normalized LMS + */ + +#define DELTA_Q31 (0x100) +#define DELTA_Q15 0x5 +#define INDEX_MASK 0x0000003F +#define PI 3.14159265358979f + + /** + * @brief Macros required for SINE and COSINE Fast math approximations + */ + +#define TABLE_SIZE 256 +#define TABLE_SPACING_Q31 0x800000 +#define TABLE_SPACING_Q15 0x80 + + /** + * @brief Macros required for SINE and COSINE Controller functions + */ + /* 1.31(q31) Fixed value of 2/360 */ + /* -1 to +1 is divided into 360 values so total spacing is (2/360) */ +#define INPUT_SPACING 0xB60B61 + + + /** + * @brief Error status returned by some functions in the library. + */ + + typedef enum + { + ARM_MATH_SUCCESS = 0, /**< No error */ + ARM_MATH_ARGUMENT_ERROR = -1, /**< One or more arguments are incorrect */ + ARM_MATH_LENGTH_ERROR = -2, /**< Length of data buffer is incorrect */ + ARM_MATH_SIZE_MISMATCH = -3, /**< Size of matrices is not compatible with the operation. */ + ARM_MATH_NANINF = -4, /**< Not-a-number (NaN) or infinity is generated */ + ARM_MATH_SINGULAR = -5, /**< Generated by matrix inversion if the input matrix is singular and cannot be inverted. */ + ARM_MATH_TEST_FAILURE = -6 /**< Test Failed */ + } arm_status; + + /** + * @brief 8-bit fractional data type in 1.7 format. + */ + typedef int8_t q7_t; + + /** + * @brief 16-bit fractional data type in 1.15 format. + */ + typedef int16_t q15_t; + + /** + * @brief 32-bit fractional data type in 1.31 format. + */ + typedef int32_t q31_t; + + /** + * @brief 64-bit fractional data type in 1.63 format. + */ + typedef int64_t q63_t; + + /** + * @brief 32-bit floating-point type definition. + */ + typedef float float32_t; + + /** + * @brief 64-bit floating-point type definition. + */ + typedef double float64_t; + + /** + * @brief definition to read/write two 16 bit values. + */ +#define __SIMD32(addr) (*(int32_t **) & (addr)) + +#if defined (ARM_MATH_CM3) || defined (ARM_MATH_CM0) + /** + * @brief definition to pack two 16 bit values. + */ +#define __PKHBT(ARG1, ARG2, ARG3) ( (((int32_t)(ARG1) << 0) & (int32_t)0x0000FFFF) | \ + (((int32_t)(ARG2) << ARG3) & (int32_t)0xFFFF0000) ) + +#endif + + + /** + * @brief definition to pack four 8 bit values. + */ +#ifndef ARM_MATH_BIG_ENDIAN + +#define __PACKq7(v0,v1,v2,v3) ( (((int32_t)(v0) << 0) & (int32_t)0x000000FF) | \ + (((int32_t)(v1) << 8) & (int32_t)0x0000FF00) | \ + (((int32_t)(v2) << 16) & (int32_t)0x00FF0000) | \ + (((int32_t)(v3) << 24) & (int32_t)0xFF000000) ) +#else + +#define __PACKq7(v0,v1,v2,v3) ( (((int32_t)(v3) << 0) & (int32_t)0x000000FF) | \ + (((int32_t)(v2) << 8) & (int32_t)0x0000FF00) | \ + (((int32_t)(v1) << 16) & (int32_t)0x00FF0000) | \ + (((int32_t)(v0) << 24) & (int32_t)0xFF000000) ) + +#endif + + + /** + * @brief Clips Q63 to Q31 values. + */ + __STATIC_INLINE q31_t clip_q63_to_q31( + q63_t x) + { + return ((q31_t) (x >> 32) != ((q31_t) x >> 31)) ? + ((0x7FFFFFFF ^ ((q31_t) (x >> 63)))) : (q31_t) x; + } + + /** + * @brief Clips Q63 to Q15 values. + */ + __STATIC_INLINE q15_t clip_q63_to_q15( + q63_t x) + { + return ((q31_t) (x >> 32) != ((q31_t) x >> 31)) ? + ((0x7FFF ^ ((q15_t) (x >> 63)))) : (q15_t) (x >> 15); + } + + /** + * @brief Clips Q31 to Q7 values. + */ + __STATIC_INLINE q7_t clip_q31_to_q7( + q31_t x) + { + return ((q31_t) (x >> 24) != ((q31_t) x >> 23)) ? + ((0x7F ^ ((q7_t) (x >> 31)))) : (q7_t) x; + } + + /** + * @brief Clips Q31 to Q15 values. + */ + __STATIC_INLINE q15_t clip_q31_to_q15( + q31_t x) + { + return ((q31_t) (x >> 16) != ((q31_t) x >> 15)) ? + ((0x7FFF ^ ((q15_t) (x >> 31)))) : (q15_t) x; + } + + /** + * @brief Multiplies 32 X 64 and returns 32 bit result in 2.30 format. + */ + + __STATIC_INLINE q63_t mult32x64( + q63_t x, + q31_t y) + { + return ((((q63_t) (x & 0x00000000FFFFFFFF) * y) >> 32) + + (((q63_t) (x >> 32) * y))); + } + + +#if defined (ARM_MATH_CM0) && defined ( __CC_ARM ) +#define __CLZ __clz +#endif + +#if defined (ARM_MATH_CM0) && defined ( __TASKING__ ) +/* No need to redefine __CLZ */ +#endif + +#if defined (ARM_MATH_CM0) && ((defined (__ICCARM__)) ||(defined (__GNUC__)) ) + + __STATIC_INLINE uint32_t __CLZ(q31_t data); + + + __STATIC_INLINE uint32_t __CLZ(q31_t data) + { + uint32_t count = 0; + uint32_t mask = 0x80000000; + + while((data & mask) == 0) + { + count += 1u; + mask = mask >> 1u; + } + + return(count); + + } + +#endif + + /** + * @brief Function to Calculates 1/in(reciprocal) value of Q31 Data type. + */ + + __STATIC_INLINE uint32_t arm_recip_q31( + q31_t in, + q31_t * dst, + q31_t * pRecipTable) + { + + uint32_t out, tempVal; + uint32_t index, i; + uint32_t signBits; + + if(in > 0) + { + signBits = __CLZ(in) - 1; + } + else + { + signBits = __CLZ(-in) - 1; + } + + /* Convert input sample to 1.31 format */ + in = in << signBits; + + /* calculation of index for initial approximated Val */ + index = (uint32_t) (in >> 24u); + index = (index & INDEX_MASK); + + /* 1.31 with exp 1 */ + out = pRecipTable[index]; + + /* calculation of reciprocal value */ + /* running approximation for two iterations */ + for (i = 0u; i < 2u; i++) + { + tempVal = (q31_t) (((q63_t) in * out) >> 31u); + tempVal = 0x7FFFFFFF - tempVal; + /* 1.31 with exp 1 */ + //out = (q31_t) (((q63_t) out * tempVal) >> 30u); + out = (q31_t) clip_q63_to_q31(((q63_t) out * tempVal) >> 30u); + } + + /* write output */ + *dst = out; + + /* return num of signbits of out = 1/in value */ + return (signBits + 1u); + + } + + /** + * @brief Function to Calculates 1/in(reciprocal) value of Q15 Data type. + */ + __STATIC_INLINE uint32_t arm_recip_q15( + q15_t in, + q15_t * dst, + q15_t * pRecipTable) + { + + uint32_t out = 0, tempVal = 0; + uint32_t index = 0, i = 0; + uint32_t signBits = 0; + + if(in > 0) + { + signBits = __CLZ(in) - 17; + } + else + { + signBits = __CLZ(-in) - 17; + } + + /* Convert input sample to 1.15 format */ + in = in << signBits; + + /* calculation of index for initial approximated Val */ + index = in >> 8; + index = (index & INDEX_MASK); + + /* 1.15 with exp 1 */ + out = pRecipTable[index]; + + /* calculation of reciprocal value */ + /* running approximation for two iterations */ + for (i = 0; i < 2; i++) + { + tempVal = (q15_t) (((q31_t) in * out) >> 15); + tempVal = 0x7FFF - tempVal; + /* 1.15 with exp 1 */ + out = (q15_t) (((q31_t) out * tempVal) >> 14); + } + + /* write output */ + *dst = out; + + /* return num of signbits of out = 1/in value */ + return (signBits + 1); + + } + + + /* + * @brief C custom defined intrinisic function for only M0 processors + */ +#if defined(ARM_MATH_CM0) + + __STATIC_INLINE q31_t __SSAT( + q31_t x, + uint32_t y) + { + int32_t posMax, negMin; + uint32_t i; + + posMax = 1; + for (i = 0; i < (y - 1); i++) + { + posMax = posMax * 2; + } + + if(x > 0) + { + posMax = (posMax - 1); + + if(x > posMax) + { + x = posMax; + } + } + else + { + negMin = -posMax; + + if(x < negMin) + { + x = negMin; + } + } + return (x); + + + } + +#endif /* end of ARM_MATH_CM0 */ + + + + /* + * @brief C custom defined intrinsic function for M3 and M0 processors + */ +#if defined (ARM_MATH_CM3) || defined (ARM_MATH_CM0) + + /* + * @brief C custom defined QADD8 for M3 and M0 processors + */ + __STATIC_INLINE q31_t __QADD8( + q31_t x, + q31_t y) + { + + q31_t sum; + q7_t r, s, t, u; + + r = (char) x; + s = (char) y; + + r = __SSAT((q31_t) (r + s), 8); + s = __SSAT(((q31_t) (((x << 16) >> 24) + ((y << 16) >> 24))), 8); + t = __SSAT(((q31_t) (((x << 8) >> 24) + ((y << 8) >> 24))), 8); + u = __SSAT(((q31_t) ((x >> 24) + (y >> 24))), 8); + + sum = (((q31_t) u << 24) & 0xFF000000) | (((q31_t) t << 16) & 0x00FF0000) | + (((q31_t) s << 8) & 0x0000FF00) | (r & 0x000000FF); + + return sum; + + } + + /* + * @brief C custom defined QSUB8 for M3 and M0 processors + */ + __STATIC_INLINE q31_t __QSUB8( + q31_t x, + q31_t y) + { + + q31_t sum; + q31_t r, s, t, u; + + r = (char) x; + s = (char) y; + + r = __SSAT((r - s), 8); + s = __SSAT(((q31_t) (((x << 16) >> 24) - ((y << 16) >> 24))), 8) << 8; + t = __SSAT(((q31_t) (((x << 8) >> 24) - ((y << 8) >> 24))), 8) << 16; + u = __SSAT(((q31_t) ((x >> 24) - (y >> 24))), 8) << 24; + + sum = + (u & 0xFF000000) | (t & 0x00FF0000) | (s & 0x0000FF00) | (r & 0x000000FF); + + return sum; + } + + /* + * @brief C custom defined QADD16 for M3 and M0 processors + */ + + /* + * @brief C custom defined QADD16 for M3 and M0 processors + */ + __STATIC_INLINE q31_t __QADD16( + q31_t x, + q31_t y) + { + + q31_t sum; + q31_t r, s; + + r = (short) x; + s = (short) y; + + r = __SSAT(r + s, 16); + s = __SSAT(((q31_t) ((x >> 16) + (y >> 16))), 16) << 16; + + sum = (s & 0xFFFF0000) | (r & 0x0000FFFF); + + return sum; + + } + + /* + * @brief C custom defined SHADD16 for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SHADD16( + q31_t x, + q31_t y) + { + + q31_t sum; + q31_t r, s; + + r = (short) x; + s = (short) y; + + r = ((r >> 1) + (s >> 1)); + s = ((q31_t) ((x >> 17) + (y >> 17))) << 16; + + sum = (s & 0xFFFF0000) | (r & 0x0000FFFF); + + return sum; + + } + + /* + * @brief C custom defined QSUB16 for M3 and M0 processors + */ + __STATIC_INLINE q31_t __QSUB16( + q31_t x, + q31_t y) + { + + q31_t sum; + q31_t r, s; + + r = (short) x; + s = (short) y; + + r = __SSAT(r - s, 16); + s = __SSAT(((q31_t) ((x >> 16) - (y >> 16))), 16) << 16; + + sum = (s & 0xFFFF0000) | (r & 0x0000FFFF); + + return sum; + } + + /* + * @brief C custom defined SHSUB16 for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SHSUB16( + q31_t x, + q31_t y) + { + + q31_t diff; + q31_t r, s; + + r = (short) x; + s = (short) y; + + r = ((r >> 1) - (s >> 1)); + s = (((x >> 17) - (y >> 17)) << 16); + + diff = (s & 0xFFFF0000) | (r & 0x0000FFFF); + + return diff; + } + + /* + * @brief C custom defined QASX for M3 and M0 processors + */ + __STATIC_INLINE q31_t __QASX( + q31_t x, + q31_t y) + { + + q31_t sum = 0; + + sum = ((sum + clip_q31_to_q15((q31_t) ((short) (x >> 16) + (short) y))) << 16) + + clip_q31_to_q15((q31_t) ((short) x - (short) (y >> 16))); + + return sum; + } + + /* + * @brief C custom defined SHASX for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SHASX( + q31_t x, + q31_t y) + { + + q31_t sum; + q31_t r, s; + + r = (short) x; + s = (short) y; + + r = ((r >> 1) - (y >> 17)); + s = (((x >> 17) + (s >> 1)) << 16); + + sum = (s & 0xFFFF0000) | (r & 0x0000FFFF); + + return sum; + } + + + /* + * @brief C custom defined QSAX for M3 and M0 processors + */ + __STATIC_INLINE q31_t __QSAX( + q31_t x, + q31_t y) + { + + q31_t sum = 0; + + sum = ((sum + clip_q31_to_q15((q31_t) ((short) (x >> 16) - (short) y))) << 16) + + clip_q31_to_q15((q31_t) ((short) x + (short) (y >> 16))); + + return sum; + } + + /* + * @brief C custom defined SHSAX for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SHSAX( + q31_t x, + q31_t y) + { + + q31_t sum; + q31_t r, s; + + r = (short) x; + s = (short) y; + + r = ((r >> 1) + (y >> 17)); + s = (((x >> 17) - (s >> 1)) << 16); + + sum = (s & 0xFFFF0000) | (r & 0x0000FFFF); + + return sum; + } + + /* + * @brief C custom defined SMUSDX for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SMUSDX( + q31_t x, + q31_t y) + { + + return ((q31_t)(((short) x * (short) (y >> 16)) - + ((short) (x >> 16) * (short) y))); + } + + /* + * @brief C custom defined SMUADX for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SMUADX( + q31_t x, + q31_t y) + { + + return ((q31_t)(((short) x * (short) (y >> 16)) + + ((short) (x >> 16) * (short) y))); + } + + /* + * @brief C custom defined QADD for M3 and M0 processors + */ + __STATIC_INLINE q31_t __QADD( + q31_t x, + q31_t y) + { + return clip_q63_to_q31((q63_t) x + y); + } + + /* + * @brief C custom defined QSUB for M3 and M0 processors + */ + __STATIC_INLINE q31_t __QSUB( + q31_t x, + q31_t y) + { + return clip_q63_to_q31((q63_t) x - y); + } + + /* + * @brief C custom defined SMLAD for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SMLAD( + q31_t x, + q31_t y, + q31_t sum) + { + + return (sum + ((short) (x >> 16) * (short) (y >> 16)) + + ((short) x * (short) y)); + } + + /* + * @brief C custom defined SMLADX for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SMLADX( + q31_t x, + q31_t y, + q31_t sum) + { + + return (sum + ((short) (x >> 16) * (short) (y)) + + ((short) x * (short) (y >> 16))); + } + + /* + * @brief C custom defined SMLSDX for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SMLSDX( + q31_t x, + q31_t y, + q31_t sum) + { + + return (sum - ((short) (x >> 16) * (short) (y)) + + ((short) x * (short) (y >> 16))); + } + + /* + * @brief C custom defined SMLALD for M3 and M0 processors + */ + __STATIC_INLINE q63_t __SMLALD( + q31_t x, + q31_t y, + q63_t sum) + { + + return (sum + ((short) (x >> 16) * (short) (y >> 16)) + + ((short) x * (short) y)); + } + + /* + * @brief C custom defined SMLALDX for M3 and M0 processors + */ + __STATIC_INLINE q63_t __SMLALDX( + q31_t x, + q31_t y, + q63_t sum) + { + + return (sum + ((short) (x >> 16) * (short) y)) + + ((short) x * (short) (y >> 16)); + } + + /* + * @brief C custom defined SMUAD for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SMUAD( + q31_t x, + q31_t y) + { + + return (((x >> 16) * (y >> 16)) + + (((x << 16) >> 16) * ((y << 16) >> 16))); + } + + /* + * @brief C custom defined SMUSD for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SMUSD( + q31_t x, + q31_t y) + { + + return (-((x >> 16) * (y >> 16)) + + (((x << 16) >> 16) * ((y << 16) >> 16))); + } + + + + +#endif /* (ARM_MATH_CM3) || defined (ARM_MATH_CM0) */ + + + /** + * @brief Instance structure for the Q7 FIR filter. + */ + typedef struct + { + uint16_t numTaps; /**< number of filter coefficients in the filter. */ + q7_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + q7_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps.*/ + } arm_fir_instance_q7; + + /** + * @brief Instance structure for the Q15 FIR filter. + */ + typedef struct + { + uint16_t numTaps; /**< number of filter coefficients in the filter. */ + q15_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + q15_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps.*/ + } arm_fir_instance_q15; + + /** + * @brief Instance structure for the Q31 FIR filter. + */ + typedef struct + { + uint16_t numTaps; /**< number of filter coefficients in the filter. */ + q31_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + q31_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps. */ + } arm_fir_instance_q31; + + /** + * @brief Instance structure for the floating-point FIR filter. + */ + typedef struct + { + uint16_t numTaps; /**< number of filter coefficients in the filter. */ + float32_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + float32_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps. */ + } arm_fir_instance_f32; + + + /** + * @brief Processing function for the Q7 FIR filter. + * @param[in] *S points to an instance of the Q7 FIR filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + void arm_fir_q7( + const arm_fir_instance_q7 * S, + q7_t * pSrc, + q7_t * pDst, + uint32_t blockSize); + + + /** + * @brief Initialization function for the Q7 FIR filter. + * @param[in,out] *S points to an instance of the Q7 FIR structure. + * @param[in] numTaps Number of filter coefficients in the filter. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of samples that are processed. + * @return none + */ + void arm_fir_init_q7( + arm_fir_instance_q7 * S, + uint16_t numTaps, + q7_t * pCoeffs, + q7_t * pState, + uint32_t blockSize); + + + /** + * @brief Processing function for the Q15 FIR filter. + * @param[in] *S points to an instance of the Q15 FIR structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + void arm_fir_q15( + const arm_fir_instance_q15 * S, + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Processing function for the fast Q15 FIR filter for Cortex-M3 and Cortex-M4. + * @param[in] *S points to an instance of the Q15 FIR filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + void arm_fir_fast_q15( + const arm_fir_instance_q15 * S, + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the Q15 FIR filter. + * @param[in,out] *S points to an instance of the Q15 FIR filter structure. + * @param[in] numTaps Number of filter coefficients in the filter. Must be even and greater than or equal to 4. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of samples that are processed at a time. + * @return The function returns ARM_MATH_SUCCESS if initialization was successful or ARM_MATH_ARGUMENT_ERROR if + * numTaps is not a supported value. + */ + + arm_status arm_fir_init_q15( + arm_fir_instance_q15 * S, + uint16_t numTaps, + q15_t * pCoeffs, + q15_t * pState, + uint32_t blockSize); + + /** + * @brief Processing function for the Q31 FIR filter. + * @param[in] *S points to an instance of the Q31 FIR filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + void arm_fir_q31( + const arm_fir_instance_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Processing function for the fast Q31 FIR filter for Cortex-M3 and Cortex-M4. + * @param[in] *S points to an instance of the Q31 FIR structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + void arm_fir_fast_q31( + const arm_fir_instance_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the Q31 FIR filter. + * @param[in,out] *S points to an instance of the Q31 FIR structure. + * @param[in] numTaps Number of filter coefficients in the filter. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of samples that are processed at a time. + * @return none. + */ + void arm_fir_init_q31( + arm_fir_instance_q31 * S, + uint16_t numTaps, + q31_t * pCoeffs, + q31_t * pState, + uint32_t blockSize); + + /** + * @brief Processing function for the floating-point FIR filter. + * @param[in] *S points to an instance of the floating-point FIR structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + void arm_fir_f32( + const arm_fir_instance_f32 * S, + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the floating-point FIR filter. + * @param[in,out] *S points to an instance of the floating-point FIR filter structure. + * @param[in] numTaps Number of filter coefficients in the filter. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of samples that are processed at a time. + * @return none. + */ + void arm_fir_init_f32( + arm_fir_instance_f32 * S, + uint16_t numTaps, + float32_t * pCoeffs, + float32_t * pState, + uint32_t blockSize); + + + /** + * @brief Instance structure for the Q15 Biquad cascade filter. + */ + typedef struct + { + int8_t numStages; /**< number of 2nd order stages in the filter. Overall order is 2*numStages. */ + q15_t *pState; /**< Points to the array of state coefficients. The array is of length 4*numStages. */ + q15_t *pCoeffs; /**< Points to the array of coefficients. The array is of length 5*numStages. */ + int8_t postShift; /**< Additional shift, in bits, applied to each output sample. */ + + } arm_biquad_casd_df1_inst_q15; + + + /** + * @brief Instance structure for the Q31 Biquad cascade filter. + */ + typedef struct + { + uint32_t numStages; /**< number of 2nd order stages in the filter. Overall order is 2*numStages. */ + q31_t *pState; /**< Points to the array of state coefficients. The array is of length 4*numStages. */ + q31_t *pCoeffs; /**< Points to the array of coefficients. The array is of length 5*numStages. */ + uint8_t postShift; /**< Additional shift, in bits, applied to each output sample. */ + + } arm_biquad_casd_df1_inst_q31; + + /** + * @brief Instance structure for the floating-point Biquad cascade filter. + */ + typedef struct + { + uint32_t numStages; /**< number of 2nd order stages in the filter. Overall order is 2*numStages. */ + float32_t *pState; /**< Points to the array of state coefficients. The array is of length 4*numStages. */ + float32_t *pCoeffs; /**< Points to the array of coefficients. The array is of length 5*numStages. */ + + + } arm_biquad_casd_df1_inst_f32; + + + + /** + * @brief Processing function for the Q15 Biquad cascade filter. + * @param[in] *S points to an instance of the Q15 Biquad cascade structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_biquad_cascade_df1_q15( + const arm_biquad_casd_df1_inst_q15 * S, + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the Q15 Biquad cascade filter. + * @param[in,out] *S points to an instance of the Q15 Biquad cascade structure. + * @param[in] numStages number of 2nd order stages in the filter. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] postShift Shift to be applied to the output. Varies according to the coefficients format + * @return none + */ + + void arm_biquad_cascade_df1_init_q15( + arm_biquad_casd_df1_inst_q15 * S, + uint8_t numStages, + q15_t * pCoeffs, + q15_t * pState, + int8_t postShift); + + + /** + * @brief Fast but less precise processing function for the Q15 Biquad cascade filter for Cortex-M3 and Cortex-M4. + * @param[in] *S points to an instance of the Q15 Biquad cascade structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_biquad_cascade_df1_fast_q15( + const arm_biquad_casd_df1_inst_q15 * S, + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + + /** + * @brief Processing function for the Q31 Biquad cascade filter + * @param[in] *S points to an instance of the Q31 Biquad cascade structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_biquad_cascade_df1_q31( + const arm_biquad_casd_df1_inst_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Fast but less precise processing function for the Q31 Biquad cascade filter for Cortex-M3 and Cortex-M4. + * @param[in] *S points to an instance of the Q31 Biquad cascade structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_biquad_cascade_df1_fast_q31( + const arm_biquad_casd_df1_inst_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the Q31 Biquad cascade filter. + * @param[in,out] *S points to an instance of the Q31 Biquad cascade structure. + * @param[in] numStages number of 2nd order stages in the filter. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] postShift Shift to be applied to the output. Varies according to the coefficients format + * @return none + */ + + void arm_biquad_cascade_df1_init_q31( + arm_biquad_casd_df1_inst_q31 * S, + uint8_t numStages, + q31_t * pCoeffs, + q31_t * pState, + int8_t postShift); + + /** + * @brief Processing function for the floating-point Biquad cascade filter. + * @param[in] *S points to an instance of the floating-point Biquad cascade structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_biquad_cascade_df1_f32( + const arm_biquad_casd_df1_inst_f32 * S, + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the floating-point Biquad cascade filter. + * @param[in,out] *S points to an instance of the floating-point Biquad cascade structure. + * @param[in] numStages number of 2nd order stages in the filter. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @return none + */ + + void arm_biquad_cascade_df1_init_f32( + arm_biquad_casd_df1_inst_f32 * S, + uint8_t numStages, + float32_t * pCoeffs, + float32_t * pState); + + + /** + * @brief Instance structure for the floating-point matrix structure. + */ + + typedef struct + { + uint16_t numRows; /**< number of rows of the matrix. */ + uint16_t numCols; /**< number of columns of the matrix. */ + float32_t *pData; /**< points to the data of the matrix. */ + } arm_matrix_instance_f32; + + /** + * @brief Instance structure for the Q15 matrix structure. + */ + + typedef struct + { + uint16_t numRows; /**< number of rows of the matrix. */ + uint16_t numCols; /**< number of columns of the matrix. */ + q15_t *pData; /**< points to the data of the matrix. */ + + } arm_matrix_instance_q15; + + /** + * @brief Instance structure for the Q31 matrix structure. + */ + + typedef struct + { + uint16_t numRows; /**< number of rows of the matrix. */ + uint16_t numCols; /**< number of columns of the matrix. */ + q31_t *pData; /**< points to the data of the matrix. */ + + } arm_matrix_instance_q31; + + + + /** + * @brief Floating-point matrix addition. + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_add_f32( + const arm_matrix_instance_f32 * pSrcA, + const arm_matrix_instance_f32 * pSrcB, + arm_matrix_instance_f32 * pDst); + + /** + * @brief Q15 matrix addition. + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_add_q15( + const arm_matrix_instance_q15 * pSrcA, + const arm_matrix_instance_q15 * pSrcB, + arm_matrix_instance_q15 * pDst); + + /** + * @brief Q31 matrix addition. + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_add_q31( + const arm_matrix_instance_q31 * pSrcA, + const arm_matrix_instance_q31 * pSrcB, + arm_matrix_instance_q31 * pDst); + + + /** + * @brief Floating-point matrix transpose. + * @param[in] *pSrc points to the input matrix + * @param[out] *pDst points to the output matrix + * @return The function returns either ARM_MATH_SIZE_MISMATCH + * or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_trans_f32( + const arm_matrix_instance_f32 * pSrc, + arm_matrix_instance_f32 * pDst); + + + /** + * @brief Q15 matrix transpose. + * @param[in] *pSrc points to the input matrix + * @param[out] *pDst points to the output matrix + * @return The function returns either ARM_MATH_SIZE_MISMATCH + * or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_trans_q15( + const arm_matrix_instance_q15 * pSrc, + arm_matrix_instance_q15 * pDst); + + /** + * @brief Q31 matrix transpose. + * @param[in] *pSrc points to the input matrix + * @param[out] *pDst points to the output matrix + * @return The function returns either ARM_MATH_SIZE_MISMATCH + * or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_trans_q31( + const arm_matrix_instance_q31 * pSrc, + arm_matrix_instance_q31 * pDst); + + + /** + * @brief Floating-point matrix multiplication + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_mult_f32( + const arm_matrix_instance_f32 * pSrcA, + const arm_matrix_instance_f32 * pSrcB, + arm_matrix_instance_f32 * pDst); + + /** + * @brief Q15 matrix multiplication + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_mult_q15( + const arm_matrix_instance_q15 * pSrcA, + const arm_matrix_instance_q15 * pSrcB, + arm_matrix_instance_q15 * pDst, + q15_t * pState); + + /** + * @brief Q15 matrix multiplication (fast variant) for Cortex-M3 and Cortex-M4 + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @param[in] *pState points to the array for storing intermediate results + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_mult_fast_q15( + const arm_matrix_instance_q15 * pSrcA, + const arm_matrix_instance_q15 * pSrcB, + arm_matrix_instance_q15 * pDst, + q15_t * pState); + + /** + * @brief Q31 matrix multiplication + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_mult_q31( + const arm_matrix_instance_q31 * pSrcA, + const arm_matrix_instance_q31 * pSrcB, + arm_matrix_instance_q31 * pDst); + + /** + * @brief Q31 matrix multiplication (fast variant) for Cortex-M3 and Cortex-M4 + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_mult_fast_q31( + const arm_matrix_instance_q31 * pSrcA, + const arm_matrix_instance_q31 * pSrcB, + arm_matrix_instance_q31 * pDst); + + + /** + * @brief Floating-point matrix subtraction + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_sub_f32( + const arm_matrix_instance_f32 * pSrcA, + const arm_matrix_instance_f32 * pSrcB, + arm_matrix_instance_f32 * pDst); + + /** + * @brief Q15 matrix subtraction + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_sub_q15( + const arm_matrix_instance_q15 * pSrcA, + const arm_matrix_instance_q15 * pSrcB, + arm_matrix_instance_q15 * pDst); + + /** + * @brief Q31 matrix subtraction + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_sub_q31( + const arm_matrix_instance_q31 * pSrcA, + const arm_matrix_instance_q31 * pSrcB, + arm_matrix_instance_q31 * pDst); + + /** + * @brief Floating-point matrix scaling. + * @param[in] *pSrc points to the input matrix + * @param[in] scale scale factor + * @param[out] *pDst points to the output matrix + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_scale_f32( + const arm_matrix_instance_f32 * pSrc, + float32_t scale, + arm_matrix_instance_f32 * pDst); + + /** + * @brief Q15 matrix scaling. + * @param[in] *pSrc points to input matrix + * @param[in] scaleFract fractional portion of the scale factor + * @param[in] shift number of bits to shift the result by + * @param[out] *pDst points to output matrix + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_scale_q15( + const arm_matrix_instance_q15 * pSrc, + q15_t scaleFract, + int32_t shift, + arm_matrix_instance_q15 * pDst); + + /** + * @brief Q31 matrix scaling. + * @param[in] *pSrc points to input matrix + * @param[in] scaleFract fractional portion of the scale factor + * @param[in] shift number of bits to shift the result by + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_scale_q31( + const arm_matrix_instance_q31 * pSrc, + q31_t scaleFract, + int32_t shift, + arm_matrix_instance_q31 * pDst); + + + /** + * @brief Q31 matrix initialization. + * @param[in,out] *S points to an instance of the floating-point matrix structure. + * @param[in] nRows number of rows in the matrix. + * @param[in] nColumns number of columns in the matrix. + * @param[in] *pData points to the matrix data array. + * @return none + */ + + void arm_mat_init_q31( + arm_matrix_instance_q31 * S, + uint16_t nRows, + uint16_t nColumns, + q31_t *pData); + + /** + * @brief Q15 matrix initialization. + * @param[in,out] *S points to an instance of the floating-point matrix structure. + * @param[in] nRows number of rows in the matrix. + * @param[in] nColumns number of columns in the matrix. + * @param[in] *pData points to the matrix data array. + * @return none + */ + + void arm_mat_init_q15( + arm_matrix_instance_q15 * S, + uint16_t nRows, + uint16_t nColumns, + q15_t *pData); + + /** + * @brief Floating-point matrix initialization. + * @param[in,out] *S points to an instance of the floating-point matrix structure. + * @param[in] nRows number of rows in the matrix. + * @param[in] nColumns number of columns in the matrix. + * @param[in] *pData points to the matrix data array. + * @return none + */ + + void arm_mat_init_f32( + arm_matrix_instance_f32 * S, + uint16_t nRows, + uint16_t nColumns, + float32_t *pData); + + + + /** + * @brief Instance structure for the Q15 PID Control. + */ + typedef struct + { + q15_t A0; /**< The derived gain, A0 = Kp + Ki + Kd . */ + #ifdef ARM_MATH_CM0 + q15_t A1; + q15_t A2; + #else + q31_t A1; /**< The derived gain A1 = -Kp - 2Kd | Kd.*/ + #endif + q15_t state[3]; /**< The state array of length 3. */ + q15_t Kp; /**< The proportional gain. */ + q15_t Ki; /**< The integral gain. */ + q15_t Kd; /**< The derivative gain. */ + } arm_pid_instance_q15; + + /** + * @brief Instance structure for the Q31 PID Control. + */ + typedef struct + { + q31_t A0; /**< The derived gain, A0 = Kp + Ki + Kd . */ + q31_t A1; /**< The derived gain, A1 = -Kp - 2Kd. */ + q31_t A2; /**< The derived gain, A2 = Kd . */ + q31_t state[3]; /**< The state array of length 3. */ + q31_t Kp; /**< The proportional gain. */ + q31_t Ki; /**< The integral gain. */ + q31_t Kd; /**< The derivative gain. */ + + } arm_pid_instance_q31; + + /** + * @brief Instance structure for the floating-point PID Control. + */ + typedef struct + { + float32_t A0; /**< The derived gain, A0 = Kp + Ki + Kd . */ + float32_t A1; /**< The derived gain, A1 = -Kp - 2Kd. */ + float32_t A2; /**< The derived gain, A2 = Kd . */ + float32_t state[3]; /**< The state array of length 3. */ + float32_t Kp; /**< The proportional gain. */ + float32_t Ki; /**< The integral gain. */ + float32_t Kd; /**< The derivative gain. */ + } arm_pid_instance_f32; + + + + /** + * @brief Initialization function for the floating-point PID Control. + * @param[in,out] *S points to an instance of the PID structure. + * @param[in] resetStateFlag flag to reset the state. 0 = no change in state 1 = reset the state. + * @return none. + */ + void arm_pid_init_f32( + arm_pid_instance_f32 * S, + int32_t resetStateFlag); + + /** + * @brief Reset function for the floating-point PID Control. + * @param[in,out] *S is an instance of the floating-point PID Control structure + * @return none + */ + void arm_pid_reset_f32( + arm_pid_instance_f32 * S); + + + /** + * @brief Initialization function for the Q31 PID Control. + * @param[in,out] *S points to an instance of the Q15 PID structure. + * @param[in] resetStateFlag flag to reset the state. 0 = no change in state 1 = reset the state. + * @return none. + */ + void arm_pid_init_q31( + arm_pid_instance_q31 * S, + int32_t resetStateFlag); + + + /** + * @brief Reset function for the Q31 PID Control. + * @param[in,out] *S points to an instance of the Q31 PID Control structure + * @return none + */ + + void arm_pid_reset_q31( + arm_pid_instance_q31 * S); + + /** + * @brief Initialization function for the Q15 PID Control. + * @param[in,out] *S points to an instance of the Q15 PID structure. + * @param[in] resetStateFlag flag to reset the state. 0 = no change in state 1 = reset the state. + * @return none. + */ + void arm_pid_init_q15( + arm_pid_instance_q15 * S, + int32_t resetStateFlag); + + /** + * @brief Reset function for the Q15 PID Control. + * @param[in,out] *S points to an instance of the q15 PID Control structure + * @return none + */ + void arm_pid_reset_q15( + arm_pid_instance_q15 * S); + + + /** + * @brief Instance structure for the floating-point Linear Interpolate function. + */ + typedef struct + { + uint32_t nValues; /**< nValues */ + float32_t x1; /**< x1 */ + float32_t xSpacing; /**< xSpacing */ + float32_t *pYData; /**< pointer to the table of Y values */ + } arm_linear_interp_instance_f32; + + /** + * @brief Instance structure for the floating-point bilinear interpolation function. + */ + + typedef struct + { + uint16_t numRows; /**< number of rows in the data table. */ + uint16_t numCols; /**< number of columns in the data table. */ + float32_t *pData; /**< points to the data table. */ + } arm_bilinear_interp_instance_f32; + + /** + * @brief Instance structure for the Q31 bilinear interpolation function. + */ + + typedef struct + { + uint16_t numRows; /**< number of rows in the data table. */ + uint16_t numCols; /**< number of columns in the data table. */ + q31_t *pData; /**< points to the data table. */ + } arm_bilinear_interp_instance_q31; + + /** + * @brief Instance structure for the Q15 bilinear interpolation function. + */ + + typedef struct + { + uint16_t numRows; /**< number of rows in the data table. */ + uint16_t numCols; /**< number of columns in the data table. */ + q15_t *pData; /**< points to the data table. */ + } arm_bilinear_interp_instance_q15; + + /** + * @brief Instance structure for the Q15 bilinear interpolation function. + */ + + typedef struct + { + uint16_t numRows; /**< number of rows in the data table. */ + uint16_t numCols; /**< number of columns in the data table. */ + q7_t *pData; /**< points to the data table. */ + } arm_bilinear_interp_instance_q7; + + + /** + * @brief Q7 vector multiplication. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_mult_q7( + q7_t * pSrcA, + q7_t * pSrcB, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Q15 vector multiplication. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_mult_q15( + q15_t * pSrcA, + q15_t * pSrcB, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Q31 vector multiplication. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_mult_q31( + q31_t * pSrcA, + q31_t * pSrcB, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Floating-point vector multiplication. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_mult_f32( + float32_t * pSrcA, + float32_t * pSrcB, + float32_t * pDst, + uint32_t blockSize); + + + /** + * @brief Instance structure for the Q15 CFFT/CIFFT function. + */ + + typedef struct + { + uint16_t fftLen; /**< length of the FFT. */ + uint8_t ifftFlag; /**< flag that selects forward (ifftFlag=0) or inverse (ifftFlag=1) transform. */ + uint8_t bitReverseFlag; /**< flag that enables (bitReverseFlag=1) or disables (bitReverseFlag=0) bit reversal of output. */ + q15_t *pTwiddle; /**< points to the twiddle factor table. */ + uint16_t *pBitRevTable; /**< points to the bit reversal table. */ + uint16_t twidCoefModifier; /**< twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. */ + uint16_t bitRevFactor; /**< bit reversal modifier that supports different size FFTs with the same bit reversal table. */ + } arm_cfft_radix4_instance_q15; + + /** + * @brief Instance structure for the Q31 CFFT/CIFFT function. + */ + + typedef struct + { + uint16_t fftLen; /**< length of the FFT. */ + uint8_t ifftFlag; /**< flag that selects forward (ifftFlag=0) or inverse (ifftFlag=1) transform. */ + uint8_t bitReverseFlag; /**< flag that enables (bitReverseFlag=1) or disables (bitReverseFlag=0) bit reversal of output. */ + q31_t *pTwiddle; /**< points to the twiddle factor table. */ + uint16_t *pBitRevTable; /**< points to the bit reversal table. */ + uint16_t twidCoefModifier; /**< twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. */ + uint16_t bitRevFactor; /**< bit reversal modifier that supports different size FFTs with the same bit reversal table. */ + } arm_cfft_radix4_instance_q31; + + /** + * @brief Instance structure for the floating-point CFFT/CIFFT function. + */ + + typedef struct + { + uint16_t fftLen; /**< length of the FFT. */ + uint8_t ifftFlag; /**< flag that selects forward (ifftFlag=0) or inverse (ifftFlag=1) transform. */ + uint8_t bitReverseFlag; /**< flag that enables (bitReverseFlag=1) or disables (bitReverseFlag=0) bit reversal of output. */ + float32_t *pTwiddle; /**< points to the twiddle factor table. */ + uint16_t *pBitRevTable; /**< points to the bit reversal table. */ + uint16_t twidCoefModifier; /**< twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. */ + uint16_t bitRevFactor; /**< bit reversal modifier that supports different size FFTs with the same bit reversal table. */ + float32_t onebyfftLen; /**< value of 1/fftLen. */ + } arm_cfft_radix4_instance_f32; + + /** + * @brief Processing function for the Q15 CFFT/CIFFT. + * @param[in] *S points to an instance of the Q15 CFFT/CIFFT structure. + * @param[in, out] *pSrc points to the complex data buffer. Processing occurs in-place. + * @return none. + */ + + void arm_cfft_radix4_q15( + const arm_cfft_radix4_instance_q15 * S, + q15_t * pSrc); + + /** + * @brief Initialization function for the Q15 CFFT/CIFFT. + * @param[in,out] *S points to an instance of the Q15 CFFT/CIFFT structure. + * @param[in] fftLen length of the FFT. + * @param[in] ifftFlag flag that selects forward (ifftFlag=0) or inverse (ifftFlag=1) transform. + * @param[in] bitReverseFlag flag that enables (bitReverseFlag=1) or disables (bitReverseFlag=0) bit reversal of output. + * @return arm_status function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_ARGUMENT_ERROR if fftLen is not a supported value. + */ + + arm_status arm_cfft_radix4_init_q15( + arm_cfft_radix4_instance_q15 * S, + uint16_t fftLen, + uint8_t ifftFlag, + uint8_t bitReverseFlag); + + /** + * @brief Processing function for the Q31 CFFT/CIFFT. + * @param[in] *S points to an instance of the Q31 CFFT/CIFFT structure. + * @param[in, out] *pSrc points to the complex data buffer. Processing occurs in-place. + * @return none. + */ + + void arm_cfft_radix4_q31( + const arm_cfft_radix4_instance_q31 * S, + q31_t * pSrc); + + /** + * @brief Initialization function for the Q31 CFFT/CIFFT. + * @param[in,out] *S points to an instance of the Q31 CFFT/CIFFT structure. + * @param[in] fftLen length of the FFT. + * @param[in] ifftFlag flag that selects forward (ifftFlag=0) or inverse (ifftFlag=1) transform. + * @param[in] bitReverseFlag flag that enables (bitReverseFlag=1) or disables (bitReverseFlag=0) bit reversal of output. + * @return arm_status function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_ARGUMENT_ERROR if fftLen is not a supported value. + */ + + arm_status arm_cfft_radix4_init_q31( + arm_cfft_radix4_instance_q31 * S, + uint16_t fftLen, + uint8_t ifftFlag, + uint8_t bitReverseFlag); + + /** + * @brief Processing function for the floating-point CFFT/CIFFT. + * @param[in] *S points to an instance of the floating-point CFFT/CIFFT structure. + * @param[in, out] *pSrc points to the complex data buffer. Processing occurs in-place. + * @return none. + */ + + void arm_cfft_radix4_f32( + const arm_cfft_radix4_instance_f32 * S, + float32_t * pSrc); + + /** + * @brief Initialization function for the floating-point CFFT/CIFFT. + * @param[in,out] *S points to an instance of the floating-point CFFT/CIFFT structure. + * @param[in] fftLen length of the FFT. + * @param[in] ifftFlag flag that selects forward (ifftFlag=0) or inverse (ifftFlag=1) transform. + * @param[in] bitReverseFlag flag that enables (bitReverseFlag=1) or disables (bitReverseFlag=0) bit reversal of output. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_ARGUMENT_ERROR if fftLen is not a supported value. + */ + + arm_status arm_cfft_radix4_init_f32( + arm_cfft_radix4_instance_f32 * S, + uint16_t fftLen, + uint8_t ifftFlag, + uint8_t bitReverseFlag); + + + + /*---------------------------------------------------------------------- + * Internal functions prototypes FFT function + ----------------------------------------------------------------------*/ + + /** + * @brief Core function for the floating-point CFFT butterfly process. + * @param[in, out] *pSrc points to the in-place buffer of floating-point data type. + * @param[in] fftLen length of the FFT. + * @param[in] *pCoef points to the twiddle coefficient buffer. + * @param[in] twidCoefModifier twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. + * @return none. + */ + + void arm_radix4_butterfly_f32( + float32_t * pSrc, + uint16_t fftLen, + float32_t * pCoef, + uint16_t twidCoefModifier); + + /** + * @brief Core function for the floating-point CIFFT butterfly process. + * @param[in, out] *pSrc points to the in-place buffer of floating-point data type. + * @param[in] fftLen length of the FFT. + * @param[in] *pCoef points to twiddle coefficient buffer. + * @param[in] twidCoefModifier twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. + * @param[in] onebyfftLen value of 1/fftLen. + * @return none. + */ + + void arm_radix4_butterfly_inverse_f32( + float32_t * pSrc, + uint16_t fftLen, + float32_t * pCoef, + uint16_t twidCoefModifier, + float32_t onebyfftLen); + + /** + * @brief In-place bit reversal function. + * @param[in, out] *pSrc points to the in-place buffer of floating-point data type. + * @param[in] fftSize length of the FFT. + * @param[in] bitRevFactor bit reversal modifier that supports different size FFTs with the same bit reversal table. + * @param[in] *pBitRevTab points to the bit reversal table. + * @return none. + */ + + void arm_bitreversal_f32( + float32_t *pSrc, + uint16_t fftSize, + uint16_t bitRevFactor, + uint16_t *pBitRevTab); + + /** + * @brief Core function for the Q31 CFFT butterfly process. + * @param[in, out] *pSrc points to the in-place buffer of Q31 data type. + * @param[in] fftLen length of the FFT. + * @param[in] *pCoef points to twiddle coefficient buffer. + * @param[in] twidCoefModifier twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. + * @return none. + */ + + void arm_radix4_butterfly_q31( + q31_t *pSrc, + uint32_t fftLen, + q31_t *pCoef, + uint32_t twidCoefModifier); + + /** + * @brief Core function for the Q31 CIFFT butterfly process. + * @param[in, out] *pSrc points to the in-place buffer of Q31 data type. + * @param[in] fftLen length of the FFT. + * @param[in] *pCoef points to twiddle coefficient buffer. + * @param[in] twidCoefModifier twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. + * @return none. + */ + + void arm_radix4_butterfly_inverse_q31( + q31_t * pSrc, + uint32_t fftLen, + q31_t * pCoef, + uint32_t twidCoefModifier); + + /** + * @brief In-place bit reversal function. + * @param[in, out] *pSrc points to the in-place buffer of Q31 data type. + * @param[in] fftLen length of the FFT. + * @param[in] bitRevFactor bit reversal modifier that supports different size FFTs with the same bit reversal table + * @param[in] *pBitRevTab points to bit reversal table. + * @return none. + */ + + void arm_bitreversal_q31( + q31_t * pSrc, + uint32_t fftLen, + uint16_t bitRevFactor, + uint16_t *pBitRevTab); + + /** + * @brief Core function for the Q15 CFFT butterfly process. + * @param[in, out] *pSrc16 points to the in-place buffer of Q15 data type. + * @param[in] fftLen length of the FFT. + * @param[in] *pCoef16 points to twiddle coefficient buffer. + * @param[in] twidCoefModifier twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. + * @return none. + */ + + void arm_radix4_butterfly_q15( + q15_t *pSrc16, + uint32_t fftLen, + q15_t *pCoef16, + uint32_t twidCoefModifier); + + /** + * @brief Core function for the Q15 CIFFT butterfly process. + * @param[in, out] *pSrc16 points to the in-place buffer of Q15 data type. + * @param[in] fftLen length of the FFT. + * @param[in] *pCoef16 points to twiddle coefficient buffer. + * @param[in] twidCoefModifier twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. + * @return none. + */ + + void arm_radix4_butterfly_inverse_q15( + q15_t *pSrc16, + uint32_t fftLen, + q15_t *pCoef16, + uint32_t twidCoefModifier); + + /** + * @brief In-place bit reversal function. + * @param[in, out] *pSrc points to the in-place buffer of Q15 data type. + * @param[in] fftLen length of the FFT. + * @param[in] bitRevFactor bit reversal modifier that supports different size FFTs with the same bit reversal table + * @param[in] *pBitRevTab points to bit reversal table. + * @return none. + */ + + void arm_bitreversal_q15( + q15_t * pSrc, + uint32_t fftLen, + uint16_t bitRevFactor, + uint16_t *pBitRevTab); + + /** + * @brief Instance structure for the Q15 RFFT/RIFFT function. + */ + + typedef struct + { + uint32_t fftLenReal; /**< length of the real FFT. */ + uint32_t fftLenBy2; /**< length of the complex FFT. */ + uint8_t ifftFlagR; /**< flag that selects forward (ifftFlagR=0) or inverse (ifftFlagR=1) transform. */ + uint8_t bitReverseFlagR; /**< flag that enables (bitReverseFlagR=1) or disables (bitReverseFlagR=0) bit reversal of output. */ + uint32_t twidCoefRModifier; /**< twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. */ + q15_t *pTwiddleAReal; /**< points to the real twiddle factor table. */ + q15_t *pTwiddleBReal; /**< points to the imag twiddle factor table. */ + arm_cfft_radix4_instance_q15 *pCfft; /**< points to the complex FFT instance. */ + } arm_rfft_instance_q15; + + /** + * @brief Instance structure for the Q31 RFFT/RIFFT function. + */ + + typedef struct + { + uint32_t fftLenReal; /**< length of the real FFT. */ + uint32_t fftLenBy2; /**< length of the complex FFT. */ + uint8_t ifftFlagR; /**< flag that selects forward (ifftFlagR=0) or inverse (ifftFlagR=1) transform. */ + uint8_t bitReverseFlagR; /**< flag that enables (bitReverseFlagR=1) or disables (bitReverseFlagR=0) bit reversal of output. */ + uint32_t twidCoefRModifier; /**< twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. */ + q31_t *pTwiddleAReal; /**< points to the real twiddle factor table. */ + q31_t *pTwiddleBReal; /**< points to the imag twiddle factor table. */ + arm_cfft_radix4_instance_q31 *pCfft; /**< points to the complex FFT instance. */ + } arm_rfft_instance_q31; + + /** + * @brief Instance structure for the floating-point RFFT/RIFFT function. + */ + + typedef struct + { + uint32_t fftLenReal; /**< length of the real FFT. */ + uint16_t fftLenBy2; /**< length of the complex FFT. */ + uint8_t ifftFlagR; /**< flag that selects forward (ifftFlagR=0) or inverse (ifftFlagR=1) transform. */ + uint8_t bitReverseFlagR; /**< flag that enables (bitReverseFlagR=1) or disables (bitReverseFlagR=0) bit reversal of output. */ + uint32_t twidCoefRModifier; /**< twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. */ + float32_t *pTwiddleAReal; /**< points to the real twiddle factor table. */ + float32_t *pTwiddleBReal; /**< points to the imag twiddle factor table. */ + arm_cfft_radix4_instance_f32 *pCfft; /**< points to the complex FFT instance. */ + } arm_rfft_instance_f32; + + /** + * @brief Processing function for the Q15 RFFT/RIFFT. + * @param[in] *S points to an instance of the Q15 RFFT/RIFFT structure. + * @param[in] *pSrc points to the input buffer. + * @param[out] *pDst points to the output buffer. + * @return none. + */ + + void arm_rfft_q15( + const arm_rfft_instance_q15 * S, + q15_t * pSrc, + q15_t * pDst); + + /** + * @brief Initialization function for the Q15 RFFT/RIFFT. + * @param[in, out] *S points to an instance of the Q15 RFFT/RIFFT structure. + * @param[in] *S_CFFT points to an instance of the Q15 CFFT/CIFFT structure. + * @param[in] fftLenReal length of the FFT. + * @param[in] ifftFlagR flag that selects forward (ifftFlagR=0) or inverse (ifftFlagR=1) transform. + * @param[in] bitReverseFlag flag that enables (bitReverseFlag=1) or disables (bitReverseFlag=0) bit reversal of output. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_ARGUMENT_ERROR if fftLenReal is not a supported value. + */ + + arm_status arm_rfft_init_q15( + arm_rfft_instance_q15 * S, + arm_cfft_radix4_instance_q15 * S_CFFT, + uint32_t fftLenReal, + uint32_t ifftFlagR, + uint32_t bitReverseFlag); + + /** + * @brief Processing function for the Q31 RFFT/RIFFT. + * @param[in] *S points to an instance of the Q31 RFFT/RIFFT structure. + * @param[in] *pSrc points to the input buffer. + * @param[out] *pDst points to the output buffer. + * @return none. + */ + + void arm_rfft_q31( + const arm_rfft_instance_q31 * S, + q31_t * pSrc, + q31_t * pDst); + + /** + * @brief Initialization function for the Q31 RFFT/RIFFT. + * @param[in, out] *S points to an instance of the Q31 RFFT/RIFFT structure. + * @param[in, out] *S_CFFT points to an instance of the Q31 CFFT/CIFFT structure. + * @param[in] fftLenReal length of the FFT. + * @param[in] ifftFlagR flag that selects forward (ifftFlagR=0) or inverse (ifftFlagR=1) transform. + * @param[in] bitReverseFlag flag that enables (bitReverseFlag=1) or disables (bitReverseFlag=0) bit reversal of output. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_ARGUMENT_ERROR if fftLenReal is not a supported value. + */ + + arm_status arm_rfft_init_q31( + arm_rfft_instance_q31 * S, + arm_cfft_radix4_instance_q31 * S_CFFT, + uint32_t fftLenReal, + uint32_t ifftFlagR, + uint32_t bitReverseFlag); + + /** + * @brief Initialization function for the floating-point RFFT/RIFFT. + * @param[in,out] *S points to an instance of the floating-point RFFT/RIFFT structure. + * @param[in,out] *S_CFFT points to an instance of the floating-point CFFT/CIFFT structure. + * @param[in] fftLenReal length of the FFT. + * @param[in] ifftFlagR flag that selects forward (ifftFlagR=0) or inverse (ifftFlagR=1) transform. + * @param[in] bitReverseFlag flag that enables (bitReverseFlag=1) or disables (bitReverseFlag=0) bit reversal of output. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_ARGUMENT_ERROR if fftLenReal is not a supported value. + */ + + arm_status arm_rfft_init_f32( + arm_rfft_instance_f32 * S, + arm_cfft_radix4_instance_f32 * S_CFFT, + uint32_t fftLenReal, + uint32_t ifftFlagR, + uint32_t bitReverseFlag); + + /** + * @brief Processing function for the floating-point RFFT/RIFFT. + * @param[in] *S points to an instance of the floating-point RFFT/RIFFT structure. + * @param[in] *pSrc points to the input buffer. + * @param[out] *pDst points to the output buffer. + * @return none. + */ + + void arm_rfft_f32( + const arm_rfft_instance_f32 * S, + float32_t * pSrc, + float32_t * pDst); + + /** + * @brief Instance structure for the floating-point DCT4/IDCT4 function. + */ + + typedef struct + { + uint16_t N; /**< length of the DCT4. */ + uint16_t Nby2; /**< half of the length of the DCT4. */ + float32_t normalize; /**< normalizing factor. */ + float32_t *pTwiddle; /**< points to the twiddle factor table. */ + float32_t *pCosFactor; /**< points to the cosFactor table. */ + arm_rfft_instance_f32 *pRfft; /**< points to the real FFT instance. */ + arm_cfft_radix4_instance_f32 *pCfft; /**< points to the complex FFT instance. */ + } arm_dct4_instance_f32; + + /** + * @brief Initialization function for the floating-point DCT4/IDCT4. + * @param[in,out] *S points to an instance of floating-point DCT4/IDCT4 structure. + * @param[in] *S_RFFT points to an instance of floating-point RFFT/RIFFT structure. + * @param[in] *S_CFFT points to an instance of floating-point CFFT/CIFFT structure. + * @param[in] N length of the DCT4. + * @param[in] Nby2 half of the length of the DCT4. + * @param[in] normalize normalizing factor. + * @return arm_status function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_ARGUMENT_ERROR if fftLenReal is not a supported transform length. + */ + + arm_status arm_dct4_init_f32( + arm_dct4_instance_f32 * S, + arm_rfft_instance_f32 * S_RFFT, + arm_cfft_radix4_instance_f32 * S_CFFT, + uint16_t N, + uint16_t Nby2, + float32_t normalize); + + /** + * @brief Processing function for the floating-point DCT4/IDCT4. + * @param[in] *S points to an instance of the floating-point DCT4/IDCT4 structure. + * @param[in] *pState points to state buffer. + * @param[in,out] *pInlineBuffer points to the in-place input and output buffer. + * @return none. + */ + + void arm_dct4_f32( + const arm_dct4_instance_f32 * S, + float32_t * pState, + float32_t * pInlineBuffer); + + /** + * @brief Instance structure for the Q31 DCT4/IDCT4 function. + */ + + typedef struct + { + uint16_t N; /**< length of the DCT4. */ + uint16_t Nby2; /**< half of the length of the DCT4. */ + q31_t normalize; /**< normalizing factor. */ + q31_t *pTwiddle; /**< points to the twiddle factor table. */ + q31_t *pCosFactor; /**< points to the cosFactor table. */ + arm_rfft_instance_q31 *pRfft; /**< points to the real FFT instance. */ + arm_cfft_radix4_instance_q31 *pCfft; /**< points to the complex FFT instance. */ + } arm_dct4_instance_q31; + + /** + * @brief Initialization function for the Q31 DCT4/IDCT4. + * @param[in,out] *S points to an instance of Q31 DCT4/IDCT4 structure. + * @param[in] *S_RFFT points to an instance of Q31 RFFT/RIFFT structure + * @param[in] *S_CFFT points to an instance of Q31 CFFT/CIFFT structure + * @param[in] N length of the DCT4. + * @param[in] Nby2 half of the length of the DCT4. + * @param[in] normalize normalizing factor. + * @return arm_status function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_ARGUMENT_ERROR if N is not a supported transform length. + */ + + arm_status arm_dct4_init_q31( + arm_dct4_instance_q31 * S, + arm_rfft_instance_q31 * S_RFFT, + arm_cfft_radix4_instance_q31 * S_CFFT, + uint16_t N, + uint16_t Nby2, + q31_t normalize); + + /** + * @brief Processing function for the Q31 DCT4/IDCT4. + * @param[in] *S points to an instance of the Q31 DCT4 structure. + * @param[in] *pState points to state buffer. + * @param[in,out] *pInlineBuffer points to the in-place input and output buffer. + * @return none. + */ + + void arm_dct4_q31( + const arm_dct4_instance_q31 * S, + q31_t * pState, + q31_t * pInlineBuffer); + + /** + * @brief Instance structure for the Q15 DCT4/IDCT4 function. + */ + + typedef struct + { + uint16_t N; /**< length of the DCT4. */ + uint16_t Nby2; /**< half of the length of the DCT4. */ + q15_t normalize; /**< normalizing factor. */ + q15_t *pTwiddle; /**< points to the twiddle factor table. */ + q15_t *pCosFactor; /**< points to the cosFactor table. */ + arm_rfft_instance_q15 *pRfft; /**< points to the real FFT instance. */ + arm_cfft_radix4_instance_q15 *pCfft; /**< points to the complex FFT instance. */ + } arm_dct4_instance_q15; + + /** + * @brief Initialization function for the Q15 DCT4/IDCT4. + * @param[in,out] *S points to an instance of Q15 DCT4/IDCT4 structure. + * @param[in] *S_RFFT points to an instance of Q15 RFFT/RIFFT structure. + * @param[in] *S_CFFT points to an instance of Q15 CFFT/CIFFT structure. + * @param[in] N length of the DCT4. + * @param[in] Nby2 half of the length of the DCT4. + * @param[in] normalize normalizing factor. + * @return arm_status function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_ARGUMENT_ERROR if N is not a supported transform length. + */ + + arm_status arm_dct4_init_q15( + arm_dct4_instance_q15 * S, + arm_rfft_instance_q15 * S_RFFT, + arm_cfft_radix4_instance_q15 * S_CFFT, + uint16_t N, + uint16_t Nby2, + q15_t normalize); + + /** + * @brief Processing function for the Q15 DCT4/IDCT4. + * @param[in] *S points to an instance of the Q15 DCT4 structure. + * @param[in] *pState points to state buffer. + * @param[in,out] *pInlineBuffer points to the in-place input and output buffer. + * @return none. + */ + + void arm_dct4_q15( + const arm_dct4_instance_q15 * S, + q15_t * pState, + q15_t * pInlineBuffer); + + /** + * @brief Floating-point vector addition. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_add_f32( + float32_t * pSrcA, + float32_t * pSrcB, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Q7 vector addition. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_add_q7( + q7_t * pSrcA, + q7_t * pSrcB, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Q15 vector addition. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_add_q15( + q15_t * pSrcA, + q15_t * pSrcB, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Q31 vector addition. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_add_q31( + q31_t * pSrcA, + q31_t * pSrcB, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Floating-point vector subtraction. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_sub_f32( + float32_t * pSrcA, + float32_t * pSrcB, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Q7 vector subtraction. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_sub_q7( + q7_t * pSrcA, + q7_t * pSrcB, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Q15 vector subtraction. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_sub_q15( + q15_t * pSrcA, + q15_t * pSrcB, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Q31 vector subtraction. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_sub_q31( + q31_t * pSrcA, + q31_t * pSrcB, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Multiplies a floating-point vector by a scalar. + * @param[in] *pSrc points to the input vector + * @param[in] scale scale factor to be applied + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_scale_f32( + float32_t * pSrc, + float32_t scale, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Multiplies a Q7 vector by a scalar. + * @param[in] *pSrc points to the input vector + * @param[in] scaleFract fractional portion of the scale value + * @param[in] shift number of bits to shift the result by + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_scale_q7( + q7_t * pSrc, + q7_t scaleFract, + int8_t shift, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Multiplies a Q15 vector by a scalar. + * @param[in] *pSrc points to the input vector + * @param[in] scaleFract fractional portion of the scale value + * @param[in] shift number of bits to shift the result by + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_scale_q15( + q15_t * pSrc, + q15_t scaleFract, + int8_t shift, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Multiplies a Q31 vector by a scalar. + * @param[in] *pSrc points to the input vector + * @param[in] scaleFract fractional portion of the scale value + * @param[in] shift number of bits to shift the result by + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_scale_q31( + q31_t * pSrc, + q31_t scaleFract, + int8_t shift, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Q7 vector absolute value. + * @param[in] *pSrc points to the input buffer + * @param[out] *pDst points to the output buffer + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_abs_q7( + q7_t * pSrc, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Floating-point vector absolute value. + * @param[in] *pSrc points to the input buffer + * @param[out] *pDst points to the output buffer + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_abs_f32( + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Q15 vector absolute value. + * @param[in] *pSrc points to the input buffer + * @param[out] *pDst points to the output buffer + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_abs_q15( + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Q31 vector absolute value. + * @param[in] *pSrc points to the input buffer + * @param[out] *pDst points to the output buffer + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_abs_q31( + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Dot product of floating-point vectors. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[in] blockSize number of samples in each vector + * @param[out] *result output result returned here + * @return none. + */ + + void arm_dot_prod_f32( + float32_t * pSrcA, + float32_t * pSrcB, + uint32_t blockSize, + float32_t * result); + + /** + * @brief Dot product of Q7 vectors. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[in] blockSize number of samples in each vector + * @param[out] *result output result returned here + * @return none. + */ + + void arm_dot_prod_q7( + q7_t * pSrcA, + q7_t * pSrcB, + uint32_t blockSize, + q31_t * result); + + /** + * @brief Dot product of Q15 vectors. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[in] blockSize number of samples in each vector + * @param[out] *result output result returned here + * @return none. + */ + + void arm_dot_prod_q15( + q15_t * pSrcA, + q15_t * pSrcB, + uint32_t blockSize, + q63_t * result); + + /** + * @brief Dot product of Q31 vectors. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[in] blockSize number of samples in each vector + * @param[out] *result output result returned here + * @return none. + */ + + void arm_dot_prod_q31( + q31_t * pSrcA, + q31_t * pSrcB, + uint32_t blockSize, + q63_t * result); + + /** + * @brief Shifts the elements of a Q7 vector a specified number of bits. + * @param[in] *pSrc points to the input vector + * @param[in] shiftBits number of bits to shift. A positive value shifts left; a negative value shifts right. + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_shift_q7( + q7_t * pSrc, + int8_t shiftBits, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Shifts the elements of a Q15 vector a specified number of bits. + * @param[in] *pSrc points to the input vector + * @param[in] shiftBits number of bits to shift. A positive value shifts left; a negative value shifts right. + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_shift_q15( + q15_t * pSrc, + int8_t shiftBits, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Shifts the elements of a Q31 vector a specified number of bits. + * @param[in] *pSrc points to the input vector + * @param[in] shiftBits number of bits to shift. A positive value shifts left; a negative value shifts right. + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_shift_q31( + q31_t * pSrc, + int8_t shiftBits, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Adds a constant offset to a floating-point vector. + * @param[in] *pSrc points to the input vector + * @param[in] offset is the offset to be added + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_offset_f32( + float32_t * pSrc, + float32_t offset, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Adds a constant offset to a Q7 vector. + * @param[in] *pSrc points to the input vector + * @param[in] offset is the offset to be added + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_offset_q7( + q7_t * pSrc, + q7_t offset, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Adds a constant offset to a Q15 vector. + * @param[in] *pSrc points to the input vector + * @param[in] offset is the offset to be added + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_offset_q15( + q15_t * pSrc, + q15_t offset, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Adds a constant offset to a Q31 vector. + * @param[in] *pSrc points to the input vector + * @param[in] offset is the offset to be added + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_offset_q31( + q31_t * pSrc, + q31_t offset, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Negates the elements of a floating-point vector. + * @param[in] *pSrc points to the input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_negate_f32( + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Negates the elements of a Q7 vector. + * @param[in] *pSrc points to the input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_negate_q7( + q7_t * pSrc, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Negates the elements of a Q15 vector. + * @param[in] *pSrc points to the input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_negate_q15( + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Negates the elements of a Q31 vector. + * @param[in] *pSrc points to the input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_negate_q31( + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + /** + * @brief Copies the elements of a floating-point vector. + * @param[in] *pSrc input pointer + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_copy_f32( + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Copies the elements of a Q7 vector. + * @param[in] *pSrc input pointer + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_copy_q7( + q7_t * pSrc, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Copies the elements of a Q15 vector. + * @param[in] *pSrc input pointer + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_copy_q15( + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Copies the elements of a Q31 vector. + * @param[in] *pSrc input pointer + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_copy_q31( + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + /** + * @brief Fills a constant value into a floating-point vector. + * @param[in] value input value to be filled + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_fill_f32( + float32_t value, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Fills a constant value into a Q7 vector. + * @param[in] value input value to be filled + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_fill_q7( + q7_t value, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Fills a constant value into a Q15 vector. + * @param[in] value input value to be filled + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_fill_q15( + q15_t value, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Fills a constant value into a Q31 vector. + * @param[in] value input value to be filled + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_fill_q31( + q31_t value, + q31_t * pDst, + uint32_t blockSize); + +/** + * @brief Convolution of floating-point sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the location where the output result is written. Length srcALen+srcBLen-1. + * @return none. + */ + + void arm_conv_f32( + float32_t * pSrcA, + uint32_t srcALen, + float32_t * pSrcB, + uint32_t srcBLen, + float32_t * pDst); + +/** + * @brief Convolution of Q15 sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the location where the output result is written. Length srcALen+srcBLen-1. + * @return none. + */ + + void arm_conv_q15( + q15_t * pSrcA, + uint32_t srcALen, + q15_t * pSrcB, + uint32_t srcBLen, + q15_t * pDst); + + /** + * @brief Convolution of Q15 sequences (fast version) for Cortex-M3 and Cortex-M4 + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length srcALen+srcBLen-1. + * @return none. + */ + + void arm_conv_fast_q15( + q15_t * pSrcA, + uint32_t srcALen, + q15_t * pSrcB, + uint32_t srcBLen, + q15_t * pDst); + + /** + * @brief Convolution of Q31 sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length srcALen+srcBLen-1. + * @return none. + */ + + void arm_conv_q31( + q31_t * pSrcA, + uint32_t srcALen, + q31_t * pSrcB, + uint32_t srcBLen, + q31_t * pDst); + + /** + * @brief Convolution of Q31 sequences (fast version) for Cortex-M3 and Cortex-M4 + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length srcALen+srcBLen-1. + * @return none. + */ + + void arm_conv_fast_q31( + q31_t * pSrcA, + uint32_t srcALen, + q31_t * pSrcB, + uint32_t srcBLen, + q31_t * pDst); + + /** + * @brief Convolution of Q7 sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length srcALen+srcBLen-1. + * @return none. + */ + + void arm_conv_q7( + q7_t * pSrcA, + uint32_t srcALen, + q7_t * pSrcB, + uint32_t srcBLen, + q7_t * pDst); + + /** + * @brief Partial convolution of floating-point sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data + * @param[in] firstIndex is the first output sample to start with. + * @param[in] numPoints is the number of output points to be computed. + * @return Returns either ARM_MATH_SUCCESS if the function completed correctly or ARM_MATH_ARGUMENT_ERROR if the requested subset is not in the range [0 srcALen+srcBLen-2]. + */ + + arm_status arm_conv_partial_f32( + float32_t * pSrcA, + uint32_t srcALen, + float32_t * pSrcB, + uint32_t srcBLen, + float32_t * pDst, + uint32_t firstIndex, + uint32_t numPoints); + + /** + * @brief Partial convolution of Q15 sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data + * @param[in] firstIndex is the first output sample to start with. + * @param[in] numPoints is the number of output points to be computed. + * @return Returns either ARM_MATH_SUCCESS if the function completed correctly or ARM_MATH_ARGUMENT_ERROR if the requested subset is not in the range [0 srcALen+srcBLen-2]. + */ + + arm_status arm_conv_partial_q15( + q15_t * pSrcA, + uint32_t srcALen, + q15_t * pSrcB, + uint32_t srcBLen, + q15_t * pDst, + uint32_t firstIndex, + uint32_t numPoints); + + /** + * @brief Partial convolution of Q15 sequences (fast version) for Cortex-M3 and Cortex-M4 + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data + * @param[in] firstIndex is the first output sample to start with. + * @param[in] numPoints is the number of output points to be computed. + * @return Returns either ARM_MATH_SUCCESS if the function completed correctly or ARM_MATH_ARGUMENT_ERROR if the requested subset is not in the range [0 srcALen+srcBLen-2]. + */ + + arm_status arm_conv_partial_fast_q15( + q15_t * pSrcA, + uint32_t srcALen, + q15_t * pSrcB, + uint32_t srcBLen, + q15_t * pDst, + uint32_t firstIndex, + uint32_t numPoints); + + /** + * @brief Partial convolution of Q31 sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data + * @param[in] firstIndex is the first output sample to start with. + * @param[in] numPoints is the number of output points to be computed. + * @return Returns either ARM_MATH_SUCCESS if the function completed correctly or ARM_MATH_ARGUMENT_ERROR if the requested subset is not in the range [0 srcALen+srcBLen-2]. + */ + + arm_status arm_conv_partial_q31( + q31_t * pSrcA, + uint32_t srcALen, + q31_t * pSrcB, + uint32_t srcBLen, + q31_t * pDst, + uint32_t firstIndex, + uint32_t numPoints); + + + /** + * @brief Partial convolution of Q31 sequences (fast version) for Cortex-M3 and Cortex-M4 + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data + * @param[in] firstIndex is the first output sample to start with. + * @param[in] numPoints is the number of output points to be computed. + * @return Returns either ARM_MATH_SUCCESS if the function completed correctly or ARM_MATH_ARGUMENT_ERROR if the requested subset is not in the range [0 srcALen+srcBLen-2]. + */ + + arm_status arm_conv_partial_fast_q31( + q31_t * pSrcA, + uint32_t srcALen, + q31_t * pSrcB, + uint32_t srcBLen, + q31_t * pDst, + uint32_t firstIndex, + uint32_t numPoints); + + /** + * @brief Partial convolution of Q7 sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data + * @param[in] firstIndex is the first output sample to start with. + * @param[in] numPoints is the number of output points to be computed. + * @return Returns either ARM_MATH_SUCCESS if the function completed correctly or ARM_MATH_ARGUMENT_ERROR if the requested subset is not in the range [0 srcALen+srcBLen-2]. + */ + + arm_status arm_conv_partial_q7( + q7_t * pSrcA, + uint32_t srcALen, + q7_t * pSrcB, + uint32_t srcBLen, + q7_t * pDst, + uint32_t firstIndex, + uint32_t numPoints); + + + /** + * @brief Instance structure for the Q15 FIR decimator. + */ + + typedef struct + { + uint8_t M; /**< decimation factor. */ + uint16_t numTaps; /**< number of coefficients in the filter. */ + q15_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps.*/ + q15_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + } arm_fir_decimate_instance_q15; + + /** + * @brief Instance structure for the Q31 FIR decimator. + */ + + typedef struct + { + uint8_t M; /**< decimation factor. */ + uint16_t numTaps; /**< number of coefficients in the filter. */ + q31_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps.*/ + q31_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + + } arm_fir_decimate_instance_q31; + + /** + * @brief Instance structure for the floating-point FIR decimator. + */ + + typedef struct + { + uint8_t M; /**< decimation factor. */ + uint16_t numTaps; /**< number of coefficients in the filter. */ + float32_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps.*/ + float32_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + + } arm_fir_decimate_instance_f32; + + + + /** + * @brief Processing function for the floating-point FIR decimator. + * @param[in] *S points to an instance of the floating-point FIR decimator structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] blockSize number of input samples to process per call. + * @return none + */ + + void arm_fir_decimate_f32( + const arm_fir_decimate_instance_f32 * S, + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + + /** + * @brief Initialization function for the floating-point FIR decimator. + * @param[in,out] *S points to an instance of the floating-point FIR decimator structure. + * @param[in] numTaps number of coefficients in the filter. + * @param[in] M decimation factor. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of input samples to process per call. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_LENGTH_ERROR if + * blockSize is not a multiple of M. + */ + + arm_status arm_fir_decimate_init_f32( + arm_fir_decimate_instance_f32 * S, + uint16_t numTaps, + uint8_t M, + float32_t * pCoeffs, + float32_t * pState, + uint32_t blockSize); + + /** + * @brief Processing function for the Q15 FIR decimator. + * @param[in] *S points to an instance of the Q15 FIR decimator structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] blockSize number of input samples to process per call. + * @return none + */ + + void arm_fir_decimate_q15( + const arm_fir_decimate_instance_q15 * S, + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Processing function for the Q15 FIR decimator (fast variant) for Cortex-M3 and Cortex-M4. + * @param[in] *S points to an instance of the Q15 FIR decimator structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] blockSize number of input samples to process per call. + * @return none + */ + + void arm_fir_decimate_fast_q15( + const arm_fir_decimate_instance_q15 * S, + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + + + /** + * @brief Initialization function for the Q15 FIR decimator. + * @param[in,out] *S points to an instance of the Q15 FIR decimator structure. + * @param[in] numTaps number of coefficients in the filter. + * @param[in] M decimation factor. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of input samples to process per call. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_LENGTH_ERROR if + * blockSize is not a multiple of M. + */ + + arm_status arm_fir_decimate_init_q15( + arm_fir_decimate_instance_q15 * S, + uint16_t numTaps, + uint8_t M, + q15_t * pCoeffs, + q15_t * pState, + uint32_t blockSize); + + /** + * @brief Processing function for the Q31 FIR decimator. + * @param[in] *S points to an instance of the Q31 FIR decimator structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] blockSize number of input samples to process per call. + * @return none + */ + + void arm_fir_decimate_q31( + const arm_fir_decimate_instance_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Processing function for the Q31 FIR decimator (fast variant) for Cortex-M3 and Cortex-M4. + * @param[in] *S points to an instance of the Q31 FIR decimator structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] blockSize number of input samples to process per call. + * @return none + */ + + void arm_fir_decimate_fast_q31( + arm_fir_decimate_instance_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + + /** + * @brief Initialization function for the Q31 FIR decimator. + * @param[in,out] *S points to an instance of the Q31 FIR decimator structure. + * @param[in] numTaps number of coefficients in the filter. + * @param[in] M decimation factor. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of input samples to process per call. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_LENGTH_ERROR if + * blockSize is not a multiple of M. + */ + + arm_status arm_fir_decimate_init_q31( + arm_fir_decimate_instance_q31 * S, + uint16_t numTaps, + uint8_t M, + q31_t * pCoeffs, + q31_t * pState, + uint32_t blockSize); + + + + /** + * @brief Instance structure for the Q15 FIR interpolator. + */ + + typedef struct + { + uint8_t L; /**< upsample factor. */ + uint16_t phaseLength; /**< length of each polyphase filter component. */ + q15_t *pCoeffs; /**< points to the coefficient array. The array is of length L*phaseLength. */ + q15_t *pState; /**< points to the state variable array. The array is of length blockSize+phaseLength-1. */ + } arm_fir_interpolate_instance_q15; + + /** + * @brief Instance structure for the Q31 FIR interpolator. + */ + + typedef struct + { + uint8_t L; /**< upsample factor. */ + uint16_t phaseLength; /**< length of each polyphase filter component. */ + q31_t *pCoeffs; /**< points to the coefficient array. The array is of length L*phaseLength. */ + q31_t *pState; /**< points to the state variable array. The array is of length blockSize+phaseLength-1. */ + } arm_fir_interpolate_instance_q31; + + /** + * @brief Instance structure for the floating-point FIR interpolator. + */ + + typedef struct + { + uint8_t L; /**< upsample factor. */ + uint16_t phaseLength; /**< length of each polyphase filter component. */ + float32_t *pCoeffs; /**< points to the coefficient array. The array is of length L*phaseLength. */ + float32_t *pState; /**< points to the state variable array. The array is of length phaseLength+numTaps-1. */ + } arm_fir_interpolate_instance_f32; + + + /** + * @brief Processing function for the Q15 FIR interpolator. + * @param[in] *S points to an instance of the Q15 FIR interpolator structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of input samples to process per call. + * @return none. + */ + + void arm_fir_interpolate_q15( + const arm_fir_interpolate_instance_q15 * S, + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + + /** + * @brief Initialization function for the Q15 FIR interpolator. + * @param[in,out] *S points to an instance of the Q15 FIR interpolator structure. + * @param[in] L upsample factor. + * @param[in] numTaps number of filter coefficients in the filter. + * @param[in] *pCoeffs points to the filter coefficient buffer. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of input samples to process per call. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_LENGTH_ERROR if + * the filter length numTaps is not a multiple of the interpolation factor L. + */ + + arm_status arm_fir_interpolate_init_q15( + arm_fir_interpolate_instance_q15 * S, + uint8_t L, + uint16_t numTaps, + q15_t * pCoeffs, + q15_t * pState, + uint32_t blockSize); + + /** + * @brief Processing function for the Q31 FIR interpolator. + * @param[in] *S points to an instance of the Q15 FIR interpolator structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of input samples to process per call. + * @return none. + */ + + void arm_fir_interpolate_q31( + const arm_fir_interpolate_instance_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the Q31 FIR interpolator. + * @param[in,out] *S points to an instance of the Q31 FIR interpolator structure. + * @param[in] L upsample factor. + * @param[in] numTaps number of filter coefficients in the filter. + * @param[in] *pCoeffs points to the filter coefficient buffer. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of input samples to process per call. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_LENGTH_ERROR if + * the filter length numTaps is not a multiple of the interpolation factor L. + */ + + arm_status arm_fir_interpolate_init_q31( + arm_fir_interpolate_instance_q31 * S, + uint8_t L, + uint16_t numTaps, + q31_t * pCoeffs, + q31_t * pState, + uint32_t blockSize); + + + /** + * @brief Processing function for the floating-point FIR interpolator. + * @param[in] *S points to an instance of the floating-point FIR interpolator structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of input samples to process per call. + * @return none. + */ + + void arm_fir_interpolate_f32( + const arm_fir_interpolate_instance_f32 * S, + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the floating-point FIR interpolator. + * @param[in,out] *S points to an instance of the floating-point FIR interpolator structure. + * @param[in] L upsample factor. + * @param[in] numTaps number of filter coefficients in the filter. + * @param[in] *pCoeffs points to the filter coefficient buffer. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of input samples to process per call. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_LENGTH_ERROR if + * the filter length numTaps is not a multiple of the interpolation factor L. + */ + + arm_status arm_fir_interpolate_init_f32( + arm_fir_interpolate_instance_f32 * S, + uint8_t L, + uint16_t numTaps, + float32_t * pCoeffs, + float32_t * pState, + uint32_t blockSize); + + /** + * @brief Instance structure for the high precision Q31 Biquad cascade filter. + */ + + typedef struct + { + uint8_t numStages; /**< number of 2nd order stages in the filter. Overall order is 2*numStages. */ + q63_t *pState; /**< points to the array of state coefficients. The array is of length 4*numStages. */ + q31_t *pCoeffs; /**< points to the array of coefficients. The array is of length 5*numStages. */ + uint8_t postShift; /**< additional shift, in bits, applied to each output sample. */ + + } arm_biquad_cas_df1_32x64_ins_q31; + + + /** + * @param[in] *S points to an instance of the high precision Q31 Biquad cascade filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_biquad_cas_df1_32x64_q31( + const arm_biquad_cas_df1_32x64_ins_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + + /** + * @param[in,out] *S points to an instance of the high precision Q31 Biquad cascade filter structure. + * @param[in] numStages number of 2nd order stages in the filter. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] postShift shift to be applied to the output. Varies according to the coefficients format + * @return none + */ + + void arm_biquad_cas_df1_32x64_init_q31( + arm_biquad_cas_df1_32x64_ins_q31 * S, + uint8_t numStages, + q31_t * pCoeffs, + q63_t * pState, + uint8_t postShift); + + + + /** + * @brief Instance structure for the floating-point transposed direct form II Biquad cascade filter. + */ + + typedef struct + { + uint8_t numStages; /**< number of 2nd order stages in the filter. Overall order is 2*numStages. */ + float32_t *pState; /**< points to the array of state coefficients. The array is of length 2*numStages. */ + float32_t *pCoeffs; /**< points to the array of coefficients. The array is of length 5*numStages. */ + } arm_biquad_cascade_df2T_instance_f32; + + + /** + * @brief Processing function for the floating-point transposed direct form II Biquad cascade filter. + * @param[in] *S points to an instance of the filter data structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_biquad_cascade_df2T_f32( + const arm_biquad_cascade_df2T_instance_f32 * S, + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + + /** + * @brief Initialization function for the floating-point transposed direct form II Biquad cascade filter. + * @param[in,out] *S points to an instance of the filter data structure. + * @param[in] numStages number of 2nd order stages in the filter. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @return none + */ + + void arm_biquad_cascade_df2T_init_f32( + arm_biquad_cascade_df2T_instance_f32 * S, + uint8_t numStages, + float32_t * pCoeffs, + float32_t * pState); + + + + /** + * @brief Instance structure for the Q15 FIR lattice filter. + */ + + typedef struct + { + uint16_t numStages; /**< number of filter stages. */ + q15_t *pState; /**< points to the state variable array. The array is of length numStages. */ + q15_t *pCoeffs; /**< points to the coefficient array. The array is of length numStages. */ + } arm_fir_lattice_instance_q15; + + /** + * @brief Instance structure for the Q31 FIR lattice filter. + */ + + typedef struct + { + uint16_t numStages; /**< number of filter stages. */ + q31_t *pState; /**< points to the state variable array. The array is of length numStages. */ + q31_t *pCoeffs; /**< points to the coefficient array. The array is of length numStages. */ + } arm_fir_lattice_instance_q31; + + /** + * @brief Instance structure for the floating-point FIR lattice filter. + */ + + typedef struct + { + uint16_t numStages; /**< number of filter stages. */ + float32_t *pState; /**< points to the state variable array. The array is of length numStages. */ + float32_t *pCoeffs; /**< points to the coefficient array. The array is of length numStages. */ + } arm_fir_lattice_instance_f32; + + /** + * @brief Initialization function for the Q15 FIR lattice filter. + * @param[in] *S points to an instance of the Q15 FIR lattice structure. + * @param[in] numStages number of filter stages. + * @param[in] *pCoeffs points to the coefficient buffer. The array is of length numStages. + * @param[in] *pState points to the state buffer. The array is of length numStages. + * @return none. + */ + + void arm_fir_lattice_init_q15( + arm_fir_lattice_instance_q15 * S, + uint16_t numStages, + q15_t * pCoeffs, + q15_t * pState); + + + /** + * @brief Processing function for the Q15 FIR lattice filter. + * @param[in] *S points to an instance of the Q15 FIR lattice structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + void arm_fir_lattice_q15( + const arm_fir_lattice_instance_q15 * S, + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the Q31 FIR lattice filter. + * @param[in] *S points to an instance of the Q31 FIR lattice structure. + * @param[in] numStages number of filter stages. + * @param[in] *pCoeffs points to the coefficient buffer. The array is of length numStages. + * @param[in] *pState points to the state buffer. The array is of length numStages. + * @return none. + */ + + void arm_fir_lattice_init_q31( + arm_fir_lattice_instance_q31 * S, + uint16_t numStages, + q31_t * pCoeffs, + q31_t * pState); + + + /** + * @brief Processing function for the Q31 FIR lattice filter. + * @param[in] *S points to an instance of the Q31 FIR lattice structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_fir_lattice_q31( + const arm_fir_lattice_instance_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + +/** + * @brief Initialization function for the floating-point FIR lattice filter. + * @param[in] *S points to an instance of the floating-point FIR lattice structure. + * @param[in] numStages number of filter stages. + * @param[in] *pCoeffs points to the coefficient buffer. The array is of length numStages. + * @param[in] *pState points to the state buffer. The array is of length numStages. + * @return none. + */ + + void arm_fir_lattice_init_f32( + arm_fir_lattice_instance_f32 * S, + uint16_t numStages, + float32_t * pCoeffs, + float32_t * pState); + + /** + * @brief Processing function for the floating-point FIR lattice filter. + * @param[in] *S points to an instance of the floating-point FIR lattice structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_fir_lattice_f32( + const arm_fir_lattice_instance_f32 * S, + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Instance structure for the Q15 IIR lattice filter. + */ + typedef struct + { + uint16_t numStages; /**< number of stages in the filter. */ + q15_t *pState; /**< points to the state variable array. The array is of length numStages+blockSize. */ + q15_t *pkCoeffs; /**< points to the reflection coefficient array. The array is of length numStages. */ + q15_t *pvCoeffs; /**< points to the ladder coefficient array. The array is of length numStages+1. */ + } arm_iir_lattice_instance_q15; + + /** + * @brief Instance structure for the Q31 IIR lattice filter. + */ + typedef struct + { + uint16_t numStages; /**< number of stages in the filter. */ + q31_t *pState; /**< points to the state variable array. The array is of length numStages+blockSize. */ + q31_t *pkCoeffs; /**< points to the reflection coefficient array. The array is of length numStages. */ + q31_t *pvCoeffs; /**< points to the ladder coefficient array. The array is of length numStages+1. */ + } arm_iir_lattice_instance_q31; + + /** + * @brief Instance structure for the floating-point IIR lattice filter. + */ + typedef struct + { + uint16_t numStages; /**< number of stages in the filter. */ + float32_t *pState; /**< points to the state variable array. The array is of length numStages+blockSize. */ + float32_t *pkCoeffs; /**< points to the reflection coefficient array. The array is of length numStages. */ + float32_t *pvCoeffs; /**< points to the ladder coefficient array. The array is of length numStages+1. */ + } arm_iir_lattice_instance_f32; + + /** + * @brief Processing function for the floating-point IIR lattice filter. + * @param[in] *S points to an instance of the floating-point IIR lattice structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_iir_lattice_f32( + const arm_iir_lattice_instance_f32 * S, + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the floating-point IIR lattice filter. + * @param[in] *S points to an instance of the floating-point IIR lattice structure. + * @param[in] numStages number of stages in the filter. + * @param[in] *pkCoeffs points to the reflection coefficient buffer. The array is of length numStages. + * @param[in] *pvCoeffs points to the ladder coefficient buffer. The array is of length numStages+1. + * @param[in] *pState points to the state buffer. The array is of length numStages+blockSize-1. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_iir_lattice_init_f32( + arm_iir_lattice_instance_f32 * S, + uint16_t numStages, + float32_t *pkCoeffs, + float32_t *pvCoeffs, + float32_t *pState, + uint32_t blockSize); + + + /** + * @brief Processing function for the Q31 IIR lattice filter. + * @param[in] *S points to an instance of the Q31 IIR lattice structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_iir_lattice_q31( + const arm_iir_lattice_instance_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + + /** + * @brief Initialization function for the Q31 IIR lattice filter. + * @param[in] *S points to an instance of the Q31 IIR lattice structure. + * @param[in] numStages number of stages in the filter. + * @param[in] *pkCoeffs points to the reflection coefficient buffer. The array is of length numStages. + * @param[in] *pvCoeffs points to the ladder coefficient buffer. The array is of length numStages+1. + * @param[in] *pState points to the state buffer. The array is of length numStages+blockSize. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_iir_lattice_init_q31( + arm_iir_lattice_instance_q31 * S, + uint16_t numStages, + q31_t *pkCoeffs, + q31_t *pvCoeffs, + q31_t *pState, + uint32_t blockSize); + + + /** + * @brief Processing function for the Q15 IIR lattice filter. + * @param[in] *S points to an instance of the Q15 IIR lattice structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_iir_lattice_q15( + const arm_iir_lattice_instance_q15 * S, + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + +/** + * @brief Initialization function for the Q15 IIR lattice filter. + * @param[in] *S points to an instance of the fixed-point Q15 IIR lattice structure. + * @param[in] numStages number of stages in the filter. + * @param[in] *pkCoeffs points to reflection coefficient buffer. The array is of length numStages. + * @param[in] *pvCoeffs points to ladder coefficient buffer. The array is of length numStages+1. + * @param[in] *pState points to state buffer. The array is of length numStages+blockSize. + * @param[in] blockSize number of samples to process per call. + * @return none. + */ + + void arm_iir_lattice_init_q15( + arm_iir_lattice_instance_q15 * S, + uint16_t numStages, + q15_t *pkCoeffs, + q15_t *pvCoeffs, + q15_t *pState, + uint32_t blockSize); + + /** + * @brief Instance structure for the floating-point LMS filter. + */ + + typedef struct + { + uint16_t numTaps; /**< number of coefficients in the filter. */ + float32_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + float32_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps. */ + float32_t mu; /**< step size that controls filter coefficient updates. */ + } arm_lms_instance_f32; + + /** + * @brief Processing function for floating-point LMS filter. + * @param[in] *S points to an instance of the floating-point LMS filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[in] *pRef points to the block of reference data. + * @param[out] *pOut points to the block of output data. + * @param[out] *pErr points to the block of error data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_lms_f32( + const arm_lms_instance_f32 * S, + float32_t * pSrc, + float32_t * pRef, + float32_t * pOut, + float32_t * pErr, + uint32_t blockSize); + + /** + * @brief Initialization function for floating-point LMS filter. + * @param[in] *S points to an instance of the floating-point LMS filter structure. + * @param[in] numTaps number of filter coefficients. + * @param[in] *pCoeffs points to the coefficient buffer. + * @param[in] *pState points to state buffer. + * @param[in] mu step size that controls filter coefficient updates. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_lms_init_f32( + arm_lms_instance_f32 * S, + uint16_t numTaps, + float32_t * pCoeffs, + float32_t * pState, + float32_t mu, + uint32_t blockSize); + + /** + * @brief Instance structure for the Q15 LMS filter. + */ + + typedef struct + { + uint16_t numTaps; /**< number of coefficients in the filter. */ + q15_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + q15_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps. */ + q15_t mu; /**< step size that controls filter coefficient updates. */ + uint32_t postShift; /**< bit shift applied to coefficients. */ + } arm_lms_instance_q15; + + + /** + * @brief Initialization function for the Q15 LMS filter. + * @param[in] *S points to an instance of the Q15 LMS filter structure. + * @param[in] numTaps number of filter coefficients. + * @param[in] *pCoeffs points to the coefficient buffer. + * @param[in] *pState points to the state buffer. + * @param[in] mu step size that controls filter coefficient updates. + * @param[in] blockSize number of samples to process. + * @param[in] postShift bit shift applied to coefficients. + * @return none. + */ + + void arm_lms_init_q15( + arm_lms_instance_q15 * S, + uint16_t numTaps, + q15_t * pCoeffs, + q15_t * pState, + q15_t mu, + uint32_t blockSize, + uint32_t postShift); + + /** + * @brief Processing function for Q15 LMS filter. + * @param[in] *S points to an instance of the Q15 LMS filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[in] *pRef points to the block of reference data. + * @param[out] *pOut points to the block of output data. + * @param[out] *pErr points to the block of error data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_lms_q15( + const arm_lms_instance_q15 * S, + q15_t * pSrc, + q15_t * pRef, + q15_t * pOut, + q15_t * pErr, + uint32_t blockSize); + + + /** + * @brief Instance structure for the Q31 LMS filter. + */ + + typedef struct + { + uint16_t numTaps; /**< number of coefficients in the filter. */ + q31_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + q31_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps. */ + q31_t mu; /**< step size that controls filter coefficient updates. */ + uint32_t postShift; /**< bit shift applied to coefficients. */ + + } arm_lms_instance_q31; + + /** + * @brief Processing function for Q31 LMS filter. + * @param[in] *S points to an instance of the Q15 LMS filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[in] *pRef points to the block of reference data. + * @param[out] *pOut points to the block of output data. + * @param[out] *pErr points to the block of error data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_lms_q31( + const arm_lms_instance_q31 * S, + q31_t * pSrc, + q31_t * pRef, + q31_t * pOut, + q31_t * pErr, + uint32_t blockSize); + + /** + * @brief Initialization function for Q31 LMS filter. + * @param[in] *S points to an instance of the Q31 LMS filter structure. + * @param[in] numTaps number of filter coefficients. + * @param[in] *pCoeffs points to coefficient buffer. + * @param[in] *pState points to state buffer. + * @param[in] mu step size that controls filter coefficient updates. + * @param[in] blockSize number of samples to process. + * @param[in] postShift bit shift applied to coefficients. + * @return none. + */ + + void arm_lms_init_q31( + arm_lms_instance_q31 * S, + uint16_t numTaps, + q31_t *pCoeffs, + q31_t *pState, + q31_t mu, + uint32_t blockSize, + uint32_t postShift); + + /** + * @brief Instance structure for the floating-point normalized LMS filter. + */ + + typedef struct + { + uint16_t numTaps; /**< number of coefficients in the filter. */ + float32_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + float32_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps. */ + float32_t mu; /**< step size that control filter coefficient updates. */ + float32_t energy; /**< saves previous frame energy. */ + float32_t x0; /**< saves previous input sample. */ + } arm_lms_norm_instance_f32; + + /** + * @brief Processing function for floating-point normalized LMS filter. + * @param[in] *S points to an instance of the floating-point normalized LMS filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[in] *pRef points to the block of reference data. + * @param[out] *pOut points to the block of output data. + * @param[out] *pErr points to the block of error data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_lms_norm_f32( + arm_lms_norm_instance_f32 * S, + float32_t * pSrc, + float32_t * pRef, + float32_t * pOut, + float32_t * pErr, + uint32_t blockSize); + + /** + * @brief Initialization function for floating-point normalized LMS filter. + * @param[in] *S points to an instance of the floating-point LMS filter structure. + * @param[in] numTaps number of filter coefficients. + * @param[in] *pCoeffs points to coefficient buffer. + * @param[in] *pState points to state buffer. + * @param[in] mu step size that controls filter coefficient updates. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_lms_norm_init_f32( + arm_lms_norm_instance_f32 * S, + uint16_t numTaps, + float32_t * pCoeffs, + float32_t * pState, + float32_t mu, + uint32_t blockSize); + + + /** + * @brief Instance structure for the Q31 normalized LMS filter. + */ + typedef struct + { + uint16_t numTaps; /**< number of coefficients in the filter. */ + q31_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + q31_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps. */ + q31_t mu; /**< step size that controls filter coefficient updates. */ + uint8_t postShift; /**< bit shift applied to coefficients. */ + q31_t *recipTable; /**< points to the reciprocal initial value table. */ + q31_t energy; /**< saves previous frame energy. */ + q31_t x0; /**< saves previous input sample. */ + } arm_lms_norm_instance_q31; + + /** + * @brief Processing function for Q31 normalized LMS filter. + * @param[in] *S points to an instance of the Q31 normalized LMS filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[in] *pRef points to the block of reference data. + * @param[out] *pOut points to the block of output data. + * @param[out] *pErr points to the block of error data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_lms_norm_q31( + arm_lms_norm_instance_q31 * S, + q31_t * pSrc, + q31_t * pRef, + q31_t * pOut, + q31_t * pErr, + uint32_t blockSize); + + /** + * @brief Initialization function for Q31 normalized LMS filter. + * @param[in] *S points to an instance of the Q31 normalized LMS filter structure. + * @param[in] numTaps number of filter coefficients. + * @param[in] *pCoeffs points to coefficient buffer. + * @param[in] *pState points to state buffer. + * @param[in] mu step size that controls filter coefficient updates. + * @param[in] blockSize number of samples to process. + * @param[in] postShift bit shift applied to coefficients. + * @return none. + */ + + void arm_lms_norm_init_q31( + arm_lms_norm_instance_q31 * S, + uint16_t numTaps, + q31_t * pCoeffs, + q31_t * pState, + q31_t mu, + uint32_t blockSize, + uint8_t postShift); + + /** + * @brief Instance structure for the Q15 normalized LMS filter. + */ + + typedef struct + { + uint16_t numTaps; /**< Number of coefficients in the filter. */ + q15_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + q15_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps. */ + q15_t mu; /**< step size that controls filter coefficient updates. */ + uint8_t postShift; /**< bit shift applied to coefficients. */ + q15_t *recipTable; /**< Points to the reciprocal initial value table. */ + q15_t energy; /**< saves previous frame energy. */ + q15_t x0; /**< saves previous input sample. */ + } arm_lms_norm_instance_q15; + + /** + * @brief Processing function for Q15 normalized LMS filter. + * @param[in] *S points to an instance of the Q15 normalized LMS filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[in] *pRef points to the block of reference data. + * @param[out] *pOut points to the block of output data. + * @param[out] *pErr points to the block of error data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_lms_norm_q15( + arm_lms_norm_instance_q15 * S, + q15_t * pSrc, + q15_t * pRef, + q15_t * pOut, + q15_t * pErr, + uint32_t blockSize); + + + /** + * @brief Initialization function for Q15 normalized LMS filter. + * @param[in] *S points to an instance of the Q15 normalized LMS filter structure. + * @param[in] numTaps number of filter coefficients. + * @param[in] *pCoeffs points to coefficient buffer. + * @param[in] *pState points to state buffer. + * @param[in] mu step size that controls filter coefficient updates. + * @param[in] blockSize number of samples to process. + * @param[in] postShift bit shift applied to coefficients. + * @return none. + */ + + void arm_lms_norm_init_q15( + arm_lms_norm_instance_q15 * S, + uint16_t numTaps, + q15_t * pCoeffs, + q15_t * pState, + q15_t mu, + uint32_t blockSize, + uint8_t postShift); + + /** + * @brief Correlation of floating-point sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length 2 * max(srcALen, srcBLen) - 1. + * @return none. + */ + + void arm_correlate_f32( + float32_t * pSrcA, + uint32_t srcALen, + float32_t * pSrcB, + uint32_t srcBLen, + float32_t * pDst); + + /** + * @brief Correlation of Q15 sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length 2 * max(srcALen, srcBLen) - 1. + * @return none. + */ + + void arm_correlate_q15( + q15_t * pSrcA, + uint32_t srcALen, + q15_t * pSrcB, + uint32_t srcBLen, + q15_t * pDst); + + /** + * @brief Correlation of Q15 sequences (fast version) for Cortex-M3 and Cortex-M4. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length 2 * max(srcALen, srcBLen) - 1. + * @return none. + */ + + void arm_correlate_fast_q15( + q15_t * pSrcA, + uint32_t srcALen, + q15_t * pSrcB, + uint32_t srcBLen, + q15_t * pDst); + + /** + * @brief Correlation of Q31 sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length 2 * max(srcALen, srcBLen) - 1. + * @return none. + */ + + void arm_correlate_q31( + q31_t * pSrcA, + uint32_t srcALen, + q31_t * pSrcB, + uint32_t srcBLen, + q31_t * pDst); + + /** + * @brief Correlation of Q31 sequences (fast version) for Cortex-M3 and Cortex-M4 + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length 2 * max(srcALen, srcBLen) - 1. + * @return none. + */ + + void arm_correlate_fast_q31( + q31_t * pSrcA, + uint32_t srcALen, + q31_t * pSrcB, + uint32_t srcBLen, + q31_t * pDst); + + /** + * @brief Correlation of Q7 sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length 2 * max(srcALen, srcBLen) - 1. + * @return none. + */ + + void arm_correlate_q7( + q7_t * pSrcA, + uint32_t srcALen, + q7_t * pSrcB, + uint32_t srcBLen, + q7_t * pDst); + + /** + * @brief Instance structure for the floating-point sparse FIR filter. + */ + typedef struct + { + uint16_t numTaps; /**< number of coefficients in the filter. */ + uint16_t stateIndex; /**< state buffer index. Points to the oldest sample in the state buffer. */ + float32_t *pState; /**< points to the state buffer array. The array is of length maxDelay+blockSize-1. */ + float32_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps.*/ + uint16_t maxDelay; /**< maximum offset specified by the pTapDelay array. */ + int32_t *pTapDelay; /**< points to the array of delay values. The array is of length numTaps. */ + } arm_fir_sparse_instance_f32; + + /** + * @brief Instance structure for the Q31 sparse FIR filter. + */ + + typedef struct + { + uint16_t numTaps; /**< number of coefficients in the filter. */ + uint16_t stateIndex; /**< state buffer index. Points to the oldest sample in the state buffer. */ + q31_t *pState; /**< points to the state buffer array. The array is of length maxDelay+blockSize-1. */ + q31_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps.*/ + uint16_t maxDelay; /**< maximum offset specified by the pTapDelay array. */ + int32_t *pTapDelay; /**< points to the array of delay values. The array is of length numTaps. */ + } arm_fir_sparse_instance_q31; + + /** + * @brief Instance structure for the Q15 sparse FIR filter. + */ + + typedef struct + { + uint16_t numTaps; /**< number of coefficients in the filter. */ + uint16_t stateIndex; /**< state buffer index. Points to the oldest sample in the state buffer. */ + q15_t *pState; /**< points to the state buffer array. The array is of length maxDelay+blockSize-1. */ + q15_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps.*/ + uint16_t maxDelay; /**< maximum offset specified by the pTapDelay array. */ + int32_t *pTapDelay; /**< points to the array of delay values. The array is of length numTaps. */ + } arm_fir_sparse_instance_q15; + + /** + * @brief Instance structure for the Q7 sparse FIR filter. + */ + + typedef struct + { + uint16_t numTaps; /**< number of coefficients in the filter. */ + uint16_t stateIndex; /**< state buffer index. Points to the oldest sample in the state buffer. */ + q7_t *pState; /**< points to the state buffer array. The array is of length maxDelay+blockSize-1. */ + q7_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps.*/ + uint16_t maxDelay; /**< maximum offset specified by the pTapDelay array. */ + int32_t *pTapDelay; /**< points to the array of delay values. The array is of length numTaps. */ + } arm_fir_sparse_instance_q7; + + /** + * @brief Processing function for the floating-point sparse FIR filter. + * @param[in] *S points to an instance of the floating-point sparse FIR structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] *pScratchIn points to a temporary buffer of size blockSize. + * @param[in] blockSize number of input samples to process per call. + * @return none. + */ + + void arm_fir_sparse_f32( + arm_fir_sparse_instance_f32 * S, + float32_t * pSrc, + float32_t * pDst, + float32_t * pScratchIn, + uint32_t blockSize); + + /** + * @brief Initialization function for the floating-point sparse FIR filter. + * @param[in,out] *S points to an instance of the floating-point sparse FIR structure. + * @param[in] numTaps number of nonzero coefficients in the filter. + * @param[in] *pCoeffs points to the array of filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] *pTapDelay points to the array of offset times. + * @param[in] maxDelay maximum offset time supported. + * @param[in] blockSize number of samples that will be processed per block. + * @return none + */ + + void arm_fir_sparse_init_f32( + arm_fir_sparse_instance_f32 * S, + uint16_t numTaps, + float32_t * pCoeffs, + float32_t * pState, + int32_t * pTapDelay, + uint16_t maxDelay, + uint32_t blockSize); + + /** + * @brief Processing function for the Q31 sparse FIR filter. + * @param[in] *S points to an instance of the Q31 sparse FIR structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] *pScratchIn points to a temporary buffer of size blockSize. + * @param[in] blockSize number of input samples to process per call. + * @return none. + */ + + void arm_fir_sparse_q31( + arm_fir_sparse_instance_q31 * S, + q31_t * pSrc, + q31_t * pDst, + q31_t * pScratchIn, + uint32_t blockSize); + + /** + * @brief Initialization function for the Q31 sparse FIR filter. + * @param[in,out] *S points to an instance of the Q31 sparse FIR structure. + * @param[in] numTaps number of nonzero coefficients in the filter. + * @param[in] *pCoeffs points to the array of filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] *pTapDelay points to the array of offset times. + * @param[in] maxDelay maximum offset time supported. + * @param[in] blockSize number of samples that will be processed per block. + * @return none + */ + + void arm_fir_sparse_init_q31( + arm_fir_sparse_instance_q31 * S, + uint16_t numTaps, + q31_t * pCoeffs, + q31_t * pState, + int32_t * pTapDelay, + uint16_t maxDelay, + uint32_t blockSize); + + /** + * @brief Processing function for the Q15 sparse FIR filter. + * @param[in] *S points to an instance of the Q15 sparse FIR structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] *pScratchIn points to a temporary buffer of size blockSize. + * @param[in] *pScratchOut points to a temporary buffer of size blockSize. + * @param[in] blockSize number of input samples to process per call. + * @return none. + */ + + void arm_fir_sparse_q15( + arm_fir_sparse_instance_q15 * S, + q15_t * pSrc, + q15_t * pDst, + q15_t * pScratchIn, + q31_t * pScratchOut, + uint32_t blockSize); + + + /** + * @brief Initialization function for the Q15 sparse FIR filter. + * @param[in,out] *S points to an instance of the Q15 sparse FIR structure. + * @param[in] numTaps number of nonzero coefficients in the filter. + * @param[in] *pCoeffs points to the array of filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] *pTapDelay points to the array of offset times. + * @param[in] maxDelay maximum offset time supported. + * @param[in] blockSize number of samples that will be processed per block. + * @return none + */ + + void arm_fir_sparse_init_q15( + arm_fir_sparse_instance_q15 * S, + uint16_t numTaps, + q15_t * pCoeffs, + q15_t * pState, + int32_t * pTapDelay, + uint16_t maxDelay, + uint32_t blockSize); + + /** + * @brief Processing function for the Q7 sparse FIR filter. + * @param[in] *S points to an instance of the Q7 sparse FIR structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] *pScratchIn points to a temporary buffer of size blockSize. + * @param[in] *pScratchOut points to a temporary buffer of size blockSize. + * @param[in] blockSize number of input samples to process per call. + * @return none. + */ + + void arm_fir_sparse_q7( + arm_fir_sparse_instance_q7 * S, + q7_t * pSrc, + q7_t * pDst, + q7_t * pScratchIn, + q31_t * pScratchOut, + uint32_t blockSize); + + /** + * @brief Initialization function for the Q7 sparse FIR filter. + * @param[in,out] *S points to an instance of the Q7 sparse FIR structure. + * @param[in] numTaps number of nonzero coefficients in the filter. + * @param[in] *pCoeffs points to the array of filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] *pTapDelay points to the array of offset times. + * @param[in] maxDelay maximum offset time supported. + * @param[in] blockSize number of samples that will be processed per block. + * @return none + */ + + void arm_fir_sparse_init_q7( + arm_fir_sparse_instance_q7 * S, + uint16_t numTaps, + q7_t * pCoeffs, + q7_t * pState, + int32_t *pTapDelay, + uint16_t maxDelay, + uint32_t blockSize); + + + /* + * @brief Floating-point sin_cos function. + * @param[in] theta input value in degrees + * @param[out] *pSinVal points to the processed sine output. + * @param[out] *pCosVal points to the processed cos output. + * @return none. + */ + + void arm_sin_cos_f32( + float32_t theta, + float32_t *pSinVal, + float32_t *pCcosVal); + + /* + * @brief Q31 sin_cos function. + * @param[in] theta scaled input value in degrees + * @param[out] *pSinVal points to the processed sine output. + * @param[out] *pCosVal points to the processed cosine output. + * @return none. + */ + + void arm_sin_cos_q31( + q31_t theta, + q31_t *pSinVal, + q31_t *pCosVal); + + + /** + * @brief Floating-point complex conjugate. + * @param[in] *pSrc points to the input vector + * @param[out] *pDst points to the output vector + * @param[in] numSamples number of complex samples in each vector + * @return none. + */ + + void arm_cmplx_conj_f32( + float32_t * pSrc, + float32_t * pDst, + uint32_t numSamples); + + /** + * @brief Q31 complex conjugate. + * @param[in] *pSrc points to the input vector + * @param[out] *pDst points to the output vector + * @param[in] numSamples number of complex samples in each vector + * @return none. + */ + + void arm_cmplx_conj_q31( + q31_t * pSrc, + q31_t * pDst, + uint32_t numSamples); + + /** + * @brief Q15 complex conjugate. + * @param[in] *pSrc points to the input vector + * @param[out] *pDst points to the output vector + * @param[in] numSamples number of complex samples in each vector + * @return none. + */ + + void arm_cmplx_conj_q15( + q15_t * pSrc, + q15_t * pDst, + uint32_t numSamples); + + + + /** + * @brief Floating-point complex magnitude squared + * @param[in] *pSrc points to the complex input vector + * @param[out] *pDst points to the real output vector + * @param[in] numSamples number of complex samples in the input vector + * @return none. + */ + + void arm_cmplx_mag_squared_f32( + float32_t * pSrc, + float32_t * pDst, + uint32_t numSamples); + + /** + * @brief Q31 complex magnitude squared + * @param[in] *pSrc points to the complex input vector + * @param[out] *pDst points to the real output vector + * @param[in] numSamples number of complex samples in the input vector + * @return none. + */ + + void arm_cmplx_mag_squared_q31( + q31_t * pSrc, + q31_t * pDst, + uint32_t numSamples); + + /** + * @brief Q15 complex magnitude squared + * @param[in] *pSrc points to the complex input vector + * @param[out] *pDst points to the real output vector + * @param[in] numSamples number of complex samples in the input vector + * @return none. + */ + + void arm_cmplx_mag_squared_q15( + q15_t * pSrc, + q15_t * pDst, + uint32_t numSamples); + + + /** + * @ingroup groupController + */ + + /** + * @defgroup PID PID Motor Control + * + * A Proportional Integral Derivative (PID) controller is a generic feedback control + * loop mechanism widely used in industrial control systems. + * A PID controller is the most commonly used type of feedback controller. + * + * This set of functions implements (PID) controllers + * for Q15, Q31, and floating-point data types. The functions operate on a single sample + * of data and each call to the function returns a single processed value. + * S points to an instance of the PID control data structure. in + * is the input sample value. The functions return the output value. + * + * \par Algorithm: + *
+   *    y[n] = y[n-1] + A0 * x[n] + A1 * x[n-1] + A2 * x[n-2]
+   *    A0 = Kp + Ki + Kd
+   *    A1 = (-Kp ) - (2 * Kd )
+   *    A2 = Kd  
+ * + * \par + * where \c Kp is proportional constant, \c Ki is Integral constant and \c Kd is Derivative constant + * + * \par + * \image html PID.gif "Proportional Integral Derivative Controller" + * + * \par + * The PID controller calculates an "error" value as the difference between + * the measured output and the reference input. + * The controller attempts to minimize the error by adjusting the process control inputs. + * The proportional value determines the reaction to the current error, + * the integral value determines the reaction based on the sum of recent errors, + * and the derivative value determines the reaction based on the rate at which the error has been changing. + * + * \par Instance Structure + * The Gains A0, A1, A2 and state variables for a PID controller are stored together in an instance data structure. + * A separate instance structure must be defined for each PID Controller. + * There are separate instance structure declarations for each of the 3 supported data types. + * + * \par Reset Functions + * There is also an associated reset function for each data type which clears the state array. + * + * \par Initialization Functions + * There is also an associated initialization function for each data type. + * The initialization function performs the following operations: + * - Initializes the Gains A0, A1, A2 from Kp,Ki, Kd gains. + * - Zeros out the values in the state buffer. + * + * \par + * Instance structure cannot be placed into a const data section and it is recommended to use the initialization function. + * + * \par Fixed-Point Behavior + * Care must be taken when using the fixed-point versions of the PID Controller functions. + * In particular, the overflow and saturation behavior of the accumulator used in each function must be considered. + * Refer to the function specific documentation below for usage guidelines. + */ + + /** + * @addtogroup PID + * @{ + */ + + /** + * @brief Process function for the floating-point PID Control. + * @param[in,out] *S is an instance of the floating-point PID Control structure + * @param[in] in input sample to process + * @return out processed output sample. + */ + + + __STATIC_INLINE float32_t arm_pid_f32( + arm_pid_instance_f32 * S, + float32_t in) + { + float32_t out; + + /* y[n] = y[n-1] + A0 * x[n] + A1 * x[n-1] + A2 * x[n-2] */ + out = (S->A0 * in) + + (S->A1 * S->state[0]) + (S->A2 * S->state[1]) + (S->state[2]); + + /* Update state */ + S->state[1] = S->state[0]; + S->state[0] = in; + S->state[2] = out; + + /* return to application */ + return (out); + + } + + /** + * @brief Process function for the Q31 PID Control. + * @param[in,out] *S points to an instance of the Q31 PID Control structure + * @param[in] in input sample to process + * @return out processed output sample. + * + * Scaling and Overflow Behavior: + * \par + * The function is implemented using an internal 64-bit accumulator. + * The accumulator has a 2.62 format and maintains full precision of the intermediate multiplication results but provides only a single guard bit. + * Thus, if the accumulator result overflows it wraps around rather than clip. + * In order to avoid overflows completely the input signal must be scaled down by 2 bits as there are four additions. + * After all multiply-accumulates are performed, the 2.62 accumulator is truncated to 1.32 format and then saturated to 1.31 format. + */ + + __STATIC_INLINE q31_t arm_pid_q31( + arm_pid_instance_q31 * S, + q31_t in) + { + q63_t acc; + q31_t out; + + /* acc = A0 * x[n] */ + acc = (q63_t) S->A0 * in; + + /* acc += A1 * x[n-1] */ + acc += (q63_t) S->A1 * S->state[0]; + + /* acc += A2 * x[n-2] */ + acc += (q63_t) S->A2 * S->state[1]; + + /* convert output to 1.31 format to add y[n-1] */ + out = (q31_t) (acc >> 31u); + + /* out += y[n-1] */ + out += S->state[2]; + + /* Update state */ + S->state[1] = S->state[0]; + S->state[0] = in; + S->state[2] = out; + + /* return to application */ + return (out); + + } + + /** + * @brief Process function for the Q15 PID Control. + * @param[in,out] *S points to an instance of the Q15 PID Control structure + * @param[in] in input sample to process + * @return out processed output sample. + * + * Scaling and Overflow Behavior: + * \par + * The function is implemented using a 64-bit internal accumulator. + * Both Gains and state variables are represented in 1.15 format and multiplications yield a 2.30 result. + * The 2.30 intermediate results are accumulated in a 64-bit accumulator in 34.30 format. + * There is no risk of internal overflow with this approach and the full precision of intermediate multiplications is preserved. + * After all additions have been performed, the accumulator is truncated to 34.15 format by discarding low 15 bits. + * Lastly, the accumulator is saturated to yield a result in 1.15 format. + */ + + __STATIC_INLINE q15_t arm_pid_q15( + arm_pid_instance_q15 * S, + q15_t in) + { + q63_t acc; + q15_t out; + + /* Implementation of PID controller */ + + #ifdef ARM_MATH_CM0 + + /* acc = A0 * x[n] */ + acc = ((q31_t) S->A0 )* in ; + + #else + + /* acc = A0 * x[n] */ + acc = (q31_t) __SMUAD(S->A0, in); + + #endif + + #ifdef ARM_MATH_CM0 + + /* acc += A1 * x[n-1] + A2 * x[n-2] */ + acc += (q31_t) S->A1 * S->state[0] ; + acc += (q31_t) S->A2 * S->state[1] ; + + #else + + /* acc += A1 * x[n-1] + A2 * x[n-2] */ + acc = __SMLALD(S->A1, (q31_t)__SIMD32(S->state), acc); + + #endif + + /* acc += y[n-1] */ + acc += (q31_t) S->state[2] << 15; + + /* saturate the output */ + out = (q15_t) (__SSAT((acc >> 15), 16)); + + /* Update state */ + S->state[1] = S->state[0]; + S->state[0] = in; + S->state[2] = out; + + /* return to application */ + return (out); + + } + + /** + * @} end of PID group + */ + + + /** + * @brief Floating-point matrix inverse. + * @param[in] *src points to the instance of the input floating-point matrix structure. + * @param[out] *dst points to the instance of the output floating-point matrix structure. + * @return The function returns ARM_MATH_SIZE_MISMATCH, if the dimensions do not match. + * If the input matrix is singular (does not have an inverse), then the algorithm terminates and returns error status ARM_MATH_SINGULAR. + */ + + arm_status arm_mat_inverse_f32( + const arm_matrix_instance_f32 * src, + arm_matrix_instance_f32 * dst); + + + + /** + * @ingroup groupController + */ + + + /** + * @defgroup clarke Vector Clarke Transform + * Forward Clarke transform converts the instantaneous stator phases into a two-coordinate time invariant vector. + * Generally the Clarke transform uses three-phase currents Ia, Ib and Ic to calculate currents + * in the two-phase orthogonal stator axis Ialpha and Ibeta. + * When Ialpha is superposed with Ia as shown in the figure below + * \image html clarke.gif Stator current space vector and its components in (a,b). + * and Ia + Ib + Ic = 0, in this condition Ialpha and Ibeta + * can be calculated using only Ia and Ib. + * + * The function operates on a single sample of data and each call to the function returns the processed output. + * The library provides separate functions for Q31 and floating-point data types. + * \par Algorithm + * \image html clarkeFormula.gif + * where Ia and Ib are the instantaneous stator phases and + * pIalpha and pIbeta are the two coordinates of time invariant vector. + * \par Fixed-Point Behavior + * Care must be taken when using the Q31 version of the Clarke transform. + * In particular, the overflow and saturation behavior of the accumulator used must be considered. + * Refer to the function specific documentation below for usage guidelines. + */ + + /** + * @addtogroup clarke + * @{ + */ + + /** + * + * @brief Floating-point Clarke transform + * @param[in] Ia input three-phase coordinate a + * @param[in] Ib input three-phase coordinate b + * @param[out] *pIalpha points to output two-phase orthogonal vector axis alpha + * @param[out] *pIbeta points to output two-phase orthogonal vector axis beta + * @return none. + */ + + __STATIC_INLINE void arm_clarke_f32( + float32_t Ia, + float32_t Ib, + float32_t * pIalpha, + float32_t * pIbeta) + { + /* Calculate pIalpha using the equation, pIalpha = Ia */ + *pIalpha = Ia; + + /* Calculate pIbeta using the equation, pIbeta = (1/sqrt(3)) * Ia + (2/sqrt(3)) * Ib */ + *pIbeta = ((float32_t) 0.57735026919 * Ia + (float32_t) 1.15470053838 * Ib); + + } + + /** + * @brief Clarke transform for Q31 version + * @param[in] Ia input three-phase coordinate a + * @param[in] Ib input three-phase coordinate b + * @param[out] *pIalpha points to output two-phase orthogonal vector axis alpha + * @param[out] *pIbeta points to output two-phase orthogonal vector axis beta + * @return none. + * + * Scaling and Overflow Behavior: + * \par + * The function is implemented using an internal 32-bit accumulator. + * The accumulator maintains 1.31 format by truncating lower 31 bits of the intermediate multiplication in 2.62 format. + * There is saturation on the addition, hence there is no risk of overflow. + */ + + __STATIC_INLINE void arm_clarke_q31( + q31_t Ia, + q31_t Ib, + q31_t * pIalpha, + q31_t * pIbeta) + { + q31_t product1, product2; /* Temporary variables used to store intermediate results */ + + /* Calculating pIalpha from Ia by equation pIalpha = Ia */ + *pIalpha = Ia; + + /* Intermediate product is calculated by (1/(sqrt(3)) * Ia) */ + product1 = (q31_t) (((q63_t) Ia * 0x24F34E8B) >> 30); + + /* Intermediate product is calculated by (2/sqrt(3) * Ib) */ + product2 = (q31_t) (((q63_t) Ib * 0x49E69D16) >> 30); + + /* pIbeta is calculated by adding the intermediate products */ + *pIbeta = __QADD(product1, product2); + } + + /** + * @} end of clarke group + */ + + /** + * @brief Converts the elements of the Q7 vector to Q31 vector. + * @param[in] *pSrc input pointer + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_q7_to_q31( + q7_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + + + + /** + * @ingroup groupController + */ + + /** + * @defgroup inv_clarke Vector Inverse Clarke Transform + * Inverse Clarke transform converts the two-coordinate time invariant vector into instantaneous stator phases. + * + * The function operates on a single sample of data and each call to the function returns the processed output. + * The library provides separate functions for Q31 and floating-point data types. + * \par Algorithm + * \image html clarkeInvFormula.gif + * where pIa and pIb are the instantaneous stator phases and + * Ialpha and Ibeta are the two coordinates of time invariant vector. + * \par Fixed-Point Behavior + * Care must be taken when using the Q31 version of the Clarke transform. + * In particular, the overflow and saturation behavior of the accumulator used must be considered. + * Refer to the function specific documentation below for usage guidelines. + */ + + /** + * @addtogroup inv_clarke + * @{ + */ + + /** + * @brief Floating-point Inverse Clarke transform + * @param[in] Ialpha input two-phase orthogonal vector axis alpha + * @param[in] Ibeta input two-phase orthogonal vector axis beta + * @param[out] *pIa points to output three-phase coordinate a + * @param[out] *pIb points to output three-phase coordinate b + * @return none. + */ + + + __STATIC_INLINE void arm_inv_clarke_f32( + float32_t Ialpha, + float32_t Ibeta, + float32_t * pIa, + float32_t * pIb) + { + /* Calculating pIa from Ialpha by equation pIa = Ialpha */ + *pIa = Ialpha; + + /* Calculating pIb from Ialpha and Ibeta by equation pIb = -(1/2) * Ialpha + (sqrt(3)/2) * Ibeta */ + *pIb = -0.5 * Ialpha + (float32_t) 0.8660254039 *Ibeta; + + } + + /** + * @brief Inverse Clarke transform for Q31 version + * @param[in] Ialpha input two-phase orthogonal vector axis alpha + * @param[in] Ibeta input two-phase orthogonal vector axis beta + * @param[out] *pIa points to output three-phase coordinate a + * @param[out] *pIb points to output three-phase coordinate b + * @return none. + * + * Scaling and Overflow Behavior: + * \par + * The function is implemented using an internal 32-bit accumulator. + * The accumulator maintains 1.31 format by truncating lower 31 bits of the intermediate multiplication in 2.62 format. + * There is saturation on the subtraction, hence there is no risk of overflow. + */ + + __STATIC_INLINE void arm_inv_clarke_q31( + q31_t Ialpha, + q31_t Ibeta, + q31_t * pIa, + q31_t * pIb) + { + q31_t product1, product2; /* Temporary variables used to store intermediate results */ + + /* Calculating pIa from Ialpha by equation pIa = Ialpha */ + *pIa = Ialpha; + + /* Intermediate product is calculated by (1/(2*sqrt(3)) * Ia) */ + product1 = (q31_t) (((q63_t) (Ialpha) * (0x40000000)) >> 31); + + /* Intermediate product is calculated by (1/sqrt(3) * pIb) */ + product2 = (q31_t) (((q63_t) (Ibeta) * (0x6ED9EBA1)) >> 31); + + /* pIb is calculated by subtracting the products */ + *pIb = __QSUB(product2, product1); + + } + + /** + * @} end of inv_clarke group + */ + + /** + * @brief Converts the elements of the Q7 vector to Q15 vector. + * @param[in] *pSrc input pointer + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_q7_to_q15( + q7_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + + + /** + * @ingroup groupController + */ + + /** + * @defgroup park Vector Park Transform + * + * Forward Park transform converts the input two-coordinate vector to flux and torque components. + * The Park transform can be used to realize the transformation of the Ialpha and the Ibeta currents + * from the stationary to the moving reference frame and control the spatial relationship between + * the stator vector current and rotor flux vector. + * If we consider the d axis aligned with the rotor flux, the diagram below shows the + * current vector and the relationship from the two reference frames: + * \image html park.gif "Stator current space vector and its component in (a,b) and in the d,q rotating reference frame" + * + * The function operates on a single sample of data and each call to the function returns the processed output. + * The library provides separate functions for Q31 and floating-point data types. + * \par Algorithm + * \image html parkFormula.gif + * where Ialpha and Ibeta are the stator vector components, + * pId and pIq are rotor vector components and cosVal and sinVal are the + * cosine and sine values of theta (rotor flux position). + * \par Fixed-Point Behavior + * Care must be taken when using the Q31 version of the Park transform. + * In particular, the overflow and saturation behavior of the accumulator used must be considered. + * Refer to the function specific documentation below for usage guidelines. + */ + + /** + * @addtogroup park + * @{ + */ + + /** + * @brief Floating-point Park transform + * @param[in] Ialpha input two-phase vector coordinate alpha + * @param[in] Ibeta input two-phase vector coordinate beta + * @param[out] *pId points to output rotor reference frame d + * @param[out] *pIq points to output rotor reference frame q + * @param[in] sinVal sine value of rotation angle theta + * @param[in] cosVal cosine value of rotation angle theta + * @return none. + * + * The function implements the forward Park transform. + * + */ + + __STATIC_INLINE void arm_park_f32( + float32_t Ialpha, + float32_t Ibeta, + float32_t * pId, + float32_t * pIq, + float32_t sinVal, + float32_t cosVal) + { + /* Calculate pId using the equation, pId = Ialpha * cosVal + Ibeta * sinVal */ + *pId = Ialpha * cosVal + Ibeta * sinVal; + + /* Calculate pIq using the equation, pIq = - Ialpha * sinVal + Ibeta * cosVal */ + *pIq = -Ialpha * sinVal + Ibeta * cosVal; + + } + + /** + * @brief Park transform for Q31 version + * @param[in] Ialpha input two-phase vector coordinate alpha + * @param[in] Ibeta input two-phase vector coordinate beta + * @param[out] *pId points to output rotor reference frame d + * @param[out] *pIq points to output rotor reference frame q + * @param[in] sinVal sine value of rotation angle theta + * @param[in] cosVal cosine value of rotation angle theta + * @return none. + * + * Scaling and Overflow Behavior: + * \par + * The function is implemented using an internal 32-bit accumulator. + * The accumulator maintains 1.31 format by truncating lower 31 bits of the intermediate multiplication in 2.62 format. + * There is saturation on the addition and subtraction, hence there is no risk of overflow. + */ + + + __STATIC_INLINE void arm_park_q31( + q31_t Ialpha, + q31_t Ibeta, + q31_t * pId, + q31_t * pIq, + q31_t sinVal, + q31_t cosVal) + { + q31_t product1, product2; /* Temporary variables used to store intermediate results */ + q31_t product3, product4; /* Temporary variables used to store intermediate results */ + + /* Intermediate product is calculated by (Ialpha * cosVal) */ + product1 = (q31_t) (((q63_t) (Ialpha) * (cosVal)) >> 31); + + /* Intermediate product is calculated by (Ibeta * sinVal) */ + product2 = (q31_t) (((q63_t) (Ibeta) * (sinVal)) >> 31); + + + /* Intermediate product is calculated by (Ialpha * sinVal) */ + product3 = (q31_t) (((q63_t) (Ialpha) * (sinVal)) >> 31); + + /* Intermediate product is calculated by (Ibeta * cosVal) */ + product4 = (q31_t) (((q63_t) (Ibeta) * (cosVal)) >> 31); + + /* Calculate pId by adding the two intermediate products 1 and 2 */ + *pId = __QADD(product1, product2); + + /* Calculate pIq by subtracting the two intermediate products 3 from 4 */ + *pIq = __QSUB(product4, product3); + } + + /** + * @} end of park group + */ + + /** + * @brief Converts the elements of the Q7 vector to floating-point vector. + * @param[in] *pSrc is input pointer + * @param[out] *pDst is output pointer + * @param[in] blockSize is the number of samples to process + * @return none. + */ + void arm_q7_to_float( + q7_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + + /** + * @ingroup groupController + */ + + /** + * @defgroup inv_park Vector Inverse Park transform + * Inverse Park transform converts the input flux and torque components to two-coordinate vector. + * + * The function operates on a single sample of data and each call to the function returns the processed output. + * The library provides separate functions for Q31 and floating-point data types. + * \par Algorithm + * \image html parkInvFormula.gif + * where pIalpha and pIbeta are the stator vector components, + * Id and Iq are rotor vector components and cosVal and sinVal are the + * cosine and sine values of theta (rotor flux position). + * \par Fixed-Point Behavior + * Care must be taken when using the Q31 version of the Park transform. + * In particular, the overflow and saturation behavior of the accumulator used must be considered. + * Refer to the function specific documentation below for usage guidelines. + */ + + /** + * @addtogroup inv_park + * @{ + */ + + /** + * @brief Floating-point Inverse Park transform + * @param[in] Id input coordinate of rotor reference frame d + * @param[in] Iq input coordinate of rotor reference frame q + * @param[out] *pIalpha points to output two-phase orthogonal vector axis alpha + * @param[out] *pIbeta points to output two-phase orthogonal vector axis beta + * @param[in] sinVal sine value of rotation angle theta + * @param[in] cosVal cosine value of rotation angle theta + * @return none. + */ + + __STATIC_INLINE void arm_inv_park_f32( + float32_t Id, + float32_t Iq, + float32_t * pIalpha, + float32_t * pIbeta, + float32_t sinVal, + float32_t cosVal) + { + /* Calculate pIalpha using the equation, pIalpha = Id * cosVal - Iq * sinVal */ + *pIalpha = Id * cosVal - Iq * sinVal; + + /* Calculate pIbeta using the equation, pIbeta = Id * sinVal + Iq * cosVal */ + *pIbeta = Id * sinVal + Iq * cosVal; + + } + + + /** + * @brief Inverse Park transform for Q31 version + * @param[in] Id input coordinate of rotor reference frame d + * @param[in] Iq input coordinate of rotor reference frame q + * @param[out] *pIalpha points to output two-phase orthogonal vector axis alpha + * @param[out] *pIbeta points to output two-phase orthogonal vector axis beta + * @param[in] sinVal sine value of rotation angle theta + * @param[in] cosVal cosine value of rotation angle theta + * @return none. + * + * Scaling and Overflow Behavior: + * \par + * The function is implemented using an internal 32-bit accumulator. + * The accumulator maintains 1.31 format by truncating lower 31 bits of the intermediate multiplication in 2.62 format. + * There is saturation on the addition, hence there is no risk of overflow. + */ + + + __STATIC_INLINE void arm_inv_park_q31( + q31_t Id, + q31_t Iq, + q31_t * pIalpha, + q31_t * pIbeta, + q31_t sinVal, + q31_t cosVal) + { + q31_t product1, product2; /* Temporary variables used to store intermediate results */ + q31_t product3, product4; /* Temporary variables used to store intermediate results */ + + /* Intermediate product is calculated by (Id * cosVal) */ + product1 = (q31_t) (((q63_t) (Id) * (cosVal)) >> 31); + + /* Intermediate product is calculated by (Iq * sinVal) */ + product2 = (q31_t) (((q63_t) (Iq) * (sinVal)) >> 31); + + + /* Intermediate product is calculated by (Id * sinVal) */ + product3 = (q31_t) (((q63_t) (Id) * (sinVal)) >> 31); + + /* Intermediate product is calculated by (Iq * cosVal) */ + product4 = (q31_t) (((q63_t) (Iq) * (cosVal)) >> 31); + + /* Calculate pIalpha by using the two intermediate products 1 and 2 */ + *pIalpha = __QSUB(product1, product2); + + /* Calculate pIbeta by using the two intermediate products 3 and 4 */ + *pIbeta = __QADD(product4, product3); + + } + + /** + * @} end of Inverse park group + */ + + + /** + * @brief Converts the elements of the Q31 vector to floating-point vector. + * @param[in] *pSrc is input pointer + * @param[out] *pDst is output pointer + * @param[in] blockSize is the number of samples to process + * @return none. + */ + void arm_q31_to_float( + q31_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + /** + * @ingroup groupInterpolation + */ + + /** + * @defgroup LinearInterpolate Linear Interpolation + * + * Linear interpolation is a method of curve fitting using linear polynomials. + * Linear interpolation works by effectively drawing a straight line between two neighboring samples and returning the appropriate point along that line + * + * \par + * \image html LinearInterp.gif "Linear interpolation" + * + * \par + * A Linear Interpolate function calculates an output value(y), for the input(x) + * using linear interpolation of the input values x0, x1( nearest input values) and the output values y0 and y1(nearest output values) + * + * \par Algorithm: + *
+   *       y = y0 + (x - x0) * ((y1 - y0)/(x1-x0))
+   *       where x0, x1 are nearest values of input x
+   *             y0, y1 are nearest values to output y
+   * 
+ * + * \par + * This set of functions implements Linear interpolation process + * for Q7, Q15, Q31, and floating-point data types. The functions operate on a single + * sample of data and each call to the function returns a single processed value. + * S points to an instance of the Linear Interpolate function data structure. + * x is the input sample value. The functions returns the output value. + * + * \par + * if x is outside of the table boundary, Linear interpolation returns first value of the table + * if x is below input range and returns last value of table if x is above range. + */ + + /** + * @addtogroup LinearInterpolate + * @{ + */ + + /** + * @brief Process function for the floating-point Linear Interpolation Function. + * @param[in,out] *S is an instance of the floating-point Linear Interpolation structure + * @param[in] x input sample to process + * @return y processed output sample. + * + */ + + __STATIC_INLINE float32_t arm_linear_interp_f32( + arm_linear_interp_instance_f32 * S, + float32_t x) + { + + float32_t y; + float32_t x0, x1; /* Nearest input values */ + float32_t y0, y1; /* Nearest output values */ + float32_t xSpacing = S->xSpacing; /* spacing between input values */ + int32_t i; /* Index variable */ + float32_t *pYData = S->pYData; /* pointer to output table */ + + /* Calculation of index */ + i = (x - S->x1) / xSpacing; + + if(i < 0) + { + /* Iniatilize output for below specified range as least output value of table */ + y = pYData[0]; + } + else if(i >= S->nValues) + { + /* Iniatilize output for above specified range as last output value of table */ + y = pYData[S->nValues-1]; + } + else + { + /* Calculation of nearest input values */ + x0 = S->x1 + i * xSpacing; + x1 = S->x1 + (i +1) * xSpacing; + + /* Read of nearest output values */ + y0 = pYData[i]; + y1 = pYData[i + 1]; + + /* Calculation of output */ + y = y0 + (x - x0) * ((y1 - y0)/(x1-x0)); + + } + + /* returns output value */ + return (y); + } + + /** + * + * @brief Process function for the Q31 Linear Interpolation Function. + * @param[in] *pYData pointer to Q31 Linear Interpolation table + * @param[in] x input sample to process + * @param[in] nValues number of table values + * @return y processed output sample. + * + * \par + * Input sample x is in 12.20 format which contains 12 bits for table index and 20 bits for fractional part. + * This function can support maximum of table size 2^12. + * + */ + + + __STATIC_INLINE q31_t arm_linear_interp_q31(q31_t *pYData, + q31_t x, uint32_t nValues) + { + q31_t y; /* output */ + q31_t y0, y1; /* Nearest output values */ + q31_t fract; /* fractional part */ + int32_t index; /* Index to read nearest output values */ + + /* Input is in 12.20 format */ + /* 12 bits for the table index */ + /* Index value calculation */ + index = ((x & 0xFFF00000) >> 20); + + if(index >= (nValues - 1)) + { + return(pYData[nValues - 1]); + } + else if(index < 0) + { + return(pYData[0]); + } + else + { + + /* 20 bits for the fractional part */ + /* shift left by 11 to keep fract in 1.31 format */ + fract = (x & 0x000FFFFF) << 11; + + /* Read two nearest output values from the index in 1.31(q31) format */ + y0 = pYData[index]; + y1 = pYData[index + 1u]; + + /* Calculation of y0 * (1-fract) and y is in 2.30 format */ + y = ((q31_t) ((q63_t) y0 * (0x7FFFFFFF - fract) >> 32)); + + /* Calculation of y0 * (1-fract) + y1 *fract and y is in 2.30 format */ + y += ((q31_t) (((q63_t) y1 * fract) >> 32)); + + /* Convert y to 1.31 format */ + return (y << 1u); + + } + + } + + /** + * + * @brief Process function for the Q15 Linear Interpolation Function. + * @param[in] *pYData pointer to Q15 Linear Interpolation table + * @param[in] x input sample to process + * @param[in] nValues number of table values + * @return y processed output sample. + * + * \par + * Input sample x is in 12.20 format which contains 12 bits for table index and 20 bits for fractional part. + * This function can support maximum of table size 2^12. + * + */ + + + __STATIC_INLINE q15_t arm_linear_interp_q15(q15_t *pYData, q31_t x, uint32_t nValues) + { + q63_t y; /* output */ + q15_t y0, y1; /* Nearest output values */ + q31_t fract; /* fractional part */ + int32_t index; /* Index to read nearest output values */ + + /* Input is in 12.20 format */ + /* 12 bits for the table index */ + /* Index value calculation */ + index = ((x & 0xFFF00000) >> 20u); + + if(index >= (nValues - 1)) + { + return(pYData[nValues - 1]); + } + else if(index < 0) + { + return(pYData[0]); + } + else + { + /* 20 bits for the fractional part */ + /* fract is in 12.20 format */ + fract = (x & 0x000FFFFF); + + /* Read two nearest output values from the index */ + y0 = pYData[index]; + y1 = pYData[index + 1u]; + + /* Calculation of y0 * (1-fract) and y is in 13.35 format */ + y = ((q63_t) y0 * (0xFFFFF - fract)); + + /* Calculation of (y0 * (1-fract) + y1 * fract) and y is in 13.35 format */ + y += ((q63_t) y1 * (fract)); + + /* convert y to 1.15 format */ + return (y >> 20); + } + + + } + + /** + * + * @brief Process function for the Q7 Linear Interpolation Function. + * @param[in] *pYData pointer to Q7 Linear Interpolation table + * @param[in] x input sample to process + * @param[in] nValues number of table values + * @return y processed output sample. + * + * \par + * Input sample x is in 12.20 format which contains 12 bits for table index and 20 bits for fractional part. + * This function can support maximum of table size 2^12. + */ + + + __STATIC_INLINE q7_t arm_linear_interp_q7(q7_t *pYData, q31_t x, uint32_t nValues) + { + q31_t y; /* output */ + q7_t y0, y1; /* Nearest output values */ + q31_t fract; /* fractional part */ + int32_t index; /* Index to read nearest output values */ + + /* Input is in 12.20 format */ + /* 12 bits for the table index */ + /* Index value calculation */ + index = ((x & 0xFFF00000) >> 20u); + + + if(index >= (nValues - 1)) + { + return(pYData[nValues - 1]); + } + else if(index < 0) + { + return(pYData[0]); + } + else + { + + /* 20 bits for the fractional part */ + /* fract is in 12.20 format */ + fract = (x & 0x000FFFFF); + + /* Read two nearest output values from the index and are in 1.7(q7) format */ + y0 = pYData[index]; + y1 = pYData[index + 1u]; + + /* Calculation of y0 * (1-fract ) and y is in 13.27(q27) format */ + y = ((y0 * (0xFFFFF - fract))); + + /* Calculation of y1 * fract + y0 * (1-fract) and y is in 13.27(q27) format */ + y += (y1 * fract); + + /* convert y to 1.7(q7) format */ + return (y >> 20u); + + } + + } + /** + * @} end of LinearInterpolate group + */ + + /** + * @brief Fast approximation to the trigonometric sine function for floating-point data. + * @param[in] x input value in radians. + * @return sin(x). + */ + + float32_t arm_sin_f32( + float32_t x); + + /** + * @brief Fast approximation to the trigonometric sine function for Q31 data. + * @param[in] x Scaled input value in radians. + * @return sin(x). + */ + + q31_t arm_sin_q31( + q31_t x); + + /** + * @brief Fast approximation to the trigonometric sine function for Q15 data. + * @param[in] x Scaled input value in radians. + * @return sin(x). + */ + + q15_t arm_sin_q15( + q15_t x); + + /** + * @brief Fast approximation to the trigonometric cosine function for floating-point data. + * @param[in] x input value in radians. + * @return cos(x). + */ + + float32_t arm_cos_f32( + float32_t x); + + /** + * @brief Fast approximation to the trigonometric cosine function for Q31 data. + * @param[in] x Scaled input value in radians. + * @return cos(x). + */ + + q31_t arm_cos_q31( + q31_t x); + + /** + * @brief Fast approximation to the trigonometric cosine function for Q15 data. + * @param[in] x Scaled input value in radians. + * @return cos(x). + */ + + q15_t arm_cos_q15( + q15_t x); + + + /** + * @ingroup groupFastMath + */ + + + /** + * @defgroup SQRT Square Root + * + * Computes the square root of a number. + * There are separate functions for Q15, Q31, and floating-point data types. + * The square root function is computed using the Newton-Raphson algorithm. + * This is an iterative algorithm of the form: + *
+   *      x1 = x0 - f(x0)/f'(x0)
+   * 
+ * where x1 is the current estimate, + * x0 is the previous estimate and + * f'(x0) is the derivative of f() evaluated at x0. + * For the square root function, the algorithm reduces to: + *
+   *     x0 = in/2                         [initial guess]
+   *     x1 = 1/2 * ( x0 + in / x0)        [each iteration]
+   * 
+ */ + + + /** + * @addtogroup SQRT + * @{ + */ + + /** + * @brief Floating-point square root function. + * @param[in] in input value. + * @param[out] *pOut square root of input value. + * @return The function returns ARM_MATH_SUCCESS if input value is positive value or ARM_MATH_ARGUMENT_ERROR if + * in is negative value and returns zero output for negative values. + */ + + __STATIC_INLINE arm_status arm_sqrt_f32( + float32_t in, float32_t *pOut) + { + if(in > 0) + { + +// #if __FPU_USED + #if (__FPU_USED == 1) && defined ( __CC_ARM ) + *pOut = __sqrtf(in); + #elif (__FPU_USED == 1) && defined ( __TMS_740 ) + *pOut = __builtin_sqrtf(in); + #else + *pOut = sqrtf(in); + #endif + + return (ARM_MATH_SUCCESS); + } + else + { + *pOut = 0.0f; + return (ARM_MATH_ARGUMENT_ERROR); + } + + } + + + /** + * @brief Q31 square root function. + * @param[in] in input value. The range of the input value is [0 +1) or 0x00000000 to 0x7FFFFFFF. + * @param[out] *pOut square root of input value. + * @return The function returns ARM_MATH_SUCCESS if input value is positive value or ARM_MATH_ARGUMENT_ERROR if + * in is negative value and returns zero output for negative values. + */ + arm_status arm_sqrt_q31( + q31_t in, q31_t *pOut); + + /** + * @brief Q15 square root function. + * @param[in] in input value. The range of the input value is [0 +1) or 0x0000 to 0x7FFF. + * @param[out] *pOut square root of input value. + * @return The function returns ARM_MATH_SUCCESS if input value is positive value or ARM_MATH_ARGUMENT_ERROR if + * in is negative value and returns zero output for negative values. + */ + arm_status arm_sqrt_q15( + q15_t in, q15_t *pOut); + + /** + * @} end of SQRT group + */ + + + + + + + /** + * @brief floating-point Circular write function. + */ + + __STATIC_INLINE void arm_circularWrite_f32( + int32_t * circBuffer, + int32_t L, + uint16_t * writeOffset, + int32_t bufferInc, + const int32_t * src, + int32_t srcInc, + uint32_t blockSize) + { + uint32_t i = 0u; + int32_t wOffset; + + /* Copy the value of Index pointer that points + * to the current location where the input samples to be copied */ + wOffset = *writeOffset; + + /* Loop over the blockSize */ + i = blockSize; + + while(i > 0u) + { + /* copy the input sample to the circular buffer */ + circBuffer[wOffset] = *src; + + /* Update the input pointer */ + src += srcInc; + + /* Circularly update wOffset. Watch out for positive and negative value */ + wOffset += bufferInc; + if(wOffset >= L) + wOffset -= L; + + /* Decrement the loop counter */ + i--; + } + + /* Update the index pointer */ + *writeOffset = wOffset; + } + + + + /** + * @brief floating-point Circular Read function. + */ + __STATIC_INLINE void arm_circularRead_f32( + int32_t * circBuffer, + int32_t L, + int32_t * readOffset, + int32_t bufferInc, + int32_t * dst, + int32_t * dst_base, + int32_t dst_length, + int32_t dstInc, + uint32_t blockSize) + { + uint32_t i = 0u; + int32_t rOffset, dst_end; + + /* Copy the value of Index pointer that points + * to the current location from where the input samples to be read */ + rOffset = *readOffset; + dst_end = (int32_t) (dst_base + dst_length); + + /* Loop over the blockSize */ + i = blockSize; + + while(i > 0u) + { + /* copy the sample from the circular buffer to the destination buffer */ + *dst = circBuffer[rOffset]; + + /* Update the input pointer */ + dst += dstInc; + + if(dst == (int32_t *) dst_end) + { + dst = dst_base; + } + + /* Circularly update rOffset. Watch out for positive and negative value */ + rOffset += bufferInc; + + if(rOffset >= L) + { + rOffset -= L; + } + + /* Decrement the loop counter */ + i--; + } + + /* Update the index pointer */ + *readOffset = rOffset; + } + + /** + * @brief Q15 Circular write function. + */ + + __STATIC_INLINE void arm_circularWrite_q15( + q15_t * circBuffer, + int32_t L, + uint16_t * writeOffset, + int32_t bufferInc, + const q15_t * src, + int32_t srcInc, + uint32_t blockSize) + { + uint32_t i = 0u; + int32_t wOffset; + + /* Copy the value of Index pointer that points + * to the current location where the input samples to be copied */ + wOffset = *writeOffset; + + /* Loop over the blockSize */ + i = blockSize; + + while(i > 0u) + { + /* copy the input sample to the circular buffer */ + circBuffer[wOffset] = *src; + + /* Update the input pointer */ + src += srcInc; + + /* Circularly update wOffset. Watch out for positive and negative value */ + wOffset += bufferInc; + if(wOffset >= L) + wOffset -= L; + + /* Decrement the loop counter */ + i--; + } + + /* Update the index pointer */ + *writeOffset = wOffset; + } + + + + /** + * @brief Q15 Circular Read function. + */ + __STATIC_INLINE void arm_circularRead_q15( + q15_t * circBuffer, + int32_t L, + int32_t * readOffset, + int32_t bufferInc, + q15_t * dst, + q15_t * dst_base, + int32_t dst_length, + int32_t dstInc, + uint32_t blockSize) + { + uint32_t i = 0; + int32_t rOffset, dst_end; + + /* Copy the value of Index pointer that points + * to the current location from where the input samples to be read */ + rOffset = *readOffset; + + dst_end = (int32_t) (dst_base + dst_length); + + /* Loop over the blockSize */ + i = blockSize; + + while(i > 0u) + { + /* copy the sample from the circular buffer to the destination buffer */ + *dst = circBuffer[rOffset]; + + /* Update the input pointer */ + dst += dstInc; + + if(dst == (q15_t *) dst_end) + { + dst = dst_base; + } + + /* Circularly update wOffset. Watch out for positive and negative value */ + rOffset += bufferInc; + + if(rOffset >= L) + { + rOffset -= L; + } + + /* Decrement the loop counter */ + i--; + } + + /* Update the index pointer */ + *readOffset = rOffset; + } + + + /** + * @brief Q7 Circular write function. + */ + + __STATIC_INLINE void arm_circularWrite_q7( + q7_t * circBuffer, + int32_t L, + uint16_t * writeOffset, + int32_t bufferInc, + const q7_t * src, + int32_t srcInc, + uint32_t blockSize) + { + uint32_t i = 0u; + int32_t wOffset; + + /* Copy the value of Index pointer that points + * to the current location where the input samples to be copied */ + wOffset = *writeOffset; + + /* Loop over the blockSize */ + i = blockSize; + + while(i > 0u) + { + /* copy the input sample to the circular buffer */ + circBuffer[wOffset] = *src; + + /* Update the input pointer */ + src += srcInc; + + /* Circularly update wOffset. Watch out for positive and negative value */ + wOffset += bufferInc; + if(wOffset >= L) + wOffset -= L; + + /* Decrement the loop counter */ + i--; + } + + /* Update the index pointer */ + *writeOffset = wOffset; + } + + + + /** + * @brief Q7 Circular Read function. + */ + __STATIC_INLINE void arm_circularRead_q7( + q7_t * circBuffer, + int32_t L, + int32_t * readOffset, + int32_t bufferInc, + q7_t * dst, + q7_t * dst_base, + int32_t dst_length, + int32_t dstInc, + uint32_t blockSize) + { + uint32_t i = 0; + int32_t rOffset, dst_end; + + /* Copy the value of Index pointer that points + * to the current location from where the input samples to be read */ + rOffset = *readOffset; + + dst_end = (int32_t) (dst_base + dst_length); + + /* Loop over the blockSize */ + i = blockSize; + + while(i > 0u) + { + /* copy the sample from the circular buffer to the destination buffer */ + *dst = circBuffer[rOffset]; + + /* Update the input pointer */ + dst += dstInc; + + if(dst == (q7_t *) dst_end) + { + dst = dst_base; + } + + /* Circularly update rOffset. Watch out for positive and negative value */ + rOffset += bufferInc; + + if(rOffset >= L) + { + rOffset -= L; + } + + /* Decrement the loop counter */ + i--; + } + + /* Update the index pointer */ + *readOffset = rOffset; + } + + + /** + * @brief Sum of the squares of the elements of a Q31 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_power_q31( + q31_t * pSrc, + uint32_t blockSize, + q63_t * pResult); + + /** + * @brief Sum of the squares of the elements of a floating-point vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_power_f32( + float32_t * pSrc, + uint32_t blockSize, + float32_t * pResult); + + /** + * @brief Sum of the squares of the elements of a Q15 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_power_q15( + q15_t * pSrc, + uint32_t blockSize, + q63_t * pResult); + + /** + * @brief Sum of the squares of the elements of a Q7 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_power_q7( + q7_t * pSrc, + uint32_t blockSize, + q31_t * pResult); + + /** + * @brief Mean value of a Q7 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_mean_q7( + q7_t * pSrc, + uint32_t blockSize, + q7_t * pResult); + + /** + * @brief Mean value of a Q15 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + void arm_mean_q15( + q15_t * pSrc, + uint32_t blockSize, + q15_t * pResult); + + /** + * @brief Mean value of a Q31 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + void arm_mean_q31( + q31_t * pSrc, + uint32_t blockSize, + q31_t * pResult); + + /** + * @brief Mean value of a floating-point vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + void arm_mean_f32( + float32_t * pSrc, + uint32_t blockSize, + float32_t * pResult); + + /** + * @brief Variance of the elements of a floating-point vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_var_f32( + float32_t * pSrc, + uint32_t blockSize, + float32_t * pResult); + + /** + * @brief Variance of the elements of a Q31 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_var_q31( + q31_t * pSrc, + uint32_t blockSize, + q63_t * pResult); + + /** + * @brief Variance of the elements of a Q15 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_var_q15( + q15_t * pSrc, + uint32_t blockSize, + q31_t * pResult); + + /** + * @brief Root Mean Square of the elements of a floating-point vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_rms_f32( + float32_t * pSrc, + uint32_t blockSize, + float32_t * pResult); + + /** + * @brief Root Mean Square of the elements of a Q31 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_rms_q31( + q31_t * pSrc, + uint32_t blockSize, + q31_t * pResult); + + /** + * @brief Root Mean Square of the elements of a Q15 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_rms_q15( + q15_t * pSrc, + uint32_t blockSize, + q15_t * pResult); + + /** + * @brief Standard deviation of the elements of a floating-point vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_std_f32( + float32_t * pSrc, + uint32_t blockSize, + float32_t * pResult); + + /** + * @brief Standard deviation of the elements of a Q31 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_std_q31( + q31_t * pSrc, + uint32_t blockSize, + q31_t * pResult); + + /** + * @brief Standard deviation of the elements of a Q15 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_std_q15( + q15_t * pSrc, + uint32_t blockSize, + q15_t * pResult); + + /** + * @brief Floating-point complex magnitude + * @param[in] *pSrc points to the complex input vector + * @param[out] *pDst points to the real output vector + * @param[in] numSamples number of complex samples in the input vector + * @return none. + */ + + void arm_cmplx_mag_f32( + float32_t * pSrc, + float32_t * pDst, + uint32_t numSamples); + + /** + * @brief Q31 complex magnitude + * @param[in] *pSrc points to the complex input vector + * @param[out] *pDst points to the real output vector + * @param[in] numSamples number of complex samples in the input vector + * @return none. + */ + + void arm_cmplx_mag_q31( + q31_t * pSrc, + q31_t * pDst, + uint32_t numSamples); + + /** + * @brief Q15 complex magnitude + * @param[in] *pSrc points to the complex input vector + * @param[out] *pDst points to the real output vector + * @param[in] numSamples number of complex samples in the input vector + * @return none. + */ + + void arm_cmplx_mag_q15( + q15_t * pSrc, + q15_t * pDst, + uint32_t numSamples); + + /** + * @brief Q15 complex dot product + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[in] numSamples number of complex samples in each vector + * @param[out] *realResult real part of the result returned here + * @param[out] *imagResult imaginary part of the result returned here + * @return none. + */ + + void arm_cmplx_dot_prod_q15( + q15_t * pSrcA, + q15_t * pSrcB, + uint32_t numSamples, + q31_t * realResult, + q31_t * imagResult); + + /** + * @brief Q31 complex dot product + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[in] numSamples number of complex samples in each vector + * @param[out] *realResult real part of the result returned here + * @param[out] *imagResult imaginary part of the result returned here + * @return none. + */ + + void arm_cmplx_dot_prod_q31( + q31_t * pSrcA, + q31_t * pSrcB, + uint32_t numSamples, + q63_t * realResult, + q63_t * imagResult); + + /** + * @brief Floating-point complex dot product + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[in] numSamples number of complex samples in each vector + * @param[out] *realResult real part of the result returned here + * @param[out] *imagResult imaginary part of the result returned here + * @return none. + */ + + void arm_cmplx_dot_prod_f32( + float32_t * pSrcA, + float32_t * pSrcB, + uint32_t numSamples, + float32_t * realResult, + float32_t * imagResult); + + /** + * @brief Q15 complex-by-real multiplication + * @param[in] *pSrcCmplx points to the complex input vector + * @param[in] *pSrcReal points to the real input vector + * @param[out] *pCmplxDst points to the complex output vector + * @param[in] numSamples number of samples in each vector + * @return none. + */ + + void arm_cmplx_mult_real_q15( + q15_t * pSrcCmplx, + q15_t * pSrcReal, + q15_t * pCmplxDst, + uint32_t numSamples); + + /** + * @brief Q31 complex-by-real multiplication + * @param[in] *pSrcCmplx points to the complex input vector + * @param[in] *pSrcReal points to the real input vector + * @param[out] *pCmplxDst points to the complex output vector + * @param[in] numSamples number of samples in each vector + * @return none. + */ + + void arm_cmplx_mult_real_q31( + q31_t * pSrcCmplx, + q31_t * pSrcReal, + q31_t * pCmplxDst, + uint32_t numSamples); + + /** + * @brief Floating-point complex-by-real multiplication + * @param[in] *pSrcCmplx points to the complex input vector + * @param[in] *pSrcReal points to the real input vector + * @param[out] *pCmplxDst points to the complex output vector + * @param[in] numSamples number of samples in each vector + * @return none. + */ + + void arm_cmplx_mult_real_f32( + float32_t * pSrcCmplx, + float32_t * pSrcReal, + float32_t * pCmplxDst, + uint32_t numSamples); + + /** + * @brief Minimum value of a Q7 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *result is output pointer + * @param[in] index is the array index of the minimum value in the input buffer. + * @return none. + */ + + void arm_min_q7( + q7_t * pSrc, + uint32_t blockSize, + q7_t * result, + uint32_t * index); + + /** + * @brief Minimum value of a Q15 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output pointer + * @param[in] *pIndex is the array index of the minimum value in the input buffer. + * @return none. + */ + + void arm_min_q15( + q15_t * pSrc, + uint32_t blockSize, + q15_t * pResult, + uint32_t * pIndex); + + /** + * @brief Minimum value of a Q31 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output pointer + * @param[out] *pIndex is the array index of the minimum value in the input buffer. + * @return none. + */ + void arm_min_q31( + q31_t * pSrc, + uint32_t blockSize, + q31_t * pResult, + uint32_t * pIndex); + + /** + * @brief Minimum value of a floating-point vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output pointer + * @param[out] *pIndex is the array index of the minimum value in the input buffer. + * @return none. + */ + + void arm_min_f32( + float32_t * pSrc, + uint32_t blockSize, + float32_t * pResult, + uint32_t * pIndex); + +/** + * @brief Maximum value of a Q7 vector. + * @param[in] *pSrc points to the input buffer + * @param[in] blockSize length of the input vector + * @param[out] *pResult maximum value returned here + * @param[out] *pIndex index of maximum value returned here + * @return none. + */ + + void arm_max_q7( + q7_t * pSrc, + uint32_t blockSize, + q7_t * pResult, + uint32_t * pIndex); + +/** + * @brief Maximum value of a Q15 vector. + * @param[in] *pSrc points to the input buffer + * @param[in] blockSize length of the input vector + * @param[out] *pResult maximum value returned here + * @param[out] *pIndex index of maximum value returned here + * @return none. + */ + + void arm_max_q15( + q15_t * pSrc, + uint32_t blockSize, + q15_t * pResult, + uint32_t * pIndex); + +/** + * @brief Maximum value of a Q31 vector. + * @param[in] *pSrc points to the input buffer + * @param[in] blockSize length of the input vector + * @param[out] *pResult maximum value returned here + * @param[out] *pIndex index of maximum value returned here + * @return none. + */ + + void arm_max_q31( + q31_t * pSrc, + uint32_t blockSize, + q31_t * pResult, + uint32_t * pIndex); + +/** + * @brief Maximum value of a floating-point vector. + * @param[in] *pSrc points to the input buffer + * @param[in] blockSize length of the input vector + * @param[out] *pResult maximum value returned here + * @param[out] *pIndex index of maximum value returned here + * @return none. + */ + + void arm_max_f32( + float32_t * pSrc, + uint32_t blockSize, + float32_t * pResult, + uint32_t * pIndex); + + /** + * @brief Q15 complex-by-complex multiplication + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] numSamples number of complex samples in each vector + * @return none. + */ + + void arm_cmplx_mult_cmplx_q15( + q15_t * pSrcA, + q15_t * pSrcB, + q15_t * pDst, + uint32_t numSamples); + + /** + * @brief Q31 complex-by-complex multiplication + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] numSamples number of complex samples in each vector + * @return none. + */ + + void arm_cmplx_mult_cmplx_q31( + q31_t * pSrcA, + q31_t * pSrcB, + q31_t * pDst, + uint32_t numSamples); + + /** + * @brief Floating-point complex-by-complex multiplication + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] numSamples number of complex samples in each vector + * @return none. + */ + + void arm_cmplx_mult_cmplx_f32( + float32_t * pSrcA, + float32_t * pSrcB, + float32_t * pDst, + uint32_t numSamples); + + /** + * @brief Converts the elements of the floating-point vector to Q31 vector. + * @param[in] *pSrc points to the floating-point input vector + * @param[out] *pDst points to the Q31 output vector + * @param[in] blockSize length of the input vector + * @return none. + */ + void arm_float_to_q31( + float32_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Converts the elements of the floating-point vector to Q15 vector. + * @param[in] *pSrc points to the floating-point input vector + * @param[out] *pDst points to the Q15 output vector + * @param[in] blockSize length of the input vector + * @return none + */ + void arm_float_to_q15( + float32_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Converts the elements of the floating-point vector to Q7 vector. + * @param[in] *pSrc points to the floating-point input vector + * @param[out] *pDst points to the Q7 output vector + * @param[in] blockSize length of the input vector + * @return none + */ + void arm_float_to_q7( + float32_t * pSrc, + q7_t * pDst, + uint32_t blockSize); + + + /** + * @brief Converts the elements of the Q31 vector to Q15 vector. + * @param[in] *pSrc is input pointer + * @param[out] *pDst is output pointer + * @param[in] blockSize is the number of samples to process + * @return none. + */ + void arm_q31_to_q15( + q31_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Converts the elements of the Q31 vector to Q7 vector. + * @param[in] *pSrc is input pointer + * @param[out] *pDst is output pointer + * @param[in] blockSize is the number of samples to process + * @return none. + */ + void arm_q31_to_q7( + q31_t * pSrc, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Converts the elements of the Q15 vector to floating-point vector. + * @param[in] *pSrc is input pointer + * @param[out] *pDst is output pointer + * @param[in] blockSize is the number of samples to process + * @return none. + */ + void arm_q15_to_float( + q15_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + + /** + * @brief Converts the elements of the Q15 vector to Q31 vector. + * @param[in] *pSrc is input pointer + * @param[out] *pDst is output pointer + * @param[in] blockSize is the number of samples to process + * @return none. + */ + void arm_q15_to_q31( + q15_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + + /** + * @brief Converts the elements of the Q15 vector to Q7 vector. + * @param[in] *pSrc is input pointer + * @param[out] *pDst is output pointer + * @param[in] blockSize is the number of samples to process + * @return none. + */ + void arm_q15_to_q7( + q15_t * pSrc, + q7_t * pDst, + uint32_t blockSize); + + + /** + * @ingroup groupInterpolation + */ + + /** + * @defgroup BilinearInterpolate Bilinear Interpolation + * + * Bilinear interpolation is an extension of linear interpolation applied to a two dimensional grid. + * The underlying function f(x, y) is sampled on a regular grid and the interpolation process + * determines values between the grid points. + * Bilinear interpolation is equivalent to two step linear interpolation, first in the x-dimension and then in the y-dimension. + * Bilinear interpolation is often used in image processing to rescale images. + * The CMSIS DSP library provides bilinear interpolation functions for Q7, Q15, Q31, and floating-point data types. + * + * Algorithm + * \par + * The instance structure used by the bilinear interpolation functions describes a two dimensional data table. + * For floating-point, the instance structure is defined as: + *
+   *   typedef struct
+   *   {
+   *     uint16_t numRows;
+   *     uint16_t numCols;
+   *     float32_t *pData;
+   * } arm_bilinear_interp_instance_f32;
+   * 
+ * + * \par + * where numRows specifies the number of rows in the table; + * numCols specifies the number of columns in the table; + * and pData points to an array of size numRows*numCols values. + * The data table pTable is organized in row order and the supplied data values fall on integer indexes. + * That is, table element (x,y) is located at pTable[x + y*numCols] where x and y are integers. + * + * \par + * Let (x, y) specify the desired interpolation point. Then define: + *
+   *     XF = floor(x)
+   *     YF = floor(y)
+   * 
+ * \par + * The interpolated output point is computed as: + *
+   *  f(x, y) = f(XF, YF) * (1-(x-XF)) * (1-(y-YF))
+   *           + f(XF+1, YF) * (x-XF)*(1-(y-YF))
+   *           + f(XF, YF+1) * (1-(x-XF))*(y-YF)
+   *           + f(XF+1, YF+1) * (x-XF)*(y-YF)
+   * 
+ * Note that the coordinates (x, y) contain integer and fractional components. + * The integer components specify which portion of the table to use while the + * fractional components control the interpolation processor. + * + * \par + * if (x,y) are outside of the table boundary, Bilinear interpolation returns zero output. + */ + + /** + * @addtogroup BilinearInterpolate + * @{ + */ + + /** + * + * @brief Floating-point bilinear interpolation. + * @param[in,out] *S points to an instance of the interpolation structure. + * @param[in] X interpolation coordinate. + * @param[in] Y interpolation coordinate. + * @return out interpolated value. + */ + + + __STATIC_INLINE float32_t arm_bilinear_interp_f32( + const arm_bilinear_interp_instance_f32 * S, + float32_t X, + float32_t Y) + { + float32_t out; + float32_t f00, f01, f10, f11; + float32_t *pData = S->pData; + int32_t xIndex, yIndex, index; + float32_t xdiff, ydiff; + float32_t b1, b2, b3, b4; + + xIndex = (int32_t) X; + yIndex = (int32_t) Y; + + /* Care taken for table outside boundary */ + /* Returns zero output when values are outside table boundary */ + if(xIndex < 0 || xIndex > (S->numRows-1) || yIndex < 0 || yIndex > ( S->numCols-1)) + { + return(0); + } + + /* Calculation of index for two nearest points in X-direction */ + index = (xIndex - 1) + (yIndex-1) * S->numCols ; + + + /* Read two nearest points in X-direction */ + f00 = pData[index]; + f01 = pData[index + 1]; + + /* Calculation of index for two nearest points in Y-direction */ + index = (xIndex-1) + (yIndex) * S->numCols; + + + /* Read two nearest points in Y-direction */ + f10 = pData[index]; + f11 = pData[index + 1]; + + /* Calculation of intermediate values */ + b1 = f00; + b2 = f01 - f00; + b3 = f10 - f00; + b4 = f00 - f01 - f10 + f11; + + /* Calculation of fractional part in X */ + xdiff = X - xIndex; + + /* Calculation of fractional part in Y */ + ydiff = Y - yIndex; + + /* Calculation of bi-linear interpolated output */ + out = b1 + b2 * xdiff + b3 * ydiff + b4 * xdiff * ydiff; + + /* return to application */ + return (out); + + } + + /** + * + * @brief Q31 bilinear interpolation. + * @param[in,out] *S points to an instance of the interpolation structure. + * @param[in] X interpolation coordinate in 12.20 format. + * @param[in] Y interpolation coordinate in 12.20 format. + * @return out interpolated value. + */ + + __STATIC_INLINE q31_t arm_bilinear_interp_q31( + arm_bilinear_interp_instance_q31 * S, + q31_t X, + q31_t Y) + { + q31_t out; /* Temporary output */ + q31_t acc = 0; /* output */ + q31_t xfract, yfract; /* X, Y fractional parts */ + q31_t x1, x2, y1, y2; /* Nearest output values */ + int32_t rI, cI; /* Row and column indices */ + q31_t *pYData = S->pData; /* pointer to output table values */ + uint32_t nCols = S->numCols; /* num of rows */ + + + /* Input is in 12.20 format */ + /* 12 bits for the table index */ + /* Index value calculation */ + rI = ((X & 0xFFF00000) >> 20u); + + /* Input is in 12.20 format */ + /* 12 bits for the table index */ + /* Index value calculation */ + cI = ((Y & 0xFFF00000) >> 20u); + + /* Care taken for table outside boundary */ + /* Returns zero output when values are outside table boundary */ + if(rI < 0 || rI > (S->numRows-1) || cI < 0 || cI > ( S->numCols-1)) + { + return(0); + } + + /* 20 bits for the fractional part */ + /* shift left xfract by 11 to keep 1.31 format */ + xfract = (X & 0x000FFFFF) << 11u; + + /* Read two nearest output values from the index */ + x1 = pYData[(rI) + nCols * (cI)]; + x2 = pYData[(rI) + nCols * (cI) + 1u]; + + /* 20 bits for the fractional part */ + /* shift left yfract by 11 to keep 1.31 format */ + yfract = (Y & 0x000FFFFF) << 11u; + + /* Read two nearest output values from the index */ + y1 = pYData[(rI) + nCols * (cI + 1)]; + y2 = pYData[(rI) + nCols * (cI + 1) + 1u]; + + /* Calculation of x1 * (1-xfract ) * (1-yfract) and acc is in 3.29(q29) format */ + out = ((q31_t) (((q63_t) x1 * (0x7FFFFFFF - xfract)) >> 32)); + acc = ((q31_t) (((q63_t) out * (0x7FFFFFFF - yfract)) >> 32)); + + /* x2 * (xfract) * (1-yfract) in 3.29(q29) and adding to acc */ + out = ((q31_t) ((q63_t) x2 * (0x7FFFFFFF - yfract) >> 32)); + acc += ((q31_t) ((q63_t) out * (xfract) >> 32)); + + /* y1 * (1 - xfract) * (yfract) in 3.29(q29) and adding to acc */ + out = ((q31_t) ((q63_t) y1 * (0x7FFFFFFF - xfract) >> 32)); + acc += ((q31_t) ((q63_t) out * (yfract) >> 32)); + + /* y2 * (xfract) * (yfract) in 3.29(q29) and adding to acc */ + out = ((q31_t) ((q63_t) y2 * (xfract) >> 32)); + acc += ((q31_t) ((q63_t) out * (yfract) >> 32)); + + /* Convert acc to 1.31(q31) format */ + return (acc << 2u); + + } + + /** + * @brief Q15 bilinear interpolation. + * @param[in,out] *S points to an instance of the interpolation structure. + * @param[in] X interpolation coordinate in 12.20 format. + * @param[in] Y interpolation coordinate in 12.20 format. + * @return out interpolated value. + */ + + __STATIC_INLINE q15_t arm_bilinear_interp_q15( + arm_bilinear_interp_instance_q15 * S, + q31_t X, + q31_t Y) + { + q63_t acc = 0; /* output */ + q31_t out; /* Temporary output */ + q15_t x1, x2, y1, y2; /* Nearest output values */ + q31_t xfract, yfract; /* X, Y fractional parts */ + int32_t rI, cI; /* Row and column indices */ + q15_t *pYData = S->pData; /* pointer to output table values */ + uint32_t nCols = S->numCols; /* num of rows */ + + /* Input is in 12.20 format */ + /* 12 bits for the table index */ + /* Index value calculation */ + rI = ((X & 0xFFF00000) >> 20); + + /* Input is in 12.20 format */ + /* 12 bits for the table index */ + /* Index value calculation */ + cI = ((Y & 0xFFF00000) >> 20); + + /* Care taken for table outside boundary */ + /* Returns zero output when values are outside table boundary */ + if(rI < 0 || rI > (S->numRows-1) || cI < 0 || cI > ( S->numCols-1)) + { + return(0); + } + + /* 20 bits for the fractional part */ + /* xfract should be in 12.20 format */ + xfract = (X & 0x000FFFFF); + + /* Read two nearest output values from the index */ + x1 = pYData[(rI) + nCols * (cI)]; + x2 = pYData[(rI) + nCols * (cI) + 1u]; + + + /* 20 bits for the fractional part */ + /* yfract should be in 12.20 format */ + yfract = (Y & 0x000FFFFF); + + /* Read two nearest output values from the index */ + y1 = pYData[(rI) + nCols * (cI + 1)]; + y2 = pYData[(rI) + nCols * (cI + 1) + 1u]; + + /* Calculation of x1 * (1-xfract ) * (1-yfract) and acc is in 13.51 format */ + + /* x1 is in 1.15(q15), xfract in 12.20 format and out is in 13.35 format */ + /* convert 13.35 to 13.31 by right shifting and out is in 1.31 */ + out = (q31_t) (((q63_t) x1 * (0xFFFFF - xfract)) >> 4u); + acc = ((q63_t) out * (0xFFFFF - yfract)); + + /* x2 * (xfract) * (1-yfract) in 1.51 and adding to acc */ + out = (q31_t) (((q63_t) x2 * (0xFFFFF - yfract)) >> 4u); + acc += ((q63_t) out * (xfract)); + + /* y1 * (1 - xfract) * (yfract) in 1.51 and adding to acc */ + out = (q31_t) (((q63_t) y1 * (0xFFFFF - xfract)) >> 4u); + acc += ((q63_t) out * (yfract)); + + /* y2 * (xfract) * (yfract) in 1.51 and adding to acc */ + out = (q31_t) (((q63_t) y2 * (xfract)) >> 4u); + acc += ((q63_t) out * (yfract)); + + /* acc is in 13.51 format and down shift acc by 36 times */ + /* Convert out to 1.15 format */ + return (acc >> 36); + + } + + /** + * @brief Q7 bilinear interpolation. + * @param[in,out] *S points to an instance of the interpolation structure. + * @param[in] X interpolation coordinate in 12.20 format. + * @param[in] Y interpolation coordinate in 12.20 format. + * @return out interpolated value. + */ + + __STATIC_INLINE q7_t arm_bilinear_interp_q7( + arm_bilinear_interp_instance_q7 * S, + q31_t X, + q31_t Y) + { + q63_t acc = 0; /* output */ + q31_t out; /* Temporary output */ + q31_t xfract, yfract; /* X, Y fractional parts */ + q7_t x1, x2, y1, y2; /* Nearest output values */ + int32_t rI, cI; /* Row and column indices */ + q7_t *pYData = S->pData; /* pointer to output table values */ + uint32_t nCols = S->numCols; /* num of rows */ + + /* Input is in 12.20 format */ + /* 12 bits for the table index */ + /* Index value calculation */ + rI = ((X & 0xFFF00000) >> 20); + + /* Input is in 12.20 format */ + /* 12 bits for the table index */ + /* Index value calculation */ + cI = ((Y & 0xFFF00000) >> 20); + + /* Care taken for table outside boundary */ + /* Returns zero output when values are outside table boundary */ + if(rI < 0 || rI > (S->numRows-1) || cI < 0 || cI > ( S->numCols-1)) + { + return(0); + } + + /* 20 bits for the fractional part */ + /* xfract should be in 12.20 format */ + xfract = (X & 0x000FFFFF); + + /* Read two nearest output values from the index */ + x1 = pYData[(rI) + nCols * (cI)]; + x2 = pYData[(rI) + nCols * (cI) + 1u]; + + + /* 20 bits for the fractional part */ + /* yfract should be in 12.20 format */ + yfract = (Y & 0x000FFFFF); + + /* Read two nearest output values from the index */ + y1 = pYData[(rI) + nCols * (cI + 1)]; + y2 = pYData[(rI) + nCols * (cI + 1) + 1u]; + + /* Calculation of x1 * (1-xfract ) * (1-yfract) and acc is in 16.47 format */ + out = ((x1 * (0xFFFFF - xfract))); + acc = (((q63_t) out * (0xFFFFF - yfract))); + + /* x2 * (xfract) * (1-yfract) in 2.22 and adding to acc */ + out = ((x2 * (0xFFFFF - yfract))); + acc += (((q63_t) out * (xfract))); + + /* y1 * (1 - xfract) * (yfract) in 2.22 and adding to acc */ + out = ((y1 * (0xFFFFF - xfract))); + acc += (((q63_t) out * (yfract))); + + /* y2 * (xfract) * (yfract) in 2.22 and adding to acc */ + out = ((y2 * (yfract))); + acc += (((q63_t) out * (xfract))); + + /* acc in 16.47 format and down shift by 40 to convert to 1.7 format */ + return (acc >> 40); + + } + + /** + * @} end of BilinearInterpolate group + */ + + + + + + +#ifdef __cplusplus +} +#endif + + +#endif /* _ARM_MATH_H */ + + +/** + * + * End of file. + */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/Include/core_cm0plus.h b/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/Include/core_cm0plus.h new file mode 100644 index 0000000..cf92fb7 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/Include/core_cm0plus.h @@ -0,0 +1,778 @@ +/**************************************************************************//** + * @file core_cm0plus.h + * @brief CMSIS Cortex-M0+ Core Peripheral Access Layer Header File + * @version V3.01 + * @date 22. March 2012 + * + * @note + * Copyright (C) 2009-2012 ARM Limited. All rights reserved. + * + * @par + * ARM Limited (ARM) is supplying this software for use with Cortex-M + * processor based microcontrollers. This file can be freely distributed + * within development tools that are supporting such ARM based processors. + * + * @par + * THIS SOFTWARE IS PROVIDED "AS IS". NO WARRANTIES, WHETHER EXPRESS, IMPLIED + * OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE. + * ARM SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR SPECIAL, INCIDENTAL, OR + * CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER. + * + ******************************************************************************/ +#if defined ( __ICCARM__ ) + #pragma system_include /* treat file as system include file for MISRA check */ +#endif + +#ifdef __cplusplus + extern "C" { +#endif + +#ifndef __CORE_CM0PLUS_H_GENERIC +#define __CORE_CM0PLUS_H_GENERIC + +/** \page CMSIS_MISRA_Exceptions MISRA-C:2004 Compliance Exceptions + CMSIS violates the following MISRA-C:2004 rules: + + \li Required Rule 8.5, object/function definition in header file.
+ Function definitions in header files are used to allow 'inlining'. + + \li Required Rule 18.4, declaration of union type or object of union type: '{...}'.
+ Unions are used for effective representation of core registers. + + \li Advisory Rule 19.7, Function-like macro defined.
+ Function-like macros are used to allow more efficient code. + */ + + +/******************************************************************************* + * CMSIS definitions + ******************************************************************************/ +/** \ingroup Cortex-M0+ + @{ + */ + +/* CMSIS CM0P definitions */ +#define __CM0PLUS_CMSIS_VERSION_MAIN (0x03) /*!< [31:16] CMSIS HAL main version */ +#define __CM0PLUS_CMSIS_VERSION_SUB (0x01) /*!< [15:0] CMSIS HAL sub version */ +#define __CM0PLUS_CMSIS_VERSION ((__CM0PLUS_CMSIS_VERSION_MAIN << 16) | \ + __CM0PLUS_CMSIS_VERSION_SUB) /*!< CMSIS HAL version number */ + +#define __CORTEX_M (0x00) /*!< Cortex-M Core */ + + +#if defined ( __CC_ARM ) + #define __ASM __asm /*!< asm keyword for ARM Compiler */ + #define __INLINE __inline /*!< inline keyword for ARM Compiler */ + #define __STATIC_INLINE static __inline + +#elif defined ( __ICCARM__ ) + #define __ASM __asm /*!< asm keyword for IAR Compiler */ + #define __INLINE inline /*!< inline keyword for IAR Compiler. Only available in High optimization mode! */ + #define __STATIC_INLINE static inline + +#elif defined ( __GNUC__ ) + #define __ASM __asm /*!< asm keyword for GNU Compiler */ + #define __INLINE inline /*!< inline keyword for GNU Compiler */ + #define __STATIC_INLINE static inline + +#elif defined ( __TASKING__ ) + #define __ASM __asm /*!< asm keyword for TASKING Compiler */ + #define __INLINE inline /*!< inline keyword for TASKING Compiler */ + #define __STATIC_INLINE static inline + +#endif + +/** __FPU_USED indicates whether an FPU is used or not. This core does not support an FPU at all +*/ +#define __FPU_USED 0 + +#if defined ( __CC_ARM ) + #if defined __TARGET_FPU_VFP + #warning "Compiler generates FPU instructions for a device without an FPU (check __FPU_PRESENT)" + #endif + +#elif defined ( __ICCARM__ ) + #if defined __ARMVFP__ + #warning "Compiler generates FPU instructions for a device without an FPU (check __FPU_PRESENT)" + #endif + +#elif defined ( __GNUC__ ) + #if defined (__VFP_FP__) && !defined(__SOFTFP__) + #warning "Compiler generates FPU instructions for a device without an FPU (check __FPU_PRESENT)" + #endif + +#elif defined ( __TASKING__ ) + #if defined __FPU_VFP__ + #error "Compiler generates FPU instructions for a device without an FPU (check __FPU_PRESENT)" + #endif +#endif + +#include /* standard types definitions */ +#include /* Core Instruction Access */ +#include /* Core Function Access */ + +#endif /* __CORE_CM0PLUS_H_GENERIC */ + +#ifndef __CMSIS_GENERIC + +#ifndef __CORE_CM0PLUS_H_DEPENDANT +#define __CORE_CM0PLUS_H_DEPENDANT + +/* check device defines and use defaults */ +#if defined __CHECK_DEVICE_DEFINES + #ifndef __CM0PLUS_REV + #define __CM0PLUS_REV 0x0000 + #warning "__CM0PLUS_REV not defined in device header file; using default!" + #endif + + #ifndef __MPU_PRESENT + #define __MPU_PRESENT 0 + #warning "__MPU_PRESENT not defined in device header file; using default!" + #endif + + #ifndef __VTOR_PRESENT + #define __VTOR_PRESENT 0 + #warning "__VTOR_PRESENT not defined in device header file; using default!" + #endif + + #ifndef __NVIC_PRIO_BITS + #define __NVIC_PRIO_BITS 2 + #warning "__NVIC_PRIO_BITS not defined in device header file; using default!" + #endif + + #ifndef __Vendor_SysTickConfig + #define __Vendor_SysTickConfig 0 + #warning "__Vendor_SysTickConfig not defined in device header file; using default!" + #endif +#endif + +/* IO definitions (access restrictions to peripheral registers) */ +/** + \defgroup CMSIS_glob_defs CMSIS Global Defines + + IO Type Qualifiers are used + \li to specify the access to peripheral variables. + \li for automatic generation of peripheral register debug information. +*/ +#ifdef __cplusplus + #define __I volatile /*!< Defines 'read only' permissions */ +#else + #define __I volatile const /*!< Defines 'read only' permissions */ +#endif +#define __O volatile /*!< Defines 'write only' permissions */ +#define __IO volatile /*!< Defines 'read / write' permissions */ + +/*@} end of group Cortex-M0+ */ + + + +/******************************************************************************* + * Register Abstraction + Core Register contain: + - Core Register + - Core NVIC Register + - Core SCB Register + - Core SysTick Register + - Core MPU Register + ******************************************************************************/ +/** \defgroup CMSIS_core_register Defines and Type Definitions + \brief Type definitions and defines for Cortex-M processor based devices. +*/ + +/** \ingroup CMSIS_core_register + \defgroup CMSIS_CORE Status and Control Registers + \brief Core Register type definitions. + @{ + */ + +/** \brief Union type to access the Application Program Status Register (APSR). + */ +typedef union +{ + struct + { +#if (__CORTEX_M != 0x04) + uint32_t _reserved0:27; /*!< bit: 0..26 Reserved */ +#else + uint32_t _reserved0:16; /*!< bit: 0..15 Reserved */ + uint32_t GE:4; /*!< bit: 16..19 Greater than or Equal flags */ + uint32_t _reserved1:7; /*!< bit: 20..26 Reserved */ +#endif + uint32_t Q:1; /*!< bit: 27 Saturation condition flag */ + uint32_t V:1; /*!< bit: 28 Overflow condition code flag */ + uint32_t C:1; /*!< bit: 29 Carry condition code flag */ + uint32_t Z:1; /*!< bit: 30 Zero condition code flag */ + uint32_t N:1; /*!< bit: 31 Negative condition code flag */ + } b; /*!< Structure used for bit access */ + uint32_t w; /*!< Type used for word access */ +} APSR_Type; + + +/** \brief Union type to access the Interrupt Program Status Register (IPSR). + */ +typedef union +{ + struct + { + uint32_t ISR:9; /*!< bit: 0.. 8 Exception number */ + uint32_t _reserved0:23; /*!< bit: 9..31 Reserved */ + } b; /*!< Structure used for bit access */ + uint32_t w; /*!< Type used for word access */ +} IPSR_Type; + + +/** \brief Union type to access the Special-Purpose Program Status Registers (xPSR). + */ +typedef union +{ + struct + { + uint32_t ISR:9; /*!< bit: 0.. 8 Exception number */ +#if (__CORTEX_M != 0x04) + uint32_t _reserved0:15; /*!< bit: 9..23 Reserved */ +#else + uint32_t _reserved0:7; /*!< bit: 9..15 Reserved */ + uint32_t GE:4; /*!< bit: 16..19 Greater than or Equal flags */ + uint32_t _reserved1:4; /*!< bit: 20..23 Reserved */ +#endif + uint32_t T:1; /*!< bit: 24 Thumb bit (read 0) */ + uint32_t IT:2; /*!< bit: 25..26 saved IT state (read 0) */ + uint32_t Q:1; /*!< bit: 27 Saturation condition flag */ + uint32_t V:1; /*!< bit: 28 Overflow condition code flag */ + uint32_t C:1; /*!< bit: 29 Carry condition code flag */ + uint32_t Z:1; /*!< bit: 30 Zero condition code flag */ + uint32_t N:1; /*!< bit: 31 Negative condition code flag */ + } b; /*!< Structure used for bit access */ + uint32_t w; /*!< Type used for word access */ +} xPSR_Type; + + +/** \brief Union type to access the Control Registers (CONTROL). + */ +typedef union +{ + struct + { + uint32_t nPRIV:1; /*!< bit: 0 Execution privilege in Thread mode */ + uint32_t SPSEL:1; /*!< bit: 1 Stack to be used */ + uint32_t FPCA:1; /*!< bit: 2 FP extension active flag */ + uint32_t _reserved0:29; /*!< bit: 3..31 Reserved */ + } b; /*!< Structure used for bit access */ + uint32_t w; /*!< Type used for word access */ +} CONTROL_Type; + +/*@} end of group CMSIS_CORE */ + + +/** \ingroup CMSIS_core_register + \defgroup CMSIS_NVIC Nested Vectored Interrupt Controller (NVIC) + \brief Type definitions for the NVIC Registers + @{ + */ + +/** \brief Structure type to access the Nested Vectored Interrupt Controller (NVIC). + */ +typedef struct +{ + __IO uint32_t ISER[1]; /*!< Offset: 0x000 (R/W) Interrupt Set Enable Register */ + uint32_t RESERVED0[31]; + __IO uint32_t ICER[1]; /*!< Offset: 0x080 (R/W) Interrupt Clear Enable Register */ + uint32_t RSERVED1[31]; + __IO uint32_t ISPR[1]; /*!< Offset: 0x100 (R/W) Interrupt Set Pending Register */ + uint32_t RESERVED2[31]; + __IO uint32_t ICPR[1]; /*!< Offset: 0x180 (R/W) Interrupt Clear Pending Register */ + uint32_t RESERVED3[31]; + uint32_t RESERVED4[64]; + __IO uint32_t IP[8]; /*!< Offset: 0x300 (R/W) Interrupt Priority Register */ +} NVIC_Type; + +/*@} end of group CMSIS_NVIC */ + + +/** \ingroup CMSIS_core_register + \defgroup CMSIS_SCB System Control Block (SCB) + \brief Type definitions for the System Control Block Registers + @{ + */ + +/** \brief Structure type to access the System Control Block (SCB). + */ +typedef struct +{ + __I uint32_t CPUID; /*!< Offset: 0x000 (R/ ) CPUID Base Register */ + __IO uint32_t ICSR; /*!< Offset: 0x004 (R/W) Interrupt Control and State Register */ +#if (__VTOR_PRESENT == 1) + __IO uint32_t VTOR; /*!< Offset: 0x008 (R/W) Vector Table Offset Register */ +#else + uint32_t RESERVED0; +#endif + __IO uint32_t AIRCR; /*!< Offset: 0x00C (R/W) Application Interrupt and Reset Control Register */ + __IO uint32_t SCR; /*!< Offset: 0x010 (R/W) System Control Register */ + __IO uint32_t CCR; /*!< Offset: 0x014 (R/W) Configuration Control Register */ + uint32_t RESERVED1; + __IO uint32_t SHP[2]; /*!< Offset: 0x01C (R/W) System Handlers Priority Registers. [0] is RESERVED */ + __IO uint32_t SHCSR; /*!< Offset: 0x024 (R/W) System Handler Control and State Register */ +} SCB_Type; + +/* SCB CPUID Register Definitions */ +#define SCB_CPUID_IMPLEMENTER_Pos 24 /*!< SCB CPUID: IMPLEMENTER Position */ +#define SCB_CPUID_IMPLEMENTER_Msk (0xFFUL << SCB_CPUID_IMPLEMENTER_Pos) /*!< SCB CPUID: IMPLEMENTER Mask */ + +#define SCB_CPUID_VARIANT_Pos 20 /*!< SCB CPUID: VARIANT Position */ +#define SCB_CPUID_VARIANT_Msk (0xFUL << SCB_CPUID_VARIANT_Pos) /*!< SCB CPUID: VARIANT Mask */ + +#define SCB_CPUID_ARCHITECTURE_Pos 16 /*!< SCB CPUID: ARCHITECTURE Position */ +#define SCB_CPUID_ARCHITECTURE_Msk (0xFUL << SCB_CPUID_ARCHITECTURE_Pos) /*!< SCB CPUID: ARCHITECTURE Mask */ + +#define SCB_CPUID_PARTNO_Pos 4 /*!< SCB CPUID: PARTNO Position */ +#define SCB_CPUID_PARTNO_Msk (0xFFFUL << SCB_CPUID_PARTNO_Pos) /*!< SCB CPUID: PARTNO Mask */ + +#define SCB_CPUID_REVISION_Pos 0 /*!< SCB CPUID: REVISION Position */ +#define SCB_CPUID_REVISION_Msk (0xFUL << SCB_CPUID_REVISION_Pos) /*!< SCB CPUID: REVISION Mask */ + +/* SCB Interrupt Control State Register Definitions */ +#define SCB_ICSR_NMIPENDSET_Pos 31 /*!< SCB ICSR: NMIPENDSET Position */ +#define SCB_ICSR_NMIPENDSET_Msk (1UL << SCB_ICSR_NMIPENDSET_Pos) /*!< SCB ICSR: NMIPENDSET Mask */ + +#define SCB_ICSR_PENDSVSET_Pos 28 /*!< SCB ICSR: PENDSVSET Position */ +#define SCB_ICSR_PENDSVSET_Msk (1UL << SCB_ICSR_PENDSVSET_Pos) /*!< SCB ICSR: PENDSVSET Mask */ + +#define SCB_ICSR_PENDSVCLR_Pos 27 /*!< SCB ICSR: PENDSVCLR Position */ +#define SCB_ICSR_PENDSVCLR_Msk (1UL << SCB_ICSR_PENDSVCLR_Pos) /*!< SCB ICSR: PENDSVCLR Mask */ + +#define SCB_ICSR_PENDSTSET_Pos 26 /*!< SCB ICSR: PENDSTSET Position */ +#define SCB_ICSR_PENDSTSET_Msk (1UL << SCB_ICSR_PENDSTSET_Pos) /*!< SCB ICSR: PENDSTSET Mask */ + +#define SCB_ICSR_PENDSTCLR_Pos 25 /*!< SCB ICSR: PENDSTCLR Position */ +#define SCB_ICSR_PENDSTCLR_Msk (1UL << SCB_ICSR_PENDSTCLR_Pos) /*!< SCB ICSR: PENDSTCLR Mask */ + +#define SCB_ICSR_ISRPREEMPT_Pos 23 /*!< SCB ICSR: ISRPREEMPT Position */ +#define SCB_ICSR_ISRPREEMPT_Msk (1UL << SCB_ICSR_ISRPREEMPT_Pos) /*!< SCB ICSR: ISRPREEMPT Mask */ + +#define SCB_ICSR_ISRPENDING_Pos 22 /*!< SCB ICSR: ISRPENDING Position */ +#define SCB_ICSR_ISRPENDING_Msk (1UL << SCB_ICSR_ISRPENDING_Pos) /*!< SCB ICSR: ISRPENDING Mask */ + +#define SCB_ICSR_VECTPENDING_Pos 12 /*!< SCB ICSR: VECTPENDING Position */ +#define SCB_ICSR_VECTPENDING_Msk (0x1FFUL << SCB_ICSR_VECTPENDING_Pos) /*!< SCB ICSR: VECTPENDING Mask */ + +#define SCB_ICSR_VECTACTIVE_Pos 0 /*!< SCB ICSR: VECTACTIVE Position */ +#define SCB_ICSR_VECTACTIVE_Msk (0x1FFUL << SCB_ICSR_VECTACTIVE_Pos) /*!< SCB ICSR: VECTACTIVE Mask */ + +#if (__VTOR_PRESENT == 1) +/* SCB Interrupt Control State Register Definitions */ +#define SCB_VTOR_TBLOFF_Pos 7 /*!< SCB VTOR: TBLOFF Position */ +#define SCB_VTOR_TBLOFF_Msk (0x1FFFFFFUL << SCB_VTOR_TBLOFF_Pos) /*!< SCB VTOR: TBLOFF Mask */ +#endif + +/* SCB Application Interrupt and Reset Control Register Definitions */ +#define SCB_AIRCR_VECTKEY_Pos 16 /*!< SCB AIRCR: VECTKEY Position */ +#define SCB_AIRCR_VECTKEY_Msk (0xFFFFUL << SCB_AIRCR_VECTKEY_Pos) /*!< SCB AIRCR: VECTKEY Mask */ + +#define SCB_AIRCR_VECTKEYSTAT_Pos 16 /*!< SCB AIRCR: VECTKEYSTAT Position */ +#define SCB_AIRCR_VECTKEYSTAT_Msk (0xFFFFUL << SCB_AIRCR_VECTKEYSTAT_Pos) /*!< SCB AIRCR: VECTKEYSTAT Mask */ + +#define SCB_AIRCR_ENDIANESS_Pos 15 /*!< SCB AIRCR: ENDIANESS Position */ +#define SCB_AIRCR_ENDIANESS_Msk (1UL << SCB_AIRCR_ENDIANESS_Pos) /*!< SCB AIRCR: ENDIANESS Mask */ + +#define SCB_AIRCR_SYSRESETREQ_Pos 2 /*!< SCB AIRCR: SYSRESETREQ Position */ +#define SCB_AIRCR_SYSRESETREQ_Msk (1UL << SCB_AIRCR_SYSRESETREQ_Pos) /*!< SCB AIRCR: SYSRESETREQ Mask */ + +#define SCB_AIRCR_VECTCLRACTIVE_Pos 1 /*!< SCB AIRCR: VECTCLRACTIVE Position */ +#define SCB_AIRCR_VECTCLRACTIVE_Msk (1UL << SCB_AIRCR_VECTCLRACTIVE_Pos) /*!< SCB AIRCR: VECTCLRACTIVE Mask */ + +/* SCB System Control Register Definitions */ +#define SCB_SCR_SEVONPEND_Pos 4 /*!< SCB SCR: SEVONPEND Position */ +#define SCB_SCR_SEVONPEND_Msk (1UL << SCB_SCR_SEVONPEND_Pos) /*!< SCB SCR: SEVONPEND Mask */ + +#define SCB_SCR_SLEEPDEEP_Pos 2 /*!< SCB SCR: SLEEPDEEP Position */ +#define SCB_SCR_SLEEPDEEP_Msk (1UL << SCB_SCR_SLEEPDEEP_Pos) /*!< SCB SCR: SLEEPDEEP Mask */ + +#define SCB_SCR_SLEEPONEXIT_Pos 1 /*!< SCB SCR: SLEEPONEXIT Position */ +#define SCB_SCR_SLEEPONEXIT_Msk (1UL << SCB_SCR_SLEEPONEXIT_Pos) /*!< SCB SCR: SLEEPONEXIT Mask */ + +/* SCB Configuration Control Register Definitions */ +#define SCB_CCR_STKALIGN_Pos 9 /*!< SCB CCR: STKALIGN Position */ +#define SCB_CCR_STKALIGN_Msk (1UL << SCB_CCR_STKALIGN_Pos) /*!< SCB CCR: STKALIGN Mask */ + +#define SCB_CCR_UNALIGN_TRP_Pos 3 /*!< SCB CCR: UNALIGN_TRP Position */ +#define SCB_CCR_UNALIGN_TRP_Msk (1UL << SCB_CCR_UNALIGN_TRP_Pos) /*!< SCB CCR: UNALIGN_TRP Mask */ + +/* SCB System Handler Control and State Register Definitions */ +#define SCB_SHCSR_SVCALLPENDED_Pos 15 /*!< SCB SHCSR: SVCALLPENDED Position */ +#define SCB_SHCSR_SVCALLPENDED_Msk (1UL << SCB_SHCSR_SVCALLPENDED_Pos) /*!< SCB SHCSR: SVCALLPENDED Mask */ + +/*@} end of group CMSIS_SCB */ + + +/** \ingroup CMSIS_core_register + \defgroup CMSIS_SysTick System Tick Timer (SysTick) + \brief Type definitions for the System Timer Registers. + @{ + */ + +/** \brief Structure type to access the System Timer (SysTick). + */ +typedef struct +{ + __IO uint32_t CTRL; /*!< Offset: 0x000 (R/W) SysTick Control and Status Register */ + __IO uint32_t LOAD; /*!< Offset: 0x004 (R/W) SysTick Reload Value Register */ + __IO uint32_t VAL; /*!< Offset: 0x008 (R/W) SysTick Current Value Register */ + __I uint32_t CALIB; /*!< Offset: 0x00C (R/ ) SysTick Calibration Register */ +} SysTick_Type; + +/* SysTick Control / Status Register Definitions */ +#define SysTick_CTRL_COUNTFLAG_Pos 16 /*!< SysTick CTRL: COUNTFLAG Position */ +#define SysTick_CTRL_COUNTFLAG_Msk (1UL << SysTick_CTRL_COUNTFLAG_Pos) /*!< SysTick CTRL: COUNTFLAG Mask */ + +#define SysTick_CTRL_CLKSOURCE_Pos 2 /*!< SysTick CTRL: CLKSOURCE Position */ +#define SysTick_CTRL_CLKSOURCE_Msk (1UL << SysTick_CTRL_CLKSOURCE_Pos) /*!< SysTick CTRL: CLKSOURCE Mask */ + +#define SysTick_CTRL_TICKINT_Pos 1 /*!< SysTick CTRL: TICKINT Position */ +#define SysTick_CTRL_TICKINT_Msk (1UL << SysTick_CTRL_TICKINT_Pos) /*!< SysTick CTRL: TICKINT Mask */ + +#define SysTick_CTRL_ENABLE_Pos 0 /*!< SysTick CTRL: ENABLE Position */ +#define SysTick_CTRL_ENABLE_Msk (1UL << SysTick_CTRL_ENABLE_Pos) /*!< SysTick CTRL: ENABLE Mask */ + +/* SysTick Reload Register Definitions */ +#define SysTick_LOAD_RELOAD_Pos 0 /*!< SysTick LOAD: RELOAD Position */ +#define SysTick_LOAD_RELOAD_Msk (0xFFFFFFUL << SysTick_LOAD_RELOAD_Pos) /*!< SysTick LOAD: RELOAD Mask */ + +/* SysTick Current Register Definitions */ +#define SysTick_VAL_CURRENT_Pos 0 /*!< SysTick VAL: CURRENT Position */ +#define SysTick_VAL_CURRENT_Msk (0xFFFFFFUL << SysTick_VAL_CURRENT_Pos) /*!< SysTick VAL: CURRENT Mask */ + +/* SysTick Calibration Register Definitions */ +#define SysTick_CALIB_NOREF_Pos 31 /*!< SysTick CALIB: NOREF Position */ +#define SysTick_CALIB_NOREF_Msk (1UL << SysTick_CALIB_NOREF_Pos) /*!< SysTick CALIB: NOREF Mask */ + +#define SysTick_CALIB_SKEW_Pos 30 /*!< SysTick CALIB: SKEW Position */ +#define SysTick_CALIB_SKEW_Msk (1UL << SysTick_CALIB_SKEW_Pos) /*!< SysTick CALIB: SKEW Mask */ + +#define SysTick_CALIB_TENMS_Pos 0 /*!< SysTick CALIB: TENMS Position */ +#define SysTick_CALIB_TENMS_Msk (0xFFFFFFUL << SysTick_VAL_CURRENT_Pos) /*!< SysTick CALIB: TENMS Mask */ + +/*@} end of group CMSIS_SysTick */ + +#if (__MPU_PRESENT == 1) +/** \ingroup CMSIS_core_register + \defgroup CMSIS_MPU Memory Protection Unit (MPU) + \brief Type definitions for the Memory Protection Unit (MPU) + @{ + */ + +/** \brief Structure type to access the Memory Protection Unit (MPU). + */ +typedef struct +{ + __I uint32_t TYPE; /*!< Offset: 0x000 (R/ ) MPU Type Register */ + __IO uint32_t CTRL; /*!< Offset: 0x004 (R/W) MPU Control Register */ + __IO uint32_t RNR; /*!< Offset: 0x008 (R/W) MPU Region RNRber Register */ + __IO uint32_t RBAR; /*!< Offset: 0x00C (R/W) MPU Region Base Address Register */ + __IO uint32_t RASR; /*!< Offset: 0x010 (R/W) MPU Region Attribute and Size Register */ +} MPU_Type; + +/* MPU Type Register */ +#define MPU_TYPE_IREGION_Pos 16 /*!< MPU TYPE: IREGION Position */ +#define MPU_TYPE_IREGION_Msk (0xFFUL << MPU_TYPE_IREGION_Pos) /*!< MPU TYPE: IREGION Mask */ + +#define MPU_TYPE_DREGION_Pos 8 /*!< MPU TYPE: DREGION Position */ +#define MPU_TYPE_DREGION_Msk (0xFFUL << MPU_TYPE_DREGION_Pos) /*!< MPU TYPE: DREGION Mask */ + +#define MPU_TYPE_SEPARATE_Pos 0 /*!< MPU TYPE: SEPARATE Position */ +#define MPU_TYPE_SEPARATE_Msk (1UL << MPU_TYPE_SEPARATE_Pos) /*!< MPU TYPE: SEPARATE Mask */ + +/* MPU Control Register */ +#define MPU_CTRL_PRIVDEFENA_Pos 2 /*!< MPU CTRL: PRIVDEFENA Position */ +#define MPU_CTRL_PRIVDEFENA_Msk (1UL << MPU_CTRL_PRIVDEFENA_Pos) /*!< MPU CTRL: PRIVDEFENA Mask */ + +#define MPU_CTRL_HFNMIENA_Pos 1 /*!< MPU CTRL: HFNMIENA Position */ +#define MPU_CTRL_HFNMIENA_Msk (1UL << MPU_CTRL_HFNMIENA_Pos) /*!< MPU CTRL: HFNMIENA Mask */ + +#define MPU_CTRL_ENABLE_Pos 0 /*!< MPU CTRL: ENABLE Position */ +#define MPU_CTRL_ENABLE_Msk (1UL << MPU_CTRL_ENABLE_Pos) /*!< MPU CTRL: ENABLE Mask */ + +/* MPU Region Number Register */ +#define MPU_RNR_REGION_Pos 0 /*!< MPU RNR: REGION Position */ +#define MPU_RNR_REGION_Msk (0xFFUL << MPU_RNR_REGION_Pos) /*!< MPU RNR: REGION Mask */ + +/* MPU Region Base Address Register */ +#define MPU_RBAR_ADDR_Pos 8 /*!< MPU RBAR: ADDR Position */ +#define MPU_RBAR_ADDR_Msk (0xFFFFFFUL << MPU_RBAR_ADDR_Pos) /*!< MPU RBAR: ADDR Mask */ + +#define MPU_RBAR_VALID_Pos 4 /*!< MPU RBAR: VALID Position */ +#define MPU_RBAR_VALID_Msk (1UL << MPU_RBAR_VALID_Pos) /*!< MPU RBAR: VALID Mask */ + +#define MPU_RBAR_REGION_Pos 0 /*!< MPU RBAR: REGION Position */ +#define MPU_RBAR_REGION_Msk (0xFUL << MPU_RBAR_REGION_Pos) /*!< MPU RBAR: REGION Mask */ + +/* MPU Region Attribute and Size Register */ +#define MPU_RASR_ATTRS_Pos 16 /*!< MPU RASR: MPU Region Attribute field Position */ +#define MPU_RASR_ATTRS_Msk (0xFFFFUL << MPU_RASR_ATTRS_Pos) /*!< MPU RASR: MPU Region Attribute field Mask */ + +#define MPU_RASR_XN_Pos 28 /*!< MPU RASR: ATTRS.XN Position */ +#define MPU_RASR_XN_Msk (1UL << MPU_RASR_XN_Pos) /*!< MPU RASR: ATTRS.XN Mask */ + +#define MPU_RASR_AP_Pos 24 /*!< MPU RASR: ATTRS.AP Position */ +#define MPU_RASR_AP_Msk (0x7UL << MPU_RASR_AP_Pos) /*!< MPU RASR: ATTRS.AP Mask */ + +#define MPU_RASR_TEX_Pos 19 /*!< MPU RASR: ATTRS.TEX Position */ +#define MPU_RASR_TEX_Msk (0x7UL << MPU_RASR_TEX_Pos) /*!< MPU RASR: ATTRS.TEX Mask */ + +#define MPU_RASR_S_Pos 18 /*!< MPU RASR: ATTRS.S Position */ +#define MPU_RASR_S_Msk (1UL << MPU_RASR_S_Pos) /*!< MPU RASR: ATTRS.S Mask */ + +#define MPU_RASR_C_Pos 17 /*!< MPU RASR: ATTRS.C Position */ +#define MPU_RASR_C_Msk (1UL << MPU_RASR_C_Pos) /*!< MPU RASR: ATTRS.C Mask */ + +#define MPU_RASR_B_Pos 16 /*!< MPU RASR: ATTRS.B Position */ +#define MPU_RASR_B_Msk (1UL << MPU_RASR_B_Pos) /*!< MPU RASR: ATTRS.B Mask */ + +#define MPU_RASR_SRD_Pos 8 /*!< MPU RASR: Sub-Region Disable Position */ +#define MPU_RASR_SRD_Msk (0xFFUL << MPU_RASR_SRD_Pos) /*!< MPU RASR: Sub-Region Disable Mask */ + +#define MPU_RASR_SIZE_Pos 1 /*!< MPU RASR: Region Size Field Position */ +#define MPU_RASR_SIZE_Msk (0x1FUL << MPU_RASR_SIZE_Pos) /*!< MPU RASR: Region Size Field Mask */ + +#define MPU_RASR_ENABLE_Pos 0 /*!< MPU RASR: Region enable bit Position */ +#define MPU_RASR_ENABLE_Msk (1UL << MPU_RASR_ENABLE_Pos) /*!< MPU RASR: Region enable bit Disable Mask */ + +/*@} end of group CMSIS_MPU */ +#endif + + +/** \ingroup CMSIS_core_register + \defgroup CMSIS_CoreDebug Core Debug Registers (CoreDebug) + \brief Cortex-M0+ Core Debug Registers (DCB registers, SHCSR, and DFSR) + are only accessible over DAP and not via processor. Therefore + they are not covered by the Cortex-M0 header file. + @{ + */ +/*@} end of group CMSIS_CoreDebug */ + + +/** \ingroup CMSIS_core_register + \defgroup CMSIS_core_base Core Definitions + \brief Definitions for base addresses, unions, and structures. + @{ + */ + +/* Memory mapping of Cortex-M0+ Hardware */ +#define SCS_BASE (0xE000E000UL) /*!< System Control Space Base Address */ +#define SysTick_BASE (SCS_BASE + 0x0010UL) /*!< SysTick Base Address */ +#define NVIC_BASE (SCS_BASE + 0x0100UL) /*!< NVIC Base Address */ +#define SCB_BASE (SCS_BASE + 0x0D00UL) /*!< System Control Block Base Address */ + +#define SCB ((SCB_Type *) SCB_BASE ) /*!< SCB configuration struct */ +#define SysTick ((SysTick_Type *) SysTick_BASE ) /*!< SysTick configuration struct */ +#define NVIC ((NVIC_Type *) NVIC_BASE ) /*!< NVIC configuration struct */ + +#if (__MPU_PRESENT == 1) + #define MPU_BASE (SCS_BASE + 0x0D90UL) /*!< Memory Protection Unit */ + #define MPU ((MPU_Type *) MPU_BASE ) /*!< Memory Protection Unit */ +#endif + +/*@} */ + + + +/******************************************************************************* + * Hardware Abstraction Layer + Core Function Interface contains: + - Core NVIC Functions + - Core SysTick Functions + - Core Register Access Functions + ******************************************************************************/ +/** \defgroup CMSIS_Core_FunctionInterface Functions and Instructions Reference +*/ + + + +/* ########################## NVIC functions #################################### */ +/** \ingroup CMSIS_Core_FunctionInterface + \defgroup CMSIS_Core_NVICFunctions NVIC Functions + \brief Functions that manage interrupts and exceptions via the NVIC. + @{ + */ + +/* Interrupt Priorities are WORD accessible only under ARMv6M */ +/* The following MACROS handle generation of the register offset and byte masks */ +#define _BIT_SHIFT(IRQn) ( (((uint32_t)(IRQn) ) & 0x03) * 8 ) +#define _SHP_IDX(IRQn) ( ((((uint32_t)(IRQn) & 0x0F)-8) >> 2) ) +#define _IP_IDX(IRQn) ( ((uint32_t)(IRQn) >> 2) ) + + +/** \brief Enable External Interrupt + + The function enables a device-specific interrupt in the NVIC interrupt controller. + + \param [in] IRQn External interrupt number. Value cannot be negative. + */ +__STATIC_INLINE void NVIC_EnableIRQ(IRQn_Type IRQn) +{ + NVIC->ISER[0] = (1 << ((uint32_t)(IRQn) & 0x1F)); +} + + +/** \brief Disable External Interrupt + + The function disables a device-specific interrupt in the NVIC interrupt controller. + + \param [in] IRQn External interrupt number. Value cannot be negative. + */ +__STATIC_INLINE void NVIC_DisableIRQ(IRQn_Type IRQn) +{ + NVIC->ICER[0] = (1 << ((uint32_t)(IRQn) & 0x1F)); +} + + +/** \brief Get Pending Interrupt + + The function reads the pending register in the NVIC and returns the pending bit + for the specified interrupt. + + \param [in] IRQn Interrupt number. + + \return 0 Interrupt status is not pending. + \return 1 Interrupt status is pending. + */ +__STATIC_INLINE uint32_t NVIC_GetPendingIRQ(IRQn_Type IRQn) +{ + return((uint32_t) ((NVIC->ISPR[0] & (1 << ((uint32_t)(IRQn) & 0x1F)))?1:0)); +} + + +/** \brief Set Pending Interrupt + + The function sets the pending bit of an external interrupt. + + \param [in] IRQn Interrupt number. Value cannot be negative. + */ +__STATIC_INLINE void NVIC_SetPendingIRQ(IRQn_Type IRQn) +{ + NVIC->ISPR[0] = (1 << ((uint32_t)(IRQn) & 0x1F)); +} + + +/** \brief Clear Pending Interrupt + + The function clears the pending bit of an external interrupt. + + \param [in] IRQn External interrupt number. Value cannot be negative. + */ +__STATIC_INLINE void NVIC_ClearPendingIRQ(IRQn_Type IRQn) +{ + NVIC->ICPR[0] = (1 << ((uint32_t)(IRQn) & 0x1F)); /* Clear pending interrupt */ +} + + +/** \brief Set Interrupt Priority + + The function sets the priority of an interrupt. + + \note The priority cannot be set for every core interrupt. + + \param [in] IRQn Interrupt number. + \param [in] priority Priority to set. + */ +__STATIC_INLINE void NVIC_SetPriority(IRQn_Type IRQn, uint32_t priority) +{ + if(IRQn < 0) { + SCB->SHP[_SHP_IDX(IRQn)] = (SCB->SHP[_SHP_IDX(IRQn)] & ~(0xFF << _BIT_SHIFT(IRQn))) | + (((priority << (8 - __NVIC_PRIO_BITS)) & 0xFF) << _BIT_SHIFT(IRQn)); } + else { + NVIC->IP[_IP_IDX(IRQn)] = (NVIC->IP[_IP_IDX(IRQn)] & ~(0xFF << _BIT_SHIFT(IRQn))) | + (((priority << (8 - __NVIC_PRIO_BITS)) & 0xFF) << _BIT_SHIFT(IRQn)); } +} + + +/** \brief Get Interrupt Priority + + The function reads the priority of an interrupt. The interrupt + number can be positive to specify an external (device specific) + interrupt, or negative to specify an internal (core) interrupt. + + + \param [in] IRQn Interrupt number. + \return Interrupt Priority. Value is aligned automatically to the implemented + priority bits of the microcontroller. + */ +__STATIC_INLINE uint32_t NVIC_GetPriority(IRQn_Type IRQn) +{ + + if(IRQn < 0) { + return((uint32_t)((SCB->SHP[_SHP_IDX(IRQn)] >> _BIT_SHIFT(IRQn) ) >> (8 - __NVIC_PRIO_BITS))); } /* get priority for Cortex-M0+ system interrupts */ + else { + return((uint32_t)((NVIC->IP[ _IP_IDX(IRQn)] >> _BIT_SHIFT(IRQn) ) >> (8 - __NVIC_PRIO_BITS))); } /* get priority for device specific interrupts */ +} + + +/** \brief System Reset + + The function initiates a system reset request to reset the MCU. + */ +__STATIC_INLINE void NVIC_SystemReset(void) +{ + __DSB(); /* Ensure all outstanding memory accesses included + buffered write are completed before reset */ + SCB->AIRCR = ((0x5FA << SCB_AIRCR_VECTKEY_Pos) | + SCB_AIRCR_SYSRESETREQ_Msk); + __DSB(); /* Ensure completion of memory access */ + while(1); /* wait until reset */ +} + +/*@} end of CMSIS_Core_NVICFunctions */ + + + +/* ################################## SysTick function ############################################ */ +/** \ingroup CMSIS_Core_FunctionInterface + \defgroup CMSIS_Core_SysTickFunctions SysTick Functions + \brief Functions that configure the System. + @{ + */ + +#if (__Vendor_SysTickConfig == 0) + +/** \brief System Tick Configuration + + The function initializes the System Timer and its interrupt, and starts the System Tick Timer. + Counter is in free running mode to generate periodic interrupts. + + \param [in] ticks Number of ticks between two interrupts. + + \return 0 Function succeeded. + \return 1 Function failed. + + \note When the variable __Vendor_SysTickConfig is set to 1, then the + function SysTick_Config is not included. In this case, the file device.h + must contain a vendor-specific implementation of this function. + + */ +__STATIC_INLINE uint32_t SysTick_Config(uint32_t ticks) +{ + if (ticks > SysTick_LOAD_RELOAD_Msk) return (1); /* Reload value impossible */ + + SysTick->LOAD = (ticks & SysTick_LOAD_RELOAD_Msk) - 1; /* set reload register */ + NVIC_SetPriority (SysTick_IRQn, (1<<__NVIC_PRIO_BITS) - 1); /* set Priority for Systick Interrupt */ + SysTick->VAL = 0; /* Load the SysTick Counter Value */ + SysTick->CTRL = SysTick_CTRL_CLKSOURCE_Msk | + SysTick_CTRL_TICKINT_Msk | + SysTick_CTRL_ENABLE_Msk; /* Enable SysTick IRQ and SysTick Timer */ + return (0); /* Function successful */ +} + +#endif + +/*@} end of CMSIS_Core_SysTickFunctions */ + + + + +#endif /* __CORE_CM0PLUS_H_DEPENDANT */ + +#endif /* __CMSIS_GENERIC */ + +#ifdef __cplusplus +} +#endif diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/Include/core_cmFunc.h b/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/Include/core_cmFunc.h new file mode 100644 index 0000000..1991ae3 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/Include/core_cmFunc.h @@ -0,0 +1,616 @@ +/**************************************************************************//** + * @file core_cmFunc.h + * @brief CMSIS Cortex-M Core Function Access Header File + * @version V3.00 + * @date 19. January 2012 + * + * @note + * Copyright (C) 2009-2012 ARM Limited. All rights reserved. + * + * @par + * ARM Limited (ARM) is supplying this software for use with Cortex-M + * processor based microcontrollers. This file can be freely distributed + * within development tools that are supporting such ARM based processors. + * + * @par + * THIS SOFTWARE IS PROVIDED "AS IS". NO WARRANTIES, WHETHER EXPRESS, IMPLIED + * OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE. + * ARM SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR SPECIAL, INCIDENTAL, OR + * CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER. + * + ******************************************************************************/ + +#ifndef __CORE_CMFUNC_H +#define __CORE_CMFUNC_H + + +/* ########################### Core Function Access ########################### */ +/** \ingroup CMSIS_Core_FunctionInterface + \defgroup CMSIS_Core_RegAccFunctions CMSIS Core Register Access Functions + @{ + */ + +#if defined ( __CC_ARM ) /*------------------RealView Compiler -----------------*/ +/* ARM armcc specific functions */ + +#if (__ARMCC_VERSION < 400677) + #error "Please use ARM Compiler Toolchain V4.0.677 or later!" +#endif + +/* intrinsic void __enable_irq(); */ +/* intrinsic void __disable_irq(); */ + +/** \brief Get Control Register + + This function returns the content of the Control Register. + + \return Control Register value + */ +__STATIC_INLINE uint32_t __get_CONTROL(void) +{ + register uint32_t __regControl __ASM("control"); + return(__regControl); +} + + +/** \brief Set Control Register + + This function writes the given value to the Control Register. + + \param [in] control Control Register value to set + */ +__STATIC_INLINE void __set_CONTROL(uint32_t control) +{ + register uint32_t __regControl __ASM("control"); + __regControl = control; +} + + +/** \brief Get IPSR Register + + This function returns the content of the IPSR Register. + + \return IPSR Register value + */ +__STATIC_INLINE uint32_t __get_IPSR(void) +{ + register uint32_t __regIPSR __ASM("ipsr"); + return(__regIPSR); +} + + +/** \brief Get APSR Register + + This function returns the content of the APSR Register. + + \return APSR Register value + */ +__STATIC_INLINE uint32_t __get_APSR(void) +{ + register uint32_t __regAPSR __ASM("apsr"); + return(__regAPSR); +} + + +/** \brief Get xPSR Register + + This function returns the content of the xPSR Register. + + \return xPSR Register value + */ +__STATIC_INLINE uint32_t __get_xPSR(void) +{ + register uint32_t __regXPSR __ASM("xpsr"); + return(__regXPSR); +} + + +/** \brief Get Process Stack Pointer + + This function returns the current value of the Process Stack Pointer (PSP). + + \return PSP Register value + */ +__STATIC_INLINE uint32_t __get_PSP(void) +{ + register uint32_t __regProcessStackPointer __ASM("psp"); + return(__regProcessStackPointer); +} + + +/** \brief Set Process Stack Pointer + + This function assigns the given value to the Process Stack Pointer (PSP). + + \param [in] topOfProcStack Process Stack Pointer value to set + */ +__STATIC_INLINE void __set_PSP(uint32_t topOfProcStack) +{ + register uint32_t __regProcessStackPointer __ASM("psp"); + __regProcessStackPointer = topOfProcStack; +} + + +/** \brief Get Main Stack Pointer + + This function returns the current value of the Main Stack Pointer (MSP). + + \return MSP Register value + */ +__STATIC_INLINE uint32_t __get_MSP(void) +{ + register uint32_t __regMainStackPointer __ASM("msp"); + return(__regMainStackPointer); +} + + +/** \brief Set Main Stack Pointer + + This function assigns the given value to the Main Stack Pointer (MSP). + + \param [in] topOfMainStack Main Stack Pointer value to set + */ +__STATIC_INLINE void __set_MSP(uint32_t topOfMainStack) +{ + register uint32_t __regMainStackPointer __ASM("msp"); + __regMainStackPointer = topOfMainStack; +} + + +/** \brief Get Priority Mask + + This function returns the current state of the priority mask bit from the Priority Mask Register. + + \return Priority Mask value + */ +__STATIC_INLINE uint32_t __get_PRIMASK(void) +{ + register uint32_t __regPriMask __ASM("primask"); + return(__regPriMask); +} + + +/** \brief Set Priority Mask + + This function assigns the given value to the Priority Mask Register. + + \param [in] priMask Priority Mask + */ +__STATIC_INLINE void __set_PRIMASK(uint32_t priMask) +{ + register uint32_t __regPriMask __ASM("primask"); + __regPriMask = (priMask); +} + + +#if (__CORTEX_M >= 0x03) + +/** \brief Enable FIQ + + This function enables FIQ interrupts by clearing the F-bit in the CPSR. + Can only be executed in Privileged modes. + */ +#define __enable_fault_irq __enable_fiq + + +/** \brief Disable FIQ + + This function disables FIQ interrupts by setting the F-bit in the CPSR. + Can only be executed in Privileged modes. + */ +#define __disable_fault_irq __disable_fiq + + +/** \brief Get Base Priority + + This function returns the current value of the Base Priority register. + + \return Base Priority register value + */ +__STATIC_INLINE uint32_t __get_BASEPRI(void) +{ + register uint32_t __regBasePri __ASM("basepri"); + return(__regBasePri); +} + + +/** \brief Set Base Priority + + This function assigns the given value to the Base Priority register. + + \param [in] basePri Base Priority value to set + */ +__STATIC_INLINE void __set_BASEPRI(uint32_t basePri) +{ + register uint32_t __regBasePri __ASM("basepri"); + __regBasePri = (basePri & 0xff); +} + + +/** \brief Get Fault Mask + + This function returns the current value of the Fault Mask register. + + \return Fault Mask register value + */ +__STATIC_INLINE uint32_t __get_FAULTMASK(void) +{ + register uint32_t __regFaultMask __ASM("faultmask"); + return(__regFaultMask); +} + + +/** \brief Set Fault Mask + + This function assigns the given value to the Fault Mask register. + + \param [in] faultMask Fault Mask value to set + */ +__STATIC_INLINE void __set_FAULTMASK(uint32_t faultMask) +{ + register uint32_t __regFaultMask __ASM("faultmask"); + __regFaultMask = (faultMask & (uint32_t)1); +} + +#endif /* (__CORTEX_M >= 0x03) */ + + +#if (__CORTEX_M == 0x04) + +/** \brief Get FPSCR + + This function returns the current value of the Floating Point Status/Control register. + + \return Floating Point Status/Control register value + */ +__STATIC_INLINE uint32_t __get_FPSCR(void) +{ +#if (__FPU_PRESENT == 1) && (__FPU_USED == 1) + register uint32_t __regfpscr __ASM("fpscr"); + return(__regfpscr); +#else + return(0); +#endif +} + + +/** \brief Set FPSCR + + This function assigns the given value to the Floating Point Status/Control register. + + \param [in] fpscr Floating Point Status/Control value to set + */ +__STATIC_INLINE void __set_FPSCR(uint32_t fpscr) +{ +#if (__FPU_PRESENT == 1) && (__FPU_USED == 1) + register uint32_t __regfpscr __ASM("fpscr"); + __regfpscr = (fpscr); +#endif +} + +#endif /* (__CORTEX_M == 0x04) */ + + +#elif defined ( __ICCARM__ ) /*------------------ ICC Compiler -------------------*/ +/* IAR iccarm specific functions */ + +#include + + +#elif defined ( __TMS470__ ) /*---------------- TI CCS Compiler ------------------*/ +/* TI CCS specific functions */ + +#include + + +#elif defined ( __GNUC__ ) /*------------------ GNU Compiler ---------------------*/ +/* GNU gcc specific functions */ + +/** \brief Enable IRQ Interrupts + + This function enables IRQ interrupts by clearing the I-bit in the CPSR. + Can only be executed in Privileged modes. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __enable_irq(void) +{ + __ASM volatile ("cpsie i"); +} + + +/** \brief Disable IRQ Interrupts + + This function disables IRQ interrupts by setting the I-bit in the CPSR. + Can only be executed in Privileged modes. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __disable_irq(void) +{ + __ASM volatile ("cpsid i"); +} + + +/** \brief Get Control Register + + This function returns the content of the Control Register. + + \return Control Register value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_CONTROL(void) +{ + uint32_t result; + + __ASM volatile ("MRS %0, control" : "=r" (result) ); + return(result); +} + + +/** \brief Set Control Register + + This function writes the given value to the Control Register. + + \param [in] control Control Register value to set + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __set_CONTROL(uint32_t control) +{ + __ASM volatile ("MSR control, %0" : : "r" (control) ); +} + + +/** \brief Get IPSR Register + + This function returns the content of the IPSR Register. + + \return IPSR Register value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_IPSR(void) +{ + uint32_t result; + + __ASM volatile ("MRS %0, ipsr" : "=r" (result) ); + return(result); +} + + +/** \brief Get APSR Register + + This function returns the content of the APSR Register. + + \return APSR Register value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_APSR(void) +{ + uint32_t result; + + __ASM volatile ("MRS %0, apsr" : "=r" (result) ); + return(result); +} + + +/** \brief Get xPSR Register + + This function returns the content of the xPSR Register. + + \return xPSR Register value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_xPSR(void) +{ + uint32_t result; + + __ASM volatile ("MRS %0, xpsr" : "=r" (result) ); + return(result); +} + + +/** \brief Get Process Stack Pointer + + This function returns the current value of the Process Stack Pointer (PSP). + + \return PSP Register value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_PSP(void) +{ + register uint32_t result; + + __ASM volatile ("MRS %0, psp\n" : "=r" (result) ); + return(result); +} + + +/** \brief Set Process Stack Pointer + + This function assigns the given value to the Process Stack Pointer (PSP). + + \param [in] topOfProcStack Process Stack Pointer value to set + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __set_PSP(uint32_t topOfProcStack) +{ + __ASM volatile ("MSR psp, %0\n" : : "r" (topOfProcStack) ); +} + + +/** \brief Get Main Stack Pointer + + This function returns the current value of the Main Stack Pointer (MSP). + + \return MSP Register value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_MSP(void) +{ + register uint32_t result; + + __ASM volatile ("MRS %0, msp\n" : "=r" (result) ); + return(result); +} + + +/** \brief Set Main Stack Pointer + + This function assigns the given value to the Main Stack Pointer (MSP). + + \param [in] topOfMainStack Main Stack Pointer value to set + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __set_MSP(uint32_t topOfMainStack) +{ + __ASM volatile ("MSR msp, %0\n" : : "r" (topOfMainStack) ); +} + + +/** \brief Get Priority Mask + + This function returns the current state of the priority mask bit from the Priority Mask Register. + + \return Priority Mask value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_PRIMASK(void) +{ + uint32_t result; + + __ASM volatile ("MRS %0, primask" : "=r" (result) ); + return(result); +} + + +/** \brief Set Priority Mask + + This function assigns the given value to the Priority Mask Register. + + \param [in] priMask Priority Mask + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __set_PRIMASK(uint32_t priMask) +{ + __ASM volatile ("MSR primask, %0" : : "r" (priMask) ); +} + + +#if (__CORTEX_M >= 0x03) + +/** \brief Enable FIQ + + This function enables FIQ interrupts by clearing the F-bit in the CPSR. + Can only be executed in Privileged modes. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __enable_fault_irq(void) +{ + __ASM volatile ("cpsie f"); +} + + +/** \brief Disable FIQ + + This function disables FIQ interrupts by setting the F-bit in the CPSR. + Can only be executed in Privileged modes. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __disable_fault_irq(void) +{ + __ASM volatile ("cpsid f"); +} + + +/** \brief Get Base Priority + + This function returns the current value of the Base Priority register. + + \return Base Priority register value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_BASEPRI(void) +{ + uint32_t result; + + __ASM volatile ("MRS %0, basepri_max" : "=r" (result) ); + return(result); +} + + +/** \brief Set Base Priority + + This function assigns the given value to the Base Priority register. + + \param [in] basePri Base Priority value to set + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __set_BASEPRI(uint32_t value) +{ + __ASM volatile ("MSR basepri, %0" : : "r" (value) ); +} + + +/** \brief Get Fault Mask + + This function returns the current value of the Fault Mask register. + + \return Fault Mask register value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_FAULTMASK(void) +{ + uint32_t result; + + __ASM volatile ("MRS %0, faultmask" : "=r" (result) ); + return(result); +} + + +/** \brief Set Fault Mask + + This function assigns the given value to the Fault Mask register. + + \param [in] faultMask Fault Mask value to set + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __set_FAULTMASK(uint32_t faultMask) +{ + __ASM volatile ("MSR faultmask, %0" : : "r" (faultMask) ); +} + +#endif /* (__CORTEX_M >= 0x03) */ + + +#if (__CORTEX_M == 0x04) + +/** \brief Get FPSCR + + This function returns the current value of the Floating Point Status/Control register. + + \return Floating Point Status/Control register value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_FPSCR(void) +{ +#if (__FPU_PRESENT == 1) && (__FPU_USED == 1) + uint32_t result; + + __ASM volatile ("VMRS %0, fpscr" : "=r" (result) ); + return(result); +#else + return(0); +#endif +} + + +/** \brief Set FPSCR + + This function assigns the given value to the Floating Point Status/Control register. + + \param [in] fpscr Floating Point Status/Control value to set + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __set_FPSCR(uint32_t fpscr) +{ +#if (__FPU_PRESENT == 1) && (__FPU_USED == 1) + __ASM volatile ("VMSR fpscr, %0" : : "r" (fpscr) ); +#endif +} + +#endif /* (__CORTEX_M == 0x04) */ + + +#elif defined ( __TASKING__ ) /*------------------ TASKING Compiler --------------*/ +/* TASKING carm specific functions */ + +/* + * The CMSIS functions have been implemented as intrinsics in the compiler. + * Please use "carm -?i" to get an up to date list of all instrinsics, + * Including the CMSIS ones. + */ + +#endif + +/*@} end of CMSIS_Core_RegAccFunctions */ + + +#endif /* __CORE_CMFUNC_H */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/Include/core_cmInstr.h b/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/Include/core_cmInstr.h new file mode 100644 index 0000000..7981634 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/Include/core_cmInstr.h @@ -0,0 +1,618 @@ +/**************************************************************************//** + * @file core_cmInstr.h + * @brief CMSIS Cortex-M Core Instruction Access Header File + * @version V3.00 + * @date 07. February 2012 + * + * @note + * Copyright (C) 2009-2012 ARM Limited. All rights reserved. + * + * @par + * ARM Limited (ARM) is supplying this software for use with Cortex-M + * processor based microcontrollers. This file can be freely distributed + * within development tools that are supporting such ARM based processors. + * + * @par + * THIS SOFTWARE IS PROVIDED "AS IS". NO WARRANTIES, WHETHER EXPRESS, IMPLIED + * OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE. + * ARM SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR SPECIAL, INCIDENTAL, OR + * CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER. + * + ******************************************************************************/ + +#ifndef __CORE_CMINSTR_H +#define __CORE_CMINSTR_H + + +/* ########################## Core Instruction Access ######################### */ +/** \defgroup CMSIS_Core_InstructionInterface CMSIS Core Instruction Interface + Access to dedicated instructions + @{ +*/ + +#if defined ( __CC_ARM ) /*------------------RealView Compiler -----------------*/ +/* ARM armcc specific functions */ + +#if (__ARMCC_VERSION < 400677) + #error "Please use ARM Compiler Toolchain V4.0.677 or later!" +#endif + + +/** \brief No Operation + + No Operation does nothing. This instruction can be used for code alignment purposes. + */ +#define __NOP __nop + + +/** \brief Wait For Interrupt + + Wait For Interrupt is a hint instruction that suspends execution + until one of a number of events occurs. + */ +#define __WFI __wfi + + +/** \brief Wait For Event + + Wait For Event is a hint instruction that permits the processor to enter + a low-power state until one of a number of events occurs. + */ +#define __WFE __wfe + + +/** \brief Send Event + + Send Event is a hint instruction. It causes an event to be signaled to the CPU. + */ +#define __SEV __sev + + +/** \brief Instruction Synchronization Barrier + + Instruction Synchronization Barrier flushes the pipeline in the processor, + so that all instructions following the ISB are fetched from cache or + memory, after the instruction has been completed. + */ +#define __ISB() __isb(0xF) + + +/** \brief Data Synchronization Barrier + + This function acts as a special kind of Data Memory Barrier. + It completes when all explicit memory accesses before this instruction complete. + */ +#define __DSB() __dsb(0xF) + + +/** \brief Data Memory Barrier + + This function ensures the apparent order of the explicit memory operations before + and after the instruction, without ensuring their completion. + */ +#define __DMB() __dmb(0xF) + + +/** \brief Reverse byte order (32 bit) + + This function reverses the byte order in integer value. + + \param [in] value Value to reverse + \return Reversed value + */ +#define __REV __rev + + +/** \brief Reverse byte order (16 bit) + + This function reverses the byte order in two unsigned short values. + + \param [in] value Value to reverse + \return Reversed value + */ +__attribute__((section(".rev16_text"))) __STATIC_INLINE __ASM uint32_t __REV16(uint32_t value) +{ + rev16 r0, r0 + bx lr +} + + +/** \brief Reverse byte order in signed short value + + This function reverses the byte order in a signed short value with sign extension to integer. + + \param [in] value Value to reverse + \return Reversed value + */ +__attribute__((section(".revsh_text"))) __STATIC_INLINE __ASM int32_t __REVSH(int32_t value) +{ + revsh r0, r0 + bx lr +} + + +/** \brief Rotate Right in unsigned value (32 bit) + + This function Rotate Right (immediate) provides the value of the contents of a register rotated by a variable number of bits. + + \param [in] value Value to rotate + \param [in] value Number of Bits to rotate + \return Rotated value + */ +#define __ROR __ror + + +#if (__CORTEX_M >= 0x03) + +/** \brief Reverse bit order of value + + This function reverses the bit order of the given value. + + \param [in] value Value to reverse + \return Reversed value + */ +#define __RBIT __rbit + + +/** \brief LDR Exclusive (8 bit) + + This function performs a exclusive LDR command for 8 bit value. + + \param [in] ptr Pointer to data + \return value of type uint8_t at (*ptr) + */ +#define __LDREXB(ptr) ((uint8_t ) __ldrex(ptr)) + + +/** \brief LDR Exclusive (16 bit) + + This function performs a exclusive LDR command for 16 bit values. + + \param [in] ptr Pointer to data + \return value of type uint16_t at (*ptr) + */ +#define __LDREXH(ptr) ((uint16_t) __ldrex(ptr)) + + +/** \brief LDR Exclusive (32 bit) + + This function performs a exclusive LDR command for 32 bit values. + + \param [in] ptr Pointer to data + \return value of type uint32_t at (*ptr) + */ +#define __LDREXW(ptr) ((uint32_t ) __ldrex(ptr)) + + +/** \brief STR Exclusive (8 bit) + + This function performs a exclusive STR command for 8 bit values. + + \param [in] value Value to store + \param [in] ptr Pointer to location + \return 0 Function succeeded + \return 1 Function failed + */ +#define __STREXB(value, ptr) __strex(value, ptr) + + +/** \brief STR Exclusive (16 bit) + + This function performs a exclusive STR command for 16 bit values. + + \param [in] value Value to store + \param [in] ptr Pointer to location + \return 0 Function succeeded + \return 1 Function failed + */ +#define __STREXH(value, ptr) __strex(value, ptr) + + +/** \brief STR Exclusive (32 bit) + + This function performs a exclusive STR command for 32 bit values. + + \param [in] value Value to store + \param [in] ptr Pointer to location + \return 0 Function succeeded + \return 1 Function failed + */ +#define __STREXW(value, ptr) __strex(value, ptr) + + +/** \brief Remove the exclusive lock + + This function removes the exclusive lock which is created by LDREX. + + */ +#define __CLREX __clrex + + +/** \brief Signed Saturate + + This function saturates a signed value. + + \param [in] value Value to be saturated + \param [in] sat Bit position to saturate to (1..32) + \return Saturated value + */ +#define __SSAT __ssat + + +/** \brief Unsigned Saturate + + This function saturates an unsigned value. + + \param [in] value Value to be saturated + \param [in] sat Bit position to saturate to (0..31) + \return Saturated value + */ +#define __USAT __usat + + +/** \brief Count leading zeros + + This function counts the number of leading zeros of a data value. + + \param [in] value Value to count the leading zeros + \return number of leading zeros in value + */ +#define __CLZ __clz + +#endif /* (__CORTEX_M >= 0x03) */ + + + +#elif defined ( __ICCARM__ ) /*------------------ ICC Compiler -------------------*/ +/* IAR iccarm specific functions */ + +#include + + +#elif defined ( __TMS470__ ) /*---------------- TI CCS Compiler ------------------*/ +/* TI CCS specific functions */ + +#include + + +#elif defined ( __GNUC__ ) /*------------------ GNU Compiler ---------------------*/ +/* GNU gcc specific functions */ + +/** \brief No Operation + + No Operation does nothing. This instruction can be used for code alignment purposes. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __NOP(void) +{ + __ASM volatile ("nop"); +} + + +/** \brief Wait For Interrupt + + Wait For Interrupt is a hint instruction that suspends execution + until one of a number of events occurs. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __WFI(void) +{ + __ASM volatile ("wfi"); +} + + +/** \brief Wait For Event + + Wait For Event is a hint instruction that permits the processor to enter + a low-power state until one of a number of events occurs. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __WFE(void) +{ + __ASM volatile ("wfe"); +} + + +/** \brief Send Event + + Send Event is a hint instruction. It causes an event to be signaled to the CPU. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __SEV(void) +{ + __ASM volatile ("sev"); +} + + +/** \brief Instruction Synchronization Barrier + + Instruction Synchronization Barrier flushes the pipeline in the processor, + so that all instructions following the ISB are fetched from cache or + memory, after the instruction has been completed. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __ISB(void) +{ + __ASM volatile ("isb"); +} + + +/** \brief Data Synchronization Barrier + + This function acts as a special kind of Data Memory Barrier. + It completes when all explicit memory accesses before this instruction complete. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __DSB(void) +{ + __ASM volatile ("dsb"); +} + + +/** \brief Data Memory Barrier + + This function ensures the apparent order of the explicit memory operations before + and after the instruction, without ensuring their completion. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __DMB(void) +{ + __ASM volatile ("dmb"); +} + + +/** \brief Reverse byte order (32 bit) + + This function reverses the byte order in integer value. + + \param [in] value Value to reverse + \return Reversed value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __REV(uint32_t value) +{ + uint32_t result; + + __ASM volatile ("rev %0, %1" : "=r" (result) : "r" (value) ); + return(result); +} + + +/** \brief Reverse byte order (16 bit) + + This function reverses the byte order in two unsigned short values. + + \param [in] value Value to reverse + \return Reversed value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __REV16(uint32_t value) +{ + uint32_t result; + + __ASM volatile ("rev16 %0, %1" : "=r" (result) : "r" (value) ); + return(result); +} + + +/** \brief Reverse byte order in signed short value + + This function reverses the byte order in a signed short value with sign extension to integer. + + \param [in] value Value to reverse + \return Reversed value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE int32_t __REVSH(int32_t value) +{ + uint32_t result; + + __ASM volatile ("revsh %0, %1" : "=r" (result) : "r" (value) ); + return(result); +} + + +/** \brief Rotate Right in unsigned value (32 bit) + + This function Rotate Right (immediate) provides the value of the contents of a register rotated by a variable number of bits. + + \param [in] value Value to rotate + \param [in] value Number of Bits to rotate + \return Rotated value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __ROR(uint32_t op1, uint32_t op2) +{ + + __ASM volatile ("ror %0, %0, %1" : "+r" (op1) : "r" (op2) ); + return(op1); +} + + +#if (__CORTEX_M >= 0x03) + +/** \brief Reverse bit order of value + + This function reverses the bit order of the given value. + + \param [in] value Value to reverse + \return Reversed value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __RBIT(uint32_t value) +{ + uint32_t result; + + __ASM volatile ("rbit %0, %1" : "=r" (result) : "r" (value) ); + return(result); +} + + +/** \brief LDR Exclusive (8 bit) + + This function performs a exclusive LDR command for 8 bit value. + + \param [in] ptr Pointer to data + \return value of type uint8_t at (*ptr) + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint8_t __LDREXB(volatile uint8_t *addr) +{ + uint8_t result; + + __ASM volatile ("ldrexb %0, [%1]" : "=r" (result) : "r" (addr) ); + return(result); +} + + +/** \brief LDR Exclusive (16 bit) + + This function performs a exclusive LDR command for 16 bit values. + + \param [in] ptr Pointer to data + \return value of type uint16_t at (*ptr) + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint16_t __LDREXH(volatile uint16_t *addr) +{ + uint16_t result; + + __ASM volatile ("ldrexh %0, [%1]" : "=r" (result) : "r" (addr) ); + return(result); +} + + +/** \brief LDR Exclusive (32 bit) + + This function performs a exclusive LDR command for 32 bit values. + + \param [in] ptr Pointer to data + \return value of type uint32_t at (*ptr) + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __LDREXW(volatile uint32_t *addr) +{ + uint32_t result; + + __ASM volatile ("ldrex %0, [%1]" : "=r" (result) : "r" (addr) ); + return(result); +} + + +/** \brief STR Exclusive (8 bit) + + This function performs a exclusive STR command for 8 bit values. + + \param [in] value Value to store + \param [in] ptr Pointer to location + \return 0 Function succeeded + \return 1 Function failed + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __STREXB(uint8_t value, volatile uint8_t *addr) +{ + uint32_t result; + + __ASM volatile ("strexb %0, %2, [%1]" : "=&r" (result) : "r" (addr), "r" (value) ); + return(result); +} + + +/** \brief STR Exclusive (16 bit) + + This function performs a exclusive STR command for 16 bit values. + + \param [in] value Value to store + \param [in] ptr Pointer to location + \return 0 Function succeeded + \return 1 Function failed + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __STREXH(uint16_t value, volatile uint16_t *addr) +{ + uint32_t result; + + __ASM volatile ("strexh %0, %2, [%1]" : "=&r" (result) : "r" (addr), "r" (value) ); + return(result); +} + + +/** \brief STR Exclusive (32 bit) + + This function performs a exclusive STR command for 32 bit values. + + \param [in] value Value to store + \param [in] ptr Pointer to location + \return 0 Function succeeded + \return 1 Function failed + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __STREXW(uint32_t value, volatile uint32_t *addr) +{ + uint32_t result; + + __ASM volatile ("strex %0, %2, [%1]" : "=&r" (result) : "r" (addr), "r" (value) ); + return(result); +} + + +/** \brief Remove the exclusive lock + + This function removes the exclusive lock which is created by LDREX. + + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __CLREX(void) +{ + __ASM volatile ("clrex"); +} + + +/** \brief Signed Saturate + + This function saturates a signed value. + + \param [in] value Value to be saturated + \param [in] sat Bit position to saturate to (1..32) + \return Saturated value + */ +#define __SSAT(ARG1,ARG2) \ +({ \ + uint32_t __RES, __ARG1 = (ARG1); \ + __ASM ("ssat %0, %1, %2" : "=r" (__RES) : "I" (ARG2), "r" (__ARG1) ); \ + __RES; \ + }) + + +/** \brief Unsigned Saturate + + This function saturates an unsigned value. + + \param [in] value Value to be saturated + \param [in] sat Bit position to saturate to (0..31) + \return Saturated value + */ +#define __USAT(ARG1,ARG2) \ +({ \ + uint32_t __RES, __ARG1 = (ARG1); \ + __ASM ("usat %0, %1, %2" : "=r" (__RES) : "I" (ARG2), "r" (__ARG1) ); \ + __RES; \ + }) + + +/** \brief Count leading zeros + + This function counts the number of leading zeros of a data value. + + \param [in] value Value to count the leading zeros + \return number of leading zeros in value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint8_t __CLZ(uint32_t value) +{ + uint8_t result; + + __ASM volatile ("clz %0, %1" : "=r" (result) : "r" (value) ); + return(result); +} + +#endif /* (__CORTEX_M >= 0x03) */ + + + + +#elif defined ( __TASKING__ ) /*------------------ TASKING Compiler --------------*/ +/* TASKING carm specific functions */ + +/* + * The CMSIS functions have been implemented as intrinsics in the compiler. + * Please use "carm -?i" to get an up to date list of all intrinsics, + * Including the CMSIS ones. + */ + +#endif + +/*@}*/ /* end of group CMSIS_Core_InstructionInterface */ + +#endif /* __CORE_CMINSTR_H */ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/Lib/GCC/.gitignore b/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/Lib/GCC/.gitignore new file mode 100644 index 0000000..5b6ae63 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/Lib/GCC/.gitignore @@ -0,0 +1,4 @@ +# Libraries + +!*.a + diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/Lib/GCC/libarm_cortexM0l_math.a b/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/Lib/GCC/libarm_cortexM0l_math.a new file mode 100644 index 0000000..f44336f Binary files /dev/null and b/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/Lib/GCC/libarm_cortexM0l_math.a differ diff --git a/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/README.txt b/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/README.txt new file mode 100644 index 0000000..efa2ad1 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/ASF/thirdparty/CMSIS/README.txt @@ -0,0 +1,37 @@ +* ------------------------------------------------------------------- +* Copyright (C) 2011 ARM Limited. All rights reserved. +* +* Date: 11 October 2011 +* Revision: V3.00 +* +* Project: Cortex Microcontroller Software Interface Standard (CMSIS) +* Title: Release Note for CMSIS +* +* ------------------------------------------------------------------- + + +NOTE - Open the index.html file to access CMSIS documentation + + +The Cortex Microcontroller Software Interface Standard (CMSIS) provides a single standard across all +Cortex-Mx processor series vendors. It enables code re-use and code sharing across software projects +and reduces time-to-market for new embedded applications. + +CMSIS is released under the terms of the end user license agreement ("CMSIS END USER LICENCE AGREEMENT.pdf"). +Any user of the software package is bound to the terms and conditions of the end user license agreement. + + +You will find the following sub-directories: + +Documentation - Contains CMSIS documentation. + +DSP_Lib - MDK project files, Examples and source files etc.. to build the + CMSIS DSP Software Library for Cortex-M0, Cortex-M3, Cortex-M4 processors. + +Include - CMSIS Core Support and CMSIS DSP Include Files. + +Lib - CMSIS DSP Libraries. + +RTOS - CMSIS RTOS API template header file. + +SVD - CMSIS SVD Schema files and Conversion Utility. diff --git a/bootloaders/mzero/Bootloader_D21/src/asf.h b/bootloaders/mzero/Bootloader_D21/src/asf.h new file mode 100644 index 0000000..0e3c3f2 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/asf.h @@ -0,0 +1,112 @@ +/** + * \file + * + * \brief Autogenerated API include file for the Atmel Software Framework (ASF) + * + * Copyright (c) 2012 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef ASF_H +#define ASF_H + +/* + * This file includes all API header files for the selected drivers from ASF. + * Note: There might be duplicate includes required by more than one driver. + * + * The file is automatically generated and will be re-written when + * running the ASF driver selector tool. Any changes will be discarded. + */ + +// From module: Common SAM0 compiler driver +#include +#include + +// From module: EXTINT - External Interrupt (Callback APIs) +//#include +//#include + +// From module: Generic board support +#include + +// From module: Interrupt management - SAM implementation +#include + +// From module: PORT - GPIO Pin Control +#include + +// From module: Part identification macros +#include + +// From module: RTC - Real Time Counter in Count Mode (Callback APIs) +#include +#include + +// From module: SAM D21/R21 USB Dual role interface +#include + +// From module: SYSTEM - Clock Management for SAMD21 +#include +#include + +// From module: SYSTEM - Core System Driver +#include + +// From module: SYSTEM - I/O Pin Multiplexer +#include + +// From module: SYSTEM - Interrupt Driver +#include + +// From module: Sleep manager - SAMD implementation +#include +#include + +// From module: USB - Universal Serial Bus +#include + +// From module: USB CDC Protocol +#include + +// From module: USB Device CDC (Single Interface Device) +#include + +// From module: USB Device Stack Core (Common API) +#include +#include + +#endif // ASF_H diff --git a/bootloaders/mzero/Bootloader_D21/src/command.h b/bootloaders/mzero/Bootloader_D21/src/command.h new file mode 100644 index 0000000..acd9988 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/command.h @@ -0,0 +1,121 @@ +#ifndef COMMAND_H_ +#define COMMAND_H_ + +//**** ATMEL AVR - A P P L I C A T I O N N O T E ************************ +//* +//* Title: AVR068 - STK500 Communication Protocol +//* Filename: command.h +//* Version: 1.0 +//* Last updated: 31.01.2005 +//* +//* Support E-mail: avr@atmel.com +//* +//************************************************************************** + +// *****************[ STK message constants ]*************************** + +#define MESSAGE_START 0x1B //= ESC = 27 decimal +#define TOKEN 0x0E + +// *****************[ STK general command constants ]************************** + +#define CMD_SIGN_ON 0x01 +#define CMD_SET_PARAMETER 0x02 +#define CMD_GET_PARAMETER 0x03 +#define CMD_SET_DEVICE_PARAMETERS 0x04 +#define CMD_OSCCAL 0x05 +#define CMD_LOAD_ADDRESS 0x06 +#define CMD_FIRMWARE_UPGRADE 0x07 + + +// *****************[ STK ISP command constants ]****************************** + +#define CMD_ENTER_PROGMODE_ISP 0x10 +#define CMD_LEAVE_PROGMODE_ISP 0x11 +#define CMD_CHIP_ERASE_ISP 0x12 +#define CMD_PROGRAM_FLASH_ISP 0x13 +#define CMD_READ_FLASH_ISP 0x14 +#define CMD_PROGRAM_EEPROM_ISP 0x15 +#define CMD_READ_EEPROM_ISP 0x16 +#define CMD_PROGRAM_FUSE_ISP 0x17 +#define CMD_READ_FUSE_ISP 0x18 +#define CMD_PROGRAM_LOCK_ISP 0x19 +#define CMD_READ_LOCK_ISP 0x1A +#define CMD_READ_SIGNATURE_ISP 0x1B +#define CMD_READ_OSCCAL_ISP 0x1C +#define CMD_SPI_MULTI 0x1D + +// *****************[ STK PP command constants ]******************************* + +#define CMD_ENTER_PROGMODE_PP 0x20 +#define CMD_LEAVE_PROGMODE_PP 0x21 +#define CMD_CHIP_ERASE_PP 0x22 +#define CMD_PROGRAM_FLASH_PP 0x23 +#define CMD_READ_FLASH_PP 0x24 +#define CMD_PROGRAM_EEPROM_PP 0x25 +#define CMD_READ_EEPROM_PP 0x26 +#define CMD_PROGRAM_FUSE_PP 0x27 +#define CMD_READ_FUSE_PP 0x28 +#define CMD_PROGRAM_LOCK_PP 0x29 +#define CMD_READ_LOCK_PP 0x2A +#define CMD_READ_SIGNATURE_PP 0x2B +#define CMD_READ_OSCCAL_PP 0x2C + +#define CMD_SET_CONTROL_STACK 0x2D + +// *****************[ STK HVSP command constants ]***************************** + +#define CMD_ENTER_PROGMODE_HVSP 0x30 +#define CMD_LEAVE_PROGMODE_HVSP 0x31 +#define CMD_CHIP_ERASE_HVSP 0x32 +#define CMD_PROGRAM_FLASH_HVSP ` 0x33 +#define CMD_READ_FLASH_HVSP 0x34 +#define CMD_PROGRAM_EEPROM_HVSP 0x35 +#define CMD_READ_EEPROM_HVSP 0x36 +#define CMD_PROGRAM_FUSE_HVSP 0x37 +#define CMD_READ_FUSE_HVSP 0x38 +#define CMD_PROGRAM_LOCK_HVSP 0x39 +#define CMD_READ_LOCK_HVSP 0x3A +#define CMD_READ_SIGNATURE_HVSP 0x3B +#define CMD_READ_OSCCAL_HVSP 0x3C + +// *****************[ STK status constants ]*************************** + +// Success +#define STATUS_CMD_OK 0x00 + +// Warnings +#define STATUS_CMD_TOUT 0x80 +#define STATUS_RDY_BSY_TOUT 0x81 +#define STATUS_SET_PARAM_MISSING 0x82 + +// Errors +#define STATUS_CMD_FAILED 0xC0 +#define STATUS_CKSUM_ERROR 0xC1 +#define STATUS_CMD_UNKNOWN 0xC9 + +// *****************[ STK parameter constants ]*************************** +#define PARAM_BUILD_NUMBER_LOW 0x80 +#define PARAM_BUILD_NUMBER_HIGH 0x81 +#define PARAM_HW_VER 0x90 +#define PARAM_SW_MAJOR 0x91 +#define PARAM_SW_MINOR 0x92 +#define PARAM_VTARGET 0x94 +#define PARAM_VADJUST 0x95 +#define PARAM_OSC_PSCALE 0x96 +#define PARAM_OSC_CMATCH 0x97 +#define PARAM_SCK_DURATION 0x98 +#define PARAM_TOPCARD_DETECT 0x9A +#define PARAM_STATUS 0x9C +#define PARAM_DATA 0x9D +#define PARAM_RESET_POLARITY 0x9E +#define PARAM_CONTROLLER_INIT 0x9F + +// *****************[ STK answer constants ]*************************** + +#define ANSWER_CKSUM_ERROR 0xB0 + + + + +#endif /* COMMAND_H_ */ \ No newline at end of file diff --git a/bootloaders/mzero/Bootloader_D21/src/config/conf_board.h b/bootloaders/mzero/Bootloader_D21/src/config/conf_board.h new file mode 100644 index 0000000..9844ec0 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/config/conf_board.h @@ -0,0 +1,47 @@ +/** + * \file + * + * \brief SAM D21 Xplained Pro board configuration. + * + * Copyright (c) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef CONF_BOARD_H_INCLUDED +#define CONF_BOARD_H_INCLUDED + +#endif /* CONF_BOARD_H_INCLUDED */ diff --git a/bootloaders/mzero/Bootloader_D21/src/config/conf_clocks.h b/bootloaders/mzero/Bootloader_D21/src/config/conf_clocks.h new file mode 100644 index 0000000..fe57cf9 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/config/conf_clocks.h @@ -0,0 +1,183 @@ +/** + * \file + * + * \brief SAM D21 Clock configuration + * + * Copyright (C) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include + +#ifndef CONF_CLOCKS_H_INCLUDED +# define CONF_CLOCKS_H_INCLUDED + +/* System clock bus configuration */ +# define CONF_CLOCK_CPU_CLOCK_FAILURE_DETECT true +# define CONF_CLOCK_FLASH_WAIT_STATES 2 +# define CONF_CLOCK_CPU_DIVIDER SYSTEM_MAIN_CLOCK_DIV_1 +# define CONF_CLOCK_APBA_DIVIDER SYSTEM_MAIN_CLOCK_DIV_1 +# define CONF_CLOCK_APBB_DIVIDER SYSTEM_MAIN_CLOCK_DIV_1 + +/* SYSTEM_CLOCK_SOURCE_OSC8M configuration - Internal 8MHz oscillator */ +# define CONF_CLOCK_OSC8M_PRESCALER SYSTEM_OSC8M_DIV_1 +# define CONF_CLOCK_OSC8M_ON_DEMAND true +# define CONF_CLOCK_OSC8M_RUN_IN_STANDBY false + +/* SYSTEM_CLOCK_SOURCE_XOSC configuration - External clock/oscillator */ +# define CONF_CLOCK_XOSC_ENABLE false +# define CONF_CLOCK_XOSC_EXTERNAL_CRYSTAL SYSTEM_CLOCK_EXTERNAL_CRYSTAL +# define CONF_CLOCK_XOSC_EXTERNAL_FREQUENCY 12000000UL +# define CONF_CLOCK_XOSC_STARTUP_TIME SYSTEM_XOSC_STARTUP_32768 +# define CONF_CLOCK_XOSC_AUTO_GAIN_CONTROL true +# define CONF_CLOCK_XOSC_ON_DEMAND true +# define CONF_CLOCK_XOSC_RUN_IN_STANDBY false + +/* SYSTEM_CLOCK_SOURCE_XOSC32K configuration - External 32KHz crystal/clock oscillator */ +# define CONF_CLOCK_XOSC32K_ENABLE false +# define CONF_CLOCK_XOSC32K_EXTERNAL_CRYSTAL SYSTEM_CLOCK_EXTERNAL_CRYSTAL +# define CONF_CLOCK_XOSC32K_STARTUP_TIME SYSTEM_XOSC32K_STARTUP_65536 +# define CONF_CLOCK_XOSC32K_AUTO_AMPLITUDE_CONTROL false +# define CONF_CLOCK_XOSC32K_ENABLE_1KHZ_OUPUT false +# define CONF_CLOCK_XOSC32K_ENABLE_32KHZ_OUTPUT true +# define CONF_CLOCK_XOSC32K_ON_DEMAND true +# define CONF_CLOCK_XOSC32K_RUN_IN_STANDBY false + +/* SYSTEM_CLOCK_SOURCE_OSC32K configuration - Internal 32KHz oscillator */ +# define CONF_CLOCK_OSC32K_ENABLE false +# define CONF_CLOCK_OSC32K_STARTUP_TIME SYSTEM_OSC32K_STARTUP_130 +# define CONF_CLOCK_OSC32K_ENABLE_1KHZ_OUTPUT true +# define CONF_CLOCK_OSC32K_ENABLE_32KHZ_OUTPUT true +# define CONF_CLOCK_OSC32K_ON_DEMAND true +# define CONF_CLOCK_OSC32K_RUN_IN_STANDBY false + +/* SYSTEM_CLOCK_SOURCE_DFLL configuration - Digital Frequency Locked Loop */ +# define CONF_CLOCK_DFLL_ENABLE true +# define CONF_CLOCK_DFLL_LOOP_MODE SYSTEM_CLOCK_DFLL_LOOP_MODE_USB_RECOVERY +# define CONF_CLOCK_DFLL_ON_DEMAND true + +/* DFLL open loop mode configuration */ +# define CONF_CLOCK_DFLL_COARSE_VALUE (0x1f / 4) +# define CONF_CLOCK_DFLL_FINE_VALUE (0xff / 4) + +/* DFLL closed loop mode configuration */ +# define CONF_CLOCK_DFLL_SOURCE_GCLK_GENERATOR GCLK_GENERATOR_1 +# define CONF_CLOCK_DFLL_MULTIPLY_FACTOR 6 +# define CONF_CLOCK_DFLL_QUICK_LOCK true +# define CONF_CLOCK_DFLL_TRACK_AFTER_FINE_LOCK true +# define CONF_CLOCK_DFLL_KEEP_LOCK_ON_WAKEUP true +# define CONF_CLOCK_DFLL_ENABLE_CHILL_CYCLE true +# define CONF_CLOCK_DFLL_MAX_COARSE_STEP_SIZE (0x1f / 4) +# define CONF_CLOCK_DFLL_MAX_FINE_STEP_SIZE (0xff / 4) + +/* SYSTEM_CLOCK_SOURCE_DPLL configuration - Digital Phase-Locked Loop */ +# define CONF_CLOCK_DPLL_ENABLE false +# define CONF_CLOCK_DPLL_ON_DEMAND true +# define CONF_CLOCK_DPLL_RUN_IN_STANDBY false +# define CONF_CLOCK_DPLL_LOCK_BYPASS false +# define CONF_CLOCK_DPLL_WAKE_UP_FAST false +# define CONF_CLOCK_DPLL_LOW_POWER_ENABLE false + +# define CONF_CLOCK_DPLL_LOCK_TIME SYSTEM_CLOCK_SOURCE_DPLL_LOCK_TIME_NO_TIMEOUT +# define CONF_CLOCK_DPLL_REFERENCE_CLOCK SYSTEM_CLOCK_SOURCE_DPLL_REFERENCE_CLOCK_REF0 +# define CONF_CLOCK_DPLL_FILTER SYSTEM_CLOCK_SOURCE_DPLL_FILTER_DEFAULT + +# define CONF_CLOCK_DPLL_REFERENCE_FREQUENCY 32768 +# define CONF_CLOCK_DPLL_REFEREMCE_DIVIDER 1 +# define CONF_CLOCK_DPLL_OUTPUT_FREQUENCY 48000000 + +/* Set this to true to configure the GCLK when running clocks_init. If set to + * false, none of the GCLK generators will be configured in clocks_init(). */ +# define CONF_CLOCK_CONFIGURE_GCLK true + +/* Configure GCLK generator 0 (Main Clock) */ +# define CONF_CLOCK_GCLK_0_ENABLE true +# define CONF_CLOCK_GCLK_0_RUN_IN_STANDBY true +# define CONF_CLOCK_GCLK_0_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_DFLL +# define CONF_CLOCK_GCLK_0_PRESCALER 1 +# define CONF_CLOCK_GCLK_0_OUTPUT_ENABLE false + +/* Configure GCLK generator 1 */ +# define CONF_CLOCK_GCLK_1_ENABLE false +# define CONF_CLOCK_GCLK_1_RUN_IN_STANDBY false +# define CONF_CLOCK_GCLK_1_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_OSC8M +# define CONF_CLOCK_GCLK_1_PRESCALER 1 +# define CONF_CLOCK_GCLK_1_OUTPUT_ENABLE false + +/* Configure GCLK generator 2 (RTC) */ +# define CONF_CLOCK_GCLK_2_ENABLE true +# define CONF_CLOCK_GCLK_2_RUN_IN_STANDBY false +# define CONF_CLOCK_GCLK_2_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_ULP32K +# define CONF_CLOCK_GCLK_2_PRESCALER 32 +# define CONF_CLOCK_GCLK_2_OUTPUT_ENABLE false + +/* Configure GCLK generator 3 */ +# define CONF_CLOCK_GCLK_3_ENABLE false +# define CONF_CLOCK_GCLK_3_RUN_IN_STANDBY false +# define CONF_CLOCK_GCLK_3_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_OSC8M +# define CONF_CLOCK_GCLK_3_PRESCALER 1 +# define CONF_CLOCK_GCLK_3_OUTPUT_ENABLE false + +/* Configure GCLK generator 4 */ +# define CONF_CLOCK_GCLK_4_ENABLE false +# define CONF_CLOCK_GCLK_4_RUN_IN_STANDBY false +# define CONF_CLOCK_GCLK_4_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_OSC8M +# define CONF_CLOCK_GCLK_4_PRESCALER 1 +# define CONF_CLOCK_GCLK_4_OUTPUT_ENABLE false + +/* Configure GCLK generator 5 */ +# define CONF_CLOCK_GCLK_5_ENABLE false +# define CONF_CLOCK_GCLK_5_RUN_IN_STANDBY false +# define CONF_CLOCK_GCLK_5_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_OSC8M +# define CONF_CLOCK_GCLK_5_PRESCALER 1 +# define CONF_CLOCK_GCLK_5_OUTPUT_ENABLE false + +/* Configure GCLK generator 6 */ +# define CONF_CLOCK_GCLK_6_ENABLE false +# define CONF_CLOCK_GCLK_6_RUN_IN_STANDBY false +# define CONF_CLOCK_GCLK_6_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_OSC8M +# define CONF_CLOCK_GCLK_6_PRESCALER 1 +# define CONF_CLOCK_GCLK_6_OUTPUT_ENABLE false + +/* Configure GCLK generator 7 */ +# define CONF_CLOCK_GCLK_7_ENABLE false +# define CONF_CLOCK_GCLK_7_RUN_IN_STANDBY false +# define CONF_CLOCK_GCLK_7_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_OSC8M +# define CONF_CLOCK_GCLK_7_PRESCALER 1 +# define CONF_CLOCK_GCLK_7_OUTPUT_ENABLE false + +#endif /* CONF_CLOCKS_H_INCLUDED */ + diff --git a/bootloaders/mzero/Bootloader_D21/src/config/conf_extint.h b/bootloaders/mzero/Bootloader_D21/src/config/conf_extint.h new file mode 100644 index 0000000..8dd56f4 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/config/conf_extint.h @@ -0,0 +1,48 @@ +/** + * \file + * + * \brief SAM External Interrupt Driver Configuration Header + * + * Copyright (C) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef CONF_EXTINT_H_INCLUDED +#define CONF_EXTINT_H_INCLUDED + +# define EXTINT_CLOCK_SOURCE GCLK_GENERATOR_0 + +#endif diff --git a/bootloaders/mzero/Bootloader_D21/src/config/conf_sleepmgr.h b/bootloaders/mzero/Bootloader_D21/src/config/conf_sleepmgr.h new file mode 100644 index 0000000..c11965c --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/config/conf_sleepmgr.h @@ -0,0 +1,49 @@ +/** + * \file + * + * \brief Chip-specific sleep manager configuration + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef CONF_SLEEPMGR_INCLUDED +#define CONF_SLEEPMGR_INCLUDED + +// Sleep manager options +#define CONFIG_SLEEPMGR_ENABLE + +#endif /* CONF_SLEEPMGR_INCLUDED */ diff --git a/bootloaders/mzero/Bootloader_D21/src/config/conf_usb.h b/bootloaders/mzero/Bootloader_D21/src/config/conf_usb.h new file mode 100644 index 0000000..47ac330 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/config/conf_usb.h @@ -0,0 +1,176 @@ +/** + * \file + * + * \brief USB configuration file for CDC application + * + * Copyright (c) 2009-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _CONF_USB_H_ +#define _CONF_USB_H_ + +#include "compiler.h" +#include "board.h" + +/** + * USB Device Configuration + * @{ + */ + + // Arduino srl Zero Pro USB ID Definition. + #define USB_VENDOR_ID 0x2A03 + #define USB_VENDOR_DESCRIPTOR "Arduino srl (www.Arduino.org)" + #define USB_PRODUCT_ID 0x004D // Arduino Zero PRO PID + #define USB_PRODUCT_NAME "Arduino Zero PRO" + + + +//! Device definition (mandatory) +#define USB_DEVICE_VENDOR_ID USB_VENDOR_ID +#if BOARD == UC3B_BOARD_CONTROLLER +# define USB_DEVICE_PRODUCT_ID USB_PID_ATMEL_UC3_CDC_DEBUG +#else +# define USB_DEVICE_PRODUCT_ID USB_PRODUCT_ID + + +#endif +#define USB_DEVICE_MAJOR_VERSION 1 +#define USB_DEVICE_MINOR_VERSION 0 +#define USB_DEVICE_POWER 100 // Consumption on Vbus line (mA) +#define USB_DEVICE_ATTR \ + (USB_CONFIG_ATTR_SELF_POWERED) +// (USB_CONFIG_ATTR_BUS_POWERED) +// (USB_CONFIG_ATTR_REMOTE_WAKEUP|USB_CONFIG_ATTR_SELF_POWERED) +// (USB_CONFIG_ATTR_REMOTE_WAKEUP|USB_CONFIG_ATTR_BUS_POWERED) + +//! USB Device string definitions (Optional) +#define USB_DEVICE_MANUFACTURE_NAME USB_VENDOR_DESCRIPTOR +#define USB_DEVICE_PRODUCT_NAME USB_PRODUCT_NAME +#define USB_DEVICE_SERIAL_NAME "004D" // Arduino Zero PRO USB Serial Number + + + +/** + * Device speeds support + * Low speed not supported by CDC + * @{ + */ +//! To authorize the High speed +#if (UC3A3||UC3A4) +#define USB_DEVICE_HS_SUPPORT +#elif (SAM3XA||SAM3U) +#define USB_DEVICE_HS_SUPPORT +#endif +//@} + + +/** + * USB Device Callbacks definitions (Optional) + * @{ + */ +#define UDC_VBUS_EVENT(b_vbus_high) +#define UDC_SOF_EVENT() +#define UDC_SUSPEND_EVENT() +#define UDC_RESUME_EVENT() +//! Mandatory when USB_DEVICE_ATTR authorizes remote wakeup feature +// #define UDC_REMOTEWAKEUP_ENABLE() user_callback_remotewakeup_enable() +// extern void user_callback_remotewakeup_enable(void); +// #define UDC_REMOTEWAKEUP_DISABLE() user_callback_remotewakeup_disable() +// extern void user_callback_remotewakeup_disable(void); +#ifdef USB_DEVICE_LPM_SUPPORT +#define UDC_SUSPEND_LPM_EVENT() +#define UDC_REMOTEWAKEUP_LPM_ENABLE() +#define UDC_REMOTEWAKEUP_LPM_DISABLE() +#endif +//! When a extra string descriptor must be supported +//! other than manufacturer, product and serial string +// #define UDC_GET_EXTRA_STRING() +//@} + +//@} + + +/** + * USB Interface Configuration + * @{ + */ +/** + * Configuration of CDC interface + * @{ + */ + +//! Define two USB communication ports +#define UDI_CDC_PORT_NB 1 + +//! Interface callback definition +#define UDI_CDC_ENABLE_EXT(port) true +#define UDI_CDC_DISABLE_EXT(port) +#define UDI_CDC_RX_NOTIFY(port) +#define UDI_CDC_TX_EMPTY_NOTIFY(port) +#define UDI_CDC_SET_CODING_EXT(port,cfg) main_cdc_config(port,cfg) +#define UDI_CDC_SET_DTR_EXT(port,set) +#define UDI_CDC_SET_RTS_EXT(port,set) + +//! Define it when the transfer CDC Device to Host is a low rate (<512000 bauds) +//! to reduce CDC buffers size +//#define UDI_CDC_LOW_RATE + +//! Default configuration of communication port +#if BOARD == UC3B_BOARD_CONTROLLER +#define UDI_CDC_DEFAULT_RATE 57600 +#else +#define UDI_CDC_DEFAULT_RATE 115200 +#endif +#define UDI_CDC_DEFAULT_STOPBITS CDC_STOP_BITS_1 +#define UDI_CDC_DEFAULT_PARITY CDC_PAR_NONE +#define UDI_CDC_DEFAULT_DATABITS 8 +//@} +//@} + + +/** + * USB Device Driver Configuration + * @{ + */ +//@} + +//! The includes of classes and other headers must be done at the end of this file to avoid compile error +#include "udi_cdc_conf.h" +#include "main.h" + +#endif // _CONF_USB_H_ diff --git a/bootloaders/mzero/Bootloader_D21/src/main.c b/bootloaders/mzero/Bootloader_D21/src/main.c new file mode 100644 index 0000000..6a2f1c4 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/main.c @@ -0,0 +1,275 @@ +/*---------- GNU PUBLIC LICENZE V3 ---------- +* +* Copyright Arduino srl (c) 2015 +* +* This file is part of Bootloader_D21. +* +* Bootloader_D21 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. +* +* bootloader_D21 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 Bootloader_D21. If not, see . +* +*/ + +/* + * Include header files for all drivers that have been imported from + * Atmel Software Framework (ASF). + */ + +#include + + +static inline bool nvm_is_ready(void) +{ + /* Get a pointer to the module hardware instance */ + Nvmctrl *const nvm_module = NVMCTRL; + + return nvm_module->INTFLAG.reg & NVMCTRL_INTFLAG_READY; +} +#include +enum nvm_cache_readmode { + /** The NVM Controller (cache system) does not insert wait states on + * a cache miss. Gives the best system performance. + */ + NVM_CACHE_READMODE_NO_MISS_PENALTY, + /** Reduces power consumption of the cache system, but inserts a + * wait state each time there is a cache miss + */ + NVM_CACHE_READMODE_LOW_POWER, + /** The cache system ensures that a cache hit or miss takes the same + * amount of time, determined by the number of programmed flash + * wait states. + */ + NVM_CACHE_READMODE_DETERMINISTIC, +}; + +enum nvm_sleep_power_mode { + /** NVM controller exits low power mode on first access after sleep. */ + NVM_SLEEP_POWER_MODE_WAKEONACCESS = NVMCTRL_CTRLB_SLEEPPRM_WAKEONACCESS_Val, + /** NVM controller exits low power mode when the device exits sleep mode. */ + NVM_SLEEP_POWER_MODE_WAKEUPINSTANT = NVMCTRL_CTRLB_SLEEPPRM_WAKEUPINSTANT_Val, + /** Power reduction mode in the NVM controller disabled. */ + NVM_SLEEP_POWER_MODE_ALWAYS_AWAKE = NVMCTRL_CTRLB_SLEEPPRM_DISABLED_Val, +}; + + +void configure_nvm(void) +{ + /* Turn on the digital interface clock */ + system_apb_clock_set_mask(SYSTEM_CLOCK_APB_APBB, PM_APBBMASK_NVMCTRL); + + /* Clear error flags */ + NVMCTRL->STATUS.reg |= NVMCTRL_STATUS_MASK; + + /* Check if the module is busy */ + if (!nvm_is_ready()) { + return STATUS_BUSY; + } + + /* Writing configuration to the CTRLB register */ + NVMCTRL->CTRLB.reg = + NVMCTRL_CTRLB_SLEEPPRM(NVM_SLEEP_POWER_MODE_WAKEONACCESS) | + ((false & 0x01) << NVMCTRL_CTRLB_MANW_Pos) | + NVMCTRL_CTRLB_RWS(NVMCTRL->CTRLB.bit.RWS) | + ((false & 0x01) << NVMCTRL_CTRLB_CACHEDIS_Pos) | + NVMCTRL_CTRLB_READMODE(NVM_CACHE_READMODE_NO_MISS_PENALTY); +} + +/** + * \brief Function to start the application. + */ +static void start_application(void) +{ + /* Pointer to the Application Section */ + void (*application_code_entry)(void); + + /* Rebase the Stack Pointer */ + __set_MSP(*(uint32_t *)APP_START_ADDR); + + /* Rebase the vector table base address */ + SCB->VTOR = ((uint32_t)APP_START_ADDR & SCB_VTOR_TBLOFF_Msk); + + /* Load the Reset Handler address of the application */ + application_code_entry = (void (*)(void))(unsigned *)(*(unsigned *) + (APP_START_ADDR + 4)); + + /* Jump to user Reset Handler in the application */ + application_code_entry(); +} + +struct rtc_module rtc_instance; + +void rtc_overflow_callback(void) +{ + timeout+=2;//callback is called every 2ms + if(timeout > TIMOUT_PERIOD) + { + rtc_count_disable(&rtc_instance); + rtc_count_clear_overflow(&rtc_instance); + NVIC_ClearPendingIRQ(RTC_IRQn); + udc_stop(); + cpu_irq_disable(); + //SCB->AIRCR = ((0x05FA<<16)|0b100); //reset cpu + NVIC_SystemReset() ; + while(1) + { + //wait for WDT + } + } + if((timeout % 50) == 0) + { + port_pin_toggle_output_level(LED_L_PIN); // when the board is in bootloader mode the L Led blink + } +} +void configure_timeout() +{ + struct rtc_count_config config_rtc_count; + rtc_count_get_config_defaults(&config_rtc_count); + config_rtc_count.prescaler = RTC_COUNT_PRESCALER_DIV_1; + config_rtc_count.mode = RTC_COUNT_MODE_16BIT; + config_rtc_count.continuously_update = true; + rtc_count_init(&rtc_instance, RTC, &config_rtc_count); + rtc_count_enable(&rtc_instance); rtc_count_register_callback( + &rtc_instance, rtc_overflow_callback, RTC_COUNT_CALLBACK_OVERFLOW); + rtc_count_enable_callback(&rtc_instance, RTC_COUNT_CALLBACK_OVERFLOW); rtc_count_set_period(&rtc_instance, 1);//1 ms per callback NVIC_SetPriority(RTC_IRQn, 0);//RTC Top priority +} + + +void configure_port_pins(void) +{ + struct port_config config_port_pin; + port_get_config_defaults(&config_port_pin); + config_port_pin.direction = PORT_PIN_DIR_INPUT; + config_port_pin.input_pull = PORT_PIN_PULL_UP; + port_pin_set_config(BUTTON_0_PIN, &config_port_pin); +} + + +//1 =16 kb +#define BOOTLOADER_SIZE 1 + +void protect_boot_section() +{ + system_interrupt_enter_critical_section(); + volatile uint32_t raw_fusebits[2]; + + /* Make sure the module is ready */ + while (!nvm_is_ready()) { + }; + + /* Read the fuse settings in the user row, 64 bit */ + ((uint16_t*)&raw_fusebits)[0] = (uint16_t)NVM_MEMORY[NVMCTRL_USER / 2]; + ((uint16_t*)&raw_fusebits)[1] = (uint16_t)NVM_MEMORY[(NVMCTRL_USER / 2) + 1]; + ((uint16_t*)&raw_fusebits)[2] = (uint16_t)NVM_MEMORY[(NVMCTRL_USER / 2) + 2]; + ((uint16_t*)&raw_fusebits)[3] = (uint16_t)NVM_MEMORY[(NVMCTRL_USER / 2) + 3]; + if(((raw_fusebits[0] & NVMCTRL_FUSES_BOOTPROT_Msk)>> NVMCTRL_FUSES_BOOTPROT_Pos) != BOOTLOADER_SIZE) + { + /* Auxiliary space cannot be accessed if the security bit is set */ + if (NVMCTRL->STATUS.reg & NVMCTRL_STATUS_SB) { + return; + } + /* Disable Cache */ + uint32_t temp = NVMCTRL->CTRLB.reg; + + NVMCTRL->CTRLB.reg = temp | NVMCTRL_CTRLB_CACHEDIS; + + /* Clear error flags */ + NVMCTRL->STATUS.reg |= NVMCTRL_STATUS_MASK; + + /* Set address, command will be issued elsewhere */ + NVMCTRL->ADDR.reg = NVMCTRL_AUX0_ADDRESS/2; + + /* Erase the user page */ + NVMCTRL->CTRLA.reg = NVMCTRL_CTRLA_CMD_EAR | NVMCTRL_CTRLA_CMDEX_KEY; + + /* Wait for NVM command to complete */ + while (!(NVMCTRL->INTFLAG.reg & NVMCTRL_INTFLAG_READY)); + + /* Clear error flags */ + NVMCTRL->STATUS.reg |= NVMCTRL_STATUS_MASK; + + /* Set address, command will be issued elsewhere */ + NVMCTRL->ADDR.reg = NVMCTRL_AUX0_ADDRESS/2; + + /* Erase the page buffer before buffering new data */ + NVMCTRL->CTRLA.reg = NVMCTRL_CTRLA_CMD_PBC | NVMCTRL_CTRLA_CMDEX_KEY; + + /* Wait for NVM command to complete */ + while (!(NVMCTRL->INTFLAG.reg & NVMCTRL_INTFLAG_READY)); + + /* Clear error flags */ + NVMCTRL->STATUS.reg |= NVMCTRL_STATUS_MASK; + + /* Set address, command will be issued elsewhere */ + NVMCTRL->ADDR.reg = NVMCTRL_AUX0_ADDRESS/2; + raw_fusebits[0] = ((raw_fusebits[0] ^ NVMCTRL_FUSES_BOOTPROT_Msk) | NVMCTRL_FUSES_BOOTPROT(BOOTLOADER_SIZE)); + *((uint32_t *)NVMCTRL_AUX0_ADDRESS) = raw_fusebits[0]; + *(((uint32_t *)NVMCTRL_AUX0_ADDRESS) + 1) = raw_fusebits[1]; + + /* Write the user page */ + NVMCTRL->CTRLA.reg = NVMCTRL_CTRLA_CMD_WAP | NVMCTRL_CTRLA_CMDEX_KEY; + + /* Restore the settings */ + NVMCTRL->CTRLB.reg = temp; + + + //nvm_execute_command(NVM_COMMAND_WRITE_AUX_ROW, NVMCTRL_USER, 0); + } + system_interrupt_leave_critical_section(); +} + +int main (void) +{ + + port_pin_set_output_level(LED_L_PIN,LED_L_INACTIVE); + port_pin_set_output_level(LED_TX_PIN,LED_TX_INACTIVE); + port_pin_set_output_level(LED_RX_PIN,LED_RX_INACTIVE); + /* Check if WDT is locked */ + + + if (!(WDT->CTRL.reg & WDT_CTRL_ALWAYSON)) { + /* Disable the Watchdog module */ + WDT->CTRL.reg &= ~WDT_CTRL_ENABLE; + } + if(!(PM->RCAUSE.reg & PM_RCAUSE_EXT) && !(PM->RCAUSE.reg & PM_RCAUSE_WDT) && (NVM_MEMORY[APP_START_ADDR / 2] != 0xFFFF)) //Power on reset or systemResetReq -> run main app + { + start_application(); + } + //if reset by wdt or reset button, run bootloader + irq_initialize_vectors(); + cpu_irq_enable(); + + system_init(); + + configure_timeout(); + configure_nvm(); + + // Start USB stack to authorize VBus monitoring + udc_start(); + NVIC_SetPriority(USB_IRQn, 1); //USB Should have lower priority than rtc + + //check if boot-protection is on + //(edbg does not write to boot-section if this is protected + //(bootprot can be manually changed to 0x07 in the "fuses" tab of Atmel tudio to reprogram) + + protect_boot_section(); //uncomment for release + + while (1) { + get_message();//STK500v2 + } +} + +void main_cdc_config(uint8_t port,usb_cdc_line_coding_t *cfg) +{ + if(cfg[port].dwDTERate == 1200) + { + //do nothing + } +} \ No newline at end of file diff --git a/bootloaders/mzero/Bootloader_D21/src/main.h b/bootloaders/mzero/Bootloader_D21/src/main.h new file mode 100644 index 0000000..4cb9e87 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/main.h @@ -0,0 +1,51 @@ +/** + * \file + * + * \brief Main functions + * + * Copyright (c) 2009-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _MAIN_H_ +#define _MAIN_H_ + +#include "usb_protocol_cdc.h" + +void main_cdc_config(uint8_t port,usb_cdc_line_coding_t *cfg); + +#endif // _MAIN_H_ diff --git a/bootloaders/mzero/Bootloader_D21/src/stk500v2.h b/bootloaders/mzero/Bootloader_D21/src/stk500v2.h new file mode 100644 index 0000000..81d893f --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21/src/stk500v2.h @@ -0,0 +1,384 @@ +/*---------- GNU PUBLIC LICENZE V3 ---------- +* +* Copyright Arduino srl (c) 2015 +* +* This file is part of Bootloader_D21. +* +* Bootloader_D21 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. +* +* bootloader_D21 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 Bootloader_D21. If not, see . +* +*/ + + +#ifndef STK500V2_H_ +#define STK500V2_H_ + +#include"command.h" +#define NVM_MEMORY ((volatile uint16_t *)FLASH_ADDR) +#define APP_START_ADDR (0x4000) +#define TIMOUT_PERIOD 8000 +volatile uint32_t timeout = 0; +volatile uint32_t current_address = APP_START_ADDR; +uint8_t GET_COMMAND_BYTE() +{ + port_pin_set_output_level(LED_RX_PIN,LED_RX_INACTIVE); // RX LED management + + while(!udi_cdc_is_rx_ready()) + { + + } + + port_pin_set_output_level(LED_RX_PIN,LED_RX_ACTIVE); // RX LED management + + return udi_cdc_multi_getc(0); +} + +void SEND_RESPONSE(char response) +{ + //if (!udi_cdc_is_tx_ready()) { + // /* Fifo full */ + // udi_cdc_signal_overrun(); + // ui_com_overflow();//not implemented yet + //} + + port_pin_set_output_level(LED_TX_PIN,LED_TX_INACTIVE); // TX LED management + + while(!udi_cdc_is_tx_ready()) + { + + } + + port_pin_set_output_level(LED_TX_PIN,LED_TX_ACTIVE); // TX LED management + + udi_cdc_putc(response); + return; +} + +void commit_page() +{ + /*if current row is not written fully, fill rest of row with zeros, on last write in page, + whole buffer is written (automatic writes are on)*/ + if(current_address >= APP_START_ADDR) + { + while(current_address%NVMCTRL_ROW_SIZE != 0) + { + NVM_MEMORY[current_address/2] = 0xffff; + current_address += 2; + } + /*wait until write operation is done*/ + while(!(NVMCTRL->INTFLAG.bit.READY)) + { + ; + } + } +} + + +/* DEFINES FOR DEVICE, pull out to header later TODOTODOTODO*/ +//signature for mega2560 +#define DEVICE_SIGNATURE 0x1E9801 +#define CONF_PARAM_BUILD_NUMBER_LOW 1 +#define CONF_PARAM_BUILD_NUMBER_HIGH 2 +#define CONF_PARAM_HW_VER 3 +#define CONF_PARAM_SW_MAJOR 4 +#define CONF_PARAM_SW_MINOR 5 + + +void handle_message(void); + +/* based on +http://www.atmel.com/images/doc2591.pdf +AVR068: STK500 communication protocol +*/ +#define MAX_MESSAGE_LENGTH 286 + +typedef enum +{ + STATE_START, + STATE_GET_SEQUENCE_NUMBER, + STATE_GET_MESSAGE_SIZE_1, + STATE_GET_MESSAGE_SIZE_2, + STATE_GET_TOKEN, + STATE_GET_DATA, + STATE_GET_CHECKSUM, + +} stk500v2_state; + +uint8_t message[MAX_MESSAGE_LENGTH]; +uint16_t message_length = 0; +uint8_t sequence_number = 0; + +uint8_t get_checksum(uint16_t current_byte_in_message, uint8_t *message_to_check) +{ + uint8_t checksum = 0; + for(uint16_t i = 0; i>((2-signature_index)*8))&0xFF; + return_message[3] = STATUS_CMD_OK; + break; + case CMD_GET_PARAMETER: + return_message_length = 3; + uint8_t parameter = message_body[1]; + return_message[1] = STATUS_CMD_OK; + switch(parameter) + { + case PARAM_BUILD_NUMBER_LOW: + return_message[2] = CONF_PARAM_BUILD_NUMBER_LOW; + break; + case PARAM_BUILD_NUMBER_HIGH: + return_message[2] = CONF_PARAM_BUILD_NUMBER_HIGH; + break; + case PARAM_HW_VER: + return_message[2] = CONF_PARAM_HW_VER; + break; + case PARAM_SW_MAJOR: + return_message[2] = CONF_PARAM_SW_MAJOR; + break; + case PARAM_SW_MINOR: + return_message[2] = CONF_PARAM_SW_MINOR; + break; + default: + return_message[2] = 0; + break; + } + break; + + case CMD_ENTER_PROGMODE_ISP: //Ignore this one for now + return_message_length = 2; + return_message[1] = STATUS_CMD_OK; + break; + case CMD_LEAVE_PROGMODE_ISP: + return_message_length = 2; + return_message[1] = STATUS_CMD_OK; + timeout = (TIMOUT_PERIOD - 500);//reset and enter main app after 500 ms + break; + case CMD_SET_PARAMETER: //Ignore this one for now + return_message_length = 2; + return_message[1] = STATUS_CMD_OK; + break; + case CMD_LOAD_ADDRESS: + current_address = (((message_body[1]<<24) | (message_body[2]<<16) | (message_body[3]<<8) | (message_body[4]))<<1);//shift left 1 to ignore msb and convert from word to byte +// current_address = current_address + APP_START_ADDR; + return_message_length = 2; + return_message[1] = STATUS_CMD_OK; + break; + case CMD_SPI_MULTI: //only partially implemented + switch(message_body[4]) + { + case 0x30: + return_message_length = 7; + return_message[1] = STATUS_CMD_OK; + return_message[2] = 0; + return_message[3] = message_body[4]; + return_message[4] = 0; + return_message[5] = (DEVICE_SIGNATURE>>((2-message_body[6])*8))&0xFF;; + return_message[6] = STATUS_CMD_OK; + break; + default: + return_message_length = 7; + return_message[1] = STATUS_CMD_OK; + return_message[2] = 0; + return_message[3] = message_body[4]; + return_message[4] = 0; + return_message[5] = 0; + return_message[6] = STATUS_CMD_OK; + break; + } + + break; + case CMD_CHIP_ERASE_ISP: + for (uint32_t current_flash_address = APP_START_ADDR; current_flash_address < NVMCTRL_FLASH_SIZE; current_flash_address += NVMCTRL_ROW_SIZE) + { + enum status_code error_code; + do + { + error_code = nvm_is_ready(); + NVMCTRL->STATUS.reg |= NVMCTRL_STATUS_MASK; + + /* Set address and command */ + NVMCTRL->ADDR.reg = (uintptr_t)&NVM_MEMORY[current_flash_address / 4]; + NVMCTRL->CTRLA.reg = NVMCTRL_CTRLA_CMD_ER | NVMCTRL_CTRLA_CMDEX_KEY; + } while (error_code == STATUS_BUSY); + } + return_message_length = 2; + return_message[1] = STATUS_CMD_OK; + break; + case CMD_PROGRAM_FLASH_ISP: + + bytes_to_read_or_write = (message_body[1]<<8) + message_body[2]; + if(current_address >= APP_START_ADDR) + { + uint32_t i; + for(i = 0; i= APP_START_ADDR) + { + uint32_t i; + for(i = 0; i>8; + } + //nvm_read_buffer(current_address, return_message+2, bytes_to_read_or_write); + } + else + { + for(uint32_t i = 0; i<(message_body[1]<<8) + message_body[2]; i++) + { + return_message[i+2] = 0xFFFF; + } + } + current_address += bytes_to_read_or_write; + return_message[return_message_length-1] = STATUS_CMD_OK; + break; + } + //send message back + uint8_t checksum = 0; + checksum ^= MESSAGE_START; + SEND_RESPONSE(MESSAGE_START); + checksum ^= sequence_number; + SEND_RESPONSE(sequence_number); + checksum ^= (return_message_length>>8)&0xFF; + SEND_RESPONSE((return_message_length>>8)&0xFF); + checksum ^= return_message_length&0xFF; + SEND_RESPONSE((return_message_length)&0xFF); + checksum ^= TOKEN; + SEND_RESPONSE(TOKEN); + for(uint16_t i = 0; i< return_message_length; i++) + { + SEND_RESPONSE(return_message[i]); + } + uint8_t body_checksum = get_checksum(return_message_length, return_message); + checksum ^= body_checksum; + SEND_RESPONSE(checksum); +} + + + +#endif /* STK500V2_H_ */ \ No newline at end of file diff --git a/bootloaders/mzero/Bootloader_D21_M0_150515.hex b/bootloaders/mzero/Bootloader_D21_M0_150515.hex new file mode 100644 index 0000000..7eff845 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21_M0_150515.hex @@ -0,0 +1,1594 @@ +:10000000002C0020F5280000F1280000F128000055 +:1000100000000000000000000000000000000000E0 +:10002000000000000000000000000000F1280000B7 +:100030000000000000000000F1280000F12800008E +:10004000F1280000F1280000F12800006D0E0000EA +:10005000F1280000F1280000F1280000451F0000F1 +:10006000F1280000F1280000F1280000F12800002C +:10007000F1280000F1280000F1280000F12800001C +:10008000F1280000F1280000F1280000F12800000C +:10009000F1280000F1280000F1280000F1280000FC +:1000A000F1280000F1280000F1280000F1280000EC +:1000B00010B5064C2378002B07D1054B002B02D03E +:1000C000044800E000BF0123237010BD1C01002084 +:1000D000000000006432000008B5084B002B03D07C +:1000E0000748084900E000BF07480368002B03D019 +:1000F000064B002B00D0984708BDC046000000000A +:100100006432000020010020643200000000000082 +:10011000EFF3108072B6BFF35F8F034B00221A70AB +:10012000434258417047C04614010020024B1A78E0 +:10013000013AD2B21A707047CC030020044B1A78EF +:10014000013AD2B21A701B78024B00221A70704723 +:1001500042010020D2030020002070470020704799 +:1001600010B50F4B0F4C0020207018800E4BA122B1 +:100170001A7020225A7002220C4958809880DA8026 +:100180001881E1235B020B600823087148718B71B1 +:10019000074B9847237801200133DBB2237010BD51 +:1001A00066060020CC030020D80300203801002080 +:1001B0002D30000008B500200149024B984708BDCA +:1001C000380100202D300000002805D0034B01220B +:1001D0001A70BFF35F8F62B67047C04614010020EB +:1001E000124B60211A7850B20A40002809DA002028 +:1001F000202A1AD15A78212A17D1DA88072A14D14D +:100200000FE00020202A10D15A78202A04D0101C98 +:1002100022384242504108E0DA88072A05D10449D1 +:10022000196104499A819960012070476C09002086 +:10023000B501000038010020F7B5364B1A78002AC6 +:1002400066D1354CA047354D2C8800280FD0344B53 +:10025000984784425CD0334B9847334A334B1478E9 +:10026000071CE4B26100C95A002919D101E0304BE2 +:10027000EEE7304E28493388013333808847002821 +:1002800006D13388632B03D8381C2B4B98473FE0AB +:10029000214A9047002803D03288284B9A42F3D94C +:1002A000244B00221A80264B1B78934205D16342CF +:1002B00063411D49DBB20B7002E063425C41E4B272 +:1002C000144A01231370381C1B4B9847174B6700C7 +:1002D000DE5B413EFF3E731E9E41F6B2002E09D00A +:1002E0000D498847002801D00D4B00E0104B98477E +:1002F000288000E02E800D49A20124021419CB5B56 +:10030000104A1149121900918120311C0F4CA0474D +:10031000F7BDC046D4030020C5140000D003002060 +:10032000D914000011010000430100204401002005 +:10033000C914000040010020C90100001F03000093 +:1003400065060020480100205D03000055170000ED +:1003500008B5014B984708BD3902000008B50028D0 +:100360000CD1074B1A7853425A41064B5200D052D7 +:10037000054B1870054B1870054B984708BDC046D3 +:10038000430100204401002065060020D403002022 +:100390003902000010B5074B9847074A074B1B88E6 +:1003A0001178074A49008C5AE41A064B9847201CDA +:1003B00010BDC04611010000D3030020CE03002071 +:1003C000C8030020C901000008B5034B9847431E2D +:1003D0009841C0B208BDC04695030000F0B5194B66 +:1003E00085B098471849194A0C781578E4B2EDB2EF +:1003F000002D08D1164E670033880393154BFB5A26 +:10040000039FBB4203D9144B9847002018E0358066 +:1004100066426641F6B20E700F4F01261670B8475D +:100420000E4B281C9847A2010D4B240214190D4AAB +:100430000093A02312190220311CB3400A4CA0479C +:1004400005B0F0BD11010000D303002064060020B8 +:10045000CE030020C8030020C9010000C90300002A +:10046000F1040000E40300205517000038B5134BD9 +:10047000134D00242C701C70124B1C70124B1C70FE +:10048000124B1C805C80124B1C80124B9847124B05 +:100490001C70124B1C70124B1C80124B1C80124B98 +:1004A0009847A04209D02B780133DBB22B702B7810 +:1004B000DBB2012B01D10D4A137038BDD4030020EB +:1004C0004201002065060020430100204401002075 +:1004D000D00300203902000064060020D30300206E +:1004E000C8030020CE030020DD030000D20300205B +:1004F00013B500281CD10F4B1B785C426341DBB263 +:1005000000290ED199011B02CB180B49101CCB18E6 +:100510000A491A1C0091A02301218B40084CA047D6 +:1005200006E0084A5B009952074B1870074B984742 +:1005300013BDC046D3030020E4030020F1040000F3 +:1005400055170000C803002064060020DD030000EA +:1005500008B50020014B984708BDC046C9030000FC +:10056000F7B5194B00269B79093B5A425341DBB240 +:100570000193164B9847164B164F3C881D78164B27 +:100580009847EDB2154B6A00D35AA4B2A34205D8DE +:10059000134B1878C0B20028EBD113E0AB012D0249 +:1005A0005D19104B2D19EB5C01341E43A4B20E4BA8 +:1005B0003C809847019B002B03D000233602019317 +:1005C000D7E7301CFEBDC0463801002011010000F5 +:1005D000D3030020CE030020C9010000C80300207F +:1005E000D2030020E4030020DD03000038B5114BE6 +:1005F0009847114A114B1178C9B24C00E45AA02314 +:100600005B009C420FD10E4B1B78002B0BD10D4D84 +:100610002B78DBB2002B06D101242C704C426141B7 +:10062000C9B211701C1C084B9847A0204000001B49 +:1006300038BDC046110100004301002044010020E4 +:10064000D403002065060020C901000008B5034B53 +:100650009847431E9841C0B208BDC046ED05000052 +:1006600008B50020014B984708BDC0464D06000064 +:10067000F8B5154B0C1C9D79093D6B425D41EDB2FF +:100680000020124B9847002805D1114B1878C0B2B2 +:100690000028F5D117E00F4B98470F4B0F491B78F7 +:1006A000DBB25E00725A571C775299011B02CB18BD +:1006B0000B499A180B4B54549847002D02D0241222 +:1006C0000025DDE70120F8BD380100204D060000BF +:1006D000D20300201101000043010020440100204A +:1006E00048010020C901000008B5011C014B002091 +:1006F000984708BD7106000008B5034B58887F2352 +:100700001840024B984708BD6C090020D51800001E +:1007100030B5144B1A7800239A4221D0124B1B6833 +:100720001B681A79824201D8002319E00F4A13602E +:10073000DC789D7824022C431C199C420ED95D78EC +:10074000042D08D19D78854205D1DD788D4202D1F6 +:100750001360012304E01D785B19EEE71360E3E703 +:10076000181C30BD710600206806002074060020A9 +:10077000094B1B681B68DA78997812020A439B18A8 +:1007800002788018834205D94278042A02D0052ACB +:10079000F6D100E0002070476806002038B5104B05 +:1007A000051C9847002801D1002018E00D4B1C685B +:1007B000201C0D4B9847041E0AD06279237912023F +:1007C0001A438078E178094B98470028F0D1EBE78D +:1007D000074BAD001B685B68EB581B68984738BD3A +:1007E0001107000074060020710700003D1500008D +:1007F00068060020F8B500210F4F051CB847041EFD +:1008000018D00E4BAA001B685B68D658F36898474F +:10081000011C281CB847041E0CD0094B1D68281C5D +:10082000084B9847051E03D08078074B9847F6E79A +:1008300073689847201CF8BD110700006806002067 +:100840007406002071070000E914000008B5014B90 +:10085000984708BDA119000038B50C4B00241A7840 +:100860001D1CA24205D100232B70094B01221A80C6 +:1008700038BD084B1B681B681B79A342F3D9201CA9 +:10088000054B01349847E4B2F3E7C04671060020F7 +:100890006E06002068060020F507000008B5024B30 +:1008A0009847024B984708BD051A000059080000F8 +:1008B00010B50B4B00241B78A3420FD0094B1B68CB +:1008C00019680A79A24209D95B68A200D3581B694A +:1008D000002B00D098470134E4B2EFE710BDC046CA +:1008E0007106002068060020F8B5A44C0023A381FF +:1008F00023616361237858B2002803DAE288002A72 +:1009000000D1B2E16021194000D065E11F2200282A +:1009100000DBA9E0E588002D00D15DE1134067D13F +:100920006378062B09D0082B5DD0002B00D053E153 +:10093000022D00D050E1924892E06088050A022D15 +:100940000CD006D8012D00D046E18E4B18680178F6 +:1009500040E0032D1FD00F2D13D03DE1894BC0B2D5 +:1009600019684A7C824200D836E15B68C000C058F2 +:10097000C178837809021943834B9847A268557060 +:100980002AE0804B9868002800D125E1C17883785F +:10099000090219431EE0C0B2032800D91CE102F08D +:1009A00051FB070004000A0061011D21774A04E0A1 +:1009B000774804210EE0774A0A21002376485D003B +:1009C000D65C451901336E80DDB28D42F6D3490005 +:1009D000023101706C4B9847E388A2899A4200D893 +:1009E000CAE0A381C8E0012D00D0F5E06B4837E0F4 +:1009F000012B25D163780A2B00D0EDE0012D00D02A +:100A0000EAE0664B1B78002B00D1E5E0644B2679C9 +:100A10001F683A681379B34200D8DDE0301C614B9F +:100A20009847051E00D1D7E07B68B600F358DB6815 +:100A300098475D4B01211870181C534B984799E05B +:100A4000022B00D0C8E06378002B00D0C4E0022D58 +:100A500000D0C1E0554B20799847554B1880181CA1 +:100A6000291C494B984787E013404DD160780138E5 +:100A7000082800D9B0E002F0DBFA0CAFAFAF05AF49 +:100A8000AFAF1A00E388002B00D0A5E0494B2361EB +:100A900072E0E388002B00D09EE06388012B00D039 +:100AA0009AE0374B02211A888A431A8064E0E5886D +:100AB000002D00D090E0404B9847002800D18BE0FB +:100AC000304EA27831684B7C9A4200DD84E03B4B8B +:100AD0009847A378314A1370002B4DD03849304ADB +:100AE0005B187168DB00CB181360161C33681B6839 +:100AF0001B79AB4240D9281C0021324B9847002873 +:100B00006AD00135EDB2F1E7012B15D163780B2BDB +:100B100062D1E388002B5FD1204B1B78002B5BD088 +:100B20002579294B281C66889847002854D0F1B2B3 +:100B3000281C244B98471CE0022B4DD16378012BD5 +:100B400002D0032B09D047E0E388002B44D163880F +:100B5000002B41D120791D4B0AE0E388002B3BD1CB +:100B60006388002B38D12079194B98472079194B8D +:100B70009847051C002D2FD0012077E06C0900203C +:100B80006E060020A0000020F518000033000020B1 +:100B90009000002028000020540000207106002052 +:100BA00068060020110700007006002009160000EA +:100BB0006C060020F9060000E51800005908000046 +:100BC000FFFFFF1F9D070000F50700001917000039 +:100BD000891400001D16000022781F231340012BEA +:100BE0001ED1234B1B78002B1AD0224B25791E686F +:100BF00032681379AB4213D9281C00211E4FB84725 +:100C000000280DD07368AA00D658F3689847011CD5 +:100C1000281CB847002803D0B36898470028ABD1F8 +:100C200022781F231340022B1FD1114B00241B7865 +:100C3000002B1AD00F4B1B6819680A79A24214D9ED +:100C40005B68A200D558E96888470B4B011C201C43 +:100C50009847002809D0AB68984700288CD1013408 +:100C6000E4B2E7E70421054AA7E60020F8BDC04644 +:100C700071060020680600201107000026320000DF +:100C80000368987AC009704770B50C4B0822056854 +:100C9000041CDA67201C0A4EB0470028FAD12B88C2 +:100CA000022293432B8020756075201CB0470028DA +:100CB000FBD12B88012213432B8070BD04E100E09F +:100CC000810C0000F8B50668071C0D1C141C381CAC +:100CD0000F4B98470028FAD13A79002A0AD01A23F4 +:100CE000012A12D11723012C0FD80634A400A551D4 +:100CF000031C0AE01723022C07D806498D4204D8AA +:100D00000C34ADB26400A553131C181CF8BDC046CA +:100D1000810C0000FFFF0000F7B52D4B0160151C92 +:100D20009A6920210A439A6101A90223041C0B70CD +:100D30000420284B98470420274B9847274B201C1A +:100D40009847AB7823712B796371254B1C602B88F6 +:100D500026683380AB78002B16D01720012B36D1B4 +:100D600033889BB23380EB78002B03D0338880220A +:100D700013433380201C1B4B9847021EFAD1201CC2 +:100D8000A968194B984719E033880422134333802C +:100D9000EB781720002B1AD1201C124FB847021EE7 +:100DA000FAD1201CA968104FB847201C0D4B98475A +:100DB0000028FAD1201CE9680122B8472B790020CD +:100DC000834204D072888023DB0113437380FEBD0D +:100DD000000400400128000079270000890C000071 +:100DE00040070020810C0000C50C000070B503799D +:100DF000041C05680E1C1520002B05D1201C034B7C +:100E000098470028FAD1AE8270BDC046810C000020 +:100E1000031C022A0CD00079002805D0012805D136 +:100E20001720012A0FD803E0022A01D917200AE06F +:100E3000901C8000C1500120197D9040021C0A4383 +:100E4000D2B21A750020704710B5036880220229BB +:100E500003D001228A4003242240DA710122437D1B +:100E60008A40111C1943C9B2417510BD38B5114BE8 +:100E70001B68597D1C681A7D207A0A40E17901407F +:100E8000C80906D0510701D51B69984780232372F2 +:100E90000EE00125294203D02A4208D09B6805E0D4 +:100EA0000225294204D02A4201D0DB6898472572E6 +:100EB00038BDC04640070020EFF3108072B6BFF384 +:100EC0005F8F034B00221A70434258417047C0465F +:100ED000140100200F2303405B00C00918180238DA +:100EE00014235843014B18187047C0467C06002055 +:100EF000F0B58E7985B072B20D1C544B301C002AAF +:100F000046DA98470F2737400197028AC368029252 +:100F10006D88041CED188368C560877C9D4221D0D4 +:100F20005E1B4B4AB6B2964206D94A4B101C029938 +:100F30009847474B5E1AB6B20023BA0706D5464B10 +:100F4000301C029998478BB25A4253415A00A37CF5 +:100F500002218B4313436268A37452193F480199DD +:100F6000331C0AE0B807C00F0AD0022362689F430F +:100F70003A480199A77452190023394CA04763E0FD +:100F800001239F432368A774002B5DD0291C59E0DF +:100F900098470F2333400293038A041C0193837CF8 +:100FA0002F885A0710D5C268436801999B1803938C +:100FB0008068294B98470A1C02992A4B01398901FC +:100FC000C9180398284B9847E368FA18A368E260A9 +:100FD0009A4200D9E360AA88BA422AD1E5689D42C4 +:100FE00027D05E1B1A4FB6B2BE4206D9381C194B29 +:100FF000019998477F1ABBB205E0301C164B019946 +:101000009847761AB3B2019A1448184E93420BD2FD +:10101000A37C04221343029AA374013A114B920158 +:10102000D2180299019B02E0626802995219B047F6 +:101030000AE0A37C01229343A3742368002B03D00E +:10104000E1680020321C984705B0F0BDD50E0000C5 +:10105000FF1F0000A1310000E13000000408002063 +:101060006D1E00004407002005320000B91E00007C +:1010700010B5064B064C05221A70201C8021054B2A +:101080009847201C0021044B984710BDF70600200C +:1010900004080020F31D00000D1E000037B51E4B94 +:1010A000041C9847226801AD80239372281C1B4BB7 +:1010B000984703236B70291C201C194B9847201C50 +:1010C0001849194B9847194D201C00210222184B32 +:1010D000A84700210A1C201C164BA847164B201CB1 +:1010E00000210122A847154D201C00210222A847FB +:1010F00000210A1C201CA847201C00210122A8470F +:1011000023680F4A19890A408021C9000A431A81BD +:101110000C4B00221A7037BD59080000111C00004A +:10112000211C000084090020011F0000A91A0000F2 +:10113000951200004916000085110000F91A000000 +:10114000FFF3FFFFF706002010B5084B084C032201 +:101150001A70201C0749084B9847084B00219A68D1 +:10116000201C0B1C064CA04710BDC046F7060020F3 +:101170000408002084090020011F00006C090020E1 +:101180006D1E000008B589790C4B4AB2002A08DAB6 +:101190001B78012B02D10A4B98470DE0042B0BD191 +:1011A00007E01A78022A02D104221A7004E0032A06 +:1011B00002D10448044B984708BDC046F7060020FA +:1011C0004911000004080020F31D0000F8B51D4D72 +:1011D0001D4E2B88B4891D4FE41AA4B2002C1BD1DC +:1011E0001B4A11885B189BB21380F2889A4203D085 +:1011F000184B1B78002B07D0174B04221A70381C91 +:101200001649174B98471CE07369002B0BD0984781 +:10121000002808D02C80B4893F2C04D90D4B002223 +:101220001A70402402E00B4B01221A702B88B2681E +:10123000381CD2180021231C0A4EB0472B88E41812 +:101240002C80F8BDF40600206C0900200408002062 +:1012500078060020F8060020F70600208409002008 +:10126000011F00006D1E000008B5014B984708BD26 +:10127000B1080000064B9A8C910605D4D968D0229B +:101280000A40D02AFAD102E0DA68D106FCD57047CC +:101290000008004070B5274E0C1C3378002B06D098 +:1012A000254B1B69002B00D09847002333702388FF +:1012B000082B01D0214B2DE0214C1F4D23782B70A2 +:1012C00063786B70E378A2781B02D3186B80637924 +:1012D00022791B02D318AB80E379A2791B02D318C1 +:1012E000EB80184B98470028E4D02B787F2B0DD942 +:1012F000154B00211980154B221C198002233370D5 +:1013000013484023134CA047134B03E0EB88002BFA +:1013100002D1124B98470BE00B4B002119800B4B6D +:10132000221C19800123337009484023094CA0472F +:1013300070BDC046F70600206C0900207110000047 +:1013400084090020E908000078060020F406002047 +:1013500004080020B91E0000CD1100004911000052 +:10136000002805D0034B01221A70BFF35F8F62B6CD +:101370007047C04614010020F7B501AE114B041CA4 +:101380001149301C04229847104B1D78A54217D0F4 +:10139000002C08D00E4B375D98470E4BDA5D0132BA +:1013A000DA550D4B9847002D08D0094B755D9847CD +:1013B000084B5A5D013A5A55074B9847034B1C702E +:1013C000F7BDC046053200002B320000F6060020B3 +:1013D000B90E0000380700206113000038B5084C32 +:1013E000084D201C0621A847201C0421A8470221E3 +:1013F000201C054B98470220044B984738BDC04637 +:10140000040800208D1A00006D1A000079130000F6 +:1014100038B50B4B98470B4C0B4B201C02219847BF +:101420000A4D201C0421A847094A0A4B201C06210A +:1014300098470621201CA8470320074B984738BD32 +:1014400075120000040800208D1A00006D1A0000BB +:10145000DD1300004D1A00007913000010B5064C92 +:101460000421201C054B98470221201C044B98475F +:101470000120044B984710BD040800208D1A00007D +:101480006D1A00007913000038B5041C211C0A48AD +:101490000A4B98470A4B201C9847827C031CD107B3 +:1014A00008D501201D6882439A74002D02D0D968A6 +:1014B000221CA84738BDC04604080020A91D000012 +:1014C000D50E000000207047024B1B68188A80046C +:1014D000400D704704080020024B1B68188A80B238 +:1014E0007047C04604080020F7B501AD041C0D4B41 +:1014F000281C9847201C0C4B98470C4F0026291C91 +:10150000381C0B4BEE702C7098470F21321C214079 +:10151000381C084B9847381C321C211C064B984736 +:10152000F7BDC046111C000089140000040800200B +:10153000211C0000D11A0000851B0000F7B501AC8A +:10154000061C294B201C0F1C151C984726700023D5 +:10155000082D1DD90123102D1AD90223202D17D9AA +:101560000323402D14D90423802D11D980235B003F +:101570009D4201D805230BE080239B009D4201D8AA +:10158000062305E0194B9D4201D900202AE00723DC +:101590006370301C164B98470323391C0582194091 +:1015A000012901D1022304E0022902D00329ECD150 +:1015B0000423104DE370211C281C0F4B9847041E78 +:1015C000E3D10F21221C0D4B3140281C0C4FB84792 +:1015D000221C311C0B4C281CA047281C311C01224A +:1015E000A0470120FEBDC046111C0000FF03000003 +:1015F000D50E000004080020211C0000F10E0000A0 +:10160000A91A0000F91A000008B5011C014B024894 +:10161000984708BDD51D0000040800200F2310B511 +:101620000340041C0020032B07D80448211C044B52 +:101630009847201C034B9847012010BD0408002048 +:10164000F31D000089140000F8B5284E3378012BF3 +:101650003FD1274A274C0D881788A3897A199342CE +:1016600001DADD1BADB2A3682349D8192A1C234B2C +:10167000EF199847BBB21E4F3B80402D05D1204D3E +:10168000E1882A88D218914208DCA3816369002B83 +:1016900002D0984700280AD01A4B1DE0A2899A422E +:1016A00010D16069002802D08047002804D10523AA +:1016B0003370154B984718E03A882B88D3182B8045 +:1016C00000233B8000210C4A4023104C1048A047C7 +:1016D0000BE0022B02D10F4B984706E0054B1B692C +:1016E000002B00D0984700233370F8BDF706002088 +:1016F000F40600206C090020840900200532000057 +:1017000078060020491100001D160000B91E0000D7 +:1017100004080020CD1100000F2370B50340061C03 +:101720000024032B0ED8084B9847084B051C311C8E +:1017300007489847AB7C0124DA0703D5A343AB7471 +:101740002B689847201C70BDD50E00000D1E0000B0 +:1017500004080020F0B51E1C0F2385B00340071CB1 +:10176000029103920193032B01D9002596E04D4B82 +:101770009847051EF9D14C4B381C98474B4B041C1D +:101780009847A27CD10702D5494B984786E00123B0 +:101790001A43A274002804D0464A1370BFF35F8F27 +:1017A00062B60023E3600A9B039A0298A17C23603F +:1017B00001236260184002229840914301430420B3 +:1017C0008143A17479B2A660002930DA002E1AD0C4 +:1017D000394DB6B2AE4205D9218A281C374B9847FD +:1017E0006E1AB6B202990023994206D0344B218A70 +:1017F000301C98478BB25A4253415A00A37C0221B5 +:101800008B43134304E00299002909D0A37C93433E +:10181000A3740199039A331C2A4C2B48A0473AE041 +:10182000A27C9A43A2740A9A002A08D10CE0002EE6 +:101830000CD1A27C0A999A43A274002904D00020FA +:10184000011C3A1C0A9B9847012527E01A4FB6B2A3 +:10185000258ABE4206D9381C184B291C98477F1A86 +:10186000BBB205E0301C164B291C9847761AB3B260 +:101870001548164EAB420BD2A37C04221343019AA7 +:10188000A374013A124B9201D21801992B1C01E06A +:101890000199039AB04745424541EDB2281C05B075 +:1018A000F0BDC04609160000D50E0000B90E0000BC +:1018B0006113000014010020FF1F0000A13100008F +:1018C000E13000006D1E000004080020B91E000079 +:1018D00044070020024B80221B6810439872704717 +:1018E00004080020024B1B68987A7F231840704739 +:1018F00004080020014B9860998170476C09002012 +:1019000008B5044B01201B681A8902431A81024B57 +:10191000984708BD0408002079130000F8B503209B +:10192000164B9847164C01272368164E1A89201C1F +:10193000BA431A810421144AB047201C0021134ADB +:10194000B047391C201C124AB047124A201C022101 +:10195000B047114D201C0421A847201C0021A84796 +:10196000391C201CA847201C0221A8470B4A201C18 +:101970000621B047201C0621A847F8BD79130000B6 +:10198000040800204D1A00005D14000069120000D8 +:101990009D100000111400006D1A0000DD130000FE +:1019A00073B50E4B984701AC061C0D4B201C984795 +:1019B0000C4D00230C49221CA370281C0B4B98478C +:1019C000281C0B4B98470B4B984701200A4B984714 +:1019D0000A4B9847301C0A4B984773BDB90E00005C +:1019E000552100000408002000500041652100003E +:1019F000311F000075120000791300001D1900004E +:101A00006113000010B5074B98470020064B98471C +:101A1000064B9847064B041C9847201C054B9847DB +:101A200010BDC0460119000079130000B90E000076 +:101A3000391A000061130000034B1A78002A01D004 +:101A400000221A707047C046F90600200B1C2E3386 +:101A50009B001A50044AAA235B004900895AC25AC3 +:101A60000A43C2520020704730320000064B490042 +:101A70000268CB5A9383AB225200815A1943815298 +:101A8000026800201383704730320000054BAB2200 +:101A900052004900CB5A815A994381520268002072 +:101AA000938270473032000010B58C00A418343493 +:101AB000A4000419411863605931044BFF310878C0 +:101AC0009B5C03430B70002010BDC0463E320000FB +:101AD00010B58C00A418031C34345B18A40004193E +:101AE0000449002059336060FF33895C1A788A43C7 +:101AF0001A7010BD3E32000070B50F230B40C418A1 +:101B000061341F4DFF342678AD5C35432570002AC3 +:101B10000ED10268002B02D1FF3203230FE05B01DC +:101B2000D31849B2FF330222002926DB012224E028 +:101B3000012A0FD10268002B03D1FF320C239372CC +:101B40001CE05B01D31849B2FF330822002914DBE3 +:101B5000042212E0022A05D102685B01D318FF3388 +:101B600010220AE0032A09D102685B01D31849B2A6 +:101B7000FF334022002900DB20229A72002070BD32 +:101B80003E32000070B50F230B40C4181F4D613466 +:101B9000FF34AE5C2578B5432570002A0ED102686B +:101BA000002B02D1FF3203230FE05B01D31849B2AF +:101BB000FF330222002926DB012224E0012A0FD173 +:101BC0000268002B03D1FF320C2353721CE05B012F +:101BD000D31849B2FF330822002914DB042212E093 +:101BE000022A05D102685B01D318FF3310220AE0F4 +:101BF000032A09D102685B01D31849B2FF3340229E +:101C0000002900DB20225A72002070BD3E32000005 +:101C100000230370437083700123C370704700007A +:101C2000F0B5021C0D78C8780F232B40ED0904286D +:101C300000D998E0146801F0FBF90308495D7A00C7 +:101C400008335B010020E054A9E05D016419FF3412 +:101C500066781C20770700D0A1E0677870263742AD +:101C600000D09CE011206070146808335B01E0181C +:101C7000402444711268D31880221A718A78484B24 +:101C8000002A08D05A195468802000060443546082 +:101C90005469204307E05A195068400040085060DA +:101CA00050694000400850615D194C78686807220F +:101CB0003C4B1440184024072043686049780A4090 +:101CC000696912070B4013436B6162E058012418E5 +:101CD000FF34002D07D0677870261C2037425ED174 +:101CE0006078202612E066781C20770757D160784C +:101CF00002262FE058012418FF34002D10D06778F9 +:101D000070261C2037424AD16078302630436070FC +:101D100010681A1C0832520182188020107122E0CB +:101D200066781C2077073AD16078032612E05801C4 +:101D30002418FF34002D07D0677870261C20374206 +:101D40002DD160784026E1E766781C20770726D100 +:101D5000607804263043607010681A1C0832520103 +:101D60008218402050715B005D190D4B48782D01A1 +:101D70005B19072210405C680A4A000722400243B0 +:101D80005A608878002806D05968802212060A43D3 +:101D90005A60002003E05A68520052085A60F0BDB1 +:101DA000C4090020FFFFFF8F0F230B400268083398 +:101DB0005B0149B2D218002905DA8021117102684D +:101DC000D318022204E0402151710268D318012285 +:101DD000DA7170470F220A400368083252019B18DB +:101DE00049B29879002901DA800600E0C006C00FE8 +:101DF00070470F220A4003680832520149B29B180B +:101E00002022002900DB10225A71704730B50F22C2 +:101E10000A404CB201685301C918FF31CD79002C3A +:101E200011DA2024254220D04C710168CB18FF33F1 +:101E30001C7A40210C4218D01972036808325201F2 +:101E40009A18022310E0102425420ED04C7101682C +:101E5000CB18FF331C7A20210C4206D0197203687C +:101E6000083252019A180123137130BD70B50D1C50 +:101E7000046808356D012E5D1C247606760F14D09B +:101E80000B4C490161180A610C1C0A4A49690A4055 +:101E900062619A046369920C9B0B9B031343636119 +:101EA000036800245D1980236B71201C70BDC0463F +:101EB000C4090020FF3F00F0F0B50D1C0468083590 +:101EC0006D012E5D1C24770713D00B4C49010A517C +:101ED00061184C689A04094B1209234013434B6064 +:101EE0004B6800249B0B9B034B6003685D194023E8 +:101EF0002B71201CF0BDC046C4090020FF3F00F03C +:101F0000094B0A4A196059680A40802189020A432C +:101F10005A605A68920B92035A6003684022FF335A +:101F200000205A717047C046C4090020FF3F00F0EE +:101F3000036802211A780A431A7002689378022B08 +:101F4000FCD07047F0B57E4C85B0206802681378ED +:101F5000DB0900D0F2E0118C8FB2002F4CD1AB2303 +:101F60005B00C65A958BAA235B00ADB2C35A2E40C4 +:101F70001E40744B7A00D35A1D4202D02268126868 +:101F800093831E420FD07049062F06D16F4B1A89DA +:101F9000802312095B0013400B603B1C20682E332A +:101FA0009B001B5898470137072FE2D1C6E01E1C43 +:101FB0000836B025009674016D00C618751959369B +:101FC0001419FF36B4460294E4792E7803956546D9 +:101FD0002D78E4B22E40351C60262540344212D1C3 +:101FE000102634422AD10C2634423AD1A60776D1A3 +:101FF0000133082B00D1A1E03C1C1C410125D9B2C2 +:102000002C42F5D0D3E75C011219FF32167A402436 +:10201000264204D0147280225242114304E0167A00 +:102020002024264202D01472494A9171602215423E +:1020300000D183E01B01C318DC337CE0029F0399CD +:10204000FE710A78324279D040495A018A185268A2 +:102050001B0192043E49C318920CD8330A805B6876 +:102060006BE05C011219FF32177A082637421DD047 +:102070001672364A1419A67E02221834164202D06D +:10208000A6789643A670802252421143304A91713D +:10209000009902684F01D719FA7994074ED40C229F +:1020A00015424BD01B01C318D43344E0167A0427E1 +:1020B0003E42F4D01772254A1219967A0224083249 +:1020C000264202D09678A6439670214A91710099D3 +:1020D00002684F01D719FA79D407E0D52EE05C01E8 +:1020E0001219FF32177ABC46664602273E420CD0D0 +:1020F000802617727642164A3143917113490C19A2 +:1021000061698904890C518010E0177A01263742F1 +:102110000CD016720E4A91710C490C196168890431 +:10212000890C118061680901890C9180AF0705D085 +:102130000D331B01C3185B680549984705B0F0BD16 +:102140000C07002030320000FC060020C4090020EB +:102150000407002000220123027043708270C370C4 +:1021600070470000F7B5171C634A00231360634AE9 +:10217000051C1060624A29600C1CD169202001AE48 +:1021800001430120D16106227370B070F3701820F2 +:102190005C4B311C3270984706205A4A3070311C13 +:1021A00019209047BB786846037069460620564B55 +:1021B0009847564B062098472378012213432370F3 +:1021C000A378D807FCD452490B685A0B1F231A4036 +:1021D0009A4200D105221A409001268D4D4A324084 +:1021E000024322850868820C13401F2B00D11D2357 +:1021F000208D1F2213409043034323850B68072241 +:10220000DB0D1340934200D103231340218D1A03A9 +:10221000414B42480B401343238521783A787F2372 +:10222000D2010B401343237079780123194023789E +:102230000422890093430B4323706062FB78012BD7 +:1022400004D12B680C211A898A4306E0002B05D1A2 +:102250002B680C241989A1430A431A818022304B30 +:102260000021520098470023E918002204334A60F5 +:10227000202BF9D1A918002310324B628B62CB625C +:102280000B63802AF6D12A1CA43213705370E9180C +:10229000081C0022A630AE31013302700A70082BF0 +:1022A000F5D1131CE918B831002204330A601C2B45 +:1022B000F8D1A918081C0023D430E0311032036093 +:1022C000436083600B60802AF3D1AA225200AB5294 +:1022D000AB225200AB52AC20EA1840001118613218 +:1022E0000020FF32013308701070082BF3D10D4B22 +:1022F00080221A60FEBDC046000700200C070020A7 +:10230000000400409D2800000128000079270000FB +:10231000246080003FF8FFFFFF8FFFFFC40900200B +:102320001732000000E100E0094B196800290BD1C9 +:10233000EFF31080074A002805D172B6BFF35F8F14 +:1023400005490870012111701A6801321A6070473E +:10235000100700201407002014010020084B1A6801 +:10236000013A1A601B68002B09D1064B1B78002B21 +:1023700005D0054B01221A70BFF35F8F62B670471C +:10238000100700201407002014010020F7B50023D7 +:1023900001AC144E80270125A370211CBF0211201F +:1023A000114B657025709847B761211C11200E4BA9 +:1023B00025709847B761211C9836082723200A4BBF +:1023C000257098473760211C1B20074B25709847C4 +:1023D000002337600F202370211C034B6570984742 +:1023E000F7BDC04600440041ED23000007B5802240 +:1023F00001AB1A700A785A704A789A708A78191C58 +:10240000DA70014B984707BD9D28000010B50C4BB2 +:1024100002211A680A431A60196880229143094A06 +:1024200089B29184101CC168064ACC06FBD5996814 +:102430000020D162596891621B689BB2938410BDE1 +:10244000180700200008004070B50D4B45781E6A43 +:10245000817804780122402086431540AD01301C6C +:102460000A402843D10180229043021C0A430548B8 +:1024700003212140090202400A431A6270BDC0468E +:1024800000080040FFFCFFFF30B5027A4389920646 +:102490009B059B0D120C1A43124B5A60428881888F +:1024A000C4791143827922430A434178C9010A431E +:1024B0001A600278042A0BD1047BC189058A0A4874 +:1024C000A40609042C43014021439960196806E0E1 +:1024D000202A06D1028A9A6019688422D2000A430F +:1024E0001A6030BD180700200000FF0308B5082857 +:1024F00028D800F09DFD122727100B18051E21007B +:10250000114B02211A6A0A431A6204E00E4B02219F +:102510009A690A439A61002015E00B4B02211A8A3E +:102520000A431A82F7E7084B02219A8A0A439A82E1 +:10253000F1E7064B984706E0054B02211A780A435B +:102540001A70E8E7172008BD000800400D240000BD +:1025500044080040F0B5C223344EDB00B360344B76 +:102560001E215A688BB08A4304210A435A6005A889 +:102570000023438083714370072303733F2320228A +:10258000C3812C4B02701A68920E3F2A00D11F2281 +:10259000294B2A491B689B059B0D8B4200D1284B78 +:1025A00043810823C37180235B008380254B027223 +:1025B0000382254B984701A8012300258370234BF4 +:1025C000457005709847224B06209847214B984745 +:1025D00002AC0323211C65702572657223700220F2 +:1025E00020231D4D6360A84702201C4FB8471C4B99 +:1025F00098472A1CF1680D4BC806FBD5998C8020A2 +:1026000001439984174B002507211D72281C5D7218 +:102610009D7201232170211C6360237265706572B5 +:102620009047281CB8470BB0F0BDC04600080040DA +:10263000004000412460800028608000FF0300000B +:10264000FF01000080BBFFFF892400004924000037 +:10265000ED240000752600009526000039270000B3 +:102660000D24000000040040014B5878C009704759 +:10267000000C0040054B08219A690A439A61044BFB +:1026800001221A701A78D107FCD470470004004068 +:10269000000C0040F8B50C784B782402051C061C91 +:1026A0000443002B02D08023DB021C434B7A002B17 +:1026B00002D080231B031C434B68012B13D95E1EE1 +:1026C0001E400222002E09D19A4202D20136520047 +:1026D000FAE7360280232E435B0303E01E028023C9 +:1026E0002E439B021C430B7A002B02D080239B03BA +:1026F0001C430C4FB8470028FBD10B4B98470B4BA2 +:102700001D70B8470028FCD1094DAE60B8470028BD +:10271000FCD16A6880235B0213401C436C60054B4C +:102720009847F8BD6926000029230000080C0040E6 +:10273000000C00405D23000038B5051C094CA04783 +:102740000028FBD1084B9847084B1D70A047002874 +:10275000FCD1074B8022596852020A435A60054B4C +:10276000984738BD6926000029230000040C00406A +:10277000000C00405D23000010B5074B041C984777 +:10278000064B80221C70064BD20159880A435A809E +:10279000044B984710BDC04629230000020C00409E +:1027A000000C00405D23000038B50F4B041C984717 +:1027B0000E4B0F4A1C700F4B598858880905104062 +:1027C00058805C880C48090F20405880101C5C8899 +:1027D000084A6504FBD45388090203400B43538025 +:1027E000064B984738BDC04629230000020C004024 +:1027F000FFF0FFFF000C0040FFBFFFFF5D23000064 +:1028000010B50C78034B240204439847024BA4B242 +:102810005C8010BDA9270000000C004030B5D478C2 +:1028200000239C421AD11478802C03D080232406E4 +:102830005B02234354780225AC4309D19478002CE1 +:1028400002D18024A40201E0C024E40223434160B9 +:102850005478013C012C01D80F4C2340A0248DB2A8 +:10286000E4052C431C438462D0240D0C24062C4325 +:102870001C438462D478002C0CD15C0305D593787A +:10288000012B01D1816100E041615378013B012BB3 +:1028900000D8816030BDC046FFFFFBFF08B5031CB8 +:1028A0000A1C4009D90903D10549C001401800E0BC +:1028B00000201F210B4001219940024B984708BD81 +:1028C000004400411D2800007047000008B5044B7B +:1028D0009847044B9847044B9847044B984708BDCA +:1028E000552500008D230000C9280000C9280000DC +:1028F000FEE700001148124910B5884201D00023BC +:1029000001E0104B07E0104CCA18A242F9D2C4589B +:1029100004331460F7E70D4A191D043B934203D2B8 +:1029200000221A600B1CF6E7094A0A4B7F218A43F2 +:102930009A60094B9847094B9847FEE764320000BC +:1029400000000020200100201C010020FC0B0020C2 +:102950000000000000ED00E0B9310000652F00002C +:1029600008B51D4B1A6802321A601968FA22520122 +:10297000914209D9194A1A4908201368C867997AF7 +:1029800049B200290BDAFAE718683221154B98474B +:10299000002920D18022144B9202DA611BE01988B1 +:1029A000022081431980136880221A720F4AC023C3 +:1029B00008215B00D1500E4B984772B6BFF35F8F72 +:1029C0000C4B00221A70BFF34F8F0B4A0B4BDA608F +:1029D000BFF34F8FFEE708BD34070020C40A002074 +:1029E00004E100E0E13000000044004100E100E0CB +:1029F0009D080000140100200400FA0500ED00E02D +:102A000008B5074B08221A60064B98470028FBD0F0 +:102A1000054B08221A600020044B9847C0B208BD3D +:102A200098440041510500009444004161050000B4 +:102A3000084A80231B0570B5041C9361151C1E1CDD +:102A4000054B98470028FBD06E61201C034B98472C +:102A500070BDC0460044004161060000E906000068 +:102A60000B4B0C4A1968914211D91A68D2B2002A4C +:102A700009D01A68012152085200494211801A688F +:102A800002321A60F1E7044B1B7DDA07FBD5704771 +:102A900018010020FF3F00000040004110B50B1C52 +:102AA00000225C1AA4B2844203D21C780133624033 +:102AB000F7E7101C10BD0000F0B5944BC9B0587971 +:102AC0006946087001381C2800D9F8E000F0B0FA17 +:102AD0000F5A32F7F75DF7F7F7F7F7F7F7F7F7ADB4 +:102AE00053869EC2F7F7F7F7F7F725F76B00002339 +:102AF0004B7008238B704123CB7056230B715223EC +:102B00004B7149238B715323CB7150230B725F237D +:102B10004B7232238B720B24D2E05A7A00234B7013 +:102B200002218A1A7A49D2006E461141B170F370BF +:102B30000424C5E09B7900224A70902B10D006D85F +:102B4000802B0BD0812B11D102238B7011E0912BA4 +:102B500009D0922B0AD105238B700AE0012306E0ED +:102B600003248C70ACE004238B7002E000236946E0 +:102B70008B700324A4E000234B70664A664B1A60F6 +:102B800002249DE000234B70FAE79979DA7909066F +:102B900012040A43597A1B7A0A431B021A435F4BF9 +:102BA00052001A602EE0597A002230290DD16E466B +:102BB000DB7AF1700221CB1A5549DB0019417270A2 +:102BC000B27032717171B27106E068464270827003 +:102BD000C170027142718271072471E08022D201BA +:102BE0004F4B197D188B2021FF3101431983910828 +:102BF0004900D9614B4901321980FF328023DB0241 +:102C00009A42EDD1002369464B70B9E79879DA7999 +:102C10004249000210180C68434A80B2944208D816 +:102C20000B68C018414B0860984700236A465370F0 +:102C3000A6E70F3300228242F2D25D780C681E783C +:102C400014192D02640875196400ADB22580023292 +:102C50000233F0E79879DB790002304A18186E46A3 +:102C6000002381B27370304D1668CC1CA4B2AE4202 +:102C70001DD98B4212D21568981C5D196D086D0024 +:102C80002D886E463554156800AE5B195B085B00F5 +:102C90001D8833182D0A5D70031CEAE7136800A82D +:102CA000C91803191160013B00221A7008E0834221 +:102CB000F4D000AEF518FF26AE700133F7E700241C +:102CC0001B4D1B20A8471B4B260A1F78381CA84702 +:102CD000F0B2A8471B235F4067407E40E0B2F7B2E6 +:102CE000A8470E204740A8470026B3B2A34204D20B +:102CF0006946885DA8470136F7E769460E4B201CF8 +:102D000098474740F8B2A84749B0F0BDDC0A002018 +:102D100001981E004C1D00003407002018010020FF +:102D20000040004102A5FFFFFF3F0000612A0000B4 +:102D3000312A0000320700209D2A0000F8B5002744 +:102D40003D1C3C1C1F4B98471F49061C485501352C +:102D5000062CF7D8201C00F06BF904080C11171C86 +:102D600023001B2E28D00025ECE7184B02241E70F0 +:102D7000E8E7174B36021E800324E3E7144B0424D4 +:102D80001A8816431E80DDE70E2E17D10027052472 +:102D9000D8E70F4B01371B889F42D3D10624D1E7D8 +:102DA000013DA8B20B4B98470025B04207D10A4B12 +:102DB0001D600A4B9847F8BD0124C3E700252C1C71 +:102DC000C0E7C046012A0000DC0A002032070020CC +:102DD000300700209D2A000034070020B92A000097 +:102DE000094B0421DA690A43DA61084B2022198B66 +:102DF000FF320A431A831A7DD10703D559681E2270 +:102E00000A405A607047C04600040040004000413C +:102E10007FB500236A46164CD370138093700293DB +:102E20000393012313711349134B201C134E98472E +:102E300008222368326021688A7A52B2002AFBDBBA +:102E40001A8802252A431A80201C2A1C0C490D4B83 +:102E50009847291C201C0C4B9847201C01210B4B28 +:102E60009847C023AB40F2581202120AF2507FBDBD +:102E7000C40A002000140040190D000000E100E029 +:102E800061290000110E0000490E0000ED0D000048 +:102E9000F0B5294B85B09847284B1A7DD007FBD554 +:102EA000274F69463A88274E0A81274A11886A4681 +:102EB0005181318803AA1180244A11886A46D18140 +:102EC000029907220A40012A31D01A8BD00530D44A +:102ED00059688022D2020A4301915A601A8B202538 +:102EE000FF352A431A831A4C1A4ADC611A80197D6D +:102EF000124AC807FBD5108B284310831648D461AB +:102F00001080197D01200D4A0142FAD0138B1D4318 +:102F10001583D461029B0724634018430290029BEF +:102F20003B6003980D4B30601380019951600C4B4E +:102F3000984705B0F0BDC04629230000004000417D +:102F40000040800004408000024080000640800075 +:102F50000020400005A5FFFF44A5FFFF06A5FFFFD9 +:102F60005D23000008B58022214B92029A618022E5 +:102F700012059A611F4B08221A601F4B1A7852B231 +:102F8000002A03DB1A7802218A431A701B4B1A7835 +:102F9000D10611D41B789A060ED48023DB01188841 +:102FA00017491A1C884207D01B6883F30888154B01 +:102FB0009A60154B1B689847144B01221A70BFF397 +:102FC0005F8F62B6124B9847124B9847124B984747 +:102FD000124B9847124AC1239B00D058802100020F +:102FE000000AC9050143D1500E4B98470E4BFCE730 +:102FF0000044004198440041001000403804004063 +:10300000FFFF000000ED00E004400000140100207C +:10301000CD280000112E0000E12D00004D08000019 +:1030200000E100E0912E00003D2D000070470000FF +:1030300002B4714649084900095C49008E4402BC4B +:103040007047C04603B47146490840004900095A18 +:1030500049008E4403BC7047002934D0012300226C +:1030600010B488422CD301242407A14204D2814207 +:1030700002D209011B01F8E7E400A14204D2814217 +:1030800002D249005B00F8E7884201D3401A1A4394 +:103090004C08A04202D3001B5C0822438C08A042CB +:1030A00002D3001B9C082243CC08A04202D3001B81 +:1030B000DC082243002803D01B0901D00909E3E7FB +:1030C000101C10BC7047002801D00020C04307B47A +:1030D000024802A14018029003BDC046D90000007A +:1030E0000029F0D003B5FFF7B9FF0EBC4243891A9F +:1030F0001847C046002941D010B4041C4C40A446D7 +:1031000001230022002900D54942002800D5404271 +:1031100088422CD301242407A14204D2814202D246 +:1031200009011B01F8E7E400A14204D2814202D266 +:1031300049005B00F8E7884201D3401A1A434C0863 +:10314000A04202D3001B5C0822438C08A04202D399 +:10315000001B9C082243CC08A04202D3001BDC08C1 +:103160002243002803D01B0901D00909E3E7101C02 +:103170006446002C00D5404210BC7047002806D0A1 +:1031800003DB0020C043400801E08020000607B4B4 +:10319000024802A14018029003BDC0461900000079 +:1031A0000029EBD003B5FFF7A7FF0EBC4243891AF5 +:1031B0001847C0467047C04670B50E4B0E4D0024F0 +:1031C000ED1AAD101E1CAC4204D0A300F358984772 +:1031D0000134F8E700F036F8084B094D0024ED1AE9 +:1031E000AD101E1CAC4204D0A300F3589847013424 +:1031F000F8E770BD5032000050320000503200003D +:103200005432000010B50023934203D0CC5CC45468 +:103210000133F9E710BD031C8218934202D01970E4 +:103220000133FAE7704730303444000003020100F4 +:103230000400080070008000010000010002030C7F +:1032400010600000F8B5C046F8BC08BC9E46704748 +:10325000D9000000F8B5C046F8BC08BC9E467047CF +:04326000B1000000B9 +:103264006D0400003D010000590100005D010000F3 +:1032740051030000610100002D010000E101000084 +:103284005D0100000000000041726475696E6F20EA +:103294004D300041726475696E6F2073726C202822 +:1032A4007777772E41726475696E6F2E6F72672916 +:1032B4000000000000030000000000000000000007 +:1032C40000000000000000000000000000000000FA +:1032D40000000000000000000000000000000000EA +:1032E40000000000000000000000000000000000DA +:1032F40004030904050F0C0001071002020000007A +:10330400BC000020B4000020940000201400002021 +:1033140000000020D0000020AC00002012010102B7 +:1033240002000040032A4E000001010203010000D4 +:1033340009024300020100C0320904000001020234 +:1033440001000524001001042402020524060001E2 +:10335400052401030107058303400010090401004B +:10336400020A00000007058102400000070502026E +:0C337400400000000100000000400000CC +:04000003000028F5DC +:104000000080002035430000FB410000FB41000020 +:1040100000000000000000000000000000000000A0 +:10402000000000000000000000000000FB41000054 +:104030000000000000000000FB410000E94100001A +:10404000FB410000FB410000FB410000FB41000080 +:10405000FB410000FB410000FB410000E14B000080 +:10406000FB410000D5490000FB410000FB4100007E +:10407000FB410000FB410000E5490000FB4100005E +:10408000FB410000FB410000FB410000FB41000040 +:10409000FB410000FB410000FB410000FB41000030 +:1040A000FB410000FB410000FB410000FB41000020 +:1040B00010B5064C2378002B07D1054B002B02D0FE +:1040C000044800E000BF0123237010BD2C00002035 +:1040D00000000000086A000008B5084B002B03D060 +:1040E0000748084900E000BF07480368002B03D0D9 +:1040F000064B002B00D0984708BDC04600000000CA +:10410000086A0000300000202800002000000000A5 +:1041100008B50D20012100F09FF908BD10B5FA2463 +:104120000121A4000D2000F043FA201C00F04CF8FF +:1041300000210D2000F03CFA201C00F045F810BDD5 +:1041400038B5134D1349281C00F074FA124913486E +:1041500000F070FA1249134800F06CFA1249134843 +:1041600000F068FA1249134800F064FA124C13493F +:10417000201C00F05FFA291C00220123104800F0E7 +:104180008FFB211C242223230E4800F089FB38BD1D +:104190000C01002000080042000C00421001002029 +:1041A0000010004214010020001400420801002009 +:1041B00000180042180100201C010020001C0042D1 +:1041C00048000020A800002070B5041E08D0054B50 +:1041D0001D681E1C00F010F833685B1BA342F9D960 +:1041E00070BDC04620010020024B1A6801321A60DF +:1041F0007047C046200100207047FEE730B5404BB5 +:104200001E225968082091430222114359603D49FA +:104210008B6903438B613C483C4B9882988A0243EC +:104220009A82DA689007FCD5394A0120107010781C +:10423000C40704D53648407840B20028F7DB012097 +:104240009060507840B20028FBDB324C304844602C +:10425000507840B20028FBDB82242D48E4014480E2 +:10426000507840B20028FBDB988C8024A0439884CF +:10427000D868C506FCD5284C2448C462DC682348AD +:10428000E506FBD5848C254D2C438484DC681F48CF +:10429000E506FBD5848C02252C438484D86804066B +:1042A000FCD51A48C0684506F8D5D868C406FCD5C0 +:1042B00000209060507840B20028FBDB184C144876 +:1042C00044605478124864B2002CFADB1D6A154C25 +:1042D0002C401C621C6A8025AC431C620323836053 +:1042E000114B436053785BB2002BFBDB00230B7256 +:1042F0000E4A4B728B72CB720D4B1A6030BDC046AA +:1043000000400041000400400C060000000800408E +:10431000000C004001050100B805FF7D040A000003 +:1043200000070300FFFCFFFF03060100006CDC0236 +:104330000000002038B51049104CA14206D101F010 +:10434000A5FFFFF75BFF00F059F90BE00C4D8D4224 +:10435000F5D00023CA18E818A24204D2006804333A +:104360001060F7E7FEE79042E9D0064B064A934219 +:10437000E5D2002204C3F9E7000000202C00002051 +:10438000286A00002C000020AC050020264BFA21F2 +:10439000186810B5890001F0CBF9244B0138984218 +:1043A0001DD8234B234A5860106AC0210002000A1E +:1043B000090601431162002407229C601A601E4B0B +:1043C000FC211A6A0A431A62196AFF2212020A437E +:1043D0001A62196AA022D2020A431A6200E0FEE7BA +:1043E000201C0021013400F037F8132CF8D1134BB6 +:1043F000134AA0215380134BC900998012491961B7 +:104400001121997002215970187801431970597E51 +:10441000C9090129FBD00D4B53800D4B41225A7025 +:104420000C4A1A8110BDC04600000020FFFFFF00AB +:1044300010E000E000ED00E0000400401E4000003D +:10444000000C0040004000420018000F2140000016 +:1044500000480042FF03000070B518244443204B7D +:1044600008261A1996571D1C013638D0012919D073 +:1044700000290AD0022932D1E3561A495268DB01D9 +:104480005B1899184031062007E0E3561549526839 +:10449000DB015B189918403102200870012191401E +:1044A00059601CE0182811D0182358432B560D4989 +:1044B00028184268DB015B189918403108780224FB +:1044C000A043087001219140996008E0064B022149 +:1044D0001A780A431A70DA79D209FCD1E4E770BD80 +:1044E0001463000000440041004800421822424387 +:1044F000F8B52D4D0824AA181457031C621C50D07F +:10450000481C00240C284CD801F008F9071E1E1E78 +:104510001E1E1E1E1E0A0A0A0A000124644240E0F2 +:10452000092902D1181C002103E00A2904D1181C12 +:104530000221FFF791FF23E000240B2931D1181C41 +:104540000121FFF789FF2CE018225343EA18526833 +:10455000EB560120141C04405508DB01002C11D03F +:10456000124C1B195D1930352E780C010F2131408A +:1045700021439A18C9B22970403213781843107039 +:1045800000240EE0094E0F279B195D1930352E7857 +:104590009A18BE433143C9B2297040321378184388 +:1045A0001070201CF8BDC046146300000044004198 +:1045B000182358430E4A30B5131808241C570134E9 +:1045C00015D080560B4C5B68C0010219D4184034DA +:1045D00004252570002904D0012908D19940916152 +:1045E00005E001229A40131C034A8018436030BD45 +:1045F00014630000004400411044004110B5FFF76F +:10460000C5FE0120FFF7E0FD084C201C00F0B2FAC7 +:10461000201C00F09DFAFFF77BFDFFF77FFD044BA8 +:10462000002BFAD000E000BFF7E7C0462C010020C5 +:104630000000000001607047F7B508AC26780468F8 +:104640009D1E27686C1EA541ECB2920705683A438F +:1046500027063A432A600268072529405068B501B9 +:10466000002C00D05C03294301430C435460F7BD88 +:1046700030B50368C0251C68AD0312052A402243EB +:10468000C024A402090421401143196003685A6838 +:1046900014435C6030BD036801211A680A431A6044 +:1046A0000268116801231942FBD1D1691942F8D17E +:1046B0007047036802211A680A431A600268D369C6 +:1046C0009907FCD470470268137ED907FCD5704760 +:1046D000036800225A8370470368187E4007C00FA2 +:1046E00070470368588B4007C00F70470368588BAA +:1046F0008007C00F70470368588B0123184070472C +:104700000368188DC0B2704738B5041C0D1CFFF744 +:10471000DAFF236801201D8538BD000002682349A7 +:1047200030B58A4210D022498A4210D021498A42AB +:1047300010D021498A4210D020498A4210D0204905 +:104740008A4210D0002210E0092314220DE00A232F +:1047500015220AE00B23162207E00C23172204E09F +:104760000D23182201E00E23192258B2012484409F +:104770001449800880000C6040180325C02189007E +:104780002B40AB404458FF259D40AC43C0259D4085 +:104790002B1C234343508023DB011A430A4B5A80CE +:1047A0005A7852B2002AFBDB30BDC04600080042F6 +:1047B000000C0042001000420014004200180042A9 +:1047C000001C004200E100E0000C0040F8B5041CB1 +:1047D000151C0F1C1E1CFFF75EFF201CFFF79EFF21 +:1047E000B9001C220A4069072368090C0A431A60B1 +:1047F000226884239375012F26D11020002D03D029 +:104800000320022D00D1082001F0DAFB051C301C2A +:1048100001F0D6FB011C281C01F018F90B4B051CFC +:10482000186801F0CDFB011C281C00F0E9FF011CF9 +:10483000FE20800501F034FA054901F007F900F087 +:10484000C7FF246880B2A081F8BDC04600000020E8 +:1048500000FF7F470120704710B5041C0069FFF777 +:104860001AFF201C143000F06CFD10BD08B5006963 +:10487000FFF729FF08BD08B5143000F074FD08BD2E +:1048800008B5143000F075FD08BD08B5143000F00F +:104890005CFD08BD08B50069FFF736FF012008BDC3 +:1048A000F8B51D1C00234360FA239B008360084B6E +:1048B000041C0833036014300F1C161C00F02BFD81 +:1048C000231C5C332761201C1E705D70F8BDC04640 +:1048D0009867000010B5041C0069FFF7FDFE002872 +:1048E00007D02069FFF70CFF011C201C143000F0DA +:1048F0001DFD2069FFF7F5FE002809D12069FFF7AB +:10490000F5FE002804D12069FFF7F5FE002802D04B +:104910002069FFF7DDFE10BD0F23081C98433038D7 +:10492000434258417047002070470F231940012926 +:1049300005D002394B424B410220C01A00E0002052 +:1049400070470000F0B5031C85B003915C33041C74 +:10495000182718783B1C43431A4E0821F318595660 +:10496000151CFFF7C3FD231C5D331878082147434E +:10497000F6197156FFF7BAFD039B00222069012149 +:10498000FFF724FF291C201CFFF7CDFF291C071C63 +:10499000201CFFF7CAFF291C061C201CFFF7BCFFC8 +:1049A000331C0090391C20690122FFF745FE206965 +:1049B00001210322FFF75CFE2069FFF77AFE05B0B4 +:1049C000F0BDC0461463000008B51322FFF7BAFF1C +:1049D00008BD000008B50248FFF77CFF08BDC046CF +:1049E0004800002008B50248FFF774FF08BDC04624 +:1049F000A800002008B500F03FFC08BDF8B5124B38 +:104A0000061C1B680D1C171C002B02D101246042E0 +:104A100019E000F031FC041EBC4200D93C1C2F19E7 +:104A2000BD4205D0301C00F0E1FB28700135F7E7EE +:104A3000002C07D0301C00F01FFC002802D1301CD5 +:104A400000F024FC201CF8BD3801002013B56C4692 +:104A50000734211C0122FFF7D1FF012801D1207862 +:104A600001E00120404216BD38B5104B051C1B6803 +:104A7000141C002B15D000F099FB08350C4A6B0173 +:104A80009B18DA7902210A43DA715979802252425D +:104A90000A435A71064A6B019B18DB799A07F9D5CC +:104AA00002E00120404200E0201C38BD3801002017 +:104AB00000500041F8B50F1C161C141C0025002CDA +:104AC00007D07919221C002000F070FB2D18241A41 +:104AD000F5E7301CF8BD30B50123A1B0C218013A8A +:104AE00014785A00002C0CD1C0239B001343694654 +:104AF00000200B80FFF7DEFF431E9841C0B221B0BB +:104B000030BD8D1A002DEFDD6D46AC520133E5E767 +:104B100008B50279002A04D100F0A6FC002809D1CA +:104B200006E00023022A06D100F01AFD002801D079 +:104B300000F09CFA0123181C08BD10B5041C00F0FD +:104B40009BFB002802D0201C00F0AAFB10BD000037 +:104B5000064B10B51B680024A34204D000F07AFA7B +:104B6000034B1C600124201C10BDC04628010020FE +:104B70003801002008B500F0D7F9024B01221A6075 +:104B800008BDC0462801002008B502280CD1A22388 +:104B9000114A40215B00D15400F06EFB002819D06F +:104BA0000E4800F02FFC15E0032806D10A4BB22274 +:104BB000520080219954682207E001280AD1064B4F +:104BC00092225200802199542822FF32995C0220BF +:104BD0000143995408BDC0460050004184040020A0 +:104BE000F0B5B24CA9B0268C1025F6B2002E1BD120 +:104BF0002023A582A3820123A382A38B08273B4203 +:104C00000AD08023A372301C311C00F037FAA84B65 +:104C10009D72A84B1E60A783228B04231A4200D1E9 +:104C20007BE1A24A938378E1A14B1A7AD2B2029235 +:104C30002A4200D159E11D72002004A900F00AFBAC +:104C40009B4840234371049B60201D78284000D07E +:104C500024E15A78002A0CD108A9002D03D10D7047 +:104C60004D70281C14E0944B1B78012B0BD00A705C +:104C70000CE0012A11D19B78012B0BD18F4B08A995 +:104C80001B78012B01D10B7000E0087000204870E8 +:104C90000222F8E0884B1870FDE0032A11D19A78BF +:104CA000012A05D1854B08A91A70087000F07EFA18 +:104CB00004998B78002B00D0F5E07F4B01221A700D +:104CC000E9E0052A03D1987800F0F4FAEBE0062A2F +:104CD00000D0ABE0DD78022D60D1DB88019300F0DD +:104CE000BDFB071C00F0BEFB041C00F017FC001904 +:104CF000039000F0B7FB041C00F010FC019A24188C +:104D00000934A24207D900F0ADFB041C00F006FCF8 +:104D100024180934019405AD0924221C281C002103 +:104D200001F0E3FA2C70039C02226B465A75093499 +:104D30006B46DC82032206AB1A7001226B465A7660 +:104D4000C0226B46DA7608ACFA2307AA1370221C3D +:104D500003CD03C20025137000F084FB854205D209 +:104D60007A5D631901355A72EDB2F5E700F0D2FBB6 +:104D70000025071C00F0D2FB854208D200F072FB30 +:104D80007B5D6219101801354372EDB2F2E7019AAA +:104D9000802A00D980220020211C44E0222D02D14B +:104DA00000F0C0FB18E0212D1AD108AC0927002122 +:104DB0003A1C201C01F099FA0123A370E37063717F +:104DC000222327706570A37100F0AAFB211CE071FB +:104DD0003A1C0020FFF76EFE431E9841C0B260E00F +:104DE000012D04D1DA883649112A1AD816E0032D8C +:104DF00070D19A78002A05D13249DA880B7893422B +:104E00000CD80EE0022A02D1D9882F4803E0012AEB +:104E100060D1D9882D48FFF75EFE42E0D2B2002A69 +:104E200000D10A780020FFF745FE3CE0072A51D068 +:104E3000082A02D100201F4924E0092A1ED1EA06CF +:104E400048D10420832100F019F90120822100F0CB +:104E500015F90220011C00F011F90320832100F054 +:104E60000DF9049B9A78134B1A602A230222FF3310 +:104E7000E2544A230122FF33E2540CE00A2A05D10E +:104E800013490020012200F091F90CE00B2A0AD10D +:104E90009A780F4B1A6000F0E9F804E0181CFFF74D +:104EA00037FE002816D000F07BF916E000500041D4 +:104EB000FF5000413801002024010020340100206F +:104EC000E4670000E0670000C8670000D3670000E7 +:104ED00030010020002000F0C5F90298402318425C +:104EE00003D00F490B7220234B7101239E430024F2 +:104EF000E0B2002E11D0331C2341DA070AD509494C +:104F000063015B18DB799A0701D0FFF73DFE0123AF +:104F1000A3409E430134092CEAD129B0F0BDC0461C +:104F2000FF5000410051004130B53E4B2021DA696D +:104F300001200A43DA613C4B06241A7802431A70B6 +:104F40003A4B0F221978914319701978214319703F +:104F500037490C782043087019780A401A701A787B +:104F600060210A431A70334B334A5A805A7852B23E +:104F7000002AFBDB314B01211A780A431A70997819 +:104F80002E4AC807FBD41178022001432C48117027 +:104F90000268510B1F221140914200D1052111409E +:104FA0008C011D8D27492940214319850468A10CD6 +:104FB0000A401F2A00D11D221C8D1F210A408C434C +:104FC00022431A8502680721D20D0A408A4200D185 +:104FD00003220A40188D11031B4A02400A431A8516 +:104FE00019787F220A401A701A7804210A431A702D +:104FF000164A0C205A621989814319810023D1185D +:10500000002008602033802189018B42F7D1104BAA +:10501000C122920099580902090A995080221A6007 +:1050200030BDC04600040040584400413C440041AB +:1050300059440041000C004006400000005000416F +:10504000246080003FF8FFFFFF8FFFFFAC040020CB +:1050500000E100E0044B01211A898A431A810822E9 +:105060001A8304221A83704700500041024B5A6988 +:10507000920B92035A617047AC040020F0B583296B +:1050800011D1021C3F4B083252014021D1543E4AFB +:105090004301D3185C693D493D4AC00121401018C5 +:1050A000596118616DE002291FD13A4B4201364C1B +:1050B000D11803234B70A3185E68344D800135402E +:1050C000C026B60535435D60334D28181051586829 +:1050D000324A02408020400302435A605A68920BD1 +:1050E00092035A6040234B714BE0822914D1294C22 +:1050F00042011319302159702349244C8A185569EB +:1051000023492C40C025AD05C0012C43081854612B +:10511000106180225A7134E0002932D11D494001CA +:1051200042181123184D8024537064424023937118 +:1051300054712B185968154F4900490859605E6928 +:105140001549760076085E615E683E40B446C0262A +:10515000B605644634435C605C6927403E435E614B +:10516000415158680D4901408020C00201435960F7 +:105170005968890B89035960802340215B429171F2 +:105180005371F0BD00500041AC040020FFFFFF8FC1 +:105190003C010020FF5000413C030020FF3F00F095 +:1051A000014B80229A717047FF50004170B50C4D41 +:1051B000C301ED18061C281C141C01F08DF8094BC6 +:1051C00076019E1935617169074A201C0A40726197 +:1051D0007269A104920B890C92030A43726170BD3B +:1051E0003C010020AC040020FF3F00F070B5134CE0 +:1051F000134A8101430165189D50D2185668114D1C +:1052000035408026B602354355605568AD0BAD0379 +:1052100055600D4A9D180D4A9B1840225A712B1C4F +:10522000FF331A7A01231A42F9D0094A4001801843 +:10523000C2791343C371605C70BDC0463C0300205B +:10524000AC040020FF3F00F000500041FF5000413F +:1052500000510041024B8001181808607047C04699 +:105260003C030020034BC0B24001C018202343710F +:105270007047C04600510041034B40011818406878 +:105280008004800C7047C046AC040020034B4001F2 +:10529000C01840234371012303727047FF5000413F +:1052A000034B4001C01880238371022303727047AF +:1052B000FF5000410C4B02215A69920B92035A6134 +:1052C0000A4B1A7A0A431A729979802252420A4387 +:1052D0009A711A7A9107FCD580235B421843044BDC +:1052E000C0B298727047C046AC040020FF50004125 +:1052F00000500041F8B5061C0C1C8F180025BC425C +:1053000007D0336821781B68301C984701342D186A +:10531000F5E7281CF8BD10B500214022041C00F060 +:10532000E4FF0023201C2364636410BD026C10B5ED +:105330003F23541C2340446CA34201D08154036496 +:1053400010BD0023036443647047436C026C9342B6 +:1053500006D0C25C3F2101330B404364101C01E0C6 +:10536000012040427047026C436CD01A00D5403097 +:105370007047436C026C934201D0C05C01E0012095 +:1053800040427047034B186C5B6CC01A3F231840B7 +:105390007047C0463C040020054B196C5A6C914282 +:1053A00002D05A6C985C01E0012040427047C04630 +:1053B0003C04002013B502686B46D971073354686A +:1053C000191C0122A04716BD38B50D4B041C196CE1 +:1053D0005A6C914211D05A6C3F219D5C5A6C02204C +:1053E00001320A405A64FFF705FB002803D0236806 +:1053F000201C9B699847281C01E00120404238BDD1 +:105400003C04002038B50C4D2C6C3F2301341C406B +:105410006B6C9C420FD00220FFF7ECFA002803D1FE +:105420000220FFF733FF06E00220FFF70FFB2B6C93 +:105430002C64E854E9E738BD3C04002008B503209B +:10544000FFF77BFB08BD10B5041C0320FFF70CFB26 +:10545000002801D10123636010BD0000004870479F +:10546000206800004220704710B50278041C437881 +:10547000A12A08D1212B2CD1002017490722FFF7A0 +:1054800019FB012026E0212A23D1202B0DD1002059 +:10549000FFF7F2FE0E28FAD90023E218117A0E4A1D +:1054A00099540133072BF8D113E0222B11D18278C4 +:1054B000094BDA7119689622D200914209D1DC7940 +:1054C00001231C4003D1FA2000F016F901E000F09E +:1054D0001DF9002010BDC04604000020044B00222E +:1054E0005A60FA2292009A60024A08321A607047A3 +:1054F00084040020F8670000036870B59B68041CF2 +:105500000D1C98472368061C291CDB68201C984743 +:10551000F0B270BD0048704708690000192070475C +:105520006520704708B5002002496522FFF7C2FADE +:1055300008BDC0462169000013B56B461870141CE5 +:1055400000235A1CA34206D0131C8A18013A127871 +:105550006846C254F5E769460420FFF785FA13BD93 +:1055600008B50178031C4278A1290ED10223101C32 +:105570009843012817D000209A4214D10A490122E9 +:10558000FFF714FEFFF70CFE0CE0002021290AD1E2 +:105590000B2A02D19A78054B03E00A2A03D1DA7864 +:1055A000014B1A70012008BD0D0000200C000020E6 +:1055B00008B502200822FFF7BFFF08BD10B58729F4 +:1055C00002D97831C9B218E04BB2002B08DA803921 +:1055D00001238B40191C037A1943017200210CE04E +:1055E000194B595C00292BD04BB2002B05DA037AFA +:1055F0000222134303727F231940837A8B4219D00E +:10560000C37A8B4216D0037B8B4213D0437B8B42F1 +:1056100010D0837B8B420DD0C37B8B420AD00023FA +:10562000C218947A002C01D1917203E00133062B49 +:10563000F6D105E0011C0831FFF7BAFF012002E0B6 +:1056400001234360002010BD8868000010B5872941 +:1056500002D97831C9B219E04BB2002B08DA80398F +:1056600001238B40191C037A8B43037200210DE048 +:10567000114B595C002399421BD04BB2002B05DA29 +:10568000037A0222934303727F231940031C0622EC +:10569000002904D09C7A8C4201D100249C72013AEA +:1056A000D2B20133002AF3D1011C0831FFF780FF89 +:1056B0000123181C10BDC0468868000008B5011CF5 +:1056C00000238372C372037343738373C3730372C0 +:1056D0000831FFF76DFF08BD044B00221A70044B20 +:1056E0005A60044A08321A607047C0469804002085 +:1056F0009C0400206868000008B5024B1860024B4B +:105700009847C046100000200D6A0000024B01229D +:1057100052421A607047C0461000002002B4714621 +:1057200049084900095C49008E4402BC7047C046E4 +:10573000002934D00123002210B488422CD3012444 +:105740002407A14204D2814202D209011B01F8E7D9 +:10575000E400A14204D2814202D249005B00F8E792 +:10576000884201D3401A1A434C08A04202D3001BBE +:105770005C0822438C08A04202D3001B9C082243F1 +:10578000CC08A04202D3001BDC082243002803D02F +:105790001B0901D00909E3E7101C10BC7047002861 +:1057A00001D00020C04307B4024802A14018029073 +:1057B00003BDC046190000000029F0D003B5FFF773 +:1057C000B9FF0EBC4243891A1847C0467047C0460D +:1057D0009E2110B5C905041C00F072FC002803D1FD +:1057E000201C00F0CDFB10BD9E21C905201C00F03F +:1057F00057FA00F0C5FB80231B06C018F3E7C0462C +:10580000F0B55F4656464D464446F0B44602450064 +:10581000C00F85B00F1C760A2D0E804641D0FF2D9B +:1058200026D08024240400212643F6007F3D8946AB +:105830008B46F90F7C027800640A000E00918A46BC +:105840003CD0FF2834D080231B041C430023E400F9 +:105850007F380193009F4346019A7B4049469C460E +:1058600011430F2900D971E0764F89007F58BF4658 +:10587000002E3ED10822022391469B46D9E75A4684 +:10588000341CC24601920199022937D0032900D164 +:10589000CFE0012900D0ABE053460B4000220026A8 +:1058A00032E0002E19D10421012289469346C0E737 +:1058B000221C531E9A4102320192CBE70127019725 +:1058C000002CC7D0201C00F005FC431F9C40762311 +:1058D0005B420021181A0191BCE7301C00F0FAFB72 +:1058E0007625431F9E406D4200232D1A99469B4604 +:1058F0009FE70C23032199468B469AE7D446012360 +:1059000067463B40FF2200267602D205700ADB077D +:105910001043184305B03CBC90469946A246AB469E +:10592000F0BD80260023F603FF22EDE700220026CB +:10593000EAE78020C00306423BD0044239D1061C6E +:1059400026437602760A009BFF22DDE7281A0390A1 +:1059500076016401A64239D3361B1A2201230120A5 +:10596000311C5B007600002901DBB44201D8361BF4 +:105970000343013A002AF3DC741EA641341C1C4385 +:10598000039A7F32002A27DD630704D00F232340C8 +:10599000042B00D00434270103D52B4B039A1C4061 +:1059A0008032FE2A0BDD012361460B40FF220026D8 +:1059B000AAE706437602760A4346FF22A4E7A4013B +:1059C00001236746660AD2B23B409DE7039F1B2234 +:1059D000013F03970023C2E77E23039F5B42DB1B4B +:1059E0001B2B07DD012361460B40002200268BE7BD +:1059F000D446C5E7221CDA40039B9E339C40231CFF +:105A00005C1EA34113435A0704D00F221A40042AF4 +:105A100000D004335F0105D5012361460B4001220C +:105A2000002671E79E01624601231340760A002298 +:105A30006AE78026F60326437602760A5346FF225B +:105A400062E7C04688690000FFFFFFF7F0B55F46D8 +:105A500056464D464446F0B44402460083B00F1CFF +:105A6000640A360EC50F002E41D0FF2E22D08023AF +:105A70001B0400201C43E4007F3E82468046391C04 +:105A80004B007F02C90F7F0A1B0E8B463BD0FF2BBA +:105A900034D0802212041743FF007F3B00215A4676 +:105AA0006A40019252460A430F2A63D87A4892000C +:105AB00082589746002C3FD10822022392469846EE +:105AC000DDE70195404602282AD1019A01251540BB +:105AD000FF2300246402DB05600AED071843284316 +:105AE00003B03CBC90469946A246AB46F0BD002CA4 +:105AF00027D10420012282469046C0E7391C4A1E65 +:105B000091410231CBE70121002FC8D0381C00F0B1 +:105B1000E1FA431F9F4076235B421B1A0021BEE738 +:105B2000032800D1AEE001284FD101984246104031 +:105B3000C5B200230024CDE70C2303209A468046FB +:105B40009DE7201C00F0C6FA7626431F9C40764253 +:105B50000023361A9A46984691E780240025E403EC +:105B6000FF23B7E75B463C1C01938846AAE73C1C31 +:105B70008846A7E7250C24043A0C240C3F04F618A9 +:105B80003F0C211C231C794353436F435543FB189F +:105B90000A0C9B18B1469F4202D980225202AD18CE +:105BA00009041A04090C521894011B0C611E8C4143 +:105BB000920EED181443AD012C43230105D50122AB +:105BC00063080120144081441C434B467F33002B63 +:105BD0002DDD600704D00F222240042A00D00434B7 +:105BE000220103D52D4B1C404B468033FE2B17DD85 +:105BF000019B01251D400024FF236BE78020C0038B +:105C0000044208D0074206D1041C3C436402640AE3 +:105C10005D46FF235EE704436402640AFF2359E7FD +:105C20000198A4010125640ADBB2054052E77E23F6 +:105C30005B424A469B1A1B2B05DD019B01251D403B +:105C40000024002346E7221CDA404B469E339C404A +:105C5000231C5C1EA3411343580704D00F221A4093 +:105C6000042A00D004335A0105D5019B01251D40AB +:105C7000002401232EE701989C010125640A0540B8 +:105C8000002327E78027FF03019B3C436402012593 +:105C90001D40640AFF231DE7C8690000FFFFFFF7EE +:105CA000F8B5C20F430244004D024800240E161CF2 +:105CB0009B09000EC90FAD09FF2800D17EE0012726 +:105CC00079408A4258D0221A002A00DC89E0002854 +:105CD0001BD1002D00D075E0580704D00F221A40C8 +:105CE000042A00D00433590138D50134FF2C00D1E7 +:105CF00083E09B0101225B0AE0B232405B02C405F3 +:105D0000580AD20720431043F8BDFF2CE4D080216D +:105D1000C9040D431B2A00DD2DE1291C2020D140A0 +:105D2000821A95406A1E95410D435B1B5801D3D5DD +:105D30009B019F09381C00F0CDF9421F9740944207 +:105D400060DC141B1F231B1B3A1C9F40611C3B1C67 +:105D5000CA405F1EBB4113430024BDE70122DB089C +:105D6000E0B23240FF2C04D1002B7ED08021C90349 +:105D70000B435B025B0AC1E7211A002946DD0028BC +:105D800026D0FF2CA8D08020C00405431B2900DDAD +:105D9000EFE0281C2027C840791A8D40691E8D41EC +:105DA00005435B19590197D50134FF2C5CD0734929 +:105DB00001221A400B405B0813438DE7002D00D0F1 +:105DC0007FE77CE7013A002AAFD0FF2CA2D183E71E +:105DD000002D00D180E701390029E2D0FF2CD5D178 +:105DE0007AE7002A1ED1621CD2B2012A4EDD5F1B67 +:105DF0007A0126D5EF1A0E1C9CE701223240FF20C3 +:105E000000237BE75D4BA41A3B4065E7002946D1A0 +:105E1000611CC8B201282ADDFF2925D0EB185B08D8 +:105E20000C1C59E7002C13D0FF2818D08024E40460 +:105E3000524223431B2A4DDD0123EB1A041C0E1C86 +:105E400074E7002F00D075E700220020002390E7C0 +:105E5000002B3BD0D243002AEFD0FF28EAD12B1CE5 +:105E6000FF240E1C38E70022FF20002346E7002C09 +:105E70005AD1002B77D0002D00D12DE75B195801A6 +:105E800000D429E73D4A0124134025E7002C15D111 +:105E9000002B2FD1002DD7D02B1C0E1C1CE7002C63 +:105EA00021D1002B53D0C943002904D0FF284BD067 +:105EB0001B294FDD01235B19041C73E7002B22D142 +:105EC000002DD0D02B1C0E1CFF2405E72B1C041C1E +:105ED0000E1C01E71C1C2026D440B21A93405A1E07 +:105EE00093412343A9E7FF282ED08024E4044942AC +:105EF0002343DDE7002D00D1EEE65A1B500134D5D7 +:105F0000EB1A0E1CE8E6FF24002D00D1E4E6802207 +:105F1000DB08D203134204D0ED08154201D12B1C3B +:105F20000E1CDB00FF24D7E6002B0DD0FF24002D34 +:105F300000D1D1E68022DB08D2031342F1D0ED0874 +:105F40001542EED12B1CECE72B1CFF24C4E62B1CC6 +:105F5000041CC1E61C1C2027CC40791A8B40591E1A +:105F60008B412343A7E72B1CB6E6131E00D0B3E6F4 +:105F70006AE7012515E70125D7E6C046FFFFFFFBCD +:105F80004302590A4300C20F1B0E00207E2B0DDD79 +:105F90009D2B0CDC802000040143952B0ADC96200D +:105FA000C31AD9404842002A00D1081C7047034B4D +:105FB000D018FBE7963B9940F4E7C046FFFFFF7F10 +:105FC00010B5041E33D000F085F89E231B1A962BC3 +:105FD00009DC083884406402640ADBB26402DB0531 +:105FE000600A184310BD992B0ADD0522121A211CE4 +:105FF000D1400A1C011C1B318C40611E8C41144392 +:10600000052801DD421F9440144A2240610704D054 +:106010000F210C40042C00D0043251010AD59F23DB +:10602000181AFF2816D09401640AC3B2D6E70023D9 +:106030000024D3E7D208FF2B03D05402640ADBB25A +:10604000CCE7002A06D08024E40314436402640AE7 +:10605000FF23C3E7FF230024C0E7C046FFFFFFFB89 +:106060008446081C6146FFE71FB500F0C3F800280E +:1060700001D40021C8421FBD10B500F049F84042CC +:10608000013010BD10B500F0B5F8002801DB00208C +:1060900010BD012010BDC04610B500F0ABF80028BF +:1060A00001DD002010BD012010BDC04610B500F07C +:1060B00059F8002801DC002010BD012010BDC046A9 +:1060C00010B500F04FF8002801DA002010BD0120C3 +:1060D00010BDC0461C2101231B04984201D3000CB3 +:1060E00010391B0A984201D3000A08391B0998424B +:1060F00001D30009043902A2105C40187047C04661 +:106100000403020201010101000000000000000080 +:106110004A02430270B55C0A550A43004A001B0E4E +:10612000C60F120EC90FFF2B05D0FF2A08D0012081 +:1061300093420BD070BD0120002CFBD1FF2AF6D179 +:106140000120002DF6D101209342F3D1AC42F1D1D0 +:106150008E4205D0002BEDD1201C441EA041E9E762 +:106160000020E7E74A024302F0B55C0A550A430003 +:106170004A001B0EC60F120EC90FFF2B31D0FF2A8B +:1061800034D0002B16D1604260418446002A14D0DE +:10619000002820D18E4217D1934215DC04DBAC429B +:1061A00012D80020AC4212D270427041404201230A +:1061B00018430CE0002AEDD194466F426F416046CF +:1061C000002805D1002FE5D0704201231843F0BD0F +:1061D0000020002FFBD14842484140420123184390 +:1061E000F5E7002CCBD002204042F0E7002DC8D0CC +:1061F000F9E7C0464A024302F0B55C0A550A43007B +:106200004A001B0EC60F120EC90FFF2B27D0FF2A04 +:1062100029D0002B10D0002A15D194466F426F412F +:106220006046002815D00020002F04D14842484184 +:10623000404201231843F0BD604260418446002A79 +:10624000ECD00028F2D18E4211D0704201231843C5 +:10625000F1E7002FF7D0704201231843EBE702204B +:10626000002CE8D1D3E70220002DE4D1D1E79342FE +:10627000EBDC04DBAC42E8D80020AC42DBD270425D +:106280007041404201231843D5E7C04670B50E4B1C +:106290000E4D0024ED1AAD101E1CAC4204D0A3001C +:1062A000F35898470134F8E700F028F8084B094DF7 +:1062B0000024ED1AAD101E1CAC4204D0A300F3580C +:1062C00098470134F8E770BD140000201400002046 +:1062D000140000202400002010B50023934203D0B6 +:1062E000CC5CC4540133F9E710BD031C82189342FF +:1062F00002D019700133FAE770470000F8B5C046C4 +:10630000F8BC08BC9E467047F8B5C046F8BC08BC4F +:106310009E467047000000000B00000002000000D5 +:106320001C000000FF00FFFFFFFF0B00000000004B +:106330000A000000020000001C000000FF00FFFF38 +:10634000FFFF0A0000000000080000000400000039 +:106350001C000000FF000000000010000000000012 +:1063600009000000040000001C000000FF00010004 +:1063700001000900000000000E0000000400000001 +:106380001C000000FF00000300030E0000000000DE +:106390000F000000040000001C000000FF000103CB +:1063A00001030F00000000001400000005000000C1 +:1063B0001C000000FF0006000600040000000000B2 +:1063C00015000000050000001C000000FF00070091 +:1063D00007000500000000000600000004000000A7 +:1063E0001C000000FF00000100010400000000008C +:1063F00007000000040000001C000000FF00010175 +:10640000010105000000000012000000040000006F +:106410001C000000FF000003000302000000000059 +:1064200010000000040000001C000000FF0000023B +:106430000002000000000000130000000400000043 +:106440001C000000FF000103010303000000000026 +:1064500011000000040000000C000000FF00010219 +:10646000FFFF0100FF00000000000000FF0000002F +:1064700000000000FF00FFFFFFFFFF000000000022 +:10648000030000000100000002000000FF00FFFF09 +:10649000FFFFFF00000000001600000002000000E7 +:1064A00004000000FF00FFFFFFFF060000000000E7 +:1064B000170000000200000004000000FF00FFFFC2 +:1064C000FFFF0700000000000C00000003000000B8 +:1064D00004000000FF00FFFFFFFF0C00FF000000B2 +:1064E00000000000FF00000000000000FF00FFFFB0 +:1064F000FFFFFF00010000000B0000000300000090 +:1065000004000000FF00FFFFFFFF0B000100000080 +:106510000A0000000300000004000000FF00FFFF6D +:10652000FFFF0A00FF00000000000000FF00000065 +:1065300000000000FF00FFFFFFFFFF00FF00000062 +:1065400000000000FF00000000000000FF00FFFF4F +:10655000FFFFFF000000000002000000010000003B +:10656000020000000000FFFFFFFF0200010000002A +:106570000800000001000000020000000200FFFF10 +:10658000FFFF0800010000000900000001000000FA +:10659000020000000300FFFFFFFF090000000000F1 +:1065A0000400000001000000020000000400FFFFE2 +:1065B000FFFF0400000000000500000001000000D3 +:1065C000020000000500FFFFFFFF050000000000C3 +:1065D0000200000001000000020000000A00FFFFAE +:1065E000FFFF020001000000030000000B0000009C +:1065F00004000000FF00FFFFFFFFFF00000000009D +:106600001B0000000B00000004000000FF00FFFF63 +:10661000FFFFFF00000000001C000000060000005B +:1066200000000000FF00FFFFFFFFFF000000000070 +:10663000180000000600000000000000FF00FFFF3F +:10664000FFFFFF000000000019000000060000002E +:1066500000000000FF00FFFFFFFFFF00010000003F +:10666000160000000300000000000000FF00FFFF14 +:10667000FFFFFF0001000000170000000300000002 +:1066800000000000FF00FFFFFFFFFF000000000010 +:10669000160000000200000000000000FF00FFFFE5 +:1066A000FFFFFF00000000001700000002000000D4 +:1066B00000000000FF00FFFFFFFFFF0000000000E0 +:1066C000130000000200000000000000FF00FFFFB8 +:1066D000FFFFFF00000000001000000002000000AB +:1066E00000000000FF00FFFFFFFFFF0000000000B0 +:1066F000120000000200000000000000FF00FFFF89 +:10670000FFFFFF0000000000110000000200000079 +:1067100000000000FF00FFFFFFFFFF00000000007F +:106720000D000000040000000C000000FF00050048 +:10673000FFFF0D0000000000150000000500000034 +:106740000C000000FF000700FFFFFF00000000003A +:1067500006000000040000000C000000FF00000123 +:10676000FFFFFF0000000000070000000400000021 +:106770000C000000FF000101FFFFFF00000000000F +:106780000200000001000000020000001400FFFFF2 +:10679000FFFF0200000000000000000000000000F9 +:1067A00095480000F5520000774800008B48000033 +:1067B000814800006D480000C949000059480000A8 +:1067C000554800000000000041726475696E6F203A +:1067D0004D300041726475696E6F2053726C000019 +:1067E0000403090412011001EF020140032A4E8044 +:1067F0000001010200010000000000000000000094 +:10680000B55300004754000085530000C9530000F1 +:10681000995300003D5400000554000000000000A2 +:10682000080B00020202000009040000010202003D +:1068300000052400100104240206052406000105B9 +:106840002401010107058103100010090401000261 +:106850000A0000000705020240000007058302400D +:106860000000000000000000000000000000000028 +:10687000F9540000F5520000BD5500004D560000CF +:10688000BD560000000000000000000000000000F5 +:106890002A2B28000000000000000000000000007B +:1068A00000000000000000002C9EB4A0A1A2A434AF +:1068B000A6A7A5AE362D3738271E1F202122232458 +:1068C0002526B333B62EB7B89F8485868788898AF4 +:1068D0008B8C8D8E8F909192939495969798999A90 +:1068E0009B9C9D2F3130A3AD350405060708090A8E +:1068F0000B0C0D0E0F101112131415161718191A70 +:106900001B1C1DAFB1B0B50009040200010300005B +:1069100000092101010001226500070584034000F0 +:106920000105010902A1010901A10085010509195B +:106930000129031500250195037501810295017553 +:1069400005810305010930093109381581257F7555 +:106950000895038106C0C005010906A1018502054D +:106960000719E029E71500250175019508810295B1 +:106970000175088103950675081500256505071939 +:106980000029658100C000004C590000FE5800003D +:106990002C590000865800002C5900002259000094 +:1069A0002C59000086580000FE580000FE580000D8 +:1069B00022590000865800007E5800007E580000D2 +:1069C0007E58000032590000745B00006E5B0000CE +:1069D0006E5B0000645B0000C45A0000C45A0000F3 +:1069E0005A5B0000645B0000C45A00005A5B000060 +:1069F000C45A0000645B0000C25A0000C25A000082 +:0C6A0000C25A0000FC5B00000000000017 +:106A0C0072B6054B0F215A788A435A701A780221B4 +:0C6A1C000A431A70FEE7C046001000405C +:106A280040420F0000C20100000008000101000000 +:106A3800FFFFFFFFD940000041410000DD54000086 +:0C6A4800D9560000B14000000000000022 +:106A54000000000000000000000000000000000032 +:106A64000000000000000000000000000000000022 +:106A74000000000000000000000000000000000012 +:106A84000000000000000000000000000000000002 +:106A940000000000000000000000000000000000F2 +:106AA40000000000000000000000000000000000E2 +:106AB40000000000000000000000000000000000D2 +:106AC40000000000000000000000000000000000C2 +:106AD40000000000000000000000000000000000B2 +:106AE40000000000000000000000000000000000A2 +:106AF4000000000000000000000000000000000092 +:106B04000000000000000000000000000000000081 +:106B14000000000000000000000000000000000071 +:106B24000000000000000000000000000000000061 +:106B34000000000000000000000000000000000051 +:106B44000000000000000000000000000000000041 +:106B54000000000000000000000000000000000031 +:106B64000000000000000000000000000000000021 +:106B74000000000000000000000000000000000011 +:106B84000000000000000000000000000000000001 +:106B940000000000000000000000000000000000F1 +:106BA40000000000000000000000000000000000E1 +:106BB40000000000000000000000000000000000D1 +:106BC40000000000000000000000000000000000C1 +:106BD40000000000000000000000000000000000B1 +:106BE40000000000000000000000000000000000A1 +:106BF4000000000000000000000000000000000091 +:106C04000000000000000000000000000000000080 +:106C14000000000000000000000000000000000070 +:106C24000000000000000000000000000000000060 +:106C34000000000000000000000000000000000050 +:106C44000000000000000000000000000000000040 +:106C54000000000000000000000000000000000030 +:106C64000000000000000000000000000000000020 +:106C74000000000000000000000000000000000010 +:106C84000000000000000000000000000000000000 +:106C940000000000000000000000000000000000F0 +:106CA40000000000000000000000000000000000E0 +:106CB40000000000000000000000000000000000D0 +:106CC40000000000000000000000000000000000C0 +:106CD40000000000000000000000000000000000B0 +:106CE40000000000000000000000000000000000A0 +:106CF4000000000000000000000000000000000090 +:106D0400000000000000000000000000000000007F +:106D1400000000000000000000000000000000006F +:106D2400000000000000000000000000000000005F +:106D3400000000000000000000000000000000004F +:106D4400000000000000000000000000000000003F +:106D5400000000000000000000000000000000002F +:106D6400000000000000000000000000000000001F +:106D7400000000000000000000000000000000000F +:106D840000000000000000000000000000000000FF +:106D940000000000000000000000000000000000EF +:106DA40000000000000000000000000000000000DF +:106DB40000000000000000000000000000000000CF +:106DC40000000000000000000000000000000000BF +:106DD40000000000000000000000000000000000AF +:106DE400000000000000000000000000000000009F +:106DF400000000000000000000000000000000008F +:106E0400000000000000000000000000000000007E +:106E1400000000000000000000000000000000006E +:106E2400000000000000000000000000000000005E +:106E3400000000000000000000000000000000004E +:106E4400000000000000000000000000000000003E +:106E5400000000000000000000000000000000002E +:106E6400000000000000000000000000000000001E +:106E7400000000000000000000000000000000000E +:106E840000000000000000000000000000000000FE +:106E940000000000000000000000000000000000EE +:106EA40000000000000000000000000000000000DE +:106EB40000000000000000000000000000000000CE +:106EC40000000000000000000000000000000000BE +:106ED40000000000000000000000000000000000AE +:106EE400000000000000000000000000000000009E +:106EF400000000000000000000000000000000008E +:106F0400000000000000000000000000000000007D +:106F1400000000000000000000000000000000006D +:106F2400000000000000000000000000000000005D +:106F3400000000000000000000000000000000004D +:106F4400000000000000000000000000000000003D +:106F5400000000000000000000000000000000002D +:106F6400000000000000000000000000000000001D +:106F7400000000000000000000000000000000000D +:106F840000000000000000000000000000000000FD +:106F940000000000000000000000000000000000ED +:106FA40000000000000000000000000000000000DD +:106FB40000000000000000000000000000000000CD +:106FC40000000000000000000000000000000000BD +:040000030000433581 +:00000001FF diff --git a/bootloaders/mzero/Bootloader_D21_M0_Pro_150427.hex b/bootloaders/mzero/Bootloader_D21_M0_Pro_150427.hex new file mode 100644 index 0000000..dfb0302 --- /dev/null +++ b/bootloaders/mzero/Bootloader_D21_M0_Pro_150427.hex @@ -0,0 +1,1595 @@ +:10000000002C0020F5280000F1280000F128000055 +:1000100000000000000000000000000000000000E0 +:10002000000000000000000000000000F1280000B7 +:100030000000000000000000F1280000F12800008E +:10004000F1280000F1280000F12800006D0E0000EA +:10005000F1280000F1280000F1280000451F0000F1 +:10006000F1280000F1280000F1280000F12800002C +:10007000F1280000F1280000F1280000F12800001C +:10008000F1280000F1280000F1280000F12800000C +:10009000F1280000F1280000F1280000F1280000FC +:1000A000F1280000F1280000F1280000F1280000EC +:1000B00010B5064C2378002B07D1054B002B02D03E +:1000C000044800E000BF0123237010BD2001002080 +:1000D000000000006432000008B5084B002B03D07C +:1000E0000748084900E000BF07480368002B03D019 +:1000F000064B002B00D0984708BDC046000000000A +:10010000643200002401002064320000000000007E +:10011000EFF3108072B6BFF35F8F034B00221A70AB +:10012000434258417047C04618010020024B1A78DC +:10013000013AD2B21A707047D0030020044B1A78EB +:10014000013AD2B21A701B78024B00221A70704723 +:1001500046010020D6030020002070470020704791 +:1001600010B50F4B0F4C0020207018800E4BA122B1 +:100170001A7020225A7002220C4958809880DA8026 +:100180001881E1235B020B600823087148718B71B1 +:10019000074B9847237801200133DBB2237010BD51 +:1001A0006A060020D0030020DC0300203C01002070 +:1001B0002D30000008B500200149024B984708BDCA +:1001C0003C0100202D300000002805D0034B012207 +:1001D0001A70BFF35F8F62B67047C04618010020E7 +:1001E000124B60211A7850B20A40002809DA002028 +:1001F000202A1AD15A78212A17D1DA88072A14D14D +:100200000FE00020202A10D15A78202A04D0101C98 +:1002100022384242504108E0DA88072A05D10449D1 +:10022000196104499A819960012070477009002082 +:10023000B50100003C010020F7B5364B1A78002AC2 +:1002400066D1354CA047354D2C8800280FD0344B53 +:10025000984784425CD0334B9847334A334B1478E9 +:10026000071CE4B26100C95A002919D101E0304BE2 +:10027000EEE7304E28493388013333808847002821 +:1002800006D13388632B03D8381C2B4B98473FE0AB +:10029000214A9047002803D03288284B9A42F3D94C +:1002A000244B00221A80264B1B78934205D16342CF +:1002B00063411D49DBB20B7002E063425C41E4B272 +:1002C000144A01231370381C1B4B9847174B6700C7 +:1002D000DE5B413EFF3E731E9E41F6B2002E09D00A +:1002E0000D498847002801D00D4B00E0104B98477E +:1002F000288000E02E800D49A20124021419CB5B56 +:10030000104A1149121900918120311C0F4CA0474D +:10031000F7BDC046D8030020C5140000D403002058 +:10032000D9140000110100004701002048010020FD +:10033000C914000044010020C90100001F0300008F +:10034000690600204C0100205D03000055170000E5 +:1003500008B5014B984708BD3902000008B50028D0 +:100360000CD1074B1A7853425A41064B5200D052D7 +:10037000054B1870054B1870054B984708BDC046D3 +:10038000470100204801002069060020D803002012 +:100390003902000010B5074B9847074A074B1B88E6 +:1003A0001178074A49008C5AE41A064B9847201CDA +:1003B00010BDC04611010000D7030020D203002069 +:1003C000CC030020C901000008B5034B9847431E29 +:1003D0009841C0B208BDC04695030000F0B5194B66 +:1003E00085B098471849194A0C781578E4B2EDB2EF +:1003F000002D08D1164E670033880393154BFB5A26 +:10040000039FBB4203D9144B9847002018E0358066 +:1004100066426641F6B20E700F4F01261670B8475D +:100420000E4B281C9847A2010D4B240214190D4AAB +:100430000093A02312190220311CB3400A4CA0479C +:1004400005B0F0BD11010000D703002068060020B0 +:10045000D2030020CC030020C9010000C903000022 +:10046000F1040000E80300205517000038B5134BD5 +:10047000134D00242C701C70124B1C70124B1C70FE +:10048000124B1C805C80124B1C80124B9847124B05 +:100490001C70124B1C70124B1C80124B1C80124B98 +:1004A0009847A04209D02B780133DBB22B702B7810 +:1004B000DBB2012B01D10D4A137038BDD8030020E7 +:1004C0004601002069060020470100204801002065 +:1004D000D40300203902000068060020D703002062 +:1004E000CC030020D2030020DD030000D60300204F +:1004F00013B500281CD10F4B1B785C426341DBB263 +:1005000000290ED199011B02CB180B49101CCB18E6 +:100510000A491A1C0091A02301218B40084CA047D6 +:1005200006E0084A5B009952074B1870074B984742 +:1005300013BDC046D7030020E8030020F1040000EB +:1005400055170000CC03002068060020DD030000E2 +:1005500008B50020014B984708BDC046C9030000FC +:10056000F7B5194B00269B79093B5A425341DBB240 +:100570000193164B9847164B164F3C881D78164B27 +:100580009847EDB2154B6A00D35AA4B2A34205D8DE +:10059000134B1878C0B20028EBD113E0AB012D0249 +:1005A0005D19104B2D19EB5C01341E43A4B20E4BA8 +:1005B0003C809847019B002B03D000233602019317 +:1005C000D7E7301CFEBDC0463C01002011010000F1 +:1005D000D7030020D2030020C9010000CC03002073 +:1005E000D6030020E8030020DD03000038B5114BDE +:1005F0009847114A114B1178C9B24C00E45AA02314 +:100600005B009C420FD10E4B1B78002B0BD10D4D84 +:100610002B78DBB2002B06D101242C704C426141B7 +:10062000C9B211701C1C084B9847A0204000001B49 +:1006300038BDC046110100004701002048010020DC +:10064000D803002069060020C901000008B5034B4B +:100650009847431E9841C0B208BDC046ED05000052 +:1006600008B50020014B984708BDC0464D06000064 +:10067000F8B5154B0C1C9D79093D6B425D41EDB2FF +:100680000020124B9847002805D1114B1878C0B2B2 +:100690000028F5D117E00F4B98470F4B0F491B78F7 +:1006A000DBB25E00725A571C775299011B02CB18BD +:1006B0000B499A180B4B54549847002D02D0241222 +:1006C0000025DDE70120F8BD3C0100204D060000BB +:1006D000D60300201101000047010020480100203E +:1006E0004C010020C901000008B5011C014B00208D +:1006F000984708BD7106000008B5034B58887F2352 +:100700001840024B984708BD70090020D51800001A +:1007100030B5144B1A7800239A4221D0124B1B6833 +:100720001B681A79824201D8002319E00F4A13602E +:10073000DC789D7824022C431C199C420ED95D78EC +:10074000042D08D19D78854205D1DD788D4202D1F6 +:100750001360012304E01D785B19EEE71360E3E703 +:10076000181C30BD750600206C060020780600209D +:10077000094B1B681B68DA78997812020A439B18A8 +:1007800002788018834205D94278042A02D0052ACB +:10079000F6D100E0002070476C06002038B5104B01 +:1007A000051C9847002801D1002018E00D4B1C685B +:1007B000201C0D4B9847041E0AD06279237912023F +:1007C0001A438078E178094B98470028F0D1EBE78D +:1007D000074BAD001B685B68EB581B68984738BD3A +:1007E0001107000078060020710700003D15000089 +:1007F0006C060020F8B500210F4F051CB847041EF9 +:1008000018D00E4BAA001B685B68D658F36898474F +:10081000011C281CB847041E0CD0094B1D68281C5D +:10082000084B9847051E03D08078074B9847F6E79A +:1008300073689847201CF8BD110700006C06002063 +:100840007806002071070000E914000008B5014B8C +:10085000984708BDA119000038B50C4B00241A7840 +:100860001D1CA24205D100232B70094B01221A80C6 +:1008700038BD084B1B681B681B79A342F3D9201CA9 +:10088000054B01349847E4B2F3E7C04675060020F3 +:10089000720600206C060020F507000008B5024B28 +:1008A0009847024B984708BD051A000059080000F8 +:1008B00010B50B4B00241B78A3420FD0094B1B68CB +:1008C00019680A79A24209D95B68A200D3581B694A +:1008D000002B00D098470134E4B2EFE710BDC046CA +:1008E000750600206C060020F8B5A44C0023A381F7 +:1008F00023616361237858B2002803DAE288002A72 +:1009000000D1B2E16021194000D065E11F2200282A +:1009100000DBA9E0E588002D00D15DE1134067D13F +:100920006378062B09D0082B5DD0002B00D053E153 +:10093000022D00D050E1924892E06088050A022D15 +:100940000CD006D8012D00D046E18E4B18680178F6 +:1009500040E0032D1FD00F2D13D03DE1894BC0B2D5 +:1009600019684A7C824200D836E15B68C000C058F2 +:10097000C178837809021943834B9847A268557060 +:100980002AE0804B9868002800D125E1C17883785F +:10099000090219431EE0C0B2032800D91CE102F08D +:1009A00051FB070004000A0061011D21774A04E0A1 +:1009B000774804210EE0774A0E21002376485D0037 +:1009C000D65C451901336E80DDB28D42F6D3490005 +:1009D000023101706C4B9847E388A2899A4200D893 +:1009E000CAE0A381C8E0012D00D0F5E06B4837E0F4 +:1009F000012B25D163780A2B00D0EDE0012D00D02A +:100A0000EAE0664B1B78002B00D1E5E0644B2679C9 +:100A10001F683A681379B34200D8DDE0301C614B9F +:100A20009847051E00D1D7E07B68B600F358DB6815 +:100A300098475D4B01211870181C534B984799E05B +:100A4000022B00D0C8E06378002B00D0C4E0022D58 +:100A500000D0C1E0554B20799847554B1880181CA1 +:100A6000291C494B984787E013404DD160780138E5 +:100A7000082800D9B0E002F0DBFA0CAFAFAF05AF49 +:100A8000AFAF1A00E388002B00D0A5E0494B2361EB +:100A900072E0E388002B00D09EE06388012B00D039 +:100AA0009AE0374B02211A888A431A8064E0E5886D +:100AB000002D00D090E0404B9847002800D18BE0FB +:100AC000304EA27831684B7C9A4200DD84E03B4B8B +:100AD0009847A378314A1370002B4DD03849304ADB +:100AE0005B187168DB00CB181360161C33681B6839 +:100AF0001B79AB4240D9281C0021324B9847002873 +:100B00006AD00135EDB2F1E7012B15D163780B2BDB +:100B100062D1E388002B5FD1204B1B78002B5BD088 +:100B20002579294B281C66889847002854D0F1B2B3 +:100B3000281C244B98471CE0022B4DD16378012BD5 +:100B400002D0032B09D047E0E388002B44D163880F +:100B5000002B41D120791D4B0AE0E388002B3BD1CB +:100B60006388002B38D12079194B98472079194B8D +:100B70009847051C002D2FD0012077E07009002038 +:100B800072060020A4000020F518000037000020A5 +:100B90009400002028000020580000207506002046 +:100BA0006C060020110700007406002009160000E2 +:100BB00070060020F9060000E51800005908000042 +:100BC000FFFFFF1F9D070000F50700001917000039 +:100BD000891400001D16000022781F231340012BEA +:100BE0001ED1234B1B78002B1AD0224B25791E686F +:100BF00032681379AB4213D9281C00211E4FB84725 +:100C000000280DD07368AA00D658F3689847011CD5 +:100C1000281CB847002803D0B36898470028ABD1F8 +:100C200022781F231340022B1FD1114B00241B7865 +:100C3000002B1AD00F4B1B6819680A79A24214D9ED +:100C40005B68A200D558E96888470B4B011C201C43 +:100C50009847002809D0AB68984700288CD1013408 +:100C6000E4B2E7E70421054AA7E60020F8BDC04644 +:100C7000750600206C0600201107000026320000D7 +:100C80000368987AC009704770B50C4B0822056854 +:100C9000041CDA67201C0A4EB0470028FAD12B88C2 +:100CA000022293432B8020756075201CB0470028DA +:100CB000FBD12B88012213432B8070BD04E100E09F +:100CC000810C0000F8B50668071C0D1C141C381CAC +:100CD0000F4B98470028FAD13A79002A0AD01A23F4 +:100CE000012A12D11723012C0FD80634A400A551D4 +:100CF000031C0AE01723022C07D806498D4204D8AA +:100D00000C34ADB26400A553131C181CF8BDC046CA +:100D1000810C0000FFFF0000F7B52D4B0160151C92 +:100D20009A6920210A439A6101A90223041C0B70CD +:100D30000420284B98470420274B9847274B201C1A +:100D40009847AB7823712B796371254B1C602B88F6 +:100D500026683380AB78002B16D01720012B36D1B4 +:100D600033889BB23380EB78002B03D0338880220A +:100D700013433380201C1B4B9847021EFAD1201CC2 +:100D8000A968194B984719E033880422134333802C +:100D9000EB781720002B1AD1201C124FB847021EE7 +:100DA000FAD1201CA968104FB847201C0D4B98475A +:100DB0000028FAD1201CE9680122B8472B790020CD +:100DC000834204D072888023DB0113437380FEBD0D +:100DD000000400400128000079270000890C000071 +:100DE00044070020810C0000C50C000070B5037999 +:100DF000041C05680E1C1520002B05D1201C034B7C +:100E000098470028FAD1AE8270BDC046810C000020 +:100E1000031C022A0CD00079002805D0012805D136 +:100E20001720012A0FD803E0022A01D917200AE06F +:100E3000901C8000C1500120197D9040021C0A4383 +:100E4000D2B21A750020704710B5036880220229BB +:100E500003D001228A4003242240DA710122437D1B +:100E60008A40111C1943C9B2417510BD38B5114BE8 +:100E70001B68597D1C681A7D207A0A40E17901407F +:100E8000C80906D0510701D51B69984780232372F2 +:100E90000EE00125294203D02A4208D09B6805E0D4 +:100EA0000225294204D02A4201D0DB6898472572E6 +:100EB00038BDC04644070020EFF3108072B6BFF380 +:100EC0005F8F034B00221A70434258417047C0465F +:100ED000180100200F2303405B00C00918180238D6 +:100EE00014235843014B18187047C0468006002051 +:100EF000F0B58E7985B072B20D1C544B301C002AAF +:100F000046DA98470F2737400197028AC368029252 +:100F10006D88041CED188368C560877C9D4221D0D4 +:100F20005E1B4B4AB6B2964206D94A4B101C029938 +:100F30009847474B5E1AB6B20023BA0706D5464B10 +:100F4000301C029998478BB25A4253415A00A37CF5 +:100F500002218B4313436268A37452193F480199DD +:100F6000331C0AE0B807C00F0AD0022362689F430F +:100F70003A480199A77452190023394CA04763E0FD +:100F800001239F432368A774002B5DD0291C59E0DF +:100F900098470F2333400293038A041C0193837CF8 +:100FA0002F885A0710D5C268436801999B1803938C +:100FB0008068294B98470A1C02992A4B01398901FC +:100FC000C9180398284B9847E368FA18A368E260A9 +:100FD0009A4200D9E360AA88BA422AD1E5689D42C4 +:100FE00027D05E1B1A4FB6B2BE4206D9381C194B29 +:100FF000019998477F1ABBB205E0301C164B019946 +:101000009847761AB3B2019A1448184E93420BD2FD +:10101000A37C04221343029AA374013A114B920158 +:10102000D2180299019B02E0626802995219B047F6 +:101030000AE0A37C01229343A3742368002B03D00E +:10104000E1680020321C984705B0F0BDD50E0000C5 +:10105000FF1F0000A1310000E1300000080800205F +:101060006D1E00004807002005320000B91E000078 +:1010700010B5064B064C05221A70201C8021054B2A +:101080009847201C0021044B984710BDFB06002008 +:1010900008080020F31D00000D1E000037B51E4B90 +:1010A000041C9847226801AD80239372281C1B4BB7 +:1010B000984703236B70291C201C194B9847201C50 +:1010C0001849194B9847194D201C00210222184B32 +:1010D000A84700210A1C201C164BA847164B201CB1 +:1010E00000210122A847154D201C00210222A847FB +:1010F00000210A1C201CA847201C00210122A8470F +:1011000023680F4A19890A408021C9000A431A81BD +:101110000C4B00221A7037BD59080000111C00004A +:10112000211C000088090020011F0000A91A0000EE +:10113000951200004916000085110000F91A000000 +:10114000FFF3FFFFFB06002010B5084B084C0322FD +:101150001A70201C0749084B9847084B00219A68D1 +:10116000201C0B1C064CA04710BDC046FB060020EF +:101170000808002088090020011F000070090020D5 +:101180006D1E000008B589790C4B4AB2002A08DAB6 +:101190001B78012B02D10A4B98470DE0042B0BD191 +:1011A00007E01A78022A02D104221A7004E0032A06 +:1011B00002D10448044B984708BDC046FB060020F6 +:1011C0004911000008080020F31D0000F8B51D4D6E +:1011D0001D4E2B88B4891D4FE41AA4B2002C1BD1DC +:1011E0001B4A11885B189BB21380F2889A4203D085 +:1011F000184B1B78002B07D0174B04221A70381C91 +:101200001649174B98471CE07369002B0BD0984781 +:10121000002808D02C80B4893F2C04D90D4B002223 +:101220001A70402402E00B4B01221A702B88B2681E +:10123000381CD2180021231C0A4EB0472B88E41812 +:101240002C80F8BDF8060020700900200808002056 +:101250007C060020FC060020FB06002088090020F8 +:10126000011F00006D1E000008B5014B984708BD26 +:10127000B1080000064B9A8C910605D4D968D0229B +:101280000A40D02AFAD102E0DA68D106FCD57047CC +:101290000008004070B5274E0C1C3378002B06D098 +:1012A000254B1B69002B00D09847002333702388FF +:1012B000082B01D0214B2DE0214C1F4D23782B70A2 +:1012C00063786B70E378A2781B02D3186B80637924 +:1012D00022791B02D318AB80E379A2791B02D318C1 +:1012E000EB80184B98470028E4D02B787F2B0DD942 +:1012F000154B00211980154B221C198002233370D5 +:1013000013484023134CA047134B03E0EB88002BFA +:1013100002D1124B98470BE00B4B002119800B4B6D +:10132000221C19800123337009484023094CA0472F +:1013300070BDC046FB06002070090020711000003F +:1013400088090020E90800007C060020F80600203B +:1013500008080020B91E0000CD110000491100004E +:10136000002805D0034B01221A70BFF35F8F62B6CD +:101370007047C04618010020F7B501AE114B041CA0 +:101380001149301C04229847104B1D78A54217D0F4 +:10139000002C08D00E4B375D98470E4BDA5D0132BA +:1013A000DA550D4B9847002D08D0094B755D9847CD +:1013B000084B5A5D013A5A55074B9847034B1C702E +:1013C000F7BDC046053200002B320000FA060020AF +:1013D000B90E00003C0700206113000038B5084C2E +:1013E000084D201C0621A847201C0421A8470221E3 +:1013F000201C054B98470220044B984738BDC04637 +:10140000080800208D1A00006D1A000079130000F2 +:1014100038B50B4B98470B4C0B4B201C02219847BF +:101420000A4D201C0421A847094A0A4B201C06210A +:1014300098470621201CA8470320074B984738BD32 +:1014400075120000080800208D1A00006D1A0000B7 +:10145000DD1300004D1A00007913000010B5064C92 +:101460000421201C054B98470221201C044B98475F +:101470000120044B984710BD080800208D1A000079 +:101480006D1A00007913000038B5041C211C0A48AD +:101490000A4B98470A4B201C9847827C031CD107B3 +:1014A00008D501201D6882439A74002D02D0D968A6 +:1014B000221CA84738BDC04608080020A91D00000E +:1014C000D50E000000207047024B1B68188A80046C +:1014D000400D704708080020024B1B68188A80B234 +:1014E0007047C04608080020F7B501AD041C0D4B3D +:1014F000281C9847201C0C4B98470C4F0026291C91 +:10150000381C0B4BEE702C7098470F21321C214079 +:10151000381C084B9847381C321C211C064B984736 +:10152000F7BDC046111C0000891400000808002007 +:10153000211C0000D11A0000851B0000F7B501AC8A +:10154000061C294B201C0F1C151C984726700023D5 +:10155000082D1DD90123102D1AD90223202D17D9AA +:101560000323402D14D90423802D11D980235B003F +:101570009D4201D805230BE080239B009D4201D8AA +:10158000062305E0194B9D4201D900202AE00723DC +:101590006370301C164B98470323391C0582194091 +:1015A000012901D1022304E0022902D00329ECD150 +:1015B0000423104DE370211C281C0F4B9847041E78 +:1015C000E3D10F21221C0D4B3140281C0C4FB84792 +:1015D000221C311C0B4C281CA047281C311C01224A +:1015E000A0470120FEBDC046111C0000FF03000003 +:1015F000D50E000008080020211C0000F10E00009C +:10160000A91A0000F91A000008B5011C014B024894 +:10161000984708BDD51D0000080800200F2310B50D +:101620000340041C0020032B07D80448211C044B52 +:101630009847201C034B9847012010BD0808002044 +:10164000F31D000089140000F8B5284E3378012BF3 +:101650003FD1274A274C0D881788A3897A199342CE +:1016600001DADD1BADB2A3682349D8192A1C234B2C +:10167000EF199847BBB21E4F3B80402D05D1204D3E +:10168000E1882A88D218914208DCA3816369002B83 +:1016900002D0984700280AD01A4B1DE0A2899A422E +:1016A00010D16069002802D08047002804D10523AA +:1016B0003370154B984718E03A882B88D3182B8045 +:1016C00000233B8000210C4A4023104C1048A047C7 +:1016D0000BE0022B02D10F4B984706E0054B1B692C +:1016E000002B00D0984700233370F8BDFB06002084 +:1016F000F80600207009002088090020053200004B +:101700007C060020491100001D160000B91E0000D3 +:1017100008080020CD1100000F2370B50340061CFF +:101720000024032B0ED8084B9847084B051C311C8E +:1017300007489847AB7C0124DA0703D5A343AB7471 +:101740002B689847201C70BDD50E00000D1E0000B0 +:1017500008080020F0B51E1C0F2385B00340071CAD +:10176000029103920193032B01D9002596E04D4B82 +:101770009847051EF9D14C4B381C98474B4B041C1D +:101780009847A27CD10702D5494B984786E00123B0 +:101790001A43A274002804D0464A1370BFF35F8F27 +:1017A00062B60023E3600A9B039A0298A17C23603F +:1017B00001236260184002229840914301430420B3 +:1017C0008143A17479B2A660002930DA002E1AD0C4 +:1017D000394DB6B2AE4205D9218A281C374B9847FD +:1017E0006E1AB6B202990023994206D0344B218A70 +:1017F000301C98478BB25A4253415A00A37C0221B5 +:101800008B43134304E00299002909D0A37C93433E +:10181000A3740199039A331C2A4C2B48A0473AE041 +:10182000A27C9A43A2740A9A002A08D10CE0002EE6 +:101830000CD1A27C0A999A43A274002904D00020FA +:10184000011C3A1C0A9B9847012527E01A4FB6B2A3 +:10185000258ABE4206D9381C184B291C98477F1A86 +:10186000BBB205E0301C164B291C9847761AB3B260 +:101870001548164EAB420BD2A37C04221343019AA7 +:10188000A374013A124B9201D21801992B1C01E06A +:101890000199039AB04745424541EDB2281C05B075 +:1018A000F0BDC04609160000D50E0000B90E0000BC +:1018B0006113000018010020FF1F0000A13100008B +:1018C000E13000006D1E000008080020B91E000075 +:1018D00048070020024B80221B6810439872704713 +:1018E00008080020024B1B68987A7F231840704735 +:1018F00008080020014B986099817047700900200A +:1019000008B5044B01201B681A8902431A81024B57 +:10191000984708BD0808002079130000F8B5032097 +:10192000164B9847164C01272368164E1A89201C1F +:10193000BA431A810421144AB047201C0021134ADB +:10194000B047391C201C124AB047124A201C022101 +:10195000B047114D201C0421A847201C0021A84796 +:10196000391C201CA847201C0221A8470B4A201C18 +:101970000621B047201C0621A847F8BD79130000B6 +:10198000080800204D1A00005D14000069120000D4 +:101990009D100000111400006D1A0000DD130000FE +:1019A00073B50E4B984701AC061C0D4B201C984795 +:1019B0000C4D00230C49221CA370281C0B4B98478C +:1019C000281C0B4B98470B4B984701200A4B984714 +:1019D0000A4B9847301C0A4B984773BDB90E00005C +:1019E000552100000808002000500041652100003A +:1019F000311F000075120000791300001D1900004E +:101A00006113000010B5074B98470020064B98471C +:101A1000064B9847064B041C9847201C054B9847DB +:101A200010BDC0460119000079130000B90E000076 +:101A3000391A000061130000034B1A78002A01D004 +:101A400000221A707047C046FD0600200B1C2E3382 +:101A50009B001A50044AAA235B004900895AC25AC3 +:101A60000A43C2520020704730320000064B490042 +:101A70000268CB5A9383AB225200815A1943815298 +:101A8000026800201383704730320000054BAB2200 +:101A900052004900CB5A815A994381520268002072 +:101AA000938270473032000010B58C00A418343493 +:101AB000A4000419411863605931044BFF310878C0 +:101AC0009B5C03430B70002010BDC0463E320000FB +:101AD00010B58C00A418031C34345B18A40004193E +:101AE0000449002059336060FF33895C1A788A43C7 +:101AF0001A7010BD3E32000070B50F230B40C418A1 +:101B000061341F4DFF342678AD5C35432570002AC3 +:101B10000ED10268002B02D1FF3203230FE05B01DC +:101B2000D31849B2FF330222002926DB012224E028 +:101B3000012A0FD10268002B03D1FF320C239372CC +:101B40001CE05B01D31849B2FF330822002914DBE3 +:101B5000042212E0022A05D102685B01D318FF3388 +:101B600010220AE0032A09D102685B01D31849B2A6 +:101B7000FF334022002900DB20229A72002070BD32 +:101B80003E32000070B50F230B40C4181F4D613466 +:101B9000FF34AE5C2578B5432570002A0ED102686B +:101BA000002B02D1FF3203230FE05B01D31849B2AF +:101BB000FF330222002926DB012224E0012A0FD173 +:101BC0000268002B03D1FF320C2353721CE05B012F +:101BD000D31849B2FF330822002914DB042212E093 +:101BE000022A05D102685B01D318FF3310220AE0F4 +:101BF000032A09D102685B01D31849B2FF3340229E +:101C0000002900DB20225A72002070BD3E32000005 +:101C100000230370437083700123C370704700007A +:101C2000F0B5021C0D78C8780F232B40ED0904286D +:101C300000D998E0146801F0FBF90308495D7A00C7 +:101C400008335B010020E054A9E05D016419FF3412 +:101C500066781C20770700D0A1E0677870263742AD +:101C600000D09CE011206070146808335B01E0181C +:101C7000402444711268D31880221A718A78484B24 +:101C8000002A08D05A195468802000060443546082 +:101C90005469204307E05A195068400040085060DA +:101CA00050694000400850615D194C78686807220F +:101CB0003C4B1440184024072043686049780A4090 +:101CC000696912070B4013436B6162E058012418E5 +:101CD000FF34002D07D0677870261C2037425ED174 +:101CE0006078202612E066781C20770757D160784C +:101CF00002262FE058012418FF34002D10D06778F9 +:101D000070261C2037424AD16078302630436070FC +:101D100010681A1C0832520182188020107122E0CB +:101D200066781C2077073AD16078032612E05801C4 +:101D30002418FF34002D07D0677870261C20374206 +:101D40002DD160784026E1E766781C20770726D100 +:101D5000607804263043607010681A1C0832520103 +:101D60008218402050715B005D190D4B48782D01A1 +:101D70005B19072210405C680A4A000722400243B0 +:101D80005A608878002806D05968802212060A43D3 +:101D90005A60002003E05A68520052085A60F0BDB1 +:101DA000C8090020FFFFFF8F0F230B400268083394 +:101DB0005B0149B2D218002905DA8021117102684D +:101DC000D318022204E0402151710268D318012285 +:101DD000DA7170470F220A400368083252019B18DB +:101DE00049B29879002901DA800600E0C006C00FE8 +:101DF00070470F220A4003680832520149B29B180B +:101E00002022002900DB10225A71704730B50F22C2 +:101E10000A404CB201685301C918FF31CD79002C3A +:101E200011DA2024254220D04C710168CB18FF33F1 +:101E30001C7A40210C4218D01972036808325201F2 +:101E40009A18022310E0102425420ED04C7101682C +:101E5000CB18FF331C7A20210C4206D0197203687C +:101E6000083252019A180123137130BD70B50D1C50 +:101E7000046808356D012E5D1C247606760F14D09B +:101E80000B4C490161180A610C1C0A4A49690A4055 +:101E900062619A046369920C9B0B9B031343636119 +:101EA000036800245D1980236B71201C70BDC0463F +:101EB000C8090020FF3F00F0F0B50D1C046808358C +:101EC0006D012E5D1C24770713D00B4C49010A517C +:101ED00061184C689A04094B1209234013434B6064 +:101EE0004B6800249B0B9B034B6003685D194023E8 +:101EF0002B71201CF0BDC046C8090020FF3F00F038 +:101F0000094B0A4A196059680A40802189020A432C +:101F10005A605A68920B92035A6003684022FF335A +:101F200000205A717047C046C8090020FF3F00F0EA +:101F3000036802211A780A431A7002689378022B08 +:101F4000FCD07047F0B57E4C85B0206802681378ED +:101F5000DB0900D0F2E0118C8FB2002F4CD1AB2303 +:101F60005B00C65A958BAA235B00ADB2C35A2E40C4 +:101F70001E40744B7A00D35A1D4202D02268126868 +:101F800093831E420FD07049062F06D16F4B1A89DA +:101F9000802312095B0013400B603B1C20682E332A +:101FA0009B001B5898470137072FE2D1C6E01E1C43 +:101FB0000836B025009674016D00C618751959369B +:101FC0001419FF36B4460294E4792E7803956546D9 +:101FD0002D78E4B22E40351C60262540344212D1C3 +:101FE000102634422AD10C2634423AD1A60776D1A3 +:101FF0000133082B00D1A1E03C1C1C410125D9B2C2 +:102000002C42F5D0D3E75C011219FF32167A402436 +:10201000264204D0147280225242114304E0167A00 +:102020002024264202D01472494A9171602215423E +:1020300000D183E01B01C318DC337CE0029F0399CD +:10204000FE710A78324279D040495A018A185268A2 +:102050001B0192043E49C318920CD8330A805B6876 +:102060006BE05C011219FF32177A082637421DD047 +:102070001672364A1419A67E02221834164202D06D +:10208000A6789643A670802252421143304A91713D +:10209000009902684F01D719FA7994074ED40C229F +:1020A00015424BD01B01C318D43344E0167A0427E1 +:1020B0003E42F4D01772254A1219967A0224083249 +:1020C000264202D09678A6439670214A91710099D3 +:1020D00002684F01D719FA79D407E0D52EE05C01E8 +:1020E0001219FF32177ABC46664602273E420CD0D0 +:1020F000802617727642164A3143917113490C19A2 +:1021000061698904890C518010E0177A01263742F1 +:102110000CD016720E4A91710C490C196168890431 +:10212000890C118061680901890C9180AF0705D085 +:102130000D331B01C3185B680549984705B0F0BD16 +:10214000100700203032000000070020C8090020DE +:102150000807002000220123027043708270C370C0 +:1021600070470000F7B5171C634A00231360634AE9 +:10217000051C1060624A29600C1CD169202001AE48 +:1021800001430120D16106227370B070F3701820F2 +:102190005C4B311C3270984706205A4A3070311C13 +:1021A00019209047BB786846037069460620564B55 +:1021B0009847564B062098472378012213432370F3 +:1021C000A378D807FCD452490B685A0B1F231A4036 +:1021D0009A4200D105221A409001268D4D4A324084 +:1021E000024322850868820C13401F2B00D11D2357 +:1021F000208D1F2213409043034323850B68072241 +:10220000DB0D1340934200D103231340218D1A03A9 +:10221000414B42480B401343238521783A787F2372 +:10222000D2010B401343237079780123194023789E +:102230000422890093430B4323706062FB78012BD7 +:1022400004D12B680C211A898A4306E0002B05D1A2 +:102250002B680C241989A1430A431A818022304B30 +:102260000021520098470023E918002204334A60F5 +:10227000202BF9D1A918002310324B628B62CB625C +:102280000B63802AF6D12A1CA43213705370E9180C +:10229000081C0022A630AE31013302700A70082BF0 +:1022A000F5D1131CE918B831002204330A601C2B45 +:1022B000F8D1A918081C0023D430E0311032036093 +:1022C000436083600B60802AF3D1AA225200AB5294 +:1022D000AB225200AB52AC20EA1840001118613218 +:1022E0000020FF32013308701070082BF3D10D4B22 +:1022F00080221A60FEBDC04604070020100700209F +:10230000000400409D2800000128000079270000FB +:10231000246080003FF8FFFFFF8FFFFFC809002007 +:102320001732000000E100E0094B196800290BD1C9 +:10233000EFF31080074A002805D172B6BFF35F8F14 +:1023400005490870012111701A6801321A6070473E +:10235000140700201807002018010020084B1A68F5 +:10236000013A1A601B68002B09D1064B1B78002B21 +:1023700005D0054B01221A70BFF35F8F62B670471C +:10238000140700201807002018010020F7B50023CB +:1023900001AC144E80270125A370211CBF0211201F +:1023A000114B657025709847B761211C11200E4BA9 +:1023B00025709847B761211C9836082723200A4BBF +:1023C000257098473760211C1B20074B25709847C4 +:1023D000002337600F202370211C034B6570984742 +:1023E000F7BDC04600440041ED23000007B5802240 +:1023F00001AB1A700A785A704A789A708A78191C58 +:10240000DA70014B984707BD9D28000010B50C4BB2 +:1024100002211A680A431A60196880229143094A06 +:1024200089B29184101CC168064ACC06FBD5996814 +:102430000020D162596891621B689BB2938410BDE1 +:102440001C0700200008004070B50D4B45781E6A3F +:10245000817804780122402086431540AD01301C6C +:102460000A402843D10180229043021C0A430548B8 +:1024700003212140090202400A431A6270BDC0468E +:1024800000080040FFFCFFFF30B5027A4389920646 +:102490009B059B0D120C1A43124B5A60428881888F +:1024A000C4791143827922430A434178C9010A431E +:1024B0001A600278042A0BD1047BC189058A0A4874 +:1024C000A40609042C43014021439960196806E0E1 +:1024D000202A06D1028A9A6019688422D2000A430F +:1024E0001A6030BD1C0700200000FF0308B5082853 +:1024F00028D800F09DFD122727100B18051E21007B +:10250000114B02211A6A0A431A6204E00E4B02219F +:102510009A690A439A61002015E00B4B02211A8A3E +:102520000A431A82F7E7084B02219A8A0A439A82E1 +:10253000F1E7064B984706E0054B02211A780A435B +:102540001A70E8E7172008BD000800400D240000BD +:1025500044080040F0B5C223344EDB00B360344B76 +:102560001E215A688BB08A4304210A435A6005A889 +:102570000023438083714370072303733F2320228A +:10258000C3812C4B02701A68920E3F2A00D11F2281 +:10259000294B2A491B689B059B0D8B4200D1284B78 +:1025A00043810823C37180235B008380254B027223 +:1025B0000382254B984701A8012300258370234BF4 +:1025C000457005709847224B06209847214B984745 +:1025D00002AC0323211C65702572657223700220F2 +:1025E00020231D4D6360A84702201C4FB8471C4B99 +:1025F00098472A1CF1680D4BC806FBD5998C8020A2 +:1026000001439984174B002507211D72281C5D7218 +:102610009D7201232170211C6360237265706572B5 +:102620009047281CB8470BB0F0BDC04600080040DA +:10263000004000412460800028608000FF0300000B +:10264000FF01000080BBFFFF892400004924000037 +:10265000ED240000752600009526000039270000B3 +:102660000D24000000040040014B5878C009704759 +:10267000000C0040054B08219A690A439A61044BFB +:1026800001221A701A78D107FCD470470004004068 +:10269000000C0040F8B50C784B782402051C061C91 +:1026A0000443002B02D08023DB021C434B7A002B17 +:1026B00002D080231B031C434B68012B13D95E1EE1 +:1026C0001E400222002E09D19A4202D20136520047 +:1026D000FAE7360280232E435B0303E01E028023C9 +:1026E0002E439B021C430B7A002B02D080239B03BA +:1026F0001C430C4FB8470028FBD10B4B98470B4BA2 +:102700001D70B8470028FCD1094DAE60B8470028BD +:10271000FCD16A6880235B0213401C436C60054B4C +:102720009847F8BD6926000029230000080C0040E6 +:10273000000C00405D23000038B5051C094CA04783 +:102740000028FBD1084B9847084B1D70A047002874 +:10275000FCD1074B8022596852020A435A60054B4C +:10276000984738BD6926000029230000040C00406A +:10277000000C00405D23000010B5074B041C984777 +:10278000064B80221C70064BD20159880A435A809E +:10279000044B984710BDC04629230000020C00409E +:1027A000000C00405D23000038B50F4B041C984717 +:1027B0000E4B0F4A1C700F4B598858880905104062 +:1027C00058805C880C48090F20405880101C5C8899 +:1027D000084A6504FBD45388090203400B43538025 +:1027E000064B984738BDC04629230000020C004024 +:1027F000FFF0FFFF000C0040FFBFFFFF5D23000064 +:1028000010B50C78034B240204439847024BA4B242 +:102810005C8010BDA9270000000C004030B5D478C2 +:1028200000239C421AD11478802C03D080232406E4 +:102830005B02234354780225AC4309D19478002CE1 +:1028400002D18024A40201E0C024E40223434160B9 +:102850005478013C012C01D80F4C2340A0248DB2A8 +:10286000E4052C431C438462D0240D0C24062C4325 +:102870001C438462D478002C0CD15C0305D593787A +:10288000012B01D1816100E041615378013B012BB3 +:1028900000D8816030BDC046FFFFFBFF08B5031CB8 +:1028A0000A1C4009D90903D10549C001401800E0BC +:1028B00000201F210B4001219940024B984708BD81 +:1028C000004400411D2800007047000008B5044B7B +:1028D0009847044B9847044B9847044B984708BDCA +:1028E000552500008D230000C9280000C9280000DC +:1028F000FEE700001148124910B5884201D00023BC +:1029000001E0104B07E0104CCA18A242F9D2C4589B +:1029100004331460F7E70D4A191D043B934203D2B8 +:1029200000221A600B1CF6E7094A0A4B7F218A43F2 +:102930009A60094B9847094B9847FEE764320000BC +:10294000000000202401002020010020000C0020B5 +:102950000000000000ED00E0B9310000652F00002C +:1029600008B51D4B1A6802321A601968FA22520122 +:10297000914209D9194A1A4908201368C867997AF7 +:1029800049B200290BDAFAE718683221154B98474B +:10299000002920D18022144B9202DA611BE01988B1 +:1029A000022081431980136880221A720F4AC023C3 +:1029B00008215B00D1500E4B984772B6BFF35F8F72 +:1029C0000C4B00221A70BFF34F8F0B4A0B4BDA608F +:1029D000BFF34F8FFEE708BD38070020C80A00206C +:1029E00004E100E0E13000000044004100E100E0CB +:1029F0009D080000180100200400FA0500ED00E029 +:102A000008B5074B08221A60064B98470028FBD0F0 +:102A1000054B08221A600020044B9847C0B208BD3D +:102A200098440041510500009444004161050000B4 +:102A3000084A80231B0570B5041C9361151C1E1CDD +:102A4000054B98470028FBD06E61201C034B98472C +:102A500070BDC0460044004161060000E906000068 +:102A60000B4B0C4A1968914211D91A68D2B2002A4C +:102A700009D01A68012152085200494211801A688F +:102A800002321A60F1E7044B1B7DDA07FBD5704771 +:102A90001C010020FF3F00000040004110B50B1C4E +:102AA00000225C1AA4B2844203D21C780133624033 +:102AB000F7E7101C10BD0000F0B5944BC9B0587971 +:102AC0006946087001381C2800D9F8E000F0B0FA17 +:102AD0000F5A32F7F75DF7F7F7F7F7F7F7F7F7ADB4 +:102AE00053869EC2F7F7F7F7F7F725F76B00002339 +:102AF0004B7008238B704123CB7056230B715223EC +:102B00004B7149238B715323CB7150230B725F237D +:102B10004B7232238B720B24D2E05A7A00234B7013 +:102B200002218A1A7A49D2006E461141B170F370BF +:102B30000424C5E09B7900224A70902B10D006D85F +:102B4000802B0BD0812B11D102238B7011E0912BA4 +:102B500009D0922B0AD105238B700AE0012306E0ED +:102B600003248C70ACE004238B7002E000236946E0 +:102B70008B700324A4E000234B70664A664B1A60F6 +:102B800002249DE000234B70FAE79979DA7909066F +:102B900012040A43597A1B7A0A431B021A435F4BF9 +:102BA00052001A602EE0597A002230290DD16E466B +:102BB000DB7AF1700221CB1A5549DB0019417270A2 +:102BC000B27032717171B27106E068464270827003 +:102BD000C170027142718271072471E08022D201BA +:102BE0004F4B197D188B2021FF3101431983910828 +:102BF0004900D9614B4901321980FF328023DB0241 +:102C00009A42EDD1002369464B70B9E79879DA7999 +:102C10004249000210180C68434A80B2944208D816 +:102C20000B68C018414B0860984700236A465370F0 +:102C3000A6E70F3300228242F2D25D780C681E783C +:102C400014192D02640875196400ADB22580023292 +:102C50000233F0E79879DB790002304A18186E46A3 +:102C6000002381B27370304D1668CC1CA4B2AE4202 +:102C70001DD98B4212D21568981C5D196D086D0024 +:102C80002D886E463554156800AE5B195B085B00F5 +:102C90001D8833182D0A5D70031CEAE7136800A82D +:102CA000C91803191160013B00221A7008E0834221 +:102CB000F4D000AEF518FF26AE700133F7E700241C +:102CC0001B4D1B20A8471B4B260A1F78381CA84702 +:102CD000F0B2A8471B235F4067407E40E0B2F7B2E6 +:102CE000A8470E204740A8470026B3B2A34204D20B +:102CF0006946885DA8470136F7E769460E4B201CF8 +:102D000098474740F8B2A84749B0F0BDE00A002014 +:102D100001981E004C1D0000380700201C010020F7 +:102D20000040004102A5FFFFFF3F0000612A0000B4 +:102D3000312A0000360700209D2A0000F8B5002740 +:102D40003D1C3C1C1F4B98471F49061C485501352C +:102D5000062CF7D8201C00F06BF904080C11171C86 +:102D600023001B2E28D00025ECE7184B02241E70F0 +:102D7000E8E7174B36021E800324E3E7144B0424D4 +:102D80001A8816431E80DDE70E2E17D10027052472 +:102D9000D8E70F4B01371B889F42D3D10624D1E7D8 +:102DA000013DA8B20B4B98470025B04207D10A4B12 +:102DB0001D600A4B9847F8BD0124C3E700252C1C71 +:102DC000C0E7C046012A0000E00A002036070020C4 +:102DD000340700209D2A000038070020B92A00008F +:102DE000094B0421DA690A43DA61084B2022198B66 +:102DF000FF320A431A831A7DD10703D559681E2270 +:102E00000A405A607047C04600040040004000413C +:102E10007FB500236A46164CD370138093700293DB +:102E20000393012313711349134B201C134E98472E +:102E300008222368326021688A7A52B2002AFBDBBA +:102E40001A8802252A431A80201C2A1C0C490D4B83 +:102E50009847291C201C0C4B9847201C01210B4B28 +:102E60009847C023AB40F2581202120AF2507FBDBD +:102E7000C80A002000140040190D000000E100E025 +:102E800061290000110E0000490E0000ED0D000048 +:102E9000F0B5294B85B09847284B1A7DD007FBD554 +:102EA000274F69463A88274E0A81274A11886A4681 +:102EB0005181318803AA1180244A11886A46D18140 +:102EC000029907220A40012A31D01A8BD00530D44A +:102ED00059688022D2020A4301915A601A8B202538 +:102EE000FF352A431A831A4C1A4ADC611A80197D6D +:102EF000124AC807FBD5108B284310831648D461AB +:102F00001080197D01200D4A0142FAD0138B1D4318 +:102F10001583D461029B0724634018430290029BEF +:102F20003B6003980D4B30601380019951600C4B4E +:102F3000984705B0F0BDC04629230000004000417D +:102F40000040800004408000024080000640800075 +:102F50000020400005A5FFFF44A5FFFF06A5FFFFD9 +:102F60005D23000008B58022214B92029A618022E5 +:102F700012059A611F4B08221A601F4B1A7852B231 +:102F8000002A03DB1A7802218A431A701B4B1A7835 +:102F9000D10611D41B789A060ED48023DB01188841 +:102FA00017491A1C884207D01B6883F30888154B01 +:102FB0009A60154B1B689847144B01221A70BFF397 +:102FC0005F8F62B6124B9847124B9847124B984747 +:102FD000124B9847124AC1239B00D058802100020F +:102FE000000AC9050143D1500E4B98470E4BFCE730 +:102FF0000044004198440041001000403804004063 +:10300000FFFF000000ED00E0044000001801002078 +:10301000CD280000112E0000E12D00004D08000019 +:1030200000E100E0912E00003D2D000070470000FF +:1030300002B4714649084900095C49008E4402BC4B +:103040007047C04603B47146490840004900095A18 +:1030500049008E4403BC7047002934D0012300226C +:1030600010B488422CD301242407A14204D2814207 +:1030700002D209011B01F8E7E400A14204D2814217 +:1030800002D249005B00F8E7884201D3401A1A4394 +:103090004C08A04202D3001B5C0822438C08A042CB +:1030A00002D3001B9C082243CC08A04202D3001B81 +:1030B000DC082243002803D01B0901D00909E3E7FB +:1030C000101C10BC7047002801D00020C04307B47A +:1030D000024802A14018029003BDC046D90000007A +:1030E0000029F0D003B5FFF7B9FF0EBC4243891A9F +:1030F0001847C046002941D010B4041C4C40A446D7 +:1031000001230022002900D54942002800D5404271 +:1031100088422CD301242407A14204D2814202D246 +:1031200009011B01F8E7E400A14204D2814202D266 +:1031300049005B00F8E7884201D3401A1A434C0863 +:10314000A04202D3001B5C0822438C08A04202D399 +:10315000001B9C082243CC08A04202D3001BDC08C1 +:103160002243002803D01B0901D00909E3E7101C02 +:103170006446002C00D5404210BC7047002806D0A1 +:1031800003DB0020C043400801E08020000607B4B4 +:10319000024802A14018029003BDC0461900000079 +:1031A0000029EBD003B5FFF7A7FF0EBC4243891AF5 +:1031B0001847C0467047C04670B50E4B0E4D0024F0 +:1031C000ED1AAD101E1CAC4204D0A300F358984772 +:1031D0000134F8E700F036F8084B094D0024ED1AE9 +:1031E000AD101E1CAC4204D0A300F3589847013424 +:1031F000F8E770BD5032000050320000503200003D +:103200005432000010B50023934203D0CC5CC45468 +:103210000133F9E710BD031C8218934202D01970E4 +:103220000133FAE7704730303446000003020100F2 +:103230000400080070008000010000010002030C7F +:1032400010600000F8B5C046F8BC08BC9E46704748 +:10325000D9000000F8B5C046F8BC08BC9E467047CF +:04326000B1000000B9 +:103264006D0400003D010000590100005D010000F3 +:1032740051030000610100002D010000E101000084 +:103284005D0100000000000041726475696E6F20EA +:103294004D302050524F0041726475696E6F207337 +:1032A400726C20287777772E41726475696E6F2E61 +:1032B4006F72672900000000000300000000000096 +:1032C40000000000000000000000000000000000FA +:1032D40000000000000000000000000000000000EA +:1032E40000000000000000000000000000000000DA +:1032F4000000000004030904050F0C00010710027C +:1033040002000000C0000020B80000209800002047 +:103314001400002000000020D4000020B000002091 +:103324001201010202000040032A4F0000010102C1 +:103334000301000009024300020100C03209040035 +:103344000001020201000524001001042402020508 +:10335400240600010524010301070583034000102E +:1033640009040100020A0000000705810240000070 +:1033740007050202400000000100000000400000B8 +:04000003000028F5DC +:104000000080002035430000FB410000FB41000020 +:1040100000000000000000000000000000000000A0 +:10402000000000000000000000000000FB41000054 +:104030000000000000000000FB410000E94100001A +:10404000FB410000FB410000FB410000FB41000080 +:10405000FB410000FB410000FB410000E14B000080 +:10406000FB410000D5490000FB410000FB4100007E +:10407000FB410000FB410000E5490000FB4100005E +:10408000FB410000FB410000FB410000FB41000040 +:10409000FB410000FB410000FB410000FB41000030 +:1040A000FB410000FB410000FB410000FB41000020 +:1040B00010B5064C2378002B07D1054B002B02D0FE +:1040C000044800E000BF0123237010BD2C00002035 +:1040D00000000000106A000008B5084B002B03D058 +:1040E0000748084900E000BF07480368002B03D0D9 +:1040F000064B002B00D0984708BDC04600000000CA +:10410000106A00003000002028000020000000009D +:1041100008B50D20012100F09FF908BD10B5FA2463 +:104120000121A4000D2000F043FA201C00F04CF8FF +:1041300000210D2000F03CFA201C00F045F810BDD5 +:1041400038B5134D1349281C00F074FA124913486E +:1041500000F070FA1249134800F06CFA1249134843 +:1041600000F068FA1249134800F064FA124C13493F +:10417000201C00F05FFA291C00220123104800F0E7 +:104180008FFB211C242223230E4800F089FB38BD1D +:104190000C01002000080042000C00421001002029 +:1041A0000010004214010020001400420801002009 +:1041B00000180042180100201C010020001C0042D1 +:1041C00048000020A800002070B5041E08D0054B50 +:1041D0001D681E1C00F010F833685B1BA342F9D960 +:1041E00070BDC04620010020024B1A6801321A60DF +:1041F0007047C046200100207047FEE730B5404BB5 +:104200001E225968082091430222114359603D49FA +:104210008B6903438B613C483C4B9882988A0243EC +:104220009A82DA689007FCD5394A0120107010781C +:10423000C40704D53648407840B20028F7DB012097 +:104240009060507840B20028FBDB324C304844602C +:10425000507840B20028FBDB82242D48E4014480E2 +:10426000507840B20028FBDB988C8024A0439884CF +:10427000D868C506FCD5284C2448C462DC682348AD +:10428000E506FBD5848C254D2C438484DC681F48CF +:10429000E506FBD5848C02252C438484D86804066B +:1042A000FCD51A48C0684506F8D5D868C406FCD5C0 +:1042B00000209060507840B20028FBDB184C144876 +:1042C00044605478124864B2002CFADB1D6A154C25 +:1042D0002C401C621C6A8025AC431C620323836053 +:1042E000114B436053785BB2002BFBDB00230B7256 +:1042F0000E4A4B728B72CB720D4B1A6030BDC046AA +:1043000000400041000400400C060000000800408E +:10431000000C004001050100B805FF7D040A000003 +:1043200000070300FFFCFFFF03060100006CDC0236 +:104330000000002038B51049104CA14206D101F010 +:10434000A5FFFFF75BFF00F059F90BE00C4D8D4224 +:10435000F5D00023CA18E818A24204D2006804333A +:104360001060F7E7FEE79042E9D0064B064A934219 +:10437000E5D2002204C3F9E7000000202C00002051 +:10438000306A00002C000020AC050020264BFA21EA +:10439000186810B5890001F0CBF9244B0138984218 +:1043A0001DD8234B234A5860106AC0210002000A1E +:1043B000090601431162002407229C601A601E4B0B +:1043C000FC211A6A0A431A62196AFF2212020A437E +:1043D0001A62196AA022D2020A431A6200E0FEE7BA +:1043E000201C0021013400F037F8132CF8D1134BB6 +:1043F000134AA0215380134BC900998012491961B7 +:104400001121997002215970187801431970597E51 +:10441000C9090129FBD00D4B53800D4B41225A7025 +:104420000C4A1A8110BDC04600000020FFFFFF00AB +:1044300010E000E000ED00E0000400401E4000003D +:10444000000C0040004000420018000F2140000016 +:1044500000480042FF03000070B518244443204B7D +:1044600008261A1996571D1C013638D0012919D073 +:1044700000290AD0022932D1E3561A495268DB01D9 +:104480005B1899184031062007E0E3561549526839 +:10449000DB015B189918403102200870012191401E +:1044A00059601CE0182811D0182358432B560D4989 +:1044B00028184268DB015B189918403108780224FB +:1044C000A043087001219140996008E0064B022149 +:1044D0001A780A431A70DA79D209FCD1E4E770BD80 +:1044E0001463000000440041004800421822424387 +:1044F000F8B52D4D0824AA181457031C621C50D07F +:10450000481C00240C284CD801F008F9071E1E1E78 +:104510001E1E1E1E1E0A0A0A0A000124644240E0F2 +:10452000092902D1181C002103E00A2904D1181C12 +:104530000221FFF791FF23E000240B2931D1181C41 +:104540000121FFF789FF2CE018225343EA18526833 +:10455000EB560120141C04405508DB01002C11D03F +:10456000124C1B195D1930352E780C010F2131408A +:1045700021439A18C9B22970403213781843107039 +:1045800000240EE0094E0F279B195D1930352E7857 +:104590009A18BE433143C9B2297040321378184388 +:1045A0001070201CF8BDC046146300000044004198 +:1045B000182358430E4A30B5131808241C570134E9 +:1045C00015D080560B4C5B68C0010219D4184034DA +:1045D00004252570002904D0012908D19940916152 +:1045E00005E001229A40131C034A8018436030BD45 +:1045F00014630000004400411044004110B5FFF76F +:10460000C5FE0120FFF7E0FD084C201C00F0B2FAC7 +:10461000201C00F09DFAFFF77BFDFFF77FFD044BA8 +:10462000002BFAD000E000BFF7E7C0462C010020C5 +:104630000000000001607047F7B508AC26780468F8 +:104640009D1E27686C1EA541ECB2920705683A438F +:1046500027063A432A600268072529405068B501B9 +:10466000002C00D05C03294301430C435460F7BD88 +:1046700030B50368C0251C68AD0312052A402243EB +:10468000C024A402090421401143196003685A6838 +:1046900014435C6030BD036801211A680A431A6044 +:1046A0000268116801231942FBD1D1691942F8D17E +:1046B0007047036802211A680A431A600268D369C6 +:1046C0009907FCD470470268137ED907FCD5704760 +:1046D000036800225A8370470368187E4007C00FA2 +:1046E00070470368588B4007C00F70470368588BAA +:1046F0008007C00F70470368588B0123184070472C +:104700000368188DC0B2704738B5041C0D1CFFF744 +:10471000DAFF236801201D8538BD000002682349A7 +:1047200030B58A4210D022498A4210D021498A42AB +:1047300010D021498A4210D020498A4210D0204905 +:104740008A4210D0002210E0092314220DE00A232F +:1047500015220AE00B23162207E00C23172204E09F +:104760000D23182201E00E23192258B2012484409F +:104770001449800880000C6040180325C02189007E +:104780002B40AB404458FF259D40AC43C0259D4085 +:104790002B1C234343508023DB011A430A4B5A80CE +:1047A0005A7852B2002AFBDB30BDC04600080042F6 +:1047B000000C0042001000420014004200180042A9 +:1047C000001C004200E100E0000C0040F8B5041CB1 +:1047D000151C0F1C1E1CFFF75EFF201CFFF79EFF21 +:1047E000B9001C220A4069072368090C0A431A60B1 +:1047F000226884239375012F26D11020002D03D029 +:104800000320022D00D1082001F0DAFB051C301C2A +:1048100001F0D6FB011C281C01F018F90B4B051CFC +:10482000186801F0CDFB011C281C00F0E9FF011CF9 +:10483000FE20800501F034FA054901F007F900F087 +:10484000C7FF246880B2A081F8BDC04600000020E8 +:1048500000FF7F470120704710B5041C0069FFF777 +:104860001AFF201C143000F06CFD10BD08B5006963 +:10487000FFF729FF08BD08B5143000F074FD08BD2E +:1048800008B5143000F075FD08BD08B5143000F00F +:104890005CFD08BD08B50069FFF736FF012008BDC3 +:1048A000F8B51D1C00234360FA239B008360084B6E +:1048B000041C0833036014300F1C161C00F02BFD81 +:1048C000231C5C332761201C1E705D70F8BDC04640 +:1048D0009867000010B5041C0069FFF7FDFE002872 +:1048E00007D02069FFF70CFF011C201C143000F0DA +:1048F0001DFD2069FFF7F5FE002809D12069FFF7AB +:10490000F5FE002804D12069FFF7F5FE002802D04B +:104910002069FFF7DDFE10BD0F23081C98433038D7 +:10492000434258417047002070470F231940012926 +:1049300005D002394B424B410220C01A00E0002052 +:1049400070470000F0B5031C85B003915C33041C74 +:10495000182718783B1C43431A4E0821F318595660 +:10496000151CFFF7C3FD231C5D331878082147434E +:10497000F6197156FFF7BAFD039B00222069012149 +:10498000FFF724FF291C201CFFF7CDFF291C071C63 +:10499000201CFFF7CAFF291C061C201CFFF7BCFFC8 +:1049A000331C0090391C20690122FFF745FE206965 +:1049B00001210322FFF75CFE2069FFF77AFE05B0B4 +:1049C000F0BDC0461463000008B51322FFF7BAFF1C +:1049D00008BD000008B50248FFF77CFF08BDC046CF +:1049E0004800002008B50248FFF774FF08BDC04624 +:1049F000A800002008B500F03FFC08BDF8B5124B38 +:104A0000061C1B680D1C171C002B02D101246042E0 +:104A100019E000F031FC041EBC4200D93C1C2F19E7 +:104A2000BD4205D0301C00F0E1FB28700135F7E7EE +:104A3000002C07D0301C00F01FFC002802D1301CD5 +:104A400000F024FC201CF8BD3801002013B56C4692 +:104A50000734211C0122FFF7D1FF012801D1207862 +:104A600001E00120404216BD38B5104B051C1B6803 +:104A7000141C002B15D000F099FB08350C4A6B0173 +:104A80009B18DA7902210A43DA715979802252425D +:104A90000A435A71064A6B019B18DB799A07F9D5CC +:104AA00002E00120404200E0201C38BD3801002017 +:104AB00000500041F8B50F1C161C141C0025002CDA +:104AC00007D07919221C002000F070FB2D18241A41 +:104AD000F5E7301CF8BD30B50123A1B0C218013A8A +:104AE00014785A00002C0CD1C0239B001343694654 +:104AF00000200B80FFF7DEFF431E9841C0B221B0BB +:104B000030BD8D1A002DEFDD6D46AC520133E5E767 +:104B100008B50279002A04D100F0A6FC002809D1CA +:104B200006E00023022A06D100F01AFD002801D079 +:104B300000F09CFA0123181C08BD10B5041C00F0FD +:104B40009BFB002802D0201C00F0AAFB10BD000037 +:104B5000064B10B51B680024A34204D000F07AFA7B +:104B6000034B1C600124201C10BDC04628010020FE +:104B70003801002008B500F0D7F9024B01221A6075 +:104B800008BDC0462801002008B502280CD1A22388 +:104B9000114A40215B00D15400F06EFB002819D06F +:104BA0000E4800F02FFC15E0032806D10A4BB22274 +:104BB000520080219954682207E001280AD1064B4F +:104BC00092225200802199542822FF32995C0220BF +:104BD0000143995408BDC0460050004184040020A0 +:104BE000F0B5B24CA9B0268C1025F6B2002E1BD120 +:104BF0002023A582A3820123A382A38B08273B4203 +:104C00000AD08023A372301C311C00F037FAA84B65 +:104C10009D72A84B1E60A783228B04231A4200D1E9 +:104C20007BE1A24A938378E1A14B1A7AD2B2029235 +:104C30002A4200D159E11D72002004A900F00AFBAC +:104C40009B4840234371049B60201D78284000D07E +:104C500024E15A78002A0CD108A9002D03D10D7047 +:104C60004D70281C14E0944B1B78012B0BD00A705C +:104C70000CE0012A11D19B78012B0BD18F4B08A995 +:104C80001B78012B01D10B7000E0087000204870E8 +:104C90000222F8E0884B1870FDE0032A11D19A78BF +:104CA000012A05D1854B08A91A70087000F07EFA18 +:104CB00004998B78002B00D0F5E07F4B01221A700D +:104CC000E9E0052A03D1987800F0F4FAEBE0062A2F +:104CD00000D0ABE0DD78022D60D1DB88019300F0DD +:104CE000BDFB071C00F0BEFB041C00F017FC001904 +:104CF000039000F0B7FB041C00F010FC019A24188C +:104D00000934A24207D900F0ADFB041C00F006FCF8 +:104D100024180934019405AD0924221C281C002103 +:104D200001F0E3FA2C70039C02226B465A75093499 +:104D30006B46DC82032206AB1A7001226B465A7660 +:104D4000C0226B46DA7608ACFA2307AA1370221C3D +:104D500003CD03C20025137000F084FB854205D209 +:104D60007A5D631901355A72EDB2F5E700F0D2FBB6 +:104D70000025071C00F0D2FB854208D200F072FB30 +:104D80007B5D6219101801354372EDB2F2E7019AAA +:104D9000802A00D980220020211C44E0222D02D14B +:104DA00000F0C0FB18E0212D1AD108AC0927002122 +:104DB0003A1C201C01F099FA0123A370E37063717F +:104DC000222327706570A37100F0AAFB211CE071FB +:104DD0003A1C0020FFF76EFE431E9841C0B260E00F +:104DE000012D04D1DA883649112A1AD816E0032D8C +:104DF00070D19A78002A05D13249DA880B7893422B +:104E00000CD80EE0022A02D1D9882F4803E0012AEB +:104E100060D1D9882D48FFF75EFE42E0D2B2002A69 +:104E200000D10A780020FFF745FE3CE0072A51D068 +:104E3000082A02D100201F4924E0092A1ED1EA06CF +:104E400048D10420832100F019F90120822100F0CB +:104E500015F90220011C00F011F90320832100F054 +:104E60000DF9049B9A78134B1A602A230222FF3310 +:104E7000E2544A230122FF33E2540CE00A2A05D10E +:104E800013490020012200F091F90CE00B2A0AD10D +:104E90009A780F4B1A6000F0E9F804E0181CFFF74D +:104EA00037FE002816D000F07BF916E000500041D4 +:104EB000FF5000413801002024010020340100206F +:104EC000E8670000E4670000C8670000D7670000DB +:104ED00030010020002000F0C5F90298402318425C +:104EE00003D00F490B7220234B7101239E430024F2 +:104EF000E0B2002E11D0331C2341DA070AD509494C +:104F000063015B18DB799A0701D0FFF73DFE0123AF +:104F1000A3409E430134092CEAD129B0F0BDC0461C +:104F2000FF5000410051004130B53E4B2021DA696D +:104F300001200A43DA613C4B06241A7802431A70B6 +:104F40003A4B0F221978914319701978214319703F +:104F500037490C782043087019780A401A701A787B +:104F600060210A431A70334B334A5A805A7852B23E +:104F7000002AFBDB314B01211A780A431A70997819 +:104F80002E4AC807FBD41178022001432C48117027 +:104F90000268510B1F221140914200D1052111409E +:104FA0008C011D8D27492940214319850468A10CD6 +:104FB0000A401F2A00D11D221C8D1F210A408C434C +:104FC00022431A8502680721D20D0A408A4200D185 +:104FD00003220A40188D11031B4A02400A431A8516 +:104FE00019787F220A401A701A7804210A431A702D +:104FF000164A0C205A621989814319810023D1185D +:10500000002008602033802189018B42F7D1104BAA +:10501000C122920099580902090A995080221A6007 +:1050200030BDC04600040040584400413C440041AB +:1050300059440041000C004006400000005000416F +:10504000246080003FF8FFFFFF8FFFFFAC040020CB +:1050500000E100E0044B01211A898A431A810822E9 +:105060001A8304221A83704700500041024B5A6988 +:10507000920B92035A617047AC040020F0B583296B +:1050800011D1021C3F4B083252014021D1543E4AFB +:105090004301D3185C693D493D4AC00121401018C5 +:1050A000596118616DE002291FD13A4B4201364C1B +:1050B000D11803234B70A3185E68344D800135402E +:1050C000C026B60535435D60334D28181051586829 +:1050D000324A02408020400302435A605A68920BD1 +:1050E00092035A6040234B714BE0822914D1294C22 +:1050F00042011319302159702349244C8A185569EB +:1051000023492C40C025AD05C0012C43081854612B +:10511000106180225A7134E0002932D11D494001CA +:1051200042181123184D8024537064424023937118 +:1051300054712B185968154F4900490859605E6928 +:105140001549760076085E615E683E40B446C0262A +:10515000B605644634435C605C6927403E435E614B +:10516000415158680D4901408020C00201435960F7 +:105170005968890B89035960802340215B429171F2 +:105180005371F0BD00500041AC040020FFFFFF8FC1 +:105190003C010020FF5000413C030020FF3F00F095 +:1051A000014B80229A717047FF50004170B50C4D41 +:1051B000C301ED18061C281C141C01F08DF8094BC6 +:1051C00076019E1935617169074A201C0A40726197 +:1051D0007269A104920B890C92030A43726170BD3B +:1051E0003C010020AC040020FF3F00F070B5134CE0 +:1051F000134A8101430165189D50D2185668114D1C +:1052000035408026B602354355605568AD0BAD0379 +:1052100055600D4A9D180D4A9B1840225A712B1C4F +:10522000FF331A7A01231A42F9D0094A4001801843 +:10523000C2791343C371605C70BDC0463C0300205B +:10524000AC040020FF3F00F000500041FF5000413F +:1052500000510041024B8001181808607047C04699 +:105260003C030020034BC0B24001C018202343710F +:105270007047C04600510041034B40011818406878 +:105280008004800C7047C046AC040020034B4001F2 +:10529000C01840234371012303727047FF5000413F +:1052A000034B4001C01880238371022303727047AF +:1052B000FF5000410C4B02215A69920B92035A6134 +:1052C0000A4B1A7A0A431A729979802252420A4387 +:1052D0009A711A7A9107FCD580235B421843044BDC +:1052E000C0B298727047C046AC040020FF50004125 +:1052F00000500041F8B5061C0C1C8F180025BC425C +:1053000007D0336821781B68301C984701342D186A +:10531000F5E7281CF8BD10B500214022041C00F060 +:10532000E4FF0023201C2364636410BD026C10B5ED +:105330003F23541C2340446CA34201D08154036496 +:1053400010BD0023036443647047436C026C9342B6 +:1053500006D0C25C3F2101330B404364101C01E0C6 +:10536000012040427047026C436CD01A00D5403097 +:105370007047436C026C934201D0C05C01E0012095 +:1053800040427047034B186C5B6CC01A3F231840B7 +:105390007047C0463C040020054B196C5A6C914282 +:1053A00002D05A6C985C01E0012040427047C04630 +:1053B0003C04002013B502686B46D971073354686A +:1053C000191C0122A04716BD38B50D4B041C196CE1 +:1053D0005A6C914211D05A6C3F219D5C5A6C02204C +:1053E00001320A405A64FFF705FB002803D0236806 +:1053F000201C9B699847281C01E00120404238BDD1 +:105400003C04002038B50C4D2C6C3F2301341C406B +:105410006B6C9C420FD00220FFF7ECFA002803D1FE +:105420000220FFF733FF06E00220FFF70FFB2B6C93 +:105430002C64E854E9E738BD3C04002008B503209B +:10544000FFF77BFB08BD10B5041C0320FFF70CFB26 +:10545000002801D10123636010BD0000004870479F +:10546000286800004220704710B50278041C437879 +:10547000A12A08D1212B2CD1002017490722FFF7A0 +:1054800019FB012026E0212A23D1202B0DD1002059 +:10549000FFF7F2FE0E28FAD90023E218117A0E4A1D +:1054A00099540133072BF8D113E0222B11D18278C4 +:1054B000094BDA7119689622D200914209D1DC7940 +:1054C00001231C4003D1FA2000F016F901E000F09E +:1054D0001DF9002010BDC04604000020044B00222E +:1054E0005A60FA2292009A60024A08321A607047A3 +:1054F0008404002000680000036870B59B68041CE9 +:105500000D1C98472368061C291CDB68201C984743 +:10551000F0B270BD00487047106900001920704754 +:105520006520704708B5002002496522FFF7C2FADE +:1055300008BDC0462969000013B56B461870141CDD +:1055400000235A1CA34206D0131C8A18013A127871 +:105550006846C254F5E769460420FFF785FA13BD93 +:1055600008B50178031C4278A1290ED10223101C32 +:105570009843012817D000209A4214D10A490122E9 +:10558000FFF714FEFFF70CFE0CE0002021290AD1E2 +:105590000B2A02D19A78054B03E00A2A03D1DA7864 +:1055A000014B1A70012008BD0D0000200C000020E6 +:1055B00008B502200822FFF7BFFF08BD10B58729F4 +:1055C00002D97831C9B218E04BB2002B08DA803921 +:1055D00001238B40191C037A1943017200210CE04E +:1055E000194B595C00292BD04BB2002B05DA037AFA +:1055F0000222134303727F231940837A8B4219D00E +:10560000C37A8B4216D0037B8B4213D0437B8B42F1 +:1056100010D0837B8B420DD0C37B8B420AD00023FA +:10562000C218947A002C01D1917203E00133062B49 +:10563000F6D105E0011C0831FFF7BAFF012002E0B6 +:1056400001234360002010BD9068000010B5872939 +:1056500002D97831C9B219E04BB2002B08DA80398F +:1056600001238B40191C037A8B43037200210DE048 +:10567000114B595C002399421BD04BB2002B05DA29 +:10568000037A0222934303727F231940031C0622EC +:10569000002904D09C7A8C4201D100249C72013AEA +:1056A000D2B20133002AF3D1011C0831FFF780FF89 +:1056B0000123181C10BDC0469068000008B5011CED +:1056C00000238372C372037343738373C3730372C0 +:1056D0000831FFF76DFF08BD044B00221A70044B20 +:1056E0005A60044A08321A607047C0469804002085 +:1056F0009C0400207068000008B5024B1860024B43 +:105700009847C04610000020156A0000024B012295 +:1057100052421A607047C0461000002002B4714621 +:1057200049084900095C49008E4402BC7047C046E4 +:10573000002934D00123002210B488422CD3012444 +:105740002407A14204D2814202D209011B01F8E7D9 +:10575000E400A14204D2814202D249005B00F8E792 +:10576000884201D3401A1A434C08A04202D3001BBE +:105770005C0822438C08A04202D3001B9C082243F1 +:10578000CC08A04202D3001BDC082243002803D02F +:105790001B0901D00909E3E7101C10BC7047002861 +:1057A00001D00020C04307B4024802A14018029073 +:1057B00003BDC046190000000029F0D003B5FFF773 +:1057C000B9FF0EBC4243891A1847C0467047C0460D +:1057D0009E2110B5C905041C00F072FC002803D1FD +:1057E000201C00F0CDFB10BD9E21C905201C00F03F +:1057F00057FA00F0C5FB80231B06C018F3E7C0462C +:10580000F0B55F4656464D464446F0B44602450064 +:10581000C00F85B00F1C760A2D0E804641D0FF2D9B +:1058200026D08024240400212643F6007F3D8946AB +:105830008B46F90F7C027800640A000E00918A46BC +:105840003CD0FF2834D080231B041C430023E400F9 +:105850007F380193009F4346019A7B4049469C460E +:1058600011430F2900D971E0764F89007F58BF4658 +:10587000002E3ED10822022391469B46D9E75A4684 +:10588000341CC24601920199022937D0032900D164 +:10589000CFE0012900D0ABE053460B4000220026A8 +:1058A00032E0002E19D10421012289469346C0E737 +:1058B000221C531E9A4102320192CBE70127019725 +:1058C000002CC7D0201C00F005FC431F9C40762311 +:1058D0005B420021181A0191BCE7301C00F0FAFB72 +:1058E0007625431F9E406D4200232D1A99469B4604 +:1058F0009FE70C23032199468B469AE7D446012360 +:1059000067463B40FF2200267602D205700ADB077D +:105910001043184305B03CBC90469946A246AB469E +:10592000F0BD80260023F603FF22EDE700220026CB +:10593000EAE78020C00306423BD0044239D1061C6E +:1059400026437602760A009BFF22DDE7281A0390A1 +:1059500076016401A64239D3361B1A2201230120A5 +:10596000311C5B007600002901DBB44201D8361BF4 +:105970000343013A002AF3DC741EA641341C1C4385 +:10598000039A7F32002A27DD630704D00F232340C8 +:10599000042B00D00434270103D52B4B039A1C4061 +:1059A0008032FE2A0BDD012361460B40FF220026D8 +:1059B000AAE706437602760A4346FF22A4E7A4013B +:1059C00001236746660AD2B23B409DE7039F1B2234 +:1059D000013F03970023C2E77E23039F5B42DB1B4B +:1059E0001B2B07DD012361460B40002200268BE7BD +:1059F000D446C5E7221CDA40039B9E339C40231CFF +:105A00005C1EA34113435A0704D00F221A40042AF4 +:105A100000D004335F0105D5012361460B4001220C +:105A2000002671E79E01624601231340760A002298 +:105A30006AE78026F60326437602760A5346FF225B +:105A400062E7C04690690000FFFFFFF7F0B55F46D0 +:105A500056464D464446F0B44402460083B00F1CFF +:105A6000640A360EC50F002E41D0FF2E22D08023AF +:105A70001B0400201C43E4007F3E82468046391C04 +:105A80004B007F02C90F7F0A1B0E8B463BD0FF2BBA +:105A900034D0802212041743FF007F3B00215A4676 +:105AA0006A40019252460A430F2A63D87A4892000C +:105AB00082589746002C3FD10822022392469846EE +:105AC000DDE70195404602282AD1019A01251540BB +:105AD000FF2300246402DB05600AED071843284316 +:105AE00003B03CBC90469946A246AB46F0BD002CA4 +:105AF00027D10420012282469046C0E7391C4A1E65 +:105B000091410231CBE70121002FC8D0381C00F0B1 +:105B1000E1FA431F9F4076235B421B1A0021BEE738 +:105B2000032800D1AEE001284FD101984246104031 +:105B3000C5B200230024CDE70C2303209A468046FB +:105B40009DE7201C00F0C6FA7626431F9C40764253 +:105B50000023361A9A46984691E780240025E403EC +:105B6000FF23B7E75B463C1C01938846AAE73C1C31 +:105B70008846A7E7250C24043A0C240C3F04F618A9 +:105B80003F0C211C231C794353436F435543FB189F +:105B90000A0C9B18B1469F4202D980225202AD18CE +:105BA00009041A04090C521894011B0C611E8C4143 +:105BB000920EED181443AD012C43230105D50122AB +:105BC00063080120144081441C434B467F33002B63 +:105BD0002DDD600704D00F222240042A00D00434B7 +:105BE000220103D52D4B1C404B468033FE2B17DD85 +:105BF000019B01251D400024FF236BE78020C0038B +:105C0000044208D0074206D1041C3C436402640AE3 +:105C10005D46FF235EE704436402640AFF2359E7FD +:105C20000198A4010125640ADBB2054052E77E23F6 +:105C30005B424A469B1A1B2B05DD019B01251D403B +:105C40000024002346E7221CDA404B469E339C404A +:105C5000231C5C1EA3411343580704D00F221A4093 +:105C6000042A00D004335A0105D5019B01251D40AB +:105C7000002401232EE701989C010125640A0540B8 +:105C8000002327E78027FF03019B3C436402012593 +:105C90001D40640AFF231DE7D0690000FFFFFFF7E6 +:105CA000F8B5C20F430244004D024800240E161CF2 +:105CB0009B09000EC90FAD09FF2800D17EE0012726 +:105CC00079408A4258D0221A002A00DC89E0002854 +:105CD0001BD1002D00D075E0580704D00F221A40C8 +:105CE000042A00D00433590138D50134FF2C00D1E7 +:105CF00083E09B0101225B0AE0B232405B02C405F3 +:105D0000580AD20720431043F8BDFF2CE4D080216D +:105D1000C9040D431B2A00DD2DE1291C2020D140A0 +:105D2000821A95406A1E95410D435B1B5801D3D5DD +:105D30009B019F09381C00F0CDF9421F9740944207 +:105D400060DC141B1F231B1B3A1C9F40611C3B1C67 +:105D5000CA405F1EBB4113430024BDE70122DB089C +:105D6000E0B23240FF2C04D1002B7ED08021C90349 +:105D70000B435B025B0AC1E7211A002946DD0028BC +:105D800026D0FF2CA8D08020C00405431B2900DDAD +:105D9000EFE0281C2027C840791A8D40691E8D41EC +:105DA00005435B19590197D50134FF2C5CD0734929 +:105DB00001221A400B405B0813438DE7002D00D0F1 +:105DC0007FE77CE7013A002AAFD0FF2CA2D183E71E +:105DD000002D00D180E701390029E2D0FF2CD5D178 +:105DE0007AE7002A1ED1621CD2B2012A4EDD5F1B67 +:105DF0007A0126D5EF1A0E1C9CE701223240FF20C3 +:105E000000237BE75D4BA41A3B4065E7002946D1A0 +:105E1000611CC8B201282ADDFF2925D0EB185B08D8 +:105E20000C1C59E7002C13D0FF2818D08024E40460 +:105E3000524223431B2A4DDD0123EB1A041C0E1C86 +:105E400074E7002F00D075E700220020002390E7C0 +:105E5000002B3BD0D243002AEFD0FF28EAD12B1CE5 +:105E6000FF240E1C38E70022FF20002346E7002C09 +:105E70005AD1002B77D0002D00D12DE75B195801A6 +:105E800000D429E73D4A0124134025E7002C15D111 +:105E9000002B2FD1002DD7D02B1C0E1C1CE7002C63 +:105EA00021D1002B53D0C943002904D0FF284BD067 +:105EB0001B294FDD01235B19041C73E7002B22D142 +:105EC000002DD0D02B1C0E1CFF2405E72B1C041C1E +:105ED0000E1C01E71C1C2026D440B21A93405A1E07 +:105EE00093412343A9E7FF282ED08024E4044942AC +:105EF0002343DDE7002D00D1EEE65A1B500134D5D7 +:105F0000EB1A0E1CE8E6FF24002D00D1E4E6802207 +:105F1000DB08D203134204D0ED08154201D12B1C3B +:105F20000E1CDB00FF24D7E6002B0DD0FF24002D34 +:105F300000D1D1E68022DB08D2031342F1D0ED0874 +:105F40001542EED12B1CECE72B1CFF24C4E62B1CC6 +:105F5000041CC1E61C1C2027CC40791A8B40591E1A +:105F60008B412343A7E72B1CB6E6131E00D0B3E6F4 +:105F70006AE7012515E70125D7E6C046FFFFFFFBCD +:105F80004302590A4300C20F1B0E00207E2B0DDD79 +:105F90009D2B0CDC802000040143952B0ADC96200D +:105FA000C31AD9404842002A00D1081C7047034B4D +:105FB000D018FBE7963B9940F4E7C046FFFFFF7F10 +:105FC00010B5041E33D000F085F89E231B1A962BC3 +:105FD00009DC083884406402640ADBB26402DB0531 +:105FE000600A184310BD992B0ADD0522121A211CE4 +:105FF000D1400A1C011C1B318C40611E8C41144392 +:10600000052801DD421F9440144A2240610704D054 +:106010000F210C40042C00D0043251010AD59F23DB +:10602000181AFF2816D09401640AC3B2D6E70023D9 +:106030000024D3E7D208FF2B03D05402640ADBB25A +:10604000CCE7002A06D08024E40314436402640AE7 +:10605000FF23C3E7FF230024C0E7C046FFFFFFFB89 +:106060008446081C6146FFE71FB500F0C3F800280E +:1060700001D40021C8421FBD10B500F049F84042CC +:10608000013010BD10B500F0B5F8002801DB00208C +:1060900010BD012010BDC04610B500F0ABF80028BF +:1060A00001DD002010BD012010BDC04610B500F07C +:1060B00059F8002801DC002010BD012010BDC046A9 +:1060C00010B500F04FF8002801DA002010BD0120C3 +:1060D00010BDC0461C2101231B04984201D3000CB3 +:1060E00010391B0A984201D3000A08391B0998424B +:1060F00001D30009043902A2105C40187047C04661 +:106100000403020201010101000000000000000080 +:106110004A02430270B55C0A550A43004A001B0E4E +:10612000C60F120EC90FFF2B05D0FF2A08D0012081 +:1061300093420BD070BD0120002CFBD1FF2AF6D179 +:106140000120002DF6D101209342F3D1AC42F1D1D0 +:106150008E4205D0002BEDD1201C441EA041E9E762 +:106160000020E7E74A024302F0B55C0A550A430003 +:106170004A001B0EC60F120EC90FFF2B31D0FF2A8B +:1061800034D0002B16D1604260418446002A14D0DE +:10619000002820D18E4217D1934215DC04DBAC429B +:1061A00012D80020AC4212D270427041404201230A +:1061B00018430CE0002AEDD194466F426F416046CF +:1061C000002805D1002FE5D0704201231843F0BD0F +:1061D0000020002FFBD14842484140420123184390 +:1061E000F5E7002CCBD002204042F0E7002DC8D0CC +:1061F000F9E7C0464A024302F0B55C0A550A43007B +:106200004A001B0EC60F120EC90FFF2B27D0FF2A04 +:1062100029D0002B10D0002A15D194466F426F412F +:106220006046002815D00020002F04D14842484184 +:10623000404201231843F0BD604260418446002A79 +:10624000ECD00028F2D18E4211D0704201231843C5 +:10625000F1E7002FF7D0704201231843EBE702204B +:10626000002CE8D1D3E70220002DE4D1D1E79342FE +:10627000EBDC04DBAC42E8D80020AC42DBD270425D +:106280007041404201231843D5E7C04670B50E4B1C +:106290000E4D0024ED1AAD101E1CAC4204D0A3001C +:1062A000F35898470134F8E700F028F8084B094DF7 +:1062B0000024ED1AAD101E1CAC4204D0A300F3580C +:1062C00098470134F8E770BD140000201400002046 +:1062D000140000202400002010B50023934203D0B6 +:1062E000CC5CC4540133F9E710BD031C82189342FF +:1062F00002D019700133FAE770470000F8B5C046C4 +:10630000F8BC08BC9E467047F8B5C046F8BC08BC4F +:106310009E467047000000000B00000002000000D5 +:106320001C000000FF00FFFFFFFF0B00000000004B +:106330000A000000020000001C000000FF00FFFF38 +:10634000FFFF0A0000000000080000000400000039 +:106350001C000000FF000000000010000000000012 +:1063600009000000040000001C000000FF00010004 +:1063700001000900000000000E0000000400000001 +:106380001C000000FF00000300030E0000000000DE +:106390000F000000040000001C000000FF000103CB +:1063A00001030F00000000001400000005000000C1 +:1063B0001C000000FF0006000600040000000000B2 +:1063C00015000000050000001C000000FF00070091 +:1063D00007000500000000000600000004000000A7 +:1063E0001C000000FF00000100010400000000008C +:1063F00007000000040000001C000000FF00010175 +:10640000010105000000000012000000040000006F +:106410001C000000FF000003000302000000000059 +:1064200010000000040000001C000000FF0000023B +:106430000002000000000000130000000400000043 +:106440001C000000FF000103010303000000000026 +:1064500011000000040000000C000000FF00010219 +:10646000FFFF0100FF00000000000000FF0000002F +:1064700000000000FF00FFFFFFFFFF000000000022 +:10648000030000000100000002000000FF00FFFF09 +:10649000FFFFFF00000000001600000002000000E7 +:1064A00004000000FF00FFFFFFFF060000000000E7 +:1064B000170000000200000004000000FF00FFFFC2 +:1064C000FFFF0700000000000C00000003000000B8 +:1064D00004000000FF00FFFFFFFF0C00FF000000B2 +:1064E00000000000FF00000000000000FF00FFFFB0 +:1064F000FFFFFF00010000000B0000000300000090 +:1065000004000000FF00FFFFFFFF0B000100000080 +:106510000A0000000300000004000000FF00FFFF6D +:10652000FFFF0A00FF00000000000000FF00000065 +:1065300000000000FF00FFFFFFFFFF00FF00000062 +:1065400000000000FF00000000000000FF00FFFF4F +:10655000FFFFFF000000000002000000010000003B +:10656000020000000000FFFFFFFF0200010000002A +:106570000800000001000000020000000200FFFF10 +:10658000FFFF0800010000000900000001000000FA +:10659000020000000300FFFFFFFF090000000000F1 +:1065A0000400000001000000020000000400FFFFE2 +:1065B000FFFF0400000000000500000001000000D3 +:1065C000020000000500FFFFFFFF050000000000C3 +:1065D0000200000001000000020000000A00FFFFAE +:1065E000FFFF020001000000030000000B0000009C +:1065F00004000000FF00FFFFFFFFFF00000000009D +:106600001B0000000B00000004000000FF00FFFF63 +:10661000FFFFFF00000000001C000000060000005B +:1066200000000000FF00FFFFFFFFFF000000000070 +:10663000180000000600000000000000FF00FFFF3F +:10664000FFFFFF000000000019000000060000002E +:1066500000000000FF00FFFFFFFFFF00010000003F +:10666000160000000300000000000000FF00FFFF14 +:10667000FFFFFF0001000000170000000300000002 +:1066800000000000FF00FFFFFFFFFF000000000010 +:10669000160000000200000000000000FF00FFFFE5 +:1066A000FFFFFF00000000001700000002000000D4 +:1066B00000000000FF00FFFFFFFFFF0000000000E0 +:1066C000130000000200000000000000FF00FFFFB8 +:1066D000FFFFFF00000000001000000002000000AB +:1066E00000000000FF00FFFFFFFFFF0000000000B0 +:1066F000120000000200000000000000FF00FFFF89 +:10670000FFFFFF0000000000110000000200000079 +:1067100000000000FF00FFFFFFFFFF00000000007F +:106720000D000000040000000C000000FF00050048 +:10673000FFFF0D0000000000150000000500000034 +:106740000C000000FF000700FFFFFF00000000003A +:1067500006000000040000000C000000FF00000123 +:10676000FFFFFF0000000000070000000400000021 +:106770000C000000FF000101FFFFFF00000000000F +:106780000200000001000000020000001400FFFFF2 +:10679000FFFF0200000000000000000000000000F9 +:1067A00095480000F5520000774800008B48000033 +:1067B000814800006D480000C949000059480000A8 +:1067C000554800000000000041726475696E6F203A +:1067D0004D302050726F0041726475696E6F2053A6 +:1067E000726C00000403090412011001EF02014061 +:1067F000032A4F8000010102000100000000000098 +:106800000000000000000000B553000047540000E5 +:1068100085530000C9530000995300003D54000007 +:106820000554000000000000080B000202020000F6 +:1068300009040000010202000005240010010424E4 +:106840000206052406000105240101010705810354 +:1068500010001009040100020A00000007050202EE +:106860004000000705830240000000000000000017 +:106870000000000000000000F9540000F552000084 +:10688000BD5500004D560000BD5600000000000040 +:1068900000000000000000002A2B2800000000007B +:1068A00000000000000000000000000000000000E8 +:1068B0002C9EB4A0A1A2A434A6A7A5AE362D37382D +:1068C000271E1F20212223242526B333B62EB7B836 +:1068D0009F8485868788898A8B8C8D8E8F909192F4 +:1068E000939495969798999A9B9C9D2F3130A3AD40 +:1068F000350405060708090A0B0C0D0E0F101112BE +:10690000131415161718191A1B1C1DAFB1B0B500BA +:106910000904020001030000000921010100012215 +:1069200065000705840340000105010902A1010972 +:1069300001A100850105091901290315002501950B +:10694000037501810295017505810305010930096F +:106950003109381581257F750895038106C0C0056A +:10696000010906A1018502050719E029E71500259F +:1069700001750195088102950175088103950675D9 +:1069800008150025650507190029658100C000006C +:106990004C590000FE5800002C5900008658000099 +:1069A0002C590000225900002C5900008658000084 +:1069B000FE580000FE5800002259000086580000D2 +:1069C0007E5800007E5800007E58000032590000BA +:1069D000745B00006E5B00006E5B0000645B000097 +:1069E000C45A0000C45A00005A5B0000645B0000F7 +:1069F000C45A00005A5B0000C45A0000645B0000E7 +:106A0000C25A0000C25A0000C25A0000FC5B0000DB +:046A10000000000082 +:106A140072B6054B0F215A788A435A701A780221AC +:0C6A24000A431A70FEE7C0460010004054 +:106A300040420F0000C201000000080001010000F8 +:106A4000FFFFFFFFD940000041410000DD5400007E +:0C6A5000D9560000B1400000000000001A +:106A5C00000000000000000000000000000000002A +:106A6C00000000000000000000000000000000001A +:106A7C00000000000000000000000000000000000A +:106A8C0000000000000000000000000000000000FA +:106A9C0000000000000000000000000000000000EA +:106AAC0000000000000000000000000000000000DA +:106ABC0000000000000000000000000000000000CA +:106ACC0000000000000000000000000000000000BA +:106ADC0000000000000000000000000000000000AA +:106AEC00000000000000000000000000000000009A +:106AFC00000000000000000000000000000000008A +:106B0C000000000000000000000000000000000079 +:106B1C000000000000000000000000000000000069 +:106B2C000000000000000000000000000000000059 +:106B3C000000000000000000000000000000000049 +:106B4C000000000000000000000000000000000039 +:106B5C000000000000000000000000000000000029 +:106B6C000000000000000000000000000000000019 +:106B7C000000000000000000000000000000000009 +:106B8C0000000000000000000000000000000000F9 +:106B9C0000000000000000000000000000000000E9 +:106BAC0000000000000000000000000000000000D9 +:106BBC0000000000000000000000000000000000C9 +:106BCC0000000000000000000000000000000000B9 +:106BDC0000000000000000000000000000000000A9 +:106BEC000000000000000000000000000000000099 +:106BFC000000000000000000000000000000000089 +:106C0C000000000000000000000000000000000078 +:106C1C000000000000000000000000000000000068 +:106C2C000000000000000000000000000000000058 +:106C3C000000000000000000000000000000000048 +:106C4C000000000000000000000000000000000038 +:106C5C000000000000000000000000000000000028 +:106C6C000000000000000000000000000000000018 +:106C7C000000000000000000000000000000000008 +:106C8C0000000000000000000000000000000000F8 +:106C9C0000000000000000000000000000000000E8 +:106CAC0000000000000000000000000000000000D8 +:106CBC0000000000000000000000000000000000C8 +:106CCC0000000000000000000000000000000000B8 +:106CDC0000000000000000000000000000000000A8 +:106CEC000000000000000000000000000000000098 +:106CFC000000000000000000000000000000000088 +:106D0C000000000000000000000000000000000077 +:106D1C000000000000000000000000000000000067 +:106D2C000000000000000000000000000000000057 +:106D3C000000000000000000000000000000000047 +:106D4C000000000000000000000000000000000037 +:106D5C000000000000000000000000000000000027 +:106D6C000000000000000000000000000000000017 +:106D7C000000000000000000000000000000000007 +:106D8C0000000000000000000000000000000000F7 +:106D9C0000000000000000000000000000000000E7 +:106DAC0000000000000000000000000000000000D7 +:106DBC0000000000000000000000000000000000C7 +:106DCC0000000000000000000000000000000000B7 +:106DDC0000000000000000000000000000000000A7 +:106DEC000000000000000000000000000000000097 +:106DFC000000000000000000000000000000000087 +:106E0C000000000000000000000000000000000076 +:106E1C000000000000000000000000000000000066 +:106E2C000000000000000000000000000000000056 +:106E3C000000000000000000000000000000000046 +:106E4C000000000000000000000000000000000036 +:106E5C000000000000000000000000000000000026 +:106E6C000000000000000000000000000000000016 +:106E7C000000000000000000000000000000000006 +:106E8C0000000000000000000000000000000000F6 +:106E9C0000000000000000000000000000000000E6 +:106EAC0000000000000000000000000000000000D6 +:106EBC0000000000000000000000000000000000C6 +:106ECC0000000000000000000000000000000000B6 +:106EDC0000000000000000000000000000000000A6 +:106EEC000000000000000000000000000000000096 +:106EFC000000000000000000000000000000000086 +:106F0C000000000000000000000000000000000075 +:106F1C000000000000000000000000000000000065 +:106F2C000000000000000000000000000000000055 +:106F3C000000000000000000000000000000000045 +:106F4C000000000000000000000000000000000035 +:106F5C000000000000000000000000000000000025 +:106F6C000000000000000000000000000000000015 +:106F7C000000000000000000000000000000000005 +:106F8C0000000000000000000000000000000000F5 +:106F9C0000000000000000000000000000000000E5 +:106FAC0000000000000000000000000000000000D5 +:106FBC0000000000000000000000000000000000C5 +:106FCC0000000000000000000000000000000000B5 +:040000030000433581 +:00000001FF diff --git a/bootloaders/nano_33_iot/samd21_sam_ba_arduino_nano_33_iot.bin b/bootloaders/nano_33_iot/samd21_sam_ba_arduino_nano_33_iot.bin new file mode 100755 index 0000000..ddb48ab Binary files /dev/null and b/bootloaders/nano_33_iot/samd21_sam_ba_arduino_nano_33_iot.bin differ diff --git a/bootloaders/nano_33_iot/samd21_sam_ba_arduino_nano_33_iot.hex b/bootloaders/nano_33_iot/samd21_sam_ba_arduino_nano_33_iot.hex new file mode 100644 index 0000000..ae32da0 --- /dev/null +++ b/bootloaders/nano_33_iot/samd21_sam_ba_arduino_nano_33_iot.hex @@ -0,0 +1,403 @@ +:10000000FC7F002001060000F1050000F50500005E +:1000100000000000000000000000000000000000E0 +:10002000000000000000000000000000F9050000D2 +:100030000000000000000000FD0500004107000076 +:1000400010B5064C2378002B07D1054B002B02D0AE +:10005000044800E000BF0123237010BD5C000020B5 +:1000600000000000A018000008B5084B002B03D0CA +:100070000748084900E000BF07480368002B03D089 +:10008000064B002B00D0984708BDC046000000007A +:10009000A0180000600000205800002000000000B0 +:1000A000154A164B1178002909D115491878097895 +:1000B0004118C9B21970802012498002C8611178B4 +:1000C0000131C9B211701978F02902D819780929BB +:1000D00009D80B4908784042C0B2087018780978EE +:1000E0004118C9B2197012781B789A4203D1802244 +:1000F000044B9202DA617047780000200100002072 +:10010000000000200044004110B5C3699C07FCD4E6 +:1001100003680224A3430360C46901231C42FBD18A +:100120000468234303600368DC07FCD4C46901232B +:100130001C42FBD1C469DC401C42F7D1084B1A4376 +:100140000260C3695A07FCD4C0239B0243608181CB +:10015000C3699C07FCD4036802221343036010BDEB +:1001600004000040037EDA07FCD5018570470000DB +:10017000027E01235107FBD5428B1A4207D1428BE5 +:10018000DA401A4203D1428B92081A4202D0034B42 +:1001900001221A70008DC0B27047C046790000205D +:1001A00070B50368041C988B1A1C0821FF320842A2 +:1001B00026D0802099839872112353704021144BCC +:1001C000917150715E68134DC0202E40800506432A +:1001D0005E605E693540284358610F4818600F48DB +:1001E00018615D680E4828408025AD02284358609C +:1001F0005868800B8003586000235171237105E01B +:10020000137ADA0602D5201C00F0D4FA207970BDEA +:1002100098010020FFFFFF8F9800002018010020A8 +:10022000FF3F00F0002303714371044B01608360C2 +:100230000B78022213430B707047C046A1010000E7 +:1002400038B5364B2021DA6901200A43DA61344B94 +:1002500006241A7802431A70324B0F221978914300 +:1002600019701978214319702F490C7820430870B0 +:1002700019780A401A701A7860210A431A702B4BB9 +:100280002B4A5A805A7852B2002AFBDB294B0121B3 +:100290001A780A431A709A78D107FCD42648026863 +:1002A000510B1F221140914200D1052111408C01B8 +:1002B0001D8D22492940214319850468A10C0A405B +:1002C0001F2A00D11D221C8D1F210A408C4322436E +:1002D0001A8502680721D20D0A408A4200D1032202 +:1002E0000A40188D1103164A02400A431A851978EC +:1002F0007F220A401A701A78042112480A431A70A1 +:1003000058621A890C218A431A811A8901218A4369 +:100310001A810021802201F040F938BD000400401C +:10032000584400413C44004159440041000C004005 +:100330000640000000500041246080003FF8FFFFAD +:10034000FF8FFFFF98010020F7B5141C1F4A5F01C3 +:1003500001971D1CD319061C5869271C4000400F2B +:1003600003301033C74006D00F1C80225968120694 +:100370000A435A6009E02F1C7B1E9F41144BBF01AA +:10038000FF18381C221C01F0FFF801990F480835AE +:1003900042181761131C5269A104920B890C920335 +:1003A0000A435A6159690B4A0A405A616B01F318B2 +:1003B0000222DA715979802252420A435A716B0142 +:1003C000F318DB799A07FAD5201CFEBD98010020AE +:1003D00018010020FF3F00F0F8B51A4E051C3378D5 +:1003E000141C002B12D1184B184A1A645A6C920B29 +:1003F00092035A64586C164A02405A64A2235B0066 +:10040000EA5C40200243EA54012333704827FF3757 +:10041000EA5D0123134012D00B4B5A6C9204920CEC +:10042000A24202D25C6CA404A40C081C221C074942 +:1004300001F0AAF80123EB550023337000E01C1CE7 +:10044000201CF8BD7A00002098010020D800002070 +:10045000FF3F00F0FF3083792022002900D11022D5 +:100460001343837170470000084BFF305A69920BA9 +:1004700092035A6102230372827980235B42134301 +:100480008371037A9A07FCD57047C0469801002013 +:1004900080235B421943C9B28172704770B5A023B3 +:1004A00003225B00C254134B134A5C6CC0211440FE +:1004B00089050C4346255C64FF35402444550F4DA7 +:1004C00030261D6490256D0046555D6B154029430F +:1004D000922559636D0080214155094D1D63B0255A +:1004E0006D0044555C6F22405A67B2235B00C154D3 +:1004F00070BDC04698010020FFFFFF8FD80000208C +:1005000058010020024B5B785BB2002BFADB70478E +:10051000000C0040024BDB68DA06FBD57047C04692 +:1005200000080040F8B5264B1E215A6802268A436F +:10053000244C32435A60A660FFF7E4FF224B234D60 +:100540006360FFF7DFFFAE84FFF7E4FF204B1B681B +:100550009B0E3F2B00D11F231E4A9B0213431E4AB2 +:100560000026EA62AB62AE84FFF7D4FF1B4B022782 +:10057000AB84FFF7CFFFAB8C3B43AB84FFF7CAFFE5 +:1005800063883F2293431F43678062888023DB0197 +:1005900013436380A660FFF7B5FF114B6360FFF75D +:1005A000B1FF104B104AC0215A60104A0906106A68 +:1005B0000002000A0143116207229E601A60F8BD22 +:1005C00000400041000C004006000100000800400F +:1005D00024608000FF01000080BB0A1C240500008D +:1005E0000007030010E000E0E703000000ED00E07A +:1005F0000EBEFEE70DBEFEE705BEFEE702BEFEE74D +:100600000E4A0F4838B5824204D10E4A0E4B93422F +:100610000ED10AE00D4C9442F7D00023D118884245 +:10062000F3D9E55804330D60F8E700F011F804E061 +:100630009342FAD2002102C3FAE7FEE7000000204D +:100640005C000020A80300205C000020A41800002B +:1006500038B5304B1A681C1C013221D02E4A191DA6 +:100660001160D9B200291BD12C4A10780122104008 +:100670002B4A0AD115682B498D4201D110600FE039 +:100680001160294901390029FCD11160226882F3E7 +:100690000888FF229343254A93601E4B5B681847E6 +:1006A000FFF740FF62B600F09DFD00F04FF8204BD1 +:1006B000802292029A601F4B1F4A041C5A601B4AF8 +:1006C000C021106A09060002000A014311620022DB +:1006D0009A6007221A60A368201C9847174B0028CD +:1006E00001D001221A701A78002A05D0002000F0EB +:1006F0008BFA00F003FBFCE71B78002BEBD100F03A +:10070000E5FD0028E7D0012000F07EFA00F0F6FABF +:10071000FCE7C0460020000018020020380400401A +:10072000FC7F00203581730748E8010000ED00E000 +:100730000044004110E000E0E70300007B000020DF +:1007400008B5FFF7ADFC00F0C3FA08BD10B5054BC6 +:10075000054C2360FFF774FD201C2168FFF762FD44 +:10076000201C10BD005000411C02002070B5051C6B +:10077000C0B0081C161C0C1C00F017FF40006A4695 +:10078000032302305370107076080123E218013AF7 +:1007900011785A00002906D1281C69460023FFF76A +:1007A000D3FD40B070BDB342F6DA684681520133E2 +:1007B000ECE70000F7B5BA4A04681378B949271C7A +:1007C000FF37051C102038720B705378B648B74EAF +:1007D000037093783380D178338809020B433380D8 +:1007E0001179B34B19805179188809020843188090 +:1007F0009079B0490880D2790888120202430A80B1 +:1008000040227A71A84F3A78A64F120238780F1C0E +:100810000243A9488446181C624500D1C2E020DC8E +:10082000802149008A4200D16EE109DC812A00D191 +:1008300092E0822A00D195E0802A00D064E18BE02A +:1008400081235B009A4200D1CFE000DA58E1C02357 +:100850009B009A4200D157E1984B9A4200D14FE158 +:1008600052E190231B019A4269D015DCD023DB00B2 +:100870009A4222D088231B019A4269D0A023DB0030 +:100880009A4200D040E1201CFFF7EEFD3188286835 +:1008900089B2FFF7FDFD3BE1894B9A4200D12FE180 +:1008A00000DC31E1874B9A4200D11DE1864B9A4230 +:1008B00000D029E133886B7122E133881B0A012BB8 +:1008C00008D10B8812222868934201D80A8892B274 +:1008D0007E4911E133881B0A022B08D10B88432281 +:1008E0002868934201D80A8892B2794904E1338892 +:1008F0001B0A032B00D007E13388DBB2012B17D092 +:10090000002B07D0022B00D0FEE00A882868D2B264 +:10091000704911E0042201A86F4900F035FE3B88C0 +:1009200004222868934201D83A8892B201A9E3E0F0 +:100930000A8828686949D2B2FFF718FFE8E03388CF +:10094000201C2B71FFF790FD201CFFF7A7FDDFE0B7 +:10095000291C01C90122CFE0614900230B802868CE +:100960000222CAE05E4900220A8018885022104004 +:100970005C4A10701E880F203040188018880328A9 +:1009800000D9C1E012781B8808335B01E418A37911 +:10099000002A01D09B0600E0DB06DB0F0B802868F5 +:1009A0000222A9E019887F2291434E4AC9B21170F0 +:1009B00018880F21014019803188002900D0A3E058 +:1009C0001988002900D19FE01988032900D99BE0EC +:1009D00012781B8808335B01E318002A02D020221A +:1009E0005A718DE0102159718AE002887F239A4361 +:1009F0003C4BD2B21A7001880F220A400280328822 +:100A0000002A00D080E00288002A00D17CE0028821 +:100A1000032A00D978E01B78002B1FD00388083305 +:100A20005B01E3189B799A066AD503882022083374 +:100A30005B01E3181A71038808335B01E318DB7963 +:100A40005F065DD50388402208335B01E318DA7145 +:100A50000388022208335B01E3181EE00388083391 +:100A60005B01E3189B79D9064AD503881022083325 +:100A70005B01E3181A71038808335B01E318DB7923 +:100A80009A063DD50388202208335B01E318DA710A +:100A90000388012208335B01E3181A7130E0C04675 +:100AA000980000207D0000208200002084000020AB +:100AB00086000020800000200203000001030000E7 +:100AC00021200000A121000021220000F4150000D7 +:100AD00004000020E0150000D0150000D41500002F +:100AE0007E0000207C0000200B88082228689342AA +:100AF00001D80A8892B207490023FFF725FC07E0D6 +:100B0000201CFFF7B1FC03E0201C0121FFF7A2FC31 +:100B1000F7BDC0464800002007B5054B01220190F3 +:100B200001A91868131CFFF70FFC01200EBDC04679 +:100B30001C02002013B5054B6C4607341868211CB5 +:100B40000122FFF749FC207816BDC0461C02002098 +:100B500010B5074C201CFFF723FB031C0020834229 +:100B600005D022684823FF33D05C0123184010BD14 +:100B70001C02002010B5054A0C1C031C191C10682F +:100B80000123221CFFF7E0FB201C10BD1C020020EB +:100B900070B5084C061C201C0D1CFFF701FB002340 +:100BA000984205D02068311C2A1CFFF715FC031C55 +:100BB000181C70BD1C020020F8B50C4C051C201C34 +:100BC0000E1CFFF7EDFA0023271C341C98420AD0B4 +:100BD000002C07D0291C221C3868FFF7FDFB241AC3 +:100BE0002D18F5E7331C181CF8BDC0461C02002068 +:100BF00008B5031C081C111C9847024B64221A807C +:100C000008BDC0468C000020012805D1054B064ACE +:100C10001A60064B187004E0002802D1044A014B08 +:100C20001A6070478C0200202816000094000020F3 +:100C30007416000030B50A1C1C4985B00978031CE5 +:100C400000292AD0042A01D1006804E0022A01D137 +:100C5000008800E00078520004A98B180B3B9C1A16 +:100C6000A3420BD00F210140092902D83025294386 +:100C700000E0373119700009013BF1E701A9302389 +:100C80000B7078234B700A208B1898700D20D87049 +:100C9000074B04321B68D86803E005490968C86837 +:100CA000191CFFF7A5FF05B030BDC0468800002025 +:100CB0008C02002072B6EFF30883044A13600368C5 +:100CC00083F30888436818477047C04690020020A5 +:100CD000084B1A88002A03D01A88013A92B21A8067 +:100CE000054B1A88002A03D01A88013A92B21A805A +:100CF0007047C0468C0000208A000020F0B591B0FB +:100D000008A9CC4A0B1C31CA31C351CA51C360CAAD +:100D100060C3C94BC9489A687A255203520F9200A2 +:100D20005258C74902609C68A4B262430C60C5492E +:100D300000240A60C44A1460C44C2570C44CC54DDC +:100D40002368281C1B6940219847002802D0C24B09 +:100D500064221A80C14B00221860C14B1D60C14B38 +:100D6000C04DBE4F1A602A683B689A42E6D2BC4B1F +:100D70001B681A78FF2A00D114E2232A00D0EBE185 +:100D8000B94E3378002B06D0B14BB8491B6802220C +:100D9000D868FFF72DFFAD4B1B78532B3CD13B6838 +:100DA0002A6893421ED9AE4801322A609A1AB04B83 +:100DB00001681B6801310160AE4E9A4201D2326077 +:100DC00000E03360A04832680068049000F0DCFB6B +:100DD000336829685A182A60A14A1668F118116008 +:100DE000A54A13702B68013B2B609D4B1A68013A92 +:100DF0001A60A14B9E4A1B7811688B420AD2226866 +:100E00009148C91A006892699047002802D0924B15 +:100E100064221A80C0468DE1522B0AD18A48944A36 +:100E20002368006811685B69039098476422934BBC +:100E30000DE04F2B05D1844B8D4A1B6812681A7048 +:100E400078E1482B05D1804B894A1B6812681A80CB +:100E500070E1572B05D17C4B854A1B6812681A60DC +:100E600068E16F2B03D1784B0121186807E0682BEC +:100E700008D1754B7E481B6802211B880360FFF771 +:100E8000D9FE57E1772B06D16F4B79481B680421B7 +:100E90001B680360F3E7472B13D1754B1868FFF706 +:100EA00009FF774B1B6883F3088862B6754B1B7884 +:100EB000002B00D13EE1664B06201B681B6898475B +:100EC00038E1542B04D101233370614B1B6864E07B +:100ED0004E2B0CD13378002B06D15D4B63491B6838 +:100EE0000222D868FFF784FE0023337022E1562BDC +:100EF00057D123686449D8680122FFF779FE236837 +:100F00006249D8680322FFF773FE614D2368291CEC +:100F1000D8680122FFF76CFE23685E49D8680D226D +:100F2000FFF766FE2368291CD8680122FFF760FEE0 +:100F30004B4F4C4D5849002339602B603A1C281CFC +:100F400013685E1C16601B780593002B03D00368A2 +:100F500001330360F4E73E4E2A683368D868FFF730 +:100F600047FE33684A49D8680122FFF741FE0599D8 +:100F700029604A4939603A4A1368581C10601B7846 +:100F8000002B04D0374B1A6801321A60F3E733683C +:100F90002A68D868FFF72CFE3368D86833490222E4 +:100FA000C6E0334A582B17D1244E264D36681368B5 +:100FB0002A68B10093420AD21F4D5808E8613848A8 +:100FC00028801D4D287DC607FBD55B18F2E7204B16 +:100FD00034491B68D868AAE0592B79D112681A4B9A +:100FE0003149002A02D11B680B606CE0124D086881 +:100FF00019686B68104E8025AB4392087360002A15 +:1010000061D02A4B0C4D2B800B4E337DDD07FBD579 +:1010100000230A4D2D680195AD08AB4203D3244D42 +:10102000054E358046E09342F9D09D004659013384 +:101030004E51EEE708160000004000414402002037 +:101040003C020020380200208802002034020020E8 +:101050008C020020480200208A0000202C02002080 +:1010600030020020400200208800002068160000A6 +:101070009402002098020020280200208C0000200A +:101080009002002094000020441600006D1600001D +:101090004616000090160000481600005416000086 +:1010A00002A5FFFF5D1600009000002044A5FFFF91 +:1010B00004A5FFFF3F4E357DEE07FBD59D00491986 +:1010C0004019D21A9BE73C4B3C491B68D8682EE07C +:1010D0005A2B2FD13A4B17681D680026EF19BD42D5 +:1010E00006D02878311C00F013F90135061CF6E70C +:1010F000314B34491B680122D868FFF779FD07237B +:101100000F223240111C36093031092A00DD073127 +:101110001820C0186A468154013BF1D2236806A901 +:10112000D8680822FFF764FD23682749D86803229E +:10113000FFF75EFD254B7A221A70254B00221A60BC +:10114000244B1B7893422DD01B4B23491B68012253 +:10115000D868FFF74DFD25E0111C3039C8B21C4B93 +:10116000092804D81D682A01114319601AE0111CCE +:101170004139052903D81E68373A310106E0111CB0 +:101180006139052904D81868573A01010A4308E073 +:101190002C2A03D10A4A1968116001E00B490A7030 +:1011A00000221A600D4B1A6801321A600C4B1A6843 +:1011B0000132D5E5004000418C020020611600009C +:1011C0008802002065160000671600003402002027 +:1011D00094020020880000206B16000040020020CE +:1011E0003002002010B51C4B01201A780324024362 +:1011F0001A701A4B0F2219789143197019782143EC +:10120000197017490C782043087019780A401A7031 +:101210001A7830210A431A70124B80211A6A0A4345 +:101220001A62114B114A5A805A7852B2002AFBDBDB +:10123000C4220F480F499203FEF766FF0E4A0023AF +:1012400013700E4A13700E4A13700E4A13700E4A32 +:1012500013700E4A137010BDD6440041BB440041C8 +:10126000D744004100040040000C00401940000039 +:10127000001C00422AF600009C02002023030020EC +:101280009D020020A0020020240300202103002052 +:1012900008B5C1B20248FEF765FF012008BDC0468F +:1012A000001C0042024B187E4007C00F7047C0462A +:1012B000001C004208B5FFF7F5FF0028FBD00248EC +:1012C000FEF756FF08BDC046001C004208B5FFF7F8 +:1012D000E9FF0023984205D0FFF7ECFF031C233BF6 +:1012E0005A425341181C08BD70B5041C0D1C461809 +:1012F000B44204D02078FFF7CBFF0134F8E7281C74 +:1013000070BD10B5041CFFF7D5FF2070012010BD83 +:101310000B0A5840034B4000C05A0902484080B2B3 +:101320007047C0469E160000F7B50024051C0F1C30 +:10133000261CBC4220D0FFF7BDFF114BC0B21B786A +:101340000190002B1AD1311CFFF7E2FF0D4B061C58 +:101350001A88002A04D10C4A11782A1C002907D0C7 +:1013600001996A1C2970802F02D1198801391980CE +:101370000134A4B2151CDCE7301C00E00120FEBDE6 +:10138000210300209E02002022030020F0B53E4EE3 +:1013900085B0002203900C1C32703C4B914201D16D +:1013A000012201E03A490C801A707F231C4201D0CF +:1013B00080349C43FFF77EFF3378C0B2002B07D008 +:1013C00000253570FFF776FF3378C0B2AB4236D1D7 +:1013D000432803D0712853D01528EBD10123009363 +:1013E0000120FFF755FF0098FFF752FF0099802575 +:1013F000C843C0B2FFF74CFF039B00270293244A67 +:101400001388002B1DD1214901930978002918D197 +:101410000198FFF73DFF391C0198FFF779FF013D67 +:10142000071C002DEBD1000AC0B2FFF731FFF8B264 +:10143000FFF72EFFFFF73EFF3378002B0AD0357001 +:101440001FE00299013B09781380029B019101334F +:101450000293DDE7C0B2062807D1009B0399013350 +:10146000DBB280310093803C0391002CB8D1042082 +:10147000FFF70EFFFFF71EFF044B01251C7000E075 +:101480000025281C05B0F0BD210300202203002008 +:101490009E020020F0B5384C87B0002301902370E5 +:1014A000994201D1012301E0344A1180344A642673 +:1014B00013704320FFF7ECFE324FFFF7F3FE0028D6 +:1014C00003D1002F03D0013FF7E7002F03D1013EE6 +:1014D000002EEED14DE00125FFF7ECFE2378002B26 +:1014E00038D1C0B20290012805D004283DD1062091 +:1014F000FFF7CEFE39E005AE0221301CFFF714FFE6 +:1015000001988021FFF710FF23780390002B18D15A +:10151000FFF7D0FE0702FFF7CDFEBFB223783F18DA +:10152000BFB2012B0DD0039B9F4207D13378AB4252 +:1015300004D1EB437278DBB29A4204D01820FFF753 +:10154000A7FE002303E00620FFF7A2FE029B2278FD +:10155000002A02D0002626700BE0012B05D1019A4B +:101560006B1C8032DDB20192B6E7054A002313708E +:101570000126301C07B0F0BD210300209E02002090 +:101580002203002000350C0010B50023934203D045 +:10159000CC5CC4540133F9E710BD031C821893429C +:1015A00002D019700133FAE770470023C25C01339F +:1015B000002AFBD1581E7047F8B5C046F8BC08BCDD +:1015C0009E467047F8B5C046F8BC08BC9E467047BA +:1015D0000403090441726475696E6F204C4C43002A +:1015E00041726475696E6F204E4F4E4120574C41D9 +:1015F0004E0000001201000202000040412357008B +:1016000000020102000100000800000010000000BC +:1016100020000000400000008000000000010000E9 +:10162000000200000004000091120000B51200004A +:10163000A5120000E9120000031300008D13000042 +:10164000951400007600200041707220313920325C +:101650003031390031343A33383A343800580A0DD1 +:1016600000590A0D005A00230A0D003E00322E30A8 +:1016700000000000190B0000350B0000510B0000AA +:10168000750B0000910B0000750B0000B90B0000FA +:101690005B41726475696E6F3A58595A5D0000007B +:1016A0002110422063308440A550C660E770088155 +:1016B00029914AA16BB18CC1ADD1CEE1EFF13112CC +:1016C000100273325222B5529442F772D6623993A5 +:1016D00018837BB35AA3BDD39CC3FFF3DEE362241C +:1016E000433420040114E664C774A44485546AA5F5 +:1016F0004BB528850995EEE5CFF5ACC58DD55336AC +:10170000722611163006D776F6669556B4465BB744 +:101710007AA719973887DFF7FEE79DD7BCC7C4487B +:10172000E5588668A7784008611802282338CCC994 +:10173000EDD98EE9AFF9488969990AA92BB9F55A0B +:10174000D44AB77A966A711A500A333A122AFDDBE4 +:10175000DCCBBFFB9EEB799B588B3BBB1AABA66CDB +:10176000877CE44CC55C222C033C600C411CAEED34 +:101770008FFDECCDCDDD2AAD0BBD688D499D977EEB +:10178000B66ED55EF44E133E322E511E700E9FFF84 +:10179000BEEFDDDFFCCF1BBF3AAF599F788F88913A +:1017A000A981CAB1EBA10CD12DC14EF16FE180101E +:1017B000A100C230E3200450254046706760B98321 +:1017C0009893FBA3DAB33DC31CD37FE35EF3B1026E +:1017D0009012F322D2323542145277625672EAB531 +:1017E000CBA5A89589856EF54FE52CD50DC5E234BE +:1017F000C324A01481046674476424540544DBA701 +:10180000FAB79987B8975FE77EF71DC73CD7D3260D +:10181000F2369106B01657667676154634564CD990 +:101820006DC90EF92FE9C899E9898AB9ABA944585D +:10183000654806782768C018E1088238A3287DCB60 +:101840005CDB3FEB1EFBF98BD89BBBAB9ABB754AAD +:10185000545A376A167AF10AD01AB32A923A2EFDF0 +:101860000FED6CDD4DCDAABD8BADE89DC98D267CFD +:10187000076C645C454CA23C832CE01CC10C1FEF40 +:101880003EFF5DCF7CDF9BAFBABFD98FF89F176E4D +:10189000367E554E745E932EB23ED10EF01E000081 +:0418A0000000000044 +:1018A400011400000902430002010080320904000F +:1018B40000010202000005240010010424020005B6 +:1018C400240600010524010001070583030800FF25 +:1018D40009040100020A000000070581024000001B +:1018E400070502024000000000C2010000000800D9 +:0C18F4006900000041000000000000003E +:0400000300000601F2 +:00000001FF diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/.DS_Store b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/.DS_Store new file mode 100755 index 0000000..d1231f5 Binary files /dev/null and b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/.DS_Store differ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/Bootloader_Sofia.atsln b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/Bootloader_Sofia.atsln new file mode 100755 index 0000000..9a1d3d8 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/Bootloader_Sofia.atsln @@ -0,0 +1,20 @@ + +Microsoft Visual Studio Solution File, Format Version 11.00 +# Atmel Studio Solution File, Format Version 11.00 +Project("{54F91283-7BC4-4236-8FF9-10F437C3AD48}") = "Bootloader_Sofia", "Bootloader_Sofia.cproj", "{7ABD2862-543D-4184-845E-8DC3E340E2CC}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|ARM = Debug|ARM + Release|ARM = Release|ARM + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {7ABD2862-543D-4184-845E-8DC3E340E2CC}.Debug|ARM.ActiveCfg = Debug|ARM + {7ABD2862-543D-4184-845E-8DC3E340E2CC}.Debug|ARM.Build.0 = Debug|ARM + {7ABD2862-543D-4184-845E-8DC3E340E2CC}.Release|ARM.ActiveCfg = Release|ARM + {7ABD2862-543D-4184-845E-8DC3E340E2CC}.Release|ARM.Build.0 = Release|ARM + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/Bootloader_Sofia.atsuo b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/Bootloader_Sofia.atsuo new file mode 100755 index 0000000..fe9a974 Binary files /dev/null and b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/Bootloader_Sofia.atsuo differ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/Bootloader_Sofia.cproj b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/Bootloader_Sofia.cproj new file mode 100755 index 0000000..ca46b3f --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/Bootloader_Sofia.cproj @@ -0,0 +1,1089 @@ + + + + 2.0 + 6.2 + com.Atmel.ARMGCC.C + {7abd2862-543d-4184-845e-8dc3e340e2cc} + ATSAMD21G18A + samd21 + Executable + C + $(MSBuildProjectName) + .elf + $(MSBuildProjectDirectory)\$(Configuration) + bootloader_stk500v2_beta + Bootloader_Sofia + bootloader_stk500v2_beta + Native + true + false + true + true + 0x20000000 + + exception_table + 2 + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + com.atmel.avrdbg.tool.edbg + SWD + + + + 2000000 + + SWD + + com.atmel.avrdbg.tool.edbg + FFFFFFFFFFFFFFFFFFFF + EDBG + + true + + + + + True + True + True + True + True + + + NDEBUG + BOARD=SAMD21_XPLAINED_PRO + __SAMD21J18A__ + ARM_MATH_CM0=true + USB_DEVICE_LPM_SUPPORT + UDD_ENABLE + EXTINT_CALLBACK_MODE=true + RTC_COUNT_ASYNC=true + USART_CALLBACK_MODE=false + + + False + + + ../common2/applications/xplained_pro_user_application/samd21j18a_samd21_xplained_pro/config + ../src/ASF/sam0/utils/header_files + ../src/ASF/thirdparty/CMSIS/Lib/GCC + ../src/config + ../src/ASF/sam0/drivers/system/interrupt/system_interrupt_samd21 + ../src/ASF/common/utils + ../src/ASF/sam0/boards/samd21_xplained_pro + ../src/ASF/sam0/drivers/system/pinmux + ../src + ../src/ASF/sam0/utils/preprocessor + ../src/ASF/sam0/utils/cmsis/samd21/include + ../src/ASF/sam0/drivers/system + ../src/ASF/common/boards + ../src/ASF/sam0/drivers/port + ../src/ASF/sam0/utils/cmsis/samd21/source + ../src/ASF/sam0/drivers/system/clock/clock_samd21_r21 + ../src/ASF/sam0/drivers/system/clock + ../src/ASF/sam0/boards + ../src/ASF/sam0/drivers/system/interrupt + ../src/ASF/sam0/utils + ../src/ASF/thirdparty/CMSIS/Include + ../src/ASF/common/services/sleepmgr + ../src/ASF/common/services/usb + ../src/ASF/common/services/usb/class/cdc + ../src/ASF/common/services/usb/class/cdc/device + ../src/ASF/common/services/usb/udc + ../src/ASF/sam0/drivers/usb + ../src/ASF/sam0/drivers/usb/stack_interface + ../src/ASF/sam0/drivers/nvm + ../src/ASF/sam0/drivers/rtc + ../src/ASF/sam0/drivers/sercom + ../src/ASF/sam0/drivers/sercom/usart + + + Optimize for size (-Os) + -fdata-sections + True + Maximum (-g3) + True + -pipe -fno-strict-aliasing -Wall -Wstrict-prototypes -Wmissing-prototypes -Werror-implicit-function-declaration -Wpointer-arith -std=gnu99 -ffunction-sections -fdata-sections -Wchar-subscripts -Wcomment -Wformat=2 -Wimplicit-int -Wmain -Wparentheses -Wsequence-point -Wreturn-type -Wswitch -Wtrigraphs -Wunused -Wuninitialized -Wunknown-pragmas -Wfloat-equal -Wundef -Wshadow -Wbad-function-cast -Wwrite-strings -Wsign-compare -Waggregate-return -Wmissing-declarations -Wformat -Wmissing-format-attribute -Wno-deprecated-declarations -Wpacked -Wredundant-decls -Wnested-externs -Wlong-long -Wunreachable-code -Wcast-align --param max-inline-insns-single=500 + True + + + libarm_cortexM0l_math + libm + + + + + ../cmsis/linkerScripts + ../src/ASF/thirdparty/CMSIS/Lib/GCC + + + True + + -Wl,--entry=Reset_Handler -Wl,--cref -mthumb -T../src/ASF/sam0/utils/linker_scripts/samd21/gcc/samd21j18a_flash.ld + -DARM_MATH_CM0=true -DBOARD=SAMD21_XPLAINED_PRO -D__SAMD21J18A__ -DUSB_DEVICE_LPM_SUPPORT -DUDD_ENABLE -DEXTINT_CALLBACK_MODE=true -DRTC_COUNT_ASYNC=true -DUSART_CALLBACK_MODE=false + False + + + ../common2/applications/xplained_pro_user_application/samd21j18a_samd21_xplained_pro/config + ../src/ASF/sam0/utils/header_files + ../src/ASF/thirdparty/CMSIS/Lib/GCC + ../src/config + ../src/ASF/sam0/drivers/system/interrupt/system_interrupt_samd21 + ../src/ASF/common/utils + ../src/ASF/sam0/boards/samd21_xplained_pro + ../src/ASF/sam0/drivers/system/pinmux + ../src + ../src/ASF/sam0/utils/preprocessor + ../src/ASF/sam0/utils/cmsis/samd21/include + ../src/ASF/sam0/drivers/system + ../src/ASF/common/boards + ../src/ASF/sam0/drivers/port + ../src/ASF/sam0/utils/cmsis/samd21/source + ../src/ASF/sam0/drivers/system/clock/clock_samd21_r21 + ../src/ASF/sam0/drivers/system/clock + ../src/ASF/sam0/boards + ../src/ASF/sam0/drivers/system/interrupt + ../src/ASF/sam0/utils + ../src/ASF/thirdparty/CMSIS/Include + ../src/ASF/common/services/sleepmgr + ../src/ASF/common/services/usb + ../src/ASF/common/services/usb/class/cdc + ../src/ASF/common/services/usb/class/cdc/device + ../src/ASF/common/services/usb/udc + ../src/ASF/sam0/drivers/usb + ../src/ASF/sam0/drivers/usb/stack_interface + ../src/ASF/sam0/drivers/nvm + ../src/ASF/sam0/drivers/rtc + ../src/ASF/sam0/drivers/sercom + ../src/ASF/sam0/drivers/sercom/usart + + + + + + + + + True + True + True + True + True + + + DEBUG + BOARD=SAMD21_XPLAINED_PRO + __SAMD21J18A__ + ARM_MATH_CM0=true + USB_DEVICE_LPM_SUPPORT + UDD_ENABLE + EXTINT_CALLBACK_MODE=true + RTC_COUNT_ASYNC=true + USART_CALLBACK_MODE=false + + + False + + + ../common2/applications/xplained_pro_user_application/samd21j18a_samd21_xplained_pro/config + ../src/ASF/sam0/utils/header_files + ../src/ASF/thirdparty/CMSIS/Lib/GCC + ../src/config + ../src/ASF/sam0/drivers/system/interrupt/system_interrupt_samd21 + ../src/ASF/common/utils + ../src/ASF/sam0/boards/samd21_xplained_pro + ../src/ASF/sam0/drivers/system/pinmux + ../src + ../src/ASF/sam0/utils/preprocessor + ../src/ASF/sam0/utils/cmsis/samd21/include + ../src/ASF/sam0/drivers/system + ../src/ASF/common/boards + ../src/ASF/sam0/drivers/port + ../src/ASF/sam0/utils/cmsis/samd21/source + ../src/ASF/sam0/drivers/system/clock/clock_samd21_r21 + ../src/ASF/sam0/drivers/system/clock + ../src/ASF/sam0/boards + ../src/ASF/sam0/drivers/system/interrupt + ../src/ASF/sam0/utils + ../src/ASF/thirdparty/CMSIS/Include + ../src/ASF/common/services/sleepmgr + ../src/ASF/common/services/usb + ../src/ASF/common/services/usb/class/cdc + ../src/ASF/common/services/usb/class/cdc/device + ../src/ASF/common/services/usb/udc + ../src/ASF/sam0/drivers/usb + ../src/ASF/sam0/drivers/usb/stack_interface + ../src/ASF/sam0/drivers/extint + ../src/ASF/sam0/drivers/nvm + ../src/ASF/sam0/drivers/rtc + ../src/ASF/sam0/drivers/sercom + ../src/ASF/sam0/drivers/sercom/usart + + + Optimize for size (-Os) + -fdata-sections -ffunction-sections + True + True + True + Maximum (-g3) + True + -pipe -fno-strict-aliasing -Wall -Wstrict-prototypes -Wmissing-prototypes -Werror-implicit-function-declaration -Wpointer-arith -std=gnu99 -ffunction-sections -fdata-sections -Wchar-subscripts -Wcomment -Wformat=2 -Wimplicit-int -Wmain -Wparentheses -Wsequence-point -Wreturn-type -Wswitch -Wtrigraphs -Wunused -Wuninitialized -Wunknown-pragmas -Wfloat-equal -Wundef -Wshadow -Wbad-function-cast -Wwrite-strings -Wsign-compare -Waggregate-return -Wmissing-declarations -Wformat -Wmissing-format-attribute -Wno-deprecated-declarations -Wpacked -Wredundant-decls -Wnested-externs -Wlong-long -Wunreachable-code -Wcast-align --param max-inline-insns-single=500 + True + + + libarm_cortexM0l_math + libm + + + + + ../cmsis/linkerScripts + ../src/ASF/thirdparty/CMSIS/Lib/GCC + + + True + + -Wl,--entry=Reset_Handler -Wl,--cref -mthumb -T../src/ASF/sam0/utils/linker_scripts/samd21/gcc/samd21j18a_flash.ld + Default (-g) + -DARM_MATH_CM0=true -DBOARD=SAMD21_XPLAINED_PRO -D__SAMD21J18A__ -DUSB_DEVICE_LPM_SUPPORT -DUDD_ENABLE -DEXTINT_CALLBACK_MODE=true -DRTC_COUNT_ASYNC=true -DUSART_CALLBACK_MODE=false + False + + + ../common2/applications/xplained_pro_user_application/samd21j18a_samd21_xplained_pro/config + ../src/ASF/sam0/utils/header_files + ../src/ASF/thirdparty/CMSIS/Lib/GCC + ../src/config + ../src/ASF/sam0/drivers/system/interrupt/system_interrupt_samd21 + ../src/ASF/common/utils + ../src/ASF/sam0/boards/samd21_xplained_pro + ../src/ASF/sam0/drivers/system/pinmux + ../src + ../src/ASF/sam0/utils/preprocessor + ../src/ASF/sam0/utils/cmsis/samd21/include + ../src/ASF/sam0/drivers/system + ../src/ASF/common/boards + ../src/ASF/sam0/drivers/port + ../src/ASF/sam0/utils/cmsis/samd21/source + ../src/ASF/sam0/drivers/system/clock/clock_samd21_r21 + ../src/ASF/sam0/drivers/system/clock + ../src/ASF/sam0/boards + ../src/ASF/sam0/drivers/system/interrupt + ../src/ASF/sam0/utils + ../src/ASF/thirdparty/CMSIS/Include + ../src/ASF/common/services/sleepmgr + ../src/ASF/common/services/usb + ../src/ASF/common/services/usb/class/cdc + ../src/ASF/common/services/usb/class/cdc/device + ../src/ASF/common/services/usb/udc + ../src/ASF/sam0/drivers/usb + ../src/ASF/sam0/drivers/usb/stack_interface + ../src/ASF/sam0/drivers/nvm + ../src/ASF/sam0/drivers/rtc + ../src/ASF/sam0/drivers/sercom + ../src/ASF/sam0/drivers/sercom/usart + + + Default (-Wa,-g) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + compile + + + + \ No newline at end of file diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/atmel_devices_cdc.cat b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/atmel_devices_cdc.cat new file mode 100755 index 0000000..09a0673 Binary files /dev/null and b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/atmel_devices_cdc.cat differ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/atmel_devices_cdc.inf b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/atmel_devices_cdc.inf new file mode 100755 index 0000000..d2df608 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/atmel_devices_cdc.inf @@ -0,0 +1,182 @@ +; Windows 2000, XP, Vista, 7 and 8 (x32 and x64) setup file for Atmel CDC Devices +; Copyright (c) 2000-2013 ATMEL, Inc. + +[Version] +Signature = "$Windows NT$" +Class = Ports +ClassGuid = {4D36E978-E325-11CE-BFC1-08002BE10318} + +Provider = %Manufacturer% +LayoutFile = layout.inf +CatalogFile = atmel_devices_cdc.cat +DriverVer = 01/08/2013,6.0.0.0 + +;---------------------------------------------------------- +; Targets +;---------------------------------------------------------- +[Manufacturer] +%Manufacturer%=DeviceList, NTAMD64, NTIA64, NT + +[DeviceList] +%ATMEL_CDC_XPLAINED%=DriverInstall, USB\VID_03EB&PID_2122 +%ATMEL_CDC_USB_ZIGBIT_Sub%=DriverInstall, USB\VID_03EB&PID_214B +%ATMEL_CDC_USB_ZIGBIT_2_4%=DriverInstall, USB\VID_03EB&PID_214A +%ATMEL_CDC_SFW_EXAMPLE%=DriverInstall, USB\VID_03EB&PID_2307 +%ATMEL_CDC_EVK1XXX%=DriverInstall, USB\VID_03EB&PID_2310 +%ATMEL_CDC_ASF_EXAMPLE%=DriverInstall, USB\VID_03EB&PID_2404 +%ATMEL_CDC_ASF_COMPOSITE_EXAMPLE2%=DriverInstall, USB\VID_03EB&PID_2421&MI_00 +%ATMEL_CDC_ASF_COMPOSITE_EXAMPLE4%=DriverInstall, USB\VID_03EB&PID_2424&MI_00 +%ATMEL_CDC_ASF_EXAMPLE2_COM1%=DriverInstall, USB\VID_03EB&PID_2425&MI_00 +%ATMEL_CDC_ASF_EXAMPLE2_COM2%=DriverInstall, USB\VID_03EB&PID_2425&MI_02 +%ATMEL_CDC_ASF_EXAMPLE3_COM1%=DriverInstall, USB\VID_03EB&PID_2426&MI_00 +%ATMEL_CDC_ASF_EXAMPLE3_COM2%=DriverInstall, USB\VID_03EB&PID_2426&MI_02 +%ATMEL_CDC_ASF_EXAMPLE3_COM3%=DriverInstall, USB\VID_03EB&PID_2426&MI_04 +%ATMEL_CDC_ASF_EXAMPLE3_COM4%=DriverInstall, USB\VID_03EB&PID_2426&MI_06 +%ATMEL_CDC_ASF_EXAMPLE3_COM5%=DriverInstall, USB\VID_03EB&PID_2426&MI_08 +%ATMEL_CDC_ASF_EXAMPLE3_COM6%=DriverInstall, USB\VID_03EB&PID_2426&MI_0A +%ATMEL_CDC_ASF_EXAMPLE3_COM7%=DriverInstall, USB\VID_03EB&PID_2426&MI_0C + +[DeviceList.NTAMD64] +%ATMEL_CDC_XPLAINED%=DriverInstall.NTamd64, USB\VID_03EB&PID_2122 +%ATMEL_CDC_USB_ZIGBIT_Sub%=DriverInstall.NTamd64, USB\VID_03EB&PID_214B +%ATMEL_CDC_USB_ZIGBIT_2_4%=DriverInstall.NTamd64, USB\VID_03EB&PID_214A +%ATMEL_CDC_SFW_EXAMPLE%=DriverInstall.NTamd64, USB\VID_03EB&PID_2307 +%ATMEL_CDC_EVK1XXX%=DriverInstall.NTamd64, USB\VID_03EB&PID_2310 +%ATMEL_CDC_ASF_EXAMPLE%=DriverInstall.NTamd64, USB\VID_03EB&PID_2404 +%ATMEL_CDC_ASF_COMPOSITE_EXAMPLE2%=DriverInstall.NTamd64, USB\VID_03EB&PID_2421&MI_00 +%ATMEL_CDC_ASF_COMPOSITE_EXAMPLE4%=DriverInstall.NTamd64, USB\VID_03EB&PID_2424&MI_00 +%ATMEL_CDC_ASF_EXAMPLE2_COM1%=DriverInstall.NTamd64, USB\VID_03EB&PID_2425&MI_00 +%ATMEL_CDC_ASF_EXAMPLE2_COM2%=DriverInstall.NTamd64, USB\VID_03EB&PID_2425&MI_02 +%ATMEL_CDC_ASF_EXAMPLE3_COM1%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_00 +%ATMEL_CDC_ASF_EXAMPLE3_COM2%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_02 +%ATMEL_CDC_ASF_EXAMPLE3_COM3%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_04 +%ATMEL_CDC_ASF_EXAMPLE3_COM4%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_06 +%ATMEL_CDC_ASF_EXAMPLE3_COM5%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_08 +%ATMEL_CDC_ASF_EXAMPLE3_COM6%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_0A +%ATMEL_CDC_ASF_EXAMPLE3_COM7%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_0C + +[DeviceList.NTIA64] +%ATMEL_CDC_XPLAINED%=DriverInstall.NTamd64, USB\VID_03EB&PID_2122 +%ATMEL_CDC_USB_ZIGBIT_Sub%=DriverInstall.NTamd64, USB\VID_03EB&PID_214B +%ATMEL_CDC_USB_ZIGBIT_2_4%=DriverInstall.NTamd64, USB\VID_03EB&PID_214A +%ATMEL_CDC_SFW_EXAMPLE%=DriverInstall.NTamd64, USB\VID_03EB&PID_2307 +%ATMEL_CDC_EVK1XXX%=DriverInstall.NTamd64, USB\VID_03EB&PID_2310 +%ATMEL_CDC_ASF_EXAMPLE%=DriverInstall.NTamd64, USB\VID_03EB&PID_2404 +%ATMEL_CDC_ASF_COMPOSITE_EXAMPLE2%=DriverInstall.NTamd64, USB\VID_03EB&PID_2421&MI_00 +%ATMEL_CDC_ASF_COMPOSITE_EXAMPLE4%=DriverInstall.NTamd64, USB\VID_03EB&PID_2424&MI_00 +%ATMEL_CDC_ASF_EXAMPLE2_COM1%=DriverInstall.NTamd64, USB\VID_03EB&PID_2425&MI_00 +%ATMEL_CDC_ASF_EXAMPLE2_COM2%=DriverInstall.NTamd64, USB\VID_03EB&PID_2425&MI_02 +%ATMEL_CDC_ASF_EXAMPLE3_COM1%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_00 +%ATMEL_CDC_ASF_EXAMPLE3_COM2%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_02 +%ATMEL_CDC_ASF_EXAMPLE3_COM3%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_04 +%ATMEL_CDC_ASF_EXAMPLE3_COM4%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_06 +%ATMEL_CDC_ASF_EXAMPLE3_COM5%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_08 +%ATMEL_CDC_ASF_EXAMPLE3_COM6%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_0A +%ATMEL_CDC_ASF_EXAMPLE3_COM7%=DriverInstall.NTamd64, USB\VID_03EB&PID_2426&MI_0C + +[DeviceList.NT] +%ATMEL_CDC_XPLAINED%=DriverInstall.NT, USB\VID_03EB&PID_2122 +%ATMEL_CDC_USB_ZIGBIT_Sub%=DriverInstall.NT, USB\VID_03EB&PID_214B +%ATMEL_CDC_USB_ZIGBIT_2_4%=DriverInstall.NT, USB\VID_03EB&PID_214A +%ATMEL_CDC_SFW_EXAMPLE%=DriverInstall.NT, USB\VID_03EB&PID_2307 +%ATMEL_CDC_EVK1XXX%=DriverInstall.NT, USB\VID_03EB&PID_2310 +%ATMEL_CDC_ASF_EXAMPLE%=DriverInstall.NT, USB\VID_03EB&PID_2404 +%ATMEL_CDC_ASF_COMPOSITE_EXAMPLE2%=DriverInstall.NT, USB\VID_03EB&PID_2421&MI_00 +%ATMEL_CDC_ASF_COMPOSITE_EXAMPLE4%=DriverInstall.NT, USB\VID_03EB&PID_2424&MI_00 +%ATMEL_CDC_ASF_EXAMPLE2_COM1%=DriverInstall.NT, USB\VID_03EB&PID_2425&MI_00 +%ATMEL_CDC_ASF_EXAMPLE2_COM2%=DriverInstall.NT, USB\VID_03EB&PID_2425&MI_02 +%ATMEL_CDC_ASF_EXAMPLE3_COM1%=DriverInstall.NT, USB\VID_03EB&PID_2426&MI_00 +%ATMEL_CDC_ASF_EXAMPLE3_COM2%=DriverInstall.NT, USB\VID_03EB&PID_2426&MI_02 +%ATMEL_CDC_ASF_EXAMPLE3_COM3%=DriverInstall.NT, USB\VID_03EB&PID_2426&MI_04 +%ATMEL_CDC_ASF_EXAMPLE3_COM4%=DriverInstall.NT, USB\VID_03EB&PID_2426&MI_06 +%ATMEL_CDC_ASF_EXAMPLE3_COM5%=DriverInstall.NT, USB\VID_03EB&PID_2426&MI_08 +%ATMEL_CDC_ASF_EXAMPLE3_COM6%=DriverInstall.NT, USB\VID_03EB&PID_2426&MI_0A +%ATMEL_CDC_ASF_EXAMPLE3_COM7%=DriverInstall.NT, USB\VID_03EB&PID_2426&MI_0C + +;---------------------------------------------------------- +; Windows 2000, XP, Vista, Windows 7, Windows 8 - 32bit +;---------------------------------------------------------- +[Reader_Install.NTx86] + + +[DestinationDirs] +DefaultDestDir=12 +DriverInstall.NT.Copy=12 + +[DriverInstall.NT] +include=mdmcpq.inf +CopyFiles=DriverInstall.NT.Copy +AddReg=DriverInstall.NT.AddReg + +[DriverInstall.NT.Copy] +usbser.sys + +[DriverInstall.NT.AddReg] +HKR,,DevLoader,,*ntkern +HKR,,NTMPDriver,,usbser.sys +HKR,,EnumPropPages32,,"MsPorts.dll,SerialPortPropPageProvider" + +[DriverInstall.NT.Services] +AddService = usbser, 0x00000002, DriverService.NT + +[DriverService.NT] +DisplayName = %Serial.SvcDesc% +ServiceType = 1 ; SERVICE_KERNEL_DRIVER +StartType = 3 ; SERVICE_DEMAND_START +ErrorControl = 1 ; SERVICE_ERROR_NORMAL +ServiceBinary = %12%\usbser.sys +LoadOrderGroup = Base + +;---------------------------------------------------------- +; Windows XP, Vista, Windows 7, Windows 8 - 64bit +;---------------------------------------------------------- + +[DriverInstall.NTamd64] +include=mdmcpq.inf +CopyFiles=DriverCopyFiles.NTamd64 +AddReg=DriverInstall.NTamd64.AddReg + +[DriverCopyFiles.NTamd64] +usbser.sys,,,0x20 + +[DriverInstall.NTamd64.AddReg] +HKR,,DevLoader,,*ntkern +HKR,,NTMPDriver,,usbser.sys +HKR,,EnumPropPages32,,"MsPorts.dll,SerialPortPropPageProvider" + +[DriverInstall.NTamd64.Services] +AddService=usbser, 0x00000002, DriverService.NTamd64 + +[DriverService.NTamd64] +DisplayName=%Serial.SvcDesc% +ServiceType=1 +StartType=3 +ErrorControl=1 +ServiceBinary=%12%\usbser.sys + +;---------------------------------------------------------- +; String +;---------------------------------------------------------- + +[Strings] +Manufacturer = "ATMEL, Inc." +ATMEL_CDC_XPLAINED = "XPLAINED Virtual Com Port" +ATMEL_CDC_USB_ZIGBIT_Sub = "ZigBit SubGHz USBstick Com Port" +ATMEL_CDC_USB_ZIGBIT_2_4 = "ZigBit 2.4GHz USBstick Com Port" +ATMEL_CDC_SFW_EXAMPLE = "Communication Device Class SFW example" +ATMEL_CDC_EVK1XXX = "EVK1XXX Virtual Com Port" +ATMEL_CDC_ASF_EXAMPLE = "Communication Device Class ASF example" +ATMEL_CDC_ASF_COMPOSITE_EXAMPLE2 = "Communication Device Class ASF composite example 2" +ATMEL_CDC_ASF_COMPOSITE_EXAMPLE4 = "Communication Device Class ASF composite example 4" +ATMEL_CDC_ASF_EXAMPLE2_COM1 = "Communication Device Class ASF example2, COM1" +ATMEL_CDC_ASF_EXAMPLE2_COM2 = "Communication Device Class ASF example2, COM2" +ATMEL_CDC_ASF_EXAMPLE3_COM1 = "Communication Device Class ASF example3, COM1" +ATMEL_CDC_ASF_EXAMPLE3_COM2 = "Communication Device Class ASF example3, COM2" +ATMEL_CDC_ASF_EXAMPLE3_COM3 = "Communication Device Class ASF example3, COM3" +ATMEL_CDC_ASF_EXAMPLE3_COM4 = "Communication Device Class ASF example3, COM4" +ATMEL_CDC_ASF_EXAMPLE3_COM5 = "Communication Device Class ASF example3, COM5" +ATMEL_CDC_ASF_EXAMPLE3_COM6 = "Communication Device Class ASF example3, COM6" +ATMEL_CDC_ASF_EXAMPLE3_COM7 = "Communication Device Class ASF example3, COM7" + +Serial.SvcDesc = "USB Serial emulation driver" + diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/.DS_Store b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/.DS_Store new file mode 100755 index 0000000..5008ddf Binary files /dev/null and b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/.DS_Store differ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/boards/board.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/boards/board.h new file mode 100755 index 0000000..729d94c --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/boards/board.h @@ -0,0 +1,383 @@ +/** + * \file + * + * \brief Standard board header file. + * + * This file includes the appropriate board header file according to the + * defined board (parameter BOARD). + * + * Copyright (c) 2009-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _BOARD_H_ +#define _BOARD_H_ + +/** + * \defgroup group_common_boards Generic board support + * + * The generic board support module includes board-specific definitions + * and function prototypes, such as the board initialization function. + * + * \{ + */ + +#include "compiler.h" + +#ifdef __cplusplus +extern "C" { +#endif + + +/*! \name Base Boards + */ +//! @{ +#define EVK1100 1 //!< AT32UC3A EVK1100 board. +#define EVK1101 2 //!< AT32UC3B EVK1101 board. +#define UC3C_EK 3 //!< AT32UC3C UC3C-EK board. +#define EVK1104 4 //!< AT32UC3A3 EVK1104 board. +#define EVK1105 5 //!< AT32UC3A EVK1105 board. +#define STK600_RCUC3L0 6 //!< STK600 RCUC3L0 board. +#define UC3L_EK 7 //!< AT32UC3L-EK board. +#define XPLAIN 8 //!< ATxmega128A1 Xplain board. +#define STK600_RC064X 10 //!< ATxmega256A3 STK600 board. +#define STK600_RC100X 11 //!< ATxmega128A1 STK600 board. +#define UC3_A3_XPLAINED 13 //!< ATUC3A3 UC3-A3 Xplained board. +#define UC3_L0_XPLAINED 15 //!< ATUC3L0 UC3-L0 Xplained board. +#define STK600_RCUC3D 16 //!< STK600 RCUC3D board. +#define STK600_RCUC3C0 17 //!< STK600 RCUC3C board. +#define XMEGA_B1_XPLAINED 18 //!< ATxmega128B1 Xplained board. +#define XMEGA_A1_XPLAINED 19 //!< ATxmega128A1 Xplain-A1 board. +#define XMEGA_A1U_XPLAINED_PRO 20 //!< ATxmega128A1U XMEGA-A1U Xplained Pro board. +#define STK600_RCUC3L4 21 //!< ATUCL4 STK600 board +#define UC3_L0_XPLAINED_BC 22 //!< ATUC3L0 UC3-L0 Xplained board controller board +#define MEGA1284P_XPLAINED_BC 23 //!< ATmega1284P-Xplained board controller board +#define STK600_RC044X 24 //!< STK600 with RC044X routing card board. +#define STK600_RCUC3B0 25 //!< STK600 RCUC3B0 board. +#define UC3_L0_QT600 26 //!< QT600 UC3L0 MCU board. +#define XMEGA_A3BU_XPLAINED 27 //!< ATxmega256A3BU Xplained board. +#define STK600_RC064X_LCDX 28 //!< XMEGAB3 STK600 RC064X LCDX board. +#define STK600_RC100X_LCDX 29 //!< XMEGAB1 STK600 RC100X LCDX board. +#define UC3B_BOARD_CONTROLLER 30 //!< AT32UC3B1 board controller for Atmel boards +#define RZ600 31 //!< AT32UC3A RZ600 MCU board +#define SAM3S_EK 32 //!< SAM3S-EK board. +#define SAM3U_EK 33 //!< SAM3U-EK board. +#define SAM3X_EK 34 //!< SAM3X-EK board. +#define SAM3N_EK 35 //!< SAM3N-EK board. +#define SAM3S_EK2 36 //!< SAM3S-EK2 board. +#define SAM4S_EK 37 //!< SAM4S-EK board. +#define STK600_RCUC3A0 38 //!< STK600 RCUC3A0 board. +#define STK600_MEGA 39 //!< STK600 MEGA board. +#define MEGA_1284P_XPLAINED 40 //!< ATmega1284P Xplained board. +#define SAM4S_XPLAINED 41 //!< SAM4S Xplained board. +#define ATXMEGA128A1_QT600 42 //!< QT600 ATXMEGA128A1 MCU board. +#define ARDUINO_DUE_X 43 //!< Arduino Due/X board. +#define STK600_RCUC3L3 44 //!< ATUCL3 STK600 board +#define SAM4L_EK 45 //!< SAM4L-EK board. +#define STK600_MEGA_RF 46 //!< STK600 MEGA RF EVK board. +#define XMEGA_C3_XPLAINED 47 //!< ATxmega384C3 Xplained board. +#define STK600_RC032X 48 //!< STK600 with RC032X routing card board. +#define SAM4S_EK2 49 //!< SAM4S-EK2 board. +#define XMEGA_E5_XPLAINED 50 //!< ATxmega32E5 Xplained board. +#define SAM4E_EK 51 //!< SAM4E-EK board. +#define ATMEGA256RFR2_XPLAINED_PRO 52 //!< ATmega256RFR2 Xplained Pro board. +#define SAM4S_XPLAINED_PRO 53 //!< SAM4S Xplained Pro board. +#define SAM4L_XPLAINED_PRO 54 //!< SAM4L Xplained Pro board. +#define ATMEGA256RFR2_ZIGBIT 55 //!< ATmega256RFR2 zigbit +#define XMEGA_RF233_ZIGBIT 56 //!< ATxmega256A3U with AT86RF233 Zigbit +#define XMEGA_RF212B_ZIGBIT 57 //!< ATxmega256A3U with AT86RF212B Zigbit +#define SAM4S_WPIR_RD 58 //!< SAM4S-WPIR-RD board. +#define SAMD20_XPLAINED_PRO 59 //!< SAM D20 Xplained Pro board +#define SAM4L8_XPLAINED_PRO 60 //!< SAM4L8 Xplained Pro board. +#define SAM4N_XPLAINED_PRO 61 //!< SAM4N Xplained Pro board. +#define XMEGA_A3_REB_CBB 62 //!< XMEGA REB Controller Base board. +#define ATMEGARFX_RCB 63 //!< RFR2 & RFA1 RCB +#define SAM4C_EK 64 //!< SAM4C-EK board. +#define RCB256RFR2_XPRO 65 //!< RFR2 RCB Xplained Pro board. +#define SAMG53_XPLAINED_PRO 66 //!< SAMG53 Xplained Pro board. +#define SAM4CP16BMB 67 //!< SAM4CP16BMB board. +#define SAM4E_XPLAINED_PRO 68 //!< SAM4E Xplained Pro board. +#define SAMD21_XPLAINED_PRO 69 //!< SAM D21 Xplained Pro board. +#define SAMR21_XPLAINED_PRO 70 //!< SAM R21 Xplained Pro board. +#define SAM4CMP_DB 71 //!< SAM4CMP demo board. +#define SAM4CMS_DB 72 //!< SAM4CMS demo board. +#define ATPL230AMB 73 //!< ATPL230AMB board. +#define SAMD11_XPLAINED_PRO 74 //!< SAM D11 Xplained Pro board. +#define SIMULATOR_XMEGA_A1 97 //!< Simulator for XMEGA A1 devices +#define AVR_SIMULATOR_UC3 98 //!< Simulator for the AVR UC3 device family. +#define USER_BOARD 99 //!< User-reserved board (if any). +#define DUMMY_BOARD 100 //!< Dummy board to support board-independent applications (e.g. bootloader) +//! @} + +/*! \name Extension Boards + */ +//! @{ +#define EXT1102 1 //!< AT32UC3B EXT1102 board +#define MC300 2 //!< AT32UC3 MC300 board +#define SENSORS_XPLAINED_INERTIAL_1 3 //!< Xplained inertial sensor board 1 +#define SENSORS_XPLAINED_INERTIAL_2 4 //!< Xplained inertial sensor board 2 +#define SENSORS_XPLAINED_PRESSURE_1 5 //!< Xplained pressure sensor board +#define SENSORS_XPLAINED_LIGHTPROX_1 6 //!< Xplained light & proximity sensor board +#define SENSORS_XPLAINED_INERTIAL_A1 7 //!< Xplained inertial sensor board "A" +#define RZ600_AT86RF231 8 //!< AT86RF231 RF board in RZ600 +#define RZ600_AT86RF230B 9 //!< AT86RF230B RF board in RZ600 +#define RZ600_AT86RF212 10 //!< AT86RF212 RF board in RZ600 +#define SENSORS_XPLAINED_BREADBOARD 11 //!< Xplained sensor development breadboard +#define SECURITY_XPLAINED 12 //!< Xplained ATSHA204 board +#define USER_EXT_BOARD 99 //!< User-reserved extension board (if any). +//! @} + +#if BOARD == EVK1100 +# include "evk1100/evk1100.h" +#elif BOARD == EVK1101 +# include "evk1101/evk1101.h" +#elif BOARD == UC3C_EK +# include "uc3c_ek/uc3c_ek.h" +#elif BOARD == EVK1104 +# include "evk1104/evk1104.h" +#elif BOARD == EVK1105 +# include "evk1105/evk1105.h" +#elif BOARD == STK600_RCUC3L0 +# include "stk600/rcuc3l0/stk600_rcuc3l0.h" +#elif BOARD == UC3L_EK +# include "uc3l_ek/uc3l_ek.h" +#elif BOARD == STK600_RCUC3L4 +# include "stk600/rcuc3l4/stk600_rcuc3l4.h" +#elif BOARD == XPLAIN +# include "xplain/xplain.h" +#elif BOARD == STK600_MEGA + /*No header-file to include*/ +#elif BOARD == STK600_MEGA_RF +# include "stk600.h" +#elif BOARD == ATMEGA256RFR2_XPLAINED_PRO +# include "atmega256rfr2_xplained_pro/atmega256rfr2_xplained_pro.h" +#elif BOARD == ATMEGA256RFR2_ZIGBIT +# include "atmega256rfr2_zigbit/atmega256rfr2_zigbit.h" +#elif BOARD == STK600_RC032X +# include "stk600/rc032x/stk600_rc032x.h" +#elif BOARD == STK600_RC044X +# include "stk600/rc044x/stk600_rc044x.h" +#elif BOARD == STK600_RC064X +# include "stk600/rc064x/stk600_rc064x.h" +#elif BOARD == STK600_RC100X +# include "stk600/rc100x/stk600_rc100x.h" +#elif BOARD == UC3_A3_XPLAINED +# include "uc3_a3_xplained/uc3_a3_xplained.h" +#elif BOARD == UC3_L0_XPLAINED +# include "uc3_l0_xplained/uc3_l0_xplained.h" +#elif BOARD == STK600_RCUC3B0 +# include "stk600/rcuc3b0/stk600_rcuc3b0.h" +#elif BOARD == STK600_RCUC3D +# include "stk600/rcuc3d/stk600_rcuc3d.h" +#elif BOARD == STK600_RCUC3C0 +# include "stk600/rcuc3c0/stk600_rcuc3c0.h" +#elif BOARD == SAMG53_XPLAINED_PRO +# include "samg53_xplained_pro/samg53_xplained_pro.h" +#elif BOARD == XMEGA_B1_XPLAINED +# include "xmega_b1_xplained/xmega_b1_xplained.h" +#elif BOARD == STK600_RC064X_LCDX +# include "stk600/rc064x_lcdx/stk600_rc064x_lcdx.h" +#elif BOARD == STK600_RC100X_LCDX +# include "stk600/rc100x_lcdx/stk600_rc100x_lcdx.h" +#elif BOARD == XMEGA_A1_XPLAINED +# include "xmega_a1_xplained/xmega_a1_xplained.h" +#elif BOARD == XMEGA_A1U_XPLAINED_PRO +# include "xmega_a1u_xplained_pro/xmega_a1u_xplained_pro.h" +#elif BOARD == UC3_L0_XPLAINED_BC +# include "uc3_l0_xplained_bc/uc3_l0_xplained_bc.h" +#elif BOARD == SAM3S_EK +# include "sam3s_ek/sam3s_ek.h" +# include "system_sam3s.h" +#elif BOARD == SAM3S_EK2 +# include "sam3s_ek2/sam3s_ek2.h" +# include "system_sam3sd8.h" +#elif BOARD == SAM3U_EK +# include "sam3u_ek/sam3u_ek.h" +# include "system_sam3u.h" +#elif BOARD == SAM3X_EK +# include "sam3x_ek/sam3x_ek.h" +# include "system_sam3x.h" +#elif BOARD == SAM3N_EK +# include "sam3n_ek/sam3n_ek.h" +# include "system_sam3n.h" +#elif BOARD == SAM4S_EK +# include "sam4s_ek/sam4s_ek.h" +# include "system_sam4s.h" +#elif BOARD == SAM4S_WPIR_RD +# include "sam4s_wpir_rd/sam4s_wpir_rd.h" +# include "system_sam4s.h" +#elif BOARD == SAM4S_XPLAINED +# include "sam4s_xplained/sam4s_xplained.h" +# include "system_sam4s.h" +#elif BOARD == SAM4S_EK2 +# include "sam4s_ek2/sam4s_ek2.h" +# include "system_sam4s.h" +#elif BOARD == MEGA_1284P_XPLAINED + /*No header-file to include*/ +#elif BOARD == ARDUINO_DUE_X +# include "arduino_due_x/arduino_due_x.h" +# include "system_sam3x.h" +#elif BOARD == SAM4L_EK +# include "sam4l_ek/sam4l_ek.h" +#elif BOARD == SAM4E_EK +# include "sam4e_ek/sam4e_ek.h" +#elif BOARD == SAMD20_XPLAINED_PRO +# include "samd20_xplained_pro/samd20_xplained_pro.h" +#elif BOARD == SAMD21_XPLAINED_PRO +# include "samd21_xplained_pro/samd21_xplained_pro.h" +#elif BOARD == SAMR21_XPLAINED_PRO +# include "samr21_xplained_pro/samr21_xplained_pro.h" +#elif BOARD == SAMD11_XPLAINED_PRO +# include "samd11_xplained_pro/samd11_xplained_pro.h" +#elif BOARD == SAM4N_XPLAINED_PRO +# include "sam4n_xplained_pro/sam4n_xplained_pro.h" +#elif BOARD == MEGA1284P_XPLAINED_BC +# include "mega1284p_xplained_bc/mega1284p_xplained_bc.h" +#elif BOARD == UC3_L0_QT600 +# include "uc3_l0_qt600/uc3_l0_qt600.h" +#elif BOARD == XMEGA_A3BU_XPLAINED +# include "xmega_a3bu_xplained/xmega_a3bu_xplained.h" +#elif BOARD == XMEGA_E5_XPLAINED +# include "xmega_e5_xplained/xmega_e5_xplained.h" +#elif BOARD == UC3B_BOARD_CONTROLLER +# include "uc3b_board_controller/uc3b_board_controller.h" +#elif BOARD == RZ600 +# include "rz600/rz600.h" +#elif BOARD == STK600_RCUC3A0 +# include "stk600/rcuc3a0/stk600_rcuc3a0.h" +#elif BOARD == ATXMEGA128A1_QT600 +# include "atxmega128a1_qt600/atxmega128a1_qt600.h" +#elif BOARD == STK600_RCUC3L3 +# include "stk600/rcuc3l3/stk600_rcuc3l3.h" +#elif BOARD == SAM4S_XPLAINED_PRO +# include "sam4s_xplained_pro/sam4s_xplained_pro.h" +#elif BOARD == SAM4L_XPLAINED_PRO +# include "sam4l_xplained_pro/sam4l_xplained_pro.h" +#elif BOARD == SAM4L8_XPLAINED_PRO +# include "sam4l8_xplained_pro/sam4l8_xplained_pro.h" +#elif BOARD == SAM4C_EK +# include "sam4c_ek/sam4c_ek.h" +#elif BOARD == SAM4CMP_DB +# include "sam4cmp_db/sam4cmp_db.h" +#elif BOARD == SAM4CMS_DB +# include "sam4cms_db/sam4cms_db.h" +#elif BOARD == SAM4CP16BMB +# include "sam4cp16bmb/sam4cp16bmb.h" +#elif BOARD == ATPL230AMB +# include "atpl230amb/atpl230amb.h" +#elif BOARD == SIMULATOR_XMEGA_A1 +# include "simulator/xmega_a1/simulator_xmega_a1.h" +#elif BOARD == XMEGA_C3_XPLAINED +# include "xmega_c3_xplained/xmega_c3_xplained.h" +#elif BOARD == XMEGA_RF233_ZIGBIT +# include "xmega_rf233_zigbit/xmega_rf233_zigbit.h" +#elif BOARD == XMEGA_A3_REB_CBB +# include "xmega_a3_reb_cbb/xmega_a3_reb_cbb.h" +#elif BOARD == ATMEGARFX_RCB +# include "atmegarfx_rcb/atmegarfx_rcb.h" +#elif BOARD == RCB256RFR2_XPRO +# include "atmega256rfr2_rcb_xpro/atmega256rfr2_rcb_xpro.h" +#elif BOARD == XMEGA_RF212B_ZIGBIT +# include "xmega_rf212b_zigbit/xmega_rf212b_zigbit.h" +#elif BOARD == SAM4E_XPLAINED_PRO +# include "sam4e_xplained_pro/sam4e_xplained_pro.h" +#elif BOARD == AVR_SIMULATOR_UC3 +# include "avr_simulator_uc3/avr_simulator_uc3.h" +#elif BOARD == USER_BOARD + // User-reserved area: #include the header file of your board here (if any). +# include "user_board.h" +#elif BOARD == DUMMY_BOARD +# include "dummy/dummy_board.h" +#else +# error No known Atmel board defined +#endif + +#if (defined EXT_BOARD) +# if EXT_BOARD == MC300 +# include "mc300/mc300.h" +# elif (EXT_BOARD == SENSORS_XPLAINED_INERTIAL_1) || \ + (EXT_BOARD == SENSORS_XPLAINED_INERTIAL_2) || \ + (EXT_BOARD == SENSORS_XPLAINED_INERTIAL_A1) || \ + (EXT_BOARD == SENSORS_XPLAINED_PRESSURE_1) || \ + (EXT_BOARD == SENSORS_XPLAINED_LIGHTPROX_1) || \ + (EXT_BOARD == SENSORS_XPLAINED_BREADBOARD) +# include "sensors_xplained/sensors_xplained.h" +# elif EXT_BOARD == RZ600_AT86RF231 +# include "at86rf231/at86rf231.h" +# elif EXT_BOARD == RZ600_AT86RF230B +# include "at86rf230b/at86rf230b.h" +# elif EXT_BOARD == RZ600_AT86RF212 +# include "at86rf212/at86rf212.h" +# elif EXT_BOARD == SECURITY_XPLAINED +# include "security_xplained.h" +# elif EXT_BOARD == USER_EXT_BOARD + // User-reserved area: #include the header file of your extension board here + // (if any). +# endif +#endif + + +#if (defined(__GNUC__) && defined(__AVR32__)) || (defined(__ICCAVR32__) || defined(__AAVR32__)) +#ifdef __AVR32_ABI_COMPILER__ // Automatically defined when compiling for AVR32, not when assembling. + +/*! \brief This function initializes the board target resources + * + * This function should be called to ensure proper initialization of the target + * board hardware connected to the part. + */ +extern void board_init(void); + +#endif // #ifdef __AVR32_ABI_COMPILER__ +#else +/*! \brief This function initializes the board target resources + * + * This function should be called to ensure proper initialization of the target + * board hardware connected to the part. + */ +extern void board_init(void); +#endif + + +#ifdef __cplusplus +} +#endif + +/** + * \} + */ + +#endif // _BOARD_H_ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/sleepmgr/samd/sleepmgr.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/sleepmgr/samd/sleepmgr.c new file mode 100755 index 0000000..2ad360c --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/sleepmgr/samd/sleepmgr.c @@ -0,0 +1,50 @@ +/** + * \file + * + * \brief Chip-specific sleep manager configuration + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include +#include + +#if defined(CONFIG_SLEEPMGR_ENABLE) || defined(__DOXYGEN__) + +uint8_t sleepmgr_locks[SLEEPMGR_NR_OF_MODES]; + +#endif /* CONFIG_SLEEPMGR_ENABLE */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/sleepmgr/samd/sleepmgr.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/sleepmgr/samd/sleepmgr.h new file mode 100755 index 0000000..261e1da --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/sleepmgr/samd/sleepmgr.h @@ -0,0 +1,125 @@ +/** + * \file + * + * \brief Chip-specific sleep manager configuration + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef SAM_SLEEPMGR_INCLUDED +#define SAM_SLEEPMGR_INCLUDED + +#ifdef __cplusplus +extern "C" { +#endif + +#include +#include +#include +#include "system.h" + +/** + * \weakgroup sleepmgr_group + * @{ + */ + +enum sleepmgr_mode { + /** Active mode. */ + SLEEPMGR_ACTIVE = 0, + + /** + * Idle 0 mode. + * Potential Wake Up sources: Synchronous(APB, AHB), asynchronous. + */ + SLEEPMGR_IDLE_0, + + /** + * Idle 1 mode. + * Potential Wake Up sources: Synchronous (APB), asynchronous + */ + SLEEPMGR_IDLE_1, + + /** + * Idle 2 mode. + * Potential Wake Up sources: Asynchronous + */ + SLEEPMGR_IDLE_2, + + /** + * Standby mode. + * Potential Wake Up sources: Asynchronous + */ + SLEEPMGR_STANDBY, + + SLEEPMGR_NR_OF_MODES, +}; + +/** + * \internal + * \name Internal arrays + * @{ + */ +#if defined(CONFIG_SLEEPMGR_ENABLE) || defined(__DOXYGEN__) +/** Sleep mode lock counters */ +extern uint8_t sleepmgr_locks[]; +#endif /* CONFIG_SLEEPMGR_ENABLE */ +/** @} */ + +static inline void sleepmgr_sleep(const enum sleepmgr_mode sleep_mode) +{ + Assert(sleep_mode != SLEEPMGR_ACTIVE); +#ifdef CONFIG_SLEEPMGR_ENABLE + cpu_irq_disable(); + + /* Enter the sleep mode. */ + system_set_sleepmode((enum system_sleepmode)(sleep_mode - 1)); + cpu_irq_enable(); + system_sleep(); +#else + UNUSED(sleep_mode); + cpu_irq_enable(); +#endif /* CONFIG_SLEEPMGR_ENABLE */ +} + +/** @} */ + +#ifdef __cplusplus +} +#endif + +#endif /* SAM_SLEEPMGR_INCLUDED */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/sleepmgr/sleepmgr.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/sleepmgr/sleepmgr.h new file mode 100755 index 0000000..2d64817 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/sleepmgr/sleepmgr.h @@ -0,0 +1,256 @@ +/** + * \file + * + * \brief Sleep manager + * + * Copyright (c) 2010 - 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef SLEEPMGR_H +#define SLEEPMGR_H + +#include +#include + +#if (SAM3S || SAM3U || SAM3N || SAM3XA || SAM4S || SAM4E || SAM4N || SAM4C || SAMG || SAM4CP || SAM4CM) +# include "sam/sleepmgr.h" +#elif XMEGA +# include "xmega/sleepmgr.h" +#elif UC3 +# include "uc3/sleepmgr.h" +#elif SAM4L +# include "sam4l/sleepmgr.h" +#elif MEGA +# include "mega/sleepmgr.h" +#elif (SAMD20 || SAMD21 || SAMR21 || SAMD11) +# include "samd/sleepmgr.h" +#else +# error Unsupported device. +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \defgroup sleepmgr_group Sleep manager + * + * The sleep manager is a service for ensuring that the device is not put to + * sleep in deeper sleep modes than the system (e.g., peripheral drivers, + * services or the application) allows at any given time. + * + * It is based on the use of lock counting for the individual sleep modes, and + * will put the device to sleep in the shallowest sleep mode that has a non-zero + * lock count. The drivers/services/application can change these counts by use + * of \ref sleepmgr_lock_mode and \ref sleepmgr_unlock_mode. + * Refer to \ref sleepmgr_mode for a list of the sleep modes available for + * locking, and the device datasheet for information on their effect. + * + * The application must supply the file \ref conf_sleepmgr.h. + * + * For the sleep manager to be enabled, the symbol \ref CONFIG_SLEEPMGR_ENABLE + * must be defined, e.g., in \ref conf_sleepmgr.h. If this symbol is not + * defined, the functions are replaced with dummy functions and no RAM is used. + * + * @{ + */ + +/** + * \def CONFIG_SLEEPMGR_ENABLE + * \brief Configuration symbol for enabling the sleep manager + * + * If this symbol is not defined, the functions of this service are replaced + * with dummy functions. This is useful for reducing code size and execution + * time if the sleep manager is not needed in the application. + * + * This symbol may be defined in \ref conf_sleepmgr.h. + */ +#if defined(__DOXYGEN__) && !defined(CONFIG_SLEEPMGR_ENABLE) +# define CONFIG_SLEEPMGR_ENABLE +#endif + +/** + * \enum sleepmgr_mode + * \brief Sleep mode locks + * + * Identifiers for the different sleep mode locks. + */ + +/** + * \brief Initialize the lock counts + * + * Sets all lock counts to 0, except the very last one, which is set to 1. This + * is done to simplify the algorithm for finding the deepest allowable sleep + * mode in \ref sleepmgr_enter_sleep. + */ +static inline void sleepmgr_init(void) +{ +#ifdef CONFIG_SLEEPMGR_ENABLE + uint8_t i; + + for (i = 0; i < SLEEPMGR_NR_OF_MODES - 1; i++) { + sleepmgr_locks[i] = 0; + } + sleepmgr_locks[SLEEPMGR_NR_OF_MODES - 1] = 1; +#endif /* CONFIG_SLEEPMGR_ENABLE */ +} + +/** + * \brief Increase lock count for a sleep mode + * + * Increases the lock count for \a mode to ensure that the sleep manager does + * not put the device to sleep in the deeper sleep modes. + * + * \param mode Sleep mode to lock. + */ +static inline void sleepmgr_lock_mode(enum sleepmgr_mode mode) +{ +#ifdef CONFIG_SLEEPMGR_ENABLE + irqflags_t flags; + + Assert(sleepmgr_locks[mode] < 0xff); + + // Enter a critical section + flags = cpu_irq_save(); + + ++sleepmgr_locks[mode]; + + // Leave the critical section + cpu_irq_restore(flags); +#else + UNUSED(mode); +#endif /* CONFIG_SLEEPMGR_ENABLE */ +} + +/** + * \brief Decrease lock count for a sleep mode + * + * Decreases the lock count for \a mode. If the lock count reaches 0, the sleep + * manager can put the device to sleep in the deeper sleep modes. + * + * \param mode Sleep mode to unlock. + */ +static inline void sleepmgr_unlock_mode(enum sleepmgr_mode mode) +{ +#ifdef CONFIG_SLEEPMGR_ENABLE + irqflags_t flags; + + Assert(sleepmgr_locks[mode]); + + // Enter a critical section + flags = cpu_irq_save(); + + --sleepmgr_locks[mode]; + + // Leave the critical section + cpu_irq_restore(flags); +#else + UNUSED(mode); +#endif /* CONFIG_SLEEPMGR_ENABLE */ +} + + /** + * \brief Retrieves the deepest allowable sleep mode + * + * Searches through the sleep mode lock counts, starting at the shallowest sleep + * mode, until the first non-zero lock count is found. The deepest allowable + * sleep mode is then returned. + */ +static inline enum sleepmgr_mode sleepmgr_get_sleep_mode(void) +{ + enum sleepmgr_mode sleep_mode = SLEEPMGR_ACTIVE; + +#ifdef CONFIG_SLEEPMGR_ENABLE + uint8_t *lock_ptr = sleepmgr_locks; + + // Find first non-zero lock count, starting with the shallowest modes. + while (!(*lock_ptr)) { + lock_ptr++; + sleep_mode = (enum sleepmgr_mode)(sleep_mode + 1); + } + + // Catch the case where one too many sleepmgr_unlock_mode() call has been + // performed on the deepest sleep mode. + Assert((uintptr_t)(lock_ptr - sleepmgr_locks) < SLEEPMGR_NR_OF_MODES); + +#endif /* CONFIG_SLEEPMGR_ENABLE */ + + return sleep_mode; +} + +/** + * \fn sleepmgr_enter_sleep + * \brief Go to sleep in the deepest allowed mode + * + * Searches through the sleep mode lock counts, starting at the shallowest sleep + * mode, until the first non-zero lock count is found. The device is then put to + * sleep in the sleep mode that corresponds to the lock. + * + * \note This function enables interrupts before going to sleep, and will leave + * them enabled upon return. This also applies if sleep is skipped due to ACTIVE + * mode being locked. + */ + +static inline void sleepmgr_enter_sleep(void) +{ +#ifdef CONFIG_SLEEPMGR_ENABLE + enum sleepmgr_mode sleep_mode; + + cpu_irq_disable(); + + // Find the deepest allowable sleep mode + sleep_mode = sleepmgr_get_sleep_mode(); + // Return right away if first mode (ACTIVE) is locked. + if (sleep_mode==SLEEPMGR_ACTIVE) { + cpu_irq_enable(); + return; + } + // Enter the deepest allowable sleep mode with interrupts enabled + sleepmgr_sleep(sleep_mode); +#else + cpu_irq_enable(); +#endif /* CONFIG_SLEEPMGR_ENABLE */ +} + + +//! @} + +#ifdef __cplusplus +} +#endif + +#endif /* SLEEPMGR_H */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/class/cdc/device/udi_cdc.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/class/cdc/device/udi_cdc.c new file mode 100755 index 0000000..27a1724 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/class/cdc/device/udi_cdc.c @@ -0,0 +1,1100 @@ +/** + * \file + * + * \brief USB Device Communication Device Class (CDC) interface. + * + * Copyright (c) 2009 - 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include "conf_usb.h" +#include "usb_protocol.h" +#include "usb_protocol_cdc.h" +#include "udd.h" +#include "udc.h" +#include "udi_cdc.h" +#include + +#ifdef UDI_CDC_LOW_RATE +# ifdef USB_DEVICE_HS_SUPPORT +# define UDI_CDC_TX_BUFFERS (UDI_CDC_DATA_EPS_HS_SIZE) +# define UDI_CDC_RX_BUFFERS (UDI_CDC_DATA_EPS_HS_SIZE) +# else +# define UDI_CDC_TX_BUFFERS (UDI_CDC_DATA_EPS_FS_SIZE) +# define UDI_CDC_RX_BUFFERS (UDI_CDC_DATA_EPS_FS_SIZE) +# endif +#else +# ifdef USB_DEVICE_HS_SUPPORT +# define UDI_CDC_TX_BUFFERS (UDI_CDC_DATA_EPS_HS_SIZE) +# define UDI_CDC_RX_BUFFERS (UDI_CDC_DATA_EPS_HS_SIZE) +# else +# define UDI_CDC_TX_BUFFERS (5*UDI_CDC_DATA_EPS_FS_SIZE) +# define UDI_CDC_RX_BUFFERS (5*UDI_CDC_DATA_EPS_FS_SIZE) +# endif +#endif + +#ifndef UDI_CDC_TX_EMPTY_NOTIFY +# define UDI_CDC_TX_EMPTY_NOTIFY(port) +#endif + +/** + * \ingroup udi_cdc_group + * \defgroup udi_cdc_group_udc Interface with USB Device Core (UDC) + * + * Structures and functions required by UDC. + * + * @{ + */ +bool udi_cdc_comm_enable(void); +void udi_cdc_comm_disable(void); +bool udi_cdc_comm_setup(void); +bool udi_cdc_data_enable(void); +void udi_cdc_data_disable(void); +bool udi_cdc_data_setup(void); +uint8_t udi_cdc_getsetting(void); +void udi_cdc_data_sof_notify(void); +UDC_DESC_STORAGE udi_api_t udi_api_cdc_comm = { + .enable = udi_cdc_comm_enable, + .disable = udi_cdc_comm_disable, + .setup = udi_cdc_comm_setup, + .getsetting = udi_cdc_getsetting, +}; +UDC_DESC_STORAGE udi_api_t udi_api_cdc_data = { + .enable = udi_cdc_data_enable, + .disable = udi_cdc_data_disable, + .setup = udi_cdc_data_setup, + .getsetting = udi_cdc_getsetting, + .sof_notify = udi_cdc_data_sof_notify, +}; +//@} + +/** + * \ingroup udi_cdc_group + * \defgroup udi_cdc_group_internal Implementation of UDI CDC + * + * Class internal implementation + * @{ + */ + +/** + * \name Internal routines + */ +//@{ + +/** + * \name Routines to control serial line + */ +//@{ + +/** + * \brief Returns the port number corresponding at current setup request + * + * \return port number + */ +static uint8_t udi_cdc_setup_to_port(void); + +/** + * \brief Sends line coding to application + * + * Called after SETUP request when line coding data is received. + */ +static void udi_cdc_line_coding_received(void); + +/** + * \brief Records new state + * + * \param port Communication port number to manage + * \param b_set State is enabled if true, else disabled + * \param bit_mask Field to process (see CDC_SERIAL_STATE_ defines) + */ +static void udi_cdc_ctrl_state_change(uint8_t port, bool b_set, le16_t bit_mask); + +/** + * \brief Check and eventually notify the USB host of new state + * + * \param port Communication port number to manage + * \param ep Port communication endpoint + */ +static void udi_cdc_ctrl_state_notify(uint8_t port, udd_ep_id_t ep); + +/** + * \brief Ack sent of serial state message + * Callback called after serial state message sent + * + * \param status UDD_EP_TRANSFER_OK, if transfer finished + * \param status UDD_EP_TRANSFER_ABORT, if transfer aborted + * \param n number of data transfered + */ +static void udi_cdc_serial_state_msg_sent(udd_ep_status_t status, iram_size_t n, udd_ep_id_t ep); + +//@} + +/** + * \name Routines to process data transfer + */ +//@{ + +/** + * \brief Enable the reception of data from the USB host + * + * The value udi_cdc_rx_trans_sel indicate the RX buffer to fill. + * + * \param port Communication port number to manage + * + * \return \c 1 if function was successfully done, otherwise \c 0. + */ +static bool udi_cdc_rx_start(uint8_t port); + +/** + * \brief Update rx buffer management with a new data + * Callback called after data reception on USB line + * + * \param status UDD_EP_TRANSFER_OK, if transfer finish + * \param status UDD_EP_TRANSFER_ABORT, if transfer aborted + * \param n number of data received + */ +static void udi_cdc_data_received(udd_ep_status_t status, iram_size_t n, udd_ep_id_t ep); + +/** + * \brief Ack sent of tx buffer + * Callback called after data transfer on USB line + * + * \param status UDD_EP_TRANSFER_OK, if transfer finished + * \param status UDD_EP_TRANSFER_ABORT, if transfer aborted + * \param n number of data transfered + */ +static void udi_cdc_data_sent(udd_ep_status_t status, iram_size_t n, udd_ep_id_t ep); + +/** + * \brief Send buffer on line or wait a SOF event + * + * \param port Communication port number to manage + */ +static void udi_cdc_tx_send(uint8_t port); + +//@} + +//@} + +/** + * \name Information about configuration of communication line + */ +//@{ +COMPILER_WORD_ALIGNED + static usb_cdc_line_coding_t udi_cdc_line_coding[UDI_CDC_PORT_NB]; +static bool udi_cdc_serial_state_msg_ongoing[UDI_CDC_PORT_NB]; +static volatile le16_t udi_cdc_state[UDI_CDC_PORT_NB]; +COMPILER_WORD_ALIGNED static usb_cdc_notify_serial_state_t uid_cdc_state_msg[UDI_CDC_PORT_NB]; + +//! Status of CDC COMM interfaces +static volatile uint8_t udi_cdc_nb_comm_enabled = 0; +//@} + +/** + * \name Variables to manage RX/TX transfer requests + * Two buffers for each sense are used to optimize the speed. + */ +//@{ + +//! Status of CDC DATA interfaces +static volatile uint8_t udi_cdc_nb_data_enabled = 0; +static volatile bool udi_cdc_data_running = false; +//! Buffer to receive data +COMPILER_WORD_ALIGNED static uint8_t udi_cdc_rx_buf[UDI_CDC_PORT_NB][2][UDI_CDC_RX_BUFFERS]; +//! Data available in RX buffers +static uint16_t udi_cdc_rx_buf_nb[UDI_CDC_PORT_NB][2]; +//! Give the current RX buffer used (rx0 if 0, rx1 if 1) +static volatile uint8_t udi_cdc_rx_buf_sel[UDI_CDC_PORT_NB]; +//! Read position in current RX buffer +static volatile uint16_t udi_cdc_rx_pos[UDI_CDC_PORT_NB]; +//! Signal a transfer on-going +static volatile bool udi_cdc_rx_trans_ongoing[UDI_CDC_PORT_NB]; + +//! Define a transfer halted +#define UDI_CDC_TRANS_HALTED 2 + +//! Buffer to send data +COMPILER_WORD_ALIGNED static uint8_t udi_cdc_tx_buf[UDI_CDC_PORT_NB][2][UDI_CDC_TX_BUFFERS]; +//! Data available in TX buffers +static uint16_t udi_cdc_tx_buf_nb[UDI_CDC_PORT_NB][2]; +//! Give current TX buffer used (tx0 if 0, tx1 if 1) +static volatile uint8_t udi_cdc_tx_buf_sel[UDI_CDC_PORT_NB]; +//! Value of SOF during last TX transfer +static uint16_t udi_cdc_tx_sof_num[UDI_CDC_PORT_NB]; +//! Signal a transfer on-going +static volatile bool udi_cdc_tx_trans_ongoing[UDI_CDC_PORT_NB]; +//! Signal that both buffer content data to send +static volatile bool udi_cdc_tx_both_buf_to_send[UDI_CDC_PORT_NB]; + +//@} + +bool udi_cdc_comm_enable(void) +{ + uint8_t port; + uint8_t iface_comm_num; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; + udi_cdc_nb_comm_enabled = 0; +#else + if (udi_cdc_nb_comm_enabled > UDI_CDC_PORT_NB) { + udi_cdc_nb_comm_enabled = 0; + } + port = udi_cdc_nb_comm_enabled; +#endif + + // Initialize control signal management + udi_cdc_state[port] = CPU_TO_LE16(0); + + uid_cdc_state_msg[port].header.bmRequestType = + USB_REQ_DIR_IN | USB_REQ_TYPE_CLASS | + USB_REQ_RECIP_INTERFACE; + uid_cdc_state_msg[port].header.bNotification = USB_REQ_CDC_NOTIFY_SERIAL_STATE; + uid_cdc_state_msg[port].header.wValue = LE16(0); + + switch (port) { +#define UDI_CDC_PORT_TO_IFACE_COMM(index, unused) \ + case index: \ + iface_comm_num = UDI_CDC_COMM_IFACE_NUMBER_##index; \ + break; + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_PORT_TO_IFACE_COMM, ~) +#undef UDI_CDC_PORT_TO_IFACE_COMM + default: + iface_comm_num = UDI_CDC_COMM_IFACE_NUMBER_0; + break; + } + + uid_cdc_state_msg[port].header.wIndex = LE16(iface_comm_num); + uid_cdc_state_msg[port].header.wLength = LE16(2); + uid_cdc_state_msg[port].value = CPU_TO_LE16(0); + + udi_cdc_line_coding[port].dwDTERate = CPU_TO_LE32(UDI_CDC_DEFAULT_RATE); + udi_cdc_line_coding[port].bCharFormat = UDI_CDC_DEFAULT_STOPBITS; + udi_cdc_line_coding[port].bParityType = UDI_CDC_DEFAULT_PARITY; + udi_cdc_line_coding[port].bDataBits = UDI_CDC_DEFAULT_DATABITS; + // Call application callback + // to initialize memories or indicate that interface is enabled + UDI_CDC_SET_CODING_EXT(port,(&udi_cdc_line_coding[port])); + if (!UDI_CDC_ENABLE_EXT(port)) { + return false; + } + udi_cdc_nb_comm_enabled++; + return true; +} + +bool udi_cdc_data_enable(void) +{ + uint8_t port; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; + udi_cdc_nb_data_enabled = 0; +#else + if (udi_cdc_nb_data_enabled > UDI_CDC_PORT_NB) { + udi_cdc_nb_data_enabled = 0; + } + port = udi_cdc_nb_data_enabled; +#endif + + // Initialize TX management + udi_cdc_tx_trans_ongoing[port] = false; + udi_cdc_tx_both_buf_to_send[port] = false; + udi_cdc_tx_buf_sel[port] = 0; + udi_cdc_tx_buf_nb[port][0] = 0; + udi_cdc_tx_buf_nb[port][1] = 0; + udi_cdc_tx_sof_num[port] = 0; + udi_cdc_tx_send(port); + + // Initialize RX management + udi_cdc_rx_trans_ongoing[port] = false; + udi_cdc_rx_buf_sel[port] = 0; + udi_cdc_rx_buf_nb[port][0] = 0; + udi_cdc_rx_pos[port] = 0; + if (!udi_cdc_rx_start(port)) { + return false; + } + udi_cdc_nb_data_enabled++; + if (udi_cdc_nb_data_enabled == UDI_CDC_PORT_NB) { + udi_cdc_data_running = true; + } + return true; +} + +void udi_cdc_comm_disable(void) +{ + Assert(udi_cdc_nb_comm_enabled != 0); + udi_cdc_nb_comm_enabled--; +} + +void udi_cdc_data_disable(void) +{ + uint8_t port; + UNUSED(port); + + Assert(udi_cdc_nb_data_enabled != 0); + udi_cdc_nb_data_enabled--; + port = udi_cdc_nb_data_enabled; + UDI_CDC_DISABLE_EXT(port); + udi_cdc_data_running = false; +} + +bool udi_cdc_comm_setup(void) +{ + uint8_t port = udi_cdc_setup_to_port(); + + if (Udd_setup_is_in()) { + // GET Interface Requests + if (Udd_setup_type() == USB_REQ_TYPE_CLASS) { + // Requests Class Interface Get + switch (udd_g_ctrlreq.req.bRequest) { + case USB_REQ_CDC_GET_LINE_CODING: + // Get configuration of CDC line + if (sizeof(usb_cdc_line_coding_t) != + udd_g_ctrlreq.req.wLength) + return false; // Error for USB host + udd_g_ctrlreq.payload = + (uint8_t *) & + udi_cdc_line_coding[port]; + udd_g_ctrlreq.payload_size = + sizeof(usb_cdc_line_coding_t); + return true; + } + } + } + if (Udd_setup_is_out()) { + // SET Interface Requests + if (Udd_setup_type() == USB_REQ_TYPE_CLASS) { + // Requests Class Interface Set + switch (udd_g_ctrlreq.req.bRequest) { + case USB_REQ_CDC_SET_LINE_CODING: + // Change configuration of CDC line + if (sizeof(usb_cdc_line_coding_t) != + udd_g_ctrlreq.req.wLength) + return false; // Error for USB host + udd_g_ctrlreq.callback = + udi_cdc_line_coding_received; + udd_g_ctrlreq.payload = + (uint8_t *) & + udi_cdc_line_coding[port]; + udd_g_ctrlreq.payload_size = + sizeof(usb_cdc_line_coding_t); + return true; + case USB_REQ_CDC_SET_CONTROL_LINE_STATE: + // According cdc spec 1.1 chapter 6.2.14 + UDI_CDC_SET_DTR_EXT(port, (0 != + (udd_g_ctrlreq.req.wValue + & CDC_CTRL_SIGNAL_DTE_PRESENT))); + UDI_CDC_SET_RTS_EXT(port, (0 != + (udd_g_ctrlreq.req.wValue + & CDC_CTRL_SIGNAL_ACTIVATE_CARRIER))); + return true; + } + } + } + return false; // request Not supported +} + +bool udi_cdc_data_setup(void) +{ + return false; // request Not supported +} + +uint8_t udi_cdc_getsetting(void) +{ + return 0; // CDC don't have multiple alternate setting +} + +void udi_cdc_data_sof_notify(void) +{ + static uint8_t port_notify = 0; + + // A call of udi_cdc_data_sof_notify() is done for each port + udi_cdc_tx_send(port_notify); +#if UDI_CDC_PORT_NB != 1 // To optimize code + port_notify++; + if (port_notify >= UDI_CDC_PORT_NB) { + port_notify = 0; + } +#endif +} + + +//------------------------------------------------- +//------- Internal routines to control serial line + +static uint8_t udi_cdc_setup_to_port(void) +{ + uint8_t port; + + switch (udd_g_ctrlreq.req.wIndex & 0xFF) { +#define UDI_CDC_IFACE_COMM_TO_PORT(iface, unused) \ + case UDI_CDC_COMM_IFACE_NUMBER_##iface: \ + port = iface; \ + break; + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_IFACE_COMM_TO_PORT, ~) +#undef UDI_CDC_IFACE_COMM_TO_PORT + default: + port = 0; + break; + } + return port; +} + +static void udi_cdc_line_coding_received(void) +{ + uint8_t port = udi_cdc_setup_to_port(); + UNUSED(port); + + UDI_CDC_SET_CODING_EXT(port, (&udi_cdc_line_coding[port])); +} + +static void udi_cdc_ctrl_state_change(uint8_t port, bool b_set, le16_t bit_mask) +{ + irqflags_t flags; + udd_ep_id_t ep_comm; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + + // Update state + flags = cpu_irq_save(); // Protect udi_cdc_state + if (b_set) { + udi_cdc_state[port] |= bit_mask; + } else { + udi_cdc_state[port] &= ~(unsigned)bit_mask; + } + cpu_irq_restore(flags); + + // Send it if possible and state changed + switch (port) { +#define UDI_CDC_PORT_TO_COMM_EP(index, unused) \ + case index: \ + ep_comm = UDI_CDC_COMM_EP_##index; \ + break; + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_PORT_TO_COMM_EP, ~) +#undef UDI_CDC_PORT_TO_COMM_EP + default: + ep_comm = UDI_CDC_COMM_EP_0; + break; + } + udi_cdc_ctrl_state_notify(port, ep_comm); +} + + +static void udi_cdc_ctrl_state_notify(uint8_t port, udd_ep_id_t ep) +{ +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + + // Send it if possible and state changed + if ((!udi_cdc_serial_state_msg_ongoing[port]) + && (udi_cdc_state[port] != uid_cdc_state_msg[port].value)) { + // Fill notification message + uid_cdc_state_msg[port].value = udi_cdc_state[port]; + // Send notification message + udi_cdc_serial_state_msg_ongoing[port] = + udd_ep_run(ep, + false, + (uint8_t *) & uid_cdc_state_msg[port], + sizeof(uid_cdc_state_msg[0]), + udi_cdc_serial_state_msg_sent); + } +} + + +static void udi_cdc_serial_state_msg_sent(udd_ep_status_t status, iram_size_t n, udd_ep_id_t ep) +{ + uint8_t port; + UNUSED(n); + UNUSED(status); + + switch (ep) { +#define UDI_CDC_GET_PORT_FROM_COMM_EP(iface, unused) \ + case UDI_CDC_COMM_EP_##iface: \ + port = iface; \ + break; + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_GET_PORT_FROM_COMM_EP, ~) +#undef UDI_CDC_GET_PORT_FROM_COMM_EP + default: + port = 0; + break; + } + + udi_cdc_serial_state_msg_ongoing[port] = false; + + // For the irregular signals like break, the incoming ring signal, + // or the overrun error state, this will reset their values to zero + // and again will not send another notification until their state changes. + udi_cdc_state[port] &= ~(CDC_SERIAL_STATE_BREAK | + CDC_SERIAL_STATE_RING | + CDC_SERIAL_STATE_FRAMING | + CDC_SERIAL_STATE_PARITY | CDC_SERIAL_STATE_OVERRUN); + uid_cdc_state_msg[port].value &= ~(CDC_SERIAL_STATE_BREAK | + CDC_SERIAL_STATE_RING | + CDC_SERIAL_STATE_FRAMING | + CDC_SERIAL_STATE_PARITY | CDC_SERIAL_STATE_OVERRUN); + // Send it if possible and state changed + udi_cdc_ctrl_state_notify(port, ep); +} + + +//------------------------------------------------- +//------- Internal routines to process data transfer + + +static bool udi_cdc_rx_start(uint8_t port) +{ + irqflags_t flags; + uint8_t buf_sel_trans; + udd_ep_id_t ep; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + + flags = cpu_irq_save(); + buf_sel_trans = udi_cdc_rx_buf_sel[port]; + if (udi_cdc_rx_trans_ongoing[port] || + (udi_cdc_rx_pos[port] < udi_cdc_rx_buf_nb[port][buf_sel_trans])) { + // Transfer already on-going or current buffer no empty + cpu_irq_restore(flags); + return false; + } + + // Change current buffer + udi_cdc_rx_pos[port] = 0; + udi_cdc_rx_buf_sel[port] = (buf_sel_trans==0)?1:0; + + // Start transfer on RX + udi_cdc_rx_trans_ongoing[port] = true; + cpu_irq_restore(flags); + + if (udi_cdc_multi_is_rx_ready(port)) { + UDI_CDC_RX_NOTIFY(port); + } + // Send the buffer with enable of short packet + switch (port) { +#define UDI_CDC_PORT_TO_DATA_EP_OUT(index, unused) \ + case index: \ + ep = UDI_CDC_DATA_EP_OUT_##index; \ + break; + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_PORT_TO_DATA_EP_OUT, ~) +#undef UDI_CDC_PORT_TO_DATA_EP_OUT + default: + ep = UDI_CDC_DATA_EP_OUT_0; + break; + } + return udd_ep_run(ep, + true, + udi_cdc_rx_buf[port][buf_sel_trans], + UDI_CDC_RX_BUFFERS, + udi_cdc_data_received); +} + + +static void udi_cdc_data_received(udd_ep_status_t status, iram_size_t n, udd_ep_id_t ep) +{ + uint8_t buf_sel_trans; + uint8_t port; + + switch (ep) { +#define UDI_CDC_DATA_EP_OUT_TO_PORT(index, unused) \ + case UDI_CDC_DATA_EP_OUT_##index: \ + port = index; \ + break; + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_DATA_EP_OUT_TO_PORT, ~) +#undef UDI_CDC_DATA_EP_OUT_TO_PORT + default: + port = 0; + break; + } + + if (UDD_EP_TRANSFER_OK != status) { + // Abort reception + return; + } + buf_sel_trans = (udi_cdc_rx_buf_sel[port]==0)?1:0; + if (!n) { + udd_ep_run( ep, + true, + udi_cdc_rx_buf[port][buf_sel_trans], + UDI_CDC_RX_BUFFERS, + udi_cdc_data_received); + return; + } + udi_cdc_rx_buf_nb[port][buf_sel_trans] = n; + udi_cdc_rx_trans_ongoing[port] = false; + udi_cdc_rx_start(port); +} + + +static void udi_cdc_data_sent(udd_ep_status_t status, iram_size_t n, udd_ep_id_t ep) +{ + uint8_t port; + UNUSED(n); + + switch (ep) { +#define UDI_CDC_DATA_EP_IN_TO_PORT(index, unused) \ + case UDI_CDC_DATA_EP_IN_##index: \ + port = index; \ + break; + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_DATA_EP_IN_TO_PORT, ~) +#undef UDI_CDC_DATA_EP_IN_TO_PORT + default: + port = 0; + break; + } + + if (UDD_EP_TRANSFER_OK != status) { + // Abort transfer + return; + } + udi_cdc_tx_buf_nb[port][(udi_cdc_tx_buf_sel[port]==0)?1:0] = 0; + udi_cdc_tx_both_buf_to_send[port] = false; + udi_cdc_tx_trans_ongoing[port] = false; + + if (n != 0) { + UDI_CDC_TX_EMPTY_NOTIFY(port); + } + udi_cdc_tx_send(port); +} + + +static void udi_cdc_tx_send(uint8_t port) +{ + irqflags_t flags; + uint8_t buf_sel_trans; + bool b_short_packet; + udd_ep_id_t ep; + static uint16_t sof_zlp_counter = 0; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + + if (udi_cdc_tx_trans_ongoing[port]) { + return; // Already on going or wait next SOF to send next data + } + if (udd_is_high_speed()) { + if (udi_cdc_tx_sof_num[port] == udd_get_micro_frame_number()) { + return; // Wait next SOF to send next data + } + }else{ + if (udi_cdc_tx_sof_num[port] == udd_get_frame_number()) { + return; // Wait next SOF to send next data + } + } + + flags = cpu_irq_save(); // to protect udi_cdc_tx_buf_sel + buf_sel_trans = udi_cdc_tx_buf_sel[port]; + if (udi_cdc_tx_buf_nb[port][buf_sel_trans] == 0) { + sof_zlp_counter++; + if (((!udd_is_high_speed()) && (sof_zlp_counter < 100)) + || (udd_is_high_speed() && (sof_zlp_counter < 800))) { + cpu_irq_restore(flags); + return; + } + } + sof_zlp_counter = 0; + + if (!udi_cdc_tx_both_buf_to_send[port]) { + // Send current Buffer + // and switch the current buffer + udi_cdc_tx_buf_sel[port] = (buf_sel_trans==0)?1:0; + }else{ + // Send the other Buffer + // and no switch the current buffer + buf_sel_trans = (buf_sel_trans==0)?1:0; + } + udi_cdc_tx_trans_ongoing[port] = true; + cpu_irq_restore(flags); + + b_short_packet = (udi_cdc_tx_buf_nb[port][buf_sel_trans] != UDI_CDC_TX_BUFFERS); + if (b_short_packet) { + if (udd_is_high_speed()) { + udi_cdc_tx_sof_num[port] = udd_get_micro_frame_number(); + }else{ + udi_cdc_tx_sof_num[port] = udd_get_frame_number(); + } + }else{ + udi_cdc_tx_sof_num[port] = 0; // Force next transfer without wait SOF + } + + // Send the buffer with enable of short packet + switch (port) { +#define UDI_CDC_PORT_TO_DATA_EP_IN(index, unused) \ + case index: \ + ep = UDI_CDC_DATA_EP_IN_##index; \ + break; + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_PORT_TO_DATA_EP_IN, ~) +#undef UDI_CDC_PORT_TO_DATA_EP_IN + default: + ep = UDI_CDC_DATA_EP_IN_0; + break; + } + udd_ep_run( ep, + b_short_packet, + udi_cdc_tx_buf[port][buf_sel_trans], + udi_cdc_tx_buf_nb[port][buf_sel_trans], + udi_cdc_data_sent); +} + + +//--------------------------------------------- +//------- Application interface + + +//------- Application interface + +void udi_cdc_ctrl_signal_dcd(bool b_set) +{ + udi_cdc_ctrl_state_change(0, b_set, CDC_SERIAL_STATE_DCD); +} + +void udi_cdc_ctrl_signal_dsr(bool b_set) +{ + udi_cdc_ctrl_state_change(0, b_set, CDC_SERIAL_STATE_DSR); +} + +void udi_cdc_signal_framing_error(void) +{ + udi_cdc_ctrl_state_change(0, true, CDC_SERIAL_STATE_FRAMING); +} + +void udi_cdc_signal_parity_error(void) +{ + udi_cdc_ctrl_state_change(0, true, CDC_SERIAL_STATE_PARITY); +} + +void udi_cdc_signal_overrun(void) +{ + udi_cdc_ctrl_state_change(0, true, CDC_SERIAL_STATE_OVERRUN); +} + +void udi_cdc_multi_ctrl_signal_dcd(uint8_t port, bool b_set) +{ + udi_cdc_ctrl_state_change(port, b_set, CDC_SERIAL_STATE_DCD); +} + +void udi_cdc_multi_ctrl_signal_dsr(uint8_t port, bool b_set) +{ + udi_cdc_ctrl_state_change(port, b_set, CDC_SERIAL_STATE_DSR); +} + +void udi_cdc_multi_signal_framing_error(uint8_t port) +{ + udi_cdc_ctrl_state_change(port, true, CDC_SERIAL_STATE_FRAMING); +} + +void udi_cdc_multi_signal_parity_error(uint8_t port) +{ + udi_cdc_ctrl_state_change(port, true, CDC_SERIAL_STATE_PARITY); +} + +void udi_cdc_multi_signal_overrun(uint8_t port) +{ + udi_cdc_ctrl_state_change(port, true, CDC_SERIAL_STATE_OVERRUN); +} + +iram_size_t udi_cdc_multi_get_nb_received_data(uint8_t port) +{ + irqflags_t flags; + uint16_t pos; + iram_size_t nb_received; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + flags = cpu_irq_save(); + pos = udi_cdc_rx_pos[port]; + nb_received = udi_cdc_rx_buf_nb[port][udi_cdc_rx_buf_sel[port]] - pos; + cpu_irq_restore(flags); + return nb_received; +} + +iram_size_t udi_cdc_get_nb_received_data(void) +{ + return udi_cdc_multi_get_nb_received_data(0); +} + +bool udi_cdc_multi_is_rx_ready(uint8_t port) +{ + return (udi_cdc_multi_get_nb_received_data(port) > 0); +} + +bool udi_cdc_is_rx_ready(void) +{ + return udi_cdc_multi_is_rx_ready(0); +} + +int udi_cdc_multi_getc(uint8_t port) +{ + irqflags_t flags; + int rx_data = 0; + bool b_databit_9; + uint16_t pos; + uint8_t buf_sel; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + + b_databit_9 = (9 == udi_cdc_line_coding[port].bDataBits); + +udi_cdc_getc_process_one_byte: + // Check available data + flags = cpu_irq_save(); + pos = udi_cdc_rx_pos[port]; + buf_sel = udi_cdc_rx_buf_sel[port]; + cpu_irq_restore(flags); + while (pos >= udi_cdc_rx_buf_nb[port][buf_sel]) { + if (!udi_cdc_data_running) { + return 0; + } + goto udi_cdc_getc_process_one_byte; + } + + // Read data + rx_data |= udi_cdc_rx_buf[port][buf_sel][pos]; + udi_cdc_rx_pos[port] = pos+1; + + udi_cdc_rx_start(port); + + if (b_databit_9) { + // Receive MSB + b_databit_9 = false; + rx_data = rx_data << 8; + goto udi_cdc_getc_process_one_byte; + } + return rx_data; +} + +int udi_cdc_getc(void) +{ + return udi_cdc_multi_getc(0); +} + +iram_size_t udi_cdc_multi_read_buf(uint8_t port, void* buf, iram_size_t size) +{ + irqflags_t flags; + uint8_t *ptr_buf = (uint8_t *)buf; + iram_size_t copy_nb; + uint16_t pos; + uint8_t buf_sel; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + +udi_cdc_read_buf_loop_wait: + // Check available data + flags = cpu_irq_save(); + pos = udi_cdc_rx_pos[port]; + buf_sel = udi_cdc_rx_buf_sel[port]; + cpu_irq_restore(flags); + while (pos >= udi_cdc_rx_buf_nb[port][buf_sel]) { + if (!udi_cdc_data_running) { + return size; + } + goto udi_cdc_read_buf_loop_wait; + } + + // Read data + copy_nb = udi_cdc_rx_buf_nb[port][buf_sel] - pos; + if (copy_nb>size) { + copy_nb = size; + } + memcpy(ptr_buf, &udi_cdc_rx_buf[port][buf_sel][pos], copy_nb); + udi_cdc_rx_pos[port] += copy_nb; + ptr_buf += copy_nb; + size -= copy_nb; + udi_cdc_rx_start(port); + + if (size) { + goto udi_cdc_read_buf_loop_wait; + } + return 0; +} + +iram_size_t udi_cdc_read_buf(void* buf, iram_size_t size) +{ + return udi_cdc_multi_read_buf(0, buf, size); +} + +iram_size_t udi_cdc_multi_get_free_tx_buffer(uint8_t port) +{ + irqflags_t flags; + iram_size_t buf_sel_nb, buf_nosel_nb, retval; + uint8_t buf_sel; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + + flags = cpu_irq_save(); + buf_sel = udi_cdc_tx_buf_sel[port]; + buf_sel_nb = udi_cdc_tx_buf_nb[port][buf_sel]; + buf_nosel_nb = udi_cdc_tx_buf_nb[port][(buf_sel == 0)? 1 : 0]; + if (buf_sel_nb == UDI_CDC_TX_BUFFERS) { + if ((!udi_cdc_tx_trans_ongoing[port]) + && (!udi_cdc_tx_both_buf_to_send[port])) { + /* One buffer is full, but the other buffer is not used. + * (not used = transfer on-going) + * then move to the other buffer to store data */ + udi_cdc_tx_both_buf_to_send[port] = true; + udi_cdc_tx_buf_sel[port] = (buf_sel == 0)? 1 : 0; + buf_sel_nb = 0; + buf_nosel_nb = UDI_CDC_TX_BUFFERS; + } + } + retval = UDI_CDC_TX_BUFFERS - buf_sel_nb; + cpu_irq_restore(flags); + return retval; +} + +iram_size_t udi_cdc_get_free_tx_buffer(void) +{ + return udi_cdc_multi_get_free_tx_buffer(0); +} + +bool udi_cdc_multi_is_tx_ready(uint8_t port) +{ + return (udi_cdc_multi_get_free_tx_buffer(port) != 0); +} + +bool udi_cdc_is_tx_ready(void) +{ + return udi_cdc_multi_is_tx_ready(0); +} + +int udi_cdc_multi_putc(uint8_t port, int value) +{ + irqflags_t flags; + bool b_databit_9; + uint8_t buf_sel; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + + b_databit_9 = (9 == udi_cdc_line_coding[port].bDataBits); + +udi_cdc_putc_process_one_byte: + // Check available space + if (!udi_cdc_multi_is_tx_ready(port)) { + if (!udi_cdc_data_running) { + return false; + } + goto udi_cdc_putc_process_one_byte; + } + + // Write value + flags = cpu_irq_save(); + buf_sel = udi_cdc_tx_buf_sel[port]; + udi_cdc_tx_buf[port][buf_sel][udi_cdc_tx_buf_nb[port][buf_sel]++] = value; + cpu_irq_restore(flags); + + if (b_databit_9) { + // Send MSB + b_databit_9 = false; + value = value >> 8; + goto udi_cdc_putc_process_one_byte; + } + return true; +} + +int udi_cdc_putc(int value) +{ + return udi_cdc_multi_putc(0, value); +} + +iram_size_t udi_cdc_multi_write_buf(uint8_t port, const void* buf, iram_size_t size) +{ + irqflags_t flags; + uint8_t buf_sel; + uint16_t buf_nb; + iram_size_t copy_nb; + uint8_t *ptr_buf = (uint8_t *)buf; + +#if UDI_CDC_PORT_NB == 1 // To optimize code + port = 0; +#endif + + if (9 == udi_cdc_line_coding[port].bDataBits) { + size *=2; + } + +udi_cdc_write_buf_loop_wait: + // Check available space + if (!udi_cdc_multi_is_tx_ready(port)) { + if (!udi_cdc_data_running) { + return size; + } + goto udi_cdc_write_buf_loop_wait; + } + + // Write values + flags = cpu_irq_save(); + buf_sel = udi_cdc_tx_buf_sel[port]; + buf_nb = udi_cdc_tx_buf_nb[port][buf_sel]; + copy_nb = UDI_CDC_TX_BUFFERS - buf_nb; + if (copy_nb > size) { + copy_nb = size; + } + memcpy(&udi_cdc_tx_buf[port][buf_sel][buf_nb], ptr_buf, copy_nb); + udi_cdc_tx_buf_nb[port][buf_sel] = buf_nb + copy_nb; + cpu_irq_restore(flags); + + // Update buffer pointer + ptr_buf = ptr_buf + copy_nb; + size -= copy_nb; + + if (size) { + goto udi_cdc_write_buf_loop_wait; + } + + return 0; +} + +iram_size_t udi_cdc_write_buf(const void* buf, iram_size_t size) +{ + return udi_cdc_multi_write_buf(0, buf, size); +} + +//@} diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/class/cdc/device/udi_cdc.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/class/cdc/device/udi_cdc.h new file mode 100755 index 0000000..d13fc13 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/class/cdc/device/udi_cdc.h @@ -0,0 +1,796 @@ +/** + * \file + * + * \brief USB Device Communication Device Class (CDC) interface definitions. + * + * Copyright (c) 2009 - 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _UDI_CDC_H_ +#define _UDI_CDC_H_ + +#include "conf_usb.h" +#include "usb_protocol.h" +#include "usb_protocol_cdc.h" +#include "udd.h" +#include "udc_desc.h" +#include "udi.h" + +// Check the number of port +#ifndef UDI_CDC_PORT_NB +# define UDI_CDC_PORT_NB 1 +#endif +#if (UDI_CDC_PORT_NB < 1) || (UDI_CDC_PORT_NB > 7) +# error UDI_CDC_PORT_NB must be between 1 and 7 +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \addtogroup udi_cdc_group_udc + * @{ + */ + +//! Global structure which contains standard UDI API for UDC +extern UDC_DESC_STORAGE udi_api_t udi_api_cdc_comm; +extern UDC_DESC_STORAGE udi_api_t udi_api_cdc_data; +//@} + +/** + * \ingroup udi_cdc_group + * \defgroup udi_cdc_group_desc USB interface descriptors + * + * The following structures provide predefined USB interface descriptors. + * It must be used to define the final USB descriptors. + */ +//@{ + +/** + * \brief Communication Class interface descriptor + * + * Interface descriptor with associated functional and endpoint + * descriptors for the CDC Communication Class interface. + */ +typedef struct { + //! Standard interface descriptor + usb_iface_desc_t iface; + //! CDC Header functional descriptor + usb_cdc_hdr_desc_t header; + //! CDC Abstract Control Model functional descriptor + usb_cdc_acm_desc_t acm; + //! CDC Union functional descriptor + usb_cdc_union_desc_t union_desc; + //! CDC Call Management functional descriptor + usb_cdc_call_mgmt_desc_t call_mgmt; + //! Notification endpoint descriptor + usb_ep_desc_t ep_notify; +} udi_cdc_comm_desc_t; + + +/** + * \brief Data Class interface descriptor + * + * Interface descriptor with associated endpoint descriptors for the + * CDC Data Class interface. + */ +typedef struct { + //! Standard interface descriptor + usb_iface_desc_t iface; + //! Data IN/OUT endpoint descriptors + usb_ep_desc_t ep_in; + usb_ep_desc_t ep_out; +} udi_cdc_data_desc_t; + + +//! CDC communication endpoints size for all speeds +#define UDI_CDC_COMM_EP_SIZE 64 +//! CDC data endpoints size for FS speed (8B, 16B, 32B, 64B) +#define UDI_CDC_DATA_EPS_FS_SIZE 64 +//! CDC data endpoints size for HS speed (512B only) +#define UDI_CDC_DATA_EPS_HS_SIZE 512 + +/** + * \name Content of interface descriptors + * Up to 7 CDC interfaces can be implemented on a USB device. + */ +//@{ +//! By default no string associated to these interfaces +#ifndef UDI_CDC_IAD_STRING_ID_0 +#define UDI_CDC_IAD_STRING_ID_0 0 +#endif +#ifndef UDI_CDC_COMM_STRING_ID_0 +#define UDI_CDC_COMM_STRING_ID_0 0 +#endif +#ifndef UDI_CDC_DATA_STRING_ID_0 +#define UDI_CDC_DATA_STRING_ID_0 0 +#endif +#define UDI_CDC_IAD_DESC_0 UDI_CDC_IAD_DESC(0) +#define UDI_CDC_COMM_DESC_0 UDI_CDC_COMM_DESC(0) +#define UDI_CDC_DATA_DESC_0_FS UDI_CDC_DATA_DESC_FS(0) +#define UDI_CDC_DATA_DESC_0_HS UDI_CDC_DATA_DESC_HS(0) + +//! By default no string associated to these interfaces +#ifndef UDI_CDC_IAD_STRING_ID_1 +#define UDI_CDC_IAD_STRING_ID_1 0 +#endif +#ifndef UDI_CDC_COMM_STRING_ID_1 +#define UDI_CDC_COMM_STRING_ID_1 0 +#endif +#ifndef UDI_CDC_DATA_STRING_ID_1 +#define UDI_CDC_DATA_STRING_ID_1 0 +#endif +#define UDI_CDC_IAD_DESC_1 UDI_CDC_IAD_DESC(1) +#define UDI_CDC_COMM_DESC_1 UDI_CDC_COMM_DESC(1) +#define UDI_CDC_DATA_DESC_1_FS UDI_CDC_DATA_DESC_FS(1) +#define UDI_CDC_DATA_DESC_1_HS UDI_CDC_DATA_DESC_HS(1) + +//! By default no string associated to these interfaces +#ifndef UDI_CDC_IAD_STRING_ID_2 +#define UDI_CDC_IAD_STRING_ID_2 0 +#endif +#ifndef UDI_CDC_COMM_STRING_ID_2 +#define UDI_CDC_COMM_STRING_ID_2 0 +#endif +#ifndef UDI_CDC_DATA_STRING_ID_2 +#define UDI_CDC_DATA_STRING_ID_2 0 +#endif +#define UDI_CDC_IAD_DESC_2 UDI_CDC_IAD_DESC(2) +#define UDI_CDC_COMM_DESC_2 UDI_CDC_COMM_DESC(2) +#define UDI_CDC_DATA_DESC_2_FS UDI_CDC_DATA_DESC_FS(2) +#define UDI_CDC_DATA_DESC_2_HS UDI_CDC_DATA_DESC_HS(2) + +//! By default no string associated to these interfaces +#ifndef UDI_CDC_IAD_STRING_ID_3 +#define UDI_CDC_IAD_STRING_ID_3 0 +#endif +#ifndef UDI_CDC_COMM_STRING_ID_3 +#define UDI_CDC_COMM_STRING_ID_3 0 +#endif +#ifndef UDI_CDC_DATA_STRING_ID_3 +#define UDI_CDC_DATA_STRING_ID_3 0 +#endif +#define UDI_CDC_IAD_DESC_3 UDI_CDC_IAD_DESC(3) +#define UDI_CDC_COMM_DESC_3 UDI_CDC_COMM_DESC(3) +#define UDI_CDC_DATA_DESC_3_FS UDI_CDC_DATA_DESC_FS(3) +#define UDI_CDC_DATA_DESC_3_HS UDI_CDC_DATA_DESC_HS(3) + +//! By default no string associated to these interfaces +#ifndef UDI_CDC_IAD_STRING_ID_4 +#define UDI_CDC_IAD_STRING_ID_4 0 +#endif +#ifndef UDI_CDC_COMM_STRING_ID_4 +#define UDI_CDC_COMM_STRING_ID_4 0 +#endif +#ifndef UDI_CDC_DATA_STRING_ID_4 +#define UDI_CDC_DATA_STRING_ID_4 0 +#endif +#define UDI_CDC_IAD_DESC_4 UDI_CDC_IAD_DESC(4) +#define UDI_CDC_COMM_DESC_4 UDI_CDC_COMM_DESC(4) +#define UDI_CDC_DATA_DESC_4_FS UDI_CDC_DATA_DESC_FS(4) +#define UDI_CDC_DATA_DESC_4_HS UDI_CDC_DATA_DESC_HS(4) + +//! By default no string associated to these interfaces +#ifndef UDI_CDC_IAD_STRING_ID_5 +#define UDI_CDC_IAD_STRING_ID_5 0 +#endif +#ifndef UDI_CDC_COMM_STRING_ID_5 +#define UDI_CDC_COMM_STRING_ID_5 0 +#endif +#ifndef UDI_CDC_DATA_STRING_ID_5 +#define UDI_CDC_DATA_STRING_ID_5 0 +#endif +#define UDI_CDC_IAD_DESC_5 UDI_CDC_IAD_DESC(5) +#define UDI_CDC_COMM_DESC_5 UDI_CDC_COMM_DESC(5) +#define UDI_CDC_DATA_DESC_5_FS UDI_CDC_DATA_DESC_FS(5) +#define UDI_CDC_DATA_DESC_5_HS UDI_CDC_DATA_DESC_HS(5) + +//! By default no string associated to these interfaces +#ifndef UDI_CDC_IAD_STRING_ID_6 +#define UDI_CDC_IAD_STRING_ID_6 0 +#endif +#ifndef UDI_CDC_COMM_STRING_ID_6 +#define UDI_CDC_COMM_STRING_ID_6 0 +#endif +#ifndef UDI_CDC_DATA_STRING_ID_6 +#define UDI_CDC_DATA_STRING_ID_6 0 +#endif +#define UDI_CDC_IAD_DESC_6 UDI_CDC_IAD_DESC(6) +#define UDI_CDC_COMM_DESC_6 UDI_CDC_COMM_DESC(6) +#define UDI_CDC_DATA_DESC_6_FS UDI_CDC_DATA_DESC_FS(6) +#define UDI_CDC_DATA_DESC_6_HS UDI_CDC_DATA_DESC_HS(6) +//@} + + +//! Content of CDC IAD interface descriptor for all speeds +#define UDI_CDC_IAD_DESC(port) { \ + .bLength = sizeof(usb_iad_desc_t),\ + .bDescriptorType = USB_DT_IAD,\ + .bInterfaceCount = 2,\ + .bFunctionClass = CDC_CLASS_COMM,\ + .bFunctionSubClass = CDC_SUBCLASS_ACM,\ + .bFunctionProtocol = CDC_PROTOCOL_V25TER,\ + .bFirstInterface = UDI_CDC_COMM_IFACE_NUMBER_##port,\ + .iFunction = UDI_CDC_IAD_STRING_ID_##port,\ + } + +//! Content of CDC COMM interface descriptor for all speeds +#define UDI_CDC_COMM_DESC(port) { \ + .iface.bLength = sizeof(usb_iface_desc_t),\ + .iface.bDescriptorType = USB_DT_INTERFACE,\ + .iface.bAlternateSetting = 0,\ + .iface.bNumEndpoints = 1,\ + .iface.bInterfaceClass = CDC_CLASS_COMM,\ + .iface.bInterfaceSubClass = CDC_SUBCLASS_ACM,\ + .iface.bInterfaceProtocol = CDC_PROTOCOL_V25TER,\ + .header.bFunctionLength = sizeof(usb_cdc_hdr_desc_t),\ + .header.bDescriptorType = CDC_CS_INTERFACE,\ + .header.bDescriptorSubtype = CDC_SCS_HEADER,\ + .header.bcdCDC = LE16(0x0110),\ + .call_mgmt.bFunctionLength = sizeof(usb_cdc_call_mgmt_desc_t),\ + .call_mgmt.bDescriptorType = CDC_CS_INTERFACE,\ + .call_mgmt.bDescriptorSubtype = CDC_SCS_CALL_MGMT,\ + .call_mgmt.bmCapabilities = \ + CDC_CALL_MGMT_SUPPORTED | CDC_CALL_MGMT_OVER_DCI,\ + .acm.bFunctionLength = sizeof(usb_cdc_acm_desc_t),\ + .acm.bDescriptorType = CDC_CS_INTERFACE,\ + .acm.bDescriptorSubtype = CDC_SCS_ACM,\ + .acm.bmCapabilities = CDC_ACM_SUPPORT_LINE_REQUESTS,\ + .union_desc.bFunctionLength = sizeof(usb_cdc_union_desc_t),\ + .union_desc.bDescriptorType = CDC_CS_INTERFACE,\ + .union_desc.bDescriptorSubtype= CDC_SCS_UNION,\ + .ep_notify.bLength = sizeof(usb_ep_desc_t),\ + .ep_notify.bDescriptorType = USB_DT_ENDPOINT,\ + .ep_notify.bmAttributes = USB_EP_TYPE_INTERRUPT,\ + .ep_notify.wMaxPacketSize = LE16(UDI_CDC_COMM_EP_SIZE),\ + .ep_notify.bInterval = 0x10,\ + .ep_notify.bEndpointAddress = UDI_CDC_COMM_EP_##port,\ + .iface.bInterfaceNumber = UDI_CDC_COMM_IFACE_NUMBER_##port,\ + .call_mgmt.bDataInterface = UDI_CDC_DATA_IFACE_NUMBER_##port,\ + .union_desc.bMasterInterface = UDI_CDC_COMM_IFACE_NUMBER_##port,\ + .union_desc.bSlaveInterface0 = UDI_CDC_DATA_IFACE_NUMBER_##port,\ + .iface.iInterface = UDI_CDC_COMM_STRING_ID_##port,\ + } + +//! Content of CDC DATA interface descriptors +#define UDI_CDC_DATA_DESC_COMMON \ + .iface.bLength = sizeof(usb_iface_desc_t),\ + .iface.bDescriptorType = USB_DT_INTERFACE,\ + .iface.bAlternateSetting = 0,\ + .iface.bNumEndpoints = 2,\ + .iface.bInterfaceClass = CDC_CLASS_DATA,\ + .iface.bInterfaceSubClass = 0,\ + .iface.bInterfaceProtocol = 0,\ + .ep_in.bLength = sizeof(usb_ep_desc_t),\ + .ep_in.bDescriptorType = USB_DT_ENDPOINT,\ + .ep_in.bmAttributes = USB_EP_TYPE_BULK,\ + .ep_in.bInterval = 0,\ + .ep_out.bLength = sizeof(usb_ep_desc_t),\ + .ep_out.bDescriptorType = USB_DT_ENDPOINT,\ + .ep_out.bmAttributes = USB_EP_TYPE_BULK,\ + .ep_out.bInterval = 0, + +#define UDI_CDC_DATA_DESC_FS(port) { \ + UDI_CDC_DATA_DESC_COMMON \ + .ep_in.wMaxPacketSize = LE16(UDI_CDC_DATA_EPS_FS_SIZE),\ + .ep_out.wMaxPacketSize = LE16(UDI_CDC_DATA_EPS_FS_SIZE),\ + .ep_in.bEndpointAddress = UDI_CDC_DATA_EP_IN_##port,\ + .ep_out.bEndpointAddress = UDI_CDC_DATA_EP_OUT_##port,\ + .iface.bInterfaceNumber = UDI_CDC_DATA_IFACE_NUMBER_##port,\ + .iface.iInterface = UDI_CDC_DATA_STRING_ID_##port,\ + } + +#define UDI_CDC_DATA_DESC_HS(port) { \ + UDI_CDC_DATA_DESC_COMMON \ + .ep_in.wMaxPacketSize = LE16(UDI_CDC_DATA_EPS_HS_SIZE),\ + .ep_out.wMaxPacketSize = LE16(UDI_CDC_DATA_EPS_HS_SIZE),\ + .ep_in.bEndpointAddress = UDI_CDC_DATA_EP_IN_##port,\ + .ep_out.bEndpointAddress = UDI_CDC_DATA_EP_OUT_##port,\ + .iface.bInterfaceNumber = UDI_CDC_DATA_IFACE_NUMBER_##port,\ + .iface.iInterface = UDI_CDC_DATA_STRING_ID_##port,\ + } + +//@} + +/** + * \ingroup udi_group + * \defgroup udi_cdc_group USB Device Interface (UDI) for Communication Class Device (CDC) + * + * Common APIs used by high level application to use this USB class. + * + * These routines are used to transfer and control data + * to/from USB CDC endpoint. + * + * See \ref udi_cdc_quickstart. + * @{ + */ + +/** + * \name Interface for application with single CDC interface support + */ +//@{ + +/** + * \brief Notify a state change of DCD signal + * + * \param b_set DCD is enabled if true, else disabled + */ +void udi_cdc_ctrl_signal_dcd(bool b_set); + +/** + * \brief Notify a state change of DSR signal + * + * \param b_set DSR is enabled if true, else disabled + */ +void udi_cdc_ctrl_signal_dsr(bool b_set); + +/** + * \brief Notify a framing error + */ +void udi_cdc_signal_framing_error(void); + +/** + * \brief Notify a parity error + */ +void udi_cdc_signal_parity_error(void); + +/** + * \brief Notify a overrun + */ +void udi_cdc_signal_overrun(void); + +/** + * \brief Gets the number of byte received + * + * \return the number of data available + */ +iram_size_t udi_cdc_get_nb_received_data(void); + +/** + * \brief This function checks if a character has been received on the CDC line + * + * \return \c 1 if a byte is ready to be read. + */ +bool udi_cdc_is_rx_ready(void); + +/** + * \brief Waits and gets a value on CDC line + * + * \return value read on CDC line + */ +int udi_cdc_getc(void); + +/** + * \brief Reads a RAM buffer on CDC line + * + * \param buf Values read + * \param size Number of value read + * + * \return the number of data remaining + */ +iram_size_t udi_cdc_read_buf(void* buf, iram_size_t size); + +/** + * \brief Gets the number of free byte in TX buffer + * + * \return the number of free byte in TX buffer + */ +iram_size_t udi_cdc_get_free_tx_buffer(void); + +/** + * \brief This function checks if a new character sent is possible + * The type int is used to support scanf redirection from compiler LIB. + * + * \return \c 1 if a new character can be sent + */ +bool udi_cdc_is_tx_ready(void); + +/** + * \brief Puts a byte on CDC line + * The type int is used to support printf redirection from compiler LIB. + * + * \param value Value to put + * + * \return \c 1 if function was successfully done, otherwise \c 0. + */ +int udi_cdc_putc(int value); + +/** + * \brief Writes a RAM buffer on CDC line + * + * \param buf Values to write + * \param size Number of value to write + * + * \return the number of data remaining + */ +iram_size_t udi_cdc_write_buf(const void* buf, iram_size_t size); +//@} + +/** + * \name Interface for application with multi CDC interfaces support + */ +//@{ + +/** + * \brief Notify a state change of DCD signal + * + * \param port Communication port number to manage + * \param b_set DCD is enabled if true, else disabled + */ +void udi_cdc_multi_ctrl_signal_dcd(uint8_t port, bool b_set); + +/** + * \brief Notify a state change of DSR signal + * + * \param port Communication port number to manage + * \param b_set DSR is enabled if true, else disabled + */ +void udi_cdc_multi_ctrl_signal_dsr(uint8_t port, bool b_set); + +/** + * \brief Notify a framing error + * + * \param port Communication port number to manage + */ +void udi_cdc_multi_signal_framing_error(uint8_t port); + +/** + * \brief Notify a parity error + * + * \param port Communication port number to manage + */ +void udi_cdc_multi_signal_parity_error(uint8_t port); + +/** + * \brief Notify a overrun + * + * \param port Communication port number to manage + */ +void udi_cdc_multi_signal_overrun(uint8_t port); + +/** + * \brief Gets the number of byte received + * + * \param port Communication port number to manage + * + * \return the number of data available + */ +iram_size_t udi_cdc_multi_get_nb_received_data(uint8_t port); + +/** + * \brief This function checks if a character has been received on the CDC line + * + * \param port Communication port number to manage + * + * \return \c 1 if a byte is ready to be read. + */ +bool udi_cdc_multi_is_rx_ready(uint8_t port); + +/** + * \brief Waits and gets a value on CDC line + * + * \param port Communication port number to manage + * + * \return value read on CDC line + */ +int udi_cdc_multi_getc(uint8_t port); + +/** + * \brief Reads a RAM buffer on CDC line + * + * \param port Communication port number to manage + * \param buf Values read + * \param size Number of values read + * + * \return the number of data remaining + */ +iram_size_t udi_cdc_multi_read_buf(uint8_t port, void* buf, iram_size_t size); + +/** + * \brief Gets the number of free byte in TX buffer + * + * \param port Communication port number to manage + * + * \return the number of free byte in TX buffer + */ +iram_size_t udi_cdc_multi_get_free_tx_buffer(uint8_t port); + +/** + * \brief This function checks if a new character sent is possible + * The type int is used to support scanf redirection from compiler LIB. + * + * \param port Communication port number to manage + * + * \return \c 1 if a new character can be sent + */ +bool udi_cdc_multi_is_tx_ready(uint8_t port); + +/** + * \brief Puts a byte on CDC line + * The type int is used to support printf redirection from compiler LIB. + * + * \param port Communication port number to manage + * \param value Value to put + * + * \return \c 1 if function was successfully done, otherwise \c 0. + */ +int udi_cdc_multi_putc(uint8_t port, int value); + +/** + * \brief Writes a RAM buffer on CDC line + * + * \param port Communication port number to manage + * \param buf Values to write + * \param size Number of value to write + * + * \return the number of data remaining + */ +iram_size_t udi_cdc_multi_write_buf(uint8_t port, const void* buf, iram_size_t size); +//@} + +//@} + +/** + * \page udi_cdc_quickstart Quick start guide for USB device Communication Class Device module (UDI CDC) + * + * This is the quick start guide for the \ref udi_cdc_group + * "USB device interface CDC module (UDI CDC)" with step-by-step instructions on + * how to configure and use the modules in a selection of use cases. + * + * The use cases contain several code fragments. The code fragments in the + * steps for setup can be copied into a custom initialization function, while + * the steps for usage can be copied into, e.g., the main application function. + * + * \section udi_cdc_basic_use_case Basic use case + * In this basic use case, the "USB CDC (Single Interface Device)" module is used + * with only one communication port. + * The "USB CDC (Composite Device)" module usage is described in \ref udi_cdc_use_cases + * "Advanced use cases". + * + * \section udi_cdc_basic_use_case_setup Setup steps + * \subsection udi_cdc_basic_use_case_setup_prereq Prerequisites + * \copydetails udc_basic_use_case_setup_prereq + * \subsection udi_cdc_basic_use_case_setup_code Example code + * \copydetails udc_basic_use_case_setup_code + * \subsection udi_cdc_basic_use_case_setup_flow Workflow + * \copydetails udc_basic_use_case_setup_flow + * + * \section udi_cdc_basic_use_case_usage Usage steps + * + * \subsection udi_cdc_basic_use_case_usage_code Example code + * Content of conf_usb.h: + * \code + #define UDI_CDC_ENABLE_EXT(port) my_callback_cdc_enable() + extern bool my_callback_cdc_enable(void); + #define UDI_CDC_DISABLE_EXT(port) my_callback_cdc_disable() + extern void my_callback_cdc_disable(void); + #define UDI_CDC_LOW_RATE + + #define UDI_CDC_DEFAULT_RATE 115200 + #define UDI_CDC_DEFAULT_STOPBITS CDC_STOP_BITS_1 + #define UDI_CDC_DEFAULT_PARITY CDC_PAR_NONE + #define UDI_CDC_DEFAULT_DATABITS 8 + + #include "udi_cdc_conf.h" // At the end of conf_usb.h file +\endcode + * + * Add to application C-file: + * \code + static bool my_flag_autorize_cdc_transfert = false; + bool my_callback_cdc_enable(void) + { + my_flag_autorize_cdc_transfert = true; + return true; + } + void my_callback_cdc_disable(void) + { + my_flag_autorize_cdc_transfert = false; + } + + void task(void) + { + if (my_flag_autorize_cdc_transfert) { + udi_cdc_putc('A'); + udi_cdc_getc(); + } + } +\endcode + * + * \subsection udi_cdc_basic_use_case_setup_flow Workflow + * -# Ensure that conf_usb.h is available and contains the following configuration + * which is the USB device CDC configuration: + * - \code #define USB_DEVICE_SERIAL_NAME "12...EF" // Disk SN for CDC \endcode + * \note The USB serial number is mandatory when a CDC interface is used. + * - \code #define UDI_CDC_ENABLE_EXT(port) my_callback_cdc_enable() + extern bool my_callback_cdc_enable(void); \endcode + * \note After the device enumeration (detecting and identifying USB devices), + * the USB host starts the device configuration. When the USB CDC interface + * from the device is accepted by the host, the USB host enables this interface and the + * UDI_CDC_ENABLE_EXT() callback function is called and return true. + * Thus, when this event is received, the data transfer on CDC interface are authorized. + * - \code #define UDI_CDC_DISABLE_EXT(port) my_callback_cdc_disable() + extern void my_callback_cdc_disable(void); \endcode + * \note When the USB device is unplugged or is reset by the USB host, the USB + * interface is disabled and the UDI_CDC_DISABLE_EXT() callback function + * is called. Thus, the data transfer must be stopped on CDC interface. + * - \code #define UDI_CDC_LOW_RATE \endcode + * \note Define it when the transfer CDC Device to Host is a low rate + * (<512000 bauds) to reduce CDC buffers size. + * - \code #define UDI_CDC_DEFAULT_RATE 115200 + #define UDI_CDC_DEFAULT_STOPBITS CDC_STOP_BITS_1 + #define UDI_CDC_DEFAULT_PARITY CDC_PAR_NONE + #define UDI_CDC_DEFAULT_DATABITS 8 \endcode + * \note Default configuration of communication port at startup. + * -# Send or wait data on CDC line: + * - \code // Waits and gets a value on CDC line + int udi_cdc_getc(void); + // Reads a RAM buffer on CDC line + iram_size_t udi_cdc_read_buf(int* buf, iram_size_t size); + // Puts a byte on CDC line + int udi_cdc_putc(int value); + // Writes a RAM buffer on CDC line + iram_size_t udi_cdc_write_buf(const int* buf, iram_size_t size); \endcode + * + * \section udi_cdc_use_cases Advanced use cases + * For more advanced use of the UDI CDC module, see the following use cases: + * - \subpage udi_cdc_use_case_composite + * - \subpage udc_use_case_1 + * - \subpage udc_use_case_2 + * - \subpage udc_use_case_3 + * - \subpage udc_use_case_4 + * - \subpage udc_use_case_5 + * - \subpage udc_use_case_6 + */ + +/** + * \page udi_cdc_use_case_composite CDC in a composite device + * + * A USB Composite Device is a USB Device which uses more than one USB class. + * In this use case, the "USB CDC (Composite Device)" module is used to + * create a USB composite device. Thus, this USB module can be associated with + * another "Composite Device" module, like "USB HID Mouse (Composite Device)". + * + * Also, you can refer to application note + * + * AVR4902 ASF - USB Composite Device. + * + * \section udi_cdc_use_case_composite_setup Setup steps + * For the setup code of this use case to work, the + * \ref udi_cdc_basic_use_case "basic use case" must be followed. + * + * \section udi_cdc_use_case_composite_usage Usage steps + * + * \subsection udi_cdc_use_case_composite_usage_code Example code + * Content of conf_usb.h: + * \code + #define USB_DEVICE_EP_CTRL_SIZE 64 + #define USB_DEVICE_NB_INTERFACE (X+2) + #define USB_DEVICE_MAX_EP (X+3) + + #define UDI_CDC_DATA_EP_IN_0 (1 | USB_EP_DIR_IN) // TX + #define UDI_CDC_DATA_EP_OUT_0 (2 | USB_EP_DIR_OUT) // RX + #define UDI_CDC_COMM_EP_0 (3 | USB_EP_DIR_IN) // Notify endpoint + #define UDI_CDC_COMM_IFACE_NUMBER_0 X+0 + #define UDI_CDC_DATA_IFACE_NUMBER_0 X+1 + + #define UDI_COMPOSITE_DESC_T \ + usb_iad_desc_t udi_cdc_iad; \ + udi_cdc_comm_desc_t udi_cdc_comm; \ + udi_cdc_data_desc_t udi_cdc_data; \ + ... + #define UDI_COMPOSITE_DESC_FS \ + .udi_cdc_iad = UDI_CDC_IAD_DESC_0, \ + .udi_cdc_comm = UDI_CDC_COMM_DESC_0, \ + .udi_cdc_data = UDI_CDC_DATA_DESC_0_FS, \ + ... + #define UDI_COMPOSITE_DESC_HS \ + .udi_cdc_iad = UDI_CDC_IAD_DESC_0, \ + .udi_cdc_comm = UDI_CDC_COMM_DESC_0, \ + .udi_cdc_data = UDI_CDC_DATA_DESC_0_HS, \ + ... + #define UDI_COMPOSITE_API \ + &udi_api_cdc_comm, \ + &udi_api_cdc_data, \ + ... +\endcode + * + * \subsection udi_cdc_use_case_composite_usage_flow Workflow + * -# Ensure that conf_usb.h is available and contains the following parameters + * required for a USB composite device configuration: + * - \code // Endpoint control size, This must be: + // - 8, 16, 32 or 64 for full speed device (8 is recommended to save RAM) + // - 64 for a high speed device + #define USB_DEVICE_EP_CTRL_SIZE 64 + // Total Number of interfaces on this USB device. + // Add 2 for CDC. + #define USB_DEVICE_NB_INTERFACE (X+2) + // Total number of endpoints on this USB device. + // This must include each endpoint for each interface. + // Add 3 for CDC. + #define USB_DEVICE_MAX_EP (X+3) \endcode + * -# Ensure that conf_usb.h contains the description of + * composite device: + * - \code // The endpoint numbers chosen by you for the CDC. + // The endpoint numbers starting from 1. + #define UDI_CDC_DATA_EP_IN_0 (1 | USB_EP_DIR_IN) // TX + #define UDI_CDC_DATA_EP_OUT_0 (2 | USB_EP_DIR_OUT) // RX + #define UDI_CDC_COMM_EP_0 (3 | USB_EP_DIR_IN) // Notify endpoint + // The interface index of an interface starting from 0 + #define UDI_CDC_COMM_IFACE_NUMBER_0 X+0 + #define UDI_CDC_DATA_IFACE_NUMBER_0 X+1 \endcode + * -# Ensure that conf_usb.h contains the following parameters + * required for a USB composite device configuration: + * - \code // USB Interfaces descriptor structure + #define UDI_COMPOSITE_DESC_T \ + ... + usb_iad_desc_t udi_cdc_iad; \ + udi_cdc_comm_desc_t udi_cdc_comm; \ + udi_cdc_data_desc_t udi_cdc_data; \ + ... + // USB Interfaces descriptor value for Full Speed + #define UDI_COMPOSITE_DESC_FS \ + ... + .udi_cdc_iad = UDI_CDC_IAD_DESC_0, \ + .udi_cdc_comm = UDI_CDC_COMM_DESC_0, \ + .udi_cdc_data = UDI_CDC_DATA_DESC_0_FS, \ + ... + // USB Interfaces descriptor value for High Speed + #define UDI_COMPOSITE_DESC_HS \ + ... + .udi_cdc_iad = UDI_CDC_IAD_DESC_0, \ + .udi_cdc_comm = UDI_CDC_COMM_DESC_0, \ + .udi_cdc_data = UDI_CDC_DATA_DESC_0_HS, \ + ... + // USB Interface APIs + #define UDI_COMPOSITE_API \ + ... + &udi_api_cdc_comm, \ + &udi_api_cdc_data, \ + ... \endcode + * - \note The descriptors order given in the four lists above must be the + * same as the order defined by all interface indexes. The interface index + * orders are defined through UDI_X_IFACE_NUMBER defines.\n + * Also, the CDC requires a USB Interface Association Descriptor (IAD) for + * composite device. + */ + +#ifdef __cplusplus +} +#endif +#endif // _UDI_CDC_H_ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/class/cdc/device/udi_cdc_conf.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/class/cdc/device/udi_cdc_conf.h new file mode 100755 index 0000000..bcb3a65 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/class/cdc/device/udi_cdc_conf.h @@ -0,0 +1,152 @@ +/** + * \file + * + * \brief Default CDC configuration for a USB Device with a single interface + * + * Copyright (c) 2009 - 2013 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _UDI_CDC_CONF_H_ +#define _UDI_CDC_CONF_H_ + +#include "usb_protocol_cdc.h" +#include "conf_usb.h" + +#ifndef UDI_CDC_PORT_NB +# define UDI_CDC_PORT_NB 1 +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \addtogroup udi_cdc_group_single_desc + * @{ + */ + +//! Control endpoint size (Endpoint 0) +#define USB_DEVICE_EP_CTRL_SIZE 64 + +#if XMEGA +/** + * \name Endpoint configuration on XMEGA + * The XMEGA supports a IN and OUT endpoint with the same number endpoint, + * thus XMEGA can support up to 7 CDC interfaces. + */ +//@{ +#define UDI_CDC_DATA_EP_IN_0 ( 1 | USB_EP_DIR_IN) // TX +#define UDI_CDC_DATA_EP_OUT_0 ( 2 | USB_EP_DIR_OUT) // RX +#define UDI_CDC_COMM_EP_0 ( 2 | USB_EP_DIR_IN) // Notify endpoint +#define UDI_CDC_DATA_EP_IN_1 ( 3 | USB_EP_DIR_IN) // TX +#define UDI_CDC_DATA_EP_OUT_1 ( 4 | USB_EP_DIR_OUT) // RX +#define UDI_CDC_COMM_EP_1 ( 4 | USB_EP_DIR_IN) // Notify endpoint +#define UDI_CDC_DATA_EP_IN_2 ( 5 | USB_EP_DIR_IN) // TX +#define UDI_CDC_DATA_EP_OUT_2 ( 6 | USB_EP_DIR_OUT) // RX +#define UDI_CDC_COMM_EP_2 ( 6 | USB_EP_DIR_IN) // Notify endpoint +#define UDI_CDC_DATA_EP_IN_3 ( 7 | USB_EP_DIR_IN) // TX +#define UDI_CDC_DATA_EP_OUT_3 ( 8 | USB_EP_DIR_OUT) // RX +#define UDI_CDC_COMM_EP_3 ( 8 | USB_EP_DIR_IN) // Notify endpoint +#define UDI_CDC_DATA_EP_IN_4 ( 9 | USB_EP_DIR_IN) // TX +#define UDI_CDC_DATA_EP_OUT_4 (10 | USB_EP_DIR_OUT) // RX +#define UDI_CDC_COMM_EP_4 (10 | USB_EP_DIR_IN) // Notify endpoint +#define UDI_CDC_DATA_EP_IN_5 (11 | USB_EP_DIR_IN) // TX +#define UDI_CDC_DATA_EP_OUT_5 (12 | USB_EP_DIR_OUT) // RX +#define UDI_CDC_COMM_EP_5 (12 | USB_EP_DIR_IN) // Notify endpoint +#define UDI_CDC_DATA_EP_IN_6 (13 | USB_EP_DIR_IN) // TX +#define UDI_CDC_DATA_EP_OUT_6 (14 | USB_EP_DIR_OUT) // RX +#define UDI_CDC_COMM_EP_6 (14 | USB_EP_DIR_IN) // Notify endpoint +//! 2 endpoints numbers used per CDC interface +#define USB_DEVICE_MAX_EP (2*UDI_CDC_PORT_NB) +//@} + +#else + +/** + * \name Default endpoint configuration + * The USBB, UDP, UDPHS and UOTGHS interfaces can support up to 2 CDC interfaces. + */ +//@{ +# if UDI_CDC_PORT_NB > 2 +# error USBB, UDP, UDPHS and UOTGHS interfaces have not enought endpoints. +# endif +#define UDI_CDC_DATA_EP_IN_0 (1 | USB_EP_DIR_IN) // TX +#define UDI_CDC_DATA_EP_OUT_0 (2 | USB_EP_DIR_OUT) // RX +#define UDI_CDC_COMM_EP_0 (3 | USB_EP_DIR_IN) // Notify endpoint +# if SAM3U + /* For 3U max endpoint size of 4 is 64, use 5 and 6 as bulk tx and rx */ +# define UDI_CDC_DATA_EP_IN_1 (6 | USB_EP_DIR_IN) // TX +# define UDI_CDC_DATA_EP_OUT_1 (5 | USB_EP_DIR_OUT) // RX +# define UDI_CDC_COMM_EP_1 (4 | USB_EP_DIR_IN) // Notify +# else +# define UDI_CDC_DATA_EP_IN_1 (4 | USB_EP_DIR_IN) // TX +# define UDI_CDC_DATA_EP_OUT_1 (5 | USB_EP_DIR_OUT) // RX +# define UDI_CDC_COMM_EP_1 (6 | USB_EP_DIR_IN) // Notify +# endif +//! 3 endpoints used per CDC interface +#define USB_DEVICE_MAX_EP (3*UDI_CDC_PORT_NB) +//@} + +#endif + +/** + * \name Default Interface numbers + */ +//@{ +#define UDI_CDC_COMM_IFACE_NUMBER_0 0 +#define UDI_CDC_DATA_IFACE_NUMBER_0 1 +#define UDI_CDC_COMM_IFACE_NUMBER_1 2 +#define UDI_CDC_DATA_IFACE_NUMBER_1 3 +#define UDI_CDC_COMM_IFACE_NUMBER_2 4 +#define UDI_CDC_DATA_IFACE_NUMBER_2 5 +#define UDI_CDC_COMM_IFACE_NUMBER_3 6 +#define UDI_CDC_DATA_IFACE_NUMBER_3 7 +#define UDI_CDC_COMM_IFACE_NUMBER_4 8 +#define UDI_CDC_DATA_IFACE_NUMBER_4 9 +#define UDI_CDC_COMM_IFACE_NUMBER_5 10 +#define UDI_CDC_DATA_IFACE_NUMBER_5 11 +#define UDI_CDC_COMM_IFACE_NUMBER_6 12 +#define UDI_CDC_DATA_IFACE_NUMBER_6 13 +//@} + +//@} + +#ifdef __cplusplus +} +#endif +#endif // _UDI_CDC_CONF_H_ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/class/cdc/device/udi_cdc_desc.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/class/cdc/device/udi_cdc_desc.c new file mode 100755 index 0000000..92a7e25 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/class/cdc/device/udi_cdc_desc.c @@ -0,0 +1,251 @@ +/** + * \file + * + * \brief Default descriptors for a USB Device with a single interface CDC + * + * Copyright (c) 2009-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include "conf_usb.h" +#include "udd.h" +#include "udc_desc.h" +#include "udi_cdc.h" + + +/** + * \defgroup udi_cdc_group_single_desc USB device descriptors for a single interface + * + * The following structures provide the USB device descriptors required for + * USB Device with a single interface CDC. + * + * It is ready to use and do not require more definition. + * + * @{ + */ + +//! Two interfaces for a CDC device +#define USB_DEVICE_NB_INTERFACE (2*UDI_CDC_PORT_NB) + +#ifdef USB_DEVICE_LPM_SUPPORT +# define USB_VERSION USB_V2_1 +#else +# define USB_VERSION USB_V2_0 +#endif + +//! USB Device Descriptor +COMPILER_WORD_ALIGNED +UDC_DESC_STORAGE usb_dev_desc_t udc_device_desc = { + .bLength = sizeof(usb_dev_desc_t), + .bDescriptorType = USB_DT_DEVICE, + .bcdUSB = LE16(USB_VERSION), +#if UDI_CDC_PORT_NB > 1 + .bDeviceClass = 0, +#else + .bDeviceClass = CDC_CLASS_DEVICE, +#endif + .bDeviceSubClass = 0, + .bDeviceProtocol = 0, + .bMaxPacketSize0 = USB_DEVICE_EP_CTRL_SIZE, + .idVendor = LE16(USB_DEVICE_VENDOR_ID), + .idProduct = LE16(USB_DEVICE_PRODUCT_ID), + .bcdDevice = LE16((USB_DEVICE_MAJOR_VERSION << 8) + | USB_DEVICE_MINOR_VERSION), +#ifdef USB_DEVICE_MANUFACTURE_NAME + .iManufacturer = 1, +#else + .iManufacturer = 0, // No manufacture string +#endif +#ifdef USB_DEVICE_PRODUCT_NAME + .iProduct = 2, +#else + .iProduct = 0, // No product string +#endif +#ifdef USB_DEVICE_SERIAL_NAME + .iSerialNumber = 3, +#else + .iSerialNumber = 0, // No serial string +#endif + .bNumConfigurations = 1 +}; + + +#ifdef USB_DEVICE_HS_SUPPORT +//! USB Device Qualifier Descriptor for HS +COMPILER_WORD_ALIGNED +UDC_DESC_STORAGE usb_dev_qual_desc_t udc_device_qual = { + .bLength = sizeof(usb_dev_qual_desc_t), + .bDescriptorType = USB_DT_DEVICE_QUALIFIER, + .bcdUSB = LE16(USB_VERSION), +#if UDI_CDC_PORT_NB > 1 + .bDeviceClass = 0, +#else + .bDeviceClass = CDC_CLASS_DEVICE, +#endif + .bDeviceSubClass = 0, + .bDeviceProtocol = 0, + .bMaxPacketSize0 = USB_DEVICE_EP_CTRL_SIZE, + .bNumConfigurations = 1 +}; +#endif + +#ifdef USB_DEVICE_LPM_SUPPORT +//! USB Device Qualifier Descriptor +COMPILER_WORD_ALIGNED +UDC_DESC_STORAGE usb_dev_lpm_desc_t udc_device_lpm = { + .bos.bLength = sizeof(usb_dev_bos_desc_t), + .bos.bDescriptorType = USB_DT_BOS, + .bos.wTotalLength = LE16(sizeof(usb_dev_bos_desc_t) + sizeof(usb_dev_capa_ext_desc_t)), + .bos.bNumDeviceCaps = 1, + .capa_ext.bLength = sizeof(usb_dev_capa_ext_desc_t), + .capa_ext.bDescriptorType = USB_DT_DEVICE_CAPABILITY, + .capa_ext.bDevCapabilityType = USB_DC_USB20_EXTENSION, + .capa_ext.bmAttributes = USB_DC_EXT_LPM, // alfran: modified to fix ASF USB 3.0 incompatibility +}; +#endif + +//! Structure for USB Device Configuration Descriptor +COMPILER_PACK_SET(1) +typedef struct { + usb_conf_desc_t conf; +#if UDI_CDC_PORT_NB == 1 + udi_cdc_comm_desc_t udi_cdc_comm_0; + udi_cdc_data_desc_t udi_cdc_data_0; +#else +# define UDI_CDC_DESC_STRUCTURE(index, unused) \ + usb_iad_desc_t udi_cdc_iad_##index; \ + udi_cdc_comm_desc_t udi_cdc_comm_##index; \ + udi_cdc_data_desc_t udi_cdc_data_##index; + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_DESC_STRUCTURE, ~) +# undef UDI_CDC_DESC_STRUCTURE +#endif +} udc_desc_t; +COMPILER_PACK_RESET() + +//! USB Device Configuration Descriptor filled for full and high speed +COMPILER_WORD_ALIGNED +UDC_DESC_STORAGE udc_desc_t udc_desc_fs = { + .conf.bLength = sizeof(usb_conf_desc_t), + .conf.bDescriptorType = USB_DT_CONFIGURATION, + .conf.wTotalLength = LE16(sizeof(udc_desc_t)), + .conf.bNumInterfaces = USB_DEVICE_NB_INTERFACE, + .conf.bConfigurationValue = 1, + .conf.iConfiguration = 0, + .conf.bmAttributes = USB_CONFIG_ATTR_MUST_SET | USB_DEVICE_ATTR, + .conf.bMaxPower = USB_CONFIG_MAX_POWER(USB_DEVICE_POWER), +#if UDI_CDC_PORT_NB == 1 + .udi_cdc_comm_0 = UDI_CDC_COMM_DESC_0, + .udi_cdc_data_0 = UDI_CDC_DATA_DESC_0_FS, +#else +# define UDI_CDC_DESC_FS(index, unused) \ + .udi_cdc_iad_##index = UDI_CDC_IAD_DESC_##index,\ + .udi_cdc_comm_##index = UDI_CDC_COMM_DESC_##index,\ + .udi_cdc_data_##index = UDI_CDC_DATA_DESC_##index##_FS, + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_DESC_FS, ~) +# undef UDI_CDC_DESC_FS +#endif +}; + +#ifdef USB_DEVICE_HS_SUPPORT +COMPILER_WORD_ALIGNED +UDC_DESC_STORAGE udc_desc_t udc_desc_hs = { + .conf.bLength = sizeof(usb_conf_desc_t), + .conf.bDescriptorType = USB_DT_CONFIGURATION, + .conf.wTotalLength = LE16(sizeof(udc_desc_t)), + .conf.bNumInterfaces = USB_DEVICE_NB_INTERFACE, + .conf.bConfigurationValue = 1, + .conf.iConfiguration = 0, + .conf.bmAttributes = USB_CONFIG_ATTR_MUST_SET | USB_DEVICE_ATTR, + .conf.bMaxPower = USB_CONFIG_MAX_POWER(USB_DEVICE_POWER), +#if UDI_CDC_PORT_NB == 1 + .udi_cdc_comm_0 = UDI_CDC_COMM_DESC_0, + .udi_cdc_data_0 = UDI_CDC_DATA_DESC_0_HS, +#else +# define UDI_CDC_DESC_HS(index, unused) \ + .udi_cdc_iad_##index = UDI_CDC_IAD_DESC_##index, \ + .udi_cdc_comm_##index = UDI_CDC_COMM_DESC_##index, \ + .udi_cdc_data_##index = UDI_CDC_DATA_DESC_##index##_HS, + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_DESC_HS, ~) +# undef UDI_CDC_DESC_HS +#endif +}; +#endif + +/** + * \name UDC structures which content all USB Device definitions + */ +//@{ + +//! Associate an UDI for each USB interface +UDC_DESC_STORAGE udi_api_t *udi_apis[USB_DEVICE_NB_INTERFACE] = { +# define UDI_CDC_API(index, unused) \ + &udi_api_cdc_comm, \ + &udi_api_cdc_data, + MREPEAT(UDI_CDC_PORT_NB, UDI_CDC_API, ~) +# undef UDI_CDC_API +}; + +//! Add UDI with USB Descriptors FS & HS +UDC_DESC_STORAGE udc_config_speed_t udc_config_fs[1] = { { + .desc = (usb_conf_desc_t UDC_DESC_STORAGE*)&udc_desc_fs, + .udi_apis = udi_apis, +}}; +#ifdef USB_DEVICE_HS_SUPPORT +UDC_DESC_STORAGE udc_config_speed_t udc_config_hs[1] = { { + .desc = (usb_conf_desc_t UDC_DESC_STORAGE*)&udc_desc_hs, + .udi_apis = udi_apis, +}}; +#endif + +//! Add all information about USB Device in global structure for UDC +UDC_DESC_STORAGE udc_config_t udc_config = { + .confdev_lsfs = &udc_device_desc, + .conf_lsfs = udc_config_fs, +#ifdef USB_DEVICE_HS_SUPPORT + .confdev_hs = &udc_device_desc, + .qualifier = &udc_device_qual, + .conf_hs = udc_config_hs, +#endif +#ifdef USB_DEVICE_LPM_SUPPORT + .conf_bos = &udc_device_lpm.bos, +#else + .conf_bos = NULL, +#endif +}; + +//@} +//@} diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/class/cdc/usb_protocol_cdc.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/class/cdc/usb_protocol_cdc.h new file mode 100755 index 0000000..ec6235a --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/class/cdc/usb_protocol_cdc.h @@ -0,0 +1,315 @@ +/** + * \file + * + * \brief USB Communication Device Class (CDC) protocol definitions + * + * Copyright (c) 2009-2012 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef _USB_PROTOCOL_CDC_H_ +#define _USB_PROTOCOL_CDC_H_ + +#include "compiler.h" + +/** + * \ingroup usb_protocol_group + * \defgroup cdc_protocol_group Communication Device Class Definitions + * @{ + */ + +/** + * \name Possible values of class + */ +//@{ +#define CDC_CLASS_DEVICE 0x02 //!< USB Communication Device Class +#define CDC_CLASS_COMM 0x02 //!< CDC Communication Class Interface +#define CDC_CLASS_DATA 0x0A //!< CDC Data Class Interface +//@} + +//! \name USB CDC Subclass IDs +//@{ +#define CDC_SUBCLASS_DLCM 0x01 //!< Direct Line Control Model +#define CDC_SUBCLASS_ACM 0x02 //!< Abstract Control Model +#define CDC_SUBCLASS_TCM 0x03 //!< Telephone Control Model +#define CDC_SUBCLASS_MCCM 0x04 //!< Multi-Channel Control Model +#define CDC_SUBCLASS_CCM 0x05 //!< CAPI Control Model +#define CDC_SUBCLASS_ETH 0x06 //!< Ethernet Networking Control Model +#define CDC_SUBCLASS_ATM 0x07 //!< ATM Networking Control Model +//@} + +//! \name USB CDC Communication Interface Protocol IDs +//@{ +#define CDC_PROTOCOL_V25TER 0x01 //!< Common AT commands +//@} + +//! \name USB CDC Data Interface Protocol IDs +//@{ +#define CDC_PROTOCOL_I430 0x30 //!< ISDN BRI +#define CDC_PROTOCOL_HDLC 0x31 //!< HDLC +#define CDC_PROTOCOL_TRANS 0x32 //!< Transparent +#define CDC_PROTOCOL_Q921M 0x50 //!< Q.921 management protocol +#define CDC_PROTOCOL_Q921 0x51 //!< Q.931 [sic] Data link protocol +#define CDC_PROTOCOL_Q921TM 0x52 //!< Q.921 TEI-multiplexor +#define CDC_PROTOCOL_V42BIS 0x90 //!< Data compression procedures +#define CDC_PROTOCOL_Q931 0x91 //!< Euro-ISDN protocol control +#define CDC_PROTOCOL_V120 0x92 //!< V.24 rate adaption to ISDN +#define CDC_PROTOCOL_CAPI20 0x93 //!< CAPI Commands +#define CDC_PROTOCOL_HOST 0xFD //!< Host based driver +/** + * \brief Describes the Protocol Unit Functional Descriptors [sic] + * on Communication Class Interface + */ +#define CDC_PROTOCOL_PUFD 0xFE +//@} + +//! \name USB CDC Functional Descriptor Types +//@{ +#define CDC_CS_INTERFACE 0x24 //!< Interface Functional Descriptor +#define CDC_CS_ENDPOINT 0x25 //!< Endpoint Functional Descriptor +//@} + +//! \name USB CDC Functional Descriptor Subtypes +//@{ +#define CDC_SCS_HEADER 0x00 //!< Header Functional Descriptor +#define CDC_SCS_CALL_MGMT 0x01 //!< Call Management +#define CDC_SCS_ACM 0x02 //!< Abstract Control Management +#define CDC_SCS_UNION 0x06 //!< Union Functional Descriptor +//@} + +//! \name USB CDC Request IDs +//@{ +#define USB_REQ_CDC_SEND_ENCAPSULATED_COMMAND 0x00 +#define USB_REQ_CDC_GET_ENCAPSULATED_RESPONSE 0x01 +#define USB_REQ_CDC_SET_COMM_FEATURE 0x02 +#define USB_REQ_CDC_GET_COMM_FEATURE 0x03 +#define USB_REQ_CDC_CLEAR_COMM_FEATURE 0x04 +#define USB_REQ_CDC_SET_AUX_LINE_STATE 0x10 +#define USB_REQ_CDC_SET_HOOK_STATE 0x11 +#define USB_REQ_CDC_PULSE_SETUP 0x12 +#define USB_REQ_CDC_SEND_PULSE 0x13 +#define USB_REQ_CDC_SET_PULSE_TIME 0x14 +#define USB_REQ_CDC_RING_AUX_JACK 0x15 +#define USB_REQ_CDC_SET_LINE_CODING 0x20 +#define USB_REQ_CDC_GET_LINE_CODING 0x21 +#define USB_REQ_CDC_SET_CONTROL_LINE_STATE 0x22 +#define USB_REQ_CDC_SEND_BREAK 0x23 +#define USB_REQ_CDC_SET_RINGER_PARMS 0x30 +#define USB_REQ_CDC_GET_RINGER_PARMS 0x31 +#define USB_REQ_CDC_SET_OPERATION_PARMS 0x32 +#define USB_REQ_CDC_GET_OPERATION_PARMS 0x33 +#define USB_REQ_CDC_SET_LINE_PARMS 0x34 +#define USB_REQ_CDC_GET_LINE_PARMS 0x35 +#define USB_REQ_CDC_DIAL_DIGITS 0x36 +#define USB_REQ_CDC_SET_UNIT_PARAMETER 0x37 +#define USB_REQ_CDC_GET_UNIT_PARAMETER 0x38 +#define USB_REQ_CDC_CLEAR_UNIT_PARAMETER 0x39 +#define USB_REQ_CDC_GET_PROFILE 0x3A +#define USB_REQ_CDC_SET_ETHERNET_MULTICAST_FILTERS 0x40 +#define USB_REQ_CDC_SET_ETHERNET_POWER_MANAGEMENT_PATTERNFILTER 0x41 +#define USB_REQ_CDC_GET_ETHERNET_POWER_MANAGEMENT_PATTERNFILTER 0x42 +#define USB_REQ_CDC_SET_ETHERNET_PACKET_FILTER 0x43 +#define USB_REQ_CDC_GET_ETHERNET_STATISTIC 0x44 +#define USB_REQ_CDC_SET_ATM_DATA_FORMAT 0x50 +#define USB_REQ_CDC_GET_ATM_DEVICE_STATISTICS 0x51 +#define USB_REQ_CDC_SET_ATM_DEFAULT_VC 0x52 +#define USB_REQ_CDC_GET_ATM_VC_STATISTICS 0x53 +// Added bNotification codes according cdc spec 1.1 chapter 6.3 +#define USB_REQ_CDC_NOTIFY_RING_DETECT 0x09 +#define USB_REQ_CDC_NOTIFY_SERIAL_STATE 0x20 +#define USB_REQ_CDC_NOTIFY_CALL_STATE_CHANGE 0x28 +#define USB_REQ_CDC_NOTIFY_LINE_STATE_CHANGE 0x29 +//@} + +/* + * Need to pack structures tightly, or the compiler might insert padding + * and violate the spec-mandated layout. + */ +COMPILER_PACK_SET(1) + +//! \name USB CDC Descriptors +//@{ + + +//! CDC Header Functional Descriptor +typedef struct { + uint8_t bFunctionLength; + uint8_t bDescriptorType; + uint8_t bDescriptorSubtype; + le16_t bcdCDC; +} usb_cdc_hdr_desc_t; + +//! CDC Call Management Functional Descriptor +typedef struct { + uint8_t bFunctionLength; + uint8_t bDescriptorType; + uint8_t bDescriptorSubtype; + uint8_t bmCapabilities; + uint8_t bDataInterface; +} usb_cdc_call_mgmt_desc_t; + +//! CDC ACM Functional Descriptor +typedef struct { + uint8_t bFunctionLength; + uint8_t bDescriptorType; + uint8_t bDescriptorSubtype; + uint8_t bmCapabilities; +} usb_cdc_acm_desc_t; + +//! CDC Union Functional Descriptor +typedef struct { + uint8_t bFunctionLength; + uint8_t bDescriptorType; + uint8_t bDescriptorSubtype; + uint8_t bMasterInterface; + uint8_t bSlaveInterface0; +} usb_cdc_union_desc_t; + + +//! \name USB CDC Call Management Capabilities +//@{ +//! Device handles call management itself +#define CDC_CALL_MGMT_SUPPORTED (1 << 0) +//! Device can send/receive call management info over a Data Class interface +#define CDC_CALL_MGMT_OVER_DCI (1 << 1) +//@} + +//! \name USB CDC ACM Capabilities +//@{ +//! Device supports the request combination of +//! Set_Comm_Feature, Clear_Comm_Feature, and Get_Comm_Feature. +#define CDC_ACM_SUPPORT_FEATURE_REQUESTS (1 << 0) +//! Device supports the request combination of +//! Set_Line_Coding, Set_Control_Line_State, Get_Line_Coding, +//! and the notification Serial_State. +#define CDC_ACM_SUPPORT_LINE_REQUESTS (1 << 1) +//! Device supports the request Send_Break +#define CDC_ACM_SUPPORT_SENDBREAK_REQUESTS (1 << 2) +//! Device supports the notification Network_Connection. +#define CDC_ACM_SUPPORT_NOTIFY_REQUESTS (1 << 3) +//@} +//@} + +//! \name USB CDC line control +//@{ + +//! \name USB CDC line coding +//@{ +//! Line Coding structure +typedef struct { + le32_t dwDTERate; + uint8_t bCharFormat; + uint8_t bParityType; + uint8_t bDataBits; +} usb_cdc_line_coding_t; +//! Possible values of bCharFormat +enum cdc_char_format { + CDC_STOP_BITS_1 = 0, //!< 1 stop bit + CDC_STOP_BITS_1_5 = 1, //!< 1.5 stop bits + CDC_STOP_BITS_2 = 2, //!< 2 stop bits +}; +//! Possible values of bParityType +enum cdc_parity { + CDC_PAR_NONE = 0, //!< No parity + CDC_PAR_ODD = 1, //!< Odd parity + CDC_PAR_EVEN = 2, //!< Even parity + CDC_PAR_MARK = 3, //!< Parity forced to 0 (space) + CDC_PAR_SPACE = 4, //!< Parity forced to 1 (mark) +}; +//@} + +//! \name USB CDC control signals +//! spec 1.1 chapter 6.2.14 +//@{ + +//! Control signal structure +typedef struct { + uint16_t value; +} usb_cdc_control_signal_t; + +//! \name Possible values in usb_cdc_control_signal_t +//@{ +//! Carrier control for half duplex modems. +//! This signal corresponds to V.24 signal 105 and RS-232 signal RTS. +//! The device ignores the value of this bit +//! when operating in full duplex mode. +#define CDC_CTRL_SIGNAL_ACTIVATE_CARRIER (1 << 1) +//! Indicates to DCE if DTE is present or not. +//! This signal corresponds to V.24 signal 108/2 and RS-232 signal DTR. +#define CDC_CTRL_SIGNAL_DTE_PRESENT (1 << 0) +//@} +//@} + + +//! \name USB CDC notification message +//@{ + +typedef struct { + uint8_t bmRequestType; + uint8_t bNotification; + le16_t wValue; + le16_t wIndex; + le16_t wLength; +} usb_cdc_notify_msg_t; + +//! \name USB CDC serial state +//@{* + +//! Hardware handshake support (cdc spec 1.1 chapter 6.3.5) +typedef struct { + usb_cdc_notify_msg_t header; + le16_t value; +} usb_cdc_notify_serial_state_t; + +//! \name Possible values in usb_cdc_notify_serial_state_t +//@{ +#define CDC_SERIAL_STATE_DCD CPU_TO_LE16((1<<0)) +#define CDC_SERIAL_STATE_DSR CPU_TO_LE16((1<<1)) +#define CDC_SERIAL_STATE_BREAK CPU_TO_LE16((1<<2)) +#define CDC_SERIAL_STATE_RING CPU_TO_LE16((1<<3)) +#define CDC_SERIAL_STATE_FRAMING CPU_TO_LE16((1<<4)) +#define CDC_SERIAL_STATE_PARITY CPU_TO_LE16((1<<5)) +#define CDC_SERIAL_STATE_OVERRUN CPU_TO_LE16((1<<6)) +//@} +//! @} + +//! @} + +COMPILER_PACK_RESET() + +//! @} + +#endif // _USB_PROTOCOL_CDC_H_ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/udc/udc.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/udc/udc.c new file mode 100755 index 0000000..461a342 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/udc/udc.c @@ -0,0 +1,1138 @@ +/** + * \file + * + * \brief USB Device Controller (UDC) + * + * Copyright (c) 2009 - 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include "conf_usb.h" +#include "usb_protocol.h" +#include "udd.h" +#include "udc_desc.h" +#include "udi.h" +#include "udc.h" + +/** + * \ingroup udc_group + * \defgroup udc_group_interne Implementation of UDC + * + * Internal implementation + * @{ + */ + +//! \name Internal variables to manage the USB device +//! @{ + +//! Device status state (see enum usb_device_status in usb_protocol.h) +static le16_t udc_device_status; + +//! Device Configuration number selected by the USB host +static uint8_t udc_num_configuration = 0; + +//! Pointer on the selected speed device configuration +static udc_config_speed_t UDC_DESC_STORAGE *udc_ptr_conf; + +//! Pointer on interface descriptor used by SETUP request. +static usb_iface_desc_t UDC_DESC_STORAGE *udc_ptr_iface; + +//! @} + + +//! \name Internal structure to store the USB device main strings +//! @{ + +/** + * \brief Language ID of USB device (US ID by default) + */ +COMPILER_WORD_ALIGNED +static UDC_DESC_STORAGE usb_str_lgid_desc_t udc_string_desc_languageid = { + .desc.bLength = sizeof(usb_str_lgid_desc_t), + .desc.bDescriptorType = USB_DT_STRING, + .string = {LE16(USB_LANGID_EN_US)} +}; + +/** + * \brief USB device manufacture name storage + * String is allocated only if USB_DEVICE_MANUFACTURE_NAME is declared + * by usb application configuration + */ +#ifdef USB_DEVICE_MANUFACTURE_NAME +static uint8_t udc_string_manufacturer_name[] = USB_DEVICE_MANUFACTURE_NAME; +# define USB_DEVICE_MANUFACTURE_NAME_SIZE \ + (sizeof(udc_string_manufacturer_name)-1) +#else +# define USB_DEVICE_MANUFACTURE_NAME_SIZE 0 +#endif + +/** + * \brief USB device product name storage + * String is allocated only if USB_DEVICE_PRODUCT_NAME is declared + * by usb application configuration + */ +#ifdef USB_DEVICE_PRODUCT_NAME +static uint8_t udc_string_product_name[] = USB_DEVICE_PRODUCT_NAME; +# define USB_DEVICE_PRODUCT_NAME_SIZE (sizeof(udc_string_product_name)-1) +#else +# define USB_DEVICE_PRODUCT_NAME_SIZE 0 +#endif + +/** + * \brief Get USB device serial number + * + * Use the define USB_DEVICE_SERIAL_NAME to set static serial number. + * + * For dynamic serial number set the define USB_DEVICE_GET_SERIAL_NAME_POINTER + * to a suitable pointer. This will also require the serial number length + * define USB_DEVICE_GET_SERIAL_NAME_LENGTH. + */ +#if defined USB_DEVICE_GET_SERIAL_NAME_POINTER + static const uint8_t *udc_get_string_serial_name(void) + { + return (const uint8_t *)USB_DEVICE_GET_SERIAL_NAME_POINTER; + } +# define USB_DEVICE_SERIAL_NAME_SIZE \ + USB_DEVICE_GET_SERIAL_NAME_LENGTH +#elif defined USB_DEVICE_SERIAL_NAME + static const uint8_t *udc_get_string_serial_name(void) + { + return (const uint8_t *)USB_DEVICE_SERIAL_NAME; + } +# define USB_DEVICE_SERIAL_NAME_SIZE \ + (sizeof(USB_DEVICE_SERIAL_NAME)-1) +#else +# define USB_DEVICE_SERIAL_NAME_SIZE 0 +#endif + +/** + * \brief USB device string descriptor + * Structure used to transfer ASCII strings to USB String descriptor structure. + */ +struct udc_string_desc_t { + usb_str_desc_t header; + le16_t string[Max(Max(USB_DEVICE_MANUFACTURE_NAME_SIZE, \ + USB_DEVICE_PRODUCT_NAME_SIZE), USB_DEVICE_SERIAL_NAME_SIZE)]; +}; +COMPILER_WORD_ALIGNED +static UDC_DESC_STORAGE struct udc_string_desc_t udc_string_desc = { + .header.bDescriptorType = USB_DT_STRING +}; +//! @} + +usb_iface_desc_t UDC_DESC_STORAGE *udc_get_interface_desc(void) +{ + return udc_ptr_iface; +} + +/** + * \brief Returns a value to check the end of USB Configuration descriptor + * + * \return address after the last byte of USB Configuration descriptor + */ +static usb_conf_desc_t UDC_DESC_STORAGE *udc_get_eof_conf(void) +{ + return (UDC_DESC_STORAGE usb_conf_desc_t *) ((uint8_t *) + udc_ptr_conf->desc + + le16_to_cpu(udc_ptr_conf->desc->wTotalLength)); +} + +#if (0!=USB_DEVICE_MAX_EP) +/** + * \brief Search specific descriptor in global interface descriptor + * + * \param desc Address of interface descriptor + * or previous specific descriptor found + * \param desc_id Descriptor ID to search + * + * \return address of specific descriptor found + * \return NULL if it is the end of global interface descriptor + */ +static usb_conf_desc_t UDC_DESC_STORAGE *udc_next_desc_in_iface(usb_conf_desc_t + UDC_DESC_STORAGE * desc, uint8_t desc_id) +{ + usb_conf_desc_t UDC_DESC_STORAGE *ptr_eof_desc; + + ptr_eof_desc = udc_get_eof_conf(); + // Go to next descriptor + desc = (UDC_DESC_STORAGE usb_conf_desc_t *) ((uint8_t *) desc + + desc->bLength); + // Check the end of configuration descriptor + while (ptr_eof_desc > desc) { + // If new interface descriptor is found, + // then it is the end of the current global interface descriptor + if (USB_DT_INTERFACE == desc->bDescriptorType) { + break; // End of global interface descriptor + } + if (desc_id == desc->bDescriptorType) { + return desc; // Specific descriptor found + } + // Go to next descriptor + desc = (UDC_DESC_STORAGE usb_conf_desc_t *) ((uint8_t *) desc + + desc->bLength); + } + return NULL; // No specific descriptor found +} +#endif + +/** + * \brief Search an interface descriptor + * This routine updates the internal pointer udc_ptr_iface. + * + * \param iface_num Interface number to find in Configuration Descriptor + * \param setting_num Setting number of interface to find + * + * \return 1 if found or 0 if not found + */ +static bool udc_update_iface_desc(uint8_t iface_num, uint8_t setting_num) +{ + usb_conf_desc_t UDC_DESC_STORAGE *ptr_end_desc; + + if (0 == udc_num_configuration) { + return false; + } + + if (iface_num >= udc_ptr_conf->desc->bNumInterfaces) { + return false; + } + + // Start at the beginning of configuration descriptor + udc_ptr_iface = (UDC_DESC_STORAGE usb_iface_desc_t *) + udc_ptr_conf->desc; + + // Check the end of configuration descriptor + ptr_end_desc = udc_get_eof_conf(); + while (ptr_end_desc > + (UDC_DESC_STORAGE usb_conf_desc_t *) udc_ptr_iface) { + if (USB_DT_INTERFACE == udc_ptr_iface->bDescriptorType) { + // A interface descriptor is found + // Check interface and alternate setting number + if ((iface_num == udc_ptr_iface->bInterfaceNumber) && + (setting_num == + udc_ptr_iface->bAlternateSetting)) { + return true; // Interface found + } + } + // Go to next descriptor + udc_ptr_iface = (UDC_DESC_STORAGE usb_iface_desc_t *) ( + (uint8_t *) udc_ptr_iface + + udc_ptr_iface->bLength); + } + return false; // Interface not found +} + +/** + * \brief Disables an usb device interface (UDI) + * This routine call the UDI corresponding to interface number + * + * \param iface_num Interface number to disable + * + * \return 1 if it is done or 0 if interface is not found + */ +static bool udc_iface_disable(uint8_t iface_num) +{ + udi_api_t UDC_DESC_STORAGE *udi_api; + + // Select first alternate setting of the interface + // to update udc_ptr_iface before call iface->getsetting() + if (!udc_update_iface_desc(iface_num, 0)) { + return false; + } + + // Select the interface with the current alternate setting + udi_api = udc_ptr_conf->udi_apis[iface_num]; + +#if (0!=USB_DEVICE_MAX_EP) + if (!udc_update_iface_desc(iface_num, udi_api->getsetting())) { + return false; + } + + // Start at the beginning of interface descriptor + { + usb_ep_desc_t UDC_DESC_STORAGE *ep_desc; + ep_desc = (UDC_DESC_STORAGE usb_ep_desc_t *) udc_ptr_iface; + while (1) { + // Search Endpoint descriptor included in global interface descriptor + ep_desc = (UDC_DESC_STORAGE usb_ep_desc_t *) + udc_next_desc_in_iface((UDC_DESC_STORAGE + usb_conf_desc_t *) + ep_desc, USB_DT_ENDPOINT); + if (NULL == ep_desc) { + break; + } + // Free the endpoint used by the interface + udd_ep_free(ep_desc->bEndpointAddress); + } + } +#endif + + // Disable interface + udi_api->disable(); + return true; +} + +/** + * \brief Enables an usb device interface (UDI) + * This routine calls the UDI corresponding + * to the interface and setting number. + * + * \param iface_num Interface number to enable + * \param setting_num Setting number to enable + * + * \return 1 if it is done or 0 if interface is not found + */ +static bool udc_iface_enable(uint8_t iface_num, uint8_t setting_num) +{ + // Select the interface descriptor + if (!udc_update_iface_desc(iface_num, setting_num)) { + return false; + } + +#if (0!=USB_DEVICE_MAX_EP) + usb_ep_desc_t UDC_DESC_STORAGE *ep_desc; + + // Start at the beginning of the global interface descriptor + ep_desc = (UDC_DESC_STORAGE usb_ep_desc_t *) udc_ptr_iface; + while (1) { + // Search Endpoint descriptor included in the global interface descriptor + ep_desc = (UDC_DESC_STORAGE usb_ep_desc_t *) + udc_next_desc_in_iface((UDC_DESC_STORAGE + usb_conf_desc_t *) ep_desc, + USB_DT_ENDPOINT); + if (NULL == ep_desc) + break; + // Alloc the endpoint used by the interface + if (!udd_ep_alloc(ep_desc->bEndpointAddress, + ep_desc->bmAttributes, + le16_to_cpu + (ep_desc->wMaxPacketSize))) { + return false; + } + } +#endif + // Enable the interface + return udc_ptr_conf->udi_apis[iface_num]->enable(); +} + +/*! \brief Start the USB Device stack + */ +void udc_start(void) +{ + udd_enable(); +} + +/*! \brief Stop the USB Device stack + */ +void udc_stop(void) +{ + udd_disable(); + udc_reset(); +} + +/** + * \brief Reset the current configuration of the USB device, + * This routines can be called by UDD when a RESET on the USB line occurs. + */ +void udc_reset(void) +{ + uint8_t iface_num; + + if (udc_num_configuration) { + for (iface_num = 0; + iface_num < udc_ptr_conf->desc->bNumInterfaces; + iface_num++) { + udc_iface_disable(iface_num); + } + } + udc_num_configuration = 0; +#if (USB_CONFIG_ATTR_REMOTE_WAKEUP \ + == (USB_DEVICE_ATTR & USB_CONFIG_ATTR_REMOTE_WAKEUP)) + if (CPU_TO_LE16(USB_DEV_STATUS_REMOTEWAKEUP) & udc_device_status) { + // Remote wakeup is enabled then disable it + UDC_REMOTEWAKEUP_DISABLE(); + } +#endif + udc_device_status = +#if (USB_DEVICE_ATTR & USB_CONFIG_ATTR_SELF_POWERED) + CPU_TO_LE16(USB_DEV_STATUS_SELF_POWERED); +#else + CPU_TO_LE16(USB_DEV_STATUS_BUS_POWERED); +#endif +} + +void udc_sof_notify(void) +{ + uint8_t iface_num; + + if (udc_num_configuration) { + for (iface_num = 0; + iface_num < udc_ptr_conf->desc->bNumInterfaces; + iface_num++) { + if (udc_ptr_conf->udi_apis[iface_num]->sof_notify != NULL) { + udc_ptr_conf->udi_apis[iface_num]->sof_notify(); + } + } + } +} + +/** + * \brief Standard device request to get device status + * + * \return true if success + */ +static bool udc_req_std_dev_get_status(void) +{ + if (udd_g_ctrlreq.req.wLength != sizeof(udc_device_status)) { + return false; + } + + udd_set_setup_payload( (uint8_t *) & udc_device_status, + sizeof(udc_device_status)); + return true; +} + +#if (0!=USB_DEVICE_MAX_EP) +/** + * \brief Standard endpoint request to get endpoint status + * + * \return true if success + */ +static bool udc_req_std_ep_get_status(void) +{ + static le16_t udc_ep_status; + + if (udd_g_ctrlreq.req.wLength != sizeof(udc_ep_status)) { + return false; + } + + udc_ep_status = udd_ep_is_halted(udd_g_ctrlreq.req. + wIndex & 0xFF) ? CPU_TO_LE16(USB_EP_STATUS_HALTED) : 0; + + udd_set_setup_payload( (uint8_t *) & udc_ep_status, + sizeof(udc_ep_status)); + return true; +} +#endif + +/** + * \brief Standard device request to change device status + * + * \return true if success + */ +static bool udc_req_std_dev_clear_feature(void) +{ + if (udd_g_ctrlreq.req.wLength) { + return false; + } + + if (udd_g_ctrlreq.req.wValue == USB_DEV_FEATURE_REMOTE_WAKEUP) { + udc_device_status &= CPU_TO_LE16(~(uint32_t)USB_DEV_STATUS_REMOTEWAKEUP); +#if (USB_CONFIG_ATTR_REMOTE_WAKEUP \ + == (USB_DEVICE_ATTR & USB_CONFIG_ATTR_REMOTE_WAKEUP)) + UDC_REMOTEWAKEUP_DISABLE(); +#endif + return true; + } + return false; +} + +#if (0!=USB_DEVICE_MAX_EP) +/** + * \brief Standard endpoint request to clear endpoint feature + * + * \return true if success + */ +static bool udc_req_std_ep_clear_feature(void) +{ + if (udd_g_ctrlreq.req.wLength) { + return false; + } + + if (udd_g_ctrlreq.req.wValue == USB_EP_FEATURE_HALT) { + return udd_ep_clear_halt(udd_g_ctrlreq.req.wIndex & 0xFF); + } + return false; +} +#endif + +/** + * \brief Standard device request to set a feature + * + * \return true if success + */ +static bool udc_req_std_dev_set_feature(void) +{ + if (udd_g_ctrlreq.req.wLength) { + return false; + } + + switch (udd_g_ctrlreq.req.wValue) { + + case USB_DEV_FEATURE_REMOTE_WAKEUP: +#if (USB_CONFIG_ATTR_REMOTE_WAKEUP \ + == (USB_DEVICE_ATTR & USB_CONFIG_ATTR_REMOTE_WAKEUP)) + udc_device_status |= CPU_TO_LE16(USB_DEV_STATUS_REMOTEWAKEUP); + UDC_REMOTEWAKEUP_ENABLE(); + return true; +#else + return false; +#endif + +#ifdef USB_DEVICE_HS_SUPPORT + case USB_DEV_FEATURE_TEST_MODE: + if (!udd_is_high_speed()) { + break; + } + if (udd_g_ctrlreq.req.wIndex & 0xff) { + break; + } + // Unconfigure the device, terminating all ongoing requests + udc_reset(); + switch ((udd_g_ctrlreq.req.wIndex >> 8) & 0xFF) { + case USB_DEV_TEST_MODE_J: + udd_g_ctrlreq.callback = udd_test_mode_j; + return true; + + case USB_DEV_TEST_MODE_K: + udd_g_ctrlreq.callback = udd_test_mode_k; + return true; + + case USB_DEV_TEST_MODE_SE0_NAK: + udd_g_ctrlreq.callback = udd_test_mode_se0_nak; + return true; + + case USB_DEV_TEST_MODE_PACKET: + udd_g_ctrlreq.callback = udd_test_mode_packet; + return true; + + case USB_DEV_TEST_MODE_FORCE_ENABLE: // Only for downstream facing hub ports + default: + break; + } + break; +#endif + default: + break; + } + return false; +} + +/** + * \brief Standard endpoint request to halt an endpoint + * + * \return true if success + */ +#if (0!=USB_DEVICE_MAX_EP) +static bool udc_req_std_ep_set_feature(void) +{ + if (udd_g_ctrlreq.req.wLength) { + return false; + } + if (udd_g_ctrlreq.req.wValue == USB_EP_FEATURE_HALT) { + udd_ep_abort(udd_g_ctrlreq.req.wIndex & 0xFF); + return udd_ep_set_halt(udd_g_ctrlreq.req.wIndex & 0xFF); + } + return false; +} +#endif + +/** + * \brief Change the address of device + * Callback called at the end of request set address + */ +static void udc_valid_address(void) +{ + udd_set_address(udd_g_ctrlreq.req.wValue & 0x7F); +} + +/** + * \brief Standard device request to set device address + * + * \return true if success + */ +static bool udc_req_std_dev_set_address(void) +{ + if (udd_g_ctrlreq.req.wLength) { + return false; + } + + // The address must be changed at the end of setup request after the handshake + // then we use a callback to change address + udd_g_ctrlreq.callback = udc_valid_address; + return true; +} + +/** + * \brief Standard device request to get device string descriptor + * + * \return true if success + */ +static bool udc_req_std_dev_get_str_desc(void) +{ + uint8_t i; + const uint8_t *str; + uint8_t str_length = 0; + + // Link payload pointer to the string corresponding at request + switch (udd_g_ctrlreq.req.wValue & 0xff) { + case 0: + udd_set_setup_payload((uint8_t *) &udc_string_desc_languageid, + sizeof(udc_string_desc_languageid)); + break; + +#ifdef USB_DEVICE_MANUFACTURE_NAME + case 1: + str_length = USB_DEVICE_MANUFACTURE_NAME_SIZE; + str = udc_string_manufacturer_name; + break; +#endif +#ifdef USB_DEVICE_PRODUCT_NAME + case 2: + str_length = USB_DEVICE_PRODUCT_NAME_SIZE; + str = udc_string_product_name; + break; +#endif +#if defined USB_DEVICE_SERIAL_NAME || defined USB_DEVICE_GET_SERIAL_NAME_POINTER + case 3: + str_length = USB_DEVICE_SERIAL_NAME_SIZE; + str = udc_get_string_serial_name(); + break; +#endif + default: +#ifdef UDC_GET_EXTRA_STRING + if (UDC_GET_EXTRA_STRING()) { + break; + } +#endif + return false; + } + + if (str_length) { + for(i = 0; i < str_length; i++) { + udc_string_desc.string[i] = cpu_to_le16((le16_t)str[i]); + } + + udc_string_desc.header.bLength = 2 + (str_length) * 2; + udd_set_setup_payload( + (uint8_t *) &udc_string_desc, + udc_string_desc.header.bLength); + } + + return true; +} + +/** + * \brief Standard device request to get descriptors about USB device + * + * \return true if success + */ +static bool udc_req_std_dev_get_descriptor(void) +{ + uint8_t conf_num; + + conf_num = udd_g_ctrlreq.req.wValue & 0xff; + + // Check descriptor ID + switch ((uint8_t) (udd_g_ctrlreq.req.wValue >> 8)) { + case USB_DT_DEVICE: + // Device descriptor requested +#ifdef USB_DEVICE_HS_SUPPORT + if (!udd_is_high_speed()) { + udd_set_setup_payload( + (uint8_t *) udc_config.confdev_hs, + udc_config.confdev_hs->bLength); + } else +#endif + { + udd_set_setup_payload( + (uint8_t *) udc_config.confdev_lsfs, + udc_config.confdev_lsfs->bLength); + } + break; + + case USB_DT_CONFIGURATION: + // Configuration descriptor requested +#ifdef USB_DEVICE_HS_SUPPORT + if (udd_is_high_speed()) { + // HS descriptor + if (conf_num >= udc_config.confdev_hs-> + bNumConfigurations) { + return false; + } + udd_set_setup_payload( + (uint8_t *)udc_config.conf_hs[conf_num].desc, + le16_to_cpu(udc_config.conf_hs[conf_num].desc->wTotalLength)); + } else +#endif + { + // FS descriptor + if (conf_num >= udc_config.confdev_lsfs-> + bNumConfigurations) { + return false; + } + udd_set_setup_payload( + (uint8_t *)udc_config.conf_lsfs[conf_num].desc, + le16_to_cpu(udc_config.conf_lsfs[conf_num].desc->wTotalLength)); + } + ((usb_conf_desc_t *) udd_g_ctrlreq.payload)->bDescriptorType = + USB_DT_CONFIGURATION; + break; + +#ifdef USB_DEVICE_HS_SUPPORT + case USB_DT_DEVICE_QUALIFIER: + // Device qualifier descriptor requested + udd_set_setup_payload( (uint8_t *) udc_config.qualifier, + udc_config.qualifier->bLength); + break; + + case USB_DT_OTHER_SPEED_CONFIGURATION: + // Other configuration descriptor requested + if (!udd_is_high_speed()) { + // HS descriptor + if (conf_num >= udc_config.confdev_hs-> + bNumConfigurations) { + return false; + } + udd_set_setup_payload( + (uint8_t *)udc_config.conf_hs[conf_num].desc, + le16_to_cpu(udc_config.conf_hs[conf_num].desc->wTotalLength)); + } else { + // FS descriptor + if (conf_num >= udc_config.confdev_lsfs-> + bNumConfigurations) { + return false; + } + udd_set_setup_payload( + (uint8_t *)udc_config.conf_lsfs[conf_num].desc, + le16_to_cpu(udc_config.conf_lsfs[conf_num].desc->wTotalLength)); + } + ((usb_conf_desc_t *) udd_g_ctrlreq.payload)->bDescriptorType = + USB_DT_OTHER_SPEED_CONFIGURATION; + break; +#endif + + case USB_DT_BOS: + // Device BOS descriptor requested + if (udc_config.conf_bos == NULL) { + return false; + } + udd_set_setup_payload( (uint8_t *) udc_config.conf_bos, + udc_config.conf_bos->wTotalLength); + break; + + case USB_DT_STRING: + // String descriptor requested + if (!udc_req_std_dev_get_str_desc()) { + return false; + } + break; + + default: + // Unknown descriptor requested + return false; + } + // if the descriptor is larger than length requested, then reduce it + if (udd_g_ctrlreq.req.wLength < udd_g_ctrlreq.payload_size) { + udd_g_ctrlreq.payload_size = udd_g_ctrlreq.req.wLength; + } + return true; +} + +/** + * \brief Standard device request to get configuration number + * + * \return true if success + */ +static bool udc_req_std_dev_get_configuration(void) +{ + if (udd_g_ctrlreq.req.wLength != 1) { + return false; + } + + udd_set_setup_payload(&udc_num_configuration,1); + return true; +} + +/** + * \brief Standard device request to enable a configuration + * + * \return true if success + */ +static bool udc_req_std_dev_set_configuration(void) +{ + uint8_t iface_num; + + // Check request length + if (udd_g_ctrlreq.req.wLength) { + return false; + } + // Authorize configuration only if the address is valid + if (!udd_getaddress()) { + return false; + } + // Check the configuration number requested +#ifdef USB_DEVICE_HS_SUPPORT + if (udd_is_high_speed()) { + // HS descriptor + if ((udd_g_ctrlreq.req.wValue & 0xFF) > + udc_config.confdev_hs->bNumConfigurations) { + return false; + } + } else +#endif + { + // FS descriptor + if ((udd_g_ctrlreq.req.wValue & 0xFF) > + udc_config.confdev_lsfs->bNumConfigurations) { + return false; + } + } + + // Reset current configuration + udc_reset(); + + // Enable new configuration + udc_num_configuration = udd_g_ctrlreq.req.wValue & 0xFF; + if (udc_num_configuration == 0) { + return true; // Default empty configuration requested + } + // Update pointer of the configuration descriptor +#ifdef USB_DEVICE_HS_SUPPORT + if (udd_is_high_speed()) { + // HS descriptor + udc_ptr_conf = &udc_config.conf_hs[udc_num_configuration - 1]; + } else +#endif + { + // FS descriptor + udc_ptr_conf = &udc_config.conf_lsfs[udc_num_configuration - 1]; + } + // Enable all interfaces of the selected configuration + for (iface_num = 0; iface_num < udc_ptr_conf->desc->bNumInterfaces; + iface_num++) { + if (!udc_iface_enable(iface_num, 0)) { + return false; + } + } + return true; +} + +/** + * \brief Standard interface request + * to get the alternate setting number of an interface + * + * \return true if success + */ +static bool udc_req_std_iface_get_setting(void) +{ + static uint8_t udc_iface_setting; + uint8_t iface_num; + udi_api_t UDC_DESC_STORAGE *udi_api; + + if (udd_g_ctrlreq.req.wLength != 1) { + return false; // Error in request + } + if (!udc_num_configuration) { + return false; // The device is not is configured state yet + } + + // Check the interface number included in the request + iface_num = udd_g_ctrlreq.req.wIndex & 0xFF; + if (iface_num >= udc_ptr_conf->desc->bNumInterfaces) { + return false; + } + + // Select first alternate setting of the interface to update udc_ptr_iface + // before call iface->getsetting() + if (!udc_update_iface_desc(iface_num, 0)) { + return false; + } + // Get alternate setting from UDI + udi_api = udc_ptr_conf->udi_apis[iface_num]; + udc_iface_setting = udi_api->getsetting(); + + // Link value to payload pointer of request + udd_set_setup_payload(&udc_iface_setting,1); + return true; +} + +/** + * \brief Standard interface request + * to set an alternate setting of an interface + * + * \return true if success + */ +static bool udc_req_std_iface_set_setting(void) +{ + uint8_t iface_num, setting_num; + + if (udd_g_ctrlreq.req.wLength) { + return false; // Error in request + } + if (!udc_num_configuration) { + return false; // The device is not is configured state yet + } + + iface_num = udd_g_ctrlreq.req.wIndex & 0xFF; + setting_num = udd_g_ctrlreq.req.wValue & 0xFF; + + // Disable current setting + if (!udc_iface_disable(iface_num)) { + return false; + } + + // Enable new setting + return udc_iface_enable(iface_num, setting_num); +} + +/** + * \brief Main routine to manage the standard USB SETUP request + * + * \return true if the request is supported + */ +static bool udc_reqstd(void) +{ + if (Udd_setup_is_in()) { + // GET Standard Requests + if (udd_g_ctrlreq.req.wLength == 0) { + return false; // Error for USB host + } + + if (USB_REQ_RECIP_DEVICE == Udd_setup_recipient()) { + // Standard Get Device request + switch (udd_g_ctrlreq.req.bRequest) { + case USB_REQ_GET_STATUS: + return udc_req_std_dev_get_status(); + case USB_REQ_GET_DESCRIPTOR: + return udc_req_std_dev_get_descriptor(); + case USB_REQ_GET_CONFIGURATION: + return udc_req_std_dev_get_configuration(); + default: + break; + } + } + + if (USB_REQ_RECIP_INTERFACE == Udd_setup_recipient()) { + // Standard Get Interface request + switch (udd_g_ctrlreq.req.bRequest) { + case USB_REQ_GET_INTERFACE: + return udc_req_std_iface_get_setting(); + default: + break; + } + } +#if (0!=USB_DEVICE_MAX_EP) + if (USB_REQ_RECIP_ENDPOINT == Udd_setup_recipient()) { + // Standard Get Endpoint request + switch (udd_g_ctrlreq.req.bRequest) { + case USB_REQ_GET_STATUS: + return udc_req_std_ep_get_status(); + default: + break; + } + } +#endif + } else { + // SET Standard Requests + if (USB_REQ_RECIP_DEVICE == Udd_setup_recipient()) { + // Standard Set Device request + switch (udd_g_ctrlreq.req.bRequest) { + case USB_REQ_SET_ADDRESS: + return udc_req_std_dev_set_address(); + case USB_REQ_CLEAR_FEATURE: + return udc_req_std_dev_clear_feature(); + case USB_REQ_SET_FEATURE: + return udc_req_std_dev_set_feature(); + case USB_REQ_SET_CONFIGURATION: + return udc_req_std_dev_set_configuration(); + case USB_REQ_SET_DESCRIPTOR: + /* Not supported (defined as optional by the USB 2.0 spec) */ + break; + default: + break; + } + } + + if (USB_REQ_RECIP_INTERFACE == Udd_setup_recipient()) { + // Standard Set Interface request + switch (udd_g_ctrlreq.req.bRequest) { + case USB_REQ_SET_INTERFACE: + return udc_req_std_iface_set_setting(); + default: + break; + } + } +#if (0!=USB_DEVICE_MAX_EP) + if (USB_REQ_RECIP_ENDPOINT == Udd_setup_recipient()) { + // Standard Set Endpoint request + switch (udd_g_ctrlreq.req.bRequest) { + case USB_REQ_CLEAR_FEATURE: + return udc_req_std_ep_clear_feature(); + case USB_REQ_SET_FEATURE: + return udc_req_std_ep_set_feature(); + default: + break; + } + } +#endif + } + return false; +} + +/** + * \brief Send the SETUP interface request to UDI + * + * \return true if the request is supported + */ +static bool udc_req_iface(void) +{ + uint8_t iface_num; + udi_api_t UDC_DESC_STORAGE *udi_api; + + if (0 == udc_num_configuration) { + return false; // The device is not is configured state yet + } + // Check interface number + iface_num = udd_g_ctrlreq.req.wIndex & 0xFF; + if (iface_num >= udc_ptr_conf->desc->bNumInterfaces) { + return false; + } + + //* To update udc_ptr_iface with the selected interface in request + // Select first alternate setting of interface to update udc_ptr_iface + // before calling udi_api->getsetting() + if (!udc_update_iface_desc(iface_num, 0)) { + return false; + } + // Select the interface with the current alternate setting + udi_api = udc_ptr_conf->udi_apis[iface_num]; + if (!udc_update_iface_desc(iface_num, udi_api->getsetting())) { + return false; + } + + // Send the SETUP request to the UDI corresponding to the interface number + return udi_api->setup(); +} + +/** + * \brief Send the SETUP interface request to UDI + * + * \return true if the request is supported + */ +static bool udc_req_ep(void) +{ + uint8_t iface_num; + udi_api_t UDC_DESC_STORAGE *udi_api; + + if (0 == udc_num_configuration) { + return false; // The device is not is configured state yet + } + // Send this request on all enabled interfaces + iface_num = udd_g_ctrlreq.req.wIndex & 0xFF; + for (iface_num = 0; iface_num < udc_ptr_conf->desc->bNumInterfaces; + iface_num++) { + // Select the interface with the current alternate setting + udi_api = udc_ptr_conf->udi_apis[iface_num]; + if (!udc_update_iface_desc(iface_num, udi_api->getsetting())) { + return false; + } + + // Send the SETUP request to the UDI + if (udi_api->setup()) { + return true; + } + } + return false; +} + +/** + * \brief Main routine to manage the USB SETUP request. + * + * This function parses a USB SETUP request and submits an appropriate + * response back to the host or, in the case of SETUP OUT requests + * with data, sets up a buffer for receiving the data payload. + * + * The main standard requests defined by the USB 2.0 standard are handled + * internally. The interface requests are sent to UDI, and the specific request + * sent to a specific application callback. + * + * \return true if the request is supported, else the request is stalled by UDD + */ +bool udc_process_setup(void) +{ + // By default no data (receive/send) and no callbacks registered + udd_g_ctrlreq.payload_size = 0; + udd_g_ctrlreq.callback = NULL; + udd_g_ctrlreq.over_under_run = NULL; + + if (Udd_setup_is_in()) { + if (udd_g_ctrlreq.req.wLength == 0) { + return false; // Error from USB host + } + } + + // If standard request then try to decode it in UDC + if (Udd_setup_type() == USB_REQ_TYPE_STANDARD) { + if (udc_reqstd()) { + return true; + } + } + + // If interface request then try to decode it in UDI + if (Udd_setup_recipient() == USB_REQ_RECIP_INTERFACE) { + if (udc_req_iface()) { + return true; + } + } + + // If endpoint request then try to decode it in UDI + if (Udd_setup_recipient() == USB_REQ_RECIP_ENDPOINT) { + if (udc_req_ep()) { + return true; + } + } + + // Here SETUP request unknown by UDC and UDIs +#ifdef USB_DEVICE_SPECIFIC_REQUEST + // Try to decode it in specific callback + return USB_DEVICE_SPECIFIC_REQUEST(); // Ex: Vendor request,... +#else + return false; +#endif +} + +//! @} diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/udc/udc.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/udc/udc.h new file mode 100755 index 0000000..93c0cdd --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/udc/udc.h @@ -0,0 +1,694 @@ +/** + * \file + * + * \brief Interface of the USB Device Controller (UDC) + * + * Copyright (c) 2009 - 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _UDC_H_ +#define _UDC_H_ + +#include "conf_usb.h" +#include "usb_protocol.h" +#include "udc_desc.h" +#include "udd.h" + +#if USB_DEVICE_VENDOR_ID == 0 +# error USB_DEVICE_VENDOR_ID cannot be equal to 0 +#endif + +#if USB_DEVICE_PRODUCT_ID == 0 +# error USB_DEVICE_PRODUCT_ID cannot be equal to 0 +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \ingroup usb_device_group + * \defgroup udc_group USB Device Controller (UDC) + * + * The UDC provides a high-level abstraction of the usb device. + * You can use these functions to control the main device state + * (start/attach/wakeup). + * + * \section USB_DEVICE_CONF USB Device Custom configuration + * The following USB Device configuration must be included in the conf_usb.h + * file of the application. + * + * USB_DEVICE_VENDOR_ID (Word)
+ * Vendor ID provided by USB org (ATMEL 0x03EB). + * + * USB_DEVICE_PRODUCT_ID (Word)
+ * Product ID (Referenced in usb_atmel.h). + * + * USB_DEVICE_MAJOR_VERSION (Byte)
+ * Major version of the device + * + * USB_DEVICE_MINOR_VERSION (Byte)
+ * Minor version of the device + * + * USB_DEVICE_MANUFACTURE_NAME (string)
+ * ASCII name for the manufacture + * + * USB_DEVICE_PRODUCT_NAME (string)
+ * ASCII name for the product + * + * USB_DEVICE_SERIAL_NAME (string)
+ * ASCII name to enable and set a serial number + * + * USB_DEVICE_POWER (Numeric)
+ * (unit mA) Maximum device power + * + * USB_DEVICE_ATTR (Byte)
+ * USB attributes available: + * - USB_CONFIG_ATTR_SELF_POWERED + * - USB_CONFIG_ATTR_REMOTE_WAKEUP + * Note: if remote wake enabled then defines remotewakeup callbacks, + * see Table 5-2. External API from UDC - Callback + * + * USB_DEVICE_LOW_SPEED (Only defined)
+ * Force the USB Device to run in low speed + * + * USB_DEVICE_HS_SUPPORT (Only defined)
+ * Authorize the USB Device to run in high speed + * + * USB_DEVICE_MAX_EP (Byte)
+ * Define the maximum endpoint number used by the USB Device.
+ * This one is already defined in UDI default configuration. + * Ex: + * - When endpoint control 0x00, endpoint 0x01 and + * endpoint 0x82 is used then USB_DEVICE_MAX_EP=2 + * - When only endpoint control 0x00 is used then USB_DEVICE_MAX_EP=0 + * - When endpoint 0x01 and endpoint 0x81 is used then USB_DEVICE_MAX_EP=1
+ * (configuration not possible on USBB interface) + * @{ + */ + +/** + * \brief Authorizes the VBUS event + * + * \return true, if the VBUS monitoring is possible. + * + * \section udc_vbus_monitoring VBus monitoring used cases + * + * The VBus monitoring is used only for USB SELF Power application. + * + * - By default the USB device is automatically attached when Vbus is high + * or when USB is start for devices without internal Vbus monitoring. + * conf_usb.h file does not contains define USB_DEVICE_ATTACH_AUTO_DISABLE. + * \code //#define USB_DEVICE_ATTACH_AUTO_DISABLE \endcode + * + * - Add custom VBUS monitoring. conf_usb.h file contains define + * USB_DEVICE_ATTACH_AUTO_DISABLE: + * \code #define USB_DEVICE_ATTACH_AUTO_DISABLE \endcode + * User C file contains: + * \code + // Authorize VBUS monitoring + if (!udc_include_vbus_monitoring()) { + // Implement custom VBUS monitoring via GPIO or other + } + Event_VBUS_present() // VBUS interrupt or GPIO interrupt or other + { + // Attach USB Device + udc_attach(); + } +\endcode + * + * - Case of battery charging. conf_usb.h file contains define + * USB_DEVICE_ATTACH_AUTO_DISABLE: + * \code #define USB_DEVICE_ATTACH_AUTO_DISABLE \endcode + * User C file contains: + * \code + Event VBUS present() // VBUS interrupt or GPIO interrupt or .. + { + // Authorize battery charging, but wait key press to start USB. + } + Event Key press() + { + // Stop batteries charging + // Start USB + udc_attach(); + } +\endcode + */ +static inline bool udc_include_vbus_monitoring(void) +{ + return udd_include_vbus_monitoring(); +} + +/*! \brief Start the USB Device stack + */ +void udc_start(void); + +/*! \brief Stop the USB Device stack + */ +void udc_stop(void); + +/** + * \brief Attach device to the bus when possible + * + * \warning If a VBus control is included in driver, + * then it will attach device when an acceptable Vbus + * level from the host is detected. + */ +static inline void udc_attach(void) +{ + udd_attach(); +} + + +/** + * \brief Detaches the device from the bus + * + * The driver must remove pull-up on USB line D- or D+. + */ +static inline void udc_detach(void) +{ + udd_detach(); +} + + +/*! \brief The USB driver sends a resume signal called \e "Upstream Resume" + * This is authorized only when the remote wakeup feature is enabled by host. + */ +static inline void udc_remotewakeup(void) +{ + udd_send_remotewakeup(); +} + + +/** + * \brief Returns a pointer on the current interface descriptor + * + * \return pointer on the current interface descriptor. + */ +usb_iface_desc_t UDC_DESC_STORAGE *udc_get_interface_desc(void); + +//@} + +/** + * \ingroup usb_group + * \defgroup usb_device_group USB Stack Device + * + * This module includes USB Stack Device implementation. + * The stack is divided in three parts: + * - USB Device Controller (UDC) provides USB chapter 9 compliance + * - USB Device Interface (UDI) provides USB Class compliance + * - USB Device Driver (UDD) provides USB Driver for each Atmel MCU + + * Many USB Device applications can be implemented on Atmel MCU. + * Atmel provides many application notes for different applications: + * - AVR4900, provides general information about Device Stack + * - AVR4901, explains how to create a new class + * - AVR4902, explains how to create a composite device + * - AVR49xx, all device classes provided in ASF have an application note + * + * A basic USB knowledge is required to understand the USB Device + * Class application notes (HID,MS,CDC,PHDC,...). + * Then, to create an USB device with + * only one class provided by ASF, refer directly to the application note + * corresponding to this USB class. The USB Device application note for + * New Class and Composite is dedicated to advanced USB users. + * + * @{ + */ + +//! @} + +#ifdef __cplusplus +} +#endif + +/** + * \ingroup udc_group + * \defgroup udc_basic_use_case_setup_prereq USB Device Controller (UDC) - Prerequisites + * Common prerequisites for all USB devices. + * + * This module is based on USB device stack full interrupt driven, and supporting + * \ref sleepmgr_group sleepmgr. For AVR and SAM3/4 devices the \ref clk_group clock services + * is supported. For SAMD devices the \ref asfdoc_sam0_system_clock_group clock driver is supported. + * + * The following procedure must be executed to setup the project correctly: + * - Specify the clock configuration: + * - XMEGA USB devices need 48MHz clock input.\n + * XMEGA USB devices need CPU frequency higher than 12MHz.\n + * You can use either an internal RC48MHz auto calibrated by Start of Frames + * or an external OSC. + * - UC3 and SAM3/4 devices without USB high speed support need 48MHz clock input.\n + * You must use a PLL and an external OSC. + * - UC3 and SAM3/4 devices with USB high speed support need 12MHz clock input.\n + * You must use an external OSC. + * - UC3 devices with USBC hardware need CPU frequency higher than 25MHz. + * - SAMD devices without USB high speed support need 48MHz clock input.\n + * You should use DFLL with USBCRM. + * - In conf_board.h, the define CONF_BOARD_USB_PORT must be added to enable USB lines. + * (Not mandatory for all boards) + * - Enable interrupts + * - Initialize the clock service + * + * The usage of \ref sleepmgr_group sleepmgr service is optional, but recommended to reduce power + * consumption: + * - Initialize the sleep manager service + * - Activate sleep mode when the application is in IDLE state + * + * \subpage udc_conf_clock. + * + * for AVR and SAM3/4 devices, add to the initialization code: + * \code + sysclk_init(); + irq_initialize_vectors(); + cpu_irq_enable(); + board_init(); + sleepmgr_init(); // Optional +\endcode + * + * For SAMD devices, add to the initialization code: + * \code + system_init(); + irq_initialize_vectors(); + cpu_irq_enable(); + sleepmgr_init(); // Optional +\endcode + * Add to the main IDLE loop: + * \code + sleepmgr_enter_sleep(); // Optional +\endcode + * + */ + +/** + * \ingroup udc_group + * \defgroup udc_basic_use_case_setup_code USB Device Controller (UDC) - Example code + * Common example code for all USB devices. + * + * Content of conf_usb.h: + * \code + #define USB_DEVICE_VENDOR_ID 0x03EB + #define USB_DEVICE_PRODUCT_ID 0xXXXX + #define USB_DEVICE_MAJOR_VERSION 1 + #define USB_DEVICE_MINOR_VERSION 0 + #define USB_DEVICE_POWER 100 + #define USB_DEVICE_ATTR USB_CONFIG_ATTR_BUS_POWERED +\endcode + * + * Add to application C-file: + * \code + void usb_init(void) + { + udc_start(); + } +\endcode + */ + +/** + * \ingroup udc_group + * \defgroup udc_basic_use_case_setup_flow USB Device Controller (UDC) - Workflow + * Common workflow for all USB devices. + * + * -# Ensure that conf_usb.h is available and contains the following configuration + * which is the main USB device configuration: + * - \code // Vendor ID provided by USB org (ATMEL 0x03EB) + #define USB_DEVICE_VENDOR_ID 0x03EB // Type Word + // Product ID (Atmel PID referenced in usb_atmel.h) + #define USB_DEVICE_PRODUCT_ID 0xXXXX // Type Word + // Major version of the device + #define USB_DEVICE_MAJOR_VERSION 1 // Type Byte + // Minor version of the device + #define USB_DEVICE_MINOR_VERSION 0 // Type Byte + // Maximum device power (mA) + #define USB_DEVICE_POWER 100 // Type 9-bits + // USB attributes to enable features + #define USB_DEVICE_ATTR USB_CONFIG_ATTR_BUS_POWERED // Flags \endcode + * -# Call the USB device stack start function to enable stack and start USB: + * - \code udc_start(); \endcode + * \note In case of USB dual roles (Device and Host) managed through USB OTG connector + * (USB ID pin), the call of udc_start() must be removed and replaced by uhc_start(). + * SeRefer to "AVR4950 section 6.1 Dual roles" for further information about dual roles. + */ + +/** + * \page udc_conf_clock conf_clock.h examples with USB support + * + * Content of XMEGA conf_clock.h: + * \code + // Configuration based on internal RC: + // USB clock need of 48Mhz + #define CONFIG_USBCLK_SOURCE USBCLK_SRC_RCOSC + #define CONFIG_OSC_RC32_CAL 48000000UL + #define CONFIG_OSC_AUTOCAL_RC32MHZ_REF_OSC OSC_ID_USBSOF + // CPU clock need of clock > 12MHz to run with USB (Here 24MHz) + #define CONFIG_SYSCLK_SOURCE SYSCLK_SRC_RC32MHZ + #define CONFIG_SYSCLK_PSADIV SYSCLK_PSADIV_2 + #define CONFIG_SYSCLK_PSBCDIV SYSCLK_PSBCDIV_1_1 +\endcode + * + * Content of conf_clock.h for AT32UC3A0, AT32UC3A1, AT32UC3B devices (USBB): + * \code + // Configuration based on 12MHz external OSC: + #define CONFIG_PLL1_SOURCE PLL_SRC_OSC0 + #define CONFIG_PLL1_MUL 8 + #define CONFIG_PLL1_DIV 2 + #define CONFIG_USBCLK_SOURCE USBCLK_SRC_PLL1 + #define CONFIG_USBCLK_DIV 1 // Fusb = Fsys/(2 ^ USB_div) +\endcode + * + * Content of conf_clock.h for AT32UC3A3, AT32UC3A4 devices (USBB with high speed support): + * \code + // Configuration based on 12MHz external OSC: + #define CONFIG_USBCLK_SOURCE USBCLK_SRC_OSC0 + #define CONFIG_USBCLK_DIV 1 // Fusb = Fsys/(2 ^ USB_div) +\endcode + * + * Content of conf_clock.h for AT32UC3C, ATUCXXD, ATUCXXL3U, ATUCXXL4U devices (USBC): + * \code + // Configuration based on 12MHz external OSC: + #define CONFIG_PLL1_SOURCE PLL_SRC_OSC0 + #define CONFIG_PLL1_MUL 8 + #define CONFIG_PLL1_DIV 2 + #define CONFIG_USBCLK_SOURCE USBCLK_SRC_PLL1 + #define CONFIG_USBCLK_DIV 1 // Fusb = Fsys/(2 ^ USB_div) + // CPU clock need of clock > 25MHz to run with USBC + #define CONFIG_SYSCLK_SOURCE SYSCLK_SRC_PLL1 +\endcode + * + * Content of conf_clock.h for SAM3S, SAM3SD, SAM4S devices (UPD: USB Peripheral Device): + * \code + // PLL1 (B) Options (Fpll = (Fclk * PLL_mul) / PLL_div) + #define CONFIG_PLL1_SOURCE PLL_SRC_MAINCK_XTAL + #define CONFIG_PLL1_MUL 16 + #define CONFIG_PLL1_DIV 2 + // USB Clock Source Options (Fusb = FpllX / USB_div) + #define CONFIG_USBCLK_SOURCE USBCLK_SRC_PLL1 + #define CONFIG_USBCLK_DIV 2 +\endcode + * + * Content of conf_clock.h for SAM3U device (UPDHS: USB Peripheral Device High Speed): + * \code + // USB Clock Source fixed at UPLL. +\endcode + * + * Content of conf_clock.h for SAM3X, SAM3A devices (UOTGHS: USB OTG High Speed): + * \code + // USB Clock Source fixed at UPLL. + #define CONFIG_USBCLK_SOURCE USBCLK_SRC_UPLL + #define CONFIG_USBCLK_DIV 1 +\endcode + * + * Content of conf_clocks.h for SAMD devices (USB): + * \code + // System clock bus configuration + # define CONF_CLOCK_FLASH_WAIT_STATES 2 + + // USB Clock Source fixed at DFLL. + // SYSTEM_CLOCK_SOURCE_DFLL configuration - Digital Frequency Locked Loop + # define CONF_CLOCK_DFLL_ENABLE true + # define CONF_CLOCK_DFLL_LOOP_MODE SYSTEM_CLOCK_DFLL_LOOP_MODE_USB_RECOVERY + # define CONF_CLOCK_DFLL_ON_DEMAND true + + // Set this to true to configure the GCLK when running clocks_init. + // If set to false, none of the GCLK generators will be configured in clocks_init(). + # define CONF_CLOCK_CONFIGURE_GCLK true + + // Configure GCLK generator 0 (Main Clock) + # define CONF_CLOCK_GCLK_0_ENABLE true + # define CONF_CLOCK_GCLK_0_RUN_IN_STANDBY true + # define CONF_CLOCK_GCLK_0_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_DFLL + # define CONF_CLOCK_GCLK_0_PRESCALER 1 + # define CONF_CLOCK_GCLK_0_OUTPUT_ENABLE false +\endcode + */ + +/** + * \page udc_use_case_1 Change USB speed + * + * In this use case, the USB device is used with different USB speeds. + * + * \section udc_use_case_1_setup Setup steps + * + * Prior to implement this use case, be sure to have already + * apply the UDI module "basic use case". + * + * \section udc_use_case_1_usage Usage steps + * + * \subsection udc_use_case_1_usage_code Example code + * Content of conf_usb.h: + * \code + #if // Low speed + #define USB_DEVICE_LOW_SPEED + // #define USB_DEVICE_HS_SUPPORT + + #elif // Full speed + // #define USB_DEVICE_LOW_SPEED + // #define USB_DEVICE_HS_SUPPORT + + #elif // High speed + // #define USB_DEVICE_LOW_SPEED + #define USB_DEVICE_HS_SUPPORT + + #endif +\endcode + * + * \subsection udc_use_case_1_usage_flow Workflow + * -# Ensure that conf_usb.h is available and contains the following parameters + * required for a USB device low speed (1.5Mbit/s): + * - \code #define USB_DEVICE_LOW_SPEED + //#define USB_DEVICE_HS_SUPPORT \endcode + * -# Ensure that conf_usb.h contains the following parameters + * required for a USB device full speed (12Mbit/s): + * - \code //#define USB_DEVICE_LOW_SPEED + //#define USB_DEVICE_HS_SUPPORT \endcode + * -# Ensure that conf_usb.h contains the following parameters + * required for a USB device high speed (480Mbit/s): + * - \code //#define USB_DEVICE_LOW_SPEED + #define USB_DEVICE_HS_SUPPORT \endcode + */ + +/** + * \page udc_use_case_2 Use USB strings + * + * In this use case, the usual USB strings is added in the USB device. + * + * \section udc_use_case_2_setup Setup steps + * Prior to implement this use case, be sure to have already + * apply the UDI module "basic use case". + * + * \section udc_use_case_2_usage Usage steps + * + * \subsection udc_use_case_2_usage_code Example code + * Content of conf_usb.h: + * \code + #define USB_DEVICE_MANUFACTURE_NAME "Manufacture name" + #define USB_DEVICE_PRODUCT_NAME "Product name" + #define USB_DEVICE_SERIAL_NAME "12...EF" +\endcode + * + * \subsection udc_use_case_2_usage_flow Workflow + * -# Ensure that conf_usb.h is available and contains the following parameters + * required to enable different USB strings: + * - \code // Static ASCII name for the manufacture + #define USB_DEVICE_MANUFACTURE_NAME "Manufacture name" \endcode + * - \code // Static ASCII name for the product + #define USB_DEVICE_PRODUCT_NAME "Product name" \endcode + * - \code // Static ASCII name to enable and set a serial number + #define USB_DEVICE_SERIAL_NAME "12...EF" \endcode + */ + +/** + * \page udc_use_case_3 Use USB remote wakeup feature + * + * In this use case, the USB remote wakeup feature is enabled. + * + * \section udc_use_case_3_setup Setup steps + * Prior to implement this use case, be sure to have already + * apply the UDI module "basic use case". + * + * \section udc_use_case_3_usage Usage steps + * + * \subsection udc_use_case_3_usage_code Example code + * Content of conf_usb.h: + * \code + #define USB_DEVICE_ATTR \ + (USB_CONFIG_ATTR_REMOTE_WAKEUP | USB_CONFIG_ATTR_..._POWERED) + #define UDC_REMOTEWAKEUP_ENABLE() my_callback_remotewakeup_enable() + extern void my_callback_remotewakeup_enable(void); + #define UDC_REMOTEWAKEUP_DISABLE() my_callback_remotewakeup_disable() + extern void my_callback_remotewakeup_disable(void); +\endcode + * + * Add to application C-file: + * \code + void my_callback_remotewakeup_enable(void) + { + // Enable application wakeup events (e.g. enable GPIO interrupt) + } + void my_callback_remotewakeup_disable(void) + { + // Disable application wakeup events (e.g. disable GPIO interrupt) + } + + void my_interrupt_event(void) + { + udc_remotewakeup(); + } +\endcode + * + * \subsection udc_use_case_3_usage_flow Workflow + * -# Ensure that conf_usb.h is available and contains the following parameters + * required to enable remote wakeup feature: + * - \code // Authorizes the remote wakeup feature + #define USB_DEVICE_ATTR (USB_CONFIG_ATTR_REMOTE_WAKEUP | USB_CONFIG_ATTR_..._POWERED) \endcode + * - \code // Define callback called when the host enables the remotewakeup feature + #define UDC_REMOTEWAKEUP_ENABLE() my_callback_remotewakeup_enable() + extern void my_callback_remotewakeup_enable(void); \endcode + * - \code // Define callback called when the host disables the remotewakeup feature + #define UDC_REMOTEWAKEUP_DISABLE() my_callback_remotewakeup_disable() + extern void my_callback_remotewakeup_disable(void); \endcode + * -# Send a remote wakeup (USB upstream): + * - \code udc_remotewakeup(); \endcode + */ + +/** + * \page udc_use_case_5 Bus power application recommendations + * + * In this use case, the USB device BUS power feature is enabled. + * This feature requires a correct power consumption management. + * + * \section udc_use_case_5_setup Setup steps + * Prior to implement this use case, be sure to have already + * apply the UDI module "basic use case". + * + * \section udc_use_case_5_usage Usage steps + * + * \subsection udc_use_case_5_usage_code Example code + * Content of conf_usb.h: + * \code + #define USB_DEVICE_ATTR (USB_CONFIG_ATTR_BUS_POWERED) + #define UDC_SUSPEND_EVENT() user_callback_suspend_action() + extern void user_callback_suspend_action(void) + #define UDC_RESUME_EVENT() user_callback_resume_action() + extern void user_callback_resume_action(void) +\endcode + * + * Add to application C-file: + * \code + void user_callback_suspend_action(void) + { + // Disable hardware component to reduce power consumption + } + void user_callback_resume_action(void) + { + // Re-enable hardware component + } +\endcode + * + * \subsection udc_use_case_5_usage_flow Workflow + * -# Ensure that conf_usb.h is available and contains the following parameters: + * - \code // Authorizes the BUS power feature + #define USB_DEVICE_ATTR (USB_CONFIG_ATTR_BUS_POWERED) \endcode + * - \code // Define callback called when the host suspend the USB line + #define UDC_SUSPEND_EVENT() user_callback_suspend_action() + extern void user_callback_suspend_action(void); \endcode + * - \code // Define callback called when the host or device resume the USB line + #define UDC_RESUME_EVENT() user_callback_resume_action() + extern void user_callback_resume_action(void); \endcode + * -# Reduce power consumption in suspend mode (max. 2.5mA on Vbus): + * - \code void user_callback_suspend_action(void) + { + turn_off_components(); + } \endcode + */ + +/** + * \page udc_use_case_6 USB dynamic serial number + * + * In this use case, the USB serial strings is dynamic. + * For a static serial string refer to \ref udc_use_case_2. + * + * \section udc_use_case_6_setup Setup steps + * Prior to implement this use case, be sure to have already + * apply the UDI module "basic use case". + * + * \section udc_use_case_6_usage Usage steps + * + * \subsection udc_use_case_6_usage_code Example code + * Content of conf_usb.h: + * \code + #define USB_DEVICE_SERIAL_NAME + #define USB_DEVICE_GET_SERIAL_NAME_POINTER serial_number + #define USB_DEVICE_GET_SERIAL_NAME_LENGTH 12 + extern uint8_t serial_number[]; +\endcode + * + * Add to application C-file: + * \code + uint8_t serial_number[USB_DEVICE_GET_SERIAL_NAME_LENGTH]; + + void init_build_usb_serial_number(void) + { + serial_number[0] = 'A'; + serial_number[1] = 'B'; + ... + serial_number[USB_DEVICE_GET_SERIAL_NAME_LENGTH-1] = 'C'; + } \endcode + * + * \subsection udc_use_case_6_usage_flow Workflow + * -# Ensure that conf_usb.h is available and contains the following parameters + * required to enable a USB serial number strings dynamically: + * - \code #define USB_DEVICE_SERIAL_NAME // Define this empty + #define USB_DEVICE_GET_SERIAL_NAME_POINTER serial_number // Give serial array pointer + #define USB_DEVICE_GET_SERIAL_NAME_LENGTH 12 // Give size of serial array + extern uint8_t serial_number[]; // Declare external serial array \endcode + * -# Before start USB stack, initialize the serial array + * - \code + uint8_t serial_number[USB_DEVICE_GET_SERIAL_NAME_LENGTH]; + + void init_build_usb_serial_number(void) + { + serial_number[0] = 'A'; + serial_number[1] = 'B'; + ... + serial_number[USB_DEVICE_GET_SERIAL_NAME_LENGTH-1] = 'C'; + } \endcode + */ + + + +#endif // _UDC_H_ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/udc/udc_desc.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/udc/udc_desc.h new file mode 100755 index 0000000..2ce5274 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/udc/udc_desc.h @@ -0,0 +1,132 @@ +/** + * \file + * + * \brief Common API for USB Device Interface + * + * Copyright (c) 2009-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _UDC_DESC_H_ +#define _UDC_DESC_H_ + +#include "conf_usb.h" +#include "usb_protocol.h" +#include "udi.h" + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \ingroup udc_group + * \defgroup udc_desc_group USB Device Descriptor + * + * @{ + */ + +/** + * \brief Defines the memory's location of USB descriptors + * + * By default the Descriptor is stored in RAM + * (UDC_DESC_STORAGE is defined empty). + * + * If you have need to free RAM space, + * it is possible to put descriptor in flash in following case: + * - USB driver authorize flash transfer (USBB on UC3 and USB on Mega) + * - USB Device is not high speed (UDC no need to change USB descriptors) + * + * For UC3 application used "const". + * + * For Mega application used "code". + */ +#define UDC_DESC_STORAGE + // Descriptor storage in internal RAM +#if (defined UDC_DATA_USE_HRAM_SUPPORT) +# if defined(__GNUC__) +# define UDC_DATA(x) COMPILER_WORD_ALIGNED __attribute__((__section__(".data_hram0"))) +# define UDC_BSS(x) COMPILER_ALIGNED(x) __attribute__((__section__(".bss_hram0"))) +# elif defined(__ICCAVR32__) +# define UDC_DATA(x) COMPILER_ALIGNED(x) __data32 +# define UDC_BSS(x) COMPILER_ALIGNED(x) __data32 +# endif +#else +# define UDC_DATA(x) COMPILER_ALIGNED(x) +# define UDC_BSS(x) COMPILER_ALIGNED(x) +#endif + + + +/** + * \brief Configuration descriptor and UDI link for one USB speed + */ +typedef struct { + //! USB configuration descriptor + usb_conf_desc_t UDC_DESC_STORAGE *desc; + //! Array of UDI API pointer + udi_api_t UDC_DESC_STORAGE *UDC_DESC_STORAGE * udi_apis; +} udc_config_speed_t; + + +/** + * \brief All information about the USB Device + */ +typedef struct { + //! USB device descriptor for low or full speed + usb_dev_desc_t UDC_DESC_STORAGE *confdev_lsfs; + //! USB configuration descriptor and UDI API pointers for low or full speed + udc_config_speed_t UDC_DESC_STORAGE *conf_lsfs; +#ifdef USB_DEVICE_HS_SUPPORT + //! USB device descriptor for high speed + usb_dev_desc_t UDC_DESC_STORAGE *confdev_hs; + //! USB device qualifier, only use in high speed mode + usb_dev_qual_desc_t UDC_DESC_STORAGE *qualifier; + //! USB configuration descriptor and UDI API pointers for high speed + udc_config_speed_t UDC_DESC_STORAGE *conf_hs; +#endif + usb_dev_bos_desc_t UDC_DESC_STORAGE *conf_bos; +} udc_config_t; + +//! Global variables of USB Device Descriptor and UDI links +extern UDC_DESC_STORAGE udc_config_t udc_config; + +//@} + +#ifdef __cplusplus +} +#endif +#endif // _UDC_DESC_H_ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/udc/udd.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/udc/udd.h new file mode 100755 index 0000000..85df46f --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/udc/udd.h @@ -0,0 +1,393 @@ +/** + * \file + * + * \brief Common API for USB Device Drivers (UDD) + * + * Copyright (c) 2009 - 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _UDD_H_ +#define _UDD_H_ + +#include "usb_protocol.h" +#include "udc_desc.h" + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \ingroup usb_device_group + * \defgroup udd_group USB Device Driver (UDD) + * + * The UDD driver provides a low-level abstraction of the device + * controller hardware. Most events coming from the hardware such as + * interrupts, which may cause the UDD to call into the UDC and UDI. + * + * @{ + */ + +//! \brief Endpoint identifier +typedef uint8_t udd_ep_id_t; + +//! \brief Endpoint transfer status +//! Returned in parameters of callback register via udd_ep_run routine. +typedef enum { + UDD_EP_TRANSFER_OK = 0, + UDD_EP_TRANSFER_ABORT = 1, +} udd_ep_status_t; + +/** + * \brief Global variable to give and record information of the setup request management + * + * This global variable allows to decode and response a setup request. + * It can be updated by udc_process_setup() from UDC or *setup() from UDIs. + */ +typedef struct { + //! Data received in USB SETUP packet + //! Note: The swap of "req.wValues" from uin16_t to le16_t is done by UDD. + usb_setup_req_t req; + + //! Point to buffer to send or fill with data following SETUP packet + //! This buffer must be word align for DATA IN phase (use prefix COMPILER_WORD_ALIGNED for buffer) + uint8_t *payload; + + //! Size of buffer to send or fill, and content the number of byte transfered + uint16_t payload_size; + + //! Callback called after reception of ZLP from setup request + void (*callback) (void); + + //! Callback called when the buffer given (.payload) is full or empty. + //! This one return false to abort data transfer, or true with a new buffer in .payload. + bool(*over_under_run) (void); +} udd_ctrl_request_t; +extern udd_ctrl_request_t udd_g_ctrlreq; + +//! Return true if the setup request \a udd_g_ctrlreq indicates IN data transfer +#define Udd_setup_is_in() \ + (USB_REQ_DIR_IN == (udd_g_ctrlreq.req.bmRequestType & USB_REQ_DIR_MASK)) + +//! Return true if the setup request \a udd_g_ctrlreq indicates OUT data transfer +#define Udd_setup_is_out() \ + (USB_REQ_DIR_OUT == (udd_g_ctrlreq.req.bmRequestType & USB_REQ_DIR_MASK)) + +//! Return the type of the SETUP request \a udd_g_ctrlreq. \see usb_reqtype. +#define Udd_setup_type() \ + (udd_g_ctrlreq.req.bmRequestType & USB_REQ_TYPE_MASK) + +//! Return the recipient of the SETUP request \a udd_g_ctrlreq. \see usb_recipient +#define Udd_setup_recipient() \ + (udd_g_ctrlreq.req.bmRequestType & USB_REQ_RECIP_MASK) + +/** + * \brief End of halt callback function type. + * Registered by routine udd_ep_wait_stall_clear() + * Callback called when endpoint stall is cleared. + */ +typedef void (*udd_callback_halt_cleared_t) (void); + +/** + * \brief End of transfer callback function type. + * Registered by routine udd_ep_run() + * Callback called by USB interrupt after data transfer or abort (reset,...). + * + * \param status UDD_EP_TRANSFER_OK, if transfer is complete + * \param status UDD_EP_TRANSFER_ABORT, if transfer is aborted + * \param n number of data transfered + */ +typedef void (*udd_callback_trans_t) (udd_ep_status_t status, + iram_size_t nb_transfered, udd_ep_id_t ep); + +/** + * \brief Authorizes the VBUS event + * + * \return true, if the VBUS monitoring is possible. + */ +bool udd_include_vbus_monitoring(void); + +/** + * \brief Enables the USB Device mode + */ +void udd_enable(void); + +/** + * \brief Disables the USB Device mode + */ +void udd_disable(void); + +/** + * \brief Attach device to the bus when possible + * + * \warning If a VBus control is included in driver, + * then it will attach device when an acceptable Vbus + * level from the host is detected. + */ +void udd_attach(void); + +/** + * \brief Detaches the device from the bus + * + * The driver must remove pull-up on USB line D- or D+. + */ +void udd_detach(void); + +/** + * \brief Test whether the USB Device Controller is running at high + * speed or not. + * + * \return \c true if the Device is running at high speed mode, otherwise \c false. + */ +bool udd_is_high_speed(void); + +/** + * \brief Changes the USB address of device + * + * \param address New USB address + */ +void udd_set_address(uint8_t address); + +/** + * \brief Returns the USB address of device + * + * \return USB address + */ +uint8_t udd_getaddress(void); + +/** + * \brief Returns the current start of frame number + * + * \return current start of frame number. + */ +uint16_t udd_get_frame_number(void); + +/** + * \brief Returns the current micro start of frame number + * + * \return current micro start of frame number required in high speed mode. + */ +uint16_t udd_get_micro_frame_number(void); + +/*! \brief The USB driver sends a resume signal called Upstream Resume + */ +void udd_send_remotewakeup(void); + +/** + * \brief Load setup payload + * + * \param payload Pointer on payload + * \param payload_size Size of payload + */ +void udd_set_setup_payload( uint8_t *payload, uint16_t payload_size ); + + +/** + * \name Endpoint Management + * + * The following functions allow drivers to create and remove + * endpoints, as well as set, clear and query their "halted" and + * "wedged" states. + */ +//@{ + +#if (USB_DEVICE_MAX_EP != 0) + +/** + * \brief Configures and enables an endpoint + * + * \param ep Endpoint number including direction (USB_EP_DIR_IN/USB_EP_DIR_OUT). + * \param bmAttributes Attributes of endpoint declared in the descriptor. + * \param MaxEndpointSize Endpoint maximum size + * + * \return \c 1 if the endpoint is enabled, otherwise \c 0. + */ +bool udd_ep_alloc(udd_ep_id_t ep, uint8_t bmAttributes, + uint16_t MaxEndpointSize); + +/** + * \brief Disables an endpoint + * + * \param ep Endpoint number including direction (USB_EP_DIR_IN/USB_EP_DIR_OUT). + */ +void udd_ep_free(udd_ep_id_t ep); + +/** + * \brief Check if the endpoint \a ep is halted. + * + * \param ep The ID of the endpoint to check. + * + * \return \c 1 if \a ep is halted, otherwise \c 0. + */ +bool udd_ep_is_halted(udd_ep_id_t ep); + +/** + * \brief Set the halted state of the endpoint \a ep + * + * After calling this function, any transaction on \a ep will result + * in a STALL handshake being sent. Any pending transactions will be + * performed first, however. + * + * \param ep The ID of the endpoint to be halted + * + * \return \c 1 if \a ep is halted, otherwise \c 0. + */ +bool udd_ep_set_halt(udd_ep_id_t ep); + +/** + * \brief Clear the halted state of the endpoint \a ep + * + * After calling this function, any transaction on \a ep will + * be handled normally, i.e. a STALL handshake will not be sent, and + * the data toggle sequence will start at DATA0. + * + * \param ep The ID of the endpoint to be un-halted + * + * \return \c 1 if function was successfully done, otherwise \c 0. + */ +bool udd_ep_clear_halt(udd_ep_id_t ep); + +/** + * \brief Registers a callback to call when endpoint halt is cleared + * + * \param ep The ID of the endpoint to use + * \param callback NULL or function to call when endpoint halt is cleared + * + * \warning if the endpoint is not halted then the \a callback is called immediately. + * + * \return \c 1 if the register is accepted, otherwise \c 0. + */ +bool udd_ep_wait_stall_clear(udd_ep_id_t ep, + udd_callback_halt_cleared_t callback); + +/** + * \brief Allows to receive or send data on an endpoint + * + * The driver uses a specific DMA USB to transfer data + * from internal RAM to endpoint, if this one is available. + * When the transfer is finished or aborted (stall, reset, ...), the \a callback is called. + * The \a callback returns the transfer status and eventually the number of byte transfered. + * Note: The control endpoint is not authorized. + * + * \param ep The ID of the endpoint to use + * \param b_shortpacket Enabled automatic short packet + * \param buf Buffer on Internal RAM to send or fill. + * It must be align, then use COMPILER_WORD_ALIGNED. + * \param buf_size Buffer size to send or fill + * \param callback NULL or function to call at the end of transfer + * + * \warning About \a b_shortpacket, for IN endpoint it means that a short packet + * (or a Zero Length Packet) will be sent to the USB line to properly close the usb + * transfer at the end of the data transfer. + * For Bulk and Interrupt OUT endpoint, it will automatically stop the transfer + * at the end of the data transfer (received short packet). + * + * \return \c 1 if function was successfully done, otherwise \c 0. + */ +bool udd_ep_run(udd_ep_id_t ep, bool b_shortpacket, + uint8_t * buf, iram_size_t buf_size, + udd_callback_trans_t callback); +/** + * \brief Aborts transfer on going on endpoint + * + * If a transfer is on going, then it is stopped and + * the callback registered is called to signal the end of transfer. + * Note: The control endpoint is not authorized. + * + * \param ep Endpoint to abort + */ +void udd_ep_abort(udd_ep_id_t ep); + +#endif + +//@} + + +/** + * \name High speed test mode management + * + * The following functions allow the device to jump to a specific test mode required in high speed mode. + */ +//@{ +void udd_test_mode_j(void); +void udd_test_mode_k(void); +void udd_test_mode_se0_nak(void); +void udd_test_mode_packet(void); +//@} + + +/** + * \name UDC callbacks to provide for UDD + * + * The following callbacks are used by UDD. + */ +//@{ + +/** + * \brief Decodes and manages a setup request + * + * The driver call it when a SETUP packet is received. + * The \c udd_g_ctrlreq contains the data of SETUP packet. + * If this callback accepts the setup request then it must + * return \c 1 and eventually update \c udd_g_ctrlreq to send or receive data. + * + * \return \c 1 if the request is accepted, otherwise \c 0. + */ +extern bool udc_process_setup(void); + +/** + * \brief Reset the UDC + * + * The UDC must reset all configuration. + */ +extern void udc_reset(void); + +/** + * \brief To signal that a SOF is occurred + * + * The UDC must send the signal to all UDIs enabled + */ +extern void udc_sof_notify(void); + +//@} + +//@} + +#ifdef __cplusplus +} +#endif +#endif // _UDD_H_ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/udc/udi.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/udc/udi.h new file mode 100755 index 0000000..48287f2 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/udc/udi.h @@ -0,0 +1,130 @@ +/** + * \file + * + * \brief Common API for USB Device Interface + * + * Copyright (c) 2009 - 2012 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _UDI_H_ +#define _UDI_H_ + +#include "conf_usb.h" +#include "usb_protocol.h" + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \ingroup usb_device_group + * \defgroup udi_group USB Device Interface (UDI) + * The UDI provides a common API for all classes, + * and this is used by UDC for the main control of USB Device interface. + * @{ + */ + +/** + * \brief UDI API. + * + * The callbacks within this structure are called only by + * USB Device Controller (UDC) + * + * The udc_get_interface_desc() can be use by UDI to know the interface descriptor + * selected by UDC. + */ +typedef struct { + /** + * \brief Enable the interface. + * + * This function is called when the host selects a configuration + * to which this interface belongs through a Set Configuration + * request, and when the host selects an alternate setting of + * this interface through a Set Interface request. + * + * \return \c 1 if function was successfully done, otherwise \c 0. + */ + bool(*enable) (void); + + /** + * \brief Disable the interface. + * + * This function is called when this interface is currently + * active, and + * - the host selects any configuration through a Set + * Configuration request, or + * - the host issues a USB reset, or + * - the device is detached from the host (i.e. Vbus is no + * longer present) + */ + void (*disable) (void); + + /** + * \brief Handle a control request directed at an interface. + * + * This function is called when this interface is currently + * active and the host sends a SETUP request + * with this interface as the recipient. + * + * Use udd_g_ctrlreq to decode and response to SETUP request. + * + * \return \c 1 if this interface supports the SETUP request, otherwise \c 0. + */ + bool(*setup) (void); + + /** + * \brief Returns the current setting of the selected interface. + * + * This function is called when UDC when know alternate setting of selected interface. + * + * \return alternate setting of selected interface + */ + uint8_t(*getsetting) (void); + + /** + * \brief To signal that a SOF is occurred + */ + void(*sof_notify) (void); +} udi_api_t; + +//@} + +#ifdef __cplusplus +} +#endif +#endif // _UDI_H_ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/usb_atmel.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/usb_atmel.h new file mode 100755 index 0000000..3178aad --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/usb_atmel.h @@ -0,0 +1,187 @@ +/** + * \file + * + * \brief All USB VIDs and PIDs from Atmel USB applications + * + * Copyright (c) 2009-2013 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _USB_ATMEL_H_ +#define _USB_ATMEL_H_ + +/** + * \defgroup usb_group USB Stack + * + * This stack includes the USB Device Stack, USB Host Stack and common + * definitions. + * @{ + */ + +//! @} + +/** + * \ingroup usb_group + * \defgroup usb_atmel_ids_group Atmel USB Identifiers + * + * This module defines Atmel PID and VIDs constants. + * + * @{ + */ + +//! \name Vendor Identifier assigned by USB org to ATMEL +#define USB_VID_ATMEL 0x03EB + + +//! \name Product Identifier assigned by ATMEL to AVR applications +//! @{ + +//! \name The range from 2000h to 20FFh is reserved to the old PID for C51, MEGA, and others. +//! @{ +#define USB_PID_ATMEL_MEGA_HIDGENERIC 0x2013 +#define USB_PID_ATMEL_MEGA_HIDKEYBOARD 0x2017 +#define USB_PID_ATMEL_MEGA_CDC 0x2018 +#define USB_PID_ATMEL_MEGA_AUDIO_IN 0x2019 +#define USB_PID_ATMEL_MEGA_MS 0x201A +#define USB_PID_ATMEL_MEGA_AUDIO_IN_OUT 0x201B +#define USB_PID_ATMEL_MEGA_HIDMOUSE 0x201C +#define USB_PID_ATMEL_MEGA_HIDMOUSE_CERTIF_U4 0x201D +#define USB_PID_ATMEL_MEGA_CDC_MULTI 0x201E +#define USB_PID_ATMEL_MEGA_MS_HIDMS_HID_USBKEY 0x2022 +#define USB_PID_ATMEL_MEGA_MS_HIDMS_HID_STK525 0x2023 +#define USB_PID_ATMEL_MEGA_MS_2 0x2029 +#define USB_PID_ATMEL_MEGA_MS_HIDMS 0x202A +#define USB_PID_ATMEL_MEGA_MS_3 0x2032 +#define USB_PID_ATMEL_MEGA_LIBUSB 0x2050 +//! @} + +//! \name The range 2100h to 21FFh is reserved to PIDs for AVR Tools. +//! @{ +#define USB_PID_ATMEL_XPLAINED 0x2122 +#define USB_PID_ATMEL_XMEGA_USB_ZIGBIT_2_4GHZ 0x214A +#define USB_PID_ATMEL_XMEGA_USB_ZIGBIT_SUBGHZ 0x214B +//! @} + +//! \name The range 2300h to 23FFh is reserved to PIDs for demo from ASF1.7=> +//! @{ +#define USB_PID_ATMEL_UC3_ENUM 0x2300 +#define USB_PID_ATMEL_UC3_MS 0x2301 +#define USB_PID_ATMEL_UC3_MS_SDRAM_LOADER 0x2302 +#define USB_PID_ATMEL_UC3_EVK1100_CTRLPANEL 0x2303 +#define USB_PID_ATMEL_UC3_HID 0x2304 +#define USB_PID_ATMEL_UC3_EVK1101_CTRLPANEL_HID 0x2305 +#define USB_PID_ATMEL_UC3_EVK1101_CTRLPANEL_HID_MS 0x2306 +#define USB_PID_ATMEL_UC3_CDC 0x2307 +#define USB_PID_ATMEL_UC3_AUDIO_MICRO 0x2308 +#define USB_PID_ATMEL_UC3_CDC_DEBUG 0x2310 // Virtual Com (debug interface) on EVK11xx +#define USB_PID_ATMEL_UC3_AUDIO_SPEAKER_MICRO 0x2311 +#define USB_PID_ATMEL_UC3_CDC_MSC 0x2312 +//! @} + +//! \name The range 2400h to 24FFh is reserved to PIDs for ASF applications +//! @{ +#define USB_PID_ATMEL_ASF_HIDMOUSE 0x2400 +#define USB_PID_ATMEL_ASF_HIDKEYBOARD 0x2401 +#define USB_PID_ATMEL_ASF_HIDGENERIC 0x2402 +#define USB_PID_ATMEL_ASF_MSC 0x2403 +#define USB_PID_ATMEL_ASF_CDC 0x2404 +#define USB_PID_ATMEL_ASF_PHDC 0x2405 +#define USB_PID_ATMEL_ASF_MSC_HIDMOUSE 0x2420 +#define USB_PID_ATMEL_ASF_MSC_HIDS_CDC 0x2421 +#define USB_PID_ATMEL_ASF_MSC_HIDKEYBOARD 0x2422 +#define USB_PID_ATMEL_ASF_VENDOR_CLASS 0x2423 +#define USB_PID_ATMEL_ASF_MSC_CDC 0x2424 +#define USB_PID_ATMEL_ASF_TWO_CDC 0x2425 +#define USB_PID_ATMEL_ASF_SEVEN_CDC 0x2426 +#define USB_PID_ATMEL_ASF_XPLAIN_BC_POWERONLY 0x2430 +#define USB_PID_ATMEL_ASF_XPLAIN_BC_TERMINAL 0x2431 +#define USB_PID_ATMEL_ASF_XPLAIN_BC_TOUCH 0x2432 +#define USB_PID_ATMEL_ASF_AUDIO_SPEAKER 0x2433 +#define USB_PID_ATMEL_ASF_XMEGA_B1_XPLAINED 0x2434 +//! @} + +//! \name The range 2F00h to 2FFFh is reserved to official PIDs for AVR bootloaders +//! Note, !!!! don't use this range for demos or examples !!!! +//! @{ +#define USB_PID_ATMEL_DFU_ATXMEGA64C3 0x2FD6 +#define USB_PID_ATMEL_DFU_ATXMEGA128C3 0x2FD7 +#define USB_PID_ATMEL_DFU_ATXMEGA16C4 0x2FD8 +#define USB_PID_ATMEL_DFU_ATXMEGA32C4 0x2FD9 +#define USB_PID_ATMEL_DFU_ATXMEGA256C3 0x2FDA +#define USB_PID_ATMEL_DFU_ATXMEGA384C3 0x2FDB +#define USB_PID_ATMEL_DFU_ATUCL3_L4 0x2FDC +#define USB_PID_ATMEL_DFU_ATXMEGA64A4U 0x2FDD +#define USB_PID_ATMEL_DFU_ATXMEGA128A4U 0x2FDE + +#define USB_PID_ATMEL_DFU_ATXMEGA64B3 0x2FDF +#define USB_PID_ATMEL_DFU_ATXMEGA128B3 0x2FE0 +#define USB_PID_ATMEL_DFU_ATXMEGA64B1 0x2FE1 +#define USB_PID_ATMEL_DFU_ATXMEGA256A3BU 0x2FE2 +#define USB_PID_ATMEL_DFU_ATXMEGA16A4U 0x2FE3 +#define USB_PID_ATMEL_DFU_ATXMEGA32A4U 0x2FE4 +#define USB_PID_ATMEL_DFU_ATXMEGA64A3U 0x2FE5 +#define USB_PID_ATMEL_DFU_ATXMEGA128A3U 0x2FE6 +#define USB_PID_ATMEL_DFU_ATXMEGA192A3U 0x2FE7 +#define USB_PID_ATMEL_DFU_ATXMEGA64A1U 0x2FE8 +#define USB_PID_ATMEL_DFU_ATUC3D 0x2FE9 +#define USB_PID_ATMEL_DFU_ATXMEGA128B1 0x2FEA +#define USB_PID_ATMEL_DFU_AT32UC3C 0x2FEB +#define USB_PID_ATMEL_DFU_ATXMEGA256A3U 0x2FEC +#define USB_PID_ATMEL_DFU_ATXMEGA128A1U 0x2FED +#define USB_PID_ATMEL_DFU_ATMEGA8U2 0x2FEE +#define USB_PID_ATMEL_DFU_ATMEGA16U2 0x2FEF +#define USB_PID_ATMEL_DFU_ATMEGA32U2 0x2FF0 +#define USB_PID_ATMEL_DFU_AT32UC3A3 0x2FF1 +#define USB_PID_ATMEL_DFU_ATMEGA32U6 0x2FF2 +#define USB_PID_ATMEL_DFU_ATMEGA16U4 0x2FF3 +#define USB_PID_ATMEL_DFU_ATMEGA32U4 0x2FF4 +#define USB_PID_ATMEL_DFU_AT32AP7200 0x2FF5 +#define USB_PID_ATMEL_DFU_AT32UC3B 0x2FF6 +#define USB_PID_ATMEL_DFU_AT90USB82 0x2FF7 +#define USB_PID_ATMEL_DFU_AT32UC3A 0x2FF8 +#define USB_PID_ATMEL_DFU_AT90USB64 0x2FF9 +#define USB_PID_ATMEL_DFU_AT90USB162 0x2FFA +#define USB_PID_ATMEL_DFU_AT90USB128 0x2FFB +// 2FFCh to 2FFFh used by C51 family products +//! @} + +//! @} + +//! @} + + +#endif // _USB_ATMEL_H_ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/usb_protocol.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/usb_protocol.h new file mode 100755 index 0000000..c65c0f7 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/services/usb/usb_protocol.h @@ -0,0 +1,502 @@ +/** + * \file + * + * \brief USB protocol definitions. + * + * This file contains the USB definitions and data structures provided by the + * USB 2.0 specification. + * + * Copyright (c) 2009-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _USB_PROTOCOL_H_ +#define _USB_PROTOCOL_H_ + +#include "usb_atmel.h" + +/** + * \ingroup usb_group + * \defgroup usb_protocol_group USB Protocol Definitions + * + * This module defines constants and data structures provided by the USB + * 2.0 specification. + * + * @{ + */ + +//! Value for field bcdUSB +#define USB_V2_0 0x0200 //!< USB Specification version 2.00 +#define USB_V2_1 0x0201 //!< USB Specification version 2.01 + +/*! \name Generic definitions (Class, subclass and protocol) + */ +//! @{ +#define NO_CLASS 0x00 +#define CLASS_VENDOR_SPECIFIC 0xFF +#define NO_SUBCLASS 0x00 +#define NO_PROTOCOL 0x00 +//! @} + +//! \name IAD (Interface Association Descriptor) constants +//! @{ +#define CLASS_IAD 0xEF +#define SUB_CLASS_IAD 0x02 +#define PROTOCOL_IAD 0x01 +//! @} + +/** + * \brief USB request data transfer direction (bmRequestType) + */ +#define USB_REQ_DIR_OUT (0<<7) //!< Host to device +#define USB_REQ_DIR_IN (1<<7) //!< Device to host +#define USB_REQ_DIR_MASK (1<<7) //!< Mask + +/** + * \brief USB request types (bmRequestType) + */ +#define USB_REQ_TYPE_STANDARD (0<<5) //!< Standard request +#define USB_REQ_TYPE_CLASS (1<<5) //!< Class-specific request +#define USB_REQ_TYPE_VENDOR (2<<5) //!< Vendor-specific request +#define USB_REQ_TYPE_MASK (3<<5) //!< Mask + +/** + * \brief USB recipient codes (bmRequestType) + */ +#define USB_REQ_RECIP_DEVICE (0<<0) //!< Recipient device +#define USB_REQ_RECIP_INTERFACE (1<<0) //!< Recipient interface +#define USB_REQ_RECIP_ENDPOINT (2<<0) //!< Recipient endpoint +#define USB_REQ_RECIP_OTHER (3<<0) //!< Recipient other +#define USB_REQ_RECIP_MASK (0x1F) //!< Mask + +/** + * \brief Standard USB requests (bRequest) + */ +enum usb_reqid { + USB_REQ_GET_STATUS = 0, + USB_REQ_CLEAR_FEATURE = 1, + USB_REQ_SET_FEATURE = 3, + USB_REQ_SET_ADDRESS = 5, + USB_REQ_GET_DESCRIPTOR = 6, + USB_REQ_SET_DESCRIPTOR = 7, + USB_REQ_GET_CONFIGURATION = 8, + USB_REQ_SET_CONFIGURATION = 9, + USB_REQ_GET_INTERFACE = 10, + USB_REQ_SET_INTERFACE = 11, + USB_REQ_SYNCH_FRAME = 12, +}; + +/** + * \brief Standard USB device status flags + * + */ +enum usb_device_status { + USB_DEV_STATUS_BUS_POWERED = 0, + USB_DEV_STATUS_SELF_POWERED = 1, + USB_DEV_STATUS_REMOTEWAKEUP = 2 +}; + +/** + * \brief Standard USB Interface status flags + * + */ +enum usb_interface_status { + USB_IFACE_STATUS_RESERVED = 0 +}; + +/** + * \brief Standard USB endpoint status flags + * + */ +enum usb_endpoint_status { + USB_EP_STATUS_HALTED = 1, +}; + +/** + * \brief Standard USB device feature flags + * + * \note valid for SetFeature request. + */ +enum usb_device_feature { + USB_DEV_FEATURE_REMOTE_WAKEUP = 1, //!< Remote wakeup enabled + USB_DEV_FEATURE_TEST_MODE = 2, //!< USB test mode + USB_DEV_FEATURE_OTG_B_HNP_ENABLE = 3, + USB_DEV_FEATURE_OTG_A_HNP_SUPPORT = 4, + USB_DEV_FEATURE_OTG_A_ALT_HNP_SUPPORT = 5 +}; + +/** + * \brief Test Mode possible on HS USB device + * + * \note valid for USB_DEV_FEATURE_TEST_MODE request. + */ +enum usb_device_hs_test_mode { + USB_DEV_TEST_MODE_J = 1, + USB_DEV_TEST_MODE_K = 2, + USB_DEV_TEST_MODE_SE0_NAK = 3, + USB_DEV_TEST_MODE_PACKET = 4, + USB_DEV_TEST_MODE_FORCE_ENABLE = 5, +}; + +/** + * \brief Standard USB endpoint feature/status flags + */ +enum usb_endpoint_feature { + USB_EP_FEATURE_HALT = 0, +}; + +/** + * \brief Standard USB Test Mode Selectors + */ +enum usb_test_mode_selector { + USB_TEST_J = 0x01, + USB_TEST_K = 0x02, + USB_TEST_SE0_NAK = 0x03, + USB_TEST_PACKET = 0x04, + USB_TEST_FORCE_ENABLE = 0x05, +}; + +/** + * \brief Standard USB descriptor types + */ +enum usb_descriptor_type { + USB_DT_DEVICE = 1, + USB_DT_CONFIGURATION = 2, + USB_DT_STRING = 3, + USB_DT_INTERFACE = 4, + USB_DT_ENDPOINT = 5, + USB_DT_DEVICE_QUALIFIER = 6, + USB_DT_OTHER_SPEED_CONFIGURATION = 7, + USB_DT_INTERFACE_POWER = 8, + USB_DT_OTG = 9, + USB_DT_IAD = 0x0B, + USB_DT_BOS = 0x0F, + USB_DT_DEVICE_CAPABILITY = 0x10, +}; + +/** + * \brief USB Device Capability types + */ +enum usb_capability_type { + USB_DC_USB20_EXTENSION = 0x02, +}; + +/** + * \brief USB Device Capability - USB 2.0 Extension + * To fill bmAttributes field of usb_capa_ext_desc_t structure. + */ +enum usb_capability_extension_attr { + USB_DC_EXT_LPM = 0x00000002, + USB_DC_EXT_BESL = 0x00000004, + USB_DC_EXT_BESL_BASELINE_VALID = 0x00000008, + USB_DC_EXT_BESL_DEEP_VALID = 0x00000010, +}; +#define USB_DC_EXT_BESL_DEEP_OFFSET 8 +#define USB_DC_EXT_BESL_DEEP(besl) ((besl & 0xF) << USB_DC_EXT_BESL_DEEP_OFFSET) +#define USB_DC_EXT_BESL_BASELINE_OFFSET 12 +#define USB_DC_EXT_BESL_BASELINE(besl) ((besl & 0xF) << USB_DC_EXT_BESL_BASELINE_OFFSET) + +#define BESL_125_US 0 +#define BESL_150_US 1 +#define BESL_200_US 2 +#define BESL_300_US 3 +#define BESL_400_US 4 +#define BESL_500_US 5 +#define BESL_1000_US 6 +#define BESL_2000_US 7 +#define BESL_3000_US 8 +#define BESL_4000_US 9 +#define BESL_5000_US 10 +#define BESL_6000_US 11 +#define BESL_7000_US 12 +#define BESL_8000_US 13 +#define BESL_9000_US 14 +#define BESL_10000_US 15 + +/** Fields definition from a LPM TOKEN */ +#define USB_LPM_ATTRIBUT_BLINKSTATE_MASK (0xF << 0) +#define USB_LPM_ATTRIBUT_BESL_MASK (0xF << 4) +#define USB_LPM_ATTRIBUT_REMOTEWAKE_MASK (1 << 8) +#define USB_LPM_ATTRIBUT_BLINKSTATE(value) ((value & 0xF) << 0) +#define USB_LPM_ATTRIBUT_BESL(value) ((value & 0xF) << 4) +#define USB_LPM_ATTRIBUT_REMOTEWAKE(value) ((value & 1) << 8) +#define USB_LPM_ATTRIBUT_BLINKSTATE_L1 USB_LPM_ATTRIBUT_BLINKSTATE(1) + +/** + * \brief Standard USB endpoint transfer types + */ +enum usb_ep_type { + USB_EP_TYPE_CONTROL = 0x00, + USB_EP_TYPE_ISOCHRONOUS = 0x01, + USB_EP_TYPE_BULK = 0x02, + USB_EP_TYPE_INTERRUPT = 0x03, + USB_EP_TYPE_MASK = 0x03, +}; + +/** + * \brief Standard USB language IDs for string descriptors + */ +enum usb_langid { + USB_LANGID_EN_US = 0x0409, //!< English (United States) +}; + +/** + * \brief Mask selecting the index part of an endpoint address + */ +#define USB_EP_ADDR_MASK 0x0f + +//! \brief USB address identifier +typedef uint8_t usb_add_t; + +/** + * \brief Endpoint transfer direction is IN + */ +#define USB_EP_DIR_IN 0x80 + +/** + * \brief Endpoint transfer direction is OUT + */ +#define USB_EP_DIR_OUT 0x00 + +//! \brief Endpoint identifier +typedef uint8_t usb_ep_t; + +/** + * \brief Maximum length in bytes of a USB descriptor + * + * The maximum length of a USB descriptor is limited by the 8-bit + * bLength field. + */ +#define USB_MAX_DESC_LEN 255 + +/* + * 2-byte alignment requested for all USB structures. + */ +COMPILER_PACK_SET(1) + +/** + * \brief A USB Device SETUP request + * + * The data payload of SETUP packets always follows this structure. + */ +typedef struct { + uint8_t bmRequestType; + uint8_t bRequest; + le16_t wValue; + le16_t wIndex; + le16_t wLength; +} usb_setup_req_t; + +/** + * \brief Standard USB device descriptor structure + */ +typedef struct { + uint8_t bLength; + uint8_t bDescriptorType; + le16_t bcdUSB; + uint8_t bDeviceClass; + uint8_t bDeviceSubClass; + uint8_t bDeviceProtocol; + uint8_t bMaxPacketSize0; + le16_t idVendor; + le16_t idProduct; + le16_t bcdDevice; + uint8_t iManufacturer; + uint8_t iProduct; + uint8_t iSerialNumber; + uint8_t bNumConfigurations; +} usb_dev_desc_t; + +/** + * \brief Standard USB device qualifier descriptor structure + * + * This descriptor contains information about the device when running at + * the "other" speed (i.e. if the device is currently operating at high + * speed, this descriptor can be used to determine what would change if + * the device was operating at full speed.) + */ +typedef struct { + uint8_t bLength; + uint8_t bDescriptorType; + le16_t bcdUSB; + uint8_t bDeviceClass; + uint8_t bDeviceSubClass; + uint8_t bDeviceProtocol; + uint8_t bMaxPacketSize0; + uint8_t bNumConfigurations; + uint8_t bReserved; +} usb_dev_qual_desc_t; + +/** + * \brief USB Device BOS descriptor structure + * + * The BOS descriptor (Binary device Object Store) defines a root + * descriptor that is similar to the configuration descriptor, and is + * the base descriptor for accessing a family of related descriptors. + * A host can read a BOS descriptor and learn from the wTotalLength field + * the entire size of the device-level descriptor set, or it can read in + * the entire BOS descriptor set of device capabilities. + * The host accesses this descriptor using the GetDescriptor() request. + * The descriptor type in the GetDescriptor() request is set to BOS. + */ +typedef struct { + uint8_t bLength; + uint8_t bDescriptorType; + le16_t wTotalLength; + uint8_t bNumDeviceCaps; +} usb_dev_bos_desc_t; + + +/** + * \brief USB Device Capabilities - USB 2.0 Extension Descriptor structure + * + * Defines the set of USB 1.1-specific device level capabilities. + */ +typedef struct { + uint8_t bLength; + uint8_t bDescriptorType; + uint8_t bDevCapabilityType; + le32_t bmAttributes; +} usb_dev_capa_ext_desc_t; + +/** + * \brief USB Device LPM Descriptor structure + * + * The BOS descriptor and capabilities descriptors for LPM. + */ +typedef struct { + usb_dev_bos_desc_t bos; + usb_dev_capa_ext_desc_t capa_ext; +} usb_dev_lpm_desc_t; + +/** + * \brief Standard USB Interface Association Descriptor structure + */ +typedef struct { + uint8_t bLength; //!< size of this descriptor in bytes + uint8_t bDescriptorType; //!< INTERFACE descriptor type + uint8_t bFirstInterface; //!< Number of interface + uint8_t bInterfaceCount; //!< value to select alternate setting + uint8_t bFunctionClass; //!< Class code assigned by the USB + uint8_t bFunctionSubClass;//!< Sub-class code assigned by the USB + uint8_t bFunctionProtocol;//!< Protocol code assigned by the USB + uint8_t iFunction; //!< Index of string descriptor +} usb_association_desc_t; + + +/** + * \brief Standard USB configuration descriptor structure + */ +typedef struct { + uint8_t bLength; + uint8_t bDescriptorType; + le16_t wTotalLength; + uint8_t bNumInterfaces; + uint8_t bConfigurationValue; + uint8_t iConfiguration; + uint8_t bmAttributes; + uint8_t bMaxPower; +} usb_conf_desc_t; + + +#define USB_CONFIG_ATTR_MUST_SET (1 << 7) //!< Must always be set +#define USB_CONFIG_ATTR_BUS_POWERED (0 << 6) //!< Bus-powered +#define USB_CONFIG_ATTR_SELF_POWERED (1 << 6) //!< Self-powered +#define USB_CONFIG_ATTR_REMOTE_WAKEUP (1 << 5) //!< remote wakeup supported + +#define USB_CONFIG_MAX_POWER(ma) (((ma) + 1) / 2) //!< Max power in mA + +/** + * \brief Standard USB association descriptor structure + */ +typedef struct { + uint8_t bLength; //!< Size of this descriptor in bytes + uint8_t bDescriptorType; //!< Interface descriptor type + uint8_t bFirstInterface; //!< Number of interface + uint8_t bInterfaceCount; //!< value to select alternate setting + uint8_t bFunctionClass; //!< Class code assigned by the USB + uint8_t bFunctionSubClass; //!< Sub-class code assigned by the USB + uint8_t bFunctionProtocol; //!< Protocol code assigned by the USB + uint8_t iFunction; //!< Index of string descriptor +} usb_iad_desc_t; + +/** + * \brief Standard USB interface descriptor structure + */ +typedef struct { + uint8_t bLength; + uint8_t bDescriptorType; + uint8_t bInterfaceNumber; + uint8_t bAlternateSetting; + uint8_t bNumEndpoints; + uint8_t bInterfaceClass; + uint8_t bInterfaceSubClass; + uint8_t bInterfaceProtocol; + uint8_t iInterface; +} usb_iface_desc_t; + +/** + * \brief Standard USB endpoint descriptor structure + */ +typedef struct { + uint8_t bLength; + uint8_t bDescriptorType; + uint8_t bEndpointAddress; + uint8_t bmAttributes; + le16_t wMaxPacketSize; + uint8_t bInterval; +} usb_ep_desc_t; + + +/** + * \brief A standard USB string descriptor structure + */ +typedef struct { + uint8_t bLength; + uint8_t bDescriptorType; +} usb_str_desc_t; + +typedef struct { + usb_str_desc_t desc; + le16_t string[1]; +} usb_str_lgid_desc_t; + +COMPILER_PACK_RESET() + +//! @} + +#endif /* _USB_PROTOCOL_H_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/utils/interrupt.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/utils/interrupt.h new file mode 100755 index 0000000..3613a26 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/utils/interrupt.h @@ -0,0 +1,139 @@ +/** + * \file + * + * \brief Global interrupt management for 8- and 32-bit AVR + * + * Copyright (c) 2010-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef UTILS_INTERRUPT_H +#define UTILS_INTERRUPT_H + +#include + +#if XMEGA || MEGA || TINY +# include "interrupt/interrupt_avr8.h" +#elif UC3 +# include "interrupt/interrupt_avr32.h" +#elif SAM +# include "interrupt/interrupt_sam_nvic.h" +#else +# error Unsupported device. +#endif + +/** + * \defgroup interrupt_group Global interrupt management + * + * This is a driver for global enabling and disabling of interrupts. + * + * @{ + */ + +#if defined(__DOXYGEN__) +/** + * \def CONFIG_INTERRUPT_FORCE_INTC + * \brief Force usage of the ASF INTC driver + * + * Predefine this symbol when preprocessing to force the use of the ASF INTC driver. + * This is useful to ensure compatibility across compilers and shall be used only when required + * by the application needs. + */ +# define CONFIG_INTERRUPT_FORCE_INTC +#endif + +//! \name Global interrupt flags +//@{ +/** + * \typedef irqflags_t + * \brief Type used for holding state of interrupt flag + */ + +/** + * \def cpu_irq_enable + * \brief Enable interrupts globally + */ + +/** + * \def cpu_irq_disable + * \brief Disable interrupts globally + */ + +/** + * \fn irqflags_t cpu_irq_save(void) + * \brief Get and clear the global interrupt flags + * + * Use in conjunction with \ref cpu_irq_restore. + * + * \return Current state of interrupt flags. + * + * \note This function leaves interrupts disabled. + */ + +/** + * \fn void cpu_irq_restore(irqflags_t flags) + * \brief Restore global interrupt flags + * + * Use in conjunction with \ref cpu_irq_save. + * + * \param flags State to set interrupt flag to. + */ + +/** + * \fn bool cpu_irq_is_enabled_flags(irqflags_t flags) + * \brief Check if interrupts are globally enabled in supplied flags + * + * \param flags Currents state of interrupt flags. + * + * \return True if interrupts are enabled. + */ + +/** + * \def cpu_irq_is_enabled + * \brief Check if interrupts are globally enabled + * + * \return True if interrupts are enabled. + */ +//@} + +//! @} + +/** + * \ingroup interrupt_group + * \defgroup interrupt_deprecated_group Deprecated interrupt definitions + */ + +#endif /* UTILS_INTERRUPT_H */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/utils/interrupt/interrupt_sam_nvic.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/utils/interrupt/interrupt_sam_nvic.c new file mode 100755 index 0000000..ee93274 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/utils/interrupt/interrupt_sam_nvic.c @@ -0,0 +1,83 @@ +/** + * \file + * + * \brief Global interrupt management for SAM D20, SAM3 and SAM4 (NVIC based) + * + * Copyright (c) 2012-2013 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include "interrupt_sam_nvic.h" + +#if !defined(__DOXYGEN__) +/* Deprecated - global flag to determine the global interrupt state. Required by + * QTouch library, however new applications should use cpu_irq_is_enabled() + * which probes the true global interrupt state from the CPU special registers. + */ +volatile bool g_interrupt_enabled = true; +#endif + +void cpu_irq_enter_critical(void) +{ + if (cpu_irq_critical_section_counter == 0) { + if (cpu_irq_is_enabled()) { + cpu_irq_disable(); + cpu_irq_prev_interrupt_state = true; + } else { + /* Make sure the to save the prev state as false */ + cpu_irq_prev_interrupt_state = false; + } + + } + + cpu_irq_critical_section_counter++; +} + +void cpu_irq_leave_critical(void) +{ + /* Check if the user is trying to leave a critical section when not in a critical section */ + Assert(cpu_irq_critical_section_counter > 0); + + cpu_irq_critical_section_counter--; + + /* Only enable global interrupts when the counter reaches 0 and the state of the global interrupt flag + was enabled when entering critical state */ + if ((cpu_irq_critical_section_counter == 0) && (cpu_irq_prev_interrupt_state)) { + cpu_irq_enable(); + } +} + diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/utils/interrupt/interrupt_sam_nvic.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/utils/interrupt/interrupt_sam_nvic.h new file mode 100755 index 0000000..1b23b08 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/utils/interrupt/interrupt_sam_nvic.h @@ -0,0 +1,186 @@ +/** + * \file + * + * \brief Global interrupt management for SAM D20, SAM3 and SAM4 (NVIC based) + * + * Copyright (c) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef UTILS_INTERRUPT_INTERRUPT_H +#define UTILS_INTERRUPT_INTERRUPT_H + +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \weakgroup interrupt_group + * + * @{ + */ + +/** + * \name Interrupt Service Routine definition + * + * @{ + */ + +/** + * \brief Define service routine + * + * \note For NVIC devices the interrupt service routines are predefined to + * add to vector table in binary generation, so there is no service + * register at run time. The routine collections are in exceptions.h. + * + * Usage: + * \code + ISR(foo_irq_handler) + { + // Function definition + ... + } +\endcode + * + * \param func Name for the function. + */ +# define ISR(func) \ + void func (void) + +/** + * \brief Initialize interrupt vectors + * + * For NVIC the interrupt vectors are put in vector table. So nothing + * to do to initialize them, except defined the vector function with + * right name. + * + * This must be called prior to \ref irq_register_handler. + */ +# define irq_initialize_vectors() \ + do { \ + } while(0) + +/** + * \brief Register handler for interrupt + * + * For NVIC the interrupt vectors are put in vector table. So nothing + * to do to register them, except defined the vector function with + * right name. + * + * Usage: + * \code + irq_initialize_vectors(); + irq_register_handler(foo_irq_handler); +\endcode + * + * \note The function \a func must be defined with the \ref ISR macro. + * \note The functions prototypes can be found in the device exception header + * files (exceptions.h). + */ +# define irq_register_handler(int_num, int_prio) \ + NVIC_ClearPendingIRQ( (IRQn_Type)int_num); \ + NVIC_SetPriority( (IRQn_Type)int_num, int_prio); \ + NVIC_EnableIRQ( (IRQn_Type)int_num); \ + +//@} + +# define cpu_irq_enable() \ + do { \ + g_interrupt_enabled = true; \ + __DMB(); \ + __enable_irq(); \ + } while (0) +# define cpu_irq_disable() \ + do { \ + __disable_irq(); \ + __DMB(); \ + g_interrupt_enabled = false; \ + } while (0) + +typedef uint32_t irqflags_t; + +#if !defined(__DOXYGEN__) +extern volatile bool g_interrupt_enabled; +#endif + +#define cpu_irq_is_enabled() (__get_PRIMASK() == 0) + +static volatile uint32_t cpu_irq_critical_section_counter; +static volatile bool cpu_irq_prev_interrupt_state; + +static inline irqflags_t cpu_irq_save(void) +{ + irqflags_t flags = cpu_irq_is_enabled(); + cpu_irq_disable(); + return flags; +} + +static inline bool cpu_irq_is_enabled_flags(irqflags_t flags) +{ + return (flags); +} + +static inline void cpu_irq_restore(irqflags_t flags) +{ + if (cpu_irq_is_enabled_flags(flags)) + cpu_irq_enable(); +} + +void cpu_irq_enter_critical(void); +void cpu_irq_leave_critical(void); + +/** + * \weakgroup interrupt_deprecated_group + * @{ + */ + +#define Enable_global_interrupt() cpu_irq_enable() +#define Disable_global_interrupt() cpu_irq_disable() +#define Is_global_interrupt_enabled() cpu_irq_is_enabled() + +//@} + +//@} + +#ifdef __cplusplus +} +#endif + +#endif /* UTILS_INTERRUPT_INTERRUPT_H */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/utils/parts.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/utils/parts.h new file mode 100755 index 0000000..3304a74 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/common/utils/parts.h @@ -0,0 +1,1242 @@ +/** + * \file + * + * \brief Atmel part identification macros + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef ATMEL_PARTS_H +#define ATMEL_PARTS_H + +/** + * \defgroup part_macros_group Atmel part identification macros + * + * This collection of macros identify which series and families that the various + * Atmel parts belong to. These can be used to select part-dependent sections of + * code at compile time. + * + * @{ + */ + +/** + * \name Convenience macros for part checking + * @{ + */ +/* ! Check GCC and IAR part definition for 8-bit AVR */ +#define AVR8_PART_IS_DEFINED(part) \ + (defined(__ ## part ## __) || defined(__AVR_ ## part ## __)) + +/* ! Check GCC and IAR part definition for 32-bit AVR */ +#define AVR32_PART_IS_DEFINED(part) \ + (defined(__AT32 ## part ## __) || defined(__AVR32_ ## part ## __)) + +/* ! Check GCC and IAR part definition for SAM */ +#define SAM_PART_IS_DEFINED(part) (defined(__ ## part ## __)) +/** @} */ + +/** + * \defgroup uc3_part_macros_group AVR UC3 parts + * @{ + */ + +/** + * \name AVR UC3 A series + * @{ + */ +#define UC3A0 ( \ + AVR32_PART_IS_DEFINED(UC3A0128) || \ + AVR32_PART_IS_DEFINED(UC3A0256) || \ + AVR32_PART_IS_DEFINED(UC3A0512) \ + ) + +#define UC3A1 ( \ + AVR32_PART_IS_DEFINED(UC3A1128) || \ + AVR32_PART_IS_DEFINED(UC3A1256) || \ + AVR32_PART_IS_DEFINED(UC3A1512) \ + ) + +#define UC3A3 ( \ + AVR32_PART_IS_DEFINED(UC3A364) || \ + AVR32_PART_IS_DEFINED(UC3A364S) || \ + AVR32_PART_IS_DEFINED(UC3A3128) || \ + AVR32_PART_IS_DEFINED(UC3A3128S) || \ + AVR32_PART_IS_DEFINED(UC3A3256) || \ + AVR32_PART_IS_DEFINED(UC3A3256S) \ + ) + +#define UC3A4 ( \ + AVR32_PART_IS_DEFINED(UC3A464) || \ + AVR32_PART_IS_DEFINED(UC3A464S) || \ + AVR32_PART_IS_DEFINED(UC3A4128) || \ + AVR32_PART_IS_DEFINED(UC3A4128S) || \ + AVR32_PART_IS_DEFINED(UC3A4256) || \ + AVR32_PART_IS_DEFINED(UC3A4256S) \ + ) +/** @} */ + +/** + * \name AVR UC3 B series + * @{ + */ +#define UC3B0 ( \ + AVR32_PART_IS_DEFINED(UC3B064) || \ + AVR32_PART_IS_DEFINED(UC3B0128) || \ + AVR32_PART_IS_DEFINED(UC3B0256) || \ + AVR32_PART_IS_DEFINED(UC3B0512) \ + ) + +#define UC3B1 ( \ + AVR32_PART_IS_DEFINED(UC3B164) || \ + AVR32_PART_IS_DEFINED(UC3B1128) || \ + AVR32_PART_IS_DEFINED(UC3B1256) || \ + AVR32_PART_IS_DEFINED(UC3B1512) \ + ) +/** @} */ + +/** + * \name AVR UC3 C series + * @{ + */ +#define UC3C0 ( \ + AVR32_PART_IS_DEFINED(UC3C064C) || \ + AVR32_PART_IS_DEFINED(UC3C0128C) || \ + AVR32_PART_IS_DEFINED(UC3C0256C) || \ + AVR32_PART_IS_DEFINED(UC3C0512C) \ + ) + +#define UC3C1 ( \ + AVR32_PART_IS_DEFINED(UC3C164C) || \ + AVR32_PART_IS_DEFINED(UC3C1128C) || \ + AVR32_PART_IS_DEFINED(UC3C1256C) || \ + AVR32_PART_IS_DEFINED(UC3C1512C) \ + ) + +#define UC3C2 ( \ + AVR32_PART_IS_DEFINED(UC3C264C) || \ + AVR32_PART_IS_DEFINED(UC3C2128C) || \ + AVR32_PART_IS_DEFINED(UC3C2256C) || \ + AVR32_PART_IS_DEFINED(UC3C2512C) \ + ) +/** @} */ + +/** + * \name AVR UC3 D series + * @{ + */ +#define UC3D3 ( \ + AVR32_PART_IS_DEFINED(UC64D3) || \ + AVR32_PART_IS_DEFINED(UC128D3) \ + ) + +#define UC3D4 ( \ + AVR32_PART_IS_DEFINED(UC64D4) || \ + AVR32_PART_IS_DEFINED(UC128D4) \ + ) +/** @} */ + +/** + * \name AVR UC3 L series + * @{ + */ +#define UC3L0 ( \ + AVR32_PART_IS_DEFINED(UC3L016) || \ + AVR32_PART_IS_DEFINED(UC3L032) || \ + AVR32_PART_IS_DEFINED(UC3L064) \ + ) + +#define UC3L0128 ( \ + AVR32_PART_IS_DEFINED(UC3L0128) \ + ) + +#define UC3L0256 ( \ + AVR32_PART_IS_DEFINED(UC3L0256) \ + ) + +#define UC3L3 ( \ + AVR32_PART_IS_DEFINED(UC64L3U) || \ + AVR32_PART_IS_DEFINED(UC128L3U) || \ + AVR32_PART_IS_DEFINED(UC256L3U) \ + ) + +#define UC3L4 ( \ + AVR32_PART_IS_DEFINED(UC64L4U) || \ + AVR32_PART_IS_DEFINED(UC128L4U) || \ + AVR32_PART_IS_DEFINED(UC256L4U) \ + ) + +#define UC3L3_L4 (UC3L3 || UC3L4) +/** @} */ + +/** + * \name AVR UC3 families + * @{ + */ +/** AVR UC3 A family */ +#define UC3A (UC3A0 || UC3A1 || UC3A3 || UC3A4) + +/** AVR UC3 B family */ +#define UC3B (UC3B0 || UC3B1) + +/** AVR UC3 C family */ +#define UC3C (UC3C0 || UC3C1 || UC3C2) + +/** AVR UC3 D family */ +#define UC3D (UC3D3 || UC3D4) + +/** AVR UC3 L family */ +#define UC3L (UC3L0 || UC3L0128 || UC3L0256 || UC3L3_L4) +/** @} */ + +/** AVR UC3 product line */ +#define UC3 (UC3A || UC3B || UC3C || UC3D || UC3L) + +/** @} */ + +/** + * \defgroup xmega_part_macros_group AVR XMEGA parts + * @{ + */ + +/** + * \name AVR XMEGA A series + * @{ + */ +#define XMEGA_A1 ( \ + AVR8_PART_IS_DEFINED(ATxmega64A1) || \ + AVR8_PART_IS_DEFINED(ATxmega128A1) \ + ) + +#define XMEGA_A3 ( \ + AVR8_PART_IS_DEFINED(ATxmega64A3) || \ + AVR8_PART_IS_DEFINED(ATxmega128A3) || \ + AVR8_PART_IS_DEFINED(ATxmega192A3) || \ + AVR8_PART_IS_DEFINED(ATxmega256A3) \ + ) + +#define XMEGA_A3B ( \ + AVR8_PART_IS_DEFINED(ATxmega256A3B) \ + ) + +#define XMEGA_A4 ( \ + AVR8_PART_IS_DEFINED(ATxmega16A4) || \ + AVR8_PART_IS_DEFINED(ATxmega32A4) \ + ) +/** @} */ + +/** + * \name AVR XMEGA AU series + * @{ + */ +#define XMEGA_A1U ( \ + AVR8_PART_IS_DEFINED(ATxmega64A1U) || \ + AVR8_PART_IS_DEFINED(ATxmega128A1U) \ + ) + +#define XMEGA_A3U ( \ + AVR8_PART_IS_DEFINED(ATxmega64A3U) || \ + AVR8_PART_IS_DEFINED(ATxmega128A3U) || \ + AVR8_PART_IS_DEFINED(ATxmega192A3U) || \ + AVR8_PART_IS_DEFINED(ATxmega256A3U) \ + ) + +#define XMEGA_A3BU ( \ + AVR8_PART_IS_DEFINED(ATxmega256A3BU) \ + ) + +#define XMEGA_A4U ( \ + AVR8_PART_IS_DEFINED(ATxmega16A4U) || \ + AVR8_PART_IS_DEFINED(ATxmega32A4U) || \ + AVR8_PART_IS_DEFINED(ATxmega64A4U) || \ + AVR8_PART_IS_DEFINED(ATxmega128A4U) \ + ) +/** @} */ + +/** + * \name AVR XMEGA B series + * @{ + */ +#define XMEGA_B1 ( \ + AVR8_PART_IS_DEFINED(ATxmega64B1) || \ + AVR8_PART_IS_DEFINED(ATxmega128B1) \ + ) + +#define XMEGA_B3 ( \ + AVR8_PART_IS_DEFINED(ATxmega64B3) || \ + AVR8_PART_IS_DEFINED(ATxmega128B3) \ + ) +/** @} */ + +/** + * \name AVR XMEGA C series + * @{ + */ +#define XMEGA_C3 ( \ + AVR8_PART_IS_DEFINED(ATxmega384C3) || \ + AVR8_PART_IS_DEFINED(ATxmega256C3) || \ + AVR8_PART_IS_DEFINED(ATxmega192C3) || \ + AVR8_PART_IS_DEFINED(ATxmega128C3) || \ + AVR8_PART_IS_DEFINED(ATxmega64C3) || \ + AVR8_PART_IS_DEFINED(ATxmega32C3) \ + ) + +#define XMEGA_C4 ( \ + AVR8_PART_IS_DEFINED(ATxmega32C4) || \ + AVR8_PART_IS_DEFINED(ATxmega16C4) \ + ) +/** @} */ + +/** + * \name AVR XMEGA D series + * @{ + */ +#define XMEGA_D3 ( \ + AVR8_PART_IS_DEFINED(ATxmega32D3) || \ + AVR8_PART_IS_DEFINED(ATxmega64D3) || \ + AVR8_PART_IS_DEFINED(ATxmega128D3) || \ + AVR8_PART_IS_DEFINED(ATxmega192D3) || \ + AVR8_PART_IS_DEFINED(ATxmega256D3) || \ + AVR8_PART_IS_DEFINED(ATxmega384D3) \ + ) + +#define XMEGA_D4 ( \ + AVR8_PART_IS_DEFINED(ATxmega16D4) || \ + AVR8_PART_IS_DEFINED(ATxmega32D4) || \ + AVR8_PART_IS_DEFINED(ATxmega64D4) || \ + AVR8_PART_IS_DEFINED(ATxmega128D4) \ + ) +/** @} */ + +/** + * \name AVR XMEGA E series + * @{ + */ +#define XMEGA_E5 ( \ + AVR8_PART_IS_DEFINED(ATxmega8E5) || \ + AVR8_PART_IS_DEFINED(ATxmega16E5) || \ + AVR8_PART_IS_DEFINED(ATxmega32E5) \ + ) +/** @} */ + + +/** + * \name AVR XMEGA families + * @{ + */ +/** AVR XMEGA A family */ +#define XMEGA_A (XMEGA_A1 || XMEGA_A3 || XMEGA_A3B || XMEGA_A4) + +/** AVR XMEGA AU family */ +#define XMEGA_AU (XMEGA_A1U || XMEGA_A3U || XMEGA_A3BU || XMEGA_A4U) + +/** AVR XMEGA B family */ +#define XMEGA_B (XMEGA_B1 || XMEGA_B3) + +/** AVR XMEGA C family */ +#define XMEGA_C (XMEGA_C3 || XMEGA_C4) + +/** AVR XMEGA D family */ +#define XMEGA_D (XMEGA_D3 || XMEGA_D4) + +/** AVR XMEGA E family */ +#define XMEGA_E (XMEGA_E5) +/** @} */ + + +/** AVR XMEGA product line */ +#define XMEGA (XMEGA_A || XMEGA_AU || XMEGA_B || XMEGA_C || XMEGA_D || XMEGA_E) + +/** @} */ + +/** + * \defgroup mega_part_macros_group megaAVR parts + * + * \note These megaAVR groupings are based on the groups in AVR Libc for the + * part header files. They are not names of official megaAVR device series or + * families. + * + * @{ + */ + +/** + * \name ATmegaxx0/xx1 subgroups + * @{ + */ +#define MEGA_XX0 ( \ + AVR8_PART_IS_DEFINED(ATmega640) || \ + AVR8_PART_IS_DEFINED(ATmega1280) || \ + AVR8_PART_IS_DEFINED(ATmega2560) \ + ) + +#define MEGA_XX1 ( \ + AVR8_PART_IS_DEFINED(ATmega1281) || \ + AVR8_PART_IS_DEFINED(ATmega2561) \ + ) +/** @} */ + +/** + * \name megaAVR groups + * @{ + */ +/** ATmegaxx0/xx1 group */ +#define MEGA_XX0_1 (MEGA_XX0 || MEGA_XX1) + +/** ATmegaxx4 group */ +#define MEGA_XX4 ( \ + AVR8_PART_IS_DEFINED(ATmega164A) || \ + AVR8_PART_IS_DEFINED(ATmega164PA) || \ + AVR8_PART_IS_DEFINED(ATmega324A) || \ + AVR8_PART_IS_DEFINED(ATmega324PA) || \ + AVR8_PART_IS_DEFINED(ATmega644) || \ + AVR8_PART_IS_DEFINED(ATmega644A) || \ + AVR8_PART_IS_DEFINED(ATmega644PA) || \ + AVR8_PART_IS_DEFINED(ATmega1284P) || \ + AVR8_PART_IS_DEFINED(ATmega128RFA1) \ + ) + +/** ATmegaxx4 group */ +#define MEGA_XX4_A ( \ + AVR8_PART_IS_DEFINED(ATmega164A) || \ + AVR8_PART_IS_DEFINED(ATmega164PA) || \ + AVR8_PART_IS_DEFINED(ATmega324A) || \ + AVR8_PART_IS_DEFINED(ATmega324PA) || \ + AVR8_PART_IS_DEFINED(ATmega644A) || \ + AVR8_PART_IS_DEFINED(ATmega644PA) || \ + AVR8_PART_IS_DEFINED(ATmega1284P) \ + ) + +/** ATmegaxx8 group */ +#define MEGA_XX8 ( \ + AVR8_PART_IS_DEFINED(ATmega48) || \ + AVR8_PART_IS_DEFINED(ATmega48A) || \ + AVR8_PART_IS_DEFINED(ATmega48PA) || \ + AVR8_PART_IS_DEFINED(ATmega88) || \ + AVR8_PART_IS_DEFINED(ATmega88A) || \ + AVR8_PART_IS_DEFINED(ATmega88PA) || \ + AVR8_PART_IS_DEFINED(ATmega168) || \ + AVR8_PART_IS_DEFINED(ATmega168A) || \ + AVR8_PART_IS_DEFINED(ATmega168PA) || \ + AVR8_PART_IS_DEFINED(ATmega328) || \ + AVR8_PART_IS_DEFINED(ATmega328P) \ + ) + +/** ATmegaxx8A/P/PA group */ +#define MEGA_XX8_A ( \ + AVR8_PART_IS_DEFINED(ATmega48A) || \ + AVR8_PART_IS_DEFINED(ATmega48PA) || \ + AVR8_PART_IS_DEFINED(ATmega88A) || \ + AVR8_PART_IS_DEFINED(ATmega88PA) || \ + AVR8_PART_IS_DEFINED(ATmega168A) || \ + AVR8_PART_IS_DEFINED(ATmega168PA) || \ + AVR8_PART_IS_DEFINED(ATmega328P) \ + ) + +/** ATmegaxx group */ +#define MEGA_XX ( \ + AVR8_PART_IS_DEFINED(ATmega16) || \ + AVR8_PART_IS_DEFINED(ATmega16A) || \ + AVR8_PART_IS_DEFINED(ATmega32) || \ + AVR8_PART_IS_DEFINED(ATmega32A) || \ + AVR8_PART_IS_DEFINED(ATmega64) || \ + AVR8_PART_IS_DEFINED(ATmega64A) || \ + AVR8_PART_IS_DEFINED(ATmega128) || \ + AVR8_PART_IS_DEFINED(ATmega128A) \ + ) + +/** ATmegaxxA/P/PA group */ +#define MEGA_XX_A ( \ + AVR8_PART_IS_DEFINED(ATmega16A) || \ + AVR8_PART_IS_DEFINED(ATmega32A) || \ + AVR8_PART_IS_DEFINED(ATmega64A) || \ + AVR8_PART_IS_DEFINED(ATmega128A) \ + ) +/** ATmegaxxRFA1 group */ +#define MEGA_RFA1 ( \ + AVR8_PART_IS_DEFINED(ATmega128RFA1) \ + ) + +/** ATmegaxxRFR2 group */ +#define MEGA_RFR2 ( \ + AVR8_PART_IS_DEFINED(ATmega64RFR2) || \ + AVR8_PART_IS_DEFINED(ATmega128RFR2) || \ + AVR8_PART_IS_DEFINED(ATmega256RFR2) || \ + AVR8_PART_IS_DEFINED(ATmega644RFR2) || \ + AVR8_PART_IS_DEFINED(ATmega1284RFR2) || \ + AVR8_PART_IS_DEFINED(ATmega2564RFR2) \ + ) + + +/** ATmegaxxRFxx group */ +#define MEGA_RF (MEGA_RFA1 || MEGA_RFR2) + +/** + * \name ATmegaxx_un0/un1/un2 subgroups + * @{ + */ +#define MEGA_XX_UN0 ( \ + AVR8_PART_IS_DEFINED(ATmega16) || \ + AVR8_PART_IS_DEFINED(ATmega16A) || \ + AVR8_PART_IS_DEFINED(ATmega32) || \ + AVR8_PART_IS_DEFINED(ATmega32A) \ + ) + +/** ATmegaxx group without power reduction and + * And interrupt sense register. + */ +#define MEGA_XX_UN1 ( \ + AVR8_PART_IS_DEFINED(ATmega64) || \ + AVR8_PART_IS_DEFINED(ATmega64A) || \ + AVR8_PART_IS_DEFINED(ATmega128) || \ + AVR8_PART_IS_DEFINED(ATmega128A) \ + ) + +/** ATmegaxx group without power reduction and + * And interrupt sense register. + */ +#define MEGA_XX_UN2 ( \ + AVR8_PART_IS_DEFINED(ATmega169P) || \ + AVR8_PART_IS_DEFINED(ATmega169PA) || \ + AVR8_PART_IS_DEFINED(ATmega329P) || \ + AVR8_PART_IS_DEFINED(ATmega329PA) \ + ) + +/** Devices added to complete megaAVR offering. + * Please do not use this group symbol as it is not intended + * to be permanent: the devices should be regrouped. + */ +#define MEGA_UNCATEGORIZED ( \ + AVR8_PART_IS_DEFINED(AT90CAN128) || \ + AVR8_PART_IS_DEFINED(AT90CAN32) || \ + AVR8_PART_IS_DEFINED(AT90CAN64) || \ + AVR8_PART_IS_DEFINED(AT90PWM1) || \ + AVR8_PART_IS_DEFINED(AT90PWM216) || \ + AVR8_PART_IS_DEFINED(AT90PWM2B) || \ + AVR8_PART_IS_DEFINED(AT90PWM316) || \ + AVR8_PART_IS_DEFINED(AT90PWM3B) || \ + AVR8_PART_IS_DEFINED(AT90PWM81) || \ + AVR8_PART_IS_DEFINED(AT90USB1286) || \ + AVR8_PART_IS_DEFINED(AT90USB1287) || \ + AVR8_PART_IS_DEFINED(AT90USB162) || \ + AVR8_PART_IS_DEFINED(AT90USB646) || \ + AVR8_PART_IS_DEFINED(AT90USB647) || \ + AVR8_PART_IS_DEFINED(AT90USB82) || \ + AVR8_PART_IS_DEFINED(ATmega1284) || \ + AVR8_PART_IS_DEFINED(ATmega162) || \ + AVR8_PART_IS_DEFINED(ATmega164P) || \ + AVR8_PART_IS_DEFINED(ATmega165A) || \ + AVR8_PART_IS_DEFINED(ATmega165P) || \ + AVR8_PART_IS_DEFINED(ATmega165PA) || \ + AVR8_PART_IS_DEFINED(ATmega168P) || \ + AVR8_PART_IS_DEFINED(ATmega169A) || \ + AVR8_PART_IS_DEFINED(ATmega16M1) || \ + AVR8_PART_IS_DEFINED(ATmega16U2) || \ + AVR8_PART_IS_DEFINED(ATmega16U4) || \ + AVR8_PART_IS_DEFINED(ATmega256RFA2) || \ + AVR8_PART_IS_DEFINED(ATmega324P) || \ + AVR8_PART_IS_DEFINED(ATmega325) || \ + AVR8_PART_IS_DEFINED(ATmega3250) || \ + AVR8_PART_IS_DEFINED(ATmega3250A) || \ + AVR8_PART_IS_DEFINED(ATmega3250P) || \ + AVR8_PART_IS_DEFINED(ATmega3250PA) || \ + AVR8_PART_IS_DEFINED(ATmega325A) || \ + AVR8_PART_IS_DEFINED(ATmega325P) || \ + AVR8_PART_IS_DEFINED(ATmega325PA) || \ + AVR8_PART_IS_DEFINED(ATmega329) || \ + AVR8_PART_IS_DEFINED(ATmega3290) || \ + AVR8_PART_IS_DEFINED(ATmega3290A) || \ + AVR8_PART_IS_DEFINED(ATmega3290P) || \ + AVR8_PART_IS_DEFINED(ATmega3290PA) || \ + AVR8_PART_IS_DEFINED(ATmega329A) || \ + AVR8_PART_IS_DEFINED(ATmega32M1) || \ + AVR8_PART_IS_DEFINED(ATmega32U2) || \ + AVR8_PART_IS_DEFINED(ATmega32U4) || \ + AVR8_PART_IS_DEFINED(ATmega48P) || \ + AVR8_PART_IS_DEFINED(ATmega644P) || \ + AVR8_PART_IS_DEFINED(ATmega645) || \ + AVR8_PART_IS_DEFINED(ATmega6450) || \ + AVR8_PART_IS_DEFINED(ATmega6450A) || \ + AVR8_PART_IS_DEFINED(ATmega6450P) || \ + AVR8_PART_IS_DEFINED(ATmega645A) || \ + AVR8_PART_IS_DEFINED(ATmega645P) || \ + AVR8_PART_IS_DEFINED(ATmega649) || \ + AVR8_PART_IS_DEFINED(ATmega6490) || \ + AVR8_PART_IS_DEFINED(ATmega6490A) || \ + AVR8_PART_IS_DEFINED(ATmega6490P) || \ + AVR8_PART_IS_DEFINED(ATmega649A) || \ + AVR8_PART_IS_DEFINED(ATmega649P) || \ + AVR8_PART_IS_DEFINED(ATmega64M1) || \ + AVR8_PART_IS_DEFINED(ATmega64RFA2) || \ + AVR8_PART_IS_DEFINED(ATmega8) || \ + AVR8_PART_IS_DEFINED(ATmega8515) || \ + AVR8_PART_IS_DEFINED(ATmega8535) || \ + AVR8_PART_IS_DEFINED(ATmega88P) || \ + AVR8_PART_IS_DEFINED(ATmega8A) || \ + AVR8_PART_IS_DEFINED(ATmega8U2) \ + ) + +/** Unspecified group */ +#define MEGA_UNSPECIFIED (MEGA_XX_UN0 || MEGA_XX_UN1 || MEGA_XX_UN2 || \ + MEGA_UNCATEGORIZED) + +/** @} */ + +/** megaAVR product line */ +#define MEGA (MEGA_XX0_1 || MEGA_XX4 || MEGA_XX8 || MEGA_XX || MEGA_RF || \ + MEGA_UNSPECIFIED) + +/** @} */ + +/** + * \defgroup tiny_part_macros_group tinyAVR parts + * + * @{ + */ + +/** + * \name tinyAVR groups + * @{ + */ + +/** Devices added to complete tinyAVR offering. + * Please do not use this group symbol as it is not intended + * to be permanent: the devices should be regrouped. + */ +#define TINY_UNCATEGORIZED ( \ + AVR8_PART_IS_DEFINED(ATtiny10) || \ + AVR8_PART_IS_DEFINED(ATtiny13) || \ + AVR8_PART_IS_DEFINED(ATtiny13A) || \ + AVR8_PART_IS_DEFINED(ATtiny1634) || \ + AVR8_PART_IS_DEFINED(ATtiny167) || \ + AVR8_PART_IS_DEFINED(ATtiny20) || \ + AVR8_PART_IS_DEFINED(ATtiny2313) || \ + AVR8_PART_IS_DEFINED(ATtiny2313A) || \ + AVR8_PART_IS_DEFINED(ATtiny24) || \ + AVR8_PART_IS_DEFINED(ATtiny24A) || \ + AVR8_PART_IS_DEFINED(ATtiny25) || \ + AVR8_PART_IS_DEFINED(ATtiny26) || \ + AVR8_PART_IS_DEFINED(ATtiny261) || \ + AVR8_PART_IS_DEFINED(ATtiny261A) || \ + AVR8_PART_IS_DEFINED(ATtiny4) || \ + AVR8_PART_IS_DEFINED(ATtiny40) || \ + AVR8_PART_IS_DEFINED(ATtiny4313) || \ + AVR8_PART_IS_DEFINED(ATtiny43U) || \ + AVR8_PART_IS_DEFINED(ATtiny44) || \ + AVR8_PART_IS_DEFINED(ATtiny44A) || \ + AVR8_PART_IS_DEFINED(ATtiny45) || \ + AVR8_PART_IS_DEFINED(ATtiny461) || \ + AVR8_PART_IS_DEFINED(ATtiny461A) || \ + AVR8_PART_IS_DEFINED(ATtiny48) || \ + AVR8_PART_IS_DEFINED(ATtiny5) || \ + AVR8_PART_IS_DEFINED(ATtiny828) || \ + AVR8_PART_IS_DEFINED(ATtiny84) || \ + AVR8_PART_IS_DEFINED(ATtiny84A) || \ + AVR8_PART_IS_DEFINED(ATtiny85) || \ + AVR8_PART_IS_DEFINED(ATtiny861) || \ + AVR8_PART_IS_DEFINED(ATtiny861A) || \ + AVR8_PART_IS_DEFINED(ATtiny87) || \ + AVR8_PART_IS_DEFINED(ATtiny88) || \ + AVR8_PART_IS_DEFINED(ATtiny9) \ + ) + +/** @} */ + +/** tinyAVR product line */ +#define TINY (TINY_UNCATEGORIZED) + +/** @} */ + +/** + * \defgroup sam_part_macros_group SAM parts + * @{ + */ + +/** + * \name SAM3S series + * @{ + */ +#define SAM3S1 ( \ + SAM_PART_IS_DEFINED(SAM3S1A) || \ + SAM_PART_IS_DEFINED(SAM3S1B) || \ + SAM_PART_IS_DEFINED(SAM3S1C) \ + ) + +#define SAM3S2 ( \ + SAM_PART_IS_DEFINED(SAM3S2A) || \ + SAM_PART_IS_DEFINED(SAM3S2B) || \ + SAM_PART_IS_DEFINED(SAM3S2C) \ + ) + +#define SAM3S4 ( \ + SAM_PART_IS_DEFINED(SAM3S4A) || \ + SAM_PART_IS_DEFINED(SAM3S4B) || \ + SAM_PART_IS_DEFINED(SAM3S4C) \ + ) + +#define SAM3S8 ( \ + SAM_PART_IS_DEFINED(SAM3S8B) || \ + SAM_PART_IS_DEFINED(SAM3S8C) \ + ) + +#define SAM3SD8 ( \ + SAM_PART_IS_DEFINED(SAM3SD8B) || \ + SAM_PART_IS_DEFINED(SAM3SD8C) \ + ) +/** @} */ + +/** + * \name SAM3U series + * @{ + */ +#define SAM3U1 ( \ + SAM_PART_IS_DEFINED(SAM3U1C) || \ + SAM_PART_IS_DEFINED(SAM3U1E) \ + ) + +#define SAM3U2 ( \ + SAM_PART_IS_DEFINED(SAM3U2C) || \ + SAM_PART_IS_DEFINED(SAM3U2E) \ + ) + +#define SAM3U4 ( \ + SAM_PART_IS_DEFINED(SAM3U4C) || \ + SAM_PART_IS_DEFINED(SAM3U4E) \ + ) +/** @} */ + +/** + * \name SAM3N series + * @{ + */ +#define SAM3N00 ( \ + SAM_PART_IS_DEFINED(SAM3N00A) || \ + SAM_PART_IS_DEFINED(SAM3N00B) \ + ) + +#define SAM3N0 ( \ + SAM_PART_IS_DEFINED(SAM3N0A) || \ + SAM_PART_IS_DEFINED(SAM3N0B) || \ + SAM_PART_IS_DEFINED(SAM3N0C) \ + ) + +#define SAM3N1 ( \ + SAM_PART_IS_DEFINED(SAM3N1A) || \ + SAM_PART_IS_DEFINED(SAM3N1B) || \ + SAM_PART_IS_DEFINED(SAM3N1C) \ + ) + +#define SAM3N2 ( \ + SAM_PART_IS_DEFINED(SAM3N2A) || \ + SAM_PART_IS_DEFINED(SAM3N2B) || \ + SAM_PART_IS_DEFINED(SAM3N2C) \ + ) + +#define SAM3N4 ( \ + SAM_PART_IS_DEFINED(SAM3N4A) || \ + SAM_PART_IS_DEFINED(SAM3N4B) || \ + SAM_PART_IS_DEFINED(SAM3N4C) \ + ) +/** @} */ + +/** + * \name SAM3X series + * @{ + */ +#define SAM3X4 ( \ + SAM_PART_IS_DEFINED(SAM3X4C) || \ + SAM_PART_IS_DEFINED(SAM3X4E) \ + ) + +#define SAM3X8 ( \ + SAM_PART_IS_DEFINED(SAM3X8C) || \ + SAM_PART_IS_DEFINED(SAM3X8E) || \ + SAM_PART_IS_DEFINED(SAM3X8H) \ + ) +/** @} */ + +/** + * \name SAM3A series + * @{ + */ +#define SAM3A4 ( \ + SAM_PART_IS_DEFINED(SAM3A4C) \ + ) + +#define SAM3A8 ( \ + SAM_PART_IS_DEFINED(SAM3A8C) \ + ) +/** @} */ + +/** + * \name SAM4S series + * @{ + */ +#define SAM4S2 ( \ + SAM_PART_IS_DEFINED(SAM4S2A) || \ + SAM_PART_IS_DEFINED(SAM4S2B) || \ + SAM_PART_IS_DEFINED(SAM4S2C) \ + ) + +#define SAM4S4 ( \ + SAM_PART_IS_DEFINED(SAM4S4A) || \ + SAM_PART_IS_DEFINED(SAM4S4B) || \ + SAM_PART_IS_DEFINED(SAM4S4C) \ + ) + +#define SAM4S8 ( \ + SAM_PART_IS_DEFINED(SAM4S8B) || \ + SAM_PART_IS_DEFINED(SAM4S8C) \ + ) + +#define SAM4S16 ( \ + SAM_PART_IS_DEFINED(SAM4S16B) || \ + SAM_PART_IS_DEFINED(SAM4S16C) \ + ) + +#define SAM4SA16 ( \ + SAM_PART_IS_DEFINED(SAM4SA16B) || \ + SAM_PART_IS_DEFINED(SAM4SA16C) \ + ) + +#define SAM4SD16 ( \ + SAM_PART_IS_DEFINED(SAM4SD16B) || \ + SAM_PART_IS_DEFINED(SAM4SD16C) \ + ) + +#define SAM4SD32 ( \ + SAM_PART_IS_DEFINED(SAM4SD32B) || \ + SAM_PART_IS_DEFINED(SAM4SD32C) \ + ) +/** @} */ + +/** + * \name SAM4L series + * @{ + */ +#define SAM4LS ( \ + SAM_PART_IS_DEFINED(SAM4LS2A) || \ + SAM_PART_IS_DEFINED(SAM4LS2B) || \ + SAM_PART_IS_DEFINED(SAM4LS2C) || \ + SAM_PART_IS_DEFINED(SAM4LS4A) || \ + SAM_PART_IS_DEFINED(SAM4LS4B) || \ + SAM_PART_IS_DEFINED(SAM4LS4C) || \ + SAM_PART_IS_DEFINED(SAM4LS8A) || \ + SAM_PART_IS_DEFINED(SAM4LS8B) || \ + SAM_PART_IS_DEFINED(SAM4LS8C) \ + ) + +#define SAM4LC ( \ + SAM_PART_IS_DEFINED(SAM4LC2A) || \ + SAM_PART_IS_DEFINED(SAM4LC2B) || \ + SAM_PART_IS_DEFINED(SAM4LC2C) || \ + SAM_PART_IS_DEFINED(SAM4LC4A) || \ + SAM_PART_IS_DEFINED(SAM4LC4B) || \ + SAM_PART_IS_DEFINED(SAM4LC4C) || \ + SAM_PART_IS_DEFINED(SAM4LC8A) || \ + SAM_PART_IS_DEFINED(SAM4LC8B) || \ + SAM_PART_IS_DEFINED(SAM4LC8C) \ + ) +/** @} */ + +/** + * \name SAMD20 series + * @{ + */ +#define SAMD20J ( \ + SAM_PART_IS_DEFINED(SAMD20J14) || \ + SAM_PART_IS_DEFINED(SAMD20J15) || \ + SAM_PART_IS_DEFINED(SAMD20J16) || \ + SAM_PART_IS_DEFINED(SAMD20J17) || \ + SAM_PART_IS_DEFINED(SAMD20J18) \ + ) + +#define SAMD20G ( \ + SAM_PART_IS_DEFINED(SAMD20G14) || \ + SAM_PART_IS_DEFINED(SAMD20G15) || \ + SAM_PART_IS_DEFINED(SAMD20G16) || \ + SAM_PART_IS_DEFINED(SAMD20G17) || \ + SAM_PART_IS_DEFINED(SAMD20G17U) || \ + SAM_PART_IS_DEFINED(SAMD20G18) || \ + SAM_PART_IS_DEFINED(SAMD20G18U) \ + ) + +#define SAMD20E ( \ + SAM_PART_IS_DEFINED(SAMD20E14) || \ + SAM_PART_IS_DEFINED(SAMD20E15) || \ + SAM_PART_IS_DEFINED(SAMD20E16) || \ + SAM_PART_IS_DEFINED(SAMD20E17) || \ + SAM_PART_IS_DEFINED(SAMD20E18) || \ + SAM_PART_IS_DEFINED(SAMD20E1F) \ + ) +/** @} */ + +/** + * \name SAMD21 series + * @{ + */ +#define SAMD21J ( \ + SAM_PART_IS_DEFINED(SAMD21J15A) || \ + SAM_PART_IS_DEFINED(SAMD21J16A) || \ + SAM_PART_IS_DEFINED(SAMD21J17A) || \ + SAM_PART_IS_DEFINED(SAMD21J18A) \ + ) + +#define SAMD21G ( \ + SAM_PART_IS_DEFINED(SAMD21G15A) || \ + SAM_PART_IS_DEFINED(SAMD21G16A) || \ + SAM_PART_IS_DEFINED(SAMD21G17A) || \ + SAM_PART_IS_DEFINED(SAMD21G18A) \ + ) + +#define SAMD21E ( \ + SAM_PART_IS_DEFINED(SAMD21E15A) || \ + SAM_PART_IS_DEFINED(SAMD21E16A) || \ + SAM_PART_IS_DEFINED(SAMD21E17A) || \ + SAM_PART_IS_DEFINED(SAMD21E18A) \ + ) +/** @} */ + +/** + * \name SAMR21 series + * @{ + */ +#define SAMR21G ( \ + SAM_PART_IS_DEFINED(SAMR21G16A) || \ + SAM_PART_IS_DEFINED(SAMR21G17A) || \ + SAM_PART_IS_DEFINED(SAMR21G18A) \ + ) + +#define SAMR21E ( \ + SAM_PART_IS_DEFINED(SAMR21E16A) || \ + SAM_PART_IS_DEFINED(SAMR21E17A) || \ + SAM_PART_IS_DEFINED(SAMR21E18A) \ + ) +/** @} */ + +/** + * \name SAMD10 series + * @{ + */ +#define SAMD10C ( \ + SAM_PART_IS_DEFINED(SAMD10C12A) || \ + SAM_PART_IS_DEFINED(SAMD10C13A) || \ + SAM_PART_IS_DEFINED(SAMD10C14A) \ + ) + +#define SAMD10DS ( \ + SAM_PART_IS_DEFINED(SAMD10D12AS) || \ + SAM_PART_IS_DEFINED(SAMD10D13AS) || \ + SAM_PART_IS_DEFINED(SAMD10D14AS) \ + ) + +#define SAMD10DM ( \ + SAM_PART_IS_DEFINED(SAMD10D12AM) || \ + SAM_PART_IS_DEFINED(SAMD10D13AM) || \ + SAM_PART_IS_DEFINED(SAMD10D14AM) \ + ) +/** @} */ + +/** + * \name SAMD11 series + * @{ + */ +#define SAMD11C ( \ + SAM_PART_IS_DEFINED(SAMD11C14A) \ + ) + +#define SAMD11DS ( \ + SAM_PART_IS_DEFINED(SAMD11D14AS) \ + ) + +#define SAMD11DM ( \ + SAM_PART_IS_DEFINED(SAMD11D14AM) \ + ) +/** @} */ + +/** + * \name SAM4E series + * @{ + */ +#define SAM4E8 ( \ + SAM_PART_IS_DEFINED(SAM4E8C) || \ + SAM_PART_IS_DEFINED(SAM4E8E) \ + ) + +#define SAM4E16 ( \ + SAM_PART_IS_DEFINED(SAM4E16C) || \ + SAM_PART_IS_DEFINED(SAM4E16E) \ + ) +/** @} */ + +/** + * \name SAM4N series + * @{ + */ +#define SAM4N8 ( \ + SAM_PART_IS_DEFINED(SAM4N8A) || \ + SAM_PART_IS_DEFINED(SAM4N8B) || \ + SAM_PART_IS_DEFINED(SAM4N8C) \ + ) + +#define SAM4N16 ( \ + SAM_PART_IS_DEFINED(SAM4N16B) || \ + SAM_PART_IS_DEFINED(SAM4N16C) \ + ) +/** @} */ + +/** + * \name SAM4C series + * @{ + */ +#define SAM4C8_0 ( \ + SAM_PART_IS_DEFINED(SAM4C8C_0) \ + ) + +#define SAM4C8_1 ( \ + SAM_PART_IS_DEFINED(SAM4C8C_1) \ + ) + +#define SAM4C8 (SAM4C8_0 || SAM4C8_1) + +#define SAM4C16_0 ( \ + SAM_PART_IS_DEFINED(SAM4C16C_0) \ + ) + +#define SAM4C16_1 ( \ + SAM_PART_IS_DEFINED(SAM4C16C_1) \ + ) + +#define SAM4C16 (SAM4C16_0 || SAM4C16_1) + +#define SAM4C32_0 ( \ + SAM_PART_IS_DEFINED(SAM4C32C_0) ||\ + SAM_PART_IS_DEFINED(SAM4C32E_0) \ + ) + +#define SAM4C32_1 ( \ + SAM_PART_IS_DEFINED(SAM4C32C_1) ||\ + SAM_PART_IS_DEFINED(SAM4C32E_1) \ + ) + + +#define SAM4C32 (SAM4C32_0 || SAM4C32_1) + +/** @} */ + +/** + * \name SAM4CM series + * @{ + */ +#define SAM4CMP8_0 ( \ + SAM_PART_IS_DEFINED(SAM4CMP8C_0) \ + ) + +#define SAM4CMP8_1 ( \ + SAM_PART_IS_DEFINED(SAM4CMP8C_1) \ + ) + +#define SAM4CMP8 (SAM4CMP8_0 || SAM4CMP8_1) + +#define SAM4CMP16_0 ( \ + SAM_PART_IS_DEFINED(SAM4CMP16C_0) \ + ) + +#define SAM4CMP16_1 ( \ + SAM_PART_IS_DEFINED(SAM4CMP16C_1) \ + ) + +#define SAM4CMP16 (SAM4CMP16_0 || SAM4CMP16_1) + +#define SAM4CMP32_0 ( \ + SAM_PART_IS_DEFINED(SAM4CMP32C_0) \ + ) + +#define SAM4CMP32_1 ( \ + SAM_PART_IS_DEFINED(SAM4CMP32C_1) \ + ) + +#define SAM4CMP32 (SAM4CMP32_0 || SAM4CMP32_1) + +#define SAM4CMS8_0 ( \ + SAM_PART_IS_DEFINED(SAM4CMS8C_0) \ + ) + +#define SAM4CMS8_1 ( \ + SAM_PART_IS_DEFINED(SAM4CMS8C_1) \ + ) + +#define SAM4CMS8 (SAM4CMS8_0 || SAM4CMS8_1) + +#define SAM4CMS16_0 ( \ + SAM_PART_IS_DEFINED(SAM4CMS16C_0) \ + ) + +#define SAM4CMS16_1 ( \ + SAM_PART_IS_DEFINED(SAM4CMS16C_1) \ + ) + +#define SAM4CMS16 (SAM4CMS16_0 || SAM4CMS16_1) + +#define SAM4CMS32_0 ( \ + SAM_PART_IS_DEFINED(SAM4CMS32C_0) \ + ) + +#define SAM4CMS32_1 ( \ + SAM_PART_IS_DEFINED(SAM4CMS32C_1) \ + ) + +#define SAM4CMS32 (SAM4CMS32_0 || SAM4CMS32_1) + +/** @} */ + +/** + * \name SAM4CP series + * @{ + */ +#define SAM4CP16_0 ( \ + SAM_PART_IS_DEFINED(SAM4CP16B_0) \ + ) + +#define SAM4CP16_1 ( \ + SAM_PART_IS_DEFINED(SAM4CP16B_1) \ + ) + +#define SAM4CP16 (SAM4CP16_0 || SAM4CP16_1) +/** @} */ + +/** + * \name SAMG series + * @{ + */ +#define SAMG51 ( \ + SAM_PART_IS_DEFINED(SAMG51G18) \ + ) + +#define SAMG53 ( \ + SAM_PART_IS_DEFINED(SAMG53G19) ||\ + SAM_PART_IS_DEFINED(SAMG53N19) \ + ) + +#define SAMG54 ( \ + SAM_PART_IS_DEFINED(SAMG54G19) ||\ + SAM_PART_IS_DEFINED(SAMG54J19) ||\ + SAM_PART_IS_DEFINED(SAMG54N19) \ +) +/** @} */ +/** + * \name SAM families + * @{ + */ +/** SAM3S Family */ +#define SAM3S (SAM3S1 || SAM3S2 || SAM3S4 || SAM3S8 || SAM3SD8) + +/** SAM3U Family */ +#define SAM3U (SAM3U1 || SAM3U2 || SAM3U4) + +/** SAM3N Family */ +#define SAM3N (SAM3N00 || SAM3N0 || SAM3N1 || SAM3N2 || SAM3N4) + +/** SAM3XA Family */ +#define SAM3XA (SAM3X4 || SAM3X8 || SAM3A4 || SAM3A8) + +/** SAM4S Family */ +#define SAM4S (SAM4S2 || SAM4S4 || SAM4S8 || SAM4S16 || SAM4SA16 || SAM4SD16 || SAM4SD32) + +/** SAM4L Family */ +#define SAM4L (SAM4LS || SAM4LC) + +/** SAMD20 Family */ +#define SAMD20 (SAMD20J || SAMD20G || SAMD20E) + +/** SAMD21 Family */ +#define SAMD21 (SAMD21J || SAMD21G || SAMD21E) + +/** SAMD10 Family */ +#define SAMD10 (SAMD10C || SAMD10DS || SAMD10DM) + +/** SAMD11 Family */ +#define SAMD11 (SAMD11C || SAMD11DS || SAMD11DM) + +/** SAMD Family */ +#define SAMD (SAMD20 || SAMD21 || SAMD10 || SAMD11) + +/** SAMR21 Family */ +#define SAMR21 (SAMR21G || SAMR21E) + +/** SAM4E Family */ +#define SAM4E (SAM4E8 || SAM4E16) + +/** SAM4N Family */ +#define SAM4N (SAM4N8 || SAM4N16) + +/** SAM4C Family */ +#define SAM4C_0 (SAM4C8_0 || SAM4C16_0 || SAM4C32_0) +#define SAM4C_1 (SAM4C8_1 || SAM4C16_1 || SAM4C32_1) +#define SAM4C (SAM4C8 || SAM4C16 || SAM4C32) + +/** SAM4CM Family */ +#define SAM4CM_0 (SAM4CMP8_0 || SAM4CMP16_0 || SAM4CMP32_0 || SAM4CMS8_0 || \ + SAM4CMS16_0 || SAM4CMS32_0) +#define SAM4CM_1 (SAM4CMP8_1 || SAM4CMP16_1 || SAM4CMP32_1 || SAM4CMS8_1 || \ + SAM4CMS16_1 || SAM4CMS32_1) +#define SAM4CM (SAM4CMP8 || SAM4CMP16 || SAM4CMP32 || SAM4CMS8 || \ + SAM4CMS16 || SAM4CMS32) + +/** SAM4CP Family */ +#define SAM4CP_0 (SAM4CP16_0) +#define SAM4CP_1 (SAM4CP16_1) +#define SAM4CP (SAM4CP16) + +/** SAMG Family */ +#define SAMG (SAMG51 || SAMG53 || SAMG54) + +/** SAM0 product line (cortex-m0+) */ +#define SAM0 (SAMD20 || SAMD21 || SAMR21 || SAMD10 || SAMD11) + +/** @} */ + +/** SAM product line */ +#define SAM (SAM3S || SAM3U || SAM3N || SAM3XA || SAM4S || SAM4L || SAM4E || \ + SAM0 || SAM4N || SAM4C || SAM4CM || SAM4CP || SAMG) + +/** @} */ + +/** @} */ + +/** @} */ + +#endif /* ATMEL_PARTS_H */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/boards/samd21_xplained_pro/board_init.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/boards/samd21_xplained_pro/board_init.c new file mode 100755 index 0000000..44c8c1f --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/boards/samd21_xplained_pro/board_init.c @@ -0,0 +1,99 @@ +/** + * \file + * + * \brief SAM D21 Xplained Pro board initialization + * + * Copyright (c) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include +#include +#include +#include + +#if defined(__GNUC__) +void board_init(void) WEAK __attribute__((alias("system_board_init"))); +#elif defined(__ICCARM__) +void board_init(void); +# pragma weak board_init=system_board_init +#endif + +void system_board_init(void) +{ + struct port_config pin_conf; + port_get_config_defaults(&pin_conf); + + /* Configure LEDs as outputs, turn them off */ + pin_conf.direction = PORT_PIN_DIR_OUTPUT; + port_pin_set_config(LED_0_PIN, &pin_conf); + port_pin_set_output_level(LED_0_PIN, LED_0_INACTIVE); + + pin_conf.direction = PORT_PIN_DIR_OUTPUT; + port_pin_set_config(LED_L_PIN, &pin_conf); + port_pin_set_output_level(LED_L_PIN, LED_0_INACTIVE); + + pin_conf.direction = PORT_PIN_DIR_OUTPUT; + port_pin_set_config(LED_RX_PIN, &pin_conf); + port_pin_set_output_level(LED_RX_PIN, LED_RX_INACTIVE); + + pin_conf.direction = PORT_PIN_DIR_OUTPUT; + port_pin_set_config(LED_TX_PIN, &pin_conf); + port_pin_set_output_level(LED_RX_PIN, LED_RX_INACTIVE); + + /* Set buttons as inputs */ + pin_conf.direction = PORT_PIN_DIR_INPUT; + pin_conf.input_pull = PORT_PIN_PULL_UP; + port_pin_set_config(BUTTON_0_PIN, &pin_conf); + +#ifdef CONF_BOARD_AT86RFX + port_get_config_defaults(&pin_conf); + pin_conf.direction = PORT_PIN_DIR_OUTPUT; + port_pin_set_config(AT86RFX_SPI_SCK, &pin_conf); + port_pin_set_config(AT86RFX_SPI_MOSI, &pin_conf); + port_pin_set_config(AT86RFX_SPI_CS, &pin_conf); + port_pin_set_config(AT86RFX_RST_PIN, &pin_conf); + port_pin_set_config(AT86RFX_SLP_PIN, &pin_conf); + port_pin_set_output_level(AT86RFX_SPI_SCK, true); + port_pin_set_output_level(AT86RFX_SPI_MOSI, true); + port_pin_set_output_level(AT86RFX_SPI_CS, true); + port_pin_set_output_level(AT86RFX_RST_PIN, true); + port_pin_set_output_level(AT86RFX_SLP_PIN, true); + pin_conf.direction = PORT_PIN_DIR_INPUT; + port_pin_set_config(AT86RFX_SPI_MISO, &pin_conf); +#endif +} diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/boards/samd21_xplained_pro/samd21_xplained_pro.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/boards/samd21_xplained_pro/samd21_xplained_pro.h new file mode 100755 index 0000000..7fcb220 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/boards/samd21_xplained_pro/samd21_xplained_pro.h @@ -0,0 +1,756 @@ +/** + * \file + * + * \brief SAM D21 Xplained Pro board definition + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef SAMD21_XPLAINED_PRO_H_INCLUDED +#define SAMD21_XPLAINED_PRO_H_INCLUDED + +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \ingroup group_common_boards + * \defgroup samd21_xplained_pro_group SAM D21 Xplained Pro board + * + * @{ + */ + +void system_board_init(void); + +/** + * \defgroup samd21_xplained_pro_features_group Features + * + * Symbols that describe features and capabilities of the board. + * + * @{ + */ + +/** Name string macro */ +#define BOARD_NAME "SAMD21_XPLAINED_PRO" + +/** \name Resonator definitions + * @{ */ +#define BOARD_FREQ_SLCK_XTAL (32768U) +#define BOARD_FREQ_SLCK_BYPASS (32768U) +#define BOARD_FREQ_MAINCK_XTAL 0 /* Not Mounted */ +#define BOARD_FREQ_MAINCK_BYPASS 0 /* Not Mounted */ +#define BOARD_MCK CHIP_FREQ_CPU_MAX +#define BOARD_OSC_STARTUP_US 15625 +/** @} */ + +/** \name LED definitions + * @{ */ +#define LED0_PIN PIN_PA17 // only for compatibility, this pin is used also by L LED +#define LED0_ACTIVE false +#define LED0_INACTIVE !LED0_ACTIVE + +#define LEDL_PIN PIN_PA17 //defining LED L PORT PIN +#define LEDL_ACTIVE true +#define LEDL_INACTIVE !LEDL_ACTIVE + +#define LEDRX_PIN PIN_PB03 //defining LED RX PORT PIN +#define LEDRX_ACTIVE false +#define LEDRX_INACTIVE !LEDRX_ACTIVE + +#define LEDTX_PIN PIN_PA27 //defining LED TX PORT PIN +#define LEDTX_ACTIVE false +#define LEDTX_INACTIVE !LEDTX_ACTIVE + +/** @} */ + +/** \name SW0 definitions + * @{ */ +#define SW0_PIN PIN_PA15 +#define SW0_ACTIVE false +#define SW0_INACTIVE !SW0_ACTIVE +#define SW0_EIC_PIN PIN_PA15A_EIC_EXTINT15 +#define SW0_EIC_MUX MUX_PA15A_EIC_EXTINT15 +#define SW0_EIC_PINMUX PINMUX_PA15A_EIC_EXTINT15 +#define SW0_EIC_LINE 15 +/** @} */ + +/** + * \name LED #0 definitions + * + * Wrapper macros for LED0, to ensure common naming across all Xplained Pro + * boards. + * + * LED L, LED RX and LED TX are used by Arduino srl SAM D21 based boards. LED 0 remain only for compatibility. + * + * @{ */ +#define LED_0_NAME "LED0 (yellow)" +#define LED_0_PIN LED0_PIN +#define LED_0_ACTIVE LED0_ACTIVE +#define LED_0_INACTIVE LED0_INACTIVE +#define LED0_GPIO LED0_PIN +#define LED0 LED0_PIN + +#define LED_L_NAME "LED L" +#define LED_L_PIN LEDL_PIN +#define LED_L_ACTIVE LEDL_ACTIVE +#define LED_L_INACTIVE LEDL_INACTIVE +#define LEDL_GPIO LEDL_PIN +#define LEDL LEDL_PIN + +#define LED_RX_NAME "LED RX" +#define LED_RX_PIN LEDRX_PIN +#define LED_RX_ACTIVE LEDRX_ACTIVE +#define LED_RX_INACTIVE LEDRX_INACTIVE +#define LEDRX_GPIO LEDRX_PIN +#define LEDRX LEDRX_PIN + +#define LED_TX_NAME "LED L" +#define LED_TX_PIN LEDTX_PIN +#define LED_TX_ACTIVE LEDTX_ACTIVE +#define LED_TX_INACTIVE LEDTX_INACTIVE +#define LEDTX_GPIO LEDTX_PIN +#define LEDTX LEDTX_PIN + +#define LED_0_PWM4CTRL_MODULE TCC0 +#define LED_0_PWM4CTRL_CHANNEL 0 +#define LED_0_PWM4CTRL_OUTPUT 0 +#define LED_0_PWM4CTRL_PIN PIN_PB30E_TCC0_WO0 +#define LED_0_PWM4CTRL_MUX MUX_PB30E_TCC0_WO0 +#define LED_0_PWM4CTRL_PINMUX PINMUX_PB30E_TCC0_WO0 +/** @} */ + +/** Number of on-board LEDs */ +#define LED_COUNT 1 + +/** + * \name Serialflash definitions + * + * On board Serialflash definitions. + * + * @{ */ +#define SERIALFLASH_SPI_MODULE SERCOM5 +#define SERIALFLASH_SPI_MUX_SETTING SPI_SIGNAL_MUX_SETTING_E +#define SERIALFLASH_SPI_PINMUX_PAD0 PINMUX_PB16C_SERCOM5_PAD0 +#define SERIALFLASH_SPI_PINMUX_PAD1 PINMUX_UNUSED +#define SERIALFLASH_SPI_PINMUX_PAD2 PINMUX_PB22D_SERCOM5_PAD2 +#define SERIALFLASH_SPI_PINMUX_PAD3 PINMUX_PB23D_SERCOM5_PAD3 +#define SERIALFLASH_SPI_CS PIN_PA13 +/** @} */ + +/** + * \name Button #0 definitions + * + * Wrapper macros for SW0, to ensure common naming across all Xplained Pro + * boards. + * + * button 0 is used only for compatibility purpose, and are not used in Arduino srl SAM D21 Based Boards. + * @{ */ +#define BUTTON_0_NAME "SW0" +#define BUTTON_0_PIN SW0_PIN +#define BUTTON_0_ACTIVE SW0_ACTIVE +#define BUTTON_0_INACTIVE SW0_INACTIVE +#define BUTTON_0_EIC_PIN SW0_EIC_PIN +#define BUTTON_0_EIC_MUX SW0_EIC_MUX +#define BUTTON_0_EIC_PINMUX SW0_EIC_PINMUX +#define BUTTON_0_EIC_LINE SW0_EIC_LINE +/** @} */ + +/** Number of on-board buttons */ +#define BUTTON_COUNT 1 + +/** \name Extension header #1 pin definitions + * @{ + */ +#define EXT1_PIN_3 PIN_PB00 +#define EXT1_PIN_4 PIN_PB01 +#define EXT1_PIN_5 PIN_PB06 +#define EXT1_PIN_6 PIN_PB07 +#define EXT1_PIN_7 PIN_PB02 +#define EXT1_PIN_8 PIN_PB03 +#define EXT1_PIN_9 PIN_PB04 +#define EXT1_PIN_10 PIN_PB05 +#define EXT1_PIN_11 PIN_PA08 +#define EXT1_PIN_12 PIN_PA09 +#define EXT1_PIN_13 PIN_PB09 +#define EXT1_PIN_14 PIN_PB08 +#define EXT1_PIN_15 PIN_PA05 +#define EXT1_PIN_16 PIN_PA06 +#define EXT1_PIN_17 PIN_PA04 +#define EXT1_PIN_18 PIN_PA07 +/** @} */ + +/** \name Extension header #1 pin definitions by function + * @{ + */ +#define EXT1_PIN_ADC_0 EXT1_PIN_3 +#define EXT1_PIN_ADC_1 EXT1_PIN_4 +#define EXT1_PIN_GPIO_0 EXT1_PIN_5 +#define EXT1_PIN_GPIO_1 EXT1_PIN_6 +#define EXT1_PIN_PWM_0 EXT1_PIN_7 +#define EXT1_PIN_PWM_1 EXT1_PIN_8 +#define EXT1_PIN_IRQ EXT1_PIN_9 +#define EXT1_PIN_I2C_SDA EXT1_PIN_11 +#define EXT1_PIN_I2C_SCL EXT1_PIN_12 +#define EXT1_PIN_UART_RX EXT1_PIN_13 +#define EXT1_PIN_UART_TX EXT1_PIN_14 +#define EXT1_PIN_SPI_SS_1 EXT1_PIN_10 +#define EXT1_PIN_SPI_SS_0 EXT1_PIN_15 +#define EXT1_PIN_SPI_MOSI EXT1_PIN_16 +#define EXT1_PIN_SPI_MISO EXT1_PIN_17 +#define EXT1_PIN_SPI_SCK EXT1_PIN_18 +/** @} */ + +/** \name Extension header #1 ADC definitions + * @{ + */ +#define EXT1_ADC_MODULE ADC +#define EXT1_ADC_0_CHANNEL 8 +#define EXT1_ADC_0_PIN PIN_PB00B_ADC_AIN8 +#define EXT1_ADC_0_MUX MUX_PB00B_ADC_AIN8 +#define EXT1_ADC_0_PINMUX PINMUX_PB00B_ADC_AIN8 +#define EXT1_ADC_1_CHANNEL 9 +#define EXT1_ADC_1_PIN PIN_PB01B_ADC_AIN9 +#define EXT1_ADC_1_MUX MUX_PB01B_ADC_AIN9 +#define EXT1_ADC_1_PINMUX PINMUX_PB01B_ADC_AIN9 +/** @} */ + +/** \name Extension header #1 PWM definitions + * @{ + */ +#define EXT1_PWM_MODULE TC6 +#define EXT1_PWM_0_CHANNEL 0 +#define EXT1_PWM_0_PIN PIN_PB02E_TC6_WO0 +#define EXT1_PWM_0_MUX MUX_PB02E_TC6_WO0 +#define EXT1_PWM_0_PINMUX PINMUX_PB02E_TC6_WO0 +#define EXT1_PWM_1_CHANNEL 1 +#define EXT1_PWM_1_PIN PIN_PB03E_TC6_WO1 +#define EXT1_PWM_1_MUX MUX_PB03E_TC6_WO1 +#define EXT1_PWM_1_PINMUX PINMUX_PB03E_TC6_WO1 +/** @} */ + +/** \name Extension header #1 IRQ/External interrupt definitions + * @{ + */ +#define EXT1_IRQ_MODULE EIC +#define EXT1_IRQ_INPUT 4 +#define EXT1_IRQ_PIN PIN_PB04A_EIC_EXTINT4 +#define EXT1_IRQ_MUX MUX_PB04A_EIC_EXTINT4 +#define EXT1_IRQ_PINMUX PINMUX_PB04A_EIC_EXTINT4 +/** @} */ + +/** \name Extension header #1 I2C definitions + * @{ + */ +#define EXT1_I2C_MODULE SERCOM2 +#define EXT1_I2C_SERCOM_PINMUX_PAD0 PINMUX_PA08D_SERCOM2_PAD0 +#define EXT1_I2C_SERCOM_PINMUX_PAD1 PINMUX_PA09D_SERCOM2_PAD1 +#define EXT1_I2C_SERCOM_DMAC_ID_TX SERCOM2_DMAC_ID_TX +#define EXT1_I2C_SERCOM_DMAC_ID_RX SERCOM2_DMAC_ID_RX +/** @} */ + +/** \name Extension header #1 UART definitions + * @{ + */ +#define EXT1_UART_MODULE SERCOM4 +#define EXT1_UART_SERCOM_MUX_SETTING USART_RX_1_TX_0_XCK_1 +#define EXT1_UART_SERCOM_PINMUX_PAD0 PINMUX_PB08D_SERCOM4_PAD0 +#define EXT1_UART_SERCOM_PINMUX_PAD1 PINMUX_PB09D_SERCOM4_PAD1 +#define EXT1_UART_SERCOM_PINMUX_PAD2 PINMUX_UNUSED +#define EXT1_UART_SERCOM_PINMUX_PAD3 PINMUX_UNUSED +#define EXT1_UART_SERCOM_DMAC_ID_TX SERCOM4_DMAC_ID_TX +#define EXT1_UART_SERCOM_DMAC_ID_RX SERCOM4_DMAC_ID_RX +/** @} */ + +/** \name Extension header #1 SPI definitions + * @{ + */ +#define EXT1_SPI_MODULE SERCOM0 +#define EXT1_SPI_SERCOM_MUX_SETTING SPI_SIGNAL_MUX_SETTING_E +#define EXT1_SPI_SERCOM_PINMUX_PAD0 PINMUX_PA04D_SERCOM0_PAD0 +#define EXT1_SPI_SERCOM_PINMUX_PAD1 PINMUX_PA05D_SERCOM0_PAD1 +#define EXT1_SPI_SERCOM_PINMUX_PAD2 PINMUX_PA06D_SERCOM0_PAD2 +#define EXT1_SPI_SERCOM_PINMUX_PAD3 PINMUX_PA07D_SERCOM0_PAD3 +#define EXT1_SPI_SERCOM_DMAC_ID_TX SERCOM0_DMAC_ID_TX +#define EXT1_SPI_SERCOM_DMAC_ID_RX SERCOM0_DMAC_ID_RX +/** @} */ + +/** \name Extension header #2 pin definitions + * @{ + */ +#define EXT2_PIN_3 PIN_PA10 +#define EXT2_PIN_4 PIN_PA11 +#define EXT2_PIN_5 PIN_PA20 +#define EXT2_PIN_6 PIN_PA21 +#define EXT2_PIN_7 PIN_PB12 +#define EXT2_PIN_8 PIN_PB13 +#define EXT2_PIN_9 PIN_PB14 +#define EXT2_PIN_10 PIN_PB15 +#define EXT2_PIN_11 PIN_PA08 +#define EXT2_PIN_12 PIN_PA09 +#define EXT2_PIN_13 PIN_PB11 +#define EXT2_PIN_14 PIN_PB10 +#define EXT2_PIN_15 PIN_PA17 +#define EXT2_PIN_16 PIN_PA18 +#define EXT2_PIN_17 PIN_PA16 +#define EXT2_PIN_18 PIN_PA19 +/** @} */ + +/** \name Extension header #2 pin definitions by function + * @{ + */ +#define EXT2_PIN_ADC_0 EXT2_PIN_3 +#define EXT2_PIN_ADC_1 EXT2_PIN_4 +#define EXT2_PIN_GPIO_0 EXT2_PIN_5 +#define EXT2_PIN_GPIO_1 EXT2_PIN_6 +#define EXT2_PIN_PWM_0 EXT2_PIN_7 +#define EXT2_PIN_PWM_1 EXT2_PIN_8 +#define EXT2_PIN_IRQ EXT2_PIN_9 +#define EXT2_PIN_I2C_SDA EXT2_PIN_11 +#define EXT2_PIN_I2C_SCL EXT2_PIN_12 +#define EXT2_PIN_UART_RX EXT2_PIN_13 +#define EXT2_PIN_UART_TX EXT2_PIN_14 +#define EXT2_PIN_SPI_SS_1 EXT2_PIN_10 +#define EXT2_PIN_SPI_SS_0 EXT2_PIN_15 +#define EXT2_PIN_SPI_MOSI EXT2_PIN_16 +#define EXT2_PIN_SPI_MISO EXT2_PIN_17 +#define EXT2_PIN_SPI_SCK EXT2_PIN_18 +/** @} */ + +/** \name Extension header #2 ADC definitions + * @{ + */ +#define EXT2_ADC_MODULE ADC +#define EXT2_ADC_0_CHANNEL 18 +#define EXT2_ADC_0_PIN PIN_PA10B_ADC_AIN18 +#define EXT2_ADC_0_MUX MUX_PA10B_ADC_AIN18 +#define EXT2_ADC_0_PINMUX PINMUX_PA10B_ADC_AIN18 +#define EXT2_ADC_1_CHANNEL 19 +#define EXT2_ADC_1_PIN PIN_PA11B_ADC_AIN19 +#define EXT2_ADC_1_MUX MUX_PA11B_ADC_AIN19 +#define EXT2_ADC_1_PINMUX PINMUX_PA11B_ADC_AIN19 +/** @} */ + +/** \name Extension header #2 PWM definitions + * @{ + */ +#define EXT2_PWM_MODULE TC4 +#define EXT2_PWM_0_CHANNEL 0 +#define EXT2_PWM_0_PIN PIN_PB12E_TC4_WO0 +#define EXT2_PWM_0_MUX MUX_PB12E_TC4_WO0 +#define EXT2_PWM_0_PINMUX PINMUX_PB12E_TC4_WO0 +#define EXT2_PWM_1_CHANNEL 1 +#define EXT2_PWM_1_PIN PIN_PB13E_TC4_WO1 +#define EXT2_PWM_1_MUX MUX_PB13E_TC4_WO1 +#define EXT2_PWM_1_PINMUX PINMUX_PB13E_TC4_WO1 +/** @} */ + +/** \name Extension header #2 PWM for Control definitions + * @{ + */ +#define EXT2_PWM4CTRL_MODULE TCC0 +#define EXT2_PWM4CTRL_0_CHANNEL 2 +#define EXT2_PWM4CTRL_0_OUTPUT 6 +#define EXT2_PWM4CTRL_0_PIN PIN_PB12F_TCC0_WO6 +#define EXT2_PWM4CTRL_0_MUX MUX_PB12F_TCC0_WO6 +#define EXT2_PWM4CTRL_0_PINMUX PINMUX_PB12F_TCC0_WO6 +#define EXT2_PWM4CTRL_1_CHANNEL 3 +#define EXT2_PWM4CTRL_1_OUTPUT 7 +#define EXT2_PWM4CTRL_1_PIN PIN_PB13F_TCC0_WO7 +#define EXT2_PWM4CTRL_1_MUX MUX_PB13F_TCC0_WO7 +#define EXT2_PWM4CTRL_1_PINMUX PINMUX_PB13F_TCC0_WO7 +/** @} */ + +/** \name Extension header #2 IRQ/External interrupt definitions + * @{ + */ +#define EXT2_IRQ_MODULE EIC +#define EXT2_IRQ_INPUT 14 +#define EXT2_IRQ_PIN PIN_PB14A_EIC_EXTINT14 +#define EXT2_IRQ_MUX MUX_PB14A_EIC_EXTINT14 +#define EXT2_IRQ_PINMUX PINMUX_PB14A_EIC_EXTINT14 +/** @} */ + + /** \name Extension header #2 I2C definitions + * @{ + */ +#define EXT2_I2C_MODULE SERCOM2 +#define EXT2_I2C_SERCOM_PINMUX_PAD0 PINMUX_PA08D_SERCOM2_PAD0 +#define EXT2_I2C_SERCOM_PINMUX_PAD1 PINMUX_PA09D_SERCOM2_PAD1 +#define EXT2_I2C_SERCOM_DMAC_ID_TX SERCOM2_DMAC_ID_TX +#define EXT2_I2C_SERCOM_DMAC_ID_RX SERCOM2_DMAC_ID_RX +/** @} */ + +/** \name Extension header #2 UART definitions + * @{ + */ +#define EXT2_UART_MODULE SERCOM4 +#define EXT2_UART_SERCOM_MUX_SETTING USART_RX_1_TX_0_XCK_1 +#define EXT2_UART_SERCOM_PINMUX_PAD0 PINMUX_PB12C_SERCOM4_PAD0 +#define EXT2_UART_SERCOM_PINMUX_PAD1 PINMUX_PB13C_SERCOM4_PAD1 +#define EXT2_UART_SERCOM_PINMUX_PAD2 PINMUX_UNUSED +#define EXT2_UART_SERCOM_PINMUX_PAD3 PINMUX_UNUSED +#define EXT2_UART_SERCOM_DMAC_ID_TX SERCOM4_DMAC_ID_TX +#define EXT2_UART_SERCOM_DMAC_ID_RX SERCOM4_DMAC_ID_RX +/** @} */ + +/** \name Extension header #2 SPI definitions + * @{ + */ +#define EXT2_SPI_MODULE SERCOM1 +#define EXT2_SPI_SERCOM_MUX_SETTING SPI_SIGNAL_MUX_SETTING_E +#define EXT2_SPI_SERCOM_PINMUX_PAD0 PINMUX_PA16C_SERCOM1_PAD0 +#define EXT2_SPI_SERCOM_PINMUX_PAD1 PINMUX_PA17C_SERCOM1_PAD1 +#define EXT2_SPI_SERCOM_PINMUX_PAD2 PINMUX_PA18C_SERCOM1_PAD2 +#define EXT2_SPI_SERCOM_PINMUX_PAD3 PINMUX_PA19C_SERCOM1_PAD3 +#define EXT2_SPI_SERCOM_DMAC_ID_TX SERCOM1_DMAC_ID_TX +#define EXT2_SPI_SERCOM_DMAC_ID_RX SERCOM1_DMAC_ID_RX +/** @} */ + +/** \name Extension header #3 pin definitions + * @{ + */ +#define EXT3_PIN_3 PIN_PA02 +#define EXT3_PIN_4 PIN_PA03 +#define EXT3_PIN_5 PIN_PB30 +#define EXT3_PIN_6 PIN_PA15 +#define EXT3_PIN_7 PIN_PA12 +#define EXT3_PIN_8 PIN_PA13 +#define EXT3_PIN_9 PIN_PA28 +#define EXT3_PIN_10 PIN_PA27 +#define EXT3_PIN_11 PIN_PA08 +#define EXT3_PIN_12 PIN_PA09 +#define EXT3_PIN_13 PIN_PB11 +#define EXT3_PIN_14 PIN_PB10 +#define EXT3_PIN_15 PIN_PB17 +#define EXT3_PIN_16 PIN_PB22 +#define EXT3_PIN_17 PIN_PB16 +#define EXT3_PIN_18 PIN_PB23 +/** @} */ + +/** \name Extension header #3 pin definitions by function + * @{ + */ +#define EXT3_PIN_ADC_0 EXT3_PIN_3 +#define EXT3_PIN_ADC_1 EXT3_PIN_4 +#define EXT3_PIN_GPIO_0 EXT3_PIN_5 +#define EXT3_PIN_GPIO_1 EXT3_PIN_6 +#define EXT3_PIN_PWM_0 EXT3_PIN_7 +#define EXT3_PIN_PWM_1 EXT3_PIN_8 +#define EXT3_PIN_IRQ EXT3_PIN_9 +#define EXT3_PIN_I2C_SDA EXT3_PIN_11 +#define EXT3_PIN_I2C_SCL EXT3_PIN_12 +#define EXT3_PIN_UART_RX EXT3_PIN_13 +#define EXT3_PIN_UART_TX EXT3_PIN_14 +#define EXT3_PIN_SPI_SS_1 EXT3_PIN_10 +#define EXT3_PIN_SPI_SS_0 EXT3_PIN_15 +#define EXT3_PIN_SPI_MOSI EXT3_PIN_16 +#define EXT3_PIN_SPI_MISO EXT3_PIN_17 +#define EXT3_PIN_SPI_SCK EXT3_PIN_18 +/** @} */ + +/** \name Extension header #3 ADC definitions + * @{ + */ +#define EXT3_ADC_MODULE ADC +#define EXT3_ADC_0_CHANNEL 0 +#define EXT3_ADC_0_PIN PIN_PA02B_ADC_AIN0 +#define EXT3_ADC_0_MUX MUX_PA02B_ADC_AIN0 +#define EXT3_ADC_0_PINMUX PINMUX_PA02B_ADC_AIN0 +#define EXT3_ADC_1_CHANNEL 1 +#define EXT3_ADC_1_PIN PIN_PA03B_ADC_AIN1 +#define EXT3_ADC_1_MUX MUX_PA03B_ADC_AIN1 +#define EXT3_ADC_1_PINMUX PINMUX_PA03B_ADC_AIN1 +/** @} */ + +/** \name Extension header #3 PWM for Control definitions + * @{ + */ +#define EXT3_PWM4CTRL_MODULE TCC2 +#define EXT3_PWM4CTRL_0_CHANNEL 0 +#define EXT3_PWM4CTRL_0_OUTPUT 0 +#define EXT3_PWM4CTRL_0_PIN PIN_PA12E_TCC2_WO0 +#define EXT3_PWM4CTRL_0_MUX MUX_PA12E_TCC2_WO0 +#define EXT3_PWM4CTRL_0_PINMUX PINMUX_PA12E_TCC2_WO0 +#define EXT3_PWM4CTRL_1_CHANNEL 1 +#define EXT3_PWM4CTRL_1_OUTPUT 1 +#define EXT3_PWM4CTRL_1_PIN PIN_PA13E_TCC2_WO1 +#define EXT3_PWM4CTRL_1_MUX MUX_PA13E_TCC2_WO1 +#define EXT3_PWM4CTRL_1_PINMUX PINMUX_PA13E_TCC2_WO1 +/** @} */ + +/** \name Extension header #3 IRQ/External interrupt definitions + * @{ + */ +#define EXT3_IRQ_MODULE EIC +#define EXT3_IRQ_INPUT 8 +#define EXT3_IRQ_PIN PIN_PA28A_EIC_EXTINT8 +#define EXT3_IRQ_MUX MUX_PA28A_EIC_EXTINT8 +#define EXT3_IRQ_PINMUX PINMUX_PA28A_EIC_EXTINT8 +/** @} */ + +/** \name Extension header #3 I2C definitions + * @{ + */ +#define EXT3_I2C_MODULE SERCOM2 +#define EXT3_I2C_SERCOM_PINMUX_PAD0 PINMUX_PA08D_SERCOM2_PAD0 +#define EXT3_I2C_SERCOM_PINMUX_PAD1 PINMUX_PA09D_SERCOM2_PAD1 +#define EXT3_I2C_SERCOM_DMAC_ID_TX SERCOM2_DMAC_ID_TX +#define EXT3_I2C_SERCOM_DMAC_ID_RX SERCOM2_DMAC_ID_RX +/** @} */ + +/** \name Extension header #3 UART definitions + * @{ + */ +#define EXT3_UART_MODULE SERCOM4 +#define EXT3_UART_SERCOM_MUX_SETTING USART_RX_3_TX_2_XCK_3 +#define EXT3_UART_SERCOM_PINMUX_PAD0 PINMUX_UNUSED +#define EXT3_UART_SERCOM_PINMUX_PAD1 PINMUX_UNUSED +#define EXT3_UART_SERCOM_PINMUX_PAD2 PINMUX_PB10D_SERCOM4_PAD2 +#define EXT3_UART_SERCOM_PINMUX_PAD3 PINMUX_PB11D_SERCOM4_PAD3 +#define EXT3_UART_SERCOM_DMAC_ID_TX SERCOM4_DMAC_ID_TX +#define EXT3_UART_SERCOM_DMAC_ID_RX SERCOM4_DMAC_ID_RX +/** @} */ + +/** \name Extension header #3 SPI definitions + * @{ + */ +#define EXT3_SPI_MODULE SERCOM5 +#define EXT3_SPI_SERCOM_MUX_SETTING SPI_SIGNAL_MUX_SETTING_E +#define EXT3_SPI_SERCOM_PINMUX_PAD0 PINMUX_PB16C_SERCOM5_PAD0 +#define EXT3_SPI_SERCOM_PINMUX_PAD1 PINMUX_PB17C_SERCOM5_PAD1 +#define EXT3_SPI_SERCOM_PINMUX_PAD2 PINMUX_PB22D_SERCOM5_PAD2 +#define EXT3_SPI_SERCOM_PINMUX_PAD3 PINMUX_PB23D_SERCOM5_PAD3 +#define EXT3_SPI_SERCOM_DMAC_ID_TX SERCOM5_DMAC_ID_TX +#define EXT3_SPI_SERCOM_DMAC_ID_RX SERCOM5_DMAC_ID_RX +/** @} */ + +/** \name Extension header #3 Dataflash + * @{ + */ +#define EXT3_DATAFLASH_SPI_MODULE EXT3_SPI_MODULE +#define EXT3_DATAFLASH_SPI_MUX_SETTING EXT3_SPI_SERCOM_MUX_SETTING +#define EXT3_DATAFLASH_SPI_PINMUX_PAD0 EXT3_SPI_SERCOM_PINMUX_PAD0 +#define EXT3_DATAFLASH_SPI_PINMUX_PAD1 EXT3_SPI_SERCOM_PINMUX_PAD1 +#define EXT3_DATAFLASH_SPI_PINMUX_PAD2 EXT3_SPI_SERCOM_PINMUX_PAD2 +#define EXT3_DATAFLASH_SPI_PINMUX_PAD3 EXT3_SPI_SERCOM_PINMUX_PAD3 +/** @} */ + +/** \name USB definitions + * @{ + */ +#define USB_ID +#define USB_TARGET_DP_PIN PIN_PA25G_USB_DP +#define USB_TARGET_DP_MUX MUX_PA25G_USB_DP +#define USB_TARGET_DP_PINMUX PINMUX_PA25G_USB_DP +#define USB_TARGET_DM_PIN PIN_PA24G_USB_DM +#define USB_TARGET_DM_MUX MUX_PA24G_USB_DM +#define USB_TARGET_DM_PINMUX PINMUX_PA24G_USB_DM +#define USB_VBUS_PIN PIN_PA14 +#define USB_VBUS_EIC_LINE 14 +#define USB_VBUS_EIC_MUX MUX_PA14A_EIC_EXTINT14 +#define USB_VBUS_EIC_PINMUX PINMUX_PA14A_EIC_EXTINT14 +//#define USB_ID_PIN PIN_PA03 +#define USB_ID_EIC_LINE 3 +#define USB_ID_EIC_MUX MUX_PA03A_EIC_EXTINT3 +#define USB_ID_EIC_PINMUX PINMUX_PA03A_EIC_EXTINT3 +/** @} */ + +/** \name Embedded debugger GPIO interface definitions + * @{ + */ +#define EDBG_GPIO0_PIN PIN_PA27 +#define EDBG_GPIO1_PIN PIN_PA28 +#define EDBG_GPIO2_PIN PIN_PA20 +#define EDBG_GPIO3_PIN PIN_PA21 +/** @} */ + +/** \name Embedded debugger USART interface definitions + * @{ + */ +#define EDBG_UART_MODULE -1 /* Not available on this board */ +#define EDBG_UART_RX_PIN -1 /* Not available on this board */ +#define EDBG_UART_RX_MUX -1 /* Not available on this board */ +#define EDBG_UART_RX_PINMUX -1 /* Not available on this board */ +#define EDBG_UART_RX_SERCOM_PAD -1 /* Not available on this board */ +#define EDBG_UART_TX_PIN -1 /* Not available on this board */ +#define EDBG_UART_TX_MUX -1 /* Not available on this board */ +#define EDBG_UART_TX_PINMUX -1 /* Not available on this board */ +#define EDBG_UART_TX_SERCOM_PAD -1 /* Not available on this board */ +/** @} */ + +/** \name Embedded debugger I2C interface definitions + * @{ + */ +#define EDBG_I2C_MODULE SERCOM2 +#define EDBG_I2C_SERCOM_PINMUX_PAD0 PINMUX_PA08D_SERCOM2_PAD0 +#define EDBG_I2C_SERCOM_PINMUX_PAD1 PINMUX_PA09D_SERCOM2_PAD1 +#define EDBG_I2C_SERCOM_DMAC_ID_TX SERCOM2_DMAC_ID_TX +#define EDBG_I2C_SERCOM_DMAC_ID_RX SERCOM2_DMAC_ID_RX +/** @} */ + +/** \name Embedded debugger SPI interface definitions + * @{ + */ +#define EDBG_SPI_MODULE SERCOM5 +#define EDBG_SPI_SERCOM_MUX_SETTING SPI_SIGNAL_MUX_SETTING_E +#define EDBG_SPI_SERCOM_PINMUX_PAD0 PINMUX_PB16C_SERCOM5_PAD0 +#define EDBG_SPI_SERCOM_PINMUX_PAD1 PINMUX_PB31D_SERCOM5_PAD1 +#define EDBG_SPI_SERCOM_PINMUX_PAD2 PINMUX_PB22D_SERCOM5_PAD2 +#define EDBG_SPI_SERCOM_PINMUX_PAD3 PINMUX_PB23D_SERCOM5_PAD3 +#define EDBG_SPI_SERCOM_DMAC_ID_TX SERCOM5_DMAC_ID_TX +#define EDBG_SPI_SERCOM_DMAC_ID_RX SERCOM5_DMAC_ID_RX +/** @} */ + +/** \name Embedded debugger CDC Gateway USART interface definitions + * @{ + */ +#define EDBG_CDC_MODULE SERCOM3 +#define EDBG_CDC_SERCOM_MUX_SETTING USART_RX_1_TX_0_XCK_1 +#define EDBG_CDC_SERCOM_PINMUX_PAD0 PINMUX_PA22C_SERCOM3_PAD0 +#define EDBG_CDC_SERCOM_PINMUX_PAD1 PINMUX_PA23C_SERCOM3_PAD1 +#define EDBG_CDC_SERCOM_PINMUX_PAD2 PINMUX_UNUSED +#define EDBG_CDC_SERCOM_PINMUX_PAD3 PINMUX_UNUSED +#define EDBG_CDC_SERCOM_DMAC_ID_TX SERCOM3_DMAC_ID_TX +#define EDBG_CDC_SERCOM_DMAC_ID_RX SERCOM3_DMAC_ID_RX +/** @} */ + +/** @} */ + +/** \name 802.15.4 TRX Interface definitions + * @{ + */ + +#define AT86RFX_SPI EXT1_SPI_MODULE +#define AT86RFX_RST_PIN EXT1_PIN_7 +#define AT86RFX_MISC_PIN EXT1_PIN_12 +#define AT86RFX_IRQ_PIN EXT1_PIN_9 +#define AT86RFX_SLP_PIN EXT1_PIN_10 +#define AT86RFX_SPI_CS EXT1_PIN_15 +#define AT86RFX_SPI_MOSI EXT1_PIN_16 +#define AT86RFX_SPI_MISO EXT1_PIN_17 +#define AT86RFX_SPI_SCK EXT1_PIN_18 +#define AT86RFX_CSD EXT1_PIN_5 +#define AT86RFX_CPS EXT1_PIN_8 + + +#define AT86RFX_SPI_CONFIG(config) \ + config.mux_setting = EXT1_SPI_SERCOM_MUX_SETTING; \ + config.mode_specific.master.baudrate = AT86RFX_SPI_BAUDRATE; \ + config.pinmux_pad0 = EXT1_SPI_SERCOM_PINMUX_PAD0; \ + config.pinmux_pad1 = PINMUX_UNUSED; \ + config.pinmux_pad2 = EXT1_SPI_SERCOM_PINMUX_PAD2; \ + config.pinmux_pad3 = EXT1_SPI_SERCOM_PINMUX_PAD3; + +#define AT86RFX_IRQ_CHAN EXT1_IRQ_INPUT +#define AT86RFX_INTC_INIT() \ + struct extint_chan_conf eint_chan_conf; \ + extint_chan_get_config_defaults(&eint_chan_conf); \ + eint_chan_conf.gpio_pin = AT86RFX_IRQ_PIN; \ + eint_chan_conf.gpio_pin_mux = EXT1_IRQ_PINMUX; \ + eint_chan_conf.gpio_pin_pull = EXTINT_PULL_NONE; \ + eint_chan_conf.wake_if_sleeping = true; \ + eint_chan_conf.filter_input_signal = false; \ + eint_chan_conf.detection_criteria = EXTINT_DETECT_RISING; \ + extint_chan_set_config(AT86RFX_IRQ_CHAN, &eint_chan_conf); \ + extint_register_callback(AT86RFX_ISR, AT86RFX_IRQ_CHAN, EXTINT_CALLBACK_TYPE_DETECT);\ + extint_chan_enable_callback(AT86RFX_IRQ_CHAN, EXTINT_CALLBACK_TYPE_DETECT); + + +/** Enables the transceiver main interrupt. */ +#define ENABLE_TRX_IRQ() \ + extint_chan_enable_callback(AT86RFX_IRQ_CHAN, EXTINT_CALLBACK_TYPE_DETECT) + +/** Disables the transceiver main interrupt. */ +#define DISABLE_TRX_IRQ() \ + extint_chan_disable_callback(AT86RFX_IRQ_CHAN, EXTINT_CALLBACK_TYPE_DETECT) + +/** Clears the transceiver main interrupt. */ +#define CLEAR_TRX_IRQ() \ + extint_chan_clear_detected(AT86RFX_IRQ_CHAN); + +/* + * This macro saves the trx interrupt status and disables the trx interrupt. + */ +#define ENTER_TRX_REGION() \ + { extint_chan_disable_callback(AT86RFX_IRQ_CHAN, EXTINT_CALLBACK_TYPE_DETECT) + +/* + * This macro restores the transceiver interrupt status + */ +#define LEAVE_TRX_REGION() \ + extint_chan_enable_callback(AT86RFX_IRQ_CHAN, EXTINT_CALLBACK_TYPE_DETECT); } + +/** @} */ + +/** + * \brief Turns off the specified LEDs. + * + * \param led_gpio LED to turn off (LEDx_GPIO). + * + * \note The pins of the specified LEDs are set to GPIO output mode. + */ +#define LED_Off(led_gpio) port_pin_set_output_level(led_gpio,true) + +/** + * \brief Turns on the specified LEDs. + * + * \param led_gpio LED to turn on (LEDx_GPIO). + * + * \note The pins of the specified LEDs are set to GPIO output mode. + */ +#define LED_On(led_gpio) port_pin_set_output_level(led_gpio,false) + +/** + * \brief Toggles the specified LEDs. + * + * \param led_gpio LED to toggle (LEDx_GPIO). + * + * \note The pins of the specified LEDs are set to GPIO output mode. + */ +#define LED_Toggle(led_gpio) port_pin_toggle_output_level(led_gpio) + +/** @} */ + +#ifdef __cplusplus +} +#endif + +#endif /* SAMD21_XPLAINED_PRO_H_INCLUDED */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/port/port.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/port/port.c new file mode 100755 index 0000000..945c541 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/port/port.c @@ -0,0 +1,106 @@ +/** + * \file + * + * \brief SAM GPIO Port Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include + +/** + * \brief Writes a Port pin configuration to the hardware module. + * + * Writes out a given configuration of a Port pin configuration to the hardware + * module. + * + * \note If the pin direction is set as an output, the pull-up/pull-down input + * configuration setting is ignored. + * + * \param[in] gpio_pin Index of the GPIO pin to configure. + * \param[in] config Configuration settings for the pin. + */ +void port_pin_set_config( + const uint8_t gpio_pin, + const struct port_config *const config) +{ + /* Sanity check arguments */ + Assert(config); + + struct system_pinmux_config pinmux_config; + system_pinmux_get_config_defaults(&pinmux_config); + + pinmux_config.mux_position = SYSTEM_PINMUX_GPIO; + pinmux_config.direction = (enum system_pinmux_pin_dir)config->direction; + pinmux_config.input_pull = (enum system_pinmux_pin_pull)config->input_pull; + pinmux_config.powersave = config->powersave; + + system_pinmux_pin_set_config(gpio_pin, &pinmux_config); +} + +/** + * \brief Writes a Port group configuration group to the hardware module. + * + * Writes out a given configuration of a Port group configuration to the + * hardware module. + * + * \note If the pin direction is set as an output, the pull-up/pull-down input + * configuration setting is ignored. + * + * \param[out] port Base of the PORT module to write to. + * \param[in] mask Mask of the port pin(s) to configure. + * \param[in] config Configuration settings for the pin group. + */ +void port_group_set_config( + PortGroup *const port, + const uint32_t mask, + const struct port_config *const config) +{ + /* Sanity check arguments */ + Assert(port); + Assert(config); + + struct system_pinmux_config pinmux_config; + system_pinmux_get_config_defaults(&pinmux_config); + + pinmux_config.mux_position = SYSTEM_PINMUX_GPIO; + pinmux_config.direction = (enum system_pinmux_pin_dir)config->direction; + pinmux_config.input_pull = (enum system_pinmux_pin_pull)config->input_pull; + pinmux_config.powersave = config->powersave; + + system_pinmux_group_set_config(port, mask, &pinmux_config); +} diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/port/port.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/port/port.h new file mode 100755 index 0000000..414da88 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/port/port.h @@ -0,0 +1,564 @@ +/** + * \file + * + * \brief SAM GPIO Port Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef PORT_H_INCLUDED +#define PORT_H_INCLUDED + +/** + * \defgroup asfdoc_sam0_port_group SAM Port Driver (PORT) + * + * This driver for SAM devices provides an interface for the configuration + * and management of the device's General Purpose Input/Output (GPIO) pin + * functionality, for manual pin state reading and writing. + * + * The following peripherals are used by this module: + * - PORT (GPIO Management) + * + * The following devices can use this module: + * - SAM D20/D21 + * - SAM R21 + * - SAM D10/D11 + * + * The outline of this documentation is as follows: + * - \ref asfdoc_sam0_port_prerequisites + * - \ref asfdoc_sam0_port_module_overview + * - \ref asfdoc_sam0_port_special_considerations + * - \ref asfdoc_sam0_port_extra_info + * - \ref asfdoc_sam0_port_examples + * - \ref asfdoc_sam0_port_api_overview + * + * + * \section asfdoc_sam0_port_prerequisites Prerequisites + * + * There are no prerequisites for this module. + * + * + * \section asfdoc_sam0_port_module_overview Module Overview + * + * The device GPIO (PORT) module provides an interface between the user + * application logic and external hardware peripherals, when general pin state + * manipulation is required. This driver provides an easy-to-use interface to + * the physical pin input samplers and output drivers, so that pins can be read + * from or written to for general purpose external hardware control. + * + * \subsection asfdoc_sam0_port_module_overview_pin_numbering Physical and Logical GPIO Pins + * SAM devices use two naming conventions for the I/O pins in the device; one + * physical, and one logical. Each physical pin on a device package is assigned + * both a physical port and pin identifier (e.g. "PORTA.0") as well as a + * monotonically incrementing logical GPIO number (e.g. "GPIO0"). While the + * former is used to map physical pins to their physical internal device module + * counterparts, for simplicity the design of this driver uses the logical GPIO + * numbers instead. + * + * \subsection asfdoc_sam0_port_module_overview_physical Physical Connection + * + * \ref asfdoc_sam0_port_module_int_connections "The diagram below" shows how + * this module is interconnected within the device. + * + * \anchor asfdoc_sam0_port_module_int_connections + * \dot + * digraph overview { + * node [label="Port Pad" shape=square] pad; + * + * subgraph driver { + * node [label="Peripheral Mux" shape=trapezium] pinmux; + * node [label="GPIO Module" shape=ellipse] gpio; + * node [label="Other Peripheral Modules" shape=ellipse style=filled fillcolor=lightgray] peripherals; + * } + * + * pinmux -> gpio; + * pad -> pinmux; + * pinmux -> peripherals; + * } + * \enddot + * + * + * \section asfdoc_sam0_port_special_considerations Special Considerations + * + * The SAM port pin input sampler can be disabled when the pin is configured + * in pure output mode to save power; reading the pin state of a pin configured + * in output-only mode will read the logical output state that was last set. + * + * \section asfdoc_sam0_port_extra_info Extra Information + * + * For extra information see \ref asfdoc_sam0_port_extra. This includes: + * - \ref asfdoc_sam0_port_extra_acronyms + * - \ref asfdoc_sam0_port_extra_dependencies + * - \ref asfdoc_sam0_port_extra_errata + * - \ref asfdoc_sam0_port_extra_history + * + * + * \section asfdoc_sam0_port_examples Examples + * + * For a list of examples related to this driver, see + * \ref asfdoc_sam0_port_exqsg. + * + * + * \section asfdoc_sam0_port_api_overview API Overview + * @{ + */ + +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** \name PORT Alias Macros + * @{ + */ + +/** Convenience definition for GPIO module group A on the device (if + * available). */ +#if (PORT_GROUPS > 0) || defined(__DOXYGEN__) +# define PORTA PORT->Group[0] +#endif + +#if (PORT_GROUPS > 1) || defined(__DOXYGEN__) +/** Convenience definition for GPIO module group B on the device (if + * available). */ +# define PORTB PORT->Group[1] +#endif + +#if (PORT_GROUPS > 2) || defined(__DOXYGEN__) +/** Convenience definition for GPIO module group C on the device (if + * available). */ +# define PORTC PORT->Group[2] +#endif + +#if (PORT_GROUPS > 3) || defined(__DOXYGEN__) +/** Convenience definition for GPIO module group D on the device (if + * available). */ +# define PORTD PORT->Group[3] +#endif + +/** @} */ + +/** + * \brief Port pin direction configuration enum. + * + * Enum for the possible pin direction settings of the port pin configuration + * structure, to indicate the direction the pin should use. + */ +enum port_pin_dir { + /** The pin's input buffer should be enabled, so that the pin state can + * be read. */ + PORT_PIN_DIR_INPUT = SYSTEM_PINMUX_PIN_DIR_INPUT, + /** The pin's output buffer should be enabled, so that the pin state can + * be set. */ + PORT_PIN_DIR_OUTPUT = SYSTEM_PINMUX_PIN_DIR_OUTPUT, + /** The pin's output and input buffers should be enabled, so that the pin + * state can be set and read back. */ + PORT_PIN_DIR_OUTPUT_WTH_READBACK = SYSTEM_PINMUX_PIN_DIR_OUTPUT_WITH_READBACK, +}; + +/** + * \brief Port pin input pull configuration enum. + * + * Enum for the possible pin pull settings of the port pin configuration + * structure, to indicate the type of logic level pull the pin should use. + */ +enum port_pin_pull { + /** No logical pull should be applied to the pin. */ + PORT_PIN_PULL_NONE = SYSTEM_PINMUX_PIN_PULL_NONE, + /** Pin should be pulled up when idle. */ + PORT_PIN_PULL_UP = SYSTEM_PINMUX_PIN_PULL_UP, + /** Pin should be pulled down when idle. */ + PORT_PIN_PULL_DOWN = SYSTEM_PINMUX_PIN_PULL_DOWN, +}; + +/** + * \brief Port pin configuration structure. + * + * Configuration structure for a port pin instance. This structure should be + * initialized by the \ref port_get_config_defaults() function before being + * modified by the user application. + */ +struct port_config { + /** Port buffer input/output direction. */ + enum port_pin_dir direction; + + /** Port pull-up/pull-down for input pins. */ + enum port_pin_pull input_pull; + + /** Enable lowest possible powerstate on the pin + * + * \note All other configurations will be ignored, the pin will be disabled + */ + bool powersave; +}; + +/** \name State reading/writing (physical group orientated) + * @{ + */ + +/** + * \brief Retrieves the PORT module group instance from a given GPIO pin number. + * + * Retrieves the PORT module group instance associated with a given logical + * GPIO pin number. + * + * \param[in] gpio_pin Index of the GPIO pin to convert. + * + * \return Base address of the associated PORT module. + */ +static inline PortGroup* port_get_group_from_gpio_pin( + const uint8_t gpio_pin) +{ + return system_pinmux_get_group_from_gpio_pin(gpio_pin); +} + +/** + * \brief Retrieves the state of a group of port pins that are configured as inputs. + * + * Reads the current logic level of a port module's pins and returns the + * current levels as a bitmask. + * + * \param[in] port Base of the PORT module to read from. + * \param[in] mask Mask of the port pin(s) to read. + * + * \return Status of the port pin(s) input buffers. + */ +static inline uint32_t port_group_get_input_level( + const PortGroup *const port, + const uint32_t mask) +{ + /* Sanity check arguments */ + Assert(port); + + return (port->IN.reg & mask); +} + +/** + * \brief Retrieves the state of a group of port pins that are configured as outputs. + * + * Reads the current logical output level of a port module's pins and returns + * the current levels as a bitmask. + * + * \param[in] port Base of the PORT module to read from. + * \param[in] mask Mask of the port pin(s) to read. + * + * \return Status of the port pin(s) output buffers. + */ +static inline uint32_t port_group_get_output_level( + const PortGroup *const port, + const uint32_t mask) +{ + /* Sanity check arguments */ + Assert(port); + + return (port->OUT.reg & mask); +} + +/** + * \brief Sets the state of a group of port pins that are configured as outputs. + * + * Sets the current output level of a port module's pins to a given logic + * level. + * + * \param[out] port Base of the PORT module to write to. + * \param[in] mask Mask of the port pin(s) to change. + * \param[in] level_mask Mask of the port level(s) to set. + */ +static inline void port_group_set_output_level( + PortGroup *const port, + const uint32_t mask, + const uint32_t level_mask) +{ + /* Sanity check arguments */ + Assert(port); + + port->OUTSET.reg = (mask & level_mask); + port->OUTCLR.reg = (mask & ~level_mask); +} + +/** + * \brief Toggles the state of a group of port pins that are configured as an outputs. + * + * Toggles the current output levels of a port module's pins. + * + * \param[out] port Base of the PORT module to write to. + * \param[in] mask Mask of the port pin(s) to toggle. + */ +static inline void port_group_toggle_output_level( + PortGroup *const port, + const uint32_t mask) +{ + /* Sanity check arguments */ + Assert(port); + + port->OUTTGL.reg = mask; +} + +/** @} */ + +/** \name Configuration and initialization + * @{ + */ + +/** + * \brief Initializes a Port pin/group configuration structure to defaults. + * + * Initializes a given Port pin/group configuration structure to a set of + * known default values. This function should be called on all new + * instances of these configuration structures before being modified by the + * user application. + * + * The default configuration is as follows: + * \li Input mode with internal pullup enabled + * + * \param[out] config Configuration structure to initialize to default values. + */ +static inline void port_get_config_defaults( + struct port_config *const config) +{ + /* Sanity check arguments */ + Assert(config); + + /* Default configuration values */ + config->direction = PORT_PIN_DIR_INPUT; + config->input_pull = PORT_PIN_PULL_UP; + config->powersave = false; +} + +void port_pin_set_config( + const uint8_t gpio_pin, + const struct port_config *const config); + +void port_group_set_config( + PortGroup *const port, + const uint32_t mask, + const struct port_config *const config); + +/** @} */ + +/** \name State reading/writing (logical pin orientated) + * @{ + */ + +/** + * \brief Retrieves the state of a port pin that is configured as an input. + * + * Reads the current logic level of a port pin and returns the current + * level as a boolean value. + * + * \param[in] gpio_pin Index of the GPIO pin to read. + * + * \return Status of the port pin's input buffer. + */ +static inline bool port_pin_get_input_level( + const uint8_t gpio_pin) +{ + PortGroup *const port_base = port_get_group_from_gpio_pin(gpio_pin); + uint32_t pin_mask = (1UL << (gpio_pin % 32)); + + return (port_base->IN.reg & pin_mask); +} + +/** + * \brief Retrieves the state of a port pin that is configured as an output. + * + * Reads the current logical output level of a port pin and returns the current + * level as a boolean value. + * + * \param[in] gpio_pin Index of the GPIO pin to read. + * + * \return Status of the port pin's output buffer. + */ +static inline bool port_pin_get_output_level( + const uint8_t gpio_pin) +{ + PortGroup *const port_base = port_get_group_from_gpio_pin(gpio_pin); + uint32_t pin_mask = (1UL << (gpio_pin % 32)); + + return (port_base->OUT.reg & pin_mask); +} + +/** + * \brief Sets the state of a port pin that is configured as an output. + * + * Sets the current output level of a port pin to a given logic level. + * + * \param[in] gpio_pin Index of the GPIO pin to write to. + * \param[in] level Logical level to set the given pin to. + */ +static inline void port_pin_set_output_level( + const uint8_t gpio_pin, + const bool level) +{ + PortGroup *const port_base = port_get_group_from_gpio_pin(gpio_pin); + uint32_t pin_mask = (1UL << (gpio_pin % 32)); + + /* Set the pin to high or low atomically based on the requested level */ + if (level) { + port_base->OUTSET.reg = pin_mask; + } else { + port_base->OUTCLR.reg = pin_mask; + } +} + +/** + * \brief Toggles the state of a port pin that is configured as an output. + * + * Toggles the current output level of a port pin. + * + * \param[in] gpio_pin Index of the GPIO pin to toggle. + */ +static inline void port_pin_toggle_output_level( + const uint8_t gpio_pin) +{ + PortGroup *const port_base = port_get_group_from_gpio_pin(gpio_pin); + uint32_t pin_mask = (1UL << (gpio_pin % 32)); + + /* Toggle pin output level */ + port_base->OUTTGL.reg = pin_mask; +} + +/** @} */ + +#ifdef __cplusplus +} +#endif + +/** @} */ + +/** + * \page asfdoc_sam0_port_extra Extra Information for PORT Driver + * + * \section asfdoc_sam0_port_extra_acronyms Acronyms + * Below is a table listing the acronyms used in this module, along with their + * intended meanings. + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
AcronymDescription
GPIOGeneral Purpose Input/Output
MUXMultiplexer
+ * + * + * \section asfdoc_sam0_port_extra_dependencies Dependencies + * This driver has the following dependencies: + * + * - \ref asfdoc_sam0_system_pinmux_group "System Pin Multiplexer Driver" + * + * + * \section asfdoc_sam0_port_extra_errata Errata + * There are no errata related to this driver. + * + * + * \section asfdoc_sam0_port_extra_history Module History + * An overview of the module history is presented in the table below, with + * details on the enhancements and fixes made to the module since its first + * release. The current version of this corresponds to the newest version in + * the table. + * + * + * + * + * + * + * + * + * + * + * + *
Changelog
Added support for SAMD21
Initial Release
+ */ + +/** + * \page asfdoc_sam0_port_exqsg Examples for PORT Driver + * + * This is a list of the available Quick Start guides (QSGs) and example + * applications for \ref asfdoc_sam0_port_group. QSGs are simple examples with + * step-by-step instructions to configure and use this driver in a selection of + * use cases. Note that QSGs can be compiled as a standalone application or be + * added to the user application. + * + * - \subpage asfdoc_sam0_port_basic_use_case + * + * \page asfdoc_sam0_port_document_revision_history Document Revision History + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Doc. Rev. + * Date + * Comments + *
E04/2014Added support for SAMD10/D11.
D02/2014Added support for SAMR21.
C01/2014Added support for SAMD21.
B06/2013Corrected documentation typos.
A06/2013Initial release
+ */ + +#endif diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/port/quick_start/qs_port_basic.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/port/quick_start/qs_port_basic.h new file mode 100755 index 0000000..39414b2 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/port/quick_start/qs_port_basic.h @@ -0,0 +1,105 @@ +/** + * \file + * + * \brief SAM GPIO Port Driver Quick Start + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +/** + * \page asfdoc_sam0_port_basic_use_case Quick Start Guide for PORT - Basic + * + * In this use case, the PORT module is configured for: + * \li One pin in input mode, with pull-up enabled + * \li One pin in output mode + * + * This use case sets up the PORT to read the current state of a GPIO pin set as + * an input, and mirrors the opposite logical state on a pin configured as an + * output. + * + * \section asfdoc_sam0_port_basic_use_case_setup Setup + * + * \subsection asfdoc_sam0_port_basic_use_case_setup_prereq Prerequisites + * There are no special setup requirements for this use-case. + * + * \subsection asfdoc_sam0_port_basic_use_case_setup_code Code + * Copy-paste the following setup code to your user application: + * \snippet qs_port_basic.c setup + * + * Add to user application initialization (typically the start of \c main()): + * \snippet qs_port_basic.c setup_init + * + * \subsection asfdoc_sam0_port_basic_use_case_setup_flow Workflow + * -# Create a PORT module pin configuration struct, which can be filled out to + * adjust the configuration of a single port pin. + * \snippet qs_port_basic.c setup_1 + * -# Initialize the pin configuration struct with the module's default values. + * \snippet qs_port_basic.c setup_2 + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Adjust the configuration struct to request an input pin. + * \snippet qs_port_basic.c setup_3 + * -# Configure push button pin with the initialized pin configuration struct, to enable + * the input sampler on the pin. + * \snippet qs_port_basic.c setup_4 + * -# Adjust the configuration struct to request an output pin. + * \snippet qs_port_basic.c setup_5 + * \note The existing configuration struct may be re-used, as long as any + * values that have been altered from the default settings are taken + * into account by the user application. + * + * -# Configure LED pin with the initialized pin configuration struct, to enable + * the output driver on the pin. + * \snippet qs_port_basic.c setup_6 + * + * \section asfdoc_sam0_port_basic_use_case_use_main Use Case + * + * \subsection asfdoc_sam0_port_basic_use_case_code Code + * Copy-paste the following code to your user application: + * \snippet qs_port_basic.c main + * + * \subsection asfdoc_sam0_port_basic_use_case_flow Workflow + * -# Read in the current input sampler state of push button pin, which has been + * configured as an input in the use-case setup code. + * \snippet qs_port_basic.c main_1 + * -# Write the inverted pin level state to LED pin, which has been configured as + * an output in the use-case setup code. + * \snippet qs_port_basic.c main_2 + */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/rtc/quick_start_count/qs_rtc_count_basic.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/rtc/quick_start_count/qs_rtc_count_basic.h new file mode 100755 index 0000000..f4c6b36 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/rtc/quick_start_count/qs_rtc_count_basic.h @@ -0,0 +1,117 @@ +/** + * \file + * + * \brief SAM RTC Count Quick Start + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +/** + * \page asfdoc_sam0_rtc_count_basic_use_case Quick Start Guide for RTC (COUNT) - Basic + * In this use case, the RTC is set up in count mode. The example configures the + * RTC in 16 bit mode, with continuous updates to the COUNT register, together + * with a set compare register value. Every 2000ms a LED on the board is + * toggled. + * + * \section asfdoc_sam0_rtc_count_basic_use_case_prereq Prerequisites + * The Generic Clock Generator for the RTC should be configured and enabled; if + * you are using the System Clock driver, this may be done via \c conf_clocks.h. + * + * \subsection asfdoc_sam0_rtc_count_basic_use_case_setup_clocks Clocks and Oscillators + * The \c conf_clock.h file needs to be changed with the following values to + * configure the clocks and oscillators for the module. + * + * The following oscillator settings are needed: + * \snippet conf_clocks.h oscillator_settings + * The following generic clock settings are needed: + * \snippet conf_clocks.h gclk_settings + * + * \section asfdoc_sam0_rtc_count_basic_use_case_setup Setup + * + * \subsection asfdoc_sam0_rtc_count_basic_use_case_init_code Initialization Code + * Create a rtc_module struct and add to the main application source file, + * outside of any functions: + * \snippet qs_rtc_count_basic.c rtc_module_instance + * + * Copy-paste the following setup code to your applications \c main(): + * \snippet qs_rtc_count_basic.c initiate + * + * \subsection asfdoc_sam0_rtc_count_basic_use_case_main_code Add to Main + * Add the following to your \c main(). + * \snippet qs_rtc_count_basic.c add_main + * + * \subsection rtc_count_basic_use_workflow Workflow + * -# Create a RTC configuration structure to hold the desired RTC driver + * settings. + * \snippet qs_rtc_count_basic.c set_conf + * -# Fill the configuration structure with the default driver configuration. + * \snippet qs_rtc_count_basic.c get_default + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Alter the RTC driver configuration to run in 16-bit counting mode, with + * continuous counter register updates. + * \snippet qs_rtc_count_basic.c set_config + * -# Initialize the RTC module. + * \snippet qs_rtc_count_basic.c init_rtc + * -# Enable the RTC module, so that it may begin counting. + * \snippet qs_rtc_count_basic.c enable + * + * \section asfdoc_sam0_rtc_count_basic_use_case_implement Implementation + * Code used to implement the initialized module. + * + * \subsection asfdoc_sam0_rtc_count_basic_use_case_imp_code Code + * Add after initialization in main(). + * \snippet qs_rtc_count_basic.c implementation_code + * + * \subsection asfdoc_sam0_rtc_count_basic_use_case_imp_workflow Workflow + * -# Set RTC period to 2000ms (2 seconds) so that it will overflow and reset + * back to zero every two seconds. + * \snippet qs_rtc_count_basic.c period + * -# Enter an infinite loop to poll the RTC driver to check when a comparison + * match occurs. + * \snippet qs_rtc_count_basic.c main_loop + * -# Check if the RTC driver has found a match on compare channel 0 against the + * current RTC count value. + * \snippet qs_rtc_count_basic.c check_match + * -# Once a compare match occurs, perform the desired user action. + * \snippet qs_rtc_count_basic.c compare_match_action + * -# Clear the compare match, so that future matches may occur. + * \snippet qs_rtc_count_basic.c clear_compare_match + */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/rtc/quick_start_count_callback/qs_rtc_count_callback.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/rtc/quick_start_count_callback/qs_rtc_count_callback.h new file mode 100755 index 0000000..7eb7a9e --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/rtc/quick_start_count_callback/qs_rtc_count_callback.h @@ -0,0 +1,128 @@ +/** + * \file + * + * \brief SAM RTC Count Quick Start + * + * Copyright (C) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +/** + * \page asfdoc_sam0_rtc_count_callback_use_case Quick Start Guide for RTC (COUNT) - Callback + * + * In this use case, the RTC is set up in count mode. The quick start + * configures the RTC in 16 bit mode and to continuously update COUNT register. + * The rest of the configuration is according to the + * \ref rtc_count_get_config_defaults "default". + * A callback is implemented for when the RTC overflows. + * + * \section asfdoc_sam0_rtc_count_callback_use_case_prereq Prerequisites + * The Generic Clock Generator for the RTC should be configured and enabled; if + * you are using the System Clock driver, this may be done via \c conf_clocks.h. + * + * \subsection asfdoc_sam0_rtc_count_callback_use_case_setup_clocks Clocks and Oscillators + * The \c conf_clock.h file needs to be changed with the following values to + * configure the clocks and oscillators for the module. + * + * The following oscillator settings are needed: + * \snippet conf_clocks.h oscillator_settings + * The following generic clock settings are needed: + * \snippet conf_clocks.h gclk_settings + * + * \section asfdoc_sam0_rtc_count_callback_use_case_setup Setup + * + * \subsection asfdoc_sam0_rtc_count_callback_use_case_setup_code Code + * Create a rtc_module struct and add to the main application source file, + * outside of any functions: + * \snippet qs_rtc_count_callback.c rtc_module_instance + * The following must be added to the user application: + * + * Function for setting up the module: + * \snippet qs_rtc_count_callback.c initialize_rtc + * + * Callback function: + * \snippet qs_rtc_count_callback.c callback + * + * Function for setting up the callback functionality of the driver: + * \snippet qs_rtc_count_callback.c setup_callback +* + * Add to user application main(): + * \snippet qs_rtc_count_callback.c run_initialize_rtc + * + * \subsection asfdoc_sam0_rtc_count_callback_use_case_setup_workflow Workflow + * -# Initialize system. + * \snippet qs_rtc_count_callback.c system_init + * -# Configure and enable module. + * \snippet qs_rtc_count_callback.c run_conf + * -# Create a RTC configuration structure to hold the desired RTC driver + * settings and fill it with the default driver configuration values. + * \snippet qs_rtc_count_callback.c init_conf + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Alter the RTC driver configuration to run in 16-bit counting mode, with + * continuous counter register updates and a compare value of 1000ms. + * \snippet qs_rtc_count_callback.c set_config + * -# Initialize the RTC module. + * \snippet qs_rtc_count_callback.c init_rtc + * -# Enable the RTC module, so that it may begin counting. + * \snippet qs_rtc_count_callback.c enable + * -# Configure callback functionality. + * \snippet qs_rtc_count_callback.c run_callback + * -# Register overflow callback. + * \snippet qs_rtc_count_callback.c reg_callback + * -# Enable overflow callback. + * \snippet qs_rtc_count_callback.c en_callback + * -# Set period. + * \snippet qs_rtc_count_callback.c period + * + * \section asfdoc_sam0_rtc_count_callback_use_case_implementation Implementation + * + * \subsection asfdoc_sam0_rtc_count_callback_use_case_implementation_code Code + * Add to user application main: + * \snippet qs_rtc_count_callback.c while + * \subsection asfdoc_sam0_rtc_count_callback_use_case_implementation_workflow Workflow + * -# Infinite while loop while waiting for callbacks. + * \snippet qs_rtc_count_callback.c while + * + * \section asfdoc_sam0_rtc_count_callback_use_case_callback Callback + * Each time the RTC counter overflows, the callback function will be called. + * \subsection asfdoc_sam0_rtc_count_callback_use_case_callback_workflow Workflow + * -# Perform the desired user action for each RTC overflow: + * \snippet qs_rtc_count_callback.c overflow_act + */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/rtc/rtc_count.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/rtc/rtc_count.c new file mode 100755 index 0000000..80f91ca --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/rtc/rtc_count.c @@ -0,0 +1,684 @@ +/** + * \file + * + * \brief SAM RTC Driver (Count Mode) + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include "rtc_count.h" +#include + +#if !defined(__DOXYGEN__) +struct rtc_module *_rtc_instance[RTC_INST_NUM]; +#endif + +/** + * \brief Resets the RTC module. + * Resets the RTC to hardware defaults. + * + * \param[in,out] module Pointer to the software instance struct + */ +void rtc_count_reset(struct rtc_module *const module) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Disable module before reset. */ + rtc_count_disable(module); + +#if RTC_COUNT_ASYNC == true + module->registered_callback = 0; + module->enabled_callback = 0; +#endif + + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + + /* Initiate software reset. */ + rtc_module->MODE0.CTRL.reg |= RTC_MODE0_CTRL_SWRST; +} + +/** + * \internal Applies the given configuration. + * + * Sets the configurations given from the configuration structure to the + * hardware module + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] config Pointer to the configuration structure. + * + * \return Status of the configuration procedure. + * \retval STATUS_OK RTC configurations was set successfully. + * \retval STATUS_ERR_INVALID_ARG If invalid argument(s) were given. + */ +static enum status_code _rtc_count_set_config( + struct rtc_module *const module, + const struct rtc_count_config *const config) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + rtc_module->MODE0.CTRL.reg = RTC_MODE0_CTRL_MODE(0) | config->prescaler; + + /* Set mode and clear on match if applicable. */ + switch (config->mode) { + case RTC_COUNT_MODE_32BIT: + /* Set 32bit mode and clear on match if applicable. */ + rtc_module->MODE0.CTRL.reg |= RTC_MODE0_CTRL_MODE(0); + + /* Check if clear on compare match should be set. */ + if (config->clear_on_match) { + /* Set clear on match. */ + rtc_module->MODE0.CTRL.reg |= RTC_MODE0_CTRL_MATCHCLR; + } + /* Set compare values. */ + for (uint8_t i = 0; i < RTC_NUM_OF_COMP32; i++) { + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + + rtc_count_set_compare(module, config->compare_values[i], + (enum rtc_count_compare)i); + } + break; + + case RTC_COUNT_MODE_16BIT: + /* Set 16bit mode. */ + rtc_module->MODE1.CTRL.reg |= RTC_MODE1_CTRL_MODE(1); + + /* Check if match on clear is set, and return invalid + * argument if set. */ + if (config->clear_on_match) { + Assert(false); + return STATUS_ERR_INVALID_ARG; + } + /* Set compare values. */ + for (uint8_t i = 0; i < RTC_NUM_OF_COMP16; i++) { + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + + rtc_count_set_compare(module, config->compare_values[i], + (enum rtc_count_compare)i); + } + break; + default: + Assert(false); + return STATUS_ERR_INVALID_ARG; + } + + /* Check to set continuously clock read update mode. */ + if (config->continuously_update) { + /* Set continuously mode. */ + rtc_module->MODE0.READREQ.reg |= RTC_READREQ_RCONT; + } + + /* Return status OK if everything was configured. */ + return STATUS_OK; +} + +/** + * \brief Initializes the RTC module with given configurations. + * + * Initializes the module, setting up all given configurations to provide + * the desired functionality of the RTC. + * + * \param[out] module Pointer to the software instance struct + * \param[in] hw Pointer to hardware instance + * \param[in] config Pointer to the configuration structure. + * + * \return Status of the initialization procedure. + * \retval STATUS_OK If the initialization was run stressfully. + * \retval STATUS_ERR_INVALID_ARG If invalid argument(s) were given. + */ +enum status_code rtc_count_init( + struct rtc_module *const module, + Rtc *const hw, + const struct rtc_count_config *const config) +{ + /* Sanity check arguments */ + Assert(module); + Assert(hw); + Assert(config); + + /* Initialize device instance */ + module->hw = hw; + + /* Turn on the digital interface clock */ + system_apb_clock_set_mask(SYSTEM_CLOCK_APB_APBA, PM_APBAMASK_RTC); + + /* Set up GCLK */ + struct system_gclk_chan_config gclk_chan_conf; + system_gclk_chan_get_config_defaults(&gclk_chan_conf); + gclk_chan_conf.source_generator = GCLK_GENERATOR_2; + system_gclk_chan_set_config(RTC_GCLK_ID, &gclk_chan_conf); + system_gclk_chan_enable(RTC_GCLK_ID); + + /* Reset module to hardware defaults. */ + rtc_count_reset(module); + + /* Save conf_struct internally for continued use. */ + module->mode = config->mode; + module->continuously_update = config->continuously_update; + +# if (RTC_INST_NUM == 1) + _rtc_instance[0] = module; +# else + /* Register this instance for callbacks*/ + _rtc_instance[_rtc_get_inst_index(hw)] = module; +# endif + + /* Set config and return status. */ + return _rtc_count_set_config(module, config); +} + +/** + * \brief Set the current count value to desired value. + * + * Sets the value of the counter to the specified value. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] count_value The value to be set in count register. + * + * \return Status of setting the register. + * \retval STATUS_OK If everything was executed correctly. + * \retval STATUS_ERR_INVALID_ARG If invalid argument(s) were provided. + */ +enum status_code rtc_count_set_count( + struct rtc_module *const module, + const uint32_t count_value) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + + /* Set count according to mode */ + switch(module->mode){ + case RTC_COUNT_MODE_32BIT: + /* Write value to register. */ + rtc_module->MODE0.COUNT.reg = count_value; + + break; + + case RTC_COUNT_MODE_16BIT: + /* Check if 16 bit value is provided. */ + if(count_value > 0xffff){ + return STATUS_ERR_INVALID_ARG; + } + + /* Write value to register. */ + rtc_module->MODE1.COUNT.reg = (uint32_t)count_value; + + break; + + default: + Assert(false); + return STATUS_ERR_INVALID_ARG; + } + return STATUS_OK; +} + +/** + * \brief Get the current count value. + * + * \param[in,out] module Pointer to the software instance struct + * + * Returns the current count value. + * + * \return The current counter value as a 32 bit unsigned integer. + */ +uint32_t rtc_count_get_count(struct rtc_module *const module) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Initialize return value. */ + uint32_t ret_val; + + /* Change of read method based on value of continuously_update value in + * the configuration structure. */ + if(!(module->continuously_update)) { + /* Request read on count register. */ + rtc_module->MODE0.READREQ.reg = RTC_READREQ_RREQ; + + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + } + + /* Read value based on mode. */ + switch (module->mode) { + case RTC_COUNT_MODE_32BIT: + /* Return count value in 32 bit mode. */ + ret_val = rtc_module->MODE0.COUNT.reg; + + break; + + case RTC_COUNT_MODE_16BIT: + /* Return count value in 16 bit mode. */ + ret_val = (uint32_t)rtc_module->MODE1.COUNT.reg; + + break; + + default: + Assert(false); + /* Counter not initialized. Assume counter value 0.*/ + ret_val = 0; + break; + } + + return ret_val; +} + +/** + * \brief Set the compare value for the specified compare. + * + * Sets the value specified by the implementer to the requested compare. + * + * \note Compare 4 and 5 are only available in 16 bit mode. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] comp_value The value to be written to the compare. + * \param[in] comp_index Index of the compare to set. + * + * \return Status indicating if compare was successfully set. + * \retval STATUS_OK If compare was successfully set. + * \retval STATUS_ERR_INVALID_ARG If invalid argument(s) were provided. + * \retval STATUS_ERR_BAD_FORMAT If the module was not initialized in a mode. + */ +enum status_code rtc_count_set_compare( + struct rtc_module *const module, + const uint32_t comp_value, + const enum rtc_count_compare comp_index) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + + /* Set compare values based on operation mode. */ + switch (module->mode) { + case RTC_COUNT_MODE_32BIT: + /* Check sanity of comp_index. */ + if ((uint32_t)comp_index > RTC_NUM_OF_COMP32) { + return STATUS_ERR_INVALID_ARG; + } + + /* Set compare value for COMP. */ + rtc_module->MODE0.COMP[comp_index].reg = comp_value; + + break; + + case RTC_COUNT_MODE_16BIT: + /* Check sanity of comp_index. */ + if ((uint32_t)comp_index > RTC_NUM_OF_COMP16) { + return STATUS_ERR_INVALID_ARG; + } + + /* Check that 16 bit value is provided. */ + if (comp_value > 0xffff) { + Assert(false); + return STATUS_ERR_INVALID_ARG; + } + + /* Set compare value for COMP. */ + rtc_module->MODE1.COMP[comp_index].reg = comp_value & 0xffff; + + break; + + default: + Assert(false); + return STATUS_ERR_BAD_FORMAT; + } + + /* Return status if everything is OK. */ + return STATUS_OK; +} + +/** + * \brief Get the current compare value of specified compare. + * + * Retrieves the current value of the specified compare. + * + * \note Compare 4 and 5 are only available in 16 bit mode. + * + * \param[in,out] module Pointer to the software instance struct + * \param[out] comp_value Pointer to 32 bit integer that will be populated with + * the current compare value. + * \param[in] comp_index Index of compare to check. + * + * \return Status of the reading procedure. + * \retval STATUS_OK If the value was read correctly. + * \retval STATUS_ERR_INVALID_ARG If invalid argument(s) were provided. + * \retval STATUS_ERR_BAD_FORMAT If the module was not initialized in a mode. + */ +enum status_code rtc_count_get_compare( + struct rtc_module *const module, + uint32_t *const comp_value, + const enum rtc_count_compare comp_index) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + switch (module->mode) { + case RTC_COUNT_MODE_32BIT: + /* Check sanity of comp_index. */ + if ((uint32_t)comp_index > RTC_NUM_OF_COMP32) { + return STATUS_ERR_INVALID_ARG; + } + + /* Get compare value for COMP. */ + *comp_value = rtc_module->MODE0.COMP[comp_index].reg; + + break; + + case RTC_COUNT_MODE_16BIT: + /* Check sanity of comp_index. */ + if ((uint32_t)comp_index > RTC_NUM_OF_COMP16) { + return STATUS_ERR_INVALID_ARG; + } + + /* Get compare value for COMP. */ + *comp_value = (uint32_t)rtc_module->MODE1.COMP[comp_index].reg; + + break; + + default: + Assert(false); + return STATUS_ERR_BAD_FORMAT; + } + /* Return status showing everything is OK. */ + return STATUS_OK; +} + +/** + * \brief Retrieves the value of period. + * + * Retrieves the value of the period for the 16 bit mode counter. + * + * \note Only available in 16 bit mode. + * + * \param[in,out] module Pointer to the software instance struct + * \param[out] period_value Pointer to value for return argument. + * + * \return Status of getting the period value. + * \retval STATUS_OK If the period value was read correctly. + * \retval STATUS_ERR_UNSUPPORTED_DEV If incorrect mode was set. + */ +enum status_code rtc_count_get_period( + struct rtc_module *const module, + uint16_t *const period_value) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Check that correct mode is set. */ + if (module->mode != RTC_COUNT_MODE_16BIT) { + return STATUS_ERR_UNSUPPORTED_DEV; + } + + /* Returns the value. */ + *period_value = rtc_module->MODE1.PER.reg; + + return STATUS_OK; +} + +/** + * \brief Set the given value to the period. + * + * Sets the given value to the period. + * + * \note Only available in 16 bit mode. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] period_value The value to set to the period. + * + * \return Status of setting the period value. + * \retval STATUS_OK If the period was set correctly. + * \retval STATUS_ERR_UNSUPPORTED_DEV If module is not operated in 16 bit mode. + */ +enum status_code rtc_count_set_period( + struct rtc_module *const module, + const uint16_t period_value) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Check that correct mode is set. */ + if (module->mode != RTC_COUNT_MODE_16BIT) { + return STATUS_ERR_UNSUPPORTED_DEV; + } + + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + + /* Write value to register. */ + rtc_module->MODE1.PER.reg = period_value; + + return STATUS_OK; +} + +/** + * \brief Check if RTC compare match has occurred. + * + * Checks the compare flag to see if a match has occurred. The compare flag is + * set when there is a compare match between counter and the compare. + * + * \note Compare 4 and 5 are only available in 16 bit mode. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] comp_index Index of compare to check current flag. + */ +bool rtc_count_is_compare_match( + struct rtc_module *const module, + const enum rtc_count_compare comp_index) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Check sanity. */ + switch (module->mode) { + case RTC_COUNT_MODE_32BIT: + /* Check sanity for 32 bit mode. */ + if (comp_index > RTC_NUM_OF_COMP32) { + return false; + } + + break; + + case RTC_COUNT_MODE_16BIT: + /* Check sanity for 16 bit mode. */ + if (comp_index > RTC_NUM_OF_COMP16) { + return false; + } + + break; + + default: + Assert(false); + return false; + } + + /* Set status of INTFLAG as return argument. */ + return (rtc_module->MODE0.INTFLAG.reg & (1 << comp_index)); +} + +/** + * \brief Clears RTC compare match flag. + * + * Clears the compare flag. The compare flag is set when there is a compare + * match between the counter and the compare. + * + * \note Compare 4 and 5 are only available in 16 bit mode. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] comp_index Index of compare to check current flag. + * + * \return Status indicating if flag was successfully cleared. + * \retval STATUS_OK If flag was successfully cleared. + * \retval STATUS_ERR_INVALID_ARG If invalid argument(s) were provided. + * \retval STATUS_ERR_BAD_FORMAT If the module was not initialized in a mode. + */ +enum status_code rtc_count_clear_compare_match( + struct rtc_module *const module, + const enum rtc_count_compare comp_index) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Check sanity. */ + switch (module->mode){ + case RTC_COUNT_MODE_32BIT: + /* Check sanity for 32 bit mode. */ + if (comp_index > RTC_NUM_OF_COMP32) { + return STATUS_ERR_INVALID_ARG; + } + + break; + + case RTC_COUNT_MODE_16BIT: + /* Check sanity for 16 bit mode. */ + if (comp_index > RTC_NUM_OF_COMP16) { + return STATUS_ERR_INVALID_ARG; + } + + break; + + default: + Assert(false); + return STATUS_ERR_BAD_FORMAT; + } + + /* Clear INTFLAG. */ + rtc_module->MODE0.INTFLAG.reg = RTC_MODE1_INTFLAG_CMP(1 << comp_index); + + return STATUS_OK; +} + +/** + * \brief Calibrate for too-slow or too-fast oscillator. + * + * When used, the RTC will compensate for an inaccurate oscillator. The + * RTC module will add or subtract cycles from the RTC prescaler to adjust the + * frequency in approximately 1 PPM steps. The provided correction value should + * be between 0 and 127, allowing for a maximum 127 PPM correction. + * + * If no correction is needed, set value to zero. + * + * \note Can only be used when the RTC is operated in 1Hz. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] value Ranging from -127 to 127 used for the correction. + * + * \return Status of the calibration procedure. + * \retval STATUS_OK If calibration was executed correctly. + * \retval STATUS_ERR_INVALID_ARG If invalid argument(s) were provided. + */ +enum status_code rtc_count_frequency_correction( + struct rtc_module *const module, + const int8_t value) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Check if valid argument. */ + if (abs(value) > 0x7F) { + /* Value bigger than allowed, return invalid argument. */ + return STATUS_ERR_INVALID_ARG; + } + + uint32_t new_correction_value; + + /* Load the new correction value as a positive value, sign added later */ + new_correction_value = abs(value); + + /* Convert to positive value and adjust register sign bit. */ + if (value < 0) { + new_correction_value |= RTC_FREQCORR_SIGN; + } + + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + + /* Set value. */ + rtc_module->MODE0.FREQCORR.reg = new_correction_value; + + return STATUS_OK; +} + diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/rtc/rtc_count.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/rtc/rtc_count.h new file mode 100755 index 0000000..90724f6 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/rtc/rtc_count.h @@ -0,0 +1,935 @@ +/** + * \file + * + * \brief SAM RTC Driver (Count Mode) + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef RTC_COUNT_H_INCLUDED +#define RTC_COUNT_H_INCLUDED + +/** + * \defgroup asfdoc_sam0_rtc_count_group SAM RTC Count Driver (RTC COUNT) + * + * This driver for SAM devices provides an interface for the configuration + * and management of the device's Real Time Clock functionality in Count + * operating mode, for the configuration and retrieval of the current RTC + * counter value. The following driver API modes are covered by this + * manual: + * + * - Polled APIs + * \if RTC_COUNT_CALLBACK_MODE + * - Callback APIs + * \endif + * + * The following peripherals are used by this module: + * - RTC (Real Time Clock) + * + * The following devices can use this module: + * - SAM D20/D21 + * - SAM R21 + * - SAM D10/D11 + * + * The outline of this documentation is as follows: + * - \ref asfdoc_sam0_rtc_count_prerequisites + * - \ref asfdoc_sam0_rtc_count_module_overview + * - \ref asfdoc_sam0_rtc_count_special_considerations + * - \ref asfdoc_sam0_rtc_count_extra_info + * - \ref asfdoc_sam0_rtc_count_examples + * - \ref asfdoc_sam0_rtc_count_api_overview + * + * + * \section asfdoc_sam0_rtc_count_prerequisites Prerequisites + * + * There are no prerequisites for this module. + * + * + * \section asfdoc_sam0_rtc_count_module_overview Module Overview + * + * The RTC module in the SAM devices is a 32-bit counter, with a 10-bit + * programmable prescaler. Typically, the RTC clock is run continuously, + * including in the device's low-power sleep modes, to track the current time + * and date information. The RTC can be used as a source to wake up the system + * at a scheduled time or periodically using the alarm functions. + * + * In this driver, the RTC is operated in Count mode. This allows for an + * easy integration of an asynchronous counter into a user application, which is + * capable of operating while the device is in sleep mode. + * + * Whilst operating in Count mode, the RTC features: + * - 16-bit counter mode + * - Selectable counter period + * - Up to 6 configurable compare values + * - 32-bit counter mode + * - Clear counter value on match + * - Up to 4 configurable compare values + * + * + * \section asfdoc_sam0_rtc_count_module_overview_compares Compare and Overflow + * The RTC can be used with up to 4/6 compare values (depending on selected + * operation mode). These compare values will trigger on match with the current + * RTC counter value, and can be set up to trigger an interrupt, event, or both. + * The RTC can also be configured to clear the counter value on compare match + * in 32-bit mode, resetting the count value back to zero. + * + * If the RTC is operated without the Clear on Match option enabled, or in + * 16-bit mode, the RTC counter value will instead be cleared on overflow once + * the maximum count value has been reached: + * + * \f[ COUNT_{MAX} = 2^{32}-1 \f] for 32-bit counter mode, and + * \f[ COUNT_{MAX} = 2^{16}-1 \f] for 16-bit counter mode. + * + * When running in 16-bit mode, the overflow value is selectable with a period + * value. The counter overflow will then occur when the counter value reaches + * the specified period value. + * + * \subsection asfdoc_sam0_rtc_count_module_overview_periodic Periodic Events + * The RTC can generate events at periodic intervals, allowing for direct + * peripheral actions without CPU intervention. The periodic events can be + * generated on the upper 8 bits of the RTC prescaler, and will be generated on + * the rising edge transition of the specified bit. The resulting periodic + * frequency can be calculated by the following formula: + * + * \f[ f_{PERIODIC}=\frac{f_{ASY}}{2^{n+3}} \f] + * + * Where \f$f_{ASY}\f$ refers to the \e asynchronous clock set up in the RTC + * module configuration. The \b n parameter is the event source generator index + * of the RTC module. If the asynchronous clock is operated at the recommended + * frequency of 1 KHz, the formula results in the values shown in + * \ref asfdoc_sam0_rtc_count_module_rtc_hz "the table below". + * + * \anchor asfdoc_sam0_rtc_count_module_rtc_hz + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
RTC event frequencies for each prescaler bit using a 1KHz clock
n Periodic event
7 1 Hz
6 2 Hz
5 4 Hz
4 8 Hz
3 16 Hz
2 32 Hz
1 64 Hz
0 128 Hz
+ * + * \note The connection of events between modules requires the use of the + * \ref asfdoc_sam0_events_group "SAM Event System Driver (EVENTS)" + * to route output event of one module to the the input event of another. + * For more information on event routing, refer to the event driver + * documentation. + * + * \subsection asfdoc_sam0_rtc_count_module_overview_correction Digital Frequency Correction + * The RTC module contains Digital Frequency Correction logic to compensate for + * inaccurate source clock frequencies which would otherwise result in skewed + * time measurements. The correction scheme requires that at least two bits + * in the RTC module prescaler are reserved by the correction logic. As a + * result of this implementation, frequency correction is only available when + * the RTC is running from a 1 Hz reference clock. + * + * The correction procedure is implemented by subtracting or adding a single + * cycle from the RTC prescaler every 1024 RTC GCLK cycles. The adjustment is + * applied the specified number of time (max 127) over 976 of these periods. The + * corresponding correction in PPM will be given by: + * + * \f[ Correction(PPM) = \frac{VALUE}{999424}10^6 \f] + * + * The RTC clock will tick faster if provided with a positive correction value, + * and slower when given a negative correction value. + * + * + * \section asfdoc_sam0_rtc_count_special_considerations Special Considerations + * + * \subsection asfdoc_sam0_rtc_count_special_considerations_clock Clock Setup + * The RTC is typically clocked by a specialized GCLK generator that has a + * smaller prescaler than the others. By default the RTC clock is on, selected + * to use the internal 32 KHz RC-oscillator with a prescaler of 32, giving a + * resulting clock frequency of 1 KHz to the RTC. When the internal RTC + * prescaler is set to 1024, this yields an end-frequency of 1 Hz. + * + * The implementer also has the option to set other end-frequencies. + * \ref asfdoc_sam0_rtc_count_rtc_out_freq "The table below" lists the + * available RTC frequencies for each possible GCLK and RTC input prescaler + * options. + * + * \anchor asfdoc_sam0_rtc_count_rtc_out_freq + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
RTC output frequencies from allowable input clocks
End-frequencyGCLK prescalerRTC Prescaler
32 KHz11
1 KHz321
1 Hz321024
+ * + * The overall RTC module clocking scheme is shown in + * \ref asfdoc_sam0_rtc_count_rtc_clock_fig "the figure below". + * + * \anchor asfdoc_sam0_rtc_count_rtc_clock_fig + * \dot + * digraph clocking_scheme { + * rankdir=LR; + * GCLK [shape="record", label=" GCLK | RTC_GCLK", + * bgcolor="lightgray", style="filled"]; + * RTCPRE [shape="record" label=" RTC | RTC PRESCALER"]; + * RTC [shape="record", label=" RTC | RTC CLOCK"]; + * + * GCLK:f1 -> RTCPRE:f1; + * RTCPRE:f1 -> RTC:f1; + * } + * \enddot + * + * + * \section asfdoc_sam0_rtc_count_extra_info Extra Information + * + * For extra information see \ref asfdoc_sam0_rtc_count_extra. This includes: + * - \ref asfdoc_sam0_rtc_count_extra_acronyms + * - \ref asfdoc_sam0_rtc_count_extra_dependencies + * - \ref asfdoc_sam0_rtc_count_extra_errata + * - \ref asfdoc_sam0_rtc_count_extra_history + * + * + * \section asfdoc_sam0_rtc_count_examples Examples + * + * For a list of examples related to this driver, see + * \ref asfdoc_sam0_rtc_count_exqsg. + * + * + * \section asfdoc_sam0_rtc_count_api_overview API Overview + * @{ + */ + +#include +#include + +#if RTC_COUNT_ASYNC == true +# include +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \brief Available operation modes for the RTC. + * + * RTC Count operating modes, to select the counting width and associated module + * operation. + */ +enum rtc_count_mode { + /** RTC Count module operates in 16-bit mode. */ + RTC_COUNT_MODE_16BIT = 0, + /** RTC Count module operates in 32-bit mode. */ + RTC_COUNT_MODE_32BIT = 1, +}; + +/** + * \brief Available compare channels. + * + * \note Not all compare channels are available in all devices and modes. + */ +enum rtc_count_compare { + /** Compare channel 0. */ + RTC_COUNT_COMPARE_0 = 0, +#if (RTC_NUM_OF_COMP16 > 1) || defined(__DOXYGEN__) + /** Compare channel 1. */ + RTC_COUNT_COMPARE_1 = 1, +#endif +#if (RTC_NUM_OF_COMP16 > 2) || defined(__DOXYGEN__) + /** Compare channel 2. */ + RTC_COUNT_COMPARE_2 = 2, +#endif +#if (RTC_NUM_OF_COMP16 > 3) || defined(__DOXYGEN__) + /** Compare channel 3. */ + RTC_COUNT_COMPARE_3 = 3, +#endif +#if (RTC_NUM_OF_COMP16 > 4) || defined(__DOXYGEN__) + /** Compare channel 4. */ + RTC_COUNT_COMPARE_4 = 4, +#endif +#if (RTC_NUM_OF_COMP16 > 5) || defined(__DOXYGEN__) + /** Compare channel 5. */ + RTC_COUNT_COMPARE_5 = 5, +#endif +}; + +#if RTC_COUNT_ASYNC == true +/** + * \brief Callback types + * + * The available callback types for the RTC count module. + */ +enum rtc_count_callback { + /** Callback for compare channel 0 */ + RTC_COUNT_CALLBACK_COMPARE_0 = 0, +# if (RTC_NUM_OF_COMP16 > 1) || defined(__DOXYGEN__) + /** Callback for compare channel 1 */ + RTC_COUNT_CALLBACK_COMPARE_1, +# endif +# if (RTC_NUM_OF_COMP16 > 2) || defined(__DOXYGEN__) + /** Callback for compare channel 2 */ + RTC_COUNT_CALLBACK_COMPARE_2, +# endif +# if (RTC_NUM_OF_COMP16 > 3) || defined(__DOXYGEN__) + /** Callback for compare channel 3 */ + RTC_COUNT_CALLBACK_COMPARE_3, +# endif +# if (RTC_NUM_OF_COMP16 > 4) || defined(__DOXYGEN__) + /** Callback for compare channel 4 */ + RTC_COUNT_CALLBACK_COMPARE_4, +# endif +# if (RTC_NUM_OF_COMP16 > 5) || defined(__DOXYGEN__) + /** Callback for compare channel 5 */ + RTC_COUNT_CALLBACK_COMPARE_5, +# endif + /** Callback for overflow */ + RTC_COUNT_CALLBACK_OVERFLOW, +# if !defined(__DOXYGEN__) + /** Total number of callbacks */ + _RTC_COUNT_CALLBACK_N +# endif +}; + +# if !defined(__DOXYGEN__) +typedef void (*rtc_count_callback_t)(void); +# endif +#endif + +/** + * \brief RTC input clock prescaler settings + * + * The available input clock prescaler values for the RTC count module. + */ +enum rtc_count_prescaler { + /** RTC input clock frequency is prescaled by a factor of 1. */ + RTC_COUNT_PRESCALER_DIV_1 = RTC_MODE0_CTRL_PRESCALER_DIV1, + /** RTC input clock frequency is prescaled by a factor of 2. */ + RTC_COUNT_PRESCALER_DIV_2 = RTC_MODE0_CTRL_PRESCALER_DIV2, + /** RTC input clock frequency is prescaled by a factor of 4. */ + RTC_COUNT_PRESCALER_DIV_4 = RTC_MODE0_CTRL_PRESCALER_DIV4, + /** RTC input clock frequency is prescaled by a factor of 8. */ + RTC_COUNT_PRESCALER_DIV_8 = RTC_MODE0_CTRL_PRESCALER_DIV8, + /** RTC input clock frequency is prescaled by a factor of 16. */ + RTC_COUNT_PRESCALER_DIV_16 = RTC_MODE0_CTRL_PRESCALER_DIV16, + /** RTC input clock frequency is prescaled by a factor of 32. */ + RTC_COUNT_PRESCALER_DIV_32 = RTC_MODE0_CTRL_PRESCALER_DIV32, + /** RTC input clock frequency is prescaled by a factor of 64. */ + RTC_COUNT_PRESCALER_DIV_64 = RTC_MODE0_CTRL_PRESCALER_DIV64, + /** RTC input clock frequency is prescaled by a factor of 128. */ + RTC_COUNT_PRESCALER_DIV_128 = RTC_MODE0_CTRL_PRESCALER_DIV128, + /** RTC input clock frequency is prescaled by a factor of 256. */ + RTC_COUNT_PRESCALER_DIV_256 = RTC_MODE0_CTRL_PRESCALER_DIV256, + /** RTC input clock frequency is prescaled by a factor of 512. */ + RTC_COUNT_PRESCALER_DIV_512 = RTC_MODE0_CTRL_PRESCALER_DIV512, + /** RTC input clock frequency is prescaled by a factor of 1024. */ + RTC_COUNT_PRESCALER_DIV_1024 = RTC_MODE0_CTRL_PRESCALER_DIV1024, +}; + +/** + * \brief RTC Count event enable/disable structure. + * + * Event flags for the \ref rtc_count_enable_events() and + * \ref rtc_count_disable_events(). + */ +struct rtc_count_events { + /** Generate an output event on each overflow of the RTC count. */ + bool generate_event_on_overflow; + /** Generate an output event on a compare channel match against the RTC + * count. */ + bool generate_event_on_compare[RTC_NUM_OF_COMP16]; + /** Generate an output event periodically at a binary division of the RTC + * counter frequency (see + * \ref asfdoc_sam0_rtc_count_module_overview_periodic). + */ + bool generate_event_on_periodic[8]; +}; + +#if !defined(__DOXYGEN__) +/** + * \brief Device structure. + */ +struct rtc_module { + /** RTC hardware module */ + Rtc *hw; + /** Operation mode of count. */ + enum rtc_count_mode mode; + /** Set if counter value should be continuously updated. */ + bool continuously_update; +# if RTC_COUNT_ASYNC == true + /** Pointers to callback functions */ + volatile rtc_count_callback_t callbacks[_RTC_COUNT_CALLBACK_N]; + /** Mask for registered callbacks */ + volatile uint8_t registered_callback; + /** Mask for enabled callbacks */ + volatile uint8_t enabled_callback; +# endif +}; +#endif + +/** + * \brief RTC Count configuration structure + * + * Configuration structure for the RTC instance. This structure should + * be initialized using the \ref rtc_count_get_config_defaults() before any + * user configurations are set. + */ +struct rtc_count_config { + /** Input clock prescaler for the RTC module. */ + enum rtc_count_prescaler prescaler; + /** Select the operation mode of the RTC.*/ + enum rtc_count_mode mode; + /** If true, clears the counter value on compare match. Only available + * whilst running in 32-bit mode. */ + bool clear_on_match; + /** Continuously update the counter value so no synchronization is + * needed for reading. */ + bool continuously_update; + /** Array of Compare values. Not all Compare values are available in 32-bit + * mode. */ + uint32_t compare_values[RTC_NUM_OF_COMP16]; +}; + + +/** + * \name Configuration and initialization + * @{ + */ + +/** + * \brief Determines if the hardware module(s) are currently synchronizing to the bus. + * + * Checks to see if the underlying hardware peripheral module(s) are currently + * synchronizing across multiple clock domains to the hardware bus, This + * function can be used to delay further operations on a module until such time + * that it is ready, to prevent blocking delays for synchronization in the + * user application. + * + * \param[in] module RTC hardware module + * + * \return Synchronization status of the underlying hardware module(s). + * + * \retval true if the module has completed synchronization + * \retval false if the module synchronization is ongoing + */ +static inline bool rtc_count_is_syncing(struct rtc_module *const module) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + if (rtc_module->MODE0.STATUS.reg & RTC_STATUS_SYNCBUSY) { + return true; + } + + return false; +} + +/** + * \brief Gets the RTC default configurations. + * + * Initializes the configuration structure to default values. This + * function should be called at the start of any RTC initialization. + * + * The default configuration is as follows: + * - Input clock divided by a factor of 1024. + * - RTC in 32 bit mode. + * - Clear on compare match off. + * - Continuously sync count register off. + * - No event source on. + * - All compare values equal 0. + * + * \param[out] config Configuration structure to be initialized to default + * values. + */ +static inline void rtc_count_get_config_defaults( + struct rtc_count_config *const config) +{ + /* Sanity check argument */ + Assert(config); + + /* Set default into configuration structure */ + config->prescaler = RTC_COUNT_PRESCALER_DIV_1024; + config->mode = RTC_COUNT_MODE_32BIT; + config->clear_on_match = false; + config->continuously_update = false; + for (uint8_t i = 0; i < RTC_NUM_OF_COMP16; i++) { + config->compare_values[i] = 0; + } +} + +void rtc_count_reset(struct rtc_module *const module); + +/** + * \brief Enables the RTC module. + * + * Enables the RTC module once it has been configured, ready for use. Most + * module configuration parameters cannot be altered while the module is enabled. + * + * \param[in,out] module RTC hardware module + */ +static inline void rtc_count_enable(struct rtc_module *const module) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + +#if RTC_COUNT_ASYNC == true + system_interrupt_enable(SYSTEM_INTERRUPT_MODULE_RTC); +#endif + + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + + /* Enable RTC module. */ + rtc_module->MODE0.CTRL.reg |= RTC_MODE0_CTRL_ENABLE; +} + +/** + * \brief Disables the RTC module. + * + * Disables the RTC module. + * + * \param[in,out] module RTC hardware module + */ +static inline void rtc_count_disable(struct rtc_module *const module) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + +#if RTC_COUNT_ASYNC == true + system_interrupt_disable(SYSTEM_INTERRUPT_MODULE_RTC); +#endif + + while (rtc_count_is_syncing(module)) { + /* Wait for synchronization */ + } + + /* Disable RTC module. */ + rtc_module->MODE0.CTRL.reg &= ~RTC_MODE0_CTRL_ENABLE; +} + +#if (RTC_INST_NUM > 1) && !defined(__DOXYGEN__) +/** + * \internal Find the index of given RTC module instance. + * + * \param[in] RTC module instance pointer. + * + * \return Index of the given AC module instance. + */ +uint8_t _rtc_get_inst_index( + Rtc *const hw) +{ + /* List of available RTC modules. */ + static Rtc *const rtc_modules[RTC_INST_NUM] = RTC_INSTS; + + /* Find index for RTC instance. */ + for (uint32_t i = 0; i < RTC_INST_NUM; i++) { + if (hw == rtc_modules[i]) { + return i; + } + } + + /* Invalid data given. */ + Assert(false); + return 0; +} +#endif /* (RTC_INST_NUM > 1) && !defined(__DOXYGEN__) */ + +enum status_code rtc_count_init( + struct rtc_module *const module, + Rtc *const hw, + const struct rtc_count_config *const config); + +enum status_code rtc_count_frequency_correction( + struct rtc_module *const module, + const int8_t value); + +/** @} */ + +/** \name Count and compare value management + * @{ + */ +enum status_code rtc_count_set_count( + struct rtc_module *const module, + const uint32_t count_value); + +uint32_t rtc_count_get_count(struct rtc_module *const module); + +enum status_code rtc_count_set_compare( + struct rtc_module *const module, + const uint32_t comp_value, + const enum rtc_count_compare comp_index); + +enum status_code rtc_count_get_compare( + struct rtc_module *const module, + uint32_t *const comp_value, + const enum rtc_count_compare comp_index); + +enum status_code rtc_count_set_period( + struct rtc_module *const module, + uint16_t period_value); + +enum status_code rtc_count_get_period( + struct rtc_module *const module, + uint16_t *const period_value); + +/** @} */ + + +/** \name Status management + * @{ + */ + +/** + * \brief Check if an RTC overflow has occurred. + * + * Checks the overflow flag in the RTC. The flag is set when there + * is an overflow in the clock. + * + * \param[in,out] module RTC hardware module + * + * \return Overflow state of the RTC module. + * + * \retval true If the RTC count value has overflowed + * \retval false If the RTC count value has not overflowed + */ + +static inline bool rtc_count_is_overflow(struct rtc_module *const module) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Return status of flag */ + return (rtc_module->MODE0.INTFLAG.reg & RTC_MODE0_INTFLAG_OVF); +} + +/** + * \brief Clears the RTC overflow flag. + * + * Clears the RTC module counter overflow flag, so that new overflow conditions + * can be detected. + * + * \param[in,out] module RTC hardware module + */ +static inline void rtc_count_clear_overflow(struct rtc_module *const module) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Clear OVF flag */ + rtc_module->MODE0.INTFLAG.reg = RTC_MODE0_INTFLAG_OVF; +} + +bool rtc_count_is_compare_match( + struct rtc_module *const module, + const enum rtc_count_compare comp_index); + +enum status_code rtc_count_clear_compare_match( + struct rtc_module *const module, + const enum rtc_count_compare comp_index); + +/** @} */ + + +/** + * \name Event management + * @{ + */ + +/** + * \brief Enables a RTC event output. + * + * Enables one or more output events from the RTC module. See + * \ref rtc_count_events for a list of events this module supports. + * + * \note Events cannot be altered while the module is enabled. + * + * \param[in,out] module RTC hardware module + * \param[in] events Struct containing flags of events to enable + */ +static inline void rtc_count_enable_events( + struct rtc_module *const module, + struct rtc_count_events *const events) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + uint32_t event_mask = 0; + + /* Check if the user has requested an overflow event. */ + if (events->generate_event_on_overflow) { + event_mask |= RTC_MODE0_EVCTRL_OVFEO; + } + + /* Check if the user has requested any compare events. */ + for (uint8_t i = 0; i < RTC_NUM_OF_COMP16; i++) { + if (events->generate_event_on_compare[i]) { + event_mask |= RTC_MODE0_EVCTRL_CMPEO(1 << i); + } + } + + /* Check if the user has requested any periodic events. */ + for (uint8_t i = 0; i < 8; i++) { + if (events->generate_event_on_periodic[i]) { + event_mask |= RTC_MODE0_EVCTRL_PEREO(1 << i); + } + } + + /* Enable given event(s). */ + rtc_module->MODE0.EVCTRL.reg |= event_mask; +} + +/** + * \brief Disables a RTC event output. + * + * Disabled one or more output events from the RTC module. See + * \ref rtc_count_events for a list of events this module supports. + * + * \note Events cannot be altered while the module is enabled. + * + * \param[in,out] module RTC hardware module + * \param[in] events Struct containing flags of events to disable + */ +static inline void rtc_count_disable_events( + struct rtc_module *const module, + struct rtc_count_events *const events) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + uint32_t event_mask = 0; + + /* Check if the user has requested an overflow event. */ + if (events->generate_event_on_overflow) { + event_mask |= RTC_MODE0_EVCTRL_OVFEO; + } + + /* Check if the user has requested any compare events. */ + for (uint8_t i = 0; i < RTC_NUM_OF_COMP16; i++) { + if (events->generate_event_on_compare[i]) { + event_mask |= RTC_MODE0_EVCTRL_CMPEO(1 << i); + } + } + + /* Check if the user has requested any periodic events. */ + for (uint8_t i = 0; i < 8; i++) { + if (events->generate_event_on_periodic[i]) { + event_mask |= RTC_MODE0_EVCTRL_PEREO(1 << i); + } + } + + /* Disable given event(s). */ + rtc_module->MODE0.EVCTRL.reg &= ~event_mask; +} + +/** @} */ + +/** @} */ + +#ifdef __cplusplus +} +#endif + +/** + * \page asfdoc_sam0_rtc_count_extra Extra Information for RTC COUNT Driver + * + * \section asfdoc_sam0_rtc_count_extra_acronyms Acronyms + * Below is a table listing the acronyms used in this module, along with their + * intended meanings. + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Acronym + * Description + *
RTCReal Time Counter
PPMPart Per Million
RCResistor/Capacitor
+ * + * + * \section asfdoc_sam0_rtc_count_extra_dependencies Dependencies + * This driver has the following dependencies: + * + * - None + * + * + * \section asfdoc_sam0_rtc_count_extra_errata Errata + * There are no errata related to this driver. + * + * + * \section asfdoc_sam0_rtc_count_extra_history Module History + * An overview of the module history is presented in the table below, with + * details on the enhancements and fixes made to the module since its first + * release. The current version of this corresponds to the newest version in + * the table. + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Changelog
+ * Added support for SAMD21 and added driver instance parameter to all + * API function calls, except get_config_defaults. + *
Updated initialization function to also enable the digital interface + * clock to the module if it is disabled.
Initial Release
+ */ + +/** + * \page asfdoc_sam0_rtc_count_exqsg Examples for RTC (COUNT) Driver + * + * This is a list of the available Quick Start guides (QSGs) and example + * applications for \ref asfdoc_sam0_rtc_count_group. QSGs are simple + * examples with step-by-step instructions to configure and use this driver in a + * selection of use cases. Note that QSGs can be compiled as a standalone + * application or be added to the user application. + * + * - \subpage asfdoc_sam0_rtc_count_basic_use_case + * \if RTC_COUNT_CALLBACK_MODE + * - \subpage asfdoc_sam0_rtc_count_callback_use_case + * \endif + * + * \page asfdoc_sam0_rtc_count_document_revision_history Document Revision History + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Doc. Rev. + * Date + * Comments + *
E05/2014Added support for SAMD10/D11.
D03/2014Added support for SAMR21.
C01/2014Added support for SAMD21.
B06/2013Added additional documentation on the event system. Corrected + * documentation typos.
A06/2013Initial release
+ */ + +#endif /* RTC_COUNT_H_INCLUDED */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/rtc/rtc_count_interrupt.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/rtc/rtc_count_interrupt.c new file mode 100755 index 0000000..8aebe7f --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/rtc/rtc_count_interrupt.c @@ -0,0 +1,317 @@ +/** + * \file + * + * \brief SAM RTC Driver (Count Interrupt Mode) + * + * Copyright (C) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include "rtc_count_interrupt.h" + +extern struct rtc_module *_rtc_instance[RTC_INST_NUM]; + +/** + * \brief Registers callback for the specified callback type + * + * Associates the given callback function with the + * specified callback type. + * To enable the callback, the \ref rtc_count_enable_callback function + * must be used. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] callback Pointer to the function desired for the specified + * callback + * \param[in] callback_type Callback type to register + * + * \return Status of registering callback + * \retval STATUS_OK Registering was done successfully + * \retval STATUS_ERR_INVALID_ARG If trying to register a callback not available + */ +enum status_code rtc_count_register_callback( + struct rtc_module *const module, + rtc_count_callback_t callback, + enum rtc_count_callback callback_type) +{ + + enum status_code status = STATUS_OK; + + /* Overflow callback */ + if (callback_type == RTC_COUNT_CALLBACK_OVERFLOW) { + status = STATUS_OK; + } else { + /* Make sure callback type can be registered */ + switch (module->mode) { + case RTC_COUNT_MODE_32BIT: + /* Check sanity for 32-bit mode. */ + if (callback_type > RTC_NUM_OF_COMP32) { + status = STATUS_ERR_INVALID_ARG; + } + + break; + case RTC_COUNT_MODE_16BIT: + /* Check sanity for 16-bit mode. */ + if (callback_type > RTC_NUM_OF_COMP16) { + status = STATUS_ERR_INVALID_ARG; + } + break; + default: + status = STATUS_ERR_INVALID_ARG; + } + } + + if (status == STATUS_OK) { + /* Register callback */ + module->callbacks[callback_type] = callback; + /* Set corresponding bit to set callback as registered */ + module->registered_callback |= (1 << callback_type); + } + + return status; +} + +/** + * \brief Unregisters callback for the specified callback type + * + * When called, the currently registered callback for the given callback type + * will be removed. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] callback_type Specifies the callback type to unregister + * + * \return Status of unregistering callback + * \retval STATUS_OK Unregistering was done successfully + * \retval STATUS_ERR_INVALID_ARG If trying to unregister a callback not available + */ +enum status_code rtc_count_unregister_callback( + struct rtc_module *const module, + enum rtc_count_callback callback_type) +{ + enum status_code status = STATUS_OK; + + /* Overflow callback */ + if (callback_type == RTC_COUNT_CALLBACK_OVERFLOW) { + status = STATUS_OK; + } else { + /* Make sure callback type can be unregistered */ + switch (module->mode) { + case RTC_COUNT_MODE_32BIT: + /* Check sanity for 32-bit mode. */ + if (callback_type > RTC_NUM_OF_COMP32) { + status = STATUS_ERR_INVALID_ARG; + } + break; + case RTC_COUNT_MODE_16BIT: + /* Check sanity for 16-bit mode. */ + if (callback_type > RTC_NUM_OF_COMP16) { + status = STATUS_ERR_INVALID_ARG; + } + break; + default: + status = STATUS_ERR_INVALID_ARG; + } + } + if (status == STATUS_OK) { + /* Unregister callback */ + module->callbacks[callback_type] = NULL; + + /* Clear corresponding bit to set callback as unregistered */ + module->registered_callback &= ~(1 << callback_type); + } + return status; +} + +/** + * \brief Enables callback + * + * Enables the callback specified by the callback_type. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] callback_type Callback type to enable + */ +void rtc_count_enable_callback( + struct rtc_module *const module, + enum rtc_count_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + if (callback_type == RTC_COUNT_CALLBACK_OVERFLOW) { + rtc_module->MODE0.INTENSET.reg = RTC_MODE0_INTFLAG_OVF; + } else { + rtc_module->MODE0.INTENSET.reg = RTC_MODE1_INTFLAG_CMP(1 << callback_type); + } + /* Mark callback as enabled. */ + module->enabled_callback |= (1 << callback_type); +} + +/** + * \brief Disables callback + * + * Disables the callback specified by the callback_type. + * + * \param[in,out] module Pointer to the software instance struct + * \param[in] callback_type Callback type to disable + */ +void rtc_count_disable_callback( + struct rtc_module *const module, + enum rtc_count_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + Rtc *const rtc_module = module->hw; + + /* Disable interrupt */ + if (callback_type == RTC_COUNT_CALLBACK_OVERFLOW) { + rtc_module->MODE0.INTENCLR.reg = RTC_MODE0_INTFLAG_OVF; + } else { + rtc_module->MODE0.INTENCLR.reg = RTC_MODE1_INTFLAG_CMP(1 << callback_type); + } + + /* Mark callback as disabled. */ + module->enabled_callback &= ~(1 << callback_type); +} + +/** + * \internal Interrupt handler for RTC + * + * \param [in] instance_index Default value 0 + */ +static void _rtc_interrupt_handler(const uint32_t instance_index) +{ + struct rtc_module *module = _rtc_instance[instance_index]; + + Rtc *const rtc_module = module->hw; + + /* Combine callback registered and enabled masks */ + uint8_t callback_mask = module->enabled_callback; + callback_mask &= module->registered_callback; + + /* Read and mask interrupt flag register */ + uint16_t interrupt_status = rtc_module->MODE0.INTFLAG.reg; + interrupt_status &= rtc_module->MODE0.INTENSET.reg; + + if (interrupt_status & RTC_MODE0_INTFLAG_OVF) { + /* Overflow interrupt */ + if (callback_mask & (1 << RTC_COUNT_CALLBACK_OVERFLOW)) { + module->callbacks[RTC_COUNT_CALLBACK_OVERFLOW](); + } + + /* Clear interrupt flag */ + rtc_module->MODE0.INTFLAG.reg = RTC_MODE0_INTFLAG_OVF; + + } else if (interrupt_status & RTC_MODE1_INTFLAG_CMP(1 << 0)) { + /* Compare 0 interrupt */ + if (callback_mask & (1 << RTC_COUNT_CALLBACK_COMPARE_0)) { + module->callbacks[RTC_COUNT_CALLBACK_COMPARE_0](); + } + /* Clear interrupt flag */ + rtc_module->MODE0.INTFLAG.reg = RTC_MODE1_INTFLAG_CMP(1 << 0); + + } else if (interrupt_status & RTC_MODE1_INTFLAG_CMP(1 << 1)) { + #if (RTC_NUM_OF_COMP16 > 1) || defined(__DOXYGEN__) + /* Compare 1 interrupt */ + if (callback_mask & (1 << RTC_COUNT_CALLBACK_COMPARE_1)) { + module->callbacks[RTC_COUNT_CALLBACK_COMPARE_1](); + } + /* Clear interrupt flag */ + rtc_module->MODE0.INTFLAG.reg = RTC_MODE1_INTFLAG_CMP(1 << 1); + #endif + + } else if (interrupt_status & RTC_MODE1_INTFLAG_CMP(1 << 2)) { + #if (RTC_NUM_OF_COMP16 > 2) || defined(__DOXYGEN__) + /* Compare 2 interrupt */ + if (callback_mask & (1 << RTC_COUNT_CALLBACK_COMPARE_2)) { + module->callbacks[RTC_COUNT_CALLBACK_COMPARE_2](); + } + /* Clear interrupt flag */ + rtc_module->MODE0.INTFLAG.reg = RTC_MODE1_INTFLAG_CMP(1 << 2); + #endif + + } else if (interrupt_status & RTC_MODE1_INTFLAG_CMP(1 << 3)) { + #if (RTC_NUM_OF_COMP16 > 3) || defined(__DOXYGEN__) + /* Compare 3 interrupt */ + if (callback_mask & (1 << RTC_COUNT_CALLBACK_COMPARE_3)) { + module->callbacks[RTC_COUNT_CALLBACK_COMPARE_3](); + } + /* Clear interrupt flag */ + rtc_module->MODE0.INTFLAG.reg = RTC_MODE1_INTFLAG_CMP(1 << 3); + #endif + + } else if (interrupt_status & RTC_MODE1_INTFLAG_CMP(1 << 4)) { + #if (RTC_NUM_OF_COMP16 > 4) || defined(__DOXYGEN__) + /* Compare 4 interrupt */ + if (callback_mask & (1 << RTC_COUNT_CALLBACK_COMPARE_4)) { + module->callbacks[RTC_COUNT_CALLBACK_COMPARE_4](); + } + /* Clear interrupt flag */ + rtc_module->MODE0.INTFLAG.reg = RTC_MODE1_INTFLAG_CMP(1 << 4); + #endif + + } else if (interrupt_status & RTC_MODE1_INTFLAG_CMP(1 << 5)) { + #if (RTC_NUM_OF_COMP16 > 5) || defined(__DOXYGEN__) + /* Compare 5 interrupt */ + if (callback_mask & (1 << RTC_COUNT_CALLBACK_COMPARE_5)) { + module->callbacks[RTC_COUNT_CALLBACK_COMPARE_5](); + } + /* Clear interrupt flag */ + rtc_module->MODE0.INTFLAG.reg = RTC_MODE1_INTFLAG_CMP(1 << 5); + #endif + } +} + +/** + * \internal ISR handler for RTC + */ +#if (RTC_INST_NUM == 1) +void RTC_Handler(void) +{ + _rtc_interrupt_handler(0); +} +#elif (RTC_INST_NUM > 1) +# define _RTC_INTERRUPT_HANDLER(n, unused) \ + void RTC##n##_Handler(void) \ + { \ + _rtc_interrupt_handler(n); \ + } + +MREPEAT(RTC_INST_NUM, _RTC_INTERRUPT_HANDLER, ~) +#endif /* (RTC_INST_NUM > 1) */ \ No newline at end of file diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/rtc/rtc_count_interrupt.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/rtc/rtc_count_interrupt.h new file mode 100755 index 0000000..f75c109 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/rtc/rtc_count_interrupt.h @@ -0,0 +1,87 @@ +/** + * \file + * + * \brief SAM RTC Driver (Count Interrupt Mode) + * + * Copyright (C) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef RTC_COUNT_INTERRUPT_H_INCLUDED +#define RTC_COUNT_INTERRUPT_H_INCLUDED + +#include "rtc_count.h" + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \addtogroup asfdoc_sam0_rtc_count_group + * @{ + */ + + /** + * \name Callbacks + * @{ + */ +enum status_code rtc_count_register_callback( + struct rtc_module *const module, + rtc_count_callback_t callback, + enum rtc_count_callback callback_type); + +enum status_code rtc_count_unregister_callback( + struct rtc_module *const module, + enum rtc_count_callback callback_type); + +void rtc_count_enable_callback( + struct rtc_module *const module, + enum rtc_count_callback callback_type); + +void rtc_count_disable_callback( + struct rtc_module *const module, + enum rtc_count_callback callback_type); + +/** @} */ + +/** @} */ + +#ifdef __cplusplus +} +#endif + +#endif /* RTC_COUNT_INTERRUPT_H_INCLUDED */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/sercom.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/sercom.c new file mode 100755 index 0000000..0d1b022 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/sercom.c @@ -0,0 +1,267 @@ +/** + * \file + * + * \brief SAM Serial Peripheral Interface Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include "sercom.h" + +#define SHIFT 32 +#define BAUD_INT_MAX 8192 +#define BAUD_FP_MAX 8 + +#if !defined(__DOXYGEN__) +/** + * \internal Configuration structure to save current gclk status. + */ +struct _sercom_conf { + /* Status of gclk generator initialization. */ + bool generator_is_set; + /* Sercom gclk generator used. */ + enum gclk_generator generator_source; +}; + +static struct _sercom_conf _sercom_config; + + +/** + * \internal Calculate 64 bit division, ref can be found in + * http://en.wikipedia.org/wiki/Division_algorithm#Long_division + */ +static uint64_t long_division(uint64_t n, uint64_t d) +{ + int32_t i; + uint64_t q = 0, r = 0, bit_shift; + for (i = 63; i >= 0; i--) { + bit_shift = (uint64_t)1 << i; + + r = r << 1; + + if (n & bit_shift) { + r |= 0x01; + } + + if (r >= d) { + r = r - d; + q |= bit_shift; + } + } + + return q; +} + +/** + * \internal Calculate synchronous baudrate value (SPI/UART) + */ +enum status_code _sercom_get_sync_baud_val( + const uint32_t baudrate, + const uint32_t external_clock, + uint16_t *const baudvalue) +{ + /* Baud value variable */ + uint16_t baud_calculated = 0; + uint32_t clock_value = external_clock; + + + /* Check if baudrate is outside of valid range. */ + if (baudrate > (external_clock / 2)) { + /* Return with error code */ + return STATUS_ERR_BAUDRATE_UNAVAILABLE; + } + + /* Calculate BAUD value from clock frequency and baudrate */ + clock_value = external_clock / 2; + while (clock_value >= baudrate) { + clock_value = clock_value - baudrate; + baud_calculated++; + } + baud_calculated = baud_calculated - 1; + + /* Check if BAUD value is more than 255, which is maximum + * for synchronous mode */ + if (baud_calculated > 0xFF) { + /* Return with an error code */ + return STATUS_ERR_BAUDRATE_UNAVAILABLE; + } else { + *baudvalue = baud_calculated; + return STATUS_OK; + } +} + +/** + * \internal Calculate asynchronous baudrate value (UART) +*/ +enum status_code _sercom_get_async_baud_val( + const uint32_t baudrate, + const uint32_t peripheral_clock, + uint16_t *const baudval, + enum sercom_asynchronous_operation_mode mode, + enum sercom_asynchronous_sample_num sample_num) +{ + /* Temporary variables */ + uint64_t ratio = 0; + uint64_t scale = 0; + uint64_t baud_calculated = 0; + uint8_t baud_fp; + uint32_t baud_int = 0; + uint64_t temp1, temp2; + + /* Check if the baudrate is outside of valid range */ + if ((baudrate * sample_num) > peripheral_clock) { + /* Return with error code */ + return STATUS_ERR_BAUDRATE_UNAVAILABLE; + } + + if(mode == SERCOM_ASYNC_OPERATION_MODE_ARITHMETIC) { + /* Calculate the BAUD value */ + temp1 = ((sample_num * (uint64_t)baudrate) << SHIFT); + ratio = long_division(temp1, peripheral_clock); + scale = ((uint64_t)1 << SHIFT) - ratio; + baud_calculated = (65536 * scale) >> SHIFT; + } else if(mode == SERCOM_ASYNC_OPERATION_MODE_FRACTIONAL) { + for(baud_fp = 0; baud_fp < BAUD_FP_MAX; baud_fp++) { + temp1 = BAUD_FP_MAX * (uint64_t)peripheral_clock; + temp2 = ((uint64_t)baudrate * sample_num); + baud_int = long_division(temp1, temp2); + baud_int -= baud_fp; + baud_int = baud_int / BAUD_FP_MAX; + if(baud_int < BAUD_INT_MAX) { + break; + } + } + if(baud_fp == BAUD_FP_MAX) { + return STATUS_ERR_BAUDRATE_UNAVAILABLE; + } + baud_calculated = baud_int | (baud_fp << 13); + } + + *baudval = baud_calculated; + return STATUS_OK; +} +#endif + +/** + * \brief Set GCLK channel to generator. + * + * This will set the appropriate GCLK channel to the requested GCLK generator. + * This will set the generator for all SERCOM instances, and the user will thus + * only be able to set the same generator that has previously been set, if any. + * + * After the generator has been set the first time, the generator can be changed + * using the \c force_change flag. + * + * \param[in] generator_source The generator to use for SERCOM. + * \param[in] force_change Force change the generator. + * + * \return Status code indicating the GCLK generator change operation. + * \retval STATUS_OK If the generator update request was + * successful. + * \retval STATUS_ERR_ALREADY_INITIALIZED If a generator was already configured + * and the new configuration was not + * forced. + */ +enum status_code sercom_set_gclk_generator( + const enum gclk_generator generator_source, + const bool force_change) +{ + /* Check if valid option. */ + if (!_sercom_config.generator_is_set || force_change) { + /* Create and fill a GCLK configuration structure for the new config. */ + struct system_gclk_chan_config gclk_chan_conf; + system_gclk_chan_get_config_defaults(&gclk_chan_conf); + gclk_chan_conf.source_generator = generator_source; + system_gclk_chan_set_config(SERCOM_GCLK_ID, &gclk_chan_conf); + system_gclk_chan_enable(SERCOM_GCLK_ID); + + /* Save config. */ + _sercom_config.generator_source = generator_source; + _sercom_config.generator_is_set = true; + + return STATUS_OK; + } else if (generator_source == _sercom_config.generator_source) { + /* Return status OK if same config. */ + return STATUS_OK; + } + + /* Return invalid config to already initialized GCLK. */ + return STATUS_ERR_ALREADY_INITIALIZED; +} + +/** \internal + * Creates a switch statement case entry to convert a SERCOM instance and pad + * index to the default SERCOM pad MUX setting. + */ +#define _SERCOM_PAD_DEFAULTS_CASE(n, pad) \ + case (uintptr_t)SERCOM##n: \ + switch (pad) { \ + case 0: \ + return SERCOM##n##_PAD0_DEFAULT; \ + case 1: \ + return SERCOM##n##_PAD1_DEFAULT; \ + case 2: \ + return SERCOM##n##_PAD2_DEFAULT; \ + case 3: \ + return SERCOM##n##_PAD3_DEFAULT; \ + } \ + break; + +/** + * \internal Gets the default PAD pinout for a given SERCOM. + * + * Returns the PINMUX settings for the given SERCOM and pad. This is used + * for default configuration of pins. + * + * \param[in] sercom_module Pointer to the SERCOM module + * \param[in] pad PAD to get default pinout for + * + * \returns The default PINMUX for the given SERCOM instance and PAD + * + */ +uint32_t _sercom_get_default_pad( + Sercom *const sercom_module, + const uint8_t pad) +{ + switch ((uintptr_t)sercom_module) { + /* Auto-generate a lookup table for the default SERCOM pad defaults */ + MREPEAT(SERCOM_INST_NUM, _SERCOM_PAD_DEFAULTS_CASE, pad) + } + + Assert(false); + return 0; +} diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/sercom.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/sercom.h new file mode 100755 index 0000000..0d15665 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/sercom.h @@ -0,0 +1,131 @@ +/** + * \file + * + * \brief SAM Serial Peripheral Interface Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef SERCOM_H_INCLUDED +#define SERCOM_H_INCLUDED + +#include +#include +#include +#include "sercom_interrupt.h" +#include "sercom_pinout.h" + +#ifdef __cplusplus +extern "C" { +#endif + +#if (SAMD10) || (SAMD11) + +#if (SERCOM0_GCLK_ID_SLOW == SERCOM1_GCLK_ID_SLOW && \ + SERCOM0_GCLK_ID_SLOW == SERCOM2_GCLK_ID_SLOW) +# define SERCOM_GCLK_ID SERCOM0_GCLK_ID_SLOW +#else +# error "SERCOM modules must share the same slow GCLK channel ID." +#endif + +#else + +#if (SERCOM0_GCLK_ID_SLOW == SERCOM1_GCLK_ID_SLOW && \ + SERCOM0_GCLK_ID_SLOW == SERCOM2_GCLK_ID_SLOW && \ + SERCOM0_GCLK_ID_SLOW == SERCOM3_GCLK_ID_SLOW) +# define SERCOM_GCLK_ID SERCOM0_GCLK_ID_SLOW +#else +# error "SERCOM modules must share the same slow GCLK channel ID." +#endif + +#endif + +#if (0x1ff >= REV_SERCOM) +# define FEATURE_SERCOM_SYNCBUSY_SCHEME_VERSION_1 +#elif (0x2ff >= REV_SERCOM) +# define FEATURE_SERCOM_SYNCBUSY_SCHEME_VERSION_2 +#else +# error "Unknown SYNCBUSY scheme for this SERCOM revision" +#endif + +/** + * \brief sercom asynchronous operation mode + * + * Select sercom asynchronous operation mode + */ +enum sercom_asynchronous_operation_mode { + SERCOM_ASYNC_OPERATION_MODE_ARITHMETIC = 0, + SERCOM_ASYNC_OPERATION_MODE_FRACTIONAL, +}; + +/** + * \brief sercom asynchronous samples per bit + * + * Select number of samples per bit + */ +enum sercom_asynchronous_sample_num { + SERCOM_ASYNC_SAMPLE_NUM_3 = 3, + SERCOM_ASYNC_SAMPLE_NUM_8 = 8, + SERCOM_ASYNC_SAMPLE_NUM_16 = 16, +}; + +enum status_code sercom_set_gclk_generator( + const enum gclk_generator generator_source, + const bool force_change); + +enum status_code _sercom_get_sync_baud_val( + const uint32_t baudrate, + const uint32_t external_clock, + uint16_t *const baudval); + +enum status_code _sercom_get_async_baud_val( + const uint32_t baudrate, + const uint32_t peripheral_clock, + uint16_t *const baudval, + enum sercom_asynchronous_operation_mode mode, + enum sercom_asynchronous_sample_num sample_num); + +uint32_t _sercom_get_default_pad( + Sercom *const sercom_module, + const uint8_t pad); + +#ifdef __cplusplus +} +#endif + +#endif //__SERCOM_H_INCLUDED diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/sercom_interrupt.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/sercom_interrupt.c new file mode 100755 index 0000000..05da258 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/sercom_interrupt.c @@ -0,0 +1,164 @@ +/** + * \file + * + * \brief SAM Serial Peripheral Interface Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include "sercom_interrupt.h" + +void *_sercom_instances[SERCOM_INST_NUM]; + +/** Save status of initialized handlers. */ +static bool _handler_table_initialized = false; + +/** Void pointers for saving device instance structures. */ +static void (*_sercom_interrupt_handlers[SERCOM_INST_NUM])(const uint8_t instance); + +/** + * \internal + * Default interrupt handler. + * + * \param[in] instance SERCOM instance used. + */ +static void _sercom_default_handler( + const uint8_t instance) +{ + Assert(false); +} + +/** + * \internal + * Find index of given instance. + * + * \param[in] sercom_instance Instance pointer. + * + * \return Index of given instance. + */ +uint8_t _sercom_get_sercom_inst_index( + Sercom *const sercom_instance) +{ + /* Save all available SERCOM instances for compare. */ + Sercom *sercom_instances[SERCOM_INST_NUM] = SERCOM_INSTS; + + /* Find index for sercom instance. */ + for (uint32_t i = 0; i < SERCOM_INST_NUM; i++) { + if ((uintptr_t)sercom_instance == (uintptr_t)sercom_instances[i]) { + return i; + } + } + + /* Invalid data given. */ + Assert(false); + return 0; +} + +/** + * \internal + * Saves the given callback handler. + * + * \param[in] instance Instance index. + * \param[in] interrupt_handler Pointer to instance callback handler. + */ +void _sercom_set_handler( + const uint8_t instance, + const sercom_handler_t interrupt_handler) +{ + /* Initialize handlers with default handler and device instances with 0. */ + if (_handler_table_initialized == false) { + for (uint32_t i = 0; i < SERCOM_INST_NUM; i++) { + _sercom_interrupt_handlers[i] = &_sercom_default_handler; + _sercom_instances[i] = NULL; + } + + _handler_table_initialized = true; + } + + /* Save interrupt handler. */ + _sercom_interrupt_handlers[instance] = interrupt_handler; +} + + +/** \internal + * Converts a given SERCOM index to its interrupt vector index. + */ +#define _SERCOM_INTERRUPT_VECT_NUM(n, unused) \ + SYSTEM_INTERRUPT_MODULE_SERCOM##n, + +/** \internal + * Generates a SERCOM interrupt handler function for a given SERCOM index. + */ +#define _SERCOM_INTERRUPT_HANDLER(n, unused) \ + void SERCOM##n##_Handler(void) \ + { \ + _sercom_interrupt_handlers[n](n); \ + } + +/** + * \internal + * Returns the system interrupt vector. + * + * \param[in] sercom_instance Instance pointer + * + * \return Enum of system interrupt vector + * \retval SYSTEM_INTERRUPT_MODULE_SERCOM0 + * \retval SYSTEM_INTERRUPT_MODULE_SERCOM1 + * \retval SYSTEM_INTERRUPT_MODULE_SERCOM2 + * \retval SYSTEM_INTERRUPT_MODULE_SERCOM3 + * \retval SYSTEM_INTERRUPT_MODULE_SERCOM4 + * \retval SYSTEM_INTERRUPT_MODULE_SERCOM5 + * \retval SYSTEM_INTERRUPT_MODULE_SERCOM6 + * \retval SYSTEM_INTERRUPT_MODULE_SERCOM7 + */ +enum system_interrupt_vector _sercom_get_interrupt_vector( + Sercom *const sercom_instance) +{ + const uint8_t sercom_int_vectors[SERCOM_INST_NUM] = + { + MREPEAT(SERCOM_INST_NUM, _SERCOM_INTERRUPT_VECT_NUM, ~) + }; + + /* Retrieve the index of the SERCOM being requested */ + uint8_t instance_index = _sercom_get_sercom_inst_index(sercom_instance); + + /* Get the vector number from the lookup table for the requested SERCOM */ + return (enum system_interrupt_vector)sercom_int_vectors[instance_index]; +} + +/** Auto-generate a set of interrupt handlers for each SERCOM in the device */ +MREPEAT(SERCOM_INST_NUM, _SERCOM_INTERRUPT_HANDLER, ~) diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/sercom_interrupt.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/sercom_interrupt.h new file mode 100755 index 0000000..b9ae998 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/sercom_interrupt.h @@ -0,0 +1,72 @@ +/** + * \file + * + * \brief SAM Serial Peripheral Interface Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef SERCOM_INTERRUPT_H_INCLUDED +#define SERCOM_INTERRUPT_H_INCLUDED + +#include "sercom.h" +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/* Look-up table for device instances. */ +extern void *_sercom_instances[SERCOM_INST_NUM]; + +typedef void (*sercom_handler_t)(uint8_t instance); + +uint8_t _sercom_get_sercom_inst_index( + Sercom *const sercom_instance); + +enum system_interrupt_vector _sercom_get_interrupt_vector( + Sercom *const sercom_instance); + +void _sercom_set_handler( + const uint8_t instance, + const sercom_handler_t interrupt_handler); + +#ifdef __cplusplus +} +#endif + +#endif /* SERCOM_INTERRUPT_H_INCLUDED */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/sercom_pinout.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/sercom_pinout.h new file mode 100755 index 0000000..61d265b --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/sercom_pinout.h @@ -0,0 +1,104 @@ +/** + * \file + * + * \brief SAM SERCOM Module Pinout Definitions + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef SERCOM_PINOUT_H_INCLUDED +#define SERCOM_PINOUT_H_INCLUDED + +#include "sercom.h" + +#if (SAMD10) || (SAMD11) +/* SERCOM0 */ +#define SERCOM0_PAD0_DEFAULT PINMUX_PA04D_SERCOM0_PAD0 +#define SERCOM0_PAD1_DEFAULT PINMUX_PA05D_SERCOM0_PAD1 +#define SERCOM0_PAD2_DEFAULT PINMUX_PA06D_SERCOM0_PAD2 +#define SERCOM0_PAD3_DEFAULT PINMUX_PA07D_SERCOM0_PAD3 + +/* SERCOM1 */ +#define SERCOM1_PAD0_DEFAULT PINMUX_PA22C_SERCOM1_PAD0 +#define SERCOM1_PAD1_DEFAULT PINMUX_PA23C_SERCOM1_PAD1 +#define SERCOM1_PAD2_DEFAULT PINMUX_PA30D_SERCOM1_PAD2 +#define SERCOM1_PAD3_DEFAULT PINMUX_PA31D_SERCOM1_PAD3 + +/* SERCOM2 */ +#define SERCOM2_PAD0_DEFAULT PINMUX_PA22D_SERCOM2_PAD0 +#define SERCOM2_PAD1_DEFAULT PINMUX_PA23D_SERCOM2_PAD1 +#define SERCOM2_PAD2_DEFAULT PINMUX_PA16D_SERCOM2_PAD2 +#define SERCOM2_PAD3_DEFAULT PINMUX_PA25D_SERCOM2_PAD3 +#else +/* SERCOM0 */ +#define SERCOM0_PAD0_DEFAULT PINMUX_PA04D_SERCOM0_PAD0 +#define SERCOM0_PAD1_DEFAULT PINMUX_PA05D_SERCOM0_PAD1 +#define SERCOM0_PAD2_DEFAULT PINMUX_PA06D_SERCOM0_PAD2 +#define SERCOM0_PAD3_DEFAULT PINMUX_PA07D_SERCOM0_PAD3 + +/* SERCOM1 */ +#define SERCOM1_PAD0_DEFAULT PINMUX_PA00D_SERCOM1_PAD0 +#define SERCOM1_PAD1_DEFAULT PINMUX_PA01D_SERCOM1_PAD1 +#define SERCOM1_PAD2_DEFAULT PINMUX_PA30D_SERCOM1_PAD2 +#define SERCOM1_PAD3_DEFAULT PINMUX_PA31D_SERCOM1_PAD3 + +/* SERCOM2 */ +#define SERCOM2_PAD0_DEFAULT PINMUX_PA08D_SERCOM2_PAD0 +#define SERCOM2_PAD1_DEFAULT PINMUX_PA09D_SERCOM2_PAD1 +#define SERCOM2_PAD2_DEFAULT PINMUX_PA10D_SERCOM2_PAD2 +#define SERCOM2_PAD3_DEFAULT PINMUX_PA11D_SERCOM2_PAD3 + +/* SERCOM3 */ +#define SERCOM3_PAD0_DEFAULT PINMUX_PA16D_SERCOM3_PAD0 +#define SERCOM3_PAD1_DEFAULT PINMUX_PA17D_SERCOM3_PAD1 +#define SERCOM3_PAD2_DEFAULT PINMUX_PA18D_SERCOM3_PAD2 +#define SERCOM3_PAD3_DEFAULT PINMUX_PA19D_SERCOM3_PAD3 + +/* SERCOM4 */ +#define SERCOM4_PAD0_DEFAULT PINMUX_PA12D_SERCOM4_PAD0 +#define SERCOM4_PAD1_DEFAULT PINMUX_PA13D_SERCOM4_PAD1 +#define SERCOM4_PAD2_DEFAULT PINMUX_PA14D_SERCOM4_PAD2 +#define SERCOM4_PAD3_DEFAULT PINMUX_PA15D_SERCOM4_PAD3 + +/* SERCOM5 */ +#define SERCOM5_PAD0_DEFAULT PINMUX_PA22D_SERCOM5_PAD0 +#define SERCOM5_PAD1_DEFAULT PINMUX_PA23D_SERCOM5_PAD1 +#define SERCOM5_PAD2_DEFAULT PINMUX_PA24D_SERCOM5_PAD2 +#define SERCOM5_PAD3_DEFAULT PINMUX_PA25D_SERCOM5_PAD3 +#endif + +#endif /* SERCOM_PINOUT_H_INCLUDED */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/usart/quick_start/qs_usart_basic_use.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/usart/quick_start/qs_usart_basic_use.h new file mode 100755 index 0000000..9627a3e --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/usart/quick_start/qs_usart_basic_use.h @@ -0,0 +1,113 @@ +/** + * \file + * + * \brief SAM USART Quick Start + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +/** + * \page asfdoc_sam0_sercom_usart_basic_use_case Quick Start Guide for SERCOM USART - Basic + * + * This quick start will echo back characters typed into the terminal. In this + * use case the USART will be configured with the following settings: + * - Asynchronous mode + * - 9600 Baudrate + * - 8-bits, No Parity and 1 Stop Bit + * - TX and RX enabled and connected to the Xplained Pro Embedded Debugger virtual COM port + * + * \section asfdoc_sam0_sercom_usart_basic_use_case_setup Setup + * + * \subsection asfdoc_sam0_sercom_usart_basic_use_case_prereq Prerequisites + * There are no special setup requirements for this use-case. + * + * \subsection asfdoc_sam0_usart_basic_use_case_setup_code Code + * Add to the main application source file, outside of any functions: + * \snippet qs_usart_basic_use.c module_inst + * + * Copy-paste the following setup code to your user application: + * \snippet qs_usart_basic_use.c setup + * + * Add to user application initialization (typically the start of \c main()): + * \snippet qs_usart_basic_use.c setup_init + * + * \subsection asfdoc_sam0_usart_basic_use_case_setup_flow Workflow + * -# Create a module software instance structure for the USART module to store + * the USART driver state while it is in use. + * \snippet qs_usart_basic_use.c module_inst + * \note This should never go out of scope as long as the module is in use. + * In most cases, this should be global. + * + * -# Configure the USART module. + * -# Create a USART module configuration struct, which can be filled out to + * adjust the configuration of a physical USART peripheral. + * \snippet qs_usart_basic_use.c setup_config + * -# Initialize the USART configuration struct with the module's default values. + * \snippet qs_usart_basic_use.c setup_config_defaults + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Alter the USART settings to configure the physical pinout, baud rate and + * other relevant parameters. + * \snippet qs_usart_basic_use.c setup_change_config + * -# Configure the USART module with the desired settings, retrying while the + * driver is busy until the configuration is stressfully set. + * \snippet qs_usart_basic_use.c setup_set_config + * -# Enable the USART module. + * \snippet qs_usart_basic_use.c setup_enable + * + * + * \section asfdoc_sam0_usart_basic_use_case_main Use Case + * + * \subsection asfdoc_sam0_usart_basic_use_case_main_code Code + * Copy-paste the following code to your user application: + * \snippet qs_usart_basic_use.c main + * + * \subsection asfdoc_sam0_usart_basic_use_case_main_flow Workflow + * -# Send a string to the USART to show the demo is running, blocking until + * all characters have been sent. + * \snippet qs_usart_basic_use.c main_send_string + * -# Enter an infinite loop to continuously echo received values on the USART. + * \snippet qs_usart_basic_use.c main_loop + * -# Perform a blocking read of the USART, storing the received character into + * the previously declared temporary variable. + * \snippet qs_usart_basic_use.c main_read + * -# Echo the received variable back to the USART via a blocking write. + * \snippet qs_usart_basic_use.c main_write + */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/usart/quick_start_dma/qs_usart_dma_use.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/usart/quick_start_dma/qs_usart_dma_use.h new file mode 100755 index 0000000..eeffcd4 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/usart/quick_start_dma/qs_usart_dma_use.h @@ -0,0 +1,210 @@ +/** + * \file + * + * \brief SAM D21/R21/D10/D11 Quick Start Guide for Using Usart driver with DMA + * + * Copyright (C) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +/** + * \page asfdoc_sam0_sercom_usart_dma_use_case Quick Start Guide for Using DMA with SERCOM USART + * + * The supported board list: + * - SAMD21 Xplained Pro + * - SAMR21 Xplained Pro + * - SAMR11 Xplained Pro + * + * This quick start will receiving 8 bytes of data from PC terminal and transmit back the string + * to the terminal through DMA. In this use case the USART will be configured with the following + * settings: + * - Asynchronous mode + * - 9600 Baudrate + * - 8-bits, No Parity and 1 Stop Bit + * - TX and RX enabled and connected to the Xplained Pro Embedded Debugger virtual COM port + * + * \section asfdoc_sam0_sercom_usart_dma_use_case_setup Setup + * + * \subsection asfdoc_sam0_sercom_usart_dma_use_case_prereq Prerequisites + * There are no special setup requirements for this use-case. + * + * \subsection asfdoc_sam0_usart_dma_use_case_setup_code Code + * Add to the main application source file, outside of any functions: + * \snippet qs_usart_dma_use.c module_inst + * \snippet qs_usart_dma_use.c dma_resource + * \snippet qs_usart_dma_use.c usart_buffer + * \snippet qs_usart_dma_use.c transfer_descriptor + * + * Copy-paste the following setup code to your user application: + * \snippet qs_usart_dma_use.c setup + * + * Add to user application initialization (typically the start of \c main()): + * \snippet qs_usart_dma_use.c setup_init + * + * \subsection asfdoc_sam0_usart_dma_use_case_setup_flow Workflow + * + * \subsubsection asfdoc_sam0_usart_dma_use_case_setup_flow_inst Create variables + * -# Create a module software instance structure for the USART module to store + * the USART driver state while it is in use. + * \snippet qs_usart_dma_use.c module_inst + * \note This should never go out of scope as long as the module is in use. + * In most cases, this should be global. + * + * -# Create module software instance structures for DMA resources to store + * the DMA resource state while it is in use. + * \snippet qs_usart_dma_use.c dma_resource + * \note This should never go out of scope as long as the module is in use. + * In most cases, this should be global. + * + * -# Create a buffer to store the data to be transferred /received + * \snippet qs_usart_dma_use.c usart_buffer + * -# Create DMA transfer descriptors for RX/TX + * \snippet qs_usart_dma_use.c transfer_descriptor + * + * \subsubsection asfdoc_sam0_usart_dma_use_case_setup_flow_usart Configure the USART + * -# Create a USART module configuration struct, which can be filled out to + * adjust the configuration of a physical USART peripheral. + * \snippet qs_usart_dma_use.c setup_config + * -# Initialize the USART configuration struct with the module's default values. + * \snippet qs_usart_dma_use.c setup_config_defaults + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Alter the USART settings to configure the physical pinout, baud rate and + * other relevant parameters. + * \snippet qs_usart_dma_use.c setup_change_config + * -# Configure the USART module with the desired settings, retrying while the + * driver is busy until the configuration is stressfully set. + * \snippet qs_usart_dma_use.c setup_set_config + * -# Enable the USART module. + * \snippet qs_usart_dma_use.c setup_enable + * + * \subsubsection asfdoc_sam0_usart_dma_use_case_setup_flow_dma Configure DMA + * -# Create a callback function of receiver done + * \snippet qs_usart_dma_use.c transfer_done_rx + * + * -# Create a callback function of transmission done + * \snippet qs_usart_dma_use.c transfer_done_tx + * + * -# Create a DMA resource configuration structure, which can be filled out to + * adjust the configuration of a single DMA transfer. + * \snippet qs_usart_dma_use.c setup_rx_1 + * + * -# Initialize the DMA resource configuration struct with the module's + * default values. + * \snippet qs_usart_dma_use.c setup_rx_2 + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Set extra configurations for the DMA resource. It is using peripheral + * trigger, SERCOM Tx empty trigger and trigger causes a beat transfer in + * this example. + * \snippet qs_usart_dma_use.c setup_rx_3 + * + * -# Allocate a DMA resource with the configurations. + * \snippet qs_usart_dma_use.c setup_rx_4 + * + * -# Create a DMA transfer descriptor configuration structure, which can be + * filled out to adjust the configuration of a single DMA transfer. + * \snippet qs_usart_dma_use.c setup_rx_5 + * + * -# Initialize the DMA transfer descriptor configuration struct with the module's + * default values. + * \snippet qs_usart_dma_use.c setup_rx_6 + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Set the specific parameters for a DMA transfer with transfer size, source + * address, destination address. + * \snippet qs_usart_dma_use.c setup_rx_7 + * + * -# Create the DMA transfer descriptor. + * \snippet qs_usart_dma_use.c setup_rx_8 + * + * -# Create a DMA resource configuration structure for tx, which can be filled + * out to adjust the configuration of a single DMA transfer. + * \snippet qs_usart_dma_use.c setup_tx_1 + * + * -# Initialize the DMA resource configuration struct with the module's + * default values. + * \snippet qs_usart_dma_use.c setup_tx_2 + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Set extra configurations for the DMA resource. It is using peripheral + * trigger, SERCOM Rx Ready trigger and trigger causes a beat transfer in + * this example. + * \snippet qs_usart_dma_use.c setup_tx_3 + * + * -# Allocate a DMA resource with the configurations. + * \snippet qs_usart_dma_use.c setup_tx_4 + * + * -# Create a DMA transfer descriptor configuration structure, which can be + * filled out to adjust the configuration of a single DMA transfer. + * \snippet qs_usart_dma_use.c setup_tx_5 + * + * -# Initialize the DMA transfer descriptor configuration struct with the module's + * default values. + * \snippet qs_usart_dma_use.c setup_tx_6 + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Set the specific parameters for a DMA transfer with transfer size, source + * address, destination address. + * \snippet qs_usart_dma_use.c setup_tx_7 + * + * -# Create the DMA transfer descriptor. + * \snippet qs_usart_dma_use.c setup_tx_8 + * + * \section asfdoc_sam0_usart_dma_use_case_main Use Case + * + * \subsection asfdoc_sam0_usart_dma_use_case_main_code Code + * Copy-paste the following code to your user application: + * \snippet qs_usart_dma_use.c main + * + * \subsection asfdoc_sam0_usart_dma_use_case_main_flow Workflow + * -# Wait for receiving data. + * \snippet qs_usart_dma_use.c main_1 + * + * -# enter endless loop + * \snippet qs_usart_dma_use.c endless_loop + */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/usart/usart.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/usart/usart.c new file mode 100755 index 0000000..f93ae24 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/usart/usart.c @@ -0,0 +1,697 @@ +/** + * \file + * + * \brief SAM SERCOM USART Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include "usart.h" +#include +#if USART_CALLBACK_MODE == true +# include "usart_interrupt.h" +#endif + +/** + * \internal + * Set Configuration of the USART module + */ +static enum status_code _usart_set_config( + struct usart_module *const module, + const struct usart_config *const config) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + /* Get a pointer to the hardware module instance */ + SercomUsart *const usart_hw = &(module->hw->USART); + + /* Index for generic clock */ + uint32_t sercom_index = _sercom_get_sercom_inst_index(module->hw); + uint32_t gclk_index = sercom_index + SERCOM0_GCLK_ID_CORE; + + /* Cache new register values to minimize the number of register writes */ + uint32_t ctrla = 0; + uint32_t ctrlb = 0; + uint16_t baud = 0; + + enum sercom_asynchronous_operation_mode mode = SERCOM_ASYNC_OPERATION_MODE_ARITHMETIC; + enum sercom_asynchronous_sample_num sample_num = SERCOM_ASYNC_SAMPLE_NUM_16; + +#ifdef FEATURE_USART_OVER_SAMPLE + switch (config->sample_rate) { + case USART_SAMPLE_RATE_16X_ARITHMETIC: + mode = SERCOM_ASYNC_OPERATION_MODE_ARITHMETIC; + sample_num = SERCOM_ASYNC_SAMPLE_NUM_16; + break; + case USART_SAMPLE_RATE_8X_ARITHMETIC: + mode = SERCOM_ASYNC_OPERATION_MODE_ARITHMETIC; + sample_num = SERCOM_ASYNC_SAMPLE_NUM_8; + break; + case USART_SAMPLE_RATE_3X_ARITHMETIC: + mode = SERCOM_ASYNC_OPERATION_MODE_ARITHMETIC; + sample_num = SERCOM_ASYNC_SAMPLE_NUM_3; + break; + case USART_SAMPLE_RATE_16X_FRACTIONAL: + mode = SERCOM_ASYNC_OPERATION_MODE_FRACTIONAL; + sample_num = SERCOM_ASYNC_SAMPLE_NUM_16; + break; + case USART_SAMPLE_RATE_8X_FRACTIONAL: + mode = SERCOM_ASYNC_OPERATION_MODE_FRACTIONAL; + sample_num = SERCOM_ASYNC_SAMPLE_NUM_8; + break; + } +#endif + + /* Set data order, internal muxing, and clock polarity */ + ctrla = (uint32_t)config->data_order | + (uint32_t)config->mux_setting | + #ifdef FEATURE_USART_OVER_SAMPLE + config->sample_adjustment | + config->sample_rate | + #endif + #ifdef FEATURE_USART_IMMEDIATE_BUFFER_OVERFLOW_NOTIFICATION + (config->immediate_buffer_overflow_notification << SERCOM_USART_CTRLA_IBON_Pos) | + #endif + (config->clock_polarity_inverted << SERCOM_USART_CTRLA_CPOL_Pos); + + enum status_code status_code = STATUS_OK; + + /* Get baud value from mode and clock */ + switch (config->transfer_mode) + { + case USART_TRANSFER_SYNCHRONOUSLY: + if (!config->use_external_clock) { + status_code = _sercom_get_sync_baud_val(config->baudrate, + system_gclk_chan_get_hz(gclk_index), &baud); + } + + break; + + case USART_TRANSFER_ASYNCHRONOUSLY: + if (config->use_external_clock) { + status_code = + _sercom_get_async_baud_val(config->baudrate, + config->ext_clock_freq, &baud, mode, sample_num); + } else { + status_code = + _sercom_get_async_baud_val(config->baudrate, + system_gclk_chan_get_hz(gclk_index), &baud, mode, sample_num); + } + + break; + } + + /* Check if calculating the baud rate failed */ + if (status_code != STATUS_OK) { + /* Abort */ + return status_code; + } + +#ifdef FEATURE_USART_IRDA + if(config->encoding_format_enable) { + usart_hw->RXPL.reg = config->receive_pulse_length; + } +#endif + + /* Wait until synchronization is complete */ + _usart_wait_for_sync(module); + + /*Set baud val */ + usart_hw->BAUD.reg = baud; + + /* Set sample mode */ + ctrla |= config->transfer_mode; + + if (config->use_external_clock == false) { + ctrla |= SERCOM_USART_CTRLA_MODE_USART_INT_CLK; + } + else { + ctrla |= SERCOM_USART_CTRLA_MODE_USART_EXT_CLK; + } + + /* Set stopbits, character size and enable transceivers */ + ctrlb = (uint32_t)config->stopbits | (uint32_t)config->character_size | + #ifdef FEATURE_USART_IRDA + (config->encoding_format_enable << SERCOM_USART_CTRLB_ENC_Pos) | + #endif + #ifdef FEATURE_USART_START_FRAME_DECTION + (config->start_frame_detection_enable << SERCOM_USART_CTRLB_SFDE_Pos) | + #endif + #ifdef FEATURE_USART_COLLISION_DECTION + (config->collision_detection_enable << SERCOM_USART_CTRLB_COLDEN_Pos) | + #endif + (config->receiver_enable << SERCOM_USART_CTRLB_RXEN_Pos) | + (config->transmitter_enable << SERCOM_USART_CTRLB_TXEN_Pos); + + /* Check parity mode bits */ + if (config->parity != USART_PARITY_NONE) { +#ifdef FEATURE_USART_LIN_SLAVE + if(config->lin_slave_enable) { + ctrla |= SERCOM_USART_CTRLA_FORM(0x5); + } +#else + ctrla |= SERCOM_USART_CTRLA_FORM(1); +#endif + ctrlb |= config->parity; + } else { +#ifdef FEATURE_USART_LIN_SLAVE + if(config->lin_slave_enable) { + ctrla |= SERCOM_USART_CTRLA_FORM(0x4); + } +#else + ctrla |= SERCOM_USART_CTRLA_FORM(0); +#endif + } + + /* Set whether module should run in standby. */ + if (config->run_in_standby || system_is_debugger_present()) { + ctrla |= SERCOM_USART_CTRLA_RUNSTDBY; + } + + /* Wait until synchronization is complete */ + _usart_wait_for_sync(module); + + /* Write configuration to CTRLB */ + usart_hw->CTRLB.reg = ctrlb; + + /* Wait until synchronization is complete */ + _usart_wait_for_sync(module); + + /* Write configuration to CTRLA */ + usart_hw->CTRLA.reg = ctrla; + + return STATUS_OK; +} + +/** + * \brief Initializes the device + * + * Initializes the USART device based on the setting specified in the + * configuration struct. + * + * \param[out] module Pointer to USART device + * \param[in] hw Pointer to USART hardware instance + * \param[in] config Pointer to configuration struct + * + * \return Status of the initialization + * + * \retval STATUS_OK The initialization was successful + * \retval STATUS_BUSY The USART module is busy + * resetting + * \retval STATUS_ERR_DENIED The USART have not been disabled in + * advance of initialization + * \retval STATUS_ERR_INVALID_ARG The configuration struct contains + * invalid configuration + * \retval STATUS_ERR_ALREADY_INITIALIZED The SERCOM instance has already been + * initialized with different clock + * configuration + * \retval STATUS_ERR_BAUD_UNAVAILABLE The BAUD rate given by the + * configuration + * struct cannot be reached with + * the current clock configuration + */ +enum status_code usart_init( + struct usart_module *const module, + Sercom *const hw, + const struct usart_config *const config) +{ + /* Sanity check arguments */ + Assert(module); + Assert(hw); + Assert(config); + + enum status_code status_code = STATUS_OK; + + /* Assign module pointer to software instance struct */ + module->hw = hw; + + /* Get a pointer to the hardware module instance */ + SercomUsart *const usart_hw = &(module->hw->USART); + + uint32_t sercom_index = _sercom_get_sercom_inst_index(module->hw); + uint32_t pm_index = sercom_index + PM_APBCMASK_SERCOM0_Pos; + uint32_t gclk_index = sercom_index + SERCOM0_GCLK_ID_CORE; + + if (usart_hw->CTRLA.reg & SERCOM_USART_CTRLA_SWRST) { + /* The module is busy resetting itself */ + return STATUS_BUSY; + } + + if (usart_hw->CTRLA.reg & SERCOM_USART_CTRLA_ENABLE) { + /* Check the module is enabled */ + return STATUS_ERR_DENIED; + } + + /* Turn on module in PM */ + system_apb_clock_set_mask(SYSTEM_CLOCK_APB_APBC, 1 << pm_index); + + /* Set up the GCLK for the module */ + struct system_gclk_chan_config gclk_chan_conf; + system_gclk_chan_get_config_defaults(&gclk_chan_conf); + gclk_chan_conf.source_generator = config->generator_source; + system_gclk_chan_set_config(gclk_index, &gclk_chan_conf); + system_gclk_chan_enable(gclk_index); + sercom_set_gclk_generator(config->generator_source, false); + + /* Set character size */ + module->character_size = config->character_size; + + /* Set transmitter and receiver status */ + module->receiver_enabled = config->receiver_enable; + module->transmitter_enabled = config->transmitter_enable; + +#ifdef FEATURE_USART_LIN_SLAVE + module->lin_slave_enabled = config->lin_slave_enable; +#endif +#ifdef FEATURE_USART_START_FRAME_DECTION + module->start_frame_detection_enabled = config->start_frame_detection_enable; +#endif + /* Set configuration according to the config struct */ + status_code = _usart_set_config(module, config); + if(status_code != STATUS_OK) { + return status_code; + } + + struct system_pinmux_config pin_conf; + system_pinmux_get_config_defaults(&pin_conf); + pin_conf.direction = SYSTEM_PINMUX_PIN_DIR_INPUT; + pin_conf.input_pull = SYSTEM_PINMUX_PIN_PULL_NONE; + + uint32_t pad_pinmuxes[] = { + config->pinmux_pad0, config->pinmux_pad1, + config->pinmux_pad2, config->pinmux_pad3 + }; + + /* Configure the SERCOM pins according to the user configuration */ + for (uint8_t pad = 0; pad < 4; pad++) { + uint32_t current_pinmux = pad_pinmuxes[pad]; + + if (current_pinmux == PINMUX_DEFAULT) { + current_pinmux = _sercom_get_default_pad(hw, pad); + } + + if (current_pinmux != PINMUX_UNUSED) { + pin_conf.mux_position = current_pinmux & 0xFFFF; + system_pinmux_pin_set_config(current_pinmux >> 16, &pin_conf); + } + } + +#if USART_CALLBACK_MODE == true + /* Initialize parameters */ + for (uint32_t i = 0; i < USART_CALLBACK_N; i++) { + module->callback[i] = NULL; + } + + module->tx_buffer_ptr = NULL; + module->rx_buffer_ptr = NULL; + module->remaining_tx_buffer_length = 0x0000; + module->remaining_rx_buffer_length = 0x0000; + module->callback_reg_mask = 0x00; + module->callback_enable_mask = 0x00; + module->rx_status = STATUS_OK; + module->tx_status = STATUS_OK; + + /* Set interrupt handler and register USART software module struct in + * look-up table */ + uint8_t instance_index = _sercom_get_sercom_inst_index(module->hw); + _sercom_set_handler(instance_index, _usart_interrupt_handler); + _sercom_instances[instance_index] = module; +#endif + + return status_code; +} + +/** + * \brief Transmit a character via the USART + * + * This blocking function will transmit a single character via the + * USART. + * + * \param[in] module Pointer to the software instance struct + * \param[in] tx_data Data to transfer + * + * \return Status of the operation + * \retval STATUS_OK If the operation was completed + * \retval STATUS_BUSY If the operation was not completed, due to the USART + * module being busy. + * \retval STATUS_ERR_DENIED If the transmitter is not enabled + */ +enum status_code usart_write_wait( + struct usart_module *const module, + const uint16_t tx_data) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + /* Get a pointer to the hardware module instance */ + SercomUsart *const usart_hw = &(module->hw->USART); + + /* Check that the transmitter is enabled */ + if (!(module->transmitter_enabled)) { + return STATUS_ERR_DENIED; + } + +#if USART_CALLBACK_MODE == true + /* Check if the USART is busy doing asynchronous operation. */ + if (module->remaining_tx_buffer_length > 0) { + return STATUS_BUSY; + } + +#else + /* Check if USART is ready for new data */ + if (!(usart_hw->INTFLAG.reg & SERCOM_USART_INTFLAG_DRE)) { + /* Return error code */ + return STATUS_BUSY; + } +#endif + + /* Wait until synchronization is complete */ + _usart_wait_for_sync(module); + + /* Write data to USART module */ + usart_hw->DATA.reg = tx_data; + + while (!(usart_hw->INTFLAG.reg & SERCOM_USART_INTFLAG_TXC)) { + /* Wait until data is sent */ + } + + return STATUS_OK; +} + +/** + * \brief Receive a character via the USART + * + * This blocking function will receive a character via the USART. + * + * \param[in] module Pointer to the software instance struct + * \param[out] rx_data Pointer to received data + * + * \return Status of the operation + * \retval STATUS_OK If the operation was completed + * \retval STATUS_BUSY If the operation was not completed, + * due to the USART module being busy + * \retval STATUS_ERR_BAD_FORMAT If the operation was not completed, + * due to configuration mismatch between USART + * and the sender + * \retval STATUS_ERR_BAD_OVERFLOW If the operation was not completed, + * due to the baud rate being too low or the + * system frequency being too high + * \retval STATUS_ERR_BAD_DATA If the operation was not completed, due to + * data being corrupted + * \retval STATUS_ERR_DENIED If the receiver is not enabled + */ +enum status_code usart_read_wait( + struct usart_module *const module, + uint16_t *const rx_data) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + /* Error variable */ + uint8_t error_code; + + /* Get a pointer to the hardware module instance */ + SercomUsart *const usart_hw = &(module->hw->USART); + + /* Check that the receiver is enabled */ + if (!(module->receiver_enabled)) { + return STATUS_ERR_DENIED; + } + +#if USART_CALLBACK_MODE == true + /* Check if the USART is busy doing asynchronous operation. */ + if (module->remaining_rx_buffer_length > 0) { + return STATUS_BUSY; + } +#endif + + /* Check if USART has new data */ + if (!(usart_hw->INTFLAG.reg & SERCOM_USART_INTFLAG_RXC)) { + /* Return error code */ + return STATUS_BUSY; + } + + /* Wait until synchronization is complete */ + _usart_wait_for_sync(module); + + /* Read out the status code and mask away all but the 3 LSBs*/ + error_code = (uint8_t)(usart_hw->STATUS.reg & SERCOM_USART_STATUS_MASK); + + /* Check if an error has occurred during the receiving */ + if (error_code) { + /* Check which error occurred */ + if (error_code & SERCOM_USART_STATUS_FERR) { + /* Clear flag by writing a 1 to it and + * return with an error code */ + usart_hw->STATUS.reg = SERCOM_USART_STATUS_FERR; + + return STATUS_ERR_BAD_FORMAT; + } else if (error_code & SERCOM_USART_STATUS_BUFOVF) { + /* Clear flag by writing a 1 to it and + * return with an error code */ + usart_hw->STATUS.reg = SERCOM_USART_STATUS_BUFOVF; + + return STATUS_ERR_OVERFLOW; + } else if (error_code & SERCOM_USART_STATUS_PERR) { + /* Clear flag by writing a 1 to it and + * return with an error code */ + usart_hw->STATUS.reg = SERCOM_USART_STATUS_PERR; + + return STATUS_ERR_BAD_DATA; + } +#ifdef FEATURE_USART_LIN_SLAVE + else if (error_code & SERCOM_USART_STATUS_ISF) { + /* Clear flag by writing 1 to it and + * return with an error code */ + usart_hw->STATUS.reg |= SERCOM_USART_STATUS_ISF; + + return STATUS_ERR_PROTOCOL; + } +#endif +#ifdef FEATURE_USART_COLLISION_DECTION + else if (error_code & SERCOM_USART_STATUS_COLL) { + /* Clear flag by writing 1 to it + * return with an error code */ + usart_hw->STATUS.reg |= SERCOM_USART_STATUS_COLL; + + return STATUS_ERR_PACKET_COLLISION; + } +#endif + } + + /* Read data from USART module */ + *rx_data = usart_hw->DATA.reg; + + return STATUS_OK; +} + +/** + * \brief Transmit a buffer of characters via the USART + * + * This blocking function will transmit a block of \c length characters + * via the USART + * + * \note Using this function in combination with the interrupt (\c _job) functions is + * not recommended as it has no functionality to check if there is an + * ongoing interrupt driven operation running or not. + * + * \param[in] module Pointer to USART software instance struct + * \param[in] tx_data Pointer to data to transmit + * \param[in] length Number of characters to transmit + * + * \return Status of the operation + * \retval STATUS_OK If operation was completed + * \retval STATUS_ERR_INVALID_ARG If operation was not completed, due to invalid + * arguments + * \retval STATUS_ERR_TIMEOUT If operation was not completed, due to USART + * module timing out + * \retval STATUS_ERR_DENIED If the transmitter is not enabled + */ +enum status_code usart_write_buffer_wait( + struct usart_module *const module, + const uint8_t *tx_data, + uint16_t length) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + /* Check if the buffer length is valid */ + if (length == 0) { + return STATUS_ERR_INVALID_ARG; + } + + /* Check that the transmitter is enabled */ + if (!(module->transmitter_enabled)) { + return STATUS_ERR_DENIED; + } + + /* Get a pointer to the hardware module instance */ + SercomUsart *const usart_hw = &(module->hw->USART); + + /* Wait until synchronization is complete */ + _usart_wait_for_sync(module); + + uint16_t tx_pos = 0; + + /* Blocks while buffer is being transferred */ + while (length--) { + /* Wait for the USART to be ready for new data and abort + * operation if it doesn't get ready within the timeout*/ + for (uint32_t i = 0; i <= USART_TIMEOUT; i++) { + if (usart_hw->INTFLAG.reg & SERCOM_USART_INTFLAG_DRE) { + break; + } else if (i == USART_TIMEOUT) { + return STATUS_ERR_TIMEOUT; + } + } + + /* Data to send is at least 8 bits long */ + uint16_t data_to_send = tx_data[tx_pos++]; + + /* Check if the character size exceeds 8 bit */ + if (module->character_size == USART_CHARACTER_SIZE_9BIT) { + data_to_send |= (tx_data[tx_pos++] << 8); + } + + /* Send the data through the USART module */ + usart_write_wait(module, data_to_send); + } + + /* Wait until Transmit is complete or timeout */ + for (uint32_t i = 0; i <= USART_TIMEOUT; i++) { + if (usart_hw->INTFLAG.reg & SERCOM_USART_INTFLAG_TXC) { + break; + } else if (i == USART_TIMEOUT) { + return STATUS_ERR_TIMEOUT; + } + } + + return STATUS_OK; +} + +/** + * \brief Receive a buffer of \c length characters via the USART + * + * This blocking function will receive a block of \c length characters + * via the USART. + * + * \note Using this function in combination with the interrupt (\c *_job) + * functions is not recommended as it has no functionality to check if + * there is an ongoing interrupt driven operation running or not. + * + * \param[in] module Pointer to USART software instance struct + * \param[out] rx_data Pointer to receive buffer + * \param[in] length Number of characters to receive + * + * \return Status of the operation. + * \retval STATUS_OK If operation was completed + * \retval STATUS_ERR_INVALID_ARG If operation was not completed, due to an + * invalid argument being supplied + * \retval STATUS_ERR_TIMEOUT If operation was not completed, due + * to USART module timing out + * \retval STATUS_ERR_BAD_FORMAT If the operation was not completed, + * due to a configuration mismatch + * between USART and the sender + * \retval STATUS_ERR_BAD_OVERFLOW If the operation was not completed, + * due to the baud rate being too low or the + * system frequency being too high + * \retval STATUS_ERR_BAD_DATA If the operation was not completed, due + * to data being corrupted + * \retval STATUS_ERR_DENIED If the receiver is not enabled + */ +enum status_code usart_read_buffer_wait( + struct usart_module *const module, + uint8_t *rx_data, + uint16_t length) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + /* Check if the buffer length is valid */ + if (length == 0) { + return STATUS_ERR_INVALID_ARG; + } + + /* Check that the receiver is enabled */ + if (!(module->receiver_enabled)) { + return STATUS_ERR_DENIED; + } + + /* Get a pointer to the hardware module instance */ + SercomUsart *const usart_hw = &(module->hw->USART); + + uint16_t rx_pos = 0; + + /* Blocks while buffer is being received */ + while (length--) { + /* Wait for the USART to have new data and abort operation if it + * doesn't get ready within the timeout*/ + for (uint32_t i = 0; i <= USART_TIMEOUT; i++) { + if (usart_hw->INTFLAG.reg & SERCOM_USART_INTFLAG_RXC) { + break; + } else if (i == USART_TIMEOUT) { + return STATUS_ERR_TIMEOUT; + } + } + + enum status_code retval; + uint16_t received_data = 0; + + retval = usart_read_wait(module, &received_data); + + if (retval != STATUS_OK) { + /* Overflow, abort */ + return retval; + } + + /* Read value will be at least 8-bits long */ + rx_data[rx_pos++] = received_data; + + /* If 9-bit data, write next received byte to the buffer */ + if (module->character_size == USART_CHARACTER_SIZE_9BIT) { + rx_data[rx_pos++] = (received_data >> 8); + } + } + + return STATUS_OK; +} diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/usart/usart.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/usart/usart.h new file mode 100755 index 0000000..e61af7a --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/sercom/usart/usart.h @@ -0,0 +1,1257 @@ +/** + * + * \file + * + * \brief SAM SERCOM USART Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef USART_H_INCLUDED +#define USART_H_INCLUDED + +/** + * \defgroup asfdoc_sam0_sercom_usart_group SAM Serial USART Driver (SERCOM USART) + * + * This driver for SAM devices provides an interface for the configuration + * and management of the SERCOM module in its USART mode to transfer or receive + * USART data frames. The following driver API modes are covered by this + * manual: + * + * - Polled APIs + * \if USART_CALLBACK_MODE + * - Callback APIs + * \endif + * + * The following peripherals are used by this module: + * - SERCOM (Serial Communication Interface) + * + * The following devices can use this module: + * - SAM D20/D21 + * - SAM R21 + * - SAM D10/D11 + * + * The outline of this documentation is as follows: + * - \ref asfdoc_sam0_sercom_usart_prerequisites + * - \ref asfdoc_sam0_sercom_usart_overview + * - \ref asfdoc_sam0_sercom_usart_special_considerations + * - \ref asfdoc_sam0_sercom_usart_extra_info + * - \ref asfdoc_sam0_sercom_usart_examples + * - \ref asfdoc_sam0_sercom_usart_api_overview + * + * \section asfdoc_sam0_sercom_usart_prerequisites Prerequisites + * + * To use the USART you need to have a GCLK generator enabled and running + * that can be used as the SERCOM clock source. This can either be configured + * in conf_clocks.h or by using the system clock driver. + * + * \section asfdoc_sam0_sercom_usart_overview Module Overview + * + * This driver will use one (or more) SERCOM interfaces on the system + * and configure it to run as a USART interface in either synchronous + * or asynchronous mode. + * + * \subsection asfdoc_sam0_sercom_usart_features Driver Feature Macro Definition + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Driver Feature MacroSupported devices
FEATURE_USART_SYNC_SCHEME_V2SAM D21/R21/D10/D11
FEATURE_USART_OVER_SAMPLESAM D21/R21/D10/D11
FEATURE_USART_HARDWARE_FLOW_CONTROLSAM D21/R21/D10/D11
FEATURE_USART_IRDASAM D21/R21/D10/D11
FEATURE_USART_LIN_SLAVESAM D21/R21/D10/D11
FEATURE_USART_COLLISION_DECTIONSAM D21/R21/D10/D11
FEATURE_USART_START_FRAME_DECTIONSAM D21/R21/D10/D11
FEATURE_USART_IMMEDIATE_BUFFER_OVERFLOW_NOTIFICATIONSAM D21/R21/D10/D11
+ * \note The specific features are only available in the driver when the + * selected device supports those features. + * + * \subsection asfdoc_sam0_sercom_usart_overview_frame_format Frame Format + * + * Communication is based on frames, where the frame format can be customized + * to accommodate a wide range of standards. A frame consists of a start bit, + * a number of data bits, an optional parity bit for error detection as well + * as a configurable length stop bit(s) - see + * \ref asfdoc_sam0_sercom_usart_frame_diagram "the figure below". + * \ref asfdoc_sam0_sercom_usart_frame_params "The table below" shows the + * available parameters you can change in a frame. + * + * \anchor asfdoc_sam0_sercom_usart_frame_params + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
USART Frame Parameters
ParameterOptions
Start bit1
Data bits5, 6, 7, 8, 9
Parity bitNone, Even, Odd
Stop bits1, 2
+ * + * \anchor asfdoc_sam0_sercom_usart_frame_diagram + * \image html usart_frame.svg "USART Frame overview" width=100% + * + * \subsection asfdoc_sam0_sercom_usart_overview_sync Synchronous mode + * + * In synchronous mode a dedicated clock line is provided; either by the USART + * itself if in master mode, or by an external master if in slave mode. + * Maximum transmission speed is the same as the GCLK clocking the USART + * peripheral when in slave mode, and the GCLK divided by two if in + * master mode. In synchronous mode the interface needs three lines to + * communicate: + * - TX (Transmit pin) + * - RX (Receive pin) + * - XCK (Clock pin) + * + * \subsubsection asfdoc_sam0_sercom_usart_overview_sync_sampling Data sampling + * In synchronous mode the data is sampled on either the rising or falling edge + * of the clock signal. This is configured by setting the clock polarity in the + * configuration struct. + * + * \subsection asfdoc_sam0_sercom_usart_overview_async Asynchronous mode + * + * In asynchronous mode no dedicated clock line is used, and the communication + * is based on matching the clock speed on the transmitter and receiver. The + * clock is generated from the internal SERCOM baudrate generator, and the + * frames are synchronized by using the frame start bits. Maximum transmission + * speed is limited to the SERCOM GCLK divided by 16. + * In asynchronous mode the interface only needs two lines to communicate: + * - TX (Transmit pin) + * - RX (Receive pin) + * + * \subsubsection asfdoc_sam0_sercom_usart_overview_async_clock_matching Transmitter/receiver clock matching + * + * For successful transmit and receive using the asynchronous mode the receiver + * and transmitter clocks needs to be closely matched. When receiving a frame + * that does not match the selected baud rate closely enough the receiver will + * be unable to synchronize the frame(s), and garbage transmissions will + * result. + * + * \subsection asfdoc_sam0_sercom_usart_parity Parity + * Parity can be enabled to detect if a transmission was in error. This is done + * by counting the number of "1" bits in the frame. When using Even parity the + * parity bit will be set if the total number of "1"s in the frame are an even + * number. If using Odd parity the parity bit will be set if the total number + * of "1"s are Odd. + * + * When receiving a character the receiver will count the number of "1"s in the + * frame and give an error if the received frame and parity bit disagree. + * + * \subsection asfdoc_sam0_sercom_usart_overview_pin_configuration GPIO configuration + * + * The SERCOM module has four internal pads; the RX pin can be placed freely on + * any one of the four pads, and the TX and XCK pins have two predefined + * positions that can be selected as a pair. The pads can then be routed to an + * external GPIO pin using the normal pin multiplexing scheme on the SAM. + * + * \section asfdoc_sam0_sercom_usart_special_considerations Special Considerations + * + * \if USART_CALLBACK_MODE + * Never execute large portions of code in the callbacks. These + * are run from the interrupt routine, and thus having long callbacks will + * keep the processor in the interrupt handler for an equally long time. + * A common way to handle this is to use global flags signaling the + * main application that an interrupt event has happened, and only do the + * minimal needed processing in the callback. + * \else + * No special considerations. + * \endif + * + * \section asfdoc_sam0_sercom_usart_extra_info Extra Information + * + * For extra information see \ref asfdoc_sam0_sercom_usart_extra. This includes: + * - \ref asfdoc_sam0_sercom_usart_extra_acronyms + * - \ref asfdoc_sam0_sercom_usart_extra_dependencies + * - \ref asfdoc_sam0_sercom_usart_extra_errata + * - \ref asfdoc_sam0_sercom_usart_extra_history + * + * \section asfdoc_sam0_sercom_usart_examples Examples + * + * For a list of examples related to this driver, see + * \ref asfdoc_sam0_sercom_usart_exqsg. + * + * \section asfdoc_sam0_sercom_usart_api_overview API Overview + * @{ + */ + +#include +#include +#include + +#if USART_CALLBACK_MODE == true +# include +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \name Driver feature definition + * Define SERCOM USART features set according to different device family. + * @{ + */ +#if (SAMD21) || (SAMR21) || (SAMD10) || (SAMD11) || defined(__DOXYGEN__) +/** Usart sync scheme version 2. */ +# define FEATURE_USART_SYNC_SCHEME_V2 +/** Usart over sampling. */ +# define FEATURE_USART_OVER_SAMPLE +/** Usart hardware control flow. */ +# define FEATURE_USART_HARDWARE_FLOW_CONTROL +/** IrDA mode. */ +# define FEATURE_USART_IRDA +/** LIN slave mode. */ +# define FEATURE_USART_LIN_SLAVE +/** Usart collision detection. */ +# define FEATURE_USART_COLLISION_DECTION +/** Usart start frame detection. */ +# define FEATURE_USART_START_FRAME_DECTION +/** Usart start buffer overflow notification. */ +# define FEATURE_USART_IMMEDIATE_BUFFER_OVERFLOW_NOTIFICATION +#endif +/*@}*/ + +#ifndef PINMUX_DEFAULT +/** Default pin mux. */ +# define PINMUX_DEFAULT 0 +#endif + +#ifndef PINMUX_UNUSED +/** Unused PIN mux. */ +# define PINMUX_UNUSED 0xFFFFFFFF +#endif + +#ifndef USART_TIMEOUT +/** USART timeout value. */ +# define USART_TIMEOUT 0xFFFF +#endif + +#if USART_CALLBACK_MODE == true +/** + * \brief USART Callback enum + * + * Callbacks for the Asynchronous USART driver + */ +enum usart_callback { + /** Callback for buffer transmitted */ + USART_CALLBACK_BUFFER_TRANSMITTED, + /** Callback for buffer received */ + USART_CALLBACK_BUFFER_RECEIVED, + /** Callback for error */ + USART_CALLBACK_ERROR, +#ifdef FEATURE_USART_LIN_SLAVE + /** Callback for break character is received. */ + USART_CALLBACK_BREAK_RECEIVED, +#endif +#ifdef FEATURE_USART_HARDWARE_FLOW_CONTROL + /** Callback for a change is detected on the CTS pin. */ + USART_CALLBACK_CTS_INPUT_CHANGE, +#endif +#ifdef FEATURE_USART_START_FRAME_DECTION + /** Callback for a start condition is detected on the RxD line. */ + USART_CALLBACK_START_RECEIVED, +#endif +# if !defined(__DOXYGEN__) + /** Number of available callbacks. */ + USART_CALLBACK_N, +# endif +}; +#endif + +/** + * \brief USART Data Order enum + * + * The data order decides which of MSB or LSB is shifted out first when data is + * transferred + */ +enum usart_dataorder { + /** The MSB will be shifted out first during transmission, + * and shifted in first during reception */ + USART_DATAORDER_MSB = 0, + /** The LSB will be shifted out first during transmission, + * and shifted in first during reception */ + USART_DATAORDER_LSB = SERCOM_USART_CTRLA_DORD, +}; + +/** + * \brief USART Transfer mode enum + * + * Select USART transfer mode + */ +enum usart_transfer_mode { + /** Transfer of data is done synchronously */ + USART_TRANSFER_SYNCHRONOUSLY = (SERCOM_USART_CTRLA_CMODE), + /** Transfer of data is done asynchronously */ + USART_TRANSFER_ASYNCHRONOUSLY = 0 +}; + +/** + * \brief USART Parity enum + * + * Select parity USART parity mode + */ +enum usart_parity { + /** For odd parity checking, the parity bit will be set if number of + * ones being transferred is even */ + USART_PARITY_ODD = SERCOM_USART_CTRLB_PMODE, + + /** For even parity checking, the parity bit will be set if number of + * ones being received is odd */ + USART_PARITY_EVEN = 0, + + /** No parity checking will be executed, and there will be no parity bit + * in the received frame */ + USART_PARITY_NONE = 0xFF, +}; + +/** + * \brief USART signal mux settings + * + * Set the functionality of the SERCOM pins. + * + * See \ref asfdoc_sam0_sercom_usart_mux_settings for a description of the + * various MUX setting options. + */ +enum usart_signal_mux_settings { +#ifdef FEATURE_USART_HARDWARE_FLOW_CONTROL + /** MUX setting RX_0_TX_0_XCK_1 */ + USART_RX_0_TX_0_XCK_1 = (SERCOM_USART_CTRLA_RXPO(0) | SERCOM_USART_CTRLA_TXPO(0)), + /** MUX setting RX_0_TX_2_XCK_3 */ + USART_RX_0_TX_2_XCK_3 = (SERCOM_USART_CTRLA_RXPO(0) | SERCOM_USART_CTRLA_TXPO(1)), + /** MUX setting USART_RX_0_TX_0_RTS_2_CTS_3 */ + USART_RX_0_TX_0_RTS_2_CTS_3 = (SERCOM_USART_CTRLA_RXPO(0) | SERCOM_USART_CTRLA_TXPO(2)), + /** MUX setting RX_1_TX_0_XCK_1 */ + USART_RX_1_TX_0_XCK_1 = (SERCOM_USART_CTRLA_RXPO(1) | SERCOM_USART_CTRLA_TXPO(0)), + /** MUX setting RX_1_TX_2_XCK_3 */ + USART_RX_1_TX_2_XCK_3 = (SERCOM_USART_CTRLA_RXPO(1) | SERCOM_USART_CTRLA_TXPO(1)), + /** MUX setting USART_RX_1_TX_0_RTS_2_CTS_3 */ + USART_RX_1_TX_0_RTS_2_CTS_3 = (SERCOM_USART_CTRLA_RXPO(1) | SERCOM_USART_CTRLA_TXPO(2)), + /** MUX setting RX_2_TX_0_XCK_1 */ + USART_RX_2_TX_0_XCK_1 = (SERCOM_USART_CTRLA_RXPO(2) | SERCOM_USART_CTRLA_TXPO(0)), + /** MUX setting RX_2_TX_2_XCK_3 */ + USART_RX_2_TX_2_XCK_3 = (SERCOM_USART_CTRLA_RXPO(2) | SERCOM_USART_CTRLA_TXPO(1)), + /** MUX setting USART_RX_2_TX_0_RTS_2_CTS_3 */ + USART_RX_2_TX_0_RTS_2_CTS_3 = (SERCOM_USART_CTRLA_RXPO(2) | SERCOM_USART_CTRLA_TXPO(2)), + /** MUX setting RX_3_TX_0_XCK_1 */ + USART_RX_3_TX_0_XCK_1 = (SERCOM_USART_CTRLA_RXPO(3) | SERCOM_USART_CTRLA_TXPO(0)), + /** MUX setting RX_3_TX_2_XCK_3 */ + USART_RX_3_TX_2_XCK_3 = (SERCOM_USART_CTRLA_RXPO(3) | SERCOM_USART_CTRLA_TXPO(1)), + /** MUX setting USART_RX_3_TX_0_RTS_2_CTS_3 */ + USART_RX_3_TX_0_RTS_2_CTS_3 = (SERCOM_USART_CTRLA_RXPO(3) | SERCOM_USART_CTRLA_TXPO(2)), +#else + /** MUX setting RX_0_TX_0_XCK_1 */ + USART_RX_0_TX_0_XCK_1 = (SERCOM_USART_CTRLA_RXPO(0)), + /** MUX setting RX_0_TX_2_XCK_3 */ + USART_RX_0_TX_2_XCK_3 = (SERCOM_USART_CTRLA_RXPO(0) | SERCOM_USART_CTRLA_TXPO), + /** MUX setting RX_1_TX_0_XCK_1 */ + USART_RX_1_TX_0_XCK_1 = (SERCOM_USART_CTRLA_RXPO(1)), + /** MUX setting RX_1_TX_2_XCK_3 */ + USART_RX_1_TX_2_XCK_3 = (SERCOM_USART_CTRLA_RXPO(1) | SERCOM_USART_CTRLA_TXPO), + /** MUX setting RX_2_TX_0_XCK_1 */ + USART_RX_2_TX_0_XCK_1 = (SERCOM_USART_CTRLA_RXPO(2)), + /** MUX setting RX_2_TX_2_XCK_3 */ + USART_RX_2_TX_2_XCK_3 = (SERCOM_USART_CTRLA_RXPO(2) | SERCOM_USART_CTRLA_TXPO), + /** MUX setting RX_3_TX_0_XCK_1 */ + USART_RX_3_TX_0_XCK_1 = (SERCOM_USART_CTRLA_RXPO(3)), + /** MUX setting RX_3_TX_2_XCK_3 */ + USART_RX_3_TX_2_XCK_3 = (SERCOM_USART_CTRLA_RXPO(3) | SERCOM_USART_CTRLA_TXPO), +#endif +}; + +/** + * \brief USART Stop Bits enum + * + * Number of stop bits for a frame. + */ +enum usart_stopbits { + /** Each transferred frame contains 1 stop bit */ + USART_STOPBITS_1 = 0, + /** Each transferred frame contains 2 stop bits */ + USART_STOPBITS_2 = SERCOM_USART_CTRLB_SBMODE, +}; + +/** + * \brief USART Character Size + * + * Number of bits for the character sent in a frame. + */ +enum usart_character_size { + /** The char being sent in a frame is 5 bits long */ + USART_CHARACTER_SIZE_5BIT = SERCOM_USART_CTRLB_CHSIZE(5), + /** The char being sent in a frame is 6 bits long */ + USART_CHARACTER_SIZE_6BIT = SERCOM_USART_CTRLB_CHSIZE(6), + /** The char being sent in a frame is 7 bits long */ + USART_CHARACTER_SIZE_7BIT = SERCOM_USART_CTRLB_CHSIZE(7), + /** The char being sent in a frame is 8 bits long */ + USART_CHARACTER_SIZE_8BIT = SERCOM_USART_CTRLB_CHSIZE(0), + /** The char being sent in a frame is 9 bits long */ + USART_CHARACTER_SIZE_9BIT = SERCOM_USART_CTRLB_CHSIZE(1), +}; + +#ifdef FEATURE_USART_OVER_SAMPLE +/** + * \brief USART Sample Rate + * + * The value of sample rate and baud rate generation mode. + */ +enum usart_sample_rate { + /** 16x over-sampling using arithmetic baud rate generation */ + USART_SAMPLE_RATE_16X_ARITHMETIC = SERCOM_USART_CTRLA_SAMPR(0), + /** 16x over-sampling using fractional baud rate generation */ + USART_SAMPLE_RATE_16X_FRACTIONAL = SERCOM_USART_CTRLA_SAMPR(1), + /** 8x over-sampling using arithmetic baud rate generation */ + USART_SAMPLE_RATE_8X_ARITHMETIC = SERCOM_USART_CTRLA_SAMPR(2), + /** 8x over-sampling using fractional baud rate generation */ + USART_SAMPLE_RATE_8X_FRACTIONAL = SERCOM_USART_CTRLA_SAMPR(3), + /** 3x over-sampling using arithmetic baud rate generation */ + USART_SAMPLE_RATE_3X_ARITHMETIC = SERCOM_USART_CTRLA_SAMPR(4), +}; + +/** + * \brief USART Sample Adjustment + * + * The value of sample number used for majority voting + */ +enum usart_sample_adjustment { + /** The first, middle and last sample number used for majority voting is 7-8-9 */ + USART_SAMPLE_ADJUSTMENT_7_8_9 = SERCOM_USART_CTRLA_SAMPA(0), + /** The first, middle and last sample number used for majority voting is 9-10-11 */ + USART_SAMPLE_ADJUSTMENT_9_10_11 = SERCOM_USART_CTRLA_SAMPA(1), + /** The first, middle and last sample number used for majority voting is 11-12-13 */ + USART_SAMPLE_ADJUSTMENT_11_12_13 = SERCOM_USART_CTRLA_SAMPA(2), + /** The first, middle and last sample number used for majority voting is 13-14-15 */ + USART_SAMPLE_ADJUSTMENT_13_14_15 = SERCOM_USART_CTRLA_SAMPA(3), +}; +#endif + +/** + * \brief USART Transceiver + * + * Select Receiver or Transmitter + */ +enum usart_transceiver_type { + /** The parameter is for the Receiver */ + USART_TRANSCEIVER_RX, + /** The parameter is for the Transmitter */ + USART_TRANSCEIVER_TX, +}; + +/** + * \brief USART configuration struct + * + * Configuration options for USART + */ +struct usart_config { + /** USART bit order (MSB or LSB first) */ + enum usart_dataorder data_order; + /** USART in asynchronous or synchronous mode */ + enum usart_transfer_mode transfer_mode; + /** USART parity */ + enum usart_parity parity; + /** Number of stop bits */ + enum usart_stopbits stopbits; + /** USART character size */ + enum usart_character_size character_size; + /** USART pin out */ + enum usart_signal_mux_settings mux_setting; +#ifdef FEATURE_USART_OVER_SAMPLE + /** USART sample rate */ + enum usart_sample_rate sample_rate; + /** USART sample adjustment */ + enum usart_sample_adjustment sample_adjustment; +#endif +#ifdef FEATURE_USART_IMMEDIATE_BUFFER_OVERFLOW_NOTIFICATION + /** Controls when the buffer overflow status bit is asserted when a buffer overflow occurs.*/ + bool immediate_buffer_overflow_notification; +#endif +#ifdef FEATURE_USART_IRDA + /** Enable IrDA encoding format */ + bool encoding_format_enable; + /** The minimum pulse length that is required for a pulse to be accepted by the IrDA receiver */ + uint8_t receive_pulse_length; +#endif +#ifdef FEATURE_USART_LIN_SLAVE + /** Enable LIN Slave Support */ + bool lin_slave_enable; +#endif +#ifdef FEATURE_USART_START_FRAME_DECTION + /** Enable start of frame dection */ + bool start_frame_detection_enable; +#endif +#ifdef FEATURE_USART_COLLISION_DECTION + /** Enable collision dection */ + bool collision_detection_enable; +#endif + /** USART baud rate */ + uint32_t baudrate; + /** Enable receiver */ + bool receiver_enable; + /** Enable transmitter */ + bool transmitter_enable; + + /** USART Clock Polarity. + * If true, data changes on falling XCK edge and + * is sampled at rising edge. + * If false, data changes on rising XCK edge and + * is sampled at falling edge. + * */ + bool clock_polarity_inverted; + + /** States whether to use the external clock applied to the XCK pin. + * In synchronous mode the shift register will act directly on the XCK clock. + * In asynchronous mode the XCK will be the input to the USART hardware module. + */ + bool use_external_clock; + /** External clock frequency in synchronous mode. + * This must be set if \c use_external_clock is true. */ + uint32_t ext_clock_freq; + /** If true the USART will be kept running in Standby sleep mode */ + bool run_in_standby; + /** GCLK generator source */ + enum gclk_generator generator_source; + /** PAD0 pinmux */ + uint32_t pinmux_pad0; + /** PAD1 pinmux */ + uint32_t pinmux_pad1; + /** PAD2 pinmux */ + uint32_t pinmux_pad2; + /** PAD3 pinmux */ + uint32_t pinmux_pad3; +}; + +#if USART_CALLBACK_MODE == true +/** + * \brief USART module instance + * + * Forward Declaration for the device instance + */ +struct usart_module; + +/** + * \brief USART callback type + * + * Type of the callback functions + */ +typedef void (*usart_callback_t)(const struct usart_module *const module); +#endif + +/** + * \brief SERCOM USART driver software device instance structure. + * + * SERCOM USART driver software instance structure, used to retain software + * state information of an associated hardware module instance. + * + * \note The fields of this structure should not be altered by the user + * application; they are reserved for module-internal use only. + */ +struct usart_module { +#if !defined(__DOXYGEN__) + /** Pointer to the hardware instance */ + Sercom *hw; + /** Module lock */ + volatile bool locked; + /** Character size of the data being transferred */ + enum usart_character_size character_size; + /** Receiver enabled */ + bool receiver_enabled; + /** Transmitter enabled */ + bool transmitter_enabled; +#ifdef FEATURE_USART_LIN_SLAVE + /** LIN Slave Support enabled */ + bool lin_slave_enabled; +#endif +#ifdef FEATURE_USART_START_FRAME_DECTION + /** Start of frame dection enabled */ + bool start_frame_detection_enabled; +#endif +# if USART_CALLBACK_MODE == true + /** Array to store callback function pointers in */ + usart_callback_t callback[USART_CALLBACK_N]; + /** Buffer pointer to where the next received character will be put */ + volatile uint8_t *rx_buffer_ptr; + + /** Buffer pointer to where the next character will be transmitted from + **/ + volatile uint8_t *tx_buffer_ptr; + /** Remaining characters to receive */ + volatile uint16_t remaining_rx_buffer_length; + /** Remaining characters to transmit */ + volatile uint16_t remaining_tx_buffer_length; + /** Bit mask for callbacks registered */ + uint8_t callback_reg_mask; + /** Bit mask for callbacks enabled */ + uint8_t callback_enable_mask; + /** Holds the status of the ongoing or last read operation */ + volatile enum status_code rx_status; + /** Holds the status of the ongoing or last write operation */ + volatile enum status_code tx_status; +# endif +#endif +}; + + /** + * \name Lock/Unlock + * @{ + */ + +/** + * \brief Attempt to get lock on driver instance + * + * This function checks the instance's lock, which indicates whether or not it + * is currently in use, and sets the lock if it was not already set. + * + * The purpose of this is to enable exclusive access to driver instances, so + * that, e.g., transactions by different services will not interfere with each + * other. + * + * \param[in,out] module Pointer to the driver instance to lock. + * + * \retval STATUS_OK if the module was locked. + * \retval STATUS_BUSY if the module was already locked. + */ +static inline enum status_code usart_lock( + struct usart_module *const module) +{ + enum status_code status; + + system_interrupt_enter_critical_section(); + + if (module->locked) { + status = STATUS_BUSY; + } else { + module->locked = true; + status = STATUS_OK; + } + + system_interrupt_leave_critical_section(); + + return status; +} + +/** + * \brief Unlock driver instance + * + * This function clears the instance lock, indicating that it is available for + * use. + * + * \param[in,out] module Pointer to the driver instance to lock. + * + */ +static inline void usart_unlock(struct usart_module *const module) +{ + module->locked = false; +} + +/** @} */ + +/** + * \brief Check if peripheral is busy syncing registers across clock domains + * + * Return peripheral synchronization status. If doing a non-blocking + * implementation this function can be used to check the sync state and hold of + * any new actions until sync is complete. If this functions is not run; the + * functions will block until the sync has completed. + * + * \param[in] module Pointer to peripheral module + * + * \return Peripheral sync status + * + * \retval true Peripheral is busy syncing + * \retval false Peripheral is not busy syncing and can be read/written without + * stalling the bus. + */ +static inline bool usart_is_syncing( + const struct usart_module *const module) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + SercomUsart *const usart_hw = &(module->hw->USART); + +#ifdef FEATURE_USART_SYNC_SCHEME_V2 + return (usart_hw->SYNCBUSY.reg); +#else + return (usart_hw->STATUS.reg & SERCOM_USART_STATUS_SYNCBUSY); +#endif +} + +#if !defined (__DOXYGEN__) +/** + * \internal + * Waits until synchronization is complete + */ +static inline void _usart_wait_for_sync( + const struct usart_module *const module) +{ + /* Sanity check. */ + Assert(module); + + while (usart_is_syncing(module)) { + /* Wait until the synchronization is complete */ + } +} +#endif + +/** + * \brief Initializes the device to predefined defaults + * + * Initialize the USART device to predefined defaults: + * - 8-bit asynchronous USART + * - No parity + * - 1 stop bit + * - 9600 baud + * - Transmitter enabled + * - Receiver enabled + * - GCLK generator 0 as clock source + * - Default pin configuration + * + * The configuration struct will be updated with the default + * configuration. + * + * \param[in,out] config Pointer to configuration struct + */ +static inline void usart_get_config_defaults( + struct usart_config *const config) +{ + /* Sanity check arguments */ + Assert(config); + + /* Set default config in the config struct */ + config->data_order = USART_DATAORDER_LSB; + config->transfer_mode = USART_TRANSFER_ASYNCHRONOUSLY; + config->parity = USART_PARITY_NONE; + config->stopbits = USART_STOPBITS_1; + config->character_size = USART_CHARACTER_SIZE_8BIT; + config->baudrate = 9600; + config->receiver_enable = true; + config->transmitter_enable = true; + config->clock_polarity_inverted = false; + config->use_external_clock = false; + config->ext_clock_freq = 0; + config->mux_setting = USART_RX_1_TX_2_XCK_3; + config->run_in_standby = false; + config->generator_source = GCLK_GENERATOR_0; + config->pinmux_pad0 = PINMUX_DEFAULT; + config->pinmux_pad1 = PINMUX_DEFAULT; + config->pinmux_pad2 = PINMUX_DEFAULT; + config->pinmux_pad3 = PINMUX_DEFAULT; +#ifdef FEATURE_USART_OVER_SAMPLE + config->sample_adjustment = USART_SAMPLE_ADJUSTMENT_7_8_9; + config->sample_rate = USART_SAMPLE_RATE_16X_ARITHMETIC; +#endif +#ifdef FEATURE_USART_LIN_SLAVE + config->lin_slave_enable = false; +#endif +#ifdef FEATURE_USART_IMMEDIATE_BUFFER_OVERFLOW_NOTIFICATION + config->immediate_buffer_overflow_notification = false; +#endif +#ifdef FEATURE_USART_START_FRAME_DECTION + config->start_frame_detection_enable = false; +#endif +#ifdef FEATURE_USART_IRDA + config->encoding_format_enable = false; + config->receive_pulse_length = 19; +#endif +#ifdef FEATURE_USART_COLLISION_DECTION + config->collision_detection_enable = false; +#endif +} + +enum status_code usart_init( + struct usart_module *const module, + Sercom *const hw, + const struct usart_config *const config); + +/** + * \brief Enable the module + * + * Enables the USART module + * + * \param[in] module Pointer to USART software instance struct + */ +static inline void usart_enable( + const struct usart_module *const module) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + /* Get a pointer to the hardware module instance */ + SercomUsart *const usart_hw = &(module->hw->USART); + +#if USART_CALLBACK_MODE == true + /* Enable Global interrupt for module */ + system_interrupt_enable(_sercom_get_interrupt_vector(module->hw)); +#endif + + /* Wait until synchronization is complete */ + _usart_wait_for_sync(module); + + /* Enable USART module */ + usart_hw->CTRLA.reg |= SERCOM_USART_CTRLA_ENABLE; +} + +/** + * \brief Disable module + * + * Disables the USART module + * + * \param[in] module Pointer to USART software instance struct + */ +static inline void usart_disable( + const struct usart_module *const module) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + /* Get a pointer to the hardware module instance */ + SercomUsart *const usart_hw = &(module->hw->USART); + + /* Disable Global interrupt for module */ + system_interrupt_disable(_sercom_get_interrupt_vector(module->hw)); + + /* Wait until synchronization is complete */ + _usart_wait_for_sync(module); + + /* Disable USART module */ + usart_hw->CTRLA.reg &= ~SERCOM_USART_CTRLA_ENABLE; +} + +/** + * \brief Resets the USART module + * + * Disables and resets the USART module. + * + * \param[in] module Pointer to the USART software instance struct + */ +static inline void usart_reset( + const struct usart_module *const module) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + /* Get a pointer to the hardware module instance */ + SercomUsart *const usart_hw = &(module->hw->USART); + + usart_disable(module); + + /* Wait until synchronization is complete */ + _usart_wait_for_sync(module); + + /* Reset module */ + usart_hw->CTRLA.reg = SERCOM_USART_CTRLA_SWRST; +} + +/** + * \name Writing and reading + * @{ + */ +enum status_code usart_write_wait( + struct usart_module *const module, + const uint16_t tx_data); + +enum status_code usart_read_wait( + struct usart_module *const module, + uint16_t *const rx_data); + +enum status_code usart_write_buffer_wait( + struct usart_module *const module, + const uint8_t *tx_data, + uint16_t length); + +enum status_code usart_read_buffer_wait( + struct usart_module *const module, + uint8_t *rx_data, + uint16_t length); +/** @} */ + +/** + * \name Enabling/Disabling receiver and transmitter + * @{ + */ + +/** + * \brief Enable Transceiver + * + * Enable the given transceiver. Either RX or TX. + * + * \param[in] module Pointer to USART software instance struct + * \param[in] transceiver_type Transceiver type. + */ +static inline void usart_enable_transceiver( + struct usart_module *const module, + enum usart_transceiver_type transceiver_type) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + /* Get a pointer to the hardware module instance */ + SercomUsart *const usart_hw = &(module->hw->USART); + + /* Wait until synchronization is complete */ + _usart_wait_for_sync(module); + + switch (transceiver_type) { + case USART_TRANSCEIVER_RX: + /* Enable RX */ + usart_hw->CTRLB.reg |= SERCOM_USART_CTRLB_RXEN; + module->receiver_enabled = true; + break; + + case USART_TRANSCEIVER_TX: + /* Enable TX */ + usart_hw->CTRLB.reg |= SERCOM_USART_CTRLB_TXEN; + module->transmitter_enabled = true; + break; + } +} + +/** + * \brief Disable Transceiver + * + * Disable the given transceiver (RX or TX). + * + * \param[in] module Pointer to USART software instance struct + * \param[in] transceiver_type Transceiver type. + */ +static inline void usart_disable_transceiver( + struct usart_module *const module, + enum usart_transceiver_type transceiver_type) +{ + /* Sanity check arguments */ + Assert(module); + Assert(module->hw); + + /* Get a pointer to the hardware module instance */ + SercomUsart *const usart_hw = &(module->hw->USART); + + /* Wait until synchronization is complete */ + _usart_wait_for_sync(module); + + switch (transceiver_type) { + case USART_TRANSCEIVER_RX: + /* Disable RX */ + usart_hw->CTRLB.reg &= ~SERCOM_USART_CTRLB_RXEN; + module->receiver_enabled = false; + break; + + case USART_TRANSCEIVER_TX: + /* Disable TX */ + usart_hw->CTRLB.reg &= ~SERCOM_USART_CTRLB_TXEN; + module->transmitter_enabled = false; + break; + } +} + +/** @} */ + +#ifdef __cplusplus +} +#endif + +/** @} */ + +/** +* \page asfdoc_sam0_sercom_usart_extra Extra Information for SERCOM USART Driver +* +* \section asfdoc_sam0_sercom_usart_extra_acronyms Acronyms +* +* Below is a table listing the acronyms used in this module, along with their +* intended meanings. +* +* +* +* +* +* +* +* +* +* +* +* +* +* +* +* +* +* +* +* +* +* +* +* +* +* +*
AcronymDescription
SERCOMSerial Communication Interface
USARTUniversal Synchronous and Asynchronous Serial Receiver and Transmitter
LSBLeast Significant Bit
MSBMost Significant Bit
DMADirect Memory Access
+* +* +* \section asfdoc_sam0_sercom_usart_extra_dependencies Dependencies +* This driver has the following dependencies: +* +* - \ref asfdoc_sam0_system_pinmux_group "System Pin Multiplexer Driver" +* - \ref asfdoc_sam0_system_clock_group "System clock configuration" +* +* +* \section asfdoc_sam0_sercom_usart_extra_errata Errata +* There are no errata related to this driver. +* +* +* \section asfdoc_sam0_sercom_usart_extra_history Module History +* An overview of the module history is presented in the table below, with +* details on the enhancements and fixes made to the module since its first +* release. The current version of this corresponds to the newest version in +* the table. +* + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Changelog
Add support for SAMD10/D11 (same features as SAMD21).
Add support for SAMR21 (same features as SAMD21).
Add support for SAMD21 and added new feature as below: + \li Oversample + \li Buffer overflow notification + \li Irda + \li Lin slave + \li Start frame detection + \li Hardware flow control + \li Collision detection + \li DMA support
\li Added new \c transmitter_enable and \c receiver_enable boolean + * values to \c struct usart_config. + * \li Altered \c usart_write_* and usart_read_* functions to abort with + * an error code if the relevant transceiver is not enabled. + * \li Fixed \c usart_write_buffer_wait() and \c usart_read_buffer_wait() + * not aborting correctly when a timeout condition occurs.
Initial Release
+*/ + +/** + * \page asfdoc_sam0_sercom_usart_exqsg Examples for SERCOM USART Driver + * + * This is a list of the available Quick Start guides (QSGs) and example + * applications for \ref asfdoc_sam0_sercom_usart_group. QSGs are simple examples with + * step-by-step instructions to configure and use this driver in a selection of + * use cases. Note that QSGs can be compiled as a standalone application or be + * added to the user application. + * + * - \subpage asfdoc_sam0_sercom_usart_basic_use_case + * \if USART_CALLBACK_MODE + * - \subpage asfdoc_sam0_sercom_usart_callback_use_case + * \endif + * - \subpage asfdoc_sam0_sercom_usart_dma_use_case + */ + +/** + * \page asfdoc_sam0_sercom_usart_mux_settings SERCOM USART MUX Settings + * + * The following lists the possible internal SERCOM module pad function + * assignments, for the four SERCOM pads when in USART mode. Note that this is + * in addition to the physical GPIO pin MUX of the device, and can be used in + * conjunction to optimize the serial data pin-out. + * + * When TX and RX are connected to the same pin, the USART will operate in + * half-duplex mode if both the transmitter and receivers are enabled. + * + * \note When RX and XCK are connected to the same pin, the receiver must not + * be enabled if the USART is configured to use an external clock. + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Mux/PadPAD 0PAD 1PAD 2PAD 3
RX_0_TX_0_XCK_1TX / RXXCK--
RX_0_TX_2_XCK_3RX-TXXCK
RX_1_TX_0_XCK_1TXRX / XCK--
RX_1_TX_2_XCK_3-RXTXXCK
RX_2_TX_0_XCK_1TXXCKRX-
RX_2_TX_2_XCK_3--TX / RXXCK
RX_3_TX_0_XCK_1TXXCK-RX
RX_3_TX_2_XCK_3--TXRX / XCK
+ * + * \page asfdoc_sam0_sercom_usart_document_revision_history Document Revision History + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Doc. Rev. + * Date + * Comments + *
F05/2014Add support for SAMD10/D11.
E03/2014Add support for SAMR21.
D01/2014Add support for SAMD21.
C10/2013Replaced the pad multiplexing documentation with a condensed table.
B06/2013Corrected documentation typos.
A06/2013Initial release
+ */ +#endif /* USART_H_INCLUDED */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/clock.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/clock.h new file mode 100755 index 0000000..a1f35db --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/clock.h @@ -0,0 +1,1526 @@ +/** + * \file + * + * \brief SAM Clock Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef SYSTEM_CLOCK_H_INCLUDED +#define SYSTEM_CLOCK_H_INCLUDED + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \defgroup asfdoc_sam0_system_clock_group SAM System Clock Management Driver (SYSTEM CLOCK) + * + * This driver for SAM devices provides an interface for the configuration + * and management of the device's clocking related functions. This includes + * the various clock sources, bus clocks and generic clocks within the device, + * with functions to manage the enabling, disabling, source selection and + * prescaling of clocks to various internal peripherals. + * + * The following peripherals are used by this module: + * + * - GCLK (Generic Clock Management) + * - PM (Power Management) + * - SYSCTRL (Clock Source Control) + * + * The following devices can use this module: + * - SAM D20/D21 + * - SAM R21 + * - SAM D10/D11 + * + * The outline of this documentation is as follows: + * - \ref asfdoc_sam0_system_clock_prerequisites + * - \ref asfdoc_sam0_system_clock_module_overview + * - \ref asfdoc_sam0_system_clock_special_considerations + * - \ref asfdoc_sam0_system_clock_extra_info + * - \ref asfdoc_sam0_system_clock_examples + * - \ref asfdoc_sam0_system_clock_api_overview + * + * + * \section asfdoc_sam0_system_clock_prerequisites Prerequisites + * + * There are no prerequisites for this module. + * + * + * \section asfdoc_sam0_system_clock_module_overview Module Overview + * The SAM devices contain a sophisticated clocking system, which is designed + * to give the maximum flexibility to the user application. This system allows + * a system designer to tune the performance and power consumption of the device + * in a dynamic manner, to achieve the best trade-off between the two for a + * particular application. + * + * This driver provides a set of functions for the configuration and management + * of the various clock related functionality within the device. + * + * \subsection asfdoc_sam0_system_clock_module_features Driver Feature Macro Definition + * + * + * + * + * + * + * + * + * + *
Driver Feature MacroSupported devices
FEATURE_SYSTEM_CLOCK_DPLLSAMD21, SAMR21, SAMD10, SAMD11
+ * \note The specific features are only available in the driver when the + * selected device supports those features. + * + * \subsection asfdoc_sam0_system_clock_module_overview_clock_sources Clock Sources + * The SAM devices have a number of master clock source modules, each of + * which being capable of producing a stabilized output frequency which can then + * be fed into the various peripherals and modules within the device. + * + * Possible clock source modules include internal R/C oscillators, internal + * DFLL modules, as well as external crystal oscillators and/or clock inputs. + * + * \subsection asfdoc_sam0_system_clock_module_overview_cpu_clock CPU / Bus Clocks + * The CPU and AHB/APBx buses are clocked by the same physical clock source + * (referred in this module as the Main Clock), however the APBx buses may + * have additional prescaler division ratios set to give each peripheral bus a + * different clock speed. + * + * The general main clock tree for the CPU and associated buses is shown in + * \ref asfdoc_sam0_system_clock_module_clock_tree "the figure below". + * + * \anchor asfdoc_sam0_system_clock_module_clock_tree + * \dot + * digraph overview { + * rankdir=LR; + * clk_src [label="Clock Sources", shape=none, height=0]; + * node [label="CPU Bus" shape=ellipse] cpu_bus; + * node [label="AHB Bus" shape=ellipse] ahb_bus; + * node [label="APBA Bus" shape=ellipse] apb_a_bus; + * node [label="APBB Bus" shape=ellipse] apb_b_bus; + * node [label="APBC Bus" shape=ellipse] apb_c_bus; + * node [label="Main Bus\nPrescaler" shape=square] main_prescaler; + * node [label="APBA Bus\nPrescaler" shape=square] apb_a_prescaler; + * node [label="APBB Bus\nPrescaler" shape=square] apb_b_prescaler; + * node [label="APBC Bus\nPrescaler" shape=square] apb_c_prescaler; + * node [label="", shape=polygon, sides=4, distortion=0.6, orientation=90, style=filled, fillcolor=black, height=0.9, width=0.2] main_clock_mux; + * + * clk_src -> main_clock_mux; + * main_clock_mux -> main_prescaler; + * main_prescaler -> cpu_bus; + * main_prescaler -> ahb_bus; + * main_prescaler -> apb_a_prescaler; + * main_prescaler -> apb_b_prescaler; + * main_prescaler -> apb_c_prescaler; + * apb_a_prescaler -> apb_a_bus; + * apb_b_prescaler -> apb_b_bus; + * apb_c_prescaler -> apb_c_bus; + * } + * \enddot + * + * \subsection asfdoc_sam0_system_clock_module_overview_clock_masking Clock Masking + * To save power, the input clock to one or more peripherals on the AHB and APBx + * buses can be masked away - when masked, no clock is passed into the module. + * Disabling of clocks of unused modules will prevent all access to the masked + * module, but will reduce the overall device power consumption. + * + * \subsection asfdoc_sam0_system_clock_module_overview_gclk Generic Clocks + * Within the SAM devices are a number of Generic Clocks; these are used to + * provide clocks to the various peripheral clock domains in the device in a + * standardized manner. One or more master source clocks can be selected as the + * input clock to a Generic Clock Generator, which can prescale down the input + * frequency to a slower rate for use in a peripheral. + * + * Additionally, a number of individually selectable Generic Clock Channels are + * provided, which multiplex and gate the various generator outputs for one or + * more peripherals within the device. This setup allows for a single common + * generator to feed one or more channels, which can then be enabled or disabled + * individually as required. + * + * \anchor asfdoc_sam0_system_clock_module_chain_overview + * \dot + * digraph overview { + * rankdir=LR; + * node [label="Clock\nSource a" shape=square] system_clock_source; + * node [label="Generator 1" shape=square] clock_gen; + * node [label="Channel x" shape=square] clock_chan0; + * node [label="Channel y" shape=square] clock_chan1; + * node [label="Peripheral x" shape=ellipse style=filled fillcolor=lightgray] peripheral0; + * node [label="Peripheral y" shape=ellipse style=filled fillcolor=lightgray] peripheral1; + * + * system_clock_source -> clock_gen; + * clock_gen -> clock_chan0; + * clock_chan0 -> peripheral0; + * clock_gen -> clock_chan1; + * clock_chan1 -> peripheral1; + * } + * \enddot + * + * \subsubsection asfdoc_sam0_system_clock_module_chain_example Clock Chain Example + * An example setup of a complete clock chain within the device is shown in + * \ref asfdoc_sam0_system_clock_module_chain_example_fig "the figure below". + * + * \anchor asfdoc_sam0_system_clock_module_chain_example_fig + * \dot + * digraph overview { + * rankdir=LR; + * node [label="External\nOscillator" shape=square] system_clock_source0; + * node [label="Generator 0" shape=square] clock_gen0; + * node [label="Channel x" shape=square] clock_chan0; + * node [label="Core CPU" shape=ellipse style=filled fillcolor=lightgray] peripheral0; + * + * system_clock_source0 -> clock_gen0; + * clock_gen0 -> clock_chan0; + * clock_chan0 -> peripheral0; + * node [label="8MHz R/C\nOscillator (OSC8M)" shape=square fillcolor=white] system_clock_source1; + * node [label="Generator 1" shape=square] clock_gen1; + * node [label="Channel y" shape=square] clock_chan1; + * node [label="Channel z" shape=square] clock_chan2; + * node [label="SERCOM\nModule" shape=ellipse style=filled fillcolor=lightgray] peripheral1; + * node [label="Timer\nModule" shape=ellipse style=filled fillcolor=lightgray] peripheral2; + * + * system_clock_source1 -> clock_gen1; + * clock_gen1 -> clock_chan1; + * clock_gen1 -> clock_chan2; + * clock_chan1 -> peripheral1; + * clock_chan2 -> peripheral2; + * } + * \enddot + * + * \subsubsection asfdoc_sam0_system_clock_module_overview_gclk_generators Generic Clock Generators + * Each Generic Clock generator within the device can source its input clock + * from one of the provided Source Clocks, and prescale the output for one or + * more Generic Clock Channels in a one-to-many relationship. The generators + * thus allow for several clocks to be generated of different frequencies, + * power usages and accuracies, which can be turned on and off individually to + * disable the clocks to multiple peripherals as a group. + * + * \subsubsection asfdoc_sam0_system_clock_module_overview_gclk_channels Generic Clock Channels + * To connect a Generic Clock Generator to a peripheral within the + * device, a Generic Clock Channel is used. Each peripheral or + * peripheral group has an associated Generic Clock Channel, which serves as the + * clock input for the peripheral(s). To supply a clock to the peripheral + * module(s), the associated channel must be connected to a running Generic + * Clock Generator and the channel enabled. + * + * \section asfdoc_sam0_system_clock_special_considerations Special Considerations + * + * There are no special considerations for this module. + * + * + * \section asfdoc_sam0_system_clock_extra_info Extra Information + * + * For extra information see \ref asfdoc_sam0_system_clock_extra. This includes: + * - \ref asfdoc_sam0_system_clock_extra_acronyms + * - \ref asfdoc_sam0_system_clock_extra_dependencies + * - \ref asfdoc_sam0_system_clock_extra_errata + * - \ref asfdoc_sam0_system_clock_extra_history + * + * + * \section asfdoc_sam0_system_clock_examples Examples + * + * For a list of examples related to this driver, see + * \ref asfdoc_sam0_system_clock_exqsg. + * + * + * \section asfdoc_sam0_system_clock_api_overview API Overview + * @{ + */ + +#include +#include + +/** + * \name Driver feature definition + * Define system clock features set according to different device family. + * @{ + */ +#if (SAMD21) || (SAMR21) || (SAMD11) || (SAMD10) || defined(__DOXYGEN__) +/** Digital Phase Locked Loop (DPLL) feature support */ +# define FEATURE_SYSTEM_CLOCK_DPLL +#endif +/*@}*/ + +/** + * \brief Available start-up times for the XOSC32K + * + * Available external 32KHz oscillator start-up times, as a number of external + * clock cycles. + */ +enum system_xosc32k_startup { + /** Wait 0 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC32K_STARTUP_0, + /** Wait 32 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC32K_STARTUP_32, + /** Wait 2048 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC32K_STARTUP_2048, + /** Wait 4096 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC32K_STARTUP_4096, + /** Wait 16384 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC32K_STARTUP_16384, + /** Wait 32768 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC32K_STARTUP_32768, + /** Wait 65536 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC32K_STARTUP_65536, + /** Wait 131072 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC32K_STARTUP_131072, +}; + +/** + * \brief Available start-up times for the XOSC + * + * Available external oscillator start-up times, as a number of external clock + * cycles. + */ +enum system_xosc_startup { + /** Wait 1 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_1, + /** Wait 2 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_2, + /** Wait 4 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_4, + /** Wait 8 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_8, + /** Wait 16 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_16, + /** Wait 32 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_32, + /** Wait 64 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_64, + /** Wait 128 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_128, + /** Wait 256 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_256, + /** Wait 512 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_512, + /** Wait 1024 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_1024, + /** Wait 2048 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_2048, + /** Wait 4096 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_4096, + /** Wait 8192 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_8192, + /** Wait 16384 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_16384, + /** Wait 32768 clock cycles until the clock source is considered stable */ + SYSTEM_XOSC_STARTUP_32768, +}; + +/** + * \brief Available start-up times for the OSC32K + * + * Available internal 32KHz oscillator start-up times, as a number of internal + * OSC32K clock cycles. + */ +enum system_osc32k_startup { + /** Wait 3 clock cycles until the clock source is considered stable */ + SYSTEM_OSC32K_STARTUP_3, + /** Wait 4 clock cycles until the clock source is considered stable */ + SYSTEM_OSC32K_STARTUP_4, + /** Wait 6 clock cycles until the clock source is considered stable */ + SYSTEM_OSC32K_STARTUP_6, + /** Wait 10 clock cycles until the clock source is considered stable */ + SYSTEM_OSC32K_STARTUP_10, + /** Wait 18 clock cycles until the clock source is considered stable */ + SYSTEM_OSC32K_STARTUP_18, + /** Wait 34 clock cycles until the clock source is considered stable */ + SYSTEM_OSC32K_STARTUP_34, + /** Wait 66 clock cycles until the clock source is considered stable */ + SYSTEM_OSC32K_STARTUP_66, + /** Wait 130 clock cycles until the clock source is considered stable */ + SYSTEM_OSC32K_STARTUP_130, +}; + +/** + * \brief Division prescalers for the internal 8MHz system clock + * + * Available prescalers for the internal 8MHz (nominal) system clock. + */ +enum system_osc8m_div { + /** Do not divide the 8MHz RC oscillator output */ + SYSTEM_OSC8M_DIV_1, + /** Divide the 8MHz RC oscillator output by 2 */ + SYSTEM_OSC8M_DIV_2, + /** Divide the 8MHz RC oscillator output by 4 */ + SYSTEM_OSC8M_DIV_4, + /** Divide the 8MHz RC oscillator output by 8 */ + SYSTEM_OSC8M_DIV_8, +}; + +/** + * \brief Frequency range for the internal 8Mhz RC oscillator + * + * Internal 8Mhz RC oscillator frequency range setting + */ +enum system_osc8m_frequency_range { + /** Frequency range 4 Mhz to 6 Mhz */ + SYSTEM_OSC8M_FREQUENCY_RANGE_4_TO_6, + /** Frequency range 6 Mhz to 8 Mhz */ + SYSTEM_OSC8M_FREQUENCY_RANGE_6_TO_8, + /** Frequency range 8 Mhz to 11 Mhz */ + SYSTEM_OSC8M_FREQUENCY_RANGE_8_TO_11, + /** Frequency range 11 Mhz to 15 Mhz */ + SYSTEM_OSC8M_FREQUENCY_RANGE_11_TO_15, +}; + +/** + * \brief Main CPU and APB/AHB bus clock source prescaler values + * + * Available division ratios for the CPU and APB/AHB bus clocks. + */ +enum system_main_clock_div { + /** Divide Main clock by 1 */ + SYSTEM_MAIN_CLOCK_DIV_1, + /** Divide Main clock by 2 */ + SYSTEM_MAIN_CLOCK_DIV_2, + /** Divide Main clock by 4 */ + SYSTEM_MAIN_CLOCK_DIV_4, + /** Divide Main clock by 8 */ + SYSTEM_MAIN_CLOCK_DIV_8, + /** Divide Main clock by 16 */ + SYSTEM_MAIN_CLOCK_DIV_16, + /** Divide Main clock by 32 */ + SYSTEM_MAIN_CLOCK_DIV_32, + /** Divide Main clock by 64 */ + SYSTEM_MAIN_CLOCK_DIV_64, + /** Divide Main clock by 128 */ + SYSTEM_MAIN_CLOCK_DIV_128, +}; + +/** + * \brief External clock source types. + * + * Available external clock source types. + */ +enum system_clock_external { + /** The external clock source is a crystal oscillator */ + SYSTEM_CLOCK_EXTERNAL_CRYSTAL, + /** The connected clock source is an external logic level clock signal */ + SYSTEM_CLOCK_EXTERNAL_CLOCK, +}; + +/** + * \brief Operating modes of the DFLL clock source. + * + * Available operating modes of the DFLL clock source module, + */ +enum system_clock_dfll_loop_mode { + /** The DFLL is operating in open loop mode with no feedback */ + SYSTEM_CLOCK_DFLL_LOOP_MODE_OPEN, + /** The DFLL is operating in closed loop mode with frequency feedback from + * a low frequency reference clock + */ + SYSTEM_CLOCK_DFLL_LOOP_MODE_CLOSED = SYSCTRL_DFLLCTRL_MODE, + +#ifdef SYSCTRL_DFLLCTRL_USBCRM + /** The DFLL is operating in USB recovery mode with frequency feedback + * from USB SOF + */ + SYSTEM_CLOCK_DFLL_LOOP_MODE_USB_RECOVERY = SYSCTRL_DFLLCTRL_USBCRM, +#endif +}; + +/** + * \brief Locking behavior for the DFLL during device wake-up + * + * DFLL lock behavior modes on device wake-up from sleep. + */ +enum system_clock_dfll_wakeup_lock { + /** Keep DFLL lock when the device wakes from sleep */ + SYSTEM_CLOCK_DFLL_WAKEUP_LOCK_KEEP, + /** Lose DFLL lock when the devices wakes from sleep */ + SYSTEM_CLOCK_DFLL_WAKEUP_LOCK_LOSE = SYSCTRL_DFLLCTRL_LLAW, +}; + +/** + * \brief Fine tracking behavior for the DFLL once a lock has been acquired + * + * DFLL fine tracking behavior modes after a lock has been acquired. + */ +enum system_clock_dfll_stable_tracking { + /** Keep tracking after the DFLL has gotten a fine lock */ + SYSTEM_CLOCK_DFLL_STABLE_TRACKING_TRACK_AFTER_LOCK, + /** Stop tracking after the DFLL has gotten a fine lock */ + SYSTEM_CLOCK_DFLL_STABLE_TRACKING_FIX_AFTER_LOCK = SYSCTRL_DFLLCTRL_STABLE, +}; + +/** + * \brief Chill-cycle behavior of the DFLL module + * + * DFLL chill-cycle behavior modes of the DFLL module. A chill cycle is a period + * of time when the DFLL output frequency is not measured by the unit, to allow + * the output to stabilize after a change in the input clock source. + */ +enum system_clock_dfll_chill_cycle { + /** Enable a chill cycle, where the DFLL output frequency is not measured */ + SYSTEM_CLOCK_DFLL_CHILL_CYCLE_ENABLE, + /** Disable a chill cycle, where the DFLL output frequency is not measured */ + SYSTEM_CLOCK_DFLL_CHILL_CYCLE_DISABLE = SYSCTRL_DFLLCTRL_CCDIS, +}; + +/** + * \brief QuickLock settings for the DFLL module + * + * DFLL QuickLock settings for the DFLL module, to allow for a faster lock of + * the DFLL output frequency at the expense of accuracy. + */ +enum system_clock_dfll_quick_lock { + /** Enable the QuickLock feature for looser lock requirements on the DFLL */ + SYSTEM_CLOCK_DFLL_QUICK_LOCK_ENABLE, + /** Disable the QuickLock feature for strict lock requirements on the DFLL */ + SYSTEM_CLOCK_DFLL_QUICK_LOCK_DISABLE = SYSCTRL_DFLLCTRL_QLDIS, +}; + +/** + * \brief Available clock sources in the system + * + * Clock sources available to the GCLK generators + */ +enum system_clock_source { + /** Internal 8MHz RC oscillator */ + SYSTEM_CLOCK_SOURCE_OSC8M = GCLK_SOURCE_OSC8M, + /** Internal 32kHz RC oscillator */ + SYSTEM_CLOCK_SOURCE_OSC32K = GCLK_SOURCE_OSC32K, + /** External oscillator */ + SYSTEM_CLOCK_SOURCE_XOSC = GCLK_SOURCE_XOSC , + /** External 32kHz oscillator */ + SYSTEM_CLOCK_SOURCE_XOSC32K = GCLK_SOURCE_XOSC32K, + /** Digital Frequency Locked Loop (DFLL) */ + SYSTEM_CLOCK_SOURCE_DFLL = GCLK_SOURCE_DFLL48M, + /** Internal Ultra Low Power 32kHz oscillator */ + SYSTEM_CLOCK_SOURCE_ULP32K = GCLK_SOURCE_OSCULP32K, + /** Generator input pad */ + SYSTEM_CLOCK_SOURCE_GCLKIN = GCLK_SOURCE_GCLKIN, + /** Generic clock generator 1 output */ + SYSTEM_CLOCK_SOURCE_GCLKGEN1 = GCLK_SOURCE_GCLKGEN1, +#ifdef FEATURE_SYSTEM_CLOCK_DPLL + /** Digital Phase Locked Loop (DPLL). + * Check \c FEATURE_SYSTEM_CLOCK_DPLL for which device support it. + */ + SYSTEM_CLOCK_SOURCE_DPLL = GCLK_SOURCE_FDPLL, +#endif +}; + +/** + * \brief List of APB peripheral buses + * + * Available bus clock domains on the APB bus. + */ +enum system_clock_apb_bus { + /** Peripheral bus A on the APB bus. */ + SYSTEM_CLOCK_APB_APBA, + /** Peripheral bus B on the APB bus. */ + SYSTEM_CLOCK_APB_APBB, + /** Peripheral bus C on the APB bus. */ + SYSTEM_CLOCK_APB_APBC, +}; + +/** + * \brief Configuration structure for XOSC + * + * External oscillator clock configuration structure. + */ +struct system_clock_source_xosc_config { + /** External clock type */ + enum system_clock_external external_clock; + /** Crystal oscillator start-up time */ + enum system_xosc_startup startup_time; + /** Enable automatic amplitude gain control */ + bool auto_gain_control; + /** External clock/crystal frequency */ + uint32_t frequency; + /** Keep the XOSC enabled in standby sleep mode */ + bool run_in_standby; + /** Run On Demand. If this is set the XOSC won't run + * until requested by a peripheral */ + bool on_demand; +}; + +/** + * \brief Configuration structure for XOSC32K + * + * External 32KHz oscillator clock configuration structure. + */ +struct system_clock_source_xosc32k_config { + /** External clock type */ + enum system_clock_external external_clock; + /** Crystal oscillator start-up time */ + enum system_xosc32k_startup startup_time; + /** Enable automatic amplitude control */ + bool auto_gain_control; + /** Enable 1kHz output */ + bool enable_1khz_output; + /** Enable 32kHz output */ + bool enable_32khz_output; + /** External clock/crystal frequency */ + uint32_t frequency; + /** Keep the XOSC32K enabled in standby sleep mode */ + bool run_in_standby; + /** Run On Demand. If this is set the XOSC32K won't run + * until requested by a peripheral */ + bool on_demand; + /** Lock configuration after it has been written, + * a device reset will release the lock */ + bool write_once; +}; + +/** + * \brief Configuration structure for OSC8M + * + * Internal 8MHz (nominal) oscillator configuration structure. + */ +struct system_clock_source_osc8m_config { + /* Internal 8MHz RC oscillator prescaler */ + enum system_osc8m_div prescaler; + /** Keep the OSC8M enabled in standby sleep mode */ + bool run_in_standby; + /** Run On Demand. If this is set the OSC8M won't run + * until requested by a peripheral */ + bool on_demand; +}; + +/** + * \brief Configuration structure for OSC32K + * + * Internal 32KHz (nominal) oscillator configuration structure. + */ +struct system_clock_source_osc32k_config { + /** Startup time */ + enum system_osc32k_startup startup_time; + /** Enable 1kHz output */ + bool enable_1khz_output; + /** Enable 32kHz output */ + bool enable_32khz_output; + /** Keep the OSC32K enabled in standby sleep mode */ + bool run_in_standby; + /** Run On Demand. If this is set the OSC32K won't run + * until requested by a peripheral */ + bool on_demand; + /** Lock configuration after it has been written, + * a device reset will release the lock */ + bool write_once; +}; + +/** + * \brief Configuration structure for DFLL + * + * DFLL oscillator configuration structure. + */ +struct system_clock_source_dfll_config { + /** Loop mode */ + enum system_clock_dfll_loop_mode loop_mode; + /** Run On Demand. If this is set the DFLL won't run + * until requested by a peripheral */ + bool on_demand; + /** Enable Quick Lock */ + enum system_clock_dfll_quick_lock quick_lock; + /** Enable Chill Cycle */ + enum system_clock_dfll_chill_cycle chill_cycle; + /** DFLL lock state on wakeup */ + enum system_clock_dfll_wakeup_lock wakeup_lock; + /** DFLL tracking after fine lock */ + enum system_clock_dfll_stable_tracking stable_tracking; + /** Coarse calibration value (Open loop mode) */ + uint8_t coarse_value; + /** Fine calibration value (Open loop mode) */ + uint16_t fine_value; + /** Coarse adjustment max step size (Closed loop mode) */ + uint8_t coarse_max_step; + /** Fine adjustment max step size (Closed loop mode) */ + uint16_t fine_max_step; + /** DFLL multiply factor (Closed loop mode */ + uint16_t multiply_factor; +}; + +/** + * \name External Oscillator management + * @{ + */ + +/** + * \brief Retrieve the default configuration for XOSC + * + * Fills a configuration structure with the default configuration for an + * external oscillator module: + * - External Crystal + * - Start-up time of 16384 external clock cycles + * - Automatic crystal gain control mode enabled + * - Frequency of 12MHz + * - Don't run in STANDBY sleep mode + * - Run only when requested by peripheral (on demand) + * + * \param[out] config Configuration structure to fill with default values + */ +static inline void system_clock_source_xosc_get_config_defaults( + struct system_clock_source_xosc_config *const config) +{ + Assert(config); + + config->external_clock = SYSTEM_CLOCK_EXTERNAL_CRYSTAL; + config->startup_time = SYSTEM_XOSC_STARTUP_16384; + config->auto_gain_control = true; + config->frequency = 12000000UL; + config->run_in_standby = false; + config->on_demand = true; +} + +void system_clock_source_xosc_set_config( + struct system_clock_source_xosc_config *const config); + +/** + * @} + */ + + +/** + * \name External 32KHz Oscillator management + * @{ + */ + +/** + * \brief Retrieve the default configuration for XOSC32K + * + * Fills a configuration structure with the default configuration for an + * external 32KHz oscillator module: + * - External Crystal + * - Start-up time of 16384 external clock cycles + * - Automatic crystal gain control mode disabled + * - Frequency of 32.768KHz + * - 1KHz clock output disabled + * - 32KHz clock output enabled + * - Don't run in STANDBY sleep mode + * - Run only when requested by peripheral (on demand) + * - Don't lock registers after configuration has been written + * + * \param[out] config Configuration structure to fill with default values + */ +static inline void system_clock_source_xosc32k_get_config_defaults( + struct system_clock_source_xosc32k_config *const config) +{ + Assert(config); + + config->external_clock = SYSTEM_CLOCK_EXTERNAL_CRYSTAL; + config->startup_time = SYSTEM_XOSC32K_STARTUP_16384; + config->auto_gain_control = false; + config->frequency = 32768UL; + config->enable_1khz_output = false; + config->enable_32khz_output = true; + config->run_in_standby = false; + config->on_demand = true; + config->write_once = false; +} + +void system_clock_source_xosc32k_set_config( + struct system_clock_source_xosc32k_config *const config); +/** + * @} + */ + + +/** + * \name Internal 32KHz Oscillator management + * @{ + */ + +/** + * \brief Retrieve the default configuration for OSC32K + * + * Fills a configuration structure with the default configuration for an + * internal 32KHz oscillator module: + * - 1KHz clock output enabled + * - 32KHz clock output enabled + * - Don't run in STANDBY sleep mode + * - Run only when requested by peripheral (on demand) + * - Set startup time to 130 cycles + * - Don't lock registers after configuration has been written + * + * \param[out] config Configuration structure to fill with default values + */ +static inline void system_clock_source_osc32k_get_config_defaults( + struct system_clock_source_osc32k_config *const config) +{ + Assert(config); + + config->enable_1khz_output = true; + config->enable_32khz_output = true; + config->run_in_standby = false; + config->on_demand = true; + config->startup_time = SYSTEM_OSC32K_STARTUP_130; + config->write_once = false; +} + +void system_clock_source_osc32k_set_config( + struct system_clock_source_osc32k_config *const config); + +/** + * @} + */ + + +/** + * \name Internal 8MHz Oscillator management + * @{ + */ + +/** + * \brief Retrieve the default configuration for OSC8M + * + * Fills a configuration structure with the default configuration for an + * internal 8MHz (nominal) oscillator module: + * - Clock output frequency divided by a factor of 8 + * - Don't run in STANDBY sleep mode + * - Run only when requested by peripheral (on demand) + * + * \param[out] config Configuration structure to fill with default values + */ +static inline void system_clock_source_osc8m_get_config_defaults( + struct system_clock_source_osc8m_config *const config) +{ + Assert(config); + + config->prescaler = SYSTEM_OSC8M_DIV_8; + config->run_in_standby = false; + config->on_demand = true; +} + +void system_clock_source_osc8m_set_config( + struct system_clock_source_osc8m_config *const config); + +/** + * @} + */ + + +/** + * \name Internal DFLL management + * @{ + */ + +/** + * \brief Retrieve the default configuration for DFLL + * + * Fills a configuration structure with the default configuration for a + * DFLL oscillator module: + * - Open loop mode + * - QuickLock mode enabled + * - Chill cycle enabled + * - Output frequency lock maintained during device wake-up + * - Continuous tracking of the output frequency + * - Default tracking values at the mid-points for both coarse and fine + * tracking parameters + * - Don't run in STANDBY sleep mode + * - Run only when requested by peripheral (on demand) + * + * \param[out] config Configuration structure to fill with default values + */ +static inline void system_clock_source_dfll_get_config_defaults( + struct system_clock_source_dfll_config *const config) +{ + Assert(config); + + config->loop_mode = SYSTEM_CLOCK_DFLL_LOOP_MODE_OPEN; + config->quick_lock = SYSTEM_CLOCK_DFLL_QUICK_LOCK_ENABLE; + config->chill_cycle = SYSTEM_CLOCK_DFLL_CHILL_CYCLE_ENABLE; + config->wakeup_lock = SYSTEM_CLOCK_DFLL_WAKEUP_LOCK_KEEP; + config->stable_tracking = SYSTEM_CLOCK_DFLL_STABLE_TRACKING_TRACK_AFTER_LOCK; + config->on_demand = true; + + /* Open loop mode calibration value */ + config->coarse_value = 0x1f / 4; /* Midpoint */ + config->fine_value = 0xff / 4; /* Midpoint */ + + /* Closed loop mode */ + config->coarse_max_step = 1; + config->fine_max_step = 1; + config->multiply_factor = 6; /* Multiply 8MHz by 6 to get 48MHz */ +} + +void system_clock_source_dfll_set_config( + struct system_clock_source_dfll_config *const config); + +/** + * @} + */ + +/** + * \name Clock source management + * @{ + */ +enum status_code system_clock_source_write_calibration( + const enum system_clock_source system_clock_source, + const uint16_t calibration_value, + const uint8_t freq_range); + +enum status_code system_clock_source_enable( + const enum system_clock_source system_clock_source); + +enum status_code system_clock_source_disable( + const enum system_clock_source clk_source); + +bool system_clock_source_is_ready( + const enum system_clock_source clk_source); + +uint32_t system_clock_source_get_hz( + const enum system_clock_source clk_source); + +/** + * @} + */ + +/** + * \name Main clock management + * @{ + */ + +#ifdef FEATURE_SYSTEM_CLOCK_FAILURE_DETECT +/** + * \brief Enable or disable the main clock failure detection. + * + * This mechanism allows switching automatically the main clock to the safe + * RCSYS clock, when the main clock source is considered off. + * + * This may happen for instance when an external crystal is selected as the + * clock source of the main clock and the crystal dies. The mechanism is to + * detect, during a RCSYS period, at least one rising edge of the main clock. + * If no rising edge is seen the clock is considered failed. + * As soon as the detector is enabled, the clock failure detector + * CFD) will monitor the divided main clock. When a clock failure is detected, + * the main clock automatically switches to the RCSYS clock and the CFD + * interrupt is generated if enabled. + * + * \note The failure detect must be disabled if the system clock is the same or + * slower than 32kHz as it will believe the system clock has failed with + * a too-slow clock. + * + * \param[in] enable Boolean \c true to enable, \c false to disable detection + */ +static inline void system_main_clock_set_failure_detect( + const bool enable) +{ + if (enable) { + PM->CTRL.reg |= PM_CTRL_CFDEN; + } else { + PM->CTRL.reg &= ~PM_CTRL_CFDEN; + } +} +#endif + +/** + * \brief Set main CPU clock divider. + * + * Sets the clock divider used on the main clock to provide the CPU clock. + * + * \param[in] divider CPU clock divider to set + */ +static inline void system_cpu_clock_set_divider( + const enum system_main_clock_div divider) +{ + Assert(((uint32_t)divider & PM_CPUSEL_CPUDIV_Msk) == divider); + PM->CPUSEL.reg = (uint32_t)divider; +} + +/** + * \brief Retrieves the current frequency of the CPU core. + * + * Retrieves the operating frequency of the CPU core, obtained from the main + * generic clock and the set CPU bus divider. + * + * \return Current CPU frequency in Hz. + */ +static inline uint32_t system_cpu_clock_get_hz(void) +{ + return (system_gclk_gen_get_hz(GCLK_GENERATOR_0) >> PM->CPUSEL.reg); +} + +/** + * \brief Set APBx clock divider. + * + * Set the clock divider used on the main clock to provide the clock for the + * given APBx bus. + * + * \param[in] divider APBx bus divider to set + * \param[in] bus APBx bus to set divider for + * + * \returns Status of the clock division change operation. + * + * \retval STATUS_ERR_INVALID_ARG Invalid bus ID was given + * \retval STATUS_OK The APBx clock was set successfully + */ +static inline enum status_code system_apb_clock_set_divider( + const enum system_clock_apb_bus bus, + const enum system_main_clock_div divider) +{ + switch (bus) { + case SYSTEM_CLOCK_APB_APBA: + PM->APBASEL.reg = (uint32_t)divider; + break; + case SYSTEM_CLOCK_APB_APBB: + PM->APBBSEL.reg = (uint32_t)divider; + break; + case SYSTEM_CLOCK_APB_APBC: + PM->APBCSEL.reg = (uint32_t)divider; + break; + default: + Assert(false); + return STATUS_ERR_INVALID_ARG; + } + + return STATUS_OK; +} + +/** + * \brief Retrieves the current frequency of a ABPx. + * + * Retrieves the operating frequency of an APBx bus, obtained from the main + * generic clock and the set APBx bus divider. + * + * \return Current APBx bus frequency in Hz. + */ +static inline uint32_t system_apb_clock_get_hz( + const enum system_clock_apb_bus bus) +{ + uint16_t bus_divider = 0; + + switch (bus) { + case SYSTEM_CLOCK_APB_APBA: + bus_divider = PM->APBASEL.reg; + break; + case SYSTEM_CLOCK_APB_APBB: + bus_divider = PM->APBBSEL.reg; + break; + case SYSTEM_CLOCK_APB_APBC: + bus_divider = PM->APBCSEL.reg; + break; + default: + Assert(false); + return 0; + } + + return (system_gclk_gen_get_hz(GCLK_GENERATOR_0) >> bus_divider); +} + + +/** + * @} + */ + +/** + * \name Bus clock masking + * @{ + */ + +/** + * \brief Set bits in the clock mask for the AHB bus. + * + * This function will set bits in the clock mask for the AHB bus. + * Any bits set to 1 will enable that clock, 0 bits in the mask + * will be ignored + * + * \param[in] ahb_mask AHB clock mask to enable + */ +static inline void system_ahb_clock_set_mask( + const uint32_t ahb_mask) +{ + PM->AHBMASK.reg |= ahb_mask; +} + +/** + * \brief Clear bits in the clock mask for the AHB bus. + * + * This function will clear bits in the clock mask for the AHB bus. + * Any bits set to 1 will disable that clock, 0 bits in the mask + * will be ignored. + * + * \param[in] ahb_mask AHB clock mask to disable + */ +static inline void system_ahb_clock_clear_mask( + const uint32_t ahb_mask) +{ + PM->AHBMASK.reg &= ~ahb_mask; +} + +/** + * \brief Set bits in the clock mask for an APBx bus. + * + * This function will set bits in the clock mask for an APBx bus. + * Any bits set to 1 will enable the corresponding module clock, zero bits in + * the mask will be ignored. + * + * \param[in] mask APBx clock mask, a \c SYSTEM_CLOCK_APB_APBx constant from + * the device header files + * \param[in] bus Bus to set clock mask bits for, a mask of \c PM_APBxMASK_* + * constants from the device header files + * + * \returns Status indicating the result of the clock mask change operation. + * + * \retval STATUS_ERR_INVALID_ARG Invalid bus given + * \retval STATUS_OK The clock mask was set successfully + */ +static inline enum status_code system_apb_clock_set_mask( + const enum system_clock_apb_bus bus, + const uint32_t mask) +{ + switch (bus) { + case SYSTEM_CLOCK_APB_APBA: + PM->APBAMASK.reg |= mask; + break; + + case SYSTEM_CLOCK_APB_APBB: + PM->APBBMASK.reg |= mask; + break; + + case SYSTEM_CLOCK_APB_APBC: + PM->APBCMASK.reg |= mask; + break; + + default: + Assert(false); + return STATUS_ERR_INVALID_ARG; + + } + + return STATUS_OK; +} + +/** + * \brief Clear bits in the clock mask for an APBx bus. + * + * This function will clear bits in the clock mask for an APBx bus. + * Any bits set to 1 will disable the corresponding module clock, zero bits in + * the mask will be ignored. + * + * \param[in] mask APBx clock mask, a \c SYSTEM_CLOCK_APB_APBx constant from + * the device header files + * \param[in] bus Bus to clear clock mask bits for + * + * \returns Status indicating the result of the clock mask change operation. + * + * \retval STATUS_ERR_INVALID_ARG Invalid bus ID was given. + * \retval STATUS_OK The clock mask was changed successfully. + */ +static inline enum status_code system_apb_clock_clear_mask( + const enum system_clock_apb_bus bus, + const uint32_t mask) +{ + switch (bus) { + case SYSTEM_CLOCK_APB_APBA: + PM->APBAMASK.reg &= ~mask; + break; + + case SYSTEM_CLOCK_APB_APBB: + PM->APBBMASK.reg &= ~mask; + break; + + case SYSTEM_CLOCK_APB_APBC: + PM->APBCMASK.reg &= ~mask; + break; + + default: + Assert(false); + return STATUS_ERR_INVALID_ARG; + } + + return STATUS_OK; +} + +/** + * @} + */ + +#ifdef FEATURE_SYSTEM_CLOCK_DPLL +/** + * \brief Reference clock source of the DPLL module + */ +enum system_clock_source_dpll_reference_clock { + /** Select CLK_DPLL_REF0 as clock reference */ + SYSTEM_CLOCK_SOURCE_DPLL_REFERENCE_CLOCK_REF0, + /** Select CLK_DPLL_REF1 as clock reference */ + SYSTEM_CLOCK_SOURCE_DPLL_REFERENCE_CLOCK_REF1, + /** Select GCLK_DPLL as clock reference */ + SYSTEM_CLOCK_SOURCE_DPLL_REFERENCE_CLOCK_GCLK, +}; + +/** + * \brief Lock time-out value of the DPLL module + */ +enum system_clock_source_dpll_lock_time { + /** Set no time-out as default */ + SYSTEM_CLOCK_SOURCE_DPLL_LOCK_TIME_DEFAULT, + /** Set time-out if no lock within 8 ms */ + SYSTEM_CLOCK_SOURCE_DPLL_LOCK_TIME_8MS = 0x04, + /** Set time-out if no lock within 9 ms */ + SYSTEM_CLOCK_SOURCE_DPLL_LOCK_TIME_9MS, + /** Set time-out if no lock within 10 ms */ + SYSTEM_CLOCK_SOURCE_DPLL_LOCK_TIME_10MS, + /** Set time-out if no lock within 11 ms */ + SYSTEM_CLOCK_SOURCE_DPLL_LOCK_TIME_11MS, +}; + +/** + * \brief Filter type of the DPLL module + */ +enum system_clock_source_dpll_filter { + /** Default filter mode */ + SYSTEM_CLOCK_SOURCE_DPLL_FILTER_DEFAULT, + /** Low bandwidth filter */ + SYSTEM_CLOCK_SOURCE_DPLL_FILTER_LOW_BANDWIDTH_FILTER, + /** High bandwidth filter */ + SYSTEM_CLOCK_SOURCE_DPLL_FILTER_HIGH_BANDWIDTH_FILTER, + /** High damping filter */ + SYSTEM_CLOCK_SOURCE_DPLL_FILTER_HIGH_DAMPING_FILTER, +}; + +/** + * \brief Configuration structure for DPLL + * + * DPLL oscillator configuration structure. + */ +struct system_clock_source_dpll_config { + /** Run On Demand. If this is set the DPLL won't run + * until requested by a peripheral */ + bool on_demand; + /** Keep the DPLL enabled in standby sleep mode */ + bool run_in_standby; + /** Bypass lock signal */ + bool lock_bypass; + /** Wake up fast. If this is set DPLL output clock is enabled after + * the startup time */ + bool wake_up_fast; + /** Enable low power mode */ + bool low_power_enable; + + /** Output frequency of the clock */ + uint32_t output_frequency; + /** Reference frequency of the clock */ + uint32_t reference_frequency; + /** Devider of reference clock */ + uint16_t reference_divider; + + /** Filter type of the DPLL module */ + enum system_clock_source_dpll_filter filter; + /** Lock time-out value of the DPLL module */ + enum system_clock_source_dpll_lock_time lock_time; + /** Reference clock source of the DPLL module */ + enum system_clock_source_dpll_reference_clock reference_clock; +}; + +/** + * \name Internal DPLL management + * @{ + */ + +/** + * \brief Retrieve the default configuration for DPLL + * + * Fills a configuration structure with the default configuration for a + * DPLL oscillator module: + * - Run only when requested by peripheral (on demand) + * - Don't run in STANDBY sleep mode + * - Lock bypass disabled + * - Fast wake up disabled + * - Low power mode disabled + * - Output frequency is 48MHz + * - Reference clock frequency is 32768Hz + * - Not divide reference clock + * - Select REF0 as reference clock + * - Set lock time to default mode + * - Use default filter + * + * \param[out] config Configuration structure to fill with default values + */ +static inline void system_clock_source_dpll_get_config_defaults( + struct system_clock_source_dpll_config *const config) +{ + config->on_demand = true; + config->run_in_standby = false; + config->lock_bypass = false; + config->wake_up_fast = false; + config->low_power_enable = false; + + config->output_frequency = 48000000; + config->reference_frequency = 32768; + config->reference_divider = 1; + config->reference_clock = SYSTEM_CLOCK_SOURCE_DPLL_REFERENCE_CLOCK_REF0; + + config->lock_time = SYSTEM_CLOCK_SOURCE_DPLL_LOCK_TIME_DEFAULT; + config->filter = SYSTEM_CLOCK_SOURCE_DPLL_FILTER_DEFAULT; +}; + +void system_clock_source_dpll_set_config( + struct system_clock_source_dpll_config *const config); + +/* @} */ +#endif + +/** + * \name System Clock Initialization + * @{ + */ + +void system_clock_init(void); + +/** + * @} + */ + +/** + * \name System Flash Wait States + * @{ + */ + +/** + * \brief Set flash controller wait states + * + * Will set the number of wait states that are used by the onboard + * flash memory. The number of wait states depend on both device + * supply voltage and CPU speed. The required number of wait states + * can be found in the electrical characteristics of the device. + * + * \param[in] wait_states Number of wait states to use for internal flash + */ +static inline void system_flash_set_waitstates(uint8_t wait_states) +{ + Assert(NVMCTRL_CTRLB_RWS((uint32_t)wait_states) == + ((uint32_t)wait_states << NVMCTRL_CTRLB_RWS_Pos)); + + NVMCTRL->CTRLB.bit.RWS = wait_states; +} +/** + * @} + */ + +/** + * @} + */ + +/** + * \page asfdoc_sam0_system_clock_extra Extra Information for SYSTEM CLOCK Driver + * + * \section asfdoc_sam0_system_clock_extra_acronyms Acronyms + * Below is a table listing the acronyms used in this module, along with their + * intended meanings. + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
AcronymDescription
DFLLDigital Frequency Locked Loop
MUXMultiplexer
OSC32KInternal 32KHz Oscillator
OSC8MInternal 8MHz Oscillator
PLLPhase Locked Loop
OSCOscillator
XOSCExternal Oscillator
XOSC32KExternal 32KHz Oscillator
AHBAdvanced High-performance Bus
APBAdvanced Peripheral Bus
DPLLDigital Phase Locked Loop
+ * + * + * \section asfdoc_sam0_system_clock_extra_dependencies Dependencies + * This driver has the following dependencies: + * + * - None + * + * + * \section asfdoc_sam0_system_clock_extra_errata Errata + * + * - This driver implements workaround for errata 10558 + * + * "Several reset values of SYSCTRL.INTFLAG are wrong (BOD and DFLL)" + * When system_init is called it will reset these interrupts flags before they are used. + + * - This driver implements experimental workaround for errata 9905 + * + * "The DFLL clock must be requested before being configured otherwise a + * write access to a DFLL register can freeze the device." + * This driver will enable and configure the DFLL before the ONDEMAND bit is set. + * + * + * \section asfdoc_sam0_system_clock_extra_history Module History + * An overview of the module history is presented in the table below, with + * details on the enhancements and fixes made to the module since its first + * release. The current version of this corresponds to the newest version in + * the table. + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Changelog
+ * \li Corrected OSC32K startup time definitions. + * \li Support locking of OSC32K and XOSC32K config register (default: false). + * \li Added DPLL support, functions added: + * \c system_clock_source_dpll_get_config_defaults() and + * \c system_clock_source_dpll_set_config(). + * \li Moved gclk channel locking feature out of the config struct, + * functions added: + * \c system_gclk_chan_lock(), + * \c system_gclk_chan_is_locked(), + * \c system_gclk_chan_is_enabled() and + * \c system_gclk_gen_is_enabled(). + *
Fixed \c system_gclk_chan_disable() deadlocking if a channel is enabled + * and configured to a failed/not running clock generator.
+ * \li Changed default value for CONF_CLOCK_DFLL_ON_DEMAND from \c true to \c false. + * \li Fixed system_flash_set_waitstates() failing with an assertion + * if an odd number of wait states provided. + *
+ * \li Updated dfll configuration function to implement workaround for + * errata 9905 in the DFLL module. + * \li Updated \c system_clock_init() to reset interrupt flags before + * they are used, errata 10558. + * \li Fixed \c system_clock_source_get_hz() to return correcy DFLL + * frequency number. + *
\li Fixed \c system_clock_source_is_ready not returning the correct + * state for \c SYSTEM_CLOCK_SOURCE_OSC8M. + * \li Renamed the various \c system_clock_source_*_get_default_config() + * functions to \c system_clock_source_*_get_config_defaults() to + * match the remainder of ASF. + * \li Added OSC8M calibration constant loading from the device signature + * row when the oscillator is initialized. + * \li Updated default configuration of the XOSC32 to disable Automatic + * Gain Control due to silicon errata. + *
Initial Release
+ */ + +/** + * \page asfdoc_sam0_system_clock_exqsg Examples for System Clock Driver + * + * This is a list of the available Quick Start guides (QSGs) and example + * applications for \ref asfdoc_sam0_system_clock_group. QSGs are simple + * examples with step-by-step instructions to configure and use this driver in + * a selection of use cases. Note that QSGs can be compiled as a standalone + * application or be added to the user application. + * + * - \subpage asfdoc_sam0_system_clock_basic_use_case + * - \subpage asfdoc_sam0_system_gclk_basic_use_case + * + * \page asfdoc_sam0_system_clock_document_revision_history Document Revision History + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Doc. Rev. + * Date + * Comments + *
E04/2014Added support for SAMD10/D11.
D02/2014Added support for SAMR21.
C01/2014Added support for SAMD21.
B06/2013Corrected documentation typos. Fixed missing steps in the Basic + * Use Case Quick Start Guide.
A06/2013Initial release
+ */ + +#ifdef __cplusplus +} +#endif + +#endif /* SYSTEM_CLOCK_H_INCLUDED */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/clock_samd21_r21/clock.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/clock_samd21_r21/clock.c new file mode 100755 index 0000000..281914f --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/clock_samd21_r21/clock.c @@ -0,0 +1,963 @@ +/** + * \file + * + * \brief SAM D21/R21 Clock Driver + * + * Copyright (C) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include +#include +#include + +#ifndef SYSCTRL_FUSES_OSC32K_ADDR +# define SYSCTRL_FUSES_OSC32K_ADDR SYSCTRL_FUSES_OSC32K_CAL_ADDR +# define SYSCTRL_FUSES_OSC32K_Pos SYSCTRL_FUSES_OSC32K_CAL_Pos +#endif + +/** + * \internal + * \brief DFLL-specific data container + */ +struct _system_clock_dfll_config { + uint32_t control; + uint32_t val; + uint32_t mul; +}; + +/** + * \internal + * \brief DPLL-specific data container + */ +struct _system_clock_dpll_config { + uint32_t frequency; +}; + + +/** + * \internal + * \brief XOSC-specific data container + */ +struct _system_clock_xosc_config { + uint32_t frequency; +}; + +/** + * \internal + * \brief System clock module data container + */ +struct _system_clock_module { + volatile struct _system_clock_dfll_config dfll; + +#ifdef FEATURE_SYSTEM_CLOCK_DPLL + volatile struct _system_clock_dpll_config dpll; +#endif + + volatile struct _system_clock_xosc_config xosc; + volatile struct _system_clock_xosc_config xosc32k; +}; + +/** + * \internal + * \brief Internal module instance to cache configuration values + */ +static struct _system_clock_module _system_clock_inst = { + .dfll = { + .control = 0, + .val = 0, + .mul = 0, + }, + +#ifdef FEATURE_SYSTEM_CLOCK_DPLL + .dpll = { + .frequency = 0, + }, +#endif + .xosc = { + .frequency = 0, + }, + .xosc32k = { + .frequency = 0, + }, + }; + +/** + * \internal + * \brief Wait for sync to the DFLL control registers + */ +static inline void _system_dfll_wait_for_sync(void) +{ + while (!(SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_DFLLRDY)) { + /* Wait for DFLL sync */ + } +} + +/** + * \internal + * \brief Wait for sync to the OSC32K control registers + */ +static inline void _system_osc32k_wait_for_sync(void) +{ + while (!(SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_OSC32KRDY)) { + /* Wait for OSC32K sync */ + } +} + +static inline void _system_clock_source_dfll_set_config_errata_9905(void) +{ + + /* Disable ONDEMAND mode while writing configurations */ + SYSCTRL->DFLLCTRL.reg = _system_clock_inst.dfll.control & ~SYSCTRL_DFLLCTRL_ONDEMAND; + _system_dfll_wait_for_sync(); + + SYSCTRL->DFLLMUL.reg = _system_clock_inst.dfll.mul; + SYSCTRL->DFLLVAL.reg = _system_clock_inst.dfll.val; + + /* Write full configuration to DFLL control register */ + SYSCTRL->DFLLCTRL.reg = _system_clock_inst.dfll.control; +} + +/** + * \brief Retrieve the frequency of a clock source + * + * Determines the current operating frequency of a given clock source. + * + * \param[in] clock_source Clock source to get the frequency of + * + * \returns Frequency of the given clock source, in Hz + */ +uint32_t system_clock_source_get_hz( + const enum system_clock_source clock_source) +{ + switch (clock_source) { + case SYSTEM_CLOCK_SOURCE_XOSC: + return _system_clock_inst.xosc.frequency; + + case SYSTEM_CLOCK_SOURCE_OSC8M: + return 8000000UL >> SYSCTRL->OSC8M.bit.PRESC; + + case SYSTEM_CLOCK_SOURCE_OSC32K: + return 32768UL; + + case SYSTEM_CLOCK_SOURCE_ULP32K: + return 32768UL; + + case SYSTEM_CLOCK_SOURCE_XOSC32K: + return _system_clock_inst.xosc32k.frequency; + + case SYSTEM_CLOCK_SOURCE_DFLL: + + /* Check if the DFLL has been configured */ + if (!(_system_clock_inst.dfll.control & SYSCTRL_DFLLCTRL_ENABLE)) + return 0; + + /* Make sure that the DFLL module is ready */ + _system_dfll_wait_for_sync(); + + /* Check if operating in closed loop mode */ + if (_system_clock_inst.dfll.control & SYSCTRL_DFLLCTRL_MODE) { + return system_gclk_chan_get_hz(SYSCTRL_GCLK_ID_DFLL48) * + (_system_clock_inst.dfll.mul & 0xffff); + } + + return 48000000UL; + +#ifdef FEATURE_SYSTEM_CLOCK_DPLL + case SYSTEM_CLOCK_SOURCE_DPLL: + if (!(SYSCTRL->DPLLSTATUS.reg & SYSCTRL_DPLLSTATUS_ENABLE)) { + return 0; + } + + return _system_clock_inst.dpll.frequency; +#endif + + default: + return 0; + } +} + +/** + * \brief Configure the internal OSC8M oscillator clock source + * + * Configures the 8MHz (nominal) internal RC oscillator with the given + * configuration settings. + * + * \param[in] config OSC8M configuration structure containing the new config + */ +void system_clock_source_osc8m_set_config( + struct system_clock_source_osc8m_config *const config) +{ + SYSCTRL_OSC8M_Type temp = SYSCTRL->OSC8M; + + /* Use temporary struct to reduce register access */ + temp.bit.PRESC = config->prescaler; + temp.bit.ONDEMAND = config->on_demand; + temp.bit.RUNSTDBY = config->run_in_standby; + + SYSCTRL->OSC8M = temp; +} + +/** + * \brief Configure the internal OSC32K oscillator clock source + * + * Configures the 32KHz (nominal) internal RC oscillator with the given + * configuration settings. + * + * \param[in] config OSC32K configuration structure containing the new config + */ +void system_clock_source_osc32k_set_config( + struct system_clock_source_osc32k_config *const config) +{ + SYSCTRL_OSC32K_Type temp = SYSCTRL->OSC32K; + + /* Update settings via a temporary struct to reduce register access */ + temp.bit.EN1K = config->enable_1khz_output; + temp.bit.EN32K = config->enable_32khz_output; + temp.bit.STARTUP = config->startup_time; + temp.bit.ONDEMAND = config->on_demand; + temp.bit.RUNSTDBY = config->run_in_standby; + temp.bit.WRTLOCK = config->write_once; + + SYSCTRL->OSC32K = temp; +} + +/** + * \brief Configure the external oscillator clock source + * + * Configures the external oscillator clock source with the given configuration + * settings. + * + * \param[in] config External oscillator configuration structure containing + * the new config + */ +void system_clock_source_xosc_set_config( + struct system_clock_source_xosc_config *const config) +{ + SYSCTRL_XOSC_Type temp = SYSCTRL->XOSC; + + temp.bit.STARTUP = config->startup_time; + + if (config->external_clock == SYSTEM_CLOCK_EXTERNAL_CRYSTAL) { + temp.bit.XTALEN = 1; + } else { + temp.bit.XTALEN = 0; + } + + temp.bit.AMPGC = config->auto_gain_control; + + /* Set gain if automatic gain control is not selected */ + if (!config->auto_gain_control) { + if (config->frequency <= 2000000) { + temp.bit.GAIN = 0; + } else if (config->frequency <= 4000000) { + temp.bit.GAIN = 1; + } else if (config->frequency <= 8000000) { + temp.bit.GAIN = 2; + } else if (config->frequency <= 16000000) { + temp.bit.GAIN = 3; + } else if (config->frequency <= 30000000) { + temp.bit.GAIN = 4; + } + + } + + temp.bit.ONDEMAND = config->on_demand; + temp.bit.RUNSTDBY = config->run_in_standby; + + /* Store XOSC frequency for internal use */ + _system_clock_inst.xosc.frequency = config->frequency; + + SYSCTRL->XOSC = temp; +} + +/** + * \brief Configure the XOSC32K external 32KHz oscillator clock source + * + * Configures the external 32KHz oscillator clock source with the given + * configuration settings. + * + * \param[in] config XOSC32K configuration structure containing the new config + */ +void system_clock_source_xosc32k_set_config( + struct system_clock_source_xosc32k_config *const config) +{ + SYSCTRL_XOSC32K_Type temp = SYSCTRL->XOSC32K; + + temp.bit.STARTUP = config->startup_time; + + if (config->external_clock == SYSTEM_CLOCK_EXTERNAL_CRYSTAL) { + temp.bit.XTALEN = 1; + } else { + temp.bit.XTALEN = 0; + } + + temp.bit.AAMPEN = config->auto_gain_control; + temp.bit.EN1K = config->enable_1khz_output; + temp.bit.EN32K = config->enable_32khz_output; + + temp.bit.ONDEMAND = config->on_demand; + temp.bit.RUNSTDBY = config->run_in_standby; + temp.bit.WRTLOCK = config->write_once; + + /* Cache the new frequency in case the user needs to check the current + * operating frequency later */ + _system_clock_inst.xosc32k.frequency = config->frequency; + + SYSCTRL->XOSC32K = temp; +} + +/** + * \brief Configure the DFLL clock source + * + * Configures the Digital Frequency Locked Loop clock source with the given + * configuration settings. + * + * \note The DFLL will be running when this function returns, as the DFLL module + * needs to be enabled in order to perform the module configuration. + * + * \param[in] config DFLL configuration structure containing the new config + */ +void system_clock_source_dfll_set_config( + struct system_clock_source_dfll_config *const config) +{ + _system_clock_inst.dfll.val = + SYSCTRL_DFLLVAL_COARSE(config->coarse_value) | + SYSCTRL_DFLLVAL_FINE(config->fine_value); + + _system_clock_inst.dfll.control = + (uint32_t)config->wakeup_lock | + (uint32_t)config->stable_tracking | + (uint32_t)config->quick_lock | + (uint32_t)config->chill_cycle | + ((uint32_t)config->on_demand << SYSCTRL_DFLLCTRL_ONDEMAND_Pos); + + if (config->loop_mode == SYSTEM_CLOCK_DFLL_LOOP_MODE_CLOSED) { + + _system_clock_inst.dfll.mul = + SYSCTRL_DFLLMUL_CSTEP(config->coarse_max_step) | + SYSCTRL_DFLLMUL_FSTEP(config->fine_max_step) | + SYSCTRL_DFLLMUL_MUL(config->multiply_factor); + + /* Enable the closed loop mode */ + _system_clock_inst.dfll.control |= config->loop_mode; + } + if (config->loop_mode == SYSTEM_CLOCK_DFLL_LOOP_MODE_USB_RECOVERY) { + + _system_clock_inst.dfll.mul = + SYSCTRL_DFLLMUL_MUL(config->multiply_factor); + + /* Enable the USB recovery mode */ + _system_clock_inst.dfll.control |= config->loop_mode | + SYSCTRL_DFLLCTRL_BPLCKC; + } +} + +#ifdef FEATURE_SYSTEM_CLOCK_DPLL +/** + * \brief Configure the DPLL clock source + * + * Configures the Digital Phase-Locked Loop clock source with the given + * configuration settings. + * + * \note The DPLL will be running when this function returns, as the DPLL module + * needs to be enabled in order to perform the module configuration. + * + * \param[in] config DPLL configuration structure containing the new config + */ +void system_clock_source_dpll_set_config( + struct system_clock_source_dpll_config *const config) +{ + + uint32_t tmpldr; + uint8_t tmpldrfrac; + uint32_t refclk; + + refclk = config->reference_frequency; + + /* Only reference clock REF1 can be divided */ + if (config->reference_clock == SYSTEM_CLOCK_SOURCE_DPLL_REFERENCE_CLOCK_REF1) { + refclk = refclk / config->reference_divider; + } + + /* Calculate LDRFRAC and LDR */ + tmpldr = (config->output_frequency << 4) / refclk; + tmpldrfrac = tmpldr & 0x0f; + tmpldr = (tmpldr >> 4) - 1; + + SYSCTRL->DPLLCTRLA.reg = + ((uint32_t)config->on_demand << SYSCTRL_DPLLCTRLA_ONDEMAND_Pos) | + ((uint32_t)config->run_in_standby << SYSCTRL_DPLLCTRLA_RUNSTDBY_Pos); + + SYSCTRL->DPLLRATIO.reg = + SYSCTRL_DPLLRATIO_LDRFRAC(tmpldrfrac) | + SYSCTRL_DPLLRATIO_LDR(tmpldr); + + SYSCTRL->DPLLCTRLB.reg = + SYSCTRL_DPLLCTRLB_DIV(config->reference_divider) | + ((uint32_t)config->lock_bypass << SYSCTRL_DPLLCTRLB_LBYPASS_Pos) | + SYSCTRL_DPLLCTRLB_LTIME(config->lock_time) | + SYSCTRL_DPLLCTRLB_REFCLK(config->reference_clock) | + ((uint32_t)config->wake_up_fast << SYSCTRL_DPLLCTRLB_WUF_Pos) | + ((uint32_t)config->low_power_enable << SYSCTRL_DPLLCTRLB_LPEN_Pos) | + SYSCTRL_DPLLCTRLB_FILTER(config->filter); + + /* + * Fck = Fckrx * (LDR + 1 + LDRFRAC / 16) + */ + _system_clock_inst.dpll.frequency = + (config->reference_frequency * + (((tmpldr + 1) << 4) + tmpldrfrac) + ) >> 4; +} +#endif + +/** + * \brief Writes the calibration values for a given oscillator clock source + * + * Writes an oscillator calibration value to the given oscillator control + * registers. The acceptable ranges are: + * + * For OSC32K: + * - 7 bits (max value 128) + * For OSC8MHZ: + * - 8 bits (Max value 255) + * For OSCULP: + * - 5 bits (Max value 32) + * + * \note The frequency range parameter applies only when configuring the 8MHz + * oscillator and will be ignored for the other oscillators. + * + * \param[in] clock_source Clock source to calibrate + * \param[in] calibration_value Calibration value to write + * \param[in] freq_range Frequency range (8MHz oscillator only) + * + * \retval STATUS_OK The calibration value was written + * successfully. + * \retval STATUS_ERR_INVALID_ARG The setting is not valid for selected clock + * source. + */ +enum status_code system_clock_source_write_calibration( + const enum system_clock_source clock_source, + const uint16_t calibration_value, + const uint8_t freq_range) +{ + switch (clock_source) { + case SYSTEM_CLOCK_SOURCE_OSC8M: + + if (calibration_value > 0xfff || freq_range > 4) { + return STATUS_ERR_INVALID_ARG; + } + + SYSCTRL->OSC8M.bit.CALIB = calibration_value; + SYSCTRL->OSC8M.bit.FRANGE = freq_range; + break; + + case SYSTEM_CLOCK_SOURCE_OSC32K: + + if (calibration_value > 128) { + return STATUS_ERR_INVALID_ARG; + } + + _system_osc32k_wait_for_sync(); + SYSCTRL->OSC32K.bit.CALIB = calibration_value; + break; + + case SYSTEM_CLOCK_SOURCE_ULP32K: + + if (calibration_value > 32) { + return STATUS_ERR_INVALID_ARG; + } + + SYSCTRL->OSCULP32K.bit.CALIB = calibration_value; + break; + + default: + Assert(false); + return STATUS_ERR_INVALID_ARG; + break; + } + + return STATUS_OK; +} + +/** + * \brief Enables a clock source + * + * Enables a clock source which has been previously configured. + * + * \param[in] clock_source Clock source to enable + * + * \retval STATUS_OK Clock source was enabled successfully and + * is ready + * \retval STATUS_ERR_INVALID_ARG The clock source is not available on this + * device + */ +enum status_code system_clock_source_enable( + const enum system_clock_source clock_source) +{ + switch (clock_source) { + case SYSTEM_CLOCK_SOURCE_OSC8M: + SYSCTRL->OSC8M.reg |= SYSCTRL_OSC8M_ENABLE; + return STATUS_OK; + + case SYSTEM_CLOCK_SOURCE_OSC32K: + SYSCTRL->OSC32K.reg |= SYSCTRL_OSC32K_ENABLE; + break; + + case SYSTEM_CLOCK_SOURCE_XOSC: + SYSCTRL->XOSC.reg |= SYSCTRL_XOSC_ENABLE; + break; + + case SYSTEM_CLOCK_SOURCE_XOSC32K: + SYSCTRL->XOSC32K.reg |= SYSCTRL_XOSC32K_ENABLE; + break; + + case SYSTEM_CLOCK_SOURCE_DFLL: + _system_clock_inst.dfll.control |= SYSCTRL_DFLLCTRL_ENABLE; + _system_clock_source_dfll_set_config_errata_9905(); + break; + +#ifdef FEATURE_SYSTEM_CLOCK_DPLL + case SYSTEM_CLOCK_SOURCE_DPLL: + SYSCTRL->DPLLCTRLA.reg |= SYSCTRL_DPLLCTRLA_ENABLE; + break; +#endif + + case SYSTEM_CLOCK_SOURCE_ULP32K: + /* Always enabled */ + return STATUS_OK; + + default: + Assert(false); + return STATUS_ERR_INVALID_ARG; + } + + return STATUS_OK; +} + +/** + * \brief Disables a clock source + * + * Disables a clock source that was previously enabled. + * + * \param[in] clock_source Clock source to disable + * + * \retval STATUS_OK Clock source was disabled successfully + * \retval STATUS_ERR_INVALID_ARG An invalid or unavailable clock source was + * given + */ +enum status_code system_clock_source_disable( + const enum system_clock_source clock_source) +{ + switch (clock_source) { + case SYSTEM_CLOCK_SOURCE_OSC8M: + SYSCTRL->OSC8M.reg &= ~SYSCTRL_OSC8M_ENABLE; + break; + + case SYSTEM_CLOCK_SOURCE_OSC32K: + SYSCTRL->OSC32K.reg &= ~SYSCTRL_OSC32K_ENABLE; + break; + + case SYSTEM_CLOCK_SOURCE_XOSC: + SYSCTRL->XOSC.reg &= ~SYSCTRL_XOSC_ENABLE; + break; + + case SYSTEM_CLOCK_SOURCE_XOSC32K: + SYSCTRL->XOSC32K.reg &= ~SYSCTRL_XOSC32K_ENABLE; + break; + + case SYSTEM_CLOCK_SOURCE_DFLL: + _system_clock_inst.dfll.control &= ~SYSCTRL_DFLLCTRL_ENABLE; + SYSCTRL->DFLLCTRL.reg = _system_clock_inst.dfll.control; + break; + +#ifdef FEATURE_SYSTEM_CLOCK_DPLL + case SYSTEM_CLOCK_SOURCE_DPLL: + SYSCTRL->DPLLCTRLA.reg &= ~SYSCTRL_DPLLCTRLA_ENABLE; + break; +#endif + + case SYSTEM_CLOCK_SOURCE_ULP32K: + /* Not possible to disable */ + + default: + Assert(false); + return STATUS_ERR_INVALID_ARG; + + } + + return STATUS_OK; +} + +/** + * \brief Checks if a clock source is ready + * + * Checks if a given clock source is ready to be used. + * + * \param[in] clock_source Clock source to check if ready + * + * \returns Ready state of the given clock source. + * + * \retval true Clock source is enabled and ready + * \retval false Clock source is disabled or not yet ready + */ +bool system_clock_source_is_ready( + const enum system_clock_source clock_source) +{ + uint32_t mask = 0; + + switch (clock_source) { + case SYSTEM_CLOCK_SOURCE_OSC8M: + mask = SYSCTRL_PCLKSR_OSC8MRDY; + break; + + case SYSTEM_CLOCK_SOURCE_OSC32K: + mask = SYSCTRL_PCLKSR_OSC32KRDY; + break; + + case SYSTEM_CLOCK_SOURCE_XOSC: + mask = SYSCTRL_PCLKSR_XOSCRDY; + break; + + case SYSTEM_CLOCK_SOURCE_XOSC32K: + mask = SYSCTRL_PCLKSR_XOSC32KRDY; + break; + + case SYSTEM_CLOCK_SOURCE_DFLL: + if (CONF_CLOCK_DFLL_LOOP_MODE == SYSTEM_CLOCK_DFLL_LOOP_MODE_CLOSED) { + mask = (SYSCTRL_PCLKSR_DFLLRDY | + SYSCTRL_PCLKSR_DFLLLCKF | SYSCTRL_PCLKSR_DFLLLCKC); + } else { + mask = SYSCTRL_PCLKSR_DFLLRDY; + } + break; + +#ifdef FEATURE_SYSTEM_CLOCK_DPLL + case SYSTEM_CLOCK_SOURCE_DPLL: + return ((SYSCTRL->DPLLSTATUS.reg & + (SYSCTRL_DPLLSTATUS_CLKRDY | SYSCTRL_DPLLSTATUS_LOCK)) == + (SYSCTRL_DPLLSTATUS_CLKRDY | SYSCTRL_DPLLSTATUS_LOCK)); +#endif + + case SYSTEM_CLOCK_SOURCE_ULP32K: + /* Not possible to disable */ + return true; + + default: + return false; + } + + return ((SYSCTRL->PCLKSR.reg & mask) == mask); +} + +/* Include some checks for conf_clocks.h validation */ +#include "clock_config_check.h" + +#if !defined(__DOXYGEN__) +/** \internal + * + * Configures a Generic Clock Generator with the configuration from \c conf_clocks.h. + */ +# define _CONF_CLOCK_GCLK_CONFIG(n, unused) \ + if (CONF_CLOCK_GCLK_##n##_ENABLE == true) { \ + struct system_gclk_gen_config gclk_conf; \ + system_gclk_gen_get_config_defaults(&gclk_conf); \ + gclk_conf.source_clock = CONF_CLOCK_GCLK_##n##_CLOCK_SOURCE; \ + gclk_conf.division_factor = CONF_CLOCK_GCLK_##n##_PRESCALER; \ + gclk_conf.run_in_standby = CONF_CLOCK_GCLK_##n##_RUN_IN_STANDBY; \ + gclk_conf.output_enable = CONF_CLOCK_GCLK_##n##_OUTPUT_ENABLE; \ + system_gclk_gen_set_config(GCLK_GENERATOR_##n, &gclk_conf); \ + system_gclk_gen_enable(GCLK_GENERATOR_##n); \ + } + +/** \internal + * + * Configures a Generic Clock Generator with the configuration from \c conf_clocks.h, + * provided that it is not the main Generic Clock Generator channel. + */ +# define _CONF_CLOCK_GCLK_CONFIG_NONMAIN(n, unused) \ + if (n > 0) { _CONF_CLOCK_GCLK_CONFIG(n, unused); } +#endif + +/** + * \brief Initialize clock system based on the configuration in conf_clocks.h + * + * This function will apply the settings in conf_clocks.h when run from the user + * application. All clock sources and GCLK generators are running when this function + * returns. + */ +void system_clock_init(void) +{ + /* Various bits in the INTFLAG register can be set to one at startup. + This will ensure that these bits are cleared */ + SYSCTRL->INTFLAG.reg = SYSCTRL_INTFLAG_BOD33RDY | SYSCTRL_INTFLAG_BOD33DET | + SYSCTRL_INTFLAG_DFLLRDY; + + system_flash_set_waitstates(CONF_CLOCK_FLASH_WAIT_STATES); + + /* XOSC */ +#if CONF_CLOCK_XOSC_ENABLE == true + struct system_clock_source_xosc_config xosc_conf; + system_clock_source_xosc_get_config_defaults(&xosc_conf); + + xosc_conf.external_clock = CONF_CLOCK_XOSC_EXTERNAL_CRYSTAL; + xosc_conf.startup_time = CONF_CLOCK_XOSC_STARTUP_TIME; + xosc_conf.auto_gain_control = CONF_CLOCK_XOSC_AUTO_GAIN_CONTROL; + xosc_conf.frequency = CONF_CLOCK_XOSC_EXTERNAL_FREQUENCY; + xosc_conf.on_demand = CONF_CLOCK_XOSC_ON_DEMAND; + xosc_conf.run_in_standby = CONF_CLOCK_XOSC_RUN_IN_STANDBY; + + system_clock_source_xosc_set_config(&xosc_conf); + system_clock_source_enable(SYSTEM_CLOCK_SOURCE_XOSC); +#endif + + + /* XOSC32K */ +#if CONF_CLOCK_XOSC32K_ENABLE == true + struct system_clock_source_xosc32k_config xosc32k_conf; + system_clock_source_xosc32k_get_config_defaults(&xosc32k_conf); + + xosc32k_conf.frequency = 32768UL; + xosc32k_conf.external_clock = CONF_CLOCK_XOSC32K_EXTERNAL_CRYSTAL; + xosc32k_conf.startup_time = CONF_CLOCK_XOSC32K_STARTUP_TIME; + xosc32k_conf.auto_gain_control = CONF_CLOCK_XOSC32K_AUTO_AMPLITUDE_CONTROL; + xosc32k_conf.enable_1khz_output = CONF_CLOCK_XOSC32K_ENABLE_1KHZ_OUPUT; + xosc32k_conf.enable_32khz_output = CONF_CLOCK_XOSC32K_ENABLE_32KHZ_OUTPUT; + xosc32k_conf.on_demand = false; + xosc32k_conf.run_in_standby = CONF_CLOCK_XOSC32K_RUN_IN_STANDBY; + + system_clock_source_xosc32k_set_config(&xosc32k_conf); + system_clock_source_enable(SYSTEM_CLOCK_SOURCE_XOSC32K); + while(!system_clock_source_is_ready(SYSTEM_CLOCK_SOURCE_XOSC32K)); + if (CONF_CLOCK_XOSC32K_ON_DEMAND) { + SYSCTRL->XOSC32K.bit.ONDEMAND = 1; + } +#endif + + + /* OSCK32K */ +#if CONF_CLOCK_OSC32K_ENABLE == true + SYSCTRL->OSC32K.bit.CALIB = + (*(uint32_t *)SYSCTRL_FUSES_OSC32K_ADDR >> SYSCTRL_FUSES_OSC32K_Pos); + + struct system_clock_source_osc32k_config osc32k_conf; + system_clock_source_osc32k_get_config_defaults(&osc32k_conf); + + osc32k_conf.startup_time = CONF_CLOCK_OSC32K_STARTUP_TIME; + osc32k_conf.enable_1khz_output = CONF_CLOCK_OSC32K_ENABLE_1KHZ_OUTPUT; + osc32k_conf.enable_32khz_output = CONF_CLOCK_OSC32K_ENABLE_32KHZ_OUTPUT; + osc32k_conf.on_demand = CONF_CLOCK_OSC32K_ON_DEMAND; + osc32k_conf.run_in_standby = CONF_CLOCK_OSC32K_RUN_IN_STANDBY; + + system_clock_source_osc32k_set_config(&osc32k_conf); + system_clock_source_enable(SYSTEM_CLOCK_SOURCE_OSC32K); +#endif + + + /* DFLL Config (Open and Closed Loop) */ +#if CONF_CLOCK_DFLL_ENABLE == true + struct system_clock_source_dfll_config dfll_conf; + system_clock_source_dfll_get_config_defaults(&dfll_conf); + + dfll_conf.loop_mode = CONF_CLOCK_DFLL_LOOP_MODE; + dfll_conf.on_demand = false; + + if (CONF_CLOCK_DFLL_LOOP_MODE == SYSTEM_CLOCK_DFLL_LOOP_MODE_OPEN) { + dfll_conf.coarse_value = CONF_CLOCK_DFLL_COARSE_VALUE; + dfll_conf.fine_value = CONF_CLOCK_DFLL_FINE_VALUE; + } + +# if CONF_CLOCK_DFLL_QUICK_LOCK == true + dfll_conf.quick_lock = SYSTEM_CLOCK_DFLL_QUICK_LOCK_ENABLE; +# else + dfll_conf.quick_lock = SYSTEM_CLOCK_DFLL_QUICK_LOCK_DISABLE; +# endif + +# if CONF_CLOCK_DFLL_TRACK_AFTER_FINE_LOCK == true + dfll_conf.stable_tracking = SYSTEM_CLOCK_DFLL_STABLE_TRACKING_TRACK_AFTER_LOCK; +# else + dfll_conf.stable_tracking = SYSTEM_CLOCK_DFLL_STABLE_TRACKING_FIX_AFTER_LOCK; +# endif + +# if CONF_CLOCK_DFLL_KEEP_LOCK_ON_WAKEUP == true + dfll_conf.wakeup_lock = SYSTEM_CLOCK_DFLL_WAKEUP_LOCK_KEEP; +# else + dfll_conf.wakeup_lock = SYSTEM_CLOCK_DFLL_WAKEUP_LOCK_LOSE; +# endif + +# if CONF_CLOCK_DFLL_ENABLE_CHILL_CYCLE == true + dfll_conf.chill_cycle = SYSTEM_CLOCK_DFLL_CHILL_CYCLE_ENABLE; +# else + dfll_conf.chill_cycle = SYSTEM_CLOCK_DFLL_CHILL_CYCLE_DISABLE; +# endif + + if (CONF_CLOCK_DFLL_LOOP_MODE == SYSTEM_CLOCK_DFLL_LOOP_MODE_CLOSED) { + dfll_conf.multiply_factor = CONF_CLOCK_DFLL_MULTIPLY_FACTOR; + } + + dfll_conf.coarse_max_step = CONF_CLOCK_DFLL_MAX_COARSE_STEP_SIZE; + dfll_conf.fine_max_step = CONF_CLOCK_DFLL_MAX_FINE_STEP_SIZE; + + if (CONF_CLOCK_DFLL_LOOP_MODE == SYSTEM_CLOCK_DFLL_LOOP_MODE_USB_RECOVERY) { +#define NVM_DFLL_COARSE_POS 58 +#define NVM_DFLL_COARSE_SIZE 6 +#define NVM_DFLL_FINE_POS 64 +#define NVM_DFLL_FINE_SIZE 10 + uint32_t coarse =( *((uint32_t *)(NVMCTRL_OTP4) + + (NVM_DFLL_COARSE_POS / 32)) + >> (NVM_DFLL_COARSE_POS % 32)) + & ((1 << NVM_DFLL_COARSE_SIZE) - 1); + if (coarse == 0x3f) { + coarse = 0x1f; + } + uint32_t fine =( *((uint32_t *)(NVMCTRL_OTP4) + + (NVM_DFLL_FINE_POS / 32)) + >> (NVM_DFLL_FINE_POS % 32)) + & ((1 << NVM_DFLL_FINE_SIZE) - 1); + if (fine == 0x3ff) { + fine = 0x1ff; + } + dfll_conf.coarse_value = coarse; + dfll_conf.fine_value = fine; + + dfll_conf.quick_lock = SYSTEM_CLOCK_DFLL_QUICK_LOCK_ENABLE; + dfll_conf.stable_tracking = SYSTEM_CLOCK_DFLL_STABLE_TRACKING_FIX_AFTER_LOCK; + dfll_conf.wakeup_lock = SYSTEM_CLOCK_DFLL_WAKEUP_LOCK_KEEP; + dfll_conf.chill_cycle = SYSTEM_CLOCK_DFLL_CHILL_CYCLE_DISABLE; + + dfll_conf.multiply_factor = 48000; + } + + system_clock_source_dfll_set_config(&dfll_conf); +#endif + + + /* OSC8M */ + struct system_clock_source_osc8m_config osc8m_conf; + system_clock_source_osc8m_get_config_defaults(&osc8m_conf); + + osc8m_conf.prescaler = CONF_CLOCK_OSC8M_PRESCALER; + osc8m_conf.on_demand = CONF_CLOCK_OSC8M_ON_DEMAND; + osc8m_conf.run_in_standby = CONF_CLOCK_OSC8M_RUN_IN_STANDBY; + + system_clock_source_osc8m_set_config(&osc8m_conf); + system_clock_source_enable(SYSTEM_CLOCK_SOURCE_OSC8M); + + + /* GCLK */ +#if CONF_CLOCK_CONFIGURE_GCLK == true + system_gclk_init(); + + /* Configure all GCLK generators except for the main generator, which + * is configured later after all other clock systems are set up */ + MREPEAT(8, _CONF_CLOCK_GCLK_CONFIG_NONMAIN, ~); + +# if CONF_CLOCK_DFLL_ENABLE == true + /* Enable DFLL reference clock if in closed loop mode */ + if (CONF_CLOCK_DFLL_LOOP_MODE == SYSTEM_CLOCK_DFLL_LOOP_MODE_CLOSED) { + struct system_gclk_chan_config dfll_gclk_chan_conf; + + system_gclk_chan_get_config_defaults(&dfll_gclk_chan_conf); + dfll_gclk_chan_conf.source_generator = CONF_CLOCK_DFLL_SOURCE_GCLK_GENERATOR; + system_gclk_chan_set_config(SYSCTRL_GCLK_ID_DFLL48, &dfll_gclk_chan_conf); + system_gclk_chan_enable(SYSCTRL_GCLK_ID_DFLL48); + } +# endif +#endif + + + /* DFLL Enable (Open and Closed Loop) */ +#if CONF_CLOCK_DFLL_ENABLE == true + system_clock_source_enable(SYSTEM_CLOCK_SOURCE_DFLL); + while(!system_clock_source_is_ready(SYSTEM_CLOCK_SOURCE_DFLL)); + if (CONF_CLOCK_DFLL_ON_DEMAND) { + SYSCTRL->DFLLCTRL.bit.ONDEMAND = 1; + } +#endif + + /* DPLL */ +#ifdef FEATURE_SYSTEM_CLOCK_DPLL +# if (CONF_CLOCK_DPLL_ENABLE == true) + + /* Enable DPLL reference clock */ + if (CONF_CLOCK_DPLL_REFERENCE_CLOCK == SYSTEM_CLOCK_SOURCE_DPLL_REFERENCE_CLOCK_REF0) { + /* XOSC32K should have been enabled for DPLL_REF0 */ + Assert(CONF_CLOCK_XOSC32K_ENABLE); + } + + struct system_clock_source_dpll_config dpll_config; + system_clock_source_dpll_get_config_defaults(&dpll_config); + + dpll_config.on_demand = false; + dpll_config.run_in_standby = CONF_CLOCK_DPLL_RUN_IN_STANDBY; + dpll_config.lock_bypass = CONF_CLOCK_DPLL_LOCK_BYPASS; + dpll_config.wake_up_fast = CONF_CLOCK_DPLL_WAKE_UP_FAST; + dpll_config.low_power_enable = CONF_CLOCK_DPLL_LOW_POWER_ENABLE; + + dpll_config.filter = CONF_CLOCK_DPLL_FILTER; + + dpll_config.reference_clock = CONF_CLOCK_DPLL_REFERENCE_CLOCK; + dpll_config.reference_frequency = CONF_CLOCK_DPLL_REFERENCE_FREQUENCY; + dpll_config.reference_divider = CONF_CLOCK_DPLL_REFEREMCE_DIVIDER; + dpll_config.output_frequency = CONF_CLOCK_DPLL_OUTPUT_FREQUENCY; + + system_clock_source_dpll_set_config(&dpll_config); + system_clock_source_enable(SYSTEM_CLOCK_SOURCE_DPLL); + while(!system_clock_source_is_ready(SYSTEM_CLOCK_SOURCE_DPLL)); + if (CONF_CLOCK_DPLL_ON_DEMAND) { + SYSCTRL->DPLLCTRLA.bit.ONDEMAND = 1; + } + +# endif +#endif + + /* CPU and BUS clocks */ + system_cpu_clock_set_divider(CONF_CLOCK_CPU_DIVIDER); + +#ifdef FEATURE_SYSTEM_CLOCK_FAILURE_DETECT + system_main_clock_set_failure_detect(CONF_CLOCK_CPU_CLOCK_FAILURE_DETECT); +#endif + + system_apb_clock_set_divider(SYSTEM_CLOCK_APB_APBA, CONF_CLOCK_APBA_DIVIDER); + system_apb_clock_set_divider(SYSTEM_CLOCK_APB_APBB, CONF_CLOCK_APBB_DIVIDER); + + /* GCLK 0 */ +#if CONF_CLOCK_CONFIGURE_GCLK == true + /* Configure the main GCLK last as it might depend on other generators */ + _CONF_CLOCK_GCLK_CONFIG(0, ~); +#endif +} diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/clock_samd21_r21/clock_config_check.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/clock_samd21_r21/clock_config_check.h new file mode 100755 index 0000000..045ef64 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/clock_samd21_r21/clock_config_check.h @@ -0,0 +1,423 @@ +/** + * \file + * + * \brief SAM D21/R21 Clock Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef CLOCK_CONFIG_CHECK_H +# define CLOCK_CONFIG_CHECK_H + +#if !defined(CONF_CLOCK_FLASH_WAIT_STATES) +# error CONF_CLOCK_FLASH_WAIT_STATES not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_CPU_DIVIDER) +# error CONF_CLOCK_CPU_DIVIDER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_APBA_DIVIDER) +# error CONF_CLOCK_APBA_DIVIDER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_APBB_DIVIDER) +# error CONF_CLOCK_APBB_DIVIDER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_OSC8M_PRESCALER) +# error CONF_CLOCK_OSC8M_PRESCALER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_OSC8M_ON_DEMAND) +# error CONF_CLOCK_OSC8M_ON_DEMAND not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_OSC8M_RUN_IN_STANDBY) +# error CONF_CLOCK_OSC8M_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC_ENABLE) +# error CONF_CLOCK_XOSC_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC_EXTERNAL_CRYSTAL) +# error CONF_CLOCK_XOSC_EXTERNAL_CRYSTAL not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC_EXTERNAL_FREQUENCY) +# error CONF_CLOCK_XOSC_EXTERNAL_FREQUENCY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC_STARTUP_TIME) +# error CONF_CLOCK_XOSC_STARTUP_TIME not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC_AUTO_GAIN_CONTROL) +# error CONF_CLOCK_XOSC_AUTO_GAIN_CONTROL not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC_ON_DEMAND) +# error CONF_CLOCK_XOSC_ON_DEMAND not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC_RUN_IN_STANDBY) +# error CONF_CLOCK_XOSC_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC32K_ENABLE) +# error CONF_CLOCK_XOSC32K_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC32K_EXTERNAL_CRYSTAL) +# error CONF_CLOCK_XOSC32K_EXTERNAL_CRYSTAL not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC32K_STARTUP_TIME) +# error CONF_CLOCK_XOSC32K_STARTUP_TIME not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC32K_AUTO_AMPLITUDE_CONTROL) +# error CONF_CLOCK_XOSC32K_AUTO_AMPLITUDE_CONTROL not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC32K_ENABLE_1KHZ_OUPUT) +# error CONF_CLOCK_XOSC32K_ENABLE_1KHZ_OUPUT not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC32K_ENABLE_32KHZ_OUTPUT) +# error CONF_CLOCK_XOSC32K_ENABLE_32KHZ_OUTPUT not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC32K_ON_DEMAND) +# error CONF_CLOCK_XOSC32K_ON_DEMAND not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_XOSC32K_RUN_IN_STANDBY) +# error CONF_CLOCK_XOSC32K_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_OSC32K_ENABLE) +# error CONF_CLOCK_OSC32K_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_OSC32K_STARTUP_TIME) +# error CONF_CLOCK_OSC32K_STARTUP_TIME not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_OSC32K_ENABLE_1KHZ_OUTPUT) +# error CONF_CLOCK_OSC32K_ENABLE_1KHZ_OUTPUT not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_OSC32K_ENABLE_32KHZ_OUTPUT) +# error CONF_CLOCK_OSC32K_ENABLE_32KHZ_OUTPUT not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_OSC32K_ON_DEMAND) +# error CONF_CLOCK_OSC32K_ON_DEMAND not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_OSC32K_RUN_IN_STANDBY) +# error CONF_CLOCK_OSC32K_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_ENABLE) +# error CONF_CLOCK_DFLL_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_LOOP_MODE) +# error CONF_CLOCK_DFLL_LOOP_MODE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_ON_DEMAND) +# error CONF_CLOCK_DFLL_ON_DEMAND not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_COARSE_VALUE) +# error CONF_CLOCK_DFLL_COARSE_VALUE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_FINE_VALUE) +# error CONF_CLOCK_DFLL_FINE_VALUE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_SOURCE_GCLK_GENERATOR) +# error CONF_CLOCK_DFLL_SOURCE_GCLK_GENERATOR not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_MULTIPLY_FACTOR) +# error CONF_CLOCK_DFLL_MULTIPLY_FACTOR not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_QUICK_LOCK) +# error CONF_CLOCK_DFLL_QUICK_LOCK not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_TRACK_AFTER_FINE_LOCK) +# error CONF_CLOCK_DFLL_TRACK_AFTER_FINE_LOCK not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_KEEP_LOCK_ON_WAKEUP) +# error CONF_CLOCK_DFLL_KEEP_LOCK_ON_WAKEUP not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_ENABLE_CHILL_CYCLE) +# error CONF_CLOCK_DFLL_ENABLE_CHILL_CYCLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_MAX_COARSE_STEP_SIZE) +# error CONF_CLOCK_DFLL_MAX_COARSE_STEP_SIZE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DFLL_MAX_FINE_STEP_SIZE) +# error CONF_CLOCK_DFLL_MAX_FINE_STEP_SIZE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_ENABLE) +# error CONF_CLOCK_DPLL_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_ON_DEMAND) +# error CONF_CLOCK_DPLL_ON_DEMAND not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_RUN_IN_STANDBY) +# error CONF_CLOCK_DPLL_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_LOCK_BYPASS) +# error CONF_CLOCK_DPLL_LOCK_BYPASS not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_WAKE_UP_FAST) +# error CONF_CLOCK_DPLL_WAKE_UP_FAST not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_LOW_POWER_ENABLE) +# error CONF_CLOCK_DPLL_LOW_POWER_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_LOCK_TIME) +# error CONF_CLOCK_DPLL_LOCK_TIME not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_REFERENCE_CLOCK) +# error CONF_CLOCK_DPLL_REFERENCE_CLOCK not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_FILTER) +# error CONF_CLOCK_DPLL_FILTER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_REFERENCE_FREQUENCY) +# error CONF_CLOCK_DPLL_REFERENCE_FREQUENCY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_REFEREMCE_DIVIDER) +# error CONF_CLOCK_DPLL_REFEREMCE_DIVIDER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_DPLL_OUTPUT_FREQUENCY) +# error CONF_CLOCK_DPLL_OUTPUT_FREQUENCY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_CONFIGURE_GCLK) +# error CONF_CLOCK_CONFIGURE_GCLK not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_0_ENABLE) +# error CONF_CLOCK_GCLK_0_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_0_RUN_IN_STANDBY) +# error CONF_CLOCK_GCLK_0_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_0_CLOCK_SOURCE) +# error CONF_CLOCK_GCLK_0_CLOCK_SOURCE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_0_PRESCALER) +# error CONF_CLOCK_GCLK_0_PRESCALER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_0_OUTPUT_ENABLE) +# error CONF_CLOCK_GCLK_0_OUTPUT_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_1_ENABLE) +# error CONF_CLOCK_GCLK_1_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_1_RUN_IN_STANDBY) +# error CONF_CLOCK_GCLK_1_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_1_CLOCK_SOURCE) +# error CONF_CLOCK_GCLK_1_CLOCK_SOURCE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_1_PRESCALER) +# error CONF_CLOCK_GCLK_1_PRESCALER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_1_OUTPUT_ENABLE) +# error CONF_CLOCK_GCLK_1_OUTPUT_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_2_ENABLE) +# error CONF_CLOCK_GCLK_2_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_2_RUN_IN_STANDBY) +# error CONF_CLOCK_GCLK_2_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_2_CLOCK_SOURCE) +# error CONF_CLOCK_GCLK_2_CLOCK_SOURCE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_2_PRESCALER) +# error CONF_CLOCK_GCLK_2_PRESCALER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_2_OUTPUT_ENABLE) +# error CONF_CLOCK_GCLK_2_OUTPUT_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_3_ENABLE) +# error CONF_CLOCK_GCLK_3_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_3_RUN_IN_STANDBY) +# error CONF_CLOCK_GCLK_3_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_3_CLOCK_SOURCE) +# error CONF_CLOCK_GCLK_3_CLOCK_SOURCE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_3_PRESCALER) +# error CONF_CLOCK_GCLK_3_PRESCALER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_3_OUTPUT_ENABLE) +# error CONF_CLOCK_GCLK_3_OUTPUT_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_4_ENABLE) +# error CONF_CLOCK_GCLK_4_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_4_RUN_IN_STANDBY) +# error CONF_CLOCK_GCLK_4_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_4_CLOCK_SOURCE) +# error CONF_CLOCK_GCLK_4_CLOCK_SOURCE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_4_PRESCALER) +# error CONF_CLOCK_GCLK_4_PRESCALER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_4_OUTPUT_ENABLE) +# error CONF_CLOCK_GCLK_4_OUTPUT_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_5_ENABLE) +# error CONF_CLOCK_GCLK_5_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_5_RUN_IN_STANDBY) +# error CONF_CLOCK_GCLK_5_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_5_CLOCK_SOURCE) +# error CONF_CLOCK_GCLK_5_CLOCK_SOURCE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_5_PRESCALER) +# error CONF_CLOCK_GCLK_5_PRESCALER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_5_OUTPUT_ENABLE) +# error CONF_CLOCK_GCLK_5_OUTPUT_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_6_ENABLE) +# error CONF_CLOCK_GCLK_6_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_6_RUN_IN_STANDBY) +# error CONF_CLOCK_GCLK_6_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_6_CLOCK_SOURCE) +# error CONF_CLOCK_GCLK_6_CLOCK_SOURCE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_6_PRESCALER) +# error CONF_CLOCK_GCLK_6_PRESCALER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_6_OUTPUT_ENABLE) +# error CONF_CLOCK_GCLK_6_OUTPUT_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_7_ENABLE) +# error CONF_CLOCK_GCLK_7_ENABLE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_7_RUN_IN_STANDBY) +# error CONF_CLOCK_GCLK_7_RUN_IN_STANDBY not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_7_CLOCK_SOURCE) +# error CONF_CLOCK_GCLK_7_CLOCK_SOURCE not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_7_PRESCALER) +# error CONF_CLOCK_GCLK_7_PRESCALER not defined in conf_clock.h +#endif + +#if !defined(CONF_CLOCK_GCLK_7_OUTPUT_ENABLE) +# error CONF_CLOCK_GCLK_7_OUTPUT_ENABLE not defined in conf_clock.h +#endif + +#endif /* CLOCK_CONFIG_CHECK_H */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/clock_samd21_r21/gclk.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/clock_samd21_r21/gclk.c new file mode 100755 index 0000000..3816ff7 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/clock_samd21_r21/gclk.c @@ -0,0 +1,496 @@ +/** + * \file + * + * \brief SAM D21/R21 Generic Clock Driver + * + * Copyright (C) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include +#include +#include + +/** + * \brief Initializes the GCLK driver. + * + * Initializes the Generic Clock module, disabling and resetting all active + * Generic Clock Generators and Channels to their power-on default values. + */ +void system_gclk_init(void) +{ + /* Turn on the digital interface clock */ + system_apb_clock_set_mask(SYSTEM_CLOCK_APB_APBA, PM_APBAMASK_GCLK); + + /* Software reset the module to ensure it is re-initialized correctly */ + GCLK->CTRL.reg = GCLK_CTRL_SWRST; + while (GCLK->CTRL.reg & GCLK_CTRL_SWRST) { + /* Wait for reset to complete */ + } +} + +/** + * \brief Writes a Generic Clock Generator configuration to the hardware module. + * + * Writes out a given configuration of a Generic Clock Generator configuration + * to the hardware module. + * + * \note Changing the clock source on the fly (on a running + * generator) can take additional time if the clock source is configured + * to only run on-demand (ONDEMAND bit is set) and it is not currently + * running (no peripheral is requesting the clock source). In this case + * the GCLK will request the new clock while still keeping a request to + * the old clock source until the new clock source is ready. + * + * \note This function will not start a generator that is not already running; + * to start the generator, call \ref system_gclk_gen_enable() + * after configuring a generator. + * + * \param[in] generator Generic Clock Generator index to configure + * \param[in] config Configuration settings for the generator + */ +void system_gclk_gen_set_config( + const uint8_t generator, + struct system_gclk_gen_config *const config) +{ + /* Sanity check arguments */ + Assert(config); + + /* Cache new register configurations to minimize sync requirements. */ + uint32_t new_genctrl_config = (generator << GCLK_GENCTRL_ID_Pos); + uint32_t new_gendiv_config = (generator << GCLK_GENDIV_ID_Pos); + + /* Select the requested source clock for the generator */ + new_genctrl_config |= config->source_clock << GCLK_GENCTRL_SRC_Pos; + + /* Configure the clock to be either high or low when disabled */ + if (config->high_when_disabled) { + new_genctrl_config |= GCLK_GENCTRL_OOV; + } + + /* Configure if the clock output to I/O pin should be enabled. */ + if (config->output_enable) { + new_genctrl_config |= GCLK_GENCTRL_OE; + } + + /* Set division factor */ + if (config->division_factor > 1) { + /* Check if division is a power of two */ + if (((config->division_factor & (config->division_factor - 1)) == 0)) { + /* Determine the index of the highest bit set to get the + * division factor that must be loaded into the division + * register */ + + uint32_t div2_count = 0; + + uint32_t mask; + for (mask = (1UL << 1); mask < config->division_factor; + mask <<= 1) { + div2_count++; + } + + /* Set binary divider power of 2 division factor */ + new_gendiv_config |= div2_count << GCLK_GENDIV_DIV_Pos; + new_genctrl_config |= GCLK_GENCTRL_DIVSEL; + } else { + /* Set integer division factor */ + + new_gendiv_config |= + (config->division_factor) << GCLK_GENDIV_DIV_Pos; + + /* Enable non-binary division with increased duty cycle accuracy */ + new_genctrl_config |= GCLK_GENCTRL_IDC; + } + + } + + /* Enable or disable the clock in standby mode */ + if (config->run_in_standby) { + new_genctrl_config |= GCLK_GENCTRL_RUNSTDBY; + } + + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + + system_interrupt_enter_critical_section(); + + /* Select the correct generator */ + *((uint8_t*)&GCLK->GENDIV.reg) = generator; + + /* Write the new generator configuration */ + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + GCLK->GENDIV.reg = new_gendiv_config; + + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + GCLK->GENCTRL.reg = new_genctrl_config | (GCLK->GENCTRL.reg & GCLK_GENCTRL_GENEN); + + system_interrupt_leave_critical_section(); +} + +/** + * \brief Enables a Generic Clock Generator that was previously configured. + * + * Starts the clock generation of a Generic Clock Generator that was previously + * configured via a call to \ref system_gclk_gen_set_config(). + * + * \param[in] generator Generic Clock Generator index to enable + */ +void system_gclk_gen_enable( + const uint8_t generator) +{ + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + + system_interrupt_enter_critical_section(); + + /* Select the requested generator */ + *((uint8_t*)&GCLK->GENCTRL.reg) = generator; + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + + /* Enable generator */ + GCLK->GENCTRL.reg |= GCLK_GENCTRL_GENEN; + + system_interrupt_leave_critical_section(); +} + +/** + * \brief Disables a Generic Clock Generator that was previously enabled. + * + * Stops the clock generation of a Generic Clock Generator that was previously + * started via a call to \ref system_gclk_gen_enable(). + * + * \param[in] generator Generic Clock Generator index to disable + */ +void system_gclk_gen_disable( + const uint8_t generator) +{ + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + + system_interrupt_enter_critical_section(); + + /* Select the requested generator */ + *((uint8_t*)&GCLK->GENCTRL.reg) = generator; + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + + /* Disable generator */ + GCLK->GENCTRL.reg &= ~GCLK_GENCTRL_GENEN; + while (GCLK->GENCTRL.reg & GCLK_GENCTRL_GENEN) { + /* Wait for clock to become disabled */ + } + + system_interrupt_leave_critical_section(); +} + +/** + * \brief Determins if the specified Generic Clock Generator is enabled + * + * \param[in] generator Generic Clock Generator index to check + * + * \return The enabled status. + * \retval true The Generic Clock Generator is enabled; + * \retval false The Generic Clock Generator is disabled. + */ +bool system_gclk_gen_is_enabled( + const uint8_t generator) +{ + bool enabled; + + system_interrupt_enter_critical_section(); + + /* Select the requested generator */ + *((uint8_t*)&GCLK->GENCTRL.reg) = generator; + /* Obtain the enabled status */ + enabled = (GCLK->GENCTRL.reg & GCLK_GENCTRL_GENEN); + + system_interrupt_leave_critical_section(); + + return enabled; +} + +/** + * \brief Retrieves the clock frequency of a Generic Clock generator. + * + * Determines the clock frequency (in Hz) of a specified Generic Clock + * generator, used as a source to a Generic Clock Channel module. + * + * \param[in] generator Generic Clock Generator index + * + * \return The frequency of the generic clock generator, in Hz. + */ +uint32_t system_gclk_gen_get_hz( + const uint8_t generator) +{ + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + + system_interrupt_enter_critical_section(); + + /* Select the appropriate generator */ + *((uint8_t*)&GCLK->GENCTRL.reg) = generator; + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + + /* Get the frequency of the source connected to the GCLK generator */ + uint32_t gen_input_hz = system_clock_source_get_hz( + (enum system_clock_source)GCLK->GENCTRL.bit.SRC); + + *((uint8_t*)&GCLK->GENCTRL.reg) = generator; + + uint8_t divsel = GCLK->GENCTRL.bit.DIVSEL; + + /* Select the appropriate generator division register */ + *((uint8_t*)&GCLK->GENDIV.reg) = generator; + while (system_gclk_is_syncing()) { + /* Wait for synchronization */ + }; + + uint32_t divider = GCLK->GENDIV.bit.DIV; + + system_interrupt_leave_critical_section(); + + /* Check if the generator is using fractional or binary division */ + if (!divsel && divider > 1) { + gen_input_hz /= divider; + } else if (divsel) { + gen_input_hz >>= (divider+1); + } + + return gen_input_hz; +} + +/** + * \brief Writes a Generic Clock configuration to the hardware module. + * + * Writes out a given configuration of a Generic Clock configuration to the + * hardware module. If the clock is currently running, it will be stopped. + * + * \note Once called the clock will not be running; to start the clock, + * call \ref system_gclk_chan_enable() after configuring a clock channel. + * + * \param[in] channel Generic Clock channel to configure + * \param[in] config Configuration settings for the clock + * + */ +void system_gclk_chan_set_config( + const uint8_t channel, + struct system_gclk_chan_config *const config) +{ + /* Sanity check arguments */ + Assert(config); + + /* Cache the new config to reduce sync requirements */ + uint32_t new_clkctrl_config = (channel << GCLK_CLKCTRL_ID_Pos); + + /* Select the desired generic clock generator */ + new_clkctrl_config |= config->source_generator << GCLK_CLKCTRL_GEN_Pos; + + /* Disable generic clock channel */ + system_gclk_chan_disable(channel); + + /* Write the new configuration */ + GCLK->CLKCTRL.reg = new_clkctrl_config; +} + +/** + * \brief Enables a Generic Clock that was previously configured. + * + * Starts the clock generation of a Generic Clock that was previously + * configured via a call to \ref system_gclk_chan_set_config(). + * + * \param[in] channel Generic Clock channel to enable + */ +void system_gclk_chan_enable( + const uint8_t channel) +{ + system_interrupt_enter_critical_section(); + + /* Select the requested generator channel */ + *((uint8_t*)&GCLK->CLKCTRL.reg) = channel; + + /* Enable the generic clock */ + GCLK->CLKCTRL.reg |= GCLK_CLKCTRL_CLKEN; + + system_interrupt_leave_critical_section(); +} + +/** + * \brief Disables a Generic Clock that was previously enabled. + * + * Stops the clock generation of a Generic Clock that was previously started + * via a call to \ref system_gclk_chan_enable(). + * + * \param[in] channel Generic Clock channel to disable + */ +void system_gclk_chan_disable( + const uint8_t channel) +{ + system_interrupt_enter_critical_section(); + + /* Select the requested generator channel */ + *((uint8_t*)&GCLK->CLKCTRL.reg) = channel; + + /* Sanity check WRTLOCK */ + Assert(!GCLK->CLKCTRL.bit.WRTLOCK); + + /* Switch to known-working source so that the channel can be disabled */ + uint32_t prev_gen_id = GCLK->CLKCTRL.bit.GEN; + GCLK->CLKCTRL.bit.GEN = 0; + + /* Disable the generic clock */ + GCLK->CLKCTRL.reg &= ~GCLK_CLKCTRL_CLKEN; + while (GCLK->CLKCTRL.reg & GCLK_CLKCTRL_CLKEN) { + /* Wait for clock to become disabled */ + } + + /* Restore previous configured clock generator */ + GCLK->CLKCTRL.bit.GEN = prev_gen_id; + + system_interrupt_leave_critical_section(); +} + +/** + * \brief Determins if the specified Generic Clock channel is enabled + * + * \param[in] channel Generic Clock Channel index + * + * \return The enabled status. + * \retval true The Generic Clock channel is enabled; + * \retval false The Generic Clock channel is disabled. + */ +bool system_gclk_chan_is_enabled( + const uint8_t channel) +{ + bool enabled; + + system_interrupt_enter_critical_section(); + + /* Select the requested generic clock channel */ + *((uint8_t*)&GCLK->CLKCTRL.reg) = channel; + enabled = GCLK->CLKCTRL.bit.CLKEN; + + system_interrupt_leave_critical_section(); + + return enabled; +} + +/** + * \brief Locks a Generic Clock channel from further configuration writes. + * + * Locks a generic clock channel from further configuration writes. It is only + * possible to unlock the channel configuration through a power on reset. + * + * \param[in] channel Generic Clock channel to enable + */ +void system_gclk_chan_lock( + const uint8_t channel) +{ + system_interrupt_enter_critical_section(); + + /* Select the requested generator channel */ + *((uint8_t*)&GCLK->CLKCTRL.reg) = channel; + + /* Enable the generic clock */ + GCLK->CLKCTRL.reg |= GCLK_CLKCTRL_CLKEN; + + system_interrupt_leave_critical_section(); +} + +/** + * \brief Determins if the specified Generic Clock channel is locked + * + * \param[in] channel Generic Clock Channel index + * + * \return The lock status. + * \retval true The Generic Clock channel is locked; + * \retval false The Generic Clock channel is not locked. + */ +bool system_gclk_chan_is_locked( + const uint8_t channel) +{ + bool locked; + + system_interrupt_enter_critical_section(); + + /* Select the requested generic clock channel */ + *((uint8_t*)&GCLK->CLKCTRL.reg) = channel; + locked = GCLK->CLKCTRL.bit.WRTLOCK; + + system_interrupt_leave_critical_section(); + + return locked; +} + +/** + * \brief Retrieves the clock frequency of a Generic Clock channel. + * + * Determines the clock frequency (in Hz) of a specified Generic Clock + * channel, used as a source to a device peripheral module. + * + * \param[in] channel Generic Clock Channel index + * + * \return The frequency of the generic clock channel, in Hz. + */ +uint32_t system_gclk_chan_get_hz( + const uint8_t channel) +{ + uint8_t gen_id; + + system_interrupt_enter_critical_section(); + + /* Select the requested generic clock channel */ + *((uint8_t*)&GCLK->CLKCTRL.reg) = channel; + gen_id = GCLK->CLKCTRL.bit.GEN; + + system_interrupt_leave_critical_section(); + + /* Return the clock speed of the associated GCLK generator */ + return system_gclk_gen_get_hz(gen_id); +} diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/gclk.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/gclk.h new file mode 100755 index 0000000..f427132 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/gclk.h @@ -0,0 +1,322 @@ +/** + * \file + * + * \brief SAM Generic Clock Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef SYSTEM_CLOCK_GCLK_H_INCLUDED +#define SYSTEM_CLOCK_GCLK_H_INCLUDED + +/** + * \addtogroup asfdoc_sam0_system_clock_group + * + * @{ + */ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \brief List of available GCLK generators. + * + * List of Available GCLK generators. This enum is used in the peripheral + * device drivers to select the GCLK generator to be used for its operation. + * + * The number of GCLK generators available is device dependent. + */ +enum gclk_generator { + /** GCLK generator channel 0. */ + GCLK_GENERATOR_0, +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 0) + /** GCLK generator channel 1. */ + GCLK_GENERATOR_1, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 1) + /** GCLK generator channel 2. */ + GCLK_GENERATOR_2, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 2) + /** GCLK generator channel 3. */ + GCLK_GENERATOR_3, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 3) + /** GCLK generator channel 4. */ + GCLK_GENERATOR_4, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 4) + /** GCLK generator channel 5. */ + GCLK_GENERATOR_5, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 5) + /** GCLK generator channel 6. */ + GCLK_GENERATOR_6, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 6) + /** GCLK generator channel 7. */ + GCLK_GENERATOR_7, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 7) + /** GCLK generator channel 8. */ + GCLK_GENERATOR_8, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 8) + /** GCLK generator channel 9. */ + GCLK_GENERATOR_9, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 9) + /** GCLK generator channel 10. */ + GCLK_GENERATOR_10, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 10) + /** GCLK generator channel 11. */ + GCLK_GENERATOR_11, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 11) + /** GCLK generator channel 12. */ + GCLK_GENERATOR_12, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 12) + /** GCLK generator channel 13. */ + GCLK_GENERATOR_13, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 13) + /** GCLK generator channel 14. */ + GCLK_GENERATOR_14, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 14) + /** GCLK generator channel 15. */ + GCLK_GENERATOR_15, +#endif +#if defined(__DOXYGEN__) || (GCLK_GEN_NUM_MSB > 15) + /** GCLK generator channel 16. */ + GCLK_GENERATOR_16, +#endif +}; + +/** + * \brief Generic Clock Generator configuration structure. + * + * Configuration structure for a Generic Clock Generator channel. This + * structure should be initialized by the + * \ref system_gclk_gen_get_config_defaults() function before being modified by + * the user application. + */ +struct system_gclk_gen_config { + /** Source clock input channel index, please see the \ref system_clock_source. */ + uint8_t source_clock; + /** If \c true, the generator output level is high when disabled. */ + bool high_when_disabled; + /** Integer division factor of the clock output compared to the input. */ + uint32_t division_factor; + /** If \c true, the clock is kept enabled during device standby mode. */ + bool run_in_standby; + /** If \c true, enables GCLK generator clock output to a GPIO pin. */ + bool output_enable; +}; + +/** + * \brief Generic Clock configuration structure. + * + * Configuration structure for a Generic Clock channel. This structure + * should be initialized by the \ref system_gclk_chan_get_config_defaults() + * function before being modified by the user application. + */ +struct system_gclk_chan_config { + /** Generic Clock Generator source channel. */ + enum gclk_generator source_generator; +}; + +/** \name Generic Clock management + * @{ + */ + +/** + * \brief Determines if the hardware module(s) are currently synchronizing to the bus. + * + * Checks to see if the underlying hardware peripheral module(s) are currently + * synchronizing across multiple clock domains to the hardware bus, This + * function can be used to delay further operations on a module until such time + * that it is ready, to prevent blocking delays for synchronization in the + * user application. + * + * \return Synchronization status of the underlying hardware module(s). + * + * \retval true if the module has completed synchronization + * \retval false if the module synchronization is ongoing + */ +static inline bool system_gclk_is_syncing(void) +{ + if (GCLK->STATUS.reg & GCLK_STATUS_SYNCBUSY) { + return true; + } + + return false; +} + +void system_gclk_init(void); + +/** @} */ + + +/** + * \name Generic Clock management (Generators) + * @{ + */ + +/** + * \brief Initializes a Generic Clock Generator configuration structure to defaults. + * + * Initializes a given Generic Clock Generator configuration structure to + * a set of known default values. This function should be called on all + * new instances of these configuration structures before being modified + * by the user application. + * + * The default configuration is as follows: + * \li Clock is generated undivided from the source frequency + * \li Clock generator output is low when the generator is disabled + * \li The input clock is sourced from input clock channel 0 + * \li Clock will be disabled during sleep + * \li The clock output will not be routed to a physical GPIO pin + * + * \param[out] config Configuration structure to initialize to default values + */ +static inline void system_gclk_gen_get_config_defaults( + struct system_gclk_gen_config *const config) +{ + /* Sanity check arguments */ + Assert(config); + + /* Default configuration values */ + config->division_factor = 1; + config->high_when_disabled = false; + config->source_clock = GCLK_SOURCE_OSC8M; + config->run_in_standby = false; + config->output_enable = false; +} + +void system_gclk_gen_set_config( + const uint8_t generator, + struct system_gclk_gen_config *const config); + +void system_gclk_gen_enable( + const uint8_t generator); + +void system_gclk_gen_disable( + const uint8_t generator); + +bool system_gclk_gen_is_enabled( + const uint8_t generator); + +/** @} */ + + +/** + * \name Generic Clock management (Channels) + * @{ + */ + +/** + * \brief Initializes a Generic Clock configuration structure to defaults. + * + * Initializes a given Generic Clock configuration structure to a set of + * known default values. This function should be called on all new + * instances of these configuration structures before being modified by the + * user application. + * + * The default configuration is as follows: + * \li Clock is sourced from the Generic Clock Generator channel 0 + * \li Clock configuration will not be write-locked when set + * + * \param[out] config Configuration structure to initialize to default values + */ +static inline void system_gclk_chan_get_config_defaults( + struct system_gclk_chan_config *const config) +{ + /* Sanity check arguments */ + Assert(config); + + /* Default configuration values */ + config->source_generator = GCLK_GENERATOR_0; +} + +void system_gclk_chan_set_config( + const uint8_t channel, + struct system_gclk_chan_config *const config); + +void system_gclk_chan_enable( + const uint8_t channel); + +void system_gclk_chan_disable( + const uint8_t channel); + +bool system_gclk_chan_is_enabled( + const uint8_t channel); + +void system_gclk_chan_lock( + const uint8_t channel); + +bool system_gclk_chan_is_locked( + const uint8_t channel); + +/** @} */ + + +/** + * \name Generic Clock frequency retrieval + * @{ + */ + +uint32_t system_gclk_gen_get_hz( + const uint8_t generator); + +uint32_t system_gclk_chan_get_hz( + const uint8_t channel); + +/** @} */ + +#ifdef __cplusplus +} +#endif + +/** @} */ + +#endif diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/quick_start_clock/qs_clock_source.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/quick_start_clock/qs_clock_source.h new file mode 100755 index 0000000..46d7600 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/quick_start_clock/qs_clock_source.h @@ -0,0 +1,129 @@ +/** + * \file + * + * \brief SAM System Clock Driver Quick Start + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + */ + +/** + * \page asfdoc_sam0_system_clock_basic_use_case Quick Start Guide for SYSTEM CLOCK - Basic + * + * In this case we apply the following configuration: + * - RC8MHz (internal 8MHz RC oscillator) + * - Divide by 4, giving a frequency of 2MHz + * - DFLL (Digital frequency locked loop) + * - Open loop mode + * - 48MHz frequency + * - CPU clock + * - Use two wait states when reading from flash memory + * - Use the DFLL, configured to 48MHz + * + * \section asfdoc_sam0_system_clock_basic_use_case_setup Setup + * + * \subsection asfdoc_sam0_system_clock_basic_use_case_setup_prereq Prerequisites + * There are no special setup requirements for this use-case. + * + * \subsection asfdoc_sam0_system_clock_basic_use_case_setup_code Code + * Copy-paste the following setup code to your application: + * \snippet qs_clock_source.c setup + * + * \subsection asfdoc_sam0_system_clock_basic_use_case_setup_flow Workflow + * -# Create a EXTOSC32K module configuration struct, which can be filled + * out to adjust the configuration of the external 32KHz oscillator channel. + * \snippet qs_clock_source.c config_extosc32k_config + * + * -# Initialize the oscillator configuration struct with the module's default + * values. + * \snippet qs_clock_source.c config_extosc32k_get_defaults + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Alter the EXTOSC32K module configuration struct to require a start-up time + * of 4096 clock cycles. + * \snippet qs_clock_source.c config_extosc32k_change_defaults + * + * -# Write the new configuration to the EXTOSC32K module. + * \snippet qs_clock_source.c config_extosc32k_set_config + * + * -# Create a DFLL module configuration struct, which can be filled + * out to adjust the configuration of the external 32KHz oscillator channel. + * \snippet qs_clock_source.c config_dfll_config + * + * -# Initialize the DFLL oscillator configuration struct with the module's + * default values. + * \snippet qs_clock_source.c config_dfll_get_defaults + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Write the new configuration to the DFLL module. + * \snippet qs_clock_source.c config_dfll_set_config + * + * + * \section asfdoc_sam0_system_clock_basic_use_case_use_main Use Case + * + * \subsection asfdoc_sam0_system_clock_basic_use_case_code Code + * + * Copy-paste the following code to your user application: + * \snippet qs_clock_source.c main + * + * \subsection asfdoc_sam0_system_clock_basic_use_case_flow Workflow + * -# Configure the external 32KHz oscillator source using the previously + * defined setup function. + * \snippet qs_clock_source.c config_extosc32k_main + * + * -# Enable the configured external 32KHz oscillator source. + * \snippet qs_clock_source.c enable_extosc32k_main + * + * -# Configure the DFLL oscillator source using the previously defined setup + * function. + * \snippet qs_clock_source.c config_dfll_main + * + * -# Enable the configured DFLL oscillator source. + * \snippet qs_clock_source.c enable_dfll_main + * + * -# Configure the flash wait states to have two wait states per read, as the + * high speed DFLL will be used as the system clock. If insufficient wait + * states are used, the device may crash randomly due to misread instructions. + * \snippet qs_clock_source.c set_sys_wait_states + * + * -# Switch the system clock source to the DFLL, by reconfiguring the main + * clock generator. + * \snippet qs_clock_source.c set_sys_clk_src + */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/quick_start_gclk/qs_gclk_basic.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/quick_start_gclk/qs_gclk_basic.h new file mode 100755 index 0000000..274a519 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/clock/quick_start_gclk/qs_gclk_basic.h @@ -0,0 +1,126 @@ +/** + * \file + * + * \brief SAM Generic Clock Driver Quick Start + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +/** + * \page asfdoc_sam0_system_gclk_basic_use_case Quick Start Guide for SYSTEM CLOCK - GCLK Configuration + * + * In this use case, the GCLK module is configured for: + * \li One generator attached to the internal 8MHz RC oscillator clock source + * \li Generator output equal to input frequency divided by a factor of 128 + * \li One channel (connected to the TC0 module) enabled with the enabled generator selected + * + * This use case configures a clock channel to output a clock for a peripheral + * within the device, by first setting up a clock generator from a master clock + * source, and then linking the generator to the desired channel. This clock + * can then be used to clock a module within the device. + * + * \section asfdoc_sam0_system_gclk_basic_use_case_setup Setup + * + * \subsection asfdoc_sam0_system_gclk_basic_use_case_setup_prereq Prerequisites + * There are no special setup requirements for this use-case. + * + * \subsection asfdoc_sam0_system_gclk_basic_use_case_setup_code Code + * Copy-paste the following setup code to your user application: + * \snippet qs_gclk_basic.c setup + * + * Add to user application initialization (typically the start of \c main()): + * \snippet qs_gclk_basic.c setup_init + * + * \subsection asfdoc_sam0_system_gclk_basic_use_case_setup_flow Workflow + * -# Create a GCLK generator configuration struct, which can be filled out to + * adjust the configuration of a single clock generator. + * \snippet qs_gclk_basic.c setup_1 + * -# Initialize the generator configuration struct with the module's default + * values. + * \snippet qs_gclk_basic.c setup_2 + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Adjust the configuration struct to request that the master clock source + * channel 0 be used as the source of the generator, and set the generator + * output prescaler to divide the input clock by a factor of 128. + * \snippet qs_gclk_basic.c setup_3 + * -# Configure the generator using the configuration structure. + * \snippet qs_gclk_basic.c setup_4 + * \note The existing configuration struct may be re-used, as long as any + * values that have been altered from the default settings are taken + * into account by the user application. + * + * -# Enable the generator once it has been properly configured, to begin clock + * generation. + * \snippet qs_gclk_basic.c setup_5 + * + * -# Create a GCLK channel configuration struct, which can be filled out to + * adjust the configuration of a single generic clock channel. + * \snippet qs_gclk_basic.c setup_6 + * -# Initialize the channel configuration struct with the module's default + * values. + * \snippet qs_gclk_basic.c setup_7 + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Adjust the configuration struct to request that the previously configured + * and enabled clock generator be used as the clock source for the channel. + * \snippet qs_gclk_basic.c setup_8 + * -# Configure the channel using the configuration structure. + * \snippet qs_gclk_basic.c setup_9 + * \note The existing configuration struct may be re-used, as long as any + * values that have been altered from the default settings are taken + * into account by the user application. + * + * -# Enable the channel once it has been properly configured, to output the + * clock to the channel's peripheral module consumers. + * \snippet qs_gclk_basic.c setup_10 + * + * \section asfdoc_sam0_system_gclk_basic_use_case_main Use Case + * + * \subsection asfdoc_sam0_system_gclk_basic_use_case_code Code + * Copy-paste the following code to your user application: + * \snippet qs_gclk_basic.c main + * + * \subsection asfdoc_sam0_system_gclk_basic_use_case_flow Workflow + * -# As the clock is generated asynchronously to the system core, no special + * extra application code is required. + */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/interrupt/quick_start/qs_system_interrupt.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/interrupt/quick_start/qs_system_interrupt.h new file mode 100755 index 0000000..a01033f --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/interrupt/quick_start/qs_system_interrupt.h @@ -0,0 +1,102 @@ +/** + * \file + * + * \brief SAM System Interrupt Driver Quick Start + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +/** + * \page asfdoc_sam0_system_interrupt_critsec_use_case Quick Start Guide for SYSTEM INTERRUPT - Critical Section Use Case + * + * In this case we perform a critical piece of code, disabling all interrupts + * while a global shared flag is read. During the critical section, no interrupts + * may occur. + * + * \section asfdoc_sam0_system_interrupt_critsec_use_case_setup Setup + * + * \subsection asfdoc_sam0_system_interrupt_critsec_use_case_setup_prereq Prerequisites + * There are no special setup requirements for this use-case. + * + * \section asfdoc_sam0_system_interrupt_critsec_use_case_use_main Use Case + * + * \subsection asfdoc_sam0_system_interrupt_critsec_use_case_code Code + * Copy-paste the following code to your user application: + * \snippet qs_system_interrupt.c main_1 + * + * \subsection asfdoc_sam0_system_interrupt_critsec_use_case_flow Workflow + * -# Enter a critical section to disable global interrupts. + * \snippet qs_system_interrupt.c critical_section_start + * \note Critical sections may be nested if desired; if nested, global + * interrupts will only be re-enabled once the outer-most critical + * section has completed. + * + * -# Check a global shared flag and perform a response. This code may be any + * critical code that requires exclusive access to all resources without the + * possibility of interruption. + * \snippet qs_system_interrupt.c do_critical_code + * + * -# Exit the critical section to re-enable global interrupts. + * \snippet qs_system_interrupt.c critical_section_end + */ + +/** + * \page asfdoc_sam0_system_interrupt_enablemodint_use_case Quick Start Guide for SYSTEM INTERRUPT - Enable Module Interrupt Use Case + * + * In this case we enable interrupt handling for a specific module, as well as + * enable interrupts globally for the device. + * + * \section asfdoc_sam0_system_interrupt_enablemodint_use_case_setup Setup + * + * \subsection asfdoc_sam0_system_interrupt_enablemodint_use_case_setup_prereq Prerequisites + * There are no special setup requirements for this use-case. + * + * \section asfdoc_sam0_system_interrupt_enablemodint_use_case_use_main Use Case + * + * \subsection asfdoc_sam0_system_interrupt_enablemodint_use_case_code Code + * Copy-paste the following code to your user application: + * \snippet qs_system_interrupt.c main_2 + * + * \subsection asfdoc_sam0_system_interrupt_enablemodint_use_case_flow Workflow + * -# Enable interrupt handling for the device's RTC peripheral. + * \snippet qs_system_interrupt.c module_int_enable + * + * -# Enable global interrupts, so that any enabled and active interrupt sources + * can trigger their respective handler functions. + * \snippet qs_system_interrupt.c global_int_enable + */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/interrupt/system_interrupt.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/interrupt/system_interrupt.c new file mode 100755 index 0000000..606a05e --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/interrupt/system_interrupt.c @@ -0,0 +1,214 @@ +/** + * \file + * + * \brief SAM System Interrupt Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include "system_interrupt.h" + +/** + * \brief Check if a interrupt line is pending + * + * Checks if the requested interrupt vector is pending. + * + * \param[in] vector Interrupt vector number to check + * + * \returns A boolean identifying if the requested interrupt vector is pending. + * + * \retval true Specified interrupt vector is pending + * \retval false Specified interrupt vector is not pending + * + */ +bool system_interrupt_is_pending( + const enum system_interrupt_vector vector) +{ + bool result; + + if (vector >= _SYSTEM_INTERRUPT_EXTERNAL_VECTOR_START) { + result = ((NVIC->ISPR[0] & (1 << vector)) != 0); + } else if (vector == SYSTEM_INTERRUPT_SYSTICK) { + result = ((SCB->ICSR & SCB_ICSR_PENDSTSET_Msk) != 0); + } else { + Assert(false); + result = false; + } + + return result; +} + +/** + * \brief Set a interrupt vector as pending + * + * Set the requested interrupt vector as pending (i.e issues a software + * interrupt request for the specified vector). The software handler will be + * handled (if enabled) in a priority order based on vector number and + * configured priority settings. + * + * \param[in] vector Interrupt vector number which is set as pending + * + * \returns Status code identifying if the vector was successfully set as + * pending. + * + * \retval STATUS_OK If no error was detected + * \retval STATUS_INVALID_ARG If an unsupported interrupt vector number was given + */ +enum status_code system_interrupt_set_pending( + const enum system_interrupt_vector vector) +{ + enum status_code status = STATUS_OK; + + if (vector >= _SYSTEM_INTERRUPT_EXTERNAL_VECTOR_START) { + NVIC->ISPR[0] = (1 << vector); + } else if (vector == SYSTEM_INTERRUPT_NON_MASKABLE) { + /* Note: Because NMI has highest priority it will be executed + * immediately after it has been set pending */ + SCB->ICSR = SCB_ICSR_NMIPENDSET_Msk; + } else if (vector == SYSTEM_INTERRUPT_SYSTICK) { + SCB->ICSR = SCB_ICSR_PENDSTSET_Msk; + } else { + /* The user want to set something unsupported as pending */ + Assert(false); + status = STATUS_ERR_INVALID_ARG; + } + + return status; +} + +/** + * \brief Clear pending interrupt vector + * + * Clear a pending interrupt vector, so the software handler is not executed. + * + * \param[in] vector Interrupt vector number to clear + * + * \returns A status code identifying if the interrupt pending state was + * successfully cleared. + * + * \retval STATUS_OK If no error was detected + * \retval STATUS_INVALID_ARG If an unsupported interrupt vector number was given + */ +enum status_code system_interrupt_clear_pending( + const enum system_interrupt_vector vector) +{ + enum status_code status = STATUS_OK; + + if (vector >= _SYSTEM_INTERRUPT_EXTERNAL_VECTOR_START) { + NVIC->ICPR[0] = (1 << vector); + } else if (vector == SYSTEM_INTERRUPT_NON_MASKABLE) { + /* Note: Clearing of NMI pending interrupts does not make sense and is + * not supported by the device, as it has the highest priority and will + * always be executed at the moment it is set */ + return STATUS_ERR_INVALID_ARG; + } else if (vector == SYSTEM_INTERRUPT_SYSTICK) { + SCB->ICSR = SCB_ICSR_PENDSTCLR_Msk; + } else { + Assert(false); + status = STATUS_ERR_INVALID_ARG; + } + + return status; +} + +/** + * \brief Set interrupt vector priority level + * + * Set the priority level of an external interrupt or exception. + * + * \param[in] vector Interrupt vector to change + * \param[in] priority_level New vector priority level to set + * + * \returns Status code indicating if the priority level of the interrupt was + * successfully set. + * + * \retval STATUS_OK If no error was detected + * \retval STATUS_INVALID_ARG If an unsupported interrupt vector number was given + */ +enum status_code system_interrupt_set_priority( + const enum system_interrupt_vector vector, + const enum system_interrupt_priority_level priority_level) +{ + enum status_code status = STATUS_OK; + + if (vector >= _SYSTEM_INTERRUPT_EXTERNAL_VECTOR_START) { + uint8_t register_num = vector / 4; + uint8_t priority_pos = ((vector % 4) * 8) + (8 - __NVIC_PRIO_BITS); + + NVIC->IP[register_num] = + (NVIC->IP[register_num] & ~(0x3 << priority_pos)) | + (priority_level << priority_pos); + + } else if (vector == SYSTEM_INTERRUPT_SYSTICK) { + SCB->SHP[1] = (priority_level << _SYSTEM_INTERRUPT_SYSTICK_PRI_POS); + } else { + Assert(false); + status = STATUS_ERR_INVALID_ARG; + } + + return status; +} + +/** + * \brief Get interrupt vector priority level + * + * Retrieves the priority level of the requested external interrupt or exception. + * + * \param[in] vector Interrupt vector of which the priority level will be read + * + * \return Currently configured interrupt priority level of the given interrupt + * vector. + */ +enum system_interrupt_priority_level system_interrupt_get_priority( + const enum system_interrupt_vector vector) +{ + uint8_t register_num = vector / 4; + uint8_t priority_pos = ((vector % 4) * 8) + (8 - __NVIC_PRIO_BITS); + + enum system_interrupt_priority_level priority = SYSTEM_INTERRUPT_PRIORITY_LEVEL_0; + + if (vector >= 0) { + priority = (enum system_interrupt_priority_level) + ((NVIC->IP[register_num] >> priority_pos) & _SYSTEM_INTERRUPT_PRIORITY_MASK); + } else if (vector == SYSTEM_INTERRUPT_SYSTICK) { + priority = (enum system_interrupt_priority_level) + ((SCB->SHP[1] >> _SYSTEM_INTERRUPT_SYSTICK_PRI_POS) & _SYSTEM_INTERRUPT_PRIORITY_MASK); + } + + return priority; +} + diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/interrupt/system_interrupt.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/interrupt/system_interrupt.h new file mode 100755 index 0000000..03dd4fd --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/interrupt/system_interrupt.h @@ -0,0 +1,431 @@ +/** + * \file + * + * \brief SAM System Interrupt Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef SYSTEM_INTERRUPT_H_INCLUDED +#define SYSTEM_INTERRUPT_H_INCLUDED + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \defgroup asfdoc_sam0_system_interrupt_group SAM System Interrupt Driver (SYSTEM INTERRUPT) + * + * This driver for SAM devices provides an interface for the configuration + * and management of internal software and hardware interrupts/exceptions. + * + * The following peripherals are used by this module: + * - NVIC (Nested Vector Interrupt Controller) + * + * The following devices can use this module: + * - SAM D20/D21 + * - SAM R21 + * - SAM D10/D11 + * + * The outline of this documentation is as follows: + * - \ref asfdoc_sam0_system_interrupt_prerequisites + * - \ref asfdoc_sam0_system_interrupt_module_overview + * - \ref asfdoc_sam0_system_interrupt_special_considerations + * - \ref asfdoc_sam0_system_interrupt_extra_info + * - \ref asfdoc_sam0_system_interrupt_examples + * - \ref asfdoc_sam0_system_interrupt_api_overview + * + * + * \section asfdoc_sam0_system_interrupt_prerequisites Prerequisites + * + * There are no prerequisites for this module. + * + * + * \section asfdoc_sam0_system_interrupt_module_overview Module Overview + * + * The ARM® Cortex® M0+ core contains an interrupt an exception vector table, which + * can be used to configure the device's interrupt handlers; individual + * interrupts and exceptions can be enabled and disabled, as well as configured + * with a variable priority. + * + * This driver provides a set of wrappers around the core interrupt functions, + * to expose a simple API for the management of global and individual interrupts + * within the device. + * + * \subsection asfdoc_sam0_system_interrupt_module_overview_criticalsec Critical Sections + * In some applications it is important to ensure that no interrupts may be + * executed by the system whilst a critical portion of code is being run; for + * example, a buffer may be copied from one context to another - during which + * interrupts must be disabled to avoid corruption of the source buffer contents + * until the copy has completed. This driver provides a basic API to enter and + * exit nested critical sections, so that global interrupts can be kept disabled + * for as long as necessary to complete a critical application code section. + * + * \subsection asfdoc_sam0_system_interrupt_module_overview_softints Software Interrupts + * For some applications, it may be desirable to raise a module or core + * interrupt via software. For this reason, a set of APIs to set an interrupt or + * exception as pending are provided to the user application. + * + * \section asfdoc_sam0_system_interrupt_special_considerations Special Considerations + * + * Interrupts from peripherals in the SAM devices are on a per-module basis; + * an interrupt raised from any source within a module will cause a single, + * module-common handler to execute. It is the user application or driver's + * responsibility to de-multiplex the module-common interrupt to determine the + * exact interrupt cause. + * + * \section asfdoc_sam0_system_interrupt_extra_info Extra Information + * + * For extra information see \ref asfdoc_sam0_system_interrupt_extra. This includes: + * - \ref asfdoc_sam0_system_interrupt_extra_acronyms + * - \ref asfdoc_sam0_system_interrupt_extra_dependencies + * - \ref asfdoc_sam0_system_interrupt_extra_errata + * - \ref asfdoc_sam0_system_interrupt_extra_history + * + * + * \section asfdoc_sam0_system_interrupt_examples Examples + * + * For a list of examples related to this driver, see + * \ref asfdoc_sam0_system_interrupt_exqsg. + * + * \section asfdoc_sam0_system_interrupt_api_overview API Overview + * @{ + */ + +#include +#include +#include "system_interrupt_features.h" + +/** + * \brief Table of possible system interrupt/exception vector priorities. + * + * Table of all possible interrupt and exception vector priorities within the + * device. + */ +enum system_interrupt_priority_level { + /** Priority level 0, the highest possible interrupt priority. */ + SYSTEM_INTERRUPT_PRIORITY_LEVEL_0 = 0, + /** Priority level 1. */ + SYSTEM_INTERRUPT_PRIORITY_LEVEL_1 = 1, + /** Priority level 2. */ + SYSTEM_INTERRUPT_PRIORITY_LEVEL_2 = 2, + /** Priority level 3, the lowest possible interrupt priority. */ + SYSTEM_INTERRUPT_PRIORITY_LEVEL_3 = 3, +}; + +/** + * \name Critical Section Management + * @{ + */ + +/** + * \brief Enters a critical section + * + * Disables global interrupts. To support nested critical sections, an internal + * count of the critical section nesting will be kept, so that global interrupts + * are only re-enabled upon leaving the outermost nested critical section. + * + */ +static inline void system_interrupt_enter_critical_section(void) +{ + cpu_irq_enter_critical(); +} + +/** + * \brief Leaves a critical section + * + * Enables global interrupts. To support nested critical sections, an internal + * count of the critical section nesting will be kept, so that global interrupts + * are only re-enabled upon leaving the outermost nested critical section. + * + */ +static inline void system_interrupt_leave_critical_section(void) +{ + cpu_irq_leave_critical(); +} + +/** @} */ + +/** + * \name Interrupt Enabling/Disabling + * @{ + */ + +/** + * \brief Check if global interrupts are enabled + * + * Checks if global interrupts are currently enabled. + * + * \returns A boolean that identifies if the global interrupts are enabled or not. + * + * \retval true Global interrupts are currently enabled + * \retval false Global interrupts are currently disabled + * + */ +static inline bool system_interrupt_is_global_enabled(void) +{ + return cpu_irq_is_enabled(); +} + +/** + * \brief Enables global interrupts + * + * Enables global interrupts in the device to fire any enabled interrupt handlers. + */ +static inline void system_interrupt_enable_global(void) +{ + cpu_irq_enable(); +} + +/** + * \brief Disables global interrupts + * + * Disabled global interrupts in the device, preventing any enabled interrupt + * handlers from executing. + */ +static inline void system_interrupt_disable_global(void) +{ + cpu_irq_disable(); +} + +/** + * \brief Checks if an interrupt vector is enabled or not + * + * Checks if a specific interrupt vector is currently enabled. + * + * \param[in] vector Interrupt vector number to check + * + * \returns A variable identifying if the requested interrupt vector is enabled + * + * \retval true Specified interrupt vector is currently enabled + * \retval false Specified interrupt vector is currently disabled + * + */ +static inline bool system_interrupt_is_enabled( + const enum system_interrupt_vector vector) +{ + return (bool)((NVIC->ISER[0] >> (uint32_t)vector) & 0x00000001); +} + +/** + * \brief Enable interrupt vector + * + * Enables execution of the software handler for the requested interrupt vector. + * + * \param[in] vector Interrupt vector to enable + */ +static inline void system_interrupt_enable( + const enum system_interrupt_vector vector) +{ + NVIC->ISER[0] = (uint32_t)(1 << ((uint32_t)vector & 0x0000001f)); +} + +/** + * \brief Disable interrupt vector + * + * Disables execution of the software handler for the requested interrupt vector. + * + * \param[in] vector Interrupt vector to disable + */ +static inline void system_interrupt_disable( + const enum system_interrupt_vector vector) +{ + NVIC->ICER[0] = (uint32_t)(1 << ((uint32_t)vector & 0x0000001f)); +} + +/** @} */ + +/** + * \name Interrupt State Management + * @{ + */ + +/** + * \brief Get active interrupt (if any) + * + * Return the vector number for the current executing software handler, if any. + * + * \return Interrupt number that is currently executing. + */ +static inline enum system_interrupt_vector system_interrupt_get_active(void) +{ + uint32_t IPSR = __get_IPSR(); + + return (enum system_interrupt_vector)(IPSR & _SYSTEM_INTERRUPT_IPSR_MASK); +} + +bool system_interrupt_is_pending( + const enum system_interrupt_vector vector); + +enum status_code system_interrupt_set_pending( + const enum system_interrupt_vector vector); + +enum status_code system_interrupt_clear_pending( + const enum system_interrupt_vector vector); + +/** @} */ + +/** + * \name Interrupt Priority Management + * @{ + */ + +enum status_code system_interrupt_set_priority( + const enum system_interrupt_vector vector, + const enum system_interrupt_priority_level priority_level); + +enum system_interrupt_priority_level system_interrupt_get_priority( + const enum system_interrupt_vector vector); + +/** @} */ + +/** @} */ + +/** + * \page asfdoc_sam0_system_interrupt_extra Extra Information for SYSTEM INTERRUPT Driver + * + * \section asfdoc_sam0_system_interrupt_extra_acronyms Acronyms + * The table below presents the acronyms used in this module: + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
AcronymDescription
ISRInterrupt Service Routine
NMINon-maskable interrupt
SERCOMSerial Communication Interface
+ * + * + * \section asfdoc_sam0_system_interrupt_extra_dependencies Dependencies + * This driver has the following dependencies: + * + * - None + * + * + * \section asfdoc_sam0_system_interrupt_extra_errata Errata + * There are no errata related to this driver. + * + * + * \section asfdoc_sam0_system_interrupt_extra_history Module History + * An overview of the module history is presented in the table below, with + * details on the enhancements and fixes made to the module since its first + * release. The current version of this corresponds to the newest version in + * the table. + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Changelog
Added support for SAMD10/D11
Added support for SAMR21
Added support for SAMD21
Initial Release
+ */ + +/** + * \page asfdoc_sam0_system_interrupt_exqsg Examples for SYSTEM INTERRUPT Driver + * + * This is a list of the available Quick Start guides (QSGs) and example + * applications for \ref asfdoc_sam0_system_interrupt_group. QSGs are simple examples with + * step-by-step instructions to configure and use this driver in a selection of + * use cases. Note that QSGs can be compiled as a standalone application or be + * added to the user application. + * + * - \subpage asfdoc_sam0_system_interrupt_critsec_use_case + * - \subpage asfdoc_sam0_system_interrupt_enablemodint_use_case + * + * \page asfdoc_sam0_system_interrupt_document_revision_history Document Revision History + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Doc. Rev. + * Date + * Comments + *
E04/2014Add support for SAMD10/D11.
D02/2014Add support for SAMR21.
C01/2014Add support for SAMD21.
B06/2013Corrected documentation typos.
A06/2013Initial release
+ */ + +#ifdef __cplusplus +} +#endif + +#endif // #ifndef SYSTEM_INTERRUPT_H_INCLUDED diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/interrupt/system_interrupt_samd21/system_interrupt_features.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/interrupt/system_interrupt_samd21/system_interrupt_features.h new file mode 100755 index 0000000..9e7c31a --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/interrupt/system_interrupt_samd21/system_interrupt_features.h @@ -0,0 +1,170 @@ +/** + * \file + * + * \brief SAM D21 System Interrupt Driver + * + * Copyright (C) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef SYSTEM_INTERRUPT_FEATURES_H_INCLUDED +#define SYSTEM_INTERRUPT_FEATURES_H_INCLUDED + +#if !defined(__DOXYGEN__) + +/* Generates a interrupt vector table enum list entry for a given module type + and index (e.g. "SYSTEM_INTERRUPT_MODULE_TC0 = TC0_IRQn,"). */ +# define _MODULE_IRQn(n, module) \ + SYSTEM_INTERRUPT_MODULE_##module##n = module##n##_IRQn, + +/* Generates interrupt vector table enum list entries for all instances of a + given module type on the selected device. */ +# define _SYSTEM_INTERRUPT_MODULES(name) \ + MREPEAT(name##_INST_NUM, _MODULE_IRQn, name) + +# define _SYSTEM_INTERRUPT_IPSR_MASK 0x0000003f +# define _SYSTEM_INTERRUPT_PRIORITY_MASK 0x00000007 + +# define _SYSTEM_INTERRUPT_EXTERNAL_VECTOR_START 0 + +# define _SYSTEM_INTERRUPT_SYSTICK_PRI_POS 29 +#endif + +/** + * \addtogroup asfdoc_sam0_system_interrupt_group + * @{ + */ + +/** + * \brief Table of possible system interrupt/exception vector numbers. + * + * Table of all possible interrupt and exception vector indexes within the + * SAMD21 device. + */ +#if defined(__DOXYGEN__) +/** \note The actual enumeration name is "system_interrupt_vector". */ +enum system_interrupt_vector_samd21 { +#else +enum system_interrupt_vector { +#endif + /** Interrupt vector index for a NMI interrupt. */ + SYSTEM_INTERRUPT_NON_MASKABLE = NonMaskableInt_IRQn, + /** Interrupt vector index for a Hard Fault memory access exception. */ + SYSTEM_INTERRUPT_HARD_FAULT = HardFault_IRQn, + /** Interrupt vector index for a Supervisor Call exception. */ + SYSTEM_INTERRUPT_SV_CALL = SVCall_IRQn, + /** Interrupt vector index for a Pending Supervisor interrupt. */ + SYSTEM_INTERRUPT_PENDING_SV = PendSV_IRQn, + /** Interrupt vector index for a System Tick interrupt. */ + SYSTEM_INTERRUPT_SYSTICK = SysTick_IRQn, + + /** Interrupt vector index for a Power Manager peripheral interrupt. */ + SYSTEM_INTERRUPT_MODULE_PM = PM_IRQn, + /** Interrupt vector index for a System Control peripheral interrupt. */ + SYSTEM_INTERRUPT_MODULE_SYSCTRL = SYSCTRL_IRQn, + /** Interrupt vector index for a Watch Dog peripheral interrupt. */ + SYSTEM_INTERRUPT_MODULE_WDT = WDT_IRQn, + /** Interrupt vector index for a Real Time Clock peripheral interrupt. */ + SYSTEM_INTERRUPT_MODULE_RTC = RTC_IRQn, + /** Interrupt vector index for an External Interrupt peripheral interrupt. */ + SYSTEM_INTERRUPT_MODULE_EIC = EIC_IRQn, + /** Interrupt vector index for a Non Volatile Memory Controller interrupt. */ + SYSTEM_INTERRUPT_MODULE_NVMCTRL = NVMCTRL_IRQn, + /** Interrupt vector index for a Direct Memory Access interrupt. */ + SYSTEM_INTERRUPT_MODULE_DMA = DMAC_IRQn, + /** Interrupt vector index for a Universal Serial Bus interrupt. */ + SYSTEM_INTERRUPT_MODULE_USB = USB_IRQn, + /** Interrupt vector index for an Event System interrupt. */ + SYSTEM_INTERRUPT_MODULE_EVSYS = EVSYS_IRQn, +#if defined(__DOXYGEN__) + /** Interrupt vector index for a SERCOM peripheral interrupt. + * + * Each specific device may contain several SERCOM peripherals; each module + * instance will have its own entry in the table, with the instance number + * substituted for "n" in the entry name (e.g. + * \c SYSTEM_INTERRUPT_MODULE_SERCOM0). + */ + SYSTEM_INTERRUPT_MODULE_SERCOMn = SERCOMn_IRQn, + + /** Interrupt vector index for a Timer/Counter Control peripheral interrupt. + * + * Each specific device may contain several TCC peripherals; each module + * instance will have its own entry in the table, with the instance number + * substituted for "n" in the entry name (e.g. + * \c SYSTEM_INTERRUPT_MODULE_TCC0). + */ + SYSTEM_INTERRUPT_MODULE_TCCn = TCCn_IRQn, + + /** Interrupt vector index for a Timer/Counter peripheral interrupt. + * + * Each specific device may contain several TC peripherals; each module + * instance will have its own entry in the table, with the instance number + * substituted for "n" in the entry name (e.g. + * \c SYSTEM_INTERRUPT_MODULE_TC3). + */ + SYSTEM_INTERRUPT_MODULE_TCn = TCn_IRQn, +#else + _SYSTEM_INTERRUPT_MODULES(SERCOM) + + _SYSTEM_INTERRUPT_MODULES(TCC) + + SYSTEM_INTERRUPT_MODULE_TC3 = TC3_IRQn, + SYSTEM_INTERRUPT_MODULE_TC4 = TC4_IRQn, + SYSTEM_INTERRUPT_MODULE_TC5 = TC5_IRQn, +# if (SAMD21J) + //SYSTEM_INTERRUPT_MODULE_TC6 = TC6_IRQn, + //SYSTEM_INTERRUPT_MODULE_TC7 = TC7_IRQn, +# endif +#endif + + /** Interrupt vector index for an Analog Comparator peripheral interrupt. */ + SYSTEM_INTERRUPT_MODULE_AC = AC_IRQn, + /** Interrupt vector index for an Analog-to-Digital peripheral interrupt. */ + SYSTEM_INTERRUPT_MODULE_ADC = ADC_IRQn, + /** Interrupt vector index for a Digital-to-Analog peripheral interrupt. */ + SYSTEM_INTERRUPT_MODULE_DAC = DAC_IRQn, + /** Interrupt vector index for a Peripheral Touch Controller peripheral + * interrupt. */ + SYSTEM_INTERRUPT_MODULE_PTC = PTC_IRQn, + /** Interrupt vector index for a Inter-IC Sound Interface peripheral + * interrupt. */ + SYSTEM_INTERRUPT_MODULE_I2S = I2S_IRQn, +}; + +/** @} */ + +#endif diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/pinmux/pinmux.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/pinmux/pinmux.c new file mode 100755 index 0000000..6ae65ac --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/pinmux/pinmux.c @@ -0,0 +1,215 @@ +/** + * \file + * + * \brief SAM Pin Multiplexer Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include + +/** + * \internal + * Writes out a given configuration of a Port pin configuration to the + * hardware module. + * + * \note If the pin direction is set as an output, the pull-up/pull-down input + * configuration setting is ignored. + * + * \param[in] port Base of the PORT module to configure. + * \param[in] pin_mask Mask of the port pin to configure. + * \param[in] config Configuration settings for the pin. + */ +static void _system_pinmux_config( + PortGroup *const port, + const uint32_t pin_mask, + const struct system_pinmux_config *const config) +{ + Assert(port); + Assert(config); + + /* Track the configuration bits into a temporary variable before writing */ + uint32_t pin_cfg = 0; + + /* Enabled powersave mode, don't create configuration */ + if (!config->powersave) { + /* Enable the pin peripheral mux flag if non-GPIO selected (pin mux will + * be written later) and store the new mux mask */ + if (config->mux_position != SYSTEM_PINMUX_GPIO) { + pin_cfg |= PORT_WRCONFIG_PMUXEN; + pin_cfg |= (config->mux_position << PORT_WRCONFIG_PMUX_Pos); + } + + /* Check if the user has requested that the input buffer be enabled */ + if ((config->direction == SYSTEM_PINMUX_PIN_DIR_INPUT) || + (config->direction == SYSTEM_PINMUX_PIN_DIR_OUTPUT_WITH_READBACK)) { + /* Enable input buffer flag */ + pin_cfg |= PORT_WRCONFIG_INEN; + + /* Enable pull-up/pull-down control flag if requested */ + if (config->input_pull != SYSTEM_PINMUX_PIN_PULL_NONE) { + pin_cfg |= PORT_WRCONFIG_PULLEN; + } + + /* Clear the port DIR bits to disable the output buffer */ + port->DIRCLR.reg = pin_mask; + } + + /* Check if the user has requested that the output buffer be enabled */ + if ((config->direction == SYSTEM_PINMUX_PIN_DIR_OUTPUT) || + (config->direction == SYSTEM_PINMUX_PIN_DIR_OUTPUT_WITH_READBACK)) { + /* Cannot use a pullup if the output driver is enabled, + * if requested the input buffer can only sample the current + * output state */ + pin_cfg &= ~PORT_WRCONFIG_PULLEN; + } + } + + /* The Write Configuration register (WRCONFIG) requires the + * pins to to grouped into two 16-bit half-words - split them out here */ + uint32_t lower_pin_mask = (pin_mask & 0xFFFF); + uint32_t upper_pin_mask = (pin_mask >> 16); + + /* Configure the lower 16-bits of the port to the desired configuration, + * including the pin peripheral multiplexer just in case it is enabled */ + port->WRCONFIG.reg + = (lower_pin_mask << PORT_WRCONFIG_PINMASK_Pos) | + pin_cfg | PORT_WRCONFIG_WRPMUX | PORT_WRCONFIG_WRPINCFG; + + /* Configure the upper 16-bits of the port to the desired configuration, + * including the pin peripheral multiplexer just in case it is enabled */ + port->WRCONFIG.reg + = (upper_pin_mask << PORT_WRCONFIG_PINMASK_Pos) | + pin_cfg | PORT_WRCONFIG_WRPMUX | PORT_WRCONFIG_WRPINCFG | + PORT_WRCONFIG_HWSEL; + + if(!config->powersave) { + /* Set the pull-up state once the port pins are configured if one was + * requested and it does not violate the valid set of port + * configurations */ + if (pin_cfg & PORT_WRCONFIG_PULLEN) { + /* Set the OUT register bits to enable the pullup if requested, + * clear to enable pull-down */ + if (config->input_pull == SYSTEM_PINMUX_PIN_PULL_UP) { + port->OUTSET.reg = pin_mask; + } else { + port->OUTCLR.reg = pin_mask; + } + } + + /* Check if the user has requested that the output buffer be enabled */ + if ((config->direction == SYSTEM_PINMUX_PIN_DIR_OUTPUT) || + (config->direction == SYSTEM_PINMUX_PIN_DIR_OUTPUT_WITH_READBACK)) { + /* Set the port DIR bits to enable the output buffer */ + port->DIRSET.reg = pin_mask; + } + } +} + +/** + * \brief Writes a Port pin configuration to the hardware module. + * + * Writes out a given configuration of a Port pin configuration to the hardware + * module. + * + * \note If the pin direction is set as an output, the pull-up/pull-down input + * configuration setting is ignored. + * + * \param[in] gpio_pin Index of the GPIO pin to configure. + * \param[in] config Configuration settings for the pin. + */ +void system_pinmux_pin_set_config( + const uint8_t gpio_pin, + const struct system_pinmux_config *const config) +{ + PortGroup *const port = system_pinmux_get_group_from_gpio_pin(gpio_pin); + uint32_t pin_mask = (1UL << (gpio_pin % 32)); + + _system_pinmux_config(port, pin_mask, config); +} + +/** + * \brief Writes a Port pin group configuration to the hardware module. + * + * Writes out a given configuration of a Port pin group configuration to the + * hardware module. + * + * \note If the pin direction is set as an output, the pull-up/pull-down input + * configuration setting is ignored. + * + * \param[in] port Base of the PORT module to configure. + * \param[in] mask Mask of the port pin(s) to configure. + * \param[in] config Configuration settings for the pin. + */ +void system_pinmux_group_set_config( + PortGroup *const port, + const uint32_t mask, + const struct system_pinmux_config *const config) +{ + Assert(port); + + for (int i = 0; i < 32; i++) { + if (mask & (1UL << i)) { + _system_pinmux_config(port, (1UL << i), config); + } + } +} + +/** + * \brief Configures the input sampling mode for a group of pins. + * + * Configures the input sampling mode for a group of pins, to + * control when the physical I/O pin value is sampled and + * stored inside the microcontroller. + * + * \param[in] port Base of the PORT module to configure. + * \param[in] mask Mask of the port pin(s) to configure. + * \param[in] mode New pin sampling mode to configure. + */ +void system_pinmux_group_set_input_sample_mode( + PortGroup *const port, + const uint32_t mask, + const enum system_pinmux_pin_sample mode) +{ + Assert(port); + + if (mode == SYSTEM_PINMUX_PIN_SAMPLE_ONDEMAND) { + port->CTRL.reg |= mask; + } else { + port->CTRL.reg &= ~mask; + } +} diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/pinmux/pinmux.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/pinmux/pinmux.h new file mode 100755 index 0000000..370c3db --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/pinmux/pinmux.h @@ -0,0 +1,517 @@ +/** + * \file + * + * \brief SAM Pin Multiplexer Driver + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef PINMUX_H_INCLUDED +#define PINMUX_H_INCLUDED + +/** + * \defgroup asfdoc_sam0_system_pinmux_group SAM System Pin Multiplexer Driver (SYSTEM PINMUX) + * + * This driver for SAM devices provides an interface for the configuration + * and management of the device's physical I/O Pins, to alter the direction and + * input/drive characteristics as well as to configure the pin peripheral + * multiplexer selection. + * + * The following peripherals are used by this module: + * - PORT (Port I/O Management) + * + * The following devices can use this module: + * - SAM D20/D21 + * - SAM R21 + * - SAM D10/D11 + * + * Physically, the modules are interconnected within the device as shown in the + * following diagram: + * + * The outline of this documentation is as follows: + * - \ref asfdoc_sam0_system_pinmux_prerequisites + * - \ref asfdoc_sam0_system_pinmux_module_overview + * - \ref asfdoc_sam0_system_pinmux_special_considerations + * - \ref asfdoc_sam0_system_pinmux_extra_info + * - \ref asfdoc_sam0_system_pinmux_examples + * - \ref asfdoc_sam0_system_pinmux_api_overview + * + * + * \section asfdoc_sam0_system_pinmux_prerequisites Prerequisites + * + * There are no prerequisites for this module. + * + * + * \section asfdoc_sam0_system_pinmux_module_overview Module Overview + * + * The SAM devices contain a number of General Purpose I/O pins, used to + * interface the user application logic and internal hardware peripherals to + * an external system. The Pin Multiplexer (PINMUX) driver provides a method + * of configuring the individual pin peripheral multiplexers to select + * alternate pin functions. + * + * \subsection asfdoc_sam0_system_pinmux_physical_logical_pins Physical and Logical GPIO Pins + * SAM devices use two naming conventions for the I/O pins in the device; one + * physical, and one logical. Each physical pin on a device package is assigned + * both a physical port and pin identifier (e.g. "PORTA.0") as well as a + * monotonically incrementing logical GPIO number (e.g. "GPIO0"). While the + * former is used to map physical pins to their physical internal device module + * counterparts, for simplicity the design of this driver uses the logical GPIO + * numbers instead. + * + * \subsection asfdoc_sam0_system_pinmux_peripheral_muxing Peripheral Multiplexing + * SAM devices contain a peripheral MUX, which is individually controllable + * for each I/O pin of the device. The peripheral MUX allows you to select the + * function of a physical package pin - whether it will be controlled as a user + * controllable GPIO pin, or whether it will be connected internally to one of + * several peripheral modules (such as an I2C module). When a pin is + * configured in GPIO mode, other peripherals connected to the same pin will be + * disabled. + * + * \subsection asfdoc_sam0_system_pinmux_pad_characteristics Special Pad Characteristics + * There are several special modes that can be selected on one or more I/O pins + * of the device, which alter the input and output characteristics of the pad: + * + * \subsubsection asfdoc_sam0_system_pinmux_drive_strength Drive Strength + * The Drive Strength configures the strength of the output driver on the + * pad. Normally, there is a fixed current limit that each I/O pin can safely + * drive, however some I/O pads offer a higher drive mode which increases this + * limit for that I/O pin at the expense of an increased power consumption. + * + * \subsubsection asfdoc_sam0_system_pinmux_slew_rate Slew Rate + * The Slew Rate configures the slew rate of the output driver, limiting the + * rate at which the pad output voltage can change with time. + * + * \subsubsection asfdoc_sam0_system_pinmux_input_sample_mode Input Sample Mode + * The Input Sample Mode configures the input sampler buffer of the pad. By + * default, the input buffer is only sampled "on-demand", i.e. when the user + * application attempts to read from the input buffer. This mode is the most + * power efficient, but increases the latency of the input sample by two clock + * cycles of the port clock. To reduce latency, the input sampler can instead + * be configured to always sample the input buffer on each port clock cycle, at + * the expense of an increased power consumption. + * + * \subsection asfdoc_sam0_system_pinmux_module_overview_physical Physical Connection + * + * \ref asfdoc_sam0_system_pinmux_intconnections "The diagram below" shows + * how this module is interconnected within the device: + * + * \anchor asfdoc_sam0_system_pinmux_intconnections + * \dot + * digraph overview { + * node [label="Port Pad" shape=square] pad; + * + * subgraph driver { + * node [label="Peripheral Mux" shape=trapezium] pinmux; + * node [label="GPIO Module" shape=ellipse shape=ellipse style=filled fillcolor=lightgray] gpio; + * node [label="Other Peripheral Modules" shape=ellipse style=filled fillcolor=lightgray] peripherals; + * } + * + * pinmux -> gpio; + * pad -> pinmux; + * pinmux -> peripherals; + * } + * \enddot + * + * \section asfdoc_sam0_system_pinmux_special_considerations Special Considerations + * + * The SAM port pin input sampling mode is set in groups of four physical + * pins; setting the sampling mode of any pin in a sub-group of eight I/O pins + * will configure the sampling mode of the entire sub-group. + * + * High Drive Strength output driver mode is not available on all device pins - + * refer to your device specific datasheet. + * + * + * \section asfdoc_sam0_system_pinmux_extra_info Extra Information + * + * For extra information see \ref asfdoc_sam0_system_pinmux_extra. This includes: + * - \ref asfdoc_sam0_system_pinmux_extra_acronyms + * - \ref asfdoc_sam0_system_pinmux_extra_dependencies + * - \ref asfdoc_sam0_system_pinmux_extra_errata + * - \ref asfdoc_sam0_system_pinmux_extra_history + * + * + * \section asfdoc_sam0_system_pinmux_examples Examples + * + * For a list of examples related to this driver, see + * \ref asfdoc_sam0_system_pinmux_exqsg. + * + * + * \section asfdoc_sam0_system_pinmux_api_overview API Overview + * @{ + */ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** Peripheral multiplexer index to select GPIO mode for a pin. */ +#define SYSTEM_PINMUX_GPIO (1 << 7) + +/** + * \brief Port pin direction configuration enum. + * + * Enum for the possible pin direction settings of the port pin configuration + * structure, to indicate the direction the pin should use. + */ +enum system_pinmux_pin_dir { + /** The pin's input buffer should be enabled, so that the pin state can + * be read. */ + SYSTEM_PINMUX_PIN_DIR_INPUT, + /** The pin's output buffer should be enabled, so that the pin state can + * be set (but not read back). */ + SYSTEM_PINMUX_PIN_DIR_OUTPUT, + /** The pin's output and input buffers should both be enabled, so that the + * pin state can be set and read back. */ + SYSTEM_PINMUX_PIN_DIR_OUTPUT_WITH_READBACK, +}; + +/** + * \brief Port pin input pull configuration enum. + * + * Enum for the possible pin pull settings of the port pin configuration + * structure, to indicate the type of logic level pull the pin should use. + */ +enum system_pinmux_pin_pull { + /** No logical pull should be applied to the pin. */ + SYSTEM_PINMUX_PIN_PULL_NONE, + /** Pin should be pulled up when idle. */ + SYSTEM_PINMUX_PIN_PULL_UP, + /** Pin should be pulled down when idle. */ + SYSTEM_PINMUX_PIN_PULL_DOWN, +}; + +/** + * \brief Port pin digital input sampling mode enum. + * + * Enum for the possible input sampling modes for the port pin configuration + * structure, to indicate the type of sampling a port pin should use. + */ +enum system_pinmux_pin_sample { + /** Pin input buffer should continuously sample the pin state. */ + SYSTEM_PINMUX_PIN_SAMPLE_CONTINUOUS, + /** Pin input buffer should be enabled when the IN register is read. */ + SYSTEM_PINMUX_PIN_SAMPLE_ONDEMAND, +}; + +/** + * \brief Port pin configuration structure. + * + * Configuration structure for a port pin instance. This structure should be + * structure should be initialized by the + * \ref system_pinmux_get_config_defaults() function before being modified by + * the user application. + */ +struct system_pinmux_config { + /** MUX index of the peripheral that should control the pin, if peripheral + * control is desired. For GPIO use, this should be set to + * \ref SYSTEM_PINMUX_GPIO. */ + uint8_t mux_position; + + /** Port buffer input/output direction. */ + enum system_pinmux_pin_dir direction; + + /** Logic level pull of the input buffer. */ + enum system_pinmux_pin_pull input_pull; + + /** Enable lowest possible powerstate on the pin + * + * \note All other configurations will be ignored, the pin will be disabled + */ + bool powersave; +}; + +/** \name Configuration and initialization + * @{ + */ + +/** + * \brief Initializes a Port pin configuration structure to defaults. + * + * Initializes a given Port pin configuration structure to a set of + * known default values. This function should be called on all new + * instances of these configuration structures before being modified by the + * user application. + * + * The default configuration is as follows: + * \li Non peripheral (i.e. GPIO) controlled + * \li Input mode with internal pull-up enabled + * + * \param[out] config Configuration structure to initialize to default values + */ +static inline void system_pinmux_get_config_defaults( + struct system_pinmux_config *const config) +{ + /* Sanity check arguments */ + Assert(config); + + /* Default configuration values */ + config->mux_position = SYSTEM_PINMUX_GPIO; + config->direction = SYSTEM_PINMUX_PIN_DIR_INPUT; + config->input_pull = SYSTEM_PINMUX_PIN_PULL_UP; + config->powersave = false; +} + +void system_pinmux_pin_set_config( + const uint8_t gpio_pin, + const struct system_pinmux_config *const config); + +void system_pinmux_group_set_config( + PortGroup *const port, + const uint32_t mask, + const struct system_pinmux_config *const config); + +/** @} */ + +/** \name Special mode configuration (physical group orientated) + * @{ + */ + +/** + * \brief Retrieves the PORT module group instance from a given GPIO pin number. + * + * Retrieves the PORT module group instance associated with a given logical + * GPIO pin number. + * + * \param[in] gpio_pin Index of the GPIO pin to convert. + * + * \return Base address of the associated PORT module. + */ +static inline PortGroup* system_pinmux_get_group_from_gpio_pin( + const uint8_t gpio_pin) +{ + uint8_t port_index = (gpio_pin / 128); + uint8_t group_index = (gpio_pin / 32); + + /* Array of available ports. */ + Port *const ports[PORT_INST_NUM] = PORT_INSTS; + + if (port_index < PORT_INST_NUM) { + return &(ports[port_index]->Group[group_index]); + } else { + Assert(false); + return NULL; + } +} + +void system_pinmux_group_set_input_sample_mode( + PortGroup *const port, + const uint32_t mask, + const enum system_pinmux_pin_sample mode); + +/** @} */ + +/** \name Special mode configuration (logical pin orientated) + * @{ + */ + +/** + * \brief Retrieves the currently selected MUX position of a logical pin. + * + * Retrieves the selected MUX peripheral on a given logical GPIO pin. + * + * \param[in] gpio_pin Index of the GPIO pin to configure. + * + * \return Currently selected peripheral index on the specified pin. + */ +static inline uint8_t system_pinmux_pin_get_mux_position( + const uint8_t gpio_pin) +{ + PortGroup *const port = system_pinmux_get_group_from_gpio_pin(gpio_pin); + uint32_t pin_index = (gpio_pin % 32); + + if (!(port->PINCFG[pin_index].reg & PORT_PINCFG_PMUXEN)) { + return SYSTEM_PINMUX_GPIO; + } + + uint32_t pmux_reg = port->PMUX[pin_index / 2].reg; + + if (pin_index & 1) { + return (pmux_reg & PORT_PMUX_PMUXO_Msk) >> PORT_PMUX_PMUXO_Pos; + } + else { + return (pmux_reg & PORT_PMUX_PMUXE_Msk) >> PORT_PMUX_PMUXE_Pos; + } +} + +/** + * \brief Configures the input sampling mode for a GPIO pin. + * + * Configures the input sampling mode for a GPIO input, to + * control when the physical I/O pin value is sampled and + * stored inside the microcontroller. + * + * \param[in] gpio_pin Index of the GPIO pin to configure. + * \param[in] mode New pin sampling mode to configure. + */ +static inline void system_pinmux_pin_set_input_sample_mode( + const uint8_t gpio_pin, + const enum system_pinmux_pin_sample mode) +{ + PortGroup* const port = system_pinmux_get_group_from_gpio_pin(gpio_pin); + uint32_t pin_index = (gpio_pin % 32); + + if (mode == SYSTEM_PINMUX_PIN_SAMPLE_ONDEMAND) { + port->CTRL.reg |= (1 << pin_index); + } else { + port->CTRL.reg &= ~(1 << pin_index); + } +} + +/** @} */ + +#ifdef __cplusplus +} +#endif + +/** @} */ + +/** + * \page asfdoc_sam0_system_pinmux_extra Extra Information for SYSTEM PINMUX Driver + * + * \section asfdoc_sam0_system_pinmux_extra_acronyms Acronyms + * The table below presents the acronyms used in this module: + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
AcronymDescription
GPIOGeneral Purpose Input/Output
MUXMultiplexer
+ * + * + * \section asfdoc_sam0_system_pinmux_extra_dependencies Dependencies + * This driver has the following dependencies: + * + * - None + * + * + * \section asfdoc_sam0_system_pinmux_extra_errata Errata + * There are no errata related to this driver. + * + * + * \section asfdoc_sam0_system_pinmux_extra_history Module History + * An overview of the module history is presented in the table below, with + * details on the enhancements and fixes made to the module since its first + * release. The current version of this corresponds to the newest version in + * the table. + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Changelog
Removed code of open drain, slew limit and drive strength + * features.
Fixed broken sampling mode function implementations, which wrote + * corrupt configuration values to the device registers.
Added missing NULL pointer asserts to the PORT driver functions.
Initial Release
+ */ + +/** + * \page asfdoc_sam0_system_pinmux_exqsg Examples for SYSTEM PINMUX Driver + * + * This is a list of the available Quick Start guides (QSGs) and example + * applications for \ref asfdoc_sam0_system_pinmux_group. QSGs are simple + * examples with step-by-step instructions to configure and use this driver in a + * selection of use cases. Note that QSGs can be compiled as a standalone + * application or be added to the user application. + * + * - \subpage asfdoc_sam0_system_pinmux_basic_use_case + * + * \page asfdoc_sam0_system_pinmux_document_revision_history Document Revision History + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Doc. Rev. + * Date + * Comments + *
F04/2014Add support for SAMD10/D11
E02/2014Add support for SAMR21
D01/2014Add support for SAMD21
C09/2013Fixed incorrect documentation for the device pin sampling mode.
B06/2013Corrected documentation typos.
A06/2013Initial release
+ */ + +#endif diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/pinmux/quick_start/qs_pinmux_basic.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/pinmux/quick_start/qs_pinmux_basic.h new file mode 100755 index 0000000..8dc9a66 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/pinmux/quick_start/qs_pinmux_basic.h @@ -0,0 +1,93 @@ +/** + * \file + * + * \brief SAM PINMUX Driver Quick Start + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +/** + * \page asfdoc_sam0_system_pinmux_basic_use_case Quick Start Guide for SYSTEM PINMUX - Basic + * + * In this use case, the PINMUX module is configured for: + * \li One pin in input mode, with pull-up enabled, connected to the GPIO + * module + * \li Sampling mode of the pin changed to sample on demand + * + * This use case sets up the PINMUX to configure a physical I/O pin set as + * an input with pull-up. and changes the sampling mode of the pin to reduce + * power by only sampling the physical pin state when the user application + * attempts to read it. + * + * \section asfdoc_sam0_system_pinmux_basic_use_case_setup Setup + * + * \subsection asfdoc_sam0_system_pinmux_basic_use_case_setup_prereq Prerequisites + * There are no special setup requirements for this use-case. + * + * \subsection asfdoc_sam0_system_pinmux_basic_use_case_setup_code Code + * Copy-paste the following setup code to your application: + * \snippet qs_pinmux_basic.c setup + * + * \subsection asfdoc_sam0_system_pinmux_basic_use_case_setup_flow Workflow + * -# Create a PINMUX module pin configuration struct, which can be filled out + * to adjust the configuration of a single port pin. + * \snippet qs_pinmux_basic.c pinmux_config + * -# Initialize the pin configuration struct with the module's default values. + * \snippet qs_pinmux_basic.c pinmux_config_defaults + * \note This should always be performed before using the configuration + * struct to ensure that all values are initialized to known default + * settings. + * + * -# Adjust the configuration struct to request an input pin with pullup + * connected to the GPIO peripheral. + * \snippet qs_pinmux_basic.c pinmux_update_config_values + * -# Configure GPIO10 with the initialized pin configuration struct, to enable + * the input sampler on the pin. + * \snippet qs_pinmux_basic.c pinmux_set_config + * + * \section asfdoc_sam0_system_pinmux_basic_use_case_use_main Use Case + * + * \subsection asfdoc_sam0_system_pinmux_basic_use_case_code Code + * Copy-paste the following code to your user application: + * \snippet qs_pinmux_basic.c main + * + * \subsection asfdoc_sam0_system_pinmux_basic_use_case_flow Workflow + + * -# Adjust the configuration of the pin to enable on-demand sampling mode. + * \snippet qs_pinmux_basic.c pinmux_change_input_sampling + */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/system.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/system.c new file mode 100755 index 0000000..b814b78 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/system.c @@ -0,0 +1,102 @@ +/** + * \file + * + * \brief SAM System related functionality + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include + +/** + * \internal + * Dummy initialization function, used as a weak alias target for the various + * init functions called by \ref system_init(). + */ +void _system_dummy_init(void); +void _system_dummy_init(void) +{ + return; +} + +#if !defined(__DOXYGEN__) +# if defined(__GNUC__) +void system_clock_init(void) WEAK __attribute__((alias("_system_dummy_init"))); +void system_board_init(void) WEAK __attribute__((alias("_system_dummy_init"))); +void _system_events_init(void) WEAK __attribute__((alias("_system_dummy_init"))); +void _system_extint_init(void) WEAK __attribute__((alias("_system_dummy_init"))); +# elif defined(__ICCARM__) +void system_clock_init(void); +void system_board_init(void); +void _system_events_init(void); +void _system_extint_init(void); +# pragma weak system_clock_init=_system_dummy_init +# pragma weak system_board_init=_system_dummy_init +# pragma weak _system_events_init=_system_dummy_init +# pragma weak _system_extint_init=_system_dummy_init +# endif +#endif + +/** + * \brief Initialize system + * + * This function will call the various initialization functions within the + * system namespace. If a given optional system module is not available, the + * associated call will effectively be a NOP (No Operation). + * + * Currently the following initialization functions are supported: + * - System clock initialization (via the SYSTEM CLOCK sub-module) + * - Board hardware initialization (via the Board module) + * - Event system driver initialization (via the EVSYS module) + * - External Interrupt driver initialization (via the EXTINT module) + */ +void system_init(void) +{ + /* Configure GCLK and clock sources according to conf_clocks.h */ + system_clock_init(); + + /* Initialize board hardware */ + system_board_init(); + + /* Initialize EVSYS hardware */ + _system_events_init(); + + /* Initialize External hardware */ + _system_extint_init(); +} + diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/system.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/system.h new file mode 100755 index 0000000..f07023a --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/system/system.h @@ -0,0 +1,577 @@ +/** + * \file + * + * \brief SAM System related functionality + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef SYSTEM_H_INCLUDED +#define SYSTEM_H_INCLUDED + +#include +#include +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \defgroup asfdoc_sam0_system_group SAM System Driver (SYSTEM) + * + * This driver for SAM devices provides an interface for the configuration + * and management of the device's system relation functionality, necessary for + * the basic device operation. This is not limited to a single peripheral, but + * extends across multiple hardware peripherals, + * + * The following peripherals are used by this module: + * - SYSCTRL (System Control) + * - PM (Power Manager) + * + * The following devices can use this module: + * - SAM D20/D21 + * - SAM R21 + * - SAM D10/D11 + * + * The outline of this documentation is as follows: + * - \ref asfdoc_sam0_system_prerequisites + * - \ref asfdoc_sam0_system_module_overview + * - \ref asfdoc_sam0_system_special_considerations + * - \ref asfdoc_sam0_system_extra_info + * - \ref asfdoc_sam0_system_examples + * - \ref asfdoc_sam0_system_api_overview + * + * + * \section asfdoc_sam0_system_prerequisites Prerequisites + * + * There are no prerequisites for this module. + * + * + * \section asfdoc_sam0_system_module_overview Module Overview + * + * The System driver provides a collection of interfaces between the user + * application logic, and the core device functionality (such as clocks, reset + * cause determination, etc.) that is required for all applications. It contains + * a number of sub-modules that control one specific aspect of the device: + * + * - System Core (this module) + * - \ref asfdoc_sam0_system_clock_group "System Clock Control" (sub-module) + * - \ref asfdoc_sam0_system_interrupt_group "System Interrupt Control" (sub-module) + * - \ref asfdoc_sam0_system_pinmux_group "System Pin Multiplexer Control" (sub-module) + * + * + * \subsection asfdoc_sam0_system_module_overview_vref Voltage References + * The various analog modules within the SAM devices (such as AC, ADC and + * DAC) require a voltage reference to be configured to act as a reference point + * for comparisons and conversions. + * + * The SAM devices contain multiple references, including an internal + * temperature sensor, and a fixed band-gap voltage source. When enabled, the + * associated voltage reference can be selected within the desired peripheral + * where applicable. + * + * \subsection asfdoc_sam0_system_module_overview_reset_cause System Reset Cause + * In some application there may be a need to execute a different program + * flow based on how the device was reset. For example, if the cause of reset + * was the Watchdog timer (WDT), this might indicate an error in the application + * and a form of error handling or error logging might be needed. + * + * For this reason, an API is provided to retrieve the cause of the last system + * reset, so that appropriate action can be taken. + * + * \subsection asfdoc_sam0_system_module_overview_sleep_mode Sleep Modes + * The SAM devices have several sleep modes, where the sleep mode controls + * which clock systems on the device will remain enabled or disabled when the + * device enters a low power sleep mode. + * \ref asfdoc_sam0_system_module_sleep_mode_table "The table below" lists the + * clock settings of the different sleep modes. + * + * \anchor asfdoc_sam0_system_module_sleep_mode_table + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
SAM Device Sleep Modes
Sleep modeCPU clockAHB clockAPB clocksClock sourcesSystem clock32KHzReg modeRAM mode
IDLE 0StopRunRunRunRunRunNormalNormal
IDLE 1StopStopRunRunRunRunNormalNormal
IDLE 2StopStopStopRunRunRunNormalNormal
STANDBYStopStopStopStopStopStopLow PowerSource/Drain biasing
+ * + * To enter device sleep, one of the available sleep modes must be set, and the + * function to enter sleep called. The device will automatically wake up in + * response to an interrupt being generated or other device event. + * + * Some peripheral clocks will remain enabled during sleep, depending on their + * configuration; if desired, modules can remain clocked during sleep to allow + * them to continue to operate while other parts of the system are powered down + * to save power. + * + * + * \section asfdoc_sam0_system_special_considerations Special Considerations + * + * Most of the functions in this driver have device specific restrictions and + * caveats; refer to your device datasheet. + * + * + * \section asfdoc_sam0_system_extra_info Extra Information + * + * For extra information see \ref asfdoc_sam0_system_extra. This includes: + * - \ref asfdoc_sam0_system_extra_acronyms + * - \ref asfdoc_sam0_system_extra_dependencies + * - \ref asfdoc_sam0_system_extra_errata + * - \ref asfdoc_sam0_system_extra_history + * + * + * \section asfdoc_sam0_system_examples Examples + * + * For SYSTEM module related examples, please refer to the sub-modules listed in + * the \ref asfdoc_sam0_system_module_overview "system module overview". + * + * + * \section asfdoc_sam0_system_api_overview API Overview + * @{ + */ + +/** + * \brief Voltage references within the device. + * + * List of available voltage references (VREF) that may be used within the + * device. + */ +enum system_voltage_reference { + /** Temperature sensor voltage reference. */ + SYSTEM_VOLTAGE_REFERENCE_TEMPSENSE, + /** Bandgap voltage reference. */ + SYSTEM_VOLTAGE_REFERENCE_BANDGAP, +}; + +/** + * \brief Device sleep modes. + * + * List of available sleep modes in the device. A table of clocks available in + * different sleep modes can be found in \ref asfdoc_sam0_system_module_overview_sleep_mode. + */ +enum system_sleepmode { + /** IDLE 0 sleep mode. */ + SYSTEM_SLEEPMODE_IDLE_0, + /** IDLE 1 sleep mode. */ + SYSTEM_SLEEPMODE_IDLE_1, + /** IDLE 2 sleep mode. */ + SYSTEM_SLEEPMODE_IDLE_2, + /** Standby sleep mode. */ + SYSTEM_SLEEPMODE_STANDBY, +}; + +/** + * \brief Reset causes of the system. + * + * List of possible reset causes of the system. + */ +enum system_reset_cause { + /** The system was last reset by a software reset. */ + SYSTEM_RESET_CAUSE_SOFTWARE = PM_RCAUSE_SYST, + /** The system was last reset by the watchdog timer. */ + SYSTEM_RESET_CAUSE_WDT = PM_RCAUSE_WDT, + /** The system was last reset because the external reset line was pulled low. */ + SYSTEM_RESET_CAUSE_EXTERNAL_RESET = PM_RCAUSE_EXT, + /** The system was last reset by the BOD33. */ + SYSTEM_RESET_CAUSE_BOD33 = PM_RCAUSE_BOD33, + /** The system was last reset by the BOD12. */ + SYSTEM_RESET_CAUSE_BOD12 = PM_RCAUSE_BOD12, + /** The system was last reset by the POR (Power on reset). */ + SYSTEM_RESET_CAUSE_POR = PM_RCAUSE_POR, +}; + +/** + * \name System identification + * @{ + */ + +/** + * \brief Retrieve the device identification signature + * + * Retrieves the signature of the current device. + * + * \return Device ID signature as a 32-bit integer. + */ +static inline uint32_t system_get_device_id(void) +{ + return DSU->DID.reg; +} + +/** + * @} + */ + + +/** + * \name Voltage references + * @{ + */ + +/** + * \brief Enable the selected voltage reference + * + * Enables the selected voltage reference source, making the voltage reference + * available on a pin as well as an input source to the analog peripherals. + * + * \param[in] vref Voltage reference to enable + */ +static inline void system_voltage_reference_enable( + const enum system_voltage_reference vref) +{ + switch (vref) { + case SYSTEM_VOLTAGE_REFERENCE_TEMPSENSE: + SYSCTRL->VREF.reg |= SYSCTRL_VREF_TSEN; + break; + + case SYSTEM_VOLTAGE_REFERENCE_BANDGAP: + SYSCTRL->VREF.reg |= SYSCTRL_VREF_BGOUTEN; + break; + + default: + Assert(false); + return; + } +} + +/** + * \brief Disable the selected voltage reference + * + * Disables the selected voltage reference source. + * + * \param[in] vref Voltage reference to disable + */ +static inline void system_voltage_reference_disable( + const enum system_voltage_reference vref) +{ + switch (vref) { + case SYSTEM_VOLTAGE_REFERENCE_TEMPSENSE: + SYSCTRL->VREF.reg &= ~SYSCTRL_VREF_TSEN; + break; + + case SYSTEM_VOLTAGE_REFERENCE_BANDGAP: + SYSCTRL->VREF.reg &= ~SYSCTRL_VREF_BGOUTEN; + break; + + default: + Assert(false); + return; + } +} + +/** + * @} + */ + + +/** + * \name Device sleep + * @{ + */ + +/** + * \brief Set the sleep mode of the device + * + * Sets the sleep mode of the device; the configured sleep mode will be entered + * upon the next call of the \ref system_sleep() function. + * + * For an overview of which systems are disabled in sleep for the different + * sleep modes, see \ref asfdoc_sam0_system_module_overview_sleep_mode. + * + * \param[in] sleep_mode Sleep mode to configure for the next sleep operation + * + * \retval STATUS_OK Operation completed successfully + * \retval STATUS_ERR_INVALID_ARG The requested sleep mode was invalid or not + * available + */ +static inline enum status_code system_set_sleepmode( + const enum system_sleepmode sleep_mode) +{ + switch (sleep_mode) { + case SYSTEM_SLEEPMODE_IDLE_0: + case SYSTEM_SLEEPMODE_IDLE_1: + case SYSTEM_SLEEPMODE_IDLE_2: + SCB->SCR &= ~SCB_SCR_SLEEPDEEP_Msk; + PM->SLEEP.reg = sleep_mode; + break; + + case SYSTEM_SLEEPMODE_STANDBY: + SCB->SCR |= SCB_SCR_SLEEPDEEP_Msk; + break; + + default: + return STATUS_ERR_INVALID_ARG; + } + + return STATUS_OK; +} + +/** + * \brief Put the system to sleep waiting for interrupt + * + * Executes a device DSB (Data Synchronization Barrier) instruction to ensure + * all ongoing memory accesses have completed, then a WFI (Wait For Interrupt) + * instruction to place the device into the sleep mode specified by + * \ref system_set_sleepmode until woken by an interrupt. + */ +static inline void system_sleep(void) +{ + __DSB(); + __WFI(); +} + +/** + * @} + */ + +/** + * \name Reset control + * @{ + */ + +/** + * \brief Check if bugger is present + * + * Check if debugger is connected to the onboard debug system (DAP) + * + * \return A bool identifying if a debugger is present + * + * \retval true Debugger is connected to the system + * \retval false Debugger is not connected to the system + * + */ +static inline bool system_is_debugger_present(void) +{ + return DSU->STATUSB.reg & DSU_STATUSB_DBGPRES; +} + +/** + * \brief Reset the MCU + * + * Resets the MCU and all associated peripherals and registers, except RTC, all 32kHz sources, + * WDT (if ALWAYSON is set) and GCLK (if WRTLOCK is set). + * + */ +static inline void system_reset(void) +{ + NVIC_SystemReset(); +} + +/** + * \brief Return the reset cause + * + * Retrieves the cause of the last system reset. + * + * \return An enum value indicating the cause of the last system reset. + */ +static inline enum system_reset_cause system_get_reset_cause(void) +{ + return (enum system_reset_cause)PM->RCAUSE.reg; +} + +/** + * @} + */ + + +/** + * \name System initialization + * @{ + */ + +void system_init(void); + +/** + * @} + */ + + +/** + * @} + */ + +/** + * \page asfdoc_sam0_system_extra Extra Information for SYSTEM Driver + * + * \section asfdoc_sam0_system_extra_acronyms Acronyms + * Below is a table listing the acronyms used in this module, along with their + * intended meanings. + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
AcronymDefinition
PMPower Manager
SYSCTRLSystem control interface
+ * + * + * \section asfdoc_sam0_system_extra_dependencies Dependencies + * This driver has the following dependencies: + * + * - None + * + * + * \section asfdoc_sam0_system_extra_errata Errata + * There are no errata related to this driver. + * + * + * \section asfdoc_sam0_system_extra_history Module History + * An overview of the module history is presented in the table below, with + * details on the enhancements and fixes made to the module since its first + * release. The current version of this corresponds to the newest version in + * the table. + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Changelog
Added support for SAMD21
Added new \c system_reset() to reset the complete MCU with some exceptions
Added new \c system_get_device_id() function to retrieved the device + * ID.
Initial Release
+ * + * \page asfdoc_sam0_system_document_revision_history Document Revision History + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Doc. Rev. + * Date + * Comments + *
E04/2014Added support for SAMD10/D11.
D02/2014Added support for SAMR21.
C01/2014Added support for SAMD21.
B06/2013Corrected documentation typos.
A06/2013Initial release
+ */ + +#ifdef __cplusplus +} +#endif + +#endif /* SYSTEM_H_INCLUDED */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/usb/stack_interface/usb_device_udd.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/usb/stack_interface/usb_device_udd.c new file mode 100755 index 0000000..d114700 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/usb/stack_interface/usb_device_udd.c @@ -0,0 +1,1242 @@ +/** + * \file + * + * \brief USB Device wrapper layer for compliance with common driver UDD + * + * Copyright (C) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include +#include + +// Get USB device configuration +#include "conf_usb.h" +#include "udd.h" +#include "usb.h" +#include "usb_dual.h" +#include "sleepmgr.h" + +/** + * \ingroup usb_device_group + * \defgroup usb_device_udd_group USB Device Driver Implement (UDD) + * USB low-level driver for USB device mode + * @{ + */ +// Check USB device configuration +#ifdef USB_DEVICE_HS_SUPPORT +# error The High speed mode is not supported on this part, please remove USB_DEVICE_HS_SUPPORT in conf_usb.h +#endif + +#if !(SAMD21) && !(SAMR21) && !(SAMD11) +# error The current USB Device Driver supports only SAMD21/R21/D11 +#endif + +#ifndef UDC_REMOTEWAKEUP_LPM_ENABLE +#define UDC_REMOTEWAKEUP_LPM_ENABLE() +#endif +#ifndef UDC_REMOTEWAKEUP_LPM_DISABLE +#define UDC_REMOTEWAKEUP_LPM_DISABLE() +#endif +#ifndef UDC_SUSPEND_LPM_EVENT +#define UDC_SUSPEND_LPM_EVENT() +#endif + +/* for debug text */ +#ifdef USB_DEBUG +# define dbg_print printf +#else +# define dbg_print(...) +#endif + +/** Maximum size of a transfer in multi-packet mode */ +#define UDD_ENDPOINT_MAX_TRANS ((8*1024)-1) + +/** USB software device instance structure */ +struct usb_module usb_device; + +/** + * \name Clock management + * + * @{ + */ +#ifndef UDD_CLOCK_GEN +# define UDD_CLOCK_GEN GCLK_GENERATOR_0 +#endif +#ifndef UDD_CLOCK_SOURCE +# define UDD_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_DFLL +#endif +static inline void udd_wait_clock_ready(void) +{ + + if (UDD_CLOCK_SOURCE == SYSTEM_CLOCK_SOURCE_DPLL) { +#define DPLL_READY_FLAG (SYSCTRL_DPLLSTATUS_ENABLE | \ + SYSCTRL_DPLLSTATUS_CLKRDY | SYSCTRL_DPLLSTATUS_LOCK) + + while((SYSCTRL->DPLLSTATUS.reg & DPLL_READY_FLAG) != DPLL_READY_FLAG); + } + + if (UDD_CLOCK_SOURCE == SYSTEM_CLOCK_SOURCE_DFLL) { +#define DFLL_READY_FLAG (SYSCTRL_PCLKSR_DFLLRDY | \ + SYSCTRL_PCLKSR_DFLLLCKF | SYSCTRL_PCLKSR_DFLLLCKC) + + /* In USB recovery mode the status is not checked */ + if (!(SYSCTRL->DFLLCTRL.reg & SYSCTRL_DFLLCTRL_USBCRM)) { + while((SYSCTRL->PCLKSR.reg & DFLL_READY_FLAG) != DFLL_READY_FLAG); + } else { + while((SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_DFLLRDY) != SYSCTRL_PCLKSR_DFLLRDY); + } + } + +} +/** @} */ + +/** + * \name Power management + * + * @{ + */ +#ifndef UDD_NO_SLEEP_MGR + +#include "sleepmgr.h" +/** States of USB interface */ +enum udd_usb_state_enum { + UDD_STATE_OFF, + UDD_STATE_SUSPEND, + UDD_STATE_SUSPEND_LPM, + UDD_STATE_IDLE, +}; + +/** \brief Manages the sleep mode following the USB state + * + * \param new_state New USB state + */ +static void udd_sleep_mode(enum udd_usb_state_enum new_state) +{ + enum sleepmgr_mode sleep_mode[] = { + SLEEPMGR_ACTIVE, /* UDD_STATE_OFF (not used) */ + SLEEPMGR_IDLE_2, /* UDD_STATE_SUSPEND */ + SLEEPMGR_IDLE_1, /* UDD_STATE_SUSPEND_LPM */ + SLEEPMGR_IDLE_0, /* UDD_STATE_IDLE */ + }; + + static enum udd_usb_state_enum udd_state = UDD_STATE_OFF; + + if (udd_state == new_state) { + return; // No change + } + if (new_state != UDD_STATE_OFF) { + /* Lock new limit */ + sleepmgr_lock_mode(sleep_mode[new_state]); + } + if (udd_state != UDD_STATE_OFF) { + /* Unlock old limit */ + sleepmgr_unlock_mode(sleep_mode[udd_state]); + } + udd_state = new_state; +} + +#else +# define udd_sleep_mode(arg) +#endif +/** @} */ + +/** + * \name Control endpoint low level management routine. + * + * This function performs control endpoint management. + * It handles the SETUP/DATA/HANDSHAKE phases of a control transaction. + * + * @{ + */ + +/** + * \brief Buffer to store the data received on control endpoint (SETUP/OUT endpoint 0) + * + * Used to avoid a RAM buffer overflow in case of the payload buffer + * is smaller than control endpoint size + */ +UDC_BSS(4) +uint8_t udd_ctrl_buffer[USB_DEVICE_EP_CTRL_SIZE]; + +/** Bit definitions about endpoint control state machine for udd_ep_control_state */ +typedef enum { + UDD_EPCTRL_SETUP = 0, //!< Wait a SETUP packet + UDD_EPCTRL_DATA_OUT = 1, //!< Wait a OUT data packet + UDD_EPCTRL_DATA_IN = 2, //!< Wait a IN data packet + UDD_EPCTRL_HANDSHAKE_WAIT_IN_ZLP = 3, //!< Wait a IN ZLP packet + UDD_EPCTRL_HANDSHAKE_WAIT_OUT_ZLP = 4, //!< Wait a OUT ZLP packet + UDD_EPCTRL_STALL_REQ = 5, //!< STALL enabled on IN & OUT packet +} udd_ctrl_ep_state_t; + +/** Global variable to give and record information of the set up request management */ +udd_ctrl_request_t udd_g_ctrlreq; + +/** State of the endpoint control management */ +static udd_ctrl_ep_state_t udd_ep_control_state; + +/** Total number of data received/sent during data packet phase with previous payload buffers */ +static uint16_t udd_ctrl_prev_payload_nb_trans; + +/** Number of data received/sent to/from udd_g_ctrlreq.payload buffer */ +static uint16_t udd_ctrl_payload_nb_trans; + +/** @} */ + +/** + * \name Management of bulk/interrupt/isochronous endpoints + * + * The UDD manages the data transfer on endpoints: + * - Start data transfer on endpoint with USB Device DMA + * - Send a ZLP packet if requested + * - Call callback registered to signal end of transfer + * The transfer abort and stall feature are supported. + * + * @{ + */ + +/** + * \brief Buffer to store the data received on bulk/interrupt endpoints + * + * Used to avoid a RAM buffer overflow in case of the user buffer + * is smaller than endpoint size + * + * \warning The protected interrupt endpoint size is 512 bytes maximum. + * \warning The isochronous and endpoint is not protected by this system and + * the user must always use a buffer corresponding at endpoint size. + */ +#if (defined USB_DEVICE_LOW_SPEED) +UDC_BSS(4) uint8_t udd_ep_out_cache_buffer[USB_DEVICE_MAX_EP][8]; +#elif (defined USB_DEVICE_HS_SUPPORT) +UDC_BSS(4) uint8_t udd_ep_out_cache_buffer[USB_DEVICE_MAX_EP][512]; +#else +UDC_BSS(4) uint8_t udd_ep_out_cache_buffer[USB_DEVICE_MAX_EP][64]; +#endif + +/** Structure definition about job registered on an endpoint */ +typedef struct { + union { + //! Callback to call at the end of transfer + udd_callback_trans_t call_trans; + //! Callback to call when the endpoint halt is cleared + udd_callback_halt_cleared_t call_nohalt; + }; + //! Buffer located in internal RAM to send or fill during job + uint8_t *buf; + //! Size of buffer to send or fill + iram_size_t buf_size; + //! Total number of data transferred on endpoint + iram_size_t nb_trans; + //! Endpoint size + uint16_t ep_size; + //! A job is registered on this endpoint + uint8_t busy:1; + //! A short packet is requested for this job on endpoint IN + uint8_t b_shortpacket:1; + //! The cache buffer is currently used on endpoint OUT + uint8_t b_use_out_cache_buffer:1; +} udd_ep_job_t; + +/** Array to register a job on bulk/interrupt/isochronous endpoint */ +static udd_ep_job_t udd_ep_job[2 * USB_DEVICE_MAX_EP]; + +/** @} */ + +/** + * \brief Get the detailed job by endpoint number + * \param[in] ep Endpoint Address + * \retval pointer to an udd_ep_job_t structure instance + */ +static udd_ep_job_t* udd_ep_get_job(udd_ep_id_t ep) +{ + return &udd_ep_job[(2 * (ep & USB_EP_ADDR_MASK) + ((ep & USB_EP_DIR_IN) ? 1 : 0)) - 2]; +} + +/** + * \brief Endpoint IN process, continue to send packets or zero length packet + * \param[in] pointer Pointer to the endpoint transfer status parameter struct from driver layer. + */ +static void udd_ep_trans_in_next(void* pointer) +{ + struct usb_endpoint_callback_parameter *ep_callback_para = (struct usb_endpoint_callback_parameter*)pointer; + udd_ep_id_t ep = ep_callback_para->endpoint_address; + uint16_t ep_size, nb_trans; + uint16_t next_trans; + udd_ep_id_t ep_num; + udd_ep_job_t *ptr_job; + + ptr_job = udd_ep_get_job(ep); + ep_num = ep & USB_EP_ADDR_MASK; + + ep_size = ptr_job->ep_size; + /* Update number of data transferred */ + nb_trans = ep_callback_para->sent_bytes; + ptr_job->nb_trans += nb_trans; + + /* Need to send other data */ + if (ptr_job->nb_trans != ptr_job->buf_size) { + next_trans = ptr_job->buf_size - ptr_job->nb_trans; + if (UDD_ENDPOINT_MAX_TRANS < next_trans) { + /* The USB hardware support a maximum + * transfer size of UDD_ENDPOINT_MAX_TRANS Bytes */ + next_trans = UDD_ENDPOINT_MAX_TRANS -(UDD_ENDPOINT_MAX_TRANS % ep_size); + } + /* Need ZLP, if requested and last packet is not a short packet */ + ptr_job->b_shortpacket = ptr_job->b_shortpacket && (0 == (next_trans % ep_size)); + usb_device_endpoint_write_buffer_job(&usb_device,ep_num,&ptr_job->buf[ptr_job->nb_trans],next_trans); + return; + } + + /* Need to send a ZLP after all data transfer */ + if (ptr_job->b_shortpacket) { + ptr_job->b_shortpacket = false; + /* Start new transfer */ + usb_device_endpoint_write_buffer_job(&usb_device,ep_num,&ptr_job->buf[ptr_job->nb_trans],0); + return; + } + + /* Job complete then call callback */ + ptr_job->busy = false; + if (NULL != ptr_job->call_trans) { + ptr_job->call_trans(UDD_EP_TRANSFER_OK, ptr_job->nb_trans, ep); + } +} + +/** + * \brief Endpoint OUT process, continue to receive packets or zero length packet + * \param[in] pointer Pointer to the endpoint transfer status parameter struct from driver layer. + */ +static void udd_ep_trans_out_next(void* pointer) +{ + struct usb_endpoint_callback_parameter *ep_callback_para = (struct usb_endpoint_callback_parameter*)pointer; + udd_ep_id_t ep = ep_callback_para->endpoint_address; + uint16_t ep_size, nb_trans; + uint16_t next_trans; + udd_ep_id_t ep_num; + udd_ep_job_t *ptr_job; + + ptr_job = udd_ep_get_job(ep); + ep_num = ep & USB_EP_ADDR_MASK; + + ep_size = ptr_job->ep_size; + /* Update number of data transferred */ + nb_trans = ep_callback_para->received_bytes; + + /* Can be necessary to copy data receive from cache buffer to user buffer */ + if (ptr_job->b_use_out_cache_buffer) { + memcpy(&ptr_job->buf[ptr_job->nb_trans], udd_ep_out_cache_buffer[ep_num - 1], ptr_job->buf_size % ep_size); + } + + /* Update number of data transferred */ + ptr_job->nb_trans += nb_trans; + if (ptr_job->nb_trans > ptr_job->buf_size) { + ptr_job->nb_trans = ptr_job->buf_size; + } + + /* If all previous data requested are received and user buffer not full + * then need to receive other data */ + if ((nb_trans == ep_callback_para->out_buffer_size) && (ptr_job->nb_trans != ptr_job->buf_size)) { + next_trans = ptr_job->buf_size - ptr_job->nb_trans; + if (UDD_ENDPOINT_MAX_TRANS < next_trans) { + /* The USB hardware support a maximum transfer size + * of UDD_ENDPOINT_MAX_TRANS Bytes */ + next_trans = UDD_ENDPOINT_MAX_TRANS - (UDD_ENDPOINT_MAX_TRANS % ep_size); + } else { + next_trans -= next_trans % ep_size; + } + + if (next_trans < ep_size) { + /* Use the cache buffer for Bulk or Interrupt size endpoint */ + ptr_job->b_use_out_cache_buffer = true; + usb_device_endpoint_read_buffer_job(&usb_device,ep_num,udd_ep_out_cache_buffer[ep_num - 1],ep_size); + } else { + usb_device_endpoint_read_buffer_job(&usb_device,ep_num,&ptr_job->buf[ptr_job->nb_trans],next_trans); + } + return; + } + + /* Job complete then call callback */ + ptr_job->busy = false; + if (NULL != ptr_job->call_trans) { + ptr_job->call_trans(UDD_EP_TRANSFER_OK, ptr_job->nb_trans, ep); + } +} + +/** + * \brief Endpoint Transfer Complete callback function, to do the next transfer depends on the direction(IN or OUT) + * \param[in] module_inst Pointer to USB module instance + * \param[in] pointer Pointer to the endpoint transfer status parameter struct from driver layer. + */ +static void udd_ep_transfer_process(struct usb_module *module_inst, void* pointer) +{ + struct usb_endpoint_callback_parameter *ep_callback_para = (struct usb_endpoint_callback_parameter*)pointer; + udd_ep_id_t ep = ep_callback_para->endpoint_address; + + if (ep & USB_EP_DIR_IN) { + udd_ep_trans_in_next(pointer); + } else { + udd_ep_trans_out_next(pointer); + } +} + +void udd_ep_abort(udd_ep_id_t ep) +{ + udd_ep_job_t *ptr_job; + + usb_device_endpoint_abort_job(&usb_device, ep); + + /* Job complete then call callback */ + ptr_job = udd_ep_get_job(ep); + if (!ptr_job->busy) { + return; + } + ptr_job->busy = false; + if (NULL != ptr_job->call_trans) { + /* It can be a Transfer or stall callback */ + ptr_job->call_trans(UDD_EP_TRANSFER_ABORT, ptr_job->nb_trans, ep); + } +} + +bool udd_is_high_speed(void) +{ +#if SAMD21 || SAMR21 || SAMD11 + return false; +#endif +} + +uint16_t udd_get_frame_number(void) +{ + return usb_device_get_frame_number(&usb_device); +} + +uint16_t udd_get_micro_frame_number(void) +{ + return usb_device_get_micro_frame_number(&usb_device); +} + +void udd_ep_free(udd_ep_id_t ep) +{ + struct usb_device_endpoint_config config_ep; + usb_device_endpoint_get_config_defaults(&config_ep); + + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + udd_ep_abort(ep); + + config_ep.ep_address = ep; + config_ep.ep_type = USB_DEVICE_ENDPOINT_TYPE_DISABLE; + usb_device_endpoint_set_config(&usb_device, &config_ep); + usb_device_endpoint_unregister_callback(&usb_device,ep_num,USB_DEVICE_ENDPOINT_CALLBACK_TRCPT); + usb_device_endpoint_disable_callback(&usb_device,ep,USB_DEVICE_ENDPOINT_CALLBACK_TRCPT); +} + +bool udd_ep_alloc(udd_ep_id_t ep, uint8_t bmAttributes, uint16_t MaxEndpointSize) +{ + struct usb_device_endpoint_config config_ep; + usb_device_endpoint_get_config_defaults(&config_ep); + + config_ep.ep_address = ep; + + if(MaxEndpointSize <= 8) { + config_ep.ep_size = USB_ENDPOINT_8_BYTE; + } else if(MaxEndpointSize <= 16) { + config_ep.ep_size = USB_ENDPOINT_16_BYTE; + } else if(MaxEndpointSize <= 32) { + config_ep.ep_size = USB_ENDPOINT_32_BYTE; + } else if(MaxEndpointSize <= 64) { + config_ep.ep_size = USB_ENDPOINT_64_BYTE; + } else if(MaxEndpointSize <= 128) { + config_ep.ep_size = USB_ENDPOINT_128_BYTE; + } else if(MaxEndpointSize <= 256) { + config_ep.ep_size = USB_ENDPOINT_256_BYTE; + } else if(MaxEndpointSize <= 512) { + config_ep.ep_size = USB_ENDPOINT_512_BYTE; + } else if(MaxEndpointSize <= 1023) { + config_ep.ep_size = USB_ENDPOINT_1023_BYTE; + } else { + return false; + } + udd_ep_job_t *ptr_job = udd_ep_get_job(ep); + ptr_job->ep_size = MaxEndpointSize; + + bmAttributes = bmAttributes & USB_EP_TYPE_MASK; + + /* Check endpoint type */ + if(USB_EP_TYPE_ISOCHRONOUS == bmAttributes) { + config_ep.ep_type = USB_DEVICE_ENDPOINT_TYPE_ISOCHRONOUS; + } else if (USB_EP_TYPE_BULK == bmAttributes) { + config_ep.ep_type = USB_DEVICE_ENDPOINT_TYPE_BULK; + } else if (USB_EP_TYPE_INTERRUPT == bmAttributes) { + config_ep.ep_type = USB_DEVICE_ENDPOINT_TYPE_INTERRUPT; + } else { + return false; + } + + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + + if (STATUS_OK != usb_device_endpoint_set_config(&usb_device, &config_ep)) { + return false; + } + usb_device_endpoint_register_callback(&usb_device,ep_num,USB_DEVICE_ENDPOINT_CALLBACK_TRCPT,udd_ep_transfer_process); + usb_device_endpoint_enable_callback(&usb_device,ep,USB_DEVICE_ENDPOINT_CALLBACK_TRCPT); + usb_device_endpoint_enable_callback(&usb_device,ep,USB_DEVICE_ENDPOINT_CALLBACK_TRFAIL); + + return true; +} + +bool udd_ep_is_halted(udd_ep_id_t ep) +{ + return usb_device_endpoint_is_halted(&usb_device, ep); +} + +bool udd_ep_set_halt(udd_ep_id_t ep) +{ + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + + if (USB_DEVICE_MAX_EP < ep_num) { + return false; + } + + usb_device_endpoint_set_halt(&usb_device, ep); + + udd_ep_abort(ep); + return true; +} + +bool udd_ep_clear_halt(udd_ep_id_t ep) +{ + udd_ep_job_t *ptr_job; + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + + if (USB_DEVICE_MAX_EP < ep_num) { + return false; + } + ptr_job = udd_ep_get_job(ep); + + usb_device_endpoint_clear_halt(&usb_device, ep); + + /* If a job is register on clear halt action then execute callback */ + if (ptr_job->busy == true) { + ptr_job->busy = false; + ptr_job->call_nohalt(); + } + + return true; +} + +bool udd_ep_wait_stall_clear(udd_ep_id_t ep, udd_callback_halt_cleared_t callback) +{ + udd_ep_id_t ep_num; + udd_ep_job_t *ptr_job; + + ep_num = ep & USB_EP_ADDR_MASK; + if (USB_DEVICE_MAX_EP < ep_num) { + return false; + } + + ptr_job = udd_ep_get_job(ep); + if (ptr_job->busy == true) { + return false; /* Job already on going */ + } + + /* Wait clear halt endpoint */ + if (usb_device_endpoint_is_halted(&usb_device, ep)) { + /* Endpoint halted then registers the callback */ + ptr_job->busy = true; + ptr_job->call_nohalt = callback; + return true; + } else if (usb_device_endpoint_is_configured(&usb_device, ep)) { + callback(); /* Endpoint not halted then call directly callback */ + return true; + } else { + return false; + } +} + +/** + * \brief Control Endpoint stall sending data + */ +static void udd_ctrl_stall_data(void) +{ + udd_ep_control_state = UDD_EPCTRL_STALL_REQ; + + usb_device_endpoint_set_halt(&usb_device, USB_EP_DIR_IN); + usb_device_endpoint_clear_halt(&usb_device, USB_EP_DIR_OUT); +} + +bool udd_ep_run(udd_ep_id_t ep, bool b_shortpacket, uint8_t * buf, iram_size_t buf_size, udd_callback_trans_t callback) +{ + udd_ep_id_t ep_num; + udd_ep_job_t *ptr_job; + irqflags_t flags; + + ep_num = ep & USB_EP_ADDR_MASK; + + if ((USB_DEVICE_MAX_EP < ep_num) || (udd_ep_is_halted(ep))) { + return false; + } + + ptr_job = udd_ep_get_job(ep); + + flags = cpu_irq_save(); + if (ptr_job->busy == true) { + cpu_irq_restore(flags); + return false; /* Job already on going */ + } + ptr_job->busy = true; + cpu_irq_restore(flags); + + /* No job running, set up a new one */ + ptr_job->buf = buf; + ptr_job->buf_size = buf_size; + ptr_job->nb_trans = 0; + ptr_job->call_trans = callback; + ptr_job->b_shortpacket = b_shortpacket; + ptr_job->b_use_out_cache_buffer = false; + + /* Initialize value to simulate a empty transfer */ + uint16_t next_trans; + + if (ep & USB_EP_DIR_IN) { + if (0 != ptr_job->buf_size) { + next_trans = ptr_job->buf_size; + if (UDD_ENDPOINT_MAX_TRANS < next_trans) { + next_trans = UDD_ENDPOINT_MAX_TRANS - + (UDD_ENDPOINT_MAX_TRANS % ptr_job->ep_size); + } + ptr_job->b_shortpacket = ptr_job->b_shortpacket && + (0 == (next_trans % ptr_job->ep_size)); + } else if (true == ptr_job->b_shortpacket) { + ptr_job->b_shortpacket = false; /* avoid to send zero length packet again */ + next_trans = 0; + } else { + ptr_job->busy = false; + if (NULL != ptr_job->call_trans) { + ptr_job->call_trans(UDD_EP_TRANSFER_OK, 0, ep); + } + return true; + } + return (STATUS_OK == + usb_device_endpoint_write_buffer_job(&usb_device, + ep_num,&ptr_job->buf[0],next_trans)); + } else { + if (0 != ptr_job->buf_size) { + next_trans = ptr_job->buf_size; + if (UDD_ENDPOINT_MAX_TRANS < next_trans) { + /* The USB hardware support a maximum transfer size + * of UDD_ENDPOINT_MAX_TRANS Bytes */ + next_trans = UDD_ENDPOINT_MAX_TRANS - + (UDD_ENDPOINT_MAX_TRANS % ptr_job->ep_size); + } else { + next_trans -= next_trans % ptr_job->ep_size; + } + if (next_trans < ptr_job->ep_size) { + ptr_job->b_use_out_cache_buffer = true; + return (STATUS_OK == + usb_device_endpoint_read_buffer_job(&usb_device, ep_num, + udd_ep_out_cache_buffer[ep_num - 1], + ptr_job->ep_size)); + } else { + return (STATUS_OK == + usb_device_endpoint_read_buffer_job(&usb_device, ep_num, + &ptr_job->buf[0],next_trans)); + } + } else { + ptr_job->busy = false; + if (NULL != ptr_job->call_trans) { + ptr_job->call_trans(UDD_EP_TRANSFER_OK, 0, ep); + } + return true; + } + } +} + +void udd_set_address(uint8_t address) +{ + usb_device_set_address(&usb_device,address); +} + +uint8_t udd_getaddress(void) +{ + return usb_device_get_address(&usb_device); +} + +void udd_send_remotewakeup(void) +{ + uint32_t try = 5; + udd_wait_clock_ready(); + udd_sleep_mode(UDD_STATE_IDLE); + while(2 != usb_get_state_machine_status(&usb_device) && try --) { + usb_device_send_remote_wake_up(&usb_device); + } +} + +void udd_set_setup_payload( uint8_t *payload, uint16_t payload_size ) +{ + udd_g_ctrlreq.payload = payload; + udd_g_ctrlreq.payload_size = payload_size; +} + +/** + * \brief Control Endpoint translate the data in buffer into Device Request Struct + */ +static void udd_ctrl_fetch_ram(void) +{ + udd_g_ctrlreq.req.bmRequestType = udd_ctrl_buffer[0]; + udd_g_ctrlreq.req.bRequest = udd_ctrl_buffer[1]; + udd_g_ctrlreq.req.wValue = ((uint16_t)(udd_ctrl_buffer[3]) << 8) + udd_ctrl_buffer[2]; + udd_g_ctrlreq.req.wIndex = ((uint16_t)(udd_ctrl_buffer[5]) << 8) + udd_ctrl_buffer[4]; + udd_g_ctrlreq.req.wLength = ((uint16_t)(udd_ctrl_buffer[7]) << 8) + udd_ctrl_buffer[6]; +} + +/** + * \brief Control Endpoint send out zero length packet + */ +static void udd_ctrl_send_zlp_in(void) +{ + udd_ep_control_state = UDD_EPCTRL_HANDSHAKE_WAIT_IN_ZLP; + usb_device_endpoint_setup_buffer_job(&usb_device,udd_ctrl_buffer); + usb_device_endpoint_write_buffer_job(&usb_device,0,udd_g_ctrlreq.payload,0); +} + +/** + * \brief Process control endpoint IN transaction + */ +static void udd_ctrl_in_sent(void) +{ + static bool b_shortpacket = false; + uint16_t nb_remain; + + nb_remain = udd_g_ctrlreq.payload_size - udd_ctrl_payload_nb_trans; + + if (0 == nb_remain) { + /* All content of current buffer payload are sent Update number of total data sending by previous payload buffer */ + udd_ctrl_prev_payload_nb_trans += udd_ctrl_payload_nb_trans; + if ((udd_g_ctrlreq.req.wLength == udd_ctrl_prev_payload_nb_trans) || b_shortpacket) { + /* All data requested are transferred or a short packet has been sent, then it is the end of data phase. + * Generate an OUT ZLP for handshake phase */ + udd_ep_control_state = UDD_EPCTRL_HANDSHAKE_WAIT_OUT_ZLP; + usb_device_endpoint_setup_buffer_job(&usb_device,udd_ctrl_buffer); + return; + } + /* Need of new buffer because the data phase is not complete */ + if ((!udd_g_ctrlreq.over_under_run) || (!udd_g_ctrlreq.over_under_run())) { + /* Under run then send zlp on IN + * Here nb_remain=0, this allows to send a IN ZLP */ + } else { + /* A new payload buffer is given */ + udd_ctrl_payload_nb_trans = 0; + nb_remain = udd_g_ctrlreq.payload_size; + } + } + + /* Continue transfer and send next data */ + if (nb_remain >= USB_DEVICE_EP_CTRL_SIZE) { + nb_remain = USB_DEVICE_EP_CTRL_SIZE; + b_shortpacket = false; + } else { + b_shortpacket = true; + } + + /* Link payload buffer directly on USB hardware */ + usb_device_endpoint_write_buffer_job(&usb_device,0,udd_g_ctrlreq.payload + udd_ctrl_payload_nb_trans,nb_remain); + + udd_ctrl_payload_nb_trans += nb_remain; +} + +/** + * \brief Process control endpoint OUT transaction + * \param[in] pointer Pointer to the endpoint transfer status parameter struct from driver layer. + */ +static void udd_ctrl_out_received(void* pointer) +{ + struct usb_endpoint_callback_parameter *ep_callback_para = (struct usb_endpoint_callback_parameter*)pointer; + + uint16_t nb_data; + nb_data = ep_callback_para->received_bytes; /* Read data received during OUT phase */ + + if (udd_g_ctrlreq.payload_size < (udd_ctrl_payload_nb_trans + nb_data)) { + /* Payload buffer too small */ + nb_data = udd_g_ctrlreq.payload_size - udd_ctrl_payload_nb_trans; + } + + memcpy((uint8_t *) (udd_g_ctrlreq.payload + udd_ctrl_payload_nb_trans), udd_ctrl_buffer, nb_data); + udd_ctrl_payload_nb_trans += nb_data; + + if ((USB_DEVICE_EP_CTRL_SIZE != nb_data) || \ + (udd_g_ctrlreq.req.wLength <= (udd_ctrl_prev_payload_nb_trans + udd_ctrl_payload_nb_trans))) { + /* End of reception because it is a short packet + * or all data are transferred */ + + /* Before send ZLP, call intermediate callback + * in case of data receive generate a stall */ + udd_g_ctrlreq.payload_size = udd_ctrl_payload_nb_trans; + if (NULL != udd_g_ctrlreq.over_under_run) { + if (!udd_g_ctrlreq.over_under_run()) { + /* Stall ZLP */ + udd_ep_control_state = UDD_EPCTRL_STALL_REQ; + /* Stall all packets on IN & OUT control endpoint */ + udd_ep_set_halt(0); + /* Ack reception of OUT to replace NAK by a STALL */ + return; + } + } + /* Send IN ZLP to ACK setup request */ + udd_ctrl_send_zlp_in(); + return; + } + + if (udd_g_ctrlreq.payload_size == udd_ctrl_payload_nb_trans) { + /* Overrun then request a new payload buffer */ + if (!udd_g_ctrlreq.over_under_run) { + /* No callback available to request a new payload buffer + * Stall ZLP */ + udd_ep_control_state = UDD_EPCTRL_STALL_REQ; + /* Stall all packets on IN & OUT control endpoint */ + udd_ep_set_halt(0); + return; + } + if (!udd_g_ctrlreq.over_under_run()) { + /* No new payload buffer delivered + * Stall ZLP */ + udd_ep_control_state = UDD_EPCTRL_STALL_REQ; + /* Stall all packets on IN & OUT control endpoint */ + udd_ep_set_halt(0); + return; + } + /* New payload buffer available + * Update number of total data received */ + udd_ctrl_prev_payload_nb_trans += udd_ctrl_payload_nb_trans; + + /* Reinitialize reception on payload buffer */ + udd_ctrl_payload_nb_trans = 0; + } + usb_device_endpoint_read_buffer_job(&usb_device,0,udd_ctrl_buffer,USB_DEVICE_EP_CTRL_SIZE); +} + +/** + * \internal + * \brief Endpoint 0 (control) SETUP received callback + * \param[in] module_inst pointer to USB module instance + * \param[in] pointer Pointer to the endpoint transfer status parameter struct from driver layer. + */ +static void _usb_ep0_on_setup(struct usb_module *module_inst, void* pointer) +{ + struct usb_endpoint_callback_parameter *ep_callback_para = (struct usb_endpoint_callback_parameter*)pointer; + + if (UDD_EPCTRL_SETUP != udd_ep_control_state) { + if (NULL != udd_g_ctrlreq.callback) { + udd_g_ctrlreq.callback(); + } + udd_ep_control_state = UDD_EPCTRL_SETUP; + } + if ( 8 != ep_callback_para->received_bytes) { + udd_ctrl_stall_data(); + return; + } else { + udd_ctrl_fetch_ram(); + if (false == udc_process_setup()) { + udd_ctrl_stall_data(); + return; + } else if (Udd_setup_is_in()) { + udd_ctrl_prev_payload_nb_trans = 0; + udd_ctrl_payload_nb_trans = 0; + udd_ep_control_state = UDD_EPCTRL_DATA_IN; + usb_device_endpoint_read_buffer_job(&usb_device,0,udd_ctrl_buffer,USB_DEVICE_EP_CTRL_SIZE); + udd_ctrl_in_sent(); + } else { + if(0 == udd_g_ctrlreq.req.wLength) { + udd_ctrl_send_zlp_in(); + return; + } else { + udd_ctrl_prev_payload_nb_trans = 0; + udd_ctrl_payload_nb_trans = 0; + udd_ep_control_state = UDD_EPCTRL_DATA_OUT; + /* Initialize buffer size and enable OUT bank */ + usb_device_endpoint_read_buffer_job(&usb_device,0,udd_ctrl_buffer,USB_DEVICE_EP_CTRL_SIZE); + } + } + } +} + +/** + * \brief Control Endpoint Process when underflow condition has occurred + * \param[in] pointer Pointer to the endpoint transfer status parameter struct from driver layer. + */ +static void udd_ctrl_underflow(void* pointer) +{ + struct usb_endpoint_callback_parameter *ep_callback_para = (struct usb_endpoint_callback_parameter*)pointer; + + if (UDD_EPCTRL_DATA_OUT == udd_ep_control_state) { + /* Host want to stop OUT transaction + * then stop to wait OUT data phase and wait IN ZLP handshake */ + udd_ctrl_send_zlp_in(); + } else if (UDD_EPCTRL_HANDSHAKE_WAIT_OUT_ZLP == udd_ep_control_state) { + /* A OUT handshake is waiting by device, + * but host want extra IN data then stall extra IN data */ + usb_device_endpoint_set_halt(&usb_device, ep_callback_para->endpoint_address); + } +} + +/** + * \brief Control Endpoint Process when overflow condition has occurred + * \param[in] pointer Pointer to the endpoint transfer status parameter struct from driver layer. + */ +static void udd_ctrl_overflow(void* pointer) +{ + struct usb_endpoint_callback_parameter *ep_callback_para = (struct usb_endpoint_callback_parameter*)pointer; + + if (UDD_EPCTRL_DATA_IN == udd_ep_control_state) { + /* Host want to stop IN transaction + * then stop to wait IN data phase and wait OUT ZLP handshake */ + udd_ep_control_state = UDD_EPCTRL_HANDSHAKE_WAIT_OUT_ZLP; + } else if (UDD_EPCTRL_HANDSHAKE_WAIT_IN_ZLP == udd_ep_control_state) { + /* A IN handshake is waiting by device, + * but host want extra OUT data then stall extra OUT data and following status stage */ + usb_device_endpoint_set_halt(&usb_device, ep_callback_para->endpoint_address); + } +} + +/** + * \internal + * \brief Control endpoint transfer fail callback function + * \param[in] module_inst Pointer to USB module instance + * \param[in] pointer Pointer to the endpoint transfer status parameter struct from driver layer. + */ +static void _usb_ep0_on_tansfer_fail(struct usb_module *module_inst, void* pointer) +{ + struct usb_endpoint_callback_parameter *ep_callback_para = (struct usb_endpoint_callback_parameter*)pointer; + + if(ep_callback_para->endpoint_address & USB_EP_DIR_IN) { + udd_ctrl_underflow(pointer); + } else { + udd_ctrl_overflow(pointer); + } +} + +/** + * \internal + * \brief Control endpoint transfer complete callback function + * \param[in] module_inst Pointer to USB module instance + * \param[in] pointer Pointer to the endpoint transfer status parameter struct from driver layer. + */ +static void _usb_ep0_on_tansfer_ok(struct usb_module *module_inst, void * pointer) +{ + if (UDD_EPCTRL_DATA_OUT == udd_ep_control_state) { /* handshake Out for status stage */ + udd_ctrl_out_received(pointer); + } else if (UDD_EPCTRL_DATA_IN == udd_ep_control_state) { /* handshake In for status stage */ + udd_ctrl_in_sent(); + } else { + if (NULL != udd_g_ctrlreq.callback) { + udd_g_ctrlreq.callback(); + } + udd_ep_control_state = UDD_EPCTRL_SETUP; + } +} + +/** + * \brief Enable Control Endpoint + * \param[in] module_inst Pointer to USB module instance + */ +static void udd_ctrl_ep_enable(struct usb_module *module_inst) +{ + /* USB Device Endpoint0 Configuration */ + struct usb_device_endpoint_config config_ep0; + + usb_device_endpoint_get_config_defaults(&config_ep0); + config_ep0.ep_size = (enum usb_endpoint_size)(32 - clz(((uint32_t)Min(Max(USB_DEVICE_EP_CTRL_SIZE, 8), 1024) << 1) - 1) - 1 - 3); + usb_device_endpoint_set_config(module_inst,&config_ep0); + + usb_device_endpoint_setup_buffer_job(module_inst,udd_ctrl_buffer); + + usb_device_endpoint_register_callback(module_inst,0,USB_DEVICE_ENDPOINT_CALLBACK_RXSTP, _usb_ep0_on_setup ); + usb_device_endpoint_register_callback(module_inst,0,USB_DEVICE_ENDPOINT_CALLBACK_TRCPT,_usb_ep0_on_tansfer_ok ); + usb_device_endpoint_register_callback(module_inst,0,USB_DEVICE_ENDPOINT_CALLBACK_TRFAIL,_usb_ep0_on_tansfer_fail ); + usb_device_endpoint_enable_callback(module_inst,0,USB_DEVICE_ENDPOINT_CALLBACK_RXSTP); + usb_device_endpoint_enable_callback(module_inst,0,USB_DEVICE_ENDPOINT_CALLBACK_TRCPT); + usb_device_endpoint_enable_callback(module_inst,0,USB_DEVICE_ENDPOINT_CALLBACK_TRFAIL); + +#ifdef USB_DEVICE_LPM_SUPPORT + // Enable LPM feature + usb_device_set_lpm_mode(module_inst, USB_DEVICE_LPM_ACK); +#endif + + udd_ep_control_state = UDD_EPCTRL_SETUP; +} + +/** + * \internal + * \brief Control endpoint Suspend callback function + * \param[in] module_inst Pointer to USB module instance + * \param[in] pointer Pointer to the callback parameter from driver layer. + */ +static void _usb_on_suspend(struct usb_module *module_inst, void *pointer) +{ + usb_device_disable_callback(&usb_device, USB_DEVICE_CALLBACK_SUSPEND); + usb_device_enable_callback(&usb_device, USB_DEVICE_CALLBACK_WAKEUP); + udd_sleep_mode(UDD_STATE_SUSPEND); +#ifdef UDC_SUSPEND_EVENT + UDC_SUSPEND_EVENT(); +#endif +} + +#ifdef USB_DEVICE_LPM_SUPPORT +static void _usb_device_lpm_suspend(struct usb_module *module_inst, void *pointer) +{ + dbg_print("LPM_SUSP\n"); + + uint32_t *lpm_wakeup_enable; + lpm_wakeup_enable = (uint32_t *)pointer; + + usb_device_disable_callback(&usb_device, USB_DEVICE_CALLBACK_LPMSUSP); + usb_device_disable_callback(&usb_device, USB_DEVICE_CALLBACK_SUSPEND); + usb_device_enable_callback(&usb_device, USB_DEVICE_CALLBACK_WAKEUP); + +//#warning Here the sleep mode must be choose to have a DFLL startup time < bmAttribut.BESL + udd_sleep_mode(UDD_STATE_SUSPEND_LPM); // Enter in LPM SUSPEND mode + if ((*lpm_wakeup_enable)) { + UDC_REMOTEWAKEUP_LPM_ENABLE(); + } + if (!(*lpm_wakeup_enable)) { + UDC_REMOTEWAKEUP_LPM_DISABLE(); + } + UDC_SUSPEND_LPM_EVENT(); +} +#endif + +/** + * \internal + * \brief Control endpoint SOF callback function + * \param[in] module_inst Pointer to USB module instance + * \param[in] pointer Pointer to the callback parameter from driver layer. + */ +static void _usb_on_sof_notify(struct usb_module *module_inst, void *pointer) +{ + udc_sof_notify(); +#ifdef UDC_SOF_EVENT + UDC_SOF_EVENT(); +#endif +} + +/** + * \internal + * \brief Control endpoint Reset callback function + * \param[in] module_inst Pointer to USB module instance + * \param[in] pointer Pointer to the callback parameter from driver layer. + */ +static void _usb_on_bus_reset(struct usb_module *module_inst, void *pointer) +{ + // Reset USB Device Stack Core + udc_reset(); + usb_device_set_address(module_inst,0); + udd_ctrl_ep_enable(module_inst); +} + +/** + * \internal + * \brief Control endpoint Wakeup callback function + * \param[in] module_inst Pointer to USB module instance + * \param[in] pointer Pointer to the callback parameter from driver layer. + */ +static void _usb_on_wakeup(struct usb_module *module_inst, void *pointer) +{ + udd_wait_clock_ready(); + + usb_device_disable_callback(&usb_device, USB_DEVICE_CALLBACK_WAKEUP); + usb_device_enable_callback(&usb_device, USB_DEVICE_CALLBACK_SUSPEND); +#ifdef USB_DEVICE_LPM_SUPPORT + usb_device_register_callback(&usb_device, USB_DEVICE_CALLBACK_LPMSUSP, _usb_device_lpm_suspend); + usb_device_enable_callback(&usb_device, USB_DEVICE_CALLBACK_LPMSUSP); +#endif + udd_sleep_mode(UDD_STATE_IDLE); +#ifdef UDC_RESUME_EVENT + UDC_RESUME_EVENT(); +#endif +} + +void udd_detach(void) +{ + usb_device_detach(&usb_device); + udd_sleep_mode(UDD_STATE_SUSPEND); +} + +void udd_attach(void) +{ + udd_sleep_mode(UDD_STATE_IDLE); + usb_device_attach(&usb_device); + + usb_device_register_callback(&usb_device, USB_DEVICE_CALLBACK_SUSPEND, _usb_on_suspend); + usb_device_register_callback(&usb_device, USB_DEVICE_CALLBACK_SOF, _usb_on_sof_notify); + usb_device_register_callback(&usb_device, USB_DEVICE_CALLBACK_RESET, _usb_on_bus_reset); + usb_device_register_callback(&usb_device, USB_DEVICE_CALLBACK_WAKEUP, _usb_on_wakeup); + + usb_device_enable_callback(&usb_device, USB_DEVICE_CALLBACK_SUSPEND); + usb_device_enable_callback(&usb_device, USB_DEVICE_CALLBACK_SOF); + usb_device_enable_callback(&usb_device, USB_DEVICE_CALLBACK_RESET); + usb_device_enable_callback(&usb_device, USB_DEVICE_CALLBACK_WAKEUP); +#ifdef USB_DEVICE_LPM_SUPPORT + usb_device_register_callback(&usb_device, USB_DEVICE_CALLBACK_LPMSUSP, _usb_device_lpm_suspend); + usb_device_enable_callback(&usb_device, USB_DEVICE_CALLBACK_LPMSUSP); +#endif +} + +#if USB_VBUS_EIC +/** + * \name USB VBUS PAD management + * + * @{ + */ + + /** Check if USB VBus is available */ +# define is_usb_vbus_high() port_pin_get_input_level(USB_VBUS_PIN) + +/** + * \internal + * \brief USB VBUS pin change handler + */ +static void _uhd_vbus_handler(void) +{ + extint_chan_disable_callback(USB_VBUS_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); +# ifndef USB_DEVICE_ATTACH_AUTO_DISABLE + if (is_usb_vbus_high()) { + udd_attach(); + } else { + udd_detach(); + } +# endif +# ifdef UDC_VBUS_EVENT + UDC_VBUS_EVENT(is_usb_vbus_high()); +# endif + extint_chan_enable_callback(USB_VBUS_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); +} + +/** + * \internal + * \brief USB VBUS pin configuration + */ +static void _usb_vbus_config(void) +{ + + /* Initialize EIC for vbus checking */ + struct extint_chan_conf eint_chan_conf; + extint_chan_get_config_defaults(&eint_chan_conf); + + eint_chan_conf.gpio_pin = USB_VBUS_PIN; + eint_chan_conf.gpio_pin_mux = USB_VBUS_EIC_MUX; + eint_chan_conf.gpio_pin_pull = EXTINT_PULL_NONE; + eint_chan_conf.detection_criteria = EXTINT_DETECT_BOTH; + eint_chan_conf.filter_input_signal = true; + + extint_chan_disable_callback(USB_VBUS_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); + extint_chan_set_config(USB_VBUS_EIC_LINE, &eint_chan_conf); + extint_register_callback(_uhd_vbus_handler, + USB_VBUS_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); + extint_chan_enable_callback(USB_VBUS_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); +} +/** @} */ +#endif + +bool udd_include_vbus_monitoring(void) +{ +#if USB_VBUS_EIC + return true; +#else + return false; +#endif +} + +void udd_enable(void) +{ + irqflags_t flags; + + /* To avoid USB interrupt before end of initialization */ + flags = cpu_irq_save(); + +#if USB_ID_EIC + if (usb_dual_enable()) { + /* The current mode has been started by otg_dual_enable() */ + cpu_irq_restore(flags); + return; + } +#endif + struct usb_config config_usb; + + /* USB Module configuration */ + usb_get_config_defaults(&config_usb); + config_usb.source_generator = UDD_CLOCK_GEN; + usb_init(&usb_device, USB, &config_usb); + + /* USB Module Enable */ + usb_enable(&usb_device); + + /* Check clock after enable module, request the clock */ + udd_wait_clock_ready(); + + udd_sleep_mode(UDD_STATE_SUSPEND); + +#if USB_VBUS_EIC + _usb_vbus_config(); + if (is_usb_vbus_high()) { + /* USB Attach */ + _uhd_vbus_handler(); + } +#else + // No VBus detect, assume always high +# ifndef USB_DEVICE_ATTACH_AUTO_DISABLE + udd_attach(); +# endif +#endif + + cpu_irq_restore(flags); +} + +void udd_disable(void) +{ + irqflags_t flags; + + udd_detach(); + + udd_sleep_mode(UDD_STATE_OFF); + + flags = cpu_irq_save(); + usb_dual_disable(); + cpu_irq_restore(flags); +} +/** @} */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/usb/stack_interface/usb_dual.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/usb/stack_interface/usb_dual.c new file mode 100755 index 0000000..0eab4b3 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/usb/stack_interface/usb_dual.c @@ -0,0 +1,175 @@ +/** + * \file + * + * \brief SAM USB Dual Role driver file. + * + * Copyright (C) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include +#include "usb_dual.h" + +#ifndef UDD_ENABLE +# define udc_start() +# define udc_stop() +#else +#include +#endif + +#ifndef UHD_ENABLE +# define uhc_start(void) +# define uhc_stop(b_id_stop) +#else +#include +#endif + +/* State of USB dual role initialization */ +static bool _initialized = false; + +#define _usb_is_id_device() port_pin_get_input_level(USB_ID_PIN) + +#if USB_ID_EIC +static void usb_id_handler(void); + +/** + * \name USB ID PAD management + * + * @{ + */ + +/** + * USB ID pin configuration + */ +static void usb_id_config(void) +{ + struct extint_chan_conf eint_chan_conf; + extint_chan_get_config_defaults(&eint_chan_conf); + + eint_chan_conf.gpio_pin = USB_ID_PIN; + eint_chan_conf.gpio_pin_mux = USB_ID_EIC_MUX; + eint_chan_conf.detection_criteria = EXTINT_DETECT_BOTH; + eint_chan_conf.filter_input_signal = true; + + extint_chan_disable_callback(USB_ID_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); + extint_chan_set_config(USB_ID_EIC_LINE, &eint_chan_conf); + extint_register_callback(usb_id_handler, + USB_ID_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); + extint_chan_enable_callback(USB_ID_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); +} + +/** + * USB ID pin change handler + */ +static void usb_id_handler(void) +{ + extint_chan_disable_callback(USB_ID_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); + if (_usb_is_id_device()) { + uhc_stop(false); + UHC_MODE_CHANGE(false); + udc_start(); + } else { + udc_stop(); + UHC_MODE_CHANGE(true); + uhc_start(); + } + extint_chan_enable_callback(USB_ID_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); +} +#endif +/** @} */ + +/** + * \brief Initialize the USB peripheral and set right role according to ID pin + * + * \return \c true if the ID pin management has been started, otherwise \c false. + */ +bool usb_dual_enable(void) +{ + if (_initialized) { + return false; // Dual role already initialized + } + +#if USB_ID_EIC + _initialized = true; + + struct port_config pin_conf; + port_get_config_defaults(&pin_conf); + + /* Set USB ID Pin as inputs */ + pin_conf.direction = PORT_PIN_DIR_INPUT; + pin_conf.input_pull = PORT_PIN_PULL_UP; + port_pin_set_config(USB_ID_PIN, &pin_conf); + + usb_id_config(); + if (_usb_is_id_device()) { + UHC_MODE_CHANGE(false); + udc_start(); + } else { + UHC_MODE_CHANGE(true); + uhc_start(); + } + + /** + * End of host or device startup, + * the current mode selected is already started now + */ + return true; // ID pin management has been enabled +#else + return false; // ID pin management has not been enabled +#endif +} + +/** + * \brief Deinitialize the dual role driver + */ +void usb_dual_disable(void) +{ + if (!_initialized) { + return; // Dual role not initialized + } + _initialized = false; + +#if USB_ID_EIC + extint_chan_disable_callback(USB_ID_EIC_LINE, + EXTINT_CALLBACK_TYPE_DETECT); +#endif +} + diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/usb/stack_interface/usb_dual.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/usb/stack_interface/usb_dual.h new file mode 100755 index 0000000..8399433 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/usb/stack_interface/usb_dual.h @@ -0,0 +1,110 @@ +/** + * \file + * + * \brief SAM USB Dual Role driver header file. + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _USB_DUAL_H_ +#define _USB_DUAL_H_ + +#include "compiler.h" +#include "preprocessor.h" + +/* Get USB pads pins configuration in board configuration */ +#include "conf_board.h" +#include "board.h" +//#include +#include "port.h" + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \ingroup usb_group + * \defgroup usb_dual_group USB dual role driver + * USB low-level driver for dual role features + * + * @{ + */ + +bool usb_dual_enable(void); +void usb_dual_disable(void); + +/** + * @name USB ID pin management + * + * The ID pin come from the USB connector (A and B receptable) and + * allows to select the USB mode between host or device. + * The ID pin can be managed through EIC pin. + * This feature is optional, and it is enabled if USB_ID_PIN + * is defined in board.h and CONF_BOARD_USB_ID_DETECT defined in + * conf_board.h. +* +* @{ +*/ +#ifdef BOOTLOADER_USES_HOST +#define USB_ID_DETECT (defined(CONF_BOARD_USB_ID_DETECT)) +#define USB_ID_EIC (defined(USB_ID_PIN) && USB_ID_DETECT) +/** @} */ + +/** + * @name USB Vbus management + * + * The VBus line can be monitored through a EIC pin and + * a basic resistor voltage divider. + * This feature is optional, and it is enabled if USB_VBUS_PIN + * is defined in board.h and CONF_BOARD_USB_VBUS_DETECT defined in + * conf_board.h. + * + * @{ + */ +#define USB_VBUS_DETECT (defined(CONF_BOARD_USB_VBUS_DETECT)) +#define USB_VBUS_EIC (defined(USB_VBUS_PIN) && USB_VBUS_DETECT) +#endif //BOOTLOADER_USES_HOST +/** @} */ + +/** @} */ + +#ifdef __cplusplus +} +#endif + +#endif // _USB_DUAL_H_ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/usb/usb.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/usb/usb.c new file mode 100755 index 0000000..dd21b8d --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/usb/usb.c @@ -0,0 +1,2066 @@ +/** + * \file + * + * \brief SAM USB Driver. + * + * Copyright (C) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include +#include "usb.h" + +/** Fields definition from a LPM TOKEN */ +#define USB_LPM_ATTRIBUT_BLINKSTATE_MASK (0xF << 0) +#define USB_LPM_ATTRIBUT_BESL_MASK (0xF << 4) +#define USB_LPM_ATTRIBUT_REMOTEWAKE_MASK (1 << 8) +#define USB_LPM_ATTRIBUT_BLINKSTATE(value) ((value & 0xF) << 0) +#define USB_LPM_ATTRIBUT_BESL(value) ((value & 0xF) << 4) +#define USB_LPM_ATTRIBUT_REMOTEWAKE(value) ((value & 1) << 8) +#define USB_LPM_ATTRIBUT_BLINKSTATE_L1 USB_LPM_ATTRIBUT_BLINKSTATE(1) + +/** + * \brief Mask selecting the index part of an endpoint address + */ +#define USB_EP_ADDR_MASK 0x0f + +/** + * \brief Endpoint transfer direction is IN + */ +#define USB_EP_DIR_IN 0x80 + +/** + * \brief Endpoint transfer direction is OUT + */ +#define USB_EP_DIR_OUT 0x00 + +#if SAMD21 || SAMD11 +/** + * \name Macros for USB device those are not realized in head file + * + * @{ + */ +#define USB_DEVICE_EPINTENCLR_TRCPT0 USB_DEVICE_EPINTENCLR_TRCPT(1) +#define USB_DEVICE_EPINTENCLR_TRCPT1 USB_DEVICE_EPINTENCLR_TRCPT(2) +#define USB_DEVICE_EPINTENCLR_TRFAIL0 USB_DEVICE_EPINTENCLR_TRFAIL(1) +#define USB_DEVICE_EPINTENCLR_TRFAIL1 USB_DEVICE_EPINTENCLR_TRFAIL(2) +#define USB_DEVICE_EPINTENCLR_STALL0 USB_DEVICE_EPINTENCLR_STALL(1) +#define USB_DEVICE_EPINTENCLR_STALL1 USB_DEVICE_EPINTENCLR_STALL(2) + +#define USB_DEVICE_EPINTENSET_TRCPT0 USB_DEVICE_EPINTENSET_TRCPT(1) +#define USB_DEVICE_EPINTENSET_TRCPT1 USB_DEVICE_EPINTENSET_TRCPT(2) +#define USB_DEVICE_EPINTENSET_TRFAIL0 USB_DEVICE_EPINTENSET_TRFAIL(1) +#define USB_DEVICE_EPINTENSET_TRFAIL1 USB_DEVICE_EPINTENSET_TRFAIL(2) +#define USB_DEVICE_EPINTENSET_STALL0 USB_DEVICE_EPINTENSET_STALL(1) +#define USB_DEVICE_EPINTENSET_STALL1 USB_DEVICE_EPINTENSET_STALL(2) + +#define USB_DEVICE_EPINTFLAG_TRCPT0 USB_DEVICE_EPINTFLAG_TRCPT(1) +#define USB_DEVICE_EPINTFLAG_TRCPT1 USB_DEVICE_EPINTFLAG_TRCPT(2) +#define USB_DEVICE_EPINTFLAG_TRFAIL0 USB_DEVICE_EPINTFLAG_TRFAIL(1) +#define USB_DEVICE_EPINTFLAG_TRFAIL1 USB_DEVICE_EPINTFLAG_TRFAIL(2) +#define USB_DEVICE_EPINTFLAG_STALL0 USB_DEVICE_EPINTFLAG_STALL(1) +#define USB_DEVICE_EPINTFLAG_STALL1 USB_DEVICE_EPINTFLAG_STALL(2) + +#define USB_DEVICE_EPSTATUSSET_STALLRQ0 USB_DEVICE_EPSTATUSSET_STALLRQ(1) +#define USB_DEVICE_EPSTATUSSET_STALLRQ1 USB_DEVICE_EPSTATUSSET_STALLRQ(2) +#define USB_DEVICE_EPSTATUSCLR_STALLRQ0 USB_DEVICE_EPSTATUSCLR_STALLRQ(1) +#define USB_DEVICE_EPSTATUSCLR_STALLRQ1 USB_DEVICE_EPSTATUSCLR_STALLRQ(2) +/** @} */ +#endif + +/** + * \name USB SRAM data containing pipe descriptor table + * The content of the USB SRAM can be : + * - modified by USB hardware interface to update pipe status. + * Thereby, it is read by software. + * - modified by USB software to control pipe. + * Thereby, it is read by hardware. + * This data section is volatile. + * + * @{ + */ +COMPILER_PACK_SET(1) +COMPILER_WORD_ALIGNED +union { + UsbDeviceDescriptor usb_endpoint_table[USB_EPT_NUM]; + UsbHostDescriptor usb_pipe_table[USB_PIPE_NUM]; +} usb_descriptor_table; +COMPILER_PACK_RESET() +/** @} */ + +/** + * \brief Local USB module instance + */ +static struct usb_module *_usb_instances; + +#if !SAMD11 +/** + * \brief Host pipe callback structure variable + */ +static struct usb_pipe_callback_parameter pipe_callback_para; +#endif + +/* Device LPM callback variable */ +static uint32_t device_callback_lpm_wakeup_enable; + +/** + * \brief Device endpoint callback parameter variable, used to transfer info to UDD wrapper layer + */ +static struct usb_endpoint_callback_parameter ep_callback_para; + +/** + * \internal USB Device IRQ Mask Bits Map + */ +static const uint16_t _usb_device_irq_bits[USB_DEVICE_CALLBACK_N] = { + USB_DEVICE_INTFLAG_SOF, + USB_DEVICE_INTFLAG_EORST, + USB_DEVICE_INTFLAG_WAKEUP | USB_DEVICE_INTFLAG_EORSM | USB_DEVICE_INTFLAG_UPRSM, + USB_DEVICE_INTFLAG_RAMACER, + USB_DEVICE_INTFLAG_SUSPEND, + USB_DEVICE_INTFLAG_LPMNYET, + USB_DEVICE_INTFLAG_LPMSUSP, +}; + +/** + * \internal USB Device IRQ Mask Bits Map + */ +static const uint8_t _usb_endpoint_irq_bits[USB_DEVICE_EP_CALLBACK_N] = { + USB_DEVICE_EPINTFLAG_TRCPT_Msk, + USB_DEVICE_EPINTFLAG_TRFAIL_Msk, + USB_DEVICE_EPINTFLAG_RXSTP, + USB_DEVICE_EPINTFLAG_STALL_Msk +}; + +#if !SAMD11 +/** + * \brief Bit mask for pipe job busy status + */ +uint32_t host_pipe_job_busy_status = 0; + +/** + * \brief Registers a USB host callback + * + * Registers a callback function which is implemented by the user. + * + * \note The callback must be enabled by \ref usb_host_enable_callback, + * in order for the interrupt handler to call it when the conditions for the + * callback type is met. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] callback_type Callback type given by an enum + * \param[in] callback_func Pointer to callback function + * + * \return Status of the registration operation. + * \retval STATUS_OK The callback was registered successfully. + */ +enum status_code usb_host_register_callback(struct usb_module *module_inst, + enum usb_host_callback callback_type, + usb_host_callback_t callback_func) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(callback_func); + + /* Register callback function */ + module_inst->host_callback[callback_type] = callback_func; + + /* Set the bit corresponding to the callback_type */ + module_inst->host_registered_callback_mask |= (1 << callback_type); + + return STATUS_OK; +} + +/** + * \brief Unregisters a USB host callback + * + * Unregisters an asynchronous callback implemented by the user. Removing it + * from the internal callback registration table. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the de-registration operation. + * \retval STATUS_OK The callback was unregistered successfully. + */ +enum status_code usb_host_unregister_callback(struct usb_module *module_inst, + enum usb_host_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + + /* Unregister callback function */ + module_inst->host_callback[callback_type] = NULL; + + /* Clear the bit corresponding to the callback_type */ + module_inst->host_registered_callback_mask &= ~(1 << callback_type); + + return STATUS_OK; +} + +/** + * \brief Enables USB host callback generation for a given type. + * + * Enables asynchronous callbacks for a given logical type. + * This must be called before USB host generate callback events. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the callback enable operation. + * \retval STATUS_OK The callback was enabled successfully. + */ +enum status_code usb_host_enable_callback(struct usb_module *module_inst, + enum usb_host_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + /* Enable callback */ + module_inst->host_enabled_callback_mask |= (1 << callback_type); + + if (callback_type == USB_HOST_CALLBACK_SOF) { + module_inst->hw->HOST.INTENSET.reg = USB_HOST_INTENSET_HSOF; + } + if (callback_type == USB_HOST_CALLBACK_RESET) { + module_inst->hw->HOST.INTENSET.reg = USB_HOST_INTENSET_RST; + } + if (callback_type == USB_HOST_CALLBACK_WAKEUP) { + module_inst->hw->HOST.INTENSET.reg = USB_HOST_INTENSET_WAKEUP; + } + if (callback_type == USB_HOST_CALLBACK_DNRSM) { + module_inst->hw->HOST.INTENSET.reg = USB_HOST_INTENSET_DNRSM; + } + if (callback_type == USB_HOST_CALLBACK_UPRSM) { + module_inst->hw->HOST.INTENSET.reg = USB_HOST_INTENSET_UPRSM; + } + if (callback_type == USB_HOST_CALLBACK_RAMACER) { + module_inst->hw->HOST.INTENSET.reg = USB_HOST_INTENSET_RAMACER; + } + if (callback_type == USB_HOST_CALLBACK_CONNECT) { + module_inst->hw->HOST.INTENSET.reg = USB_HOST_INTENSET_DCONN; + } + if (callback_type == USB_HOST_CALLBACK_DISCONNECT) { + module_inst->hw->HOST.INTENSET.reg = USB_HOST_INTENSET_DDISC; + } + + return STATUS_OK; +} + +/** + * \brief Disables USB host callback generation for a given type. + * + * Disables asynchronous callbacks for a given logical type. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the callback disable operation. + * \retval STATUS_OK The callback was disabled successfully. + */ +enum status_code usb_host_disable_callback(struct usb_module *module_inst, + enum usb_host_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + /* Disable callback */ + module_inst->host_enabled_callback_mask &= ~(1 << callback_type); + + if (callback_type == USB_HOST_CALLBACK_SOF) { + module_inst->hw->HOST.INTENCLR.reg = USB_HOST_INTENCLR_HSOF; + } + if (callback_type == USB_HOST_CALLBACK_RESET) { + module_inst->hw->HOST.INTENCLR.reg = USB_HOST_INTENCLR_RST; + } + if (callback_type == USB_HOST_CALLBACK_WAKEUP) { + module_inst->hw->HOST.INTENCLR.reg = USB_HOST_INTENCLR_WAKEUP; + } + if (callback_type == USB_HOST_CALLBACK_DNRSM) { + module_inst->hw->HOST.INTENCLR.reg = USB_HOST_INTENCLR_DNRSM; + } + if (callback_type == USB_HOST_CALLBACK_UPRSM) { + module_inst->hw->HOST.INTENCLR.reg = USB_HOST_INTENCLR_UPRSM; + } + if (callback_type == USB_HOST_CALLBACK_RAMACER) { + module_inst->hw->HOST.INTENCLR.reg = USB_HOST_INTENCLR_RAMACER; + } + if (callback_type == USB_HOST_CALLBACK_CONNECT) { + module_inst->hw->HOST.INTENCLR.reg = USB_HOST_INTENCLR_DCONN; + } + if (callback_type == USB_HOST_CALLBACK_DISCONNECT) { + module_inst->hw->HOST.INTENCLR.reg = USB_HOST_INTENCLR_DDISC; + } + + return STATUS_OK; +} + +/** + * \brief Initializes an USB host pipe configuration structure to defaults. + * + * Initializes a given USB host pipe configuration structure to a + * set of known default values. This function should be called on all new + * instances of these configuration structures before being modified by the + * user application. + * + * The default configuration is as follows: + * \li device address is 0 + * \li endpoint address is 0 + * \li pipe type is control + * \li interval is 0 + * \li pipe size is 8 + * + * \param[out] ep_config Configuration structure to initialize to default values + */ +void usb_host_pipe_get_config_defaults(struct usb_host_pipe_config *ep_config) +{ + /* Sanity check arguments */ + Assert(ep_config); + /* Write default config to config struct */ + ep_config->device_address = 0; + ep_config->endpoint_address = 0; + ep_config->pipe_type = USB_HOST_PIPE_TYPE_CONTROL; + ep_config->binterval = 0; + ep_config->size = 8; +} + +/** + * \brief Writes an USB host pipe configuration to the hardware module. + * + * Writes out a given configuration of an USB host pipe + * configuration to the hardware module. If the pipe is already configured, + * the new configuration will replace the existing one. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] ep_config Configuration settings for the pipe + * + * \return Status of the host pipe configuration operation. + * \retval STATUS_OK The host pipe was configured successfully. + */ +enum status_code usb_host_pipe_set_config(struct usb_module *module_inst, uint8_t pipe_num, + struct usb_host_pipe_config *ep_config) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(pipe_num < USB_PIPE_NUM); + Assert(ep_config); + + /* set pipe config */ + module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.BK = 0; + module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTYPE = ep_config->pipe_type; + module_inst->hw->HOST.HostPipe[pipe_num].BINTERVAL.reg = + ep_config->binterval; + if (ep_config->endpoint_address == 0) { + module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTOKEN = + USB_HOST_PIPE_TOKEN_SETUP; + } else if (ep_config->endpoint_address & USB_EP_DIR_IN) { + module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTOKEN = + USB_HOST_PIPE_TOKEN_IN; + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSSET.reg = + USB_HOST_PSTATUSSET_BK0RDY; + } else { + module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTOKEN = + USB_HOST_PIPE_TOKEN_OUT; + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSCLR.reg = + USB_HOST_PSTATUSCLR_BK0RDY; + } + + memset((uint8_t *)&usb_descriptor_table.usb_pipe_table[pipe_num], 0, + sizeof(usb_descriptor_table.usb_pipe_table[0])); + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].CTRL_PIPE.bit.PDADDR = + ep_config->device_address; + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].CTRL_PIPE.bit.PEPNUM = + ep_config->endpoint_address & USB_EP_ADDR_MASK; + if (ep_config->size == 1023) { + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.SIZE = 0x07; + } else { + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.SIZE = + (32 - clz(((uint32_t)min(max(ep_config->size, 8), 1024) << 1) - 1) - 1 - 3); + } + + /* Clear busy status */ + host_pipe_job_busy_status &= ~(1 << pipe_num); + + return STATUS_OK; +} + +/** + * \brief Gets an USB host pipe configuration. + * + * Gets out the configuration of an USB host pipe from the hardware module. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[out] ep_config Configuration settings for the pipe + * + * \return Status of the get host pipe configuration operation. + * \retval STATUS_OK The host pipe configuration was read successfully. + */ +enum status_code usb_host_pipe_get_config(struct usb_module *module_inst, uint8_t pipe_num, + struct usb_host_pipe_config *ep_config) +{ + uint32_t size; + + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(pipe_num < USB_PIPE_NUM); + Assert(ep_config); + /* get pipe config from setting register */ + ep_config->device_address = + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].CTRL_PIPE.bit.PDADDR; + ep_config->endpoint_address = + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].CTRL_PIPE.bit.PEPNUM; + + if (module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTOKEN == + USB_HOST_PIPE_TOKEN_IN) { + ep_config->endpoint_address |= USB_EP_DIR_IN; + } + + ep_config->pipe_type = (enum usb_host_pipe_type)module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTYPE; + ep_config->binterval = + module_inst->hw->HOST.HostPipe[pipe_num].BINTERVAL.reg; + size = usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.SIZE; + if (size == 0x07) { + ep_config->size = 1023; + } else { + ep_config->size = (8 << size); + } + + return STATUS_OK; +} + +/** + * \brief Registers a USB host pipe callback + * + * Registers a callback function which is implemented by the user. + * + * \note The callback must be enabled by \ref usb_host_pipe_enable_callback, + * in order for the interrupt handler to call it when the conditions for the + * callback type is met. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] callback_type Callback type given by an enum + * \param[in] callback_func Pointer to callback function + * + * \return Status of the registration operation. + * \retval STATUS_OK The callback was registered successfully. + */ +enum status_code usb_host_pipe_register_callback( + struct usb_module *module_inst, uint8_t pipe_num, + enum usb_host_pipe_callback callback_type, + usb_host_pipe_callback_t callback_func) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(pipe_num < USB_PIPE_NUM); + Assert(callback_func); + + /* Register callback function */ + module_inst->host_pipe_callback[pipe_num][callback_type] = callback_func; + + /* Set the bit corresponding to the callback_type */ + module_inst->host_pipe_registered_callback_mask[pipe_num] |= (1 << callback_type); + + return STATUS_OK; +} + +/** + * \brief Unregisters a USB host pipe callback + * + * Unregisters an asynchronous callback implemented by the user. Removing it + * from the internal callback registration table. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the de-registration operation. + * \retval STATUS_OK The callback was unregistered successfully. + */ +enum status_code usb_host_pipe_unregister_callback( + struct usb_module *module_inst, uint8_t pipe_num, + enum usb_host_pipe_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(pipe_num < USB_PIPE_NUM); + + /* Unregister callback function */ + module_inst->host_pipe_callback[pipe_num][callback_type] = NULL; + + /* Clear the bit corresponding to the callback_type */ + module_inst->host_pipe_registered_callback_mask[pipe_num] &= ~(1 << callback_type); + + return STATUS_OK; +} + +/** + * \brief Enables USB host pipe callback generation for a given type. + * + * Enables asynchronous callbacks for a given logical type. + * This must be called before USB host pipe generate callback events. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the callback enable operation. + * \retval STATUS_OK The callback was enabled successfully. + */ +enum status_code usb_host_pipe_enable_callback( + struct usb_module *module_inst, uint8_t pipe_num, + enum usb_host_pipe_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(pipe_num < USB_PIPE_NUM); + + /* Enable callback */ + module_inst->host_pipe_enabled_callback_mask[pipe_num] |= (1 << callback_type); + + if (callback_type == USB_HOST_PIPE_CALLBACK_TRANSFER_COMPLETE) { + module_inst->hw->HOST.HostPipe[pipe_num].PINTENSET.reg = USB_HOST_PINTENSET_TRCPT_Msk; + } + if (callback_type == USB_HOST_PIPE_CALLBACK_ERROR) { + module_inst->hw->HOST.HostPipe[pipe_num].PINTENSET.reg = + USB_HOST_PINTENSET_TRFAIL | USB_HOST_PINTENSET_PERR; + } + if (callback_type == USB_HOST_PIPE_CALLBACK_SETUP) { + module_inst->hw->HOST.HostPipe[pipe_num].PINTENSET.reg = USB_HOST_PINTENSET_TXSTP; + } + if (callback_type == USB_HOST_PIPE_CALLBACK_STALL) { + module_inst->hw->HOST.HostPipe[pipe_num].PINTENSET.reg = USB_HOST_PINTENSET_STALL; + } + + return STATUS_OK; +} + +/** + * \brief Disables USB host callback generation for a given type. + * + * Disables asynchronous callbacks for a given logical type. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the callback disable operation. + * \retval STATUS_OK The callback was disabled successfully. + */ +enum status_code usb_host_pipe_disable_callback( + struct usb_module *module_inst, uint8_t pipe_num, + enum usb_host_pipe_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(pipe_num < USB_PIPE_NUM); + + /* Enable callback */ + module_inst->host_pipe_enabled_callback_mask[pipe_num] &= ~(1 << callback_type); + + if (callback_type == USB_HOST_PIPE_CALLBACK_TRANSFER_COMPLETE) { + module_inst->hw->HOST.HostPipe[pipe_num].PINTENCLR.reg = USB_HOST_PINTENCLR_TRCPT_Msk; + } + if (callback_type == USB_HOST_PIPE_CALLBACK_ERROR) { + module_inst->hw->HOST.HostPipe[pipe_num].PINTENCLR.reg = + USB_HOST_PINTENCLR_TRFAIL| USB_HOST_PINTENCLR_PERR; + } + if (callback_type == USB_HOST_PIPE_CALLBACK_SETUP) { + module_inst->hw->HOST.HostPipe[pipe_num].PINTENCLR.reg = USB_HOST_PINTENCLR_TXSTP; + } + if (callback_type == USB_HOST_PIPE_CALLBACK_STALL) { + module_inst->hw->HOST.HostPipe[pipe_num].PINTENCLR.reg = USB_HOST_PINTENCLR_STALL; + } + + return STATUS_OK; +} + +/** + * \brief Sends the setup package. + * + * Sends the setup package. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] buf Pointer to data buffer + * + * \return Status of the setup operation. + * \retval STATUS_OK The setup job was set successfully. + * \retval STATUS_BUSY The pipe is busy. + * \retval STATUS_ERR_NOT_INITIALIZED The pipe has not been configured. + */ +enum status_code usb_host_pipe_setup_job(struct usb_module *module_inst, + uint8_t pipe_num, uint8_t *buf) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(pipe_num < USB_PIPE_NUM); + + if (host_pipe_job_busy_status & (1 << pipe_num)) { + return STATUS_BUSY; + } + + /* Set busy status */ + host_pipe_job_busy_status |= 1 << pipe_num; + + if (module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTYPE == + USB_HOST_PIPE_TYPE_DISABLE) { + return STATUS_ERR_NOT_INITIALIZED; + } + + /* get pipe config from setting register */ + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].ADDR.reg = (uint32_t)buf; + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.BYTE_COUNT = + 8; + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE = + 0; + module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTOKEN = + USB_HOST_PIPE_TOKEN_SETUP; + + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSSET.reg = USB_HOST_PSTATUSSET_BK0RDY; + usb_host_pipe_unfreeze(module_inst, pipe_num); + + return STATUS_OK; +} + +/** + * \brief USB host pipe read job. + * + * USB host pipe read job by set and start an in transaction transfer. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] buf Pointer to data buffer + * \param[in] buf_size Data buffer size + * \note The buffer length should not larger than 0x3FFF + * + * \return Status of the setting operation. + * \retval STATUS_OK The read job was set successfully. + * \retval STATUS_BUSY The pipe is busy. + * \retval STATUS_ERR_NOT_INITIALIZED The pipe has not been configured. + */ +enum status_code usb_host_pipe_read_job(struct usb_module *module_inst, + uint8_t pipe_num, uint8_t *buf, uint32_t buf_size) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(pipe_num < USB_PIPE_NUM); + + if (host_pipe_job_busy_status & (1 << pipe_num)) { + return STATUS_BUSY; + } + + /* Set busy status */ + host_pipe_job_busy_status |= 1 << pipe_num; + + if (module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTYPE == + USB_HOST_PIPE_TYPE_DISABLE) { + return STATUS_ERR_NOT_INITIALIZED; + } + + /* get pipe config from setting register */ + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].ADDR.reg = (uint32_t)buf; + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.BYTE_COUNT = + 0; + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE = + buf_size; + module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTOKEN = + USB_HOST_PIPE_TOKEN_IN; + + /* Start transfer */ + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSCLR.reg = USB_HOST_PSTATUSCLR_BK0RDY; + usb_host_pipe_unfreeze(module_inst, pipe_num); + + return STATUS_OK; +} + +/** + * \brief USB host pipe write job. + * + * USB host pipe write job by set and start an out transaction transfer. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] buf Pointer to data buffer + * \param[in] buf_size Data buffer size + * \note The buffer length should not larger than 0x3FFF + * + * \return Status of the setting operation. + * \retval STATUS_OK The write job was set successfully. + * \retval STATUS_BUSY The pipe is busy. + * \retval STATUS_ERR_NOT_INITIALIZED The pipe has not been configured. + */ +enum status_code usb_host_pipe_write_job(struct usb_module *module_inst, + uint8_t pipe_num, uint8_t *buf, uint32_t buf_size) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(pipe_num < USB_PIPE_NUM); + + if (host_pipe_job_busy_status & (1 << pipe_num)) { + return STATUS_BUSY; + } + + /* Set busy status */ + host_pipe_job_busy_status |= 1 << pipe_num; + + if (module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTYPE == + USB_HOST_PIPE_TYPE_DISABLE) { + return STATUS_ERR_NOT_INITIALIZED; + } + + /* get pipe config from setting register */ + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].ADDR.reg = (uint32_t)buf; + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.BYTE_COUNT = + buf_size; + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE = + 0; + module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTOKEN = + USB_HOST_PIPE_TOKEN_OUT; + + /* Start transfer */ + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSSET.reg = USB_HOST_PSTATUSSET_BK0RDY; + usb_host_pipe_unfreeze(module_inst, pipe_num); + + return STATUS_OK; +} + +/** + * \brief USB host abort a pipe job. + * + * USB host pipe abort job by freeze the pipe. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * + * \return Status of the setting operation. + * \retval STATUS_OK The abort job was set successfully. + * \retval STATUS_ERR_NOT_INITIALIZED The pipe has not been configured. + */ +enum status_code usb_host_pipe_abort_job(struct usb_module *module_inst, uint8_t pipe_num) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(pipe_num < USB_PIPE_NUM); + + if (module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTYPE == + USB_HOST_PIPE_TYPE_DISABLE) { + return STATUS_ERR_NOT_INITIALIZED; + } + + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSSET.reg = USB_HOST_PSTATUSSET_PFREEZE; + + /* Clear busy status */ + host_pipe_job_busy_status &= ~(1 << pipe_num); + + return STATUS_OK; +} + +/** + * \brief Sends the LPM package. + * + * Sends the LPM package. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] buf Pointer to data buffer + * + * \return Status of the setup operation. + * \retval STATUS_OK The setup job was set successfully. + * \retval STATUS_BUSY The pipe is busy. + * \retval STATUS_ERR_NOT_INITIALIZED The pipe has not been configured. + */ +enum status_code usb_host_pipe_lpm_job(struct usb_module *module_inst, + uint8_t pipe_num, bool b_remotewakeup, uint8_t besl) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(pipe_num < USB_PIPE_NUM); + + if (host_pipe_job_busy_status & (1 << pipe_num)) { + return STATUS_BUSY; + } + + /* Set busy status */ + host_pipe_job_busy_status |= 1 << pipe_num; + + if (module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTYPE == + USB_HOST_PIPE_TYPE_DISABLE) { + return STATUS_ERR_NOT_INITIALIZED; + } + + module_inst->hw->HOST.HostPipe[pipe_num].PCFG.bit.PTYPE = + USB_HOST_PIPE_TYPE_EXTENDED; + + /* get pipe config from setting register */ + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].EXTREG.bit.SUBPID = 0x3; + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].EXTREG.bit.VARIABLE = + USB_LPM_ATTRIBUT_REMOTEWAKE(b_remotewakeup) | + USB_LPM_ATTRIBUT_BESL(besl) | + USB_LPM_ATTRIBUT_BLINKSTATE_L1; + + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSSET.reg = USB_HOST_PSTATUSSET_BK0RDY; + usb_host_pipe_unfreeze(module_inst, pipe_num); + + return STATUS_OK; +} + +/** + * \internal + * \brief Function called by USB interrupt to manage USB host interrupts + * + * USB host interrupt events are split into four sections: + * - USB line events + * (Device dis/connection, SOF, reset, resume, wakeup, error) + * - Pipe events + * (End of data transfer, setup, stall, error) + */ +static void _usb_host_interrupt_handler(void) +{ +#if BOOTLOADER_USES_HOST + + uint32_t pipe_int; + uint32_t flags; + + /* Manage pipe interrupts */ + pipe_int = ctz(_usb_instances->hw->HOST.PINTSMRY.reg); + if (pipe_int < 32) { + /* pipe interrupts */ + + /* get interrupt flags */ + flags = _usb_instances->hw->HOST.HostPipe[pipe_int].PINTFLAG.reg; + + /* host pipe transfer complete interrupt */ + if (flags & USB_HOST_PINTFLAG_TRCPT_Msk) { + /* Clear busy status */ + host_pipe_job_busy_status &= ~(1 << pipe_int); + /* clear the flag */ + _usb_instances->hw->HOST.HostPipe[pipe_int].PINTFLAG.reg = + USB_HOST_PINTFLAG_TRCPT_Msk; + if(_usb_instances->host_pipe_enabled_callback_mask[pipe_int] & + (1 << USB_HOST_PIPE_CALLBACK_TRANSFER_COMPLETE)) { + pipe_callback_para.pipe_num = pipe_int; + if (_usb_instances->hw->HOST.HostPipe[pipe_int].PCFG.bit.PTOKEN == + USB_HOST_PIPE_TOKEN_IN) { + /* in */ + pipe_callback_para.transfered_size = usb_descriptor_table.usb_pipe_table[pipe_int].HostDescBank[0].PCKSIZE.bit.BYTE_COUNT; + pipe_callback_para.required_size = usb_descriptor_table.usb_pipe_table[pipe_int].HostDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE; + usb_descriptor_table.usb_pipe_table[pipe_int].HostDescBank[0].PCKSIZE.bit.BYTE_COUNT = 0; + } else { + /* out */ + pipe_callback_para.transfered_size = usb_descriptor_table.usb_pipe_table[pipe_int].HostDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE; + pipe_callback_para.required_size = usb_descriptor_table.usb_pipe_table[pipe_int].HostDescBank[0].PCKSIZE.bit.BYTE_COUNT; + usb_descriptor_table.usb_pipe_table[pipe_int].HostDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE = 0; + if (0 == pipe_callback_para.transfered_size) { + pipe_callback_para.transfered_size = usb_descriptor_table.usb_pipe_table[pipe_int].HostDescBank[0].PCKSIZE.bit.BYTE_COUNT; + } + } + (_usb_instances->host_pipe_callback[pipe_int] + [USB_HOST_PIPE_CALLBACK_TRANSFER_COMPLETE])(_usb_instances, &pipe_callback_para); + } + } + + /* host pipe transfer fail interrupt */ + if (flags & USB_HOST_PINTFLAG_TRFAIL) { + /* Clear busy status */ + host_pipe_job_busy_status &= ~(1 << pipe_int); + /* clear the flag */ + _usb_instances->hw->HOST.HostPipe[pipe_int].PINTFLAG.reg = + USB_HOST_PINTFLAG_TRFAIL; + } + + /* host pipe error interrupt */ + if (flags & USB_HOST_PINTFLAG_PERR) { + /* Clear busy status */ + host_pipe_job_busy_status &= ~(1 << pipe_int); + /* clear the flag */ + _usb_instances->hw->HOST.HostPipe[pipe_int].PINTFLAG.reg = + USB_HOST_PINTFLAG_PERR; + if(_usb_instances->host_pipe_enabled_callback_mask[pipe_int] & + (1 << USB_HOST_PIPE_CALLBACK_ERROR)) { + pipe_callback_para.pipe_num = pipe_int; + pipe_callback_para.pipe_error_status = + usb_descriptor_table.usb_pipe_table[pipe_int].HostDescBank[0].STATUS_PIPE.reg & 0x1F; + (_usb_instances->host_pipe_callback[pipe_int] + [USB_HOST_PIPE_CALLBACK_ERROR])(_usb_instances, &pipe_callback_para); + } + } + + /* host pipe transmitted setup interrupt */ + if (flags & USB_HOST_PINTFLAG_TXSTP) { + /* Clear busy status */ + host_pipe_job_busy_status &= ~(1 << pipe_int); + /* clear the flag */ + _usb_instances->hw->HOST.HostPipe[pipe_int].PINTFLAG.reg = + USB_HOST_PINTFLAG_TXSTP; + if(_usb_instances->host_pipe_enabled_callback_mask[pipe_int] & + (1 << USB_HOST_PIPE_CALLBACK_SETUP)) { + pipe_callback_para.pipe_num = pipe_int; + pipe_callback_para.transfered_size = usb_descriptor_table.usb_pipe_table[pipe_int].HostDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE; + (_usb_instances->host_pipe_callback[pipe_int] + [USB_HOST_PIPE_CALLBACK_SETUP])(_usb_instances, NULL); + } + } + + /* host pipe stall interrupt */ + if (flags & USB_HOST_PINTFLAG_STALL) { + /* Clear busy status */ + host_pipe_job_busy_status &= ~(1 << pipe_int); + /* clear the flag */ + _usb_instances->hw->HOST.HostPipe[pipe_int].PINTFLAG.reg = + USB_HOST_PINTFLAG_STALL; + if(_usb_instances->host_pipe_enabled_callback_mask[pipe_int] & + (1 << USB_HOST_PIPE_CALLBACK_STALL)) { + pipe_callback_para.pipe_num = pipe_int; + (_usb_instances->host_pipe_callback[pipe_int] + [USB_HOST_PIPE_CALLBACK_STALL])(_usb_instances, &pipe_callback_para); + } + } + + } else { + /* host interrupts */ + + /* get interrupt flags */ + flags = _usb_instances->hw->HOST.INTFLAG.reg; + + /* host SOF interrupt */ + if (flags & USB_HOST_INTFLAG_HSOF) { + /* clear the flag */ + _usb_instances->hw->HOST.INTFLAG.reg = USB_HOST_INTFLAG_HSOF; + if(_usb_instances->host_enabled_callback_mask & (1 << USB_HOST_CALLBACK_SOF)) { + (_usb_instances->host_callback[USB_HOST_CALLBACK_SOF])(_usb_instances); + } + } + + /* host reset interrupt */ + if (flags & USB_HOST_INTFLAG_RST) { + /* Clear busy status */ + host_pipe_job_busy_status = 0; + /* clear the flag */ + _usb_instances->hw->HOST.INTFLAG.reg = USB_HOST_INTFLAG_RST; + if(_usb_instances->host_enabled_callback_mask & (1 << USB_HOST_CALLBACK_RESET)) { + (_usb_instances->host_callback[USB_HOST_CALLBACK_RESET])(_usb_instances); + } + } + + /* host upstream resume interrupts */ + if (flags & USB_HOST_INTFLAG_UPRSM) { + /* clear the flags */ + _usb_instances->hw->HOST.INTFLAG.reg = USB_HOST_INTFLAG_UPRSM; + if(_usb_instances->host_enabled_callback_mask & (1 << USB_HOST_CALLBACK_UPRSM)) { + (_usb_instances->host_callback[USB_HOST_CALLBACK_UPRSM])(_usb_instances); + } + } + + /* host downstream resume interrupts */ + if (flags & USB_HOST_INTFLAG_DNRSM) { + /* clear the flags */ + _usb_instances->hw->HOST.INTFLAG.reg = USB_HOST_INTFLAG_DNRSM; + if(_usb_instances->host_enabled_callback_mask & (1 << USB_HOST_CALLBACK_DNRSM)) { + (_usb_instances->host_callback[USB_HOST_CALLBACK_DNRSM])(_usb_instances); + } + } + + /* host wakeup interrupts */ + if (flags & USB_HOST_INTFLAG_WAKEUP) { + /* clear the flags */ + _usb_instances->hw->HOST.INTFLAG.reg = USB_HOST_INTFLAG_WAKEUP; + if(_usb_instances->host_enabled_callback_mask & (1 << USB_HOST_CALLBACK_WAKEUP)) { + (_usb_instances->host_callback[USB_HOST_CALLBACK_WAKEUP])(_usb_instances); + } + } + + /* host ram access interrupt */ + if (flags & USB_HOST_INTFLAG_RAMACER) { + /* Clear busy status */ + host_pipe_job_busy_status = 0; + /* clear the flag */ + _usb_instances->hw->HOST.INTFLAG.reg = USB_HOST_INTFLAG_RAMACER; + if(_usb_instances->host_enabled_callback_mask & (1 << USB_HOST_CALLBACK_RAMACER)) { + (_usb_instances->host_callback[USB_HOST_CALLBACK_RAMACER])(_usb_instances); + } + } + + /* host connect interrupt */ + if (flags & USB_HOST_INTFLAG_DCONN) { + /* Clear busy status */ + host_pipe_job_busy_status = 0; + /* clear the flag */ + _usb_instances->hw->HOST.INTFLAG.reg = USB_HOST_INTFLAG_DCONN; + if(_usb_instances->host_enabled_callback_mask & (1 << USB_HOST_CALLBACK_CONNECT)) { + (_usb_instances->host_callback[USB_HOST_CALLBACK_CONNECT])(_usb_instances); + } + } + + /* host disconnect interrupt */ + if (flags & USB_HOST_INTFLAG_DDISC) { + /* Clear busy status */ + host_pipe_job_busy_status = 0; + /* clear the flag */ + _usb_instances->hw->HOST.INTFLAG.reg = USB_HOST_INTFLAG_DDISC; + if(_usb_instances->host_enabled_callback_mask & (1 << USB_HOST_CALLBACK_DISCONNECT)) { + (_usb_instances->host_callback[USB_HOST_CALLBACK_DISCONNECT])(_usb_instances); + } + } + + } +#endif +} + +/** + * \brief Sets USB host pipe auto ZLP setting value + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] pipe_num Pipe to configure + * \param[in] value Auto ZLP setting value, \c true to enable + * + */ +void usb_host_pipe_set_auto_zlp(struct usb_module *module_inst, uint8_t pipe_num, bool value) +{ + Assert(module_inst); + + usb_descriptor_table.usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.AUTO_ZLP = value; +} +#endif + +/** + * \brief Registers a USB device callback + * + * Registers a callback function which is implemented by the user. + * + * \note The callback must be enabled by \ref usb_host_enable_callback, + * in order for the interrupt handler to call it when the conditions for the + * callback type is met. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] callback_type Callback type given by an enum + * \param[in] callback_func Pointer to callback function + * + * \return Status of the registration operation. + * \retval STATUS_OK The callback was registered successfully. + */ +enum status_code usb_device_register_callback(struct usb_module *module_inst, + enum usb_device_callback callback_type, + usb_device_callback_t callback_func) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(callback_func); + + /* Register callback function */ + module_inst->device_callback[callback_type] = callback_func; + + /* Set the bit corresponding to the callback_type */ + module_inst->device_registered_callback_mask |= _usb_device_irq_bits[callback_type]; + + return STATUS_OK; +} + +/** + * \brief Unregisters a USB device callback + * + * Unregisters an asynchronous callback implemented by the user. Removing it + * from the internal callback registration table. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the de-registration operation. + * \retval STATUS_OK The callback was unregistered successfully. + */ +enum status_code usb_device_unregister_callback(struct usb_module *module_inst, + enum usb_device_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + + /* Unregister callback function */ + module_inst->device_callback[callback_type] = NULL; + + /* Clear the bit corresponding to the callback_type */ + module_inst->device_registered_callback_mask &= ~_usb_device_irq_bits[callback_type]; + + return STATUS_OK; +} + +/** + * \brief Enables USB device callback generation for a given type. + * + * Enables asynchronous callbacks for a given logical type. + * This must be called before USB host generate callback events. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the callback enable operation. + * \retval STATUS_OK The callback was enabled successfully. + */ +enum status_code usb_device_enable_callback(struct usb_module *module_inst, + enum usb_device_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + /* clear related flag */ + module_inst->hw->DEVICE.INTFLAG.reg = _usb_device_irq_bits[callback_type]; + + /* Enable callback */ + module_inst->device_enabled_callback_mask |= _usb_device_irq_bits[callback_type]; + + module_inst->hw->DEVICE.INTENSET.reg = _usb_device_irq_bits[callback_type]; + + return STATUS_OK; +} + +/** + * \brief Disables USB device callback generation for a given type. + * + * Disables asynchronous callbacks for a given logical type. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the callback disable operation. + * \retval STATUS_OK The callback was disabled successfully. + */ +enum status_code usb_device_disable_callback(struct usb_module *module_inst, + enum usb_device_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + /* Disable callback */ + module_inst->device_enabled_callback_mask &= ~_usb_device_irq_bits[callback_type]; + + module_inst->hw->DEVICE.INTENCLR.reg = _usb_device_irq_bits[callback_type]; + + return STATUS_OK; +} + +/** + * \brief Registers a USB device endpoint callback + * + * Registers a callback function which is implemented by the user. + * + * \note The callback must be enabled by \ref usb_device_endpoint_enable_callback, + * in order for the interrupt handler to call it when the conditions for the + * callback type is met. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] ep_num Endpoint to configure + * \param[in] callback_type Callback type given by an enum + * \param[in] callback_func Pointer to callback function + * + * \return Status of the registration operation. + * \retval STATUS_OK The callback was registered successfully. + */ +enum status_code usb_device_endpoint_register_callback( + struct usb_module *module_inst, uint8_t ep_num, + enum usb_device_endpoint_callback callback_type, + usb_device_endpoint_callback_t callback_func) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(ep_num < USB_EPT_NUM); + Assert(callback_func); + + /* Register callback function */ + module_inst->device_endpoint_callback[ep_num][callback_type] = callback_func; + + /* Set the bit corresponding to the callback_type */ + module_inst->deivce_endpoint_registered_callback_mask[ep_num] |= _usb_endpoint_irq_bits[callback_type]; + + return STATUS_OK; +} + +/** + * \brief Unregisters a USB device endpoint callback + * + * Unregisters an callback implemented by the user. Removing it + * from the internal callback registration table. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] ep_num Endpoint to configure + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the de-registration operation. + * \retval STATUS_OK The callback was unregistered successfully. + */ +enum status_code usb_device_endpoint_unregister_callback( + struct usb_module *module_inst, uint8_t ep_num, + enum usb_device_endpoint_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(ep_num < USB_EPT_NUM); + + /* Unregister callback function */ + module_inst->device_endpoint_callback[ep_num][callback_type] = NULL; + + /* Clear the bit corresponding to the callback_type */ + module_inst->deivce_endpoint_registered_callback_mask[ep_num] &= ~_usb_endpoint_irq_bits[callback_type]; + + return STATUS_OK; +} + +/** + * \brief Enables USB device endpoint callback generation for a given type. + * + * Enables callbacks for a given logical type. + * This must be called before USB host pipe generate callback events. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] ep Endpoint to configure + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the callback enable operation. + * \retval STATUS_OK The callback was enabled successfully. + */ +enum status_code usb_device_endpoint_enable_callback( + struct usb_module *module_inst, uint8_t ep, + enum usb_device_endpoint_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + Assert(ep_num < USB_EPT_NUM); + + /* Enable callback */ + module_inst->device_endpoint_enabled_callback_mask[ep_num] |= _usb_endpoint_irq_bits[callback_type]; + + if (callback_type == USB_DEVICE_ENDPOINT_CALLBACK_TRCPT) { + if (ep_num == 0) { // control endpoint + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENSET.reg = USB_DEVICE_EPINTENSET_TRCPT0 | USB_DEVICE_EPINTENSET_TRCPT1; + } else if (ep & USB_EP_DIR_IN) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENSET.reg = USB_DEVICE_EPINTENSET_TRCPT1; + } else { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENSET.reg = USB_DEVICE_EPINTENSET_TRCPT0; + } + } + + if (callback_type == USB_DEVICE_ENDPOINT_CALLBACK_TRFAIL) { + if (ep_num == 0) { // control endpoint + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENSET.reg = USB_DEVICE_EPINTENSET_TRFAIL0 | USB_DEVICE_EPINTENSET_TRFAIL1; + } else if (ep & USB_EP_DIR_IN) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENSET.reg = USB_DEVICE_EPINTENSET_TRFAIL1; + } else { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENSET.reg = USB_DEVICE_EPINTENSET_TRFAIL0; + } + } + + if (callback_type == USB_DEVICE_ENDPOINT_CALLBACK_RXSTP) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENSET.reg = USB_DEVICE_EPINTENSET_RXSTP; + } + + if (callback_type == USB_DEVICE_ENDPOINT_CALLBACK_STALL) { + if (ep & USB_EP_DIR_IN) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENSET.reg = USB_DEVICE_EPINTENSET_STALL1; + } else { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENSET.reg = USB_DEVICE_EPINTENSET_STALL0; + } + } + + return STATUS_OK; +} + +/** + * \brief Disables USB device endpoint callback generation for a given type. + * + * Disables callbacks for a given logical type. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] ep Endpoint to configure + * \param[in] callback_type Callback type given by an enum + * + * \return Status of the callback disable operation. + * \retval STATUS_OK The callback was disabled successfully. + */ +enum status_code usb_device_endpoint_disable_callback( + struct usb_module *module_inst, uint8_t ep, + enum usb_device_endpoint_callback callback_type) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + Assert(ep_num < USB_EPT_NUM); + + /* Enable callback */ + module_inst->device_endpoint_enabled_callback_mask[ep_num] &= ~_usb_endpoint_irq_bits[callback_type]; + + if (callback_type == USB_DEVICE_ENDPOINT_CALLBACK_TRCPT) { + if (ep_num == 0) { // control endpoint + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENCLR.reg = USB_DEVICE_EPINTENCLR_TRCPT0 | USB_DEVICE_EPINTENCLR_TRCPT1; + } else if (ep & USB_EP_DIR_IN) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENCLR.reg = USB_DEVICE_EPINTENCLR_TRCPT1; + } else { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENCLR.reg = USB_DEVICE_EPINTENCLR_TRCPT0; + } + } + + if (callback_type == USB_DEVICE_ENDPOINT_CALLBACK_TRFAIL) { + if (ep_num == 0) { // control endpoint + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENCLR.reg = USB_DEVICE_EPINTENCLR_TRFAIL0 | USB_DEVICE_EPINTENCLR_TRFAIL1; + } else if (ep & USB_EP_DIR_IN) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENCLR.reg = USB_DEVICE_EPINTENCLR_TRFAIL1; + } else { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENCLR.reg = USB_DEVICE_EPINTENCLR_TRFAIL0; + } + } + + if (callback_type == USB_DEVICE_ENDPOINT_CALLBACK_RXSTP) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENCLR.reg = USB_DEVICE_EPINTENCLR_RXSTP; + } + + if (callback_type == USB_DEVICE_ENDPOINT_CALLBACK_STALL) { + if (ep & USB_EP_DIR_IN) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENCLR.reg = USB_DEVICE_EPINTENCLR_STALL1; + } else { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTENCLR.reg = USB_DEVICE_EPINTENCLR_STALL0; + } + } + + return STATUS_OK; +} + +/** + * \brief Initializes an USB device endpoint configuration structure to defaults. + * + * Initializes a given USB device endpoint configuration structure to a + * set of known default values. This function should be called on all new + * instances of these configuration structures before being modified by the + * user application. + * + * The default configuration is as follows: + * \li endpoint address is 0 + * \li endpoint size is 8 bytes + * \li auto_zlp is false + * \li endpoint type is control + * + * \param[out] ep_config Configuration structure to initialize to default values + */ +void usb_device_endpoint_get_config_defaults(struct usb_device_endpoint_config *ep_config) +{ + /* Sanity check arguments */ + Assert(ep_config); + + /* Write default config to config struct */ + ep_config->ep_address = 0; + ep_config->ep_size = USB_ENDPOINT_8_BYTE; + ep_config->auto_zlp = false; + ep_config->ep_type = USB_DEVICE_ENDPOINT_TYPE_CONTROL; +} + +/** + * \brief Writes an USB device endpoint configuration to the hardware module. + * + * Writes out a given configuration of an USB device endpoint + * configuration to the hardware module. If the pipe is already configured, + * the new configuration will replace the existing one. + * + * \param[in] module_inst Pointer to USB software instance struct + * \param[in] ep_config Configuration settings for the endpoint + * + * \return Status of the device endpoint configuration operation + * \retval STATUS_OK The device endpoint was configured successfully + * \retval STATUS_ERR_DENIED The endpoint address is already configured + */ +enum status_code usb_device_endpoint_set_config(struct usb_module *module_inst, + struct usb_device_endpoint_config *ep_config) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(ep_config); + + uint8_t ep_num = ep_config->ep_address & USB_EP_ADDR_MASK; + uint8_t ep_bank = (ep_config->ep_address & USB_EP_DIR_IN) ? 1 : 0; + + switch (ep_config->ep_type) { + case USB_DEVICE_ENDPOINT_TYPE_DISABLE: + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg = USB_DEVICE_EPCFG_EPTYPE0(0) | USB_DEVICE_EPCFG_EPTYPE1(0); + return STATUS_OK; + + case USB_DEVICE_ENDPOINT_TYPE_CONTROL: + if ((module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg & USB_DEVICE_EPCFG_EPTYPE0_Msk) == 0 && \ + (module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg & USB_DEVICE_EPCFG_EPTYPE1_Msk) == 0) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg = USB_DEVICE_EPCFG_EPTYPE0(1) | USB_DEVICE_EPCFG_EPTYPE1(1); + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_BK0RDY; + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_BK1RDY; + } else { + return STATUS_ERR_DENIED; + } + if (true == ep_config->auto_zlp) { + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[0].PCKSIZE.reg |= USB_DEVICE_PCKSIZE_AUTO_ZLP; + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[1].PCKSIZE.reg |= USB_DEVICE_PCKSIZE_AUTO_ZLP; + } else { + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[0].PCKSIZE.reg &= ~USB_DEVICE_PCKSIZE_AUTO_ZLP; + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[1].PCKSIZE.reg &= ~USB_DEVICE_PCKSIZE_AUTO_ZLP; + } + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[0].PCKSIZE.bit.SIZE = ep_config->ep_size; + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[1].PCKSIZE.bit.SIZE = ep_config->ep_size; + return STATUS_OK; + + case USB_DEVICE_ENDPOINT_TYPE_ISOCHRONOUS: + if (ep_bank) { + if ((module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg & USB_DEVICE_EPCFG_EPTYPE1_Msk) == 0){ + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg |= USB_DEVICE_EPCFG_EPTYPE1(2); + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_BK1RDY; + } else { + return STATUS_ERR_DENIED; + } + } else { + if ((module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg & USB_DEVICE_EPCFG_EPTYPE0_Msk) == 0){ + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg |= USB_DEVICE_EPCFG_EPTYPE0(2); + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_BK0RDY; + } else { + return STATUS_ERR_DENIED; + } + } + break; + + case USB_DEVICE_ENDPOINT_TYPE_BULK: + if (ep_bank) { + if ((module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg & USB_DEVICE_EPCFG_EPTYPE1_Msk) == 0){ + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg |= USB_DEVICE_EPCFG_EPTYPE1(3); + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_BK1RDY; + } else { + return STATUS_ERR_DENIED; + } + } else { + if ((module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg & USB_DEVICE_EPCFG_EPTYPE0_Msk) == 0){ + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg |= USB_DEVICE_EPCFG_EPTYPE0(3); + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_BK0RDY; + } else { + return STATUS_ERR_DENIED; + } + } + break; + + case USB_DEVICE_ENDPOINT_TYPE_INTERRUPT: + if (ep_bank) { + if ((module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg & USB_DEVICE_EPCFG_EPTYPE1_Msk) == 0){ + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg |= USB_DEVICE_EPCFG_EPTYPE1(4); + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_BK1RDY; + } else { + return STATUS_ERR_DENIED; + } + } else { + if ((module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg & USB_DEVICE_EPCFG_EPTYPE0_Msk) == 0){ + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.reg |= USB_DEVICE_EPCFG_EPTYPE0(4); + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_BK0RDY; + } else { + return STATUS_ERR_DENIED; + } + } + break; + + default: + break; + } + + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[ep_bank].PCKSIZE.bit.SIZE = ep_config->ep_size; + + if (true == ep_config->auto_zlp) { + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[ep_bank].PCKSIZE.reg |= USB_DEVICE_PCKSIZE_AUTO_ZLP; + } else { + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[ep_bank].PCKSIZE.reg &= ~USB_DEVICE_PCKSIZE_AUTO_ZLP; + } + + return STATUS_OK; +} + +/** + * \brief Check if current endpoint is configured + * + * \param module_inst Pointer to USB software instance struct + * \param ep Endpoint address (direction & number) + * + * \return \c true if endpoint is configured and ready to use + */ +bool usb_device_endpoint_is_configured(struct usb_module *module_inst, uint8_t ep) +{ + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + uint8_t flag; + + if (ep & USB_EP_DIR_IN) { + flag = (uint8_t)(module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.bit.EPTYPE1); + } else { + flag = (uint8_t)(module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.bit.EPTYPE0); + } + return ((enum usb_device_endpoint_type)(flag) != USB_DEVICE_ENDPOINT_TYPE_DISABLE); +} + + +/** + * \brief Abort ongoing job on the endpoint + * + * \param module_inst Pointer to USB software instance struct + * \param ep Endpoint address + */ +void usb_device_endpoint_abort_job(struct usb_module *module_inst, uint8_t ep) +{ + uint8_t ep_num; + ep_num = ep & USB_EP_ADDR_MASK; + + // Stop transfer + if (ep & USB_EP_DIR_IN) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_BK1RDY; + // Eventually ack a transfer occur during abort + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRCPT1; + } else { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_BK0RDY; + // Eventually ack a transfer occur during abort + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRCPT0; + } +} + +/** + * \brief Check if endpoint is halted + * + * \param module_inst Pointer to USB software instance struct + * \param ep Endpoint address + * + * \return \c true if the endpoint is halted + */ +bool usb_device_endpoint_is_halted(struct usb_module *module_inst, uint8_t ep) +{ + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + + if (ep & USB_EP_DIR_IN) { + return (module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUS.reg & USB_DEVICE_EPSTATUSSET_STALLRQ1); + } else { + return (module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUS.reg & USB_DEVICE_EPSTATUSSET_STALLRQ0); + } +} + +/** + * \brief Halt the endpoint (send STALL) + * + * \param module_inst Pointer to USB software instance struct + * \param ep Endpoint address + */ +void usb_device_endpoint_set_halt(struct usb_module *module_inst, uint8_t ep) +{ + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + + // Stall endpoint + if (ep & USB_EP_DIR_IN) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_STALLRQ1; + } else { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_STALLRQ0; + } +} + +/** + * \brief Clear endpoint halt state + * + * \param module_inst Pointer to USB software instance struct + * \param ep Endpoint address + */ +void usb_device_endpoint_clear_halt(struct usb_module *module_inst, uint8_t ep) +{ + uint8_t ep_num = ep & USB_EP_ADDR_MASK; + + if (ep & USB_EP_DIR_IN) { + if (module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUS.reg & USB_DEVICE_EPSTATUSSET_STALLRQ1) { + // Remove stall request + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_STALLRQ1; + if (module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_STALL1) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_STALL1; + // The Stall has occurred, then reset data toggle + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSSET_DTGLIN; + } + } + } else { + if (module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUS.reg & USB_DEVICE_EPSTATUSSET_STALLRQ0) { + // Remove stall request + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_STALLRQ0; + if (module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_STALL0) { + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_STALL0; + // The Stall has occurred, then reset data toggle + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSSET_DTGLOUT; + } + } + } +} + +/** + * \brief Start write buffer job on a endpoint + * + * \param module_inst Pointer to USB module instance + * \param ep_num Endpoint number + * \param pbuf Pointer to buffer + * \param buf_size Size of buffer + * + * \return Status of procedure + * \retval STATUS_OK Job started successfully + * \retval STATUS_ERR_DENIED Endpoint is not ready + */ +enum status_code usb_device_endpoint_write_buffer_job(struct usb_module *module_inst,uint8_t ep_num, + uint8_t* pbuf, uint32_t buf_size) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(ep_num < USB_EPT_NUM); + + uint8_t flag; + flag = (uint8_t)(module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.bit.EPTYPE1); + if ((enum usb_device_endpoint_type)(flag) == USB_DEVICE_ENDPOINT_TYPE_DISABLE) { + return STATUS_ERR_DENIED; + }; + + /* get endpoint configuration from setting register */ + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[1].ADDR.reg = (uint32_t)pbuf; + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[1].PCKSIZE.bit.MULTI_PACKET_SIZE = 0; + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[1].PCKSIZE.bit.BYTE_COUNT = buf_size; + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_BK1RDY; + + return STATUS_OK; +} + +/** + * \brief Start read buffer job on a endpoint + * + * \param module_inst Pointer to USB module instance + * \param ep_num Endpoint number + * \param pbuf Pointer to buffer + * \param buf_size Size of buffer + * + * \return Status of procedure + * \retval STATUS_OK Job started successfully + * \retval STATUS_ERR_DENIED Endpoint is not ready + */ +enum status_code usb_device_endpoint_read_buffer_job(struct usb_module *module_inst,uint8_t ep_num, + uint8_t* pbuf, uint32_t buf_size) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + Assert(ep_num < USB_EPT_NUM); + + uint8_t flag; + flag = (uint8_t)(module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPCFG.bit.EPTYPE0); + if ((enum usb_device_endpoint_type)(flag) == USB_DEVICE_ENDPOINT_TYPE_DISABLE) { + return STATUS_ERR_DENIED; + }; + + /* get endpoint configuration from setting register */ + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[0].ADDR.reg = (uint32_t)pbuf; + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE = buf_size; + usb_descriptor_table.usb_endpoint_table[ep_num].DeviceDescBank[0].PCKSIZE.bit.BYTE_COUNT = 0; + module_inst->hw->DEVICE.DeviceEndpoint[ep_num].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_BK0RDY; + + return STATUS_OK; +} + +/** + * \brief Start setup packet read job on a endpoint + * + * \param module_inst Pointer to USB device module instance + * \param pbuf Pointer to buffer + * + * \return Status of procedure + * \retval STATUS_OK Job started successfully + * \retval STATUS_ERR_DENIED Endpoint is not ready + */ +enum status_code usb_device_endpoint_setup_buffer_job(struct usb_module *module_inst, + uint8_t* pbuf) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + /* get endpoint configuration from setting register */ + usb_descriptor_table.usb_endpoint_table[0].DeviceDescBank[0].ADDR.reg = (uint32_t)pbuf; + usb_descriptor_table.usb_endpoint_table[0].DeviceDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE = 8; + usb_descriptor_table.usb_endpoint_table[0].DeviceDescBank[0].PCKSIZE.bit.BYTE_COUNT = 0; + module_inst->hw->DEVICE.DeviceEndpoint[0].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_BK0RDY; + + return STATUS_OK; +} + +static void _usb_device_interrupt_handler(void) +{ + uint16_t ep_inst; + uint16_t flags, flags_run; + ep_inst = _usb_instances->hw->DEVICE.EPINTSMRY.reg; + + /* device interrupt */ + if (0 == ep_inst) { + int i; + + /* get interrupt flags */ + flags = _usb_instances->hw->DEVICE.INTFLAG.reg; + flags_run = flags & + _usb_instances->device_enabled_callback_mask & + _usb_instances->device_registered_callback_mask; + + for (i = 0; i < USB_DEVICE_CALLBACK_N; i ++) { + if (flags & _usb_device_irq_bits[i]) { + _usb_instances->hw->DEVICE.INTFLAG.reg = + _usb_device_irq_bits[i]; + } + if (flags_run & _usb_device_irq_bits[i]) { + if (i == USB_DEVICE_CALLBACK_LPMSUSP) { + device_callback_lpm_wakeup_enable = + usb_descriptor_table.usb_endpoint_table[0].DeviceDescBank[0].EXTREG.bit.VARIABLE + & USB_LPM_ATTRIBUT_REMOTEWAKE_MASK; + } + (_usb_instances->device_callback[i])(_usb_instances, &device_callback_lpm_wakeup_enable); + } + } + + } else { + /* endpoint interrupt */ + + for (uint8_t i = 0; i < USB_EPT_NUM; i++) { + + if (ep_inst & (1 << i)) { + flags = _usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg; + flags_run = flags & + _usb_instances->device_endpoint_enabled_callback_mask[i] & + _usb_instances->deivce_endpoint_registered_callback_mask[i]; + + // endpoint transfer stall interrupt + if (flags & USB_DEVICE_EPINTFLAG_STALL_Msk) { + if (_usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_STALL1) { + _usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_STALL1; + ep_callback_para.endpoint_address = USB_EP_DIR_IN | i; + } else if (_usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_STALL0) { + _usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_STALL0; + ep_callback_para.endpoint_address = USB_EP_DIR_OUT | i; + } + + if (flags_run & USB_DEVICE_EPINTFLAG_STALL_Msk) { + (_usb_instances->device_endpoint_callback[i][USB_DEVICE_ENDPOINT_CALLBACK_STALL])(_usb_instances,&ep_callback_para); + } + return; + } + + // endpoint received setup interrupt + if (flags & USB_DEVICE_EPINTFLAG_RXSTP) { + _usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_RXSTP; + if(_usb_instances->device_endpoint_enabled_callback_mask[i] & _usb_endpoint_irq_bits[USB_DEVICE_ENDPOINT_CALLBACK_RXSTP]) { + ep_callback_para.received_bytes = (uint16_t)(usb_descriptor_table.usb_endpoint_table[i].DeviceDescBank[0].PCKSIZE.bit.BYTE_COUNT); + (_usb_instances->device_endpoint_callback[i][USB_DEVICE_ENDPOINT_CALLBACK_RXSTP])(_usb_instances,&ep_callback_para); + } + return; + } + + // endpoint transfer fail interrupt + if (flags & USB_DEVICE_EPINTFLAG_TRFAIL_Msk) { + if (_usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_TRFAIL1) { + _usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRFAIL1; + if (usb_descriptor_table.usb_endpoint_table[i].DeviceDescBank[1].STATUS_BK.reg & USB_DEVICE_STATUS_BK_ERRORFLOW) { + usb_descriptor_table.usb_endpoint_table[i].DeviceDescBank[1].STATUS_BK.reg &= ~USB_DEVICE_STATUS_BK_ERRORFLOW; + } + ep_callback_para.endpoint_address = USB_EP_DIR_IN | i; + if (_usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_TRCPT1) { + return; + } + } else if(_usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_TRFAIL0) { + _usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRFAIL0; + if (usb_descriptor_table.usb_endpoint_table[i].DeviceDescBank[0].STATUS_BK.reg & USB_DEVICE_STATUS_BK_ERRORFLOW) { + usb_descriptor_table.usb_endpoint_table[i].DeviceDescBank[0].STATUS_BK.reg &= ~USB_DEVICE_STATUS_BK_ERRORFLOW; + } + ep_callback_para.endpoint_address = USB_EP_DIR_OUT | i; + if (_usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_TRCPT0) { + return; + } + } + + if(flags_run & USB_DEVICE_EPINTFLAG_TRFAIL_Msk) { + (_usb_instances->device_endpoint_callback[i][USB_DEVICE_ENDPOINT_CALLBACK_TRFAIL])(_usb_instances,&ep_callback_para); + } + return; + } + + // endpoint transfer complete interrupt + if (flags & USB_DEVICE_EPINTFLAG_TRCPT_Msk) { + if (_usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_TRCPT1) { + _usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRCPT1; + ep_callback_para.endpoint_address = USB_EP_DIR_IN | i; + ep_callback_para.sent_bytes = (uint16_t)(usb_descriptor_table.usb_endpoint_table[i].DeviceDescBank[1].PCKSIZE.bit.BYTE_COUNT); + + } else if (_usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_TRCPT0) { + _usb_instances->hw->DEVICE.DeviceEndpoint[i].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRCPT0; + ep_callback_para.endpoint_address = USB_EP_DIR_OUT | i; + ep_callback_para.received_bytes = (uint16_t)(usb_descriptor_table.usb_endpoint_table[i].DeviceDescBank[0].PCKSIZE.bit.BYTE_COUNT); + ep_callback_para.out_buffer_size = (uint16_t)(usb_descriptor_table.usb_endpoint_table[i].DeviceDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE); + } + if(flags_run & USB_DEVICE_EPINTFLAG_TRCPT_Msk) { + (_usb_instances->device_endpoint_callback[i][USB_DEVICE_ENDPOINT_CALLBACK_TRCPT])(_usb_instances,&ep_callback_para); + } + return; + } + } + } + } +} + +/** + * \brief Enable the USB module peripheral + * + * \param module_inst pointer to USB module instance + */ +void usb_enable(struct usb_module *module_inst) +{ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.CTRLA.reg |= USB_CTRLA_ENABLE; + while (module_inst->hw->HOST.SYNCBUSY.reg == USB_SYNCBUSY_ENABLE); +} + +/** + * \brief Disable the USB module peripheral + * + * \param module_inst pointer to USB module instance + */ +void usb_disable(struct usb_module *module_inst) +{ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.CTRLA.reg &= ~USB_CTRLA_ENABLE; + while (module_inst->hw->HOST.SYNCBUSY.reg == USB_SYNCBUSY_ENABLE); +} + +/** + * \brief Interrupt handler for the USB module. + */ +void USB_Handler(void) +{ + if (_usb_instances->hw->HOST.CTRLA.bit.MODE) { +#if !SAMD11 + /*host mode ISR */ + _usb_host_interrupt_handler(); +#endif + } else { + /*device mode ISR */ + _usb_device_interrupt_handler(); + } +} + +/** + * \brief Get the default USB module settings + * + * \param[out] module_config Configuration structure to initialize to default values + */ +void usb_get_config_defaults(struct usb_config *module_config) +{ + Assert(module_config); + + /* Sanity check arguments */ + Assert(module_config); + /* Write default configuration to config struct */ + module_config->select_host_mode = 0; + module_config->run_in_standby = 1; + module_config->source_generator = GCLK_GENERATOR_0; + module_config->speed_mode = USB_SPEED_FULL; +} + +#define NVM_USB_PAD_TRANSN_POS 45 +#define NVM_USB_PAD_TRANSN_SIZE 5 +#define NVM_USB_PAD_TRANSP_POS 50 +#define NVM_USB_PAD_TRANSP_SIZE 5 +#define NVM_USB_PAD_TRIM_POS 55 +#define NVM_USB_PAD_TRIM_SIZE 3 + +/** + * \brief Initializes USB module instance + * + * Enables the clock and initializes the USB module, based on the given + * configuration values. + * + * \param[in,out] module_inst Pointer to the software module instance struct + * \param[in] hw Pointer to the USB hardware module + * \param[in] module_config Pointer to the USB configuration options struct + * + * \return Status of the initialization procedure. + * + * \retval STATUS_OK The module was initialized successfully + */ +enum status_code usb_init(struct usb_module *module_inst, Usb *const hw, + struct usb_config *module_config) +{ + /* Sanity check arguments */ + Assert(hw); + Assert(module_inst); + Assert(module_config); + + uint32_t i,j; + uint32_t pad_transn, pad_transp, pad_trim; + struct system_pinmux_config pin_config; + struct system_gclk_chan_config gclk_chan_config; + +#if !SAMD11 + host_pipe_job_busy_status = 0; +#endif + + _usb_instances = module_inst; + + /* Associate the software module instance with the hardware module */ + module_inst->hw = hw; + + /* Turn on the digital interface clock */ + system_apb_clock_set_mask(SYSTEM_CLOCK_APB_APBB, PM_APBBMASK_USB); + + /* Set up the USB DP/DN pins */ + system_pinmux_get_config_defaults(&pin_config); + pin_config.mux_position = MUX_PA24G_USB_DM; + system_pinmux_pin_set_config(PIN_PA24G_USB_DM, &pin_config); + pin_config.mux_position = MUX_PA25G_USB_DP; + system_pinmux_pin_set_config(PIN_PA25G_USB_DP, &pin_config); + + /* Setup clock for module */ + system_gclk_chan_get_config_defaults(&gclk_chan_config); + gclk_chan_config.source_generator = module_config->source_generator; + system_gclk_chan_set_config(USB_GCLK_ID, &gclk_chan_config); + system_gclk_chan_enable(USB_GCLK_ID); + + /* Reset */ + hw->HOST.CTRLA.bit.SWRST = 1; + while (hw->HOST.SYNCBUSY.bit.SWRST) { + /* Sync wait */ + } + + /* Load Pad Calibration */ + pad_transn =( *((uint32_t *)(NVMCTRL_OTP4) + + (NVM_USB_PAD_TRANSN_POS / 32)) + >> (NVM_USB_PAD_TRANSN_POS % 32)) + & ((1 << NVM_USB_PAD_TRANSN_SIZE) - 1); + + if (pad_transn == 0x1F) { + pad_transn = 5; + } + + hw->HOST.PADCAL.bit.TRANSN = pad_transn; + + pad_transp =( *((uint32_t *)(NVMCTRL_OTP4) + + (NVM_USB_PAD_TRANSP_POS / 32)) + >> (NVM_USB_PAD_TRANSP_POS % 32)) + & ((1 << NVM_USB_PAD_TRANSP_SIZE) - 1); + + if (pad_transp == 0x1F) { + pad_transp = 29; + } + + hw->HOST.PADCAL.bit.TRANSP = pad_transp; + + pad_trim =( *((uint32_t *)(NVMCTRL_OTP4) + + (NVM_USB_PAD_TRIM_POS / 32)) + >> (NVM_USB_PAD_TRIM_POS % 32)) + & ((1 << NVM_USB_PAD_TRIM_SIZE) - 1); + + if (pad_trim == 0x7) { + pad_trim = 3; + } + + hw->HOST.PADCAL.bit.TRIM = pad_trim; + + /* Set the configuration */ + hw->HOST.CTRLA.bit.MODE = module_config->select_host_mode; + hw->HOST.CTRLA.bit.RUNSTDBY = module_config->run_in_standby; + hw->HOST.DESCADD.reg = (uint32_t)(&usb_descriptor_table.usb_endpoint_table[0]); + if (USB_SPEED_FULL == module_config->speed_mode) { + module_inst->hw->DEVICE.CTRLB.bit.SPDCONF = USB_DEVICE_CTRLB_SPDCONF_0_Val; + } else if(USB_SPEED_LOW == module_config->speed_mode) { + module_inst->hw->DEVICE.CTRLB.bit.SPDCONF = USB_DEVICE_CTRLB_SPDCONF_1_Val; + } + + memset((uint8_t *)(&usb_descriptor_table.usb_endpoint_table[0]), 0, + sizeof(usb_descriptor_table.usb_endpoint_table)); + +#if !SAMD11 + /* callback related init */ + for (i = 0; i < USB_HOST_CALLBACK_N; i++) { + module_inst->host_callback[i] = NULL; + }; + for (i = 0; i < USB_PIPE_NUM; i++) { + for (j = 0; j < USB_HOST_PIPE_CALLBACK_N; j++) { + module_inst->host_pipe_callback[i][j] = NULL; + } + }; + module_inst->host_registered_callback_mask = 0; + module_inst->host_enabled_callback_mask = 0; + for (i = 0; i < USB_PIPE_NUM; i++) { + module_inst->host_pipe_registered_callback_mask[i] = 0; + module_inst->host_pipe_enabled_callback_mask[i] = 0; + } +#endif + + /* device callback related */ + for (i = 0; i < USB_DEVICE_CALLBACK_N; i++) { + module_inst->device_callback[i] = NULL; + } + for (i = 0; i < USB_EPT_NUM; i++) { + for(j = 0; j < USB_DEVICE_EP_CALLBACK_N; j++) { + module_inst->device_endpoint_callback[i][j] = NULL; + } + } + module_inst->device_registered_callback_mask = 0; + module_inst->device_enabled_callback_mask = 0; + for (j = 0; j < USB_EPT_NUM; j++) { + module_inst->deivce_endpoint_registered_callback_mask[j] = 0; + module_inst->device_endpoint_enabled_callback_mask[j] = 0; + } + + /* Enable interrupts for this USB module */ + system_interrupt_enable(SYSTEM_INTERRUPT_MODULE_USB); + + return STATUS_OK; +} + + diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/usb/usb.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/usb/usb.h new file mode 100755 index 0000000..a2e0664 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/drivers/usb/usb.h @@ -0,0 +1,820 @@ +/** + * \file + * + * \brief SAM USB Driver + * + * Copyright (C) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef USB_H_INCLUDED +#define USB_H_INCLUDED + +#include +#include +#include +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \defgroup asfdoc_sam0_usb_group SAM Universal Serial Bus (USB) + * + * The Universal Serial Bus (USB) module complies with the USB 2.1 specification. + * + * The following peripherals are used by this module: + * - USB (Universal Serial Bus) + * + * The following devices can use this module: + * - SAM D21 + * - SAM R21 + * - SAM D11 + * + * The USB module covers following mode: + * \if USB_DEVICE_MODE + * - USB Device Mode + * \endif + * \if USB_HOST_MODE + * - USB Host Mode + * \endif + * + * The USB module covers following speed: + * \if USB_HS_MODE + * - USB High Speed (480Mbit/s) + * \endif + * - USB Full Speed (12Mbit/s) + * \if USB_LS_MODE + * - USB Low Speed (1.5Mbit/s) + * \endif + * + * \if USB_LPM_MODE + * The USB module supports Link Power Management (LPM-L1) protocol. + * \endif + * + * USB support needs whole set of enumeration process, to make the device + * recognizable and usable. The USB driver is designed to interface to the + * USB Stack in Atmel Software Framework (ASF). + * + * \if USB_DEVICE_MODE + * \section asfdoc_sam0_usb_device USB Device Mode + * The ASF USB Device Stack has defined the USB Device Driver (UDD) interface, + * to support USB device operations. The USB module device driver complies with + * this interface, so that the USB Device Stack can work based on the + * USB module. + * + * Refer to + * "ASF - USB Device Stack" for more details. + * \endif + * + * \if USB_HOST_MODE + * \section adfdoc_sam0_usb_host USB Host Mode + * The ASF USB Host Stack has defined the USB Host Driver (UHD) interface, + * to support USB host operations. The USB module host driver complies with + * this interface, so that the USB Host Stack can work based on the USB module. + * + * Refer to + * "ASF - USB Host Stack" for more details. + * \endif + */ + +/** Enum for the speed status for the USB module */ +enum usb_speed { + USB_SPEED_LOW, + USB_SPEED_FULL, +}; + +/** Enum for the possible callback types for the USB in host module */ +enum usb_host_callback { + USB_HOST_CALLBACK_SOF, + USB_HOST_CALLBACK_RESET, + USB_HOST_CALLBACK_WAKEUP, + USB_HOST_CALLBACK_DNRSM, + USB_HOST_CALLBACK_UPRSM, + USB_HOST_CALLBACK_RAMACER, + USB_HOST_CALLBACK_CONNECT, + USB_HOST_CALLBACK_DISCONNECT, + USB_HOST_CALLBACK_N, +}; + +/** Enum for the possible callback types for the USB pipe in host module */ +enum usb_host_pipe_callback { + USB_HOST_PIPE_CALLBACK_TRANSFER_COMPLETE, + USB_HOST_PIPE_CALLBACK_ERROR, + USB_HOST_PIPE_CALLBACK_SETUP, + USB_HOST_PIPE_CALLBACK_STALL, + USB_HOST_PIPE_CALLBACK_N, +}; + +/** + * \brief Host pipe types. + */ +enum usb_host_pipe_type { + USB_HOST_PIPE_TYPE_DISABLE, + USB_HOST_PIPE_TYPE_CONTROL, + USB_HOST_PIPE_TYPE_ISO, + USB_HOST_PIPE_TYPE_BULK, + USB_HOST_PIPE_TYPE_INTERRUPT, + USB_HOST_PIPE_TYPE_EXTENDED, +}; + +/** + * \brief Host pipe token types. + */ +enum usb_host_pipe_token { + USB_HOST_PIPE_TOKEN_SETUP, + USB_HOST_PIPE_TOKEN_IN, + USB_HOST_PIPE_TOKEN_OUT, +}; + +/** + * \brief Enumeration for the possible callback types for the USB in device module + */ +enum usb_device_callback { + USB_DEVICE_CALLBACK_SOF, + USB_DEVICE_CALLBACK_RESET, + USB_DEVICE_CALLBACK_WAKEUP, + USB_DEVICE_CALLBACK_RAMACER, + USB_DEVICE_CALLBACK_SUSPEND, + USB_DEVICE_CALLBACK_LPMNYET, + USB_DEVICE_CALLBACK_LPMSUSP, + USB_DEVICE_CALLBACK_N, +}; + +/** + * \brief Enumeration for the possible callback types for the USB endpoint in device module + */ +enum usb_device_endpoint_callback { + USB_DEVICE_ENDPOINT_CALLBACK_TRCPT, + USB_DEVICE_ENDPOINT_CALLBACK_TRFAIL, + USB_DEVICE_ENDPOINT_CALLBACK_RXSTP, + USB_DEVICE_ENDPOINT_CALLBACK_STALL, + USB_DEVICE_EP_CALLBACK_N, +}; + +/** + * \brief Device Endpoint types. + */ +enum usb_device_endpoint_type { + USB_DEVICE_ENDPOINT_TYPE_DISABLE, + USB_DEVICE_ENDPOINT_TYPE_CONTROL, + USB_DEVICE_ENDPOINT_TYPE_ISOCHRONOUS, + USB_DEVICE_ENDPOINT_TYPE_BULK, + USB_DEVICE_ENDPOINT_TYPE_INTERRUPT, +}; + +/** + * \brief Endpoint Size + */ +enum usb_endpoint_size { + USB_ENDPOINT_8_BYTE, + USB_ENDPOINT_16_BYTE, + USB_ENDPOINT_32_BYTE, + USB_ENDPOINT_64_BYTE, + USB_ENDPOINT_128_BYTE, + USB_ENDPOINT_256_BYTE, + USB_ENDPOINT_512_BYTE, + USB_ENDPOINT_1023_BYTE, +}; + +/** + * \brief Link Power Management Handshake. + */ +enum usb_device_lpm_mode { + USB_DEVICE_LPM_NOT_SUPPORT, + USB_DEVICE_LPM_ACK, + USB_DEVICE_LPM_NYET, +}; + +/** + * \brief Module structure + */ +struct usb_module; + +/** + * \name Host callback functions types + * @{ + */ +typedef void (*usb_host_callback_t)(struct usb_module *module_inst); +typedef void (*usb_host_pipe_callback_t)(struct usb_module *module_inst, void *); +/** @} */ + +/** + * \name Device callback functions types + * @{ + */ +typedef void (*usb_device_callback_t)(struct usb_module *module_inst, void* pointer); +typedef void (*usb_device_endpoint_callback_t)(struct usb_module *module_inst, void* pointer); +/** @} */ + + +/** USB configurations */ +struct usb_config { + /** \c true for host, \c false for device. */ + bool select_host_mode; + /** When \c true the module is enabled during standby. */ + bool run_in_standby; + /** Generic Clock Generator source channel. */ + enum gclk_generator source_generator; + /** Speed mode */ + enum usb_speed speed_mode; +}; + +/** + * \brief USB software module instance structure. + * + * USB software module instance structure, used to retain software state + * information of an associated hardware module instance. + * + */ +struct usb_module { + /** Hardware module pointer of the associated USB peripheral. */ + Usb *hw; + + /** Array to store host related callback functions */ + usb_host_callback_t host_callback[USB_HOST_CALLBACK_N]; + usb_host_pipe_callback_t host_pipe_callback[USB_PIPE_NUM][USB_HOST_PIPE_CALLBACK_N]; + /** Bit mask for host callbacks registered */ + uint8_t host_registered_callback_mask; + /** Bit mask for host callbacks enabled */ + uint8_t host_enabled_callback_mask; + /** Bit mask for host pipe callbacks registered */ + uint8_t host_pipe_registered_callback_mask[USB_PIPE_NUM]; + /** Bit mask for host pipe callbacks enabled */ + uint8_t host_pipe_enabled_callback_mask[USB_PIPE_NUM]; + + /** Array to store device related callback functions */ + usb_device_callback_t device_callback[USB_DEVICE_CALLBACK_N]; + usb_device_endpoint_callback_t device_endpoint_callback[USB_EPT_NUM][USB_DEVICE_EP_CALLBACK_N]; + /** Bit mask for device callbacks registered */ + uint16_t device_registered_callback_mask; + /** Bit mask for device callbacks enabled */ + uint16_t device_enabled_callback_mask; + /** Bit mask for device endpoint callbacks registered */ + uint8_t deivce_endpoint_registered_callback_mask[USB_EPT_NUM]; + /** Bit mask for device endpoint callbacks enabled */ + uint8_t device_endpoint_enabled_callback_mask[USB_EPT_NUM]; +}; + +/** USB host pipe configurations */ +struct usb_host_pipe_config { + /** device address */ + uint8_t device_address; + /** endpoint address */ + uint8_t endpoint_address; + /** Pipe type */ + enum usb_host_pipe_type pipe_type; + /** interval */ + uint8_t binterval; + /** pipe size */ + uint16_t size; +}; + +/** USB device endpoint configurations */ +struct usb_device_endpoint_config { + /** device address */ + uint8_t ep_address; + /** endpoint size */ + enum usb_endpoint_size ep_size; + /** automatic zero length packet mode, \c true to enable */ + bool auto_zlp; + /** type of endpoint with Bank */ + enum usb_device_endpoint_type ep_type; +}; + +/** USB host pipe callback status parameter structure */ +struct usb_pipe_callback_parameter { + /** current pipe number */ + uint8_t pipe_num; + /** pipe error status */ + uint8_t pipe_error_status; + /** actual transferred data size */ + uint16_t transfered_size; + /** required data size */ + uint16_t required_size; +}; + +/** USB device endpoint callback status parameter structure */ +struct usb_endpoint_callback_parameter { + uint16_t received_bytes; + uint16_t sent_bytes; + uint16_t out_buffer_size; + uint8_t endpoint_address; +}; + +void usb_enable(struct usb_module *module_inst); +void usb_disable(struct usb_module *module_inst); +/** + * \brief Get the status of USB module's state machine + * + * \param module_inst Pointer to USB module instance + */ +static inline uint8_t usb_get_state_machine_status(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + return module_inst->hw->HOST.FSMSTATUS.reg; +} + +void usb_get_config_defaults(struct usb_config *module_config); +enum status_code usb_init(struct usb_module *module_inst, Usb *const hw, + struct usb_config *module_config); + +/** + * \brief Enable the USB host by setting the VBUS OK + * + * \param module_inst Pointer to USB software instance struct + */ +static inline void usb_host_enable(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.CTRLB.bit.VBUSOK = 1; +} + +/** + * \brief Send the USB reset + * + * \param module_inst Pointer to USB software instance struct + */ +static inline void usb_host_send_reset(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.CTRLB.bit.BUSRESET = 1; +} + +/** + * \brief Enable the USB SOF generation + * + * \param module_inst Pointer to USB software instance struct + */ +static inline void usb_host_enable_sof(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.CTRLB.bit.SOFE = 1; +} + +/** + * \brief Disable the USB SOF generation + * + * \param module_inst Pointer to USB software instance struct + */ +static inline void usb_host_disable_sof(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.CTRLB.bit.SOFE = 0; +} + +/** + * \brief Check the USB SOF generation status + * + * \param module_inst Pointer to USB software instance struct + * + * \return USB SOF generation status, \c true if SOF generation is ON. + */ +static inline bool usb_host_is_sof_enabled(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + return module_inst->hw->HOST.CTRLB.bit.SOFE; +} + +/** + * \brief Send the USB host resume + * + * \param module_inst Pointer to USB software instance struct + */ +static inline void usb_host_send_resume(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.CTRLB.bit.RESUME= 1; +} + +/** + * \brief Send the USB host LPM resume + * + * \param module_inst Pointer to USB software instance struct + */ +static inline void usb_host_send_l1_resume(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.CTRLB.bit.L1RESUME = 1; +} + +/** + * \brief Get the speed mode of USB host + * + * \param module_inst Pointer to USB module instance struct + * + * \return USB speed mode (\ref usb_speed) + */ +static inline enum usb_speed usb_host_get_speed(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + if (module_inst->hw->HOST.STATUS.bit.SPEED == 0) { + return USB_SPEED_FULL; + } else { + return USB_SPEED_LOW; + } +} + +/** + * \brief Get the frame number + * + * \param module_inst Pointer to USB software instance struct + * + * \return frame number value + */ +static inline uint16_t usb_host_get_frame_number(struct usb_module *module_inst) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + return (uint16_t)(module_inst->hw->HOST.FNUM.bit.FNUM); +} + +/** + * \brief Attach USB device to the bus + * + * \param module_inst Pointer to USB device module instance + */ +static inline void usb_device_attach(struct usb_module *module_inst) +{ + module_inst->hw->DEVICE.CTRLB.reg &= ~USB_DEVICE_CTRLB_DETACH; +} + +/** + * \brief Detach USB device from the bus + * + * \param module_inst Pointer to USB device module instance + */ +static inline void usb_device_detach(struct usb_module *module_inst) +{ + module_inst->hw->DEVICE.CTRLB.reg |= USB_DEVICE_CTRLB_DETACH; +} + +/** + * \brief Get the speed mode of USB device + * + * \param module_inst Pointer to USB device module instance + * \return USB Speed mode (\ref usb_speed) + */ +static inline enum usb_speed usb_device_get_speed(struct usb_module *module_inst) +{ + if (!(module_inst->hw->DEVICE.STATUS.reg & USB_DEVICE_STATUS_SPEED_Msk)) { + return USB_SPEED_FULL; + } else { + return USB_SPEED_LOW; + } +} + +/** + * \brief Get the address of USB device + * + * \param module_inst Pointer to USB device module instance + * \return USB device address value + */ +static inline uint8_t usb_device_get_address(struct usb_module *module_inst) +{ + return ((uint8_t)(module_inst->hw->DEVICE.DADD.bit.DADD)); +} + +/** + * \brief Set the speed mode of USB device + * + * \param module_inst Pointer to USB device module instance + * \param address USB device address value + */ +static inline void usb_device_set_address(struct usb_module *module_inst, uint8_t address) +{ + module_inst->hw->DEVICE.DADD.reg = USB_DEVICE_DADD_ADDEN | address; +} + +/** + * \brief Get the frame number of USB device + * + * \param module_inst Pointer to USB device module instance + * \return USB device frame number value + */ +static inline uint16_t usb_device_get_frame_number(struct usb_module *module_inst) +{ + return ((uint16_t)(module_inst->hw->DEVICE.FNUM.bit.FNUM)); +} + +/** + * \brief Get the micro-frame number of USB device + * + * \param module_inst Pointer to USB device module instance + * \return USB device micro-frame number value + */ +static inline uint16_t usb_device_get_micro_frame_number(struct usb_module *module_inst) +{ + return ((uint16_t)(module_inst->hw->DEVICE.FNUM.reg)); +} + +/** + * \brief USB device send the resume wakeup + * + * \param module_inst Pointer to USB device module instance + */ +static inline void usb_device_send_remote_wake_up(struct usb_module *module_inst) +{ + module_inst->hw->DEVICE.CTRLB.reg |= USB_DEVICE_CTRLB_UPRSM; +} + +/** + * \brief USB device set the LPM mode + * + * \param module_inst Pointer to USB device module instance + * \param lpm_mode LPM mode + */ +static inline void usb_device_set_lpm_mode(struct usb_module *module_inst, + enum usb_device_lpm_mode lpm_mode) +{ + module_inst->hw->DEVICE.CTRLB.bit.LPMHDSK = lpm_mode; +} + +/** + * \name USB Host Callback management + * @{ + */ +enum status_code usb_host_register_callback(struct usb_module *module_inst, + enum usb_host_callback callback_type, + usb_host_callback_t callback_func); +enum status_code usb_host_unregister_callback(struct usb_module *module_inst, + enum usb_host_callback callback_type); +enum status_code usb_host_enable_callback(struct usb_module *module_inst, + enum usb_host_callback callback_type); +enum status_code usb_host_disable_callback(struct usb_module *module_inst, + enum usb_host_callback callback_type); +/** @} */ + +/** + * \name USB Device Callback management + * @{ + */ +enum status_code usb_device_register_callback(struct usb_module *module_inst, + enum usb_device_callback callback_type, + usb_device_callback_t callback_func); +enum status_code usb_device_unregister_callback(struct usb_module *module_inst, + enum usb_device_callback callback_type); +enum status_code usb_device_enable_callback(struct usb_module *module_inst, + enum usb_device_callback callback_type); +enum status_code usb_device_disable_callback(struct usb_module *module_inst, + enum usb_device_callback callback_type); +/** @} */ + +/** + * \name USB Host Pipe configuration + * @{ + */ +void usb_host_pipe_get_config_defaults(struct usb_host_pipe_config *ep_config); +enum status_code usb_host_pipe_set_config(struct usb_module *module_inst, uint8_t pipe_num, + struct usb_host_pipe_config *ep_config); +enum status_code usb_host_pipe_get_config(struct usb_module *module_inst, uint8_t pipe_num, + struct usb_host_pipe_config *ep_config); +/** @} */ + +/** + * \name USB Device Endpoint Configuration + * @{ + */ +void usb_device_endpoint_get_config_defaults(struct usb_device_endpoint_config *ep_config); +enum status_code usb_device_endpoint_set_config(struct usb_module *module_inst, + struct usb_device_endpoint_config *ep_config); +bool usb_device_endpoint_is_configured(struct usb_module *module_inst, uint8_t ep); +/** @} */ + +/** + * \name USB Host Pipe Callback management + * @{ + */ +enum status_code usb_host_pipe_register_callback( + struct usb_module *module_inst, uint8_t pipe_num, + enum usb_host_pipe_callback callback_type, + usb_host_pipe_callback_t callback_func); +enum status_code usb_host_pipe_unregister_callback( + struct usb_module *module_inst, uint8_t pipe_num, + enum usb_host_pipe_callback callback_type); +enum status_code usb_host_pipe_enable_callback( + struct usb_module *module_inst, uint8_t pipe_num, + enum usb_host_pipe_callback callback_type); +enum status_code usb_host_pipe_disable_callback( + struct usb_module *module_inst, uint8_t pipe_num, + enum usb_host_pipe_callback callback_type); +/** @} */ + +/** + * \name USB Device Endpoint Callback management + * @{ + */ +enum status_code usb_device_endpoint_register_callback( + struct usb_module *module_inst, uint8_t ep_num, + enum usb_device_endpoint_callback callback_type, + usb_device_endpoint_callback_t callback_func); +enum status_code usb_device_endpoint_unregister_callback( + struct usb_module *module_inst, uint8_t ep_num, + enum usb_device_endpoint_callback callback_type); +enum status_code usb_device_endpoint_enable_callback( + struct usb_module *module_inst, uint8_t ep, + enum usb_device_endpoint_callback callback_type); +enum status_code usb_device_endpoint_disable_callback( + struct usb_module *module_inst, uint8_t ep, + enum usb_device_endpoint_callback callback_type); +/** @} */ + +/** + * \name USB Host Pipe Job management + * @{ + */ +enum status_code usb_host_pipe_setup_job(struct usb_module *module_inst, + uint8_t pipe_num, uint8_t *buf); +enum status_code usb_host_pipe_read_job(struct usb_module *module_inst, + uint8_t pipe_num, uint8_t *buf, uint32_t buf_size); +enum status_code usb_host_pipe_write_job(struct usb_module *module_inst, + uint8_t pipe_num, uint8_t *buf, uint32_t buf_size); +enum status_code usb_host_pipe_abort_job(struct usb_module *module_inst, uint8_t pipe_num); +enum status_code usb_host_pipe_lpm_job(struct usb_module *module_inst, + uint8_t pipe_num, bool b_remotewakeup, uint8_t besl); +/** @} */ + +/** + * \name USB Device Endpoint Job management + * @{ + */ +enum status_code usb_device_endpoint_write_buffer_job(struct usb_module *module_inst,uint8_t ep_num, + uint8_t* pbuf, uint32_t buf_size); +enum status_code usb_device_endpoint_read_buffer_job(struct usb_module *module_inst,uint8_t ep_num, + uint8_t* pbuf, uint32_t buf_size); +enum status_code usb_device_endpoint_setup_buffer_job(struct usb_module *module_inst, + uint8_t* pbuf); +void usb_device_endpoint_abort_job(struct usb_module *module_inst, uint8_t ep); +/** @} */ + +/** + * \name USB Host Pipe Operations + * @{ + */ + +/** + * \brief Freeze a pipe + * + * \param module_inst Pointer to USB module instance + * \param pipe_num Pipe number + */ +static inline void usb_host_pipe_freeze(struct usb_module *module_inst, uint8_t pipe_num) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSSET.reg = USB_HOST_PSTATUSSET_PFREEZE; +} + +/** + * \brief Unfreeze a pipe + * + * \param module_inst Pointer to USB module instance + * \param pipe_num Pipe number + */ +static inline void usb_host_pipe_unfreeze(struct usb_module *module_inst, uint8_t pipe_num) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSCLR.reg = USB_HOST_PSTATUSCLR_PFREEZE; +} + +/** + * \brief Check if the pipe is frozen + * + * \param module_inst Pointer to USB module instance + * \param pipe_num Pipe number + */ +static inline bool usb_host_pipe_is_frozen(struct usb_module *module_inst, uint8_t pipe_num) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + return (module_inst->hw->HOST.HostPipe[pipe_num].PSTATUS.bit.PFREEZE == 1); +} + +/** + * \brief Set the data toggle bit of pipe + * + * \param module_inst Pointer to USB module instance + * \param pipe_num Pipe number + */ +static inline void usb_host_pipe_set_toggle(struct usb_module *module_inst, uint8_t pipe_num) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSSET.reg = USB_HOST_PSTATUSSET_DTGL; +} + +/** + * \brief Clear the data toggle bit of pipe + * + * \param module_inst Pointer to USB module instance + * \param pipe_num Pipe number + */ +static inline void usb_host_pipe_clear_toggle(struct usb_module *module_inst, uint8_t pipe_num) +{ + /* Sanity check arguments */ + Assert(module_inst); + Assert(module_inst->hw); + + module_inst->hw->HOST.HostPipe[pipe_num].PSTATUSCLR.reg = USB_HOST_PSTATUSCLR_DTGL; +} + +/** + * \brief Set the auto zero length packet of pipe + * + * \param module_inst Pointer to USB module instance + * \param pipe_num Pipe number + * \param value \c true to enable auto ZLP and \c false to disable + */ +void usb_host_pipe_set_auto_zlp(struct usb_module *module_inst, uint8_t pipe_num, bool value); + +/** @} */ + +/** + * \name USB Device Endpoint Operations + * @{ + */ + +bool usb_device_endpoint_is_halted(struct usb_module *module_inst, uint8_t ep); +void usb_device_endpoint_set_halt(struct usb_module *module_inst, uint8_t ep); +void usb_device_endpoint_clear_halt(struct usb_module *module_inst, uint8_t ep); + +/** @} */ + +#ifdef __cplusplus +} +#endif + +#endif /* USB_H_INCLUDED */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/ac.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/ac.h new file mode 100755 index 0000000..6a19024 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/ac.h @@ -0,0 +1,559 @@ +/** + * \file + * + * \brief Component description for AC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_AC_COMPONENT_ +#define _SAMD21_AC_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR AC */ +/* ========================================================================== */ +/** \addtogroup SAMD21_AC Analog Comparators */ +/*@{*/ + +#define AC_U2205 +#define REV_AC 0x111 + +/* -------- AC_CTRLA : (AC Offset: 0x00) (R/W 8) Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset */ + uint8_t ENABLE:1; /*!< bit: 1 Enable */ + uint8_t RUNSTDBY:1; /*!< bit: 2 Run in Standby */ + uint8_t :4; /*!< bit: 3.. 6 Reserved */ + uint8_t LPMUX:1; /*!< bit: 7 Low-Power Mux */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} AC_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_CTRLA_OFFSET 0x00 /**< \brief (AC_CTRLA offset) Control A */ +#define AC_CTRLA_RESETVALUE 0x00 /**< \brief (AC_CTRLA reset_value) Control A */ + +#define AC_CTRLA_SWRST_Pos 0 /**< \brief (AC_CTRLA) Software Reset */ +#define AC_CTRLA_SWRST (0x1u << AC_CTRLA_SWRST_Pos) +#define AC_CTRLA_ENABLE_Pos 1 /**< \brief (AC_CTRLA) Enable */ +#define AC_CTRLA_ENABLE (0x1u << AC_CTRLA_ENABLE_Pos) +#define AC_CTRLA_RUNSTDBY_Pos 2 /**< \brief (AC_CTRLA) Run in Standby */ +#define AC_CTRLA_RUNSTDBY_Msk (0x1u << AC_CTRLA_RUNSTDBY_Pos) +#define AC_CTRLA_RUNSTDBY(value) ((AC_CTRLA_RUNSTDBY_Msk & ((value) << AC_CTRLA_RUNSTDBY_Pos))) +#define AC_CTRLA_LPMUX_Pos 7 /**< \brief (AC_CTRLA) Low-Power Mux */ +#define AC_CTRLA_LPMUX (0x1u << AC_CTRLA_LPMUX_Pos) +#define AC_CTRLA_MASK 0x87u /**< \brief (AC_CTRLA) MASK Register */ + +/* -------- AC_CTRLB : (AC Offset: 0x01) ( /W 8) Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t START0:1; /*!< bit: 0 Comparator 0 Start Comparison */ + uint8_t START1:1; /*!< bit: 1 Comparator 1 Start Comparison */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t START:2; /*!< bit: 0.. 1 Comparator x Start Comparison */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} AC_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_CTRLB_OFFSET 0x01 /**< \brief (AC_CTRLB offset) Control B */ +#define AC_CTRLB_RESETVALUE 0x00 /**< \brief (AC_CTRLB reset_value) Control B */ + +#define AC_CTRLB_START0_Pos 0 /**< \brief (AC_CTRLB) Comparator 0 Start Comparison */ +#define AC_CTRLB_START0 (1 << AC_CTRLB_START0_Pos) +#define AC_CTRLB_START1_Pos 1 /**< \brief (AC_CTRLB) Comparator 1 Start Comparison */ +#define AC_CTRLB_START1 (1 << AC_CTRLB_START1_Pos) +#define AC_CTRLB_START_Pos 0 /**< \brief (AC_CTRLB) Comparator x Start Comparison */ +#define AC_CTRLB_START_Msk (0x3u << AC_CTRLB_START_Pos) +#define AC_CTRLB_START(value) ((AC_CTRLB_START_Msk & ((value) << AC_CTRLB_START_Pos))) +#define AC_CTRLB_MASK 0x03u /**< \brief (AC_CTRLB) MASK Register */ + +/* -------- AC_EVCTRL : (AC Offset: 0x02) (R/W 16) Event Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t COMPEO0:1; /*!< bit: 0 Comparator 0 Event Output Enable */ + uint16_t COMPEO1:1; /*!< bit: 1 Comparator 1 Event Output Enable */ + uint16_t :2; /*!< bit: 2.. 3 Reserved */ + uint16_t WINEO0:1; /*!< bit: 4 Window 0 Event Output Enable */ + uint16_t :3; /*!< bit: 5.. 7 Reserved */ + uint16_t COMPEI0:1; /*!< bit: 8 Comparator 0 Event Input */ + uint16_t COMPEI1:1; /*!< bit: 9 Comparator 1 Event Input */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t COMPEO:2; /*!< bit: 0.. 1 Comparator x Event Output Enable */ + uint16_t :2; /*!< bit: 2.. 3 Reserved */ + uint16_t WINEO:1; /*!< bit: 4 Window x Event Output Enable */ + uint16_t :3; /*!< bit: 5.. 7 Reserved */ + uint16_t COMPEI:2; /*!< bit: 8.. 9 Comparator x Event Input */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} AC_EVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_EVCTRL_OFFSET 0x02 /**< \brief (AC_EVCTRL offset) Event Control */ +#define AC_EVCTRL_RESETVALUE 0x0000 /**< \brief (AC_EVCTRL reset_value) Event Control */ + +#define AC_EVCTRL_COMPEO0_Pos 0 /**< \brief (AC_EVCTRL) Comparator 0 Event Output Enable */ +#define AC_EVCTRL_COMPEO0 (1 << AC_EVCTRL_COMPEO0_Pos) +#define AC_EVCTRL_COMPEO1_Pos 1 /**< \brief (AC_EVCTRL) Comparator 1 Event Output Enable */ +#define AC_EVCTRL_COMPEO1 (1 << AC_EVCTRL_COMPEO1_Pos) +#define AC_EVCTRL_COMPEO_Pos 0 /**< \brief (AC_EVCTRL) Comparator x Event Output Enable */ +#define AC_EVCTRL_COMPEO_Msk (0x3u << AC_EVCTRL_COMPEO_Pos) +#define AC_EVCTRL_COMPEO(value) ((AC_EVCTRL_COMPEO_Msk & ((value) << AC_EVCTRL_COMPEO_Pos))) +#define AC_EVCTRL_WINEO0_Pos 4 /**< \brief (AC_EVCTRL) Window 0 Event Output Enable */ +#define AC_EVCTRL_WINEO0 (1 << AC_EVCTRL_WINEO0_Pos) +#define AC_EVCTRL_WINEO_Pos 4 /**< \brief (AC_EVCTRL) Window x Event Output Enable */ +#define AC_EVCTRL_WINEO_Msk (0x1u << AC_EVCTRL_WINEO_Pos) +#define AC_EVCTRL_WINEO(value) ((AC_EVCTRL_WINEO_Msk & ((value) << AC_EVCTRL_WINEO_Pos))) +#define AC_EVCTRL_COMPEI0_Pos 8 /**< \brief (AC_EVCTRL) Comparator 0 Event Input */ +#define AC_EVCTRL_COMPEI0 (1 << AC_EVCTRL_COMPEI0_Pos) +#define AC_EVCTRL_COMPEI1_Pos 9 /**< \brief (AC_EVCTRL) Comparator 1 Event Input */ +#define AC_EVCTRL_COMPEI1 (1 << AC_EVCTRL_COMPEI1_Pos) +#define AC_EVCTRL_COMPEI_Pos 8 /**< \brief (AC_EVCTRL) Comparator x Event Input */ +#define AC_EVCTRL_COMPEI_Msk (0x3u << AC_EVCTRL_COMPEI_Pos) +#define AC_EVCTRL_COMPEI(value) ((AC_EVCTRL_COMPEI_Msk & ((value) << AC_EVCTRL_COMPEI_Pos))) +#define AC_EVCTRL_MASK 0x0313u /**< \brief (AC_EVCTRL) MASK Register */ + +/* -------- AC_INTENCLR : (AC Offset: 0x04) (R/W 8) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t COMP0:1; /*!< bit: 0 Comparator 0 Interrupt Enable */ + uint8_t COMP1:1; /*!< bit: 1 Comparator 1 Interrupt Enable */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t WIN0:1; /*!< bit: 4 Window 0 Interrupt Enable */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t COMP:2; /*!< bit: 0.. 1 Comparator x Interrupt Enable */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t WIN:1; /*!< bit: 4 Window x Interrupt Enable */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} AC_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_INTENCLR_OFFSET 0x04 /**< \brief (AC_INTENCLR offset) Interrupt Enable Clear */ +#define AC_INTENCLR_RESETVALUE 0x00 /**< \brief (AC_INTENCLR reset_value) Interrupt Enable Clear */ + +#define AC_INTENCLR_COMP0_Pos 0 /**< \brief (AC_INTENCLR) Comparator 0 Interrupt Enable */ +#define AC_INTENCLR_COMP0 (1 << AC_INTENCLR_COMP0_Pos) +#define AC_INTENCLR_COMP1_Pos 1 /**< \brief (AC_INTENCLR) Comparator 1 Interrupt Enable */ +#define AC_INTENCLR_COMP1 (1 << AC_INTENCLR_COMP1_Pos) +#define AC_INTENCLR_COMP_Pos 0 /**< \brief (AC_INTENCLR) Comparator x Interrupt Enable */ +#define AC_INTENCLR_COMP_Msk (0x3u << AC_INTENCLR_COMP_Pos) +#define AC_INTENCLR_COMP(value) ((AC_INTENCLR_COMP_Msk & ((value) << AC_INTENCLR_COMP_Pos))) +#define AC_INTENCLR_WIN0_Pos 4 /**< \brief (AC_INTENCLR) Window 0 Interrupt Enable */ +#define AC_INTENCLR_WIN0 (1 << AC_INTENCLR_WIN0_Pos) +#define AC_INTENCLR_WIN_Pos 4 /**< \brief (AC_INTENCLR) Window x Interrupt Enable */ +#define AC_INTENCLR_WIN_Msk (0x1u << AC_INTENCLR_WIN_Pos) +#define AC_INTENCLR_WIN(value) ((AC_INTENCLR_WIN_Msk & ((value) << AC_INTENCLR_WIN_Pos))) +#define AC_INTENCLR_MASK 0x13u /**< \brief (AC_INTENCLR) MASK Register */ + +/* -------- AC_INTENSET : (AC Offset: 0x05) (R/W 8) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t COMP0:1; /*!< bit: 0 Comparator 0 Interrupt Enable */ + uint8_t COMP1:1; /*!< bit: 1 Comparator 1 Interrupt Enable */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t WIN0:1; /*!< bit: 4 Window 0 Interrupt Enable */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t COMP:2; /*!< bit: 0.. 1 Comparator x Interrupt Enable */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t WIN:1; /*!< bit: 4 Window x Interrupt Enable */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} AC_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_INTENSET_OFFSET 0x05 /**< \brief (AC_INTENSET offset) Interrupt Enable Set */ +#define AC_INTENSET_RESETVALUE 0x00 /**< \brief (AC_INTENSET reset_value) Interrupt Enable Set */ + +#define AC_INTENSET_COMP0_Pos 0 /**< \brief (AC_INTENSET) Comparator 0 Interrupt Enable */ +#define AC_INTENSET_COMP0 (1 << AC_INTENSET_COMP0_Pos) +#define AC_INTENSET_COMP1_Pos 1 /**< \brief (AC_INTENSET) Comparator 1 Interrupt Enable */ +#define AC_INTENSET_COMP1 (1 << AC_INTENSET_COMP1_Pos) +#define AC_INTENSET_COMP_Pos 0 /**< \brief (AC_INTENSET) Comparator x Interrupt Enable */ +#define AC_INTENSET_COMP_Msk (0x3u << AC_INTENSET_COMP_Pos) +#define AC_INTENSET_COMP(value) ((AC_INTENSET_COMP_Msk & ((value) << AC_INTENSET_COMP_Pos))) +#define AC_INTENSET_WIN0_Pos 4 /**< \brief (AC_INTENSET) Window 0 Interrupt Enable */ +#define AC_INTENSET_WIN0 (1 << AC_INTENSET_WIN0_Pos) +#define AC_INTENSET_WIN_Pos 4 /**< \brief (AC_INTENSET) Window x Interrupt Enable */ +#define AC_INTENSET_WIN_Msk (0x1u << AC_INTENSET_WIN_Pos) +#define AC_INTENSET_WIN(value) ((AC_INTENSET_WIN_Msk & ((value) << AC_INTENSET_WIN_Pos))) +#define AC_INTENSET_MASK 0x13u /**< \brief (AC_INTENSET) MASK Register */ + +/* -------- AC_INTFLAG : (AC Offset: 0x06) (R/W 8) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t COMP0:1; /*!< bit: 0 Comparator 0 */ + uint8_t COMP1:1; /*!< bit: 1 Comparator 1 */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t WIN0:1; /*!< bit: 4 Window 0 */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t COMP:2; /*!< bit: 0.. 1 Comparator x */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t WIN:1; /*!< bit: 4 Window x */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} AC_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_INTFLAG_OFFSET 0x06 /**< \brief (AC_INTFLAG offset) Interrupt Flag Status and Clear */ +#define AC_INTFLAG_RESETVALUE 0x00 /**< \brief (AC_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define AC_INTFLAG_COMP0_Pos 0 /**< \brief (AC_INTFLAG) Comparator 0 */ +#define AC_INTFLAG_COMP0 (1 << AC_INTFLAG_COMP0_Pos) +#define AC_INTFLAG_COMP1_Pos 1 /**< \brief (AC_INTFLAG) Comparator 1 */ +#define AC_INTFLAG_COMP1 (1 << AC_INTFLAG_COMP1_Pos) +#define AC_INTFLAG_COMP_Pos 0 /**< \brief (AC_INTFLAG) Comparator x */ +#define AC_INTFLAG_COMP_Msk (0x3u << AC_INTFLAG_COMP_Pos) +#define AC_INTFLAG_COMP(value) ((AC_INTFLAG_COMP_Msk & ((value) << AC_INTFLAG_COMP_Pos))) +#define AC_INTFLAG_WIN0_Pos 4 /**< \brief (AC_INTFLAG) Window 0 */ +#define AC_INTFLAG_WIN0 (1 << AC_INTFLAG_WIN0_Pos) +#define AC_INTFLAG_WIN_Pos 4 /**< \brief (AC_INTFLAG) Window x */ +#define AC_INTFLAG_WIN_Msk (0x1u << AC_INTFLAG_WIN_Pos) +#define AC_INTFLAG_WIN(value) ((AC_INTFLAG_WIN_Msk & ((value) << AC_INTFLAG_WIN_Pos))) +#define AC_INTFLAG_MASK 0x13u /**< \brief (AC_INTFLAG) MASK Register */ + +/* -------- AC_STATUSA : (AC Offset: 0x08) (R/ 8) Status A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t STATE0:1; /*!< bit: 0 Comparator 0 Current State */ + uint8_t STATE1:1; /*!< bit: 1 Comparator 1 Current State */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t WSTATE0:2; /*!< bit: 4.. 5 Window 0 Current State */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t STATE:2; /*!< bit: 0.. 1 Comparator x Current State */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} AC_STATUSA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_STATUSA_OFFSET 0x08 /**< \brief (AC_STATUSA offset) Status A */ +#define AC_STATUSA_RESETVALUE 0x00 /**< \brief (AC_STATUSA reset_value) Status A */ + +#define AC_STATUSA_STATE0_Pos 0 /**< \brief (AC_STATUSA) Comparator 0 Current State */ +#define AC_STATUSA_STATE0 (1 << AC_STATUSA_STATE0_Pos) +#define AC_STATUSA_STATE1_Pos 1 /**< \brief (AC_STATUSA) Comparator 1 Current State */ +#define AC_STATUSA_STATE1 (1 << AC_STATUSA_STATE1_Pos) +#define AC_STATUSA_STATE_Pos 0 /**< \brief (AC_STATUSA) Comparator x Current State */ +#define AC_STATUSA_STATE_Msk (0x3u << AC_STATUSA_STATE_Pos) +#define AC_STATUSA_STATE(value) ((AC_STATUSA_STATE_Msk & ((value) << AC_STATUSA_STATE_Pos))) +#define AC_STATUSA_WSTATE0_Pos 4 /**< \brief (AC_STATUSA) Window 0 Current State */ +#define AC_STATUSA_WSTATE0_Msk (0x3u << AC_STATUSA_WSTATE0_Pos) +#define AC_STATUSA_WSTATE0(value) ((AC_STATUSA_WSTATE0_Msk & ((value) << AC_STATUSA_WSTATE0_Pos))) +#define AC_STATUSA_WSTATE0_ABOVE_Val 0x0u /**< \brief (AC_STATUSA) Signal is above window */ +#define AC_STATUSA_WSTATE0_INSIDE_Val 0x1u /**< \brief (AC_STATUSA) Signal is inside window */ +#define AC_STATUSA_WSTATE0_BELOW_Val 0x2u /**< \brief (AC_STATUSA) Signal is below window */ +#define AC_STATUSA_WSTATE0_ABOVE (AC_STATUSA_WSTATE0_ABOVE_Val << AC_STATUSA_WSTATE0_Pos) +#define AC_STATUSA_WSTATE0_INSIDE (AC_STATUSA_WSTATE0_INSIDE_Val << AC_STATUSA_WSTATE0_Pos) +#define AC_STATUSA_WSTATE0_BELOW (AC_STATUSA_WSTATE0_BELOW_Val << AC_STATUSA_WSTATE0_Pos) +#define AC_STATUSA_MASK 0x33u /**< \brief (AC_STATUSA) MASK Register */ + +/* -------- AC_STATUSB : (AC Offset: 0x09) (R/ 8) Status B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t READY0:1; /*!< bit: 0 Comparator 0 Ready */ + uint8_t READY1:1; /*!< bit: 1 Comparator 1 Ready */ + uint8_t :5; /*!< bit: 2.. 6 Reserved */ + uint8_t SYNCBUSY:1; /*!< bit: 7 Synchronization Busy */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t READY:2; /*!< bit: 0.. 1 Comparator x Ready */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} AC_STATUSB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_STATUSB_OFFSET 0x09 /**< \brief (AC_STATUSB offset) Status B */ +#define AC_STATUSB_RESETVALUE 0x00 /**< \brief (AC_STATUSB reset_value) Status B */ + +#define AC_STATUSB_READY0_Pos 0 /**< \brief (AC_STATUSB) Comparator 0 Ready */ +#define AC_STATUSB_READY0 (1 << AC_STATUSB_READY0_Pos) +#define AC_STATUSB_READY1_Pos 1 /**< \brief (AC_STATUSB) Comparator 1 Ready */ +#define AC_STATUSB_READY1 (1 << AC_STATUSB_READY1_Pos) +#define AC_STATUSB_READY_Pos 0 /**< \brief (AC_STATUSB) Comparator x Ready */ +#define AC_STATUSB_READY_Msk (0x3u << AC_STATUSB_READY_Pos) +#define AC_STATUSB_READY(value) ((AC_STATUSB_READY_Msk & ((value) << AC_STATUSB_READY_Pos))) +#define AC_STATUSB_SYNCBUSY_Pos 7 /**< \brief (AC_STATUSB) Synchronization Busy */ +#define AC_STATUSB_SYNCBUSY (0x1u << AC_STATUSB_SYNCBUSY_Pos) +#define AC_STATUSB_MASK 0x83u /**< \brief (AC_STATUSB) MASK Register */ + +/* -------- AC_STATUSC : (AC Offset: 0x0A) (R/ 8) Status C -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t STATE0:1; /*!< bit: 0 Comparator 0 Current State */ + uint8_t STATE1:1; /*!< bit: 1 Comparator 1 Current State */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t WSTATE0:2; /*!< bit: 4.. 5 Window 0 Current State */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t STATE:2; /*!< bit: 0.. 1 Comparator x Current State */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} AC_STATUSC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_STATUSC_OFFSET 0x0A /**< \brief (AC_STATUSC offset) Status C */ +#define AC_STATUSC_RESETVALUE 0x00 /**< \brief (AC_STATUSC reset_value) Status C */ + +#define AC_STATUSC_STATE0_Pos 0 /**< \brief (AC_STATUSC) Comparator 0 Current State */ +#define AC_STATUSC_STATE0 (1 << AC_STATUSC_STATE0_Pos) +#define AC_STATUSC_STATE1_Pos 1 /**< \brief (AC_STATUSC) Comparator 1 Current State */ +#define AC_STATUSC_STATE1 (1 << AC_STATUSC_STATE1_Pos) +#define AC_STATUSC_STATE_Pos 0 /**< \brief (AC_STATUSC) Comparator x Current State */ +#define AC_STATUSC_STATE_Msk (0x3u << AC_STATUSC_STATE_Pos) +#define AC_STATUSC_STATE(value) ((AC_STATUSC_STATE_Msk & ((value) << AC_STATUSC_STATE_Pos))) +#define AC_STATUSC_WSTATE0_Pos 4 /**< \brief (AC_STATUSC) Window 0 Current State */ +#define AC_STATUSC_WSTATE0_Msk (0x3u << AC_STATUSC_WSTATE0_Pos) +#define AC_STATUSC_WSTATE0(value) ((AC_STATUSC_WSTATE0_Msk & ((value) << AC_STATUSC_WSTATE0_Pos))) +#define AC_STATUSC_WSTATE0_ABOVE_Val 0x0u /**< \brief (AC_STATUSC) Signal is above window */ +#define AC_STATUSC_WSTATE0_INSIDE_Val 0x1u /**< \brief (AC_STATUSC) Signal is inside window */ +#define AC_STATUSC_WSTATE0_BELOW_Val 0x2u /**< \brief (AC_STATUSC) Signal is below window */ +#define AC_STATUSC_WSTATE0_ABOVE (AC_STATUSC_WSTATE0_ABOVE_Val << AC_STATUSC_WSTATE0_Pos) +#define AC_STATUSC_WSTATE0_INSIDE (AC_STATUSC_WSTATE0_INSIDE_Val << AC_STATUSC_WSTATE0_Pos) +#define AC_STATUSC_WSTATE0_BELOW (AC_STATUSC_WSTATE0_BELOW_Val << AC_STATUSC_WSTATE0_Pos) +#define AC_STATUSC_MASK 0x33u /**< \brief (AC_STATUSC) MASK Register */ + +/* -------- AC_WINCTRL : (AC Offset: 0x0C) (R/W 8) Window Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t WEN0:1; /*!< bit: 0 Window 0 Mode Enable */ + uint8_t WINTSEL0:2; /*!< bit: 1.. 2 Window 0 Interrupt Selection */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} AC_WINCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_WINCTRL_OFFSET 0x0C /**< \brief (AC_WINCTRL offset) Window Control */ +#define AC_WINCTRL_RESETVALUE 0x00 /**< \brief (AC_WINCTRL reset_value) Window Control */ + +#define AC_WINCTRL_WEN0_Pos 0 /**< \brief (AC_WINCTRL) Window 0 Mode Enable */ +#define AC_WINCTRL_WEN0 (0x1u << AC_WINCTRL_WEN0_Pos) +#define AC_WINCTRL_WINTSEL0_Pos 1 /**< \brief (AC_WINCTRL) Window 0 Interrupt Selection */ +#define AC_WINCTRL_WINTSEL0_Msk (0x3u << AC_WINCTRL_WINTSEL0_Pos) +#define AC_WINCTRL_WINTSEL0(value) ((AC_WINCTRL_WINTSEL0_Msk & ((value) << AC_WINCTRL_WINTSEL0_Pos))) +#define AC_WINCTRL_WINTSEL0_ABOVE_Val 0x0u /**< \brief (AC_WINCTRL) Interrupt on signal above window */ +#define AC_WINCTRL_WINTSEL0_INSIDE_Val 0x1u /**< \brief (AC_WINCTRL) Interrupt on signal inside window */ +#define AC_WINCTRL_WINTSEL0_BELOW_Val 0x2u /**< \brief (AC_WINCTRL) Interrupt on signal below window */ +#define AC_WINCTRL_WINTSEL0_OUTSIDE_Val 0x3u /**< \brief (AC_WINCTRL) Interrupt on signal outside window */ +#define AC_WINCTRL_WINTSEL0_ABOVE (AC_WINCTRL_WINTSEL0_ABOVE_Val << AC_WINCTRL_WINTSEL0_Pos) +#define AC_WINCTRL_WINTSEL0_INSIDE (AC_WINCTRL_WINTSEL0_INSIDE_Val << AC_WINCTRL_WINTSEL0_Pos) +#define AC_WINCTRL_WINTSEL0_BELOW (AC_WINCTRL_WINTSEL0_BELOW_Val << AC_WINCTRL_WINTSEL0_Pos) +#define AC_WINCTRL_WINTSEL0_OUTSIDE (AC_WINCTRL_WINTSEL0_OUTSIDE_Val << AC_WINCTRL_WINTSEL0_Pos) +#define AC_WINCTRL_MASK 0x07u /**< \brief (AC_WINCTRL) MASK Register */ + +/* -------- AC_COMPCTRL : (AC Offset: 0x10) (R/W 32) Comparator Control n -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t ENABLE:1; /*!< bit: 0 Enable */ + uint32_t SINGLE:1; /*!< bit: 1 Single-Shot Mode */ + uint32_t SPEED:2; /*!< bit: 2.. 3 Speed Selection */ + uint32_t :1; /*!< bit: 4 Reserved */ + uint32_t INTSEL:2; /*!< bit: 5.. 6 Interrupt Selection */ + uint32_t :1; /*!< bit: 7 Reserved */ + uint32_t MUXNEG:3; /*!< bit: 8..10 Negative Input Mux Selection */ + uint32_t :1; /*!< bit: 11 Reserved */ + uint32_t MUXPOS:2; /*!< bit: 12..13 Positive Input Mux Selection */ + uint32_t :1; /*!< bit: 14 Reserved */ + uint32_t SWAP:1; /*!< bit: 15 Swap Inputs and Invert */ + uint32_t OUT:2; /*!< bit: 16..17 Output */ + uint32_t :1; /*!< bit: 18 Reserved */ + uint32_t HYST:1; /*!< bit: 19 Hysteresis Enable */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t FLEN:3; /*!< bit: 24..26 Filter Length */ + uint32_t :5; /*!< bit: 27..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} AC_COMPCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_COMPCTRL_OFFSET 0x10 /**< \brief (AC_COMPCTRL offset) Comparator Control n */ +#define AC_COMPCTRL_RESETVALUE 0x00000000 /**< \brief (AC_COMPCTRL reset_value) Comparator Control n */ + +#define AC_COMPCTRL_ENABLE_Pos 0 /**< \brief (AC_COMPCTRL) Enable */ +#define AC_COMPCTRL_ENABLE (0x1u << AC_COMPCTRL_ENABLE_Pos) +#define AC_COMPCTRL_SINGLE_Pos 1 /**< \brief (AC_COMPCTRL) Single-Shot Mode */ +#define AC_COMPCTRL_SINGLE (0x1u << AC_COMPCTRL_SINGLE_Pos) +#define AC_COMPCTRL_SPEED_Pos 2 /**< \brief (AC_COMPCTRL) Speed Selection */ +#define AC_COMPCTRL_SPEED_Msk (0x3u << AC_COMPCTRL_SPEED_Pos) +#define AC_COMPCTRL_SPEED(value) ((AC_COMPCTRL_SPEED_Msk & ((value) << AC_COMPCTRL_SPEED_Pos))) +#define AC_COMPCTRL_SPEED_LOW_Val 0x0u /**< \brief (AC_COMPCTRL) Low speed */ +#define AC_COMPCTRL_SPEED_HIGH_Val 0x1u /**< \brief (AC_COMPCTRL) High speed */ +#define AC_COMPCTRL_SPEED_LOW (AC_COMPCTRL_SPEED_LOW_Val << AC_COMPCTRL_SPEED_Pos) +#define AC_COMPCTRL_SPEED_HIGH (AC_COMPCTRL_SPEED_HIGH_Val << AC_COMPCTRL_SPEED_Pos) +#define AC_COMPCTRL_INTSEL_Pos 5 /**< \brief (AC_COMPCTRL) Interrupt Selection */ +#define AC_COMPCTRL_INTSEL_Msk (0x3u << AC_COMPCTRL_INTSEL_Pos) +#define AC_COMPCTRL_INTSEL(value) ((AC_COMPCTRL_INTSEL_Msk & ((value) << AC_COMPCTRL_INTSEL_Pos))) +#define AC_COMPCTRL_INTSEL_TOGGLE_Val 0x0u /**< \brief (AC_COMPCTRL) Interrupt on comparator output toggle */ +#define AC_COMPCTRL_INTSEL_RISING_Val 0x1u /**< \brief (AC_COMPCTRL) Interrupt on comparator output rising */ +#define AC_COMPCTRL_INTSEL_FALLING_Val 0x2u /**< \brief (AC_COMPCTRL) Interrupt on comparator output falling */ +#define AC_COMPCTRL_INTSEL_EOC_Val 0x3u /**< \brief (AC_COMPCTRL) Interrupt on end of comparison (single-shot mode only) */ +#define AC_COMPCTRL_INTSEL_TOGGLE (AC_COMPCTRL_INTSEL_TOGGLE_Val << AC_COMPCTRL_INTSEL_Pos) +#define AC_COMPCTRL_INTSEL_RISING (AC_COMPCTRL_INTSEL_RISING_Val << AC_COMPCTRL_INTSEL_Pos) +#define AC_COMPCTRL_INTSEL_FALLING (AC_COMPCTRL_INTSEL_FALLING_Val << AC_COMPCTRL_INTSEL_Pos) +#define AC_COMPCTRL_INTSEL_EOC (AC_COMPCTRL_INTSEL_EOC_Val << AC_COMPCTRL_INTSEL_Pos) +#define AC_COMPCTRL_MUXNEG_Pos 8 /**< \brief (AC_COMPCTRL) Negative Input Mux Selection */ +#define AC_COMPCTRL_MUXNEG_Msk (0x7u << AC_COMPCTRL_MUXNEG_Pos) +#define AC_COMPCTRL_MUXNEG(value) ((AC_COMPCTRL_MUXNEG_Msk & ((value) << AC_COMPCTRL_MUXNEG_Pos))) +#define AC_COMPCTRL_MUXNEG_PIN0_Val 0x0u /**< \brief (AC_COMPCTRL) I/O pin 0 */ +#define AC_COMPCTRL_MUXNEG_PIN1_Val 0x1u /**< \brief (AC_COMPCTRL) I/O pin 1 */ +#define AC_COMPCTRL_MUXNEG_PIN2_Val 0x2u /**< \brief (AC_COMPCTRL) I/O pin 2 */ +#define AC_COMPCTRL_MUXNEG_PIN3_Val 0x3u /**< \brief (AC_COMPCTRL) I/O pin 3 */ +#define AC_COMPCTRL_MUXNEG_GND_Val 0x4u /**< \brief (AC_COMPCTRL) Ground */ +#define AC_COMPCTRL_MUXNEG_VSCALE_Val 0x5u /**< \brief (AC_COMPCTRL) VDD scaler */ +#define AC_COMPCTRL_MUXNEG_BANDGAP_Val 0x6u /**< \brief (AC_COMPCTRL) Internal bandgap voltage */ +#define AC_COMPCTRL_MUXNEG_DAC_Val 0x7u /**< \brief (AC_COMPCTRL) DAC output */ +#define AC_COMPCTRL_MUXNEG_PIN0 (AC_COMPCTRL_MUXNEG_PIN0_Val << AC_COMPCTRL_MUXNEG_Pos) +#define AC_COMPCTRL_MUXNEG_PIN1 (AC_COMPCTRL_MUXNEG_PIN1_Val << AC_COMPCTRL_MUXNEG_Pos) +#define AC_COMPCTRL_MUXNEG_PIN2 (AC_COMPCTRL_MUXNEG_PIN2_Val << AC_COMPCTRL_MUXNEG_Pos) +#define AC_COMPCTRL_MUXNEG_PIN3 (AC_COMPCTRL_MUXNEG_PIN3_Val << AC_COMPCTRL_MUXNEG_Pos) +#define AC_COMPCTRL_MUXNEG_GND (AC_COMPCTRL_MUXNEG_GND_Val << AC_COMPCTRL_MUXNEG_Pos) +#define AC_COMPCTRL_MUXNEG_VSCALE (AC_COMPCTRL_MUXNEG_VSCALE_Val << AC_COMPCTRL_MUXNEG_Pos) +#define AC_COMPCTRL_MUXNEG_BANDGAP (AC_COMPCTRL_MUXNEG_BANDGAP_Val << AC_COMPCTRL_MUXNEG_Pos) +#define AC_COMPCTRL_MUXNEG_DAC (AC_COMPCTRL_MUXNEG_DAC_Val << AC_COMPCTRL_MUXNEG_Pos) +#define AC_COMPCTRL_MUXPOS_Pos 12 /**< \brief (AC_COMPCTRL) Positive Input Mux Selection */ +#define AC_COMPCTRL_MUXPOS_Msk (0x3u << AC_COMPCTRL_MUXPOS_Pos) +#define AC_COMPCTRL_MUXPOS(value) ((AC_COMPCTRL_MUXPOS_Msk & ((value) << AC_COMPCTRL_MUXPOS_Pos))) +#define AC_COMPCTRL_MUXPOS_PIN0_Val 0x0u /**< \brief (AC_COMPCTRL) I/O pin 0 */ +#define AC_COMPCTRL_MUXPOS_PIN1_Val 0x1u /**< \brief (AC_COMPCTRL) I/O pin 1 */ +#define AC_COMPCTRL_MUXPOS_PIN2_Val 0x2u /**< \brief (AC_COMPCTRL) I/O pin 2 */ +#define AC_COMPCTRL_MUXPOS_PIN3_Val 0x3u /**< \brief (AC_COMPCTRL) I/O pin 3 */ +#define AC_COMPCTRL_MUXPOS_PIN0 (AC_COMPCTRL_MUXPOS_PIN0_Val << AC_COMPCTRL_MUXPOS_Pos) +#define AC_COMPCTRL_MUXPOS_PIN1 (AC_COMPCTRL_MUXPOS_PIN1_Val << AC_COMPCTRL_MUXPOS_Pos) +#define AC_COMPCTRL_MUXPOS_PIN2 (AC_COMPCTRL_MUXPOS_PIN2_Val << AC_COMPCTRL_MUXPOS_Pos) +#define AC_COMPCTRL_MUXPOS_PIN3 (AC_COMPCTRL_MUXPOS_PIN3_Val << AC_COMPCTRL_MUXPOS_Pos) +#define AC_COMPCTRL_SWAP_Pos 15 /**< \brief (AC_COMPCTRL) Swap Inputs and Invert */ +#define AC_COMPCTRL_SWAP (0x1u << AC_COMPCTRL_SWAP_Pos) +#define AC_COMPCTRL_OUT_Pos 16 /**< \brief (AC_COMPCTRL) Output */ +#define AC_COMPCTRL_OUT_Msk (0x3u << AC_COMPCTRL_OUT_Pos) +#define AC_COMPCTRL_OUT(value) ((AC_COMPCTRL_OUT_Msk & ((value) << AC_COMPCTRL_OUT_Pos))) +#define AC_COMPCTRL_OUT_OFF_Val 0x0u /**< \brief (AC_COMPCTRL) The output of COMPn is not routed to the COMPn I/O port */ +#define AC_COMPCTRL_OUT_ASYNC_Val 0x1u /**< \brief (AC_COMPCTRL) The asynchronous output of COMPn is routed to the COMPn I/O port */ +#define AC_COMPCTRL_OUT_SYNC_Val 0x2u /**< \brief (AC_COMPCTRL) The synchronous output (including filtering) of COMPn is routed to the COMPn I/O port */ +#define AC_COMPCTRL_OUT_OFF (AC_COMPCTRL_OUT_OFF_Val << AC_COMPCTRL_OUT_Pos) +#define AC_COMPCTRL_OUT_ASYNC (AC_COMPCTRL_OUT_ASYNC_Val << AC_COMPCTRL_OUT_Pos) +#define AC_COMPCTRL_OUT_SYNC (AC_COMPCTRL_OUT_SYNC_Val << AC_COMPCTRL_OUT_Pos) +#define AC_COMPCTRL_HYST_Pos 19 /**< \brief (AC_COMPCTRL) Hysteresis Enable */ +#define AC_COMPCTRL_HYST (0x1u << AC_COMPCTRL_HYST_Pos) +#define AC_COMPCTRL_FLEN_Pos 24 /**< \brief (AC_COMPCTRL) Filter Length */ +#define AC_COMPCTRL_FLEN_Msk (0x7u << AC_COMPCTRL_FLEN_Pos) +#define AC_COMPCTRL_FLEN(value) ((AC_COMPCTRL_FLEN_Msk & ((value) << AC_COMPCTRL_FLEN_Pos))) +#define AC_COMPCTRL_FLEN_OFF_Val 0x0u /**< \brief (AC_COMPCTRL) No filtering */ +#define AC_COMPCTRL_FLEN_MAJ3_Val 0x1u /**< \brief (AC_COMPCTRL) 3-bit majority function (2 of 3) */ +#define AC_COMPCTRL_FLEN_MAJ5_Val 0x2u /**< \brief (AC_COMPCTRL) 5-bit majority function (3 of 5) */ +#define AC_COMPCTRL_FLEN_OFF (AC_COMPCTRL_FLEN_OFF_Val << AC_COMPCTRL_FLEN_Pos) +#define AC_COMPCTRL_FLEN_MAJ3 (AC_COMPCTRL_FLEN_MAJ3_Val << AC_COMPCTRL_FLEN_Pos) +#define AC_COMPCTRL_FLEN_MAJ5 (AC_COMPCTRL_FLEN_MAJ5_Val << AC_COMPCTRL_FLEN_Pos) +#define AC_COMPCTRL_MASK 0x070BB76Fu /**< \brief (AC_COMPCTRL) MASK Register */ + +/* -------- AC_SCALER : (AC Offset: 0x20) (R/W 8) Scaler n -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t VALUE:6; /*!< bit: 0.. 5 Scaler Value */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} AC_SCALER_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define AC_SCALER_OFFSET 0x20 /**< \brief (AC_SCALER offset) Scaler n */ +#define AC_SCALER_RESETVALUE 0x00 /**< \brief (AC_SCALER reset_value) Scaler n */ + +#define AC_SCALER_VALUE_Pos 0 /**< \brief (AC_SCALER) Scaler Value */ +#define AC_SCALER_VALUE_Msk (0x3Fu << AC_SCALER_VALUE_Pos) +#define AC_SCALER_VALUE(value) ((AC_SCALER_VALUE_Msk & ((value) << AC_SCALER_VALUE_Pos))) +#define AC_SCALER_MASK 0x3Fu /**< \brief (AC_SCALER) MASK Register */ + +/** \brief AC hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO AC_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 8) Control A */ + __O AC_CTRLB_Type CTRLB; /**< \brief Offset: 0x01 ( /W 8) Control B */ + __IO AC_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x02 (R/W 16) Event Control */ + __IO AC_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x04 (R/W 8) Interrupt Enable Clear */ + __IO AC_INTENSET_Type INTENSET; /**< \brief Offset: 0x05 (R/W 8) Interrupt Enable Set */ + __IO AC_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x06 (R/W 8) Interrupt Flag Status and Clear */ + RoReg8 Reserved1[0x1]; + __I AC_STATUSA_Type STATUSA; /**< \brief Offset: 0x08 (R/ 8) Status A */ + __I AC_STATUSB_Type STATUSB; /**< \brief Offset: 0x09 (R/ 8) Status B */ + __I AC_STATUSC_Type STATUSC; /**< \brief Offset: 0x0A (R/ 8) Status C */ + RoReg8 Reserved2[0x1]; + __IO AC_WINCTRL_Type WINCTRL; /**< \brief Offset: 0x0C (R/W 8) Window Control */ + RoReg8 Reserved3[0x3]; + __IO AC_COMPCTRL_Type COMPCTRL[2]; /**< \brief Offset: 0x10 (R/W 32) Comparator Control n */ + RoReg8 Reserved4[0x8]; + __IO AC_SCALER_Type SCALER[2]; /**< \brief Offset: 0x20 (R/W 8) Scaler n */ +} Ac; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_AC_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/adc.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/adc.h new file mode 100755 index 0000000..64cd91b --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/adc.h @@ -0,0 +1,699 @@ +/** + * \file + * + * \brief Component description for ADC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_ADC_COMPONENT_ +#define _SAMD21_ADC_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR ADC */ +/* ========================================================================== */ +/** \addtogroup SAMD21_ADC Analog Digital Converter */ +/*@{*/ + +#define ADC_U2204 +#define REV_ADC 0x120 + +/* -------- ADC_CTRLA : (ADC Offset: 0x00) (R/W 8) Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset */ + uint8_t ENABLE:1; /*!< bit: 1 Enable */ + uint8_t RUNSTDBY:1; /*!< bit: 2 Run in Standby */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_CTRLA_OFFSET 0x00 /**< \brief (ADC_CTRLA offset) Control A */ +#define ADC_CTRLA_RESETVALUE 0x00 /**< \brief (ADC_CTRLA reset_value) Control A */ + +#define ADC_CTRLA_SWRST_Pos 0 /**< \brief (ADC_CTRLA) Software Reset */ +#define ADC_CTRLA_SWRST (0x1u << ADC_CTRLA_SWRST_Pos) +#define ADC_CTRLA_ENABLE_Pos 1 /**< \brief (ADC_CTRLA) Enable */ +#define ADC_CTRLA_ENABLE (0x1u << ADC_CTRLA_ENABLE_Pos) +#define ADC_CTRLA_RUNSTDBY_Pos 2 /**< \brief (ADC_CTRLA) Run in Standby */ +#define ADC_CTRLA_RUNSTDBY (0x1u << ADC_CTRLA_RUNSTDBY_Pos) +#define ADC_CTRLA_MASK 0x07u /**< \brief (ADC_CTRLA) MASK Register */ + +/* -------- ADC_REFCTRL : (ADC Offset: 0x01) (R/W 8) Reference Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t REFSEL:4; /*!< bit: 0.. 3 Reference Selection */ + uint8_t :3; /*!< bit: 4.. 6 Reserved */ + uint8_t REFCOMP:1; /*!< bit: 7 Reference Buffer Offset Compensation Enable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_REFCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_REFCTRL_OFFSET 0x01 /**< \brief (ADC_REFCTRL offset) Reference Control */ +#define ADC_REFCTRL_RESETVALUE 0x00 /**< \brief (ADC_REFCTRL reset_value) Reference Control */ + +#define ADC_REFCTRL_REFSEL_Pos 0 /**< \brief (ADC_REFCTRL) Reference Selection */ +#define ADC_REFCTRL_REFSEL_Msk (0xFu << ADC_REFCTRL_REFSEL_Pos) +#define ADC_REFCTRL_REFSEL(value) ((ADC_REFCTRL_REFSEL_Msk & ((value) << ADC_REFCTRL_REFSEL_Pos))) +#define ADC_REFCTRL_REFSEL_INT1V_Val 0x0u /**< \brief (ADC_REFCTRL) 1.0V voltage reference */ +#define ADC_REFCTRL_REFSEL_INTVCC0_Val 0x1u /**< \brief (ADC_REFCTRL) 1/1.48 VDDANA */ +#define ADC_REFCTRL_REFSEL_INTVCC1_Val 0x2u /**< \brief (ADC_REFCTRL) 1/2 VDDANA (only for VDDANA > 2.0V) */ +#define ADC_REFCTRL_REFSEL_AREFA_Val 0x3u /**< \brief (ADC_REFCTRL) External reference */ +#define ADC_REFCTRL_REFSEL_AREFB_Val 0x4u /**< \brief (ADC_REFCTRL) External reference */ +#define ADC_REFCTRL_REFSEL_INT1V (ADC_REFCTRL_REFSEL_INT1V_Val << ADC_REFCTRL_REFSEL_Pos) +#define ADC_REFCTRL_REFSEL_INTVCC0 (ADC_REFCTRL_REFSEL_INTVCC0_Val << ADC_REFCTRL_REFSEL_Pos) +#define ADC_REFCTRL_REFSEL_INTVCC1 (ADC_REFCTRL_REFSEL_INTVCC1_Val << ADC_REFCTRL_REFSEL_Pos) +#define ADC_REFCTRL_REFSEL_AREFA (ADC_REFCTRL_REFSEL_AREFA_Val << ADC_REFCTRL_REFSEL_Pos) +#define ADC_REFCTRL_REFSEL_AREFB (ADC_REFCTRL_REFSEL_AREFB_Val << ADC_REFCTRL_REFSEL_Pos) +#define ADC_REFCTRL_REFCOMP_Pos 7 /**< \brief (ADC_REFCTRL) Reference Buffer Offset Compensation Enable */ +#define ADC_REFCTRL_REFCOMP (0x1u << ADC_REFCTRL_REFCOMP_Pos) +#define ADC_REFCTRL_MASK 0x8Fu /**< \brief (ADC_REFCTRL) MASK Register */ + +/* -------- ADC_AVGCTRL : (ADC Offset: 0x02) (R/W 8) Average Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SAMPLENUM:4; /*!< bit: 0.. 3 Number of Samples to be Collected */ + uint8_t ADJRES:3; /*!< bit: 4.. 6 Adjusting Result / Division Coefficient */ + uint8_t :1; /*!< bit: 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_AVGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_AVGCTRL_OFFSET 0x02 /**< \brief (ADC_AVGCTRL offset) Average Control */ +#define ADC_AVGCTRL_RESETVALUE 0x00 /**< \brief (ADC_AVGCTRL reset_value) Average Control */ + +#define ADC_AVGCTRL_SAMPLENUM_Pos 0 /**< \brief (ADC_AVGCTRL) Number of Samples to be Collected */ +#define ADC_AVGCTRL_SAMPLENUM_Msk (0xFu << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM(value) ((ADC_AVGCTRL_SAMPLENUM_Msk & ((value) << ADC_AVGCTRL_SAMPLENUM_Pos))) +#define ADC_AVGCTRL_SAMPLENUM_1_Val 0x0u /**< \brief (ADC_AVGCTRL) 1 sample */ +#define ADC_AVGCTRL_SAMPLENUM_2_Val 0x1u /**< \brief (ADC_AVGCTRL) 2 samples */ +#define ADC_AVGCTRL_SAMPLENUM_4_Val 0x2u /**< \brief (ADC_AVGCTRL) 4 samples */ +#define ADC_AVGCTRL_SAMPLENUM_8_Val 0x3u /**< \brief (ADC_AVGCTRL) 8 samples */ +#define ADC_AVGCTRL_SAMPLENUM_16_Val 0x4u /**< \brief (ADC_AVGCTRL) 16 samples */ +#define ADC_AVGCTRL_SAMPLENUM_32_Val 0x5u /**< \brief (ADC_AVGCTRL) 32 samples */ +#define ADC_AVGCTRL_SAMPLENUM_64_Val 0x6u /**< \brief (ADC_AVGCTRL) 64 samples */ +#define ADC_AVGCTRL_SAMPLENUM_128_Val 0x7u /**< \brief (ADC_AVGCTRL) 128 samples */ +#define ADC_AVGCTRL_SAMPLENUM_256_Val 0x8u /**< \brief (ADC_AVGCTRL) 256 samples */ +#define ADC_AVGCTRL_SAMPLENUM_512_Val 0x9u /**< \brief (ADC_AVGCTRL) 512 samples */ +#define ADC_AVGCTRL_SAMPLENUM_1024_Val 0xAu /**< \brief (ADC_AVGCTRL) 1024 samples */ +#define ADC_AVGCTRL_SAMPLENUM_1 (ADC_AVGCTRL_SAMPLENUM_1_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_2 (ADC_AVGCTRL_SAMPLENUM_2_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_4 (ADC_AVGCTRL_SAMPLENUM_4_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_8 (ADC_AVGCTRL_SAMPLENUM_8_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_16 (ADC_AVGCTRL_SAMPLENUM_16_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_32 (ADC_AVGCTRL_SAMPLENUM_32_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_64 (ADC_AVGCTRL_SAMPLENUM_64_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_128 (ADC_AVGCTRL_SAMPLENUM_128_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_256 (ADC_AVGCTRL_SAMPLENUM_256_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_512 (ADC_AVGCTRL_SAMPLENUM_512_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_SAMPLENUM_1024 (ADC_AVGCTRL_SAMPLENUM_1024_Val << ADC_AVGCTRL_SAMPLENUM_Pos) +#define ADC_AVGCTRL_ADJRES_Pos 4 /**< \brief (ADC_AVGCTRL) Adjusting Result / Division Coefficient */ +#define ADC_AVGCTRL_ADJRES_Msk (0x7u << ADC_AVGCTRL_ADJRES_Pos) +#define ADC_AVGCTRL_ADJRES(value) ((ADC_AVGCTRL_ADJRES_Msk & ((value) << ADC_AVGCTRL_ADJRES_Pos))) +#define ADC_AVGCTRL_MASK 0x7Fu /**< \brief (ADC_AVGCTRL) MASK Register */ + +/* -------- ADC_SAMPCTRL : (ADC Offset: 0x03) (R/W 8) Sampling Time Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SAMPLEN:6; /*!< bit: 0.. 5 Sampling Time Length */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_SAMPCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_SAMPCTRL_OFFSET 0x03 /**< \brief (ADC_SAMPCTRL offset) Sampling Time Control */ +#define ADC_SAMPCTRL_RESETVALUE 0x00 /**< \brief (ADC_SAMPCTRL reset_value) Sampling Time Control */ + +#define ADC_SAMPCTRL_SAMPLEN_Pos 0 /**< \brief (ADC_SAMPCTRL) Sampling Time Length */ +#define ADC_SAMPCTRL_SAMPLEN_Msk (0x3Fu << ADC_SAMPCTRL_SAMPLEN_Pos) +#define ADC_SAMPCTRL_SAMPLEN(value) ((ADC_SAMPCTRL_SAMPLEN_Msk & ((value) << ADC_SAMPCTRL_SAMPLEN_Pos))) +#define ADC_SAMPCTRL_MASK 0x3Fu /**< \brief (ADC_SAMPCTRL) MASK Register */ + +/* -------- ADC_CTRLB : (ADC Offset: 0x04) (R/W 16) Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t DIFFMODE:1; /*!< bit: 0 Differential Mode */ + uint16_t LEFTADJ:1; /*!< bit: 1 Left-Adjusted Result */ + uint16_t FREERUN:1; /*!< bit: 2 Free Running Mode */ + uint16_t CORREN:1; /*!< bit: 3 Digital Correction Logic Enabled */ + uint16_t RESSEL:2; /*!< bit: 4.. 5 Conversion Result Resolution */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t PRESCALER:3; /*!< bit: 8..10 Prescaler Configuration */ + uint16_t :5; /*!< bit: 11..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} ADC_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_CTRLB_OFFSET 0x04 /**< \brief (ADC_CTRLB offset) Control B */ +#define ADC_CTRLB_RESETVALUE 0x0000 /**< \brief (ADC_CTRLB reset_value) Control B */ + +#define ADC_CTRLB_DIFFMODE_Pos 0 /**< \brief (ADC_CTRLB) Differential Mode */ +#define ADC_CTRLB_DIFFMODE (0x1u << ADC_CTRLB_DIFFMODE_Pos) +#define ADC_CTRLB_LEFTADJ_Pos 1 /**< \brief (ADC_CTRLB) Left-Adjusted Result */ +#define ADC_CTRLB_LEFTADJ (0x1u << ADC_CTRLB_LEFTADJ_Pos) +#define ADC_CTRLB_FREERUN_Pos 2 /**< \brief (ADC_CTRLB) Free Running Mode */ +#define ADC_CTRLB_FREERUN (0x1u << ADC_CTRLB_FREERUN_Pos) +#define ADC_CTRLB_CORREN_Pos 3 /**< \brief (ADC_CTRLB) Digital Correction Logic Enabled */ +#define ADC_CTRLB_CORREN (0x1u << ADC_CTRLB_CORREN_Pos) +#define ADC_CTRLB_RESSEL_Pos 4 /**< \brief (ADC_CTRLB) Conversion Result Resolution */ +#define ADC_CTRLB_RESSEL_Msk (0x3u << ADC_CTRLB_RESSEL_Pos) +#define ADC_CTRLB_RESSEL(value) ((ADC_CTRLB_RESSEL_Msk & ((value) << ADC_CTRLB_RESSEL_Pos))) +#define ADC_CTRLB_RESSEL_12BIT_Val 0x0u /**< \brief (ADC_CTRLB) 12-bit result */ +#define ADC_CTRLB_RESSEL_16BIT_Val 0x1u /**< \brief (ADC_CTRLB) For averaging mode output */ +#define ADC_CTRLB_RESSEL_10BIT_Val 0x2u /**< \brief (ADC_CTRLB) 10-bit result */ +#define ADC_CTRLB_RESSEL_8BIT_Val 0x3u /**< \brief (ADC_CTRLB) 8-bit result */ +#define ADC_CTRLB_RESSEL_12BIT (ADC_CTRLB_RESSEL_12BIT_Val << ADC_CTRLB_RESSEL_Pos) +#define ADC_CTRLB_RESSEL_16BIT (ADC_CTRLB_RESSEL_16BIT_Val << ADC_CTRLB_RESSEL_Pos) +#define ADC_CTRLB_RESSEL_10BIT (ADC_CTRLB_RESSEL_10BIT_Val << ADC_CTRLB_RESSEL_Pos) +#define ADC_CTRLB_RESSEL_8BIT (ADC_CTRLB_RESSEL_8BIT_Val << ADC_CTRLB_RESSEL_Pos) +#define ADC_CTRLB_PRESCALER_Pos 8 /**< \brief (ADC_CTRLB) Prescaler Configuration */ +#define ADC_CTRLB_PRESCALER_Msk (0x7u << ADC_CTRLB_PRESCALER_Pos) +#define ADC_CTRLB_PRESCALER(value) ((ADC_CTRLB_PRESCALER_Msk & ((value) << ADC_CTRLB_PRESCALER_Pos))) +#define ADC_CTRLB_PRESCALER_DIV4_Val 0x0u /**< \brief (ADC_CTRLB) Peripheral clock divided by 4 */ +#define ADC_CTRLB_PRESCALER_DIV8_Val 0x1u /**< \brief (ADC_CTRLB) Peripheral clock divided by 8 */ +#define ADC_CTRLB_PRESCALER_DIV16_Val 0x2u /**< \brief (ADC_CTRLB) Peripheral clock divided by 16 */ +#define ADC_CTRLB_PRESCALER_DIV32_Val 0x3u /**< \brief (ADC_CTRLB) Peripheral clock divided by 32 */ +#define ADC_CTRLB_PRESCALER_DIV64_Val 0x4u /**< \brief (ADC_CTRLB) Peripheral clock divided by 64 */ +#define ADC_CTRLB_PRESCALER_DIV128_Val 0x5u /**< \brief (ADC_CTRLB) Peripheral clock divided by 128 */ +#define ADC_CTRLB_PRESCALER_DIV256_Val 0x6u /**< \brief (ADC_CTRLB) Peripheral clock divided by 256 */ +#define ADC_CTRLB_PRESCALER_DIV512_Val 0x7u /**< \brief (ADC_CTRLB) Peripheral clock divided by 512 */ +#define ADC_CTRLB_PRESCALER_DIV4 (ADC_CTRLB_PRESCALER_DIV4_Val << ADC_CTRLB_PRESCALER_Pos) +#define ADC_CTRLB_PRESCALER_DIV8 (ADC_CTRLB_PRESCALER_DIV8_Val << ADC_CTRLB_PRESCALER_Pos) +#define ADC_CTRLB_PRESCALER_DIV16 (ADC_CTRLB_PRESCALER_DIV16_Val << ADC_CTRLB_PRESCALER_Pos) +#define ADC_CTRLB_PRESCALER_DIV32 (ADC_CTRLB_PRESCALER_DIV32_Val << ADC_CTRLB_PRESCALER_Pos) +#define ADC_CTRLB_PRESCALER_DIV64 (ADC_CTRLB_PRESCALER_DIV64_Val << ADC_CTRLB_PRESCALER_Pos) +#define ADC_CTRLB_PRESCALER_DIV128 (ADC_CTRLB_PRESCALER_DIV128_Val << ADC_CTRLB_PRESCALER_Pos) +#define ADC_CTRLB_PRESCALER_DIV256 (ADC_CTRLB_PRESCALER_DIV256_Val << ADC_CTRLB_PRESCALER_Pos) +#define ADC_CTRLB_PRESCALER_DIV512 (ADC_CTRLB_PRESCALER_DIV512_Val << ADC_CTRLB_PRESCALER_Pos) +#define ADC_CTRLB_MASK 0x073Fu /**< \brief (ADC_CTRLB) MASK Register */ + +/* -------- ADC_WINCTRL : (ADC Offset: 0x08) (R/W 8) Window Monitor Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t WINMODE:3; /*!< bit: 0.. 2 Window Monitor Mode */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_WINCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_WINCTRL_OFFSET 0x08 /**< \brief (ADC_WINCTRL offset) Window Monitor Control */ +#define ADC_WINCTRL_RESETVALUE 0x00 /**< \brief (ADC_WINCTRL reset_value) Window Monitor Control */ + +#define ADC_WINCTRL_WINMODE_Pos 0 /**< \brief (ADC_WINCTRL) Window Monitor Mode */ +#define ADC_WINCTRL_WINMODE_Msk (0x7u << ADC_WINCTRL_WINMODE_Pos) +#define ADC_WINCTRL_WINMODE(value) ((ADC_WINCTRL_WINMODE_Msk & ((value) << ADC_WINCTRL_WINMODE_Pos))) +#define ADC_WINCTRL_WINMODE_DISABLE_Val 0x0u /**< \brief (ADC_WINCTRL) No window mode (default) */ +#define ADC_WINCTRL_WINMODE_MODE1_Val 0x1u /**< \brief (ADC_WINCTRL) Mode 1: RESULT > WINLT */ +#define ADC_WINCTRL_WINMODE_MODE2_Val 0x2u /**< \brief (ADC_WINCTRL) Mode 2: RESULT < WINUT */ +#define ADC_WINCTRL_WINMODE_MODE3_Val 0x3u /**< \brief (ADC_WINCTRL) Mode 3: WINLT < RESULT < WINUT */ +#define ADC_WINCTRL_WINMODE_MODE4_Val 0x4u /**< \brief (ADC_WINCTRL) Mode 4: !(WINLT < RESULT < WINUT) */ +#define ADC_WINCTRL_WINMODE_DISABLE (ADC_WINCTRL_WINMODE_DISABLE_Val << ADC_WINCTRL_WINMODE_Pos) +#define ADC_WINCTRL_WINMODE_MODE1 (ADC_WINCTRL_WINMODE_MODE1_Val << ADC_WINCTRL_WINMODE_Pos) +#define ADC_WINCTRL_WINMODE_MODE2 (ADC_WINCTRL_WINMODE_MODE2_Val << ADC_WINCTRL_WINMODE_Pos) +#define ADC_WINCTRL_WINMODE_MODE3 (ADC_WINCTRL_WINMODE_MODE3_Val << ADC_WINCTRL_WINMODE_Pos) +#define ADC_WINCTRL_WINMODE_MODE4 (ADC_WINCTRL_WINMODE_MODE4_Val << ADC_WINCTRL_WINMODE_Pos) +#define ADC_WINCTRL_MASK 0x07u /**< \brief (ADC_WINCTRL) MASK Register */ + +/* -------- ADC_SWTRIG : (ADC Offset: 0x0C) (R/W 8) Software Trigger -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t FLUSH:1; /*!< bit: 0 ADC Conversion Flush */ + uint8_t START:1; /*!< bit: 1 ADC Start Conversion */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_SWTRIG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_SWTRIG_OFFSET 0x0C /**< \brief (ADC_SWTRIG offset) Software Trigger */ +#define ADC_SWTRIG_RESETVALUE 0x00 /**< \brief (ADC_SWTRIG reset_value) Software Trigger */ + +#define ADC_SWTRIG_FLUSH_Pos 0 /**< \brief (ADC_SWTRIG) ADC Conversion Flush */ +#define ADC_SWTRIG_FLUSH (0x1u << ADC_SWTRIG_FLUSH_Pos) +#define ADC_SWTRIG_START_Pos 1 /**< \brief (ADC_SWTRIG) ADC Start Conversion */ +#define ADC_SWTRIG_START (0x1u << ADC_SWTRIG_START_Pos) +#define ADC_SWTRIG_MASK 0x03u /**< \brief (ADC_SWTRIG) MASK Register */ + +/* -------- ADC_INPUTCTRL : (ADC Offset: 0x10) (R/W 32) Input Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t MUXPOS:5; /*!< bit: 0.. 4 Positive Mux Input Selection */ + uint32_t :3; /*!< bit: 5.. 7 Reserved */ + uint32_t MUXNEG:5; /*!< bit: 8..12 Negative Mux Input Selection */ + uint32_t :3; /*!< bit: 13..15 Reserved */ + uint32_t INPUTSCAN:4; /*!< bit: 16..19 Number of Input Channels Included in Scan */ + uint32_t INPUTOFFSET:4; /*!< bit: 20..23 Positive Mux Setting Offset */ + uint32_t GAIN:4; /*!< bit: 24..27 Gain Factor Selection */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} ADC_INPUTCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_INPUTCTRL_OFFSET 0x10 /**< \brief (ADC_INPUTCTRL offset) Input Control */ +#define ADC_INPUTCTRL_RESETVALUE 0x00000000 /**< \brief (ADC_INPUTCTRL reset_value) Input Control */ + +#define ADC_INPUTCTRL_MUXPOS_Pos 0 /**< \brief (ADC_INPUTCTRL) Positive Mux Input Selection */ +#define ADC_INPUTCTRL_MUXPOS_Msk (0x1Fu << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS(value) ((ADC_INPUTCTRL_MUXPOS_Msk & ((value) << ADC_INPUTCTRL_MUXPOS_Pos))) +#define ADC_INPUTCTRL_MUXPOS_PIN0_Val 0x0u /**< \brief (ADC_INPUTCTRL) ADC AIN0 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN1_Val 0x1u /**< \brief (ADC_INPUTCTRL) ADC AIN1 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN2_Val 0x2u /**< \brief (ADC_INPUTCTRL) ADC AIN2 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN3_Val 0x3u /**< \brief (ADC_INPUTCTRL) ADC AIN3 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN4_Val 0x4u /**< \brief (ADC_INPUTCTRL) ADC AIN4 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN5_Val 0x5u /**< \brief (ADC_INPUTCTRL) ADC AIN5 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN6_Val 0x6u /**< \brief (ADC_INPUTCTRL) ADC AIN6 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN7_Val 0x7u /**< \brief (ADC_INPUTCTRL) ADC AIN7 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN8_Val 0x8u /**< \brief (ADC_INPUTCTRL) ADC AIN8 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN9_Val 0x9u /**< \brief (ADC_INPUTCTRL) ADC AIN9 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN10_Val 0xAu /**< \brief (ADC_INPUTCTRL) ADC AIN10 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN11_Val 0xBu /**< \brief (ADC_INPUTCTRL) ADC AIN11 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN12_Val 0xCu /**< \brief (ADC_INPUTCTRL) ADC AIN12 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN13_Val 0xDu /**< \brief (ADC_INPUTCTRL) ADC AIN13 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN14_Val 0xEu /**< \brief (ADC_INPUTCTRL) ADC AIN14 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN15_Val 0xFu /**< \brief (ADC_INPUTCTRL) ADC AIN15 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN16_Val 0x10u /**< \brief (ADC_INPUTCTRL) ADC AIN16 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN17_Val 0x11u /**< \brief (ADC_INPUTCTRL) ADC AIN17 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN18_Val 0x12u /**< \brief (ADC_INPUTCTRL) ADC AIN18 Pin */ +#define ADC_INPUTCTRL_MUXPOS_PIN19_Val 0x13u /**< \brief (ADC_INPUTCTRL) ADC AIN19 Pin */ +#define ADC_INPUTCTRL_MUXPOS_TEMP_Val 0x18u /**< \brief (ADC_INPUTCTRL) Temperature Reference */ +#define ADC_INPUTCTRL_MUXPOS_BANDGAP_Val 0x19u /**< \brief (ADC_INPUTCTRL) Bandgap Voltage */ +#define ADC_INPUTCTRL_MUXPOS_SCALEDCOREVCC_Val 0x1Au /**< \brief (ADC_INPUTCTRL) 1/4 Scaled Core Supply */ +#define ADC_INPUTCTRL_MUXPOS_SCALEDIOVCC_Val 0x1Bu /**< \brief (ADC_INPUTCTRL) 1/4 Scaled I/O Supply */ +#define ADC_INPUTCTRL_MUXPOS_DAC_Val 0x1Cu /**< \brief (ADC_INPUTCTRL) DAC Output */ +#define ADC_INPUTCTRL_MUXPOS_PIN0 (ADC_INPUTCTRL_MUXPOS_PIN0_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN1 (ADC_INPUTCTRL_MUXPOS_PIN1_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN2 (ADC_INPUTCTRL_MUXPOS_PIN2_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN3 (ADC_INPUTCTRL_MUXPOS_PIN3_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN4 (ADC_INPUTCTRL_MUXPOS_PIN4_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN5 (ADC_INPUTCTRL_MUXPOS_PIN5_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN6 (ADC_INPUTCTRL_MUXPOS_PIN6_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN7 (ADC_INPUTCTRL_MUXPOS_PIN7_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN8 (ADC_INPUTCTRL_MUXPOS_PIN8_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN9 (ADC_INPUTCTRL_MUXPOS_PIN9_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN10 (ADC_INPUTCTRL_MUXPOS_PIN10_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN11 (ADC_INPUTCTRL_MUXPOS_PIN11_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN12 (ADC_INPUTCTRL_MUXPOS_PIN12_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN13 (ADC_INPUTCTRL_MUXPOS_PIN13_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN14 (ADC_INPUTCTRL_MUXPOS_PIN14_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN15 (ADC_INPUTCTRL_MUXPOS_PIN15_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN16 (ADC_INPUTCTRL_MUXPOS_PIN16_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN17 (ADC_INPUTCTRL_MUXPOS_PIN17_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN18 (ADC_INPUTCTRL_MUXPOS_PIN18_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_PIN19 (ADC_INPUTCTRL_MUXPOS_PIN19_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_TEMP (ADC_INPUTCTRL_MUXPOS_TEMP_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_BANDGAP (ADC_INPUTCTRL_MUXPOS_BANDGAP_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_SCALEDCOREVCC (ADC_INPUTCTRL_MUXPOS_SCALEDCOREVCC_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_SCALEDIOVCC (ADC_INPUTCTRL_MUXPOS_SCALEDIOVCC_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXPOS_DAC (ADC_INPUTCTRL_MUXPOS_DAC_Val << ADC_INPUTCTRL_MUXPOS_Pos) +#define ADC_INPUTCTRL_MUXNEG_Pos 8 /**< \brief (ADC_INPUTCTRL) Negative Mux Input Selection */ +#define ADC_INPUTCTRL_MUXNEG_Msk (0x1Fu << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG(value) ((ADC_INPUTCTRL_MUXNEG_Msk & ((value) << ADC_INPUTCTRL_MUXNEG_Pos))) +#define ADC_INPUTCTRL_MUXNEG_PIN0_Val 0x0u /**< \brief (ADC_INPUTCTRL) ADC AIN0 Pin */ +#define ADC_INPUTCTRL_MUXNEG_PIN1_Val 0x1u /**< \brief (ADC_INPUTCTRL) ADC AIN1 Pin */ +#define ADC_INPUTCTRL_MUXNEG_PIN2_Val 0x2u /**< \brief (ADC_INPUTCTRL) ADC AIN2 Pin */ +#define ADC_INPUTCTRL_MUXNEG_PIN3_Val 0x3u /**< \brief (ADC_INPUTCTRL) ADC AIN3 Pin */ +#define ADC_INPUTCTRL_MUXNEG_PIN4_Val 0x4u /**< \brief (ADC_INPUTCTRL) ADC AIN4 Pin */ +#define ADC_INPUTCTRL_MUXNEG_PIN5_Val 0x5u /**< \brief (ADC_INPUTCTRL) ADC AIN5 Pin */ +#define ADC_INPUTCTRL_MUXNEG_PIN6_Val 0x6u /**< \brief (ADC_INPUTCTRL) ADC AIN6 Pin */ +#define ADC_INPUTCTRL_MUXNEG_PIN7_Val 0x7u /**< \brief (ADC_INPUTCTRL) ADC AIN7 Pin */ +#define ADC_INPUTCTRL_MUXNEG_GND_Val 0x18u /**< \brief (ADC_INPUTCTRL) Internal Ground */ +#define ADC_INPUTCTRL_MUXNEG_IOGND_Val 0x19u /**< \brief (ADC_INPUTCTRL) I/O Ground */ +#define ADC_INPUTCTRL_MUXNEG_PIN0 (ADC_INPUTCTRL_MUXNEG_PIN0_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG_PIN1 (ADC_INPUTCTRL_MUXNEG_PIN1_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG_PIN2 (ADC_INPUTCTRL_MUXNEG_PIN2_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG_PIN3 (ADC_INPUTCTRL_MUXNEG_PIN3_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG_PIN4 (ADC_INPUTCTRL_MUXNEG_PIN4_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG_PIN5 (ADC_INPUTCTRL_MUXNEG_PIN5_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG_PIN6 (ADC_INPUTCTRL_MUXNEG_PIN6_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG_PIN7 (ADC_INPUTCTRL_MUXNEG_PIN7_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG_GND (ADC_INPUTCTRL_MUXNEG_GND_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_MUXNEG_IOGND (ADC_INPUTCTRL_MUXNEG_IOGND_Val << ADC_INPUTCTRL_MUXNEG_Pos) +#define ADC_INPUTCTRL_INPUTSCAN_Pos 16 /**< \brief (ADC_INPUTCTRL) Number of Input Channels Included in Scan */ +#define ADC_INPUTCTRL_INPUTSCAN_Msk (0xFu << ADC_INPUTCTRL_INPUTSCAN_Pos) +#define ADC_INPUTCTRL_INPUTSCAN(value) ((ADC_INPUTCTRL_INPUTSCAN_Msk & ((value) << ADC_INPUTCTRL_INPUTSCAN_Pos))) +#define ADC_INPUTCTRL_INPUTOFFSET_Pos 20 /**< \brief (ADC_INPUTCTRL) Positive Mux Setting Offset */ +#define ADC_INPUTCTRL_INPUTOFFSET_Msk (0xFu << ADC_INPUTCTRL_INPUTOFFSET_Pos) +#define ADC_INPUTCTRL_INPUTOFFSET(value) ((ADC_INPUTCTRL_INPUTOFFSET_Msk & ((value) << ADC_INPUTCTRL_INPUTOFFSET_Pos))) +#define ADC_INPUTCTRL_GAIN_Pos 24 /**< \brief (ADC_INPUTCTRL) Gain Factor Selection */ +#define ADC_INPUTCTRL_GAIN_Msk (0xFu << ADC_INPUTCTRL_GAIN_Pos) +#define ADC_INPUTCTRL_GAIN(value) ((ADC_INPUTCTRL_GAIN_Msk & ((value) << ADC_INPUTCTRL_GAIN_Pos))) +#define ADC_INPUTCTRL_GAIN_1X_Val 0x0u /**< \brief (ADC_INPUTCTRL) 1x */ +#define ADC_INPUTCTRL_GAIN_2X_Val 0x1u /**< \brief (ADC_INPUTCTRL) 2x */ +#define ADC_INPUTCTRL_GAIN_4X_Val 0x2u /**< \brief (ADC_INPUTCTRL) 4x */ +#define ADC_INPUTCTRL_GAIN_8X_Val 0x3u /**< \brief (ADC_INPUTCTRL) 8x */ +#define ADC_INPUTCTRL_GAIN_16X_Val 0x4u /**< \brief (ADC_INPUTCTRL) 16x */ +#define ADC_INPUTCTRL_GAIN_DIV2_Val 0xFu /**< \brief (ADC_INPUTCTRL) 1/2x */ +#define ADC_INPUTCTRL_GAIN_1X (ADC_INPUTCTRL_GAIN_1X_Val << ADC_INPUTCTRL_GAIN_Pos) +#define ADC_INPUTCTRL_GAIN_2X (ADC_INPUTCTRL_GAIN_2X_Val << ADC_INPUTCTRL_GAIN_Pos) +#define ADC_INPUTCTRL_GAIN_4X (ADC_INPUTCTRL_GAIN_4X_Val << ADC_INPUTCTRL_GAIN_Pos) +#define ADC_INPUTCTRL_GAIN_8X (ADC_INPUTCTRL_GAIN_8X_Val << ADC_INPUTCTRL_GAIN_Pos) +#define ADC_INPUTCTRL_GAIN_16X (ADC_INPUTCTRL_GAIN_16X_Val << ADC_INPUTCTRL_GAIN_Pos) +#define ADC_INPUTCTRL_GAIN_DIV2 (ADC_INPUTCTRL_GAIN_DIV2_Val << ADC_INPUTCTRL_GAIN_Pos) +#define ADC_INPUTCTRL_MASK 0x0FFF1F1Fu /**< \brief (ADC_INPUTCTRL) MASK Register */ + +/* -------- ADC_EVCTRL : (ADC Offset: 0x14) (R/W 8) Event Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t STARTEI:1; /*!< bit: 0 Start Conversion Event In */ + uint8_t SYNCEI:1; /*!< bit: 1 Synchronization Event In */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t RESRDYEO:1; /*!< bit: 4 Result Ready Event Out */ + uint8_t WINMONEO:1; /*!< bit: 5 Window Monitor Event Out */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_EVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_EVCTRL_OFFSET 0x14 /**< \brief (ADC_EVCTRL offset) Event Control */ +#define ADC_EVCTRL_RESETVALUE 0x00 /**< \brief (ADC_EVCTRL reset_value) Event Control */ + +#define ADC_EVCTRL_STARTEI_Pos 0 /**< \brief (ADC_EVCTRL) Start Conversion Event In */ +#define ADC_EVCTRL_STARTEI (0x1u << ADC_EVCTRL_STARTEI_Pos) +#define ADC_EVCTRL_SYNCEI_Pos 1 /**< \brief (ADC_EVCTRL) Synchronization Event In */ +#define ADC_EVCTRL_SYNCEI (0x1u << ADC_EVCTRL_SYNCEI_Pos) +#define ADC_EVCTRL_RESRDYEO_Pos 4 /**< \brief (ADC_EVCTRL) Result Ready Event Out */ +#define ADC_EVCTRL_RESRDYEO (0x1u << ADC_EVCTRL_RESRDYEO_Pos) +#define ADC_EVCTRL_WINMONEO_Pos 5 /**< \brief (ADC_EVCTRL) Window Monitor Event Out */ +#define ADC_EVCTRL_WINMONEO (0x1u << ADC_EVCTRL_WINMONEO_Pos) +#define ADC_EVCTRL_MASK 0x33u /**< \brief (ADC_EVCTRL) MASK Register */ + +/* -------- ADC_INTENCLR : (ADC Offset: 0x16) (R/W 8) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t RESRDY:1; /*!< bit: 0 Result Ready Interrupt Enable */ + uint8_t OVERRUN:1; /*!< bit: 1 Overrun Interrupt Enable */ + uint8_t WINMON:1; /*!< bit: 2 Window Monitor Interrupt Enable */ + uint8_t SYNCRDY:1; /*!< bit: 3 Synchronization Ready Interrupt Enable */ + uint8_t :4; /*!< bit: 4.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_INTENCLR_OFFSET 0x16 /**< \brief (ADC_INTENCLR offset) Interrupt Enable Clear */ +#define ADC_INTENCLR_RESETVALUE 0x00 /**< \brief (ADC_INTENCLR reset_value) Interrupt Enable Clear */ + +#define ADC_INTENCLR_RESRDY_Pos 0 /**< \brief (ADC_INTENCLR) Result Ready Interrupt Enable */ +#define ADC_INTENCLR_RESRDY (0x1u << ADC_INTENCLR_RESRDY_Pos) +#define ADC_INTENCLR_OVERRUN_Pos 1 /**< \brief (ADC_INTENCLR) Overrun Interrupt Enable */ +#define ADC_INTENCLR_OVERRUN (0x1u << ADC_INTENCLR_OVERRUN_Pos) +#define ADC_INTENCLR_WINMON_Pos 2 /**< \brief (ADC_INTENCLR) Window Monitor Interrupt Enable */ +#define ADC_INTENCLR_WINMON (0x1u << ADC_INTENCLR_WINMON_Pos) +#define ADC_INTENCLR_SYNCRDY_Pos 3 /**< \brief (ADC_INTENCLR) Synchronization Ready Interrupt Enable */ +#define ADC_INTENCLR_SYNCRDY (0x1u << ADC_INTENCLR_SYNCRDY_Pos) +#define ADC_INTENCLR_MASK 0x0Fu /**< \brief (ADC_INTENCLR) MASK Register */ + +/* -------- ADC_INTENSET : (ADC Offset: 0x17) (R/W 8) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t RESRDY:1; /*!< bit: 0 Result Ready Interrupt Enable */ + uint8_t OVERRUN:1; /*!< bit: 1 Overrun Interrupt Enable */ + uint8_t WINMON:1; /*!< bit: 2 Window Monitor Interrupt Enable */ + uint8_t SYNCRDY:1; /*!< bit: 3 Synchronization Ready Interrupt Enable */ + uint8_t :4; /*!< bit: 4.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_INTENSET_OFFSET 0x17 /**< \brief (ADC_INTENSET offset) Interrupt Enable Set */ +#define ADC_INTENSET_RESETVALUE 0x00 /**< \brief (ADC_INTENSET reset_value) Interrupt Enable Set */ + +#define ADC_INTENSET_RESRDY_Pos 0 /**< \brief (ADC_INTENSET) Result Ready Interrupt Enable */ +#define ADC_INTENSET_RESRDY (0x1u << ADC_INTENSET_RESRDY_Pos) +#define ADC_INTENSET_OVERRUN_Pos 1 /**< \brief (ADC_INTENSET) Overrun Interrupt Enable */ +#define ADC_INTENSET_OVERRUN (0x1u << ADC_INTENSET_OVERRUN_Pos) +#define ADC_INTENSET_WINMON_Pos 2 /**< \brief (ADC_INTENSET) Window Monitor Interrupt Enable */ +#define ADC_INTENSET_WINMON (0x1u << ADC_INTENSET_WINMON_Pos) +#define ADC_INTENSET_SYNCRDY_Pos 3 /**< \brief (ADC_INTENSET) Synchronization Ready Interrupt Enable */ +#define ADC_INTENSET_SYNCRDY (0x1u << ADC_INTENSET_SYNCRDY_Pos) +#define ADC_INTENSET_MASK 0x0Fu /**< \brief (ADC_INTENSET) MASK Register */ + +/* -------- ADC_INTFLAG : (ADC Offset: 0x18) (R/W 8) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t RESRDY:1; /*!< bit: 0 Result Ready */ + uint8_t OVERRUN:1; /*!< bit: 1 Overrun */ + uint8_t WINMON:1; /*!< bit: 2 Window Monitor */ + uint8_t SYNCRDY:1; /*!< bit: 3 Synchronization Ready */ + uint8_t :4; /*!< bit: 4.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_INTFLAG_OFFSET 0x18 /**< \brief (ADC_INTFLAG offset) Interrupt Flag Status and Clear */ +#define ADC_INTFLAG_RESETVALUE 0x00 /**< \brief (ADC_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define ADC_INTFLAG_RESRDY_Pos 0 /**< \brief (ADC_INTFLAG) Result Ready */ +#define ADC_INTFLAG_RESRDY (0x1u << ADC_INTFLAG_RESRDY_Pos) +#define ADC_INTFLAG_OVERRUN_Pos 1 /**< \brief (ADC_INTFLAG) Overrun */ +#define ADC_INTFLAG_OVERRUN (0x1u << ADC_INTFLAG_OVERRUN_Pos) +#define ADC_INTFLAG_WINMON_Pos 2 /**< \brief (ADC_INTFLAG) Window Monitor */ +#define ADC_INTFLAG_WINMON (0x1u << ADC_INTFLAG_WINMON_Pos) +#define ADC_INTFLAG_SYNCRDY_Pos 3 /**< \brief (ADC_INTFLAG) Synchronization Ready */ +#define ADC_INTFLAG_SYNCRDY (0x1u << ADC_INTFLAG_SYNCRDY_Pos) +#define ADC_INTFLAG_MASK 0x0Fu /**< \brief (ADC_INTFLAG) MASK Register */ + +/* -------- ADC_STATUS : (ADC Offset: 0x19) (R/ 8) Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :7; /*!< bit: 0.. 6 Reserved */ + uint8_t SYNCBUSY:1; /*!< bit: 7 Synchronization Busy */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_STATUS_OFFSET 0x19 /**< \brief (ADC_STATUS offset) Status */ +#define ADC_STATUS_RESETVALUE 0x00 /**< \brief (ADC_STATUS reset_value) Status */ + +#define ADC_STATUS_SYNCBUSY_Pos 7 /**< \brief (ADC_STATUS) Synchronization Busy */ +#define ADC_STATUS_SYNCBUSY (0x1u << ADC_STATUS_SYNCBUSY_Pos) +#define ADC_STATUS_MASK 0x80u /**< \brief (ADC_STATUS) MASK Register */ + +/* -------- ADC_RESULT : (ADC Offset: 0x1A) (R/ 16) Result -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t RESULT:16; /*!< bit: 0..15 Result Conversion Value */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} ADC_RESULT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_RESULT_OFFSET 0x1A /**< \brief (ADC_RESULT offset) Result */ +#define ADC_RESULT_RESETVALUE 0x0000 /**< \brief (ADC_RESULT reset_value) Result */ + +#define ADC_RESULT_RESULT_Pos 0 /**< \brief (ADC_RESULT) Result Conversion Value */ +#define ADC_RESULT_RESULT_Msk (0xFFFFu << ADC_RESULT_RESULT_Pos) +#define ADC_RESULT_RESULT(value) ((ADC_RESULT_RESULT_Msk & ((value) << ADC_RESULT_RESULT_Pos))) +#define ADC_RESULT_MASK 0xFFFFu /**< \brief (ADC_RESULT) MASK Register */ + +/* -------- ADC_WINLT : (ADC Offset: 0x1C) (R/W 16) Window Monitor Lower Threshold -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t WINLT:16; /*!< bit: 0..15 Window Lower Threshold */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} ADC_WINLT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_WINLT_OFFSET 0x1C /**< \brief (ADC_WINLT offset) Window Monitor Lower Threshold */ +#define ADC_WINLT_RESETVALUE 0x0000 /**< \brief (ADC_WINLT reset_value) Window Monitor Lower Threshold */ + +#define ADC_WINLT_WINLT_Pos 0 /**< \brief (ADC_WINLT) Window Lower Threshold */ +#define ADC_WINLT_WINLT_Msk (0xFFFFu << ADC_WINLT_WINLT_Pos) +#define ADC_WINLT_WINLT(value) ((ADC_WINLT_WINLT_Msk & ((value) << ADC_WINLT_WINLT_Pos))) +#define ADC_WINLT_MASK 0xFFFFu /**< \brief (ADC_WINLT) MASK Register */ + +/* -------- ADC_WINUT : (ADC Offset: 0x20) (R/W 16) Window Monitor Upper Threshold -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t WINUT:16; /*!< bit: 0..15 Window Upper Threshold */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} ADC_WINUT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_WINUT_OFFSET 0x20 /**< \brief (ADC_WINUT offset) Window Monitor Upper Threshold */ +#define ADC_WINUT_RESETVALUE 0x0000 /**< \brief (ADC_WINUT reset_value) Window Monitor Upper Threshold */ + +#define ADC_WINUT_WINUT_Pos 0 /**< \brief (ADC_WINUT) Window Upper Threshold */ +#define ADC_WINUT_WINUT_Msk (0xFFFFu << ADC_WINUT_WINUT_Pos) +#define ADC_WINUT_WINUT(value) ((ADC_WINUT_WINUT_Msk & ((value) << ADC_WINUT_WINUT_Pos))) +#define ADC_WINUT_MASK 0xFFFFu /**< \brief (ADC_WINUT) MASK Register */ + +/* -------- ADC_GAINCORR : (ADC Offset: 0x24) (R/W 16) Gain Correction -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t GAINCORR:12; /*!< bit: 0..11 Gain Correction Value */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} ADC_GAINCORR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_GAINCORR_OFFSET 0x24 /**< \brief (ADC_GAINCORR offset) Gain Correction */ +#define ADC_GAINCORR_RESETVALUE 0x0000 /**< \brief (ADC_GAINCORR reset_value) Gain Correction */ + +#define ADC_GAINCORR_GAINCORR_Pos 0 /**< \brief (ADC_GAINCORR) Gain Correction Value */ +#define ADC_GAINCORR_GAINCORR_Msk (0xFFFu << ADC_GAINCORR_GAINCORR_Pos) +#define ADC_GAINCORR_GAINCORR(value) ((ADC_GAINCORR_GAINCORR_Msk & ((value) << ADC_GAINCORR_GAINCORR_Pos))) +#define ADC_GAINCORR_MASK 0x0FFFu /**< \brief (ADC_GAINCORR) MASK Register */ + +/* -------- ADC_OFFSETCORR : (ADC Offset: 0x26) (R/W 16) Offset Correction -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t OFFSETCORR:12; /*!< bit: 0..11 Offset Correction Value */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} ADC_OFFSETCORR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_OFFSETCORR_OFFSET 0x26 /**< \brief (ADC_OFFSETCORR offset) Offset Correction */ +#define ADC_OFFSETCORR_RESETVALUE 0x0000 /**< \brief (ADC_OFFSETCORR reset_value) Offset Correction */ + +#define ADC_OFFSETCORR_OFFSETCORR_Pos 0 /**< \brief (ADC_OFFSETCORR) Offset Correction Value */ +#define ADC_OFFSETCORR_OFFSETCORR_Msk (0xFFFu << ADC_OFFSETCORR_OFFSETCORR_Pos) +#define ADC_OFFSETCORR_OFFSETCORR(value) ((ADC_OFFSETCORR_OFFSETCORR_Msk & ((value) << ADC_OFFSETCORR_OFFSETCORR_Pos))) +#define ADC_OFFSETCORR_MASK 0x0FFFu /**< \brief (ADC_OFFSETCORR) MASK Register */ + +/* -------- ADC_CALIB : (ADC Offset: 0x28) (R/W 16) Calibration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t LINEARITY_CAL:8; /*!< bit: 0.. 7 Linearity Calibration Value */ + uint16_t BIAS_CAL:3; /*!< bit: 8..10 Bias Calibration Value */ + uint16_t :5; /*!< bit: 11..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} ADC_CALIB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_CALIB_OFFSET 0x28 /**< \brief (ADC_CALIB offset) Calibration */ +#define ADC_CALIB_RESETVALUE 0x0000 /**< \brief (ADC_CALIB reset_value) Calibration */ + +#define ADC_CALIB_LINEARITY_CAL_Pos 0 /**< \brief (ADC_CALIB) Linearity Calibration Value */ +#define ADC_CALIB_LINEARITY_CAL_Msk (0xFFu << ADC_CALIB_LINEARITY_CAL_Pos) +#define ADC_CALIB_LINEARITY_CAL(value) ((ADC_CALIB_LINEARITY_CAL_Msk & ((value) << ADC_CALIB_LINEARITY_CAL_Pos))) +#define ADC_CALIB_BIAS_CAL_Pos 8 /**< \brief (ADC_CALIB) Bias Calibration Value */ +#define ADC_CALIB_BIAS_CAL_Msk (0x7u << ADC_CALIB_BIAS_CAL_Pos) +#define ADC_CALIB_BIAS_CAL(value) ((ADC_CALIB_BIAS_CAL_Msk & ((value) << ADC_CALIB_BIAS_CAL_Pos))) +#define ADC_CALIB_MASK 0x07FFu /**< \brief (ADC_CALIB) MASK Register */ + +/* -------- ADC_DBGCTRL : (ADC Offset: 0x2A) (R/W 8) Debug Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DBGRUN:1; /*!< bit: 0 Debug Run */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} ADC_DBGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define ADC_DBGCTRL_OFFSET 0x2A /**< \brief (ADC_DBGCTRL offset) Debug Control */ +#define ADC_DBGCTRL_RESETVALUE 0x00 /**< \brief (ADC_DBGCTRL reset_value) Debug Control */ + +#define ADC_DBGCTRL_DBGRUN_Pos 0 /**< \brief (ADC_DBGCTRL) Debug Run */ +#define ADC_DBGCTRL_DBGRUN (0x1u << ADC_DBGCTRL_DBGRUN_Pos) +#define ADC_DBGCTRL_MASK 0x01u /**< \brief (ADC_DBGCTRL) MASK Register */ + +/** \brief ADC hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO ADC_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 8) Control A */ + __IO ADC_REFCTRL_Type REFCTRL; /**< \brief Offset: 0x01 (R/W 8) Reference Control */ + __IO ADC_AVGCTRL_Type AVGCTRL; /**< \brief Offset: 0x02 (R/W 8) Average Control */ + __IO ADC_SAMPCTRL_Type SAMPCTRL; /**< \brief Offset: 0x03 (R/W 8) Sampling Time Control */ + __IO ADC_CTRLB_Type CTRLB; /**< \brief Offset: 0x04 (R/W 16) Control B */ + RoReg8 Reserved1[0x2]; + __IO ADC_WINCTRL_Type WINCTRL; /**< \brief Offset: 0x08 (R/W 8) Window Monitor Control */ + RoReg8 Reserved2[0x3]; + __IO ADC_SWTRIG_Type SWTRIG; /**< \brief Offset: 0x0C (R/W 8) Software Trigger */ + RoReg8 Reserved3[0x3]; + __IO ADC_INPUTCTRL_Type INPUTCTRL; /**< \brief Offset: 0x10 (R/W 32) Input Control */ + __IO ADC_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x14 (R/W 8) Event Control */ + RoReg8 Reserved4[0x1]; + __IO ADC_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x16 (R/W 8) Interrupt Enable Clear */ + __IO ADC_INTENSET_Type INTENSET; /**< \brief Offset: 0x17 (R/W 8) Interrupt Enable Set */ + __IO ADC_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x18 (R/W 8) Interrupt Flag Status and Clear */ + __I ADC_STATUS_Type STATUS; /**< \brief Offset: 0x19 (R/ 8) Status */ + __I ADC_RESULT_Type RESULT; /**< \brief Offset: 0x1A (R/ 16) Result */ + __IO ADC_WINLT_Type WINLT; /**< \brief Offset: 0x1C (R/W 16) Window Monitor Lower Threshold */ + RoReg8 Reserved5[0x2]; + __IO ADC_WINUT_Type WINUT; /**< \brief Offset: 0x20 (R/W 16) Window Monitor Upper Threshold */ + RoReg8 Reserved6[0x2]; + __IO ADC_GAINCORR_Type GAINCORR; /**< \brief Offset: 0x24 (R/W 16) Gain Correction */ + __IO ADC_OFFSETCORR_Type OFFSETCORR; /**< \brief Offset: 0x26 (R/W 16) Offset Correction */ + __IO ADC_CALIB_Type CALIB; /**< \brief Offset: 0x28 (R/W 16) Calibration */ + __IO ADC_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x2A (R/W 8) Debug Control */ +} Adc; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_ADC_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/dac.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/dac.h new file mode 100755 index 0000000..08fb25f --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/dac.h @@ -0,0 +1,286 @@ +/** + * \file + * + * \brief Component description for DAC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_DAC_COMPONENT_ +#define _SAMD21_DAC_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR DAC */ +/* ========================================================================== */ +/** \addtogroup SAMD21_DAC Digital Analog Converter */ +/*@{*/ + +#define DAC_U2214 +#define REV_DAC 0x110 + +/* -------- DAC_CTRLA : (DAC Offset: 0x0) (R/W 8) Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset */ + uint8_t ENABLE:1; /*!< bit: 1 Enable */ + uint8_t RUNSTDBY:1; /*!< bit: 2 Run in Standby */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DAC_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DAC_CTRLA_OFFSET 0x0 /**< \brief (DAC_CTRLA offset) Control A */ +#define DAC_CTRLA_RESETVALUE 0x00 /**< \brief (DAC_CTRLA reset_value) Control A */ + +#define DAC_CTRLA_SWRST_Pos 0 /**< \brief (DAC_CTRLA) Software Reset */ +#define DAC_CTRLA_SWRST (0x1u << DAC_CTRLA_SWRST_Pos) +#define DAC_CTRLA_ENABLE_Pos 1 /**< \brief (DAC_CTRLA) Enable */ +#define DAC_CTRLA_ENABLE (0x1u << DAC_CTRLA_ENABLE_Pos) +#define DAC_CTRLA_RUNSTDBY_Pos 2 /**< \brief (DAC_CTRLA) Run in Standby */ +#define DAC_CTRLA_RUNSTDBY (0x1u << DAC_CTRLA_RUNSTDBY_Pos) +#define DAC_CTRLA_MASK 0x07u /**< \brief (DAC_CTRLA) MASK Register */ + +/* -------- DAC_CTRLB : (DAC Offset: 0x1) (R/W 8) Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t EOEN:1; /*!< bit: 0 External Output Enable */ + uint8_t IOEN:1; /*!< bit: 1 Internal Output Enable */ + uint8_t LEFTADJ:1; /*!< bit: 2 Left Adjusted Data */ + uint8_t VPD:1; /*!< bit: 3 Voltage Pump Disable */ + uint8_t BDWP:1; /*!< bit: 4 Bypass DATABUF Write Protection */ + uint8_t :1; /*!< bit: 5 Reserved */ + uint8_t REFSEL:2; /*!< bit: 6.. 7 Reference Selection */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DAC_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DAC_CTRLB_OFFSET 0x1 /**< \brief (DAC_CTRLB offset) Control B */ +#define DAC_CTRLB_RESETVALUE 0x00 /**< \brief (DAC_CTRLB reset_value) Control B */ + +#define DAC_CTRLB_EOEN_Pos 0 /**< \brief (DAC_CTRLB) External Output Enable */ +#define DAC_CTRLB_EOEN (0x1u << DAC_CTRLB_EOEN_Pos) +#define DAC_CTRLB_IOEN_Pos 1 /**< \brief (DAC_CTRLB) Internal Output Enable */ +#define DAC_CTRLB_IOEN (0x1u << DAC_CTRLB_IOEN_Pos) +#define DAC_CTRLB_LEFTADJ_Pos 2 /**< \brief (DAC_CTRLB) Left Adjusted Data */ +#define DAC_CTRLB_LEFTADJ (0x1u << DAC_CTRLB_LEFTADJ_Pos) +#define DAC_CTRLB_VPD_Pos 3 /**< \brief (DAC_CTRLB) Voltage Pump Disable */ +#define DAC_CTRLB_VPD (0x1u << DAC_CTRLB_VPD_Pos) +#define DAC_CTRLB_BDWP_Pos 4 /**< \brief (DAC_CTRLB) Bypass DATABUF Write Protection */ +#define DAC_CTRLB_BDWP (0x1u << DAC_CTRLB_BDWP_Pos) +#define DAC_CTRLB_REFSEL_Pos 6 /**< \brief (DAC_CTRLB) Reference Selection */ +#define DAC_CTRLB_REFSEL_Msk (0x3u << DAC_CTRLB_REFSEL_Pos) +#define DAC_CTRLB_REFSEL(value) ((DAC_CTRLB_REFSEL_Msk & ((value) << DAC_CTRLB_REFSEL_Pos))) +#define DAC_CTRLB_REFSEL_INT1V_Val 0x0u /**< \brief (DAC_CTRLB) Internal 1.0V reference */ +#define DAC_CTRLB_REFSEL_AVCC_Val 0x1u /**< \brief (DAC_CTRLB) AVCC */ +#define DAC_CTRLB_REFSEL_VREFP_Val 0x2u /**< \brief (DAC_CTRLB) External reference */ +#define DAC_CTRLB_REFSEL_INT1V (DAC_CTRLB_REFSEL_INT1V_Val << DAC_CTRLB_REFSEL_Pos) +#define DAC_CTRLB_REFSEL_AVCC (DAC_CTRLB_REFSEL_AVCC_Val << DAC_CTRLB_REFSEL_Pos) +#define DAC_CTRLB_REFSEL_VREFP (DAC_CTRLB_REFSEL_VREFP_Val << DAC_CTRLB_REFSEL_Pos) +#define DAC_CTRLB_MASK 0xDFu /**< \brief (DAC_CTRLB) MASK Register */ + +/* -------- DAC_EVCTRL : (DAC Offset: 0x2) (R/W 8) Event Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t STARTEI:1; /*!< bit: 0 Start Conversion Event Input */ + uint8_t EMPTYEO:1; /*!< bit: 1 Data Buffer Empty Event Output */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DAC_EVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DAC_EVCTRL_OFFSET 0x2 /**< \brief (DAC_EVCTRL offset) Event Control */ +#define DAC_EVCTRL_RESETVALUE 0x00 /**< \brief (DAC_EVCTRL reset_value) Event Control */ + +#define DAC_EVCTRL_STARTEI_Pos 0 /**< \brief (DAC_EVCTRL) Start Conversion Event Input */ +#define DAC_EVCTRL_STARTEI (0x1u << DAC_EVCTRL_STARTEI_Pos) +#define DAC_EVCTRL_EMPTYEO_Pos 1 /**< \brief (DAC_EVCTRL) Data Buffer Empty Event Output */ +#define DAC_EVCTRL_EMPTYEO (0x1u << DAC_EVCTRL_EMPTYEO_Pos) +#define DAC_EVCTRL_MASK 0x03u /**< \brief (DAC_EVCTRL) MASK Register */ + +/* -------- DAC_INTENCLR : (DAC Offset: 0x4) (R/W 8) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t UNDERRUN:1; /*!< bit: 0 Underrun Interrupt Enable */ + uint8_t EMPTY:1; /*!< bit: 1 Data Buffer Empty Interrupt Enable */ + uint8_t SYNCRDY:1; /*!< bit: 2 Synchronization Ready Interrupt Enable */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DAC_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DAC_INTENCLR_OFFSET 0x4 /**< \brief (DAC_INTENCLR offset) Interrupt Enable Clear */ +#define DAC_INTENCLR_RESETVALUE 0x00 /**< \brief (DAC_INTENCLR reset_value) Interrupt Enable Clear */ + +#define DAC_INTENCLR_UNDERRUN_Pos 0 /**< \brief (DAC_INTENCLR) Underrun Interrupt Enable */ +#define DAC_INTENCLR_UNDERRUN (0x1u << DAC_INTENCLR_UNDERRUN_Pos) +#define DAC_INTENCLR_EMPTY_Pos 1 /**< \brief (DAC_INTENCLR) Data Buffer Empty Interrupt Enable */ +#define DAC_INTENCLR_EMPTY (0x1u << DAC_INTENCLR_EMPTY_Pos) +#define DAC_INTENCLR_SYNCRDY_Pos 2 /**< \brief (DAC_INTENCLR) Synchronization Ready Interrupt Enable */ +#define DAC_INTENCLR_SYNCRDY (0x1u << DAC_INTENCLR_SYNCRDY_Pos) +#define DAC_INTENCLR_MASK 0x07u /**< \brief (DAC_INTENCLR) MASK Register */ + +/* -------- DAC_INTENSET : (DAC Offset: 0x5) (R/W 8) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t UNDERRUN:1; /*!< bit: 0 Underrun Interrupt Enable */ + uint8_t EMPTY:1; /*!< bit: 1 Data Buffer Empty Interrupt Enable */ + uint8_t SYNCRDY:1; /*!< bit: 2 Synchronization Ready Interrupt Enable */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DAC_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DAC_INTENSET_OFFSET 0x5 /**< \brief (DAC_INTENSET offset) Interrupt Enable Set */ +#define DAC_INTENSET_RESETVALUE 0x00 /**< \brief (DAC_INTENSET reset_value) Interrupt Enable Set */ + +#define DAC_INTENSET_UNDERRUN_Pos 0 /**< \brief (DAC_INTENSET) Underrun Interrupt Enable */ +#define DAC_INTENSET_UNDERRUN (0x1u << DAC_INTENSET_UNDERRUN_Pos) +#define DAC_INTENSET_EMPTY_Pos 1 /**< \brief (DAC_INTENSET) Data Buffer Empty Interrupt Enable */ +#define DAC_INTENSET_EMPTY (0x1u << DAC_INTENSET_EMPTY_Pos) +#define DAC_INTENSET_SYNCRDY_Pos 2 /**< \brief (DAC_INTENSET) Synchronization Ready Interrupt Enable */ +#define DAC_INTENSET_SYNCRDY (0x1u << DAC_INTENSET_SYNCRDY_Pos) +#define DAC_INTENSET_MASK 0x07u /**< \brief (DAC_INTENSET) MASK Register */ + +/* -------- DAC_INTFLAG : (DAC Offset: 0x6) (R/W 8) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t UNDERRUN:1; /*!< bit: 0 Underrun */ + uint8_t EMPTY:1; /*!< bit: 1 Data Buffer Empty */ + uint8_t SYNCRDY:1; /*!< bit: 2 Synchronization Ready */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DAC_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DAC_INTFLAG_OFFSET 0x6 /**< \brief (DAC_INTFLAG offset) Interrupt Flag Status and Clear */ +#define DAC_INTFLAG_RESETVALUE 0x00 /**< \brief (DAC_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define DAC_INTFLAG_UNDERRUN_Pos 0 /**< \brief (DAC_INTFLAG) Underrun */ +#define DAC_INTFLAG_UNDERRUN (0x1u << DAC_INTFLAG_UNDERRUN_Pos) +#define DAC_INTFLAG_EMPTY_Pos 1 /**< \brief (DAC_INTFLAG) Data Buffer Empty */ +#define DAC_INTFLAG_EMPTY (0x1u << DAC_INTFLAG_EMPTY_Pos) +#define DAC_INTFLAG_SYNCRDY_Pos 2 /**< \brief (DAC_INTFLAG) Synchronization Ready */ +#define DAC_INTFLAG_SYNCRDY (0x1u << DAC_INTFLAG_SYNCRDY_Pos) +#define DAC_INTFLAG_MASK 0x07u /**< \brief (DAC_INTFLAG) MASK Register */ + +/* -------- DAC_STATUS : (DAC Offset: 0x7) (R/ 8) Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :7; /*!< bit: 0.. 6 Reserved */ + uint8_t SYNCBUSY:1; /*!< bit: 7 Synchronization Busy Status */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DAC_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DAC_STATUS_OFFSET 0x7 /**< \brief (DAC_STATUS offset) Status */ +#define DAC_STATUS_RESETVALUE 0x00 /**< \brief (DAC_STATUS reset_value) Status */ + +#define DAC_STATUS_SYNCBUSY_Pos 7 /**< \brief (DAC_STATUS) Synchronization Busy Status */ +#define DAC_STATUS_SYNCBUSY (0x1u << DAC_STATUS_SYNCBUSY_Pos) +#define DAC_STATUS_MASK 0x80u /**< \brief (DAC_STATUS) MASK Register */ + +/* -------- DAC_DATA : (DAC Offset: 0x8) (R/W 16) Data -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t DATA:16; /*!< bit: 0..15 Data value to be converted */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} DAC_DATA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DAC_DATA_OFFSET 0x8 /**< \brief (DAC_DATA offset) Data */ +#define DAC_DATA_RESETVALUE 0x0000 /**< \brief (DAC_DATA reset_value) Data */ + +#define DAC_DATA_DATA_Pos 0 /**< \brief (DAC_DATA) Data value to be converted */ +#define DAC_DATA_DATA_Msk (0xFFFFu << DAC_DATA_DATA_Pos) +#define DAC_DATA_DATA(value) ((DAC_DATA_DATA_Msk & ((value) << DAC_DATA_DATA_Pos))) +#define DAC_DATA_MASK 0xFFFFu /**< \brief (DAC_DATA) MASK Register */ + +/* -------- DAC_DATABUF : (DAC Offset: 0xC) (R/W 16) Data Buffer -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t DATABUF:16; /*!< bit: 0..15 Data Buffer */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} DAC_DATABUF_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DAC_DATABUF_OFFSET 0xC /**< \brief (DAC_DATABUF offset) Data Buffer */ +#define DAC_DATABUF_RESETVALUE 0x0000 /**< \brief (DAC_DATABUF reset_value) Data Buffer */ + +#define DAC_DATABUF_DATABUF_Pos 0 /**< \brief (DAC_DATABUF) Data Buffer */ +#define DAC_DATABUF_DATABUF_Msk (0xFFFFu << DAC_DATABUF_DATABUF_Pos) +#define DAC_DATABUF_DATABUF(value) ((DAC_DATABUF_DATABUF_Msk & ((value) << DAC_DATABUF_DATABUF_Pos))) +#define DAC_DATABUF_MASK 0xFFFFu /**< \brief (DAC_DATABUF) MASK Register */ + +/** \brief DAC hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO DAC_CTRLA_Type CTRLA; /**< \brief Offset: 0x0 (R/W 8) Control A */ + __IO DAC_CTRLB_Type CTRLB; /**< \brief Offset: 0x1 (R/W 8) Control B */ + __IO DAC_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x2 (R/W 8) Event Control */ + RoReg8 Reserved1[0x1]; + __IO DAC_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x4 (R/W 8) Interrupt Enable Clear */ + __IO DAC_INTENSET_Type INTENSET; /**< \brief Offset: 0x5 (R/W 8) Interrupt Enable Set */ + __IO DAC_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x6 (R/W 8) Interrupt Flag Status and Clear */ + __I DAC_STATUS_Type STATUS; /**< \brief Offset: 0x7 (R/ 8) Status */ + __IO DAC_DATA_Type DATA; /**< \brief Offset: 0x8 (R/W 16) Data */ + RoReg8 Reserved2[0x2]; + __IO DAC_DATABUF_Type DATABUF; /**< \brief Offset: 0xC (R/W 16) Data Buffer */ +} Dac; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_DAC_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/dmac.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/dmac.h new file mode 100755 index 0000000..dfd112b --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/dmac.h @@ -0,0 +1,1033 @@ +/** + * \file + * + * \brief Component description for DMAC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_DMAC_COMPONENT_ +#define _SAMD21_DMAC_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR DMAC */ +/* ========================================================================== */ +/** \addtogroup SAMD21_DMAC Direct Memory Access Controller */ +/*@{*/ + +#define DMAC_U2223 +#define REV_DMAC 0x100 + +/* -------- DMAC_CTRL : (DMAC Offset: 0x00) (R/W 16) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SWRST:1; /*!< bit: 0 Software Reset */ + uint16_t DMAENABLE:1; /*!< bit: 1 DMA Enable */ + uint16_t CRCENABLE:1; /*!< bit: 2 CRC Enable */ + uint16_t :5; /*!< bit: 3.. 7 Reserved */ + uint16_t LVLEN0:1; /*!< bit: 8 Priority Level 0 Enable */ + uint16_t LVLEN1:1; /*!< bit: 9 Priority Level 1 Enable */ + uint16_t LVLEN2:1; /*!< bit: 10 Priority Level 2 Enable */ + uint16_t LVLEN3:1; /*!< bit: 11 Priority Level 3 Enable */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t :8; /*!< bit: 0.. 7 Reserved */ + uint16_t LVLEN:4; /*!< bit: 8..11 Priority Level x Enable */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} DMAC_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CTRL_OFFSET 0x00 /**< \brief (DMAC_CTRL offset) Control */ +#define DMAC_CTRL_RESETVALUE 0x0000 /**< \brief (DMAC_CTRL reset_value) Control */ + +#define DMAC_CTRL_SWRST_Pos 0 /**< \brief (DMAC_CTRL) Software Reset */ +#define DMAC_CTRL_SWRST (0x1u << DMAC_CTRL_SWRST_Pos) +#define DMAC_CTRL_DMAENABLE_Pos 1 /**< \brief (DMAC_CTRL) DMA Enable */ +#define DMAC_CTRL_DMAENABLE (0x1u << DMAC_CTRL_DMAENABLE_Pos) +#define DMAC_CTRL_CRCENABLE_Pos 2 /**< \brief (DMAC_CTRL) CRC Enable */ +#define DMAC_CTRL_CRCENABLE (0x1u << DMAC_CTRL_CRCENABLE_Pos) +#define DMAC_CTRL_LVLEN0_Pos 8 /**< \brief (DMAC_CTRL) Priority Level 0 Enable */ +#define DMAC_CTRL_LVLEN0 (1 << DMAC_CTRL_LVLEN0_Pos) +#define DMAC_CTRL_LVLEN1_Pos 9 /**< \brief (DMAC_CTRL) Priority Level 1 Enable */ +#define DMAC_CTRL_LVLEN1 (1 << DMAC_CTRL_LVLEN1_Pos) +#define DMAC_CTRL_LVLEN2_Pos 10 /**< \brief (DMAC_CTRL) Priority Level 2 Enable */ +#define DMAC_CTRL_LVLEN2 (1 << DMAC_CTRL_LVLEN2_Pos) +#define DMAC_CTRL_LVLEN3_Pos 11 /**< \brief (DMAC_CTRL) Priority Level 3 Enable */ +#define DMAC_CTRL_LVLEN3 (1 << DMAC_CTRL_LVLEN3_Pos) +#define DMAC_CTRL_LVLEN_Pos 8 /**< \brief (DMAC_CTRL) Priority Level x Enable */ +#define DMAC_CTRL_LVLEN_Msk (0xFu << DMAC_CTRL_LVLEN_Pos) +#define DMAC_CTRL_LVLEN(value) ((DMAC_CTRL_LVLEN_Msk & ((value) << DMAC_CTRL_LVLEN_Pos))) +#define DMAC_CTRL_MASK 0x0F07u /**< \brief (DMAC_CTRL) MASK Register */ + +/* -------- DMAC_CRCCTRL : (DMAC Offset: 0x02) (R/W 16) CRC Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t CRCBEATSIZE:2; /*!< bit: 0.. 1 CRC Beat Size */ + uint16_t CRCPOLY:2; /*!< bit: 2.. 3 CRC Polynomial Type */ + uint16_t :4; /*!< bit: 4.. 7 Reserved */ + uint16_t CRCSRC:6; /*!< bit: 8..13 CRC Input Source */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} DMAC_CRCCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CRCCTRL_OFFSET 0x02 /**< \brief (DMAC_CRCCTRL offset) CRC Control */ +#define DMAC_CRCCTRL_RESETVALUE 0x0000 /**< \brief (DMAC_CRCCTRL reset_value) CRC Control */ + +#define DMAC_CRCCTRL_CRCBEATSIZE_Pos 0 /**< \brief (DMAC_CRCCTRL) CRC Beat Size */ +#define DMAC_CRCCTRL_CRCBEATSIZE_Msk (0x3u << DMAC_CRCCTRL_CRCBEATSIZE_Pos) +#define DMAC_CRCCTRL_CRCBEATSIZE(value) ((DMAC_CRCCTRL_CRCBEATSIZE_Msk & ((value) << DMAC_CRCCTRL_CRCBEATSIZE_Pos))) +#define DMAC_CRCCTRL_CRCBEATSIZE_BYTE_Val 0x0u /**< \brief (DMAC_CRCCTRL) Byte bus access */ +#define DMAC_CRCCTRL_CRCBEATSIZE_HWORD_Val 0x1u /**< \brief (DMAC_CRCCTRL) Half-word bus access */ +#define DMAC_CRCCTRL_CRCBEATSIZE_WORD_Val 0x2u /**< \brief (DMAC_CRCCTRL) Word bus access */ +#define DMAC_CRCCTRL_CRCBEATSIZE_BYTE (DMAC_CRCCTRL_CRCBEATSIZE_BYTE_Val << DMAC_CRCCTRL_CRCBEATSIZE_Pos) +#define DMAC_CRCCTRL_CRCBEATSIZE_HWORD (DMAC_CRCCTRL_CRCBEATSIZE_HWORD_Val << DMAC_CRCCTRL_CRCBEATSIZE_Pos) +#define DMAC_CRCCTRL_CRCBEATSIZE_WORD (DMAC_CRCCTRL_CRCBEATSIZE_WORD_Val << DMAC_CRCCTRL_CRCBEATSIZE_Pos) +#define DMAC_CRCCTRL_CRCPOLY_Pos 2 /**< \brief (DMAC_CRCCTRL) CRC Polynomial Type */ +#define DMAC_CRCCTRL_CRCPOLY_Msk (0x3u << DMAC_CRCCTRL_CRCPOLY_Pos) +#define DMAC_CRCCTRL_CRCPOLY(value) ((DMAC_CRCCTRL_CRCPOLY_Msk & ((value) << DMAC_CRCCTRL_CRCPOLY_Pos))) +#define DMAC_CRCCTRL_CRCPOLY_CRC16_Val 0x0u /**< \brief (DMAC_CRCCTRL) CRC-16 (CRC-CCITT) */ +#define DMAC_CRCCTRL_CRCPOLY_CRC32_Val 0x1u /**< \brief (DMAC_CRCCTRL) CRC32 (IEEE 802.3) */ +#define DMAC_CRCCTRL_CRCPOLY_CRC16 (DMAC_CRCCTRL_CRCPOLY_CRC16_Val << DMAC_CRCCTRL_CRCPOLY_Pos) +#define DMAC_CRCCTRL_CRCPOLY_CRC32 (DMAC_CRCCTRL_CRCPOLY_CRC32_Val << DMAC_CRCCTRL_CRCPOLY_Pos) +#define DMAC_CRCCTRL_CRCSRC_Pos 8 /**< \brief (DMAC_CRCCTRL) CRC Input Source */ +#define DMAC_CRCCTRL_CRCSRC_Msk (0x3Fu << DMAC_CRCCTRL_CRCSRC_Pos) +#define DMAC_CRCCTRL_CRCSRC(value) ((DMAC_CRCCTRL_CRCSRC_Msk & ((value) << DMAC_CRCCTRL_CRCSRC_Pos))) +#define DMAC_CRCCTRL_CRCSRC_NOACT_Val 0x0u /**< \brief (DMAC_CRCCTRL) No action */ +#define DMAC_CRCCTRL_CRCSRC_IO_Val 0x1u /**< \brief (DMAC_CRCCTRL) I/O interface */ +#define DMAC_CRCCTRL_CRCSRC_NOACT (DMAC_CRCCTRL_CRCSRC_NOACT_Val << DMAC_CRCCTRL_CRCSRC_Pos) +#define DMAC_CRCCTRL_CRCSRC_IO (DMAC_CRCCTRL_CRCSRC_IO_Val << DMAC_CRCCTRL_CRCSRC_Pos) +#define DMAC_CRCCTRL_MASK 0x3F0Fu /**< \brief (DMAC_CRCCTRL) MASK Register */ + +/* -------- DMAC_CRCDATAIN : (DMAC Offset: 0x04) (R/W 32) CRC Data Input -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CRCDATAIN:32; /*!< bit: 0..31 CRC Data Input */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_CRCDATAIN_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CRCDATAIN_OFFSET 0x04 /**< \brief (DMAC_CRCDATAIN offset) CRC Data Input */ +#define DMAC_CRCDATAIN_RESETVALUE 0x00000000 /**< \brief (DMAC_CRCDATAIN reset_value) CRC Data Input */ + +#define DMAC_CRCDATAIN_CRCDATAIN_Pos 0 /**< \brief (DMAC_CRCDATAIN) CRC Data Input */ +#define DMAC_CRCDATAIN_CRCDATAIN_Msk (0xFFFFFFFFu << DMAC_CRCDATAIN_CRCDATAIN_Pos) +#define DMAC_CRCDATAIN_CRCDATAIN(value) ((DMAC_CRCDATAIN_CRCDATAIN_Msk & ((value) << DMAC_CRCDATAIN_CRCDATAIN_Pos))) +#define DMAC_CRCDATAIN_MASK 0xFFFFFFFFu /**< \brief (DMAC_CRCDATAIN) MASK Register */ + +/* -------- DMAC_CRCCHKSUM : (DMAC Offset: 0x08) (R/W 32) CRC Checksum -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CRCCHKSUM:32; /*!< bit: 0..31 CRC Checksum */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_CRCCHKSUM_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CRCCHKSUM_OFFSET 0x08 /**< \brief (DMAC_CRCCHKSUM offset) CRC Checksum */ +#define DMAC_CRCCHKSUM_RESETVALUE 0x00000000 /**< \brief (DMAC_CRCCHKSUM reset_value) CRC Checksum */ + +#define DMAC_CRCCHKSUM_CRCCHKSUM_Pos 0 /**< \brief (DMAC_CRCCHKSUM) CRC Checksum */ +#define DMAC_CRCCHKSUM_CRCCHKSUM_Msk (0xFFFFFFFFu << DMAC_CRCCHKSUM_CRCCHKSUM_Pos) +#define DMAC_CRCCHKSUM_CRCCHKSUM(value) ((DMAC_CRCCHKSUM_CRCCHKSUM_Msk & ((value) << DMAC_CRCCHKSUM_CRCCHKSUM_Pos))) +#define DMAC_CRCCHKSUM_MASK 0xFFFFFFFFu /**< \brief (DMAC_CRCCHKSUM) MASK Register */ + +/* -------- DMAC_CRCSTATUS : (DMAC Offset: 0x0C) (R/W 8) CRC Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CRCBUSY:1; /*!< bit: 0 CRC Module Busy */ + uint8_t CRCZERO:1; /*!< bit: 1 CRC Zero */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DMAC_CRCSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CRCSTATUS_OFFSET 0x0C /**< \brief (DMAC_CRCSTATUS offset) CRC Status */ +#define DMAC_CRCSTATUS_RESETVALUE 0x00 /**< \brief (DMAC_CRCSTATUS reset_value) CRC Status */ + +#define DMAC_CRCSTATUS_CRCBUSY_Pos 0 /**< \brief (DMAC_CRCSTATUS) CRC Module Busy */ +#define DMAC_CRCSTATUS_CRCBUSY (0x1u << DMAC_CRCSTATUS_CRCBUSY_Pos) +#define DMAC_CRCSTATUS_CRCZERO_Pos 1 /**< \brief (DMAC_CRCSTATUS) CRC Zero */ +#define DMAC_CRCSTATUS_CRCZERO (0x1u << DMAC_CRCSTATUS_CRCZERO_Pos) +#define DMAC_CRCSTATUS_MASK 0x03u /**< \brief (DMAC_CRCSTATUS) MASK Register */ + +/* -------- DMAC_DBGCTRL : (DMAC Offset: 0x0D) (R/W 8) Debug Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DBGRUN:1; /*!< bit: 0 Debug Run */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DMAC_DBGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_DBGCTRL_OFFSET 0x0D /**< \brief (DMAC_DBGCTRL offset) Debug Control */ +#define DMAC_DBGCTRL_RESETVALUE 0x00 /**< \brief (DMAC_DBGCTRL reset_value) Debug Control */ + +#define DMAC_DBGCTRL_DBGRUN_Pos 0 /**< \brief (DMAC_DBGCTRL) Debug Run */ +#define DMAC_DBGCTRL_DBGRUN (0x1u << DMAC_DBGCTRL_DBGRUN_Pos) +#define DMAC_DBGCTRL_MASK 0x01u /**< \brief (DMAC_DBGCTRL) MASK Register */ + +/* -------- DMAC_SWTRIGCTRL : (DMAC Offset: 0x10) (R/W 32) Software Trigger Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWTRIG0:1; /*!< bit: 0 Channel 0 Software Trigger */ + uint32_t SWTRIG1:1; /*!< bit: 1 Channel 1 Software Trigger */ + uint32_t SWTRIG2:1; /*!< bit: 2 Channel 2 Software Trigger */ + uint32_t SWTRIG3:1; /*!< bit: 3 Channel 3 Software Trigger */ + uint32_t SWTRIG4:1; /*!< bit: 4 Channel 4 Software Trigger */ + uint32_t SWTRIG5:1; /*!< bit: 5 Channel 5 Software Trigger */ + uint32_t SWTRIG6:1; /*!< bit: 6 Channel 6 Software Trigger */ + uint32_t SWTRIG7:1; /*!< bit: 7 Channel 7 Software Trigger */ + uint32_t SWTRIG8:1; /*!< bit: 8 Channel 8 Software Trigger */ + uint32_t SWTRIG9:1; /*!< bit: 9 Channel 9 Software Trigger */ + uint32_t SWTRIG10:1; /*!< bit: 10 Channel 10 Software Trigger */ + uint32_t SWTRIG11:1; /*!< bit: 11 Channel 11 Software Trigger */ + uint32_t :20; /*!< bit: 12..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t SWTRIG:12; /*!< bit: 0..11 Channel x Software Trigger */ + uint32_t :20; /*!< bit: 12..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_SWTRIGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_SWTRIGCTRL_OFFSET 0x10 /**< \brief (DMAC_SWTRIGCTRL offset) Software Trigger Control */ +#define DMAC_SWTRIGCTRL_RESETVALUE 0x00000000 /**< \brief (DMAC_SWTRIGCTRL reset_value) Software Trigger Control */ + +#define DMAC_SWTRIGCTRL_SWTRIG0_Pos 0 /**< \brief (DMAC_SWTRIGCTRL) Channel 0 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG0 (1 << DMAC_SWTRIGCTRL_SWTRIG0_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG1_Pos 1 /**< \brief (DMAC_SWTRIGCTRL) Channel 1 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG1 (1 << DMAC_SWTRIGCTRL_SWTRIG1_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG2_Pos 2 /**< \brief (DMAC_SWTRIGCTRL) Channel 2 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG2 (1 << DMAC_SWTRIGCTRL_SWTRIG2_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG3_Pos 3 /**< \brief (DMAC_SWTRIGCTRL) Channel 3 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG3 (1 << DMAC_SWTRIGCTRL_SWTRIG3_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG4_Pos 4 /**< \brief (DMAC_SWTRIGCTRL) Channel 4 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG4 (1 << DMAC_SWTRIGCTRL_SWTRIG4_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG5_Pos 5 /**< \brief (DMAC_SWTRIGCTRL) Channel 5 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG5 (1 << DMAC_SWTRIGCTRL_SWTRIG5_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG6_Pos 6 /**< \brief (DMAC_SWTRIGCTRL) Channel 6 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG6 (1 << DMAC_SWTRIGCTRL_SWTRIG6_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG7_Pos 7 /**< \brief (DMAC_SWTRIGCTRL) Channel 7 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG7 (1 << DMAC_SWTRIGCTRL_SWTRIG7_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG8_Pos 8 /**< \brief (DMAC_SWTRIGCTRL) Channel 8 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG8 (1 << DMAC_SWTRIGCTRL_SWTRIG8_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG9_Pos 9 /**< \brief (DMAC_SWTRIGCTRL) Channel 9 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG9 (1 << DMAC_SWTRIGCTRL_SWTRIG9_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG10_Pos 10 /**< \brief (DMAC_SWTRIGCTRL) Channel 10 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG10 (1 << DMAC_SWTRIGCTRL_SWTRIG10_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG11_Pos 11 /**< \brief (DMAC_SWTRIGCTRL) Channel 11 Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG11 (1 << DMAC_SWTRIGCTRL_SWTRIG11_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG_Pos 0 /**< \brief (DMAC_SWTRIGCTRL) Channel x Software Trigger */ +#define DMAC_SWTRIGCTRL_SWTRIG_Msk (0xFFFu << DMAC_SWTRIGCTRL_SWTRIG_Pos) +#define DMAC_SWTRIGCTRL_SWTRIG(value) ((DMAC_SWTRIGCTRL_SWTRIG_Msk & ((value) << DMAC_SWTRIGCTRL_SWTRIG_Pos))) +#define DMAC_SWTRIGCTRL_MASK 0x00000FFFu /**< \brief (DMAC_SWTRIGCTRL) MASK Register */ + +/* -------- DMAC_PRICTRL0 : (DMAC Offset: 0x14) (R/W 32) Priority Control 0 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t LVLPRI0:4; /*!< bit: 0.. 3 Level 0 Channel Priority Number */ + uint32_t :3; /*!< bit: 4.. 6 Reserved */ + uint32_t RRLVLEN0:1; /*!< bit: 7 Level 0 Round-Robin Scheduling Enable */ + uint32_t LVLPRI1:4; /*!< bit: 8..11 Level 1 Channel Priority Number */ + uint32_t :3; /*!< bit: 12..14 Reserved */ + uint32_t RRLVLEN1:1; /*!< bit: 15 Level 1 Round-Robin Scheduling Enable */ + uint32_t LVLPRI2:4; /*!< bit: 16..19 Level 2 Channel Priority Number */ + uint32_t :3; /*!< bit: 20..22 Reserved */ + uint32_t RRLVLEN2:1; /*!< bit: 23 Level 2 Round-Robin Scheduling Enable */ + uint32_t LVLPRI3:4; /*!< bit: 24..27 Level 3 Channel Priority Number */ + uint32_t :3; /*!< bit: 28..30 Reserved */ + uint32_t RRLVLEN3:1; /*!< bit: 31 Level 3 Round-Robin Scheduling Enable */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_PRICTRL0_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_PRICTRL0_OFFSET 0x14 /**< \brief (DMAC_PRICTRL0 offset) Priority Control 0 */ +#define DMAC_PRICTRL0_RESETVALUE 0x00000000 /**< \brief (DMAC_PRICTRL0 reset_value) Priority Control 0 */ + +#define DMAC_PRICTRL0_LVLPRI0_Pos 0 /**< \brief (DMAC_PRICTRL0) Level 0 Channel Priority Number */ +#define DMAC_PRICTRL0_LVLPRI0_Msk (0xFu << DMAC_PRICTRL0_LVLPRI0_Pos) +#define DMAC_PRICTRL0_LVLPRI0(value) ((DMAC_PRICTRL0_LVLPRI0_Msk & ((value) << DMAC_PRICTRL0_LVLPRI0_Pos))) +#define DMAC_PRICTRL0_RRLVLEN0_Pos 7 /**< \brief (DMAC_PRICTRL0) Level 0 Round-Robin Scheduling Enable */ +#define DMAC_PRICTRL0_RRLVLEN0 (0x1u << DMAC_PRICTRL0_RRLVLEN0_Pos) +#define DMAC_PRICTRL0_LVLPRI1_Pos 8 /**< \brief (DMAC_PRICTRL0) Level 1 Channel Priority Number */ +#define DMAC_PRICTRL0_LVLPRI1_Msk (0xFu << DMAC_PRICTRL0_LVLPRI1_Pos) +#define DMAC_PRICTRL0_LVLPRI1(value) ((DMAC_PRICTRL0_LVLPRI1_Msk & ((value) << DMAC_PRICTRL0_LVLPRI1_Pos))) +#define DMAC_PRICTRL0_RRLVLEN1_Pos 15 /**< \brief (DMAC_PRICTRL0) Level 1 Round-Robin Scheduling Enable */ +#define DMAC_PRICTRL0_RRLVLEN1 (0x1u << DMAC_PRICTRL0_RRLVLEN1_Pos) +#define DMAC_PRICTRL0_LVLPRI2_Pos 16 /**< \brief (DMAC_PRICTRL0) Level 2 Channel Priority Number */ +#define DMAC_PRICTRL0_LVLPRI2_Msk (0xFu << DMAC_PRICTRL0_LVLPRI2_Pos) +#define DMAC_PRICTRL0_LVLPRI2(value) ((DMAC_PRICTRL0_LVLPRI2_Msk & ((value) << DMAC_PRICTRL0_LVLPRI2_Pos))) +#define DMAC_PRICTRL0_RRLVLEN2_Pos 23 /**< \brief (DMAC_PRICTRL0) Level 2 Round-Robin Scheduling Enable */ +#define DMAC_PRICTRL0_RRLVLEN2 (0x1u << DMAC_PRICTRL0_RRLVLEN2_Pos) +#define DMAC_PRICTRL0_LVLPRI3_Pos 24 /**< \brief (DMAC_PRICTRL0) Level 3 Channel Priority Number */ +#define DMAC_PRICTRL0_LVLPRI3_Msk (0xFu << DMAC_PRICTRL0_LVLPRI3_Pos) +#define DMAC_PRICTRL0_LVLPRI3(value) ((DMAC_PRICTRL0_LVLPRI3_Msk & ((value) << DMAC_PRICTRL0_LVLPRI3_Pos))) +#define DMAC_PRICTRL0_RRLVLEN3_Pos 31 /**< \brief (DMAC_PRICTRL0) Level 3 Round-Robin Scheduling Enable */ +#define DMAC_PRICTRL0_RRLVLEN3 (0x1u << DMAC_PRICTRL0_RRLVLEN3_Pos) +#define DMAC_PRICTRL0_MASK 0x8F8F8F8Fu /**< \brief (DMAC_PRICTRL0) MASK Register */ + +/* -------- DMAC_INTPEND : (DMAC Offset: 0x20) (R/W 16) Interrupt Pending -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t ID:4; /*!< bit: 0.. 3 Channel ID */ + uint16_t :4; /*!< bit: 4.. 7 Reserved */ + uint16_t TERR:1; /*!< bit: 8 Transfer Error */ + uint16_t TCMPL:1; /*!< bit: 9 Transfer Complete */ + uint16_t SUSP:1; /*!< bit: 10 Channel Suspend */ + uint16_t :2; /*!< bit: 11..12 Reserved */ + uint16_t FERR:1; /*!< bit: 13 Fetch Error */ + uint16_t BUSY:1; /*!< bit: 14 Busy */ + uint16_t PEND:1; /*!< bit: 15 Pending */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} DMAC_INTPEND_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_INTPEND_OFFSET 0x20 /**< \brief (DMAC_INTPEND offset) Interrupt Pending */ +#define DMAC_INTPEND_RESETVALUE 0x0000 /**< \brief (DMAC_INTPEND reset_value) Interrupt Pending */ + +#define DMAC_INTPEND_ID_Pos 0 /**< \brief (DMAC_INTPEND) Channel ID */ +#define DMAC_INTPEND_ID_Msk (0xFu << DMAC_INTPEND_ID_Pos) +#define DMAC_INTPEND_ID(value) ((DMAC_INTPEND_ID_Msk & ((value) << DMAC_INTPEND_ID_Pos))) +#define DMAC_INTPEND_TERR_Pos 8 /**< \brief (DMAC_INTPEND) Transfer Error */ +#define DMAC_INTPEND_TERR (0x1u << DMAC_INTPEND_TERR_Pos) +#define DMAC_INTPEND_TCMPL_Pos 9 /**< \brief (DMAC_INTPEND) Transfer Complete */ +#define DMAC_INTPEND_TCMPL (0x1u << DMAC_INTPEND_TCMPL_Pos) +#define DMAC_INTPEND_SUSP_Pos 10 /**< \brief (DMAC_INTPEND) Channel Suspend */ +#define DMAC_INTPEND_SUSP (0x1u << DMAC_INTPEND_SUSP_Pos) +#define DMAC_INTPEND_FERR_Pos 13 /**< \brief (DMAC_INTPEND) Fetch Error */ +#define DMAC_INTPEND_FERR (0x1u << DMAC_INTPEND_FERR_Pos) +#define DMAC_INTPEND_BUSY_Pos 14 /**< \brief (DMAC_INTPEND) Busy */ +#define DMAC_INTPEND_BUSY (0x1u << DMAC_INTPEND_BUSY_Pos) +#define DMAC_INTPEND_PEND_Pos 15 /**< \brief (DMAC_INTPEND) Pending */ +#define DMAC_INTPEND_PEND (0x1u << DMAC_INTPEND_PEND_Pos) +#define DMAC_INTPEND_MASK 0xE70Fu /**< \brief (DMAC_INTPEND) MASK Register */ + +/* -------- DMAC_INTSTATUS : (DMAC Offset: 0x24) (R/ 32) Interrupt Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CHINT0:1; /*!< bit: 0 Channel 0 Pending Interrupt */ + uint32_t CHINT1:1; /*!< bit: 1 Channel 1 Pending Interrupt */ + uint32_t CHINT2:1; /*!< bit: 2 Channel 2 Pending Interrupt */ + uint32_t CHINT3:1; /*!< bit: 3 Channel 3 Pending Interrupt */ + uint32_t CHINT4:1; /*!< bit: 4 Channel 4 Pending Interrupt */ + uint32_t CHINT5:1; /*!< bit: 5 Channel 5 Pending Interrupt */ + uint32_t CHINT6:1; /*!< bit: 6 Channel 6 Pending Interrupt */ + uint32_t CHINT7:1; /*!< bit: 7 Channel 7 Pending Interrupt */ + uint32_t CHINT8:1; /*!< bit: 8 Channel 8 Pending Interrupt */ + uint32_t CHINT9:1; /*!< bit: 9 Channel 9 Pending Interrupt */ + uint32_t CHINT10:1; /*!< bit: 10 Channel 10 Pending Interrupt */ + uint32_t CHINT11:1; /*!< bit: 11 Channel 11 Pending Interrupt */ + uint32_t :20; /*!< bit: 12..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t CHINT:12; /*!< bit: 0..11 Channel x Pending Interrupt */ + uint32_t :20; /*!< bit: 12..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_INTSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_INTSTATUS_OFFSET 0x24 /**< \brief (DMAC_INTSTATUS offset) Interrupt Status */ +#define DMAC_INTSTATUS_RESETVALUE 0x00000000 /**< \brief (DMAC_INTSTATUS reset_value) Interrupt Status */ + +#define DMAC_INTSTATUS_CHINT0_Pos 0 /**< \brief (DMAC_INTSTATUS) Channel 0 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT0 (1 << DMAC_INTSTATUS_CHINT0_Pos) +#define DMAC_INTSTATUS_CHINT1_Pos 1 /**< \brief (DMAC_INTSTATUS) Channel 1 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT1 (1 << DMAC_INTSTATUS_CHINT1_Pos) +#define DMAC_INTSTATUS_CHINT2_Pos 2 /**< \brief (DMAC_INTSTATUS) Channel 2 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT2 (1 << DMAC_INTSTATUS_CHINT2_Pos) +#define DMAC_INTSTATUS_CHINT3_Pos 3 /**< \brief (DMAC_INTSTATUS) Channel 3 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT3 (1 << DMAC_INTSTATUS_CHINT3_Pos) +#define DMAC_INTSTATUS_CHINT4_Pos 4 /**< \brief (DMAC_INTSTATUS) Channel 4 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT4 (1 << DMAC_INTSTATUS_CHINT4_Pos) +#define DMAC_INTSTATUS_CHINT5_Pos 5 /**< \brief (DMAC_INTSTATUS) Channel 5 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT5 (1 << DMAC_INTSTATUS_CHINT5_Pos) +#define DMAC_INTSTATUS_CHINT6_Pos 6 /**< \brief (DMAC_INTSTATUS) Channel 6 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT6 (1 << DMAC_INTSTATUS_CHINT6_Pos) +#define DMAC_INTSTATUS_CHINT7_Pos 7 /**< \brief (DMAC_INTSTATUS) Channel 7 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT7 (1 << DMAC_INTSTATUS_CHINT7_Pos) +#define DMAC_INTSTATUS_CHINT8_Pos 8 /**< \brief (DMAC_INTSTATUS) Channel 8 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT8 (1 << DMAC_INTSTATUS_CHINT8_Pos) +#define DMAC_INTSTATUS_CHINT9_Pos 9 /**< \brief (DMAC_INTSTATUS) Channel 9 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT9 (1 << DMAC_INTSTATUS_CHINT9_Pos) +#define DMAC_INTSTATUS_CHINT10_Pos 10 /**< \brief (DMAC_INTSTATUS) Channel 10 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT10 (1 << DMAC_INTSTATUS_CHINT10_Pos) +#define DMAC_INTSTATUS_CHINT11_Pos 11 /**< \brief (DMAC_INTSTATUS) Channel 11 Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT11 (1 << DMAC_INTSTATUS_CHINT11_Pos) +#define DMAC_INTSTATUS_CHINT_Pos 0 /**< \brief (DMAC_INTSTATUS) Channel x Pending Interrupt */ +#define DMAC_INTSTATUS_CHINT_Msk (0xFFFu << DMAC_INTSTATUS_CHINT_Pos) +#define DMAC_INTSTATUS_CHINT(value) ((DMAC_INTSTATUS_CHINT_Msk & ((value) << DMAC_INTSTATUS_CHINT_Pos))) +#define DMAC_INTSTATUS_MASK 0x00000FFFu /**< \brief (DMAC_INTSTATUS) MASK Register */ + +/* -------- DMAC_BUSYCH : (DMAC Offset: 0x28) (R/ 32) Busy Channels -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t BUSYCH0:1; /*!< bit: 0 Busy Channel 0 */ + uint32_t BUSYCH1:1; /*!< bit: 1 Busy Channel 1 */ + uint32_t BUSYCH2:1; /*!< bit: 2 Busy Channel 2 */ + uint32_t BUSYCH3:1; /*!< bit: 3 Busy Channel 3 */ + uint32_t BUSYCH4:1; /*!< bit: 4 Busy Channel 4 */ + uint32_t BUSYCH5:1; /*!< bit: 5 Busy Channel 5 */ + uint32_t BUSYCH6:1; /*!< bit: 6 Busy Channel 6 */ + uint32_t BUSYCH7:1; /*!< bit: 7 Busy Channel 7 */ + uint32_t BUSYCH8:1; /*!< bit: 8 Busy Channel 8 */ + uint32_t BUSYCH9:1; /*!< bit: 9 Busy Channel 9 */ + uint32_t BUSYCH10:1; /*!< bit: 10 Busy Channel 10 */ + uint32_t BUSYCH11:1; /*!< bit: 11 Busy Channel 11 */ + uint32_t :20; /*!< bit: 12..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t BUSYCH:12; /*!< bit: 0..11 Busy Channel x */ + uint32_t :20; /*!< bit: 12..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_BUSYCH_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_BUSYCH_OFFSET 0x28 /**< \brief (DMAC_BUSYCH offset) Busy Channels */ +#define DMAC_BUSYCH_RESETVALUE 0x00000000 /**< \brief (DMAC_BUSYCH reset_value) Busy Channels */ + +#define DMAC_BUSYCH_BUSYCH0_Pos 0 /**< \brief (DMAC_BUSYCH) Busy Channel 0 */ +#define DMAC_BUSYCH_BUSYCH0 (1 << DMAC_BUSYCH_BUSYCH0_Pos) +#define DMAC_BUSYCH_BUSYCH1_Pos 1 /**< \brief (DMAC_BUSYCH) Busy Channel 1 */ +#define DMAC_BUSYCH_BUSYCH1 (1 << DMAC_BUSYCH_BUSYCH1_Pos) +#define DMAC_BUSYCH_BUSYCH2_Pos 2 /**< \brief (DMAC_BUSYCH) Busy Channel 2 */ +#define DMAC_BUSYCH_BUSYCH2 (1 << DMAC_BUSYCH_BUSYCH2_Pos) +#define DMAC_BUSYCH_BUSYCH3_Pos 3 /**< \brief (DMAC_BUSYCH) Busy Channel 3 */ +#define DMAC_BUSYCH_BUSYCH3 (1 << DMAC_BUSYCH_BUSYCH3_Pos) +#define DMAC_BUSYCH_BUSYCH4_Pos 4 /**< \brief (DMAC_BUSYCH) Busy Channel 4 */ +#define DMAC_BUSYCH_BUSYCH4 (1 << DMAC_BUSYCH_BUSYCH4_Pos) +#define DMAC_BUSYCH_BUSYCH5_Pos 5 /**< \brief (DMAC_BUSYCH) Busy Channel 5 */ +#define DMAC_BUSYCH_BUSYCH5 (1 << DMAC_BUSYCH_BUSYCH5_Pos) +#define DMAC_BUSYCH_BUSYCH6_Pos 6 /**< \brief (DMAC_BUSYCH) Busy Channel 6 */ +#define DMAC_BUSYCH_BUSYCH6 (1 << DMAC_BUSYCH_BUSYCH6_Pos) +#define DMAC_BUSYCH_BUSYCH7_Pos 7 /**< \brief (DMAC_BUSYCH) Busy Channel 7 */ +#define DMAC_BUSYCH_BUSYCH7 (1 << DMAC_BUSYCH_BUSYCH7_Pos) +#define DMAC_BUSYCH_BUSYCH8_Pos 8 /**< \brief (DMAC_BUSYCH) Busy Channel 8 */ +#define DMAC_BUSYCH_BUSYCH8 (1 << DMAC_BUSYCH_BUSYCH8_Pos) +#define DMAC_BUSYCH_BUSYCH9_Pos 9 /**< \brief (DMAC_BUSYCH) Busy Channel 9 */ +#define DMAC_BUSYCH_BUSYCH9 (1 << DMAC_BUSYCH_BUSYCH9_Pos) +#define DMAC_BUSYCH_BUSYCH10_Pos 10 /**< \brief (DMAC_BUSYCH) Busy Channel 10 */ +#define DMAC_BUSYCH_BUSYCH10 (1 << DMAC_BUSYCH_BUSYCH10_Pos) +#define DMAC_BUSYCH_BUSYCH11_Pos 11 /**< \brief (DMAC_BUSYCH) Busy Channel 11 */ +#define DMAC_BUSYCH_BUSYCH11 (1 << DMAC_BUSYCH_BUSYCH11_Pos) +#define DMAC_BUSYCH_BUSYCH_Pos 0 /**< \brief (DMAC_BUSYCH) Busy Channel x */ +#define DMAC_BUSYCH_BUSYCH_Msk (0xFFFu << DMAC_BUSYCH_BUSYCH_Pos) +#define DMAC_BUSYCH_BUSYCH(value) ((DMAC_BUSYCH_BUSYCH_Msk & ((value) << DMAC_BUSYCH_BUSYCH_Pos))) +#define DMAC_BUSYCH_MASK 0x00000FFFu /**< \brief (DMAC_BUSYCH) MASK Register */ + +/* -------- DMAC_PENDCH : (DMAC Offset: 0x2C) (R/ 32) Pending Channels -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PENDCH0:1; /*!< bit: 0 Pending Channel 0 */ + uint32_t PENDCH1:1; /*!< bit: 1 Pending Channel 1 */ + uint32_t PENDCH2:1; /*!< bit: 2 Pending Channel 2 */ + uint32_t PENDCH3:1; /*!< bit: 3 Pending Channel 3 */ + uint32_t PENDCH4:1; /*!< bit: 4 Pending Channel 4 */ + uint32_t PENDCH5:1; /*!< bit: 5 Pending Channel 5 */ + uint32_t PENDCH6:1; /*!< bit: 6 Pending Channel 6 */ + uint32_t PENDCH7:1; /*!< bit: 7 Pending Channel 7 */ + uint32_t PENDCH8:1; /*!< bit: 8 Pending Channel 8 */ + uint32_t PENDCH9:1; /*!< bit: 9 Pending Channel 9 */ + uint32_t PENDCH10:1; /*!< bit: 10 Pending Channel 10 */ + uint32_t PENDCH11:1; /*!< bit: 11 Pending Channel 11 */ + uint32_t :20; /*!< bit: 12..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t PENDCH:12; /*!< bit: 0..11 Pending Channel x */ + uint32_t :20; /*!< bit: 12..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_PENDCH_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_PENDCH_OFFSET 0x2C /**< \brief (DMAC_PENDCH offset) Pending Channels */ +#define DMAC_PENDCH_RESETVALUE 0x00000000 /**< \brief (DMAC_PENDCH reset_value) Pending Channels */ + +#define DMAC_PENDCH_PENDCH0_Pos 0 /**< \brief (DMAC_PENDCH) Pending Channel 0 */ +#define DMAC_PENDCH_PENDCH0 (1 << DMAC_PENDCH_PENDCH0_Pos) +#define DMAC_PENDCH_PENDCH1_Pos 1 /**< \brief (DMAC_PENDCH) Pending Channel 1 */ +#define DMAC_PENDCH_PENDCH1 (1 << DMAC_PENDCH_PENDCH1_Pos) +#define DMAC_PENDCH_PENDCH2_Pos 2 /**< \brief (DMAC_PENDCH) Pending Channel 2 */ +#define DMAC_PENDCH_PENDCH2 (1 << DMAC_PENDCH_PENDCH2_Pos) +#define DMAC_PENDCH_PENDCH3_Pos 3 /**< \brief (DMAC_PENDCH) Pending Channel 3 */ +#define DMAC_PENDCH_PENDCH3 (1 << DMAC_PENDCH_PENDCH3_Pos) +#define DMAC_PENDCH_PENDCH4_Pos 4 /**< \brief (DMAC_PENDCH) Pending Channel 4 */ +#define DMAC_PENDCH_PENDCH4 (1 << DMAC_PENDCH_PENDCH4_Pos) +#define DMAC_PENDCH_PENDCH5_Pos 5 /**< \brief (DMAC_PENDCH) Pending Channel 5 */ +#define DMAC_PENDCH_PENDCH5 (1 << DMAC_PENDCH_PENDCH5_Pos) +#define DMAC_PENDCH_PENDCH6_Pos 6 /**< \brief (DMAC_PENDCH) Pending Channel 6 */ +#define DMAC_PENDCH_PENDCH6 (1 << DMAC_PENDCH_PENDCH6_Pos) +#define DMAC_PENDCH_PENDCH7_Pos 7 /**< \brief (DMAC_PENDCH) Pending Channel 7 */ +#define DMAC_PENDCH_PENDCH7 (1 << DMAC_PENDCH_PENDCH7_Pos) +#define DMAC_PENDCH_PENDCH8_Pos 8 /**< \brief (DMAC_PENDCH) Pending Channel 8 */ +#define DMAC_PENDCH_PENDCH8 (1 << DMAC_PENDCH_PENDCH8_Pos) +#define DMAC_PENDCH_PENDCH9_Pos 9 /**< \brief (DMAC_PENDCH) Pending Channel 9 */ +#define DMAC_PENDCH_PENDCH9 (1 << DMAC_PENDCH_PENDCH9_Pos) +#define DMAC_PENDCH_PENDCH10_Pos 10 /**< \brief (DMAC_PENDCH) Pending Channel 10 */ +#define DMAC_PENDCH_PENDCH10 (1 << DMAC_PENDCH_PENDCH10_Pos) +#define DMAC_PENDCH_PENDCH11_Pos 11 /**< \brief (DMAC_PENDCH) Pending Channel 11 */ +#define DMAC_PENDCH_PENDCH11 (1 << DMAC_PENDCH_PENDCH11_Pos) +#define DMAC_PENDCH_PENDCH_Pos 0 /**< \brief (DMAC_PENDCH) Pending Channel x */ +#define DMAC_PENDCH_PENDCH_Msk (0xFFFu << DMAC_PENDCH_PENDCH_Pos) +#define DMAC_PENDCH_PENDCH(value) ((DMAC_PENDCH_PENDCH_Msk & ((value) << DMAC_PENDCH_PENDCH_Pos))) +#define DMAC_PENDCH_MASK 0x00000FFFu /**< \brief (DMAC_PENDCH) MASK Register */ + +/* -------- DMAC_ACTIVE : (DMAC Offset: 0x30) (R/ 32) Active Channel and Levels -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t LVLEX0:1; /*!< bit: 0 Level 0 Channel Trigger Request Executing */ + uint32_t LVLEX1:1; /*!< bit: 1 Level 1 Channel Trigger Request Executing */ + uint32_t LVLEX2:1; /*!< bit: 2 Level 2 Channel Trigger Request Executing */ + uint32_t LVLEX3:1; /*!< bit: 3 Level 3 Channel Trigger Request Executing */ + uint32_t :4; /*!< bit: 4.. 7 Reserved */ + uint32_t ID:5; /*!< bit: 8..12 Active Channel ID */ + uint32_t :2; /*!< bit: 13..14 Reserved */ + uint32_t ABUSY:1; /*!< bit: 15 Active Channel Busy */ + uint32_t BTCNT:16; /*!< bit: 16..31 Active Channel Block Transfer Count */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t LVLEX:4; /*!< bit: 0.. 3 Level x Channel Trigger Request Executing */ + uint32_t :28; /*!< bit: 4..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_ACTIVE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_ACTIVE_OFFSET 0x30 /**< \brief (DMAC_ACTIVE offset) Active Channel and Levels */ +#define DMAC_ACTIVE_RESETVALUE 0x00000000 /**< \brief (DMAC_ACTIVE reset_value) Active Channel and Levels */ + +#define DMAC_ACTIVE_LVLEX0_Pos 0 /**< \brief (DMAC_ACTIVE) Level 0 Channel Trigger Request Executing */ +#define DMAC_ACTIVE_LVLEX0 (1 << DMAC_ACTIVE_LVLEX0_Pos) +#define DMAC_ACTIVE_LVLEX1_Pos 1 /**< \brief (DMAC_ACTIVE) Level 1 Channel Trigger Request Executing */ +#define DMAC_ACTIVE_LVLEX1 (1 << DMAC_ACTIVE_LVLEX1_Pos) +#define DMAC_ACTIVE_LVLEX2_Pos 2 /**< \brief (DMAC_ACTIVE) Level 2 Channel Trigger Request Executing */ +#define DMAC_ACTIVE_LVLEX2 (1 << DMAC_ACTIVE_LVLEX2_Pos) +#define DMAC_ACTIVE_LVLEX3_Pos 3 /**< \brief (DMAC_ACTIVE) Level 3 Channel Trigger Request Executing */ +#define DMAC_ACTIVE_LVLEX3 (1 << DMAC_ACTIVE_LVLEX3_Pos) +#define DMAC_ACTIVE_LVLEX_Pos 0 /**< \brief (DMAC_ACTIVE) Level x Channel Trigger Request Executing */ +#define DMAC_ACTIVE_LVLEX_Msk (0xFu << DMAC_ACTIVE_LVLEX_Pos) +#define DMAC_ACTIVE_LVLEX(value) ((DMAC_ACTIVE_LVLEX_Msk & ((value) << DMAC_ACTIVE_LVLEX_Pos))) +#define DMAC_ACTIVE_ID_Pos 8 /**< \brief (DMAC_ACTIVE) Active Channel ID */ +#define DMAC_ACTIVE_ID_Msk (0x1Fu << DMAC_ACTIVE_ID_Pos) +#define DMAC_ACTIVE_ID(value) ((DMAC_ACTIVE_ID_Msk & ((value) << DMAC_ACTIVE_ID_Pos))) +#define DMAC_ACTIVE_ABUSY_Pos 15 /**< \brief (DMAC_ACTIVE) Active Channel Busy */ +#define DMAC_ACTIVE_ABUSY (0x1u << DMAC_ACTIVE_ABUSY_Pos) +#define DMAC_ACTIVE_BTCNT_Pos 16 /**< \brief (DMAC_ACTIVE) Active Channel Block Transfer Count */ +#define DMAC_ACTIVE_BTCNT_Msk (0xFFFFu << DMAC_ACTIVE_BTCNT_Pos) +#define DMAC_ACTIVE_BTCNT(value) ((DMAC_ACTIVE_BTCNT_Msk & ((value) << DMAC_ACTIVE_BTCNT_Pos))) +#define DMAC_ACTIVE_MASK 0xFFFF9F0Fu /**< \brief (DMAC_ACTIVE) MASK Register */ + +/* -------- DMAC_BASEADDR : (DMAC Offset: 0x34) (R/W 32) Descriptor Memory Section Base Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t BASEADDR:32; /*!< bit: 0..31 Descriptor Memory Base Address */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_BASEADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_BASEADDR_OFFSET 0x34 /**< \brief (DMAC_BASEADDR offset) Descriptor Memory Section Base Address */ +#define DMAC_BASEADDR_RESETVALUE 0x00000000 /**< \brief (DMAC_BASEADDR reset_value) Descriptor Memory Section Base Address */ + +#define DMAC_BASEADDR_BASEADDR_Pos 0 /**< \brief (DMAC_BASEADDR) Descriptor Memory Base Address */ +#define DMAC_BASEADDR_BASEADDR_Msk (0xFFFFFFFFu << DMAC_BASEADDR_BASEADDR_Pos) +#define DMAC_BASEADDR_BASEADDR(value) ((DMAC_BASEADDR_BASEADDR_Msk & ((value) << DMAC_BASEADDR_BASEADDR_Pos))) +#define DMAC_BASEADDR_MASK 0xFFFFFFFFu /**< \brief (DMAC_BASEADDR) MASK Register */ + +/* -------- DMAC_WRBADDR : (DMAC Offset: 0x38) (R/W 32) Write-Back Memory Section Base Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t WRBADDR:32; /*!< bit: 0..31 Write-Back Memory Base Address */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_WRBADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_WRBADDR_OFFSET 0x38 /**< \brief (DMAC_WRBADDR offset) Write-Back Memory Section Base Address */ +#define DMAC_WRBADDR_RESETVALUE 0x00000000 /**< \brief (DMAC_WRBADDR reset_value) Write-Back Memory Section Base Address */ + +#define DMAC_WRBADDR_WRBADDR_Pos 0 /**< \brief (DMAC_WRBADDR) Write-Back Memory Base Address */ +#define DMAC_WRBADDR_WRBADDR_Msk (0xFFFFFFFFu << DMAC_WRBADDR_WRBADDR_Pos) +#define DMAC_WRBADDR_WRBADDR(value) ((DMAC_WRBADDR_WRBADDR_Msk & ((value) << DMAC_WRBADDR_WRBADDR_Pos))) +#define DMAC_WRBADDR_MASK 0xFFFFFFFFu /**< \brief (DMAC_WRBADDR) MASK Register */ + +/* -------- DMAC_CHID : (DMAC Offset: 0x3F) (R/W 8) Channel ID -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t ID:4; /*!< bit: 0.. 3 Channel ID */ + uint8_t :4; /*!< bit: 4.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DMAC_CHID_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CHID_OFFSET 0x3F /**< \brief (DMAC_CHID offset) Channel ID */ +#define DMAC_CHID_RESETVALUE 0x00 /**< \brief (DMAC_CHID reset_value) Channel ID */ + +#define DMAC_CHID_ID_Pos 0 /**< \brief (DMAC_CHID) Channel ID */ +#define DMAC_CHID_ID_Msk (0xFu << DMAC_CHID_ID_Pos) +#define DMAC_CHID_ID(value) ((DMAC_CHID_ID_Msk & ((value) << DMAC_CHID_ID_Pos))) +#define DMAC_CHID_MASK 0x0Fu /**< \brief (DMAC_CHID) MASK Register */ + +/* -------- DMAC_CHCTRLA : (DMAC Offset: 0x40) (R/W 8) Channel Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Channel Software Reset */ + uint8_t ENABLE:1; /*!< bit: 1 Channel Enable */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DMAC_CHCTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CHCTRLA_OFFSET 0x40 /**< \brief (DMAC_CHCTRLA offset) Channel Control A */ +#define DMAC_CHCTRLA_RESETVALUE 0x00 /**< \brief (DMAC_CHCTRLA reset_value) Channel Control A */ + +#define DMAC_CHCTRLA_SWRST_Pos 0 /**< \brief (DMAC_CHCTRLA) Channel Software Reset */ +#define DMAC_CHCTRLA_SWRST (0x1u << DMAC_CHCTRLA_SWRST_Pos) +#define DMAC_CHCTRLA_ENABLE_Pos 1 /**< \brief (DMAC_CHCTRLA) Channel Enable */ +#define DMAC_CHCTRLA_ENABLE (0x1u << DMAC_CHCTRLA_ENABLE_Pos) +#define DMAC_CHCTRLA_MASK 0x03u /**< \brief (DMAC_CHCTRLA) MASK Register */ + +/* -------- DMAC_CHCTRLB : (DMAC Offset: 0x44) (R/W 32) Channel Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t EVACT:3; /*!< bit: 0.. 2 Event Input Action */ + uint32_t EVIE:1; /*!< bit: 3 Channel Event Input Enable */ + uint32_t EVOE:1; /*!< bit: 4 Channel Event Output Enable */ + uint32_t LVL:2; /*!< bit: 5.. 6 Channel Arbitration Level */ + uint32_t :1; /*!< bit: 7 Reserved */ + uint32_t TRIGSRC:6; /*!< bit: 8..13 Peripheral Trigger Source */ + uint32_t :8; /*!< bit: 14..21 Reserved */ + uint32_t TRIGACT:2; /*!< bit: 22..23 Trigger Action */ + uint32_t CMD:2; /*!< bit: 24..25 Software Command */ + uint32_t :6; /*!< bit: 26..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_CHCTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CHCTRLB_OFFSET 0x44 /**< \brief (DMAC_CHCTRLB offset) Channel Control B */ +#define DMAC_CHCTRLB_RESETVALUE 0x00000000 /**< \brief (DMAC_CHCTRLB reset_value) Channel Control B */ + +#define DMAC_CHCTRLB_EVACT_Pos 0 /**< \brief (DMAC_CHCTRLB) Event Input Action */ +#define DMAC_CHCTRLB_EVACT_Msk (0x7u << DMAC_CHCTRLB_EVACT_Pos) +#define DMAC_CHCTRLB_EVACT(value) ((DMAC_CHCTRLB_EVACT_Msk & ((value) << DMAC_CHCTRLB_EVACT_Pos))) +#define DMAC_CHCTRLB_EVACT_NOACT_Val 0x0u /**< \brief (DMAC_CHCTRLB) No action */ +#define DMAC_CHCTRLB_EVACT_TRIG_Val 0x1u /**< \brief (DMAC_CHCTRLB) Transfer and periodic transfer trigger */ +#define DMAC_CHCTRLB_EVACT_CTRIG_Val 0x2u /**< \brief (DMAC_CHCTRLB) Conditional transfer trigger */ +#define DMAC_CHCTRLB_EVACT_CBLOCK_Val 0x3u /**< \brief (DMAC_CHCTRLB) Conditional block transfer */ +#define DMAC_CHCTRLB_EVACT_SUSPEND_Val 0x4u /**< \brief (DMAC_CHCTRLB) Channel suspend operation */ +#define DMAC_CHCTRLB_EVACT_RESUME_Val 0x5u /**< \brief (DMAC_CHCTRLB) Channel resume operation */ +#define DMAC_CHCTRLB_EVACT_SSKIP_Val 0x6u /**< \brief (DMAC_CHCTRLB) Skip next block suspend action */ +#define DMAC_CHCTRLB_EVACT_NOACT (DMAC_CHCTRLB_EVACT_NOACT_Val << DMAC_CHCTRLB_EVACT_Pos) +#define DMAC_CHCTRLB_EVACT_TRIG (DMAC_CHCTRLB_EVACT_TRIG_Val << DMAC_CHCTRLB_EVACT_Pos) +#define DMAC_CHCTRLB_EVACT_CTRIG (DMAC_CHCTRLB_EVACT_CTRIG_Val << DMAC_CHCTRLB_EVACT_Pos) +#define DMAC_CHCTRLB_EVACT_CBLOCK (DMAC_CHCTRLB_EVACT_CBLOCK_Val << DMAC_CHCTRLB_EVACT_Pos) +#define DMAC_CHCTRLB_EVACT_SUSPEND (DMAC_CHCTRLB_EVACT_SUSPEND_Val << DMAC_CHCTRLB_EVACT_Pos) +#define DMAC_CHCTRLB_EVACT_RESUME (DMAC_CHCTRLB_EVACT_RESUME_Val << DMAC_CHCTRLB_EVACT_Pos) +#define DMAC_CHCTRLB_EVACT_SSKIP (DMAC_CHCTRLB_EVACT_SSKIP_Val << DMAC_CHCTRLB_EVACT_Pos) +#define DMAC_CHCTRLB_EVIE_Pos 3 /**< \brief (DMAC_CHCTRLB) Channel Event Input Enable */ +#define DMAC_CHCTRLB_EVIE (0x1u << DMAC_CHCTRLB_EVIE_Pos) +#define DMAC_CHCTRLB_EVOE_Pos 4 /**< \brief (DMAC_CHCTRLB) Channel Event Output Enable */ +#define DMAC_CHCTRLB_EVOE (0x1u << DMAC_CHCTRLB_EVOE_Pos) +#define DMAC_CHCTRLB_LVL_Pos 5 /**< \brief (DMAC_CHCTRLB) Channel Arbitration Level */ +#define DMAC_CHCTRLB_LVL_Msk (0x3u << DMAC_CHCTRLB_LVL_Pos) +#define DMAC_CHCTRLB_LVL(value) ((DMAC_CHCTRLB_LVL_Msk & ((value) << DMAC_CHCTRLB_LVL_Pos))) +#define DMAC_CHCTRLB_LVL_LVL0_Val 0x0u /**< \brief (DMAC_CHCTRLB) Channel Priority Level 0 */ +#define DMAC_CHCTRLB_LVL_LVL1_Val 0x1u /**< \brief (DMAC_CHCTRLB) Channel Priority Level 1 */ +#define DMAC_CHCTRLB_LVL_LVL2_Val 0x2u /**< \brief (DMAC_CHCTRLB) Channel Priority Level 2 */ +#define DMAC_CHCTRLB_LVL_LVL3_Val 0x3u /**< \brief (DMAC_CHCTRLB) Channel Priority Level 3 */ +#define DMAC_CHCTRLB_LVL_LVL0 (DMAC_CHCTRLB_LVL_LVL0_Val << DMAC_CHCTRLB_LVL_Pos) +#define DMAC_CHCTRLB_LVL_LVL1 (DMAC_CHCTRLB_LVL_LVL1_Val << DMAC_CHCTRLB_LVL_Pos) +#define DMAC_CHCTRLB_LVL_LVL2 (DMAC_CHCTRLB_LVL_LVL2_Val << DMAC_CHCTRLB_LVL_Pos) +#define DMAC_CHCTRLB_LVL_LVL3 (DMAC_CHCTRLB_LVL_LVL3_Val << DMAC_CHCTRLB_LVL_Pos) +#define DMAC_CHCTRLB_TRIGSRC_Pos 8 /**< \brief (DMAC_CHCTRLB) Peripheral Trigger Source */ +#define DMAC_CHCTRLB_TRIGSRC_Msk (0x3Fu << DMAC_CHCTRLB_TRIGSRC_Pos) +#define DMAC_CHCTRLB_TRIGSRC(value) ((DMAC_CHCTRLB_TRIGSRC_Msk & ((value) << DMAC_CHCTRLB_TRIGSRC_Pos))) +#define DMAC_CHCTRLB_TRIGSRC_DISABLE_Val 0x0u /**< \brief (DMAC_CHCTRLB) Only software/event triggers */ +#define DMAC_CHCTRLB_TRIGSRC_DISABLE (DMAC_CHCTRLB_TRIGSRC_DISABLE_Val << DMAC_CHCTRLB_TRIGSRC_Pos) +#define DMAC_CHCTRLB_TRIGACT_Pos 22 /**< \brief (DMAC_CHCTRLB) Trigger Action */ +#define DMAC_CHCTRLB_TRIGACT_Msk (0x3u << DMAC_CHCTRLB_TRIGACT_Pos) +#define DMAC_CHCTRLB_TRIGACT(value) ((DMAC_CHCTRLB_TRIGACT_Msk & ((value) << DMAC_CHCTRLB_TRIGACT_Pos))) +#define DMAC_CHCTRLB_TRIGACT_BLOCK_Val 0x0u /**< \brief (DMAC_CHCTRLB) One trigger required for each block transfer */ +#define DMAC_CHCTRLB_TRIGACT_BEAT_Val 0x2u /**< \brief (DMAC_CHCTRLB) One trigger required for each beat transfer */ +#define DMAC_CHCTRLB_TRIGACT_TRANSACTION_Val 0x3u /**< \brief (DMAC_CHCTRLB) One trigger required for each transaction */ +#define DMAC_CHCTRLB_TRIGACT_BLOCK (DMAC_CHCTRLB_TRIGACT_BLOCK_Val << DMAC_CHCTRLB_TRIGACT_Pos) +#define DMAC_CHCTRLB_TRIGACT_BEAT (DMAC_CHCTRLB_TRIGACT_BEAT_Val << DMAC_CHCTRLB_TRIGACT_Pos) +#define DMAC_CHCTRLB_TRIGACT_TRANSACTION (DMAC_CHCTRLB_TRIGACT_TRANSACTION_Val << DMAC_CHCTRLB_TRIGACT_Pos) +#define DMAC_CHCTRLB_CMD_Pos 24 /**< \brief (DMAC_CHCTRLB) Software Command */ +#define DMAC_CHCTRLB_CMD_Msk (0x3u << DMAC_CHCTRLB_CMD_Pos) +#define DMAC_CHCTRLB_CMD(value) ((DMAC_CHCTRLB_CMD_Msk & ((value) << DMAC_CHCTRLB_CMD_Pos))) +#define DMAC_CHCTRLB_CMD_NOACT_Val 0x0u /**< \brief (DMAC_CHCTRLB) No action */ +#define DMAC_CHCTRLB_CMD_SUSPEND_Val 0x1u /**< \brief (DMAC_CHCTRLB) Channel suspend operation */ +#define DMAC_CHCTRLB_CMD_RESUME_Val 0x2u /**< \brief (DMAC_CHCTRLB) Channel resume operation */ +#define DMAC_CHCTRLB_CMD_NOACT (DMAC_CHCTRLB_CMD_NOACT_Val << DMAC_CHCTRLB_CMD_Pos) +#define DMAC_CHCTRLB_CMD_SUSPEND (DMAC_CHCTRLB_CMD_SUSPEND_Val << DMAC_CHCTRLB_CMD_Pos) +#define DMAC_CHCTRLB_CMD_RESUME (DMAC_CHCTRLB_CMD_RESUME_Val << DMAC_CHCTRLB_CMD_Pos) +#define DMAC_CHCTRLB_MASK 0x03C03F7Fu /**< \brief (DMAC_CHCTRLB) MASK Register */ + +/* -------- DMAC_CHINTENCLR : (DMAC Offset: 0x4C) (R/W 8) Channel Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t TERR:1; /*!< bit: 0 Transfer Error Interrupt Enable */ + uint8_t TCMPL:1; /*!< bit: 1 Transfer Complete Interrupt Enable */ + uint8_t SUSP:1; /*!< bit: 2 Channel Suspend Interrupt Enable */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DMAC_CHINTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CHINTENCLR_OFFSET 0x4C /**< \brief (DMAC_CHINTENCLR offset) Channel Interrupt Enable Clear */ +#define DMAC_CHINTENCLR_RESETVALUE 0x00 /**< \brief (DMAC_CHINTENCLR reset_value) Channel Interrupt Enable Clear */ + +#define DMAC_CHINTENCLR_TERR_Pos 0 /**< \brief (DMAC_CHINTENCLR) Transfer Error Interrupt Enable */ +#define DMAC_CHINTENCLR_TERR (0x1u << DMAC_CHINTENCLR_TERR_Pos) +#define DMAC_CHINTENCLR_TCMPL_Pos 1 /**< \brief (DMAC_CHINTENCLR) Transfer Complete Interrupt Enable */ +#define DMAC_CHINTENCLR_TCMPL (0x1u << DMAC_CHINTENCLR_TCMPL_Pos) +#define DMAC_CHINTENCLR_SUSP_Pos 2 /**< \brief (DMAC_CHINTENCLR) Channel Suspend Interrupt Enable */ +#define DMAC_CHINTENCLR_SUSP (0x1u << DMAC_CHINTENCLR_SUSP_Pos) +#define DMAC_CHINTENCLR_MASK 0x07u /**< \brief (DMAC_CHINTENCLR) MASK Register */ + +/* -------- DMAC_CHINTENSET : (DMAC Offset: 0x4D) (R/W 8) Channel Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t TERR:1; /*!< bit: 0 Transfer Error Interrupt Enable */ + uint8_t TCMPL:1; /*!< bit: 1 Transfer Complete Interrupt Enable */ + uint8_t SUSP:1; /*!< bit: 2 Channel Suspend Interrupt Enable */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DMAC_CHINTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CHINTENSET_OFFSET 0x4D /**< \brief (DMAC_CHINTENSET offset) Channel Interrupt Enable Set */ +#define DMAC_CHINTENSET_RESETVALUE 0x00 /**< \brief (DMAC_CHINTENSET reset_value) Channel Interrupt Enable Set */ + +#define DMAC_CHINTENSET_TERR_Pos 0 /**< \brief (DMAC_CHINTENSET) Transfer Error Interrupt Enable */ +#define DMAC_CHINTENSET_TERR (0x1u << DMAC_CHINTENSET_TERR_Pos) +#define DMAC_CHINTENSET_TCMPL_Pos 1 /**< \brief (DMAC_CHINTENSET) Transfer Complete Interrupt Enable */ +#define DMAC_CHINTENSET_TCMPL (0x1u << DMAC_CHINTENSET_TCMPL_Pos) +#define DMAC_CHINTENSET_SUSP_Pos 2 /**< \brief (DMAC_CHINTENSET) Channel Suspend Interrupt Enable */ +#define DMAC_CHINTENSET_SUSP (0x1u << DMAC_CHINTENSET_SUSP_Pos) +#define DMAC_CHINTENSET_MASK 0x07u /**< \brief (DMAC_CHINTENSET) MASK Register */ + +/* -------- DMAC_CHINTFLAG : (DMAC Offset: 0x4E) (R/W 8) Channel Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t TERR:1; /*!< bit: 0 Transfer Error */ + uint8_t TCMPL:1; /*!< bit: 1 Transfer Complete */ + uint8_t SUSP:1; /*!< bit: 2 Channel Suspend */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DMAC_CHINTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CHINTFLAG_OFFSET 0x4E /**< \brief (DMAC_CHINTFLAG offset) Channel Interrupt Flag Status and Clear */ +#define DMAC_CHINTFLAG_RESETVALUE 0x00 /**< \brief (DMAC_CHINTFLAG reset_value) Channel Interrupt Flag Status and Clear */ + +#define DMAC_CHINTFLAG_TERR_Pos 0 /**< \brief (DMAC_CHINTFLAG) Transfer Error */ +#define DMAC_CHINTFLAG_TERR (0x1u << DMAC_CHINTFLAG_TERR_Pos) +#define DMAC_CHINTFLAG_TCMPL_Pos 1 /**< \brief (DMAC_CHINTFLAG) Transfer Complete */ +#define DMAC_CHINTFLAG_TCMPL (0x1u << DMAC_CHINTFLAG_TCMPL_Pos) +#define DMAC_CHINTFLAG_SUSP_Pos 2 /**< \brief (DMAC_CHINTFLAG) Channel Suspend */ +#define DMAC_CHINTFLAG_SUSP (0x1u << DMAC_CHINTFLAG_SUSP_Pos) +#define DMAC_CHINTFLAG_MASK 0x07u /**< \brief (DMAC_CHINTFLAG) MASK Register */ + +/* -------- DMAC_CHSTATUS : (DMAC Offset: 0x4F) (R/ 8) Channel Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PEND:1; /*!< bit: 0 Channel Pending */ + uint8_t BUSY:1; /*!< bit: 1 Channel Busy */ + uint8_t FERR:1; /*!< bit: 2 Fetch Error */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DMAC_CHSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_CHSTATUS_OFFSET 0x4F /**< \brief (DMAC_CHSTATUS offset) Channel Status */ +#define DMAC_CHSTATUS_RESETVALUE 0x00 /**< \brief (DMAC_CHSTATUS reset_value) Channel Status */ + +#define DMAC_CHSTATUS_PEND_Pos 0 /**< \brief (DMAC_CHSTATUS) Channel Pending */ +#define DMAC_CHSTATUS_PEND (0x1u << DMAC_CHSTATUS_PEND_Pos) +#define DMAC_CHSTATUS_BUSY_Pos 1 /**< \brief (DMAC_CHSTATUS) Channel Busy */ +#define DMAC_CHSTATUS_BUSY (0x1u << DMAC_CHSTATUS_BUSY_Pos) +#define DMAC_CHSTATUS_FERR_Pos 2 /**< \brief (DMAC_CHSTATUS) Fetch Error */ +#define DMAC_CHSTATUS_FERR (0x1u << DMAC_CHSTATUS_FERR_Pos) +#define DMAC_CHSTATUS_MASK 0x07u /**< \brief (DMAC_CHSTATUS) MASK Register */ + +/* -------- DMAC_BTCTRL : (DMAC Offset: 0x00) (R/W 16) Block Transfer Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t VALID:1; /*!< bit: 0 Descriptor Valid */ + uint16_t EVOSEL:2; /*!< bit: 1.. 2 Event Output Selection */ + uint16_t BLOCKACT:2; /*!< bit: 3.. 4 Block Action */ + uint16_t :3; /*!< bit: 5.. 7 Reserved */ + uint16_t BEATSIZE:2; /*!< bit: 8.. 9 Beat Size */ + uint16_t SRCINC:1; /*!< bit: 10 Source Address Increment Enable */ + uint16_t DSTINC:1; /*!< bit: 11 Destination Address Increment Enable */ + uint16_t STEPSEL:1; /*!< bit: 12 Step Selection */ + uint16_t STEPSIZE:3; /*!< bit: 13..15 Address Increment Step Size */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} DMAC_BTCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_BTCTRL_OFFSET 0x00 /**< \brief (DMAC_BTCTRL offset) Block Transfer Control */ + +#define DMAC_BTCTRL_VALID_Pos 0 /**< \brief (DMAC_BTCTRL) Descriptor Valid */ +#define DMAC_BTCTRL_VALID (0x1u << DMAC_BTCTRL_VALID_Pos) +#define DMAC_BTCTRL_EVOSEL_Pos 1 /**< \brief (DMAC_BTCTRL) Event Output Selection */ +#define DMAC_BTCTRL_EVOSEL_Msk (0x3u << DMAC_BTCTRL_EVOSEL_Pos) +#define DMAC_BTCTRL_EVOSEL(value) ((DMAC_BTCTRL_EVOSEL_Msk & ((value) << DMAC_BTCTRL_EVOSEL_Pos))) +#define DMAC_BTCTRL_EVOSEL_DISABLE_Val 0x0u /**< \brief (DMAC_BTCTRL) Event generation disabled */ +#define DMAC_BTCTRL_EVOSEL_BLOCK_Val 0x1u /**< \brief (DMAC_BTCTRL) Event strobe when block transfer complete */ +#define DMAC_BTCTRL_EVOSEL_BEAT_Val 0x3u /**< \brief (DMAC_BTCTRL) Event strobe when beat transfer complete */ +#define DMAC_BTCTRL_EVOSEL_DISABLE (DMAC_BTCTRL_EVOSEL_DISABLE_Val << DMAC_BTCTRL_EVOSEL_Pos) +#define DMAC_BTCTRL_EVOSEL_BLOCK (DMAC_BTCTRL_EVOSEL_BLOCK_Val << DMAC_BTCTRL_EVOSEL_Pos) +#define DMAC_BTCTRL_EVOSEL_BEAT (DMAC_BTCTRL_EVOSEL_BEAT_Val << DMAC_BTCTRL_EVOSEL_Pos) +#define DMAC_BTCTRL_BLOCKACT_Pos 3 /**< \brief (DMAC_BTCTRL) Block Action */ +#define DMAC_BTCTRL_BLOCKACT_Msk (0x3u << DMAC_BTCTRL_BLOCKACT_Pos) +#define DMAC_BTCTRL_BLOCKACT(value) ((DMAC_BTCTRL_BLOCKACT_Msk & ((value) << DMAC_BTCTRL_BLOCKACT_Pos))) +#define DMAC_BTCTRL_BLOCKACT_NOACT_Val 0x0u /**< \brief (DMAC_BTCTRL) No action */ +#define DMAC_BTCTRL_BLOCKACT_INT_Val 0x1u /**< \brief (DMAC_BTCTRL) Channel in normal operation and block interrupt */ +#define DMAC_BTCTRL_BLOCKACT_SUSPEND_Val 0x2u /**< \brief (DMAC_BTCTRL) Channel suspend operation is completed */ +#define DMAC_BTCTRL_BLOCKACT_BOTH_Val 0x3u /**< \brief (DMAC_BTCTRL) Both channel suspend operation and block interrupt */ +#define DMAC_BTCTRL_BLOCKACT_NOACT (DMAC_BTCTRL_BLOCKACT_NOACT_Val << DMAC_BTCTRL_BLOCKACT_Pos) +#define DMAC_BTCTRL_BLOCKACT_INT (DMAC_BTCTRL_BLOCKACT_INT_Val << DMAC_BTCTRL_BLOCKACT_Pos) +#define DMAC_BTCTRL_BLOCKACT_SUSPEND (DMAC_BTCTRL_BLOCKACT_SUSPEND_Val << DMAC_BTCTRL_BLOCKACT_Pos) +#define DMAC_BTCTRL_BLOCKACT_BOTH (DMAC_BTCTRL_BLOCKACT_BOTH_Val << DMAC_BTCTRL_BLOCKACT_Pos) +#define DMAC_BTCTRL_BEATSIZE_Pos 8 /**< \brief (DMAC_BTCTRL) Beat Size */ +#define DMAC_BTCTRL_BEATSIZE_Msk (0x3u << DMAC_BTCTRL_BEATSIZE_Pos) +#define DMAC_BTCTRL_BEATSIZE(value) ((DMAC_BTCTRL_BEATSIZE_Msk & ((value) << DMAC_BTCTRL_BEATSIZE_Pos))) +#define DMAC_BTCTRL_BEATSIZE_BYTE_Val 0x0u /**< \brief (DMAC_BTCTRL) 8-bit access */ +#define DMAC_BTCTRL_BEATSIZE_HWORD_Val 0x1u /**< \brief (DMAC_BTCTRL) 16-bit access */ +#define DMAC_BTCTRL_BEATSIZE_WORD_Val 0x2u /**< \brief (DMAC_BTCTRL) 32-bit access */ +#define DMAC_BTCTRL_BEATSIZE_BYTE (DMAC_BTCTRL_BEATSIZE_BYTE_Val << DMAC_BTCTRL_BEATSIZE_Pos) +#define DMAC_BTCTRL_BEATSIZE_HWORD (DMAC_BTCTRL_BEATSIZE_HWORD_Val << DMAC_BTCTRL_BEATSIZE_Pos) +#define DMAC_BTCTRL_BEATSIZE_WORD (DMAC_BTCTRL_BEATSIZE_WORD_Val << DMAC_BTCTRL_BEATSIZE_Pos) +#define DMAC_BTCTRL_SRCINC_Pos 10 /**< \brief (DMAC_BTCTRL) Source Address Increment Enable */ +#define DMAC_BTCTRL_SRCINC (0x1u << DMAC_BTCTRL_SRCINC_Pos) +#define DMAC_BTCTRL_DSTINC_Pos 11 /**< \brief (DMAC_BTCTRL) Destination Address Increment Enable */ +#define DMAC_BTCTRL_DSTINC (0x1u << DMAC_BTCTRL_DSTINC_Pos) +#define DMAC_BTCTRL_STEPSEL_Pos 12 /**< \brief (DMAC_BTCTRL) Step Selection */ +#define DMAC_BTCTRL_STEPSEL (0x1u << DMAC_BTCTRL_STEPSEL_Pos) +#define DMAC_BTCTRL_STEPSEL_DST_Val 0x0u /**< \brief (DMAC_BTCTRL) Step size settings apply to the destination address */ +#define DMAC_BTCTRL_STEPSEL_SRC_Val 0x1u /**< \brief (DMAC_BTCTRL) Step size settings apply to the source address */ +#define DMAC_BTCTRL_STEPSEL_DST (DMAC_BTCTRL_STEPSEL_DST_Val << DMAC_BTCTRL_STEPSEL_Pos) +#define DMAC_BTCTRL_STEPSEL_SRC (DMAC_BTCTRL_STEPSEL_SRC_Val << DMAC_BTCTRL_STEPSEL_Pos) +#define DMAC_BTCTRL_STEPSIZE_Pos 13 /**< \brief (DMAC_BTCTRL) Address Increment Step Size */ +#define DMAC_BTCTRL_STEPSIZE_Msk (0x7u << DMAC_BTCTRL_STEPSIZE_Pos) +#define DMAC_BTCTRL_STEPSIZE(value) ((DMAC_BTCTRL_STEPSIZE_Msk & ((value) << DMAC_BTCTRL_STEPSIZE_Pos))) +#define DMAC_BTCTRL_STEPSIZE_X1_Val 0x0u /**< \brief (DMAC_BTCTRL) Next ADDR <- ADDR + BEATSIZE * 1 */ +#define DMAC_BTCTRL_STEPSIZE_X2_Val 0x1u /**< \brief (DMAC_BTCTRL) Next ADDR <- ADDR + BEATSIZE * 2 */ +#define DMAC_BTCTRL_STEPSIZE_X4_Val 0x2u /**< \brief (DMAC_BTCTRL) Next ADDR <- ADDR + BEATSIZE * 4 */ +#define DMAC_BTCTRL_STEPSIZE_X8_Val 0x3u /**< \brief (DMAC_BTCTRL) Next ADDR <- ADDR + BEATSIZE * 8 */ +#define DMAC_BTCTRL_STEPSIZE_X16_Val 0x4u /**< \brief (DMAC_BTCTRL) Next ADDR <- ADDR + BEATSIZE * 16 */ +#define DMAC_BTCTRL_STEPSIZE_X32_Val 0x5u /**< \brief (DMAC_BTCTRL) Next ADDR <- ADDR + BEATSIZE * 32 */ +#define DMAC_BTCTRL_STEPSIZE_X64_Val 0x6u /**< \brief (DMAC_BTCTRL) Next ADDR <- ADDR + BEATSIZE * 64 */ +#define DMAC_BTCTRL_STEPSIZE_X128_Val 0x7u /**< \brief (DMAC_BTCTRL) Next ADDR <- ADDR + BEATSIZE * 128 */ +#define DMAC_BTCTRL_STEPSIZE_X1 (DMAC_BTCTRL_STEPSIZE_X1_Val << DMAC_BTCTRL_STEPSIZE_Pos) +#define DMAC_BTCTRL_STEPSIZE_X2 (DMAC_BTCTRL_STEPSIZE_X2_Val << DMAC_BTCTRL_STEPSIZE_Pos) +#define DMAC_BTCTRL_STEPSIZE_X4 (DMAC_BTCTRL_STEPSIZE_X4_Val << DMAC_BTCTRL_STEPSIZE_Pos) +#define DMAC_BTCTRL_STEPSIZE_X8 (DMAC_BTCTRL_STEPSIZE_X8_Val << DMAC_BTCTRL_STEPSIZE_Pos) +#define DMAC_BTCTRL_STEPSIZE_X16 (DMAC_BTCTRL_STEPSIZE_X16_Val << DMAC_BTCTRL_STEPSIZE_Pos) +#define DMAC_BTCTRL_STEPSIZE_X32 (DMAC_BTCTRL_STEPSIZE_X32_Val << DMAC_BTCTRL_STEPSIZE_Pos) +#define DMAC_BTCTRL_STEPSIZE_X64 (DMAC_BTCTRL_STEPSIZE_X64_Val << DMAC_BTCTRL_STEPSIZE_Pos) +#define DMAC_BTCTRL_STEPSIZE_X128 (DMAC_BTCTRL_STEPSIZE_X128_Val << DMAC_BTCTRL_STEPSIZE_Pos) +#define DMAC_BTCTRL_MASK 0xFF1Fu /**< \brief (DMAC_BTCTRL) MASK Register */ + +/* -------- DMAC_BTCNT : (DMAC Offset: 0x02) (R/W 16) Block Transfer Count -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t BTCNT:16; /*!< bit: 0..15 Block Transfer Count */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} DMAC_BTCNT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_BTCNT_OFFSET 0x02 /**< \brief (DMAC_BTCNT offset) Block Transfer Count */ + +#define DMAC_BTCNT_BTCNT_Pos 0 /**< \brief (DMAC_BTCNT) Block Transfer Count */ +#define DMAC_BTCNT_BTCNT_Msk (0xFFFFu << DMAC_BTCNT_BTCNT_Pos) +#define DMAC_BTCNT_BTCNT(value) ((DMAC_BTCNT_BTCNT_Msk & ((value) << DMAC_BTCNT_BTCNT_Pos))) +#define DMAC_BTCNT_MASK 0xFFFFu /**< \brief (DMAC_BTCNT) MASK Register */ + +/* -------- DMAC_SRCADDR : (DMAC Offset: 0x04) (R/W 32) Transfer Source Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SRCADDR:32; /*!< bit: 0..31 Transfer Source Address */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_SRCADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_SRCADDR_OFFSET 0x04 /**< \brief (DMAC_SRCADDR offset) Transfer Source Address */ + +#define DMAC_SRCADDR_SRCADDR_Pos 0 /**< \brief (DMAC_SRCADDR) Transfer Source Address */ +#define DMAC_SRCADDR_SRCADDR_Msk (0xFFFFFFFFu << DMAC_SRCADDR_SRCADDR_Pos) +#define DMAC_SRCADDR_SRCADDR(value) ((DMAC_SRCADDR_SRCADDR_Msk & ((value) << DMAC_SRCADDR_SRCADDR_Pos))) +#define DMAC_SRCADDR_MASK 0xFFFFFFFFu /**< \brief (DMAC_SRCADDR) MASK Register */ + +/* -------- DMAC_DSTADDR : (DMAC Offset: 0x08) (R/W 32) Transfer Destination Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DSTADDR:32; /*!< bit: 0..31 Transfer Destination Address */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_DSTADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_DSTADDR_OFFSET 0x08 /**< \brief (DMAC_DSTADDR offset) Transfer Destination Address */ + +#define DMAC_DSTADDR_DSTADDR_Pos 0 /**< \brief (DMAC_DSTADDR) Transfer Destination Address */ +#define DMAC_DSTADDR_DSTADDR_Msk (0xFFFFFFFFu << DMAC_DSTADDR_DSTADDR_Pos) +#define DMAC_DSTADDR_DSTADDR(value) ((DMAC_DSTADDR_DSTADDR_Msk & ((value) << DMAC_DSTADDR_DSTADDR_Pos))) +#define DMAC_DSTADDR_MASK 0xFFFFFFFFu /**< \brief (DMAC_DSTADDR) MASK Register */ + +/* -------- DMAC_DESCADDR : (DMAC Offset: 0x0C) (R/W 32) Next Descriptor Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DESCADDR:32; /*!< bit: 0..31 Next Descriptor Address */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DMAC_DESCADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DMAC_DESCADDR_OFFSET 0x0C /**< \brief (DMAC_DESCADDR offset) Next Descriptor Address */ + +#define DMAC_DESCADDR_DESCADDR_Pos 0 /**< \brief (DMAC_DESCADDR) Next Descriptor Address */ +#define DMAC_DESCADDR_DESCADDR_Msk (0xFFFFFFFFu << DMAC_DESCADDR_DESCADDR_Pos) +#define DMAC_DESCADDR_DESCADDR(value) ((DMAC_DESCADDR_DESCADDR_Msk & ((value) << DMAC_DESCADDR_DESCADDR_Pos))) +#define DMAC_DESCADDR_MASK 0xFFFFFFFFu /**< \brief (DMAC_DESCADDR) MASK Register */ + +/** \brief DMAC APB hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO DMAC_CTRL_Type CTRL; /**< \brief Offset: 0x00 (R/W 16) Control */ + __IO DMAC_CRCCTRL_Type CRCCTRL; /**< \brief Offset: 0x02 (R/W 16) CRC Control */ + __IO DMAC_CRCDATAIN_Type CRCDATAIN; /**< \brief Offset: 0x04 (R/W 32) CRC Data Input */ + __IO DMAC_CRCCHKSUM_Type CRCCHKSUM; /**< \brief Offset: 0x08 (R/W 32) CRC Checksum */ + __IO DMAC_CRCSTATUS_Type CRCSTATUS; /**< \brief Offset: 0x0C (R/W 8) CRC Status */ + __IO DMAC_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x0D (R/W 8) Debug Control */ + RoReg8 Reserved1[0x2]; + __IO DMAC_SWTRIGCTRL_Type SWTRIGCTRL; /**< \brief Offset: 0x10 (R/W 32) Software Trigger Control */ + __IO DMAC_PRICTRL0_Type PRICTRL0; /**< \brief Offset: 0x14 (R/W 32) Priority Control 0 */ + RoReg8 Reserved2[0x8]; + __IO DMAC_INTPEND_Type INTPEND; /**< \brief Offset: 0x20 (R/W 16) Interrupt Pending */ + RoReg8 Reserved3[0x2]; + __I DMAC_INTSTATUS_Type INTSTATUS; /**< \brief Offset: 0x24 (R/ 32) Interrupt Status */ + __I DMAC_BUSYCH_Type BUSYCH; /**< \brief Offset: 0x28 (R/ 32) Busy Channels */ + __I DMAC_PENDCH_Type PENDCH; /**< \brief Offset: 0x2C (R/ 32) Pending Channels */ + __I DMAC_ACTIVE_Type ACTIVE; /**< \brief Offset: 0x30 (R/ 32) Active Channel and Levels */ + __IO DMAC_BASEADDR_Type BASEADDR; /**< \brief Offset: 0x34 (R/W 32) Descriptor Memory Section Base Address */ + __IO DMAC_WRBADDR_Type WRBADDR; /**< \brief Offset: 0x38 (R/W 32) Write-Back Memory Section Base Address */ + RoReg8 Reserved4[0x3]; + __IO DMAC_CHID_Type CHID; /**< \brief Offset: 0x3F (R/W 8) Channel ID */ + __IO DMAC_CHCTRLA_Type CHCTRLA; /**< \brief Offset: 0x40 (R/W 8) Channel Control A */ + RoReg8 Reserved5[0x3]; + __IO DMAC_CHCTRLB_Type CHCTRLB; /**< \brief Offset: 0x44 (R/W 32) Channel Control B */ + RoReg8 Reserved6[0x4]; + __IO DMAC_CHINTENCLR_Type CHINTENCLR; /**< \brief Offset: 0x4C (R/W 8) Channel Interrupt Enable Clear */ + __IO DMAC_CHINTENSET_Type CHINTENSET; /**< \brief Offset: 0x4D (R/W 8) Channel Interrupt Enable Set */ + __IO DMAC_CHINTFLAG_Type CHINTFLAG; /**< \brief Offset: 0x4E (R/W 8) Channel Interrupt Flag Status and Clear */ + __I DMAC_CHSTATUS_Type CHSTATUS; /**< \brief Offset: 0x4F (R/ 8) Channel Status */ +} Dmac; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief DMAC Descriptor SRAM registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO DMAC_BTCTRL_Type BTCTRL; /**< \brief Offset: 0x00 (R/W 16) Block Transfer Control */ + __IO DMAC_BTCNT_Type BTCNT; /**< \brief Offset: 0x02 (R/W 16) Block Transfer Count */ + __IO DMAC_SRCADDR_Type SRCADDR; /**< \brief Offset: 0x04 (R/W 32) Transfer Source Address */ + __IO DMAC_DSTADDR_Type DSTADDR; /**< \brief Offset: 0x08 (R/W 32) Transfer Destination Address */ + __IO DMAC_DESCADDR_Type DESCADDR; /**< \brief Offset: 0x0C (R/W 32) Next Descriptor Address */ +} DmacDescriptor +#ifdef __GNUC__ + __attribute__ ((aligned (8))) +#endif +; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +#define SECTION_DMAC_DESCRIPTOR + +/*@}*/ + +#endif /* _SAMD21_DMAC_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/dsu.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/dsu.h new file mode 100755 index 0000000..3e5eb60 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/dsu.h @@ -0,0 +1,551 @@ +/** + * \file + * + * \brief Component description for DSU + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_DSU_COMPONENT_ +#define _SAMD21_DSU_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR DSU */ +/* ========================================================================== */ +/** \addtogroup SAMD21_DSU Device Service Unit */ +/*@{*/ + +#define DSU_U2209 +#define REV_DSU 0x200 + +/* -------- DSU_CTRL : (DSU Offset: 0x0000) ( /W 8) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset */ + uint8_t :1; /*!< bit: 1 Reserved */ + uint8_t CRC:1; /*!< bit: 2 32-bit Cyclic Redundancy Check */ + uint8_t MBIST:1; /*!< bit: 3 Memory Built-In Self-Test */ + uint8_t CE:1; /*!< bit: 4 Chip Erase */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DSU_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_CTRL_OFFSET 0x0000 /**< \brief (DSU_CTRL offset) Control */ +#define DSU_CTRL_RESETVALUE 0x00 /**< \brief (DSU_CTRL reset_value) Control */ + +#define DSU_CTRL_SWRST_Pos 0 /**< \brief (DSU_CTRL) Software Reset */ +#define DSU_CTRL_SWRST (0x1u << DSU_CTRL_SWRST_Pos) +#define DSU_CTRL_CRC_Pos 2 /**< \brief (DSU_CTRL) 32-bit Cyclic Redundancy Check */ +#define DSU_CTRL_CRC (0x1u << DSU_CTRL_CRC_Pos) +#define DSU_CTRL_MBIST_Pos 3 /**< \brief (DSU_CTRL) Memory Built-In Self-Test */ +#define DSU_CTRL_MBIST (0x1u << DSU_CTRL_MBIST_Pos) +#define DSU_CTRL_CE_Pos 4 /**< \brief (DSU_CTRL) Chip Erase */ +#define DSU_CTRL_CE (0x1u << DSU_CTRL_CE_Pos) +#define DSU_CTRL_MASK 0x1Du /**< \brief (DSU_CTRL) MASK Register */ + +/* -------- DSU_STATUSA : (DSU Offset: 0x0001) (R/W 8) Status A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DONE:1; /*!< bit: 0 Done */ + uint8_t CRSTEXT:1; /*!< bit: 1 CPU Reset Phase Extension */ + uint8_t BERR:1; /*!< bit: 2 Bus Error */ + uint8_t FAIL:1; /*!< bit: 3 Failure */ + uint8_t PERR:1; /*!< bit: 4 Protection Error */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} DSU_STATUSA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_STATUSA_OFFSET 0x0001 /**< \brief (DSU_STATUSA offset) Status A */ +#define DSU_STATUSA_RESETVALUE 0x00 /**< \brief (DSU_STATUSA reset_value) Status A */ + +#define DSU_STATUSA_DONE_Pos 0 /**< \brief (DSU_STATUSA) Done */ +#define DSU_STATUSA_DONE (0x1u << DSU_STATUSA_DONE_Pos) +#define DSU_STATUSA_CRSTEXT_Pos 1 /**< \brief (DSU_STATUSA) CPU Reset Phase Extension */ +#define DSU_STATUSA_CRSTEXT (0x1u << DSU_STATUSA_CRSTEXT_Pos) +#define DSU_STATUSA_BERR_Pos 2 /**< \brief (DSU_STATUSA) Bus Error */ +#define DSU_STATUSA_BERR (0x1u << DSU_STATUSA_BERR_Pos) +#define DSU_STATUSA_FAIL_Pos 3 /**< \brief (DSU_STATUSA) Failure */ +#define DSU_STATUSA_FAIL (0x1u << DSU_STATUSA_FAIL_Pos) +#define DSU_STATUSA_PERR_Pos 4 /**< \brief (DSU_STATUSA) Protection Error */ +#define DSU_STATUSA_PERR (0x1u << DSU_STATUSA_PERR_Pos) +#define DSU_STATUSA_MASK 0x1Fu /**< \brief (DSU_STATUSA) MASK Register */ + +/* -------- DSU_STATUSB : (DSU Offset: 0x0002) (R/ 8) Status B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PROT:1; /*!< bit: 0 Protected */ + uint8_t DBGPRES:1; /*!< bit: 1 Debugger Present */ + uint8_t DCCD0:1; /*!< bit: 2 Debug Communication Channel 0 Dirty */ + uint8_t DCCD1:1; /*!< bit: 3 Debug Communication Channel 1 Dirty */ + uint8_t HPE:1; /*!< bit: 4 Hot-Plugging Enable */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t :2; /*!< bit: 0.. 1 Reserved */ + uint8_t DCCD:2; /*!< bit: 2.. 3 Debug Communication Channel x Dirty */ + uint8_t :4; /*!< bit: 4.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} DSU_STATUSB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_STATUSB_OFFSET 0x0002 /**< \brief (DSU_STATUSB offset) Status B */ +#define DSU_STATUSB_RESETVALUE 0x10 /**< \brief (DSU_STATUSB reset_value) Status B */ + +#define DSU_STATUSB_PROT_Pos 0 /**< \brief (DSU_STATUSB) Protected */ +#define DSU_STATUSB_PROT (0x1u << DSU_STATUSB_PROT_Pos) +#define DSU_STATUSB_DBGPRES_Pos 1 /**< \brief (DSU_STATUSB) Debugger Present */ +#define DSU_STATUSB_DBGPRES (0x1u << DSU_STATUSB_DBGPRES_Pos) +#define DSU_STATUSB_DCCD0_Pos 2 /**< \brief (DSU_STATUSB) Debug Communication Channel 0 Dirty */ +#define DSU_STATUSB_DCCD0 (1 << DSU_STATUSB_DCCD0_Pos) +#define DSU_STATUSB_DCCD1_Pos 3 /**< \brief (DSU_STATUSB) Debug Communication Channel 1 Dirty */ +#define DSU_STATUSB_DCCD1 (1 << DSU_STATUSB_DCCD1_Pos) +#define DSU_STATUSB_DCCD_Pos 2 /**< \brief (DSU_STATUSB) Debug Communication Channel x Dirty */ +#define DSU_STATUSB_DCCD_Msk (0x3u << DSU_STATUSB_DCCD_Pos) +#define DSU_STATUSB_DCCD(value) ((DSU_STATUSB_DCCD_Msk & ((value) << DSU_STATUSB_DCCD_Pos))) +#define DSU_STATUSB_HPE_Pos 4 /**< \brief (DSU_STATUSB) Hot-Plugging Enable */ +#define DSU_STATUSB_HPE (0x1u << DSU_STATUSB_HPE_Pos) +#define DSU_STATUSB_MASK 0x1Fu /**< \brief (DSU_STATUSB) MASK Register */ + +/* -------- DSU_ADDR : (DSU Offset: 0x0004) (R/W 32) Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :2; /*!< bit: 0.. 1 Reserved */ + uint32_t ADDR:30; /*!< bit: 2..31 Address */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_ADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_ADDR_OFFSET 0x0004 /**< \brief (DSU_ADDR offset) Address */ +#define DSU_ADDR_RESETVALUE 0x00000000 /**< \brief (DSU_ADDR reset_value) Address */ + +#define DSU_ADDR_ADDR_Pos 2 /**< \brief (DSU_ADDR) Address */ +#define DSU_ADDR_ADDR_Msk (0x3FFFFFFFu << DSU_ADDR_ADDR_Pos) +#define DSU_ADDR_ADDR(value) ((DSU_ADDR_ADDR_Msk & ((value) << DSU_ADDR_ADDR_Pos))) +#define DSU_ADDR_MASK 0xFFFFFFFCu /**< \brief (DSU_ADDR) MASK Register */ + +/* -------- DSU_LENGTH : (DSU Offset: 0x0008) (R/W 32) Length -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :2; /*!< bit: 0.. 1 Reserved */ + uint32_t LENGTH:30; /*!< bit: 2..31 Length */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_LENGTH_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_LENGTH_OFFSET 0x0008 /**< \brief (DSU_LENGTH offset) Length */ +#define DSU_LENGTH_RESETVALUE 0x00000000 /**< \brief (DSU_LENGTH reset_value) Length */ + +#define DSU_LENGTH_LENGTH_Pos 2 /**< \brief (DSU_LENGTH) Length */ +#define DSU_LENGTH_LENGTH_Msk (0x3FFFFFFFu << DSU_LENGTH_LENGTH_Pos) +#define DSU_LENGTH_LENGTH(value) ((DSU_LENGTH_LENGTH_Msk & ((value) << DSU_LENGTH_LENGTH_Pos))) +#define DSU_LENGTH_MASK 0xFFFFFFFCu /**< \brief (DSU_LENGTH) MASK Register */ + +/* -------- DSU_DATA : (DSU Offset: 0x000C) (R/W 32) Data -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DATA:32; /*!< bit: 0..31 Data */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_DATA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_DATA_OFFSET 0x000C /**< \brief (DSU_DATA offset) Data */ +#define DSU_DATA_RESETVALUE 0x00000000 /**< \brief (DSU_DATA reset_value) Data */ + +#define DSU_DATA_DATA_Pos 0 /**< \brief (DSU_DATA) Data */ +#define DSU_DATA_DATA_Msk (0xFFFFFFFFu << DSU_DATA_DATA_Pos) +#define DSU_DATA_DATA(value) ((DSU_DATA_DATA_Msk & ((value) << DSU_DATA_DATA_Pos))) +#define DSU_DATA_MASK 0xFFFFFFFFu /**< \brief (DSU_DATA) MASK Register */ + +/* -------- DSU_DCC : (DSU Offset: 0x0010) (R/W 32) Debug Communication Channel n -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DATA:32; /*!< bit: 0..31 Data */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_DCC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_DCC_OFFSET 0x0010 /**< \brief (DSU_DCC offset) Debug Communication Channel n */ +#define DSU_DCC_RESETVALUE 0x00000000 /**< \brief (DSU_DCC reset_value) Debug Communication Channel n */ + +#define DSU_DCC_DATA_Pos 0 /**< \brief (DSU_DCC) Data */ +#define DSU_DCC_DATA_Msk (0xFFFFFFFFu << DSU_DCC_DATA_Pos) +#define DSU_DCC_DATA(value) ((DSU_DCC_DATA_Msk & ((value) << DSU_DCC_DATA_Pos))) +#define DSU_DCC_MASK 0xFFFFFFFFu /**< \brief (DSU_DCC) MASK Register */ + +/* -------- DSU_DID : (DSU Offset: 0x0018) (R/ 32) Device Identification -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DEVSEL:8; /*!< bit: 0.. 7 Device Select */ + uint32_t REVISION:4; /*!< bit: 8..11 Revision */ + uint32_t DIE:4; /*!< bit: 12..15 Die Identification */ + uint32_t SERIES:6; /*!< bit: 16..21 Product Series */ + uint32_t :1; /*!< bit: 22 Reserved */ + uint32_t FAMILY:5; /*!< bit: 23..27 Product Family */ + uint32_t PROCESSOR:4; /*!< bit: 28..31 Processor */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_DID_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_DID_OFFSET 0x0018 /**< \brief (DSU_DID offset) Device Identification */ + +#define DSU_DID_DEVSEL_Pos 0 /**< \brief (DSU_DID) Device Select */ +#define DSU_DID_DEVSEL_Msk (0xFFu << DSU_DID_DEVSEL_Pos) +#define DSU_DID_DEVSEL(value) ((DSU_DID_DEVSEL_Msk & ((value) << DSU_DID_DEVSEL_Pos))) +#define DSU_DID_REVISION_Pos 8 /**< \brief (DSU_DID) Revision */ +#define DSU_DID_REVISION_Msk (0xFu << DSU_DID_REVISION_Pos) +#define DSU_DID_REVISION(value) ((DSU_DID_REVISION_Msk & ((value) << DSU_DID_REVISION_Pos))) +#define DSU_DID_DIE_Pos 12 /**< \brief (DSU_DID) Die Identification */ +#define DSU_DID_DIE_Msk (0xFu << DSU_DID_DIE_Pos) +#define DSU_DID_DIE(value) ((DSU_DID_DIE_Msk & ((value) << DSU_DID_DIE_Pos))) +#define DSU_DID_SERIES_Pos 16 /**< \brief (DSU_DID) Product Series */ +#define DSU_DID_SERIES_Msk (0x3Fu << DSU_DID_SERIES_Pos) +#define DSU_DID_SERIES(value) ((DSU_DID_SERIES_Msk & ((value) << DSU_DID_SERIES_Pos))) +#define DSU_DID_FAMILY_Pos 23 /**< \brief (DSU_DID) Product Family */ +#define DSU_DID_FAMILY_Msk (0x1Fu << DSU_DID_FAMILY_Pos) +#define DSU_DID_FAMILY(value) ((DSU_DID_FAMILY_Msk & ((value) << DSU_DID_FAMILY_Pos))) +#define DSU_DID_PROCESSOR_Pos 28 /**< \brief (DSU_DID) Processor */ +#define DSU_DID_PROCESSOR_Msk (0xFu << DSU_DID_PROCESSOR_Pos) +#define DSU_DID_PROCESSOR(value) ((DSU_DID_PROCESSOR_Msk & ((value) << DSU_DID_PROCESSOR_Pos))) +#define DSU_DID_MASK 0xFFBFFFFFu /**< \brief (DSU_DID) MASK Register */ + +/* -------- DSU_ENTRY : (DSU Offset: 0x1000) (R/ 32) Coresight ROM Table Entry n -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t EPRES:1; /*!< bit: 0 Entry Present */ + uint32_t FMT:1; /*!< bit: 1 Format */ + uint32_t :10; /*!< bit: 2..11 Reserved */ + uint32_t ADDOFF:20; /*!< bit: 12..31 Address Offset */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_ENTRY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_ENTRY_OFFSET 0x1000 /**< \brief (DSU_ENTRY offset) Coresight ROM Table Entry n */ +#define DSU_ENTRY_RESETVALUE 0x00000002 /**< \brief (DSU_ENTRY reset_value) Coresight ROM Table Entry n */ + +#define DSU_ENTRY_EPRES_Pos 0 /**< \brief (DSU_ENTRY) Entry Present */ +#define DSU_ENTRY_EPRES (0x1u << DSU_ENTRY_EPRES_Pos) +#define DSU_ENTRY_FMT_Pos 1 /**< \brief (DSU_ENTRY) Format */ +#define DSU_ENTRY_FMT (0x1u << DSU_ENTRY_FMT_Pos) +#define DSU_ENTRY_ADDOFF_Pos 12 /**< \brief (DSU_ENTRY) Address Offset */ +#define DSU_ENTRY_ADDOFF_Msk (0xFFFFFu << DSU_ENTRY_ADDOFF_Pos) +#define DSU_ENTRY_ADDOFF(value) ((DSU_ENTRY_ADDOFF_Msk & ((value) << DSU_ENTRY_ADDOFF_Pos))) +#define DSU_ENTRY_MASK 0xFFFFF003u /**< \brief (DSU_ENTRY) MASK Register */ + +/* -------- DSU_END : (DSU Offset: 0x1008) (R/ 32) Coresight ROM Table End -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t END:32; /*!< bit: 0..31 End Marker */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_END_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_END_OFFSET 0x1008 /**< \brief (DSU_END offset) Coresight ROM Table End */ +#define DSU_END_RESETVALUE 0x00000000 /**< \brief (DSU_END reset_value) Coresight ROM Table End */ + +#define DSU_END_END_Pos 0 /**< \brief (DSU_END) End Marker */ +#define DSU_END_END_Msk (0xFFFFFFFFu << DSU_END_END_Pos) +#define DSU_END_END(value) ((DSU_END_END_Msk & ((value) << DSU_END_END_Pos))) +#define DSU_END_MASK 0xFFFFFFFFu /**< \brief (DSU_END) MASK Register */ + +/* -------- DSU_MEMTYPE : (DSU Offset: 0x1FCC) (R/ 32) Coresight ROM Table Memory Type -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SMEMP:1; /*!< bit: 0 System Memory Present */ + uint32_t :31; /*!< bit: 1..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_MEMTYPE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_MEMTYPE_OFFSET 0x1FCC /**< \brief (DSU_MEMTYPE offset) Coresight ROM Table Memory Type */ +#define DSU_MEMTYPE_RESETVALUE 0x00000000 /**< \brief (DSU_MEMTYPE reset_value) Coresight ROM Table Memory Type */ + +#define DSU_MEMTYPE_SMEMP_Pos 0 /**< \brief (DSU_MEMTYPE) System Memory Present */ +#define DSU_MEMTYPE_SMEMP (0x1u << DSU_MEMTYPE_SMEMP_Pos) +#define DSU_MEMTYPE_MASK 0x00000001u /**< \brief (DSU_MEMTYPE) MASK Register */ + +/* -------- DSU_PID4 : (DSU Offset: 0x1FD0) (R/ 32) Peripheral Identification 4 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t JEPCC:4; /*!< bit: 0.. 3 JEP-106 Continuation Code */ + uint32_t FKBC:4; /*!< bit: 4.. 7 4KB Count */ + uint32_t :24; /*!< bit: 8..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_PID4_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_PID4_OFFSET 0x1FD0 /**< \brief (DSU_PID4 offset) Peripheral Identification 4 */ +#define DSU_PID4_RESETVALUE 0x00000000 /**< \brief (DSU_PID4 reset_value) Peripheral Identification 4 */ + +#define DSU_PID4_JEPCC_Pos 0 /**< \brief (DSU_PID4) JEP-106 Continuation Code */ +#define DSU_PID4_JEPCC_Msk (0xFu << DSU_PID4_JEPCC_Pos) +#define DSU_PID4_JEPCC(value) ((DSU_PID4_JEPCC_Msk & ((value) << DSU_PID4_JEPCC_Pos))) +#define DSU_PID4_FKBC_Pos 4 /**< \brief (DSU_PID4) 4KB Count */ +#define DSU_PID4_FKBC_Msk (0xFu << DSU_PID4_FKBC_Pos) +#define DSU_PID4_FKBC(value) ((DSU_PID4_FKBC_Msk & ((value) << DSU_PID4_FKBC_Pos))) +#define DSU_PID4_MASK 0x000000FFu /**< \brief (DSU_PID4) MASK Register */ + +/* -------- DSU_PID0 : (DSU Offset: 0x1FE0) (R/ 32) Peripheral Identification 0 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PARTNBL:8; /*!< bit: 0.. 7 Part Number Low */ + uint32_t :24; /*!< bit: 8..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_PID0_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_PID0_OFFSET 0x1FE0 /**< \brief (DSU_PID0 offset) Peripheral Identification 0 */ +#define DSU_PID0_RESETVALUE 0x000000D0 /**< \brief (DSU_PID0 reset_value) Peripheral Identification 0 */ + +#define DSU_PID0_PARTNBL_Pos 0 /**< \brief (DSU_PID0) Part Number Low */ +#define DSU_PID0_PARTNBL_Msk (0xFFu << DSU_PID0_PARTNBL_Pos) +#define DSU_PID0_PARTNBL(value) ((DSU_PID0_PARTNBL_Msk & ((value) << DSU_PID0_PARTNBL_Pos))) +#define DSU_PID0_MASK 0x000000FFu /**< \brief (DSU_PID0) MASK Register */ + +/* -------- DSU_PID1 : (DSU Offset: 0x1FE4) (R/ 32) Peripheral Identification 1 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PARTNBH:4; /*!< bit: 0.. 3 Part Number High */ + uint32_t JEPIDCL:4; /*!< bit: 4.. 7 Low part of the JEP-106 Identity Code */ + uint32_t :24; /*!< bit: 8..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_PID1_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_PID1_OFFSET 0x1FE4 /**< \brief (DSU_PID1 offset) Peripheral Identification 1 */ +#define DSU_PID1_RESETVALUE 0x000000FC /**< \brief (DSU_PID1 reset_value) Peripheral Identification 1 */ + +#define DSU_PID1_PARTNBH_Pos 0 /**< \brief (DSU_PID1) Part Number High */ +#define DSU_PID1_PARTNBH_Msk (0xFu << DSU_PID1_PARTNBH_Pos) +#define DSU_PID1_PARTNBH(value) ((DSU_PID1_PARTNBH_Msk & ((value) << DSU_PID1_PARTNBH_Pos))) +#define DSU_PID1_JEPIDCL_Pos 4 /**< \brief (DSU_PID1) Low part of the JEP-106 Identity Code */ +#define DSU_PID1_JEPIDCL_Msk (0xFu << DSU_PID1_JEPIDCL_Pos) +#define DSU_PID1_JEPIDCL(value) ((DSU_PID1_JEPIDCL_Msk & ((value) << DSU_PID1_JEPIDCL_Pos))) +#define DSU_PID1_MASK 0x000000FFu /**< \brief (DSU_PID1) MASK Register */ + +/* -------- DSU_PID2 : (DSU Offset: 0x1FE8) (R/ 32) Peripheral Identification 2 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t JEPIDCH:3; /*!< bit: 0.. 2 JEP-106 Identity Code High */ + uint32_t JEPU:1; /*!< bit: 3 JEP-106 Identity Code is used */ + uint32_t REVISION:4; /*!< bit: 4.. 7 Revision Number */ + uint32_t :24; /*!< bit: 8..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_PID2_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_PID2_OFFSET 0x1FE8 /**< \brief (DSU_PID2 offset) Peripheral Identification 2 */ +#define DSU_PID2_RESETVALUE 0x00000009 /**< \brief (DSU_PID2 reset_value) Peripheral Identification 2 */ + +#define DSU_PID2_JEPIDCH_Pos 0 /**< \brief (DSU_PID2) JEP-106 Identity Code High */ +#define DSU_PID2_JEPIDCH_Msk (0x7u << DSU_PID2_JEPIDCH_Pos) +#define DSU_PID2_JEPIDCH(value) ((DSU_PID2_JEPIDCH_Msk & ((value) << DSU_PID2_JEPIDCH_Pos))) +#define DSU_PID2_JEPU_Pos 3 /**< \brief (DSU_PID2) JEP-106 Identity Code is used */ +#define DSU_PID2_JEPU (0x1u << DSU_PID2_JEPU_Pos) +#define DSU_PID2_REVISION_Pos 4 /**< \brief (DSU_PID2) Revision Number */ +#define DSU_PID2_REVISION_Msk (0xFu << DSU_PID2_REVISION_Pos) +#define DSU_PID2_REVISION(value) ((DSU_PID2_REVISION_Msk & ((value) << DSU_PID2_REVISION_Pos))) +#define DSU_PID2_MASK 0x000000FFu /**< \brief (DSU_PID2) MASK Register */ + +/* -------- DSU_PID3 : (DSU Offset: 0x1FEC) (R/ 32) Peripheral Identification 3 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CUSMOD:4; /*!< bit: 0.. 3 ARM CUSMOD */ + uint32_t REVAND:4; /*!< bit: 4.. 7 Revision Number */ + uint32_t :24; /*!< bit: 8..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_PID3_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_PID3_OFFSET 0x1FEC /**< \brief (DSU_PID3 offset) Peripheral Identification 3 */ +#define DSU_PID3_RESETVALUE 0x00000000 /**< \brief (DSU_PID3 reset_value) Peripheral Identification 3 */ + +#define DSU_PID3_CUSMOD_Pos 0 /**< \brief (DSU_PID3) ARM CUSMOD */ +#define DSU_PID3_CUSMOD_Msk (0xFu << DSU_PID3_CUSMOD_Pos) +#define DSU_PID3_CUSMOD(value) ((DSU_PID3_CUSMOD_Msk & ((value) << DSU_PID3_CUSMOD_Pos))) +#define DSU_PID3_REVAND_Pos 4 /**< \brief (DSU_PID3) Revision Number */ +#define DSU_PID3_REVAND_Msk (0xFu << DSU_PID3_REVAND_Pos) +#define DSU_PID3_REVAND(value) ((DSU_PID3_REVAND_Msk & ((value) << DSU_PID3_REVAND_Pos))) +#define DSU_PID3_MASK 0x000000FFu /**< \brief (DSU_PID3) MASK Register */ + +/* -------- DSU_CID0 : (DSU Offset: 0x1FF0) (R/ 32) Component Identification 0 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PREAMBLEB0:8; /*!< bit: 0.. 7 Preamble Byte 0 */ + uint32_t :24; /*!< bit: 8..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_CID0_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_CID0_OFFSET 0x1FF0 /**< \brief (DSU_CID0 offset) Component Identification 0 */ +#define DSU_CID0_RESETVALUE 0x0000000D /**< \brief (DSU_CID0 reset_value) Component Identification 0 */ + +#define DSU_CID0_PREAMBLEB0_Pos 0 /**< \brief (DSU_CID0) Preamble Byte 0 */ +#define DSU_CID0_PREAMBLEB0_Msk (0xFFu << DSU_CID0_PREAMBLEB0_Pos) +#define DSU_CID0_PREAMBLEB0(value) ((DSU_CID0_PREAMBLEB0_Msk & ((value) << DSU_CID0_PREAMBLEB0_Pos))) +#define DSU_CID0_MASK 0x000000FFu /**< \brief (DSU_CID0) MASK Register */ + +/* -------- DSU_CID1 : (DSU Offset: 0x1FF4) (R/ 32) Component Identification 1 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PREAMBLE:4; /*!< bit: 0.. 3 Preamble */ + uint32_t CCLASS:4; /*!< bit: 4.. 7 Component Class */ + uint32_t :24; /*!< bit: 8..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_CID1_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_CID1_OFFSET 0x1FF4 /**< \brief (DSU_CID1 offset) Component Identification 1 */ +#define DSU_CID1_RESETVALUE 0x00000010 /**< \brief (DSU_CID1 reset_value) Component Identification 1 */ + +#define DSU_CID1_PREAMBLE_Pos 0 /**< \brief (DSU_CID1) Preamble */ +#define DSU_CID1_PREAMBLE_Msk (0xFu << DSU_CID1_PREAMBLE_Pos) +#define DSU_CID1_PREAMBLE(value) ((DSU_CID1_PREAMBLE_Msk & ((value) << DSU_CID1_PREAMBLE_Pos))) +#define DSU_CID1_CCLASS_Pos 4 /**< \brief (DSU_CID1) Component Class */ +#define DSU_CID1_CCLASS_Msk (0xFu << DSU_CID1_CCLASS_Pos) +#define DSU_CID1_CCLASS(value) ((DSU_CID1_CCLASS_Msk & ((value) << DSU_CID1_CCLASS_Pos))) +#define DSU_CID1_MASK 0x000000FFu /**< \brief (DSU_CID1) MASK Register */ + +/* -------- DSU_CID2 : (DSU Offset: 0x1FF8) (R/ 32) Component Identification 2 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PREAMBLEB2:8; /*!< bit: 0.. 7 Preamble Byte 2 */ + uint32_t :24; /*!< bit: 8..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_CID2_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_CID2_OFFSET 0x1FF8 /**< \brief (DSU_CID2 offset) Component Identification 2 */ +#define DSU_CID2_RESETVALUE 0x00000005 /**< \brief (DSU_CID2 reset_value) Component Identification 2 */ + +#define DSU_CID2_PREAMBLEB2_Pos 0 /**< \brief (DSU_CID2) Preamble Byte 2 */ +#define DSU_CID2_PREAMBLEB2_Msk (0xFFu << DSU_CID2_PREAMBLEB2_Pos) +#define DSU_CID2_PREAMBLEB2(value) ((DSU_CID2_PREAMBLEB2_Msk & ((value) << DSU_CID2_PREAMBLEB2_Pos))) +#define DSU_CID2_MASK 0x000000FFu /**< \brief (DSU_CID2) MASK Register */ + +/* -------- DSU_CID3 : (DSU Offset: 0x1FFC) (R/ 32) Component Identification 3 -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PREAMBLEB3:8; /*!< bit: 0.. 7 Preamble Byte 3 */ + uint32_t :24; /*!< bit: 8..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} DSU_CID3_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define DSU_CID3_OFFSET 0x1FFC /**< \brief (DSU_CID3 offset) Component Identification 3 */ +#define DSU_CID3_RESETVALUE 0x000000B1 /**< \brief (DSU_CID3 reset_value) Component Identification 3 */ + +#define DSU_CID3_PREAMBLEB3_Pos 0 /**< \brief (DSU_CID3) Preamble Byte 3 */ +#define DSU_CID3_PREAMBLEB3_Msk (0xFFu << DSU_CID3_PREAMBLEB3_Pos) +#define DSU_CID3_PREAMBLEB3(value) ((DSU_CID3_PREAMBLEB3_Msk & ((value) << DSU_CID3_PREAMBLEB3_Pos))) +#define DSU_CID3_MASK 0x000000FFu /**< \brief (DSU_CID3) MASK Register */ + +/** \brief DSU hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __O DSU_CTRL_Type CTRL; /**< \brief Offset: 0x0000 ( /W 8) Control */ + __IO DSU_STATUSA_Type STATUSA; /**< \brief Offset: 0x0001 (R/W 8) Status A */ + __I DSU_STATUSB_Type STATUSB; /**< \brief Offset: 0x0002 (R/ 8) Status B */ + RoReg8 Reserved1[0x1]; + __IO DSU_ADDR_Type ADDR; /**< \brief Offset: 0x0004 (R/W 32) Address */ + __IO DSU_LENGTH_Type LENGTH; /**< \brief Offset: 0x0008 (R/W 32) Length */ + __IO DSU_DATA_Type DATA; /**< \brief Offset: 0x000C (R/W 32) Data */ + __IO DSU_DCC_Type DCC[2]; /**< \brief Offset: 0x0010 (R/W 32) Debug Communication Channel n */ + __I DSU_DID_Type DID; /**< \brief Offset: 0x0018 (R/ 32) Device Identification */ + RoReg8 Reserved2[0xFE4]; + __I DSU_ENTRY_Type ENTRY[2]; /**< \brief Offset: 0x1000 (R/ 32) Coresight ROM Table Entry n */ + __I DSU_END_Type END; /**< \brief Offset: 0x1008 (R/ 32) Coresight ROM Table End */ + RoReg8 Reserved3[0xFC0]; + __I DSU_MEMTYPE_Type MEMTYPE; /**< \brief Offset: 0x1FCC (R/ 32) Coresight ROM Table Memory Type */ + __I DSU_PID4_Type PID4; /**< \brief Offset: 0x1FD0 (R/ 32) Peripheral Identification 4 */ + RoReg8 Reserved4[0xC]; + __I DSU_PID0_Type PID0; /**< \brief Offset: 0x1FE0 (R/ 32) Peripheral Identification 0 */ + __I DSU_PID1_Type PID1; /**< \brief Offset: 0x1FE4 (R/ 32) Peripheral Identification 1 */ + __I DSU_PID2_Type PID2; /**< \brief Offset: 0x1FE8 (R/ 32) Peripheral Identification 2 */ + __I DSU_PID3_Type PID3; /**< \brief Offset: 0x1FEC (R/ 32) Peripheral Identification 3 */ + __I DSU_CID0_Type CID0; /**< \brief Offset: 0x1FF0 (R/ 32) Component Identification 0 */ + __I DSU_CID1_Type CID1; /**< \brief Offset: 0x1FF4 (R/ 32) Component Identification 1 */ + __I DSU_CID2_Type CID2; /**< \brief Offset: 0x1FF8 (R/ 32) Component Identification 2 */ + __I DSU_CID3_Type CID3; /**< \brief Offset: 0x1FFC (R/ 32) Component Identification 3 */ +} Dsu; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_DSU_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/eic.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/eic.h new file mode 100755 index 0000000..1601beb --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/eic.h @@ -0,0 +1,681 @@ +/** + * \file + * + * \brief Component description for EIC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_EIC_COMPONENT_ +#define _SAMD21_EIC_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR EIC */ +/* ========================================================================== */ +/** \addtogroup SAMD21_EIC External Interrupt Controller */ +/*@{*/ + +#define EIC_U2217 +#define REV_EIC 0x101 + +/* -------- EIC_CTRL : (EIC Offset: 0x00) (R/W 8) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset */ + uint8_t ENABLE:1; /*!< bit: 1 Enable */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} EIC_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_CTRL_OFFSET 0x00 /**< \brief (EIC_CTRL offset) Control */ +#define EIC_CTRL_RESETVALUE 0x00 /**< \brief (EIC_CTRL reset_value) Control */ + +#define EIC_CTRL_SWRST_Pos 0 /**< \brief (EIC_CTRL) Software Reset */ +#define EIC_CTRL_SWRST (0x1u << EIC_CTRL_SWRST_Pos) +#define EIC_CTRL_ENABLE_Pos 1 /**< \brief (EIC_CTRL) Enable */ +#define EIC_CTRL_ENABLE (0x1u << EIC_CTRL_ENABLE_Pos) +#define EIC_CTRL_MASK 0x03u /**< \brief (EIC_CTRL) MASK Register */ + +/* -------- EIC_STATUS : (EIC Offset: 0x01) (R/ 8) Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :7; /*!< bit: 0.. 6 Reserved */ + uint8_t SYNCBUSY:1; /*!< bit: 7 Synchronization Busy */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} EIC_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_STATUS_OFFSET 0x01 /**< \brief (EIC_STATUS offset) Status */ +#define EIC_STATUS_RESETVALUE 0x00 /**< \brief (EIC_STATUS reset_value) Status */ + +#define EIC_STATUS_SYNCBUSY_Pos 7 /**< \brief (EIC_STATUS) Synchronization Busy */ +#define EIC_STATUS_SYNCBUSY (0x1u << EIC_STATUS_SYNCBUSY_Pos) +#define EIC_STATUS_MASK 0x80u /**< \brief (EIC_STATUS) MASK Register */ + +/* -------- EIC_NMICTRL : (EIC Offset: 0x02) (R/W 8) Non-Maskable Interrupt Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t NMISENSE:3; /*!< bit: 0.. 2 Non-Maskable Interrupt Sense */ + uint8_t NMIFILTEN:1; /*!< bit: 3 Non-Maskable Interrupt Filter Enable */ + uint8_t :4; /*!< bit: 4.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} EIC_NMICTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_NMICTRL_OFFSET 0x02 /**< \brief (EIC_NMICTRL offset) Non-Maskable Interrupt Control */ +#define EIC_NMICTRL_RESETVALUE 0x00 /**< \brief (EIC_NMICTRL reset_value) Non-Maskable Interrupt Control */ + +#define EIC_NMICTRL_NMISENSE_Pos 0 /**< \brief (EIC_NMICTRL) Non-Maskable Interrupt Sense */ +#define EIC_NMICTRL_NMISENSE_Msk (0x7u << EIC_NMICTRL_NMISENSE_Pos) +#define EIC_NMICTRL_NMISENSE(value) ((EIC_NMICTRL_NMISENSE_Msk & ((value) << EIC_NMICTRL_NMISENSE_Pos))) +#define EIC_NMICTRL_NMISENSE_NONE_Val 0x0u /**< \brief (EIC_NMICTRL) No detection */ +#define EIC_NMICTRL_NMISENSE_RISE_Val 0x1u /**< \brief (EIC_NMICTRL) Rising-edge detection */ +#define EIC_NMICTRL_NMISENSE_FALL_Val 0x2u /**< \brief (EIC_NMICTRL) Falling-edge detection */ +#define EIC_NMICTRL_NMISENSE_BOTH_Val 0x3u /**< \brief (EIC_NMICTRL) Both-edges detection */ +#define EIC_NMICTRL_NMISENSE_HIGH_Val 0x4u /**< \brief (EIC_NMICTRL) High-level detection */ +#define EIC_NMICTRL_NMISENSE_LOW_Val 0x5u /**< \brief (EIC_NMICTRL) Low-level detection */ +#define EIC_NMICTRL_NMISENSE_NONE (EIC_NMICTRL_NMISENSE_NONE_Val << EIC_NMICTRL_NMISENSE_Pos) +#define EIC_NMICTRL_NMISENSE_RISE (EIC_NMICTRL_NMISENSE_RISE_Val << EIC_NMICTRL_NMISENSE_Pos) +#define EIC_NMICTRL_NMISENSE_FALL (EIC_NMICTRL_NMISENSE_FALL_Val << EIC_NMICTRL_NMISENSE_Pos) +#define EIC_NMICTRL_NMISENSE_BOTH (EIC_NMICTRL_NMISENSE_BOTH_Val << EIC_NMICTRL_NMISENSE_Pos) +#define EIC_NMICTRL_NMISENSE_HIGH (EIC_NMICTRL_NMISENSE_HIGH_Val << EIC_NMICTRL_NMISENSE_Pos) +#define EIC_NMICTRL_NMISENSE_LOW (EIC_NMICTRL_NMISENSE_LOW_Val << EIC_NMICTRL_NMISENSE_Pos) +#define EIC_NMICTRL_NMIFILTEN_Pos 3 /**< \brief (EIC_NMICTRL) Non-Maskable Interrupt Filter Enable */ +#define EIC_NMICTRL_NMIFILTEN (0x1u << EIC_NMICTRL_NMIFILTEN_Pos) +#define EIC_NMICTRL_MASK 0x0Fu /**< \brief (EIC_NMICTRL) MASK Register */ + +/* -------- EIC_NMIFLAG : (EIC Offset: 0x03) (R/W 8) Non-Maskable Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t NMI:1; /*!< bit: 0 Non-Maskable Interrupt */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} EIC_NMIFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_NMIFLAG_OFFSET 0x03 /**< \brief (EIC_NMIFLAG offset) Non-Maskable Interrupt Flag Status and Clear */ +#define EIC_NMIFLAG_RESETVALUE 0x00 /**< \brief (EIC_NMIFLAG reset_value) Non-Maskable Interrupt Flag Status and Clear */ + +#define EIC_NMIFLAG_NMI_Pos 0 /**< \brief (EIC_NMIFLAG) Non-Maskable Interrupt */ +#define EIC_NMIFLAG_NMI (0x1u << EIC_NMIFLAG_NMI_Pos) +#define EIC_NMIFLAG_MASK 0x01u /**< \brief (EIC_NMIFLAG) MASK Register */ + +/* -------- EIC_EVCTRL : (EIC Offset: 0x04) (R/W 32) Event Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t EXTINTEO0:1; /*!< bit: 0 External Interrupt 0 Event Output Enable */ + uint32_t EXTINTEO1:1; /*!< bit: 1 External Interrupt 1 Event Output Enable */ + uint32_t EXTINTEO2:1; /*!< bit: 2 External Interrupt 2 Event Output Enable */ + uint32_t EXTINTEO3:1; /*!< bit: 3 External Interrupt 3 Event Output Enable */ + uint32_t EXTINTEO4:1; /*!< bit: 4 External Interrupt 4 Event Output Enable */ + uint32_t EXTINTEO5:1; /*!< bit: 5 External Interrupt 5 Event Output Enable */ + uint32_t EXTINTEO6:1; /*!< bit: 6 External Interrupt 6 Event Output Enable */ + uint32_t EXTINTEO7:1; /*!< bit: 7 External Interrupt 7 Event Output Enable */ + uint32_t EXTINTEO8:1; /*!< bit: 8 External Interrupt 8 Event Output Enable */ + uint32_t EXTINTEO9:1; /*!< bit: 9 External Interrupt 9 Event Output Enable */ + uint32_t EXTINTEO10:1; /*!< bit: 10 External Interrupt 10 Event Output Enable */ + uint32_t EXTINTEO11:1; /*!< bit: 11 External Interrupt 11 Event Output Enable */ + uint32_t EXTINTEO12:1; /*!< bit: 12 External Interrupt 12 Event Output Enable */ + uint32_t EXTINTEO13:1; /*!< bit: 13 External Interrupt 13 Event Output Enable */ + uint32_t EXTINTEO14:1; /*!< bit: 14 External Interrupt 14 Event Output Enable */ + uint32_t EXTINTEO15:1; /*!< bit: 15 External Interrupt 15 Event Output Enable */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t EXTINTEO:16; /*!< bit: 0..15 External Interrupt x Event Output Enable */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} EIC_EVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_EVCTRL_OFFSET 0x04 /**< \brief (EIC_EVCTRL offset) Event Control */ +#define EIC_EVCTRL_RESETVALUE 0x00000000 /**< \brief (EIC_EVCTRL reset_value) Event Control */ + +#define EIC_EVCTRL_EXTINTEO0_Pos 0 /**< \brief (EIC_EVCTRL) External Interrupt 0 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO0 (1 << EIC_EVCTRL_EXTINTEO0_Pos) +#define EIC_EVCTRL_EXTINTEO1_Pos 1 /**< \brief (EIC_EVCTRL) External Interrupt 1 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO1 (1 << EIC_EVCTRL_EXTINTEO1_Pos) +#define EIC_EVCTRL_EXTINTEO2_Pos 2 /**< \brief (EIC_EVCTRL) External Interrupt 2 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO2 (1 << EIC_EVCTRL_EXTINTEO2_Pos) +#define EIC_EVCTRL_EXTINTEO3_Pos 3 /**< \brief (EIC_EVCTRL) External Interrupt 3 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO3 (1 << EIC_EVCTRL_EXTINTEO3_Pos) +#define EIC_EVCTRL_EXTINTEO4_Pos 4 /**< \brief (EIC_EVCTRL) External Interrupt 4 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO4 (1 << EIC_EVCTRL_EXTINTEO4_Pos) +#define EIC_EVCTRL_EXTINTEO5_Pos 5 /**< \brief (EIC_EVCTRL) External Interrupt 5 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO5 (1 << EIC_EVCTRL_EXTINTEO5_Pos) +#define EIC_EVCTRL_EXTINTEO6_Pos 6 /**< \brief (EIC_EVCTRL) External Interrupt 6 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO6 (1 << EIC_EVCTRL_EXTINTEO6_Pos) +#define EIC_EVCTRL_EXTINTEO7_Pos 7 /**< \brief (EIC_EVCTRL) External Interrupt 7 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO7 (1 << EIC_EVCTRL_EXTINTEO7_Pos) +#define EIC_EVCTRL_EXTINTEO8_Pos 8 /**< \brief (EIC_EVCTRL) External Interrupt 8 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO8 (1 << EIC_EVCTRL_EXTINTEO8_Pos) +#define EIC_EVCTRL_EXTINTEO9_Pos 9 /**< \brief (EIC_EVCTRL) External Interrupt 9 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO9 (1 << EIC_EVCTRL_EXTINTEO9_Pos) +#define EIC_EVCTRL_EXTINTEO10_Pos 10 /**< \brief (EIC_EVCTRL) External Interrupt 10 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO10 (1 << EIC_EVCTRL_EXTINTEO10_Pos) +#define EIC_EVCTRL_EXTINTEO11_Pos 11 /**< \brief (EIC_EVCTRL) External Interrupt 11 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO11 (1 << EIC_EVCTRL_EXTINTEO11_Pos) +#define EIC_EVCTRL_EXTINTEO12_Pos 12 /**< \brief (EIC_EVCTRL) External Interrupt 12 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO12 (1 << EIC_EVCTRL_EXTINTEO12_Pos) +#define EIC_EVCTRL_EXTINTEO13_Pos 13 /**< \brief (EIC_EVCTRL) External Interrupt 13 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO13 (1 << EIC_EVCTRL_EXTINTEO13_Pos) +#define EIC_EVCTRL_EXTINTEO14_Pos 14 /**< \brief (EIC_EVCTRL) External Interrupt 14 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO14 (1 << EIC_EVCTRL_EXTINTEO14_Pos) +#define EIC_EVCTRL_EXTINTEO15_Pos 15 /**< \brief (EIC_EVCTRL) External Interrupt 15 Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO15 (1 << EIC_EVCTRL_EXTINTEO15_Pos) +#define EIC_EVCTRL_EXTINTEO_Pos 0 /**< \brief (EIC_EVCTRL) External Interrupt x Event Output Enable */ +#define EIC_EVCTRL_EXTINTEO_Msk (0xFFFFu << EIC_EVCTRL_EXTINTEO_Pos) +#define EIC_EVCTRL_EXTINTEO(value) ((EIC_EVCTRL_EXTINTEO_Msk & ((value) << EIC_EVCTRL_EXTINTEO_Pos))) +#define EIC_EVCTRL_MASK 0x0000FFFFu /**< \brief (EIC_EVCTRL) MASK Register */ + +/* -------- EIC_INTENCLR : (EIC Offset: 0x08) (R/W 32) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t EXTINT0:1; /*!< bit: 0 External Interrupt 0 Enable */ + uint32_t EXTINT1:1; /*!< bit: 1 External Interrupt 1 Enable */ + uint32_t EXTINT2:1; /*!< bit: 2 External Interrupt 2 Enable */ + uint32_t EXTINT3:1; /*!< bit: 3 External Interrupt 3 Enable */ + uint32_t EXTINT4:1; /*!< bit: 4 External Interrupt 4 Enable */ + uint32_t EXTINT5:1; /*!< bit: 5 External Interrupt 5 Enable */ + uint32_t EXTINT6:1; /*!< bit: 6 External Interrupt 6 Enable */ + uint32_t EXTINT7:1; /*!< bit: 7 External Interrupt 7 Enable */ + uint32_t EXTINT8:1; /*!< bit: 8 External Interrupt 8 Enable */ + uint32_t EXTINT9:1; /*!< bit: 9 External Interrupt 9 Enable */ + uint32_t EXTINT10:1; /*!< bit: 10 External Interrupt 10 Enable */ + uint32_t EXTINT11:1; /*!< bit: 11 External Interrupt 11 Enable */ + uint32_t EXTINT12:1; /*!< bit: 12 External Interrupt 12 Enable */ + uint32_t EXTINT13:1; /*!< bit: 13 External Interrupt 13 Enable */ + uint32_t EXTINT14:1; /*!< bit: 14 External Interrupt 14 Enable */ + uint32_t EXTINT15:1; /*!< bit: 15 External Interrupt 15 Enable */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t EXTINT:16; /*!< bit: 0..15 External Interrupt x Enable */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} EIC_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_INTENCLR_OFFSET 0x08 /**< \brief (EIC_INTENCLR offset) Interrupt Enable Clear */ +#define EIC_INTENCLR_RESETVALUE 0x00000000 /**< \brief (EIC_INTENCLR reset_value) Interrupt Enable Clear */ + +#define EIC_INTENCLR_EXTINT0_Pos 0 /**< \brief (EIC_INTENCLR) External Interrupt 0 Enable */ +#define EIC_INTENCLR_EXTINT0 (1 << EIC_INTENCLR_EXTINT0_Pos) +#define EIC_INTENCLR_EXTINT1_Pos 1 /**< \brief (EIC_INTENCLR) External Interrupt 1 Enable */ +#define EIC_INTENCLR_EXTINT1 (1 << EIC_INTENCLR_EXTINT1_Pos) +#define EIC_INTENCLR_EXTINT2_Pos 2 /**< \brief (EIC_INTENCLR) External Interrupt 2 Enable */ +#define EIC_INTENCLR_EXTINT2 (1 << EIC_INTENCLR_EXTINT2_Pos) +#define EIC_INTENCLR_EXTINT3_Pos 3 /**< \brief (EIC_INTENCLR) External Interrupt 3 Enable */ +#define EIC_INTENCLR_EXTINT3 (1 << EIC_INTENCLR_EXTINT3_Pos) +#define EIC_INTENCLR_EXTINT4_Pos 4 /**< \brief (EIC_INTENCLR) External Interrupt 4 Enable */ +#define EIC_INTENCLR_EXTINT4 (1 << EIC_INTENCLR_EXTINT4_Pos) +#define EIC_INTENCLR_EXTINT5_Pos 5 /**< \brief (EIC_INTENCLR) External Interrupt 5 Enable */ +#define EIC_INTENCLR_EXTINT5 (1 << EIC_INTENCLR_EXTINT5_Pos) +#define EIC_INTENCLR_EXTINT6_Pos 6 /**< \brief (EIC_INTENCLR) External Interrupt 6 Enable */ +#define EIC_INTENCLR_EXTINT6 (1 << EIC_INTENCLR_EXTINT6_Pos) +#define EIC_INTENCLR_EXTINT7_Pos 7 /**< \brief (EIC_INTENCLR) External Interrupt 7 Enable */ +#define EIC_INTENCLR_EXTINT7 (1 << EIC_INTENCLR_EXTINT7_Pos) +#define EIC_INTENCLR_EXTINT8_Pos 8 /**< \brief (EIC_INTENCLR) External Interrupt 8 Enable */ +#define EIC_INTENCLR_EXTINT8 (1 << EIC_INTENCLR_EXTINT8_Pos) +#define EIC_INTENCLR_EXTINT9_Pos 9 /**< \brief (EIC_INTENCLR) External Interrupt 9 Enable */ +#define EIC_INTENCLR_EXTINT9 (1 << EIC_INTENCLR_EXTINT9_Pos) +#define EIC_INTENCLR_EXTINT10_Pos 10 /**< \brief (EIC_INTENCLR) External Interrupt 10 Enable */ +#define EIC_INTENCLR_EXTINT10 (1 << EIC_INTENCLR_EXTINT10_Pos) +#define EIC_INTENCLR_EXTINT11_Pos 11 /**< \brief (EIC_INTENCLR) External Interrupt 11 Enable */ +#define EIC_INTENCLR_EXTINT11 (1 << EIC_INTENCLR_EXTINT11_Pos) +#define EIC_INTENCLR_EXTINT12_Pos 12 /**< \brief (EIC_INTENCLR) External Interrupt 12 Enable */ +#define EIC_INTENCLR_EXTINT12 (1 << EIC_INTENCLR_EXTINT12_Pos) +#define EIC_INTENCLR_EXTINT13_Pos 13 /**< \brief (EIC_INTENCLR) External Interrupt 13 Enable */ +#define EIC_INTENCLR_EXTINT13 (1 << EIC_INTENCLR_EXTINT13_Pos) +#define EIC_INTENCLR_EXTINT14_Pos 14 /**< \brief (EIC_INTENCLR) External Interrupt 14 Enable */ +#define EIC_INTENCLR_EXTINT14 (1 << EIC_INTENCLR_EXTINT14_Pos) +#define EIC_INTENCLR_EXTINT15_Pos 15 /**< \brief (EIC_INTENCLR) External Interrupt 15 Enable */ +#define EIC_INTENCLR_EXTINT15 (1 << EIC_INTENCLR_EXTINT15_Pos) +#define EIC_INTENCLR_EXTINT_Pos 0 /**< \brief (EIC_INTENCLR) External Interrupt x Enable */ +#define EIC_INTENCLR_EXTINT_Msk (0xFFFFu << EIC_INTENCLR_EXTINT_Pos) +#define EIC_INTENCLR_EXTINT(value) ((EIC_INTENCLR_EXTINT_Msk & ((value) << EIC_INTENCLR_EXTINT_Pos))) +#define EIC_INTENCLR_MASK 0x0000FFFFu /**< \brief (EIC_INTENCLR) MASK Register */ + +/* -------- EIC_INTENSET : (EIC Offset: 0x0C) (R/W 32) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t EXTINT0:1; /*!< bit: 0 External Interrupt 0 Enable */ + uint32_t EXTINT1:1; /*!< bit: 1 External Interrupt 1 Enable */ + uint32_t EXTINT2:1; /*!< bit: 2 External Interrupt 2 Enable */ + uint32_t EXTINT3:1; /*!< bit: 3 External Interrupt 3 Enable */ + uint32_t EXTINT4:1; /*!< bit: 4 External Interrupt 4 Enable */ + uint32_t EXTINT5:1; /*!< bit: 5 External Interrupt 5 Enable */ + uint32_t EXTINT6:1; /*!< bit: 6 External Interrupt 6 Enable */ + uint32_t EXTINT7:1; /*!< bit: 7 External Interrupt 7 Enable */ + uint32_t EXTINT8:1; /*!< bit: 8 External Interrupt 8 Enable */ + uint32_t EXTINT9:1; /*!< bit: 9 External Interrupt 9 Enable */ + uint32_t EXTINT10:1; /*!< bit: 10 External Interrupt 10 Enable */ + uint32_t EXTINT11:1; /*!< bit: 11 External Interrupt 11 Enable */ + uint32_t EXTINT12:1; /*!< bit: 12 External Interrupt 12 Enable */ + uint32_t EXTINT13:1; /*!< bit: 13 External Interrupt 13 Enable */ + uint32_t EXTINT14:1; /*!< bit: 14 External Interrupt 14 Enable */ + uint32_t EXTINT15:1; /*!< bit: 15 External Interrupt 15 Enable */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t EXTINT:16; /*!< bit: 0..15 External Interrupt x Enable */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} EIC_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_INTENSET_OFFSET 0x0C /**< \brief (EIC_INTENSET offset) Interrupt Enable Set */ +#define EIC_INTENSET_RESETVALUE 0x00000000 /**< \brief (EIC_INTENSET reset_value) Interrupt Enable Set */ + +#define EIC_INTENSET_EXTINT0_Pos 0 /**< \brief (EIC_INTENSET) External Interrupt 0 Enable */ +#define EIC_INTENSET_EXTINT0 (1 << EIC_INTENSET_EXTINT0_Pos) +#define EIC_INTENSET_EXTINT1_Pos 1 /**< \brief (EIC_INTENSET) External Interrupt 1 Enable */ +#define EIC_INTENSET_EXTINT1 (1 << EIC_INTENSET_EXTINT1_Pos) +#define EIC_INTENSET_EXTINT2_Pos 2 /**< \brief (EIC_INTENSET) External Interrupt 2 Enable */ +#define EIC_INTENSET_EXTINT2 (1 << EIC_INTENSET_EXTINT2_Pos) +#define EIC_INTENSET_EXTINT3_Pos 3 /**< \brief (EIC_INTENSET) External Interrupt 3 Enable */ +#define EIC_INTENSET_EXTINT3 (1 << EIC_INTENSET_EXTINT3_Pos) +#define EIC_INTENSET_EXTINT4_Pos 4 /**< \brief (EIC_INTENSET) External Interrupt 4 Enable */ +#define EIC_INTENSET_EXTINT4 (1 << EIC_INTENSET_EXTINT4_Pos) +#define EIC_INTENSET_EXTINT5_Pos 5 /**< \brief (EIC_INTENSET) External Interrupt 5 Enable */ +#define EIC_INTENSET_EXTINT5 (1 << EIC_INTENSET_EXTINT5_Pos) +#define EIC_INTENSET_EXTINT6_Pos 6 /**< \brief (EIC_INTENSET) External Interrupt 6 Enable */ +#define EIC_INTENSET_EXTINT6 (1 << EIC_INTENSET_EXTINT6_Pos) +#define EIC_INTENSET_EXTINT7_Pos 7 /**< \brief (EIC_INTENSET) External Interrupt 7 Enable */ +#define EIC_INTENSET_EXTINT7 (1 << EIC_INTENSET_EXTINT7_Pos) +#define EIC_INTENSET_EXTINT8_Pos 8 /**< \brief (EIC_INTENSET) External Interrupt 8 Enable */ +#define EIC_INTENSET_EXTINT8 (1 << EIC_INTENSET_EXTINT8_Pos) +#define EIC_INTENSET_EXTINT9_Pos 9 /**< \brief (EIC_INTENSET) External Interrupt 9 Enable */ +#define EIC_INTENSET_EXTINT9 (1 << EIC_INTENSET_EXTINT9_Pos) +#define EIC_INTENSET_EXTINT10_Pos 10 /**< \brief (EIC_INTENSET) External Interrupt 10 Enable */ +#define EIC_INTENSET_EXTINT10 (1 << EIC_INTENSET_EXTINT10_Pos) +#define EIC_INTENSET_EXTINT11_Pos 11 /**< \brief (EIC_INTENSET) External Interrupt 11 Enable */ +#define EIC_INTENSET_EXTINT11 (1 << EIC_INTENSET_EXTINT11_Pos) +#define EIC_INTENSET_EXTINT12_Pos 12 /**< \brief (EIC_INTENSET) External Interrupt 12 Enable */ +#define EIC_INTENSET_EXTINT12 (1 << EIC_INTENSET_EXTINT12_Pos) +#define EIC_INTENSET_EXTINT13_Pos 13 /**< \brief (EIC_INTENSET) External Interrupt 13 Enable */ +#define EIC_INTENSET_EXTINT13 (1 << EIC_INTENSET_EXTINT13_Pos) +#define EIC_INTENSET_EXTINT14_Pos 14 /**< \brief (EIC_INTENSET) External Interrupt 14 Enable */ +#define EIC_INTENSET_EXTINT14 (1 << EIC_INTENSET_EXTINT14_Pos) +#define EIC_INTENSET_EXTINT15_Pos 15 /**< \brief (EIC_INTENSET) External Interrupt 15 Enable */ +#define EIC_INTENSET_EXTINT15 (1 << EIC_INTENSET_EXTINT15_Pos) +#define EIC_INTENSET_EXTINT_Pos 0 /**< \brief (EIC_INTENSET) External Interrupt x Enable */ +#define EIC_INTENSET_EXTINT_Msk (0xFFFFu << EIC_INTENSET_EXTINT_Pos) +#define EIC_INTENSET_EXTINT(value) ((EIC_INTENSET_EXTINT_Msk & ((value) << EIC_INTENSET_EXTINT_Pos))) +#define EIC_INTENSET_MASK 0x0000FFFFu /**< \brief (EIC_INTENSET) MASK Register */ + +/* -------- EIC_INTFLAG : (EIC Offset: 0x10) (R/W 32) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t EXTINT0:1; /*!< bit: 0 External Interrupt 0 */ + uint32_t EXTINT1:1; /*!< bit: 1 External Interrupt 1 */ + uint32_t EXTINT2:1; /*!< bit: 2 External Interrupt 2 */ + uint32_t EXTINT3:1; /*!< bit: 3 External Interrupt 3 */ + uint32_t EXTINT4:1; /*!< bit: 4 External Interrupt 4 */ + uint32_t EXTINT5:1; /*!< bit: 5 External Interrupt 5 */ + uint32_t EXTINT6:1; /*!< bit: 6 External Interrupt 6 */ + uint32_t EXTINT7:1; /*!< bit: 7 External Interrupt 7 */ + uint32_t EXTINT8:1; /*!< bit: 8 External Interrupt 8 */ + uint32_t EXTINT9:1; /*!< bit: 9 External Interrupt 9 */ + uint32_t EXTINT10:1; /*!< bit: 10 External Interrupt 10 */ + uint32_t EXTINT11:1; /*!< bit: 11 External Interrupt 11 */ + uint32_t EXTINT12:1; /*!< bit: 12 External Interrupt 12 */ + uint32_t EXTINT13:1; /*!< bit: 13 External Interrupt 13 */ + uint32_t EXTINT14:1; /*!< bit: 14 External Interrupt 14 */ + uint32_t EXTINT15:1; /*!< bit: 15 External Interrupt 15 */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t EXTINT:16; /*!< bit: 0..15 External Interrupt x */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} EIC_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_INTFLAG_OFFSET 0x10 /**< \brief (EIC_INTFLAG offset) Interrupt Flag Status and Clear */ +#define EIC_INTFLAG_RESETVALUE 0x00000000 /**< \brief (EIC_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define EIC_INTFLAG_EXTINT0_Pos 0 /**< \brief (EIC_INTFLAG) External Interrupt 0 */ +#define EIC_INTFLAG_EXTINT0 (1 << EIC_INTFLAG_EXTINT0_Pos) +#define EIC_INTFLAG_EXTINT1_Pos 1 /**< \brief (EIC_INTFLAG) External Interrupt 1 */ +#define EIC_INTFLAG_EXTINT1 (1 << EIC_INTFLAG_EXTINT1_Pos) +#define EIC_INTFLAG_EXTINT2_Pos 2 /**< \brief (EIC_INTFLAG) External Interrupt 2 */ +#define EIC_INTFLAG_EXTINT2 (1 << EIC_INTFLAG_EXTINT2_Pos) +#define EIC_INTFLAG_EXTINT3_Pos 3 /**< \brief (EIC_INTFLAG) External Interrupt 3 */ +#define EIC_INTFLAG_EXTINT3 (1 << EIC_INTFLAG_EXTINT3_Pos) +#define EIC_INTFLAG_EXTINT4_Pos 4 /**< \brief (EIC_INTFLAG) External Interrupt 4 */ +#define EIC_INTFLAG_EXTINT4 (1 << EIC_INTFLAG_EXTINT4_Pos) +#define EIC_INTFLAG_EXTINT5_Pos 5 /**< \brief (EIC_INTFLAG) External Interrupt 5 */ +#define EIC_INTFLAG_EXTINT5 (1 << EIC_INTFLAG_EXTINT5_Pos) +#define EIC_INTFLAG_EXTINT6_Pos 6 /**< \brief (EIC_INTFLAG) External Interrupt 6 */ +#define EIC_INTFLAG_EXTINT6 (1 << EIC_INTFLAG_EXTINT6_Pos) +#define EIC_INTFLAG_EXTINT7_Pos 7 /**< \brief (EIC_INTFLAG) External Interrupt 7 */ +#define EIC_INTFLAG_EXTINT7 (1 << EIC_INTFLAG_EXTINT7_Pos) +#define EIC_INTFLAG_EXTINT8_Pos 8 /**< \brief (EIC_INTFLAG) External Interrupt 8 */ +#define EIC_INTFLAG_EXTINT8 (1 << EIC_INTFLAG_EXTINT8_Pos) +#define EIC_INTFLAG_EXTINT9_Pos 9 /**< \brief (EIC_INTFLAG) External Interrupt 9 */ +#define EIC_INTFLAG_EXTINT9 (1 << EIC_INTFLAG_EXTINT9_Pos) +#define EIC_INTFLAG_EXTINT10_Pos 10 /**< \brief (EIC_INTFLAG) External Interrupt 10 */ +#define EIC_INTFLAG_EXTINT10 (1 << EIC_INTFLAG_EXTINT10_Pos) +#define EIC_INTFLAG_EXTINT11_Pos 11 /**< \brief (EIC_INTFLAG) External Interrupt 11 */ +#define EIC_INTFLAG_EXTINT11 (1 << EIC_INTFLAG_EXTINT11_Pos) +#define EIC_INTFLAG_EXTINT12_Pos 12 /**< \brief (EIC_INTFLAG) External Interrupt 12 */ +#define EIC_INTFLAG_EXTINT12 (1 << EIC_INTFLAG_EXTINT12_Pos) +#define EIC_INTFLAG_EXTINT13_Pos 13 /**< \brief (EIC_INTFLAG) External Interrupt 13 */ +#define EIC_INTFLAG_EXTINT13 (1 << EIC_INTFLAG_EXTINT13_Pos) +#define EIC_INTFLAG_EXTINT14_Pos 14 /**< \brief (EIC_INTFLAG) External Interrupt 14 */ +#define EIC_INTFLAG_EXTINT14 (1 << EIC_INTFLAG_EXTINT14_Pos) +#define EIC_INTFLAG_EXTINT15_Pos 15 /**< \brief (EIC_INTFLAG) External Interrupt 15 */ +#define EIC_INTFLAG_EXTINT15 (1 << EIC_INTFLAG_EXTINT15_Pos) +#define EIC_INTFLAG_EXTINT_Pos 0 /**< \brief (EIC_INTFLAG) External Interrupt x */ +#define EIC_INTFLAG_EXTINT_Msk (0xFFFFu << EIC_INTFLAG_EXTINT_Pos) +#define EIC_INTFLAG_EXTINT(value) ((EIC_INTFLAG_EXTINT_Msk & ((value) << EIC_INTFLAG_EXTINT_Pos))) +#define EIC_INTFLAG_MASK 0x0000FFFFu /**< \brief (EIC_INTFLAG) MASK Register */ + +/* -------- EIC_WAKEUP : (EIC Offset: 0x14) (R/W 32) Wake-Up Enable -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t WAKEUPEN0:1; /*!< bit: 0 External Interrupt 0 Wake-up Enable */ + uint32_t WAKEUPEN1:1; /*!< bit: 1 External Interrupt 1 Wake-up Enable */ + uint32_t WAKEUPEN2:1; /*!< bit: 2 External Interrupt 2 Wake-up Enable */ + uint32_t WAKEUPEN3:1; /*!< bit: 3 External Interrupt 3 Wake-up Enable */ + uint32_t WAKEUPEN4:1; /*!< bit: 4 External Interrupt 4 Wake-up Enable */ + uint32_t WAKEUPEN5:1; /*!< bit: 5 External Interrupt 5 Wake-up Enable */ + uint32_t WAKEUPEN6:1; /*!< bit: 6 External Interrupt 6 Wake-up Enable */ + uint32_t WAKEUPEN7:1; /*!< bit: 7 External Interrupt 7 Wake-up Enable */ + uint32_t WAKEUPEN8:1; /*!< bit: 8 External Interrupt 8 Wake-up Enable */ + uint32_t WAKEUPEN9:1; /*!< bit: 9 External Interrupt 9 Wake-up Enable */ + uint32_t WAKEUPEN10:1; /*!< bit: 10 External Interrupt 10 Wake-up Enable */ + uint32_t WAKEUPEN11:1; /*!< bit: 11 External Interrupt 11 Wake-up Enable */ + uint32_t WAKEUPEN12:1; /*!< bit: 12 External Interrupt 12 Wake-up Enable */ + uint32_t WAKEUPEN13:1; /*!< bit: 13 External Interrupt 13 Wake-up Enable */ + uint32_t WAKEUPEN14:1; /*!< bit: 14 External Interrupt 14 Wake-up Enable */ + uint32_t WAKEUPEN15:1; /*!< bit: 15 External Interrupt 15 Wake-up Enable */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t WAKEUPEN:16; /*!< bit: 0..15 External Interrupt x Wake-up Enable */ + uint32_t :16; /*!< bit: 16..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} EIC_WAKEUP_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_WAKEUP_OFFSET 0x14 /**< \brief (EIC_WAKEUP offset) Wake-Up Enable */ +#define EIC_WAKEUP_RESETVALUE 0x00000000 /**< \brief (EIC_WAKEUP reset_value) Wake-Up Enable */ + +#define EIC_WAKEUP_WAKEUPEN0_Pos 0 /**< \brief (EIC_WAKEUP) External Interrupt 0 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN0 (1 << EIC_WAKEUP_WAKEUPEN0_Pos) +#define EIC_WAKEUP_WAKEUPEN1_Pos 1 /**< \brief (EIC_WAKEUP) External Interrupt 1 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN1 (1 << EIC_WAKEUP_WAKEUPEN1_Pos) +#define EIC_WAKEUP_WAKEUPEN2_Pos 2 /**< \brief (EIC_WAKEUP) External Interrupt 2 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN2 (1 << EIC_WAKEUP_WAKEUPEN2_Pos) +#define EIC_WAKEUP_WAKEUPEN3_Pos 3 /**< \brief (EIC_WAKEUP) External Interrupt 3 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN3 (1 << EIC_WAKEUP_WAKEUPEN3_Pos) +#define EIC_WAKEUP_WAKEUPEN4_Pos 4 /**< \brief (EIC_WAKEUP) External Interrupt 4 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN4 (1 << EIC_WAKEUP_WAKEUPEN4_Pos) +#define EIC_WAKEUP_WAKEUPEN5_Pos 5 /**< \brief (EIC_WAKEUP) External Interrupt 5 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN5 (1 << EIC_WAKEUP_WAKEUPEN5_Pos) +#define EIC_WAKEUP_WAKEUPEN6_Pos 6 /**< \brief (EIC_WAKEUP) External Interrupt 6 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN6 (1 << EIC_WAKEUP_WAKEUPEN6_Pos) +#define EIC_WAKEUP_WAKEUPEN7_Pos 7 /**< \brief (EIC_WAKEUP) External Interrupt 7 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN7 (1 << EIC_WAKEUP_WAKEUPEN7_Pos) +#define EIC_WAKEUP_WAKEUPEN8_Pos 8 /**< \brief (EIC_WAKEUP) External Interrupt 8 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN8 (1 << EIC_WAKEUP_WAKEUPEN8_Pos) +#define EIC_WAKEUP_WAKEUPEN9_Pos 9 /**< \brief (EIC_WAKEUP) External Interrupt 9 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN9 (1 << EIC_WAKEUP_WAKEUPEN9_Pos) +#define EIC_WAKEUP_WAKEUPEN10_Pos 10 /**< \brief (EIC_WAKEUP) External Interrupt 10 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN10 (1 << EIC_WAKEUP_WAKEUPEN10_Pos) +#define EIC_WAKEUP_WAKEUPEN11_Pos 11 /**< \brief (EIC_WAKEUP) External Interrupt 11 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN11 (1 << EIC_WAKEUP_WAKEUPEN11_Pos) +#define EIC_WAKEUP_WAKEUPEN12_Pos 12 /**< \brief (EIC_WAKEUP) External Interrupt 12 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN12 (1 << EIC_WAKEUP_WAKEUPEN12_Pos) +#define EIC_WAKEUP_WAKEUPEN13_Pos 13 /**< \brief (EIC_WAKEUP) External Interrupt 13 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN13 (1 << EIC_WAKEUP_WAKEUPEN13_Pos) +#define EIC_WAKEUP_WAKEUPEN14_Pos 14 /**< \brief (EIC_WAKEUP) External Interrupt 14 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN14 (1 << EIC_WAKEUP_WAKEUPEN14_Pos) +#define EIC_WAKEUP_WAKEUPEN15_Pos 15 /**< \brief (EIC_WAKEUP) External Interrupt 15 Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN15 (1 << EIC_WAKEUP_WAKEUPEN15_Pos) +#define EIC_WAKEUP_WAKEUPEN_Pos 0 /**< \brief (EIC_WAKEUP) External Interrupt x Wake-up Enable */ +#define EIC_WAKEUP_WAKEUPEN_Msk (0xFFFFu << EIC_WAKEUP_WAKEUPEN_Pos) +#define EIC_WAKEUP_WAKEUPEN(value) ((EIC_WAKEUP_WAKEUPEN_Msk & ((value) << EIC_WAKEUP_WAKEUPEN_Pos))) +#define EIC_WAKEUP_MASK 0x0000FFFFu /**< \brief (EIC_WAKEUP) MASK Register */ + +/* -------- EIC_CONFIG : (EIC Offset: 0x18) (R/W 32) Configuration n -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SENSE0:3; /*!< bit: 0.. 2 Input Sense 0 Configuration */ + uint32_t FILTEN0:1; /*!< bit: 3 Filter 0 Enable */ + uint32_t SENSE1:3; /*!< bit: 4.. 6 Input Sense 1 Configuration */ + uint32_t FILTEN1:1; /*!< bit: 7 Filter 1 Enable */ + uint32_t SENSE2:3; /*!< bit: 8..10 Input Sense 2 Configuration */ + uint32_t FILTEN2:1; /*!< bit: 11 Filter 2 Enable */ + uint32_t SENSE3:3; /*!< bit: 12..14 Input Sense 3 Configuration */ + uint32_t FILTEN3:1; /*!< bit: 15 Filter 3 Enable */ + uint32_t SENSE4:3; /*!< bit: 16..18 Input Sense 4 Configuration */ + uint32_t FILTEN4:1; /*!< bit: 19 Filter 4 Enable */ + uint32_t SENSE5:3; /*!< bit: 20..22 Input Sense 5 Configuration */ + uint32_t FILTEN5:1; /*!< bit: 23 Filter 5 Enable */ + uint32_t SENSE6:3; /*!< bit: 24..26 Input Sense 6 Configuration */ + uint32_t FILTEN6:1; /*!< bit: 27 Filter 6 Enable */ + uint32_t SENSE7:3; /*!< bit: 28..30 Input Sense 7 Configuration */ + uint32_t FILTEN7:1; /*!< bit: 31 Filter 7 Enable */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} EIC_CONFIG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EIC_CONFIG_OFFSET 0x18 /**< \brief (EIC_CONFIG offset) Configuration n */ +#define EIC_CONFIG_RESETVALUE 0x00000000 /**< \brief (EIC_CONFIG reset_value) Configuration n */ + +#define EIC_CONFIG_SENSE0_Pos 0 /**< \brief (EIC_CONFIG) Input Sense 0 Configuration */ +#define EIC_CONFIG_SENSE0_Msk (0x7u << EIC_CONFIG_SENSE0_Pos) +#define EIC_CONFIG_SENSE0(value) ((EIC_CONFIG_SENSE0_Msk & ((value) << EIC_CONFIG_SENSE0_Pos))) +#define EIC_CONFIG_SENSE0_NONE_Val 0x0u /**< \brief (EIC_CONFIG) No detection */ +#define EIC_CONFIG_SENSE0_RISE_Val 0x1u /**< \brief (EIC_CONFIG) Rising-edge detection */ +#define EIC_CONFIG_SENSE0_FALL_Val 0x2u /**< \brief (EIC_CONFIG) Falling-edge detection */ +#define EIC_CONFIG_SENSE0_BOTH_Val 0x3u /**< \brief (EIC_CONFIG) Both-edges detection */ +#define EIC_CONFIG_SENSE0_HIGH_Val 0x4u /**< \brief (EIC_CONFIG) High-level detection */ +#define EIC_CONFIG_SENSE0_LOW_Val 0x5u /**< \brief (EIC_CONFIG) Low-level detection */ +#define EIC_CONFIG_SENSE0_NONE (EIC_CONFIG_SENSE0_NONE_Val << EIC_CONFIG_SENSE0_Pos) +#define EIC_CONFIG_SENSE0_RISE (EIC_CONFIG_SENSE0_RISE_Val << EIC_CONFIG_SENSE0_Pos) +#define EIC_CONFIG_SENSE0_FALL (EIC_CONFIG_SENSE0_FALL_Val << EIC_CONFIG_SENSE0_Pos) +#define EIC_CONFIG_SENSE0_BOTH (EIC_CONFIG_SENSE0_BOTH_Val << EIC_CONFIG_SENSE0_Pos) +#define EIC_CONFIG_SENSE0_HIGH (EIC_CONFIG_SENSE0_HIGH_Val << EIC_CONFIG_SENSE0_Pos) +#define EIC_CONFIG_SENSE0_LOW (EIC_CONFIG_SENSE0_LOW_Val << EIC_CONFIG_SENSE0_Pos) +#define EIC_CONFIG_FILTEN0_Pos 3 /**< \brief (EIC_CONFIG) Filter 0 Enable */ +#define EIC_CONFIG_FILTEN0 (0x1u << EIC_CONFIG_FILTEN0_Pos) +#define EIC_CONFIG_SENSE1_Pos 4 /**< \brief (EIC_CONFIG) Input Sense 1 Configuration */ +#define EIC_CONFIG_SENSE1_Msk (0x7u << EIC_CONFIG_SENSE1_Pos) +#define EIC_CONFIG_SENSE1(value) ((EIC_CONFIG_SENSE1_Msk & ((value) << EIC_CONFIG_SENSE1_Pos))) +#define EIC_CONFIG_SENSE1_NONE_Val 0x0u /**< \brief (EIC_CONFIG) No detection */ +#define EIC_CONFIG_SENSE1_RISE_Val 0x1u /**< \brief (EIC_CONFIG) Rising edge detection */ +#define EIC_CONFIG_SENSE1_FALL_Val 0x2u /**< \brief (EIC_CONFIG) Falling edge detection */ +#define EIC_CONFIG_SENSE1_BOTH_Val 0x3u /**< \brief (EIC_CONFIG) Both edges detection */ +#define EIC_CONFIG_SENSE1_HIGH_Val 0x4u /**< \brief (EIC_CONFIG) High level detection */ +#define EIC_CONFIG_SENSE1_LOW_Val 0x5u /**< \brief (EIC_CONFIG) Low level detection */ +#define EIC_CONFIG_SENSE1_NONE (EIC_CONFIG_SENSE1_NONE_Val << EIC_CONFIG_SENSE1_Pos) +#define EIC_CONFIG_SENSE1_RISE (EIC_CONFIG_SENSE1_RISE_Val << EIC_CONFIG_SENSE1_Pos) +#define EIC_CONFIG_SENSE1_FALL (EIC_CONFIG_SENSE1_FALL_Val << EIC_CONFIG_SENSE1_Pos) +#define EIC_CONFIG_SENSE1_BOTH (EIC_CONFIG_SENSE1_BOTH_Val << EIC_CONFIG_SENSE1_Pos) +#define EIC_CONFIG_SENSE1_HIGH (EIC_CONFIG_SENSE1_HIGH_Val << EIC_CONFIG_SENSE1_Pos) +#define EIC_CONFIG_SENSE1_LOW (EIC_CONFIG_SENSE1_LOW_Val << EIC_CONFIG_SENSE1_Pos) +#define EIC_CONFIG_FILTEN1_Pos 7 /**< \brief (EIC_CONFIG) Filter 1 Enable */ +#define EIC_CONFIG_FILTEN1 (0x1u << EIC_CONFIG_FILTEN1_Pos) +#define EIC_CONFIG_SENSE2_Pos 8 /**< \brief (EIC_CONFIG) Input Sense 2 Configuration */ +#define EIC_CONFIG_SENSE2_Msk (0x7u << EIC_CONFIG_SENSE2_Pos) +#define EIC_CONFIG_SENSE2(value) ((EIC_CONFIG_SENSE2_Msk & ((value) << EIC_CONFIG_SENSE2_Pos))) +#define EIC_CONFIG_SENSE2_NONE_Val 0x0u /**< \brief (EIC_CONFIG) No detection */ +#define EIC_CONFIG_SENSE2_RISE_Val 0x1u /**< \brief (EIC_CONFIG) Rising edge detection */ +#define EIC_CONFIG_SENSE2_FALL_Val 0x2u /**< \brief (EIC_CONFIG) Falling edge detection */ +#define EIC_CONFIG_SENSE2_BOTH_Val 0x3u /**< \brief (EIC_CONFIG) Both edges detection */ +#define EIC_CONFIG_SENSE2_HIGH_Val 0x4u /**< \brief (EIC_CONFIG) High level detection */ +#define EIC_CONFIG_SENSE2_LOW_Val 0x5u /**< \brief (EIC_CONFIG) Low level detection */ +#define EIC_CONFIG_SENSE2_NONE (EIC_CONFIG_SENSE2_NONE_Val << EIC_CONFIG_SENSE2_Pos) +#define EIC_CONFIG_SENSE2_RISE (EIC_CONFIG_SENSE2_RISE_Val << EIC_CONFIG_SENSE2_Pos) +#define EIC_CONFIG_SENSE2_FALL (EIC_CONFIG_SENSE2_FALL_Val << EIC_CONFIG_SENSE2_Pos) +#define EIC_CONFIG_SENSE2_BOTH (EIC_CONFIG_SENSE2_BOTH_Val << EIC_CONFIG_SENSE2_Pos) +#define EIC_CONFIG_SENSE2_HIGH (EIC_CONFIG_SENSE2_HIGH_Val << EIC_CONFIG_SENSE2_Pos) +#define EIC_CONFIG_SENSE2_LOW (EIC_CONFIG_SENSE2_LOW_Val << EIC_CONFIG_SENSE2_Pos) +#define EIC_CONFIG_FILTEN2_Pos 11 /**< \brief (EIC_CONFIG) Filter 2 Enable */ +#define EIC_CONFIG_FILTEN2 (0x1u << EIC_CONFIG_FILTEN2_Pos) +#define EIC_CONFIG_SENSE3_Pos 12 /**< \brief (EIC_CONFIG) Input Sense 3 Configuration */ +#define EIC_CONFIG_SENSE3_Msk (0x7u << EIC_CONFIG_SENSE3_Pos) +#define EIC_CONFIG_SENSE3(value) ((EIC_CONFIG_SENSE3_Msk & ((value) << EIC_CONFIG_SENSE3_Pos))) +#define EIC_CONFIG_SENSE3_NONE_Val 0x0u /**< \brief (EIC_CONFIG) No detection */ +#define EIC_CONFIG_SENSE3_RISE_Val 0x1u /**< \brief (EIC_CONFIG) Rising edge detection */ +#define EIC_CONFIG_SENSE3_FALL_Val 0x2u /**< \brief (EIC_CONFIG) Falling edge detection */ +#define EIC_CONFIG_SENSE3_BOTH_Val 0x3u /**< \brief (EIC_CONFIG) Both edges detection */ +#define EIC_CONFIG_SENSE3_HIGH_Val 0x4u /**< \brief (EIC_CONFIG) High level detection */ +#define EIC_CONFIG_SENSE3_LOW_Val 0x5u /**< \brief (EIC_CONFIG) Low level detection */ +#define EIC_CONFIG_SENSE3_NONE (EIC_CONFIG_SENSE3_NONE_Val << EIC_CONFIG_SENSE3_Pos) +#define EIC_CONFIG_SENSE3_RISE (EIC_CONFIG_SENSE3_RISE_Val << EIC_CONFIG_SENSE3_Pos) +#define EIC_CONFIG_SENSE3_FALL (EIC_CONFIG_SENSE3_FALL_Val << EIC_CONFIG_SENSE3_Pos) +#define EIC_CONFIG_SENSE3_BOTH (EIC_CONFIG_SENSE3_BOTH_Val << EIC_CONFIG_SENSE3_Pos) +#define EIC_CONFIG_SENSE3_HIGH (EIC_CONFIG_SENSE3_HIGH_Val << EIC_CONFIG_SENSE3_Pos) +#define EIC_CONFIG_SENSE3_LOW (EIC_CONFIG_SENSE3_LOW_Val << EIC_CONFIG_SENSE3_Pos) +#define EIC_CONFIG_FILTEN3_Pos 15 /**< \brief (EIC_CONFIG) Filter 3 Enable */ +#define EIC_CONFIG_FILTEN3 (0x1u << EIC_CONFIG_FILTEN3_Pos) +#define EIC_CONFIG_SENSE4_Pos 16 /**< \brief (EIC_CONFIG) Input Sense 4 Configuration */ +#define EIC_CONFIG_SENSE4_Msk (0x7u << EIC_CONFIG_SENSE4_Pos) +#define EIC_CONFIG_SENSE4(value) ((EIC_CONFIG_SENSE4_Msk & ((value) << EIC_CONFIG_SENSE4_Pos))) +#define EIC_CONFIG_SENSE4_NONE_Val 0x0u /**< \brief (EIC_CONFIG) No detection */ +#define EIC_CONFIG_SENSE4_RISE_Val 0x1u /**< \brief (EIC_CONFIG) Rising edge detection */ +#define EIC_CONFIG_SENSE4_FALL_Val 0x2u /**< \brief (EIC_CONFIG) Falling edge detection */ +#define EIC_CONFIG_SENSE4_BOTH_Val 0x3u /**< \brief (EIC_CONFIG) Both edges detection */ +#define EIC_CONFIG_SENSE4_HIGH_Val 0x4u /**< \brief (EIC_CONFIG) High level detection */ +#define EIC_CONFIG_SENSE4_LOW_Val 0x5u /**< \brief (EIC_CONFIG) Low level detection */ +#define EIC_CONFIG_SENSE4_NONE (EIC_CONFIG_SENSE4_NONE_Val << EIC_CONFIG_SENSE4_Pos) +#define EIC_CONFIG_SENSE4_RISE (EIC_CONFIG_SENSE4_RISE_Val << EIC_CONFIG_SENSE4_Pos) +#define EIC_CONFIG_SENSE4_FALL (EIC_CONFIG_SENSE4_FALL_Val << EIC_CONFIG_SENSE4_Pos) +#define EIC_CONFIG_SENSE4_BOTH (EIC_CONFIG_SENSE4_BOTH_Val << EIC_CONFIG_SENSE4_Pos) +#define EIC_CONFIG_SENSE4_HIGH (EIC_CONFIG_SENSE4_HIGH_Val << EIC_CONFIG_SENSE4_Pos) +#define EIC_CONFIG_SENSE4_LOW (EIC_CONFIG_SENSE4_LOW_Val << EIC_CONFIG_SENSE4_Pos) +#define EIC_CONFIG_FILTEN4_Pos 19 /**< \brief (EIC_CONFIG) Filter 4 Enable */ +#define EIC_CONFIG_FILTEN4 (0x1u << EIC_CONFIG_FILTEN4_Pos) +#define EIC_CONFIG_SENSE5_Pos 20 /**< \brief (EIC_CONFIG) Input Sense 5 Configuration */ +#define EIC_CONFIG_SENSE5_Msk (0x7u << EIC_CONFIG_SENSE5_Pos) +#define EIC_CONFIG_SENSE5(value) ((EIC_CONFIG_SENSE5_Msk & ((value) << EIC_CONFIG_SENSE5_Pos))) +#define EIC_CONFIG_SENSE5_NONE_Val 0x0u /**< \brief (EIC_CONFIG) No detection */ +#define EIC_CONFIG_SENSE5_RISE_Val 0x1u /**< \brief (EIC_CONFIG) Rising edge detection */ +#define EIC_CONFIG_SENSE5_FALL_Val 0x2u /**< \brief (EIC_CONFIG) Falling edge detection */ +#define EIC_CONFIG_SENSE5_BOTH_Val 0x3u /**< \brief (EIC_CONFIG) Both edges detection */ +#define EIC_CONFIG_SENSE5_HIGH_Val 0x4u /**< \brief (EIC_CONFIG) High level detection */ +#define EIC_CONFIG_SENSE5_LOW_Val 0x5u /**< \brief (EIC_CONFIG) Low level detection */ +#define EIC_CONFIG_SENSE5_NONE (EIC_CONFIG_SENSE5_NONE_Val << EIC_CONFIG_SENSE5_Pos) +#define EIC_CONFIG_SENSE5_RISE (EIC_CONFIG_SENSE5_RISE_Val << EIC_CONFIG_SENSE5_Pos) +#define EIC_CONFIG_SENSE5_FALL (EIC_CONFIG_SENSE5_FALL_Val << EIC_CONFIG_SENSE5_Pos) +#define EIC_CONFIG_SENSE5_BOTH (EIC_CONFIG_SENSE5_BOTH_Val << EIC_CONFIG_SENSE5_Pos) +#define EIC_CONFIG_SENSE5_HIGH (EIC_CONFIG_SENSE5_HIGH_Val << EIC_CONFIG_SENSE5_Pos) +#define EIC_CONFIG_SENSE5_LOW (EIC_CONFIG_SENSE5_LOW_Val << EIC_CONFIG_SENSE5_Pos) +#define EIC_CONFIG_FILTEN5_Pos 23 /**< \brief (EIC_CONFIG) Filter 5 Enable */ +#define EIC_CONFIG_FILTEN5 (0x1u << EIC_CONFIG_FILTEN5_Pos) +#define EIC_CONFIG_SENSE6_Pos 24 /**< \brief (EIC_CONFIG) Input Sense 6 Configuration */ +#define EIC_CONFIG_SENSE6_Msk (0x7u << EIC_CONFIG_SENSE6_Pos) +#define EIC_CONFIG_SENSE6(value) ((EIC_CONFIG_SENSE6_Msk & ((value) << EIC_CONFIG_SENSE6_Pos))) +#define EIC_CONFIG_SENSE6_NONE_Val 0x0u /**< \brief (EIC_CONFIG) No detection */ +#define EIC_CONFIG_SENSE6_RISE_Val 0x1u /**< \brief (EIC_CONFIG) Rising edge detection */ +#define EIC_CONFIG_SENSE6_FALL_Val 0x2u /**< \brief (EIC_CONFIG) Falling edge detection */ +#define EIC_CONFIG_SENSE6_BOTH_Val 0x3u /**< \brief (EIC_CONFIG) Both edges detection */ +#define EIC_CONFIG_SENSE6_HIGH_Val 0x4u /**< \brief (EIC_CONFIG) High level detection */ +#define EIC_CONFIG_SENSE6_LOW_Val 0x5u /**< \brief (EIC_CONFIG) Low level detection */ +#define EIC_CONFIG_SENSE6_NONE (EIC_CONFIG_SENSE6_NONE_Val << EIC_CONFIG_SENSE6_Pos) +#define EIC_CONFIG_SENSE6_RISE (EIC_CONFIG_SENSE6_RISE_Val << EIC_CONFIG_SENSE6_Pos) +#define EIC_CONFIG_SENSE6_FALL (EIC_CONFIG_SENSE6_FALL_Val << EIC_CONFIG_SENSE6_Pos) +#define EIC_CONFIG_SENSE6_BOTH (EIC_CONFIG_SENSE6_BOTH_Val << EIC_CONFIG_SENSE6_Pos) +#define EIC_CONFIG_SENSE6_HIGH (EIC_CONFIG_SENSE6_HIGH_Val << EIC_CONFIG_SENSE6_Pos) +#define EIC_CONFIG_SENSE6_LOW (EIC_CONFIG_SENSE6_LOW_Val << EIC_CONFIG_SENSE6_Pos) +#define EIC_CONFIG_FILTEN6_Pos 27 /**< \brief (EIC_CONFIG) Filter 6 Enable */ +#define EIC_CONFIG_FILTEN6 (0x1u << EIC_CONFIG_FILTEN6_Pos) +#define EIC_CONFIG_SENSE7_Pos 28 /**< \brief (EIC_CONFIG) Input Sense 7 Configuration */ +#define EIC_CONFIG_SENSE7_Msk (0x7u << EIC_CONFIG_SENSE7_Pos) +#define EIC_CONFIG_SENSE7(value) ((EIC_CONFIG_SENSE7_Msk & ((value) << EIC_CONFIG_SENSE7_Pos))) +#define EIC_CONFIG_SENSE7_NONE_Val 0x0u /**< \brief (EIC_CONFIG) No detection */ +#define EIC_CONFIG_SENSE7_RISE_Val 0x1u /**< \brief (EIC_CONFIG) Rising edge detection */ +#define EIC_CONFIG_SENSE7_FALL_Val 0x2u /**< \brief (EIC_CONFIG) Falling edge detection */ +#define EIC_CONFIG_SENSE7_BOTH_Val 0x3u /**< \brief (EIC_CONFIG) Both edges detection */ +#define EIC_CONFIG_SENSE7_HIGH_Val 0x4u /**< \brief (EIC_CONFIG) High level detection */ +#define EIC_CONFIG_SENSE7_LOW_Val 0x5u /**< \brief (EIC_CONFIG) Low level detection */ +#define EIC_CONFIG_SENSE7_NONE (EIC_CONFIG_SENSE7_NONE_Val << EIC_CONFIG_SENSE7_Pos) +#define EIC_CONFIG_SENSE7_RISE (EIC_CONFIG_SENSE7_RISE_Val << EIC_CONFIG_SENSE7_Pos) +#define EIC_CONFIG_SENSE7_FALL (EIC_CONFIG_SENSE7_FALL_Val << EIC_CONFIG_SENSE7_Pos) +#define EIC_CONFIG_SENSE7_BOTH (EIC_CONFIG_SENSE7_BOTH_Val << EIC_CONFIG_SENSE7_Pos) +#define EIC_CONFIG_SENSE7_HIGH (EIC_CONFIG_SENSE7_HIGH_Val << EIC_CONFIG_SENSE7_Pos) +#define EIC_CONFIG_SENSE7_LOW (EIC_CONFIG_SENSE7_LOW_Val << EIC_CONFIG_SENSE7_Pos) +#define EIC_CONFIG_FILTEN7_Pos 31 /**< \brief (EIC_CONFIG) Filter 7 Enable */ +#define EIC_CONFIG_FILTEN7 (0x1u << EIC_CONFIG_FILTEN7_Pos) +#define EIC_CONFIG_MASK 0xFFFFFFFFu /**< \brief (EIC_CONFIG) MASK Register */ + +/** \brief EIC hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO EIC_CTRL_Type CTRL; /**< \brief Offset: 0x00 (R/W 8) Control */ + __I EIC_STATUS_Type STATUS; /**< \brief Offset: 0x01 (R/ 8) Status */ + __IO EIC_NMICTRL_Type NMICTRL; /**< \brief Offset: 0x02 (R/W 8) Non-Maskable Interrupt Control */ + __IO EIC_NMIFLAG_Type NMIFLAG; /**< \brief Offset: 0x03 (R/W 8) Non-Maskable Interrupt Flag Status and Clear */ + __IO EIC_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x04 (R/W 32) Event Control */ + __IO EIC_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x08 (R/W 32) Interrupt Enable Clear */ + __IO EIC_INTENSET_Type INTENSET; /**< \brief Offset: 0x0C (R/W 32) Interrupt Enable Set */ + __IO EIC_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x10 (R/W 32) Interrupt Flag Status and Clear */ + __IO EIC_WAKEUP_Type WAKEUP; /**< \brief Offset: 0x14 (R/W 32) Wake-Up Enable */ + __IO EIC_CONFIG_Type CONFIG[2]; /**< \brief Offset: 0x18 (R/W 32) Configuration n */ +} Eic; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_EIC_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/evsys.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/evsys.h new file mode 100755 index 0000000..c036ecf --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/evsys.h @@ -0,0 +1,604 @@ +/** + * \file + * + * \brief Component description for EVSYS + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_EVSYS_COMPONENT_ +#define _SAMD21_EVSYS_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR EVSYS */ +/* ========================================================================== */ +/** \addtogroup SAMD21_EVSYS Event System Interface */ +/*@{*/ + +#define EVSYS_U2208 +#define REV_EVSYS 0x101 + +/* -------- EVSYS_CTRL : (EVSYS Offset: 0x00) ( /W 8) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset */ + uint8_t :3; /*!< bit: 1.. 3 Reserved */ + uint8_t GCLKREQ:1; /*!< bit: 4 Generic Clock Requests */ + uint8_t :3; /*!< bit: 5.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} EVSYS_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EVSYS_CTRL_OFFSET 0x00 /**< \brief (EVSYS_CTRL offset) Control */ +#define EVSYS_CTRL_RESETVALUE 0x00 /**< \brief (EVSYS_CTRL reset_value) Control */ + +#define EVSYS_CTRL_SWRST_Pos 0 /**< \brief (EVSYS_CTRL) Software Reset */ +#define EVSYS_CTRL_SWRST (0x1u << EVSYS_CTRL_SWRST_Pos) +#define EVSYS_CTRL_GCLKREQ_Pos 4 /**< \brief (EVSYS_CTRL) Generic Clock Requests */ +#define EVSYS_CTRL_GCLKREQ (0x1u << EVSYS_CTRL_GCLKREQ_Pos) +#define EVSYS_CTRL_MASK 0x11u /**< \brief (EVSYS_CTRL) MASK Register */ + +/* -------- EVSYS_CHANNEL : (EVSYS Offset: 0x04) (R/W 32) Channel -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CHANNEL:4; /*!< bit: 0.. 3 Channel Selection */ + uint32_t :4; /*!< bit: 4.. 7 Reserved */ + uint32_t SWEVT:1; /*!< bit: 8 Software Event */ + uint32_t :7; /*!< bit: 9..15 Reserved */ + uint32_t EVGEN:7; /*!< bit: 16..22 Event Generator Selection */ + uint32_t :1; /*!< bit: 23 Reserved */ + uint32_t PATH:2; /*!< bit: 24..25 Path Selection */ + uint32_t EDGSEL:2; /*!< bit: 26..27 Edge Detection Selection */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} EVSYS_CHANNEL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EVSYS_CHANNEL_OFFSET 0x04 /**< \brief (EVSYS_CHANNEL offset) Channel */ +#define EVSYS_CHANNEL_RESETVALUE 0x00000000 /**< \brief (EVSYS_CHANNEL reset_value) Channel */ + +#define EVSYS_CHANNEL_CHANNEL_Pos 0 /**< \brief (EVSYS_CHANNEL) Channel Selection */ +#define EVSYS_CHANNEL_CHANNEL_Msk (0xFu << EVSYS_CHANNEL_CHANNEL_Pos) +#define EVSYS_CHANNEL_CHANNEL(value) ((EVSYS_CHANNEL_CHANNEL_Msk & ((value) << EVSYS_CHANNEL_CHANNEL_Pos))) +#define EVSYS_CHANNEL_SWEVT_Pos 8 /**< \brief (EVSYS_CHANNEL) Software Event */ +#define EVSYS_CHANNEL_SWEVT (0x1u << EVSYS_CHANNEL_SWEVT_Pos) +#define EVSYS_CHANNEL_EVGEN_Pos 16 /**< \brief (EVSYS_CHANNEL) Event Generator Selection */ +#define EVSYS_CHANNEL_EVGEN_Msk (0x7Fu << EVSYS_CHANNEL_EVGEN_Pos) +#define EVSYS_CHANNEL_EVGEN(value) ((EVSYS_CHANNEL_EVGEN_Msk & ((value) << EVSYS_CHANNEL_EVGEN_Pos))) +#define EVSYS_CHANNEL_PATH_Pos 24 /**< \brief (EVSYS_CHANNEL) Path Selection */ +#define EVSYS_CHANNEL_PATH_Msk (0x3u << EVSYS_CHANNEL_PATH_Pos) +#define EVSYS_CHANNEL_PATH(value) ((EVSYS_CHANNEL_PATH_Msk & ((value) << EVSYS_CHANNEL_PATH_Pos))) +#define EVSYS_CHANNEL_PATH_SYNCHRONOUS_Val 0x0u /**< \brief (EVSYS_CHANNEL) Synchronous path */ +#define EVSYS_CHANNEL_PATH_RESYNCHRONIZED_Val 0x1u /**< \brief (EVSYS_CHANNEL) Resynchronized path */ +#define EVSYS_CHANNEL_PATH_ASYNCHRONOUS_Val 0x2u /**< \brief (EVSYS_CHANNEL) Asynchronous path */ +#define EVSYS_CHANNEL_PATH_SYNCHRONOUS (EVSYS_CHANNEL_PATH_SYNCHRONOUS_Val << EVSYS_CHANNEL_PATH_Pos) +#define EVSYS_CHANNEL_PATH_RESYNCHRONIZED (EVSYS_CHANNEL_PATH_RESYNCHRONIZED_Val << EVSYS_CHANNEL_PATH_Pos) +#define EVSYS_CHANNEL_PATH_ASYNCHRONOUS (EVSYS_CHANNEL_PATH_ASYNCHRONOUS_Val << EVSYS_CHANNEL_PATH_Pos) +#define EVSYS_CHANNEL_EDGSEL_Pos 26 /**< \brief (EVSYS_CHANNEL) Edge Detection Selection */ +#define EVSYS_CHANNEL_EDGSEL_Msk (0x3u << EVSYS_CHANNEL_EDGSEL_Pos) +#define EVSYS_CHANNEL_EDGSEL(value) ((EVSYS_CHANNEL_EDGSEL_Msk & ((value) << EVSYS_CHANNEL_EDGSEL_Pos))) +#define EVSYS_CHANNEL_EDGSEL_NO_EVT_OUTPUT_Val 0x0u /**< \brief (EVSYS_CHANNEL) No event output when using the resynchronized or synchronous path */ +#define EVSYS_CHANNEL_EDGSEL_RISING_EDGE_Val 0x1u /**< \brief (EVSYS_CHANNEL) Event detection only on the rising edge of the signal from the event generator when using the resynchronized or synchronous path */ +#define EVSYS_CHANNEL_EDGSEL_FALLING_EDGE_Val 0x2u /**< \brief (EVSYS_CHANNEL) Event detection only on the falling edge of the signal from the event generator when using the resynchronized or synchronous path */ +#define EVSYS_CHANNEL_EDGSEL_BOTH_EDGES_Val 0x3u /**< \brief (EVSYS_CHANNEL) Event detection on rising and falling edges of the signal from the event generator when using the resynchronized or synchronous path */ +#define EVSYS_CHANNEL_EDGSEL_NO_EVT_OUTPUT (EVSYS_CHANNEL_EDGSEL_NO_EVT_OUTPUT_Val << EVSYS_CHANNEL_EDGSEL_Pos) +#define EVSYS_CHANNEL_EDGSEL_RISING_EDGE (EVSYS_CHANNEL_EDGSEL_RISING_EDGE_Val << EVSYS_CHANNEL_EDGSEL_Pos) +#define EVSYS_CHANNEL_EDGSEL_FALLING_EDGE (EVSYS_CHANNEL_EDGSEL_FALLING_EDGE_Val << EVSYS_CHANNEL_EDGSEL_Pos) +#define EVSYS_CHANNEL_EDGSEL_BOTH_EDGES (EVSYS_CHANNEL_EDGSEL_BOTH_EDGES_Val << EVSYS_CHANNEL_EDGSEL_Pos) +#define EVSYS_CHANNEL_MASK 0x0F7F010Fu /**< \brief (EVSYS_CHANNEL) MASK Register */ + +/* -------- EVSYS_USER : (EVSYS Offset: 0x08) (R/W 16) User Multiplexer -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t USER:5; /*!< bit: 0.. 4 User Multiplexer Selection */ + uint16_t :3; /*!< bit: 5.. 7 Reserved */ + uint16_t CHANNEL:5; /*!< bit: 8..12 Channel Event Selection */ + uint16_t :3; /*!< bit: 13..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} EVSYS_USER_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EVSYS_USER_OFFSET 0x08 /**< \brief (EVSYS_USER offset) User Multiplexer */ +#define EVSYS_USER_RESETVALUE 0x0000 /**< \brief (EVSYS_USER reset_value) User Multiplexer */ + +#define EVSYS_USER_USER_Pos 0 /**< \brief (EVSYS_USER) User Multiplexer Selection */ +#define EVSYS_USER_USER_Msk (0x1Fu << EVSYS_USER_USER_Pos) +#define EVSYS_USER_USER(value) ((EVSYS_USER_USER_Msk & ((value) << EVSYS_USER_USER_Pos))) +#define EVSYS_USER_CHANNEL_Pos 8 /**< \brief (EVSYS_USER) Channel Event Selection */ +#define EVSYS_USER_CHANNEL_Msk (0x1Fu << EVSYS_USER_CHANNEL_Pos) +#define EVSYS_USER_CHANNEL(value) ((EVSYS_USER_CHANNEL_Msk & ((value) << EVSYS_USER_CHANNEL_Pos))) +#define EVSYS_USER_CHANNEL_0_Val 0x0u /**< \brief (EVSYS_USER) No Channel Output Selected */ +#define EVSYS_USER_CHANNEL_0 (EVSYS_USER_CHANNEL_0_Val << EVSYS_USER_CHANNEL_Pos) +#define EVSYS_USER_MASK 0x1F1Fu /**< \brief (EVSYS_USER) MASK Register */ + +/* -------- EVSYS_CHSTATUS : (EVSYS Offset: 0x0C) (R/ 32) Channel Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t USRRDY0:1; /*!< bit: 0 Channel 0 User Ready */ + uint32_t USRRDY1:1; /*!< bit: 1 Channel 1 User Ready */ + uint32_t USRRDY2:1; /*!< bit: 2 Channel 2 User Ready */ + uint32_t USRRDY3:1; /*!< bit: 3 Channel 3 User Ready */ + uint32_t USRRDY4:1; /*!< bit: 4 Channel 4 User Ready */ + uint32_t USRRDY5:1; /*!< bit: 5 Channel 5 User Ready */ + uint32_t USRRDY6:1; /*!< bit: 6 Channel 6 User Ready */ + uint32_t USRRDY7:1; /*!< bit: 7 Channel 7 User Ready */ + uint32_t CHBUSY0:1; /*!< bit: 8 Channel 0 Busy */ + uint32_t CHBUSY1:1; /*!< bit: 9 Channel 1 Busy */ + uint32_t CHBUSY2:1; /*!< bit: 10 Channel 2 Busy */ + uint32_t CHBUSY3:1; /*!< bit: 11 Channel 3 Busy */ + uint32_t CHBUSY4:1; /*!< bit: 12 Channel 4 Busy */ + uint32_t CHBUSY5:1; /*!< bit: 13 Channel 5 Busy */ + uint32_t CHBUSY6:1; /*!< bit: 14 Channel 6 Busy */ + uint32_t CHBUSY7:1; /*!< bit: 15 Channel 7 Busy */ + uint32_t USRRDY8:1; /*!< bit: 16 Channel 8 User Ready */ + uint32_t USRRDY9:1; /*!< bit: 17 Channel 9 User Ready */ + uint32_t USRRDY10:1; /*!< bit: 18 Channel 10 User Ready */ + uint32_t USRRDY11:1; /*!< bit: 19 Channel 11 User Ready */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t CHBUSY8:1; /*!< bit: 24 Channel 8 Busy */ + uint32_t CHBUSY9:1; /*!< bit: 25 Channel 9 Busy */ + uint32_t CHBUSY10:1; /*!< bit: 26 Channel 10 Busy */ + uint32_t CHBUSY11:1; /*!< bit: 27 Channel 11 Busy */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t USRRDY:8; /*!< bit: 0.. 7 Channel x User Ready */ + uint32_t CHBUSY:8; /*!< bit: 8..15 Channel x Busy */ + uint32_t USRRDYp8:4; /*!< bit: 16..19 Channel x+8 User Ready */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t CHBUSYp8:4; /*!< bit: 24..27 Channel x+8 Busy */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} EVSYS_CHSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EVSYS_CHSTATUS_OFFSET 0x0C /**< \brief (EVSYS_CHSTATUS offset) Channel Status */ +#define EVSYS_CHSTATUS_RESETVALUE 0x000F00FF /**< \brief (EVSYS_CHSTATUS reset_value) Channel Status */ + +#define EVSYS_CHSTATUS_USRRDY0_Pos 0 /**< \brief (EVSYS_CHSTATUS) Channel 0 User Ready */ +#define EVSYS_CHSTATUS_USRRDY0 (1 << EVSYS_CHSTATUS_USRRDY0_Pos) +#define EVSYS_CHSTATUS_USRRDY1_Pos 1 /**< \brief (EVSYS_CHSTATUS) Channel 1 User Ready */ +#define EVSYS_CHSTATUS_USRRDY1 (1 << EVSYS_CHSTATUS_USRRDY1_Pos) +#define EVSYS_CHSTATUS_USRRDY2_Pos 2 /**< \brief (EVSYS_CHSTATUS) Channel 2 User Ready */ +#define EVSYS_CHSTATUS_USRRDY2 (1 << EVSYS_CHSTATUS_USRRDY2_Pos) +#define EVSYS_CHSTATUS_USRRDY3_Pos 3 /**< \brief (EVSYS_CHSTATUS) Channel 3 User Ready */ +#define EVSYS_CHSTATUS_USRRDY3 (1 << EVSYS_CHSTATUS_USRRDY3_Pos) +#define EVSYS_CHSTATUS_USRRDY4_Pos 4 /**< \brief (EVSYS_CHSTATUS) Channel 4 User Ready */ +#define EVSYS_CHSTATUS_USRRDY4 (1 << EVSYS_CHSTATUS_USRRDY4_Pos) +#define EVSYS_CHSTATUS_USRRDY5_Pos 5 /**< \brief (EVSYS_CHSTATUS) Channel 5 User Ready */ +#define EVSYS_CHSTATUS_USRRDY5 (1 << EVSYS_CHSTATUS_USRRDY5_Pos) +#define EVSYS_CHSTATUS_USRRDY6_Pos 6 /**< \brief (EVSYS_CHSTATUS) Channel 6 User Ready */ +#define EVSYS_CHSTATUS_USRRDY6 (1 << EVSYS_CHSTATUS_USRRDY6_Pos) +#define EVSYS_CHSTATUS_USRRDY7_Pos 7 /**< \brief (EVSYS_CHSTATUS) Channel 7 User Ready */ +#define EVSYS_CHSTATUS_USRRDY7 (1 << EVSYS_CHSTATUS_USRRDY7_Pos) +#define EVSYS_CHSTATUS_USRRDY_Pos 0 /**< \brief (EVSYS_CHSTATUS) Channel x User Ready */ +#define EVSYS_CHSTATUS_USRRDY_Msk (0xFFu << EVSYS_CHSTATUS_USRRDY_Pos) +#define EVSYS_CHSTATUS_USRRDY(value) ((EVSYS_CHSTATUS_USRRDY_Msk & ((value) << EVSYS_CHSTATUS_USRRDY_Pos))) +#define EVSYS_CHSTATUS_CHBUSY0_Pos 8 /**< \brief (EVSYS_CHSTATUS) Channel 0 Busy */ +#define EVSYS_CHSTATUS_CHBUSY0 (1 << EVSYS_CHSTATUS_CHBUSY0_Pos) +#define EVSYS_CHSTATUS_CHBUSY1_Pos 9 /**< \brief (EVSYS_CHSTATUS) Channel 1 Busy */ +#define EVSYS_CHSTATUS_CHBUSY1 (1 << EVSYS_CHSTATUS_CHBUSY1_Pos) +#define EVSYS_CHSTATUS_CHBUSY2_Pos 10 /**< \brief (EVSYS_CHSTATUS) Channel 2 Busy */ +#define EVSYS_CHSTATUS_CHBUSY2 (1 << EVSYS_CHSTATUS_CHBUSY2_Pos) +#define EVSYS_CHSTATUS_CHBUSY3_Pos 11 /**< \brief (EVSYS_CHSTATUS) Channel 3 Busy */ +#define EVSYS_CHSTATUS_CHBUSY3 (1 << EVSYS_CHSTATUS_CHBUSY3_Pos) +#define EVSYS_CHSTATUS_CHBUSY4_Pos 12 /**< \brief (EVSYS_CHSTATUS) Channel 4 Busy */ +#define EVSYS_CHSTATUS_CHBUSY4 (1 << EVSYS_CHSTATUS_CHBUSY4_Pos) +#define EVSYS_CHSTATUS_CHBUSY5_Pos 13 /**< \brief (EVSYS_CHSTATUS) Channel 5 Busy */ +#define EVSYS_CHSTATUS_CHBUSY5 (1 << EVSYS_CHSTATUS_CHBUSY5_Pos) +#define EVSYS_CHSTATUS_CHBUSY6_Pos 14 /**< \brief (EVSYS_CHSTATUS) Channel 6 Busy */ +#define EVSYS_CHSTATUS_CHBUSY6 (1 << EVSYS_CHSTATUS_CHBUSY6_Pos) +#define EVSYS_CHSTATUS_CHBUSY7_Pos 15 /**< \brief (EVSYS_CHSTATUS) Channel 7 Busy */ +#define EVSYS_CHSTATUS_CHBUSY7 (1 << EVSYS_CHSTATUS_CHBUSY7_Pos) +#define EVSYS_CHSTATUS_CHBUSY_Pos 8 /**< \brief (EVSYS_CHSTATUS) Channel x Busy */ +#define EVSYS_CHSTATUS_CHBUSY_Msk (0xFFu << EVSYS_CHSTATUS_CHBUSY_Pos) +#define EVSYS_CHSTATUS_CHBUSY(value) ((EVSYS_CHSTATUS_CHBUSY_Msk & ((value) << EVSYS_CHSTATUS_CHBUSY_Pos))) +#define EVSYS_CHSTATUS_USRRDY8_Pos 16 /**< \brief (EVSYS_CHSTATUS) Channel 8 User Ready */ +#define EVSYS_CHSTATUS_USRRDY8 (1 << EVSYS_CHSTATUS_USRRDY8_Pos) +#define EVSYS_CHSTATUS_USRRDY9_Pos 17 /**< \brief (EVSYS_CHSTATUS) Channel 9 User Ready */ +#define EVSYS_CHSTATUS_USRRDY9 (1 << EVSYS_CHSTATUS_USRRDY9_Pos) +#define EVSYS_CHSTATUS_USRRDY10_Pos 18 /**< \brief (EVSYS_CHSTATUS) Channel 10 User Ready */ +#define EVSYS_CHSTATUS_USRRDY10 (1 << EVSYS_CHSTATUS_USRRDY10_Pos) +#define EVSYS_CHSTATUS_USRRDY11_Pos 19 /**< \brief (EVSYS_CHSTATUS) Channel 11 User Ready */ +#define EVSYS_CHSTATUS_USRRDY11 (1 << EVSYS_CHSTATUS_USRRDY11_Pos) +#define EVSYS_CHSTATUS_USRRDYp8_Pos 16 /**< \brief (EVSYS_CHSTATUS) Channel x+8 User Ready */ +#define EVSYS_CHSTATUS_USRRDYp8_Msk (0xFu << EVSYS_CHSTATUS_USRRDYp8_Pos) +#define EVSYS_CHSTATUS_USRRDYp8(value) ((EVSYS_CHSTATUS_USRRDYp8_Msk & ((value) << EVSYS_CHSTATUS_USRRDYp8_Pos))) +#define EVSYS_CHSTATUS_CHBUSY8_Pos 24 /**< \brief (EVSYS_CHSTATUS) Channel 8 Busy */ +#define EVSYS_CHSTATUS_CHBUSY8 (1 << EVSYS_CHSTATUS_CHBUSY8_Pos) +#define EVSYS_CHSTATUS_CHBUSY9_Pos 25 /**< \brief (EVSYS_CHSTATUS) Channel 9 Busy */ +#define EVSYS_CHSTATUS_CHBUSY9 (1 << EVSYS_CHSTATUS_CHBUSY9_Pos) +#define EVSYS_CHSTATUS_CHBUSY10_Pos 26 /**< \brief (EVSYS_CHSTATUS) Channel 10 Busy */ +#define EVSYS_CHSTATUS_CHBUSY10 (1 << EVSYS_CHSTATUS_CHBUSY10_Pos) +#define EVSYS_CHSTATUS_CHBUSY11_Pos 27 /**< \brief (EVSYS_CHSTATUS) Channel 11 Busy */ +#define EVSYS_CHSTATUS_CHBUSY11 (1 << EVSYS_CHSTATUS_CHBUSY11_Pos) +#define EVSYS_CHSTATUS_CHBUSYp8_Pos 24 /**< \brief (EVSYS_CHSTATUS) Channel x+8 Busy */ +#define EVSYS_CHSTATUS_CHBUSYp8_Msk (0xFu << EVSYS_CHSTATUS_CHBUSYp8_Pos) +#define EVSYS_CHSTATUS_CHBUSYp8(value) ((EVSYS_CHSTATUS_CHBUSYp8_Msk & ((value) << EVSYS_CHSTATUS_CHBUSYp8_Pos))) +#define EVSYS_CHSTATUS_MASK 0x0F0FFFFFu /**< \brief (EVSYS_CHSTATUS) MASK Register */ + +/* -------- EVSYS_INTENCLR : (EVSYS Offset: 0x10) (R/W 32) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OVR0:1; /*!< bit: 0 Channel 0 Overrun Interrupt Enable */ + uint32_t OVR1:1; /*!< bit: 1 Channel 1 Overrun Interrupt Enable */ + uint32_t OVR2:1; /*!< bit: 2 Channel 2 Overrun Interrupt Enable */ + uint32_t OVR3:1; /*!< bit: 3 Channel 3 Overrun Interrupt Enable */ + uint32_t OVR4:1; /*!< bit: 4 Channel 4 Overrun Interrupt Enable */ + uint32_t OVR5:1; /*!< bit: 5 Channel 5 Overrun Interrupt Enable */ + uint32_t OVR6:1; /*!< bit: 6 Channel 6 Overrun Interrupt Enable */ + uint32_t OVR7:1; /*!< bit: 7 Channel 7 Overrun Interrupt Enable */ + uint32_t EVD0:1; /*!< bit: 8 Channel 0 Event Detection Interrupt Enable */ + uint32_t EVD1:1; /*!< bit: 9 Channel 1 Event Detection Interrupt Enable */ + uint32_t EVD2:1; /*!< bit: 10 Channel 2 Event Detection Interrupt Enable */ + uint32_t EVD3:1; /*!< bit: 11 Channel 3 Event Detection Interrupt Enable */ + uint32_t EVD4:1; /*!< bit: 12 Channel 4 Event Detection Interrupt Enable */ + uint32_t EVD5:1; /*!< bit: 13 Channel 5 Event Detection Interrupt Enable */ + uint32_t EVD6:1; /*!< bit: 14 Channel 6 Event Detection Interrupt Enable */ + uint32_t EVD7:1; /*!< bit: 15 Channel 7 Event Detection Interrupt Enable */ + uint32_t OVR8:1; /*!< bit: 16 Channel 8 Overrun Interrupt Enable */ + uint32_t OVR9:1; /*!< bit: 17 Channel 9 Overrun Interrupt Enable */ + uint32_t OVR10:1; /*!< bit: 18 Channel 10 Overrun Interrupt Enable */ + uint32_t OVR11:1; /*!< bit: 19 Channel 11 Overrun Interrupt Enable */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t EVD8:1; /*!< bit: 24 Channel 8 Event Detection Interrupt Enable */ + uint32_t EVD9:1; /*!< bit: 25 Channel 9 Event Detection Interrupt Enable */ + uint32_t EVD10:1; /*!< bit: 26 Channel 10 Event Detection Interrupt Enable */ + uint32_t EVD11:1; /*!< bit: 27 Channel 11 Event Detection Interrupt Enable */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t OVR:8; /*!< bit: 0.. 7 Channel x Overrun Interrupt Enable */ + uint32_t EVD:8; /*!< bit: 8..15 Channel x Event Detection Interrupt Enable */ + uint32_t OVRp8:4; /*!< bit: 16..19 Channel x+8 Overrun Interrupt Enable */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t EVDp8:4; /*!< bit: 24..27 Channel x+8 Event Detection Interrupt Enable */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} EVSYS_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EVSYS_INTENCLR_OFFSET 0x10 /**< \brief (EVSYS_INTENCLR offset) Interrupt Enable Clear */ +#define EVSYS_INTENCLR_RESETVALUE 0x00000000 /**< \brief (EVSYS_INTENCLR reset_value) Interrupt Enable Clear */ + +#define EVSYS_INTENCLR_OVR0_Pos 0 /**< \brief (EVSYS_INTENCLR) Channel 0 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR0 (1 << EVSYS_INTENCLR_OVR0_Pos) +#define EVSYS_INTENCLR_OVR1_Pos 1 /**< \brief (EVSYS_INTENCLR) Channel 1 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR1 (1 << EVSYS_INTENCLR_OVR1_Pos) +#define EVSYS_INTENCLR_OVR2_Pos 2 /**< \brief (EVSYS_INTENCLR) Channel 2 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR2 (1 << EVSYS_INTENCLR_OVR2_Pos) +#define EVSYS_INTENCLR_OVR3_Pos 3 /**< \brief (EVSYS_INTENCLR) Channel 3 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR3 (1 << EVSYS_INTENCLR_OVR3_Pos) +#define EVSYS_INTENCLR_OVR4_Pos 4 /**< \brief (EVSYS_INTENCLR) Channel 4 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR4 (1 << EVSYS_INTENCLR_OVR4_Pos) +#define EVSYS_INTENCLR_OVR5_Pos 5 /**< \brief (EVSYS_INTENCLR) Channel 5 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR5 (1 << EVSYS_INTENCLR_OVR5_Pos) +#define EVSYS_INTENCLR_OVR6_Pos 6 /**< \brief (EVSYS_INTENCLR) Channel 6 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR6 (1 << EVSYS_INTENCLR_OVR6_Pos) +#define EVSYS_INTENCLR_OVR7_Pos 7 /**< \brief (EVSYS_INTENCLR) Channel 7 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR7 (1 << EVSYS_INTENCLR_OVR7_Pos) +#define EVSYS_INTENCLR_OVR_Pos 0 /**< \brief (EVSYS_INTENCLR) Channel x Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR_Msk (0xFFu << EVSYS_INTENCLR_OVR_Pos) +#define EVSYS_INTENCLR_OVR(value) ((EVSYS_INTENCLR_OVR_Msk & ((value) << EVSYS_INTENCLR_OVR_Pos))) +#define EVSYS_INTENCLR_EVD0_Pos 8 /**< \brief (EVSYS_INTENCLR) Channel 0 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD0 (1 << EVSYS_INTENCLR_EVD0_Pos) +#define EVSYS_INTENCLR_EVD1_Pos 9 /**< \brief (EVSYS_INTENCLR) Channel 1 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD1 (1 << EVSYS_INTENCLR_EVD1_Pos) +#define EVSYS_INTENCLR_EVD2_Pos 10 /**< \brief (EVSYS_INTENCLR) Channel 2 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD2 (1 << EVSYS_INTENCLR_EVD2_Pos) +#define EVSYS_INTENCLR_EVD3_Pos 11 /**< \brief (EVSYS_INTENCLR) Channel 3 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD3 (1 << EVSYS_INTENCLR_EVD3_Pos) +#define EVSYS_INTENCLR_EVD4_Pos 12 /**< \brief (EVSYS_INTENCLR) Channel 4 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD4 (1 << EVSYS_INTENCLR_EVD4_Pos) +#define EVSYS_INTENCLR_EVD5_Pos 13 /**< \brief (EVSYS_INTENCLR) Channel 5 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD5 (1 << EVSYS_INTENCLR_EVD5_Pos) +#define EVSYS_INTENCLR_EVD6_Pos 14 /**< \brief (EVSYS_INTENCLR) Channel 6 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD6 (1 << EVSYS_INTENCLR_EVD6_Pos) +#define EVSYS_INTENCLR_EVD7_Pos 15 /**< \brief (EVSYS_INTENCLR) Channel 7 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD7 (1 << EVSYS_INTENCLR_EVD7_Pos) +#define EVSYS_INTENCLR_EVD_Pos 8 /**< \brief (EVSYS_INTENCLR) Channel x Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD_Msk (0xFFu << EVSYS_INTENCLR_EVD_Pos) +#define EVSYS_INTENCLR_EVD(value) ((EVSYS_INTENCLR_EVD_Msk & ((value) << EVSYS_INTENCLR_EVD_Pos))) +#define EVSYS_INTENCLR_OVR8_Pos 16 /**< \brief (EVSYS_INTENCLR) Channel 8 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR8 (1 << EVSYS_INTENCLR_OVR8_Pos) +#define EVSYS_INTENCLR_OVR9_Pos 17 /**< \brief (EVSYS_INTENCLR) Channel 9 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR9 (1 << EVSYS_INTENCLR_OVR9_Pos) +#define EVSYS_INTENCLR_OVR10_Pos 18 /**< \brief (EVSYS_INTENCLR) Channel 10 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR10 (1 << EVSYS_INTENCLR_OVR10_Pos) +#define EVSYS_INTENCLR_OVR11_Pos 19 /**< \brief (EVSYS_INTENCLR) Channel 11 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVR11 (1 << EVSYS_INTENCLR_OVR11_Pos) +#define EVSYS_INTENCLR_OVRp8_Pos 16 /**< \brief (EVSYS_INTENCLR) Channel x+8 Overrun Interrupt Enable */ +#define EVSYS_INTENCLR_OVRp8_Msk (0xFu << EVSYS_INTENCLR_OVRp8_Pos) +#define EVSYS_INTENCLR_OVRp8(value) ((EVSYS_INTENCLR_OVRp8_Msk & ((value) << EVSYS_INTENCLR_OVRp8_Pos))) +#define EVSYS_INTENCLR_EVD8_Pos 24 /**< \brief (EVSYS_INTENCLR) Channel 8 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD8 (1 << EVSYS_INTENCLR_EVD8_Pos) +#define EVSYS_INTENCLR_EVD9_Pos 25 /**< \brief (EVSYS_INTENCLR) Channel 9 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD9 (1 << EVSYS_INTENCLR_EVD9_Pos) +#define EVSYS_INTENCLR_EVD10_Pos 26 /**< \brief (EVSYS_INTENCLR) Channel 10 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD10 (1 << EVSYS_INTENCLR_EVD10_Pos) +#define EVSYS_INTENCLR_EVD11_Pos 27 /**< \brief (EVSYS_INTENCLR) Channel 11 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVD11 (1 << EVSYS_INTENCLR_EVD11_Pos) +#define EVSYS_INTENCLR_EVDp8_Pos 24 /**< \brief (EVSYS_INTENCLR) Channel x+8 Event Detection Interrupt Enable */ +#define EVSYS_INTENCLR_EVDp8_Msk (0xFu << EVSYS_INTENCLR_EVDp8_Pos) +#define EVSYS_INTENCLR_EVDp8(value) ((EVSYS_INTENCLR_EVDp8_Msk & ((value) << EVSYS_INTENCLR_EVDp8_Pos))) +#define EVSYS_INTENCLR_MASK 0x0F0FFFFFu /**< \brief (EVSYS_INTENCLR) MASK Register */ + +/* -------- EVSYS_INTENSET : (EVSYS Offset: 0x14) (R/W 32) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OVR0:1; /*!< bit: 0 Channel 0 Overrun Interrupt Enable */ + uint32_t OVR1:1; /*!< bit: 1 Channel 1 Overrun Interrupt Enable */ + uint32_t OVR2:1; /*!< bit: 2 Channel 2 Overrun Interrupt Enable */ + uint32_t OVR3:1; /*!< bit: 3 Channel 3 Overrun Interrupt Enable */ + uint32_t OVR4:1; /*!< bit: 4 Channel 4 Overrun Interrupt Enable */ + uint32_t OVR5:1; /*!< bit: 5 Channel 5 Overrun Interrupt Enable */ + uint32_t OVR6:1; /*!< bit: 6 Channel 6 Overrun Interrupt Enable */ + uint32_t OVR7:1; /*!< bit: 7 Channel 7 Overrun Interrupt Enable */ + uint32_t EVD0:1; /*!< bit: 8 Channel 0 Event Detection Interrupt Enable */ + uint32_t EVD1:1; /*!< bit: 9 Channel 1 Event Detection Interrupt Enable */ + uint32_t EVD2:1; /*!< bit: 10 Channel 2 Event Detection Interrupt Enable */ + uint32_t EVD3:1; /*!< bit: 11 Channel 3 Event Detection Interrupt Enable */ + uint32_t EVD4:1; /*!< bit: 12 Channel 4 Event Detection Interrupt Enable */ + uint32_t EVD5:1; /*!< bit: 13 Channel 5 Event Detection Interrupt Enable */ + uint32_t EVD6:1; /*!< bit: 14 Channel 6 Event Detection Interrupt Enable */ + uint32_t EVD7:1; /*!< bit: 15 Channel 7 Event Detection Interrupt Enable */ + uint32_t OVR8:1; /*!< bit: 16 Channel 8 Overrun Interrupt Enable */ + uint32_t OVR9:1; /*!< bit: 17 Channel 9 Overrun Interrupt Enable */ + uint32_t OVR10:1; /*!< bit: 18 Channel 10 Overrun Interrupt Enable */ + uint32_t OVR11:1; /*!< bit: 19 Channel 11 Overrun Interrupt Enable */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t EVD8:1; /*!< bit: 24 Channel 8 Event Detection Interrupt Enable */ + uint32_t EVD9:1; /*!< bit: 25 Channel 9 Event Detection Interrupt Enable */ + uint32_t EVD10:1; /*!< bit: 26 Channel 10 Event Detection Interrupt Enable */ + uint32_t EVD11:1; /*!< bit: 27 Channel 11 Event Detection Interrupt Enable */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t OVR:8; /*!< bit: 0.. 7 Channel x Overrun Interrupt Enable */ + uint32_t EVD:8; /*!< bit: 8..15 Channel x Event Detection Interrupt Enable */ + uint32_t OVRp8:4; /*!< bit: 16..19 Channel x+8 Overrun Interrupt Enable */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t EVDp8:4; /*!< bit: 24..27 Channel x+8 Event Detection Interrupt Enable */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} EVSYS_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EVSYS_INTENSET_OFFSET 0x14 /**< \brief (EVSYS_INTENSET offset) Interrupt Enable Set */ +#define EVSYS_INTENSET_RESETVALUE 0x00000000 /**< \brief (EVSYS_INTENSET reset_value) Interrupt Enable Set */ + +#define EVSYS_INTENSET_OVR0_Pos 0 /**< \brief (EVSYS_INTENSET) Channel 0 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR0 (1 << EVSYS_INTENSET_OVR0_Pos) +#define EVSYS_INTENSET_OVR1_Pos 1 /**< \brief (EVSYS_INTENSET) Channel 1 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR1 (1 << EVSYS_INTENSET_OVR1_Pos) +#define EVSYS_INTENSET_OVR2_Pos 2 /**< \brief (EVSYS_INTENSET) Channel 2 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR2 (1 << EVSYS_INTENSET_OVR2_Pos) +#define EVSYS_INTENSET_OVR3_Pos 3 /**< \brief (EVSYS_INTENSET) Channel 3 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR3 (1 << EVSYS_INTENSET_OVR3_Pos) +#define EVSYS_INTENSET_OVR4_Pos 4 /**< \brief (EVSYS_INTENSET) Channel 4 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR4 (1 << EVSYS_INTENSET_OVR4_Pos) +#define EVSYS_INTENSET_OVR5_Pos 5 /**< \brief (EVSYS_INTENSET) Channel 5 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR5 (1 << EVSYS_INTENSET_OVR5_Pos) +#define EVSYS_INTENSET_OVR6_Pos 6 /**< \brief (EVSYS_INTENSET) Channel 6 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR6 (1 << EVSYS_INTENSET_OVR6_Pos) +#define EVSYS_INTENSET_OVR7_Pos 7 /**< \brief (EVSYS_INTENSET) Channel 7 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR7 (1 << EVSYS_INTENSET_OVR7_Pos) +#define EVSYS_INTENSET_OVR_Pos 0 /**< \brief (EVSYS_INTENSET) Channel x Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR_Msk (0xFFu << EVSYS_INTENSET_OVR_Pos) +#define EVSYS_INTENSET_OVR(value) ((EVSYS_INTENSET_OVR_Msk & ((value) << EVSYS_INTENSET_OVR_Pos))) +#define EVSYS_INTENSET_EVD0_Pos 8 /**< \brief (EVSYS_INTENSET) Channel 0 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD0 (1 << EVSYS_INTENSET_EVD0_Pos) +#define EVSYS_INTENSET_EVD1_Pos 9 /**< \brief (EVSYS_INTENSET) Channel 1 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD1 (1 << EVSYS_INTENSET_EVD1_Pos) +#define EVSYS_INTENSET_EVD2_Pos 10 /**< \brief (EVSYS_INTENSET) Channel 2 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD2 (1 << EVSYS_INTENSET_EVD2_Pos) +#define EVSYS_INTENSET_EVD3_Pos 11 /**< \brief (EVSYS_INTENSET) Channel 3 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD3 (1 << EVSYS_INTENSET_EVD3_Pos) +#define EVSYS_INTENSET_EVD4_Pos 12 /**< \brief (EVSYS_INTENSET) Channel 4 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD4 (1 << EVSYS_INTENSET_EVD4_Pos) +#define EVSYS_INTENSET_EVD5_Pos 13 /**< \brief (EVSYS_INTENSET) Channel 5 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD5 (1 << EVSYS_INTENSET_EVD5_Pos) +#define EVSYS_INTENSET_EVD6_Pos 14 /**< \brief (EVSYS_INTENSET) Channel 6 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD6 (1 << EVSYS_INTENSET_EVD6_Pos) +#define EVSYS_INTENSET_EVD7_Pos 15 /**< \brief (EVSYS_INTENSET) Channel 7 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD7 (1 << EVSYS_INTENSET_EVD7_Pos) +#define EVSYS_INTENSET_EVD_Pos 8 /**< \brief (EVSYS_INTENSET) Channel x Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD_Msk (0xFFu << EVSYS_INTENSET_EVD_Pos) +#define EVSYS_INTENSET_EVD(value) ((EVSYS_INTENSET_EVD_Msk & ((value) << EVSYS_INTENSET_EVD_Pos))) +#define EVSYS_INTENSET_OVR8_Pos 16 /**< \brief (EVSYS_INTENSET) Channel 8 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR8 (1 << EVSYS_INTENSET_OVR8_Pos) +#define EVSYS_INTENSET_OVR9_Pos 17 /**< \brief (EVSYS_INTENSET) Channel 9 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR9 (1 << EVSYS_INTENSET_OVR9_Pos) +#define EVSYS_INTENSET_OVR10_Pos 18 /**< \brief (EVSYS_INTENSET) Channel 10 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR10 (1 << EVSYS_INTENSET_OVR10_Pos) +#define EVSYS_INTENSET_OVR11_Pos 19 /**< \brief (EVSYS_INTENSET) Channel 11 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVR11 (1 << EVSYS_INTENSET_OVR11_Pos) +#define EVSYS_INTENSET_OVRp8_Pos 16 /**< \brief (EVSYS_INTENSET) Channel x+8 Overrun Interrupt Enable */ +#define EVSYS_INTENSET_OVRp8_Msk (0xFu << EVSYS_INTENSET_OVRp8_Pos) +#define EVSYS_INTENSET_OVRp8(value) ((EVSYS_INTENSET_OVRp8_Msk & ((value) << EVSYS_INTENSET_OVRp8_Pos))) +#define EVSYS_INTENSET_EVD8_Pos 24 /**< \brief (EVSYS_INTENSET) Channel 8 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD8 (1 << EVSYS_INTENSET_EVD8_Pos) +#define EVSYS_INTENSET_EVD9_Pos 25 /**< \brief (EVSYS_INTENSET) Channel 9 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD9 (1 << EVSYS_INTENSET_EVD9_Pos) +#define EVSYS_INTENSET_EVD10_Pos 26 /**< \brief (EVSYS_INTENSET) Channel 10 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD10 (1 << EVSYS_INTENSET_EVD10_Pos) +#define EVSYS_INTENSET_EVD11_Pos 27 /**< \brief (EVSYS_INTENSET) Channel 11 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVD11 (1 << EVSYS_INTENSET_EVD11_Pos) +#define EVSYS_INTENSET_EVDp8_Pos 24 /**< \brief (EVSYS_INTENSET) Channel x+8 Event Detection Interrupt Enable */ +#define EVSYS_INTENSET_EVDp8_Msk (0xFu << EVSYS_INTENSET_EVDp8_Pos) +#define EVSYS_INTENSET_EVDp8(value) ((EVSYS_INTENSET_EVDp8_Msk & ((value) << EVSYS_INTENSET_EVDp8_Pos))) +#define EVSYS_INTENSET_MASK 0x0F0FFFFFu /**< \brief (EVSYS_INTENSET) MASK Register */ + +/* -------- EVSYS_INTFLAG : (EVSYS Offset: 0x18) (R/W 32) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OVR0:1; /*!< bit: 0 Channel 0 Overrun */ + uint32_t OVR1:1; /*!< bit: 1 Channel 1 Overrun */ + uint32_t OVR2:1; /*!< bit: 2 Channel 2 Overrun */ + uint32_t OVR3:1; /*!< bit: 3 Channel 3 Overrun */ + uint32_t OVR4:1; /*!< bit: 4 Channel 4 Overrun */ + uint32_t OVR5:1; /*!< bit: 5 Channel 5 Overrun */ + uint32_t OVR6:1; /*!< bit: 6 Channel 6 Overrun */ + uint32_t OVR7:1; /*!< bit: 7 Channel 7 Overrun */ + uint32_t EVD0:1; /*!< bit: 8 Channel 0 Event Detection */ + uint32_t EVD1:1; /*!< bit: 9 Channel 1 Event Detection */ + uint32_t EVD2:1; /*!< bit: 10 Channel 2 Event Detection */ + uint32_t EVD3:1; /*!< bit: 11 Channel 3 Event Detection */ + uint32_t EVD4:1; /*!< bit: 12 Channel 4 Event Detection */ + uint32_t EVD5:1; /*!< bit: 13 Channel 5 Event Detection */ + uint32_t EVD6:1; /*!< bit: 14 Channel 6 Event Detection */ + uint32_t EVD7:1; /*!< bit: 15 Channel 7 Event Detection */ + uint32_t OVR8:1; /*!< bit: 16 Channel 8 Overrun */ + uint32_t OVR9:1; /*!< bit: 17 Channel 9 Overrun */ + uint32_t OVR10:1; /*!< bit: 18 Channel 10 Overrun */ + uint32_t OVR11:1; /*!< bit: 19 Channel 11 Overrun */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t EVD8:1; /*!< bit: 24 Channel 8 Event Detection */ + uint32_t EVD9:1; /*!< bit: 25 Channel 9 Event Detection */ + uint32_t EVD10:1; /*!< bit: 26 Channel 10 Event Detection */ + uint32_t EVD11:1; /*!< bit: 27 Channel 11 Event Detection */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t OVR:8; /*!< bit: 0.. 7 Channel x Overrun */ + uint32_t EVD:8; /*!< bit: 8..15 Channel x Event Detection */ + uint32_t OVRp8:4; /*!< bit: 16..19 Channel x+8 Overrun */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t EVDp8:4; /*!< bit: 24..27 Channel x+8 Event Detection */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} EVSYS_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define EVSYS_INTFLAG_OFFSET 0x18 /**< \brief (EVSYS_INTFLAG offset) Interrupt Flag Status and Clear */ +#define EVSYS_INTFLAG_RESETVALUE 0x00000000 /**< \brief (EVSYS_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define EVSYS_INTFLAG_OVR0_Pos 0 /**< \brief (EVSYS_INTFLAG) Channel 0 Overrun */ +#define EVSYS_INTFLAG_OVR0 (1 << EVSYS_INTFLAG_OVR0_Pos) +#define EVSYS_INTFLAG_OVR1_Pos 1 /**< \brief (EVSYS_INTFLAG) Channel 1 Overrun */ +#define EVSYS_INTFLAG_OVR1 (1 << EVSYS_INTFLAG_OVR1_Pos) +#define EVSYS_INTFLAG_OVR2_Pos 2 /**< \brief (EVSYS_INTFLAG) Channel 2 Overrun */ +#define EVSYS_INTFLAG_OVR2 (1 << EVSYS_INTFLAG_OVR2_Pos) +#define EVSYS_INTFLAG_OVR3_Pos 3 /**< \brief (EVSYS_INTFLAG) Channel 3 Overrun */ +#define EVSYS_INTFLAG_OVR3 (1 << EVSYS_INTFLAG_OVR3_Pos) +#define EVSYS_INTFLAG_OVR4_Pos 4 /**< \brief (EVSYS_INTFLAG) Channel 4 Overrun */ +#define EVSYS_INTFLAG_OVR4 (1 << EVSYS_INTFLAG_OVR4_Pos) +#define EVSYS_INTFLAG_OVR5_Pos 5 /**< \brief (EVSYS_INTFLAG) Channel 5 Overrun */ +#define EVSYS_INTFLAG_OVR5 (1 << EVSYS_INTFLAG_OVR5_Pos) +#define EVSYS_INTFLAG_OVR6_Pos 6 /**< \brief (EVSYS_INTFLAG) Channel 6 Overrun */ +#define EVSYS_INTFLAG_OVR6 (1 << EVSYS_INTFLAG_OVR6_Pos) +#define EVSYS_INTFLAG_OVR7_Pos 7 /**< \brief (EVSYS_INTFLAG) Channel 7 Overrun */ +#define EVSYS_INTFLAG_OVR7 (1 << EVSYS_INTFLAG_OVR7_Pos) +#define EVSYS_INTFLAG_OVR_Pos 0 /**< \brief (EVSYS_INTFLAG) Channel x Overrun */ +#define EVSYS_INTFLAG_OVR_Msk (0xFFu << EVSYS_INTFLAG_OVR_Pos) +#define EVSYS_INTFLAG_OVR(value) ((EVSYS_INTFLAG_OVR_Msk & ((value) << EVSYS_INTFLAG_OVR_Pos))) +#define EVSYS_INTFLAG_EVD0_Pos 8 /**< \brief (EVSYS_INTFLAG) Channel 0 Event Detection */ +#define EVSYS_INTFLAG_EVD0 (1 << EVSYS_INTFLAG_EVD0_Pos) +#define EVSYS_INTFLAG_EVD1_Pos 9 /**< \brief (EVSYS_INTFLAG) Channel 1 Event Detection */ +#define EVSYS_INTFLAG_EVD1 (1 << EVSYS_INTFLAG_EVD1_Pos) +#define EVSYS_INTFLAG_EVD2_Pos 10 /**< \brief (EVSYS_INTFLAG) Channel 2 Event Detection */ +#define EVSYS_INTFLAG_EVD2 (1 << EVSYS_INTFLAG_EVD2_Pos) +#define EVSYS_INTFLAG_EVD3_Pos 11 /**< \brief (EVSYS_INTFLAG) Channel 3 Event Detection */ +#define EVSYS_INTFLAG_EVD3 (1 << EVSYS_INTFLAG_EVD3_Pos) +#define EVSYS_INTFLAG_EVD4_Pos 12 /**< \brief (EVSYS_INTFLAG) Channel 4 Event Detection */ +#define EVSYS_INTFLAG_EVD4 (1 << EVSYS_INTFLAG_EVD4_Pos) +#define EVSYS_INTFLAG_EVD5_Pos 13 /**< \brief (EVSYS_INTFLAG) Channel 5 Event Detection */ +#define EVSYS_INTFLAG_EVD5 (1 << EVSYS_INTFLAG_EVD5_Pos) +#define EVSYS_INTFLAG_EVD6_Pos 14 /**< \brief (EVSYS_INTFLAG) Channel 6 Event Detection */ +#define EVSYS_INTFLAG_EVD6 (1 << EVSYS_INTFLAG_EVD6_Pos) +#define EVSYS_INTFLAG_EVD7_Pos 15 /**< \brief (EVSYS_INTFLAG) Channel 7 Event Detection */ +#define EVSYS_INTFLAG_EVD7 (1 << EVSYS_INTFLAG_EVD7_Pos) +#define EVSYS_INTFLAG_EVD_Pos 8 /**< \brief (EVSYS_INTFLAG) Channel x Event Detection */ +#define EVSYS_INTFLAG_EVD_Msk (0xFFu << EVSYS_INTFLAG_EVD_Pos) +#define EVSYS_INTFLAG_EVD(value) ((EVSYS_INTFLAG_EVD_Msk & ((value) << EVSYS_INTFLAG_EVD_Pos))) +#define EVSYS_INTFLAG_OVR8_Pos 16 /**< \brief (EVSYS_INTFLAG) Channel 8 Overrun */ +#define EVSYS_INTFLAG_OVR8 (1 << EVSYS_INTFLAG_OVR8_Pos) +#define EVSYS_INTFLAG_OVR9_Pos 17 /**< \brief (EVSYS_INTFLAG) Channel 9 Overrun */ +#define EVSYS_INTFLAG_OVR9 (1 << EVSYS_INTFLAG_OVR9_Pos) +#define EVSYS_INTFLAG_OVR10_Pos 18 /**< \brief (EVSYS_INTFLAG) Channel 10 Overrun */ +#define EVSYS_INTFLAG_OVR10 (1 << EVSYS_INTFLAG_OVR10_Pos) +#define EVSYS_INTFLAG_OVR11_Pos 19 /**< \brief (EVSYS_INTFLAG) Channel 11 Overrun */ +#define EVSYS_INTFLAG_OVR11 (1 << EVSYS_INTFLAG_OVR11_Pos) +#define EVSYS_INTFLAG_OVRp8_Pos 16 /**< \brief (EVSYS_INTFLAG) Channel x+8 Overrun */ +#define EVSYS_INTFLAG_OVRp8_Msk (0xFu << EVSYS_INTFLAG_OVRp8_Pos) +#define EVSYS_INTFLAG_OVRp8(value) ((EVSYS_INTFLAG_OVRp8_Msk & ((value) << EVSYS_INTFLAG_OVRp8_Pos))) +#define EVSYS_INTFLAG_EVD8_Pos 24 /**< \brief (EVSYS_INTFLAG) Channel 8 Event Detection */ +#define EVSYS_INTFLAG_EVD8 (1 << EVSYS_INTFLAG_EVD8_Pos) +#define EVSYS_INTFLAG_EVD9_Pos 25 /**< \brief (EVSYS_INTFLAG) Channel 9 Event Detection */ +#define EVSYS_INTFLAG_EVD9 (1 << EVSYS_INTFLAG_EVD9_Pos) +#define EVSYS_INTFLAG_EVD10_Pos 26 /**< \brief (EVSYS_INTFLAG) Channel 10 Event Detection */ +#define EVSYS_INTFLAG_EVD10 (1 << EVSYS_INTFLAG_EVD10_Pos) +#define EVSYS_INTFLAG_EVD11_Pos 27 /**< \brief (EVSYS_INTFLAG) Channel 11 Event Detection */ +#define EVSYS_INTFLAG_EVD11 (1 << EVSYS_INTFLAG_EVD11_Pos) +#define EVSYS_INTFLAG_EVDp8_Pos 24 /**< \brief (EVSYS_INTFLAG) Channel x+8 Event Detection */ +#define EVSYS_INTFLAG_EVDp8_Msk (0xFu << EVSYS_INTFLAG_EVDp8_Pos) +#define EVSYS_INTFLAG_EVDp8(value) ((EVSYS_INTFLAG_EVDp8_Msk & ((value) << EVSYS_INTFLAG_EVDp8_Pos))) +#define EVSYS_INTFLAG_MASK 0x0F0FFFFFu /**< \brief (EVSYS_INTFLAG) MASK Register */ + +/** \brief EVSYS hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __O EVSYS_CTRL_Type CTRL; /**< \brief Offset: 0x00 ( /W 8) Control */ + RoReg8 Reserved1[0x3]; + __IO EVSYS_CHANNEL_Type CHANNEL; /**< \brief Offset: 0x04 (R/W 32) Channel */ + __IO EVSYS_USER_Type USER; /**< \brief Offset: 0x08 (R/W 16) User Multiplexer */ + RoReg8 Reserved2[0x2]; + __I EVSYS_CHSTATUS_Type CHSTATUS; /**< \brief Offset: 0x0C (R/ 32) Channel Status */ + __IO EVSYS_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x10 (R/W 32) Interrupt Enable Clear */ + __IO EVSYS_INTENSET_Type INTENSET; /**< \brief Offset: 0x14 (R/W 32) Interrupt Enable Set */ + __IO EVSYS_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x18 (R/W 32) Interrupt Flag Status and Clear */ +} Evsys; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_EVSYS_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/gclk.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/gclk.h new file mode 100755 index 0000000..43b8cb6 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/gclk.h @@ -0,0 +1,234 @@ +/** + * \file + * + * \brief Component description for GCLK + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_GCLK_COMPONENT_ +#define _SAMD21_GCLK_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR GCLK */ +/* ========================================================================== */ +/** \addtogroup SAMD21_GCLK Generic Clock Generator */ +/*@{*/ + +#define GCLK_U2102 +#define REV_GCLK 0x210 + +/* -------- GCLK_CTRL : (GCLK Offset: 0x0) (R/W 8) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} GCLK_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define GCLK_CTRL_OFFSET 0x0 /**< \brief (GCLK_CTRL offset) Control */ +#define GCLK_CTRL_RESETVALUE 0x00 /**< \brief (GCLK_CTRL reset_value) Control */ + +#define GCLK_CTRL_SWRST_Pos 0 /**< \brief (GCLK_CTRL) Software Reset */ +#define GCLK_CTRL_SWRST (0x1u << GCLK_CTRL_SWRST_Pos) +#define GCLK_CTRL_MASK 0x01u /**< \brief (GCLK_CTRL) MASK Register */ + +/* -------- GCLK_STATUS : (GCLK Offset: 0x1) (R/ 8) Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :7; /*!< bit: 0.. 6 Reserved */ + uint8_t SYNCBUSY:1; /*!< bit: 7 Synchronization Busy Status */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} GCLK_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define GCLK_STATUS_OFFSET 0x1 /**< \brief (GCLK_STATUS offset) Status */ +#define GCLK_STATUS_RESETVALUE 0x00 /**< \brief (GCLK_STATUS reset_value) Status */ + +#define GCLK_STATUS_SYNCBUSY_Pos 7 /**< \brief (GCLK_STATUS) Synchronization Busy Status */ +#define GCLK_STATUS_SYNCBUSY (0x1u << GCLK_STATUS_SYNCBUSY_Pos) +#define GCLK_STATUS_MASK 0x80u /**< \brief (GCLK_STATUS) MASK Register */ + +/* -------- GCLK_CLKCTRL : (GCLK Offset: 0x2) (R/W 16) Generic Clock Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t ID:6; /*!< bit: 0.. 5 Generic Clock Selection ID */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t GEN:4; /*!< bit: 8..11 Generic Clock Generator */ + uint16_t :2; /*!< bit: 12..13 Reserved */ + uint16_t CLKEN:1; /*!< bit: 14 Clock Enable */ + uint16_t WRTLOCK:1; /*!< bit: 15 Write Lock */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} GCLK_CLKCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define GCLK_CLKCTRL_OFFSET 0x2 /**< \brief (GCLK_CLKCTRL offset) Generic Clock Control */ +#define GCLK_CLKCTRL_RESETVALUE 0x0000 /**< \brief (GCLK_CLKCTRL reset_value) Generic Clock Control */ + +#define GCLK_CLKCTRL_ID_Pos 0 /**< \brief (GCLK_CLKCTRL) Generic Clock Selection ID */ +#define GCLK_CLKCTRL_ID_Msk (0x3Fu << GCLK_CLKCTRL_ID_Pos) +#define GCLK_CLKCTRL_ID(value) ((GCLK_CLKCTRL_ID_Msk & ((value) << GCLK_CLKCTRL_ID_Pos))) +#define GCLK_CLKCTRL_GEN_Pos 8 /**< \brief (GCLK_CLKCTRL) Generic Clock Generator */ +#define GCLK_CLKCTRL_GEN_Msk (0xFu << GCLK_CLKCTRL_GEN_Pos) +#define GCLK_CLKCTRL_GEN(value) ((GCLK_CLKCTRL_GEN_Msk & ((value) << GCLK_CLKCTRL_GEN_Pos))) +#define GCLK_CLKCTRL_GEN_GCLK0_Val 0x0u /**< \brief (GCLK_CLKCTRL) Generic clock generator 0 */ +#define GCLK_CLKCTRL_GEN_GCLK1_Val 0x1u /**< \brief (GCLK_CLKCTRL) Generic clock generator 1 */ +#define GCLK_CLKCTRL_GEN_GCLK2_Val 0x2u /**< \brief (GCLK_CLKCTRL) Generic clock generator 2 */ +#define GCLK_CLKCTRL_GEN_GCLK3_Val 0x3u /**< \brief (GCLK_CLKCTRL) Generic clock generator 3 */ +#define GCLK_CLKCTRL_GEN_GCLK4_Val 0x4u /**< \brief (GCLK_CLKCTRL) Generic clock generator 4 */ +#define GCLK_CLKCTRL_GEN_GCLK5_Val 0x5u /**< \brief (GCLK_CLKCTRL) Generic clock generator 5 */ +#define GCLK_CLKCTRL_GEN_GCLK6_Val 0x6u /**< \brief (GCLK_CLKCTRL) Generic clock generator 6 */ +#define GCLK_CLKCTRL_GEN_GCLK7_Val 0x7u /**< \brief (GCLK_CLKCTRL) Generic clock generator 7 */ +#define GCLK_CLKCTRL_GEN_GCLK0 (GCLK_CLKCTRL_GEN_GCLK0_Val << GCLK_CLKCTRL_GEN_Pos) +#define GCLK_CLKCTRL_GEN_GCLK1 (GCLK_CLKCTRL_GEN_GCLK1_Val << GCLK_CLKCTRL_GEN_Pos) +#define GCLK_CLKCTRL_GEN_GCLK2 (GCLK_CLKCTRL_GEN_GCLK2_Val << GCLK_CLKCTRL_GEN_Pos) +#define GCLK_CLKCTRL_GEN_GCLK3 (GCLK_CLKCTRL_GEN_GCLK3_Val << GCLK_CLKCTRL_GEN_Pos) +#define GCLK_CLKCTRL_GEN_GCLK4 (GCLK_CLKCTRL_GEN_GCLK4_Val << GCLK_CLKCTRL_GEN_Pos) +#define GCLK_CLKCTRL_GEN_GCLK5 (GCLK_CLKCTRL_GEN_GCLK5_Val << GCLK_CLKCTRL_GEN_Pos) +#define GCLK_CLKCTRL_GEN_GCLK6 (GCLK_CLKCTRL_GEN_GCLK6_Val << GCLK_CLKCTRL_GEN_Pos) +#define GCLK_CLKCTRL_GEN_GCLK7 (GCLK_CLKCTRL_GEN_GCLK7_Val << GCLK_CLKCTRL_GEN_Pos) +#define GCLK_CLKCTRL_CLKEN_Pos 14 /**< \brief (GCLK_CLKCTRL) Clock Enable */ +#define GCLK_CLKCTRL_CLKEN (0x1u << GCLK_CLKCTRL_CLKEN_Pos) +#define GCLK_CLKCTRL_WRTLOCK_Pos 15 /**< \brief (GCLK_CLKCTRL) Write Lock */ +#define GCLK_CLKCTRL_WRTLOCK (0x1u << GCLK_CLKCTRL_WRTLOCK_Pos) +#define GCLK_CLKCTRL_MASK 0xCF3Fu /**< \brief (GCLK_CLKCTRL) MASK Register */ + +/* -------- GCLK_GENCTRL : (GCLK Offset: 0x4) (R/W 32) Generic Clock Generator Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t ID:4; /*!< bit: 0.. 3 Generic Clock Generator Selection */ + uint32_t :4; /*!< bit: 4.. 7 Reserved */ + uint32_t SRC:5; /*!< bit: 8..12 Source Select */ + uint32_t :3; /*!< bit: 13..15 Reserved */ + uint32_t GENEN:1; /*!< bit: 16 Generic Clock Generator Enable */ + uint32_t IDC:1; /*!< bit: 17 Improve Duty Cycle */ + uint32_t OOV:1; /*!< bit: 18 Output Off Value */ + uint32_t OE:1; /*!< bit: 19 Output Enable */ + uint32_t DIVSEL:1; /*!< bit: 20 Divide Selection */ + uint32_t RUNSTDBY:1; /*!< bit: 21 Run in Standby */ + uint32_t :10; /*!< bit: 22..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} GCLK_GENCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define GCLK_GENCTRL_OFFSET 0x4 /**< \brief (GCLK_GENCTRL offset) Generic Clock Generator Control */ +#define GCLK_GENCTRL_RESETVALUE 0x00000000 /**< \brief (GCLK_GENCTRL reset_value) Generic Clock Generator Control */ + +#define GCLK_GENCTRL_ID_Pos 0 /**< \brief (GCLK_GENCTRL) Generic Clock Generator Selection */ +#define GCLK_GENCTRL_ID_Msk (0xFu << GCLK_GENCTRL_ID_Pos) +#define GCLK_GENCTRL_ID(value) ((GCLK_GENCTRL_ID_Msk & ((value) << GCLK_GENCTRL_ID_Pos))) +#define GCLK_GENCTRL_SRC_Pos 8 /**< \brief (GCLK_GENCTRL) Source Select */ +#define GCLK_GENCTRL_SRC_Msk (0x1Fu << GCLK_GENCTRL_SRC_Pos) +#define GCLK_GENCTRL_SRC(value) ((GCLK_GENCTRL_SRC_Msk & ((value) << GCLK_GENCTRL_SRC_Pos))) +#define GCLK_GENCTRL_SRC_XOSC_Val 0x0u /**< \brief (GCLK_GENCTRL) XOSC oscillator output */ +#define GCLK_GENCTRL_SRC_GCLKIN_Val 0x1u /**< \brief (GCLK_GENCTRL) Generator input pad */ +#define GCLK_GENCTRL_SRC_GCLKGEN1_Val 0x2u /**< \brief (GCLK_GENCTRL) Generic clock generator 1 output */ +#define GCLK_GENCTRL_SRC_OSCULP32K_Val 0x3u /**< \brief (GCLK_GENCTRL) OSCULP32K oscillator output */ +#define GCLK_GENCTRL_SRC_OSC32K_Val 0x4u /**< \brief (GCLK_GENCTRL) OSC32K oscillator output */ +#define GCLK_GENCTRL_SRC_XOSC32K_Val 0x5u /**< \brief (GCLK_GENCTRL) XOSC32K oscillator output */ +#define GCLK_GENCTRL_SRC_OSC8M_Val 0x6u /**< \brief (GCLK_GENCTRL) OSC8M oscillator output */ +#define GCLK_GENCTRL_SRC_DFLL48M_Val 0x7u /**< \brief (GCLK_GENCTRL) DFLL48M output */ +#define GCLK_GENCTRL_SRC_XOSC (GCLK_GENCTRL_SRC_XOSC_Val << GCLK_GENCTRL_SRC_Pos) +#define GCLK_GENCTRL_SRC_GCLKIN (GCLK_GENCTRL_SRC_GCLKIN_Val << GCLK_GENCTRL_SRC_Pos) +#define GCLK_GENCTRL_SRC_GCLKGEN1 (GCLK_GENCTRL_SRC_GCLKGEN1_Val << GCLK_GENCTRL_SRC_Pos) +#define GCLK_GENCTRL_SRC_OSCULP32K (GCLK_GENCTRL_SRC_OSCULP32K_Val << GCLK_GENCTRL_SRC_Pos) +#define GCLK_GENCTRL_SRC_OSC32K (GCLK_GENCTRL_SRC_OSC32K_Val << GCLK_GENCTRL_SRC_Pos) +#define GCLK_GENCTRL_SRC_XOSC32K (GCLK_GENCTRL_SRC_XOSC32K_Val << GCLK_GENCTRL_SRC_Pos) +#define GCLK_GENCTRL_SRC_OSC8M (GCLK_GENCTRL_SRC_OSC8M_Val << GCLK_GENCTRL_SRC_Pos) +#define GCLK_GENCTRL_SRC_DFLL48M (GCLK_GENCTRL_SRC_DFLL48M_Val << GCLK_GENCTRL_SRC_Pos) +#define GCLK_GENCTRL_GENEN_Pos 16 /**< \brief (GCLK_GENCTRL) Generic Clock Generator Enable */ +#define GCLK_GENCTRL_GENEN (0x1u << GCLK_GENCTRL_GENEN_Pos) +#define GCLK_GENCTRL_IDC_Pos 17 /**< \brief (GCLK_GENCTRL) Improve Duty Cycle */ +#define GCLK_GENCTRL_IDC (0x1u << GCLK_GENCTRL_IDC_Pos) +#define GCLK_GENCTRL_OOV_Pos 18 /**< \brief (GCLK_GENCTRL) Output Off Value */ +#define GCLK_GENCTRL_OOV (0x1u << GCLK_GENCTRL_OOV_Pos) +#define GCLK_GENCTRL_OE_Pos 19 /**< \brief (GCLK_GENCTRL) Output Enable */ +#define GCLK_GENCTRL_OE (0x1u << GCLK_GENCTRL_OE_Pos) +#define GCLK_GENCTRL_DIVSEL_Pos 20 /**< \brief (GCLK_GENCTRL) Divide Selection */ +#define GCLK_GENCTRL_DIVSEL (0x1u << GCLK_GENCTRL_DIVSEL_Pos) +#define GCLK_GENCTRL_RUNSTDBY_Pos 21 /**< \brief (GCLK_GENCTRL) Run in Standby */ +#define GCLK_GENCTRL_RUNSTDBY (0x1u << GCLK_GENCTRL_RUNSTDBY_Pos) +#define GCLK_GENCTRL_MASK 0x003F1F0Fu /**< \brief (GCLK_GENCTRL) MASK Register */ + +/* -------- GCLK_GENDIV : (GCLK Offset: 0x8) (R/W 32) Generic Clock Generator Division -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t ID:4; /*!< bit: 0.. 3 Generic Clock Generator Selection */ + uint32_t :4; /*!< bit: 4.. 7 Reserved */ + uint32_t DIV:16; /*!< bit: 8..23 Division Factor */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} GCLK_GENDIV_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define GCLK_GENDIV_OFFSET 0x8 /**< \brief (GCLK_GENDIV offset) Generic Clock Generator Division */ +#define GCLK_GENDIV_RESETVALUE 0x00000000 /**< \brief (GCLK_GENDIV reset_value) Generic Clock Generator Division */ + +#define GCLK_GENDIV_ID_Pos 0 /**< \brief (GCLK_GENDIV) Generic Clock Generator Selection */ +#define GCLK_GENDIV_ID_Msk (0xFu << GCLK_GENDIV_ID_Pos) +#define GCLK_GENDIV_ID(value) ((GCLK_GENDIV_ID_Msk & ((value) << GCLK_GENDIV_ID_Pos))) +#define GCLK_GENDIV_DIV_Pos 8 /**< \brief (GCLK_GENDIV) Division Factor */ +#define GCLK_GENDIV_DIV_Msk (0xFFFFu << GCLK_GENDIV_DIV_Pos) +#define GCLK_GENDIV_DIV(value) ((GCLK_GENDIV_DIV_Msk & ((value) << GCLK_GENDIV_DIV_Pos))) +#define GCLK_GENDIV_MASK 0x00FFFF0Fu /**< \brief (GCLK_GENDIV) MASK Register */ + +/** \brief GCLK hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO GCLK_CTRL_Type CTRL; /**< \brief Offset: 0x0 (R/W 8) Control */ + __I GCLK_STATUS_Type STATUS; /**< \brief Offset: 0x1 (R/ 8) Status */ + __IO GCLK_CLKCTRL_Type CLKCTRL; /**< \brief Offset: 0x2 (R/W 16) Generic Clock Control */ + __IO GCLK_GENCTRL_Type GENCTRL; /**< \brief Offset: 0x4 (R/W 32) Generic Clock Generator Control */ + __IO GCLK_GENDIV_Type GENDIV; /**< \brief Offset: 0x8 (R/W 32) Generic Clock Generator Division */ +} Gclk; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_GCLK_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/i2s.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/i2s.h new file mode 100755 index 0000000..4eebf78 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/i2s.h @@ -0,0 +1,639 @@ +/** + * \file + * + * \brief Component description for I2S + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_I2S_COMPONENT_ +#define _SAMD21_I2S_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR I2S */ +/* ========================================================================== */ +/** \addtogroup SAMD21_I2S Inter-IC Sound Interface */ +/*@{*/ + +#define I2S_U2224 +#define REV_I2S 0x101 + +/* -------- I2S_CTRLA : (I2S Offset: 0x00) (R/W 8) Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset */ + uint8_t ENABLE:1; /*!< bit: 1 Enable */ + uint8_t CKEN0:1; /*!< bit: 2 Clock Unit 0 Enable */ + uint8_t CKEN1:1; /*!< bit: 3 Clock Unit 1 Enable */ + uint8_t SEREN0:1; /*!< bit: 4 Serializer 0 Enable */ + uint8_t SEREN1:1; /*!< bit: 5 Serializer 1 Enable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t :2; /*!< bit: 0.. 1 Reserved */ + uint8_t CKEN:2; /*!< bit: 2.. 3 Clock Unit x Enable */ + uint8_t SEREN:2; /*!< bit: 4.. 5 Serializer x Enable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} I2S_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define I2S_CTRLA_OFFSET 0x00 /**< \brief (I2S_CTRLA offset) Control A */ +#define I2S_CTRLA_RESETVALUE 0x00 /**< \brief (I2S_CTRLA reset_value) Control A */ + +#define I2S_CTRLA_SWRST_Pos 0 /**< \brief (I2S_CTRLA) Software Reset */ +#define I2S_CTRLA_SWRST (0x1u << I2S_CTRLA_SWRST_Pos) +#define I2S_CTRLA_ENABLE_Pos 1 /**< \brief (I2S_CTRLA) Enable */ +#define I2S_CTRLA_ENABLE (0x1u << I2S_CTRLA_ENABLE_Pos) +#define I2S_CTRLA_CKEN0_Pos 2 /**< \brief (I2S_CTRLA) Clock Unit 0 Enable */ +#define I2S_CTRLA_CKEN0 (1 << I2S_CTRLA_CKEN0_Pos) +#define I2S_CTRLA_CKEN1_Pos 3 /**< \brief (I2S_CTRLA) Clock Unit 1 Enable */ +#define I2S_CTRLA_CKEN1 (1 << I2S_CTRLA_CKEN1_Pos) +#define I2S_CTRLA_CKEN_Pos 2 /**< \brief (I2S_CTRLA) Clock Unit x Enable */ +#define I2S_CTRLA_CKEN_Msk (0x3u << I2S_CTRLA_CKEN_Pos) +#define I2S_CTRLA_CKEN(value) ((I2S_CTRLA_CKEN_Msk & ((value) << I2S_CTRLA_CKEN_Pos))) +#define I2S_CTRLA_SEREN0_Pos 4 /**< \brief (I2S_CTRLA) Serializer 0 Enable */ +#define I2S_CTRLA_SEREN0 (1 << I2S_CTRLA_SEREN0_Pos) +#define I2S_CTRLA_SEREN1_Pos 5 /**< \brief (I2S_CTRLA) Serializer 1 Enable */ +#define I2S_CTRLA_SEREN1 (1 << I2S_CTRLA_SEREN1_Pos) +#define I2S_CTRLA_SEREN_Pos 4 /**< \brief (I2S_CTRLA) Serializer x Enable */ +#define I2S_CTRLA_SEREN_Msk (0x3u << I2S_CTRLA_SEREN_Pos) +#define I2S_CTRLA_SEREN(value) ((I2S_CTRLA_SEREN_Msk & ((value) << I2S_CTRLA_SEREN_Pos))) +#define I2S_CTRLA_MASK 0x3Fu /**< \brief (I2S_CTRLA) MASK Register */ + +/* -------- I2S_CLKCTRL : (I2S Offset: 0x04) (R/W 32) Clock Unit n Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SLOTSIZE:2; /*!< bit: 0.. 1 Slot Size */ + uint32_t NBSLOTS:3; /*!< bit: 2.. 4 Number of Slots in Frame */ + uint32_t FSWIDTH:2; /*!< bit: 5.. 6 Frame Sync Width */ + uint32_t BITDELAY:1; /*!< bit: 7 Data Delay from Frame Sync */ + uint32_t FSSEL:1; /*!< bit: 8 Frame Sync Select */ + uint32_t :2; /*!< bit: 9..10 Reserved */ + uint32_t FSINV:1; /*!< bit: 11 Frame Sync Invert */ + uint32_t SCKSEL:1; /*!< bit: 12 Serial Clock Select */ + uint32_t :3; /*!< bit: 13..15 Reserved */ + uint32_t MCKSEL:1; /*!< bit: 16 Master Clock Select */ + uint32_t :1; /*!< bit: 17 Reserved */ + uint32_t MCKEN:1; /*!< bit: 18 Master Clock Enable */ + uint32_t MCKDIV:5; /*!< bit: 19..23 Master Clock Division Factor */ + uint32_t MCKOUTDIV:5; /*!< bit: 24..28 Master Clock Output Division Factor */ + uint32_t FSOUTINV:1; /*!< bit: 29 Frame Sync Output Invert */ + uint32_t SCKOUTINV:1; /*!< bit: 30 Serial Clock Output Invert */ + uint32_t MCKOUTINV:1; /*!< bit: 31 Master Clock Output Invert */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} I2S_CLKCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define I2S_CLKCTRL_OFFSET 0x04 /**< \brief (I2S_CLKCTRL offset) Clock Unit n Control */ +#define I2S_CLKCTRL_RESETVALUE 0x00000000 /**< \brief (I2S_CLKCTRL reset_value) Clock Unit n Control */ + +#define I2S_CLKCTRL_SLOTSIZE_Pos 0 /**< \brief (I2S_CLKCTRL) Slot Size */ +#define I2S_CLKCTRL_SLOTSIZE_Msk (0x3u << I2S_CLKCTRL_SLOTSIZE_Pos) +#define I2S_CLKCTRL_SLOTSIZE(value) ((I2S_CLKCTRL_SLOTSIZE_Msk & ((value) << I2S_CLKCTRL_SLOTSIZE_Pos))) +#define I2S_CLKCTRL_SLOTSIZE_8_Val 0x0u /**< \brief (I2S_CLKCTRL) 8-bit Slot for Clock Unit n */ +#define I2S_CLKCTRL_SLOTSIZE_16_Val 0x1u /**< \brief (I2S_CLKCTRL) 16-bit Slot for Clock Unit n */ +#define I2S_CLKCTRL_SLOTSIZE_24_Val 0x2u /**< \brief (I2S_CLKCTRL) 24-bit Slot for Clock Unit n */ +#define I2S_CLKCTRL_SLOTSIZE_32_Val 0x3u /**< \brief (I2S_CLKCTRL) 32-bit Slot for Clock Unit n */ +#define I2S_CLKCTRL_SLOTSIZE_8 (I2S_CLKCTRL_SLOTSIZE_8_Val << I2S_CLKCTRL_SLOTSIZE_Pos) +#define I2S_CLKCTRL_SLOTSIZE_16 (I2S_CLKCTRL_SLOTSIZE_16_Val << I2S_CLKCTRL_SLOTSIZE_Pos) +#define I2S_CLKCTRL_SLOTSIZE_24 (I2S_CLKCTRL_SLOTSIZE_24_Val << I2S_CLKCTRL_SLOTSIZE_Pos) +#define I2S_CLKCTRL_SLOTSIZE_32 (I2S_CLKCTRL_SLOTSIZE_32_Val << I2S_CLKCTRL_SLOTSIZE_Pos) +#define I2S_CLKCTRL_NBSLOTS_Pos 2 /**< \brief (I2S_CLKCTRL) Number of Slots in Frame */ +#define I2S_CLKCTRL_NBSLOTS_Msk (0x7u << I2S_CLKCTRL_NBSLOTS_Pos) +#define I2S_CLKCTRL_NBSLOTS(value) ((I2S_CLKCTRL_NBSLOTS_Msk & ((value) << I2S_CLKCTRL_NBSLOTS_Pos))) +#define I2S_CLKCTRL_FSWIDTH_Pos 5 /**< \brief (I2S_CLKCTRL) Frame Sync Width */ +#define I2S_CLKCTRL_FSWIDTH_Msk (0x3u << I2S_CLKCTRL_FSWIDTH_Pos) +#define I2S_CLKCTRL_FSWIDTH(value) ((I2S_CLKCTRL_FSWIDTH_Msk & ((value) << I2S_CLKCTRL_FSWIDTH_Pos))) +#define I2S_CLKCTRL_FSWIDTH_SLOT_Val 0x0u /**< \brief (I2S_CLKCTRL) Frame Sync Pulse is 1 Slot wide (default for I2S protocol) */ +#define I2S_CLKCTRL_FSWIDTH_HALF_Val 0x1u /**< \brief (I2S_CLKCTRL) Frame Sync Pulse is half a Frame wide */ +#define I2S_CLKCTRL_FSWIDTH_BIT_Val 0x2u /**< \brief (I2S_CLKCTRL) Frame Sync Pulse is 1 Bit wide */ +#define I2S_CLKCTRL_FSWIDTH_BURST_Val 0x3u /**< \brief (I2S_CLKCTRL) Clock Unit n operates in Burst mode, with a 1-bit wide Frame Sync pulse per Data sample, only when Data transfer is requested */ +#define I2S_CLKCTRL_FSWIDTH_SLOT (I2S_CLKCTRL_FSWIDTH_SLOT_Val << I2S_CLKCTRL_FSWIDTH_Pos) +#define I2S_CLKCTRL_FSWIDTH_HALF (I2S_CLKCTRL_FSWIDTH_HALF_Val << I2S_CLKCTRL_FSWIDTH_Pos) +#define I2S_CLKCTRL_FSWIDTH_BIT (I2S_CLKCTRL_FSWIDTH_BIT_Val << I2S_CLKCTRL_FSWIDTH_Pos) +#define I2S_CLKCTRL_FSWIDTH_BURST (I2S_CLKCTRL_FSWIDTH_BURST_Val << I2S_CLKCTRL_FSWIDTH_Pos) +#define I2S_CLKCTRL_BITDELAY_Pos 7 /**< \brief (I2S_CLKCTRL) Data Delay from Frame Sync */ +#define I2S_CLKCTRL_BITDELAY (0x1u << I2S_CLKCTRL_BITDELAY_Pos) +#define I2S_CLKCTRL_BITDELAY_LJ_Val 0x0u /**< \brief (I2S_CLKCTRL) Left Justified (0 Bit Delay) */ +#define I2S_CLKCTRL_BITDELAY_I2S_Val 0x1u /**< \brief (I2S_CLKCTRL) I2S (1 Bit Delay) */ +#define I2S_CLKCTRL_BITDELAY_LJ (I2S_CLKCTRL_BITDELAY_LJ_Val << I2S_CLKCTRL_BITDELAY_Pos) +#define I2S_CLKCTRL_BITDELAY_I2S (I2S_CLKCTRL_BITDELAY_I2S_Val << I2S_CLKCTRL_BITDELAY_Pos) +#define I2S_CLKCTRL_FSSEL_Pos 8 /**< \brief (I2S_CLKCTRL) Frame Sync Select */ +#define I2S_CLKCTRL_FSSEL (0x1u << I2S_CLKCTRL_FSSEL_Pos) +#define I2S_CLKCTRL_FSSEL_SCKDIV_Val 0x0u /**< \brief (I2S_CLKCTRL) Divided Serial Clock n is used as Frame Sync n source */ +#define I2S_CLKCTRL_FSSEL_FSPIN_Val 0x1u /**< \brief (I2S_CLKCTRL) FSn input pin is used as Frame Sync n source */ +#define I2S_CLKCTRL_FSSEL_SCKDIV (I2S_CLKCTRL_FSSEL_SCKDIV_Val << I2S_CLKCTRL_FSSEL_Pos) +#define I2S_CLKCTRL_FSSEL_FSPIN (I2S_CLKCTRL_FSSEL_FSPIN_Val << I2S_CLKCTRL_FSSEL_Pos) +#define I2S_CLKCTRL_FSINV_Pos 11 /**< \brief (I2S_CLKCTRL) Frame Sync Invert */ +#define I2S_CLKCTRL_FSINV (0x1u << I2S_CLKCTRL_FSINV_Pos) +#define I2S_CLKCTRL_SCKSEL_Pos 12 /**< \brief (I2S_CLKCTRL) Serial Clock Select */ +#define I2S_CLKCTRL_SCKSEL (0x1u << I2S_CLKCTRL_SCKSEL_Pos) +#define I2S_CLKCTRL_SCKSEL_MCKDIV_Val 0x0u /**< \brief (I2S_CLKCTRL) Divided Master Clock n is used as Serial Clock n source */ +#define I2S_CLKCTRL_SCKSEL_SCKPIN_Val 0x1u /**< \brief (I2S_CLKCTRL) SCKn input pin is used as Serial Clock n source */ +#define I2S_CLKCTRL_SCKSEL_MCKDIV (I2S_CLKCTRL_SCKSEL_MCKDIV_Val << I2S_CLKCTRL_SCKSEL_Pos) +#define I2S_CLKCTRL_SCKSEL_SCKPIN (I2S_CLKCTRL_SCKSEL_SCKPIN_Val << I2S_CLKCTRL_SCKSEL_Pos) +#define I2S_CLKCTRL_MCKSEL_Pos 16 /**< \brief (I2S_CLKCTRL) Master Clock Select */ +#define I2S_CLKCTRL_MCKSEL (0x1u << I2S_CLKCTRL_MCKSEL_Pos) +#define I2S_CLKCTRL_MCKSEL_GCLK_Val 0x0u /**< \brief (I2S_CLKCTRL) GCLK_I2S_n is used as Master Clock n source */ +#define I2S_CLKCTRL_MCKSEL_MCKPIN_Val 0x1u /**< \brief (I2S_CLKCTRL) MCKn input pin is used as Master Clock n source */ +#define I2S_CLKCTRL_MCKSEL_GCLK (I2S_CLKCTRL_MCKSEL_GCLK_Val << I2S_CLKCTRL_MCKSEL_Pos) +#define I2S_CLKCTRL_MCKSEL_MCKPIN (I2S_CLKCTRL_MCKSEL_MCKPIN_Val << I2S_CLKCTRL_MCKSEL_Pos) +#define I2S_CLKCTRL_MCKEN_Pos 18 /**< \brief (I2S_CLKCTRL) Master Clock Enable */ +#define I2S_CLKCTRL_MCKEN (0x1u << I2S_CLKCTRL_MCKEN_Pos) +#define I2S_CLKCTRL_MCKDIV_Pos 19 /**< \brief (I2S_CLKCTRL) Master Clock Division Factor */ +#define I2S_CLKCTRL_MCKDIV_Msk (0x1Fu << I2S_CLKCTRL_MCKDIV_Pos) +#define I2S_CLKCTRL_MCKDIV(value) ((I2S_CLKCTRL_MCKDIV_Msk & ((value) << I2S_CLKCTRL_MCKDIV_Pos))) +#define I2S_CLKCTRL_MCKOUTDIV_Pos 24 /**< \brief (I2S_CLKCTRL) Master Clock Output Division Factor */ +#define I2S_CLKCTRL_MCKOUTDIV_Msk (0x1Fu << I2S_CLKCTRL_MCKOUTDIV_Pos) +#define I2S_CLKCTRL_MCKOUTDIV(value) ((I2S_CLKCTRL_MCKOUTDIV_Msk & ((value) << I2S_CLKCTRL_MCKOUTDIV_Pos))) +#define I2S_CLKCTRL_FSOUTINV_Pos 29 /**< \brief (I2S_CLKCTRL) Frame Sync Output Invert */ +#define I2S_CLKCTRL_FSOUTINV (0x1u << I2S_CLKCTRL_FSOUTINV_Pos) +#define I2S_CLKCTRL_SCKOUTINV_Pos 30 /**< \brief (I2S_CLKCTRL) Serial Clock Output Invert */ +#define I2S_CLKCTRL_SCKOUTINV (0x1u << I2S_CLKCTRL_SCKOUTINV_Pos) +#define I2S_CLKCTRL_MCKOUTINV_Pos 31 /**< \brief (I2S_CLKCTRL) Master Clock Output Invert */ +#define I2S_CLKCTRL_MCKOUTINV (0x1u << I2S_CLKCTRL_MCKOUTINV_Pos) +#define I2S_CLKCTRL_MASK 0xFFFD19FFu /**< \brief (I2S_CLKCTRL) MASK Register */ + +/* -------- I2S_INTENCLR : (I2S Offset: 0x0C) (R/W 16) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t RXRDY0:1; /*!< bit: 0 Receive Ready 0 Interrupt Enable */ + uint16_t RXRDY1:1; /*!< bit: 1 Receive Ready 1 Interrupt Enable */ + uint16_t :2; /*!< bit: 2.. 3 Reserved */ + uint16_t RXOR0:1; /*!< bit: 4 Receive Overrun 0 Interrupt Enable */ + uint16_t RXOR1:1; /*!< bit: 5 Receive Overrun 1 Interrupt Enable */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t TXRDY0:1; /*!< bit: 8 Transmit Ready 0 Interrupt Enable */ + uint16_t TXRDY1:1; /*!< bit: 9 Transmit Ready 1 Interrupt Enable */ + uint16_t :2; /*!< bit: 10..11 Reserved */ + uint16_t TXUR0:1; /*!< bit: 12 Transmit Underrun 0 Interrupt Enable */ + uint16_t TXUR1:1; /*!< bit: 13 Transmit Underrun 1 Interrupt Enable */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t RXRDY:2; /*!< bit: 0.. 1 Receive Ready x Interrupt Enable */ + uint16_t :2; /*!< bit: 2.. 3 Reserved */ + uint16_t RXOR:2; /*!< bit: 4.. 5 Receive Overrun x Interrupt Enable */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t TXRDY:2; /*!< bit: 8.. 9 Transmit Ready x Interrupt Enable */ + uint16_t :2; /*!< bit: 10..11 Reserved */ + uint16_t TXUR:2; /*!< bit: 12..13 Transmit Underrun x Interrupt Enable */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} I2S_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define I2S_INTENCLR_OFFSET 0x0C /**< \brief (I2S_INTENCLR offset) Interrupt Enable Clear */ +#define I2S_INTENCLR_RESETVALUE 0x0000 /**< \brief (I2S_INTENCLR reset_value) Interrupt Enable Clear */ + +#define I2S_INTENCLR_RXRDY0_Pos 0 /**< \brief (I2S_INTENCLR) Receive Ready 0 Interrupt Enable */ +#define I2S_INTENCLR_RXRDY0 (1 << I2S_INTENCLR_RXRDY0_Pos) +#define I2S_INTENCLR_RXRDY1_Pos 1 /**< \brief (I2S_INTENCLR) Receive Ready 1 Interrupt Enable */ +#define I2S_INTENCLR_RXRDY1 (1 << I2S_INTENCLR_RXRDY1_Pos) +#define I2S_INTENCLR_RXRDY_Pos 0 /**< \brief (I2S_INTENCLR) Receive Ready x Interrupt Enable */ +#define I2S_INTENCLR_RXRDY_Msk (0x3u << I2S_INTENCLR_RXRDY_Pos) +#define I2S_INTENCLR_RXRDY(value) ((I2S_INTENCLR_RXRDY_Msk & ((value) << I2S_INTENCLR_RXRDY_Pos))) +#define I2S_INTENCLR_RXOR0_Pos 4 /**< \brief (I2S_INTENCLR) Receive Overrun 0 Interrupt Enable */ +#define I2S_INTENCLR_RXOR0 (1 << I2S_INTENCLR_RXOR0_Pos) +#define I2S_INTENCLR_RXOR1_Pos 5 /**< \brief (I2S_INTENCLR) Receive Overrun 1 Interrupt Enable */ +#define I2S_INTENCLR_RXOR1 (1 << I2S_INTENCLR_RXOR1_Pos) +#define I2S_INTENCLR_RXOR_Pos 4 /**< \brief (I2S_INTENCLR) Receive Overrun x Interrupt Enable */ +#define I2S_INTENCLR_RXOR_Msk (0x3u << I2S_INTENCLR_RXOR_Pos) +#define I2S_INTENCLR_RXOR(value) ((I2S_INTENCLR_RXOR_Msk & ((value) << I2S_INTENCLR_RXOR_Pos))) +#define I2S_INTENCLR_TXRDY0_Pos 8 /**< \brief (I2S_INTENCLR) Transmit Ready 0 Interrupt Enable */ +#define I2S_INTENCLR_TXRDY0 (1 << I2S_INTENCLR_TXRDY0_Pos) +#define I2S_INTENCLR_TXRDY1_Pos 9 /**< \brief (I2S_INTENCLR) Transmit Ready 1 Interrupt Enable */ +#define I2S_INTENCLR_TXRDY1 (1 << I2S_INTENCLR_TXRDY1_Pos) +#define I2S_INTENCLR_TXRDY_Pos 8 /**< \brief (I2S_INTENCLR) Transmit Ready x Interrupt Enable */ +#define I2S_INTENCLR_TXRDY_Msk (0x3u << I2S_INTENCLR_TXRDY_Pos) +#define I2S_INTENCLR_TXRDY(value) ((I2S_INTENCLR_TXRDY_Msk & ((value) << I2S_INTENCLR_TXRDY_Pos))) +#define I2S_INTENCLR_TXUR0_Pos 12 /**< \brief (I2S_INTENCLR) Transmit Underrun 0 Interrupt Enable */ +#define I2S_INTENCLR_TXUR0 (1 << I2S_INTENCLR_TXUR0_Pos) +#define I2S_INTENCLR_TXUR1_Pos 13 /**< \brief (I2S_INTENCLR) Transmit Underrun 1 Interrupt Enable */ +#define I2S_INTENCLR_TXUR1 (1 << I2S_INTENCLR_TXUR1_Pos) +#define I2S_INTENCLR_TXUR_Pos 12 /**< \brief (I2S_INTENCLR) Transmit Underrun x Interrupt Enable */ +#define I2S_INTENCLR_TXUR_Msk (0x3u << I2S_INTENCLR_TXUR_Pos) +#define I2S_INTENCLR_TXUR(value) ((I2S_INTENCLR_TXUR_Msk & ((value) << I2S_INTENCLR_TXUR_Pos))) +#define I2S_INTENCLR_MASK 0x3333u /**< \brief (I2S_INTENCLR) MASK Register */ + +/* -------- I2S_INTENSET : (I2S Offset: 0x10) (R/W 16) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t RXRDY0:1; /*!< bit: 0 Receive Ready 0 Interrupt Enable */ + uint16_t RXRDY1:1; /*!< bit: 1 Receive Ready 1 Interrupt Enable */ + uint16_t :2; /*!< bit: 2.. 3 Reserved */ + uint16_t RXOR0:1; /*!< bit: 4 Receive Overrun 0 Interrupt Enable */ + uint16_t RXOR1:1; /*!< bit: 5 Receive Overrun 1 Interrupt Enable */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t TXRDY0:1; /*!< bit: 8 Transmit Ready 0 Interrupt Enable */ + uint16_t TXRDY1:1; /*!< bit: 9 Transmit Ready 1 Interrupt Enable */ + uint16_t :2; /*!< bit: 10..11 Reserved */ + uint16_t TXUR0:1; /*!< bit: 12 Transmit Underrun 0 Interrupt Enable */ + uint16_t TXUR1:1; /*!< bit: 13 Transmit Underrun 1 Interrupt Enable */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t RXRDY:2; /*!< bit: 0.. 1 Receive Ready x Interrupt Enable */ + uint16_t :2; /*!< bit: 2.. 3 Reserved */ + uint16_t RXOR:2; /*!< bit: 4.. 5 Receive Overrun x Interrupt Enable */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t TXRDY:2; /*!< bit: 8.. 9 Transmit Ready x Interrupt Enable */ + uint16_t :2; /*!< bit: 10..11 Reserved */ + uint16_t TXUR:2; /*!< bit: 12..13 Transmit Underrun x Interrupt Enable */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} I2S_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define I2S_INTENSET_OFFSET 0x10 /**< \brief (I2S_INTENSET offset) Interrupt Enable Set */ +#define I2S_INTENSET_RESETVALUE 0x0000 /**< \brief (I2S_INTENSET reset_value) Interrupt Enable Set */ + +#define I2S_INTENSET_RXRDY0_Pos 0 /**< \brief (I2S_INTENSET) Receive Ready 0 Interrupt Enable */ +#define I2S_INTENSET_RXRDY0 (1 << I2S_INTENSET_RXRDY0_Pos) +#define I2S_INTENSET_RXRDY1_Pos 1 /**< \brief (I2S_INTENSET) Receive Ready 1 Interrupt Enable */ +#define I2S_INTENSET_RXRDY1 (1 << I2S_INTENSET_RXRDY1_Pos) +#define I2S_INTENSET_RXRDY_Pos 0 /**< \brief (I2S_INTENSET) Receive Ready x Interrupt Enable */ +#define I2S_INTENSET_RXRDY_Msk (0x3u << I2S_INTENSET_RXRDY_Pos) +#define I2S_INTENSET_RXRDY(value) ((I2S_INTENSET_RXRDY_Msk & ((value) << I2S_INTENSET_RXRDY_Pos))) +#define I2S_INTENSET_RXOR0_Pos 4 /**< \brief (I2S_INTENSET) Receive Overrun 0 Interrupt Enable */ +#define I2S_INTENSET_RXOR0 (1 << I2S_INTENSET_RXOR0_Pos) +#define I2S_INTENSET_RXOR1_Pos 5 /**< \brief (I2S_INTENSET) Receive Overrun 1 Interrupt Enable */ +#define I2S_INTENSET_RXOR1 (1 << I2S_INTENSET_RXOR1_Pos) +#define I2S_INTENSET_RXOR_Pos 4 /**< \brief (I2S_INTENSET) Receive Overrun x Interrupt Enable */ +#define I2S_INTENSET_RXOR_Msk (0x3u << I2S_INTENSET_RXOR_Pos) +#define I2S_INTENSET_RXOR(value) ((I2S_INTENSET_RXOR_Msk & ((value) << I2S_INTENSET_RXOR_Pos))) +#define I2S_INTENSET_TXRDY0_Pos 8 /**< \brief (I2S_INTENSET) Transmit Ready 0 Interrupt Enable */ +#define I2S_INTENSET_TXRDY0 (1 << I2S_INTENSET_TXRDY0_Pos) +#define I2S_INTENSET_TXRDY1_Pos 9 /**< \brief (I2S_INTENSET) Transmit Ready 1 Interrupt Enable */ +#define I2S_INTENSET_TXRDY1 (1 << I2S_INTENSET_TXRDY1_Pos) +#define I2S_INTENSET_TXRDY_Pos 8 /**< \brief (I2S_INTENSET) Transmit Ready x Interrupt Enable */ +#define I2S_INTENSET_TXRDY_Msk (0x3u << I2S_INTENSET_TXRDY_Pos) +#define I2S_INTENSET_TXRDY(value) ((I2S_INTENSET_TXRDY_Msk & ((value) << I2S_INTENSET_TXRDY_Pos))) +#define I2S_INTENSET_TXUR0_Pos 12 /**< \brief (I2S_INTENSET) Transmit Underrun 0 Interrupt Enable */ +#define I2S_INTENSET_TXUR0 (1 << I2S_INTENSET_TXUR0_Pos) +#define I2S_INTENSET_TXUR1_Pos 13 /**< \brief (I2S_INTENSET) Transmit Underrun 1 Interrupt Enable */ +#define I2S_INTENSET_TXUR1 (1 << I2S_INTENSET_TXUR1_Pos) +#define I2S_INTENSET_TXUR_Pos 12 /**< \brief (I2S_INTENSET) Transmit Underrun x Interrupt Enable */ +#define I2S_INTENSET_TXUR_Msk (0x3u << I2S_INTENSET_TXUR_Pos) +#define I2S_INTENSET_TXUR(value) ((I2S_INTENSET_TXUR_Msk & ((value) << I2S_INTENSET_TXUR_Pos))) +#define I2S_INTENSET_MASK 0x3333u /**< \brief (I2S_INTENSET) MASK Register */ + +/* -------- I2S_INTFLAG : (I2S Offset: 0x14) (R/W 16) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t RXRDY0:1; /*!< bit: 0 Receive Ready 0 */ + uint16_t RXRDY1:1; /*!< bit: 1 Receive Ready 1 */ + uint16_t :2; /*!< bit: 2.. 3 Reserved */ + uint16_t RXOR0:1; /*!< bit: 4 Receive Overrun 0 */ + uint16_t RXOR1:1; /*!< bit: 5 Receive Overrun 1 */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t TXRDY0:1; /*!< bit: 8 Transmit Ready 0 */ + uint16_t TXRDY1:1; /*!< bit: 9 Transmit Ready 1 */ + uint16_t :2; /*!< bit: 10..11 Reserved */ + uint16_t TXUR0:1; /*!< bit: 12 Transmit Underrun 0 */ + uint16_t TXUR1:1; /*!< bit: 13 Transmit Underrun 1 */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t RXRDY:2; /*!< bit: 0.. 1 Receive Ready x */ + uint16_t :2; /*!< bit: 2.. 3 Reserved */ + uint16_t RXOR:2; /*!< bit: 4.. 5 Receive Overrun x */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t TXRDY:2; /*!< bit: 8.. 9 Transmit Ready x */ + uint16_t :2; /*!< bit: 10..11 Reserved */ + uint16_t TXUR:2; /*!< bit: 12..13 Transmit Underrun x */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} I2S_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define I2S_INTFLAG_OFFSET 0x14 /**< \brief (I2S_INTFLAG offset) Interrupt Flag Status and Clear */ +#define I2S_INTFLAG_RESETVALUE 0x0000 /**< \brief (I2S_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define I2S_INTFLAG_RXRDY0_Pos 0 /**< \brief (I2S_INTFLAG) Receive Ready 0 */ +#define I2S_INTFLAG_RXRDY0 (1 << I2S_INTFLAG_RXRDY0_Pos) +#define I2S_INTFLAG_RXRDY1_Pos 1 /**< \brief (I2S_INTFLAG) Receive Ready 1 */ +#define I2S_INTFLAG_RXRDY1 (1 << I2S_INTFLAG_RXRDY1_Pos) +#define I2S_INTFLAG_RXRDY_Pos 0 /**< \brief (I2S_INTFLAG) Receive Ready x */ +#define I2S_INTFLAG_RXRDY_Msk (0x3u << I2S_INTFLAG_RXRDY_Pos) +#define I2S_INTFLAG_RXRDY(value) ((I2S_INTFLAG_RXRDY_Msk & ((value) << I2S_INTFLAG_RXRDY_Pos))) +#define I2S_INTFLAG_RXOR0_Pos 4 /**< \brief (I2S_INTFLAG) Receive Overrun 0 */ +#define I2S_INTFLAG_RXOR0 (1 << I2S_INTFLAG_RXOR0_Pos) +#define I2S_INTFLAG_RXOR1_Pos 5 /**< \brief (I2S_INTFLAG) Receive Overrun 1 */ +#define I2S_INTFLAG_RXOR1 (1 << I2S_INTFLAG_RXOR1_Pos) +#define I2S_INTFLAG_RXOR_Pos 4 /**< \brief (I2S_INTFLAG) Receive Overrun x */ +#define I2S_INTFLAG_RXOR_Msk (0x3u << I2S_INTFLAG_RXOR_Pos) +#define I2S_INTFLAG_RXOR(value) ((I2S_INTFLAG_RXOR_Msk & ((value) << I2S_INTFLAG_RXOR_Pos))) +#define I2S_INTFLAG_TXRDY0_Pos 8 /**< \brief (I2S_INTFLAG) Transmit Ready 0 */ +#define I2S_INTFLAG_TXRDY0 (1 << I2S_INTFLAG_TXRDY0_Pos) +#define I2S_INTFLAG_TXRDY1_Pos 9 /**< \brief (I2S_INTFLAG) Transmit Ready 1 */ +#define I2S_INTFLAG_TXRDY1 (1 << I2S_INTFLAG_TXRDY1_Pos) +#define I2S_INTFLAG_TXRDY_Pos 8 /**< \brief (I2S_INTFLAG) Transmit Ready x */ +#define I2S_INTFLAG_TXRDY_Msk (0x3u << I2S_INTFLAG_TXRDY_Pos) +#define I2S_INTFLAG_TXRDY(value) ((I2S_INTFLAG_TXRDY_Msk & ((value) << I2S_INTFLAG_TXRDY_Pos))) +#define I2S_INTFLAG_TXUR0_Pos 12 /**< \brief (I2S_INTFLAG) Transmit Underrun 0 */ +#define I2S_INTFLAG_TXUR0 (1 << I2S_INTFLAG_TXUR0_Pos) +#define I2S_INTFLAG_TXUR1_Pos 13 /**< \brief (I2S_INTFLAG) Transmit Underrun 1 */ +#define I2S_INTFLAG_TXUR1 (1 << I2S_INTFLAG_TXUR1_Pos) +#define I2S_INTFLAG_TXUR_Pos 12 /**< \brief (I2S_INTFLAG) Transmit Underrun x */ +#define I2S_INTFLAG_TXUR_Msk (0x3u << I2S_INTFLAG_TXUR_Pos) +#define I2S_INTFLAG_TXUR(value) ((I2S_INTFLAG_TXUR_Msk & ((value) << I2S_INTFLAG_TXUR_Pos))) +#define I2S_INTFLAG_MASK 0x3333u /**< \brief (I2S_INTFLAG) MASK Register */ + +/* -------- I2S_SYNCBUSY : (I2S Offset: 0x18) (R/ 16) Synchronization Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SWRST:1; /*!< bit: 0 Software Reset Synchronization Status */ + uint16_t ENABLE:1; /*!< bit: 1 Enable Synchronization Status */ + uint16_t CKEN0:1; /*!< bit: 2 Clock Unit 0 Enable Synchronization Status */ + uint16_t CKEN1:1; /*!< bit: 3 Clock Unit 1 Enable Synchronization Status */ + uint16_t SEREN0:1; /*!< bit: 4 Serializer 0 Enable Synchronization Status */ + uint16_t SEREN1:1; /*!< bit: 5 Serializer 1 Enable Synchronization Status */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t DATA0:1; /*!< bit: 8 Data 0 Synchronization Status */ + uint16_t DATA1:1; /*!< bit: 9 Data 1 Synchronization Status */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t :2; /*!< bit: 0.. 1 Reserved */ + uint16_t CKEN:2; /*!< bit: 2.. 3 Clock Unit x Enable Synchronization Status */ + uint16_t SEREN:2; /*!< bit: 4.. 5 Serializer x Enable Synchronization Status */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t DATA:2; /*!< bit: 8.. 9 Data x Synchronization Status */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} I2S_SYNCBUSY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define I2S_SYNCBUSY_OFFSET 0x18 /**< \brief (I2S_SYNCBUSY offset) Synchronization Status */ +#define I2S_SYNCBUSY_RESETVALUE 0x0000 /**< \brief (I2S_SYNCBUSY reset_value) Synchronization Status */ + +#define I2S_SYNCBUSY_SWRST_Pos 0 /**< \brief (I2S_SYNCBUSY) Software Reset Synchronization Status */ +#define I2S_SYNCBUSY_SWRST (0x1u << I2S_SYNCBUSY_SWRST_Pos) +#define I2S_SYNCBUSY_ENABLE_Pos 1 /**< \brief (I2S_SYNCBUSY) Enable Synchronization Status */ +#define I2S_SYNCBUSY_ENABLE (0x1u << I2S_SYNCBUSY_ENABLE_Pos) +#define I2S_SYNCBUSY_CKEN0_Pos 2 /**< \brief (I2S_SYNCBUSY) Clock Unit 0 Enable Synchronization Status */ +#define I2S_SYNCBUSY_CKEN0 (1 << I2S_SYNCBUSY_CKEN0_Pos) +#define I2S_SYNCBUSY_CKEN1_Pos 3 /**< \brief (I2S_SYNCBUSY) Clock Unit 1 Enable Synchronization Status */ +#define I2S_SYNCBUSY_CKEN1 (1 << I2S_SYNCBUSY_CKEN1_Pos) +#define I2S_SYNCBUSY_CKEN_Pos 2 /**< \brief (I2S_SYNCBUSY) Clock Unit x Enable Synchronization Status */ +#define I2S_SYNCBUSY_CKEN_Msk (0x3u << I2S_SYNCBUSY_CKEN_Pos) +#define I2S_SYNCBUSY_CKEN(value) ((I2S_SYNCBUSY_CKEN_Msk & ((value) << I2S_SYNCBUSY_CKEN_Pos))) +#define I2S_SYNCBUSY_SEREN0_Pos 4 /**< \brief (I2S_SYNCBUSY) Serializer 0 Enable Synchronization Status */ +#define I2S_SYNCBUSY_SEREN0 (1 << I2S_SYNCBUSY_SEREN0_Pos) +#define I2S_SYNCBUSY_SEREN1_Pos 5 /**< \brief (I2S_SYNCBUSY) Serializer 1 Enable Synchronization Status */ +#define I2S_SYNCBUSY_SEREN1 (1 << I2S_SYNCBUSY_SEREN1_Pos) +#define I2S_SYNCBUSY_SEREN_Pos 4 /**< \brief (I2S_SYNCBUSY) Serializer x Enable Synchronization Status */ +#define I2S_SYNCBUSY_SEREN_Msk (0x3u << I2S_SYNCBUSY_SEREN_Pos) +#define I2S_SYNCBUSY_SEREN(value) ((I2S_SYNCBUSY_SEREN_Msk & ((value) << I2S_SYNCBUSY_SEREN_Pos))) +#define I2S_SYNCBUSY_DATA0_Pos 8 /**< \brief (I2S_SYNCBUSY) Data 0 Synchronization Status */ +#define I2S_SYNCBUSY_DATA0 (1 << I2S_SYNCBUSY_DATA0_Pos) +#define I2S_SYNCBUSY_DATA1_Pos 9 /**< \brief (I2S_SYNCBUSY) Data 1 Synchronization Status */ +#define I2S_SYNCBUSY_DATA1 (1 << I2S_SYNCBUSY_DATA1_Pos) +#define I2S_SYNCBUSY_DATA_Pos 8 /**< \brief (I2S_SYNCBUSY) Data x Synchronization Status */ +#define I2S_SYNCBUSY_DATA_Msk (0x3u << I2S_SYNCBUSY_DATA_Pos) +#define I2S_SYNCBUSY_DATA(value) ((I2S_SYNCBUSY_DATA_Msk & ((value) << I2S_SYNCBUSY_DATA_Pos))) +#define I2S_SYNCBUSY_MASK 0x033Fu /**< \brief (I2S_SYNCBUSY) MASK Register */ + +/* -------- I2S_SERCTRL : (I2S Offset: 0x20) (R/W 32) Serializer n Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SERMODE:2; /*!< bit: 0.. 1 Serializer Mode */ + uint32_t TXDEFAULT:2; /*!< bit: 2.. 3 Line Default Line when Slot Disabled */ + uint32_t TXSAME:1; /*!< bit: 4 Transmit Data when Underrun */ + uint32_t CLKSEL:1; /*!< bit: 5 Clock Unit Selection */ + uint32_t :1; /*!< bit: 6 Reserved */ + uint32_t SLOTADJ:1; /*!< bit: 7 Data Slot Formatting Adjust */ + uint32_t DATASIZE:3; /*!< bit: 8..10 Data Word Size */ + uint32_t :1; /*!< bit: 11 Reserved */ + uint32_t WORDADJ:1; /*!< bit: 12 Data Word Formatting Adjust */ + uint32_t EXTEND:2; /*!< bit: 13..14 Data Formatting Bit Extension */ + uint32_t BITREV:1; /*!< bit: 15 Data Formatting Bit Reverse */ + uint32_t SLOTDIS0:1; /*!< bit: 16 Slot 0 Disabled for this Serializer */ + uint32_t SLOTDIS1:1; /*!< bit: 17 Slot 1 Disabled for this Serializer */ + uint32_t SLOTDIS2:1; /*!< bit: 18 Slot 2 Disabled for this Serializer */ + uint32_t SLOTDIS3:1; /*!< bit: 19 Slot 3 Disabled for this Serializer */ + uint32_t SLOTDIS4:1; /*!< bit: 20 Slot 4 Disabled for this Serializer */ + uint32_t SLOTDIS5:1; /*!< bit: 21 Slot 5 Disabled for this Serializer */ + uint32_t SLOTDIS6:1; /*!< bit: 22 Slot 6 Disabled for this Serializer */ + uint32_t SLOTDIS7:1; /*!< bit: 23 Slot 7 Disabled for this Serializer */ + uint32_t MONO:1; /*!< bit: 24 Mono Mode */ + uint32_t DMA:1; /*!< bit: 25 Single or Multiple DMA Channels */ + uint32_t RXLOOP:1; /*!< bit: 26 Loop-back Test Mode */ + uint32_t :5; /*!< bit: 27..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :16; /*!< bit: 0..15 Reserved */ + uint32_t SLOTDIS:8; /*!< bit: 16..23 Slot x Disabled for this Serializer */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} I2S_SERCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define I2S_SERCTRL_OFFSET 0x20 /**< \brief (I2S_SERCTRL offset) Serializer n Control */ +#define I2S_SERCTRL_RESETVALUE 0x00000000 /**< \brief (I2S_SERCTRL reset_value) Serializer n Control */ + +#define I2S_SERCTRL_SERMODE_Pos 0 /**< \brief (I2S_SERCTRL) Serializer Mode */ +#define I2S_SERCTRL_SERMODE_Msk (0x3u << I2S_SERCTRL_SERMODE_Pos) +#define I2S_SERCTRL_SERMODE(value) ((I2S_SERCTRL_SERMODE_Msk & ((value) << I2S_SERCTRL_SERMODE_Pos))) +#define I2S_SERCTRL_SERMODE_RX_Val 0x0u /**< \brief (I2S_SERCTRL) Receive */ +#define I2S_SERCTRL_SERMODE_TX_Val 0x1u /**< \brief (I2S_SERCTRL) Transmit */ +#define I2S_SERCTRL_SERMODE_PDM2_Val 0x2u /**< \brief (I2S_SERCTRL) Receive one PDM data on each serial clock edge */ +#define I2S_SERCTRL_SERMODE_RX (I2S_SERCTRL_SERMODE_RX_Val << I2S_SERCTRL_SERMODE_Pos) +#define I2S_SERCTRL_SERMODE_TX (I2S_SERCTRL_SERMODE_TX_Val << I2S_SERCTRL_SERMODE_Pos) +#define I2S_SERCTRL_SERMODE_PDM2 (I2S_SERCTRL_SERMODE_PDM2_Val << I2S_SERCTRL_SERMODE_Pos) +#define I2S_SERCTRL_TXDEFAULT_Pos 2 /**< \brief (I2S_SERCTRL) Line Default Line when Slot Disabled */ +#define I2S_SERCTRL_TXDEFAULT_Msk (0x3u << I2S_SERCTRL_TXDEFAULT_Pos) +#define I2S_SERCTRL_TXDEFAULT(value) ((I2S_SERCTRL_TXDEFAULT_Msk & ((value) << I2S_SERCTRL_TXDEFAULT_Pos))) +#define I2S_SERCTRL_TXDEFAULT_ZERO_Val 0x0u /**< \brief (I2S_SERCTRL) Output Default Value is 0 */ +#define I2S_SERCTRL_TXDEFAULT_ONE_Val 0x1u /**< \brief (I2S_SERCTRL) Output Default Value is 1 */ +#define I2S_SERCTRL_TXDEFAULT_HIZ_Val 0x3u /**< \brief (I2S_SERCTRL) Output Default Value is high impedance */ +#define I2S_SERCTRL_TXDEFAULT_ZERO (I2S_SERCTRL_TXDEFAULT_ZERO_Val << I2S_SERCTRL_TXDEFAULT_Pos) +#define I2S_SERCTRL_TXDEFAULT_ONE (I2S_SERCTRL_TXDEFAULT_ONE_Val << I2S_SERCTRL_TXDEFAULT_Pos) +#define I2S_SERCTRL_TXDEFAULT_HIZ (I2S_SERCTRL_TXDEFAULT_HIZ_Val << I2S_SERCTRL_TXDEFAULT_Pos) +#define I2S_SERCTRL_TXSAME_Pos 4 /**< \brief (I2S_SERCTRL) Transmit Data when Underrun */ +#define I2S_SERCTRL_TXSAME (0x1u << I2S_SERCTRL_TXSAME_Pos) +#define I2S_SERCTRL_TXSAME_ZERO_Val 0x0u /**< \brief (I2S_SERCTRL) Zero data transmitted in case of underrun */ +#define I2S_SERCTRL_TXSAME_SAME_Val 0x1u /**< \brief (I2S_SERCTRL) Last data transmitted in case of underrun */ +#define I2S_SERCTRL_TXSAME_ZERO (I2S_SERCTRL_TXSAME_ZERO_Val << I2S_SERCTRL_TXSAME_Pos) +#define I2S_SERCTRL_TXSAME_SAME (I2S_SERCTRL_TXSAME_SAME_Val << I2S_SERCTRL_TXSAME_Pos) +#define I2S_SERCTRL_CLKSEL_Pos 5 /**< \brief (I2S_SERCTRL) Clock Unit Selection */ +#define I2S_SERCTRL_CLKSEL (0x1u << I2S_SERCTRL_CLKSEL_Pos) +#define I2S_SERCTRL_CLKSEL_CLK0_Val 0x0u /**< \brief (I2S_SERCTRL) Use Clock Unit 0 */ +#define I2S_SERCTRL_CLKSEL_CLK1_Val 0x1u /**< \brief (I2S_SERCTRL) Use Clock Unit 1 */ +#define I2S_SERCTRL_CLKSEL_CLK0 (I2S_SERCTRL_CLKSEL_CLK0_Val << I2S_SERCTRL_CLKSEL_Pos) +#define I2S_SERCTRL_CLKSEL_CLK1 (I2S_SERCTRL_CLKSEL_CLK1_Val << I2S_SERCTRL_CLKSEL_Pos) +#define I2S_SERCTRL_SLOTADJ_Pos 7 /**< \brief (I2S_SERCTRL) Data Slot Formatting Adjust */ +#define I2S_SERCTRL_SLOTADJ (0x1u << I2S_SERCTRL_SLOTADJ_Pos) +#define I2S_SERCTRL_SLOTADJ_RIGHT_Val 0x0u /**< \brief (I2S_SERCTRL) Data is right adjusted in slot */ +#define I2S_SERCTRL_SLOTADJ_LEFT_Val 0x1u /**< \brief (I2S_SERCTRL) Data is left adjusted in slot */ +#define I2S_SERCTRL_SLOTADJ_RIGHT (I2S_SERCTRL_SLOTADJ_RIGHT_Val << I2S_SERCTRL_SLOTADJ_Pos) +#define I2S_SERCTRL_SLOTADJ_LEFT (I2S_SERCTRL_SLOTADJ_LEFT_Val << I2S_SERCTRL_SLOTADJ_Pos) +#define I2S_SERCTRL_DATASIZE_Pos 8 /**< \brief (I2S_SERCTRL) Data Word Size */ +#define I2S_SERCTRL_DATASIZE_Msk (0x7u << I2S_SERCTRL_DATASIZE_Pos) +#define I2S_SERCTRL_DATASIZE(value) ((I2S_SERCTRL_DATASIZE_Msk & ((value) << I2S_SERCTRL_DATASIZE_Pos))) +#define I2S_SERCTRL_DATASIZE_32_Val 0x0u /**< \brief (I2S_SERCTRL) 32 bits */ +#define I2S_SERCTRL_DATASIZE_24_Val 0x1u /**< \brief (I2S_SERCTRL) 24 bits */ +#define I2S_SERCTRL_DATASIZE_20_Val 0x2u /**< \brief (I2S_SERCTRL) 20 bits */ +#define I2S_SERCTRL_DATASIZE_18_Val 0x3u /**< \brief (I2S_SERCTRL) 18 bits */ +#define I2S_SERCTRL_DATASIZE_16_Val 0x4u /**< \brief (I2S_SERCTRL) 16 bits */ +#define I2S_SERCTRL_DATASIZE_16C_Val 0x5u /**< \brief (I2S_SERCTRL) 16 bits compact stereo */ +#define I2S_SERCTRL_DATASIZE_8_Val 0x6u /**< \brief (I2S_SERCTRL) 8 bits */ +#define I2S_SERCTRL_DATASIZE_8C_Val 0x7u /**< \brief (I2S_SERCTRL) 8 bits compact stereo */ +#define I2S_SERCTRL_DATASIZE_32 (I2S_SERCTRL_DATASIZE_32_Val << I2S_SERCTRL_DATASIZE_Pos) +#define I2S_SERCTRL_DATASIZE_24 (I2S_SERCTRL_DATASIZE_24_Val << I2S_SERCTRL_DATASIZE_Pos) +#define I2S_SERCTRL_DATASIZE_20 (I2S_SERCTRL_DATASIZE_20_Val << I2S_SERCTRL_DATASIZE_Pos) +#define I2S_SERCTRL_DATASIZE_18 (I2S_SERCTRL_DATASIZE_18_Val << I2S_SERCTRL_DATASIZE_Pos) +#define I2S_SERCTRL_DATASIZE_16 (I2S_SERCTRL_DATASIZE_16_Val << I2S_SERCTRL_DATASIZE_Pos) +#define I2S_SERCTRL_DATASIZE_16C (I2S_SERCTRL_DATASIZE_16C_Val << I2S_SERCTRL_DATASIZE_Pos) +#define I2S_SERCTRL_DATASIZE_8 (I2S_SERCTRL_DATASIZE_8_Val << I2S_SERCTRL_DATASIZE_Pos) +#define I2S_SERCTRL_DATASIZE_8C (I2S_SERCTRL_DATASIZE_8C_Val << I2S_SERCTRL_DATASIZE_Pos) +#define I2S_SERCTRL_WORDADJ_Pos 12 /**< \brief (I2S_SERCTRL) Data Word Formatting Adjust */ +#define I2S_SERCTRL_WORDADJ (0x1u << I2S_SERCTRL_WORDADJ_Pos) +#define I2S_SERCTRL_WORDADJ_RIGHT_Val 0x0u /**< \brief (I2S_SERCTRL) Data is right adjusted in word */ +#define I2S_SERCTRL_WORDADJ_LEFT_Val 0x1u /**< \brief (I2S_SERCTRL) Data is left adjusted in word */ +#define I2S_SERCTRL_WORDADJ_RIGHT (I2S_SERCTRL_WORDADJ_RIGHT_Val << I2S_SERCTRL_WORDADJ_Pos) +#define I2S_SERCTRL_WORDADJ_LEFT (I2S_SERCTRL_WORDADJ_LEFT_Val << I2S_SERCTRL_WORDADJ_Pos) +#define I2S_SERCTRL_EXTEND_Pos 13 /**< \brief (I2S_SERCTRL) Data Formatting Bit Extension */ +#define I2S_SERCTRL_EXTEND_Msk (0x3u << I2S_SERCTRL_EXTEND_Pos) +#define I2S_SERCTRL_EXTEND(value) ((I2S_SERCTRL_EXTEND_Msk & ((value) << I2S_SERCTRL_EXTEND_Pos))) +#define I2S_SERCTRL_EXTEND_ZERO_Val 0x0u /**< \brief (I2S_SERCTRL) Extend with zeroes */ +#define I2S_SERCTRL_EXTEND_ONE_Val 0x1u /**< \brief (I2S_SERCTRL) Extend with ones */ +#define I2S_SERCTRL_EXTEND_MSBIT_Val 0x2u /**< \brief (I2S_SERCTRL) Extend with Most Significant Bit */ +#define I2S_SERCTRL_EXTEND_LSBIT_Val 0x3u /**< \brief (I2S_SERCTRL) Extend with Least Significant Bit */ +#define I2S_SERCTRL_EXTEND_ZERO (I2S_SERCTRL_EXTEND_ZERO_Val << I2S_SERCTRL_EXTEND_Pos) +#define I2S_SERCTRL_EXTEND_ONE (I2S_SERCTRL_EXTEND_ONE_Val << I2S_SERCTRL_EXTEND_Pos) +#define I2S_SERCTRL_EXTEND_MSBIT (I2S_SERCTRL_EXTEND_MSBIT_Val << I2S_SERCTRL_EXTEND_Pos) +#define I2S_SERCTRL_EXTEND_LSBIT (I2S_SERCTRL_EXTEND_LSBIT_Val << I2S_SERCTRL_EXTEND_Pos) +#define I2S_SERCTRL_BITREV_Pos 15 /**< \brief (I2S_SERCTRL) Data Formatting Bit Reverse */ +#define I2S_SERCTRL_BITREV (0x1u << I2S_SERCTRL_BITREV_Pos) +#define I2S_SERCTRL_BITREV_MSBIT_Val 0x0u /**< \brief (I2S_SERCTRL) Transfer Data Most Significant Bit (MSB) first (default for I2S protocol) */ +#define I2S_SERCTRL_BITREV_LSBIT_Val 0x1u /**< \brief (I2S_SERCTRL) Transfer Data Least Significant Bit (LSB) first */ +#define I2S_SERCTRL_BITREV_MSBIT (I2S_SERCTRL_BITREV_MSBIT_Val << I2S_SERCTRL_BITREV_Pos) +#define I2S_SERCTRL_BITREV_LSBIT (I2S_SERCTRL_BITREV_LSBIT_Val << I2S_SERCTRL_BITREV_Pos) +#define I2S_SERCTRL_SLOTDIS0_Pos 16 /**< \brief (I2S_SERCTRL) Slot 0 Disabled for this Serializer */ +#define I2S_SERCTRL_SLOTDIS0 (1 << I2S_SERCTRL_SLOTDIS0_Pos) +#define I2S_SERCTRL_SLOTDIS1_Pos 17 /**< \brief (I2S_SERCTRL) Slot 1 Disabled for this Serializer */ +#define I2S_SERCTRL_SLOTDIS1 (1 << I2S_SERCTRL_SLOTDIS1_Pos) +#define I2S_SERCTRL_SLOTDIS2_Pos 18 /**< \brief (I2S_SERCTRL) Slot 2 Disabled for this Serializer */ +#define I2S_SERCTRL_SLOTDIS2 (1 << I2S_SERCTRL_SLOTDIS2_Pos) +#define I2S_SERCTRL_SLOTDIS3_Pos 19 /**< \brief (I2S_SERCTRL) Slot 3 Disabled for this Serializer */ +#define I2S_SERCTRL_SLOTDIS3 (1 << I2S_SERCTRL_SLOTDIS3_Pos) +#define I2S_SERCTRL_SLOTDIS4_Pos 20 /**< \brief (I2S_SERCTRL) Slot 4 Disabled for this Serializer */ +#define I2S_SERCTRL_SLOTDIS4 (1 << I2S_SERCTRL_SLOTDIS4_Pos) +#define I2S_SERCTRL_SLOTDIS5_Pos 21 /**< \brief (I2S_SERCTRL) Slot 5 Disabled for this Serializer */ +#define I2S_SERCTRL_SLOTDIS5 (1 << I2S_SERCTRL_SLOTDIS5_Pos) +#define I2S_SERCTRL_SLOTDIS6_Pos 22 /**< \brief (I2S_SERCTRL) Slot 6 Disabled for this Serializer */ +#define I2S_SERCTRL_SLOTDIS6 (1 << I2S_SERCTRL_SLOTDIS6_Pos) +#define I2S_SERCTRL_SLOTDIS7_Pos 23 /**< \brief (I2S_SERCTRL) Slot 7 Disabled for this Serializer */ +#define I2S_SERCTRL_SLOTDIS7 (1 << I2S_SERCTRL_SLOTDIS7_Pos) +#define I2S_SERCTRL_SLOTDIS_Pos 16 /**< \brief (I2S_SERCTRL) Slot x Disabled for this Serializer */ +#define I2S_SERCTRL_SLOTDIS_Msk (0xFFu << I2S_SERCTRL_SLOTDIS_Pos) +#define I2S_SERCTRL_SLOTDIS(value) ((I2S_SERCTRL_SLOTDIS_Msk & ((value) << I2S_SERCTRL_SLOTDIS_Pos))) +#define I2S_SERCTRL_MONO_Pos 24 /**< \brief (I2S_SERCTRL) Mono Mode */ +#define I2S_SERCTRL_MONO (0x1u << I2S_SERCTRL_MONO_Pos) +#define I2S_SERCTRL_MONO_STEREO_Val 0x0u /**< \brief (I2S_SERCTRL) Normal mode */ +#define I2S_SERCTRL_MONO_MONO_Val 0x1u /**< \brief (I2S_SERCTRL) Left channel data is duplicated to right channel */ +#define I2S_SERCTRL_MONO_STEREO (I2S_SERCTRL_MONO_STEREO_Val << I2S_SERCTRL_MONO_Pos) +#define I2S_SERCTRL_MONO_MONO (I2S_SERCTRL_MONO_MONO_Val << I2S_SERCTRL_MONO_Pos) +#define I2S_SERCTRL_DMA_Pos 25 /**< \brief (I2S_SERCTRL) Single or Multiple DMA Channels */ +#define I2S_SERCTRL_DMA (0x1u << I2S_SERCTRL_DMA_Pos) +#define I2S_SERCTRL_DMA_SINGLE_Val 0x0u /**< \brief (I2S_SERCTRL) Single DMA channel */ +#define I2S_SERCTRL_DMA_MULTIPLE_Val 0x1u /**< \brief (I2S_SERCTRL) One DMA channel per data channel */ +#define I2S_SERCTRL_DMA_SINGLE (I2S_SERCTRL_DMA_SINGLE_Val << I2S_SERCTRL_DMA_Pos) +#define I2S_SERCTRL_DMA_MULTIPLE (I2S_SERCTRL_DMA_MULTIPLE_Val << I2S_SERCTRL_DMA_Pos) +#define I2S_SERCTRL_RXLOOP_Pos 26 /**< \brief (I2S_SERCTRL) Loop-back Test Mode */ +#define I2S_SERCTRL_RXLOOP (0x1u << I2S_SERCTRL_RXLOOP_Pos) +#define I2S_SERCTRL_MASK 0x07FFF7BFu /**< \brief (I2S_SERCTRL) MASK Register */ + +/* -------- I2S_DATA : (I2S Offset: 0x30) (R/W 32) Data n -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DATA:32; /*!< bit: 0..31 Sample Data */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} I2S_DATA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define I2S_DATA_OFFSET 0x30 /**< \brief (I2S_DATA offset) Data n */ +#define I2S_DATA_RESETVALUE 0x00000000 /**< \brief (I2S_DATA reset_value) Data n */ + +#define I2S_DATA_DATA_Pos 0 /**< \brief (I2S_DATA) Sample Data */ +#define I2S_DATA_DATA_Msk (0xFFFFFFFFu << I2S_DATA_DATA_Pos) +#define I2S_DATA_DATA(value) ((I2S_DATA_DATA_Msk & ((value) << I2S_DATA_DATA_Pos))) +#define I2S_DATA_MASK 0xFFFFFFFFu /**< \brief (I2S_DATA) MASK Register */ + +/** \brief I2S hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO I2S_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 8) Control A */ + RoReg8 Reserved1[0x3]; + __IO I2S_CLKCTRL_Type CLKCTRL[2]; /**< \brief Offset: 0x04 (R/W 32) Clock Unit n Control */ + __IO I2S_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x0C (R/W 16) Interrupt Enable Clear */ + RoReg8 Reserved2[0x2]; + __IO I2S_INTENSET_Type INTENSET; /**< \brief Offset: 0x10 (R/W 16) Interrupt Enable Set */ + RoReg8 Reserved3[0x2]; + __IO I2S_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x14 (R/W 16) Interrupt Flag Status and Clear */ + RoReg8 Reserved4[0x2]; + __I I2S_SYNCBUSY_Type SYNCBUSY; /**< \brief Offset: 0x18 (R/ 16) Synchronization Status */ + RoReg8 Reserved5[0x6]; + __IO I2S_SERCTRL_Type SERCTRL[2]; /**< \brief Offset: 0x20 (R/W 32) Serializer n Control */ + RoReg8 Reserved6[0x8]; + __IO I2S_DATA_Type DATA[2]; /**< \brief Offset: 0x30 (R/W 32) Data n */ +} I2s; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_I2S_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/mtb.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/mtb.h new file mode 100755 index 0000000..fc6e988 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/mtb.h @@ -0,0 +1,396 @@ +/** + * \file + * + * \brief Component description for MTB + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_MTB_COMPONENT_ +#define _SAMD21_MTB_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR MTB */ +/* ========================================================================== */ +/** \addtogroup SAMD21_MTB Cortex-M0+ Micro-Trace Buffer */ +/*@{*/ + +#define MTB_U2002 +#define REV_MTB 0x100 + +/* -------- MTB_POSITION : (MTB Offset: 0x000) (R/W 32) MTB Position -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :2; /*!< bit: 0.. 1 Reserved */ + uint32_t WRAP:1; /*!< bit: 2 Pointer Value Wraps */ + uint32_t POINTER:29; /*!< bit: 3..31 Trace Packet Location Pointer */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} MTB_POSITION_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_POSITION_OFFSET 0x000 /**< \brief (MTB_POSITION offset) MTB Position */ + +#define MTB_POSITION_WRAP_Pos 2 /**< \brief (MTB_POSITION) Pointer Value Wraps */ +#define MTB_POSITION_WRAP (0x1u << MTB_POSITION_WRAP_Pos) +#define MTB_POSITION_POINTER_Pos 3 /**< \brief (MTB_POSITION) Trace Packet Location Pointer */ +#define MTB_POSITION_POINTER_Msk (0x1FFFFFFFu << MTB_POSITION_POINTER_Pos) +#define MTB_POSITION_POINTER(value) ((MTB_POSITION_POINTER_Msk & ((value) << MTB_POSITION_POINTER_Pos))) +#define MTB_POSITION_MASK 0xFFFFFFFCu /**< \brief (MTB_POSITION) MASK Register */ + +/* -------- MTB_MASTER : (MTB Offset: 0x004) (R/W 32) MTB Master -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t MASK:5; /*!< bit: 0.. 4 Maximum Value of the Trace Buffer in SRAM */ + uint32_t TSTARTEN:1; /*!< bit: 5 Trace Start Input Enable */ + uint32_t TSTOPEN:1; /*!< bit: 6 Trace Stop Input Enable */ + uint32_t SFRWPRIV:1; /*!< bit: 7 Special Function Register Write Privilege */ + uint32_t RAMPRIV:1; /*!< bit: 8 SRAM Privilege */ + uint32_t HALTREQ:1; /*!< bit: 9 Halt Request */ + uint32_t :21; /*!< bit: 10..30 Reserved */ + uint32_t EN:1; /*!< bit: 31 Main Trace Enable */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} MTB_MASTER_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_MASTER_OFFSET 0x004 /**< \brief (MTB_MASTER offset) MTB Master */ +#define MTB_MASTER_RESETVALUE 0x00000000 /**< \brief (MTB_MASTER reset_value) MTB Master */ + +#define MTB_MASTER_MASK_Pos 0 /**< \brief (MTB_MASTER) Maximum Value of the Trace Buffer in SRAM */ +#define MTB_MASTER_MASK_Msk (0x1Fu << MTB_MASTER_MASK_Pos) +#define MTB_MASTER_MASK(value) ((MTB_MASTER_MASK_Msk & ((value) << MTB_MASTER_MASK_Pos))) +#define MTB_MASTER_TSTARTEN_Pos 5 /**< \brief (MTB_MASTER) Trace Start Input Enable */ +#define MTB_MASTER_TSTARTEN (0x1u << MTB_MASTER_TSTARTEN_Pos) +#define MTB_MASTER_TSTOPEN_Pos 6 /**< \brief (MTB_MASTER) Trace Stop Input Enable */ +#define MTB_MASTER_TSTOPEN (0x1u << MTB_MASTER_TSTOPEN_Pos) +#define MTB_MASTER_SFRWPRIV_Pos 7 /**< \brief (MTB_MASTER) Special Function Register Write Privilege */ +#define MTB_MASTER_SFRWPRIV (0x1u << MTB_MASTER_SFRWPRIV_Pos) +#define MTB_MASTER_RAMPRIV_Pos 8 /**< \brief (MTB_MASTER) SRAM Privilege */ +#define MTB_MASTER_RAMPRIV (0x1u << MTB_MASTER_RAMPRIV_Pos) +#define MTB_MASTER_HALTREQ_Pos 9 /**< \brief (MTB_MASTER) Halt Request */ +#define MTB_MASTER_HALTREQ (0x1u << MTB_MASTER_HALTREQ_Pos) +#define MTB_MASTER_EN_Pos 31 /**< \brief (MTB_MASTER) Main Trace Enable */ +#define MTB_MASTER_EN (0x1u << MTB_MASTER_EN_Pos) +#define MTB_MASTER_MASK_ 0x800003FFu /**< \brief (MTB_MASTER) MASK Register */ + +/* -------- MTB_FLOW : (MTB Offset: 0x008) (R/W 32) MTB Flow -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t AUTOSTOP:1; /*!< bit: 0 Auto Stop Tracing */ + uint32_t AUTOHALT:1; /*!< bit: 1 Auto Halt Request */ + uint32_t :1; /*!< bit: 2 Reserved */ + uint32_t WATERMARK:29; /*!< bit: 3..31 Watermark value */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} MTB_FLOW_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_FLOW_OFFSET 0x008 /**< \brief (MTB_FLOW offset) MTB Flow */ +#define MTB_FLOW_RESETVALUE 0x00000000 /**< \brief (MTB_FLOW reset_value) MTB Flow */ + +#define MTB_FLOW_AUTOSTOP_Pos 0 /**< \brief (MTB_FLOW) Auto Stop Tracing */ +#define MTB_FLOW_AUTOSTOP (0x1u << MTB_FLOW_AUTOSTOP_Pos) +#define MTB_FLOW_AUTOHALT_Pos 1 /**< \brief (MTB_FLOW) Auto Halt Request */ +#define MTB_FLOW_AUTOHALT (0x1u << MTB_FLOW_AUTOHALT_Pos) +#define MTB_FLOW_WATERMARK_Pos 3 /**< \brief (MTB_FLOW) Watermark value */ +#define MTB_FLOW_WATERMARK_Msk (0x1FFFFFFFu << MTB_FLOW_WATERMARK_Pos) +#define MTB_FLOW_WATERMARK(value) ((MTB_FLOW_WATERMARK_Msk & ((value) << MTB_FLOW_WATERMARK_Pos))) +#define MTB_FLOW_MASK 0xFFFFFFFBu /**< \brief (MTB_FLOW) MASK Register */ + +/* -------- MTB_BASE : (MTB Offset: 0x00C) (R/ 32) MTB Base -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_BASE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_BASE_OFFSET 0x00C /**< \brief (MTB_BASE offset) MTB Base */ +#define MTB_BASE_MASK 0xFFFFFFFFu /**< \brief (MTB_BASE) MASK Register */ + +/* -------- MTB_ITCTRL : (MTB Offset: 0xF00) (R/W 32) MTB Integration Mode Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_ITCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_ITCTRL_OFFSET 0xF00 /**< \brief (MTB_ITCTRL offset) MTB Integration Mode Control */ +#define MTB_ITCTRL_MASK 0xFFFFFFFFu /**< \brief (MTB_ITCTRL) MASK Register */ + +/* -------- MTB_CLAIMSET : (MTB Offset: 0xFA0) (R/W 32) MTB Claim Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_CLAIMSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_CLAIMSET_OFFSET 0xFA0 /**< \brief (MTB_CLAIMSET offset) MTB Claim Set */ +#define MTB_CLAIMSET_MASK 0xFFFFFFFFu /**< \brief (MTB_CLAIMSET) MASK Register */ + +/* -------- MTB_CLAIMCLR : (MTB Offset: 0xFA4) (R/W 32) MTB Claim Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_CLAIMCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_CLAIMCLR_OFFSET 0xFA4 /**< \brief (MTB_CLAIMCLR offset) MTB Claim Clear */ +#define MTB_CLAIMCLR_MASK 0xFFFFFFFFu /**< \brief (MTB_CLAIMCLR) MASK Register */ + +/* -------- MTB_LOCKACCESS : (MTB Offset: 0xFB0) (R/W 32) MTB Lock Access -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_LOCKACCESS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_LOCKACCESS_OFFSET 0xFB0 /**< \brief (MTB_LOCKACCESS offset) MTB Lock Access */ +#define MTB_LOCKACCESS_MASK 0xFFFFFFFFu /**< \brief (MTB_LOCKACCESS) MASK Register */ + +/* -------- MTB_LOCKSTATUS : (MTB Offset: 0xFB4) (R/ 32) MTB Lock Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_LOCKSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_LOCKSTATUS_OFFSET 0xFB4 /**< \brief (MTB_LOCKSTATUS offset) MTB Lock Status */ +#define MTB_LOCKSTATUS_MASK 0xFFFFFFFFu /**< \brief (MTB_LOCKSTATUS) MASK Register */ + +/* -------- MTB_AUTHSTATUS : (MTB Offset: 0xFB8) (R/ 32) MTB Authentication Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_AUTHSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_AUTHSTATUS_OFFSET 0xFB8 /**< \brief (MTB_AUTHSTATUS offset) MTB Authentication Status */ +#define MTB_AUTHSTATUS_MASK 0xFFFFFFFFu /**< \brief (MTB_AUTHSTATUS) MASK Register */ + +/* -------- MTB_DEVARCH : (MTB Offset: 0xFBC) (R/ 32) MTB Device Architecture -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_DEVARCH_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_DEVARCH_OFFSET 0xFBC /**< \brief (MTB_DEVARCH offset) MTB Device Architecture */ +#define MTB_DEVARCH_MASK 0xFFFFFFFFu /**< \brief (MTB_DEVARCH) MASK Register */ + +/* -------- MTB_DEVID : (MTB Offset: 0xFC8) (R/ 32) MTB Device Configuration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_DEVID_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_DEVID_OFFSET 0xFC8 /**< \brief (MTB_DEVID offset) MTB Device Configuration */ +#define MTB_DEVID_MASK 0xFFFFFFFFu /**< \brief (MTB_DEVID) MASK Register */ + +/* -------- MTB_DEVTYPE : (MTB Offset: 0xFCC) (R/ 32) MTB Device Type -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_DEVTYPE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_DEVTYPE_OFFSET 0xFCC /**< \brief (MTB_DEVTYPE offset) MTB Device Type */ +#define MTB_DEVTYPE_MASK 0xFFFFFFFFu /**< \brief (MTB_DEVTYPE) MASK Register */ + +/* -------- MTB_PID4 : (MTB Offset: 0xFD0) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_PID4_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_PID4_OFFSET 0xFD0 /**< \brief (MTB_PID4 offset) CoreSight */ +#define MTB_PID4_MASK 0xFFFFFFFFu /**< \brief (MTB_PID4) MASK Register */ + +/* -------- MTB_PID5 : (MTB Offset: 0xFD4) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_PID5_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_PID5_OFFSET 0xFD4 /**< \brief (MTB_PID5 offset) CoreSight */ +#define MTB_PID5_MASK 0xFFFFFFFFu /**< \brief (MTB_PID5) MASK Register */ + +/* -------- MTB_PID6 : (MTB Offset: 0xFD8) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_PID6_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_PID6_OFFSET 0xFD8 /**< \brief (MTB_PID6 offset) CoreSight */ +#define MTB_PID6_MASK 0xFFFFFFFFu /**< \brief (MTB_PID6) MASK Register */ + +/* -------- MTB_PID7 : (MTB Offset: 0xFDC) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_PID7_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_PID7_OFFSET 0xFDC /**< \brief (MTB_PID7 offset) CoreSight */ +#define MTB_PID7_MASK 0xFFFFFFFFu /**< \brief (MTB_PID7) MASK Register */ + +/* -------- MTB_PID0 : (MTB Offset: 0xFE0) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_PID0_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_PID0_OFFSET 0xFE0 /**< \brief (MTB_PID0 offset) CoreSight */ +#define MTB_PID0_MASK 0xFFFFFFFFu /**< \brief (MTB_PID0) MASK Register */ + +/* -------- MTB_PID1 : (MTB Offset: 0xFE4) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_PID1_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_PID1_OFFSET 0xFE4 /**< \brief (MTB_PID1 offset) CoreSight */ +#define MTB_PID1_MASK 0xFFFFFFFFu /**< \brief (MTB_PID1) MASK Register */ + +/* -------- MTB_PID2 : (MTB Offset: 0xFE8) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_PID2_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_PID2_OFFSET 0xFE8 /**< \brief (MTB_PID2 offset) CoreSight */ +#define MTB_PID2_MASK 0xFFFFFFFFu /**< \brief (MTB_PID2) MASK Register */ + +/* -------- MTB_PID3 : (MTB Offset: 0xFEC) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_PID3_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_PID3_OFFSET 0xFEC /**< \brief (MTB_PID3 offset) CoreSight */ +#define MTB_PID3_MASK 0xFFFFFFFFu /**< \brief (MTB_PID3) MASK Register */ + +/* -------- MTB_CID0 : (MTB Offset: 0xFF0) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_CID0_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_CID0_OFFSET 0xFF0 /**< \brief (MTB_CID0 offset) CoreSight */ +#define MTB_CID0_MASK 0xFFFFFFFFu /**< \brief (MTB_CID0) MASK Register */ + +/* -------- MTB_CID1 : (MTB Offset: 0xFF4) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_CID1_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_CID1_OFFSET 0xFF4 /**< \brief (MTB_CID1 offset) CoreSight */ +#define MTB_CID1_MASK 0xFFFFFFFFu /**< \brief (MTB_CID1) MASK Register */ + +/* -------- MTB_CID2 : (MTB Offset: 0xFF8) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_CID2_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_CID2_OFFSET 0xFF8 /**< \brief (MTB_CID2 offset) CoreSight */ +#define MTB_CID2_MASK 0xFFFFFFFFu /**< \brief (MTB_CID2) MASK Register */ + +/* -------- MTB_CID3 : (MTB Offset: 0xFFC) (R/ 32) CoreSight -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint32_t reg; /*!< Type used for register access */ +} MTB_CID3_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define MTB_CID3_OFFSET 0xFFC /**< \brief (MTB_CID3 offset) CoreSight */ +#define MTB_CID3_MASK 0xFFFFFFFFu /**< \brief (MTB_CID3) MASK Register */ + +/** \brief MTB hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO MTB_POSITION_Type POSITION; /**< \brief Offset: 0x000 (R/W 32) MTB Position */ + __IO MTB_MASTER_Type MASTER; /**< \brief Offset: 0x004 (R/W 32) MTB Master */ + __IO MTB_FLOW_Type FLOW; /**< \brief Offset: 0x008 (R/W 32) MTB Flow */ + __I MTB_BASE_Type BASE; /**< \brief Offset: 0x00C (R/ 32) MTB Base */ + RoReg8 Reserved1[0xEF0]; + __IO MTB_ITCTRL_Type ITCTRL; /**< \brief Offset: 0xF00 (R/W 32) MTB Integration Mode Control */ + RoReg8 Reserved2[0x9C]; + __IO MTB_CLAIMSET_Type CLAIMSET; /**< \brief Offset: 0xFA0 (R/W 32) MTB Claim Set */ + __IO MTB_CLAIMCLR_Type CLAIMCLR; /**< \brief Offset: 0xFA4 (R/W 32) MTB Claim Clear */ + RoReg8 Reserved3[0x8]; + __IO MTB_LOCKACCESS_Type LOCKACCESS; /**< \brief Offset: 0xFB0 (R/W 32) MTB Lock Access */ + __I MTB_LOCKSTATUS_Type LOCKSTATUS; /**< \brief Offset: 0xFB4 (R/ 32) MTB Lock Status */ + __I MTB_AUTHSTATUS_Type AUTHSTATUS; /**< \brief Offset: 0xFB8 (R/ 32) MTB Authentication Status */ + __I MTB_DEVARCH_Type DEVARCH; /**< \brief Offset: 0xFBC (R/ 32) MTB Device Architecture */ + RoReg8 Reserved4[0x8]; + __I MTB_DEVID_Type DEVID; /**< \brief Offset: 0xFC8 (R/ 32) MTB Device Configuration */ + __I MTB_DEVTYPE_Type DEVTYPE; /**< \brief Offset: 0xFCC (R/ 32) MTB Device Type */ + __I MTB_PID4_Type PID4; /**< \brief Offset: 0xFD0 (R/ 32) CoreSight */ + __I MTB_PID5_Type PID5; /**< \brief Offset: 0xFD4 (R/ 32) CoreSight */ + __I MTB_PID6_Type PID6; /**< \brief Offset: 0xFD8 (R/ 32) CoreSight */ + __I MTB_PID7_Type PID7; /**< \brief Offset: 0xFDC (R/ 32) CoreSight */ + __I MTB_PID0_Type PID0; /**< \brief Offset: 0xFE0 (R/ 32) CoreSight */ + __I MTB_PID1_Type PID1; /**< \brief Offset: 0xFE4 (R/ 32) CoreSight */ + __I MTB_PID2_Type PID2; /**< \brief Offset: 0xFE8 (R/ 32) CoreSight */ + __I MTB_PID3_Type PID3; /**< \brief Offset: 0xFEC (R/ 32) CoreSight */ + __I MTB_CID0_Type CID0; /**< \brief Offset: 0xFF0 (R/ 32) CoreSight */ + __I MTB_CID1_Type CID1; /**< \brief Offset: 0xFF4 (R/ 32) CoreSight */ + __I MTB_CID2_Type CID2; /**< \brief Offset: 0xFF8 (R/ 32) CoreSight */ + __I MTB_CID3_Type CID3; /**< \brief Offset: 0xFFC (R/ 32) CoreSight */ +} Mtb; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_MTB_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/nvmctrl.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/nvmctrl.h new file mode 100755 index 0000000..b7f1af7 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/nvmctrl.h @@ -0,0 +1,530 @@ +/** + * \file + * + * \brief Component description for NVMCTRL + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_NVMCTRL_COMPONENT_ +#define _SAMD21_NVMCTRL_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR NVMCTRL */ +/* ========================================================================== */ +/** \addtogroup SAMD21_NVMCTRL Non-Volatile Memory Controller */ +/*@{*/ + +#define NVMCTRL_U2207 +#define REV_NVMCTRL 0x106 + +/* -------- NVMCTRL_CTRLA : (NVMCTRL Offset: 0x00) (R/W 16) Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t CMD:7; /*!< bit: 0.. 6 Command */ + uint16_t :1; /*!< bit: 7 Reserved */ + uint16_t CMDEX:8; /*!< bit: 8..15 Command Execution */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} NVMCTRL_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define NVMCTRL_CTRLA_OFFSET 0x00 /**< \brief (NVMCTRL_CTRLA offset) Control A */ +#define NVMCTRL_CTRLA_RESETVALUE 0x0000 /**< \brief (NVMCTRL_CTRLA reset_value) Control A */ + +#define NVMCTRL_CTRLA_CMD_Pos 0 /**< \brief (NVMCTRL_CTRLA) Command */ +#define NVMCTRL_CTRLA_CMD_Msk (0x7Fu << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD(value) ((NVMCTRL_CTRLA_CMD_Msk & ((value) << NVMCTRL_CTRLA_CMD_Pos))) +#define NVMCTRL_CTRLA_CMD_ER_Val 0x2u /**< \brief (NVMCTRL_CTRLA) Erase Row - Erases the row addressed by the ADDR register. */ +#define NVMCTRL_CTRLA_CMD_WP_Val 0x4u /**< \brief (NVMCTRL_CTRLA) Write Page - Writes the contents of the page buffer to the page addressed by the ADDR register. */ +#define NVMCTRL_CTRLA_CMD_EAR_Val 0x5u /**< \brief (NVMCTRL_CTRLA) Erase Auxiliary Row - Erases the auxiliary row addressed by the ADDR register. This command can be given only when the security bit is not set and only to the user configuration row. */ +#define NVMCTRL_CTRLA_CMD_WAP_Val 0x6u /**< \brief (NVMCTRL_CTRLA) Write Auxiliary Page - Writes the contents of the page buffer to the page addressed by the ADDR register. This command can be given only when the security bit is not set and only to the user configuration row. */ +#define NVMCTRL_CTRLA_CMD_SF_Val 0xAu /**< \brief (NVMCTRL_CTRLA) Security Flow Command */ +#define NVMCTRL_CTRLA_CMD_WL_Val 0xFu /**< \brief (NVMCTRL_CTRLA) Write lockbits */ +#define NVMCTRL_CTRLA_CMD_LR_Val 0x40u /**< \brief (NVMCTRL_CTRLA) Lock Region - Locks the region containing the address location in the ADDR register. */ +#define NVMCTRL_CTRLA_CMD_UR_Val 0x41u /**< \brief (NVMCTRL_CTRLA) Unlock Region - Unlocks the region containing the address location in the ADDR register. */ +#define NVMCTRL_CTRLA_CMD_SPRM_Val 0x42u /**< \brief (NVMCTRL_CTRLA) Sets the power reduction mode. */ +#define NVMCTRL_CTRLA_CMD_CPRM_Val 0x43u /**< \brief (NVMCTRL_CTRLA) Clears the power reduction mode. */ +#define NVMCTRL_CTRLA_CMD_PBC_Val 0x44u /**< \brief (NVMCTRL_CTRLA) Page Buffer Clear - Clears the page buffer. */ +#define NVMCTRL_CTRLA_CMD_SSB_Val 0x45u /**< \brief (NVMCTRL_CTRLA) Set Security Bit - Sets the security bit by writing 0x00 to the first byte in the lockbit row. */ +#define NVMCTRL_CTRLA_CMD_INVALL_Val 0x46u /**< \brief (NVMCTRL_CTRLA) Invalidates all cache lines. */ +#define NVMCTRL_CTRLA_CMD_ER (NVMCTRL_CTRLA_CMD_ER_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_WP (NVMCTRL_CTRLA_CMD_WP_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_EAR (NVMCTRL_CTRLA_CMD_EAR_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_WAP (NVMCTRL_CTRLA_CMD_WAP_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_SF (NVMCTRL_CTRLA_CMD_SF_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_WL (NVMCTRL_CTRLA_CMD_WL_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_LR (NVMCTRL_CTRLA_CMD_LR_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_UR (NVMCTRL_CTRLA_CMD_UR_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_SPRM (NVMCTRL_CTRLA_CMD_SPRM_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_CPRM (NVMCTRL_CTRLA_CMD_CPRM_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_PBC (NVMCTRL_CTRLA_CMD_PBC_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_SSB (NVMCTRL_CTRLA_CMD_SSB_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMD_INVALL (NVMCTRL_CTRLA_CMD_INVALL_Val << NVMCTRL_CTRLA_CMD_Pos) +#define NVMCTRL_CTRLA_CMDEX_Pos 8 /**< \brief (NVMCTRL_CTRLA) Command Execution */ +#define NVMCTRL_CTRLA_CMDEX_Msk (0xFFu << NVMCTRL_CTRLA_CMDEX_Pos) +#define NVMCTRL_CTRLA_CMDEX(value) ((NVMCTRL_CTRLA_CMDEX_Msk & ((value) << NVMCTRL_CTRLA_CMDEX_Pos))) +#define NVMCTRL_CTRLA_CMDEX_KEY_Val 0xA5u /**< \brief (NVMCTRL_CTRLA) Execution Key */ +#define NVMCTRL_CTRLA_CMDEX_KEY (NVMCTRL_CTRLA_CMDEX_KEY_Val << NVMCTRL_CTRLA_CMDEX_Pos) +#define NVMCTRL_CTRLA_MASK 0xFF7Fu /**< \brief (NVMCTRL_CTRLA) MASK Register */ + +/* -------- NVMCTRL_CTRLB : (NVMCTRL Offset: 0x04) (R/W 32) Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :1; /*!< bit: 0 Reserved */ + uint32_t RWS:4; /*!< bit: 1.. 4 NVM Read Wait States */ + uint32_t :2; /*!< bit: 5.. 6 Reserved */ + uint32_t MANW:1; /*!< bit: 7 Manual Write */ + uint32_t SLEEPPRM:2; /*!< bit: 8.. 9 Power Reduction Mode during Sleep */ + uint32_t :6; /*!< bit: 10..15 Reserved */ + uint32_t READMODE:2; /*!< bit: 16..17 NVMCTRL Read Mode */ + uint32_t CACHEDIS:1; /*!< bit: 18 Cache Disable */ + uint32_t :13; /*!< bit: 19..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} NVMCTRL_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define NVMCTRL_CTRLB_OFFSET 0x04 /**< \brief (NVMCTRL_CTRLB offset) Control B */ +#define NVMCTRL_CTRLB_RESETVALUE 0x00000000 /**< \brief (NVMCTRL_CTRLB reset_value) Control B */ + +#define NVMCTRL_CTRLB_RWS_Pos 1 /**< \brief (NVMCTRL_CTRLB) NVM Read Wait States */ +#define NVMCTRL_CTRLB_RWS_Msk (0xFu << NVMCTRL_CTRLB_RWS_Pos) +#define NVMCTRL_CTRLB_RWS(value) ((NVMCTRL_CTRLB_RWS_Msk & ((value) << NVMCTRL_CTRLB_RWS_Pos))) +#define NVMCTRL_CTRLB_RWS_SINGLE_Val 0x0u /**< \brief (NVMCTRL_CTRLB) Single Auto Wait State */ +#define NVMCTRL_CTRLB_RWS_HALF_Val 0x1u /**< \brief (NVMCTRL_CTRLB) Half Auto Wait State */ +#define NVMCTRL_CTRLB_RWS_DUAL_Val 0x2u /**< \brief (NVMCTRL_CTRLB) Dual Auto Wait State */ +#define NVMCTRL_CTRLB_RWS_SINGLE (NVMCTRL_CTRLB_RWS_SINGLE_Val << NVMCTRL_CTRLB_RWS_Pos) +#define NVMCTRL_CTRLB_RWS_HALF (NVMCTRL_CTRLB_RWS_HALF_Val << NVMCTRL_CTRLB_RWS_Pos) +#define NVMCTRL_CTRLB_RWS_DUAL (NVMCTRL_CTRLB_RWS_DUAL_Val << NVMCTRL_CTRLB_RWS_Pos) +#define NVMCTRL_CTRLB_MANW_Pos 7 /**< \brief (NVMCTRL_CTRLB) Manual Write */ +#define NVMCTRL_CTRLB_MANW (0x1u << NVMCTRL_CTRLB_MANW_Pos) +#define NVMCTRL_CTRLB_SLEEPPRM_Pos 8 /**< \brief (NVMCTRL_CTRLB) Power Reduction Mode during Sleep */ +#define NVMCTRL_CTRLB_SLEEPPRM_Msk (0x3u << NVMCTRL_CTRLB_SLEEPPRM_Pos) +#define NVMCTRL_CTRLB_SLEEPPRM(value) ((NVMCTRL_CTRLB_SLEEPPRM_Msk & ((value) << NVMCTRL_CTRLB_SLEEPPRM_Pos))) +#define NVMCTRL_CTRLB_SLEEPPRM_WAKEONACCESS_Val 0x0u /**< \brief (NVMCTRL_CTRLB) NVM block enters low-power mode when entering sleep.NVM block exits low-power mode upon first access. */ +#define NVMCTRL_CTRLB_SLEEPPRM_WAKEUPINSTANT_Val 0x1u /**< \brief (NVMCTRL_CTRLB) NVM block enters low-power mode when entering sleep.NVM block exits low-power mode when exiting sleep. */ +#define NVMCTRL_CTRLB_SLEEPPRM_DISABLED_Val 0x3u /**< \brief (NVMCTRL_CTRLB) Auto power reduction disabled. */ +#define NVMCTRL_CTRLB_SLEEPPRM_WAKEONACCESS (NVMCTRL_CTRLB_SLEEPPRM_WAKEONACCESS_Val << NVMCTRL_CTRLB_SLEEPPRM_Pos) +#define NVMCTRL_CTRLB_SLEEPPRM_WAKEUPINSTANT (NVMCTRL_CTRLB_SLEEPPRM_WAKEUPINSTANT_Val << NVMCTRL_CTRLB_SLEEPPRM_Pos) +#define NVMCTRL_CTRLB_SLEEPPRM_DISABLED (NVMCTRL_CTRLB_SLEEPPRM_DISABLED_Val << NVMCTRL_CTRLB_SLEEPPRM_Pos) +#define NVMCTRL_CTRLB_READMODE_Pos 16 /**< \brief (NVMCTRL_CTRLB) NVMCTRL Read Mode */ +#define NVMCTRL_CTRLB_READMODE_Msk (0x3u << NVMCTRL_CTRLB_READMODE_Pos) +#define NVMCTRL_CTRLB_READMODE(value) ((NVMCTRL_CTRLB_READMODE_Msk & ((value) << NVMCTRL_CTRLB_READMODE_Pos))) +#define NVMCTRL_CTRLB_READMODE_NO_MISS_PENALTY_Val 0x0u /**< \brief (NVMCTRL_CTRLB) The NVM Controller (cache system) does not insert wait states on a cache miss. Gives the best system performance. */ +#define NVMCTRL_CTRLB_READMODE_LOW_POWER_Val 0x1u /**< \brief (NVMCTRL_CTRLB) Reduces power consumption of the cache system, but inserts a wait state each time there is a cache miss. This mode may not be relevant if CPU performance is required, as the application will be stalled and may lead to increase run time. */ +#define NVMCTRL_CTRLB_READMODE_DETERMINISTIC_Val 0x2u /**< \brief (NVMCTRL_CTRLB) The cache system ensures that a cache hit or miss takes the same amount of time, determined by the number of programmed flash wait states. This mode can be used for real-time applications that require deterministic execution timings. */ +#define NVMCTRL_CTRLB_READMODE_NO_MISS_PENALTY (NVMCTRL_CTRLB_READMODE_NO_MISS_PENALTY_Val << NVMCTRL_CTRLB_READMODE_Pos) +#define NVMCTRL_CTRLB_READMODE_LOW_POWER (NVMCTRL_CTRLB_READMODE_LOW_POWER_Val << NVMCTRL_CTRLB_READMODE_Pos) +#define NVMCTRL_CTRLB_READMODE_DETERMINISTIC (NVMCTRL_CTRLB_READMODE_DETERMINISTIC_Val << NVMCTRL_CTRLB_READMODE_Pos) +#define NVMCTRL_CTRLB_CACHEDIS_Pos 18 /**< \brief (NVMCTRL_CTRLB) Cache Disable */ +#define NVMCTRL_CTRLB_CACHEDIS (0x1u << NVMCTRL_CTRLB_CACHEDIS_Pos) +#define NVMCTRL_CTRLB_MASK 0x0007039Eu /**< \brief (NVMCTRL_CTRLB) MASK Register */ + +/* -------- NVMCTRL_PARAM : (NVMCTRL Offset: 0x08) (R/W 32) NVM Parameter -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t NVMP:16; /*!< bit: 0..15 NVM Pages */ + uint32_t PSZ:3; /*!< bit: 16..18 Page Size */ + uint32_t :13; /*!< bit: 19..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} NVMCTRL_PARAM_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define NVMCTRL_PARAM_OFFSET 0x08 /**< \brief (NVMCTRL_PARAM offset) NVM Parameter */ +#define NVMCTRL_PARAM_RESETVALUE 0x00000000 /**< \brief (NVMCTRL_PARAM reset_value) NVM Parameter */ + +#define NVMCTRL_PARAM_NVMP_Pos 0 /**< \brief (NVMCTRL_PARAM) NVM Pages */ +#define NVMCTRL_PARAM_NVMP_Msk (0xFFFFu << NVMCTRL_PARAM_NVMP_Pos) +#define NVMCTRL_PARAM_NVMP(value) ((NVMCTRL_PARAM_NVMP_Msk & ((value) << NVMCTRL_PARAM_NVMP_Pos))) +#define NVMCTRL_PARAM_PSZ_Pos 16 /**< \brief (NVMCTRL_PARAM) Page Size */ +#define NVMCTRL_PARAM_PSZ_Msk (0x7u << NVMCTRL_PARAM_PSZ_Pos) +#define NVMCTRL_PARAM_PSZ(value) ((NVMCTRL_PARAM_PSZ_Msk & ((value) << NVMCTRL_PARAM_PSZ_Pos))) +#define NVMCTRL_PARAM_PSZ_8_Val 0x0u /**< \brief (NVMCTRL_PARAM) 8 bytes */ +#define NVMCTRL_PARAM_PSZ_16_Val 0x1u /**< \brief (NVMCTRL_PARAM) 16 bytes */ +#define NVMCTRL_PARAM_PSZ_32_Val 0x2u /**< \brief (NVMCTRL_PARAM) 32 bytes */ +#define NVMCTRL_PARAM_PSZ_64_Val 0x3u /**< \brief (NVMCTRL_PARAM) 64 bytes */ +#define NVMCTRL_PARAM_PSZ_128_Val 0x4u /**< \brief (NVMCTRL_PARAM) 128 bytes */ +#define NVMCTRL_PARAM_PSZ_256_Val 0x5u /**< \brief (NVMCTRL_PARAM) 256 bytes */ +#define NVMCTRL_PARAM_PSZ_512_Val 0x6u /**< \brief (NVMCTRL_PARAM) 512 bytes */ +#define NVMCTRL_PARAM_PSZ_1024_Val 0x7u /**< \brief (NVMCTRL_PARAM) 1024 bytes */ +#define NVMCTRL_PARAM_PSZ_8 (NVMCTRL_PARAM_PSZ_8_Val << NVMCTRL_PARAM_PSZ_Pos) +#define NVMCTRL_PARAM_PSZ_16 (NVMCTRL_PARAM_PSZ_16_Val << NVMCTRL_PARAM_PSZ_Pos) +#define NVMCTRL_PARAM_PSZ_32 (NVMCTRL_PARAM_PSZ_32_Val << NVMCTRL_PARAM_PSZ_Pos) +#define NVMCTRL_PARAM_PSZ_64 (NVMCTRL_PARAM_PSZ_64_Val << NVMCTRL_PARAM_PSZ_Pos) +#define NVMCTRL_PARAM_PSZ_128 (NVMCTRL_PARAM_PSZ_128_Val << NVMCTRL_PARAM_PSZ_Pos) +#define NVMCTRL_PARAM_PSZ_256 (NVMCTRL_PARAM_PSZ_256_Val << NVMCTRL_PARAM_PSZ_Pos) +#define NVMCTRL_PARAM_PSZ_512 (NVMCTRL_PARAM_PSZ_512_Val << NVMCTRL_PARAM_PSZ_Pos) +#define NVMCTRL_PARAM_PSZ_1024 (NVMCTRL_PARAM_PSZ_1024_Val << NVMCTRL_PARAM_PSZ_Pos) +#define NVMCTRL_PARAM_MASK 0x0007FFFFu /**< \brief (NVMCTRL_PARAM) MASK Register */ + +/* -------- NVMCTRL_INTENCLR : (NVMCTRL Offset: 0x0C) (R/W 8) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t READY:1; /*!< bit: 0 NVM Ready Interrupt Enable */ + uint8_t ERROR:1; /*!< bit: 1 Error Interrupt Enable */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} NVMCTRL_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define NVMCTRL_INTENCLR_OFFSET 0x0C /**< \brief (NVMCTRL_INTENCLR offset) Interrupt Enable Clear */ +#define NVMCTRL_INTENCLR_RESETVALUE 0x00 /**< \brief (NVMCTRL_INTENCLR reset_value) Interrupt Enable Clear */ + +#define NVMCTRL_INTENCLR_READY_Pos 0 /**< \brief (NVMCTRL_INTENCLR) NVM Ready Interrupt Enable */ +#define NVMCTRL_INTENCLR_READY (0x1u << NVMCTRL_INTENCLR_READY_Pos) +#define NVMCTRL_INTENCLR_ERROR_Pos 1 /**< \brief (NVMCTRL_INTENCLR) Error Interrupt Enable */ +#define NVMCTRL_INTENCLR_ERROR (0x1u << NVMCTRL_INTENCLR_ERROR_Pos) +#define NVMCTRL_INTENCLR_MASK 0x03u /**< \brief (NVMCTRL_INTENCLR) MASK Register */ + +/* -------- NVMCTRL_INTENSET : (NVMCTRL Offset: 0x10) (R/W 8) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t READY:1; /*!< bit: 0 NVM Ready Interrupt Enable */ + uint8_t ERROR:1; /*!< bit: 1 Error Interrupt Enable */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} NVMCTRL_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define NVMCTRL_INTENSET_OFFSET 0x10 /**< \brief (NVMCTRL_INTENSET offset) Interrupt Enable Set */ +#define NVMCTRL_INTENSET_RESETVALUE 0x00 /**< \brief (NVMCTRL_INTENSET reset_value) Interrupt Enable Set */ + +#define NVMCTRL_INTENSET_READY_Pos 0 /**< \brief (NVMCTRL_INTENSET) NVM Ready Interrupt Enable */ +#define NVMCTRL_INTENSET_READY (0x1u << NVMCTRL_INTENSET_READY_Pos) +#define NVMCTRL_INTENSET_ERROR_Pos 1 /**< \brief (NVMCTRL_INTENSET) Error Interrupt Enable */ +#define NVMCTRL_INTENSET_ERROR (0x1u << NVMCTRL_INTENSET_ERROR_Pos) +#define NVMCTRL_INTENSET_MASK 0x03u /**< \brief (NVMCTRL_INTENSET) MASK Register */ + +/* -------- NVMCTRL_INTFLAG : (NVMCTRL Offset: 0x14) (R/W 8) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t READY:1; /*!< bit: 0 NVM Ready */ + uint8_t ERROR:1; /*!< bit: 1 Error */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} NVMCTRL_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define NVMCTRL_INTFLAG_OFFSET 0x14 /**< \brief (NVMCTRL_INTFLAG offset) Interrupt Flag Status and Clear */ +#define NVMCTRL_INTFLAG_RESETVALUE 0x00 /**< \brief (NVMCTRL_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define NVMCTRL_INTFLAG_READY_Pos 0 /**< \brief (NVMCTRL_INTFLAG) NVM Ready */ +#define NVMCTRL_INTFLAG_READY (0x1u << NVMCTRL_INTFLAG_READY_Pos) +#define NVMCTRL_INTFLAG_ERROR_Pos 1 /**< \brief (NVMCTRL_INTFLAG) Error */ +#define NVMCTRL_INTFLAG_ERROR (0x1u << NVMCTRL_INTFLAG_ERROR_Pos) +#define NVMCTRL_INTFLAG_MASK 0x03u /**< \brief (NVMCTRL_INTFLAG) MASK Register */ + +/* -------- NVMCTRL_STATUS : (NVMCTRL Offset: 0x18) (R/W 16) Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t PRM:1; /*!< bit: 0 Power Reduction Mode */ + uint16_t LOAD:1; /*!< bit: 1 NVM Page Buffer Active Loading */ + uint16_t PROGE:1; /*!< bit: 2 Programming Error Status */ + uint16_t LOCKE:1; /*!< bit: 3 Lock Error Status */ + uint16_t NVME:1; /*!< bit: 4 NVM Error */ + uint16_t :3; /*!< bit: 5.. 7 Reserved */ + uint16_t SB:1; /*!< bit: 8 Security Bit Status */ + uint16_t :7; /*!< bit: 9..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} NVMCTRL_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define NVMCTRL_STATUS_OFFSET 0x18 /**< \brief (NVMCTRL_STATUS offset) Status */ +#define NVMCTRL_STATUS_RESETVALUE 0x0000 /**< \brief (NVMCTRL_STATUS reset_value) Status */ + +#define NVMCTRL_STATUS_PRM_Pos 0 /**< \brief (NVMCTRL_STATUS) Power Reduction Mode */ +#define NVMCTRL_STATUS_PRM (0x1u << NVMCTRL_STATUS_PRM_Pos) +#define NVMCTRL_STATUS_LOAD_Pos 1 /**< \brief (NVMCTRL_STATUS) NVM Page Buffer Active Loading */ +#define NVMCTRL_STATUS_LOAD (0x1u << NVMCTRL_STATUS_LOAD_Pos) +#define NVMCTRL_STATUS_PROGE_Pos 2 /**< \brief (NVMCTRL_STATUS) Programming Error Status */ +#define NVMCTRL_STATUS_PROGE (0x1u << NVMCTRL_STATUS_PROGE_Pos) +#define NVMCTRL_STATUS_LOCKE_Pos 3 /**< \brief (NVMCTRL_STATUS) Lock Error Status */ +#define NVMCTRL_STATUS_LOCKE (0x1u << NVMCTRL_STATUS_LOCKE_Pos) +#define NVMCTRL_STATUS_NVME_Pos 4 /**< \brief (NVMCTRL_STATUS) NVM Error */ +#define NVMCTRL_STATUS_NVME (0x1u << NVMCTRL_STATUS_NVME_Pos) +#define NVMCTRL_STATUS_SB_Pos 8 /**< \brief (NVMCTRL_STATUS) Security Bit Status */ +#define NVMCTRL_STATUS_SB (0x1u << NVMCTRL_STATUS_SB_Pos) +#define NVMCTRL_STATUS_MASK 0x011Fu /**< \brief (NVMCTRL_STATUS) MASK Register */ + +/* -------- NVMCTRL_ADDR : (NVMCTRL Offset: 0x1C) (R/W 32) Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t ADDR:22; /*!< bit: 0..21 NVM Address */ + uint32_t :10; /*!< bit: 22..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} NVMCTRL_ADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define NVMCTRL_ADDR_OFFSET 0x1C /**< \brief (NVMCTRL_ADDR offset) Address */ +#define NVMCTRL_ADDR_RESETVALUE 0x00000000 /**< \brief (NVMCTRL_ADDR reset_value) Address */ + +#define NVMCTRL_ADDR_ADDR_Pos 0 /**< \brief (NVMCTRL_ADDR) NVM Address */ +#define NVMCTRL_ADDR_ADDR_Msk (0x3FFFFFu << NVMCTRL_ADDR_ADDR_Pos) +#define NVMCTRL_ADDR_ADDR(value) ((NVMCTRL_ADDR_ADDR_Msk & ((value) << NVMCTRL_ADDR_ADDR_Pos))) +#define NVMCTRL_ADDR_MASK 0x003FFFFFu /**< \brief (NVMCTRL_ADDR) MASK Register */ + +/* -------- NVMCTRL_LOCK : (NVMCTRL Offset: 0x20) (R/W 16) Lock Section -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t LOCK:16; /*!< bit: 0..15 Region Lock Bits */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} NVMCTRL_LOCK_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define NVMCTRL_LOCK_OFFSET 0x20 /**< \brief (NVMCTRL_LOCK offset) Lock Section */ + +#define NVMCTRL_LOCK_LOCK_Pos 0 /**< \brief (NVMCTRL_LOCK) Region Lock Bits */ +#define NVMCTRL_LOCK_LOCK_Msk (0xFFFFu << NVMCTRL_LOCK_LOCK_Pos) +#define NVMCTRL_LOCK_LOCK(value) ((NVMCTRL_LOCK_LOCK_Msk & ((value) << NVMCTRL_LOCK_LOCK_Pos))) +#define NVMCTRL_LOCK_MASK 0xFFFFu /**< \brief (NVMCTRL_LOCK) MASK Register */ + +/** \brief NVMCTRL APB hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO NVMCTRL_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 16) Control A */ + RoReg8 Reserved1[0x2]; + __IO NVMCTRL_CTRLB_Type CTRLB; /**< \brief Offset: 0x04 (R/W 32) Control B */ + __IO NVMCTRL_PARAM_Type PARAM; /**< \brief Offset: 0x08 (R/W 32) NVM Parameter */ + __IO NVMCTRL_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x0C (R/W 8) Interrupt Enable Clear */ + RoReg8 Reserved2[0x3]; + __IO NVMCTRL_INTENSET_Type INTENSET; /**< \brief Offset: 0x10 (R/W 8) Interrupt Enable Set */ + RoReg8 Reserved3[0x3]; + __IO NVMCTRL_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x14 (R/W 8) Interrupt Flag Status and Clear */ + RoReg8 Reserved4[0x3]; + __IO NVMCTRL_STATUS_Type STATUS; /**< \brief Offset: 0x18 (R/W 16) Status */ + RoReg8 Reserved5[0x2]; + __IO NVMCTRL_ADDR_Type ADDR; /**< \brief Offset: 0x1C (R/W 32) Address */ + __IO NVMCTRL_LOCK_Type LOCK; /**< \brief Offset: 0x20 (R/W 16) Lock Section */ +} Nvmctrl; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +#define SECTION_NVMCTRL_CAL +#define SECTION_NVMCTRL_LOCKBIT +#define SECTION_NVMCTRL_OTP1 +#define SECTION_NVMCTRL_OTP2 +#define SECTION_NVMCTRL_OTP4 +#define SECTION_NVMCTRL_TEMP_LOG +#define SECTION_NVMCTRL_USER + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR NON-VOLATILE FUSES */ +/* ************************************************************************** */ +/** \addtogroup fuses_api Peripheral Software API */ +/*@{*/ + + +#define ADC_FUSES_BIASCAL_ADDR (NVMCTRL_OTP4 + 4) +#define ADC_FUSES_BIASCAL_Pos 3 /**< \brief (NVMCTRL_OTP4) ADC Bias Calibration */ +#define ADC_FUSES_BIASCAL_Msk (0x7u << ADC_FUSES_BIASCAL_Pos) +#define ADC_FUSES_BIASCAL(value) ((ADC_FUSES_BIASCAL_Msk & ((value) << ADC_FUSES_BIASCAL_Pos))) + +#define ADC_FUSES_LINEARITY_0_ADDR NVMCTRL_OTP4 +#define ADC_FUSES_LINEARITY_0_Pos 27 /**< \brief (NVMCTRL_OTP4) ADC Linearity bits 4:0 */ +#define ADC_FUSES_LINEARITY_0_Msk (0x1Fu << ADC_FUSES_LINEARITY_0_Pos) +#define ADC_FUSES_LINEARITY_0(value) ((ADC_FUSES_LINEARITY_0_Msk & ((value) << ADC_FUSES_LINEARITY_0_Pos))) + +#define ADC_FUSES_LINEARITY_1_ADDR (NVMCTRL_OTP4 + 4) +#define ADC_FUSES_LINEARITY_1_Pos 0 /**< \brief (NVMCTRL_OTP4) ADC Linearity bits 7:5 */ +#define ADC_FUSES_LINEARITY_1_Msk (0x7u << ADC_FUSES_LINEARITY_1_Pos) +#define ADC_FUSES_LINEARITY_1(value) ((ADC_FUSES_LINEARITY_1_Msk & ((value) << ADC_FUSES_LINEARITY_1_Pos))) + +#define NVMCTRL_FUSES_BOOTPROT_ADDR NVMCTRL_USER +#define NVMCTRL_FUSES_BOOTPROT_Pos 0 /**< \brief (NVMCTRL_USER) Bootloader Size */ +#define NVMCTRL_FUSES_BOOTPROT_Msk (0x7u << NVMCTRL_FUSES_BOOTPROT_Pos) +#define NVMCTRL_FUSES_BOOTPROT(value) ((NVMCTRL_FUSES_BOOTPROT_Msk & ((value) << NVMCTRL_FUSES_BOOTPROT_Pos))) + +#define NVMCTRL_FUSES_EEPROM_SIZE_ADDR NVMCTRL_USER +#define NVMCTRL_FUSES_EEPROM_SIZE_Pos 4 /**< \brief (NVMCTRL_USER) EEPROM Size */ +#define NVMCTRL_FUSES_EEPROM_SIZE_Msk (0x7u << NVMCTRL_FUSES_EEPROM_SIZE_Pos) +#define NVMCTRL_FUSES_EEPROM_SIZE(value) ((NVMCTRL_FUSES_EEPROM_SIZE_Msk & ((value) << NVMCTRL_FUSES_EEPROM_SIZE_Pos))) + +#define NVMCTRL_FUSES_HOT_ADC_VAL_ADDR (NVMCTRL_TEMP_LOG + 4) +#define NVMCTRL_FUSES_HOT_ADC_VAL_Pos 20 /**< \brief (NVMCTRL_TEMP_LOG) 12-bit ADC conversion at hot temperature */ +#define NVMCTRL_FUSES_HOT_ADC_VAL_Msk (0xFFFu << NVMCTRL_FUSES_HOT_ADC_VAL_Pos) +#define NVMCTRL_FUSES_HOT_ADC_VAL(value) ((NVMCTRL_FUSES_HOT_ADC_VAL_Msk & ((value) << NVMCTRL_FUSES_HOT_ADC_VAL_Pos))) + +#define NVMCTRL_FUSES_HOT_INT1V_VAL_ADDR (NVMCTRL_TEMP_LOG + 4) +#define NVMCTRL_FUSES_HOT_INT1V_VAL_Pos 0 /**< \brief (NVMCTRL_TEMP_LOG) 2's complement of the internal 1V reference drift at hot temperature (versus a 1.0 centered value) */ +#define NVMCTRL_FUSES_HOT_INT1V_VAL_Msk (0xFFu << NVMCTRL_FUSES_HOT_INT1V_VAL_Pos) +#define NVMCTRL_FUSES_HOT_INT1V_VAL(value) ((NVMCTRL_FUSES_HOT_INT1V_VAL_Msk & ((value) << NVMCTRL_FUSES_HOT_INT1V_VAL_Pos))) + +#define NVMCTRL_FUSES_HOT_TEMP_VAL_DEC_ADDR NVMCTRL_TEMP_LOG +#define NVMCTRL_FUSES_HOT_TEMP_VAL_DEC_Pos 20 /**< \brief (NVMCTRL_TEMP_LOG) Decimal part of hot temperature */ +#define NVMCTRL_FUSES_HOT_TEMP_VAL_DEC_Msk (0xFu << NVMCTRL_FUSES_HOT_TEMP_VAL_DEC_Pos) +#define NVMCTRL_FUSES_HOT_TEMP_VAL_DEC(value) ((NVMCTRL_FUSES_HOT_TEMP_VAL_DEC_Msk & ((value) << NVMCTRL_FUSES_HOT_TEMP_VAL_DEC_Pos))) + +#define NVMCTRL_FUSES_HOT_TEMP_VAL_INT_ADDR NVMCTRL_TEMP_LOG +#define NVMCTRL_FUSES_HOT_TEMP_VAL_INT_Pos 12 /**< \brief (NVMCTRL_TEMP_LOG) Integer part of hot temperature in oC */ +#define NVMCTRL_FUSES_HOT_TEMP_VAL_INT_Msk (0xFFu << NVMCTRL_FUSES_HOT_TEMP_VAL_INT_Pos) +#define NVMCTRL_FUSES_HOT_TEMP_VAL_INT(value) ((NVMCTRL_FUSES_HOT_TEMP_VAL_INT_Msk & ((value) << NVMCTRL_FUSES_HOT_TEMP_VAL_INT_Pos))) + +#define NVMCTRL_FUSES_NVMP_ADDR NVMCTRL_OTP1 +#define NVMCTRL_FUSES_NVMP_Pos 16 /**< \brief (NVMCTRL_OTP1) Number of NVM Pages */ +#define NVMCTRL_FUSES_NVMP_Msk (0xFFFFu << NVMCTRL_FUSES_NVMP_Pos) +#define NVMCTRL_FUSES_NVMP(value) ((NVMCTRL_FUSES_NVMP_Msk & ((value) << NVMCTRL_FUSES_NVMP_Pos))) + +#define NVMCTRL_FUSES_NVM_LOCK_ADDR NVMCTRL_OTP1 +#define NVMCTRL_FUSES_NVM_LOCK_Pos 0 /**< \brief (NVMCTRL_OTP1) NVM Lock */ +#define NVMCTRL_FUSES_NVM_LOCK_Msk (0xFFu << NVMCTRL_FUSES_NVM_LOCK_Pos) +#define NVMCTRL_FUSES_NVM_LOCK(value) ((NVMCTRL_FUSES_NVM_LOCK_Msk & ((value) << NVMCTRL_FUSES_NVM_LOCK_Pos))) + +#define NVMCTRL_FUSES_PSZ_ADDR NVMCTRL_OTP1 +#define NVMCTRL_FUSES_PSZ_Pos 8 /**< \brief (NVMCTRL_OTP1) NVM Page Size */ +#define NVMCTRL_FUSES_PSZ_Msk (0xFu << NVMCTRL_FUSES_PSZ_Pos) +#define NVMCTRL_FUSES_PSZ(value) ((NVMCTRL_FUSES_PSZ_Msk & ((value) << NVMCTRL_FUSES_PSZ_Pos))) + +#define NVMCTRL_FUSES_REGION_LOCKS_ADDR (NVMCTRL_USER + 4) +#define NVMCTRL_FUSES_REGION_LOCKS_Pos 16 /**< \brief (NVMCTRL_USER) NVM Region Locks */ +#define NVMCTRL_FUSES_REGION_LOCKS_Msk (0xFFFFu << NVMCTRL_FUSES_REGION_LOCKS_Pos) +#define NVMCTRL_FUSES_REGION_LOCKS(value) ((NVMCTRL_FUSES_REGION_LOCKS_Msk & ((value) << NVMCTRL_FUSES_REGION_LOCKS_Pos))) + +#define NVMCTRL_FUSES_ROOM_ADC_VAL_ADDR (NVMCTRL_TEMP_LOG + 4) +#define NVMCTRL_FUSES_ROOM_ADC_VAL_Pos 8 /**< \brief (NVMCTRL_TEMP_LOG) 12-bit ADC conversion at room temperature */ +#define NVMCTRL_FUSES_ROOM_ADC_VAL_Msk (0xFFFu << NVMCTRL_FUSES_ROOM_ADC_VAL_Pos) +#define NVMCTRL_FUSES_ROOM_ADC_VAL(value) ((NVMCTRL_FUSES_ROOM_ADC_VAL_Msk & ((value) << NVMCTRL_FUSES_ROOM_ADC_VAL_Pos))) + +#define NVMCTRL_FUSES_ROOM_INT1V_VAL_ADDR NVMCTRL_TEMP_LOG +#define NVMCTRL_FUSES_ROOM_INT1V_VAL_Pos 24 /**< \brief (NVMCTRL_TEMP_LOG) 2's complement of the internal 1V reference drift at room temperature (versus a 1.0 centered value) */ +#define NVMCTRL_FUSES_ROOM_INT1V_VAL_Msk (0xFFu << NVMCTRL_FUSES_ROOM_INT1V_VAL_Pos) +#define NVMCTRL_FUSES_ROOM_INT1V_VAL(value) ((NVMCTRL_FUSES_ROOM_INT1V_VAL_Msk & ((value) << NVMCTRL_FUSES_ROOM_INT1V_VAL_Pos))) + +#define NVMCTRL_FUSES_ROOM_TEMP_VAL_DEC_ADDR NVMCTRL_TEMP_LOG +#define NVMCTRL_FUSES_ROOM_TEMP_VAL_DEC_Pos 8 /**< \brief (NVMCTRL_TEMP_LOG) Decimal part of room temperature */ +#define NVMCTRL_FUSES_ROOM_TEMP_VAL_DEC_Msk (0xFu << NVMCTRL_FUSES_ROOM_TEMP_VAL_DEC_Pos) +#define NVMCTRL_FUSES_ROOM_TEMP_VAL_DEC(value) ((NVMCTRL_FUSES_ROOM_TEMP_VAL_DEC_Msk & ((value) << NVMCTRL_FUSES_ROOM_TEMP_VAL_DEC_Pos))) + +#define NVMCTRL_FUSES_ROOM_TEMP_VAL_INT_ADDR NVMCTRL_TEMP_LOG +#define NVMCTRL_FUSES_ROOM_TEMP_VAL_INT_Pos 0 /**< \brief (NVMCTRL_TEMP_LOG) Integer part of room temperature in oC */ +#define NVMCTRL_FUSES_ROOM_TEMP_VAL_INT_Msk (0xFFu << NVMCTRL_FUSES_ROOM_TEMP_VAL_INT_Pos) +#define NVMCTRL_FUSES_ROOM_TEMP_VAL_INT(value) ((NVMCTRL_FUSES_ROOM_TEMP_VAL_INT_Msk & ((value) << NVMCTRL_FUSES_ROOM_TEMP_VAL_INT_Pos))) + +#define SYSCTRL_FUSES_BOD33USERLEVEL_ADDR NVMCTRL_USER +#define SYSCTRL_FUSES_BOD33USERLEVEL_Pos 8 /**< \brief (NVMCTRL_USER) BOD33 User Level */ +#define SYSCTRL_FUSES_BOD33USERLEVEL_Msk (0x3Fu << SYSCTRL_FUSES_BOD33USERLEVEL_Pos) +#define SYSCTRL_FUSES_BOD33USERLEVEL(value) ((SYSCTRL_FUSES_BOD33USERLEVEL_Msk & ((value) << SYSCTRL_FUSES_BOD33USERLEVEL_Pos))) + +#define SYSCTRL_FUSES_BOD33_ACTION_ADDR NVMCTRL_USER +#define SYSCTRL_FUSES_BOD33_ACTION_Pos 15 /**< \brief (NVMCTRL_USER) BOD33 Action */ +#define SYSCTRL_FUSES_BOD33_ACTION_Msk (0x3u << SYSCTRL_FUSES_BOD33_ACTION_Pos) +#define SYSCTRL_FUSES_BOD33_ACTION(value) ((SYSCTRL_FUSES_BOD33_ACTION_Msk & ((value) << SYSCTRL_FUSES_BOD33_ACTION_Pos))) + +#define SYSCTRL_FUSES_BOD33_EN_ADDR NVMCTRL_USER +#define SYSCTRL_FUSES_BOD33_EN_Pos 14 /**< \brief (NVMCTRL_USER) BOD33 Enable */ +#define SYSCTRL_FUSES_BOD33_EN_Msk (0x1u << SYSCTRL_FUSES_BOD33_EN_Pos) + +#define SYSCTRL_FUSES_BOD33_HYST_ADDR (NVMCTRL_USER + 4) +#define SYSCTRL_FUSES_BOD33_HYST_Pos 8 /**< \brief (NVMCTRL_USER) BOD33 Hysteresis */ +#define SYSCTRL_FUSES_BOD33_HYST_Msk (0x1u << SYSCTRL_FUSES_BOD33_HYST_Pos) + +#define SYSCTRL_FUSES_DFLL48M_COARSE_CAL_ADDR (NVMCTRL_OTP4 + 4) +#define SYSCTRL_FUSES_DFLL48M_COARSE_CAL_Pos 26 /**< \brief (NVMCTRL_OTP4) DFLL48M Coarse Calibration */ +#define SYSCTRL_FUSES_DFLL48M_COARSE_CAL_Msk (0x3Fu << SYSCTRL_FUSES_DFLL48M_COARSE_CAL_Pos) +#define SYSCTRL_FUSES_DFLL48M_COARSE_CAL(value) ((SYSCTRL_FUSES_DFLL48M_COARSE_CAL_Msk & ((value) << SYSCTRL_FUSES_DFLL48M_COARSE_CAL_Pos))) + +#define SYSCTRL_FUSES_OSC32K_CAL_ADDR (NVMCTRL_OTP4 + 4) +#define SYSCTRL_FUSES_OSC32K_CAL_Pos 6 /**< \brief (NVMCTRL_OTP4) OSC32K Calibration */ +#define SYSCTRL_FUSES_OSC32K_CAL_Msk (0x7Fu << SYSCTRL_FUSES_OSC32K_CAL_Pos) +#define SYSCTRL_FUSES_OSC32K_CAL(value) ((SYSCTRL_FUSES_OSC32K_CAL_Msk & ((value) << SYSCTRL_FUSES_OSC32K_CAL_Pos))) + +#define USB_FUSES_TRANSN_ADDR (NVMCTRL_OTP4 + 4) +#define USB_FUSES_TRANSN_Pos 13 /**< \brief (NVMCTRL_OTP4) USB pad Transn calibration */ +#define USB_FUSES_TRANSN_Msk (0x1Fu << USB_FUSES_TRANSN_Pos) +#define USB_FUSES_TRANSN(value) ((USB_FUSES_TRANSN_Msk & ((value) << USB_FUSES_TRANSN_Pos))) + +#define USB_FUSES_TRANSP_ADDR (NVMCTRL_OTP4 + 4) +#define USB_FUSES_TRANSP_Pos 18 /**< \brief (NVMCTRL_OTP4) USB pad Transp calibration */ +#define USB_FUSES_TRANSP_Msk (0x1Fu << USB_FUSES_TRANSP_Pos) +#define USB_FUSES_TRANSP(value) ((USB_FUSES_TRANSP_Msk & ((value) << USB_FUSES_TRANSP_Pos))) + +#define USB_FUSES_TRIM_ADDR (NVMCTRL_OTP4 + 4) +#define USB_FUSES_TRIM_Pos 23 /**< \brief (NVMCTRL_OTP4) USB pad Trim calibration */ +#define USB_FUSES_TRIM_Msk (0x7u << USB_FUSES_TRIM_Pos) +#define USB_FUSES_TRIM(value) ((USB_FUSES_TRIM_Msk & ((value) << USB_FUSES_TRIM_Pos))) + +#define WDT_FUSES_ALWAYSON_ADDR NVMCTRL_USER +#define WDT_FUSES_ALWAYSON_Pos 26 /**< \brief (NVMCTRL_USER) WDT Always On */ +#define WDT_FUSES_ALWAYSON_Msk (0x1u << WDT_FUSES_ALWAYSON_Pos) + +#define WDT_FUSES_ENABLE_ADDR NVMCTRL_USER +#define WDT_FUSES_ENABLE_Pos 25 /**< \brief (NVMCTRL_USER) WDT Enable */ +#define WDT_FUSES_ENABLE_Msk (0x1u << WDT_FUSES_ENABLE_Pos) + +#define WDT_FUSES_EWOFFSET_ADDR (NVMCTRL_USER + 4) +#define WDT_FUSES_EWOFFSET_Pos 3 /**< \brief (NVMCTRL_USER) WDT Early Warning Offset */ +#define WDT_FUSES_EWOFFSET_Msk (0xFu << WDT_FUSES_EWOFFSET_Pos) +#define WDT_FUSES_EWOFFSET(value) ((WDT_FUSES_EWOFFSET_Msk & ((value) << WDT_FUSES_EWOFFSET_Pos))) + +#define WDT_FUSES_PER_ADDR NVMCTRL_USER +#define WDT_FUSES_PER_Pos 27 /**< \brief (NVMCTRL_USER) WDT Period */ +#define WDT_FUSES_PER_Msk (0xFu << WDT_FUSES_PER_Pos) +#define WDT_FUSES_PER(value) ((WDT_FUSES_PER_Msk & ((value) << WDT_FUSES_PER_Pos))) + +#define WDT_FUSES_WEN_ADDR (NVMCTRL_USER + 4) +#define WDT_FUSES_WEN_Pos 7 /**< \brief (NVMCTRL_USER) WDT Window Mode Enable */ +#define WDT_FUSES_WEN_Msk (0x1u << WDT_FUSES_WEN_Pos) + +#define WDT_FUSES_WINDOW_0_ADDR NVMCTRL_USER +#define WDT_FUSES_WINDOW_0_Pos 31 /**< \brief (NVMCTRL_USER) WDT Window bit 0 */ +#define WDT_FUSES_WINDOW_0_Msk (0x1u << WDT_FUSES_WINDOW_0_Pos) + +#define WDT_FUSES_WINDOW_1_ADDR (NVMCTRL_USER + 4) +#define WDT_FUSES_WINDOW_1_Pos 0 /**< \brief (NVMCTRL_USER) WDT Window bits 3:1 */ +#define WDT_FUSES_WINDOW_1_Msk (0x7u << WDT_FUSES_WINDOW_1_Pos) +#define WDT_FUSES_WINDOW_1(value) ((WDT_FUSES_WINDOW_1_Msk & ((value) << WDT_FUSES_WINDOW_1_Pos))) + +/*@}*/ + +#endif /* _SAMD21_NVMCTRL_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/pac.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/pac.h new file mode 100755 index 0000000..e175508 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/pac.h @@ -0,0 +1,104 @@ +/** + * \file + * + * \brief Component description for PAC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_PAC_COMPONENT_ +#define _SAMD21_PAC_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR PAC */ +/* ========================================================================== */ +/** \addtogroup SAMD21_PAC Peripheral Access Controller */ +/*@{*/ + +#define PAC_U2211 +#define REV_PAC 0x101 + +/* -------- PAC_WPCLR : (PAC Offset: 0x0) (R/W 32) Write Protection Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :1; /*!< bit: 0 Reserved */ + uint32_t WP:31; /*!< bit: 1..31 Write Protection Clear */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PAC_WPCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PAC_WPCLR_OFFSET 0x0 /**< \brief (PAC_WPCLR offset) Write Protection Clear */ +#define PAC_WPCLR_RESETVALUE 0x00000000 /**< \brief (PAC_WPCLR reset_value) Write Protection Clear */ + +#define PAC_WPCLR_WP_Pos 1 /**< \brief (PAC_WPCLR) Write Protection Clear */ +#define PAC_WPCLR_WP_Msk (0x7FFFFFFFu << PAC_WPCLR_WP_Pos) +#define PAC_WPCLR_WP(value) ((PAC_WPCLR_WP_Msk & ((value) << PAC_WPCLR_WP_Pos))) +#define PAC_WPCLR_MASK 0xFFFFFFFEu /**< \brief (PAC_WPCLR) MASK Register */ + +/* -------- PAC_WPSET : (PAC Offset: 0x4) (R/W 32) Write Protection Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :1; /*!< bit: 0 Reserved */ + uint32_t WP:31; /*!< bit: 1..31 Write Protection Set */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PAC_WPSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PAC_WPSET_OFFSET 0x4 /**< \brief (PAC_WPSET offset) Write Protection Set */ +#define PAC_WPSET_RESETVALUE 0x00000000 /**< \brief (PAC_WPSET reset_value) Write Protection Set */ + +#define PAC_WPSET_WP_Pos 1 /**< \brief (PAC_WPSET) Write Protection Set */ +#define PAC_WPSET_WP_Msk (0x7FFFFFFFu << PAC_WPSET_WP_Pos) +#define PAC_WPSET_WP(value) ((PAC_WPSET_WP_Msk & ((value) << PAC_WPSET_WP_Pos))) +#define PAC_WPSET_MASK 0xFFFFFFFEu /**< \brief (PAC_WPSET) MASK Register */ + +/** \brief PAC hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO PAC_WPCLR_Type WPCLR; /**< \brief Offset: 0x0 (R/W 32) Write Protection Clear */ + __IO PAC_WPSET_Type WPSET; /**< \brief Offset: 0x4 (R/W 32) Write Protection Set */ +} Pac; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_PAC_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/pm.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/pm.h new file mode 100755 index 0000000..055d49c --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/pm.h @@ -0,0 +1,530 @@ +/** + * \file + * + * \brief Component description for PM + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_PM_COMPONENT_ +#define _SAMD21_PM_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR PM */ +/* ========================================================================== */ +/** \addtogroup SAMD21_PM Power Manager */ +/*@{*/ + +#define PM_U2206 +#define REV_PM 0x201 + +/* -------- PM_CTRL : (PM Offset: 0x00) (R/W 8) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + uint8_t reg; /*!< Type used for register access */ +} PM_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_CTRL_OFFSET 0x00 /**< \brief (PM_CTRL offset) Control */ +#define PM_CTRL_RESETVALUE 0x00 /**< \brief (PM_CTRL reset_value) Control */ + +#define PM_CTRL_MASK 0x00u /**< \brief (PM_CTRL) MASK Register */ + +/* -------- PM_SLEEP : (PM Offset: 0x01) (R/W 8) Sleep Mode -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t IDLE:2; /*!< bit: 0.. 1 Idle Mode Configuration */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PM_SLEEP_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_SLEEP_OFFSET 0x01 /**< \brief (PM_SLEEP offset) Sleep Mode */ +#define PM_SLEEP_RESETVALUE 0x00 /**< \brief (PM_SLEEP reset_value) Sleep Mode */ + +#define PM_SLEEP_IDLE_Pos 0 /**< \brief (PM_SLEEP) Idle Mode Configuration */ +#define PM_SLEEP_IDLE_Msk (0x3u << PM_SLEEP_IDLE_Pos) +#define PM_SLEEP_IDLE(value) ((PM_SLEEP_IDLE_Msk & ((value) << PM_SLEEP_IDLE_Pos))) +#define PM_SLEEP_IDLE_CPU_Val 0x0u /**< \brief (PM_SLEEP) The CPU clock domain is stopped */ +#define PM_SLEEP_IDLE_AHB_Val 0x1u /**< \brief (PM_SLEEP) The CPU and AHB clock domains are stopped */ +#define PM_SLEEP_IDLE_APB_Val 0x2u /**< \brief (PM_SLEEP) The CPU, AHB and APB clock domains are stopped */ +#define PM_SLEEP_IDLE_CPU (PM_SLEEP_IDLE_CPU_Val << PM_SLEEP_IDLE_Pos) +#define PM_SLEEP_IDLE_AHB (PM_SLEEP_IDLE_AHB_Val << PM_SLEEP_IDLE_Pos) +#define PM_SLEEP_IDLE_APB (PM_SLEEP_IDLE_APB_Val << PM_SLEEP_IDLE_Pos) +#define PM_SLEEP_MASK 0x03u /**< \brief (PM_SLEEP) MASK Register */ + +/* -------- PM_CPUSEL : (PM Offset: 0x08) (R/W 8) CPU Clock Select -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CPUDIV:3; /*!< bit: 0.. 2 CPU Prescaler Selection */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PM_CPUSEL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_CPUSEL_OFFSET 0x08 /**< \brief (PM_CPUSEL offset) CPU Clock Select */ +#define PM_CPUSEL_RESETVALUE 0x00 /**< \brief (PM_CPUSEL reset_value) CPU Clock Select */ + +#define PM_CPUSEL_CPUDIV_Pos 0 /**< \brief (PM_CPUSEL) CPU Prescaler Selection */ +#define PM_CPUSEL_CPUDIV_Msk (0x7u << PM_CPUSEL_CPUDIV_Pos) +#define PM_CPUSEL_CPUDIV(value) ((PM_CPUSEL_CPUDIV_Msk & ((value) << PM_CPUSEL_CPUDIV_Pos))) +#define PM_CPUSEL_CPUDIV_DIV1_Val 0x0u /**< \brief (PM_CPUSEL) Divide by 1 */ +#define PM_CPUSEL_CPUDIV_DIV2_Val 0x1u /**< \brief (PM_CPUSEL) Divide by 2 */ +#define PM_CPUSEL_CPUDIV_DIV4_Val 0x2u /**< \brief (PM_CPUSEL) Divide by 4 */ +#define PM_CPUSEL_CPUDIV_DIV8_Val 0x3u /**< \brief (PM_CPUSEL) Divide by 8 */ +#define PM_CPUSEL_CPUDIV_DIV16_Val 0x4u /**< \brief (PM_CPUSEL) Divide by 16 */ +#define PM_CPUSEL_CPUDIV_DIV32_Val 0x5u /**< \brief (PM_CPUSEL) Divide by 32 */ +#define PM_CPUSEL_CPUDIV_DIV64_Val 0x6u /**< \brief (PM_CPUSEL) Divide by 64 */ +#define PM_CPUSEL_CPUDIV_DIV128_Val 0x7u /**< \brief (PM_CPUSEL) Divide by 128 */ +#define PM_CPUSEL_CPUDIV_DIV1 (PM_CPUSEL_CPUDIV_DIV1_Val << PM_CPUSEL_CPUDIV_Pos) +#define PM_CPUSEL_CPUDIV_DIV2 (PM_CPUSEL_CPUDIV_DIV2_Val << PM_CPUSEL_CPUDIV_Pos) +#define PM_CPUSEL_CPUDIV_DIV4 (PM_CPUSEL_CPUDIV_DIV4_Val << PM_CPUSEL_CPUDIV_Pos) +#define PM_CPUSEL_CPUDIV_DIV8 (PM_CPUSEL_CPUDIV_DIV8_Val << PM_CPUSEL_CPUDIV_Pos) +#define PM_CPUSEL_CPUDIV_DIV16 (PM_CPUSEL_CPUDIV_DIV16_Val << PM_CPUSEL_CPUDIV_Pos) +#define PM_CPUSEL_CPUDIV_DIV32 (PM_CPUSEL_CPUDIV_DIV32_Val << PM_CPUSEL_CPUDIV_Pos) +#define PM_CPUSEL_CPUDIV_DIV64 (PM_CPUSEL_CPUDIV_DIV64_Val << PM_CPUSEL_CPUDIV_Pos) +#define PM_CPUSEL_CPUDIV_DIV128 (PM_CPUSEL_CPUDIV_DIV128_Val << PM_CPUSEL_CPUDIV_Pos) +#define PM_CPUSEL_MASK 0x07u /**< \brief (PM_CPUSEL) MASK Register */ + +/* -------- PM_APBASEL : (PM Offset: 0x09) (R/W 8) APBA Clock Select -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t APBADIV:3; /*!< bit: 0.. 2 APBA Prescaler Selection */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PM_APBASEL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_APBASEL_OFFSET 0x09 /**< \brief (PM_APBASEL offset) APBA Clock Select */ +#define PM_APBASEL_RESETVALUE 0x00 /**< \brief (PM_APBASEL reset_value) APBA Clock Select */ + +#define PM_APBASEL_APBADIV_Pos 0 /**< \brief (PM_APBASEL) APBA Prescaler Selection */ +#define PM_APBASEL_APBADIV_Msk (0x7u << PM_APBASEL_APBADIV_Pos) +#define PM_APBASEL_APBADIV(value) ((PM_APBASEL_APBADIV_Msk & ((value) << PM_APBASEL_APBADIV_Pos))) +#define PM_APBASEL_APBADIV_DIV1_Val 0x0u /**< \brief (PM_APBASEL) Divide by 1 */ +#define PM_APBASEL_APBADIV_DIV2_Val 0x1u /**< \brief (PM_APBASEL) Divide by 2 */ +#define PM_APBASEL_APBADIV_DIV4_Val 0x2u /**< \brief (PM_APBASEL) Divide by 4 */ +#define PM_APBASEL_APBADIV_DIV8_Val 0x3u /**< \brief (PM_APBASEL) Divide by 8 */ +#define PM_APBASEL_APBADIV_DIV16_Val 0x4u /**< \brief (PM_APBASEL) Divide by 16 */ +#define PM_APBASEL_APBADIV_DIV32_Val 0x5u /**< \brief (PM_APBASEL) Divide by 32 */ +#define PM_APBASEL_APBADIV_DIV64_Val 0x6u /**< \brief (PM_APBASEL) Divide by 64 */ +#define PM_APBASEL_APBADIV_DIV128_Val 0x7u /**< \brief (PM_APBASEL) Divide by 128 */ +#define PM_APBASEL_APBADIV_DIV1 (PM_APBASEL_APBADIV_DIV1_Val << PM_APBASEL_APBADIV_Pos) +#define PM_APBASEL_APBADIV_DIV2 (PM_APBASEL_APBADIV_DIV2_Val << PM_APBASEL_APBADIV_Pos) +#define PM_APBASEL_APBADIV_DIV4 (PM_APBASEL_APBADIV_DIV4_Val << PM_APBASEL_APBADIV_Pos) +#define PM_APBASEL_APBADIV_DIV8 (PM_APBASEL_APBADIV_DIV8_Val << PM_APBASEL_APBADIV_Pos) +#define PM_APBASEL_APBADIV_DIV16 (PM_APBASEL_APBADIV_DIV16_Val << PM_APBASEL_APBADIV_Pos) +#define PM_APBASEL_APBADIV_DIV32 (PM_APBASEL_APBADIV_DIV32_Val << PM_APBASEL_APBADIV_Pos) +#define PM_APBASEL_APBADIV_DIV64 (PM_APBASEL_APBADIV_DIV64_Val << PM_APBASEL_APBADIV_Pos) +#define PM_APBASEL_APBADIV_DIV128 (PM_APBASEL_APBADIV_DIV128_Val << PM_APBASEL_APBADIV_Pos) +#define PM_APBASEL_MASK 0x07u /**< \brief (PM_APBASEL) MASK Register */ + +/* -------- PM_APBBSEL : (PM Offset: 0x0A) (R/W 8) APBB Clock Select -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t APBBDIV:3; /*!< bit: 0.. 2 APBB Prescaler Selection */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PM_APBBSEL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_APBBSEL_OFFSET 0x0A /**< \brief (PM_APBBSEL offset) APBB Clock Select */ +#define PM_APBBSEL_RESETVALUE 0x00 /**< \brief (PM_APBBSEL reset_value) APBB Clock Select */ + +#define PM_APBBSEL_APBBDIV_Pos 0 /**< \brief (PM_APBBSEL) APBB Prescaler Selection */ +#define PM_APBBSEL_APBBDIV_Msk (0x7u << PM_APBBSEL_APBBDIV_Pos) +#define PM_APBBSEL_APBBDIV(value) ((PM_APBBSEL_APBBDIV_Msk & ((value) << PM_APBBSEL_APBBDIV_Pos))) +#define PM_APBBSEL_APBBDIV_DIV1_Val 0x0u /**< \brief (PM_APBBSEL) Divide by 1 */ +#define PM_APBBSEL_APBBDIV_DIV2_Val 0x1u /**< \brief (PM_APBBSEL) Divide by 2 */ +#define PM_APBBSEL_APBBDIV_DIV4_Val 0x2u /**< \brief (PM_APBBSEL) Divide by 4 */ +#define PM_APBBSEL_APBBDIV_DIV8_Val 0x3u /**< \brief (PM_APBBSEL) Divide by 8 */ +#define PM_APBBSEL_APBBDIV_DIV16_Val 0x4u /**< \brief (PM_APBBSEL) Divide by 16 */ +#define PM_APBBSEL_APBBDIV_DIV32_Val 0x5u /**< \brief (PM_APBBSEL) Divide by 32 */ +#define PM_APBBSEL_APBBDIV_DIV64_Val 0x6u /**< \brief (PM_APBBSEL) Divide by 64 */ +#define PM_APBBSEL_APBBDIV_DIV128_Val 0x7u /**< \brief (PM_APBBSEL) Divide by 128 */ +#define PM_APBBSEL_APBBDIV_DIV1 (PM_APBBSEL_APBBDIV_DIV1_Val << PM_APBBSEL_APBBDIV_Pos) +#define PM_APBBSEL_APBBDIV_DIV2 (PM_APBBSEL_APBBDIV_DIV2_Val << PM_APBBSEL_APBBDIV_Pos) +#define PM_APBBSEL_APBBDIV_DIV4 (PM_APBBSEL_APBBDIV_DIV4_Val << PM_APBBSEL_APBBDIV_Pos) +#define PM_APBBSEL_APBBDIV_DIV8 (PM_APBBSEL_APBBDIV_DIV8_Val << PM_APBBSEL_APBBDIV_Pos) +#define PM_APBBSEL_APBBDIV_DIV16 (PM_APBBSEL_APBBDIV_DIV16_Val << PM_APBBSEL_APBBDIV_Pos) +#define PM_APBBSEL_APBBDIV_DIV32 (PM_APBBSEL_APBBDIV_DIV32_Val << PM_APBBSEL_APBBDIV_Pos) +#define PM_APBBSEL_APBBDIV_DIV64 (PM_APBBSEL_APBBDIV_DIV64_Val << PM_APBBSEL_APBBDIV_Pos) +#define PM_APBBSEL_APBBDIV_DIV128 (PM_APBBSEL_APBBDIV_DIV128_Val << PM_APBBSEL_APBBDIV_Pos) +#define PM_APBBSEL_MASK 0x07u /**< \brief (PM_APBBSEL) MASK Register */ + +/* -------- PM_APBCSEL : (PM Offset: 0x0B) (R/W 8) APBC Clock Select -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t APBCDIV:3; /*!< bit: 0.. 2 APBC Prescaler Selection */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PM_APBCSEL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_APBCSEL_OFFSET 0x0B /**< \brief (PM_APBCSEL offset) APBC Clock Select */ +#define PM_APBCSEL_RESETVALUE 0x00 /**< \brief (PM_APBCSEL reset_value) APBC Clock Select */ + +#define PM_APBCSEL_APBCDIV_Pos 0 /**< \brief (PM_APBCSEL) APBC Prescaler Selection */ +#define PM_APBCSEL_APBCDIV_Msk (0x7u << PM_APBCSEL_APBCDIV_Pos) +#define PM_APBCSEL_APBCDIV(value) ((PM_APBCSEL_APBCDIV_Msk & ((value) << PM_APBCSEL_APBCDIV_Pos))) +#define PM_APBCSEL_APBCDIV_DIV1_Val 0x0u /**< \brief (PM_APBCSEL) Divide by 1 */ +#define PM_APBCSEL_APBCDIV_DIV2_Val 0x1u /**< \brief (PM_APBCSEL) Divide by 2 */ +#define PM_APBCSEL_APBCDIV_DIV4_Val 0x2u /**< \brief (PM_APBCSEL) Divide by 4 */ +#define PM_APBCSEL_APBCDIV_DIV8_Val 0x3u /**< \brief (PM_APBCSEL) Divide by 8 */ +#define PM_APBCSEL_APBCDIV_DIV16_Val 0x4u /**< \brief (PM_APBCSEL) Divide by 16 */ +#define PM_APBCSEL_APBCDIV_DIV32_Val 0x5u /**< \brief (PM_APBCSEL) Divide by 32 */ +#define PM_APBCSEL_APBCDIV_DIV64_Val 0x6u /**< \brief (PM_APBCSEL) Divide by 64 */ +#define PM_APBCSEL_APBCDIV_DIV128_Val 0x7u /**< \brief (PM_APBCSEL) Divide by 128 */ +#define PM_APBCSEL_APBCDIV_DIV1 (PM_APBCSEL_APBCDIV_DIV1_Val << PM_APBCSEL_APBCDIV_Pos) +#define PM_APBCSEL_APBCDIV_DIV2 (PM_APBCSEL_APBCDIV_DIV2_Val << PM_APBCSEL_APBCDIV_Pos) +#define PM_APBCSEL_APBCDIV_DIV4 (PM_APBCSEL_APBCDIV_DIV4_Val << PM_APBCSEL_APBCDIV_Pos) +#define PM_APBCSEL_APBCDIV_DIV8 (PM_APBCSEL_APBCDIV_DIV8_Val << PM_APBCSEL_APBCDIV_Pos) +#define PM_APBCSEL_APBCDIV_DIV16 (PM_APBCSEL_APBCDIV_DIV16_Val << PM_APBCSEL_APBCDIV_Pos) +#define PM_APBCSEL_APBCDIV_DIV32 (PM_APBCSEL_APBCDIV_DIV32_Val << PM_APBCSEL_APBCDIV_Pos) +#define PM_APBCSEL_APBCDIV_DIV64 (PM_APBCSEL_APBCDIV_DIV64_Val << PM_APBCSEL_APBCDIV_Pos) +#define PM_APBCSEL_APBCDIV_DIV128 (PM_APBCSEL_APBCDIV_DIV128_Val << PM_APBCSEL_APBCDIV_Pos) +#define PM_APBCSEL_MASK 0x07u /**< \brief (PM_APBCSEL) MASK Register */ + +/* -------- PM_AHBMASK : (PM Offset: 0x14) (R/W 32) AHB Mask -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t HPB0:1; /*!< bit: 0 HPB0 AHB Clock Mask */ + uint32_t HPB1:1; /*!< bit: 1 HPB1 AHB Clock Mask */ + uint32_t HPB2:1; /*!< bit: 2 HPB2 AHB Clock Mask */ + uint32_t DSU:1; /*!< bit: 3 DSU AHB Clock Mask */ + uint32_t NVMCTRL:1; /*!< bit: 4 NVMCTRL AHB Clock Mask */ + uint32_t DMAC:1; /*!< bit: 5 DMAC AHB Clock Mask */ + uint32_t USB:1; /*!< bit: 6 USB AHB Clock Mask */ + uint32_t :25; /*!< bit: 7..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PM_AHBMASK_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_AHBMASK_OFFSET 0x14 /**< \brief (PM_AHBMASK offset) AHB Mask */ +#define PM_AHBMASK_RESETVALUE 0x0000007F /**< \brief (PM_AHBMASK reset_value) AHB Mask */ + +#define PM_AHBMASK_HPB0_Pos 0 /**< \brief (PM_AHBMASK) HPB0 AHB Clock Mask */ +#define PM_AHBMASK_HPB0 (0x1u << PM_AHBMASK_HPB0_Pos) +#define PM_AHBMASK_HPB1_Pos 1 /**< \brief (PM_AHBMASK) HPB1 AHB Clock Mask */ +#define PM_AHBMASK_HPB1 (0x1u << PM_AHBMASK_HPB1_Pos) +#define PM_AHBMASK_HPB2_Pos 2 /**< \brief (PM_AHBMASK) HPB2 AHB Clock Mask */ +#define PM_AHBMASK_HPB2 (0x1u << PM_AHBMASK_HPB2_Pos) +#define PM_AHBMASK_DSU_Pos 3 /**< \brief (PM_AHBMASK) DSU AHB Clock Mask */ +#define PM_AHBMASK_DSU (0x1u << PM_AHBMASK_DSU_Pos) +#define PM_AHBMASK_NVMCTRL_Pos 4 /**< \brief (PM_AHBMASK) NVMCTRL AHB Clock Mask */ +#define PM_AHBMASK_NVMCTRL (0x1u << PM_AHBMASK_NVMCTRL_Pos) +#define PM_AHBMASK_DMAC_Pos 5 /**< \brief (PM_AHBMASK) DMAC AHB Clock Mask */ +#define PM_AHBMASK_DMAC (0x1u << PM_AHBMASK_DMAC_Pos) +#define PM_AHBMASK_USB_Pos 6 /**< \brief (PM_AHBMASK) USB AHB Clock Mask */ +#define PM_AHBMASK_USB (0x1u << PM_AHBMASK_USB_Pos) +#define PM_AHBMASK_MASK 0x0000007Fu /**< \brief (PM_AHBMASK) MASK Register */ + +/* -------- PM_APBAMASK : (PM Offset: 0x18) (R/W 32) APBA Mask -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PAC0:1; /*!< bit: 0 PAC0 APB Clock Enable */ + uint32_t PM:1; /*!< bit: 1 PM APB Clock Enable */ + uint32_t SYSCTRL:1; /*!< bit: 2 SYSCTRL APB Clock Enable */ + uint32_t GCLK:1; /*!< bit: 3 GCLK APB Clock Enable */ + uint32_t WDT:1; /*!< bit: 4 WDT APB Clock Enable */ + uint32_t RTC:1; /*!< bit: 5 RTC APB Clock Enable */ + uint32_t EIC:1; /*!< bit: 6 EIC APB Clock Enable */ + uint32_t :25; /*!< bit: 7..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PM_APBAMASK_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_APBAMASK_OFFSET 0x18 /**< \brief (PM_APBAMASK offset) APBA Mask */ +#define PM_APBAMASK_RESETVALUE 0x0000007F /**< \brief (PM_APBAMASK reset_value) APBA Mask */ + +#define PM_APBAMASK_PAC0_Pos 0 /**< \brief (PM_APBAMASK) PAC0 APB Clock Enable */ +#define PM_APBAMASK_PAC0 (0x1u << PM_APBAMASK_PAC0_Pos) +#define PM_APBAMASK_PM_Pos 1 /**< \brief (PM_APBAMASK) PM APB Clock Enable */ +#define PM_APBAMASK_PM (0x1u << PM_APBAMASK_PM_Pos) +#define PM_APBAMASK_SYSCTRL_Pos 2 /**< \brief (PM_APBAMASK) SYSCTRL APB Clock Enable */ +#define PM_APBAMASK_SYSCTRL (0x1u << PM_APBAMASK_SYSCTRL_Pos) +#define PM_APBAMASK_GCLK_Pos 3 /**< \brief (PM_APBAMASK) GCLK APB Clock Enable */ +#define PM_APBAMASK_GCLK (0x1u << PM_APBAMASK_GCLK_Pos) +#define PM_APBAMASK_WDT_Pos 4 /**< \brief (PM_APBAMASK) WDT APB Clock Enable */ +#define PM_APBAMASK_WDT (0x1u << PM_APBAMASK_WDT_Pos) +#define PM_APBAMASK_RTC_Pos 5 /**< \brief (PM_APBAMASK) RTC APB Clock Enable */ +#define PM_APBAMASK_RTC (0x1u << PM_APBAMASK_RTC_Pos) +#define PM_APBAMASK_EIC_Pos 6 /**< \brief (PM_APBAMASK) EIC APB Clock Enable */ +#define PM_APBAMASK_EIC (0x1u << PM_APBAMASK_EIC_Pos) +#define PM_APBAMASK_MASK 0x0000007Fu /**< \brief (PM_APBAMASK) MASK Register */ + +/* -------- PM_APBBMASK : (PM Offset: 0x1C) (R/W 32) APBB Mask -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PAC1:1; /*!< bit: 0 PAC1 APB Clock Enable */ + uint32_t DSU:1; /*!< bit: 1 DSU APB Clock Enable */ + uint32_t NVMCTRL:1; /*!< bit: 2 NVMCTRL APB Clock Enable */ + uint32_t PORT:1; /*!< bit: 3 PORT APB Clock Enable */ + uint32_t DMAC:1; /*!< bit: 4 DMAC APB Clock Enable */ + uint32_t USB:1; /*!< bit: 5 USB APB Clock Enable */ + uint32_t :26; /*!< bit: 6..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PM_APBBMASK_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_APBBMASK_OFFSET 0x1C /**< \brief (PM_APBBMASK offset) APBB Mask */ +#define PM_APBBMASK_RESETVALUE 0x0000007F /**< \brief (PM_APBBMASK reset_value) APBB Mask */ + +#define PM_APBBMASK_PAC1_Pos 0 /**< \brief (PM_APBBMASK) PAC1 APB Clock Enable */ +#define PM_APBBMASK_PAC1 (0x1u << PM_APBBMASK_PAC1_Pos) +#define PM_APBBMASK_DSU_Pos 1 /**< \brief (PM_APBBMASK) DSU APB Clock Enable */ +#define PM_APBBMASK_DSU (0x1u << PM_APBBMASK_DSU_Pos) +#define PM_APBBMASK_NVMCTRL_Pos 2 /**< \brief (PM_APBBMASK) NVMCTRL APB Clock Enable */ +#define PM_APBBMASK_NVMCTRL (0x1u << PM_APBBMASK_NVMCTRL_Pos) +#define PM_APBBMASK_PORT_Pos 3 /**< \brief (PM_APBBMASK) PORT APB Clock Enable */ +#define PM_APBBMASK_PORT (0x1u << PM_APBBMASK_PORT_Pos) +#define PM_APBBMASK_DMAC_Pos 4 /**< \brief (PM_APBBMASK) DMAC APB Clock Enable */ +#define PM_APBBMASK_DMAC (0x1u << PM_APBBMASK_DMAC_Pos) +#define PM_APBBMASK_USB_Pos 5 /**< \brief (PM_APBBMASK) USB APB Clock Enable */ +#define PM_APBBMASK_USB (0x1u << PM_APBBMASK_USB_Pos) +#define PM_APBBMASK_MASK 0x0000003Fu /**< \brief (PM_APBBMASK) MASK Register */ + +/* -------- PM_APBCMASK : (PM Offset: 0x20) (R/W 32) APBC Mask -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PAC2:1; /*!< bit: 0 PAC2 APB Clock Enable */ + uint32_t EVSYS:1; /*!< bit: 1 EVSYS APB Clock Enable */ + uint32_t SERCOM0:1; /*!< bit: 2 SERCOM0 APB Clock Enable */ + uint32_t SERCOM1:1; /*!< bit: 3 SERCOM1 APB Clock Enable */ + uint32_t SERCOM2:1; /*!< bit: 4 SERCOM2 APB Clock Enable */ + uint32_t SERCOM3:1; /*!< bit: 5 SERCOM3 APB Clock Enable */ + uint32_t SERCOM4:1; /*!< bit: 6 SERCOM4 APB Clock Enable */ + uint32_t SERCOM5:1; /*!< bit: 7 SERCOM5 APB Clock Enable */ + uint32_t TCC0:1; /*!< bit: 8 TCC0 APB Clock Enable */ + uint32_t TCC1:1; /*!< bit: 9 TCC1 APB Clock Enable */ + uint32_t TCC2:1; /*!< bit: 10 TCC2 APB Clock Enable */ + uint32_t TC3:1; /*!< bit: 11 TC3 APB Clock Enable */ + uint32_t TC4:1; /*!< bit: 12 TC4 APB Clock Enable */ + uint32_t TC5:1; /*!< bit: 13 TC5 APB Clock Enable */ + uint32_t TC6:1; /*!< bit: 14 TC6 APB Clock Enable */ + uint32_t TC7:1; /*!< bit: 15 TC7 APB Clock Enable */ + uint32_t ADC:1; /*!< bit: 16 ADC APB Clock Enable */ + uint32_t AC:1; /*!< bit: 17 AC APB Clock Enable */ + uint32_t DAC:1; /*!< bit: 18 DAC APB Clock Enable */ + uint32_t PTC:1; /*!< bit: 19 PTC APB Clock Enable */ + uint32_t I2S:1; /*!< bit: 20 I2S APB Clock Enable */ + uint32_t :11; /*!< bit: 21..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PM_APBCMASK_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_APBCMASK_OFFSET 0x20 /**< \brief (PM_APBCMASK offset) APBC Mask */ +#define PM_APBCMASK_RESETVALUE 0x00010000 /**< \brief (PM_APBCMASK reset_value) APBC Mask */ + +#define PM_APBCMASK_PAC2_Pos 0 /**< \brief (PM_APBCMASK) PAC2 APB Clock Enable */ +#define PM_APBCMASK_PAC2 (0x1u << PM_APBCMASK_PAC2_Pos) +#define PM_APBCMASK_EVSYS_Pos 1 /**< \brief (PM_APBCMASK) EVSYS APB Clock Enable */ +#define PM_APBCMASK_EVSYS (0x1u << PM_APBCMASK_EVSYS_Pos) +#define PM_APBCMASK_SERCOM0_Pos 2 /**< \brief (PM_APBCMASK) SERCOM0 APB Clock Enable */ +#define PM_APBCMASK_SERCOM0 (0x1u << PM_APBCMASK_SERCOM0_Pos) +#define PM_APBCMASK_SERCOM1_Pos 3 /**< \brief (PM_APBCMASK) SERCOM1 APB Clock Enable */ +#define PM_APBCMASK_SERCOM1 (0x1u << PM_APBCMASK_SERCOM1_Pos) +#define PM_APBCMASK_SERCOM2_Pos 4 /**< \brief (PM_APBCMASK) SERCOM2 APB Clock Enable */ +#define PM_APBCMASK_SERCOM2 (0x1u << PM_APBCMASK_SERCOM2_Pos) +#define PM_APBCMASK_SERCOM3_Pos 5 /**< \brief (PM_APBCMASK) SERCOM3 APB Clock Enable */ +#define PM_APBCMASK_SERCOM3 (0x1u << PM_APBCMASK_SERCOM3_Pos) +#define PM_APBCMASK_SERCOM4_Pos 6 /**< \brief (PM_APBCMASK) SERCOM4 APB Clock Enable */ +#define PM_APBCMASK_SERCOM4 (0x1u << PM_APBCMASK_SERCOM4_Pos) +#define PM_APBCMASK_SERCOM5_Pos 7 /**< \brief (PM_APBCMASK) SERCOM5 APB Clock Enable */ +#define PM_APBCMASK_SERCOM5 (0x1u << PM_APBCMASK_SERCOM5_Pos) +#define PM_APBCMASK_TCC0_Pos 8 /**< \brief (PM_APBCMASK) TCC0 APB Clock Enable */ +#define PM_APBCMASK_TCC0 (0x1u << PM_APBCMASK_TCC0_Pos) +#define PM_APBCMASK_TCC1_Pos 9 /**< \brief (PM_APBCMASK) TCC1 APB Clock Enable */ +#define PM_APBCMASK_TCC1 (0x1u << PM_APBCMASK_TCC1_Pos) +#define PM_APBCMASK_TCC2_Pos 10 /**< \brief (PM_APBCMASK) TCC2 APB Clock Enable */ +#define PM_APBCMASK_TCC2 (0x1u << PM_APBCMASK_TCC2_Pos) +#define PM_APBCMASK_TC3_Pos 11 /**< \brief (PM_APBCMASK) TC3 APB Clock Enable */ +#define PM_APBCMASK_TC3 (0x1u << PM_APBCMASK_TC3_Pos) +#define PM_APBCMASK_TC4_Pos 12 /**< \brief (PM_APBCMASK) TC4 APB Clock Enable */ +#define PM_APBCMASK_TC4 (0x1u << PM_APBCMASK_TC4_Pos) +#define PM_APBCMASK_TC5_Pos 13 /**< \brief (PM_APBCMASK) TC5 APB Clock Enable */ +#define PM_APBCMASK_TC5 (0x1u << PM_APBCMASK_TC5_Pos) +#define PM_APBCMASK_TC6_Pos 14 /**< \brief (PM_APBCMASK) TC6 APB Clock Enable */ +#define PM_APBCMASK_TC6 (0x1u << PM_APBCMASK_TC6_Pos) +#define PM_APBCMASK_TC7_Pos 15 /**< \brief (PM_APBCMASK) TC7 APB Clock Enable */ +#define PM_APBCMASK_TC7 (0x1u << PM_APBCMASK_TC7_Pos) +#define PM_APBCMASK_ADC_Pos 16 /**< \brief (PM_APBCMASK) ADC APB Clock Enable */ +#define PM_APBCMASK_ADC (0x1u << PM_APBCMASK_ADC_Pos) +#define PM_APBCMASK_AC_Pos 17 /**< \brief (PM_APBCMASK) AC APB Clock Enable */ +#define PM_APBCMASK_AC (0x1u << PM_APBCMASK_AC_Pos) +#define PM_APBCMASK_DAC_Pos 18 /**< \brief (PM_APBCMASK) DAC APB Clock Enable */ +#define PM_APBCMASK_DAC (0x1u << PM_APBCMASK_DAC_Pos) +#define PM_APBCMASK_PTC_Pos 19 /**< \brief (PM_APBCMASK) PTC APB Clock Enable */ +#define PM_APBCMASK_PTC (0x1u << PM_APBCMASK_PTC_Pos) +#define PM_APBCMASK_I2S_Pos 20 /**< \brief (PM_APBCMASK) I2S APB Clock Enable */ +#define PM_APBCMASK_I2S (0x1u << PM_APBCMASK_I2S_Pos) +#define PM_APBCMASK_MASK 0x001FFFFFu /**< \brief (PM_APBCMASK) MASK Register */ + +/* -------- PM_INTENCLR : (PM Offset: 0x34) (R/W 8) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CKRDY:1; /*!< bit: 0 Clock Ready Interrupt Enable */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PM_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_INTENCLR_OFFSET 0x34 /**< \brief (PM_INTENCLR offset) Interrupt Enable Clear */ +#define PM_INTENCLR_RESETVALUE 0x00 /**< \brief (PM_INTENCLR reset_value) Interrupt Enable Clear */ + +#define PM_INTENCLR_CKRDY_Pos 0 /**< \brief (PM_INTENCLR) Clock Ready Interrupt Enable */ +#define PM_INTENCLR_CKRDY (0x1u << PM_INTENCLR_CKRDY_Pos) +#define PM_INTENCLR_MASK 0x01u /**< \brief (PM_INTENCLR) MASK Register */ + +/* -------- PM_INTENSET : (PM Offset: 0x35) (R/W 8) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CKRDY:1; /*!< bit: 0 Clock Ready Interrupt Enable */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PM_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_INTENSET_OFFSET 0x35 /**< \brief (PM_INTENSET offset) Interrupt Enable Set */ +#define PM_INTENSET_RESETVALUE 0x00 /**< \brief (PM_INTENSET reset_value) Interrupt Enable Set */ + +#define PM_INTENSET_CKRDY_Pos 0 /**< \brief (PM_INTENSET) Clock Ready Interrupt Enable */ +#define PM_INTENSET_CKRDY (0x1u << PM_INTENSET_CKRDY_Pos) +#define PM_INTENSET_MASK 0x01u /**< \brief (PM_INTENSET) MASK Register */ + +/* -------- PM_INTFLAG : (PM Offset: 0x36) (R/W 8) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CKRDY:1; /*!< bit: 0 Clock Ready */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PM_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_INTFLAG_OFFSET 0x36 /**< \brief (PM_INTFLAG offset) Interrupt Flag Status and Clear */ +#define PM_INTFLAG_RESETVALUE 0x00 /**< \brief (PM_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define PM_INTFLAG_CKRDY_Pos 0 /**< \brief (PM_INTFLAG) Clock Ready */ +#define PM_INTFLAG_CKRDY (0x1u << PM_INTFLAG_CKRDY_Pos) +#define PM_INTFLAG_MASK 0x01u /**< \brief (PM_INTFLAG) MASK Register */ + +/* -------- PM_RCAUSE : (PM Offset: 0x38) (R/ 8) Reset Cause -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t POR:1; /*!< bit: 0 Power On Reset */ + uint8_t BOD12:1; /*!< bit: 1 Brown Out 12 Detector Reset */ + uint8_t BOD33:1; /*!< bit: 2 Brown Out 33 Detector Reset */ + uint8_t :1; /*!< bit: 3 Reserved */ + uint8_t EXT:1; /*!< bit: 4 External Reset */ + uint8_t WDT:1; /*!< bit: 5 Watchdog Reset */ + uint8_t SYST:1; /*!< bit: 6 System Reset Request */ + uint8_t :1; /*!< bit: 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PM_RCAUSE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PM_RCAUSE_OFFSET 0x38 /**< \brief (PM_RCAUSE offset) Reset Cause */ +#define PM_RCAUSE_RESETVALUE 0x01 /**< \brief (PM_RCAUSE reset_value) Reset Cause */ + +#define PM_RCAUSE_POR_Pos 0 /**< \brief (PM_RCAUSE) Power On Reset */ +#define PM_RCAUSE_POR (0x1u << PM_RCAUSE_POR_Pos) +#define PM_RCAUSE_BOD12_Pos 1 /**< \brief (PM_RCAUSE) Brown Out 12 Detector Reset */ +#define PM_RCAUSE_BOD12 (0x1u << PM_RCAUSE_BOD12_Pos) +#define PM_RCAUSE_BOD33_Pos 2 /**< \brief (PM_RCAUSE) Brown Out 33 Detector Reset */ +#define PM_RCAUSE_BOD33 (0x1u << PM_RCAUSE_BOD33_Pos) +#define PM_RCAUSE_EXT_Pos 4 /**< \brief (PM_RCAUSE) External Reset */ +#define PM_RCAUSE_EXT (0x1u << PM_RCAUSE_EXT_Pos) +#define PM_RCAUSE_WDT_Pos 5 /**< \brief (PM_RCAUSE) Watchdog Reset */ +#define PM_RCAUSE_WDT (0x1u << PM_RCAUSE_WDT_Pos) +#define PM_RCAUSE_SYST_Pos 6 /**< \brief (PM_RCAUSE) System Reset Request */ +#define PM_RCAUSE_SYST (0x1u << PM_RCAUSE_SYST_Pos) +#define PM_RCAUSE_MASK 0x77u /**< \brief (PM_RCAUSE) MASK Register */ + +/** \brief PM hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO PM_CTRL_Type CTRL; /**< \brief Offset: 0x00 (R/W 8) Control */ + __IO PM_SLEEP_Type SLEEP; /**< \brief Offset: 0x01 (R/W 8) Sleep Mode */ + RoReg8 Reserved1[0x6]; + __IO PM_CPUSEL_Type CPUSEL; /**< \brief Offset: 0x08 (R/W 8) CPU Clock Select */ + __IO PM_APBASEL_Type APBASEL; /**< \brief Offset: 0x09 (R/W 8) APBA Clock Select */ + __IO PM_APBBSEL_Type APBBSEL; /**< \brief Offset: 0x0A (R/W 8) APBB Clock Select */ + __IO PM_APBCSEL_Type APBCSEL; /**< \brief Offset: 0x0B (R/W 8) APBC Clock Select */ + RoReg8 Reserved2[0x8]; + __IO PM_AHBMASK_Type AHBMASK; /**< \brief Offset: 0x14 (R/W 32) AHB Mask */ + __IO PM_APBAMASK_Type APBAMASK; /**< \brief Offset: 0x18 (R/W 32) APBA Mask */ + __IO PM_APBBMASK_Type APBBMASK; /**< \brief Offset: 0x1C (R/W 32) APBB Mask */ + __IO PM_APBCMASK_Type APBCMASK; /**< \brief Offset: 0x20 (R/W 32) APBC Mask */ + RoReg8 Reserved3[0x10]; + __IO PM_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x34 (R/W 8) Interrupt Enable Clear */ + __IO PM_INTENSET_Type INTENSET; /**< \brief Offset: 0x35 (R/W 8) Interrupt Enable Set */ + __IO PM_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x36 (R/W 8) Interrupt Flag Status and Clear */ + RoReg8 Reserved4[0x1]; + __I PM_RCAUSE_Type RCAUSE; /**< \brief Offset: 0x38 (R/ 8) Reset Cause */ +} Pm; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_PM_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/port.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/port.h new file mode 100755 index 0000000..77365b5 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/port.h @@ -0,0 +1,395 @@ +/** + * \file + * + * \brief Component description for PORT + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_PORT_COMPONENT_ +#define _SAMD21_PORT_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR PORT */ +/* ========================================================================== */ +/** \addtogroup SAMD21_PORT Port Module */ +/*@{*/ + +#define PORT_U2210 +#define REV_PORT 0x100 + +/* -------- PORT_DIR : (PORT Offset: 0x00) (R/W 32) GROUP Data Direction -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DIR:32; /*!< bit: 0..31 Port Data Direction */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_DIR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_DIR_OFFSET 0x00 /**< \brief (PORT_DIR offset) Data Direction */ +#define PORT_DIR_RESETVALUE 0x00000000 /**< \brief (PORT_DIR reset_value) Data Direction */ + +#define PORT_DIR_DIR_Pos 0 /**< \brief (PORT_DIR) Port Data Direction */ +#define PORT_DIR_DIR_Msk (0xFFFFFFFFu << PORT_DIR_DIR_Pos) +#define PORT_DIR_DIR(value) ((PORT_DIR_DIR_Msk & ((value) << PORT_DIR_DIR_Pos))) +#define PORT_DIR_MASK 0xFFFFFFFFu /**< \brief (PORT_DIR) MASK Register */ + +/* -------- PORT_DIRCLR : (PORT Offset: 0x04) (R/W 32) GROUP Data Direction Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DIRCLR:32; /*!< bit: 0..31 Port Data Direction Clear */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_DIRCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_DIRCLR_OFFSET 0x04 /**< \brief (PORT_DIRCLR offset) Data Direction Clear */ +#define PORT_DIRCLR_RESETVALUE 0x00000000 /**< \brief (PORT_DIRCLR reset_value) Data Direction Clear */ + +#define PORT_DIRCLR_DIRCLR_Pos 0 /**< \brief (PORT_DIRCLR) Port Data Direction Clear */ +#define PORT_DIRCLR_DIRCLR_Msk (0xFFFFFFFFu << PORT_DIRCLR_DIRCLR_Pos) +#define PORT_DIRCLR_DIRCLR(value) ((PORT_DIRCLR_DIRCLR_Msk & ((value) << PORT_DIRCLR_DIRCLR_Pos))) +#define PORT_DIRCLR_MASK 0xFFFFFFFFu /**< \brief (PORT_DIRCLR) MASK Register */ + +/* -------- PORT_DIRSET : (PORT Offset: 0x08) (R/W 32) GROUP Data Direction Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DIRSET:32; /*!< bit: 0..31 Port Data Direction Set */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_DIRSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_DIRSET_OFFSET 0x08 /**< \brief (PORT_DIRSET offset) Data Direction Set */ +#define PORT_DIRSET_RESETVALUE 0x00000000 /**< \brief (PORT_DIRSET reset_value) Data Direction Set */ + +#define PORT_DIRSET_DIRSET_Pos 0 /**< \brief (PORT_DIRSET) Port Data Direction Set */ +#define PORT_DIRSET_DIRSET_Msk (0xFFFFFFFFu << PORT_DIRSET_DIRSET_Pos) +#define PORT_DIRSET_DIRSET(value) ((PORT_DIRSET_DIRSET_Msk & ((value) << PORT_DIRSET_DIRSET_Pos))) +#define PORT_DIRSET_MASK 0xFFFFFFFFu /**< \brief (PORT_DIRSET) MASK Register */ + +/* -------- PORT_DIRTGL : (PORT Offset: 0x0C) (R/W 32) GROUP Data Direction Toggle -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DIRTGL:32; /*!< bit: 0..31 Port Data Direction Toggle */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_DIRTGL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_DIRTGL_OFFSET 0x0C /**< \brief (PORT_DIRTGL offset) Data Direction Toggle */ +#define PORT_DIRTGL_RESETVALUE 0x00000000 /**< \brief (PORT_DIRTGL reset_value) Data Direction Toggle */ + +#define PORT_DIRTGL_DIRTGL_Pos 0 /**< \brief (PORT_DIRTGL) Port Data Direction Toggle */ +#define PORT_DIRTGL_DIRTGL_Msk (0xFFFFFFFFu << PORT_DIRTGL_DIRTGL_Pos) +#define PORT_DIRTGL_DIRTGL(value) ((PORT_DIRTGL_DIRTGL_Msk & ((value) << PORT_DIRTGL_DIRTGL_Pos))) +#define PORT_DIRTGL_MASK 0xFFFFFFFFu /**< \brief (PORT_DIRTGL) MASK Register */ + +/* -------- PORT_OUT : (PORT Offset: 0x10) (R/W 32) GROUP Data Output Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OUT:32; /*!< bit: 0..31 Port Data Output Value */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_OUT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_OUT_OFFSET 0x10 /**< \brief (PORT_OUT offset) Data Output Value */ +#define PORT_OUT_RESETVALUE 0x00000000 /**< \brief (PORT_OUT reset_value) Data Output Value */ + +#define PORT_OUT_OUT_Pos 0 /**< \brief (PORT_OUT) Port Data Output Value */ +#define PORT_OUT_OUT_Msk (0xFFFFFFFFu << PORT_OUT_OUT_Pos) +#define PORT_OUT_OUT(value) ((PORT_OUT_OUT_Msk & ((value) << PORT_OUT_OUT_Pos))) +#define PORT_OUT_MASK 0xFFFFFFFFu /**< \brief (PORT_OUT) MASK Register */ + +/* -------- PORT_OUTCLR : (PORT Offset: 0x14) (R/W 32) GROUP Data Output Value Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OUTCLR:32; /*!< bit: 0..31 Port Data Output Value Clear */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_OUTCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_OUTCLR_OFFSET 0x14 /**< \brief (PORT_OUTCLR offset) Data Output Value Clear */ +#define PORT_OUTCLR_RESETVALUE 0x00000000 /**< \brief (PORT_OUTCLR reset_value) Data Output Value Clear */ + +#define PORT_OUTCLR_OUTCLR_Pos 0 /**< \brief (PORT_OUTCLR) Port Data Output Value Clear */ +#define PORT_OUTCLR_OUTCLR_Msk (0xFFFFFFFFu << PORT_OUTCLR_OUTCLR_Pos) +#define PORT_OUTCLR_OUTCLR(value) ((PORT_OUTCLR_OUTCLR_Msk & ((value) << PORT_OUTCLR_OUTCLR_Pos))) +#define PORT_OUTCLR_MASK 0xFFFFFFFFu /**< \brief (PORT_OUTCLR) MASK Register */ + +/* -------- PORT_OUTSET : (PORT Offset: 0x18) (R/W 32) GROUP Data Output Value Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OUTSET:32; /*!< bit: 0..31 Port Data Output Value Set */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_OUTSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_OUTSET_OFFSET 0x18 /**< \brief (PORT_OUTSET offset) Data Output Value Set */ +#define PORT_OUTSET_RESETVALUE 0x00000000 /**< \brief (PORT_OUTSET reset_value) Data Output Value Set */ + +#define PORT_OUTSET_OUTSET_Pos 0 /**< \brief (PORT_OUTSET) Port Data Output Value Set */ +#define PORT_OUTSET_OUTSET_Msk (0xFFFFFFFFu << PORT_OUTSET_OUTSET_Pos) +#define PORT_OUTSET_OUTSET(value) ((PORT_OUTSET_OUTSET_Msk & ((value) << PORT_OUTSET_OUTSET_Pos))) +#define PORT_OUTSET_MASK 0xFFFFFFFFu /**< \brief (PORT_OUTSET) MASK Register */ + +/* -------- PORT_OUTTGL : (PORT Offset: 0x1C) (R/W 32) GROUP Data Output Value Toggle -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OUTTGL:32; /*!< bit: 0..31 Port Data Output Value Toggle */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_OUTTGL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_OUTTGL_OFFSET 0x1C /**< \brief (PORT_OUTTGL offset) Data Output Value Toggle */ +#define PORT_OUTTGL_RESETVALUE 0x00000000 /**< \brief (PORT_OUTTGL reset_value) Data Output Value Toggle */ + +#define PORT_OUTTGL_OUTTGL_Pos 0 /**< \brief (PORT_OUTTGL) Port Data Output Value Toggle */ +#define PORT_OUTTGL_OUTTGL_Msk (0xFFFFFFFFu << PORT_OUTTGL_OUTTGL_Pos) +#define PORT_OUTTGL_OUTTGL(value) ((PORT_OUTTGL_OUTTGL_Msk & ((value) << PORT_OUTTGL_OUTTGL_Pos))) +#define PORT_OUTTGL_MASK 0xFFFFFFFFu /**< \brief (PORT_OUTTGL) MASK Register */ + +/* -------- PORT_IN : (PORT Offset: 0x20) (R/ 32) GROUP Data Input Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t IN:32; /*!< bit: 0..31 Port Data Input Value */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_IN_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_IN_OFFSET 0x20 /**< \brief (PORT_IN offset) Data Input Value */ +#define PORT_IN_RESETVALUE 0x00000000 /**< \brief (PORT_IN reset_value) Data Input Value */ + +#define PORT_IN_IN_Pos 0 /**< \brief (PORT_IN) Port Data Input Value */ +#define PORT_IN_IN_Msk (0xFFFFFFFFu << PORT_IN_IN_Pos) +#define PORT_IN_IN(value) ((PORT_IN_IN_Msk & ((value) << PORT_IN_IN_Pos))) +#define PORT_IN_MASK 0xFFFFFFFFu /**< \brief (PORT_IN) MASK Register */ + +/* -------- PORT_CTRL : (PORT Offset: 0x24) (R/W 32) GROUP Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SAMPLING:32; /*!< bit: 0..31 Input Sampling Mode */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_CTRL_OFFSET 0x24 /**< \brief (PORT_CTRL offset) Control */ +#define PORT_CTRL_RESETVALUE 0x00000000 /**< \brief (PORT_CTRL reset_value) Control */ + +#define PORT_CTRL_SAMPLING_Pos 0 /**< \brief (PORT_CTRL) Input Sampling Mode */ +#define PORT_CTRL_SAMPLING_Msk (0xFFFFFFFFu << PORT_CTRL_SAMPLING_Pos) +#define PORT_CTRL_SAMPLING(value) ((PORT_CTRL_SAMPLING_Msk & ((value) << PORT_CTRL_SAMPLING_Pos))) +#define PORT_CTRL_MASK 0xFFFFFFFFu /**< \brief (PORT_CTRL) MASK Register */ + +/* -------- PORT_WRCONFIG : (PORT Offset: 0x28) ( /W 32) GROUP Write Configuration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PINMASK:16; /*!< bit: 0..15 Pin Mask for Multiple Pin Configuration */ + uint32_t PMUXEN:1; /*!< bit: 16 Peripheral Multiplexer Enable */ + uint32_t INEN:1; /*!< bit: 17 Input Enable */ + uint32_t PULLEN:1; /*!< bit: 18 Pull Enable */ + uint32_t :3; /*!< bit: 19..21 Reserved */ + uint32_t DRVSTR:1; /*!< bit: 22 Output Driver Strength Selection */ + uint32_t :1; /*!< bit: 23 Reserved */ + uint32_t PMUX:4; /*!< bit: 24..27 Peripheral Multiplexing */ + uint32_t WRPMUX:1; /*!< bit: 28 Write PMUX */ + uint32_t :1; /*!< bit: 29 Reserved */ + uint32_t WRPINCFG:1; /*!< bit: 30 Write PINCFG */ + uint32_t HWSEL:1; /*!< bit: 31 Half-Word Select */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} PORT_WRCONFIG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_WRCONFIG_OFFSET 0x28 /**< \brief (PORT_WRCONFIG offset) Write Configuration */ +#define PORT_WRCONFIG_RESETVALUE 0x00000000 /**< \brief (PORT_WRCONFIG reset_value) Write Configuration */ + +#define PORT_WRCONFIG_PINMASK_Pos 0 /**< \brief (PORT_WRCONFIG) Pin Mask for Multiple Pin Configuration */ +#define PORT_WRCONFIG_PINMASK_Msk (0xFFFFu << PORT_WRCONFIG_PINMASK_Pos) +#define PORT_WRCONFIG_PINMASK(value) ((PORT_WRCONFIG_PINMASK_Msk & ((value) << PORT_WRCONFIG_PINMASK_Pos))) +#define PORT_WRCONFIG_PMUXEN_Pos 16 /**< \brief (PORT_WRCONFIG) Peripheral Multiplexer Enable */ +#define PORT_WRCONFIG_PMUXEN (0x1u << PORT_WRCONFIG_PMUXEN_Pos) +#define PORT_WRCONFIG_INEN_Pos 17 /**< \brief (PORT_WRCONFIG) Input Enable */ +#define PORT_WRCONFIG_INEN (0x1u << PORT_WRCONFIG_INEN_Pos) +#define PORT_WRCONFIG_PULLEN_Pos 18 /**< \brief (PORT_WRCONFIG) Pull Enable */ +#define PORT_WRCONFIG_PULLEN (0x1u << PORT_WRCONFIG_PULLEN_Pos) +#define PORT_WRCONFIG_DRVSTR_Pos 22 /**< \brief (PORT_WRCONFIG) Output Driver Strength Selection */ +#define PORT_WRCONFIG_DRVSTR (0x1u << PORT_WRCONFIG_DRVSTR_Pos) +#define PORT_WRCONFIG_PMUX_Pos 24 /**< \brief (PORT_WRCONFIG) Peripheral Multiplexing */ +#define PORT_WRCONFIG_PMUX_Msk (0xFu << PORT_WRCONFIG_PMUX_Pos) +#define PORT_WRCONFIG_PMUX(value) ((PORT_WRCONFIG_PMUX_Msk & ((value) << PORT_WRCONFIG_PMUX_Pos))) +#define PORT_WRCONFIG_WRPMUX_Pos 28 /**< \brief (PORT_WRCONFIG) Write PMUX */ +#define PORT_WRCONFIG_WRPMUX (0x1u << PORT_WRCONFIG_WRPMUX_Pos) +#define PORT_WRCONFIG_WRPINCFG_Pos 30 /**< \brief (PORT_WRCONFIG) Write PINCFG */ +#define PORT_WRCONFIG_WRPINCFG (0x1u << PORT_WRCONFIG_WRPINCFG_Pos) +#define PORT_WRCONFIG_HWSEL_Pos 31 /**< \brief (PORT_WRCONFIG) Half-Word Select */ +#define PORT_WRCONFIG_HWSEL (0x1u << PORT_WRCONFIG_HWSEL_Pos) +#define PORT_WRCONFIG_MASK 0xDF47FFFFu /**< \brief (PORT_WRCONFIG) MASK Register */ + +/* -------- PORT_PMUX : (PORT Offset: 0x30) (R/W 8) GROUP Peripheral Multiplexing n -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PMUXE:4; /*!< bit: 0.. 3 Peripheral Multiplexing Even */ + uint8_t PMUXO:4; /*!< bit: 4.. 7 Peripheral Multiplexing Odd */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PORT_PMUX_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_PMUX_OFFSET 0x30 /**< \brief (PORT_PMUX offset) Peripheral Multiplexing n */ +#define PORT_PMUX_RESETVALUE 0x00 /**< \brief (PORT_PMUX reset_value) Peripheral Multiplexing n */ + +#define PORT_PMUX_PMUXE_Pos 0 /**< \brief (PORT_PMUX) Peripheral Multiplexing Even */ +#define PORT_PMUX_PMUXE_Msk (0xFu << PORT_PMUX_PMUXE_Pos) +#define PORT_PMUX_PMUXE(value) ((PORT_PMUX_PMUXE_Msk & ((value) << PORT_PMUX_PMUXE_Pos))) +#define PORT_PMUX_PMUXE_A_Val 0x0u /**< \brief (PORT_PMUX) Peripheral function A selected */ +#define PORT_PMUX_PMUXE_B_Val 0x1u /**< \brief (PORT_PMUX) Peripheral function B selected */ +#define PORT_PMUX_PMUXE_C_Val 0x2u /**< \brief (PORT_PMUX) Peripheral function C selected */ +#define PORT_PMUX_PMUXE_D_Val 0x3u /**< \brief (PORT_PMUX) Peripheral function D selected */ +#define PORT_PMUX_PMUXE_E_Val 0x4u /**< \brief (PORT_PMUX) Peripheral function E selected */ +#define PORT_PMUX_PMUXE_F_Val 0x5u /**< \brief (PORT_PMUX) Peripheral function F selected */ +#define PORT_PMUX_PMUXE_G_Val 0x6u /**< \brief (PORT_PMUX) Peripheral function G selected */ +#define PORT_PMUX_PMUXE_H_Val 0x7u /**< \brief (PORT_PMUX) Peripheral function H selected */ +#define PORT_PMUX_PMUXE_A (PORT_PMUX_PMUXE_A_Val << PORT_PMUX_PMUXE_Pos) +#define PORT_PMUX_PMUXE_B (PORT_PMUX_PMUXE_B_Val << PORT_PMUX_PMUXE_Pos) +#define PORT_PMUX_PMUXE_C (PORT_PMUX_PMUXE_C_Val << PORT_PMUX_PMUXE_Pos) +#define PORT_PMUX_PMUXE_D (PORT_PMUX_PMUXE_D_Val << PORT_PMUX_PMUXE_Pos) +#define PORT_PMUX_PMUXE_E (PORT_PMUX_PMUXE_E_Val << PORT_PMUX_PMUXE_Pos) +#define PORT_PMUX_PMUXE_F (PORT_PMUX_PMUXE_F_Val << PORT_PMUX_PMUXE_Pos) +#define PORT_PMUX_PMUXE_G (PORT_PMUX_PMUXE_G_Val << PORT_PMUX_PMUXE_Pos) +#define PORT_PMUX_PMUXE_H (PORT_PMUX_PMUXE_H_Val << PORT_PMUX_PMUXE_Pos) +#define PORT_PMUX_PMUXO_Pos 4 /**< \brief (PORT_PMUX) Peripheral Multiplexing Odd */ +#define PORT_PMUX_PMUXO_Msk (0xFu << PORT_PMUX_PMUXO_Pos) +#define PORT_PMUX_PMUXO(value) ((PORT_PMUX_PMUXO_Msk & ((value) << PORT_PMUX_PMUXO_Pos))) +#define PORT_PMUX_PMUXO_A_Val 0x0u /**< \brief (PORT_PMUX) Peripheral function A selected */ +#define PORT_PMUX_PMUXO_B_Val 0x1u /**< \brief (PORT_PMUX) Peripheral function B selected */ +#define PORT_PMUX_PMUXO_C_Val 0x2u /**< \brief (PORT_PMUX) Peripheral function C selected */ +#define PORT_PMUX_PMUXO_D_Val 0x3u /**< \brief (PORT_PMUX) Peripheral function D selected */ +#define PORT_PMUX_PMUXO_E_Val 0x4u /**< \brief (PORT_PMUX) Peripheral function E selected */ +#define PORT_PMUX_PMUXO_F_Val 0x5u /**< \brief (PORT_PMUX) Peripheral function F selected */ +#define PORT_PMUX_PMUXO_G_Val 0x6u /**< \brief (PORT_PMUX) Peripheral function G selected */ +#define PORT_PMUX_PMUXO_H_Val 0x7u /**< \brief (PORT_PMUX) Peripheral function H selected */ +#define PORT_PMUX_PMUXO_A (PORT_PMUX_PMUXO_A_Val << PORT_PMUX_PMUXO_Pos) +#define PORT_PMUX_PMUXO_B (PORT_PMUX_PMUXO_B_Val << PORT_PMUX_PMUXO_Pos) +#define PORT_PMUX_PMUXO_C (PORT_PMUX_PMUXO_C_Val << PORT_PMUX_PMUXO_Pos) +#define PORT_PMUX_PMUXO_D (PORT_PMUX_PMUXO_D_Val << PORT_PMUX_PMUXO_Pos) +#define PORT_PMUX_PMUXO_E (PORT_PMUX_PMUXO_E_Val << PORT_PMUX_PMUXO_Pos) +#define PORT_PMUX_PMUXO_F (PORT_PMUX_PMUXO_F_Val << PORT_PMUX_PMUXO_Pos) +#define PORT_PMUX_PMUXO_G (PORT_PMUX_PMUXO_G_Val << PORT_PMUX_PMUXO_Pos) +#define PORT_PMUX_PMUXO_H (PORT_PMUX_PMUXO_H_Val << PORT_PMUX_PMUXO_Pos) +#define PORT_PMUX_MASK 0xFFu /**< \brief (PORT_PMUX) MASK Register */ + +/* -------- PORT_PINCFG : (PORT Offset: 0x40) (R/W 8) GROUP Pin Configuration n -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PMUXEN:1; /*!< bit: 0 Peripheral Multiplexer Enable */ + uint8_t INEN:1; /*!< bit: 1 Input Enable */ + uint8_t PULLEN:1; /*!< bit: 2 Pull Enable */ + uint8_t :3; /*!< bit: 3.. 5 Reserved */ + uint8_t DRVSTR:1; /*!< bit: 6 Output Driver Strength Selection */ + uint8_t :1; /*!< bit: 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} PORT_PINCFG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define PORT_PINCFG_OFFSET 0x40 /**< \brief (PORT_PINCFG offset) Pin Configuration n */ +#define PORT_PINCFG_RESETVALUE 0x00 /**< \brief (PORT_PINCFG reset_value) Pin Configuration n */ + +#define PORT_PINCFG_PMUXEN_Pos 0 /**< \brief (PORT_PINCFG) Peripheral Multiplexer Enable */ +#define PORT_PINCFG_PMUXEN (0x1u << PORT_PINCFG_PMUXEN_Pos) +#define PORT_PINCFG_INEN_Pos 1 /**< \brief (PORT_PINCFG) Input Enable */ +#define PORT_PINCFG_INEN (0x1u << PORT_PINCFG_INEN_Pos) +#define PORT_PINCFG_PULLEN_Pos 2 /**< \brief (PORT_PINCFG) Pull Enable */ +#define PORT_PINCFG_PULLEN (0x1u << PORT_PINCFG_PULLEN_Pos) +#define PORT_PINCFG_DRVSTR_Pos 6 /**< \brief (PORT_PINCFG) Output Driver Strength Selection */ +#define PORT_PINCFG_DRVSTR (0x1u << PORT_PINCFG_DRVSTR_Pos) +#define PORT_PINCFG_MASK 0x47u /**< \brief (PORT_PINCFG) MASK Register */ + +/** \brief PortGroup hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO PORT_DIR_Type DIR; /**< \brief Offset: 0x00 (R/W 32) Data Direction */ + __IO PORT_DIRCLR_Type DIRCLR; /**< \brief Offset: 0x04 (R/W 32) Data Direction Clear */ + __IO PORT_DIRSET_Type DIRSET; /**< \brief Offset: 0x08 (R/W 32) Data Direction Set */ + __IO PORT_DIRTGL_Type DIRTGL; /**< \brief Offset: 0x0C (R/W 32) Data Direction Toggle */ + __IO PORT_OUT_Type OUT; /**< \brief Offset: 0x10 (R/W 32) Data Output Value */ + __IO PORT_OUTCLR_Type OUTCLR; /**< \brief Offset: 0x14 (R/W 32) Data Output Value Clear */ + __IO PORT_OUTSET_Type OUTSET; /**< \brief Offset: 0x18 (R/W 32) Data Output Value Set */ + __IO PORT_OUTTGL_Type OUTTGL; /**< \brief Offset: 0x1C (R/W 32) Data Output Value Toggle */ + __I PORT_IN_Type IN; /**< \brief Offset: 0x20 (R/ 32) Data Input Value */ + __IO PORT_CTRL_Type CTRL; /**< \brief Offset: 0x24 (R/W 32) Control */ + __O PORT_WRCONFIG_Type WRCONFIG; /**< \brief Offset: 0x28 ( /W 32) Write Configuration */ + RoReg8 Reserved1[0x4]; + __IO PORT_PMUX_Type PMUX[16]; /**< \brief Offset: 0x30 (R/W 8) Peripheral Multiplexing n */ + __IO PORT_PINCFG_Type PINCFG[32]; /**< \brief Offset: 0x40 (R/W 8) Pin Configuration n */ + RoReg8 Reserved2[0x20]; +} PortGroup; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief PORT APB hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + PortGroup Group[2]; /**< \brief Offset: 0x00 PortGroup groups [GROUPS] */ +} Port; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +#define SECTION_PORT_IOBUS + +/*@}*/ + +#endif /* _SAMD21_PORT_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/rtc.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/rtc.h new file mode 100755 index 0000000..0fe36bb --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/rtc.h @@ -0,0 +1,1062 @@ +/** + * \file + * + * \brief Component description for RTC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_RTC_COMPONENT_ +#define _SAMD21_RTC_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR RTC */ +/* ========================================================================== */ +/** \addtogroup SAMD21_RTC Real-Time Counter */ +/*@{*/ + +#define RTC_U2202 +#define REV_RTC 0x101 + +/* -------- RTC_MODE0_CTRL : (RTC Offset: 0x00) (R/W 16) MODE0 MODE0 Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SWRST:1; /*!< bit: 0 Software Reset */ + uint16_t ENABLE:1; /*!< bit: 1 Enable */ + uint16_t MODE:2; /*!< bit: 2.. 3 Operating Mode */ + uint16_t :3; /*!< bit: 4.. 6 Reserved */ + uint16_t MATCHCLR:1; /*!< bit: 7 Clear on Match */ + uint16_t PRESCALER:4; /*!< bit: 8..11 Prescaler */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_MODE0_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE0_CTRL_OFFSET 0x00 /**< \brief (RTC_MODE0_CTRL offset) MODE0 Control */ +#define RTC_MODE0_CTRL_RESETVALUE 0x0000 /**< \brief (RTC_MODE0_CTRL reset_value) MODE0 Control */ + +#define RTC_MODE0_CTRL_SWRST_Pos 0 /**< \brief (RTC_MODE0_CTRL) Software Reset */ +#define RTC_MODE0_CTRL_SWRST (0x1u << RTC_MODE0_CTRL_SWRST_Pos) +#define RTC_MODE0_CTRL_ENABLE_Pos 1 /**< \brief (RTC_MODE0_CTRL) Enable */ +#define RTC_MODE0_CTRL_ENABLE (0x1u << RTC_MODE0_CTRL_ENABLE_Pos) +#define RTC_MODE0_CTRL_MODE_Pos 2 /**< \brief (RTC_MODE0_CTRL) Operating Mode */ +#define RTC_MODE0_CTRL_MODE_Msk (0x3u << RTC_MODE0_CTRL_MODE_Pos) +#define RTC_MODE0_CTRL_MODE(value) ((RTC_MODE0_CTRL_MODE_Msk & ((value) << RTC_MODE0_CTRL_MODE_Pos))) +#define RTC_MODE0_CTRL_MODE_COUNT32_Val 0x0u /**< \brief (RTC_MODE0_CTRL) Mode 0: 32-bit Counter */ +#define RTC_MODE0_CTRL_MODE_COUNT16_Val 0x1u /**< \brief (RTC_MODE0_CTRL) Mode 1: 16-bit Counter */ +#define RTC_MODE0_CTRL_MODE_CLOCK_Val 0x2u /**< \brief (RTC_MODE0_CTRL) Mode 2: Clock/Calendar */ +#define RTC_MODE0_CTRL_MODE_COUNT32 (RTC_MODE0_CTRL_MODE_COUNT32_Val << RTC_MODE0_CTRL_MODE_Pos) +#define RTC_MODE0_CTRL_MODE_COUNT16 (RTC_MODE0_CTRL_MODE_COUNT16_Val << RTC_MODE0_CTRL_MODE_Pos) +#define RTC_MODE0_CTRL_MODE_CLOCK (RTC_MODE0_CTRL_MODE_CLOCK_Val << RTC_MODE0_CTRL_MODE_Pos) +#define RTC_MODE0_CTRL_MATCHCLR_Pos 7 /**< \brief (RTC_MODE0_CTRL) Clear on Match */ +#define RTC_MODE0_CTRL_MATCHCLR (0x1u << RTC_MODE0_CTRL_MATCHCLR_Pos) +#define RTC_MODE0_CTRL_PRESCALER_Pos 8 /**< \brief (RTC_MODE0_CTRL) Prescaler */ +#define RTC_MODE0_CTRL_PRESCALER_Msk (0xFu << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER(value) ((RTC_MODE0_CTRL_PRESCALER_Msk & ((value) << RTC_MODE0_CTRL_PRESCALER_Pos))) +#define RTC_MODE0_CTRL_PRESCALER_DIV1_Val 0x0u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/1 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV2_Val 0x1u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/2 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV4_Val 0x2u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/4 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV8_Val 0x3u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/8 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV16_Val 0x4u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/16 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV32_Val 0x5u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/32 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV64_Val 0x6u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/64 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV128_Val 0x7u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/128 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV256_Val 0x8u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/256 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV512_Val 0x9u /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/512 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV1024_Val 0xAu /**< \brief (RTC_MODE0_CTRL) CLK_RTC_CNT = GCLK_RTC/1024 */ +#define RTC_MODE0_CTRL_PRESCALER_DIV1 (RTC_MODE0_CTRL_PRESCALER_DIV1_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV2 (RTC_MODE0_CTRL_PRESCALER_DIV2_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV4 (RTC_MODE0_CTRL_PRESCALER_DIV4_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV8 (RTC_MODE0_CTRL_PRESCALER_DIV8_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV16 (RTC_MODE0_CTRL_PRESCALER_DIV16_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV32 (RTC_MODE0_CTRL_PRESCALER_DIV32_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV64 (RTC_MODE0_CTRL_PRESCALER_DIV64_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV128 (RTC_MODE0_CTRL_PRESCALER_DIV128_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV256 (RTC_MODE0_CTRL_PRESCALER_DIV256_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV512 (RTC_MODE0_CTRL_PRESCALER_DIV512_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_PRESCALER_DIV1024 (RTC_MODE0_CTRL_PRESCALER_DIV1024_Val << RTC_MODE0_CTRL_PRESCALER_Pos) +#define RTC_MODE0_CTRL_MASK 0x0F8Fu /**< \brief (RTC_MODE0_CTRL) MASK Register */ + +/* -------- RTC_MODE1_CTRL : (RTC Offset: 0x00) (R/W 16) MODE1 MODE1 Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SWRST:1; /*!< bit: 0 Software Reset */ + uint16_t ENABLE:1; /*!< bit: 1 Enable */ + uint16_t MODE:2; /*!< bit: 2.. 3 Operating Mode */ + uint16_t :4; /*!< bit: 4.. 7 Reserved */ + uint16_t PRESCALER:4; /*!< bit: 8..11 Prescaler */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_MODE1_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE1_CTRL_OFFSET 0x00 /**< \brief (RTC_MODE1_CTRL offset) MODE1 Control */ +#define RTC_MODE1_CTRL_RESETVALUE 0x0000 /**< \brief (RTC_MODE1_CTRL reset_value) MODE1 Control */ + +#define RTC_MODE1_CTRL_SWRST_Pos 0 /**< \brief (RTC_MODE1_CTRL) Software Reset */ +#define RTC_MODE1_CTRL_SWRST (0x1u << RTC_MODE1_CTRL_SWRST_Pos) +#define RTC_MODE1_CTRL_ENABLE_Pos 1 /**< \brief (RTC_MODE1_CTRL) Enable */ +#define RTC_MODE1_CTRL_ENABLE (0x1u << RTC_MODE1_CTRL_ENABLE_Pos) +#define RTC_MODE1_CTRL_MODE_Pos 2 /**< \brief (RTC_MODE1_CTRL) Operating Mode */ +#define RTC_MODE1_CTRL_MODE_Msk (0x3u << RTC_MODE1_CTRL_MODE_Pos) +#define RTC_MODE1_CTRL_MODE(value) ((RTC_MODE1_CTRL_MODE_Msk & ((value) << RTC_MODE1_CTRL_MODE_Pos))) +#define RTC_MODE1_CTRL_MODE_COUNT32_Val 0x0u /**< \brief (RTC_MODE1_CTRL) Mode 0: 32-bit Counter */ +#define RTC_MODE1_CTRL_MODE_COUNT16_Val 0x1u /**< \brief (RTC_MODE1_CTRL) Mode 1: 16-bit Counter */ +#define RTC_MODE1_CTRL_MODE_CLOCK_Val 0x2u /**< \brief (RTC_MODE1_CTRL) Mode 2: Clock/Calendar */ +#define RTC_MODE1_CTRL_MODE_COUNT32 (RTC_MODE1_CTRL_MODE_COUNT32_Val << RTC_MODE1_CTRL_MODE_Pos) +#define RTC_MODE1_CTRL_MODE_COUNT16 (RTC_MODE1_CTRL_MODE_COUNT16_Val << RTC_MODE1_CTRL_MODE_Pos) +#define RTC_MODE1_CTRL_MODE_CLOCK (RTC_MODE1_CTRL_MODE_CLOCK_Val << RTC_MODE1_CTRL_MODE_Pos) +#define RTC_MODE1_CTRL_PRESCALER_Pos 8 /**< \brief (RTC_MODE1_CTRL) Prescaler */ +#define RTC_MODE1_CTRL_PRESCALER_Msk (0xFu << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER(value) ((RTC_MODE1_CTRL_PRESCALER_Msk & ((value) << RTC_MODE1_CTRL_PRESCALER_Pos))) +#define RTC_MODE1_CTRL_PRESCALER_DIV1_Val 0x0u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/1 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV2_Val 0x1u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/2 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV4_Val 0x2u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/4 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV8_Val 0x3u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/8 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV16_Val 0x4u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/16 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV32_Val 0x5u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/32 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV64_Val 0x6u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/64 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV128_Val 0x7u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/128 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV256_Val 0x8u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/256 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV512_Val 0x9u /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/512 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV1024_Val 0xAu /**< \brief (RTC_MODE1_CTRL) CLK_RTC_CNT = GCLK_RTC/1024 */ +#define RTC_MODE1_CTRL_PRESCALER_DIV1 (RTC_MODE1_CTRL_PRESCALER_DIV1_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV2 (RTC_MODE1_CTRL_PRESCALER_DIV2_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV4 (RTC_MODE1_CTRL_PRESCALER_DIV4_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV8 (RTC_MODE1_CTRL_PRESCALER_DIV8_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV16 (RTC_MODE1_CTRL_PRESCALER_DIV16_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV32 (RTC_MODE1_CTRL_PRESCALER_DIV32_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV64 (RTC_MODE1_CTRL_PRESCALER_DIV64_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV128 (RTC_MODE1_CTRL_PRESCALER_DIV128_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV256 (RTC_MODE1_CTRL_PRESCALER_DIV256_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV512 (RTC_MODE1_CTRL_PRESCALER_DIV512_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_PRESCALER_DIV1024 (RTC_MODE1_CTRL_PRESCALER_DIV1024_Val << RTC_MODE1_CTRL_PRESCALER_Pos) +#define RTC_MODE1_CTRL_MASK 0x0F0Fu /**< \brief (RTC_MODE1_CTRL) MASK Register */ + +/* -------- RTC_MODE2_CTRL : (RTC Offset: 0x00) (R/W 16) MODE2 MODE2 Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SWRST:1; /*!< bit: 0 Software Reset */ + uint16_t ENABLE:1; /*!< bit: 1 Enable */ + uint16_t MODE:2; /*!< bit: 2.. 3 Operating Mode */ + uint16_t :2; /*!< bit: 4.. 5 Reserved */ + uint16_t CLKREP:1; /*!< bit: 6 Clock Representation */ + uint16_t MATCHCLR:1; /*!< bit: 7 Clear on Match */ + uint16_t PRESCALER:4; /*!< bit: 8..11 Prescaler */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_MODE2_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE2_CTRL_OFFSET 0x00 /**< \brief (RTC_MODE2_CTRL offset) MODE2 Control */ +#define RTC_MODE2_CTRL_RESETVALUE 0x0000 /**< \brief (RTC_MODE2_CTRL reset_value) MODE2 Control */ + +#define RTC_MODE2_CTRL_SWRST_Pos 0 /**< \brief (RTC_MODE2_CTRL) Software Reset */ +#define RTC_MODE2_CTRL_SWRST (0x1u << RTC_MODE2_CTRL_SWRST_Pos) +#define RTC_MODE2_CTRL_ENABLE_Pos 1 /**< \brief (RTC_MODE2_CTRL) Enable */ +#define RTC_MODE2_CTRL_ENABLE (0x1u << RTC_MODE2_CTRL_ENABLE_Pos) +#define RTC_MODE2_CTRL_MODE_Pos 2 /**< \brief (RTC_MODE2_CTRL) Operating Mode */ +#define RTC_MODE2_CTRL_MODE_Msk (0x3u << RTC_MODE2_CTRL_MODE_Pos) +#define RTC_MODE2_CTRL_MODE(value) ((RTC_MODE2_CTRL_MODE_Msk & ((value) << RTC_MODE2_CTRL_MODE_Pos))) +#define RTC_MODE2_CTRL_MODE_COUNT32_Val 0x0u /**< \brief (RTC_MODE2_CTRL) Mode 0: 32-bit Counter */ +#define RTC_MODE2_CTRL_MODE_COUNT16_Val 0x1u /**< \brief (RTC_MODE2_CTRL) Mode 1: 16-bit Counter */ +#define RTC_MODE2_CTRL_MODE_CLOCK_Val 0x2u /**< \brief (RTC_MODE2_CTRL) Mode 2: Clock/Calendar */ +#define RTC_MODE2_CTRL_MODE_COUNT32 (RTC_MODE2_CTRL_MODE_COUNT32_Val << RTC_MODE2_CTRL_MODE_Pos) +#define RTC_MODE2_CTRL_MODE_COUNT16 (RTC_MODE2_CTRL_MODE_COUNT16_Val << RTC_MODE2_CTRL_MODE_Pos) +#define RTC_MODE2_CTRL_MODE_CLOCK (RTC_MODE2_CTRL_MODE_CLOCK_Val << RTC_MODE2_CTRL_MODE_Pos) +#define RTC_MODE2_CTRL_CLKREP_Pos 6 /**< \brief (RTC_MODE2_CTRL) Clock Representation */ +#define RTC_MODE2_CTRL_CLKREP (0x1u << RTC_MODE2_CTRL_CLKREP_Pos) +#define RTC_MODE2_CTRL_MATCHCLR_Pos 7 /**< \brief (RTC_MODE2_CTRL) Clear on Match */ +#define RTC_MODE2_CTRL_MATCHCLR (0x1u << RTC_MODE2_CTRL_MATCHCLR_Pos) +#define RTC_MODE2_CTRL_PRESCALER_Pos 8 /**< \brief (RTC_MODE2_CTRL) Prescaler */ +#define RTC_MODE2_CTRL_PRESCALER_Msk (0xFu << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER(value) ((RTC_MODE2_CTRL_PRESCALER_Msk & ((value) << RTC_MODE2_CTRL_PRESCALER_Pos))) +#define RTC_MODE2_CTRL_PRESCALER_DIV1_Val 0x0u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/1 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV2_Val 0x1u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/2 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV4_Val 0x2u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/4 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV8_Val 0x3u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/8 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV16_Val 0x4u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/16 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV32_Val 0x5u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/32 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV64_Val 0x6u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/64 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV128_Val 0x7u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/128 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV256_Val 0x8u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/256 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV512_Val 0x9u /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/512 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV1024_Val 0xAu /**< \brief (RTC_MODE2_CTRL) CLK_RTC_CNT = GCLK_RTC/1024 */ +#define RTC_MODE2_CTRL_PRESCALER_DIV1 (RTC_MODE2_CTRL_PRESCALER_DIV1_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV2 (RTC_MODE2_CTRL_PRESCALER_DIV2_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV4 (RTC_MODE2_CTRL_PRESCALER_DIV4_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV8 (RTC_MODE2_CTRL_PRESCALER_DIV8_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV16 (RTC_MODE2_CTRL_PRESCALER_DIV16_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV32 (RTC_MODE2_CTRL_PRESCALER_DIV32_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV64 (RTC_MODE2_CTRL_PRESCALER_DIV64_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV128 (RTC_MODE2_CTRL_PRESCALER_DIV128_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV256 (RTC_MODE2_CTRL_PRESCALER_DIV256_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV512 (RTC_MODE2_CTRL_PRESCALER_DIV512_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_PRESCALER_DIV1024 (RTC_MODE2_CTRL_PRESCALER_DIV1024_Val << RTC_MODE2_CTRL_PRESCALER_Pos) +#define RTC_MODE2_CTRL_MASK 0x0FCFu /**< \brief (RTC_MODE2_CTRL) MASK Register */ + +/* -------- RTC_READREQ : (RTC Offset: 0x02) (R/W 16) Read Request -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t ADDR:6; /*!< bit: 0.. 5 Address */ + uint16_t :8; /*!< bit: 6..13 Reserved */ + uint16_t RCONT:1; /*!< bit: 14 Read Continuously */ + uint16_t RREQ:1; /*!< bit: 15 Read Request */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_READREQ_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_READREQ_OFFSET 0x02 /**< \brief (RTC_READREQ offset) Read Request */ +#define RTC_READREQ_RESETVALUE 0x0010 /**< \brief (RTC_READREQ reset_value) Read Request */ + +#define RTC_READREQ_ADDR_Pos 0 /**< \brief (RTC_READREQ) Address */ +#define RTC_READREQ_ADDR_Msk (0x3Fu << RTC_READREQ_ADDR_Pos) +#define RTC_READREQ_ADDR(value) ((RTC_READREQ_ADDR_Msk & ((value) << RTC_READREQ_ADDR_Pos))) +#define RTC_READREQ_RCONT_Pos 14 /**< \brief (RTC_READREQ) Read Continuously */ +#define RTC_READREQ_RCONT (0x1u << RTC_READREQ_RCONT_Pos) +#define RTC_READREQ_RREQ_Pos 15 /**< \brief (RTC_READREQ) Read Request */ +#define RTC_READREQ_RREQ (0x1u << RTC_READREQ_RREQ_Pos) +#define RTC_READREQ_MASK 0xC03Fu /**< \brief (RTC_READREQ) MASK Register */ + +/* -------- RTC_MODE0_EVCTRL : (RTC Offset: 0x04) (R/W 16) MODE0 MODE0 Event Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t PEREO0:1; /*!< bit: 0 Periodic Interval 0 Event Output Enable */ + uint16_t PEREO1:1; /*!< bit: 1 Periodic Interval 1 Event Output Enable */ + uint16_t PEREO2:1; /*!< bit: 2 Periodic Interval 2 Event Output Enable */ + uint16_t PEREO3:1; /*!< bit: 3 Periodic Interval 3 Event Output Enable */ + uint16_t PEREO4:1; /*!< bit: 4 Periodic Interval 4 Event Output Enable */ + uint16_t PEREO5:1; /*!< bit: 5 Periodic Interval 5 Event Output Enable */ + uint16_t PEREO6:1; /*!< bit: 6 Periodic Interval 6 Event Output Enable */ + uint16_t PEREO7:1; /*!< bit: 7 Periodic Interval 7 Event Output Enable */ + uint16_t CMPEO0:1; /*!< bit: 8 Compare 0 Event Output Enable */ + uint16_t :6; /*!< bit: 9..14 Reserved */ + uint16_t OVFEO:1; /*!< bit: 15 Overflow Event Output Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t PEREO:8; /*!< bit: 0.. 7 Periodic Interval x Event Output Enable */ + uint16_t CMPEO:1; /*!< bit: 8 Compare x Event Output Enable */ + uint16_t :7; /*!< bit: 9..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_MODE0_EVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE0_EVCTRL_OFFSET 0x04 /**< \brief (RTC_MODE0_EVCTRL offset) MODE0 Event Control */ +#define RTC_MODE0_EVCTRL_RESETVALUE 0x0000 /**< \brief (RTC_MODE0_EVCTRL reset_value) MODE0 Event Control */ + +#define RTC_MODE0_EVCTRL_PEREO0_Pos 0 /**< \brief (RTC_MODE0_EVCTRL) Periodic Interval 0 Event Output Enable */ +#define RTC_MODE0_EVCTRL_PEREO0 (1 << RTC_MODE0_EVCTRL_PEREO0_Pos) +#define RTC_MODE0_EVCTRL_PEREO1_Pos 1 /**< \brief (RTC_MODE0_EVCTRL) Periodic Interval 1 Event Output Enable */ +#define RTC_MODE0_EVCTRL_PEREO1 (1 << RTC_MODE0_EVCTRL_PEREO1_Pos) +#define RTC_MODE0_EVCTRL_PEREO2_Pos 2 /**< \brief (RTC_MODE0_EVCTRL) Periodic Interval 2 Event Output Enable */ +#define RTC_MODE0_EVCTRL_PEREO2 (1 << RTC_MODE0_EVCTRL_PEREO2_Pos) +#define RTC_MODE0_EVCTRL_PEREO3_Pos 3 /**< \brief (RTC_MODE0_EVCTRL) Periodic Interval 3 Event Output Enable */ +#define RTC_MODE0_EVCTRL_PEREO3 (1 << RTC_MODE0_EVCTRL_PEREO3_Pos) +#define RTC_MODE0_EVCTRL_PEREO4_Pos 4 /**< \brief (RTC_MODE0_EVCTRL) Periodic Interval 4 Event Output Enable */ +#define RTC_MODE0_EVCTRL_PEREO4 (1 << RTC_MODE0_EVCTRL_PEREO4_Pos) +#define RTC_MODE0_EVCTRL_PEREO5_Pos 5 /**< \brief (RTC_MODE0_EVCTRL) Periodic Interval 5 Event Output Enable */ +#define RTC_MODE0_EVCTRL_PEREO5 (1 << RTC_MODE0_EVCTRL_PEREO5_Pos) +#define RTC_MODE0_EVCTRL_PEREO6_Pos 6 /**< \brief (RTC_MODE0_EVCTRL) Periodic Interval 6 Event Output Enable */ +#define RTC_MODE0_EVCTRL_PEREO6 (1 << RTC_MODE0_EVCTRL_PEREO6_Pos) +#define RTC_MODE0_EVCTRL_PEREO7_Pos 7 /**< \brief (RTC_MODE0_EVCTRL) Periodic Interval 7 Event Output Enable */ +#define RTC_MODE0_EVCTRL_PEREO7 (1 << RTC_MODE0_EVCTRL_PEREO7_Pos) +#define RTC_MODE0_EVCTRL_PEREO_Pos 0 /**< \brief (RTC_MODE0_EVCTRL) Periodic Interval x Event Output Enable */ +#define RTC_MODE0_EVCTRL_PEREO_Msk (0xFFu << RTC_MODE0_EVCTRL_PEREO_Pos) +#define RTC_MODE0_EVCTRL_PEREO(value) ((RTC_MODE0_EVCTRL_PEREO_Msk & ((value) << RTC_MODE0_EVCTRL_PEREO_Pos))) +#define RTC_MODE0_EVCTRL_CMPEO0_Pos 8 /**< \brief (RTC_MODE0_EVCTRL) Compare 0 Event Output Enable */ +#define RTC_MODE0_EVCTRL_CMPEO0 (1 << RTC_MODE0_EVCTRL_CMPEO0_Pos) +#define RTC_MODE0_EVCTRL_CMPEO_Pos 8 /**< \brief (RTC_MODE0_EVCTRL) Compare x Event Output Enable */ +#define RTC_MODE0_EVCTRL_CMPEO_Msk (0x1u << RTC_MODE0_EVCTRL_CMPEO_Pos) +#define RTC_MODE0_EVCTRL_CMPEO(value) ((RTC_MODE0_EVCTRL_CMPEO_Msk & ((value) << RTC_MODE0_EVCTRL_CMPEO_Pos))) +#define RTC_MODE0_EVCTRL_OVFEO_Pos 15 /**< \brief (RTC_MODE0_EVCTRL) Overflow Event Output Enable */ +#define RTC_MODE0_EVCTRL_OVFEO (0x1u << RTC_MODE0_EVCTRL_OVFEO_Pos) +#define RTC_MODE0_EVCTRL_MASK 0x81FFu /**< \brief (RTC_MODE0_EVCTRL) MASK Register */ + +/* -------- RTC_MODE1_EVCTRL : (RTC Offset: 0x04) (R/W 16) MODE1 MODE1 Event Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t PEREO0:1; /*!< bit: 0 Periodic Interval 0 Event Output Enable */ + uint16_t PEREO1:1; /*!< bit: 1 Periodic Interval 1 Event Output Enable */ + uint16_t PEREO2:1; /*!< bit: 2 Periodic Interval 2 Event Output Enable */ + uint16_t PEREO3:1; /*!< bit: 3 Periodic Interval 3 Event Output Enable */ + uint16_t PEREO4:1; /*!< bit: 4 Periodic Interval 4 Event Output Enable */ + uint16_t PEREO5:1; /*!< bit: 5 Periodic Interval 5 Event Output Enable */ + uint16_t PEREO6:1; /*!< bit: 6 Periodic Interval 6 Event Output Enable */ + uint16_t PEREO7:1; /*!< bit: 7 Periodic Interval 7 Event Output Enable */ + uint16_t CMPEO0:1; /*!< bit: 8 Compare 0 Event Output Enable */ + uint16_t CMPEO1:1; /*!< bit: 9 Compare 1 Event Output Enable */ + uint16_t :5; /*!< bit: 10..14 Reserved */ + uint16_t OVFEO:1; /*!< bit: 15 Overflow Event Output Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t PEREO:8; /*!< bit: 0.. 7 Periodic Interval x Event Output Enable */ + uint16_t CMPEO:2; /*!< bit: 8.. 9 Compare x Event Output Enable */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_MODE1_EVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE1_EVCTRL_OFFSET 0x04 /**< \brief (RTC_MODE1_EVCTRL offset) MODE1 Event Control */ +#define RTC_MODE1_EVCTRL_RESETVALUE 0x0000 /**< \brief (RTC_MODE1_EVCTRL reset_value) MODE1 Event Control */ + +#define RTC_MODE1_EVCTRL_PEREO0_Pos 0 /**< \brief (RTC_MODE1_EVCTRL) Periodic Interval 0 Event Output Enable */ +#define RTC_MODE1_EVCTRL_PEREO0 (1 << RTC_MODE1_EVCTRL_PEREO0_Pos) +#define RTC_MODE1_EVCTRL_PEREO1_Pos 1 /**< \brief (RTC_MODE1_EVCTRL) Periodic Interval 1 Event Output Enable */ +#define RTC_MODE1_EVCTRL_PEREO1 (1 << RTC_MODE1_EVCTRL_PEREO1_Pos) +#define RTC_MODE1_EVCTRL_PEREO2_Pos 2 /**< \brief (RTC_MODE1_EVCTRL) Periodic Interval 2 Event Output Enable */ +#define RTC_MODE1_EVCTRL_PEREO2 (1 << RTC_MODE1_EVCTRL_PEREO2_Pos) +#define RTC_MODE1_EVCTRL_PEREO3_Pos 3 /**< \brief (RTC_MODE1_EVCTRL) Periodic Interval 3 Event Output Enable */ +#define RTC_MODE1_EVCTRL_PEREO3 (1 << RTC_MODE1_EVCTRL_PEREO3_Pos) +#define RTC_MODE1_EVCTRL_PEREO4_Pos 4 /**< \brief (RTC_MODE1_EVCTRL) Periodic Interval 4 Event Output Enable */ +#define RTC_MODE1_EVCTRL_PEREO4 (1 << RTC_MODE1_EVCTRL_PEREO4_Pos) +#define RTC_MODE1_EVCTRL_PEREO5_Pos 5 /**< \brief (RTC_MODE1_EVCTRL) Periodic Interval 5 Event Output Enable */ +#define RTC_MODE1_EVCTRL_PEREO5 (1 << RTC_MODE1_EVCTRL_PEREO5_Pos) +#define RTC_MODE1_EVCTRL_PEREO6_Pos 6 /**< \brief (RTC_MODE1_EVCTRL) Periodic Interval 6 Event Output Enable */ +#define RTC_MODE1_EVCTRL_PEREO6 (1 << RTC_MODE1_EVCTRL_PEREO6_Pos) +#define RTC_MODE1_EVCTRL_PEREO7_Pos 7 /**< \brief (RTC_MODE1_EVCTRL) Periodic Interval 7 Event Output Enable */ +#define RTC_MODE1_EVCTRL_PEREO7 (1 << RTC_MODE1_EVCTRL_PEREO7_Pos) +#define RTC_MODE1_EVCTRL_PEREO_Pos 0 /**< \brief (RTC_MODE1_EVCTRL) Periodic Interval x Event Output Enable */ +#define RTC_MODE1_EVCTRL_PEREO_Msk (0xFFu << RTC_MODE1_EVCTRL_PEREO_Pos) +#define RTC_MODE1_EVCTRL_PEREO(value) ((RTC_MODE1_EVCTRL_PEREO_Msk & ((value) << RTC_MODE1_EVCTRL_PEREO_Pos))) +#define RTC_MODE1_EVCTRL_CMPEO0_Pos 8 /**< \brief (RTC_MODE1_EVCTRL) Compare 0 Event Output Enable */ +#define RTC_MODE1_EVCTRL_CMPEO0 (1 << RTC_MODE1_EVCTRL_CMPEO0_Pos) +#define RTC_MODE1_EVCTRL_CMPEO1_Pos 9 /**< \brief (RTC_MODE1_EVCTRL) Compare 1 Event Output Enable */ +#define RTC_MODE1_EVCTRL_CMPEO1 (1 << RTC_MODE1_EVCTRL_CMPEO1_Pos) +#define RTC_MODE1_EVCTRL_CMPEO_Pos 8 /**< \brief (RTC_MODE1_EVCTRL) Compare x Event Output Enable */ +#define RTC_MODE1_EVCTRL_CMPEO_Msk (0x3u << RTC_MODE1_EVCTRL_CMPEO_Pos) +#define RTC_MODE1_EVCTRL_CMPEO(value) ((RTC_MODE1_EVCTRL_CMPEO_Msk & ((value) << RTC_MODE1_EVCTRL_CMPEO_Pos))) +#define RTC_MODE1_EVCTRL_OVFEO_Pos 15 /**< \brief (RTC_MODE1_EVCTRL) Overflow Event Output Enable */ +#define RTC_MODE1_EVCTRL_OVFEO (0x1u << RTC_MODE1_EVCTRL_OVFEO_Pos) +#define RTC_MODE1_EVCTRL_MASK 0x83FFu /**< \brief (RTC_MODE1_EVCTRL) MASK Register */ + +/* -------- RTC_MODE2_EVCTRL : (RTC Offset: 0x04) (R/W 16) MODE2 MODE2 Event Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t PEREO0:1; /*!< bit: 0 Periodic Interval 0 Event Output Enable */ + uint16_t PEREO1:1; /*!< bit: 1 Periodic Interval 1 Event Output Enable */ + uint16_t PEREO2:1; /*!< bit: 2 Periodic Interval 2 Event Output Enable */ + uint16_t PEREO3:1; /*!< bit: 3 Periodic Interval 3 Event Output Enable */ + uint16_t PEREO4:1; /*!< bit: 4 Periodic Interval 4 Event Output Enable */ + uint16_t PEREO5:1; /*!< bit: 5 Periodic Interval 5 Event Output Enable */ + uint16_t PEREO6:1; /*!< bit: 6 Periodic Interval 6 Event Output Enable */ + uint16_t PEREO7:1; /*!< bit: 7 Periodic Interval 7 Event Output Enable */ + uint16_t ALARMEO0:1; /*!< bit: 8 Alarm 0 Event Output Enable */ + uint16_t :6; /*!< bit: 9..14 Reserved */ + uint16_t OVFEO:1; /*!< bit: 15 Overflow Event Output Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t PEREO:8; /*!< bit: 0.. 7 Periodic Interval x Event Output Enable */ + uint16_t ALARMEO:1; /*!< bit: 8 Alarm x Event Output Enable */ + uint16_t :7; /*!< bit: 9..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_MODE2_EVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE2_EVCTRL_OFFSET 0x04 /**< \brief (RTC_MODE2_EVCTRL offset) MODE2 Event Control */ +#define RTC_MODE2_EVCTRL_RESETVALUE 0x0000 /**< \brief (RTC_MODE2_EVCTRL reset_value) MODE2 Event Control */ + +#define RTC_MODE2_EVCTRL_PEREO0_Pos 0 /**< \brief (RTC_MODE2_EVCTRL) Periodic Interval 0 Event Output Enable */ +#define RTC_MODE2_EVCTRL_PEREO0 (1 << RTC_MODE2_EVCTRL_PEREO0_Pos) +#define RTC_MODE2_EVCTRL_PEREO1_Pos 1 /**< \brief (RTC_MODE2_EVCTRL) Periodic Interval 1 Event Output Enable */ +#define RTC_MODE2_EVCTRL_PEREO1 (1 << RTC_MODE2_EVCTRL_PEREO1_Pos) +#define RTC_MODE2_EVCTRL_PEREO2_Pos 2 /**< \brief (RTC_MODE2_EVCTRL) Periodic Interval 2 Event Output Enable */ +#define RTC_MODE2_EVCTRL_PEREO2 (1 << RTC_MODE2_EVCTRL_PEREO2_Pos) +#define RTC_MODE2_EVCTRL_PEREO3_Pos 3 /**< \brief (RTC_MODE2_EVCTRL) Periodic Interval 3 Event Output Enable */ +#define RTC_MODE2_EVCTRL_PEREO3 (1 << RTC_MODE2_EVCTRL_PEREO3_Pos) +#define RTC_MODE2_EVCTRL_PEREO4_Pos 4 /**< \brief (RTC_MODE2_EVCTRL) Periodic Interval 4 Event Output Enable */ +#define RTC_MODE2_EVCTRL_PEREO4 (1 << RTC_MODE2_EVCTRL_PEREO4_Pos) +#define RTC_MODE2_EVCTRL_PEREO5_Pos 5 /**< \brief (RTC_MODE2_EVCTRL) Periodic Interval 5 Event Output Enable */ +#define RTC_MODE2_EVCTRL_PEREO5 (1 << RTC_MODE2_EVCTRL_PEREO5_Pos) +#define RTC_MODE2_EVCTRL_PEREO6_Pos 6 /**< \brief (RTC_MODE2_EVCTRL) Periodic Interval 6 Event Output Enable */ +#define RTC_MODE2_EVCTRL_PEREO6 (1 << RTC_MODE2_EVCTRL_PEREO6_Pos) +#define RTC_MODE2_EVCTRL_PEREO7_Pos 7 /**< \brief (RTC_MODE2_EVCTRL) Periodic Interval 7 Event Output Enable */ +#define RTC_MODE2_EVCTRL_PEREO7 (1 << RTC_MODE2_EVCTRL_PEREO7_Pos) +#define RTC_MODE2_EVCTRL_PEREO_Pos 0 /**< \brief (RTC_MODE2_EVCTRL) Periodic Interval x Event Output Enable */ +#define RTC_MODE2_EVCTRL_PEREO_Msk (0xFFu << RTC_MODE2_EVCTRL_PEREO_Pos) +#define RTC_MODE2_EVCTRL_PEREO(value) ((RTC_MODE2_EVCTRL_PEREO_Msk & ((value) << RTC_MODE2_EVCTRL_PEREO_Pos))) +#define RTC_MODE2_EVCTRL_ALARMEO0_Pos 8 /**< \brief (RTC_MODE2_EVCTRL) Alarm 0 Event Output Enable */ +#define RTC_MODE2_EVCTRL_ALARMEO0 (1 << RTC_MODE2_EVCTRL_ALARMEO0_Pos) +#define RTC_MODE2_EVCTRL_ALARMEO_Pos 8 /**< \brief (RTC_MODE2_EVCTRL) Alarm x Event Output Enable */ +#define RTC_MODE2_EVCTRL_ALARMEO_Msk (0x1u << RTC_MODE2_EVCTRL_ALARMEO_Pos) +#define RTC_MODE2_EVCTRL_ALARMEO(value) ((RTC_MODE2_EVCTRL_ALARMEO_Msk & ((value) << RTC_MODE2_EVCTRL_ALARMEO_Pos))) +#define RTC_MODE2_EVCTRL_OVFEO_Pos 15 /**< \brief (RTC_MODE2_EVCTRL) Overflow Event Output Enable */ +#define RTC_MODE2_EVCTRL_OVFEO (0x1u << RTC_MODE2_EVCTRL_OVFEO_Pos) +#define RTC_MODE2_EVCTRL_MASK 0x81FFu /**< \brief (RTC_MODE2_EVCTRL) MASK Register */ + +/* -------- RTC_MODE0_INTENCLR : (RTC Offset: 0x06) (R/W 8) MODE0 MODE0 Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CMP0:1; /*!< bit: 0 Compare 0 Interrupt Enable */ + uint8_t :5; /*!< bit: 1.. 5 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 6 Synchronization Ready Interrupt Enable */ + uint8_t OVF:1; /*!< bit: 7 Overflow Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t CMP:1; /*!< bit: 0 Compare x Interrupt Enable */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE0_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE0_INTENCLR_OFFSET 0x06 /**< \brief (RTC_MODE0_INTENCLR offset) MODE0 Interrupt Enable Clear */ +#define RTC_MODE0_INTENCLR_RESETVALUE 0x00 /**< \brief (RTC_MODE0_INTENCLR reset_value) MODE0 Interrupt Enable Clear */ + +#define RTC_MODE0_INTENCLR_CMP0_Pos 0 /**< \brief (RTC_MODE0_INTENCLR) Compare 0 Interrupt Enable */ +#define RTC_MODE0_INTENCLR_CMP0 (1 << RTC_MODE0_INTENCLR_CMP0_Pos) +#define RTC_MODE0_INTENCLR_CMP_Pos 0 /**< \brief (RTC_MODE0_INTENCLR) Compare x Interrupt Enable */ +#define RTC_MODE0_INTENCLR_CMP_Msk (0x1u << RTC_MODE0_INTENCLR_CMP_Pos) +#define RTC_MODE0_INTENCLR_CMP(value) ((RTC_MODE0_INTENCLR_CMP_Msk & ((value) << RTC_MODE0_INTENCLR_CMP_Pos))) +#define RTC_MODE0_INTENCLR_SYNCRDY_Pos 6 /**< \brief (RTC_MODE0_INTENCLR) Synchronization Ready Interrupt Enable */ +#define RTC_MODE0_INTENCLR_SYNCRDY (0x1u << RTC_MODE0_INTENCLR_SYNCRDY_Pos) +#define RTC_MODE0_INTENCLR_OVF_Pos 7 /**< \brief (RTC_MODE0_INTENCLR) Overflow Interrupt Enable */ +#define RTC_MODE0_INTENCLR_OVF (0x1u << RTC_MODE0_INTENCLR_OVF_Pos) +#define RTC_MODE0_INTENCLR_MASK 0xC1u /**< \brief (RTC_MODE0_INTENCLR) MASK Register */ + +/* -------- RTC_MODE1_INTENCLR : (RTC Offset: 0x06) (R/W 8) MODE1 MODE1 Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CMP0:1; /*!< bit: 0 Compare 0 Interrupt Enable */ + uint8_t CMP1:1; /*!< bit: 1 Compare 1 Interrupt Enable */ + uint8_t :4; /*!< bit: 2.. 5 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 6 Synchronization Ready Interrupt Enable */ + uint8_t OVF:1; /*!< bit: 7 Overflow Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t CMP:2; /*!< bit: 0.. 1 Compare x Interrupt Enable */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE1_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE1_INTENCLR_OFFSET 0x06 /**< \brief (RTC_MODE1_INTENCLR offset) MODE1 Interrupt Enable Clear */ +#define RTC_MODE1_INTENCLR_RESETVALUE 0x00 /**< \brief (RTC_MODE1_INTENCLR reset_value) MODE1 Interrupt Enable Clear */ + +#define RTC_MODE1_INTENCLR_CMP0_Pos 0 /**< \brief (RTC_MODE1_INTENCLR) Compare 0 Interrupt Enable */ +#define RTC_MODE1_INTENCLR_CMP0 (1 << RTC_MODE1_INTENCLR_CMP0_Pos) +#define RTC_MODE1_INTENCLR_CMP1_Pos 1 /**< \brief (RTC_MODE1_INTENCLR) Compare 1 Interrupt Enable */ +#define RTC_MODE1_INTENCLR_CMP1 (1 << RTC_MODE1_INTENCLR_CMP1_Pos) +#define RTC_MODE1_INTENCLR_CMP_Pos 0 /**< \brief (RTC_MODE1_INTENCLR) Compare x Interrupt Enable */ +#define RTC_MODE1_INTENCLR_CMP_Msk (0x3u << RTC_MODE1_INTENCLR_CMP_Pos) +#define RTC_MODE1_INTENCLR_CMP(value) ((RTC_MODE1_INTENCLR_CMP_Msk & ((value) << RTC_MODE1_INTENCLR_CMP_Pos))) +#define RTC_MODE1_INTENCLR_SYNCRDY_Pos 6 /**< \brief (RTC_MODE1_INTENCLR) Synchronization Ready Interrupt Enable */ +#define RTC_MODE1_INTENCLR_SYNCRDY (0x1u << RTC_MODE1_INTENCLR_SYNCRDY_Pos) +#define RTC_MODE1_INTENCLR_OVF_Pos 7 /**< \brief (RTC_MODE1_INTENCLR) Overflow Interrupt Enable */ +#define RTC_MODE1_INTENCLR_OVF (0x1u << RTC_MODE1_INTENCLR_OVF_Pos) +#define RTC_MODE1_INTENCLR_MASK 0xC3u /**< \brief (RTC_MODE1_INTENCLR) MASK Register */ + +/* -------- RTC_MODE2_INTENCLR : (RTC Offset: 0x06) (R/W 8) MODE2 MODE2 Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t ALARM0:1; /*!< bit: 0 Alarm 0 Interrupt Enable */ + uint8_t :5; /*!< bit: 1.. 5 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 6 Synchronization Ready Interrupt Enable */ + uint8_t OVF:1; /*!< bit: 7 Overflow Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t ALARM:1; /*!< bit: 0 Alarm x Interrupt Enable */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE2_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE2_INTENCLR_OFFSET 0x06 /**< \brief (RTC_MODE2_INTENCLR offset) MODE2 Interrupt Enable Clear */ +#define RTC_MODE2_INTENCLR_RESETVALUE 0x00 /**< \brief (RTC_MODE2_INTENCLR reset_value) MODE2 Interrupt Enable Clear */ + +#define RTC_MODE2_INTENCLR_ALARM0_Pos 0 /**< \brief (RTC_MODE2_INTENCLR) Alarm 0 Interrupt Enable */ +#define RTC_MODE2_INTENCLR_ALARM0 (1 << RTC_MODE2_INTENCLR_ALARM0_Pos) +#define RTC_MODE2_INTENCLR_ALARM_Pos 0 /**< \brief (RTC_MODE2_INTENCLR) Alarm x Interrupt Enable */ +#define RTC_MODE2_INTENCLR_ALARM_Msk (0x1u << RTC_MODE2_INTENCLR_ALARM_Pos) +#define RTC_MODE2_INTENCLR_ALARM(value) ((RTC_MODE2_INTENCLR_ALARM_Msk & ((value) << RTC_MODE2_INTENCLR_ALARM_Pos))) +#define RTC_MODE2_INTENCLR_SYNCRDY_Pos 6 /**< \brief (RTC_MODE2_INTENCLR) Synchronization Ready Interrupt Enable */ +#define RTC_MODE2_INTENCLR_SYNCRDY (0x1u << RTC_MODE2_INTENCLR_SYNCRDY_Pos) +#define RTC_MODE2_INTENCLR_OVF_Pos 7 /**< \brief (RTC_MODE2_INTENCLR) Overflow Interrupt Enable */ +#define RTC_MODE2_INTENCLR_OVF (0x1u << RTC_MODE2_INTENCLR_OVF_Pos) +#define RTC_MODE2_INTENCLR_MASK 0xC1u /**< \brief (RTC_MODE2_INTENCLR) MASK Register */ + +/* -------- RTC_MODE0_INTENSET : (RTC Offset: 0x07) (R/W 8) MODE0 MODE0 Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CMP0:1; /*!< bit: 0 Compare 0 Interrupt Enable */ + uint8_t :5; /*!< bit: 1.. 5 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 6 Synchronization Ready Interrupt Enable */ + uint8_t OVF:1; /*!< bit: 7 Overflow Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t CMP:1; /*!< bit: 0 Compare x Interrupt Enable */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE0_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE0_INTENSET_OFFSET 0x07 /**< \brief (RTC_MODE0_INTENSET offset) MODE0 Interrupt Enable Set */ +#define RTC_MODE0_INTENSET_RESETVALUE 0x00 /**< \brief (RTC_MODE0_INTENSET reset_value) MODE0 Interrupt Enable Set */ + +#define RTC_MODE0_INTENSET_CMP0_Pos 0 /**< \brief (RTC_MODE0_INTENSET) Compare 0 Interrupt Enable */ +#define RTC_MODE0_INTENSET_CMP0 (1 << RTC_MODE0_INTENSET_CMP0_Pos) +#define RTC_MODE0_INTENSET_CMP_Pos 0 /**< \brief (RTC_MODE0_INTENSET) Compare x Interrupt Enable */ +#define RTC_MODE0_INTENSET_CMP_Msk (0x1u << RTC_MODE0_INTENSET_CMP_Pos) +#define RTC_MODE0_INTENSET_CMP(value) ((RTC_MODE0_INTENSET_CMP_Msk & ((value) << RTC_MODE0_INTENSET_CMP_Pos))) +#define RTC_MODE0_INTENSET_SYNCRDY_Pos 6 /**< \brief (RTC_MODE0_INTENSET) Synchronization Ready Interrupt Enable */ +#define RTC_MODE0_INTENSET_SYNCRDY (0x1u << RTC_MODE0_INTENSET_SYNCRDY_Pos) +#define RTC_MODE0_INTENSET_OVF_Pos 7 /**< \brief (RTC_MODE0_INTENSET) Overflow Interrupt Enable */ +#define RTC_MODE0_INTENSET_OVF (0x1u << RTC_MODE0_INTENSET_OVF_Pos) +#define RTC_MODE0_INTENSET_MASK 0xC1u /**< \brief (RTC_MODE0_INTENSET) MASK Register */ + +/* -------- RTC_MODE1_INTENSET : (RTC Offset: 0x07) (R/W 8) MODE1 MODE1 Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CMP0:1; /*!< bit: 0 Compare 0 Interrupt Enable */ + uint8_t CMP1:1; /*!< bit: 1 Compare 1 Interrupt Enable */ + uint8_t :4; /*!< bit: 2.. 5 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 6 Synchronization Ready Interrupt Enable */ + uint8_t OVF:1; /*!< bit: 7 Overflow Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t CMP:2; /*!< bit: 0.. 1 Compare x Interrupt Enable */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE1_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE1_INTENSET_OFFSET 0x07 /**< \brief (RTC_MODE1_INTENSET offset) MODE1 Interrupt Enable Set */ +#define RTC_MODE1_INTENSET_RESETVALUE 0x00 /**< \brief (RTC_MODE1_INTENSET reset_value) MODE1 Interrupt Enable Set */ + +#define RTC_MODE1_INTENSET_CMP0_Pos 0 /**< \brief (RTC_MODE1_INTENSET) Compare 0 Interrupt Enable */ +#define RTC_MODE1_INTENSET_CMP0 (1 << RTC_MODE1_INTENSET_CMP0_Pos) +#define RTC_MODE1_INTENSET_CMP1_Pos 1 /**< \brief (RTC_MODE1_INTENSET) Compare 1 Interrupt Enable */ +#define RTC_MODE1_INTENSET_CMP1 (1 << RTC_MODE1_INTENSET_CMP1_Pos) +#define RTC_MODE1_INTENSET_CMP_Pos 0 /**< \brief (RTC_MODE1_INTENSET) Compare x Interrupt Enable */ +#define RTC_MODE1_INTENSET_CMP_Msk (0x3u << RTC_MODE1_INTENSET_CMP_Pos) +#define RTC_MODE1_INTENSET_CMP(value) ((RTC_MODE1_INTENSET_CMP_Msk & ((value) << RTC_MODE1_INTENSET_CMP_Pos))) +#define RTC_MODE1_INTENSET_SYNCRDY_Pos 6 /**< \brief (RTC_MODE1_INTENSET) Synchronization Ready Interrupt Enable */ +#define RTC_MODE1_INTENSET_SYNCRDY (0x1u << RTC_MODE1_INTENSET_SYNCRDY_Pos) +#define RTC_MODE1_INTENSET_OVF_Pos 7 /**< \brief (RTC_MODE1_INTENSET) Overflow Interrupt Enable */ +#define RTC_MODE1_INTENSET_OVF (0x1u << RTC_MODE1_INTENSET_OVF_Pos) +#define RTC_MODE1_INTENSET_MASK 0xC3u /**< \brief (RTC_MODE1_INTENSET) MASK Register */ + +/* -------- RTC_MODE2_INTENSET : (RTC Offset: 0x07) (R/W 8) MODE2 MODE2 Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t ALARM0:1; /*!< bit: 0 Alarm 0 Interrupt Enable */ + uint8_t :5; /*!< bit: 1.. 5 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 6 Synchronization Ready Interrupt Enable */ + uint8_t OVF:1; /*!< bit: 7 Overflow Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t ALARM:1; /*!< bit: 0 Alarm x Interrupt Enable */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE2_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE2_INTENSET_OFFSET 0x07 /**< \brief (RTC_MODE2_INTENSET offset) MODE2 Interrupt Enable Set */ +#define RTC_MODE2_INTENSET_RESETVALUE 0x00 /**< \brief (RTC_MODE2_INTENSET reset_value) MODE2 Interrupt Enable Set */ + +#define RTC_MODE2_INTENSET_ALARM0_Pos 0 /**< \brief (RTC_MODE2_INTENSET) Alarm 0 Interrupt Enable */ +#define RTC_MODE2_INTENSET_ALARM0 (1 << RTC_MODE2_INTENSET_ALARM0_Pos) +#define RTC_MODE2_INTENSET_ALARM_Pos 0 /**< \brief (RTC_MODE2_INTENSET) Alarm x Interrupt Enable */ +#define RTC_MODE2_INTENSET_ALARM_Msk (0x1u << RTC_MODE2_INTENSET_ALARM_Pos) +#define RTC_MODE2_INTENSET_ALARM(value) ((RTC_MODE2_INTENSET_ALARM_Msk & ((value) << RTC_MODE2_INTENSET_ALARM_Pos))) +#define RTC_MODE2_INTENSET_SYNCRDY_Pos 6 /**< \brief (RTC_MODE2_INTENSET) Synchronization Ready Interrupt Enable */ +#define RTC_MODE2_INTENSET_SYNCRDY (0x1u << RTC_MODE2_INTENSET_SYNCRDY_Pos) +#define RTC_MODE2_INTENSET_OVF_Pos 7 /**< \brief (RTC_MODE2_INTENSET) Overflow Interrupt Enable */ +#define RTC_MODE2_INTENSET_OVF (0x1u << RTC_MODE2_INTENSET_OVF_Pos) +#define RTC_MODE2_INTENSET_MASK 0xC1u /**< \brief (RTC_MODE2_INTENSET) MASK Register */ + +/* -------- RTC_MODE0_INTFLAG : (RTC Offset: 0x08) (R/W 8) MODE0 MODE0 Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CMP0:1; /*!< bit: 0 Compare 0 */ + uint8_t :5; /*!< bit: 1.. 5 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 6 Synchronization Ready */ + uint8_t OVF:1; /*!< bit: 7 Overflow */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t CMP:1; /*!< bit: 0 Compare x */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE0_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE0_INTFLAG_OFFSET 0x08 /**< \brief (RTC_MODE0_INTFLAG offset) MODE0 Interrupt Flag Status and Clear */ +#define RTC_MODE0_INTFLAG_RESETVALUE 0x00 /**< \brief (RTC_MODE0_INTFLAG reset_value) MODE0 Interrupt Flag Status and Clear */ + +#define RTC_MODE0_INTFLAG_CMP0_Pos 0 /**< \brief (RTC_MODE0_INTFLAG) Compare 0 */ +#define RTC_MODE0_INTFLAG_CMP0 (1 << RTC_MODE0_INTFLAG_CMP0_Pos) +#define RTC_MODE0_INTFLAG_CMP_Pos 0 /**< \brief (RTC_MODE0_INTFLAG) Compare x */ +#define RTC_MODE0_INTFLAG_CMP_Msk (0x1u << RTC_MODE0_INTFLAG_CMP_Pos) +#define RTC_MODE0_INTFLAG_CMP(value) ((RTC_MODE0_INTFLAG_CMP_Msk & ((value) << RTC_MODE0_INTFLAG_CMP_Pos))) +#define RTC_MODE0_INTFLAG_SYNCRDY_Pos 6 /**< \brief (RTC_MODE0_INTFLAG) Synchronization Ready */ +#define RTC_MODE0_INTFLAG_SYNCRDY (0x1u << RTC_MODE0_INTFLAG_SYNCRDY_Pos) +#define RTC_MODE0_INTFLAG_OVF_Pos 7 /**< \brief (RTC_MODE0_INTFLAG) Overflow */ +#define RTC_MODE0_INTFLAG_OVF (0x1u << RTC_MODE0_INTFLAG_OVF_Pos) +#define RTC_MODE0_INTFLAG_MASK 0xC1u /**< \brief (RTC_MODE0_INTFLAG) MASK Register */ + +/* -------- RTC_MODE1_INTFLAG : (RTC Offset: 0x08) (R/W 8) MODE1 MODE1 Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CMP0:1; /*!< bit: 0 Compare 0 */ + uint8_t CMP1:1; /*!< bit: 1 Compare 1 */ + uint8_t :4; /*!< bit: 2.. 5 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 6 Synchronization Ready */ + uint8_t OVF:1; /*!< bit: 7 Overflow */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t CMP:2; /*!< bit: 0.. 1 Compare x */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE1_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE1_INTFLAG_OFFSET 0x08 /**< \brief (RTC_MODE1_INTFLAG offset) MODE1 Interrupt Flag Status and Clear */ +#define RTC_MODE1_INTFLAG_RESETVALUE 0x00 /**< \brief (RTC_MODE1_INTFLAG reset_value) MODE1 Interrupt Flag Status and Clear */ + +#define RTC_MODE1_INTFLAG_CMP0_Pos 0 /**< \brief (RTC_MODE1_INTFLAG) Compare 0 */ +#define RTC_MODE1_INTFLAG_CMP0 (1 << RTC_MODE1_INTFLAG_CMP0_Pos) +#define RTC_MODE1_INTFLAG_CMP1_Pos 1 /**< \brief (RTC_MODE1_INTFLAG) Compare 1 */ +#define RTC_MODE1_INTFLAG_CMP1 (1 << RTC_MODE1_INTFLAG_CMP1_Pos) +#define RTC_MODE1_INTFLAG_CMP_Pos 0 /**< \brief (RTC_MODE1_INTFLAG) Compare x */ +#define RTC_MODE1_INTFLAG_CMP_Msk (0x3u << RTC_MODE1_INTFLAG_CMP_Pos) +#define RTC_MODE1_INTFLAG_CMP(value) ((RTC_MODE1_INTFLAG_CMP_Msk & ((value) << RTC_MODE1_INTFLAG_CMP_Pos))) +#define RTC_MODE1_INTFLAG_SYNCRDY_Pos 6 /**< \brief (RTC_MODE1_INTFLAG) Synchronization Ready */ +#define RTC_MODE1_INTFLAG_SYNCRDY (0x1u << RTC_MODE1_INTFLAG_SYNCRDY_Pos) +#define RTC_MODE1_INTFLAG_OVF_Pos 7 /**< \brief (RTC_MODE1_INTFLAG) Overflow */ +#define RTC_MODE1_INTFLAG_OVF (0x1u << RTC_MODE1_INTFLAG_OVF_Pos) +#define RTC_MODE1_INTFLAG_MASK 0xC3u /**< \brief (RTC_MODE1_INTFLAG) MASK Register */ + +/* -------- RTC_MODE2_INTFLAG : (RTC Offset: 0x08) (R/W 8) MODE2 MODE2 Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t ALARM0:1; /*!< bit: 0 Alarm 0 */ + uint8_t :5; /*!< bit: 1.. 5 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 6 Synchronization Ready */ + uint8_t OVF:1; /*!< bit: 7 Overflow */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t ALARM:1; /*!< bit: 0 Alarm x */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE2_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE2_INTFLAG_OFFSET 0x08 /**< \brief (RTC_MODE2_INTFLAG offset) MODE2 Interrupt Flag Status and Clear */ +#define RTC_MODE2_INTFLAG_RESETVALUE 0x00 /**< \brief (RTC_MODE2_INTFLAG reset_value) MODE2 Interrupt Flag Status and Clear */ + +#define RTC_MODE2_INTFLAG_ALARM0_Pos 0 /**< \brief (RTC_MODE2_INTFLAG) Alarm 0 */ +#define RTC_MODE2_INTFLAG_ALARM0 (1 << RTC_MODE2_INTFLAG_ALARM0_Pos) +#define RTC_MODE2_INTFLAG_ALARM_Pos 0 /**< \brief (RTC_MODE2_INTFLAG) Alarm x */ +#define RTC_MODE2_INTFLAG_ALARM_Msk (0x1u << RTC_MODE2_INTFLAG_ALARM_Pos) +#define RTC_MODE2_INTFLAG_ALARM(value) ((RTC_MODE2_INTFLAG_ALARM_Msk & ((value) << RTC_MODE2_INTFLAG_ALARM_Pos))) +#define RTC_MODE2_INTFLAG_SYNCRDY_Pos 6 /**< \brief (RTC_MODE2_INTFLAG) Synchronization Ready */ +#define RTC_MODE2_INTFLAG_SYNCRDY (0x1u << RTC_MODE2_INTFLAG_SYNCRDY_Pos) +#define RTC_MODE2_INTFLAG_OVF_Pos 7 /**< \brief (RTC_MODE2_INTFLAG) Overflow */ +#define RTC_MODE2_INTFLAG_OVF (0x1u << RTC_MODE2_INTFLAG_OVF_Pos) +#define RTC_MODE2_INTFLAG_MASK 0xC1u /**< \brief (RTC_MODE2_INTFLAG) MASK Register */ + +/* -------- RTC_STATUS : (RTC Offset: 0x0A) (R/W 8) Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :7; /*!< bit: 0.. 6 Reserved */ + uint8_t SYNCBUSY:1; /*!< bit: 7 Synchronization Busy */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_STATUS_OFFSET 0x0A /**< \brief (RTC_STATUS offset) Status */ +#define RTC_STATUS_RESETVALUE 0x00 /**< \brief (RTC_STATUS reset_value) Status */ + +#define RTC_STATUS_SYNCBUSY_Pos 7 /**< \brief (RTC_STATUS) Synchronization Busy */ +#define RTC_STATUS_SYNCBUSY (0x1u << RTC_STATUS_SYNCBUSY_Pos) +#define RTC_STATUS_MASK 0x80u /**< \brief (RTC_STATUS) MASK Register */ + +/* -------- RTC_DBGCTRL : (RTC Offset: 0x0B) (R/W 8) Debug Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DBGRUN:1; /*!< bit: 0 Run During Debug */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_DBGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_DBGCTRL_OFFSET 0x0B /**< \brief (RTC_DBGCTRL offset) Debug Control */ +#define RTC_DBGCTRL_RESETVALUE 0x00 /**< \brief (RTC_DBGCTRL reset_value) Debug Control */ + +#define RTC_DBGCTRL_DBGRUN_Pos 0 /**< \brief (RTC_DBGCTRL) Run During Debug */ +#define RTC_DBGCTRL_DBGRUN (0x1u << RTC_DBGCTRL_DBGRUN_Pos) +#define RTC_DBGCTRL_MASK 0x01u /**< \brief (RTC_DBGCTRL) MASK Register */ + +/* -------- RTC_FREQCORR : (RTC Offset: 0x0C) (R/W 8) Frequency Correction -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t VALUE:7; /*!< bit: 0.. 6 Correction Value */ + uint8_t SIGN:1; /*!< bit: 7 Correction Sign */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_FREQCORR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_FREQCORR_OFFSET 0x0C /**< \brief (RTC_FREQCORR offset) Frequency Correction */ +#define RTC_FREQCORR_RESETVALUE 0x00 /**< \brief (RTC_FREQCORR reset_value) Frequency Correction */ + +#define RTC_FREQCORR_VALUE_Pos 0 /**< \brief (RTC_FREQCORR) Correction Value */ +#define RTC_FREQCORR_VALUE_Msk (0x7Fu << RTC_FREQCORR_VALUE_Pos) +#define RTC_FREQCORR_VALUE(value) ((RTC_FREQCORR_VALUE_Msk & ((value) << RTC_FREQCORR_VALUE_Pos))) +#define RTC_FREQCORR_SIGN_Pos 7 /**< \brief (RTC_FREQCORR) Correction Sign */ +#define RTC_FREQCORR_SIGN (0x1u << RTC_FREQCORR_SIGN_Pos) +#define RTC_FREQCORR_MASK 0xFFu /**< \brief (RTC_FREQCORR) MASK Register */ + +/* -------- RTC_MODE0_COUNT : (RTC Offset: 0x10) (R/W 32) MODE0 MODE0 Counter Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t COUNT:32; /*!< bit: 0..31 Counter Value */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} RTC_MODE0_COUNT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE0_COUNT_OFFSET 0x10 /**< \brief (RTC_MODE0_COUNT offset) MODE0 Counter Value */ +#define RTC_MODE0_COUNT_RESETVALUE 0x00000000 /**< \brief (RTC_MODE0_COUNT reset_value) MODE0 Counter Value */ + +#define RTC_MODE0_COUNT_COUNT_Pos 0 /**< \brief (RTC_MODE0_COUNT) Counter Value */ +#define RTC_MODE0_COUNT_COUNT_Msk (0xFFFFFFFFu << RTC_MODE0_COUNT_COUNT_Pos) +#define RTC_MODE0_COUNT_COUNT(value) ((RTC_MODE0_COUNT_COUNT_Msk & ((value) << RTC_MODE0_COUNT_COUNT_Pos))) +#define RTC_MODE0_COUNT_MASK 0xFFFFFFFFu /**< \brief (RTC_MODE0_COUNT) MASK Register */ + +/* -------- RTC_MODE1_COUNT : (RTC Offset: 0x10) (R/W 16) MODE1 MODE1 Counter Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t COUNT:16; /*!< bit: 0..15 Counter Value */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_MODE1_COUNT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE1_COUNT_OFFSET 0x10 /**< \brief (RTC_MODE1_COUNT offset) MODE1 Counter Value */ +#define RTC_MODE1_COUNT_RESETVALUE 0x0000 /**< \brief (RTC_MODE1_COUNT reset_value) MODE1 Counter Value */ + +#define RTC_MODE1_COUNT_COUNT_Pos 0 /**< \brief (RTC_MODE1_COUNT) Counter Value */ +#define RTC_MODE1_COUNT_COUNT_Msk (0xFFFFu << RTC_MODE1_COUNT_COUNT_Pos) +#define RTC_MODE1_COUNT_COUNT(value) ((RTC_MODE1_COUNT_COUNT_Msk & ((value) << RTC_MODE1_COUNT_COUNT_Pos))) +#define RTC_MODE1_COUNT_MASK 0xFFFFu /**< \brief (RTC_MODE1_COUNT) MASK Register */ + +/* -------- RTC_MODE2_CLOCK : (RTC Offset: 0x10) (R/W 32) MODE2 MODE2 Clock Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SECOND:6; /*!< bit: 0.. 5 Second */ + uint32_t MINUTE:6; /*!< bit: 6..11 Minute */ + uint32_t HOUR:5; /*!< bit: 12..16 Hour */ + uint32_t DAY:5; /*!< bit: 17..21 Day */ + uint32_t MONTH:4; /*!< bit: 22..25 Month */ + uint32_t YEAR:6; /*!< bit: 26..31 Year */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} RTC_MODE2_CLOCK_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE2_CLOCK_OFFSET 0x10 /**< \brief (RTC_MODE2_CLOCK offset) MODE2 Clock Value */ +#define RTC_MODE2_CLOCK_RESETVALUE 0x00000000 /**< \brief (RTC_MODE2_CLOCK reset_value) MODE2 Clock Value */ + +#define RTC_MODE2_CLOCK_SECOND_Pos 0 /**< \brief (RTC_MODE2_CLOCK) Second */ +#define RTC_MODE2_CLOCK_SECOND_Msk (0x3Fu << RTC_MODE2_CLOCK_SECOND_Pos) +#define RTC_MODE2_CLOCK_SECOND(value) ((RTC_MODE2_CLOCK_SECOND_Msk & ((value) << RTC_MODE2_CLOCK_SECOND_Pos))) +#define RTC_MODE2_CLOCK_MINUTE_Pos 6 /**< \brief (RTC_MODE2_CLOCK) Minute */ +#define RTC_MODE2_CLOCK_MINUTE_Msk (0x3Fu << RTC_MODE2_CLOCK_MINUTE_Pos) +#define RTC_MODE2_CLOCK_MINUTE(value) ((RTC_MODE2_CLOCK_MINUTE_Msk & ((value) << RTC_MODE2_CLOCK_MINUTE_Pos))) +#define RTC_MODE2_CLOCK_HOUR_Pos 12 /**< \brief (RTC_MODE2_CLOCK) Hour */ +#define RTC_MODE2_CLOCK_HOUR_Msk (0x1Fu << RTC_MODE2_CLOCK_HOUR_Pos) +#define RTC_MODE2_CLOCK_HOUR(value) ((RTC_MODE2_CLOCK_HOUR_Msk & ((value) << RTC_MODE2_CLOCK_HOUR_Pos))) +#define RTC_MODE2_CLOCK_HOUR_PM_Val 0x10u /**< \brief (RTC_MODE2_CLOCK) Afternoon Hour */ +#define RTC_MODE2_CLOCK_HOUR_PM (RTC_MODE2_CLOCK_HOUR_PM_Val << RTC_MODE2_CLOCK_HOUR_Pos) +#define RTC_MODE2_CLOCK_DAY_Pos 17 /**< \brief (RTC_MODE2_CLOCK) Day */ +#define RTC_MODE2_CLOCK_DAY_Msk (0x1Fu << RTC_MODE2_CLOCK_DAY_Pos) +#define RTC_MODE2_CLOCK_DAY(value) ((RTC_MODE2_CLOCK_DAY_Msk & ((value) << RTC_MODE2_CLOCK_DAY_Pos))) +#define RTC_MODE2_CLOCK_MONTH_Pos 22 /**< \brief (RTC_MODE2_CLOCK) Month */ +#define RTC_MODE2_CLOCK_MONTH_Msk (0xFu << RTC_MODE2_CLOCK_MONTH_Pos) +#define RTC_MODE2_CLOCK_MONTH(value) ((RTC_MODE2_CLOCK_MONTH_Msk & ((value) << RTC_MODE2_CLOCK_MONTH_Pos))) +#define RTC_MODE2_CLOCK_YEAR_Pos 26 /**< \brief (RTC_MODE2_CLOCK) Year */ +#define RTC_MODE2_CLOCK_YEAR_Msk (0x3Fu << RTC_MODE2_CLOCK_YEAR_Pos) +#define RTC_MODE2_CLOCK_YEAR(value) ((RTC_MODE2_CLOCK_YEAR_Msk & ((value) << RTC_MODE2_CLOCK_YEAR_Pos))) +#define RTC_MODE2_CLOCK_MASK 0xFFFFFFFFu /**< \brief (RTC_MODE2_CLOCK) MASK Register */ + +/* -------- RTC_MODE1_PER : (RTC Offset: 0x14) (R/W 16) MODE1 MODE1 Counter Period -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t PER:16; /*!< bit: 0..15 Counter Period */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_MODE1_PER_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE1_PER_OFFSET 0x14 /**< \brief (RTC_MODE1_PER offset) MODE1 Counter Period */ +#define RTC_MODE1_PER_RESETVALUE 0x0000 /**< \brief (RTC_MODE1_PER reset_value) MODE1 Counter Period */ + +#define RTC_MODE1_PER_PER_Pos 0 /**< \brief (RTC_MODE1_PER) Counter Period */ +#define RTC_MODE1_PER_PER_Msk (0xFFFFu << RTC_MODE1_PER_PER_Pos) +#define RTC_MODE1_PER_PER(value) ((RTC_MODE1_PER_PER_Msk & ((value) << RTC_MODE1_PER_PER_Pos))) +#define RTC_MODE1_PER_MASK 0xFFFFu /**< \brief (RTC_MODE1_PER) MASK Register */ + +/* -------- RTC_MODE0_COMP : (RTC Offset: 0x18) (R/W 32) MODE0 MODE0 Compare n Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t COMP:32; /*!< bit: 0..31 Compare Value */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} RTC_MODE0_COMP_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE0_COMP_OFFSET 0x18 /**< \brief (RTC_MODE0_COMP offset) MODE0 Compare n Value */ +#define RTC_MODE0_COMP_RESETVALUE 0x00000000 /**< \brief (RTC_MODE0_COMP reset_value) MODE0 Compare n Value */ + +#define RTC_MODE0_COMP_COMP_Pos 0 /**< \brief (RTC_MODE0_COMP) Compare Value */ +#define RTC_MODE0_COMP_COMP_Msk (0xFFFFFFFFu << RTC_MODE0_COMP_COMP_Pos) +#define RTC_MODE0_COMP_COMP(value) ((RTC_MODE0_COMP_COMP_Msk & ((value) << RTC_MODE0_COMP_COMP_Pos))) +#define RTC_MODE0_COMP_MASK 0xFFFFFFFFu /**< \brief (RTC_MODE0_COMP) MASK Register */ + +/* -------- RTC_MODE1_COMP : (RTC Offset: 0x18) (R/W 16) MODE1 MODE1 Compare n Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t COMP:16; /*!< bit: 0..15 Compare Value */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} RTC_MODE1_COMP_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE1_COMP_OFFSET 0x18 /**< \brief (RTC_MODE1_COMP offset) MODE1 Compare n Value */ +#define RTC_MODE1_COMP_RESETVALUE 0x0000 /**< \brief (RTC_MODE1_COMP reset_value) MODE1 Compare n Value */ + +#define RTC_MODE1_COMP_COMP_Pos 0 /**< \brief (RTC_MODE1_COMP) Compare Value */ +#define RTC_MODE1_COMP_COMP_Msk (0xFFFFu << RTC_MODE1_COMP_COMP_Pos) +#define RTC_MODE1_COMP_COMP(value) ((RTC_MODE1_COMP_COMP_Msk & ((value) << RTC_MODE1_COMP_COMP_Pos))) +#define RTC_MODE1_COMP_MASK 0xFFFFu /**< \brief (RTC_MODE1_COMP) MASK Register */ + +/* -------- RTC_MODE2_ALARM : (RTC Offset: 0x18) (R/W 32) MODE2 MODE2_ALARM Alarm n Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SECOND:6; /*!< bit: 0.. 5 Second */ + uint32_t MINUTE:6; /*!< bit: 6..11 Minute */ + uint32_t HOUR:5; /*!< bit: 12..16 Hour */ + uint32_t DAY:5; /*!< bit: 17..21 Day */ + uint32_t MONTH:4; /*!< bit: 22..25 Month */ + uint32_t YEAR:6; /*!< bit: 26..31 Year */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} RTC_MODE2_ALARM_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE2_ALARM_OFFSET 0x18 /**< \brief (RTC_MODE2_ALARM offset) MODE2_ALARM Alarm n Value */ +#define RTC_MODE2_ALARM_RESETVALUE 0x00000000 /**< \brief (RTC_MODE2_ALARM reset_value) MODE2_ALARM Alarm n Value */ + +#define RTC_MODE2_ALARM_SECOND_Pos 0 /**< \brief (RTC_MODE2_ALARM) Second */ +#define RTC_MODE2_ALARM_SECOND_Msk (0x3Fu << RTC_MODE2_ALARM_SECOND_Pos) +#define RTC_MODE2_ALARM_SECOND(value) ((RTC_MODE2_ALARM_SECOND_Msk & ((value) << RTC_MODE2_ALARM_SECOND_Pos))) +#define RTC_MODE2_ALARM_MINUTE_Pos 6 /**< \brief (RTC_MODE2_ALARM) Minute */ +#define RTC_MODE2_ALARM_MINUTE_Msk (0x3Fu << RTC_MODE2_ALARM_MINUTE_Pos) +#define RTC_MODE2_ALARM_MINUTE(value) ((RTC_MODE2_ALARM_MINUTE_Msk & ((value) << RTC_MODE2_ALARM_MINUTE_Pos))) +#define RTC_MODE2_ALARM_HOUR_Pos 12 /**< \brief (RTC_MODE2_ALARM) Hour */ +#define RTC_MODE2_ALARM_HOUR_Msk (0x1Fu << RTC_MODE2_ALARM_HOUR_Pos) +#define RTC_MODE2_ALARM_HOUR(value) ((RTC_MODE2_ALARM_HOUR_Msk & ((value) << RTC_MODE2_ALARM_HOUR_Pos))) +#define RTC_MODE2_ALARM_DAY_Pos 17 /**< \brief (RTC_MODE2_ALARM) Day */ +#define RTC_MODE2_ALARM_DAY_Msk (0x1Fu << RTC_MODE2_ALARM_DAY_Pos) +#define RTC_MODE2_ALARM_DAY(value) ((RTC_MODE2_ALARM_DAY_Msk & ((value) << RTC_MODE2_ALARM_DAY_Pos))) +#define RTC_MODE2_ALARM_MONTH_Pos 22 /**< \brief (RTC_MODE2_ALARM) Month */ +#define RTC_MODE2_ALARM_MONTH_Msk (0xFu << RTC_MODE2_ALARM_MONTH_Pos) +#define RTC_MODE2_ALARM_MONTH(value) ((RTC_MODE2_ALARM_MONTH_Msk & ((value) << RTC_MODE2_ALARM_MONTH_Pos))) +#define RTC_MODE2_ALARM_YEAR_Pos 26 /**< \brief (RTC_MODE2_ALARM) Year */ +#define RTC_MODE2_ALARM_YEAR_Msk (0x3Fu << RTC_MODE2_ALARM_YEAR_Pos) +#define RTC_MODE2_ALARM_YEAR(value) ((RTC_MODE2_ALARM_YEAR_Msk & ((value) << RTC_MODE2_ALARM_YEAR_Pos))) +#define RTC_MODE2_ALARM_MASK 0xFFFFFFFFu /**< \brief (RTC_MODE2_ALARM) MASK Register */ + +/* -------- RTC_MODE2_MASK : (RTC Offset: 0x1C) (R/W 8) MODE2 MODE2_ALARM Alarm n Mask -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SEL:3; /*!< bit: 0.. 2 Alarm Mask Selection */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} RTC_MODE2_MASK_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define RTC_MODE2_MASK_OFFSET 0x1C /**< \brief (RTC_MODE2_MASK offset) MODE2_ALARM Alarm n Mask */ +#define RTC_MODE2_MASK_RESETVALUE 0x00 /**< \brief (RTC_MODE2_MASK reset_value) MODE2_ALARM Alarm n Mask */ + +#define RTC_MODE2_MASK_SEL_Pos 0 /**< \brief (RTC_MODE2_MASK) Alarm Mask Selection */ +#define RTC_MODE2_MASK_SEL_Msk (0x7u << RTC_MODE2_MASK_SEL_Pos) +#define RTC_MODE2_MASK_SEL(value) ((RTC_MODE2_MASK_SEL_Msk & ((value) << RTC_MODE2_MASK_SEL_Pos))) +#define RTC_MODE2_MASK_SEL_OFF_Val 0x0u /**< \brief (RTC_MODE2_MASK) Alarm Disabled */ +#define RTC_MODE2_MASK_SEL_SS_Val 0x1u /**< \brief (RTC_MODE2_MASK) Match seconds only */ +#define RTC_MODE2_MASK_SEL_MMSS_Val 0x2u /**< \brief (RTC_MODE2_MASK) Match seconds and minutes only */ +#define RTC_MODE2_MASK_SEL_HHMMSS_Val 0x3u /**< \brief (RTC_MODE2_MASK) Match seconds, minutes, and hours only */ +#define RTC_MODE2_MASK_SEL_DDHHMMSS_Val 0x4u /**< \brief (RTC_MODE2_MASK) Match seconds, minutes, hours, and days only */ +#define RTC_MODE2_MASK_SEL_MMDDHHMMSS_Val 0x5u /**< \brief (RTC_MODE2_MASK) Match seconds, minutes, hours, days, and months only */ +#define RTC_MODE2_MASK_SEL_YYMMDDHHMMSS_Val 0x6u /**< \brief (RTC_MODE2_MASK) Match seconds, minutes, hours, days, months, and years */ +#define RTC_MODE2_MASK_SEL_OFF (RTC_MODE2_MASK_SEL_OFF_Val << RTC_MODE2_MASK_SEL_Pos) +#define RTC_MODE2_MASK_SEL_SS (RTC_MODE2_MASK_SEL_SS_Val << RTC_MODE2_MASK_SEL_Pos) +#define RTC_MODE2_MASK_SEL_MMSS (RTC_MODE2_MASK_SEL_MMSS_Val << RTC_MODE2_MASK_SEL_Pos) +#define RTC_MODE2_MASK_SEL_HHMMSS (RTC_MODE2_MASK_SEL_HHMMSS_Val << RTC_MODE2_MASK_SEL_Pos) +#define RTC_MODE2_MASK_SEL_DDHHMMSS (RTC_MODE2_MASK_SEL_DDHHMMSS_Val << RTC_MODE2_MASK_SEL_Pos) +#define RTC_MODE2_MASK_SEL_MMDDHHMMSS (RTC_MODE2_MASK_SEL_MMDDHHMMSS_Val << RTC_MODE2_MASK_SEL_Pos) +#define RTC_MODE2_MASK_SEL_YYMMDDHHMMSS (RTC_MODE2_MASK_SEL_YYMMDDHHMMSS_Val << RTC_MODE2_MASK_SEL_Pos) +#define RTC_MODE2_MASK_MASK 0x07u /**< \brief (RTC_MODE2_MASK) MASK Register */ + +/** \brief RtcMode2Alarm hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO RTC_MODE2_ALARM_Type ALARM; /**< \brief Offset: 0x00 (R/W 32) MODE2_ALARM Alarm n Value */ + __IO RTC_MODE2_MASK_Type MASK; /**< \brief Offset: 0x04 (R/W 8) MODE2_ALARM Alarm n Mask */ + RoReg8 Reserved1[0x3]; +} RtcMode2Alarm; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief RTC_MODE0 hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* 32-bit Counter with Single 32-bit Compare */ + __IO RTC_MODE0_CTRL_Type CTRL; /**< \brief Offset: 0x00 (R/W 16) MODE0 Control */ + __IO RTC_READREQ_Type READREQ; /**< \brief Offset: 0x02 (R/W 16) Read Request */ + __IO RTC_MODE0_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x04 (R/W 16) MODE0 Event Control */ + __IO RTC_MODE0_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x06 (R/W 8) MODE0 Interrupt Enable Clear */ + __IO RTC_MODE0_INTENSET_Type INTENSET; /**< \brief Offset: 0x07 (R/W 8) MODE0 Interrupt Enable Set */ + __IO RTC_MODE0_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x08 (R/W 8) MODE0 Interrupt Flag Status and Clear */ + RoReg8 Reserved1[0x1]; + __IO RTC_STATUS_Type STATUS; /**< \brief Offset: 0x0A (R/W 8) Status */ + __IO RTC_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x0B (R/W 8) Debug Control */ + __IO RTC_FREQCORR_Type FREQCORR; /**< \brief Offset: 0x0C (R/W 8) Frequency Correction */ + RoReg8 Reserved2[0x3]; + __IO RTC_MODE0_COUNT_Type COUNT; /**< \brief Offset: 0x10 (R/W 32) MODE0 Counter Value */ + RoReg8 Reserved3[0x4]; + __IO RTC_MODE0_COMP_Type COMP[1]; /**< \brief Offset: 0x18 (R/W 32) MODE0 Compare n Value */ +} RtcMode0; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief RTC_MODE1 hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* 16-bit Counter with Two 16-bit Compares */ + __IO RTC_MODE1_CTRL_Type CTRL; /**< \brief Offset: 0x00 (R/W 16) MODE1 Control */ + __IO RTC_READREQ_Type READREQ; /**< \brief Offset: 0x02 (R/W 16) Read Request */ + __IO RTC_MODE1_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x04 (R/W 16) MODE1 Event Control */ + __IO RTC_MODE1_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x06 (R/W 8) MODE1 Interrupt Enable Clear */ + __IO RTC_MODE1_INTENSET_Type INTENSET; /**< \brief Offset: 0x07 (R/W 8) MODE1 Interrupt Enable Set */ + __IO RTC_MODE1_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x08 (R/W 8) MODE1 Interrupt Flag Status and Clear */ + RoReg8 Reserved1[0x1]; + __IO RTC_STATUS_Type STATUS; /**< \brief Offset: 0x0A (R/W 8) Status */ + __IO RTC_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x0B (R/W 8) Debug Control */ + __IO RTC_FREQCORR_Type FREQCORR; /**< \brief Offset: 0x0C (R/W 8) Frequency Correction */ + RoReg8 Reserved2[0x3]; + __IO RTC_MODE1_COUNT_Type COUNT; /**< \brief Offset: 0x10 (R/W 16) MODE1 Counter Value */ + RoReg8 Reserved3[0x2]; + __IO RTC_MODE1_PER_Type PER; /**< \brief Offset: 0x14 (R/W 16) MODE1 Counter Period */ + RoReg8 Reserved4[0x2]; + __IO RTC_MODE1_COMP_Type COMP[2]; /**< \brief Offset: 0x18 (R/W 16) MODE1 Compare n Value */ +} RtcMode1; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief RTC_MODE2 hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* Clock/Calendar with Alarm */ + __IO RTC_MODE2_CTRL_Type CTRL; /**< \brief Offset: 0x00 (R/W 16) MODE2 Control */ + __IO RTC_READREQ_Type READREQ; /**< \brief Offset: 0x02 (R/W 16) Read Request */ + __IO RTC_MODE2_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x04 (R/W 16) MODE2 Event Control */ + __IO RTC_MODE2_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x06 (R/W 8) MODE2 Interrupt Enable Clear */ + __IO RTC_MODE2_INTENSET_Type INTENSET; /**< \brief Offset: 0x07 (R/W 8) MODE2 Interrupt Enable Set */ + __IO RTC_MODE2_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x08 (R/W 8) MODE2 Interrupt Flag Status and Clear */ + RoReg8 Reserved1[0x1]; + __IO RTC_STATUS_Type STATUS; /**< \brief Offset: 0x0A (R/W 8) Status */ + __IO RTC_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x0B (R/W 8) Debug Control */ + __IO RTC_FREQCORR_Type FREQCORR; /**< \brief Offset: 0x0C (R/W 8) Frequency Correction */ + RoReg8 Reserved2[0x3]; + __IO RTC_MODE2_CLOCK_Type CLOCK; /**< \brief Offset: 0x10 (R/W 32) MODE2 Clock Value */ + RoReg8 Reserved3[0x4]; + RtcMode2Alarm Mode2Alarm[1]; /**< \brief Offset: 0x18 RtcMode2Alarm groups [ALARM_NUM] */ +} RtcMode2; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + RtcMode0 MODE0; /**< \brief Offset: 0x00 32-bit Counter with Single 32-bit Compare */ + RtcMode1 MODE1; /**< \brief Offset: 0x00 16-bit Counter with Two 16-bit Compares */ + RtcMode2 MODE2; /**< \brief Offset: 0x00 Clock/Calendar with Alarm */ +} Rtc; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_RTC_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/sercom.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/sercom.h new file mode 100755 index 0000000..c27d9da --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/sercom.h @@ -0,0 +1,1508 @@ +/** + * \file + * + * \brief Component description for SERCOM + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_SERCOM_COMPONENT_ +#define _SAMD21_SERCOM_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR SERCOM */ +/* ========================================================================== */ +/** \addtogroup SAMD21_SERCOM Serial Communication Interface */ +/*@{*/ + +#define SERCOM_U2201 +#define REV_SERCOM 0x200 + +/* -------- SERCOM_I2CM_CTRLA : (SERCOM Offset: 0x00) (R/W 32) I2CM I2CM Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Software Reset */ + uint32_t ENABLE:1; /*!< bit: 1 Enable */ + uint32_t MODE:3; /*!< bit: 2.. 4 Operating Mode */ + uint32_t :2; /*!< bit: 5.. 6 Reserved */ + uint32_t RUNSTDBY:1; /*!< bit: 7 Run in Standby */ + uint32_t :8; /*!< bit: 8..15 Reserved */ + uint32_t PINOUT:1; /*!< bit: 16 Pin Usage */ + uint32_t :3; /*!< bit: 17..19 Reserved */ + uint32_t SDAHOLD:2; /*!< bit: 20..21 SDA Hold Time */ + uint32_t MEXTTOEN:1; /*!< bit: 22 Master SCL Low Extend Timeout */ + uint32_t SEXTTOEN:1; /*!< bit: 23 Slave SCL Low Extend Timeout */ + uint32_t SPEED:2; /*!< bit: 24..25 Transfer Speed */ + uint32_t :1; /*!< bit: 26 Reserved */ + uint32_t SCLSM:1; /*!< bit: 27 SCL Clock Stretch Mode */ + uint32_t INACTOUT:2; /*!< bit: 28..29 Inactive Time-Out */ + uint32_t LOWTOUTEN:1; /*!< bit: 30 SCL Low Timeout Enable */ + uint32_t :1; /*!< bit: 31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_CTRLA_OFFSET 0x00 /**< \brief (SERCOM_I2CM_CTRLA offset) I2CM Control A */ +#define SERCOM_I2CM_CTRLA_RESETVALUE 0x00000000 /**< \brief (SERCOM_I2CM_CTRLA reset_value) I2CM Control A */ + +#define SERCOM_I2CM_CTRLA_SWRST_Pos 0 /**< \brief (SERCOM_I2CM_CTRLA) Software Reset */ +#define SERCOM_I2CM_CTRLA_SWRST (0x1u << SERCOM_I2CM_CTRLA_SWRST_Pos) +#define SERCOM_I2CM_CTRLA_ENABLE_Pos 1 /**< \brief (SERCOM_I2CM_CTRLA) Enable */ +#define SERCOM_I2CM_CTRLA_ENABLE (0x1u << SERCOM_I2CM_CTRLA_ENABLE_Pos) +#define SERCOM_I2CM_CTRLA_MODE_Pos 2 /**< \brief (SERCOM_I2CM_CTRLA) Operating Mode */ +#define SERCOM_I2CM_CTRLA_MODE_Msk (0x7u << SERCOM_I2CM_CTRLA_MODE_Pos) +#define SERCOM_I2CM_CTRLA_MODE(value) ((SERCOM_I2CM_CTRLA_MODE_Msk & ((value) << SERCOM_I2CM_CTRLA_MODE_Pos))) +#define SERCOM_I2CM_CTRLA_MODE_USART_EXT_CLK_Val 0x0u /**< \brief (SERCOM_I2CM_CTRLA) USART mode with external clock */ +#define SERCOM_I2CM_CTRLA_MODE_USART_INT_CLK_Val 0x1u /**< \brief (SERCOM_I2CM_CTRLA) USART mode with internal clock */ +#define SERCOM_I2CM_CTRLA_MODE_SPI_SLAVE_Val 0x2u /**< \brief (SERCOM_I2CM_CTRLA) SPI mode with external clock */ +#define SERCOM_I2CM_CTRLA_MODE_SPI_MASTER_Val 0x3u /**< \brief (SERCOM_I2CM_CTRLA) SPI mode with internal clock */ +#define SERCOM_I2CM_CTRLA_MODE_I2C_SLAVE_Val 0x4u /**< \brief (SERCOM_I2CM_CTRLA) I2C mode with external clock */ +#define SERCOM_I2CM_CTRLA_MODE_I2C_MASTER_Val 0x5u /**< \brief (SERCOM_I2CM_CTRLA) I2C mode with internal clock */ +#define SERCOM_I2CM_CTRLA_MODE_USART_EXT_CLK (SERCOM_I2CM_CTRLA_MODE_USART_EXT_CLK_Val << SERCOM_I2CM_CTRLA_MODE_Pos) +#define SERCOM_I2CM_CTRLA_MODE_USART_INT_CLK (SERCOM_I2CM_CTRLA_MODE_USART_INT_CLK_Val << SERCOM_I2CM_CTRLA_MODE_Pos) +#define SERCOM_I2CM_CTRLA_MODE_SPI_SLAVE (SERCOM_I2CM_CTRLA_MODE_SPI_SLAVE_Val << SERCOM_I2CM_CTRLA_MODE_Pos) +#define SERCOM_I2CM_CTRLA_MODE_SPI_MASTER (SERCOM_I2CM_CTRLA_MODE_SPI_MASTER_Val << SERCOM_I2CM_CTRLA_MODE_Pos) +#define SERCOM_I2CM_CTRLA_MODE_I2C_SLAVE (SERCOM_I2CM_CTRLA_MODE_I2C_SLAVE_Val << SERCOM_I2CM_CTRLA_MODE_Pos) +#define SERCOM_I2CM_CTRLA_MODE_I2C_MASTER (SERCOM_I2CM_CTRLA_MODE_I2C_MASTER_Val << SERCOM_I2CM_CTRLA_MODE_Pos) +#define SERCOM_I2CM_CTRLA_RUNSTDBY_Pos 7 /**< \brief (SERCOM_I2CM_CTRLA) Run in Standby */ +#define SERCOM_I2CM_CTRLA_RUNSTDBY (0x1u << SERCOM_I2CM_CTRLA_RUNSTDBY_Pos) +#define SERCOM_I2CM_CTRLA_PINOUT_Pos 16 /**< \brief (SERCOM_I2CM_CTRLA) Pin Usage */ +#define SERCOM_I2CM_CTRLA_PINOUT (0x1u << SERCOM_I2CM_CTRLA_PINOUT_Pos) +#define SERCOM_I2CM_CTRLA_SDAHOLD_Pos 20 /**< \brief (SERCOM_I2CM_CTRLA) SDA Hold Time */ +#define SERCOM_I2CM_CTRLA_SDAHOLD_Msk (0x3u << SERCOM_I2CM_CTRLA_SDAHOLD_Pos) +#define SERCOM_I2CM_CTRLA_SDAHOLD(value) ((SERCOM_I2CM_CTRLA_SDAHOLD_Msk & ((value) << SERCOM_I2CM_CTRLA_SDAHOLD_Pos))) +#define SERCOM_I2CM_CTRLA_MEXTTOEN_Pos 22 /**< \brief (SERCOM_I2CM_CTRLA) Master SCL Low Extend Timeout */ +#define SERCOM_I2CM_CTRLA_MEXTTOEN (0x1u << SERCOM_I2CM_CTRLA_MEXTTOEN_Pos) +#define SERCOM_I2CM_CTRLA_SEXTTOEN_Pos 23 /**< \brief (SERCOM_I2CM_CTRLA) Slave SCL Low Extend Timeout */ +#define SERCOM_I2CM_CTRLA_SEXTTOEN (0x1u << SERCOM_I2CM_CTRLA_SEXTTOEN_Pos) +#define SERCOM_I2CM_CTRLA_SPEED_Pos 24 /**< \brief (SERCOM_I2CM_CTRLA) Transfer Speed */ +#define SERCOM_I2CM_CTRLA_SPEED_Msk (0x3u << SERCOM_I2CM_CTRLA_SPEED_Pos) +#define SERCOM_I2CM_CTRLA_SPEED(value) ((SERCOM_I2CM_CTRLA_SPEED_Msk & ((value) << SERCOM_I2CM_CTRLA_SPEED_Pos))) +#define SERCOM_I2CM_CTRLA_SCLSM_Pos 27 /**< \brief (SERCOM_I2CM_CTRLA) SCL Clock Stretch Mode */ +#define SERCOM_I2CM_CTRLA_SCLSM (0x1u << SERCOM_I2CM_CTRLA_SCLSM_Pos) +#define SERCOM_I2CM_CTRLA_INACTOUT_Pos 28 /**< \brief (SERCOM_I2CM_CTRLA) Inactive Time-Out */ +#define SERCOM_I2CM_CTRLA_INACTOUT_Msk (0x3u << SERCOM_I2CM_CTRLA_INACTOUT_Pos) +#define SERCOM_I2CM_CTRLA_INACTOUT(value) ((SERCOM_I2CM_CTRLA_INACTOUT_Msk & ((value) << SERCOM_I2CM_CTRLA_INACTOUT_Pos))) +#define SERCOM_I2CM_CTRLA_LOWTOUTEN_Pos 30 /**< \brief (SERCOM_I2CM_CTRLA) SCL Low Timeout Enable */ +#define SERCOM_I2CM_CTRLA_LOWTOUTEN (0x1u << SERCOM_I2CM_CTRLA_LOWTOUTEN_Pos) +#define SERCOM_I2CM_CTRLA_MASK 0x7BF1009Fu /**< \brief (SERCOM_I2CM_CTRLA) MASK Register */ + +/* -------- SERCOM_I2CS_CTRLA : (SERCOM Offset: 0x00) (R/W 32) I2CS I2CS Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Software Reset */ + uint32_t ENABLE:1; /*!< bit: 1 Enable */ + uint32_t MODE:3; /*!< bit: 2.. 4 Operating Mode */ + uint32_t :2; /*!< bit: 5.. 6 Reserved */ + uint32_t RUNSTDBY:1; /*!< bit: 7 Run during Standby */ + uint32_t :8; /*!< bit: 8..15 Reserved */ + uint32_t PINOUT:1; /*!< bit: 16 Pin Usage */ + uint32_t :3; /*!< bit: 17..19 Reserved */ + uint32_t SDAHOLD:2; /*!< bit: 20..21 SDA Hold Time */ + uint32_t :1; /*!< bit: 22 Reserved */ + uint32_t SEXTTOEN:1; /*!< bit: 23 Slave SCL Low Extend Timeout */ + uint32_t SPEED:2; /*!< bit: 24..25 Transfer Speed */ + uint32_t :1; /*!< bit: 26 Reserved */ + uint32_t SCLSM:1; /*!< bit: 27 SCL Clock Stretch Mode */ + uint32_t :2; /*!< bit: 28..29 Reserved */ + uint32_t LOWTOUTEN:1; /*!< bit: 30 SCL Low Timeout Enable */ + uint32_t :1; /*!< bit: 31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_I2CS_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CS_CTRLA_OFFSET 0x00 /**< \brief (SERCOM_I2CS_CTRLA offset) I2CS Control A */ +#define SERCOM_I2CS_CTRLA_RESETVALUE 0x00000000 /**< \brief (SERCOM_I2CS_CTRLA reset_value) I2CS Control A */ + +#define SERCOM_I2CS_CTRLA_SWRST_Pos 0 /**< \brief (SERCOM_I2CS_CTRLA) Software Reset */ +#define SERCOM_I2CS_CTRLA_SWRST (0x1u << SERCOM_I2CS_CTRLA_SWRST_Pos) +#define SERCOM_I2CS_CTRLA_ENABLE_Pos 1 /**< \brief (SERCOM_I2CS_CTRLA) Enable */ +#define SERCOM_I2CS_CTRLA_ENABLE (0x1u << SERCOM_I2CS_CTRLA_ENABLE_Pos) +#define SERCOM_I2CS_CTRLA_MODE_Pos 2 /**< \brief (SERCOM_I2CS_CTRLA) Operating Mode */ +#define SERCOM_I2CS_CTRLA_MODE_Msk (0x7u << SERCOM_I2CS_CTRLA_MODE_Pos) +#define SERCOM_I2CS_CTRLA_MODE(value) ((SERCOM_I2CS_CTRLA_MODE_Msk & ((value) << SERCOM_I2CS_CTRLA_MODE_Pos))) +#define SERCOM_I2CS_CTRLA_MODE_USART_EXT_CLK_Val 0x0u /**< \brief (SERCOM_I2CS_CTRLA) USART mode with external clock */ +#define SERCOM_I2CS_CTRLA_MODE_USART_INT_CLK_Val 0x1u /**< \brief (SERCOM_I2CS_CTRLA) USART mode with internal clock */ +#define SERCOM_I2CS_CTRLA_MODE_SPI_SLAVE_Val 0x2u /**< \brief (SERCOM_I2CS_CTRLA) SPI mode with external clock */ +#define SERCOM_I2CS_CTRLA_MODE_SPI_MASTER_Val 0x3u /**< \brief (SERCOM_I2CS_CTRLA) SPI mode with internal clock */ +#define SERCOM_I2CS_CTRLA_MODE_I2C_SLAVE_Val 0x4u /**< \brief (SERCOM_I2CS_CTRLA) I2C mode with external clock */ +#define SERCOM_I2CS_CTRLA_MODE_I2C_MASTER_Val 0x5u /**< \brief (SERCOM_I2CS_CTRLA) I2C mode with internal clock */ +#define SERCOM_I2CS_CTRLA_MODE_USART_EXT_CLK (SERCOM_I2CS_CTRLA_MODE_USART_EXT_CLK_Val << SERCOM_I2CS_CTRLA_MODE_Pos) +#define SERCOM_I2CS_CTRLA_MODE_USART_INT_CLK (SERCOM_I2CS_CTRLA_MODE_USART_INT_CLK_Val << SERCOM_I2CS_CTRLA_MODE_Pos) +#define SERCOM_I2CS_CTRLA_MODE_SPI_SLAVE (SERCOM_I2CS_CTRLA_MODE_SPI_SLAVE_Val << SERCOM_I2CS_CTRLA_MODE_Pos) +#define SERCOM_I2CS_CTRLA_MODE_SPI_MASTER (SERCOM_I2CS_CTRLA_MODE_SPI_MASTER_Val << SERCOM_I2CS_CTRLA_MODE_Pos) +#define SERCOM_I2CS_CTRLA_MODE_I2C_SLAVE (SERCOM_I2CS_CTRLA_MODE_I2C_SLAVE_Val << SERCOM_I2CS_CTRLA_MODE_Pos) +#define SERCOM_I2CS_CTRLA_MODE_I2C_MASTER (SERCOM_I2CS_CTRLA_MODE_I2C_MASTER_Val << SERCOM_I2CS_CTRLA_MODE_Pos) +#define SERCOM_I2CS_CTRLA_RUNSTDBY_Pos 7 /**< \brief (SERCOM_I2CS_CTRLA) Run during Standby */ +#define SERCOM_I2CS_CTRLA_RUNSTDBY (0x1u << SERCOM_I2CS_CTRLA_RUNSTDBY_Pos) +#define SERCOM_I2CS_CTRLA_PINOUT_Pos 16 /**< \brief (SERCOM_I2CS_CTRLA) Pin Usage */ +#define SERCOM_I2CS_CTRLA_PINOUT (0x1u << SERCOM_I2CS_CTRLA_PINOUT_Pos) +#define SERCOM_I2CS_CTRLA_SDAHOLD_Pos 20 /**< \brief (SERCOM_I2CS_CTRLA) SDA Hold Time */ +#define SERCOM_I2CS_CTRLA_SDAHOLD_Msk (0x3u << SERCOM_I2CS_CTRLA_SDAHOLD_Pos) +#define SERCOM_I2CS_CTRLA_SDAHOLD(value) ((SERCOM_I2CS_CTRLA_SDAHOLD_Msk & ((value) << SERCOM_I2CS_CTRLA_SDAHOLD_Pos))) +#define SERCOM_I2CS_CTRLA_SEXTTOEN_Pos 23 /**< \brief (SERCOM_I2CS_CTRLA) Slave SCL Low Extend Timeout */ +#define SERCOM_I2CS_CTRLA_SEXTTOEN (0x1u << SERCOM_I2CS_CTRLA_SEXTTOEN_Pos) +#define SERCOM_I2CS_CTRLA_SPEED_Pos 24 /**< \brief (SERCOM_I2CS_CTRLA) Transfer Speed */ +#define SERCOM_I2CS_CTRLA_SPEED_Msk (0x3u << SERCOM_I2CS_CTRLA_SPEED_Pos) +#define SERCOM_I2CS_CTRLA_SPEED(value) ((SERCOM_I2CS_CTRLA_SPEED_Msk & ((value) << SERCOM_I2CS_CTRLA_SPEED_Pos))) +#define SERCOM_I2CS_CTRLA_SCLSM_Pos 27 /**< \brief (SERCOM_I2CS_CTRLA) SCL Clock Stretch Mode */ +#define SERCOM_I2CS_CTRLA_SCLSM (0x1u << SERCOM_I2CS_CTRLA_SCLSM_Pos) +#define SERCOM_I2CS_CTRLA_LOWTOUTEN_Pos 30 /**< \brief (SERCOM_I2CS_CTRLA) SCL Low Timeout Enable */ +#define SERCOM_I2CS_CTRLA_LOWTOUTEN (0x1u << SERCOM_I2CS_CTRLA_LOWTOUTEN_Pos) +#define SERCOM_I2CS_CTRLA_MASK 0x4BB1009Fu /**< \brief (SERCOM_I2CS_CTRLA) MASK Register */ + +/* -------- SERCOM_SPI_CTRLA : (SERCOM Offset: 0x00) (R/W 32) SPI SPI Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Software Reset */ + uint32_t ENABLE:1; /*!< bit: 1 Enable */ + uint32_t MODE:3; /*!< bit: 2.. 4 Operating Mode */ + uint32_t :2; /*!< bit: 5.. 6 Reserved */ + uint32_t RUNSTDBY:1; /*!< bit: 7 Run during Standby */ + uint32_t IBON:1; /*!< bit: 8 Immediate Buffer Overflow Notification */ + uint32_t :7; /*!< bit: 9..15 Reserved */ + uint32_t DOPO:2; /*!< bit: 16..17 Data Out Pinout */ + uint32_t :2; /*!< bit: 18..19 Reserved */ + uint32_t DIPO:2; /*!< bit: 20..21 Data In Pinout */ + uint32_t :2; /*!< bit: 22..23 Reserved */ + uint32_t FORM:4; /*!< bit: 24..27 Frame Format */ + uint32_t CPHA:1; /*!< bit: 28 Clock Phase */ + uint32_t CPOL:1; /*!< bit: 29 Clock Polarity */ + uint32_t DORD:1; /*!< bit: 30 Data Order */ + uint32_t :1; /*!< bit: 31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_SPI_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_CTRLA_OFFSET 0x00 /**< \brief (SERCOM_SPI_CTRLA offset) SPI Control A */ +#define SERCOM_SPI_CTRLA_RESETVALUE 0x00000000 /**< \brief (SERCOM_SPI_CTRLA reset_value) SPI Control A */ + +#define SERCOM_SPI_CTRLA_SWRST_Pos 0 /**< \brief (SERCOM_SPI_CTRLA) Software Reset */ +#define SERCOM_SPI_CTRLA_SWRST (0x1u << SERCOM_SPI_CTRLA_SWRST_Pos) +#define SERCOM_SPI_CTRLA_ENABLE_Pos 1 /**< \brief (SERCOM_SPI_CTRLA) Enable */ +#define SERCOM_SPI_CTRLA_ENABLE (0x1u << SERCOM_SPI_CTRLA_ENABLE_Pos) +#define SERCOM_SPI_CTRLA_MODE_Pos 2 /**< \brief (SERCOM_SPI_CTRLA) Operating Mode */ +#define SERCOM_SPI_CTRLA_MODE_Msk (0x7u << SERCOM_SPI_CTRLA_MODE_Pos) +#define SERCOM_SPI_CTRLA_MODE(value) ((SERCOM_SPI_CTRLA_MODE_Msk & ((value) << SERCOM_SPI_CTRLA_MODE_Pos))) +#define SERCOM_SPI_CTRLA_MODE_USART_EXT_CLK_Val 0x0u /**< \brief (SERCOM_SPI_CTRLA) USART mode with external clock */ +#define SERCOM_SPI_CTRLA_MODE_USART_INT_CLK_Val 0x1u /**< \brief (SERCOM_SPI_CTRLA) USART mode with internal clock */ +#define SERCOM_SPI_CTRLA_MODE_SPI_SLAVE_Val 0x2u /**< \brief (SERCOM_SPI_CTRLA) SPI mode with external clock */ +#define SERCOM_SPI_CTRLA_MODE_SPI_MASTER_Val 0x3u /**< \brief (SERCOM_SPI_CTRLA) SPI mode with internal clock */ +#define SERCOM_SPI_CTRLA_MODE_I2C_SLAVE_Val 0x4u /**< \brief (SERCOM_SPI_CTRLA) I2C mode with external clock */ +#define SERCOM_SPI_CTRLA_MODE_I2C_MASTER_Val 0x5u /**< \brief (SERCOM_SPI_CTRLA) I2C mode with internal clock */ +#define SERCOM_SPI_CTRLA_MODE_USART_EXT_CLK (SERCOM_SPI_CTRLA_MODE_USART_EXT_CLK_Val << SERCOM_SPI_CTRLA_MODE_Pos) +#define SERCOM_SPI_CTRLA_MODE_USART_INT_CLK (SERCOM_SPI_CTRLA_MODE_USART_INT_CLK_Val << SERCOM_SPI_CTRLA_MODE_Pos) +#define SERCOM_SPI_CTRLA_MODE_SPI_SLAVE (SERCOM_SPI_CTRLA_MODE_SPI_SLAVE_Val << SERCOM_SPI_CTRLA_MODE_Pos) +#define SERCOM_SPI_CTRLA_MODE_SPI_MASTER (SERCOM_SPI_CTRLA_MODE_SPI_MASTER_Val << SERCOM_SPI_CTRLA_MODE_Pos) +#define SERCOM_SPI_CTRLA_MODE_I2C_SLAVE (SERCOM_SPI_CTRLA_MODE_I2C_SLAVE_Val << SERCOM_SPI_CTRLA_MODE_Pos) +#define SERCOM_SPI_CTRLA_MODE_I2C_MASTER (SERCOM_SPI_CTRLA_MODE_I2C_MASTER_Val << SERCOM_SPI_CTRLA_MODE_Pos) +#define SERCOM_SPI_CTRLA_RUNSTDBY_Pos 7 /**< \brief (SERCOM_SPI_CTRLA) Run during Standby */ +#define SERCOM_SPI_CTRLA_RUNSTDBY (0x1u << SERCOM_SPI_CTRLA_RUNSTDBY_Pos) +#define SERCOM_SPI_CTRLA_IBON_Pos 8 /**< \brief (SERCOM_SPI_CTRLA) Immediate Buffer Overflow Notification */ +#define SERCOM_SPI_CTRLA_IBON (0x1u << SERCOM_SPI_CTRLA_IBON_Pos) +#define SERCOM_SPI_CTRLA_DOPO_Pos 16 /**< \brief (SERCOM_SPI_CTRLA) Data Out Pinout */ +#define SERCOM_SPI_CTRLA_DOPO_Msk (0x3u << SERCOM_SPI_CTRLA_DOPO_Pos) +#define SERCOM_SPI_CTRLA_DOPO(value) ((SERCOM_SPI_CTRLA_DOPO_Msk & ((value) << SERCOM_SPI_CTRLA_DOPO_Pos))) +#define SERCOM_SPI_CTRLA_DIPO_Pos 20 /**< \brief (SERCOM_SPI_CTRLA) Data In Pinout */ +#define SERCOM_SPI_CTRLA_DIPO_Msk (0x3u << SERCOM_SPI_CTRLA_DIPO_Pos) +#define SERCOM_SPI_CTRLA_DIPO(value) ((SERCOM_SPI_CTRLA_DIPO_Msk & ((value) << SERCOM_SPI_CTRLA_DIPO_Pos))) +#define SERCOM_SPI_CTRLA_FORM_Pos 24 /**< \brief (SERCOM_SPI_CTRLA) Frame Format */ +#define SERCOM_SPI_CTRLA_FORM_Msk (0xFu << SERCOM_SPI_CTRLA_FORM_Pos) +#define SERCOM_SPI_CTRLA_FORM(value) ((SERCOM_SPI_CTRLA_FORM_Msk & ((value) << SERCOM_SPI_CTRLA_FORM_Pos))) +#define SERCOM_SPI_CTRLA_CPHA_Pos 28 /**< \brief (SERCOM_SPI_CTRLA) Clock Phase */ +#define SERCOM_SPI_CTRLA_CPHA (0x1u << SERCOM_SPI_CTRLA_CPHA_Pos) +#define SERCOM_SPI_CTRLA_CPOL_Pos 29 /**< \brief (SERCOM_SPI_CTRLA) Clock Polarity */ +#define SERCOM_SPI_CTRLA_CPOL (0x1u << SERCOM_SPI_CTRLA_CPOL_Pos) +#define SERCOM_SPI_CTRLA_DORD_Pos 30 /**< \brief (SERCOM_SPI_CTRLA) Data Order */ +#define SERCOM_SPI_CTRLA_DORD (0x1u << SERCOM_SPI_CTRLA_DORD_Pos) +#define SERCOM_SPI_CTRLA_MASK 0x7F33019Fu /**< \brief (SERCOM_SPI_CTRLA) MASK Register */ + +/* -------- SERCOM_USART_CTRLA : (SERCOM Offset: 0x00) (R/W 32) USART USART Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Software Reset */ + uint32_t ENABLE:1; /*!< bit: 1 Enable */ + uint32_t MODE:3; /*!< bit: 2.. 4 Operating Mode */ + uint32_t :2; /*!< bit: 5.. 6 Reserved */ + uint32_t RUNSTDBY:1; /*!< bit: 7 Run during Standby */ + uint32_t IBON:1; /*!< bit: 8 Immediate Buffer Overflow Notification */ + uint32_t :4; /*!< bit: 9..12 Reserved */ + uint32_t SAMPR:3; /*!< bit: 13..15 Sample */ + uint32_t TXPO:2; /*!< bit: 16..17 Transmit Data Pinout */ + uint32_t :2; /*!< bit: 18..19 Reserved */ + uint32_t RXPO:2; /*!< bit: 20..21 Receive Data Pinout */ + uint32_t SAMPA:2; /*!< bit: 22..23 Sample Adjustment */ + uint32_t FORM:4; /*!< bit: 24..27 Frame Format */ + uint32_t CMODE:1; /*!< bit: 28 Communication Mode */ + uint32_t CPOL:1; /*!< bit: 29 Clock Polarity */ + uint32_t DORD:1; /*!< bit: 30 Data Order */ + uint32_t :1; /*!< bit: 31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_USART_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_CTRLA_OFFSET 0x00 /**< \brief (SERCOM_USART_CTRLA offset) USART Control A */ +#define SERCOM_USART_CTRLA_RESETVALUE 0x00000000 /**< \brief (SERCOM_USART_CTRLA reset_value) USART Control A */ + +#define SERCOM_USART_CTRLA_SWRST_Pos 0 /**< \brief (SERCOM_USART_CTRLA) Software Reset */ +#define SERCOM_USART_CTRLA_SWRST (0x1u << SERCOM_USART_CTRLA_SWRST_Pos) +#define SERCOM_USART_CTRLA_ENABLE_Pos 1 /**< \brief (SERCOM_USART_CTRLA) Enable */ +#define SERCOM_USART_CTRLA_ENABLE (0x1u << SERCOM_USART_CTRLA_ENABLE_Pos) +#define SERCOM_USART_CTRLA_MODE_Pos 2 /**< \brief (SERCOM_USART_CTRLA) Operating Mode */ +#define SERCOM_USART_CTRLA_MODE_Msk (0x7u << SERCOM_USART_CTRLA_MODE_Pos) +#define SERCOM_USART_CTRLA_MODE(value) ((SERCOM_USART_CTRLA_MODE_Msk & ((value) << SERCOM_USART_CTRLA_MODE_Pos))) +#define SERCOM_USART_CTRLA_MODE_USART_EXT_CLK_Val 0x0u /**< \brief (SERCOM_USART_CTRLA) USART mode with external clock */ +#define SERCOM_USART_CTRLA_MODE_USART_INT_CLK_Val 0x1u /**< \brief (SERCOM_USART_CTRLA) USART mode with internal clock */ +#define SERCOM_USART_CTRLA_MODE_SPI_SLAVE_Val 0x2u /**< \brief (SERCOM_USART_CTRLA) SPI mode with external clock */ +#define SERCOM_USART_CTRLA_MODE_SPI_MASTER_Val 0x3u /**< \brief (SERCOM_USART_CTRLA) SPI mode with internal clock */ +#define SERCOM_USART_CTRLA_MODE_I2C_SLAVE_Val 0x4u /**< \brief (SERCOM_USART_CTRLA) I2C mode with external clock */ +#define SERCOM_USART_CTRLA_MODE_I2C_MASTER_Val 0x5u /**< \brief (SERCOM_USART_CTRLA) I2C mode with internal clock */ +#define SERCOM_USART_CTRLA_MODE_USART_EXT_CLK (SERCOM_USART_CTRLA_MODE_USART_EXT_CLK_Val << SERCOM_USART_CTRLA_MODE_Pos) +#define SERCOM_USART_CTRLA_MODE_USART_INT_CLK (SERCOM_USART_CTRLA_MODE_USART_INT_CLK_Val << SERCOM_USART_CTRLA_MODE_Pos) +#define SERCOM_USART_CTRLA_MODE_SPI_SLAVE (SERCOM_USART_CTRLA_MODE_SPI_SLAVE_Val << SERCOM_USART_CTRLA_MODE_Pos) +#define SERCOM_USART_CTRLA_MODE_SPI_MASTER (SERCOM_USART_CTRLA_MODE_SPI_MASTER_Val << SERCOM_USART_CTRLA_MODE_Pos) +#define SERCOM_USART_CTRLA_MODE_I2C_SLAVE (SERCOM_USART_CTRLA_MODE_I2C_SLAVE_Val << SERCOM_USART_CTRLA_MODE_Pos) +#define SERCOM_USART_CTRLA_MODE_I2C_MASTER (SERCOM_USART_CTRLA_MODE_I2C_MASTER_Val << SERCOM_USART_CTRLA_MODE_Pos) +#define SERCOM_USART_CTRLA_RUNSTDBY_Pos 7 /**< \brief (SERCOM_USART_CTRLA) Run during Standby */ +#define SERCOM_USART_CTRLA_RUNSTDBY (0x1u << SERCOM_USART_CTRLA_RUNSTDBY_Pos) +#define SERCOM_USART_CTRLA_IBON_Pos 8 /**< \brief (SERCOM_USART_CTRLA) Immediate Buffer Overflow Notification */ +#define SERCOM_USART_CTRLA_IBON (0x1u << SERCOM_USART_CTRLA_IBON_Pos) +#define SERCOM_USART_CTRLA_SAMPR_Pos 13 /**< \brief (SERCOM_USART_CTRLA) Sample */ +#define SERCOM_USART_CTRLA_SAMPR_Msk (0x7u << SERCOM_USART_CTRLA_SAMPR_Pos) +#define SERCOM_USART_CTRLA_SAMPR(value) ((SERCOM_USART_CTRLA_SAMPR_Msk & ((value) << SERCOM_USART_CTRLA_SAMPR_Pos))) +#define SERCOM_USART_CTRLA_TXPO_Pos 16 /**< \brief (SERCOM_USART_CTRLA) Transmit Data Pinout */ +#define SERCOM_USART_CTRLA_TXPO_Msk (0x3u << SERCOM_USART_CTRLA_TXPO_Pos) +#define SERCOM_USART_CTRLA_TXPO(value) ((SERCOM_USART_CTRLA_TXPO_Msk & ((value) << SERCOM_USART_CTRLA_TXPO_Pos))) +#define SERCOM_USART_CTRLA_RXPO_Pos 20 /**< \brief (SERCOM_USART_CTRLA) Receive Data Pinout */ +#define SERCOM_USART_CTRLA_RXPO_Msk (0x3u << SERCOM_USART_CTRLA_RXPO_Pos) +#define SERCOM_USART_CTRLA_RXPO(value) ((SERCOM_USART_CTRLA_RXPO_Msk & ((value) << SERCOM_USART_CTRLA_RXPO_Pos))) +#define SERCOM_USART_CTRLA_SAMPA_Pos 22 /**< \brief (SERCOM_USART_CTRLA) Sample Adjustment */ +#define SERCOM_USART_CTRLA_SAMPA_Msk (0x3u << SERCOM_USART_CTRLA_SAMPA_Pos) +#define SERCOM_USART_CTRLA_SAMPA(value) ((SERCOM_USART_CTRLA_SAMPA_Msk & ((value) << SERCOM_USART_CTRLA_SAMPA_Pos))) +#define SERCOM_USART_CTRLA_FORM_Pos 24 /**< \brief (SERCOM_USART_CTRLA) Frame Format */ +#define SERCOM_USART_CTRLA_FORM_Msk (0xFu << SERCOM_USART_CTRLA_FORM_Pos) +#define SERCOM_USART_CTRLA_FORM(value) ((SERCOM_USART_CTRLA_FORM_Msk & ((value) << SERCOM_USART_CTRLA_FORM_Pos))) +#define SERCOM_USART_CTRLA_CMODE_Pos 28 /**< \brief (SERCOM_USART_CTRLA) Communication Mode */ +#define SERCOM_USART_CTRLA_CMODE (0x1u << SERCOM_USART_CTRLA_CMODE_Pos) +#define SERCOM_USART_CTRLA_CPOL_Pos 29 /**< \brief (SERCOM_USART_CTRLA) Clock Polarity */ +#define SERCOM_USART_CTRLA_CPOL (0x1u << SERCOM_USART_CTRLA_CPOL_Pos) +#define SERCOM_USART_CTRLA_DORD_Pos 30 /**< \brief (SERCOM_USART_CTRLA) Data Order */ +#define SERCOM_USART_CTRLA_DORD (0x1u << SERCOM_USART_CTRLA_DORD_Pos) +#define SERCOM_USART_CTRLA_MASK 0x7FF3E19Fu /**< \brief (SERCOM_USART_CTRLA) MASK Register */ + +/* -------- SERCOM_I2CM_CTRLB : (SERCOM Offset: 0x04) (R/W 32) I2CM I2CM Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :8; /*!< bit: 0.. 7 Reserved */ + uint32_t SMEN:1; /*!< bit: 8 Smart Mode Enable */ + uint32_t QCEN:1; /*!< bit: 9 Quick Command Enable */ + uint32_t :6; /*!< bit: 10..15 Reserved */ + uint32_t CMD:2; /*!< bit: 16..17 Command */ + uint32_t ACKACT:1; /*!< bit: 18 Acknowledge Action */ + uint32_t :13; /*!< bit: 19..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_CTRLB_OFFSET 0x04 /**< \brief (SERCOM_I2CM_CTRLB offset) I2CM Control B */ +#define SERCOM_I2CM_CTRLB_RESETVALUE 0x00000000 /**< \brief (SERCOM_I2CM_CTRLB reset_value) I2CM Control B */ + +#define SERCOM_I2CM_CTRLB_SMEN_Pos 8 /**< \brief (SERCOM_I2CM_CTRLB) Smart Mode Enable */ +#define SERCOM_I2CM_CTRLB_SMEN (0x1u << SERCOM_I2CM_CTRLB_SMEN_Pos) +#define SERCOM_I2CM_CTRLB_QCEN_Pos 9 /**< \brief (SERCOM_I2CM_CTRLB) Quick Command Enable */ +#define SERCOM_I2CM_CTRLB_QCEN (0x1u << SERCOM_I2CM_CTRLB_QCEN_Pos) +#define SERCOM_I2CM_CTRLB_CMD_Pos 16 /**< \brief (SERCOM_I2CM_CTRLB) Command */ +#define SERCOM_I2CM_CTRLB_CMD_Msk (0x3u << SERCOM_I2CM_CTRLB_CMD_Pos) +#define SERCOM_I2CM_CTRLB_CMD(value) ((SERCOM_I2CM_CTRLB_CMD_Msk & ((value) << SERCOM_I2CM_CTRLB_CMD_Pos))) +#define SERCOM_I2CM_CTRLB_ACKACT_Pos 18 /**< \brief (SERCOM_I2CM_CTRLB) Acknowledge Action */ +#define SERCOM_I2CM_CTRLB_ACKACT (0x1u << SERCOM_I2CM_CTRLB_ACKACT_Pos) +#define SERCOM_I2CM_CTRLB_MASK 0x00070300u /**< \brief (SERCOM_I2CM_CTRLB) MASK Register */ + +/* -------- SERCOM_I2CS_CTRLB : (SERCOM Offset: 0x04) (R/W 32) I2CS I2CS Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :8; /*!< bit: 0.. 7 Reserved */ + uint32_t SMEN:1; /*!< bit: 8 Smart Mode Enable */ + uint32_t GCMD:1; /*!< bit: 9 PMBus Group Command */ + uint32_t AACKEN:1; /*!< bit: 10 Automatic Address Acknowledge */ + uint32_t :3; /*!< bit: 11..13 Reserved */ + uint32_t AMODE:2; /*!< bit: 14..15 Address Mode */ + uint32_t CMD:2; /*!< bit: 16..17 Command */ + uint32_t ACKACT:1; /*!< bit: 18 Acknowledge Action */ + uint32_t :13; /*!< bit: 19..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_I2CS_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CS_CTRLB_OFFSET 0x04 /**< \brief (SERCOM_I2CS_CTRLB offset) I2CS Control B */ +#define SERCOM_I2CS_CTRLB_RESETVALUE 0x00000000 /**< \brief (SERCOM_I2CS_CTRLB reset_value) I2CS Control B */ + +#define SERCOM_I2CS_CTRLB_SMEN_Pos 8 /**< \brief (SERCOM_I2CS_CTRLB) Smart Mode Enable */ +#define SERCOM_I2CS_CTRLB_SMEN (0x1u << SERCOM_I2CS_CTRLB_SMEN_Pos) +#define SERCOM_I2CS_CTRLB_GCMD_Pos 9 /**< \brief (SERCOM_I2CS_CTRLB) PMBus Group Command */ +#define SERCOM_I2CS_CTRLB_GCMD (0x1u << SERCOM_I2CS_CTRLB_GCMD_Pos) +#define SERCOM_I2CS_CTRLB_AACKEN_Pos 10 /**< \brief (SERCOM_I2CS_CTRLB) Automatic Address Acknowledge */ +#define SERCOM_I2CS_CTRLB_AACKEN (0x1u << SERCOM_I2CS_CTRLB_AACKEN_Pos) +#define SERCOM_I2CS_CTRLB_AMODE_Pos 14 /**< \brief (SERCOM_I2CS_CTRLB) Address Mode */ +#define SERCOM_I2CS_CTRLB_AMODE_Msk (0x3u << SERCOM_I2CS_CTRLB_AMODE_Pos) +#define SERCOM_I2CS_CTRLB_AMODE(value) ((SERCOM_I2CS_CTRLB_AMODE_Msk & ((value) << SERCOM_I2CS_CTRLB_AMODE_Pos))) +#define SERCOM_I2CS_CTRLB_CMD_Pos 16 /**< \brief (SERCOM_I2CS_CTRLB) Command */ +#define SERCOM_I2CS_CTRLB_CMD_Msk (0x3u << SERCOM_I2CS_CTRLB_CMD_Pos) +#define SERCOM_I2CS_CTRLB_CMD(value) ((SERCOM_I2CS_CTRLB_CMD_Msk & ((value) << SERCOM_I2CS_CTRLB_CMD_Pos))) +#define SERCOM_I2CS_CTRLB_ACKACT_Pos 18 /**< \brief (SERCOM_I2CS_CTRLB) Acknowledge Action */ +#define SERCOM_I2CS_CTRLB_ACKACT (0x1u << SERCOM_I2CS_CTRLB_ACKACT_Pos) +#define SERCOM_I2CS_CTRLB_MASK 0x0007C700u /**< \brief (SERCOM_I2CS_CTRLB) MASK Register */ + +/* -------- SERCOM_SPI_CTRLB : (SERCOM Offset: 0x04) (R/W 32) SPI SPI Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CHSIZE:3; /*!< bit: 0.. 2 Character Size */ + uint32_t :3; /*!< bit: 3.. 5 Reserved */ + uint32_t PLOADEN:1; /*!< bit: 6 Data Preload Enable */ + uint32_t :2; /*!< bit: 7.. 8 Reserved */ + uint32_t SSDE:1; /*!< bit: 9 Slave Select Low Detect Enable */ + uint32_t :3; /*!< bit: 10..12 Reserved */ + uint32_t MSSEN:1; /*!< bit: 13 Master Slave Select Enable */ + uint32_t AMODE:2; /*!< bit: 14..15 Address Mode */ + uint32_t :1; /*!< bit: 16 Reserved */ + uint32_t RXEN:1; /*!< bit: 17 Receiver Enable */ + uint32_t :14; /*!< bit: 18..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_SPI_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_CTRLB_OFFSET 0x04 /**< \brief (SERCOM_SPI_CTRLB offset) SPI Control B */ +#define SERCOM_SPI_CTRLB_RESETVALUE 0x00000000 /**< \brief (SERCOM_SPI_CTRLB reset_value) SPI Control B */ + +#define SERCOM_SPI_CTRLB_CHSIZE_Pos 0 /**< \brief (SERCOM_SPI_CTRLB) Character Size */ +#define SERCOM_SPI_CTRLB_CHSIZE_Msk (0x7u << SERCOM_SPI_CTRLB_CHSIZE_Pos) +#define SERCOM_SPI_CTRLB_CHSIZE(value) ((SERCOM_SPI_CTRLB_CHSIZE_Msk & ((value) << SERCOM_SPI_CTRLB_CHSIZE_Pos))) +#define SERCOM_SPI_CTRLB_PLOADEN_Pos 6 /**< \brief (SERCOM_SPI_CTRLB) Data Preload Enable */ +#define SERCOM_SPI_CTRLB_PLOADEN (0x1u << SERCOM_SPI_CTRLB_PLOADEN_Pos) +#define SERCOM_SPI_CTRLB_SSDE_Pos 9 /**< \brief (SERCOM_SPI_CTRLB) Slave Select Low Detect Enable */ +#define SERCOM_SPI_CTRLB_SSDE (0x1u << SERCOM_SPI_CTRLB_SSDE_Pos) +#define SERCOM_SPI_CTRLB_MSSEN_Pos 13 /**< \brief (SERCOM_SPI_CTRLB) Master Slave Select Enable */ +#define SERCOM_SPI_CTRLB_MSSEN (0x1u << SERCOM_SPI_CTRLB_MSSEN_Pos) +#define SERCOM_SPI_CTRLB_AMODE_Pos 14 /**< \brief (SERCOM_SPI_CTRLB) Address Mode */ +#define SERCOM_SPI_CTRLB_AMODE_Msk (0x3u << SERCOM_SPI_CTRLB_AMODE_Pos) +#define SERCOM_SPI_CTRLB_AMODE(value) ((SERCOM_SPI_CTRLB_AMODE_Msk & ((value) << SERCOM_SPI_CTRLB_AMODE_Pos))) +#define SERCOM_SPI_CTRLB_RXEN_Pos 17 /**< \brief (SERCOM_SPI_CTRLB) Receiver Enable */ +#define SERCOM_SPI_CTRLB_RXEN (0x1u << SERCOM_SPI_CTRLB_RXEN_Pos) +#define SERCOM_SPI_CTRLB_MASK 0x0002E247u /**< \brief (SERCOM_SPI_CTRLB) MASK Register */ + +/* -------- SERCOM_USART_CTRLB : (SERCOM Offset: 0x04) (R/W 32) USART USART Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CHSIZE:3; /*!< bit: 0.. 2 Character Size */ + uint32_t :3; /*!< bit: 3.. 5 Reserved */ + uint32_t SBMODE:1; /*!< bit: 6 Stop Bit Mode */ + uint32_t :1; /*!< bit: 7 Reserved */ + uint32_t COLDEN:1; /*!< bit: 8 Collision Detection Enable */ + uint32_t SFDE:1; /*!< bit: 9 Start of Frame Detection Enable */ + uint32_t ENC:1; /*!< bit: 10 Encoding Format */ + uint32_t :2; /*!< bit: 11..12 Reserved */ + uint32_t PMODE:1; /*!< bit: 13 Parity Mode */ + uint32_t :2; /*!< bit: 14..15 Reserved */ + uint32_t TXEN:1; /*!< bit: 16 Transmitter Enable */ + uint32_t RXEN:1; /*!< bit: 17 Receiver Enable */ + uint32_t :14; /*!< bit: 18..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_USART_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_CTRLB_OFFSET 0x04 /**< \brief (SERCOM_USART_CTRLB offset) USART Control B */ +#define SERCOM_USART_CTRLB_RESETVALUE 0x00000000 /**< \brief (SERCOM_USART_CTRLB reset_value) USART Control B */ + +#define SERCOM_USART_CTRLB_CHSIZE_Pos 0 /**< \brief (SERCOM_USART_CTRLB) Character Size */ +#define SERCOM_USART_CTRLB_CHSIZE_Msk (0x7u << SERCOM_USART_CTRLB_CHSIZE_Pos) +#define SERCOM_USART_CTRLB_CHSIZE(value) ((SERCOM_USART_CTRLB_CHSIZE_Msk & ((value) << SERCOM_USART_CTRLB_CHSIZE_Pos))) +#define SERCOM_USART_CTRLB_SBMODE_Pos 6 /**< \brief (SERCOM_USART_CTRLB) Stop Bit Mode */ +#define SERCOM_USART_CTRLB_SBMODE (0x1u << SERCOM_USART_CTRLB_SBMODE_Pos) +#define SERCOM_USART_CTRLB_COLDEN_Pos 8 /**< \brief (SERCOM_USART_CTRLB) Collision Detection Enable */ +#define SERCOM_USART_CTRLB_COLDEN (0x1u << SERCOM_USART_CTRLB_COLDEN_Pos) +#define SERCOM_USART_CTRLB_SFDE_Pos 9 /**< \brief (SERCOM_USART_CTRLB) Start of Frame Detection Enable */ +#define SERCOM_USART_CTRLB_SFDE (0x1u << SERCOM_USART_CTRLB_SFDE_Pos) +#define SERCOM_USART_CTRLB_ENC_Pos 10 /**< \brief (SERCOM_USART_CTRLB) Encoding Format */ +#define SERCOM_USART_CTRLB_ENC (0x1u << SERCOM_USART_CTRLB_ENC_Pos) +#define SERCOM_USART_CTRLB_PMODE_Pos 13 /**< \brief (SERCOM_USART_CTRLB) Parity Mode */ +#define SERCOM_USART_CTRLB_PMODE (0x1u << SERCOM_USART_CTRLB_PMODE_Pos) +#define SERCOM_USART_CTRLB_TXEN_Pos 16 /**< \brief (SERCOM_USART_CTRLB) Transmitter Enable */ +#define SERCOM_USART_CTRLB_TXEN (0x1u << SERCOM_USART_CTRLB_TXEN_Pos) +#define SERCOM_USART_CTRLB_RXEN_Pos 17 /**< \brief (SERCOM_USART_CTRLB) Receiver Enable */ +#define SERCOM_USART_CTRLB_RXEN (0x1u << SERCOM_USART_CTRLB_RXEN_Pos) +#define SERCOM_USART_CTRLB_MASK 0x00032747u /**< \brief (SERCOM_USART_CTRLB) MASK Register */ + +/* -------- SERCOM_I2CM_BAUD : (SERCOM Offset: 0x0C) (R/W 32) I2CM I2CM Baud Rate -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t BAUD:8; /*!< bit: 0.. 7 Baud Rate Value */ + uint32_t BAUDLOW:8; /*!< bit: 8..15 Baud Rate Value Low */ + uint32_t HSBAUD:8; /*!< bit: 16..23 High Speed Baud Rate Value */ + uint32_t HSBAUDLOW:8; /*!< bit: 24..31 High Speed Baud Rate Value Low */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_BAUD_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_BAUD_OFFSET 0x0C /**< \brief (SERCOM_I2CM_BAUD offset) I2CM Baud Rate */ +#define SERCOM_I2CM_BAUD_RESETVALUE 0x00000000 /**< \brief (SERCOM_I2CM_BAUD reset_value) I2CM Baud Rate */ + +#define SERCOM_I2CM_BAUD_BAUD_Pos 0 /**< \brief (SERCOM_I2CM_BAUD) Baud Rate Value */ +#define SERCOM_I2CM_BAUD_BAUD_Msk (0xFFu << SERCOM_I2CM_BAUD_BAUD_Pos) +#define SERCOM_I2CM_BAUD_BAUD(value) ((SERCOM_I2CM_BAUD_BAUD_Msk & ((value) << SERCOM_I2CM_BAUD_BAUD_Pos))) +#define SERCOM_I2CM_BAUD_BAUDLOW_Pos 8 /**< \brief (SERCOM_I2CM_BAUD) Baud Rate Value Low */ +#define SERCOM_I2CM_BAUD_BAUDLOW_Msk (0xFFu << SERCOM_I2CM_BAUD_BAUDLOW_Pos) +#define SERCOM_I2CM_BAUD_BAUDLOW(value) ((SERCOM_I2CM_BAUD_BAUDLOW_Msk & ((value) << SERCOM_I2CM_BAUD_BAUDLOW_Pos))) +#define SERCOM_I2CM_BAUD_HSBAUD_Pos 16 /**< \brief (SERCOM_I2CM_BAUD) High Speed Baud Rate Value */ +#define SERCOM_I2CM_BAUD_HSBAUD_Msk (0xFFu << SERCOM_I2CM_BAUD_HSBAUD_Pos) +#define SERCOM_I2CM_BAUD_HSBAUD(value) ((SERCOM_I2CM_BAUD_HSBAUD_Msk & ((value) << SERCOM_I2CM_BAUD_HSBAUD_Pos))) +#define SERCOM_I2CM_BAUD_HSBAUDLOW_Pos 24 /**< \brief (SERCOM_I2CM_BAUD) High Speed Baud Rate Value Low */ +#define SERCOM_I2CM_BAUD_HSBAUDLOW_Msk (0xFFu << SERCOM_I2CM_BAUD_HSBAUDLOW_Pos) +#define SERCOM_I2CM_BAUD_HSBAUDLOW(value) ((SERCOM_I2CM_BAUD_HSBAUDLOW_Msk & ((value) << SERCOM_I2CM_BAUD_HSBAUDLOW_Pos))) +#define SERCOM_I2CM_BAUD_MASK 0xFFFFFFFFu /**< \brief (SERCOM_I2CM_BAUD) MASK Register */ + +/* -------- SERCOM_SPI_BAUD : (SERCOM Offset: 0x0C) (R/W 8) SPI SPI Baud Rate -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t BAUD:8; /*!< bit: 0.. 7 Baud Rate Value */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_SPI_BAUD_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_BAUD_OFFSET 0x0C /**< \brief (SERCOM_SPI_BAUD offset) SPI Baud Rate */ +#define SERCOM_SPI_BAUD_RESETVALUE 0x00 /**< \brief (SERCOM_SPI_BAUD reset_value) SPI Baud Rate */ + +#define SERCOM_SPI_BAUD_BAUD_Pos 0 /**< \brief (SERCOM_SPI_BAUD) Baud Rate Value */ +#define SERCOM_SPI_BAUD_BAUD_Msk (0xFFu << SERCOM_SPI_BAUD_BAUD_Pos) +#define SERCOM_SPI_BAUD_BAUD(value) ((SERCOM_SPI_BAUD_BAUD_Msk & ((value) << SERCOM_SPI_BAUD_BAUD_Pos))) +#define SERCOM_SPI_BAUD_MASK 0xFFu /**< \brief (SERCOM_SPI_BAUD) MASK Register */ + +/* -------- SERCOM_USART_BAUD : (SERCOM Offset: 0x0C) (R/W 16) USART USART Baud Rate -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t BAUD:16; /*!< bit: 0..15 Baud Rate Value */ + } bit; /*!< Structure used for bit access */ + struct { // FRAC mode + uint16_t BAUD:13; /*!< bit: 0..12 Baud Rate Value */ + uint16_t FP:3; /*!< bit: 13..15 Fractional Part */ + } FRAC; /*!< Structure used for FRAC */ + struct { // FRACFP mode + uint16_t BAUD:13; /*!< bit: 0..12 Baud Rate Value */ + uint16_t FP:3; /*!< bit: 13..15 Fractional Part */ + } FRACFP; /*!< Structure used for FRACFP */ + struct { // USARTFP mode + uint16_t BAUD:16; /*!< bit: 0..15 Baud Rate Value */ + } USARTFP; /*!< Structure used for USARTFP */ + uint16_t reg; /*!< Type used for register access */ +} SERCOM_USART_BAUD_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_BAUD_OFFSET 0x0C /**< \brief (SERCOM_USART_BAUD offset) USART Baud Rate */ +#define SERCOM_USART_BAUD_RESETVALUE 0x0000 /**< \brief (SERCOM_USART_BAUD reset_value) USART Baud Rate */ + +#define SERCOM_USART_BAUD_BAUD_Pos 0 /**< \brief (SERCOM_USART_BAUD) Baud Rate Value */ +#define SERCOM_USART_BAUD_BAUD_Msk (0xFFFFu << SERCOM_USART_BAUD_BAUD_Pos) +#define SERCOM_USART_BAUD_BAUD(value) ((SERCOM_USART_BAUD_BAUD_Msk & ((value) << SERCOM_USART_BAUD_BAUD_Pos))) +#define SERCOM_USART_BAUD_MASK 0xFFFFu /**< \brief (SERCOM_USART_BAUD) MASK Register */ + +// FRAC mode +#define SERCOM_USART_BAUD_FRAC_BAUD_Pos 0 /**< \brief (SERCOM_USART_BAUD_FRAC) Baud Rate Value */ +#define SERCOM_USART_BAUD_FRAC_BAUD_Msk (0x1FFFu << SERCOM_USART_BAUD_FRAC_BAUD_Pos) +#define SERCOM_USART_BAUD_FRAC_BAUD(value) ((SERCOM_USART_BAUD_FRAC_BAUD_Msk & ((value) << SERCOM_USART_BAUD_FRAC_BAUD_Pos))) +#define SERCOM_USART_BAUD_FRAC_FP_Pos 13 /**< \brief (SERCOM_USART_BAUD_FRAC) Fractional Part */ +#define SERCOM_USART_BAUD_FRAC_FP_Msk (0x7u << SERCOM_USART_BAUD_FRAC_FP_Pos) +#define SERCOM_USART_BAUD_FRAC_FP(value) ((SERCOM_USART_BAUD_FRAC_FP_Msk & ((value) << SERCOM_USART_BAUD_FRAC_FP_Pos))) +#define SERCOM_USART_BAUD_FRAC_MASK 0xFFFFu /**< \brief (SERCOM_USART_BAUD_FRAC) MASK Register */ + +// FRACFP mode +#define SERCOM_USART_BAUD_FRACFP_BAUD_Pos 0 /**< \brief (SERCOM_USART_BAUD_FRACFP) Baud Rate Value */ +#define SERCOM_USART_BAUD_FRACFP_BAUD_Msk (0x1FFFu << SERCOM_USART_BAUD_FRACFP_BAUD_Pos) +#define SERCOM_USART_BAUD_FRACFP_BAUD(value) ((SERCOM_USART_BAUD_FRACFP_BAUD_Msk & ((value) << SERCOM_USART_BAUD_FRACFP_BAUD_Pos))) +#define SERCOM_USART_BAUD_FRACFP_FP_Pos 13 /**< \brief (SERCOM_USART_BAUD_FRACFP) Fractional Part */ +#define SERCOM_USART_BAUD_FRACFP_FP_Msk (0x7u << SERCOM_USART_BAUD_FRACFP_FP_Pos) +#define SERCOM_USART_BAUD_FRACFP_FP(value) ((SERCOM_USART_BAUD_FRACFP_FP_Msk & ((value) << SERCOM_USART_BAUD_FRACFP_FP_Pos))) +#define SERCOM_USART_BAUD_FRACFP_MASK 0xFFFFu /**< \brief (SERCOM_USART_BAUD_FRACFP) MASK Register */ + +// USARTFP mode +#define SERCOM_USART_BAUD_USARTFP_BAUD_Pos 0 /**< \brief (SERCOM_USART_BAUD_USARTFP) Baud Rate Value */ +#define SERCOM_USART_BAUD_USARTFP_BAUD_Msk (0xFFFFu << SERCOM_USART_BAUD_USARTFP_BAUD_Pos) +#define SERCOM_USART_BAUD_USARTFP_BAUD(value) ((SERCOM_USART_BAUD_USARTFP_BAUD_Msk & ((value) << SERCOM_USART_BAUD_USARTFP_BAUD_Pos))) +#define SERCOM_USART_BAUD_USARTFP_MASK 0xFFFFu /**< \brief (SERCOM_USART_BAUD_USARTFP) MASK Register */ + +/* -------- SERCOM_USART_RXPL : (SERCOM Offset: 0x0E) (R/W 8) USART USART Receive Pulse Length -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t RXPL:8; /*!< bit: 0.. 7 Receive Pulse Length */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_USART_RXPL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_RXPL_OFFSET 0x0E /**< \brief (SERCOM_USART_RXPL offset) USART Receive Pulse Length */ +#define SERCOM_USART_RXPL_RESETVALUE 0x00 /**< \brief (SERCOM_USART_RXPL reset_value) USART Receive Pulse Length */ + +#define SERCOM_USART_RXPL_RXPL_Pos 0 /**< \brief (SERCOM_USART_RXPL) Receive Pulse Length */ +#define SERCOM_USART_RXPL_RXPL_Msk (0xFFu << SERCOM_USART_RXPL_RXPL_Pos) +#define SERCOM_USART_RXPL_RXPL(value) ((SERCOM_USART_RXPL_RXPL_Msk & ((value) << SERCOM_USART_RXPL_RXPL_Pos))) +#define SERCOM_USART_RXPL_MASK 0xFFu /**< \brief (SERCOM_USART_RXPL) MASK Register */ + +/* -------- SERCOM_I2CM_INTENCLR : (SERCOM Offset: 0x14) (R/W 8) I2CM I2CM Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t MB:1; /*!< bit: 0 Master On Bus Interrupt Disable */ + uint8_t SB:1; /*!< bit: 1 Slave On Bus Interrupt Disable */ + uint8_t :5; /*!< bit: 2.. 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt Disable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_INTENCLR_OFFSET 0x14 /**< \brief (SERCOM_I2CM_INTENCLR offset) I2CM Interrupt Enable Clear */ +#define SERCOM_I2CM_INTENCLR_RESETVALUE 0x00 /**< \brief (SERCOM_I2CM_INTENCLR reset_value) I2CM Interrupt Enable Clear */ + +#define SERCOM_I2CM_INTENCLR_MB_Pos 0 /**< \brief (SERCOM_I2CM_INTENCLR) Master On Bus Interrupt Disable */ +#define SERCOM_I2CM_INTENCLR_MB (0x1u << SERCOM_I2CM_INTENCLR_MB_Pos) +#define SERCOM_I2CM_INTENCLR_SB_Pos 1 /**< \brief (SERCOM_I2CM_INTENCLR) Slave On Bus Interrupt Disable */ +#define SERCOM_I2CM_INTENCLR_SB (0x1u << SERCOM_I2CM_INTENCLR_SB_Pos) +#define SERCOM_I2CM_INTENCLR_ERROR_Pos 7 /**< \brief (SERCOM_I2CM_INTENCLR) Combined Error Interrupt Disable */ +#define SERCOM_I2CM_INTENCLR_ERROR (0x1u << SERCOM_I2CM_INTENCLR_ERROR_Pos) +#define SERCOM_I2CM_INTENCLR_MASK 0x83u /**< \brief (SERCOM_I2CM_INTENCLR) MASK Register */ + +/* -------- SERCOM_I2CS_INTENCLR : (SERCOM Offset: 0x14) (R/W 8) I2CS I2CS Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PREC:1; /*!< bit: 0 Stop Received Interrupt Disable */ + uint8_t AMATCH:1; /*!< bit: 1 Address Match Interrupt Disable */ + uint8_t DRDY:1; /*!< bit: 2 Data Interrupt Disable */ + uint8_t :4; /*!< bit: 3.. 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt Disable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_I2CS_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CS_INTENCLR_OFFSET 0x14 /**< \brief (SERCOM_I2CS_INTENCLR offset) I2CS Interrupt Enable Clear */ +#define SERCOM_I2CS_INTENCLR_RESETVALUE 0x00 /**< \brief (SERCOM_I2CS_INTENCLR reset_value) I2CS Interrupt Enable Clear */ + +#define SERCOM_I2CS_INTENCLR_PREC_Pos 0 /**< \brief (SERCOM_I2CS_INTENCLR) Stop Received Interrupt Disable */ +#define SERCOM_I2CS_INTENCLR_PREC (0x1u << SERCOM_I2CS_INTENCLR_PREC_Pos) +#define SERCOM_I2CS_INTENCLR_AMATCH_Pos 1 /**< \brief (SERCOM_I2CS_INTENCLR) Address Match Interrupt Disable */ +#define SERCOM_I2CS_INTENCLR_AMATCH (0x1u << SERCOM_I2CS_INTENCLR_AMATCH_Pos) +#define SERCOM_I2CS_INTENCLR_DRDY_Pos 2 /**< \brief (SERCOM_I2CS_INTENCLR) Data Interrupt Disable */ +#define SERCOM_I2CS_INTENCLR_DRDY (0x1u << SERCOM_I2CS_INTENCLR_DRDY_Pos) +#define SERCOM_I2CS_INTENCLR_ERROR_Pos 7 /**< \brief (SERCOM_I2CS_INTENCLR) Combined Error Interrupt Disable */ +#define SERCOM_I2CS_INTENCLR_ERROR (0x1u << SERCOM_I2CS_INTENCLR_ERROR_Pos) +#define SERCOM_I2CS_INTENCLR_MASK 0x87u /**< \brief (SERCOM_I2CS_INTENCLR) MASK Register */ + +/* -------- SERCOM_SPI_INTENCLR : (SERCOM Offset: 0x14) (R/W 8) SPI SPI Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DRE:1; /*!< bit: 0 Data Register Empty Interrupt Disable */ + uint8_t TXC:1; /*!< bit: 1 Transmit Complete Interrupt Disable */ + uint8_t RXC:1; /*!< bit: 2 Receive Complete Interrupt Disable */ + uint8_t SSL:1; /*!< bit: 3 Slave Select Low Interrupt Disable */ + uint8_t :3; /*!< bit: 4.. 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt Disable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_SPI_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_INTENCLR_OFFSET 0x14 /**< \brief (SERCOM_SPI_INTENCLR offset) SPI Interrupt Enable Clear */ +#define SERCOM_SPI_INTENCLR_RESETVALUE 0x00 /**< \brief (SERCOM_SPI_INTENCLR reset_value) SPI Interrupt Enable Clear */ + +#define SERCOM_SPI_INTENCLR_DRE_Pos 0 /**< \brief (SERCOM_SPI_INTENCLR) Data Register Empty Interrupt Disable */ +#define SERCOM_SPI_INTENCLR_DRE (0x1u << SERCOM_SPI_INTENCLR_DRE_Pos) +#define SERCOM_SPI_INTENCLR_TXC_Pos 1 /**< \brief (SERCOM_SPI_INTENCLR) Transmit Complete Interrupt Disable */ +#define SERCOM_SPI_INTENCLR_TXC (0x1u << SERCOM_SPI_INTENCLR_TXC_Pos) +#define SERCOM_SPI_INTENCLR_RXC_Pos 2 /**< \brief (SERCOM_SPI_INTENCLR) Receive Complete Interrupt Disable */ +#define SERCOM_SPI_INTENCLR_RXC (0x1u << SERCOM_SPI_INTENCLR_RXC_Pos) +#define SERCOM_SPI_INTENCLR_SSL_Pos 3 /**< \brief (SERCOM_SPI_INTENCLR) Slave Select Low Interrupt Disable */ +#define SERCOM_SPI_INTENCLR_SSL (0x1u << SERCOM_SPI_INTENCLR_SSL_Pos) +#define SERCOM_SPI_INTENCLR_ERROR_Pos 7 /**< \brief (SERCOM_SPI_INTENCLR) Combined Error Interrupt Disable */ +#define SERCOM_SPI_INTENCLR_ERROR (0x1u << SERCOM_SPI_INTENCLR_ERROR_Pos) +#define SERCOM_SPI_INTENCLR_MASK 0x8Fu /**< \brief (SERCOM_SPI_INTENCLR) MASK Register */ + +/* -------- SERCOM_USART_INTENCLR : (SERCOM Offset: 0x14) (R/W 8) USART USART Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DRE:1; /*!< bit: 0 Data Register Empty Interrupt Disable */ + uint8_t TXC:1; /*!< bit: 1 Transmit Complete Interrupt Disable */ + uint8_t RXC:1; /*!< bit: 2 Receive Complete Interrupt Disable */ + uint8_t RXS:1; /*!< bit: 3 Receive Start Interrupt Disable */ + uint8_t CTSIC:1; /*!< bit: 4 Clear To Send Input Change Interrupt Disable */ + uint8_t RXBRK:1; /*!< bit: 5 Break Received Interrupt Disable */ + uint8_t :1; /*!< bit: 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt Disable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_USART_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_INTENCLR_OFFSET 0x14 /**< \brief (SERCOM_USART_INTENCLR offset) USART Interrupt Enable Clear */ +#define SERCOM_USART_INTENCLR_RESETVALUE 0x00 /**< \brief (SERCOM_USART_INTENCLR reset_value) USART Interrupt Enable Clear */ + +#define SERCOM_USART_INTENCLR_DRE_Pos 0 /**< \brief (SERCOM_USART_INTENCLR) Data Register Empty Interrupt Disable */ +#define SERCOM_USART_INTENCLR_DRE (0x1u << SERCOM_USART_INTENCLR_DRE_Pos) +#define SERCOM_USART_INTENCLR_TXC_Pos 1 /**< \brief (SERCOM_USART_INTENCLR) Transmit Complete Interrupt Disable */ +#define SERCOM_USART_INTENCLR_TXC (0x1u << SERCOM_USART_INTENCLR_TXC_Pos) +#define SERCOM_USART_INTENCLR_RXC_Pos 2 /**< \brief (SERCOM_USART_INTENCLR) Receive Complete Interrupt Disable */ +#define SERCOM_USART_INTENCLR_RXC (0x1u << SERCOM_USART_INTENCLR_RXC_Pos) +#define SERCOM_USART_INTENCLR_RXS_Pos 3 /**< \brief (SERCOM_USART_INTENCLR) Receive Start Interrupt Disable */ +#define SERCOM_USART_INTENCLR_RXS (0x1u << SERCOM_USART_INTENCLR_RXS_Pos) +#define SERCOM_USART_INTENCLR_CTSIC_Pos 4 /**< \brief (SERCOM_USART_INTENCLR) Clear To Send Input Change Interrupt Disable */ +#define SERCOM_USART_INTENCLR_CTSIC (0x1u << SERCOM_USART_INTENCLR_CTSIC_Pos) +#define SERCOM_USART_INTENCLR_RXBRK_Pos 5 /**< \brief (SERCOM_USART_INTENCLR) Break Received Interrupt Disable */ +#define SERCOM_USART_INTENCLR_RXBRK (0x1u << SERCOM_USART_INTENCLR_RXBRK_Pos) +#define SERCOM_USART_INTENCLR_ERROR_Pos 7 /**< \brief (SERCOM_USART_INTENCLR) Combined Error Interrupt Disable */ +#define SERCOM_USART_INTENCLR_ERROR (0x1u << SERCOM_USART_INTENCLR_ERROR_Pos) +#define SERCOM_USART_INTENCLR_MASK 0xBFu /**< \brief (SERCOM_USART_INTENCLR) MASK Register */ + +/* -------- SERCOM_I2CM_INTENSET : (SERCOM Offset: 0x16) (R/W 8) I2CM I2CM Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t MB:1; /*!< bit: 0 Master On Bus Interrupt Enable */ + uint8_t SB:1; /*!< bit: 1 Slave On Bus Interrupt Enable */ + uint8_t :5; /*!< bit: 2.. 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_INTENSET_OFFSET 0x16 /**< \brief (SERCOM_I2CM_INTENSET offset) I2CM Interrupt Enable Set */ +#define SERCOM_I2CM_INTENSET_RESETVALUE 0x00 /**< \brief (SERCOM_I2CM_INTENSET reset_value) I2CM Interrupt Enable Set */ + +#define SERCOM_I2CM_INTENSET_MB_Pos 0 /**< \brief (SERCOM_I2CM_INTENSET) Master On Bus Interrupt Enable */ +#define SERCOM_I2CM_INTENSET_MB (0x1u << SERCOM_I2CM_INTENSET_MB_Pos) +#define SERCOM_I2CM_INTENSET_SB_Pos 1 /**< \brief (SERCOM_I2CM_INTENSET) Slave On Bus Interrupt Enable */ +#define SERCOM_I2CM_INTENSET_SB (0x1u << SERCOM_I2CM_INTENSET_SB_Pos) +#define SERCOM_I2CM_INTENSET_ERROR_Pos 7 /**< \brief (SERCOM_I2CM_INTENSET) Combined Error Interrupt Enable */ +#define SERCOM_I2CM_INTENSET_ERROR (0x1u << SERCOM_I2CM_INTENSET_ERROR_Pos) +#define SERCOM_I2CM_INTENSET_MASK 0x83u /**< \brief (SERCOM_I2CM_INTENSET) MASK Register */ + +/* -------- SERCOM_I2CS_INTENSET : (SERCOM Offset: 0x16) (R/W 8) I2CS I2CS Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PREC:1; /*!< bit: 0 Stop Received Interrupt Enable */ + uint8_t AMATCH:1; /*!< bit: 1 Address Match Interrupt Enable */ + uint8_t DRDY:1; /*!< bit: 2 Data Interrupt Enable */ + uint8_t :4; /*!< bit: 3.. 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_I2CS_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CS_INTENSET_OFFSET 0x16 /**< \brief (SERCOM_I2CS_INTENSET offset) I2CS Interrupt Enable Set */ +#define SERCOM_I2CS_INTENSET_RESETVALUE 0x00 /**< \brief (SERCOM_I2CS_INTENSET reset_value) I2CS Interrupt Enable Set */ + +#define SERCOM_I2CS_INTENSET_PREC_Pos 0 /**< \brief (SERCOM_I2CS_INTENSET) Stop Received Interrupt Enable */ +#define SERCOM_I2CS_INTENSET_PREC (0x1u << SERCOM_I2CS_INTENSET_PREC_Pos) +#define SERCOM_I2CS_INTENSET_AMATCH_Pos 1 /**< \brief (SERCOM_I2CS_INTENSET) Address Match Interrupt Enable */ +#define SERCOM_I2CS_INTENSET_AMATCH (0x1u << SERCOM_I2CS_INTENSET_AMATCH_Pos) +#define SERCOM_I2CS_INTENSET_DRDY_Pos 2 /**< \brief (SERCOM_I2CS_INTENSET) Data Interrupt Enable */ +#define SERCOM_I2CS_INTENSET_DRDY (0x1u << SERCOM_I2CS_INTENSET_DRDY_Pos) +#define SERCOM_I2CS_INTENSET_ERROR_Pos 7 /**< \brief (SERCOM_I2CS_INTENSET) Combined Error Interrupt Enable */ +#define SERCOM_I2CS_INTENSET_ERROR (0x1u << SERCOM_I2CS_INTENSET_ERROR_Pos) +#define SERCOM_I2CS_INTENSET_MASK 0x87u /**< \brief (SERCOM_I2CS_INTENSET) MASK Register */ + +/* -------- SERCOM_SPI_INTENSET : (SERCOM Offset: 0x16) (R/W 8) SPI SPI Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DRE:1; /*!< bit: 0 Data Register Empty Interrupt Enable */ + uint8_t TXC:1; /*!< bit: 1 Transmit Complete Interrupt Enable */ + uint8_t RXC:1; /*!< bit: 2 Receive Complete Interrupt Enable */ + uint8_t SSL:1; /*!< bit: 3 Slave Select Low Interrupt Enable */ + uint8_t :3; /*!< bit: 4.. 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_SPI_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_INTENSET_OFFSET 0x16 /**< \brief (SERCOM_SPI_INTENSET offset) SPI Interrupt Enable Set */ +#define SERCOM_SPI_INTENSET_RESETVALUE 0x00 /**< \brief (SERCOM_SPI_INTENSET reset_value) SPI Interrupt Enable Set */ + +#define SERCOM_SPI_INTENSET_DRE_Pos 0 /**< \brief (SERCOM_SPI_INTENSET) Data Register Empty Interrupt Enable */ +#define SERCOM_SPI_INTENSET_DRE (0x1u << SERCOM_SPI_INTENSET_DRE_Pos) +#define SERCOM_SPI_INTENSET_TXC_Pos 1 /**< \brief (SERCOM_SPI_INTENSET) Transmit Complete Interrupt Enable */ +#define SERCOM_SPI_INTENSET_TXC (0x1u << SERCOM_SPI_INTENSET_TXC_Pos) +#define SERCOM_SPI_INTENSET_RXC_Pos 2 /**< \brief (SERCOM_SPI_INTENSET) Receive Complete Interrupt Enable */ +#define SERCOM_SPI_INTENSET_RXC (0x1u << SERCOM_SPI_INTENSET_RXC_Pos) +#define SERCOM_SPI_INTENSET_SSL_Pos 3 /**< \brief (SERCOM_SPI_INTENSET) Slave Select Low Interrupt Enable */ +#define SERCOM_SPI_INTENSET_SSL (0x1u << SERCOM_SPI_INTENSET_SSL_Pos) +#define SERCOM_SPI_INTENSET_ERROR_Pos 7 /**< \brief (SERCOM_SPI_INTENSET) Combined Error Interrupt Enable */ +#define SERCOM_SPI_INTENSET_ERROR (0x1u << SERCOM_SPI_INTENSET_ERROR_Pos) +#define SERCOM_SPI_INTENSET_MASK 0x8Fu /**< \brief (SERCOM_SPI_INTENSET) MASK Register */ + +/* -------- SERCOM_USART_INTENSET : (SERCOM Offset: 0x16) (R/W 8) USART USART Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DRE:1; /*!< bit: 0 Data Register Empty Interrupt Enable */ + uint8_t TXC:1; /*!< bit: 1 Transmit Complete Interrupt Enable */ + uint8_t RXC:1; /*!< bit: 2 Receive Complete Interrupt Enable */ + uint8_t RXS:1; /*!< bit: 3 Receive Start Interrupt Enable */ + uint8_t CTSIC:1; /*!< bit: 4 Clear To Send Input Change Interrupt Enable */ + uint8_t RXBRK:1; /*!< bit: 5 Break Received Interrupt Enable */ + uint8_t :1; /*!< bit: 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt Enable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_USART_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_INTENSET_OFFSET 0x16 /**< \brief (SERCOM_USART_INTENSET offset) USART Interrupt Enable Set */ +#define SERCOM_USART_INTENSET_RESETVALUE 0x00 /**< \brief (SERCOM_USART_INTENSET reset_value) USART Interrupt Enable Set */ + +#define SERCOM_USART_INTENSET_DRE_Pos 0 /**< \brief (SERCOM_USART_INTENSET) Data Register Empty Interrupt Enable */ +#define SERCOM_USART_INTENSET_DRE (0x1u << SERCOM_USART_INTENSET_DRE_Pos) +#define SERCOM_USART_INTENSET_TXC_Pos 1 /**< \brief (SERCOM_USART_INTENSET) Transmit Complete Interrupt Enable */ +#define SERCOM_USART_INTENSET_TXC (0x1u << SERCOM_USART_INTENSET_TXC_Pos) +#define SERCOM_USART_INTENSET_RXC_Pos 2 /**< \brief (SERCOM_USART_INTENSET) Receive Complete Interrupt Enable */ +#define SERCOM_USART_INTENSET_RXC (0x1u << SERCOM_USART_INTENSET_RXC_Pos) +#define SERCOM_USART_INTENSET_RXS_Pos 3 /**< \brief (SERCOM_USART_INTENSET) Receive Start Interrupt Enable */ +#define SERCOM_USART_INTENSET_RXS (0x1u << SERCOM_USART_INTENSET_RXS_Pos) +#define SERCOM_USART_INTENSET_CTSIC_Pos 4 /**< \brief (SERCOM_USART_INTENSET) Clear To Send Input Change Interrupt Enable */ +#define SERCOM_USART_INTENSET_CTSIC (0x1u << SERCOM_USART_INTENSET_CTSIC_Pos) +#define SERCOM_USART_INTENSET_RXBRK_Pos 5 /**< \brief (SERCOM_USART_INTENSET) Break Received Interrupt Enable */ +#define SERCOM_USART_INTENSET_RXBRK (0x1u << SERCOM_USART_INTENSET_RXBRK_Pos) +#define SERCOM_USART_INTENSET_ERROR_Pos 7 /**< \brief (SERCOM_USART_INTENSET) Combined Error Interrupt Enable */ +#define SERCOM_USART_INTENSET_ERROR (0x1u << SERCOM_USART_INTENSET_ERROR_Pos) +#define SERCOM_USART_INTENSET_MASK 0xBFu /**< \brief (SERCOM_USART_INTENSET) MASK Register */ + +/* -------- SERCOM_I2CM_INTFLAG : (SERCOM Offset: 0x18) (R/W 8) I2CM I2CM Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t MB:1; /*!< bit: 0 Master On Bus Interrupt */ + uint8_t SB:1; /*!< bit: 1 Slave On Bus Interrupt */ + uint8_t :5; /*!< bit: 2.. 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_INTFLAG_OFFSET 0x18 /**< \brief (SERCOM_I2CM_INTFLAG offset) I2CM Interrupt Flag Status and Clear */ +#define SERCOM_I2CM_INTFLAG_RESETVALUE 0x00 /**< \brief (SERCOM_I2CM_INTFLAG reset_value) I2CM Interrupt Flag Status and Clear */ + +#define SERCOM_I2CM_INTFLAG_MB_Pos 0 /**< \brief (SERCOM_I2CM_INTFLAG) Master On Bus Interrupt */ +#define SERCOM_I2CM_INTFLAG_MB (0x1u << SERCOM_I2CM_INTFLAG_MB_Pos) +#define SERCOM_I2CM_INTFLAG_SB_Pos 1 /**< \brief (SERCOM_I2CM_INTFLAG) Slave On Bus Interrupt */ +#define SERCOM_I2CM_INTFLAG_SB (0x1u << SERCOM_I2CM_INTFLAG_SB_Pos) +#define SERCOM_I2CM_INTFLAG_ERROR_Pos 7 /**< \brief (SERCOM_I2CM_INTFLAG) Combined Error Interrupt */ +#define SERCOM_I2CM_INTFLAG_ERROR (0x1u << SERCOM_I2CM_INTFLAG_ERROR_Pos) +#define SERCOM_I2CM_INTFLAG_MASK 0x83u /**< \brief (SERCOM_I2CM_INTFLAG) MASK Register */ + +/* -------- SERCOM_I2CS_INTFLAG : (SERCOM Offset: 0x18) (R/W 8) I2CS I2CS Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PREC:1; /*!< bit: 0 Stop Received Interrupt */ + uint8_t AMATCH:1; /*!< bit: 1 Address Match Interrupt */ + uint8_t DRDY:1; /*!< bit: 2 Data Interrupt */ + uint8_t :4; /*!< bit: 3.. 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_I2CS_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CS_INTFLAG_OFFSET 0x18 /**< \brief (SERCOM_I2CS_INTFLAG offset) I2CS Interrupt Flag Status and Clear */ +#define SERCOM_I2CS_INTFLAG_RESETVALUE 0x00 /**< \brief (SERCOM_I2CS_INTFLAG reset_value) I2CS Interrupt Flag Status and Clear */ + +#define SERCOM_I2CS_INTFLAG_PREC_Pos 0 /**< \brief (SERCOM_I2CS_INTFLAG) Stop Received Interrupt */ +#define SERCOM_I2CS_INTFLAG_PREC (0x1u << SERCOM_I2CS_INTFLAG_PREC_Pos) +#define SERCOM_I2CS_INTFLAG_AMATCH_Pos 1 /**< \brief (SERCOM_I2CS_INTFLAG) Address Match Interrupt */ +#define SERCOM_I2CS_INTFLAG_AMATCH (0x1u << SERCOM_I2CS_INTFLAG_AMATCH_Pos) +#define SERCOM_I2CS_INTFLAG_DRDY_Pos 2 /**< \brief (SERCOM_I2CS_INTFLAG) Data Interrupt */ +#define SERCOM_I2CS_INTFLAG_DRDY (0x1u << SERCOM_I2CS_INTFLAG_DRDY_Pos) +#define SERCOM_I2CS_INTFLAG_ERROR_Pos 7 /**< \brief (SERCOM_I2CS_INTFLAG) Combined Error Interrupt */ +#define SERCOM_I2CS_INTFLAG_ERROR (0x1u << SERCOM_I2CS_INTFLAG_ERROR_Pos) +#define SERCOM_I2CS_INTFLAG_MASK 0x87u /**< \brief (SERCOM_I2CS_INTFLAG) MASK Register */ + +/* -------- SERCOM_SPI_INTFLAG : (SERCOM Offset: 0x18) (R/W 8) SPI SPI Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DRE:1; /*!< bit: 0 Data Register Empty Interrupt */ + uint8_t TXC:1; /*!< bit: 1 Transmit Complete Interrupt */ + uint8_t RXC:1; /*!< bit: 2 Receive Complete Interrupt */ + uint8_t SSL:1; /*!< bit: 3 Slave Select Low Interrupt Flag */ + uint8_t :3; /*!< bit: 4.. 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_SPI_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_INTFLAG_OFFSET 0x18 /**< \brief (SERCOM_SPI_INTFLAG offset) SPI Interrupt Flag Status and Clear */ +#define SERCOM_SPI_INTFLAG_RESETVALUE 0x00 /**< \brief (SERCOM_SPI_INTFLAG reset_value) SPI Interrupt Flag Status and Clear */ + +#define SERCOM_SPI_INTFLAG_DRE_Pos 0 /**< \brief (SERCOM_SPI_INTFLAG) Data Register Empty Interrupt */ +#define SERCOM_SPI_INTFLAG_DRE (0x1u << SERCOM_SPI_INTFLAG_DRE_Pos) +#define SERCOM_SPI_INTFLAG_TXC_Pos 1 /**< \brief (SERCOM_SPI_INTFLAG) Transmit Complete Interrupt */ +#define SERCOM_SPI_INTFLAG_TXC (0x1u << SERCOM_SPI_INTFLAG_TXC_Pos) +#define SERCOM_SPI_INTFLAG_RXC_Pos 2 /**< \brief (SERCOM_SPI_INTFLAG) Receive Complete Interrupt */ +#define SERCOM_SPI_INTFLAG_RXC (0x1u << SERCOM_SPI_INTFLAG_RXC_Pos) +#define SERCOM_SPI_INTFLAG_SSL_Pos 3 /**< \brief (SERCOM_SPI_INTFLAG) Slave Select Low Interrupt Flag */ +#define SERCOM_SPI_INTFLAG_SSL (0x1u << SERCOM_SPI_INTFLAG_SSL_Pos) +#define SERCOM_SPI_INTFLAG_ERROR_Pos 7 /**< \brief (SERCOM_SPI_INTFLAG) Combined Error Interrupt */ +#define SERCOM_SPI_INTFLAG_ERROR (0x1u << SERCOM_SPI_INTFLAG_ERROR_Pos) +#define SERCOM_SPI_INTFLAG_MASK 0x8Fu /**< \brief (SERCOM_SPI_INTFLAG) MASK Register */ + +/* -------- SERCOM_USART_INTFLAG : (SERCOM Offset: 0x18) (R/W 8) USART USART Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DRE:1; /*!< bit: 0 Data Register Empty Interrupt */ + uint8_t TXC:1; /*!< bit: 1 Transmit Complete Interrupt */ + uint8_t RXC:1; /*!< bit: 2 Receive Complete Interrupt */ + uint8_t RXS:1; /*!< bit: 3 Receive Start Interrupt */ + uint8_t CTSIC:1; /*!< bit: 4 Clear To Send Input Change Interrupt */ + uint8_t RXBRK:1; /*!< bit: 5 Break Received Interrupt */ + uint8_t :1; /*!< bit: 6 Reserved */ + uint8_t ERROR:1; /*!< bit: 7 Combined Error Interrupt */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_USART_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_INTFLAG_OFFSET 0x18 /**< \brief (SERCOM_USART_INTFLAG offset) USART Interrupt Flag Status and Clear */ +#define SERCOM_USART_INTFLAG_RESETVALUE 0x00 /**< \brief (SERCOM_USART_INTFLAG reset_value) USART Interrupt Flag Status and Clear */ + +#define SERCOM_USART_INTFLAG_DRE_Pos 0 /**< \brief (SERCOM_USART_INTFLAG) Data Register Empty Interrupt */ +#define SERCOM_USART_INTFLAG_DRE (0x1u << SERCOM_USART_INTFLAG_DRE_Pos) +#define SERCOM_USART_INTFLAG_TXC_Pos 1 /**< \brief (SERCOM_USART_INTFLAG) Transmit Complete Interrupt */ +#define SERCOM_USART_INTFLAG_TXC (0x1u << SERCOM_USART_INTFLAG_TXC_Pos) +#define SERCOM_USART_INTFLAG_RXC_Pos 2 /**< \brief (SERCOM_USART_INTFLAG) Receive Complete Interrupt */ +#define SERCOM_USART_INTFLAG_RXC (0x1u << SERCOM_USART_INTFLAG_RXC_Pos) +#define SERCOM_USART_INTFLAG_RXS_Pos 3 /**< \brief (SERCOM_USART_INTFLAG) Receive Start Interrupt */ +#define SERCOM_USART_INTFLAG_RXS (0x1u << SERCOM_USART_INTFLAG_RXS_Pos) +#define SERCOM_USART_INTFLAG_CTSIC_Pos 4 /**< \brief (SERCOM_USART_INTFLAG) Clear To Send Input Change Interrupt */ +#define SERCOM_USART_INTFLAG_CTSIC (0x1u << SERCOM_USART_INTFLAG_CTSIC_Pos) +#define SERCOM_USART_INTFLAG_RXBRK_Pos 5 /**< \brief (SERCOM_USART_INTFLAG) Break Received Interrupt */ +#define SERCOM_USART_INTFLAG_RXBRK (0x1u << SERCOM_USART_INTFLAG_RXBRK_Pos) +#define SERCOM_USART_INTFLAG_ERROR_Pos 7 /**< \brief (SERCOM_USART_INTFLAG) Combined Error Interrupt */ +#define SERCOM_USART_INTFLAG_ERROR (0x1u << SERCOM_USART_INTFLAG_ERROR_Pos) +#define SERCOM_USART_INTFLAG_MASK 0xBFu /**< \brief (SERCOM_USART_INTFLAG) MASK Register */ + +/* -------- SERCOM_I2CM_STATUS : (SERCOM Offset: 0x1A) (R/W 16) I2CM I2CM Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t BUSERR:1; /*!< bit: 0 Bus Error */ + uint16_t ARBLOST:1; /*!< bit: 1 Arbitration Lost */ + uint16_t RXNACK:1; /*!< bit: 2 Received Not Acknowledge */ + uint16_t :1; /*!< bit: 3 Reserved */ + uint16_t BUSSTATE:2; /*!< bit: 4.. 5 Bus State */ + uint16_t LOWTOUT:1; /*!< bit: 6 SCL Low Timeout */ + uint16_t CLKHOLD:1; /*!< bit: 7 Clock Hold */ + uint16_t MEXTTOUT:1; /*!< bit: 8 Master SCL Low Extend Timeout */ + uint16_t SEXTTOUT:1; /*!< bit: 9 Slave SCL Low Extend Timeout */ + uint16_t LENERR:1; /*!< bit: 10 Length Error */ + uint16_t :5; /*!< bit: 11..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_STATUS_OFFSET 0x1A /**< \brief (SERCOM_I2CM_STATUS offset) I2CM Status */ +#define SERCOM_I2CM_STATUS_RESETVALUE 0x0000 /**< \brief (SERCOM_I2CM_STATUS reset_value) I2CM Status */ + +#define SERCOM_I2CM_STATUS_BUSERR_Pos 0 /**< \brief (SERCOM_I2CM_STATUS) Bus Error */ +#define SERCOM_I2CM_STATUS_BUSERR (0x1u << SERCOM_I2CM_STATUS_BUSERR_Pos) +#define SERCOM_I2CM_STATUS_ARBLOST_Pos 1 /**< \brief (SERCOM_I2CM_STATUS) Arbitration Lost */ +#define SERCOM_I2CM_STATUS_ARBLOST (0x1u << SERCOM_I2CM_STATUS_ARBLOST_Pos) +#define SERCOM_I2CM_STATUS_RXNACK_Pos 2 /**< \brief (SERCOM_I2CM_STATUS) Received Not Acknowledge */ +#define SERCOM_I2CM_STATUS_RXNACK (0x1u << SERCOM_I2CM_STATUS_RXNACK_Pos) +#define SERCOM_I2CM_STATUS_BUSSTATE_Pos 4 /**< \brief (SERCOM_I2CM_STATUS) Bus State */ +#define SERCOM_I2CM_STATUS_BUSSTATE_Msk (0x3u << SERCOM_I2CM_STATUS_BUSSTATE_Pos) +#define SERCOM_I2CM_STATUS_BUSSTATE(value) ((SERCOM_I2CM_STATUS_BUSSTATE_Msk & ((value) << SERCOM_I2CM_STATUS_BUSSTATE_Pos))) +#define SERCOM_I2CM_STATUS_LOWTOUT_Pos 6 /**< \brief (SERCOM_I2CM_STATUS) SCL Low Timeout */ +#define SERCOM_I2CM_STATUS_LOWTOUT (0x1u << SERCOM_I2CM_STATUS_LOWTOUT_Pos) +#define SERCOM_I2CM_STATUS_CLKHOLD_Pos 7 /**< \brief (SERCOM_I2CM_STATUS) Clock Hold */ +#define SERCOM_I2CM_STATUS_CLKHOLD (0x1u << SERCOM_I2CM_STATUS_CLKHOLD_Pos) +#define SERCOM_I2CM_STATUS_MEXTTOUT_Pos 8 /**< \brief (SERCOM_I2CM_STATUS) Master SCL Low Extend Timeout */ +#define SERCOM_I2CM_STATUS_MEXTTOUT (0x1u << SERCOM_I2CM_STATUS_MEXTTOUT_Pos) +#define SERCOM_I2CM_STATUS_SEXTTOUT_Pos 9 /**< \brief (SERCOM_I2CM_STATUS) Slave SCL Low Extend Timeout */ +#define SERCOM_I2CM_STATUS_SEXTTOUT (0x1u << SERCOM_I2CM_STATUS_SEXTTOUT_Pos) +#define SERCOM_I2CM_STATUS_LENERR_Pos 10 /**< \brief (SERCOM_I2CM_STATUS) Length Error */ +#define SERCOM_I2CM_STATUS_LENERR (0x1u << SERCOM_I2CM_STATUS_LENERR_Pos) +#define SERCOM_I2CM_STATUS_MASK 0x07F7u /**< \brief (SERCOM_I2CM_STATUS) MASK Register */ + +/* -------- SERCOM_I2CS_STATUS : (SERCOM Offset: 0x1A) (R/W 16) I2CS I2CS Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t BUSERR:1; /*!< bit: 0 Bus Error */ + uint16_t COLL:1; /*!< bit: 1 Transmit Collision */ + uint16_t RXNACK:1; /*!< bit: 2 Received Not Acknowledge */ + uint16_t DIR:1; /*!< bit: 3 Read/Write Direction */ + uint16_t SR:1; /*!< bit: 4 Repeated Start */ + uint16_t :1; /*!< bit: 5 Reserved */ + uint16_t LOWTOUT:1; /*!< bit: 6 SCL Low Timeout */ + uint16_t CLKHOLD:1; /*!< bit: 7 Clock Hold */ + uint16_t :1; /*!< bit: 8 Reserved */ + uint16_t SEXTTOUT:1; /*!< bit: 9 Slave SCL Low Extend Timeout */ + uint16_t HS:1; /*!< bit: 10 High Speed */ + uint16_t :5; /*!< bit: 11..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} SERCOM_I2CS_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CS_STATUS_OFFSET 0x1A /**< \brief (SERCOM_I2CS_STATUS offset) I2CS Status */ +#define SERCOM_I2CS_STATUS_RESETVALUE 0x0000 /**< \brief (SERCOM_I2CS_STATUS reset_value) I2CS Status */ + +#define SERCOM_I2CS_STATUS_BUSERR_Pos 0 /**< \brief (SERCOM_I2CS_STATUS) Bus Error */ +#define SERCOM_I2CS_STATUS_BUSERR (0x1u << SERCOM_I2CS_STATUS_BUSERR_Pos) +#define SERCOM_I2CS_STATUS_COLL_Pos 1 /**< \brief (SERCOM_I2CS_STATUS) Transmit Collision */ +#define SERCOM_I2CS_STATUS_COLL (0x1u << SERCOM_I2CS_STATUS_COLL_Pos) +#define SERCOM_I2CS_STATUS_RXNACK_Pos 2 /**< \brief (SERCOM_I2CS_STATUS) Received Not Acknowledge */ +#define SERCOM_I2CS_STATUS_RXNACK (0x1u << SERCOM_I2CS_STATUS_RXNACK_Pos) +#define SERCOM_I2CS_STATUS_DIR_Pos 3 /**< \brief (SERCOM_I2CS_STATUS) Read/Write Direction */ +#define SERCOM_I2CS_STATUS_DIR (0x1u << SERCOM_I2CS_STATUS_DIR_Pos) +#define SERCOM_I2CS_STATUS_SR_Pos 4 /**< \brief (SERCOM_I2CS_STATUS) Repeated Start */ +#define SERCOM_I2CS_STATUS_SR (0x1u << SERCOM_I2CS_STATUS_SR_Pos) +#define SERCOM_I2CS_STATUS_LOWTOUT_Pos 6 /**< \brief (SERCOM_I2CS_STATUS) SCL Low Timeout */ +#define SERCOM_I2CS_STATUS_LOWTOUT (0x1u << SERCOM_I2CS_STATUS_LOWTOUT_Pos) +#define SERCOM_I2CS_STATUS_CLKHOLD_Pos 7 /**< \brief (SERCOM_I2CS_STATUS) Clock Hold */ +#define SERCOM_I2CS_STATUS_CLKHOLD (0x1u << SERCOM_I2CS_STATUS_CLKHOLD_Pos) +#define SERCOM_I2CS_STATUS_SEXTTOUT_Pos 9 /**< \brief (SERCOM_I2CS_STATUS) Slave SCL Low Extend Timeout */ +#define SERCOM_I2CS_STATUS_SEXTTOUT (0x1u << SERCOM_I2CS_STATUS_SEXTTOUT_Pos) +#define SERCOM_I2CS_STATUS_HS_Pos 10 /**< \brief (SERCOM_I2CS_STATUS) High Speed */ +#define SERCOM_I2CS_STATUS_HS (0x1u << SERCOM_I2CS_STATUS_HS_Pos) +#define SERCOM_I2CS_STATUS_MASK 0x06DFu /**< \brief (SERCOM_I2CS_STATUS) MASK Register */ + +/* -------- SERCOM_SPI_STATUS : (SERCOM Offset: 0x1A) (R/W 16) SPI SPI Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t :2; /*!< bit: 0.. 1 Reserved */ + uint16_t BUFOVF:1; /*!< bit: 2 Buffer Overflow */ + uint16_t :13; /*!< bit: 3..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} SERCOM_SPI_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_STATUS_OFFSET 0x1A /**< \brief (SERCOM_SPI_STATUS offset) SPI Status */ +#define SERCOM_SPI_STATUS_RESETVALUE 0x0000 /**< \brief (SERCOM_SPI_STATUS reset_value) SPI Status */ + +#define SERCOM_SPI_STATUS_BUFOVF_Pos 2 /**< \brief (SERCOM_SPI_STATUS) Buffer Overflow */ +#define SERCOM_SPI_STATUS_BUFOVF (0x1u << SERCOM_SPI_STATUS_BUFOVF_Pos) +#define SERCOM_SPI_STATUS_MASK 0x0004u /**< \brief (SERCOM_SPI_STATUS) MASK Register */ + +/* -------- SERCOM_USART_STATUS : (SERCOM Offset: 0x1A) (R/W 16) USART USART Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t PERR:1; /*!< bit: 0 Parity Error */ + uint16_t FERR:1; /*!< bit: 1 Frame Error */ + uint16_t BUFOVF:1; /*!< bit: 2 Buffer Overflow */ + uint16_t CTS:1; /*!< bit: 3 Clear To Send */ + uint16_t ISF:1; /*!< bit: 4 Inconsistent Sync Field */ + uint16_t COLL:1; /*!< bit: 5 Collision Detected */ + uint16_t :10; /*!< bit: 6..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} SERCOM_USART_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_STATUS_OFFSET 0x1A /**< \brief (SERCOM_USART_STATUS offset) USART Status */ +#define SERCOM_USART_STATUS_RESETVALUE 0x0000 /**< \brief (SERCOM_USART_STATUS reset_value) USART Status */ + +#define SERCOM_USART_STATUS_PERR_Pos 0 /**< \brief (SERCOM_USART_STATUS) Parity Error */ +#define SERCOM_USART_STATUS_PERR (0x1u << SERCOM_USART_STATUS_PERR_Pos) +#define SERCOM_USART_STATUS_FERR_Pos 1 /**< \brief (SERCOM_USART_STATUS) Frame Error */ +#define SERCOM_USART_STATUS_FERR (0x1u << SERCOM_USART_STATUS_FERR_Pos) +#define SERCOM_USART_STATUS_BUFOVF_Pos 2 /**< \brief (SERCOM_USART_STATUS) Buffer Overflow */ +#define SERCOM_USART_STATUS_BUFOVF (0x1u << SERCOM_USART_STATUS_BUFOVF_Pos) +#define SERCOM_USART_STATUS_CTS_Pos 3 /**< \brief (SERCOM_USART_STATUS) Clear To Send */ +#define SERCOM_USART_STATUS_CTS (0x1u << SERCOM_USART_STATUS_CTS_Pos) +#define SERCOM_USART_STATUS_ISF_Pos 4 /**< \brief (SERCOM_USART_STATUS) Inconsistent Sync Field */ +#define SERCOM_USART_STATUS_ISF (0x1u << SERCOM_USART_STATUS_ISF_Pos) +#define SERCOM_USART_STATUS_COLL_Pos 5 /**< \brief (SERCOM_USART_STATUS) Collision Detected */ +#define SERCOM_USART_STATUS_COLL (0x1u << SERCOM_USART_STATUS_COLL_Pos) +#define SERCOM_USART_STATUS_MASK 0x003Fu /**< \brief (SERCOM_USART_STATUS) MASK Register */ + +/* -------- SERCOM_I2CM_SYNCBUSY : (SERCOM Offset: 0x1C) (R/ 32) I2CM I2CM Syncbusy -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Software Reset Synchronization Busy */ + uint32_t ENABLE:1; /*!< bit: 1 SERCOM Enable Synchronization Busy */ + uint32_t SYSOP:1; /*!< bit: 2 System Operation Synchronization Busy */ + uint32_t :29; /*!< bit: 3..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_SYNCBUSY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_SYNCBUSY_OFFSET 0x1C /**< \brief (SERCOM_I2CM_SYNCBUSY offset) I2CM Syncbusy */ +#define SERCOM_I2CM_SYNCBUSY_RESETVALUE 0x00000000 /**< \brief (SERCOM_I2CM_SYNCBUSY reset_value) I2CM Syncbusy */ + +#define SERCOM_I2CM_SYNCBUSY_SWRST_Pos 0 /**< \brief (SERCOM_I2CM_SYNCBUSY) Software Reset Synchronization Busy */ +#define SERCOM_I2CM_SYNCBUSY_SWRST (0x1u << SERCOM_I2CM_SYNCBUSY_SWRST_Pos) +#define SERCOM_I2CM_SYNCBUSY_ENABLE_Pos 1 /**< \brief (SERCOM_I2CM_SYNCBUSY) SERCOM Enable Synchronization Busy */ +#define SERCOM_I2CM_SYNCBUSY_ENABLE (0x1u << SERCOM_I2CM_SYNCBUSY_ENABLE_Pos) +#define SERCOM_I2CM_SYNCBUSY_SYSOP_Pos 2 /**< \brief (SERCOM_I2CM_SYNCBUSY) System Operation Synchronization Busy */ +#define SERCOM_I2CM_SYNCBUSY_SYSOP (0x1u << SERCOM_I2CM_SYNCBUSY_SYSOP_Pos) +#define SERCOM_I2CM_SYNCBUSY_MASK 0x00000007u /**< \brief (SERCOM_I2CM_SYNCBUSY) MASK Register */ + +/* -------- SERCOM_I2CS_SYNCBUSY : (SERCOM Offset: 0x1C) (R/ 32) I2CS I2CS Syncbusy -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Software Reset Synchronization Busy */ + uint32_t ENABLE:1; /*!< bit: 1 SERCOM Enable Synchronization Busy */ + uint32_t :30; /*!< bit: 2..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_I2CS_SYNCBUSY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CS_SYNCBUSY_OFFSET 0x1C /**< \brief (SERCOM_I2CS_SYNCBUSY offset) I2CS Syncbusy */ +#define SERCOM_I2CS_SYNCBUSY_RESETVALUE 0x00000000 /**< \brief (SERCOM_I2CS_SYNCBUSY reset_value) I2CS Syncbusy */ + +#define SERCOM_I2CS_SYNCBUSY_SWRST_Pos 0 /**< \brief (SERCOM_I2CS_SYNCBUSY) Software Reset Synchronization Busy */ +#define SERCOM_I2CS_SYNCBUSY_SWRST (0x1u << SERCOM_I2CS_SYNCBUSY_SWRST_Pos) +#define SERCOM_I2CS_SYNCBUSY_ENABLE_Pos 1 /**< \brief (SERCOM_I2CS_SYNCBUSY) SERCOM Enable Synchronization Busy */ +#define SERCOM_I2CS_SYNCBUSY_ENABLE (0x1u << SERCOM_I2CS_SYNCBUSY_ENABLE_Pos) +#define SERCOM_I2CS_SYNCBUSY_MASK 0x00000003u /**< \brief (SERCOM_I2CS_SYNCBUSY) MASK Register */ + +/* -------- SERCOM_SPI_SYNCBUSY : (SERCOM Offset: 0x1C) (R/ 32) SPI SPI Syncbusy -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Software Reset Synchronization Busy */ + uint32_t ENABLE:1; /*!< bit: 1 SERCOM Enable Synchronization Busy */ + uint32_t CTRLB:1; /*!< bit: 2 CTRLB Synchronization Busy */ + uint32_t :29; /*!< bit: 3..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_SPI_SYNCBUSY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_SYNCBUSY_OFFSET 0x1C /**< \brief (SERCOM_SPI_SYNCBUSY offset) SPI Syncbusy */ +#define SERCOM_SPI_SYNCBUSY_RESETVALUE 0x00000000 /**< \brief (SERCOM_SPI_SYNCBUSY reset_value) SPI Syncbusy */ + +#define SERCOM_SPI_SYNCBUSY_SWRST_Pos 0 /**< \brief (SERCOM_SPI_SYNCBUSY) Software Reset Synchronization Busy */ +#define SERCOM_SPI_SYNCBUSY_SWRST (0x1u << SERCOM_SPI_SYNCBUSY_SWRST_Pos) +#define SERCOM_SPI_SYNCBUSY_ENABLE_Pos 1 /**< \brief (SERCOM_SPI_SYNCBUSY) SERCOM Enable Synchronization Busy */ +#define SERCOM_SPI_SYNCBUSY_ENABLE (0x1u << SERCOM_SPI_SYNCBUSY_ENABLE_Pos) +#define SERCOM_SPI_SYNCBUSY_CTRLB_Pos 2 /**< \brief (SERCOM_SPI_SYNCBUSY) CTRLB Synchronization Busy */ +#define SERCOM_SPI_SYNCBUSY_CTRLB (0x1u << SERCOM_SPI_SYNCBUSY_CTRLB_Pos) +#define SERCOM_SPI_SYNCBUSY_MASK 0x00000007u /**< \brief (SERCOM_SPI_SYNCBUSY) MASK Register */ + +/* -------- SERCOM_USART_SYNCBUSY : (SERCOM Offset: 0x1C) (R/ 32) USART USART Syncbusy -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Software Reset Synchronization Busy */ + uint32_t ENABLE:1; /*!< bit: 1 SERCOM Enable Synchronization Busy */ + uint32_t CTRLB:1; /*!< bit: 2 CTRLB Synchronization Busy */ + uint32_t :29; /*!< bit: 3..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_USART_SYNCBUSY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_SYNCBUSY_OFFSET 0x1C /**< \brief (SERCOM_USART_SYNCBUSY offset) USART Syncbusy */ +#define SERCOM_USART_SYNCBUSY_RESETVALUE 0x00000000 /**< \brief (SERCOM_USART_SYNCBUSY reset_value) USART Syncbusy */ + +#define SERCOM_USART_SYNCBUSY_SWRST_Pos 0 /**< \brief (SERCOM_USART_SYNCBUSY) Software Reset Synchronization Busy */ +#define SERCOM_USART_SYNCBUSY_SWRST (0x1u << SERCOM_USART_SYNCBUSY_SWRST_Pos) +#define SERCOM_USART_SYNCBUSY_ENABLE_Pos 1 /**< \brief (SERCOM_USART_SYNCBUSY) SERCOM Enable Synchronization Busy */ +#define SERCOM_USART_SYNCBUSY_ENABLE (0x1u << SERCOM_USART_SYNCBUSY_ENABLE_Pos) +#define SERCOM_USART_SYNCBUSY_CTRLB_Pos 2 /**< \brief (SERCOM_USART_SYNCBUSY) CTRLB Synchronization Busy */ +#define SERCOM_USART_SYNCBUSY_CTRLB (0x1u << SERCOM_USART_SYNCBUSY_CTRLB_Pos) +#define SERCOM_USART_SYNCBUSY_MASK 0x00000007u /**< \brief (SERCOM_USART_SYNCBUSY) MASK Register */ + +/* -------- SERCOM_I2CM_ADDR : (SERCOM Offset: 0x24) (R/W 32) I2CM I2CM Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t ADDR:11; /*!< bit: 0..10 Address Value */ + uint32_t :2; /*!< bit: 11..12 Reserved */ + uint32_t LENEN:1; /*!< bit: 13 Length Enable */ + uint32_t HS:1; /*!< bit: 14 High Speed Mode */ + uint32_t TENBITEN:1; /*!< bit: 15 Ten Bit Addressing Enable */ + uint32_t LEN:8; /*!< bit: 16..23 Length */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_ADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_ADDR_OFFSET 0x24 /**< \brief (SERCOM_I2CM_ADDR offset) I2CM Address */ +#define SERCOM_I2CM_ADDR_RESETVALUE 0x00000000 /**< \brief (SERCOM_I2CM_ADDR reset_value) I2CM Address */ + +#define SERCOM_I2CM_ADDR_ADDR_Pos 0 /**< \brief (SERCOM_I2CM_ADDR) Address Value */ +#define SERCOM_I2CM_ADDR_ADDR_Msk (0x7FFu << SERCOM_I2CM_ADDR_ADDR_Pos) +#define SERCOM_I2CM_ADDR_ADDR(value) ((SERCOM_I2CM_ADDR_ADDR_Msk & ((value) << SERCOM_I2CM_ADDR_ADDR_Pos))) +#define SERCOM_I2CM_ADDR_LENEN_Pos 13 /**< \brief (SERCOM_I2CM_ADDR) Length Enable */ +#define SERCOM_I2CM_ADDR_LENEN (0x1u << SERCOM_I2CM_ADDR_LENEN_Pos) +#define SERCOM_I2CM_ADDR_HS_Pos 14 /**< \brief (SERCOM_I2CM_ADDR) High Speed Mode */ +#define SERCOM_I2CM_ADDR_HS (0x1u << SERCOM_I2CM_ADDR_HS_Pos) +#define SERCOM_I2CM_ADDR_TENBITEN_Pos 15 /**< \brief (SERCOM_I2CM_ADDR) Ten Bit Addressing Enable */ +#define SERCOM_I2CM_ADDR_TENBITEN (0x1u << SERCOM_I2CM_ADDR_TENBITEN_Pos) +#define SERCOM_I2CM_ADDR_LEN_Pos 16 /**< \brief (SERCOM_I2CM_ADDR) Length */ +#define SERCOM_I2CM_ADDR_LEN_Msk (0xFFu << SERCOM_I2CM_ADDR_LEN_Pos) +#define SERCOM_I2CM_ADDR_LEN(value) ((SERCOM_I2CM_ADDR_LEN_Msk & ((value) << SERCOM_I2CM_ADDR_LEN_Pos))) +#define SERCOM_I2CM_ADDR_MASK 0x00FFE7FFu /**< \brief (SERCOM_I2CM_ADDR) MASK Register */ + +/* -------- SERCOM_I2CS_ADDR : (SERCOM Offset: 0x24) (R/W 32) I2CS I2CS Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t GENCEN:1; /*!< bit: 0 General Call Address Enable */ + uint32_t ADDR:10; /*!< bit: 1..10 Address Value */ + uint32_t :4; /*!< bit: 11..14 Reserved */ + uint32_t TENBITEN:1; /*!< bit: 15 Ten Bit Addressing Enable */ + uint32_t :1; /*!< bit: 16 Reserved */ + uint32_t ADDRMASK:10; /*!< bit: 17..26 Address Mask */ + uint32_t :5; /*!< bit: 27..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_I2CS_ADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CS_ADDR_OFFSET 0x24 /**< \brief (SERCOM_I2CS_ADDR offset) I2CS Address */ +#define SERCOM_I2CS_ADDR_RESETVALUE 0x00000000 /**< \brief (SERCOM_I2CS_ADDR reset_value) I2CS Address */ + +#define SERCOM_I2CS_ADDR_GENCEN_Pos 0 /**< \brief (SERCOM_I2CS_ADDR) General Call Address Enable */ +#define SERCOM_I2CS_ADDR_GENCEN (0x1u << SERCOM_I2CS_ADDR_GENCEN_Pos) +#define SERCOM_I2CS_ADDR_ADDR_Pos 1 /**< \brief (SERCOM_I2CS_ADDR) Address Value */ +#define SERCOM_I2CS_ADDR_ADDR_Msk (0x3FFu << SERCOM_I2CS_ADDR_ADDR_Pos) +#define SERCOM_I2CS_ADDR_ADDR(value) ((SERCOM_I2CS_ADDR_ADDR_Msk & ((value) << SERCOM_I2CS_ADDR_ADDR_Pos))) +#define SERCOM_I2CS_ADDR_TENBITEN_Pos 15 /**< \brief (SERCOM_I2CS_ADDR) Ten Bit Addressing Enable */ +#define SERCOM_I2CS_ADDR_TENBITEN (0x1u << SERCOM_I2CS_ADDR_TENBITEN_Pos) +#define SERCOM_I2CS_ADDR_ADDRMASK_Pos 17 /**< \brief (SERCOM_I2CS_ADDR) Address Mask */ +#define SERCOM_I2CS_ADDR_ADDRMASK_Msk (0x3FFu << SERCOM_I2CS_ADDR_ADDRMASK_Pos) +#define SERCOM_I2CS_ADDR_ADDRMASK(value) ((SERCOM_I2CS_ADDR_ADDRMASK_Msk & ((value) << SERCOM_I2CS_ADDR_ADDRMASK_Pos))) +#define SERCOM_I2CS_ADDR_MASK 0x07FE87FFu /**< \brief (SERCOM_I2CS_ADDR) MASK Register */ + +/* -------- SERCOM_SPI_ADDR : (SERCOM Offset: 0x24) (R/W 32) SPI SPI Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t ADDR:8; /*!< bit: 0.. 7 Address Value */ + uint32_t :8; /*!< bit: 8..15 Reserved */ + uint32_t ADDRMASK:8; /*!< bit: 16..23 Address Mask */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_SPI_ADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_ADDR_OFFSET 0x24 /**< \brief (SERCOM_SPI_ADDR offset) SPI Address */ +#define SERCOM_SPI_ADDR_RESETVALUE 0x00000000 /**< \brief (SERCOM_SPI_ADDR reset_value) SPI Address */ + +#define SERCOM_SPI_ADDR_ADDR_Pos 0 /**< \brief (SERCOM_SPI_ADDR) Address Value */ +#define SERCOM_SPI_ADDR_ADDR_Msk (0xFFu << SERCOM_SPI_ADDR_ADDR_Pos) +#define SERCOM_SPI_ADDR_ADDR(value) ((SERCOM_SPI_ADDR_ADDR_Msk & ((value) << SERCOM_SPI_ADDR_ADDR_Pos))) +#define SERCOM_SPI_ADDR_ADDRMASK_Pos 16 /**< \brief (SERCOM_SPI_ADDR) Address Mask */ +#define SERCOM_SPI_ADDR_ADDRMASK_Msk (0xFFu << SERCOM_SPI_ADDR_ADDRMASK_Pos) +#define SERCOM_SPI_ADDR_ADDRMASK(value) ((SERCOM_SPI_ADDR_ADDRMASK_Msk & ((value) << SERCOM_SPI_ADDR_ADDRMASK_Pos))) +#define SERCOM_SPI_ADDR_MASK 0x00FF00FFu /**< \brief (SERCOM_SPI_ADDR) MASK Register */ + +/* -------- SERCOM_I2CM_DATA : (SERCOM Offset: 0x28) (R/W 8) I2CM I2CM Data -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DATA:8; /*!< bit: 0.. 7 Data Value */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_DATA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_DATA_OFFSET 0x28 /**< \brief (SERCOM_I2CM_DATA offset) I2CM Data */ +#define SERCOM_I2CM_DATA_RESETVALUE 0x00 /**< \brief (SERCOM_I2CM_DATA reset_value) I2CM Data */ + +#define SERCOM_I2CM_DATA_DATA_Pos 0 /**< \brief (SERCOM_I2CM_DATA) Data Value */ +#define SERCOM_I2CM_DATA_DATA_Msk (0xFFu << SERCOM_I2CM_DATA_DATA_Pos) +#define SERCOM_I2CM_DATA_DATA(value) ((SERCOM_I2CM_DATA_DATA_Msk & ((value) << SERCOM_I2CM_DATA_DATA_Pos))) +#define SERCOM_I2CM_DATA_MASK 0xFFu /**< \brief (SERCOM_I2CM_DATA) MASK Register */ + +/* -------- SERCOM_I2CS_DATA : (SERCOM Offset: 0x28) (R/W 8) I2CS I2CS Data -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DATA:8; /*!< bit: 0.. 7 Data Value */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_I2CS_DATA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CS_DATA_OFFSET 0x28 /**< \brief (SERCOM_I2CS_DATA offset) I2CS Data */ +#define SERCOM_I2CS_DATA_RESETVALUE 0x00 /**< \brief (SERCOM_I2CS_DATA reset_value) I2CS Data */ + +#define SERCOM_I2CS_DATA_DATA_Pos 0 /**< \brief (SERCOM_I2CS_DATA) Data Value */ +#define SERCOM_I2CS_DATA_DATA_Msk (0xFFu << SERCOM_I2CS_DATA_DATA_Pos) +#define SERCOM_I2CS_DATA_DATA(value) ((SERCOM_I2CS_DATA_DATA_Msk & ((value) << SERCOM_I2CS_DATA_DATA_Pos))) +#define SERCOM_I2CS_DATA_MASK 0xFFu /**< \brief (SERCOM_I2CS_DATA) MASK Register */ + +/* -------- SERCOM_SPI_DATA : (SERCOM Offset: 0x28) (R/W 32) SPI SPI Data -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DATA:9; /*!< bit: 0.. 8 Data Value */ + uint32_t :23; /*!< bit: 9..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SERCOM_SPI_DATA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_DATA_OFFSET 0x28 /**< \brief (SERCOM_SPI_DATA offset) SPI Data */ +#define SERCOM_SPI_DATA_RESETVALUE 0x00000000 /**< \brief (SERCOM_SPI_DATA reset_value) SPI Data */ + +#define SERCOM_SPI_DATA_DATA_Pos 0 /**< \brief (SERCOM_SPI_DATA) Data Value */ +#define SERCOM_SPI_DATA_DATA_Msk (0x1FFu << SERCOM_SPI_DATA_DATA_Pos) +#define SERCOM_SPI_DATA_DATA(value) ((SERCOM_SPI_DATA_DATA_Msk & ((value) << SERCOM_SPI_DATA_DATA_Pos))) +#define SERCOM_SPI_DATA_MASK 0x000001FFu /**< \brief (SERCOM_SPI_DATA) MASK Register */ + +/* -------- SERCOM_USART_DATA : (SERCOM Offset: 0x28) (R/W 16) USART USART Data -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t DATA:9; /*!< bit: 0.. 8 Data Value */ + uint16_t :7; /*!< bit: 9..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} SERCOM_USART_DATA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_DATA_OFFSET 0x28 /**< \brief (SERCOM_USART_DATA offset) USART Data */ +#define SERCOM_USART_DATA_RESETVALUE 0x0000 /**< \brief (SERCOM_USART_DATA reset_value) USART Data */ + +#define SERCOM_USART_DATA_DATA_Pos 0 /**< \brief (SERCOM_USART_DATA) Data Value */ +#define SERCOM_USART_DATA_DATA_Msk (0x1FFu << SERCOM_USART_DATA_DATA_Pos) +#define SERCOM_USART_DATA_DATA(value) ((SERCOM_USART_DATA_DATA_Msk & ((value) << SERCOM_USART_DATA_DATA_Pos))) +#define SERCOM_USART_DATA_MASK 0x01FFu /**< \brief (SERCOM_USART_DATA) MASK Register */ + +/* -------- SERCOM_I2CM_DBGCTRL : (SERCOM Offset: 0x30) (R/W 8) I2CM I2CM Debug Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DBGSTOP:1; /*!< bit: 0 Debug Mode */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_I2CM_DBGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_I2CM_DBGCTRL_OFFSET 0x30 /**< \brief (SERCOM_I2CM_DBGCTRL offset) I2CM Debug Control */ +#define SERCOM_I2CM_DBGCTRL_RESETVALUE 0x00 /**< \brief (SERCOM_I2CM_DBGCTRL reset_value) I2CM Debug Control */ + +#define SERCOM_I2CM_DBGCTRL_DBGSTOP_Pos 0 /**< \brief (SERCOM_I2CM_DBGCTRL) Debug Mode */ +#define SERCOM_I2CM_DBGCTRL_DBGSTOP (0x1u << SERCOM_I2CM_DBGCTRL_DBGSTOP_Pos) +#define SERCOM_I2CM_DBGCTRL_MASK 0x01u /**< \brief (SERCOM_I2CM_DBGCTRL) MASK Register */ + +/* -------- SERCOM_SPI_DBGCTRL : (SERCOM Offset: 0x30) (R/W 8) SPI SPI Debug Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DBGSTOP:1; /*!< bit: 0 Debug Mode */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_SPI_DBGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_SPI_DBGCTRL_OFFSET 0x30 /**< \brief (SERCOM_SPI_DBGCTRL offset) SPI Debug Control */ +#define SERCOM_SPI_DBGCTRL_RESETVALUE 0x00 /**< \brief (SERCOM_SPI_DBGCTRL reset_value) SPI Debug Control */ + +#define SERCOM_SPI_DBGCTRL_DBGSTOP_Pos 0 /**< \brief (SERCOM_SPI_DBGCTRL) Debug Mode */ +#define SERCOM_SPI_DBGCTRL_DBGSTOP (0x1u << SERCOM_SPI_DBGCTRL_DBGSTOP_Pos) +#define SERCOM_SPI_DBGCTRL_MASK 0x01u /**< \brief (SERCOM_SPI_DBGCTRL) MASK Register */ + +/* -------- SERCOM_USART_DBGCTRL : (SERCOM Offset: 0x30) (R/W 8) USART USART Debug Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DBGSTOP:1; /*!< bit: 0 Debug Mode */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SERCOM_USART_DBGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SERCOM_USART_DBGCTRL_OFFSET 0x30 /**< \brief (SERCOM_USART_DBGCTRL offset) USART Debug Control */ +#define SERCOM_USART_DBGCTRL_RESETVALUE 0x00 /**< \brief (SERCOM_USART_DBGCTRL reset_value) USART Debug Control */ + +#define SERCOM_USART_DBGCTRL_DBGSTOP_Pos 0 /**< \brief (SERCOM_USART_DBGCTRL) Debug Mode */ +#define SERCOM_USART_DBGCTRL_DBGSTOP (0x1u << SERCOM_USART_DBGCTRL_DBGSTOP_Pos) +#define SERCOM_USART_DBGCTRL_MASK 0x01u /**< \brief (SERCOM_USART_DBGCTRL) MASK Register */ + +/** \brief SERCOM_I2CM hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* I2C Master Mode */ + __IO SERCOM_I2CM_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 32) I2CM Control A */ + __IO SERCOM_I2CM_CTRLB_Type CTRLB; /**< \brief Offset: 0x04 (R/W 32) I2CM Control B */ + RoReg8 Reserved1[0x4]; + __IO SERCOM_I2CM_BAUD_Type BAUD; /**< \brief Offset: 0x0C (R/W 32) I2CM Baud Rate */ + RoReg8 Reserved2[0x4]; + __IO SERCOM_I2CM_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x14 (R/W 8) I2CM Interrupt Enable Clear */ + RoReg8 Reserved3[0x1]; + __IO SERCOM_I2CM_INTENSET_Type INTENSET; /**< \brief Offset: 0x16 (R/W 8) I2CM Interrupt Enable Set */ + RoReg8 Reserved4[0x1]; + __IO SERCOM_I2CM_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x18 (R/W 8) I2CM Interrupt Flag Status and Clear */ + RoReg8 Reserved5[0x1]; + __IO SERCOM_I2CM_STATUS_Type STATUS; /**< \brief Offset: 0x1A (R/W 16) I2CM Status */ + __I SERCOM_I2CM_SYNCBUSY_Type SYNCBUSY; /**< \brief Offset: 0x1C (R/ 32) I2CM Syncbusy */ + RoReg8 Reserved6[0x4]; + __IO SERCOM_I2CM_ADDR_Type ADDR; /**< \brief Offset: 0x24 (R/W 32) I2CM Address */ + __IO SERCOM_I2CM_DATA_Type DATA; /**< \brief Offset: 0x28 (R/W 8) I2CM Data */ + RoReg8 Reserved7[0x7]; + __IO SERCOM_I2CM_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x30 (R/W 8) I2CM Debug Control */ +} SercomI2cm; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief SERCOM_I2CS hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* I2C Slave Mode */ + __IO SERCOM_I2CS_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 32) I2CS Control A */ + __IO SERCOM_I2CS_CTRLB_Type CTRLB; /**< \brief Offset: 0x04 (R/W 32) I2CS Control B */ + RoReg8 Reserved1[0xC]; + __IO SERCOM_I2CS_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x14 (R/W 8) I2CS Interrupt Enable Clear */ + RoReg8 Reserved2[0x1]; + __IO SERCOM_I2CS_INTENSET_Type INTENSET; /**< \brief Offset: 0x16 (R/W 8) I2CS Interrupt Enable Set */ + RoReg8 Reserved3[0x1]; + __IO SERCOM_I2CS_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x18 (R/W 8) I2CS Interrupt Flag Status and Clear */ + RoReg8 Reserved4[0x1]; + __IO SERCOM_I2CS_STATUS_Type STATUS; /**< \brief Offset: 0x1A (R/W 16) I2CS Status */ + __I SERCOM_I2CS_SYNCBUSY_Type SYNCBUSY; /**< \brief Offset: 0x1C (R/ 32) I2CS Syncbusy */ + RoReg8 Reserved5[0x4]; + __IO SERCOM_I2CS_ADDR_Type ADDR; /**< \brief Offset: 0x24 (R/W 32) I2CS Address */ + __IO SERCOM_I2CS_DATA_Type DATA; /**< \brief Offset: 0x28 (R/W 8) I2CS Data */ +} SercomI2cs; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief SERCOM_SPI hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* SPI Mode */ + __IO SERCOM_SPI_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 32) SPI Control A */ + __IO SERCOM_SPI_CTRLB_Type CTRLB; /**< \brief Offset: 0x04 (R/W 32) SPI Control B */ + RoReg8 Reserved1[0x4]; + __IO SERCOM_SPI_BAUD_Type BAUD; /**< \brief Offset: 0x0C (R/W 8) SPI Baud Rate */ + RoReg8 Reserved2[0x7]; + __IO SERCOM_SPI_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x14 (R/W 8) SPI Interrupt Enable Clear */ + RoReg8 Reserved3[0x1]; + __IO SERCOM_SPI_INTENSET_Type INTENSET; /**< \brief Offset: 0x16 (R/W 8) SPI Interrupt Enable Set */ + RoReg8 Reserved4[0x1]; + __IO SERCOM_SPI_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x18 (R/W 8) SPI Interrupt Flag Status and Clear */ + RoReg8 Reserved5[0x1]; + __IO SERCOM_SPI_STATUS_Type STATUS; /**< \brief Offset: 0x1A (R/W 16) SPI Status */ + __I SERCOM_SPI_SYNCBUSY_Type SYNCBUSY; /**< \brief Offset: 0x1C (R/ 32) SPI Syncbusy */ + RoReg8 Reserved6[0x4]; + __IO SERCOM_SPI_ADDR_Type ADDR; /**< \brief Offset: 0x24 (R/W 32) SPI Address */ + __IO SERCOM_SPI_DATA_Type DATA; /**< \brief Offset: 0x28 (R/W 32) SPI Data */ + RoReg8 Reserved7[0x4]; + __IO SERCOM_SPI_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x30 (R/W 8) SPI Debug Control */ +} SercomSpi; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief SERCOM_USART hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* USART Mode */ + __IO SERCOM_USART_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 32) USART Control A */ + __IO SERCOM_USART_CTRLB_Type CTRLB; /**< \brief Offset: 0x04 (R/W 32) USART Control B */ + RoReg8 Reserved1[0x4]; + __IO SERCOM_USART_BAUD_Type BAUD; /**< \brief Offset: 0x0C (R/W 16) USART Baud Rate */ + __IO SERCOM_USART_RXPL_Type RXPL; /**< \brief Offset: 0x0E (R/W 8) USART Receive Pulse Length */ + RoReg8 Reserved2[0x5]; + __IO SERCOM_USART_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x14 (R/W 8) USART Interrupt Enable Clear */ + RoReg8 Reserved3[0x1]; + __IO SERCOM_USART_INTENSET_Type INTENSET; /**< \brief Offset: 0x16 (R/W 8) USART Interrupt Enable Set */ + RoReg8 Reserved4[0x1]; + __IO SERCOM_USART_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x18 (R/W 8) USART Interrupt Flag Status and Clear */ + RoReg8 Reserved5[0x1]; + __IO SERCOM_USART_STATUS_Type STATUS; /**< \brief Offset: 0x1A (R/W 16) USART Status */ + __I SERCOM_USART_SYNCBUSY_Type SYNCBUSY; /**< \brief Offset: 0x1C (R/ 32) USART Syncbusy */ + RoReg8 Reserved6[0x8]; + __IO SERCOM_USART_DATA_Type DATA; /**< \brief Offset: 0x28 (R/W 16) USART Data */ + RoReg8 Reserved7[0x6]; + __IO SERCOM_USART_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x30 (R/W 8) USART Debug Control */ +} SercomUsart; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + SercomI2cm I2CM; /**< \brief Offset: 0x00 I2C Master Mode */ + SercomI2cs I2CS; /**< \brief Offset: 0x00 I2C Slave Mode */ + SercomSpi SPI; /**< \brief Offset: 0x00 SPI Mode */ + SercomUsart USART; /**< \brief Offset: 0x00 USART Mode */ +} Sercom; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_SERCOM_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/sysctrl.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/sysctrl.h new file mode 100755 index 0000000..00980e4 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/sysctrl.h @@ -0,0 +1,948 @@ +/** + * \file + * + * \brief Component description for SYSCTRL + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_SYSCTRL_COMPONENT_ +#define _SAMD21_SYSCTRL_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR SYSCTRL */ +/* ========================================================================== */ +/** \addtogroup SAMD21_SYSCTRL System Control */ +/*@{*/ + +#define SYSCTRL_U2100 +#define REV_SYSCTRL 0x201 + +/* -------- SYSCTRL_INTENCLR : (SYSCTRL Offset: 0x00) (R/W 32) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t XOSCRDY:1; /*!< bit: 0 XOSC Ready Interrupt Enable */ + uint32_t XOSC32KRDY:1; /*!< bit: 1 XOSC32K Ready Interrupt Enable */ + uint32_t OSC32KRDY:1; /*!< bit: 2 OSC32K Ready Interrupt Enable */ + uint32_t OSC8MRDY:1; /*!< bit: 3 OSC8M Ready Interrupt Enable */ + uint32_t DFLLRDY:1; /*!< bit: 4 DFLL Ready Interrupt Enable */ + uint32_t DFLLOOB:1; /*!< bit: 5 DFLL Out Of Bounds Interrupt Enable */ + uint32_t DFLLLCKF:1; /*!< bit: 6 DFLL Lock Fine Interrupt Enable */ + uint32_t DFLLLCKC:1; /*!< bit: 7 DFLL Lock Coarse Interrupt Enable */ + uint32_t DFLLRCS:1; /*!< bit: 8 DFLL Reference Clock Stopped Interrupt Enable */ + uint32_t BOD33RDY:1; /*!< bit: 9 BOD33 Ready Interrupt Enable */ + uint32_t BOD33DET:1; /*!< bit: 10 BOD33 Detection Interrupt Enable */ + uint32_t B33SRDY:1; /*!< bit: 11 BOD33 Synchronization Ready Interrupt Enable */ + uint32_t :3; /*!< bit: 12..14 Reserved */ + uint32_t DPLLLCKR:1; /*!< bit: 15 DPLL Lock Rise Interrupt Enable */ + uint32_t DPLLLCKF:1; /*!< bit: 16 DPLL Lock Fall Interrupt Enable */ + uint32_t DPLLLTO:1; /*!< bit: 17 DPLL Lock Timeout Interrupt Enable */ + uint32_t :14; /*!< bit: 18..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_INTENCLR_OFFSET 0x00 /**< \brief (SYSCTRL_INTENCLR offset) Interrupt Enable Clear */ +#define SYSCTRL_INTENCLR_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_INTENCLR reset_value) Interrupt Enable Clear */ + +#define SYSCTRL_INTENCLR_XOSCRDY_Pos 0 /**< \brief (SYSCTRL_INTENCLR) XOSC Ready Interrupt Enable */ +#define SYSCTRL_INTENCLR_XOSCRDY (0x1u << SYSCTRL_INTENCLR_XOSCRDY_Pos) +#define SYSCTRL_INTENCLR_XOSC32KRDY_Pos 1 /**< \brief (SYSCTRL_INTENCLR) XOSC32K Ready Interrupt Enable */ +#define SYSCTRL_INTENCLR_XOSC32KRDY (0x1u << SYSCTRL_INTENCLR_XOSC32KRDY_Pos) +#define SYSCTRL_INTENCLR_OSC32KRDY_Pos 2 /**< \brief (SYSCTRL_INTENCLR) OSC32K Ready Interrupt Enable */ +#define SYSCTRL_INTENCLR_OSC32KRDY (0x1u << SYSCTRL_INTENCLR_OSC32KRDY_Pos) +#define SYSCTRL_INTENCLR_OSC8MRDY_Pos 3 /**< \brief (SYSCTRL_INTENCLR) OSC8M Ready Interrupt Enable */ +#define SYSCTRL_INTENCLR_OSC8MRDY (0x1u << SYSCTRL_INTENCLR_OSC8MRDY_Pos) +#define SYSCTRL_INTENCLR_DFLLRDY_Pos 4 /**< \brief (SYSCTRL_INTENCLR) DFLL Ready Interrupt Enable */ +#define SYSCTRL_INTENCLR_DFLLRDY (0x1u << SYSCTRL_INTENCLR_DFLLRDY_Pos) +#define SYSCTRL_INTENCLR_DFLLOOB_Pos 5 /**< \brief (SYSCTRL_INTENCLR) DFLL Out Of Bounds Interrupt Enable */ +#define SYSCTRL_INTENCLR_DFLLOOB (0x1u << SYSCTRL_INTENCLR_DFLLOOB_Pos) +#define SYSCTRL_INTENCLR_DFLLLCKF_Pos 6 /**< \brief (SYSCTRL_INTENCLR) DFLL Lock Fine Interrupt Enable */ +#define SYSCTRL_INTENCLR_DFLLLCKF (0x1u << SYSCTRL_INTENCLR_DFLLLCKF_Pos) +#define SYSCTRL_INTENCLR_DFLLLCKC_Pos 7 /**< \brief (SYSCTRL_INTENCLR) DFLL Lock Coarse Interrupt Enable */ +#define SYSCTRL_INTENCLR_DFLLLCKC (0x1u << SYSCTRL_INTENCLR_DFLLLCKC_Pos) +#define SYSCTRL_INTENCLR_DFLLRCS_Pos 8 /**< \brief (SYSCTRL_INTENCLR) DFLL Reference Clock Stopped Interrupt Enable */ +#define SYSCTRL_INTENCLR_DFLLRCS (0x1u << SYSCTRL_INTENCLR_DFLLRCS_Pos) +#define SYSCTRL_INTENCLR_BOD33RDY_Pos 9 /**< \brief (SYSCTRL_INTENCLR) BOD33 Ready Interrupt Enable */ +#define SYSCTRL_INTENCLR_BOD33RDY (0x1u << SYSCTRL_INTENCLR_BOD33RDY_Pos) +#define SYSCTRL_INTENCLR_BOD33DET_Pos 10 /**< \brief (SYSCTRL_INTENCLR) BOD33 Detection Interrupt Enable */ +#define SYSCTRL_INTENCLR_BOD33DET (0x1u << SYSCTRL_INTENCLR_BOD33DET_Pos) +#define SYSCTRL_INTENCLR_B33SRDY_Pos 11 /**< \brief (SYSCTRL_INTENCLR) BOD33 Synchronization Ready Interrupt Enable */ +#define SYSCTRL_INTENCLR_B33SRDY (0x1u << SYSCTRL_INTENCLR_B33SRDY_Pos) +#define SYSCTRL_INTENCLR_DPLLLCKR_Pos 15 /**< \brief (SYSCTRL_INTENCLR) DPLL Lock Rise Interrupt Enable */ +#define SYSCTRL_INTENCLR_DPLLLCKR (0x1u << SYSCTRL_INTENCLR_DPLLLCKR_Pos) +#define SYSCTRL_INTENCLR_DPLLLCKF_Pos 16 /**< \brief (SYSCTRL_INTENCLR) DPLL Lock Fall Interrupt Enable */ +#define SYSCTRL_INTENCLR_DPLLLCKF (0x1u << SYSCTRL_INTENCLR_DPLLLCKF_Pos) +#define SYSCTRL_INTENCLR_DPLLLTO_Pos 17 /**< \brief (SYSCTRL_INTENCLR) DPLL Lock Timeout Interrupt Enable */ +#define SYSCTRL_INTENCLR_DPLLLTO (0x1u << SYSCTRL_INTENCLR_DPLLLTO_Pos) +#define SYSCTRL_INTENCLR_MASK 0x00038FFFu /**< \brief (SYSCTRL_INTENCLR) MASK Register */ + +/* -------- SYSCTRL_INTENSET : (SYSCTRL Offset: 0x04) (R/W 32) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t XOSCRDY:1; /*!< bit: 0 XOSC Ready Interrupt Enable */ + uint32_t XOSC32KRDY:1; /*!< bit: 1 XOSC32K Ready Interrupt Enable */ + uint32_t OSC32KRDY:1; /*!< bit: 2 OSC32K Ready Interrupt Enable */ + uint32_t OSC8MRDY:1; /*!< bit: 3 OSC8M Ready Interrupt Enable */ + uint32_t DFLLRDY:1; /*!< bit: 4 DFLL Ready Interrupt Enable */ + uint32_t DFLLOOB:1; /*!< bit: 5 DFLL Out Of Bounds Interrupt Enable */ + uint32_t DFLLLCKF:1; /*!< bit: 6 DFLL Lock Fine Interrupt Enable */ + uint32_t DFLLLCKC:1; /*!< bit: 7 DFLL Lock Coarse Interrupt Enable */ + uint32_t DFLLRCS:1; /*!< bit: 8 DFLL Reference Clock Stopped Interrupt Enable */ + uint32_t BOD33RDY:1; /*!< bit: 9 BOD33 Ready Interrupt Enable */ + uint32_t BOD33DET:1; /*!< bit: 10 BOD33 Detection Interrupt Enable */ + uint32_t B33SRDY:1; /*!< bit: 11 BOD33 Synchronization Ready Interrupt Enable */ + uint32_t :3; /*!< bit: 12..14 Reserved */ + uint32_t DPLLLCKR:1; /*!< bit: 15 DPLL Lock Rise Interrupt Enable */ + uint32_t DPLLLCKF:1; /*!< bit: 16 DPLL Lock Fall Interrupt Enable */ + uint32_t DPLLLTO:1; /*!< bit: 17 DPLL Lock Timeout Interrupt Enable */ + uint32_t :14; /*!< bit: 18..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_INTENSET_OFFSET 0x04 /**< \brief (SYSCTRL_INTENSET offset) Interrupt Enable Set */ +#define SYSCTRL_INTENSET_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_INTENSET reset_value) Interrupt Enable Set */ + +#define SYSCTRL_INTENSET_XOSCRDY_Pos 0 /**< \brief (SYSCTRL_INTENSET) XOSC Ready Interrupt Enable */ +#define SYSCTRL_INTENSET_XOSCRDY (0x1u << SYSCTRL_INTENSET_XOSCRDY_Pos) +#define SYSCTRL_INTENSET_XOSC32KRDY_Pos 1 /**< \brief (SYSCTRL_INTENSET) XOSC32K Ready Interrupt Enable */ +#define SYSCTRL_INTENSET_XOSC32KRDY (0x1u << SYSCTRL_INTENSET_XOSC32KRDY_Pos) +#define SYSCTRL_INTENSET_OSC32KRDY_Pos 2 /**< \brief (SYSCTRL_INTENSET) OSC32K Ready Interrupt Enable */ +#define SYSCTRL_INTENSET_OSC32KRDY (0x1u << SYSCTRL_INTENSET_OSC32KRDY_Pos) +#define SYSCTRL_INTENSET_OSC8MRDY_Pos 3 /**< \brief (SYSCTRL_INTENSET) OSC8M Ready Interrupt Enable */ +#define SYSCTRL_INTENSET_OSC8MRDY (0x1u << SYSCTRL_INTENSET_OSC8MRDY_Pos) +#define SYSCTRL_INTENSET_DFLLRDY_Pos 4 /**< \brief (SYSCTRL_INTENSET) DFLL Ready Interrupt Enable */ +#define SYSCTRL_INTENSET_DFLLRDY (0x1u << SYSCTRL_INTENSET_DFLLRDY_Pos) +#define SYSCTRL_INTENSET_DFLLOOB_Pos 5 /**< \brief (SYSCTRL_INTENSET) DFLL Out Of Bounds Interrupt Enable */ +#define SYSCTRL_INTENSET_DFLLOOB (0x1u << SYSCTRL_INTENSET_DFLLOOB_Pos) +#define SYSCTRL_INTENSET_DFLLLCKF_Pos 6 /**< \brief (SYSCTRL_INTENSET) DFLL Lock Fine Interrupt Enable */ +#define SYSCTRL_INTENSET_DFLLLCKF (0x1u << SYSCTRL_INTENSET_DFLLLCKF_Pos) +#define SYSCTRL_INTENSET_DFLLLCKC_Pos 7 /**< \brief (SYSCTRL_INTENSET) DFLL Lock Coarse Interrupt Enable */ +#define SYSCTRL_INTENSET_DFLLLCKC (0x1u << SYSCTRL_INTENSET_DFLLLCKC_Pos) +#define SYSCTRL_INTENSET_DFLLRCS_Pos 8 /**< \brief (SYSCTRL_INTENSET) DFLL Reference Clock Stopped Interrupt Enable */ +#define SYSCTRL_INTENSET_DFLLRCS (0x1u << SYSCTRL_INTENSET_DFLLRCS_Pos) +#define SYSCTRL_INTENSET_BOD33RDY_Pos 9 /**< \brief (SYSCTRL_INTENSET) BOD33 Ready Interrupt Enable */ +#define SYSCTRL_INTENSET_BOD33RDY (0x1u << SYSCTRL_INTENSET_BOD33RDY_Pos) +#define SYSCTRL_INTENSET_BOD33DET_Pos 10 /**< \brief (SYSCTRL_INTENSET) BOD33 Detection Interrupt Enable */ +#define SYSCTRL_INTENSET_BOD33DET (0x1u << SYSCTRL_INTENSET_BOD33DET_Pos) +#define SYSCTRL_INTENSET_B33SRDY_Pos 11 /**< \brief (SYSCTRL_INTENSET) BOD33 Synchronization Ready Interrupt Enable */ +#define SYSCTRL_INTENSET_B33SRDY (0x1u << SYSCTRL_INTENSET_B33SRDY_Pos) +#define SYSCTRL_INTENSET_DPLLLCKR_Pos 15 /**< \brief (SYSCTRL_INTENSET) DPLL Lock Rise Interrupt Enable */ +#define SYSCTRL_INTENSET_DPLLLCKR (0x1u << SYSCTRL_INTENSET_DPLLLCKR_Pos) +#define SYSCTRL_INTENSET_DPLLLCKF_Pos 16 /**< \brief (SYSCTRL_INTENSET) DPLL Lock Fall Interrupt Enable */ +#define SYSCTRL_INTENSET_DPLLLCKF (0x1u << SYSCTRL_INTENSET_DPLLLCKF_Pos) +#define SYSCTRL_INTENSET_DPLLLTO_Pos 17 /**< \brief (SYSCTRL_INTENSET) DPLL Lock Timeout Interrupt Enable */ +#define SYSCTRL_INTENSET_DPLLLTO (0x1u << SYSCTRL_INTENSET_DPLLLTO_Pos) +#define SYSCTRL_INTENSET_MASK 0x00038FFFu /**< \brief (SYSCTRL_INTENSET) MASK Register */ + +/* -------- SYSCTRL_INTFLAG : (SYSCTRL Offset: 0x08) (R/W 32) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t XOSCRDY:1; /*!< bit: 0 XOSC Ready */ + uint32_t XOSC32KRDY:1; /*!< bit: 1 XOSC32K Ready */ + uint32_t OSC32KRDY:1; /*!< bit: 2 OSC32K Ready */ + uint32_t OSC8MRDY:1; /*!< bit: 3 OSC8M Ready */ + uint32_t DFLLRDY:1; /*!< bit: 4 DFLL Ready */ + uint32_t DFLLOOB:1; /*!< bit: 5 DFLL Out Of Bounds */ + uint32_t DFLLLCKF:1; /*!< bit: 6 DFLL Lock Fine */ + uint32_t DFLLLCKC:1; /*!< bit: 7 DFLL Lock Coarse */ + uint32_t DFLLRCS:1; /*!< bit: 8 DFLL Reference Clock Stopped */ + uint32_t BOD33RDY:1; /*!< bit: 9 BOD33 Ready */ + uint32_t BOD33DET:1; /*!< bit: 10 BOD33 Detection */ + uint32_t B33SRDY:1; /*!< bit: 11 BOD33 Synchronization Ready */ + uint32_t :3; /*!< bit: 12..14 Reserved */ + uint32_t DPLLLCKR:1; /*!< bit: 15 DPLL Lock Rise */ + uint32_t DPLLLCKF:1; /*!< bit: 16 DPLL Lock Fall */ + uint32_t DPLLLTO:1; /*!< bit: 17 DPLL Lock Timeout */ + uint32_t :14; /*!< bit: 18..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_INTFLAG_OFFSET 0x08 /**< \brief (SYSCTRL_INTFLAG offset) Interrupt Flag Status and Clear */ +#define SYSCTRL_INTFLAG_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define SYSCTRL_INTFLAG_XOSCRDY_Pos 0 /**< \brief (SYSCTRL_INTFLAG) XOSC Ready */ +#define SYSCTRL_INTFLAG_XOSCRDY (0x1u << SYSCTRL_INTFLAG_XOSCRDY_Pos) +#define SYSCTRL_INTFLAG_XOSC32KRDY_Pos 1 /**< \brief (SYSCTRL_INTFLAG) XOSC32K Ready */ +#define SYSCTRL_INTFLAG_XOSC32KRDY (0x1u << SYSCTRL_INTFLAG_XOSC32KRDY_Pos) +#define SYSCTRL_INTFLAG_OSC32KRDY_Pos 2 /**< \brief (SYSCTRL_INTFLAG) OSC32K Ready */ +#define SYSCTRL_INTFLAG_OSC32KRDY (0x1u << SYSCTRL_INTFLAG_OSC32KRDY_Pos) +#define SYSCTRL_INTFLAG_OSC8MRDY_Pos 3 /**< \brief (SYSCTRL_INTFLAG) OSC8M Ready */ +#define SYSCTRL_INTFLAG_OSC8MRDY (0x1u << SYSCTRL_INTFLAG_OSC8MRDY_Pos) +#define SYSCTRL_INTFLAG_DFLLRDY_Pos 4 /**< \brief (SYSCTRL_INTFLAG) DFLL Ready */ +#define SYSCTRL_INTFLAG_DFLLRDY (0x1u << SYSCTRL_INTFLAG_DFLLRDY_Pos) +#define SYSCTRL_INTFLAG_DFLLOOB_Pos 5 /**< \brief (SYSCTRL_INTFLAG) DFLL Out Of Bounds */ +#define SYSCTRL_INTFLAG_DFLLOOB (0x1u << SYSCTRL_INTFLAG_DFLLOOB_Pos) +#define SYSCTRL_INTFLAG_DFLLLCKF_Pos 6 /**< \brief (SYSCTRL_INTFLAG) DFLL Lock Fine */ +#define SYSCTRL_INTFLAG_DFLLLCKF (0x1u << SYSCTRL_INTFLAG_DFLLLCKF_Pos) +#define SYSCTRL_INTFLAG_DFLLLCKC_Pos 7 /**< \brief (SYSCTRL_INTFLAG) DFLL Lock Coarse */ +#define SYSCTRL_INTFLAG_DFLLLCKC (0x1u << SYSCTRL_INTFLAG_DFLLLCKC_Pos) +#define SYSCTRL_INTFLAG_DFLLRCS_Pos 8 /**< \brief (SYSCTRL_INTFLAG) DFLL Reference Clock Stopped */ +#define SYSCTRL_INTFLAG_DFLLRCS (0x1u << SYSCTRL_INTFLAG_DFLLRCS_Pos) +#define SYSCTRL_INTFLAG_BOD33RDY_Pos 9 /**< \brief (SYSCTRL_INTFLAG) BOD33 Ready */ +#define SYSCTRL_INTFLAG_BOD33RDY (0x1u << SYSCTRL_INTFLAG_BOD33RDY_Pos) +#define SYSCTRL_INTFLAG_BOD33DET_Pos 10 /**< \brief (SYSCTRL_INTFLAG) BOD33 Detection */ +#define SYSCTRL_INTFLAG_BOD33DET (0x1u << SYSCTRL_INTFLAG_BOD33DET_Pos) +#define SYSCTRL_INTFLAG_B33SRDY_Pos 11 /**< \brief (SYSCTRL_INTFLAG) BOD33 Synchronization Ready */ +#define SYSCTRL_INTFLAG_B33SRDY (0x1u << SYSCTRL_INTFLAG_B33SRDY_Pos) +#define SYSCTRL_INTFLAG_DPLLLCKR_Pos 15 /**< \brief (SYSCTRL_INTFLAG) DPLL Lock Rise */ +#define SYSCTRL_INTFLAG_DPLLLCKR (0x1u << SYSCTRL_INTFLAG_DPLLLCKR_Pos) +#define SYSCTRL_INTFLAG_DPLLLCKF_Pos 16 /**< \brief (SYSCTRL_INTFLAG) DPLL Lock Fall */ +#define SYSCTRL_INTFLAG_DPLLLCKF (0x1u << SYSCTRL_INTFLAG_DPLLLCKF_Pos) +#define SYSCTRL_INTFLAG_DPLLLTO_Pos 17 /**< \brief (SYSCTRL_INTFLAG) DPLL Lock Timeout */ +#define SYSCTRL_INTFLAG_DPLLLTO (0x1u << SYSCTRL_INTFLAG_DPLLLTO_Pos) +#define SYSCTRL_INTFLAG_MASK 0x00038FFFu /**< \brief (SYSCTRL_INTFLAG) MASK Register */ + +/* -------- SYSCTRL_PCLKSR : (SYSCTRL Offset: 0x0C) (R/ 32) Power and Clocks Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t XOSCRDY:1; /*!< bit: 0 XOSC Ready */ + uint32_t XOSC32KRDY:1; /*!< bit: 1 XOSC32K Ready */ + uint32_t OSC32KRDY:1; /*!< bit: 2 OSC32K Ready */ + uint32_t OSC8MRDY:1; /*!< bit: 3 OSC8M Ready */ + uint32_t DFLLRDY:1; /*!< bit: 4 DFLL Ready */ + uint32_t DFLLOOB:1; /*!< bit: 5 DFLL Out Of Bounds */ + uint32_t DFLLLCKF:1; /*!< bit: 6 DFLL Lock Fine */ + uint32_t DFLLLCKC:1; /*!< bit: 7 DFLL Lock Coarse */ + uint32_t DFLLRCS:1; /*!< bit: 8 DFLL Reference Clock Stopped */ + uint32_t BOD33RDY:1; /*!< bit: 9 BOD33 Ready */ + uint32_t BOD33DET:1; /*!< bit: 10 BOD33 Detection */ + uint32_t B33SRDY:1; /*!< bit: 11 BOD33 Synchronization Ready */ + uint32_t :3; /*!< bit: 12..14 Reserved */ + uint32_t DPLLLCKR:1; /*!< bit: 15 DPLL Lock Rise */ + uint32_t DPLLLCKF:1; /*!< bit: 16 DPLL Lock Fall */ + uint32_t DPLLLTO:1; /*!< bit: 17 DPLL Lock Timeout */ + uint32_t :14; /*!< bit: 18..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_PCLKSR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_PCLKSR_OFFSET 0x0C /**< \brief (SYSCTRL_PCLKSR offset) Power and Clocks Status */ +#define SYSCTRL_PCLKSR_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_PCLKSR reset_value) Power and Clocks Status */ + +#define SYSCTRL_PCLKSR_XOSCRDY_Pos 0 /**< \brief (SYSCTRL_PCLKSR) XOSC Ready */ +#define SYSCTRL_PCLKSR_XOSCRDY (0x1u << SYSCTRL_PCLKSR_XOSCRDY_Pos) +#define SYSCTRL_PCLKSR_XOSC32KRDY_Pos 1 /**< \brief (SYSCTRL_PCLKSR) XOSC32K Ready */ +#define SYSCTRL_PCLKSR_XOSC32KRDY (0x1u << SYSCTRL_PCLKSR_XOSC32KRDY_Pos) +#define SYSCTRL_PCLKSR_OSC32KRDY_Pos 2 /**< \brief (SYSCTRL_PCLKSR) OSC32K Ready */ +#define SYSCTRL_PCLKSR_OSC32KRDY (0x1u << SYSCTRL_PCLKSR_OSC32KRDY_Pos) +#define SYSCTRL_PCLKSR_OSC8MRDY_Pos 3 /**< \brief (SYSCTRL_PCLKSR) OSC8M Ready */ +#define SYSCTRL_PCLKSR_OSC8MRDY (0x1u << SYSCTRL_PCLKSR_OSC8MRDY_Pos) +#define SYSCTRL_PCLKSR_DFLLRDY_Pos 4 /**< \brief (SYSCTRL_PCLKSR) DFLL Ready */ +#define SYSCTRL_PCLKSR_DFLLRDY (0x1u << SYSCTRL_PCLKSR_DFLLRDY_Pos) +#define SYSCTRL_PCLKSR_DFLLOOB_Pos 5 /**< \brief (SYSCTRL_PCLKSR) DFLL Out Of Bounds */ +#define SYSCTRL_PCLKSR_DFLLOOB (0x1u << SYSCTRL_PCLKSR_DFLLOOB_Pos) +#define SYSCTRL_PCLKSR_DFLLLCKF_Pos 6 /**< \brief (SYSCTRL_PCLKSR) DFLL Lock Fine */ +#define SYSCTRL_PCLKSR_DFLLLCKF (0x1u << SYSCTRL_PCLKSR_DFLLLCKF_Pos) +#define SYSCTRL_PCLKSR_DFLLLCKC_Pos 7 /**< \brief (SYSCTRL_PCLKSR) DFLL Lock Coarse */ +#define SYSCTRL_PCLKSR_DFLLLCKC (0x1u << SYSCTRL_PCLKSR_DFLLLCKC_Pos) +#define SYSCTRL_PCLKSR_DFLLRCS_Pos 8 /**< \brief (SYSCTRL_PCLKSR) DFLL Reference Clock Stopped */ +#define SYSCTRL_PCLKSR_DFLLRCS (0x1u << SYSCTRL_PCLKSR_DFLLRCS_Pos) +#define SYSCTRL_PCLKSR_BOD33RDY_Pos 9 /**< \brief (SYSCTRL_PCLKSR) BOD33 Ready */ +#define SYSCTRL_PCLKSR_BOD33RDY (0x1u << SYSCTRL_PCLKSR_BOD33RDY_Pos) +#define SYSCTRL_PCLKSR_BOD33DET_Pos 10 /**< \brief (SYSCTRL_PCLKSR) BOD33 Detection */ +#define SYSCTRL_PCLKSR_BOD33DET (0x1u << SYSCTRL_PCLKSR_BOD33DET_Pos) +#define SYSCTRL_PCLKSR_B33SRDY_Pos 11 /**< \brief (SYSCTRL_PCLKSR) BOD33 Synchronization Ready */ +#define SYSCTRL_PCLKSR_B33SRDY (0x1u << SYSCTRL_PCLKSR_B33SRDY_Pos) +#define SYSCTRL_PCLKSR_DPLLLCKR_Pos 15 /**< \brief (SYSCTRL_PCLKSR) DPLL Lock Rise */ +#define SYSCTRL_PCLKSR_DPLLLCKR (0x1u << SYSCTRL_PCLKSR_DPLLLCKR_Pos) +#define SYSCTRL_PCLKSR_DPLLLCKF_Pos 16 /**< \brief (SYSCTRL_PCLKSR) DPLL Lock Fall */ +#define SYSCTRL_PCLKSR_DPLLLCKF (0x1u << SYSCTRL_PCLKSR_DPLLLCKF_Pos) +#define SYSCTRL_PCLKSR_DPLLLTO_Pos 17 /**< \brief (SYSCTRL_PCLKSR) DPLL Lock Timeout */ +#define SYSCTRL_PCLKSR_DPLLLTO (0x1u << SYSCTRL_PCLKSR_DPLLLTO_Pos) +#define SYSCTRL_PCLKSR_MASK 0x00038FFFu /**< \brief (SYSCTRL_PCLKSR) MASK Register */ + +/* -------- SYSCTRL_XOSC : (SYSCTRL Offset: 0x10) (R/W 16) External Multipurpose Crystal Oscillator (XOSC) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t :1; /*!< bit: 0 Reserved */ + uint16_t ENABLE:1; /*!< bit: 1 Oscillator Enable */ + uint16_t XTALEN:1; /*!< bit: 2 Crystal Oscillator Enable */ + uint16_t :3; /*!< bit: 3.. 5 Reserved */ + uint16_t RUNSTDBY:1; /*!< bit: 6 Run in Standby */ + uint16_t ONDEMAND:1; /*!< bit: 7 On Demand Control */ + uint16_t GAIN:3; /*!< bit: 8..10 Oscillator Gain */ + uint16_t AMPGC:1; /*!< bit: 11 Automatic Amplitude Gain Control */ + uint16_t STARTUP:4; /*!< bit: 12..15 Start-Up Time */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} SYSCTRL_XOSC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_XOSC_OFFSET 0x10 /**< \brief (SYSCTRL_XOSC offset) External Multipurpose Crystal Oscillator (XOSC) Control */ +#define SYSCTRL_XOSC_RESETVALUE 0x0080 /**< \brief (SYSCTRL_XOSC reset_value) External Multipurpose Crystal Oscillator (XOSC) Control */ + +#define SYSCTRL_XOSC_ENABLE_Pos 1 /**< \brief (SYSCTRL_XOSC) Oscillator Enable */ +#define SYSCTRL_XOSC_ENABLE (0x1u << SYSCTRL_XOSC_ENABLE_Pos) +#define SYSCTRL_XOSC_XTALEN_Pos 2 /**< \brief (SYSCTRL_XOSC) Crystal Oscillator Enable */ +#define SYSCTRL_XOSC_XTALEN (0x1u << SYSCTRL_XOSC_XTALEN_Pos) +#define SYSCTRL_XOSC_RUNSTDBY_Pos 6 /**< \brief (SYSCTRL_XOSC) Run in Standby */ +#define SYSCTRL_XOSC_RUNSTDBY (0x1u << SYSCTRL_XOSC_RUNSTDBY_Pos) +#define SYSCTRL_XOSC_ONDEMAND_Pos 7 /**< \brief (SYSCTRL_XOSC) On Demand Control */ +#define SYSCTRL_XOSC_ONDEMAND (0x1u << SYSCTRL_XOSC_ONDEMAND_Pos) +#define SYSCTRL_XOSC_GAIN_Pos 8 /**< \brief (SYSCTRL_XOSC) Oscillator Gain */ +#define SYSCTRL_XOSC_GAIN_Msk (0x7u << SYSCTRL_XOSC_GAIN_Pos) +#define SYSCTRL_XOSC_GAIN(value) ((SYSCTRL_XOSC_GAIN_Msk & ((value) << SYSCTRL_XOSC_GAIN_Pos))) +#define SYSCTRL_XOSC_GAIN_0_Val 0x0u /**< \brief (SYSCTRL_XOSC) 2MHz */ +#define SYSCTRL_XOSC_GAIN_1_Val 0x1u /**< \brief (SYSCTRL_XOSC) 4MHz */ +#define SYSCTRL_XOSC_GAIN_2_Val 0x2u /**< \brief (SYSCTRL_XOSC) 8MHz */ +#define SYSCTRL_XOSC_GAIN_3_Val 0x3u /**< \brief (SYSCTRL_XOSC) 16MHz */ +#define SYSCTRL_XOSC_GAIN_4_Val 0x4u /**< \brief (SYSCTRL_XOSC) 30MHz */ +#define SYSCTRL_XOSC_GAIN_0 (SYSCTRL_XOSC_GAIN_0_Val << SYSCTRL_XOSC_GAIN_Pos) +#define SYSCTRL_XOSC_GAIN_1 (SYSCTRL_XOSC_GAIN_1_Val << SYSCTRL_XOSC_GAIN_Pos) +#define SYSCTRL_XOSC_GAIN_2 (SYSCTRL_XOSC_GAIN_2_Val << SYSCTRL_XOSC_GAIN_Pos) +#define SYSCTRL_XOSC_GAIN_3 (SYSCTRL_XOSC_GAIN_3_Val << SYSCTRL_XOSC_GAIN_Pos) +#define SYSCTRL_XOSC_GAIN_4 (SYSCTRL_XOSC_GAIN_4_Val << SYSCTRL_XOSC_GAIN_Pos) +#define SYSCTRL_XOSC_AMPGC_Pos 11 /**< \brief (SYSCTRL_XOSC) Automatic Amplitude Gain Control */ +#define SYSCTRL_XOSC_AMPGC (0x1u << SYSCTRL_XOSC_AMPGC_Pos) +#define SYSCTRL_XOSC_STARTUP_Pos 12 /**< \brief (SYSCTRL_XOSC) Start-Up Time */ +#define SYSCTRL_XOSC_STARTUP_Msk (0xFu << SYSCTRL_XOSC_STARTUP_Pos) +#define SYSCTRL_XOSC_STARTUP(value) ((SYSCTRL_XOSC_STARTUP_Msk & ((value) << SYSCTRL_XOSC_STARTUP_Pos))) +#define SYSCTRL_XOSC_MASK 0xFFC6u /**< \brief (SYSCTRL_XOSC) MASK Register */ + +/* -------- SYSCTRL_XOSC32K : (SYSCTRL Offset: 0x14) (R/W 16) 32kHz External Crystal Oscillator (XOSC32K) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t :1; /*!< bit: 0 Reserved */ + uint16_t ENABLE:1; /*!< bit: 1 Oscillator Enable */ + uint16_t XTALEN:1; /*!< bit: 2 Crystal Oscillator Enable */ + uint16_t EN32K:1; /*!< bit: 3 32kHz Output Enable */ + uint16_t EN1K:1; /*!< bit: 4 1kHz Output Enable */ + uint16_t AAMPEN:1; /*!< bit: 5 Automatic Amplitude Control Enable */ + uint16_t RUNSTDBY:1; /*!< bit: 6 Run in Standby */ + uint16_t ONDEMAND:1; /*!< bit: 7 On Demand Control */ + uint16_t STARTUP:3; /*!< bit: 8..10 Oscillator Start-Up Time */ + uint16_t :1; /*!< bit: 11 Reserved */ + uint16_t WRTLOCK:1; /*!< bit: 12 Write Lock */ + uint16_t :3; /*!< bit: 13..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} SYSCTRL_XOSC32K_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_XOSC32K_OFFSET 0x14 /**< \brief (SYSCTRL_XOSC32K offset) 32kHz External Crystal Oscillator (XOSC32K) Control */ +#define SYSCTRL_XOSC32K_RESETVALUE 0x0080 /**< \brief (SYSCTRL_XOSC32K reset_value) 32kHz External Crystal Oscillator (XOSC32K) Control */ + +#define SYSCTRL_XOSC32K_ENABLE_Pos 1 /**< \brief (SYSCTRL_XOSC32K) Oscillator Enable */ +#define SYSCTRL_XOSC32K_ENABLE (0x1u << SYSCTRL_XOSC32K_ENABLE_Pos) +#define SYSCTRL_XOSC32K_XTALEN_Pos 2 /**< \brief (SYSCTRL_XOSC32K) Crystal Oscillator Enable */ +#define SYSCTRL_XOSC32K_XTALEN (0x1u << SYSCTRL_XOSC32K_XTALEN_Pos) +#define SYSCTRL_XOSC32K_EN32K_Pos 3 /**< \brief (SYSCTRL_XOSC32K) 32kHz Output Enable */ +#define SYSCTRL_XOSC32K_EN32K (0x1u << SYSCTRL_XOSC32K_EN32K_Pos) +#define SYSCTRL_XOSC32K_EN1K_Pos 4 /**< \brief (SYSCTRL_XOSC32K) 1kHz Output Enable */ +#define SYSCTRL_XOSC32K_EN1K (0x1u << SYSCTRL_XOSC32K_EN1K_Pos) +#define SYSCTRL_XOSC32K_AAMPEN_Pos 5 /**< \brief (SYSCTRL_XOSC32K) Automatic Amplitude Control Enable */ +#define SYSCTRL_XOSC32K_AAMPEN (0x1u << SYSCTRL_XOSC32K_AAMPEN_Pos) +#define SYSCTRL_XOSC32K_RUNSTDBY_Pos 6 /**< \brief (SYSCTRL_XOSC32K) Run in Standby */ +#define SYSCTRL_XOSC32K_RUNSTDBY (0x1u << SYSCTRL_XOSC32K_RUNSTDBY_Pos) +#define SYSCTRL_XOSC32K_ONDEMAND_Pos 7 /**< \brief (SYSCTRL_XOSC32K) On Demand Control */ +#define SYSCTRL_XOSC32K_ONDEMAND (0x1u << SYSCTRL_XOSC32K_ONDEMAND_Pos) +#define SYSCTRL_XOSC32K_STARTUP_Pos 8 /**< \brief (SYSCTRL_XOSC32K) Oscillator Start-Up Time */ +#define SYSCTRL_XOSC32K_STARTUP_Msk (0x7u << SYSCTRL_XOSC32K_STARTUP_Pos) +#define SYSCTRL_XOSC32K_STARTUP(value) ((SYSCTRL_XOSC32K_STARTUP_Msk & ((value) << SYSCTRL_XOSC32K_STARTUP_Pos))) +#define SYSCTRL_XOSC32K_WRTLOCK_Pos 12 /**< \brief (SYSCTRL_XOSC32K) Write Lock */ +#define SYSCTRL_XOSC32K_WRTLOCK (0x1u << SYSCTRL_XOSC32K_WRTLOCK_Pos) +#define SYSCTRL_XOSC32K_MASK 0x17FEu /**< \brief (SYSCTRL_XOSC32K) MASK Register */ + +/* -------- SYSCTRL_OSC32K : (SYSCTRL Offset: 0x18) (R/W 32) 32kHz Internal Oscillator (OSC32K) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :1; /*!< bit: 0 Reserved */ + uint32_t ENABLE:1; /*!< bit: 1 Oscillator Enable */ + uint32_t EN32K:1; /*!< bit: 2 32kHz Output Enable */ + uint32_t EN1K:1; /*!< bit: 3 1kHz Output Enable */ + uint32_t :2; /*!< bit: 4.. 5 Reserved */ + uint32_t RUNSTDBY:1; /*!< bit: 6 Run in Standby */ + uint32_t ONDEMAND:1; /*!< bit: 7 On Demand Control */ + uint32_t STARTUP:3; /*!< bit: 8..10 Oscillator Start-Up Time */ + uint32_t :1; /*!< bit: 11 Reserved */ + uint32_t WRTLOCK:1; /*!< bit: 12 Write Lock */ + uint32_t :3; /*!< bit: 13..15 Reserved */ + uint32_t CALIB:7; /*!< bit: 16..22 Oscillator Calibration */ + uint32_t :9; /*!< bit: 23..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_OSC32K_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_OSC32K_OFFSET 0x18 /**< \brief (SYSCTRL_OSC32K offset) 32kHz Internal Oscillator (OSC32K) Control */ +#define SYSCTRL_OSC32K_RESETVALUE 0x003F0080 /**< \brief (SYSCTRL_OSC32K reset_value) 32kHz Internal Oscillator (OSC32K) Control */ + +#define SYSCTRL_OSC32K_ENABLE_Pos 1 /**< \brief (SYSCTRL_OSC32K) Oscillator Enable */ +#define SYSCTRL_OSC32K_ENABLE (0x1u << SYSCTRL_OSC32K_ENABLE_Pos) +#define SYSCTRL_OSC32K_EN32K_Pos 2 /**< \brief (SYSCTRL_OSC32K) 32kHz Output Enable */ +#define SYSCTRL_OSC32K_EN32K (0x1u << SYSCTRL_OSC32K_EN32K_Pos) +#define SYSCTRL_OSC32K_EN1K_Pos 3 /**< \brief (SYSCTRL_OSC32K) 1kHz Output Enable */ +#define SYSCTRL_OSC32K_EN1K (0x1u << SYSCTRL_OSC32K_EN1K_Pos) +#define SYSCTRL_OSC32K_RUNSTDBY_Pos 6 /**< \brief (SYSCTRL_OSC32K) Run in Standby */ +#define SYSCTRL_OSC32K_RUNSTDBY (0x1u << SYSCTRL_OSC32K_RUNSTDBY_Pos) +#define SYSCTRL_OSC32K_ONDEMAND_Pos 7 /**< \brief (SYSCTRL_OSC32K) On Demand Control */ +#define SYSCTRL_OSC32K_ONDEMAND (0x1u << SYSCTRL_OSC32K_ONDEMAND_Pos) +#define SYSCTRL_OSC32K_STARTUP_Pos 8 /**< \brief (SYSCTRL_OSC32K) Oscillator Start-Up Time */ +#define SYSCTRL_OSC32K_STARTUP_Msk (0x7u << SYSCTRL_OSC32K_STARTUP_Pos) +#define SYSCTRL_OSC32K_STARTUP(value) ((SYSCTRL_OSC32K_STARTUP_Msk & ((value) << SYSCTRL_OSC32K_STARTUP_Pos))) +#define SYSCTRL_OSC32K_WRTLOCK_Pos 12 /**< \brief (SYSCTRL_OSC32K) Write Lock */ +#define SYSCTRL_OSC32K_WRTLOCK (0x1u << SYSCTRL_OSC32K_WRTLOCK_Pos) +#define SYSCTRL_OSC32K_CALIB_Pos 16 /**< \brief (SYSCTRL_OSC32K) Oscillator Calibration */ +#define SYSCTRL_OSC32K_CALIB_Msk (0x7Fu << SYSCTRL_OSC32K_CALIB_Pos) +#define SYSCTRL_OSC32K_CALIB(value) ((SYSCTRL_OSC32K_CALIB_Msk & ((value) << SYSCTRL_OSC32K_CALIB_Pos))) +#define SYSCTRL_OSC32K_MASK 0x007F17CEu /**< \brief (SYSCTRL_OSC32K) MASK Register */ + +/* -------- SYSCTRL_OSCULP32K : (SYSCTRL Offset: 0x1C) (R/W 8) 32kHz Ultra Low Power Internal Oscillator (OSCULP32K) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CALIB:5; /*!< bit: 0.. 4 Oscillator Calibration */ + uint8_t :2; /*!< bit: 5.. 6 Reserved */ + uint8_t WRTLOCK:1; /*!< bit: 7 Write Lock */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SYSCTRL_OSCULP32K_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_OSCULP32K_OFFSET 0x1C /**< \brief (SYSCTRL_OSCULP32K offset) 32kHz Ultra Low Power Internal Oscillator (OSCULP32K) Control */ +#define SYSCTRL_OSCULP32K_RESETVALUE 0x1F /**< \brief (SYSCTRL_OSCULP32K reset_value) 32kHz Ultra Low Power Internal Oscillator (OSCULP32K) Control */ + +#define SYSCTRL_OSCULP32K_CALIB_Pos 0 /**< \brief (SYSCTRL_OSCULP32K) Oscillator Calibration */ +#define SYSCTRL_OSCULP32K_CALIB_Msk (0x1Fu << SYSCTRL_OSCULP32K_CALIB_Pos) +#define SYSCTRL_OSCULP32K_CALIB(value) ((SYSCTRL_OSCULP32K_CALIB_Msk & ((value) << SYSCTRL_OSCULP32K_CALIB_Pos))) +#define SYSCTRL_OSCULP32K_WRTLOCK_Pos 7 /**< \brief (SYSCTRL_OSCULP32K) Write Lock */ +#define SYSCTRL_OSCULP32K_WRTLOCK (0x1u << SYSCTRL_OSCULP32K_WRTLOCK_Pos) +#define SYSCTRL_OSCULP32K_MASK 0x9Fu /**< \brief (SYSCTRL_OSCULP32K) MASK Register */ + +/* -------- SYSCTRL_OSC8M : (SYSCTRL Offset: 0x20) (R/W 32) 8MHz Internal Oscillator (OSC8M) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :1; /*!< bit: 0 Reserved */ + uint32_t ENABLE:1; /*!< bit: 1 Oscillator Enable */ + uint32_t :4; /*!< bit: 2.. 5 Reserved */ + uint32_t RUNSTDBY:1; /*!< bit: 6 Run in Standby */ + uint32_t ONDEMAND:1; /*!< bit: 7 On Demand Control */ + uint32_t PRESC:2; /*!< bit: 8.. 9 Oscillator Prescaler */ + uint32_t :6; /*!< bit: 10..15 Reserved */ + uint32_t CALIB:12; /*!< bit: 16..27 Oscillator Calibration */ + uint32_t :2; /*!< bit: 28..29 Reserved */ + uint32_t FRANGE:2; /*!< bit: 30..31 Oscillator Frequency Range */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_OSC8M_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_OSC8M_OFFSET 0x20 /**< \brief (SYSCTRL_OSC8M offset) 8MHz Internal Oscillator (OSC8M) Control */ +#define SYSCTRL_OSC8M_RESETVALUE 0x87070382 /**< \brief (SYSCTRL_OSC8M reset_value) 8MHz Internal Oscillator (OSC8M) Control */ + +#define SYSCTRL_OSC8M_ENABLE_Pos 1 /**< \brief (SYSCTRL_OSC8M) Oscillator Enable */ +#define SYSCTRL_OSC8M_ENABLE (0x1u << SYSCTRL_OSC8M_ENABLE_Pos) +#define SYSCTRL_OSC8M_RUNSTDBY_Pos 6 /**< \brief (SYSCTRL_OSC8M) Run in Standby */ +#define SYSCTRL_OSC8M_RUNSTDBY (0x1u << SYSCTRL_OSC8M_RUNSTDBY_Pos) +#define SYSCTRL_OSC8M_ONDEMAND_Pos 7 /**< \brief (SYSCTRL_OSC8M) On Demand Control */ +#define SYSCTRL_OSC8M_ONDEMAND (0x1u << SYSCTRL_OSC8M_ONDEMAND_Pos) +#define SYSCTRL_OSC8M_PRESC_Pos 8 /**< \brief (SYSCTRL_OSC8M) Oscillator Prescaler */ +#define SYSCTRL_OSC8M_PRESC_Msk (0x3u << SYSCTRL_OSC8M_PRESC_Pos) +#define SYSCTRL_OSC8M_PRESC(value) ((SYSCTRL_OSC8M_PRESC_Msk & ((value) << SYSCTRL_OSC8M_PRESC_Pos))) +#define SYSCTRL_OSC8M_PRESC_0_Val 0x0u /**< \brief (SYSCTRL_OSC8M) 1 */ +#define SYSCTRL_OSC8M_PRESC_1_Val 0x1u /**< \brief (SYSCTRL_OSC8M) 2 */ +#define SYSCTRL_OSC8M_PRESC_2_Val 0x2u /**< \brief (SYSCTRL_OSC8M) 4 */ +#define SYSCTRL_OSC8M_PRESC_3_Val 0x3u /**< \brief (SYSCTRL_OSC8M) 8 */ +#define SYSCTRL_OSC8M_PRESC_0 (SYSCTRL_OSC8M_PRESC_0_Val << SYSCTRL_OSC8M_PRESC_Pos) +#define SYSCTRL_OSC8M_PRESC_1 (SYSCTRL_OSC8M_PRESC_1_Val << SYSCTRL_OSC8M_PRESC_Pos) +#define SYSCTRL_OSC8M_PRESC_2 (SYSCTRL_OSC8M_PRESC_2_Val << SYSCTRL_OSC8M_PRESC_Pos) +#define SYSCTRL_OSC8M_PRESC_3 (SYSCTRL_OSC8M_PRESC_3_Val << SYSCTRL_OSC8M_PRESC_Pos) +#define SYSCTRL_OSC8M_CALIB_Pos 16 /**< \brief (SYSCTRL_OSC8M) Oscillator Calibration */ +#define SYSCTRL_OSC8M_CALIB_Msk (0xFFFu << SYSCTRL_OSC8M_CALIB_Pos) +#define SYSCTRL_OSC8M_CALIB(value) ((SYSCTRL_OSC8M_CALIB_Msk & ((value) << SYSCTRL_OSC8M_CALIB_Pos))) +#define SYSCTRL_OSC8M_FRANGE_Pos 30 /**< \brief (SYSCTRL_OSC8M) Oscillator Frequency Range */ +#define SYSCTRL_OSC8M_FRANGE_Msk (0x3u << SYSCTRL_OSC8M_FRANGE_Pos) +#define SYSCTRL_OSC8M_FRANGE(value) ((SYSCTRL_OSC8M_FRANGE_Msk & ((value) << SYSCTRL_OSC8M_FRANGE_Pos))) +#define SYSCTRL_OSC8M_FRANGE_0_Val 0x0u /**< \brief (SYSCTRL_OSC8M) 4 to 6MHz */ +#define SYSCTRL_OSC8M_FRANGE_1_Val 0x1u /**< \brief (SYSCTRL_OSC8M) 6 to 8MHz */ +#define SYSCTRL_OSC8M_FRANGE_2_Val 0x2u /**< \brief (SYSCTRL_OSC8M) 8 to 11MHz */ +#define SYSCTRL_OSC8M_FRANGE_3_Val 0x3u /**< \brief (SYSCTRL_OSC8M) 11 to 15MHz */ +#define SYSCTRL_OSC8M_FRANGE_0 (SYSCTRL_OSC8M_FRANGE_0_Val << SYSCTRL_OSC8M_FRANGE_Pos) +#define SYSCTRL_OSC8M_FRANGE_1 (SYSCTRL_OSC8M_FRANGE_1_Val << SYSCTRL_OSC8M_FRANGE_Pos) +#define SYSCTRL_OSC8M_FRANGE_2 (SYSCTRL_OSC8M_FRANGE_2_Val << SYSCTRL_OSC8M_FRANGE_Pos) +#define SYSCTRL_OSC8M_FRANGE_3 (SYSCTRL_OSC8M_FRANGE_3_Val << SYSCTRL_OSC8M_FRANGE_Pos) +#define SYSCTRL_OSC8M_MASK 0xCFFF03C2u /**< \brief (SYSCTRL_OSC8M) MASK Register */ + +/* -------- SYSCTRL_DFLLCTRL : (SYSCTRL Offset: 0x24) (R/W 16) DFLL48M Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t :1; /*!< bit: 0 Reserved */ + uint16_t ENABLE:1; /*!< bit: 1 DFLL Enable */ + uint16_t MODE:1; /*!< bit: 2 Operating Mode Selection */ + uint16_t STABLE:1; /*!< bit: 3 Stable DFLL Frequency */ + uint16_t LLAW:1; /*!< bit: 4 Lose Lock After Wake */ + uint16_t USBCRM:1; /*!< bit: 5 USB Clock Recovery Mode */ + uint16_t RUNSTDBY:1; /*!< bit: 6 Run in Standby */ + uint16_t ONDEMAND:1; /*!< bit: 7 On Demand Control */ + uint16_t CCDIS:1; /*!< bit: 8 Chill Cycle Disable */ + uint16_t QLDIS:1; /*!< bit: 9 Quick Lock Disable */ + uint16_t BPLCKC:1; /*!< bit: 10 Bypass Coarse Lock */ + uint16_t WAITLOCK:1; /*!< bit: 11 Wait Lock */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} SYSCTRL_DFLLCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_DFLLCTRL_OFFSET 0x24 /**< \brief (SYSCTRL_DFLLCTRL offset) DFLL48M Control */ +#define SYSCTRL_DFLLCTRL_RESETVALUE 0x0080 /**< \brief (SYSCTRL_DFLLCTRL reset_value) DFLL48M Control */ + +#define SYSCTRL_DFLLCTRL_ENABLE_Pos 1 /**< \brief (SYSCTRL_DFLLCTRL) DFLL Enable */ +#define SYSCTRL_DFLLCTRL_ENABLE (0x1u << SYSCTRL_DFLLCTRL_ENABLE_Pos) +#define SYSCTRL_DFLLCTRL_MODE_Pos 2 /**< \brief (SYSCTRL_DFLLCTRL) Operating Mode Selection */ +#define SYSCTRL_DFLLCTRL_MODE (0x1u << SYSCTRL_DFLLCTRL_MODE_Pos) +#define SYSCTRL_DFLLCTRL_STABLE_Pos 3 /**< \brief (SYSCTRL_DFLLCTRL) Stable DFLL Frequency */ +#define SYSCTRL_DFLLCTRL_STABLE (0x1u << SYSCTRL_DFLLCTRL_STABLE_Pos) +#define SYSCTRL_DFLLCTRL_LLAW_Pos 4 /**< \brief (SYSCTRL_DFLLCTRL) Lose Lock After Wake */ +#define SYSCTRL_DFLLCTRL_LLAW (0x1u << SYSCTRL_DFLLCTRL_LLAW_Pos) +#define SYSCTRL_DFLLCTRL_USBCRM_Pos 5 /**< \brief (SYSCTRL_DFLLCTRL) USB Clock Recovery Mode */ +#define SYSCTRL_DFLLCTRL_USBCRM (0x1u << SYSCTRL_DFLLCTRL_USBCRM_Pos) +#define SYSCTRL_DFLLCTRL_RUNSTDBY_Pos 6 /**< \brief (SYSCTRL_DFLLCTRL) Run in Standby */ +#define SYSCTRL_DFLLCTRL_RUNSTDBY (0x1u << SYSCTRL_DFLLCTRL_RUNSTDBY_Pos) +#define SYSCTRL_DFLLCTRL_ONDEMAND_Pos 7 /**< \brief (SYSCTRL_DFLLCTRL) On Demand Control */ +#define SYSCTRL_DFLLCTRL_ONDEMAND (0x1u << SYSCTRL_DFLLCTRL_ONDEMAND_Pos) +#define SYSCTRL_DFLLCTRL_CCDIS_Pos 8 /**< \brief (SYSCTRL_DFLLCTRL) Chill Cycle Disable */ +#define SYSCTRL_DFLLCTRL_CCDIS (0x1u << SYSCTRL_DFLLCTRL_CCDIS_Pos) +#define SYSCTRL_DFLLCTRL_QLDIS_Pos 9 /**< \brief (SYSCTRL_DFLLCTRL) Quick Lock Disable */ +#define SYSCTRL_DFLLCTRL_QLDIS (0x1u << SYSCTRL_DFLLCTRL_QLDIS_Pos) +#define SYSCTRL_DFLLCTRL_BPLCKC_Pos 10 /**< \brief (SYSCTRL_DFLLCTRL) Bypass Coarse Lock */ +#define SYSCTRL_DFLLCTRL_BPLCKC (0x1u << SYSCTRL_DFLLCTRL_BPLCKC_Pos) +#define SYSCTRL_DFLLCTRL_WAITLOCK_Pos 11 /**< \brief (SYSCTRL_DFLLCTRL) Wait Lock */ +#define SYSCTRL_DFLLCTRL_WAITLOCK (0x1u << SYSCTRL_DFLLCTRL_WAITLOCK_Pos) +#define SYSCTRL_DFLLCTRL_MASK 0x0FFEu /**< \brief (SYSCTRL_DFLLCTRL) MASK Register */ + +/* -------- SYSCTRL_DFLLVAL : (SYSCTRL Offset: 0x28) (R/W 32) DFLL48M Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t FINE:10; /*!< bit: 0.. 9 Fine Value */ + uint32_t COARSE:6; /*!< bit: 10..15 Coarse Value */ + uint32_t DIFF:16; /*!< bit: 16..31 Multiplication Ratio Difference */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_DFLLVAL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_DFLLVAL_OFFSET 0x28 /**< \brief (SYSCTRL_DFLLVAL offset) DFLL48M Value */ +#define SYSCTRL_DFLLVAL_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_DFLLVAL reset_value) DFLL48M Value */ + +#define SYSCTRL_DFLLVAL_FINE_Pos 0 /**< \brief (SYSCTRL_DFLLVAL) Fine Value */ +#define SYSCTRL_DFLLVAL_FINE_Msk (0x3FFu << SYSCTRL_DFLLVAL_FINE_Pos) +#define SYSCTRL_DFLLVAL_FINE(value) ((SYSCTRL_DFLLVAL_FINE_Msk & ((value) << SYSCTRL_DFLLVAL_FINE_Pos))) +#define SYSCTRL_DFLLVAL_COARSE_Pos 10 /**< \brief (SYSCTRL_DFLLVAL) Coarse Value */ +#define SYSCTRL_DFLLVAL_COARSE_Msk (0x3Fu << SYSCTRL_DFLLVAL_COARSE_Pos) +#define SYSCTRL_DFLLVAL_COARSE(value) ((SYSCTRL_DFLLVAL_COARSE_Msk & ((value) << SYSCTRL_DFLLVAL_COARSE_Pos))) +#define SYSCTRL_DFLLVAL_DIFF_Pos 16 /**< \brief (SYSCTRL_DFLLVAL) Multiplication Ratio Difference */ +#define SYSCTRL_DFLLVAL_DIFF_Msk (0xFFFFu << SYSCTRL_DFLLVAL_DIFF_Pos) +#define SYSCTRL_DFLLVAL_DIFF(value) ((SYSCTRL_DFLLVAL_DIFF_Msk & ((value) << SYSCTRL_DFLLVAL_DIFF_Pos))) +#define SYSCTRL_DFLLVAL_MASK 0xFFFFFFFFu /**< \brief (SYSCTRL_DFLLVAL) MASK Register */ + +/* -------- SYSCTRL_DFLLMUL : (SYSCTRL Offset: 0x2C) (R/W 32) DFLL48M Multiplier -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t MUL:16; /*!< bit: 0..15 DFLL Multiply Factor */ + uint32_t FSTEP:10; /*!< bit: 16..25 Fine Maximum Step */ + uint32_t CSTEP:6; /*!< bit: 26..31 Coarse Maximum Step */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_DFLLMUL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_DFLLMUL_OFFSET 0x2C /**< \brief (SYSCTRL_DFLLMUL offset) DFLL48M Multiplier */ +#define SYSCTRL_DFLLMUL_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_DFLLMUL reset_value) DFLL48M Multiplier */ + +#define SYSCTRL_DFLLMUL_MUL_Pos 0 /**< \brief (SYSCTRL_DFLLMUL) DFLL Multiply Factor */ +#define SYSCTRL_DFLLMUL_MUL_Msk (0xFFFFu << SYSCTRL_DFLLMUL_MUL_Pos) +#define SYSCTRL_DFLLMUL_MUL(value) ((SYSCTRL_DFLLMUL_MUL_Msk & ((value) << SYSCTRL_DFLLMUL_MUL_Pos))) +#define SYSCTRL_DFLLMUL_FSTEP_Pos 16 /**< \brief (SYSCTRL_DFLLMUL) Fine Maximum Step */ +#define SYSCTRL_DFLLMUL_FSTEP_Msk (0x3FFu << SYSCTRL_DFLLMUL_FSTEP_Pos) +#define SYSCTRL_DFLLMUL_FSTEP(value) ((SYSCTRL_DFLLMUL_FSTEP_Msk & ((value) << SYSCTRL_DFLLMUL_FSTEP_Pos))) +#define SYSCTRL_DFLLMUL_CSTEP_Pos 26 /**< \brief (SYSCTRL_DFLLMUL) Coarse Maximum Step */ +#define SYSCTRL_DFLLMUL_CSTEP_Msk (0x3Fu << SYSCTRL_DFLLMUL_CSTEP_Pos) +#define SYSCTRL_DFLLMUL_CSTEP(value) ((SYSCTRL_DFLLMUL_CSTEP_Msk & ((value) << SYSCTRL_DFLLMUL_CSTEP_Pos))) +#define SYSCTRL_DFLLMUL_MASK 0xFFFFFFFFu /**< \brief (SYSCTRL_DFLLMUL) MASK Register */ + +/* -------- SYSCTRL_DFLLSYNC : (SYSCTRL Offset: 0x30) (R/W 8) DFLL48M Synchronization -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :7; /*!< bit: 0.. 6 Reserved */ + uint8_t READREQ:1; /*!< bit: 7 Read Request */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SYSCTRL_DFLLSYNC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_DFLLSYNC_OFFSET 0x30 /**< \brief (SYSCTRL_DFLLSYNC offset) DFLL48M Synchronization */ +#define SYSCTRL_DFLLSYNC_RESETVALUE 0x00 /**< \brief (SYSCTRL_DFLLSYNC reset_value) DFLL48M Synchronization */ + +#define SYSCTRL_DFLLSYNC_READREQ_Pos 7 /**< \brief (SYSCTRL_DFLLSYNC) Read Request */ +#define SYSCTRL_DFLLSYNC_READREQ (0x1u << SYSCTRL_DFLLSYNC_READREQ_Pos) +#define SYSCTRL_DFLLSYNC_MASK 0x80u /**< \brief (SYSCTRL_DFLLSYNC) MASK Register */ + +/* -------- SYSCTRL_BOD33 : (SYSCTRL Offset: 0x34) (R/W 32) 3.3V Brown-Out Detector (BOD33) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :1; /*!< bit: 0 Reserved */ + uint32_t ENABLE:1; /*!< bit: 1 Enable */ + uint32_t HYST:1; /*!< bit: 2 Hysteresis */ + uint32_t ACTION:2; /*!< bit: 3.. 4 BOD33 Action */ + uint32_t :1; /*!< bit: 5 Reserved */ + uint32_t RUNSTDBY:1; /*!< bit: 6 Run in Standby */ + uint32_t :1; /*!< bit: 7 Reserved */ + uint32_t MODE:1; /*!< bit: 8 Operation Mode */ + uint32_t CEN:1; /*!< bit: 9 Clock Enable */ + uint32_t :2; /*!< bit: 10..11 Reserved */ + uint32_t PSEL:4; /*!< bit: 12..15 Prescaler Select */ + uint32_t LEVEL:6; /*!< bit: 16..21 BOD33 Threshold Level */ + uint32_t :10; /*!< bit: 22..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_BOD33_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_BOD33_OFFSET 0x34 /**< \brief (SYSCTRL_BOD33 offset) 3.3V Brown-Out Detector (BOD33) Control */ +#define SYSCTRL_BOD33_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_BOD33 reset_value) 3.3V Brown-Out Detector (BOD33) Control */ + +#define SYSCTRL_BOD33_ENABLE_Pos 1 /**< \brief (SYSCTRL_BOD33) Enable */ +#define SYSCTRL_BOD33_ENABLE (0x1u << SYSCTRL_BOD33_ENABLE_Pos) +#define SYSCTRL_BOD33_HYST_Pos 2 /**< \brief (SYSCTRL_BOD33) Hysteresis */ +#define SYSCTRL_BOD33_HYST (0x1u << SYSCTRL_BOD33_HYST_Pos) +#define SYSCTRL_BOD33_ACTION_Pos 3 /**< \brief (SYSCTRL_BOD33) BOD33 Action */ +#define SYSCTRL_BOD33_ACTION_Msk (0x3u << SYSCTRL_BOD33_ACTION_Pos) +#define SYSCTRL_BOD33_ACTION(value) ((SYSCTRL_BOD33_ACTION_Msk & ((value) << SYSCTRL_BOD33_ACTION_Pos))) +#define SYSCTRL_BOD33_ACTION_NONE_Val 0x0u /**< \brief (SYSCTRL_BOD33) No action */ +#define SYSCTRL_BOD33_ACTION_RESET_Val 0x1u /**< \brief (SYSCTRL_BOD33) The BOD33 generates a reset */ +#define SYSCTRL_BOD33_ACTION_INTERRUPT_Val 0x2u /**< \brief (SYSCTRL_BOD33) The BOD33 generates an interrupt */ +#define SYSCTRL_BOD33_ACTION_NONE (SYSCTRL_BOD33_ACTION_NONE_Val << SYSCTRL_BOD33_ACTION_Pos) +#define SYSCTRL_BOD33_ACTION_RESET (SYSCTRL_BOD33_ACTION_RESET_Val << SYSCTRL_BOD33_ACTION_Pos) +#define SYSCTRL_BOD33_ACTION_INTERRUPT (SYSCTRL_BOD33_ACTION_INTERRUPT_Val << SYSCTRL_BOD33_ACTION_Pos) +#define SYSCTRL_BOD33_RUNSTDBY_Pos 6 /**< \brief (SYSCTRL_BOD33) Run in Standby */ +#define SYSCTRL_BOD33_RUNSTDBY (0x1u << SYSCTRL_BOD33_RUNSTDBY_Pos) +#define SYSCTRL_BOD33_MODE_Pos 8 /**< \brief (SYSCTRL_BOD33) Operation Mode */ +#define SYSCTRL_BOD33_MODE (0x1u << SYSCTRL_BOD33_MODE_Pos) +#define SYSCTRL_BOD33_CEN_Pos 9 /**< \brief (SYSCTRL_BOD33) Clock Enable */ +#define SYSCTRL_BOD33_CEN (0x1u << SYSCTRL_BOD33_CEN_Pos) +#define SYSCTRL_BOD33_PSEL_Pos 12 /**< \brief (SYSCTRL_BOD33) Prescaler Select */ +#define SYSCTRL_BOD33_PSEL_Msk (0xFu << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL(value) ((SYSCTRL_BOD33_PSEL_Msk & ((value) << SYSCTRL_BOD33_PSEL_Pos))) +#define SYSCTRL_BOD33_PSEL_DIV2_Val 0x0u /**< \brief (SYSCTRL_BOD33) Divide clock by 2 */ +#define SYSCTRL_BOD33_PSEL_DIV4_Val 0x1u /**< \brief (SYSCTRL_BOD33) Divide clock by 4 */ +#define SYSCTRL_BOD33_PSEL_DIV8_Val 0x2u /**< \brief (SYSCTRL_BOD33) Divide clock by 8 */ +#define SYSCTRL_BOD33_PSEL_DIV16_Val 0x3u /**< \brief (SYSCTRL_BOD33) Divide clock by 16 */ +#define SYSCTRL_BOD33_PSEL_DIV32_Val 0x4u /**< \brief (SYSCTRL_BOD33) Divide clock by 32 */ +#define SYSCTRL_BOD33_PSEL_DIV64_Val 0x5u /**< \brief (SYSCTRL_BOD33) Divide clock by 64 */ +#define SYSCTRL_BOD33_PSEL_DIV128_Val 0x6u /**< \brief (SYSCTRL_BOD33) Divide clock by 128 */ +#define SYSCTRL_BOD33_PSEL_DIV256_Val 0x7u /**< \brief (SYSCTRL_BOD33) Divide clock by 256 */ +#define SYSCTRL_BOD33_PSEL_DIV512_Val 0x8u /**< \brief (SYSCTRL_BOD33) Divide clock by 512 */ +#define SYSCTRL_BOD33_PSEL_DIV1K_Val 0x9u /**< \brief (SYSCTRL_BOD33) Divide clock by 1024 */ +#define SYSCTRL_BOD33_PSEL_DIV2K_Val 0xAu /**< \brief (SYSCTRL_BOD33) Divide clock by 2048 */ +#define SYSCTRL_BOD33_PSEL_DIV4K_Val 0xBu /**< \brief (SYSCTRL_BOD33) Divide clock by 4096 */ +#define SYSCTRL_BOD33_PSEL_DIV8K_Val 0xCu /**< \brief (SYSCTRL_BOD33) Divide clock by 8192 */ +#define SYSCTRL_BOD33_PSEL_DIV16K_Val 0xDu /**< \brief (SYSCTRL_BOD33) Divide clock by 16384 */ +#define SYSCTRL_BOD33_PSEL_DIV32K_Val 0xEu /**< \brief (SYSCTRL_BOD33) Divide clock by 32768 */ +#define SYSCTRL_BOD33_PSEL_DIV64K_Val 0xFu /**< \brief (SYSCTRL_BOD33) Divide clock by 65536 */ +#define SYSCTRL_BOD33_PSEL_DIV2 (SYSCTRL_BOD33_PSEL_DIV2_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV4 (SYSCTRL_BOD33_PSEL_DIV4_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV8 (SYSCTRL_BOD33_PSEL_DIV8_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV16 (SYSCTRL_BOD33_PSEL_DIV16_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV32 (SYSCTRL_BOD33_PSEL_DIV32_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV64 (SYSCTRL_BOD33_PSEL_DIV64_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV128 (SYSCTRL_BOD33_PSEL_DIV128_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV256 (SYSCTRL_BOD33_PSEL_DIV256_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV512 (SYSCTRL_BOD33_PSEL_DIV512_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV1K (SYSCTRL_BOD33_PSEL_DIV1K_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV2K (SYSCTRL_BOD33_PSEL_DIV2K_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV4K (SYSCTRL_BOD33_PSEL_DIV4K_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV8K (SYSCTRL_BOD33_PSEL_DIV8K_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV16K (SYSCTRL_BOD33_PSEL_DIV16K_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV32K (SYSCTRL_BOD33_PSEL_DIV32K_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_PSEL_DIV64K (SYSCTRL_BOD33_PSEL_DIV64K_Val << SYSCTRL_BOD33_PSEL_Pos) +#define SYSCTRL_BOD33_LEVEL_Pos 16 /**< \brief (SYSCTRL_BOD33) BOD33 Threshold Level */ +#define SYSCTRL_BOD33_LEVEL_Msk (0x3Fu << SYSCTRL_BOD33_LEVEL_Pos) +#define SYSCTRL_BOD33_LEVEL(value) ((SYSCTRL_BOD33_LEVEL_Msk & ((value) << SYSCTRL_BOD33_LEVEL_Pos))) +#define SYSCTRL_BOD33_MASK 0x003FF35Eu /**< \brief (SYSCTRL_BOD33) MASK Register */ + +/* -------- SYSCTRL_VREG : (SYSCTRL Offset: 0x3C) (R/W 16) Voltage Regulator System (VREG) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t :6; /*!< bit: 0.. 5 Reserved */ + uint16_t RUNSTDBY:1; /*!< bit: 6 Run in Standby */ + uint16_t :6; /*!< bit: 7..12 Reserved */ + uint16_t FORCELDO:1; /*!< bit: 13 Force LDO Voltage Regulator */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} SYSCTRL_VREG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_VREG_OFFSET 0x3C /**< \brief (SYSCTRL_VREG offset) Voltage Regulator System (VREG) Control */ +#define SYSCTRL_VREG_RESETVALUE 0x0000 /**< \brief (SYSCTRL_VREG reset_value) Voltage Regulator System (VREG) Control */ + +#define SYSCTRL_VREG_RUNSTDBY_Pos 6 /**< \brief (SYSCTRL_VREG) Run in Standby */ +#define SYSCTRL_VREG_RUNSTDBY (0x1u << SYSCTRL_VREG_RUNSTDBY_Pos) +#define SYSCTRL_VREG_FORCELDO_Pos 13 /**< \brief (SYSCTRL_VREG) Force LDO Voltage Regulator */ +#define SYSCTRL_VREG_FORCELDO (0x1u << SYSCTRL_VREG_FORCELDO_Pos) +#define SYSCTRL_VREG_MASK 0x2040u /**< \brief (SYSCTRL_VREG) MASK Register */ + +/* -------- SYSCTRL_VREF : (SYSCTRL Offset: 0x40) (R/W 32) Voltage References System (VREF) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t :1; /*!< bit: 0 Reserved */ + uint32_t TSEN:1; /*!< bit: 1 Temperature Sensor Enable */ + uint32_t BGOUTEN:1; /*!< bit: 2 Bandgap Output Enable */ + uint32_t :13; /*!< bit: 3..15 Reserved */ + uint32_t CALIB:11; /*!< bit: 16..26 Bandgap Voltage Generator Calibration */ + uint32_t :5; /*!< bit: 27..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_VREF_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_VREF_OFFSET 0x40 /**< \brief (SYSCTRL_VREF offset) Voltage References System (VREF) Control */ +#define SYSCTRL_VREF_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_VREF reset_value) Voltage References System (VREF) Control */ + +#define SYSCTRL_VREF_TSEN_Pos 1 /**< \brief (SYSCTRL_VREF) Temperature Sensor Enable */ +#define SYSCTRL_VREF_TSEN (0x1u << SYSCTRL_VREF_TSEN_Pos) +#define SYSCTRL_VREF_BGOUTEN_Pos 2 /**< \brief (SYSCTRL_VREF) Bandgap Output Enable */ +#define SYSCTRL_VREF_BGOUTEN (0x1u << SYSCTRL_VREF_BGOUTEN_Pos) +#define SYSCTRL_VREF_CALIB_Pos 16 /**< \brief (SYSCTRL_VREF) Bandgap Voltage Generator Calibration */ +#define SYSCTRL_VREF_CALIB_Msk (0x7FFu << SYSCTRL_VREF_CALIB_Pos) +#define SYSCTRL_VREF_CALIB(value) ((SYSCTRL_VREF_CALIB_Msk & ((value) << SYSCTRL_VREF_CALIB_Pos))) +#define SYSCTRL_VREF_MASK 0x07FF0006u /**< \brief (SYSCTRL_VREF) MASK Register */ + +/* -------- SYSCTRL_DPLLCTRLA : (SYSCTRL Offset: 0x44) (R/W 8) DPLL Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :1; /*!< bit: 0 Reserved */ + uint8_t ENABLE:1; /*!< bit: 1 DPLL Enable */ + uint8_t :4; /*!< bit: 2.. 5 Reserved */ + uint8_t RUNSTDBY:1; /*!< bit: 6 Run in Standby */ + uint8_t ONDEMAND:1; /*!< bit: 7 On Demand Clock Activation */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SYSCTRL_DPLLCTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_DPLLCTRLA_OFFSET 0x44 /**< \brief (SYSCTRL_DPLLCTRLA offset) DPLL Control A */ +#define SYSCTRL_DPLLCTRLA_RESETVALUE 0x80 /**< \brief (SYSCTRL_DPLLCTRLA reset_value) DPLL Control A */ + +#define SYSCTRL_DPLLCTRLA_ENABLE_Pos 1 /**< \brief (SYSCTRL_DPLLCTRLA) DPLL Enable */ +#define SYSCTRL_DPLLCTRLA_ENABLE (0x1u << SYSCTRL_DPLLCTRLA_ENABLE_Pos) +#define SYSCTRL_DPLLCTRLA_RUNSTDBY_Pos 6 /**< \brief (SYSCTRL_DPLLCTRLA) Run in Standby */ +#define SYSCTRL_DPLLCTRLA_RUNSTDBY (0x1u << SYSCTRL_DPLLCTRLA_RUNSTDBY_Pos) +#define SYSCTRL_DPLLCTRLA_ONDEMAND_Pos 7 /**< \brief (SYSCTRL_DPLLCTRLA) On Demand Clock Activation */ +#define SYSCTRL_DPLLCTRLA_ONDEMAND (0x1u << SYSCTRL_DPLLCTRLA_ONDEMAND_Pos) +#define SYSCTRL_DPLLCTRLA_MASK 0xC2u /**< \brief (SYSCTRL_DPLLCTRLA) MASK Register */ + +/* -------- SYSCTRL_DPLLRATIO : (SYSCTRL Offset: 0x48) (R/W 32) DPLL Ratio Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t LDR:12; /*!< bit: 0..11 Loop Divider Ratio */ + uint32_t :4; /*!< bit: 12..15 Reserved */ + uint32_t LDRFRAC:4; /*!< bit: 16..19 Loop Divider Ratio Fractional Part */ + uint32_t :12; /*!< bit: 20..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_DPLLRATIO_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_DPLLRATIO_OFFSET 0x48 /**< \brief (SYSCTRL_DPLLRATIO offset) DPLL Ratio Control */ +#define SYSCTRL_DPLLRATIO_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_DPLLRATIO reset_value) DPLL Ratio Control */ + +#define SYSCTRL_DPLLRATIO_LDR_Pos 0 /**< \brief (SYSCTRL_DPLLRATIO) Loop Divider Ratio */ +#define SYSCTRL_DPLLRATIO_LDR_Msk (0xFFFu << SYSCTRL_DPLLRATIO_LDR_Pos) +#define SYSCTRL_DPLLRATIO_LDR(value) ((SYSCTRL_DPLLRATIO_LDR_Msk & ((value) << SYSCTRL_DPLLRATIO_LDR_Pos))) +#define SYSCTRL_DPLLRATIO_LDRFRAC_Pos 16 /**< \brief (SYSCTRL_DPLLRATIO) Loop Divider Ratio Fractional Part */ +#define SYSCTRL_DPLLRATIO_LDRFRAC_Msk (0xFu << SYSCTRL_DPLLRATIO_LDRFRAC_Pos) +#define SYSCTRL_DPLLRATIO_LDRFRAC(value) ((SYSCTRL_DPLLRATIO_LDRFRAC_Msk & ((value) << SYSCTRL_DPLLRATIO_LDRFRAC_Pos))) +#define SYSCTRL_DPLLRATIO_MASK 0x000F0FFFu /**< \brief (SYSCTRL_DPLLRATIO) MASK Register */ + +/* -------- SYSCTRL_DPLLCTRLB : (SYSCTRL Offset: 0x4C) (R/W 32) DPLL Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t FILTER:2; /*!< bit: 0.. 1 Proportional Integral Filter Selection */ + uint32_t LPEN:1; /*!< bit: 2 Low-Power Enable */ + uint32_t WUF:1; /*!< bit: 3 Wake Up Fast */ + uint32_t REFCLK:2; /*!< bit: 4.. 5 Reference Clock Selection */ + uint32_t :2; /*!< bit: 6.. 7 Reserved */ + uint32_t LTIME:3; /*!< bit: 8..10 Lock Time */ + uint32_t :1; /*!< bit: 11 Reserved */ + uint32_t LBYPASS:1; /*!< bit: 12 Lock Bypass */ + uint32_t :3; /*!< bit: 13..15 Reserved */ + uint32_t DIV:11; /*!< bit: 16..26 Clock Divider */ + uint32_t :5; /*!< bit: 27..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} SYSCTRL_DPLLCTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_DPLLCTRLB_OFFSET 0x4C /**< \brief (SYSCTRL_DPLLCTRLB offset) DPLL Control B */ +#define SYSCTRL_DPLLCTRLB_RESETVALUE 0x00000000 /**< \brief (SYSCTRL_DPLLCTRLB reset_value) DPLL Control B */ + +#define SYSCTRL_DPLLCTRLB_FILTER_Pos 0 /**< \brief (SYSCTRL_DPLLCTRLB) Proportional Integral Filter Selection */ +#define SYSCTRL_DPLLCTRLB_FILTER_Msk (0x3u << SYSCTRL_DPLLCTRLB_FILTER_Pos) +#define SYSCTRL_DPLLCTRLB_FILTER(value) ((SYSCTRL_DPLLCTRLB_FILTER_Msk & ((value) << SYSCTRL_DPLLCTRLB_FILTER_Pos))) +#define SYSCTRL_DPLLCTRLB_FILTER_DEFAULT_Val 0x0u /**< \brief (SYSCTRL_DPLLCTRLB) Default filter mode */ +#define SYSCTRL_DPLLCTRLB_FILTER_LBFILT_Val 0x1u /**< \brief (SYSCTRL_DPLLCTRLB) Low bandwidth filter */ +#define SYSCTRL_DPLLCTRLB_FILTER_HBFILT_Val 0x2u /**< \brief (SYSCTRL_DPLLCTRLB) High bandwidth filter */ +#define SYSCTRL_DPLLCTRLB_FILTER_HDFILT_Val 0x3u /**< \brief (SYSCTRL_DPLLCTRLB) High damping filter */ +#define SYSCTRL_DPLLCTRLB_FILTER_DEFAULT (SYSCTRL_DPLLCTRLB_FILTER_DEFAULT_Val << SYSCTRL_DPLLCTRLB_FILTER_Pos) +#define SYSCTRL_DPLLCTRLB_FILTER_LBFILT (SYSCTRL_DPLLCTRLB_FILTER_LBFILT_Val << SYSCTRL_DPLLCTRLB_FILTER_Pos) +#define SYSCTRL_DPLLCTRLB_FILTER_HBFILT (SYSCTRL_DPLLCTRLB_FILTER_HBFILT_Val << SYSCTRL_DPLLCTRLB_FILTER_Pos) +#define SYSCTRL_DPLLCTRLB_FILTER_HDFILT (SYSCTRL_DPLLCTRLB_FILTER_HDFILT_Val << SYSCTRL_DPLLCTRLB_FILTER_Pos) +#define SYSCTRL_DPLLCTRLB_LPEN_Pos 2 /**< \brief (SYSCTRL_DPLLCTRLB) Low-Power Enable */ +#define SYSCTRL_DPLLCTRLB_LPEN (0x1u << SYSCTRL_DPLLCTRLB_LPEN_Pos) +#define SYSCTRL_DPLLCTRLB_WUF_Pos 3 /**< \brief (SYSCTRL_DPLLCTRLB) Wake Up Fast */ +#define SYSCTRL_DPLLCTRLB_WUF (0x1u << SYSCTRL_DPLLCTRLB_WUF_Pos) +#define SYSCTRL_DPLLCTRLB_REFCLK_Pos 4 /**< \brief (SYSCTRL_DPLLCTRLB) Reference Clock Selection */ +#define SYSCTRL_DPLLCTRLB_REFCLK_Msk (0x3u << SYSCTRL_DPLLCTRLB_REFCLK_Pos) +#define SYSCTRL_DPLLCTRLB_REFCLK(value) ((SYSCTRL_DPLLCTRLB_REFCLK_Msk & ((value) << SYSCTRL_DPLLCTRLB_REFCLK_Pos))) +#define SYSCTRL_DPLLCTRLB_REFCLK_REF0_Val 0x0u /**< \brief (SYSCTRL_DPLLCTRLB) CLK_DPLL_REF0 clock reference */ +#define SYSCTRL_DPLLCTRLB_REFCLK_REF1_Val 0x1u /**< \brief (SYSCTRL_DPLLCTRLB) CLK_DPLL_REF1 clock reference */ +#define SYSCTRL_DPLLCTRLB_REFCLK_GCLK_Val 0x2u /**< \brief (SYSCTRL_DPLLCTRLB) GCLK_DPLL clock reference */ +#define SYSCTRL_DPLLCTRLB_REFCLK_REF0 (SYSCTRL_DPLLCTRLB_REFCLK_REF0_Val << SYSCTRL_DPLLCTRLB_REFCLK_Pos) +#define SYSCTRL_DPLLCTRLB_REFCLK_REF1 (SYSCTRL_DPLLCTRLB_REFCLK_REF1_Val << SYSCTRL_DPLLCTRLB_REFCLK_Pos) +#define SYSCTRL_DPLLCTRLB_REFCLK_GCLK (SYSCTRL_DPLLCTRLB_REFCLK_GCLK_Val << SYSCTRL_DPLLCTRLB_REFCLK_Pos) +#define SYSCTRL_DPLLCTRLB_LTIME_Pos 8 /**< \brief (SYSCTRL_DPLLCTRLB) Lock Time */ +#define SYSCTRL_DPLLCTRLB_LTIME_Msk (0x7u << SYSCTRL_DPLLCTRLB_LTIME_Pos) +#define SYSCTRL_DPLLCTRLB_LTIME(value) ((SYSCTRL_DPLLCTRLB_LTIME_Msk & ((value) << SYSCTRL_DPLLCTRLB_LTIME_Pos))) +#define SYSCTRL_DPLLCTRLB_LTIME_DEFAULT_Val 0x0u /**< \brief (SYSCTRL_DPLLCTRLB) No time-out */ +#define SYSCTRL_DPLLCTRLB_LTIME_8MS_Val 0x4u /**< \brief (SYSCTRL_DPLLCTRLB) Time-out if no lock within 8 ms */ +#define SYSCTRL_DPLLCTRLB_LTIME_9MS_Val 0x5u /**< \brief (SYSCTRL_DPLLCTRLB) Time-out if no lock within 9 ms */ +#define SYSCTRL_DPLLCTRLB_LTIME_10MS_Val 0x6u /**< \brief (SYSCTRL_DPLLCTRLB) Time-out if no lock within 10 ms */ +#define SYSCTRL_DPLLCTRLB_LTIME_11MS_Val 0x7u /**< \brief (SYSCTRL_DPLLCTRLB) Time-out if no lock within 11 ms */ +#define SYSCTRL_DPLLCTRLB_LTIME_DEFAULT (SYSCTRL_DPLLCTRLB_LTIME_DEFAULT_Val << SYSCTRL_DPLLCTRLB_LTIME_Pos) +#define SYSCTRL_DPLLCTRLB_LTIME_8MS (SYSCTRL_DPLLCTRLB_LTIME_8MS_Val << SYSCTRL_DPLLCTRLB_LTIME_Pos) +#define SYSCTRL_DPLLCTRLB_LTIME_9MS (SYSCTRL_DPLLCTRLB_LTIME_9MS_Val << SYSCTRL_DPLLCTRLB_LTIME_Pos) +#define SYSCTRL_DPLLCTRLB_LTIME_10MS (SYSCTRL_DPLLCTRLB_LTIME_10MS_Val << SYSCTRL_DPLLCTRLB_LTIME_Pos) +#define SYSCTRL_DPLLCTRLB_LTIME_11MS (SYSCTRL_DPLLCTRLB_LTIME_11MS_Val << SYSCTRL_DPLLCTRLB_LTIME_Pos) +#define SYSCTRL_DPLLCTRLB_LBYPASS_Pos 12 /**< \brief (SYSCTRL_DPLLCTRLB) Lock Bypass */ +#define SYSCTRL_DPLLCTRLB_LBYPASS (0x1u << SYSCTRL_DPLLCTRLB_LBYPASS_Pos) +#define SYSCTRL_DPLLCTRLB_DIV_Pos 16 /**< \brief (SYSCTRL_DPLLCTRLB) Clock Divider */ +#define SYSCTRL_DPLLCTRLB_DIV_Msk (0x7FFu << SYSCTRL_DPLLCTRLB_DIV_Pos) +#define SYSCTRL_DPLLCTRLB_DIV(value) ((SYSCTRL_DPLLCTRLB_DIV_Msk & ((value) << SYSCTRL_DPLLCTRLB_DIV_Pos))) +#define SYSCTRL_DPLLCTRLB_MASK 0x07FF173Fu /**< \brief (SYSCTRL_DPLLCTRLB) MASK Register */ + +/* -------- SYSCTRL_DPLLSTATUS : (SYSCTRL Offset: 0x50) (R/ 8) DPLL Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t LOCK:1; /*!< bit: 0 DPLL Lock Status */ + uint8_t CLKRDY:1; /*!< bit: 1 Output Clock Ready */ + uint8_t ENABLE:1; /*!< bit: 2 DPLL Enable */ + uint8_t DIV:1; /*!< bit: 3 Divider Enable */ + uint8_t :4; /*!< bit: 4.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} SYSCTRL_DPLLSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define SYSCTRL_DPLLSTATUS_OFFSET 0x50 /**< \brief (SYSCTRL_DPLLSTATUS offset) DPLL Status */ +#define SYSCTRL_DPLLSTATUS_RESETVALUE 0x00 /**< \brief (SYSCTRL_DPLLSTATUS reset_value) DPLL Status */ + +#define SYSCTRL_DPLLSTATUS_LOCK_Pos 0 /**< \brief (SYSCTRL_DPLLSTATUS) DPLL Lock Status */ +#define SYSCTRL_DPLLSTATUS_LOCK (0x1u << SYSCTRL_DPLLSTATUS_LOCK_Pos) +#define SYSCTRL_DPLLSTATUS_CLKRDY_Pos 1 /**< \brief (SYSCTRL_DPLLSTATUS) Output Clock Ready */ +#define SYSCTRL_DPLLSTATUS_CLKRDY (0x1u << SYSCTRL_DPLLSTATUS_CLKRDY_Pos) +#define SYSCTRL_DPLLSTATUS_ENABLE_Pos 2 /**< \brief (SYSCTRL_DPLLSTATUS) DPLL Enable */ +#define SYSCTRL_DPLLSTATUS_ENABLE (0x1u << SYSCTRL_DPLLSTATUS_ENABLE_Pos) +#define SYSCTRL_DPLLSTATUS_DIV_Pos 3 /**< \brief (SYSCTRL_DPLLSTATUS) Divider Enable */ +#define SYSCTRL_DPLLSTATUS_DIV (0x1u << SYSCTRL_DPLLSTATUS_DIV_Pos) +#define SYSCTRL_DPLLSTATUS_MASK 0x0Fu /**< \brief (SYSCTRL_DPLLSTATUS) MASK Register */ + +/** \brief SYSCTRL hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO SYSCTRL_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x00 (R/W 32) Interrupt Enable Clear */ + __IO SYSCTRL_INTENSET_Type INTENSET; /**< \brief Offset: 0x04 (R/W 32) Interrupt Enable Set */ + __IO SYSCTRL_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x08 (R/W 32) Interrupt Flag Status and Clear */ + __I SYSCTRL_PCLKSR_Type PCLKSR; /**< \brief Offset: 0x0C (R/ 32) Power and Clocks Status */ + __IO SYSCTRL_XOSC_Type XOSC; /**< \brief Offset: 0x10 (R/W 16) External Multipurpose Crystal Oscillator (XOSC) Control */ + RoReg8 Reserved1[0x2]; + __IO SYSCTRL_XOSC32K_Type XOSC32K; /**< \brief Offset: 0x14 (R/W 16) 32kHz External Crystal Oscillator (XOSC32K) Control */ + RoReg8 Reserved2[0x2]; + __IO SYSCTRL_OSC32K_Type OSC32K; /**< \brief Offset: 0x18 (R/W 32) 32kHz Internal Oscillator (OSC32K) Control */ + __IO SYSCTRL_OSCULP32K_Type OSCULP32K; /**< \brief Offset: 0x1C (R/W 8) 32kHz Ultra Low Power Internal Oscillator (OSCULP32K) Control */ + RoReg8 Reserved3[0x3]; + __IO SYSCTRL_OSC8M_Type OSC8M; /**< \brief Offset: 0x20 (R/W 32) 8MHz Internal Oscillator (OSC8M) Control */ + __IO SYSCTRL_DFLLCTRL_Type DFLLCTRL; /**< \brief Offset: 0x24 (R/W 16) DFLL48M Control */ + RoReg8 Reserved4[0x2]; + __IO SYSCTRL_DFLLVAL_Type DFLLVAL; /**< \brief Offset: 0x28 (R/W 32) DFLL48M Value */ + __IO SYSCTRL_DFLLMUL_Type DFLLMUL; /**< \brief Offset: 0x2C (R/W 32) DFLL48M Multiplier */ + __IO SYSCTRL_DFLLSYNC_Type DFLLSYNC; /**< \brief Offset: 0x30 (R/W 8) DFLL48M Synchronization */ + RoReg8 Reserved5[0x3]; + __IO SYSCTRL_BOD33_Type BOD33; /**< \brief Offset: 0x34 (R/W 32) 3.3V Brown-Out Detector (BOD33) Control */ + RoReg8 Reserved6[0x4]; + __IO SYSCTRL_VREG_Type VREG; /**< \brief Offset: 0x3C (R/W 16) Voltage Regulator System (VREG) Control */ + RoReg8 Reserved7[0x2]; + __IO SYSCTRL_VREF_Type VREF; /**< \brief Offset: 0x40 (R/W 32) Voltage References System (VREF) Control */ + __IO SYSCTRL_DPLLCTRLA_Type DPLLCTRLA; /**< \brief Offset: 0x44 (R/W 8) DPLL Control A */ + RoReg8 Reserved8[0x3]; + __IO SYSCTRL_DPLLRATIO_Type DPLLRATIO; /**< \brief Offset: 0x48 (R/W 32) DPLL Ratio Control */ + __IO SYSCTRL_DPLLCTRLB_Type DPLLCTRLB; /**< \brief Offset: 0x4C (R/W 32) DPLL Control B */ + __I SYSCTRL_DPLLSTATUS_Type DPLLSTATUS; /**< \brief Offset: 0x50 (R/ 8) DPLL Status */ +} Sysctrl; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_SYSCTRL_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/tc.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/tc.h new file mode 100755 index 0000000..1ed1557 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/tc.h @@ -0,0 +1,684 @@ +/** + * \file + * + * \brief Component description for TC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_TC_COMPONENT_ +#define _SAMD21_TC_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR TC */ +/* ========================================================================== */ +/** \addtogroup SAMD21_TC Basic Timer Counter */ +/*@{*/ + +#define TC_U2212 +#define REV_TC 0x121 + +/* -------- TC_CTRLA : (TC Offset: 0x00) (R/W 16) Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SWRST:1; /*!< bit: 0 Software Reset */ + uint16_t ENABLE:1; /*!< bit: 1 Enable */ + uint16_t MODE:2; /*!< bit: 2.. 3 TC Mode */ + uint16_t :1; /*!< bit: 4 Reserved */ + uint16_t WAVEGEN:2; /*!< bit: 5.. 6 Waveform Generation Operation */ + uint16_t :1; /*!< bit: 7 Reserved */ + uint16_t PRESCALER:3; /*!< bit: 8..10 Prescaler */ + uint16_t RUNSTDBY:1; /*!< bit: 11 Run in Standby */ + uint16_t PRESCSYNC:2; /*!< bit: 12..13 Prescaler and Counter Synchronization */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} TC_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_CTRLA_OFFSET 0x00 /**< \brief (TC_CTRLA offset) Control A */ +#define TC_CTRLA_RESETVALUE 0x0000 /**< \brief (TC_CTRLA reset_value) Control A */ + +#define TC_CTRLA_SWRST_Pos 0 /**< \brief (TC_CTRLA) Software Reset */ +#define TC_CTRLA_SWRST (0x1u << TC_CTRLA_SWRST_Pos) +#define TC_CTRLA_ENABLE_Pos 1 /**< \brief (TC_CTRLA) Enable */ +#define TC_CTRLA_ENABLE (0x1u << TC_CTRLA_ENABLE_Pos) +#define TC_CTRLA_MODE_Pos 2 /**< \brief (TC_CTRLA) TC Mode */ +#define TC_CTRLA_MODE_Msk (0x3u << TC_CTRLA_MODE_Pos) +#define TC_CTRLA_MODE(value) ((TC_CTRLA_MODE_Msk & ((value) << TC_CTRLA_MODE_Pos))) +#define TC_CTRLA_MODE_COUNT16_Val 0x0u /**< \brief (TC_CTRLA) Counter in 16-bit mode */ +#define TC_CTRLA_MODE_COUNT8_Val 0x1u /**< \brief (TC_CTRLA) Counter in 8-bit mode */ +#define TC_CTRLA_MODE_COUNT32_Val 0x2u /**< \brief (TC_CTRLA) Counter in 32-bit mode */ +#define TC_CTRLA_MODE_COUNT16 (TC_CTRLA_MODE_COUNT16_Val << TC_CTRLA_MODE_Pos) +#define TC_CTRLA_MODE_COUNT8 (TC_CTRLA_MODE_COUNT8_Val << TC_CTRLA_MODE_Pos) +#define TC_CTRLA_MODE_COUNT32 (TC_CTRLA_MODE_COUNT32_Val << TC_CTRLA_MODE_Pos) +#define TC_CTRLA_WAVEGEN_Pos 5 /**< \brief (TC_CTRLA) Waveform Generation Operation */ +#define TC_CTRLA_WAVEGEN_Msk (0x3u << TC_CTRLA_WAVEGEN_Pos) +#define TC_CTRLA_WAVEGEN(value) ((TC_CTRLA_WAVEGEN_Msk & ((value) << TC_CTRLA_WAVEGEN_Pos))) +#define TC_CTRLA_WAVEGEN_NFRQ_Val 0x0u /**< \brief (TC_CTRLA) */ +#define TC_CTRLA_WAVEGEN_MFRQ_Val 0x1u /**< \brief (TC_CTRLA) */ +#define TC_CTRLA_WAVEGEN_NPWM_Val 0x2u /**< \brief (TC_CTRLA) */ +#define TC_CTRLA_WAVEGEN_MPWM_Val 0x3u /**< \brief (TC_CTRLA) */ +#define TC_CTRLA_WAVEGEN_NFRQ (TC_CTRLA_WAVEGEN_NFRQ_Val << TC_CTRLA_WAVEGEN_Pos) +#define TC_CTRLA_WAVEGEN_MFRQ (TC_CTRLA_WAVEGEN_MFRQ_Val << TC_CTRLA_WAVEGEN_Pos) +#define TC_CTRLA_WAVEGEN_NPWM (TC_CTRLA_WAVEGEN_NPWM_Val << TC_CTRLA_WAVEGEN_Pos) +#define TC_CTRLA_WAVEGEN_MPWM (TC_CTRLA_WAVEGEN_MPWM_Val << TC_CTRLA_WAVEGEN_Pos) +#define TC_CTRLA_PRESCALER_Pos 8 /**< \brief (TC_CTRLA) Prescaler */ +#define TC_CTRLA_PRESCALER_Msk (0x7u << TC_CTRLA_PRESCALER_Pos) +#define TC_CTRLA_PRESCALER(value) ((TC_CTRLA_PRESCALER_Msk & ((value) << TC_CTRLA_PRESCALER_Pos))) +#define TC_CTRLA_PRESCALER_DIV1_Val 0x0u /**< \brief (TC_CTRLA) Prescaler: GCLK_TC */ +#define TC_CTRLA_PRESCALER_DIV2_Val 0x1u /**< \brief (TC_CTRLA) Prescaler: GCLK_TC/2 */ +#define TC_CTRLA_PRESCALER_DIV4_Val 0x2u /**< \brief (TC_CTRLA) Prescaler: GCLK_TC/4 */ +#define TC_CTRLA_PRESCALER_DIV8_Val 0x3u /**< \brief (TC_CTRLA) Prescaler: GCLK_TC/8 */ +#define TC_CTRLA_PRESCALER_DIV16_Val 0x4u /**< \brief (TC_CTRLA) Prescaler: GCLK_TC/16 */ +#define TC_CTRLA_PRESCALER_DIV64_Val 0x5u /**< \brief (TC_CTRLA) Prescaler: GCLK_TC/64 */ +#define TC_CTRLA_PRESCALER_DIV256_Val 0x6u /**< \brief (TC_CTRLA) Prescaler: GCLK_TC/256 */ +#define TC_CTRLA_PRESCALER_DIV1024_Val 0x7u /**< \brief (TC_CTRLA) Prescaler: GCLK_TC/1024 */ +#define TC_CTRLA_PRESCALER_DIV1 (TC_CTRLA_PRESCALER_DIV1_Val << TC_CTRLA_PRESCALER_Pos) +#define TC_CTRLA_PRESCALER_DIV2 (TC_CTRLA_PRESCALER_DIV2_Val << TC_CTRLA_PRESCALER_Pos) +#define TC_CTRLA_PRESCALER_DIV4 (TC_CTRLA_PRESCALER_DIV4_Val << TC_CTRLA_PRESCALER_Pos) +#define TC_CTRLA_PRESCALER_DIV8 (TC_CTRLA_PRESCALER_DIV8_Val << TC_CTRLA_PRESCALER_Pos) +#define TC_CTRLA_PRESCALER_DIV16 (TC_CTRLA_PRESCALER_DIV16_Val << TC_CTRLA_PRESCALER_Pos) +#define TC_CTRLA_PRESCALER_DIV64 (TC_CTRLA_PRESCALER_DIV64_Val << TC_CTRLA_PRESCALER_Pos) +#define TC_CTRLA_PRESCALER_DIV256 (TC_CTRLA_PRESCALER_DIV256_Val << TC_CTRLA_PRESCALER_Pos) +#define TC_CTRLA_PRESCALER_DIV1024 (TC_CTRLA_PRESCALER_DIV1024_Val << TC_CTRLA_PRESCALER_Pos) +#define TC_CTRLA_RUNSTDBY_Pos 11 /**< \brief (TC_CTRLA) Run in Standby */ +#define TC_CTRLA_RUNSTDBY (0x1u << TC_CTRLA_RUNSTDBY_Pos) +#define TC_CTRLA_PRESCSYNC_Pos 12 /**< \brief (TC_CTRLA) Prescaler and Counter Synchronization */ +#define TC_CTRLA_PRESCSYNC_Msk (0x3u << TC_CTRLA_PRESCSYNC_Pos) +#define TC_CTRLA_PRESCSYNC(value) ((TC_CTRLA_PRESCSYNC_Msk & ((value) << TC_CTRLA_PRESCSYNC_Pos))) +#define TC_CTRLA_PRESCSYNC_GCLK_Val 0x0u /**< \brief (TC_CTRLA) Reload or reset the counter on next generic clock */ +#define TC_CTRLA_PRESCSYNC_PRESC_Val 0x1u /**< \brief (TC_CTRLA) Reload or reset the counter on next prescaler clock */ +#define TC_CTRLA_PRESCSYNC_RESYNC_Val 0x2u /**< \brief (TC_CTRLA) Reload or reset the counter on next generic clock. Reset the prescaler counter */ +#define TC_CTRLA_PRESCSYNC_GCLK (TC_CTRLA_PRESCSYNC_GCLK_Val << TC_CTRLA_PRESCSYNC_Pos) +#define TC_CTRLA_PRESCSYNC_PRESC (TC_CTRLA_PRESCSYNC_PRESC_Val << TC_CTRLA_PRESCSYNC_Pos) +#define TC_CTRLA_PRESCSYNC_RESYNC (TC_CTRLA_PRESCSYNC_RESYNC_Val << TC_CTRLA_PRESCSYNC_Pos) +#define TC_CTRLA_MASK 0x3F6Fu /**< \brief (TC_CTRLA) MASK Register */ + +/* -------- TC_READREQ : (TC Offset: 0x02) (R/W 16) Read Request -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t ADDR:5; /*!< bit: 0.. 4 Address */ + uint16_t :9; /*!< bit: 5..13 Reserved */ + uint16_t RCONT:1; /*!< bit: 14 Read Continuously */ + uint16_t RREQ:1; /*!< bit: 15 Read Request */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} TC_READREQ_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_READREQ_OFFSET 0x02 /**< \brief (TC_READREQ offset) Read Request */ +#define TC_READREQ_RESETVALUE 0x0000 /**< \brief (TC_READREQ reset_value) Read Request */ + +#define TC_READREQ_ADDR_Pos 0 /**< \brief (TC_READREQ) Address */ +#define TC_READREQ_ADDR_Msk (0x1Fu << TC_READREQ_ADDR_Pos) +#define TC_READREQ_ADDR(value) ((TC_READREQ_ADDR_Msk & ((value) << TC_READREQ_ADDR_Pos))) +#define TC_READREQ_RCONT_Pos 14 /**< \brief (TC_READREQ) Read Continuously */ +#define TC_READREQ_RCONT (0x1u << TC_READREQ_RCONT_Pos) +#define TC_READREQ_RREQ_Pos 15 /**< \brief (TC_READREQ) Read Request */ +#define TC_READREQ_RREQ (0x1u << TC_READREQ_RREQ_Pos) +#define TC_READREQ_MASK 0xC01Fu /**< \brief (TC_READREQ) MASK Register */ + +/* -------- TC_CTRLBCLR : (TC Offset: 0x04) (R/W 8) Control B Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DIR:1; /*!< bit: 0 Counter Direction */ + uint8_t :1; /*!< bit: 1 Reserved */ + uint8_t ONESHOT:1; /*!< bit: 2 One-Shot */ + uint8_t :3; /*!< bit: 3.. 5 Reserved */ + uint8_t CMD:2; /*!< bit: 6.. 7 Command */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TC_CTRLBCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_CTRLBCLR_OFFSET 0x04 /**< \brief (TC_CTRLBCLR offset) Control B Clear */ +#define TC_CTRLBCLR_RESETVALUE 0x02 /**< \brief (TC_CTRLBCLR reset_value) Control B Clear */ + +#define TC_CTRLBCLR_DIR_Pos 0 /**< \brief (TC_CTRLBCLR) Counter Direction */ +#define TC_CTRLBCLR_DIR (0x1u << TC_CTRLBCLR_DIR_Pos) +#define TC_CTRLBCLR_ONESHOT_Pos 2 /**< \brief (TC_CTRLBCLR) One-Shot */ +#define TC_CTRLBCLR_ONESHOT (0x1u << TC_CTRLBCLR_ONESHOT_Pos) +#define TC_CTRLBCLR_CMD_Pos 6 /**< \brief (TC_CTRLBCLR) Command */ +#define TC_CTRLBCLR_CMD_Msk (0x3u << TC_CTRLBCLR_CMD_Pos) +#define TC_CTRLBCLR_CMD(value) ((TC_CTRLBCLR_CMD_Msk & ((value) << TC_CTRLBCLR_CMD_Pos))) +#define TC_CTRLBCLR_CMD_NONE_Val 0x0u /**< \brief (TC_CTRLBCLR) No action */ +#define TC_CTRLBCLR_CMD_RETRIGGER_Val 0x1u /**< \brief (TC_CTRLBCLR) Force a start, restart or retrigger */ +#define TC_CTRLBCLR_CMD_STOP_Val 0x2u /**< \brief (TC_CTRLBCLR) Force a stop */ +#define TC_CTRLBCLR_CMD_NONE (TC_CTRLBCLR_CMD_NONE_Val << TC_CTRLBCLR_CMD_Pos) +#define TC_CTRLBCLR_CMD_RETRIGGER (TC_CTRLBCLR_CMD_RETRIGGER_Val << TC_CTRLBCLR_CMD_Pos) +#define TC_CTRLBCLR_CMD_STOP (TC_CTRLBCLR_CMD_STOP_Val << TC_CTRLBCLR_CMD_Pos) +#define TC_CTRLBCLR_MASK 0xC5u /**< \brief (TC_CTRLBCLR) MASK Register */ + +/* -------- TC_CTRLBSET : (TC Offset: 0x05) (R/W 8) Control B Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DIR:1; /*!< bit: 0 Counter Direction */ + uint8_t :1; /*!< bit: 1 Reserved */ + uint8_t ONESHOT:1; /*!< bit: 2 One-Shot */ + uint8_t :3; /*!< bit: 3.. 5 Reserved */ + uint8_t CMD:2; /*!< bit: 6.. 7 Command */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TC_CTRLBSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_CTRLBSET_OFFSET 0x05 /**< \brief (TC_CTRLBSET offset) Control B Set */ +#define TC_CTRLBSET_RESETVALUE 0x00 /**< \brief (TC_CTRLBSET reset_value) Control B Set */ + +#define TC_CTRLBSET_DIR_Pos 0 /**< \brief (TC_CTRLBSET) Counter Direction */ +#define TC_CTRLBSET_DIR (0x1u << TC_CTRLBSET_DIR_Pos) +#define TC_CTRLBSET_ONESHOT_Pos 2 /**< \brief (TC_CTRLBSET) One-Shot */ +#define TC_CTRLBSET_ONESHOT (0x1u << TC_CTRLBSET_ONESHOT_Pos) +#define TC_CTRLBSET_CMD_Pos 6 /**< \brief (TC_CTRLBSET) Command */ +#define TC_CTRLBSET_CMD_Msk (0x3u << TC_CTRLBSET_CMD_Pos) +#define TC_CTRLBSET_CMD(value) ((TC_CTRLBSET_CMD_Msk & ((value) << TC_CTRLBSET_CMD_Pos))) +#define TC_CTRLBSET_CMD_NONE_Val 0x0u /**< \brief (TC_CTRLBSET) No action */ +#define TC_CTRLBSET_CMD_RETRIGGER_Val 0x1u /**< \brief (TC_CTRLBSET) Force a start, restart or retrigger */ +#define TC_CTRLBSET_CMD_STOP_Val 0x2u /**< \brief (TC_CTRLBSET) Force a stop */ +#define TC_CTRLBSET_CMD_NONE (TC_CTRLBSET_CMD_NONE_Val << TC_CTRLBSET_CMD_Pos) +#define TC_CTRLBSET_CMD_RETRIGGER (TC_CTRLBSET_CMD_RETRIGGER_Val << TC_CTRLBSET_CMD_Pos) +#define TC_CTRLBSET_CMD_STOP (TC_CTRLBSET_CMD_STOP_Val << TC_CTRLBSET_CMD_Pos) +#define TC_CTRLBSET_MASK 0xC5u /**< \brief (TC_CTRLBSET) MASK Register */ + +/* -------- TC_CTRLC : (TC Offset: 0x06) (R/W 8) Control C -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t INVEN0:1; /*!< bit: 0 Output Waveform 0 Invert Enable */ + uint8_t INVEN1:1; /*!< bit: 1 Output Waveform 1 Invert Enable */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t CPTEN0:1; /*!< bit: 4 Capture Channel 0 Enable */ + uint8_t CPTEN1:1; /*!< bit: 5 Capture Channel 1 Enable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t INVEN:2; /*!< bit: 0.. 1 Output Waveform x Invert Enable */ + uint8_t :2; /*!< bit: 2.. 3 Reserved */ + uint8_t CPTEN:2; /*!< bit: 4.. 5 Capture Channel x Enable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} TC_CTRLC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_CTRLC_OFFSET 0x06 /**< \brief (TC_CTRLC offset) Control C */ +#define TC_CTRLC_RESETVALUE 0x00 /**< \brief (TC_CTRLC reset_value) Control C */ + +#define TC_CTRLC_INVEN0_Pos 0 /**< \brief (TC_CTRLC) Output Waveform 0 Invert Enable */ +#define TC_CTRLC_INVEN0 (1 << TC_CTRLC_INVEN0_Pos) +#define TC_CTRLC_INVEN1_Pos 1 /**< \brief (TC_CTRLC) Output Waveform 1 Invert Enable */ +#define TC_CTRLC_INVEN1 (1 << TC_CTRLC_INVEN1_Pos) +#define TC_CTRLC_INVEN_Pos 0 /**< \brief (TC_CTRLC) Output Waveform x Invert Enable */ +#define TC_CTRLC_INVEN_Msk (0x3u << TC_CTRLC_INVEN_Pos) +#define TC_CTRLC_INVEN(value) ((TC_CTRLC_INVEN_Msk & ((value) << TC_CTRLC_INVEN_Pos))) +#define TC_CTRLC_CPTEN0_Pos 4 /**< \brief (TC_CTRLC) Capture Channel 0 Enable */ +#define TC_CTRLC_CPTEN0 (1 << TC_CTRLC_CPTEN0_Pos) +#define TC_CTRLC_CPTEN1_Pos 5 /**< \brief (TC_CTRLC) Capture Channel 1 Enable */ +#define TC_CTRLC_CPTEN1 (1 << TC_CTRLC_CPTEN1_Pos) +#define TC_CTRLC_CPTEN_Pos 4 /**< \brief (TC_CTRLC) Capture Channel x Enable */ +#define TC_CTRLC_CPTEN_Msk (0x3u << TC_CTRLC_CPTEN_Pos) +#define TC_CTRLC_CPTEN(value) ((TC_CTRLC_CPTEN_Msk & ((value) << TC_CTRLC_CPTEN_Pos))) +#define TC_CTRLC_MASK 0x33u /**< \brief (TC_CTRLC) MASK Register */ + +/* -------- TC_DBGCTRL : (TC Offset: 0x08) (R/W 8) Debug Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DBGRUN:1; /*!< bit: 0 Debug Run Mode */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TC_DBGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_DBGCTRL_OFFSET 0x08 /**< \brief (TC_DBGCTRL offset) Debug Control */ +#define TC_DBGCTRL_RESETVALUE 0x00 /**< \brief (TC_DBGCTRL reset_value) Debug Control */ + +#define TC_DBGCTRL_DBGRUN_Pos 0 /**< \brief (TC_DBGCTRL) Debug Run Mode */ +#define TC_DBGCTRL_DBGRUN (0x1u << TC_DBGCTRL_DBGRUN_Pos) +#define TC_DBGCTRL_MASK 0x01u /**< \brief (TC_DBGCTRL) MASK Register */ + +/* -------- TC_EVCTRL : (TC Offset: 0x0A) (R/W 16) Event Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t EVACT:3; /*!< bit: 0.. 2 Event Action */ + uint16_t :1; /*!< bit: 3 Reserved */ + uint16_t TCINV:1; /*!< bit: 4 TC Inverted Event Input */ + uint16_t TCEI:1; /*!< bit: 5 TC Event Input */ + uint16_t :2; /*!< bit: 6.. 7 Reserved */ + uint16_t OVFEO:1; /*!< bit: 8 Overflow/Underflow Event Output Enable */ + uint16_t :3; /*!< bit: 9..11 Reserved */ + uint16_t MCEO0:1; /*!< bit: 12 Match or Capture Channel 0 Event Output Enable */ + uint16_t MCEO1:1; /*!< bit: 13 Match or Capture Channel 1 Event Output Enable */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t :12; /*!< bit: 0..11 Reserved */ + uint16_t MCEO:2; /*!< bit: 12..13 Match or Capture Channel x Event Output Enable */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} TC_EVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_EVCTRL_OFFSET 0x0A /**< \brief (TC_EVCTRL offset) Event Control */ +#define TC_EVCTRL_RESETVALUE 0x0000 /**< \brief (TC_EVCTRL reset_value) Event Control */ + +#define TC_EVCTRL_EVACT_Pos 0 /**< \brief (TC_EVCTRL) Event Action */ +#define TC_EVCTRL_EVACT_Msk (0x7u << TC_EVCTRL_EVACT_Pos) +#define TC_EVCTRL_EVACT(value) ((TC_EVCTRL_EVACT_Msk & ((value) << TC_EVCTRL_EVACT_Pos))) +#define TC_EVCTRL_EVACT_OFF_Val 0x0u /**< \brief (TC_EVCTRL) Event action disabled */ +#define TC_EVCTRL_EVACT_RETRIGGER_Val 0x1u /**< \brief (TC_EVCTRL) Start, restart or retrigger TC on event */ +#define TC_EVCTRL_EVACT_COUNT_Val 0x2u /**< \brief (TC_EVCTRL) Count on event */ +#define TC_EVCTRL_EVACT_START_Val 0x3u /**< \brief (TC_EVCTRL) Start TC on event */ +#define TC_EVCTRL_EVACT_PPW_Val 0x5u /**< \brief (TC_EVCTRL) Period captured in CC0, pulse width in CC1 */ +#define TC_EVCTRL_EVACT_PWP_Val 0x6u /**< \brief (TC_EVCTRL) Period captured in CC1, pulse width in CC0 */ +#define TC_EVCTRL_EVACT_OFF (TC_EVCTRL_EVACT_OFF_Val << TC_EVCTRL_EVACT_Pos) +#define TC_EVCTRL_EVACT_RETRIGGER (TC_EVCTRL_EVACT_RETRIGGER_Val << TC_EVCTRL_EVACT_Pos) +#define TC_EVCTRL_EVACT_COUNT (TC_EVCTRL_EVACT_COUNT_Val << TC_EVCTRL_EVACT_Pos) +#define TC_EVCTRL_EVACT_START (TC_EVCTRL_EVACT_START_Val << TC_EVCTRL_EVACT_Pos) +#define TC_EVCTRL_EVACT_PPW (TC_EVCTRL_EVACT_PPW_Val << TC_EVCTRL_EVACT_Pos) +#define TC_EVCTRL_EVACT_PWP (TC_EVCTRL_EVACT_PWP_Val << TC_EVCTRL_EVACT_Pos) +#define TC_EVCTRL_TCINV_Pos 4 /**< \brief (TC_EVCTRL) TC Inverted Event Input */ +#define TC_EVCTRL_TCINV (0x1u << TC_EVCTRL_TCINV_Pos) +#define TC_EVCTRL_TCEI_Pos 5 /**< \brief (TC_EVCTRL) TC Event Input */ +#define TC_EVCTRL_TCEI (0x1u << TC_EVCTRL_TCEI_Pos) +#define TC_EVCTRL_OVFEO_Pos 8 /**< \brief (TC_EVCTRL) Overflow/Underflow Event Output Enable */ +#define TC_EVCTRL_OVFEO (0x1u << TC_EVCTRL_OVFEO_Pos) +#define TC_EVCTRL_MCEO0_Pos 12 /**< \brief (TC_EVCTRL) Match or Capture Channel 0 Event Output Enable */ +#define TC_EVCTRL_MCEO0 (1 << TC_EVCTRL_MCEO0_Pos) +#define TC_EVCTRL_MCEO1_Pos 13 /**< \brief (TC_EVCTRL) Match or Capture Channel 1 Event Output Enable */ +#define TC_EVCTRL_MCEO1 (1 << TC_EVCTRL_MCEO1_Pos) +#define TC_EVCTRL_MCEO_Pos 12 /**< \brief (TC_EVCTRL) Match or Capture Channel x Event Output Enable */ +#define TC_EVCTRL_MCEO_Msk (0x3u << TC_EVCTRL_MCEO_Pos) +#define TC_EVCTRL_MCEO(value) ((TC_EVCTRL_MCEO_Msk & ((value) << TC_EVCTRL_MCEO_Pos))) +#define TC_EVCTRL_MASK 0x3137u /**< \brief (TC_EVCTRL) MASK Register */ + +/* -------- TC_INTENCLR : (TC Offset: 0x0C) (R/W 8) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t OVF:1; /*!< bit: 0 Overflow Interrupt Enable */ + uint8_t ERR:1; /*!< bit: 1 Error Interrupt Enable */ + uint8_t :1; /*!< bit: 2 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 3 Synchronization Ready Interrupt Enable */ + uint8_t MC0:1; /*!< bit: 4 Match or Capture Channel 0 Interrupt Enable */ + uint8_t MC1:1; /*!< bit: 5 Match or Capture Channel 1 Interrupt Enable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t :4; /*!< bit: 0.. 3 Reserved */ + uint8_t MC:2; /*!< bit: 4.. 5 Match or Capture Channel x Interrupt Enable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} TC_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_INTENCLR_OFFSET 0x0C /**< \brief (TC_INTENCLR offset) Interrupt Enable Clear */ +#define TC_INTENCLR_RESETVALUE 0x00 /**< \brief (TC_INTENCLR reset_value) Interrupt Enable Clear */ + +#define TC_INTENCLR_OVF_Pos 0 /**< \brief (TC_INTENCLR) Overflow Interrupt Enable */ +#define TC_INTENCLR_OVF (0x1u << TC_INTENCLR_OVF_Pos) +#define TC_INTENCLR_ERR_Pos 1 /**< \brief (TC_INTENCLR) Error Interrupt Enable */ +#define TC_INTENCLR_ERR (0x1u << TC_INTENCLR_ERR_Pos) +#define TC_INTENCLR_SYNCRDY_Pos 3 /**< \brief (TC_INTENCLR) Synchronization Ready Interrupt Enable */ +#define TC_INTENCLR_SYNCRDY (0x1u << TC_INTENCLR_SYNCRDY_Pos) +#define TC_INTENCLR_MC0_Pos 4 /**< \brief (TC_INTENCLR) Match or Capture Channel 0 Interrupt Enable */ +#define TC_INTENCLR_MC0 (1 << TC_INTENCLR_MC0_Pos) +#define TC_INTENCLR_MC1_Pos 5 /**< \brief (TC_INTENCLR) Match or Capture Channel 1 Interrupt Enable */ +#define TC_INTENCLR_MC1 (1 << TC_INTENCLR_MC1_Pos) +#define TC_INTENCLR_MC_Pos 4 /**< \brief (TC_INTENCLR) Match or Capture Channel x Interrupt Enable */ +#define TC_INTENCLR_MC_Msk (0x3u << TC_INTENCLR_MC_Pos) +#define TC_INTENCLR_MC(value) ((TC_INTENCLR_MC_Msk & ((value) << TC_INTENCLR_MC_Pos))) +#define TC_INTENCLR_MASK 0x3Bu /**< \brief (TC_INTENCLR) MASK Register */ + +/* -------- TC_INTENSET : (TC Offset: 0x0D) (R/W 8) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t OVF:1; /*!< bit: 0 Overflow Interrupt Enable */ + uint8_t ERR:1; /*!< bit: 1 Error Interrupt Enable */ + uint8_t :1; /*!< bit: 2 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 3 Synchronization Ready Interrupt Enable */ + uint8_t MC0:1; /*!< bit: 4 Match or Capture Channel 0 Interrupt Enable */ + uint8_t MC1:1; /*!< bit: 5 Match or Capture Channel 1 Interrupt Enable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t :4; /*!< bit: 0.. 3 Reserved */ + uint8_t MC:2; /*!< bit: 4.. 5 Match or Capture Channel x Interrupt Enable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} TC_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_INTENSET_OFFSET 0x0D /**< \brief (TC_INTENSET offset) Interrupt Enable Set */ +#define TC_INTENSET_RESETVALUE 0x00 /**< \brief (TC_INTENSET reset_value) Interrupt Enable Set */ + +#define TC_INTENSET_OVF_Pos 0 /**< \brief (TC_INTENSET) Overflow Interrupt Enable */ +#define TC_INTENSET_OVF (0x1u << TC_INTENSET_OVF_Pos) +#define TC_INTENSET_ERR_Pos 1 /**< \brief (TC_INTENSET) Error Interrupt Enable */ +#define TC_INTENSET_ERR (0x1u << TC_INTENSET_ERR_Pos) +#define TC_INTENSET_SYNCRDY_Pos 3 /**< \brief (TC_INTENSET) Synchronization Ready Interrupt Enable */ +#define TC_INTENSET_SYNCRDY (0x1u << TC_INTENSET_SYNCRDY_Pos) +#define TC_INTENSET_MC0_Pos 4 /**< \brief (TC_INTENSET) Match or Capture Channel 0 Interrupt Enable */ +#define TC_INTENSET_MC0 (1 << TC_INTENSET_MC0_Pos) +#define TC_INTENSET_MC1_Pos 5 /**< \brief (TC_INTENSET) Match or Capture Channel 1 Interrupt Enable */ +#define TC_INTENSET_MC1 (1 << TC_INTENSET_MC1_Pos) +#define TC_INTENSET_MC_Pos 4 /**< \brief (TC_INTENSET) Match or Capture Channel x Interrupt Enable */ +#define TC_INTENSET_MC_Msk (0x3u << TC_INTENSET_MC_Pos) +#define TC_INTENSET_MC(value) ((TC_INTENSET_MC_Msk & ((value) << TC_INTENSET_MC_Pos))) +#define TC_INTENSET_MASK 0x3Bu /**< \brief (TC_INTENSET) MASK Register */ + +/* -------- TC_INTFLAG : (TC Offset: 0x0E) (R/W 8) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t OVF:1; /*!< bit: 0 Overflow */ + uint8_t ERR:1; /*!< bit: 1 Error */ + uint8_t :1; /*!< bit: 2 Reserved */ + uint8_t SYNCRDY:1; /*!< bit: 3 Synchronization Ready */ + uint8_t MC0:1; /*!< bit: 4 Match or Capture Channel 0 */ + uint8_t MC1:1; /*!< bit: 5 Match or Capture Channel 1 */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t :4; /*!< bit: 0.. 3 Reserved */ + uint8_t MC:2; /*!< bit: 4.. 5 Match or Capture Channel x */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} TC_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_INTFLAG_OFFSET 0x0E /**< \brief (TC_INTFLAG offset) Interrupt Flag Status and Clear */ +#define TC_INTFLAG_RESETVALUE 0x00 /**< \brief (TC_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define TC_INTFLAG_OVF_Pos 0 /**< \brief (TC_INTFLAG) Overflow */ +#define TC_INTFLAG_OVF (0x1u << TC_INTFLAG_OVF_Pos) +#define TC_INTFLAG_ERR_Pos 1 /**< \brief (TC_INTFLAG) Error */ +#define TC_INTFLAG_ERR (0x1u << TC_INTFLAG_ERR_Pos) +#define TC_INTFLAG_SYNCRDY_Pos 3 /**< \brief (TC_INTFLAG) Synchronization Ready */ +#define TC_INTFLAG_SYNCRDY (0x1u << TC_INTFLAG_SYNCRDY_Pos) +#define TC_INTFLAG_MC0_Pos 4 /**< \brief (TC_INTFLAG) Match or Capture Channel 0 */ +#define TC_INTFLAG_MC0 (1 << TC_INTFLAG_MC0_Pos) +#define TC_INTFLAG_MC1_Pos 5 /**< \brief (TC_INTFLAG) Match or Capture Channel 1 */ +#define TC_INTFLAG_MC1 (1 << TC_INTFLAG_MC1_Pos) +#define TC_INTFLAG_MC_Pos 4 /**< \brief (TC_INTFLAG) Match or Capture Channel x */ +#define TC_INTFLAG_MC_Msk (0x3u << TC_INTFLAG_MC_Pos) +#define TC_INTFLAG_MC(value) ((TC_INTFLAG_MC_Msk & ((value) << TC_INTFLAG_MC_Pos))) +#define TC_INTFLAG_MASK 0x3Bu /**< \brief (TC_INTFLAG) MASK Register */ + +/* -------- TC_STATUS : (TC Offset: 0x0F) (R/ 8) Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :3; /*!< bit: 0.. 2 Reserved */ + uint8_t STOP:1; /*!< bit: 3 Stop */ + uint8_t SLAVE:1; /*!< bit: 4 Slave */ + uint8_t :2; /*!< bit: 5.. 6 Reserved */ + uint8_t SYNCBUSY:1; /*!< bit: 7 Synchronization Busy */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TC_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_STATUS_OFFSET 0x0F /**< \brief (TC_STATUS offset) Status */ +#define TC_STATUS_RESETVALUE 0x08 /**< \brief (TC_STATUS reset_value) Status */ + +#define TC_STATUS_STOP_Pos 3 /**< \brief (TC_STATUS) Stop */ +#define TC_STATUS_STOP (0x1u << TC_STATUS_STOP_Pos) +#define TC_STATUS_SLAVE_Pos 4 /**< \brief (TC_STATUS) Slave */ +#define TC_STATUS_SLAVE (0x1u << TC_STATUS_SLAVE_Pos) +#define TC_STATUS_SYNCBUSY_Pos 7 /**< \brief (TC_STATUS) Synchronization Busy */ +#define TC_STATUS_SYNCBUSY (0x1u << TC_STATUS_SYNCBUSY_Pos) +#define TC_STATUS_MASK 0x98u /**< \brief (TC_STATUS) MASK Register */ + +/* -------- TC_COUNT16_COUNT : (TC Offset: 0x10) (R/W 16) COUNT16 COUNT16 Counter Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t COUNT:16; /*!< bit: 0..15 Count Value */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} TC_COUNT16_COUNT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_COUNT16_COUNT_OFFSET 0x10 /**< \brief (TC_COUNT16_COUNT offset) COUNT16 Counter Value */ +#define TC_COUNT16_COUNT_RESETVALUE 0x0000 /**< \brief (TC_COUNT16_COUNT reset_value) COUNT16 Counter Value */ + +#define TC_COUNT16_COUNT_COUNT_Pos 0 /**< \brief (TC_COUNT16_COUNT) Count Value */ +#define TC_COUNT16_COUNT_COUNT_Msk (0xFFFFu << TC_COUNT16_COUNT_COUNT_Pos) +#define TC_COUNT16_COUNT_COUNT(value) ((TC_COUNT16_COUNT_COUNT_Msk & ((value) << TC_COUNT16_COUNT_COUNT_Pos))) +#define TC_COUNT16_COUNT_MASK 0xFFFFu /**< \brief (TC_COUNT16_COUNT) MASK Register */ + +/* -------- TC_COUNT32_COUNT : (TC Offset: 0x10) (R/W 32) COUNT32 COUNT32 Counter Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t COUNT:32; /*!< bit: 0..31 Count Value */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} TC_COUNT32_COUNT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_COUNT32_COUNT_OFFSET 0x10 /**< \brief (TC_COUNT32_COUNT offset) COUNT32 Counter Value */ +#define TC_COUNT32_COUNT_RESETVALUE 0x00000000 /**< \brief (TC_COUNT32_COUNT reset_value) COUNT32 Counter Value */ + +#define TC_COUNT32_COUNT_COUNT_Pos 0 /**< \brief (TC_COUNT32_COUNT) Count Value */ +#define TC_COUNT32_COUNT_COUNT_Msk (0xFFFFFFFFu << TC_COUNT32_COUNT_COUNT_Pos) +#define TC_COUNT32_COUNT_COUNT(value) ((TC_COUNT32_COUNT_COUNT_Msk & ((value) << TC_COUNT32_COUNT_COUNT_Pos))) +#define TC_COUNT32_COUNT_MASK 0xFFFFFFFFu /**< \brief (TC_COUNT32_COUNT) MASK Register */ + +/* -------- TC_COUNT8_COUNT : (TC Offset: 0x10) (R/W 8) COUNT8 COUNT8 Counter Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t COUNT:8; /*!< bit: 0.. 7 Counter Value */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TC_COUNT8_COUNT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_COUNT8_COUNT_OFFSET 0x10 /**< \brief (TC_COUNT8_COUNT offset) COUNT8 Counter Value */ +#define TC_COUNT8_COUNT_RESETVALUE 0x00 /**< \brief (TC_COUNT8_COUNT reset_value) COUNT8 Counter Value */ + +#define TC_COUNT8_COUNT_COUNT_Pos 0 /**< \brief (TC_COUNT8_COUNT) Counter Value */ +#define TC_COUNT8_COUNT_COUNT_Msk (0xFFu << TC_COUNT8_COUNT_COUNT_Pos) +#define TC_COUNT8_COUNT_COUNT(value) ((TC_COUNT8_COUNT_COUNT_Msk & ((value) << TC_COUNT8_COUNT_COUNT_Pos))) +#define TC_COUNT8_COUNT_MASK 0xFFu /**< \brief (TC_COUNT8_COUNT) MASK Register */ + +/* -------- TC_COUNT8_PER : (TC Offset: 0x14) (R/W 8) COUNT8 COUNT8 Period Value -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PER:8; /*!< bit: 0.. 7 Period Value */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TC_COUNT8_PER_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_COUNT8_PER_OFFSET 0x14 /**< \brief (TC_COUNT8_PER offset) COUNT8 Period Value */ +#define TC_COUNT8_PER_RESETVALUE 0xFF /**< \brief (TC_COUNT8_PER reset_value) COUNT8 Period Value */ + +#define TC_COUNT8_PER_PER_Pos 0 /**< \brief (TC_COUNT8_PER) Period Value */ +#define TC_COUNT8_PER_PER_Msk (0xFFu << TC_COUNT8_PER_PER_Pos) +#define TC_COUNT8_PER_PER(value) ((TC_COUNT8_PER_PER_Msk & ((value) << TC_COUNT8_PER_PER_Pos))) +#define TC_COUNT8_PER_MASK 0xFFu /**< \brief (TC_COUNT8_PER) MASK Register */ + +/* -------- TC_COUNT16_CC : (TC Offset: 0x18) (R/W 16) COUNT16 COUNT16 Compare/Capture -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t CC:16; /*!< bit: 0..15 Compare/Capture Value */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} TC_COUNT16_CC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_COUNT16_CC_OFFSET 0x18 /**< \brief (TC_COUNT16_CC offset) COUNT16 Compare/Capture */ +#define TC_COUNT16_CC_RESETVALUE 0x0000 /**< \brief (TC_COUNT16_CC reset_value) COUNT16 Compare/Capture */ + +#define TC_COUNT16_CC_CC_Pos 0 /**< \brief (TC_COUNT16_CC) Compare/Capture Value */ +#define TC_COUNT16_CC_CC_Msk (0xFFFFu << TC_COUNT16_CC_CC_Pos) +#define TC_COUNT16_CC_CC(value) ((TC_COUNT16_CC_CC_Msk & ((value) << TC_COUNT16_CC_CC_Pos))) +#define TC_COUNT16_CC_MASK 0xFFFFu /**< \brief (TC_COUNT16_CC) MASK Register */ + +/* -------- TC_COUNT32_CC : (TC Offset: 0x18) (R/W 32) COUNT32 COUNT32 Compare/Capture -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CC:32; /*!< bit: 0..31 Compare/Capture Value */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} TC_COUNT32_CC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_COUNT32_CC_OFFSET 0x18 /**< \brief (TC_COUNT32_CC offset) COUNT32 Compare/Capture */ +#define TC_COUNT32_CC_RESETVALUE 0x00000000 /**< \brief (TC_COUNT32_CC reset_value) COUNT32 Compare/Capture */ + +#define TC_COUNT32_CC_CC_Pos 0 /**< \brief (TC_COUNT32_CC) Compare/Capture Value */ +#define TC_COUNT32_CC_CC_Msk (0xFFFFFFFFu << TC_COUNT32_CC_CC_Pos) +#define TC_COUNT32_CC_CC(value) ((TC_COUNT32_CC_CC_Msk & ((value) << TC_COUNT32_CC_CC_Pos))) +#define TC_COUNT32_CC_MASK 0xFFFFFFFFu /**< \brief (TC_COUNT32_CC) MASK Register */ + +/* -------- TC_COUNT8_CC : (TC Offset: 0x18) (R/W 8) COUNT8 COUNT8 Compare/Capture -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CC:8; /*!< bit: 0.. 7 Compare/Capture Value */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TC_COUNT8_CC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TC_COUNT8_CC_OFFSET 0x18 /**< \brief (TC_COUNT8_CC offset) COUNT8 Compare/Capture */ +#define TC_COUNT8_CC_RESETVALUE 0x00 /**< \brief (TC_COUNT8_CC reset_value) COUNT8 Compare/Capture */ + +#define TC_COUNT8_CC_CC_Pos 0 /**< \brief (TC_COUNT8_CC) Compare/Capture Value */ +#define TC_COUNT8_CC_CC_Msk (0xFFu << TC_COUNT8_CC_CC_Pos) +#define TC_COUNT8_CC_CC(value) ((TC_COUNT8_CC_CC_Msk & ((value) << TC_COUNT8_CC_CC_Pos))) +#define TC_COUNT8_CC_MASK 0xFFu /**< \brief (TC_COUNT8_CC) MASK Register */ + +/** \brief TC_COUNT8 hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* 8-bit Counter Mode */ + __IO TC_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 16) Control A */ + __IO TC_READREQ_Type READREQ; /**< \brief Offset: 0x02 (R/W 16) Read Request */ + __IO TC_CTRLBCLR_Type CTRLBCLR; /**< \brief Offset: 0x04 (R/W 8) Control B Clear */ + __IO TC_CTRLBSET_Type CTRLBSET; /**< \brief Offset: 0x05 (R/W 8) Control B Set */ + __IO TC_CTRLC_Type CTRLC; /**< \brief Offset: 0x06 (R/W 8) Control C */ + RoReg8 Reserved1[0x1]; + __IO TC_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x08 (R/W 8) Debug Control */ + RoReg8 Reserved2[0x1]; + __IO TC_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x0A (R/W 16) Event Control */ + __IO TC_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x0C (R/W 8) Interrupt Enable Clear */ + __IO TC_INTENSET_Type INTENSET; /**< \brief Offset: 0x0D (R/W 8) Interrupt Enable Set */ + __IO TC_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x0E (R/W 8) Interrupt Flag Status and Clear */ + __I TC_STATUS_Type STATUS; /**< \brief Offset: 0x0F (R/ 8) Status */ + __IO TC_COUNT8_COUNT_Type COUNT; /**< \brief Offset: 0x10 (R/W 8) COUNT8 Counter Value */ + RoReg8 Reserved3[0x3]; + __IO TC_COUNT8_PER_Type PER; /**< \brief Offset: 0x14 (R/W 8) COUNT8 Period Value */ + RoReg8 Reserved4[0x3]; + __IO TC_COUNT8_CC_Type CC[2]; /**< \brief Offset: 0x18 (R/W 8) COUNT8 Compare/Capture */ +} TcCount8; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief TC_COUNT16 hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* 16-bit Counter Mode */ + __IO TC_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 16) Control A */ + __IO TC_READREQ_Type READREQ; /**< \brief Offset: 0x02 (R/W 16) Read Request */ + __IO TC_CTRLBCLR_Type CTRLBCLR; /**< \brief Offset: 0x04 (R/W 8) Control B Clear */ + __IO TC_CTRLBSET_Type CTRLBSET; /**< \brief Offset: 0x05 (R/W 8) Control B Set */ + __IO TC_CTRLC_Type CTRLC; /**< \brief Offset: 0x06 (R/W 8) Control C */ + RoReg8 Reserved1[0x1]; + __IO TC_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x08 (R/W 8) Debug Control */ + RoReg8 Reserved2[0x1]; + __IO TC_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x0A (R/W 16) Event Control */ + __IO TC_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x0C (R/W 8) Interrupt Enable Clear */ + __IO TC_INTENSET_Type INTENSET; /**< \brief Offset: 0x0D (R/W 8) Interrupt Enable Set */ + __IO TC_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x0E (R/W 8) Interrupt Flag Status and Clear */ + __I TC_STATUS_Type STATUS; /**< \brief Offset: 0x0F (R/ 8) Status */ + __IO TC_COUNT16_COUNT_Type COUNT; /**< \brief Offset: 0x10 (R/W 16) COUNT16 Counter Value */ + RoReg8 Reserved3[0x6]; + __IO TC_COUNT16_CC_Type CC[2]; /**< \brief Offset: 0x18 (R/W 16) COUNT16 Compare/Capture */ +} TcCount16; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief TC_COUNT32 hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* 32-bit Counter Mode */ + __IO TC_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 16) Control A */ + __IO TC_READREQ_Type READREQ; /**< \brief Offset: 0x02 (R/W 16) Read Request */ + __IO TC_CTRLBCLR_Type CTRLBCLR; /**< \brief Offset: 0x04 (R/W 8) Control B Clear */ + __IO TC_CTRLBSET_Type CTRLBSET; /**< \brief Offset: 0x05 (R/W 8) Control B Set */ + __IO TC_CTRLC_Type CTRLC; /**< \brief Offset: 0x06 (R/W 8) Control C */ + RoReg8 Reserved1[0x1]; + __IO TC_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x08 (R/W 8) Debug Control */ + RoReg8 Reserved2[0x1]; + __IO TC_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x0A (R/W 16) Event Control */ + __IO TC_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x0C (R/W 8) Interrupt Enable Clear */ + __IO TC_INTENSET_Type INTENSET; /**< \brief Offset: 0x0D (R/W 8) Interrupt Enable Set */ + __IO TC_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x0E (R/W 8) Interrupt Flag Status and Clear */ + __I TC_STATUS_Type STATUS; /**< \brief Offset: 0x0F (R/ 8) Status */ + __IO TC_COUNT32_COUNT_Type COUNT; /**< \brief Offset: 0x10 (R/W 32) COUNT32 Counter Value */ + RoReg8 Reserved3[0x4]; + __IO TC_COUNT32_CC_Type CC[2]; /**< \brief Offset: 0x18 (R/W 32) COUNT32 Compare/Capture */ +} TcCount32; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + TcCount8 COUNT8; /**< \brief Offset: 0x00 8-bit Counter Mode */ + TcCount16 COUNT16; /**< \brief Offset: 0x00 16-bit Counter Mode */ + TcCount32 COUNT32; /**< \brief Offset: 0x00 32-bit Counter Mode */ +} Tc; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_TC_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/tcc.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/tcc.h new file mode 100755 index 0000000..65fad45 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/tcc.h @@ -0,0 +1,1608 @@ +/** + * \file + * + * \brief Component description for TCC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_TCC_COMPONENT_ +#define _SAMD21_TCC_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR TCC */ +/* ========================================================================== */ +/** \addtogroup SAMD21_TCC Timer Counter Control */ +/*@{*/ + +#define TCC_U2213 +#define REV_TCC 0x101 + +/* -------- TCC_CTRLA : (TCC Offset: 0x00) (R/W 32) Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Software Reset */ + uint32_t ENABLE:1; /*!< bit: 1 Enable */ + uint32_t :3; /*!< bit: 2.. 4 Reserved */ + uint32_t RESOLUTION:2; /*!< bit: 5.. 6 Enhanced Resolution */ + uint32_t :1; /*!< bit: 7 Reserved */ + uint32_t PRESCALER:3; /*!< bit: 8..10 Prescaler */ + uint32_t RUNSTDBY:1; /*!< bit: 11 Run in Standby */ + uint32_t PRESCSYNC:2; /*!< bit: 12..13 Prescaler and Counter Synchronization Selection */ + uint32_t ALOCK:1; /*!< bit: 14 Auto Lock */ + uint32_t :9; /*!< bit: 15..23 Reserved */ + uint32_t CPTEN0:1; /*!< bit: 24 Capture Channel 0 Enable */ + uint32_t CPTEN1:1; /*!< bit: 25 Capture Channel 1 Enable */ + uint32_t CPTEN2:1; /*!< bit: 26 Capture Channel 2 Enable */ + uint32_t CPTEN3:1; /*!< bit: 27 Capture Channel 3 Enable */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :24; /*!< bit: 0..23 Reserved */ + uint32_t CPTEN:4; /*!< bit: 24..27 Capture Channel x Enable */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_CTRLA_OFFSET 0x00 /**< \brief (TCC_CTRLA offset) Control A */ +#define TCC_CTRLA_RESETVALUE 0x00000000 /**< \brief (TCC_CTRLA reset_value) Control A */ + +#define TCC_CTRLA_SWRST_Pos 0 /**< \brief (TCC_CTRLA) Software Reset */ +#define TCC_CTRLA_SWRST (0x1u << TCC_CTRLA_SWRST_Pos) +#define TCC_CTRLA_ENABLE_Pos 1 /**< \brief (TCC_CTRLA) Enable */ +#define TCC_CTRLA_ENABLE (0x1u << TCC_CTRLA_ENABLE_Pos) +#define TCC_CTRLA_RESOLUTION_Pos 5 /**< \brief (TCC_CTRLA) Enhanced Resolution */ +#define TCC_CTRLA_RESOLUTION_Msk (0x3u << TCC_CTRLA_RESOLUTION_Pos) +#define TCC_CTRLA_RESOLUTION(value) ((TCC_CTRLA_RESOLUTION_Msk & ((value) << TCC_CTRLA_RESOLUTION_Pos))) +#define TCC_CTRLA_RESOLUTION_NONE_Val 0x0u /**< \brief (TCC_CTRLA) Dithering is disabled */ +#define TCC_CTRLA_RESOLUTION_DITH4_Val 0x1u /**< \brief (TCC_CTRLA) Dithering is done every 16 PWM frames. PER[3:0] and CCx[3:0] contain dithering pattern selection. */ +#define TCC_CTRLA_RESOLUTION_DITH5_Val 0x2u /**< \brief (TCC_CTRLA) Dithering is done every 32 PWM frames. PER[4:0] and CCx[4:0] contain dithering pattern selection. */ +#define TCC_CTRLA_RESOLUTION_DITH6_Val 0x3u /**< \brief (TCC_CTRLA) Dithering is done every 64 PWM frames. PER[5:0] and CCx[5:0] contain dithering pattern selection. */ +#define TCC_CTRLA_RESOLUTION_NONE (TCC_CTRLA_RESOLUTION_NONE_Val << TCC_CTRLA_RESOLUTION_Pos) +#define TCC_CTRLA_RESOLUTION_DITH4 (TCC_CTRLA_RESOLUTION_DITH4_Val << TCC_CTRLA_RESOLUTION_Pos) +#define TCC_CTRLA_RESOLUTION_DITH5 (TCC_CTRLA_RESOLUTION_DITH5_Val << TCC_CTRLA_RESOLUTION_Pos) +#define TCC_CTRLA_RESOLUTION_DITH6 (TCC_CTRLA_RESOLUTION_DITH6_Val << TCC_CTRLA_RESOLUTION_Pos) +#define TCC_CTRLA_PRESCALER_Pos 8 /**< \brief (TCC_CTRLA) Prescaler */ +#define TCC_CTRLA_PRESCALER_Msk (0x7u << TCC_CTRLA_PRESCALER_Pos) +#define TCC_CTRLA_PRESCALER(value) ((TCC_CTRLA_PRESCALER_Msk & ((value) << TCC_CTRLA_PRESCALER_Pos))) +#define TCC_CTRLA_PRESCALER_DIV1_Val 0x0u /**< \brief (TCC_CTRLA) Prescaler: GCLK_TCC */ +#define TCC_CTRLA_PRESCALER_DIV2_Val 0x1u /**< \brief (TCC_CTRLA) Prescaler: GCLK_TCC/2 */ +#define TCC_CTRLA_PRESCALER_DIV4_Val 0x2u /**< \brief (TCC_CTRLA) Prescaler: GCLK_TCC/4 */ +#define TCC_CTRLA_PRESCALER_DIV8_Val 0x3u /**< \brief (TCC_CTRLA) Prescaler: GCLK_TCC/8 */ +#define TCC_CTRLA_PRESCALER_DIV16_Val 0x4u /**< \brief (TCC_CTRLA) Prescaler: GCLK_TCC/16 */ +#define TCC_CTRLA_PRESCALER_DIV64_Val 0x5u /**< \brief (TCC_CTRLA) Prescaler: GCLK_TCC/64 */ +#define TCC_CTRLA_PRESCALER_DIV256_Val 0x6u /**< \brief (TCC_CTRLA) Prescaler: GCLK_TCC/256 */ +#define TCC_CTRLA_PRESCALER_DIV1024_Val 0x7u /**< \brief (TCC_CTRLA) Prescaler: GCLK_TCC/1024 */ +#define TCC_CTRLA_PRESCALER_DIV1 (TCC_CTRLA_PRESCALER_DIV1_Val << TCC_CTRLA_PRESCALER_Pos) +#define TCC_CTRLA_PRESCALER_DIV2 (TCC_CTRLA_PRESCALER_DIV2_Val << TCC_CTRLA_PRESCALER_Pos) +#define TCC_CTRLA_PRESCALER_DIV4 (TCC_CTRLA_PRESCALER_DIV4_Val << TCC_CTRLA_PRESCALER_Pos) +#define TCC_CTRLA_PRESCALER_DIV8 (TCC_CTRLA_PRESCALER_DIV8_Val << TCC_CTRLA_PRESCALER_Pos) +#define TCC_CTRLA_PRESCALER_DIV16 (TCC_CTRLA_PRESCALER_DIV16_Val << TCC_CTRLA_PRESCALER_Pos) +#define TCC_CTRLA_PRESCALER_DIV64 (TCC_CTRLA_PRESCALER_DIV64_Val << TCC_CTRLA_PRESCALER_Pos) +#define TCC_CTRLA_PRESCALER_DIV256 (TCC_CTRLA_PRESCALER_DIV256_Val << TCC_CTRLA_PRESCALER_Pos) +#define TCC_CTRLA_PRESCALER_DIV1024 (TCC_CTRLA_PRESCALER_DIV1024_Val << TCC_CTRLA_PRESCALER_Pos) +#define TCC_CTRLA_RUNSTDBY_Pos 11 /**< \brief (TCC_CTRLA) Run in Standby */ +#define TCC_CTRLA_RUNSTDBY (0x1u << TCC_CTRLA_RUNSTDBY_Pos) +#define TCC_CTRLA_PRESCSYNC_Pos 12 /**< \brief (TCC_CTRLA) Prescaler and Counter Synchronization Selection */ +#define TCC_CTRLA_PRESCSYNC_Msk (0x3u << TCC_CTRLA_PRESCSYNC_Pos) +#define TCC_CTRLA_PRESCSYNC(value) ((TCC_CTRLA_PRESCSYNC_Msk & ((value) << TCC_CTRLA_PRESCSYNC_Pos))) +#define TCC_CTRLA_PRESCSYNC_GCLK_Val 0x0u /**< \brief (TCC_CTRLA) Reload or reset Counter on next GCLK */ +#define TCC_CTRLA_PRESCSYNC_PRESC_Val 0x1u /**< \brief (TCC_CTRLA) Reload or reset Counter on next prescaler clock */ +#define TCC_CTRLA_PRESCSYNC_RESYNC_Val 0x2u /**< \brief (TCC_CTRLA) Reload or reset Counter on next GCLK */ +#define TCC_CTRLA_PRESCSYNC_GCLK (TCC_CTRLA_PRESCSYNC_GCLK_Val << TCC_CTRLA_PRESCSYNC_Pos) +#define TCC_CTRLA_PRESCSYNC_PRESC (TCC_CTRLA_PRESCSYNC_PRESC_Val << TCC_CTRLA_PRESCSYNC_Pos) +#define TCC_CTRLA_PRESCSYNC_RESYNC (TCC_CTRLA_PRESCSYNC_RESYNC_Val << TCC_CTRLA_PRESCSYNC_Pos) +#define TCC_CTRLA_ALOCK_Pos 14 /**< \brief (TCC_CTRLA) Auto Lock */ +#define TCC_CTRLA_ALOCK (0x1u << TCC_CTRLA_ALOCK_Pos) +#define TCC_CTRLA_CPTEN0_Pos 24 /**< \brief (TCC_CTRLA) Capture Channel 0 Enable */ +#define TCC_CTRLA_CPTEN0 (1 << TCC_CTRLA_CPTEN0_Pos) +#define TCC_CTRLA_CPTEN1_Pos 25 /**< \brief (TCC_CTRLA) Capture Channel 1 Enable */ +#define TCC_CTRLA_CPTEN1 (1 << TCC_CTRLA_CPTEN1_Pos) +#define TCC_CTRLA_CPTEN2_Pos 26 /**< \brief (TCC_CTRLA) Capture Channel 2 Enable */ +#define TCC_CTRLA_CPTEN2 (1 << TCC_CTRLA_CPTEN2_Pos) +#define TCC_CTRLA_CPTEN3_Pos 27 /**< \brief (TCC_CTRLA) Capture Channel 3 Enable */ +#define TCC_CTRLA_CPTEN3 (1 << TCC_CTRLA_CPTEN3_Pos) +#define TCC_CTRLA_CPTEN_Pos 24 /**< \brief (TCC_CTRLA) Capture Channel x Enable */ +#define TCC_CTRLA_CPTEN_Msk (0xFu << TCC_CTRLA_CPTEN_Pos) +#define TCC_CTRLA_CPTEN(value) ((TCC_CTRLA_CPTEN_Msk & ((value) << TCC_CTRLA_CPTEN_Pos))) +#define TCC_CTRLA_MASK 0x0F007F63u /**< \brief (TCC_CTRLA) MASK Register */ + +/* -------- TCC_CTRLBCLR : (TCC Offset: 0x04) (R/W 8) Control B Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DIR:1; /*!< bit: 0 Counter Direction */ + uint8_t LUPD:1; /*!< bit: 1 Lock Update */ + uint8_t ONESHOT:1; /*!< bit: 2 One-Shot */ + uint8_t IDXCMD:2; /*!< bit: 3.. 4 Ramp Index Command */ + uint8_t CMD:3; /*!< bit: 5.. 7 TCC Command */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TCC_CTRLBCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_CTRLBCLR_OFFSET 0x04 /**< \brief (TCC_CTRLBCLR offset) Control B Clear */ +#define TCC_CTRLBCLR_RESETVALUE 0x00 /**< \brief (TCC_CTRLBCLR reset_value) Control B Clear */ + +#define TCC_CTRLBCLR_DIR_Pos 0 /**< \brief (TCC_CTRLBCLR) Counter Direction */ +#define TCC_CTRLBCLR_DIR (0x1u << TCC_CTRLBCLR_DIR_Pos) +#define TCC_CTRLBCLR_LUPD_Pos 1 /**< \brief (TCC_CTRLBCLR) Lock Update */ +#define TCC_CTRLBCLR_LUPD (0x1u << TCC_CTRLBCLR_LUPD_Pos) +#define TCC_CTRLBCLR_ONESHOT_Pos 2 /**< \brief (TCC_CTRLBCLR) One-Shot */ +#define TCC_CTRLBCLR_ONESHOT (0x1u << TCC_CTRLBCLR_ONESHOT_Pos) +#define TCC_CTRLBCLR_IDXCMD_Pos 3 /**< \brief (TCC_CTRLBCLR) Ramp Index Command */ +#define TCC_CTRLBCLR_IDXCMD_Msk (0x3u << TCC_CTRLBCLR_IDXCMD_Pos) +#define TCC_CTRLBCLR_IDXCMD(value) ((TCC_CTRLBCLR_IDXCMD_Msk & ((value) << TCC_CTRLBCLR_IDXCMD_Pos))) +#define TCC_CTRLBCLR_IDXCMD_DISABLE_Val 0x0u /**< \brief (TCC_CTRLBCLR) Command disabled: IDX toggles between cycles A and B */ +#define TCC_CTRLBCLR_IDXCMD_SET_Val 0x1u /**< \brief (TCC_CTRLBCLR) Set IDX: cycle B will be forced in the next cycle */ +#define TCC_CTRLBCLR_IDXCMD_CLEAR_Val 0x2u /**< \brief (TCC_CTRLBCLR) Clear IDX: cycle A will be forced in next cycle */ +#define TCC_CTRLBCLR_IDXCMD_HOLD_Val 0x3u /**< \brief (TCC_CTRLBCLR) Hold IDX: the next cycle will be the same as the current cycle. */ +#define TCC_CTRLBCLR_IDXCMD_DISABLE (TCC_CTRLBCLR_IDXCMD_DISABLE_Val << TCC_CTRLBCLR_IDXCMD_Pos) +#define TCC_CTRLBCLR_IDXCMD_SET (TCC_CTRLBCLR_IDXCMD_SET_Val << TCC_CTRLBCLR_IDXCMD_Pos) +#define TCC_CTRLBCLR_IDXCMD_CLEAR (TCC_CTRLBCLR_IDXCMD_CLEAR_Val << TCC_CTRLBCLR_IDXCMD_Pos) +#define TCC_CTRLBCLR_IDXCMD_HOLD (TCC_CTRLBCLR_IDXCMD_HOLD_Val << TCC_CTRLBCLR_IDXCMD_Pos) +#define TCC_CTRLBCLR_CMD_Pos 5 /**< \brief (TCC_CTRLBCLR) TCC Command */ +#define TCC_CTRLBCLR_CMD_Msk (0x7u << TCC_CTRLBCLR_CMD_Pos) +#define TCC_CTRLBCLR_CMD(value) ((TCC_CTRLBCLR_CMD_Msk & ((value) << TCC_CTRLBCLR_CMD_Pos))) +#define TCC_CTRLBCLR_CMD_NONE_Val 0x0u /**< \brief (TCC_CTRLBCLR) No action */ +#define TCC_CTRLBCLR_CMD_RETRIGGER_Val 0x1u /**< \brief (TCC_CTRLBCLR) Clear start, restart or retrigger */ +#define TCC_CTRLBCLR_CMD_STOP_Val 0x2u /**< \brief (TCC_CTRLBCLR) Force stop */ +#define TCC_CTRLBCLR_CMD_UPDATE_Val 0x3u /**< \brief (TCC_CTRLBCLR) Force update of double buffered registers */ +#define TCC_CTRLBCLR_CMD_READSYNC_Val 0x4u /**< \brief (TCC_CTRLBCLR) Force COUNT read synchronization */ +#define TCC_CTRLBCLR_CMD_NONE (TCC_CTRLBCLR_CMD_NONE_Val << TCC_CTRLBCLR_CMD_Pos) +#define TCC_CTRLBCLR_CMD_RETRIGGER (TCC_CTRLBCLR_CMD_RETRIGGER_Val << TCC_CTRLBCLR_CMD_Pos) +#define TCC_CTRLBCLR_CMD_STOP (TCC_CTRLBCLR_CMD_STOP_Val << TCC_CTRLBCLR_CMD_Pos) +#define TCC_CTRLBCLR_CMD_UPDATE (TCC_CTRLBCLR_CMD_UPDATE_Val << TCC_CTRLBCLR_CMD_Pos) +#define TCC_CTRLBCLR_CMD_READSYNC (TCC_CTRLBCLR_CMD_READSYNC_Val << TCC_CTRLBCLR_CMD_Pos) +#define TCC_CTRLBCLR_MASK 0xFFu /**< \brief (TCC_CTRLBCLR) MASK Register */ + +/* -------- TCC_CTRLBSET : (TCC Offset: 0x05) (R/W 8) Control B Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DIR:1; /*!< bit: 0 Counter Direction */ + uint8_t LUPD:1; /*!< bit: 1 Lock update */ + uint8_t ONESHOT:1; /*!< bit: 2 One-Shot */ + uint8_t IDXCMD:2; /*!< bit: 3.. 4 Ramp Index Command */ + uint8_t CMD:3; /*!< bit: 5.. 7 TCC Command */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TCC_CTRLBSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_CTRLBSET_OFFSET 0x05 /**< \brief (TCC_CTRLBSET offset) Control B Set */ +#define TCC_CTRLBSET_RESETVALUE 0x00 /**< \brief (TCC_CTRLBSET reset_value) Control B Set */ + +#define TCC_CTRLBSET_DIR_Pos 0 /**< \brief (TCC_CTRLBSET) Counter Direction */ +#define TCC_CTRLBSET_DIR (0x1u << TCC_CTRLBSET_DIR_Pos) +#define TCC_CTRLBSET_LUPD_Pos 1 /**< \brief (TCC_CTRLBSET) Lock update */ +#define TCC_CTRLBSET_LUPD (0x1u << TCC_CTRLBSET_LUPD_Pos) +#define TCC_CTRLBSET_ONESHOT_Pos 2 /**< \brief (TCC_CTRLBSET) One-Shot */ +#define TCC_CTRLBSET_ONESHOT (0x1u << TCC_CTRLBSET_ONESHOT_Pos) +#define TCC_CTRLBSET_IDXCMD_Pos 3 /**< \brief (TCC_CTRLBSET) Ramp Index Command */ +#define TCC_CTRLBSET_IDXCMD_Msk (0x3u << TCC_CTRLBSET_IDXCMD_Pos) +#define TCC_CTRLBSET_IDXCMD(value) ((TCC_CTRLBSET_IDXCMD_Msk & ((value) << TCC_CTRLBSET_IDXCMD_Pos))) +#define TCC_CTRLBSET_IDXCMD_DISABLE_Val 0x0u /**< \brief (TCC_CTRLBSET) */ +#define TCC_CTRLBSET_IDXCMD_SET_Val 0x1u /**< \brief (TCC_CTRLBSET) */ +#define TCC_CTRLBSET_IDXCMD_CLEAR_Val 0x2u /**< \brief (TCC_CTRLBSET) */ +#define TCC_CTRLBSET_IDXCMD_HOLD_Val 0x3u /**< \brief (TCC_CTRLBSET) */ +#define TCC_CTRLBSET_IDXCMD_DISABLE (TCC_CTRLBSET_IDXCMD_DISABLE_Val << TCC_CTRLBSET_IDXCMD_Pos) +#define TCC_CTRLBSET_IDXCMD_SET (TCC_CTRLBSET_IDXCMD_SET_Val << TCC_CTRLBSET_IDXCMD_Pos) +#define TCC_CTRLBSET_IDXCMD_CLEAR (TCC_CTRLBSET_IDXCMD_CLEAR_Val << TCC_CTRLBSET_IDXCMD_Pos) +#define TCC_CTRLBSET_IDXCMD_HOLD (TCC_CTRLBSET_IDXCMD_HOLD_Val << TCC_CTRLBSET_IDXCMD_Pos) +#define TCC_CTRLBSET_CMD_Pos 5 /**< \brief (TCC_CTRLBSET) TCC Command */ +#define TCC_CTRLBSET_CMD_Msk (0x7u << TCC_CTRLBSET_CMD_Pos) +#define TCC_CTRLBSET_CMD(value) ((TCC_CTRLBSET_CMD_Msk & ((value) << TCC_CTRLBSET_CMD_Pos))) +#define TCC_CTRLBSET_CMD_NONE_Val 0x0u /**< \brief (TCC_CTRLBSET) */ +#define TCC_CTRLBSET_CMD_RETRIGGER_Val 0x1u /**< \brief (TCC_CTRLBSET) */ +#define TCC_CTRLBSET_CMD_STOP_Val 0x2u /**< \brief (TCC_CTRLBSET) */ +#define TCC_CTRLBSET_CMD_UPDATE_Val 0x3u /**< \brief (TCC_CTRLBSET) */ +#define TCC_CTRLBSET_CMD_READSYNC_Val 0x4u /**< \brief (TCC_CTRLBSET) */ +#define TCC_CTRLBSET_CMD_NONE (TCC_CTRLBSET_CMD_NONE_Val << TCC_CTRLBSET_CMD_Pos) +#define TCC_CTRLBSET_CMD_RETRIGGER (TCC_CTRLBSET_CMD_RETRIGGER_Val << TCC_CTRLBSET_CMD_Pos) +#define TCC_CTRLBSET_CMD_STOP (TCC_CTRLBSET_CMD_STOP_Val << TCC_CTRLBSET_CMD_Pos) +#define TCC_CTRLBSET_CMD_UPDATE (TCC_CTRLBSET_CMD_UPDATE_Val << TCC_CTRLBSET_CMD_Pos) +#define TCC_CTRLBSET_CMD_READSYNC (TCC_CTRLBSET_CMD_READSYNC_Val << TCC_CTRLBSET_CMD_Pos) +#define TCC_CTRLBSET_MASK 0xFFu /**< \brief (TCC_CTRLBSET) MASK Register */ + +/* -------- TCC_SYNCBUSY : (TCC Offset: 0x08) (R/ 32) Synchronization Busy -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SWRST:1; /*!< bit: 0 Swrst Busy */ + uint32_t ENABLE:1; /*!< bit: 1 Enable Busy */ + uint32_t CTRLB:1; /*!< bit: 2 Ctrlb Busy */ + uint32_t STATUS:1; /*!< bit: 3 Status Busy */ + uint32_t COUNT:1; /*!< bit: 4 Count Busy */ + uint32_t PATT:1; /*!< bit: 5 Pattern Busy */ + uint32_t WAVE:1; /*!< bit: 6 Wave Busy */ + uint32_t PER:1; /*!< bit: 7 Period busy */ + uint32_t CC0:1; /*!< bit: 8 Compare Channel Buffer 0 Busy */ + uint32_t CC1:1; /*!< bit: 9 Compare Channel Buffer 1 Busy */ + uint32_t CC2:1; /*!< bit: 10 Compare Channel Buffer 2 Busy */ + uint32_t CC3:1; /*!< bit: 11 Compare Channel Buffer 3 Busy */ + uint32_t :4; /*!< bit: 12..15 Reserved */ + uint32_t PATTB:1; /*!< bit: 16 Pattern Buffer Busy */ + uint32_t WAVEB:1; /*!< bit: 17 Wave Buffer Busy */ + uint32_t PERB:1; /*!< bit: 18 Period Buffer Busy */ + uint32_t CCB0:1; /*!< bit: 19 Compare Channel Buffer 0 Busy */ + uint32_t CCB1:1; /*!< bit: 20 Compare Channel Buffer 1 Busy */ + uint32_t CCB2:1; /*!< bit: 21 Compare Channel Buffer 2 Busy */ + uint32_t CCB3:1; /*!< bit: 22 Compare Channel Buffer 3 Busy */ + uint32_t :9; /*!< bit: 23..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :8; /*!< bit: 0.. 7 Reserved */ + uint32_t CC:4; /*!< bit: 8..11 Compare Channel Buffer x Busy */ + uint32_t :7; /*!< bit: 12..18 Reserved */ + uint32_t CCB:4; /*!< bit: 19..22 Compare Channel Buffer x Busy */ + uint32_t :9; /*!< bit: 23..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_SYNCBUSY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_SYNCBUSY_OFFSET 0x08 /**< \brief (TCC_SYNCBUSY offset) Synchronization Busy */ +#define TCC_SYNCBUSY_RESETVALUE 0x00000000 /**< \brief (TCC_SYNCBUSY reset_value) Synchronization Busy */ + +#define TCC_SYNCBUSY_SWRST_Pos 0 /**< \brief (TCC_SYNCBUSY) Swrst Busy */ +#define TCC_SYNCBUSY_SWRST (0x1u << TCC_SYNCBUSY_SWRST_Pos) +#define TCC_SYNCBUSY_ENABLE_Pos 1 /**< \brief (TCC_SYNCBUSY) Enable Busy */ +#define TCC_SYNCBUSY_ENABLE (0x1u << TCC_SYNCBUSY_ENABLE_Pos) +#define TCC_SYNCBUSY_CTRLB_Pos 2 /**< \brief (TCC_SYNCBUSY) Ctrlb Busy */ +#define TCC_SYNCBUSY_CTRLB (0x1u << TCC_SYNCBUSY_CTRLB_Pos) +#define TCC_SYNCBUSY_STATUS_Pos 3 /**< \brief (TCC_SYNCBUSY) Status Busy */ +#define TCC_SYNCBUSY_STATUS (0x1u << TCC_SYNCBUSY_STATUS_Pos) +#define TCC_SYNCBUSY_COUNT_Pos 4 /**< \brief (TCC_SYNCBUSY) Count Busy */ +#define TCC_SYNCBUSY_COUNT (0x1u << TCC_SYNCBUSY_COUNT_Pos) +#define TCC_SYNCBUSY_PATT_Pos 5 /**< \brief (TCC_SYNCBUSY) Pattern Busy */ +#define TCC_SYNCBUSY_PATT (0x1u << TCC_SYNCBUSY_PATT_Pos) +#define TCC_SYNCBUSY_WAVE_Pos 6 /**< \brief (TCC_SYNCBUSY) Wave Busy */ +#define TCC_SYNCBUSY_WAVE (0x1u << TCC_SYNCBUSY_WAVE_Pos) +#define TCC_SYNCBUSY_PER_Pos 7 /**< \brief (TCC_SYNCBUSY) Period busy */ +#define TCC_SYNCBUSY_PER (0x1u << TCC_SYNCBUSY_PER_Pos) +#define TCC_SYNCBUSY_CC0_Pos 8 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer 0 Busy */ +#define TCC_SYNCBUSY_CC0 (1 << TCC_SYNCBUSY_CC0_Pos) +#define TCC_SYNCBUSY_CC1_Pos 9 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer 1 Busy */ +#define TCC_SYNCBUSY_CC1 (1 << TCC_SYNCBUSY_CC1_Pos) +#define TCC_SYNCBUSY_CC2_Pos 10 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer 2 Busy */ +#define TCC_SYNCBUSY_CC2 (1 << TCC_SYNCBUSY_CC2_Pos) +#define TCC_SYNCBUSY_CC3_Pos 11 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer 3 Busy */ +#define TCC_SYNCBUSY_CC3 (1 << TCC_SYNCBUSY_CC3_Pos) +#define TCC_SYNCBUSY_CC_Pos 8 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer x Busy */ +#define TCC_SYNCBUSY_CC_Msk (0xFu << TCC_SYNCBUSY_CC_Pos) +#define TCC_SYNCBUSY_CC(value) ((TCC_SYNCBUSY_CC_Msk & ((value) << TCC_SYNCBUSY_CC_Pos))) +#define TCC_SYNCBUSY_PATTB_Pos 16 /**< \brief (TCC_SYNCBUSY) Pattern Buffer Busy */ +#define TCC_SYNCBUSY_PATTB (0x1u << TCC_SYNCBUSY_PATTB_Pos) +#define TCC_SYNCBUSY_WAVEB_Pos 17 /**< \brief (TCC_SYNCBUSY) Wave Buffer Busy */ +#define TCC_SYNCBUSY_WAVEB (0x1u << TCC_SYNCBUSY_WAVEB_Pos) +#define TCC_SYNCBUSY_PERB_Pos 18 /**< \brief (TCC_SYNCBUSY) Period Buffer Busy */ +#define TCC_SYNCBUSY_PERB (0x1u << TCC_SYNCBUSY_PERB_Pos) +#define TCC_SYNCBUSY_CCB0_Pos 19 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer 0 Busy */ +#define TCC_SYNCBUSY_CCB0 (1 << TCC_SYNCBUSY_CCB0_Pos) +#define TCC_SYNCBUSY_CCB1_Pos 20 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer 1 Busy */ +#define TCC_SYNCBUSY_CCB1 (1 << TCC_SYNCBUSY_CCB1_Pos) +#define TCC_SYNCBUSY_CCB2_Pos 21 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer 2 Busy */ +#define TCC_SYNCBUSY_CCB2 (1 << TCC_SYNCBUSY_CCB2_Pos) +#define TCC_SYNCBUSY_CCB3_Pos 22 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer 3 Busy */ +#define TCC_SYNCBUSY_CCB3 (1 << TCC_SYNCBUSY_CCB3_Pos) +#define TCC_SYNCBUSY_CCB_Pos 19 /**< \brief (TCC_SYNCBUSY) Compare Channel Buffer x Busy */ +#define TCC_SYNCBUSY_CCB_Msk (0xFu << TCC_SYNCBUSY_CCB_Pos) +#define TCC_SYNCBUSY_CCB(value) ((TCC_SYNCBUSY_CCB_Msk & ((value) << TCC_SYNCBUSY_CCB_Pos))) +#define TCC_SYNCBUSY_MASK 0x007F0FFFu /**< \brief (TCC_SYNCBUSY) MASK Register */ + +/* -------- TCC_FCTRLA : (TCC Offset: 0x0C) (R/W 32) Recoverable FaultA Configuration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SRC:2; /*!< bit: 0.. 1 FaultA Source */ + uint32_t :1; /*!< bit: 2 Reserved */ + uint32_t KEEP:1; /*!< bit: 3 FaultA Keeper */ + uint32_t QUAL:1; /*!< bit: 4 FaultA Qualification */ + uint32_t BLANK:2; /*!< bit: 5.. 6 FaultA Blanking Mode */ + uint32_t RESTART:1; /*!< bit: 7 FaultA Restart */ + uint32_t HALT:2; /*!< bit: 8.. 9 FaultA Halt Mode */ + uint32_t CHSEL:2; /*!< bit: 10..11 FaultA Capture Channel */ + uint32_t CAPTURE:3; /*!< bit: 12..14 FaultA Capture Action */ + uint32_t :1; /*!< bit: 15 Reserved */ + uint32_t BLANKVAL:8; /*!< bit: 16..23 FaultA Blanking Time */ + uint32_t FILTERVAL:4; /*!< bit: 24..27 FaultA Filter Value */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_FCTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_FCTRLA_OFFSET 0x0C /**< \brief (TCC_FCTRLA offset) Recoverable FaultA Configuration */ +#define TCC_FCTRLA_RESETVALUE 0x00000000 /**< \brief (TCC_FCTRLA reset_value) Recoverable FaultA Configuration */ + +#define TCC_FCTRLA_SRC_Pos 0 /**< \brief (TCC_FCTRLA) FaultA Source */ +#define TCC_FCTRLA_SRC_Msk (0x3u << TCC_FCTRLA_SRC_Pos) +#define TCC_FCTRLA_SRC(value) ((TCC_FCTRLA_SRC_Msk & ((value) << TCC_FCTRLA_SRC_Pos))) +#define TCC_FCTRLA_SRC_DISABLE_Val 0x0u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_SRC_ENABLE_Val 0x1u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_SRC_INVERT_Val 0x2u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_SRC_ALTFAULT_Val 0x3u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_SRC_DISABLE (TCC_FCTRLA_SRC_DISABLE_Val << TCC_FCTRLA_SRC_Pos) +#define TCC_FCTRLA_SRC_ENABLE (TCC_FCTRLA_SRC_ENABLE_Val << TCC_FCTRLA_SRC_Pos) +#define TCC_FCTRLA_SRC_INVERT (TCC_FCTRLA_SRC_INVERT_Val << TCC_FCTRLA_SRC_Pos) +#define TCC_FCTRLA_SRC_ALTFAULT (TCC_FCTRLA_SRC_ALTFAULT_Val << TCC_FCTRLA_SRC_Pos) +#define TCC_FCTRLA_KEEP_Pos 3 /**< \brief (TCC_FCTRLA) FaultA Keeper */ +#define TCC_FCTRLA_KEEP (0x1u << TCC_FCTRLA_KEEP_Pos) +#define TCC_FCTRLA_QUAL_Pos 4 /**< \brief (TCC_FCTRLA) FaultA Qualification */ +#define TCC_FCTRLA_QUAL (0x1u << TCC_FCTRLA_QUAL_Pos) +#define TCC_FCTRLA_BLANK_Pos 5 /**< \brief (TCC_FCTRLA) FaultA Blanking Mode */ +#define TCC_FCTRLA_BLANK_Msk (0x3u << TCC_FCTRLA_BLANK_Pos) +#define TCC_FCTRLA_BLANK(value) ((TCC_FCTRLA_BLANK_Msk & ((value) << TCC_FCTRLA_BLANK_Pos))) +#define TCC_FCTRLA_BLANK_DISABLE_Val 0x0u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_BLANK_RISE_Val 0x1u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_BLANK_FALL_Val 0x2u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_BLANK_BOTH_Val 0x3u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_BLANK_DISABLE (TCC_FCTRLA_BLANK_DISABLE_Val << TCC_FCTRLA_BLANK_Pos) +#define TCC_FCTRLA_BLANK_RISE (TCC_FCTRLA_BLANK_RISE_Val << TCC_FCTRLA_BLANK_Pos) +#define TCC_FCTRLA_BLANK_FALL (TCC_FCTRLA_BLANK_FALL_Val << TCC_FCTRLA_BLANK_Pos) +#define TCC_FCTRLA_BLANK_BOTH (TCC_FCTRLA_BLANK_BOTH_Val << TCC_FCTRLA_BLANK_Pos) +#define TCC_FCTRLA_RESTART_Pos 7 /**< \brief (TCC_FCTRLA) FaultA Restart */ +#define TCC_FCTRLA_RESTART (0x1u << TCC_FCTRLA_RESTART_Pos) +#define TCC_FCTRLA_HALT_Pos 8 /**< \brief (TCC_FCTRLA) FaultA Halt Mode */ +#define TCC_FCTRLA_HALT_Msk (0x3u << TCC_FCTRLA_HALT_Pos) +#define TCC_FCTRLA_HALT(value) ((TCC_FCTRLA_HALT_Msk & ((value) << TCC_FCTRLA_HALT_Pos))) +#define TCC_FCTRLA_HALT_DISABLE_Val 0x0u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_HALT_HW_Val 0x1u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_HALT_SW_Val 0x2u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_HALT_NR_Val 0x3u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_HALT_DISABLE (TCC_FCTRLA_HALT_DISABLE_Val << TCC_FCTRLA_HALT_Pos) +#define TCC_FCTRLA_HALT_HW (TCC_FCTRLA_HALT_HW_Val << TCC_FCTRLA_HALT_Pos) +#define TCC_FCTRLA_HALT_SW (TCC_FCTRLA_HALT_SW_Val << TCC_FCTRLA_HALT_Pos) +#define TCC_FCTRLA_HALT_NR (TCC_FCTRLA_HALT_NR_Val << TCC_FCTRLA_HALT_Pos) +#define TCC_FCTRLA_CHSEL_Pos 10 /**< \brief (TCC_FCTRLA) FaultA Capture Channel */ +#define TCC_FCTRLA_CHSEL_Msk (0x3u << TCC_FCTRLA_CHSEL_Pos) +#define TCC_FCTRLA_CHSEL(value) ((TCC_FCTRLA_CHSEL_Msk & ((value) << TCC_FCTRLA_CHSEL_Pos))) +#define TCC_FCTRLA_CHSEL_CC0_Val 0x0u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CHSEL_CC1_Val 0x1u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CHSEL_CC2_Val 0x2u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CHSEL_CC3_Val 0x3u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CHSEL_CC0 (TCC_FCTRLA_CHSEL_CC0_Val << TCC_FCTRLA_CHSEL_Pos) +#define TCC_FCTRLA_CHSEL_CC1 (TCC_FCTRLA_CHSEL_CC1_Val << TCC_FCTRLA_CHSEL_Pos) +#define TCC_FCTRLA_CHSEL_CC2 (TCC_FCTRLA_CHSEL_CC2_Val << TCC_FCTRLA_CHSEL_Pos) +#define TCC_FCTRLA_CHSEL_CC3 (TCC_FCTRLA_CHSEL_CC3_Val << TCC_FCTRLA_CHSEL_Pos) +#define TCC_FCTRLA_CAPTURE_Pos 12 /**< \brief (TCC_FCTRLA) FaultA Capture Action */ +#define TCC_FCTRLA_CAPTURE_Msk (0x7u << TCC_FCTRLA_CAPTURE_Pos) +#define TCC_FCTRLA_CAPTURE(value) ((TCC_FCTRLA_CAPTURE_Msk & ((value) << TCC_FCTRLA_CAPTURE_Pos))) +#define TCC_FCTRLA_CAPTURE_DISABLE_Val 0x0u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CAPTURE_CAPT_Val 0x1u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CAPTURE_CAPTMIN_Val 0x2u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CAPTURE_CAPTMAX_Val 0x3u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CAPTURE_LOCMIN_Val 0x4u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CAPTURE_LOCMAX_Val 0x5u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CAPTURE_DERIV0_Val 0x6u /**< \brief (TCC_FCTRLA) */ +#define TCC_FCTRLA_CAPTURE_DISABLE (TCC_FCTRLA_CAPTURE_DISABLE_Val << TCC_FCTRLA_CAPTURE_Pos) +#define TCC_FCTRLA_CAPTURE_CAPT (TCC_FCTRLA_CAPTURE_CAPT_Val << TCC_FCTRLA_CAPTURE_Pos) +#define TCC_FCTRLA_CAPTURE_CAPTMIN (TCC_FCTRLA_CAPTURE_CAPTMIN_Val << TCC_FCTRLA_CAPTURE_Pos) +#define TCC_FCTRLA_CAPTURE_CAPTMAX (TCC_FCTRLA_CAPTURE_CAPTMAX_Val << TCC_FCTRLA_CAPTURE_Pos) +#define TCC_FCTRLA_CAPTURE_LOCMIN (TCC_FCTRLA_CAPTURE_LOCMIN_Val << TCC_FCTRLA_CAPTURE_Pos) +#define TCC_FCTRLA_CAPTURE_LOCMAX (TCC_FCTRLA_CAPTURE_LOCMAX_Val << TCC_FCTRLA_CAPTURE_Pos) +#define TCC_FCTRLA_CAPTURE_DERIV0 (TCC_FCTRLA_CAPTURE_DERIV0_Val << TCC_FCTRLA_CAPTURE_Pos) +#define TCC_FCTRLA_BLANKVAL_Pos 16 /**< \brief (TCC_FCTRLA) FaultA Blanking Time */ +#define TCC_FCTRLA_BLANKVAL_Msk (0xFFu << TCC_FCTRLA_BLANKVAL_Pos) +#define TCC_FCTRLA_BLANKVAL(value) ((TCC_FCTRLA_BLANKVAL_Msk & ((value) << TCC_FCTRLA_BLANKVAL_Pos))) +#define TCC_FCTRLA_FILTERVAL_Pos 24 /**< \brief (TCC_FCTRLA) FaultA Filter Value */ +#define TCC_FCTRLA_FILTERVAL_Msk (0xFu << TCC_FCTRLA_FILTERVAL_Pos) +#define TCC_FCTRLA_FILTERVAL(value) ((TCC_FCTRLA_FILTERVAL_Msk & ((value) << TCC_FCTRLA_FILTERVAL_Pos))) +#define TCC_FCTRLA_MASK 0x0FFF7FFBu /**< \brief (TCC_FCTRLA) MASK Register */ + +/* -------- TCC_FCTRLB : (TCC Offset: 0x10) (R/W 32) Recoverable FaultB Configuration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t SRC:2; /*!< bit: 0.. 1 FaultB Source */ + uint32_t :1; /*!< bit: 2 Reserved */ + uint32_t KEEP:1; /*!< bit: 3 FaultB Keeper */ + uint32_t QUAL:1; /*!< bit: 4 FaultB Qualification */ + uint32_t BLANK:2; /*!< bit: 5.. 6 FaultB Blanking Mode */ + uint32_t RESTART:1; /*!< bit: 7 FaultB Restart */ + uint32_t HALT:2; /*!< bit: 8.. 9 FaultB Halt Mode */ + uint32_t CHSEL:2; /*!< bit: 10..11 FaultB Capture Channel */ + uint32_t CAPTURE:3; /*!< bit: 12..14 FaultB Capture Action */ + uint32_t :1; /*!< bit: 15 Reserved */ + uint32_t BLANKVAL:8; /*!< bit: 16..23 FaultB Blanking Time */ + uint32_t FILTERVAL:4; /*!< bit: 24..27 FaultB Filter Value */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_FCTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_FCTRLB_OFFSET 0x10 /**< \brief (TCC_FCTRLB offset) Recoverable FaultB Configuration */ +#define TCC_FCTRLB_RESETVALUE 0x00000000 /**< \brief (TCC_FCTRLB reset_value) Recoverable FaultB Configuration */ + +#define TCC_FCTRLB_SRC_Pos 0 /**< \brief (TCC_FCTRLB) FaultB Source */ +#define TCC_FCTRLB_SRC_Msk (0x3u << TCC_FCTRLB_SRC_Pos) +#define TCC_FCTRLB_SRC(value) ((TCC_FCTRLB_SRC_Msk & ((value) << TCC_FCTRLB_SRC_Pos))) +#define TCC_FCTRLB_SRC_DISABLE_Val 0x0u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_SRC_ENABLE_Val 0x1u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_SRC_INVERT_Val 0x2u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_SRC_ALTFAULT_Val 0x3u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_SRC_DISABLE (TCC_FCTRLB_SRC_DISABLE_Val << TCC_FCTRLB_SRC_Pos) +#define TCC_FCTRLB_SRC_ENABLE (TCC_FCTRLB_SRC_ENABLE_Val << TCC_FCTRLB_SRC_Pos) +#define TCC_FCTRLB_SRC_INVERT (TCC_FCTRLB_SRC_INVERT_Val << TCC_FCTRLB_SRC_Pos) +#define TCC_FCTRLB_SRC_ALTFAULT (TCC_FCTRLB_SRC_ALTFAULT_Val << TCC_FCTRLB_SRC_Pos) +#define TCC_FCTRLB_KEEP_Pos 3 /**< \brief (TCC_FCTRLB) FaultB Keeper */ +#define TCC_FCTRLB_KEEP (0x1u << TCC_FCTRLB_KEEP_Pos) +#define TCC_FCTRLB_QUAL_Pos 4 /**< \brief (TCC_FCTRLB) FaultB Qualification */ +#define TCC_FCTRLB_QUAL (0x1u << TCC_FCTRLB_QUAL_Pos) +#define TCC_FCTRLB_BLANK_Pos 5 /**< \brief (TCC_FCTRLB) FaultB Blanking Mode */ +#define TCC_FCTRLB_BLANK_Msk (0x3u << TCC_FCTRLB_BLANK_Pos) +#define TCC_FCTRLB_BLANK(value) ((TCC_FCTRLB_BLANK_Msk & ((value) << TCC_FCTRLB_BLANK_Pos))) +#define TCC_FCTRLB_BLANK_DISABLE_Val 0x0u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_BLANK_RISE_Val 0x1u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_BLANK_FALL_Val 0x2u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_BLANK_BOTH_Val 0x3u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_BLANK_DISABLE (TCC_FCTRLB_BLANK_DISABLE_Val << TCC_FCTRLB_BLANK_Pos) +#define TCC_FCTRLB_BLANK_RISE (TCC_FCTRLB_BLANK_RISE_Val << TCC_FCTRLB_BLANK_Pos) +#define TCC_FCTRLB_BLANK_FALL (TCC_FCTRLB_BLANK_FALL_Val << TCC_FCTRLB_BLANK_Pos) +#define TCC_FCTRLB_BLANK_BOTH (TCC_FCTRLB_BLANK_BOTH_Val << TCC_FCTRLB_BLANK_Pos) +#define TCC_FCTRLB_RESTART_Pos 7 /**< \brief (TCC_FCTRLB) FaultB Restart */ +#define TCC_FCTRLB_RESTART (0x1u << TCC_FCTRLB_RESTART_Pos) +#define TCC_FCTRLB_HALT_Pos 8 /**< \brief (TCC_FCTRLB) FaultB Halt Mode */ +#define TCC_FCTRLB_HALT_Msk (0x3u << TCC_FCTRLB_HALT_Pos) +#define TCC_FCTRLB_HALT(value) ((TCC_FCTRLB_HALT_Msk & ((value) << TCC_FCTRLB_HALT_Pos))) +#define TCC_FCTRLB_HALT_DISABLE_Val 0x0u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_HALT_HW_Val 0x1u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_HALT_SW_Val 0x2u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_HALT_NR_Val 0x3u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_HALT_DISABLE (TCC_FCTRLB_HALT_DISABLE_Val << TCC_FCTRLB_HALT_Pos) +#define TCC_FCTRLB_HALT_HW (TCC_FCTRLB_HALT_HW_Val << TCC_FCTRLB_HALT_Pos) +#define TCC_FCTRLB_HALT_SW (TCC_FCTRLB_HALT_SW_Val << TCC_FCTRLB_HALT_Pos) +#define TCC_FCTRLB_HALT_NR (TCC_FCTRLB_HALT_NR_Val << TCC_FCTRLB_HALT_Pos) +#define TCC_FCTRLB_CHSEL_Pos 10 /**< \brief (TCC_FCTRLB) FaultB Capture Channel */ +#define TCC_FCTRLB_CHSEL_Msk (0x3u << TCC_FCTRLB_CHSEL_Pos) +#define TCC_FCTRLB_CHSEL(value) ((TCC_FCTRLB_CHSEL_Msk & ((value) << TCC_FCTRLB_CHSEL_Pos))) +#define TCC_FCTRLB_CHSEL_CC0_Val 0x0u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CHSEL_CC1_Val 0x1u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CHSEL_CC2_Val 0x2u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CHSEL_CC3_Val 0x3u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CHSEL_CC0 (TCC_FCTRLB_CHSEL_CC0_Val << TCC_FCTRLB_CHSEL_Pos) +#define TCC_FCTRLB_CHSEL_CC1 (TCC_FCTRLB_CHSEL_CC1_Val << TCC_FCTRLB_CHSEL_Pos) +#define TCC_FCTRLB_CHSEL_CC2 (TCC_FCTRLB_CHSEL_CC2_Val << TCC_FCTRLB_CHSEL_Pos) +#define TCC_FCTRLB_CHSEL_CC3 (TCC_FCTRLB_CHSEL_CC3_Val << TCC_FCTRLB_CHSEL_Pos) +#define TCC_FCTRLB_CAPTURE_Pos 12 /**< \brief (TCC_FCTRLB) FaultB Capture Action */ +#define TCC_FCTRLB_CAPTURE_Msk (0x7u << TCC_FCTRLB_CAPTURE_Pos) +#define TCC_FCTRLB_CAPTURE(value) ((TCC_FCTRLB_CAPTURE_Msk & ((value) << TCC_FCTRLB_CAPTURE_Pos))) +#define TCC_FCTRLB_CAPTURE_DISABLE_Val 0x0u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CAPTURE_CAPT_Val 0x1u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CAPTURE_CAPTMIN_Val 0x2u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CAPTURE_CAPTMAX_Val 0x3u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CAPTURE_LOCMIN_Val 0x4u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CAPTURE_LOCMAX_Val 0x5u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CAPTURE_DERIV0_Val 0x6u /**< \brief (TCC_FCTRLB) */ +#define TCC_FCTRLB_CAPTURE_DISABLE (TCC_FCTRLB_CAPTURE_DISABLE_Val << TCC_FCTRLB_CAPTURE_Pos) +#define TCC_FCTRLB_CAPTURE_CAPT (TCC_FCTRLB_CAPTURE_CAPT_Val << TCC_FCTRLB_CAPTURE_Pos) +#define TCC_FCTRLB_CAPTURE_CAPTMIN (TCC_FCTRLB_CAPTURE_CAPTMIN_Val << TCC_FCTRLB_CAPTURE_Pos) +#define TCC_FCTRLB_CAPTURE_CAPTMAX (TCC_FCTRLB_CAPTURE_CAPTMAX_Val << TCC_FCTRLB_CAPTURE_Pos) +#define TCC_FCTRLB_CAPTURE_LOCMIN (TCC_FCTRLB_CAPTURE_LOCMIN_Val << TCC_FCTRLB_CAPTURE_Pos) +#define TCC_FCTRLB_CAPTURE_LOCMAX (TCC_FCTRLB_CAPTURE_LOCMAX_Val << TCC_FCTRLB_CAPTURE_Pos) +#define TCC_FCTRLB_CAPTURE_DERIV0 (TCC_FCTRLB_CAPTURE_DERIV0_Val << TCC_FCTRLB_CAPTURE_Pos) +#define TCC_FCTRLB_BLANKVAL_Pos 16 /**< \brief (TCC_FCTRLB) FaultB Blanking Time */ +#define TCC_FCTRLB_BLANKVAL_Msk (0xFFu << TCC_FCTRLB_BLANKVAL_Pos) +#define TCC_FCTRLB_BLANKVAL(value) ((TCC_FCTRLB_BLANKVAL_Msk & ((value) << TCC_FCTRLB_BLANKVAL_Pos))) +#define TCC_FCTRLB_FILTERVAL_Pos 24 /**< \brief (TCC_FCTRLB) FaultB Filter Value */ +#define TCC_FCTRLB_FILTERVAL_Msk (0xFu << TCC_FCTRLB_FILTERVAL_Pos) +#define TCC_FCTRLB_FILTERVAL(value) ((TCC_FCTRLB_FILTERVAL_Msk & ((value) << TCC_FCTRLB_FILTERVAL_Pos))) +#define TCC_FCTRLB_MASK 0x0FFF7FFBu /**< \brief (TCC_FCTRLB) MASK Register */ + +/* -------- TCC_WEXCTRL : (TCC Offset: 0x14) (R/W 32) Waveform Extension Configuration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OTMX:2; /*!< bit: 0.. 1 Output Matrix */ + uint32_t :6; /*!< bit: 2.. 7 Reserved */ + uint32_t DTIEN0:1; /*!< bit: 8 Dead-time Insertion Generator 0 Enable */ + uint32_t DTIEN1:1; /*!< bit: 9 Dead-time Insertion Generator 1 Enable */ + uint32_t DTIEN2:1; /*!< bit: 10 Dead-time Insertion Generator 2 Enable */ + uint32_t DTIEN3:1; /*!< bit: 11 Dead-time Insertion Generator 3 Enable */ + uint32_t :4; /*!< bit: 12..15 Reserved */ + uint32_t DTLS:8; /*!< bit: 16..23 Dead-time Low Side Outputs Value */ + uint32_t DTHS:8; /*!< bit: 24..31 Dead-time High Side Outputs Value */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :8; /*!< bit: 0.. 7 Reserved */ + uint32_t DTIEN:4; /*!< bit: 8..11 Dead-time Insertion Generator x Enable */ + uint32_t :20; /*!< bit: 12..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_WEXCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_WEXCTRL_OFFSET 0x14 /**< \brief (TCC_WEXCTRL offset) Waveform Extension Configuration */ +#define TCC_WEXCTRL_RESETVALUE 0x00000000 /**< \brief (TCC_WEXCTRL reset_value) Waveform Extension Configuration */ + +#define TCC_WEXCTRL_OTMX_Pos 0 /**< \brief (TCC_WEXCTRL) Output Matrix */ +#define TCC_WEXCTRL_OTMX_Msk (0x3u << TCC_WEXCTRL_OTMX_Pos) +#define TCC_WEXCTRL_OTMX(value) ((TCC_WEXCTRL_OTMX_Msk & ((value) << TCC_WEXCTRL_OTMX_Pos))) +#define TCC_WEXCTRL_DTIEN0_Pos 8 /**< \brief (TCC_WEXCTRL) Dead-time Insertion Generator 0 Enable */ +#define TCC_WEXCTRL_DTIEN0 (1 << TCC_WEXCTRL_DTIEN0_Pos) +#define TCC_WEXCTRL_DTIEN1_Pos 9 /**< \brief (TCC_WEXCTRL) Dead-time Insertion Generator 1 Enable */ +#define TCC_WEXCTRL_DTIEN1 (1 << TCC_WEXCTRL_DTIEN1_Pos) +#define TCC_WEXCTRL_DTIEN2_Pos 10 /**< \brief (TCC_WEXCTRL) Dead-time Insertion Generator 2 Enable */ +#define TCC_WEXCTRL_DTIEN2 (1 << TCC_WEXCTRL_DTIEN2_Pos) +#define TCC_WEXCTRL_DTIEN3_Pos 11 /**< \brief (TCC_WEXCTRL) Dead-time Insertion Generator 3 Enable */ +#define TCC_WEXCTRL_DTIEN3 (1 << TCC_WEXCTRL_DTIEN3_Pos) +#define TCC_WEXCTRL_DTIEN_Pos 8 /**< \brief (TCC_WEXCTRL) Dead-time Insertion Generator x Enable */ +#define TCC_WEXCTRL_DTIEN_Msk (0xFu << TCC_WEXCTRL_DTIEN_Pos) +#define TCC_WEXCTRL_DTIEN(value) ((TCC_WEXCTRL_DTIEN_Msk & ((value) << TCC_WEXCTRL_DTIEN_Pos))) +#define TCC_WEXCTRL_DTLS_Pos 16 /**< \brief (TCC_WEXCTRL) Dead-time Low Side Outputs Value */ +#define TCC_WEXCTRL_DTLS_Msk (0xFFu << TCC_WEXCTRL_DTLS_Pos) +#define TCC_WEXCTRL_DTLS(value) ((TCC_WEXCTRL_DTLS_Msk & ((value) << TCC_WEXCTRL_DTLS_Pos))) +#define TCC_WEXCTRL_DTHS_Pos 24 /**< \brief (TCC_WEXCTRL) Dead-time High Side Outputs Value */ +#define TCC_WEXCTRL_DTHS_Msk (0xFFu << TCC_WEXCTRL_DTHS_Pos) +#define TCC_WEXCTRL_DTHS(value) ((TCC_WEXCTRL_DTHS_Msk & ((value) << TCC_WEXCTRL_DTHS_Pos))) +#define TCC_WEXCTRL_MASK 0xFFFF0F03u /**< \brief (TCC_WEXCTRL) MASK Register */ + +/* -------- TCC_DRVCTRL : (TCC Offset: 0x18) (R/W 32) Driver Configuration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t NRE0:1; /*!< bit: 0 Non-Recoverable State 0 Output Enable */ + uint32_t NRE1:1; /*!< bit: 1 Non-Recoverable State 1 Output Enable */ + uint32_t NRE2:1; /*!< bit: 2 Non-Recoverable State 2 Output Enable */ + uint32_t NRE3:1; /*!< bit: 3 Non-Recoverable State 3 Output Enable */ + uint32_t NRE4:1; /*!< bit: 4 Non-Recoverable State 4 Output Enable */ + uint32_t NRE5:1; /*!< bit: 5 Non-Recoverable State 5 Output Enable */ + uint32_t NRE6:1; /*!< bit: 6 Non-Recoverable State 6 Output Enable */ + uint32_t NRE7:1; /*!< bit: 7 Non-Recoverable State 7 Output Enable */ + uint32_t NRV0:1; /*!< bit: 8 Non-Recoverable State 0 Output Value */ + uint32_t NRV1:1; /*!< bit: 9 Non-Recoverable State 1 Output Value */ + uint32_t NRV2:1; /*!< bit: 10 Non-Recoverable State 2 Output Value */ + uint32_t NRV3:1; /*!< bit: 11 Non-Recoverable State 3 Output Value */ + uint32_t NRV4:1; /*!< bit: 12 Non-Recoverable State 4 Output Value */ + uint32_t NRV5:1; /*!< bit: 13 Non-Recoverable State 5 Output Value */ + uint32_t NRV6:1; /*!< bit: 14 Non-Recoverable State 6 Output Value */ + uint32_t NRV7:1; /*!< bit: 15 Non-Recoverable State 7 Output Value */ + uint32_t INVEN0:1; /*!< bit: 16 Output Waveform 0 Inversion */ + uint32_t INVEN1:1; /*!< bit: 17 Output Waveform 1 Inversion */ + uint32_t INVEN2:1; /*!< bit: 18 Output Waveform 2 Inversion */ + uint32_t INVEN3:1; /*!< bit: 19 Output Waveform 3 Inversion */ + uint32_t INVEN4:1; /*!< bit: 20 Output Waveform 4 Inversion */ + uint32_t INVEN5:1; /*!< bit: 21 Output Waveform 5 Inversion */ + uint32_t INVEN6:1; /*!< bit: 22 Output Waveform 6 Inversion */ + uint32_t INVEN7:1; /*!< bit: 23 Output Waveform 7 Inversion */ + uint32_t FILTERVAL0:4; /*!< bit: 24..27 Non-Recoverable Fault Input 0 Filter Value */ + uint32_t FILTERVAL1:4; /*!< bit: 28..31 Non-Recoverable Fault Input 1 Filter Value */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t NRE:8; /*!< bit: 0.. 7 Non-Recoverable State x Output Enable */ + uint32_t NRV:8; /*!< bit: 8..15 Non-Recoverable State x Output Value */ + uint32_t INVEN:8; /*!< bit: 16..23 Output Waveform x Inversion */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_DRVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_DRVCTRL_OFFSET 0x18 /**< \brief (TCC_DRVCTRL offset) Driver Configuration */ +#define TCC_DRVCTRL_RESETVALUE 0x00000000 /**< \brief (TCC_DRVCTRL reset_value) Driver Configuration */ + +#define TCC_DRVCTRL_NRE0_Pos 0 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 0 Output Enable */ +#define TCC_DRVCTRL_NRE0 (1 << TCC_DRVCTRL_NRE0_Pos) +#define TCC_DRVCTRL_NRE1_Pos 1 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 1 Output Enable */ +#define TCC_DRVCTRL_NRE1 (1 << TCC_DRVCTRL_NRE1_Pos) +#define TCC_DRVCTRL_NRE2_Pos 2 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 2 Output Enable */ +#define TCC_DRVCTRL_NRE2 (1 << TCC_DRVCTRL_NRE2_Pos) +#define TCC_DRVCTRL_NRE3_Pos 3 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 3 Output Enable */ +#define TCC_DRVCTRL_NRE3 (1 << TCC_DRVCTRL_NRE3_Pos) +#define TCC_DRVCTRL_NRE4_Pos 4 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 4 Output Enable */ +#define TCC_DRVCTRL_NRE4 (1 << TCC_DRVCTRL_NRE4_Pos) +#define TCC_DRVCTRL_NRE5_Pos 5 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 5 Output Enable */ +#define TCC_DRVCTRL_NRE5 (1 << TCC_DRVCTRL_NRE5_Pos) +#define TCC_DRVCTRL_NRE6_Pos 6 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 6 Output Enable */ +#define TCC_DRVCTRL_NRE6 (1 << TCC_DRVCTRL_NRE6_Pos) +#define TCC_DRVCTRL_NRE7_Pos 7 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 7 Output Enable */ +#define TCC_DRVCTRL_NRE7 (1 << TCC_DRVCTRL_NRE7_Pos) +#define TCC_DRVCTRL_NRE_Pos 0 /**< \brief (TCC_DRVCTRL) Non-Recoverable State x Output Enable */ +#define TCC_DRVCTRL_NRE_Msk (0xFFu << TCC_DRVCTRL_NRE_Pos) +#define TCC_DRVCTRL_NRE(value) ((TCC_DRVCTRL_NRE_Msk & ((value) << TCC_DRVCTRL_NRE_Pos))) +#define TCC_DRVCTRL_NRV0_Pos 8 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 0 Output Value */ +#define TCC_DRVCTRL_NRV0 (1 << TCC_DRVCTRL_NRV0_Pos) +#define TCC_DRVCTRL_NRV1_Pos 9 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 1 Output Value */ +#define TCC_DRVCTRL_NRV1 (1 << TCC_DRVCTRL_NRV1_Pos) +#define TCC_DRVCTRL_NRV2_Pos 10 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 2 Output Value */ +#define TCC_DRVCTRL_NRV2 (1 << TCC_DRVCTRL_NRV2_Pos) +#define TCC_DRVCTRL_NRV3_Pos 11 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 3 Output Value */ +#define TCC_DRVCTRL_NRV3 (1 << TCC_DRVCTRL_NRV3_Pos) +#define TCC_DRVCTRL_NRV4_Pos 12 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 4 Output Value */ +#define TCC_DRVCTRL_NRV4 (1 << TCC_DRVCTRL_NRV4_Pos) +#define TCC_DRVCTRL_NRV5_Pos 13 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 5 Output Value */ +#define TCC_DRVCTRL_NRV5 (1 << TCC_DRVCTRL_NRV5_Pos) +#define TCC_DRVCTRL_NRV6_Pos 14 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 6 Output Value */ +#define TCC_DRVCTRL_NRV6 (1 << TCC_DRVCTRL_NRV6_Pos) +#define TCC_DRVCTRL_NRV7_Pos 15 /**< \brief (TCC_DRVCTRL) Non-Recoverable State 7 Output Value */ +#define TCC_DRVCTRL_NRV7 (1 << TCC_DRVCTRL_NRV7_Pos) +#define TCC_DRVCTRL_NRV_Pos 8 /**< \brief (TCC_DRVCTRL) Non-Recoverable State x Output Value */ +#define TCC_DRVCTRL_NRV_Msk (0xFFu << TCC_DRVCTRL_NRV_Pos) +#define TCC_DRVCTRL_NRV(value) ((TCC_DRVCTRL_NRV_Msk & ((value) << TCC_DRVCTRL_NRV_Pos))) +#define TCC_DRVCTRL_INVEN0_Pos 16 /**< \brief (TCC_DRVCTRL) Output Waveform 0 Inversion */ +#define TCC_DRVCTRL_INVEN0 (1 << TCC_DRVCTRL_INVEN0_Pos) +#define TCC_DRVCTRL_INVEN1_Pos 17 /**< \brief (TCC_DRVCTRL) Output Waveform 1 Inversion */ +#define TCC_DRVCTRL_INVEN1 (1 << TCC_DRVCTRL_INVEN1_Pos) +#define TCC_DRVCTRL_INVEN2_Pos 18 /**< \brief (TCC_DRVCTRL) Output Waveform 2 Inversion */ +#define TCC_DRVCTRL_INVEN2 (1 << TCC_DRVCTRL_INVEN2_Pos) +#define TCC_DRVCTRL_INVEN3_Pos 19 /**< \brief (TCC_DRVCTRL) Output Waveform 3 Inversion */ +#define TCC_DRVCTRL_INVEN3 (1 << TCC_DRVCTRL_INVEN3_Pos) +#define TCC_DRVCTRL_INVEN4_Pos 20 /**< \brief (TCC_DRVCTRL) Output Waveform 4 Inversion */ +#define TCC_DRVCTRL_INVEN4 (1 << TCC_DRVCTRL_INVEN4_Pos) +#define TCC_DRVCTRL_INVEN5_Pos 21 /**< \brief (TCC_DRVCTRL) Output Waveform 5 Inversion */ +#define TCC_DRVCTRL_INVEN5 (1 << TCC_DRVCTRL_INVEN5_Pos) +#define TCC_DRVCTRL_INVEN6_Pos 22 /**< \brief (TCC_DRVCTRL) Output Waveform 6 Inversion */ +#define TCC_DRVCTRL_INVEN6 (1 << TCC_DRVCTRL_INVEN6_Pos) +#define TCC_DRVCTRL_INVEN7_Pos 23 /**< \brief (TCC_DRVCTRL) Output Waveform 7 Inversion */ +#define TCC_DRVCTRL_INVEN7 (1 << TCC_DRVCTRL_INVEN7_Pos) +#define TCC_DRVCTRL_INVEN_Pos 16 /**< \brief (TCC_DRVCTRL) Output Waveform x Inversion */ +#define TCC_DRVCTRL_INVEN_Msk (0xFFu << TCC_DRVCTRL_INVEN_Pos) +#define TCC_DRVCTRL_INVEN(value) ((TCC_DRVCTRL_INVEN_Msk & ((value) << TCC_DRVCTRL_INVEN_Pos))) +#define TCC_DRVCTRL_FILTERVAL0_Pos 24 /**< \brief (TCC_DRVCTRL) Non-Recoverable Fault Input 0 Filter Value */ +#define TCC_DRVCTRL_FILTERVAL0_Msk (0xFu << TCC_DRVCTRL_FILTERVAL0_Pos) +#define TCC_DRVCTRL_FILTERVAL0(value) ((TCC_DRVCTRL_FILTERVAL0_Msk & ((value) << TCC_DRVCTRL_FILTERVAL0_Pos))) +#define TCC_DRVCTRL_FILTERVAL1_Pos 28 /**< \brief (TCC_DRVCTRL) Non-Recoverable Fault Input 1 Filter Value */ +#define TCC_DRVCTRL_FILTERVAL1_Msk (0xFu << TCC_DRVCTRL_FILTERVAL1_Pos) +#define TCC_DRVCTRL_FILTERVAL1(value) ((TCC_DRVCTRL_FILTERVAL1_Msk & ((value) << TCC_DRVCTRL_FILTERVAL1_Pos))) +#define TCC_DRVCTRL_MASK 0xFFFFFFFFu /**< \brief (TCC_DRVCTRL) MASK Register */ + +/* -------- TCC_DBGCTRL : (TCC Offset: 0x1E) (R/W 8) Debug Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DBGRUN:1; /*!< bit: 0 Debug Running Mode */ + uint8_t :1; /*!< bit: 1 Reserved */ + uint8_t FDDBD:1; /*!< bit: 2 Fault Detection on Debug Break Detection */ + uint8_t :5; /*!< bit: 3.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} TCC_DBGCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_DBGCTRL_OFFSET 0x1E /**< \brief (TCC_DBGCTRL offset) Debug Control */ +#define TCC_DBGCTRL_RESETVALUE 0x00 /**< \brief (TCC_DBGCTRL reset_value) Debug Control */ + +#define TCC_DBGCTRL_DBGRUN_Pos 0 /**< \brief (TCC_DBGCTRL) Debug Running Mode */ +#define TCC_DBGCTRL_DBGRUN (0x1u << TCC_DBGCTRL_DBGRUN_Pos) +#define TCC_DBGCTRL_FDDBD_Pos 2 /**< \brief (TCC_DBGCTRL) Fault Detection on Debug Break Detection */ +#define TCC_DBGCTRL_FDDBD (0x1u << TCC_DBGCTRL_FDDBD_Pos) +#define TCC_DBGCTRL_MASK 0x05u /**< \brief (TCC_DBGCTRL) MASK Register */ + +/* -------- TCC_EVCTRL : (TCC Offset: 0x20) (R/W 32) Event Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t EVACT0:3; /*!< bit: 0.. 2 Timer/counter Input Event0 Action */ + uint32_t EVACT1:3; /*!< bit: 3.. 5 Timer/counter Input Event1 Action */ + uint32_t CNTSEL:2; /*!< bit: 6.. 7 Timer/counter Output Event Mode */ + uint32_t OVFEO:1; /*!< bit: 8 Overflow/Underflow Output Event Enable */ + uint32_t TRGEO:1; /*!< bit: 9 Retrigger Output Event Enable */ + uint32_t CNTEO:1; /*!< bit: 10 Timer/counter Output Event Enable */ + uint32_t :1; /*!< bit: 11 Reserved */ + uint32_t TCINV0:1; /*!< bit: 12 Inverted Event 0 Input Enable */ + uint32_t TCINV1:1; /*!< bit: 13 Inverted Event 1 Input Enable */ + uint32_t TCEI0:1; /*!< bit: 14 Timer/counter Event 0 Input Enable */ + uint32_t TCEI1:1; /*!< bit: 15 Timer/counter Event 1 Input Enable */ + uint32_t MCEI0:1; /*!< bit: 16 Match or Capture Channel 0 Event Input Enable */ + uint32_t MCEI1:1; /*!< bit: 17 Match or Capture Channel 1 Event Input Enable */ + uint32_t MCEI2:1; /*!< bit: 18 Match or Capture Channel 2 Event Input Enable */ + uint32_t MCEI3:1; /*!< bit: 19 Match or Capture Channel 3 Event Input Enable */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t MCEO0:1; /*!< bit: 24 Match or Capture Channel 0 Event Output Enable */ + uint32_t MCEO1:1; /*!< bit: 25 Match or Capture Channel 1 Event Output Enable */ + uint32_t MCEO2:1; /*!< bit: 26 Match or Capture Channel 2 Event Output Enable */ + uint32_t MCEO3:1; /*!< bit: 27 Match or Capture Channel 3 Event Output Enable */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :12; /*!< bit: 0..11 Reserved */ + uint32_t TCINV:2; /*!< bit: 12..13 Inverted Event x Input Enable */ + uint32_t TCEI:2; /*!< bit: 14..15 Timer/counter Event x Input Enable */ + uint32_t MCEI:4; /*!< bit: 16..19 Match or Capture Channel x Event Input Enable */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t MCEO:4; /*!< bit: 24..27 Match or Capture Channel x Event Output Enable */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_EVCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_EVCTRL_OFFSET 0x20 /**< \brief (TCC_EVCTRL offset) Event Control */ +#define TCC_EVCTRL_RESETVALUE 0x00000000 /**< \brief (TCC_EVCTRL reset_value) Event Control */ + +#define TCC_EVCTRL_EVACT0_Pos 0 /**< \brief (TCC_EVCTRL) Timer/counter Input Event0 Action */ +#define TCC_EVCTRL_EVACT0_Msk (0x7u << TCC_EVCTRL_EVACT0_Pos) +#define TCC_EVCTRL_EVACT0(value) ((TCC_EVCTRL_EVACT0_Msk & ((value) << TCC_EVCTRL_EVACT0_Pos))) +#define TCC_EVCTRL_EVACT0_OFF_Val 0x0u /**< \brief (TCC_EVCTRL) Event action disabled. */ +#define TCC_EVCTRL_EVACT0_RETRIGGER_Val 0x1u /**< \brief (TCC_EVCTRL) Start restart or re-trigger TC on event */ +#define TCC_EVCTRL_EVACT0_COUNTEV_Val 0x2u /**< \brief (TCC_EVCTRL) Count on event. Increment or decrement depending on count direction. */ +#define TCC_EVCTRL_EVACT0_START_Val 0x3u /**< \brief (TCC_EVCTRL) Count on event.Start counting on the event rising edge. Further events will not restart the counter; it keeps on counting using prescaled GCLK_TCCx, until it reaches TOP or Zero depending on the direction. */ +#define TCC_EVCTRL_EVACT0_INC_Val 0x4u /**< \brief (TCC_EVCTRL) Increment TC on EVENT. Increment the counter on event, irrespective of count direction */ +#define TCC_EVCTRL_EVACT0_COUNT_Val 0x5u /**< \brief (TCC_EVCTRL) Count on active state of asynchronous event */ +#define TCC_EVCTRL_EVACT0_FAULT_Val 0x7u /**< \brief (TCC_EVCTRL) Non-recoverable Fault */ +#define TCC_EVCTRL_EVACT0_OFF (TCC_EVCTRL_EVACT0_OFF_Val << TCC_EVCTRL_EVACT0_Pos) +#define TCC_EVCTRL_EVACT0_RETRIGGER (TCC_EVCTRL_EVACT0_RETRIGGER_Val << TCC_EVCTRL_EVACT0_Pos) +#define TCC_EVCTRL_EVACT0_COUNTEV (TCC_EVCTRL_EVACT0_COUNTEV_Val << TCC_EVCTRL_EVACT0_Pos) +#define TCC_EVCTRL_EVACT0_START (TCC_EVCTRL_EVACT0_START_Val << TCC_EVCTRL_EVACT0_Pos) +#define TCC_EVCTRL_EVACT0_INC (TCC_EVCTRL_EVACT0_INC_Val << TCC_EVCTRL_EVACT0_Pos) +#define TCC_EVCTRL_EVACT0_COUNT (TCC_EVCTRL_EVACT0_COUNT_Val << TCC_EVCTRL_EVACT0_Pos) +#define TCC_EVCTRL_EVACT0_FAULT (TCC_EVCTRL_EVACT0_FAULT_Val << TCC_EVCTRL_EVACT0_Pos) +#define TCC_EVCTRL_EVACT1_Pos 3 /**< \brief (TCC_EVCTRL) Timer/counter Input Event1 Action */ +#define TCC_EVCTRL_EVACT1_Msk (0x7u << TCC_EVCTRL_EVACT1_Pos) +#define TCC_EVCTRL_EVACT1(value) ((TCC_EVCTRL_EVACT1_Msk & ((value) << TCC_EVCTRL_EVACT1_Pos))) +#define TCC_EVCTRL_EVACT1_OFF_Val 0x0u /**< \brief (TCC_EVCTRL) Event action disabled. */ +#define TCC_EVCTRL_EVACT1_RETRIGGER_Val 0x1u /**< \brief (TCC_EVCTRL) Re-trigger TC on event */ +#define TCC_EVCTRL_EVACT1_DIR_Val 0x2u /**< \brief (TCC_EVCTRL) Direction control */ +#define TCC_EVCTRL_EVACT1_STOP_Val 0x3u /**< \brief (TCC_EVCTRL) Stop TC on event */ +#define TCC_EVCTRL_EVACT1_DEC_Val 0x4u /**< \brief (TCC_EVCTRL) Decrement TC on event */ +#define TCC_EVCTRL_EVACT1_PPW_Val 0x5u /**< \brief (TCC_EVCTRL) Period captured into CC0 Pulse Width on CC1 */ +#define TCC_EVCTRL_EVACT1_PWP_Val 0x6u /**< \brief (TCC_EVCTRL) Period captured into CC1 Pulse Width on CC0 */ +#define TCC_EVCTRL_EVACT1_FAULT_Val 0x7u /**< \brief (TCC_EVCTRL) Non-recoverable Fault */ +#define TCC_EVCTRL_EVACT1_OFF (TCC_EVCTRL_EVACT1_OFF_Val << TCC_EVCTRL_EVACT1_Pos) +#define TCC_EVCTRL_EVACT1_RETRIGGER (TCC_EVCTRL_EVACT1_RETRIGGER_Val << TCC_EVCTRL_EVACT1_Pos) +#define TCC_EVCTRL_EVACT1_DIR (TCC_EVCTRL_EVACT1_DIR_Val << TCC_EVCTRL_EVACT1_Pos) +#define TCC_EVCTRL_EVACT1_STOP (TCC_EVCTRL_EVACT1_STOP_Val << TCC_EVCTRL_EVACT1_Pos) +#define TCC_EVCTRL_EVACT1_DEC (TCC_EVCTRL_EVACT1_DEC_Val << TCC_EVCTRL_EVACT1_Pos) +#define TCC_EVCTRL_EVACT1_PPW (TCC_EVCTRL_EVACT1_PPW_Val << TCC_EVCTRL_EVACT1_Pos) +#define TCC_EVCTRL_EVACT1_PWP (TCC_EVCTRL_EVACT1_PWP_Val << TCC_EVCTRL_EVACT1_Pos) +#define TCC_EVCTRL_EVACT1_FAULT (TCC_EVCTRL_EVACT1_FAULT_Val << TCC_EVCTRL_EVACT1_Pos) +#define TCC_EVCTRL_CNTSEL_Pos 6 /**< \brief (TCC_EVCTRL) Timer/counter Output Event Mode */ +#define TCC_EVCTRL_CNTSEL_Msk (0x3u << TCC_EVCTRL_CNTSEL_Pos) +#define TCC_EVCTRL_CNTSEL(value) ((TCC_EVCTRL_CNTSEL_Msk & ((value) << TCC_EVCTRL_CNTSEL_Pos))) +#define TCC_EVCTRL_CNTSEL_START_Val 0x0u /**< \brief (TCC_EVCTRL) An interrupt/event is generated when a new counter cycle starts */ +#define TCC_EVCTRL_CNTSEL_END_Val 0x1u /**< \brief (TCC_EVCTRL) An interrupt/event is generated when a counter cycle ends */ +#define TCC_EVCTRL_CNTSEL_BETWEEN_Val 0x2u /**< \brief (TCC_EVCTRL) An interrupt/event is generated when a counter cycle ends, except for the first and last cycles. */ +#define TCC_EVCTRL_CNTSEL_BOUNDARY_Val 0x3u /**< \brief (TCC_EVCTRL) An interrupt/event is generated when a new counter cycle starts or a counter cycle ends */ +#define TCC_EVCTRL_CNTSEL_START (TCC_EVCTRL_CNTSEL_START_Val << TCC_EVCTRL_CNTSEL_Pos) +#define TCC_EVCTRL_CNTSEL_END (TCC_EVCTRL_CNTSEL_END_Val << TCC_EVCTRL_CNTSEL_Pos) +#define TCC_EVCTRL_CNTSEL_BETWEEN (TCC_EVCTRL_CNTSEL_BETWEEN_Val << TCC_EVCTRL_CNTSEL_Pos) +#define TCC_EVCTRL_CNTSEL_BOUNDARY (TCC_EVCTRL_CNTSEL_BOUNDARY_Val << TCC_EVCTRL_CNTSEL_Pos) +#define TCC_EVCTRL_OVFEO_Pos 8 /**< \brief (TCC_EVCTRL) Overflow/Underflow Output Event Enable */ +#define TCC_EVCTRL_OVFEO (0x1u << TCC_EVCTRL_OVFEO_Pos) +#define TCC_EVCTRL_TRGEO_Pos 9 /**< \brief (TCC_EVCTRL) Retrigger Output Event Enable */ +#define TCC_EVCTRL_TRGEO (0x1u << TCC_EVCTRL_TRGEO_Pos) +#define TCC_EVCTRL_CNTEO_Pos 10 /**< \brief (TCC_EVCTRL) Timer/counter Output Event Enable */ +#define TCC_EVCTRL_CNTEO (0x1u << TCC_EVCTRL_CNTEO_Pos) +#define TCC_EVCTRL_TCINV0_Pos 12 /**< \brief (TCC_EVCTRL) Inverted Event 0 Input Enable */ +#define TCC_EVCTRL_TCINV0 (1 << TCC_EVCTRL_TCINV0_Pos) +#define TCC_EVCTRL_TCINV1_Pos 13 /**< \brief (TCC_EVCTRL) Inverted Event 1 Input Enable */ +#define TCC_EVCTRL_TCINV1 (1 << TCC_EVCTRL_TCINV1_Pos) +#define TCC_EVCTRL_TCINV_Pos 12 /**< \brief (TCC_EVCTRL) Inverted Event x Input Enable */ +#define TCC_EVCTRL_TCINV_Msk (0x3u << TCC_EVCTRL_TCINV_Pos) +#define TCC_EVCTRL_TCINV(value) ((TCC_EVCTRL_TCINV_Msk & ((value) << TCC_EVCTRL_TCINV_Pos))) +#define TCC_EVCTRL_TCEI0_Pos 14 /**< \brief (TCC_EVCTRL) Timer/counter Event 0 Input Enable */ +#define TCC_EVCTRL_TCEI0 (1 << TCC_EVCTRL_TCEI0_Pos) +#define TCC_EVCTRL_TCEI1_Pos 15 /**< \brief (TCC_EVCTRL) Timer/counter Event 1 Input Enable */ +#define TCC_EVCTRL_TCEI1 (1 << TCC_EVCTRL_TCEI1_Pos) +#define TCC_EVCTRL_TCEI_Pos 14 /**< \brief (TCC_EVCTRL) Timer/counter Event x Input Enable */ +#define TCC_EVCTRL_TCEI_Msk (0x3u << TCC_EVCTRL_TCEI_Pos) +#define TCC_EVCTRL_TCEI(value) ((TCC_EVCTRL_TCEI_Msk & ((value) << TCC_EVCTRL_TCEI_Pos))) +#define TCC_EVCTRL_MCEI0_Pos 16 /**< \brief (TCC_EVCTRL) Match or Capture Channel 0 Event Input Enable */ +#define TCC_EVCTRL_MCEI0 (1 << TCC_EVCTRL_MCEI0_Pos) +#define TCC_EVCTRL_MCEI1_Pos 17 /**< \brief (TCC_EVCTRL) Match or Capture Channel 1 Event Input Enable */ +#define TCC_EVCTRL_MCEI1 (1 << TCC_EVCTRL_MCEI1_Pos) +#define TCC_EVCTRL_MCEI2_Pos 18 /**< \brief (TCC_EVCTRL) Match or Capture Channel 2 Event Input Enable */ +#define TCC_EVCTRL_MCEI2 (1 << TCC_EVCTRL_MCEI2_Pos) +#define TCC_EVCTRL_MCEI3_Pos 19 /**< \brief (TCC_EVCTRL) Match or Capture Channel 3 Event Input Enable */ +#define TCC_EVCTRL_MCEI3 (1 << TCC_EVCTRL_MCEI3_Pos) +#define TCC_EVCTRL_MCEI_Pos 16 /**< \brief (TCC_EVCTRL) Match or Capture Channel x Event Input Enable */ +#define TCC_EVCTRL_MCEI_Msk (0xFu << TCC_EVCTRL_MCEI_Pos) +#define TCC_EVCTRL_MCEI(value) ((TCC_EVCTRL_MCEI_Msk & ((value) << TCC_EVCTRL_MCEI_Pos))) +#define TCC_EVCTRL_MCEO0_Pos 24 /**< \brief (TCC_EVCTRL) Match or Capture Channel 0 Event Output Enable */ +#define TCC_EVCTRL_MCEO0 (1 << TCC_EVCTRL_MCEO0_Pos) +#define TCC_EVCTRL_MCEO1_Pos 25 /**< \brief (TCC_EVCTRL) Match or Capture Channel 1 Event Output Enable */ +#define TCC_EVCTRL_MCEO1 (1 << TCC_EVCTRL_MCEO1_Pos) +#define TCC_EVCTRL_MCEO2_Pos 26 /**< \brief (TCC_EVCTRL) Match or Capture Channel 2 Event Output Enable */ +#define TCC_EVCTRL_MCEO2 (1 << TCC_EVCTRL_MCEO2_Pos) +#define TCC_EVCTRL_MCEO3_Pos 27 /**< \brief (TCC_EVCTRL) Match or Capture Channel 3 Event Output Enable */ +#define TCC_EVCTRL_MCEO3 (1 << TCC_EVCTRL_MCEO3_Pos) +#define TCC_EVCTRL_MCEO_Pos 24 /**< \brief (TCC_EVCTRL) Match or Capture Channel x Event Output Enable */ +#define TCC_EVCTRL_MCEO_Msk (0xFu << TCC_EVCTRL_MCEO_Pos) +#define TCC_EVCTRL_MCEO(value) ((TCC_EVCTRL_MCEO_Msk & ((value) << TCC_EVCTRL_MCEO_Pos))) +#define TCC_EVCTRL_MASK 0x0F0FF7FFu /**< \brief (TCC_EVCTRL) MASK Register */ + +/* -------- TCC_INTENCLR : (TCC Offset: 0x24) (R/W 32) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OVF:1; /*!< bit: 0 Overflow Interrupt Enable */ + uint32_t TRG:1; /*!< bit: 1 Retrigger Interrupt Enable */ + uint32_t CNT:1; /*!< bit: 2 Counter Interrupt Enable */ + uint32_t ERR:1; /*!< bit: 3 Error Interrupt Enable */ + uint32_t :7; /*!< bit: 4..10 Reserved */ + uint32_t DFS:1; /*!< bit: 11 Non-recoverable Debug Fault Interrupt Enable */ + uint32_t FAULTA:1; /*!< bit: 12 Recoverable FaultA Interrupt Enable */ + uint32_t FAULTB:1; /*!< bit: 13 Recoverable FaultB Interrupt Enable */ + uint32_t FAULT0:1; /*!< bit: 14 Non-Recoverable Fault 0 Interrupt Enable */ + uint32_t FAULT1:1; /*!< bit: 15 Non-Recoverable Fault 1 Interrupt Enable */ + uint32_t MC0:1; /*!< bit: 16 Match or Capture Channel 0 Interrupt Enable */ + uint32_t MC1:1; /*!< bit: 17 Match or Capture Channel 1 Interrupt Enable */ + uint32_t MC2:1; /*!< bit: 18 Match or Capture Channel 2 Interrupt Enable */ + uint32_t MC3:1; /*!< bit: 19 Match or Capture Channel 3 Interrupt Enable */ + uint32_t :12; /*!< bit: 20..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :16; /*!< bit: 0..15 Reserved */ + uint32_t MC:4; /*!< bit: 16..19 Match or Capture Channel x Interrupt Enable */ + uint32_t :12; /*!< bit: 20..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_INTENCLR_OFFSET 0x24 /**< \brief (TCC_INTENCLR offset) Interrupt Enable Clear */ +#define TCC_INTENCLR_RESETVALUE 0x00000000 /**< \brief (TCC_INTENCLR reset_value) Interrupt Enable Clear */ + +#define TCC_INTENCLR_OVF_Pos 0 /**< \brief (TCC_INTENCLR) Overflow Interrupt Enable */ +#define TCC_INTENCLR_OVF (0x1u << TCC_INTENCLR_OVF_Pos) +#define TCC_INTENCLR_TRG_Pos 1 /**< \brief (TCC_INTENCLR) Retrigger Interrupt Enable */ +#define TCC_INTENCLR_TRG (0x1u << TCC_INTENCLR_TRG_Pos) +#define TCC_INTENCLR_CNT_Pos 2 /**< \brief (TCC_INTENCLR) Counter Interrupt Enable */ +#define TCC_INTENCLR_CNT (0x1u << TCC_INTENCLR_CNT_Pos) +#define TCC_INTENCLR_ERR_Pos 3 /**< \brief (TCC_INTENCLR) Error Interrupt Enable */ +#define TCC_INTENCLR_ERR (0x1u << TCC_INTENCLR_ERR_Pos) +#define TCC_INTENCLR_DFS_Pos 11 /**< \brief (TCC_INTENCLR) Non-recoverable Debug Fault Interrupt Enable */ +#define TCC_INTENCLR_DFS (0x1u << TCC_INTENCLR_DFS_Pos) +#define TCC_INTENCLR_FAULTA_Pos 12 /**< \brief (TCC_INTENCLR) Recoverable FaultA Interrupt Enable */ +#define TCC_INTENCLR_FAULTA (0x1u << TCC_INTENCLR_FAULTA_Pos) +#define TCC_INTENCLR_FAULTB_Pos 13 /**< \brief (TCC_INTENCLR) Recoverable FaultB Interrupt Enable */ +#define TCC_INTENCLR_FAULTB (0x1u << TCC_INTENCLR_FAULTB_Pos) +#define TCC_INTENCLR_FAULT0_Pos 14 /**< \brief (TCC_INTENCLR) Non-Recoverable Fault 0 Interrupt Enable */ +#define TCC_INTENCLR_FAULT0 (0x1u << TCC_INTENCLR_FAULT0_Pos) +#define TCC_INTENCLR_FAULT1_Pos 15 /**< \brief (TCC_INTENCLR) Non-Recoverable Fault 1 Interrupt Enable */ +#define TCC_INTENCLR_FAULT1 (0x1u << TCC_INTENCLR_FAULT1_Pos) +#define TCC_INTENCLR_MC0_Pos 16 /**< \brief (TCC_INTENCLR) Match or Capture Channel 0 Interrupt Enable */ +#define TCC_INTENCLR_MC0 (1 << TCC_INTENCLR_MC0_Pos) +#define TCC_INTENCLR_MC1_Pos 17 /**< \brief (TCC_INTENCLR) Match or Capture Channel 1 Interrupt Enable */ +#define TCC_INTENCLR_MC1 (1 << TCC_INTENCLR_MC1_Pos) +#define TCC_INTENCLR_MC2_Pos 18 /**< \brief (TCC_INTENCLR) Match or Capture Channel 2 Interrupt Enable */ +#define TCC_INTENCLR_MC2 (1 << TCC_INTENCLR_MC2_Pos) +#define TCC_INTENCLR_MC3_Pos 19 /**< \brief (TCC_INTENCLR) Match or Capture Channel 3 Interrupt Enable */ +#define TCC_INTENCLR_MC3 (1 << TCC_INTENCLR_MC3_Pos) +#define TCC_INTENCLR_MC_Pos 16 /**< \brief (TCC_INTENCLR) Match or Capture Channel x Interrupt Enable */ +#define TCC_INTENCLR_MC_Msk (0xFu << TCC_INTENCLR_MC_Pos) +#define TCC_INTENCLR_MC(value) ((TCC_INTENCLR_MC_Msk & ((value) << TCC_INTENCLR_MC_Pos))) +#define TCC_INTENCLR_MASK 0x000FF80Fu /**< \brief (TCC_INTENCLR) MASK Register */ + +/* -------- TCC_INTENSET : (TCC Offset: 0x28) (R/W 32) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OVF:1; /*!< bit: 0 Overflow Interrupt Enable */ + uint32_t TRG:1; /*!< bit: 1 Retrigger Interrupt Enable */ + uint32_t CNT:1; /*!< bit: 2 Counter Interrupt Enable */ + uint32_t ERR:1; /*!< bit: 3 Error Interrupt Enable */ + uint32_t :7; /*!< bit: 4..10 Reserved */ + uint32_t DFS:1; /*!< bit: 11 Non-Recoverable Debug Fault Interrupt Enable */ + uint32_t FAULTA:1; /*!< bit: 12 Recoverable FaultA Interrupt Enable */ + uint32_t FAULTB:1; /*!< bit: 13 Recoverable FaultB Interrupt Enable */ + uint32_t FAULT0:1; /*!< bit: 14 Non-Recoverable Fault 0 Interrupt Enable */ + uint32_t FAULT1:1; /*!< bit: 15 Non-Recoverable Fault 1 Interrupt Enabl */ + uint32_t MC0:1; /*!< bit: 16 Match or Capture Channel 0 Interrupt Enable */ + uint32_t MC1:1; /*!< bit: 17 Match or Capture Channel 1 Interrupt Enable */ + uint32_t MC2:1; /*!< bit: 18 Match or Capture Channel 2 Interrupt Enable */ + uint32_t MC3:1; /*!< bit: 19 Match or Capture Channel 3 Interrupt Enable */ + uint32_t :12; /*!< bit: 20..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :16; /*!< bit: 0..15 Reserved */ + uint32_t MC:4; /*!< bit: 16..19 Match or Capture Channel x Interrupt Enable */ + uint32_t :12; /*!< bit: 20..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_INTENSET_OFFSET 0x28 /**< \brief (TCC_INTENSET offset) Interrupt Enable Set */ +#define TCC_INTENSET_RESETVALUE 0x00000000 /**< \brief (TCC_INTENSET reset_value) Interrupt Enable Set */ + +#define TCC_INTENSET_OVF_Pos 0 /**< \brief (TCC_INTENSET) Overflow Interrupt Enable */ +#define TCC_INTENSET_OVF (0x1u << TCC_INTENSET_OVF_Pos) +#define TCC_INTENSET_TRG_Pos 1 /**< \brief (TCC_INTENSET) Retrigger Interrupt Enable */ +#define TCC_INTENSET_TRG (0x1u << TCC_INTENSET_TRG_Pos) +#define TCC_INTENSET_CNT_Pos 2 /**< \brief (TCC_INTENSET) Counter Interrupt Enable */ +#define TCC_INTENSET_CNT (0x1u << TCC_INTENSET_CNT_Pos) +#define TCC_INTENSET_ERR_Pos 3 /**< \brief (TCC_INTENSET) Error Interrupt Enable */ +#define TCC_INTENSET_ERR (0x1u << TCC_INTENSET_ERR_Pos) +#define TCC_INTENSET_DFS_Pos 11 /**< \brief (TCC_INTENSET) Non-Recoverable Debug Fault Interrupt Enable */ +#define TCC_INTENSET_DFS (0x1u << TCC_INTENSET_DFS_Pos) +#define TCC_INTENSET_FAULTA_Pos 12 /**< \brief (TCC_INTENSET) Recoverable FaultA Interrupt Enable */ +#define TCC_INTENSET_FAULTA (0x1u << TCC_INTENSET_FAULTA_Pos) +#define TCC_INTENSET_FAULTB_Pos 13 /**< \brief (TCC_INTENSET) Recoverable FaultB Interrupt Enable */ +#define TCC_INTENSET_FAULTB (0x1u << TCC_INTENSET_FAULTB_Pos) +#define TCC_INTENSET_FAULT0_Pos 14 /**< \brief (TCC_INTENSET) Non-Recoverable Fault 0 Interrupt Enable */ +#define TCC_INTENSET_FAULT0 (0x1u << TCC_INTENSET_FAULT0_Pos) +#define TCC_INTENSET_FAULT1_Pos 15 /**< \brief (TCC_INTENSET) Non-Recoverable Fault 1 Interrupt Enabl */ +#define TCC_INTENSET_FAULT1 (0x1u << TCC_INTENSET_FAULT1_Pos) +#define TCC_INTENSET_MC0_Pos 16 /**< \brief (TCC_INTENSET) Match or Capture Channel 0 Interrupt Enable */ +#define TCC_INTENSET_MC0 (1 << TCC_INTENSET_MC0_Pos) +#define TCC_INTENSET_MC1_Pos 17 /**< \brief (TCC_INTENSET) Match or Capture Channel 1 Interrupt Enable */ +#define TCC_INTENSET_MC1 (1 << TCC_INTENSET_MC1_Pos) +#define TCC_INTENSET_MC2_Pos 18 /**< \brief (TCC_INTENSET) Match or Capture Channel 2 Interrupt Enable */ +#define TCC_INTENSET_MC2 (1 << TCC_INTENSET_MC2_Pos) +#define TCC_INTENSET_MC3_Pos 19 /**< \brief (TCC_INTENSET) Match or Capture Channel 3 Interrupt Enable */ +#define TCC_INTENSET_MC3 (1 << TCC_INTENSET_MC3_Pos) +#define TCC_INTENSET_MC_Pos 16 /**< \brief (TCC_INTENSET) Match or Capture Channel x Interrupt Enable */ +#define TCC_INTENSET_MC_Msk (0xFu << TCC_INTENSET_MC_Pos) +#define TCC_INTENSET_MC(value) ((TCC_INTENSET_MC_Msk & ((value) << TCC_INTENSET_MC_Pos))) +#define TCC_INTENSET_MASK 0x000FF80Fu /**< \brief (TCC_INTENSET) MASK Register */ + +/* -------- TCC_INTFLAG : (TCC Offset: 0x2C) (R/W 32) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t OVF:1; /*!< bit: 0 Overflow */ + uint32_t TRG:1; /*!< bit: 1 Retrigger */ + uint32_t CNT:1; /*!< bit: 2 Counter */ + uint32_t ERR:1; /*!< bit: 3 Error */ + uint32_t :7; /*!< bit: 4..10 Reserved */ + uint32_t DFS:1; /*!< bit: 11 Non-Recoverable Debug Fault */ + uint32_t FAULTA:1; /*!< bit: 12 Recoverable FaultA */ + uint32_t FAULTB:1; /*!< bit: 13 Recoverable FaultB */ + uint32_t FAULT0:1; /*!< bit: 14 Non-Recoverable Fault 0 */ + uint32_t FAULT1:1; /*!< bit: 15 Non-Recoverable Fault 1 */ + uint32_t MC0:1; /*!< bit: 16 Match or Capture 0 */ + uint32_t MC1:1; /*!< bit: 17 Match or Capture 1 */ + uint32_t MC2:1; /*!< bit: 18 Match or Capture 2 */ + uint32_t MC3:1; /*!< bit: 19 Match or Capture 3 */ + uint32_t :12; /*!< bit: 20..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :16; /*!< bit: 0..15 Reserved */ + uint32_t MC:4; /*!< bit: 16..19 Match or Capture x */ + uint32_t :12; /*!< bit: 20..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_INTFLAG_OFFSET 0x2C /**< \brief (TCC_INTFLAG offset) Interrupt Flag Status and Clear */ +#define TCC_INTFLAG_RESETVALUE 0x00000000 /**< \brief (TCC_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define TCC_INTFLAG_OVF_Pos 0 /**< \brief (TCC_INTFLAG) Overflow */ +#define TCC_INTFLAG_OVF (0x1u << TCC_INTFLAG_OVF_Pos) +#define TCC_INTFLAG_TRG_Pos 1 /**< \brief (TCC_INTFLAG) Retrigger */ +#define TCC_INTFLAG_TRG (0x1u << TCC_INTFLAG_TRG_Pos) +#define TCC_INTFLAG_CNT_Pos 2 /**< \brief (TCC_INTFLAG) Counter */ +#define TCC_INTFLAG_CNT (0x1u << TCC_INTFLAG_CNT_Pos) +#define TCC_INTFLAG_ERR_Pos 3 /**< \brief (TCC_INTFLAG) Error */ +#define TCC_INTFLAG_ERR (0x1u << TCC_INTFLAG_ERR_Pos) +#define TCC_INTFLAG_DFS_Pos 11 /**< \brief (TCC_INTFLAG) Non-Recoverable Debug Fault */ +#define TCC_INTFLAG_DFS (0x1u << TCC_INTFLAG_DFS_Pos) +#define TCC_INTFLAG_FAULTA_Pos 12 /**< \brief (TCC_INTFLAG) Recoverable FaultA */ +#define TCC_INTFLAG_FAULTA (0x1u << TCC_INTFLAG_FAULTA_Pos) +#define TCC_INTFLAG_FAULTB_Pos 13 /**< \brief (TCC_INTFLAG) Recoverable FaultB */ +#define TCC_INTFLAG_FAULTB (0x1u << TCC_INTFLAG_FAULTB_Pos) +#define TCC_INTFLAG_FAULT0_Pos 14 /**< \brief (TCC_INTFLAG) Non-Recoverable Fault 0 */ +#define TCC_INTFLAG_FAULT0 (0x1u << TCC_INTFLAG_FAULT0_Pos) +#define TCC_INTFLAG_FAULT1_Pos 15 /**< \brief (TCC_INTFLAG) Non-Recoverable Fault 1 */ +#define TCC_INTFLAG_FAULT1 (0x1u << TCC_INTFLAG_FAULT1_Pos) +#define TCC_INTFLAG_MC0_Pos 16 /**< \brief (TCC_INTFLAG) Match or Capture 0 */ +#define TCC_INTFLAG_MC0 (1 << TCC_INTFLAG_MC0_Pos) +#define TCC_INTFLAG_MC1_Pos 17 /**< \brief (TCC_INTFLAG) Match or Capture 1 */ +#define TCC_INTFLAG_MC1 (1 << TCC_INTFLAG_MC1_Pos) +#define TCC_INTFLAG_MC2_Pos 18 /**< \brief (TCC_INTFLAG) Match or Capture 2 */ +#define TCC_INTFLAG_MC2 (1 << TCC_INTFLAG_MC2_Pos) +#define TCC_INTFLAG_MC3_Pos 19 /**< \brief (TCC_INTFLAG) Match or Capture 3 */ +#define TCC_INTFLAG_MC3 (1 << TCC_INTFLAG_MC3_Pos) +#define TCC_INTFLAG_MC_Pos 16 /**< \brief (TCC_INTFLAG) Match or Capture x */ +#define TCC_INTFLAG_MC_Msk (0xFu << TCC_INTFLAG_MC_Pos) +#define TCC_INTFLAG_MC(value) ((TCC_INTFLAG_MC_Msk & ((value) << TCC_INTFLAG_MC_Pos))) +#define TCC_INTFLAG_MASK 0x000FF80Fu /**< \brief (TCC_INTFLAG) MASK Register */ + +/* -------- TCC_STATUS : (TCC Offset: 0x30) (R/W 32) Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t STOP:1; /*!< bit: 0 Stop */ + uint32_t IDX:1; /*!< bit: 1 Ramp */ + uint32_t :1; /*!< bit: 2 Reserved */ + uint32_t DFS:1; /*!< bit: 3 Non-Recoverable Debug Fault State */ + uint32_t :1; /*!< bit: 4 Reserved */ + uint32_t PATTBV:1; /*!< bit: 5 Pattern Buffer Valid */ + uint32_t WAVEBV:1; /*!< bit: 6 Wave Buffer Valid */ + uint32_t PERBV:1; /*!< bit: 7 Period Buffer Valid */ + uint32_t FAULTAIN:1; /*!< bit: 8 Recoverable FaultA Input */ + uint32_t FAULTBIN:1; /*!< bit: 9 Recoverable FaultB Input */ + uint32_t FAULT0IN:1; /*!< bit: 10 Non-Recoverable Fault0 Input */ + uint32_t FAULT1IN:1; /*!< bit: 11 Non-Recoverable Fault1 Input */ + uint32_t FAULTA:1; /*!< bit: 12 Recoverable FaultA State */ + uint32_t FAULTB:1; /*!< bit: 13 Recoverable FaultB State */ + uint32_t FAULT0:1; /*!< bit: 14 Non-Recoverable Fault 0 State */ + uint32_t FAULT1:1; /*!< bit: 15 Non-Recoverable Fault 1 State */ + uint32_t CCBV0:1; /*!< bit: 16 Compare Channel 0 Buffer Valid */ + uint32_t CCBV1:1; /*!< bit: 17 Compare Channel 1 Buffer Valid */ + uint32_t CCBV2:1; /*!< bit: 18 Compare Channel 2 Buffer Valid */ + uint32_t CCBV3:1; /*!< bit: 19 Compare Channel 3 Buffer Valid */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t CMP0:1; /*!< bit: 24 Compare Channel 0 Value */ + uint32_t CMP1:1; /*!< bit: 25 Compare Channel 1 Value */ + uint32_t CMP2:1; /*!< bit: 26 Compare Channel 2 Value */ + uint32_t CMP3:1; /*!< bit: 27 Compare Channel 3 Value */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :16; /*!< bit: 0..15 Reserved */ + uint32_t CCBV:4; /*!< bit: 16..19 Compare Channel x Buffer Valid */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t CMP:4; /*!< bit: 24..27 Compare Channel x Value */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_STATUS_OFFSET 0x30 /**< \brief (TCC_STATUS offset) Status */ +#define TCC_STATUS_RESETVALUE 0x00000001 /**< \brief (TCC_STATUS reset_value) Status */ + +#define TCC_STATUS_STOP_Pos 0 /**< \brief (TCC_STATUS) Stop */ +#define TCC_STATUS_STOP (0x1u << TCC_STATUS_STOP_Pos) +#define TCC_STATUS_IDX_Pos 1 /**< \brief (TCC_STATUS) Ramp */ +#define TCC_STATUS_IDX (0x1u << TCC_STATUS_IDX_Pos) +#define TCC_STATUS_DFS_Pos 3 /**< \brief (TCC_STATUS) Non-Recoverable Debug Fault State */ +#define TCC_STATUS_DFS (0x1u << TCC_STATUS_DFS_Pos) +#define TCC_STATUS_PATTBV_Pos 5 /**< \brief (TCC_STATUS) Pattern Buffer Valid */ +#define TCC_STATUS_PATTBV (0x1u << TCC_STATUS_PATTBV_Pos) +#define TCC_STATUS_WAVEBV_Pos 6 /**< \brief (TCC_STATUS) Wave Buffer Valid */ +#define TCC_STATUS_WAVEBV (0x1u << TCC_STATUS_WAVEBV_Pos) +#define TCC_STATUS_PERBV_Pos 7 /**< \brief (TCC_STATUS) Period Buffer Valid */ +#define TCC_STATUS_PERBV (0x1u << TCC_STATUS_PERBV_Pos) +#define TCC_STATUS_FAULTAIN_Pos 8 /**< \brief (TCC_STATUS) Recoverable FaultA Input */ +#define TCC_STATUS_FAULTAIN (0x1u << TCC_STATUS_FAULTAIN_Pos) +#define TCC_STATUS_FAULTBIN_Pos 9 /**< \brief (TCC_STATUS) Recoverable FaultB Input */ +#define TCC_STATUS_FAULTBIN (0x1u << TCC_STATUS_FAULTBIN_Pos) +#define TCC_STATUS_FAULT0IN_Pos 10 /**< \brief (TCC_STATUS) Non-Recoverable Fault0 Input */ +#define TCC_STATUS_FAULT0IN (0x1u << TCC_STATUS_FAULT0IN_Pos) +#define TCC_STATUS_FAULT1IN_Pos 11 /**< \brief (TCC_STATUS) Non-Recoverable Fault1 Input */ +#define TCC_STATUS_FAULT1IN (0x1u << TCC_STATUS_FAULT1IN_Pos) +#define TCC_STATUS_FAULTA_Pos 12 /**< \brief (TCC_STATUS) Recoverable FaultA State */ +#define TCC_STATUS_FAULTA (0x1u << TCC_STATUS_FAULTA_Pos) +#define TCC_STATUS_FAULTB_Pos 13 /**< \brief (TCC_STATUS) Recoverable FaultB State */ +#define TCC_STATUS_FAULTB (0x1u << TCC_STATUS_FAULTB_Pos) +#define TCC_STATUS_FAULT0_Pos 14 /**< \brief (TCC_STATUS) Non-Recoverable Fault 0 State */ +#define TCC_STATUS_FAULT0 (0x1u << TCC_STATUS_FAULT0_Pos) +#define TCC_STATUS_FAULT1_Pos 15 /**< \brief (TCC_STATUS) Non-Recoverable Fault 1 State */ +#define TCC_STATUS_FAULT1 (0x1u << TCC_STATUS_FAULT1_Pos) +#define TCC_STATUS_CCBV0_Pos 16 /**< \brief (TCC_STATUS) Compare Channel 0 Buffer Valid */ +#define TCC_STATUS_CCBV0 (1 << TCC_STATUS_CCBV0_Pos) +#define TCC_STATUS_CCBV1_Pos 17 /**< \brief (TCC_STATUS) Compare Channel 1 Buffer Valid */ +#define TCC_STATUS_CCBV1 (1 << TCC_STATUS_CCBV1_Pos) +#define TCC_STATUS_CCBV2_Pos 18 /**< \brief (TCC_STATUS) Compare Channel 2 Buffer Valid */ +#define TCC_STATUS_CCBV2 (1 << TCC_STATUS_CCBV2_Pos) +#define TCC_STATUS_CCBV3_Pos 19 /**< \brief (TCC_STATUS) Compare Channel 3 Buffer Valid */ +#define TCC_STATUS_CCBV3 (1 << TCC_STATUS_CCBV3_Pos) +#define TCC_STATUS_CCBV_Pos 16 /**< \brief (TCC_STATUS) Compare Channel x Buffer Valid */ +#define TCC_STATUS_CCBV_Msk (0xFu << TCC_STATUS_CCBV_Pos) +#define TCC_STATUS_CCBV(value) ((TCC_STATUS_CCBV_Msk & ((value) << TCC_STATUS_CCBV_Pos))) +#define TCC_STATUS_CMP0_Pos 24 /**< \brief (TCC_STATUS) Compare Channel 0 Value */ +#define TCC_STATUS_CMP0 (1 << TCC_STATUS_CMP0_Pos) +#define TCC_STATUS_CMP1_Pos 25 /**< \brief (TCC_STATUS) Compare Channel 1 Value */ +#define TCC_STATUS_CMP1 (1 << TCC_STATUS_CMP1_Pos) +#define TCC_STATUS_CMP2_Pos 26 /**< \brief (TCC_STATUS) Compare Channel 2 Value */ +#define TCC_STATUS_CMP2 (1 << TCC_STATUS_CMP2_Pos) +#define TCC_STATUS_CMP3_Pos 27 /**< \brief (TCC_STATUS) Compare Channel 3 Value */ +#define TCC_STATUS_CMP3 (1 << TCC_STATUS_CMP3_Pos) +#define TCC_STATUS_CMP_Pos 24 /**< \brief (TCC_STATUS) Compare Channel x Value */ +#define TCC_STATUS_CMP_Msk (0xFu << TCC_STATUS_CMP_Pos) +#define TCC_STATUS_CMP(value) ((TCC_STATUS_CMP_Msk & ((value) << TCC_STATUS_CMP_Pos))) +#define TCC_STATUS_MASK 0x0F0FFFEBu /**< \brief (TCC_STATUS) MASK Register */ + +/* -------- TCC_COUNT : (TCC Offset: 0x34) (R/W 32) Count -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t COUNT:24; /*!< bit: 0..23 Count Value */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_COUNT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_COUNT_OFFSET 0x34 /**< \brief (TCC_COUNT offset) Count */ +#define TCC_COUNT_RESETVALUE 0x00000000 /**< \brief (TCC_COUNT reset_value) Count */ + +#define TCC_COUNT_COUNT_Pos 0 /**< \brief (TCC_COUNT) Count Value */ +#define TCC_COUNT_COUNT_Msk (0xFFFFFFu << TCC_COUNT_COUNT_Pos) +#define TCC_COUNT_COUNT(value) ((TCC_COUNT_COUNT_Msk & ((value) << TCC_COUNT_COUNT_Pos))) +#define TCC_COUNT_MASK 0x00FFFFFFu /**< \brief (TCC_COUNT) MASK Register */ + +/* -------- TCC_PATT : (TCC Offset: 0x38) (R/W 16) Pattern -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t PGE0:1; /*!< bit: 0 Pattern Generator 0 Output Enable */ + uint16_t PGE1:1; /*!< bit: 1 Pattern Generator 1 Output Enable */ + uint16_t PGE2:1; /*!< bit: 2 Pattern Generator 2 Output Enable */ + uint16_t PGE3:1; /*!< bit: 3 Pattern Generator 3 Output Enable */ + uint16_t PGE4:1; /*!< bit: 4 Pattern Generator 4 Output Enable */ + uint16_t PGE5:1; /*!< bit: 5 Pattern Generator 5 Output Enable */ + uint16_t PGE6:1; /*!< bit: 6 Pattern Generator 6 Output Enable */ + uint16_t PGE7:1; /*!< bit: 7 Pattern Generator 7 Output Enable */ + uint16_t PGV0:1; /*!< bit: 8 Pattern Generator 0 Output Value */ + uint16_t PGV1:1; /*!< bit: 9 Pattern Generator 1 Output Value */ + uint16_t PGV2:1; /*!< bit: 10 Pattern Generator 2 Output Value */ + uint16_t PGV3:1; /*!< bit: 11 Pattern Generator 3 Output Value */ + uint16_t PGV4:1; /*!< bit: 12 Pattern Generator 4 Output Value */ + uint16_t PGV5:1; /*!< bit: 13 Pattern Generator 5 Output Value */ + uint16_t PGV6:1; /*!< bit: 14 Pattern Generator 6 Output Value */ + uint16_t PGV7:1; /*!< bit: 15 Pattern Generator 7 Output Value */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t PGE:8; /*!< bit: 0.. 7 Pattern Generator x Output Enable */ + uint16_t PGV:8; /*!< bit: 8..15 Pattern Generator x Output Value */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} TCC_PATT_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_PATT_OFFSET 0x38 /**< \brief (TCC_PATT offset) Pattern */ +#define TCC_PATT_RESETVALUE 0x0000 /**< \brief (TCC_PATT reset_value) Pattern */ + +#define TCC_PATT_PGE0_Pos 0 /**< \brief (TCC_PATT) Pattern Generator 0 Output Enable */ +#define TCC_PATT_PGE0 (1 << TCC_PATT_PGE0_Pos) +#define TCC_PATT_PGE1_Pos 1 /**< \brief (TCC_PATT) Pattern Generator 1 Output Enable */ +#define TCC_PATT_PGE1 (1 << TCC_PATT_PGE1_Pos) +#define TCC_PATT_PGE2_Pos 2 /**< \brief (TCC_PATT) Pattern Generator 2 Output Enable */ +#define TCC_PATT_PGE2 (1 << TCC_PATT_PGE2_Pos) +#define TCC_PATT_PGE3_Pos 3 /**< \brief (TCC_PATT) Pattern Generator 3 Output Enable */ +#define TCC_PATT_PGE3 (1 << TCC_PATT_PGE3_Pos) +#define TCC_PATT_PGE4_Pos 4 /**< \brief (TCC_PATT) Pattern Generator 4 Output Enable */ +#define TCC_PATT_PGE4 (1 << TCC_PATT_PGE4_Pos) +#define TCC_PATT_PGE5_Pos 5 /**< \brief (TCC_PATT) Pattern Generator 5 Output Enable */ +#define TCC_PATT_PGE5 (1 << TCC_PATT_PGE5_Pos) +#define TCC_PATT_PGE6_Pos 6 /**< \brief (TCC_PATT) Pattern Generator 6 Output Enable */ +#define TCC_PATT_PGE6 (1 << TCC_PATT_PGE6_Pos) +#define TCC_PATT_PGE7_Pos 7 /**< \brief (TCC_PATT) Pattern Generator 7 Output Enable */ +#define TCC_PATT_PGE7 (1 << TCC_PATT_PGE7_Pos) +#define TCC_PATT_PGE_Pos 0 /**< \brief (TCC_PATT) Pattern Generator x Output Enable */ +#define TCC_PATT_PGE_Msk (0xFFu << TCC_PATT_PGE_Pos) +#define TCC_PATT_PGE(value) ((TCC_PATT_PGE_Msk & ((value) << TCC_PATT_PGE_Pos))) +#define TCC_PATT_PGV0_Pos 8 /**< \brief (TCC_PATT) Pattern Generator 0 Output Value */ +#define TCC_PATT_PGV0 (1 << TCC_PATT_PGV0_Pos) +#define TCC_PATT_PGV1_Pos 9 /**< \brief (TCC_PATT) Pattern Generator 1 Output Value */ +#define TCC_PATT_PGV1 (1 << TCC_PATT_PGV1_Pos) +#define TCC_PATT_PGV2_Pos 10 /**< \brief (TCC_PATT) Pattern Generator 2 Output Value */ +#define TCC_PATT_PGV2 (1 << TCC_PATT_PGV2_Pos) +#define TCC_PATT_PGV3_Pos 11 /**< \brief (TCC_PATT) Pattern Generator 3 Output Value */ +#define TCC_PATT_PGV3 (1 << TCC_PATT_PGV3_Pos) +#define TCC_PATT_PGV4_Pos 12 /**< \brief (TCC_PATT) Pattern Generator 4 Output Value */ +#define TCC_PATT_PGV4 (1 << TCC_PATT_PGV4_Pos) +#define TCC_PATT_PGV5_Pos 13 /**< \brief (TCC_PATT) Pattern Generator 5 Output Value */ +#define TCC_PATT_PGV5 (1 << TCC_PATT_PGV5_Pos) +#define TCC_PATT_PGV6_Pos 14 /**< \brief (TCC_PATT) Pattern Generator 6 Output Value */ +#define TCC_PATT_PGV6 (1 << TCC_PATT_PGV6_Pos) +#define TCC_PATT_PGV7_Pos 15 /**< \brief (TCC_PATT) Pattern Generator 7 Output Value */ +#define TCC_PATT_PGV7 (1 << TCC_PATT_PGV7_Pos) +#define TCC_PATT_PGV_Pos 8 /**< \brief (TCC_PATT) Pattern Generator x Output Value */ +#define TCC_PATT_PGV_Msk (0xFFu << TCC_PATT_PGV_Pos) +#define TCC_PATT_PGV(value) ((TCC_PATT_PGV_Msk & ((value) << TCC_PATT_PGV_Pos))) +#define TCC_PATT_MASK 0xFFFFu /**< \brief (TCC_PATT) MASK Register */ + +/* -------- TCC_WAVE : (TCC Offset: 0x3C) (R/W 32) Waveform Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t WAVEGEN:3; /*!< bit: 0.. 2 Waveform Generation */ + uint32_t :1; /*!< bit: 3 Reserved */ + uint32_t RAMP:2; /*!< bit: 4.. 5 Ramp Mode */ + uint32_t :1; /*!< bit: 6 Reserved */ + uint32_t CIPEREN:1; /*!< bit: 7 Circular period Enable */ + uint32_t CICCEN0:1; /*!< bit: 8 Circular Channel 0 Enable */ + uint32_t CICCEN1:1; /*!< bit: 9 Circular Channel 1 Enable */ + uint32_t CICCEN2:1; /*!< bit: 10 Circular Channel 2 Enable */ + uint32_t CICCEN3:1; /*!< bit: 11 Circular Channel 3 Enable */ + uint32_t :4; /*!< bit: 12..15 Reserved */ + uint32_t POL0:1; /*!< bit: 16 Channel 0 Polarity */ + uint32_t POL1:1; /*!< bit: 17 Channel 1 Polarity */ + uint32_t POL2:1; /*!< bit: 18 Channel 2 Polarity */ + uint32_t POL3:1; /*!< bit: 19 Channel 3 Polarity */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t SWAP0:1; /*!< bit: 24 Swap DTI Output Pair 0 */ + uint32_t SWAP1:1; /*!< bit: 25 Swap DTI Output Pair 1 */ + uint32_t SWAP2:1; /*!< bit: 26 Swap DTI Output Pair 2 */ + uint32_t SWAP3:1; /*!< bit: 27 Swap DTI Output Pair 3 */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :8; /*!< bit: 0.. 7 Reserved */ + uint32_t CICCEN:4; /*!< bit: 8..11 Circular Channel x Enable */ + uint32_t :4; /*!< bit: 12..15 Reserved */ + uint32_t POL:4; /*!< bit: 16..19 Channel x Polarity */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t SWAP:4; /*!< bit: 24..27 Swap DTI Output Pair x */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_WAVE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_WAVE_OFFSET 0x3C /**< \brief (TCC_WAVE offset) Waveform Control */ +#define TCC_WAVE_RESETVALUE 0x00000000 /**< \brief (TCC_WAVE reset_value) Waveform Control */ + +#define TCC_WAVE_WAVEGEN_Pos 0 /**< \brief (TCC_WAVE) Waveform Generation */ +#define TCC_WAVE_WAVEGEN_Msk (0x7u << TCC_WAVE_WAVEGEN_Pos) +#define TCC_WAVE_WAVEGEN(value) ((TCC_WAVE_WAVEGEN_Msk & ((value) << TCC_WAVE_WAVEGEN_Pos))) +#define TCC_WAVE_WAVEGEN_NFRQ_Val 0x0u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_WAVEGEN_MFRQ_Val 0x1u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_WAVEGEN_NPWM_Val 0x2u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_WAVEGEN_DSCRITICAL_Val 0x4u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_WAVEGEN_DSBOTTOM_Val 0x5u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_WAVEGEN_DSBOTH_Val 0x6u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_WAVEGEN_DSTOP_Val 0x7u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_WAVEGEN_NFRQ (TCC_WAVE_WAVEGEN_NFRQ_Val << TCC_WAVE_WAVEGEN_Pos) +#define TCC_WAVE_WAVEGEN_MFRQ (TCC_WAVE_WAVEGEN_MFRQ_Val << TCC_WAVE_WAVEGEN_Pos) +#define TCC_WAVE_WAVEGEN_NPWM (TCC_WAVE_WAVEGEN_NPWM_Val << TCC_WAVE_WAVEGEN_Pos) +#define TCC_WAVE_WAVEGEN_DSCRITICAL (TCC_WAVE_WAVEGEN_DSCRITICAL_Val << TCC_WAVE_WAVEGEN_Pos) +#define TCC_WAVE_WAVEGEN_DSBOTTOM (TCC_WAVE_WAVEGEN_DSBOTTOM_Val << TCC_WAVE_WAVEGEN_Pos) +#define TCC_WAVE_WAVEGEN_DSBOTH (TCC_WAVE_WAVEGEN_DSBOTH_Val << TCC_WAVE_WAVEGEN_Pos) +#define TCC_WAVE_WAVEGEN_DSTOP (TCC_WAVE_WAVEGEN_DSTOP_Val << TCC_WAVE_WAVEGEN_Pos) +#define TCC_WAVE_RAMP_Pos 4 /**< \brief (TCC_WAVE) Ramp Mode */ +#define TCC_WAVE_RAMP_Msk (0x3u << TCC_WAVE_RAMP_Pos) +#define TCC_WAVE_RAMP(value) ((TCC_WAVE_RAMP_Msk & ((value) << TCC_WAVE_RAMP_Pos))) +#define TCC_WAVE_RAMP_RAMP1_Val 0x0u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_RAMP_RAMP2A_Val 0x1u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_RAMP_RAMP2_Val 0x2u /**< \brief (TCC_WAVE) */ +#define TCC_WAVE_RAMP_RAMP1 (TCC_WAVE_RAMP_RAMP1_Val << TCC_WAVE_RAMP_Pos) +#define TCC_WAVE_RAMP_RAMP2A (TCC_WAVE_RAMP_RAMP2A_Val << TCC_WAVE_RAMP_Pos) +#define TCC_WAVE_RAMP_RAMP2 (TCC_WAVE_RAMP_RAMP2_Val << TCC_WAVE_RAMP_Pos) +#define TCC_WAVE_CIPEREN_Pos 7 /**< \brief (TCC_WAVE) Circular period Enable */ +#define TCC_WAVE_CIPEREN (0x1u << TCC_WAVE_CIPEREN_Pos) +#define TCC_WAVE_CICCEN0_Pos 8 /**< \brief (TCC_WAVE) Circular Channel 0 Enable */ +#define TCC_WAVE_CICCEN0 (1 << TCC_WAVE_CICCEN0_Pos) +#define TCC_WAVE_CICCEN1_Pos 9 /**< \brief (TCC_WAVE) Circular Channel 1 Enable */ +#define TCC_WAVE_CICCEN1 (1 << TCC_WAVE_CICCEN1_Pos) +#define TCC_WAVE_CICCEN2_Pos 10 /**< \brief (TCC_WAVE) Circular Channel 2 Enable */ +#define TCC_WAVE_CICCEN2 (1 << TCC_WAVE_CICCEN2_Pos) +#define TCC_WAVE_CICCEN3_Pos 11 /**< \brief (TCC_WAVE) Circular Channel 3 Enable */ +#define TCC_WAVE_CICCEN3 (1 << TCC_WAVE_CICCEN3_Pos) +#define TCC_WAVE_CICCEN_Pos 8 /**< \brief (TCC_WAVE) Circular Channel x Enable */ +#define TCC_WAVE_CICCEN_Msk (0xFu << TCC_WAVE_CICCEN_Pos) +#define TCC_WAVE_CICCEN(value) ((TCC_WAVE_CICCEN_Msk & ((value) << TCC_WAVE_CICCEN_Pos))) +#define TCC_WAVE_POL0_Pos 16 /**< \brief (TCC_WAVE) Channel 0 Polarity */ +#define TCC_WAVE_POL0 (1 << TCC_WAVE_POL0_Pos) +#define TCC_WAVE_POL1_Pos 17 /**< \brief (TCC_WAVE) Channel 1 Polarity */ +#define TCC_WAVE_POL1 (1 << TCC_WAVE_POL1_Pos) +#define TCC_WAVE_POL2_Pos 18 /**< \brief (TCC_WAVE) Channel 2 Polarity */ +#define TCC_WAVE_POL2 (1 << TCC_WAVE_POL2_Pos) +#define TCC_WAVE_POL3_Pos 19 /**< \brief (TCC_WAVE) Channel 3 Polarity */ +#define TCC_WAVE_POL3 (1 << TCC_WAVE_POL3_Pos) +#define TCC_WAVE_POL_Pos 16 /**< \brief (TCC_WAVE) Channel x Polarity */ +#define TCC_WAVE_POL_Msk (0xFu << TCC_WAVE_POL_Pos) +#define TCC_WAVE_POL(value) ((TCC_WAVE_POL_Msk & ((value) << TCC_WAVE_POL_Pos))) +#define TCC_WAVE_SWAP0_Pos 24 /**< \brief (TCC_WAVE) Swap DTI Output Pair 0 */ +#define TCC_WAVE_SWAP0 (1 << TCC_WAVE_SWAP0_Pos) +#define TCC_WAVE_SWAP1_Pos 25 /**< \brief (TCC_WAVE) Swap DTI Output Pair 1 */ +#define TCC_WAVE_SWAP1 (1 << TCC_WAVE_SWAP1_Pos) +#define TCC_WAVE_SWAP2_Pos 26 /**< \brief (TCC_WAVE) Swap DTI Output Pair 2 */ +#define TCC_WAVE_SWAP2 (1 << TCC_WAVE_SWAP2_Pos) +#define TCC_WAVE_SWAP3_Pos 27 /**< \brief (TCC_WAVE) Swap DTI Output Pair 3 */ +#define TCC_WAVE_SWAP3 (1 << TCC_WAVE_SWAP3_Pos) +#define TCC_WAVE_SWAP_Pos 24 /**< \brief (TCC_WAVE) Swap DTI Output Pair x */ +#define TCC_WAVE_SWAP_Msk (0xFu << TCC_WAVE_SWAP_Pos) +#define TCC_WAVE_SWAP(value) ((TCC_WAVE_SWAP_Msk & ((value) << TCC_WAVE_SWAP_Pos))) +#define TCC_WAVE_MASK 0x0F0F0FB7u /**< \brief (TCC_WAVE) MASK Register */ + +/* -------- TCC_PER : (TCC Offset: 0x40) (R/W 32) Period -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PER:24; /*!< bit: 0..23 Period Value */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_PER_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_PER_OFFSET 0x40 /**< \brief (TCC_PER offset) Period */ +#define TCC_PER_RESETVALUE 0xFFFFFFFF /**< \brief (TCC_PER reset_value) Period */ + +#define TCC_PER_PER_Pos 0 /**< \brief (TCC_PER) Period Value */ +#define TCC_PER_PER_Msk (0xFFFFFFu << TCC_PER_PER_Pos) +#define TCC_PER_PER(value) ((TCC_PER_PER_Msk & ((value) << TCC_PER_PER_Pos))) +#define TCC_PER_MASK 0x00FFFFFFu /**< \brief (TCC_PER) MASK Register */ + +/* -------- TCC_CC : (TCC Offset: 0x44) (R/W 32) Compare and Capture -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CC:24; /*!< bit: 0..23 Compare and Capture value */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_CC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_CC_OFFSET 0x44 /**< \brief (TCC_CC offset) Compare and Capture */ +#define TCC_CC_RESETVALUE 0x00000000 /**< \brief (TCC_CC reset_value) Compare and Capture */ + +#define TCC_CC_CC_Pos 0 /**< \brief (TCC_CC) Compare and Capture value */ +#define TCC_CC_CC_Msk (0xFFFFFFu << TCC_CC_CC_Pos) +#define TCC_CC_CC(value) ((TCC_CC_CC_Msk & ((value) << TCC_CC_CC_Pos))) +#define TCC_CC_MASK 0x00FFFFFFu /**< \brief (TCC_CC) MASK Register */ + +/* -------- TCC_PATTB : (TCC Offset: 0x64) (R/W 16) Pattern Buffer -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t PGEB0:1; /*!< bit: 0 Pattern Generator 0 Output Enable Buffer */ + uint16_t PGEB1:1; /*!< bit: 1 Pattern Generator 1 Output Enable Buffer */ + uint16_t PGEB2:1; /*!< bit: 2 Pattern Generator 2 Output Enable Buffer */ + uint16_t PGEB3:1; /*!< bit: 3 Pattern Generator 3 Output Enable Buffer */ + uint16_t PGEB4:1; /*!< bit: 4 Pattern Generator 4 Output Enable Buffer */ + uint16_t PGEB5:1; /*!< bit: 5 Pattern Generator 5 Output Enable Buffer */ + uint16_t PGEB6:1; /*!< bit: 6 Pattern Generator 6 Output Enable Buffer */ + uint16_t PGEB7:1; /*!< bit: 7 Pattern Generator 7 Output Enable Buffer */ + uint16_t PGVB0:1; /*!< bit: 8 Pattern Generator 0 Output Enable */ + uint16_t PGVB1:1; /*!< bit: 9 Pattern Generator 1 Output Enable */ + uint16_t PGVB2:1; /*!< bit: 10 Pattern Generator 2 Output Enable */ + uint16_t PGVB3:1; /*!< bit: 11 Pattern Generator 3 Output Enable */ + uint16_t PGVB4:1; /*!< bit: 12 Pattern Generator 4 Output Enable */ + uint16_t PGVB5:1; /*!< bit: 13 Pattern Generator 5 Output Enable */ + uint16_t PGVB6:1; /*!< bit: 14 Pattern Generator 6 Output Enable */ + uint16_t PGVB7:1; /*!< bit: 15 Pattern Generator 7 Output Enable */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t PGEB:8; /*!< bit: 0.. 7 Pattern Generator x Output Enable Buffer */ + uint16_t PGVB:8; /*!< bit: 8..15 Pattern Generator x Output Enable */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} TCC_PATTB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_PATTB_OFFSET 0x64 /**< \brief (TCC_PATTB offset) Pattern Buffer */ +#define TCC_PATTB_RESETVALUE 0x0000 /**< \brief (TCC_PATTB reset_value) Pattern Buffer */ + +#define TCC_PATTB_PGEB0_Pos 0 /**< \brief (TCC_PATTB) Pattern Generator 0 Output Enable Buffer */ +#define TCC_PATTB_PGEB0 (1 << TCC_PATTB_PGEB0_Pos) +#define TCC_PATTB_PGEB1_Pos 1 /**< \brief (TCC_PATTB) Pattern Generator 1 Output Enable Buffer */ +#define TCC_PATTB_PGEB1 (1 << TCC_PATTB_PGEB1_Pos) +#define TCC_PATTB_PGEB2_Pos 2 /**< \brief (TCC_PATTB) Pattern Generator 2 Output Enable Buffer */ +#define TCC_PATTB_PGEB2 (1 << TCC_PATTB_PGEB2_Pos) +#define TCC_PATTB_PGEB3_Pos 3 /**< \brief (TCC_PATTB) Pattern Generator 3 Output Enable Buffer */ +#define TCC_PATTB_PGEB3 (1 << TCC_PATTB_PGEB3_Pos) +#define TCC_PATTB_PGEB4_Pos 4 /**< \brief (TCC_PATTB) Pattern Generator 4 Output Enable Buffer */ +#define TCC_PATTB_PGEB4 (1 << TCC_PATTB_PGEB4_Pos) +#define TCC_PATTB_PGEB5_Pos 5 /**< \brief (TCC_PATTB) Pattern Generator 5 Output Enable Buffer */ +#define TCC_PATTB_PGEB5 (1 << TCC_PATTB_PGEB5_Pos) +#define TCC_PATTB_PGEB6_Pos 6 /**< \brief (TCC_PATTB) Pattern Generator 6 Output Enable Buffer */ +#define TCC_PATTB_PGEB6 (1 << TCC_PATTB_PGEB6_Pos) +#define TCC_PATTB_PGEB7_Pos 7 /**< \brief (TCC_PATTB) Pattern Generator 7 Output Enable Buffer */ +#define TCC_PATTB_PGEB7 (1 << TCC_PATTB_PGEB7_Pos) +#define TCC_PATTB_PGEB_Pos 0 /**< \brief (TCC_PATTB) Pattern Generator x Output Enable Buffer */ +#define TCC_PATTB_PGEB_Msk (0xFFu << TCC_PATTB_PGEB_Pos) +#define TCC_PATTB_PGEB(value) ((TCC_PATTB_PGEB_Msk & ((value) << TCC_PATTB_PGEB_Pos))) +#define TCC_PATTB_PGVB0_Pos 8 /**< \brief (TCC_PATTB) Pattern Generator 0 Output Enable */ +#define TCC_PATTB_PGVB0 (1 << TCC_PATTB_PGVB0_Pos) +#define TCC_PATTB_PGVB1_Pos 9 /**< \brief (TCC_PATTB) Pattern Generator 1 Output Enable */ +#define TCC_PATTB_PGVB1 (1 << TCC_PATTB_PGVB1_Pos) +#define TCC_PATTB_PGVB2_Pos 10 /**< \brief (TCC_PATTB) Pattern Generator 2 Output Enable */ +#define TCC_PATTB_PGVB2 (1 << TCC_PATTB_PGVB2_Pos) +#define TCC_PATTB_PGVB3_Pos 11 /**< \brief (TCC_PATTB) Pattern Generator 3 Output Enable */ +#define TCC_PATTB_PGVB3 (1 << TCC_PATTB_PGVB3_Pos) +#define TCC_PATTB_PGVB4_Pos 12 /**< \brief (TCC_PATTB) Pattern Generator 4 Output Enable */ +#define TCC_PATTB_PGVB4 (1 << TCC_PATTB_PGVB4_Pos) +#define TCC_PATTB_PGVB5_Pos 13 /**< \brief (TCC_PATTB) Pattern Generator 5 Output Enable */ +#define TCC_PATTB_PGVB5 (1 << TCC_PATTB_PGVB5_Pos) +#define TCC_PATTB_PGVB6_Pos 14 /**< \brief (TCC_PATTB) Pattern Generator 6 Output Enable */ +#define TCC_PATTB_PGVB6 (1 << TCC_PATTB_PGVB6_Pos) +#define TCC_PATTB_PGVB7_Pos 15 /**< \brief (TCC_PATTB) Pattern Generator 7 Output Enable */ +#define TCC_PATTB_PGVB7 (1 << TCC_PATTB_PGVB7_Pos) +#define TCC_PATTB_PGVB_Pos 8 /**< \brief (TCC_PATTB) Pattern Generator x Output Enable */ +#define TCC_PATTB_PGVB_Msk (0xFFu << TCC_PATTB_PGVB_Pos) +#define TCC_PATTB_PGVB(value) ((TCC_PATTB_PGVB_Msk & ((value) << TCC_PATTB_PGVB_Pos))) +#define TCC_PATTB_MASK 0xFFFFu /**< \brief (TCC_PATTB) MASK Register */ + +/* -------- TCC_WAVEB : (TCC Offset: 0x68) (R/W 32) Waveform Control Buffer -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t WAVEGENB:3; /*!< bit: 0.. 2 Waveform Generation Buffer */ + uint32_t :1; /*!< bit: 3 Reserved */ + uint32_t RAMPB:2; /*!< bit: 4.. 5 Ramp Mode Buffer */ + uint32_t :1; /*!< bit: 6 Reserved */ + uint32_t CIPERENB:1; /*!< bit: 7 Circular Period Enable Buffer */ + uint32_t CICCENB0:1; /*!< bit: 8 Circular Channel 0 Enable Buffer */ + uint32_t CICCENB1:1; /*!< bit: 9 Circular Channel 1 Enable Buffer */ + uint32_t CICCENB2:1; /*!< bit: 10 Circular Channel 2 Enable Buffer */ + uint32_t CICCENB3:1; /*!< bit: 11 Circular Channel 3 Enable Buffer */ + uint32_t :4; /*!< bit: 12..15 Reserved */ + uint32_t POLB0:1; /*!< bit: 16 Channel 0 Polarity Buffer */ + uint32_t POLB1:1; /*!< bit: 17 Channel 1 Polarity Buffer */ + uint32_t POLB2:1; /*!< bit: 18 Channel 2 Polarity Buffer */ + uint32_t POLB3:1; /*!< bit: 19 Channel 3 Polarity Buffer */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t SWAPB0:1; /*!< bit: 24 Swap DTI Output Pair 0 Buffer */ + uint32_t SWAPB1:1; /*!< bit: 25 Swap DTI Output Pair 1 Buffer */ + uint32_t SWAPB2:1; /*!< bit: 26 Swap DTI Output Pair 2 Buffer */ + uint32_t SWAPB3:1; /*!< bit: 27 Swap DTI Output Pair 3 Buffer */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint32_t :8; /*!< bit: 0.. 7 Reserved */ + uint32_t CICCENB:4; /*!< bit: 8..11 Circular Channel x Enable Buffer */ + uint32_t :4; /*!< bit: 12..15 Reserved */ + uint32_t POLB:4; /*!< bit: 16..19 Channel x Polarity Buffer */ + uint32_t :4; /*!< bit: 20..23 Reserved */ + uint32_t SWAPB:4; /*!< bit: 24..27 Swap DTI Output Pair x Buffer */ + uint32_t :4; /*!< bit: 28..31 Reserved */ + } vec; /*!< Structure used for vec access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_WAVEB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_WAVEB_OFFSET 0x68 /**< \brief (TCC_WAVEB offset) Waveform Control Buffer */ +#define TCC_WAVEB_RESETVALUE 0x00000000 /**< \brief (TCC_WAVEB reset_value) Waveform Control Buffer */ + +#define TCC_WAVEB_WAVEGENB_Pos 0 /**< \brief (TCC_WAVEB) Waveform Generation Buffer */ +#define TCC_WAVEB_WAVEGENB_Msk (0x7u << TCC_WAVEB_WAVEGENB_Pos) +#define TCC_WAVEB_WAVEGENB(value) ((TCC_WAVEB_WAVEGENB_Msk & ((value) << TCC_WAVEB_WAVEGENB_Pos))) +#define TCC_WAVEB_WAVEGENB_NFRQ_Val 0x0u /**< \brief (TCC_WAVEB) */ +#define TCC_WAVEB_WAVEGENB_MFRQ_Val 0x1u /**< \brief (TCC_WAVEB) */ +#define TCC_WAVEB_WAVEGENB_NPWM_Val 0x2u /**< \brief (TCC_WAVEB) */ +#define TCC_WAVEB_WAVEGENB_DSCRITICAL_Val 0x4u /**< \brief (TCC_WAVEB) */ +#define TCC_WAVEB_WAVEGENB_DSBOTTOM_Val 0x5u /**< \brief (TCC_WAVEB) */ +#define TCC_WAVEB_WAVEGENB_DSBOTH_Val 0x6u /**< \brief (TCC_WAVEB) */ +#define TCC_WAVEB_WAVEGENB_DSTOP_Val 0x7u /**< \brief (TCC_WAVEB) */ +#define TCC_WAVEB_WAVEGENB_NFRQ (TCC_WAVEB_WAVEGENB_NFRQ_Val << TCC_WAVEB_WAVEGENB_Pos) +#define TCC_WAVEB_WAVEGENB_MFRQ (TCC_WAVEB_WAVEGENB_MFRQ_Val << TCC_WAVEB_WAVEGENB_Pos) +#define TCC_WAVEB_WAVEGENB_NPWM (TCC_WAVEB_WAVEGENB_NPWM_Val << TCC_WAVEB_WAVEGENB_Pos) +#define TCC_WAVEB_WAVEGENB_DSCRITICAL (TCC_WAVEB_WAVEGENB_DSCRITICAL_Val << TCC_WAVEB_WAVEGENB_Pos) +#define TCC_WAVEB_WAVEGENB_DSBOTTOM (TCC_WAVEB_WAVEGENB_DSBOTTOM_Val << TCC_WAVEB_WAVEGENB_Pos) +#define TCC_WAVEB_WAVEGENB_DSBOTH (TCC_WAVEB_WAVEGENB_DSBOTH_Val << TCC_WAVEB_WAVEGENB_Pos) +#define TCC_WAVEB_WAVEGENB_DSTOP (TCC_WAVEB_WAVEGENB_DSTOP_Val << TCC_WAVEB_WAVEGENB_Pos) +#define TCC_WAVEB_RAMPB_Pos 4 /**< \brief (TCC_WAVEB) Ramp Mode Buffer */ +#define TCC_WAVEB_RAMPB_Msk (0x3u << TCC_WAVEB_RAMPB_Pos) +#define TCC_WAVEB_RAMPB(value) ((TCC_WAVEB_RAMPB_Msk & ((value) << TCC_WAVEB_RAMPB_Pos))) +#define TCC_WAVEB_CIPERENB_Pos 7 /**< \brief (TCC_WAVEB) Circular Period Enable Buffer */ +#define TCC_WAVEB_CIPERENB (0x1u << TCC_WAVEB_CIPERENB_Pos) +#define TCC_WAVEB_CICCENB0_Pos 8 /**< \brief (TCC_WAVEB) Circular Channel 0 Enable Buffer */ +#define TCC_WAVEB_CICCENB0 (1 << TCC_WAVEB_CICCENB0_Pos) +#define TCC_WAVEB_CICCENB1_Pos 9 /**< \brief (TCC_WAVEB) Circular Channel 1 Enable Buffer */ +#define TCC_WAVEB_CICCENB1 (1 << TCC_WAVEB_CICCENB1_Pos) +#define TCC_WAVEB_CICCENB2_Pos 10 /**< \brief (TCC_WAVEB) Circular Channel 2 Enable Buffer */ +#define TCC_WAVEB_CICCENB2 (1 << TCC_WAVEB_CICCENB2_Pos) +#define TCC_WAVEB_CICCENB3_Pos 11 /**< \brief (TCC_WAVEB) Circular Channel 3 Enable Buffer */ +#define TCC_WAVEB_CICCENB3 (1 << TCC_WAVEB_CICCENB3_Pos) +#define TCC_WAVEB_CICCENB_Pos 8 /**< \brief (TCC_WAVEB) Circular Channel x Enable Buffer */ +#define TCC_WAVEB_CICCENB_Msk (0xFu << TCC_WAVEB_CICCENB_Pos) +#define TCC_WAVEB_CICCENB(value) ((TCC_WAVEB_CICCENB_Msk & ((value) << TCC_WAVEB_CICCENB_Pos))) +#define TCC_WAVEB_POLB0_Pos 16 /**< \brief (TCC_WAVEB) Channel 0 Polarity Buffer */ +#define TCC_WAVEB_POLB0 (1 << TCC_WAVEB_POLB0_Pos) +#define TCC_WAVEB_POLB1_Pos 17 /**< \brief (TCC_WAVEB) Channel 1 Polarity Buffer */ +#define TCC_WAVEB_POLB1 (1 << TCC_WAVEB_POLB1_Pos) +#define TCC_WAVEB_POLB2_Pos 18 /**< \brief (TCC_WAVEB) Channel 2 Polarity Buffer */ +#define TCC_WAVEB_POLB2 (1 << TCC_WAVEB_POLB2_Pos) +#define TCC_WAVEB_POLB3_Pos 19 /**< \brief (TCC_WAVEB) Channel 3 Polarity Buffer */ +#define TCC_WAVEB_POLB3 (1 << TCC_WAVEB_POLB3_Pos) +#define TCC_WAVEB_POLB_Pos 16 /**< \brief (TCC_WAVEB) Channel x Polarity Buffer */ +#define TCC_WAVEB_POLB_Msk (0xFu << TCC_WAVEB_POLB_Pos) +#define TCC_WAVEB_POLB(value) ((TCC_WAVEB_POLB_Msk & ((value) << TCC_WAVEB_POLB_Pos))) +#define TCC_WAVEB_SWAPB0_Pos 24 /**< \brief (TCC_WAVEB) Swap DTI Output Pair 0 Buffer */ +#define TCC_WAVEB_SWAPB0 (1 << TCC_WAVEB_SWAPB0_Pos) +#define TCC_WAVEB_SWAPB1_Pos 25 /**< \brief (TCC_WAVEB) Swap DTI Output Pair 1 Buffer */ +#define TCC_WAVEB_SWAPB1 (1 << TCC_WAVEB_SWAPB1_Pos) +#define TCC_WAVEB_SWAPB2_Pos 26 /**< \brief (TCC_WAVEB) Swap DTI Output Pair 2 Buffer */ +#define TCC_WAVEB_SWAPB2 (1 << TCC_WAVEB_SWAPB2_Pos) +#define TCC_WAVEB_SWAPB3_Pos 27 /**< \brief (TCC_WAVEB) Swap DTI Output Pair 3 Buffer */ +#define TCC_WAVEB_SWAPB3 (1 << TCC_WAVEB_SWAPB3_Pos) +#define TCC_WAVEB_SWAPB_Pos 24 /**< \brief (TCC_WAVEB) Swap DTI Output Pair x Buffer */ +#define TCC_WAVEB_SWAPB_Msk (0xFu << TCC_WAVEB_SWAPB_Pos) +#define TCC_WAVEB_SWAPB(value) ((TCC_WAVEB_SWAPB_Msk & ((value) << TCC_WAVEB_SWAPB_Pos))) +#define TCC_WAVEB_MASK 0x0F0F0FB7u /**< \brief (TCC_WAVEB) MASK Register */ + +/* -------- TCC_PERB : (TCC Offset: 0x6C) (R/W 32) Period Buffer -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t PERB:24; /*!< bit: 0..23 Period Value */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_PERB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_PERB_OFFSET 0x6C /**< \brief (TCC_PERB offset) Period Buffer */ +#define TCC_PERB_RESETVALUE 0xFFFFFFFF /**< \brief (TCC_PERB reset_value) Period Buffer */ + +#define TCC_PERB_PERB_Pos 0 /**< \brief (TCC_PERB) Period Value */ +#define TCC_PERB_PERB_Msk (0xFFFFFFu << TCC_PERB_PERB_Pos) +#define TCC_PERB_PERB(value) ((TCC_PERB_PERB_Msk & ((value) << TCC_PERB_PERB_Pos))) +#define TCC_PERB_MASK 0x00FFFFFFu /**< \brief (TCC_PERB) MASK Register */ + +/* -------- TCC_CCB : (TCC Offset: 0x70) (R/W 32) Compare and Capture Buffer -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t CCB:24; /*!< bit: 0..23 Compare and Capture buffer value */ + uint32_t :8; /*!< bit: 24..31 Reserved */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} TCC_CCB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define TCC_CCB_OFFSET 0x70 /**< \brief (TCC_CCB offset) Compare and Capture Buffer */ +#define TCC_CCB_RESETVALUE 0x00000000 /**< \brief (TCC_CCB reset_value) Compare and Capture Buffer */ + +#define TCC_CCB_CCB_Pos 0 /**< \brief (TCC_CCB) Compare and Capture buffer value */ +#define TCC_CCB_CCB_Msk (0xFFFFFFu << TCC_CCB_CCB_Pos) +#define TCC_CCB_CCB(value) ((TCC_CCB_CCB_Msk & ((value) << TCC_CCB_CCB_Pos))) +#define TCC_CCB_MASK 0x00FFFFFFu /**< \brief (TCC_CCB) MASK Register */ + +/** \brief TCC hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO TCC_CTRLA_Type CTRLA; /**< \brief Offset: 0x00 (R/W 32) Control A */ + __IO TCC_CTRLBCLR_Type CTRLBCLR; /**< \brief Offset: 0x04 (R/W 8) Control B Clear */ + __IO TCC_CTRLBSET_Type CTRLBSET; /**< \brief Offset: 0x05 (R/W 8) Control B Set */ + RoReg8 Reserved1[0x2]; + __I TCC_SYNCBUSY_Type SYNCBUSY; /**< \brief Offset: 0x08 (R/ 32) Synchronization Busy */ + __IO TCC_FCTRLA_Type FCTRLA; /**< \brief Offset: 0x0C (R/W 32) Recoverable FaultA Configuration */ + __IO TCC_FCTRLB_Type FCTRLB; /**< \brief Offset: 0x10 (R/W 32) Recoverable FaultB Configuration */ + __IO TCC_WEXCTRL_Type WEXCTRL; /**< \brief Offset: 0x14 (R/W 32) Waveform Extension Configuration */ + __IO TCC_DRVCTRL_Type DRVCTRL; /**< \brief Offset: 0x18 (R/W 32) Driver Configuration */ + RoReg8 Reserved2[0x2]; + __IO TCC_DBGCTRL_Type DBGCTRL; /**< \brief Offset: 0x1E (R/W 8) Debug Control */ + RoReg8 Reserved3[0x1]; + __IO TCC_EVCTRL_Type EVCTRL; /**< \brief Offset: 0x20 (R/W 32) Event Control */ + __IO TCC_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x24 (R/W 32) Interrupt Enable Clear */ + __IO TCC_INTENSET_Type INTENSET; /**< \brief Offset: 0x28 (R/W 32) Interrupt Enable Set */ + __IO TCC_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x2C (R/W 32) Interrupt Flag Status and Clear */ + __IO TCC_STATUS_Type STATUS; /**< \brief Offset: 0x30 (R/W 32) Status */ + __IO TCC_COUNT_Type COUNT; /**< \brief Offset: 0x34 (R/W 32) Count */ + __IO TCC_PATT_Type PATT; /**< \brief Offset: 0x38 (R/W 16) Pattern */ + RoReg8 Reserved4[0x2]; + __IO TCC_WAVE_Type WAVE; /**< \brief Offset: 0x3C (R/W 32) Waveform Control */ + __IO TCC_PER_Type PER; /**< \brief Offset: 0x40 (R/W 32) Period */ + __IO TCC_CC_Type CC[4]; /**< \brief Offset: 0x44 (R/W 32) Compare and Capture */ + RoReg8 Reserved5[0x10]; + __IO TCC_PATTB_Type PATTB; /**< \brief Offset: 0x64 (R/W 16) Pattern Buffer */ + RoReg8 Reserved6[0x2]; + __IO TCC_WAVEB_Type WAVEB; /**< \brief Offset: 0x68 (R/W 32) Waveform Control Buffer */ + __IO TCC_PERB_Type PERB; /**< \brief Offset: 0x6C (R/W 32) Period Buffer */ + __IO TCC_CCB_Type CCB[4]; /**< \brief Offset: 0x70 (R/W 32) Compare and Capture Buffer */ +} Tcc; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_TCC_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/usb.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/usb.h new file mode 100755 index 0000000..eadabad --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/usb.h @@ -0,0 +1,1767 @@ +/** + * \file + * + * \brief Component description for USB + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_USB_COMPONENT_ +#define _SAMD21_USB_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR USB */ +/* ========================================================================== */ +/** \addtogroup SAMD21_USB Universal Serial Bus */ +/*@{*/ + +#define USB_U2222 +#define REV_USB 0x101 + +/* -------- USB_CTRLA : (USB Offset: 0x000) (R/W 8) Control A -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset */ + uint8_t ENABLE:1; /*!< bit: 1 Enable */ + uint8_t RUNSTDBY:1; /*!< bit: 2 Run in Standby Mode */ + uint8_t :4; /*!< bit: 3.. 6 Reserved */ + uint8_t MODE:1; /*!< bit: 7 Operating Mode */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_CTRLA_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_CTRLA_OFFSET 0x000 /**< \brief (USB_CTRLA offset) Control A */ +#define USB_CTRLA_RESETVALUE 0x00 /**< \brief (USB_CTRLA reset_value) Control A */ + +#define USB_CTRLA_SWRST_Pos 0 /**< \brief (USB_CTRLA) Software Reset */ +#define USB_CTRLA_SWRST (0x1u << USB_CTRLA_SWRST_Pos) +#define USB_CTRLA_ENABLE_Pos 1 /**< \brief (USB_CTRLA) Enable */ +#define USB_CTRLA_ENABLE (0x1u << USB_CTRLA_ENABLE_Pos) +#define USB_CTRLA_RUNSTDBY_Pos 2 /**< \brief (USB_CTRLA) Run in Standby Mode */ +#define USB_CTRLA_RUNSTDBY (0x1u << USB_CTRLA_RUNSTDBY_Pos) +#define USB_CTRLA_MODE_Pos 7 /**< \brief (USB_CTRLA) Operating Mode */ +#define USB_CTRLA_MODE (0x1u << USB_CTRLA_MODE_Pos) +#define USB_CTRLA_MODE_DEVICE_Val 0x0u /**< \brief (USB_CTRLA) Device Mode */ +#define USB_CTRLA_MODE_HOST_Val 0x1u /**< \brief (USB_CTRLA) Host Mode */ +#define USB_CTRLA_MODE_DEVICE (USB_CTRLA_MODE_DEVICE_Val << USB_CTRLA_MODE_Pos) +#define USB_CTRLA_MODE_HOST (USB_CTRLA_MODE_HOST_Val << USB_CTRLA_MODE_Pos) +#define USB_CTRLA_MASK 0x87u /**< \brief (USB_CTRLA) MASK Register */ + +/* -------- USB_SYNCBUSY : (USB Offset: 0x002) (R/ 8) Synchronization Busy -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t SWRST:1; /*!< bit: 0 Software Reset Synchronization Busy */ + uint8_t ENABLE:1; /*!< bit: 1 Enable Synchronization Busy */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_SYNCBUSY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_SYNCBUSY_OFFSET 0x002 /**< \brief (USB_SYNCBUSY offset) Synchronization Busy */ +#define USB_SYNCBUSY_RESETVALUE 0x00 /**< \brief (USB_SYNCBUSY reset_value) Synchronization Busy */ + +#define USB_SYNCBUSY_SWRST_Pos 0 /**< \brief (USB_SYNCBUSY) Software Reset Synchronization Busy */ +#define USB_SYNCBUSY_SWRST (0x1u << USB_SYNCBUSY_SWRST_Pos) +#define USB_SYNCBUSY_ENABLE_Pos 1 /**< \brief (USB_SYNCBUSY) Enable Synchronization Busy */ +#define USB_SYNCBUSY_ENABLE (0x1u << USB_SYNCBUSY_ENABLE_Pos) +#define USB_SYNCBUSY_MASK 0x03u /**< \brief (USB_SYNCBUSY) MASK Register */ + +/* -------- USB_DEVICE_CTRLB : (USB Offset: 0x008) (R/W 16) DEVICE DEVICE Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t DETACH:1; /*!< bit: 0 Detach */ + uint16_t UPRSM:1; /*!< bit: 1 Upstream Resume */ + uint16_t SPDCONF:2; /*!< bit: 2.. 3 Speed Configuration */ + uint16_t NREPLY:1; /*!< bit: 4 No Reply */ + uint16_t TSTJ:1; /*!< bit: 5 Test mode J */ + uint16_t TSTK:1; /*!< bit: 6 Test mode K */ + uint16_t TSTPCKT:1; /*!< bit: 7 Test packet mode */ + uint16_t OPMODE2:1; /*!< bit: 8 Specific Operational Mode */ + uint16_t GNAK:1; /*!< bit: 9 Global NAK */ + uint16_t LPMHDSK:2; /*!< bit: 10..11 Link Power Management Handshake */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_DEVICE_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_CTRLB_OFFSET 0x008 /**< \brief (USB_DEVICE_CTRLB offset) DEVICE Control B */ +#define USB_DEVICE_CTRLB_RESETVALUE 0x0001 /**< \brief (USB_DEVICE_CTRLB reset_value) DEVICE Control B */ + +#define USB_DEVICE_CTRLB_DETACH_Pos 0 /**< \brief (USB_DEVICE_CTRLB) Detach */ +#define USB_DEVICE_CTRLB_DETACH (0x1u << USB_DEVICE_CTRLB_DETACH_Pos) +#define USB_DEVICE_CTRLB_UPRSM_Pos 1 /**< \brief (USB_DEVICE_CTRLB) Upstream Resume */ +#define USB_DEVICE_CTRLB_UPRSM (0x1u << USB_DEVICE_CTRLB_UPRSM_Pos) +#define USB_DEVICE_CTRLB_SPDCONF_Pos 2 /**< \brief (USB_DEVICE_CTRLB) Speed Configuration */ +#define USB_DEVICE_CTRLB_SPDCONF_Msk (0x3u << USB_DEVICE_CTRLB_SPDCONF_Pos) +#define USB_DEVICE_CTRLB_SPDCONF(value) ((USB_DEVICE_CTRLB_SPDCONF_Msk & ((value) << USB_DEVICE_CTRLB_SPDCONF_Pos))) +#define USB_DEVICE_CTRLB_SPDCONF_0_Val 0x0u /**< \brief (USB_DEVICE_CTRLB) FS : Full Speed */ +#define USB_DEVICE_CTRLB_SPDCONF_1_Val 0x1u /**< \brief (USB_DEVICE_CTRLB) LS : Low Speed */ +#define USB_DEVICE_CTRLB_SPDCONF_2_Val 0x2u /**< \brief (USB_DEVICE_CTRLB) HS : High Speed capable */ +#define USB_DEVICE_CTRLB_SPDCONF_3_Val 0x3u /**< \brief (USB_DEVICE_CTRLB) HSTM: High Speed Test Mode (force high-speed mode for test mode) */ +#define USB_DEVICE_CTRLB_SPDCONF_0 (USB_DEVICE_CTRLB_SPDCONF_0_Val << USB_DEVICE_CTRLB_SPDCONF_Pos) +#define USB_DEVICE_CTRLB_SPDCONF_1 (USB_DEVICE_CTRLB_SPDCONF_1_Val << USB_DEVICE_CTRLB_SPDCONF_Pos) +#define USB_DEVICE_CTRLB_SPDCONF_2 (USB_DEVICE_CTRLB_SPDCONF_2_Val << USB_DEVICE_CTRLB_SPDCONF_Pos) +#define USB_DEVICE_CTRLB_SPDCONF_3 (USB_DEVICE_CTRLB_SPDCONF_3_Val << USB_DEVICE_CTRLB_SPDCONF_Pos) +#define USB_DEVICE_CTRLB_NREPLY_Pos 4 /**< \brief (USB_DEVICE_CTRLB) No Reply */ +#define USB_DEVICE_CTRLB_NREPLY (0x1u << USB_DEVICE_CTRLB_NREPLY_Pos) +#define USB_DEVICE_CTRLB_TSTJ_Pos 5 /**< \brief (USB_DEVICE_CTRLB) Test mode J */ +#define USB_DEVICE_CTRLB_TSTJ (0x1u << USB_DEVICE_CTRLB_TSTJ_Pos) +#define USB_DEVICE_CTRLB_TSTK_Pos 6 /**< \brief (USB_DEVICE_CTRLB) Test mode K */ +#define USB_DEVICE_CTRLB_TSTK (0x1u << USB_DEVICE_CTRLB_TSTK_Pos) +#define USB_DEVICE_CTRLB_TSTPCKT_Pos 7 /**< \brief (USB_DEVICE_CTRLB) Test packet mode */ +#define USB_DEVICE_CTRLB_TSTPCKT (0x1u << USB_DEVICE_CTRLB_TSTPCKT_Pos) +#define USB_DEVICE_CTRLB_OPMODE2_Pos 8 /**< \brief (USB_DEVICE_CTRLB) Specific Operational Mode */ +#define USB_DEVICE_CTRLB_OPMODE2 (0x1u << USB_DEVICE_CTRLB_OPMODE2_Pos) +#define USB_DEVICE_CTRLB_GNAK_Pos 9 /**< \brief (USB_DEVICE_CTRLB) Global NAK */ +#define USB_DEVICE_CTRLB_GNAK (0x1u << USB_DEVICE_CTRLB_GNAK_Pos) +#define USB_DEVICE_CTRLB_LPMHDSK_Pos 10 /**< \brief (USB_DEVICE_CTRLB) Link Power Management Handshake */ +#define USB_DEVICE_CTRLB_LPMHDSK_Msk (0x3u << USB_DEVICE_CTRLB_LPMHDSK_Pos) +#define USB_DEVICE_CTRLB_LPMHDSK(value) ((USB_DEVICE_CTRLB_LPMHDSK_Msk & ((value) << USB_DEVICE_CTRLB_LPMHDSK_Pos))) +#define USB_DEVICE_CTRLB_LPMHDSK_NO_Val 0x0u /**< \brief (USB_DEVICE_CTRLB) No handshake. LPM is not supported */ +#define USB_DEVICE_CTRLB_LPMHDSK_ACK_Val 0x1u /**< \brief (USB_DEVICE_CTRLB) ACK */ +#define USB_DEVICE_CTRLB_LPMHDSK_NYET_Val 0x2u /**< \brief (USB_DEVICE_CTRLB) NYET */ +#define USB_DEVICE_CTRLB_LPMHDSK_STALL_Val 0x3u /**< \brief (USB_DEVICE_CTRLB) STALL */ +#define USB_DEVICE_CTRLB_LPMHDSK_NO (USB_DEVICE_CTRLB_LPMHDSK_NO_Val << USB_DEVICE_CTRLB_LPMHDSK_Pos) +#define USB_DEVICE_CTRLB_LPMHDSK_ACK (USB_DEVICE_CTRLB_LPMHDSK_ACK_Val << USB_DEVICE_CTRLB_LPMHDSK_Pos) +#define USB_DEVICE_CTRLB_LPMHDSK_NYET (USB_DEVICE_CTRLB_LPMHDSK_NYET_Val << USB_DEVICE_CTRLB_LPMHDSK_Pos) +#define USB_DEVICE_CTRLB_LPMHDSK_STALL (USB_DEVICE_CTRLB_LPMHDSK_STALL_Val << USB_DEVICE_CTRLB_LPMHDSK_Pos) +#define USB_DEVICE_CTRLB_MASK 0x0FFFu /**< \brief (USB_DEVICE_CTRLB) MASK Register */ + +/* -------- USB_HOST_CTRLB : (USB Offset: 0x008) (R/W 16) HOST HOST Control B -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t :1; /*!< bit: 0 Reserved */ + uint16_t RESUME:1; /*!< bit: 1 Send USB Resume */ + uint16_t SPDCONF:2; /*!< bit: 2.. 3 Speed Configuration for Host */ + uint16_t :1; /*!< bit: 4 Reserved */ + uint16_t TSTJ:1; /*!< bit: 5 Test mode J */ + uint16_t TSTK:1; /*!< bit: 6 Test mode K */ + uint16_t :1; /*!< bit: 7 Reserved */ + uint16_t SOFE:1; /*!< bit: 8 Start of Frame Generation Enable */ + uint16_t BUSRESET:1; /*!< bit: 9 Send USB Reset */ + uint16_t VBUSOK:1; /*!< bit: 10 VBUS is OK */ + uint16_t L1RESUME:1; /*!< bit: 11 Send L1 Resume */ + uint16_t :4; /*!< bit: 12..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_HOST_CTRLB_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_CTRLB_OFFSET 0x008 /**< \brief (USB_HOST_CTRLB offset) HOST Control B */ +#define USB_HOST_CTRLB_RESETVALUE 0x0000 /**< \brief (USB_HOST_CTRLB reset_value) HOST Control B */ + +#define USB_HOST_CTRLB_RESUME_Pos 1 /**< \brief (USB_HOST_CTRLB) Send USB Resume */ +#define USB_HOST_CTRLB_RESUME (0x1u << USB_HOST_CTRLB_RESUME_Pos) +#define USB_HOST_CTRLB_SPDCONF_Pos 2 /**< \brief (USB_HOST_CTRLB) Speed Configuration for Host */ +#define USB_HOST_CTRLB_SPDCONF_Msk (0x3u << USB_HOST_CTRLB_SPDCONF_Pos) +#define USB_HOST_CTRLB_SPDCONF(value) ((USB_HOST_CTRLB_SPDCONF_Msk & ((value) << USB_HOST_CTRLB_SPDCONF_Pos))) +#define USB_HOST_CTRLB_SPDCONF_0_Val 0x0u /**< \brief (USB_HOST_CTRLB) Normal mode:the host starts in full-speed mode and performs a high-speed reset to switch to the high speed mode if the downstream peripheralis high-speed capable. */ +#define USB_HOST_CTRLB_SPDCONF_1_Val 0x1u /**< \brief (USB_HOST_CTRLB) reserved */ +#define USB_HOST_CTRLB_SPDCONF_2_Val 0x2u /**< \brief (USB_HOST_CTRLB) reserved */ +#define USB_HOST_CTRLB_SPDCONF_3_Val 0x3u /**< \brief (USB_HOST_CTRLB) Full-speed:the host remains in full-speed mode whatever is the peripheral speed capability. Releveant in UTMI mode only. */ +#define USB_HOST_CTRLB_SPDCONF_0 (USB_HOST_CTRLB_SPDCONF_0_Val << USB_HOST_CTRLB_SPDCONF_Pos) +#define USB_HOST_CTRLB_SPDCONF_1 (USB_HOST_CTRLB_SPDCONF_1_Val << USB_HOST_CTRLB_SPDCONF_Pos) +#define USB_HOST_CTRLB_SPDCONF_2 (USB_HOST_CTRLB_SPDCONF_2_Val << USB_HOST_CTRLB_SPDCONF_Pos) +#define USB_HOST_CTRLB_SPDCONF_3 (USB_HOST_CTRLB_SPDCONF_3_Val << USB_HOST_CTRLB_SPDCONF_Pos) +#define USB_HOST_CTRLB_TSTJ_Pos 5 /**< \brief (USB_HOST_CTRLB) Test mode J */ +#define USB_HOST_CTRLB_TSTJ (0x1u << USB_HOST_CTRLB_TSTJ_Pos) +#define USB_HOST_CTRLB_TSTK_Pos 6 /**< \brief (USB_HOST_CTRLB) Test mode K */ +#define USB_HOST_CTRLB_TSTK (0x1u << USB_HOST_CTRLB_TSTK_Pos) +#define USB_HOST_CTRLB_SOFE_Pos 8 /**< \brief (USB_HOST_CTRLB) Start of Frame Generation Enable */ +#define USB_HOST_CTRLB_SOFE (0x1u << USB_HOST_CTRLB_SOFE_Pos) +#define USB_HOST_CTRLB_BUSRESET_Pos 9 /**< \brief (USB_HOST_CTRLB) Send USB Reset */ +#define USB_HOST_CTRLB_BUSRESET (0x1u << USB_HOST_CTRLB_BUSRESET_Pos) +#define USB_HOST_CTRLB_VBUSOK_Pos 10 /**< \brief (USB_HOST_CTRLB) VBUS is OK */ +#define USB_HOST_CTRLB_VBUSOK (0x1u << USB_HOST_CTRLB_VBUSOK_Pos) +#define USB_HOST_CTRLB_L1RESUME_Pos 11 /**< \brief (USB_HOST_CTRLB) Send L1 Resume */ +#define USB_HOST_CTRLB_L1RESUME (0x1u << USB_HOST_CTRLB_L1RESUME_Pos) +#define USB_HOST_CTRLB_MASK 0x0F6Eu /**< \brief (USB_HOST_CTRLB) MASK Register */ + +/* -------- USB_DEVICE_DADD : (USB Offset: 0x00A) (R/W 8) DEVICE DEVICE Device Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DADD:7; /*!< bit: 0.. 6 Device Address */ + uint8_t ADDEN:1; /*!< bit: 7 Device Address Enable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_DADD_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_DADD_OFFSET 0x00A /**< \brief (USB_DEVICE_DADD offset) DEVICE Device Address */ +#define USB_DEVICE_DADD_RESETVALUE 0x00 /**< \brief (USB_DEVICE_DADD reset_value) DEVICE Device Address */ + +#define USB_DEVICE_DADD_DADD_Pos 0 /**< \brief (USB_DEVICE_DADD) Device Address */ +#define USB_DEVICE_DADD_DADD_Msk (0x7Fu << USB_DEVICE_DADD_DADD_Pos) +#define USB_DEVICE_DADD_DADD(value) ((USB_DEVICE_DADD_DADD_Msk & ((value) << USB_DEVICE_DADD_DADD_Pos))) +#define USB_DEVICE_DADD_ADDEN_Pos 7 /**< \brief (USB_DEVICE_DADD) Device Address Enable */ +#define USB_DEVICE_DADD_ADDEN (0x1u << USB_DEVICE_DADD_ADDEN_Pos) +#define USB_DEVICE_DADD_MASK 0xFFu /**< \brief (USB_DEVICE_DADD) MASK Register */ + +/* -------- USB_HOST_HSOFC : (USB Offset: 0x00A) (R/W 8) HOST HOST Host Start Of Frame Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t FLENC:4; /*!< bit: 0.. 3 Frame Length Control */ + uint8_t :3; /*!< bit: 4.. 6 Reserved */ + uint8_t FLENCE:1; /*!< bit: 7 Frame Length Control Enable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_HSOFC_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_HSOFC_OFFSET 0x00A /**< \brief (USB_HOST_HSOFC offset) HOST Host Start Of Frame Control */ +#define USB_HOST_HSOFC_RESETVALUE 0x00 /**< \brief (USB_HOST_HSOFC reset_value) HOST Host Start Of Frame Control */ + +#define USB_HOST_HSOFC_FLENC_Pos 0 /**< \brief (USB_HOST_HSOFC) Frame Length Control */ +#define USB_HOST_HSOFC_FLENC_Msk (0xFu << USB_HOST_HSOFC_FLENC_Pos) +#define USB_HOST_HSOFC_FLENC(value) ((USB_HOST_HSOFC_FLENC_Msk & ((value) << USB_HOST_HSOFC_FLENC_Pos))) +#define USB_HOST_HSOFC_FLENCE_Pos 7 /**< \brief (USB_HOST_HSOFC) Frame Length Control Enable */ +#define USB_HOST_HSOFC_FLENCE (0x1u << USB_HOST_HSOFC_FLENCE_Pos) +#define USB_HOST_HSOFC_MASK 0x8Fu /**< \brief (USB_HOST_HSOFC) MASK Register */ + +/* -------- USB_DEVICE_STATUS : (USB Offset: 0x00C) (R/ 8) DEVICE DEVICE Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :2; /*!< bit: 0.. 1 Reserved */ + uint8_t SPEED:2; /*!< bit: 2.. 3 Speed Status */ + uint8_t :2; /*!< bit: 4.. 5 Reserved */ + uint8_t LINESTATE:2; /*!< bit: 6.. 7 USB Line State Status */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_STATUS_OFFSET 0x00C /**< \brief (USB_DEVICE_STATUS offset) DEVICE Status */ +#define USB_DEVICE_STATUS_RESETVALUE 0x40 /**< \brief (USB_DEVICE_STATUS reset_value) DEVICE Status */ + +#define USB_DEVICE_STATUS_SPEED_Pos 2 /**< \brief (USB_DEVICE_STATUS) Speed Status */ +#define USB_DEVICE_STATUS_SPEED_Msk (0x3u << USB_DEVICE_STATUS_SPEED_Pos) +#define USB_DEVICE_STATUS_SPEED(value) ((USB_DEVICE_STATUS_SPEED_Msk & ((value) << USB_DEVICE_STATUS_SPEED_Pos))) +#define USB_DEVICE_STATUS_SPEED_0_Val 0x0u /**< \brief (USB_DEVICE_STATUS) Full-speed mode */ +#define USB_DEVICE_STATUS_SPEED_1_Val 0x1u /**< \brief (USB_DEVICE_STATUS) High-speed mode */ +#define USB_DEVICE_STATUS_SPEED_2_Val 0x2u /**< \brief (USB_DEVICE_STATUS) Low-speed mode */ +#define USB_DEVICE_STATUS_SPEED_0 (USB_DEVICE_STATUS_SPEED_0_Val << USB_DEVICE_STATUS_SPEED_Pos) +#define USB_DEVICE_STATUS_SPEED_1 (USB_DEVICE_STATUS_SPEED_1_Val << USB_DEVICE_STATUS_SPEED_Pos) +#define USB_DEVICE_STATUS_SPEED_2 (USB_DEVICE_STATUS_SPEED_2_Val << USB_DEVICE_STATUS_SPEED_Pos) +#define USB_DEVICE_STATUS_LINESTATE_Pos 6 /**< \brief (USB_DEVICE_STATUS) USB Line State Status */ +#define USB_DEVICE_STATUS_LINESTATE_Msk (0x3u << USB_DEVICE_STATUS_LINESTATE_Pos) +#define USB_DEVICE_STATUS_LINESTATE(value) ((USB_DEVICE_STATUS_LINESTATE_Msk & ((value) << USB_DEVICE_STATUS_LINESTATE_Pos))) +#define USB_DEVICE_STATUS_LINESTATE_0_Val 0x0u /**< \brief (USB_DEVICE_STATUS) SE0/RESET */ +#define USB_DEVICE_STATUS_LINESTATE_1_Val 0x1u /**< \brief (USB_DEVICE_STATUS) FS-J or LS-K State */ +#define USB_DEVICE_STATUS_LINESTATE_2_Val 0x2u /**< \brief (USB_DEVICE_STATUS) FS-K or LS-J State */ +#define USB_DEVICE_STATUS_LINESTATE_0 (USB_DEVICE_STATUS_LINESTATE_0_Val << USB_DEVICE_STATUS_LINESTATE_Pos) +#define USB_DEVICE_STATUS_LINESTATE_1 (USB_DEVICE_STATUS_LINESTATE_1_Val << USB_DEVICE_STATUS_LINESTATE_Pos) +#define USB_DEVICE_STATUS_LINESTATE_2 (USB_DEVICE_STATUS_LINESTATE_2_Val << USB_DEVICE_STATUS_LINESTATE_Pos) +#define USB_DEVICE_STATUS_MASK 0xCCu /**< \brief (USB_DEVICE_STATUS) MASK Register */ + +/* -------- USB_HOST_STATUS : (USB Offset: 0x00C) (R/W 8) HOST HOST Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :2; /*!< bit: 0.. 1 Reserved */ + uint8_t SPEED:2; /*!< bit: 2.. 3 Speed Status */ + uint8_t :2; /*!< bit: 4.. 5 Reserved */ + uint8_t LINESTATE:2; /*!< bit: 6.. 7 USB Line State Status */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_STATUS_OFFSET 0x00C /**< \brief (USB_HOST_STATUS offset) HOST Status */ +#define USB_HOST_STATUS_RESETVALUE 0x00 /**< \brief (USB_HOST_STATUS reset_value) HOST Status */ + +#define USB_HOST_STATUS_SPEED_Pos 2 /**< \brief (USB_HOST_STATUS) Speed Status */ +#define USB_HOST_STATUS_SPEED_Msk (0x3u << USB_HOST_STATUS_SPEED_Pos) +#define USB_HOST_STATUS_SPEED(value) ((USB_HOST_STATUS_SPEED_Msk & ((value) << USB_HOST_STATUS_SPEED_Pos))) +#define USB_HOST_STATUS_LINESTATE_Pos 6 /**< \brief (USB_HOST_STATUS) USB Line State Status */ +#define USB_HOST_STATUS_LINESTATE_Msk (0x3u << USB_HOST_STATUS_LINESTATE_Pos) +#define USB_HOST_STATUS_LINESTATE(value) ((USB_HOST_STATUS_LINESTATE_Msk & ((value) << USB_HOST_STATUS_LINESTATE_Pos))) +#define USB_HOST_STATUS_MASK 0xCCu /**< \brief (USB_HOST_STATUS) MASK Register */ + +/* -------- USB_FSMSTATUS : (USB Offset: 0x00D) (R/ 8) Finite State Machine Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t FSMSTATE:6; /*!< bit: 0.. 5 Fine State Machine Status */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_FSMSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_FSMSTATUS_OFFSET 0x00D /**< \brief (USB_FSMSTATUS offset) Finite State Machine Status */ +#define USB_FSMSTATUS_RESETVALUE 0x01 /**< \brief (USB_FSMSTATUS reset_value) Finite State Machine Status */ + +#define USB_FSMSTATUS_FSMSTATE_Pos 0 /**< \brief (USB_FSMSTATUS) Fine State Machine Status */ +#define USB_FSMSTATUS_FSMSTATE_Msk (0x3Fu << USB_FSMSTATUS_FSMSTATE_Pos) +#define USB_FSMSTATUS_FSMSTATE(value) ((USB_FSMSTATUS_FSMSTATE_Msk & ((value) << USB_FSMSTATUS_FSMSTATE_Pos))) +#define USB_FSMSTATUS_FSMSTATE_1_Val 0x1u /**< \brief (USB_FSMSTATUS) OFF (L3). It corresponds to the powered-off, disconnected, and disabled state */ +#define USB_FSMSTATUS_FSMSTATE_2_Val 0x2u /**< \brief (USB_FSMSTATUS) ON (L0). It corresponds to the Idle and Active states */ +#define USB_FSMSTATUS_FSMSTATE_4_Val 0x4u /**< \brief (USB_FSMSTATUS) SUSPEND (L2) */ +#define USB_FSMSTATUS_FSMSTATE_8_Val 0x8u /**< \brief (USB_FSMSTATUS) SLEEP (L1) */ +#define USB_FSMSTATUS_FSMSTATE_16_Val 0x10u /**< \brief (USB_FSMSTATUS) DNRESUME. Down Stream Resume. */ +#define USB_FSMSTATUS_FSMSTATE_32_Val 0x20u /**< \brief (USB_FSMSTATUS) UPRESUME. Up Stream Resume. */ +#define USB_FSMSTATUS_FSMSTATE_64_Val 0x40u /**< \brief (USB_FSMSTATUS) RESET. USB lines Reset. */ +#define USB_FSMSTATUS_FSMSTATE_1 (USB_FSMSTATUS_FSMSTATE_1_Val << USB_FSMSTATUS_FSMSTATE_Pos) +#define USB_FSMSTATUS_FSMSTATE_2 (USB_FSMSTATUS_FSMSTATE_2_Val << USB_FSMSTATUS_FSMSTATE_Pos) +#define USB_FSMSTATUS_FSMSTATE_4 (USB_FSMSTATUS_FSMSTATE_4_Val << USB_FSMSTATUS_FSMSTATE_Pos) +#define USB_FSMSTATUS_FSMSTATE_8 (USB_FSMSTATUS_FSMSTATE_8_Val << USB_FSMSTATUS_FSMSTATE_Pos) +#define USB_FSMSTATUS_FSMSTATE_16 (USB_FSMSTATUS_FSMSTATE_16_Val << USB_FSMSTATUS_FSMSTATE_Pos) +#define USB_FSMSTATUS_FSMSTATE_32 (USB_FSMSTATUS_FSMSTATE_32_Val << USB_FSMSTATUS_FSMSTATE_Pos) +#define USB_FSMSTATUS_FSMSTATE_64 (USB_FSMSTATUS_FSMSTATE_64_Val << USB_FSMSTATUS_FSMSTATE_Pos) +#define USB_FSMSTATUS_MASK 0x3Fu /**< \brief (USB_FSMSTATUS) MASK Register */ + +/* -------- USB_DEVICE_FNUM : (USB Offset: 0x010) (R/ 16) DEVICE DEVICE Device Frame Number -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t MFNUM:3; /*!< bit: 0.. 2 Micro Frame Number */ + uint16_t FNUM:11; /*!< bit: 3..13 Frame Number */ + uint16_t :1; /*!< bit: 14 Reserved */ + uint16_t FNCERR:1; /*!< bit: 15 Frame Number CRC Error */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_DEVICE_FNUM_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_FNUM_OFFSET 0x010 /**< \brief (USB_DEVICE_FNUM offset) DEVICE Device Frame Number */ +#define USB_DEVICE_FNUM_RESETVALUE 0x0000 /**< \brief (USB_DEVICE_FNUM reset_value) DEVICE Device Frame Number */ + +#define USB_DEVICE_FNUM_MFNUM_Pos 0 /**< \brief (USB_DEVICE_FNUM) Micro Frame Number */ +#define USB_DEVICE_FNUM_MFNUM_Msk (0x7u << USB_DEVICE_FNUM_MFNUM_Pos) +#define USB_DEVICE_FNUM_MFNUM(value) ((USB_DEVICE_FNUM_MFNUM_Msk & ((value) << USB_DEVICE_FNUM_MFNUM_Pos))) +#define USB_DEVICE_FNUM_FNUM_Pos 3 /**< \brief (USB_DEVICE_FNUM) Frame Number */ +#define USB_DEVICE_FNUM_FNUM_Msk (0x7FFu << USB_DEVICE_FNUM_FNUM_Pos) +#define USB_DEVICE_FNUM_FNUM(value) ((USB_DEVICE_FNUM_FNUM_Msk & ((value) << USB_DEVICE_FNUM_FNUM_Pos))) +#define USB_DEVICE_FNUM_FNCERR_Pos 15 /**< \brief (USB_DEVICE_FNUM) Frame Number CRC Error */ +#define USB_DEVICE_FNUM_FNCERR (0x1u << USB_DEVICE_FNUM_FNCERR_Pos) +#define USB_DEVICE_FNUM_MASK 0xBFFFu /**< \brief (USB_DEVICE_FNUM) MASK Register */ + +/* -------- USB_HOST_FNUM : (USB Offset: 0x010) (R/W 16) HOST HOST Host Frame Number -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t MFNUM:3; /*!< bit: 0.. 2 Micro Frame Number */ + uint16_t FNUM:11; /*!< bit: 3..13 Frame Number */ + uint16_t :2; /*!< bit: 14..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_HOST_FNUM_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_FNUM_OFFSET 0x010 /**< \brief (USB_HOST_FNUM offset) HOST Host Frame Number */ +#define USB_HOST_FNUM_RESETVALUE 0x0000 /**< \brief (USB_HOST_FNUM reset_value) HOST Host Frame Number */ + +#define USB_HOST_FNUM_MFNUM_Pos 0 /**< \brief (USB_HOST_FNUM) Micro Frame Number */ +#define USB_HOST_FNUM_MFNUM_Msk (0x7u << USB_HOST_FNUM_MFNUM_Pos) +#define USB_HOST_FNUM_MFNUM(value) ((USB_HOST_FNUM_MFNUM_Msk & ((value) << USB_HOST_FNUM_MFNUM_Pos))) +#define USB_HOST_FNUM_FNUM_Pos 3 /**< \brief (USB_HOST_FNUM) Frame Number */ +#define USB_HOST_FNUM_FNUM_Msk (0x7FFu << USB_HOST_FNUM_FNUM_Pos) +#define USB_HOST_FNUM_FNUM(value) ((USB_HOST_FNUM_FNUM_Msk & ((value) << USB_HOST_FNUM_FNUM_Pos))) +#define USB_HOST_FNUM_MASK 0x3FFFu /**< \brief (USB_HOST_FNUM) MASK Register */ + +/* -------- USB_HOST_FLENHIGH : (USB Offset: 0x012) (R/ 8) HOST HOST Host Frame Length -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t FLENHIGH:8; /*!< bit: 0.. 7 Frame Length */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_FLENHIGH_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_FLENHIGH_OFFSET 0x012 /**< \brief (USB_HOST_FLENHIGH offset) HOST Host Frame Length */ +#define USB_HOST_FLENHIGH_RESETVALUE 0x00 /**< \brief (USB_HOST_FLENHIGH reset_value) HOST Host Frame Length */ + +#define USB_HOST_FLENHIGH_FLENHIGH_Pos 0 /**< \brief (USB_HOST_FLENHIGH) Frame Length */ +#define USB_HOST_FLENHIGH_FLENHIGH_Msk (0xFFu << USB_HOST_FLENHIGH_FLENHIGH_Pos) +#define USB_HOST_FLENHIGH_FLENHIGH(value) ((USB_HOST_FLENHIGH_FLENHIGH_Msk & ((value) << USB_HOST_FLENHIGH_FLENHIGH_Pos))) +#define USB_HOST_FLENHIGH_MASK 0xFFu /**< \brief (USB_HOST_FLENHIGH) MASK Register */ + +/* -------- USB_DEVICE_INTENCLR : (USB Offset: 0x014) (R/W 16) DEVICE DEVICE Device Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SUSPEND:1; /*!< bit: 0 Suspend Interrupt Enable */ + uint16_t MSOF:1; /*!< bit: 1 Micro Start of Frame Interrupt Enable in High Speed Mode */ + uint16_t SOF:1; /*!< bit: 2 Start Of Frame Interrupt Enable */ + uint16_t EORST:1; /*!< bit: 3 End of Reset Interrupt Enable */ + uint16_t WAKEUP:1; /*!< bit: 4 Wake Up Interrupt Enable */ + uint16_t EORSM:1; /*!< bit: 5 End Of Resume Interrupt Enable */ + uint16_t UPRSM:1; /*!< bit: 6 Upstream Resume Interrupt Enable */ + uint16_t RAMACER:1; /*!< bit: 7 Ram Access Interrupt Enable */ + uint16_t LPMNYET:1; /*!< bit: 8 Link Power Management Not Yet Interrupt Enable */ + uint16_t LPMSUSP:1; /*!< bit: 9 Link Power Management Suspend Interrupt Enable */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_DEVICE_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_INTENCLR_OFFSET 0x014 /**< \brief (USB_DEVICE_INTENCLR offset) DEVICE Device Interrupt Enable Clear */ +#define USB_DEVICE_INTENCLR_RESETVALUE 0x0000 /**< \brief (USB_DEVICE_INTENCLR reset_value) DEVICE Device Interrupt Enable Clear */ + +#define USB_DEVICE_INTENCLR_SUSPEND_Pos 0 /**< \brief (USB_DEVICE_INTENCLR) Suspend Interrupt Enable */ +#define USB_DEVICE_INTENCLR_SUSPEND (0x1u << USB_DEVICE_INTENCLR_SUSPEND_Pos) +#define USB_DEVICE_INTENCLR_MSOF_Pos 1 /**< \brief (USB_DEVICE_INTENCLR) Micro Start of Frame Interrupt Enable in High Speed Mode */ +#define USB_DEVICE_INTENCLR_MSOF (0x1u << USB_DEVICE_INTENCLR_MSOF_Pos) +#define USB_DEVICE_INTENCLR_SOF_Pos 2 /**< \brief (USB_DEVICE_INTENCLR) Start Of Frame Interrupt Enable */ +#define USB_DEVICE_INTENCLR_SOF (0x1u << USB_DEVICE_INTENCLR_SOF_Pos) +#define USB_DEVICE_INTENCLR_EORST_Pos 3 /**< \brief (USB_DEVICE_INTENCLR) End of Reset Interrupt Enable */ +#define USB_DEVICE_INTENCLR_EORST (0x1u << USB_DEVICE_INTENCLR_EORST_Pos) +#define USB_DEVICE_INTENCLR_WAKEUP_Pos 4 /**< \brief (USB_DEVICE_INTENCLR) Wake Up Interrupt Enable */ +#define USB_DEVICE_INTENCLR_WAKEUP (0x1u << USB_DEVICE_INTENCLR_WAKEUP_Pos) +#define USB_DEVICE_INTENCLR_EORSM_Pos 5 /**< \brief (USB_DEVICE_INTENCLR) End Of Resume Interrupt Enable */ +#define USB_DEVICE_INTENCLR_EORSM (0x1u << USB_DEVICE_INTENCLR_EORSM_Pos) +#define USB_DEVICE_INTENCLR_UPRSM_Pos 6 /**< \brief (USB_DEVICE_INTENCLR) Upstream Resume Interrupt Enable */ +#define USB_DEVICE_INTENCLR_UPRSM (0x1u << USB_DEVICE_INTENCLR_UPRSM_Pos) +#define USB_DEVICE_INTENCLR_RAMACER_Pos 7 /**< \brief (USB_DEVICE_INTENCLR) Ram Access Interrupt Enable */ +#define USB_DEVICE_INTENCLR_RAMACER (0x1u << USB_DEVICE_INTENCLR_RAMACER_Pos) +#define USB_DEVICE_INTENCLR_LPMNYET_Pos 8 /**< \brief (USB_DEVICE_INTENCLR) Link Power Management Not Yet Interrupt Enable */ +#define USB_DEVICE_INTENCLR_LPMNYET (0x1u << USB_DEVICE_INTENCLR_LPMNYET_Pos) +#define USB_DEVICE_INTENCLR_LPMSUSP_Pos 9 /**< \brief (USB_DEVICE_INTENCLR) Link Power Management Suspend Interrupt Enable */ +#define USB_DEVICE_INTENCLR_LPMSUSP (0x1u << USB_DEVICE_INTENCLR_LPMSUSP_Pos) +#define USB_DEVICE_INTENCLR_MASK 0x03FFu /**< \brief (USB_DEVICE_INTENCLR) MASK Register */ + +/* -------- USB_HOST_INTENCLR : (USB Offset: 0x014) (R/W 16) HOST HOST Host Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t :2; /*!< bit: 0.. 1 Reserved */ + uint16_t HSOF:1; /*!< bit: 2 Host Start Of Frame Interrupt Disable */ + uint16_t RST:1; /*!< bit: 3 BUS Reset Interrupt Disable */ + uint16_t WAKEUP:1; /*!< bit: 4 Wake Up Interrupt Disable */ + uint16_t DNRSM:1; /*!< bit: 5 DownStream to Device Interrupt Disable */ + uint16_t UPRSM:1; /*!< bit: 6 Upstream Resume from Device Interrupt Disable */ + uint16_t RAMACER:1; /*!< bit: 7 Ram Access Interrupt Disable */ + uint16_t DCONN:1; /*!< bit: 8 Device Connection Interrupt Disable */ + uint16_t DDISC:1; /*!< bit: 9 Device Disconnection Interrupt Disable */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_HOST_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_INTENCLR_OFFSET 0x014 /**< \brief (USB_HOST_INTENCLR offset) HOST Host Interrupt Enable Clear */ +#define USB_HOST_INTENCLR_RESETVALUE 0x0000 /**< \brief (USB_HOST_INTENCLR reset_value) HOST Host Interrupt Enable Clear */ + +#define USB_HOST_INTENCLR_HSOF_Pos 2 /**< \brief (USB_HOST_INTENCLR) Host Start Of Frame Interrupt Disable */ +#define USB_HOST_INTENCLR_HSOF (0x1u << USB_HOST_INTENCLR_HSOF_Pos) +#define USB_HOST_INTENCLR_RST_Pos 3 /**< \brief (USB_HOST_INTENCLR) BUS Reset Interrupt Disable */ +#define USB_HOST_INTENCLR_RST (0x1u << USB_HOST_INTENCLR_RST_Pos) +#define USB_HOST_INTENCLR_WAKEUP_Pos 4 /**< \brief (USB_HOST_INTENCLR) Wake Up Interrupt Disable */ +#define USB_HOST_INTENCLR_WAKEUP (0x1u << USB_HOST_INTENCLR_WAKEUP_Pos) +#define USB_HOST_INTENCLR_DNRSM_Pos 5 /**< \brief (USB_HOST_INTENCLR) DownStream to Device Interrupt Disable */ +#define USB_HOST_INTENCLR_DNRSM (0x1u << USB_HOST_INTENCLR_DNRSM_Pos) +#define USB_HOST_INTENCLR_UPRSM_Pos 6 /**< \brief (USB_HOST_INTENCLR) Upstream Resume from Device Interrupt Disable */ +#define USB_HOST_INTENCLR_UPRSM (0x1u << USB_HOST_INTENCLR_UPRSM_Pos) +#define USB_HOST_INTENCLR_RAMACER_Pos 7 /**< \brief (USB_HOST_INTENCLR) Ram Access Interrupt Disable */ +#define USB_HOST_INTENCLR_RAMACER (0x1u << USB_HOST_INTENCLR_RAMACER_Pos) +#define USB_HOST_INTENCLR_DCONN_Pos 8 /**< \brief (USB_HOST_INTENCLR) Device Connection Interrupt Disable */ +#define USB_HOST_INTENCLR_DCONN (0x1u << USB_HOST_INTENCLR_DCONN_Pos) +#define USB_HOST_INTENCLR_DDISC_Pos 9 /**< \brief (USB_HOST_INTENCLR) Device Disconnection Interrupt Disable */ +#define USB_HOST_INTENCLR_DDISC (0x1u << USB_HOST_INTENCLR_DDISC_Pos) +#define USB_HOST_INTENCLR_MASK 0x03FCu /**< \brief (USB_HOST_INTENCLR) MASK Register */ + +/* -------- USB_DEVICE_INTENSET : (USB Offset: 0x018) (R/W 16) DEVICE DEVICE Device Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SUSPEND:1; /*!< bit: 0 Suspend Interrupt Enable */ + uint16_t MSOF:1; /*!< bit: 1 Micro Start of Frame Interrupt Enable in High Speed Mode */ + uint16_t SOF:1; /*!< bit: 2 Start Of Frame Interrupt Enable */ + uint16_t EORST:1; /*!< bit: 3 End of Reset Interrupt Enable */ + uint16_t WAKEUP:1; /*!< bit: 4 Wake Up Interrupt Enable */ + uint16_t EORSM:1; /*!< bit: 5 End Of Resume Interrupt Enable */ + uint16_t UPRSM:1; /*!< bit: 6 Upstream Resume Interrupt Enable */ + uint16_t RAMACER:1; /*!< bit: 7 Ram Access Interrupt Enable */ + uint16_t LPMNYET:1; /*!< bit: 8 Link Power Management Not Yet Interrupt Enable */ + uint16_t LPMSUSP:1; /*!< bit: 9 Link Power Management Suspend Interrupt Enable */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_DEVICE_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_INTENSET_OFFSET 0x018 /**< \brief (USB_DEVICE_INTENSET offset) DEVICE Device Interrupt Enable Set */ +#define USB_DEVICE_INTENSET_RESETVALUE 0x0000 /**< \brief (USB_DEVICE_INTENSET reset_value) DEVICE Device Interrupt Enable Set */ + +#define USB_DEVICE_INTENSET_SUSPEND_Pos 0 /**< \brief (USB_DEVICE_INTENSET) Suspend Interrupt Enable */ +#define USB_DEVICE_INTENSET_SUSPEND (0x1u << USB_DEVICE_INTENSET_SUSPEND_Pos) +#define USB_DEVICE_INTENSET_MSOF_Pos 1 /**< \brief (USB_DEVICE_INTENSET) Micro Start of Frame Interrupt Enable in High Speed Mode */ +#define USB_DEVICE_INTENSET_MSOF (0x1u << USB_DEVICE_INTENSET_MSOF_Pos) +#define USB_DEVICE_INTENSET_SOF_Pos 2 /**< \brief (USB_DEVICE_INTENSET) Start Of Frame Interrupt Enable */ +#define USB_DEVICE_INTENSET_SOF (0x1u << USB_DEVICE_INTENSET_SOF_Pos) +#define USB_DEVICE_INTENSET_EORST_Pos 3 /**< \brief (USB_DEVICE_INTENSET) End of Reset Interrupt Enable */ +#define USB_DEVICE_INTENSET_EORST (0x1u << USB_DEVICE_INTENSET_EORST_Pos) +#define USB_DEVICE_INTENSET_WAKEUP_Pos 4 /**< \brief (USB_DEVICE_INTENSET) Wake Up Interrupt Enable */ +#define USB_DEVICE_INTENSET_WAKEUP (0x1u << USB_DEVICE_INTENSET_WAKEUP_Pos) +#define USB_DEVICE_INTENSET_EORSM_Pos 5 /**< \brief (USB_DEVICE_INTENSET) End Of Resume Interrupt Enable */ +#define USB_DEVICE_INTENSET_EORSM (0x1u << USB_DEVICE_INTENSET_EORSM_Pos) +#define USB_DEVICE_INTENSET_UPRSM_Pos 6 /**< \brief (USB_DEVICE_INTENSET) Upstream Resume Interrupt Enable */ +#define USB_DEVICE_INTENSET_UPRSM (0x1u << USB_DEVICE_INTENSET_UPRSM_Pos) +#define USB_DEVICE_INTENSET_RAMACER_Pos 7 /**< \brief (USB_DEVICE_INTENSET) Ram Access Interrupt Enable */ +#define USB_DEVICE_INTENSET_RAMACER (0x1u << USB_DEVICE_INTENSET_RAMACER_Pos) +#define USB_DEVICE_INTENSET_LPMNYET_Pos 8 /**< \brief (USB_DEVICE_INTENSET) Link Power Management Not Yet Interrupt Enable */ +#define USB_DEVICE_INTENSET_LPMNYET (0x1u << USB_DEVICE_INTENSET_LPMNYET_Pos) +#define USB_DEVICE_INTENSET_LPMSUSP_Pos 9 /**< \brief (USB_DEVICE_INTENSET) Link Power Management Suspend Interrupt Enable */ +#define USB_DEVICE_INTENSET_LPMSUSP (0x1u << USB_DEVICE_INTENSET_LPMSUSP_Pos) +#define USB_DEVICE_INTENSET_MASK 0x03FFu /**< \brief (USB_DEVICE_INTENSET) MASK Register */ + +/* -------- USB_HOST_INTENSET : (USB Offset: 0x018) (R/W 16) HOST HOST Host Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t :2; /*!< bit: 0.. 1 Reserved */ + uint16_t HSOF:1; /*!< bit: 2 Host Start Of Frame Interrupt Enable */ + uint16_t RST:1; /*!< bit: 3 Bus Reset Interrupt Enable */ + uint16_t WAKEUP:1; /*!< bit: 4 Wake Up Interrupt Enable */ + uint16_t DNRSM:1; /*!< bit: 5 DownStream to the Device Interrupt Enable */ + uint16_t UPRSM:1; /*!< bit: 6 Upstream Resume fromthe device Interrupt Enable */ + uint16_t RAMACER:1; /*!< bit: 7 Ram Access Interrupt Enable */ + uint16_t DCONN:1; /*!< bit: 8 Link Power Management Interrupt Enable */ + uint16_t DDISC:1; /*!< bit: 9 Device Disconnection Interrupt Enable */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_HOST_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_INTENSET_OFFSET 0x018 /**< \brief (USB_HOST_INTENSET offset) HOST Host Interrupt Enable Set */ +#define USB_HOST_INTENSET_RESETVALUE 0x0000 /**< \brief (USB_HOST_INTENSET reset_value) HOST Host Interrupt Enable Set */ + +#define USB_HOST_INTENSET_HSOF_Pos 2 /**< \brief (USB_HOST_INTENSET) Host Start Of Frame Interrupt Enable */ +#define USB_HOST_INTENSET_HSOF (0x1u << USB_HOST_INTENSET_HSOF_Pos) +#define USB_HOST_INTENSET_RST_Pos 3 /**< \brief (USB_HOST_INTENSET) Bus Reset Interrupt Enable */ +#define USB_HOST_INTENSET_RST (0x1u << USB_HOST_INTENSET_RST_Pos) +#define USB_HOST_INTENSET_WAKEUP_Pos 4 /**< \brief (USB_HOST_INTENSET) Wake Up Interrupt Enable */ +#define USB_HOST_INTENSET_WAKEUP (0x1u << USB_HOST_INTENSET_WAKEUP_Pos) +#define USB_HOST_INTENSET_DNRSM_Pos 5 /**< \brief (USB_HOST_INTENSET) DownStream to the Device Interrupt Enable */ +#define USB_HOST_INTENSET_DNRSM (0x1u << USB_HOST_INTENSET_DNRSM_Pos) +#define USB_HOST_INTENSET_UPRSM_Pos 6 /**< \brief (USB_HOST_INTENSET) Upstream Resume fromthe device Interrupt Enable */ +#define USB_HOST_INTENSET_UPRSM (0x1u << USB_HOST_INTENSET_UPRSM_Pos) +#define USB_HOST_INTENSET_RAMACER_Pos 7 /**< \brief (USB_HOST_INTENSET) Ram Access Interrupt Enable */ +#define USB_HOST_INTENSET_RAMACER (0x1u << USB_HOST_INTENSET_RAMACER_Pos) +#define USB_HOST_INTENSET_DCONN_Pos 8 /**< \brief (USB_HOST_INTENSET) Link Power Management Interrupt Enable */ +#define USB_HOST_INTENSET_DCONN (0x1u << USB_HOST_INTENSET_DCONN_Pos) +#define USB_HOST_INTENSET_DDISC_Pos 9 /**< \brief (USB_HOST_INTENSET) Device Disconnection Interrupt Enable */ +#define USB_HOST_INTENSET_DDISC (0x1u << USB_HOST_INTENSET_DDISC_Pos) +#define USB_HOST_INTENSET_MASK 0x03FCu /**< \brief (USB_HOST_INTENSET) MASK Register */ + +/* -------- USB_DEVICE_INTFLAG : (USB Offset: 0x01C) (R/W 16) DEVICE DEVICE Device Interrupt Flag -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SUSPEND:1; /*!< bit: 0 Suspend */ + uint16_t MSOF:1; /*!< bit: 1 Micro Start of Frame in High Speed Mode */ + uint16_t SOF:1; /*!< bit: 2 Start Of Frame */ + uint16_t EORST:1; /*!< bit: 3 End of Reset */ + uint16_t WAKEUP:1; /*!< bit: 4 Wake Up */ + uint16_t EORSM:1; /*!< bit: 5 End Of Resume */ + uint16_t UPRSM:1; /*!< bit: 6 Upstream Resume */ + uint16_t RAMACER:1; /*!< bit: 7 Ram Access */ + uint16_t LPMNYET:1; /*!< bit: 8 Link Power Management Not Yet */ + uint16_t LPMSUSP:1; /*!< bit: 9 Link Power Management Suspend */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_DEVICE_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_INTFLAG_OFFSET 0x01C /**< \brief (USB_DEVICE_INTFLAG offset) DEVICE Device Interrupt Flag */ +#define USB_DEVICE_INTFLAG_RESETVALUE 0x0000 /**< \brief (USB_DEVICE_INTFLAG reset_value) DEVICE Device Interrupt Flag */ + +#define USB_DEVICE_INTFLAG_SUSPEND_Pos 0 /**< \brief (USB_DEVICE_INTFLAG) Suspend */ +#define USB_DEVICE_INTFLAG_SUSPEND (0x1u << USB_DEVICE_INTFLAG_SUSPEND_Pos) +#define USB_DEVICE_INTFLAG_MSOF_Pos 1 /**< \brief (USB_DEVICE_INTFLAG) Micro Start of Frame in High Speed Mode */ +#define USB_DEVICE_INTFLAG_MSOF (0x1u << USB_DEVICE_INTFLAG_MSOF_Pos) +#define USB_DEVICE_INTFLAG_SOF_Pos 2 /**< \brief (USB_DEVICE_INTFLAG) Start Of Frame */ +#define USB_DEVICE_INTFLAG_SOF (0x1u << USB_DEVICE_INTFLAG_SOF_Pos) +#define USB_DEVICE_INTFLAG_EORST_Pos 3 /**< \brief (USB_DEVICE_INTFLAG) End of Reset */ +#define USB_DEVICE_INTFLAG_EORST (0x1u << USB_DEVICE_INTFLAG_EORST_Pos) +#define USB_DEVICE_INTFLAG_WAKEUP_Pos 4 /**< \brief (USB_DEVICE_INTFLAG) Wake Up */ +#define USB_DEVICE_INTFLAG_WAKEUP (0x1u << USB_DEVICE_INTFLAG_WAKEUP_Pos) +#define USB_DEVICE_INTFLAG_EORSM_Pos 5 /**< \brief (USB_DEVICE_INTFLAG) End Of Resume */ +#define USB_DEVICE_INTFLAG_EORSM (0x1u << USB_DEVICE_INTFLAG_EORSM_Pos) +#define USB_DEVICE_INTFLAG_UPRSM_Pos 6 /**< \brief (USB_DEVICE_INTFLAG) Upstream Resume */ +#define USB_DEVICE_INTFLAG_UPRSM (0x1u << USB_DEVICE_INTFLAG_UPRSM_Pos) +#define USB_DEVICE_INTFLAG_RAMACER_Pos 7 /**< \brief (USB_DEVICE_INTFLAG) Ram Access */ +#define USB_DEVICE_INTFLAG_RAMACER (0x1u << USB_DEVICE_INTFLAG_RAMACER_Pos) +#define USB_DEVICE_INTFLAG_LPMNYET_Pos 8 /**< \brief (USB_DEVICE_INTFLAG) Link Power Management Not Yet */ +#define USB_DEVICE_INTFLAG_LPMNYET (0x1u << USB_DEVICE_INTFLAG_LPMNYET_Pos) +#define USB_DEVICE_INTFLAG_LPMSUSP_Pos 9 /**< \brief (USB_DEVICE_INTFLAG) Link Power Management Suspend */ +#define USB_DEVICE_INTFLAG_LPMSUSP (0x1u << USB_DEVICE_INTFLAG_LPMSUSP_Pos) +#define USB_DEVICE_INTFLAG_MASK 0x03FFu /**< \brief (USB_DEVICE_INTFLAG) MASK Register */ + +/* -------- USB_HOST_INTFLAG : (USB Offset: 0x01C) (R/W 16) HOST HOST Host Interrupt Flag -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t :2; /*!< bit: 0.. 1 Reserved */ + uint16_t HSOF:1; /*!< bit: 2 Host Start Of Frame */ + uint16_t RST:1; /*!< bit: 3 Bus Reset */ + uint16_t WAKEUP:1; /*!< bit: 4 Wake Up */ + uint16_t DNRSM:1; /*!< bit: 5 Downstream */ + uint16_t UPRSM:1; /*!< bit: 6 Upstream Resume from the Device */ + uint16_t RAMACER:1; /*!< bit: 7 Ram Access */ + uint16_t DCONN:1; /*!< bit: 8 Device Connection */ + uint16_t DDISC:1; /*!< bit: 9 Device Disconnection */ + uint16_t :6; /*!< bit: 10..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_HOST_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_INTFLAG_OFFSET 0x01C /**< \brief (USB_HOST_INTFLAG offset) HOST Host Interrupt Flag */ +#define USB_HOST_INTFLAG_RESETVALUE 0x0000 /**< \brief (USB_HOST_INTFLAG reset_value) HOST Host Interrupt Flag */ + +#define USB_HOST_INTFLAG_HSOF_Pos 2 /**< \brief (USB_HOST_INTFLAG) Host Start Of Frame */ +#define USB_HOST_INTFLAG_HSOF (0x1u << USB_HOST_INTFLAG_HSOF_Pos) +#define USB_HOST_INTFLAG_RST_Pos 3 /**< \brief (USB_HOST_INTFLAG) Bus Reset */ +#define USB_HOST_INTFLAG_RST (0x1u << USB_HOST_INTFLAG_RST_Pos) +#define USB_HOST_INTFLAG_WAKEUP_Pos 4 /**< \brief (USB_HOST_INTFLAG) Wake Up */ +#define USB_HOST_INTFLAG_WAKEUP (0x1u << USB_HOST_INTFLAG_WAKEUP_Pos) +#define USB_HOST_INTFLAG_DNRSM_Pos 5 /**< \brief (USB_HOST_INTFLAG) Downstream */ +#define USB_HOST_INTFLAG_DNRSM (0x1u << USB_HOST_INTFLAG_DNRSM_Pos) +#define USB_HOST_INTFLAG_UPRSM_Pos 6 /**< \brief (USB_HOST_INTFLAG) Upstream Resume from the Device */ +#define USB_HOST_INTFLAG_UPRSM (0x1u << USB_HOST_INTFLAG_UPRSM_Pos) +#define USB_HOST_INTFLAG_RAMACER_Pos 7 /**< \brief (USB_HOST_INTFLAG) Ram Access */ +#define USB_HOST_INTFLAG_RAMACER (0x1u << USB_HOST_INTFLAG_RAMACER_Pos) +#define USB_HOST_INTFLAG_DCONN_Pos 8 /**< \brief (USB_HOST_INTFLAG) Device Connection */ +#define USB_HOST_INTFLAG_DCONN (0x1u << USB_HOST_INTFLAG_DCONN_Pos) +#define USB_HOST_INTFLAG_DDISC_Pos 9 /**< \brief (USB_HOST_INTFLAG) Device Disconnection */ +#define USB_HOST_INTFLAG_DDISC (0x1u << USB_HOST_INTFLAG_DDISC_Pos) +#define USB_HOST_INTFLAG_MASK 0x03FCu /**< \brief (USB_HOST_INTFLAG) MASK Register */ + +/* -------- USB_DEVICE_EPINTSMRY : (USB Offset: 0x020) (R/ 16) DEVICE DEVICE End Point Interrupt Summary -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t EPINT0:1; /*!< bit: 0 End Point 0 Interrupt */ + uint16_t EPINT1:1; /*!< bit: 1 End Point 1 Interrupt */ + uint16_t EPINT2:1; /*!< bit: 2 End Point 2 Interrupt */ + uint16_t EPINT3:1; /*!< bit: 3 End Point 3 Interrupt */ + uint16_t EPINT4:1; /*!< bit: 4 End Point 4 Interrupt */ + uint16_t EPINT5:1; /*!< bit: 5 End Point 5 Interrupt */ + uint16_t EPINT6:1; /*!< bit: 6 End Point 6 Interrupt */ + uint16_t EPINT7:1; /*!< bit: 7 End Point 7 Interrupt */ + uint16_t :8; /*!< bit: 8..15 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t EPINT:8; /*!< bit: 0.. 7 End Point x Interrupt */ + uint16_t :8; /*!< bit: 8..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} USB_DEVICE_EPINTSMRY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_EPINTSMRY_OFFSET 0x020 /**< \brief (USB_DEVICE_EPINTSMRY offset) DEVICE End Point Interrupt Summary */ +#define USB_DEVICE_EPINTSMRY_RESETVALUE 0x0000 /**< \brief (USB_DEVICE_EPINTSMRY reset_value) DEVICE End Point Interrupt Summary */ + +#define USB_DEVICE_EPINTSMRY_EPINT0_Pos 0 /**< \brief (USB_DEVICE_EPINTSMRY) End Point 0 Interrupt */ +#define USB_DEVICE_EPINTSMRY_EPINT0 (1 << USB_DEVICE_EPINTSMRY_EPINT0_Pos) +#define USB_DEVICE_EPINTSMRY_EPINT1_Pos 1 /**< \brief (USB_DEVICE_EPINTSMRY) End Point 1 Interrupt */ +#define USB_DEVICE_EPINTSMRY_EPINT1 (1 << USB_DEVICE_EPINTSMRY_EPINT1_Pos) +#define USB_DEVICE_EPINTSMRY_EPINT2_Pos 2 /**< \brief (USB_DEVICE_EPINTSMRY) End Point 2 Interrupt */ +#define USB_DEVICE_EPINTSMRY_EPINT2 (1 << USB_DEVICE_EPINTSMRY_EPINT2_Pos) +#define USB_DEVICE_EPINTSMRY_EPINT3_Pos 3 /**< \brief (USB_DEVICE_EPINTSMRY) End Point 3 Interrupt */ +#define USB_DEVICE_EPINTSMRY_EPINT3 (1 << USB_DEVICE_EPINTSMRY_EPINT3_Pos) +#define USB_DEVICE_EPINTSMRY_EPINT4_Pos 4 /**< \brief (USB_DEVICE_EPINTSMRY) End Point 4 Interrupt */ +#define USB_DEVICE_EPINTSMRY_EPINT4 (1 << USB_DEVICE_EPINTSMRY_EPINT4_Pos) +#define USB_DEVICE_EPINTSMRY_EPINT5_Pos 5 /**< \brief (USB_DEVICE_EPINTSMRY) End Point 5 Interrupt */ +#define USB_DEVICE_EPINTSMRY_EPINT5 (1 << USB_DEVICE_EPINTSMRY_EPINT5_Pos) +#define USB_DEVICE_EPINTSMRY_EPINT6_Pos 6 /**< \brief (USB_DEVICE_EPINTSMRY) End Point 6 Interrupt */ +#define USB_DEVICE_EPINTSMRY_EPINT6 (1 << USB_DEVICE_EPINTSMRY_EPINT6_Pos) +#define USB_DEVICE_EPINTSMRY_EPINT7_Pos 7 /**< \brief (USB_DEVICE_EPINTSMRY) End Point 7 Interrupt */ +#define USB_DEVICE_EPINTSMRY_EPINT7 (1 << USB_DEVICE_EPINTSMRY_EPINT7_Pos) +#define USB_DEVICE_EPINTSMRY_EPINT_Pos 0 /**< \brief (USB_DEVICE_EPINTSMRY) End Point x Interrupt */ +#define USB_DEVICE_EPINTSMRY_EPINT_Msk (0xFFu << USB_DEVICE_EPINTSMRY_EPINT_Pos) +#define USB_DEVICE_EPINTSMRY_EPINT(value) ((USB_DEVICE_EPINTSMRY_EPINT_Msk & ((value) << USB_DEVICE_EPINTSMRY_EPINT_Pos))) +#define USB_DEVICE_EPINTSMRY_MASK 0x00FFu /**< \brief (USB_DEVICE_EPINTSMRY) MASK Register */ + +/* -------- USB_HOST_PINTSMRY : (USB Offset: 0x020) (R/ 16) HOST HOST Pipe Interrupt Summary -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t EPINT0:1; /*!< bit: 0 Pipe 0 Interrupt */ + uint16_t EPINT1:1; /*!< bit: 1 Pipe 1 Interrupt */ + uint16_t EPINT2:1; /*!< bit: 2 Pipe 2 Interrupt */ + uint16_t EPINT3:1; /*!< bit: 3 Pipe 3 Interrupt */ + uint16_t EPINT4:1; /*!< bit: 4 Pipe 4 Interrupt */ + uint16_t EPINT5:1; /*!< bit: 5 Pipe 5 Interrupt */ + uint16_t EPINT6:1; /*!< bit: 6 Pipe 6 Interrupt */ + uint16_t EPINT7:1; /*!< bit: 7 Pipe 7 Interrupt */ + uint16_t :8; /*!< bit: 8..15 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint16_t EPINT:8; /*!< bit: 0.. 7 Pipe x Interrupt */ + uint16_t :8; /*!< bit: 8..15 Reserved */ + } vec; /*!< Structure used for vec access */ + uint16_t reg; /*!< Type used for register access */ +} USB_HOST_PINTSMRY_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_PINTSMRY_OFFSET 0x020 /**< \brief (USB_HOST_PINTSMRY offset) HOST Pipe Interrupt Summary */ +#define USB_HOST_PINTSMRY_RESETVALUE 0x0000 /**< \brief (USB_HOST_PINTSMRY reset_value) HOST Pipe Interrupt Summary */ + +#define USB_HOST_PINTSMRY_EPINT0_Pos 0 /**< \brief (USB_HOST_PINTSMRY) Pipe 0 Interrupt */ +#define USB_HOST_PINTSMRY_EPINT0 (1 << USB_HOST_PINTSMRY_EPINT0_Pos) +#define USB_HOST_PINTSMRY_EPINT1_Pos 1 /**< \brief (USB_HOST_PINTSMRY) Pipe 1 Interrupt */ +#define USB_HOST_PINTSMRY_EPINT1 (1 << USB_HOST_PINTSMRY_EPINT1_Pos) +#define USB_HOST_PINTSMRY_EPINT2_Pos 2 /**< \brief (USB_HOST_PINTSMRY) Pipe 2 Interrupt */ +#define USB_HOST_PINTSMRY_EPINT2 (1 << USB_HOST_PINTSMRY_EPINT2_Pos) +#define USB_HOST_PINTSMRY_EPINT3_Pos 3 /**< \brief (USB_HOST_PINTSMRY) Pipe 3 Interrupt */ +#define USB_HOST_PINTSMRY_EPINT3 (1 << USB_HOST_PINTSMRY_EPINT3_Pos) +#define USB_HOST_PINTSMRY_EPINT4_Pos 4 /**< \brief (USB_HOST_PINTSMRY) Pipe 4 Interrupt */ +#define USB_HOST_PINTSMRY_EPINT4 (1 << USB_HOST_PINTSMRY_EPINT4_Pos) +#define USB_HOST_PINTSMRY_EPINT5_Pos 5 /**< \brief (USB_HOST_PINTSMRY) Pipe 5 Interrupt */ +#define USB_HOST_PINTSMRY_EPINT5 (1 << USB_HOST_PINTSMRY_EPINT5_Pos) +#define USB_HOST_PINTSMRY_EPINT6_Pos 6 /**< \brief (USB_HOST_PINTSMRY) Pipe 6 Interrupt */ +#define USB_HOST_PINTSMRY_EPINT6 (1 << USB_HOST_PINTSMRY_EPINT6_Pos) +#define USB_HOST_PINTSMRY_EPINT7_Pos 7 /**< \brief (USB_HOST_PINTSMRY) Pipe 7 Interrupt */ +#define USB_HOST_PINTSMRY_EPINT7 (1 << USB_HOST_PINTSMRY_EPINT7_Pos) +#define USB_HOST_PINTSMRY_EPINT_Pos 0 /**< \brief (USB_HOST_PINTSMRY) Pipe x Interrupt */ +#define USB_HOST_PINTSMRY_EPINT_Msk (0xFFu << USB_HOST_PINTSMRY_EPINT_Pos) +#define USB_HOST_PINTSMRY_EPINT(value) ((USB_HOST_PINTSMRY_EPINT_Msk & ((value) << USB_HOST_PINTSMRY_EPINT_Pos))) +#define USB_HOST_PINTSMRY_MASK 0x00FFu /**< \brief (USB_HOST_PINTSMRY) MASK Register */ + +/* -------- USB_DESCADD : (USB Offset: 0x024) (R/W 32) Descriptor Address -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t DESCADD:32; /*!< bit: 0..31 Descriptor Address Value */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} USB_DESCADD_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DESCADD_OFFSET 0x024 /**< \brief (USB_DESCADD offset) Descriptor Address */ +#define USB_DESCADD_RESETVALUE 0x00000000 /**< \brief (USB_DESCADD reset_value) Descriptor Address */ + +#define USB_DESCADD_DESCADD_Pos 0 /**< \brief (USB_DESCADD) Descriptor Address Value */ +#define USB_DESCADD_DESCADD_Msk (0xFFFFFFFFu << USB_DESCADD_DESCADD_Pos) +#define USB_DESCADD_DESCADD(value) ((USB_DESCADD_DESCADD_Msk & ((value) << USB_DESCADD_DESCADD_Pos))) +#define USB_DESCADD_MASK 0xFFFFFFFFu /**< \brief (USB_DESCADD) MASK Register */ + +/* -------- USB_PADCAL : (USB Offset: 0x028) (R/W 16) USB PAD Calibration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t TRANSP:5; /*!< bit: 0.. 4 USB Pad Transp calibration */ + uint16_t :1; /*!< bit: 5 Reserved */ + uint16_t TRANSN:5; /*!< bit: 6..10 USB Pad Transn calibration */ + uint16_t :1; /*!< bit: 11 Reserved */ + uint16_t TRIM:3; /*!< bit: 12..14 USB Pad Trim calibration */ + uint16_t :1; /*!< bit: 15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_PADCAL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_PADCAL_OFFSET 0x028 /**< \brief (USB_PADCAL offset) USB PAD Calibration */ +#define USB_PADCAL_RESETVALUE 0x0000 /**< \brief (USB_PADCAL reset_value) USB PAD Calibration */ + +#define USB_PADCAL_TRANSP_Pos 0 /**< \brief (USB_PADCAL) USB Pad Transp calibration */ +#define USB_PADCAL_TRANSP_Msk (0x1Fu << USB_PADCAL_TRANSP_Pos) +#define USB_PADCAL_TRANSP(value) ((USB_PADCAL_TRANSP_Msk & ((value) << USB_PADCAL_TRANSP_Pos))) +#define USB_PADCAL_TRANSN_Pos 6 /**< \brief (USB_PADCAL) USB Pad Transn calibration */ +#define USB_PADCAL_TRANSN_Msk (0x1Fu << USB_PADCAL_TRANSN_Pos) +#define USB_PADCAL_TRANSN(value) ((USB_PADCAL_TRANSN_Msk & ((value) << USB_PADCAL_TRANSN_Pos))) +#define USB_PADCAL_TRIM_Pos 12 /**< \brief (USB_PADCAL) USB Pad Trim calibration */ +#define USB_PADCAL_TRIM_Msk (0x7u << USB_PADCAL_TRIM_Pos) +#define USB_PADCAL_TRIM(value) ((USB_PADCAL_TRIM_Msk & ((value) << USB_PADCAL_TRIM_Pos))) +#define USB_PADCAL_MASK 0x77DFu /**< \brief (USB_PADCAL) MASK Register */ + +/* -------- USB_DEVICE_EPCFG : (USB Offset: 0x100) (R/W 8) DEVICE DEVICE_ENDPOINT End Point Configuration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t EPTYPE0:3; /*!< bit: 0.. 2 End Point Type0 */ + uint8_t :1; /*!< bit: 3 Reserved */ + uint8_t EPTYPE1:3; /*!< bit: 4.. 6 End Point Type1 */ + uint8_t NYETDIS:1; /*!< bit: 7 NYET Token Disable */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_EPCFG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_EPCFG_OFFSET 0x100 /**< \brief (USB_DEVICE_EPCFG offset) DEVICE_ENDPOINT End Point Configuration */ +#define USB_DEVICE_EPCFG_RESETVALUE 0x00 /**< \brief (USB_DEVICE_EPCFG reset_value) DEVICE_ENDPOINT End Point Configuration */ + +#define USB_DEVICE_EPCFG_EPTYPE0_Pos 0 /**< \brief (USB_DEVICE_EPCFG) End Point Type0 */ +#define USB_DEVICE_EPCFG_EPTYPE0_Msk (0x7u << USB_DEVICE_EPCFG_EPTYPE0_Pos) +#define USB_DEVICE_EPCFG_EPTYPE0(value) ((USB_DEVICE_EPCFG_EPTYPE0_Msk & ((value) << USB_DEVICE_EPCFG_EPTYPE0_Pos))) +#define USB_DEVICE_EPCFG_EPTYPE1_Pos 4 /**< \brief (USB_DEVICE_EPCFG) End Point Type1 */ +#define USB_DEVICE_EPCFG_EPTYPE1_Msk (0x7u << USB_DEVICE_EPCFG_EPTYPE1_Pos) +#define USB_DEVICE_EPCFG_EPTYPE1(value) ((USB_DEVICE_EPCFG_EPTYPE1_Msk & ((value) << USB_DEVICE_EPCFG_EPTYPE1_Pos))) +#define USB_DEVICE_EPCFG_NYETDIS_Pos 7 /**< \brief (USB_DEVICE_EPCFG) NYET Token Disable */ +#define USB_DEVICE_EPCFG_NYETDIS (0x1u << USB_DEVICE_EPCFG_NYETDIS_Pos) +#define USB_DEVICE_EPCFG_MASK 0xF7u /**< \brief (USB_DEVICE_EPCFG) MASK Register */ + +/* -------- USB_HOST_PCFG : (USB Offset: 0x100) (R/W 8) HOST HOST_PIPE End Point Configuration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PTOKEN:2; /*!< bit: 0.. 1 Pipe Token */ + uint8_t BK:1; /*!< bit: 2 Pipe Bank */ + uint8_t PTYPE:3; /*!< bit: 3.. 5 Pipe Type */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_PCFG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_PCFG_OFFSET 0x100 /**< \brief (USB_HOST_PCFG offset) HOST_PIPE End Point Configuration */ +#define USB_HOST_PCFG_RESETVALUE 0x00 /**< \brief (USB_HOST_PCFG reset_value) HOST_PIPE End Point Configuration */ + +#define USB_HOST_PCFG_PTOKEN_Pos 0 /**< \brief (USB_HOST_PCFG) Pipe Token */ +#define USB_HOST_PCFG_PTOKEN_Msk (0x3u << USB_HOST_PCFG_PTOKEN_Pos) +#define USB_HOST_PCFG_PTOKEN(value) ((USB_HOST_PCFG_PTOKEN_Msk & ((value) << USB_HOST_PCFG_PTOKEN_Pos))) +#define USB_HOST_PCFG_BK_Pos 2 /**< \brief (USB_HOST_PCFG) Pipe Bank */ +#define USB_HOST_PCFG_BK (0x1u << USB_HOST_PCFG_BK_Pos) +#define USB_HOST_PCFG_PTYPE_Pos 3 /**< \brief (USB_HOST_PCFG) Pipe Type */ +#define USB_HOST_PCFG_PTYPE_Msk (0x7u << USB_HOST_PCFG_PTYPE_Pos) +#define USB_HOST_PCFG_PTYPE(value) ((USB_HOST_PCFG_PTYPE_Msk & ((value) << USB_HOST_PCFG_PTYPE_Pos))) +#define USB_HOST_PCFG_MASK 0x3Fu /**< \brief (USB_HOST_PCFG) MASK Register */ + +/* -------- USB_HOST_BINTERVAL : (USB Offset: 0x103) (R/W 8) HOST HOST_PIPE Bus Access Period of Pipe -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t BITINTERVAL:8; /*!< bit: 0.. 7 Bit Interval */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_BINTERVAL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_BINTERVAL_OFFSET 0x103 /**< \brief (USB_HOST_BINTERVAL offset) HOST_PIPE Bus Access Period of Pipe */ +#define USB_HOST_BINTERVAL_RESETVALUE 0x00 /**< \brief (USB_HOST_BINTERVAL reset_value) HOST_PIPE Bus Access Period of Pipe */ + +#define USB_HOST_BINTERVAL_BITINTERVAL_Pos 0 /**< \brief (USB_HOST_BINTERVAL) Bit Interval */ +#define USB_HOST_BINTERVAL_BITINTERVAL_Msk (0xFFu << USB_HOST_BINTERVAL_BITINTERVAL_Pos) +#define USB_HOST_BINTERVAL_BITINTERVAL(value) ((USB_HOST_BINTERVAL_BITINTERVAL_Msk & ((value) << USB_HOST_BINTERVAL_BITINTERVAL_Pos))) +#define USB_HOST_BINTERVAL_MASK 0xFFu /**< \brief (USB_HOST_BINTERVAL) MASK Register */ + +/* -------- USB_DEVICE_EPSTATUSCLR : (USB Offset: 0x104) ( /W 8) DEVICE DEVICE_ENDPOINT End Point Pipe Status Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DTGLOUT:1; /*!< bit: 0 Data Toggle OUT Clear */ + uint8_t DTGLIN:1; /*!< bit: 1 Data Toggle IN Clear */ + uint8_t CURBK:1; /*!< bit: 2 Curren Bank Clear */ + uint8_t :1; /*!< bit: 3 Reserved */ + uint8_t STALLRQ0:1; /*!< bit: 4 Stall 0 Request Clear */ + uint8_t STALLRQ1:1; /*!< bit: 5 Stall 1 Request Clear */ + uint8_t BK0RDY:1; /*!< bit: 6 Bank 0 Ready Clear */ + uint8_t BK1RDY:1; /*!< bit: 7 Bank 1 Ready Clear */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t :4; /*!< bit: 0.. 3 Reserved */ + uint8_t STALLRQ:2; /*!< bit: 4.. 5 Stall x Request Clear */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_EPSTATUSCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_EPSTATUSCLR_OFFSET 0x104 /**< \brief (USB_DEVICE_EPSTATUSCLR offset) DEVICE_ENDPOINT End Point Pipe Status Clear */ +#define USB_DEVICE_EPSTATUSCLR_RESETVALUE 0x00 /**< \brief (USB_DEVICE_EPSTATUSCLR reset_value) DEVICE_ENDPOINT End Point Pipe Status Clear */ + +#define USB_DEVICE_EPSTATUSCLR_DTGLOUT_Pos 0 /**< \brief (USB_DEVICE_EPSTATUSCLR) Data Toggle OUT Clear */ +#define USB_DEVICE_EPSTATUSCLR_DTGLOUT (0x1u << USB_DEVICE_EPSTATUSCLR_DTGLOUT_Pos) +#define USB_DEVICE_EPSTATUSCLR_DTGLIN_Pos 1 /**< \brief (USB_DEVICE_EPSTATUSCLR) Data Toggle IN Clear */ +#define USB_DEVICE_EPSTATUSCLR_DTGLIN (0x1u << USB_DEVICE_EPSTATUSCLR_DTGLIN_Pos) +#define USB_DEVICE_EPSTATUSCLR_CURBK_Pos 2 /**< \brief (USB_DEVICE_EPSTATUSCLR) Curren Bank Clear */ +#define USB_DEVICE_EPSTATUSCLR_CURBK (0x1u << USB_DEVICE_EPSTATUSCLR_CURBK_Pos) +#define USB_DEVICE_EPSTATUSCLR_STALLRQ0_Pos 4 /**< \brief (USB_DEVICE_EPSTATUSCLR) Stall 0 Request Clear */ +#define USB_DEVICE_EPSTATUSCLR_STALLRQ0 (1 << USB_DEVICE_EPSTATUSCLR_STALLRQ0_Pos) +#define USB_DEVICE_EPSTATUSCLR_STALLRQ1_Pos 5 /**< \brief (USB_DEVICE_EPSTATUSCLR) Stall 1 Request Clear */ +#define USB_DEVICE_EPSTATUSCLR_STALLRQ1 (1 << USB_DEVICE_EPSTATUSCLR_STALLRQ1_Pos) +#define USB_DEVICE_EPSTATUSCLR_STALLRQ_Pos 4 /**< \brief (USB_DEVICE_EPSTATUSCLR) Stall x Request Clear */ +#define USB_DEVICE_EPSTATUSCLR_STALLRQ_Msk (0x3u << USB_DEVICE_EPSTATUSCLR_STALLRQ_Pos) +#define USB_DEVICE_EPSTATUSCLR_STALLRQ(value) ((USB_DEVICE_EPSTATUSCLR_STALLRQ_Msk & ((value) << USB_DEVICE_EPSTATUSCLR_STALLRQ_Pos))) +#define USB_DEVICE_EPSTATUSCLR_BK0RDY_Pos 6 /**< \brief (USB_DEVICE_EPSTATUSCLR) Bank 0 Ready Clear */ +#define USB_DEVICE_EPSTATUSCLR_BK0RDY (0x1u << USB_DEVICE_EPSTATUSCLR_BK0RDY_Pos) +#define USB_DEVICE_EPSTATUSCLR_BK1RDY_Pos 7 /**< \brief (USB_DEVICE_EPSTATUSCLR) Bank 1 Ready Clear */ +#define USB_DEVICE_EPSTATUSCLR_BK1RDY (0x1u << USB_DEVICE_EPSTATUSCLR_BK1RDY_Pos) +#define USB_DEVICE_EPSTATUSCLR_MASK 0xF7u /**< \brief (USB_DEVICE_EPSTATUSCLR) MASK Register */ + +/* -------- USB_HOST_PSTATUSCLR : (USB Offset: 0x104) ( /W 8) HOST HOST_PIPE End Point Pipe Status Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DTGL:1; /*!< bit: 0 Data Toggle clear */ + uint8_t :1; /*!< bit: 1 Reserved */ + uint8_t CURBK:1; /*!< bit: 2 Curren Bank clear */ + uint8_t :1; /*!< bit: 3 Reserved */ + uint8_t PFREEZE:1; /*!< bit: 4 Pipe Freeze Clear */ + uint8_t :1; /*!< bit: 5 Reserved */ + uint8_t BK0RDY:1; /*!< bit: 6 Bank 0 Ready Clear */ + uint8_t BK1RDY:1; /*!< bit: 7 Bank 1 Ready Clear */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_PSTATUSCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_PSTATUSCLR_OFFSET 0x104 /**< \brief (USB_HOST_PSTATUSCLR offset) HOST_PIPE End Point Pipe Status Clear */ +#define USB_HOST_PSTATUSCLR_RESETVALUE 0x00 /**< \brief (USB_HOST_PSTATUSCLR reset_value) HOST_PIPE End Point Pipe Status Clear */ + +#define USB_HOST_PSTATUSCLR_DTGL_Pos 0 /**< \brief (USB_HOST_PSTATUSCLR) Data Toggle clear */ +#define USB_HOST_PSTATUSCLR_DTGL (0x1u << USB_HOST_PSTATUSCLR_DTGL_Pos) +#define USB_HOST_PSTATUSCLR_CURBK_Pos 2 /**< \brief (USB_HOST_PSTATUSCLR) Curren Bank clear */ +#define USB_HOST_PSTATUSCLR_CURBK (0x1u << USB_HOST_PSTATUSCLR_CURBK_Pos) +#define USB_HOST_PSTATUSCLR_PFREEZE_Pos 4 /**< \brief (USB_HOST_PSTATUSCLR) Pipe Freeze Clear */ +#define USB_HOST_PSTATUSCLR_PFREEZE (0x1u << USB_HOST_PSTATUSCLR_PFREEZE_Pos) +#define USB_HOST_PSTATUSCLR_BK0RDY_Pos 6 /**< \brief (USB_HOST_PSTATUSCLR) Bank 0 Ready Clear */ +#define USB_HOST_PSTATUSCLR_BK0RDY (0x1u << USB_HOST_PSTATUSCLR_BK0RDY_Pos) +#define USB_HOST_PSTATUSCLR_BK1RDY_Pos 7 /**< \brief (USB_HOST_PSTATUSCLR) Bank 1 Ready Clear */ +#define USB_HOST_PSTATUSCLR_BK1RDY (0x1u << USB_HOST_PSTATUSCLR_BK1RDY_Pos) +#define USB_HOST_PSTATUSCLR_MASK 0xD5u /**< \brief (USB_HOST_PSTATUSCLR) MASK Register */ + +/* -------- USB_DEVICE_EPSTATUSSET : (USB Offset: 0x105) ( /W 8) DEVICE DEVICE_ENDPOINT End Point Pipe Status Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DTGLOUT:1; /*!< bit: 0 Data Toggle OUT Set */ + uint8_t DTGLIN:1; /*!< bit: 1 Data Toggle IN Set */ + uint8_t CURBK:1; /*!< bit: 2 Current Bank Set */ + uint8_t :1; /*!< bit: 3 Reserved */ + uint8_t STALLRQ0:1; /*!< bit: 4 Stall 0 Request Set */ + uint8_t STALLRQ1:1; /*!< bit: 5 Stall 1 Request Set */ + uint8_t BK0RDY:1; /*!< bit: 6 Bank 0 Ready Set */ + uint8_t BK1RDY:1; /*!< bit: 7 Bank 1 Ready Set */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t :4; /*!< bit: 0.. 3 Reserved */ + uint8_t STALLRQ:2; /*!< bit: 4.. 5 Stall x Request Set */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_EPSTATUSSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_EPSTATUSSET_OFFSET 0x105 /**< \brief (USB_DEVICE_EPSTATUSSET offset) DEVICE_ENDPOINT End Point Pipe Status Set */ +#define USB_DEVICE_EPSTATUSSET_RESETVALUE 0x00 /**< \brief (USB_DEVICE_EPSTATUSSET reset_value) DEVICE_ENDPOINT End Point Pipe Status Set */ + +#define USB_DEVICE_EPSTATUSSET_DTGLOUT_Pos 0 /**< \brief (USB_DEVICE_EPSTATUSSET) Data Toggle OUT Set */ +#define USB_DEVICE_EPSTATUSSET_DTGLOUT (0x1u << USB_DEVICE_EPSTATUSSET_DTGLOUT_Pos) +#define USB_DEVICE_EPSTATUSSET_DTGLIN_Pos 1 /**< \brief (USB_DEVICE_EPSTATUSSET) Data Toggle IN Set */ +#define USB_DEVICE_EPSTATUSSET_DTGLIN (0x1u << USB_DEVICE_EPSTATUSSET_DTGLIN_Pos) +#define USB_DEVICE_EPSTATUSSET_CURBK_Pos 2 /**< \brief (USB_DEVICE_EPSTATUSSET) Current Bank Set */ +#define USB_DEVICE_EPSTATUSSET_CURBK (0x1u << USB_DEVICE_EPSTATUSSET_CURBK_Pos) +#define USB_DEVICE_EPSTATUSSET_STALLRQ0_Pos 4 /**< \brief (USB_DEVICE_EPSTATUSSET) Stall 0 Request Set */ +#define USB_DEVICE_EPSTATUSSET_STALLRQ0 (1 << USB_DEVICE_EPSTATUSSET_STALLRQ0_Pos) +#define USB_DEVICE_EPSTATUSSET_STALLRQ1_Pos 5 /**< \brief (USB_DEVICE_EPSTATUSSET) Stall 1 Request Set */ +#define USB_DEVICE_EPSTATUSSET_STALLRQ1 (1 << USB_DEVICE_EPSTATUSSET_STALLRQ1_Pos) +#define USB_DEVICE_EPSTATUSSET_STALLRQ_Pos 4 /**< \brief (USB_DEVICE_EPSTATUSSET) Stall x Request Set */ +#define USB_DEVICE_EPSTATUSSET_STALLRQ_Msk (0x3u << USB_DEVICE_EPSTATUSSET_STALLRQ_Pos) +#define USB_DEVICE_EPSTATUSSET_STALLRQ(value) ((USB_DEVICE_EPSTATUSSET_STALLRQ_Msk & ((value) << USB_DEVICE_EPSTATUSSET_STALLRQ_Pos))) +#define USB_DEVICE_EPSTATUSSET_BK0RDY_Pos 6 /**< \brief (USB_DEVICE_EPSTATUSSET) Bank 0 Ready Set */ +#define USB_DEVICE_EPSTATUSSET_BK0RDY (0x1u << USB_DEVICE_EPSTATUSSET_BK0RDY_Pos) +#define USB_DEVICE_EPSTATUSSET_BK1RDY_Pos 7 /**< \brief (USB_DEVICE_EPSTATUSSET) Bank 1 Ready Set */ +#define USB_DEVICE_EPSTATUSSET_BK1RDY (0x1u << USB_DEVICE_EPSTATUSSET_BK1RDY_Pos) +#define USB_DEVICE_EPSTATUSSET_MASK 0xF7u /**< \brief (USB_DEVICE_EPSTATUSSET) MASK Register */ + +/* -------- USB_HOST_PSTATUSSET : (USB Offset: 0x105) ( /W 8) HOST HOST_PIPE End Point Pipe Status Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DTGL:1; /*!< bit: 0 Data Toggle Set */ + uint8_t :1; /*!< bit: 1 Reserved */ + uint8_t CURBK:1; /*!< bit: 2 Current Bank Set */ + uint8_t :1; /*!< bit: 3 Reserved */ + uint8_t PFREEZE:1; /*!< bit: 4 Pipe Freeze Set */ + uint8_t :1; /*!< bit: 5 Reserved */ + uint8_t BK0RDY:1; /*!< bit: 6 Bank 0 Ready Set */ + uint8_t BK1RDY:1; /*!< bit: 7 Bank 1 Ready Set */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_PSTATUSSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_PSTATUSSET_OFFSET 0x105 /**< \brief (USB_HOST_PSTATUSSET offset) HOST_PIPE End Point Pipe Status Set */ +#define USB_HOST_PSTATUSSET_RESETVALUE 0x00 /**< \brief (USB_HOST_PSTATUSSET reset_value) HOST_PIPE End Point Pipe Status Set */ + +#define USB_HOST_PSTATUSSET_DTGL_Pos 0 /**< \brief (USB_HOST_PSTATUSSET) Data Toggle Set */ +#define USB_HOST_PSTATUSSET_DTGL (0x1u << USB_HOST_PSTATUSSET_DTGL_Pos) +#define USB_HOST_PSTATUSSET_CURBK_Pos 2 /**< \brief (USB_HOST_PSTATUSSET) Current Bank Set */ +#define USB_HOST_PSTATUSSET_CURBK (0x1u << USB_HOST_PSTATUSSET_CURBK_Pos) +#define USB_HOST_PSTATUSSET_PFREEZE_Pos 4 /**< \brief (USB_HOST_PSTATUSSET) Pipe Freeze Set */ +#define USB_HOST_PSTATUSSET_PFREEZE (0x1u << USB_HOST_PSTATUSSET_PFREEZE_Pos) +#define USB_HOST_PSTATUSSET_BK0RDY_Pos 6 /**< \brief (USB_HOST_PSTATUSSET) Bank 0 Ready Set */ +#define USB_HOST_PSTATUSSET_BK0RDY (0x1u << USB_HOST_PSTATUSSET_BK0RDY_Pos) +#define USB_HOST_PSTATUSSET_BK1RDY_Pos 7 /**< \brief (USB_HOST_PSTATUSSET) Bank 1 Ready Set */ +#define USB_HOST_PSTATUSSET_BK1RDY (0x1u << USB_HOST_PSTATUSSET_BK1RDY_Pos) +#define USB_HOST_PSTATUSSET_MASK 0xD5u /**< \brief (USB_HOST_PSTATUSSET) MASK Register */ + +/* -------- USB_DEVICE_EPSTATUS : (USB Offset: 0x106) (R/ 8) DEVICE DEVICE_ENDPOINT End Point Pipe Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DTGLOUT:1; /*!< bit: 0 Data Toggle Out */ + uint8_t DTGLIN:1; /*!< bit: 1 Data Toggle In */ + uint8_t CURBK:1; /*!< bit: 2 Current Bank */ + uint8_t :1; /*!< bit: 3 Reserved */ + uint8_t STALLRQ0:1; /*!< bit: 4 Stall 0 Request */ + uint8_t STALLRQ1:1; /*!< bit: 5 Stall 1 Request */ + uint8_t BK0RDY:1; /*!< bit: 6 Bank 0 ready */ + uint8_t BK1RDY:1; /*!< bit: 7 Bank 1 ready */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t :4; /*!< bit: 0.. 3 Reserved */ + uint8_t STALLRQ:2; /*!< bit: 4.. 5 Stall x Request */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_EPSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_EPSTATUS_OFFSET 0x106 /**< \brief (USB_DEVICE_EPSTATUS offset) DEVICE_ENDPOINT End Point Pipe Status */ +#define USB_DEVICE_EPSTATUS_RESETVALUE 0x00 /**< \brief (USB_DEVICE_EPSTATUS reset_value) DEVICE_ENDPOINT End Point Pipe Status */ + +#define USB_DEVICE_EPSTATUS_DTGLOUT_Pos 0 /**< \brief (USB_DEVICE_EPSTATUS) Data Toggle Out */ +#define USB_DEVICE_EPSTATUS_DTGLOUT (0x1u << USB_DEVICE_EPSTATUS_DTGLOUT_Pos) +#define USB_DEVICE_EPSTATUS_DTGLIN_Pos 1 /**< \brief (USB_DEVICE_EPSTATUS) Data Toggle In */ +#define USB_DEVICE_EPSTATUS_DTGLIN (0x1u << USB_DEVICE_EPSTATUS_DTGLIN_Pos) +#define USB_DEVICE_EPSTATUS_CURBK_Pos 2 /**< \brief (USB_DEVICE_EPSTATUS) Current Bank */ +#define USB_DEVICE_EPSTATUS_CURBK (0x1u << USB_DEVICE_EPSTATUS_CURBK_Pos) +#define USB_DEVICE_EPSTATUS_STALLRQ0_Pos 4 /**< \brief (USB_DEVICE_EPSTATUS) Stall 0 Request */ +#define USB_DEVICE_EPSTATUS_STALLRQ0 (1 << USB_DEVICE_EPSTATUS_STALLRQ0_Pos) +#define USB_DEVICE_EPSTATUS_STALLRQ1_Pos 5 /**< \brief (USB_DEVICE_EPSTATUS) Stall 1 Request */ +#define USB_DEVICE_EPSTATUS_STALLRQ1 (1 << USB_DEVICE_EPSTATUS_STALLRQ1_Pos) +#define USB_DEVICE_EPSTATUS_STALLRQ_Pos 4 /**< \brief (USB_DEVICE_EPSTATUS) Stall x Request */ +#define USB_DEVICE_EPSTATUS_STALLRQ_Msk (0x3u << USB_DEVICE_EPSTATUS_STALLRQ_Pos) +#define USB_DEVICE_EPSTATUS_STALLRQ(value) ((USB_DEVICE_EPSTATUS_STALLRQ_Msk & ((value) << USB_DEVICE_EPSTATUS_STALLRQ_Pos))) +#define USB_DEVICE_EPSTATUS_BK0RDY_Pos 6 /**< \brief (USB_DEVICE_EPSTATUS) Bank 0 ready */ +#define USB_DEVICE_EPSTATUS_BK0RDY (0x1u << USB_DEVICE_EPSTATUS_BK0RDY_Pos) +#define USB_DEVICE_EPSTATUS_BK1RDY_Pos 7 /**< \brief (USB_DEVICE_EPSTATUS) Bank 1 ready */ +#define USB_DEVICE_EPSTATUS_BK1RDY (0x1u << USB_DEVICE_EPSTATUS_BK1RDY_Pos) +#define USB_DEVICE_EPSTATUS_MASK 0xF7u /**< \brief (USB_DEVICE_EPSTATUS) MASK Register */ + +/* -------- USB_HOST_PSTATUS : (USB Offset: 0x106) (R/ 8) HOST HOST_PIPE End Point Pipe Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t DTGL:1; /*!< bit: 0 Data Toggle */ + uint8_t :1; /*!< bit: 1 Reserved */ + uint8_t CURBK:1; /*!< bit: 2 Current Bank */ + uint8_t :1; /*!< bit: 3 Reserved */ + uint8_t PFREEZE:1; /*!< bit: 4 Pipe Freeze */ + uint8_t :1; /*!< bit: 5 Reserved */ + uint8_t BK0RDY:1; /*!< bit: 6 Bank 0 ready */ + uint8_t BK1RDY:1; /*!< bit: 7 Bank 1 ready */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_PSTATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_PSTATUS_OFFSET 0x106 /**< \brief (USB_HOST_PSTATUS offset) HOST_PIPE End Point Pipe Status */ +#define USB_HOST_PSTATUS_RESETVALUE 0x00 /**< \brief (USB_HOST_PSTATUS reset_value) HOST_PIPE End Point Pipe Status */ + +#define USB_HOST_PSTATUS_DTGL_Pos 0 /**< \brief (USB_HOST_PSTATUS) Data Toggle */ +#define USB_HOST_PSTATUS_DTGL (0x1u << USB_HOST_PSTATUS_DTGL_Pos) +#define USB_HOST_PSTATUS_CURBK_Pos 2 /**< \brief (USB_HOST_PSTATUS) Current Bank */ +#define USB_HOST_PSTATUS_CURBK (0x1u << USB_HOST_PSTATUS_CURBK_Pos) +#define USB_HOST_PSTATUS_PFREEZE_Pos 4 /**< \brief (USB_HOST_PSTATUS) Pipe Freeze */ +#define USB_HOST_PSTATUS_PFREEZE (0x1u << USB_HOST_PSTATUS_PFREEZE_Pos) +#define USB_HOST_PSTATUS_BK0RDY_Pos 6 /**< \brief (USB_HOST_PSTATUS) Bank 0 ready */ +#define USB_HOST_PSTATUS_BK0RDY (0x1u << USB_HOST_PSTATUS_BK0RDY_Pos) +#define USB_HOST_PSTATUS_BK1RDY_Pos 7 /**< \brief (USB_HOST_PSTATUS) Bank 1 ready */ +#define USB_HOST_PSTATUS_BK1RDY (0x1u << USB_HOST_PSTATUS_BK1RDY_Pos) +#define USB_HOST_PSTATUS_MASK 0xD5u /**< \brief (USB_HOST_PSTATUS) MASK Register */ + +/* -------- USB_DEVICE_EPINTFLAG : (USB Offset: 0x107) (R/W 8) DEVICE DEVICE_ENDPOINT End Point Interrupt Flag -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t TRCPT0:1; /*!< bit: 0 Transfer Complete 0 */ + uint8_t TRCPT1:1; /*!< bit: 1 Transfer Complete 1 */ + uint8_t TRFAIL0:1; /*!< bit: 2 Error Flow 0 */ + uint8_t TRFAIL1:1; /*!< bit: 3 Error Flow 1 */ + uint8_t RXSTP:1; /*!< bit: 4 Received Setup */ + uint8_t STALL0:1; /*!< bit: 5 Stall 0 In/out */ + uint8_t STALL1:1; /*!< bit: 6 Stall 1 In/out */ + uint8_t :1; /*!< bit: 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t TRCPT:2; /*!< bit: 0.. 1 Transfer Complete x */ + uint8_t TRFAIL:2; /*!< bit: 2.. 3 Error Flow x */ + uint8_t :1; /*!< bit: 4 Reserved */ + uint8_t STALL:2; /*!< bit: 5.. 6 Stall x In/out */ + uint8_t :1; /*!< bit: 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_EPINTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_EPINTFLAG_OFFSET 0x107 /**< \brief (USB_DEVICE_EPINTFLAG offset) DEVICE_ENDPOINT End Point Interrupt Flag */ +#define USB_DEVICE_EPINTFLAG_RESETVALUE 0x00 /**< \brief (USB_DEVICE_EPINTFLAG reset_value) DEVICE_ENDPOINT End Point Interrupt Flag */ + +#define USB_DEVICE_EPINTFLAG_TRCPT0_Pos 0 /**< \brief (USB_DEVICE_EPINTFLAG) Transfer Complete 0 */ +#define USB_DEVICE_EPINTFLAG_TRCPT0 (1 << USB_DEVICE_EPINTFLAG_TRCPT0_Pos) +#define USB_DEVICE_EPINTFLAG_TRCPT1_Pos 1 /**< \brief (USB_DEVICE_EPINTFLAG) Transfer Complete 1 */ +#define USB_DEVICE_EPINTFLAG_TRCPT1 (1 << USB_DEVICE_EPINTFLAG_TRCPT1_Pos) +#define USB_DEVICE_EPINTFLAG_TRCPT_Pos 0 /**< \brief (USB_DEVICE_EPINTFLAG) Transfer Complete x */ +#define USB_DEVICE_EPINTFLAG_TRCPT_Msk (0x3u << USB_DEVICE_EPINTFLAG_TRCPT_Pos) +#define USB_DEVICE_EPINTFLAG_TRCPT(value) ((USB_DEVICE_EPINTFLAG_TRCPT_Msk & ((value) << USB_DEVICE_EPINTFLAG_TRCPT_Pos))) +#define USB_DEVICE_EPINTFLAG_TRFAIL0_Pos 2 /**< \brief (USB_DEVICE_EPINTFLAG) Error Flow 0 */ +#define USB_DEVICE_EPINTFLAG_TRFAIL0 (1 << USB_DEVICE_EPINTFLAG_TRFAIL0_Pos) +#define USB_DEVICE_EPINTFLAG_TRFAIL1_Pos 3 /**< \brief (USB_DEVICE_EPINTFLAG) Error Flow 1 */ +#define USB_DEVICE_EPINTFLAG_TRFAIL1 (1 << USB_DEVICE_EPINTFLAG_TRFAIL1_Pos) +#define USB_DEVICE_EPINTFLAG_TRFAIL_Pos 2 /**< \brief (USB_DEVICE_EPINTFLAG) Error Flow x */ +#define USB_DEVICE_EPINTFLAG_TRFAIL_Msk (0x3u << USB_DEVICE_EPINTFLAG_TRFAIL_Pos) +#define USB_DEVICE_EPINTFLAG_TRFAIL(value) ((USB_DEVICE_EPINTFLAG_TRFAIL_Msk & ((value) << USB_DEVICE_EPINTFLAG_TRFAIL_Pos))) +#define USB_DEVICE_EPINTFLAG_RXSTP_Pos 4 /**< \brief (USB_DEVICE_EPINTFLAG) Received Setup */ +#define USB_DEVICE_EPINTFLAG_RXSTP (0x1u << USB_DEVICE_EPINTFLAG_RXSTP_Pos) +#define USB_DEVICE_EPINTFLAG_STALL0_Pos 5 /**< \brief (USB_DEVICE_EPINTFLAG) Stall 0 In/out */ +#define USB_DEVICE_EPINTFLAG_STALL0 (1 << USB_DEVICE_EPINTFLAG_STALL0_Pos) +#define USB_DEVICE_EPINTFLAG_STALL1_Pos 6 /**< \brief (USB_DEVICE_EPINTFLAG) Stall 1 In/out */ +#define USB_DEVICE_EPINTFLAG_STALL1 (1 << USB_DEVICE_EPINTFLAG_STALL1_Pos) +#define USB_DEVICE_EPINTFLAG_STALL_Pos 5 /**< \brief (USB_DEVICE_EPINTFLAG) Stall x In/out */ +#define USB_DEVICE_EPINTFLAG_STALL_Msk (0x3u << USB_DEVICE_EPINTFLAG_STALL_Pos) +#define USB_DEVICE_EPINTFLAG_STALL(value) ((USB_DEVICE_EPINTFLAG_STALL_Msk & ((value) << USB_DEVICE_EPINTFLAG_STALL_Pos))) +#define USB_DEVICE_EPINTFLAG_MASK 0x7Fu /**< \brief (USB_DEVICE_EPINTFLAG) MASK Register */ + +/* -------- USB_HOST_PINTFLAG : (USB Offset: 0x107) (R/W 8) HOST HOST_PIPE Pipe Interrupt Flag -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t TRCPT0:1; /*!< bit: 0 Transfer Complete 0 Interrupt Flag */ + uint8_t TRCPT1:1; /*!< bit: 1 Transfer Complete 1 Interrupt Flag */ + uint8_t TRFAIL:1; /*!< bit: 2 Error Flow Interrupt Flag */ + uint8_t PERR:1; /*!< bit: 3 Pipe Error Interrupt Flag */ + uint8_t TXSTP:1; /*!< bit: 4 Transmit Setup Interrupt Flag */ + uint8_t STALL:1; /*!< bit: 5 Stall Interrupt Flag */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t TRCPT:2; /*!< bit: 0.. 1 Transfer Complete x Interrupt Flag */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_PINTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_PINTFLAG_OFFSET 0x107 /**< \brief (USB_HOST_PINTFLAG offset) HOST_PIPE Pipe Interrupt Flag */ +#define USB_HOST_PINTFLAG_RESETVALUE 0x00 /**< \brief (USB_HOST_PINTFLAG reset_value) HOST_PIPE Pipe Interrupt Flag */ + +#define USB_HOST_PINTFLAG_TRCPT0_Pos 0 /**< \brief (USB_HOST_PINTFLAG) Transfer Complete 0 Interrupt Flag */ +#define USB_HOST_PINTFLAG_TRCPT0 (1 << USB_HOST_PINTFLAG_TRCPT0_Pos) +#define USB_HOST_PINTFLAG_TRCPT1_Pos 1 /**< \brief (USB_HOST_PINTFLAG) Transfer Complete 1 Interrupt Flag */ +#define USB_HOST_PINTFLAG_TRCPT1 (1 << USB_HOST_PINTFLAG_TRCPT1_Pos) +#define USB_HOST_PINTFLAG_TRCPT_Pos 0 /**< \brief (USB_HOST_PINTFLAG) Transfer Complete x Interrupt Flag */ +#define USB_HOST_PINTFLAG_TRCPT_Msk (0x3u << USB_HOST_PINTFLAG_TRCPT_Pos) +#define USB_HOST_PINTFLAG_TRCPT(value) ((USB_HOST_PINTFLAG_TRCPT_Msk & ((value) << USB_HOST_PINTFLAG_TRCPT_Pos))) +#define USB_HOST_PINTFLAG_TRFAIL_Pos 2 /**< \brief (USB_HOST_PINTFLAG) Error Flow Interrupt Flag */ +#define USB_HOST_PINTFLAG_TRFAIL (0x1u << USB_HOST_PINTFLAG_TRFAIL_Pos) +#define USB_HOST_PINTFLAG_PERR_Pos 3 /**< \brief (USB_HOST_PINTFLAG) Pipe Error Interrupt Flag */ +#define USB_HOST_PINTFLAG_PERR (0x1u << USB_HOST_PINTFLAG_PERR_Pos) +#define USB_HOST_PINTFLAG_TXSTP_Pos 4 /**< \brief (USB_HOST_PINTFLAG) Transmit Setup Interrupt Flag */ +#define USB_HOST_PINTFLAG_TXSTP (0x1u << USB_HOST_PINTFLAG_TXSTP_Pos) +#define USB_HOST_PINTFLAG_STALL_Pos 5 /**< \brief (USB_HOST_PINTFLAG) Stall Interrupt Flag */ +#define USB_HOST_PINTFLAG_STALL (0x1u << USB_HOST_PINTFLAG_STALL_Pos) +#define USB_HOST_PINTFLAG_MASK 0x3Fu /**< \brief (USB_HOST_PINTFLAG) MASK Register */ + +/* -------- USB_DEVICE_EPINTENCLR : (USB Offset: 0x108) (R/W 8) DEVICE DEVICE_ENDPOINT End Point Interrupt Clear Flag -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t TRCPT0:1; /*!< bit: 0 Transfer Complete 0 Interrupt Disable */ + uint8_t TRCPT1:1; /*!< bit: 1 Transfer Complete 1 Interrupt Disable */ + uint8_t TRFAIL0:1; /*!< bit: 2 Error Flow 0 Interrupt Disable */ + uint8_t TRFAIL1:1; /*!< bit: 3 Error Flow 1 Interrupt Disable */ + uint8_t RXSTP:1; /*!< bit: 4 Received Setup Interrupt Disable */ + uint8_t STALL0:1; /*!< bit: 5 Stall 0 In/Out Interrupt Disable */ + uint8_t STALL1:1; /*!< bit: 6 Stall 1 In/Out Interrupt Disable */ + uint8_t :1; /*!< bit: 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t TRCPT:2; /*!< bit: 0.. 1 Transfer Complete x Interrupt Disable */ + uint8_t TRFAIL:2; /*!< bit: 2.. 3 Error Flow x Interrupt Disable */ + uint8_t :1; /*!< bit: 4 Reserved */ + uint8_t STALL:2; /*!< bit: 5.. 6 Stall x In/Out Interrupt Disable */ + uint8_t :1; /*!< bit: 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_EPINTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_EPINTENCLR_OFFSET 0x108 /**< \brief (USB_DEVICE_EPINTENCLR offset) DEVICE_ENDPOINT End Point Interrupt Clear Flag */ +#define USB_DEVICE_EPINTENCLR_RESETVALUE 0x00 /**< \brief (USB_DEVICE_EPINTENCLR reset_value) DEVICE_ENDPOINT End Point Interrupt Clear Flag */ + +#define USB_DEVICE_EPINTENCLR_TRCPT0_Pos 0 /**< \brief (USB_DEVICE_EPINTENCLR) Transfer Complete 0 Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_TRCPT0 (1 << USB_DEVICE_EPINTENCLR_TRCPT0_Pos) +#define USB_DEVICE_EPINTENCLR_TRCPT1_Pos 1 /**< \brief (USB_DEVICE_EPINTENCLR) Transfer Complete 1 Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_TRCPT1 (1 << USB_DEVICE_EPINTENCLR_TRCPT1_Pos) +#define USB_DEVICE_EPINTENCLR_TRCPT_Pos 0 /**< \brief (USB_DEVICE_EPINTENCLR) Transfer Complete x Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_TRCPT_Msk (0x3u << USB_DEVICE_EPINTENCLR_TRCPT_Pos) +#define USB_DEVICE_EPINTENCLR_TRCPT(value) ((USB_DEVICE_EPINTENCLR_TRCPT_Msk & ((value) << USB_DEVICE_EPINTENCLR_TRCPT_Pos))) +#define USB_DEVICE_EPINTENCLR_TRFAIL0_Pos 2 /**< \brief (USB_DEVICE_EPINTENCLR) Error Flow 0 Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_TRFAIL0 (1 << USB_DEVICE_EPINTENCLR_TRFAIL0_Pos) +#define USB_DEVICE_EPINTENCLR_TRFAIL1_Pos 3 /**< \brief (USB_DEVICE_EPINTENCLR) Error Flow 1 Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_TRFAIL1 (1 << USB_DEVICE_EPINTENCLR_TRFAIL1_Pos) +#define USB_DEVICE_EPINTENCLR_TRFAIL_Pos 2 /**< \brief (USB_DEVICE_EPINTENCLR) Error Flow x Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_TRFAIL_Msk (0x3u << USB_DEVICE_EPINTENCLR_TRFAIL_Pos) +#define USB_DEVICE_EPINTENCLR_TRFAIL(value) ((USB_DEVICE_EPINTENCLR_TRFAIL_Msk & ((value) << USB_DEVICE_EPINTENCLR_TRFAIL_Pos))) +#define USB_DEVICE_EPINTENCLR_RXSTP_Pos 4 /**< \brief (USB_DEVICE_EPINTENCLR) Received Setup Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_RXSTP (0x1u << USB_DEVICE_EPINTENCLR_RXSTP_Pos) +#define USB_DEVICE_EPINTENCLR_STALL0_Pos 5 /**< \brief (USB_DEVICE_EPINTENCLR) Stall 0 In/Out Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_STALL0 (1 << USB_DEVICE_EPINTENCLR_STALL0_Pos) +#define USB_DEVICE_EPINTENCLR_STALL1_Pos 6 /**< \brief (USB_DEVICE_EPINTENCLR) Stall 1 In/Out Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_STALL1 (1 << USB_DEVICE_EPINTENCLR_STALL1_Pos) +#define USB_DEVICE_EPINTENCLR_STALL_Pos 5 /**< \brief (USB_DEVICE_EPINTENCLR) Stall x In/Out Interrupt Disable */ +#define USB_DEVICE_EPINTENCLR_STALL_Msk (0x3u << USB_DEVICE_EPINTENCLR_STALL_Pos) +#define USB_DEVICE_EPINTENCLR_STALL(value) ((USB_DEVICE_EPINTENCLR_STALL_Msk & ((value) << USB_DEVICE_EPINTENCLR_STALL_Pos))) +#define USB_DEVICE_EPINTENCLR_MASK 0x7Fu /**< \brief (USB_DEVICE_EPINTENCLR) MASK Register */ + +/* -------- USB_HOST_PINTENCLR : (USB Offset: 0x108) (R/W 8) HOST HOST_PIPE Pipe Interrupt Flag Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t TRCPT0:1; /*!< bit: 0 Transfer Complete 0 Disable */ + uint8_t TRCPT1:1; /*!< bit: 1 Transfer Complete 1 Disable */ + uint8_t TRFAIL:1; /*!< bit: 2 Error Flow Interrupt Disable */ + uint8_t PERR:1; /*!< bit: 3 Pipe Error Interrupt Disable */ + uint8_t TXSTP:1; /*!< bit: 4 Transmit Setup Interrupt Disable */ + uint8_t STALL:1; /*!< bit: 5 Stall Inetrrupt Disable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t TRCPT:2; /*!< bit: 0.. 1 Transfer Complete x Disable */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_PINTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_PINTENCLR_OFFSET 0x108 /**< \brief (USB_HOST_PINTENCLR offset) HOST_PIPE Pipe Interrupt Flag Clear */ +#define USB_HOST_PINTENCLR_RESETVALUE 0x00 /**< \brief (USB_HOST_PINTENCLR reset_value) HOST_PIPE Pipe Interrupt Flag Clear */ + +#define USB_HOST_PINTENCLR_TRCPT0_Pos 0 /**< \brief (USB_HOST_PINTENCLR) Transfer Complete 0 Disable */ +#define USB_HOST_PINTENCLR_TRCPT0 (1 << USB_HOST_PINTENCLR_TRCPT0_Pos) +#define USB_HOST_PINTENCLR_TRCPT1_Pos 1 /**< \brief (USB_HOST_PINTENCLR) Transfer Complete 1 Disable */ +#define USB_HOST_PINTENCLR_TRCPT1 (1 << USB_HOST_PINTENCLR_TRCPT1_Pos) +#define USB_HOST_PINTENCLR_TRCPT_Pos 0 /**< \brief (USB_HOST_PINTENCLR) Transfer Complete x Disable */ +#define USB_HOST_PINTENCLR_TRCPT_Msk (0x3u << USB_HOST_PINTENCLR_TRCPT_Pos) +#define USB_HOST_PINTENCLR_TRCPT(value) ((USB_HOST_PINTENCLR_TRCPT_Msk & ((value) << USB_HOST_PINTENCLR_TRCPT_Pos))) +#define USB_HOST_PINTENCLR_TRFAIL_Pos 2 /**< \brief (USB_HOST_PINTENCLR) Error Flow Interrupt Disable */ +#define USB_HOST_PINTENCLR_TRFAIL (0x1u << USB_HOST_PINTENCLR_TRFAIL_Pos) +#define USB_HOST_PINTENCLR_PERR_Pos 3 /**< \brief (USB_HOST_PINTENCLR) Pipe Error Interrupt Disable */ +#define USB_HOST_PINTENCLR_PERR (0x1u << USB_HOST_PINTENCLR_PERR_Pos) +#define USB_HOST_PINTENCLR_TXSTP_Pos 4 /**< \brief (USB_HOST_PINTENCLR) Transmit Setup Interrupt Disable */ +#define USB_HOST_PINTENCLR_TXSTP (0x1u << USB_HOST_PINTENCLR_TXSTP_Pos) +#define USB_HOST_PINTENCLR_STALL_Pos 5 /**< \brief (USB_HOST_PINTENCLR) Stall Inetrrupt Disable */ +#define USB_HOST_PINTENCLR_STALL (0x1u << USB_HOST_PINTENCLR_STALL_Pos) +#define USB_HOST_PINTENCLR_MASK 0x3Fu /**< \brief (USB_HOST_PINTENCLR) MASK Register */ + +/* -------- USB_DEVICE_EPINTENSET : (USB Offset: 0x109) (R/W 8) DEVICE DEVICE_ENDPOINT End Point Interrupt Set Flag -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t TRCPT0:1; /*!< bit: 0 Transfer Complete 0 Interrupt Enable */ + uint8_t TRCPT1:1; /*!< bit: 1 Transfer Complete 1 Interrupt Enable */ + uint8_t TRFAIL0:1; /*!< bit: 2 Error Flow 0 Interrupt Enable */ + uint8_t TRFAIL1:1; /*!< bit: 3 Error Flow 1 Interrupt Enable */ + uint8_t RXSTP:1; /*!< bit: 4 Received Setup Interrupt Enable */ + uint8_t STALL0:1; /*!< bit: 5 Stall 0 In/out Interrupt enable */ + uint8_t STALL1:1; /*!< bit: 6 Stall 1 In/out Interrupt enable */ + uint8_t :1; /*!< bit: 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t TRCPT:2; /*!< bit: 0.. 1 Transfer Complete x Interrupt Enable */ + uint8_t TRFAIL:2; /*!< bit: 2.. 3 Error Flow x Interrupt Enable */ + uint8_t :1; /*!< bit: 4 Reserved */ + uint8_t STALL:2; /*!< bit: 5.. 6 Stall x In/out Interrupt enable */ + uint8_t :1; /*!< bit: 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_EPINTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_EPINTENSET_OFFSET 0x109 /**< \brief (USB_DEVICE_EPINTENSET offset) DEVICE_ENDPOINT End Point Interrupt Set Flag */ +#define USB_DEVICE_EPINTENSET_RESETVALUE 0x00 /**< \brief (USB_DEVICE_EPINTENSET reset_value) DEVICE_ENDPOINT End Point Interrupt Set Flag */ + +#define USB_DEVICE_EPINTENSET_TRCPT0_Pos 0 /**< \brief (USB_DEVICE_EPINTENSET) Transfer Complete 0 Interrupt Enable */ +#define USB_DEVICE_EPINTENSET_TRCPT0 (1 << USB_DEVICE_EPINTENSET_TRCPT0_Pos) +#define USB_DEVICE_EPINTENSET_TRCPT1_Pos 1 /**< \brief (USB_DEVICE_EPINTENSET) Transfer Complete 1 Interrupt Enable */ +#define USB_DEVICE_EPINTENSET_TRCPT1 (1 << USB_DEVICE_EPINTENSET_TRCPT1_Pos) +#define USB_DEVICE_EPINTENSET_TRCPT_Pos 0 /**< \brief (USB_DEVICE_EPINTENSET) Transfer Complete x Interrupt Enable */ +#define USB_DEVICE_EPINTENSET_TRCPT_Msk (0x3u << USB_DEVICE_EPINTENSET_TRCPT_Pos) +#define USB_DEVICE_EPINTENSET_TRCPT(value) ((USB_DEVICE_EPINTENSET_TRCPT_Msk & ((value) << USB_DEVICE_EPINTENSET_TRCPT_Pos))) +#define USB_DEVICE_EPINTENSET_TRFAIL0_Pos 2 /**< \brief (USB_DEVICE_EPINTENSET) Error Flow 0 Interrupt Enable */ +#define USB_DEVICE_EPINTENSET_TRFAIL0 (1 << USB_DEVICE_EPINTENSET_TRFAIL0_Pos) +#define USB_DEVICE_EPINTENSET_TRFAIL1_Pos 3 /**< \brief (USB_DEVICE_EPINTENSET) Error Flow 1 Interrupt Enable */ +#define USB_DEVICE_EPINTENSET_TRFAIL1 (1 << USB_DEVICE_EPINTENSET_TRFAIL1_Pos) +#define USB_DEVICE_EPINTENSET_TRFAIL_Pos 2 /**< \brief (USB_DEVICE_EPINTENSET) Error Flow x Interrupt Enable */ +#define USB_DEVICE_EPINTENSET_TRFAIL_Msk (0x3u << USB_DEVICE_EPINTENSET_TRFAIL_Pos) +#define USB_DEVICE_EPINTENSET_TRFAIL(value) ((USB_DEVICE_EPINTENSET_TRFAIL_Msk & ((value) << USB_DEVICE_EPINTENSET_TRFAIL_Pos))) +#define USB_DEVICE_EPINTENSET_RXSTP_Pos 4 /**< \brief (USB_DEVICE_EPINTENSET) Received Setup Interrupt Enable */ +#define USB_DEVICE_EPINTENSET_RXSTP (0x1u << USB_DEVICE_EPINTENSET_RXSTP_Pos) +#define USB_DEVICE_EPINTENSET_STALL0_Pos 5 /**< \brief (USB_DEVICE_EPINTENSET) Stall 0 In/out Interrupt enable */ +#define USB_DEVICE_EPINTENSET_STALL0 (1 << USB_DEVICE_EPINTENSET_STALL0_Pos) +#define USB_DEVICE_EPINTENSET_STALL1_Pos 6 /**< \brief (USB_DEVICE_EPINTENSET) Stall 1 In/out Interrupt enable */ +#define USB_DEVICE_EPINTENSET_STALL1 (1 << USB_DEVICE_EPINTENSET_STALL1_Pos) +#define USB_DEVICE_EPINTENSET_STALL_Pos 5 /**< \brief (USB_DEVICE_EPINTENSET) Stall x In/out Interrupt enable */ +#define USB_DEVICE_EPINTENSET_STALL_Msk (0x3u << USB_DEVICE_EPINTENSET_STALL_Pos) +#define USB_DEVICE_EPINTENSET_STALL(value) ((USB_DEVICE_EPINTENSET_STALL_Msk & ((value) << USB_DEVICE_EPINTENSET_STALL_Pos))) +#define USB_DEVICE_EPINTENSET_MASK 0x7Fu /**< \brief (USB_DEVICE_EPINTENSET) MASK Register */ + +/* -------- USB_HOST_PINTENSET : (USB Offset: 0x109) (R/W 8) HOST HOST_PIPE Pipe Interrupt Flag Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t TRCPT0:1; /*!< bit: 0 Transfer Complete 0 Interrupt Enable */ + uint8_t TRCPT1:1; /*!< bit: 1 Transfer Complete 1 Interrupt Enable */ + uint8_t TRFAIL:1; /*!< bit: 2 Error Flow Interrupt Enable */ + uint8_t PERR:1; /*!< bit: 3 Pipe Error Interrupt Enable */ + uint8_t TXSTP:1; /*!< bit: 4 Transmit Setup Interrupt Enable */ + uint8_t STALL:1; /*!< bit: 5 Stall Interrupt Enable */ + uint8_t :2; /*!< bit: 6.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + struct { + uint8_t TRCPT:2; /*!< bit: 0.. 1 Transfer Complete x Interrupt Enable */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } vec; /*!< Structure used for vec access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_PINTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_PINTENSET_OFFSET 0x109 /**< \brief (USB_HOST_PINTENSET offset) HOST_PIPE Pipe Interrupt Flag Set */ +#define USB_HOST_PINTENSET_RESETVALUE 0x00 /**< \brief (USB_HOST_PINTENSET reset_value) HOST_PIPE Pipe Interrupt Flag Set */ + +#define USB_HOST_PINTENSET_TRCPT0_Pos 0 /**< \brief (USB_HOST_PINTENSET) Transfer Complete 0 Interrupt Enable */ +#define USB_HOST_PINTENSET_TRCPT0 (1 << USB_HOST_PINTENSET_TRCPT0_Pos) +#define USB_HOST_PINTENSET_TRCPT1_Pos 1 /**< \brief (USB_HOST_PINTENSET) Transfer Complete 1 Interrupt Enable */ +#define USB_HOST_PINTENSET_TRCPT1 (1 << USB_HOST_PINTENSET_TRCPT1_Pos) +#define USB_HOST_PINTENSET_TRCPT_Pos 0 /**< \brief (USB_HOST_PINTENSET) Transfer Complete x Interrupt Enable */ +#define USB_HOST_PINTENSET_TRCPT_Msk (0x3u << USB_HOST_PINTENSET_TRCPT_Pos) +#define USB_HOST_PINTENSET_TRCPT(value) ((USB_HOST_PINTENSET_TRCPT_Msk & ((value) << USB_HOST_PINTENSET_TRCPT_Pos))) +#define USB_HOST_PINTENSET_TRFAIL_Pos 2 /**< \brief (USB_HOST_PINTENSET) Error Flow Interrupt Enable */ +#define USB_HOST_PINTENSET_TRFAIL (0x1u << USB_HOST_PINTENSET_TRFAIL_Pos) +#define USB_HOST_PINTENSET_PERR_Pos 3 /**< \brief (USB_HOST_PINTENSET) Pipe Error Interrupt Enable */ +#define USB_HOST_PINTENSET_PERR (0x1u << USB_HOST_PINTENSET_PERR_Pos) +#define USB_HOST_PINTENSET_TXSTP_Pos 4 /**< \brief (USB_HOST_PINTENSET) Transmit Setup Interrupt Enable */ +#define USB_HOST_PINTENSET_TXSTP (0x1u << USB_HOST_PINTENSET_TXSTP_Pos) +#define USB_HOST_PINTENSET_STALL_Pos 5 /**< \brief (USB_HOST_PINTENSET) Stall Interrupt Enable */ +#define USB_HOST_PINTENSET_STALL (0x1u << USB_HOST_PINTENSET_STALL_Pos) +#define USB_HOST_PINTENSET_MASK 0x3Fu /**< \brief (USB_HOST_PINTENSET) MASK Register */ + +/* -------- USB_DEVICE_ADDR : (USB Offset: 0x000) (R/W 32) DEVICE DEVICE_DESC_BANK Endpoint Bank, Adress of Data Buffer -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t ADDR:32; /*!< bit: 0..31 Adress of data buffer */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} USB_DEVICE_ADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_ADDR_OFFSET 0x000 /**< \brief (USB_DEVICE_ADDR offset) DEVICE_DESC_BANK Endpoint Bank, Adress of Data Buffer */ + +#define USB_DEVICE_ADDR_ADDR_Pos 0 /**< \brief (USB_DEVICE_ADDR) Adress of data buffer */ +#define USB_DEVICE_ADDR_ADDR_Msk (0xFFFFFFFFu << USB_DEVICE_ADDR_ADDR_Pos) +#define USB_DEVICE_ADDR_ADDR(value) ((USB_DEVICE_ADDR_ADDR_Msk & ((value) << USB_DEVICE_ADDR_ADDR_Pos))) +#define USB_DEVICE_ADDR_MASK 0xFFFFFFFFu /**< \brief (USB_DEVICE_ADDR) MASK Register */ + +/* -------- USB_HOST_ADDR : (USB Offset: 0x000) (R/W 32) HOST HOST_DESC_BANK Host Bank, Adress of Data Buffer -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t ADDR:32; /*!< bit: 0..31 Adress of data buffer */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} USB_HOST_ADDR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_ADDR_OFFSET 0x000 /**< \brief (USB_HOST_ADDR offset) HOST_DESC_BANK Host Bank, Adress of Data Buffer */ + +#define USB_HOST_ADDR_ADDR_Pos 0 /**< \brief (USB_HOST_ADDR) Adress of data buffer */ +#define USB_HOST_ADDR_ADDR_Msk (0xFFFFFFFFu << USB_HOST_ADDR_ADDR_Pos) +#define USB_HOST_ADDR_ADDR(value) ((USB_HOST_ADDR_ADDR_Msk & ((value) << USB_HOST_ADDR_ADDR_Pos))) +#define USB_HOST_ADDR_MASK 0xFFFFFFFFu /**< \brief (USB_HOST_ADDR) MASK Register */ + +/* -------- USB_DEVICE_PCKSIZE : (USB Offset: 0x004) (R/W 32) DEVICE DEVICE_DESC_BANK Endpoint Bank, Packet Size -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t BYTE_COUNT:14; /*!< bit: 0..13 Byte Count */ + uint32_t MULTI_PACKET_SIZE:14; /*!< bit: 14..27 Multi Packet In or Out size */ + uint32_t SIZE:3; /*!< bit: 28..30 Enpoint size */ + uint32_t AUTO_ZLP:1; /*!< bit: 31 Automatic Zero Length Packet */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} USB_DEVICE_PCKSIZE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_PCKSIZE_OFFSET 0x004 /**< \brief (USB_DEVICE_PCKSIZE offset) DEVICE_DESC_BANK Endpoint Bank, Packet Size */ + +#define USB_DEVICE_PCKSIZE_BYTE_COUNT_Pos 0 /**< \brief (USB_DEVICE_PCKSIZE) Byte Count */ +#define USB_DEVICE_PCKSIZE_BYTE_COUNT_Msk (0x3FFFu << USB_DEVICE_PCKSIZE_BYTE_COUNT_Pos) +#define USB_DEVICE_PCKSIZE_BYTE_COUNT(value) ((USB_DEVICE_PCKSIZE_BYTE_COUNT_Msk & ((value) << USB_DEVICE_PCKSIZE_BYTE_COUNT_Pos))) +#define USB_DEVICE_PCKSIZE_MULTI_PACKET_SIZE_Pos 14 /**< \brief (USB_DEVICE_PCKSIZE) Multi Packet In or Out size */ +#define USB_DEVICE_PCKSIZE_MULTI_PACKET_SIZE_Msk (0x3FFFu << USB_DEVICE_PCKSIZE_MULTI_PACKET_SIZE_Pos) +#define USB_DEVICE_PCKSIZE_MULTI_PACKET_SIZE(value) ((USB_DEVICE_PCKSIZE_MULTI_PACKET_SIZE_Msk & ((value) << USB_DEVICE_PCKSIZE_MULTI_PACKET_SIZE_Pos))) +#define USB_DEVICE_PCKSIZE_SIZE_Pos 28 /**< \brief (USB_DEVICE_PCKSIZE) Enpoint size */ +#define USB_DEVICE_PCKSIZE_SIZE_Msk (0x7u << USB_DEVICE_PCKSIZE_SIZE_Pos) +#define USB_DEVICE_PCKSIZE_SIZE(value) ((USB_DEVICE_PCKSIZE_SIZE_Msk & ((value) << USB_DEVICE_PCKSIZE_SIZE_Pos))) +#define USB_DEVICE_PCKSIZE_AUTO_ZLP_Pos 31 /**< \brief (USB_DEVICE_PCKSIZE) Automatic Zero Length Packet */ +#define USB_DEVICE_PCKSIZE_AUTO_ZLP (0x1u << USB_DEVICE_PCKSIZE_AUTO_ZLP_Pos) +#define USB_DEVICE_PCKSIZE_MASK 0xFFFFFFFFu /**< \brief (USB_DEVICE_PCKSIZE) MASK Register */ + +/* -------- USB_HOST_PCKSIZE : (USB Offset: 0x004) (R/W 32) HOST HOST_DESC_BANK Host Bank, Packet Size -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint32_t BYTE_COUNT:14; /*!< bit: 0..13 Byte Count */ + uint32_t MULTI_PACKET_SIZE:14; /*!< bit: 14..27 Multi Packet In or Out size */ + uint32_t SIZE:3; /*!< bit: 28..30 Pipe size */ + uint32_t AUTO_ZLP:1; /*!< bit: 31 Automatic Zero Length Packet */ + } bit; /*!< Structure used for bit access */ + uint32_t reg; /*!< Type used for register access */ +} USB_HOST_PCKSIZE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_PCKSIZE_OFFSET 0x004 /**< \brief (USB_HOST_PCKSIZE offset) HOST_DESC_BANK Host Bank, Packet Size */ + +#define USB_HOST_PCKSIZE_BYTE_COUNT_Pos 0 /**< \brief (USB_HOST_PCKSIZE) Byte Count */ +#define USB_HOST_PCKSIZE_BYTE_COUNT_Msk (0x3FFFu << USB_HOST_PCKSIZE_BYTE_COUNT_Pos) +#define USB_HOST_PCKSIZE_BYTE_COUNT(value) ((USB_HOST_PCKSIZE_BYTE_COUNT_Msk & ((value) << USB_HOST_PCKSIZE_BYTE_COUNT_Pos))) +#define USB_HOST_PCKSIZE_MULTI_PACKET_SIZE_Pos 14 /**< \brief (USB_HOST_PCKSIZE) Multi Packet In or Out size */ +#define USB_HOST_PCKSIZE_MULTI_PACKET_SIZE_Msk (0x3FFFu << USB_HOST_PCKSIZE_MULTI_PACKET_SIZE_Pos) +#define USB_HOST_PCKSIZE_MULTI_PACKET_SIZE(value) ((USB_HOST_PCKSIZE_MULTI_PACKET_SIZE_Msk & ((value) << USB_HOST_PCKSIZE_MULTI_PACKET_SIZE_Pos))) +#define USB_HOST_PCKSIZE_SIZE_Pos 28 /**< \brief (USB_HOST_PCKSIZE) Pipe size */ +#define USB_HOST_PCKSIZE_SIZE_Msk (0x7u << USB_HOST_PCKSIZE_SIZE_Pos) +#define USB_HOST_PCKSIZE_SIZE(value) ((USB_HOST_PCKSIZE_SIZE_Msk & ((value) << USB_HOST_PCKSIZE_SIZE_Pos))) +#define USB_HOST_PCKSIZE_AUTO_ZLP_Pos 31 /**< \brief (USB_HOST_PCKSIZE) Automatic Zero Length Packet */ +#define USB_HOST_PCKSIZE_AUTO_ZLP (0x1u << USB_HOST_PCKSIZE_AUTO_ZLP_Pos) +#define USB_HOST_PCKSIZE_MASK 0xFFFFFFFFu /**< \brief (USB_HOST_PCKSIZE) MASK Register */ + +/* -------- USB_DEVICE_EXTREG : (USB Offset: 0x008) (R/W 16) DEVICE DEVICE_DESC_BANK Endpoint Bank, Extended -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SUBPID:4; /*!< bit: 0.. 3 SUBPID field send with extended token */ + uint16_t VARIABLE:11; /*!< bit: 4..14 Variable field send with extended token */ + uint16_t :1; /*!< bit: 15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_DEVICE_EXTREG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_EXTREG_OFFSET 0x008 /**< \brief (USB_DEVICE_EXTREG offset) DEVICE_DESC_BANK Endpoint Bank, Extended */ + +#define USB_DEVICE_EXTREG_SUBPID_Pos 0 /**< \brief (USB_DEVICE_EXTREG) SUBPID field send with extended token */ +#define USB_DEVICE_EXTREG_SUBPID_Msk (0xFu << USB_DEVICE_EXTREG_SUBPID_Pos) +#define USB_DEVICE_EXTREG_SUBPID(value) ((USB_DEVICE_EXTREG_SUBPID_Msk & ((value) << USB_DEVICE_EXTREG_SUBPID_Pos))) +#define USB_DEVICE_EXTREG_VARIABLE_Pos 4 /**< \brief (USB_DEVICE_EXTREG) Variable field send with extended token */ +#define USB_DEVICE_EXTREG_VARIABLE_Msk (0x7FFu << USB_DEVICE_EXTREG_VARIABLE_Pos) +#define USB_DEVICE_EXTREG_VARIABLE(value) ((USB_DEVICE_EXTREG_VARIABLE_Msk & ((value) << USB_DEVICE_EXTREG_VARIABLE_Pos))) +#define USB_DEVICE_EXTREG_MASK 0x7FFFu /**< \brief (USB_DEVICE_EXTREG) MASK Register */ + +/* -------- USB_HOST_EXTREG : (USB Offset: 0x008) (R/W 16) HOST HOST_DESC_BANK Host Bank, Extended -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t SUBPID:4; /*!< bit: 0.. 3 SUBPID field send with extended token */ + uint16_t VARIABLE:11; /*!< bit: 4..14 Variable field send with extended token */ + uint16_t :1; /*!< bit: 15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_HOST_EXTREG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_EXTREG_OFFSET 0x008 /**< \brief (USB_HOST_EXTREG offset) HOST_DESC_BANK Host Bank, Extended */ + +#define USB_HOST_EXTREG_SUBPID_Pos 0 /**< \brief (USB_HOST_EXTREG) SUBPID field send with extended token */ +#define USB_HOST_EXTREG_SUBPID_Msk (0xFu << USB_HOST_EXTREG_SUBPID_Pos) +#define USB_HOST_EXTREG_SUBPID(value) ((USB_HOST_EXTREG_SUBPID_Msk & ((value) << USB_HOST_EXTREG_SUBPID_Pos))) +#define USB_HOST_EXTREG_VARIABLE_Pos 4 /**< \brief (USB_HOST_EXTREG) Variable field send with extended token */ +#define USB_HOST_EXTREG_VARIABLE_Msk (0x7FFu << USB_HOST_EXTREG_VARIABLE_Pos) +#define USB_HOST_EXTREG_VARIABLE(value) ((USB_HOST_EXTREG_VARIABLE_Msk & ((value) << USB_HOST_EXTREG_VARIABLE_Pos))) +#define USB_HOST_EXTREG_MASK 0x7FFFu /**< \brief (USB_HOST_EXTREG) MASK Register */ + +/* -------- USB_DEVICE_STATUS_BK : (USB Offset: 0x00A) (R/W 8) DEVICE DEVICE_DESC_BANK Enpoint Bank, Status of Bank -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CRCERR:1; /*!< bit: 0 CRC Error Status */ + uint8_t ERRORFLOW:1; /*!< bit: 1 Error Flow Status */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_DEVICE_STATUS_BK_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_DEVICE_STATUS_BK_OFFSET 0x00A /**< \brief (USB_DEVICE_STATUS_BK offset) DEVICE_DESC_BANK Enpoint Bank, Status of Bank */ + +#define USB_DEVICE_STATUS_BK_CRCERR_Pos 0 /**< \brief (USB_DEVICE_STATUS_BK) CRC Error Status */ +#define USB_DEVICE_STATUS_BK_CRCERR (0x1u << USB_DEVICE_STATUS_BK_CRCERR_Pos) +#define USB_DEVICE_STATUS_BK_ERRORFLOW_Pos 1 /**< \brief (USB_DEVICE_STATUS_BK) Error Flow Status */ +#define USB_DEVICE_STATUS_BK_ERRORFLOW (0x1u << USB_DEVICE_STATUS_BK_ERRORFLOW_Pos) +#define USB_DEVICE_STATUS_BK_MASK 0x03u /**< \brief (USB_DEVICE_STATUS_BK) MASK Register */ + +/* -------- USB_HOST_STATUS_BK : (USB Offset: 0x00A) (R/W 8) HOST HOST_DESC_BANK Host Bank, Status of Bank -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CRCERR:1; /*!< bit: 0 CRC Error Status */ + uint8_t ERRORFLOW:1; /*!< bit: 1 Error Flow Status */ + uint8_t :6; /*!< bit: 2.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} USB_HOST_STATUS_BK_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_STATUS_BK_OFFSET 0x00A /**< \brief (USB_HOST_STATUS_BK offset) HOST_DESC_BANK Host Bank, Status of Bank */ + +#define USB_HOST_STATUS_BK_CRCERR_Pos 0 /**< \brief (USB_HOST_STATUS_BK) CRC Error Status */ +#define USB_HOST_STATUS_BK_CRCERR (0x1u << USB_HOST_STATUS_BK_CRCERR_Pos) +#define USB_HOST_STATUS_BK_ERRORFLOW_Pos 1 /**< \brief (USB_HOST_STATUS_BK) Error Flow Status */ +#define USB_HOST_STATUS_BK_ERRORFLOW (0x1u << USB_HOST_STATUS_BK_ERRORFLOW_Pos) +#define USB_HOST_STATUS_BK_MASK 0x03u /**< \brief (USB_HOST_STATUS_BK) MASK Register */ + +/* -------- USB_HOST_CTRL_PIPE : (USB Offset: 0x00C) (R/W 16) HOST HOST_DESC_BANK Host Bank, Host Control Pipe -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t PDADDR:7; /*!< bit: 0.. 6 Pipe Device Adress */ + uint16_t :1; /*!< bit: 7 Reserved */ + uint16_t PEPNUM:4; /*!< bit: 8..11 Pipe Endpoint Number */ + uint16_t PERMAX:4; /*!< bit: 12..15 Pipe Error Max Number */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_HOST_CTRL_PIPE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_CTRL_PIPE_OFFSET 0x00C /**< \brief (USB_HOST_CTRL_PIPE offset) HOST_DESC_BANK Host Bank, Host Control Pipe */ +#define USB_HOST_CTRL_PIPE_RESETVALUE 0x0000 /**< \brief (USB_HOST_CTRL_PIPE reset_value) HOST_DESC_BANK Host Bank, Host Control Pipe */ + +#define USB_HOST_CTRL_PIPE_PDADDR_Pos 0 /**< \brief (USB_HOST_CTRL_PIPE) Pipe Device Adress */ +#define USB_HOST_CTRL_PIPE_PDADDR_Msk (0x7Fu << USB_HOST_CTRL_PIPE_PDADDR_Pos) +#define USB_HOST_CTRL_PIPE_PDADDR(value) ((USB_HOST_CTRL_PIPE_PDADDR_Msk & ((value) << USB_HOST_CTRL_PIPE_PDADDR_Pos))) +#define USB_HOST_CTRL_PIPE_PEPNUM_Pos 8 /**< \brief (USB_HOST_CTRL_PIPE) Pipe Endpoint Number */ +#define USB_HOST_CTRL_PIPE_PEPNUM_Msk (0xFu << USB_HOST_CTRL_PIPE_PEPNUM_Pos) +#define USB_HOST_CTRL_PIPE_PEPNUM(value) ((USB_HOST_CTRL_PIPE_PEPNUM_Msk & ((value) << USB_HOST_CTRL_PIPE_PEPNUM_Pos))) +#define USB_HOST_CTRL_PIPE_PERMAX_Pos 12 /**< \brief (USB_HOST_CTRL_PIPE) Pipe Error Max Number */ +#define USB_HOST_CTRL_PIPE_PERMAX_Msk (0xFu << USB_HOST_CTRL_PIPE_PERMAX_Pos) +#define USB_HOST_CTRL_PIPE_PERMAX(value) ((USB_HOST_CTRL_PIPE_PERMAX_Msk & ((value) << USB_HOST_CTRL_PIPE_PERMAX_Pos))) +#define USB_HOST_CTRL_PIPE_MASK 0xFF7Fu /**< \brief (USB_HOST_CTRL_PIPE) MASK Register */ + +/* -------- USB_HOST_STATUS_PIPE : (USB Offset: 0x00E) (R/W 16) HOST HOST_DESC_BANK Host Bank, Host Status Pipe -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint16_t DTGLER:1; /*!< bit: 0 Data Toggle Error */ + uint16_t DAPIDER:1; /*!< bit: 1 Data PID Error */ + uint16_t PIDER:1; /*!< bit: 2 PID Error */ + uint16_t TOUTER:1; /*!< bit: 3 Time Out Error */ + uint16_t CRC16ER:1; /*!< bit: 4 CRC16 Error */ + uint16_t ERCNT:3; /*!< bit: 5.. 7 Pipe Error Count */ + uint16_t :8; /*!< bit: 8..15 Reserved */ + } bit; /*!< Structure used for bit access */ + uint16_t reg; /*!< Type used for register access */ +} USB_HOST_STATUS_PIPE_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define USB_HOST_STATUS_PIPE_OFFSET 0x00E /**< \brief (USB_HOST_STATUS_PIPE offset) HOST_DESC_BANK Host Bank, Host Status Pipe */ + +#define USB_HOST_STATUS_PIPE_DTGLER_Pos 0 /**< \brief (USB_HOST_STATUS_PIPE) Data Toggle Error */ +#define USB_HOST_STATUS_PIPE_DTGLER (0x1u << USB_HOST_STATUS_PIPE_DTGLER_Pos) +#define USB_HOST_STATUS_PIPE_DAPIDER_Pos 1 /**< \brief (USB_HOST_STATUS_PIPE) Data PID Error */ +#define USB_HOST_STATUS_PIPE_DAPIDER (0x1u << USB_HOST_STATUS_PIPE_DAPIDER_Pos) +#define USB_HOST_STATUS_PIPE_PIDER_Pos 2 /**< \brief (USB_HOST_STATUS_PIPE) PID Error */ +#define USB_HOST_STATUS_PIPE_PIDER (0x1u << USB_HOST_STATUS_PIPE_PIDER_Pos) +#define USB_HOST_STATUS_PIPE_TOUTER_Pos 3 /**< \brief (USB_HOST_STATUS_PIPE) Time Out Error */ +#define USB_HOST_STATUS_PIPE_TOUTER (0x1u << USB_HOST_STATUS_PIPE_TOUTER_Pos) +#define USB_HOST_STATUS_PIPE_CRC16ER_Pos 4 /**< \brief (USB_HOST_STATUS_PIPE) CRC16 Error */ +#define USB_HOST_STATUS_PIPE_CRC16ER (0x1u << USB_HOST_STATUS_PIPE_CRC16ER_Pos) +#define USB_HOST_STATUS_PIPE_ERCNT_Pos 5 /**< \brief (USB_HOST_STATUS_PIPE) Pipe Error Count */ +#define USB_HOST_STATUS_PIPE_ERCNT_Msk (0x7u << USB_HOST_STATUS_PIPE_ERCNT_Pos) +#define USB_HOST_STATUS_PIPE_ERCNT(value) ((USB_HOST_STATUS_PIPE_ERCNT_Msk & ((value) << USB_HOST_STATUS_PIPE_ERCNT_Pos))) +#define USB_HOST_STATUS_PIPE_MASK 0x00FFu /**< \brief (USB_HOST_STATUS_PIPE) MASK Register */ + +/** \brief UsbDeviceDescBank SRAM registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO USB_DEVICE_ADDR_Type ADDR; /**< \brief Offset: 0x000 (R/W 32) DEVICE_DESC_BANK Endpoint Bank, Adress of Data Buffer */ + __IO USB_DEVICE_PCKSIZE_Type PCKSIZE; /**< \brief Offset: 0x004 (R/W 32) DEVICE_DESC_BANK Endpoint Bank, Packet Size */ + __IO USB_DEVICE_EXTREG_Type EXTREG; /**< \brief Offset: 0x008 (R/W 16) DEVICE_DESC_BANK Endpoint Bank, Extended */ + __IO USB_DEVICE_STATUS_BK_Type STATUS_BK; /**< \brief Offset: 0x00A (R/W 8) DEVICE_DESC_BANK Enpoint Bank, Status of Bank */ + RoReg8 Reserved1[0x5]; +} UsbDeviceDescBank; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief UsbHostDescBank SRAM registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO USB_HOST_ADDR_Type ADDR; /**< \brief Offset: 0x000 (R/W 32) HOST_DESC_BANK Host Bank, Adress of Data Buffer */ + __IO USB_HOST_PCKSIZE_Type PCKSIZE; /**< \brief Offset: 0x004 (R/W 32) HOST_DESC_BANK Host Bank, Packet Size */ + __IO USB_HOST_EXTREG_Type EXTREG; /**< \brief Offset: 0x008 (R/W 16) HOST_DESC_BANK Host Bank, Extended */ + __IO USB_HOST_STATUS_BK_Type STATUS_BK; /**< \brief Offset: 0x00A (R/W 8) HOST_DESC_BANK Host Bank, Status of Bank */ + RoReg8 Reserved1[0x1]; + __IO USB_HOST_CTRL_PIPE_Type CTRL_PIPE; /**< \brief Offset: 0x00C (R/W 16) HOST_DESC_BANK Host Bank, Host Control Pipe */ + __IO USB_HOST_STATUS_PIPE_Type STATUS_PIPE; /**< \brief Offset: 0x00E (R/W 16) HOST_DESC_BANK Host Bank, Host Status Pipe */ +} UsbHostDescBank; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief UsbDeviceEndpoint hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO USB_DEVICE_EPCFG_Type EPCFG; /**< \brief Offset: 0x000 (R/W 8) DEVICE_ENDPOINT End Point Configuration */ + RoReg8 Reserved1[0x3]; + __O USB_DEVICE_EPSTATUSCLR_Type EPSTATUSCLR; /**< \brief Offset: 0x004 ( /W 8) DEVICE_ENDPOINT End Point Pipe Status Clear */ + __O USB_DEVICE_EPSTATUSSET_Type EPSTATUSSET; /**< \brief Offset: 0x005 ( /W 8) DEVICE_ENDPOINT End Point Pipe Status Set */ + __I USB_DEVICE_EPSTATUS_Type EPSTATUS; /**< \brief Offset: 0x006 (R/ 8) DEVICE_ENDPOINT End Point Pipe Status */ + __IO USB_DEVICE_EPINTFLAG_Type EPINTFLAG; /**< \brief Offset: 0x007 (R/W 8) DEVICE_ENDPOINT End Point Interrupt Flag */ + __IO USB_DEVICE_EPINTENCLR_Type EPINTENCLR; /**< \brief Offset: 0x008 (R/W 8) DEVICE_ENDPOINT End Point Interrupt Clear Flag */ + __IO USB_DEVICE_EPINTENSET_Type EPINTENSET; /**< \brief Offset: 0x009 (R/W 8) DEVICE_ENDPOINT End Point Interrupt Set Flag */ + RoReg8 Reserved2[0x16]; +} UsbDeviceEndpoint; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief UsbHostPipe hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO USB_HOST_PCFG_Type PCFG; /**< \brief Offset: 0x000 (R/W 8) HOST_PIPE End Point Configuration */ + RoReg8 Reserved1[0x2]; + __IO USB_HOST_BINTERVAL_Type BINTERVAL; /**< \brief Offset: 0x003 (R/W 8) HOST_PIPE Bus Access Period of Pipe */ + __O USB_HOST_PSTATUSCLR_Type PSTATUSCLR; /**< \brief Offset: 0x004 ( /W 8) HOST_PIPE End Point Pipe Status Clear */ + __O USB_HOST_PSTATUSSET_Type PSTATUSSET; /**< \brief Offset: 0x005 ( /W 8) HOST_PIPE End Point Pipe Status Set */ + __I USB_HOST_PSTATUS_Type PSTATUS; /**< \brief Offset: 0x006 (R/ 8) HOST_PIPE End Point Pipe Status */ + __IO USB_HOST_PINTFLAG_Type PINTFLAG; /**< \brief Offset: 0x007 (R/W 8) HOST_PIPE Pipe Interrupt Flag */ + __IO USB_HOST_PINTENCLR_Type PINTENCLR; /**< \brief Offset: 0x008 (R/W 8) HOST_PIPE Pipe Interrupt Flag Clear */ + __IO USB_HOST_PINTENSET_Type PINTENSET; /**< \brief Offset: 0x009 (R/W 8) HOST_PIPE Pipe Interrupt Flag Set */ + RoReg8 Reserved2[0x16]; +} UsbHostPipe; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief USB_DEVICE APB hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* USB is Device */ + __IO USB_CTRLA_Type CTRLA; /**< \brief Offset: 0x000 (R/W 8) Control A */ + RoReg8 Reserved1[0x1]; + __I USB_SYNCBUSY_Type SYNCBUSY; /**< \brief Offset: 0x002 (R/ 8) Synchronization Busy */ + RoReg8 Reserved2[0x5]; + __IO USB_DEVICE_CTRLB_Type CTRLB; /**< \brief Offset: 0x008 (R/W 16) DEVICE Control B */ + __IO USB_DEVICE_DADD_Type DADD; /**< \brief Offset: 0x00A (R/W 8) DEVICE Device Address */ + RoReg8 Reserved3[0x1]; + __I USB_DEVICE_STATUS_Type STATUS; /**< \brief Offset: 0x00C (R/ 8) DEVICE Status */ + __I USB_FSMSTATUS_Type FSMSTATUS; /**< \brief Offset: 0x00D (R/ 8) Finite State Machine Status */ + RoReg8 Reserved4[0x2]; + __I USB_DEVICE_FNUM_Type FNUM; /**< \brief Offset: 0x010 (R/ 16) DEVICE Device Frame Number */ + RoReg8 Reserved5[0x2]; + __IO USB_DEVICE_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x014 (R/W 16) DEVICE Device Interrupt Enable Clear */ + RoReg8 Reserved6[0x2]; + __IO USB_DEVICE_INTENSET_Type INTENSET; /**< \brief Offset: 0x018 (R/W 16) DEVICE Device Interrupt Enable Set */ + RoReg8 Reserved7[0x2]; + __IO USB_DEVICE_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x01C (R/W 16) DEVICE Device Interrupt Flag */ + RoReg8 Reserved8[0x2]; + __I USB_DEVICE_EPINTSMRY_Type EPINTSMRY; /**< \brief Offset: 0x020 (R/ 16) DEVICE End Point Interrupt Summary */ + RoReg8 Reserved9[0x2]; + __IO USB_DESCADD_Type DESCADD; /**< \brief Offset: 0x024 (R/W 32) Descriptor Address */ + __IO USB_PADCAL_Type PADCAL; /**< \brief Offset: 0x028 (R/W 16) USB PAD Calibration */ + RoReg8 Reserved10[0xD6]; + UsbDeviceEndpoint DeviceEndpoint[8]; /**< \brief Offset: 0x100 UsbDeviceEndpoint groups [EPT_NUM] */ +} UsbDevice; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief USB_HOST hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* USB is Host */ + __IO USB_CTRLA_Type CTRLA; /**< \brief Offset: 0x000 (R/W 8) Control A */ + RoReg8 Reserved1[0x1]; + __I USB_SYNCBUSY_Type SYNCBUSY; /**< \brief Offset: 0x002 (R/ 8) Synchronization Busy */ + RoReg8 Reserved2[0x5]; + __IO USB_HOST_CTRLB_Type CTRLB; /**< \brief Offset: 0x008 (R/W 16) HOST Control B */ + __IO USB_HOST_HSOFC_Type HSOFC; /**< \brief Offset: 0x00A (R/W 8) HOST Host Start Of Frame Control */ + RoReg8 Reserved3[0x1]; + __IO USB_HOST_STATUS_Type STATUS; /**< \brief Offset: 0x00C (R/W 8) HOST Status */ + __I USB_FSMSTATUS_Type FSMSTATUS; /**< \brief Offset: 0x00D (R/ 8) Finite State Machine Status */ + RoReg8 Reserved4[0x2]; + __IO USB_HOST_FNUM_Type FNUM; /**< \brief Offset: 0x010 (R/W 16) HOST Host Frame Number */ + __I USB_HOST_FLENHIGH_Type FLENHIGH; /**< \brief Offset: 0x012 (R/ 8) HOST Host Frame Length */ + RoReg8 Reserved5[0x1]; + __IO USB_HOST_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x014 (R/W 16) HOST Host Interrupt Enable Clear */ + RoReg8 Reserved6[0x2]; + __IO USB_HOST_INTENSET_Type INTENSET; /**< \brief Offset: 0x018 (R/W 16) HOST Host Interrupt Enable Set */ + RoReg8 Reserved7[0x2]; + __IO USB_HOST_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x01C (R/W 16) HOST Host Interrupt Flag */ + RoReg8 Reserved8[0x2]; + __I USB_HOST_PINTSMRY_Type PINTSMRY; /**< \brief Offset: 0x020 (R/ 16) HOST Pipe Interrupt Summary */ + RoReg8 Reserved9[0x2]; + __IO USB_DESCADD_Type DESCADD; /**< \brief Offset: 0x024 (R/W 32) Descriptor Address */ + __IO USB_PADCAL_Type PADCAL; /**< \brief Offset: 0x028 (R/W 16) USB PAD Calibration */ + RoReg8 Reserved10[0xD6]; + UsbHostPipe HostPipe[8]; /**< \brief Offset: 0x100 UsbHostPipe groups [EPT_NUM] */ +} UsbHost; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief USB_DEVICE Descriptor SRAM registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* USB is Device */ + UsbDeviceDescBank DeviceDescBank[2]; /**< \brief Offset: 0x000 UsbDeviceDescBank groups */ +} UsbDeviceDescriptor; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/** \brief USB_HOST Descriptor SRAM registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { /* USB is Host */ + UsbHostDescBank HostDescBank[2]; /**< \brief Offset: 0x000 UsbHostDescBank groups */ +} UsbHostDescriptor; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +#define SECTION_USB_DESCRIPTOR + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + UsbDevice DEVICE; /**< \brief Offset: 0x000 USB is Device */ + UsbHost HOST; /**< \brief Offset: 0x000 USB is Host */ +} Usb; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_USB_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/wdt.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/wdt.h new file mode 100755 index 0000000..a5a5858 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/component/wdt.h @@ -0,0 +1,303 @@ +/** + * \file + * + * \brief Component description for WDT + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_WDT_COMPONENT_ +#define _SAMD21_WDT_COMPONENT_ + +/* ========================================================================== */ +/** SOFTWARE API DEFINITION FOR WDT */ +/* ========================================================================== */ +/** \addtogroup SAMD21_WDT Watchdog Timer */ +/*@{*/ + +#define WDT_U2203 +#define REV_WDT 0x200 + +/* -------- WDT_CTRL : (WDT Offset: 0x0) (R/W 8) Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :1; /*!< bit: 0 Reserved */ + uint8_t ENABLE:1; /*!< bit: 1 Enable */ + uint8_t WEN:1; /*!< bit: 2 Watchdog Timer Window Mode Enable */ + uint8_t :4; /*!< bit: 3.. 6 Reserved */ + uint8_t ALWAYSON:1; /*!< bit: 7 Always-On */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} WDT_CTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define WDT_CTRL_OFFSET 0x0 /**< \brief (WDT_CTRL offset) Control */ +#define WDT_CTRL_RESETVALUE 0x00 /**< \brief (WDT_CTRL reset_value) Control */ + +#define WDT_CTRL_ENABLE_Pos 1 /**< \brief (WDT_CTRL) Enable */ +#define WDT_CTRL_ENABLE (0x1u << WDT_CTRL_ENABLE_Pos) +#define WDT_CTRL_WEN_Pos 2 /**< \brief (WDT_CTRL) Watchdog Timer Window Mode Enable */ +#define WDT_CTRL_WEN (0x1u << WDT_CTRL_WEN_Pos) +#define WDT_CTRL_ALWAYSON_Pos 7 /**< \brief (WDT_CTRL) Always-On */ +#define WDT_CTRL_ALWAYSON (0x1u << WDT_CTRL_ALWAYSON_Pos) +#define WDT_CTRL_MASK 0x86u /**< \brief (WDT_CTRL) MASK Register */ + +/* -------- WDT_CONFIG : (WDT Offset: 0x1) (R/W 8) Configuration -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t PER:4; /*!< bit: 0.. 3 Time-Out Period */ + uint8_t WINDOW:4; /*!< bit: 4.. 7 Window Mode Time-Out Period */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} WDT_CONFIG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define WDT_CONFIG_OFFSET 0x1 /**< \brief (WDT_CONFIG offset) Configuration */ +#define WDT_CONFIG_RESETVALUE 0xBB /**< \brief (WDT_CONFIG reset_value) Configuration */ + +#define WDT_CONFIG_PER_Pos 0 /**< \brief (WDT_CONFIG) Time-Out Period */ +#define WDT_CONFIG_PER_Msk (0xFu << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER(value) ((WDT_CONFIG_PER_Msk & ((value) << WDT_CONFIG_PER_Pos))) +#define WDT_CONFIG_PER_0_Val 0x0u /**< \brief (WDT_CONFIG) 8 clock cycles */ +#define WDT_CONFIG_PER_1_Val 0x1u /**< \brief (WDT_CONFIG) 16 clock cycles */ +#define WDT_CONFIG_PER_2_Val 0x2u /**< \brief (WDT_CONFIG) 32 clock cycles */ +#define WDT_CONFIG_PER_3_Val 0x3u /**< \brief (WDT_CONFIG) 64 clock cycles */ +#define WDT_CONFIG_PER_4_Val 0x4u /**< \brief (WDT_CONFIG) 128 clock cycles */ +#define WDT_CONFIG_PER_5_Val 0x5u /**< \brief (WDT_CONFIG) 256 clock cycles */ +#define WDT_CONFIG_PER_6_Val 0x6u /**< \brief (WDT_CONFIG) 512 clock cycles */ +#define WDT_CONFIG_PER_7_Val 0x7u /**< \brief (WDT_CONFIG) 1024 clock cycles */ +#define WDT_CONFIG_PER_8_Val 0x8u /**< \brief (WDT_CONFIG) 2048 clock cycles */ +#define WDT_CONFIG_PER_9_Val 0x9u /**< \brief (WDT_CONFIG) 4096 clock cycles */ +#define WDT_CONFIG_PER_10_Val 0xAu /**< \brief (WDT_CONFIG) 8192 clock cycles */ +#define WDT_CONFIG_PER_11_Val 0xBu /**< \brief (WDT_CONFIG) 16384 clock cycles */ +#define WDT_CONFIG_PER_0 (WDT_CONFIG_PER_0_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_1 (WDT_CONFIG_PER_1_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_2 (WDT_CONFIG_PER_2_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_3 (WDT_CONFIG_PER_3_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_4 (WDT_CONFIG_PER_4_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_5 (WDT_CONFIG_PER_5_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_6 (WDT_CONFIG_PER_6_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_7 (WDT_CONFIG_PER_7_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_8 (WDT_CONFIG_PER_8_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_9 (WDT_CONFIG_PER_9_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_10 (WDT_CONFIG_PER_10_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_PER_11 (WDT_CONFIG_PER_11_Val << WDT_CONFIG_PER_Pos) +#define WDT_CONFIG_WINDOW_Pos 4 /**< \brief (WDT_CONFIG) Window Mode Time-Out Period */ +#define WDT_CONFIG_WINDOW_Msk (0xFu << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW(value) ((WDT_CONFIG_WINDOW_Msk & ((value) << WDT_CONFIG_WINDOW_Pos))) +#define WDT_CONFIG_WINDOW_0_Val 0x0u /**< \brief (WDT_CONFIG) 8 clock cycles */ +#define WDT_CONFIG_WINDOW_1_Val 0x1u /**< \brief (WDT_CONFIG) 16 clock cycles */ +#define WDT_CONFIG_WINDOW_2_Val 0x2u /**< \brief (WDT_CONFIG) 32 clock cycles */ +#define WDT_CONFIG_WINDOW_3_Val 0x3u /**< \brief (WDT_CONFIG) 64 clock cycles */ +#define WDT_CONFIG_WINDOW_4_Val 0x4u /**< \brief (WDT_CONFIG) 128 clock cycles */ +#define WDT_CONFIG_WINDOW_5_Val 0x5u /**< \brief (WDT_CONFIG) 256 clock cycles */ +#define WDT_CONFIG_WINDOW_6_Val 0x6u /**< \brief (WDT_CONFIG) 512 clock cycles */ +#define WDT_CONFIG_WINDOW_7_Val 0x7u /**< \brief (WDT_CONFIG) 1024 clock cycles */ +#define WDT_CONFIG_WINDOW_8_Val 0x8u /**< \brief (WDT_CONFIG) 2048 clock cycles */ +#define WDT_CONFIG_WINDOW_9_Val 0x9u /**< \brief (WDT_CONFIG) 4096 clock cycles */ +#define WDT_CONFIG_WINDOW_10_Val 0xAu /**< \brief (WDT_CONFIG) 8192 clock cycles */ +#define WDT_CONFIG_WINDOW_11_Val 0xBu /**< \brief (WDT_CONFIG) 16384 clock cycles */ +#define WDT_CONFIG_WINDOW_0 (WDT_CONFIG_WINDOW_0_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_1 (WDT_CONFIG_WINDOW_1_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_2 (WDT_CONFIG_WINDOW_2_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_3 (WDT_CONFIG_WINDOW_3_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_4 (WDT_CONFIG_WINDOW_4_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_5 (WDT_CONFIG_WINDOW_5_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_6 (WDT_CONFIG_WINDOW_6_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_7 (WDT_CONFIG_WINDOW_7_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_8 (WDT_CONFIG_WINDOW_8_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_9 (WDT_CONFIG_WINDOW_9_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_10 (WDT_CONFIG_WINDOW_10_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_WINDOW_11 (WDT_CONFIG_WINDOW_11_Val << WDT_CONFIG_WINDOW_Pos) +#define WDT_CONFIG_MASK 0xFFu /**< \brief (WDT_CONFIG) MASK Register */ + +/* -------- WDT_EWCTRL : (WDT Offset: 0x2) (R/W 8) Early Warning Interrupt Control -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t EWOFFSET:4; /*!< bit: 0.. 3 Early Warning Interrupt Time Offset */ + uint8_t :4; /*!< bit: 4.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} WDT_EWCTRL_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define WDT_EWCTRL_OFFSET 0x2 /**< \brief (WDT_EWCTRL offset) Early Warning Interrupt Control */ +#define WDT_EWCTRL_RESETVALUE 0x0B /**< \brief (WDT_EWCTRL reset_value) Early Warning Interrupt Control */ + +#define WDT_EWCTRL_EWOFFSET_Pos 0 /**< \brief (WDT_EWCTRL) Early Warning Interrupt Time Offset */ +#define WDT_EWCTRL_EWOFFSET_Msk (0xFu << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET(value) ((WDT_EWCTRL_EWOFFSET_Msk & ((value) << WDT_EWCTRL_EWOFFSET_Pos))) +#define WDT_EWCTRL_EWOFFSET_0_Val 0x0u /**< \brief (WDT_EWCTRL) 8 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_1_Val 0x1u /**< \brief (WDT_EWCTRL) 16 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_2_Val 0x2u /**< \brief (WDT_EWCTRL) 32 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_3_Val 0x3u /**< \brief (WDT_EWCTRL) 64 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_4_Val 0x4u /**< \brief (WDT_EWCTRL) 128 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_5_Val 0x5u /**< \brief (WDT_EWCTRL) 256 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_6_Val 0x6u /**< \brief (WDT_EWCTRL) 512 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_7_Val 0x7u /**< \brief (WDT_EWCTRL) 1024 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_8_Val 0x8u /**< \brief (WDT_EWCTRL) 2048 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_9_Val 0x9u /**< \brief (WDT_EWCTRL) 4096 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_10_Val 0xAu /**< \brief (WDT_EWCTRL) 8192 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_11_Val 0xBu /**< \brief (WDT_EWCTRL) 16384 clock cycles */ +#define WDT_EWCTRL_EWOFFSET_0 (WDT_EWCTRL_EWOFFSET_0_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_1 (WDT_EWCTRL_EWOFFSET_1_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_2 (WDT_EWCTRL_EWOFFSET_2_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_3 (WDT_EWCTRL_EWOFFSET_3_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_4 (WDT_EWCTRL_EWOFFSET_4_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_5 (WDT_EWCTRL_EWOFFSET_5_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_6 (WDT_EWCTRL_EWOFFSET_6_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_7 (WDT_EWCTRL_EWOFFSET_7_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_8 (WDT_EWCTRL_EWOFFSET_8_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_9 (WDT_EWCTRL_EWOFFSET_9_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_10 (WDT_EWCTRL_EWOFFSET_10_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_EWOFFSET_11 (WDT_EWCTRL_EWOFFSET_11_Val << WDT_EWCTRL_EWOFFSET_Pos) +#define WDT_EWCTRL_MASK 0x0Fu /**< \brief (WDT_EWCTRL) MASK Register */ + +/* -------- WDT_INTENCLR : (WDT Offset: 0x4) (R/W 8) Interrupt Enable Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t EW:1; /*!< bit: 0 Early Warning Interrupt Enable */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} WDT_INTENCLR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define WDT_INTENCLR_OFFSET 0x4 /**< \brief (WDT_INTENCLR offset) Interrupt Enable Clear */ +#define WDT_INTENCLR_RESETVALUE 0x00 /**< \brief (WDT_INTENCLR reset_value) Interrupt Enable Clear */ + +#define WDT_INTENCLR_EW_Pos 0 /**< \brief (WDT_INTENCLR) Early Warning Interrupt Enable */ +#define WDT_INTENCLR_EW (0x1u << WDT_INTENCLR_EW_Pos) +#define WDT_INTENCLR_MASK 0x01u /**< \brief (WDT_INTENCLR) MASK Register */ + +/* -------- WDT_INTENSET : (WDT Offset: 0x5) (R/W 8) Interrupt Enable Set -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t EW:1; /*!< bit: 0 Early Warning Interrupt Enable */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} WDT_INTENSET_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define WDT_INTENSET_OFFSET 0x5 /**< \brief (WDT_INTENSET offset) Interrupt Enable Set */ +#define WDT_INTENSET_RESETVALUE 0x00 /**< \brief (WDT_INTENSET reset_value) Interrupt Enable Set */ + +#define WDT_INTENSET_EW_Pos 0 /**< \brief (WDT_INTENSET) Early Warning Interrupt Enable */ +#define WDT_INTENSET_EW (0x1u << WDT_INTENSET_EW_Pos) +#define WDT_INTENSET_MASK 0x01u /**< \brief (WDT_INTENSET) MASK Register */ + +/* -------- WDT_INTFLAG : (WDT Offset: 0x6) (R/W 8) Interrupt Flag Status and Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t EW:1; /*!< bit: 0 Early Warning */ + uint8_t :7; /*!< bit: 1.. 7 Reserved */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} WDT_INTFLAG_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define WDT_INTFLAG_OFFSET 0x6 /**< \brief (WDT_INTFLAG offset) Interrupt Flag Status and Clear */ +#define WDT_INTFLAG_RESETVALUE 0x00 /**< \brief (WDT_INTFLAG reset_value) Interrupt Flag Status and Clear */ + +#define WDT_INTFLAG_EW_Pos 0 /**< \brief (WDT_INTFLAG) Early Warning */ +#define WDT_INTFLAG_EW (0x1u << WDT_INTFLAG_EW_Pos) +#define WDT_INTFLAG_MASK 0x01u /**< \brief (WDT_INTFLAG) MASK Register */ + +/* -------- WDT_STATUS : (WDT Offset: 0x7) (R/ 8) Status -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t :7; /*!< bit: 0.. 6 Reserved */ + uint8_t SYNCBUSY:1; /*!< bit: 7 Synchronization Busy */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} WDT_STATUS_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define WDT_STATUS_OFFSET 0x7 /**< \brief (WDT_STATUS offset) Status */ +#define WDT_STATUS_RESETVALUE 0x00 /**< \brief (WDT_STATUS reset_value) Status */ + +#define WDT_STATUS_SYNCBUSY_Pos 7 /**< \brief (WDT_STATUS) Synchronization Busy */ +#define WDT_STATUS_SYNCBUSY (0x1u << WDT_STATUS_SYNCBUSY_Pos) +#define WDT_STATUS_MASK 0x80u /**< \brief (WDT_STATUS) MASK Register */ + +/* -------- WDT_CLEAR : (WDT Offset: 0x8) ( /W 8) Clear -------- */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef union { + struct { + uint8_t CLEAR:8; /*!< bit: 0.. 7 Watchdog Clear */ + } bit; /*!< Structure used for bit access */ + uint8_t reg; /*!< Type used for register access */ +} WDT_CLEAR_Type; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +#define WDT_CLEAR_OFFSET 0x8 /**< \brief (WDT_CLEAR offset) Clear */ +#define WDT_CLEAR_RESETVALUE 0x00 /**< \brief (WDT_CLEAR reset_value) Clear */ + +#define WDT_CLEAR_CLEAR_Pos 0 /**< \brief (WDT_CLEAR) Watchdog Clear */ +#define WDT_CLEAR_CLEAR_Msk (0xFFu << WDT_CLEAR_CLEAR_Pos) +#define WDT_CLEAR_CLEAR(value) ((WDT_CLEAR_CLEAR_Msk & ((value) << WDT_CLEAR_CLEAR_Pos))) +#define WDT_CLEAR_CLEAR_KEY_Val 0xA5u /**< \brief (WDT_CLEAR) Clear Key */ +#define WDT_CLEAR_CLEAR_KEY (WDT_CLEAR_CLEAR_KEY_Val << WDT_CLEAR_CLEAR_Pos) +#define WDT_CLEAR_MASK 0xFFu /**< \brief (WDT_CLEAR) MASK Register */ + +/** \brief WDT hardware registers */ +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +typedef struct { + __IO WDT_CTRL_Type CTRL; /**< \brief Offset: 0x0 (R/W 8) Control */ + __IO WDT_CONFIG_Type CONFIG; /**< \brief Offset: 0x1 (R/W 8) Configuration */ + __IO WDT_EWCTRL_Type EWCTRL; /**< \brief Offset: 0x2 (R/W 8) Early Warning Interrupt Control */ + RoReg8 Reserved1[0x1]; + __IO WDT_INTENCLR_Type INTENCLR; /**< \brief Offset: 0x4 (R/W 8) Interrupt Enable Clear */ + __IO WDT_INTENSET_Type INTENSET; /**< \brief Offset: 0x5 (R/W 8) Interrupt Enable Set */ + __IO WDT_INTFLAG_Type INTFLAG; /**< \brief Offset: 0x6 (R/W 8) Interrupt Flag Status and Clear */ + __I WDT_STATUS_Type STATUS; /**< \brief Offset: 0x7 (R/ 8) Status */ + __O WDT_CLEAR_Type CLEAR; /**< \brief Offset: 0x8 ( /W 8) Clear */ +} Wdt; +#endif /* !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/*@}*/ + +#endif /* _SAMD21_WDT_COMPONENT_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/ac.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/ac.h new file mode 100755 index 0000000..5beec63 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/ac.h @@ -0,0 +1,87 @@ +/** + * \file + * + * \brief Instance description for AC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_AC_INSTANCE_ +#define _SAMD21_AC_INSTANCE_ + +/* ========== Register definition for AC peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_AC_CTRLA (0x42004400U) /**< \brief (AC) Control A */ +#define REG_AC_CTRLB (0x42004401U) /**< \brief (AC) Control B */ +#define REG_AC_EVCTRL (0x42004402U) /**< \brief (AC) Event Control */ +#define REG_AC_INTENCLR (0x42004404U) /**< \brief (AC) Interrupt Enable Clear */ +#define REG_AC_INTENSET (0x42004405U) /**< \brief (AC) Interrupt Enable Set */ +#define REG_AC_INTFLAG (0x42004406U) /**< \brief (AC) Interrupt Flag Status and Clear */ +#define REG_AC_STATUSA (0x42004408U) /**< \brief (AC) Status A */ +#define REG_AC_STATUSB (0x42004409U) /**< \brief (AC) Status B */ +#define REG_AC_STATUSC (0x4200440AU) /**< \brief (AC) Status C */ +#define REG_AC_WINCTRL (0x4200440CU) /**< \brief (AC) Window Control */ +#define REG_AC_COMPCTRL0 (0x42004410U) /**< \brief (AC) Comparator Control 0 */ +#define REG_AC_COMPCTRL1 (0x42004414U) /**< \brief (AC) Comparator Control 1 */ +#define REG_AC_SCALER0 (0x42004420U) /**< \brief (AC) Scaler 0 */ +#define REG_AC_SCALER1 (0x42004421U) /**< \brief (AC) Scaler 1 */ +#else +#define REG_AC_CTRLA (*(RwReg8 *)0x42004400U) /**< \brief (AC) Control A */ +#define REG_AC_CTRLB (*(WoReg8 *)0x42004401U) /**< \brief (AC) Control B */ +#define REG_AC_EVCTRL (*(RwReg16*)0x42004402U) /**< \brief (AC) Event Control */ +#define REG_AC_INTENCLR (*(RwReg8 *)0x42004404U) /**< \brief (AC) Interrupt Enable Clear */ +#define REG_AC_INTENSET (*(RwReg8 *)0x42004405U) /**< \brief (AC) Interrupt Enable Set */ +#define REG_AC_INTFLAG (*(RwReg8 *)0x42004406U) /**< \brief (AC) Interrupt Flag Status and Clear */ +#define REG_AC_STATUSA (*(RoReg8 *)0x42004408U) /**< \brief (AC) Status A */ +#define REG_AC_STATUSB (*(RoReg8 *)0x42004409U) /**< \brief (AC) Status B */ +#define REG_AC_STATUSC (*(RoReg8 *)0x4200440AU) /**< \brief (AC) Status C */ +#define REG_AC_WINCTRL (*(RwReg8 *)0x4200440CU) /**< \brief (AC) Window Control */ +#define REG_AC_COMPCTRL0 (*(RwReg *)0x42004410U) /**< \brief (AC) Comparator Control 0 */ +#define REG_AC_COMPCTRL1 (*(RwReg *)0x42004414U) /**< \brief (AC) Comparator Control 1 */ +#define REG_AC_SCALER0 (*(RwReg8 *)0x42004420U) /**< \brief (AC) Scaler 0 */ +#define REG_AC_SCALER1 (*(RwReg8 *)0x42004421U) /**< \brief (AC) Scaler 1 */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for AC peripheral ========== */ +#define AC_CMP_NUM 2 +#define AC_GCLK_ID_ANA 32 +#define AC_GCLK_ID_DIG 31 +#define AC_NUM_CMP AC_CMP_NUM +#define AC_PAIRS 1 + +#endif /* _SAMD21_AC_INSTANCE_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/adc.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/adc.h new file mode 100755 index 0000000..fedabae --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/adc.h @@ -0,0 +1,99 @@ +/** + * \file + * + * \brief Instance description for ADC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_ADC_INSTANCE_ +#define _SAMD21_ADC_INSTANCE_ + +/* ========== Register definition for ADC peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_ADC_CTRLA (0x42004000U) /**< \brief (ADC) Control A */ +#define REG_ADC_REFCTRL (0x42004001U) /**< \brief (ADC) Reference Control */ +#define REG_ADC_AVGCTRL (0x42004002U) /**< \brief (ADC) Average Control */ +#define REG_ADC_SAMPCTRL (0x42004003U) /**< \brief (ADC) Sampling Time Control */ +#define REG_ADC_CTRLB (0x42004004U) /**< \brief (ADC) Control B */ +#define REG_ADC_WINCTRL (0x42004008U) /**< \brief (ADC) Window Monitor Control */ +#define REG_ADC_SWTRIG (0x4200400CU) /**< \brief (ADC) Software Trigger */ +#define REG_ADC_INPUTCTRL (0x42004010U) /**< \brief (ADC) Input Control */ +#define REG_ADC_EVCTRL (0x42004014U) /**< \brief (ADC) Event Control */ +#define REG_ADC_INTENCLR (0x42004016U) /**< \brief (ADC) Interrupt Enable Clear */ +#define REG_ADC_INTENSET (0x42004017U) /**< \brief (ADC) Interrupt Enable Set */ +#define REG_ADC_INTFLAG (0x42004018U) /**< \brief (ADC) Interrupt Flag Status and Clear */ +#define REG_ADC_STATUS (0x42004019U) /**< \brief (ADC) Status */ +#define REG_ADC_RESULT (0x4200401AU) /**< \brief (ADC) Result */ +#define REG_ADC_WINLT (0x4200401CU) /**< \brief (ADC) Window Monitor Lower Threshold */ +#define REG_ADC_WINUT (0x42004020U) /**< \brief (ADC) Window Monitor Upper Threshold */ +#define REG_ADC_GAINCORR (0x42004024U) /**< \brief (ADC) Gain Correction */ +#define REG_ADC_OFFSETCORR (0x42004026U) /**< \brief (ADC) Offset Correction */ +#define REG_ADC_CALIB (0x42004028U) /**< \brief (ADC) Calibration */ +#define REG_ADC_DBGCTRL (0x4200402AU) /**< \brief (ADC) Debug Control */ +#else +#define REG_ADC_CTRLA (*(RwReg8 *)0x42004000U) /**< \brief (ADC) Control A */ +#define REG_ADC_REFCTRL (*(RwReg8 *)0x42004001U) /**< \brief (ADC) Reference Control */ +#define REG_ADC_AVGCTRL (*(RwReg8 *)0x42004002U) /**< \brief (ADC) Average Control */ +#define REG_ADC_SAMPCTRL (*(RwReg8 *)0x42004003U) /**< \brief (ADC) Sampling Time Control */ +#define REG_ADC_CTRLB (*(RwReg16*)0x42004004U) /**< \brief (ADC) Control B */ +#define REG_ADC_WINCTRL (*(RwReg8 *)0x42004008U) /**< \brief (ADC) Window Monitor Control */ +#define REG_ADC_SWTRIG (*(RwReg8 *)0x4200400CU) /**< \brief (ADC) Software Trigger */ +#define REG_ADC_INPUTCTRL (*(RwReg *)0x42004010U) /**< \brief (ADC) Input Control */ +#define REG_ADC_EVCTRL (*(RwReg8 *)0x42004014U) /**< \brief (ADC) Event Control */ +#define REG_ADC_INTENCLR (*(RwReg8 *)0x42004016U) /**< \brief (ADC) Interrupt Enable Clear */ +#define REG_ADC_INTENSET (*(RwReg8 *)0x42004017U) /**< \brief (ADC) Interrupt Enable Set */ +#define REG_ADC_INTFLAG (*(RwReg8 *)0x42004018U) /**< \brief (ADC) Interrupt Flag Status and Clear */ +#define REG_ADC_STATUS (*(RoReg8 *)0x42004019U) /**< \brief (ADC) Status */ +#define REG_ADC_RESULT (*(RoReg16*)0x4200401AU) /**< \brief (ADC) Result */ +#define REG_ADC_WINLT (*(RwReg16*)0x4200401CU) /**< \brief (ADC) Window Monitor Lower Threshold */ +#define REG_ADC_WINUT (*(RwReg16*)0x42004020U) /**< \brief (ADC) Window Monitor Upper Threshold */ +#define REG_ADC_GAINCORR (*(RwReg16*)0x42004024U) /**< \brief (ADC) Gain Correction */ +#define REG_ADC_OFFSETCORR (*(RwReg16*)0x42004026U) /**< \brief (ADC) Offset Correction */ +#define REG_ADC_CALIB (*(RwReg16*)0x42004028U) /**< \brief (ADC) Calibration */ +#define REG_ADC_DBGCTRL (*(RwReg8 *)0x4200402AU) /**< \brief (ADC) Debug Control */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for ADC peripheral ========== */ +#define ADC_DMAC_ID_RESRDY 39 +#define ADC_EXTCHANNEL_MSB 19 +#define ADC_GCLK_ID 30 +#define ADC_RESULT_BITS 16 +#define ADC_RESULT_MSB (ADC_RESULT_BITS-1) + +#endif /* _SAMD21_ADC_INSTANCE_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/dac.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/dac.h new file mode 100755 index 0000000..25c2a89 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/dac.h @@ -0,0 +1,74 @@ +/** + * \file + * + * \brief Instance description for DAC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_DAC_INSTANCE_ +#define _SAMD21_DAC_INSTANCE_ + +/* ========== Register definition for DAC peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_DAC_CTRLA (0x42004800U) /**< \brief (DAC) Control A */ +#define REG_DAC_CTRLB (0x42004801U) /**< \brief (DAC) Control B */ +#define REG_DAC_EVCTRL (0x42004802U) /**< \brief (DAC) Event Control */ +#define REG_DAC_INTENCLR (0x42004804U) /**< \brief (DAC) Interrupt Enable Clear */ +#define REG_DAC_INTENSET (0x42004805U) /**< \brief (DAC) Interrupt Enable Set */ +#define REG_DAC_INTFLAG (0x42004806U) /**< \brief (DAC) Interrupt Flag Status and Clear */ +#define REG_DAC_STATUS (0x42004807U) /**< \brief (DAC) Status */ +#define REG_DAC_DATA (0x42004808U) /**< \brief (DAC) Data */ +#define REG_DAC_DATABUF (0x4200480CU) /**< \brief (DAC) Data Buffer */ +#else +#define REG_DAC_CTRLA (*(RwReg8 *)0x42004800U) /**< \brief (DAC) Control A */ +#define REG_DAC_CTRLB (*(RwReg8 *)0x42004801U) /**< \brief (DAC) Control B */ +#define REG_DAC_EVCTRL (*(RwReg8 *)0x42004802U) /**< \brief (DAC) Event Control */ +#define REG_DAC_INTENCLR (*(RwReg8 *)0x42004804U) /**< \brief (DAC) Interrupt Enable Clear */ +#define REG_DAC_INTENSET (*(RwReg8 *)0x42004805U) /**< \brief (DAC) Interrupt Enable Set */ +#define REG_DAC_INTFLAG (*(RwReg8 *)0x42004806U) /**< \brief (DAC) Interrupt Flag Status and Clear */ +#define REG_DAC_STATUS (*(RoReg8 *)0x42004807U) /**< \brief (DAC) Status */ +#define REG_DAC_DATA (*(RwReg16*)0x42004808U) /**< \brief (DAC) Data */ +#define REG_DAC_DATABUF (*(RwReg16*)0x4200480CU) /**< \brief (DAC) Data Buffer */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for DAC peripheral ========== */ +#define DAC_DMAC_ID_EMPTY 40 +#define DAC_GCLK_ID 33 + +#endif /* _SAMD21_DAC_INSTANCE_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/dmac.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/dmac.h new file mode 100755 index 0000000..c82818d --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/dmac.h @@ -0,0 +1,107 @@ +/** + * \file + * + * \brief Instance description for DMAC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_DMAC_INSTANCE_ +#define _SAMD21_DMAC_INSTANCE_ + +/* ========== Register definition for DMAC peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_DMAC_CTRL (0x41004800U) /**< \brief (DMAC) Control */ +#define REG_DMAC_CRCCTRL (0x41004802U) /**< \brief (DMAC) CRC Control */ +#define REG_DMAC_CRCDATAIN (0x41004804U) /**< \brief (DMAC) CRC Data Input */ +#define REG_DMAC_CRCCHKSUM (0x41004808U) /**< \brief (DMAC) CRC Checksum */ +#define REG_DMAC_CRCSTATUS (0x4100480CU) /**< \brief (DMAC) CRC Status */ +#define REG_DMAC_DBGCTRL (0x4100480DU) /**< \brief (DMAC) Debug Control */ +#define REG_DMAC_SWTRIGCTRL (0x41004810U) /**< \brief (DMAC) Software Trigger Control */ +#define REG_DMAC_PRICTRL0 (0x41004814U) /**< \brief (DMAC) Priority Control 0 */ +#define REG_DMAC_INTPEND (0x41004820U) /**< \brief (DMAC) Interrupt Pending */ +#define REG_DMAC_INTSTATUS (0x41004824U) /**< \brief (DMAC) Interrupt Status */ +#define REG_DMAC_BUSYCH (0x41004828U) /**< \brief (DMAC) Busy Channels */ +#define REG_DMAC_PENDCH (0x4100482CU) /**< \brief (DMAC) Pending Channels */ +#define REG_DMAC_ACTIVE (0x41004830U) /**< \brief (DMAC) Active Channel and Levels */ +#define REG_DMAC_BASEADDR (0x41004834U) /**< \brief (DMAC) Descriptor Memory Section Base Address */ +#define REG_DMAC_WRBADDR (0x41004838U) /**< \brief (DMAC) Write-Back Memory Section Base Address */ +#define REG_DMAC_CHID (0x4100483FU) /**< \brief (DMAC) Channel ID */ +#define REG_DMAC_CHCTRLA (0x41004840U) /**< \brief (DMAC) Channel Control A */ +#define REG_DMAC_CHCTRLB (0x41004844U) /**< \brief (DMAC) Channel Control B */ +#define REG_DMAC_CHINTENCLR (0x4100484CU) /**< \brief (DMAC) Channel Interrupt Enable Clear */ +#define REG_DMAC_CHINTENSET (0x4100484DU) /**< \brief (DMAC) Channel Interrupt Enable Set */ +#define REG_DMAC_CHINTFLAG (0x4100484EU) /**< \brief (DMAC) Channel Interrupt Flag Status and Clear */ +#define REG_DMAC_CHSTATUS (0x4100484FU) /**< \brief (DMAC) Channel Status */ +#else +#define REG_DMAC_CTRL (*(RwReg16*)0x41004800U) /**< \brief (DMAC) Control */ +#define REG_DMAC_CRCCTRL (*(RwReg16*)0x41004802U) /**< \brief (DMAC) CRC Control */ +#define REG_DMAC_CRCDATAIN (*(RwReg *)0x41004804U) /**< \brief (DMAC) CRC Data Input */ +#define REG_DMAC_CRCCHKSUM (*(RwReg *)0x41004808U) /**< \brief (DMAC) CRC Checksum */ +#define REG_DMAC_CRCSTATUS (*(RwReg8 *)0x4100480CU) /**< \brief (DMAC) CRC Status */ +#define REG_DMAC_DBGCTRL (*(RwReg8 *)0x4100480DU) /**< \brief (DMAC) Debug Control */ +#define REG_DMAC_SWTRIGCTRL (*(RwReg *)0x41004810U) /**< \brief (DMAC) Software Trigger Control */ +#define REG_DMAC_PRICTRL0 (*(RwReg *)0x41004814U) /**< \brief (DMAC) Priority Control 0 */ +#define REG_DMAC_INTPEND (*(RwReg16*)0x41004820U) /**< \brief (DMAC) Interrupt Pending */ +#define REG_DMAC_INTSTATUS (*(RoReg *)0x41004824U) /**< \brief (DMAC) Interrupt Status */ +#define REG_DMAC_BUSYCH (*(RoReg *)0x41004828U) /**< \brief (DMAC) Busy Channels */ +#define REG_DMAC_PENDCH (*(RoReg *)0x4100482CU) /**< \brief (DMAC) Pending Channels */ +#define REG_DMAC_ACTIVE (*(RoReg *)0x41004830U) /**< \brief (DMAC) Active Channel and Levels */ +#define REG_DMAC_BASEADDR (*(RwReg *)0x41004834U) /**< \brief (DMAC) Descriptor Memory Section Base Address */ +#define REG_DMAC_WRBADDR (*(RwReg *)0x41004838U) /**< \brief (DMAC) Write-Back Memory Section Base Address */ +#define REG_DMAC_CHID (*(RwReg8 *)0x4100483FU) /**< \brief (DMAC) Channel ID */ +#define REG_DMAC_CHCTRLA (*(RwReg8 *)0x41004840U) /**< \brief (DMAC) Channel Control A */ +#define REG_DMAC_CHCTRLB (*(RwReg *)0x41004844U) /**< \brief (DMAC) Channel Control B */ +#define REG_DMAC_CHINTENCLR (*(RwReg8 *)0x4100484CU) /**< \brief (DMAC) Channel Interrupt Enable Clear */ +#define REG_DMAC_CHINTENSET (*(RwReg8 *)0x4100484DU) /**< \brief (DMAC) Channel Interrupt Enable Set */ +#define REG_DMAC_CHINTFLAG (*(RwReg8 *)0x4100484EU) /**< \brief (DMAC) Channel Interrupt Flag Status and Clear */ +#define REG_DMAC_CHSTATUS (*(RoReg8 *)0x4100484FU) /**< \brief (DMAC) Channel Status */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for DMAC peripheral ========== */ +#define DMAC_CH_BITS len(bin(DMAC_CH_NUM - 1))-2 +#define DMAC_CH_NUM 12 +#define DMAC_CLK_AHB_ID 5 +#define DMAC_EVIN_NUM 4 +#define DMAC_EVOUT_NUM 4 +#define DMAC_LVL_BITS len(bin(DMAC_LVL_NUM - 1))-2 +#define DMAC_LVL_NUM 4 +#define DMAC_TRIG_BITS len(bin(DMAC_TRIG_NUM - 1))-2 +#define DMAC_TRIG_NUM 45 + +#endif /* _SAMD21_DMAC_INSTANCE_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/dsu.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/dsu.h new file mode 100755 index 0000000..62b1151 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/dsu.h @@ -0,0 +1,99 @@ +/** + * \file + * + * \brief Instance description for DSU + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_DSU_INSTANCE_ +#define _SAMD21_DSU_INSTANCE_ + +/* ========== Register definition for DSU peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_DSU_CTRL (0x41002000U) /**< \brief (DSU) Control */ +#define REG_DSU_STATUSA (0x41002001U) /**< \brief (DSU) Status A */ +#define REG_DSU_STATUSB (0x41002002U) /**< \brief (DSU) Status B */ +#define REG_DSU_ADDR (0x41002004U) /**< \brief (DSU) Address */ +#define REG_DSU_LENGTH (0x41002008U) /**< \brief (DSU) Length */ +#define REG_DSU_DATA (0x4100200CU) /**< \brief (DSU) Data */ +#define REG_DSU_DCC0 (0x41002010U) /**< \brief (DSU) Debug Communication Channel 0 */ +#define REG_DSU_DCC1 (0x41002014U) /**< \brief (DSU) Debug Communication Channel 1 */ +#define REG_DSU_DID (0x41002018U) /**< \brief (DSU) Device Identification */ +#define REG_DSU_ENTRY0 (0x41003000U) /**< \brief (DSU) Coresight ROM Table Entry 0 */ +#define REG_DSU_ENTRY1 (0x41003004U) /**< \brief (DSU) Coresight ROM Table Entry 1 */ +#define REG_DSU_END (0x41003008U) /**< \brief (DSU) Coresight ROM Table End */ +#define REG_DSU_MEMTYPE (0x41003FCCU) /**< \brief (DSU) Coresight ROM Table Memory Type */ +#define REG_DSU_PID4 (0x41003FD0U) /**< \brief (DSU) Peripheral Identification 4 */ +#define REG_DSU_PID0 (0x41003FE0U) /**< \brief (DSU) Peripheral Identification 0 */ +#define REG_DSU_PID1 (0x41003FE4U) /**< \brief (DSU) Peripheral Identification 1 */ +#define REG_DSU_PID2 (0x41003FE8U) /**< \brief (DSU) Peripheral Identification 2 */ +#define REG_DSU_PID3 (0x41003FECU) /**< \brief (DSU) Peripheral Identification 3 */ +#define REG_DSU_CID0 (0x41003FF0U) /**< \brief (DSU) Component Identification 0 */ +#define REG_DSU_CID1 (0x41003FF4U) /**< \brief (DSU) Component Identification 1 */ +#define REG_DSU_CID2 (0x41003FF8U) /**< \brief (DSU) Component Identification 2 */ +#define REG_DSU_CID3 (0x41003FFCU) /**< \brief (DSU) Component Identification 3 */ +#else +#define REG_DSU_CTRL (*(WoReg8 *)0x41002000U) /**< \brief (DSU) Control */ +#define REG_DSU_STATUSA (*(RwReg8 *)0x41002001U) /**< \brief (DSU) Status A */ +#define REG_DSU_STATUSB (*(RoReg8 *)0x41002002U) /**< \brief (DSU) Status B */ +#define REG_DSU_ADDR (*(RwReg *)0x41002004U) /**< \brief (DSU) Address */ +#define REG_DSU_LENGTH (*(RwReg *)0x41002008U) /**< \brief (DSU) Length */ +#define REG_DSU_DATA (*(RwReg *)0x4100200CU) /**< \brief (DSU) Data */ +#define REG_DSU_DCC0 (*(RwReg *)0x41002010U) /**< \brief (DSU) Debug Communication Channel 0 */ +#define REG_DSU_DCC1 (*(RwReg *)0x41002014U) /**< \brief (DSU) Debug Communication Channel 1 */ +#define REG_DSU_DID (*(RoReg *)0x41002018U) /**< \brief (DSU) Device Identification */ +#define REG_DSU_ENTRY0 (*(RoReg *)0x41003000U) /**< \brief (DSU) Coresight ROM Table Entry 0 */ +#define REG_DSU_ENTRY1 (*(RoReg *)0x41003004U) /**< \brief (DSU) Coresight ROM Table Entry 1 */ +#define REG_DSU_END (*(RoReg *)0x41003008U) /**< \brief (DSU) Coresight ROM Table End */ +#define REG_DSU_MEMTYPE (*(RoReg *)0x41003FCCU) /**< \brief (DSU) Coresight ROM Table Memory Type */ +#define REG_DSU_PID4 (*(RoReg *)0x41003FD0U) /**< \brief (DSU) Peripheral Identification 4 */ +#define REG_DSU_PID0 (*(RoReg *)0x41003FE0U) /**< \brief (DSU) Peripheral Identification 0 */ +#define REG_DSU_PID1 (*(RoReg *)0x41003FE4U) /**< \brief (DSU) Peripheral Identification 1 */ +#define REG_DSU_PID2 (*(RoReg *)0x41003FE8U) /**< \brief (DSU) Peripheral Identification 2 */ +#define REG_DSU_PID3 (*(RoReg *)0x41003FECU) /**< \brief (DSU) Peripheral Identification 3 */ +#define REG_DSU_CID0 (*(RoReg *)0x41003FF0U) /**< \brief (DSU) Component Identification 0 */ +#define REG_DSU_CID1 (*(RoReg *)0x41003FF4U) /**< \brief (DSU) Component Identification 1 */ +#define REG_DSU_CID2 (*(RoReg *)0x41003FF8U) /**< \brief (DSU) Component Identification 2 */ +#define REG_DSU_CID3 (*(RoReg *)0x41003FFCU) /**< \brief (DSU) Component Identification 3 */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for DSU peripheral ========== */ +#define DSU_CLK_HSB_ID 3 + +#endif /* _SAMD21_DSU_INSTANCE_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/eic.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/eic.h new file mode 100755 index 0000000..7d6f253 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/eic.h @@ -0,0 +1,78 @@ +/** + * \file + * + * \brief Instance description for EIC + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_EIC_INSTANCE_ +#define _SAMD21_EIC_INSTANCE_ + +/* ========== Register definition for EIC peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_EIC_CTRL (0x40001800U) /**< \brief (EIC) Control */ +#define REG_EIC_STATUS (0x40001801U) /**< \brief (EIC) Status */ +#define REG_EIC_NMICTRL (0x40001802U) /**< \brief (EIC) Non-Maskable Interrupt Control */ +#define REG_EIC_NMIFLAG (0x40001803U) /**< \brief (EIC) Non-Maskable Interrupt Flag Status and Clear */ +#define REG_EIC_EVCTRL (0x40001804U) /**< \brief (EIC) Event Control */ +#define REG_EIC_INTENCLR (0x40001808U) /**< \brief (EIC) Interrupt Enable Clear */ +#define REG_EIC_INTENSET (0x4000180CU) /**< \brief (EIC) Interrupt Enable Set */ +#define REG_EIC_INTFLAG (0x40001810U) /**< \brief (EIC) Interrupt Flag Status and Clear */ +#define REG_EIC_WAKEUP (0x40001814U) /**< \brief (EIC) Wake-Up Enable */ +#define REG_EIC_CONFIG0 (0x40001818U) /**< \brief (EIC) Configuration 0 */ +#define REG_EIC_CONFIG1 (0x4000181CU) /**< \brief (EIC) Configuration 1 */ +#else +#define REG_EIC_CTRL (*(RwReg8 *)0x40001800U) /**< \brief (EIC) Control */ +#define REG_EIC_STATUS (*(RoReg8 *)0x40001801U) /**< \brief (EIC) Status */ +#define REG_EIC_NMICTRL (*(RwReg8 *)0x40001802U) /**< \brief (EIC) Non-Maskable Interrupt Control */ +#define REG_EIC_NMIFLAG (*(RwReg8 *)0x40001803U) /**< \brief (EIC) Non-Maskable Interrupt Flag Status and Clear */ +#define REG_EIC_EVCTRL (*(RwReg *)0x40001804U) /**< \brief (EIC) Event Control */ +#define REG_EIC_INTENCLR (*(RwReg *)0x40001808U) /**< \brief (EIC) Interrupt Enable Clear */ +#define REG_EIC_INTENSET (*(RwReg *)0x4000180CU) /**< \brief (EIC) Interrupt Enable Set */ +#define REG_EIC_INTFLAG (*(RwReg *)0x40001810U) /**< \brief (EIC) Interrupt Flag Status and Clear */ +#define REG_EIC_WAKEUP (*(RwReg *)0x40001814U) /**< \brief (EIC) Wake-Up Enable */ +#define REG_EIC_CONFIG0 (*(RwReg *)0x40001818U) /**< \brief (EIC) Configuration 0 */ +#define REG_EIC_CONFIG1 (*(RwReg *)0x4000181CU) /**< \brief (EIC) Configuration 1 */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for EIC peripheral ========== */ +#define EIC_CONFIG_NUM ((EIC_EXTINT_NUM+7)/8) +#define EIC_GCLK_ID 5 + +#endif /* _SAMD21_EIC_INSTANCE_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/evsys.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/evsys.h new file mode 100755 index 0000000..8f94c5f --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/evsys.h @@ -0,0 +1,197 @@ +/** + * \file + * + * \brief Instance description for EVSYS + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_EVSYS_INSTANCE_ +#define _SAMD21_EVSYS_INSTANCE_ + +/* ========== Register definition for EVSYS peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_EVSYS_CTRL (0x42000400U) /**< \brief (EVSYS) Control */ +#define REG_EVSYS_CHANNEL (0x42000404U) /**< \brief (EVSYS) Channel */ +#define REG_EVSYS_USER (0x42000408U) /**< \brief (EVSYS) User Multiplexer */ +#define REG_EVSYS_CHSTATUS (0x4200040CU) /**< \brief (EVSYS) Channel Status */ +#define REG_EVSYS_INTENCLR (0x42000410U) /**< \brief (EVSYS) Interrupt Enable Clear */ +#define REG_EVSYS_INTENSET (0x42000414U) /**< \brief (EVSYS) Interrupt Enable Set */ +#define REG_EVSYS_INTFLAG (0x42000418U) /**< \brief (EVSYS) Interrupt Flag Status and Clear */ +#else +#define REG_EVSYS_CTRL (*(WoReg8 *)0x42000400U) /**< \brief (EVSYS) Control */ +#define REG_EVSYS_CHANNEL (*(RwReg *)0x42000404U) /**< \brief (EVSYS) Channel */ +#define REG_EVSYS_USER (*(RwReg16*)0x42000408U) /**< \brief (EVSYS) User Multiplexer */ +#define REG_EVSYS_CHSTATUS (*(RoReg *)0x4200040CU) /**< \brief (EVSYS) Channel Status */ +#define REG_EVSYS_INTENCLR (*(RwReg *)0x42000410U) /**< \brief (EVSYS) Interrupt Enable Clear */ +#define REG_EVSYS_INTENSET (*(RwReg *)0x42000414U) /**< \brief (EVSYS) Interrupt Enable Set */ +#define REG_EVSYS_INTFLAG (*(RwReg *)0x42000418U) /**< \brief (EVSYS) Interrupt Flag Status and Clear */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for EVSYS peripheral ========== */ +#define EVSYS_CHANNELS 12 +#define EVSYS_CHANNELS_BITS (len(bin(EVSYS_CHANNELS-1))-2) +#define EVSYS_CHANNELS_MSB (EVSYS_CHANNELS-1) +#define EVSYS_EXTEVT_NUM 0 +#define EVSYS_GCLK_ID_0 7 +#define EVSYS_GCLK_ID_1 8 +#define EVSYS_GCLK_ID_2 9 +#define EVSYS_GCLK_ID_3 10 +#define EVSYS_GCLK_ID_4 11 +#define EVSYS_GCLK_ID_5 12 +#define EVSYS_GCLK_ID_6 13 +#define EVSYS_GCLK_ID_7 14 +#define EVSYS_GCLK_ID_8 15 +#define EVSYS_GCLK_ID_9 16 +#define EVSYS_GCLK_ID_10 17 +#define EVSYS_GCLK_ID_11 18 +#define EVSYS_GCLK_ID_LSB 7 +#define EVSYS_GCLK_ID_MSB 18 +#define EVSYS_GCLK_ID_SIZE 12 +#define EVSYS_GENERATORS 73 +#define EVSYS_GENERATORS_BITS (len(bin(EVSYS_GENERATORS-1))-2) +#define EVSYS_USERS 29 +#define EVSYS_USERS_BITS (len(bin(EVSYS_USERS-1))-2) + +// GENERATORS +#define EVSYS_ID_GEN_RTC_CMP_0 1 +#define EVSYS_ID_GEN_RTC_CMP_1 2 +#define EVSYS_ID_GEN_RTC_OVF 3 +#define EVSYS_ID_GEN_RTC_PER_0 4 +#define EVSYS_ID_GEN_RTC_PER_1 5 +#define EVSYS_ID_GEN_RTC_PER_2 6 +#define EVSYS_ID_GEN_RTC_PER_3 7 +#define EVSYS_ID_GEN_RTC_PER_4 8 +#define EVSYS_ID_GEN_RTC_PER_5 9 +#define EVSYS_ID_GEN_RTC_PER_6 10 +#define EVSYS_ID_GEN_RTC_PER_7 11 +#define EVSYS_ID_GEN_EIC_EXTINT_0 12 +#define EVSYS_ID_GEN_EIC_EXTINT_1 13 +#define EVSYS_ID_GEN_EIC_EXTINT_2 14 +#define EVSYS_ID_GEN_EIC_EXTINT_3 15 +#define EVSYS_ID_GEN_EIC_EXTINT_4 16 +#define EVSYS_ID_GEN_EIC_EXTINT_5 17 +#define EVSYS_ID_GEN_EIC_EXTINT_6 18 +#define EVSYS_ID_GEN_EIC_EXTINT_7 19 +#define EVSYS_ID_GEN_EIC_EXTINT_8 20 +#define EVSYS_ID_GEN_EIC_EXTINT_9 21 +#define EVSYS_ID_GEN_EIC_EXTINT_10 22 +#define EVSYS_ID_GEN_EIC_EXTINT_11 23 +#define EVSYS_ID_GEN_EIC_EXTINT_12 24 +#define EVSYS_ID_GEN_EIC_EXTINT_13 25 +#define EVSYS_ID_GEN_EIC_EXTINT_14 26 +#define EVSYS_ID_GEN_EIC_EXTINT_15 27 +#define EVSYS_ID_GEN_EIC_EXTINT_16 28 +#define EVSYS_ID_GEN_EIC_EXTINT_17 29 +#define EVSYS_ID_GEN_DMAC_CH_0 30 +#define EVSYS_ID_GEN_DMAC_CH_1 31 +#define EVSYS_ID_GEN_DMAC_CH_2 32 +#define EVSYS_ID_GEN_DMAC_CH_3 33 +#define EVSYS_ID_GEN_TCC0_OVF 34 +#define EVSYS_ID_GEN_TCC0_TRG 35 +#define EVSYS_ID_GEN_TCC0_CNT 36 +#define EVSYS_ID_GEN_TCC0_MCX_0 37 +#define EVSYS_ID_GEN_TCC0_MCX_1 38 +#define EVSYS_ID_GEN_TCC0_MCX_2 39 +#define EVSYS_ID_GEN_TCC0_MCX_3 40 +#define EVSYS_ID_GEN_TCC1_OVF 41 +#define EVSYS_ID_GEN_TCC1_TRG 42 +#define EVSYS_ID_GEN_TCC1_CNT 43 +#define EVSYS_ID_GEN_TCC1_MCX_0 44 +#define EVSYS_ID_GEN_TCC1_MCX_1 45 +#define EVSYS_ID_GEN_TCC2_OVF 46 +#define EVSYS_ID_GEN_TCC2_TRG 47 +#define EVSYS_ID_GEN_TCC2_CNT 48 +#define EVSYS_ID_GEN_TCC2_MCX_0 49 +#define EVSYS_ID_GEN_TCC2_MCX_1 50 +#define EVSYS_ID_GEN_TC3_OVF 51 +#define EVSYS_ID_GEN_TC3_MCX_0 52 +#define EVSYS_ID_GEN_TC3_MCX_1 53 +#define EVSYS_ID_GEN_TC4_OVF 54 +#define EVSYS_ID_GEN_TC4_MCX_0 55 +#define EVSYS_ID_GEN_TC4_MCX_1 56 +#define EVSYS_ID_GEN_TC5_OVF 57 +#define EVSYS_ID_GEN_TC5_MCX_0 58 +#define EVSYS_ID_GEN_TC5_MCX_1 59 +#define EVSYS_ID_GEN_TC6_OVF 60 +#define EVSYS_ID_GEN_TC6_MCX_0 61 +#define EVSYS_ID_GEN_TC6_MCX_1 62 +#define EVSYS_ID_GEN_TC7_OVF 63 +#define EVSYS_ID_GEN_TC7_MCX_0 64 +#define EVSYS_ID_GEN_TC7_MCX_1 65 +#define EVSYS_ID_GEN_ADC_RESRDY 66 +#define EVSYS_ID_GEN_ADC_WINMON 67 +#define EVSYS_ID_GEN_AC_COMP_0 68 +#define EVSYS_ID_GEN_AC_COMP_1 69 +#define EVSYS_ID_GEN_AC_WIN_0 70 +#define EVSYS_ID_GEN_DAC_EMPTY 71 +#define EVSYS_ID_GEN_PTC_EOC 72 +#define EVSYS_ID_GEN_PTC_WCOMP 73 + +// USERS +#define EVSYS_ID_USER_DMAC_CH_0 0 +#define EVSYS_ID_USER_DMAC_CH_1 1 +#define EVSYS_ID_USER_DMAC_CH_2 2 +#define EVSYS_ID_USER_DMAC_CH_3 3 +#define EVSYS_ID_USER_TCC0_EV_0 4 +#define EVSYS_ID_USER_TCC0_EV_1 5 +#define EVSYS_ID_USER_TCC0_MC_0 6 +#define EVSYS_ID_USER_TCC0_MC_1 7 +#define EVSYS_ID_USER_TCC0_MC_2 8 +#define EVSYS_ID_USER_TCC0_MC_3 9 +#define EVSYS_ID_USER_TCC1_EV_0 10 +#define EVSYS_ID_USER_TCC1_EV_1 11 +#define EVSYS_ID_USER_TCC1_MC_0 12 +#define EVSYS_ID_USER_TCC1_MC_1 13 +#define EVSYS_ID_USER_TCC2_EV_0 14 +#define EVSYS_ID_USER_TCC2_EV_1 15 +#define EVSYS_ID_USER_TCC2_MC_0 16 +#define EVSYS_ID_USER_TCC2_MC_1 17 +#define EVSYS_ID_USER_TC3_EVU 18 +#define EVSYS_ID_USER_TC4_EVU 19 +#define EVSYS_ID_USER_TC5_EVU 20 +#define EVSYS_ID_USER_TC6_EVU 21 +#define EVSYS_ID_USER_TC7_EVU 22 +#define EVSYS_ID_USER_ADC_START 23 +#define EVSYS_ID_USER_ADC_SYNC 24 +#define EVSYS_ID_USER_AC_SOC_0 25 +#define EVSYS_ID_USER_AC_SOC_1 26 +#define EVSYS_ID_USER_DAC_START 27 +#define EVSYS_ID_USER_PTC_STCONV 28 + +#endif /* _SAMD21_EVSYS_INSTANCE_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/gclk.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/gclk.h new file mode 100755 index 0000000..04869ef --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/gclk.h @@ -0,0 +1,79 @@ +/** + * \file + * + * \brief Instance description for GCLK + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_GCLK_INSTANCE_ +#define _SAMD21_GCLK_INSTANCE_ + +/* ========== Register definition for GCLK peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_GCLK_CTRL (0x40000C00U) /**< \brief (GCLK) Control */ +#define REG_GCLK_STATUS (0x40000C01U) /**< \brief (GCLK) Status */ +#define REG_GCLK_CLKCTRL (0x40000C02U) /**< \brief (GCLK) Generic Clock Control */ +#define REG_GCLK_GENCTRL (0x40000C04U) /**< \brief (GCLK) Generic Clock Generator Control */ +#define REG_GCLK_GENDIV (0x40000C08U) /**< \brief (GCLK) Generic Clock Generator Division */ +#else +#define REG_GCLK_CTRL (*(RwReg8 *)0x40000C00U) /**< \brief (GCLK) Control */ +#define REG_GCLK_STATUS (*(RoReg8 *)0x40000C01U) /**< \brief (GCLK) Status */ +#define REG_GCLK_CLKCTRL (*(RwReg16*)0x40000C02U) /**< \brief (GCLK) Generic Clock Control */ +#define REG_GCLK_GENCTRL (*(RwReg *)0x40000C04U) /**< \brief (GCLK) Generic Clock Generator Control */ +#define REG_GCLK_GENDIV (*(RwReg *)0x40000C08U) /**< \brief (GCLK) Generic Clock Generator Division */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for GCLK peripheral ========== */ +#define GCLK_GENDIV_BITS 16 +#define GCLK_GEN_NUM 9 +#define GCLK_GEN_NUM_MSB (GCLK_GEN_NUM-1) +#define GCLK_GEN_SOURCE_NUM_MSB (GCLK_SOURCE_NUM-1) +#define GCLK_NUM 37 +#define GCLK_SOURCE_DFLL48M 7 +#define GCLK_SOURCE_FDPLL 8 +#define GCLK_SOURCE_GCLKGEN1 2 +#define GCLK_SOURCE_GCLKIN 1 +#define GCLK_SOURCE_NUM 9 +#define GCLK_SOURCE_OSCULP32K 3 +#define GCLK_SOURCE_OSC8M 6 +#define GCLK_SOURCE_OSC32K 4 +#define GCLK_SOURCE_XOSC 0 +#define GCLK_SOURCE_XOSC32K 5 + +#endif /* _SAMD21_GCLK_INSTANCE_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/i2s.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/i2s.h new file mode 100755 index 0000000..3c92cde --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/i2s.h @@ -0,0 +1,94 @@ +/** + * \file + * + * \brief Instance description for I2S + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_I2S_INSTANCE_ +#define _SAMD21_I2S_INSTANCE_ + +/* ========== Register definition for I2S peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_I2S_CTRLA (0x42005000U) /**< \brief (I2S) Control A */ +#define REG_I2S_CLKCTRL0 (0x42005004U) /**< \brief (I2S) Clock Unit 0 Control */ +#define REG_I2S_CLKCTRL1 (0x42005008U) /**< \brief (I2S) Clock Unit 1 Control */ +#define REG_I2S_INTENCLR (0x4200500CU) /**< \brief (I2S) Interrupt Enable Clear */ +#define REG_I2S_INTENSET (0x42005010U) /**< \brief (I2S) Interrupt Enable Set */ +#define REG_I2S_INTFLAG (0x42005014U) /**< \brief (I2S) Interrupt Flag Status and Clear */ +#define REG_I2S_SYNCBUSY (0x42005018U) /**< \brief (I2S) Synchronization Status */ +#define REG_I2S_SERCTRL0 (0x42005020U) /**< \brief (I2S) Serializer 0 Control */ +#define REG_I2S_SERCTRL1 (0x42005024U) /**< \brief (I2S) Serializer 1 Control */ +#define REG_I2S_DATA0 (0x42005030U) /**< \brief (I2S) Data 0 */ +#define REG_I2S_DATA1 (0x42005034U) /**< \brief (I2S) Data 1 */ +#else +#define REG_I2S_CTRLA (*(RwReg8 *)0x42005000U) /**< \brief (I2S) Control A */ +#define REG_I2S_CLKCTRL0 (*(RwReg *)0x42005004U) /**< \brief (I2S) Clock Unit 0 Control */ +#define REG_I2S_CLKCTRL1 (*(RwReg *)0x42005008U) /**< \brief (I2S) Clock Unit 1 Control */ +#define REG_I2S_INTENCLR (*(RwReg16*)0x4200500CU) /**< \brief (I2S) Interrupt Enable Clear */ +#define REG_I2S_INTENSET (*(RwReg16*)0x42005010U) /**< \brief (I2S) Interrupt Enable Set */ +#define REG_I2S_INTFLAG (*(RwReg16*)0x42005014U) /**< \brief (I2S) Interrupt Flag Status and Clear */ +#define REG_I2S_SYNCBUSY (*(RoReg16*)0x42005018U) /**< \brief (I2S) Synchronization Status */ +#define REG_I2S_SERCTRL0 (*(RwReg *)0x42005020U) /**< \brief (I2S) Serializer 0 Control */ +#define REG_I2S_SERCTRL1 (*(RwReg *)0x42005024U) /**< \brief (I2S) Serializer 1 Control */ +#define REG_I2S_DATA0 (*(RwReg *)0x42005030U) /**< \brief (I2S) Data 0 */ +#define REG_I2S_DATA1 (*(RwReg *)0x42005034U) /**< \brief (I2S) Data 1 */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for I2S peripheral ========== */ +#define I2S_CLK_NUM 2 +#define I2S_DMAC_ID_RX_0 41 +#define I2S_DMAC_ID_RX_1 42 +#define I2S_DMAC_ID_RX_LSB 41 +#define I2S_DMAC_ID_RX_MSB 42 +#define I2S_DMAC_ID_RX_SIZE 2 +#define I2S_DMAC_ID_TX_0 43 +#define I2S_DMAC_ID_TX_1 44 +#define I2S_DMAC_ID_TX_LSB 43 +#define I2S_DMAC_ID_TX_MSB 44 +#define I2S_DMAC_ID_TX_SIZE 2 +#define I2S_GCLK_ID_0 35 +#define I2S_GCLK_ID_1 36 +#define I2S_GCLK_ID_LSB 35 +#define I2S_GCLK_ID_MSB 36 +#define I2S_GCLK_ID_SIZE 2 +#define I2S_MAX_SLOTS 8 +#define I2S_SER_NUM 2 + +#endif /* _SAMD21_I2S_INSTANCE_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/mtb.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/mtb.h new file mode 100755 index 0000000..ba3afe8 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/mtb.h @@ -0,0 +1,103 @@ +/** + * \file + * + * \brief Instance description for MTB + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_MTB_INSTANCE_ +#define _SAMD21_MTB_INSTANCE_ + +/* ========== Register definition for MTB peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_MTB_POSITION (0x41006000U) /**< \brief (MTB) MTB Position */ +#define REG_MTB_MASTER (0x41006004U) /**< \brief (MTB) MTB Master */ +#define REG_MTB_FLOW (0x41006008U) /**< \brief (MTB) MTB Flow */ +#define REG_MTB_BASE (0x4100600CU) /**< \brief (MTB) MTB Base */ +#define REG_MTB_ITCTRL (0x41006F00U) /**< \brief (MTB) MTB Integration Mode Control */ +#define REG_MTB_CLAIMSET (0x41006FA0U) /**< \brief (MTB) MTB Claim Set */ +#define REG_MTB_CLAIMCLR (0x41006FA4U) /**< \brief (MTB) MTB Claim Clear */ +#define REG_MTB_LOCKACCESS (0x41006FB0U) /**< \brief (MTB) MTB Lock Access */ +#define REG_MTB_LOCKSTATUS (0x41006FB4U) /**< \brief (MTB) MTB Lock Status */ +#define REG_MTB_AUTHSTATUS (0x41006FB8U) /**< \brief (MTB) MTB Authentication Status */ +#define REG_MTB_DEVARCH (0x41006FBCU) /**< \brief (MTB) MTB Device Architecture */ +#define REG_MTB_DEVID (0x41006FC8U) /**< \brief (MTB) MTB Device Configuration */ +#define REG_MTB_DEVTYPE (0x41006FCCU) /**< \brief (MTB) MTB Device Type */ +#define REG_MTB_PID4 (0x41006FD0U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID5 (0x41006FD4U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID6 (0x41006FD8U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID7 (0x41006FDCU) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID0 (0x41006FE0U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID1 (0x41006FE4U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID2 (0x41006FE8U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID3 (0x41006FECU) /**< \brief (MTB) CoreSight */ +#define REG_MTB_CID0 (0x41006FF0U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_CID1 (0x41006FF4U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_CID2 (0x41006FF8U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_CID3 (0x41006FFCU) /**< \brief (MTB) CoreSight */ +#else +#define REG_MTB_POSITION (*(RwReg *)0x41006000U) /**< \brief (MTB) MTB Position */ +#define REG_MTB_MASTER (*(RwReg *)0x41006004U) /**< \brief (MTB) MTB Master */ +#define REG_MTB_FLOW (*(RwReg *)0x41006008U) /**< \brief (MTB) MTB Flow */ +#define REG_MTB_BASE (*(RoReg *)0x4100600CU) /**< \brief (MTB) MTB Base */ +#define REG_MTB_ITCTRL (*(RwReg *)0x41006F00U) /**< \brief (MTB) MTB Integration Mode Control */ +#define REG_MTB_CLAIMSET (*(RwReg *)0x41006FA0U) /**< \brief (MTB) MTB Claim Set */ +#define REG_MTB_CLAIMCLR (*(RwReg *)0x41006FA4U) /**< \brief (MTB) MTB Claim Clear */ +#define REG_MTB_LOCKACCESS (*(RwReg *)0x41006FB0U) /**< \brief (MTB) MTB Lock Access */ +#define REG_MTB_LOCKSTATUS (*(RoReg *)0x41006FB4U) /**< \brief (MTB) MTB Lock Status */ +#define REG_MTB_AUTHSTATUS (*(RoReg *)0x41006FB8U) /**< \brief (MTB) MTB Authentication Status */ +#define REG_MTB_DEVARCH (*(RoReg *)0x41006FBCU) /**< \brief (MTB) MTB Device Architecture */ +#define REG_MTB_DEVID (*(RoReg *)0x41006FC8U) /**< \brief (MTB) MTB Device Configuration */ +#define REG_MTB_DEVTYPE (*(RoReg *)0x41006FCCU) /**< \brief (MTB) MTB Device Type */ +#define REG_MTB_PID4 (*(RoReg *)0x41006FD0U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID5 (*(RoReg *)0x41006FD4U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID6 (*(RoReg *)0x41006FD8U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID7 (*(RoReg *)0x41006FDCU) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID0 (*(RoReg *)0x41006FE0U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID1 (*(RoReg *)0x41006FE4U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID2 (*(RoReg *)0x41006FE8U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_PID3 (*(RoReg *)0x41006FECU) /**< \brief (MTB) CoreSight */ +#define REG_MTB_CID0 (*(RoReg *)0x41006FF0U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_CID1 (*(RoReg *)0x41006FF4U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_CID2 (*(RoReg *)0x41006FF8U) /**< \brief (MTB) CoreSight */ +#define REG_MTB_CID3 (*(RoReg *)0x41006FFCU) /**< \brief (MTB) CoreSight */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + + +#endif /* _SAMD21_MTB_INSTANCE_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/nvmctrl.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/nvmctrl.h new file mode 100755 index 0000000..2e78614 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/instance/nvmctrl.h @@ -0,0 +1,92 @@ +/** + * \file + * + * \brief Instance description for NVMCTRL + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21_NVMCTRL_INSTANCE_ +#define _SAMD21_NVMCTRL_INSTANCE_ + +/* ========== Register definition for NVMCTRL peripheral ========== */ +#if (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#define REG_NVMCTRL_CTRLA (0x41004000U) /**< \brief (NVMCTRL) Control A */ +#define REG_NVMCTRL_CTRLB (0x41004004U) /**< \brief (NVMCTRL) Control B */ +#define REG_NVMCTRL_PARAM (0x41004008U) /**< \brief (NVMCTRL) NVM Parameter */ +#define REG_NVMCTRL_INTENCLR (0x4100400CU) /**< \brief (NVMCTRL) Interrupt Enable Clear */ +#define REG_NVMCTRL_INTENSET (0x41004010U) /**< \brief (NVMCTRL) Interrupt Enable Set */ +#define REG_NVMCTRL_INTFLAG (0x41004014U) /**< \brief (NVMCTRL) Interrupt Flag Status and Clear */ +#define REG_NVMCTRL_STATUS (0x41004018U) /**< \brief (NVMCTRL) Status */ +#define REG_NVMCTRL_ADDR (0x4100401CU) /**< \brief (NVMCTRL) Address */ +#define REG_NVMCTRL_LOCK (0x41004020U) /**< \brief (NVMCTRL) Lock Section */ +#else +#define REG_NVMCTRL_CTRLA (*(RwReg16*)0x41004000U) /**< \brief (NVMCTRL) Control A */ +#define REG_NVMCTRL_CTRLB (*(RwReg *)0x41004004U) /**< \brief (NVMCTRL) Control B */ +#define REG_NVMCTRL_PARAM (*(RwReg *)0x41004008U) /**< \brief (NVMCTRL) NVM Parameter */ +#define REG_NVMCTRL_INTENCLR (*(RwReg8 *)0x4100400CU) /**< \brief (NVMCTRL) Interrupt Enable Clear */ +#define REG_NVMCTRL_INTENSET (*(RwReg8 *)0x41004010U) /**< \brief (NVMCTRL) Interrupt Enable Set */ +#define REG_NVMCTRL_INTFLAG (*(RwReg8 *)0x41004014U) /**< \brief (NVMCTRL) Interrupt Flag Status and Clear */ +#define REG_NVMCTRL_STATUS (*(RwReg16*)0x41004018U) /**< \brief (NVMCTRL) Status */ +#define REG_NVMCTRL_ADDR (*(RwReg *)0x4100401CU) /**< \brief (NVMCTRL) Address */ +#define REG_NVMCTRL_LOCK (*(RwReg16*)0x41004020U) /**< \brief (NVMCTRL) Lock Section */ +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ + +/* ========== Instance parameters for NVMCTRL peripheral ========== */ +#define NVMCTRL_AUX0_ADDRESS (NVMCTRL_USER_PAGE_ADDRESS + 0x00004000) +#define NVMCTRL_AUX1_ADDRESS (NVMCTRL_USER_PAGE_ADDRESS + 0x00006000) +#define NVMCTRL_AUX2_ADDRESS (NVMCTRL_USER_PAGE_ADDRESS + 0x00008000) +#define NVMCTRL_AUX3_ADDRESS (NVMCTRL_USER_PAGE_ADDRESS + 0x0000A000) +#define NVMCTRL_CLK_AHB_ID 4 +#define NVMCTRL_FACTORY_WORD_IMPLEMENTED_MASK 0xC0000007FFFFFFFF +#define NVMCTRL_FLASH_SIZE (NVMCTRL_PAGES*NVMCTRL_PAGE_SIZE) +#define NVMCTRL_LOCKBIT_ADDRESS (NVMCTRL_USER_PAGE_ADDRESS + 0x00002000) +#define NVMCTRL_PAGES 4096 +#define NVMCTRL_PAGE_HW (NVMCTRL_PAGE_SIZE/2) +#define NVMCTRL_PAGE_SIZE (1< +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21E15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E15A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21E15A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21E15A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21E15A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21E15A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21E15A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21E15A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21E15A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21E15A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21E15A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21E15A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21E15A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21E15A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21E15A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21E15A Serial Communication Interface 3 (SERCOM3) */ + TCC0_IRQn = 15, /**< 15 SAMD21E15A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21E15A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21E15A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21E15A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21E15A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21E15A Basic Timer Counter 5 (TC5) */ + ADC_IRQn = 23, /**< 23 SAMD21E15A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21E15A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21E15A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21E15A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21E15A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnReserved13; + void* pfnReserved14; + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnReserved21; + void* pfnReserved22; + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21E15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E15A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21E15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E15A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21E15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E15A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21E15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E15A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM_INST_NUM 4 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC_INST_NUM 3 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21E15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E15A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21e15a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21E15A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x8000 /* 32 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 512 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x1000 /* 4 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x1001000D +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 1 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21E15A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21E15A_H */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21e16a.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21e16a.h new file mode 100755 index 0000000..1732fe8 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21e16a.h @@ -0,0 +1,543 @@ +/** + * \file + * + * \brief Header file for SAMD21E16A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21E16A_ +#define _SAMD21E16A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21E16A_definitions SAMD21E16A definitions + * This file defines all structures and symbols for SAMD21E16A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21E16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E16A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21E16A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21E16A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21E16A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21E16A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21E16A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21E16A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21E16A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21E16A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21E16A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21E16A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21E16A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21E16A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21E16A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21E16A Serial Communication Interface 3 (SERCOM3) */ + TCC0_IRQn = 15, /**< 15 SAMD21E16A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21E16A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21E16A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21E16A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21E16A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21E16A Basic Timer Counter 5 (TC5) */ + ADC_IRQn = 23, /**< 23 SAMD21E16A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21E16A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21E16A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21E16A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21E16A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnReserved13; + void* pfnReserved14; + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnReserved21; + void* pfnReserved22; + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21E16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E16A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21E16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E16A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21E16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E16A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21E16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E16A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM_INST_NUM 4 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC_INST_NUM 3 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21E16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E16A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21e16a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21E16A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x10000 /* 64 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 1024 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x2000 /* 8 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x1001000C +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 1 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21E16A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21E16A_H */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21e17a.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21e17a.h new file mode 100755 index 0000000..bad36c6 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21e17a.h @@ -0,0 +1,543 @@ +/** + * \file + * + * \brief Header file for SAMD21E17A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21E17A_ +#define _SAMD21E17A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21E17A_definitions SAMD21E17A definitions + * This file defines all structures and symbols for SAMD21E17A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21E17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E17A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21E17A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21E17A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21E17A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21E17A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21E17A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21E17A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21E17A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21E17A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21E17A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21E17A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21E17A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21E17A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21E17A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21E17A Serial Communication Interface 3 (SERCOM3) */ + TCC0_IRQn = 15, /**< 15 SAMD21E17A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21E17A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21E17A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21E17A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21E17A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21E17A Basic Timer Counter 5 (TC5) */ + ADC_IRQn = 23, /**< 23 SAMD21E17A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21E17A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21E17A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21E17A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21E17A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnReserved13; + void* pfnReserved14; + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnReserved21; + void* pfnReserved22; + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21E17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E17A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21E17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E17A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21E17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E17A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21E17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E17A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM_INST_NUM 4 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC_INST_NUM 3 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21E17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E17A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21e17a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21E17A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x20000 /* 128 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 2048 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x4000 /* 16 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x1001000B +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 1 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21E17A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21E17A_H */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21e18a.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21e18a.h new file mode 100755 index 0000000..8397066 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21e18a.h @@ -0,0 +1,543 @@ +/** + * \file + * + * \brief Header file for SAMD21E18A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21E18A_ +#define _SAMD21E18A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21E18A_definitions SAMD21E18A definitions + * This file defines all structures and symbols for SAMD21E18A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21E18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E18A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21E18A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21E18A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21E18A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21E18A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21E18A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21E18A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21E18A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21E18A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21E18A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21E18A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21E18A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21E18A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21E18A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21E18A Serial Communication Interface 3 (SERCOM3) */ + TCC0_IRQn = 15, /**< 15 SAMD21E18A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21E18A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21E18A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21E18A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21E18A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21E18A Basic Timer Counter 5 (TC5) */ + ADC_IRQn = 23, /**< 23 SAMD21E18A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21E18A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21E18A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21E18A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21E18A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnReserved13; + void* pfnReserved14; + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnReserved21; + void* pfnReserved22; + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21E18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E18A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21E18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E18A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21E18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E18A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21E18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E18A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM_INST_NUM 4 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC_INST_NUM 3 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21E18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21E18A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21e18a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21E18A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x40000 /* 256 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 4096 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x8000 /* 32 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x1001000A +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 1 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21E18A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21E18A_H */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21g15a.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21g15a.h new file mode 100755 index 0000000..fbc1116 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21g15a.h @@ -0,0 +1,555 @@ +/** + * \file + * + * \brief Header file for SAMD21G15A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21G15A_ +#define _SAMD21G15A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21G15A_definitions SAMD21G15A definitions + * This file defines all structures and symbols for SAMD21G15A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21G15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G15A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21G15A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21G15A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21G15A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21G15A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21G15A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21G15A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21G15A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21G15A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21G15A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21G15A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21G15A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21G15A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21G15A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21G15A Serial Communication Interface 3 (SERCOM3) */ + SERCOM4_IRQn = 13, /**< 13 SAMD21G15A Serial Communication Interface 4 (SERCOM4) */ + SERCOM5_IRQn = 14, /**< 14 SAMD21G15A Serial Communication Interface 5 (SERCOM5) */ + TCC0_IRQn = 15, /**< 15 SAMD21G15A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21G15A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21G15A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21G15A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21G15A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21G15A Basic Timer Counter 5 (TC5) */ + ADC_IRQn = 23, /**< 23 SAMD21G15A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21G15A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21G15A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21G15A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21G15A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnSERCOM4_Handler; /* 13 Serial Communication Interface 4 */ + void* pfnSERCOM5_Handler; /* 14 Serial Communication Interface 5 */ + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnReserved21; + void* pfnReserved22; + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void SERCOM4_Handler ( void ); +void SERCOM5_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21G15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G15A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21G15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G15A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sercom4.h" +#include "instance/sercom5.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21G15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G15A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_SERCOM4 70 /**< \brief Serial Communication Interface SERCOM (SERCOM4) */ +#define ID_SERCOM5 71 /**< \brief Serial Communication Interface SERCOM (SERCOM5) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21G15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G15A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 (0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 (0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 ((Sercom *)0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 ((Sercom *)0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SERCOM_INST_NUM 6 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3, SERCOM4, SERCOM5 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC_INST_NUM 3 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21G15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G15A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21g15a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21G15A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x8000 /* 32 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 512 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x1000 /* 4 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x10010008 +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 2 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21G15A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21G15A_H */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21g16a.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21g16a.h new file mode 100755 index 0000000..d8aa246 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21g16a.h @@ -0,0 +1,555 @@ +/** + * \file + * + * \brief Header file for SAMD21G16A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21G16A_ +#define _SAMD21G16A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21G16A_definitions SAMD21G16A definitions + * This file defines all structures and symbols for SAMD21G16A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21G16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G16A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21G16A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21G16A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21G16A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21G16A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21G16A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21G16A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21G16A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21G16A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21G16A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21G16A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21G16A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21G16A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21G16A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21G16A Serial Communication Interface 3 (SERCOM3) */ + SERCOM4_IRQn = 13, /**< 13 SAMD21G16A Serial Communication Interface 4 (SERCOM4) */ + SERCOM5_IRQn = 14, /**< 14 SAMD21G16A Serial Communication Interface 5 (SERCOM5) */ + TCC0_IRQn = 15, /**< 15 SAMD21G16A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21G16A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21G16A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21G16A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21G16A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21G16A Basic Timer Counter 5 (TC5) */ + ADC_IRQn = 23, /**< 23 SAMD21G16A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21G16A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21G16A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21G16A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21G16A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnSERCOM4_Handler; /* 13 Serial Communication Interface 4 */ + void* pfnSERCOM5_Handler; /* 14 Serial Communication Interface 5 */ + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnReserved21; + void* pfnReserved22; + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void SERCOM4_Handler ( void ); +void SERCOM5_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21G16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G16A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21G16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G16A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sercom4.h" +#include "instance/sercom5.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21G16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G16A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_SERCOM4 70 /**< \brief Serial Communication Interface SERCOM (SERCOM4) */ +#define ID_SERCOM5 71 /**< \brief Serial Communication Interface SERCOM (SERCOM5) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21G16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G16A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 (0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 (0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 ((Sercom *)0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 ((Sercom *)0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SERCOM_INST_NUM 6 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3, SERCOM4, SERCOM5 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC_INST_NUM 3 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21G16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G16A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21g16a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21G16A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x10000 /* 64 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 1024 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x2000 /* 8 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x10010007 +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 2 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21G16A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21G16A_H */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21g17a.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21g17a.h new file mode 100755 index 0000000..0cad9c7 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21g17a.h @@ -0,0 +1,555 @@ +/** + * \file + * + * \brief Header file for SAMD21G17A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21G17A_ +#define _SAMD21G17A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21G17A_definitions SAMD21G17A definitions + * This file defines all structures and symbols for SAMD21G17A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21G17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G17A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21G17A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21G17A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21G17A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21G17A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21G17A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21G17A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21G17A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21G17A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21G17A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21G17A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21G17A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21G17A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21G17A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21G17A Serial Communication Interface 3 (SERCOM3) */ + SERCOM4_IRQn = 13, /**< 13 SAMD21G17A Serial Communication Interface 4 (SERCOM4) */ + SERCOM5_IRQn = 14, /**< 14 SAMD21G17A Serial Communication Interface 5 (SERCOM5) */ + TCC0_IRQn = 15, /**< 15 SAMD21G17A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21G17A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21G17A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21G17A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21G17A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21G17A Basic Timer Counter 5 (TC5) */ + ADC_IRQn = 23, /**< 23 SAMD21G17A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21G17A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21G17A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21G17A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21G17A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnSERCOM4_Handler; /* 13 Serial Communication Interface 4 */ + void* pfnSERCOM5_Handler; /* 14 Serial Communication Interface 5 */ + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnReserved21; + void* pfnReserved22; + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void SERCOM4_Handler ( void ); +void SERCOM5_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21G17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G17A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21G17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G17A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sercom4.h" +#include "instance/sercom5.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21G17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G17A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_SERCOM4 70 /**< \brief Serial Communication Interface SERCOM (SERCOM4) */ +#define ID_SERCOM5 71 /**< \brief Serial Communication Interface SERCOM (SERCOM5) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21G17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G17A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 (0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 (0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 ((Sercom *)0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 ((Sercom *)0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SERCOM_INST_NUM 6 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3, SERCOM4, SERCOM5 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC_INST_NUM 3 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21G17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G17A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21g17a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21G17A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x20000 /* 128 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 2048 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x4000 /* 16 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x10010006 +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 2 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21G17A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21G17A_H */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21g18a.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21g18a.h new file mode 100755 index 0000000..76273e1 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21g18a.h @@ -0,0 +1,555 @@ +/** + * \file + * + * \brief Header file for SAMD21G18A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21G18A_ +#define _SAMD21G18A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21G18A_definitions SAMD21G18A definitions + * This file defines all structures and symbols for SAMD21G18A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21G18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G18A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21G18A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21G18A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21G18A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21G18A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21G18A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21G18A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21G18A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21G18A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21G18A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21G18A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21G18A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21G18A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21G18A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21G18A Serial Communication Interface 3 (SERCOM3) */ + SERCOM4_IRQn = 13, /**< 13 SAMD21G18A Serial Communication Interface 4 (SERCOM4) */ + SERCOM5_IRQn = 14, /**< 14 SAMD21G18A Serial Communication Interface 5 (SERCOM5) */ + TCC0_IRQn = 15, /**< 15 SAMD21G18A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21G18A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21G18A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21G18A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21G18A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21G18A Basic Timer Counter 5 (TC5) */ + ADC_IRQn = 23, /**< 23 SAMD21G18A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21G18A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21G18A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21G18A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21G18A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnSERCOM4_Handler; /* 13 Serial Communication Interface 4 */ + void* pfnSERCOM5_Handler; /* 14 Serial Communication Interface 5 */ + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnReserved21; + void* pfnReserved22; + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void SERCOM4_Handler ( void ); +void SERCOM5_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21G18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G18A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21G18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G18A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sercom4.h" +#include "instance/sercom5.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21G18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G18A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_SERCOM4 70 /**< \brief Serial Communication Interface SERCOM (SERCOM4) */ +#define ID_SERCOM5 71 /**< \brief Serial Communication Interface SERCOM (SERCOM5) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21G18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G18A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 (0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 (0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 ((Sercom *)0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 ((Sercom *)0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SERCOM_INST_NUM 6 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3, SERCOM4, SERCOM5 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC_INST_NUM 3 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21G18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21G18A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21g18a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21G18A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x40000 /* 256 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 4096 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x8000 /* 32 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x10010005 +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 2 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21G18A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21G18A_H */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21j15a.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21j15a.h new file mode 100755 index 0000000..a3f771e --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21j15a.h @@ -0,0 +1,567 @@ +/** + * \file + * + * \brief Header file for SAMD21J15A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21J15A_ +#define _SAMD21J15A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21J15A_definitions SAMD21J15A definitions + * This file defines all structures and symbols for SAMD21J15A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21J15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J15A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21J15A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21J15A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21J15A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21J15A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21J15A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21J15A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21J15A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21J15A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21J15A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21J15A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21J15A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21J15A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21J15A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21J15A Serial Communication Interface 3 (SERCOM3) */ + SERCOM4_IRQn = 13, /**< 13 SAMD21J15A Serial Communication Interface 4 (SERCOM4) */ + SERCOM5_IRQn = 14, /**< 14 SAMD21J15A Serial Communication Interface 5 (SERCOM5) */ + TCC0_IRQn = 15, /**< 15 SAMD21J15A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21J15A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21J15A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21J15A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21J15A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21J15A Basic Timer Counter 5 (TC5) */ + TC6_IRQn = 21, /**< 21 SAMD21J15A Basic Timer Counter 6 (TC6) */ + TC7_IRQn = 22, /**< 22 SAMD21J15A Basic Timer Counter 7 (TC7) */ + ADC_IRQn = 23, /**< 23 SAMD21J15A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21J15A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21J15A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21J15A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21J15A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnSERCOM4_Handler; /* 13 Serial Communication Interface 4 */ + void* pfnSERCOM5_Handler; /* 14 Serial Communication Interface 5 */ + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnTC6_Handler; /* 21 Basic Timer Counter 6 */ + void* pfnTC7_Handler; /* 22 Basic Timer Counter 7 */ + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void SERCOM4_Handler ( void ); +void SERCOM5_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void TC6_Handler ( void ); +void TC7_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21J15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J15A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21J15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J15A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sercom4.h" +#include "instance/sercom5.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tc6.h" +#include "instance/tc7.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21J15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J15A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_SERCOM4 70 /**< \brief Serial Communication Interface SERCOM (SERCOM4) */ +#define ID_SERCOM5 71 /**< \brief Serial Communication Interface SERCOM (SERCOM5) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_TC6 78 /**< \brief Basic Timer Counter TC (TC6) */ +#define ID_TC7 79 /**< \brief Basic Timer Counter TC (TC7) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21J15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J15A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 (0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 (0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC6 (0x42003800U) /**< \brief (TC6) APB Base Address */ +#define TC7 (0x42003C00U) /**< \brief (TC7) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 ((Sercom *)0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 ((Sercom *)0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SERCOM_INST_NUM 6 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3, SERCOM4, SERCOM5 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC6 ((Tc *)0x42003800U) /**< \brief (TC6) APB Base Address */ +#define TC7 ((Tc *)0x42003C00U) /**< \brief (TC7) APB Base Address */ +#define TC_INST_NUM 5 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5, TC6, TC7 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21J15A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J15A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21j15a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21J15A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x8000 /* 32 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 512 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x1000 /* 4 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x10010003 +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 2 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21J15A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21J15A_H */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21j16a.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21j16a.h new file mode 100755 index 0000000..eaa2ec1 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21j16a.h @@ -0,0 +1,567 @@ +/** + * \file + * + * \brief Header file for SAMD21J16A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21J16A_ +#define _SAMD21J16A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21J16A_definitions SAMD21J16A definitions + * This file defines all structures and symbols for SAMD21J16A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21J16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J16A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21J16A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21J16A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21J16A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21J16A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21J16A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21J16A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21J16A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21J16A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21J16A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21J16A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21J16A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21J16A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21J16A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21J16A Serial Communication Interface 3 (SERCOM3) */ + SERCOM4_IRQn = 13, /**< 13 SAMD21J16A Serial Communication Interface 4 (SERCOM4) */ + SERCOM5_IRQn = 14, /**< 14 SAMD21J16A Serial Communication Interface 5 (SERCOM5) */ + TCC0_IRQn = 15, /**< 15 SAMD21J16A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21J16A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21J16A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21J16A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21J16A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21J16A Basic Timer Counter 5 (TC5) */ + TC6_IRQn = 21, /**< 21 SAMD21J16A Basic Timer Counter 6 (TC6) */ + TC7_IRQn = 22, /**< 22 SAMD21J16A Basic Timer Counter 7 (TC7) */ + ADC_IRQn = 23, /**< 23 SAMD21J16A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21J16A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21J16A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21J16A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21J16A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnSERCOM4_Handler; /* 13 Serial Communication Interface 4 */ + void* pfnSERCOM5_Handler; /* 14 Serial Communication Interface 5 */ + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnTC6_Handler; /* 21 Basic Timer Counter 6 */ + void* pfnTC7_Handler; /* 22 Basic Timer Counter 7 */ + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void SERCOM4_Handler ( void ); +void SERCOM5_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void TC6_Handler ( void ); +void TC7_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21J16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J16A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21J16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J16A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sercom4.h" +#include "instance/sercom5.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tc6.h" +#include "instance/tc7.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21J16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J16A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_SERCOM4 70 /**< \brief Serial Communication Interface SERCOM (SERCOM4) */ +#define ID_SERCOM5 71 /**< \brief Serial Communication Interface SERCOM (SERCOM5) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_TC6 78 /**< \brief Basic Timer Counter TC (TC6) */ +#define ID_TC7 79 /**< \brief Basic Timer Counter TC (TC7) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21J16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J16A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 (0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 (0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC6 (0x42003800U) /**< \brief (TC6) APB Base Address */ +#define TC7 (0x42003C00U) /**< \brief (TC7) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 ((Sercom *)0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 ((Sercom *)0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SERCOM_INST_NUM 6 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3, SERCOM4, SERCOM5 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC6 ((Tc *)0x42003800U) /**< \brief (TC6) APB Base Address */ +#define TC7 ((Tc *)0x42003C00U) /**< \brief (TC7) APB Base Address */ +#define TC_INST_NUM 5 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5, TC6, TC7 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21J16A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J16A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21j16a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21J16A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x10000 /* 64 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 1024 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x2000 /* 8 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x10010002 +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 2 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21J16A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21J16A_H */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21j17a.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21j17a.h new file mode 100755 index 0000000..5e956b9 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21j17a.h @@ -0,0 +1,567 @@ +/** + * \file + * + * \brief Header file for SAMD21J17A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21J17A_ +#define _SAMD21J17A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21J17A_definitions SAMD21J17A definitions + * This file defines all structures and symbols for SAMD21J17A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21J17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J17A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21J17A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21J17A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21J17A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21J17A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21J17A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21J17A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21J17A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21J17A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21J17A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21J17A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21J17A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21J17A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21J17A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21J17A Serial Communication Interface 3 (SERCOM3) */ + SERCOM4_IRQn = 13, /**< 13 SAMD21J17A Serial Communication Interface 4 (SERCOM4) */ + SERCOM5_IRQn = 14, /**< 14 SAMD21J17A Serial Communication Interface 5 (SERCOM5) */ + TCC0_IRQn = 15, /**< 15 SAMD21J17A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21J17A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21J17A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21J17A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21J17A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21J17A Basic Timer Counter 5 (TC5) */ + TC6_IRQn = 21, /**< 21 SAMD21J17A Basic Timer Counter 6 (TC6) */ + TC7_IRQn = 22, /**< 22 SAMD21J17A Basic Timer Counter 7 (TC7) */ + ADC_IRQn = 23, /**< 23 SAMD21J17A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21J17A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21J17A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21J17A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21J17A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnSERCOM4_Handler; /* 13 Serial Communication Interface 4 */ + void* pfnSERCOM5_Handler; /* 14 Serial Communication Interface 5 */ + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnTC6_Handler; /* 21 Basic Timer Counter 6 */ + void* pfnTC7_Handler; /* 22 Basic Timer Counter 7 */ + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void SERCOM4_Handler ( void ); +void SERCOM5_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void TC6_Handler ( void ); +void TC7_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21J17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J17A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21J17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J17A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sercom4.h" +#include "instance/sercom5.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tc6.h" +#include "instance/tc7.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21J17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J17A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_SERCOM4 70 /**< \brief Serial Communication Interface SERCOM (SERCOM4) */ +#define ID_SERCOM5 71 /**< \brief Serial Communication Interface SERCOM (SERCOM5) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_TC6 78 /**< \brief Basic Timer Counter TC (TC6) */ +#define ID_TC7 79 /**< \brief Basic Timer Counter TC (TC7) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21J17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J17A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 (0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 (0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC6 (0x42003800U) /**< \brief (TC6) APB Base Address */ +#define TC7 (0x42003C00U) /**< \brief (TC7) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 ((Sercom *)0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 ((Sercom *)0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SERCOM_INST_NUM 6 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3, SERCOM4, SERCOM5 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC6 ((Tc *)0x42003800U) /**< \brief (TC6) APB Base Address */ +#define TC7 ((Tc *)0x42003C00U) /**< \brief (TC7) APB Base Address */ +#define TC_INST_NUM 5 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5, TC6, TC7 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21J17A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J17A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21j17a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21J17A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x20000 /* 128 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 2048 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x4000 /* 16 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x10010001 +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 2 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21J17A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21J17A_H */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21j18a.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21j18a.h new file mode 100755 index 0000000..1a1d7e8 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/include/samd21j18a.h @@ -0,0 +1,567 @@ +/** + * \file + * + * \brief Header file for SAMD21J18A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAMD21J18A_ +#define _SAMD21J18A_ + +/** + * \ingroup SAMD21_definitions + * \addtogroup SAMD21J18A_definitions SAMD21J18A definitions + * This file defines all structures and symbols for SAMD21J18A: + * - registers and bitfields + * - peripheral base address + * - peripheral ID + * - PIO definitions +*/ +/*@{*/ + +#ifdef __cplusplus + extern "C" { +#endif + +#if !(defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) +#include +#ifndef __cplusplus +typedef volatile const uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile const uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile const uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#else +typedef volatile uint32_t RoReg; /**< Read only 32-bit register (volatile const unsigned int) */ +typedef volatile uint16_t RoReg16; /**< Read only 16-bit register (volatile const unsigned int) */ +typedef volatile uint8_t RoReg8; /**< Read only 8-bit register (volatile const unsigned int) */ +#endif +typedef volatile uint32_t WoReg; /**< Write only 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t WoReg16; /**< Write only 16-bit register (volatile unsigned int) */ +typedef volatile uint32_t WoReg8; /**< Write only 8-bit register (volatile unsigned int) */ +typedef volatile uint32_t RwReg; /**< Read-Write 32-bit register (volatile unsigned int) */ +typedef volatile uint16_t RwReg16; /**< Read-Write 16-bit register (volatile unsigned int) */ +typedef volatile uint8_t RwReg8; /**< Read-Write 8-bit register (volatile unsigned int) */ +#define CAST(type, value) ((type *)(value)) +#define REG_ACCESS(type, address) (*(type*)(address)) /**< C code: Register value */ +#else +#define CAST(type, value) (value) +#define REG_ACCESS(type, address) (address) /**< Assembly code: Register address */ +#endif + +/* ************************************************************************** */ +/** CMSIS DEFINITIONS FOR SAMD21J18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J18A_cmsis CMSIS Definitions */ +/*@{*/ + +/** Interrupt Number Definition */ +typedef enum IRQn +{ + /****** Cortex-M0+ Processor Exceptions Numbers *******************************/ + NonMaskableInt_IRQn = -14, /**< 2 Non Maskable Interrupt */ + HardFault_IRQn = -13, /**< 3 Cortex-M0+ Hard Fault Interrupt */ + SVCall_IRQn = -5, /**< 11 Cortex-M0+ SV Call Interrupt */ + PendSV_IRQn = -2, /**< 14 Cortex-M0+ Pend SV Interrupt */ + SysTick_IRQn = -1, /**< 15 Cortex-M0+ System Tick Interrupt */ + /****** SAMD21J18A-specific Interrupt Numbers ***********************/ + PM_IRQn = 0, /**< 0 SAMD21J18A Power Manager (PM) */ + SYSCTRL_IRQn = 1, /**< 1 SAMD21J18A System Control (SYSCTRL) */ + WDT_IRQn = 2, /**< 2 SAMD21J18A Watchdog Timer (WDT) */ + RTC_IRQn = 3, /**< 3 SAMD21J18A Real-Time Counter (RTC) */ + EIC_IRQn = 4, /**< 4 SAMD21J18A External Interrupt Controller (EIC) */ + NVMCTRL_IRQn = 5, /**< 5 SAMD21J18A Non-Volatile Memory Controller (NVMCTRL) */ + DMAC_IRQn = 6, /**< 6 SAMD21J18A Direct Memory Access Controller (DMAC) */ + USB_IRQn = 7, /**< 7 SAMD21J18A Universal Serial Bus (USB) */ + EVSYS_IRQn = 8, /**< 8 SAMD21J18A Event System Interface (EVSYS) */ + SERCOM0_IRQn = 9, /**< 9 SAMD21J18A Serial Communication Interface 0 (SERCOM0) */ + SERCOM1_IRQn = 10, /**< 10 SAMD21J18A Serial Communication Interface 1 (SERCOM1) */ + SERCOM2_IRQn = 11, /**< 11 SAMD21J18A Serial Communication Interface 2 (SERCOM2) */ + SERCOM3_IRQn = 12, /**< 12 SAMD21J18A Serial Communication Interface 3 (SERCOM3) */ + SERCOM4_IRQn = 13, /**< 13 SAMD21J18A Serial Communication Interface 4 (SERCOM4) */ + SERCOM5_IRQn = 14, /**< 14 SAMD21J18A Serial Communication Interface 5 (SERCOM5) */ + TCC0_IRQn = 15, /**< 15 SAMD21J18A Timer Counter Control 0 (TCC0) */ + TCC1_IRQn = 16, /**< 16 SAMD21J18A Timer Counter Control 1 (TCC1) */ + TCC2_IRQn = 17, /**< 17 SAMD21J18A Timer Counter Control 2 (TCC2) */ + TC3_IRQn = 18, /**< 18 SAMD21J18A Basic Timer Counter 3 (TC3) */ + TC4_IRQn = 19, /**< 19 SAMD21J18A Basic Timer Counter 4 (TC4) */ + TC5_IRQn = 20, /**< 20 SAMD21J18A Basic Timer Counter 5 (TC5) */ + TC6_IRQn = 21, /**< 21 SAMD21J18A Basic Timer Counter 6 (TC6) */ + TC7_IRQn = 22, /**< 22 SAMD21J18A Basic Timer Counter 7 (TC7) */ + ADC_IRQn = 23, /**< 23 SAMD21J18A Analog Digital Converter (ADC) */ + AC_IRQn = 24, /**< 24 SAMD21J18A Analog Comparators (AC) */ + DAC_IRQn = 25, /**< 25 SAMD21J18A Digital Analog Converter (DAC) */ + PTC_IRQn = 26, /**< 26 SAMD21J18A Peripheral Touch Controller (PTC) */ + I2S_IRQn = 27, /**< 27 SAMD21J18A Inter-IC Sound Interface (I2S) */ + + PERIPH_COUNT_IRQn = 28 /**< Number of peripheral IDs */ +} IRQn_Type; + +typedef struct _DeviceVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; + + /* Peripheral handlers */ + void* pfnPM_Handler; /* 0 Power Manager */ + void* pfnSYSCTRL_Handler; /* 1 System Control */ + void* pfnWDT_Handler; /* 2 Watchdog Timer */ + void* pfnRTC_Handler; /* 3 Real-Time Counter */ + void* pfnEIC_Handler; /* 4 External Interrupt Controller */ + void* pfnNVMCTRL_Handler; /* 5 Non-Volatile Memory Controller */ + void* pfnDMAC_Handler; /* 6 Direct Memory Access Controller */ + void* pfnUSB_Handler; /* 7 Universal Serial Bus */ + void* pfnEVSYS_Handler; /* 8 Event System Interface */ + void* pfnSERCOM0_Handler; /* 9 Serial Communication Interface 0 */ + void* pfnSERCOM1_Handler; /* 10 Serial Communication Interface 1 */ + void* pfnSERCOM2_Handler; /* 11 Serial Communication Interface 2 */ + void* pfnSERCOM3_Handler; /* 12 Serial Communication Interface 3 */ + void* pfnSERCOM4_Handler; /* 13 Serial Communication Interface 4 */ + void* pfnSERCOM5_Handler; /* 14 Serial Communication Interface 5 */ + void* pfnTCC0_Handler; /* 15 Timer Counter Control 0 */ + void* pfnTCC1_Handler; /* 16 Timer Counter Control 1 */ + void* pfnTCC2_Handler; /* 17 Timer Counter Control 2 */ + void* pfnTC3_Handler; /* 18 Basic Timer Counter 3 */ + void* pfnTC4_Handler; /* 19 Basic Timer Counter 4 */ + void* pfnTC5_Handler; /* 20 Basic Timer Counter 5 */ + void* pfnTC6_Handler; /* 21 Basic Timer Counter 6 */ + void* pfnTC7_Handler; /* 22 Basic Timer Counter 7 */ + void* pfnADC_Handler; /* 23 Analog Digital Converter */ + void* pfnAC_Handler; /* 24 Analog Comparators */ + void* pfnDAC_Handler; /* 25 Digital Analog Converter */ + void* pfnPTC_Handler; /* 26 Peripheral Touch Controller */ + void* pfnI2S_Handler; /* 27 Inter-IC Sound Interface */ +} DeviceVectors; + +/* Cortex-M0+ processor handlers */ +void Reset_Handler ( void ); +void NMI_Handler ( void ); +void HardFault_Handler ( void ); +void SVC_Handler ( void ); +void PendSV_Handler ( void ); +void SysTick_Handler ( void ); + +/* Peripherals handlers */ +void PM_Handler ( void ); +void SYSCTRL_Handler ( void ); +void WDT_Handler ( void ); +void RTC_Handler ( void ); +void EIC_Handler ( void ); +void NVMCTRL_Handler ( void ); +void DMAC_Handler ( void ); +void USB_Handler ( void ); +void EVSYS_Handler ( void ); +void SERCOM0_Handler ( void ); +void SERCOM1_Handler ( void ); +void SERCOM2_Handler ( void ); +void SERCOM3_Handler ( void ); +void SERCOM4_Handler ( void ); +void SERCOM5_Handler ( void ); +void TCC0_Handler ( void ); +void TCC1_Handler ( void ); +void TCC2_Handler ( void ); +void TC3_Handler ( void ); +void TC4_Handler ( void ); +void TC5_Handler ( void ); +void TC6_Handler ( void ); +void TC7_Handler ( void ); +void ADC_Handler ( void ); +void AC_Handler ( void ); +void DAC_Handler ( void ); +void PTC_Handler ( void ); +void I2S_Handler ( void ); + +/* + * \brief Configuration of the Cortex-M0+ Processor and Core Peripherals + */ + +#define LITTLE_ENDIAN 1 +#define __CM0PLUS_REV 1 /*!< Core revision r0p1 */ +#define __MPU_PRESENT 0 /*!< MPU present or not */ +#define __NVIC_PRIO_BITS 2 /*!< Number of bits used for Priority Levels */ +#define __VTOR_PRESENT 1 /*!< VTOR present or not */ +#define __Vendor_SysTickConfig 0 /*!< Set to 1 if different SysTick Config is used */ + +/** + * \brief CMSIS includes + */ + +#include +#if !defined DONT_USE_CMSIS_INIT +#include "system_samd21.h" +#endif /* DONT_USE_CMSIS_INIT */ + +/*@}*/ + +/* ************************************************************************** */ +/** SOFTWARE PERIPHERAL API DEFINITION FOR SAMD21J18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J18A_api Peripheral Software API */ +/*@{*/ + +#include "component/ac.h" +#include "component/adc.h" +#include "component/dac.h" +#include "component/dmac.h" +#include "component/dsu.h" +#include "component/eic.h" +#include "component/evsys.h" +#include "component/gclk.h" +#include "component/i2s.h" +#include "component/mtb.h" +#include "component/nvmctrl.h" +#include "component/pac.h" +#include "component/pm.h" +#include "component/port.h" +#include "component/rtc.h" +#include "component/sercom.h" +#include "component/sysctrl.h" +#include "component/tc.h" +#include "component/tcc.h" +#include "component/usb.h" +#include "component/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** REGISTERS ACCESS DEFINITIONS FOR SAMD21J18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J18A_reg Registers Access Definitions */ +/*@{*/ + +#include "instance/ac.h" +#include "instance/adc.h" +#include "instance/dac.h" +#include "instance/dmac.h" +#include "instance/dsu.h" +#include "instance/eic.h" +#include "instance/evsys.h" +#include "instance/gclk.h" +#include "instance/i2s.h" +#include "instance/mtb.h" +#include "instance/nvmctrl.h" +#include "instance/pac0.h" +#include "instance/pac1.h" +#include "instance/pac2.h" +#include "instance/pm.h" +#include "instance/port.h" +#include "instance/rtc.h" +#include "instance/sercom0.h" +#include "instance/sercom1.h" +#include "instance/sercom2.h" +#include "instance/sercom3.h" +#include "instance/sercom4.h" +#include "instance/sercom5.h" +#include "instance/sysctrl.h" +#include "instance/tc3.h" +#include "instance/tc4.h" +#include "instance/tc5.h" +#include "instance/tc6.h" +#include "instance/tc7.h" +#include "instance/tcc0.h" +#include "instance/tcc1.h" +#include "instance/tcc2.h" +#include "instance/usb.h" +#include "instance/wdt.h" +/*@}*/ + +/* ************************************************************************** */ +/** PERIPHERAL ID DEFINITIONS FOR SAMD21J18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J18A_id Peripheral Ids Definitions */ +/*@{*/ + +// Peripheral instances on HPB0 bridge +#define ID_PAC0 0 /**< \brief Peripheral Access Controller PAC (PAC0) */ +#define ID_PM 1 /**< \brief Power Manager (PM) */ +#define ID_SYSCTRL 2 /**< \brief System Control (SYSCTRL) */ +#define ID_GCLK 3 /**< \brief Generic Clock Generator (GCLK) */ +#define ID_WDT 4 /**< \brief Watchdog Timer (WDT) */ +#define ID_RTC 5 /**< \brief Real-Time Counter (RTC) */ +#define ID_EIC 6 /**< \brief External Interrupt Controller (EIC) */ + +// Peripheral instances on HPB1 bridge +#define ID_PAC1 32 /**< \brief Peripheral Access Controller PAC (PAC1) */ +#define ID_DSU 33 /**< \brief Device Service Unit (DSU) */ +#define ID_NVMCTRL 34 /**< \brief Non-Volatile Memory Controller (NVMCTRL) */ +#define ID_PORT 35 /**< \brief Port Module (PORT) */ +#define ID_DMAC 36 /**< \brief Direct Memory Access Controller (DMAC) */ +#define ID_USB 37 /**< \brief Universal Serial Bus (USB) */ +#define ID_MTB 38 /**< \brief Cortex-M0+ Micro-Trace Buffer (MTB) */ + +// Peripheral instances on HPB2 bridge +#define ID_PAC2 64 /**< \brief Peripheral Access Controller PAC (PAC2) */ +#define ID_EVSYS 65 /**< \brief Event System Interface (EVSYS) */ +#define ID_SERCOM0 66 /**< \brief Serial Communication Interface SERCOM (SERCOM0) */ +#define ID_SERCOM1 67 /**< \brief Serial Communication Interface SERCOM (SERCOM1) */ +#define ID_SERCOM2 68 /**< \brief Serial Communication Interface SERCOM (SERCOM2) */ +#define ID_SERCOM3 69 /**< \brief Serial Communication Interface SERCOM (SERCOM3) */ +#define ID_SERCOM4 70 /**< \brief Serial Communication Interface SERCOM (SERCOM4) */ +#define ID_SERCOM5 71 /**< \brief Serial Communication Interface SERCOM (SERCOM5) */ +#define ID_TCC0 72 /**< \brief Timer Counter Control TCC (TCC0) */ +#define ID_TCC1 73 /**< \brief Timer Counter Control TCC (TCC1) */ +#define ID_TCC2 74 /**< \brief Timer Counter Control TCC (TCC2) */ +#define ID_TC3 75 /**< \brief Basic Timer Counter TC (TC3) */ +#define ID_TC4 76 /**< \brief Basic Timer Counter TC (TC4) */ +#define ID_TC5 77 /**< \brief Basic Timer Counter TC (TC5) */ +#define ID_TC6 78 /**< \brief Basic Timer Counter TC (TC6) */ +#define ID_TC7 79 /**< \brief Basic Timer Counter TC (TC7) */ +#define ID_ADC 80 /**< \brief Analog Digital Converter (ADC) */ +#define ID_AC 81 /**< \brief Analog Comparators (AC) */ +#define ID_DAC 82 /**< \brief Digital Analog Converter (DAC) */ +#define ID_PTC 83 /**< \brief Peripheral Touch Controller (PTC) */ +#define ID_I2S 84 /**< \brief Inter-IC Sound Interface (I2S) */ + +#define ID_PERIPH_COUNT 85 /**< \brief Number of peripheral IDs */ +/*@}*/ + +/* ************************************************************************** */ +/** BASE ADDRESS DEFINITIONS FOR SAMD21J18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J18A_base Peripheral Base Address Definitions */ +/*@{*/ + +#if defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__) +#define AC (0x42004400U) /**< \brief (AC) APB Base Address */ +#define ADC (0x42004000U) /**< \brief (ADC) APB Base Address */ +#define DAC (0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DMAC (0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DSU (0x41002000U) /**< \brief (DSU) APB Base Address */ +#define EIC (0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EVSYS (0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define GCLK (0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define I2S (0x42005000U) /**< \brief (I2S) APB Base Address */ +#define MTB (0x41006000U) /**< \brief (MTB) APB Base Address */ +#define NVMCTRL (0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define PAC0 (0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 (0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 (0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PM (0x40000400U) /**< \brief (PM) APB Base Address */ +#define PORT (0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS (0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define RTC (0x40001400U) /**< \brief (RTC) APB Base Address */ +#define SERCOM0 (0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 (0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 (0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 (0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 (0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 (0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SYSCTRL (0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define TC3 (0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 (0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 (0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC6 (0x42003800U) /**< \brief (TC6) APB Base Address */ +#define TC7 (0x42003C00U) /**< \brief (TC7) APB Base Address */ +#define TCC0 (0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 (0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 (0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define USB (0x41005000U) /**< \brief (USB) APB Base Address */ +#define WDT (0x40001000U) /**< \brief (WDT) APB Base Address */ +#else +#define AC ((Ac *)0x42004400U) /**< \brief (AC) APB Base Address */ +#define AC_INST_NUM 1 /**< \brief (AC) Number of instances */ +#define AC_INSTS { AC } /**< \brief (AC) Instances List */ + +#define ADC ((Adc *)0x42004000U) /**< \brief (ADC) APB Base Address */ +#define ADC_INST_NUM 1 /**< \brief (ADC) Number of instances */ +#define ADC_INSTS { ADC } /**< \brief (ADC) Instances List */ + +#define DAC ((Dac *)0x42004800U) /**< \brief (DAC) APB Base Address */ +#define DAC_INST_NUM 1 /**< \brief (DAC) Number of instances */ +#define DAC_INSTS { DAC } /**< \brief (DAC) Instances List */ + +#define DMAC ((Dmac *)0x41004800U) /**< \brief (DMAC) APB Base Address */ +#define DMAC_INST_NUM 1 /**< \brief (DMAC) Number of instances */ +#define DMAC_INSTS { DMAC } /**< \brief (DMAC) Instances List */ + +#define DSU ((Dsu *)0x41002000U) /**< \brief (DSU) APB Base Address */ +#define DSU_INST_NUM 1 /**< \brief (DSU) Number of instances */ +#define DSU_INSTS { DSU } /**< \brief (DSU) Instances List */ + +#define EIC ((Eic *)0x40001800U) /**< \brief (EIC) APB Base Address */ +#define EIC_INST_NUM 1 /**< \brief (EIC) Number of instances */ +#define EIC_INSTS { EIC } /**< \brief (EIC) Instances List */ + +#define EVSYS ((Evsys *)0x42000400U) /**< \brief (EVSYS) APB Base Address */ +#define EVSYS_INST_NUM 1 /**< \brief (EVSYS) Number of instances */ +#define EVSYS_INSTS { EVSYS } /**< \brief (EVSYS) Instances List */ + +#define GCLK ((Gclk *)0x40000C00U) /**< \brief (GCLK) APB Base Address */ +#define GCLK_INST_NUM 1 /**< \brief (GCLK) Number of instances */ +#define GCLK_INSTS { GCLK } /**< \brief (GCLK) Instances List */ + +#define I2S ((I2s *)0x42005000U) /**< \brief (I2S) APB Base Address */ +#define I2S_INST_NUM 1 /**< \brief (I2S) Number of instances */ +#define I2S_INSTS { I2S } /**< \brief (I2S) Instances List */ + +#define MTB ((Mtb *)0x41006000U) /**< \brief (MTB) APB Base Address */ +#define MTB_INST_NUM 1 /**< \brief (MTB) Number of instances */ +#define MTB_INSTS { MTB } /**< \brief (MTB) Instances List */ + +#define NVMCTRL ((Nvmctrl *)0x41004000U) /**< \brief (NVMCTRL) APB Base Address */ +#define NVMCTRL_CAL (0x00800000U) /**< \brief (NVMCTRL) CAL Base Address */ +#define NVMCTRL_LOCKBIT (0x00802000U) /**< \brief (NVMCTRL) LOCKBIT Base Address */ +#define NVMCTRL_OTP1 (0x00806000U) /**< \brief (NVMCTRL) OTP1 Base Address */ +#define NVMCTRL_OTP2 (0x00806008U) /**< \brief (NVMCTRL) OTP2 Base Address */ +#define NVMCTRL_OTP4 (0x00806020U) /**< \brief (NVMCTRL) OTP4 Base Address */ +#define NVMCTRL_TEMP_LOG (0x00806030U) /**< \brief (NVMCTRL) TEMP_LOG Base Address */ +#define NVMCTRL_USER (0x00804000U) /**< \brief (NVMCTRL) USER Base Address */ +#define NVMCTRL_INST_NUM 1 /**< \brief (NVMCTRL) Number of instances */ +#define NVMCTRL_INSTS { NVMCTRL } /**< \brief (NVMCTRL) Instances List */ + +#define PAC0 ((Pac *)0x40000000U) /**< \brief (PAC0) APB Base Address */ +#define PAC1 ((Pac *)0x41000000U) /**< \brief (PAC1) APB Base Address */ +#define PAC2 ((Pac *)0x42000000U) /**< \brief (PAC2) APB Base Address */ +#define PAC_INST_NUM 3 /**< \brief (PAC) Number of instances */ +#define PAC_INSTS { PAC0, PAC1, PAC2 } /**< \brief (PAC) Instances List */ + +#define PM ((Pm *)0x40000400U) /**< \brief (PM) APB Base Address */ +#define PM_INST_NUM 1 /**< \brief (PM) Number of instances */ +#define PM_INSTS { PM } /**< \brief (PM) Instances List */ + +#define PORT ((Port *)0x41004400U) /**< \brief (PORT) APB Base Address */ +#define PORT_IOBUS ((Port *)0x60000000U) /**< \brief (PORT) IOBUS Base Address */ +#define PORT_INST_NUM 1 /**< \brief (PORT) Number of instances */ +#define PORT_INSTS { PORT } /**< \brief (PORT) Instances List */ + +#define PTC_GCLK_ID 34 +#define PTC_INST_NUM 1 /**< \brief (PTC) Number of instances */ +#define PTC_INSTS { PTC } /**< \brief (PTC) Instances List */ + +#define RTC ((Rtc *)0x40001400U) /**< \brief (RTC) APB Base Address */ +#define RTC_INST_NUM 1 /**< \brief (RTC) Number of instances */ +#define RTC_INSTS { RTC } /**< \brief (RTC) Instances List */ + +#define SERCOM0 ((Sercom *)0x42000800U) /**< \brief (SERCOM0) APB Base Address */ +#define SERCOM1 ((Sercom *)0x42000C00U) /**< \brief (SERCOM1) APB Base Address */ +#define SERCOM2 ((Sercom *)0x42001000U) /**< \brief (SERCOM2) APB Base Address */ +#define SERCOM3 ((Sercom *)0x42001400U) /**< \brief (SERCOM3) APB Base Address */ +#define SERCOM4 ((Sercom *)0x42001800U) /**< \brief (SERCOM4) APB Base Address */ +#define SERCOM5 ((Sercom *)0x42001C00U) /**< \brief (SERCOM5) APB Base Address */ +#define SERCOM_INST_NUM 6 /**< \brief (SERCOM) Number of instances */ +#define SERCOM_INSTS { SERCOM0, SERCOM1, SERCOM2, SERCOM3, SERCOM4, SERCOM5 } /**< \brief (SERCOM) Instances List */ + +#define SYSCTRL ((Sysctrl *)0x40000800U) /**< \brief (SYSCTRL) APB Base Address */ +#define SYSCTRL_INST_NUM 1 /**< \brief (SYSCTRL) Number of instances */ +#define SYSCTRL_INSTS { SYSCTRL } /**< \brief (SYSCTRL) Instances List */ + +#define TC3 ((Tc *)0x42002C00U) /**< \brief (TC3) APB Base Address */ +#define TC4 ((Tc *)0x42003000U) /**< \brief (TC4) APB Base Address */ +#define TC5 ((Tc *)0x42003400U) /**< \brief (TC5) APB Base Address */ +#define TC6 ((Tc *)0x42003800U) /**< \brief (TC6) APB Base Address */ +#define TC7 ((Tc *)0x42003C00U) /**< \brief (TC7) APB Base Address */ +#define TC_INST_NUM 5 /**< \brief (TC) Number of instances */ +#define TC_INSTS { TC3, TC4, TC5, TC6, TC7 } /**< \brief (TC) Instances List */ + +#define TCC0 ((Tcc *)0x42002000U) /**< \brief (TCC0) APB Base Address */ +#define TCC1 ((Tcc *)0x42002400U) /**< \brief (TCC1) APB Base Address */ +#define TCC2 ((Tcc *)0x42002800U) /**< \brief (TCC2) APB Base Address */ +#define TCC_INST_NUM 3 /**< \brief (TCC) Number of instances */ +#define TCC_INSTS { TCC0, TCC1, TCC2 } /**< \brief (TCC) Instances List */ + +#define USB ((Usb *)0x41005000U) /**< \brief (USB) APB Base Address */ +#define USB_INST_NUM 1 /**< \brief (USB) Number of instances */ +#define USB_INSTS { USB } /**< \brief (USB) Instances List */ + +#define WDT ((Wdt *)0x40001000U) /**< \brief (WDT) APB Base Address */ +#define WDT_INST_NUM 1 /**< \brief (WDT) Number of instances */ +#define WDT_INSTS { WDT } /**< \brief (WDT) Instances List */ + +#endif /* (defined(__ASSEMBLY__) || defined(__IAR_SYSTEMS_ASM__)) */ +/*@}*/ + +/* ************************************************************************** */ +/** PORT DEFINITIONS FOR SAMD21J18A */ +/* ************************************************************************** */ +/** \defgroup SAMD21J18A_port PORT Definitions */ +/*@{*/ + +#include "pio/samd21j18a.h" +/*@}*/ + +/* ************************************************************************** */ +/** MEMORY MAPPING DEFINITIONS FOR SAMD21J18A */ +/* ************************************************************************** */ + +#define FLASH_SIZE 0x40000 /* 256 kB */ +#define FLASH_PAGE_SIZE 64 +#define FLASH_NB_OF_PAGES 4096 +#define FLASH_USER_PAGE_SIZE 64 +#define HMCRAMC0_SIZE 0x8000 /* 32 kB */ +#define FLASH_ADDR (0x00000000U) /**< FLASH base address */ +#define FLASH_USER_PAGE_ADDR (0x00800000U) /**< FLASH_USER_PAGE base address */ +#define HMCRAMC0_ADDR (0x20000000U) /**< HMCRAMC0 base address */ + +#define DSU_DID_RESETVALUE 0x10010000 +#define EIC_EXTINT_NUM 16 +#define PORT_GROUPS 2 + +/* ************************************************************************** */ +/** ELECTRICAL DEFINITIONS FOR SAMD21J18A */ +/* ************************************************************************** */ + + +#ifdef __cplusplus +} +#endif + +/*@}*/ + +#endif /* SAMD21J18A_H */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/source/gcc/startup_samd21.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/source/gcc/startup_samd21.c new file mode 100755 index 0000000..d95be7c --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/source/gcc/startup_samd21.c @@ -0,0 +1,201 @@ +/** + * \file + * + * \brief gcc starttup file for SAMD21 + * + * Copyright (c) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include "samd21.h" + +/* Initialize segments */ +extern uint32_t _sfixed; +extern uint32_t _efixed; +extern uint32_t _etext; +extern uint32_t _srelocate; +extern uint32_t _erelocate; +extern uint32_t _szero; +extern uint32_t _ezero; +extern uint32_t _sstack; +extern uint32_t _estack; + +/** \cond DOXYGEN_SHOULD_SKIP_THIS */ +int main(void); +/** \endcond */ + +void __libc_init_array(void); + +/* Default empty handler */ +void Dummy_Handler(void); + +/* Cortex-M0+ core handlers */ +void NMI_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void HardFault_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void SVC_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void PendSV_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void SysTick_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); + +/* Peripherals handlers */ +void PM_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void SYSCTRL_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void WDT_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void RTC_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void EIC_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void NVMCTRL_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void DMAC_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void USB_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void EVSYS_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void SERCOM0_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void SERCOM1_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void SERCOM2_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void SERCOM3_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void SERCOM4_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void SERCOM5_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void TCC0_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void TCC1_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void TCC2_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void TC3_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void TC4_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void TC5_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void TC6_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void TC7_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void ADC_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void AC_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void DAC_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void PTC_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); +void I2S_Handler ( void ) __attribute__ ((weak, alias("Dummy_Handler"))); + +/* Exception Table */ +__attribute__ ((section(".vectors"))) +const DeviceVectors exception_table = { + + /* Configure Initial Stack Pointer, using linker-generated symbols */ + (void*) (&_estack), + + (void*) Reset_Handler, + (void*) NMI_Handler, + (void*) HardFault_Handler, + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) SVC_Handler, + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) PendSV_Handler, + (void*) SysTick_Handler, + + /* Configurable interrupts */ + (void*) PM_Handler, /* 0 Power Manager */ + (void*) SYSCTRL_Handler, /* 1 System Control */ + (void*) WDT_Handler, /* 2 Watchdog Timer */ + (void*) RTC_Handler, /* 3 Real-Time Counter */ + (void*) EIC_Handler, /* 4 External Interrupt Controller */ + (void*) NVMCTRL_Handler, /* 5 Non-Volatile Memory Controller */ + (void*) DMAC_Handler, /* 6 Direct Memory Access Controller */ + (void*) USB_Handler, /* 7 Universal Serial Bus */ + (void*) EVSYS_Handler, /* 8 Event System Interface */ + (void*) SERCOM0_Handler, /* 9 Serial Communication Interface 0 */ + (void*) SERCOM1_Handler, /* 10 Serial Communication Interface 1 */ + (void*) SERCOM2_Handler, /* 11 Serial Communication Interface 2 */ + (void*) SERCOM3_Handler, /* 12 Serial Communication Interface 3 */ + (void*) SERCOM4_Handler, /* 13 Serial Communication Interface 4 */ + (void*) SERCOM5_Handler, /* 14 Serial Communication Interface 5 */ + (void*) TCC0_Handler, /* 15 Timer Counter Control 0 */ + (void*) TCC1_Handler, /* 16 Timer Counter Control 1 */ + (void*) TCC2_Handler, /* 17 Timer Counter Control 2 */ + (void*) TC3_Handler, /* 18 Basic Timer Counter 0 */ + (void*) TC4_Handler, /* 19 Basic Timer Counter 1 */ + (void*) TC5_Handler, /* 20 Basic Timer Counter 2 */ + (void*) TC6_Handler, /* 21 Basic Timer Counter 3 */ + (void*) TC7_Handler, /* 22 Basic Timer Counter 4 */ + (void*) ADC_Handler, /* 23 Analog Digital Converter */ + (void*) AC_Handler, /* 24 Analog Comparators */ + (void*) DAC_Handler, /* 25 Digital Analog Converter */ + (void*) PTC_Handler, /* 26 Peripheral Touch Controller */ + (void*) I2S_Handler /* 27 Inter-IC Sound Interface */ +}; + +/** + * \brief This is the code that gets called on processor reset. + * To initialize the device, and call the main() routine. + */ +void Reset_Handler(void) +{ + uint32_t *pSrc, *pDest; + + /* Initialize the relocate segment */ + pSrc = &_etext; + pDest = &_srelocate; + + if (pSrc != pDest) { + for (; pDest < &_erelocate;) { + *pDest++ = *pSrc++; + } + } + + /* Clear the zero segment */ + for (pDest = &_szero; pDest < &_ezero;) { + *pDest++ = 0; + } + + /* Set the vector table base address */ + pSrc = (uint32_t *) & _sfixed; + SCB->VTOR = ((uint32_t) pSrc & SCB_VTOR_TBLOFF_Msk); + + /* Initialize the C library */ + __libc_init_array(); + + /* Branch to main function */ + main(); + + /* Infinite loop */ + while (1); +} + +/** + * \brief Default interrupt handler for unused IRQs. + */ +void Dummy_Handler(void) +{ + while (1) { + } +} diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/source/system_samd21.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/source/system_samd21.c new file mode 100755 index 0000000..917f3b0 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/source/system_samd21.c @@ -0,0 +1,78 @@ +/** + * \file + * + * \brief Low-level initialization functions called upon chip startup. + * + * Copyright (c) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include "samd21.h" + +/** + * Initial system clock frequency. The System RC Oscillator (RCSYS) provides + * the source for the main clock at chip startup. + */ +#define __SYSTEM_CLOCK (1000000) + +uint32_t SystemCoreClock = __SYSTEM_CLOCK;/*!< System Clock Frequency (Core Clock)*/ + +/** + * Initialize the system + * + * @brief Setup the microcontroller system. + * Initialize the System and update the SystemCoreClock variable. + */ +void SystemInit(void) +{ + // Keep the default device state after reset + SystemCoreClock = __SYSTEM_CLOCK; + return; +} + +/** + * Update SystemCoreClock variable + * + * @brief Updates the SystemCoreClock with current core Clock + * retrieved from cpu registers. + */ +void SystemCoreClockUpdate(void) +{ + // Not implemented + SystemCoreClock = __SYSTEM_CLOCK; + return; +} diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/source/system_samd21.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/source/system_samd21.h new file mode 100755 index 0000000..5cf7d40 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/cmsis/samd21/source/system_samd21.h @@ -0,0 +1,62 @@ +/** + * \file + * + * \brief Low-level initialization functions called upon chip startup + * + * Copyright (c) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SYSTEM_SAMD21_H_INCLUDED_ +#define _SYSTEM_SAMD21_H_INCLUDED_ + +#ifdef __cplusplus +extern "C" { +#endif + +#include + +extern uint32_t SystemCoreClock; /*!< System Clock Frequency (Core Clock) */ + +void SystemInit(void); +void SystemCoreClockUpdate(void); + +#ifdef __cplusplus +} +#endif + +#endif /* SYSTEM_SAMD21_H_INCLUDED */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/compiler.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/compiler.h new file mode 100755 index 0000000..1d3fd78 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/compiler.h @@ -0,0 +1,1169 @@ +/** + * \file + * + * \brief Commonly used includes, types and macros. + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef UTILS_COMPILER_H_INCLUDED +#define UTILS_COMPILER_H_INCLUDED + +/** + * \defgroup group_sam0_utils Compiler abstraction layer and code utilities + * + * Compiler abstraction layer and code utilities for Cortex-M0+ based Atmel SAM devices. + * This module provides various abstraction layers and utilities to make code compatible between different compilers. + * + * @{ + */ + +#if (defined __ICCARM__) +# include +#endif + +#include +#include +#include +#include +#include + +#ifndef __ASSEMBLY__ + +#include +#include +#include +#include + +/** + * \def UNUSED + * \brief Marking \a v as a unused parameter or value. + */ +#define UNUSED(v) (void)(v) + +/** + * \def barrier + * \brief Memory barrier + */ +#ifdef __GNUC__ +# define barrier() asm volatile("" ::: "memory") +#else +# define barrier() asm ("") +#endif + +/** + * \brief Emit the compiler pragma \a arg. + * + * \param[in] arg The pragma directive as it would appear after \e \#pragma + * (i.e. not stringified). + */ +#define COMPILER_PRAGMA(arg) _Pragma(#arg) + +/** + * \def COMPILER_PACK_SET(alignment) + * \brief Set maximum alignment for subsequent struct and union definitions to \a alignment. + */ +#define COMPILER_PACK_SET(alignment) COMPILER_PRAGMA(pack(alignment)) + +/** + * \def COMPILER_PACK_RESET() + * \brief Set default alignment for subsequent struct and union definitions. + */ +#define COMPILER_PACK_RESET() COMPILER_PRAGMA(pack()) + + +/** + * \brief Set aligned boundary. + */ +#if (defined __GNUC__) || (defined __CC_ARM) +# define COMPILER_ALIGNED(a) __attribute__((__aligned__(a))) +#elif (defined __ICCARM__) +# define COMPILER_ALIGNED(a) COMPILER_PRAGMA(data_alignment = a) +#endif + +/** + * \brief Set word-aligned boundary. + */ +#if (defined __GNUC__) || defined(__CC_ARM) +#define COMPILER_WORD_ALIGNED __attribute__((__aligned__(4))) +#elif (defined __ICCARM__) +#define COMPILER_WORD_ALIGNED COMPILER_PRAGMA(data_alignment = 4) +#endif + +/** + * \def __always_inline + * \brief The function should always be inlined. + * + * This annotation instructs the compiler to ignore its inlining + * heuristics and inline the function no matter how big it thinks it + * becomes. + */ +#if defined(__CC_ARM) +# define __always_inline __forceinline +#elif (defined __GNUC__) +# define __always_inline __attribute__((__always_inline__)) +#elif (defined __ICCARM__) +# define __always_inline _Pragma("inline=forced") +#endif + +/** + * \def __no_inline + * \brief The function should never be inlined + * + * This annotation instructs the compiler to ignore its inlining + * heuristics and not inline the function no matter how small it thinks it + * becomes. + */ +#if defined(__CC_ARM) +# define __no_inline __attribute__((noinline)) +#elif (defined __GNUC__) +# define __no_inline __attribute__((noinline)) +#elif (defined __ICCARM__) +# define __no_inline _Pragma("inline=never") +#endif + + +/** \brief This macro is used to test fatal errors. + * + * The macro tests if the expression is false. If it is, a fatal error is + * detected and the application hangs up. If \c TEST_SUITE_DEFINE_ASSERT_MACRO + * is defined, a unit test version of the macro is used, to allow execution + * of further tests after a false expression. + * + * \param[in] expr Expression to evaluate and supposed to be nonzero. + */ +#if defined(_ASSERT_ENABLE_) +# if defined(TEST_SUITE_DEFINE_ASSERT_MACRO) +# include "unit_test/suite.h" +# else +# undef TEST_SUITE_DEFINE_ASSERT_MACRO +# define Assert(expr) \ + {\ + if (!(expr)) asm("BKPT #0");\ + } +# endif +#else +# define Assert(expr) ((void) 0) +#endif + +/* Define WEAK attribute */ +#if defined ( __CC_ARM ) +# define WEAK __attribute__ ((weak)) +#elif defined ( __ICCARM__ ) +# define WEAK __weak +#elif defined ( __GNUC__ ) +# define WEAK __attribute__ ((weak)) +#endif + +/* Define NO_INIT attribute */ +#if defined ( __CC_ARM ) +# define NO_INIT __attribute__((zero_init)) +#elif defined ( __ICCARM__ ) +# define NO_INIT __no_init +#elif defined ( __GNUC__ ) +# define NO_INIT __attribute__((section(".no_init"))) +#endif + +#include "interrupt.h" + +/** \name Usual Types + * @{ */ +#ifndef __cplusplus +# if !defined(__bool_true_false_are_defined) +typedef unsigned char bool; +# endif +#endif +typedef uint16_t le16_t; +typedef uint16_t be16_t; +typedef uint32_t le32_t; +typedef uint32_t be32_t; +typedef uint32_t iram_size_t; +/** @} */ + +/** \name Aliasing Aggregate Types + * @{ */ + +/** 16-bit union. */ +typedef union +{ + int16_t s16; + uint16_t u16; + int8_t s8[2]; + uint8_t u8[2]; +} Union16; + +/** 32-bit union. */ +typedef union +{ + int32_t s32; + uint32_t u32; + int16_t s16[2]; + uint16_t u16[2]; + int8_t s8[4]; + uint8_t u8[4]; +} Union32; + +/** 64-bit union. */ +typedef union +{ + int64_t s64; + uint64_t u64; + int32_t s32[2]; + uint32_t u32[2]; + int16_t s16[4]; + uint16_t u16[4]; + int8_t s8[8]; + uint8_t u8[8]; +} Union64; + +/** Union of pointers to 64-, 32-, 16- and 8-bit unsigned integers. */ +typedef union +{ + int64_t *s64ptr; + uint64_t *u64ptr; + int32_t *s32ptr; + uint32_t *u32ptr; + int16_t *s16ptr; + uint16_t *u16ptr; + int8_t *s8ptr; + uint8_t *u8ptr; +} UnionPtr; + +/** Union of pointers to volatile 64-, 32-, 16- and 8-bit unsigned integers. */ +typedef union +{ + volatile int64_t *s64ptr; + volatile uint64_t *u64ptr; + volatile int32_t *s32ptr; + volatile uint32_t *u32ptr; + volatile int16_t *s16ptr; + volatile uint16_t *u16ptr; + volatile int8_t *s8ptr; + volatile uint8_t *u8ptr; +} UnionVPtr; + +/** Union of pointers to constant 64-, 32-, 16- and 8-bit unsigned integers. */ +typedef union +{ + const int64_t *s64ptr; + const uint64_t *u64ptr; + const int32_t *s32ptr; + const uint32_t *u32ptr; + const int16_t *s16ptr; + const uint16_t *u16ptr; + const int8_t *s8ptr; + const uint8_t *u8ptr; +} UnionCPtr; + +/** Union of pointers to constant volatile 64-, 32-, 16- and 8-bit unsigned integers. */ +typedef union +{ + const volatile int64_t *s64ptr; + const volatile uint64_t *u64ptr; + const volatile int32_t *s32ptr; + const volatile uint32_t *u32ptr; + const volatile int16_t *s16ptr; + const volatile uint16_t *u16ptr; + const volatile int8_t *s8ptr; + const volatile uint8_t *u8ptr; +} UnionCVPtr; + +/** Structure of pointers to 64-, 32-, 16- and 8-bit unsigned integers. */ +typedef struct +{ + int64_t *s64ptr; + uint64_t *u64ptr; + int32_t *s32ptr; + uint32_t *u32ptr; + int16_t *s16ptr; + uint16_t *u16ptr; + int8_t *s8ptr; + uint8_t *u8ptr; +} StructPtr; + +/** Structure of pointers to volatile 64-, 32-, 16- and 8-bit unsigned integers. */ +typedef struct +{ + volatile int64_t *s64ptr; + volatile uint64_t *u64ptr; + volatile int32_t *s32ptr; + volatile uint32_t *u32ptr; + volatile int16_t *s16ptr; + volatile uint16_t *u16ptr; + volatile int8_t *s8ptr; + volatile uint8_t *u8ptr; +} StructVPtr; + +/** Structure of pointers to constant 64-, 32-, 16- and 8-bit unsigned integers. */ +typedef struct +{ + const int64_t *s64ptr; + const uint64_t *u64ptr; + const int32_t *s32ptr; + const uint32_t *u32ptr; + const int16_t *s16ptr; + const uint16_t *u16ptr; + const int8_t *s8ptr; + const uint8_t *u8ptr; +} StructCPtr; + +/** Structure of pointers to constant volatile 64-, 32-, 16- and 8-bit unsigned integers. */ +typedef struct +{ + const volatile int64_t *s64ptr; + const volatile uint64_t *u64ptr; + const volatile int32_t *s32ptr; + const volatile uint32_t *u32ptr; + const volatile int16_t *s16ptr; + const volatile uint16_t *u16ptr; + const volatile int8_t *s8ptr; + const volatile uint8_t *u8ptr; +} StructCVPtr; + +/** @} */ + +#endif /* #ifndef __ASSEMBLY__ */ + +/** \name Usual Constants + * @{ */ +#define DISABLE 0 +#define ENABLE 1 + +#ifndef __cplusplus +# if !defined(__bool_true_false_are_defined) +# define false 0 +# define true 1 +# endif +#endif +/** @} */ + +#ifndef __ASSEMBLY__ + +/** \name Optimization Control + * @{ */ + +/** + * \def likely(exp) + * \brief The expression \a exp is likely to be true + */ +#if !defined(likely) || defined(__DOXYGEN__) +# define likely(exp) (exp) +#endif + +/** + * \def unlikely(exp) + * \brief The expression \a exp is unlikely to be true + */ +#if !defined(unlikely) || defined(__DOXYGEN__) +# define unlikely(exp) (exp) +#endif + +/** + * \def is_constant(exp) + * \brief Determine if an expression evaluates to a constant value. + * + * \param[in] exp Any expression + * + * \return true if \a exp is constant, false otherwise. + */ +#if (defined __GNUC__) || (defined __CC_ARM) +# define is_constant(exp) __builtin_constant_p(exp) +#else +# define is_constant(exp) (0) +#endif + +/** @} */ + +/** \name Bit-Field Handling + * @{ */ + +/** \brief Reads the bits of a value specified by a given bit-mask. + * + * \param[in] value Value to read bits from. + * \param[in] mask Bit-mask indicating bits to read. + * + * \return Read bits. + */ +#define Rd_bits( value, mask) ((value) & (mask)) + +/** \brief Writes the bits of a C lvalue specified by a given bit-mask. + * + * \param[in] lvalue C lvalue to write bits to. + * \param[in] mask Bit-mask indicating bits to write. + * \param[in] bits Bits to write. + * + * \return Resulting value with written bits. + */ +#define Wr_bits(lvalue, mask, bits) ((lvalue) = ((lvalue) & ~(mask)) |\ + ((bits ) & (mask))) + +/** \brief Tests the bits of a value specified by a given bit-mask. + * + * \param[in] value Value of which to test bits. + * \param[in] mask Bit-mask indicating bits to test. + * + * \return \c 1 if at least one of the tested bits is set, else \c 0. + */ +#define Tst_bits( value, mask) (Rd_bits(value, mask) != 0) + +/** \brief Clears the bits of a C lvalue specified by a given bit-mask. + * + * \param[in] lvalue C lvalue of which to clear bits. + * \param[in] mask Bit-mask indicating bits to clear. + * + * \return Resulting value with cleared bits. + */ +#define Clr_bits(lvalue, mask) ((lvalue) &= ~(mask)) + +/** \brief Sets the bits of a C lvalue specified by a given bit-mask. + * + * \param[in] lvalue C lvalue of which to set bits. + * \param[in] mask Bit-mask indicating bits to set. + * + * \return Resulting value with set bits. + */ +#define Set_bits(lvalue, mask) ((lvalue) |= (mask)) + +/** \brief Toggles the bits of a C lvalue specified by a given bit-mask. + * + * \param[in] lvalue C lvalue of which to toggle bits. + * \param[in] mask Bit-mask indicating bits to toggle. + * + * \return Resulting value with toggled bits. + */ +#define Tgl_bits(lvalue, mask) ((lvalue) ^= (mask)) + +/** \brief Reads the bit-field of a value specified by a given bit-mask. + * + * \param[in] value Value to read a bit-field from. + * \param[in] mask Bit-mask indicating the bit-field to read. + * + * \return Read bit-field. + */ +#define Rd_bitfield( value, mask) (Rd_bits( value, mask) >> ctz(mask)) + +/** \brief Writes the bit-field of a C lvalue specified by a given bit-mask. + * + * \param[in] lvalue C lvalue to write a bit-field to. + * \param[in] mask Bit-mask indicating the bit-field to write. + * \param[in] bitfield Bit-field to write. + * + * \return Resulting value with written bit-field. + */ +#define Wr_bitfield(lvalue, mask, bitfield) (Wr_bits(lvalue, mask, (uint32_t)(bitfield) << ctz(mask))) + +/** @} */ + + +/** \name Zero-Bit Counting + * + * Under GCC, __builtin_clz and __builtin_ctz behave like macros when + * applied to constant expressions (values known at compile time), so they are + * more optimized than the use of the corresponding assembly instructions and + * they can be used as constant expressions e.g. to initialize objects having + * static storage duration, and like the corresponding assembly instructions + * when applied to non-constant expressions (values unknown at compile time), so + * they are more optimized than an assembly periphrasis. Hence, clz and ctz + * ensure a possible and optimized behavior for both constant and non-constant + * expressions. + * + * @{ */ + +/** \brief Counts the leading zero bits of the given value considered as a 32-bit integer. + * + * \param[in] u Value of which to count the leading zero bits. + * + * \return The count of leading zero bits in \a u. + */ +#if (defined __GNUC__) || (defined __CC_ARM) +# define clz(u) __builtin_clz(u) +#else +# define clz(u) (((u) == 0) ? 32 : \ + ((u) & (1ul << 31)) ? 0 : \ + ((u) & (1ul << 30)) ? 1 : \ + ((u) & (1ul << 29)) ? 2 : \ + ((u) & (1ul << 28)) ? 3 : \ + ((u) & (1ul << 27)) ? 4 : \ + ((u) & (1ul << 26)) ? 5 : \ + ((u) & (1ul << 25)) ? 6 : \ + ((u) & (1ul << 24)) ? 7 : \ + ((u) & (1ul << 23)) ? 8 : \ + ((u) & (1ul << 22)) ? 9 : \ + ((u) & (1ul << 21)) ? 10 : \ + ((u) & (1ul << 20)) ? 11 : \ + ((u) & (1ul << 19)) ? 12 : \ + ((u) & (1ul << 18)) ? 13 : \ + ((u) & (1ul << 17)) ? 14 : \ + ((u) & (1ul << 16)) ? 15 : \ + ((u) & (1ul << 15)) ? 16 : \ + ((u) & (1ul << 14)) ? 17 : \ + ((u) & (1ul << 13)) ? 18 : \ + ((u) & (1ul << 12)) ? 19 : \ + ((u) & (1ul << 11)) ? 20 : \ + ((u) & (1ul << 10)) ? 21 : \ + ((u) & (1ul << 9)) ? 22 : \ + ((u) & (1ul << 8)) ? 23 : \ + ((u) & (1ul << 7)) ? 24 : \ + ((u) & (1ul << 6)) ? 25 : \ + ((u) & (1ul << 5)) ? 26 : \ + ((u) & (1ul << 4)) ? 27 : \ + ((u) & (1ul << 3)) ? 28 : \ + ((u) & (1ul << 2)) ? 29 : \ + ((u) & (1ul << 1)) ? 30 : \ + 31) +#endif + +/** \brief Counts the trailing zero bits of the given value considered as a 32-bit integer. + * + * \param[in] u Value of which to count the trailing zero bits. + * + * \return The count of trailing zero bits in \a u. + */ +#if (defined __GNUC__) || (defined __CC_ARM) +# define ctz(u) __builtin_ctz(u) +#else +# define ctz(u) ((u) & (1ul << 0) ? 0 : \ + (u) & (1ul << 1) ? 1 : \ + (u) & (1ul << 2) ? 2 : \ + (u) & (1ul << 3) ? 3 : \ + (u) & (1ul << 4) ? 4 : \ + (u) & (1ul << 5) ? 5 : \ + (u) & (1ul << 6) ? 6 : \ + (u) & (1ul << 7) ? 7 : \ + (u) & (1ul << 8) ? 8 : \ + (u) & (1ul << 9) ? 9 : \ + (u) & (1ul << 10) ? 10 : \ + (u) & (1ul << 11) ? 11 : \ + (u) & (1ul << 12) ? 12 : \ + (u) & (1ul << 13) ? 13 : \ + (u) & (1ul << 14) ? 14 : \ + (u) & (1ul << 15) ? 15 : \ + (u) & (1ul << 16) ? 16 : \ + (u) & (1ul << 17) ? 17 : \ + (u) & (1ul << 18) ? 18 : \ + (u) & (1ul << 19) ? 19 : \ + (u) & (1ul << 20) ? 20 : \ + (u) & (1ul << 21) ? 21 : \ + (u) & (1ul << 22) ? 22 : \ + (u) & (1ul << 23) ? 23 : \ + (u) & (1ul << 24) ? 24 : \ + (u) & (1ul << 25) ? 25 : \ + (u) & (1ul << 26) ? 26 : \ + (u) & (1ul << 27) ? 27 : \ + (u) & (1ul << 28) ? 28 : \ + (u) & (1ul << 29) ? 29 : \ + (u) & (1ul << 30) ? 30 : \ + (u) & (1ul << 31) ? 31 : \ + 32) +#endif + +/** @} */ + + +/** \name Bit Reversing + * @{ */ + +/** \brief Reverses the bits of \a u8. + * + * \param[in] u8 U8 of which to reverse the bits. + * + * \return Value resulting from \a u8 with reversed bits. + */ +#define bit_reverse8(u8) ((U8)(bit_reverse32((U8)(u8)) >> 24)) + +/** \brief Reverses the bits of \a u16. + * + * \param[in] u16 U16 of which to reverse the bits. + * + * \return Value resulting from \a u16 with reversed bits. + */ +#define bit_reverse16(u16) ((uint16_t)(bit_reverse32((uint16_t)(u16)) >> 16)) + +/** \brief Reverses the bits of \a u32. + * + * \param[in] u32 U32 of which to reverse the bits. + * + * \return Value resulting from \a u32 with reversed bits. + */ +#define bit_reverse32(u32) __RBIT(u32) + +/** \brief Reverses the bits of \a u64. + * + * \param[in] u64 U64 of which to reverse the bits. + * + * \return Value resulting from \a u64 with reversed bits. + */ +#define bit_reverse64(u64) ((uint64_t)(((uint64_t)bit_reverse32((uint64_t)(u64) >> 32)) |\ + ((uint64_t)bit_reverse32((uint64_t)(u64)) << 32))) + +/** @} */ + + +/** \name Alignment + * @{ */ + +/** \brief Tests alignment of the number \a val with the \a n boundary. + * + * \param[in] val Input value. + * \param[in] n Boundary. + * + * \return \c 1 if the number \a val is aligned with the \a n boundary, else \c 0. + */ +#define Test_align(val, n) (!Tst_bits( val, (n) - 1 ) ) + +/** \brief Gets alignment of the number \a val with respect to the \a n boundary. + * + * \param[in] val Input value. + * \param[in] n Boundary. + * + * \return Alignment of the number \a val with respect to the \a n boundary. + */ +#define Get_align(val, n) ( Rd_bits( val, (n) - 1 ) ) + +/** \brief Sets alignment of the lvalue number \a lval to \a alg with respect to the \a n boundary. + * + * \param[in] lval Input/output lvalue. + * \param[in] n Boundary. + * \param[in] alg Alignment. + * + * \return New value of \a lval resulting from its alignment set to \a alg with respect to the \a n boundary. + */ +#define Set_align(lval, n, alg) ( Wr_bits(lval, (n) - 1, alg) ) + +/** \brief Aligns the number \a val with the upper \a n boundary. + * + * \param[in] val Input value. + * \param[in] n Boundary. + * + * \return Value resulting from the number \a val aligned with the upper \a n boundary. + */ +#define Align_up( val, n) (((val) + ((n) - 1)) & ~((n) - 1)) + +/** \brief Aligns the number \a val with the lower \a n boundary. + * + * \param[in] val Input value. + * \param[in] n Boundary. + * + * \return Value resulting from the number \a val aligned with the lower \a n boundary. + */ +#define Align_down(val, n) ( (val) & ~((n) - 1)) + +/** @} */ + + +/** \name Mathematics + * + * The same considerations as for clz and ctz apply here but GCC does not + * provide built-in functions to access the assembly instructions abs, min and + * max and it does not produce them by itself in most cases, so two sets of + * macros are defined here: + * - Abs, Min and Max to apply to constant expressions (values known at + * compile time); + * - abs, min and max to apply to non-constant expressions (values unknown at + * compile time), abs is found in stdlib.h. + * + * @{ */ + +/** \brief Takes the absolute value of \a a. + * + * \param[in] a Input value. + * + * \return Absolute value of \a a. + * + * \note More optimized if only used with values known at compile time. + */ +#define Abs(a) (((a) < 0 ) ? -(a) : (a)) + +/** \brief Takes the minimal value of \a a and \a b. + * + * \param[in] a Input value. + * \param[in] b Input value. + * + * \return Minimal value of \a a and \a b. + * + * \note More optimized if only used with values known at compile time. + */ +#define Min(a, b) (((a) < (b)) ? (a) : (b)) + +/** \brief Takes the maximal value of \a a and \a b. + * + * \param[in] a Input value. + * \param[in] b Input value. + * + * \return Maximal value of \a a and \a b. + * + * \note More optimized if only used with values known at compile time. + */ +#define Max(a, b) (((a) > (b)) ? (a) : (b)) + +/** \brief Takes the minimal value of \a a and \a b. + * + * \param[in] a Input value. + * \param[in] b Input value. + * + * \return Minimal value of \a a and \a b. + * + * \note More optimized if only used with values unknown at compile time. + */ +#define min(a, b) Min(a, b) + +/** \brief Takes the maximal value of \a a and \a b. + * + * \param[in] a Input value. + * \param[in] b Input value. + * + * \return Maximal value of \a a and \a b. + * + * \note More optimized if only used with values unknown at compile time. + */ +#define max(a, b) Max(a, b) + +/** @} */ + + +/** \brief Calls the routine at address \a addr. + * + * It generates a long call opcode. + * + * For example, `Long_call(0x80000000)' generates a software reset on a UC3 if + * it is invoked from the CPU supervisor mode. + * + * \param[in] addr Address of the routine to call. + * + * \note It may be used as a long jump opcode in some special cases. + */ +#define Long_call(addr) ((*(void (*)(void))(addr))()) + + +/** \name MCU Endianism Handling + * ARM is MCU little endian. + * + * @{ */ +#define BE16(x) Swap16(x) +#define LE16(x) (x) + +#define le16_to_cpu(x) (x) +#define cpu_to_le16(x) (x) +#define LE16_TO_CPU(x) (x) +#define CPU_TO_LE16(x) (x) + +#define be16_to_cpu(x) Swap16(x) +#define cpu_to_be16(x) Swap16(x) +#define BE16_TO_CPU(x) Swap16(x) +#define CPU_TO_BE16(x) Swap16(x) + +#define le32_to_cpu(x) (x) +#define cpu_to_le32(x) (x) +#define LE32_TO_CPU(x) (x) +#define CPU_TO_LE32(x) (x) + +#define be32_to_cpu(x) swap32(x) +#define cpu_to_be32(x) swap32(x) +#define BE32_TO_CPU(x) swap32(x) +#define CPU_TO_BE32(x) swap32(x) +/** @} */ + + +/** \name Endianism Conversion + * + * The same considerations as for clz and ctz apply here but GCC's + * __builtin_bswap_32 and __builtin_bswap_64 do not behave like macros when + * applied to constant expressions, so two sets of macros are defined here: + * - Swap16, Swap32 and Swap64 to apply to constant expressions (values known + * at compile time); + * - swap16, swap32 and swap64 to apply to non-constant expressions (values + * unknown at compile time). + * + * @{ */ + +/** \brief Toggles the endianism of \a u16 (by swapping its bytes). + * + * \param[in] u16 U16 of which to toggle the endianism. + * + * \return Value resulting from \a u16 with toggled endianism. + * + * \note More optimized if only used with values known at compile time. + */ +#define Swap16(u16) ((uint16_t)(((uint16_t)(u16) >> 8) |\ + ((uint16_t)(u16) << 8))) + +/** \brief Toggles the endianism of \a u32 (by swapping its bytes). + * + * \param[in] u32 U32 of which to toggle the endianism. + * + * \return Value resulting from \a u32 with toggled endianism. + * + * \note More optimized if only used with values known at compile time. + */ +#define Swap32(u32) ((uint32_t)(((uint32_t)Swap16((uint32_t)(u32) >> 16)) |\ + ((uint32_t)Swap16((uint32_t)(u32)) << 16))) + +/** \brief Toggles the endianism of \a u64 (by swapping its bytes). + * + * \param[in] u64 U64 of which to toggle the endianism. + * + * \return Value resulting from \a u64 with toggled endianism. + * + * \note More optimized if only used with values known at compile time. + */ +#define Swap64(u64) ((uint64_t)(((uint64_t)Swap32((uint64_t)(u64) >> 32)) |\ + ((uint64_t)Swap32((uint64_t)(u64)) << 32))) + +/** \brief Toggles the endianism of \a u16 (by swapping its bytes). + * + * \param[in] u16 U16 of which to toggle the endianism. + * + * \return Value resulting from \a u16 with toggled endianism. + * + * \note More optimized if only used with values unknown at compile time. + */ +#define swap16(u16) Swap16(u16) + +/** \brief Toggles the endianism of \a u32 (by swapping its bytes). + * + * \param[in] u32 U32 of which to toggle the endianism. + * + * \return Value resulting from \a u32 with toggled endianism. + * + * \note More optimized if only used with values unknown at compile time. + */ +#if (defined __GNUC__) +# define swap32(u32) ((uint32_t)__builtin_bswap32((uint32_t)(u32))) +#else +# define swap32(u32) Swap32(u32) +#endif + +/** \brief Toggles the endianism of \a u64 (by swapping its bytes). + * + * \param[in] u64 U64 of which to toggle the endianism. + * + * \return Value resulting from \a u64 with toggled endianism. + * + * \note More optimized if only used with values unknown at compile time. + */ +#if (defined __GNUC__) +# define swap64(u64) ((uint64_t)__builtin_bswap64((uint64_t)(u64))) +#else +# define swap64(u64) ((uint64_t)(((uint64_t)swap32((uint64_t)(u64) >> 32)) |\ + ((uint64_t)swap32((uint64_t)(u64)) << 32))) +#endif + +/** @} */ + + +/** \name Target Abstraction + * + * @{ */ + +#define _GLOBEXT_ extern /**< extern storage-class specifier. */ +#define _CONST_TYPE_ const /**< const type qualifier. */ +#define _MEM_TYPE_SLOW_ /**< Slow memory type. */ +#define _MEM_TYPE_MEDFAST_ /**< Fairly fast memory type. */ +#define _MEM_TYPE_FAST_ /**< Fast memory type. */ + +#define memcmp_ram2ram memcmp /**< Target-specific memcmp of RAM to RAM. */ +#define memcmp_code2ram memcmp /**< Target-specific memcmp of RAM to NVRAM. */ +#define memcpy_ram2ram memcpy /**< Target-specific memcpy from RAM to RAM. */ +#define memcpy_code2ram memcpy /**< Target-specific memcpy from NVRAM to RAM. */ + +/** @} */ + +/** + * \brief Calculate \f$ \left\lceil \frac{a}{b} \right\rceil \f$ using + * integer arithmetic. + * + * \param[in] a An integer + * \param[in] b Another integer + * + * \return (\a a / \a b) rounded up to the nearest integer. + */ +#define div_ceil(a, b) (((a) + (b) - 1) / (b)) + +#endif /* #ifndef __ASSEMBLY__ */ +#ifdef __ICCARM__ +/** \name Compiler Keywords + * + * Port of some keywords from GCC to IAR Embedded Workbench. + * + * @{ */ + +#define __asm__ asm +#define __inline__ inline +#define __volatile__ + +/** @} */ + +#endif + +#define FUNC_PTR void * +/** + * \def unused + * \brief Marking \a v as a unused parameter or value. + */ +#define unused(v) do { (void)(v); } while(0) + +/* Define RAMFUNC attribute */ +#if defined ( __CC_ARM ) /* Keil uVision 4 */ +# define RAMFUNC __attribute__ ((section(".ramfunc"))) +#elif defined ( __ICCARM__ ) /* IAR Ewarm 5.41+ */ +# define RAMFUNC __ramfunc +#elif defined ( __GNUC__ ) /* GCC CS3 2009q3-68 */ +# define RAMFUNC __attribute__ ((section(".ramfunc"))) +#endif + +/* Define OPTIMIZE_HIGH attribute */ +#if defined ( __CC_ARM ) /* Keil uVision 4 */ +# define OPTIMIZE_HIGH _Pragma("O3") +#elif defined ( __ICCARM__ ) /* IAR Ewarm 5.41+ */ +# define OPTIMIZE_HIGH _Pragma("optimize=high") +#elif defined ( __GNUC__ ) /* GCC CS3 2009q3-68 */ +# define OPTIMIZE_HIGH __attribute__((optimize(s))) +#endif +#define PASS 0 +#define FAIL 1 +#define LOW 0 +#define HIGH 1 + +typedef int8_t S8 ; //!< 8-bit signed integer. +typedef uint8_t U8 ; //!< 8-bit unsigned integer. +typedef int16_t S16; //!< 16-bit signed integer. +typedef uint16_t U16; //!< 16-bit unsigned integer. +typedef int32_t S32; //!< 32-bit signed integer. +typedef uint32_t U32; //!< 32-bit unsigned integer. +typedef int64_t S64; //!< 64-bit signed integer. +typedef uint64_t U64; //!< 64-bit unsigned integer. +typedef float F32; //!< 32-bit floating-point number. +typedef double F64; //!< 64-bit floating-point number. + +#define MSB(u16) (((U8 *)&(u16))[1]) //!< Most significant byte of \a u16. +#define LSB(u16) (((U8 *)&(u16))[0]) //!< Least significant byte of \a u16. + +#define MSH(u32) (((U16 *)&(u32))[1]) //!< Most significant half-word of \a u32. +#define LSH(u32) (((U16 *)&(u32))[0]) //!< Least significant half-word of \a u32. +#define MSB0W(u32) (((U8 *)&(u32))[3]) //!< Most significant byte of 1st rank of \a u32. +#define MSB1W(u32) (((U8 *)&(u32))[2]) //!< Most significant byte of 2nd rank of \a u32. +#define MSB2W(u32) (((U8 *)&(u32))[1]) //!< Most significant byte of 3rd rank of \a u32. +#define MSB3W(u32) (((U8 *)&(u32))[0]) //!< Most significant byte of 4th rank of \a u32. +#define LSB3W(u32) MSB0W(u32) //!< Least significant byte of 4th rank of \a u32. +#define LSB2W(u32) MSB1W(u32) //!< Least significant byte of 3rd rank of \a u32. +#define LSB1W(u32) MSB2W(u32) //!< Least significant byte of 2nd rank of \a u32. +#define LSB0W(u32) MSB3W(u32) //!< Least significant byte of 1st rank of \a u32. + +#define MSW(u64) (((U32 *)&(u64))[1]) //!< Most significant word of \a u64. +#define LSW(u64) (((U32 *)&(u64))[0]) //!< Least significant word of \a u64. +#define MSH0(u64) (((U16 *)&(u64))[3]) //!< Most significant half-word of 1st rank of \a u64. +#define MSH1(u64) (((U16 *)&(u64))[2]) //!< Most significant half-word of 2nd rank of \a u64. +#define MSH2(u64) (((U16 *)&(u64))[1]) //!< Most significant half-word of 3rd rank of \a u64. +#define MSH3(u64) (((U16 *)&(u64))[0]) //!< Most significant half-word of 4th rank of \a u64. +#define LSH3(u64) MSH0(u64) //!< Least significant half-word of 4th rank of \a u64. +#define LSH2(u64) MSH1(u64) //!< Least significant half-word of 3rd rank of \a u64. +#define LSH1(u64) MSH2(u64) //!< Least significant half-word of 2nd rank of \a u64. +#define LSH0(u64) MSH3(u64) //!< Least significant half-word of 1st rank of \a u64. +#define MSB0D(u64) (((U8 *)&(u64))[7]) //!< Most significant byte of 1st rank of \a u64. +#define MSB1D(u64) (((U8 *)&(u64))[6]) //!< Most significant byte of 2nd rank of \a u64. +#define MSB2D(u64) (((U8 *)&(u64))[5]) //!< Most significant byte of 3rd rank of \a u64. +#define MSB3D(u64) (((U8 *)&(u64))[4]) //!< Most significant byte of 4th rank of \a u64. +#define MSB4D(u64) (((U8 *)&(u64))[3]) //!< Most significant byte of 5th rank of \a u64. +#define MSB5D(u64) (((U8 *)&(u64))[2]) //!< Most significant byte of 6th rank of \a u64. +#define MSB6D(u64) (((U8 *)&(u64))[1]) //!< Most significant byte of 7th rank of \a u64. +#define MSB7D(u64) (((U8 *)&(u64))[0]) //!< Most significant byte of 8th rank of \a u64. +#define LSB7D(u64) MSB0D(u64) //!< Least significant byte of 8th rank of \a u64. +#define LSB6D(u64) MSB1D(u64) //!< Least significant byte of 7th rank of \a u64. +#define LSB5D(u64) MSB2D(u64) //!< Least significant byte of 6th rank of \a u64. +#define LSB4D(u64) MSB3D(u64) //!< Least significant byte of 5th rank of \a u64. +#define LSB3D(u64) MSB4D(u64) //!< Least significant byte of 4th rank of \a u64. +#define LSB2D(u64) MSB5D(u64) //!< Least significant byte of 3rd rank of \a u64. +#define LSB1D(u64) MSB6D(u64) //!< Least significant byte of 2nd rank of \a u64. +#define LSB0D(u64) MSB7D(u64) //!< Least significant byte of 1st rank of \a u64. + +#define LSB0(u32) LSB0W(u32) //!< Least significant byte of 1st rank of \a u32. +#define LSB1(u32) LSB1W(u32) //!< Least significant byte of 2nd rank of \a u32. +#define LSB2(u32) LSB2W(u32) //!< Least significant byte of 3rd rank of \a u32. +#define LSB3(u32) LSB3W(u32) //!< Least significant byte of 4th rank of \a u32. +#define MSB3(u32) MSB3W(u32) //!< Most significant byte of 4th rank of \a u32. +#define MSB2(u32) MSB2W(u32) //!< Most significant byte of 3rd rank of \a u32. +#define MSB1(u32) MSB1W(u32) //!< Most significant byte of 2nd rank of \a u32. +#define MSB0(u32) MSB0W(u32) //!< Most significant byte of 1st rank of \a u32. + +#if defined(__ICCARM__) +#define SHORTENUM __packed +#elif defined(__GNUC__) +#define SHORTENUM __attribute__((packed)) +#endif + +/* No operation */ +#if defined(__ICCARM__) +#define nop() __no_operation() +#elif defined(__GNUC__) +#define nop() (__NOP()) +#endif + +#define FLASH_DECLARE(x) const x +#define FLASH_EXTERN(x) extern const x +#define PGM_READ_BYTE(x) *(x) +#define PGM_READ_WORD(x) *(x) +#define MEMCPY_ENDIAN memcpy +#define PGM_READ_BLOCK(dst, src, len) memcpy((dst), (src), (len)) + +/*Defines the Flash Storage for the request and response of MAC*/ +#define CMD_ID_OCTET (0) + +/* Converting of values from CPU endian to little endian. */ +#define CPU_ENDIAN_TO_LE16(x) (x) +#define CPU_ENDIAN_TO_LE32(x) (x) +#define CPU_ENDIAN_TO_LE64(x) (x) + +/* Converting of values from little endian to CPU endian. */ +#define LE16_TO_CPU_ENDIAN(x) (x) +#define LE32_TO_CPU_ENDIAN(x) (x) +#define LE64_TO_CPU_ENDIAN(x) (x) + +/* Converting of constants from little endian to CPU endian. */ +#define CLE16_TO_CPU_ENDIAN(x) (x) +#define CLE32_TO_CPU_ENDIAN(x) (x) +#define CLE64_TO_CPU_ENDIAN(x) (x) + +/* Converting of constants from CPU endian to little endian. */ +#define CCPU_ENDIAN_TO_LE16(x) (x) +#define CCPU_ENDIAN_TO_LE32(x) (x) +#define CCPU_ENDIAN_TO_LE64(x) (x) + +#define ADDR_COPY_DST_SRC_16(dst, src) ((dst) = (src)) +#define ADDR_COPY_DST_SRC_64(dst, src) ((dst) = (src)) + +/** + * @brief Converts a 64-Bit value into a 8 Byte array + * + * @param[in] value 64-Bit value + * @param[out] data Pointer to the 8 Byte array to be updated with 64-Bit value + * @ingroup apiPalApi + */ +static inline void convert_64_bit_to_byte_array(uint64_t value, uint8_t *data) +{ + uint8_t index = 0; + + while (index < 8) + { + data[index++] = value & 0xFF; + value = value >> 8; + } +} + +/** + * @brief Converts a 16-Bit value into a 2 Byte array + * + * @param[in] value 16-Bit value + * @param[out] data Pointer to the 2 Byte array to be updated with 16-Bit value + * @ingroup apiPalApi + */ +static inline void convert_16_bit_to_byte_array(uint16_t value, uint8_t *data) +{ + data[0] = value & 0xFF; + data[1] = (value >> 8) & 0xFF; +} + +/* Converts a 16-Bit value into a 2 Byte array */ +static inline void convert_spec_16_bit_to_byte_array(uint16_t value, uint8_t *data) +{ + data[0] = value & 0xFF; + data[1] = (value >> 8) & 0xFF; +} + +/* Converts a 16-Bit value into a 2 Byte array */ +static inline void convert_16_bit_to_byte_address(uint16_t value, uint8_t *data) +{ + data[0] = value & 0xFF; + data[1] = (value >> 8) & 0xFF; +} + +/* + * @brief Converts a 2 Byte array into a 16-Bit value + * + * @param data Specifies the pointer to the 2 Byte array + * + * @return 16-Bit value + * @ingroup apiPalApi + */ +static inline uint16_t convert_byte_array_to_16_bit(uint8_t *data) +{ + return (data[0] | ((uint16_t)data[1] << 8)); +} + +/* Converts a 4 Byte array into a 32-Bit value */ +static inline uint32_t convert_byte_array_to_32_bit(uint8_t *data) +{ + union + { + uint32_t u32; + uint8_t u8[4]; + }long_addr; + uint8_t index; + for (index = 0; index < 4; index++) + { + long_addr.u8[index] = *data++; + } + return long_addr.u32; +} + +/** + * @brief Converts a 8 Byte array into a 64-Bit value + * + * @param data Specifies the pointer to the 8 Byte array + * + * @return 64-Bit value + * @ingroup apiPalApi + */ +static inline uint64_t convert_byte_array_to_64_bit(uint8_t *data) +{ + union + { + uint64_t u64; + uint8_t u8[8]; + } long_addr; + + uint8_t index; + + for (index = 0; index < 8; index++) + { + long_addr.u8[index] = *data++; + } + + return long_addr.u64; +} + +/** @} */ + +#endif /* UTILS_COMPILER_H_INCLUDED */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/header_files/io.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/header_files/io.h new file mode 100755 index 0000000..6f2b569 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/header_files/io.h @@ -0,0 +1,74 @@ +/** + * \file + * + * \brief Arch file for SAM0. + * + * This file defines common SAM0 series. + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _SAM_IO_ +#define _SAM_IO_ + +#include +#include +#include + +/* SAM D20 family */ +#if (SAMD20) +# include "samd20.h" +#endif + +#if (SAMD21) +# include "samd21.h" +#endif + +#if (SAMR21) +# include "samr21.h" +#endif + +#if (SAMD10) +# include "samd10.h" +#endif + +#if (SAMD11) +# include "samd11.h" +#endif + +#endif /* _SAM_IO_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/linker_scripts/samd21/gcc/samd21j18a_flash.ld b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/linker_scripts/samd21/gcc/samd21j18a_flash.ld new file mode 100755 index 0000000..d59417d --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/linker_scripts/samd21/gcc/samd21j18a_flash.ld @@ -0,0 +1,157 @@ +/** + * \file + * + * \brief Linker script for running in internal FLASH on the SAMD21J18A + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + + +OUTPUT_FORMAT("elf32-littlearm", "elf32-littlearm", "elf32-littlearm") +OUTPUT_ARCH(arm) +SEARCH_DIR(.) + +/* Memory Spaces Definitions */ +MEMORY +{ + rom (rx) : ORIGIN = 0x00000000, LENGTH = 0x00040000 + ram (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* The stack size used by the application. NOTE: you need to adjust according to your application. */ +STACK_SIZE = DEFINED(STACK_SIZE) ? STACK_SIZE : DEFINED(__stack_size__) ? __stack_size__ : 0x2000; + +/* Section Definitions */ +SECTIONS +{ + .text : + { + . = ALIGN(4); + _sfixed = .; + KEEP(*(.vectors .vectors.*)) + *(.text .text.* .gnu.linkonce.t.*) + *(.glue_7t) *(.glue_7) + *(.rodata .rodata* .gnu.linkonce.r.*) + *(.ARM.extab* .gnu.linkonce.armextab.*) + + /* Support C constructors, and C destructors in both user code + and the C library. This also provides support for C++ code. */ + . = ALIGN(4); + KEEP(*(.init)) + . = ALIGN(4); + __preinit_array_start = .; + KEEP (*(.preinit_array)) + __preinit_array_end = .; + + . = ALIGN(4); + __init_array_start = .; + KEEP (*(SORT(.init_array.*))) + KEEP (*(.init_array)) + __init_array_end = .; + + . = ALIGN(4); + KEEP (*crtbegin.o(.ctors)) + KEEP (*(EXCLUDE_FILE (*crtend.o) .ctors)) + KEEP (*(SORT(.ctors.*))) + KEEP (*crtend.o(.ctors)) + + . = ALIGN(4); + KEEP(*(.fini)) + + . = ALIGN(4); + __fini_array_start = .; + KEEP (*(.fini_array)) + KEEP (*(SORT(.fini_array.*))) + __fini_array_end = .; + + KEEP (*crtbegin.o(.dtors)) + KEEP (*(EXCLUDE_FILE (*crtend.o) .dtors)) + KEEP (*(SORT(.dtors.*))) + KEEP (*crtend.o(.dtors)) + + . = ALIGN(4); + _efixed = .; /* End of text section */ + } > rom + + /* .ARM.exidx is sorted, so has to go in its own output section. */ + PROVIDE_HIDDEN (__exidx_start = .); + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > rom + PROVIDE_HIDDEN (__exidx_end = .); + + . = ALIGN(4); + _etext = .; + + .relocate : AT (_etext) + { + . = ALIGN(4); + _srelocate = .; + *(.ramfunc .ramfunc.*); + *(.data .data.*); + . = ALIGN(4); + _erelocate = .; + } > ram + + /* .bss section which is used for uninitialized data */ + .bss (NOLOAD) : + { + . = ALIGN(4); + _sbss = . ; + _szero = .; + *(.bss .bss.*) + *(COMMON) + . = ALIGN(4); + _ebss = . ; + _ezero = .; + } > ram + + /* stack section */ + .stack (NOLOAD): + { + . = ALIGN(8); + _sstack = .; + . = . + STACK_SIZE; + . = ALIGN(8); + _estack = .; + } > ram + + . = ALIGN(4); + _end = . ; +} diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/make/Makefile.sam.in b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/make/Makefile.sam.in new file mode 100755 index 0000000..d07e471 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/make/Makefile.sam.in @@ -0,0 +1,502 @@ +# List of available make goals: +# +# all Default target, builds the project +# clean Clean up the project +# rebuild Rebuild the project +# debug_flash Builds the project and debug in flash +# debug_sram Builds the project and debug in sram +# +# doc Build the documentation +# cleandoc Clean up the documentation +# rebuilddoc Rebuild the documentation +# +# \file +# +# Copyright (c) 2011 - 2014 Atmel Corporation. All rights reserved. +# +# \asf_license_start +# +# \page License +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# 1. Redistributions of source code must retain the above copyright notice, +# this list of conditions and the following disclaimer. +# +# 2. Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# 3. The name of Atmel may not be used to endorse or promote products derived +# from this software without specific prior written permission. +# +# 4. This software may only be redistributed and used in connection with an +# Atmel microcontroller product. +# +# THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED +# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE +# EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. +# +# \asf_license_stop +# + +# Include the config.mk file from the current working path, e.g., where the +# user called make. +include config.mk + +# Tool to use to generate documentation from the source code +DOCGEN ?= doxygen + +# Look for source files relative to the top-level source directory +VPATH := $(PRJ_PATH) + +# Output target file +project_type := $(PROJECT_TYPE) + +# Output target file +ifeq ($(project_type),flash) +target := $(TARGET_FLASH) +linker_script := $(PRJ_PATH)/$(LINKER_SCRIPT_FLASH) +debug_script := $(PRJ_PATH)/$(DEBUG_SCRIPT_FLASH) +else +target := $(TARGET_SRAM) +linker_script := $(PRJ_PATH)/$(LINKER_SCRIPT_SRAM) +debug_script := $(PRJ_PATH)/$(DEBUG_SCRIPT_SRAM) +endif + +# Output project name (target name minus suffix) +project := $(basename $(target)) + +# Output target file (typically ELF or static library) +ifeq ($(suffix $(target)),.a) +target_type := lib +else +ifeq ($(suffix $(target)),.elf) +target_type := elf +else +$(error "Target type $(target_type) is not supported") +endif +endif + +# Allow override of operating system detection. The user can add OS=Linux or +# OS=Windows on the command line to explicit set the host OS. +# +# This allows to work around broken uname utility on certain systems. +ifdef OS + ifeq ($(strip $(OS)), Linux) + os_type := Linux + endif + ifeq ($(strip $(OS)), Windows) + os_type := windows32_64 + endif +endif + +os_type ?= $(strip $(shell uname)) + +ifeq ($(os_type),windows32) +os := Windows +else +ifeq ($(os_type),windows64) +os := Windows +else +ifeq ($(os_type),windows32_64) +os ?= Windows +else +ifeq ($(os_type),) +os := Windows +else +# Default to Linux style operating system. Both Cygwin and mingw are fully +# compatible (for this Makefile) with Linux. +os := Linux +endif +endif +endif +endif + +# Output documentation directory and configuration file. +docdir := ../doxygen/html +doccfg := ../doxygen/doxyfile.doxygen + +CROSS ?= arm-none-eabi- +AR := $(CROSS)ar +AS := $(CROSS)as +CC := $(CROSS)gcc +CPP := $(CROSS)gcc -E +CXX := $(CROSS)g++ +LD := $(CROSS)g++ +NM := $(CROSS)nm +OBJCOPY := $(CROSS)objcopy +OBJDUMP := $(CROSS)objdump +SIZE := $(CROSS)size +GDB := $(CROSS)gdb + +RM := rm +ifeq ($(os),Windows) +RMDIR := rmdir /S /Q +else +RMDIR := rmdir -p --ignore-fail-on-non-empty +endif + +# On Windows, we need to override the shell to force the use of cmd.exe +ifeq ($(os),Windows) +SHELL := cmd +endif + +# Strings for beautifying output +MSG_CLEAN_FILES = "RM *.o *.d" +MSG_CLEAN_DIRS = "RMDIR $(strip $(clean-dirs))" +MSG_CLEAN_DOC = "RMDIR $(docdir)" +MSG_MKDIR = "MKDIR $(dir $@)" + +MSG_INFO = "INFO " +MSG_PREBUILD = "PREBUILD $(PREBUILD_CMD)" +MSG_POSTBUILD = "POSTBUILD $(POSTBUILD_CMD)" + +MSG_ARCHIVING = "AR $@" +MSG_ASSEMBLING = "AS $@" +MSG_BINARY_IMAGE = "OBJCOPY $@" +MSG_COMPILING = "CC $@" +MSG_COMPILING_CXX = "CXX $@" +MSG_EXTENDED_LISTING = "OBJDUMP $@" +MSG_IHEX_IMAGE = "OBJCOPY $@" +MSG_LINKING = "LN $@" +MSG_PREPROCESSING = "CPP $@" +MSG_SIZE = "SIZE $@" +MSG_SYMBOL_TABLE = "NM $@" + +MSG_GENERATING_DOC = "DOXYGEN $(docdir)" + +# Don't use make's built-in rules and variables +MAKEFLAGS += -rR + +# Don't print 'Entering directory ...' +MAKEFLAGS += --no-print-directory + +# Function for reversing the order of a list +reverse = $(if $(1),$(call reverse,$(wordlist 2,$(words $(1)),$(1)))) $(firstword $(1)) + +# Hide command output by default, but allow the user to override this +# by adding V=1 on the command line. +# +# This is inspired by the Kbuild system used by the Linux kernel. +ifdef V + ifeq ("$(origin V)", "command line") + VERBOSE = $(V) + endif +endif +ifndef VERBOSE + VERBOSE = 0 +endif + +ifeq ($(VERBOSE), 1) + Q = +else + Q = @ +endif + +arflags-gnu-y := $(ARFLAGS) +asflags-gnu-y := $(ASFLAGS) +cflags-gnu-y := $(CFLAGS) +cxxflags-gnu-y := $(CXXFLAGS) +cppflags-gnu-y := $(CPPFLAGS) +cpuflags-gnu-y := +dbgflags-gnu-y := $(DBGFLAGS) +libflags-gnu-y := $(foreach LIB,$(LIBS),-l$(LIB)) +ldflags-gnu-y := $(LDFLAGS) +flashflags-gnu-y := +clean-files := +clean-dirs := + +clean-files += $(wildcard $(target) $(project).map) +clean-files += $(wildcard $(project).hex $(project).bin) +clean-files += $(wildcard $(project).lss $(project).sym) +clean-files += $(wildcard $(build)) + +# Use pipes instead of temporary files for communication between processes +cflags-gnu-y += -pipe +asflags-gnu-y += -pipe +ldflags-gnu-y += -pipe + +# Archiver flags. +arflags-gnu-y += rcs + +# Always enable warnings. And be very careful about implicit +# declarations. +cflags-gnu-y += -Wall -Wstrict-prototypes -Wmissing-prototypes +cflags-gnu-y += -Werror-implicit-function-declaration +cxxflags-gnu-y += -Wall +# IAR doesn't allow arithmetic on void pointers, so warn about that. +cflags-gnu-y += -Wpointer-arith +cxxflags-gnu-y += -Wpointer-arith + +# Preprocessor flags. +cppflags-gnu-y += $(foreach INC,$(addprefix $(PRJ_PATH)/,$(INC_PATH)),-I$(INC)) +asflags-gnu-y += $(foreach INC,$(addprefix $(PRJ_PATH)/,$(INC_PATH)),'-Wa,-I$(INC)') + +# CPU specific flags. +cpuflags-gnu-y += -mcpu=$(ARCH) -mthumb -D=__$(PART)__ + +# Dependency file flags. +depflags = -MD -MP -MQ $@ + +# Debug specific flags. +ifdef BUILD_DEBUG_LEVEL +dbgflags-gnu-y += -g$(BUILD_DEBUG_LEVEL) +else +dbgflags-gnu-y += -g3 +endif + +# Optimization specific flags. +ifdef BUILD_OPTIMIZATION +optflags-gnu-y = -O$(BUILD_OPTIMIZATION) +else +optflags-gnu-y = $(OPTIMIZATION) +endif + +# Always preprocess assembler files. +asflags-gnu-y += -x assembler-with-cpp +# Compile C files using the GNU99 standard. +cflags-gnu-y += -std=gnu99 +# Compile C++ files using the GNU++98 standard. +cxxflags-gnu-y += -std=gnu++98 + +# Don't use strict aliasing (very common in embedded applications). +cflags-gnu-y += -fno-strict-aliasing +cxxflags-gnu-y += -fno-strict-aliasing + +# Separate each function and data into its own separate section to allow +# garbage collection of unused sections. +cflags-gnu-y += -ffunction-sections -fdata-sections +cxxflags-gnu-y += -ffunction-sections -fdata-sections + +# Various cflags. +cflags-gnu-y += -Wchar-subscripts -Wcomment -Wformat=2 -Wimplicit-int +cflags-gnu-y += -Wmain -Wparentheses +cflags-gnu-y += -Wsequence-point -Wreturn-type -Wswitch -Wtrigraphs -Wunused +cflags-gnu-y += -Wuninitialized -Wunknown-pragmas -Wfloat-equal -Wundef +cflags-gnu-y += -Wshadow -Wbad-function-cast -Wwrite-strings +cflags-gnu-y += -Wsign-compare -Waggregate-return +cflags-gnu-y += -Wmissing-declarations +cflags-gnu-y += -Wformat -Wmissing-format-attribute -Wno-deprecated-declarations +cflags-gnu-y += -Wpacked -Wredundant-decls -Wnested-externs -Wlong-long +cflags-gnu-y += -Wunreachable-code +cflags-gnu-y += -Wcast-align +cflags-gnu-y += --param max-inline-insns-single=500 + +# To reduce application size use only integer printf function. +cflags-gnu-y += -Dprintf=iprintf + +# Use newlib-nano to reduce application size +ldflags-gnu-y += --specs=nano.specs + +# Garbage collect unreferred sections when linking. +ldflags-gnu-y += -Wl,--gc-sections + +# Use the linker script if provided by the project. +ifneq ($(strip $(linker_script)),) +ldflags-gnu-y += -Wl,-T $(linker_script) +endif + +# Output a link map file and a cross reference table +ldflags-gnu-y += -Wl,-Map=$(project).map,--cref + +# Add library search paths relative to the top level directory. +ldflags-gnu-y += $(foreach _LIB_PATH,$(addprefix $(PRJ_PATH)/,$(LIB_PATH)),-L$(_LIB_PATH)) + +a_flags = $(cpuflags-gnu-y) $(depflags) $(cppflags-gnu-y) $(asflags-gnu-y) -D__ASSEMBLY__ +c_flags = $(cpuflags-gnu-y) $(dbgflags-gnu-y) $(depflags) $(optflags-gnu-y) $(cppflags-gnu-y) $(cflags-gnu-y) +cxx_flags= $(cpuflags-gnu-y) $(dbgflags-gnu-y) $(depflags) $(optflags-gnu-y) $(cppflags-gnu-y) $(cxxflags-gnu-y) +l_flags = -Wl,--entry=Reset_Handler -Wl,--cref $(cpuflags-gnu-y) $(optflags-gnu-y) $(ldflags-gnu-y) +ar_flags = $(arflags-gnu-y) + +# Source files list and part informations must already be included before +# running this makefile + +# If a custom build directory is specified, use it -- force trailing / in directory name. +ifdef BUILD_DIR + build-dir := $(dir $(BUILD_DIR))$(if $(notdir $(BUILD_DIR)),$(notdir $(BUILD_DIR))/) +else + build-dir = +endif + +# Create object files list from source files list. +obj-y := $(addprefix $(build-dir), $(addsuffix .o,$(basename $(CSRCS) $(ASSRCS)))) +# Create dependency files list from source files list. +dep-files := $(wildcard $(foreach f,$(obj-y),$(basename $(f)).d)) + +clean-files += $(wildcard $(obj-y)) +clean-files += $(dep-files) + +clean-dirs += $(call reverse,$(sort $(wildcard $(dir $(obj-y))))) + +# Default target. +.PHONY: all +ifeq ($(project_type),all) +all: + $(MAKE) all PROJECT_TYPE=flash + $(MAKE) all PROJECT_TYPE=sram +else +ifeq ($(target_type),lib) +all: $(target) $(project).lss $(project).sym +else +ifeq ($(target_type),elf) +all: prebuild $(target) $(project).lss $(project).sym $(project).hex $(project).bin postbuild +endif +endif +endif + +prebuild: +ifneq ($(strip $(PREBUILD_CMD)),) + @echo $(MSG_PREBUILD) + $(Q)$(PREBUILD_CMD) +endif + +postbuild: +ifneq ($(strip $(POSTBUILD_CMD)),) + @echo $(MSG_POSTBUILD) + $(Q)$(POSTBUILD_CMD) +endif + +# Clean up the project. +.PHONY: clean +clean: + @$(if $(strip $(clean-files)),echo $(MSG_CLEAN_FILES)) + $(if $(strip $(clean-files)),$(Q)$(RM) $(clean-files),) + @$(if $(strip $(clean-dirs)),echo $(MSG_CLEAN_DIRS)) +# Remove created directories, and make sure we only remove existing +# directories, since recursive rmdir might help us a bit on the way. +ifeq ($(os),Windows) + $(Q)$(if $(strip $(clean-dirs)), \ + $(RMDIR) $(strip $(subst /,\,$(clean-dirs)))) +else + $(Q)$(if $(strip $(clean-dirs)), \ + for directory in $(strip $(clean-dirs)); do \ + if [ -d "$$directory" ]; then \ + $(RMDIR) $$directory; \ + fi \ + done \ + ) +endif + +# Rebuild the project. +.PHONY: rebuild +rebuild: clean all + +# Debug the project in flash. +.PHONY: debug_flash +debug_flash: all + $(GDB) -x "$(PRJ_PATH)/$(DEBUG_SCRIPT_FLASH)" -ex "reset" -readnow -se $(TARGET_FLASH) + +# Debug the project in sram. +.PHONY: debug_sram +debug_sram: all + $(GDB) -x "$(PRJ_PATH)/$(DEBUG_SCRIPT_SRAM)" -ex "reset" -readnow -se $(TARGET_SRAM) + +.PHONY: objfiles +objfiles: $(obj-y) + +# Create object files from C source files. +$(build-dir)%.o: %.c $(MAKEFILE_PATH) config.mk + $(Q)test -d $(dir $@) || echo $(MSG_MKDIR) +ifeq ($(os),Windows) + $(Q)test -d $(patsubst %/,%,$(dir $@)) || mkdir $(subst /,\,$(dir $@)) +else + $(Q)test -d $(dir $@) || mkdir -p $(dir $@) +endif + @echo $(MSG_COMPILING) + $(Q)$(CC) $(c_flags) -c $< -o $@ + +# Create object files from C++ source files. +$(build-dir)%.o: %.cpp $(MAKEFILE_PATH) config.mk + $(Q)test -d $(dir $@) || echo $(MSG_MKDIR) +ifeq ($(os),Windows) + $(Q)test -d $(patsubst %/,%,$(dir $@)) || mkdir $(subst /,\,$(dir $@)) +else + $(Q)test -d $(dir $@) || mkdir -p $(dir $@) +endif + @echo $(MSG_COMPILING_CXX) + $(Q)$(CXX) $(cxx_flags) -c $< -o $@ + +# Preprocess and assemble: create object files from assembler source files. +$(build-dir)%.o: %.S $(MAKEFILE_PATH) config.mk + $(Q)test -d $(dir $@) || echo $(MSG_MKDIR) +ifeq ($(os),Windows) + $(Q)test -d $(patsubst %/,%,$(dir $@)) || mkdir $(subst /,\,$(dir $@)) +else + $(Q)test -d $(dir $@) || mkdir -p $(dir $@) +endif + @echo $(MSG_ASSEMBLING) + $(Q)$(CC) $(a_flags) -c $< -o $@ + +# Include all dependency files to add depedency to all header files in use. +include $(dep-files) + +ifeq ($(target_type),lib) +# Archive object files into an archive +$(target): $(MAKEFILE_PATH) config.mk $(obj-y) + @echo $(MSG_ARCHIVING) + $(Q)$(AR) $(ar_flags) $@ $(obj-y) + @echo $(MSG_SIZE) + $(Q)$(SIZE) -Bxt $@ +else +ifeq ($(target_type),elf) +# Link the object files into an ELF file. Also make sure the target is rebuilt +# if the common Makefile.sam.in or project config.mk is changed. +$(target): $(linker_script) $(MAKEFILE_PATH) config.mk $(obj-y) + @echo $(MSG_LINKING) + $(Q)$(LD) $(l_flags) $(obj-y) $(libflags-gnu-y) -o $@ + @echo $(MSG_SIZE) + $(Q)$(SIZE) -Ax $@ + $(Q)$(SIZE) -Bx $@ +endif +endif + +# Create extended function listing from target output file. +%.lss: $(target) + @echo $(MSG_EXTENDED_LISTING) + $(Q)$(OBJDUMP) -h -S $< > $@ + +# Create symbol table from target output file. +%.sym: $(target) + @echo $(MSG_SYMBOL_TABLE) + $(Q)$(NM) -n $< > $@ + +# Create Intel HEX image from ELF output file. +%.hex: $(target) + @echo $(MSG_IHEX_IMAGE) + $(Q)$(OBJCOPY) -O ihex $(flashflags-gnu-y) $< $@ + +# Create binary image from ELF output file. +%.bin: $(target) + @echo $(MSG_BINARY_IMAGE) + $(Q)$(OBJCOPY) -O binary $< $@ + +# Provide information about the detected host operating system. +.SECONDARY: info-os +info-os: + @echo $(MSG_INFO)$(os) build host detected + +# Build Doxygen generated documentation. +.PHONY: doc +doc: + @echo $(MSG_GENERATING_DOC) + $(Q)cd $(dir $(doccfg)) && $(DOCGEN) $(notdir $(doccfg)) + +# Clean Doxygen generated documentation. +.PHONY: cleandoc +cleandoc: + @$(if $(wildcard $(docdir)),echo $(MSG_CLEAN_DOC)) + $(Q)$(if $(wildcard $(docdir)),$(RM) --recursive $(docdir)) + +# Rebuild the Doxygen generated documentation. +.PHONY: rebuilddoc +rebuilddoc: cleandoc doc diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/preprocessor/mrecursion.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/preprocessor/mrecursion.h new file mode 100755 index 0000000..a05f8fa --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/preprocessor/mrecursion.h @@ -0,0 +1,595 @@ +/** + * \file + * + * \brief Preprocessor macro recursion utils. + * + * Copyright (C) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _MRECURSION_H_ +#define _MRECURSION_H_ + +/** + * \defgroup group_sam0_utils_mrecursion Preprocessor - Macro Recursion + * + * \ingroup group_sam0_utils + * + * @{ + */ + +#include "preprocessor.h" + +#define DEC_256 255 +#define DEC_255 254 +#define DEC_254 253 +#define DEC_253 252 +#define DEC_252 251 +#define DEC_251 250 +#define DEC_250 249 +#define DEC_249 248 +#define DEC_248 247 +#define DEC_247 246 +#define DEC_246 245 +#define DEC_245 244 +#define DEC_244 243 +#define DEC_243 242 +#define DEC_242 241 +#define DEC_241 240 +#define DEC_240 239 +#define DEC_239 238 +#define DEC_238 237 +#define DEC_237 236 +#define DEC_236 235 +#define DEC_235 234 +#define DEC_234 233 +#define DEC_233 232 +#define DEC_232 231 +#define DEC_231 230 +#define DEC_230 229 +#define DEC_229 228 +#define DEC_228 227 +#define DEC_227 226 +#define DEC_226 225 +#define DEC_225 224 +#define DEC_224 223 +#define DEC_223 222 +#define DEC_222 221 +#define DEC_221 220 +#define DEC_220 219 +#define DEC_219 218 +#define DEC_218 217 +#define DEC_217 216 +#define DEC_216 215 +#define DEC_215 214 +#define DEC_214 213 +#define DEC_213 212 +#define DEC_212 211 +#define DEC_211 210 +#define DEC_210 209 +#define DEC_209 208 +#define DEC_208 207 +#define DEC_207 206 +#define DEC_206 205 +#define DEC_205 204 +#define DEC_204 203 +#define DEC_203 202 +#define DEC_202 201 +#define DEC_201 200 +#define DEC_200 199 +#define DEC_199 198 +#define DEC_198 197 +#define DEC_197 196 +#define DEC_196 195 +#define DEC_195 194 +#define DEC_194 193 +#define DEC_193 192 +#define DEC_192 191 +#define DEC_191 190 +#define DEC_190 189 +#define DEC_189 188 +#define DEC_188 187 +#define DEC_187 186 +#define DEC_186 185 +#define DEC_185 184 +#define DEC_184 183 +#define DEC_183 182 +#define DEC_182 181 +#define DEC_181 180 +#define DEC_180 179 +#define DEC_179 178 +#define DEC_178 177 +#define DEC_177 176 +#define DEC_176 175 +#define DEC_175 174 +#define DEC_174 173 +#define DEC_173 172 +#define DEC_172 171 +#define DEC_171 170 +#define DEC_170 169 +#define DEC_169 168 +#define DEC_168 167 +#define DEC_167 166 +#define DEC_166 165 +#define DEC_165 164 +#define DEC_164 163 +#define DEC_163 162 +#define DEC_162 161 +#define DEC_161 160 +#define DEC_160 159 +#define DEC_159 158 +#define DEC_158 157 +#define DEC_157 156 +#define DEC_156 155 +#define DEC_155 154 +#define DEC_154 153 +#define DEC_153 152 +#define DEC_152 151 +#define DEC_151 150 +#define DEC_150 149 +#define DEC_149 148 +#define DEC_148 147 +#define DEC_147 146 +#define DEC_146 145 +#define DEC_145 144 +#define DEC_144 143 +#define DEC_143 142 +#define DEC_142 141 +#define DEC_141 140 +#define DEC_140 139 +#define DEC_139 138 +#define DEC_138 137 +#define DEC_137 136 +#define DEC_136 135 +#define DEC_135 134 +#define DEC_134 133 +#define DEC_133 132 +#define DEC_132 131 +#define DEC_131 130 +#define DEC_130 129 +#define DEC_129 128 +#define DEC_128 127 +#define DEC_127 126 +#define DEC_126 125 +#define DEC_125 124 +#define DEC_124 123 +#define DEC_123 122 +#define DEC_122 121 +#define DEC_121 120 +#define DEC_120 119 +#define DEC_119 118 +#define DEC_118 117 +#define DEC_117 116 +#define DEC_116 115 +#define DEC_115 114 +#define DEC_114 113 +#define DEC_113 112 +#define DEC_112 111 +#define DEC_111 110 +#define DEC_110 109 +#define DEC_109 108 +#define DEC_108 107 +#define DEC_107 106 +#define DEC_106 105 +#define DEC_105 104 +#define DEC_104 103 +#define DEC_103 102 +#define DEC_102 101 +#define DEC_101 100 +#define DEC_100 99 +#define DEC_99 98 +#define DEC_98 97 +#define DEC_97 96 +#define DEC_96 95 +#define DEC_95 94 +#define DEC_94 93 +#define DEC_93 92 +#define DEC_92 91 +#define DEC_91 90 +#define DEC_90 89 +#define DEC_89 88 +#define DEC_88 87 +#define DEC_87 86 +#define DEC_86 85 +#define DEC_85 84 +#define DEC_84 83 +#define DEC_83 82 +#define DEC_82 81 +#define DEC_81 80 +#define DEC_80 79 +#define DEC_79 78 +#define DEC_78 77 +#define DEC_77 76 +#define DEC_76 75 +#define DEC_75 74 +#define DEC_74 73 +#define DEC_73 72 +#define DEC_72 71 +#define DEC_71 70 +#define DEC_70 69 +#define DEC_69 68 +#define DEC_68 67 +#define DEC_67 66 +#define DEC_66 65 +#define DEC_65 64 +#define DEC_64 63 +#define DEC_63 62 +#define DEC_62 61 +#define DEC_61 60 +#define DEC_60 59 +#define DEC_59 58 +#define DEC_58 57 +#define DEC_57 56 +#define DEC_56 55 +#define DEC_55 54 +#define DEC_54 53 +#define DEC_53 52 +#define DEC_52 51 +#define DEC_51 50 +#define DEC_50 49 +#define DEC_49 48 +#define DEC_48 47 +#define DEC_47 46 +#define DEC_46 45 +#define DEC_45 44 +#define DEC_44 43 +#define DEC_43 42 +#define DEC_42 41 +#define DEC_41 40 +#define DEC_40 39 +#define DEC_39 38 +#define DEC_38 37 +#define DEC_37 36 +#define DEC_36 35 +#define DEC_35 34 +#define DEC_34 33 +#define DEC_33 32 +#define DEC_32 31 +#define DEC_31 30 +#define DEC_30 29 +#define DEC_29 28 +#define DEC_28 27 +#define DEC_27 26 +#define DEC_26 25 +#define DEC_25 24 +#define DEC_24 23 +#define DEC_23 22 +#define DEC_22 21 +#define DEC_21 20 +#define DEC_20 19 +#define DEC_19 18 +#define DEC_18 17 +#define DEC_17 16 +#define DEC_16 15 +#define DEC_15 14 +#define DEC_14 13 +#define DEC_13 12 +#define DEC_12 11 +#define DEC_11 10 +#define DEC_10 9 +#define DEC_9 8 +#define DEC_8 7 +#define DEC_7 6 +#define DEC_6 5 +#define DEC_5 4 +#define DEC_4 3 +#define DEC_3 2 +#define DEC_2 1 +#define DEC_1 0 +#define DEC_(n) DEC_##n + + +/** Maximal number of repetitions supported by MRECURSION. */ +#define MRECURSION_LIMIT 256 + +/** \brief Macro recursion. + * + * This macro represents a horizontal repetition construct. + * + * \param[in] count The number of repetitious calls to macro. Valid values + * range from 0 to MRECURSION_LIMIT. + * \param[in] macro A binary operation of the form macro(data, n). This macro + * is expanded by MRECURSION with the current repetition number + * and the auxiliary data argument. + * \param[in] data A recursive threshold, building on this to decline by times + * defined with param count. + * + * \return macro(data-count+1,0) macro(data-count+2,1)...macro(data,count-1) + */ +#define MRECURSION(count, macro, data) TPASTE2(MRECURSION, count) (macro, data) + +#define MRECURSION0( macro, data) +#define MRECURSION1( macro, data) MRECURSION0( macro, DEC_(data)) macro(data, 0) +#define MRECURSION2( macro, data) MRECURSION1( macro, DEC_(data)) macro(data, 1) +#define MRECURSION3( macro, data) MRECURSION2( macro, DEC_(data)) macro(data, 2) +#define MRECURSION4( macro, data) MRECURSION3( macro, DEC_(data)) macro(data, 3) +#define MRECURSION5( macro, data) MRECURSION4( macro, DEC_(data)) macro(data, 4) +#define MRECURSION6( macro, data) MRECURSION5( macro, DEC_(data)) macro(data, 5) +#define MRECURSION7( macro, data) MRECURSION6( macro, DEC_(data)) macro(data, 6) +#define MRECURSION8( macro, data) MRECURSION7( macro, DEC_(data)) macro(data, 7) +#define MRECURSION9( macro, data) MRECURSION8( macro, DEC_(data)) macro(data, 8) +#define MRECURSION10( macro, data) MRECURSION9( macro, DEC_(data)) macro(data, 9) +#define MRECURSION11( macro, data) MRECURSION10( macro, DEC_(data)) macro(data, 10) +#define MRECURSION12( macro, data) MRECURSION11( macro, DEC_(data)) macro(data, 11) +#define MRECURSION13( macro, data) MRECURSION12( macro, DEC_(data)) macro(data, 12) +#define MRECURSION14( macro, data) MRECURSION13( macro, DEC_(data)) macro(data, 13) +#define MRECURSION15( macro, data) MRECURSION14( macro, DEC_(data)) macro(data, 14) +#define MRECURSION16( macro, data) MRECURSION15( macro, DEC_(data)) macro(data, 15) +#define MRECURSION17( macro, data) MRECURSION16( macro, DEC_(data)) macro(data, 16) +#define MRECURSION18( macro, data) MRECURSION17( macro, DEC_(data)) macro(data, 17) +#define MRECURSION19( macro, data) MRECURSION18( macro, DEC_(data)) macro(data, 18) +#define MRECURSION20( macro, data) MRECURSION19( macro, DEC_(data)) macro(data, 19) +#define MRECURSION21( macro, data) MRECURSION20( macro, DEC_(data)) macro(data, 20) +#define MRECURSION22( macro, data) MRECURSION21( macro, DEC_(data)) macro(data, 21) +#define MRECURSION23( macro, data) MRECURSION22( macro, DEC_(data)) macro(data, 22) +#define MRECURSION24( macro, data) MRECURSION23( macro, DEC_(data)) macro(data, 23) +#define MRECURSION25( macro, data) MRECURSION24( macro, DEC_(data)) macro(data, 24) +#define MRECURSION26( macro, data) MRECURSION25( macro, DEC_(data)) macro(data, 25) +#define MRECURSION27( macro, data) MRECURSION26( macro, DEC_(data)) macro(data, 26) +#define MRECURSION28( macro, data) MRECURSION27( macro, DEC_(data)) macro(data, 27) +#define MRECURSION29( macro, data) MRECURSION28( macro, DEC_(data)) macro(data, 28) +#define MRECURSION30( macro, data) MRECURSION29( macro, DEC_(data)) macro(data, 29) +#define MRECURSION31( macro, data) MRECURSION30( macro, DEC_(data)) macro(data, 30) +#define MRECURSION32( macro, data) MRECURSION31( macro, DEC_(data)) macro(data, 31) +#define MRECURSION33( macro, data) MRECURSION32( macro, DEC_(data)) macro(data, 32) +#define MRECURSION34( macro, data) MRECURSION33( macro, DEC_(data)) macro(data, 33) +#define MRECURSION35( macro, data) MRECURSION34( macro, DEC_(data)) macro(data, 34) +#define MRECURSION36( macro, data) MRECURSION35( macro, DEC_(data)) macro(data, 35) +#define MRECURSION37( macro, data) MRECURSION36( macro, DEC_(data)) macro(data, 36) +#define MRECURSION38( macro, data) MRECURSION37( macro, DEC_(data)) macro(data, 37) +#define MRECURSION39( macro, data) MRECURSION38( macro, DEC_(data)) macro(data, 38) +#define MRECURSION40( macro, data) MRECURSION39( macro, DEC_(data)) macro(data, 39) +#define MRECURSION41( macro, data) MRECURSION40( macro, DEC_(data)) macro(data, 40) +#define MRECURSION42( macro, data) MRECURSION41( macro, DEC_(data)) macro(data, 41) +#define MRECURSION43( macro, data) MRECURSION42( macro, DEC_(data)) macro(data, 42) +#define MRECURSION44( macro, data) MRECURSION43( macro, DEC_(data)) macro(data, 43) +#define MRECURSION45( macro, data) MRECURSION44( macro, DEC_(data)) macro(data, 44) +#define MRECURSION46( macro, data) MRECURSION45( macro, DEC_(data)) macro(data, 45) +#define MRECURSION47( macro, data) MRECURSION46( macro, DEC_(data)) macro(data, 46) +#define MRECURSION48( macro, data) MRECURSION47( macro, DEC_(data)) macro(data, 47) +#define MRECURSION49( macro, data) MRECURSION48( macro, DEC_(data)) macro(data, 48) +#define MRECURSION50( macro, data) MRECURSION49( macro, DEC_(data)) macro(data, 49) +#define MRECURSION51( macro, data) MRECURSION50( macro, DEC_(data)) macro(data, 50) +#define MRECURSION52( macro, data) MRECURSION51( macro, DEC_(data)) macro(data, 51) +#define MRECURSION53( macro, data) MRECURSION52( macro, DEC_(data)) macro(data, 52) +#define MRECURSION54( macro, data) MRECURSION53( macro, DEC_(data)) macro(data, 53) +#define MRECURSION55( macro, data) MRECURSION54( macro, DEC_(data)) macro(data, 54) +#define MRECURSION56( macro, data) MRECURSION55( macro, DEC_(data)) macro(data, 55) +#define MRECURSION57( macro, data) MRECURSION56( macro, DEC_(data)) macro(data, 56) +#define MRECURSION58( macro, data) MRECURSION57( macro, DEC_(data)) macro(data, 57) +#define MRECURSION59( macro, data) MRECURSION58( macro, DEC_(data)) macro(data, 58) +#define MRECURSION60( macro, data) MRECURSION59( macro, DEC_(data)) macro(data, 59) +#define MRECURSION61( macro, data) MRECURSION60( macro, DEC_(data)) macro(data, 60) +#define MRECURSION62( macro, data) MRECURSION61( macro, DEC_(data)) macro(data, 61) +#define MRECURSION63( macro, data) MRECURSION62( macro, DEC_(data)) macro(data, 62) +#define MRECURSION64( macro, data) MRECURSION63( macro, DEC_(data)) macro(data, 63) +#define MRECURSION65( macro, data) MRECURSION64( macro, DEC_(data)) macro(data, 64) +#define MRECURSION66( macro, data) MRECURSION65( macro, DEC_(data)) macro(data, 65) +#define MRECURSION67( macro, data) MRECURSION66( macro, DEC_(data)) macro(data, 66) +#define MRECURSION68( macro, data) MRECURSION67( macro, DEC_(data)) macro(data, 67) +#define MRECURSION69( macro, data) MRECURSION68( macro, DEC_(data)) macro(data, 68) +#define MRECURSION70( macro, data) MRECURSION69( macro, DEC_(data)) macro(data, 69) +#define MRECURSION71( macro, data) MRECURSION70( macro, DEC_(data)) macro(data, 70) +#define MRECURSION72( macro, data) MRECURSION71( macro, DEC_(data)) macro(data, 71) +#define MRECURSION73( macro, data) MRECURSION72( macro, DEC_(data)) macro(data, 72) +#define MRECURSION74( macro, data) MRECURSION73( macro, DEC_(data)) macro(data, 73) +#define MRECURSION75( macro, data) MRECURSION74( macro, DEC_(data)) macro(data, 74) +#define MRECURSION76( macro, data) MRECURSION75( macro, DEC_(data)) macro(data, 75) +#define MRECURSION77( macro, data) MRECURSION76( macro, DEC_(data)) macro(data, 76) +#define MRECURSION78( macro, data) MRECURSION77( macro, DEC_(data)) macro(data, 77) +#define MRECURSION79( macro, data) MRECURSION78( macro, DEC_(data)) macro(data, 78) +#define MRECURSION80( macro, data) MRECURSION79( macro, DEC_(data)) macro(data, 79) +#define MRECURSION81( macro, data) MRECURSION80( macro, DEC_(data)) macro(data, 80) +#define MRECURSION82( macro, data) MRECURSION81( macro, DEC_(data)) macro(data, 81) +#define MRECURSION83( macro, data) MRECURSION82( macro, DEC_(data)) macro(data, 82) +#define MRECURSION84( macro, data) MRECURSION83( macro, DEC_(data)) macro(data, 83) +#define MRECURSION85( macro, data) MRECURSION84( macro, DEC_(data)) macro(data, 84) +#define MRECURSION86( macro, data) MRECURSION85( macro, DEC_(data)) macro(data, 85) +#define MRECURSION87( macro, data) MRECURSION86( macro, DEC_(data)) macro(data, 86) +#define MRECURSION88( macro, data) MRECURSION87( macro, DEC_(data)) macro(data, 87) +#define MRECURSION89( macro, data) MRECURSION88( macro, DEC_(data)) macro(data, 88) +#define MRECURSION90( macro, data) MRECURSION89( macro, DEC_(data)) macro(data, 89) +#define MRECURSION91( macro, data) MRECURSION90( macro, DEC_(data)) macro(data, 90) +#define MRECURSION92( macro, data) MRECURSION91( macro, DEC_(data)) macro(data, 91) +#define MRECURSION93( macro, data) MRECURSION92( macro, DEC_(data)) macro(data, 92) +#define MRECURSION94( macro, data) MRECURSION93( macro, DEC_(data)) macro(data, 93) +#define MRECURSION95( macro, data) MRECURSION94( macro, DEC_(data)) macro(data, 94) +#define MRECURSION96( macro, data) MRECURSION95( macro, DEC_(data)) macro(data, 95) +#define MRECURSION97( macro, data) MRECURSION96( macro, DEC_(data)) macro(data, 96) +#define MRECURSION98( macro, data) MRECURSION97( macro, DEC_(data)) macro(data, 97) +#define MRECURSION99( macro, data) MRECURSION98( macro, DEC_(data)) macro(data, 98) +#define MRECURSION100(macro, data) MRECURSION99( macro, DEC_(data)) macro(data, 99) +#define MRECURSION101(macro, data) MRECURSION100( macro, DEC_(data)) macro(data, 100) +#define MRECURSION102(macro, data) MRECURSION101( macro, DEC_(data)) macro(data, 101) +#define MRECURSION103(macro, data) MRECURSION102( macro, DEC_(data)) macro(data, 102) +#define MRECURSION104(macro, data) MRECURSION103( macro, DEC_(data)) macro(data, 103) +#define MRECURSION105(macro, data) MRECURSION104( macro, DEC_(data)) macro(data, 104) +#define MRECURSION106(macro, data) MRECURSION105( macro, DEC_(data)) macro(data, 105) +#define MRECURSION107(macro, data) MRECURSION106( macro, DEC_(data)) macro(data, 106) +#define MRECURSION108(macro, data) MRECURSION107( macro, DEC_(data)) macro(data, 107) +#define MRECURSION109(macro, data) MRECURSION108( macro, DEC_(data)) macro(data, 108) +#define MRECURSION110(macro, data) MRECURSION109( macro, DEC_(data)) macro(data, 109) +#define MRECURSION111(macro, data) MRECURSION110( macro, DEC_(data)) macro(data, 110) +#define MRECURSION112(macro, data) MRECURSION111( macro, DEC_(data)) macro(data, 111) +#define MRECURSION113(macro, data) MRECURSION112( macro, DEC_(data)) macro(data, 112) +#define MRECURSION114(macro, data) MRECURSION113( macro, DEC_(data)) macro(data, 113) +#define MRECURSION115(macro, data) MRECURSION114( macro, DEC_(data)) macro(data, 114) +#define MRECURSION116(macro, data) MRECURSION115( macro, DEC_(data)) macro(data, 115) +#define MRECURSION117(macro, data) MRECURSION116( macro, DEC_(data)) macro(data, 116) +#define MRECURSION118(macro, data) MRECURSION117( macro, DEC_(data)) macro(data, 117) +#define MRECURSION119(macro, data) MRECURSION118( macro, DEC_(data)) macro(data, 118) +#define MRECURSION120(macro, data) MRECURSION119( macro, DEC_(data)) macro(data, 119) +#define MRECURSION121(macro, data) MRECURSION120( macro, DEC_(data)) macro(data, 120) +#define MRECURSION122(macro, data) MRECURSION121( macro, DEC_(data)) macro(data, 121) +#define MRECURSION123(macro, data) MRECURSION122( macro, DEC_(data)) macro(data, 122) +#define MRECURSION124(macro, data) MRECURSION123( macro, DEC_(data)) macro(data, 123) +#define MRECURSION125(macro, data) MRECURSION124( macro, DEC_(data)) macro(data, 124) +#define MRECURSION126(macro, data) MRECURSION125( macro, DEC_(data)) macro(data, 125) +#define MRECURSION127(macro, data) MRECURSION126( macro, DEC_(data)) macro(data, 126) +#define MRECURSION128(macro, data) MRECURSION127( macro, DEC_(data)) macro(data, 127) +#define MRECURSION129(macro, data) MRECURSION128( macro, DEC_(data)) macro(data, 128) +#define MRECURSION130(macro, data) MRECURSION129( macro, DEC_(data)) macro(data, 129) +#define MRECURSION131(macro, data) MRECURSION130( macro, DEC_(data)) macro(data, 130) +#define MRECURSION132(macro, data) MRECURSION131( macro, DEC_(data)) macro(data, 131) +#define MRECURSION133(macro, data) MRECURSION132( macro, DEC_(data)) macro(data, 132) +#define MRECURSION134(macro, data) MRECURSION133( macro, DEC_(data)) macro(data, 133) +#define MRECURSION135(macro, data) MRECURSION134( macro, DEC_(data)) macro(data, 134) +#define MRECURSION136(macro, data) MRECURSION135( macro, DEC_(data)) macro(data, 135) +#define MRECURSION137(macro, data) MRECURSION136( macro, DEC_(data)) macro(data, 136) +#define MRECURSION138(macro, data) MRECURSION137( macro, DEC_(data)) macro(data, 137) +#define MRECURSION139(macro, data) MRECURSION138( macro, DEC_(data)) macro(data, 138) +#define MRECURSION140(macro, data) MRECURSION139( macro, DEC_(data)) macro(data, 139) +#define MRECURSION141(macro, data) MRECURSION140( macro, DEC_(data)) macro(data, 140) +#define MRECURSION142(macro, data) MRECURSION141( macro, DEC_(data)) macro(data, 141) +#define MRECURSION143(macro, data) MRECURSION142( macro, DEC_(data)) macro(data, 142) +#define MRECURSION144(macro, data) MRECURSION143( macro, DEC_(data)) macro(data, 143) +#define MRECURSION145(macro, data) MRECURSION144( macro, DEC_(data)) macro(data, 144) +#define MRECURSION146(macro, data) MRECURSION145( macro, DEC_(data)) macro(data, 145) +#define MRECURSION147(macro, data) MRECURSION146( macro, DEC_(data)) macro(data, 146) +#define MRECURSION148(macro, data) MRECURSION147( macro, DEC_(data)) macro(data, 147) +#define MRECURSION149(macro, data) MRECURSION148( macro, DEC_(data)) macro(data, 148) +#define MRECURSION150(macro, data) MRECURSION149( macro, DEC_(data)) macro(data, 149) +#define MRECURSION151(macro, data) MRECURSION150( macro, DEC_(data)) macro(data, 150) +#define MRECURSION152(macro, data) MRECURSION151( macro, DEC_(data)) macro(data, 151) +#define MRECURSION153(macro, data) MRECURSION152( macro, DEC_(data)) macro(data, 152) +#define MRECURSION154(macro, data) MRECURSION153( macro, DEC_(data)) macro(data, 153) +#define MRECURSION155(macro, data) MRECURSION154( macro, DEC_(data)) macro(data, 154) +#define MRECURSION156(macro, data) MRECURSION155( macro, DEC_(data)) macro(data, 155) +#define MRECURSION157(macro, data) MRECURSION156( macro, DEC_(data)) macro(data, 156) +#define MRECURSION158(macro, data) MRECURSION157( macro, DEC_(data)) macro(data, 157) +#define MRECURSION159(macro, data) MRECURSION158( macro, DEC_(data)) macro(data, 158) +#define MRECURSION160(macro, data) MRECURSION159( macro, DEC_(data)) macro(data, 159) +#define MRECURSION161(macro, data) MRECURSION160( macro, DEC_(data)) macro(data, 160) +#define MRECURSION162(macro, data) MRECURSION161( macro, DEC_(data)) macro(data, 161) +#define MRECURSION163(macro, data) MRECURSION162( macro, DEC_(data)) macro(data, 162) +#define MRECURSION164(macro, data) MRECURSION163( macro, DEC_(data)) macro(data, 163) +#define MRECURSION165(macro, data) MRECURSION164( macro, DEC_(data)) macro(data, 164) +#define MRECURSION166(macro, data) MRECURSION165( macro, DEC_(data)) macro(data, 165) +#define MRECURSION167(macro, data) MRECURSION166( macro, DEC_(data)) macro(data, 166) +#define MRECURSION168(macro, data) MRECURSION167( macro, DEC_(data)) macro(data, 167) +#define MRECURSION169(macro, data) MRECURSION168( macro, DEC_(data)) macro(data, 168) +#define MRECURSION170(macro, data) MRECURSION169( macro, DEC_(data)) macro(data, 169) +#define MRECURSION171(macro, data) MRECURSION170( macro, DEC_(data)) macro(data, 170) +#define MRECURSION172(macro, data) MRECURSION171( macro, DEC_(data)) macro(data, 171) +#define MRECURSION173(macro, data) MRECURSION172( macro, DEC_(data)) macro(data, 172) +#define MRECURSION174(macro, data) MRECURSION173( macro, DEC_(data)) macro(data, 173) +#define MRECURSION175(macro, data) MRECURSION174( macro, DEC_(data)) macro(data, 174) +#define MRECURSION176(macro, data) MRECURSION175( macro, DEC_(data)) macro(data, 175) +#define MRECURSION177(macro, data) MRECURSION176( macro, DEC_(data)) macro(data, 176) +#define MRECURSION178(macro, data) MRECURSION177( macro, DEC_(data)) macro(data, 177) +#define MRECURSION179(macro, data) MRECURSION178( macro, DEC_(data)) macro(data, 178) +#define MRECURSION180(macro, data) MRECURSION179( macro, DEC_(data)) macro(data, 179) +#define MRECURSION181(macro, data) MRECURSION180( macro, DEC_(data)) macro(data, 180) +#define MRECURSION182(macro, data) MRECURSION181( macro, DEC_(data)) macro(data, 181) +#define MRECURSION183(macro, data) MRECURSION182( macro, DEC_(data)) macro(data, 182) +#define MRECURSION184(macro, data) MRECURSION183( macro, DEC_(data)) macro(data, 183) +#define MRECURSION185(macro, data) MRECURSION184( macro, DEC_(data)) macro(data, 184) +#define MRECURSION186(macro, data) MRECURSION185( macro, DEC_(data)) macro(data, 185) +#define MRECURSION187(macro, data) MRECURSION186( macro, DEC_(data)) macro(data, 186) +#define MRECURSION188(macro, data) MRECURSION187( macro, DEC_(data)) macro(data, 187) +#define MRECURSION189(macro, data) MRECURSION188( macro, DEC_(data)) macro(data, 188) +#define MRECURSION190(macro, data) MRECURSION189( macro, DEC_(data)) macro(data, 189) +#define MRECURSION191(macro, data) MRECURSION190( macro, DEC_(data)) macro(data, 190) +#define MRECURSION192(macro, data) MRECURSION191( macro, DEC_(data)) macro(data, 191) +#define MRECURSION193(macro, data) MRECURSION192( macro, DEC_(data)) macro(data, 192) +#define MRECURSION194(macro, data) MRECURSION193( macro, DEC_(data)) macro(data, 193) +#define MRECURSION195(macro, data) MRECURSION194( macro, DEC_(data)) macro(data, 194) +#define MRECURSION196(macro, data) MRECURSION195( macro, DEC_(data)) macro(data, 195) +#define MRECURSION197(macro, data) MRECURSION196( macro, DEC_(data)) macro(data, 196) +#define MRECURSION198(macro, data) MRECURSION197( macro, DEC_(data)) macro(data, 197) +#define MRECURSION199(macro, data) MRECURSION198( macro, DEC_(data)) macro(data, 198) +#define MRECURSION200(macro, data) MRECURSION199( macro, DEC_(data)) macro(data, 199) +#define MRECURSION201(macro, data) MRECURSION200( macro, DEC_(data)) macro(data, 200) +#define MRECURSION202(macro, data) MRECURSION201( macro, DEC_(data)) macro(data, 201) +#define MRECURSION203(macro, data) MRECURSION202( macro, DEC_(data)) macro(data, 202) +#define MRECURSION204(macro, data) MRECURSION203( macro, DEC_(data)) macro(data, 203) +#define MRECURSION205(macro, data) MRECURSION204( macro, DEC_(data)) macro(data, 204) +#define MRECURSION206(macro, data) MRECURSION205( macro, DEC_(data)) macro(data, 205) +#define MRECURSION207(macro, data) MRECURSION206( macro, DEC_(data)) macro(data, 206) +#define MRECURSION208(macro, data) MRECURSION207( macro, DEC_(data)) macro(data, 207) +#define MRECURSION209(macro, data) MRECURSION208( macro, DEC_(data)) macro(data, 208) +#define MRECURSION210(macro, data) MRECURSION209( macro, DEC_(data)) macro(data, 209) +#define MRECURSION211(macro, data) MRECURSION210( macro, DEC_(data)) macro(data, 210) +#define MRECURSION212(macro, data) MRECURSION211( macro, DEC_(data)) macro(data, 211) +#define MRECURSION213(macro, data) MRECURSION212( macro, DEC_(data)) macro(data, 212) +#define MRECURSION214(macro, data) MRECURSION213( macro, DEC_(data)) macro(data, 213) +#define MRECURSION215(macro, data) MRECURSION214( macro, DEC_(data)) macro(data, 214) +#define MRECURSION216(macro, data) MRECURSION215( macro, DEC_(data)) macro(data, 215) +#define MRECURSION217(macro, data) MRECURSION216( macro, DEC_(data)) macro(data, 216) +#define MRECURSION218(macro, data) MRECURSION217( macro, DEC_(data)) macro(data, 217) +#define MRECURSION219(macro, data) MRECURSION218( macro, DEC_(data)) macro(data, 218) +#define MRECURSION220(macro, data) MRECURSION219( macro, DEC_(data)) macro(data, 219) +#define MRECURSION221(macro, data) MRECURSION220( macro, DEC_(data)) macro(data, 220) +#define MRECURSION222(macro, data) MRECURSION221( macro, DEC_(data)) macro(data, 221) +#define MRECURSION223(macro, data) MRECURSION222( macro, DEC_(data)) macro(data, 222) +#define MRECURSION224(macro, data) MRECURSION223( macro, DEC_(data)) macro(data, 223) +#define MRECURSION225(macro, data) MRECURSION224( macro, DEC_(data)) macro(data, 224) +#define MRECURSION226(macro, data) MRECURSION225( macro, DEC_(data)) macro(data, 225) +#define MRECURSION227(macro, data) MRECURSION226( macro, DEC_(data)) macro(data, 226) +#define MRECURSION228(macro, data) MRECURSION227( macro, DEC_(data)) macro(data, 227) +#define MRECURSION229(macro, data) MRECURSION228( macro, DEC_(data)) macro(data, 228) +#define MRECURSION230(macro, data) MRECURSION229( macro, DEC_(data)) macro(data, 229) +#define MRECURSION231(macro, data) MRECURSION230( macro, DEC_(data)) macro(data, 230) +#define MRECURSION232(macro, data) MRECURSION231( macro, DEC_(data)) macro(data, 231) +#define MRECURSION233(macro, data) MRECURSION232( macro, DEC_(data)) macro(data, 232) +#define MRECURSION234(macro, data) MRECURSION233( macro, DEC_(data)) macro(data, 233) +#define MRECURSION235(macro, data) MRECURSION234( macro, DEC_(data)) macro(data, 234) +#define MRECURSION236(macro, data) MRECURSION235( macro, DEC_(data)) macro(data, 235) +#define MRECURSION237(macro, data) MRECURSION236( macro, DEC_(data)) macro(data, 236) +#define MRECURSION238(macro, data) MRECURSION237( macro, DEC_(data)) macro(data, 237) +#define MRECURSION239(macro, data) MRECURSION238( macro, DEC_(data)) macro(data, 238) +#define MRECURSION240(macro, data) MRECURSION239( macro, DEC_(data)) macro(data, 239) +#define MRECURSION241(macro, data) MRECURSION240( macro, DEC_(data)) macro(data, 240) +#define MRECURSION242(macro, data) MRECURSION241( macro, DEC_(data)) macro(data, 241) +#define MRECURSION243(macro, data) MRECURSION242( macro, DEC_(data)) macro(data, 242) +#define MRECURSION244(macro, data) MRECURSION243( macro, DEC_(data)) macro(data, 243) +#define MRECURSION245(macro, data) MRECURSION244( macro, DEC_(data)) macro(data, 244) +#define MRECURSION246(macro, data) MRECURSION245( macro, DEC_(data)) macro(data, 245) +#define MRECURSION247(macro, data) MRECURSION246( macro, DEC_(data)) macro(data, 246) +#define MRECURSION248(macro, data) MRECURSION247( macro, DEC_(data)) macro(data, 247) +#define MRECURSION249(macro, data) MRECURSION248( macro, DEC_(data)) macro(data, 248) +#define MRECURSION250(macro, data) MRECURSION249( macro, DEC_(data)) macro(data, 249) +#define MRECURSION251(macro, data) MRECURSION250( macro, DEC_(data)) macro(data, 250) +#define MRECURSION252(macro, data) MRECURSION251( macro, DEC_(data)) macro(data, 251) +#define MRECURSION253(macro, data) MRECURSION252( macro, DEC_(data)) macro(data, 252) +#define MRECURSION254(macro, data) MRECURSION253( macro, DEC_(data)) macro(data, 253) +#define MRECURSION255(macro, data) MRECURSION254( macro, DEC_(data)) macro(data, 254) +#define MRECURSION256(macro, data) MRECURSION255( macro, DEC_(data)) macro(data, 255) + +/** @} */ + +#endif /* _MRECURSION_H_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/preprocessor/mrepeat.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/preprocessor/mrepeat.h new file mode 100755 index 0000000..127ad9e --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/preprocessor/mrepeat.h @@ -0,0 +1,335 @@ +/** + * \file + * + * \brief Preprocessor macro repeating utils. + * + * Copyright (C) 2012-2013 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _MREPEAT_H_ +#define _MREPEAT_H_ + +/** + * \defgroup group_sam0_utils_mrepeat Preprocessor - Macro Repeat + * + * \ingroup group_sam0_utils + * + * @{ + */ + +#include "preprocessor.h" + +/** Maximal number of repetitions supported by MREPEAT. */ +#define MREPEAT_LIMIT 256 + +/** \brief Macro repeat. + * + * This macro represents a horizontal repetition construct. + * + * \param[in] count The number of repetitious calls to macro. Valid values + * range from 0 to MREPEAT_LIMIT. + * \param[in] macro A binary operation of the form macro(n, data). This macro + * is expanded by MREPEAT with the current repetition number + * and the auxiliary data argument. + * \param[in] data Auxiliary data passed to macro. + * + * \return macro(0, data) macro(1, data) ... macro(count - 1, data) + */ +#define MREPEAT(count, macro, data) TPASTE2(MREPEAT, count) (macro, data) + +#define MREPEAT0( macro, data) +#define MREPEAT1( macro, data) MREPEAT0( macro, data) macro( 0, data) +#define MREPEAT2( macro, data) MREPEAT1( macro, data) macro( 1, data) +#define MREPEAT3( macro, data) MREPEAT2( macro, data) macro( 2, data) +#define MREPEAT4( macro, data) MREPEAT3( macro, data) macro( 3, data) +#define MREPEAT5( macro, data) MREPEAT4( macro, data) macro( 4, data) +#define MREPEAT6( macro, data) MREPEAT5( macro, data) macro( 5, data) +#define MREPEAT7( macro, data) MREPEAT6( macro, data) macro( 6, data) +#define MREPEAT8( macro, data) MREPEAT7( macro, data) macro( 7, data) +#define MREPEAT9( macro, data) MREPEAT8( macro, data) macro( 8, data) +#define MREPEAT10( macro, data) MREPEAT9( macro, data) macro( 9, data) +#define MREPEAT11( macro, data) MREPEAT10( macro, data) macro( 10, data) +#define MREPEAT12( macro, data) MREPEAT11( macro, data) macro( 11, data) +#define MREPEAT13( macro, data) MREPEAT12( macro, data) macro( 12, data) +#define MREPEAT14( macro, data) MREPEAT13( macro, data) macro( 13, data) +#define MREPEAT15( macro, data) MREPEAT14( macro, data) macro( 14, data) +#define MREPEAT16( macro, data) MREPEAT15( macro, data) macro( 15, data) +#define MREPEAT17( macro, data) MREPEAT16( macro, data) macro( 16, data) +#define MREPEAT18( macro, data) MREPEAT17( macro, data) macro( 17, data) +#define MREPEAT19( macro, data) MREPEAT18( macro, data) macro( 18, data) +#define MREPEAT20( macro, data) MREPEAT19( macro, data) macro( 19, data) +#define MREPEAT21( macro, data) MREPEAT20( macro, data) macro( 20, data) +#define MREPEAT22( macro, data) MREPEAT21( macro, data) macro( 21, data) +#define MREPEAT23( macro, data) MREPEAT22( macro, data) macro( 22, data) +#define MREPEAT24( macro, data) MREPEAT23( macro, data) macro( 23, data) +#define MREPEAT25( macro, data) MREPEAT24( macro, data) macro( 24, data) +#define MREPEAT26( macro, data) MREPEAT25( macro, data) macro( 25, data) +#define MREPEAT27( macro, data) MREPEAT26( macro, data) macro( 26, data) +#define MREPEAT28( macro, data) MREPEAT27( macro, data) macro( 27, data) +#define MREPEAT29( macro, data) MREPEAT28( macro, data) macro( 28, data) +#define MREPEAT30( macro, data) MREPEAT29( macro, data) macro( 29, data) +#define MREPEAT31( macro, data) MREPEAT30( macro, data) macro( 30, data) +#define MREPEAT32( macro, data) MREPEAT31( macro, data) macro( 31, data) +#define MREPEAT33( macro, data) MREPEAT32( macro, data) macro( 32, data) +#define MREPEAT34( macro, data) MREPEAT33( macro, data) macro( 33, data) +#define MREPEAT35( macro, data) MREPEAT34( macro, data) macro( 34, data) +#define MREPEAT36( macro, data) MREPEAT35( macro, data) macro( 35, data) +#define MREPEAT37( macro, data) MREPEAT36( macro, data) macro( 36, data) +#define MREPEAT38( macro, data) MREPEAT37( macro, data) macro( 37, data) +#define MREPEAT39( macro, data) MREPEAT38( macro, data) macro( 38, data) +#define MREPEAT40( macro, data) MREPEAT39( macro, data) macro( 39, data) +#define MREPEAT41( macro, data) MREPEAT40( macro, data) macro( 40, data) +#define MREPEAT42( macro, data) MREPEAT41( macro, data) macro( 41, data) +#define MREPEAT43( macro, data) MREPEAT42( macro, data) macro( 42, data) +#define MREPEAT44( macro, data) MREPEAT43( macro, data) macro( 43, data) +#define MREPEAT45( macro, data) MREPEAT44( macro, data) macro( 44, data) +#define MREPEAT46( macro, data) MREPEAT45( macro, data) macro( 45, data) +#define MREPEAT47( macro, data) MREPEAT46( macro, data) macro( 46, data) +#define MREPEAT48( macro, data) MREPEAT47( macro, data) macro( 47, data) +#define MREPEAT49( macro, data) MREPEAT48( macro, data) macro( 48, data) +#define MREPEAT50( macro, data) MREPEAT49( macro, data) macro( 49, data) +#define MREPEAT51( macro, data) MREPEAT50( macro, data) macro( 50, data) +#define MREPEAT52( macro, data) MREPEAT51( macro, data) macro( 51, data) +#define MREPEAT53( macro, data) MREPEAT52( macro, data) macro( 52, data) +#define MREPEAT54( macro, data) MREPEAT53( macro, data) macro( 53, data) +#define MREPEAT55( macro, data) MREPEAT54( macro, data) macro( 54, data) +#define MREPEAT56( macro, data) MREPEAT55( macro, data) macro( 55, data) +#define MREPEAT57( macro, data) MREPEAT56( macro, data) macro( 56, data) +#define MREPEAT58( macro, data) MREPEAT57( macro, data) macro( 57, data) +#define MREPEAT59( macro, data) MREPEAT58( macro, data) macro( 58, data) +#define MREPEAT60( macro, data) MREPEAT59( macro, data) macro( 59, data) +#define MREPEAT61( macro, data) MREPEAT60( macro, data) macro( 60, data) +#define MREPEAT62( macro, data) MREPEAT61( macro, data) macro( 61, data) +#define MREPEAT63( macro, data) MREPEAT62( macro, data) macro( 62, data) +#define MREPEAT64( macro, data) MREPEAT63( macro, data) macro( 63, data) +#define MREPEAT65( macro, data) MREPEAT64( macro, data) macro( 64, data) +#define MREPEAT66( macro, data) MREPEAT65( macro, data) macro( 65, data) +#define MREPEAT67( macro, data) MREPEAT66( macro, data) macro( 66, data) +#define MREPEAT68( macro, data) MREPEAT67( macro, data) macro( 67, data) +#define MREPEAT69( macro, data) MREPEAT68( macro, data) macro( 68, data) +#define MREPEAT70( macro, data) MREPEAT69( macro, data) macro( 69, data) +#define MREPEAT71( macro, data) MREPEAT70( macro, data) macro( 70, data) +#define MREPEAT72( macro, data) MREPEAT71( macro, data) macro( 71, data) +#define MREPEAT73( macro, data) MREPEAT72( macro, data) macro( 72, data) +#define MREPEAT74( macro, data) MREPEAT73( macro, data) macro( 73, data) +#define MREPEAT75( macro, data) MREPEAT74( macro, data) macro( 74, data) +#define MREPEAT76( macro, data) MREPEAT75( macro, data) macro( 75, data) +#define MREPEAT77( macro, data) MREPEAT76( macro, data) macro( 76, data) +#define MREPEAT78( macro, data) MREPEAT77( macro, data) macro( 77, data) +#define MREPEAT79( macro, data) MREPEAT78( macro, data) macro( 78, data) +#define MREPEAT80( macro, data) MREPEAT79( macro, data) macro( 79, data) +#define MREPEAT81( macro, data) MREPEAT80( macro, data) macro( 80, data) +#define MREPEAT82( macro, data) MREPEAT81( macro, data) macro( 81, data) +#define MREPEAT83( macro, data) MREPEAT82( macro, data) macro( 82, data) +#define MREPEAT84( macro, data) MREPEAT83( macro, data) macro( 83, data) +#define MREPEAT85( macro, data) MREPEAT84( macro, data) macro( 84, data) +#define MREPEAT86( macro, data) MREPEAT85( macro, data) macro( 85, data) +#define MREPEAT87( macro, data) MREPEAT86( macro, data) macro( 86, data) +#define MREPEAT88( macro, data) MREPEAT87( macro, data) macro( 87, data) +#define MREPEAT89( macro, data) MREPEAT88( macro, data) macro( 88, data) +#define MREPEAT90( macro, data) MREPEAT89( macro, data) macro( 89, data) +#define MREPEAT91( macro, data) MREPEAT90( macro, data) macro( 90, data) +#define MREPEAT92( macro, data) MREPEAT91( macro, data) macro( 91, data) +#define MREPEAT93( macro, data) MREPEAT92( macro, data) macro( 92, data) +#define MREPEAT94( macro, data) MREPEAT93( macro, data) macro( 93, data) +#define MREPEAT95( macro, data) MREPEAT94( macro, data) macro( 94, data) +#define MREPEAT96( macro, data) MREPEAT95( macro, data) macro( 95, data) +#define MREPEAT97( macro, data) MREPEAT96( macro, data) macro( 96, data) +#define MREPEAT98( macro, data) MREPEAT97( macro, data) macro( 97, data) +#define MREPEAT99( macro, data) MREPEAT98( macro, data) macro( 98, data) +#define MREPEAT100(macro, data) MREPEAT99( macro, data) macro( 99, data) +#define MREPEAT101(macro, data) MREPEAT100(macro, data) macro(100, data) +#define MREPEAT102(macro, data) MREPEAT101(macro, data) macro(101, data) +#define MREPEAT103(macro, data) MREPEAT102(macro, data) macro(102, data) +#define MREPEAT104(macro, data) MREPEAT103(macro, data) macro(103, data) +#define MREPEAT105(macro, data) MREPEAT104(macro, data) macro(104, data) +#define MREPEAT106(macro, data) MREPEAT105(macro, data) macro(105, data) +#define MREPEAT107(macro, data) MREPEAT106(macro, data) macro(106, data) +#define MREPEAT108(macro, data) MREPEAT107(macro, data) macro(107, data) +#define MREPEAT109(macro, data) MREPEAT108(macro, data) macro(108, data) +#define MREPEAT110(macro, data) MREPEAT109(macro, data) macro(109, data) +#define MREPEAT111(macro, data) MREPEAT110(macro, data) macro(110, data) +#define MREPEAT112(macro, data) MREPEAT111(macro, data) macro(111, data) +#define MREPEAT113(macro, data) MREPEAT112(macro, data) macro(112, data) +#define MREPEAT114(macro, data) MREPEAT113(macro, data) macro(113, data) +#define MREPEAT115(macro, data) MREPEAT114(macro, data) macro(114, data) +#define MREPEAT116(macro, data) MREPEAT115(macro, data) macro(115, data) +#define MREPEAT117(macro, data) MREPEAT116(macro, data) macro(116, data) +#define MREPEAT118(macro, data) MREPEAT117(macro, data) macro(117, data) +#define MREPEAT119(macro, data) MREPEAT118(macro, data) macro(118, data) +#define MREPEAT120(macro, data) MREPEAT119(macro, data) macro(119, data) +#define MREPEAT121(macro, data) MREPEAT120(macro, data) macro(120, data) +#define MREPEAT122(macro, data) MREPEAT121(macro, data) macro(121, data) +#define MREPEAT123(macro, data) MREPEAT122(macro, data) macro(122, data) +#define MREPEAT124(macro, data) MREPEAT123(macro, data) macro(123, data) +#define MREPEAT125(macro, data) MREPEAT124(macro, data) macro(124, data) +#define MREPEAT126(macro, data) MREPEAT125(macro, data) macro(125, data) +#define MREPEAT127(macro, data) MREPEAT126(macro, data) macro(126, data) +#define MREPEAT128(macro, data) MREPEAT127(macro, data) macro(127, data) +#define MREPEAT129(macro, data) MREPEAT128(macro, data) macro(128, data) +#define MREPEAT130(macro, data) MREPEAT129(macro, data) macro(129, data) +#define MREPEAT131(macro, data) MREPEAT130(macro, data) macro(130, data) +#define MREPEAT132(macro, data) MREPEAT131(macro, data) macro(131, data) +#define MREPEAT133(macro, data) MREPEAT132(macro, data) macro(132, data) +#define MREPEAT134(macro, data) MREPEAT133(macro, data) macro(133, data) +#define MREPEAT135(macro, data) MREPEAT134(macro, data) macro(134, data) +#define MREPEAT136(macro, data) MREPEAT135(macro, data) macro(135, data) +#define MREPEAT137(macro, data) MREPEAT136(macro, data) macro(136, data) +#define MREPEAT138(macro, data) MREPEAT137(macro, data) macro(137, data) +#define MREPEAT139(macro, data) MREPEAT138(macro, data) macro(138, data) +#define MREPEAT140(macro, data) MREPEAT139(macro, data) macro(139, data) +#define MREPEAT141(macro, data) MREPEAT140(macro, data) macro(140, data) +#define MREPEAT142(macro, data) MREPEAT141(macro, data) macro(141, data) +#define MREPEAT143(macro, data) MREPEAT142(macro, data) macro(142, data) +#define MREPEAT144(macro, data) MREPEAT143(macro, data) macro(143, data) +#define MREPEAT145(macro, data) MREPEAT144(macro, data) macro(144, data) +#define MREPEAT146(macro, data) MREPEAT145(macro, data) macro(145, data) +#define MREPEAT147(macro, data) MREPEAT146(macro, data) macro(146, data) +#define MREPEAT148(macro, data) MREPEAT147(macro, data) macro(147, data) +#define MREPEAT149(macro, data) MREPEAT148(macro, data) macro(148, data) +#define MREPEAT150(macro, data) MREPEAT149(macro, data) macro(149, data) +#define MREPEAT151(macro, data) MREPEAT150(macro, data) macro(150, data) +#define MREPEAT152(macro, data) MREPEAT151(macro, data) macro(151, data) +#define MREPEAT153(macro, data) MREPEAT152(macro, data) macro(152, data) +#define MREPEAT154(macro, data) MREPEAT153(macro, data) macro(153, data) +#define MREPEAT155(macro, data) MREPEAT154(macro, data) macro(154, data) +#define MREPEAT156(macro, data) MREPEAT155(macro, data) macro(155, data) +#define MREPEAT157(macro, data) MREPEAT156(macro, data) macro(156, data) +#define MREPEAT158(macro, data) MREPEAT157(macro, data) macro(157, data) +#define MREPEAT159(macro, data) MREPEAT158(macro, data) macro(158, data) +#define MREPEAT160(macro, data) MREPEAT159(macro, data) macro(159, data) +#define MREPEAT161(macro, data) MREPEAT160(macro, data) macro(160, data) +#define MREPEAT162(macro, data) MREPEAT161(macro, data) macro(161, data) +#define MREPEAT163(macro, data) MREPEAT162(macro, data) macro(162, data) +#define MREPEAT164(macro, data) MREPEAT163(macro, data) macro(163, data) +#define MREPEAT165(macro, data) MREPEAT164(macro, data) macro(164, data) +#define MREPEAT166(macro, data) MREPEAT165(macro, data) macro(165, data) +#define MREPEAT167(macro, data) MREPEAT166(macro, data) macro(166, data) +#define MREPEAT168(macro, data) MREPEAT167(macro, data) macro(167, data) +#define MREPEAT169(macro, data) MREPEAT168(macro, data) macro(168, data) +#define MREPEAT170(macro, data) MREPEAT169(macro, data) macro(169, data) +#define MREPEAT171(macro, data) MREPEAT170(macro, data) macro(170, data) +#define MREPEAT172(macro, data) MREPEAT171(macro, data) macro(171, data) +#define MREPEAT173(macro, data) MREPEAT172(macro, data) macro(172, data) +#define MREPEAT174(macro, data) MREPEAT173(macro, data) macro(173, data) +#define MREPEAT175(macro, data) MREPEAT174(macro, data) macro(174, data) +#define MREPEAT176(macro, data) MREPEAT175(macro, data) macro(175, data) +#define MREPEAT177(macro, data) MREPEAT176(macro, data) macro(176, data) +#define MREPEAT178(macro, data) MREPEAT177(macro, data) macro(177, data) +#define MREPEAT179(macro, data) MREPEAT178(macro, data) macro(178, data) +#define MREPEAT180(macro, data) MREPEAT179(macro, data) macro(179, data) +#define MREPEAT181(macro, data) MREPEAT180(macro, data) macro(180, data) +#define MREPEAT182(macro, data) MREPEAT181(macro, data) macro(181, data) +#define MREPEAT183(macro, data) MREPEAT182(macro, data) macro(182, data) +#define MREPEAT184(macro, data) MREPEAT183(macro, data) macro(183, data) +#define MREPEAT185(macro, data) MREPEAT184(macro, data) macro(184, data) +#define MREPEAT186(macro, data) MREPEAT185(macro, data) macro(185, data) +#define MREPEAT187(macro, data) MREPEAT186(macro, data) macro(186, data) +#define MREPEAT188(macro, data) MREPEAT187(macro, data) macro(187, data) +#define MREPEAT189(macro, data) MREPEAT188(macro, data) macro(188, data) +#define MREPEAT190(macro, data) MREPEAT189(macro, data) macro(189, data) +#define MREPEAT191(macro, data) MREPEAT190(macro, data) macro(190, data) +#define MREPEAT192(macro, data) MREPEAT191(macro, data) macro(191, data) +#define MREPEAT193(macro, data) MREPEAT192(macro, data) macro(192, data) +#define MREPEAT194(macro, data) MREPEAT193(macro, data) macro(193, data) +#define MREPEAT195(macro, data) MREPEAT194(macro, data) macro(194, data) +#define MREPEAT196(macro, data) MREPEAT195(macro, data) macro(195, data) +#define MREPEAT197(macro, data) MREPEAT196(macro, data) macro(196, data) +#define MREPEAT198(macro, data) MREPEAT197(macro, data) macro(197, data) +#define MREPEAT199(macro, data) MREPEAT198(macro, data) macro(198, data) +#define MREPEAT200(macro, data) MREPEAT199(macro, data) macro(199, data) +#define MREPEAT201(macro, data) MREPEAT200(macro, data) macro(200, data) +#define MREPEAT202(macro, data) MREPEAT201(macro, data) macro(201, data) +#define MREPEAT203(macro, data) MREPEAT202(macro, data) macro(202, data) +#define MREPEAT204(macro, data) MREPEAT203(macro, data) macro(203, data) +#define MREPEAT205(macro, data) MREPEAT204(macro, data) macro(204, data) +#define MREPEAT206(macro, data) MREPEAT205(macro, data) macro(205, data) +#define MREPEAT207(macro, data) MREPEAT206(macro, data) macro(206, data) +#define MREPEAT208(macro, data) MREPEAT207(macro, data) macro(207, data) +#define MREPEAT209(macro, data) MREPEAT208(macro, data) macro(208, data) +#define MREPEAT210(macro, data) MREPEAT209(macro, data) macro(209, data) +#define MREPEAT211(macro, data) MREPEAT210(macro, data) macro(210, data) +#define MREPEAT212(macro, data) MREPEAT211(macro, data) macro(211, data) +#define MREPEAT213(macro, data) MREPEAT212(macro, data) macro(212, data) +#define MREPEAT214(macro, data) MREPEAT213(macro, data) macro(213, data) +#define MREPEAT215(macro, data) MREPEAT214(macro, data) macro(214, data) +#define MREPEAT216(macro, data) MREPEAT215(macro, data) macro(215, data) +#define MREPEAT217(macro, data) MREPEAT216(macro, data) macro(216, data) +#define MREPEAT218(macro, data) MREPEAT217(macro, data) macro(217, data) +#define MREPEAT219(macro, data) MREPEAT218(macro, data) macro(218, data) +#define MREPEAT220(macro, data) MREPEAT219(macro, data) macro(219, data) +#define MREPEAT221(macro, data) MREPEAT220(macro, data) macro(220, data) +#define MREPEAT222(macro, data) MREPEAT221(macro, data) macro(221, data) +#define MREPEAT223(macro, data) MREPEAT222(macro, data) macro(222, data) +#define MREPEAT224(macro, data) MREPEAT223(macro, data) macro(223, data) +#define MREPEAT225(macro, data) MREPEAT224(macro, data) macro(224, data) +#define MREPEAT226(macro, data) MREPEAT225(macro, data) macro(225, data) +#define MREPEAT227(macro, data) MREPEAT226(macro, data) macro(226, data) +#define MREPEAT228(macro, data) MREPEAT227(macro, data) macro(227, data) +#define MREPEAT229(macro, data) MREPEAT228(macro, data) macro(228, data) +#define MREPEAT230(macro, data) MREPEAT229(macro, data) macro(229, data) +#define MREPEAT231(macro, data) MREPEAT230(macro, data) macro(230, data) +#define MREPEAT232(macro, data) MREPEAT231(macro, data) macro(231, data) +#define MREPEAT233(macro, data) MREPEAT232(macro, data) macro(232, data) +#define MREPEAT234(macro, data) MREPEAT233(macro, data) macro(233, data) +#define MREPEAT235(macro, data) MREPEAT234(macro, data) macro(234, data) +#define MREPEAT236(macro, data) MREPEAT235(macro, data) macro(235, data) +#define MREPEAT237(macro, data) MREPEAT236(macro, data) macro(236, data) +#define MREPEAT238(macro, data) MREPEAT237(macro, data) macro(237, data) +#define MREPEAT239(macro, data) MREPEAT238(macro, data) macro(238, data) +#define MREPEAT240(macro, data) MREPEAT239(macro, data) macro(239, data) +#define MREPEAT241(macro, data) MREPEAT240(macro, data) macro(240, data) +#define MREPEAT242(macro, data) MREPEAT241(macro, data) macro(241, data) +#define MREPEAT243(macro, data) MREPEAT242(macro, data) macro(242, data) +#define MREPEAT244(macro, data) MREPEAT243(macro, data) macro(243, data) +#define MREPEAT245(macro, data) MREPEAT244(macro, data) macro(244, data) +#define MREPEAT246(macro, data) MREPEAT245(macro, data) macro(245, data) +#define MREPEAT247(macro, data) MREPEAT246(macro, data) macro(246, data) +#define MREPEAT248(macro, data) MREPEAT247(macro, data) macro(247, data) +#define MREPEAT249(macro, data) MREPEAT248(macro, data) macro(248, data) +#define MREPEAT250(macro, data) MREPEAT249(macro, data) macro(249, data) +#define MREPEAT251(macro, data) MREPEAT250(macro, data) macro(250, data) +#define MREPEAT252(macro, data) MREPEAT251(macro, data) macro(251, data) +#define MREPEAT253(macro, data) MREPEAT252(macro, data) macro(252, data) +#define MREPEAT254(macro, data) MREPEAT253(macro, data) macro(253, data) +#define MREPEAT255(macro, data) MREPEAT254(macro, data) macro(254, data) +#define MREPEAT256(macro, data) MREPEAT255(macro, data) macro(255, data) + +/** @} */ + +#endif /* _MREPEAT_H_ */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/preprocessor/preprocessor.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/preprocessor/preprocessor.h new file mode 100755 index 0000000..6442651 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/preprocessor/preprocessor.h @@ -0,0 +1,52 @@ +/** + * \file + * + * \brief Preprocessor utils. + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _PREPROCESSOR_H_ +#define _PREPROCESSOR_H_ + +#include "tpaste.h" +#include "stringz.h" +#include "mrepeat.h" +#include "mrecursion.h" + +#endif // _PREPROCESSOR_H_ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/preprocessor/stringz.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/preprocessor/stringz.h new file mode 100755 index 0000000..747d6ac --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/preprocessor/stringz.h @@ -0,0 +1,81 @@ +/** + * \file + * + * \brief Preprocessor stringizing utils. + * + * Copyright (C) 2012-2013 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _STRINGZ_H_ +#define _STRINGZ_H_ + +/** + * \defgroup group_sam0_utils_stringz Preprocessor - Stringize + * + * \ingroup group_sam0_utils + * + * @{ + */ + +/** \brief Stringize. + * + * Stringize a preprocessing token, this token being allowed to be \#defined. + * + * May be used only within macros with the token passed as an argument if the + * token is \#defined. + * + * For example, writing STRINGZ(PIN) within a macro \#defined by PIN_NAME(PIN) + * and invoked as PIN_NAME(PIN0) with PIN0 \#defined as A0 is equivalent to + * writing "A0". + */ +#define STRINGZ(x) #x + +/** \brief Absolute stringize. + * + * Stringize a preprocessing token, this token being allowed to be \#defined. + * + * No restriction of use if the token is \#defined. + * + * For example, writing ASTRINGZ(PIN0) anywhere with PIN0 \#defined as A0 is + * equivalent to writing "A0". + */ +#define ASTRINGZ(x) STRINGZ(x) + +/** @} */ + +#endif // _STRINGZ_H_ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/preprocessor/tpaste.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/preprocessor/tpaste.h new file mode 100755 index 0000000..f5fddbf --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/preprocessor/tpaste.h @@ -0,0 +1,100 @@ +/** + * \file + * + * \brief Preprocessor token pasting utils. + * + * Copyright (C) 2012-2013 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _TPASTE_H_ +#define _TPASTE_H_ + +/** + * \defgroup group_sam0_utils_tpaste Preprocessor - Token Paste + * + * \ingroup group_sam0_utils + * + * @{ + */ + +/** \name Token Paste + * + * Paste N preprocessing tokens together, these tokens being allowed to be \#defined. + * + * May be used only within macros with the tokens passed as arguments if the tokens are \#defined. + * + * For example, writing TPASTE2(U, WIDTH) within a macro \#defined by + * UTYPE(WIDTH) and invoked as UTYPE(UL_WIDTH) with UL_WIDTH \#defined as 32 is + * equivalent to writing U32. + * + * @{ */ +#define TPASTE2( a, b) a##b +#define TPASTE3( a, b, c) a##b##c +#define TPASTE4( a, b, c, d) a##b##c##d +#define TPASTE5( a, b, c, d, e) a##b##c##d##e +#define TPASTE6( a, b, c, d, e, f) a##b##c##d##e##f +#define TPASTE7( a, b, c, d, e, f, g) a##b##c##d##e##f##g +#define TPASTE8( a, b, c, d, e, f, g, h) a##b##c##d##e##f##g##h +#define TPASTE9( a, b, c, d, e, f, g, h, i) a##b##c##d##e##f##g##h##i +#define TPASTE10(a, b, c, d, e, f, g, h, i, j) a##b##c##d##e##f##g##h##i##j +/** @} */ + +/** \name Absolute Token Paste + * + * Paste N preprocessing tokens together, these tokens being allowed to be \#defined. + * + * No restriction of use if the tokens are \#defined. + * + * For example, writing ATPASTE2(U, UL_WIDTH) anywhere with UL_WIDTH \#defined + * as 32 is equivalent to writing U32. + * + * @{ */ +#define ATPASTE2( a, b) TPASTE2( a, b) +#define ATPASTE3( a, b, c) TPASTE3( a, b, c) +#define ATPASTE4( a, b, c, d) TPASTE4( a, b, c, d) +#define ATPASTE5( a, b, c, d, e) TPASTE5( a, b, c, d, e) +#define ATPASTE6( a, b, c, d, e, f) TPASTE6( a, b, c, d, e, f) +#define ATPASTE7( a, b, c, d, e, f, g) TPASTE7( a, b, c, d, e, f, g) +#define ATPASTE8( a, b, c, d, e, f, g, h) TPASTE8( a, b, c, d, e, f, g, h) +#define ATPASTE9( a, b, c, d, e, f, g, h, i) TPASTE9( a, b, c, d, e, f, g, h, i) +#define ATPASTE10(a, b, c, d, e, f, g, h, i, j) TPASTE10(a, b, c, d, e, f, g, h, i, j) +/** @} */ + +/** @} */ + +#endif // _TPASTE_H_ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/status_codes.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/status_codes.h new file mode 100755 index 0000000..0df6708 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/status_codes.h @@ -0,0 +1,155 @@ +/** + * \file + * + * \brief Status code definitions. + * + * This file defines various status codes returned by functions, + * indicating success or failure as well as what kind of failure. + * + * Copyright (C) 2012-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef STATUS_CODES_H_INCLUDED +#define STATUS_CODES_H_INCLUDED + +#include + +/** + * \defgroup group_sam0_utils_status_codes Status Codes + * + * \ingroup group_sam0_utils + * + * @{ + */ + +/** Mask to retrieve the error category of a status code. */ +#define STATUS_CATEGORY_MASK 0xF0 + +/** Mask to retrieve the error code within the category of a status code. */ +#define STATUS_ERROR_MASK 0x0F + +/** Status code error categories. */ +enum status_categories { + STATUS_CATEGORY_OK = 0x00, + STATUS_CATEGORY_COMMON = 0x10, + STATUS_CATEGORY_ANALOG = 0x30, + STATUS_CATEGORY_COM = 0x40, + STATUS_CATEGORY_IO = 0x50, +}; + +/** + * Status code that may be returned by shell commands and protocol + * implementations. + * + * \note Any change to these status codes and the corresponding + * message strings is strictly forbidden. New codes can be added, + * however, but make sure that any message string tables are updated + * at the same time. + */ +enum status_code { + STATUS_OK = STATUS_CATEGORY_OK | 0x00, + STATUS_VALID_DATA = STATUS_CATEGORY_OK | 0x01, + STATUS_NO_CHANGE = STATUS_CATEGORY_OK | 0x02, + STATUS_ABORTED = STATUS_CATEGORY_OK | 0x04, + STATUS_BUSY = STATUS_CATEGORY_OK | 0x05, + STATUS_SUSPEND = STATUS_CATEGORY_OK | 0x06, + + STATUS_ERR_IO = STATUS_CATEGORY_COMMON | 0x00, + STATUS_ERR_REQ_FLUSHED = STATUS_CATEGORY_COMMON | 0x01, + STATUS_ERR_TIMEOUT = STATUS_CATEGORY_COMMON | 0x02, + STATUS_ERR_BAD_DATA = STATUS_CATEGORY_COMMON | 0x03, + STATUS_ERR_NOT_FOUND = STATUS_CATEGORY_COMMON | 0x04, + STATUS_ERR_UNSUPPORTED_DEV = STATUS_CATEGORY_COMMON | 0x05, + STATUS_ERR_NO_MEMORY = STATUS_CATEGORY_COMMON | 0x06, + STATUS_ERR_INVALID_ARG = STATUS_CATEGORY_COMMON | 0x07, + STATUS_ERR_BAD_ADDRESS = STATUS_CATEGORY_COMMON | 0x08, + STATUS_ERR_BAD_FORMAT = STATUS_CATEGORY_COMMON | 0x0A, + STATUS_ERR_BAD_FRQ = STATUS_CATEGORY_COMMON | 0x0B, + STATUS_ERR_DENIED = STATUS_CATEGORY_COMMON | 0x0c, + STATUS_ERR_ALREADY_INITIALIZED = STATUS_CATEGORY_COMMON | 0x0d, + STATUS_ERR_OVERFLOW = STATUS_CATEGORY_COMMON | 0x0e, + STATUS_ERR_NOT_INITIALIZED = STATUS_CATEGORY_COMMON | 0x0f, + + STATUS_ERR_SAMPLERATE_UNAVAILABLE = STATUS_CATEGORY_ANALOG | 0x00, + STATUS_ERR_RESOLUTION_UNAVAILABLE = STATUS_CATEGORY_ANALOG | 0x01, + + STATUS_ERR_BAUDRATE_UNAVAILABLE = STATUS_CATEGORY_COM | 0x00, + STATUS_ERR_PACKET_COLLISION = STATUS_CATEGORY_COM | 0x01, + STATUS_ERR_PROTOCOL = STATUS_CATEGORY_COM | 0x02, + + STATUS_ERR_PIN_MUX_INVALID = STATUS_CATEGORY_IO | 0x00, +}; +typedef enum status_code status_code_genare_t; + +/** + Status codes used by MAC stack. + */ +enum status_code_wireless { + //STATUS_OK = 0, //!< Success + ERR_IO_ERROR = -1, //!< I/O error + ERR_FLUSHED = -2, //!< Request flushed from queue + ERR_TIMEOUT = -3, //!< Operation timed out + ERR_BAD_DATA = -4, //!< Data integrity check failed + ERR_PROTOCOL = -5, //!< Protocol error + ERR_UNSUPPORTED_DEV = -6, //!< Unsupported device + ERR_NO_MEMORY = -7, //!< Insufficient memory + ERR_INVALID_ARG = -8, //!< Invalid argument + ERR_BAD_ADDRESS = -9, //!< Bad address + ERR_BUSY = -10, //!< Resource is busy + ERR_BAD_FORMAT = -11, //!< Data format not recognized + ERR_NO_TIMER = -12, //!< No timer available + ERR_TIMER_ALREADY_RUNNING = -13, //!< Timer already running + ERR_TIMER_NOT_RUNNING = -14, //!< Timer not running + + /** + * \brief Operation in progress + * + * This status code is for driver-internal use when an operation + * is currently being performed. + * + * \note Drivers should never return this status code to any + * callers. It is strictly for internal use. + */ + OPERATION_IN_PROGRESS = -128, +}; + +typedef enum status_code_wireless status_code_t; + +/** @} */ + +#endif /* STATUS_CODES_H_INCLUDED */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/syscalls/gcc/syscalls.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/syscalls/gcc/syscalls.c new file mode 100755 index 0000000..aa5aded --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/sam0/utils/syscalls/gcc/syscalls.c @@ -0,0 +1,128 @@ +/** + * \file + * + * \brief Syscalls for SAM0 (GCC). + * + * Copyright (C) 2012-2013 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#include +#include +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +#undef errno +extern int errno; +extern int _end; + +extern caddr_t _sbrk(int incr); +extern int link(char *old, char *new); +extern int _close(int file); +extern int _fstat(int file, struct stat *st); +extern int _isatty(int file); +extern int _lseek(int file, int ptr, int dir); +extern void _exit(int status); +extern void _kill(int pid, int sig); +extern int _getpid(void); + +extern caddr_t _sbrk(int incr) +{ + static unsigned char *heap = NULL; + unsigned char *prev_heap; + + if (heap == NULL) { + heap = (unsigned char *)&_end; + } + prev_heap = heap; + + heap += incr; + + return (caddr_t) prev_heap; +} + +extern int link(char *old, char *new) +{ + return -1; +} + +extern int _close(int file) +{ + return -1; +} + +extern int _fstat(int file, struct stat *st) +{ + st->st_mode = S_IFCHR; + + return 0; +} + +extern int _isatty(int file) +{ + return 1; +} + +extern int _lseek(int file, int ptr, int dir) +{ + return 0; +} + +extern void _exit(int status) +{ + printf("Exiting with status %d.\n", status); + + for (;;); +} + +extern void _kill(int pid, int sig) +{ + return; +} + +extern int _getpid(void) +{ + return -1; +} + +#ifdef __cplusplus +} +#endif diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/CMSIS END USER LICENCE AGREEMENT.pdf b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/CMSIS END USER LICENCE AGREEMENT.pdf new file mode 100755 index 0000000..c8feab4 Binary files /dev/null and b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/CMSIS END USER LICENCE AGREEMENT.pdf differ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/Include/arm_math.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/Include/arm_math.h new file mode 100755 index 0000000..38713fd --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/Include/arm_math.h @@ -0,0 +1,7059 @@ +/* ---------------------------------------------------------------------- + * Copyright (C) 2010-2011 ARM Limited. All rights reserved. + * + * $Date: 15. July 2011 + * $Revision: V1.0.10 + * + * Project: CMSIS DSP Library + * Title: arm_math.h + * + * Description: Public header file for CMSIS DSP Library + * + * Target Processor: Cortex-M4/Cortex-M3/Cortex-M0 + * + * Version 1.0.10 2011/7/15 + * Big Endian support added and Merged M0 and M3/M4 Source code. + * + * Version 1.0.3 2010/11/29 + * Re-organized the CMSIS folders and updated documentation. + * + * Version 1.0.2 2010/11/11 + * Documentation updated. + * + * Version 1.0.1 2010/10/05 + * Production release and review comments incorporated. + * + * Version 1.0.0 2010/09/20 + * Production release and review comments incorporated. + * -------------------------------------------------------------------- */ + +/** + \mainpage CMSIS DSP Software Library + * + * Introduction + * + * This user manual describes the CMSIS DSP software library, + * a suite of common signal processing functions for use on Cortex-M processor based devices. + * + * The library is divided into a number of modules each covering a specific category: + * - Basic math functions + * - Fast math functions + * - Complex math functions + * - Filters + * - Matrix functions + * - Transforms + * - Motor control functions + * - Statistical functions + * - Support functions + * - Interpolation functions + * + * The library has separate functions for operating on 8-bit integers, 16-bit integers, + * 32-bit integer and 32-bit floating-point values. + * + * Processor Support + * + * The library is completely written in C and is fully CMSIS compliant. + * High performance is achieved through maximum use of Cortex-M4 intrinsics. + * + * The supplied library source code also builds and runs on the Cortex-M3 and Cortex-M0 processor, + * with the DSP intrinsics being emulated through software. + * + * + * Toolchain Support + * + * The library has been developed and tested with MDK-ARM version 4.21. + * The library is being tested in GCC and IAR toolchains and updates on this activity will be made available shortly. + * + * Using the Library + * + * The library installer contains prebuilt versions of the libraries in the Lib folder. + * - arm_cortexM4lf_math.lib (Little endian and Floating Point Unit on Cortex-M4) + * - arm_cortexM4bf_math.lib (Big endian and Floating Point Unit on Cortex-M4) + * - arm_cortexM4l_math.lib (Little endian on Cortex-M4) + * - arm_cortexM4b_math.lib (Big endian on Cortex-M4) + * - arm_cortexM3l_math.lib (Little endian on Cortex-M3) + * - arm_cortexM3b_math.lib (Big endian on Cortex-M3) + * - arm_cortexM0l_math.lib (Little endian on Cortex-M0) + * - arm_cortexM0b_math.lib (Big endian on Cortex-M3) + * + * The library functions are declared in the public file arm_math.h which is placed in the Include folder. + * Simply include this file and link the appropriate library in the application and begin calling the library functions. The Library supports single + * public header file arm_math.h for Cortex-M4/M3/M0 with little endian and big endian. Same header file will be used for floating point unit(FPU) variants. + * Define the appropriate pre processor MACRO ARM_MATH_CM4 or ARM_MATH_CM3 or + * ARM_MATH_CM0 depending on the target processor in the application. + * + * Examples + * + * The library ships with a number of examples which demonstrate how to use the library functions. + * + * Building the Library + * + * The library installer contains project files to re build libraries on MDK Tool chain in the CMSIS\\DSP_Lib\\Source\\ARM folder. + * - arm_cortexM0b_math.uvproj + * - arm_cortexM0l_math.uvproj + * - arm_cortexM3b_math.uvproj + * - arm_cortexM3l_math.uvproj + * - arm_cortexM4b_math.uvproj + * - arm_cortexM4l_math.uvproj + * - arm_cortexM4bf_math.uvproj + * - arm_cortexM4lf_math.uvproj + * + * Each library project have differant pre-processor macros. + * + * ARM_MATH_CMx: + * Define macro ARM_MATH_CM4 for building the library on Cortex-M4 target, ARM_MATH_CM3 for building library on Cortex-M3 target + * and ARM_MATH_CM0 for building library on cortex-M0 target. + * + * ARM_MATH_BIG_ENDIAN: + * Define macro ARM_MATH_BIG_ENDIAN to build the library for big endian targets. By default library builds for little endian targets. + * + * ARM_MATH_MATRIX_CHECK: + * Define macro for checking on the input and output sizes of matrices + * + * ARM_MATH_ROUNDING: + * Define macro for rounding on support functions + * + * __FPU_PRESENT: + * Initialize macro __FPU_PRESENT = 1 when building on FPU supported Targets. Enable this macro for M4bf and M4lf libraries + * + * + * The project can be built by opening the appropriate project in MDK-ARM 4.21 chain and defining the optional pre processor MACROs detailed above. + * + * Copyright Notice + * + * Copyright (C) 2010 ARM Limited. All rights reserved. + */ + + +/** + * @defgroup groupMath Basic Math Functions + */ + +/** + * @defgroup groupFastMath Fast Math Functions + * This set of functions provides a fast approximation to sine, cosine, and square root. + * As compared to most of the other functions in the CMSIS math library, the fast math functions + * operate on individual values and not arrays. + * There are separate functions for Q15, Q31, and floating-point data. + * + */ + +/** + * @defgroup groupCmplxMath Complex Math Functions + * This set of functions operates on complex data vectors. + * The data in the complex arrays is stored in an interleaved fashion + * (real, imag, real, imag, ...). + * In the API functions, the number of samples in a complex array refers + * to the number of complex values; the array contains twice this number of + * real values. + */ + +/** + * @defgroup groupFilters Filtering Functions + */ + +/** + * @defgroup groupMatrix Matrix Functions + * + * This set of functions provides basic matrix math operations. + * The functions operate on matrix data structures. For example, + * the type + * definition for the floating-point matrix structure is shown + * below: + *
+ *     typedef struct
+ *     {
+ *       uint16_t numRows;     // number of rows of the matrix.
+ *       uint16_t numCols;     // number of columns of the matrix.
+ *       float32_t *pData;     // points to the data of the matrix.
+ *     } arm_matrix_instance_f32;
+ * 
+ * There are similar definitions for Q15 and Q31 data types. + * + * The structure specifies the size of the matrix and then points to + * an array of data. The array is of size numRows X numCols + * and the values are arranged in row order. That is, the + * matrix element (i, j) is stored at: + *
+ *     pData[i*numCols + j]
+ * 
+ * + * \par Init Functions + * There is an associated initialization function for each type of matrix + * data structure. + * The initialization function sets the values of the internal structure fields. + * Refer to the function arm_mat_init_f32(), arm_mat_init_q31() + * and arm_mat_init_q15() for floating-point, Q31 and Q15 types, respectively. + * + * \par + * Use of the initialization function is optional. However, if initialization function is used + * then the instance structure cannot be placed into a const data section. + * To place the instance structure in a const data + * section, manually initialize the data structure. For example: + *
+ * arm_matrix_instance_f32 S = {nRows, nColumns, pData};
+ * arm_matrix_instance_q31 S = {nRows, nColumns, pData};
+ * arm_matrix_instance_q15 S = {nRows, nColumns, pData};
+ * 
+ * where nRows specifies the number of rows, nColumns + * specifies the number of columns, and pData points to the + * data array. + * + * \par Size Checking + * By default all of the matrix functions perform size checking on the input and + * output matrices. For example, the matrix addition function verifies that the + * two input matrices and the output matrix all have the same number of rows and + * columns. If the size check fails the functions return: + *
+ *     ARM_MATH_SIZE_MISMATCH
+ * 
+ * Otherwise the functions return + *
+ *     ARM_MATH_SUCCESS
+ * 
+ * There is some overhead associated with this matrix size checking. + * The matrix size checking is enabled via the \#define + *
+ *     ARM_MATH_MATRIX_CHECK
+ * 
+ * within the library project settings. By default this macro is defined + * and size checking is enabled. By changing the project settings and + * undefining this macro size checking is eliminated and the functions + * run a bit faster. With size checking disabled the functions always + * return ARM_MATH_SUCCESS. + */ + +/** + * @defgroup groupTransforms Transform Functions + */ + +/** + * @defgroup groupController Controller Functions + */ + +/** + * @defgroup groupStats Statistics Functions + */ +/** + * @defgroup groupSupport Support Functions + */ + +/** + * @defgroup groupInterpolation Interpolation Functions + * These functions perform 1- and 2-dimensional interpolation of data. + * Linear interpolation is used for 1-dimensional data and + * bilinear interpolation is used for 2-dimensional data. + */ + +/** + * @defgroup groupExamples Examples + */ +#ifndef _ARM_MATH_H +#define _ARM_MATH_H + +#include "compiler.h" + +#define __CMSIS_GENERIC /* disable NVIC and Systick functions */ + +#if defined (ARM_MATH_CM4) + #include "core_cm4.h" +#elif defined (ARM_MATH_CM3) + #include "core_cm3.h" +#elif defined (ARM_MATH_CM0) + #include "core_cm0.h" +#else +#include "ARMCM4.h" +#warning "Define either ARM_MATH_CM4 OR ARM_MATH_CM3...By Default building on ARM_MATH_CM4....." +#endif + +#undef __CMSIS_GENERIC /* enable NVIC and Systick functions */ +#include "string.h" + #include "math.h" +#ifdef __cplusplus +extern "C" +{ +#endif + + + /** + * @brief Macros required for reciprocal calculation in Normalized LMS + */ + +#define DELTA_Q31 (0x100) +#define DELTA_Q15 0x5 +#define INDEX_MASK 0x0000003F +#define PI 3.14159265358979f + + /** + * @brief Macros required for SINE and COSINE Fast math approximations + */ + +#define TABLE_SIZE 256 +#define TABLE_SPACING_Q31 0x800000 +#define TABLE_SPACING_Q15 0x80 + + /** + * @brief Macros required for SINE and COSINE Controller functions + */ + /* 1.31(q31) Fixed value of 2/360 */ + /* -1 to +1 is divided into 360 values so total spacing is (2/360) */ +#define INPUT_SPACING 0xB60B61 + + + /** + * @brief Error status returned by some functions in the library. + */ + + typedef enum + { + ARM_MATH_SUCCESS = 0, /**< No error */ + ARM_MATH_ARGUMENT_ERROR = -1, /**< One or more arguments are incorrect */ + ARM_MATH_LENGTH_ERROR = -2, /**< Length of data buffer is incorrect */ + ARM_MATH_SIZE_MISMATCH = -3, /**< Size of matrices is not compatible with the operation. */ + ARM_MATH_NANINF = -4, /**< Not-a-number (NaN) or infinity is generated */ + ARM_MATH_SINGULAR = -5, /**< Generated by matrix inversion if the input matrix is singular and cannot be inverted. */ + ARM_MATH_TEST_FAILURE = -6 /**< Test Failed */ + } arm_status; + + /** + * @brief 8-bit fractional data type in 1.7 format. + */ + typedef int8_t q7_t; + + /** + * @brief 16-bit fractional data type in 1.15 format. + */ + typedef int16_t q15_t; + + /** + * @brief 32-bit fractional data type in 1.31 format. + */ + typedef int32_t q31_t; + + /** + * @brief 64-bit fractional data type in 1.63 format. + */ + typedef int64_t q63_t; + + /** + * @brief 32-bit floating-point type definition. + */ + typedef float float32_t; + + /** + * @brief 64-bit floating-point type definition. + */ + typedef double float64_t; + + /** + * @brief definition to read/write two 16 bit values. + */ +#define __SIMD32(addr) (*(int32_t **) & (addr)) + +#if defined (ARM_MATH_CM3) || defined (ARM_MATH_CM0) + /** + * @brief definition to pack two 16 bit values. + */ +#define __PKHBT(ARG1, ARG2, ARG3) ( (((int32_t)(ARG1) << 0) & (int32_t)0x0000FFFF) | \ + (((int32_t)(ARG2) << ARG3) & (int32_t)0xFFFF0000) ) + +#endif + + + /** + * @brief definition to pack four 8 bit values. + */ +#ifndef ARM_MATH_BIG_ENDIAN + +#define __PACKq7(v0,v1,v2,v3) ( (((int32_t)(v0) << 0) & (int32_t)0x000000FF) | \ + (((int32_t)(v1) << 8) & (int32_t)0x0000FF00) | \ + (((int32_t)(v2) << 16) & (int32_t)0x00FF0000) | \ + (((int32_t)(v3) << 24) & (int32_t)0xFF000000) ) +#else + +#define __PACKq7(v0,v1,v2,v3) ( (((int32_t)(v3) << 0) & (int32_t)0x000000FF) | \ + (((int32_t)(v2) << 8) & (int32_t)0x0000FF00) | \ + (((int32_t)(v1) << 16) & (int32_t)0x00FF0000) | \ + (((int32_t)(v0) << 24) & (int32_t)0xFF000000) ) + +#endif + + + /** + * @brief Clips Q63 to Q31 values. + */ + __STATIC_INLINE q31_t clip_q63_to_q31( + q63_t x) + { + return ((q31_t) (x >> 32) != ((q31_t) x >> 31)) ? + ((0x7FFFFFFF ^ ((q31_t) (x >> 63)))) : (q31_t) x; + } + + /** + * @brief Clips Q63 to Q15 values. + */ + __STATIC_INLINE q15_t clip_q63_to_q15( + q63_t x) + { + return ((q31_t) (x >> 32) != ((q31_t) x >> 31)) ? + ((0x7FFF ^ ((q15_t) (x >> 63)))) : (q15_t) (x >> 15); + } + + /** + * @brief Clips Q31 to Q7 values. + */ + __STATIC_INLINE q7_t clip_q31_to_q7( + q31_t x) + { + return ((q31_t) (x >> 24) != ((q31_t) x >> 23)) ? + ((0x7F ^ ((q7_t) (x >> 31)))) : (q7_t) x; + } + + /** + * @brief Clips Q31 to Q15 values. + */ + __STATIC_INLINE q15_t clip_q31_to_q15( + q31_t x) + { + return ((q31_t) (x >> 16) != ((q31_t) x >> 15)) ? + ((0x7FFF ^ ((q15_t) (x >> 31)))) : (q15_t) x; + } + + /** + * @brief Multiplies 32 X 64 and returns 32 bit result in 2.30 format. + */ + + __STATIC_INLINE q63_t mult32x64( + q63_t x, + q31_t y) + { + return ((((q63_t) (x & 0x00000000FFFFFFFF) * y) >> 32) + + (((q63_t) (x >> 32) * y))); + } + + +#if defined (ARM_MATH_CM0) && defined ( __CC_ARM ) +#define __CLZ __clz +#endif + +#if defined (ARM_MATH_CM0) && defined ( __TASKING__ ) +/* No need to redefine __CLZ */ +#endif + +#if defined (ARM_MATH_CM0) && ((defined (__ICCARM__)) ||(defined (__GNUC__)) ) + + __STATIC_INLINE uint32_t __CLZ(q31_t data); + + + __STATIC_INLINE uint32_t __CLZ(q31_t data) + { + uint32_t count = 0; + uint32_t mask = 0x80000000; + + while((data & mask) == 0) + { + count += 1u; + mask = mask >> 1u; + } + + return(count); + + } + +#endif + + /** + * @brief Function to Calculates 1/in(reciprocal) value of Q31 Data type. + */ + + __STATIC_INLINE uint32_t arm_recip_q31( + q31_t in, + q31_t * dst, + q31_t * pRecipTable) + { + + uint32_t out, tempVal; + uint32_t index, i; + uint32_t signBits; + + if(in > 0) + { + signBits = __CLZ(in) - 1; + } + else + { + signBits = __CLZ(-in) - 1; + } + + /* Convert input sample to 1.31 format */ + in = in << signBits; + + /* calculation of index for initial approximated Val */ + index = (uint32_t) (in >> 24u); + index = (index & INDEX_MASK); + + /* 1.31 with exp 1 */ + out = pRecipTable[index]; + + /* calculation of reciprocal value */ + /* running approximation for two iterations */ + for (i = 0u; i < 2u; i++) + { + tempVal = (q31_t) (((q63_t) in * out) >> 31u); + tempVal = 0x7FFFFFFF - tempVal; + /* 1.31 with exp 1 */ + //out = (q31_t) (((q63_t) out * tempVal) >> 30u); + out = (q31_t) clip_q63_to_q31(((q63_t) out * tempVal) >> 30u); + } + + /* write output */ + *dst = out; + + /* return num of signbits of out = 1/in value */ + return (signBits + 1u); + + } + + /** + * @brief Function to Calculates 1/in(reciprocal) value of Q15 Data type. + */ + __STATIC_INLINE uint32_t arm_recip_q15( + q15_t in, + q15_t * dst, + q15_t * pRecipTable) + { + + uint32_t out = 0, tempVal = 0; + uint32_t index = 0, i = 0; + uint32_t signBits = 0; + + if(in > 0) + { + signBits = __CLZ(in) - 17; + } + else + { + signBits = __CLZ(-in) - 17; + } + + /* Convert input sample to 1.15 format */ + in = in << signBits; + + /* calculation of index for initial approximated Val */ + index = in >> 8; + index = (index & INDEX_MASK); + + /* 1.15 with exp 1 */ + out = pRecipTable[index]; + + /* calculation of reciprocal value */ + /* running approximation for two iterations */ + for (i = 0; i < 2; i++) + { + tempVal = (q15_t) (((q31_t) in * out) >> 15); + tempVal = 0x7FFF - tempVal; + /* 1.15 with exp 1 */ + out = (q15_t) (((q31_t) out * tempVal) >> 14); + } + + /* write output */ + *dst = out; + + /* return num of signbits of out = 1/in value */ + return (signBits + 1); + + } + + + /* + * @brief C custom defined intrinisic function for only M0 processors + */ +#if defined(ARM_MATH_CM0) + + __STATIC_INLINE q31_t __SSAT( + q31_t x, + uint32_t y) + { + int32_t posMax, negMin; + uint32_t i; + + posMax = 1; + for (i = 0; i < (y - 1); i++) + { + posMax = posMax * 2; + } + + if(x > 0) + { + posMax = (posMax - 1); + + if(x > posMax) + { + x = posMax; + } + } + else + { + negMin = -posMax; + + if(x < negMin) + { + x = negMin; + } + } + return (x); + + + } + +#endif /* end of ARM_MATH_CM0 */ + + + + /* + * @brief C custom defined intrinsic function for M3 and M0 processors + */ +#if defined (ARM_MATH_CM3) || defined (ARM_MATH_CM0) + + /* + * @brief C custom defined QADD8 for M3 and M0 processors + */ + __STATIC_INLINE q31_t __QADD8( + q31_t x, + q31_t y) + { + + q31_t sum; + q7_t r, s, t, u; + + r = (char) x; + s = (char) y; + + r = __SSAT((q31_t) (r + s), 8); + s = __SSAT(((q31_t) (((x << 16) >> 24) + ((y << 16) >> 24))), 8); + t = __SSAT(((q31_t) (((x << 8) >> 24) + ((y << 8) >> 24))), 8); + u = __SSAT(((q31_t) ((x >> 24) + (y >> 24))), 8); + + sum = (((q31_t) u << 24) & 0xFF000000) | (((q31_t) t << 16) & 0x00FF0000) | + (((q31_t) s << 8) & 0x0000FF00) | (r & 0x000000FF); + + return sum; + + } + + /* + * @brief C custom defined QSUB8 for M3 and M0 processors + */ + __STATIC_INLINE q31_t __QSUB8( + q31_t x, + q31_t y) + { + + q31_t sum; + q31_t r, s, t, u; + + r = (char) x; + s = (char) y; + + r = __SSAT((r - s), 8); + s = __SSAT(((q31_t) (((x << 16) >> 24) - ((y << 16) >> 24))), 8) << 8; + t = __SSAT(((q31_t) (((x << 8) >> 24) - ((y << 8) >> 24))), 8) << 16; + u = __SSAT(((q31_t) ((x >> 24) - (y >> 24))), 8) << 24; + + sum = + (u & 0xFF000000) | (t & 0x00FF0000) | (s & 0x0000FF00) | (r & 0x000000FF); + + return sum; + } + + /* + * @brief C custom defined QADD16 for M3 and M0 processors + */ + + /* + * @brief C custom defined QADD16 for M3 and M0 processors + */ + __STATIC_INLINE q31_t __QADD16( + q31_t x, + q31_t y) + { + + q31_t sum; + q31_t r, s; + + r = (short) x; + s = (short) y; + + r = __SSAT(r + s, 16); + s = __SSAT(((q31_t) ((x >> 16) + (y >> 16))), 16) << 16; + + sum = (s & 0xFFFF0000) | (r & 0x0000FFFF); + + return sum; + + } + + /* + * @brief C custom defined SHADD16 for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SHADD16( + q31_t x, + q31_t y) + { + + q31_t sum; + q31_t r, s; + + r = (short) x; + s = (short) y; + + r = ((r >> 1) + (s >> 1)); + s = ((q31_t) ((x >> 17) + (y >> 17))) << 16; + + sum = (s & 0xFFFF0000) | (r & 0x0000FFFF); + + return sum; + + } + + /* + * @brief C custom defined QSUB16 for M3 and M0 processors + */ + __STATIC_INLINE q31_t __QSUB16( + q31_t x, + q31_t y) + { + + q31_t sum; + q31_t r, s; + + r = (short) x; + s = (short) y; + + r = __SSAT(r - s, 16); + s = __SSAT(((q31_t) ((x >> 16) - (y >> 16))), 16) << 16; + + sum = (s & 0xFFFF0000) | (r & 0x0000FFFF); + + return sum; + } + + /* + * @brief C custom defined SHSUB16 for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SHSUB16( + q31_t x, + q31_t y) + { + + q31_t diff; + q31_t r, s; + + r = (short) x; + s = (short) y; + + r = ((r >> 1) - (s >> 1)); + s = (((x >> 17) - (y >> 17)) << 16); + + diff = (s & 0xFFFF0000) | (r & 0x0000FFFF); + + return diff; + } + + /* + * @brief C custom defined QASX for M3 and M0 processors + */ + __STATIC_INLINE q31_t __QASX( + q31_t x, + q31_t y) + { + + q31_t sum = 0; + + sum = ((sum + clip_q31_to_q15((q31_t) ((short) (x >> 16) + (short) y))) << 16) + + clip_q31_to_q15((q31_t) ((short) x - (short) (y >> 16))); + + return sum; + } + + /* + * @brief C custom defined SHASX for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SHASX( + q31_t x, + q31_t y) + { + + q31_t sum; + q31_t r, s; + + r = (short) x; + s = (short) y; + + r = ((r >> 1) - (y >> 17)); + s = (((x >> 17) + (s >> 1)) << 16); + + sum = (s & 0xFFFF0000) | (r & 0x0000FFFF); + + return sum; + } + + + /* + * @brief C custom defined QSAX for M3 and M0 processors + */ + __STATIC_INLINE q31_t __QSAX( + q31_t x, + q31_t y) + { + + q31_t sum = 0; + + sum = ((sum + clip_q31_to_q15((q31_t) ((short) (x >> 16) - (short) y))) << 16) + + clip_q31_to_q15((q31_t) ((short) x + (short) (y >> 16))); + + return sum; + } + + /* + * @brief C custom defined SHSAX for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SHSAX( + q31_t x, + q31_t y) + { + + q31_t sum; + q31_t r, s; + + r = (short) x; + s = (short) y; + + r = ((r >> 1) + (y >> 17)); + s = (((x >> 17) - (s >> 1)) << 16); + + sum = (s & 0xFFFF0000) | (r & 0x0000FFFF); + + return sum; + } + + /* + * @brief C custom defined SMUSDX for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SMUSDX( + q31_t x, + q31_t y) + { + + return ((q31_t)(((short) x * (short) (y >> 16)) - + ((short) (x >> 16) * (short) y))); + } + + /* + * @brief C custom defined SMUADX for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SMUADX( + q31_t x, + q31_t y) + { + + return ((q31_t)(((short) x * (short) (y >> 16)) + + ((short) (x >> 16) * (short) y))); + } + + /* + * @brief C custom defined QADD for M3 and M0 processors + */ + __STATIC_INLINE q31_t __QADD( + q31_t x, + q31_t y) + { + return clip_q63_to_q31((q63_t) x + y); + } + + /* + * @brief C custom defined QSUB for M3 and M0 processors + */ + __STATIC_INLINE q31_t __QSUB( + q31_t x, + q31_t y) + { + return clip_q63_to_q31((q63_t) x - y); + } + + /* + * @brief C custom defined SMLAD for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SMLAD( + q31_t x, + q31_t y, + q31_t sum) + { + + return (sum + ((short) (x >> 16) * (short) (y >> 16)) + + ((short) x * (short) y)); + } + + /* + * @brief C custom defined SMLADX for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SMLADX( + q31_t x, + q31_t y, + q31_t sum) + { + + return (sum + ((short) (x >> 16) * (short) (y)) + + ((short) x * (short) (y >> 16))); + } + + /* + * @brief C custom defined SMLSDX for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SMLSDX( + q31_t x, + q31_t y, + q31_t sum) + { + + return (sum - ((short) (x >> 16) * (short) (y)) + + ((short) x * (short) (y >> 16))); + } + + /* + * @brief C custom defined SMLALD for M3 and M0 processors + */ + __STATIC_INLINE q63_t __SMLALD( + q31_t x, + q31_t y, + q63_t sum) + { + + return (sum + ((short) (x >> 16) * (short) (y >> 16)) + + ((short) x * (short) y)); + } + + /* + * @brief C custom defined SMLALDX for M3 and M0 processors + */ + __STATIC_INLINE q63_t __SMLALDX( + q31_t x, + q31_t y, + q63_t sum) + { + + return (sum + ((short) (x >> 16) * (short) y)) + + ((short) x * (short) (y >> 16)); + } + + /* + * @brief C custom defined SMUAD for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SMUAD( + q31_t x, + q31_t y) + { + + return (((x >> 16) * (y >> 16)) + + (((x << 16) >> 16) * ((y << 16) >> 16))); + } + + /* + * @brief C custom defined SMUSD for M3 and M0 processors + */ + __STATIC_INLINE q31_t __SMUSD( + q31_t x, + q31_t y) + { + + return (-((x >> 16) * (y >> 16)) + + (((x << 16) >> 16) * ((y << 16) >> 16))); + } + + + + +#endif /* (ARM_MATH_CM3) || defined (ARM_MATH_CM0) */ + + + /** + * @brief Instance structure for the Q7 FIR filter. + */ + typedef struct + { + uint16_t numTaps; /**< number of filter coefficients in the filter. */ + q7_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + q7_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps.*/ + } arm_fir_instance_q7; + + /** + * @brief Instance structure for the Q15 FIR filter. + */ + typedef struct + { + uint16_t numTaps; /**< number of filter coefficients in the filter. */ + q15_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + q15_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps.*/ + } arm_fir_instance_q15; + + /** + * @brief Instance structure for the Q31 FIR filter. + */ + typedef struct + { + uint16_t numTaps; /**< number of filter coefficients in the filter. */ + q31_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + q31_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps. */ + } arm_fir_instance_q31; + + /** + * @brief Instance structure for the floating-point FIR filter. + */ + typedef struct + { + uint16_t numTaps; /**< number of filter coefficients in the filter. */ + float32_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + float32_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps. */ + } arm_fir_instance_f32; + + + /** + * @brief Processing function for the Q7 FIR filter. + * @param[in] *S points to an instance of the Q7 FIR filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + void arm_fir_q7( + const arm_fir_instance_q7 * S, + q7_t * pSrc, + q7_t * pDst, + uint32_t blockSize); + + + /** + * @brief Initialization function for the Q7 FIR filter. + * @param[in,out] *S points to an instance of the Q7 FIR structure. + * @param[in] numTaps Number of filter coefficients in the filter. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of samples that are processed. + * @return none + */ + void arm_fir_init_q7( + arm_fir_instance_q7 * S, + uint16_t numTaps, + q7_t * pCoeffs, + q7_t * pState, + uint32_t blockSize); + + + /** + * @brief Processing function for the Q15 FIR filter. + * @param[in] *S points to an instance of the Q15 FIR structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + void arm_fir_q15( + const arm_fir_instance_q15 * S, + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Processing function for the fast Q15 FIR filter for Cortex-M3 and Cortex-M4. + * @param[in] *S points to an instance of the Q15 FIR filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + void arm_fir_fast_q15( + const arm_fir_instance_q15 * S, + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the Q15 FIR filter. + * @param[in,out] *S points to an instance of the Q15 FIR filter structure. + * @param[in] numTaps Number of filter coefficients in the filter. Must be even and greater than or equal to 4. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of samples that are processed at a time. + * @return The function returns ARM_MATH_SUCCESS if initialization was successful or ARM_MATH_ARGUMENT_ERROR if + * numTaps is not a supported value. + */ + + arm_status arm_fir_init_q15( + arm_fir_instance_q15 * S, + uint16_t numTaps, + q15_t * pCoeffs, + q15_t * pState, + uint32_t blockSize); + + /** + * @brief Processing function for the Q31 FIR filter. + * @param[in] *S points to an instance of the Q31 FIR filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + void arm_fir_q31( + const arm_fir_instance_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Processing function for the fast Q31 FIR filter for Cortex-M3 and Cortex-M4. + * @param[in] *S points to an instance of the Q31 FIR structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + void arm_fir_fast_q31( + const arm_fir_instance_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the Q31 FIR filter. + * @param[in,out] *S points to an instance of the Q31 FIR structure. + * @param[in] numTaps Number of filter coefficients in the filter. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of samples that are processed at a time. + * @return none. + */ + void arm_fir_init_q31( + arm_fir_instance_q31 * S, + uint16_t numTaps, + q31_t * pCoeffs, + q31_t * pState, + uint32_t blockSize); + + /** + * @brief Processing function for the floating-point FIR filter. + * @param[in] *S points to an instance of the floating-point FIR structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + void arm_fir_f32( + const arm_fir_instance_f32 * S, + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the floating-point FIR filter. + * @param[in,out] *S points to an instance of the floating-point FIR filter structure. + * @param[in] numTaps Number of filter coefficients in the filter. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of samples that are processed at a time. + * @return none. + */ + void arm_fir_init_f32( + arm_fir_instance_f32 * S, + uint16_t numTaps, + float32_t * pCoeffs, + float32_t * pState, + uint32_t blockSize); + + + /** + * @brief Instance structure for the Q15 Biquad cascade filter. + */ + typedef struct + { + int8_t numStages; /**< number of 2nd order stages in the filter. Overall order is 2*numStages. */ + q15_t *pState; /**< Points to the array of state coefficients. The array is of length 4*numStages. */ + q15_t *pCoeffs; /**< Points to the array of coefficients. The array is of length 5*numStages. */ + int8_t postShift; /**< Additional shift, in bits, applied to each output sample. */ + + } arm_biquad_casd_df1_inst_q15; + + + /** + * @brief Instance structure for the Q31 Biquad cascade filter. + */ + typedef struct + { + uint32_t numStages; /**< number of 2nd order stages in the filter. Overall order is 2*numStages. */ + q31_t *pState; /**< Points to the array of state coefficients. The array is of length 4*numStages. */ + q31_t *pCoeffs; /**< Points to the array of coefficients. The array is of length 5*numStages. */ + uint8_t postShift; /**< Additional shift, in bits, applied to each output sample. */ + + } arm_biquad_casd_df1_inst_q31; + + /** + * @brief Instance structure for the floating-point Biquad cascade filter. + */ + typedef struct + { + uint32_t numStages; /**< number of 2nd order stages in the filter. Overall order is 2*numStages. */ + float32_t *pState; /**< Points to the array of state coefficients. The array is of length 4*numStages. */ + float32_t *pCoeffs; /**< Points to the array of coefficients. The array is of length 5*numStages. */ + + + } arm_biquad_casd_df1_inst_f32; + + + + /** + * @brief Processing function for the Q15 Biquad cascade filter. + * @param[in] *S points to an instance of the Q15 Biquad cascade structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_biquad_cascade_df1_q15( + const arm_biquad_casd_df1_inst_q15 * S, + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the Q15 Biquad cascade filter. + * @param[in,out] *S points to an instance of the Q15 Biquad cascade structure. + * @param[in] numStages number of 2nd order stages in the filter. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] postShift Shift to be applied to the output. Varies according to the coefficients format + * @return none + */ + + void arm_biquad_cascade_df1_init_q15( + arm_biquad_casd_df1_inst_q15 * S, + uint8_t numStages, + q15_t * pCoeffs, + q15_t * pState, + int8_t postShift); + + + /** + * @brief Fast but less precise processing function for the Q15 Biquad cascade filter for Cortex-M3 and Cortex-M4. + * @param[in] *S points to an instance of the Q15 Biquad cascade structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_biquad_cascade_df1_fast_q15( + const arm_biquad_casd_df1_inst_q15 * S, + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + + /** + * @brief Processing function for the Q31 Biquad cascade filter + * @param[in] *S points to an instance of the Q31 Biquad cascade structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_biquad_cascade_df1_q31( + const arm_biquad_casd_df1_inst_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Fast but less precise processing function for the Q31 Biquad cascade filter for Cortex-M3 and Cortex-M4. + * @param[in] *S points to an instance of the Q31 Biquad cascade structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_biquad_cascade_df1_fast_q31( + const arm_biquad_casd_df1_inst_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the Q31 Biquad cascade filter. + * @param[in,out] *S points to an instance of the Q31 Biquad cascade structure. + * @param[in] numStages number of 2nd order stages in the filter. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] postShift Shift to be applied to the output. Varies according to the coefficients format + * @return none + */ + + void arm_biquad_cascade_df1_init_q31( + arm_biquad_casd_df1_inst_q31 * S, + uint8_t numStages, + q31_t * pCoeffs, + q31_t * pState, + int8_t postShift); + + /** + * @brief Processing function for the floating-point Biquad cascade filter. + * @param[in] *S points to an instance of the floating-point Biquad cascade structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_biquad_cascade_df1_f32( + const arm_biquad_casd_df1_inst_f32 * S, + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the floating-point Biquad cascade filter. + * @param[in,out] *S points to an instance of the floating-point Biquad cascade structure. + * @param[in] numStages number of 2nd order stages in the filter. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @return none + */ + + void arm_biquad_cascade_df1_init_f32( + arm_biquad_casd_df1_inst_f32 * S, + uint8_t numStages, + float32_t * pCoeffs, + float32_t * pState); + + + /** + * @brief Instance structure for the floating-point matrix structure. + */ + + typedef struct + { + uint16_t numRows; /**< number of rows of the matrix. */ + uint16_t numCols; /**< number of columns of the matrix. */ + float32_t *pData; /**< points to the data of the matrix. */ + } arm_matrix_instance_f32; + + /** + * @brief Instance structure for the Q15 matrix structure. + */ + + typedef struct + { + uint16_t numRows; /**< number of rows of the matrix. */ + uint16_t numCols; /**< number of columns of the matrix. */ + q15_t *pData; /**< points to the data of the matrix. */ + + } arm_matrix_instance_q15; + + /** + * @brief Instance structure for the Q31 matrix structure. + */ + + typedef struct + { + uint16_t numRows; /**< number of rows of the matrix. */ + uint16_t numCols; /**< number of columns of the matrix. */ + q31_t *pData; /**< points to the data of the matrix. */ + + } arm_matrix_instance_q31; + + + + /** + * @brief Floating-point matrix addition. + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_add_f32( + const arm_matrix_instance_f32 * pSrcA, + const arm_matrix_instance_f32 * pSrcB, + arm_matrix_instance_f32 * pDst); + + /** + * @brief Q15 matrix addition. + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_add_q15( + const arm_matrix_instance_q15 * pSrcA, + const arm_matrix_instance_q15 * pSrcB, + arm_matrix_instance_q15 * pDst); + + /** + * @brief Q31 matrix addition. + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_add_q31( + const arm_matrix_instance_q31 * pSrcA, + const arm_matrix_instance_q31 * pSrcB, + arm_matrix_instance_q31 * pDst); + + + /** + * @brief Floating-point matrix transpose. + * @param[in] *pSrc points to the input matrix + * @param[out] *pDst points to the output matrix + * @return The function returns either ARM_MATH_SIZE_MISMATCH + * or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_trans_f32( + const arm_matrix_instance_f32 * pSrc, + arm_matrix_instance_f32 * pDst); + + + /** + * @brief Q15 matrix transpose. + * @param[in] *pSrc points to the input matrix + * @param[out] *pDst points to the output matrix + * @return The function returns either ARM_MATH_SIZE_MISMATCH + * or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_trans_q15( + const arm_matrix_instance_q15 * pSrc, + arm_matrix_instance_q15 * pDst); + + /** + * @brief Q31 matrix transpose. + * @param[in] *pSrc points to the input matrix + * @param[out] *pDst points to the output matrix + * @return The function returns either ARM_MATH_SIZE_MISMATCH + * or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_trans_q31( + const arm_matrix_instance_q31 * pSrc, + arm_matrix_instance_q31 * pDst); + + + /** + * @brief Floating-point matrix multiplication + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_mult_f32( + const arm_matrix_instance_f32 * pSrcA, + const arm_matrix_instance_f32 * pSrcB, + arm_matrix_instance_f32 * pDst); + + /** + * @brief Q15 matrix multiplication + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_mult_q15( + const arm_matrix_instance_q15 * pSrcA, + const arm_matrix_instance_q15 * pSrcB, + arm_matrix_instance_q15 * pDst, + q15_t * pState); + + /** + * @brief Q15 matrix multiplication (fast variant) for Cortex-M3 and Cortex-M4 + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @param[in] *pState points to the array for storing intermediate results + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_mult_fast_q15( + const arm_matrix_instance_q15 * pSrcA, + const arm_matrix_instance_q15 * pSrcB, + arm_matrix_instance_q15 * pDst, + q15_t * pState); + + /** + * @brief Q31 matrix multiplication + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_mult_q31( + const arm_matrix_instance_q31 * pSrcA, + const arm_matrix_instance_q31 * pSrcB, + arm_matrix_instance_q31 * pDst); + + /** + * @brief Q31 matrix multiplication (fast variant) for Cortex-M3 and Cortex-M4 + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_mult_fast_q31( + const arm_matrix_instance_q31 * pSrcA, + const arm_matrix_instance_q31 * pSrcB, + arm_matrix_instance_q31 * pDst); + + + /** + * @brief Floating-point matrix subtraction + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_sub_f32( + const arm_matrix_instance_f32 * pSrcA, + const arm_matrix_instance_f32 * pSrcB, + arm_matrix_instance_f32 * pDst); + + /** + * @brief Q15 matrix subtraction + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_sub_q15( + const arm_matrix_instance_q15 * pSrcA, + const arm_matrix_instance_q15 * pSrcB, + arm_matrix_instance_q15 * pDst); + + /** + * @brief Q31 matrix subtraction + * @param[in] *pSrcA points to the first input matrix structure + * @param[in] *pSrcB points to the second input matrix structure + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_sub_q31( + const arm_matrix_instance_q31 * pSrcA, + const arm_matrix_instance_q31 * pSrcB, + arm_matrix_instance_q31 * pDst); + + /** + * @brief Floating-point matrix scaling. + * @param[in] *pSrc points to the input matrix + * @param[in] scale scale factor + * @param[out] *pDst points to the output matrix + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_scale_f32( + const arm_matrix_instance_f32 * pSrc, + float32_t scale, + arm_matrix_instance_f32 * pDst); + + /** + * @brief Q15 matrix scaling. + * @param[in] *pSrc points to input matrix + * @param[in] scaleFract fractional portion of the scale factor + * @param[in] shift number of bits to shift the result by + * @param[out] *pDst points to output matrix + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_scale_q15( + const arm_matrix_instance_q15 * pSrc, + q15_t scaleFract, + int32_t shift, + arm_matrix_instance_q15 * pDst); + + /** + * @brief Q31 matrix scaling. + * @param[in] *pSrc points to input matrix + * @param[in] scaleFract fractional portion of the scale factor + * @param[in] shift number of bits to shift the result by + * @param[out] *pDst points to output matrix structure + * @return The function returns either + * ARM_MATH_SIZE_MISMATCH or ARM_MATH_SUCCESS based on the outcome of size checking. + */ + + arm_status arm_mat_scale_q31( + const arm_matrix_instance_q31 * pSrc, + q31_t scaleFract, + int32_t shift, + arm_matrix_instance_q31 * pDst); + + + /** + * @brief Q31 matrix initialization. + * @param[in,out] *S points to an instance of the floating-point matrix structure. + * @param[in] nRows number of rows in the matrix. + * @param[in] nColumns number of columns in the matrix. + * @param[in] *pData points to the matrix data array. + * @return none + */ + + void arm_mat_init_q31( + arm_matrix_instance_q31 * S, + uint16_t nRows, + uint16_t nColumns, + q31_t *pData); + + /** + * @brief Q15 matrix initialization. + * @param[in,out] *S points to an instance of the floating-point matrix structure. + * @param[in] nRows number of rows in the matrix. + * @param[in] nColumns number of columns in the matrix. + * @param[in] *pData points to the matrix data array. + * @return none + */ + + void arm_mat_init_q15( + arm_matrix_instance_q15 * S, + uint16_t nRows, + uint16_t nColumns, + q15_t *pData); + + /** + * @brief Floating-point matrix initialization. + * @param[in,out] *S points to an instance of the floating-point matrix structure. + * @param[in] nRows number of rows in the matrix. + * @param[in] nColumns number of columns in the matrix. + * @param[in] *pData points to the matrix data array. + * @return none + */ + + void arm_mat_init_f32( + arm_matrix_instance_f32 * S, + uint16_t nRows, + uint16_t nColumns, + float32_t *pData); + + + + /** + * @brief Instance structure for the Q15 PID Control. + */ + typedef struct + { + q15_t A0; /**< The derived gain, A0 = Kp + Ki + Kd . */ + #ifdef ARM_MATH_CM0 + q15_t A1; + q15_t A2; + #else + q31_t A1; /**< The derived gain A1 = -Kp - 2Kd | Kd.*/ + #endif + q15_t state[3]; /**< The state array of length 3. */ + q15_t Kp; /**< The proportional gain. */ + q15_t Ki; /**< The integral gain. */ + q15_t Kd; /**< The derivative gain. */ + } arm_pid_instance_q15; + + /** + * @brief Instance structure for the Q31 PID Control. + */ + typedef struct + { + q31_t A0; /**< The derived gain, A0 = Kp + Ki + Kd . */ + q31_t A1; /**< The derived gain, A1 = -Kp - 2Kd. */ + q31_t A2; /**< The derived gain, A2 = Kd . */ + q31_t state[3]; /**< The state array of length 3. */ + q31_t Kp; /**< The proportional gain. */ + q31_t Ki; /**< The integral gain. */ + q31_t Kd; /**< The derivative gain. */ + + } arm_pid_instance_q31; + + /** + * @brief Instance structure for the floating-point PID Control. + */ + typedef struct + { + float32_t A0; /**< The derived gain, A0 = Kp + Ki + Kd . */ + float32_t A1; /**< The derived gain, A1 = -Kp - 2Kd. */ + float32_t A2; /**< The derived gain, A2 = Kd . */ + float32_t state[3]; /**< The state array of length 3. */ + float32_t Kp; /**< The proportional gain. */ + float32_t Ki; /**< The integral gain. */ + float32_t Kd; /**< The derivative gain. */ + } arm_pid_instance_f32; + + + + /** + * @brief Initialization function for the floating-point PID Control. + * @param[in,out] *S points to an instance of the PID structure. + * @param[in] resetStateFlag flag to reset the state. 0 = no change in state 1 = reset the state. + * @return none. + */ + void arm_pid_init_f32( + arm_pid_instance_f32 * S, + int32_t resetStateFlag); + + /** + * @brief Reset function for the floating-point PID Control. + * @param[in,out] *S is an instance of the floating-point PID Control structure + * @return none + */ + void arm_pid_reset_f32( + arm_pid_instance_f32 * S); + + + /** + * @brief Initialization function for the Q31 PID Control. + * @param[in,out] *S points to an instance of the Q15 PID structure. + * @param[in] resetStateFlag flag to reset the state. 0 = no change in state 1 = reset the state. + * @return none. + */ + void arm_pid_init_q31( + arm_pid_instance_q31 * S, + int32_t resetStateFlag); + + + /** + * @brief Reset function for the Q31 PID Control. + * @param[in,out] *S points to an instance of the Q31 PID Control structure + * @return none + */ + + void arm_pid_reset_q31( + arm_pid_instance_q31 * S); + + /** + * @brief Initialization function for the Q15 PID Control. + * @param[in,out] *S points to an instance of the Q15 PID structure. + * @param[in] resetStateFlag flag to reset the state. 0 = no change in state 1 = reset the state. + * @return none. + */ + void arm_pid_init_q15( + arm_pid_instance_q15 * S, + int32_t resetStateFlag); + + /** + * @brief Reset function for the Q15 PID Control. + * @param[in,out] *S points to an instance of the q15 PID Control structure + * @return none + */ + void arm_pid_reset_q15( + arm_pid_instance_q15 * S); + + + /** + * @brief Instance structure for the floating-point Linear Interpolate function. + */ + typedef struct + { + uint32_t nValues; /**< nValues */ + float32_t x1; /**< x1 */ + float32_t xSpacing; /**< xSpacing */ + float32_t *pYData; /**< pointer to the table of Y values */ + } arm_linear_interp_instance_f32; + + /** + * @brief Instance structure for the floating-point bilinear interpolation function. + */ + + typedef struct + { + uint16_t numRows; /**< number of rows in the data table. */ + uint16_t numCols; /**< number of columns in the data table. */ + float32_t *pData; /**< points to the data table. */ + } arm_bilinear_interp_instance_f32; + + /** + * @brief Instance structure for the Q31 bilinear interpolation function. + */ + + typedef struct + { + uint16_t numRows; /**< number of rows in the data table. */ + uint16_t numCols; /**< number of columns in the data table. */ + q31_t *pData; /**< points to the data table. */ + } arm_bilinear_interp_instance_q31; + + /** + * @brief Instance structure for the Q15 bilinear interpolation function. + */ + + typedef struct + { + uint16_t numRows; /**< number of rows in the data table. */ + uint16_t numCols; /**< number of columns in the data table. */ + q15_t *pData; /**< points to the data table. */ + } arm_bilinear_interp_instance_q15; + + /** + * @brief Instance structure for the Q15 bilinear interpolation function. + */ + + typedef struct + { + uint16_t numRows; /**< number of rows in the data table. */ + uint16_t numCols; /**< number of columns in the data table. */ + q7_t *pData; /**< points to the data table. */ + } arm_bilinear_interp_instance_q7; + + + /** + * @brief Q7 vector multiplication. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_mult_q7( + q7_t * pSrcA, + q7_t * pSrcB, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Q15 vector multiplication. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_mult_q15( + q15_t * pSrcA, + q15_t * pSrcB, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Q31 vector multiplication. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_mult_q31( + q31_t * pSrcA, + q31_t * pSrcB, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Floating-point vector multiplication. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_mult_f32( + float32_t * pSrcA, + float32_t * pSrcB, + float32_t * pDst, + uint32_t blockSize); + + + /** + * @brief Instance structure for the Q15 CFFT/CIFFT function. + */ + + typedef struct + { + uint16_t fftLen; /**< length of the FFT. */ + uint8_t ifftFlag; /**< flag that selects forward (ifftFlag=0) or inverse (ifftFlag=1) transform. */ + uint8_t bitReverseFlag; /**< flag that enables (bitReverseFlag=1) or disables (bitReverseFlag=0) bit reversal of output. */ + q15_t *pTwiddle; /**< points to the twiddle factor table. */ + uint16_t *pBitRevTable; /**< points to the bit reversal table. */ + uint16_t twidCoefModifier; /**< twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. */ + uint16_t bitRevFactor; /**< bit reversal modifier that supports different size FFTs with the same bit reversal table. */ + } arm_cfft_radix4_instance_q15; + + /** + * @brief Instance structure for the Q31 CFFT/CIFFT function. + */ + + typedef struct + { + uint16_t fftLen; /**< length of the FFT. */ + uint8_t ifftFlag; /**< flag that selects forward (ifftFlag=0) or inverse (ifftFlag=1) transform. */ + uint8_t bitReverseFlag; /**< flag that enables (bitReverseFlag=1) or disables (bitReverseFlag=0) bit reversal of output. */ + q31_t *pTwiddle; /**< points to the twiddle factor table. */ + uint16_t *pBitRevTable; /**< points to the bit reversal table. */ + uint16_t twidCoefModifier; /**< twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. */ + uint16_t bitRevFactor; /**< bit reversal modifier that supports different size FFTs with the same bit reversal table. */ + } arm_cfft_radix4_instance_q31; + + /** + * @brief Instance structure for the floating-point CFFT/CIFFT function. + */ + + typedef struct + { + uint16_t fftLen; /**< length of the FFT. */ + uint8_t ifftFlag; /**< flag that selects forward (ifftFlag=0) or inverse (ifftFlag=1) transform. */ + uint8_t bitReverseFlag; /**< flag that enables (bitReverseFlag=1) or disables (bitReverseFlag=0) bit reversal of output. */ + float32_t *pTwiddle; /**< points to the twiddle factor table. */ + uint16_t *pBitRevTable; /**< points to the bit reversal table. */ + uint16_t twidCoefModifier; /**< twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. */ + uint16_t bitRevFactor; /**< bit reversal modifier that supports different size FFTs with the same bit reversal table. */ + float32_t onebyfftLen; /**< value of 1/fftLen. */ + } arm_cfft_radix4_instance_f32; + + /** + * @brief Processing function for the Q15 CFFT/CIFFT. + * @param[in] *S points to an instance of the Q15 CFFT/CIFFT structure. + * @param[in, out] *pSrc points to the complex data buffer. Processing occurs in-place. + * @return none. + */ + + void arm_cfft_radix4_q15( + const arm_cfft_radix4_instance_q15 * S, + q15_t * pSrc); + + /** + * @brief Initialization function for the Q15 CFFT/CIFFT. + * @param[in,out] *S points to an instance of the Q15 CFFT/CIFFT structure. + * @param[in] fftLen length of the FFT. + * @param[in] ifftFlag flag that selects forward (ifftFlag=0) or inverse (ifftFlag=1) transform. + * @param[in] bitReverseFlag flag that enables (bitReverseFlag=1) or disables (bitReverseFlag=0) bit reversal of output. + * @return arm_status function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_ARGUMENT_ERROR if fftLen is not a supported value. + */ + + arm_status arm_cfft_radix4_init_q15( + arm_cfft_radix4_instance_q15 * S, + uint16_t fftLen, + uint8_t ifftFlag, + uint8_t bitReverseFlag); + + /** + * @brief Processing function for the Q31 CFFT/CIFFT. + * @param[in] *S points to an instance of the Q31 CFFT/CIFFT structure. + * @param[in, out] *pSrc points to the complex data buffer. Processing occurs in-place. + * @return none. + */ + + void arm_cfft_radix4_q31( + const arm_cfft_radix4_instance_q31 * S, + q31_t * pSrc); + + /** + * @brief Initialization function for the Q31 CFFT/CIFFT. + * @param[in,out] *S points to an instance of the Q31 CFFT/CIFFT structure. + * @param[in] fftLen length of the FFT. + * @param[in] ifftFlag flag that selects forward (ifftFlag=0) or inverse (ifftFlag=1) transform. + * @param[in] bitReverseFlag flag that enables (bitReverseFlag=1) or disables (bitReverseFlag=0) bit reversal of output. + * @return arm_status function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_ARGUMENT_ERROR if fftLen is not a supported value. + */ + + arm_status arm_cfft_radix4_init_q31( + arm_cfft_radix4_instance_q31 * S, + uint16_t fftLen, + uint8_t ifftFlag, + uint8_t bitReverseFlag); + + /** + * @brief Processing function for the floating-point CFFT/CIFFT. + * @param[in] *S points to an instance of the floating-point CFFT/CIFFT structure. + * @param[in, out] *pSrc points to the complex data buffer. Processing occurs in-place. + * @return none. + */ + + void arm_cfft_radix4_f32( + const arm_cfft_radix4_instance_f32 * S, + float32_t * pSrc); + + /** + * @brief Initialization function for the floating-point CFFT/CIFFT. + * @param[in,out] *S points to an instance of the floating-point CFFT/CIFFT structure. + * @param[in] fftLen length of the FFT. + * @param[in] ifftFlag flag that selects forward (ifftFlag=0) or inverse (ifftFlag=1) transform. + * @param[in] bitReverseFlag flag that enables (bitReverseFlag=1) or disables (bitReverseFlag=0) bit reversal of output. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_ARGUMENT_ERROR if fftLen is not a supported value. + */ + + arm_status arm_cfft_radix4_init_f32( + arm_cfft_radix4_instance_f32 * S, + uint16_t fftLen, + uint8_t ifftFlag, + uint8_t bitReverseFlag); + + + + /*---------------------------------------------------------------------- + * Internal functions prototypes FFT function + ----------------------------------------------------------------------*/ + + /** + * @brief Core function for the floating-point CFFT butterfly process. + * @param[in, out] *pSrc points to the in-place buffer of floating-point data type. + * @param[in] fftLen length of the FFT. + * @param[in] *pCoef points to the twiddle coefficient buffer. + * @param[in] twidCoefModifier twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. + * @return none. + */ + + void arm_radix4_butterfly_f32( + float32_t * pSrc, + uint16_t fftLen, + float32_t * pCoef, + uint16_t twidCoefModifier); + + /** + * @brief Core function for the floating-point CIFFT butterfly process. + * @param[in, out] *pSrc points to the in-place buffer of floating-point data type. + * @param[in] fftLen length of the FFT. + * @param[in] *pCoef points to twiddle coefficient buffer. + * @param[in] twidCoefModifier twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. + * @param[in] onebyfftLen value of 1/fftLen. + * @return none. + */ + + void arm_radix4_butterfly_inverse_f32( + float32_t * pSrc, + uint16_t fftLen, + float32_t * pCoef, + uint16_t twidCoefModifier, + float32_t onebyfftLen); + + /** + * @brief In-place bit reversal function. + * @param[in, out] *pSrc points to the in-place buffer of floating-point data type. + * @param[in] fftSize length of the FFT. + * @param[in] bitRevFactor bit reversal modifier that supports different size FFTs with the same bit reversal table. + * @param[in] *pBitRevTab points to the bit reversal table. + * @return none. + */ + + void arm_bitreversal_f32( + float32_t *pSrc, + uint16_t fftSize, + uint16_t bitRevFactor, + uint16_t *pBitRevTab); + + /** + * @brief Core function for the Q31 CFFT butterfly process. + * @param[in, out] *pSrc points to the in-place buffer of Q31 data type. + * @param[in] fftLen length of the FFT. + * @param[in] *pCoef points to twiddle coefficient buffer. + * @param[in] twidCoefModifier twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. + * @return none. + */ + + void arm_radix4_butterfly_q31( + q31_t *pSrc, + uint32_t fftLen, + q31_t *pCoef, + uint32_t twidCoefModifier); + + /** + * @brief Core function for the Q31 CIFFT butterfly process. + * @param[in, out] *pSrc points to the in-place buffer of Q31 data type. + * @param[in] fftLen length of the FFT. + * @param[in] *pCoef points to twiddle coefficient buffer. + * @param[in] twidCoefModifier twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. + * @return none. + */ + + void arm_radix4_butterfly_inverse_q31( + q31_t * pSrc, + uint32_t fftLen, + q31_t * pCoef, + uint32_t twidCoefModifier); + + /** + * @brief In-place bit reversal function. + * @param[in, out] *pSrc points to the in-place buffer of Q31 data type. + * @param[in] fftLen length of the FFT. + * @param[in] bitRevFactor bit reversal modifier that supports different size FFTs with the same bit reversal table + * @param[in] *pBitRevTab points to bit reversal table. + * @return none. + */ + + void arm_bitreversal_q31( + q31_t * pSrc, + uint32_t fftLen, + uint16_t bitRevFactor, + uint16_t *pBitRevTab); + + /** + * @brief Core function for the Q15 CFFT butterfly process. + * @param[in, out] *pSrc16 points to the in-place buffer of Q15 data type. + * @param[in] fftLen length of the FFT. + * @param[in] *pCoef16 points to twiddle coefficient buffer. + * @param[in] twidCoefModifier twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. + * @return none. + */ + + void arm_radix4_butterfly_q15( + q15_t *pSrc16, + uint32_t fftLen, + q15_t *pCoef16, + uint32_t twidCoefModifier); + + /** + * @brief Core function for the Q15 CIFFT butterfly process. + * @param[in, out] *pSrc16 points to the in-place buffer of Q15 data type. + * @param[in] fftLen length of the FFT. + * @param[in] *pCoef16 points to twiddle coefficient buffer. + * @param[in] twidCoefModifier twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. + * @return none. + */ + + void arm_radix4_butterfly_inverse_q15( + q15_t *pSrc16, + uint32_t fftLen, + q15_t *pCoef16, + uint32_t twidCoefModifier); + + /** + * @brief In-place bit reversal function. + * @param[in, out] *pSrc points to the in-place buffer of Q15 data type. + * @param[in] fftLen length of the FFT. + * @param[in] bitRevFactor bit reversal modifier that supports different size FFTs with the same bit reversal table + * @param[in] *pBitRevTab points to bit reversal table. + * @return none. + */ + + void arm_bitreversal_q15( + q15_t * pSrc, + uint32_t fftLen, + uint16_t bitRevFactor, + uint16_t *pBitRevTab); + + /** + * @brief Instance structure for the Q15 RFFT/RIFFT function. + */ + + typedef struct + { + uint32_t fftLenReal; /**< length of the real FFT. */ + uint32_t fftLenBy2; /**< length of the complex FFT. */ + uint8_t ifftFlagR; /**< flag that selects forward (ifftFlagR=0) or inverse (ifftFlagR=1) transform. */ + uint8_t bitReverseFlagR; /**< flag that enables (bitReverseFlagR=1) or disables (bitReverseFlagR=0) bit reversal of output. */ + uint32_t twidCoefRModifier; /**< twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. */ + q15_t *pTwiddleAReal; /**< points to the real twiddle factor table. */ + q15_t *pTwiddleBReal; /**< points to the imag twiddle factor table. */ + arm_cfft_radix4_instance_q15 *pCfft; /**< points to the complex FFT instance. */ + } arm_rfft_instance_q15; + + /** + * @brief Instance structure for the Q31 RFFT/RIFFT function. + */ + + typedef struct + { + uint32_t fftLenReal; /**< length of the real FFT. */ + uint32_t fftLenBy2; /**< length of the complex FFT. */ + uint8_t ifftFlagR; /**< flag that selects forward (ifftFlagR=0) or inverse (ifftFlagR=1) transform. */ + uint8_t bitReverseFlagR; /**< flag that enables (bitReverseFlagR=1) or disables (bitReverseFlagR=0) bit reversal of output. */ + uint32_t twidCoefRModifier; /**< twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. */ + q31_t *pTwiddleAReal; /**< points to the real twiddle factor table. */ + q31_t *pTwiddleBReal; /**< points to the imag twiddle factor table. */ + arm_cfft_radix4_instance_q31 *pCfft; /**< points to the complex FFT instance. */ + } arm_rfft_instance_q31; + + /** + * @brief Instance structure for the floating-point RFFT/RIFFT function. + */ + + typedef struct + { + uint32_t fftLenReal; /**< length of the real FFT. */ + uint16_t fftLenBy2; /**< length of the complex FFT. */ + uint8_t ifftFlagR; /**< flag that selects forward (ifftFlagR=0) or inverse (ifftFlagR=1) transform. */ + uint8_t bitReverseFlagR; /**< flag that enables (bitReverseFlagR=1) or disables (bitReverseFlagR=0) bit reversal of output. */ + uint32_t twidCoefRModifier; /**< twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table. */ + float32_t *pTwiddleAReal; /**< points to the real twiddle factor table. */ + float32_t *pTwiddleBReal; /**< points to the imag twiddle factor table. */ + arm_cfft_radix4_instance_f32 *pCfft; /**< points to the complex FFT instance. */ + } arm_rfft_instance_f32; + + /** + * @brief Processing function for the Q15 RFFT/RIFFT. + * @param[in] *S points to an instance of the Q15 RFFT/RIFFT structure. + * @param[in] *pSrc points to the input buffer. + * @param[out] *pDst points to the output buffer. + * @return none. + */ + + void arm_rfft_q15( + const arm_rfft_instance_q15 * S, + q15_t * pSrc, + q15_t * pDst); + + /** + * @brief Initialization function for the Q15 RFFT/RIFFT. + * @param[in, out] *S points to an instance of the Q15 RFFT/RIFFT structure. + * @param[in] *S_CFFT points to an instance of the Q15 CFFT/CIFFT structure. + * @param[in] fftLenReal length of the FFT. + * @param[in] ifftFlagR flag that selects forward (ifftFlagR=0) or inverse (ifftFlagR=1) transform. + * @param[in] bitReverseFlag flag that enables (bitReverseFlag=1) or disables (bitReverseFlag=0) bit reversal of output. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_ARGUMENT_ERROR if fftLenReal is not a supported value. + */ + + arm_status arm_rfft_init_q15( + arm_rfft_instance_q15 * S, + arm_cfft_radix4_instance_q15 * S_CFFT, + uint32_t fftLenReal, + uint32_t ifftFlagR, + uint32_t bitReverseFlag); + + /** + * @brief Processing function for the Q31 RFFT/RIFFT. + * @param[in] *S points to an instance of the Q31 RFFT/RIFFT structure. + * @param[in] *pSrc points to the input buffer. + * @param[out] *pDst points to the output buffer. + * @return none. + */ + + void arm_rfft_q31( + const arm_rfft_instance_q31 * S, + q31_t * pSrc, + q31_t * pDst); + + /** + * @brief Initialization function for the Q31 RFFT/RIFFT. + * @param[in, out] *S points to an instance of the Q31 RFFT/RIFFT structure. + * @param[in, out] *S_CFFT points to an instance of the Q31 CFFT/CIFFT structure. + * @param[in] fftLenReal length of the FFT. + * @param[in] ifftFlagR flag that selects forward (ifftFlagR=0) or inverse (ifftFlagR=1) transform. + * @param[in] bitReverseFlag flag that enables (bitReverseFlag=1) or disables (bitReverseFlag=0) bit reversal of output. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_ARGUMENT_ERROR if fftLenReal is not a supported value. + */ + + arm_status arm_rfft_init_q31( + arm_rfft_instance_q31 * S, + arm_cfft_radix4_instance_q31 * S_CFFT, + uint32_t fftLenReal, + uint32_t ifftFlagR, + uint32_t bitReverseFlag); + + /** + * @brief Initialization function for the floating-point RFFT/RIFFT. + * @param[in,out] *S points to an instance of the floating-point RFFT/RIFFT structure. + * @param[in,out] *S_CFFT points to an instance of the floating-point CFFT/CIFFT structure. + * @param[in] fftLenReal length of the FFT. + * @param[in] ifftFlagR flag that selects forward (ifftFlagR=0) or inverse (ifftFlagR=1) transform. + * @param[in] bitReverseFlag flag that enables (bitReverseFlag=1) or disables (bitReverseFlag=0) bit reversal of output. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_ARGUMENT_ERROR if fftLenReal is not a supported value. + */ + + arm_status arm_rfft_init_f32( + arm_rfft_instance_f32 * S, + arm_cfft_radix4_instance_f32 * S_CFFT, + uint32_t fftLenReal, + uint32_t ifftFlagR, + uint32_t bitReverseFlag); + + /** + * @brief Processing function for the floating-point RFFT/RIFFT. + * @param[in] *S points to an instance of the floating-point RFFT/RIFFT structure. + * @param[in] *pSrc points to the input buffer. + * @param[out] *pDst points to the output buffer. + * @return none. + */ + + void arm_rfft_f32( + const arm_rfft_instance_f32 * S, + float32_t * pSrc, + float32_t * pDst); + + /** + * @brief Instance structure for the floating-point DCT4/IDCT4 function. + */ + + typedef struct + { + uint16_t N; /**< length of the DCT4. */ + uint16_t Nby2; /**< half of the length of the DCT4. */ + float32_t normalize; /**< normalizing factor. */ + float32_t *pTwiddle; /**< points to the twiddle factor table. */ + float32_t *pCosFactor; /**< points to the cosFactor table. */ + arm_rfft_instance_f32 *pRfft; /**< points to the real FFT instance. */ + arm_cfft_radix4_instance_f32 *pCfft; /**< points to the complex FFT instance. */ + } arm_dct4_instance_f32; + + /** + * @brief Initialization function for the floating-point DCT4/IDCT4. + * @param[in,out] *S points to an instance of floating-point DCT4/IDCT4 structure. + * @param[in] *S_RFFT points to an instance of floating-point RFFT/RIFFT structure. + * @param[in] *S_CFFT points to an instance of floating-point CFFT/CIFFT structure. + * @param[in] N length of the DCT4. + * @param[in] Nby2 half of the length of the DCT4. + * @param[in] normalize normalizing factor. + * @return arm_status function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_ARGUMENT_ERROR if fftLenReal is not a supported transform length. + */ + + arm_status arm_dct4_init_f32( + arm_dct4_instance_f32 * S, + arm_rfft_instance_f32 * S_RFFT, + arm_cfft_radix4_instance_f32 * S_CFFT, + uint16_t N, + uint16_t Nby2, + float32_t normalize); + + /** + * @brief Processing function for the floating-point DCT4/IDCT4. + * @param[in] *S points to an instance of the floating-point DCT4/IDCT4 structure. + * @param[in] *pState points to state buffer. + * @param[in,out] *pInlineBuffer points to the in-place input and output buffer. + * @return none. + */ + + void arm_dct4_f32( + const arm_dct4_instance_f32 * S, + float32_t * pState, + float32_t * pInlineBuffer); + + /** + * @brief Instance structure for the Q31 DCT4/IDCT4 function. + */ + + typedef struct + { + uint16_t N; /**< length of the DCT4. */ + uint16_t Nby2; /**< half of the length of the DCT4. */ + q31_t normalize; /**< normalizing factor. */ + q31_t *pTwiddle; /**< points to the twiddle factor table. */ + q31_t *pCosFactor; /**< points to the cosFactor table. */ + arm_rfft_instance_q31 *pRfft; /**< points to the real FFT instance. */ + arm_cfft_radix4_instance_q31 *pCfft; /**< points to the complex FFT instance. */ + } arm_dct4_instance_q31; + + /** + * @brief Initialization function for the Q31 DCT4/IDCT4. + * @param[in,out] *S points to an instance of Q31 DCT4/IDCT4 structure. + * @param[in] *S_RFFT points to an instance of Q31 RFFT/RIFFT structure + * @param[in] *S_CFFT points to an instance of Q31 CFFT/CIFFT structure + * @param[in] N length of the DCT4. + * @param[in] Nby2 half of the length of the DCT4. + * @param[in] normalize normalizing factor. + * @return arm_status function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_ARGUMENT_ERROR if N is not a supported transform length. + */ + + arm_status arm_dct4_init_q31( + arm_dct4_instance_q31 * S, + arm_rfft_instance_q31 * S_RFFT, + arm_cfft_radix4_instance_q31 * S_CFFT, + uint16_t N, + uint16_t Nby2, + q31_t normalize); + + /** + * @brief Processing function for the Q31 DCT4/IDCT4. + * @param[in] *S points to an instance of the Q31 DCT4 structure. + * @param[in] *pState points to state buffer. + * @param[in,out] *pInlineBuffer points to the in-place input and output buffer. + * @return none. + */ + + void arm_dct4_q31( + const arm_dct4_instance_q31 * S, + q31_t * pState, + q31_t * pInlineBuffer); + + /** + * @brief Instance structure for the Q15 DCT4/IDCT4 function. + */ + + typedef struct + { + uint16_t N; /**< length of the DCT4. */ + uint16_t Nby2; /**< half of the length of the DCT4. */ + q15_t normalize; /**< normalizing factor. */ + q15_t *pTwiddle; /**< points to the twiddle factor table. */ + q15_t *pCosFactor; /**< points to the cosFactor table. */ + arm_rfft_instance_q15 *pRfft; /**< points to the real FFT instance. */ + arm_cfft_radix4_instance_q15 *pCfft; /**< points to the complex FFT instance. */ + } arm_dct4_instance_q15; + + /** + * @brief Initialization function for the Q15 DCT4/IDCT4. + * @param[in,out] *S points to an instance of Q15 DCT4/IDCT4 structure. + * @param[in] *S_RFFT points to an instance of Q15 RFFT/RIFFT structure. + * @param[in] *S_CFFT points to an instance of Q15 CFFT/CIFFT structure. + * @param[in] N length of the DCT4. + * @param[in] Nby2 half of the length of the DCT4. + * @param[in] normalize normalizing factor. + * @return arm_status function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_ARGUMENT_ERROR if N is not a supported transform length. + */ + + arm_status arm_dct4_init_q15( + arm_dct4_instance_q15 * S, + arm_rfft_instance_q15 * S_RFFT, + arm_cfft_radix4_instance_q15 * S_CFFT, + uint16_t N, + uint16_t Nby2, + q15_t normalize); + + /** + * @brief Processing function for the Q15 DCT4/IDCT4. + * @param[in] *S points to an instance of the Q15 DCT4 structure. + * @param[in] *pState points to state buffer. + * @param[in,out] *pInlineBuffer points to the in-place input and output buffer. + * @return none. + */ + + void arm_dct4_q15( + const arm_dct4_instance_q15 * S, + q15_t * pState, + q15_t * pInlineBuffer); + + /** + * @brief Floating-point vector addition. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_add_f32( + float32_t * pSrcA, + float32_t * pSrcB, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Q7 vector addition. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_add_q7( + q7_t * pSrcA, + q7_t * pSrcB, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Q15 vector addition. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_add_q15( + q15_t * pSrcA, + q15_t * pSrcB, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Q31 vector addition. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_add_q31( + q31_t * pSrcA, + q31_t * pSrcB, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Floating-point vector subtraction. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_sub_f32( + float32_t * pSrcA, + float32_t * pSrcB, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Q7 vector subtraction. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_sub_q7( + q7_t * pSrcA, + q7_t * pSrcB, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Q15 vector subtraction. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_sub_q15( + q15_t * pSrcA, + q15_t * pSrcB, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Q31 vector subtraction. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_sub_q31( + q31_t * pSrcA, + q31_t * pSrcB, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Multiplies a floating-point vector by a scalar. + * @param[in] *pSrc points to the input vector + * @param[in] scale scale factor to be applied + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_scale_f32( + float32_t * pSrc, + float32_t scale, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Multiplies a Q7 vector by a scalar. + * @param[in] *pSrc points to the input vector + * @param[in] scaleFract fractional portion of the scale value + * @param[in] shift number of bits to shift the result by + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_scale_q7( + q7_t * pSrc, + q7_t scaleFract, + int8_t shift, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Multiplies a Q15 vector by a scalar. + * @param[in] *pSrc points to the input vector + * @param[in] scaleFract fractional portion of the scale value + * @param[in] shift number of bits to shift the result by + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_scale_q15( + q15_t * pSrc, + q15_t scaleFract, + int8_t shift, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Multiplies a Q31 vector by a scalar. + * @param[in] *pSrc points to the input vector + * @param[in] scaleFract fractional portion of the scale value + * @param[in] shift number of bits to shift the result by + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_scale_q31( + q31_t * pSrc, + q31_t scaleFract, + int8_t shift, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Q7 vector absolute value. + * @param[in] *pSrc points to the input buffer + * @param[out] *pDst points to the output buffer + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_abs_q7( + q7_t * pSrc, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Floating-point vector absolute value. + * @param[in] *pSrc points to the input buffer + * @param[out] *pDst points to the output buffer + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_abs_f32( + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Q15 vector absolute value. + * @param[in] *pSrc points to the input buffer + * @param[out] *pDst points to the output buffer + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_abs_q15( + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Q31 vector absolute value. + * @param[in] *pSrc points to the input buffer + * @param[out] *pDst points to the output buffer + * @param[in] blockSize number of samples in each vector + * @return none. + */ + + void arm_abs_q31( + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Dot product of floating-point vectors. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[in] blockSize number of samples in each vector + * @param[out] *result output result returned here + * @return none. + */ + + void arm_dot_prod_f32( + float32_t * pSrcA, + float32_t * pSrcB, + uint32_t blockSize, + float32_t * result); + + /** + * @brief Dot product of Q7 vectors. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[in] blockSize number of samples in each vector + * @param[out] *result output result returned here + * @return none. + */ + + void arm_dot_prod_q7( + q7_t * pSrcA, + q7_t * pSrcB, + uint32_t blockSize, + q31_t * result); + + /** + * @brief Dot product of Q15 vectors. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[in] blockSize number of samples in each vector + * @param[out] *result output result returned here + * @return none. + */ + + void arm_dot_prod_q15( + q15_t * pSrcA, + q15_t * pSrcB, + uint32_t blockSize, + q63_t * result); + + /** + * @brief Dot product of Q31 vectors. + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[in] blockSize number of samples in each vector + * @param[out] *result output result returned here + * @return none. + */ + + void arm_dot_prod_q31( + q31_t * pSrcA, + q31_t * pSrcB, + uint32_t blockSize, + q63_t * result); + + /** + * @brief Shifts the elements of a Q7 vector a specified number of bits. + * @param[in] *pSrc points to the input vector + * @param[in] shiftBits number of bits to shift. A positive value shifts left; a negative value shifts right. + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_shift_q7( + q7_t * pSrc, + int8_t shiftBits, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Shifts the elements of a Q15 vector a specified number of bits. + * @param[in] *pSrc points to the input vector + * @param[in] shiftBits number of bits to shift. A positive value shifts left; a negative value shifts right. + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_shift_q15( + q15_t * pSrc, + int8_t shiftBits, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Shifts the elements of a Q31 vector a specified number of bits. + * @param[in] *pSrc points to the input vector + * @param[in] shiftBits number of bits to shift. A positive value shifts left; a negative value shifts right. + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_shift_q31( + q31_t * pSrc, + int8_t shiftBits, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Adds a constant offset to a floating-point vector. + * @param[in] *pSrc points to the input vector + * @param[in] offset is the offset to be added + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_offset_f32( + float32_t * pSrc, + float32_t offset, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Adds a constant offset to a Q7 vector. + * @param[in] *pSrc points to the input vector + * @param[in] offset is the offset to be added + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_offset_q7( + q7_t * pSrc, + q7_t offset, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Adds a constant offset to a Q15 vector. + * @param[in] *pSrc points to the input vector + * @param[in] offset is the offset to be added + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_offset_q15( + q15_t * pSrc, + q15_t offset, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Adds a constant offset to a Q31 vector. + * @param[in] *pSrc points to the input vector + * @param[in] offset is the offset to be added + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_offset_q31( + q31_t * pSrc, + q31_t offset, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Negates the elements of a floating-point vector. + * @param[in] *pSrc points to the input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_negate_f32( + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Negates the elements of a Q7 vector. + * @param[in] *pSrc points to the input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_negate_q7( + q7_t * pSrc, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Negates the elements of a Q15 vector. + * @param[in] *pSrc points to the input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_negate_q15( + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Negates the elements of a Q31 vector. + * @param[in] *pSrc points to the input vector + * @param[out] *pDst points to the output vector + * @param[in] blockSize number of samples in the vector + * @return none. + */ + + void arm_negate_q31( + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + /** + * @brief Copies the elements of a floating-point vector. + * @param[in] *pSrc input pointer + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_copy_f32( + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Copies the elements of a Q7 vector. + * @param[in] *pSrc input pointer + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_copy_q7( + q7_t * pSrc, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Copies the elements of a Q15 vector. + * @param[in] *pSrc input pointer + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_copy_q15( + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Copies the elements of a Q31 vector. + * @param[in] *pSrc input pointer + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_copy_q31( + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + /** + * @brief Fills a constant value into a floating-point vector. + * @param[in] value input value to be filled + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_fill_f32( + float32_t value, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Fills a constant value into a Q7 vector. + * @param[in] value input value to be filled + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_fill_q7( + q7_t value, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Fills a constant value into a Q15 vector. + * @param[in] value input value to be filled + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_fill_q15( + q15_t value, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Fills a constant value into a Q31 vector. + * @param[in] value input value to be filled + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_fill_q31( + q31_t value, + q31_t * pDst, + uint32_t blockSize); + +/** + * @brief Convolution of floating-point sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the location where the output result is written. Length srcALen+srcBLen-1. + * @return none. + */ + + void arm_conv_f32( + float32_t * pSrcA, + uint32_t srcALen, + float32_t * pSrcB, + uint32_t srcBLen, + float32_t * pDst); + +/** + * @brief Convolution of Q15 sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the location where the output result is written. Length srcALen+srcBLen-1. + * @return none. + */ + + void arm_conv_q15( + q15_t * pSrcA, + uint32_t srcALen, + q15_t * pSrcB, + uint32_t srcBLen, + q15_t * pDst); + + /** + * @brief Convolution of Q15 sequences (fast version) for Cortex-M3 and Cortex-M4 + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length srcALen+srcBLen-1. + * @return none. + */ + + void arm_conv_fast_q15( + q15_t * pSrcA, + uint32_t srcALen, + q15_t * pSrcB, + uint32_t srcBLen, + q15_t * pDst); + + /** + * @brief Convolution of Q31 sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length srcALen+srcBLen-1. + * @return none. + */ + + void arm_conv_q31( + q31_t * pSrcA, + uint32_t srcALen, + q31_t * pSrcB, + uint32_t srcBLen, + q31_t * pDst); + + /** + * @brief Convolution of Q31 sequences (fast version) for Cortex-M3 and Cortex-M4 + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length srcALen+srcBLen-1. + * @return none. + */ + + void arm_conv_fast_q31( + q31_t * pSrcA, + uint32_t srcALen, + q31_t * pSrcB, + uint32_t srcBLen, + q31_t * pDst); + + /** + * @brief Convolution of Q7 sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length srcALen+srcBLen-1. + * @return none. + */ + + void arm_conv_q7( + q7_t * pSrcA, + uint32_t srcALen, + q7_t * pSrcB, + uint32_t srcBLen, + q7_t * pDst); + + /** + * @brief Partial convolution of floating-point sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data + * @param[in] firstIndex is the first output sample to start with. + * @param[in] numPoints is the number of output points to be computed. + * @return Returns either ARM_MATH_SUCCESS if the function completed correctly or ARM_MATH_ARGUMENT_ERROR if the requested subset is not in the range [0 srcALen+srcBLen-2]. + */ + + arm_status arm_conv_partial_f32( + float32_t * pSrcA, + uint32_t srcALen, + float32_t * pSrcB, + uint32_t srcBLen, + float32_t * pDst, + uint32_t firstIndex, + uint32_t numPoints); + + /** + * @brief Partial convolution of Q15 sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data + * @param[in] firstIndex is the first output sample to start with. + * @param[in] numPoints is the number of output points to be computed. + * @return Returns either ARM_MATH_SUCCESS if the function completed correctly or ARM_MATH_ARGUMENT_ERROR if the requested subset is not in the range [0 srcALen+srcBLen-2]. + */ + + arm_status arm_conv_partial_q15( + q15_t * pSrcA, + uint32_t srcALen, + q15_t * pSrcB, + uint32_t srcBLen, + q15_t * pDst, + uint32_t firstIndex, + uint32_t numPoints); + + /** + * @brief Partial convolution of Q15 sequences (fast version) for Cortex-M3 and Cortex-M4 + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data + * @param[in] firstIndex is the first output sample to start with. + * @param[in] numPoints is the number of output points to be computed. + * @return Returns either ARM_MATH_SUCCESS if the function completed correctly or ARM_MATH_ARGUMENT_ERROR if the requested subset is not in the range [0 srcALen+srcBLen-2]. + */ + + arm_status arm_conv_partial_fast_q15( + q15_t * pSrcA, + uint32_t srcALen, + q15_t * pSrcB, + uint32_t srcBLen, + q15_t * pDst, + uint32_t firstIndex, + uint32_t numPoints); + + /** + * @brief Partial convolution of Q31 sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data + * @param[in] firstIndex is the first output sample to start with. + * @param[in] numPoints is the number of output points to be computed. + * @return Returns either ARM_MATH_SUCCESS if the function completed correctly or ARM_MATH_ARGUMENT_ERROR if the requested subset is not in the range [0 srcALen+srcBLen-2]. + */ + + arm_status arm_conv_partial_q31( + q31_t * pSrcA, + uint32_t srcALen, + q31_t * pSrcB, + uint32_t srcBLen, + q31_t * pDst, + uint32_t firstIndex, + uint32_t numPoints); + + + /** + * @brief Partial convolution of Q31 sequences (fast version) for Cortex-M3 and Cortex-M4 + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data + * @param[in] firstIndex is the first output sample to start with. + * @param[in] numPoints is the number of output points to be computed. + * @return Returns either ARM_MATH_SUCCESS if the function completed correctly or ARM_MATH_ARGUMENT_ERROR if the requested subset is not in the range [0 srcALen+srcBLen-2]. + */ + + arm_status arm_conv_partial_fast_q31( + q31_t * pSrcA, + uint32_t srcALen, + q31_t * pSrcB, + uint32_t srcBLen, + q31_t * pDst, + uint32_t firstIndex, + uint32_t numPoints); + + /** + * @brief Partial convolution of Q7 sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data + * @param[in] firstIndex is the first output sample to start with. + * @param[in] numPoints is the number of output points to be computed. + * @return Returns either ARM_MATH_SUCCESS if the function completed correctly or ARM_MATH_ARGUMENT_ERROR if the requested subset is not in the range [0 srcALen+srcBLen-2]. + */ + + arm_status arm_conv_partial_q7( + q7_t * pSrcA, + uint32_t srcALen, + q7_t * pSrcB, + uint32_t srcBLen, + q7_t * pDst, + uint32_t firstIndex, + uint32_t numPoints); + + + /** + * @brief Instance structure for the Q15 FIR decimator. + */ + + typedef struct + { + uint8_t M; /**< decimation factor. */ + uint16_t numTaps; /**< number of coefficients in the filter. */ + q15_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps.*/ + q15_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + } arm_fir_decimate_instance_q15; + + /** + * @brief Instance structure for the Q31 FIR decimator. + */ + + typedef struct + { + uint8_t M; /**< decimation factor. */ + uint16_t numTaps; /**< number of coefficients in the filter. */ + q31_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps.*/ + q31_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + + } arm_fir_decimate_instance_q31; + + /** + * @brief Instance structure for the floating-point FIR decimator. + */ + + typedef struct + { + uint8_t M; /**< decimation factor. */ + uint16_t numTaps; /**< number of coefficients in the filter. */ + float32_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps.*/ + float32_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + + } arm_fir_decimate_instance_f32; + + + + /** + * @brief Processing function for the floating-point FIR decimator. + * @param[in] *S points to an instance of the floating-point FIR decimator structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] blockSize number of input samples to process per call. + * @return none + */ + + void arm_fir_decimate_f32( + const arm_fir_decimate_instance_f32 * S, + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + + /** + * @brief Initialization function for the floating-point FIR decimator. + * @param[in,out] *S points to an instance of the floating-point FIR decimator structure. + * @param[in] numTaps number of coefficients in the filter. + * @param[in] M decimation factor. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of input samples to process per call. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_LENGTH_ERROR if + * blockSize is not a multiple of M. + */ + + arm_status arm_fir_decimate_init_f32( + arm_fir_decimate_instance_f32 * S, + uint16_t numTaps, + uint8_t M, + float32_t * pCoeffs, + float32_t * pState, + uint32_t blockSize); + + /** + * @brief Processing function for the Q15 FIR decimator. + * @param[in] *S points to an instance of the Q15 FIR decimator structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] blockSize number of input samples to process per call. + * @return none + */ + + void arm_fir_decimate_q15( + const arm_fir_decimate_instance_q15 * S, + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Processing function for the Q15 FIR decimator (fast variant) for Cortex-M3 and Cortex-M4. + * @param[in] *S points to an instance of the Q15 FIR decimator structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] blockSize number of input samples to process per call. + * @return none + */ + + void arm_fir_decimate_fast_q15( + const arm_fir_decimate_instance_q15 * S, + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + + + /** + * @brief Initialization function for the Q15 FIR decimator. + * @param[in,out] *S points to an instance of the Q15 FIR decimator structure. + * @param[in] numTaps number of coefficients in the filter. + * @param[in] M decimation factor. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of input samples to process per call. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_LENGTH_ERROR if + * blockSize is not a multiple of M. + */ + + arm_status arm_fir_decimate_init_q15( + arm_fir_decimate_instance_q15 * S, + uint16_t numTaps, + uint8_t M, + q15_t * pCoeffs, + q15_t * pState, + uint32_t blockSize); + + /** + * @brief Processing function for the Q31 FIR decimator. + * @param[in] *S points to an instance of the Q31 FIR decimator structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] blockSize number of input samples to process per call. + * @return none + */ + + void arm_fir_decimate_q31( + const arm_fir_decimate_instance_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Processing function for the Q31 FIR decimator (fast variant) for Cortex-M3 and Cortex-M4. + * @param[in] *S points to an instance of the Q31 FIR decimator structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] blockSize number of input samples to process per call. + * @return none + */ + + void arm_fir_decimate_fast_q31( + arm_fir_decimate_instance_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + + /** + * @brief Initialization function for the Q31 FIR decimator. + * @param[in,out] *S points to an instance of the Q31 FIR decimator structure. + * @param[in] numTaps number of coefficients in the filter. + * @param[in] M decimation factor. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of input samples to process per call. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_LENGTH_ERROR if + * blockSize is not a multiple of M. + */ + + arm_status arm_fir_decimate_init_q31( + arm_fir_decimate_instance_q31 * S, + uint16_t numTaps, + uint8_t M, + q31_t * pCoeffs, + q31_t * pState, + uint32_t blockSize); + + + + /** + * @brief Instance structure for the Q15 FIR interpolator. + */ + + typedef struct + { + uint8_t L; /**< upsample factor. */ + uint16_t phaseLength; /**< length of each polyphase filter component. */ + q15_t *pCoeffs; /**< points to the coefficient array. The array is of length L*phaseLength. */ + q15_t *pState; /**< points to the state variable array. The array is of length blockSize+phaseLength-1. */ + } arm_fir_interpolate_instance_q15; + + /** + * @brief Instance structure for the Q31 FIR interpolator. + */ + + typedef struct + { + uint8_t L; /**< upsample factor. */ + uint16_t phaseLength; /**< length of each polyphase filter component. */ + q31_t *pCoeffs; /**< points to the coefficient array. The array is of length L*phaseLength. */ + q31_t *pState; /**< points to the state variable array. The array is of length blockSize+phaseLength-1. */ + } arm_fir_interpolate_instance_q31; + + /** + * @brief Instance structure for the floating-point FIR interpolator. + */ + + typedef struct + { + uint8_t L; /**< upsample factor. */ + uint16_t phaseLength; /**< length of each polyphase filter component. */ + float32_t *pCoeffs; /**< points to the coefficient array. The array is of length L*phaseLength. */ + float32_t *pState; /**< points to the state variable array. The array is of length phaseLength+numTaps-1. */ + } arm_fir_interpolate_instance_f32; + + + /** + * @brief Processing function for the Q15 FIR interpolator. + * @param[in] *S points to an instance of the Q15 FIR interpolator structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of input samples to process per call. + * @return none. + */ + + void arm_fir_interpolate_q15( + const arm_fir_interpolate_instance_q15 * S, + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + + /** + * @brief Initialization function for the Q15 FIR interpolator. + * @param[in,out] *S points to an instance of the Q15 FIR interpolator structure. + * @param[in] L upsample factor. + * @param[in] numTaps number of filter coefficients in the filter. + * @param[in] *pCoeffs points to the filter coefficient buffer. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of input samples to process per call. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_LENGTH_ERROR if + * the filter length numTaps is not a multiple of the interpolation factor L. + */ + + arm_status arm_fir_interpolate_init_q15( + arm_fir_interpolate_instance_q15 * S, + uint8_t L, + uint16_t numTaps, + q15_t * pCoeffs, + q15_t * pState, + uint32_t blockSize); + + /** + * @brief Processing function for the Q31 FIR interpolator. + * @param[in] *S points to an instance of the Q15 FIR interpolator structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of input samples to process per call. + * @return none. + */ + + void arm_fir_interpolate_q31( + const arm_fir_interpolate_instance_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the Q31 FIR interpolator. + * @param[in,out] *S points to an instance of the Q31 FIR interpolator structure. + * @param[in] L upsample factor. + * @param[in] numTaps number of filter coefficients in the filter. + * @param[in] *pCoeffs points to the filter coefficient buffer. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of input samples to process per call. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_LENGTH_ERROR if + * the filter length numTaps is not a multiple of the interpolation factor L. + */ + + arm_status arm_fir_interpolate_init_q31( + arm_fir_interpolate_instance_q31 * S, + uint8_t L, + uint16_t numTaps, + q31_t * pCoeffs, + q31_t * pState, + uint32_t blockSize); + + + /** + * @brief Processing function for the floating-point FIR interpolator. + * @param[in] *S points to an instance of the floating-point FIR interpolator structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of input samples to process per call. + * @return none. + */ + + void arm_fir_interpolate_f32( + const arm_fir_interpolate_instance_f32 * S, + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the floating-point FIR interpolator. + * @param[in,out] *S points to an instance of the floating-point FIR interpolator structure. + * @param[in] L upsample factor. + * @param[in] numTaps number of filter coefficients in the filter. + * @param[in] *pCoeffs points to the filter coefficient buffer. + * @param[in] *pState points to the state buffer. + * @param[in] blockSize number of input samples to process per call. + * @return The function returns ARM_MATH_SUCCESS if initialization is successful or ARM_MATH_LENGTH_ERROR if + * the filter length numTaps is not a multiple of the interpolation factor L. + */ + + arm_status arm_fir_interpolate_init_f32( + arm_fir_interpolate_instance_f32 * S, + uint8_t L, + uint16_t numTaps, + float32_t * pCoeffs, + float32_t * pState, + uint32_t blockSize); + + /** + * @brief Instance structure for the high precision Q31 Biquad cascade filter. + */ + + typedef struct + { + uint8_t numStages; /**< number of 2nd order stages in the filter. Overall order is 2*numStages. */ + q63_t *pState; /**< points to the array of state coefficients. The array is of length 4*numStages. */ + q31_t *pCoeffs; /**< points to the array of coefficients. The array is of length 5*numStages. */ + uint8_t postShift; /**< additional shift, in bits, applied to each output sample. */ + + } arm_biquad_cas_df1_32x64_ins_q31; + + + /** + * @param[in] *S points to an instance of the high precision Q31 Biquad cascade filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_biquad_cas_df1_32x64_q31( + const arm_biquad_cas_df1_32x64_ins_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + + /** + * @param[in,out] *S points to an instance of the high precision Q31 Biquad cascade filter structure. + * @param[in] numStages number of 2nd order stages in the filter. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] postShift shift to be applied to the output. Varies according to the coefficients format + * @return none + */ + + void arm_biquad_cas_df1_32x64_init_q31( + arm_biquad_cas_df1_32x64_ins_q31 * S, + uint8_t numStages, + q31_t * pCoeffs, + q63_t * pState, + uint8_t postShift); + + + + /** + * @brief Instance structure for the floating-point transposed direct form II Biquad cascade filter. + */ + + typedef struct + { + uint8_t numStages; /**< number of 2nd order stages in the filter. Overall order is 2*numStages. */ + float32_t *pState; /**< points to the array of state coefficients. The array is of length 2*numStages. */ + float32_t *pCoeffs; /**< points to the array of coefficients. The array is of length 5*numStages. */ + } arm_biquad_cascade_df2T_instance_f32; + + + /** + * @brief Processing function for the floating-point transposed direct form II Biquad cascade filter. + * @param[in] *S points to an instance of the filter data structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_biquad_cascade_df2T_f32( + const arm_biquad_cascade_df2T_instance_f32 * S, + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + + /** + * @brief Initialization function for the floating-point transposed direct form II Biquad cascade filter. + * @param[in,out] *S points to an instance of the filter data structure. + * @param[in] numStages number of 2nd order stages in the filter. + * @param[in] *pCoeffs points to the filter coefficients. + * @param[in] *pState points to the state buffer. + * @return none + */ + + void arm_biquad_cascade_df2T_init_f32( + arm_biquad_cascade_df2T_instance_f32 * S, + uint8_t numStages, + float32_t * pCoeffs, + float32_t * pState); + + + + /** + * @brief Instance structure for the Q15 FIR lattice filter. + */ + + typedef struct + { + uint16_t numStages; /**< number of filter stages. */ + q15_t *pState; /**< points to the state variable array. The array is of length numStages. */ + q15_t *pCoeffs; /**< points to the coefficient array. The array is of length numStages. */ + } arm_fir_lattice_instance_q15; + + /** + * @brief Instance structure for the Q31 FIR lattice filter. + */ + + typedef struct + { + uint16_t numStages; /**< number of filter stages. */ + q31_t *pState; /**< points to the state variable array. The array is of length numStages. */ + q31_t *pCoeffs; /**< points to the coefficient array. The array is of length numStages. */ + } arm_fir_lattice_instance_q31; + + /** + * @brief Instance structure for the floating-point FIR lattice filter. + */ + + typedef struct + { + uint16_t numStages; /**< number of filter stages. */ + float32_t *pState; /**< points to the state variable array. The array is of length numStages. */ + float32_t *pCoeffs; /**< points to the coefficient array. The array is of length numStages. */ + } arm_fir_lattice_instance_f32; + + /** + * @brief Initialization function for the Q15 FIR lattice filter. + * @param[in] *S points to an instance of the Q15 FIR lattice structure. + * @param[in] numStages number of filter stages. + * @param[in] *pCoeffs points to the coefficient buffer. The array is of length numStages. + * @param[in] *pState points to the state buffer. The array is of length numStages. + * @return none. + */ + + void arm_fir_lattice_init_q15( + arm_fir_lattice_instance_q15 * S, + uint16_t numStages, + q15_t * pCoeffs, + q15_t * pState); + + + /** + * @brief Processing function for the Q15 FIR lattice filter. + * @param[in] *S points to an instance of the Q15 FIR lattice structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + void arm_fir_lattice_q15( + const arm_fir_lattice_instance_q15 * S, + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the Q31 FIR lattice filter. + * @param[in] *S points to an instance of the Q31 FIR lattice structure. + * @param[in] numStages number of filter stages. + * @param[in] *pCoeffs points to the coefficient buffer. The array is of length numStages. + * @param[in] *pState points to the state buffer. The array is of length numStages. + * @return none. + */ + + void arm_fir_lattice_init_q31( + arm_fir_lattice_instance_q31 * S, + uint16_t numStages, + q31_t * pCoeffs, + q31_t * pState); + + + /** + * @brief Processing function for the Q31 FIR lattice filter. + * @param[in] *S points to an instance of the Q31 FIR lattice structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_fir_lattice_q31( + const arm_fir_lattice_instance_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + +/** + * @brief Initialization function for the floating-point FIR lattice filter. + * @param[in] *S points to an instance of the floating-point FIR lattice structure. + * @param[in] numStages number of filter stages. + * @param[in] *pCoeffs points to the coefficient buffer. The array is of length numStages. + * @param[in] *pState points to the state buffer. The array is of length numStages. + * @return none. + */ + + void arm_fir_lattice_init_f32( + arm_fir_lattice_instance_f32 * S, + uint16_t numStages, + float32_t * pCoeffs, + float32_t * pState); + + /** + * @brief Processing function for the floating-point FIR lattice filter. + * @param[in] *S points to an instance of the floating-point FIR lattice structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_fir_lattice_f32( + const arm_fir_lattice_instance_f32 * S, + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Instance structure for the Q15 IIR lattice filter. + */ + typedef struct + { + uint16_t numStages; /**< number of stages in the filter. */ + q15_t *pState; /**< points to the state variable array. The array is of length numStages+blockSize. */ + q15_t *pkCoeffs; /**< points to the reflection coefficient array. The array is of length numStages. */ + q15_t *pvCoeffs; /**< points to the ladder coefficient array. The array is of length numStages+1. */ + } arm_iir_lattice_instance_q15; + + /** + * @brief Instance structure for the Q31 IIR lattice filter. + */ + typedef struct + { + uint16_t numStages; /**< number of stages in the filter. */ + q31_t *pState; /**< points to the state variable array. The array is of length numStages+blockSize. */ + q31_t *pkCoeffs; /**< points to the reflection coefficient array. The array is of length numStages. */ + q31_t *pvCoeffs; /**< points to the ladder coefficient array. The array is of length numStages+1. */ + } arm_iir_lattice_instance_q31; + + /** + * @brief Instance structure for the floating-point IIR lattice filter. + */ + typedef struct + { + uint16_t numStages; /**< number of stages in the filter. */ + float32_t *pState; /**< points to the state variable array. The array is of length numStages+blockSize. */ + float32_t *pkCoeffs; /**< points to the reflection coefficient array. The array is of length numStages. */ + float32_t *pvCoeffs; /**< points to the ladder coefficient array. The array is of length numStages+1. */ + } arm_iir_lattice_instance_f32; + + /** + * @brief Processing function for the floating-point IIR lattice filter. + * @param[in] *S points to an instance of the floating-point IIR lattice structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_iir_lattice_f32( + const arm_iir_lattice_instance_f32 * S, + float32_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + /** + * @brief Initialization function for the floating-point IIR lattice filter. + * @param[in] *S points to an instance of the floating-point IIR lattice structure. + * @param[in] numStages number of stages in the filter. + * @param[in] *pkCoeffs points to the reflection coefficient buffer. The array is of length numStages. + * @param[in] *pvCoeffs points to the ladder coefficient buffer. The array is of length numStages+1. + * @param[in] *pState points to the state buffer. The array is of length numStages+blockSize-1. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_iir_lattice_init_f32( + arm_iir_lattice_instance_f32 * S, + uint16_t numStages, + float32_t *pkCoeffs, + float32_t *pvCoeffs, + float32_t *pState, + uint32_t blockSize); + + + /** + * @brief Processing function for the Q31 IIR lattice filter. + * @param[in] *S points to an instance of the Q31 IIR lattice structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_iir_lattice_q31( + const arm_iir_lattice_instance_q31 * S, + q31_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + + /** + * @brief Initialization function for the Q31 IIR lattice filter. + * @param[in] *S points to an instance of the Q31 IIR lattice structure. + * @param[in] numStages number of stages in the filter. + * @param[in] *pkCoeffs points to the reflection coefficient buffer. The array is of length numStages. + * @param[in] *pvCoeffs points to the ladder coefficient buffer. The array is of length numStages+1. + * @param[in] *pState points to the state buffer. The array is of length numStages+blockSize. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_iir_lattice_init_q31( + arm_iir_lattice_instance_q31 * S, + uint16_t numStages, + q31_t *pkCoeffs, + q31_t *pvCoeffs, + q31_t *pState, + uint32_t blockSize); + + + /** + * @brief Processing function for the Q15 IIR lattice filter. + * @param[in] *S points to an instance of the Q15 IIR lattice structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_iir_lattice_q15( + const arm_iir_lattice_instance_q15 * S, + q15_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + +/** + * @brief Initialization function for the Q15 IIR lattice filter. + * @param[in] *S points to an instance of the fixed-point Q15 IIR lattice structure. + * @param[in] numStages number of stages in the filter. + * @param[in] *pkCoeffs points to reflection coefficient buffer. The array is of length numStages. + * @param[in] *pvCoeffs points to ladder coefficient buffer. The array is of length numStages+1. + * @param[in] *pState points to state buffer. The array is of length numStages+blockSize. + * @param[in] blockSize number of samples to process per call. + * @return none. + */ + + void arm_iir_lattice_init_q15( + arm_iir_lattice_instance_q15 * S, + uint16_t numStages, + q15_t *pkCoeffs, + q15_t *pvCoeffs, + q15_t *pState, + uint32_t blockSize); + + /** + * @brief Instance structure for the floating-point LMS filter. + */ + + typedef struct + { + uint16_t numTaps; /**< number of coefficients in the filter. */ + float32_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + float32_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps. */ + float32_t mu; /**< step size that controls filter coefficient updates. */ + } arm_lms_instance_f32; + + /** + * @brief Processing function for floating-point LMS filter. + * @param[in] *S points to an instance of the floating-point LMS filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[in] *pRef points to the block of reference data. + * @param[out] *pOut points to the block of output data. + * @param[out] *pErr points to the block of error data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_lms_f32( + const arm_lms_instance_f32 * S, + float32_t * pSrc, + float32_t * pRef, + float32_t * pOut, + float32_t * pErr, + uint32_t blockSize); + + /** + * @brief Initialization function for floating-point LMS filter. + * @param[in] *S points to an instance of the floating-point LMS filter structure. + * @param[in] numTaps number of filter coefficients. + * @param[in] *pCoeffs points to the coefficient buffer. + * @param[in] *pState points to state buffer. + * @param[in] mu step size that controls filter coefficient updates. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_lms_init_f32( + arm_lms_instance_f32 * S, + uint16_t numTaps, + float32_t * pCoeffs, + float32_t * pState, + float32_t mu, + uint32_t blockSize); + + /** + * @brief Instance structure for the Q15 LMS filter. + */ + + typedef struct + { + uint16_t numTaps; /**< number of coefficients in the filter. */ + q15_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + q15_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps. */ + q15_t mu; /**< step size that controls filter coefficient updates. */ + uint32_t postShift; /**< bit shift applied to coefficients. */ + } arm_lms_instance_q15; + + + /** + * @brief Initialization function for the Q15 LMS filter. + * @param[in] *S points to an instance of the Q15 LMS filter structure. + * @param[in] numTaps number of filter coefficients. + * @param[in] *pCoeffs points to the coefficient buffer. + * @param[in] *pState points to the state buffer. + * @param[in] mu step size that controls filter coefficient updates. + * @param[in] blockSize number of samples to process. + * @param[in] postShift bit shift applied to coefficients. + * @return none. + */ + + void arm_lms_init_q15( + arm_lms_instance_q15 * S, + uint16_t numTaps, + q15_t * pCoeffs, + q15_t * pState, + q15_t mu, + uint32_t blockSize, + uint32_t postShift); + + /** + * @brief Processing function for Q15 LMS filter. + * @param[in] *S points to an instance of the Q15 LMS filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[in] *pRef points to the block of reference data. + * @param[out] *pOut points to the block of output data. + * @param[out] *pErr points to the block of error data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_lms_q15( + const arm_lms_instance_q15 * S, + q15_t * pSrc, + q15_t * pRef, + q15_t * pOut, + q15_t * pErr, + uint32_t blockSize); + + + /** + * @brief Instance structure for the Q31 LMS filter. + */ + + typedef struct + { + uint16_t numTaps; /**< number of coefficients in the filter. */ + q31_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + q31_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps. */ + q31_t mu; /**< step size that controls filter coefficient updates. */ + uint32_t postShift; /**< bit shift applied to coefficients. */ + + } arm_lms_instance_q31; + + /** + * @brief Processing function for Q31 LMS filter. + * @param[in] *S points to an instance of the Q15 LMS filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[in] *pRef points to the block of reference data. + * @param[out] *pOut points to the block of output data. + * @param[out] *pErr points to the block of error data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_lms_q31( + const arm_lms_instance_q31 * S, + q31_t * pSrc, + q31_t * pRef, + q31_t * pOut, + q31_t * pErr, + uint32_t blockSize); + + /** + * @brief Initialization function for Q31 LMS filter. + * @param[in] *S points to an instance of the Q31 LMS filter structure. + * @param[in] numTaps number of filter coefficients. + * @param[in] *pCoeffs points to coefficient buffer. + * @param[in] *pState points to state buffer. + * @param[in] mu step size that controls filter coefficient updates. + * @param[in] blockSize number of samples to process. + * @param[in] postShift bit shift applied to coefficients. + * @return none. + */ + + void arm_lms_init_q31( + arm_lms_instance_q31 * S, + uint16_t numTaps, + q31_t *pCoeffs, + q31_t *pState, + q31_t mu, + uint32_t blockSize, + uint32_t postShift); + + /** + * @brief Instance structure for the floating-point normalized LMS filter. + */ + + typedef struct + { + uint16_t numTaps; /**< number of coefficients in the filter. */ + float32_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + float32_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps. */ + float32_t mu; /**< step size that control filter coefficient updates. */ + float32_t energy; /**< saves previous frame energy. */ + float32_t x0; /**< saves previous input sample. */ + } arm_lms_norm_instance_f32; + + /** + * @brief Processing function for floating-point normalized LMS filter. + * @param[in] *S points to an instance of the floating-point normalized LMS filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[in] *pRef points to the block of reference data. + * @param[out] *pOut points to the block of output data. + * @param[out] *pErr points to the block of error data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_lms_norm_f32( + arm_lms_norm_instance_f32 * S, + float32_t * pSrc, + float32_t * pRef, + float32_t * pOut, + float32_t * pErr, + uint32_t blockSize); + + /** + * @brief Initialization function for floating-point normalized LMS filter. + * @param[in] *S points to an instance of the floating-point LMS filter structure. + * @param[in] numTaps number of filter coefficients. + * @param[in] *pCoeffs points to coefficient buffer. + * @param[in] *pState points to state buffer. + * @param[in] mu step size that controls filter coefficient updates. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_lms_norm_init_f32( + arm_lms_norm_instance_f32 * S, + uint16_t numTaps, + float32_t * pCoeffs, + float32_t * pState, + float32_t mu, + uint32_t blockSize); + + + /** + * @brief Instance structure for the Q31 normalized LMS filter. + */ + typedef struct + { + uint16_t numTaps; /**< number of coefficients in the filter. */ + q31_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + q31_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps. */ + q31_t mu; /**< step size that controls filter coefficient updates. */ + uint8_t postShift; /**< bit shift applied to coefficients. */ + q31_t *recipTable; /**< points to the reciprocal initial value table. */ + q31_t energy; /**< saves previous frame energy. */ + q31_t x0; /**< saves previous input sample. */ + } arm_lms_norm_instance_q31; + + /** + * @brief Processing function for Q31 normalized LMS filter. + * @param[in] *S points to an instance of the Q31 normalized LMS filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[in] *pRef points to the block of reference data. + * @param[out] *pOut points to the block of output data. + * @param[out] *pErr points to the block of error data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_lms_norm_q31( + arm_lms_norm_instance_q31 * S, + q31_t * pSrc, + q31_t * pRef, + q31_t * pOut, + q31_t * pErr, + uint32_t blockSize); + + /** + * @brief Initialization function for Q31 normalized LMS filter. + * @param[in] *S points to an instance of the Q31 normalized LMS filter structure. + * @param[in] numTaps number of filter coefficients. + * @param[in] *pCoeffs points to coefficient buffer. + * @param[in] *pState points to state buffer. + * @param[in] mu step size that controls filter coefficient updates. + * @param[in] blockSize number of samples to process. + * @param[in] postShift bit shift applied to coefficients. + * @return none. + */ + + void arm_lms_norm_init_q31( + arm_lms_norm_instance_q31 * S, + uint16_t numTaps, + q31_t * pCoeffs, + q31_t * pState, + q31_t mu, + uint32_t blockSize, + uint8_t postShift); + + /** + * @brief Instance structure for the Q15 normalized LMS filter. + */ + + typedef struct + { + uint16_t numTaps; /**< Number of coefficients in the filter. */ + q15_t *pState; /**< points to the state variable array. The array is of length numTaps+blockSize-1. */ + q15_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps. */ + q15_t mu; /**< step size that controls filter coefficient updates. */ + uint8_t postShift; /**< bit shift applied to coefficients. */ + q15_t *recipTable; /**< Points to the reciprocal initial value table. */ + q15_t energy; /**< saves previous frame energy. */ + q15_t x0; /**< saves previous input sample. */ + } arm_lms_norm_instance_q15; + + /** + * @brief Processing function for Q15 normalized LMS filter. + * @param[in] *S points to an instance of the Q15 normalized LMS filter structure. + * @param[in] *pSrc points to the block of input data. + * @param[in] *pRef points to the block of reference data. + * @param[out] *pOut points to the block of output data. + * @param[out] *pErr points to the block of error data. + * @param[in] blockSize number of samples to process. + * @return none. + */ + + void arm_lms_norm_q15( + arm_lms_norm_instance_q15 * S, + q15_t * pSrc, + q15_t * pRef, + q15_t * pOut, + q15_t * pErr, + uint32_t blockSize); + + + /** + * @brief Initialization function for Q15 normalized LMS filter. + * @param[in] *S points to an instance of the Q15 normalized LMS filter structure. + * @param[in] numTaps number of filter coefficients. + * @param[in] *pCoeffs points to coefficient buffer. + * @param[in] *pState points to state buffer. + * @param[in] mu step size that controls filter coefficient updates. + * @param[in] blockSize number of samples to process. + * @param[in] postShift bit shift applied to coefficients. + * @return none. + */ + + void arm_lms_norm_init_q15( + arm_lms_norm_instance_q15 * S, + uint16_t numTaps, + q15_t * pCoeffs, + q15_t * pState, + q15_t mu, + uint32_t blockSize, + uint8_t postShift); + + /** + * @brief Correlation of floating-point sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length 2 * max(srcALen, srcBLen) - 1. + * @return none. + */ + + void arm_correlate_f32( + float32_t * pSrcA, + uint32_t srcALen, + float32_t * pSrcB, + uint32_t srcBLen, + float32_t * pDst); + + /** + * @brief Correlation of Q15 sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length 2 * max(srcALen, srcBLen) - 1. + * @return none. + */ + + void arm_correlate_q15( + q15_t * pSrcA, + uint32_t srcALen, + q15_t * pSrcB, + uint32_t srcBLen, + q15_t * pDst); + + /** + * @brief Correlation of Q15 sequences (fast version) for Cortex-M3 and Cortex-M4. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length 2 * max(srcALen, srcBLen) - 1. + * @return none. + */ + + void arm_correlate_fast_q15( + q15_t * pSrcA, + uint32_t srcALen, + q15_t * pSrcB, + uint32_t srcBLen, + q15_t * pDst); + + /** + * @brief Correlation of Q31 sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length 2 * max(srcALen, srcBLen) - 1. + * @return none. + */ + + void arm_correlate_q31( + q31_t * pSrcA, + uint32_t srcALen, + q31_t * pSrcB, + uint32_t srcBLen, + q31_t * pDst); + + /** + * @brief Correlation of Q31 sequences (fast version) for Cortex-M3 and Cortex-M4 + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length 2 * max(srcALen, srcBLen) - 1. + * @return none. + */ + + void arm_correlate_fast_q31( + q31_t * pSrcA, + uint32_t srcALen, + q31_t * pSrcB, + uint32_t srcBLen, + q31_t * pDst); + + /** + * @brief Correlation of Q7 sequences. + * @param[in] *pSrcA points to the first input sequence. + * @param[in] srcALen length of the first input sequence. + * @param[in] *pSrcB points to the second input sequence. + * @param[in] srcBLen length of the second input sequence. + * @param[out] *pDst points to the block of output data Length 2 * max(srcALen, srcBLen) - 1. + * @return none. + */ + + void arm_correlate_q7( + q7_t * pSrcA, + uint32_t srcALen, + q7_t * pSrcB, + uint32_t srcBLen, + q7_t * pDst); + + /** + * @brief Instance structure for the floating-point sparse FIR filter. + */ + typedef struct + { + uint16_t numTaps; /**< number of coefficients in the filter. */ + uint16_t stateIndex; /**< state buffer index. Points to the oldest sample in the state buffer. */ + float32_t *pState; /**< points to the state buffer array. The array is of length maxDelay+blockSize-1. */ + float32_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps.*/ + uint16_t maxDelay; /**< maximum offset specified by the pTapDelay array. */ + int32_t *pTapDelay; /**< points to the array of delay values. The array is of length numTaps. */ + } arm_fir_sparse_instance_f32; + + /** + * @brief Instance structure for the Q31 sparse FIR filter. + */ + + typedef struct + { + uint16_t numTaps; /**< number of coefficients in the filter. */ + uint16_t stateIndex; /**< state buffer index. Points to the oldest sample in the state buffer. */ + q31_t *pState; /**< points to the state buffer array. The array is of length maxDelay+blockSize-1. */ + q31_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps.*/ + uint16_t maxDelay; /**< maximum offset specified by the pTapDelay array. */ + int32_t *pTapDelay; /**< points to the array of delay values. The array is of length numTaps. */ + } arm_fir_sparse_instance_q31; + + /** + * @brief Instance structure for the Q15 sparse FIR filter. + */ + + typedef struct + { + uint16_t numTaps; /**< number of coefficients in the filter. */ + uint16_t stateIndex; /**< state buffer index. Points to the oldest sample in the state buffer. */ + q15_t *pState; /**< points to the state buffer array. The array is of length maxDelay+blockSize-1. */ + q15_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps.*/ + uint16_t maxDelay; /**< maximum offset specified by the pTapDelay array. */ + int32_t *pTapDelay; /**< points to the array of delay values. The array is of length numTaps. */ + } arm_fir_sparse_instance_q15; + + /** + * @brief Instance structure for the Q7 sparse FIR filter. + */ + + typedef struct + { + uint16_t numTaps; /**< number of coefficients in the filter. */ + uint16_t stateIndex; /**< state buffer index. Points to the oldest sample in the state buffer. */ + q7_t *pState; /**< points to the state buffer array. The array is of length maxDelay+blockSize-1. */ + q7_t *pCoeffs; /**< points to the coefficient array. The array is of length numTaps.*/ + uint16_t maxDelay; /**< maximum offset specified by the pTapDelay array. */ + int32_t *pTapDelay; /**< points to the array of delay values. The array is of length numTaps. */ + } arm_fir_sparse_instance_q7; + + /** + * @brief Processing function for the floating-point sparse FIR filter. + * @param[in] *S points to an instance of the floating-point sparse FIR structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] *pScratchIn points to a temporary buffer of size blockSize. + * @param[in] blockSize number of input samples to process per call. + * @return none. + */ + + void arm_fir_sparse_f32( + arm_fir_sparse_instance_f32 * S, + float32_t * pSrc, + float32_t * pDst, + float32_t * pScratchIn, + uint32_t blockSize); + + /** + * @brief Initialization function for the floating-point sparse FIR filter. + * @param[in,out] *S points to an instance of the floating-point sparse FIR structure. + * @param[in] numTaps number of nonzero coefficients in the filter. + * @param[in] *pCoeffs points to the array of filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] *pTapDelay points to the array of offset times. + * @param[in] maxDelay maximum offset time supported. + * @param[in] blockSize number of samples that will be processed per block. + * @return none + */ + + void arm_fir_sparse_init_f32( + arm_fir_sparse_instance_f32 * S, + uint16_t numTaps, + float32_t * pCoeffs, + float32_t * pState, + int32_t * pTapDelay, + uint16_t maxDelay, + uint32_t blockSize); + + /** + * @brief Processing function for the Q31 sparse FIR filter. + * @param[in] *S points to an instance of the Q31 sparse FIR structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] *pScratchIn points to a temporary buffer of size blockSize. + * @param[in] blockSize number of input samples to process per call. + * @return none. + */ + + void arm_fir_sparse_q31( + arm_fir_sparse_instance_q31 * S, + q31_t * pSrc, + q31_t * pDst, + q31_t * pScratchIn, + uint32_t blockSize); + + /** + * @brief Initialization function for the Q31 sparse FIR filter. + * @param[in,out] *S points to an instance of the Q31 sparse FIR structure. + * @param[in] numTaps number of nonzero coefficients in the filter. + * @param[in] *pCoeffs points to the array of filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] *pTapDelay points to the array of offset times. + * @param[in] maxDelay maximum offset time supported. + * @param[in] blockSize number of samples that will be processed per block. + * @return none + */ + + void arm_fir_sparse_init_q31( + arm_fir_sparse_instance_q31 * S, + uint16_t numTaps, + q31_t * pCoeffs, + q31_t * pState, + int32_t * pTapDelay, + uint16_t maxDelay, + uint32_t blockSize); + + /** + * @brief Processing function for the Q15 sparse FIR filter. + * @param[in] *S points to an instance of the Q15 sparse FIR structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] *pScratchIn points to a temporary buffer of size blockSize. + * @param[in] *pScratchOut points to a temporary buffer of size blockSize. + * @param[in] blockSize number of input samples to process per call. + * @return none. + */ + + void arm_fir_sparse_q15( + arm_fir_sparse_instance_q15 * S, + q15_t * pSrc, + q15_t * pDst, + q15_t * pScratchIn, + q31_t * pScratchOut, + uint32_t blockSize); + + + /** + * @brief Initialization function for the Q15 sparse FIR filter. + * @param[in,out] *S points to an instance of the Q15 sparse FIR structure. + * @param[in] numTaps number of nonzero coefficients in the filter. + * @param[in] *pCoeffs points to the array of filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] *pTapDelay points to the array of offset times. + * @param[in] maxDelay maximum offset time supported. + * @param[in] blockSize number of samples that will be processed per block. + * @return none + */ + + void arm_fir_sparse_init_q15( + arm_fir_sparse_instance_q15 * S, + uint16_t numTaps, + q15_t * pCoeffs, + q15_t * pState, + int32_t * pTapDelay, + uint16_t maxDelay, + uint32_t blockSize); + + /** + * @brief Processing function for the Q7 sparse FIR filter. + * @param[in] *S points to an instance of the Q7 sparse FIR structure. + * @param[in] *pSrc points to the block of input data. + * @param[out] *pDst points to the block of output data + * @param[in] *pScratchIn points to a temporary buffer of size blockSize. + * @param[in] *pScratchOut points to a temporary buffer of size blockSize. + * @param[in] blockSize number of input samples to process per call. + * @return none. + */ + + void arm_fir_sparse_q7( + arm_fir_sparse_instance_q7 * S, + q7_t * pSrc, + q7_t * pDst, + q7_t * pScratchIn, + q31_t * pScratchOut, + uint32_t blockSize); + + /** + * @brief Initialization function for the Q7 sparse FIR filter. + * @param[in,out] *S points to an instance of the Q7 sparse FIR structure. + * @param[in] numTaps number of nonzero coefficients in the filter. + * @param[in] *pCoeffs points to the array of filter coefficients. + * @param[in] *pState points to the state buffer. + * @param[in] *pTapDelay points to the array of offset times. + * @param[in] maxDelay maximum offset time supported. + * @param[in] blockSize number of samples that will be processed per block. + * @return none + */ + + void arm_fir_sparse_init_q7( + arm_fir_sparse_instance_q7 * S, + uint16_t numTaps, + q7_t * pCoeffs, + q7_t * pState, + int32_t *pTapDelay, + uint16_t maxDelay, + uint32_t blockSize); + + + /* + * @brief Floating-point sin_cos function. + * @param[in] theta input value in degrees + * @param[out] *pSinVal points to the processed sine output. + * @param[out] *pCosVal points to the processed cos output. + * @return none. + */ + + void arm_sin_cos_f32( + float32_t theta, + float32_t *pSinVal, + float32_t *pCcosVal); + + /* + * @brief Q31 sin_cos function. + * @param[in] theta scaled input value in degrees + * @param[out] *pSinVal points to the processed sine output. + * @param[out] *pCosVal points to the processed cosine output. + * @return none. + */ + + void arm_sin_cos_q31( + q31_t theta, + q31_t *pSinVal, + q31_t *pCosVal); + + + /** + * @brief Floating-point complex conjugate. + * @param[in] *pSrc points to the input vector + * @param[out] *pDst points to the output vector + * @param[in] numSamples number of complex samples in each vector + * @return none. + */ + + void arm_cmplx_conj_f32( + float32_t * pSrc, + float32_t * pDst, + uint32_t numSamples); + + /** + * @brief Q31 complex conjugate. + * @param[in] *pSrc points to the input vector + * @param[out] *pDst points to the output vector + * @param[in] numSamples number of complex samples in each vector + * @return none. + */ + + void arm_cmplx_conj_q31( + q31_t * pSrc, + q31_t * pDst, + uint32_t numSamples); + + /** + * @brief Q15 complex conjugate. + * @param[in] *pSrc points to the input vector + * @param[out] *pDst points to the output vector + * @param[in] numSamples number of complex samples in each vector + * @return none. + */ + + void arm_cmplx_conj_q15( + q15_t * pSrc, + q15_t * pDst, + uint32_t numSamples); + + + + /** + * @brief Floating-point complex magnitude squared + * @param[in] *pSrc points to the complex input vector + * @param[out] *pDst points to the real output vector + * @param[in] numSamples number of complex samples in the input vector + * @return none. + */ + + void arm_cmplx_mag_squared_f32( + float32_t * pSrc, + float32_t * pDst, + uint32_t numSamples); + + /** + * @brief Q31 complex magnitude squared + * @param[in] *pSrc points to the complex input vector + * @param[out] *pDst points to the real output vector + * @param[in] numSamples number of complex samples in the input vector + * @return none. + */ + + void arm_cmplx_mag_squared_q31( + q31_t * pSrc, + q31_t * pDst, + uint32_t numSamples); + + /** + * @brief Q15 complex magnitude squared + * @param[in] *pSrc points to the complex input vector + * @param[out] *pDst points to the real output vector + * @param[in] numSamples number of complex samples in the input vector + * @return none. + */ + + void arm_cmplx_mag_squared_q15( + q15_t * pSrc, + q15_t * pDst, + uint32_t numSamples); + + + /** + * @ingroup groupController + */ + + /** + * @defgroup PID PID Motor Control + * + * A Proportional Integral Derivative (PID) controller is a generic feedback control + * loop mechanism widely used in industrial control systems. + * A PID controller is the most commonly used type of feedback controller. + * + * This set of functions implements (PID) controllers + * for Q15, Q31, and floating-point data types. The functions operate on a single sample + * of data and each call to the function returns a single processed value. + * S points to an instance of the PID control data structure. in + * is the input sample value. The functions return the output value. + * + * \par Algorithm: + *
+   *    y[n] = y[n-1] + A0 * x[n] + A1 * x[n-1] + A2 * x[n-2]
+   *    A0 = Kp + Ki + Kd
+   *    A1 = (-Kp ) - (2 * Kd )
+   *    A2 = Kd  
+ * + * \par + * where \c Kp is proportional constant, \c Ki is Integral constant and \c Kd is Derivative constant + * + * \par + * \image html PID.gif "Proportional Integral Derivative Controller" + * + * \par + * The PID controller calculates an "error" value as the difference between + * the measured output and the reference input. + * The controller attempts to minimize the error by adjusting the process control inputs. + * The proportional value determines the reaction to the current error, + * the integral value determines the reaction based on the sum of recent errors, + * and the derivative value determines the reaction based on the rate at which the error has been changing. + * + * \par Instance Structure + * The Gains A0, A1, A2 and state variables for a PID controller are stored together in an instance data structure. + * A separate instance structure must be defined for each PID Controller. + * There are separate instance structure declarations for each of the 3 supported data types. + * + * \par Reset Functions + * There is also an associated reset function for each data type which clears the state array. + * + * \par Initialization Functions + * There is also an associated initialization function for each data type. + * The initialization function performs the following operations: + * - Initializes the Gains A0, A1, A2 from Kp,Ki, Kd gains. + * - Zeros out the values in the state buffer. + * + * \par + * Instance structure cannot be placed into a const data section and it is recommended to use the initialization function. + * + * \par Fixed-Point Behavior + * Care must be taken when using the fixed-point versions of the PID Controller functions. + * In particular, the overflow and saturation behavior of the accumulator used in each function must be considered. + * Refer to the function specific documentation below for usage guidelines. + */ + + /** + * @addtogroup PID + * @{ + */ + + /** + * @brief Process function for the floating-point PID Control. + * @param[in,out] *S is an instance of the floating-point PID Control structure + * @param[in] in input sample to process + * @return out processed output sample. + */ + + + __STATIC_INLINE float32_t arm_pid_f32( + arm_pid_instance_f32 * S, + float32_t in) + { + float32_t out; + + /* y[n] = y[n-1] + A0 * x[n] + A1 * x[n-1] + A2 * x[n-2] */ + out = (S->A0 * in) + + (S->A1 * S->state[0]) + (S->A2 * S->state[1]) + (S->state[2]); + + /* Update state */ + S->state[1] = S->state[0]; + S->state[0] = in; + S->state[2] = out; + + /* return to application */ + return (out); + + } + + /** + * @brief Process function for the Q31 PID Control. + * @param[in,out] *S points to an instance of the Q31 PID Control structure + * @param[in] in input sample to process + * @return out processed output sample. + * + * Scaling and Overflow Behavior: + * \par + * The function is implemented using an internal 64-bit accumulator. + * The accumulator has a 2.62 format and maintains full precision of the intermediate multiplication results but provides only a single guard bit. + * Thus, if the accumulator result overflows it wraps around rather than clip. + * In order to avoid overflows completely the input signal must be scaled down by 2 bits as there are four additions. + * After all multiply-accumulates are performed, the 2.62 accumulator is truncated to 1.32 format and then saturated to 1.31 format. + */ + + __STATIC_INLINE q31_t arm_pid_q31( + arm_pid_instance_q31 * S, + q31_t in) + { + q63_t acc; + q31_t out; + + /* acc = A0 * x[n] */ + acc = (q63_t) S->A0 * in; + + /* acc += A1 * x[n-1] */ + acc += (q63_t) S->A1 * S->state[0]; + + /* acc += A2 * x[n-2] */ + acc += (q63_t) S->A2 * S->state[1]; + + /* convert output to 1.31 format to add y[n-1] */ + out = (q31_t) (acc >> 31u); + + /* out += y[n-1] */ + out += S->state[2]; + + /* Update state */ + S->state[1] = S->state[0]; + S->state[0] = in; + S->state[2] = out; + + /* return to application */ + return (out); + + } + + /** + * @brief Process function for the Q15 PID Control. + * @param[in,out] *S points to an instance of the Q15 PID Control structure + * @param[in] in input sample to process + * @return out processed output sample. + * + * Scaling and Overflow Behavior: + * \par + * The function is implemented using a 64-bit internal accumulator. + * Both Gains and state variables are represented in 1.15 format and multiplications yield a 2.30 result. + * The 2.30 intermediate results are accumulated in a 64-bit accumulator in 34.30 format. + * There is no risk of internal overflow with this approach and the full precision of intermediate multiplications is preserved. + * After all additions have been performed, the accumulator is truncated to 34.15 format by discarding low 15 bits. + * Lastly, the accumulator is saturated to yield a result in 1.15 format. + */ + + __STATIC_INLINE q15_t arm_pid_q15( + arm_pid_instance_q15 * S, + q15_t in) + { + q63_t acc; + q15_t out; + + /* Implementation of PID controller */ + + #ifdef ARM_MATH_CM0 + + /* acc = A0 * x[n] */ + acc = ((q31_t) S->A0 )* in ; + + #else + + /* acc = A0 * x[n] */ + acc = (q31_t) __SMUAD(S->A0, in); + + #endif + + #ifdef ARM_MATH_CM0 + + /* acc += A1 * x[n-1] + A2 * x[n-2] */ + acc += (q31_t) S->A1 * S->state[0] ; + acc += (q31_t) S->A2 * S->state[1] ; + + #else + + /* acc += A1 * x[n-1] + A2 * x[n-2] */ + acc = __SMLALD(S->A1, (q31_t)__SIMD32(S->state), acc); + + #endif + + /* acc += y[n-1] */ + acc += (q31_t) S->state[2] << 15; + + /* saturate the output */ + out = (q15_t) (__SSAT((acc >> 15), 16)); + + /* Update state */ + S->state[1] = S->state[0]; + S->state[0] = in; + S->state[2] = out; + + /* return to application */ + return (out); + + } + + /** + * @} end of PID group + */ + + + /** + * @brief Floating-point matrix inverse. + * @param[in] *src points to the instance of the input floating-point matrix structure. + * @param[out] *dst points to the instance of the output floating-point matrix structure. + * @return The function returns ARM_MATH_SIZE_MISMATCH, if the dimensions do not match. + * If the input matrix is singular (does not have an inverse), then the algorithm terminates and returns error status ARM_MATH_SINGULAR. + */ + + arm_status arm_mat_inverse_f32( + const arm_matrix_instance_f32 * src, + arm_matrix_instance_f32 * dst); + + + + /** + * @ingroup groupController + */ + + + /** + * @defgroup clarke Vector Clarke Transform + * Forward Clarke transform converts the instantaneous stator phases into a two-coordinate time invariant vector. + * Generally the Clarke transform uses three-phase currents Ia, Ib and Ic to calculate currents + * in the two-phase orthogonal stator axis Ialpha and Ibeta. + * When Ialpha is superposed with Ia as shown in the figure below + * \image html clarke.gif Stator current space vector and its components in (a,b). + * and Ia + Ib + Ic = 0, in this condition Ialpha and Ibeta + * can be calculated using only Ia and Ib. + * + * The function operates on a single sample of data and each call to the function returns the processed output. + * The library provides separate functions for Q31 and floating-point data types. + * \par Algorithm + * \image html clarkeFormula.gif + * where Ia and Ib are the instantaneous stator phases and + * pIalpha and pIbeta are the two coordinates of time invariant vector. + * \par Fixed-Point Behavior + * Care must be taken when using the Q31 version of the Clarke transform. + * In particular, the overflow and saturation behavior of the accumulator used must be considered. + * Refer to the function specific documentation below for usage guidelines. + */ + + /** + * @addtogroup clarke + * @{ + */ + + /** + * + * @brief Floating-point Clarke transform + * @param[in] Ia input three-phase coordinate a + * @param[in] Ib input three-phase coordinate b + * @param[out] *pIalpha points to output two-phase orthogonal vector axis alpha + * @param[out] *pIbeta points to output two-phase orthogonal vector axis beta + * @return none. + */ + + __STATIC_INLINE void arm_clarke_f32( + float32_t Ia, + float32_t Ib, + float32_t * pIalpha, + float32_t * pIbeta) + { + /* Calculate pIalpha using the equation, pIalpha = Ia */ + *pIalpha = Ia; + + /* Calculate pIbeta using the equation, pIbeta = (1/sqrt(3)) * Ia + (2/sqrt(3)) * Ib */ + *pIbeta = ((float32_t) 0.57735026919 * Ia + (float32_t) 1.15470053838 * Ib); + + } + + /** + * @brief Clarke transform for Q31 version + * @param[in] Ia input three-phase coordinate a + * @param[in] Ib input three-phase coordinate b + * @param[out] *pIalpha points to output two-phase orthogonal vector axis alpha + * @param[out] *pIbeta points to output two-phase orthogonal vector axis beta + * @return none. + * + * Scaling and Overflow Behavior: + * \par + * The function is implemented using an internal 32-bit accumulator. + * The accumulator maintains 1.31 format by truncating lower 31 bits of the intermediate multiplication in 2.62 format. + * There is saturation on the addition, hence there is no risk of overflow. + */ + + __STATIC_INLINE void arm_clarke_q31( + q31_t Ia, + q31_t Ib, + q31_t * pIalpha, + q31_t * pIbeta) + { + q31_t product1, product2; /* Temporary variables used to store intermediate results */ + + /* Calculating pIalpha from Ia by equation pIalpha = Ia */ + *pIalpha = Ia; + + /* Intermediate product is calculated by (1/(sqrt(3)) * Ia) */ + product1 = (q31_t) (((q63_t) Ia * 0x24F34E8B) >> 30); + + /* Intermediate product is calculated by (2/sqrt(3) * Ib) */ + product2 = (q31_t) (((q63_t) Ib * 0x49E69D16) >> 30); + + /* pIbeta is calculated by adding the intermediate products */ + *pIbeta = __QADD(product1, product2); + } + + /** + * @} end of clarke group + */ + + /** + * @brief Converts the elements of the Q7 vector to Q31 vector. + * @param[in] *pSrc input pointer + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_q7_to_q31( + q7_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + + + + /** + * @ingroup groupController + */ + + /** + * @defgroup inv_clarke Vector Inverse Clarke Transform + * Inverse Clarke transform converts the two-coordinate time invariant vector into instantaneous stator phases. + * + * The function operates on a single sample of data and each call to the function returns the processed output. + * The library provides separate functions for Q31 and floating-point data types. + * \par Algorithm + * \image html clarkeInvFormula.gif + * where pIa and pIb are the instantaneous stator phases and + * Ialpha and Ibeta are the two coordinates of time invariant vector. + * \par Fixed-Point Behavior + * Care must be taken when using the Q31 version of the Clarke transform. + * In particular, the overflow and saturation behavior of the accumulator used must be considered. + * Refer to the function specific documentation below for usage guidelines. + */ + + /** + * @addtogroup inv_clarke + * @{ + */ + + /** + * @brief Floating-point Inverse Clarke transform + * @param[in] Ialpha input two-phase orthogonal vector axis alpha + * @param[in] Ibeta input two-phase orthogonal vector axis beta + * @param[out] *pIa points to output three-phase coordinate a + * @param[out] *pIb points to output three-phase coordinate b + * @return none. + */ + + + __STATIC_INLINE void arm_inv_clarke_f32( + float32_t Ialpha, + float32_t Ibeta, + float32_t * pIa, + float32_t * pIb) + { + /* Calculating pIa from Ialpha by equation pIa = Ialpha */ + *pIa = Ialpha; + + /* Calculating pIb from Ialpha and Ibeta by equation pIb = -(1/2) * Ialpha + (sqrt(3)/2) * Ibeta */ + *pIb = -0.5 * Ialpha + (float32_t) 0.8660254039 *Ibeta; + + } + + /** + * @brief Inverse Clarke transform for Q31 version + * @param[in] Ialpha input two-phase orthogonal vector axis alpha + * @param[in] Ibeta input two-phase orthogonal vector axis beta + * @param[out] *pIa points to output three-phase coordinate a + * @param[out] *pIb points to output three-phase coordinate b + * @return none. + * + * Scaling and Overflow Behavior: + * \par + * The function is implemented using an internal 32-bit accumulator. + * The accumulator maintains 1.31 format by truncating lower 31 bits of the intermediate multiplication in 2.62 format. + * There is saturation on the subtraction, hence there is no risk of overflow. + */ + + __STATIC_INLINE void arm_inv_clarke_q31( + q31_t Ialpha, + q31_t Ibeta, + q31_t * pIa, + q31_t * pIb) + { + q31_t product1, product2; /* Temporary variables used to store intermediate results */ + + /* Calculating pIa from Ialpha by equation pIa = Ialpha */ + *pIa = Ialpha; + + /* Intermediate product is calculated by (1/(2*sqrt(3)) * Ia) */ + product1 = (q31_t) (((q63_t) (Ialpha) * (0x40000000)) >> 31); + + /* Intermediate product is calculated by (1/sqrt(3) * pIb) */ + product2 = (q31_t) (((q63_t) (Ibeta) * (0x6ED9EBA1)) >> 31); + + /* pIb is calculated by subtracting the products */ + *pIb = __QSUB(product2, product1); + + } + + /** + * @} end of inv_clarke group + */ + + /** + * @brief Converts the elements of the Q7 vector to Q15 vector. + * @param[in] *pSrc input pointer + * @param[out] *pDst output pointer + * @param[in] blockSize number of samples to process + * @return none. + */ + void arm_q7_to_q15( + q7_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + + + /** + * @ingroup groupController + */ + + /** + * @defgroup park Vector Park Transform + * + * Forward Park transform converts the input two-coordinate vector to flux and torque components. + * The Park transform can be used to realize the transformation of the Ialpha and the Ibeta currents + * from the stationary to the moving reference frame and control the spatial relationship between + * the stator vector current and rotor flux vector. + * If we consider the d axis aligned with the rotor flux, the diagram below shows the + * current vector and the relationship from the two reference frames: + * \image html park.gif "Stator current space vector and its component in (a,b) and in the d,q rotating reference frame" + * + * The function operates on a single sample of data and each call to the function returns the processed output. + * The library provides separate functions for Q31 and floating-point data types. + * \par Algorithm + * \image html parkFormula.gif + * where Ialpha and Ibeta are the stator vector components, + * pId and pIq are rotor vector components and cosVal and sinVal are the + * cosine and sine values of theta (rotor flux position). + * \par Fixed-Point Behavior + * Care must be taken when using the Q31 version of the Park transform. + * In particular, the overflow and saturation behavior of the accumulator used must be considered. + * Refer to the function specific documentation below for usage guidelines. + */ + + /** + * @addtogroup park + * @{ + */ + + /** + * @brief Floating-point Park transform + * @param[in] Ialpha input two-phase vector coordinate alpha + * @param[in] Ibeta input two-phase vector coordinate beta + * @param[out] *pId points to output rotor reference frame d + * @param[out] *pIq points to output rotor reference frame q + * @param[in] sinVal sine value of rotation angle theta + * @param[in] cosVal cosine value of rotation angle theta + * @return none. + * + * The function implements the forward Park transform. + * + */ + + __STATIC_INLINE void arm_park_f32( + float32_t Ialpha, + float32_t Ibeta, + float32_t * pId, + float32_t * pIq, + float32_t sinVal, + float32_t cosVal) + { + /* Calculate pId using the equation, pId = Ialpha * cosVal + Ibeta * sinVal */ + *pId = Ialpha * cosVal + Ibeta * sinVal; + + /* Calculate pIq using the equation, pIq = - Ialpha * sinVal + Ibeta * cosVal */ + *pIq = -Ialpha * sinVal + Ibeta * cosVal; + + } + + /** + * @brief Park transform for Q31 version + * @param[in] Ialpha input two-phase vector coordinate alpha + * @param[in] Ibeta input two-phase vector coordinate beta + * @param[out] *pId points to output rotor reference frame d + * @param[out] *pIq points to output rotor reference frame q + * @param[in] sinVal sine value of rotation angle theta + * @param[in] cosVal cosine value of rotation angle theta + * @return none. + * + * Scaling and Overflow Behavior: + * \par + * The function is implemented using an internal 32-bit accumulator. + * The accumulator maintains 1.31 format by truncating lower 31 bits of the intermediate multiplication in 2.62 format. + * There is saturation on the addition and subtraction, hence there is no risk of overflow. + */ + + + __STATIC_INLINE void arm_park_q31( + q31_t Ialpha, + q31_t Ibeta, + q31_t * pId, + q31_t * pIq, + q31_t sinVal, + q31_t cosVal) + { + q31_t product1, product2; /* Temporary variables used to store intermediate results */ + q31_t product3, product4; /* Temporary variables used to store intermediate results */ + + /* Intermediate product is calculated by (Ialpha * cosVal) */ + product1 = (q31_t) (((q63_t) (Ialpha) * (cosVal)) >> 31); + + /* Intermediate product is calculated by (Ibeta * sinVal) */ + product2 = (q31_t) (((q63_t) (Ibeta) * (sinVal)) >> 31); + + + /* Intermediate product is calculated by (Ialpha * sinVal) */ + product3 = (q31_t) (((q63_t) (Ialpha) * (sinVal)) >> 31); + + /* Intermediate product is calculated by (Ibeta * cosVal) */ + product4 = (q31_t) (((q63_t) (Ibeta) * (cosVal)) >> 31); + + /* Calculate pId by adding the two intermediate products 1 and 2 */ + *pId = __QADD(product1, product2); + + /* Calculate pIq by subtracting the two intermediate products 3 from 4 */ + *pIq = __QSUB(product4, product3); + } + + /** + * @} end of park group + */ + + /** + * @brief Converts the elements of the Q7 vector to floating-point vector. + * @param[in] *pSrc is input pointer + * @param[out] *pDst is output pointer + * @param[in] blockSize is the number of samples to process + * @return none. + */ + void arm_q7_to_float( + q7_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + + /** + * @ingroup groupController + */ + + /** + * @defgroup inv_park Vector Inverse Park transform + * Inverse Park transform converts the input flux and torque components to two-coordinate vector. + * + * The function operates on a single sample of data and each call to the function returns the processed output. + * The library provides separate functions for Q31 and floating-point data types. + * \par Algorithm + * \image html parkInvFormula.gif + * where pIalpha and pIbeta are the stator vector components, + * Id and Iq are rotor vector components and cosVal and sinVal are the + * cosine and sine values of theta (rotor flux position). + * \par Fixed-Point Behavior + * Care must be taken when using the Q31 version of the Park transform. + * In particular, the overflow and saturation behavior of the accumulator used must be considered. + * Refer to the function specific documentation below for usage guidelines. + */ + + /** + * @addtogroup inv_park + * @{ + */ + + /** + * @brief Floating-point Inverse Park transform + * @param[in] Id input coordinate of rotor reference frame d + * @param[in] Iq input coordinate of rotor reference frame q + * @param[out] *pIalpha points to output two-phase orthogonal vector axis alpha + * @param[out] *pIbeta points to output two-phase orthogonal vector axis beta + * @param[in] sinVal sine value of rotation angle theta + * @param[in] cosVal cosine value of rotation angle theta + * @return none. + */ + + __STATIC_INLINE void arm_inv_park_f32( + float32_t Id, + float32_t Iq, + float32_t * pIalpha, + float32_t * pIbeta, + float32_t sinVal, + float32_t cosVal) + { + /* Calculate pIalpha using the equation, pIalpha = Id * cosVal - Iq * sinVal */ + *pIalpha = Id * cosVal - Iq * sinVal; + + /* Calculate pIbeta using the equation, pIbeta = Id * sinVal + Iq * cosVal */ + *pIbeta = Id * sinVal + Iq * cosVal; + + } + + + /** + * @brief Inverse Park transform for Q31 version + * @param[in] Id input coordinate of rotor reference frame d + * @param[in] Iq input coordinate of rotor reference frame q + * @param[out] *pIalpha points to output two-phase orthogonal vector axis alpha + * @param[out] *pIbeta points to output two-phase orthogonal vector axis beta + * @param[in] sinVal sine value of rotation angle theta + * @param[in] cosVal cosine value of rotation angle theta + * @return none. + * + * Scaling and Overflow Behavior: + * \par + * The function is implemented using an internal 32-bit accumulator. + * The accumulator maintains 1.31 format by truncating lower 31 bits of the intermediate multiplication in 2.62 format. + * There is saturation on the addition, hence there is no risk of overflow. + */ + + + __STATIC_INLINE void arm_inv_park_q31( + q31_t Id, + q31_t Iq, + q31_t * pIalpha, + q31_t * pIbeta, + q31_t sinVal, + q31_t cosVal) + { + q31_t product1, product2; /* Temporary variables used to store intermediate results */ + q31_t product3, product4; /* Temporary variables used to store intermediate results */ + + /* Intermediate product is calculated by (Id * cosVal) */ + product1 = (q31_t) (((q63_t) (Id) * (cosVal)) >> 31); + + /* Intermediate product is calculated by (Iq * sinVal) */ + product2 = (q31_t) (((q63_t) (Iq) * (sinVal)) >> 31); + + + /* Intermediate product is calculated by (Id * sinVal) */ + product3 = (q31_t) (((q63_t) (Id) * (sinVal)) >> 31); + + /* Intermediate product is calculated by (Iq * cosVal) */ + product4 = (q31_t) (((q63_t) (Iq) * (cosVal)) >> 31); + + /* Calculate pIalpha by using the two intermediate products 1 and 2 */ + *pIalpha = __QSUB(product1, product2); + + /* Calculate pIbeta by using the two intermediate products 3 and 4 */ + *pIbeta = __QADD(product4, product3); + + } + + /** + * @} end of Inverse park group + */ + + + /** + * @brief Converts the elements of the Q31 vector to floating-point vector. + * @param[in] *pSrc is input pointer + * @param[out] *pDst is output pointer + * @param[in] blockSize is the number of samples to process + * @return none. + */ + void arm_q31_to_float( + q31_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + /** + * @ingroup groupInterpolation + */ + + /** + * @defgroup LinearInterpolate Linear Interpolation + * + * Linear interpolation is a method of curve fitting using linear polynomials. + * Linear interpolation works by effectively drawing a straight line between two neighboring samples and returning the appropriate point along that line + * + * \par + * \image html LinearInterp.gif "Linear interpolation" + * + * \par + * A Linear Interpolate function calculates an output value(y), for the input(x) + * using linear interpolation of the input values x0, x1( nearest input values) and the output values y0 and y1(nearest output values) + * + * \par Algorithm: + *
+   *       y = y0 + (x - x0) * ((y1 - y0)/(x1-x0))
+   *       where x0, x1 are nearest values of input x
+   *             y0, y1 are nearest values to output y
+   * 
+ * + * \par + * This set of functions implements Linear interpolation process + * for Q7, Q15, Q31, and floating-point data types. The functions operate on a single + * sample of data and each call to the function returns a single processed value. + * S points to an instance of the Linear Interpolate function data structure. + * x is the input sample value. The functions returns the output value. + * + * \par + * if x is outside of the table boundary, Linear interpolation returns first value of the table + * if x is below input range and returns last value of table if x is above range. + */ + + /** + * @addtogroup LinearInterpolate + * @{ + */ + + /** + * @brief Process function for the floating-point Linear Interpolation Function. + * @param[in,out] *S is an instance of the floating-point Linear Interpolation structure + * @param[in] x input sample to process + * @return y processed output sample. + * + */ + + __STATIC_INLINE float32_t arm_linear_interp_f32( + arm_linear_interp_instance_f32 * S, + float32_t x) + { + + float32_t y; + float32_t x0, x1; /* Nearest input values */ + float32_t y0, y1; /* Nearest output values */ + float32_t xSpacing = S->xSpacing; /* spacing between input values */ + int32_t i; /* Index variable */ + float32_t *pYData = S->pYData; /* pointer to output table */ + + /* Calculation of index */ + i = (x - S->x1) / xSpacing; + + if(i < 0) + { + /* Iniatilize output for below specified range as least output value of table */ + y = pYData[0]; + } + else if(i >= S->nValues) + { + /* Iniatilize output for above specified range as last output value of table */ + y = pYData[S->nValues-1]; + } + else + { + /* Calculation of nearest input values */ + x0 = S->x1 + i * xSpacing; + x1 = S->x1 + (i +1) * xSpacing; + + /* Read of nearest output values */ + y0 = pYData[i]; + y1 = pYData[i + 1]; + + /* Calculation of output */ + y = y0 + (x - x0) * ((y1 - y0)/(x1-x0)); + + } + + /* returns output value */ + return (y); + } + + /** + * + * @brief Process function for the Q31 Linear Interpolation Function. + * @param[in] *pYData pointer to Q31 Linear Interpolation table + * @param[in] x input sample to process + * @param[in] nValues number of table values + * @return y processed output sample. + * + * \par + * Input sample x is in 12.20 format which contains 12 bits for table index and 20 bits for fractional part. + * This function can support maximum of table size 2^12. + * + */ + + + __STATIC_INLINE q31_t arm_linear_interp_q31(q31_t *pYData, + q31_t x, uint32_t nValues) + { + q31_t y; /* output */ + q31_t y0, y1; /* Nearest output values */ + q31_t fract; /* fractional part */ + int32_t index; /* Index to read nearest output values */ + + /* Input is in 12.20 format */ + /* 12 bits for the table index */ + /* Index value calculation */ + index = ((x & 0xFFF00000) >> 20); + + if(index >= (nValues - 1)) + { + return(pYData[nValues - 1]); + } + else if(index < 0) + { + return(pYData[0]); + } + else + { + + /* 20 bits for the fractional part */ + /* shift left by 11 to keep fract in 1.31 format */ + fract = (x & 0x000FFFFF) << 11; + + /* Read two nearest output values from the index in 1.31(q31) format */ + y0 = pYData[index]; + y1 = pYData[index + 1u]; + + /* Calculation of y0 * (1-fract) and y is in 2.30 format */ + y = ((q31_t) ((q63_t) y0 * (0x7FFFFFFF - fract) >> 32)); + + /* Calculation of y0 * (1-fract) + y1 *fract and y is in 2.30 format */ + y += ((q31_t) (((q63_t) y1 * fract) >> 32)); + + /* Convert y to 1.31 format */ + return (y << 1u); + + } + + } + + /** + * + * @brief Process function for the Q15 Linear Interpolation Function. + * @param[in] *pYData pointer to Q15 Linear Interpolation table + * @param[in] x input sample to process + * @param[in] nValues number of table values + * @return y processed output sample. + * + * \par + * Input sample x is in 12.20 format which contains 12 bits for table index and 20 bits for fractional part. + * This function can support maximum of table size 2^12. + * + */ + + + __STATIC_INLINE q15_t arm_linear_interp_q15(q15_t *pYData, q31_t x, uint32_t nValues) + { + q63_t y; /* output */ + q15_t y0, y1; /* Nearest output values */ + q31_t fract; /* fractional part */ + int32_t index; /* Index to read nearest output values */ + + /* Input is in 12.20 format */ + /* 12 bits for the table index */ + /* Index value calculation */ + index = ((x & 0xFFF00000) >> 20u); + + if(index >= (nValues - 1)) + { + return(pYData[nValues - 1]); + } + else if(index < 0) + { + return(pYData[0]); + } + else + { + /* 20 bits for the fractional part */ + /* fract is in 12.20 format */ + fract = (x & 0x000FFFFF); + + /* Read two nearest output values from the index */ + y0 = pYData[index]; + y1 = pYData[index + 1u]; + + /* Calculation of y0 * (1-fract) and y is in 13.35 format */ + y = ((q63_t) y0 * (0xFFFFF - fract)); + + /* Calculation of (y0 * (1-fract) + y1 * fract) and y is in 13.35 format */ + y += ((q63_t) y1 * (fract)); + + /* convert y to 1.15 format */ + return (y >> 20); + } + + + } + + /** + * + * @brief Process function for the Q7 Linear Interpolation Function. + * @param[in] *pYData pointer to Q7 Linear Interpolation table + * @param[in] x input sample to process + * @param[in] nValues number of table values + * @return y processed output sample. + * + * \par + * Input sample x is in 12.20 format which contains 12 bits for table index and 20 bits for fractional part. + * This function can support maximum of table size 2^12. + */ + + + __STATIC_INLINE q7_t arm_linear_interp_q7(q7_t *pYData, q31_t x, uint32_t nValues) + { + q31_t y; /* output */ + q7_t y0, y1; /* Nearest output values */ + q31_t fract; /* fractional part */ + int32_t index; /* Index to read nearest output values */ + + /* Input is in 12.20 format */ + /* 12 bits for the table index */ + /* Index value calculation */ + index = ((x & 0xFFF00000) >> 20u); + + + if(index >= (nValues - 1)) + { + return(pYData[nValues - 1]); + } + else if(index < 0) + { + return(pYData[0]); + } + else + { + + /* 20 bits for the fractional part */ + /* fract is in 12.20 format */ + fract = (x & 0x000FFFFF); + + /* Read two nearest output values from the index and are in 1.7(q7) format */ + y0 = pYData[index]; + y1 = pYData[index + 1u]; + + /* Calculation of y0 * (1-fract ) and y is in 13.27(q27) format */ + y = ((y0 * (0xFFFFF - fract))); + + /* Calculation of y1 * fract + y0 * (1-fract) and y is in 13.27(q27) format */ + y += (y1 * fract); + + /* convert y to 1.7(q7) format */ + return (y >> 20u); + + } + + } + /** + * @} end of LinearInterpolate group + */ + + /** + * @brief Fast approximation to the trigonometric sine function for floating-point data. + * @param[in] x input value in radians. + * @return sin(x). + */ + + float32_t arm_sin_f32( + float32_t x); + + /** + * @brief Fast approximation to the trigonometric sine function for Q31 data. + * @param[in] x Scaled input value in radians. + * @return sin(x). + */ + + q31_t arm_sin_q31( + q31_t x); + + /** + * @brief Fast approximation to the trigonometric sine function for Q15 data. + * @param[in] x Scaled input value in radians. + * @return sin(x). + */ + + q15_t arm_sin_q15( + q15_t x); + + /** + * @brief Fast approximation to the trigonometric cosine function for floating-point data. + * @param[in] x input value in radians. + * @return cos(x). + */ + + float32_t arm_cos_f32( + float32_t x); + + /** + * @brief Fast approximation to the trigonometric cosine function for Q31 data. + * @param[in] x Scaled input value in radians. + * @return cos(x). + */ + + q31_t arm_cos_q31( + q31_t x); + + /** + * @brief Fast approximation to the trigonometric cosine function for Q15 data. + * @param[in] x Scaled input value in radians. + * @return cos(x). + */ + + q15_t arm_cos_q15( + q15_t x); + + + /** + * @ingroup groupFastMath + */ + + + /** + * @defgroup SQRT Square Root + * + * Computes the square root of a number. + * There are separate functions for Q15, Q31, and floating-point data types. + * The square root function is computed using the Newton-Raphson algorithm. + * This is an iterative algorithm of the form: + *
+   *      x1 = x0 - f(x0)/f'(x0)
+   * 
+ * where x1 is the current estimate, + * x0 is the previous estimate and + * f'(x0) is the derivative of f() evaluated at x0. + * For the square root function, the algorithm reduces to: + *
+   *     x0 = in/2                         [initial guess]
+   *     x1 = 1/2 * ( x0 + in / x0)        [each iteration]
+   * 
+ */ + + + /** + * @addtogroup SQRT + * @{ + */ + + /** + * @brief Floating-point square root function. + * @param[in] in input value. + * @param[out] *pOut square root of input value. + * @return The function returns ARM_MATH_SUCCESS if input value is positive value or ARM_MATH_ARGUMENT_ERROR if + * in is negative value and returns zero output for negative values. + */ + + __STATIC_INLINE arm_status arm_sqrt_f32( + float32_t in, float32_t *pOut) + { + if(in > 0) + { + +// #if __FPU_USED + #if (__FPU_USED == 1) && defined ( __CC_ARM ) + *pOut = __sqrtf(in); + #elif (__FPU_USED == 1) && defined ( __TMS_740 ) + *pOut = __builtin_sqrtf(in); + #else + *pOut = sqrtf(in); + #endif + + return (ARM_MATH_SUCCESS); + } + else + { + *pOut = 0.0f; + return (ARM_MATH_ARGUMENT_ERROR); + } + + } + + + /** + * @brief Q31 square root function. + * @param[in] in input value. The range of the input value is [0 +1) or 0x00000000 to 0x7FFFFFFF. + * @param[out] *pOut square root of input value. + * @return The function returns ARM_MATH_SUCCESS if input value is positive value or ARM_MATH_ARGUMENT_ERROR if + * in is negative value and returns zero output for negative values. + */ + arm_status arm_sqrt_q31( + q31_t in, q31_t *pOut); + + /** + * @brief Q15 square root function. + * @param[in] in input value. The range of the input value is [0 +1) or 0x0000 to 0x7FFF. + * @param[out] *pOut square root of input value. + * @return The function returns ARM_MATH_SUCCESS if input value is positive value or ARM_MATH_ARGUMENT_ERROR if + * in is negative value and returns zero output for negative values. + */ + arm_status arm_sqrt_q15( + q15_t in, q15_t *pOut); + + /** + * @} end of SQRT group + */ + + + + + + + /** + * @brief floating-point Circular write function. + */ + + __STATIC_INLINE void arm_circularWrite_f32( + int32_t * circBuffer, + int32_t L, + uint16_t * writeOffset, + int32_t bufferInc, + const int32_t * src, + int32_t srcInc, + uint32_t blockSize) + { + uint32_t i = 0u; + int32_t wOffset; + + /* Copy the value of Index pointer that points + * to the current location where the input samples to be copied */ + wOffset = *writeOffset; + + /* Loop over the blockSize */ + i = blockSize; + + while(i > 0u) + { + /* copy the input sample to the circular buffer */ + circBuffer[wOffset] = *src; + + /* Update the input pointer */ + src += srcInc; + + /* Circularly update wOffset. Watch out for positive and negative value */ + wOffset += bufferInc; + if(wOffset >= L) + wOffset -= L; + + /* Decrement the loop counter */ + i--; + } + + /* Update the index pointer */ + *writeOffset = wOffset; + } + + + + /** + * @brief floating-point Circular Read function. + */ + __STATIC_INLINE void arm_circularRead_f32( + int32_t * circBuffer, + int32_t L, + int32_t * readOffset, + int32_t bufferInc, + int32_t * dst, + int32_t * dst_base, + int32_t dst_length, + int32_t dstInc, + uint32_t blockSize) + { + uint32_t i = 0u; + int32_t rOffset, dst_end; + + /* Copy the value of Index pointer that points + * to the current location from where the input samples to be read */ + rOffset = *readOffset; + dst_end = (int32_t) (dst_base + dst_length); + + /* Loop over the blockSize */ + i = blockSize; + + while(i > 0u) + { + /* copy the sample from the circular buffer to the destination buffer */ + *dst = circBuffer[rOffset]; + + /* Update the input pointer */ + dst += dstInc; + + if(dst == (int32_t *) dst_end) + { + dst = dst_base; + } + + /* Circularly update rOffset. Watch out for positive and negative value */ + rOffset += bufferInc; + + if(rOffset >= L) + { + rOffset -= L; + } + + /* Decrement the loop counter */ + i--; + } + + /* Update the index pointer */ + *readOffset = rOffset; + } + + /** + * @brief Q15 Circular write function. + */ + + __STATIC_INLINE void arm_circularWrite_q15( + q15_t * circBuffer, + int32_t L, + uint16_t * writeOffset, + int32_t bufferInc, + const q15_t * src, + int32_t srcInc, + uint32_t blockSize) + { + uint32_t i = 0u; + int32_t wOffset; + + /* Copy the value of Index pointer that points + * to the current location where the input samples to be copied */ + wOffset = *writeOffset; + + /* Loop over the blockSize */ + i = blockSize; + + while(i > 0u) + { + /* copy the input sample to the circular buffer */ + circBuffer[wOffset] = *src; + + /* Update the input pointer */ + src += srcInc; + + /* Circularly update wOffset. Watch out for positive and negative value */ + wOffset += bufferInc; + if(wOffset >= L) + wOffset -= L; + + /* Decrement the loop counter */ + i--; + } + + /* Update the index pointer */ + *writeOffset = wOffset; + } + + + + /** + * @brief Q15 Circular Read function. + */ + __STATIC_INLINE void arm_circularRead_q15( + q15_t * circBuffer, + int32_t L, + int32_t * readOffset, + int32_t bufferInc, + q15_t * dst, + q15_t * dst_base, + int32_t dst_length, + int32_t dstInc, + uint32_t blockSize) + { + uint32_t i = 0; + int32_t rOffset, dst_end; + + /* Copy the value of Index pointer that points + * to the current location from where the input samples to be read */ + rOffset = *readOffset; + + dst_end = (int32_t) (dst_base + dst_length); + + /* Loop over the blockSize */ + i = blockSize; + + while(i > 0u) + { + /* copy the sample from the circular buffer to the destination buffer */ + *dst = circBuffer[rOffset]; + + /* Update the input pointer */ + dst += dstInc; + + if(dst == (q15_t *) dst_end) + { + dst = dst_base; + } + + /* Circularly update wOffset. Watch out for positive and negative value */ + rOffset += bufferInc; + + if(rOffset >= L) + { + rOffset -= L; + } + + /* Decrement the loop counter */ + i--; + } + + /* Update the index pointer */ + *readOffset = rOffset; + } + + + /** + * @brief Q7 Circular write function. + */ + + __STATIC_INLINE void arm_circularWrite_q7( + q7_t * circBuffer, + int32_t L, + uint16_t * writeOffset, + int32_t bufferInc, + const q7_t * src, + int32_t srcInc, + uint32_t blockSize) + { + uint32_t i = 0u; + int32_t wOffset; + + /* Copy the value of Index pointer that points + * to the current location where the input samples to be copied */ + wOffset = *writeOffset; + + /* Loop over the blockSize */ + i = blockSize; + + while(i > 0u) + { + /* copy the input sample to the circular buffer */ + circBuffer[wOffset] = *src; + + /* Update the input pointer */ + src += srcInc; + + /* Circularly update wOffset. Watch out for positive and negative value */ + wOffset += bufferInc; + if(wOffset >= L) + wOffset -= L; + + /* Decrement the loop counter */ + i--; + } + + /* Update the index pointer */ + *writeOffset = wOffset; + } + + + + /** + * @brief Q7 Circular Read function. + */ + __STATIC_INLINE void arm_circularRead_q7( + q7_t * circBuffer, + int32_t L, + int32_t * readOffset, + int32_t bufferInc, + q7_t * dst, + q7_t * dst_base, + int32_t dst_length, + int32_t dstInc, + uint32_t blockSize) + { + uint32_t i = 0; + int32_t rOffset, dst_end; + + /* Copy the value of Index pointer that points + * to the current location from where the input samples to be read */ + rOffset = *readOffset; + + dst_end = (int32_t) (dst_base + dst_length); + + /* Loop over the blockSize */ + i = blockSize; + + while(i > 0u) + { + /* copy the sample from the circular buffer to the destination buffer */ + *dst = circBuffer[rOffset]; + + /* Update the input pointer */ + dst += dstInc; + + if(dst == (q7_t *) dst_end) + { + dst = dst_base; + } + + /* Circularly update rOffset. Watch out for positive and negative value */ + rOffset += bufferInc; + + if(rOffset >= L) + { + rOffset -= L; + } + + /* Decrement the loop counter */ + i--; + } + + /* Update the index pointer */ + *readOffset = rOffset; + } + + + /** + * @brief Sum of the squares of the elements of a Q31 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_power_q31( + q31_t * pSrc, + uint32_t blockSize, + q63_t * pResult); + + /** + * @brief Sum of the squares of the elements of a floating-point vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_power_f32( + float32_t * pSrc, + uint32_t blockSize, + float32_t * pResult); + + /** + * @brief Sum of the squares of the elements of a Q15 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_power_q15( + q15_t * pSrc, + uint32_t blockSize, + q63_t * pResult); + + /** + * @brief Sum of the squares of the elements of a Q7 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_power_q7( + q7_t * pSrc, + uint32_t blockSize, + q31_t * pResult); + + /** + * @brief Mean value of a Q7 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_mean_q7( + q7_t * pSrc, + uint32_t blockSize, + q7_t * pResult); + + /** + * @brief Mean value of a Q15 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + void arm_mean_q15( + q15_t * pSrc, + uint32_t blockSize, + q15_t * pResult); + + /** + * @brief Mean value of a Q31 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + void arm_mean_q31( + q31_t * pSrc, + uint32_t blockSize, + q31_t * pResult); + + /** + * @brief Mean value of a floating-point vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + void arm_mean_f32( + float32_t * pSrc, + uint32_t blockSize, + float32_t * pResult); + + /** + * @brief Variance of the elements of a floating-point vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_var_f32( + float32_t * pSrc, + uint32_t blockSize, + float32_t * pResult); + + /** + * @brief Variance of the elements of a Q31 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_var_q31( + q31_t * pSrc, + uint32_t blockSize, + q63_t * pResult); + + /** + * @brief Variance of the elements of a Q15 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_var_q15( + q15_t * pSrc, + uint32_t blockSize, + q31_t * pResult); + + /** + * @brief Root Mean Square of the elements of a floating-point vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_rms_f32( + float32_t * pSrc, + uint32_t blockSize, + float32_t * pResult); + + /** + * @brief Root Mean Square of the elements of a Q31 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_rms_q31( + q31_t * pSrc, + uint32_t blockSize, + q31_t * pResult); + + /** + * @brief Root Mean Square of the elements of a Q15 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_rms_q15( + q15_t * pSrc, + uint32_t blockSize, + q15_t * pResult); + + /** + * @brief Standard deviation of the elements of a floating-point vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_std_f32( + float32_t * pSrc, + uint32_t blockSize, + float32_t * pResult); + + /** + * @brief Standard deviation of the elements of a Q31 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_std_q31( + q31_t * pSrc, + uint32_t blockSize, + q31_t * pResult); + + /** + * @brief Standard deviation of the elements of a Q15 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output value. + * @return none. + */ + + void arm_std_q15( + q15_t * pSrc, + uint32_t blockSize, + q15_t * pResult); + + /** + * @brief Floating-point complex magnitude + * @param[in] *pSrc points to the complex input vector + * @param[out] *pDst points to the real output vector + * @param[in] numSamples number of complex samples in the input vector + * @return none. + */ + + void arm_cmplx_mag_f32( + float32_t * pSrc, + float32_t * pDst, + uint32_t numSamples); + + /** + * @brief Q31 complex magnitude + * @param[in] *pSrc points to the complex input vector + * @param[out] *pDst points to the real output vector + * @param[in] numSamples number of complex samples in the input vector + * @return none. + */ + + void arm_cmplx_mag_q31( + q31_t * pSrc, + q31_t * pDst, + uint32_t numSamples); + + /** + * @brief Q15 complex magnitude + * @param[in] *pSrc points to the complex input vector + * @param[out] *pDst points to the real output vector + * @param[in] numSamples number of complex samples in the input vector + * @return none. + */ + + void arm_cmplx_mag_q15( + q15_t * pSrc, + q15_t * pDst, + uint32_t numSamples); + + /** + * @brief Q15 complex dot product + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[in] numSamples number of complex samples in each vector + * @param[out] *realResult real part of the result returned here + * @param[out] *imagResult imaginary part of the result returned here + * @return none. + */ + + void arm_cmplx_dot_prod_q15( + q15_t * pSrcA, + q15_t * pSrcB, + uint32_t numSamples, + q31_t * realResult, + q31_t * imagResult); + + /** + * @brief Q31 complex dot product + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[in] numSamples number of complex samples in each vector + * @param[out] *realResult real part of the result returned here + * @param[out] *imagResult imaginary part of the result returned here + * @return none. + */ + + void arm_cmplx_dot_prod_q31( + q31_t * pSrcA, + q31_t * pSrcB, + uint32_t numSamples, + q63_t * realResult, + q63_t * imagResult); + + /** + * @brief Floating-point complex dot product + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[in] numSamples number of complex samples in each vector + * @param[out] *realResult real part of the result returned here + * @param[out] *imagResult imaginary part of the result returned here + * @return none. + */ + + void arm_cmplx_dot_prod_f32( + float32_t * pSrcA, + float32_t * pSrcB, + uint32_t numSamples, + float32_t * realResult, + float32_t * imagResult); + + /** + * @brief Q15 complex-by-real multiplication + * @param[in] *pSrcCmplx points to the complex input vector + * @param[in] *pSrcReal points to the real input vector + * @param[out] *pCmplxDst points to the complex output vector + * @param[in] numSamples number of samples in each vector + * @return none. + */ + + void arm_cmplx_mult_real_q15( + q15_t * pSrcCmplx, + q15_t * pSrcReal, + q15_t * pCmplxDst, + uint32_t numSamples); + + /** + * @brief Q31 complex-by-real multiplication + * @param[in] *pSrcCmplx points to the complex input vector + * @param[in] *pSrcReal points to the real input vector + * @param[out] *pCmplxDst points to the complex output vector + * @param[in] numSamples number of samples in each vector + * @return none. + */ + + void arm_cmplx_mult_real_q31( + q31_t * pSrcCmplx, + q31_t * pSrcReal, + q31_t * pCmplxDst, + uint32_t numSamples); + + /** + * @brief Floating-point complex-by-real multiplication + * @param[in] *pSrcCmplx points to the complex input vector + * @param[in] *pSrcReal points to the real input vector + * @param[out] *pCmplxDst points to the complex output vector + * @param[in] numSamples number of samples in each vector + * @return none. + */ + + void arm_cmplx_mult_real_f32( + float32_t * pSrcCmplx, + float32_t * pSrcReal, + float32_t * pCmplxDst, + uint32_t numSamples); + + /** + * @brief Minimum value of a Q7 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *result is output pointer + * @param[in] index is the array index of the minimum value in the input buffer. + * @return none. + */ + + void arm_min_q7( + q7_t * pSrc, + uint32_t blockSize, + q7_t * result, + uint32_t * index); + + /** + * @brief Minimum value of a Q15 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output pointer + * @param[in] *pIndex is the array index of the minimum value in the input buffer. + * @return none. + */ + + void arm_min_q15( + q15_t * pSrc, + uint32_t blockSize, + q15_t * pResult, + uint32_t * pIndex); + + /** + * @brief Minimum value of a Q31 vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output pointer + * @param[out] *pIndex is the array index of the minimum value in the input buffer. + * @return none. + */ + void arm_min_q31( + q31_t * pSrc, + uint32_t blockSize, + q31_t * pResult, + uint32_t * pIndex); + + /** + * @brief Minimum value of a floating-point vector. + * @param[in] *pSrc is input pointer + * @param[in] blockSize is the number of samples to process + * @param[out] *pResult is output pointer + * @param[out] *pIndex is the array index of the minimum value in the input buffer. + * @return none. + */ + + void arm_min_f32( + float32_t * pSrc, + uint32_t blockSize, + float32_t * pResult, + uint32_t * pIndex); + +/** + * @brief Maximum value of a Q7 vector. + * @param[in] *pSrc points to the input buffer + * @param[in] blockSize length of the input vector + * @param[out] *pResult maximum value returned here + * @param[out] *pIndex index of maximum value returned here + * @return none. + */ + + void arm_max_q7( + q7_t * pSrc, + uint32_t blockSize, + q7_t * pResult, + uint32_t * pIndex); + +/** + * @brief Maximum value of a Q15 vector. + * @param[in] *pSrc points to the input buffer + * @param[in] blockSize length of the input vector + * @param[out] *pResult maximum value returned here + * @param[out] *pIndex index of maximum value returned here + * @return none. + */ + + void arm_max_q15( + q15_t * pSrc, + uint32_t blockSize, + q15_t * pResult, + uint32_t * pIndex); + +/** + * @brief Maximum value of a Q31 vector. + * @param[in] *pSrc points to the input buffer + * @param[in] blockSize length of the input vector + * @param[out] *pResult maximum value returned here + * @param[out] *pIndex index of maximum value returned here + * @return none. + */ + + void arm_max_q31( + q31_t * pSrc, + uint32_t blockSize, + q31_t * pResult, + uint32_t * pIndex); + +/** + * @brief Maximum value of a floating-point vector. + * @param[in] *pSrc points to the input buffer + * @param[in] blockSize length of the input vector + * @param[out] *pResult maximum value returned here + * @param[out] *pIndex index of maximum value returned here + * @return none. + */ + + void arm_max_f32( + float32_t * pSrc, + uint32_t blockSize, + float32_t * pResult, + uint32_t * pIndex); + + /** + * @brief Q15 complex-by-complex multiplication + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] numSamples number of complex samples in each vector + * @return none. + */ + + void arm_cmplx_mult_cmplx_q15( + q15_t * pSrcA, + q15_t * pSrcB, + q15_t * pDst, + uint32_t numSamples); + + /** + * @brief Q31 complex-by-complex multiplication + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] numSamples number of complex samples in each vector + * @return none. + */ + + void arm_cmplx_mult_cmplx_q31( + q31_t * pSrcA, + q31_t * pSrcB, + q31_t * pDst, + uint32_t numSamples); + + /** + * @brief Floating-point complex-by-complex multiplication + * @param[in] *pSrcA points to the first input vector + * @param[in] *pSrcB points to the second input vector + * @param[out] *pDst points to the output vector + * @param[in] numSamples number of complex samples in each vector + * @return none. + */ + + void arm_cmplx_mult_cmplx_f32( + float32_t * pSrcA, + float32_t * pSrcB, + float32_t * pDst, + uint32_t numSamples); + + /** + * @brief Converts the elements of the floating-point vector to Q31 vector. + * @param[in] *pSrc points to the floating-point input vector + * @param[out] *pDst points to the Q31 output vector + * @param[in] blockSize length of the input vector + * @return none. + */ + void arm_float_to_q31( + float32_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + /** + * @brief Converts the elements of the floating-point vector to Q15 vector. + * @param[in] *pSrc points to the floating-point input vector + * @param[out] *pDst points to the Q15 output vector + * @param[in] blockSize length of the input vector + * @return none + */ + void arm_float_to_q15( + float32_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Converts the elements of the floating-point vector to Q7 vector. + * @param[in] *pSrc points to the floating-point input vector + * @param[out] *pDst points to the Q7 output vector + * @param[in] blockSize length of the input vector + * @return none + */ + void arm_float_to_q7( + float32_t * pSrc, + q7_t * pDst, + uint32_t blockSize); + + + /** + * @brief Converts the elements of the Q31 vector to Q15 vector. + * @param[in] *pSrc is input pointer + * @param[out] *pDst is output pointer + * @param[in] blockSize is the number of samples to process + * @return none. + */ + void arm_q31_to_q15( + q31_t * pSrc, + q15_t * pDst, + uint32_t blockSize); + + /** + * @brief Converts the elements of the Q31 vector to Q7 vector. + * @param[in] *pSrc is input pointer + * @param[out] *pDst is output pointer + * @param[in] blockSize is the number of samples to process + * @return none. + */ + void arm_q31_to_q7( + q31_t * pSrc, + q7_t * pDst, + uint32_t blockSize); + + /** + * @brief Converts the elements of the Q15 vector to floating-point vector. + * @param[in] *pSrc is input pointer + * @param[out] *pDst is output pointer + * @param[in] blockSize is the number of samples to process + * @return none. + */ + void arm_q15_to_float( + q15_t * pSrc, + float32_t * pDst, + uint32_t blockSize); + + + /** + * @brief Converts the elements of the Q15 vector to Q31 vector. + * @param[in] *pSrc is input pointer + * @param[out] *pDst is output pointer + * @param[in] blockSize is the number of samples to process + * @return none. + */ + void arm_q15_to_q31( + q15_t * pSrc, + q31_t * pDst, + uint32_t blockSize); + + + /** + * @brief Converts the elements of the Q15 vector to Q7 vector. + * @param[in] *pSrc is input pointer + * @param[out] *pDst is output pointer + * @param[in] blockSize is the number of samples to process + * @return none. + */ + void arm_q15_to_q7( + q15_t * pSrc, + q7_t * pDst, + uint32_t blockSize); + + + /** + * @ingroup groupInterpolation + */ + + /** + * @defgroup BilinearInterpolate Bilinear Interpolation + * + * Bilinear interpolation is an extension of linear interpolation applied to a two dimensional grid. + * The underlying function f(x, y) is sampled on a regular grid and the interpolation process + * determines values between the grid points. + * Bilinear interpolation is equivalent to two step linear interpolation, first in the x-dimension and then in the y-dimension. + * Bilinear interpolation is often used in image processing to rescale images. + * The CMSIS DSP library provides bilinear interpolation functions for Q7, Q15, Q31, and floating-point data types. + * + * Algorithm + * \par + * The instance structure used by the bilinear interpolation functions describes a two dimensional data table. + * For floating-point, the instance structure is defined as: + *
+   *   typedef struct
+   *   {
+   *     uint16_t numRows;
+   *     uint16_t numCols;
+   *     float32_t *pData;
+   * } arm_bilinear_interp_instance_f32;
+   * 
+ * + * \par + * where numRows specifies the number of rows in the table; + * numCols specifies the number of columns in the table; + * and pData points to an array of size numRows*numCols values. + * The data table pTable is organized in row order and the supplied data values fall on integer indexes. + * That is, table element (x,y) is located at pTable[x + y*numCols] where x and y are integers. + * + * \par + * Let (x, y) specify the desired interpolation point. Then define: + *
+   *     XF = floor(x)
+   *     YF = floor(y)
+   * 
+ * \par + * The interpolated output point is computed as: + *
+   *  f(x, y) = f(XF, YF) * (1-(x-XF)) * (1-(y-YF))
+   *           + f(XF+1, YF) * (x-XF)*(1-(y-YF))
+   *           + f(XF, YF+1) * (1-(x-XF))*(y-YF)
+   *           + f(XF+1, YF+1) * (x-XF)*(y-YF)
+   * 
+ * Note that the coordinates (x, y) contain integer and fractional components. + * The integer components specify which portion of the table to use while the + * fractional components control the interpolation processor. + * + * \par + * if (x,y) are outside of the table boundary, Bilinear interpolation returns zero output. + */ + + /** + * @addtogroup BilinearInterpolate + * @{ + */ + + /** + * + * @brief Floating-point bilinear interpolation. + * @param[in,out] *S points to an instance of the interpolation structure. + * @param[in] X interpolation coordinate. + * @param[in] Y interpolation coordinate. + * @return out interpolated value. + */ + + + __STATIC_INLINE float32_t arm_bilinear_interp_f32( + const arm_bilinear_interp_instance_f32 * S, + float32_t X, + float32_t Y) + { + float32_t out; + float32_t f00, f01, f10, f11; + float32_t *pData = S->pData; + int32_t xIndex, yIndex, index; + float32_t xdiff, ydiff; + float32_t b1, b2, b3, b4; + + xIndex = (int32_t) X; + yIndex = (int32_t) Y; + + /* Care taken for table outside boundary */ + /* Returns zero output when values are outside table boundary */ + if(xIndex < 0 || xIndex > (S->numRows-1) || yIndex < 0 || yIndex > ( S->numCols-1)) + { + return(0); + } + + /* Calculation of index for two nearest points in X-direction */ + index = (xIndex - 1) + (yIndex-1) * S->numCols ; + + + /* Read two nearest points in X-direction */ + f00 = pData[index]; + f01 = pData[index + 1]; + + /* Calculation of index for two nearest points in Y-direction */ + index = (xIndex-1) + (yIndex) * S->numCols; + + + /* Read two nearest points in Y-direction */ + f10 = pData[index]; + f11 = pData[index + 1]; + + /* Calculation of intermediate values */ + b1 = f00; + b2 = f01 - f00; + b3 = f10 - f00; + b4 = f00 - f01 - f10 + f11; + + /* Calculation of fractional part in X */ + xdiff = X - xIndex; + + /* Calculation of fractional part in Y */ + ydiff = Y - yIndex; + + /* Calculation of bi-linear interpolated output */ + out = b1 + b2 * xdiff + b3 * ydiff + b4 * xdiff * ydiff; + + /* return to application */ + return (out); + + } + + /** + * + * @brief Q31 bilinear interpolation. + * @param[in,out] *S points to an instance of the interpolation structure. + * @param[in] X interpolation coordinate in 12.20 format. + * @param[in] Y interpolation coordinate in 12.20 format. + * @return out interpolated value. + */ + + __STATIC_INLINE q31_t arm_bilinear_interp_q31( + arm_bilinear_interp_instance_q31 * S, + q31_t X, + q31_t Y) + { + q31_t out; /* Temporary output */ + q31_t acc = 0; /* output */ + q31_t xfract, yfract; /* X, Y fractional parts */ + q31_t x1, x2, y1, y2; /* Nearest output values */ + int32_t rI, cI; /* Row and column indices */ + q31_t *pYData = S->pData; /* pointer to output table values */ + uint32_t nCols = S->numCols; /* num of rows */ + + + /* Input is in 12.20 format */ + /* 12 bits for the table index */ + /* Index value calculation */ + rI = ((X & 0xFFF00000) >> 20u); + + /* Input is in 12.20 format */ + /* 12 bits for the table index */ + /* Index value calculation */ + cI = ((Y & 0xFFF00000) >> 20u); + + /* Care taken for table outside boundary */ + /* Returns zero output when values are outside table boundary */ + if(rI < 0 || rI > (S->numRows-1) || cI < 0 || cI > ( S->numCols-1)) + { + return(0); + } + + /* 20 bits for the fractional part */ + /* shift left xfract by 11 to keep 1.31 format */ + xfract = (X & 0x000FFFFF) << 11u; + + /* Read two nearest output values from the index */ + x1 = pYData[(rI) + nCols * (cI)]; + x2 = pYData[(rI) + nCols * (cI) + 1u]; + + /* 20 bits for the fractional part */ + /* shift left yfract by 11 to keep 1.31 format */ + yfract = (Y & 0x000FFFFF) << 11u; + + /* Read two nearest output values from the index */ + y1 = pYData[(rI) + nCols * (cI + 1)]; + y2 = pYData[(rI) + nCols * (cI + 1) + 1u]; + + /* Calculation of x1 * (1-xfract ) * (1-yfract) and acc is in 3.29(q29) format */ + out = ((q31_t) (((q63_t) x1 * (0x7FFFFFFF - xfract)) >> 32)); + acc = ((q31_t) (((q63_t) out * (0x7FFFFFFF - yfract)) >> 32)); + + /* x2 * (xfract) * (1-yfract) in 3.29(q29) and adding to acc */ + out = ((q31_t) ((q63_t) x2 * (0x7FFFFFFF - yfract) >> 32)); + acc += ((q31_t) ((q63_t) out * (xfract) >> 32)); + + /* y1 * (1 - xfract) * (yfract) in 3.29(q29) and adding to acc */ + out = ((q31_t) ((q63_t) y1 * (0x7FFFFFFF - xfract) >> 32)); + acc += ((q31_t) ((q63_t) out * (yfract) >> 32)); + + /* y2 * (xfract) * (yfract) in 3.29(q29) and adding to acc */ + out = ((q31_t) ((q63_t) y2 * (xfract) >> 32)); + acc += ((q31_t) ((q63_t) out * (yfract) >> 32)); + + /* Convert acc to 1.31(q31) format */ + return (acc << 2u); + + } + + /** + * @brief Q15 bilinear interpolation. + * @param[in,out] *S points to an instance of the interpolation structure. + * @param[in] X interpolation coordinate in 12.20 format. + * @param[in] Y interpolation coordinate in 12.20 format. + * @return out interpolated value. + */ + + __STATIC_INLINE q15_t arm_bilinear_interp_q15( + arm_bilinear_interp_instance_q15 * S, + q31_t X, + q31_t Y) + { + q63_t acc = 0; /* output */ + q31_t out; /* Temporary output */ + q15_t x1, x2, y1, y2; /* Nearest output values */ + q31_t xfract, yfract; /* X, Y fractional parts */ + int32_t rI, cI; /* Row and column indices */ + q15_t *pYData = S->pData; /* pointer to output table values */ + uint32_t nCols = S->numCols; /* num of rows */ + + /* Input is in 12.20 format */ + /* 12 bits for the table index */ + /* Index value calculation */ + rI = ((X & 0xFFF00000) >> 20); + + /* Input is in 12.20 format */ + /* 12 bits for the table index */ + /* Index value calculation */ + cI = ((Y & 0xFFF00000) >> 20); + + /* Care taken for table outside boundary */ + /* Returns zero output when values are outside table boundary */ + if(rI < 0 || rI > (S->numRows-1) || cI < 0 || cI > ( S->numCols-1)) + { + return(0); + } + + /* 20 bits for the fractional part */ + /* xfract should be in 12.20 format */ + xfract = (X & 0x000FFFFF); + + /* Read two nearest output values from the index */ + x1 = pYData[(rI) + nCols * (cI)]; + x2 = pYData[(rI) + nCols * (cI) + 1u]; + + + /* 20 bits for the fractional part */ + /* yfract should be in 12.20 format */ + yfract = (Y & 0x000FFFFF); + + /* Read two nearest output values from the index */ + y1 = pYData[(rI) + nCols * (cI + 1)]; + y2 = pYData[(rI) + nCols * (cI + 1) + 1u]; + + /* Calculation of x1 * (1-xfract ) * (1-yfract) and acc is in 13.51 format */ + + /* x1 is in 1.15(q15), xfract in 12.20 format and out is in 13.35 format */ + /* convert 13.35 to 13.31 by right shifting and out is in 1.31 */ + out = (q31_t) (((q63_t) x1 * (0xFFFFF - xfract)) >> 4u); + acc = ((q63_t) out * (0xFFFFF - yfract)); + + /* x2 * (xfract) * (1-yfract) in 1.51 and adding to acc */ + out = (q31_t) (((q63_t) x2 * (0xFFFFF - yfract)) >> 4u); + acc += ((q63_t) out * (xfract)); + + /* y1 * (1 - xfract) * (yfract) in 1.51 and adding to acc */ + out = (q31_t) (((q63_t) y1 * (0xFFFFF - xfract)) >> 4u); + acc += ((q63_t) out * (yfract)); + + /* y2 * (xfract) * (yfract) in 1.51 and adding to acc */ + out = (q31_t) (((q63_t) y2 * (xfract)) >> 4u); + acc += ((q63_t) out * (yfract)); + + /* acc is in 13.51 format and down shift acc by 36 times */ + /* Convert out to 1.15 format */ + return (acc >> 36); + + } + + /** + * @brief Q7 bilinear interpolation. + * @param[in,out] *S points to an instance of the interpolation structure. + * @param[in] X interpolation coordinate in 12.20 format. + * @param[in] Y interpolation coordinate in 12.20 format. + * @return out interpolated value. + */ + + __STATIC_INLINE q7_t arm_bilinear_interp_q7( + arm_bilinear_interp_instance_q7 * S, + q31_t X, + q31_t Y) + { + q63_t acc = 0; /* output */ + q31_t out; /* Temporary output */ + q31_t xfract, yfract; /* X, Y fractional parts */ + q7_t x1, x2, y1, y2; /* Nearest output values */ + int32_t rI, cI; /* Row and column indices */ + q7_t *pYData = S->pData; /* pointer to output table values */ + uint32_t nCols = S->numCols; /* num of rows */ + + /* Input is in 12.20 format */ + /* 12 bits for the table index */ + /* Index value calculation */ + rI = ((X & 0xFFF00000) >> 20); + + /* Input is in 12.20 format */ + /* 12 bits for the table index */ + /* Index value calculation */ + cI = ((Y & 0xFFF00000) >> 20); + + /* Care taken for table outside boundary */ + /* Returns zero output when values are outside table boundary */ + if(rI < 0 || rI > (S->numRows-1) || cI < 0 || cI > ( S->numCols-1)) + { + return(0); + } + + /* 20 bits for the fractional part */ + /* xfract should be in 12.20 format */ + xfract = (X & 0x000FFFFF); + + /* Read two nearest output values from the index */ + x1 = pYData[(rI) + nCols * (cI)]; + x2 = pYData[(rI) + nCols * (cI) + 1u]; + + + /* 20 bits for the fractional part */ + /* yfract should be in 12.20 format */ + yfract = (Y & 0x000FFFFF); + + /* Read two nearest output values from the index */ + y1 = pYData[(rI) + nCols * (cI + 1)]; + y2 = pYData[(rI) + nCols * (cI + 1) + 1u]; + + /* Calculation of x1 * (1-xfract ) * (1-yfract) and acc is in 16.47 format */ + out = ((x1 * (0xFFFFF - xfract))); + acc = (((q63_t) out * (0xFFFFF - yfract))); + + /* x2 * (xfract) * (1-yfract) in 2.22 and adding to acc */ + out = ((x2 * (0xFFFFF - yfract))); + acc += (((q63_t) out * (xfract))); + + /* y1 * (1 - xfract) * (yfract) in 2.22 and adding to acc */ + out = ((y1 * (0xFFFFF - xfract))); + acc += (((q63_t) out * (yfract))); + + /* y2 * (xfract) * (yfract) in 2.22 and adding to acc */ + out = ((y2 * (yfract))); + acc += (((q63_t) out * (xfract))); + + /* acc in 16.47 format and down shift by 40 to convert to 1.7 format */ + return (acc >> 40); + + } + + /** + * @} end of BilinearInterpolate group + */ + + + + + + +#ifdef __cplusplus +} +#endif + + +#endif /* _ARM_MATH_H */ + + +/** + * + * End of file. + */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/Include/core_cm0plus.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/Include/core_cm0plus.h new file mode 100755 index 0000000..aa20e68 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/Include/core_cm0plus.h @@ -0,0 +1,778 @@ +/**************************************************************************//** + * @file core_cm0plus.h + * @brief CMSIS Cortex-M0+ Core Peripheral Access Layer Header File + * @version V3.01 + * @date 22. March 2012 + * + * @note + * Copyright (C) 2009-2012 ARM Limited. All rights reserved. + * + * @par + * ARM Limited (ARM) is supplying this software for use with Cortex-M + * processor based microcontrollers. This file can be freely distributed + * within development tools that are supporting such ARM based processors. + * + * @par + * THIS SOFTWARE IS PROVIDED "AS IS". NO WARRANTIES, WHETHER EXPRESS, IMPLIED + * OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE. + * ARM SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR SPECIAL, INCIDENTAL, OR + * CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER. + * + ******************************************************************************/ +#if defined ( __ICCARM__ ) + #pragma system_include /* treat file as system include file for MISRA check */ +#endif + +#ifdef __cplusplus + extern "C" { +#endif + +#ifndef __CORE_CM0PLUS_H_GENERIC +#define __CORE_CM0PLUS_H_GENERIC + +/** \page CMSIS_MISRA_Exceptions MISRA-C:2004 Compliance Exceptions + CMSIS violates the following MISRA-C:2004 rules: + + \li Required Rule 8.5, object/function definition in header file.
+ Function definitions in header files are used to allow 'inlining'. + + \li Required Rule 18.4, declaration of union type or object of union type: '{...}'.
+ Unions are used for effective representation of core registers. + + \li Advisory Rule 19.7, Function-like macro defined.
+ Function-like macros are used to allow more efficient code. + */ + + +/******************************************************************************* + * CMSIS definitions + ******************************************************************************/ +/** \ingroup Cortex-M0+ + @{ + */ + +/* CMSIS CM0P definitions */ +#define __CM0PLUS_CMSIS_VERSION_MAIN (0x03) /*!< [31:16] CMSIS HAL main version */ +#define __CM0PLUS_CMSIS_VERSION_SUB (0x01) /*!< [15:0] CMSIS HAL sub version */ +#define __CM0PLUS_CMSIS_VERSION ((__CM0PLUS_CMSIS_VERSION_MAIN << 16) | \ + __CM0PLUS_CMSIS_VERSION_SUB) /*!< CMSIS HAL version number */ + +#define __CORTEX_M (0x00) /*!< Cortex-M Core */ + + +#if defined ( __CC_ARM ) + #define __ASM __asm /*!< asm keyword for ARM Compiler */ + #define __INLINE __inline /*!< inline keyword for ARM Compiler */ + #define __STATIC_INLINE static __inline + +#elif defined ( __ICCARM__ ) + #define __ASM __asm /*!< asm keyword for IAR Compiler */ + #define __INLINE inline /*!< inline keyword for IAR Compiler. Only available in High optimization mode! */ + #define __STATIC_INLINE static inline + +#elif defined ( __GNUC__ ) + #define __ASM __asm /*!< asm keyword for GNU Compiler */ + #define __INLINE inline /*!< inline keyword for GNU Compiler */ + #define __STATIC_INLINE static inline + +#elif defined ( __TASKING__ ) + #define __ASM __asm /*!< asm keyword for TASKING Compiler */ + #define __INLINE inline /*!< inline keyword for TASKING Compiler */ + #define __STATIC_INLINE static inline + +#endif + +/** __FPU_USED indicates whether an FPU is used or not. This core does not support an FPU at all +*/ +#define __FPU_USED 0 + +#if defined ( __CC_ARM ) + #if defined __TARGET_FPU_VFP + #warning "Compiler generates FPU instructions for a device without an FPU (check __FPU_PRESENT)" + #endif + +#elif defined ( __ICCARM__ ) + #if defined __ARMVFP__ + #warning "Compiler generates FPU instructions for a device without an FPU (check __FPU_PRESENT)" + #endif + +#elif defined ( __GNUC__ ) + #if defined (__VFP_FP__) && !defined(__SOFTFP__) + #warning "Compiler generates FPU instructions for a device without an FPU (check __FPU_PRESENT)" + #endif + +#elif defined ( __TASKING__ ) + #if defined __FPU_VFP__ + #error "Compiler generates FPU instructions for a device without an FPU (check __FPU_PRESENT)" + #endif +#endif + +#include /* standard types definitions */ +#include /* Core Instruction Access */ +#include /* Core Function Access */ + +#endif /* __CORE_CM0PLUS_H_GENERIC */ + +#ifndef __CMSIS_GENERIC + +#ifndef __CORE_CM0PLUS_H_DEPENDANT +#define __CORE_CM0PLUS_H_DEPENDANT + +/* check device defines and use defaults */ +#if defined __CHECK_DEVICE_DEFINES + #ifndef __CM0PLUS_REV + #define __CM0PLUS_REV 0x0000 + #warning "__CM0PLUS_REV not defined in device header file; using default!" + #endif + + #ifndef __MPU_PRESENT + #define __MPU_PRESENT 0 + #warning "__MPU_PRESENT not defined in device header file; using default!" + #endif + + #ifndef __VTOR_PRESENT + #define __VTOR_PRESENT 0 + #warning "__VTOR_PRESENT not defined in device header file; using default!" + #endif + + #ifndef __NVIC_PRIO_BITS + #define __NVIC_PRIO_BITS 2 + #warning "__NVIC_PRIO_BITS not defined in device header file; using default!" + #endif + + #ifndef __Vendor_SysTickConfig + #define __Vendor_SysTickConfig 0 + #warning "__Vendor_SysTickConfig not defined in device header file; using default!" + #endif +#endif + +/* IO definitions (access restrictions to peripheral registers) */ +/** + \defgroup CMSIS_glob_defs CMSIS Global Defines + + IO Type Qualifiers are used + \li to specify the access to peripheral variables. + \li for automatic generation of peripheral register debug information. +*/ +#ifdef __cplusplus + #define __I volatile /*!< Defines 'read only' permissions */ +#else + #define __I volatile const /*!< Defines 'read only' permissions */ +#endif +#define __O volatile /*!< Defines 'write only' permissions */ +#define __IO volatile /*!< Defines 'read / write' permissions */ + +/*@} end of group Cortex-M0+ */ + + + +/******************************************************************************* + * Register Abstraction + Core Register contain: + - Core Register + - Core NVIC Register + - Core SCB Register + - Core SysTick Register + - Core MPU Register + ******************************************************************************/ +/** \defgroup CMSIS_core_register Defines and Type Definitions + \brief Type definitions and defines for Cortex-M processor based devices. +*/ + +/** \ingroup CMSIS_core_register + \defgroup CMSIS_CORE Status and Control Registers + \brief Core Register type definitions. + @{ + */ + +/** \brief Union type to access the Application Program Status Register (APSR). + */ +typedef union +{ + struct + { +#if (__CORTEX_M != 0x04) + uint32_t _reserved0:27; /*!< bit: 0..26 Reserved */ +#else + uint32_t _reserved0:16; /*!< bit: 0..15 Reserved */ + uint32_t GE:4; /*!< bit: 16..19 Greater than or Equal flags */ + uint32_t _reserved1:7; /*!< bit: 20..26 Reserved */ +#endif + uint32_t Q:1; /*!< bit: 27 Saturation condition flag */ + uint32_t V:1; /*!< bit: 28 Overflow condition code flag */ + uint32_t C:1; /*!< bit: 29 Carry condition code flag */ + uint32_t Z:1; /*!< bit: 30 Zero condition code flag */ + uint32_t N:1; /*!< bit: 31 Negative condition code flag */ + } b; /*!< Structure used for bit access */ + uint32_t w; /*!< Type used for word access */ +} APSR_Type; + + +/** \brief Union type to access the Interrupt Program Status Register (IPSR). + */ +typedef union +{ + struct + { + uint32_t ISR:9; /*!< bit: 0.. 8 Exception number */ + uint32_t _reserved0:23; /*!< bit: 9..31 Reserved */ + } b; /*!< Structure used for bit access */ + uint32_t w; /*!< Type used for word access */ +} IPSR_Type; + + +/** \brief Union type to access the Special-Purpose Program Status Registers (xPSR). + */ +typedef union +{ + struct + { + uint32_t ISR:9; /*!< bit: 0.. 8 Exception number */ +#if (__CORTEX_M != 0x04) + uint32_t _reserved0:15; /*!< bit: 9..23 Reserved */ +#else + uint32_t _reserved0:7; /*!< bit: 9..15 Reserved */ + uint32_t GE:4; /*!< bit: 16..19 Greater than or Equal flags */ + uint32_t _reserved1:4; /*!< bit: 20..23 Reserved */ +#endif + uint32_t T:1; /*!< bit: 24 Thumb bit (read 0) */ + uint32_t IT:2; /*!< bit: 25..26 saved IT state (read 0) */ + uint32_t Q:1; /*!< bit: 27 Saturation condition flag */ + uint32_t V:1; /*!< bit: 28 Overflow condition code flag */ + uint32_t C:1; /*!< bit: 29 Carry condition code flag */ + uint32_t Z:1; /*!< bit: 30 Zero condition code flag */ + uint32_t N:1; /*!< bit: 31 Negative condition code flag */ + } b; /*!< Structure used for bit access */ + uint32_t w; /*!< Type used for word access */ +} xPSR_Type; + + +/** \brief Union type to access the Control Registers (CONTROL). + */ +typedef union +{ + struct + { + uint32_t nPRIV:1; /*!< bit: 0 Execution privilege in Thread mode */ + uint32_t SPSEL:1; /*!< bit: 1 Stack to be used */ + uint32_t FPCA:1; /*!< bit: 2 FP extension active flag */ + uint32_t _reserved0:29; /*!< bit: 3..31 Reserved */ + } b; /*!< Structure used for bit access */ + uint32_t w; /*!< Type used for word access */ +} CONTROL_Type; + +/*@} end of group CMSIS_CORE */ + + +/** \ingroup CMSIS_core_register + \defgroup CMSIS_NVIC Nested Vectored Interrupt Controller (NVIC) + \brief Type definitions for the NVIC Registers + @{ + */ + +/** \brief Structure type to access the Nested Vectored Interrupt Controller (NVIC). + */ +typedef struct +{ + __IO uint32_t ISER[1]; /*!< Offset: 0x000 (R/W) Interrupt Set Enable Register */ + uint32_t RESERVED0[31]; + __IO uint32_t ICER[1]; /*!< Offset: 0x080 (R/W) Interrupt Clear Enable Register */ + uint32_t RSERVED1[31]; + __IO uint32_t ISPR[1]; /*!< Offset: 0x100 (R/W) Interrupt Set Pending Register */ + uint32_t RESERVED2[31]; + __IO uint32_t ICPR[1]; /*!< Offset: 0x180 (R/W) Interrupt Clear Pending Register */ + uint32_t RESERVED3[31]; + uint32_t RESERVED4[64]; + __IO uint32_t IP[8]; /*!< Offset: 0x300 (R/W) Interrupt Priority Register */ +} NVIC_Type; + +/*@} end of group CMSIS_NVIC */ + + +/** \ingroup CMSIS_core_register + \defgroup CMSIS_SCB System Control Block (SCB) + \brief Type definitions for the System Control Block Registers + @{ + */ + +/** \brief Structure type to access the System Control Block (SCB). + */ +typedef struct +{ + __I uint32_t CPUID; /*!< Offset: 0x000 (R/ ) CPUID Base Register */ + __IO uint32_t ICSR; /*!< Offset: 0x004 (R/W) Interrupt Control and State Register */ +#if (__VTOR_PRESENT == 1) + __IO uint32_t VTOR; /*!< Offset: 0x008 (R/W) Vector Table Offset Register */ +#else + uint32_t RESERVED0; +#endif + __IO uint32_t AIRCR; /*!< Offset: 0x00C (R/W) Application Interrupt and Reset Control Register */ + __IO uint32_t SCR; /*!< Offset: 0x010 (R/W) System Control Register */ + __IO uint32_t CCR; /*!< Offset: 0x014 (R/W) Configuration Control Register */ + uint32_t RESERVED1; + __IO uint32_t SHP[2]; /*!< Offset: 0x01C (R/W) System Handlers Priority Registers. [0] is RESERVED */ + __IO uint32_t SHCSR; /*!< Offset: 0x024 (R/W) System Handler Control and State Register */ +} SCB_Type; + +/* SCB CPUID Register Definitions */ +#define SCB_CPUID_IMPLEMENTER_Pos 24 /*!< SCB CPUID: IMPLEMENTER Position */ +#define SCB_CPUID_IMPLEMENTER_Msk (0xFFUL << SCB_CPUID_IMPLEMENTER_Pos) /*!< SCB CPUID: IMPLEMENTER Mask */ + +#define SCB_CPUID_VARIANT_Pos 20 /*!< SCB CPUID: VARIANT Position */ +#define SCB_CPUID_VARIANT_Msk (0xFUL << SCB_CPUID_VARIANT_Pos) /*!< SCB CPUID: VARIANT Mask */ + +#define SCB_CPUID_ARCHITECTURE_Pos 16 /*!< SCB CPUID: ARCHITECTURE Position */ +#define SCB_CPUID_ARCHITECTURE_Msk (0xFUL << SCB_CPUID_ARCHITECTURE_Pos) /*!< SCB CPUID: ARCHITECTURE Mask */ + +#define SCB_CPUID_PARTNO_Pos 4 /*!< SCB CPUID: PARTNO Position */ +#define SCB_CPUID_PARTNO_Msk (0xFFFUL << SCB_CPUID_PARTNO_Pos) /*!< SCB CPUID: PARTNO Mask */ + +#define SCB_CPUID_REVISION_Pos 0 /*!< SCB CPUID: REVISION Position */ +#define SCB_CPUID_REVISION_Msk (0xFUL << SCB_CPUID_REVISION_Pos) /*!< SCB CPUID: REVISION Mask */ + +/* SCB Interrupt Control State Register Definitions */ +#define SCB_ICSR_NMIPENDSET_Pos 31 /*!< SCB ICSR: NMIPENDSET Position */ +#define SCB_ICSR_NMIPENDSET_Msk (1UL << SCB_ICSR_NMIPENDSET_Pos) /*!< SCB ICSR: NMIPENDSET Mask */ + +#define SCB_ICSR_PENDSVSET_Pos 28 /*!< SCB ICSR: PENDSVSET Position */ +#define SCB_ICSR_PENDSVSET_Msk (1UL << SCB_ICSR_PENDSVSET_Pos) /*!< SCB ICSR: PENDSVSET Mask */ + +#define SCB_ICSR_PENDSVCLR_Pos 27 /*!< SCB ICSR: PENDSVCLR Position */ +#define SCB_ICSR_PENDSVCLR_Msk (1UL << SCB_ICSR_PENDSVCLR_Pos) /*!< SCB ICSR: PENDSVCLR Mask */ + +#define SCB_ICSR_PENDSTSET_Pos 26 /*!< SCB ICSR: PENDSTSET Position */ +#define SCB_ICSR_PENDSTSET_Msk (1UL << SCB_ICSR_PENDSTSET_Pos) /*!< SCB ICSR: PENDSTSET Mask */ + +#define SCB_ICSR_PENDSTCLR_Pos 25 /*!< SCB ICSR: PENDSTCLR Position */ +#define SCB_ICSR_PENDSTCLR_Msk (1UL << SCB_ICSR_PENDSTCLR_Pos) /*!< SCB ICSR: PENDSTCLR Mask */ + +#define SCB_ICSR_ISRPREEMPT_Pos 23 /*!< SCB ICSR: ISRPREEMPT Position */ +#define SCB_ICSR_ISRPREEMPT_Msk (1UL << SCB_ICSR_ISRPREEMPT_Pos) /*!< SCB ICSR: ISRPREEMPT Mask */ + +#define SCB_ICSR_ISRPENDING_Pos 22 /*!< SCB ICSR: ISRPENDING Position */ +#define SCB_ICSR_ISRPENDING_Msk (1UL << SCB_ICSR_ISRPENDING_Pos) /*!< SCB ICSR: ISRPENDING Mask */ + +#define SCB_ICSR_VECTPENDING_Pos 12 /*!< SCB ICSR: VECTPENDING Position */ +#define SCB_ICSR_VECTPENDING_Msk (0x1FFUL << SCB_ICSR_VECTPENDING_Pos) /*!< SCB ICSR: VECTPENDING Mask */ + +#define SCB_ICSR_VECTACTIVE_Pos 0 /*!< SCB ICSR: VECTACTIVE Position */ +#define SCB_ICSR_VECTACTIVE_Msk (0x1FFUL << SCB_ICSR_VECTACTIVE_Pos) /*!< SCB ICSR: VECTACTIVE Mask */ + +#if (__VTOR_PRESENT == 1) +/* SCB Interrupt Control State Register Definitions */ +#define SCB_VTOR_TBLOFF_Pos 7 /*!< SCB VTOR: TBLOFF Position */ +#define SCB_VTOR_TBLOFF_Msk (0x1FFFFFFUL << SCB_VTOR_TBLOFF_Pos) /*!< SCB VTOR: TBLOFF Mask */ +#endif + +/* SCB Application Interrupt and Reset Control Register Definitions */ +#define SCB_AIRCR_VECTKEY_Pos 16 /*!< SCB AIRCR: VECTKEY Position */ +#define SCB_AIRCR_VECTKEY_Msk (0xFFFFUL << SCB_AIRCR_VECTKEY_Pos) /*!< SCB AIRCR: VECTKEY Mask */ + +#define SCB_AIRCR_VECTKEYSTAT_Pos 16 /*!< SCB AIRCR: VECTKEYSTAT Position */ +#define SCB_AIRCR_VECTKEYSTAT_Msk (0xFFFFUL << SCB_AIRCR_VECTKEYSTAT_Pos) /*!< SCB AIRCR: VECTKEYSTAT Mask */ + +#define SCB_AIRCR_ENDIANESS_Pos 15 /*!< SCB AIRCR: ENDIANESS Position */ +#define SCB_AIRCR_ENDIANESS_Msk (1UL << SCB_AIRCR_ENDIANESS_Pos) /*!< SCB AIRCR: ENDIANESS Mask */ + +#define SCB_AIRCR_SYSRESETREQ_Pos 2 /*!< SCB AIRCR: SYSRESETREQ Position */ +#define SCB_AIRCR_SYSRESETREQ_Msk (1UL << SCB_AIRCR_SYSRESETREQ_Pos) /*!< SCB AIRCR: SYSRESETREQ Mask */ + +#define SCB_AIRCR_VECTCLRACTIVE_Pos 1 /*!< SCB AIRCR: VECTCLRACTIVE Position */ +#define SCB_AIRCR_VECTCLRACTIVE_Msk (1UL << SCB_AIRCR_VECTCLRACTIVE_Pos) /*!< SCB AIRCR: VECTCLRACTIVE Mask */ + +/* SCB System Control Register Definitions */ +#define SCB_SCR_SEVONPEND_Pos 4 /*!< SCB SCR: SEVONPEND Position */ +#define SCB_SCR_SEVONPEND_Msk (1UL << SCB_SCR_SEVONPEND_Pos) /*!< SCB SCR: SEVONPEND Mask */ + +#define SCB_SCR_SLEEPDEEP_Pos 2 /*!< SCB SCR: SLEEPDEEP Position */ +#define SCB_SCR_SLEEPDEEP_Msk (1UL << SCB_SCR_SLEEPDEEP_Pos) /*!< SCB SCR: SLEEPDEEP Mask */ + +#define SCB_SCR_SLEEPONEXIT_Pos 1 /*!< SCB SCR: SLEEPONEXIT Position */ +#define SCB_SCR_SLEEPONEXIT_Msk (1UL << SCB_SCR_SLEEPONEXIT_Pos) /*!< SCB SCR: SLEEPONEXIT Mask */ + +/* SCB Configuration Control Register Definitions */ +#define SCB_CCR_STKALIGN_Pos 9 /*!< SCB CCR: STKALIGN Position */ +#define SCB_CCR_STKALIGN_Msk (1UL << SCB_CCR_STKALIGN_Pos) /*!< SCB CCR: STKALIGN Mask */ + +#define SCB_CCR_UNALIGN_TRP_Pos 3 /*!< SCB CCR: UNALIGN_TRP Position */ +#define SCB_CCR_UNALIGN_TRP_Msk (1UL << SCB_CCR_UNALIGN_TRP_Pos) /*!< SCB CCR: UNALIGN_TRP Mask */ + +/* SCB System Handler Control and State Register Definitions */ +#define SCB_SHCSR_SVCALLPENDED_Pos 15 /*!< SCB SHCSR: SVCALLPENDED Position */ +#define SCB_SHCSR_SVCALLPENDED_Msk (1UL << SCB_SHCSR_SVCALLPENDED_Pos) /*!< SCB SHCSR: SVCALLPENDED Mask */ + +/*@} end of group CMSIS_SCB */ + + +/** \ingroup CMSIS_core_register + \defgroup CMSIS_SysTick System Tick Timer (SysTick) + \brief Type definitions for the System Timer Registers. + @{ + */ + +/** \brief Structure type to access the System Timer (SysTick). + */ +typedef struct +{ + __IO uint32_t CTRL; /*!< Offset: 0x000 (R/W) SysTick Control and Status Register */ + __IO uint32_t LOAD; /*!< Offset: 0x004 (R/W) SysTick Reload Value Register */ + __IO uint32_t VAL; /*!< Offset: 0x008 (R/W) SysTick Current Value Register */ + __I uint32_t CALIB; /*!< Offset: 0x00C (R/ ) SysTick Calibration Register */ +} SysTick_Type; + +/* SysTick Control / Status Register Definitions */ +#define SysTick_CTRL_COUNTFLAG_Pos 16 /*!< SysTick CTRL: COUNTFLAG Position */ +#define SysTick_CTRL_COUNTFLAG_Msk (1UL << SysTick_CTRL_COUNTFLAG_Pos) /*!< SysTick CTRL: COUNTFLAG Mask */ + +#define SysTick_CTRL_CLKSOURCE_Pos 2 /*!< SysTick CTRL: CLKSOURCE Position */ +#define SysTick_CTRL_CLKSOURCE_Msk (1UL << SysTick_CTRL_CLKSOURCE_Pos) /*!< SysTick CTRL: CLKSOURCE Mask */ + +#define SysTick_CTRL_TICKINT_Pos 1 /*!< SysTick CTRL: TICKINT Position */ +#define SysTick_CTRL_TICKINT_Msk (1UL << SysTick_CTRL_TICKINT_Pos) /*!< SysTick CTRL: TICKINT Mask */ + +#define SysTick_CTRL_ENABLE_Pos 0 /*!< SysTick CTRL: ENABLE Position */ +#define SysTick_CTRL_ENABLE_Msk (1UL << SysTick_CTRL_ENABLE_Pos) /*!< SysTick CTRL: ENABLE Mask */ + +/* SysTick Reload Register Definitions */ +#define SysTick_LOAD_RELOAD_Pos 0 /*!< SysTick LOAD: RELOAD Position */ +#define SysTick_LOAD_RELOAD_Msk (0xFFFFFFUL << SysTick_LOAD_RELOAD_Pos) /*!< SysTick LOAD: RELOAD Mask */ + +/* SysTick Current Register Definitions */ +#define SysTick_VAL_CURRENT_Pos 0 /*!< SysTick VAL: CURRENT Position */ +#define SysTick_VAL_CURRENT_Msk (0xFFFFFFUL << SysTick_VAL_CURRENT_Pos) /*!< SysTick VAL: CURRENT Mask */ + +/* SysTick Calibration Register Definitions */ +#define SysTick_CALIB_NOREF_Pos 31 /*!< SysTick CALIB: NOREF Position */ +#define SysTick_CALIB_NOREF_Msk (1UL << SysTick_CALIB_NOREF_Pos) /*!< SysTick CALIB: NOREF Mask */ + +#define SysTick_CALIB_SKEW_Pos 30 /*!< SysTick CALIB: SKEW Position */ +#define SysTick_CALIB_SKEW_Msk (1UL << SysTick_CALIB_SKEW_Pos) /*!< SysTick CALIB: SKEW Mask */ + +#define SysTick_CALIB_TENMS_Pos 0 /*!< SysTick CALIB: TENMS Position */ +#define SysTick_CALIB_TENMS_Msk (0xFFFFFFUL << SysTick_VAL_CURRENT_Pos) /*!< SysTick CALIB: TENMS Mask */ + +/*@} end of group CMSIS_SysTick */ + +#if (__MPU_PRESENT == 1) +/** \ingroup CMSIS_core_register + \defgroup CMSIS_MPU Memory Protection Unit (MPU) + \brief Type definitions for the Memory Protection Unit (MPU) + @{ + */ + +/** \brief Structure type to access the Memory Protection Unit (MPU). + */ +typedef struct +{ + __I uint32_t TYPE; /*!< Offset: 0x000 (R/ ) MPU Type Register */ + __IO uint32_t CTRL; /*!< Offset: 0x004 (R/W) MPU Control Register */ + __IO uint32_t RNR; /*!< Offset: 0x008 (R/W) MPU Region RNRber Register */ + __IO uint32_t RBAR; /*!< Offset: 0x00C (R/W) MPU Region Base Address Register */ + __IO uint32_t RASR; /*!< Offset: 0x010 (R/W) MPU Region Attribute and Size Register */ +} MPU_Type; + +/* MPU Type Register */ +#define MPU_TYPE_IREGION_Pos 16 /*!< MPU TYPE: IREGION Position */ +#define MPU_TYPE_IREGION_Msk (0xFFUL << MPU_TYPE_IREGION_Pos) /*!< MPU TYPE: IREGION Mask */ + +#define MPU_TYPE_DREGION_Pos 8 /*!< MPU TYPE: DREGION Position */ +#define MPU_TYPE_DREGION_Msk (0xFFUL << MPU_TYPE_DREGION_Pos) /*!< MPU TYPE: DREGION Mask */ + +#define MPU_TYPE_SEPARATE_Pos 0 /*!< MPU TYPE: SEPARATE Position */ +#define MPU_TYPE_SEPARATE_Msk (1UL << MPU_TYPE_SEPARATE_Pos) /*!< MPU TYPE: SEPARATE Mask */ + +/* MPU Control Register */ +#define MPU_CTRL_PRIVDEFENA_Pos 2 /*!< MPU CTRL: PRIVDEFENA Position */ +#define MPU_CTRL_PRIVDEFENA_Msk (1UL << MPU_CTRL_PRIVDEFENA_Pos) /*!< MPU CTRL: PRIVDEFENA Mask */ + +#define MPU_CTRL_HFNMIENA_Pos 1 /*!< MPU CTRL: HFNMIENA Position */ +#define MPU_CTRL_HFNMIENA_Msk (1UL << MPU_CTRL_HFNMIENA_Pos) /*!< MPU CTRL: HFNMIENA Mask */ + +#define MPU_CTRL_ENABLE_Pos 0 /*!< MPU CTRL: ENABLE Position */ +#define MPU_CTRL_ENABLE_Msk (1UL << MPU_CTRL_ENABLE_Pos) /*!< MPU CTRL: ENABLE Mask */ + +/* MPU Region Number Register */ +#define MPU_RNR_REGION_Pos 0 /*!< MPU RNR: REGION Position */ +#define MPU_RNR_REGION_Msk (0xFFUL << MPU_RNR_REGION_Pos) /*!< MPU RNR: REGION Mask */ + +/* MPU Region Base Address Register */ +#define MPU_RBAR_ADDR_Pos 8 /*!< MPU RBAR: ADDR Position */ +#define MPU_RBAR_ADDR_Msk (0xFFFFFFUL << MPU_RBAR_ADDR_Pos) /*!< MPU RBAR: ADDR Mask */ + +#define MPU_RBAR_VALID_Pos 4 /*!< MPU RBAR: VALID Position */ +#define MPU_RBAR_VALID_Msk (1UL << MPU_RBAR_VALID_Pos) /*!< MPU RBAR: VALID Mask */ + +#define MPU_RBAR_REGION_Pos 0 /*!< MPU RBAR: REGION Position */ +#define MPU_RBAR_REGION_Msk (0xFUL << MPU_RBAR_REGION_Pos) /*!< MPU RBAR: REGION Mask */ + +/* MPU Region Attribute and Size Register */ +#define MPU_RASR_ATTRS_Pos 16 /*!< MPU RASR: MPU Region Attribute field Position */ +#define MPU_RASR_ATTRS_Msk (0xFFFFUL << MPU_RASR_ATTRS_Pos) /*!< MPU RASR: MPU Region Attribute field Mask */ + +#define MPU_RASR_XN_Pos 28 /*!< MPU RASR: ATTRS.XN Position */ +#define MPU_RASR_XN_Msk (1UL << MPU_RASR_XN_Pos) /*!< MPU RASR: ATTRS.XN Mask */ + +#define MPU_RASR_AP_Pos 24 /*!< MPU RASR: ATTRS.AP Position */ +#define MPU_RASR_AP_Msk (0x7UL << MPU_RASR_AP_Pos) /*!< MPU RASR: ATTRS.AP Mask */ + +#define MPU_RASR_TEX_Pos 19 /*!< MPU RASR: ATTRS.TEX Position */ +#define MPU_RASR_TEX_Msk (0x7UL << MPU_RASR_TEX_Pos) /*!< MPU RASR: ATTRS.TEX Mask */ + +#define MPU_RASR_S_Pos 18 /*!< MPU RASR: ATTRS.S Position */ +#define MPU_RASR_S_Msk (1UL << MPU_RASR_S_Pos) /*!< MPU RASR: ATTRS.S Mask */ + +#define MPU_RASR_C_Pos 17 /*!< MPU RASR: ATTRS.C Position */ +#define MPU_RASR_C_Msk (1UL << MPU_RASR_C_Pos) /*!< MPU RASR: ATTRS.C Mask */ + +#define MPU_RASR_B_Pos 16 /*!< MPU RASR: ATTRS.B Position */ +#define MPU_RASR_B_Msk (1UL << MPU_RASR_B_Pos) /*!< MPU RASR: ATTRS.B Mask */ + +#define MPU_RASR_SRD_Pos 8 /*!< MPU RASR: Sub-Region Disable Position */ +#define MPU_RASR_SRD_Msk (0xFFUL << MPU_RASR_SRD_Pos) /*!< MPU RASR: Sub-Region Disable Mask */ + +#define MPU_RASR_SIZE_Pos 1 /*!< MPU RASR: Region Size Field Position */ +#define MPU_RASR_SIZE_Msk (0x1FUL << MPU_RASR_SIZE_Pos) /*!< MPU RASR: Region Size Field Mask */ + +#define MPU_RASR_ENABLE_Pos 0 /*!< MPU RASR: Region enable bit Position */ +#define MPU_RASR_ENABLE_Msk (1UL << MPU_RASR_ENABLE_Pos) /*!< MPU RASR: Region enable bit Disable Mask */ + +/*@} end of group CMSIS_MPU */ +#endif + + +/** \ingroup CMSIS_core_register + \defgroup CMSIS_CoreDebug Core Debug Registers (CoreDebug) + \brief Cortex-M0+ Core Debug Registers (DCB registers, SHCSR, and DFSR) + are only accessible over DAP and not via processor. Therefore + they are not covered by the Cortex-M0 header file. + @{ + */ +/*@} end of group CMSIS_CoreDebug */ + + +/** \ingroup CMSIS_core_register + \defgroup CMSIS_core_base Core Definitions + \brief Definitions for base addresses, unions, and structures. + @{ + */ + +/* Memory mapping of Cortex-M0+ Hardware */ +#define SCS_BASE (0xE000E000UL) /*!< System Control Space Base Address */ +#define SysTick_BASE (SCS_BASE + 0x0010UL) /*!< SysTick Base Address */ +#define NVIC_BASE (SCS_BASE + 0x0100UL) /*!< NVIC Base Address */ +#define SCB_BASE (SCS_BASE + 0x0D00UL) /*!< System Control Block Base Address */ + +#define SCB ((SCB_Type *) SCB_BASE ) /*!< SCB configuration struct */ +#define SysTick ((SysTick_Type *) SysTick_BASE ) /*!< SysTick configuration struct */ +#define NVIC ((NVIC_Type *) NVIC_BASE ) /*!< NVIC configuration struct */ + +#if (__MPU_PRESENT == 1) + #define MPU_BASE (SCS_BASE + 0x0D90UL) /*!< Memory Protection Unit */ + #define MPU ((MPU_Type *) MPU_BASE ) /*!< Memory Protection Unit */ +#endif + +/*@} */ + + + +/******************************************************************************* + * Hardware Abstraction Layer + Core Function Interface contains: + - Core NVIC Functions + - Core SysTick Functions + - Core Register Access Functions + ******************************************************************************/ +/** \defgroup CMSIS_Core_FunctionInterface Functions and Instructions Reference +*/ + + + +/* ########################## NVIC functions #################################### */ +/** \ingroup CMSIS_Core_FunctionInterface + \defgroup CMSIS_Core_NVICFunctions NVIC Functions + \brief Functions that manage interrupts and exceptions via the NVIC. + @{ + */ + +/* Interrupt Priorities are WORD accessible only under ARMv6M */ +/* The following MACROS handle generation of the register offset and byte masks */ +#define _BIT_SHIFT(IRQn) ( (((uint32_t)(IRQn) ) & 0x03) * 8 ) +#define _SHP_IDX(IRQn) ( ((((uint32_t)(IRQn) & 0x0F)-8) >> 2) ) +#define _IP_IDX(IRQn) ( ((uint32_t)(IRQn) >> 2) ) + + +/** \brief Enable External Interrupt + + The function enables a device-specific interrupt in the NVIC interrupt controller. + + \param [in] IRQn External interrupt number. Value cannot be negative. + */ +__STATIC_INLINE void NVIC_EnableIRQ(IRQn_Type IRQn) +{ + NVIC->ISER[0] = (1 << ((uint32_t)(IRQn) & 0x1F)); +} + + +/** \brief Disable External Interrupt + + The function disables a device-specific interrupt in the NVIC interrupt controller. + + \param [in] IRQn External interrupt number. Value cannot be negative. + */ +__STATIC_INLINE void NVIC_DisableIRQ(IRQn_Type IRQn) +{ + NVIC->ICER[0] = (1 << ((uint32_t)(IRQn) & 0x1F)); +} + + +/** \brief Get Pending Interrupt + + The function reads the pending register in the NVIC and returns the pending bit + for the specified interrupt. + + \param [in] IRQn Interrupt number. + + \return 0 Interrupt status is not pending. + \return 1 Interrupt status is pending. + */ +__STATIC_INLINE uint32_t NVIC_GetPendingIRQ(IRQn_Type IRQn) +{ + return((uint32_t) ((NVIC->ISPR[0] & (1 << ((uint32_t)(IRQn) & 0x1F)))?1:0)); +} + + +/** \brief Set Pending Interrupt + + The function sets the pending bit of an external interrupt. + + \param [in] IRQn Interrupt number. Value cannot be negative. + */ +__STATIC_INLINE void NVIC_SetPendingIRQ(IRQn_Type IRQn) +{ + NVIC->ISPR[0] = (1 << ((uint32_t)(IRQn) & 0x1F)); +} + + +/** \brief Clear Pending Interrupt + + The function clears the pending bit of an external interrupt. + + \param [in] IRQn External interrupt number. Value cannot be negative. + */ +__STATIC_INLINE void NVIC_ClearPendingIRQ(IRQn_Type IRQn) +{ + NVIC->ICPR[0] = (1 << ((uint32_t)(IRQn) & 0x1F)); /* Clear pending interrupt */ +} + + +/** \brief Set Interrupt Priority + + The function sets the priority of an interrupt. + + \note The priority cannot be set for every core interrupt. + + \param [in] IRQn Interrupt number. + \param [in] priority Priority to set. + */ +__STATIC_INLINE void NVIC_SetPriority(IRQn_Type IRQn, uint32_t priority) +{ + if(IRQn < 0) { + SCB->SHP[_SHP_IDX(IRQn)] = (SCB->SHP[_SHP_IDX(IRQn)] & ~(0xFF << _BIT_SHIFT(IRQn))) | + (((priority << (8 - __NVIC_PRIO_BITS)) & 0xFF) << _BIT_SHIFT(IRQn)); } + else { + NVIC->IP[_IP_IDX(IRQn)] = (NVIC->IP[_IP_IDX(IRQn)] & ~(0xFF << _BIT_SHIFT(IRQn))) | + (((priority << (8 - __NVIC_PRIO_BITS)) & 0xFF) << _BIT_SHIFT(IRQn)); } +} + + +/** \brief Get Interrupt Priority + + The function reads the priority of an interrupt. The interrupt + number can be positive to specify an external (device specific) + interrupt, or negative to specify an internal (core) interrupt. + + + \param [in] IRQn Interrupt number. + \return Interrupt Priority. Value is aligned automatically to the implemented + priority bits of the microcontroller. + */ +__STATIC_INLINE uint32_t NVIC_GetPriority(IRQn_Type IRQn) +{ + + if(IRQn < 0) { + return((uint32_t)((SCB->SHP[_SHP_IDX(IRQn)] >> _BIT_SHIFT(IRQn) ) >> (8 - __NVIC_PRIO_BITS))); } /* get priority for Cortex-M0+ system interrupts */ + else { + return((uint32_t)((NVIC->IP[ _IP_IDX(IRQn)] >> _BIT_SHIFT(IRQn) ) >> (8 - __NVIC_PRIO_BITS))); } /* get priority for device specific interrupts */ +} + + +/** \brief System Reset + + The function initiates a system reset request to reset the MCU. + */ +__STATIC_INLINE void NVIC_SystemReset(void) +{ + __DSB(); /* Ensure all outstanding memory accesses included + buffered write are completed before reset */ + SCB->AIRCR = ((0x5FA << SCB_AIRCR_VECTKEY_Pos) | + SCB_AIRCR_SYSRESETREQ_Msk); + __DSB(); /* Ensure completion of memory access */ + while(1); /* wait until reset */ +} + +/*@} end of CMSIS_Core_NVICFunctions */ + + + +/* ################################## SysTick function ############################################ */ +/** \ingroup CMSIS_Core_FunctionInterface + \defgroup CMSIS_Core_SysTickFunctions SysTick Functions + \brief Functions that configure the System. + @{ + */ + +#if (__Vendor_SysTickConfig == 0) + +/** \brief System Tick Configuration + + The function initializes the System Timer and its interrupt, and starts the System Tick Timer. + Counter is in free running mode to generate periodic interrupts. + + \param [in] ticks Number of ticks between two interrupts. + + \return 0 Function succeeded. + \return 1 Function failed. + + \note When the variable __Vendor_SysTickConfig is set to 1, then the + function SysTick_Config is not included. In this case, the file device.h + must contain a vendor-specific implementation of this function. + + */ +__STATIC_INLINE uint32_t SysTick_Config(uint32_t ticks) +{ + if (ticks > SysTick_LOAD_RELOAD_Msk) return (1); /* Reload value impossible */ + + SysTick->LOAD = (ticks & SysTick_LOAD_RELOAD_Msk) - 1; /* set reload register */ + NVIC_SetPriority (SysTick_IRQn, (1<<__NVIC_PRIO_BITS) - 1); /* set Priority for Systick Interrupt */ + SysTick->VAL = 0; /* Load the SysTick Counter Value */ + SysTick->CTRL = SysTick_CTRL_CLKSOURCE_Msk | + SysTick_CTRL_TICKINT_Msk | + SysTick_CTRL_ENABLE_Msk; /* Enable SysTick IRQ and SysTick Timer */ + return (0); /* Function successful */ +} + +#endif + +/*@} end of CMSIS_Core_SysTickFunctions */ + + + + +#endif /* __CORE_CM0PLUS_H_DEPENDANT */ + +#endif /* __CMSIS_GENERIC */ + +#ifdef __cplusplus +} +#endif diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/Include/core_cmFunc.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/Include/core_cmFunc.h new file mode 100755 index 0000000..902f4f1 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/Include/core_cmFunc.h @@ -0,0 +1,616 @@ +/**************************************************************************//** + * @file core_cmFunc.h + * @brief CMSIS Cortex-M Core Function Access Header File + * @version V3.00 + * @date 19. January 2012 + * + * @note + * Copyright (C) 2009-2012 ARM Limited. All rights reserved. + * + * @par + * ARM Limited (ARM) is supplying this software for use with Cortex-M + * processor based microcontrollers. This file can be freely distributed + * within development tools that are supporting such ARM based processors. + * + * @par + * THIS SOFTWARE IS PROVIDED "AS IS". NO WARRANTIES, WHETHER EXPRESS, IMPLIED + * OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE. + * ARM SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR SPECIAL, INCIDENTAL, OR + * CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER. + * + ******************************************************************************/ + +#ifndef __CORE_CMFUNC_H +#define __CORE_CMFUNC_H + + +/* ########################### Core Function Access ########################### */ +/** \ingroup CMSIS_Core_FunctionInterface + \defgroup CMSIS_Core_RegAccFunctions CMSIS Core Register Access Functions + @{ + */ + +#if defined ( __CC_ARM ) /*------------------RealView Compiler -----------------*/ +/* ARM armcc specific functions */ + +#if (__ARMCC_VERSION < 400677) + #error "Please use ARM Compiler Toolchain V4.0.677 or later!" +#endif + +/* intrinsic void __enable_irq(); */ +/* intrinsic void __disable_irq(); */ + +/** \brief Get Control Register + + This function returns the content of the Control Register. + + \return Control Register value + */ +__STATIC_INLINE uint32_t __get_CONTROL(void) +{ + register uint32_t __regControl __ASM("control"); + return(__regControl); +} + + +/** \brief Set Control Register + + This function writes the given value to the Control Register. + + \param [in] control Control Register value to set + */ +__STATIC_INLINE void __set_CONTROL(uint32_t control) +{ + register uint32_t __regControl __ASM("control"); + __regControl = control; +} + + +/** \brief Get IPSR Register + + This function returns the content of the IPSR Register. + + \return IPSR Register value + */ +__STATIC_INLINE uint32_t __get_IPSR(void) +{ + register uint32_t __regIPSR __ASM("ipsr"); + return(__regIPSR); +} + + +/** \brief Get APSR Register + + This function returns the content of the APSR Register. + + \return APSR Register value + */ +__STATIC_INLINE uint32_t __get_APSR(void) +{ + register uint32_t __regAPSR __ASM("apsr"); + return(__regAPSR); +} + + +/** \brief Get xPSR Register + + This function returns the content of the xPSR Register. + + \return xPSR Register value + */ +__STATIC_INLINE uint32_t __get_xPSR(void) +{ + register uint32_t __regXPSR __ASM("xpsr"); + return(__regXPSR); +} + + +/** \brief Get Process Stack Pointer + + This function returns the current value of the Process Stack Pointer (PSP). + + \return PSP Register value + */ +__STATIC_INLINE uint32_t __get_PSP(void) +{ + register uint32_t __regProcessStackPointer __ASM("psp"); + return(__regProcessStackPointer); +} + + +/** \brief Set Process Stack Pointer + + This function assigns the given value to the Process Stack Pointer (PSP). + + \param [in] topOfProcStack Process Stack Pointer value to set + */ +__STATIC_INLINE void __set_PSP(uint32_t topOfProcStack) +{ + register uint32_t __regProcessStackPointer __ASM("psp"); + __regProcessStackPointer = topOfProcStack; +} + + +/** \brief Get Main Stack Pointer + + This function returns the current value of the Main Stack Pointer (MSP). + + \return MSP Register value + */ +__STATIC_INLINE uint32_t __get_MSP(void) +{ + register uint32_t __regMainStackPointer __ASM("msp"); + return(__regMainStackPointer); +} + + +/** \brief Set Main Stack Pointer + + This function assigns the given value to the Main Stack Pointer (MSP). + + \param [in] topOfMainStack Main Stack Pointer value to set + */ +__STATIC_INLINE void __set_MSP(uint32_t topOfMainStack) +{ + register uint32_t __regMainStackPointer __ASM("msp"); + __regMainStackPointer = topOfMainStack; +} + + +/** \brief Get Priority Mask + + This function returns the current state of the priority mask bit from the Priority Mask Register. + + \return Priority Mask value + */ +__STATIC_INLINE uint32_t __get_PRIMASK(void) +{ + register uint32_t __regPriMask __ASM("primask"); + return(__regPriMask); +} + + +/** \brief Set Priority Mask + + This function assigns the given value to the Priority Mask Register. + + \param [in] priMask Priority Mask + */ +__STATIC_INLINE void __set_PRIMASK(uint32_t priMask) +{ + register uint32_t __regPriMask __ASM("primask"); + __regPriMask = (priMask); +} + + +#if (__CORTEX_M >= 0x03) + +/** \brief Enable FIQ + + This function enables FIQ interrupts by clearing the F-bit in the CPSR. + Can only be executed in Privileged modes. + */ +#define __enable_fault_irq __enable_fiq + + +/** \brief Disable FIQ + + This function disables FIQ interrupts by setting the F-bit in the CPSR. + Can only be executed in Privileged modes. + */ +#define __disable_fault_irq __disable_fiq + + +/** \brief Get Base Priority + + This function returns the current value of the Base Priority register. + + \return Base Priority register value + */ +__STATIC_INLINE uint32_t __get_BASEPRI(void) +{ + register uint32_t __regBasePri __ASM("basepri"); + return(__regBasePri); +} + + +/** \brief Set Base Priority + + This function assigns the given value to the Base Priority register. + + \param [in] basePri Base Priority value to set + */ +__STATIC_INLINE void __set_BASEPRI(uint32_t basePri) +{ + register uint32_t __regBasePri __ASM("basepri"); + __regBasePri = (basePri & 0xff); +} + + +/** \brief Get Fault Mask + + This function returns the current value of the Fault Mask register. + + \return Fault Mask register value + */ +__STATIC_INLINE uint32_t __get_FAULTMASK(void) +{ + register uint32_t __regFaultMask __ASM("faultmask"); + return(__regFaultMask); +} + + +/** \brief Set Fault Mask + + This function assigns the given value to the Fault Mask register. + + \param [in] faultMask Fault Mask value to set + */ +__STATIC_INLINE void __set_FAULTMASK(uint32_t faultMask) +{ + register uint32_t __regFaultMask __ASM("faultmask"); + __regFaultMask = (faultMask & (uint32_t)1); +} + +#endif /* (__CORTEX_M >= 0x03) */ + + +#if (__CORTEX_M == 0x04) + +/** \brief Get FPSCR + + This function returns the current value of the Floating Point Status/Control register. + + \return Floating Point Status/Control register value + */ +__STATIC_INLINE uint32_t __get_FPSCR(void) +{ +#if (__FPU_PRESENT == 1) && (__FPU_USED == 1) + register uint32_t __regfpscr __ASM("fpscr"); + return(__regfpscr); +#else + return(0); +#endif +} + + +/** \brief Set FPSCR + + This function assigns the given value to the Floating Point Status/Control register. + + \param [in] fpscr Floating Point Status/Control value to set + */ +__STATIC_INLINE void __set_FPSCR(uint32_t fpscr) +{ +#if (__FPU_PRESENT == 1) && (__FPU_USED == 1) + register uint32_t __regfpscr __ASM("fpscr"); + __regfpscr = (fpscr); +#endif +} + +#endif /* (__CORTEX_M == 0x04) */ + + +#elif defined ( __ICCARM__ ) /*------------------ ICC Compiler -------------------*/ +/* IAR iccarm specific functions */ + +#include + + +#elif defined ( __TMS470__ ) /*---------------- TI CCS Compiler ------------------*/ +/* TI CCS specific functions */ + +#include + + +#elif defined ( __GNUC__ ) /*------------------ GNU Compiler ---------------------*/ +/* GNU gcc specific functions */ + +/** \brief Enable IRQ Interrupts + + This function enables IRQ interrupts by clearing the I-bit in the CPSR. + Can only be executed in Privileged modes. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __enable_irq(void) +{ + __ASM volatile ("cpsie i"); +} + + +/** \brief Disable IRQ Interrupts + + This function disables IRQ interrupts by setting the I-bit in the CPSR. + Can only be executed in Privileged modes. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __disable_irq(void) +{ + __ASM volatile ("cpsid i"); +} + + +/** \brief Get Control Register + + This function returns the content of the Control Register. + + \return Control Register value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_CONTROL(void) +{ + uint32_t result; + + __ASM volatile ("MRS %0, control" : "=r" (result) ); + return(result); +} + + +/** \brief Set Control Register + + This function writes the given value to the Control Register. + + \param [in] control Control Register value to set + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __set_CONTROL(uint32_t control) +{ + __ASM volatile ("MSR control, %0" : : "r" (control) ); +} + + +/** \brief Get IPSR Register + + This function returns the content of the IPSR Register. + + \return IPSR Register value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_IPSR(void) +{ + uint32_t result; + + __ASM volatile ("MRS %0, ipsr" : "=r" (result) ); + return(result); +} + + +/** \brief Get APSR Register + + This function returns the content of the APSR Register. + + \return APSR Register value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_APSR(void) +{ + uint32_t result; + + __ASM volatile ("MRS %0, apsr" : "=r" (result) ); + return(result); +} + + +/** \brief Get xPSR Register + + This function returns the content of the xPSR Register. + + \return xPSR Register value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_xPSR(void) +{ + uint32_t result; + + __ASM volatile ("MRS %0, xpsr" : "=r" (result) ); + return(result); +} + + +/** \brief Get Process Stack Pointer + + This function returns the current value of the Process Stack Pointer (PSP). + + \return PSP Register value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_PSP(void) +{ + register uint32_t result; + + __ASM volatile ("MRS %0, psp\n" : "=r" (result) ); + return(result); +} + + +/** \brief Set Process Stack Pointer + + This function assigns the given value to the Process Stack Pointer (PSP). + + \param [in] topOfProcStack Process Stack Pointer value to set + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __set_PSP(uint32_t topOfProcStack) +{ + __ASM volatile ("MSR psp, %0\n" : : "r" (topOfProcStack) ); +} + + +/** \brief Get Main Stack Pointer + + This function returns the current value of the Main Stack Pointer (MSP). + + \return MSP Register value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_MSP(void) +{ + register uint32_t result; + + __ASM volatile ("MRS %0, msp\n" : "=r" (result) ); + return(result); +} + + +/** \brief Set Main Stack Pointer + + This function assigns the given value to the Main Stack Pointer (MSP). + + \param [in] topOfMainStack Main Stack Pointer value to set + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __set_MSP(uint32_t topOfMainStack) +{ + __ASM volatile ("MSR msp, %0\n" : : "r" (topOfMainStack) ); +} + + +/** \brief Get Priority Mask + + This function returns the current state of the priority mask bit from the Priority Mask Register. + + \return Priority Mask value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_PRIMASK(void) +{ + uint32_t result; + + __ASM volatile ("MRS %0, primask" : "=r" (result) ); + return(result); +} + + +/** \brief Set Priority Mask + + This function assigns the given value to the Priority Mask Register. + + \param [in] priMask Priority Mask + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __set_PRIMASK(uint32_t priMask) +{ + __ASM volatile ("MSR primask, %0" : : "r" (priMask) ); +} + + +#if (__CORTEX_M >= 0x03) + +/** \brief Enable FIQ + + This function enables FIQ interrupts by clearing the F-bit in the CPSR. + Can only be executed in Privileged modes. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __enable_fault_irq(void) +{ + __ASM volatile ("cpsie f"); +} + + +/** \brief Disable FIQ + + This function disables FIQ interrupts by setting the F-bit in the CPSR. + Can only be executed in Privileged modes. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __disable_fault_irq(void) +{ + __ASM volatile ("cpsid f"); +} + + +/** \brief Get Base Priority + + This function returns the current value of the Base Priority register. + + \return Base Priority register value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_BASEPRI(void) +{ + uint32_t result; + + __ASM volatile ("MRS %0, basepri_max" : "=r" (result) ); + return(result); +} + + +/** \brief Set Base Priority + + This function assigns the given value to the Base Priority register. + + \param [in] basePri Base Priority value to set + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __set_BASEPRI(uint32_t value) +{ + __ASM volatile ("MSR basepri, %0" : : "r" (value) ); +} + + +/** \brief Get Fault Mask + + This function returns the current value of the Fault Mask register. + + \return Fault Mask register value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_FAULTMASK(void) +{ + uint32_t result; + + __ASM volatile ("MRS %0, faultmask" : "=r" (result) ); + return(result); +} + + +/** \brief Set Fault Mask + + This function assigns the given value to the Fault Mask register. + + \param [in] faultMask Fault Mask value to set + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __set_FAULTMASK(uint32_t faultMask) +{ + __ASM volatile ("MSR faultmask, %0" : : "r" (faultMask) ); +} + +#endif /* (__CORTEX_M >= 0x03) */ + + +#if (__CORTEX_M == 0x04) + +/** \brief Get FPSCR + + This function returns the current value of the Floating Point Status/Control register. + + \return Floating Point Status/Control register value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __get_FPSCR(void) +{ +#if (__FPU_PRESENT == 1) && (__FPU_USED == 1) + uint32_t result; + + __ASM volatile ("VMRS %0, fpscr" : "=r" (result) ); + return(result); +#else + return(0); +#endif +} + + +/** \brief Set FPSCR + + This function assigns the given value to the Floating Point Status/Control register. + + \param [in] fpscr Floating Point Status/Control value to set + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __set_FPSCR(uint32_t fpscr) +{ +#if (__FPU_PRESENT == 1) && (__FPU_USED == 1) + __ASM volatile ("VMSR fpscr, %0" : : "r" (fpscr) ); +#endif +} + +#endif /* (__CORTEX_M == 0x04) */ + + +#elif defined ( __TASKING__ ) /*------------------ TASKING Compiler --------------*/ +/* TASKING carm specific functions */ + +/* + * The CMSIS functions have been implemented as intrinsics in the compiler. + * Please use "carm -?i" to get an up to date list of all instrinsics, + * Including the CMSIS ones. + */ + +#endif + +/*@} end of CMSIS_Core_RegAccFunctions */ + + +#endif /* __CORE_CMFUNC_H */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/Include/core_cmInstr.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/Include/core_cmInstr.h new file mode 100755 index 0000000..0e6cf3d --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/Include/core_cmInstr.h @@ -0,0 +1,618 @@ +/**************************************************************************//** + * @file core_cmInstr.h + * @brief CMSIS Cortex-M Core Instruction Access Header File + * @version V3.00 + * @date 07. February 2012 + * + * @note + * Copyright (C) 2009-2012 ARM Limited. All rights reserved. + * + * @par + * ARM Limited (ARM) is supplying this software for use with Cortex-M + * processor based microcontrollers. This file can be freely distributed + * within development tools that are supporting such ARM based processors. + * + * @par + * THIS SOFTWARE IS PROVIDED "AS IS". NO WARRANTIES, WHETHER EXPRESS, IMPLIED + * OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE. + * ARM SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR SPECIAL, INCIDENTAL, OR + * CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER. + * + ******************************************************************************/ + +#ifndef __CORE_CMINSTR_H +#define __CORE_CMINSTR_H + + +/* ########################## Core Instruction Access ######################### */ +/** \defgroup CMSIS_Core_InstructionInterface CMSIS Core Instruction Interface + Access to dedicated instructions + @{ +*/ + +#if defined ( __CC_ARM ) /*------------------RealView Compiler -----------------*/ +/* ARM armcc specific functions */ + +#if (__ARMCC_VERSION < 400677) + #error "Please use ARM Compiler Toolchain V4.0.677 or later!" +#endif + + +/** \brief No Operation + + No Operation does nothing. This instruction can be used for code alignment purposes. + */ +#define __NOP __nop + + +/** \brief Wait For Interrupt + + Wait For Interrupt is a hint instruction that suspends execution + until one of a number of events occurs. + */ +#define __WFI __wfi + + +/** \brief Wait For Event + + Wait For Event is a hint instruction that permits the processor to enter + a low-power state until one of a number of events occurs. + */ +#define __WFE __wfe + + +/** \brief Send Event + + Send Event is a hint instruction. It causes an event to be signaled to the CPU. + */ +#define __SEV __sev + + +/** \brief Instruction Synchronization Barrier + + Instruction Synchronization Barrier flushes the pipeline in the processor, + so that all instructions following the ISB are fetched from cache or + memory, after the instruction has been completed. + */ +#define __ISB() __isb(0xF) + + +/** \brief Data Synchronization Barrier + + This function acts as a special kind of Data Memory Barrier. + It completes when all explicit memory accesses before this instruction complete. + */ +#define __DSB() __dsb(0xF) + + +/** \brief Data Memory Barrier + + This function ensures the apparent order of the explicit memory operations before + and after the instruction, without ensuring their completion. + */ +#define __DMB() __dmb(0xF) + + +/** \brief Reverse byte order (32 bit) + + This function reverses the byte order in integer value. + + \param [in] value Value to reverse + \return Reversed value + */ +#define __REV __rev + + +/** \brief Reverse byte order (16 bit) + + This function reverses the byte order in two unsigned short values. + + \param [in] value Value to reverse + \return Reversed value + */ +__attribute__((section(".rev16_text"))) __STATIC_INLINE __ASM uint32_t __REV16(uint32_t value) +{ + rev16 r0, r0 + bx lr +} + + +/** \brief Reverse byte order in signed short value + + This function reverses the byte order in a signed short value with sign extension to integer. + + \param [in] value Value to reverse + \return Reversed value + */ +__attribute__((section(".revsh_text"))) __STATIC_INLINE __ASM int32_t __REVSH(int32_t value) +{ + revsh r0, r0 + bx lr +} + + +/** \brief Rotate Right in unsigned value (32 bit) + + This function Rotate Right (immediate) provides the value of the contents of a register rotated by a variable number of bits. + + \param [in] value Value to rotate + \param [in] value Number of Bits to rotate + \return Rotated value + */ +#define __ROR __ror + + +#if (__CORTEX_M >= 0x03) + +/** \brief Reverse bit order of value + + This function reverses the bit order of the given value. + + \param [in] value Value to reverse + \return Reversed value + */ +#define __RBIT __rbit + + +/** \brief LDR Exclusive (8 bit) + + This function performs a exclusive LDR command for 8 bit value. + + \param [in] ptr Pointer to data + \return value of type uint8_t at (*ptr) + */ +#define __LDREXB(ptr) ((uint8_t ) __ldrex(ptr)) + + +/** \brief LDR Exclusive (16 bit) + + This function performs a exclusive LDR command for 16 bit values. + + \param [in] ptr Pointer to data + \return value of type uint16_t at (*ptr) + */ +#define __LDREXH(ptr) ((uint16_t) __ldrex(ptr)) + + +/** \brief LDR Exclusive (32 bit) + + This function performs a exclusive LDR command for 32 bit values. + + \param [in] ptr Pointer to data + \return value of type uint32_t at (*ptr) + */ +#define __LDREXW(ptr) ((uint32_t ) __ldrex(ptr)) + + +/** \brief STR Exclusive (8 bit) + + This function performs a exclusive STR command for 8 bit values. + + \param [in] value Value to store + \param [in] ptr Pointer to location + \return 0 Function succeeded + \return 1 Function failed + */ +#define __STREXB(value, ptr) __strex(value, ptr) + + +/** \brief STR Exclusive (16 bit) + + This function performs a exclusive STR command for 16 bit values. + + \param [in] value Value to store + \param [in] ptr Pointer to location + \return 0 Function succeeded + \return 1 Function failed + */ +#define __STREXH(value, ptr) __strex(value, ptr) + + +/** \brief STR Exclusive (32 bit) + + This function performs a exclusive STR command for 32 bit values. + + \param [in] value Value to store + \param [in] ptr Pointer to location + \return 0 Function succeeded + \return 1 Function failed + */ +#define __STREXW(value, ptr) __strex(value, ptr) + + +/** \brief Remove the exclusive lock + + This function removes the exclusive lock which is created by LDREX. + + */ +#define __CLREX __clrex + + +/** \brief Signed Saturate + + This function saturates a signed value. + + \param [in] value Value to be saturated + \param [in] sat Bit position to saturate to (1..32) + \return Saturated value + */ +#define __SSAT __ssat + + +/** \brief Unsigned Saturate + + This function saturates an unsigned value. + + \param [in] value Value to be saturated + \param [in] sat Bit position to saturate to (0..31) + \return Saturated value + */ +#define __USAT __usat + + +/** \brief Count leading zeros + + This function counts the number of leading zeros of a data value. + + \param [in] value Value to count the leading zeros + \return number of leading zeros in value + */ +#define __CLZ __clz + +#endif /* (__CORTEX_M >= 0x03) */ + + + +#elif defined ( __ICCARM__ ) /*------------------ ICC Compiler -------------------*/ +/* IAR iccarm specific functions */ + +#include + + +#elif defined ( __TMS470__ ) /*---------------- TI CCS Compiler ------------------*/ +/* TI CCS specific functions */ + +#include + + +#elif defined ( __GNUC__ ) /*------------------ GNU Compiler ---------------------*/ +/* GNU gcc specific functions */ + +/** \brief No Operation + + No Operation does nothing. This instruction can be used for code alignment purposes. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __NOP(void) +{ + __ASM volatile ("nop"); +} + + +/** \brief Wait For Interrupt + + Wait For Interrupt is a hint instruction that suspends execution + until one of a number of events occurs. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __WFI(void) +{ + __ASM volatile ("wfi"); +} + + +/** \brief Wait For Event + + Wait For Event is a hint instruction that permits the processor to enter + a low-power state until one of a number of events occurs. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __WFE(void) +{ + __ASM volatile ("wfe"); +} + + +/** \brief Send Event + + Send Event is a hint instruction. It causes an event to be signaled to the CPU. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __SEV(void) +{ + __ASM volatile ("sev"); +} + + +/** \brief Instruction Synchronization Barrier + + Instruction Synchronization Barrier flushes the pipeline in the processor, + so that all instructions following the ISB are fetched from cache or + memory, after the instruction has been completed. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __ISB(void) +{ + __ASM volatile ("isb"); +} + + +/** \brief Data Synchronization Barrier + + This function acts as a special kind of Data Memory Barrier. + It completes when all explicit memory accesses before this instruction complete. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __DSB(void) +{ + __ASM volatile ("dsb"); +} + + +/** \brief Data Memory Barrier + + This function ensures the apparent order of the explicit memory operations before + and after the instruction, without ensuring their completion. + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __DMB(void) +{ + __ASM volatile ("dmb"); +} + + +/** \brief Reverse byte order (32 bit) + + This function reverses the byte order in integer value. + + \param [in] value Value to reverse + \return Reversed value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __REV(uint32_t value) +{ + uint32_t result; + + __ASM volatile ("rev %0, %1" : "=r" (result) : "r" (value) ); + return(result); +} + + +/** \brief Reverse byte order (16 bit) + + This function reverses the byte order in two unsigned short values. + + \param [in] value Value to reverse + \return Reversed value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __REV16(uint32_t value) +{ + uint32_t result; + + __ASM volatile ("rev16 %0, %1" : "=r" (result) : "r" (value) ); + return(result); +} + + +/** \brief Reverse byte order in signed short value + + This function reverses the byte order in a signed short value with sign extension to integer. + + \param [in] value Value to reverse + \return Reversed value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE int32_t __REVSH(int32_t value) +{ + uint32_t result; + + __ASM volatile ("revsh %0, %1" : "=r" (result) : "r" (value) ); + return(result); +} + + +/** \brief Rotate Right in unsigned value (32 bit) + + This function Rotate Right (immediate) provides the value of the contents of a register rotated by a variable number of bits. + + \param [in] value Value to rotate + \param [in] value Number of Bits to rotate + \return Rotated value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __ROR(uint32_t op1, uint32_t op2) +{ + + __ASM volatile ("ror %0, %0, %1" : "+r" (op1) : "r" (op2) ); + return(op1); +} + + +#if (__CORTEX_M >= 0x03) + +/** \brief Reverse bit order of value + + This function reverses the bit order of the given value. + + \param [in] value Value to reverse + \return Reversed value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __RBIT(uint32_t value) +{ + uint32_t result; + + __ASM volatile ("rbit %0, %1" : "=r" (result) : "r" (value) ); + return(result); +} + + +/** \brief LDR Exclusive (8 bit) + + This function performs a exclusive LDR command for 8 bit value. + + \param [in] ptr Pointer to data + \return value of type uint8_t at (*ptr) + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint8_t __LDREXB(volatile uint8_t *addr) +{ + uint8_t result; + + __ASM volatile ("ldrexb %0, [%1]" : "=r" (result) : "r" (addr) ); + return(result); +} + + +/** \brief LDR Exclusive (16 bit) + + This function performs a exclusive LDR command for 16 bit values. + + \param [in] ptr Pointer to data + \return value of type uint16_t at (*ptr) + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint16_t __LDREXH(volatile uint16_t *addr) +{ + uint16_t result; + + __ASM volatile ("ldrexh %0, [%1]" : "=r" (result) : "r" (addr) ); + return(result); +} + + +/** \brief LDR Exclusive (32 bit) + + This function performs a exclusive LDR command for 32 bit values. + + \param [in] ptr Pointer to data + \return value of type uint32_t at (*ptr) + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __LDREXW(volatile uint32_t *addr) +{ + uint32_t result; + + __ASM volatile ("ldrex %0, [%1]" : "=r" (result) : "r" (addr) ); + return(result); +} + + +/** \brief STR Exclusive (8 bit) + + This function performs a exclusive STR command for 8 bit values. + + \param [in] value Value to store + \param [in] ptr Pointer to location + \return 0 Function succeeded + \return 1 Function failed + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __STREXB(uint8_t value, volatile uint8_t *addr) +{ + uint32_t result; + + __ASM volatile ("strexb %0, %2, [%1]" : "=&r" (result) : "r" (addr), "r" (value) ); + return(result); +} + + +/** \brief STR Exclusive (16 bit) + + This function performs a exclusive STR command for 16 bit values. + + \param [in] value Value to store + \param [in] ptr Pointer to location + \return 0 Function succeeded + \return 1 Function failed + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __STREXH(uint16_t value, volatile uint16_t *addr) +{ + uint32_t result; + + __ASM volatile ("strexh %0, %2, [%1]" : "=&r" (result) : "r" (addr), "r" (value) ); + return(result); +} + + +/** \brief STR Exclusive (32 bit) + + This function performs a exclusive STR command for 32 bit values. + + \param [in] value Value to store + \param [in] ptr Pointer to location + \return 0 Function succeeded + \return 1 Function failed + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint32_t __STREXW(uint32_t value, volatile uint32_t *addr) +{ + uint32_t result; + + __ASM volatile ("strex %0, %2, [%1]" : "=&r" (result) : "r" (addr), "r" (value) ); + return(result); +} + + +/** \brief Remove the exclusive lock + + This function removes the exclusive lock which is created by LDREX. + + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE void __CLREX(void) +{ + __ASM volatile ("clrex"); +} + + +/** \brief Signed Saturate + + This function saturates a signed value. + + \param [in] value Value to be saturated + \param [in] sat Bit position to saturate to (1..32) + \return Saturated value + */ +#define __SSAT(ARG1,ARG2) \ +({ \ + uint32_t __RES, __ARG1 = (ARG1); \ + __ASM ("ssat %0, %1, %2" : "=r" (__RES) : "I" (ARG2), "r" (__ARG1) ); \ + __RES; \ + }) + + +/** \brief Unsigned Saturate + + This function saturates an unsigned value. + + \param [in] value Value to be saturated + \param [in] sat Bit position to saturate to (0..31) + \return Saturated value + */ +#define __USAT(ARG1,ARG2) \ +({ \ + uint32_t __RES, __ARG1 = (ARG1); \ + __ASM ("usat %0, %1, %2" : "=r" (__RES) : "I" (ARG2), "r" (__ARG1) ); \ + __RES; \ + }) + + +/** \brief Count leading zeros + + This function counts the number of leading zeros of a data value. + + \param [in] value Value to count the leading zeros + \return number of leading zeros in value + */ +__attribute__( ( always_inline ) ) __STATIC_INLINE uint8_t __CLZ(uint32_t value) +{ + uint8_t result; + + __ASM volatile ("clz %0, %1" : "=r" (result) : "r" (value) ); + return(result); +} + +#endif /* (__CORTEX_M >= 0x03) */ + + + + +#elif defined ( __TASKING__ ) /*------------------ TASKING Compiler --------------*/ +/* TASKING carm specific functions */ + +/* + * The CMSIS functions have been implemented as intrinsics in the compiler. + * Please use "carm -?i" to get an up to date list of all intrinsics, + * Including the CMSIS ones. + */ + +#endif + +/*@}*/ /* end of group CMSIS_Core_InstructionInterface */ + +#endif /* __CORE_CMINSTR_H */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/Lib/GCC/.gitignore b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/Lib/GCC/.gitignore new file mode 100755 index 0000000..5b6ae63 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/Lib/GCC/.gitignore @@ -0,0 +1,4 @@ +# Libraries + +!*.a + diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/Lib/GCC/libarm_cortexM0l_math.a b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/Lib/GCC/libarm_cortexM0l_math.a new file mode 100755 index 0000000..f44336f Binary files /dev/null and b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/Lib/GCC/libarm_cortexM0l_math.a differ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/README.txt b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/README.txt new file mode 100755 index 0000000..41cede7 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/ASF/thirdparty/CMSIS/README.txt @@ -0,0 +1,37 @@ +* ------------------------------------------------------------------- +* Copyright (C) 2011 ARM Limited. All rights reserved. +* +* Date: 11 October 2011 +* Revision: V3.00 +* +* Project: Cortex Microcontroller Software Interface Standard (CMSIS) +* Title: Release Note for CMSIS +* +* ------------------------------------------------------------------- + + +NOTE - Open the index.html file to access CMSIS documentation + + +The Cortex Microcontroller Software Interface Standard (CMSIS) provides a single standard across all +Cortex-Mx processor series vendors. It enables code re-use and code sharing across software projects +and reduces time-to-market for new embedded applications. + +CMSIS is released under the terms of the end user license agreement ("CMSIS END USER LICENCE AGREEMENT.pdf"). +Any user of the software package is bound to the terms and conditions of the end user license agreement. + + +You will find the following sub-directories: + +Documentation - Contains CMSIS documentation. + +DSP_Lib - MDK project files, Examples and source files etc.. to build the + CMSIS DSP Software Library for Cortex-M0, Cortex-M3, Cortex-M4 processors. + +Include - CMSIS Core Support and CMSIS DSP Include Files. + +Lib - CMSIS DSP Libraries. + +RTOS - CMSIS RTOS API template header file. + +SVD - CMSIS SVD Schema files and Conversion Utility. diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/asf.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/asf.h new file mode 100755 index 0000000..ebced37 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/asf.h @@ -0,0 +1,122 @@ +/** + * \file + * + * \brief Autogenerated API include file for the Atmel Software Framework (ASF) + * + * Copyright (c) 2012 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef ASF_H +#define ASF_H + +/* + * This file includes all API header files for the selected drivers from ASF. + * Note: There might be duplicate includes required by more than one driver. + * + * The file is automatically generated and will be re-written when + * running the ASF driver selector tool. Any changes will be discarded. + */ + +// From module: Common SAM0 compiler driver +#include +#include + +// From module: EXTINT - External Interrupt (Callback APIs) +//#include +//#include + +// From module: Generic board support +#include + +// From module: Interrupt management - SAM implementation +#include + +// From module: NVM - Non-Volatile Memory +//#include + +// From module: PORT - GPIO Pin Control +#include + +// From module: Part identification macros +#include + +// From module: RTC - Real Time Counter in Count Mode (Callback APIs) +#include +#include + +// From module: SAM D21/R21 USB Dual role interface +#include + +// From module: SERCOM +#include +#include + +// From module: SERCOM USART - Serial Communications (Polled APIs) +#include + +// From module: SYSTEM - Clock Management for SAMD21 +#include +#include + +// From module: SYSTEM - Core System Driver +#include + +// From module: SYSTEM - I/O Pin Multiplexer +#include + +// From module: SYSTEM - Interrupt Driver +#include + +// From module: Sleep manager - SAMD implementation +#include +#include + +// From module: USB - Universal Serial Bus +#include + +// From module: USB CDC Protocol +#include + +// From module: USB Device CDC (Single Interface Device) +#include + +// From module: USB Device Stack Core (Common API) +#include +#include + +#endif // ASF_H diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/command.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/command.h new file mode 100755 index 0000000..e6942be --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/command.h @@ -0,0 +1,121 @@ +#ifndef COMMAND_H_ +#define COMMAND_H_ + +//**** ATMEL AVR - A P P L I C A T I O N N O T E ************************ +//* +//* Title: AVR068 - STK500 Communication Protocol +//* Filename: command.h +//* Version: 1.0 +//* Last updated: 31.01.2005 +//* +//* Support E-mail: avr@atmel.com +//* +//************************************************************************** + +// *****************[ STK message constants ]*************************** + +#define MESSAGE_START 0x1B //= ESC = 27 decimal +#define TOKEN 0x0E + +// *****************[ STK general command constants ]************************** + +#define CMD_SIGN_ON 0x01 +#define CMD_SET_PARAMETER 0x02 +#define CMD_GET_PARAMETER 0x03 +#define CMD_SET_DEVICE_PARAMETERS 0x04 +#define CMD_OSCCAL 0x05 +#define CMD_LOAD_ADDRESS 0x06 +#define CMD_FIRMWARE_UPGRADE 0x07 + + +// *****************[ STK ISP command constants ]****************************** + +#define CMD_ENTER_PROGMODE_ISP 0x10 +#define CMD_LEAVE_PROGMODE_ISP 0x11 +#define CMD_CHIP_ERASE_ISP 0x12 +#define CMD_PROGRAM_FLASH_ISP 0x13 +#define CMD_READ_FLASH_ISP 0x14 +#define CMD_PROGRAM_EEPROM_ISP 0x15 +#define CMD_READ_EEPROM_ISP 0x16 +#define CMD_PROGRAM_FUSE_ISP 0x17 +#define CMD_READ_FUSE_ISP 0x18 +#define CMD_PROGRAM_LOCK_ISP 0x19 +#define CMD_READ_LOCK_ISP 0x1A +#define CMD_READ_SIGNATURE_ISP 0x1B +#define CMD_READ_OSCCAL_ISP 0x1C +#define CMD_SPI_MULTI 0x1D + +// *****************[ STK PP command constants ]******************************* + +#define CMD_ENTER_PROGMODE_PP 0x20 +#define CMD_LEAVE_PROGMODE_PP 0x21 +#define CMD_CHIP_ERASE_PP 0x22 +#define CMD_PROGRAM_FLASH_PP 0x23 +#define CMD_READ_FLASH_PP 0x24 +#define CMD_PROGRAM_EEPROM_PP 0x25 +#define CMD_READ_EEPROM_PP 0x26 +#define CMD_PROGRAM_FUSE_PP 0x27 +#define CMD_READ_FUSE_PP 0x28 +#define CMD_PROGRAM_LOCK_PP 0x29 +#define CMD_READ_LOCK_PP 0x2A +#define CMD_READ_SIGNATURE_PP 0x2B +#define CMD_READ_OSCCAL_PP 0x2C + +#define CMD_SET_CONTROL_STACK 0x2D + +// *****************[ STK HVSP command constants ]***************************** + +#define CMD_ENTER_PROGMODE_HVSP 0x30 +#define CMD_LEAVE_PROGMODE_HVSP 0x31 +#define CMD_CHIP_ERASE_HVSP 0x32 +#define CMD_PROGRAM_FLASH_HVSP ` 0x33 +#define CMD_READ_FLASH_HVSP 0x34 +#define CMD_PROGRAM_EEPROM_HVSP 0x35 +#define CMD_READ_EEPROM_HVSP 0x36 +#define CMD_PROGRAM_FUSE_HVSP 0x37 +#define CMD_READ_FUSE_HVSP 0x38 +#define CMD_PROGRAM_LOCK_HVSP 0x39 +#define CMD_READ_LOCK_HVSP 0x3A +#define CMD_READ_SIGNATURE_HVSP 0x3B +#define CMD_READ_OSCCAL_HVSP 0x3C + +// *****************[ STK status constants ]*************************** + +// Success +#define STATUS_CMD_OK 0x00 + +// Warnings +#define STATUS_CMD_TOUT 0x80 +#define STATUS_RDY_BSY_TOUT 0x81 +#define STATUS_SET_PARAM_MISSING 0x82 + +// Errors +#define STATUS_CMD_FAILED 0xC0 +#define STATUS_CKSUM_ERROR 0xC1 +#define STATUS_CMD_UNKNOWN 0xC9 + +// *****************[ STK parameter constants ]*************************** +#define PARAM_BUILD_NUMBER_LOW 0x80 +#define PARAM_BUILD_NUMBER_HIGH 0x81 +#define PARAM_HW_VER 0x90 +#define PARAM_SW_MAJOR 0x91 +#define PARAM_SW_MINOR 0x92 +#define PARAM_VTARGET 0x94 +#define PARAM_VADJUST 0x95 +#define PARAM_OSC_PSCALE 0x96 +#define PARAM_OSC_CMATCH 0x97 +#define PARAM_SCK_DURATION 0x98 +#define PARAM_TOPCARD_DETECT 0x9A +#define PARAM_STATUS 0x9C +#define PARAM_DATA 0x9D +#define PARAM_RESET_POLARITY 0x9E +#define PARAM_CONTROLLER_INIT 0x9F + +// *****************[ STK answer constants ]*************************** + +#define ANSWER_CKSUM_ERROR 0xB0 + + + + +#endif /* COMMAND_H_ */ \ No newline at end of file diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/config/conf_board.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/config/conf_board.h new file mode 100755 index 0000000..1766a3c --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/config/conf_board.h @@ -0,0 +1,47 @@ +/** + * \file + * + * \brief SAM D21 Xplained Pro board configuration. + * + * Copyright (c) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef CONF_BOARD_H_INCLUDED +#define CONF_BOARD_H_INCLUDED + +#endif /* CONF_BOARD_H_INCLUDED */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/config/conf_clocks.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/config/conf_clocks.h new file mode 100755 index 0000000..99e72b4 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/config/conf_clocks.h @@ -0,0 +1,183 @@ +/** + * \file + * + * \brief SAM D21 Clock configuration + * + * Copyright (C) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#include + +#ifndef CONF_CLOCKS_H_INCLUDED +# define CONF_CLOCKS_H_INCLUDED + +/* System clock bus configuration */ +# define CONF_CLOCK_CPU_CLOCK_FAILURE_DETECT true +# define CONF_CLOCK_FLASH_WAIT_STATES 2 +# define CONF_CLOCK_CPU_DIVIDER SYSTEM_MAIN_CLOCK_DIV_1 +# define CONF_CLOCK_APBA_DIVIDER SYSTEM_MAIN_CLOCK_DIV_1 +# define CONF_CLOCK_APBB_DIVIDER SYSTEM_MAIN_CLOCK_DIV_1 + +/* SYSTEM_CLOCK_SOURCE_OSC8M configuration - Internal 8MHz oscillator */ +# define CONF_CLOCK_OSC8M_PRESCALER SYSTEM_OSC8M_DIV_1 +# define CONF_CLOCK_OSC8M_ON_DEMAND true +# define CONF_CLOCK_OSC8M_RUN_IN_STANDBY false + +/* SYSTEM_CLOCK_SOURCE_XOSC configuration - External clock/oscillator */ +# define CONF_CLOCK_XOSC_ENABLE false +# define CONF_CLOCK_XOSC_EXTERNAL_CRYSTAL SYSTEM_CLOCK_EXTERNAL_CRYSTAL +# define CONF_CLOCK_XOSC_EXTERNAL_FREQUENCY 12000000UL +# define CONF_CLOCK_XOSC_STARTUP_TIME SYSTEM_XOSC_STARTUP_32768 +# define CONF_CLOCK_XOSC_AUTO_GAIN_CONTROL true +# define CONF_CLOCK_XOSC_ON_DEMAND true +# define CONF_CLOCK_XOSC_RUN_IN_STANDBY false + +/* SYSTEM_CLOCK_SOURCE_XOSC32K configuration - External 32KHz crystal/clock oscillator */ +# define CONF_CLOCK_XOSC32K_ENABLE false +# define CONF_CLOCK_XOSC32K_EXTERNAL_CRYSTAL SYSTEM_CLOCK_EXTERNAL_CRYSTAL +# define CONF_CLOCK_XOSC32K_STARTUP_TIME SYSTEM_XOSC32K_STARTUP_65536 +# define CONF_CLOCK_XOSC32K_AUTO_AMPLITUDE_CONTROL false +# define CONF_CLOCK_XOSC32K_ENABLE_1KHZ_OUPUT false +# define CONF_CLOCK_XOSC32K_ENABLE_32KHZ_OUTPUT true +# define CONF_CLOCK_XOSC32K_ON_DEMAND true +# define CONF_CLOCK_XOSC32K_RUN_IN_STANDBY false + +/* SYSTEM_CLOCK_SOURCE_OSC32K configuration - Internal 32KHz oscillator */ +# define CONF_CLOCK_OSC32K_ENABLE false +# define CONF_CLOCK_OSC32K_STARTUP_TIME SYSTEM_OSC32K_STARTUP_130 +# define CONF_CLOCK_OSC32K_ENABLE_1KHZ_OUTPUT true +# define CONF_CLOCK_OSC32K_ENABLE_32KHZ_OUTPUT true +# define CONF_CLOCK_OSC32K_ON_DEMAND true +# define CONF_CLOCK_OSC32K_RUN_IN_STANDBY false + +/* SYSTEM_CLOCK_SOURCE_DFLL configuration - Digital Frequency Locked Loop */ +# define CONF_CLOCK_DFLL_ENABLE true +# define CONF_CLOCK_DFLL_LOOP_MODE SYSTEM_CLOCK_DFLL_LOOP_MODE_USB_RECOVERY +# define CONF_CLOCK_DFLL_ON_DEMAND true + +/* DFLL open loop mode configuration */ +# define CONF_CLOCK_DFLL_COARSE_VALUE (0x1f / 4) +# define CONF_CLOCK_DFLL_FINE_VALUE (0xff / 4) + +/* DFLL closed loop mode configuration */ +# define CONF_CLOCK_DFLL_SOURCE_GCLK_GENERATOR GCLK_GENERATOR_1 +# define CONF_CLOCK_DFLL_MULTIPLY_FACTOR 6 +# define CONF_CLOCK_DFLL_QUICK_LOCK true +# define CONF_CLOCK_DFLL_TRACK_AFTER_FINE_LOCK true +# define CONF_CLOCK_DFLL_KEEP_LOCK_ON_WAKEUP true +# define CONF_CLOCK_DFLL_ENABLE_CHILL_CYCLE true +# define CONF_CLOCK_DFLL_MAX_COARSE_STEP_SIZE (0x1f / 4) +# define CONF_CLOCK_DFLL_MAX_FINE_STEP_SIZE (0xff / 4) + +/* SYSTEM_CLOCK_SOURCE_DPLL configuration - Digital Phase-Locked Loop */ +# define CONF_CLOCK_DPLL_ENABLE false +# define CONF_CLOCK_DPLL_ON_DEMAND true +# define CONF_CLOCK_DPLL_RUN_IN_STANDBY false +# define CONF_CLOCK_DPLL_LOCK_BYPASS false +# define CONF_CLOCK_DPLL_WAKE_UP_FAST false +# define CONF_CLOCK_DPLL_LOW_POWER_ENABLE false + +# define CONF_CLOCK_DPLL_LOCK_TIME SYSTEM_CLOCK_SOURCE_DPLL_LOCK_TIME_NO_TIMEOUT +# define CONF_CLOCK_DPLL_REFERENCE_CLOCK SYSTEM_CLOCK_SOURCE_DPLL_REFERENCE_CLOCK_REF0 +# define CONF_CLOCK_DPLL_FILTER SYSTEM_CLOCK_SOURCE_DPLL_FILTER_DEFAULT + +# define CONF_CLOCK_DPLL_REFERENCE_FREQUENCY 32768 +# define CONF_CLOCK_DPLL_REFEREMCE_DIVIDER 1 +# define CONF_CLOCK_DPLL_OUTPUT_FREQUENCY 48000000 + +/* Set this to true to configure the GCLK when running clocks_init. If set to + * false, none of the GCLK generators will be configured in clocks_init(). */ +# define CONF_CLOCK_CONFIGURE_GCLK true + +/* Configure GCLK generator 0 (Main Clock) */ +# define CONF_CLOCK_GCLK_0_ENABLE true +# define CONF_CLOCK_GCLK_0_RUN_IN_STANDBY true +# define CONF_CLOCK_GCLK_0_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_DFLL +# define CONF_CLOCK_GCLK_0_PRESCALER 1 +# define CONF_CLOCK_GCLK_0_OUTPUT_ENABLE false + +/* Configure GCLK generator 1 */ +# define CONF_CLOCK_GCLK_1_ENABLE false +# define CONF_CLOCK_GCLK_1_RUN_IN_STANDBY false +# define CONF_CLOCK_GCLK_1_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_OSC8M +# define CONF_CLOCK_GCLK_1_PRESCALER 1 +# define CONF_CLOCK_GCLK_1_OUTPUT_ENABLE false + +/* Configure GCLK generator 2 (RTC) */ +# define CONF_CLOCK_GCLK_2_ENABLE true +# define CONF_CLOCK_GCLK_2_RUN_IN_STANDBY false +# define CONF_CLOCK_GCLK_2_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_ULP32K +# define CONF_CLOCK_GCLK_2_PRESCALER 32 +# define CONF_CLOCK_GCLK_2_OUTPUT_ENABLE false + +/* Configure GCLK generator 3 */ +# define CONF_CLOCK_GCLK_3_ENABLE false +# define CONF_CLOCK_GCLK_3_RUN_IN_STANDBY false +# define CONF_CLOCK_GCLK_3_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_OSC8M +# define CONF_CLOCK_GCLK_3_PRESCALER 1 +# define CONF_CLOCK_GCLK_3_OUTPUT_ENABLE false + +/* Configure GCLK generator 4 */ +# define CONF_CLOCK_GCLK_4_ENABLE false +# define CONF_CLOCK_GCLK_4_RUN_IN_STANDBY false +# define CONF_CLOCK_GCLK_4_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_OSC8M +# define CONF_CLOCK_GCLK_4_PRESCALER 1 +# define CONF_CLOCK_GCLK_4_OUTPUT_ENABLE false + +/* Configure GCLK generator 5 */ +# define CONF_CLOCK_GCLK_5_ENABLE false +# define CONF_CLOCK_GCLK_5_RUN_IN_STANDBY false +# define CONF_CLOCK_GCLK_5_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_OSC8M +# define CONF_CLOCK_GCLK_5_PRESCALER 1 +# define CONF_CLOCK_GCLK_5_OUTPUT_ENABLE false + +/* Configure GCLK generator 6 */ +# define CONF_CLOCK_GCLK_6_ENABLE false +# define CONF_CLOCK_GCLK_6_RUN_IN_STANDBY false +# define CONF_CLOCK_GCLK_6_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_OSC8M +# define CONF_CLOCK_GCLK_6_PRESCALER 1 +# define CONF_CLOCK_GCLK_6_OUTPUT_ENABLE false + +/* Configure GCLK generator 7 */ +# define CONF_CLOCK_GCLK_7_ENABLE false +# define CONF_CLOCK_GCLK_7_RUN_IN_STANDBY false +# define CONF_CLOCK_GCLK_7_CLOCK_SOURCE SYSTEM_CLOCK_SOURCE_OSC8M +# define CONF_CLOCK_GCLK_7_PRESCALER 1 +# define CONF_CLOCK_GCLK_7_OUTPUT_ENABLE false + +#endif /* CONF_CLOCKS_H_INCLUDED */ + diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/config/conf_extint.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/config/conf_extint.h new file mode 100755 index 0000000..0f5b08a --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/config/conf_extint.h @@ -0,0 +1,48 @@ +/** + * \file + * + * \brief SAM External Interrupt Driver Configuration Header + * + * Copyright (C) 2013-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef CONF_EXTINT_H_INCLUDED +#define CONF_EXTINT_H_INCLUDED + +# define EXTINT_CLOCK_SOURCE GCLK_GENERATOR_0 + +#endif diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/config/conf_sleepmgr.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/config/conf_sleepmgr.h new file mode 100755 index 0000000..38a889b --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/config/conf_sleepmgr.h @@ -0,0 +1,49 @@ +/** + * \file + * + * \brief Chip-specific sleep manager configuration + * + * Copyright (c) 2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ +#ifndef CONF_SLEEPMGR_INCLUDED +#define CONF_SLEEPMGR_INCLUDED + +// Sleep manager options +#define CONFIG_SLEEPMGR_ENABLE + +#endif /* CONF_SLEEPMGR_INCLUDED */ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/config/conf_usb.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/config/conf_usb.h new file mode 100755 index 0000000..c4889b8 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/config/conf_usb.h @@ -0,0 +1,202 @@ +/** + * \file + * + * \brief USB configuration file for CDC application + * + * Copyright (c) 2009-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _CONF_USB_H_ +#define _CONF_USB_H_ + +#include "compiler.h" +#include "board.h" + +/** + * USB Device Configuration + * @{ + */ + + // Arduino srl USB VID Definition. + #define USB_VENDOR_ID 0x2A03 + #define USB_VENDOR_DESCRIPTOR "Arduino srl (www.arduino.org)" + + // Arduiino Zero Pro USB PID + //#define USB_PRODUCT_ID 0x004D + //#define USB_PRODUCT_NAME "Arduino Zero PRO" + + // Arduino M0 Pro USB PID + //#define USB_PRODUCT_ID 0x004E // Arduino M0 PID + //#define USB_PRODUCT_NAME "Arduino M0 PRO" + + // Arduino M0 Pro USB PID + //#define USB_PRODUCT_ID 0x004F // Arduino M0 PRO PID + //#define USB_PRODUCT_NAME "Arduino M0 PRO" + + // Arduino Tian USB PID + #define USB_PRODUCT_ID 0x0052 // Arduino Tian PID + #define USB_PRODUCT_NAME "Arduino Tian" + + // Arduino M0s USB PID + //#define USB_PRODUCT_ID 0x0053 // Arduino M0s PID + //#define USB_PRODUCT_NAME "Arduino M0s" + + + +//! Device definition (mandatory) +#define USB_DEVICE_VENDOR_ID USB_VENDOR_ID +#if BOARD == UC3B_BOARD_CONTROLLER +# define USB_DEVICE_PRODUCT_ID USB_PID_ATMEL_UC3_CDC_DEBUG +#else +# define USB_DEVICE_PRODUCT_ID USB_PRODUCT_ID + + +#endif +#define USB_DEVICE_MAJOR_VERSION 1 +#define USB_DEVICE_MINOR_VERSION 0 +#define USB_DEVICE_POWER 100 // Consumption on Vbus line (mA) +#define USB_DEVICE_ATTR \ + (USB_CONFIG_ATTR_SELF_POWERED) +// (USB_CONFIG_ATTR_BUS_POWERED) +// (USB_CONFIG_ATTR_REMOTE_WAKEUP|USB_CONFIG_ATTR_SELF_POWERED) +// (USB_CONFIG_ATTR_REMOTE_WAKEUP|USB_CONFIG_ATTR_BUS_POWERED) + +//! USB Device string definitions (Optional) +#define USB_DEVICE_MANUFACTURE_NAME USB_VENDOR_DESCRIPTOR +#define USB_DEVICE_PRODUCT_NAME USB_PRODUCT_NAME + +// Serial Number Definition (needed for Drivers Signature) +//#define USB_DEVICE_SERIAL_NAME "004D" // Arduino Zero PRO USB Serial Number +//#define USB_DEVICE_SERIAL_NAME "004F" // Arduino M0 PRO USB Serial Number +//#define USB_DEVICE_SERIAL_NAME "004E" // Arduino M0 USB Serial Number +//#define USB_DEVICE_SERIAL_NAME "0052" // Arduino Tian Serial Number +#define USB_DEVICE_SERIAL_NAME "0053" // Arduino M0s Serial Number + + + + + +/** + * Device speeds support + * Low speed not supported by CDC + * @{ + */ +//! To authorize the High speed +#if (UC3A3||UC3A4) +#define USB_DEVICE_HS_SUPPORT +#elif (SAM3XA||SAM3U) +#define USB_DEVICE_HS_SUPPORT +#endif +//@} + + +/** + * USB Device Callbacks definitions (Optional) + * @{ + */ +#define UDC_VBUS_EVENT(b_vbus_high) +#define UDC_SOF_EVENT() +#define UDC_SUSPEND_EVENT() +#define UDC_RESUME_EVENT() +//! Mandatory when USB_DEVICE_ATTR authorizes remote wakeup feature +// #define UDC_REMOTEWAKEUP_ENABLE() user_callback_remotewakeup_enable() +// extern void user_callback_remotewakeup_enable(void); +// #define UDC_REMOTEWAKEUP_DISABLE() user_callback_remotewakeup_disable() +// extern void user_callback_remotewakeup_disable(void); +#ifdef USB_DEVICE_LPM_SUPPORT +#define UDC_SUSPEND_LPM_EVENT() +#define UDC_REMOTEWAKEUP_LPM_ENABLE() +#define UDC_REMOTEWAKEUP_LPM_DISABLE() +#endif +//! When a extra string descriptor must be supported +//! other than manufacturer, product and serial string +// #define UDC_GET_EXTRA_STRING() +//@} + +//@} + + +/** + * USB Interface Configuration + * @{ + */ +/** + * Configuration of CDC interface + * @{ + */ + +//! Define two USB communication ports +#define UDI_CDC_PORT_NB 1 + +//! Interface callback definition +#define UDI_CDC_ENABLE_EXT(port) true +#define UDI_CDC_DISABLE_EXT(port) +#define UDI_CDC_RX_NOTIFY(port) +#define UDI_CDC_TX_EMPTY_NOTIFY(port) +#define UDI_CDC_SET_CODING_EXT(port,cfg) main_cdc_config(port,cfg) +#define UDI_CDC_SET_DTR_EXT(port,set) +#define UDI_CDC_SET_RTS_EXT(port,set) + +//! Define it when the transfer CDC Device to Host is a low rate (<512000 bauds) +//! to reduce CDC buffers size +//#define UDI_CDC_LOW_RATE + +//! Default configuration of communication port +#if BOARD == UC3B_BOARD_CONTROLLER +#define UDI_CDC_DEFAULT_RATE 57600 +#else +#define UDI_CDC_DEFAULT_RATE 115200 +#endif +#define UDI_CDC_DEFAULT_STOPBITS CDC_STOP_BITS_1 +#define UDI_CDC_DEFAULT_PARITY CDC_PAR_NONE +#define UDI_CDC_DEFAULT_DATABITS 8 +//@} +//@} + + +/** + * USB Device Driver Configuration + * @{ + */ +//@} + +//! The includes of classes and other headers must be done at the end of this file to avoid compile error +#include "udi_cdc_conf.h" +#include "main.h" + +#endif // _CONF_USB_H_ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/main.c b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/main.c new file mode 100755 index 0000000..15a947d --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/main.c @@ -0,0 +1,280 @@ +/*---------- GNU PUBLIC LICENZE V3 ---------- +* +* Copyright Arduino srl (c) 2015 +* +* This file is part of Bootloader_D21. +* +* Bootloader_D21 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. +* +* bootloader_D21 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 Bootloader_D21. If not, see . +* +*/ + +/* + * Include header files for all drivers that have been imported from + * Atmel Software Framework (ASF). + */ + +#include +#include + +static inline bool nvm_is_ready(void) +{ + /* Get a pointer to the module hardware instance */ + Nvmctrl *const nvm_module = NVMCTRL; + + return nvm_module->INTFLAG.reg & NVMCTRL_INTFLAG_READY; +} +#include +enum nvm_cache_readmode { + /** The NVM Controller (cache system) does not insert wait states on + * a cache miss. Gives the best system performance. + */ + NVM_CACHE_READMODE_NO_MISS_PENALTY, + /** Reduces power consumption of the cache system, but inserts a + * wait state each time there is a cache miss + */ + NVM_CACHE_READMODE_LOW_POWER, + /** The cache system ensures that a cache hit or miss takes the same + * amount of time, determined by the number of programmed flash + * wait states. + */ + NVM_CACHE_READMODE_DETERMINISTIC, +}; + +enum nvm_sleep_power_mode { + /** NVM controller exits low power mode on first access after sleep. */ + NVM_SLEEP_POWER_MODE_WAKEONACCESS = NVMCTRL_CTRLB_SLEEPPRM_WAKEONACCESS_Val, + /** NVM controller exits low power mode when the device exits sleep mode. */ + NVM_SLEEP_POWER_MODE_WAKEUPINSTANT = NVMCTRL_CTRLB_SLEEPPRM_WAKEUPINSTANT_Val, + /** Power reduction mode in the NVM controller disabled. */ + NVM_SLEEP_POWER_MODE_ALWAYS_AWAKE = NVMCTRL_CTRLB_SLEEPPRM_DISABLED_Val, +}; + + +void configure_nvm(void) +{ + /* Turn on the digital interface clock */ + system_apb_clock_set_mask(SYSTEM_CLOCK_APB_APBB, PM_APBBMASK_NVMCTRL); + + /* Clear error flags */ + NVMCTRL->STATUS.reg |= NVMCTRL_STATUS_MASK; + + /* Check if the module is busy */ + if (!nvm_is_ready()) { + return STATUS_BUSY; + } + + /* Writing configuration to the CTRLB register */ + NVMCTRL->CTRLB.reg = + NVMCTRL_CTRLB_SLEEPPRM(NVM_SLEEP_POWER_MODE_WAKEONACCESS) | + ((false & 0x01) << NVMCTRL_CTRLB_MANW_Pos) | + NVMCTRL_CTRLB_RWS(NVMCTRL->CTRLB.bit.RWS) | + ((false & 0x01) << NVMCTRL_CTRLB_CACHEDIS_Pos) | + NVMCTRL_CTRLB_READMODE(NVM_CACHE_READMODE_NO_MISS_PENALTY); +} + +/** + * \brief Function to start the application. + */ +static void start_application(void) +{ + /* Pointer to the Application Section */ + void (*application_code_entry)(void); + + /* Rebase the Stack Pointer */ + __set_MSP(*(uint32_t *)APP_START_ADDR); + + /* Rebase the vector table base address */ + SCB->VTOR = ((uint32_t)APP_START_ADDR & SCB_VTOR_TBLOFF_Msk); + + /* Load the Reset Handler address of the application */ + application_code_entry = (void (*)(void))(unsigned *)(*(unsigned *) + (APP_START_ADDR + 4)); + + /* Jump to user Reset Handler in the application */ + application_code_entry(); +} + +struct rtc_module rtc_instance; + +void rtc_overflow_callback(void) +{ + timeout+=2;//callback is called every 2ms + if(timeout > TIMOUT_PERIOD) + { + rtc_count_disable(&rtc_instance); + rtc_count_clear_overflow(&rtc_instance); + NVIC_ClearPendingIRQ(RTC_IRQn); + udc_stop(); + cpu_irq_disable(); + //SCB->AIRCR = ((0x05FA<<16)|0b100); //reset cpu + NVIC_SystemReset() ; + while(1) + { + //wait for WDT + } + } + if((timeout % 50) == 0) + { + port_pin_toggle_output_level(LED_L_PIN); // when the board is in bootloader mode the L Led blink + } +} +void configure_timeout() +{ + struct rtc_count_config config_rtc_count; + rtc_count_get_config_defaults(&config_rtc_count); + config_rtc_count.prescaler = RTC_COUNT_PRESCALER_DIV_1; + config_rtc_count.mode = RTC_COUNT_MODE_16BIT; + config_rtc_count.continuously_update = true; + rtc_count_init(&rtc_instance, RTC, &config_rtc_count); + rtc_count_enable(&rtc_instance); rtc_count_register_callback( + &rtc_instance, rtc_overflow_callback, RTC_COUNT_CALLBACK_OVERFLOW); + rtc_count_enable_callback(&rtc_instance, RTC_COUNT_CALLBACK_OVERFLOW); rtc_count_set_period(&rtc_instance, 1);//1 ms per callback NVIC_SetPriority(RTC_IRQn, 0);//RTC Top priority +} + + +void configure_port_pins(void) +{ + struct port_config config_port_pin; + port_get_config_defaults(&config_port_pin); + config_port_pin.direction = PORT_PIN_DIR_INPUT; + config_port_pin.input_pull = PORT_PIN_PULL_UP; + port_pin_set_config(BUTTON_0_PIN, &config_port_pin); +} + + +//1 =16 kb +#define BOOTLOADER_SIZE 1 + +void protect_boot_section() +{ + system_interrupt_enter_critical_section(); + volatile uint32_t raw_fusebits[2]; + + /* Make sure the module is ready */ + while (!nvm_is_ready()) { + }; + + /* Read the fuse settings in the user row, 64 bit */ + ((uint16_t*)&raw_fusebits)[0] = (uint16_t)NVM_MEMORY[NVMCTRL_USER / 2]; + ((uint16_t*)&raw_fusebits)[1] = (uint16_t)NVM_MEMORY[(NVMCTRL_USER / 2) + 1]; + ((uint16_t*)&raw_fusebits)[2] = (uint16_t)NVM_MEMORY[(NVMCTRL_USER / 2) + 2]; + ((uint16_t*)&raw_fusebits)[3] = (uint16_t)NVM_MEMORY[(NVMCTRL_USER / 2) + 3]; + if(((raw_fusebits[0] & NVMCTRL_FUSES_BOOTPROT_Msk)>> NVMCTRL_FUSES_BOOTPROT_Pos) != BOOTLOADER_SIZE) + { + /* Auxiliary space cannot be accessed if the security bit is set */ + if (NVMCTRL->STATUS.reg & NVMCTRL_STATUS_SB) { + return; + } + /* Disable Cache */ + uint32_t temp = NVMCTRL->CTRLB.reg; + + NVMCTRL->CTRLB.reg = temp | NVMCTRL_CTRLB_CACHEDIS; + + /* Clear error flags */ + NVMCTRL->STATUS.reg |= NVMCTRL_STATUS_MASK; + + /* Set address, command will be issued elsewhere */ + NVMCTRL->ADDR.reg = NVMCTRL_AUX0_ADDRESS/2; + + /* Erase the user page */ + NVMCTRL->CTRLA.reg = NVMCTRL_CTRLA_CMD_EAR | NVMCTRL_CTRLA_CMDEX_KEY; + + /* Wait for NVM command to complete */ + while (!(NVMCTRL->INTFLAG.reg & NVMCTRL_INTFLAG_READY)); + + /* Clear error flags */ + NVMCTRL->STATUS.reg |= NVMCTRL_STATUS_MASK; + + /* Set address, command will be issued elsewhere */ + NVMCTRL->ADDR.reg = NVMCTRL_AUX0_ADDRESS/2; + + /* Erase the page buffer before buffering new data */ + NVMCTRL->CTRLA.reg = NVMCTRL_CTRLA_CMD_PBC | NVMCTRL_CTRLA_CMDEX_KEY; + + /* Wait for NVM command to complete */ + while (!(NVMCTRL->INTFLAG.reg & NVMCTRL_INTFLAG_READY)); + + /* Clear error flags */ + NVMCTRL->STATUS.reg |= NVMCTRL_STATUS_MASK; + + /* Set address, command will be issued elsewhere */ + NVMCTRL->ADDR.reg = NVMCTRL_AUX0_ADDRESS/2; + raw_fusebits[0] = ((raw_fusebits[0] ^ NVMCTRL_FUSES_BOOTPROT_Msk) | NVMCTRL_FUSES_BOOTPROT(BOOTLOADER_SIZE)); + *((uint32_t *)NVMCTRL_AUX0_ADDRESS) = raw_fusebits[0]; + *(((uint32_t *)NVMCTRL_AUX0_ADDRESS) + 1) = raw_fusebits[1]; + + /* Write the user page */ + NVMCTRL->CTRLA.reg = NVMCTRL_CTRLA_CMD_WAP | NVMCTRL_CTRLA_CMDEX_KEY; + + /* Restore the settings */ + NVMCTRL->CTRLB.reg = temp; + + + //nvm_execute_command(NVM_COMMAND_WRITE_AUX_ROW, NVMCTRL_USER, 0); + } + system_interrupt_leave_critical_section(); +} + +int main (void) +{ + + /* Check if WDT is locked */ + + + if (!(WDT->CTRL.reg & WDT_CTRL_ALWAYSON)) { + /* Disable the Watchdog module */ + WDT->CTRL.reg &= ~WDT_CTRL_ENABLE; + } + if(!(PM->RCAUSE.reg & PM_RCAUSE_EXT) && !(PM->RCAUSE.reg & PM_RCAUSE_WDT) && (NVM_MEMORY[APP_START_ADDR / 2] != 0xFFFF)) //Power on reset or systemResetReq -> run main app + { + start_application(); + } + //if reset by wdt or reset button, run bootloader + irq_initialize_vectors(); + cpu_irq_enable(); + + system_init(); + + configure_timeout(); + configure_nvm(); + + // start usart + configure_usart(); + // Start USB stack to authorize VBus monitoring + udc_start(); + NVIC_SetPriority(USB_IRQn, 1); //USB Should have lower priority than rtc + + //check if boot-protection is on + //(edbg does not write to boot-section if this is protected + //(bootprot can be manually changed to 0x07 in the "fuses" tab of Atmel tudio to reprogram) + + protect_boot_section(); //uncomment for release + + // set board LED initial status + + port_pin_set_output_level(LED_L_PIN,LED_L_INACTIVE); + port_pin_set_output_level(LED_TX_PIN,LED_TX_INACTIVE); + port_pin_set_output_level(LED_RX_PIN,LED_RX_INACTIVE); + + while (1) { + get_message();//STK500v2 + } +} + +void main_cdc_config(uint8_t port,usb_cdc_line_coding_t *cfg) +{ + if(cfg[port].dwDTERate == 1200) + { + //do nothing + } +} \ No newline at end of file diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/main.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/main.h new file mode 100755 index 0000000..3335fc4 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/main.h @@ -0,0 +1,51 @@ +/** + * \file + * + * \brief Main functions + * + * Copyright (c) 2009-2014 Atmel Corporation. All rights reserved. + * + * \asf_license_start + * + * \page License + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * 3. The name of Atmel may not be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * 4. This software may only be redistributed and used in connection with an + * Atmel microcontroller product. + * + * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE + * EXPRESSLY AND SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL 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. + * + * \asf_license_stop + * + */ + +#ifndef _MAIN_H_ +#define _MAIN_H_ + +#include "usb_protocol_cdc.h" + +void main_cdc_config(uint8_t port,usb_cdc_line_coding_t *cfg); + +#endif // _MAIN_H_ diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/stk500v2.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/stk500v2.h new file mode 100755 index 0000000..6e2f85e --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/stk500v2.h @@ -0,0 +1,403 @@ +/*---------- GNU PUBLIC LICENZE V3 ---------- +* +* Copyright Arduino srl (c) 2015 +* +* This file is part of Bootloader_D21. +* +* Bootloader_D21 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. +* +* bootloader_D21 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 Bootloader_D21. If not, see . +* +*/ + + +#ifndef STK500V2_H_ +#define STK500V2_H_ + +#include"command.h" +#define NVM_MEMORY ((volatile uint16_t *)FLASH_ADDR) +#define APP_START_ADDR (0x4000) +#define TIMOUT_PERIOD 8000 +volatile uint32_t timeout = 0; +volatile uint32_t current_address = APP_START_ADDR; +uint8_t GET_COMMAND_BYTE() +{ + port_pin_set_output_level(LED_RX_PIN,LED_RX_INACTIVE); // RX LED management + + while(!(usart_instance.hw->USART.INTFLAG.reg & SERCOM_USART_INTFLAG_RXC) && !udi_cdc_is_rx_ready()) + { + + } + + port_pin_set_output_level(LED_RX_PIN,LED_RX_ACTIVE); // RX LED management + if(usart_instance.hw->USART.INTFLAG.reg & SERCOM_USART_INTFLAG_RXC) + { + return usart_instance.hw->USART.DATA.reg; + } + return udi_cdc_multi_getc(0); +} + +void SEND_RESPONSE(char response) +{ + //if (!udi_cdc_is_tx_ready()) { + // /* Fifo full */ + // udi_cdc_signal_overrun(); + // ui_com_overflow();//not implemented yet + //} + + port_pin_set_output_level(LED_TX_PIN,LED_TX_INACTIVE); // TX LED management + //wait until usb or usart is ready + while(!(usart_instance.hw->USART.INTFLAG.reg & SERCOM_USART_INTFLAG_DRE) && !udi_cdc_is_tx_ready()) + { + + } + + port_pin_set_output_level(LED_TX_PIN,LED_TX_ACTIVE); // TX LED management + /*try to send over usart*/ + if(usart_instance.hw->USART.INTFLAG.reg & SERCOM_USART_INTFLAG_DRE) + { + usart_instance.hw->USART.DATA.reg = response; + /* Wait until data is sent */ + /*problem: need to time out in case only USB is used, this will only be a problem for the first byte, + after one timeout, INTFLAG_DRE will not be set if USART is not used*/ + for (uint32_t i = 0; i <= USART_TIMEOUT; i++) { + if ((usart_instance.hw->USART.INTFLAG.reg & SERCOM_USART_INTFLAG_TXC)) + break; + + } + } + // Mod for Tian compatibility + else + { + udi_cdc_putc(response); + } + return; +} + +void commit_page() +{ + /*if current row is not written fully, fill rest of row with zeros, on last write in page, + whole buffer is written (automatic writes are on)*/ + if(current_address >= APP_START_ADDR) + { + while(current_address%NVMCTRL_ROW_SIZE != 0) + { + NVM_MEMORY[current_address/2] = 0xffff; + current_address += 2; + } + /*wait until write operation is done*/ + while(!(NVMCTRL->INTFLAG.bit.READY)) + { + ; + } + } +} + + +/* DEFINES FOR DEVICE, pull out to header later TODOTODOTODO*/ +//signature for mega2560 +#define DEVICE_SIGNATURE 0x1E9801 +#define CONF_PARAM_BUILD_NUMBER_LOW 1 +#define CONF_PARAM_BUILD_NUMBER_HIGH 2 +#define CONF_PARAM_HW_VER 3 +#define CONF_PARAM_SW_MAJOR 4 +#define CONF_PARAM_SW_MINOR 5 + + +void handle_message(void); + +/* based on +http://www.atmel.com/images/doc2591.pdf +AVR068: STK500 communication protocol +*/ +#define MAX_MESSAGE_LENGTH 286 + +typedef enum +{ + STATE_START, + STATE_GET_SEQUENCE_NUMBER, + STATE_GET_MESSAGE_SIZE_1, + STATE_GET_MESSAGE_SIZE_2, + STATE_GET_TOKEN, + STATE_GET_DATA, + STATE_GET_CHECKSUM, + +} stk500v2_state; + +uint8_t message[MAX_MESSAGE_LENGTH]; +uint16_t message_length = 0; +uint8_t sequence_number = 0; + +uint8_t get_checksum(uint16_t current_byte_in_message, uint8_t *message_to_check) +{ + uint8_t checksum = 0; + for(uint16_t i = 0; i>((2-signature_index)*8))&0xFF; + return_message[3] = STATUS_CMD_OK; + break; + case CMD_GET_PARAMETER: + return_message_length = 3; + uint8_t parameter = message_body[1]; + return_message[1] = STATUS_CMD_OK; + switch(parameter) + { + case PARAM_BUILD_NUMBER_LOW: + return_message[2] = CONF_PARAM_BUILD_NUMBER_LOW; + break; + case PARAM_BUILD_NUMBER_HIGH: + return_message[2] = CONF_PARAM_BUILD_NUMBER_HIGH; + break; + case PARAM_HW_VER: + return_message[2] = CONF_PARAM_HW_VER; + break; + case PARAM_SW_MAJOR: + return_message[2] = CONF_PARAM_SW_MAJOR; + break; + case PARAM_SW_MINOR: + return_message[2] = CONF_PARAM_SW_MINOR; + break; + default: + return_message[2] = 0; + break; + } + break; + + case CMD_ENTER_PROGMODE_ISP: //Ignore this one for now + return_message_length = 2; + return_message[1] = STATUS_CMD_OK; + break; + case CMD_LEAVE_PROGMODE_ISP: + return_message_length = 2; + return_message[1] = STATUS_CMD_OK; + timeout = (TIMOUT_PERIOD - 500);//reset and enter main app after 500 ms + break; + case CMD_SET_PARAMETER: //Ignore this one for now + return_message_length = 2; + return_message[1] = STATUS_CMD_OK; + break; + case CMD_LOAD_ADDRESS: + current_address = (((message_body[1]<<24) | (message_body[2]<<16) | (message_body[3]<<8) | (message_body[4]))<<1);//shift left 1 to ignore msb and convert from word to byte +// current_address = current_address + APP_START_ADDR; + return_message_length = 2; + return_message[1] = STATUS_CMD_OK; + break; + case CMD_SPI_MULTI: //only partially implemented + switch(message_body[4]) + { + case 0x30: + return_message_length = 7; + return_message[1] = STATUS_CMD_OK; + return_message[2] = 0; + return_message[3] = message_body[4]; + return_message[4] = 0; + return_message[5] = (DEVICE_SIGNATURE>>((2-message_body[6])*8))&0xFF;; + return_message[6] = STATUS_CMD_OK; + break; + default: + return_message_length = 7; + return_message[1] = STATUS_CMD_OK; + return_message[2] = 0; + return_message[3] = message_body[4]; + return_message[4] = 0; + return_message[5] = 0; + return_message[6] = STATUS_CMD_OK; + break; + } + + break; + case CMD_CHIP_ERASE_ISP: + for (uint32_t current_flash_address = APP_START_ADDR; current_flash_address < NVMCTRL_FLASH_SIZE; current_flash_address += NVMCTRL_ROW_SIZE) + { + enum status_code error_code; + do + { + error_code = nvm_is_ready(); + NVMCTRL->STATUS.reg |= NVMCTRL_STATUS_MASK; + + /* Set address and command */ + NVMCTRL->ADDR.reg = (uintptr_t)&NVM_MEMORY[current_flash_address / 4]; + NVMCTRL->CTRLA.reg = NVMCTRL_CTRLA_CMD_ER | NVMCTRL_CTRLA_CMDEX_KEY; + } while (error_code == STATUS_BUSY); + } + return_message_length = 2; + return_message[1] = STATUS_CMD_OK; + break; + case CMD_PROGRAM_FLASH_ISP: + + bytes_to_read_or_write = (message_body[1]<<8) + message_body[2]; + if(current_address >= APP_START_ADDR) + { + uint32_t i; + for(i = 0; i= APP_START_ADDR) + { + uint32_t i; + for(i = 0; i>8; + } + //nvm_read_buffer(current_address, return_message+2, bytes_to_read_or_write); + } + else + { + for(uint32_t i = 0; i<(message_body[1]<<8) + message_body[2]; i++) + { + return_message[i+2] = 0xFFFF; + } + } + current_address += bytes_to_read_or_write; + return_message[return_message_length-1] = STATUS_CMD_OK; + break; + } + //send message back + uint8_t checksum = 0; + checksum ^= MESSAGE_START; + SEND_RESPONSE(MESSAGE_START); + checksum ^= sequence_number; + SEND_RESPONSE(sequence_number); + checksum ^= (return_message_length>>8)&0xFF; + SEND_RESPONSE((return_message_length>>8)&0xFF); + checksum ^= return_message_length&0xFF; + SEND_RESPONSE((return_message_length)&0xFF); + checksum ^= TOKEN; + SEND_RESPONSE(TOKEN); + for(uint16_t i = 0; i< return_message_length; i++) + { + SEND_RESPONSE(return_message[i]); + } + uint8_t body_checksum = get_checksum(return_message_length, return_message); + checksum ^= body_checksum; + SEND_RESPONSE(checksum); +} + + + +#endif /* STK500V2_H_ */ \ No newline at end of file diff --git a/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/usart_setup.h b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/usart_setup.h new file mode 100755 index 0000000..3fa2968 --- /dev/null +++ b/bootloaders/sofia/Bootloader_D21_Sofia_V2.1/src/usart_setup.h @@ -0,0 +1,46 @@ + + + +#ifndef USART_SETUP_H_ +#define USART_SETUP_H_ +/** \name Embedded debugger SOFIA SERCOM interface definitions +* @{ +*/ +#define EDBG_SOFIA_MODULE SERCOM5 +#define EDBG_SOFIA_SERCOM_MUX_SETTING USART_RX_3_TX_2_XCK_3//USART_RX_3_TX_2_XCK_3 +#define EDBG_SOFIA_SERCOM_PINMUX_PAD0 PINMUX_UNUSED +#define EDBG_SOFIA_SERCOM_PINMUX_PAD1 PINMUX_UNUSED +#define EDBG_SOFIA_SERCOM_PINMUX_PAD2 PINMUX_PB22D_SERCOM5_PAD2 +#define EDBG_SOFIA_SERCOM_PINMUX_PAD3 PINMUX_PB23D_SERCOM5_PAD3 +#define EDBG_SOFIA_SERCOM_DMAC_ID_TX SERCOM5_DMAC_ID_TX +#define EDBG_SOFIA_SERCOM_DMAC_ID_RX SERCOM5_DMAC_ID_RX +/** @} */ + + + + + + +struct usart_module usart_instance; +void configure_usart(void) +{ + struct usart_config config_usart; + usart_get_config_defaults(&config_usart); + //! [setup_change_config] + config_usart.baudrate = 57600; + config_usart.mux_setting = EDBG_SOFIA_SERCOM_MUX_SETTING; + config_usart.pinmux_pad0 = EDBG_SOFIA_SERCOM_PINMUX_PAD0; + config_usart.pinmux_pad1 = EDBG_SOFIA_SERCOM_PINMUX_PAD1; + config_usart.pinmux_pad2 = EDBG_SOFIA_SERCOM_PINMUX_PAD2; + config_usart.pinmux_pad3 = EDBG_SOFIA_SERCOM_PINMUX_PAD3; + //config_usart.start_frame_detection_enable = true; + //! [setup_change_config] + while (usart_init(&usart_instance, SERCOM5, &config_usart) != STATUS_OK) { + + } + usart_enable(&usart_instance); +} + +#endif /* USART_SETUP_H_ */ + + diff --git a/bootloaders/sofia/Sofia_Tian_151118.hex b/bootloaders/sofia/Sofia_Tian_151118.hex new file mode 100644 index 0000000..eacd894 --- /dev/null +++ b/bootloaders/sofia/Sofia_Tian_151118.hex @@ -0,0 +1,970 @@ +:10000000282C002075300000713000007130000095 +:1000100000000000000000000000000000000000E0 +:10002000000000000000000000000000713000002F +:10003000000000000000000071300000713000007E +:10004000713000007130000071300000A514000014 +:100050007130000071300000713000007D2500001B +:1000600071300000E10F0000F10F000001100000EE +:10007000111000002110000031100000713000004C +:1000800071300000713000007130000071300000EC +:1000900071300000713000007130000071300000DC +:1000A00071300000713000007130000071300000CC +:1000B00010B5064C2378002B07D1054B002B02D03E +:1000C000044800E000BF0123237010BD1C01002084 +:1000D000000000005C3B000008B5084B002B03D07B +:1000E0000748084900E000BF07480368002B03D019 +:1000F000064B002B00D0984708BDC046000000000A +:100100005C3B0000200100205C3B00000000000080 +:10011000EFF3108072B6BFF35F8F034B00221A70AB +:10012000434258417047C04614010020024B1A78E0 +:10013000013AD2B21A707047C8030020044B1A78F3 +:10014000013AD2B21A701B78024B00221A70704723 +:1001500042010020CE03002000207047002070479D +:1001600010B50F4B0F4C0020207018800E4BA122B1 +:100170001A7020225A7002220C4958809880DA8026 +:100180001881E1235B020B600823087148718B71B1 +:10019000074B9847237801200133DBB2237010BD51 +:1001A00066060020C8030020D80300203801002084 +:1001B000A938000008B500200149024B984708BD46 +:1001C00038010020A9380000002805D0034B012287 +:1001D0001A70BFF35F8F62B67047C04614010020EB +:1001E000124B60211A7850B20A40002809DA002028 +:1001F000202A1AD15A78212A17D1DA88072A14D14D +:100200000FE00020202A10D15A78202A04D0101C98 +:1002100022384242504108E0DA88072A05D10449D1 +:10022000196104499A81996001207047880900206A +:10023000B501000038010020F7B5364B1A78002AC6 +:1002400066D1354CA047354D2C8800280FD0344B53 +:10025000984784425CD0334B9847334A334B1478E9 +:10026000071CE4B26100C95A002919D101E0304BE2 +:10027000EEE7304E28493388013333808847002821 +:1002800006D13388632B03D8381C2B4B98473FE0AB +:10029000214A9047002803D03288284B9A42F3D94C +:1002A000244B00221A80264B1B78934205D16342CF +:1002B00063411D49DBB20B7002E063425C41E4B272 +:1002C000144A01231370381C1B4B9847174B6700C7 +:1002D000DE5B413EFF3E731E9E41F6B2002E09D00A +:1002E0000D498847002801D00D4B00E0104B98477E +:1002F000288000E02E800D49A20124021419CB5B56 +:10030000104A1149121900918120311C0F4CA0474D +:10031000F7BDC046D4030020FD1A0000CC03002026 +:10032000111B0000110100004301002044010020C6 +:10033000011B000040010020C90100001F03000054 +:1003400065060020480100205D0300008D1D0000AF +:1003500008B5014B984708BD3902000008B50028D0 +:100360000CD1074B1A7853425A41064B5200D052D7 +:10037000054B1870054B1870054B984708BDC046D3 +:10038000430100204401002065060020D403002022 +:100390003902000010B5074B9847074A074B1B88E6 +:1003A0001178074A49008C5AE41A064B9847201CDA +:1003B00010BDC04611010000CF030020CA03002079 +:1003C000D0030020C901000008B5034B9847431E25 +:1003D0009841C0B208BDC04695030000F0B5194B66 +:1003E00085B098471849194A0C781578E4B2EDB2EF +:1003F000002D08D1164E670033880393154BFB5A26 +:10040000039FBB4203D9144B9847002018E0358066 +:1004100066426641F6B20E700F4F01261670B8475D +:100420000E4B281C9847A2010D4B240214190D4AAB +:100430000093A02312190220311CB3400A4CA0479C +:1004400005B0F0BD11010000CF03002064060020BC +:10045000CA030020D0030020C9010000C903000026 +:10046000F1040000E40300208D1D000038B5134B9B +:10047000134D00242C701C70124B1C70124B1C70FE +:10048000124B1C805C80124B1C80124B9847124B05 +:100490001C70124B1C70124B1C80124B1C80124B98 +:1004A0009847A04209D02B780133DBB22B702B7810 +:1004B000DBB2012B01D10D4A137038BDD4030020EB +:1004C0004201002065060020430100204401002075 +:1004D000CC0300203902000064060020CF03002076 +:1004E000D0030020CA030020DD030000CE0300205B +:1004F00013B500281CD10F4B1B785C426341DBB263 +:1005000000290ED199011B02CB180B49101CCB18E6 +:100510000A491A1C0091A02301218B40084CA047D6 +:1005200006E0084A5B009952074B1870074B984742 +:1005300013BDC046CF030020E4030020F1040000F7 +:100540008D1D0000D003002064060020DD030000A4 +:1005500008B50020014B984708BDC046C9030000FC +:10056000F7B5194B00269B79093B5A425341DBB240 +:100570000193164B9847164B164F3C881D78164B27 +:100580009847EDB2154B6A00D35AA4B2A34205D8DE +:10059000134B1878C0B20028EBD113E0AB012D0249 +:1005A0005D19104B2D19EB5C01341E43A4B20E4BA8 +:1005B0003C809847019B002B03D000233602019317 +:1005C000D7E7301CFEBDC0463801002011010000F5 +:1005D000CF030020CA030020C9010000D00300207F +:1005E000CE030020E4030020DD03000038B5114BEA +:1005F0009847114A114B1178C9B24C00E45AA02314 +:100600005B009C420FD10E4B1B78002B0BD10D4D84 +:100610002B78DBB2002B06D101242C704C426141B7 +:10062000C9B211701C1C084B9847A0204000001B49 +:1006300038BDC046110100004301002044010020E4 +:10064000D403002065060020C901000008B5034B53 +:100650009847431E9841C0B208BDC046ED05000052 +:1006600008B50020014B984708BDC0464D06000064 +:10067000F8B5154B0C1C9D79093D6B425D41EDB2FF +:100680000020124B9847002805D1114B1878C0B2B2 +:100690000028F5D117E00F4B98470F4B0F491B78F7 +:1006A000DBB25E00725A571C775299011B02CB18BD +:1006B0000B499A180B4B54549847002D02D0241222 +:1006C0000025DDE70120F8BD380100204D060000BF +:1006D000CE0300201101000043010020440100204E +:1006E00048010020C901000008B5011C014B002091 +:1006F000984708BD7106000008B5034B58887F2352 +:100700001840024B984708BD880900200D1F0000C3 +:1007100030B5144B1A7800239A4221D0124B1B6833 +:100720001B681A79824201D8002319E00F4A13602E +:10073000DC789D7824022C431C199C420ED95D78EC +:10074000042D08D19D78854205D1DD788D4202D1F6 +:100750001360012304E01D785B19EEE71360E3E703 +:10076000181C30BD710600206806002074060020A9 +:10077000094B1B681B68DA78997812020A439B18A8 +:1007800002788018834205D94278042A02D0052ACB +:10079000F6D100E0002070476806002038B5104B05 +:1007A000051C9847002801D1002018E00D4B1C685B +:1007B000201C0D4B9847041E0AD06279237912023F +:1007C0001A438078E178094B98470028F0D1EBE78D +:1007D000074BAD001B685B68EB581B68984738BD3A +:1007E000110700007406002071070000751B00004F +:1007F00068060020F8B500210F4F051CB847041EFD +:1008000018D00E4BAA001B685B68D658F36898474F +:10081000011C281CB847041E0CD0094B1D68281C5D +:10082000084B9847051E03D08078074B9847F6E79A +:1008300073689847201CF8BD110700006806002067 +:100840007406002071070000211B000008B5014B51 +:10085000984708BDD91F000038B50C4B00241A7802 +:100860001D1CA24205D100232B70094B01221A80C6 +:1008700038BD084B1B681B681B79A342F3D9201CA9 +:10088000054B01349847E4B2F3E7C04671060020F7 +:100890006E06002068060020F507000008B5024B30 +:1008A0009847024B984708BD3D20000059080000BA +:1008B00010B50B4B00241B78A3420FD0094B1B68CB +:1008C00019680A79A24209D95B68A200D3581B694A +:1008D000002B00D098470134E4B2EFE710BDC046CA +:1008E0007106002068060020F8B5A44C0023A381FF +:1008F00023616361237858B2002803DAE288002A72 +:1009000000D1B2E16021194000D065E11F2200282A +:1009100000DBA9E0E588002D00D15DE1134067D13F +:100920006378062B09D0082B5DD0002B00D053E153 +:10093000022D00D050E1924892E06088050A022D15 +:100940000CD006D8012D00D046E18E4B18680178F6 +:1009500040E0032D1FD00F2D13D03DE1894BC0B2D5 +:1009600019684A7C824200D836E15B68C000C058F2 +:10097000C178837809021943834B9847A268557060 +:100980002AE0804B9868002800D125E1C17883785F +:10099000090219431EE0C0B2032800D91CE102F08D +:1009A0008FFF070004000A0061011D21774A04E05F +:1009B000774804210EE0774A0C21002376485D0039 +:1009C000D65C451901336E80DDB28D42F6D3490005 +:1009D000023101706C4B9847E388A2899A4200D893 +:1009E000CAE0A381C8E0012D00D0F5E06B4837E0F4 +:1009F000012B25D163780A2B00D0EDE0012D00D02A +:100A0000EAE0664B1B78002B00D1E5E0644B2679C9 +:100A10001F683A681379B34200D8DDE0301C614B9F +:100A20009847051E00D1D7E07B68B600F358DB6815 +:100A300098475D4B01211870181C534B984799E05B +:100A4000022B00D0C8E06378002B00D0C4E0022D58 +:100A500000D0C1E0554B20799847554B1880181CA1 +:100A6000291C494B984787E013404DD160780138E5 +:100A7000082800D9B0E002F019FF0CAFAFAF05AF06 +:100A8000AFAF1A00E388002B00D0A5E0494B2361EB +:100A900072E0E388002B00D09EE06388012B00D039 +:100AA0009AE0374B02211A888A431A8064E0E5886D +:100AB000002D00D090E0404B9847002800D18BE0FB +:100AC000304EA27831684B7C9A4200DD84E03B4B8B +:100AD0009847A378314A1370002B4DD03849304ADB +:100AE0005B187168DB00CB181360161C33681B6839 +:100AF0001B79AB4240D9281C0021324B9847002873 +:100B00006AD00135EDB2F1E7012B15D163780B2BDB +:100B100062D1E388002B5FD1204B1B78002B5BD088 +:100B20002579294B281C66889847002854D0F1B2B3 +:100B3000281C244B98471CE0022B4DD16378012BD5 +:100B400002D0032B09D047E0E388002B44D163880F +:100B5000002B41D120791D4B0AE0E388002B3BD1CB +:100B60006388002B38D12079194B98472079194B8D +:100B70009847051C002D2FD0012077E08809002020 +:100B80006E060020A00000202D1F00003500002070 +:100B90009000002028000020540000207106002052 +:100BA000680600201107000070060020411C0000AC +:100BB0006C060020F90600001D1F00005908000007 +:100BC000FFFFFF1F9D070000F5070000511D0000FB +:100BD000C11A0000551C000022781F231340012B6E +:100BE0001ED1234B1B78002B1AD0224B25791E686F +:100BF00032681379AB4213D9281C00211E4FB84725 +:100C000000280DD07368AA00D658F3689847011CD5 +:100C1000281CB847002803D0B36898470028ABD1F8 +:100C200022781F231340022B1FD1114B00241B7865 +:100C3000002B1AD00F4B1B6819680A79A24214D9ED +:100C40005B68A200D558E96888470B4B011C201C43 +:100C50009847002809D0AB68984700288CD1013408 +:100C6000E4B2E7E70421054AA7E60020F8BDC04644 +:100C7000710600206806002011070000FE3A0000FF +:100C800010B54908402488420CD800235C1C091A7E +:100C9000A4B2814201D3231CF8E74024FF2B01D8E2 +:100CA00013800024201C10BDF0B58BB01C1C10ABB1 +:100CB000071C187807923A1C42430D1C40238A42B5 +:100CC00000D98FE0002C3DD1211C3A1C231C4A4E38 +:100CD000B04706900020002102950F1C0D1C3F21FB +:100CE0000394061C041C0591059A444B0120002125 +:100CF0009847221C2B1C8446069812196B41141C21 +:100D00001D1C084203D001222243141C1D1C039AFF +:100D1000AA420CD802D1029BA34208D860463043B5 +:100D20003943029A039B061CA41A9D410F1C059B84 +:100D3000013B0593D8D22F4B2D4A921BBB41160C79 +:100D40001B044BE00026012C49D1490FED0008910E +:100D50000995311C3A1C331C274CA0470290039183 +:100D6000F7B20697002705973F2700240025019733 +:100D7000019A224B012000219847099F221C07401D +:100D8000BC46089F2B1C12196B4139406746141C46 +:100D90001D1C394303D001222243141C1D1C03993E +:100DA000A9420AD802D1029AA24206D8059F029906 +:100DB000039A0743641A95410597019F013F0197E4 +:100DC000D6D2059F0E4ABB1BDB08934204D90136DD +:100DD000082EC5D1402305E0069F7E031E43079FD2 +:100DE00000233E80181C0BB0F0BDC046C046C04674 +:100DF00000000000010000004D3A0000353A0000FC +:100E0000FF1F0000C046C04637B50E4B041C1A78C1 +:100E10001D1C002A01D000290CD001A913200A4B67 +:100E20000C7098471320094B984701236C702B7066 +:100E3000002006E05A781D20141B621E9441644273 +:100E400020403EBD780600204D2F0000C52E00003A +:100E50003A4A031C00B5081C93422BD006D8384AE6 +:100E600093420DD0374A934217D057E0364A934207 +:100E70003AD0364A934244D0354A93424ED126E086 +:100E80000023032957D802F011FD024B0406314B11 +:100E900051E0314B4FE0314B4DE0002303294AD85C +:100EA00002F004FD02400406032344E02C4B42E020 +:100EB0002C4B40E0002303293DD802F0F7FC02351B +:100EC0000406294B37E0294B35E0294B33E000235A +:100ED000032930D802F0EAFC022A0406254B2AE056 +:100EE000254B28E0254B26E00023032923D802F0D8 +:100EF000DDFC021F0406224B1DE0224B1BE0224BAF +:100F000019E00023032916D802F0D0FC02140406CD +:100F10001E4B10E01E4B0EE01E4B0CE000230AE0BF +:100F20001D4B08E01D4B06E01D4B04E01D4B02E08D +:100F30001D4B00E01D4B181C00BDC04600100042B8 +:100F400000080042000C004200180042001C004251 +:100F50000014004203000400030006000300070021 +:100F600003001E0003001F000300080003000A0026 +:100F700003000B0003001000030012000300130025 +:100F800003000C0003000E0003000F000300160016 +:100F9000030018000300190003000500030001000E +:100FA000030009000300110003000D0003001700F7 +:100FB00070B50A4986B06B4670C970C36A4670C97D +:100FC00070C3002399005158884201D1D8B203E080 +:100FD0000133062BF6D1002006B070BD043B0000A3 +:100FE00008B5024B00201B68984708BD7C0600200E +:100FF00008B5024B01205B68984708BD7C060020BD +:1010000008B5024B02209B68984708BD7C0600206B +:1010100008B5024B0320DB68984708BD7C0600201A +:1010200008B5024B04201B69984708BD7C060020C8 +:1010300008B5024B05205B69984708BD7C06002077 +:101040000268D369002BFCD170470000F0B593B063 +:10105000039001608C4F081C0691141CB847069F32 +:1010600001263B680527334200D009E1069F022391 +:101070003D681C271D4000D002E1844B821C371CB8 +:10108000196A97403A1C271C0A432D371A620497A5 +:101090003B78071C14370CA9FFB20B70381C7C4B33 +:1010A0009847381C7B4B9847049F291C38787A4B0B +:1010B0009847E37A039F7B71631DDB7FBB71A31DA0 +:1010C000DB7FFB71E37E3B72237F7B723F6805977A +:1010D000381C6D4FB8470EAB1D80278A8023143013 +:1010E0000497DB019F4211D005D880239B019F42CA +:1010F00011D110270DE0049FC023DB019F4207D0D0 +:1011000080231B029F4206D1032706E0082704E044 +:101110000827351C01E0102700252268E3680792A4 +:10112000626908930992237E62680A93E31DDB7F5C +:101130000B93231C0833002A10D0802149058A42D2 +:1011400020D1DB7F002B1DD1544BC0B2256A9847BC +:101150000EAA011C524B281C984711E0DB7F266A1F +:10116000002B03D00097301CA16A05E0C0B24B4BA6 +:1011700098470097011C301C2B1C0EAA494DA8470C +:10118000071E7DD1637E002B02D0A37E059FBB731B +:101190000398454FB8470EAB1B88059A089D93816D +:1011A000079B099A1D4363681543049A1D43154321 +:1011B0000A9A13020B9A1D4353071D43231C08333D +:1011C000DB7F002B01D104231D43667E237FB60203 +:1011D0005B021E43E27AA37A13431E43637F228994 +:1011E0001B021E43631DDB7F5B041E43A31DDB7FCD +:1011F0001B041E43E37EFF2A06D0002B02D0A0234F +:10120000DB041D43164304E0002B02D08023DB04E3 +:101210001D43231C2C331B78002B03D1234B9B78BD +:101220009A0701D580231D430398B847059B03986F +:101230005E60B847059F80233D60226B0DAD2B702B +:101240000E92636BA26BE46B00270EAEF4606F70BE +:10125000EF70AF707360B2603C1CA300F058E1B255 +:10126000002802D10698124B9847431C05D02870DD +:10127000000CC0B2291C0F4B98470134042CECD150 +:10128000381C13B0F0BDC046B10F00000004004090 +:101290004D2F0000C52E0000090E0000692F000030 +:1012A000810C0000A90C000041100000002000414A +:1012B000510E00001D3000000368987AC009704785 +:1012C00070B50C4B08220568041CDA67201C0A4E16 +:1012D000B0470028FAD12B88022293432B80207537 +:1012E0006075201CB0470028FBD12B8801221343D6 +:1012F0002B8070BD04E100E0B9120000F8B506686B +:10130000071C0D1C141C381C0F4B98470028FAD1E1 +:101310003A79002A0AD01A23012A12D11723012C64 +:101320000FD80634A400A551031C0AE01723022C91 +:1013300007D806498D4204D80C34ADB26400A553D9 +:10134000131C181CF8BDC046B9120000FFFF0000B6 +:10135000F7B52D4B0160151C9A6920210A439A614B +:1013600001A90223041C0B700420284B9847042079 +:10137000274B9847274B201C9847AB7823712B7934 +:101380006371254B1C602B8826683380AB78002B5B +:1013900016D01720012B36D133889BB23380EB78DF +:1013A000002B03D03388802213433380201C1B4B37 +:1013B0009847021EFAD1201CA968194B984719E0DA +:1013C0003388042213433380EB781720002B1AD183 +:1013D000201C124FB847021EFAD1201CA968104FDA +:1013E000B847201C0D4B98470028FAD1201CE9680B +:1013F0000122B8472B790020834204D072888023D1 +:10140000DB0113437380FEBD000400404D2F00003C +:10141000C52E0000C11200005C070020B9120000B8 +:10142000FD12000070B50379041C05680E1C152020 +:10143000002B05D1201C034B98470028FAD1AE821F +:1014400070BDC046B9120000031C022A0CD00079FE +:10145000002805D0012805D11720012A0FD803E064 +:10146000022A01D917200AE0901C8000C1500120F7 +:10147000197D9040021C0A43D2B21A7500207047B1 +:1014800010B503688022022903D001228A40032478 +:101490002240DA710122437D8A40111C1943C9B2EE +:1014A000417510BD38B5114B1B68597D1C681A7DFC +:1014B000207A0A40E1790140C80906D0510701D5D8 +:1014C0001B699847802323720EE00125294203D02F +:1014D0002A4208D09B6805E00225294204D02A420E +:1014E00001D0DB689847257238BDC0465C070020F4 +:1014F000EFF3108072B6BFF35F8F034B00221A70B8 +:10150000434258417047C046140100200F23034056 +:101510005B00C0091818023814235843014B1818EF +:101520007047C04698060020F0B58E7985B072B23B +:101530000D1C544B301C002A46DA98470F273740C1 +:101540000197028AC36802926D88041CED188368B3 +:10155000C560877C9D4221D05E1B4B4AB6B2964245 +:1015600006D94A4B101C02999847474B5E1AB6B2EF +:101570000023BA0706D5464B301C029998478BB218 +:101580005A4253415A00A37C02218B4313436268A1 +:10159000A37452193F480199331C0AE0B807C00FE1 +:1015A0000AD0022362689F433A480199A7745219EE +:1015B0000023394CA04763E001239F432368A774AD +:1015C000002B5DD0291C59E098470F23334002932C +:1015D000038A041C0193837C2F885A0710D5C268A4 +:1015E000436801999B1803938068294B98470A1C0C +:1015F00002992A4B01398901C9180398284B984749 +:10160000E368FA18A368E2609A4200D9E360AA8806 +:10161000BA422AD1E5689D4227D05E1B1A4FB6B266 +:10162000BE4206D9381C194B019998477F1ABBB2A4 +:1016300005E0301C164B01999847761AB3B2019A0F +:101640001448184E93420BD2A37C04221343029AEF +:10165000A374013A114B9201D2180299019B02E046 +:10166000626802995219B0470AE0A37C01229343B1 +:10167000A3742368002B03D0E1680020321C984734 +:1016800005B0F0BD0D150000FF1F00001D3A000061 +:101690005D39000020080020A5240000600700201C +:1016A000DD3A0000F124000010B5064B064C05227F +:1016B0001A70201C8021054B9847201C0021044BE8 +:1016C000984710BD13070020200800202B2400009D +:1016D0004524000037B51E4B041C9847226801AD15 +:1016E00080239372281C1B4B984703236B70291C83 +:1016F000201C194B9847201C1849194B9847194D25 +:10170000201C00210222184BA84700210A1C201C83 +:10171000164BA847164B201C00210122A847154D47 +:10172000201C00210222A84700210A1C201CA847D7 +:10173000201C00210122A84723680F4A19890A406A +:101740008021C9000A431A810C4B00221A7037BD50 +:10175000590800004922000059220000A009002079 +:1017600039250000E1200000CD180000811C000098 +:10177000BD17000031210000FFF3FFFF1307002019 +:1017800010B5084B084C03221A70201C0749084B5F +:101790009847084B00219A68201C0B1C064CA04758 +:1017A00010BDC0461307002020080020A00900201B +:1017B0003925000088090020A524000008B5897992 +:1017C0000C4B4AB2002A08DA1B78012B02D10A4BD3 +:1017D00098470DE0042B0BD107E01A78022A02D1BA +:1017E00004221A7004E0032A02D10448044B9847EB +:1017F00008BDC04613070020811700002008002004 +:101800002B240000F8B51D4D1D4E2B88B4891D4FAB +:10181000E41AA4B2002C1BD11B4A11885B189BB29E +:101820001380F2889A4203D0184B1B78002B07D004 +:10183000174B04221A70381C1649174B98471CE0A6 +:101840007369002B0BD09847002808D02C80B489EE +:101850003F2C04D90D4B00221A70402402E00B4BA0 +:1018600001221A702B88B268381CD2180021231C60 +:101870000A4EB0472B88E4182C80F8BD10070020D2 +:10188000880900202008002094060020140700206A +:1018900013070020A009002039250000A52400001E +:1018A00008B5014B984708BDB1080000064B9A8C5B +:1018B000910605D4D968D0220A40D02AFAD102E094 +:1018C000DA68D106FCD570470008004070B5274E95 +:1018D0000C1C3378002B06D0254B1B69002B00D045 +:1018E0009847002333702388082B01D0214B2DE02B +:1018F000214C1F4D23782B7063786B70E378A278AE +:101900001B02D3186B80637922791B02D318AB803A +:10191000E379A2791B02D318EB80184B9847002873 +:10192000E4D02B787F2B0DD9154B00211980154B56 +:10193000221C19800223337013484023134CA04704 +:10194000134B03E0EB88002B02D1124B98470BE0BE +:101950000B4B002119800B4B221C19800123337083 +:1019600009484023094CA04770BDC046130700201A +:1019700088090020A9160000A0090020E90800003D +:10198000940600201007002020080020F124000009 +:101990000518000081170000002805D0034B012224 +:1019A0001A70BFF35F8F62B67047C0461401002003 +:1019B000F7B501AE114B041C1149301C04229847A5 +:1019C000104B1D78A54217D0002C08D00E4B375D68 +:1019D00098470E4BDA5D0132DA550D4B9847002DD2 +:1019E00008D0094B755D9847084B5A5D013A5A5526 +:1019F000074B9847034B1C70F7BDC046DD3A00000B +:101A0000243B000012070020F114000054070020BE +:101A10009919000038B5084C084D201C0621A8472C +:101A2000201C0421A8470221201C054B98470220B6 +:101A3000044B984738BDC04620080020C520000050 +:101A4000A5200000B119000038B50B4B98470B4C8E +:101A50000B4B201C022198470A4D201C0421A8474B +:101A6000094A0A4B201C062198470621201CA8473A +:101A70000320074B984738BDAD1800002008002010 +:101A8000C5200000A5200000151A000085200000D8 +:101A9000B119000010B5064C0421201C054B9847D5 +:101AA0000221201C044B98470120044B984710BD8D +:101AB00020080020C5200000A5200000B11900006A +:101AC00038B5041C211C0A480A4B98470A4B201CB5 +:101AD0009847827C031CD10708D501201D688243EA +:101AE0009A74002D02D0D968221CA84738BDC04680 +:101AF00020080020E12300000D15000000207047A1 +:101B0000024B1B68188A8004400D70472008002093 +:101B1000024B1B68188A80B27047C046200800201C +:101B2000F7B501AD041C0D4B281C9847201C0C4B2D +:101B300098470C4F0026291C381C0B4BEE702C705C +:101B400098470F21321C2140381C084B9847381CFD +:101B5000321C211C064B9847F7BDC04649220000A5 +:101B6000C11A0000200800205922000009210000AD +:101B7000BD210000F7B501AC061C294B201C0F1C31 +:101B8000151C984726700023082D1DD90123102D00 +:101B90001AD90223202D17D90323402D14D9042349 +:101BA000802D11D980235B009D4201D805230BE0D5 +:101BB00080239B009D4201D8062305E0194B9D42DE +:101BC00001D900202AE007236370301C164B984788 +:101BD0000323391C05821940012901D1022304E0A5 +:101BE000022902D00329ECD10423104DE370211CFB +:101BF000281C0F4B9847041EE3D10F21221C0D4BCC +:101C00003140281C0C4FB847221C311C0B4C281C9F +:101C1000A047281C311C0122A0470120FEBDC04660 +:101C200049220000FF0300000D15000020080020DD +:101C30005922000029150000E12000003121000098 +:101C400008B5011C014B0248984708BD0D2400004F +:101C5000200800200F2310B50340041C0020032B94 +:101C600007D80448211C044B9847201C034B984775 +:101C7000012010BD200800202B240000C11A000004 +:101C8000F8B5284E3378012B3FD1274A274C0D88D1 +:101C90001788A3897A19934201DADD1BADB2A368D4 +:101CA0002349D8192A1C234BEF199847BBB21E4F62 +:101CB0003B80402D05D1204DE1882A88D2189142E1 +:101CC00008DCA3816369002B02D0984700280AD062 +:101CD0001A4B1DE0A2899A4210D16069002802D0F7 +:101CE0008047002804D105233370154B984718E02E +:101CF0003A882B88D3182B8000233B8000210C4A84 +:101D00004023104C1048A0470BE0022B02D10F4B90 +:101D1000984706E0054B1B69002B00D0984700232D +:101D20003370F8BD13070020100700208809002039 +:101D3000A0090020DD3A0000940600208117000071 +:101D4000551C0000F12400002008002005180000A8 +:101D50000F2370B50340061C0024032B0ED8084B3C +:101D60009847084B051C311C07489847AB7C012459 +:101D7000DA0703D5A343AB742B689847201C70BDCA +:101D80000D1500004524000020080020F0B51E1CA1 +:101D90000F2385B00340071C029103920193032B8C +:101DA00001D9002596E04D4B9847051EF9D14C4BC3 +:101DB000381C98474B4B041C9847A27CD10702D58E +:101DC000494B984786E001231A43A274002804D0A7 +:101DD000464A1370BFF35F8F62B60023E3600A9B2D +:101DE000039A0298A17C23600123626018400222BA +:101DF00098409143014304208143A17479B2A660C5 +:101E0000002930DA002E1AD0394DB6B2AE4205D9CB +:101E1000218A281C374B98476E1AB6B202990023C4 +:101E2000994206D0344B218A301C98478BB25A42D3 +:101E300053415A00A37C02218B43134304E00299CF +:101E4000002909D0A37C9343A3740199039A331CFE +:101E50002A4C2B48A0473AE0A27C9A43A2740A9AE3 +:101E6000002A08D10CE0002E0CD1A27C0A999A43DA +:101E7000A274002904D00020011C3A1C0A9B984738 +:101E8000012527E01A4FB6B2258ABE4206D9381C72 +:101E9000184B291C98477F1ABBB205E0301C164B23 +:101EA000291C9847761AB3B21548164EAB420BD28E +:101EB000A37C04221343019AA374013A124B9201AA +:101EC000D21801992B1C01E00199039AB0474542B1 +:101ED0004541EDB2281C05B0F0BDC046411C0000D4 +:101EE0000D150000F11400009919000014010020E4 +:101EF000FF1F00001D3A00005D390000A52400000E +:101F000020080020F124000060070020024B8022FE +:101F10001B6810439872704720080020024B1B6812 +:101F2000987A7F231840704720080020014B986062 +:101F3000998170478809002008B5044B01201B686F +:101F40001A8902431A81024B984708BD20080020D5 +:101F5000B1190000F8B50320164B9847164C01271D +:101F60002368164E1A89201CBA431A810421144A88 +:101F7000B047201C0021134AB047391C201C124ACC +:101F8000B047124A201C0221B047114D201C0421E9 +:101F9000A847201C0021A847391C201CA847201C4A +:101FA0000221A8470B4A201C0621B047201C06210D +:101FB000A847F8BDB11900002008002085200000C6 +:101FC000951A0000A1180000D5160000491A00005B +:101FD000A5200000151A000073B50E4B984701AC00 +:101FE000061C0D4B201C98470C4D00230C49221C4D +:101FF000A370281C0B4B9847281C0B4B98470B4B86 +:10200000984701200A4B98470A4B9847301C0A4BC7 +:10201000984773BDF11400008D27000020080020B0 +:10202000005000419D27000069250000AD18000008 +:10203000B1190000551F00009919000010B5074B99 +:1020400098470020064B9847064B9847064B041CC0 +:102050009847201C054B984710BDC046391F00000B +:10206000B1190000F114000071200000991900005E +:10207000034B1A78002A01D000221A707047C0461C +:10208000150700200B1C2E339B001A50044AAA236C +:102090005B004900895AC25A0A43C2520020704765 +:1020A000283B0000064B49000268CB5A9383AB22C1 +:1020B0005200815A194381520268002013837047ED +:1020C000283B0000054BAB2252004900CB5A815AF5 +:1020D000994381520268002093827047283B000098 +:1020E00010B58C00A4183434A4000419411863609E +:1020F0005931044BFF3108789B5C03430B7000207F +:1021000010BDC046363B000010B58C00A418031C5F +:1021100034345B18A400041904490020593360606A +:10212000FF33895C1A788A431A7010BD363B000071 +:1021300070B50F230B40C41861341F4DFF3426784F +:10214000AD5C35432570002A0ED10268002B02D108 +:10215000FF3203230FE05B01D31849B2FF330222A1 +:10216000002926DB012224E0012A0FD10268002B7E +:1021700003D1FF320C2393721CE05B01D31849B2E8 +:10218000FF330822002914DB042212E0022A05D1C1 +:1021900002685B01D318FF3310220AE0032A09D139 +:1021A00002685B01D31849B2FF334022002900DBEB +:1021B00020229A72002070BD363B000070B50F23BC +:1021C0000B40C4181F4D6134FF34AE5C2578B54315 +:1021D0002570002A0ED10268002B02D1FF320323A2 +:1021E0000FE05B01D31849B2FF330222002926DB3E +:1021F000012224E0012A0FD10268002B03D1FF3213 +:102200000C2353721CE05B01D31849B2FF33082240 +:10221000002914DB042212E0022A05D102685B01C6 +:10222000D318FF3310220AE0032A09D102685B01A8 +:10223000D31849B2FF334022002900DB20225A7212 +:10224000002070BD363B0000002303704370837094 +:102250000123C37070470000F0B5021C0D78C878E8 +:102260000F232B40ED09042800D998E0146801F0F1 +:102270001DFB0308495D7A0008335B010020E05430 +:10228000A9E05D016419FF3466781C20770700D04F +:10229000A1E067787026374200D09CE01120607082 +:1022A000146808335B01E018402444711268D318A5 +:1022B00080221A718A78484B002A08D05A1954682B +:1022C00080200006044354605469204307E05A19F3 +:1022D000506840004008506050694000400850611C +:1022E0005D194C78686807223C4B1440184024075D +:1022F0002043686049780A40696912070B4013431C +:102300006B6162E058012418FF34002D07D0677814 +:1023100070261C2037425ED16078202612E0667855 +:102320001C20770757D1607802262FE05801241827 +:10233000FF34002D10D0677870261C2037424AD118 +:10234000607830263043607010681A1C08325201E1 +:1023500082188020107122E066781C2077073AD11D +:102360006078032612E058012418FF34002D07D0AE +:10237000677870261C2037422DD160784026E1E72F +:1023800066781C20770726D1607804263043607079 +:1023900010681A1C083252018218402050715B00EC +:1023A0005D190D4B48782D015B19072210405C68C0 +:1023B0000A4A0007224002435A608878002806D063 +:1023C0005968802212060A435A60002003E05A68C6 +:1023D000520052085A60F0BDE0090020FFFFFF8F55 +:1023E0000F230B40026808335B0149B2D218002961 +:1023F00005DA802111710268D318022204E040211D +:1024000051710268D3180122DA7170470F220A4015 +:102410000368083252019B1849B29879002901DA01 +:10242000800600E0C006C00F70470F220A40036814 +:102430000832520149B29B182022002900DB1022E9 +:102440005A71704730B50F220A404CB201685301EF +:10245000C918FF31CD79002C11DA2024254220D073 +:102460004C710168CB18FF331C7A40210C4218D004 +:1024700019720368083252019A18022310E01024DE +:1024800025420ED04C710168CB18FF331C7A2021F5 +:102490000C4206D019720368083252019A180123BF +:1024A000137130BD70B50D1C046808356D012E5DCB +:1024B0001C247606760F14D00B4C490161180A6172 +:1024C0000C1C0A4A49690A4062619A046369920CC9 +:1024D0009B0B9B0313436361036800245D198023F6 +:1024E0006B71201C70BDC046E0090020FF3F00F06A +:1024F000F0B50D1C046808356D012E5D1C247707AE +:1025000013D00B4C49010A5161184C689A04094BCD +:102510001209234013434B604B6800249B0B9B0321 +:102520004B6003685D1940232B71201CF0BDC04631 +:10253000E0090020FF3F00F0094B0A4A1960596882 +:102540000A40802189020A435A605A68920B92031A +:102550005A6003684022FF3300205A717047C0461A +:10256000E0090020FF3F00F0036802211A780A43C7 +:102570001A7002689378022BFCD07047F0B57E4C3D +:1025800085B0206802681378DB0900D0F2E0118C76 +:102590008FB2002F4CD1AB235B00C65A958BAA2378 +:1025A0005B00ADB2C35A2E401E40744B7A00D35A22 +:1025B0001D4202D02268126893831E420FD07049D8 +:1025C000062F06D16F4B1A89802312095B00134036 +:1025D0000B603B1C20682E339B001B58984701372B +:1025E000072FE2D1C6E01E1C0836B0250096740104 +:1025F0006D00C618751959361419FF36B446029481 +:10260000E4792E78039565462D78E4B22E40351C8A +:1026100060262540344212D1102634422AD10C269D +:1026200034423AD1A60776D10133082B00D1A1E07C +:102630003C1C1C410125D9B22C42F5D0D3E75C01EA +:102640001219FF32167A4024264204D014728022D6 +:102650005242114304E0167A2024264202D014721A +:10266000494A91716022154200D183E01B01C318D1 +:10267000DC337CE0029F0399FE710A78324279D004 +:1026800040495A018A1852681B0192043E49C318F6 +:10269000920CD8330A805B686BE05C011219FF3240 +:1026A000177A082637421DD01672364A1419A67EAC +:1026B00002221834164202D0A6789643A6708022D1 +:1026C00052421143304A9171009902684F01D71963 +:1026D000FA7994074ED40C2215424BD01B01C31833 +:1026E000D43344E0167A04273E42F4D01772254AC8 +:1026F0001219967A02240832264202D09678A6430E +:102700009670214A9171009902684F01D719FA79A0 +:10271000D407E0D52EE05C011219FF32177ABC46CF +:10272000664602273E420CD0802617727642164A31 +:102730003143917113490C1961698904890C5180E5 +:1027400010E0177A012637420CD016720E4A9171AA +:102750000C490C1961688904890C118061680901B0 +:10276000890C9180AF0705D00D331B01C3185B683E +:102770000549984705B0F0BD28070020283B000018 +:1027800018070020E0090020200700200022012374 +:10279000027043708270C37070470000F7B5171C59 +:1027A000634A00231360634A051C1060624A296073 +:1027B0000C1CD169202001AE01430120D161062209 +:1027C0007370B070F37018205C4B311C32709847F6 +:1027D00006205A4A3070311C19209047BB78684651 +:1027E000037069460620564B9847564B062098477B +:1027F0002378012213432370A378D807FCD45249CD +:102800000B685A0B1F231A409A4200D105221A4026 +:102810009001268D4D4A3240024322850868820C81 +:1028200013401F2B00D11D23208D1F2213409043E6 +:10283000034323850B680722DB0D1340934200D12D +:1028400003231340218D1A03414B42480B4013438D +:10285000238521783A787F23D2010B4013432370DC +:1028600079780123194023780422890093430B438C +:1028700023706062FB78012B04D12B680C211A892C +:102880008A4306E0002B05D12B680C241989A1434B +:102890000A431A818022304B0021520098470023BE +:1028A000E918002204334A60202BF9D1A91800232B +:1028B00010324B628B62CB620B63802AF6D12A1CEA +:1028C000A43213705370E918081C0022A630AE31F0 +:1028D000013302700A70082BF5D1131CE918B831C6 +:1028E000002204330A601C2BF8D1A918081C00230D +:1028F000D430E03110320360436083600B60802A83 +:10290000F3D1AA225200AB52AB225200AB52AC2000 +:10291000EA184000111861320020FF3201330870BC +:102920001070082BF3D10D4B80221A60FEBDC046FB +:102930001C07002028070020000400401D30000074 +:102940004D2F0000C52E0000246080003FF8FFFFDF +:10295000FF8FFFFFE0090020EF3A000000E100E0F8 +:10296000094B196800290BD1EFF31080074A0028A2 +:1029700005D172B6BFF35F8F054908700121117050 +:102980001A6801321A6070472C07002030070020B7 +:1029900014010020084B1A68013A1A601B68002BCA +:1029A00009D1064B1B78002B05D0054B01221A706C +:1029B000BFF35F8F62B670472C07002030070020FE +:1029C00014010020F7B5002301AC144E8027012527 +:1029D000A370211CBF021120114B65702570984710 +:1029E000B761211C11200E4B25709847B761211C3F +:1029F0009836082723200A4B257098473760211CFA +:102A00001B20074B25709847002337600F20237049 +:102A1000211C034B65709847F7BDC0460044004138 +:102A2000252A000007B5802201AB1A700A785A7077 +:102A30004A789A708A78191CDA70014B984707BD5A +:102A40001D30000010B50C4B02211A680A431A60B1 +:102A5000196880229143094A89B29184101CC16887 +:102A6000064ACC06FBD599680020D162596891626C +:102A70001B689BB2938410BD3407002000080040FF +:102A800010B5082832D800F011FF083131050513C0 +:102A90000B162900802000022BE0164B186928E055 +:102AA000154B186A154B8005800FC340181C20E099 +:102AB000104B58691DE00F4C02232068184018D0B5 +:102AC0000D4BDB68DA06FBD523685A0710D50C4B93 +:102AD00000209847A3689BB258430AE0094B0020A6 +:102AE0001B785A0705D5034BD86802E0002000E0A8 +:102AF000054810BD340700200008004000127A008D +:102B0000692F000050080040006CDC0270B50D4BCE +:102B100045781E6A8178047801224020864315405A +:102B2000AD01301C0A402843D10180229043021C91 +:102B30000A43054803212140090202400A431A6260 +:102B400070BDC04600080040FFFCFFFF30B5027AB0 +:102B5000438992069B059B0D120C1A43124B5A6037 +:102B600042888188C4791143827922430A4341789B +:102B7000C9010A431A600278042A0BD1047BC18977 +:102B8000058A0A48A40609042C43014021439960A0 +:102B9000196806E0202A06D1028A9A601968842200 +:102BA000D2000A431A6030BD340700200000FF0342 +:102BB00008B5082828D800F079FE122727100B182E +:102BC000051E2100114B02211A6A0A431A6204E011 +:102BD0000E4B02219A690A439A61002015E00B4BC3 +:102BE00002211A8A0A431A82F7E7084B02219A8ABD +:102BF0000A439A82F1E7064B984706E0054B02210B +:102C00001A780A431A70E8E7172008BD0008004048 +:102C1000452A000044080040F0B5C223344EDB00D2 +:102C2000B360344B1E215A688BB08A4304210A4397 +:102C30005A6005A800234380837143700723037300 +:102C40003F232022C3812C4B02701A68920E3F2A28 +:102C500000D11F22294B2A491B689B059B0D8B42E3 +:102C600000D1284B43810823C37180235B008380FC +:102C7000254B02720382254B984701A801230025AA +:102C80008370234B457005709847224B0620984768 +:102C9000214B984702AC0323211C65702572657295 +:102CA0002370022020231D4D6360A84702201C4F83 +:102CB000B8471C4B98472A1CF1680D4BC806FBD53A +:102CC000998C802001439984174B002507211D72A0 +:102CD000281C5D729D7201232170211C6360237288 +:102CE000657065729047281CB8470BB0F0BDC046B0 +:102CF00000080040004000412460800028608000FF +:102D0000FF030000FF01000080BBFFFF4D2B000010 +:102D10000D2B0000B12B0000392D0000592D0000B3 +:102D2000FD2D0000452A000000040040014B5878AA +:102D3000C0097047000C0040054B08219A690A43FE +:102D40009A61044B01221A701A78D107FCD470479B +:102D500000040040000C0040F8B50C784B782402C9 +:102D6000051C061C0443002B02D08023DB021C43FD +:102D70004B7A002B02D080231B031C434B68012B92 +:102D800013D95E1E1E400222002E09D19A4202D2A1 +:102D900001365200FAE7360280232E435B0303E03C +:102DA0001E0280232E439B021C430B7A002B02D071 +:102DB00080239B031C430C4FB8470028FBD10B4BCF +:102DC00098470B4B1D70B8470028FCD1094DAE60E9 +:102DD000B8470028FCD16A6880235B0213401C437B +:102DE0006C60054B9847F8BD2D2D0000612900004F +:102DF000080C0040000C00409529000038B5051C67 +:102E0000094CA0470028FBD1084B9847084B1D7080 +:102E1000A0470028FCD1074B8022596852020A4380 +:102E20005A60054B984738BD2D2D000061290000E0 +:102E3000040C0040000C004095290000F7B5061C6A +:102E4000184FB8470028FBD1174B9847174B1E70F7 +:102E5000B8470028FCD1164D164B6868C004C00E58 +:102E60009847124B041C1E706B68DB02DB0F01934A +:102E7000114B1E70B8470028FCD1AD680F4B984726 +:102E8000019B2D0AADB2002B07D1012D07D9201CC3 +:102E9000291C0B4B9847041C01E00135EC40201C19 +:102EA000FEBDC0462D2D000061290000040C00402D +:102EB000000C0040812A0000080C00409529000009 +:102EC000D538000010B5074B041C9847064B8022EC +:102ED0001C70064BD20159880A435A80044B98470C +:102EE00010BDC04661290000020C0040000C0040EB +:102EF0009529000038B50F4B041C98470E4B0F4A1C +:102F00001C700F4B598858880905104058805C8800 +:102F10000C48090F20405880101C5C88084A650442 +:102F2000FBD45388090203400B435380064B984758 +:102F300038BDC04661290000020C0040FFF0FFFFD1 +:102F4000000C0040FFBFFFFF9529000010B50C7872 +:102F5000034B240204439847024BA4B25C8010BD8B +:102F6000F52E0000000C004010B5074B041C9847DC +:102F7000064B1C70064B5C88064B2405240F9847B3 +:102F8000201C054B984710BD61290000020C004031 +:102F9000000C0040952900003D2E000030B5D4788B +:102FA00000239C421AD11478802C03D0802324065D +:102FB0005B02234354780225AC4309D19478002C5A +:102FC00002D18024A40201E0C024E4022343416032 +:102FD0005478013C012C01D80F4C2340A0248DB221 +:102FE000E4052C431C438462D0240D0C24062C439E +:102FF0001C438462D478002C0CD15C0305D59378F3 +:10300000012B01D1816100E041615378013B012B2B +:1030100000D8816030BDC046FFFFFBFF08B5031C30 +:103020000A1C4009D90903D10549C001401800E034 +:1030300000201F210B4001219940024B984708BDF9 +:10304000004400419D2F00007047000008B5044B6C +:103050009847044B9847044B9847044B984708BD42 +:10306000192C0000C529000049300000493000003B +:10307000FEE700001148124910B5884201D0002334 +:1030800001E0104B07E0104CCA18A242F9D2C45814 +:1030900004331460F7E70D4A191D043B934203D231 +:1030A00000221A600B1CF6E7094A0A4B7F218A436B +:1030B0009A60094B9847094B9847FEE75C3B000034 +:1030C00000000020200100201C010020240C002012 +:1030D0000000000000ED00E0913A0000D53700004C +:1030E00008B51D4B1A6802321A601968FA2252019B +:1030F000914209D9194A1A4908201368C867997A70 +:1031000049B200290BDAFAE718683221154B9847C3 +:10311000002920D18022144B9202DA611BE0198829 +:10312000022081431980136880221A720F4AC0233B +:1031300008215B00D1500E4B984772B6BFF35F8FEA +:103140000C4B00221A70BFF34F8F0B4A0B4BDA6007 +:10315000BFF34F8FFEE708BD50070020E00A0020B4 +:1031600004E100E05D3900000044004100E100E0BE +:103170009D080000140100200400FA0500ED00E0A5 +:1031800010B5802390B0DB056946FF220093002331 +:103190008B72CB720A8101220531CA778918CA77EE +:1031A0006A460732D37702AAD3770BAA13705370FB +:1031B00069466A461382D376137613775376019362 +:1031C0000A9305934B77E1231B020893C4239B03C7 +:1031D000039301235B420C930D930C4B13220E932C +:1031E0000B4B8A760F930B4C0B49201C6A460B4BFA +:1031F00098470028F7D12368DA69002AFCD11A68B9 +:1032000002210A431A6010B010BDC0460300360008 +:1032100003003700F80A0020001C00424D10000097 +:103220000E4B082210B51A600D4B19681C1C0A7E43 +:10323000530709D50B4B08221A6023680422187E15 +:10324000104006D0188D06E0074B98470028EBD0B9 +:10325000F0E7064B9847C0B210BDC0469844004105 +:10326000F80A002094440041510500006105000067 +:10327000134B8022120570B5041C9A611D1C114B62 +:1032800018681E1C027ED1070AD580231B056B61BE +:103290003268137ED8070FD5802314855B0207E0C0 +:1032A000094B98470028EAD0EFE7013B002B06D0F6 +:1032B000117E8807F9D502E0201C044B984770BDA9 +:1032C00000440041F80A002061060000E906000001 +:1032D0000B4B0C4A1968914211D91A68D2B2002AD4 +:1032E00009D01A68012152085200494211801A6817 +:1032F00002321A60F1E7044B1B7DDA07FBD57047F9 +:1033000018010020FF3F00000040004110B50B1CD9 +:1033100000225C1AA4B2844203D21C7801336240BA +:10332000F7E7101C10BD0000F0B5944BC9B05879F8 +:103330006946087001381C2800D9F8E000F0B6FA98 +:103340000F5A32F7F75DF7F7F7F7F7F7F7F7F7AD3B +:1033500053869EC2F7F7F7F7F7F725F76B000023C0 +:103360004B7008238B704123CB7056230B71522373 +:103370004B7149238B715323CB7150230B725F2305 +:103380004B7232238B720B24D2E05A7A00234B709B +:1033900002218A1A7A49D2006E461141B170F37047 +:1033A0000424C5E09B7900224A70902B10D006D8E7 +:1033B000802B0BD0812B11D102238B7011E0912B2C +:1033C00009D0922B0AD105238B700AE0012306E075 +:1033D00003248C70ACE004238B7002E00023694668 +:1033E0008B700324A4E000234B70664A664B1A607E +:1033F00002249DE000234B70FAE79979DA790906F7 +:1034000012040A43597A1B7A0A431B021A435F4B80 +:1034100052001A602EE0597A002230290DD16E46F2 +:10342000DB7AF1700221CB1A5549DB001941727029 +:10343000B27032717171B27106E06846427082708A +:10344000C170027142718271072471E08022D20141 +:103450004F4B197D188B2021FF31014319839108AF +:103460004900D9614B4901321980FF328023DB02C8 +:103470009A42EDD1002369464B70B9E79879DA7921 +:103480004249000210180C68434A80B2944208D89E +:103490000B68C018414B0860984700236A46537078 +:1034A000A6E70F3300228242F2D25D780C681E78C4 +:1034B00014192D02640875196400ADB2258002321A +:1034C0000233F0E79879DB790002304A18186E462B +:1034D000002381B27370304D1668CC1CA4B2AE428A +:1034E0001DD98B4212D21568981C5D196D086D00AC +:1034F0002D886E463554156800AE5B195B085B007D +:103500001D8833182D0A5D70031CEAE7136800A8B4 +:10351000C91803191160013B00221A7008E08342A8 +:10352000F4D000AEF518FF26AE700133F7E70024A3 +:103530001B4D1B20A8471B4B260A1F78381CA84789 +:10354000F0B2A8471B235F4067407E40E0B2F7B26D +:10355000A8470E204740A8470026B3B2A34204D292 +:103560006946885DA8470136F7E769460E4B201C7F +:1035700098474740F8B2A84749B0F0BD040B002077 +:1035800001981E004C1D000050070020180100206B +:103590000040004102A5FFFFFF3F0000D1320000C4 +:1035A000713200004E0700200D330000F8B50027EF +:1035B0003D1C3C1C1F4B98471F49061C48550135B4 +:1035C000062CF7D8201C00F071F904080C11171C08 +:1035D00023001B2E28D00025ECE7184B02241E7078 +:1035E000E8E7174B36021E800324E3E7144B04245C +:1035F0001A8816431E80DDE70E2E17D100270524FA +:10360000D8E70F4B01371B889F42D3D10624D1E75F +:10361000013DA8B20B4B98470025B04207D10A4B99 +:103620001D600A4B9847F8BD0124C3E700252C1CF8 +:10363000C0E7C04621320000040B00204E070020E6 +:103640004C0700200D3300005007002029330000F4 +:10365000094B0421DA690A43DA61084B2022198BED +:10366000FF320A431A831A7DD10703D559681E22F7 +:103670000A405A607047C0460004004000400041C4 +:103680007FB500236A46164CD37013809370029363 +:103690000393012313711349134B201C134E9847B6 +:1036A00008222368326021688A7A52B2002AFBDB42 +:1036B0001A8802252A431A80201C2A1C0C490D4B0B +:1036C0009847291C201C0C4B9847201C01210B4BB0 +:1036D0009847C023AB40F2581202120AF2507FBD45 +:1036E000E00A0020001400405113000000E100E057 +:1036F000E13000004914000081140000251400008E +:10370000F0B5294B85B09847284B1A7DD007FBD5DB +:10371000274F69463A88274E0A81274A11886A4608 +:103720005181318803AA1180244A11886A46D181C7 +:10373000029907220A40012A31D01A8BD00530D4D1 +:1037400059688022D2020A4301915A601A8B2025BF +:10375000FF352A431A831A4C1A4ADC611A80197DF4 +:10376000124AC807FBD5108B284310831648D46132 +:103770001080197D01200D4A0142FAD0138B1D43A0 +:103780001583D461029B0724634018430290029B77 +:103790003B6003980D4B30601380019951600C4BD6 +:1037A000984705B0F0BDC0466129000000400041C7 +:1037B00000408000044080000240800006408000FD +:1037C0000020400005A5FFFF44A5FFFF06A5FFFF61 +:1037D0009529000008B5244B1A7852B2002A03DB61 +:1037E0001A7802218A431A70204B1A78D10611D414 +:1037F0001B789A060ED48023DB0118881C491A1CFA +:10380000884207D01B6883F308881A4B9A601A4BCA +:103810001B689847194B01221A70BFF35F8F62B67D +:10382000174B9847174B9847174B9847174B984794 +:10383000174B9847174AC1239B00D058802100029C +:10384000000AC9050143D150134B9847134B8022FE +:1038500092025A61802212059A61114B08221A6065 +:10386000104B9847FCE7C046001000403804004069 +:10387000FFFF000000ED00E0044000001401002004 +:103880004D300000813600005136000081310000CB +:103890004D08000000E100E0013700000044004155 +:1038A00098440041AD3500007047000002B47146F5 +:1038B00049084900095C49008E4402BC7047C04673 +:1038C00003B47146490840004900095A49008E4432 +:1038D00003BC7047002934D00123002210B4884271 +:1038E0002CD301242407A14204D2814202D209012F +:1038F0001B01F8E7E400A14204D2814202D2490050 +:103900005B00F8E7884201D3401A1A434C08A042F2 +:1039100002D3001B5C0822438C08A04202D3001B88 +:103920009C082243CC08A04202D3001BDC0822439F +:10393000002803D01B0901D00909E3E7101C10BCC3 +:103940007047002801D00020C04307B4024802A1FC +:103950004018029003BDC046D90000000029F0D0F5 +:1039600003B5FFF7B9FF0EBC4243891A1847C0469A +:10397000002941D010B4041C4C40A446012300226D +:10398000002900D54942002800D5404288422CD366 +:1039900001242407A14204D2814202D209011B0161 +:1039A000F8E7E400A14204D2814202D249005B0060 +:1039B000F8E7884201D3401A1A434C08A04202D3C8 +:1039C000001B5C0822438C08A04202D3001B9C0809 +:1039D0002243CC08A04202D3001BDC08224300286B +:1039E00003D01B0901D00909E3E7101C6446002C31 +:1039F00000D5404210BC7047002806D003DB0020F1 +:103A0000C043400801E08020000607B4024802A13C +:103A10004018029003BDC046190000000029EBD0F9 +:103A200003B5FFF7A7FF0EBC4243891A1847C046EB +:103A30007047C0469140031C90409C46203A9340FA +:103A4000194352426346D340194370479C460304CE +:103A5000F0B51B0C17043F0C150C1E1C041C000CAD +:103A60007E436B4347434543FB18300C181887428D +:103A700002D980235B02ED18030CED1863465C430A +:103A80004A433604360CA118000480194919F0BDC8 +:103A900070B50E4B0E4D0024ED1AAD101E1CAC423D +:103AA00004D0A300F35898470134F8E700F046F833 +:103AB000084B094D0024ED1AAD101E1CAC4204D079 +:103AC000A300F35898470134F8E770BD483B000065 +:103AD000483B0000483B00004C3B000010B5002371 +:103AE000934203D0CC5CC4540133F9E710BD031CEE +:103AF0008218934202D019700133FAE770473030D0 +:103B00003533000000080042000C00420010004263 +:103B10000014004200180042001C0042090A0B0C6D +:103B20000D0E000000030201040008007000800078 +:103B3000010000010002030C10600000F8B5C0464F +:103B4000F8BC08BC9E467047D9000000F8B5C046D6 +:0C3B5000F8BC08BC9E467047B1000000A5 +:103B5C006D0400003D010000590100005D010000F2 +:103B6C0051030000610100002D010000E101000083 +:103B7C005D0100000000000041726475696E6F20E9 +:103B8C005469616E0041726475696E6F2073726C5A +:103B9C0020287777772E61726475696E6F2E6F723D +:103BAC006729000000030000000000000000000076 +:103BBC0000000000000000000000000000000000F9 +:103BCC0000000000000000000000000000000000E9 +:103BDC0000000000000000000000000000000000D9 +:103BEC0004030904050F0C00010710020200000079 +:103BFC00BC000020B4000020940000201400002021 +:103C0C0000000020D0000020AC00002012010102B6 +:103C1C0002000040032A52000001010203010000CF +:103C2C0009024300020100C0320904000001020233 +:103C3C0001000524001001042402020524060001E1 +:103C4C00052401030107058303400010090401004A +:103C5C00020A00000007058102400000070502026D +:0C3C6C00400000000100000000400000CB +:040000030000307554 +:00000001FF diff --git a/bootloaders/zero/Makefile b/bootloaders/zero/Makefile new file mode 100644 index 0000000..61fca6e --- /dev/null +++ b/bootloaders/zero/Makefile @@ -0,0 +1,178 @@ +# Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. All right reserved. +# Copyright (c) 2015 Arduino LLC. 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 + +# ----------------------------------------------------------------------------- +# Paths +ifeq ($(OS),Windows_NT) + # Are we using mingw/msys/msys2/cygwin? + ifeq ($(TERM),xterm) + T=$(shell cygpath -u $(LOCALAPPDATA)) + MODULE_PATH?=$(T)/Arduino15/packages/arduino + RM=rm + SEP=/ + else + MODULE_PATH?=$(LOCALAPPDATA)/Arduino15/packages/arduino + RM=rm + SEP=\\ + endif +else + UNAME_S := $(shell uname -s) + + ifeq ($(UNAME_S),Linux) + MODULE_PATH?=$(HOME)/.arduino15/packages/arduino + RM=rm + SEP=/ + endif + + ifeq ($(UNAME_S),Darwin) + MODULE_PATH?=$(HOME)/Library/Arduino15/packages/arduino/ + RM=rm + SEP=/ + endif +endif + +ARM_GCC_PATH?=$(MODULE_PATH)/tools/arm-none-eabi-gcc/7-2017q4/bin/arm-none-eabi- +BUILD_PATH=build + +# ----------------------------------------------------------------------------- +# Tools +CC=$(ARM_GCC_PATH)gcc +OBJCOPY=$(ARM_GCC_PATH)objcopy +NM=$(ARM_GCC_PATH)nm +SIZE=$(ARM_GCC_PATH)size + +# ----------------------------------------------------------------------------- +# Boards definitions +BOARD_ID?=arduino_zero +NAME?=samd21_sam_ba + +# ----------------------------------------------------------------------------- +# Compiler options +SAM_BA_INTERFACES?=SAM_BA_BOTH_INTERFACES +CFLAGS_EXTRA=-D__SAMD21G18A__ -DBOARD_ID_$(BOARD_ID) -D$(SAM_BA_INTERFACES) +CFLAGS=-mthumb -mcpu=cortex-m0plus -Wall -c -std=gnu99 -ffunction-sections -fdata-sections -nostdlib -nostartfiles --param max-inline-insns-single=500 +ifdef DEBUG + CFLAGS+=-g3 -O1 -DDEBUG=1 +else + CFLAGS+=-Os -DDEBUG=0 -flto +endif + +ifdef SECURE_BY_DEFAULT + CFLAGS+=-DSECURE_BY_DEFAULT=1 +endif + +ELF=$(NAME).elf +BIN=$(NAME).bin +HEX=$(NAME).hex + +INCLUDES=-I"$(MODULE_PATH)/tools/CMSIS/4.5.0/CMSIS/Include/" -I"$(MODULE_PATH)/tools/CMSIS-Atmel/1.2.0/CMSIS/Device/ATMEL/" + +# ----------------------------------------------------------------------------- +# Linker options +LDFLAGS=-mthumb -mcpu=cortex-m0plus -Wall -Wl,--cref -Wl,--check-sections -Wl,--gc-sections -Wl,--unresolved-symbols=report-all +LDFLAGS+=-Wl,--warn-common -Wl,--warn-section-align -Wl,--warn-unresolved-symbols --specs=nano.specs --specs=nosys.specs + +# ----------------------------------------------------------------------------- +# Source files and objects +SOURCES= \ + board_driver_i2c.c \ + board_driver_led.c \ + board_driver_pmic.c \ + board_driver_jtag.c \ + board_driver_serial.c \ + board_driver_usb.c \ + board_init.c \ + board_startup.c \ + main.c \ + sam_ba_usb.c \ + sam_ba_cdc.c \ + sam_ba_monitor.c \ + sam_ba_serial.c + +OBJECTS=$(addprefix $(BUILD_PATH)/, $(SOURCES:.c=.o)) +DEPS=$(addprefix $(BUILD_PATH)/, $(SOURCES:.c=.d)) + +ifneq "test$(AVRSTUDIO_EXE_PATH)" "test" + AS_BUILD=copy_for_atmel_studio + AS_CLEAN=clean_for_atmel_studio +else + AS_BUILD= + AS_CLEAN= +endif + +LD_SCRIPT=bootloader_samd21x18.ld + +all: print_info $(SOURCES) $(BIN) $(HEX) $(AS_BUILD) + +$(ELF): Makefile $(BUILD_PATH) $(OBJECTS) + @echo ---------------------------------------------------------- + @echo Creating ELF binary + "$(CC)" -L. -L$(BUILD_PATH) $(LDFLAGS) -Os -Wl,--gc-sections -save-temps -T$(LD_SCRIPT) -Wl,-Map,"$(BUILD_PATH)/$(NAME).map" -o "$(BUILD_PATH)/$(ELF)" -Wl,--start-group $(OBJECTS) -lm -Wl,--end-group + "$(NM)" "$(BUILD_PATH)/$(ELF)" >"$(BUILD_PATH)/$(NAME)_symbols.txt" + "$(SIZE)" --format=sysv -t -x $(BUILD_PATH)/$(ELF) + +$(BIN): $(ELF) + @echo ---------------------------------------------------------- + @echo Creating flash binary + "$(OBJCOPY)" -O binary $(BUILD_PATH)/$< $@ + +$(HEX): $(ELF) + @echo ---------------------------------------------------------- + @echo Creating flash binary + "$(OBJCOPY)" -O ihex $(BUILD_PATH)/$< $@ + +$(BUILD_PATH)/%.o: %.c + @echo ---------------------------------------------------------- + @echo Compiling $< to $@ + "$(CC)" $(CFLAGS) $(CFLAGS_EXTRA) $(INCLUDES) $< -o $@ + @echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + +$(BUILD_PATH): + @echo ---------------------------------------------------------- + @echo Creating build folder + -mkdir $(BUILD_PATH) + +print_info: + @echo ---------------------------------------------------------- + @echo Compiling bootloader using + @echo BASE PATH = $(MODULE_PATH) + @echo GCC PATH = $(ARM_GCC_PATH) +# @echo OS = $(OS) +# @echo SHELL = $(SHELL) +# @echo TERM = $(TERM) +# "$(CC)" -v +# env + +copy_for_atmel_studio: $(BIN) $(HEX) + @echo ---------------------------------------------------------- + @echo Atmel Studio detected, copying ELF to project root for debug + cp $(BUILD_PATH)/$(ELF) . + +clean_for_atmel_studio: + @echo ---------------------------------------------------------- + @echo Atmel Studio detected, cleaning ELF from project root + -$(RM) ./$(ELF) + +clean: $(AS_CLEAN) + @echo ---------------------------------------------------------- + @echo Cleaning project + -$(RM) $(BIN) + -$(RM) $(HEX) + -$(RM) $(BUILD_PATH)/*.* + -rmdir $(BUILD_PATH) + +.phony: print_info $(BUILD_PATH) diff --git a/bootloaders/zero/README.md b/bootloaders/zero/README.md new file mode 100644 index 0000000..b0d939d --- /dev/null +++ b/bootloaders/zero/README.md @@ -0,0 +1,95 @@ +# Arduino Zero Bootloader + +## 1- Prerequisites + +The project build is based on Makefile system. +Makefile is present at project root and try to handle multi-platform cases. + +Multi-plaform GCC is provided by ARM here: https://launchpad.net/gcc-arm-embedded/+download + +Atmel Studio contains both make and ARM GCC toolchain. You don't need to install them in this specific use case. + +For all builds and platforms you will need to have the Arduino IDE installed and the board support +package for "Arduino SAMD Boards (32-bits ARM Cortex-M0+)". You can install the latter +from the former's "Boards Manager" UI. + +### Windows + +* Native command line +Make binary can be obtained here: http://gnuwin32.sourceforge.net/packages/make.htm + +* Cygwin/MSys/MSys2/Babun/etc... +It is available natively in all distributions. + +* Atmel Studio +An Atmel Studio **7** Makefile-based project is present at project root, just open samd21_sam_ba.atsln file in AS7. + +### Linux + +Make is usually available by default. + +### OS X + +Make is available through XCode package. + + +## 2- Selecting available SAM-BA interfaces + +By default both USB and UART are made available, but this parameter can be modified in sam_ba_monitor.h, line 31: + +Set the define SAM_BA_INTERFACE to +* SAM_BA_UART_ONLY for only UART interface +* SAM_BA_USBCDC_ONLY for only USB CDC interface +* SAM_BA_BOTH_INTERFACES for enabling both the interfaces + +## 3- Behaviour + +This bootloader implements the double-tap on Reset button. +By quickly pressing this button two times, the board will reset and stay in bootloader, waiting for communication on either USB or USART. + +The USB port in use is the USB Native port, close to the Reset button. +The USART in use is the one available on pins D0/D1, labelled respectively RX/TX. Communication parameters are a baudrate at 115200, 8bits of data, no parity and 1 stop bit (8N1). + +## 4- Description + +**Pinmap** + +The following pins are used by the program : +PA25 : input/output (USB DP) +PA24 : input/output (USB DM) +PA11 : input (USART RX) +PA10 : output (USART TX) + +The application board shall avoid driving the PA25, PA24, PB23 and PB22 signals while the boot program is running (after a POR for example). + +**Clock system** + +CPU runs at 48MHz from Generic Clock Generator 0 on DFLL48M. + +Generic Clock Generator 1 is using external 32kHz oscillator and is the source of DFLL48M. + +USB and USART are using Generic Clock Generator 0 also. + +**Memory Mapping** + +Bootloader code will be located at 0x0 and executed before any applicative code. + +Applications compiled to be executed along with the bootloader will start at 0x2000 (see linker script bootloader_samd21x18.ld). + +Before jumping to the application, the bootloader changes the VTOR register to use the interrupt vectors of the application @0x2000.<- not required as application code is taking care of this. + +## 5- How to build + +If not specified the makefile builds for **Arduino Zero**: + +``` +make +``` + +if you want to make a custom bootloader for a derivative board you must supply all the necessary information in a `board_definitions_xxx.h` file, and add the corresponding case in `board_definitions.h`. +For example for the **Arduino MKR1000** we use `board_definitions_arduino_mkr1000.h` and it is build with the following command: + +``` +BOARD_ID=arduino_mkr1000 NAME=samd21_sam_ba_arduino_mkr1000 make clean all +``` + diff --git a/bootloaders/zero/board_definitions.h b/bootloaders/zero/board_definitions.h new file mode 100644 index 0000000..097484c --- /dev/null +++ b/bootloaders/zero/board_definitions.h @@ -0,0 +1,50 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 +*/ + +#if defined(BOARD_ID_arduino_zero) + #include "board_definitions_arduino_zero.h" +#elif defined(BOARD_ID_arduino_mkr1000) + #include "board_definitions_arduino_mkr1000.h" +#elif defined(BOARD_ID_arduino_mkrzero) + #include "board_definitions_arduino_mkrzero.h" +#elif defined(BOARD_ID_arduino_mkrfox1200) + #include "board_definitions_arduino_mkrfox1200.h" +#elif defined(BOARD_ID_arduino_mkrgsm1400) + #include "board_definitions_arduino_mkrgsm1400.h" +#elif defined(BOARD_ID_arduino_mkrwan1300) + #include "board_definitions_arduino_mkrwan1300.h" +#elif defined(BOARD_ID_arduino_mkrwan1310) + #include "board_definitions_arduino_mkrwan1310.h" +#elif defined(BOARD_ID_arduino_mkrwifi1010) + #include "board_definitions_arduino_mkrwifi1010.h" +#elif defined(BOARD_ID_arduino_mkrvidor4000) + #include "board_definitions_arduino_mkrvidor4000.h" +#elif defined(BOARD_ID_arduino_mkrnb1500) + #include "board_definitions_arduino_mkrnb1500.h" +#elif defined(BOARD_ID_arduino_nano_33_iot) + #include "board_definitions_arduino_nano_33_iot.h" +#else + #error You must define a BOARD_ID and add the corresponding definitions in board_definitions.h +#endif + +// Common definitions +// ------------------ + +#define BOOT_PIN_MASK (1U << (BOOT_LOAD_PIN & 0x1f)) + diff --git a/bootloaders/zero/board_definitions_arduino_mkr1000.h b/bootloaders/zero/board_definitions_arduino_mkr1000.h new file mode 100644 index 0000000..4e71e4d --- /dev/null +++ b/bootloaders/zero/board_definitions_arduino_mkr1000.h @@ -0,0 +1,82 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 _BOARD_DEFINITIONS_H_ +#define _BOARD_DEFINITIONS_H_ + +/* + * USB device definitions + */ +#define STRING_PRODUCT "Arduino MKR1000" +#define USB_VID_HIGH 0x23 +#define USB_VID_LOW 0x41 +#define USB_PID_HIGH 0x00 +#define USB_PID_LOW 0x4E + +/* + * If BOOT_DOUBLE_TAP_ADDRESS is defined the bootloader is started by + * quickly tapping two times on the reset button. + * BOOT_DOUBLE_TAP_ADDRESS must point to a free SRAM cell that must not + * be touched from the loaded application. + */ +#define BOOT_DOUBLE_TAP_ADDRESS (0x20007FFCul) +#define BOOT_DOUBLE_TAP_DATA (*((volatile uint32_t *) BOOT_DOUBLE_TAP_ADDRESS)) + +/* + * If BOOT_LOAD_PIN is defined the bootloader is started if the selected + * pin is tied LOW. + */ +//#define BOOT_LOAD_PIN PIN_PA21 // Pin 7 +//#define BOOT_LOAD_PIN PIN_PA15 // Pin 5 + +#define BOOT_USART_MODULE SERCOM0 +#define BOOT_USART_BUS_CLOCK_INDEX PM_APBCMASK_SERCOM0 +#define BOOT_USART_PER_CLOCK_INDEX GCLK_CLKCTRL_ID_SERCOM0_CORE_Val +#define BOOT_USART_PAD_SETTINGS UART_RX_PAD3_TX_PAD2 +#define BOOT_USART_PAD3 PINMUX_PA11C_SERCOM0_PAD3 +#define BOOT_USART_PAD2 PINMUX_PA10C_SERCOM0_PAD2 +#define BOOT_USART_PAD1 PINMUX_UNUSED +#define BOOT_USART_PAD0 PINMUX_UNUSED + +/* Master clock frequency */ +#define CPU_FREQUENCY (48000000ul) +#define VARIANT_MCK CPU_FREQUENCY + +/* Frequency of the board main oscillator */ +#define VARIANT_MAINOSC (32768ul) + +/* Calibration values for DFLL48 pll */ +#define NVM_SW_CALIB_DFLL48M_COARSE_VAL (58) +#define NVM_SW_CALIB_DFLL48M_FINE_VAL (64) + +/* + * LEDs definitions + */ +// PA20 (digital pin 6) +#define BOARD_LED_PORT (0) +#define BOARD_LED_PIN (20) + +// No RX/TX led +//#define BOARD_LEDRX_PORT +//#define BOARD_LEDRX_PIN + +//#define BOARD_LEDTX_PORT +//#define BOARD_LEDTX_PIN + +#endif // _BOARD_DEFINITIONS_H_ diff --git a/bootloaders/zero/board_definitions_arduino_mkrfox1200.h b/bootloaders/zero/board_definitions_arduino_mkrfox1200.h new file mode 100644 index 0000000..ccf5676 --- /dev/null +++ b/bootloaders/zero/board_definitions_arduino_mkrfox1200.h @@ -0,0 +1,81 @@ +/* + Copyright (c) 2016 Arduino LLC. 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 _BOARD_DEFINITIONS_H_ +#define _BOARD_DEFINITIONS_H_ + +/* + * USB device definitions + */ +#define STRING_PRODUCT "Arduino MKR FOX 1200" +#define USB_VID_HIGH 0x23 +#define USB_VID_LOW 0x41 +#define USB_PID_HIGH 0x00 +#define USB_PID_LOW 0x50 + +/* + * If BOOT_DOUBLE_TAP_ADDRESS is defined the bootloader is started by + * quickly tapping two times on the reset button. + * BOOT_DOUBLE_TAP_ADDRESS must point to a free SRAM cell that must not + * be touched from the loaded application. + */ +#define BOOT_DOUBLE_TAP_ADDRESS (0x20007FFCul) +#define BOOT_DOUBLE_TAP_DATA (*((volatile uint32_t *) BOOT_DOUBLE_TAP_ADDRESS)) + +/* + * If BOOT_LOAD_PIN is defined the bootloader is started if the selected + * pin is tied LOW. + */ +//#define BOOT_LOAD_PIN PIN_PA21 +//#define BOOT_LOAD_PIN PIN_PA15 + +#define BOOT_USART_MODULE SERCOM5 +#define BOOT_USART_BUS_CLOCK_INDEX PM_APBCMASK_SERCOM5 +#define BOOT_USART_PER_CLOCK_INDEX GCLK_CLKCTRL_ID_SERCOM5_CORE_Val +#define BOOT_USART_PAD_SETTINGS UART_RX_PAD3_TX_PAD2 +#define BOOT_USART_PAD3 PINMUX_PB23D_SERCOM5_PAD3 +#define BOOT_USART_PAD2 PINMUX_PB22D_SERCOM5_PAD2 +#define BOOT_USART_PAD1 PINMUX_UNUSED +#define BOOT_USART_PAD0 PINMUX_UNUSED + +/* Master clock frequency */ +#define CPU_FREQUENCY (48000000ul) +#define VARIANT_MCK CPU_FREQUENCY + +/* Frequency of the board main oscillator */ +#define VARIANT_MAINOSC (32768ul) + +/* Calibration values for DFLL48 pll */ +#define NVM_SW_CALIB_DFLL48M_COARSE_VAL (58) +#define NVM_SW_CALIB_DFLL48M_FINE_VAL (64) + +/* + * LEDs definitions + */ +// PA20 (digital pin 6) +#define BOARD_LED_PORT (0) +#define BOARD_LED_PIN (20) + +// No RX/TX led +//#define BOARD_LEDRX_PORT +//#define BOARD_LEDRX_PIN + +//#define BOARD_LEDTX_PORT +//#define BOARD_LEDTX_PIN + +#endif // _BOARD_DEFINITIONS_H_ diff --git a/bootloaders/zero/board_definitions_arduino_mkrgsm1400.h b/bootloaders/zero/board_definitions_arduino_mkrgsm1400.h new file mode 100644 index 0000000..89b4ea8 --- /dev/null +++ b/bootloaders/zero/board_definitions_arduino_mkrgsm1400.h @@ -0,0 +1,86 @@ +/* + Copyright (c) 2016 Arduino LLC. 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 _BOARD_DEFINITIONS_H_ +#define _BOARD_DEFINITIONS_H_ + +/* + * USB device definitions + */ +#define STRING_PRODUCT "Arduino MKR GSM 1400" +#define USB_VID_HIGH 0x23 +#define USB_VID_LOW 0x41 +#define USB_PID_HIGH 0x00 +#define USB_PID_LOW 0x52 + +/* + * If BOOT_DOUBLE_TAP_ADDRESS is defined the bootloader is started by + * quickly tapping two times on the reset button. + * BOOT_DOUBLE_TAP_ADDRESS must point to a free SRAM cell that must not + * be touched from the loaded application. + */ +#define BOOT_DOUBLE_TAP_ADDRESS (0x20007FFCul) +#define BOOT_DOUBLE_TAP_DATA (*((volatile uint32_t *) BOOT_DOUBLE_TAP_ADDRESS)) + +/* + * If BOOT_LOAD_PIN is defined the bootloader is started if the selected + * pin is tied LOW. + */ +//#define BOOT_LOAD_PIN PIN_PA21 +//#define BOOT_LOAD_PIN PIN_PA15 + +#define BOOT_USART_MODULE SERCOM5 +#define BOOT_USART_BUS_CLOCK_INDEX PM_APBCMASK_SERCOM5 +#define BOOT_USART_PER_CLOCK_INDEX GCLK_CLKCTRL_ID_SERCOM5_CORE_Val +#define BOOT_USART_PAD_SETTINGS UART_RX_PAD3_TX_PAD2 +#define BOOT_USART_PAD3 PINMUX_PB23D_SERCOM5_PAD3 +#define BOOT_USART_PAD2 PINMUX_PB22D_SERCOM5_PAD2 +#define BOOT_USART_PAD1 PINMUX_UNUSED +#define BOOT_USART_PAD0 PINMUX_UNUSED + +/* Master clock frequency */ +#define CPU_FREQUENCY (48000000ul) +#define VARIANT_MCK CPU_FREQUENCY + +/* Frequency of the board main oscillator */ +#define VARIANT_MAINOSC (32768ul) + +/* Calibration values for DFLL48 pll */ +#define NVM_SW_CALIB_DFLL48M_COARSE_VAL (58) +#define NVM_SW_CALIB_DFLL48M_FINE_VAL (64) + +/* + * LEDs definitions + */ +// PA20 (digital pin 6) +#define BOARD_LED_PORT (0) +#define BOARD_LED_PIN (20) + +#define CONFIGURE_PMIC 1 +#define PMIC_PIN_SCL 12 +#define PMIC_PIN_SDA 11 +#define PMIC_SERCOM SERCOM0 + +// No RX/TX led +//#define BOARD_LEDRX_PORT +//#define BOARD_LEDRX_PIN + +//#define BOARD_LEDTX_PORT +//#define BOARD_LEDTX_PIN + +#endif // _BOARD_DEFINITIONS_H_ diff --git a/bootloaders/zero/board_definitions_arduino_mkrnb1500.h b/bootloaders/zero/board_definitions_arduino_mkrnb1500.h new file mode 100644 index 0000000..e75de38 --- /dev/null +++ b/bootloaders/zero/board_definitions_arduino_mkrnb1500.h @@ -0,0 +1,86 @@ +/* + Copyright (c) 2016 Arduino LLC. 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 _BOARD_DEFINITIONS_H_ +#define _BOARD_DEFINITIONS_H_ + +/* + * USB device definitions + */ +#define STRING_PRODUCT "Arduino MKR NB 1500" +#define USB_VID_HIGH 0x23 +#define USB_VID_LOW 0x41 +#define USB_PID_HIGH 0x00 +#define USB_PID_LOW 0x55 + +/* + * If BOOT_DOUBLE_TAP_ADDRESS is defined the bootloader is started by + * quickly tapping two times on the reset button. + * BOOT_DOUBLE_TAP_ADDRESS must point to a free SRAM cell that must not + * be touched from the loaded application. + */ +#define BOOT_DOUBLE_TAP_ADDRESS (0x20007FFCul) +#define BOOT_DOUBLE_TAP_DATA (*((volatile uint32_t *) BOOT_DOUBLE_TAP_ADDRESS)) + +/* + * If BOOT_LOAD_PIN is defined the bootloader is started if the selected + * pin is tied LOW. + */ +//#define BOOT_LOAD_PIN PIN_PA21 +//#define BOOT_LOAD_PIN PIN_PA15 + +#define BOOT_USART_MODULE SERCOM5 +#define BOOT_USART_BUS_CLOCK_INDEX PM_APBCMASK_SERCOM5 +#define BOOT_USART_PER_CLOCK_INDEX GCLK_CLKCTRL_ID_SERCOM5_CORE_Val +#define BOOT_USART_PAD_SETTINGS UART_RX_PAD3_TX_PAD2 +#define BOOT_USART_PAD3 PINMUX_PB23D_SERCOM5_PAD3 +#define BOOT_USART_PAD2 PINMUX_PB22D_SERCOM5_PAD2 +#define BOOT_USART_PAD1 PINMUX_UNUSED +#define BOOT_USART_PAD0 PINMUX_UNUSED + +/* Master clock frequency */ +#define CPU_FREQUENCY (48000000ul) +#define VARIANT_MCK CPU_FREQUENCY + +/* Frequency of the board main oscillator */ +#define VARIANT_MAINOSC (32768ul) + +/* Calibration values for DFLL48 pll */ +#define NVM_SW_CALIB_DFLL48M_COARSE_VAL (58) +#define NVM_SW_CALIB_DFLL48M_FINE_VAL (64) + +/* + * LEDs definitions + */ +// PA20 (digital pin 6) +#define BOARD_LED_PORT (0) +#define BOARD_LED_PIN (20) + +#define CONFIGURE_PMIC 1 +#define PMIC_PIN_SCL 12 +#define PMIC_PIN_SDA 11 +#define PMIC_SERCOM SERCOM0 + +// No RX/TX led +//#define BOARD_LEDRX_PORT +//#define BOARD_LEDRX_PIN + +//#define BOARD_LEDTX_PORT +//#define BOARD_LEDTX_PIN + +#endif // _BOARD_DEFINITIONS_H_ diff --git a/bootloaders/zero/board_definitions_arduino_mkrvidor4000.h b/bootloaders/zero/board_definitions_arduino_mkrvidor4000.h new file mode 100644 index 0000000..f78a530 --- /dev/null +++ b/bootloaders/zero/board_definitions_arduino_mkrvidor4000.h @@ -0,0 +1,98 @@ +/* + Copyright (c) 2016 Arduino LLC. 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 _BOARD_DEFINITIONS_H_ +#define _BOARD_DEFINITIONS_H_ + +/* + * USB device definitions + */ +#define STRING_PRODUCT "Arduino MKR Vidor 4000" +#define USB_VID_HIGH 0x23 +#define USB_VID_LOW 0x41 +#define USB_PID_HIGH 0x00 +#define USB_PID_LOW 0x56 +#define USB_CURRENT_MA 500 + +/* + * If BOOT_DOUBLE_TAP_ADDRESS is defined the bootloader is started by + * quickly tapping two times on the reset button. + * BOOT_DOUBLE_TAP_ADDRESS must point to a free SRAM cell that must not + * be touched from the loaded application. + */ +#define BOOT_DOUBLE_TAP_ADDRESS (0x20007FFCul) +#define BOOT_DOUBLE_TAP_DATA (*((volatile uint32_t *) BOOT_DOUBLE_TAP_ADDRESS)) + +/* + * If BOOT_LOAD_PIN is defined the bootloader is started if the selected + * pin is tied LOW. + */ +//#define BOOT_LOAD_PIN PIN_PA21 +//#define BOOT_LOAD_PIN PIN_PA15 + +/* Master clock frequency */ +#define CPU_FREQUENCY (48000000ul) +#define VARIANT_MCK CPU_FREQUENCY + +/* Frequency of the board main oscillator */ +#define VARIANT_MAINOSC (32768ul) + +/* Calibration values for DFLL48 pll */ +#define NVM_SW_CALIB_DFLL48M_COARSE_VAL (58) +#define NVM_SW_CALIB_DFLL48M_FINE_VAL (64) + +/* + * LEDs definitions + */ +// PB08 (digital pin 32) +#define BOARD_LED_PORT (1) +#define BOARD_LED_PIN (8) + +#define CONFIGURE_PMIC 1 +#define PMIC_PIN_SCL 12 +#define PMIC_PIN_SDA 11 +#define PMIC_SERCOM SERCOM0 + +#define HAS_EZ6301QI 1 + +#define ENABLE_JTAG_LOAD 1 +#define TDI 12 +#define TDO 15 +#define TCK 13 +#define TMS 14 +#define MB_INT 28 + +#define LAST_FLASH_PAGE (0x200000 - 0x1000) +#define SCRATCHPAD_FLASH_PAGE (0x200000 - 0x2000) + +typedef struct __attribute__((packed)) { + uint32_t offset; + uint32_t length; + uint32_t sha256sum[8]; + uint32_t type; + uint32_t force; +} externalFlashSignatures; + +// No RX/TX led +//#define BOARD_LEDRX_PORT +//#define BOARD_LEDRX_PIN + +//#define BOARD_LEDTX_PORT +//#define BOARD_LEDTX_PIN + +#endif // _BOARD_DEFINITIONS_H_ diff --git a/bootloaders/zero/board_definitions_arduino_mkrwan1300.h b/bootloaders/zero/board_definitions_arduino_mkrwan1300.h new file mode 100644 index 0000000..d89cdee --- /dev/null +++ b/bootloaders/zero/board_definitions_arduino_mkrwan1300.h @@ -0,0 +1,81 @@ +/* + Copyright (c) 2016 Arduino LLC. 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 _BOARD_DEFINITIONS_H_ +#define _BOARD_DEFINITIONS_H_ + +/* + * USB device definitions + */ +#define STRING_PRODUCT "Arduino MKR WAN 1300" +#define USB_VID_HIGH 0x23 +#define USB_VID_LOW 0x41 +#define USB_PID_HIGH 0x00 +#define USB_PID_LOW 0x53 + +/* + * If BOOT_DOUBLE_TAP_ADDRESS is defined the bootloader is started by + * quickly tapping two times on the reset button. + * BOOT_DOUBLE_TAP_ADDRESS must point to a free SRAM cell that must not + * be touched from the loaded application. + */ +#define BOOT_DOUBLE_TAP_ADDRESS (0x20007FFCul) +#define BOOT_DOUBLE_TAP_DATA (*((volatile uint32_t *) BOOT_DOUBLE_TAP_ADDRESS)) + +/* + * If BOOT_LOAD_PIN is defined the bootloader is started if the selected + * pin is tied LOW. + */ +//#define BOOT_LOAD_PIN PIN_PA21 +//#define BOOT_LOAD_PIN PIN_PA15 + +#define BOOT_USART_MODULE SERCOM5 +#define BOOT_USART_BUS_CLOCK_INDEX PM_APBCMASK_SERCOM5 +#define BOOT_USART_PER_CLOCK_INDEX GCLK_CLKCTRL_ID_SERCOM5_CORE_Val +#define BOOT_USART_PAD_SETTINGS UART_RX_PAD3_TX_PAD2 +#define BOOT_USART_PAD3 PINMUX_PB23D_SERCOM5_PAD3 +#define BOOT_USART_PAD2 PINMUX_PB22D_SERCOM5_PAD2 +#define BOOT_USART_PAD1 PINMUX_UNUSED +#define BOOT_USART_PAD0 PINMUX_UNUSED + +/* Master clock frequency */ +#define CPU_FREQUENCY (48000000ul) +#define VARIANT_MCK CPU_FREQUENCY + +/* Frequency of the board main oscillator */ +#define VARIANT_MAINOSC (32768ul) + +/* Calibration values for DFLL48 pll */ +#define NVM_SW_CALIB_DFLL48M_COARSE_VAL (58) +#define NVM_SW_CALIB_DFLL48M_FINE_VAL (64) + +/* + * LEDs definitions + */ +// PA20 (digital pin 6) +#define BOARD_LED_PORT (0) +#define BOARD_LED_PIN (20) + +// No RX/TX led +//#define BOARD_LEDRX_PORT +//#define BOARD_LEDRX_PIN + +//#define BOARD_LEDTX_PORT +//#define BOARD_LEDTX_PIN + +#endif // _BOARD_DEFINITIONS_H_ diff --git a/bootloaders/zero/board_definitions_arduino_mkrwan1310.h b/bootloaders/zero/board_definitions_arduino_mkrwan1310.h new file mode 100644 index 0000000..7aeb5d3 --- /dev/null +++ b/bootloaders/zero/board_definitions_arduino_mkrwan1310.h @@ -0,0 +1,86 @@ +/* + Copyright (c) 2016 Arduino LLC. 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 _BOARD_DEFINITIONS_H_ +#define _BOARD_DEFINITIONS_H_ + +/* + * USB device definitions + */ +#define STRING_PRODUCT "Arduino MKR WAN 1310" +#define USB_VID_HIGH 0x23 +#define USB_VID_LOW 0x41 +#define USB_PID_HIGH 0x00 +#define USB_PID_LOW 0x59 + +/* + * If BOOT_DOUBLE_TAP_ADDRESS is defined the bootloader is started by + * quickly tapping two times on the reset button. + * BOOT_DOUBLE_TAP_ADDRESS must point to a free SRAM cell that must not + * be touched from the loaded application. + */ +#define BOOT_DOUBLE_TAP_ADDRESS (0x20007FFCul) +#define BOOT_DOUBLE_TAP_DATA (*((volatile uint32_t *) BOOT_DOUBLE_TAP_ADDRESS)) + +/* + * If BOOT_LOAD_PIN is defined the bootloader is started if the selected + * pin is tied LOW. + */ +//#define BOOT_LOAD_PIN PIN_PA21 +//#define BOOT_LOAD_PIN PIN_PA15 + +#define BOOT_USART_MODULE SERCOM5 +#define BOOT_USART_BUS_CLOCK_INDEX PM_APBCMASK_SERCOM5 +#define BOOT_USART_PER_CLOCK_INDEX GCLK_CLKCTRL_ID_SERCOM5_CORE_Val +#define BOOT_USART_PAD_SETTINGS UART_RX_PAD3_TX_PAD2 +#define BOOT_USART_PAD3 PINMUX_PB23D_SERCOM5_PAD3 +#define BOOT_USART_PAD2 PINMUX_PB22D_SERCOM5_PAD2 +#define BOOT_USART_PAD1 PINMUX_UNUSED +#define BOOT_USART_PAD0 PINMUX_UNUSED + +/* Master clock frequency */ +#define CPU_FREQUENCY (48000000ul) +#define VARIANT_MCK CPU_FREQUENCY + +/* Frequency of the board main oscillator */ +#define VARIANT_MAINOSC (32768ul) + +/* Calibration values for DFLL48 pll */ +#define NVM_SW_CALIB_DFLL48M_COARSE_VAL (58) +#define NVM_SW_CALIB_DFLL48M_FINE_VAL (64) + +#define CONFIGURE_PMIC 1 +#define PMIC_PIN_SCL 12 +#define PMIC_PIN_SDA 11 +#define PMIC_SERCOM SERCOM0 + +/* + * LEDs definitions + */ +// PA20 (digital pin 6) +#define BOARD_LED_PORT (0) +#define BOARD_LED_PIN (20) + +// No RX/TX led +//#define BOARD_LEDRX_PORT +//#define BOARD_LEDRX_PIN + +//#define BOARD_LEDTX_PORT +//#define BOARD_LEDTX_PIN + +#endif // _BOARD_DEFINITIONS_H_ diff --git a/bootloaders/zero/board_definitions_arduino_mkrwifi1010.h b/bootloaders/zero/board_definitions_arduino_mkrwifi1010.h new file mode 100644 index 0000000..4feecf9 --- /dev/null +++ b/bootloaders/zero/board_definitions_arduino_mkrwifi1010.h @@ -0,0 +1,86 @@ +/* + Copyright (c) 2016 Arduino LLC. 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 _BOARD_DEFINITIONS_H_ +#define _BOARD_DEFINITIONS_H_ + +/* + * USB device definitions + */ +#define STRING_PRODUCT "Arduino MKR WiFi 1010" +#define USB_VID_HIGH 0x23 +#define USB_VID_LOW 0x41 +#define USB_PID_HIGH 0x00 +#define USB_PID_LOW 0x54 + +/* + * If BOOT_DOUBLE_TAP_ADDRESS is defined the bootloader is started by + * quickly tapping two times on the reset button. + * BOOT_DOUBLE_TAP_ADDRESS must point to a free SRAM cell that must not + * be touched from the loaded application. + */ +#define BOOT_DOUBLE_TAP_ADDRESS (0x20007FFCul) +#define BOOT_DOUBLE_TAP_DATA (*((volatile uint32_t *) BOOT_DOUBLE_TAP_ADDRESS)) + +/* + * If BOOT_LOAD_PIN is defined the bootloader is started if the selected + * pin is tied LOW. + */ +//#define BOOT_LOAD_PIN PIN_PA21 +//#define BOOT_LOAD_PIN PIN_PA15 + +#define BOOT_USART_MODULE SERCOM5 +#define BOOT_USART_BUS_CLOCK_INDEX PM_APBCMASK_SERCOM5 +#define BOOT_USART_PER_CLOCK_INDEX GCLK_CLKCTRL_ID_SERCOM5_CORE_Val +#define BOOT_USART_PAD_SETTINGS UART_RX_PAD3_TX_PAD2 +#define BOOT_USART_PAD3 PINMUX_PB23D_SERCOM5_PAD3 +#define BOOT_USART_PAD2 PINMUX_PB22D_SERCOM5_PAD2 +#define BOOT_USART_PAD1 PINMUX_UNUSED +#define BOOT_USART_PAD0 PINMUX_UNUSED + +/* Master clock frequency */ +#define CPU_FREQUENCY (48000000ul) +#define VARIANT_MCK CPU_FREQUENCY + +/* Frequency of the board main oscillator */ +#define VARIANT_MAINOSC (32768ul) + +/* Calibration values for DFLL48 pll */ +#define NVM_SW_CALIB_DFLL48M_COARSE_VAL (58) +#define NVM_SW_CALIB_DFLL48M_FINE_VAL (64) + +/* + * LEDs definitions + */ +// PA20 (digital pin 6) +#define BOARD_LED_PORT (0) +#define BOARD_LED_PIN (20) + +#define CONFIGURE_PMIC 1 +#define PMIC_PIN_SCL 12 +#define PMIC_PIN_SDA 11 +#define PMIC_SERCOM SERCOM0 + +// No RX/TX led +//#define BOARD_LEDRX_PORT +//#define BOARD_LEDRX_PIN + +//#define BOARD_LEDTX_PORT +//#define BOARD_LEDTX_PIN + +#endif // _BOARD_DEFINITIONS_H_ diff --git a/bootloaders/zero/board_definitions_arduino_mkrzero.h b/bootloaders/zero/board_definitions_arduino_mkrzero.h new file mode 100644 index 0000000..0adfeb6 --- /dev/null +++ b/bootloaders/zero/board_definitions_arduino_mkrzero.h @@ -0,0 +1,81 @@ +/* + Copyright (c) 2016 Arduino LLC. 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 _BOARD_DEFINITIONS_H_ +#define _BOARD_DEFINITIONS_H_ + +/* + * USB device definitions + */ +#define STRING_PRODUCT "Arduino MKRZero" +#define USB_VID_HIGH 0x23 +#define USB_VID_LOW 0x41 +#define USB_PID_HIGH 0x00 +#define USB_PID_LOW 0x4F + +/* + * If BOOT_DOUBLE_TAP_ADDRESS is defined the bootloader is started by + * quickly tapping two times on the reset button. + * BOOT_DOUBLE_TAP_ADDRESS must point to a free SRAM cell that must not + * be touched from the loaded application. + */ +#define BOOT_DOUBLE_TAP_ADDRESS (0x20007FFCul) +#define BOOT_DOUBLE_TAP_DATA (*((volatile uint32_t *) BOOT_DOUBLE_TAP_ADDRESS)) + +/* + * If BOOT_LOAD_PIN is defined the bootloader is started if the selected + * pin is tied LOW. + */ +//#define BOOT_LOAD_PIN PIN_PA21 +//#define BOOT_LOAD_PIN PIN_PA15 + +#define BOOT_USART_MODULE SERCOM5 +#define BOOT_USART_BUS_CLOCK_INDEX PM_APBCMASK_SERCOM5 +#define BOOT_USART_PER_CLOCK_INDEX GCLK_CLKCTRL_ID_SERCOM5_CORE_Val +#define BOOT_USART_PAD_SETTINGS UART_RX_PAD3_TX_PAD2 +#define BOOT_USART_PAD3 PINMUX_PB23D_SERCOM5_PAD3 +#define BOOT_USART_PAD2 PINMUX_PB22D_SERCOM5_PAD2 +#define BOOT_USART_PAD1 PINMUX_UNUSED +#define BOOT_USART_PAD0 PINMUX_UNUSED + +/* Master clock frequency */ +#define CPU_FREQUENCY (48000000ul) +#define VARIANT_MCK CPU_FREQUENCY + +/* Frequency of the board main oscillator */ +#define VARIANT_MAINOSC (32768ul) + +/* Calibration values for DFLL48 pll */ +#define NVM_SW_CALIB_DFLL48M_COARSE_VAL (58) +#define NVM_SW_CALIB_DFLL48M_FINE_VAL (64) + +/* + * LEDs definitions + */ +// PB08 (digital pin 32) +#define BOARD_LED_PORT (1) +#define BOARD_LED_PIN (8) + +// No RX/TX led +//#define BOARD_LEDRX_PORT +//#define BOARD_LEDRX_PIN + +//#define BOARD_LEDTX_PORT +//#define BOARD_LEDTX_PIN + +#endif // _BOARD_DEFINITIONS_H_ diff --git a/bootloaders/zero/board_definitions_arduino_nano_33_iot.h b/bootloaders/zero/board_definitions_arduino_nano_33_iot.h new file mode 100644 index 0000000..5917b91 --- /dev/null +++ b/bootloaders/zero/board_definitions_arduino_nano_33_iot.h @@ -0,0 +1,82 @@ +/* + Copyright (c) 2016 Arduino LLC. 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 _BOARD_DEFINITIONS_H_ +#define _BOARD_DEFINITIONS_H_ + +/* + * USB device definitions + */ +#define STRING_PRODUCT "Arduino Nano 33 IoT" +#define USB_VID_HIGH 0x23 +#define USB_VID_LOW 0x41 +#define USB_PID_HIGH 0x00 +#define USB_PID_LOW 0x57 + +/* + * If BOOT_DOUBLE_TAP_ADDRESS is defined the bootloader is started by + * quickly tapping two times on the reset button. + * BOOT_DOUBLE_TAP_ADDRESS must point to a free SRAM cell that must not + * be touched from the loaded application. + */ +#define BOOT_DOUBLE_TAP_ADDRESS (0x20007FFCul) +#define BOOT_DOUBLE_TAP_DATA (*((volatile uint32_t *) BOOT_DOUBLE_TAP_ADDRESS)) + +/* + * If BOOT_LOAD_PIN is defined the bootloader is started if the selected + * pin is tied LOW. + */ +//#define BOOT_LOAD_PIN PIN_PA21 +//#define BOOT_LOAD_PIN PIN_PA15 + +#define BOOT_USART_MODULE SERCOM5 +#define BOOT_USART_BUS_CLOCK_INDEX PM_APBCMASK_SERCOM5 +#define BOOT_USART_PER_CLOCK_INDEX GCLK_CLKCTRL_ID_SERCOM5_CORE_Val +#define BOOT_USART_PAD_SETTINGS UART_RX_PAD3_TX_PAD2 +#define BOOT_USART_PAD3 PINMUX_PB23D_SERCOM5_PAD3 +#define BOOT_USART_PAD2 PINMUX_PB22D_SERCOM5_PAD2 +#define BOOT_USART_PAD1 PINMUX_UNUSED +#define BOOT_USART_PAD0 PINMUX_UNUSED + +/* Master clock frequency */ +#define CPU_FREQUENCY (48000000ul) +#define VARIANT_MCK CPU_FREQUENCY + +/* Frequency of the board main oscillator */ +#define VARIANT_MAINOSC (32768ul) +#define CRYSTALLESS (1) + +/* Calibration values for DFLL48 pll */ +#define NVM_SW_CALIB_DFLL48M_COARSE_VAL (58) +#define NVM_SW_CALIB_DFLL48M_FINE_VAL (64) + +/* + * LEDs definitions + */ +// PA20 (digital pin 6) +#define BOARD_LED_PORT (0) +#define BOARD_LED_PIN (17) + +// No RX/TX led +//#define BOARD_LEDRX_PORT +//#define BOARD_LEDRX_PIN + +//#define BOARD_LEDTX_PORT +//#define BOARD_LEDTX_PIN + +#endif // _BOARD_DEFINITIONS_H_ diff --git a/bootloaders/zero/board_definitions_arduino_zero.h b/bootloaders/zero/board_definitions_arduino_zero.h new file mode 100644 index 0000000..eac27b7 --- /dev/null +++ b/bootloaders/zero/board_definitions_arduino_zero.h @@ -0,0 +1,81 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 _BOARD_DEFINITIONS_H_ +#define _BOARD_DEFINITIONS_H_ + +/* + * USB device definitions + */ +#define STRING_PRODUCT "Arduino Zero" +#define USB_VID_HIGH 0x23 +#define USB_VID_LOW 0x41 +#define USB_PID_HIGH 0x00 +#define USB_PID_LOW 0x4D + +/* + * If BOOT_DOUBLE_TAP_ADDRESS is defined the bootloader is started by + * quickly tapping two times on the reset button. + * BOOT_DOUBLE_TAP_ADDRESS must point to a free SRAM cell that must not + * be touched from the loaded application. + */ +#define BOOT_DOUBLE_TAP_ADDRESS (0x20007FFCul) +#define BOOT_DOUBLE_TAP_DATA (*((volatile uint32_t *) BOOT_DOUBLE_TAP_ADDRESS)) + +/* + * If BOOT_LOAD_PIN is defined the bootloader is started if the selected + * pin is tied LOW. + */ +//#define BOOT_LOAD_PIN PIN_PA21 // Pin 7 +//#define BOOT_LOAD_PIN PIN_PA15 // Pin 5 + +#define BOOT_USART_MODULE SERCOM0 +#define BOOT_USART_BUS_CLOCK_INDEX PM_APBCMASK_SERCOM0 +#define BOOT_USART_PER_CLOCK_INDEX GCLK_CLKCTRL_ID_SERCOM0_CORE_Val +#define BOOT_USART_PAD_SETTINGS UART_RX_PAD3_TX_PAD2 +#define BOOT_USART_PAD3 PINMUX_PA11C_SERCOM0_PAD3 +#define BOOT_USART_PAD2 PINMUX_PA10C_SERCOM0_PAD2 +#define BOOT_USART_PAD1 PINMUX_UNUSED +#define BOOT_USART_PAD0 PINMUX_UNUSED + + +/* Master clock frequency */ +#define CPU_FREQUENCY (48000000ul) +#define VARIANT_MCK CPU_FREQUENCY + +/* Frequency of the board main oscillator */ +#define VARIANT_MAINOSC (32768ul) + +/* Calibration values for DFLL48 pll */ +#define NVM_SW_CALIB_DFLL48M_COARSE_VAL (58) +#define NVM_SW_CALIB_DFLL48M_FINE_VAL (64) + +/* + * LEDs definitions + */ +#define BOARD_LED_PORT (0) +#define BOARD_LED_PIN (17) + +#define BOARD_LEDRX_PORT (1) +#define BOARD_LEDRX_PIN (3) + +#define BOARD_LEDTX_PORT (0) +#define BOARD_LEDTX_PIN (27) + +#endif // _BOARD_DEFINITIONS_H_ diff --git a/bootloaders/zero/board_driver_i2c.c b/bootloaders/zero/board_driver_i2c.c new file mode 100644 index 0000000..9fab995 --- /dev/null +++ b/bootloaders/zero/board_driver_i2c.c @@ -0,0 +1,449 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 +*/ + +#include "board_driver_i2c.h" + +#ifdef CONFIGURE_PMIC + +/*- Definitions -------------------------------------------------------------*/ +#define I2C_SERCOM SERCOM0 +#define I2C_SERCOM_GCLK_ID GCLK_CLKCTRL_ID_SERCOM0_CORE_Val +#define I2C_SERCOM_CLK_GEN 0 +#define I2C_SERCOM_APBCMASK PM_APBCMASK_SERCOM0 + +static uint8_t txBuffer[2]; +uint8_t rxBuffer[1]; +static uint8_t txBufferLen = 0; +static uint8_t rxBufferLen = 0; +static uint8_t txAddress; + +typedef enum +{ + WIRE_UNKNOWN_STATE = 0x0ul, + WIRE_IDLE_STATE, + WIRE_OWNER_STATE, + WIRE_BUSY_STATE +} SercomWireBusState; + +typedef enum +{ + WIRE_WRITE_FLAG = 0x0ul, + WIRE_READ_FLAG +} SercomWireReadWriteFlag; + +typedef enum +{ + WIRE_MASTER_ACT_NO_ACTION = 0, + WIRE_MASTER_ACT_REPEAT_START, + WIRE_MASTER_ACT_READ, + WIRE_MASTER_ACT_STOP +} SercomMasterCommandWire; + +typedef enum +{ + WIRE_MASTER_ACK_ACTION = 0, + WIRE_MASTER_NACK_ACTION +} SercomMasterAckActionWire; + +typedef enum +{ + I2C_SLAVE_OPERATION = 0x4u, + I2C_MASTER_OPERATION = 0x5u +} SercomI2CMode; + +static inline void pin_set_peripheral_function(uint32_t pinmux) +{ + /* the variable pinmux consist of two components: + 31:16 is a pad, wich includes: + 31:21 : port information 0->PORTA, 1->PORTB + 20:16 : pin 0-31 + 15:00 pin multiplex information + there are defines for pinmux like: PINMUX_PA09D_SERCOM2_PAD1 + */ + uint16_t pad = pinmux >> 16; // get pad (port+pin) + uint8_t port = pad >> 5; // get port + uint8_t pin = pad & 0x1F; // get number of pin - no port information anymore + + PORT->Group[port].PINCFG[pin].bit.PMUXEN =1; + + /* each pinmux register is for two pins! with pin/2 you can get the index of the needed pinmux register + the p mux resiter is 8Bit (7:4 odd pin; 3:0 evan bit) */ + // reset pinmux values. VV shift if pin is odd (if evan: (4*(pin & 1))==0 ) + PORT->Group[port].PMUX[pin/2].reg &= ~( 0xF << (4*(pin & 1)) ); + // + // set new values + PORT->Group[port].PMUX[pin/2].reg |= ( (uint8_t)( (pinmux&0xFFFF) <<(4*(pin&1)) ) ); +} + +static inline void initClockNVIC( void ) +{ + //Setting clock + GCLK->CLKCTRL.reg = GCLK_CLKCTRL_ID( I2C_SERCOM_GCLK_ID ) | // Generic Clock 0 (SERCOMx) + GCLK_CLKCTRL_GEN_GCLK0 | // Generic Clock Generator 0 is source + GCLK_CLKCTRL_CLKEN ; + + while ( GCLK->STATUS.reg & GCLK_STATUS_SYNCBUSY ) + { + /* Wait for synchronization */ + } + PM->APBCMASK.reg |= PM_APBCMASK_SERCOM0; +} + +static inline bool isBusIdleWIRE( void ) +{ + return I2C_SERCOM->I2CM.STATUS.bit.BUSSTATE == WIRE_IDLE_STATE; +} + +static inline bool isBusOwnerWIRE( void ) +{ + return I2C_SERCOM->I2CM.STATUS.bit.BUSSTATE == WIRE_OWNER_STATE; +} + +static inline bool isDataReadyWIRE( void ) +{ + return I2C_SERCOM->I2CS.INTFLAG.bit.DRDY; +} + +static inline bool isStopDetectedWIRE( void ) +{ + return I2C_SERCOM->I2CS.INTFLAG.bit.PREC; +} + +static inline bool isRestartDetectedWIRE( void ) +{ + return I2C_SERCOM->I2CS.STATUS.bit.SR; +} + +static inline bool isAddressMatch( void ) +{ + return I2C_SERCOM->I2CS.INTFLAG.bit.AMATCH; +} + +static inline bool isMasterReadOperationWIRE( void ) +{ + return I2C_SERCOM->I2CS.STATUS.bit.DIR; +} + +static inline bool isRXNackReceivedWIRE( void ) +{ + return I2C_SERCOM->I2CM.STATUS.bit.RXNACK; +} + +static inline int availableWIRE( void ) +{ + return I2C_SERCOM->I2CM.INTFLAG.bit.SB; +} + +static inline uint8_t readDataWIRE( void ) +{ + while( I2C_SERCOM->I2CM.INTFLAG.bit.SB == 0 ) + { + // Waiting complete receive + } + + return I2C_SERCOM->I2CM.DATA.bit.DATA ; +} + +/* ========================= + * ===== Sercom WIRE + * ========================= + */ +static inline void resetWIRE() +{ + //I2CM OR I2CS, no matter SWRST is the same bit. + + //Setting the Software bit to 1 + I2C_SERCOM->I2CM.CTRLA.bit.SWRST = 1; + + //Wait both bits Software Reset from CTRLA and SYNCBUSY are equal to 0 + while(I2C_SERCOM->I2CM.CTRLA.bit.SWRST || I2C_SERCOM->I2CM.SYNCBUSY.bit.SWRST); +} + +static inline void enableWIRE() +{ + // I2C Master and Slave modes share the ENABLE bit function. + + // Enable the I²C master mode + I2C_SERCOM->I2CM.CTRLA.bit.ENABLE = 1 ; + + while ( I2C_SERCOM->I2CM.SYNCBUSY.bit.ENABLE != 0 ) + { + // Waiting the enable bit from SYNCBUSY is equal to 0; + } + + // Setting bus idle mode + I2C_SERCOM->I2CM.STATUS.bit.BUSSTATE = 1 ; + + while ( I2C_SERCOM->I2CM.SYNCBUSY.bit.SYSOP != 0 ) + { + // Wait the SYSOP bit from SYNCBUSY coming back to 0 + } +} + +static inline void disableWIRE() +{ + // I2C Master and Slave modes share the ENABLE bit function. + + // Enable the I²C master mode + I2C_SERCOM->I2CM.CTRLA.bit.ENABLE = 0 ; + + while ( I2C_SERCOM->I2CM.SYNCBUSY.bit.ENABLE != 0 ) + { + // Waiting the enable bit from SYNCBUSY is equal to 0; + } +} + +static inline void initMasterWIRE( uint32_t baudrate ) +{ + // Initialize the peripheral clock and interruption + initClockNVIC() ; + + //NVIC_EnableIRQ(SERCOM0_IRQn); + //NVIC_SetPriority (SERCOM0_IRQn, (1<<__NVIC_PRIO_BITS) - 1); /* set Priority */ + + resetWIRE() ; + + // Set master mode and enable SCL Clock Stretch mode (stretch after ACK bit) + I2C_SERCOM->I2CM.CTRLA.reg = SERCOM_I2CM_CTRLA_MODE( I2C_MASTER_OPERATION )/* | + SERCOM_I2CM_CTRLA_SCLSM*/ ; + + // Enable Smart mode and Quick Command + //I2C_SERCOM->I2CM.I2CM.CTRLB.reg = SERCOM_I2CM_CTRLB_SMEN /*| SERCOM_I2CM_CTRLB_QCEN*/ ; + + + // Enable all interrupts + //I2C_SERCOM->I2CM.INTENSET.reg = SERCOM_I2CM_INTENSET_MB | SERCOM_I2CM_INTENSET_SB | SERCOM_I2CM_INTENSET_ERROR ; + + // Synchronous arithmetic baudrate + I2C_SERCOM->I2CM.BAUD.bit.BAUD = 48000000 / ( 2 * baudrate) - 1 ; +} + +static inline void prepareNackBitWIRE( void ) +{ + // Send a NACK + I2C_SERCOM->I2CM.CTRLB.bit.ACKACT = 1; +} + +static inline void prepareAckBitWIRE( void ) +{ + // Send an ACK + I2C_SERCOM->I2CM.CTRLB.bit.ACKACT = 0; +} + +static inline int prepareCommandBitsWire(uint8_t cmd) +{ + I2C_SERCOM->I2CM.CTRLB.bit.CMD = cmd; + + int timeout = 50000; + while(I2C_SERCOM->I2CM.SYNCBUSY.bit.SYSOP) + { + if (timeout -- < 0) { + return -1; + } + // Waiting for synchronization + } + return 0; +} + +static inline bool startTransmissionWIRE(uint8_t address, SercomWireReadWriteFlag flag) +{ + // 7-bits address + 1-bits R/W + address = (address << 0x1ul) | flag; + + int timeout = 50000; + + // Wait idle or owner bus mode + while ( !isBusIdleWIRE() && !isBusOwnerWIRE() ) { + if (timeout -- < 0) { + return false; + } + } + + // Send start and address + I2C_SERCOM->I2CM.ADDR.bit.ADDR = address; + + // Address Transmitted + if ( flag == WIRE_WRITE_FLAG ) // Write mode + { + while( !I2C_SERCOM->I2CM.INTFLAG.bit.MB ) + { + if (timeout -- < 0) { + return false; + } + // Wait transmission complete + } + } + else // Read mode + { + while( !I2C_SERCOM->I2CM.INTFLAG.bit.SB ) + { + if (timeout -- < 0) { + return false; + } + // If the slave NACKS the address, the MB bit will be set. + // In that case, send a stop condition and return false. + if (I2C_SERCOM->I2CM.INTFLAG.bit.MB) { + I2C_SERCOM->I2CM.CTRLB.bit.CMD = 3; // Stop condition + return false; + } + // Wait transmission complete + } + + // Clean the 'Slave on Bus' flag, for further usage. + //I2C_SERCOM->I2CM.I2CM.INTFLAG.bit.SB = 0x1ul; + } + + + //ACK received (0: ACK, 1: NACK) + if(I2C_SERCOM->I2CM.STATUS.bit.RXNACK) + { + return false; + } + else + { + return true; + } +} + +static inline bool sendDataMasterWIRE(uint8_t data) +{ + //Send data + I2C_SERCOM->I2CM.DATA.bit.DATA = data; + + int timeout = 50000; + + //Wait transmission successful + while(!I2C_SERCOM->I2CM.INTFLAG.bit.MB) { + + if (timeout -- < 0) { + return false; + } + // If a bus error occurs, the MB bit may never be set. + // Check the bus error bit and bail if it's set. + if (I2C_SERCOM->I2CM.STATUS.bit.BUSERR) { + return false; + } + } + + //Problems on line? nack received? + if(I2C_SERCOM->I2CM.STATUS.bit.RXNACK) + return false; + else + return true; +} + +void i2c_init(uint32_t baud) { + //Master Mode + initMasterWIRE(baud); + enableWIRE(); + + pin_set_peripheral_function(PINMUX_PA08C_SERCOM0_PAD0); + pin_set_peripheral_function(PINMUX_PA09C_SERCOM0_PAD1); +} + +void i2c_end() { + disableWIRE(); +} + +uint8_t i2c_requestFrom(uint8_t address, uint8_t quantity, bool stopBit) +{ + if(quantity == 0) + { + return 0; + } + + uint8_t byteRead = 0; + + rxBufferLen = 0;; + + if(startTransmissionWIRE(address, WIRE_READ_FLAG)) + { + // Read first data + rxBuffer[rxBufferLen++] = readDataWIRE(); + + // Connected to slave + for (byteRead = 1; byteRead < quantity; ++byteRead) + { + prepareAckBitWIRE(); // Prepare Acknowledge + prepareCommandBitsWire(WIRE_MASTER_ACT_READ); // Prepare the ACK command for the slave + rxBuffer[rxBufferLen++] = readDataWIRE(); // Read data and send the ACK + } + prepareNackBitWIRE(); // Prepare NACK to stop slave transmission + //I2C_SERCOM->I2CM.readDataWIRE(); // Clear data register to send NACK + + if (stopBit) + { + prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); // Send Stop + } + } + + return byteRead; +} + +void i2c_beginTransmission(uint8_t address) { + // save address of target and clear buffer + txAddress = address; + txBufferLen = 0; +} + +// Errors: +// 0 : Success +// 1 : Data too long +// 2 : NACK on transmit of address +// 3 : NACK on transmit of data +// 4 : Other error +uint8_t i2c_endTransmission(bool stopBit) +{ + + // Start I2C transmission + if ( !startTransmissionWIRE( txAddress, WIRE_WRITE_FLAG ) ) + { + prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); + return 2 ; // Address error + } + + // Send all buffer + int tempLen = txBufferLen; + while( txBufferLen > 0 ) + { + // Trying to send data + if ( !sendDataMasterWIRE( txBuffer[tempLen-txBufferLen] ) ) + { + prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); + return 3 ; // Nack or error + } else { + txBufferLen--; + } + } + + if (stopBit) + { + prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); + } + + return 0; +} + +uint8_t i2c_write(uint8_t ucData) +{ + txBuffer[txBufferLen++] = ucData ; + return 1 ; +} + +#endif diff --git a/bootloaders/zero/board_driver_i2c.h b/bootloaders/zero/board_driver_i2c.h new file mode 100644 index 0000000..f6b206f --- /dev/null +++ b/bootloaders/zero/board_driver_i2c.h @@ -0,0 +1,35 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 _BOARD_DRIVER_I2C_ +#define _BOARD_DRIVER_I2C_ + +#include +#include +#include "board_definitions.h" + +void i2c_init(uint32_t baud); +void i2c_end(); +uint8_t i2c_requestFrom(uint8_t address, uint8_t quantity, bool stopBit); +void i2c_beginTransmission(uint8_t address); +uint8_t i2c_endTransmission(bool stopBit); +uint8_t i2c_write(uint8_t ucData); + + +#endif // _BOARD_DRIVER_I2C_ diff --git a/bootloaders/zero/board_driver_jtag.c b/bootloaders/zero/board_driver_jtag.c new file mode 100644 index 0000000..426ad68 --- /dev/null +++ b/bootloaders/zero/board_driver_jtag.c @@ -0,0 +1,769 @@ +#include "board_driver_jtag.h" +#include + +#ifdef ENABLE_JTAG_LOAD + +/* JTAG State Machine */ +const int JSM[16][2] = { + /*-State- -mode= '0'- -mode= '1'- */ + /*RESET */ {JS_RUNIDLE, JS_RESET }, + /*RUNIDLE */ {JS_RUNIDLE, JS_SELECT_DR}, + /*SELECTIR */ {JS_CAPTURE_IR, JS_RESET }, + /*CAPTURE_IR*/ {JS_SHIFT_IR, JS_EXIT1_IR }, + /*SHIFT_IR */ {JS_SHIFT_IR, JS_EXIT1_IR }, + /*EXIT1_IR */ {JS_PAUSE_IR, JS_UPDATE_IR}, + /*PAUSE_IR */ {JS_PAUSE_IR, JS_EXIT2_IR }, + /*EXIT2_IR */ {JS_SHIFT_IR, JS_UPDATE_IR}, + /*UPDATE_IR */ {JS_RUNIDLE, JS_SELECT_DR}, + /*SELECT_DR */ {JS_CAPTURE_DR, JS_SELECT_IR}, + /*CAPTURE_DR*/ {JS_SHIFT_DR, JS_EXIT1_DR }, + /*SHIFT_DR */ {JS_SHIFT_DR, JS_EXIT1_DR }, + /*EXIT1_DR */ {JS_PAUSE_DR, JS_UPDATE_DR}, + /*PAUSE_DR */ {JS_PAUSE_DR, JS_EXIT2_DR }, + /*EXIT2_DR */ {JS_SHIFT_DR, JS_UPDATE_DR}, + /*UPDATE_DR */ {JS_RUNIDLE, JS_SELECT_DR} +}; + + +static struct states { + unsigned char state; + unsigned char nSlaves; + unsigned char slaveBits; + unsigned char virSize; + unsigned char id; + unsigned char lastVir; +} jtag; + +void port_pin_set_output_level(int pin, int level) { + if (level) { + outpin_on(pin); + } else { + outpin_off(pin); + } +} + +int port_pin_get_input_level(int pin) { + return inpin_get(pin); +} + + + +/******************************************************************/ +/* Name: DriveSignal */ +/* */ +/* Parameters: signal,data,clk,buffer_enable */ +/* -the name of the signal (SIG_*). */ +/* -the value to be dumped to the signal,'1' or '0' */ +/* -driving a LOW to HIGH transition to SIG_TCK */ +/* together with signal. */ +/* -buffer_enable is used by WritePort function. */ +/* -If "buffer_enable"=1, */ +/* -processes in "port_io_buffer" are flushed when */ +/* -"PORT_IO_BUFFER_SIZE" is reached. */ +/* -If "buffer_enable"=0, */ +/* -"data" is dumped to port 0 at once */ +/* */ +/* Return Value: None. */ +/* */ +/* Descriptions: Dump data to signal. If clk is '1', a clock pulse*/ +/* is driven after the data is dumped to signal. */ +/* */ +/******************************************************************/ +static void DriveSignal(int signal, int data, int clk) +{ + + port_pin_set_output_level (signal, data); + + if (clk) + { + port_pin_set_output_level (TCK, 1); + port_pin_set_output_level (TCK, 0); + } +} + + +/******************************************************************/ +/* Name: ReadTDO */ +/* */ +/* Parameters: bit_count,data,inst */ +/* -bit_count is the number of bits to shift out. */ +/* -data is the value to shift in from lsb to msb. */ +/* -inst determines if the data is an instruction. */ +/* if inst=1,the number of bits shifted in/out */ +/* equals to bit_count-1;if not,the number of bits */ +/* does not change. */ +/* */ +/* Return Value: The data shifted out from TDO. The first bit */ +/* shifted out is placed at the lsb of the returned */ +/* integer. */ +/* */ +/* Descriptions: Shift out bit_count bits from TDO while shift in */ +/* data to TDI. During instruction loading, the */ +/* number of shifting equals to the instruction */ +/* length minus 1 */ +/* */ +/******************************************************************/ + +static int ReadTDO(int bit_count, int data, int inst) +{ + unsigned int record = 0; + unsigned int i; + + for (i = 0; i < bit_count; i++) + { + record = record | (port_pin_get_input_level(TDO) << i); + + DriveSignal( + TDI, + data & 1, + !(i == (bit_count - 1) && inst) + ); + + data >>= 1; + } + return record; +} /* + int ReadTDO(int bit_count,int data,int inst) + { + unsigned int tdi=0,tdo=0,record=0; + unsigned int i; + + for(i=0;i> i; + if (i==(bit_count-1) && inst) + DriveSignal(PIN_TDI,tdi,0); + else + DriveSignal(PIN_TDI,tdi,1); + } + return record; + } +*/ +/******************************************************************/ +/* Name: ReadTDO */ +/* */ +/* Parameters: bit_count,data,inst */ +/* -bit_count is the number of bits to shift out. */ +/* -data is the value to shift in from lsb to msb. */ +/* -inst determines if the data is an instruction. */ +/* if inst=1,the number of bits shifted in/out */ +/* equals to bit_count-1;if not,the number of bits */ +/* does not change. */ +/* */ +/* Return Value: The data shifted out from TDO. The first bit */ +/* shifted out is placed at the lsb of the returned */ +/* integer. */ +/* */ +/* Descriptions: Shift out bit_count bits from TDO while shift in */ +/* data to TDI. During instruction loading, the */ +/* number of shifting equals to the instruction */ +/* length minus 1 */ +/* */ +/******************************************************************/ +static void ReadTDOBuf(int bit_count, char *txbuf, char *rxbuf, int inst) +{ + unsigned int tdi = 0, tdo = 0, record = 0; + unsigned int i; + unsigned int charbit = 0; + unsigned char indata, outdata; + indata = 0; + for (i = 0; i < bit_count; i++) + { + unsigned int mask = 1; + + if (charbit == 0) + if (txbuf) + outdata = *txbuf++; + else + outdata = -1; + + indata = (indata >> 1) | (port_pin_get_input_level (TDO) << 7); + + DriveSignal( TDI, + outdata & 1, + !(i == (bit_count - 1) && inst) + ); + outdata = outdata >> 1; + charbit = (charbit + 1) & 7; + if (charbit == 0 && rxbuf) + { + *rxbuf++ = indata; + indata = 0; + } + } +} + +/******************************************************************/ +/* Name: AdvanceJSM */ +/* */ +/* Parameters: mode */ +/* -the input mode to JSM. */ +/* */ +/* Return Value: The current JSM state. */ +/* */ +/* Descriptions: Function that keep track of the JSM state. It */ +/* drives out signals to TMS associated with a */ +/* clock pulse at TCK and updates the current state */ +/* variable. */ +/* */ +/******************************************************************/ +static int AdvanceJSM(int mode) +{ + DriveSignal(TMS, mode, 1); + + jtag.state = JSM[jtag.state][mode]; + + return (jtag.state); +} + +/******************************************************************/ +/* Name: Js_Updatedr */ +/* */ +/* Parameters: None. */ +/* */ +/* Return Value: 1 if the current state is not SHIFT_DR;0 if the */ +/* operation is successful. */ +/* */ +/* Descriptions: Move the JSM to UPDATE_DR. The current state is */ +/* expected to be SHIFT_DR */ +/* */ +/******************************************************************/ +static int Js_Updatedr() +{ + /* The current JSM state must be in UPDATE_IR or UPDATE_DR */ + if (jtag.state != JS_SHIFT_DR) + return (1); + + AdvanceJSM(1); + AdvanceJSM(1); + + return (0); +} + +/******************************************************************/ +/* Name: Js_Shiftdr */ +/* */ +/* Parameters: None. */ +/* */ +/* Return Value: 1 if the current state is not UPDATE_DR or */ +/* UPDATE_IR. 0 if the opeation is successful. */ +/* */ +/* Descriptions: Move the JSM to SHIFT_DR. The current state is */ +/* expected to be UPDATE_DR or UPDATE_IR. */ +/* */ +/******************************************************************/ +static int Js_Shiftdr() +{ + /* The current JSM state must be in UPDATE_IR or UPDATE_DR */ + if (jtag.state != JS_UPDATE_DR && jtag.state != JS_UPDATE_IR) + { + if (jtag.state != JS_RESET && jtag.state != JS_RUNIDLE) + return (1); + else + { + AdvanceJSM(0); + AdvanceJSM(0); + AdvanceJSM(1); + AdvanceJSM(0); + AdvanceJSM(0); + + return (0); + } + } + + AdvanceJSM(1); + AdvanceJSM(0); + AdvanceJSM(0); + + return (0); +} + +/******************************************************************/ +/* Name: Js_Reset */ +/* */ +/* Parameters: None. */ +/* */ +/* Return Value: None. */ +/* */ +/* Descriptions: Reset the JSM by issuing JSM_RESET_COUNT of clock*/ +/* with the TMS at HIGH. */ +/* */ +/******************************************************************/ +static void Js_Reset() +{ + int i; + + for (i = 0; i < JSM_RESET_COUNT; i++) + AdvanceJSM(1); +} + +/******************************************************************/ +/* Name: Runidle */ +/* */ +/* Parameters: None. */ +/* */ +/* Return Value: None. */ +/* */ +/* Descriptions: If the current JSM is not at UPDATE_DR or */ +/* UPDATE_IR state, RESET JSM and move to RUNIDLE, */ +/* if it is, clock once with TMS LOW and move to */ +/* RUNIDLE. */ +/* */ +/******************************************************************/ +static void Js_Runidle() +{ + int i = 0; + + /* If the current state is not UPDATE_DR or UPDATE_IR, reset the JSM and move to RUN/IDLE */ + if (jtag.state != JS_UPDATE_IR && jtag.state != JS_UPDATE_DR) + { + for (i = 0; i < JSM_RESET_COUNT; i++) + AdvanceJSM(1); + } + + AdvanceJSM(0); +} + +/******************************************************************/ +/* Name: LoadJI */ +/* */ +/* Parameters: action,dev_count,ji_info */ +/* -action is the JTAG instruction to load */ +/* -dev_count is the maximum number of devices in */ +/* chain. */ +/* -ji_info is the pointer to an integer array that */ +/* contains the JTAG instruction length for the */ +/* devices in chain. */ +/* */ +/* Return Value: 1 if contains error;0 if not. */ +/* */ +/* Descriptions: Move the JSM to SHIFT_IR. Load in the JTAG */ +/* instruction to all devices in chain. Then */ +/* advance the JSM to UPDATE_IR. Irrespective of */ +/* */ +/******************************************************************/ +static int LoadJI(int action) +{ + int i, record = 0, error = 0; + + /* Move Jtag State Machine (JSM) to RUN/IDLE */ + if (jtag.state != JS_RUNIDLE && jtag.state != JS_RESET) + Js_Runidle(); + + /* Move JSM to SHIFT_IR */ + AdvanceJSM(0); + AdvanceJSM(1); + AdvanceJSM(1); + AdvanceJSM(0); + AdvanceJSM(0); + + record = ReadTDO(INST_LEN, action, 1); + if (record != 0x155) + { + error = -1; + // fprintf(stderr,"Error: JTAG chain broken!\nError: Bits unloaded: 0x%X\n", record); + return error; + } + + /* Move JSM to UPDATE_IR */ + AdvanceJSM(1); + AdvanceJSM(1); + + return error; +} + +/******************************************************************/ +/* Name: SetupChain */ +/* */ +/* Parameters: dev_count,dev_seq,ji_info,action */ +/* -device_count is the total device in chain */ +/* -dev_seq is the device sequence in chain */ +/* -ji_info is the pointer to an integer array that */ +/* contains the JTAG instruction length for the */ +/* devices in chain. */ +/* -action is the JTAG instruction to load */ +/* */ +/* Return Value: None. */ +/* */ +/* Descriptions: Move the JSM to SHIFT_IR. Issue the JTAG */ +/* instruction, "action" to the target device and */ +/* BYPASS to the rest of the devices. Then, move */ +/* the JSM to UPDATE_IR. */ +/* */ +/******************************************************************/ +static void SetupChain(int action) +{ + int i, record = 0; + /* Move Jtag State Machine (JSM) to RUN/IDLE */ + if (jtag.state != JS_RUNIDLE && jtag.state != JS_RESET) + Js_Runidle(); + + /* Move JSM to SHIFT_IR */ + AdvanceJSM(0); + AdvanceJSM(1); + AdvanceJSM(1); + AdvanceJSM(0); + AdvanceJSM(0); + + record = ReadTDO(INST_LEN, action, 1); + + /* Move JSM to UPDATE_IR */ + AdvanceJSM(1); + AdvanceJSM(1); +} + +/******************************************************************/ +/* Name: CheckStatus */ +/* */ +/* Parameters: dev_seq */ +/* -dev_seq is the device sequence in chains. */ +/* */ +/* Return Value: '0' if CONF_DONE is HIGH;'1' if it is LOW. */ +/* */ +/* Descriptions: Issue CHECK_STATUS instruction to the device to */ +/* be configured and BYPASS for the rest of the */ +/* devices. */ +/* */ +/* = */ +/* (( - */ +/* )*3) + 1 */ +/* */ +/* The formula calculates the number of bits */ +/* to be shifted out from the device, excluding the */ +/* 1-bit register for each device in BYPASS mode. */ +/* */ +/******************************************************************/ +int CheckStatus() +{ + int bit,data=0,error=0; + int jseq_max=0,jseq_conf_done=0,conf_done_bit=0; + + // fprintf( stdout, "Info: Checking Status\n" ); + + /* Load CHECK_STATUS instruction */ + SetupChain(JI_CHECK_STATUS); + + Js_Shiftdr(); + + /* Maximum JTAG sequence of the device in chain */ + jseq_max= JSEQ_MAX; + + jseq_conf_done= JSEQ_CONF_DONE; + + conf_done_bit = ((jseq_max-jseq_conf_done)*3)+1; + + /* Compensate for 1 bit unloaded from every Bypass register */ + conf_done_bit+= 0; + + for(bit=0;bit> 4) | (ReadTDO(4, 0x0, 0) << 28); + Js_Updatedr(); + Js_Runidle(); + } + jtag.id = -1; + jtag.lastVir = -1; + if (((record >> 8) & 0x7ff) == JTAG_VENDOR_ID) + { + jtag.nSlaves = (record >> 19) & 0xff; // number of jtag slaves + for (jtag.slaveBits = 0; (1 << jtag.slaveBits) < (jtag.nSlaves + 1); jtag.slaveBits++); + + jtag.virSize = record & 0xff; + for (j = 0; j < jtag.nSlaves; j++) + { + record = 0; + for (i = 0; i < 8; i++) + { + Js_Shiftdr(); + record = (record >> 4) | (ReadTDO(4, 0x0, 0) << 28); + Js_Updatedr(); + Js_Runidle(); + } + if (((record >> 19) & 0xff) == JTAG_ID_VJTAG && ((record >> 8) & 0x7ff) == JTAG_VENDOR_ID) + { + jtag.id = j; + return 0; + } + } + } + } + return -1; +} + +void jtagDeinit(void) +{ + jtag.id = -1; +} + +int jtagReload() { + int ret = LoadJI(JI_PULSE_NCONFIG); + Js_Shiftdr(); + return ret; +} + +int jtagWriteBuffer(unsigned int address, const uint8_t *data, size_t len) +{ + int ret = 0; + ret = jtagVIR(JBC_WRITE); + if (ret < 0) { + return ret; + } + LoadJI(JI_USER0_VDR); + Js_Shiftdr(); + address = (address << 2) | 0x00000003; + ReadTDOBuf(32, &address, 0, 0); + ReadTDOBuf(32 * len+2, data, 0, 0); + return len; +} + +int jtagReadBuffer(unsigned int address, uint8_t *data, size_t len) +{ + int ret = 0; + ret = jtagVIR(JBC_WRITE); + if (ret < 0) { + return ret; + } + LoadJI(JI_USER0_VDR); + Js_Shiftdr(); + address = (address << 2) | 0x00000003; + ReadTDOBuf(32, &address, 0, 0); + if (len > 1) + { + address = len - 1; + ReadTDOBuf(4, &address, 0, 1); + } + ret = jtagVIR(JBC_READ); + if (ret < 0) { + return ret; + } + LoadJI(JI_USER0_VDR); + Js_Shiftdr(); + for (; len > 0; len--) + { + //*data++=ReadTDO(32,*data,0); + ReadTDOBuf(32, 0, data, 0); + data += 4; + } + return len; +} + +#define MB_BASE 0x00000000 +#define MB_TIMEOUT 5000 + +/** + */ +int mbPinSet(void) +{ +#ifdef MB_INT + uint32_t rpc[1]; + rpc[0] = 0; + jtagWriteBuffer(MB_BASE, (const uint8_t *)rpc, 1); + outpin_init(MB_INT); + outpin_off(MB_INT); +#endif +} + +/** + * Sends len words (32 bit) via messagebox + */ +int mbCmdSend(uint32_t* data, int len) +{ + int ret; +#ifdef MB_INT + ret = jtagWriteBuffer(MB_BASE, (const uint8_t *)data, len); + if (ret!=len) { + return -10; + } + outpin_on(MB_INT); + outpin_off(MB_INT); +#else + jtagWriteBuffer(MB_BASE + 1, (const uint8_t *)(&data[1]), len-1); + jtagWriteBuffer(MB_BASE, (const uint8_t *)data, 1); +#endif + + int retries = 1000; + do { + if (retries-- < 0) { + return -1; + } + + jtagReadBuffer(MB_BASE, (uint8_t*)&ret, 1); + } while (ret); + + jtagReadBuffer(MB_BASE + 1, (uint8_t*)&ret, 1); + + return ret; +} + +/** + * Writes len words (32 bit) via messagebox at a specified address + */ +int mbWrite(uint32_t address, void* data, int len) +{ + jtagWriteBuffer(MB_BASE + address, (const uint8_t *)data, len); + return 0; +} + +/** + * Reads len words (32 bit) using messagebox from a specified address + */ +int mbRead(uint32_t address, void* data, int len) +{ + uint32_t *p = (uint32_t*)data; + int i; + + for (i=0; iGENDIV.reg = gendiv.reg; + + // setup Clock Generator + GCLK_GENCTRL_Type genctrl = + { + .bit.RUNSTDBY = 0, // Run in Standby + .bit.DIVSEL = 0, // .DIV (above) Selection: 0=linear 1=powers of 2 + .bit.OE = 1, // Output Enable to observe on a port pin + .bit.OOV = 0, // Output Off Value + .bit.IDC = 1, // Improve Duty Cycle + .bit.GENEN = 1, // enable this GCLK + // select GCLK source + //.bit.SRC = GCLK_SOURCE_OSC8M, + .bit.SRC = GCLK_SOURCE_DFLL48M, + // select GCLK2 to output on + .bit.ID = gclk, // GCLK_GENERATOR_X + }; + GCLK->GENCTRL.reg = genctrl.reg; +} +#endif diff --git a/bootloaders/zero/board_driver_jtag.h b/bootloaders/zero/board_driver_jtag.h new file mode 100644 index 0000000..d7684a5 --- /dev/null +++ b/bootloaders/zero/board_driver_jtag.h @@ -0,0 +1,92 @@ +#include +#include "board_definitions.h" +#include + +#ifndef __JTAG_H__ +#define __JTAG_H__ + +/* States of JTAG State Machine */ +#define JS_RESET 0 +#define JS_RUNIDLE 1 +#define JS_SELECT_IR 2 +#define JS_CAPTURE_IR 3 +#define JS_SHIFT_IR 4 +#define JS_EXIT1_IR 5 +#define JS_PAUSE_IR 6 +#define JS_EXIT2_IR 7 +#define JS_UPDATE_IR 8 +#define JS_SELECT_DR 9 +#define JS_CAPTURE_DR 10 +#define JS_SHIFT_DR 11 +#define JS_EXIT1_DR 12 +#define JS_PAUSE_DR 13 +#define JS_EXIT2_DR 14 +#define JS_UPDATE_DR 15 +#define JS_UNDEFINE 16 + +#define JSM_RESET_COUNT 5 + +#define JTAG_VENDOR_ID 0x6E +#define JTAG_ID_VJTAG 0x84 + +/* JTAG Instructions */ +#define JI_EXTEST 0x000 +#define JI_PROGRAM 0x002 +#define JI_STARTUP 0x003 +#define JI_CHECK_STATUS 0x004 +#define JI_SAMPLE 0x005 +#define JI_IDCODE 0x006 +#define JI_USERCODE 0x007 +#define JI_BYPASS 0x3FF +#define JI_PULSE_NCONFIG 0x001 +#define JI_CONFIG_IO 0x00D +#define JI_HIGHZ 0x00B +#define JI_CLAMP 0x00A +#define JI_ACTIVE_DISENGAGE 0x2D0 +#define JI_FACTORY 0x281 +#define JI_USER0_VDR 0x00C +#define JI_USER1_VIR 0x00E + +#define JBC_WRITE 0 +#define JBC_READ 1 + +#define MAX_JTAG_INIT_CLOCK 3192 +#define CDF_IDCODE_LEN 32 + +#define IDCODE 0x20F20DD +#define JSEQ_MAX 360 +#define JSEQ_CONF_DONE 224 +#define INST_LEN 10 +#define INIT_COUNT 200 + +inline void outpin_init(int pin) { PORT->Group[0].DIRSET.reg = (1<Group[0].OUTSET.reg = (1<Group[0].OUTCLR.reg = (1<Group[0].OUTTGL.reg = (1<Group[0].PINCFG[pin].reg=(uint8_t)(PORT_PINCFG_INEN); + PORT->Group[0].DIRCLR.reg = (1<Group[0].IN.reg & (1< 240 || ledTargetValue < 10) { + ledDirection = -ledDirection; + ledTargetValue += ledDirection; + } + + if (ledKeepValue == ledTargetValue) { + LED_toggle(); + } +} diff --git a/bootloaders/zero/board_driver_led.h b/bootloaders/zero/board_driver_led.h new file mode 100644 index 0000000..d7d47ca --- /dev/null +++ b/bootloaders/zero/board_driver_led.h @@ -0,0 +1,63 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 _BOARD_DRIVER_LED_ +#define _BOARD_DRIVER_LED_ + +#include +#include "board_definitions.h" + +#if defined(BOARD_LED_PORT) +inline void LED_init(void) { PORT->Group[BOARD_LED_PORT].DIRSET.reg = (1<Group[BOARD_LED_PORT].OUTSET.reg = (1<Group[BOARD_LED_PORT].OUTCLR.reg = (1<Group[BOARD_LED_PORT].OUTTGL.reg = (1<Group[BOARD_LEDRX_PORT].DIRSET.reg = (1<Group[BOARD_LEDRX_PORT].OUTCLR.reg = (1<Group[BOARD_LEDRX_PORT].OUTSET.reg = (1<Group[BOARD_LEDRX_PORT].OUTTGL.reg = (1<Group[BOARD_LEDTX_PORT].DIRSET.reg = (1<Group[BOARD_LEDTX_PORT].OUTCLR.reg = (1<Group[BOARD_LEDTX_PORT].OUTSET.reg = (1<Group[BOARD_LEDTX_PORT].OUTTGL.reg = (1< +#include +#include "board_definitions.h" + +//Default PMIC (BQ24195) I2C address +#define PMIC_ADDRESS 0x6B + +// Register address definitions +#define INPUT_SOURCE_REGISTER 0x00 +#define POWERON_CONFIG_REGISTER 0x01 +#define CHARGE_CURRENT_CONTROL_REGISTER 0x02 +#define PRECHARGE_CURRENT_CONTROL_REGISTER 0x03 +#define CHARGE_VOLTAGE_CONTROL_REGISTER 0x04 +#define CHARGE_TIMER_CONTROL_REGISTER 0x05 +#define THERMAL_REG_CONTROL_REGISTER 0x06 +#define MISC_CONTROL_REGISTER 0x07 +#define SYSTEM_STATUS_REGISTER 0x08 +#define FAULT_REGISTER 0x09 +#define PMIC_VERSION_REGISTER 0x0A + +int configure_pmic(); + +#endif // _BOARD_DRIVER_PMIC_ diff --git a/bootloaders/zero/board_driver_serial.c b/bootloaders/zero/board_driver_serial.c new file mode 100644 index 0000000..ea5c679 --- /dev/null +++ b/bootloaders/zero/board_driver_serial.c @@ -0,0 +1,109 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 +*/ + +#include "board_driver_serial.h" +#include "board_definitions.h" + +#if defined(SAM_BA_UART_ONLY) || defined(SAM_BA_BOTH_INTERFACES) + +bool uart_drv_error_flag = false; + +void uart_basic_init(Sercom *sercom, uint16_t baud_val, enum uart_pad_settings pad_conf) +{ + /* Wait for synchronization */ + while(sercom->USART.SYNCBUSY.bit.ENABLE); + /* Disable the SERCOM UART module */ + sercom->USART.CTRLA.bit.ENABLE = 0; + /* Wait for synchronization */ + while(sercom->USART.SYNCBUSY.bit.SWRST); + /* Perform a software reset */ + sercom->USART.CTRLA.bit.SWRST = 1; + /* Wait for synchronization */ + while(sercom->USART.CTRLA.bit.SWRST); + /* Wait for synchronization */ + while(sercom->USART.SYNCBUSY.bit.SWRST || sercom->USART.SYNCBUSY.bit.ENABLE); + /* Update the UART pad settings, mode and data order settings */ + sercom->USART.CTRLA.reg = pad_conf | SERCOM_USART_CTRLA_MODE(1) | SERCOM_USART_CTRLA_DORD; + /* Wait for synchronization */ + while(sercom->USART.SYNCBUSY.bit.CTRLB); + /* Enable transmit and receive and set data size to 8 bits */ + sercom->USART.CTRLB.reg = SERCOM_USART_CTRLB_RXEN | SERCOM_USART_CTRLB_TXEN | SERCOM_USART_CTRLB_CHSIZE(0); + /* Load the baud value */ + sercom->USART.BAUD.reg = baud_val; + /* Wait for synchronization */ + while(sercom->USART.SYNCBUSY.bit.ENABLE); + /* Enable SERCOM UART */ + sercom->USART.CTRLA.bit.ENABLE = 1; +} + +void uart_disable(Sercom *sercom) +{ + /* Wait for synchronization */ + while(sercom->USART.SYNCBUSY.bit.ENABLE); + /* Disable SERCOM UART */ + sercom->USART.CTRLA.bit.ENABLE = 0; +} + +void uart_write_byte(Sercom *sercom, uint8_t data) +{ + /* Wait for Data Register Empty flag */ + while(!sercom->USART.INTFLAG.bit.DRE); + /* Write the data to DATA register */ + sercom->USART.DATA.reg = (uint16_t)data; +} + +uint8_t uart_read_byte(Sercom *sercom) +{ + /* Wait for Receive Complete flag */ + while(!sercom->USART.INTFLAG.bit.RXC); + /* Check for errors */ + if (sercom->USART.STATUS.bit.PERR || sercom->USART.STATUS.bit.FERR || sercom->USART.STATUS.bit.BUFOVF) + /* Set the error flag */ + uart_drv_error_flag = true; + /* Return the read data */ + return((uint8_t)sercom->USART.DATA.reg); +} + +void uart_write_buffer_polled(Sercom *sercom, uint8_t *ptr, uint16_t length) +{ + /* Do the following for specified length */ + do { + /* Wait for Data Register Empty flag */ + while(!sercom->USART.INTFLAG.bit.DRE); + /* Send data from the buffer */ + sercom->USART.DATA.reg = (uint16_t)*ptr++; + } while (length--); +} + +void uart_read_buffer_polled(Sercom *sercom, uint8_t *ptr, uint16_t length) +{ + /* Do the following for specified length */ + do { + /* Wait for Receive Complete flag */ + while(!sercom->USART.INTFLAG.bit.RXC); + /* Check for errors */ + if (sercom->USART.STATUS.bit.PERR || sercom->USART.STATUS.bit.FERR || sercom->USART.STATUS.bit.BUFOVF) + /* Set the error flag */ + uart_drv_error_flag = true; + /* Store the read data to the buffer */ + *ptr++ = (uint8_t)sercom->USART.DATA.reg; + } while (length--); +} + +#endif \ No newline at end of file diff --git a/bootloaders/zero/board_driver_serial.h b/bootloaders/zero/board_driver_serial.h new file mode 100644 index 0000000..809f7ec --- /dev/null +++ b/bootloaders/zero/board_driver_serial.h @@ -0,0 +1,89 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 UART_DRIVER_H +#define UART_DRIVER_H + +#include +#include +#include + +#define PINMUX_UNUSED 0xFFFFFFFF + +/* SERCOM UART available pad settings */ +enum uart_pad_settings { + UART_RX_PAD0_TX_PAD2 = SERCOM_USART_CTRLA_RXPO(0) | SERCOM_USART_CTRLA_TXPO(1), + UART_RX_PAD1_TX_PAD2 = SERCOM_USART_CTRLA_RXPO(1) | SERCOM_USART_CTRLA_TXPO(1), + UART_RX_PAD2_TX_PAD0 = SERCOM_USART_CTRLA_RXPO(2), + UART_RX_PAD3_TX_PAD0 = SERCOM_USART_CTRLA_RXPO(3), + UART_RX_PAD1_TX_PAD0 = SERCOM_USART_CTRLA_RXPO(1), + UART_RX_PAD3_TX_PAD2 = SERCOM_USART_CTRLA_RXPO(3) | SERCOM_USART_CTRLA_TXPO(1), +}; + +/** + * \brief Initializes the UART + * + * \param Pointer to SERCOM instance + * \param Baud value corresponding to the desired baudrate + * \param SERCOM pad settings + */ +void uart_basic_init(Sercom *sercom, uint16_t baud_val, enum uart_pad_settings pad_conf); + +/** + * \brief Disables UART interface + * + * \param Pointer to SERCOM instance + */ +void uart_disable(Sercom *sercom); + +/** + * \brief Sends a single byte through UART interface + * + * \param Pointer to SERCOM instance + * \param Data to send + */ +void uart_write_byte(Sercom *sercom, uint8_t data); + +/** + * \brief Reads a single character from UART interface + * + * \param Pointer to SERCOM instance + * \return Data byte read + */ +uint8_t uart_read_byte(Sercom *sercom); + +/** + * \brief Sends buffer on UART interface + * + * \param Pointer to SERCOM instance + * \param Pointer to data to send + * \param Number of bytes to send + */ +void uart_write_buffer_polled(Sercom *sercom, uint8_t *ptr, uint16_t length); + +/** + * \brief Reads data on UART interface + * + * \param Pointer to SERCOM instance + * \param Pointer to store read data + * \param Number of bytes to read + */ +void uart_read_buffer_polled(Sercom *sercom, uint8_t *ptr, uint16_t length); + +#endif diff --git a/bootloaders/zero/board_driver_usb.c b/bootloaders/zero/board_driver_usb.c new file mode 100644 index 0000000..0cad4b7 --- /dev/null +++ b/bootloaders/zero/board_driver_usb.c @@ -0,0 +1,365 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 +*/ + +#include +#include "board_driver_usb.h" +#include "sam_ba_usb.h" +#include "sam_ba_cdc.h" + +#if defined(SAM_BA_USBCDC_ONLY) || defined(SAM_BA_BOTH_INTERFACES) + +#define NVM_USB_PAD_TRANSN_POS (45) +#define NVM_USB_PAD_TRANSN_SIZE (5) +#define NVM_USB_PAD_TRANSP_POS (50) +#define NVM_USB_PAD_TRANSP_SIZE (5) +#define NVM_USB_PAD_TRIM_POS (55) +#define NVM_USB_PAD_TRIM_SIZE (3) + +__attribute__((__aligned__(4))) UsbDeviceDescriptor usb_endpoint_table[MAX_EP]; // Initialized to zero in USB_Init +__attribute__((__aligned__(4))) uint8_t udd_ep_out_cache_buffer[2][64]; //1 for CTRL, 1 for BULK +__attribute__((__aligned__(4))) uint8_t udd_ep_in_cache_buffer[2][64]; //1 for CTRL, 1 for BULK + +static volatile bool read_job = false; + +/*---------------------------------------------------------------------------- + * \brief + */ +P_USB_CDC USB_Open(P_USB_CDC pCdc, Usb *pUsb) +{ + pCdc->pUsb = pUsb; + pCdc->currentConfiguration = 0; + pCdc->currentConnection = 0; + pCdc->IsConfigured = USB_IsConfigured; +// pCdc->Write = USB_Write; +// pCdc->Read = USB_Read; + + pCdc->pUsb->HOST.CTRLA.bit.ENABLE = true; + + return pCdc; +} + +/*---------------------------------------------------------------------------- + * \brief Initializes USB + */ +void USB_Init(void) +{ + uint32_t pad_transn, pad_transp, pad_trim; + + /* Enable USB clock */ + PM->APBBMASK.reg |= PM_APBBMASK_USB; + + /* Set up the USB DP/DN pins */ + PORT->Group[0].PINCFG[PIN_PA24G_USB_DM].bit.PMUXEN = 1; + PORT->Group[0].PMUX[PIN_PA24G_USB_DM/2].reg &= ~(0xF << (4 * (PIN_PA24G_USB_DM & 0x01u))); + PORT->Group[0].PMUX[PIN_PA24G_USB_DM/2].reg |= MUX_PA24G_USB_DM << (4 * (PIN_PA24G_USB_DM & 0x01u)); + PORT->Group[0].PINCFG[PIN_PA25G_USB_DP].bit.PMUXEN = 1; + PORT->Group[0].PMUX[PIN_PA25G_USB_DP/2].reg &= ~(0xF << (4 * (PIN_PA25G_USB_DP & 0x01u))); + PORT->Group[0].PMUX[PIN_PA25G_USB_DP/2].reg |= MUX_PA25G_USB_DP << (4 * (PIN_PA25G_USB_DP & 0x01u)); + + /* ---------------------------------------------------------------------------------------------- + * Put Generic Clock Generator 0 as source for Generic Clock Multiplexer 6 (USB reference) + */ + GCLK->CLKCTRL.reg = GCLK_CLKCTRL_ID( 6 ) | // Generic Clock Multiplexer 6 + GCLK_CLKCTRL_GEN_GCLK0 | // Generic Clock Generator 0 is source + GCLK_CLKCTRL_CLKEN ; + + while ( GCLK->STATUS.reg & GCLK_STATUS_SYNCBUSY ) + { + /* Wait for synchronization */ + } + + /* Reset */ + USB->DEVICE.CTRLA.bit.SWRST = 1; + while (USB->DEVICE.SYNCBUSY.bit.SWRST) + { + /* Sync wait */ + } + + /* Load Pad Calibration */ + pad_transn =( *((uint32_t *)(NVMCTRL_OTP4) + + (NVM_USB_PAD_TRANSN_POS / 32)) + >> (NVM_USB_PAD_TRANSN_POS % 32)) + & ((1 << NVM_USB_PAD_TRANSN_SIZE) - 1); + + if (pad_transn == 0x1F) + { + pad_transn = 5; + } + + USB->HOST.PADCAL.bit.TRANSN = pad_transn; + + pad_transp =( *((uint32_t *)(NVMCTRL_OTP4) + + (NVM_USB_PAD_TRANSP_POS / 32)) + >> (NVM_USB_PAD_TRANSP_POS % 32)) + & ((1 << NVM_USB_PAD_TRANSP_SIZE) - 1); + + if (pad_transp == 0x1F) + { + pad_transp = 29; + } + + USB->HOST.PADCAL.bit.TRANSP = pad_transp; + pad_trim =( *((uint32_t *)(NVMCTRL_OTP4) + + (NVM_USB_PAD_TRIM_POS / 32)) + >> (NVM_USB_PAD_TRIM_POS % 32)) + & ((1 << NVM_USB_PAD_TRIM_SIZE) - 1); + + if (pad_trim == 0x7) + { + pad_trim = 3; + } + + USB->HOST.PADCAL.bit.TRIM = pad_trim; + + /* Set the configuration */ + /* Set mode to Device mode */ + USB->HOST.CTRLA.bit.MODE = 0; + /* Enable Run in Standby */ + USB->HOST.CTRLA.bit.RUNSTDBY = true; + /* Set the descriptor address */ + USB->HOST.DESCADD.reg = (uint32_t)(&usb_endpoint_table[0]); + /* Set speed configuration to Full speed */ + USB->DEVICE.CTRLB.bit.SPDCONF = USB_DEVICE_CTRLB_SPDCONF_FS_Val; + /* Attach to the USB host */ + USB->DEVICE.CTRLB.reg &= ~USB_DEVICE_CTRLB_DETACH; + + /* Initialize endpoint table RAM location to a known value 0 */ + memset((uint8_t *)(&usb_endpoint_table[0]), 0, sizeof(usb_endpoint_table)); +} + +uint32_t USB_Write(Usb *pUsb, const char *pData, uint32_t length, uint8_t ep_num) +{ + uint32_t data_address; + uint8_t buf_index; + + /* Set buffer index */ + buf_index = (ep_num == 0) ? 0 : 1; + + /* Check for requirement for multi-packet or auto zlp */ + if (length >= (1 << (usb_endpoint_table[ep_num].DeviceDescBank[1].PCKSIZE.bit.SIZE + 3))) + { + /* Update the EP data address */ + data_address = (uint32_t) pData; + /* Enable auto zlp */ + usb_endpoint_table[ep_num].DeviceDescBank[1].PCKSIZE.bit.AUTO_ZLP = true; + } + else + { + /* Copy to local buffer */ + memcpy(udd_ep_in_cache_buffer[buf_index], pData, length); + /* Update the EP data address */ + data_address = (uint32_t) &udd_ep_in_cache_buffer[buf_index]; + } + + /* Set the buffer address for ep data */ + usb_endpoint_table[ep_num].DeviceDescBank[1].ADDR.reg = data_address; + /* Set the byte count as zero */ + usb_endpoint_table[ep_num].DeviceDescBank[1].PCKSIZE.bit.BYTE_COUNT = length; + /* Set the multi packet size as zero for multi-packet transfers where length > ep size */ + usb_endpoint_table[ep_num].DeviceDescBank[1].PCKSIZE.bit.MULTI_PACKET_SIZE = 0; + /* Clear the transfer complete flag */ + pUsb->DEVICE.DeviceEndpoint[ep_num].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRCPT1; + /* Set the bank as ready */ + pUsb->DEVICE.DeviceEndpoint[ep_num].EPSTATUSSET.bit.BK1RDY = true; + + /* Wait for transfer to complete */ + while ( (pUsb->DEVICE.DeviceEndpoint[ep_num].EPINTFLAG.bit.TRCPT1) == 0 ); + + return length; +} + +/*---------------------------------------------------------------------------- + * \brief Read available data from Endpoint OUT + */ +uint32_t USB_Read(Usb *pUsb, char *pData, uint32_t length) +{ + uint32_t packetSize = 0; + + if (!read_job) + { + /* Set the buffer address for ep data */ + usb_endpoint_table[USB_EP_OUT].DeviceDescBank[0].ADDR.reg = (uint32_t)&udd_ep_out_cache_buffer[USB_EP_OUT-1]; + /* Set the byte count as zero */ + usb_endpoint_table[USB_EP_OUT].DeviceDescBank[0].PCKSIZE.bit.BYTE_COUNT = 0; + /* Set the byte count as zero */ + usb_endpoint_table[USB_EP_OUT].DeviceDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE = 0; + /* Start the reception by clearing the bank 0 ready bit */ + pUsb->DEVICE.DeviceEndpoint[USB_EP_OUT].EPSTATUSCLR.bit.BK0RDY = true; + /* set the user flag */ + read_job = true; + } + + /* Check for Transfer Complete 0 flag */ + if ( pUsb->DEVICE.DeviceEndpoint[USB_EP_OUT].EPINTFLAG.bit.TRCPT0 ) + { + /* Set packet size */ + packetSize = SAM_BA_MIN(usb_endpoint_table[USB_EP_OUT].DeviceDescBank[0].PCKSIZE.bit.BYTE_COUNT, length); + /* Copy read data to user buffer */ + memcpy(pData, udd_ep_out_cache_buffer[USB_EP_OUT-1], packetSize); + /* Clear the Transfer Complete 0 flag */ + pUsb->DEVICE.DeviceEndpoint[USB_EP_OUT].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRCPT0; + /* Clear the user flag */ + read_job = false; + } + + return packetSize; +} + +uint32_t USB_Read_blocking(Usb *pUsb, char *pData, uint32_t length) +{ + if (read_job) + { + /* Stop the reception by setting the bank 0 ready bit */ + pUsb->DEVICE.DeviceEndpoint[USB_EP_OUT].EPSTATUSSET.bit.BK0RDY = true; + /* Clear the user flag */ + read_job = false; + } + + /* Set the buffer address for ep data */ + usb_endpoint_table[USB_EP_OUT].DeviceDescBank[0].ADDR.reg = ((uint32_t)pData); + /* Set the byte count as zero */ + usb_endpoint_table[USB_EP_OUT].DeviceDescBank[0].PCKSIZE.bit.BYTE_COUNT = 0; + /* Set the multi packet size as zero for multi-packet transfers where length > ep size */ + usb_endpoint_table[USB_EP_OUT].DeviceDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE = length; + /* Clear the bank 0 ready flag */ + pUsb->DEVICE.DeviceEndpoint[USB_EP_OUT].EPSTATUSCLR.bit.BK0RDY = true; + /* Wait for transfer to complete */ + while (!( pUsb->DEVICE.DeviceEndpoint[USB_EP_OUT].EPINTFLAG.bit.TRCPT0 )); + /* Clear Transfer complete 0 flag */ + pUsb->DEVICE.DeviceEndpoint[USB_EP_OUT].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRCPT0; + + return length; +} + +/*---------------------------------------------------------------------------- + * \brief Test if the device is configured and handle enumeration + */ +uint8_t USB_IsConfigured(P_USB_CDC pCdc) +{ + Usb *pUsb = pCdc->pUsb; + + /* Check for End of Reset flag */ + if (pUsb->DEVICE.INTFLAG.reg & USB_DEVICE_INTFLAG_EORST) + { + /* Clear the flag */ + pUsb->DEVICE.INTFLAG.reg = USB_DEVICE_INTFLAG_EORST; + /* Set Device address as 0 */ + pUsb->DEVICE.DADD.reg = USB_DEVICE_DADD_ADDEN | 0; + /* Configure endpoint 0 */ + /* Configure Endpoint 0 for Control IN and Control OUT */ + pUsb->DEVICE.DeviceEndpoint[0].EPCFG.reg = USB_DEVICE_EPCFG_EPTYPE0(1) | USB_DEVICE_EPCFG_EPTYPE1(1); + pUsb->DEVICE.DeviceEndpoint[0].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_BK0RDY; + pUsb->DEVICE.DeviceEndpoint[0].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_BK1RDY; + /* Configure control OUT Packet size to 64 bytes */ + usb_endpoint_table[0].DeviceDescBank[0].PCKSIZE.bit.SIZE = 3; + /* Configure control IN Packet size to 64 bytes */ + usb_endpoint_table[0].DeviceDescBank[1].PCKSIZE.bit.SIZE = 3; + /* Configure the data buffer address for control OUT */ + usb_endpoint_table[0].DeviceDescBank[0].ADDR.reg = (uint32_t)&udd_ep_out_cache_buffer[0]; + /* Configure the data buffer address for control IN */ + usb_endpoint_table[0].DeviceDescBank[1].ADDR.reg = (uint32_t)&udd_ep_in_cache_buffer[0]; + /* Set Multipacket size to 8 for control OUT and byte count to 0*/ + usb_endpoint_table[0].DeviceDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE = 8; + usb_endpoint_table[0].DeviceDescBank[0].PCKSIZE.bit.BYTE_COUNT = 0; + pUsb->DEVICE.DeviceEndpoint[0].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_BK0RDY; + + // Reset current configuration value to 0 + pCdc->currentConfiguration = 0; + } + else + { + if (pUsb->DEVICE.DeviceEndpoint[0].EPINTFLAG.reg & USB_DEVICE_EPINTFLAG_RXSTP) + { + sam_ba_usb_CDC_Enumerate(pCdc); + } + } + + return pCdc->currentConfiguration; +} + +/*---------------------------------------------------------------------------- + * \brief Stall the control endpoint + */ +void USB_SendStall(Usb *pUsb, bool direction_in) +{ + /* Check the direction */ + if (direction_in) + { + /* Set STALL request on IN direction */ + pUsb->DEVICE.DeviceEndpoint[0].EPSTATUSSET.bit.STALLRQ1 = 1; + } + else + { + /* Set STALL request on OUT direction */ + pUsb->DEVICE.DeviceEndpoint[0].EPSTATUSSET.bit.STALLRQ0 = 1; + } +} + +/*---------------------------------------------------------------------------- + * \brief Send zero length packet through the control endpoint + */ +void USB_SendZlp(Usb *pUsb) +{ + /* Set the byte count as zero */ + usb_endpoint_table[0].DeviceDescBank[1].PCKSIZE.bit.BYTE_COUNT = 0; + /* Clear the transfer complete flag */ + pUsb->DEVICE.DeviceEndpoint[0].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRCPT1; + /* Set the bank as ready */ + pUsb->DEVICE.DeviceEndpoint[0].EPSTATUSSET.bit.BK1RDY = true; + /* Wait for transfer to complete */ + while (!( pUsb->DEVICE.DeviceEndpoint[0].EPINTFLAG.bit.TRCPT1 )); +} + +/*---------------------------------------------------------------------------- + * \brief Set USB device address obtained from host + */ +void USB_SetAddress(Usb *pUsb, uint16_t wValue) +{ + pUsb->DEVICE.DADD.reg = USB_DEVICE_DADD_ADDEN | wValue; +} + +/*---------------------------------------------------------------------------- + * \brief Configure USB device + */ +void USB_Configure(Usb *pUsb) +{ + /* Configure BULK OUT endpoint for CDC Data interface*/ + pUsb->DEVICE.DeviceEndpoint[USB_EP_OUT].EPCFG.reg = USB_DEVICE_EPCFG_EPTYPE0(3); + /* Set maximum packet size as 64 bytes */ + usb_endpoint_table[USB_EP_OUT].DeviceDescBank[0].PCKSIZE.bit.SIZE = 3; + pUsb->DEVICE.DeviceEndpoint[USB_EP_OUT].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_BK0RDY; + /* Configure the data buffer */ + usb_endpoint_table[USB_EP_OUT].DeviceDescBank[0].ADDR.reg = (uint32_t)&udd_ep_out_cache_buffer[1]; + + /* Configure BULK IN endpoint for CDC Data interface */ + pUsb->DEVICE.DeviceEndpoint[USB_EP_IN].EPCFG.reg = USB_DEVICE_EPCFG_EPTYPE1(3); + /* Set maximum packet size as 64 bytes */ + usb_endpoint_table[USB_EP_IN].DeviceDescBank[1].PCKSIZE.bit.SIZE = 3; + pUsb->DEVICE.DeviceEndpoint[USB_EP_IN].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_BK1RDY; + /* Configure the data buffer */ + usb_endpoint_table[USB_EP_IN].DeviceDescBank[1].ADDR.reg = (uint32_t)&udd_ep_in_cache_buffer[1]; + + /* Configure INTERRUPT IN endpoint for CDC COMM interface*/ + pUsb->DEVICE.DeviceEndpoint[USB_EP_COMM].EPCFG.reg = USB_DEVICE_EPCFG_EPTYPE1(4); + /* Set maximum packet size as 64 bytes */ + usb_endpoint_table[USB_EP_COMM].DeviceDescBank[1].PCKSIZE.bit.SIZE = 0; + pUsb->DEVICE.DeviceEndpoint[USB_EP_COMM].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_BK1RDY; +} + +#endif \ No newline at end of file diff --git a/bootloaders/zero/board_driver_usb.h b/bootloaders/zero/board_driver_usb.h new file mode 100644 index 0000000..4e71b8c --- /dev/null +++ b/bootloaders/zero/board_driver_usb.h @@ -0,0 +1,45 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 _BOARD_DRIVER_USB_H_ +#define _BOARD_DRIVER_USB_H_ + +#include "sam_ba_cdc.h" + +extern UsbDeviceDescriptor usb_endpoint_table[MAX_EP]; +extern uint8_t udd_ep_out_cache_buffer[2][64]; //1 for CTRL, 1 for BULK +extern uint8_t udd_ep_in_cache_buffer[2][64]; //1 for CTRL, 1 for BULK + +P_USB_CDC USB_Open(P_USB_CDC pCdc, Usb *pUsb); + +void USB_Init(void); + +uint32_t USB_Write(Usb *pUsb, const char *pData, uint32_t length, uint8_t ep_num); +uint32_t USB_Read(Usb *pUsb, char *pData, uint32_t length); +uint32_t USB_Read_blocking(Usb *pUsb, char *pData, uint32_t length); + +uint8_t USB_IsConfigured(P_USB_CDC pCdc); + +void USB_SendStall(Usb *pUsb, bool direction_in); +void USB_SendZlp(Usb *pUsb); + +void USB_SetAddress(Usb *pUsb, uint16_t wValue); +void USB_Configure(Usb *pUsb); + +#endif // _BOARD_DRIVER_USB_H_ diff --git a/bootloaders/zero/board_init.c b/bootloaders/zero/board_init.c new file mode 100644 index 0000000..392cd79 --- /dev/null +++ b/bootloaders/zero/board_init.c @@ -0,0 +1,147 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 +*/ + +#include +#include +#include "board_definitions.h" + +#define SYSCTRL_FUSES_OSC32K_CAL_ADDR (NVMCTRL_OTP4 + 4) +#define SYSCTRL_FUSES_OSC32K_CAL_Pos 6 +#define SYSCTRL_FUSES_OSC32K_ADDR SYSCTRL_FUSES_OSC32K_CAL_ADDR +#define SYSCTRL_FUSES_OSC32K_Pos SYSCTRL_FUSES_OSC32K_CAL_Pos +#define SYSCTRL_FUSES_OSC32K_Msk (0x7Fu << SYSCTRL_FUSES_OSC32K_Pos) + +volatile bool g_interrupt_enabled = true; + +static void gclk_sync(void) { + while (GCLK->STATUS.reg & GCLK_STATUS_SYNCBUSY) + ; +} + +static void dfll_sync(void) { + while ((SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_DFLLRDY) == 0) + ; +} + + +void board_init(void) { + + NVMCTRL->CTRLB.bit.RWS = 1; + +#if defined(CRYSTALLESS) + /* Configure OSC8M as source for GCLK_GEN 2 */ + GCLK->GENDIV.reg = GCLK_GENDIV_ID(2); // Read GENERATOR_ID - GCLK_GEN_2 + gclk_sync(); + + GCLK->GENCTRL.reg = GCLK_GENCTRL_ID(2) | GCLK_GENCTRL_SRC_OSC8M_Val | GCLK_GENCTRL_GENEN; + gclk_sync(); + + // Turn on DFLL with USB correction and sync to internal 8 mhz oscillator + SYSCTRL->DFLLCTRL.reg = SYSCTRL_DFLLCTRL_ENABLE; + dfll_sync(); + + SYSCTRL_DFLLVAL_Type dfllval_conf = {0}; + uint32_t coarse =( *((uint32_t *)(NVMCTRL_OTP4) + + (NVM_SW_CALIB_DFLL48M_COARSE_VAL / 32)) + >> (NVM_SW_CALIB_DFLL48M_COARSE_VAL % 32)) + & ((1 << 6) - 1); + if (coarse == 0x3f) { + coarse = 0x1f; + } + dfllval_conf.bit.COARSE = coarse; + // TODO(tannewt): Load this from a well known flash location so that it can be + // calibrated during testing. + dfllval_conf.bit.FINE = 0x1ff; + + SYSCTRL->DFLLMUL.reg = SYSCTRL_DFLLMUL_CSTEP( 0x1f / 4 ) | // Coarse step is 31, half of the max value + SYSCTRL_DFLLMUL_FSTEP( 10 ) | + 48000; + SYSCTRL->DFLLVAL.reg = dfllval_conf.reg; + SYSCTRL->DFLLCTRL.reg = 0; + dfll_sync(); + SYSCTRL->DFLLCTRL.reg = SYSCTRL_DFLLCTRL_MODE | + SYSCTRL_DFLLCTRL_CCDIS | + SYSCTRL_DFLLCTRL_USBCRM | /* USB correction */ + SYSCTRL_DFLLCTRL_BPLCKC; + dfll_sync(); + SYSCTRL->DFLLCTRL.reg |= SYSCTRL_DFLLCTRL_ENABLE ; + dfll_sync(); + + GCLK_CLKCTRL_Type clkctrl={0}; + uint16_t temp; + GCLK->CLKCTRL.bit.ID = 2; // GCLK_ID - DFLL48M Reference + temp = GCLK->CLKCTRL.reg; + clkctrl.bit.CLKEN = 1; + clkctrl.bit.WRTLOCK = 0; + clkctrl.bit.GEN = GCLK_CLKCTRL_GEN_GCLK0_Val; + GCLK->CLKCTRL.reg = (clkctrl.reg | temp); + +#else + + SYSCTRL->XOSC32K.reg = + SYSCTRL_XOSC32K_STARTUP(6) | SYSCTRL_XOSC32K_XTALEN | SYSCTRL_XOSC32K_EN32K; + SYSCTRL->XOSC32K.bit.ENABLE = 1; + while ((SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_XOSC32KRDY) == 0) + ; + + GCLK->GENDIV.reg = GCLK_GENDIV_ID(1); + gclk_sync(); + + GCLK->GENCTRL.reg = GCLK_GENCTRL_ID(1) | GCLK_GENCTRL_SRC_XOSC32K | GCLK_GENCTRL_GENEN; + gclk_sync(); + + GCLK->CLKCTRL.reg = GCLK_CLKCTRL_ID(0) | GCLK_CLKCTRL_GEN_GCLK1 | GCLK_CLKCTRL_CLKEN; + gclk_sync(); + + SYSCTRL->DFLLCTRL.bit.ONDEMAND = 0; + dfll_sync(); + + SYSCTRL->DFLLMUL.reg = SYSCTRL_DFLLMUL_CSTEP(31) | SYSCTRL_DFLLMUL_FSTEP(511) | + SYSCTRL_DFLLMUL_MUL((CPU_FREQUENCY / (32 * 1024))); + dfll_sync(); + + SYSCTRL->DFLLCTRL.reg |= + SYSCTRL_DFLLCTRL_MODE | SYSCTRL_DFLLCTRL_WAITLOCK | SYSCTRL_DFLLCTRL_QLDIS; + dfll_sync(); + + SYSCTRL->DFLLCTRL.reg |= SYSCTRL_DFLLCTRL_ENABLE; + + while ((SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_DFLLLCKC) == 0 || + (SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_DFLLLCKF) == 0) + ; + dfll_sync(); + +#endif + + // Configure DFLL48M as source for GCLK_GEN 0 + GCLK->GENDIV.reg = GCLK_GENDIV_ID(0); + gclk_sync(); + + // Add GCLK_GENCTRL_OE below to output GCLK0 on the SWCLK pin. + GCLK->GENCTRL.reg = + GCLK_GENCTRL_ID(0) | GCLK_GENCTRL_SRC_DFLL48M | GCLK_GENCTRL_IDC | GCLK_GENCTRL_GENEN; + gclk_sync(); + + SysTick_Config(1000); + + // Uncomment these two lines to output GCLK0 on the SWCLK pin. + // PORT->Group[0].PINCFG[30].bit.PMUXEN = 1; + // Set the port mux mask for odd processor pin numbers, PA30 = 30 is even number, PMUXE = PMUX Even + // PORT->Group[0].PMUX[30 / 2].reg |= PORT_PMUX_PMUXE_H; +} diff --git a/bootloaders/zero/board_startup.c b/bootloaders/zero/board_startup.c new file mode 100644 index 0000000..8513a2d --- /dev/null +++ b/bootloaders/zero/board_startup.c @@ -0,0 +1,141 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 +*/ + +#include + +struct ConstVectors +{ + /* Stack pointer */ + void* pvStack; + + /* Cortex-M handlers */ + void* pfnReset_Handler; + void* pfnNMI_Handler; + void* pfnHardFault_Handler; + void* pfnReservedM12; + void* pfnReservedM11; + void* pfnReservedM10; + void* pfnReservedM9; + void* pfnReservedM8; + void* pfnReservedM7; + void* pfnReservedM6; + void* pfnSVC_Handler; + void* pfnReservedM4; + void* pfnReservedM3; + void* pfnPendSV_Handler; + void* pfnSysTick_Handler; +}; + +/* Symbols exported from linker script */ +extern uint32_t __etext ; +extern uint32_t __data_start__ ; +extern uint32_t __data_end__ ; +extern uint32_t __bss_start__ ; +extern uint32_t __bss_end__ ; +extern uint32_t __StackTop; + +extern int main(void); +extern void __libc_init_array(void); + +/* Exception Table */ +__attribute__ ((used, section(".isr_vector"))) +const struct ConstVectors exception_table = +{ + /* Configure Initial Stack Pointer, using linker-generated symbols */ + .pvStack = (void*) (&__StackTop), + + .pfnReset_Handler = (void*) Reset_Handler, + .pfnNMI_Handler = (void*) NMI_Handler, + .pfnHardFault_Handler = (void*) HardFault_Handler, + .pfnReservedM12 = (void*) (0UL), /* Reserved */ + .pfnReservedM11 = (void*) (0UL), /* Reserved */ + .pfnReservedM10 = (void*) (0UL), /* Reserved */ + .pfnReservedM9 = (void*) (0UL), /* Reserved */ + .pfnReservedM8 = (void*) (0UL), /* Reserved */ + .pfnReservedM7 = (void*) (0UL), /* Reserved */ + .pfnReservedM6 = (void*) (0UL), /* Reserved */ + .pfnSVC_Handler = (void*) SVC_Handler, + .pfnReservedM4 = (void*) (0UL), /* Reserved */ + .pfnReservedM3 = (void*) (0UL), /* Reserved */ + .pfnPendSV_Handler = (void*) PendSV_Handler, + .pfnSysTick_Handler = (void*) SysTick_Handler, +}; + +/** + * \brief This is the code that gets called on processor reset. + * Initializes the device and call the main() routine. + */ +void Reset_Handler( void ) +{ + uint32_t *pSrc, *pDest; + + /* Initialize the initialized data section */ + pSrc = &__etext; + pDest = &__data_start__; + + if ( (&__data_start__ != &__data_end__) && (pSrc != pDest) ) + { + for (; pDest < &__data_end__ ; pDest++, pSrc++ ) + { + *pDest = *pSrc ; + } + } + + /* Clear the zero section */ + if ( &__bss_start__ != &__bss_end__ ) + { + for ( pDest = &__bss_start__ ; pDest < &__bss_end__ ; pDest++ ) + { + *pDest = 0ul ; + } + } + +// board_init(); // will be done in main() after app check + + /* Initialize the C library */ +// __libc_init_array(); + + main(); + + while (1); +} + +void NMI_Handler(void) +{ + __BKPT(14); + while (1); +} + +void HardFault_Handler(void) +{ + __BKPT(13); + while (1); +} + +void SVC_Handler(void) +{ + __BKPT(5); + while (1); +} + +void PendSV_Handler(void) +{ + __BKPT(2); + while (1); +} diff --git a/bootloaders/zero/bootloader_samd21x18.ld b/bootloaders/zero/bootloader_samd21x18.ld new file mode 100644 index 0000000..91d308d --- /dev/null +++ b/bootloaders/zero/bootloader_samd21x18.ld @@ -0,0 +1,221 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 0x2000 /* First 8KB used by bootloader */ + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000-0x0400 /* last 4 bytes used by bootloader to keep data between resets, but reserves 1024 bytes for sketches to have same possibility */ +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + * __sketch_vectors_ptr + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + . = ORIGIN(FLASH); + + .vectors : + { + KEEP(*(.isr_vector)) + } > FLASH + + .text : + { + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + PROVIDE(__sketch_vectors_ptr = ORIGIN(FLASH) + LENGTH(FLASH)); + + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(4); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM); + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/bootloaders/zero/build_all_bootloaders.sh b/bootloaders/zero/build_all_bootloaders.sh new file mode 100755 index 0000000..f1c1fb1 --- /dev/null +++ b/bootloaders/zero/build_all_bootloaders.sh @@ -0,0 +1,36 @@ +#!/bin/bash -ex + +BOARD_ID=arduino_zero NAME=samd21_sam_ba make clean all + +BOARD_ID=arduino_mkr1000 NAME=samd21_sam_ba_arduino_mkr1000 make clean all +mv -v samd21_sam_ba_arduino_mkr1000.* ../mkr1000/ + +BOARD_ID=arduino_mkrzero NAME=samd21_sam_ba_arduino_mkrzero make clean all +mv -v samd21_sam_ba_arduino_mkrzero.* ../mkrzero/ + +BOARD_ID=arduino_mkrfox1200 NAME=samd21_sam_ba_arduino_mkrfox1200 make clean all +mv -v samd21_sam_ba_arduino_mkrfox1200.* ../mkrfox1200/ + +BOARD_ID=arduino_mkrgsm1400 NAME=samd21_sam_ba_arduino_mkrgsm1400 make clean all +mv -v samd21_sam_ba_arduino_mkrgsm1400.* ../mkrgsm1400/ + +BOARD_ID=arduino_mkrwan1300 NAME=samd21_sam_ba_arduino_mkrwan1300 make clean all +mv -v samd21_sam_ba_arduino_mkrwan1300.* ../mkrwan1300/ + +BOARD_ID=arduino_mkrwan1310 NAME=samd21_sam_ba_arduino_mkrwan1310 make clean all +mv -v samd21_sam_ba_arduino_mkrwan1310.* ../mkrwan1300/ + +BOARD_ID=arduino_mkrwifi1010 NAME=samd21_sam_ba_arduino_mkrwifi1010 make clean all +mv -v samd21_sam_ba_arduino_mkrwifi1010.* ../mkrwifi1010/ + +BOARD_ID=arduino_mkrvidor4000 SAM_BA_INTERFACES=SAM_BA_USBCDC_ONLY NAME=samd21_sam_ba_arduino_mkrvidor4000 make clean all +mv -v samd21_sam_ba_arduino_mkrvidor4000.* ../mkrvidor4000/ + +BOARD_ID=arduino_mkrnb1500 NAME=samd21_sam_ba_arduino_mkrnb1500 make clean all +mv -v samd21_sam_ba_arduino_mkrnb1500.* ../mkrnb1500/ + +BOARD_ID=arduino_nano_33_iot NAME=samd21_sam_ba_arduino_nano_33_iot make clean all +mv -v samd21_sam_ba_arduino_nano_33_iot.* ../nano_33_iot/ + +echo Done building bootloaders! + diff --git a/bootloaders/zero/main.c b/bootloaders/zero/main.c new file mode 100644 index 0000000..402be29 --- /dev/null +++ b/bootloaders/zero/main.c @@ -0,0 +1,280 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 +*/ + +#include +#include +#include "sam_ba_monitor.h" +#include "sam_ba_serial.h" +#include "board_definitions.h" +#include "board_driver_led.h" +#include "board_driver_i2c.h" +#include "board_driver_pmic.h" +#include "board_driver_jtag.h" +#include "sam_ba_usb.h" +#include "sam_ba_cdc.h" + +extern uint32_t __sketch_vectors_ptr; // Exported value from linker script +extern void board_init(void); + +volatile uint32_t* pulSketch_Start_Address; + +static void jump_to_application(void) { + + /* Rebase the Stack Pointer */ + __set_MSP( (uint32_t)(__sketch_vectors_ptr) ); + + /* Rebase the vector table base address */ + SCB->VTOR = ((uint32_t)(&__sketch_vectors_ptr) & SCB_VTOR_TBLOFF_Msk); + + /* Jump to application Reset Handler in the application */ + asm("bx %0"::"r"(*pulSketch_Start_Address)); +} + +static volatile bool main_b_cdc_enable = false; + +#ifdef CONFIGURE_PMIC +static volatile bool jump_to_app = false; +#endif + +/** + * \brief Check the application startup condition + * + */ +static void check_start_application(void) +{ +// LED_init(); +// LED_off(); + + /* + * Test sketch stack pointer @ &__sketch_vectors_ptr + * Stay in SAM-BA if value @ (&__sketch_vectors_ptr) == 0xFFFFFFFF (Erased flash cell value) + */ + if (__sketch_vectors_ptr == 0xFFFFFFFF) + { + /* Stay in bootloader */ + return; + } + + /* + * Load the sketch Reset Handler address + * __sketch_vectors_ptr is exported from linker script and point on first 32b word of sketch vector table + * First 32b word is sketch stack + * Second 32b word is sketch entry point: Reset_Handler() + */ + pulSketch_Start_Address = &__sketch_vectors_ptr ; + pulSketch_Start_Address++ ; + + /* + * Test vector table address of sketch @ &__sketch_vectors_ptr + * Stay in SAM-BA if this function is not aligned enough, ie not valid + */ + if ( ((uint32_t)(&__sketch_vectors_ptr) & ~SCB_VTOR_TBLOFF_Msk) != 0x00) + { + /* Stay in bootloader */ + return; + } + +#if defined(BOOT_DOUBLE_TAP_ADDRESS) + #define DOUBLE_TAP_MAGIC 0x07738135 + if (PM->RCAUSE.bit.POR) + { + /* On power-on initialize double-tap */ + BOOT_DOUBLE_TAP_DATA = 0; + } + else + { + if (BOOT_DOUBLE_TAP_DATA == DOUBLE_TAP_MAGIC) + { + /* Second tap, stay in bootloader */ + BOOT_DOUBLE_TAP_DATA = 0; + return; + } + +#ifdef HAS_EZ6301QI + // wait a tiny bit for the EZ6301QI to settle, + // as it's connected to RESETN and might reset + // the chip when the cable is plugged in fresh + + for (uint32_t i=0; i<2500; i++) /* 10ms */ + /* force compiler to not optimize this... */ + __asm__ __volatile__(""); +#endif + + /* First tap */ + BOOT_DOUBLE_TAP_DATA = DOUBLE_TAP_MAGIC; + + /* Wait 0.5sec to see if the user tap reset again. + * The loop value is based on SAMD21 default 1MHz clock @ reset. + */ + for (uint32_t i=0; i<125000; i++) /* 500ms */ + /* force compiler to not optimize this... */ + __asm__ __volatile__(""); + + /* Timeout happened, continue boot... */ + BOOT_DOUBLE_TAP_DATA = 0; + } +#endif + +/* +#if defined(BOOT_LOAD_PIN) + volatile PortGroup *boot_port = (volatile PortGroup *)(&(PORT->Group[BOOT_LOAD_PIN / 32])); + volatile bool boot_en; + + // Enable the input mode in Boot GPIO Pin + boot_port->DIRCLR.reg = BOOT_PIN_MASK; + boot_port->PINCFG[BOOT_LOAD_PIN & 0x1F].reg = PORT_PINCFG_INEN | PORT_PINCFG_PULLEN; + boot_port->OUTSET.reg = BOOT_PIN_MASK; + // Read the BOOT_LOAD_PIN status + boot_en = (boot_port->IN.reg) & BOOT_PIN_MASK; + + // Check the bootloader enable condition + if (!boot_en) + { + // Stay in bootloader + return; + } +#endif +*/ + +// LED_on(); +#ifdef CONFIGURE_PMIC + jump_to_app = true; +#else + jump_to_application(); +#endif + +} + +#if DEBUG_ENABLE +# define DEBUG_PIN_HIGH port_pin_set_output_level(BOOT_LED, 1) +# define DEBUG_PIN_LOW port_pin_set_output_level(BOOT_LED, 0) +#else +# define DEBUG_PIN_HIGH do{}while(0) +# define DEBUG_PIN_LOW do{}while(0) +#endif + +/** + * \brief SAMD21 SAM-BA Main loop. + * \return Unused (ANSI-C compatibility). + */ +int main(void) +{ +#if defined(SAM_BA_USBCDC_ONLY) || defined(SAM_BA_BOTH_INTERFACES) + P_USB_CDC pCdc; +#endif + DEBUG_PIN_HIGH; + + /* Jump in application if condition is satisfied */ + check_start_application(); + + /* We have determined we should stay in the monitor. */ + /* System initialization */ + board_init(); + __enable_irq(); + +#ifdef CONFIGURE_PMIC + configure_pmic(); +#endif + +#ifdef ENABLE_JTAG_LOAD + uint32_t temp ; + // Get whole current setup for both odd and even pins and remove odd one + temp = (PORT->Group[0].PMUX[27 >> 1].reg) & PORT_PMUX_PMUXE( 0xF ) ; + // Set new muxing + PORT->Group[0].PMUX[27 >> 1].reg = temp|PORT_PMUX_PMUXO( 7 ) ; + // Enable port mux + PORT->Group[0].PINCFG[27].reg |= PORT_PINCFG_PMUXEN ; + clockout(0, 1); + + jtagInit(); + if ((jtagBitstreamVersion() & 0xFF000000) != 0xB0000000) { + // FPGA is not in the bootloader, restart it + jtagReload(); + } +#endif + +#ifdef CONFIGURE_PMIC + if (jump_to_app == true) { + jump_to_application(); + } +#endif + +#if defined(SAM_BA_UART_ONLY) || defined(SAM_BA_BOTH_INTERFACES) + /* UART is enabled in all cases */ + serial_open(); +#endif + +#if defined(SAM_BA_USBCDC_ONLY) || defined(SAM_BA_BOTH_INTERFACES) + pCdc = usb_init(); +#endif + + DEBUG_PIN_LOW; + + /* Initialize LEDs */ + LED_init(); + LEDRX_init(); + LEDRX_off(); + LEDTX_init(); + LEDTX_off(); + + /* Start the sys tick (1 ms) */ + SysTick_Config(1000); + + /* Wait for a complete enum on usb or a '#' char on serial line */ + while (1) + { +#if defined(SAM_BA_USBCDC_ONLY) || defined(SAM_BA_BOTH_INTERFACES) + if (pCdc->IsConfigured(pCdc) != 0) + { + main_b_cdc_enable = true; + } + + /* Check if a USB enumeration has succeeded and if comm port has been opened */ + if (main_b_cdc_enable) + { + sam_ba_monitor_init(SAM_BA_INTERFACE_USBCDC); + /* SAM-BA on USB loop */ + while( 1 ) + { + sam_ba_monitor_run(); + } + } +#endif + +#if defined(SAM_BA_UART_ONLY) || defined(SAM_BA_BOTH_INTERFACES) + /* Check if a '#' has been received */ + if (!main_b_cdc_enable && serial_sharp_received()) + { + sam_ba_monitor_init(SAM_BA_INTERFACE_USART); + /* SAM-BA on Serial loop */ + while(1) + { + sam_ba_monitor_run(); + } + } +#endif + } +} + +void SysTick_Handler(void) +{ + LED_pulse(); + + sam_ba_monitor_sys_tick(); +} diff --git a/bootloaders/zero/sam_ba_cdc.c b/bootloaders/zero/sam_ba_cdc.c new file mode 100644 index 0000000..3773409 --- /dev/null +++ b/bootloaders/zero/sam_ba_cdc.c @@ -0,0 +1,98 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 +*/ + +#include "sam_ba_cdc.h" +#include "board_driver_usb.h" + +usb_cdc_line_coding_t line_coding= +{ + 115200, // baudrate + 0, // 1 Stop Bit + 0, // None Parity + 8 // 8 Data bits +}; + +#define pCdc (&sam_ba_cdc) + +int cdc_putc(/*P_USB_CDC pCdc,*/ int value) +{ + /* Send single byte on USB CDC */ + USB_Write(pCdc->pUsb, (const char *)&value, 1, USB_EP_IN); + + return 1; +} + +int cdc_getc(/*P_USB_CDC pCdc*/void) +{ + uint8_t rx_char; + + /* Read singly byte on USB CDC */ + USB_Read(pCdc->pUsb, (char *)&rx_char, 1); + + return (int)rx_char; +} + +bool cdc_is_rx_ready(/*P_USB_CDC pCdc*/void) +{ + /* Check whether the device is configured */ + if ( !USB_IsConfigured(pCdc) ) + return 0; + + /* Return transfer complete 0 flag status */ + return (pCdc->pUsb->DEVICE.DeviceEndpoint[USB_EP_OUT].EPINTFLAG.bit.TRCPT0); +} + +uint32_t cdc_write_buf(/*P_USB_CDC pCdc,*/ void const* data, uint32_t length) +{ + /* Send the specified number of bytes on USB CDC */ + USB_Write(pCdc->pUsb, (const char *)data, length, USB_EP_IN); + return length; +} + +uint32_t cdc_read_buf(/*P_USB_CDC pCdc,*/ void* data, uint32_t length) +{ + /* Check whether the device is configured */ + if ( !USB_IsConfigured(pCdc) ) + return 0; + + /* Read from USB CDC */ + return USB_Read(pCdc->pUsb, (char *)data, length); +} + +uint32_t cdc_read_buf_xmd(/*P_USB_CDC pCdc,*/ void* data, uint32_t length) +{ + /* Check whether the device is configured */ + if ( !USB_IsConfigured(pCdc) ) + return 0; + + /* Blocking read till specified number of bytes is received */ + // XXX: USB_Read_blocking is not reliable + // return USB_Read_blocking(pCdc, (char *)data, length); + + char *dst = (char *)data; + uint32_t remaining = length; + while (remaining) + { + uint32_t readed = USB_Read(pCdc->pUsb, (char *)dst, remaining); + remaining -= readed; + dst += readed; + } + + return length; +} diff --git a/bootloaders/zero/sam_ba_cdc.h b/bootloaders/zero/sam_ba_cdc.h new file mode 100644 index 0000000..49b7643 --- /dev/null +++ b/bootloaders/zero/sam_ba_cdc.h @@ -0,0 +1,91 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 _SAM_BA_USB_CDC_H_ +#define _SAM_BA_USB_CDC_H_ + +#include +#include "sam_ba_usb.h" + +typedef struct +{ + uint32_t dwDTERate; + uint8_t bCharFormat; + uint8_t bParityType; + uint8_t bDataBits; +} usb_cdc_line_coding_t; + +/* CDC Class Specific Request Code */ +#define GET_LINE_CODING 0x21A1 +#define SET_LINE_CODING 0x2021 +#define SET_CONTROL_LINE_STATE 0x2221 + +extern usb_cdc_line_coding_t line_coding; + + +/** + * \brief Sends a single byte through USB CDC + * + * \param Data to send + * \return number of data sent + */ +int cdc_putc(/*P_USB_CDC pCdc,*/ int value); + +/** + * \brief Reads a single byte through USB CDC + * + * \return Data read through USB + */ +int cdc_getc(/*P_USB_CDC pCdc*/); + +/** + * \brief Checks if a character has been received on USB CDC + * + * \return \c 1 if a byte is ready to be read. + */ +bool cdc_is_rx_ready(/*P_USB_CDC pCdc*/); + +/** + * \brief Sends buffer on USB CDC + * + * \param data pointer + * \param number of data to send + * \return number of data sent + */ +uint32_t cdc_write_buf(/*P_USB_CDC pCdc,*/ void const* data, uint32_t length); + +/** + * \brief Gets data on USB CDC + * + * \param data pointer + * \param number of data to read + * \return number of data read + */ +uint32_t cdc_read_buf(/*P_USB_CDC pCdc,*/ void* data, uint32_t length); + +/** + * \brief Gets specified number of bytes on USB CDC + * + * \param data pointer + * \param number of data to read + * \return number of data read + */ +uint32_t cdc_read_buf_xmd(/*P_USB_CDC pCdc,*/ void* data, uint32_t length); + +#endif // _SAM_BA_USB_CDC_H_ diff --git a/bootloaders/zero/sam_ba_monitor.c b/bootloaders/zero/sam_ba_monitor.c new file mode 100644 index 0000000..619d133 --- /dev/null +++ b/bootloaders/zero/sam_ba_monitor.c @@ -0,0 +1,723 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 +*/ + +#include "sam.h" +#include +#include "sam_ba_monitor.h" +#include "sam_ba_serial.h" +#include "board_driver_serial.h" +#include "board_driver_usb.h" +#include "board_driver_jtag.h" +#include "sam_ba_usb.h" +#include "sam_ba_cdc.h" +#include "board_driver_led.h" +#include + +const char RomBOOT_Version[] = SAM_BA_VERSION; +// X = Chip Erase, Y = Write Buffer, Z = Checksum Buffer, P = Secure Bit Aware +const char RomBOOT_ExtendedCapabilities[] = "[Arduino:XYZP]"; + +/* Provides one common interface to handle both USART and USB-CDC */ +typedef struct +{ + /* send one byte of data */ + int (*put_c)(int value); + /* Get one byte */ + int (*get_c)(void); + /* Receive buffer not empty */ + bool (*is_rx_ready)(void); + /* Send given data (polling) */ + uint32_t (*putdata)(void const* data, uint32_t length); + /* Get data from comm. device */ + uint32_t (*getdata)(void* data, uint32_t length); + /* Send given data (polling) using xmodem (if necessary) */ + uint32_t (*putdata_xmd)(void const* data, uint32_t length); + /* Get data from comm. device using xmodem (if necessary) */ + uint32_t (*getdata_xmd)(void* data, uint32_t length); +} t_monitor_if; + +#if defined(SAM_BA_UART_ONLY) || defined(SAM_BA_BOTH_INTERFACES) +/* Initialize structures with function pointers from supported interfaces */ +const t_monitor_if uart_if = +{ + .put_c = serial_putc, + .get_c = serial_getc, + .is_rx_ready = serial_is_rx_ready, + .putdata = serial_putdata, + .getdata = serial_getdata, + .putdata_xmd = serial_putdata_xmd, + .getdata_xmd = serial_getdata_xmd +}; +#endif + +#if defined(SAM_BA_USBCDC_ONLY) || defined(SAM_BA_BOTH_INTERFACES) +//Please note that USB doesn't use Xmodem protocol, since USB already includes flow control and data verification +//Data are simply forwarded without further coding. +const t_monitor_if usbcdc_if = +{ + .put_c = cdc_putc, + .get_c = cdc_getc, + .is_rx_ready = cdc_is_rx_ready, + .putdata = cdc_write_buf, + .getdata = cdc_read_buf, + .putdata_xmd = cdc_write_buf, + .getdata_xmd = cdc_read_buf_xmd +}; +#endif + +/* The pointer to the interface object use by the monitor */ +t_monitor_if * ptr_monitor_if; + +#ifdef SECURE_BY_DEFAULT +bool b_security_enabled = true; +#else +bool b_security_enabled = false; +#endif + +/* b_terminal_mode mode (ascii) or hex mode */ +volatile bool b_terminal_mode = false; +volatile bool b_sam_ba_interface_usart = false; + +/* Pulse generation counters to keep track of the time remaining for each pulse type */ +#define TX_RX_LED_PULSE_PERIOD 100 +volatile uint16_t txLEDPulse = 0; // time remaining for Tx LED pulse +volatile uint16_t rxLEDPulse = 0; // time remaining for Rx LED pulse + +void sam_ba_monitor_init(uint8_t com_interface) +{ +#if defined(SAM_BA_UART_ONLY) || defined(SAM_BA_BOTH_INTERFACES) + //Selects the requested interface for future actions + if (com_interface == SAM_BA_INTERFACE_USART) + { + ptr_monitor_if = (t_monitor_if*) &uart_if; + b_sam_ba_interface_usart = true; + } +#endif +#if defined(SAM_BA_USBCDC_ONLY) || defined(SAM_BA_BOTH_INTERFACES) + if (com_interface == SAM_BA_INTERFACE_USBCDC) + { + ptr_monitor_if = (t_monitor_if*) &usbcdc_if; + } +#endif +} + +/* + * Central SAM-BA monitor putdata function using the board LEDs + */ +static uint32_t sam_ba_putdata(t_monitor_if* pInterface, void const* data, uint32_t length) +{ + uint32_t result ; + + result=pInterface->putdata(data, length); + + LEDTX_on(); + txLEDPulse = TX_RX_LED_PULSE_PERIOD; + + return result; +} + +/* + * Central SAM-BA monitor getdata function using the board LEDs + */ +static uint32_t sam_ba_getdata(t_monitor_if* pInterface, void* data, uint32_t length) +{ + uint32_t result ; + + result=pInterface->getdata(data, length); + + if (result) + { + LEDRX_on(); + rxLEDPulse = TX_RX_LED_PULSE_PERIOD; + } + + return result; +} + +/* + * Central SAM-BA monitor putdata function using the board LEDs + */ +static uint32_t sam_ba_putdata_xmd(t_monitor_if* pInterface, void const* data, uint32_t length) +{ + uint32_t result ; + + result=pInterface->putdata_xmd(data, length); + + LEDTX_on(); + txLEDPulse = TX_RX_LED_PULSE_PERIOD; + + return result; +} + +/* + * Central SAM-BA monitor getdata function using the board LEDs + */ +static uint32_t sam_ba_getdata_xmd(t_monitor_if* pInterface, void* data, uint32_t length) +{ + uint32_t result ; + + result=pInterface->getdata_xmd(data, length); + + if (result) + { + LEDRX_on(); + rxLEDPulse = TX_RX_LED_PULSE_PERIOD; + } + + return result; +} + +/** + * \brief This function allows data emission by USART + * + * \param *data Data pointer + * \param length Length of the data + */ +void sam_ba_putdata_term(uint8_t* data, uint32_t length) +{ + uint8_t temp, buf[12], *data_ascii; + uint32_t i, int_value; + + if (b_terminal_mode) + { + if (length == 4) + int_value = *(uint32_t *) data; + else if (length == 2) + int_value = *(uint16_t *) data; + else + int_value = *(uint8_t *) data; + + data_ascii = buf + 2; + data_ascii += length * 2 - 1; + + for (i = 0; i < length * 2; i++) + { + temp = (uint8_t) (int_value & 0xf); + + if (temp <= 0x9) + *data_ascii = temp | 0x30; + else + *data_ascii = temp + 0x37; + + int_value >>= 4; + data_ascii--; + } + buf[0] = '0'; + buf[1] = 'x'; + buf[length * 2 + 2] = '\n'; + buf[length * 2 + 3] = '\r'; + sam_ba_putdata(ptr_monitor_if, buf, length * 2 + 4); + } + else + sam_ba_putdata(ptr_monitor_if, data, length); + return; +} + +#ifndef SECURE_BY_DEFAULT +volatile uint32_t sp; +void call_applet(uint32_t address) +{ + if (b_security_enabled) { + return; + } + + uint32_t app_start_address; + + __disable_irq(); + + sp = __get_MSP(); + + /* Rebase the Stack Pointer */ + __set_MSP(*(uint32_t *) address); + + /* Load the Reset Handler address of the application */ + app_start_address = *(uint32_t *)(address + 4); + + /* Jump to application Reset Handler in the application */ + asm("bx %0"::"r"(app_start_address)); +} +#endif + +uint32_t current_number; +uint32_t erased_from = 0; +uint32_t i, length; +uint8_t command, *ptr_data, *ptr, data[SIZEBUFMAX]; +uint8_t j; +uint32_t u32tmp; + +uint32_t PAGE_SIZE, PAGES, MAX_FLASH; + +// Prints a 32-bit integer in hex. +static void put_uint32(uint32_t n) +{ + char buff[8]; + int i; + for (i=0; i<8; i++) + { + int d = n & 0XF; + n = (n >> 4); + + buff[7-i] = d > 9 ? 'A' + d - 10 : '0' + d; + } + sam_ba_putdata( ptr_monitor_if, buff, 8); +} + +static void eraseFlash(uint32_t dst_addr) +{ + erased_from = dst_addr; + while (dst_addr < MAX_FLASH) + { + // Execute "ER" Erase Row + NVMCTRL->ADDR.reg = dst_addr / 2; + NVMCTRL->CTRLA.reg = NVMCTRL_CTRLA_CMDEX_KEY | NVMCTRL_CTRLA_CMD_ER; + while (NVMCTRL->INTFLAG.bit.READY == 0) + ; + dst_addr += PAGE_SIZE * 4; // Skip a ROW + } +} + +#ifdef ENABLE_JTAG_LOAD +static uint32_t offset = __UINT32_MAX__; +static bool flashNeeded = false; +#endif + +static void sam_ba_monitor_loop(void) +{ + length = sam_ba_getdata(ptr_monitor_if, data, SIZEBUFMAX); + ptr = data; + + for (i = 0; i < length; i++, ptr++) + { + if (*ptr == 0xff) continue; + + if (*ptr == '#') + { + if (b_terminal_mode) + { + sam_ba_putdata(ptr_monitor_if, "\n\r", 2); + } + if (command == 'S') // Write memory (normally RAM, but might be flash, if client handles the Flash MCU commands?) + { + //Check if some data are remaining in the "data" buffer + if(length>i) + { + //Move current indexes to next avail data (currently ptr points to "#") + ptr++; + i++; + + //We need to add first the remaining data of the current buffer already read from usb + //read a maximum of "current_number" bytes + if ((length-i) < current_number) + { + u32tmp=(length-i); + } + else + { + u32tmp=current_number; + } + + memcpy(ptr_data, ptr, u32tmp); + i += u32tmp; + ptr += u32tmp; + j = u32tmp; + } + //update i with the data read from the buffer + i--; + ptr--; + //Do we expect more data ? + if(j= 0x0000 && (uint32_t)ptr_data < 0x20000000)) + { + ptr_data = (uint8_t *)0x20005000; + } + + sam_ba_putdata_xmd(ptr_monitor_if, ptr_data, current_number); + } + else if (command == 'O') // write byte + { + *ptr_data = (char) current_number; + } + else if (command == 'H') // Write half word + { + *((uint16_t *) ptr_data) = (uint16_t) current_number; + } + else if (command == 'W') // Write word + { + *((int *) ptr_data) = current_number; + } + else if (command == 'o') // Read byte + { + // Flash memory starts at address 0 and runs to flash size 0x40000 (256 KByte). RAM starts at 0x20000000. + // Intern RWW section is at adress 0x400000. RWW is flash used for EEPROM emulation. Will not let anyone read that, when in secure mode, either. + // BOSSA reads address 0 to check something, but using read word instead of read byte, but in any case allow reading first byte + // Bootloader ends at 0x1FFF, so user programs start at 0x2000 + if (b_security_enabled && ((uint32_t)ptr_data > 0x0003 && (uint32_t)ptr_data < 0x20000000)) + { + ptr_data = (uint8_t*) ¤t_number; + } + + sam_ba_putdata_term(ptr_data, 1); + } + else if (command == 'h') // Read half word + { + // Flash memory starts at address 0 and runs to flash size 0x40000 (256 KByte). RAM starts at 0x20000000. + // Intern RWW section is at adress 0x400000. RWW is flash used for EEPROM emulation. Will not let anyone read that, when in secure mode, either. + // BOSSA reads address 0 to check something, but using read word instead of read byte, but in any case allow reading first byte + // Bootloader ends at 0x1FFF, so user programs start at 0x2000 + if (b_security_enabled && ((uint32_t)ptr_data > 0x0003 && (uint32_t)ptr_data < 0x20000000)) + { + current_number = 0; + } + else + { + current_number = *((uint16_t *) ptr_data); + } + + sam_ba_putdata_term((uint8_t*) ¤t_number, 2); + } + else if (command == 'w') // Read word + { + // Flash memory starts at address 0 and runs to flash size 0x40000 (256 KByte). RAM starts at 0x20000000. + // Intern RWW section is at adress 0x400000. RWW is flash used for EEPROM emulation. Will not let anyone read that, when in secure mode, either. + // BOSSA reads address 0 to check something, but using read word instead of read byte, but in any case allow reading first byte + // Bootloader ends at 0x1FFF, so user programs start at 0x2000 + if (b_security_enabled && ((uint32_t)ptr_data > 0x0003 && (uint32_t)ptr_data < 0x20000000)) + { + current_number = 0; + } + else + { + current_number = *((uint32_t *) ptr_data); + } + + sam_ba_putdata_term((uint8_t*) ¤t_number, 4); + } +#ifndef SECURE_BY_DEFAULT + else if (!b_security_enabled && command == 'G') // Execute code. Will not allow when security is enabled. + { + call_applet(current_number); + /* Rebase the Stack Pointer */ + __set_MSP(sp); + __enable_irq(); + if (b_sam_ba_interface_usart) { + ptr_monitor_if->put_c(0x6); + } + } +#endif + else if (command == 'T') // Turn on terminal mode + { + b_terminal_mode = 1; + sam_ba_putdata(ptr_monitor_if, "\n\r", 2); + } + else if (command == 'N') // Turn off terminal mode + { + if (b_terminal_mode == 0) + { + sam_ba_putdata( ptr_monitor_if, "\n\r", 2); + } + b_terminal_mode = 0; + } + else if (command == 'V') // Read version information + { + sam_ba_putdata( ptr_monitor_if, "v", 1); + sam_ba_putdata( ptr_monitor_if, (uint8_t *) RomBOOT_Version, strlen(RomBOOT_Version)); + sam_ba_putdata( ptr_monitor_if, " ", 1); + sam_ba_putdata( ptr_monitor_if, (uint8_t *) RomBOOT_ExtendedCapabilities, strlen(RomBOOT_ExtendedCapabilities)); + ptr = (uint8_t*) &(" " __DATE__ " " __TIME__ "\n\r"); + sam_ba_putdata( ptr_monitor_if, ptr, strlen(ptr)); + } + else if (command == 'X') // Erase flash + { + // Syntax: X[ADDR]# + // Erase the flash memory starting from ADDR to the end of flash. + + // Note: the flash memory is erased in ROWS, that is in block of 4 pages. + // Even if the starting address is the last byte of a ROW the entire + // ROW is erased anyway. + + // BOSSAC.exe always erase with 0x2000 as argument, but an attacker might try to erase just parts of the flash, to be able to copy or analyze the untouched parts. + // To mitigate this, always erase all sketch flash, that is, starting from address 0x2000. This butloader always assume 8 KByte for itself, and sketch starting at 0x2000. + eraseFlash(b_security_enabled ? 0x2000 : current_number); + // Notify command completed + sam_ba_putdata( ptr_monitor_if, "X\n\r", 3); + } + else if (command == 'Y') // Write buffer to flash + { + // This command writes the content of a buffer in SRAM into flash memory. + + // Syntax: Y[ADDR],0# + // Set the starting address of the SRAM buffer. + + // Syntax: Y[ROM_ADDR],[SIZE]# + // Write the first SIZE bytes from the SRAM buffer (previously set) into + // flash memory starting from address ROM_ADDR + + static uint32_t *src_buff_addr = NULL; + + if (current_number == 0) + { + // Set buffer address + src_buff_addr = (uint32_t*)ptr_data; + } + else + { + if (b_security_enabled && erased_from != 0x2000) + { + // To mitigate that an attacker might not use the ordinary BOSSA method of erasing flash before programming, + // always erase flash, if it hasn't been done already. + eraseFlash(0x2000); + } + + // Write to flash + uint32_t size = current_number/4; + uint32_t *src_addr = src_buff_addr; + uint32_t *dst_addr = (uint32_t*)ptr_data; + +#ifdef ENABLE_JTAG_LOAD + + if ((uint32_t)dst_addr == 0x40000) { + if (jtagInit() != 0) { + // fail! + sam_ba_putdata( ptr_monitor_if, "y\n\r", 3); + return; + } + + // content of the first flash page: + // offset (32) : length(32) : sha256sum(256) : type (32) : force (32) = 48 bytes + // for every section; check last sector of the flash to understand if reflash is needed + externalFlashSignatures data[3]; + jtagFlashReadBlock(LAST_FLASH_PAGE, sizeof(data), (uint8_t*)data); + externalFlashSignatures* newData = (externalFlashSignatures*)src_addr; + for (int k=0; k<3; k++) { + if (newData[k].force != 0) { + offset = newData[k].offset; + flashNeeded = true; + break; + } + if ((data[k].type == newData[k].type) || (data[k].type == 0xFFFFFFFF)) { + if (newData[k].offset < offset) { + offset = newData[k].offset; + } + if (memcmp(data[k].sha256sum, newData[k].sha256sum, 32) != 0) { + flashNeeded = true; + break; + } + } + } + + // merge old page and new page + for (int k=0; k<3; k++) { + if (newData[k].type != 0xFFFFFFFF) { + memcpy(&data[k], &newData[k], sizeof(newData[k])); + } + } + + jtagFlashEraseBlock(SCRATCHPAD_FLASH_PAGE); + // write first page to SCRATCHPAD_FLASH_PAGE (to allow correct verification) + for (int j =0; j= 0x41000) { + + if (flashNeeded == false) { + goto end; + } + + uint32_t rebasedAddress = (uint32_t)dst_addr - 0x41000 + offset; + if (rebasedAddress % 0x10000 == 0) { + jtagFlashEraseBlock(rebasedAddress); + } + + for (int j =0; jCTRLB.bit.MANW = 0; + + // Do writes in pages + while (size) + { + // Execute "PBC" Page Buffer Clear + NVMCTRL->CTRLA.reg = NVMCTRL_CTRLA_CMDEX_KEY | NVMCTRL_CTRLA_CMD_PBC; + while (NVMCTRL->INTFLAG.bit.READY == 0) + ; + + // Fill page buffer + uint32_t i; + for (i=0; i<(PAGE_SIZE/4) && iADDR.reg = ((uint32_t)dst_addr) / 2; + NVMCTRL->CTRLA.reg = NVMCTRL_CTRLA_CMDEX_KEY | NVMCTRL_CTRLA_CMD_WP; + while (NVMCTRL->INTFLAG.bit.READY == 0) + ; + + // Advance to next page + dst_addr += i; + src_addr += i; + size -= i; + } + } + +end: + + // Notify command completed + sam_ba_putdata( ptr_monitor_if, "Y\n\r", 3); + } + else if (command == 'Z') // Calculate CRC16 + { + // This command calculate CRC for a given area of memory. + // It's useful to quickly check if a transfer has been done + // successfully. + + // Syntax: Z[START_ADDR],[SIZE]# + // Returns: Z[CRC]# + + uint8_t *data; + uint32_t size = current_number; + uint16_t crc = 0; + uint32_t i = 0; + +#ifdef ENABLE_JTAG_LOAD + uint8_t buf[4096]; +#endif + +#ifdef ENABLE_JTAG_LOAD + if ((uint32_t)ptr_data == 0x40000) { + data = (uint8_t*)buf; + for (int j =0; j= 0x41000) { + data = (uint8_t*)buf; + for (int j =0; j", 1); + } + } + else + { + if (('0' <= *ptr) && (*ptr <= '9')) + { + current_number = (current_number << 4) | (*ptr - '0'); + } + else if (('A' <= *ptr) && (*ptr <= 'F')) + { + current_number = (current_number << 4) | (*ptr - 'A' + 0xa); + } + else if (('a' <= *ptr) && (*ptr <= 'f')) + { + current_number = (current_number << 4) | (*ptr - 'a' + 0xa); + } + else if (*ptr == ',') + { + ptr_data = (uint8_t *) current_number; + current_number = 0; + } + else + { + command = *ptr; + current_number = 0; + } + } + } +} + +void sam_ba_monitor_sys_tick(void) +{ + /* Check whether the TX or RX LED one-shot period has elapsed. if so, turn off the LED */ + if (txLEDPulse && !(--txLEDPulse)) + LEDTX_off(); + if (rxLEDPulse && !(--rxLEDPulse)) + LEDRX_off(); +} + +/** + * \brief This function starts the SAM-BA monitor. + */ +void sam_ba_monitor_run(void) +{ + uint32_t pageSizes[] = { 8, 16, 32, 64, 128, 256, 512, 1024 }; + PAGE_SIZE = pageSizes[NVMCTRL->PARAM.bit.PSZ]; + PAGES = NVMCTRL->PARAM.bit.NVMP; + MAX_FLASH = PAGE_SIZE * PAGES; + +#ifdef SECURE_BY_DEFAULT + b_security_enabled = true; +#else + b_security_enabled = NVMCTRL->STATUS.bit.SB != 0; +#endif + + ptr_data = NULL; + command = 'z'; + while (1) + { + sam_ba_monitor_loop(); + } +} diff --git a/bootloaders/zero/sam_ba_monitor.h b/bootloaders/zero/sam_ba_monitor.h new file mode 100644 index 0000000..122b22a --- /dev/null +++ b/bootloaders/zero/sam_ba_monitor.h @@ -0,0 +1,72 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 _MONITOR_SAM_BA_H_ +#define _MONITOR_SAM_BA_H_ + +#include "board_definitions.h" + +#define SAM_BA_VERSION "2.0" + +#if !defined(SAM_BA_BOTH_INTERFACES) && !defined(SAM_BA_UART_ONLY) && !defined(SAM_BA_USBCDC_ONLY) +#define SAM_BA_BOTH_INTERFACES +#endif + +/* Selects USB as the communication interface of the monitor */ +#define SAM_BA_INTERFACE_USBCDC 0 +/* Selects USART as the communication interface of the monitor */ +#define SAM_BA_INTERFACE_USART 1 + +/* Selects USB as the communication interface of the monitor */ +#define SIZEBUFMAX 64 + +// Set this flag to let the bootloader enforce read restrictions of flash memory, even if security bit is not set +//#define SECURE_BY_DEFAULT + +/** + * \brief Initialize the monitor + * + */ +void sam_ba_monitor_init(uint8_t com_interface); + +/** + * \brief System tick function of the SAM-BA Monitor + * + */ +void sam_ba_monitor_sys_tick(void); + +/** + * \brief Main function of the SAM-BA Monitor + * + */ +void sam_ba_monitor_run(void); + +/** + * \brief + * + */ +void sam_ba_putdata_term(uint8_t* data, uint32_t length); + +/** + * \brief + * + */ +void call_applet(uint32_t address); + +#endif // _MONITOR_SAM_BA_H_ diff --git a/bootloaders/zero/sam_ba_serial.c b/bootloaders/zero/sam_ba_serial.c new file mode 100644 index 0000000..53e6626 --- /dev/null +++ b/bootloaders/zero/sam_ba_serial.c @@ -0,0 +1,538 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 +*/ + +#include +#include "board_definitions.h" +#include "sam_ba_serial.h" +#include "board_driver_serial.h" + +#if defined(SAM_BA_UART_ONLY) || defined(SAM_BA_BOTH_INTERFACES) + +/* Local reference to current Usart instance in use with this driver */ +//struct usart_module usart_sam_ba; + +/* Variable to let the main task select the appropriate communication interface */ +volatile uint8_t b_sharp_received; + +/* RX and TX Buffers + rw pointers for each buffer */ +volatile uint8_t buffer_rx_usart[USART_BUFFER_SIZE]; + +volatile uint8_t idx_rx_read; +volatile uint8_t idx_rx_write; + +volatile uint8_t buffer_tx_usart[USART_BUFFER_SIZE]; + +volatile uint8_t idx_tx_read; +volatile uint8_t idx_tx_write; + +/* Test for timeout in AT91F_GetChar */ +uint8_t error_timeout; +uint16_t size_of_data; +uint8_t mode_of_transfer; + +#define BOOT_USART_PAD(n) BOOT_USART_PAD##n + +/** + * \brief Open the given USART + */ +void serial_open(void) +{ + uint32_t port; + uint32_t pin; + + /* Configure the port pins for SERCOM_USART */ + if (BOOT_USART_PAD0 != PINMUX_UNUSED) + { + /* Mask 6th bit in pin number to check whether it is greater than 32 i.e., PORTB pin */ + port = (BOOT_USART_PAD0 & 0x200000) >> 21; + pin = (BOOT_USART_PAD0 >> 16); + PORT->Group[port].PINCFG[(pin - (port*32))].bit.PMUXEN = 1; + PORT->Group[port].PMUX[(pin - (port*32))/2].reg &= ~(0xF << (4 * (pin & 0x01u))); + PORT->Group[port].PMUX[(pin - (port*32))/2].reg |= (BOOT_USART_PAD0 & 0xFF) << (4 * (pin & 0x01u)); + } + + if (BOOT_USART_PAD1 != PINMUX_UNUSED) + { + /* Mask 6th bit in pin number to check whether it is greater than 32 i.e., PORTB pin */ + port = (BOOT_USART_PAD1 & 0x200000) >> 21; + pin = BOOT_USART_PAD1 >> 16; + PORT->Group[port].PINCFG[(pin - (port*32))].bit.PMUXEN = 1; + PORT->Group[port].PMUX[(pin - (port*32))/2].reg &= ~(0xF << (4 * (pin & 0x01u))); + PORT->Group[port].PMUX[(pin - (port*32))/2].reg |= (BOOT_USART_PAD1 & 0xFF) << (4 * (pin & 0x01u)); + } + + if (BOOT_USART_PAD2 != PINMUX_UNUSED) + { + /* Mask 6th bit in pin number to check whether it is greater than 32 i.e., PORTB pin */ + port = (BOOT_USART_PAD2 & 0x200000) >> 21; + pin = BOOT_USART_PAD2 >> 16; + PORT->Group[port].PINCFG[(pin - (port*32))].bit.PMUXEN = 1; + PORT->Group[port].PMUX[(pin - (port*32))/2].reg &= ~(0xF << (4 * (pin & 0x01u))); + PORT->Group[port].PMUX[(pin - (port*32))/2].reg |= (BOOT_USART_PAD2 & 0xFF) << (4 * (pin & 0x01u)); + } + + if (BOOT_USART_PAD3 != PINMUX_UNUSED) + { + /* Mask 6th bit in pin number to check whether it is greater than 32 i.e., PORTB pin */ + port = (BOOT_USART_PAD3 & 0x200000) >> 21; + pin = BOOT_USART_PAD3 >> 16; + PORT->Group[port].PINCFG[(pin - (port*32))].bit.PMUXEN = 1; + PORT->Group[port].PMUX[(pin - (port*32))/2].reg &= ~(0xF << (4 * (pin & 0x01u))); + PORT->Group[port].PMUX[(pin - (port*32))/2].reg |= (BOOT_USART_PAD3 & 0xFF) << (4 * (pin & 0x01u)); + } + + /* Enable clock for BOOT_USART_MODULE */ + PM->APBCMASK.reg |= BOOT_USART_BUS_CLOCK_INDEX ; + + /* Set GCLK_GEN0 as source for GCLK_ID_SERCOMx_CORE */ + GCLK->CLKCTRL.reg = GCLK_CLKCTRL_ID( BOOT_USART_PER_CLOCK_INDEX ) | // Generic Clock 0 (SERCOMx) + GCLK_CLKCTRL_GEN_GCLK0 | // Generic Clock Generator 0 is source + GCLK_CLKCTRL_CLKEN ; + + while ( GCLK->STATUS.reg & GCLK_STATUS_SYNCBUSY ) + { + /* Wait for synchronization */ + } + + /* Baud rate 115200 - clock 48MHz -> BAUD value-63018 */ + uart_basic_init(BOOT_USART_MODULE, 63018, BOOT_USART_PAD_SETTINGS); + + //Initialize flag + b_sharp_received = false; + idx_rx_read = 0; + idx_rx_write = 0; + idx_tx_read = 0; + idx_tx_write = 0; + + error_timeout = 0; +} + +/** + * \brief Close communication line + */ +void serial_close(void) +{ + uart_disable(BOOT_USART_MODULE); +} + +/** + * \brief Puts a byte on usart line + * The type int is used to support printf redirection from compiler LIB. + * + * \param value Value to put + * + * \return \c 1 if function was successfully done, otherwise \c 0. + */ +int serial_putc(int value) +{ + uart_write_byte(BOOT_USART_MODULE, (uint8_t)value); + return 1; +} + +int serial_getc(void) +{ + uint16_t retval; + //Wait until input buffer is filled + while(!(serial_is_rx_ready())); + retval = (uint16_t)uart_read_byte(BOOT_USART_MODULE); + //usart_read_wait(&usart_sam_ba, &retval); + return (int)retval; + +} + +int serial_sharp_received(void) +{ + if (serial_is_rx_ready()) + { + if (serial_getc() == SHARP_CHARACTER) + return (true); + } + return (false); +} + +bool serial_is_rx_ready(void) +{ + return (BOOT_USART_MODULE->USART.INTFLAG.reg & SERCOM_USART_INTFLAG_RXC); +} + +int serial_readc(void) +{ + int retval; + retval = buffer_rx_usart[idx_rx_read]; + idx_rx_read = (idx_rx_read + 1) & (USART_BUFFER_SIZE - 1); + return (retval); +} + +//Send given data (polling) +uint32_t serial_putdata(void const* data, uint32_t length) +{ + uint32_t i; + uint8_t* ptrdata; + ptrdata = (uint8_t*) data; + for (i = 0; i < length; i++) + { + serial_putc(*ptrdata); + ptrdata++; + } + return (i); +} + +//Get data from comm. device +uint32_t serial_getdata(void* data, uint32_t length) +{ + uint8_t* ptrdata; + ptrdata = (uint8_t*) data; + *ptrdata = serial_getc(); + return (1); +} + + +//*---------------------------------------------------------------------------- +//* \brief +//*---------------------------------------------------------------------------- +static uint16_t getbytes(uint8_t *ptr_data, uint16_t length) +{ + uint16_t crc = 0; + uint16_t cpt; + uint8_t c; + + for (cpt = 0; cpt < length; ++cpt) + { + c = serial_getc(); + if (error_timeout) + return 1; + crc = serial_add_crc(c, crc); + //crc = (crc << 8) ^ xcrc16tab[(crc>>8) ^ c]; + if (size_of_data || mode_of_transfer) + { + *ptr_data++ = c; + if (length == PKTLEN_128) + size_of_data--; + } + } + + return crc; +} + +//*---------------------------------------------------------------------------- +//* \brief Used by Xup to send packets. +//*---------------------------------------------------------------------------- +static int putPacket(uint8_t *tmppkt, uint8_t sno) +{ + uint32_t i; + uint16_t chksm; + uint8_t data; + + chksm = 0; + + serial_putc(SOH); + + serial_putc(sno); + serial_putc((uint8_t) ~(sno)); + + for (i = 0; i < PKTLEN_128; i++) + { + if (size_of_data || mode_of_transfer) + { + data = *tmppkt++; + size_of_data--; + } + else + data = 0x00; + + serial_putc(data); + + //chksm = (chksm<<8) ^ xcrc16tab[(chksm>>8)^data]; + chksm = serial_add_crc(data, chksm); + } + + /* An "endian independent way to extract the CRC bytes. */ + serial_putc((uint8_t) (chksm >> 8)); + serial_putc((uint8_t) chksm); + + return (serial_getc()); /* Wait for ack */ +} + +//*---------------------------------------------------------------------------- +//* \brief Called when a transfer from target to host is being made (considered +//* an upload). +//*---------------------------------------------------------------------------- +//Send given data (polling) using xmodem (if necessary) +uint32_t serial_putdata_xmd(void const* data, uint32_t length) +{ + uint8_t c, sno = 1; + uint8_t done; + uint8_t * ptr_data = (uint8_t *) data; + error_timeout = 0; + if (!length) + mode_of_transfer = 1; + else + { + size_of_data = length; + mode_of_transfer = 0; + } + + if (length & (PKTLEN_128 - 1)) + { + length += PKTLEN_128; + length &= ~(PKTLEN_128 - 1); + } + + /* Startup synchronization... */ + /* Wait to receive a NAK or 'C' from receiver. */ + done = 0; + while (!done) { + c = (uint8_t) serial_getc(); + if (error_timeout) + { // Test for timeout in serial_getc + error_timeout = 0; + c = (uint8_t) serial_getc(); + if (error_timeout) + { + error_timeout = 0; + return (0); + } + } + switch (c) + { + case NAK: + done = 1; + // ("CSM"); + break; + case 'C': + done = 1; + // ("CRC"); + break; + case 'q': /* ELS addition, not part of XMODEM spec. */ + return (0); + default: + break; + } + } + + done = 0; + sno = 1; + while (!done) + { + c = (uint8_t) putPacket((uint8_t *) ptr_data, sno); + if (error_timeout) + { // Test for timeout in serial_getc + error_timeout = 0; + return (0); + } + switch (c) + { + case ACK: + ++sno; + length -= PKTLEN_128; + ptr_data += PKTLEN_128; + // ("A"); + break; + + case NAK: + // ("N"); + break; + + case CAN: + case EOT: + default: + done = 0; + break; + } + + if (!length) + { + serial_putc(EOT); + serial_getc(); /* Flush the ACK */ + break; + } + // ("!"); + } + + mode_of_transfer = 0; + // ("Xup_done."); + return (1); + // return(0); +} + +/*---------------------------------------------------------------------------- + * \brief Used by serial_getdata_xmd to retrieve packets. + */ +static uint8_t getPacket(uint8_t *ptr_data, uint8_t sno) +{ + uint8_t seq[2]; + uint16_t crc, xcrc; + + getbytes(seq, 2); + xcrc = getbytes(ptr_data, PKTLEN_128); + if (error_timeout) + return (false); + + /* An "endian independent way to combine the CRC bytes. */ + crc = (uint16_t) serial_getc() << 8; + crc += (uint16_t) serial_getc(); + + if (error_timeout == 1) + return (false); + + if ((crc != xcrc) || (seq[0] != sno) || (seq[1] != (uint8_t) (~sno))) + { + serial_putc(CAN); + return (false); + } + + serial_putc(ACK); + return (true); +} + +//*---------------------------------------------------------------------------- +//* \brief Called when a transfer from host to target is being made (considered +//* an download). +//*---------------------------------------------------------------------------- +//Get data from comm. device using xmodem (if necessary) +uint32_t serial_getdata_xmd(void* data, uint32_t length) +{ + uint32_t timeout; + char c; + uint8_t * ptr_data = (uint8_t *) data; + uint32_t b_run, nbr_of_timeout = 100; + uint8_t sno = 0x01; + uint32_t data_transfered = 0; + + //Copied from legacy source code ... might need some tweaking + uint32_t loops_per_second = CPU_FREQUENCY/60; + + error_timeout = 0; + + if (length == 0) + mode_of_transfer = 1; + else + { + size_of_data = length; + mode_of_transfer = 0; + } + + /* Startup synchronization... */ + /* Continuously send NAK or 'C' until sender responds. */ + // ("Xdown"); + while (1) + { + serial_putc('C'); + timeout = loops_per_second; + while (!(serial_is_rx_ready()) && timeout) + timeout--; + if (timeout) + break; + + if (!(--nbr_of_timeout)) + return (0); +// return -1; + } + + b_run = true; + // ("Got response"); + while (b_run != false) + { + c = (char) serial_getc(); + if (error_timeout) + { // Test for timeout in serial_getc + error_timeout = 0; + return (0); +// return (-1); + } + switch (c) + { + case SOH: /* 128-byte incoming packet */ + // ("O"); + b_run = getPacket(ptr_data, sno); + if (error_timeout) + { // Test for timeout in serial_getc + error_timeout = 0; + return (0); + // return (-1); + } + if (b_run == true) + { + ++sno; + ptr_data += PKTLEN_128; + data_transfered += PKTLEN_128; + } + break; + case EOT: // ("E"); + serial_putc(ACK); + b_run = false; + break; + case CAN: // ("C"); + case ESC: /* "X" User-invoked abort */ + default: + b_run = false; + break; + } + // ("!"); + } + mode_of_transfer = 0; + return (true); +// return(b_run); +} + +#endif + +static const uint16_t crc16Table[256]= +{ + 0x0000,0x1021,0x2042,0x3063,0x4084,0x50a5,0x60c6,0x70e7, + 0x8108,0x9129,0xa14a,0xb16b,0xc18c,0xd1ad,0xe1ce,0xf1ef, + 0x1231,0x0210,0x3273,0x2252,0x52b5,0x4294,0x72f7,0x62d6, + 0x9339,0x8318,0xb37b,0xa35a,0xd3bd,0xc39c,0xf3ff,0xe3de, + 0x2462,0x3443,0x0420,0x1401,0x64e6,0x74c7,0x44a4,0x5485, + 0xa56a,0xb54b,0x8528,0x9509,0xe5ee,0xf5cf,0xc5ac,0xd58d, + 0x3653,0x2672,0x1611,0x0630,0x76d7,0x66f6,0x5695,0x46b4, + 0xb75b,0xa77a,0x9719,0x8738,0xf7df,0xe7fe,0xd79d,0xc7bc, + 0x48c4,0x58e5,0x6886,0x78a7,0x0840,0x1861,0x2802,0x3823, + 0xc9cc,0xd9ed,0xe98e,0xf9af,0x8948,0x9969,0xa90a,0xb92b, + 0x5af5,0x4ad4,0x7ab7,0x6a96,0x1a71,0x0a50,0x3a33,0x2a12, + 0xdbfd,0xcbdc,0xfbbf,0xeb9e,0x9b79,0x8b58,0xbb3b,0xab1a, + 0x6ca6,0x7c87,0x4ce4,0x5cc5,0x2c22,0x3c03,0x0c60,0x1c41, + 0xedae,0xfd8f,0xcdec,0xddcd,0xad2a,0xbd0b,0x8d68,0x9d49, + 0x7e97,0x6eb6,0x5ed5,0x4ef4,0x3e13,0x2e32,0x1e51,0x0e70, + 0xff9f,0xefbe,0xdfdd,0xcffc,0xbf1b,0xaf3a,0x9f59,0x8f78, + 0x9188,0x81a9,0xb1ca,0xa1eb,0xd10c,0xc12d,0xf14e,0xe16f, + 0x1080,0x00a1,0x30c2,0x20e3,0x5004,0x4025,0x7046,0x6067, + 0x83b9,0x9398,0xa3fb,0xb3da,0xc33d,0xd31c,0xe37f,0xf35e, + 0x02b1,0x1290,0x22f3,0x32d2,0x4235,0x5214,0x6277,0x7256, + 0xb5ea,0xa5cb,0x95a8,0x8589,0xf56e,0xe54f,0xd52c,0xc50d, + 0x34e2,0x24c3,0x14a0,0x0481,0x7466,0x6447,0x5424,0x4405, + 0xa7db,0xb7fa,0x8799,0x97b8,0xe75f,0xf77e,0xc71d,0xd73c, + 0x26d3,0x36f2,0x0691,0x16b0,0x6657,0x7676,0x4615,0x5634, + 0xd94c,0xc96d,0xf90e,0xe92f,0x99c8,0x89e9,0xb98a,0xa9ab, + 0x5844,0x4865,0x7806,0x6827,0x18c0,0x08e1,0x3882,0x28a3, + 0xcb7d,0xdb5c,0xeb3f,0xfb1e,0x8bf9,0x9bd8,0xabbb,0xbb9a, + 0x4a75,0x5a54,0x6a37,0x7a16,0x0af1,0x1ad0,0x2ab3,0x3a92, + 0xfd2e,0xed0f,0xdd6c,0xcd4d,0xbdaa,0xad8b,0x9de8,0x8dc9, + 0x7c26,0x6c07,0x5c64,0x4c45,0x3ca2,0x2c83,0x1ce0,0x0cc1, + 0xef1f,0xff3e,0xcf5d,0xdf7c,0xaf9b,0xbfba,0x8fd9,0x9ff8, + 0x6e17,0x7e36,0x4e55,0x5e74,0x2e93,0x3eb2,0x0ed1,0x1ef0 +}; + +//*---------------------------------------------------------------------------- +//* \brief Compute the CRC +//*---------------------------------------------------------------------------- +unsigned short serial_add_crc(char ptr, unsigned short crc) +{ + return (crc << 8) ^ crc16Table[((crc >> 8) ^ ptr) & 0xff]; +} \ No newline at end of file diff --git a/bootloaders/zero/sam_ba_serial.h b/bootloaders/zero/sam_ba_serial.h new file mode 100644 index 0000000..cb69f45 --- /dev/null +++ b/bootloaders/zero/sam_ba_serial.h @@ -0,0 +1,143 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 _SAM_BA_SERIAL_H_ +#define _SAM_BA_SERIAL_H_ + +#include +#include + + +/* USART buffer size (must be a power of two) */ +#define USART_BUFFER_SIZE (128) + +/* Define the default time-out value for USART. */ +#define USART_DEFAULT_TIMEOUT (1000) + +/* Xmodem related defines */ +/* CRC16 polynomial */ +#define CRC16POLY (0x1021) + +#define SHARP_CHARACTER '#' + +/* X/Ymodem protocol: */ +#define SOH (0x01) +//#define STX (0x02) +#define EOT (0x04) +#define ACK (0x06) +#define NAK (0x15) +#define CAN (0x18) +#define ESC (0x1b) + +#define PKTLEN_128 (128) + + +/** + * \brief Open the given USART + */ +void serial_open(void); + +/** + * \brief Stops the USART + */ +void serial_close(void); + +/** + * \brief Puts a byte on usart line + * + * \param value Value to put + * + * \return \c 1 if function was successfully done, otherwise \c 0. + */ +int serial_putc(int value); + +/** + * \brief Waits and gets a value on usart line + * + * \return value read on usart line + */ +int serial_getc(void); + +/** + * \brief Returns true if the SAM-BA Uart received the sharp char + * + * \return Returns true if the SAM-BA Uart received the sharp char + */ +int serial_sharp_received(void); + +/** + * \brief This function checks if a character has been received on the usart line + * + * \return \c 1 if a byte is ready to be read. + */ +bool serial_is_rx_ready(void); + +/** + * \brief Gets a value on usart line + * + * \return value read on usart line + */ +int serial_readc(void); + +/** + * \brief Send buffer on usart line + * + * \param data pointer + * \param number of data to send + * \return number of data sent + */ +uint32_t serial_putdata(void const* data, uint32_t length); //Send given data (polling) + +/** + * \brief Gets data from usart line + * + * \param data pointer + * \param number of data to get + * \return value read on usart line + */ +uint32_t serial_getdata(void* data, uint32_t length); //Get data from comm. device + +/** + * \brief Send buffer on usart line using Xmodem protocol + * + * \param data pointer + * \param number of data to send + * \return number of data sent + */ +uint32_t serial_putdata_xmd(void const* data, uint32_t length); //Send given data (polling) using xmodem (if necessary) + +/** + * \brief Gets data from usart line using Xmodem protocol + * + * \param data pointer + * \param number of data to get + * \return value read on usart line + */ +uint32_t serial_getdata_xmd(void* data, uint32_t length); //Get data from comm. device using xmodem (if necessary) + +/** + * \brief Compute the CRC + * + * \param Char to add to CRC + * \param Previous CRC + * \return The new computed CRC + */ +unsigned short serial_add_crc(char c, unsigned short crc); + +#endif // _SAM_BA_SERIAL_H_ diff --git a/bootloaders/zero/sam_ba_usb.c b/bootloaders/zero/sam_ba_usb.c new file mode 100644 index 0000000..955db39 --- /dev/null +++ b/bootloaders/zero/sam_ba_usb.c @@ -0,0 +1,441 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 +*/ + +#include +#include +#include "board_definitions.h" +#include "sam_ba_usb.h" +#include "board_driver_usb.h" +#include "sam_ba_cdc.h" + +#ifndef USB_CURRENT_MA +// default USB current, report using 100mA, enough for a bootloader +#define USB_CURRENT_MA 100 +#endif + +/* This data array will be copied into SRAM as its length is inferior to 64 bytes, + * and so can stay in flash. + */ +static __attribute__((__aligned__(4))) +const char devDescriptor[] = +{ + /* Device descriptor */ + 0x12, // bLength + 0x01, // bDescriptorType + 0x00, // bcdUSB L + 0x02, // bcdUSB H + 0x02, // bDeviceClass: CDC class code + 0x00, // bDeviceSubclass: CDC class sub code + 0x00, // bDeviceProtocol: CDC Device protocol + 0x40, // bMaxPacketSize0 + USB_VID_LOW, // idVendor L + USB_VID_HIGH, // idVendor H + USB_PID_LOW, // idProduct L + USB_PID_HIGH, // idProduct H + 0x00, // bcdDevice L, here matching SAM-BA version + 0x02, // bcdDevice H + STRING_INDEX_MANUFACTURER, // iManufacturer + STRING_INDEX_PRODUCT, // iProduct + 0x00, // SerialNumber, should be based on product unique ID + 0x01 // bNumConfigs +}; + +/* This data array will be consumed directly by USB_Write() and must be in SRAM. + * We cannot send data from product internal flash. + */ +static __attribute__((__aligned__(4))) +char cfgDescriptor[] = +{ + /* ============== CONFIGURATION 1 =========== */ + /* Configuration 1 descriptor */ + 0x09, // CbLength + 0x02, // CbDescriptorType + 0x43, // CwTotalLength 2 EP + Control + 0x00, + 0x02, // CbNumInterfaces + 0x01, // CbConfigurationValue + 0x00, // CiConfiguration + 0x80, // CbmAttributes Bus powered without remote wakeup: 0x80, Self powered without remote wakeup: 0xc0 + (USB_CURRENT_MA / 2), // CMaxPower + + /* Communication Class Interface Descriptor Requirement */ + 0x09, // bLength + 0x04, // bDescriptorType + 0x00, // bInterfaceNumber + 0x00, // bAlternateSetting + 0x01, // bNumEndpoints + 0x02, // bInterfaceClass + 0x02, // bInterfaceSubclass + 0x00, // bInterfaceProtocol + 0x00, // iInterface + + /* Header Functional Descriptor */ + 0x05, // bFunction Length + 0x24, // bDescriptor type: CS_INTERFACE + 0x00, // bDescriptor subtype: Header Func Desc + 0x10, // bcdCDC:1.1 + 0x01, + + /* ACM Functional Descriptor */ + 0x04, // bFunctionLength + 0x24, // bDescriptor Type: CS_INTERFACE + 0x02, // bDescriptor Subtype: ACM Func Desc + 0x00, // bmCapabilities + + /* Union Functional Descriptor */ + 0x05, // bFunctionLength + 0x24, // bDescriptorType: CS_INTERFACE + 0x06, // bDescriptor Subtype: Union Func Desc + 0x00, // bMasterInterface: Communication Class Interface + 0x01, // bSlaveInterface0: Data Class Interface + + /* Call Management Functional Descriptor */ + 0x05, // bFunctionLength + 0x24, // bDescriptor Type: CS_INTERFACE + 0x01, // bDescriptor Subtype: Call Management Func Desc + 0x00, // bmCapabilities: D1 + D0 + 0x01, // bDataInterface: Data Class Interface 1 + + /* Endpoint 1 descriptor */ + 0x07, // bLength + 0x05, // bDescriptorType + 0x83, // bEndpointAddress, Endpoint 03 - IN + 0x03, // bmAttributes INT + 0x08, // wMaxPacketSize + 0x00, + 0xFF, // bInterval + + /* Data Class Interface Descriptor Requirement */ + 0x09, // bLength + 0x04, // bDescriptorType + 0x01, // bInterfaceNumber + 0x00, // bAlternateSetting + 0x02, // bNumEndpoints + 0x0A, // bInterfaceClass + 0x00, // bInterfaceSubclass + 0x00, // bInterfaceProtocol + 0x00, // iInterface + + /* First alternate setting */ + /* Endpoint 1 descriptor */ + 0x07, // bLength + 0x05, // bDescriptorType + 0x81, // bEndpointAddress, Endpoint 01 - IN + 0x02, // bmAttributes BULK + USB_EP_IN_SIZE, // wMaxPacketSize + 0x00, + 0x00, // bInterval + + /* Endpoint 2 descriptor */ + 0x07, // bLength + 0x05, // bDescriptorType + 0x02, // bEndpointAddress, Endpoint 02 - OUT + 0x02, // bmAttributes BULK + USB_EP_OUT_SIZE, // wMaxPacketSize + 0x00, + 0x00 // bInterval +}; + +#ifndef STRING_MANUFACTURER +# define STRING_MANUFACTURER "Arduino LLC" +#endif + +#ifndef STRING_PRODUCT +# define STRING_PRODUCT "Arduino Zero" +#endif + +USB_CDC sam_ba_cdc; + +/*---------------------------------------------------------------------------- + * \brief This function is a callback invoked when a SETUP packet is received + */ +void sam_ba_usb_CDC_Enumerate(P_USB_CDC pCdc) +{ + Usb *pUsb = pCdc->pUsb; + static volatile uint8_t bmRequestType, bRequest, dir; + static volatile uint16_t wValue, wIndex, wLength, wStatus; + + /* Clear the Received Setup flag */ + pUsb->DEVICE.DeviceEndpoint[0].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_RXSTP; + + /* Read the USB request parameters */ + bmRequestType = udd_ep_out_cache_buffer[0][0]; + bRequest = udd_ep_out_cache_buffer[0][1]; + wValue = (udd_ep_out_cache_buffer[0][2] & 0xFF); + wValue |= (udd_ep_out_cache_buffer[0][3] << 8); + wIndex = (udd_ep_out_cache_buffer[0][4] & 0xFF); + wIndex |= (udd_ep_out_cache_buffer[0][5] << 8); + wLength = (udd_ep_out_cache_buffer[0][6] & 0xFF); + wLength |= (udd_ep_out_cache_buffer[0][7] << 8); + + /* Clear the Bank 0 ready flag on Control OUT */ + pUsb->DEVICE.DeviceEndpoint[0].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_BK0RDY; + + /* Handle supported standard device request Cf Table 9-3 in USB specification Rev 1.1 */ + switch ((bRequest << 8) | bmRequestType) + { + case STD_GET_DESCRIPTOR: + if (wValue>>8 == STD_GET_DESCRIPTOR_DEVICE) + { + /* Return Device Descriptor */ + USB_Write(pCdc->pUsb, devDescriptor, SAM_BA_MIN(sizeof(devDescriptor), wLength), USB_EP_CTRL); + } + else if (wValue>>8 == STD_GET_DESCRIPTOR_CONFIGURATION) + { + /* Return Configuration Descriptor */ + USB_Write(pCdc->pUsb, cfgDescriptor, SAM_BA_MIN(sizeof(cfgDescriptor), wLength), USB_EP_CTRL); + } + else if (wValue>>8 == STD_GET_DESCRIPTOR_STRING) + { + switch ( wValue & 0xff ) + { + case STRING_INDEX_LANGUAGES: { + uint16_t STRING_LANGUAGE[2] = { (STD_GET_DESCRIPTOR_STRING<<8) | 4, 0x0409 }; + + USB_Write(pCdc->pUsb, (const char*)STRING_LANGUAGE, SAM_BA_MIN(sizeof(STRING_LANGUAGE), wLength), USB_EP_CTRL); + } + break; + + case STRING_INDEX_MANUFACTURER: + USB_SendString(pCdc->pUsb, STRING_MANUFACTURER, wLength ); + break; + + case STRING_INDEX_PRODUCT: + USB_SendString(pCdc->pUsb, STRING_PRODUCT, wLength ); + break; + default: + /* Stall the request */ + USB_SendStall(pUsb, true); + break; + } + } + else + { + /* Stall the request */ + USB_SendStall(pUsb, true); + } + break; + + case STD_SET_ADDRESS: + /* Send ZLP */ + USB_SendZlp(pUsb); + /* Set device address to the newly received address from host */ + USB_SetAddress(pCdc->pUsb, wValue); + break; + + case STD_SET_CONFIGURATION: + /* Store configuration */ + pCdc->currentConfiguration = (uint8_t)wValue; + + /* Send ZLP */ + USB_SendZlp(pUsb); + + /* Configure the 3 needed endpoints */ + USB_Configure(pUsb); + break; + + case STD_GET_CONFIGURATION: + /* Return current configuration value */ + USB_Write(pCdc->pUsb, (char *) &(pCdc->currentConfiguration), sizeof(pCdc->currentConfiguration), USB_EP_CTRL); + break; + + case STD_GET_STATUS_ZERO: + wStatus = 0; + USB_Write(pCdc->pUsb, (char *) &wStatus, sizeof(wStatus), USB_EP_CTRL); + break; + + case STD_GET_STATUS_INTERFACE: + wStatus = 0; + USB_Write(pCdc->pUsb, (char *) &wStatus, sizeof(wStatus), USB_EP_CTRL); + break; + + case STD_GET_STATUS_ENDPOINT: + wStatus = 0; + dir = wIndex & 80; + wIndex &= 0x0F; + if (wIndex <= 3) + { + if (dir) + { + wStatus = (pUsb->DEVICE.DeviceEndpoint[wIndex].EPSTATUS.reg & USB_DEVICE_EPSTATUSSET_STALLRQ1) ? 1 : 0; + } + else + { + wStatus = (pUsb->DEVICE.DeviceEndpoint[wIndex].EPSTATUS.reg & USB_DEVICE_EPSTATUSSET_STALLRQ0) ? 1 : 0; + } + /* Return current status of endpoint */ + USB_Write(pCdc->pUsb, (char *) &wStatus, sizeof(wStatus), USB_EP_CTRL); + } + else + { + /* Stall the request */ + USB_SendStall(pUsb, true); + } + break; + + case STD_SET_FEATURE_ZERO: + /* Stall the request */ + USB_SendStall(pUsb, true); + break; + + case STD_SET_FEATURE_INTERFACE: + /* Send ZLP */ + USB_SendZlp(pUsb); + break; + + case STD_SET_FEATURE_ENDPOINT: + dir = wIndex & 0x80; + wIndex &= 0x0F; + if ((wValue == 0) && wIndex && (wIndex <= 3)) + { + /* Set STALL request for the endpoint */ + if (dir) + { + pUsb->DEVICE.DeviceEndpoint[wIndex].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_STALLRQ1; + } + else + { + pUsb->DEVICE.DeviceEndpoint[wIndex].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_STALLRQ0; + } + + /* Send ZLP */ + USB_SendZlp(pUsb); + } + else + { + /* Stall the request */ + USB_SendStall(pUsb, true); + } + break; + + case STD_SET_INTERFACE: + case STD_CLEAR_FEATURE_ZERO: + /* Stall the request */ + USB_SendStall(pUsb, true); + break; + + case STD_CLEAR_FEATURE_INTERFACE: + /* Send ZLP */ + USB_SendZlp(pUsb); + break; + + case STD_CLEAR_FEATURE_ENDPOINT: + dir = wIndex & 0x80; + wIndex &= 0x0F; + + if ((wValue == 0) && wIndex && (wIndex <= 3)) + { + if (dir) + { + if (pUsb->DEVICE.DeviceEndpoint[wIndex].EPSTATUS.bit.STALLRQ1) + { + // Remove stall request + pUsb->DEVICE.DeviceEndpoint[wIndex].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_STALLRQ1; + if (pUsb->DEVICE.DeviceEndpoint[wIndex].EPINTFLAG.bit.STALL1) + { + pUsb->DEVICE.DeviceEndpoint[wIndex].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_STALL1; + // The Stall has occurred, then reset data toggle + pUsb->DEVICE.DeviceEndpoint[wIndex].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSSET_DTGLIN; + } + } + } + else + { + if (pUsb->DEVICE.DeviceEndpoint[wIndex].EPSTATUS.bit.STALLRQ0) + { + // Remove stall request + pUsb->DEVICE.DeviceEndpoint[wIndex].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSCLR_STALLRQ0; + if (pUsb->DEVICE.DeviceEndpoint[wIndex].EPINTFLAG.bit.STALL0) + { + pUsb->DEVICE.DeviceEndpoint[wIndex].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_STALL0; + // The Stall has occurred, then reset data toggle + pUsb->DEVICE.DeviceEndpoint[wIndex].EPSTATUSCLR.reg = USB_DEVICE_EPSTATUSSET_DTGLOUT; + } + } + } + /* Send ZLP */ + USB_SendZlp(pUsb); + } + else + { + USB_SendStall(pUsb, true); + } + break; + + // handle CDC class requests + case SET_LINE_CODING: + /* Send ZLP */ + USB_SendZlp(pUsb); + break; + + case GET_LINE_CODING: + /* Send current line coding */ + USB_Write(pCdc->pUsb, (char *) &line_coding, SAM_BA_MIN(sizeof(usb_cdc_line_coding_t), wLength), USB_EP_CTRL); + break; + + case SET_CONTROL_LINE_STATE: + /* Store the current connection */ + pCdc->currentConnection = wValue; + /* Send ZLP */ + USB_SendZlp(pUsb); + break; + + default: + /* Stall the request */ + USB_SendStall(pUsb, true); + break; + } +} + +/*---------------------------------------------------------------------------- + * \brief + */ +P_USB_CDC usb_init(void) +{ + sam_ba_cdc.pUsb = USB; + + /* Initialize USB */ + USB_Init(); + /* Get the default CDC structure settings */ + USB_Open(&sam_ba_cdc, sam_ba_cdc.pUsb); + + return &sam_ba_cdc; +} + +/*---------------------------------------------------------------------------- + * \brief Send a USB descriptor string. + * + * The input string is plain ASCII but is sent out as UTF-16 with the correct 2-byte prefix. + */ +uint32_t USB_SendString(Usb *pUsb, const char* ascii_string, uint8_t maxLength) +{ + uint8_t string_descriptor[255]; // Max USB-allowed string length + uint16_t* unicode_string=(uint16_t*)(string_descriptor+2); // point on 3 bytes of descriptor + int resulting_length; + + string_descriptor[0] = (strlen(ascii_string)<<1) + 2; + string_descriptor[1] = STD_GET_DESCRIPTOR_STRING; + + for ( resulting_length = 1 ; *ascii_string && (resulting_length>1) ; resulting_length++ ) + { + *unicode_string++ = (uint16_t)(*ascii_string++); + } + + return USB_Write(pUsb, (const char*)string_descriptor, resulting_length<<1, USB_EP_CTRL); +} diff --git a/bootloaders/zero/sam_ba_usb.h b/bootloaders/zero/sam_ba_usb.h new file mode 100644 index 0000000..457fdbc --- /dev/null +++ b/bootloaders/zero/sam_ba_usb.h @@ -0,0 +1,103 @@ +/* + Copyright (c) 2015 Arduino LLC. All right reserved. + Copyright (c) 2015 Atmel Corporation/Thibaut VIARD. 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 CDC_ENUMERATE_H +#define CDC_ENUMERATE_H + +#include +#include + +#define USB_EP_CTRL (0u) +#define USB_EP_OUT (2u) +#define USB_EP_OUT_SIZE (0x40u) +#define USB_EP_IN (1u) +#define USB_EP_IN_SIZE (0x40u) +#define USB_EP_COMM (3u) +#define MAX_EP (4u) + +/* USB standard request code */ +#define STD_GET_STATUS_ZERO (0x0080u) +#define STD_GET_STATUS_INTERFACE (0x0081u) +#define STD_GET_STATUS_ENDPOINT (0x0082u) + +#define STD_CLEAR_FEATURE_ZERO (0x0100u) +#define STD_CLEAR_FEATURE_INTERFACE (0x0101u) +#define STD_CLEAR_FEATURE_ENDPOINT (0x0102u) + +#define STD_SET_FEATURE_ZERO (0x0300u) +#define STD_SET_FEATURE_INTERFACE (0x0301u) +#define STD_SET_FEATURE_ENDPOINT (0x0302u) + +#define STD_SET_ADDRESS (0x0500u) +#define STD_GET_DESCRIPTOR (0x0680u) +#define STD_SET_DESCRIPTOR (0x0700u) +#define STD_GET_CONFIGURATION (0x0880u) +#define STD_SET_CONFIGURATION (0x0900u) +#define STD_GET_INTERFACE (0x0A81u) +#define STD_SET_INTERFACE (0x0B01u) +#define STD_SYNCH_FRAME (0x0C82u) + +#define STD_GET_DESCRIPTOR_DEVICE (1u) +#define STD_GET_DESCRIPTOR_CONFIGURATION (2u) +#define STD_GET_DESCRIPTOR_STRING (3u) +#define STD_GET_DESCRIPTOR_INTERFACE (4u) +#define STD_GET_DESCRIPTOR_ENDPOINT (5u) +#define STD_GET_DESCRIPTOR_DEVICE_QUALIFIER (6u) +#define STD_GET_DESCRIPTOR_OTHER_SPEED_CONFIGURATION (7u) +#define STD_GET_DESCRIPTOR_INTERFACE_POWER1 (8u) + +#define FEATURE_ENDPOINT_HALT (0u) +#define FEATURE_DEVICE_REMOTE_WAKEUP (1u) +#define FEATURE_TEST_MODE (2u) + +#define STRING_INDEX_LANGUAGES (0x00u) +#define STRING_INDEX_MANUFACTURER (0x01u) +#define STRING_INDEX_PRODUCT (0x02u) + +#define SAM_BA_MIN(a, b) (((a) < (b)) ? (a) : (b)) + + +typedef struct _USB_CDC +{ + // Private members + Usb *pUsb; + uint8_t currentConfiguration; + uint8_t currentConnection; + // Public Methods: + uint8_t (*IsConfigured)(struct _USB_CDC *pCdc); +// uint32_t (*Write) (Usb *pUsb, const char *pData, uint32_t length, uint8_t ep_num); +// uint32_t (*Read) (Usb *pUsb, char *pData, uint32_t length); +} USB_CDC, *P_USB_CDC; + +/** + * \brief Initializes the USB module + * + * \return Pointer to the USB CDC structure + */ +P_USB_CDC usb_init(void); + +void sam_ba_usb_CDC_Enumerate(P_USB_CDC pCdc); + +uint32_t USB_SendString(Usb *pUsb, const char* ascii_string, uint8_t maxLength); + +extern USB_CDC sam_ba_cdc; + + + +#endif // CDC_ENUMERATE_H diff --git a/bootloaders/zero/samd21_sam_ba.atsln b/bootloaders/zero/samd21_sam_ba.atsln new file mode 100644 index 0000000..cf10431 --- /dev/null +++ b/bootloaders/zero/samd21_sam_ba.atsln @@ -0,0 +1,22 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Atmel Studio Solution File, Format Version 11.00 +VisualStudioVersion = 14.0.23107.0 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{54F91283-7BC4-4236-8FF9-10F437C3AD48}") = "samd21_sam_ba", "samd21_sam_ba.cproj", "{DCE6C7E3-EE26-4D79-826B-08594B9AD897}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|ARM = Debug|ARM + Release|ARM = Release|ARM + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {DCE6C7E3-EE26-4D79-826B-08594B9AD897}.Debug|ARM.ActiveCfg = Debug|ARM + {DCE6C7E3-EE26-4D79-826B-08594B9AD897}.Debug|ARM.Build.0 = Debug|ARM + {DCE6C7E3-EE26-4D79-826B-08594B9AD897}.Release|ARM.ActiveCfg = Release|ARM + {DCE6C7E3-EE26-4D79-826B-08594B9AD897}.Release|ARM.Build.0 = Release|ARM + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/bootloaders/zero/samd21_sam_ba.bin b/bootloaders/zero/samd21_sam_ba.bin new file mode 100755 index 0000000..1d2da89 Binary files /dev/null and b/bootloaders/zero/samd21_sam_ba.bin differ diff --git a/bootloaders/zero/samd21_sam_ba.cproj b/bootloaders/zero/samd21_sam_ba.cproj new file mode 100644 index 0000000..70ee7e9 --- /dev/null +++ b/bootloaders/zero/samd21_sam_ba.cproj @@ -0,0 +1,218 @@ + + + + 2.0 + 7.0 + com.Atmel.ARMGCC.C + dce6c7e3-ee26-4d79-826b-08594b9ad897 + ATSAMD21G18A + none + Executable + C + $(MSBuildProjectName) + .elf + $(MSBuildProjectDirectory)\$(Configuration) + samd21_sam_ba + samd21_sam_ba + samd21_sam_ba + Native + true + false + true + true + 0x20000000 + + true + exception_table + 2 + 0 + + + + + + + + + + + + + + com.atmel.avrdbg.tool.atmelice + J41800001895 + 0x10010000 + SWD + + + + 2000000 + + SWD + + com.atmel.avrdbg.tool.atmelice + J41800001895 + Atmel-ICE + + 2000000 + + + + + SWD + + com.atmel.avrdbg.tool.edbg + ATML2320040200000259 + EDBG + + + + + + True + True + True + True + True + + + NDEBUG + + + Optimize for size (-Os) + True + True + + + libm + + + True + -Tsamd21j18a_flash.ld + + + + + + + True + True + True + True + True + + + DEBUG + + + Optimize (-O1) + True + Maximum (-g3) + True + + + libm + + + True + -Tsamd21j18a_flash.ld + Default (-g) + Default (-Wa,-g) + + + True + + DEBUG=1 all + clean + Makefile + + + + compile + board_definitions.h + + + compile + board_driver_led.c + + + compile + board_driver_led.h + + + compile + board_driver_serial.c + + + compile + board_driver_serial.h + + + compile + board_driver_usb.c + + + compile + board_driver_usb.h + + + compile + board_init.c + + + compile + board_startup.c + + + compile + main.c + + + compile + sam_ba_cdc.c + + + compile + sam_ba_cdc.h + + + compile + sam_ba_monitor.c + + + compile + sam_ba_monitor.h + + + compile + sam_ba_serial.c + + + compile + sam_ba_serial.h + + + compile + sam_ba_usb.c + + + compile + sam_ba_usb.h + + + + + compile + Makefile + + + compile + README.md + + + compile + bootloader_samd21x18.ld + + + + \ No newline at end of file diff --git a/bootloaders/zero/samd21_sam_ba.hex b/bootloaders/zero/samd21_sam_ba.hex new file mode 100644 index 0000000..42d2d3b --- /dev/null +++ b/bootloaders/zero/samd21_sam_ba.hex @@ -0,0 +1,409 @@ +:10000000FC7F00200D060000FD0500000106000039 +:1000100000000000000000000000000000000000E0 +:1000200000000000000000000000000005060000C5 +:100030000000000000000000090600006507000045 +:1000400010B5064C2378002B07D1054B002B02D0AE +:10005000044800E000BF0123237010BD5C000020B5 +:10006000000000000819000008B5084B002B03D061 +:100070000748084900E000BF07480368002B03D089 +:10008000064B002B00D0984708BDC046000000007A +:100090000819000060000020580000200000000047 +:1000A000154A164B1178002909D115491878097895 +:1000B0004118C9B21970802012498002C8611178B4 +:1000C0000131C9B211701978F02902D819780929BB +:1000D00009D80B4908784042C0B2087018780978EE +:1000E0004118C9B2197012781B789A4203D1802244 +:1000F000044B9202DA617047780000200100002072 +:10010000000000200044004110B5C3699C07FCD4E6 +:1001100003680224A3430360C46901231C42FBD18A +:100120000468234303600368DC07FCD4C46901232B +:100130001C42FBD1C469DC401C42F7D1084B1A4376 +:100140000260C3695A07FCD4C0239B0243608181CB +:10015000C3699C07FCD4036802221343036010BDEB +:1001600004000040037EDA07FCD5018570470000DB +:10017000027E01235107FBD5428B1A4207D1428BE5 +:10018000DA401A4203D1428B92081A4202D0034B42 +:1001900001221A70008DC0B27047C046790000205D +:1001A00070B50368041C988B1A1C0821FF320842A2 +:1001B00026D0802099839872112353704021144BCC +:1001C000917150715E68134DC0202E40800506432A +:1001D0005E605E693540284358610F4818600F48DB +:1001E00018615D680E4828408025AD02284358609C +:1001F0005868800B8003586000235171237105E01B +:10020000137ADA0602D5201C00F0E6FA207970BDD8 +:1002100098010020FFFFFF8F9800002018010020A8 +:10022000FF3F00F0002303714371044B01608360C2 +:100230000B78022213430B707047C046A1010000E7 +:1002400038B5364B2021DA6901200A43DA61344B94 +:1002500006241A7802431A70324B0F221978914300 +:1002600019701978214319702F490C7820430870B0 +:1002700019780A401A701A7860210A431A702B4BB9 +:100280002B4A5A805A7852B2002AFBDB294B0121B3 +:100290001A780A431A709A78D107FCD42648026863 +:1002A000510B1F221140914200D1052111408C01B8 +:1002B0001D8D22492940214319850468A10C0A405B +:1002C0001F2A00D11D221C8D1F210A408C4322436E +:1002D0001A8502680721D20D0A408A4200D1032202 +:1002E0000A40188D1103164A02400A431A851978EC +:1002F0007F220A401A701A78042112480A431A70A1 +:1003000058621A890C218A431A811A8901218A4369 +:100310001A810021802201F076F938BD00040040E6 +:10032000584400413C44004159440041000C004005 +:100330000640000000500041246080003FF8FFFFAD +:10034000FF8FFFFF98010020F7B5141C1F4A5F01C3 +:1003500001971D1CD319061C5869271C4000400F2B +:1003600003301033C74006D00F1C80225968120694 +:100370000A435A6009E02F1C7B1E9F41144BBF01AA +:10038000FF18381C221C01F035F901990F48083577 +:1003900042181761131C5269A104920B890C920335 +:1003A0000A435A6159690B4A0A405A616B01F318B2 +:1003B0000222DA715979802252420A435A716B0142 +:1003C000F318DB799A07FAD5201CFEBD98010020AE +:1003D00018010020FF3F00F0F8B51A4E051C3378D5 +:1003E000141C002B12D1184B184A1A645A6C920B29 +:1003F00092035A64586C164A02405A64A2235B0066 +:10040000EA5C40200243EA54012333704827FF3757 +:10041000EA5D0123134012D00B4B5A6C9204920CEC +:10042000A24202D25C6CA404A40C081C221C074942 +:1004300001F0E0F80123EB550023337000E01C1CB1 +:10044000201CF8BD7A00002098010020D800002070 +:10045000FF3F00F0FF3083792022002900D11022D5 +:100460001343837170470000084BFF305A69920BA9 +:1004700092035A6102230372827980235B42134301 +:100480008371037A9A07FCD57047C0469801002013 +:1004900080235B421943C9B28172704770B5A023B3 +:1004A00003225B00C254134B134A5C6CC0211440FE +:1004B00089050C4346255C64FF35402444550F4DA7 +:1004C00030261D6490256D0046555D6B154029430F +:1004D000922559636D0080214155094D1D63B0255A +:1004E0006D0044555C6F22405A67B2235B00C154D3 +:1004F00070BDC04698010020FFFFFF8FD80000208C +:1005000058010020024B5B785BB2002BFADB70478E +:10051000000C0040024BDB68DA06FBD57047C04692 +:1005200000080040F8B52A4B1E2259689143022268 +:1005300011435960274B28491E1C9982998A0A4306 +:100540009A82F3680227234C3B42FAD0234D0123C1 +:10055000AB60FFF7D7FF224B6B60FFF7D3FF82231F +:10056000DB016B80FFF7CEFFA38C80229343A38433 +:10057000FFF7D0FF1B4BE362FFF7CCFFA38C1A4AB7 +:100580001343A384FFF7C6FFA38C1F43A784F3681C +:100590001A06FCD50F4BDB685A06F8D50024FFF786 +:1005A000B9FFAC60FFF7AEFF104B6B60FFF7AAFF1F +:1005B0000F4B104AC0215A600F4A0906106A000208 +:1005C000000A0143116207229C601A60F8BDC04610 +:1005D00000400041000800400C060000000C0040F4 +:1005E00001050100B805FF7D040A000000070300B3 +:1005F00010E000E0E703000000ED00E00EBEFEE7C3 +:100600000DBEFEE705BEFEE702BEFEE70E4A0F483E +:1006100038B5824204D10E4A0E4B93420ED10AE005 +:100620000D4C9442F7D00023D1188842F3D9E558F5 +:1006300004330D60F8E700F011F804E09342FAD2B9 +:10064000002102C3FAE7FEE7000000205C00002062 +:10065000A80300205C0000200C19000038B5344BC2 +:100660001A681C1C013221D0324A191D1160D9B2FE +:1006700000291BD1304A1078012210402F4A0AD19C +:1006800015682F498D4201D110600FE011602D498E +:1006900001390029FCD11160226882F30888FF2209 +:1006A0009343294A9360224B5B681847FFF73AFF50 +:1006B00062B600F0CDFD00F05BF8244B8022920280 +:1006C00023499A6008220A602249041C0A60802299 +:1006D00012059A609A61204B204AC0215A601A4A3A +:1006E0000906106A0002000A0143116200229A60A2 +:1006F00007221A60A368201C9847194B002801D0D4 +:1007000001221A701A78002A05D0002000F094FA0D +:1007100000F01AFBFCE71B78002BEBD100F00CFE7D +:100720000028E7D0012000F087FA00F00DFBFCE77D +:10073000002000001802002038040040FC7F002048 +:100740003581730748E8010000ED00E000440041F6 +:10075000884400419844004110E000E0E7030000B5 +:100760007B00002008B5FFF79BFC00F0C9FA08BD2C +:1007700010B5054B054C2360FFF762FD201C216876 +:10078000FFF750FD201C10BD005000411C0200204E +:1007900070B5051CC0B0081C161C0C1C00F03BFFFB +:1007A00040006A460323023053701070760801231C +:1007B000E218013A11785A00002906D1281C69462E +:1007C0000023FFF7C1FD40B070BDB342F6DA6846C2 +:1007D00081520133ECE70000F7B5BA4A0468137898 +:1007E000B949271CFF37051C102038720B7053784D +:1007F000B648B74E037093783380D17833880902B6 +:100800000B4333801179B34B198051791888090251 +:10081000084318809079B0490880D279088812027C +:1008200002430A8040227A71A84F3A78A64F1202FA +:1008300038780F1C0243A9488446181C624500D131 +:10084000C2E020DC802149008A4200D16EE109DC4F +:10085000812A00D192E0822A00D195E0802A00D03E +:1008600064E18BE081235B009A4200D1CFE000DAA3 +:1008700058E1C0239B009A4200D157E1984B9A421D +:1008800000D14FE152E190231B019A4269D015DC5F +:10089000D023DB009A4222D088231B019A4269D0E0 +:1008A000A023DB009A4200D040E1201CFFF7DCFDD2 +:1008B0003188286889B2FFF7EBFD3BE1894B9A420A +:1008C00000D12FE100DC31E1874B9A4200D11DE1DC +:1008D000864B9A4200D029E133886B7122E133883C +:1008E0001B0A012B08D10B8812222868934201D8D9 +:1008F0000A8892B27E4911E133881B0A022B08D183 +:100900000B8843222868934201D80A8892B2794919 +:1009100004E133881B0A032B00D007E13388DBB2E4 +:10092000012B17D0002B07D0022B00D0FEE00A8845 +:100930002868D2B2704911E0042201A86F4900F082 +:1009400059FE3B8804222868934201D83A8892B223 +:1009500001A9E3E00A8828686949D2B2FFF718FFC5 +:10096000E8E03388201C2B71FFF77EFD201CFFF789 +:1009700095FDDFE0291C01C90122CFE06149002378 +:100980000B8028680222CAE05E4900220A8018888B +:10099000502210405C4A10701E880F203040188092 +:1009A0001888032800D9C1E012781B8808335B013E +:1009B000E418A379002A01D09B0600E0DB06DB0FD8 +:1009C0000B8028680222A9E019887F2291434E4AB1 +:1009D000C9B2117018880F2101401980318800298F +:1009E00000D0A3E01988002900D19FE019880329CD +:1009F00000D99BE012781B8808335B01E318002ABA +:100A000002D020225A718DE0102159718AE00288AB +:100A10007F239A433C4BD2B21A7001880F220A40BE +:100A200002803288002A00D080E00288002A00D1AB +:100A30007CE00288032A00D978E01B78002B1FD0C5 +:100A4000038808335B01E3189B799A066AD503880B +:100A5000202208335B01E3181A71038808335B0115 +:100A6000E318DB795F065DD50388402208335B011C +:100A7000E318DA710388022208335B01E3181EE0F1 +:100A8000038808335B01E3189B79D9064AD50388AC +:100A9000102208335B01E3181A71038808335B01E5 +:100AA000E318DB799A063DD50388202208335B01E1 +:100AB000E318DA710388012208335B01E3181A7125 +:100AC00030E0C046980000207D0000208200002019 +:100AD0008400002086000020800000200203000027 +:100AE0000103000021200000A121000021220000BC +:100AF0005C160000040000204C1600003C160000AC +:100B0000401600007E0000207C0000200B88082298 +:100B10002868934201D80A8892B207490023FFF758 +:100B200013FC07E0201CFFF79FFC03E0201C0121C1 +:100B3000FFF790FCF7BDC0464800002007B5054B05 +:100B40000122019001A91868131CFFF7FDFB012089 +:100B50000EBDC0461C02002013B5054B6C46073481 +:100B60001868211C0122FFF737FC207816BDC0460B +:100B70001C02002010B5074C201CFFF711FB031CC2 +:100B80000020834205D022684823FF33D05C012334 +:100B9000184010BD1C02002010B5054A0C1C031C97 +:100BA000191C10680123221CFFF7CEFB201C10BD6E +:100BB0001C02002070B5084C061C201C0D1CFFF701 +:100BC000EFFA0023984205D02068311C2A1CFFF759 +:100BD00003FC031C181C70BD1C020020F8B50C4C53 +:100BE000051C201C0E1CFFF7DBFA0023271C341CFD +:100BF00098420AD0002C07D0291C221C3868FFF725 +:100C0000EBFB241A2D18F5E7331C181CF8BDC04661 +:100C10001C02002008B5031C081C111C9847044B3B +:100C2000802212055A61034B64221A8008BDC04617 +:100C3000004400418C000020012805D1054B064AE4 +:100C40001A60064B187004E0002802D1044A014BD8 +:100C50001A6070478C02002090160000940000205B +:100C6000DC16000030B50A1C1C4985B00978031C4D +:100C700000292AD0042A01D1006804E0022A01D107 +:100C8000008800E00078520004A98B180B3B9C1AE6 +:100C9000A3420BD00F210140092902D83025294356 +:100CA00000E0373119700009013BF1E701A9302359 +:100CB0000B7078234B700A208B1898700D20D87019 +:100CC000074B04321B68D86803E005490968C86807 +:100CD000191CFFF79FFF05B030BDC04688000020FB +:100CE0008C02002072B6EFF30883044A1360036895 +:100CF00083F30888436818477047C0469002002075 +:100D00000D4B1A88002A09D01A88013A92B21A802B +:100D1000002A03D18022094B12059A61084B1A88D8 +:100D2000002A08D01A88013A92B21A80002A02D109 +:100D3000044B08221A6070478C00002000440041D8 +:100D40008A00002098440041F0B591B008A9CE4A2D +:100D50000B1C31CA31C351CA51C360CA60C3CB4BEB +:100D6000CB489A687A255203520F92005258C949CB +:100D700002609C68A4B262430C60C74900240A6008 +:100D8000C64A1460C64C2570C64CC74D2368281C43 +:100D90001B6940219847002805D0C44B08221A60DF +:100DA000C34B64221A80C34B00221860C24B1D60E3 +:100DB000C24BC24DBF4F1A602A683B689A42E3D2C9 +:100DC000BD4B1B681A78FF2A00D120E2232A00D0ED +:100DD000F7E1BB4E3378002B06D0B24BB9491B6804 +:100DE0000222D868FFF716FFAD4B1B78532B3FD17B +:100DF0003B682A6893421ED9AF4801322A609A1A8A +:100E0000B14B01681B6801310160B04E9A4201D2BA +:100E1000326000E03360A14832680068049000F05E +:100E2000E9FB336829685A182A60A34A1668F11842 +:100E30001160A74A13702B68013B2B609E4B1A6808 +:100E4000013A1A60A24BA04A1B7811688B420DD25E +:100E500022689248C91A006892699047002805D014 +:100E6000924B08221A60924B64221A80C04696E187 +:100E7000522B0ED18948944A2368006811685B6937 +:100E800003909847934B802212055A616422924B3B +:100E90000DE04F2B05D1814B8B4A1B6812681A70ED +:100EA0007DE1482B05D17D4B874A1B6812681A806B +:100EB00075E1572B05D1794B834A1B6812681A607C +:100EC0006DE16F2B03D1754B0121186807E0682B8A +:100ED00008D1724B7C481B6802211B880360FFF716 +:100EE000C1FE5CE1772B06D16C4B77481B6804216F +:100EF0001B680360F3E7472B13D1734B1868FFF7A8 +:100F0000F1FE764B1B6883F3088862B6744B1B783E +:100F1000002B00D143E1634B06201B681B689847F8 +:100F20003DE1542B04D1012333705E4B1B6864E018 +:100F30004E2B0CD13378002B06D15A4B61491B68DC +:100F40000222D868FFF766FE0023337027E1562B94 +:100F500057D123686349D8680122FFF75BFE2368F5 +:100F60006149D8680322FFF755FE604D2368291CAC +:100F7000D8680122FFF74EFE23685D49D8680D222C +:100F8000FFF748FE2368291CD8680122FFF742FEBC +:100F9000494F4A4D5749002339602B603A1C281CA1 +:100FA00013685E1C16601B780593002B03D0036842 +:100FB00001330360F4E73B4E2A683368D868FFF7D3 +:100FC00029FE33684949D8680122FFF723FE0599B5 +:100FD000296049493960384A1368581C10601B78E9 +:100FE000002B04D0354B1A6801321A60F3E73368DE +:100FF0002A68D868FFF70EFE3368D86831490222A4 +:10100000CBE0314A582B17D1214E234D3668136857 +:101010002A68B10093420AD21C4D5808E86137484B +:1010200028801A4D287DC607FBD55B18F2E71D4BBB +:1010300033491B68D868AFE0592B00D07DE01268B7 +:10104000164B3049002A02D11B680B6070E00F4D2F +:10105000086819686B680D4E8025AB439208736071 +:10106000002A65D0284B094D2B80084E337DDD07C3 +:10107000FBD50023064D2D680195AD08AB4247D343 +:10108000224D024E35804AE07016000000400041BB +:10109000440200203C020020380200208802002088 +:1010A000340200208C0200204802002094440041B9 +:1010B0008A0000202C020020300200204002002084 +:1010C00088000020D0160000940200209802002022 +:1010D00028020020004400418C00002090020020E3 +:1010E00094000020AC160000D5160000AE160000DB +:1010F000F8160000B0160000BC16000002A5FFFFA5 +:10110000C51600009000002044A5FFFF04A5FFFFC6 +:101110009342B5D09D00465901334E51AAE7404E47 +:10112000357DEE07FBD59D0049194019D21A97E786 +:101130003C4B3D491B68D8682EE05A2B2FD13B4BC6 +:1011400017681D680026EF19BD4206D02878311CAB +:1011500000F014F90135061CF6E7324B34491B68E0 +:101160000122D868FFF756FD07230F223240111CD9 +:1011700036093031092A00DD07311820C0186A46C7 +:101180008154013BF1D2236806A9D8680822FFF7F1 +:1011900041FD23682749D8680322FFF73BFD264B12 +:1011A0007A221A70254B00221A60254B1B78934235 +:1011B0002DD01C4B23491B680122D868FFF72AFD5C +:1011C00025E0111C3039C8B21C4B092804D81D6811 +:1011D0002A01114319601AE0111C4139052903D86D +:1011E0001E68373A310106E0111C6139052904D81F +:1011F0001868573A01010A4308E02C2A03D10B4A28 +:101200001968116001E00C490A7000221A600E4B47 +:101210001A6801321A600D4B1A680132C9E5C046DE +:10122000004000418C020020C91600008802002006 +:10123000CD160000CF1600003402002094020020DA +:1012400088000020D3160000400200203002002059 +:1012500010B51C4B01201A78022402431A701A4B55 +:101260000F22197891431970197821431970174981 +:101270000C782043087019780A401A701A782021D7 +:101280000A431A70124B04211A6A0A431A62114B5C +:10129000114A5A805A7852B2002AFBDBC4220F4806 +:1012A0000F499203FEF730FF0E4A002313700E4AD7 +:1012B00013700E4A13700E4A13700E4A13700E4AC2 +:1012C000137010BD4A440041354400414B44004175 +:1012D00000040040000C00401440000000080042E0 +:1012E0002AF600009C020020230300209D0200201B +:1012F000A0020020240300202103002008B5C1B271 +:101300000248FEF72FFF012008BDC046000800423A +:10131000024B187E4007C00F7047C04600080042CD +:1013200008B5FFF7F5FF0028FBD00248FEF720FFC5 +:1013300008BDC0460008004208B5FFF7E9FF0023DA +:10134000984205D0FFF7ECFF031C233B5A42534160 +:10135000181C08BD70B5041C0D1C4618B44204D0FE +:101360002078FFF7CBFF0134F8E7281C70BD10B5DB +:10137000041CFFF7D5FF2070012010BD0B0A584058 +:10138000034B4000C05A0902484080B27047C04633 +:1013900006170000F7B50024051C0F1C261CBC42D4 +:1013A00020D0FFF7BDFF114BC0B21B780190002B7E +:1013B0001AD1311CFFF7E2FF0D4B061C1A88002AD8 +:1013C00004D10C4A11782A1C002907D001996A1C03 +:1013D0002970802F02D11988013919800134A4B2F3 +:1013E000151CDCE7301C00E00120FEBD21030020BD +:1013F0009E02002022030020F0B53E4E85B0002260 +:1014000003900C1C32703C4B914201D1012201E04F +:101410003A490C801A707F231C4201D080349C43CF +:10142000FFF77EFF3378C0B2002B07D00025357060 +:10143000FFF776FF3378C0B2AB4236D1432803D0F2 +:10144000712853D01528EBD1012300930120FFF719 +:1014500055FF0098FFF752FF00998025C843C0B29E +:10146000FFF74CFF039B00270293244A1388002BAD +:101470001DD1214901930978002918D10198FFF75E +:101480003DFF391C0198FFF779FF013D071C002D36 +:10149000EBD1000AC0B2FFF731FFF8B2FFF72EFF21 +:1014A000FFF73EFF3378002B0AD035701FE002991A +:1014B000013B09781380029B019101330293DDE720 +:1014C000C0B2062807D1009B03990133DBB28031FB +:1014D0000093803C0391002CB8D10420FFF70EFF4D +:1014E000FFF71EFF044B01251C7000E00025281C9F +:1014F00005B0F0BD21030020220300209E02002041 +:10150000F0B5384C87B0002301902370994201D187 +:10151000012301E0344A1180344A642613704320C9 +:10152000FFF7ECFE324FFFF7F3FE002803D1002F48 +:1015300003D0013FF7E7002F03D1013E002EEED18B +:101540004DE00125FFF7ECFE2378002B38D1C0B227 +:101550000290012805D004283DD10620FFF7CEFED9 +:1015600039E005AE0221301CFFF714FF01988021FD +:10157000FFF710FF23780390002B18D1FFF7D0FE60 +:101580000702FFF7CDFEBFB223783F18BFB2012B91 +:101590000DD0039B9F4207D13378AB4204D1EB437C +:1015A0007278DBB29A4204D01820FFF7A7FE00231E +:1015B00003E00620FFF7A2FE029B2278002A02D059 +:1015C000002626700BE0012B05D1019A6B1C80329E +:1015D000DDB20192B6E7054A002313700126301CE4 +:1015E00007B0F0BD210300209E020020220300204E +:1015F00000350C0010B50023934203D0CC5CC454DA +:101600000133F9E710BD031C8218934202D0197010 +:101610000133FAE770470023C25C0133002AFBD193 +:10162000581E7047F8B5C046F8BC08BC9E467047C7 +:10163000F8B5C046F8BC08BC9E46704704030904D0 +:1016400041726475696E6F204C4C43004172647541 +:10165000696E6F205A65726F00000000120100026F +:101660000200004041234D00000201020001000081 +:1016700008000000100000002000000040000000F2 +:1016800080000000000100000002000000040000D3 +:10169000FD1200002113000011130000551300007B +:1016A0006F130000F9130000011500007600200000 +:1016B00041707220313120323031390031333A30CB +:1016C000393A343900580A0D00590A0D005A0023DE +:1016D0000A0D003E00322E30000000003D0B0000DD +:1016E000590B0000750B0000990B0000B50B0000B2 +:1016F000990B0000DD0B00005B41726475696E6F31 +:101700003A58595A5D00000021104220633084404D +:10171000A550C660E770088129914AA16BB18CC1C0 +:10172000ADD1CEE1EFF13112100273325222B55237 +:101730009442F772D662399318837BB35AA3BDD310 +:101740009CC3FFF3DEE36224433420040114E66407 +:10175000C774A44485546AA54BB528850995EEE560 +:10176000CFF5ACC58DD55336722611163006D77617 +:10177000F6669556B4465BB77AA719973887DFF7B0 +:10178000FEE79DD7BCC7C448E5588668A7784008DF +:10179000611802282338CCC9EDD98EE9AFF9488900 +:1017A00069990AA92BB9F55AD44AB77A966A711A77 +:1017B000500A333A122AFDDBDCCBBFFB9EEB799B50 +:1017C000588B3BBB1AABA66C877CE44CC55C222CC7 +:1017D000033C600C411CAEED8FFDECCDCDDD2AADA0 +:1017E0000BBD688D499D977EB66ED55EF44E133E57 +:1017F000322E511E700E9FFFBEEFDDDFFCCF1BBFF0 +:101800003AAF599F788F8891A981CAB1EBA10CD1C9 +:101810002DC14EF16FE18010A100C230E3200450D1 +:10182000254046706760B9839893FBA3DAB33DC344 +:101830001CD37FE35EF3B1029012F322D232354221 +:10184000145277625672EAB5CBA5A89589856EF5D4 +:101850004FE52CD50DC5E234C324A0148104667471 +:10186000476424540544DBA7FAB79987B8975FE724 +:101870007EF71DC73CD7D326F2369106B0165766C1 +:101880007676154634564CD96DC90EF92FE9C899AC +:10189000E9898AB9ABA94458654806782768C01811 +:1018A000E1088238A3287DCB5CDB3FEB1EFBF98B84 +:1018B000D89BBBAB9ABB754A545A376A167AF10A61 +:1018C000D01AB32A923A2EFD0FED6CDD4DCDAABD94 +:1018D0008BADE89DC98D267C076C645C454CA23CB1 +:1018E000832CE01CC10C1FEF3EFF5DCF7CDF9BAF64 +:1018F000BABFD98FF89F176E367E554E745E932E01 +:0C190000B23ED10EF01E000000000000FE +:10190C0001140000090243000201008032090400A6 +:10191C00000102020000052400100104240200054D +:10192C00240600010524010001070583030800FFBC +:10193C0009040100020A00000007058102400000B2 +:10194C00070502024000000000C201000000080070 +:0C195C00690000004100000000000000D5 +:040000030000060DE6 +:00000001FF diff --git a/cores/arduino/Arduino.h b/cores/arduino/Arduino.h new file mode 100644 index 0000000..d78acd9 --- /dev/null +++ b/cores/arduino/Arduino.h @@ -0,0 +1,118 @@ +/* + Arduino.h - Main include file for the Arduino SDK + Copyright (c) 2014 Arduino LLC. 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 Arduino_h +#define Arduino_h + +#include "api/ArduinoAPI.h" + +#define RAMSTART (HMCRAMC0_ADDR) +#define RAMSIZE (HMCRAMC0_SIZE) +#define RAMEND (RAMSTART + RAMSIZE - 1) + +#ifdef __cplusplus + +using namespace arduino; + +extern "C"{ +#endif // __cplusplus + +// Include Atmel headers +#undef LITTLE_ENDIAN +#include + +#define clockCyclesPerMicrosecond() ( SystemCoreClock / 1000000L ) +#define clockCyclesToMicroseconds(a) ( ((a) * 1000L) / (SystemCoreClock / 1000L) ) +#define microsecondsToClockCycles(a) ( (a) * (SystemCoreClock / 1000000L) ) + +#include "WVariant.h" + +#ifdef __cplusplus +} // extern "C" +#endif + +// Include board variant +#include "variant.h" + +#define interrupts() __enable_irq() +#define noInterrupts() __disable_irq() + +#if (ARDUINO_SAMD_VARIANT_COMPLIANCE >= 10606) +// Interrupts +#define digitalPinToInterrupt(P) ( P ) +#endif + +// undefine stdlib's abs if encountered +#ifdef abs +#undef abs +#endif // abs + +#define abs(x) ((x)>0?(x):-(x)) + +// Allows publishing the Beta core under samd-beta / arduino organization +#ifndef ARDUINO_ARCH_SAMD +#define ARDUINO_ARCH_SAMD +#endif + +#ifdef __cplusplus +extern "C" { +#endif +/* + * \brief SAMD products have only one reference for ADC + */ +typedef enum _eAnalogReference +{ + AR_DEFAULT, + AR_INTERNAL, + AR_EXTERNAL, + AR_INTERNAL1V0, + AR_INTERNAL1V65, + AR_INTERNAL2V23 +} eAnalogReference ; + +/* + * \brief Set the resolution of analogRead return values. Default is 10 bits (range from 0 to 1023). + * + * \param res + */ +extern void analogReadResolution(int res); + +/* + * \brief Set the resolution of analogWrite parameters. Default is 8 bits (range from 0 to 255). + * + * \param res + */ +extern void analogWriteResolution(int res); + +extern void analogOutputInit( void ) ; + +#ifdef __cplusplus +} +#endif + +// USB Device +#include "USB/USBDesc.h" +#include "USB/USBCore.h" +#include "USB/USBAPI.h" +#include "USB/USB_host.h" + +// ARM toolchain doesn't provide itoa etc, provide them +#include "api/itoa.h" + +#endif // Arduino_h diff --git a/cores/arduino/Reset.cpp b/cores/arduino/Reset.cpp new file mode 100644 index 0000000..c53915e --- /dev/null +++ b/cores/arduino/Reset.cpp @@ -0,0 +1,90 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#include +#include "Reset.h" + +#ifdef __cplusplus +extern "C" { +#endif + +#define NVM_MEMORY ((volatile uint16_t *)0x000000) + +#if (ARDUINO_SAMD_VARIANT_COMPLIANCE >= 10610) + +extern const uint32_t __text_start__; +#define APP_START ((uint32_t)(&__text_start__) + 4) + +#else +#define APP_START 0x00002004 +#endif + +static inline bool nvmReady(void) { + return NVMCTRL->INTFLAG.reg & NVMCTRL_INTFLAG_READY; +} + +__attribute__ ((long_call, section (".ramfunc"))) +static void banzai() { + // Disable all interrupts + __disable_irq(); + + // Avoid erasing the application if APP_START is < than the minimum bootloader size + // This could happen if without_bootloader linker script was chosen + // Minimum bootloader size in SAMD21 family is 512bytes (RM section 22.6.5) + if (APP_START < (0x200 + 4)) { + goto reset; + } + + // Erase application + while (!nvmReady()) + ; + NVMCTRL->STATUS.reg |= NVMCTRL_STATUS_MASK; + NVMCTRL->ADDR.reg = (uintptr_t)&NVM_MEMORY[APP_START / 4]; + NVMCTRL->CTRLA.reg = NVMCTRL_CTRLA_CMD_ER | NVMCTRL_CTRLA_CMDEX_KEY; + while (!nvmReady()) + ; + +reset: + // Reset the device + NVIC_SystemReset() ; + + while (true); +} + +static int ticks = -1; + +void initiateReset(int _ticks) { + resetExternalChip(); + ticks = _ticks; +} + +void cancelReset() { + ticks = -1; +} + +void tickReset() { + if (ticks == -1) + return; + ticks--; + if (ticks == 0) + banzai(); +} + +#ifdef __cplusplus +} +#endif diff --git a/cores/arduino/Reset.h b/cores/arduino/Reset.h new file mode 100644 index 0000000..3b7e9fa --- /dev/null +++ b/cores/arduino/Reset.h @@ -0,0 +1,33 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#pragma once + +#ifdef __cplusplus +extern "C" { +#endif + +void initiateReset(int ms); +void tickReset(); +void cancelReset(); + + __attribute__ ((weak)) void resetExternalChip() {}; + +#ifdef __cplusplus +} +#endif diff --git a/cores/arduino/RingBuffer.h b/cores/arduino/RingBuffer.h new file mode 100644 index 0000000..e706cc4 --- /dev/null +++ b/cores/arduino/RingBuffer.h @@ -0,0 +1,144 @@ +/* + 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 +*/ + +#ifdef __cplusplus + +#ifndef _RING_BUFFER_ +#define _RING_BUFFER_ + +#include + +// Define constants and variables for buffering incoming serial data. We're +// using a ring buffer (I think), in which head is the index of the location +// to which to write the next incoming character and tail is the index of the +// location from which to read. +#ifndef SERIAL_BUFFER_SIZE +#define SERIAL_BUFFER_SIZE 256 +#endif + +template +class RingBufferN +{ + public: + uint8_t _aucBuffer[N] ; + volatile int _iHead ; + volatile int _iTail ; + + public: + RingBufferN( void ) ; + void store_char( uint8_t c ) ; + void clear(); + int read_char(); + int available(); + int availableForStore(); + int peek(); + bool isFull(); + + private: + int nextIndex(int index); +}; + +typedef RingBufferN RingBuffer; + + +template +RingBufferN::RingBufferN( void ) +{ + memset( _aucBuffer, 0, N ) ; + clear(); +} + +template +void RingBufferN::store_char( uint8_t c ) +{ + int i = nextIndex(_iHead); + + // if we should be storing the received character into the location + // just before the tail (meaning that the head would advance to the + // current location of the tail), we're about to overflow the buffer + // and so we don't write the character or advance the head. + if ( i != _iTail ) + { + _aucBuffer[_iHead] = c ; + _iHead = i ; + } +} + +template +void RingBufferN::clear() +{ + _iHead = 0; + _iTail = 0; +} + +template +int RingBufferN::read_char() +{ + if(_iTail == _iHead) + return -1; + + uint8_t value = _aucBuffer[_iTail]; + _iTail = nextIndex(_iTail); + + return value; +} + +template +int RingBufferN::available() +{ + int delta = _iHead - _iTail; + + if(delta < 0) + return N + delta; + else + return delta; +} + +template +int RingBufferN::availableForStore() +{ + if (_iHead >= _iTail) + return N - 1 - _iHead + _iTail; + else + return _iTail - _iHead - 1; +} + +template +int RingBufferN::peek() +{ + if(_iTail == _iHead) + return -1; + + return _aucBuffer[_iTail]; +} + +template +int RingBufferN::nextIndex(int index) +{ + return (uint32_t)(index + 1) % N; +} + +template +bool RingBufferN::isFull() +{ + return (nextIndex(_iHead) == _iTail); +} + +#endif /* _RING_BUFFER_ */ + +#endif /* __cplusplus */ diff --git a/cores/arduino/SERCOM.cpp b/cores/arduino/SERCOM.cpp new file mode 100644 index 0000000..20adf51 --- /dev/null +++ b/cores/arduino/SERCOM.cpp @@ -0,0 +1,744 @@ +/* + 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 +*/ + +#include "Arduino.h" +#include "SERCOM.h" +#include "variant.h" + +#ifndef WIRE_RISE_TIME_NANOSECONDS +// Default rise time in nanoseconds, based on 4.7K ohm pull up resistors +// you can override this value in your variant if needed +#define WIRE_RISE_TIME_NANOSECONDS 125 +#endif + +SERCOM::SERCOM(Sercom* s) +{ + sercom = s; +} + +/* ========================= + * ===== Sercom UART + * ========================= +*/ +void SERCOM::initUART(SercomUartMode mode, SercomUartSampleRate sampleRate, uint32_t baudrate) +{ + initClockNVIC(); + resetUART(); + + //Setting the CTRLA register + sercom->USART.CTRLA.reg = SERCOM_USART_CTRLA_MODE(mode) | + SERCOM_USART_CTRLA_SAMPR(sampleRate); + + //Setting the Interrupt register + sercom->USART.INTENSET.reg = SERCOM_USART_INTENSET_RXC | //Received complete + SERCOM_USART_INTENSET_ERROR; //All others errors + + if ( mode == UART_INT_CLOCK ) + { + uint16_t sampleRateValue; + + if (sampleRate == SAMPLE_RATE_x16) { + sampleRateValue = 16; + } else { + sampleRateValue = 8; + } + + // Asynchronous fractional mode (Table 24-2 in datasheet) + // BAUD = fref / (sampleRateValue * fbaud) + // (multiply by 8, to calculate fractional piece) + uint32_t baudTimes8 = (SystemCoreClock * 8) / (sampleRateValue * baudrate); + + sercom->USART.BAUD.FRAC.FP = (baudTimes8 % 8); + sercom->USART.BAUD.FRAC.BAUD = (baudTimes8 / 8); + } +} +void SERCOM::initFrame(SercomUartCharSize charSize, SercomDataOrder dataOrder, SercomParityMode parityMode, SercomNumberStopBit nbStopBits) +{ + //Setting the CTRLA register + sercom->USART.CTRLA.reg |= SERCOM_USART_CTRLA_FORM( (parityMode == SERCOM_NO_PARITY ? 0 : 1) ) | + dataOrder << SERCOM_USART_CTRLA_DORD_Pos; + + //Setting the CTRLB register + sercom->USART.CTRLB.reg |= SERCOM_USART_CTRLB_CHSIZE(charSize) | + nbStopBits << SERCOM_USART_CTRLB_SBMODE_Pos | + (parityMode == SERCOM_NO_PARITY ? 0 : parityMode) << SERCOM_USART_CTRLB_PMODE_Pos; //If no parity use default value +} + +void SERCOM::initPads(SercomUartTXPad txPad, SercomRXPad rxPad) +{ + //Setting the CTRLA register + sercom->USART.CTRLA.reg |= SERCOM_USART_CTRLA_TXPO(txPad) | + SERCOM_USART_CTRLA_RXPO(rxPad); + + // Enable Transceiver and Receiver + sercom->USART.CTRLB.reg |= SERCOM_USART_CTRLB_TXEN | SERCOM_USART_CTRLB_RXEN ; +} + +void SERCOM::resetUART() +{ + // Start the Software Reset + sercom->USART.CTRLA.bit.SWRST = 1 ; + + while ( sercom->USART.CTRLA.bit.SWRST || sercom->USART.SYNCBUSY.bit.SWRST ) + { + // Wait for both bits Software Reset from CTRLA and SYNCBUSY coming back to 0 + } +} + +void SERCOM::enableUART() +{ + //Setting the enable bit to 1 + sercom->USART.CTRLA.bit.ENABLE = 0x1u; + + //Wait for then enable bit from SYNCBUSY is equal to 0; + while(sercom->USART.SYNCBUSY.bit.ENABLE); +} + +void SERCOM::flushUART() +{ + // Skip checking transmission completion if data register is empty + // Wait for transmission to complete, if ok to do so. + while(!sercom->USART.INTFLAG.bit.TXC && onFlushWaitUartTXC); + + onFlushWaitUartTXC = false; +} + +void SERCOM::clearStatusUART() +{ + //Reset (with 0) the STATUS register + sercom->USART.STATUS.reg = SERCOM_USART_STATUS_RESETVALUE; +} + +bool SERCOM::availableDataUART() +{ + //RXC : Receive Complete + return sercom->USART.INTFLAG.bit.RXC; +} + +bool SERCOM::isUARTError() +{ + return sercom->USART.INTFLAG.bit.ERROR; +} + +void SERCOM::acknowledgeUARTError() +{ + sercom->USART.INTFLAG.bit.ERROR = 1; +} + +bool SERCOM::isBufferOverflowErrorUART() +{ + //BUFOVF : Buffer Overflow + return sercom->USART.STATUS.bit.BUFOVF; +} + +bool SERCOM::isFrameErrorUART() +{ + //FERR : Frame Error + return sercom->USART.STATUS.bit.FERR; +} + +void SERCOM::clearFrameErrorUART() +{ + // clear FERR bit writing 1 status bit + sercom->USART.STATUS.bit.FERR = 1; +} + +bool SERCOM::isParityErrorUART() +{ + //PERR : Parity Error + return sercom->USART.STATUS.bit.PERR; +} + +bool SERCOM::isDataRegisterEmptyUART() +{ + //DRE : Data Register Empty + return sercom->USART.INTFLAG.bit.DRE; +} + +uint8_t SERCOM::readDataUART() +{ + return sercom->USART.DATA.bit.DATA; +} + +int SERCOM::writeDataUART(uint8_t data) +{ + // Wait for data register to be empty + while(!isDataRegisterEmptyUART()); + + //Put data into DATA register + sercom->USART.DATA.reg = (uint16_t)data; + + // indicate it's ok to wait for TXC flag when flushing + onFlushWaitUartTXC = true; + + return 1; +} + +void SERCOM::enableDataRegisterEmptyInterruptUART() +{ + sercom->USART.INTENSET.reg = SERCOM_USART_INTENSET_DRE; +} + +void SERCOM::disableDataRegisterEmptyInterruptUART() +{ + sercom->USART.INTENCLR.reg = SERCOM_USART_INTENCLR_DRE; +} + +/* ========================= + * ===== Sercom SPI + * ========================= +*/ +void SERCOM::initSPI(SercomSpiTXPad mosi, SercomRXPad miso, SercomSpiCharSize charSize, SercomDataOrder dataOrder) +{ + resetSPI(); + initClockNVIC(); + + //Setting the CTRLA register + sercom->SPI.CTRLA.reg = SERCOM_SPI_CTRLA_MODE_SPI_MASTER | + SERCOM_SPI_CTRLA_DOPO(mosi) | + SERCOM_SPI_CTRLA_DIPO(miso) | + dataOrder << SERCOM_SPI_CTRLA_DORD_Pos; + + //Setting the CTRLB register + sercom->SPI.CTRLB.reg = SERCOM_SPI_CTRLB_CHSIZE(charSize) | + SERCOM_SPI_CTRLB_RXEN; //Active the SPI receiver. + + +} + +void SERCOM::initSPIClock(SercomSpiClockMode clockMode, uint32_t baudrate) +{ + //Extract data from clockMode + int cpha, cpol; + + if((clockMode & (0x1ul)) == 0 ) + cpha = 0; + else + cpha = 1; + + if((clockMode & (0x2ul)) == 0) + cpol = 0; + else + cpol = 1; + + //Setting the CTRLA register + sercom->SPI.CTRLA.reg |= ( cpha << SERCOM_SPI_CTRLA_CPHA_Pos ) | + ( cpol << SERCOM_SPI_CTRLA_CPOL_Pos ); + + //Synchronous arithmetic + sercom->SPI.BAUD.reg = calculateBaudrateSynchronous(baudrate); +} + +void SERCOM::resetSPI() +{ + //Setting the Software Reset bit to 1 + sercom->SPI.CTRLA.bit.SWRST = 1; + + //Wait both bits Software Reset from CTRLA and SYNCBUSY are equal to 0 + while(sercom->SPI.CTRLA.bit.SWRST || sercom->SPI.SYNCBUSY.bit.SWRST); +} + +void SERCOM::enableSPI() +{ + //Setting the enable bit to 1 + sercom->SPI.CTRLA.bit.ENABLE = 1; + + while(sercom->SPI.SYNCBUSY.bit.ENABLE) + { + //Waiting then enable bit from SYNCBUSY is equal to 0; + } +} + +void SERCOM::disableSPI() +{ + while(sercom->SPI.SYNCBUSY.bit.ENABLE) + { + //Waiting then enable bit from SYNCBUSY is equal to 0; + } + + //Setting the enable bit to 0 + sercom->SPI.CTRLA.bit.ENABLE = 0; +} + +void SERCOM::setDataOrderSPI(SercomDataOrder dataOrder) +{ + //Register enable-protected + disableSPI(); + + sercom->SPI.CTRLA.bit.DORD = dataOrder; + + enableSPI(); +} + +SercomDataOrder SERCOM::getDataOrderSPI() +{ + return (sercom->SPI.CTRLA.bit.DORD ? LSB_FIRST : MSB_FIRST); +} + +void SERCOM::setBaudrateSPI(uint8_t divider) +{ + //Can't divide by 0 + if(divider == 0) + return; + + //Register enable-protected + disableSPI(); + + sercom->SPI.BAUD.reg = calculateBaudrateSynchronous( SERCOM_FREQ_REF / divider ); + + enableSPI(); +} + +void SERCOM::setClockModeSPI(SercomSpiClockMode clockMode) +{ + int cpha, cpol; + if((clockMode & (0x1ul)) == 0) + cpha = 0; + else + cpha = 1; + + if((clockMode & (0x2ul)) == 0) + cpol = 0; + else + cpol = 1; + + //Register enable-protected + disableSPI(); + + sercom->SPI.CTRLA.bit.CPOL = cpol; + sercom->SPI.CTRLA.bit.CPHA = cpha; + + enableSPI(); +} + +uint8_t SERCOM::transferDataSPI(uint8_t data) +{ + sercom->SPI.DATA.bit.DATA = data; // Writing data into Data register + + while( sercom->SPI.INTFLAG.bit.RXC == 0 ) + { + // Waiting Complete Reception + } + + return sercom->SPI.DATA.bit.DATA; // Reading data +} + +bool SERCOM::isBufferOverflowErrorSPI() +{ + return sercom->SPI.STATUS.bit.BUFOVF; +} + +bool SERCOM::isDataRegisterEmptySPI() +{ + //DRE : Data Register Empty + return sercom->SPI.INTFLAG.bit.DRE; +} + +//bool SERCOM::isTransmitCompleteSPI() +//{ +// //TXC : Transmit complete +// return sercom->SPI.INTFLAG.bit.TXC; +//} +// +//bool SERCOM::isReceiveCompleteSPI() +//{ +// //RXC : Receive complete +// return sercom->SPI.INTFLAG.bit.RXC; +//} + +uint8_t SERCOM::calculateBaudrateSynchronous(uint32_t baudrate) +{ + return SERCOM_FREQ_REF / (2 * baudrate) - 1; +} + + +/* ========================= + * ===== Sercom WIRE + * ========================= + */ +void SERCOM::resetWIRE() +{ + //I2CM OR I2CS, no matter SWRST is the same bit. + + //Setting the Software bit to 1 + sercom->I2CM.CTRLA.bit.SWRST = 1; + + //Wait both bits Software Reset from CTRLA and SYNCBUSY are equal to 0 + while(sercom->I2CM.CTRLA.bit.SWRST || sercom->I2CM.SYNCBUSY.bit.SWRST); +} + +void SERCOM::enableWIRE() +{ + // I2C Master and Slave modes share the ENABLE bit function. + + // Enable the I2C master mode + sercom->I2CM.CTRLA.bit.ENABLE = 1 ; + + while ( sercom->I2CM.SYNCBUSY.bit.ENABLE != 0 ) + { + // Waiting the enable bit from SYNCBUSY is equal to 0; + } + + // Setting bus idle mode + sercom->I2CM.STATUS.bit.BUSSTATE = 1 ; + + while ( sercom->I2CM.SYNCBUSY.bit.SYSOP != 0 ) + { + // Wait the SYSOP bit from SYNCBUSY coming back to 0 + } +} + +void SERCOM::disableWIRE() +{ + // I2C Master and Slave modes share the ENABLE bit function. + + // Enable the I2C master mode + sercom->I2CM.CTRLA.bit.ENABLE = 0 ; + + while ( sercom->I2CM.SYNCBUSY.bit.ENABLE != 0 ) + { + // Waiting the enable bit from SYNCBUSY is equal to 0; + } +} + +void SERCOM::initSlaveWIRE( uint8_t ucAddress, bool enableGeneralCall ) +{ + // Initialize the peripheral clock and interruption + initClockNVIC() ; + resetWIRE() ; + + // Set slave mode + sercom->I2CS.CTRLA.bit.MODE = I2C_SLAVE_OPERATION; + + sercom->I2CS.ADDR.reg = SERCOM_I2CS_ADDR_ADDR( ucAddress & 0x7Ful ) | // 0x7F, select only 7 bits + SERCOM_I2CS_ADDR_ADDRMASK( 0x00ul ); // 0x00, only match exact address + if (enableGeneralCall) { + sercom->I2CS.ADDR.reg |= SERCOM_I2CS_ADDR_GENCEN; // enable general call (address 0x00) + } + + // Set the interrupt register + sercom->I2CS.INTENSET.reg = SERCOM_I2CS_INTENSET_PREC | // Stop + SERCOM_I2CS_INTENSET_AMATCH | // Address Match + SERCOM_I2CS_INTENSET_DRDY ; // Data Ready + + while ( sercom->I2CM.SYNCBUSY.bit.SYSOP != 0 ) + { + // Wait the SYSOP bit from SYNCBUSY to come back to 0 + } +} + +void SERCOM::initMasterWIRE( uint32_t baudrate ) +{ + // Initialize the peripheral clock and interruption + initClockNVIC() ; + + resetWIRE() ; + + // Set master mode and enable SCL Clock Stretch mode (stretch after ACK bit) + sercom->I2CM.CTRLA.reg = SERCOM_I2CM_CTRLA_MODE( I2C_MASTER_OPERATION )/* | + SERCOM_I2CM_CTRLA_SCLSM*/ ; + + // Enable Smart mode and Quick Command + //sercom->I2CM.CTRLB.reg = SERCOM_I2CM_CTRLB_SMEN /*| SERCOM_I2CM_CTRLB_QCEN*/ ; + + + // Enable all interrupts +// sercom->I2CM.INTENSET.reg = SERCOM_I2CM_INTENSET_MB | SERCOM_I2CM_INTENSET_SB | SERCOM_I2CM_INTENSET_ERROR ; + + // Synchronous arithmetic baudrate + sercom->I2CM.BAUD.bit.BAUD = SystemCoreClock / ( 2 * baudrate) - 5 - (((SystemCoreClock / 1000000) * WIRE_RISE_TIME_NANOSECONDS) / (2 * 1000)); +} + +void SERCOM::prepareNackBitWIRE( void ) +{ + if(isMasterWIRE()) { + // Send a NACK + sercom->I2CM.CTRLB.bit.ACKACT = 1; + } else { + sercom->I2CS.CTRLB.bit.ACKACT = 1; + } +} + +void SERCOM::prepareAckBitWIRE( void ) +{ + if(isMasterWIRE()) { + // Send an ACK + sercom->I2CM.CTRLB.bit.ACKACT = 0; + } else { + sercom->I2CS.CTRLB.bit.ACKACT = 0; + } +} + +void SERCOM::prepareCommandBitsWire(uint8_t cmd) +{ + if(isMasterWIRE()) { + sercom->I2CM.CTRLB.bit.CMD = cmd; + + while(sercom->I2CM.SYNCBUSY.bit.SYSOP) + { + // Waiting for synchronization + } + } else { + sercom->I2CS.CTRLB.bit.CMD = cmd; + } +} + +bool SERCOM::startTransmissionWIRE(uint8_t address, SercomWireReadWriteFlag flag) +{ + // 7-bits address + 1-bits R/W + address = (address << 0x1ul) | flag; + + // If another master owns the bus or the last bus owner has not properly + // sent a stop, return failure early. This will prevent some misbehaved + // devices from deadlocking here at the cost of the caller being responsible + // for retrying the failed transmission. See SercomWireBusState for the + // possible bus states. + if(!isBusOwnerWIRE()) + { + if( isBusBusyWIRE() || (isArbLostWIRE() && !isBusIdleWIRE()) ) + { + return false; + } + } + + // Send start and address + sercom->I2CM.ADDR.bit.ADDR = address; + + // Address Transmitted + if ( flag == WIRE_WRITE_FLAG ) // Write mode + { + while( !sercom->I2CM.INTFLAG.bit.MB ) + { + // Wait transmission complete + } + // Check for loss of arbitration (multiple masters starting communication at the same time) + if(!isBusOwnerWIRE()) + { + // Restart communication + startTransmissionWIRE(address >> 1, flag); + } + } + else // Read mode + { + while( !sercom->I2CM.INTFLAG.bit.SB ) + { + // If the slave NACKS the address, the MB bit will be set. + // In that case, send a stop condition and return false. + if (sercom->I2CM.INTFLAG.bit.MB) { + sercom->I2CM.CTRLB.bit.CMD = 3; // Stop condition + return false; + } + // Wait transmission complete + } + + // Clean the 'Slave on Bus' flag, for further usage. + //sercom->I2CM.INTFLAG.bit.SB = 0x1ul; + } + + + //ACK received (0: ACK, 1: NACK) + if(sercom->I2CM.STATUS.bit.RXNACK) + { + return false; + } + else + { + return true; + } +} + +bool SERCOM::sendDataMasterWIRE(uint8_t data) +{ + //Send data + sercom->I2CM.DATA.bit.DATA = data; + + //Wait transmission successful + while(!sercom->I2CM.INTFLAG.bit.MB) { + + // If a bus error occurs, the MB bit may never be set. + // Check the bus error bit and ARBLOST bit and bail if either is set. + if (sercom->I2CM.STATUS.bit.BUSERR || sercom->I2CM.STATUS.bit.ARBLOST) { + return false; + } + } + + //Problems on line? nack received? + if(sercom->I2CM.STATUS.bit.RXNACK) + return false; + else + return true; +} + +bool SERCOM::sendDataSlaveWIRE(uint8_t data) +{ + //Send data + sercom->I2CS.DATA.bit.DATA = data; + + //Problems on line? nack received? + if(!sercom->I2CS.INTFLAG.bit.DRDY || sercom->I2CS.STATUS.bit.RXNACK) + return false; + else + return true; +} + +bool SERCOM::isMasterWIRE( void ) +{ + return sercom->I2CS.CTRLA.bit.MODE == I2C_MASTER_OPERATION; +} + +bool SERCOM::isSlaveWIRE( void ) +{ + return sercom->I2CS.CTRLA.bit.MODE == I2C_SLAVE_OPERATION; +} + +bool SERCOM::isBusIdleWIRE( void ) +{ + return sercom->I2CM.STATUS.bit.BUSSTATE == WIRE_IDLE_STATE; +} + +bool SERCOM::isBusOwnerWIRE( void ) +{ + return sercom->I2CM.STATUS.bit.BUSSTATE == WIRE_OWNER_STATE; +} + +bool SERCOM::isArbLostWIRE( void ) +{ + return sercom->I2CM.STATUS.bit.ARBLOST == 1; +} + +bool SERCOM::isBusBusyWIRE( void ) +{ + return sercom->I2CM.STATUS.bit.BUSSTATE == WIRE_BUSY_STATE; +} + +bool SERCOM::isDataReadyWIRE( void ) +{ + return sercom->I2CS.INTFLAG.bit.DRDY; +} + +bool SERCOM::isStopDetectedWIRE( void ) +{ + return sercom->I2CS.INTFLAG.bit.PREC; +} + +bool SERCOM::isRestartDetectedWIRE( void ) +{ + return sercom->I2CS.STATUS.bit.SR; +} + +bool SERCOM::isAddressMatch( void ) +{ + return sercom->I2CS.INTFLAG.bit.AMATCH; +} + +bool SERCOM::isMasterReadOperationWIRE( void ) +{ + return sercom->I2CS.STATUS.bit.DIR; +} + +bool SERCOM::isRXNackReceivedWIRE( void ) +{ + return sercom->I2CM.STATUS.bit.RXNACK; +} + +int SERCOM::availableWIRE( void ) +{ + if(isMasterWIRE()) + return sercom->I2CM.INTFLAG.bit.SB; + else + return sercom->I2CS.INTFLAG.bit.DRDY; +} + +uint8_t SERCOM::readDataWIRE( void ) +{ + if(isMasterWIRE()) + { + while( sercom->I2CM.INTFLAG.bit.SB == 0 && sercom->I2CM.INTFLAG.bit.MB == 0 ) + { + // Waiting complete receive + } + + return sercom->I2CM.DATA.bit.DATA ; + } + else + { + return sercom->I2CS.DATA.reg ; + } +} + + +void SERCOM::initClockNVIC( void ) +{ + uint8_t clockId = 0; + IRQn_Type IdNvic=PendSV_IRQn ; // Dummy init to intercept potential error later + + if(sercom == SERCOM0) + { + clockId = GCM_SERCOM0_CORE; + IdNvic = SERCOM0_IRQn; + } + else if(sercom == SERCOM1) + { + clockId = GCM_SERCOM1_CORE; + IdNvic = SERCOM1_IRQn; + } + else if(sercom == SERCOM2) + { + clockId = GCM_SERCOM2_CORE; + IdNvic = SERCOM2_IRQn; + } + else if(sercom == SERCOM3) + { + clockId = GCM_SERCOM3_CORE; + IdNvic = SERCOM3_IRQn; + } + #if defined(SERCOM4) + else if(sercom == SERCOM4) + { + clockId = GCM_SERCOM4_CORE; + IdNvic = SERCOM4_IRQn; + } + #endif // SERCOM4 + #if defined(SERCOM5) + else if(sercom == SERCOM5) + { + clockId = GCM_SERCOM5_CORE; + IdNvic = SERCOM5_IRQn; + } + #endif // SERCOM5 + + if ( IdNvic == PendSV_IRQn ) + { + // We got a problem here + return ; + } + + // Setting NVIC + NVIC_EnableIRQ(IdNvic); + NVIC_SetPriority (IdNvic, SERCOM_NVIC_PRIORITY); /* set Priority */ + + //Setting clock + GCLK->CLKCTRL.reg = GCLK_CLKCTRL_ID( clockId ) | // Generic Clock 0 (SERCOMx) + GCLK_CLKCTRL_GEN_GCLK0 | // Generic Clock Generator 0 is source + GCLK_CLKCTRL_CLKEN ; + + while ( GCLK->STATUS.reg & GCLK_STATUS_SYNCBUSY ) + { + /* Wait for synchronization */ + } +} diff --git a/cores/arduino/SERCOM.h b/cores/arduino/SERCOM.h new file mode 100644 index 0000000..80b54de --- /dev/null +++ b/cores/arduino/SERCOM.h @@ -0,0 +1,228 @@ +/* + 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 _SERCOM_CLASS_ +#define _SERCOM_CLASS_ + +#include + +#define SERCOM_FREQ_REF 48000000 +#define SERCOM_NVIC_PRIORITY ((1<<__NVIC_PRIO_BITS) - 1) + +typedef enum +{ + UART_EXT_CLOCK = 0, + UART_INT_CLOCK = 0x1u +} SercomUartMode; + +typedef enum +{ + SPI_SLAVE_OPERATION = 0x2u, + SPI_MASTER_OPERATION = 0x3u +} SercomSpiMode; + +typedef enum +{ + I2C_SLAVE_OPERATION = 0x4u, + I2C_MASTER_OPERATION = 0x5u +} SercomI2CMode; + +typedef enum +{ + SERCOM_EVEN_PARITY = 0, + SERCOM_ODD_PARITY, + SERCOM_NO_PARITY +} SercomParityMode; + +typedef enum +{ + SERCOM_STOP_BIT_1 = 0, + SERCOM_STOP_BITS_2 +} SercomNumberStopBit; + +typedef enum +{ + MSB_FIRST = 0, + LSB_FIRST +} SercomDataOrder; + +typedef enum +{ + UART_CHAR_SIZE_8_BITS = 0, + UART_CHAR_SIZE_9_BITS, + UART_CHAR_SIZE_5_BITS = 0x5u, + UART_CHAR_SIZE_6_BITS, + UART_CHAR_SIZE_7_BITS +} SercomUartCharSize; + +typedef enum +{ + SERCOM_RX_PAD_0 = 0, + SERCOM_RX_PAD_1, + SERCOM_RX_PAD_2, + SERCOM_RX_PAD_3 +} SercomRXPad; + +typedef enum +{ + UART_TX_PAD_0 = 0x0ul, // Only for UART + UART_TX_PAD_2 = 0x1ul, // Only for UART + UART_TX_RTS_CTS_PAD_0_2_3 = 0x2ul, // Only for UART with TX on PAD0, RTS on PAD2 and CTS on PAD3 +} SercomUartTXPad; + +typedef enum +{ + SAMPLE_RATE_x16 = 0x1, //Fractional + SAMPLE_RATE_x8 = 0x3, //Fractional +} SercomUartSampleRate; + +typedef enum +{ + SERCOM_SPI_MODE_0 = 0, // CPOL : 0 | CPHA : 0 + SERCOM_SPI_MODE_1, // CPOL : 0 | CPHA : 1 + SERCOM_SPI_MODE_2, // CPOL : 1 | CPHA : 0 + SERCOM_SPI_MODE_3 // CPOL : 1 | CPHA : 1 +} SercomSpiClockMode; + +typedef enum +{ + SPI_PAD_0_SCK_1 = 0, + SPI_PAD_2_SCK_3, + SPI_PAD_3_SCK_1, + SPI_PAD_0_SCK_3 +} SercomSpiTXPad; + +typedef enum +{ + SPI_CHAR_SIZE_8_BITS = 0x0ul, + SPI_CHAR_SIZE_9_BITS +} SercomSpiCharSize; + +typedef enum +{ + WIRE_UNKNOWN_STATE = 0x0ul, + WIRE_IDLE_STATE, + WIRE_OWNER_STATE, + WIRE_BUSY_STATE +} SercomWireBusState; + +typedef enum +{ + WIRE_WRITE_FLAG = 0x0ul, + WIRE_READ_FLAG +} SercomWireReadWriteFlag; + +typedef enum +{ + WIRE_MASTER_ACT_NO_ACTION = 0, + WIRE_MASTER_ACT_REPEAT_START, + WIRE_MASTER_ACT_READ, + WIRE_MASTER_ACT_STOP +} SercomMasterCommandWire; + +typedef enum +{ + WIRE_MASTER_ACK_ACTION = 0, + WIRE_MASTER_NACK_ACTION +} SercomMasterAckActionWire; + +class SERCOM +{ + public: + SERCOM(Sercom* s) ; + + /* ========== UART ========== */ + void initUART(SercomUartMode mode, SercomUartSampleRate sampleRate, uint32_t baudrate=0) ; + void initFrame(SercomUartCharSize charSize, SercomDataOrder dataOrder, SercomParityMode parityMode, SercomNumberStopBit nbStopBits) ; + void initPads(SercomUartTXPad txPad, SercomRXPad rxPad) ; + + void resetUART( void ) ; + void enableUART( void ) ; + void flushUART( void ) ; + void clearStatusUART( void ) ; + bool availableDataUART( void ) ; + bool isBufferOverflowErrorUART( void ) ; + bool isFrameErrorUART( void ) ; + void clearFrameErrorUART( void ) ; + bool isParityErrorUART( void ) ; + bool isDataRegisterEmptyUART( void ) ; + uint8_t readDataUART( void ) ; + int writeDataUART(uint8_t data) ; + bool isUARTError() ; + void acknowledgeUARTError() ; + void enableDataRegisterEmptyInterruptUART(); + void disableDataRegisterEmptyInterruptUART(); + + /* ========== SPI ========== */ + void initSPI(SercomSpiTXPad mosi, SercomRXPad miso, SercomSpiCharSize charSize, SercomDataOrder dataOrder) ; + void initSPIClock(SercomSpiClockMode clockMode, uint32_t baudrate) ; + + void resetSPI( void ) ; + void enableSPI( void ) ; + void disableSPI( void ) ; + void setDataOrderSPI(SercomDataOrder dataOrder) ; + SercomDataOrder getDataOrderSPI( void ) ; + void setBaudrateSPI(uint8_t divider) ; + void setClockModeSPI(SercomSpiClockMode clockMode) ; + uint8_t transferDataSPI(uint8_t data) ; + bool isBufferOverflowErrorSPI( void ) ; + bool isDataRegisterEmptySPI( void ) ; + bool isTransmitCompleteSPI( void ) ; + bool isReceiveCompleteSPI( void ) ; + + /* ========== WIRE ========== */ + void initSlaveWIRE(uint8_t address, bool enableGeneralCall = false) ; + void initMasterWIRE(uint32_t baudrate) ; + + void resetWIRE( void ) ; + void enableWIRE( void ) ; + void disableWIRE( void ); + void prepareNackBitWIRE( void ) ; + void prepareAckBitWIRE( void ) ; + void prepareCommandBitsWire(uint8_t cmd); + bool startTransmissionWIRE(uint8_t address, SercomWireReadWriteFlag flag) ; + bool sendDataMasterWIRE(uint8_t data) ; + bool sendDataSlaveWIRE(uint8_t data) ; + bool isMasterWIRE( void ) ; + bool isSlaveWIRE( void ) ; + bool isBusIdleWIRE( void ) ; + bool isBusOwnerWIRE( void ) ; + bool isArbLostWIRE( void ); + bool isBusBusyWIRE( void ); + bool isDataReadyWIRE( void ) ; + bool isStopDetectedWIRE( void ) ; + bool isRestartDetectedWIRE( void ) ; + bool isAddressMatch( void ) ; + bool isMasterReadOperationWIRE( void ) ; + bool isRXNackReceivedWIRE( void ) ; + int availableWIRE( void ) ; + uint8_t readDataWIRE( void ) ; + + private: + Sercom* sercom; + uint8_t calculateBaudrateSynchronous(uint32_t baudrate) ; + uint32_t division(uint32_t dividend, uint32_t divisor) ; + void initClockNVIC( void ) ; + + // Flag set when data is loaded into sercom->USART.DATA.reg. + // Helps with preventing UART lockups when flushing on startup + // and the asyncronous nature of the DRE and TXC interrupt flags. + bool onFlushWaitUartTXC = false; +}; + +#endif diff --git a/cores/arduino/SafeRingBuffer.h b/cores/arduino/SafeRingBuffer.h new file mode 100644 index 0000000..235406f --- /dev/null +++ b/cores/arduino/SafeRingBuffer.h @@ -0,0 +1,62 @@ +/* + Copyright (c) 2020 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 +*/ + +#ifdef __cplusplus + +#ifndef _SAFE_RING_BUFFER_ +#define _SAFE_RING_BUFFER_ + +#include +#include "sync.h" + +namespace arduino { + +template +class SafeRingBufferN : public RingBufferN +{ + public: + int read_char(); + void store_char( uint8_t c ) ; +}; + +typedef SafeRingBufferN SafeRingBuffer; + +template +int SafeRingBufferN::read_char() { + synchronized { + return RingBufferN::read_char(); + } + + // We should never reached this line because the synchronized {} block gets + // executed at least once. However the compiler gets confused and prints a + // warning about control reaching the end of a non-void function. This + // silences that warning. + return -1; +} + +template +void SafeRingBufferN::store_char(uint8_t c) { + synchronized { + RingBufferN::store_char(c); + } +} + +} + +#endif /* _SAFE_RING_BUFFER_ */ +#endif /* __cplusplus */ diff --git a/cores/arduino/Tone.cpp b/cores/arduino/Tone.cpp new file mode 100644 index 0000000..37b6b0b --- /dev/null +++ b/cores/arduino/Tone.cpp @@ -0,0 +1,205 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#include "Arduino.h" +#include "variant.h" + +#define WAIT_TC16_REGS_SYNC(x) while(x->COUNT16.STATUS.bit.SYNCBUSY); + +uint32_t toneMaxFrequency = F_CPU / 2; +uint32_t lastOutputPin = 0xFFFFFFFF; + +volatile uint32_t *portToggleRegister; +volatile uint32_t *portClearRegister; +volatile uint32_t portBitMask; +volatile int64_t toggleCount; +volatile bool toneIsActive = false; +volatile bool firstTimeRunning = false; + +#define TONE_TC TC5 +#define TONE_TC_IRQn TC5_IRQn +#define TONE_TC_TOP 0xFFFF +#define TONE_TC_CHANNEL 0 + +void TC5_Handler (void) __attribute__ ((weak, alias("Tone_Handler"))); + +static inline void resetTC (Tc* TCx) +{ + // Disable TCx + TCx->COUNT16.CTRLA.reg &= ~TC_CTRLA_ENABLE; + WAIT_TC16_REGS_SYNC(TCx) + + // Reset TCx + TCx->COUNT16.CTRLA.reg = TC_CTRLA_SWRST; + WAIT_TC16_REGS_SYNC(TCx) + while (TCx->COUNT16.CTRLA.bit.SWRST); +} + +void toneAccurateClock (uint32_t accurateSystemCoreClockFrequency) +{ + toneMaxFrequency = accurateSystemCoreClockFrequency / 2; +} + +void tone (unsigned char outputPin, unsigned int frequency, unsigned long duration) +{ + + // Avoid divide by zero error by calling 'noTone' instead + if (frequency == 0) + { + noTone(outputPin); + return; + } + + // Configure interrupt request + NVIC_DisableIRQ(TONE_TC_IRQn); + NVIC_ClearPendingIRQ(TONE_TC_IRQn); + + if(!firstTimeRunning) + { + firstTimeRunning = true; + + NVIC_SetPriority(TONE_TC_IRQn, 0); + + // Enable GCLK for TC4 and TC5 (timer counter input clock) + GCLK->CLKCTRL.reg = (uint16_t) (GCLK_CLKCTRL_CLKEN | GCLK_CLKCTRL_GEN_GCLK0 | GCLK_CLKCTRL_ID(GCM_TC4_TC5)); + while (GCLK->STATUS.bit.SYNCBUSY); + } + + if (toneIsActive && (outputPin != lastOutputPin)) + noTone(lastOutputPin); + + // + // Calculate best prescaler divider and comparator value for a 16 bit TC peripheral + // + + uint32_t prescalerConfigBits; + uint32_t ccValue; + + ccValue = toneMaxFrequency / frequency - 1; + prescalerConfigBits = TC_CTRLA_PRESCALER_DIV1; + + uint8_t i = 0; + + while(ccValue > TONE_TC_TOP) + { + ccValue = toneMaxFrequency / frequency / (2< 0 ? frequency * duration * 2 / 1000UL : -1LL); + + resetTC(TONE_TC); + + uint16_t tmpReg = 0; + tmpReg |= TC_CTRLA_MODE_COUNT16; // Set Timer counter Mode to 16 bits + tmpReg |= TC_CTRLA_WAVEGEN_MFRQ; // Set TONE_TC mode as match frequency + tmpReg |= prescalerConfigBits; + TONE_TC->COUNT16.CTRLA.reg |= tmpReg; + WAIT_TC16_REGS_SYNC(TONE_TC) + + TONE_TC->COUNT16.CC[TONE_TC_CHANNEL].reg = (uint16_t) ccValue; + WAIT_TC16_REGS_SYNC(TONE_TC) + + portToggleRegister = &(PORT->Group[g_APinDescription[outputPin].ulPort].OUTTGL.reg); + portClearRegister = &(PORT->Group[g_APinDescription[outputPin].ulPort].OUTCLR.reg); + portBitMask = (1ul << g_APinDescription[outputPin].ulPin); + + // Enable the TONE_TC interrupt request + TONE_TC->COUNT16.INTENSET.bit.MC0 = 1; + + if (outputPin != lastOutputPin) + { + lastOutputPin = outputPin; + digitalWrite(outputPin, LOW); + pinMode(outputPin, OUTPUT); + toneIsActive = true; + } + + // Enable TONE_TC + TONE_TC->COUNT16.CTRLA.reg |= TC_CTRLA_ENABLE; + WAIT_TC16_REGS_SYNC(TONE_TC) + + NVIC_EnableIRQ(TONE_TC_IRQn); +} + +void noTone (uint8_t outputPin) +{ + /* 'tone' need to run at least once in order to enable GCLK for + * the timers used for the tone-functionality. If 'noTone' is called + * without ever calling 'tone' before then 'WAIT_TC16_REGS_SYNC(TCx)' + * will wait infinitely. The variable 'firstTimeRunning' is set the + * 1st time 'tone' is set so it can be used to detect wether or not + * 'tone' has been called before. + */ + if(firstTimeRunning) + { + resetTC(TONE_TC); + digitalWrite(outputPin, LOW); + toneIsActive = false; + } +} + +#ifdef __cplusplus +extern "C" { +#endif + +void Tone_Handler (void) +{ + if (toggleCount != 0) + { + // Toggle the ouput pin + *portToggleRegister = portBitMask; + + if (toggleCount > 0) + --toggleCount; + + // Clear the interrupt + TONE_TC->COUNT16.INTFLAG.bit.MC0 = 1; + } + else + { + resetTC(TONE_TC); + *portClearRegister = portBitMask; + toneIsActive = false; + } +} + +#ifdef __cplusplus +} +#endif diff --git a/cores/arduino/USB/CDC.cpp b/cores/arduino/USB/CDC.cpp new file mode 100644 index 0000000..8d6c6f4 --- /dev/null +++ b/cores/arduino/USB/CDC.cpp @@ -0,0 +1,355 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#include +#include // Needed for auto-reset with 1200bps port touch +#include "CDC.h" +#include "USBAPI.h" +#include "SAMD21_USBDevice.h" + +#include +#include +#include + +#ifdef CDC_ENABLED + +using namespace arduino; + +extern USBDevice_SAMD21G18x usbd; + +#define CDC_SERIAL_BUFFER_SIZE 256 + +/* For information purpose only since RTS is not always handled by the terminal application */ +#define CDC_LINESTATE_DTR 0x01 // Data Terminal Ready +#define CDC_LINESTATE_RTS 0x02 // Ready to Send + +#define CDC_LINESTATE_READY (CDC_LINESTATE_RTS | CDC_LINESTATE_DTR) + +extern USBDeviceClass USBDevice; + +typedef struct { + uint32_t dwDTERate; + uint8_t bCharFormat; + uint8_t bParityType; + uint8_t bDataBits; + uint8_t lineState; +} LineInfo; + +static volatile LineInfo _usbLineInfo = { + 115200, // dWDTERate + 0x00, // bCharFormat + 0x00, // bParityType + 0x08, // bDataBits + 0x00 // lineState +}; + +static volatile int32_t breakValue = -1; + +// CDC +#define CDC_ACM_INTERFACE pluggedInterface // CDC ACM +#define CDC_DATA_INTERFACE uint8_t(pluggedInterface + 1) // CDC Data +#define CDC_ENDPOINT_ACM pluggedEndpoint +#define CDC_ENDPOINT_OUT pluggedEndpoint + 1 +#define CDC_ENDPOINT_IN pluggedEndpoint + 2 + +#define CDC_RX CDC_ENDPOINT_OUT +#define CDC_TX CDC_ENDPOINT_IN + +int Serial_::getInterface(uint8_t* interfaceNum) +{ + interfaceNum[0] += 2; // uses 2 + CDCDescriptor _cdcInterface = { + D_IAD(pluggedInterface, 2, CDC_COMMUNICATION_INTERFACE_CLASS, CDC_ABSTRACT_CONTROL_MODEL, 0), + + // CDC communication interface + D_INTERFACE(CDC_ACM_INTERFACE, 1, CDC_COMMUNICATION_INTERFACE_CLASS, CDC_ABSTRACT_CONTROL_MODEL, 0), + D_CDCCS(CDC_HEADER, CDC_V1_10 & 0xFF, (CDC_V1_10>>8) & 0x0FF), // Header (1.10 bcd) + + D_CDCCS4(CDC_ABSTRACT_CONTROL_MANAGEMENT, 6), // SET_LINE_CODING, GET_LINE_CODING, SET_CONTROL_LINE_STATE supported + D_CDCCS(CDC_UNION, CDC_ACM_INTERFACE, CDC_DATA_INTERFACE), // Communication interface is master, data interface is slave 0 + D_CDCCS(CDC_CALL_MANAGEMENT, 1, 1), // Device handles call management (not) + D_ENDPOINT(USB_ENDPOINT_IN(CDC_ENDPOINT_ACM), USB_ENDPOINT_TYPE_INTERRUPT, 0x10, 0x10), + + // CDC data interface + D_INTERFACE(CDC_DATA_INTERFACE, 2, CDC_DATA_INTERFACE_CLASS, 0, 0), + D_ENDPOINT(USB_ENDPOINT_OUT(CDC_ENDPOINT_OUT), USB_ENDPOINT_TYPE_BULK, EPX_SIZE, 0), + D_ENDPOINT(USB_ENDPOINT_IN (CDC_ENDPOINT_IN), USB_ENDPOINT_TYPE_BULK, EPX_SIZE, 0) + }; + + return USBDevice.sendControl(&_cdcInterface, sizeof(_cdcInterface)); +} + +int Serial_::getDescriptor(USBSetup& /* setup */) +{ + return 0; +} + +static void utox8(uint32_t val, char* s) { + for (int i = 0; i < 8; i++) { + int d = val & 0XF; + val = (val >> 4); + + s[7 - i] = d > 9 ? 'A' + d - 10 : '0' + d; + } +} + +uint8_t Serial_::getShortName(char* name) { + // from section 9.3.3 of the datasheet + #define SERIAL_NUMBER_WORD_0 *(volatile uint32_t*)(0x0080A00C) + #define SERIAL_NUMBER_WORD_1 *(volatile uint32_t*)(0x0080A040) + #define SERIAL_NUMBER_WORD_2 *(volatile uint32_t*)(0x0080A044) + #define SERIAL_NUMBER_WORD_3 *(volatile uint32_t*)(0x0080A048) + + utox8(SERIAL_NUMBER_WORD_0, &name[0]); + utox8(SERIAL_NUMBER_WORD_1, &name[8]); + utox8(SERIAL_NUMBER_WORD_2, &name[16]); + utox8(SERIAL_NUMBER_WORD_3, &name[24]); + return 32; +} + +void Serial_::handleEndpoint(int /* ep */) { +} + +bool Serial_::setup(USBSetup& setup) +{ + uint8_t requestType = setup.bmRequestType; + uint8_t r = setup.bRequest; + uint8_t i = setup.wIndex; + + if (CDC_ACM_INTERFACE != i) { + return false; + } + + if (requestType == REQUEST_DEVICETOHOST_CLASS_INTERFACE) + { + if (r == CDC_GET_LINE_CODING) + { + USBDevice.sendControl((void*)&_usbLineInfo, 7); + return true; + } + } + + if (requestType == REQUEST_HOSTTODEVICE_CLASS_INTERFACE) + { + + if (r == CDC_SET_LINE_CODING) + { + USBDevice.recvControl((void*)&_usbLineInfo, 7); + } + + if (r == CDC_SET_CONTROL_LINE_STATE) + { + _usbLineInfo.lineState = setup.wValueL; + } + + if (r == CDC_SET_LINE_CODING || r == CDC_SET_CONTROL_LINE_STATE) + { + // auto-reset into the bootloader is triggered when the port, already + // open at 1200 bps, is closed. We check DTR state to determine if host + // port is open (bit 0 of lineState). + if (_usbLineInfo.dwDTERate == 1200 && (_usbLineInfo.lineState & CDC_LINESTATE_DTR) == 0) + { + initiateReset(250); + } + else + { + cancelReset(); + } + USBDevice.sendZlp(0); + } + + if (CDC_SEND_BREAK == r) + { + breakValue = ((uint16_t)setup.wValueH << 8) | setup.wValueL; + USBDevice.sendZlp(0); + } + return true; + } + return false; +} + +Serial_::Serial_(USBDeviceClass &_usb) : PluggableUSBModule(3, 2, epType), usb(_usb), stalled(false) +{ + epType[0] = USB_ENDPOINT_TYPE_INTERRUPT | USB_ENDPOINT_IN(0); + epType[1] = USB_ENDPOINT_TYPE_BULK | USB_ENDPOINT_OUT(0); + epType[2] = USB_ENDPOINT_TYPE_BULK | USB_ENDPOINT_IN(0); + PluggableUSB().plug(this); +} + +void Serial_::enableInterrupt() { + usbd.epBank1EnableTransferComplete(CDC_ENDPOINT_ACM); + usbd.epBank0EnableTransferComplete(CDC_ENDPOINT_OUT); +} + +void Serial_::begin(unsigned long /* baudrate */) +{ + // uart config is ignored in USB-CDC +} + +void Serial_::begin(unsigned long /* baudrate */, uint16_t /* config */) +{ + // uart config is ignored in USB-CDC +} + +void Serial_::end(void) +{ + memset((void*)&_usbLineInfo, 0, sizeof(_usbLineInfo)); +} + +int _serialPeek = -1; + +int Serial_::available(void) +{ + return usb.available(CDC_ENDPOINT_OUT) + (_serialPeek != -1); +} + +int Serial_::availableForWrite(void) +{ + // return the number of bytes left in the current bank, + // always EP size - 1, because bank is flushed on every write + return (EPX_SIZE - 1); +} + +int Serial_::peek(void) +{ + if (_serialPeek != -1) + return _serialPeek; + _serialPeek = read(); + return _serialPeek; +} + +int Serial_::read(void) +{ + if (_serialPeek != -1) { + int res = _serialPeek; + _serialPeek = -1; + return res; + } + return usb.recv(CDC_ENDPOINT_OUT); +} + +size_t Serial_::readBytes(char *buffer, size_t length) +{ + size_t count = 0; + _startMillis = millis(); + while (count < length) + { + uint32_t n = usb.recv(CDC_ENDPOINT_OUT, buffer+count, length-count); + if (n == 0 && (millis() - _startMillis) >= _timeout) + break; + count += n; + } + return count; +} + +void Serial_::flush(void) +{ + usb.flush(CDC_ENDPOINT_IN); +} + +void Serial_::clear(void) { + usb.clear(CDC_ENDPOINT_IN); +} + +size_t Serial_::write(const uint8_t *buffer, size_t size) +{ + uint32_t r = usb.send(CDC_ENDPOINT_IN, buffer, size); + + if (r > 0) { + return r; + } else { + setWriteError(); + return 0; + } +} + +size_t Serial_::write(uint8_t c) { + return write(&c, 1); +} + +// This operator is a convenient way for a sketch to check whether the +// port has actually been configured and opened by the host (as opposed +// to just being connected to the host). It can be used, for example, in +// setup() before printing to ensure that an application on the host is +// actually ready to receive and display the data. +// We add a short delay before returning to fix a bug observed by Federico +// where the port is configured (lineState != 0) but not quite opened. +Serial_::operator bool() +{ + // this is here to avoid spurious opening after upload + if (millis() < 500) + return false; + + bool result = false; + + if (_usbLineInfo.lineState > 0) + { + result = true; + } + + delay(10); + return result; +} + +int32_t Serial_::readBreak() { + uint8_t enableInterrupts = ((__get_PRIMASK() & 0x1) == 0); + + // disable interrupts, + // to avoid clearing a breakValue that might occur + // while processing the current break value + __disable_irq(); + + int32_t ret = breakValue; + + breakValue = -1; + + if (enableInterrupts) { + // re-enable the interrupts + __enable_irq(); + } + + return ret; +} + +unsigned long Serial_::baud() { + return _usbLineInfo.dwDTERate; +} + +uint8_t Serial_::stopbits() { + return _usbLineInfo.bCharFormat; +} + +uint8_t Serial_::paritytype() { + return _usbLineInfo.bParityType; +} + +uint8_t Serial_::numbits() { + return _usbLineInfo.bDataBits; +} + +bool Serial_::dtr() { + return ((_usbLineInfo.lineState & CDC_LINESTATE_DTR) == CDC_LINESTATE_DTR); +} + +bool Serial_::rts() { + return ((_usbLineInfo.lineState & CDC_LINESTATE_RTS) == CDC_LINESTATE_RTS); +} + +Serial_ SerialUSB(USBDevice); + +#endif diff --git a/cores/arduino/USB/CDC.h b/cores/arduino/USB/CDC.h new file mode 100644 index 0000000..8e88db5 --- /dev/null +++ b/cores/arduino/USB/CDC.h @@ -0,0 +1,78 @@ +#ifndef __CDC_H__ +#define __CDC_H__ + +#ifdef CDC_ENABLED + +#include "USBDesc.h" +#include "USBAPI.h" +#include "api/PluggableUSB.h" + + +#define CDC_V1_10 0x0110 +#define CDC_COMMUNICATION_INTERFACE_CLASS 0x02 + +#define CDC_CALL_MANAGEMENT 0x01 +#define CDC_ABSTRACT_CONTROL_MODEL 0x02 +#define CDC_HEADER 0x00 +#define CDC_ABSTRACT_CONTROL_MANAGEMENT 0x02 +#define CDC_UNION 0x06 +#define CDC_CS_INTERFACE 0x24 +#define CDC_CS_ENDPOINT 0x25 +#define CDC_DATA_INTERFACE_CLASS 0x0A + +// CDC CS interface descriptor +typedef struct +{ + uint8_t len; // 5 + uint8_t dtype; // 0x24 + uint8_t subtype; + uint8_t d0; + uint8_t d1; +} CDCCSInterfaceDescriptor; + +typedef struct +{ + uint8_t len; // 4 + uint8_t dtype; // 0x24 + uint8_t subtype; + uint8_t d0; +} CDCCSInterfaceDescriptor4; + +typedef struct +{ + uint8_t len; + uint8_t dtype; // 0x24 + uint8_t subtype; // 1 + uint8_t bmCapabilities; + uint8_t bDataInterface; +} CMFunctionalDescriptor; + +typedef struct +{ + uint8_t len; + uint8_t dtype; // 0x24 + uint8_t subtype; // 1 + uint8_t bmCapabilities; +} ACMFunctionalDescriptor; + +typedef struct +{ + // IAD + IADDescriptor iad; // Only needed on compound device + // Control + InterfaceDescriptor cif; + CDCCSInterfaceDescriptor header; + ACMFunctionalDescriptor controlManagement; // ACM + CDCCSInterfaceDescriptor functionalDescriptor; // CDC_UNION + CMFunctionalDescriptor callManagement; // Call Management + EndpointDescriptor cifin; + + // Data + InterfaceDescriptor dif; + EndpointDescriptor in; + EndpointDescriptor out; +} CDCDescriptor; + + +#endif +#endif \ No newline at end of file diff --git a/cores/arduino/USB/SAMD21_USBDevice.h b/cores/arduino/USB/SAMD21_USBDevice.h new file mode 100644 index 0000000..98a95ce --- /dev/null +++ b/cores/arduino/USB/SAMD21_USBDevice.h @@ -0,0 +1,416 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#pragma once + +#include + +#include +#include +#include + +#include "sync.h" + +typedef uint8_t ep_t; + +class USBDevice_SAMD21G18x { +public: + USBDevice_SAMD21G18x() : usb(USB->DEVICE) { + // Empty + } + + // USB Device function mapping + // --------------------------- + + // Reset USB Device + inline void reset(); + + // Enable + inline void enable() { usb.CTRLA.bit.ENABLE = 1; } + inline void disable() { usb.CTRLA.bit.ENABLE = 0; } + + // USB mode (device/host) + inline void setUSBDeviceMode() { usb.CTRLA.bit.MODE = USB_CTRLA_MODE_DEVICE_Val; } + inline void setUSBHostMode() { usb.CTRLA.bit.MODE = USB_CTRLA_MODE_HOST_Val; } + + inline void runInStandby() { usb.CTRLA.bit.RUNSTDBY = 1; } + inline void noRunInStandby() { usb.CTRLA.bit.RUNSTDBY = 0; } + inline void wakeupHost() { usb.CTRLB.bit.UPRSM = 1; } + + // USB QoS + inline void setDataSensitiveQoS() { usb.QOSCTRL.bit.DQOS = 2; } + inline void setConfigSensitiveQoS() { usb.QOSCTRL.bit.CQOS = 2; } + + // USB speed + inline void setFullSpeed() { usb.CTRLB.bit.SPDCONF = USB_DEVICE_CTRLB_SPDCONF_FS_Val; } + inline void setLowSpeed() { usb.CTRLB.bit.SPDCONF = USB_DEVICE_CTRLB_SPDCONF_LS_Val; } + inline void setHiSpeed() { usb.CTRLB.bit.SPDCONF = USB_DEVICE_CTRLB_SPDCONF_HS_Val; } + inline void setHiSpeedTestMode() { usb.CTRLB.bit.SPDCONF = USB_DEVICE_CTRLB_SPDCONF_HSTM_Val; } + + // Authorize attach if Vbus is present + inline void attach() { usb.CTRLB.bit.DETACH = 0; } + inline void detach() { usb.CTRLB.bit.DETACH = 1; } + + // USB Interrupts + inline bool isEndOfResetInterrupt() { return usb.INTFLAG.bit.EORST; } + inline void ackEndOfResetInterrupt() { usb.INTFLAG.reg = USB_DEVICE_INTFLAG_EORST; } + inline void enableEndOfResetInterrupt() { usb.INTENSET.bit.EORST = 1; } + inline void disableEndOfResetInterrupt() { usb.INTENCLR.bit.EORST = 1; } + + inline bool isStartOfFrameInterrupt() { return usb.INTFLAG.bit.SOF; } + inline void ackStartOfFrameInterrupt() { usb.INTFLAG.reg = USB_DEVICE_INTFLAG_SOF; } + inline void enableStartOfFrameInterrupt() { usb.INTENSET.bit.SOF = 1; } + inline void disableStartOfFrameInterrupt() { usb.INTENCLR.bit.SOF = 1; } + + // USB Address + inline void setAddress(uint32_t addr) { usb.DADD.bit.DADD = addr; usb.DADD.bit.ADDEN = 1; } + inline void unsetAddress() { usb.DADD.bit.DADD = 0; usb.DADD.bit.ADDEN = 0; } + + // Frame number + inline uint16_t frameNumber() { return usb.FNUM.bit.FNUM; } + + // Load calibration values + inline void calibrate(); + + // USB Device Endpoints function mapping + // ------------------------------------- + + // Config + inline void epBank0SetType(ep_t ep, uint8_t type) { usb.DeviceEndpoint[ep].EPCFG.bit.EPTYPE0 = type; } + inline void epBank1SetType(ep_t ep, uint8_t type) { usb.DeviceEndpoint[ep].EPCFG.bit.EPTYPE1 = type; } + + // Interrupts + inline uint16_t epInterruptSummary() { return usb.EPINTSMRY.reg; } + + inline bool epHasPendingInterrupts(ep_t ep) { return usb.DeviceEndpoint[ep].EPINTFLAG.reg != 0; } + inline bool epBank0IsSetupReceived(ep_t ep) { return usb.DeviceEndpoint[ep].EPINTFLAG.bit.RXSTP; } + inline bool epBank0IsStalled(ep_t ep) { return usb.DeviceEndpoint[ep].EPINTFLAG.bit.STALL0; } + inline bool epBank1IsStalled(ep_t ep) { return usb.DeviceEndpoint[ep].EPINTFLAG.bit.STALL1; } + inline bool epBank0IsTransferFailed(ep_t ep) { return usb.DeviceEndpoint[ep].EPINTFLAG.bit.TRFAIL0; } + inline bool epBank1IsTransferFailed(ep_t ep) { return usb.DeviceEndpoint[ep].EPINTFLAG.bit.TRFAIL1; } + inline bool epBank0IsTransferComplete(ep_t ep) { return usb.DeviceEndpoint[ep].EPINTFLAG.bit.TRCPT0; } + inline bool epBank1IsTransferComplete(ep_t ep) { return usb.DeviceEndpoint[ep].EPINTFLAG.bit.TRCPT1; } + + inline void epAckPendingInterrupts(ep_t ep) { usb.DeviceEndpoint[ep].EPINTFLAG.reg = 0x7F; } + inline void epBank0AckSetupReceived(ep_t ep) { usb.DeviceEndpoint[ep].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_RXSTP; } + inline void epBank0AckStalled(ep_t ep) { usb.DeviceEndpoint[ep].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_STALL(1); } + inline void epBank1AckStalled(ep_t ep) { usb.DeviceEndpoint[ep].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_STALL(2); } + inline void epBank0AckTransferFailed(ep_t ep) { usb.DeviceEndpoint[ep].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRFAIL(1); } + inline void epBank1AckTransferFailed(ep_t ep) { usb.DeviceEndpoint[ep].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRFAIL(2); } + inline void epBank0AckTransferComplete(ep_t ep) { usb.DeviceEndpoint[ep].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRCPT(1); } + inline void epBank1AckTransferComplete(ep_t ep) { usb.DeviceEndpoint[ep].EPINTFLAG.reg = USB_DEVICE_EPINTFLAG_TRCPT(2); } + + inline void epBank0EnableSetupReceived(ep_t ep) { usb.DeviceEndpoint[ep].EPINTENSET.bit.RXSTP = 1; } + inline void epBank0EnableStalled(ep_t ep) { usb.DeviceEndpoint[ep].EPINTENSET.bit.STALL0 = 1; } + inline void epBank1EnableStalled(ep_t ep) { usb.DeviceEndpoint[ep].EPINTENSET.bit.STALL1 = 1; } + inline void epBank0EnableTransferFailed(ep_t ep) { usb.DeviceEndpoint[ep].EPINTENSET.bit.TRFAIL0 = 1; } + inline void epBank1EnableTransferFailed(ep_t ep) { usb.DeviceEndpoint[ep].EPINTENSET.bit.TRFAIL1 = 1; } + inline void epBank0EnableTransferComplete(ep_t ep) { usb.DeviceEndpoint[ep].EPINTENSET.bit.TRCPT0 = 1; } + inline void epBank1EnableTransferComplete(ep_t ep) { usb.DeviceEndpoint[ep].EPINTENSET.bit.TRCPT1 = 1; } + + inline void epBank0DisableSetupReceived(ep_t ep) { usb.DeviceEndpoint[ep].EPINTENCLR.bit.RXSTP = 1; } + inline void epBank0DisableStalled(ep_t ep) { usb.DeviceEndpoint[ep].EPINTENCLR.bit.STALL0 = 1; } + inline void epBank1DisableStalled(ep_t ep) { usb.DeviceEndpoint[ep].EPINTENCLR.bit.STALL1 = 1; } + inline void epBank0DisableTransferFailed(ep_t ep) { usb.DeviceEndpoint[ep].EPINTENCLR.bit.TRFAIL0 = 1; } + inline void epBank1DisableTransferFailed(ep_t ep) { usb.DeviceEndpoint[ep].EPINTENCLR.bit.TRFAIL1 = 1; } + inline void epBank0DisableTransferComplete(ep_t ep) { usb.DeviceEndpoint[ep].EPINTENCLR.bit.TRCPT0 = 1; } + inline void epBank1DisableTransferComplete(ep_t ep) { usb.DeviceEndpoint[ep].EPINTENCLR.bit.TRCPT1 = 1; } + + // Status + inline bool epBank0IsReady(ep_t ep) { return usb.DeviceEndpoint[ep].EPSTATUS.bit.BK0RDY; } + inline bool epBank1IsReady(ep_t ep) { return usb.DeviceEndpoint[ep].EPSTATUS.bit.BK1RDY; } + inline void epBank0SetReady(ep_t ep) { usb.DeviceEndpoint[ep].EPSTATUSSET.bit.BK0RDY = 1; } + inline void epBank1SetReady(ep_t ep) { usb.DeviceEndpoint[ep].EPSTATUSSET.bit.BK1RDY = 1; } + inline void epBank0ResetReady(ep_t ep) { usb.DeviceEndpoint[ep].EPSTATUSCLR.bit.BK0RDY = 1; } + inline void epBank1ResetReady(ep_t ep) { usb.DeviceEndpoint[ep].EPSTATUSCLR.bit.BK1RDY = 1; } + + inline void epBank0SetStallReq(ep_t ep) { usb.DeviceEndpoint[ep].EPSTATUSSET.bit.STALLRQ0 = 1; } + inline void epBank1SetStallReq(ep_t ep) { usb.DeviceEndpoint[ep].EPSTATUSSET.bit.STALLRQ1 = 1; } + inline void epBank0ResetStallReq(ep_t ep) { usb.DeviceEndpoint[ep].EPSTATUSCLR.bit.STALLRQ0 = 1; } + inline void epBank1ResetStallReq(ep_t ep) { usb.DeviceEndpoint[ep].EPSTATUSCLR.bit.STALLRQ1 = 1; } + + // Packet + inline uint16_t epBank0ByteCount(ep_t ep) { return EP[ep].DeviceDescBank[0].PCKSIZE.bit.BYTE_COUNT; } + inline uint16_t epBank1ByteCount(ep_t ep) { return EP[ep].DeviceDescBank[1].PCKSIZE.bit.BYTE_COUNT; } + inline void epBank0SetByteCount(ep_t ep, uint16_t bc) { EP[ep].DeviceDescBank[0].PCKSIZE.bit.BYTE_COUNT = bc; } + inline void epBank1SetByteCount(ep_t ep, uint16_t bc) { EP[ep].DeviceDescBank[1].PCKSIZE.bit.BYTE_COUNT = bc; } + inline void epBank0SetMultiPacketSize(ep_t ep, uint16_t s) { EP[ep].DeviceDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE = s; } + inline void epBank1SetMultiPacketSize(ep_t ep, uint16_t s) { EP[ep].DeviceDescBank[1].PCKSIZE.bit.MULTI_PACKET_SIZE = s; } + + inline void epBank0SetAddress(ep_t ep, void *addr) { EP[ep].DeviceDescBank[0].ADDR.reg = (uint32_t)addr; } + inline void epBank1SetAddress(ep_t ep, void *addr) { EP[ep].DeviceDescBank[1].ADDR.reg = (uint32_t)addr; } + inline void epBank0SetSize(ep_t ep, uint16_t size) { EP[ep].DeviceDescBank[0].PCKSIZE.bit.SIZE = EP_PCKSIZE_SIZE(size); } + inline void epBank1SetSize(ep_t ep, uint16_t size) { EP[ep].DeviceDescBank[1].PCKSIZE.bit.SIZE = EP_PCKSIZE_SIZE(size); } + inline uint8_t EP_PCKSIZE_SIZE(uint16_t size) { + switch (size) { + case 8: return 0; + case 16: return 1; + case 32: return 2; + case 64: return 3; + case 128: return 4; + case 256: return 5; + case 512: return 6; + case 1023: return 7; + default: return 0; + } + } + + inline void epBank0DisableAutoZLP(ep_t ep) { EP[ep].DeviceDescBank[0].PCKSIZE.bit.AUTO_ZLP = 0; } + inline void epBank1DisableAutoZLP(ep_t ep) { EP[ep].DeviceDescBank[1].PCKSIZE.bit.AUTO_ZLP = 0; } + inline void epBank0EnableAutoZLP(ep_t ep) { EP[ep].DeviceDescBank[0].PCKSIZE.bit.AUTO_ZLP = 1; } + inline void epBank1EnableAutoZLP(ep_t ep) { EP[ep].DeviceDescBank[1].PCKSIZE.bit.AUTO_ZLP = 1; } + + // USB Device Endpoint transactions helpers + // ---------------------------------------- + + inline void epReleaseOutBank0(ep_t ep, uint16_t s) { + epBank0SetMultiPacketSize(ep, s); + epBank0SetByteCount(ep, 0); + epBank0ResetReady(ep); + } + +private: + // USB Device registers + UsbDevice &usb; + + // Endpoints descriptors table + __attribute__((__aligned__(4))) UsbDeviceDescriptor EP[USB_EPT_NUM]; +}; + +void USBDevice_SAMD21G18x::reset() { + usb.CTRLA.bit.SWRST = 1; + memset(EP, 0, sizeof(EP)); + while (usb.SYNCBUSY.bit.SWRST) {} + usb.DESCADD.reg = (uint32_t)(&EP); +} + +void USBDevice_SAMD21G18x::calibrate() { + // Load Pad Calibration data from non-volatile memory + uint32_t *pad_transn_p = (uint32_t *) USB_FUSES_TRANSN_ADDR; + uint32_t *pad_transp_p = (uint32_t *) USB_FUSES_TRANSP_ADDR; + uint32_t *pad_trim_p = (uint32_t *) USB_FUSES_TRIM_ADDR; + + uint32_t pad_transn = (*pad_transn_p & USB_FUSES_TRANSN_Msk) >> USB_FUSES_TRANSN_Pos; + uint32_t pad_transp = (*pad_transp_p & USB_FUSES_TRANSP_Msk) >> USB_FUSES_TRANSP_Pos; + uint32_t pad_trim = (*pad_trim_p & USB_FUSES_TRIM_Msk ) >> USB_FUSES_TRIM_Pos; + + if (pad_transn == 0x1F) // maximum value (31) + pad_transn = 5; + if (pad_transp == 0x1F) // maximum value (31) + pad_transp = 29; + if (pad_trim == 0x7) // maximum value (7) + pad_trim = 3; + + usb.PADCAL.bit.TRANSN = pad_transn; + usb.PADCAL.bit.TRANSP = pad_transp; + usb.PADCAL.bit.TRIM = pad_trim; +} + +/* + * USB EP generic handlers. + */ + +class EPHandler { +public: + virtual void handleEndpoint() = 0; + virtual uint32_t recv(void *_data, uint32_t len) = 0; + virtual uint32_t available() = 0; + virtual int peek() = 0; +}; + +class DoubleBufferedEPOutHandler : public EPHandler { +public: + enum { size = 64 }; + + DoubleBufferedEPOutHandler(USBDevice_SAMD21G18x &usbDev, uint32_t endPoint) : + usbd(usbDev), + ep(endPoint), + current(0), incoming(0), + first0(0), last0(0), ready0(false), + first1(0), last1(0), ready1(false), + notify(false) + { + usbd.epBank0SetSize(ep, 64); + usbd.epBank0SetType(ep, 3); // BULK OUT + usbd.epBank0SetAddress(ep, const_cast(data0)); + usbd.epBank0EnableTransferComplete(ep); + + release(); + } + + virtual ~DoubleBufferedEPOutHandler() { + } + + uint32_t _recv() + { + uint32_t i = 0; + uint32_t len = 0; + + synchronized { + len = _rx_buffer.availableForStore(); + } + + // R/W: current, first0/1, ready0/1, notify + // R : last0/1, data0/1 + if (current == 0) { + synchronized { + if (!ready0) { + return 0; + } + } + // when ready0==true the buffer is not being filled and last0 is constant + for (; i(_data); + synchronized { + for (; i < len && _rx_buffer.available(); i++) { + data[i] = _rx_buffer.read_char(); + } + } + return i; + } + + virtual uint32_t _available() const { + if (current == 0) { + bool ready = ready0; + synchronized { + ready = ready0; + } + return ready ? (last0 - first0) : 0; + } else { + bool ready = false; + synchronized { + ready = ready1; + } + return ready ? (last1 - first1) : 0; + } + } + + virtual void handleEndpoint() + { + // R/W : incoming, ready0/1 + // W : last0/1, notify + if (usbd.epBank0IsTransferComplete(ep)) + { + uint32_t received = usbd.epBank0ByteCount(ep); + if (received == 0) { + release(); + } else if (incoming == 0) { + // Update counters and swap banks for non-ZLP's + last0 = received; + incoming = 1; + usbd.epBank0SetAddress(ep, const_cast(data1)); + synchronized { + ready0 = true; + notify = ready1; + if (!notify) { + release(); + } + } + } else { + last1 = received; + incoming = 0; + usbd.epBank0SetAddress(ep, const_cast(data0)); + synchronized { + ready1 = true; + notify = ready0; + if (!notify) { + release(); + } + } + } + usbd.epAckPendingInterrupts(ep); + } + } + + // Returns how many bytes are stored in the buffers + virtual uint32_t available() { + _recv(); + return _rx_buffer.available(); + } + + virtual int peek() { + _recv(); + return _rx_buffer.peek(); + } + + void release() { + usbd.epReleaseOutBank0(ep, size); + } + +private: + USBDevice_SAMD21G18x &usbd; + + arduino::RingBuffer _rx_buffer; + + const uint32_t ep; + volatile uint32_t current, incoming; + + __attribute__((__aligned__(4))) volatile uint8_t data0[size]; + uint32_t first0; + volatile uint32_t last0; + volatile bool ready0; + + __attribute__((__aligned__(4))) volatile uint8_t data1[size]; + uint32_t first1; + volatile uint32_t last1; + volatile bool ready1; + + volatile bool notify; +}; + diff --git a/cores/arduino/USB/USBAPI.h b/cores/arduino/USB/USBAPI.h new file mode 100644 index 0000000..b06b5e5 --- /dev/null +++ b/cores/arduino/USB/USBAPI.h @@ -0,0 +1,182 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#pragma once + +#define HSTPIPCFG_PTYPE_BLK 1 +#define HSTPIPCFG_PTOKEN_IN 2 +#define HSTPIPCFG_PTOKEN_OUT 3 +#define HSTPIPCFG_PBK_1_BANK 4 +#define HSTPIPCFG_PTYPE_INTRPT 5 + +#define EP0 0 +#define EPX_SIZE 64 // 64 for Full Speed, EPT size max is 1024 + +#if defined __cplusplus + +#include "Arduino.h" +#include "api/Stream.h" +#include "api/RingBuffer.h" +#include "api/HardwareSerial.h" +#include "api/USBAPI.h" +#include "CDC.h" + +//================================================================================ +// USB + +class USBDeviceClass { +public: + USBDeviceClass() {}; + + // USB Device API + void init(); + bool end(); + bool attach(); + bool detach(); + void setAddress(uint32_t addr); + + bool configured(); + bool connected(); + + void standby(); + + // Setup API + bool handleClassInterfaceSetup(arduino::USBSetup &setup); + bool handleStandardSetup(arduino::USBSetup &setup); + bool sendDescriptor(arduino::USBSetup &setup); + + // Control EndPoint API + uint32_t sendControl(const void *data, uint32_t len); + uint32_t sendControl(int /* ep */, const void *data, uint32_t len) { return sendControl(data, len); } + uint32_t recvControl(void *data, uint32_t len); + uint32_t sendConfiguration(uint32_t maxlen); + bool sendStringDescriptor(const uint8_t *string, uint32_t maxlen); + void initControl(int end); + uint8_t SendInterfaces(uint32_t* total); + void packMessages(bool val); + + // Generic EndPoint API + void initEndpoints(void); + void initEP(uint32_t ep, uint32_t type); + + uint32_t send(uint32_t ep, const void *data, uint32_t len); + void sendZlp(uint32_t ep); + uint32_t recv(uint32_t ep, void *data, uint32_t len); + int recv(uint32_t ep); + uint32_t available(uint32_t ep); + void flush(uint32_t ep); + void clear(uint32_t ep); + void stall(uint32_t ep); + + // private? + uint32_t armSend(uint32_t ep, const void *data, uint32_t len); + uint8_t armRecvCtrlOUT(uint32_t ep); + + void ISRHandler(); + +private: + bool initialized; +}; +extern USBDeviceClass USBDevice; + +//================================================================================ +// Serial over CDC (Serial1 is the physical port) + +class Serial_ : public arduino::HardwareSerial, arduino::PluggableUSBModule +{ +public: + Serial_(USBDeviceClass &_usb); + void begin(unsigned long baudrate); + void begin(unsigned long baudrate, uint16_t config); + void end(void); + + virtual int available(void); + virtual int availableForWrite(void); + virtual int peek(void); + virtual int read(void); + virtual void flush(void); + virtual void clear(void); + virtual size_t write(uint8_t); + virtual size_t write(const uint8_t *buffer, size_t size); + using Print::write; // pull in write(str) from Print + operator bool(); + + size_t readBytes(char *buffer, size_t length); + size_t readBytes( uint8_t *buffer, size_t length) { return readBytes((char *)buffer, length); } + + // This method allows processing "SEND_BREAK" requests sent by + // the USB host. Those requests indicate that the host wants to + // send a BREAK signal and are accompanied by a single uint16_t + // value, specifying the duration of the break. The value 0 + // means to end any current break, while the value 0xffff means + // to start an indefinite break. + // readBreak() will return the value of the most recent break + // request, but will return it at most once, returning -1 when + // readBreak() is called again (until another break request is + // received, which is again returned once). + // This also mean that if two break requests are received + // without readBreak() being called in between, the value of the + // first request is lost. + // Note that the value returned is a long, so it can return + // 0-0xffff as well as -1. + int32_t readBreak(); + + // These return the settings specified by the USB host for the + // serial port. These aren't really used, but are offered here + // in case a sketch wants to act on these settings. + uint32_t baud(); + uint8_t stopbits(); + uint8_t paritytype(); + uint8_t numbits(); + bool dtr(); + bool rts(); + enum { + ONE_STOP_BIT = 0, + ONE_AND_HALF_STOP_BIT = 1, + TWO_STOP_BITS = 2, + }; + enum { + NO_PARITY = 0, + ODD_PARITY = 1, + EVEN_PARITY = 2, + MARK_PARITY = 3, + SPACE_PARITY = 4, + }; + +protected: + // Implementation of the PUSBListNode + int getInterface(uint8_t* interfaceNum); + int getDescriptor(arduino::USBSetup& setup); + bool setup(arduino::USBSetup& setup); + uint8_t getShortName(char* name); + void handleEndpoint(int ep); + void enableInterrupt(); + +friend USBDeviceClass; + +private: + int availableForStore(void); + + USBDeviceClass &usb; + bool stalled; + unsigned int epType[3]; + +}; +extern Serial_ SerialUSB; + +#endif // __cplusplus diff --git a/cores/arduino/USB/USBCore.cpp b/cores/arduino/USB/USBCore.cpp new file mode 100644 index 0000000..5f22739 --- /dev/null +++ b/cores/arduino/USB/USBCore.cpp @@ -0,0 +1,941 @@ +/* + Copyright (c) 2016 Arduino LLC. 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 +*/ + +#if defined(USBCON) + +#include + +#include "api/USBAPI.h" +#include "USBAPI.h" +#include "SAMD21_USBDevice.h" +#include "CDC.h" +#include "api/PluggableUSB.h" + +#include +#include +#include +#include + +using namespace arduino; + +/* + * USB Device instance + * ------------------- + */ + +USBDevice_SAMD21G18x usbd; +USBDeviceClass USBDevice; + +/** Pulse generation counters to keep track of the number of milliseconds remaining for each pulse type */ +#define TX_RX_LED_PULSE_MS 100 +#ifdef PIN_LED_TXL +static volatile uint8_t txLEDPulse; /**< Milliseconds remaining for data Tx LED pulse */ +#endif +#ifdef PIN_LED_RXL +static volatile uint8_t rxLEDPulse; /**< Milliseconds remaining for data Rx LED pulse */ +#endif +static char isRemoteWakeUpEnabled = 0; +static char isEndpointHalt = 0; + +extern void (*gpf_isr)(void); + +// USB_Handler ISR +extern "C" void UDD_Handler(void) { + USBDevice.ISRHandler(); +} + +const uint16_t STRING_LANGUAGE[2] = { + (3<<8) | (2+2), + 0x0409 // English +}; + +#ifndef USB_PRODUCT +// If no product is provided, use USB IO Board +#define USB_PRODUCT "USB IO Board" +#endif + +const uint8_t STRING_PRODUCT[] = USB_PRODUCT; + +#if USB_VID == 0x2341 +# if defined(USB_MANUFACTURER) +# undef USB_MANUFACTURER +# endif +# define USB_MANUFACTURER "Arduino LLC" +#elif !defined(USB_MANUFACTURER) +// Fall through to unknown if no manufacturer name was provided in a macro +# define USB_MANUFACTURER "Unknown" +#endif + +const uint8_t STRING_MANUFACTURER[] = USB_MANUFACTURER; + + +// DEVICE DESCRIPTOR +const DeviceDescriptor USB_DeviceDescriptorB = D_DEVICE(0xEF, 0x02, 0x01, 64, USB_VID, USB_PID, 0x100, IMANUFACTURER, IPRODUCT, ISERIAL, 1); +const DeviceDescriptor USB_DeviceDescriptor = D_DEVICE(0x00, 0x00, 0x00, 64, USB_VID, USB_PID, 0x100, IMANUFACTURER, IPRODUCT, ISERIAL, 1); + +//================================================================== + +volatile uint32_t _usbConfiguration = 0; +volatile uint32_t _usbSetInterface = 0; + +static __attribute__((__aligned__(4))) //__attribute__((__section__(".bss_hram0"))) +uint8_t udd_ep_out_cache_buffer[7][64]; + +static __attribute__((__aligned__(4))) //__attribute__((__section__(".bss_hram0"))) +uint8_t udd_ep_in_cache_buffer[7][64]; + +// Some EP are handled using EPHanlders. +// Possibly all the sparse EP handling subroutines will be +// converted into reusable EPHandlers in the future. +static EPHandler *epHandlers[7] = {NULL, NULL, NULL, NULL, NULL, NULL, NULL}; + +//================================================================== + +// Send a USB descriptor string. The string is stored as a +// plain ASCII string but is sent out as UTF-16 with the +// correct 2-byte prefix +bool USBDeviceClass::sendStringDescriptor(const uint8_t *string, uint32_t maxlen) +{ + if (maxlen < 2) + return false; + + uint8_t* buffer = (uint8_t*)malloc(maxlen); + buffer[0] = strlen((const char*)string) * 2 + 2; + buffer[1] = 0x03; + + uint8_t i; + for (i = 2; i < maxlen && *string; i++) { + buffer[i++] = *string++; + if (i == maxlen) break; + buffer[i] = 0; + } + + bool ret = USBDevice.sendControl(buffer, i); + free(buffer); + return ret; +} + +bool _dry_run = false; +bool _pack_message = false; +uint16_t _pack_size = 0; +uint8_t _pack_buffer[256]; + +void USBDeviceClass::packMessages(bool val) +{ + if (val) { + _pack_message = true; + _pack_size = 0; + } else { + _pack_message = false; + sendControl(_pack_buffer, _pack_size); + } +} + +uint8_t USBDeviceClass::SendInterfaces(uint32_t* total) +{ + uint8_t interfaces = 0; + +#ifdef PLUGGABLE_USB_ENABLED + total[0] += PluggableUSB().getInterface(&interfaces); +#endif + + return interfaces; +} + +// Construct a dynamic configuration descriptor +// This really needs dynamic endpoint allocation etc +uint32_t USBDeviceClass::sendConfiguration(uint32_t maxlen) +{ + uint32_t total = 0; + // Count and measure interfaces + _dry_run = true; + uint8_t interfaces = SendInterfaces(&total); + + ConfigDescriptor config = D_CONFIG((uint16_t)(total + sizeof(ConfigDescriptor)), interfaces); + + // Now send them + _dry_run = false; + + if (maxlen == sizeof(ConfigDescriptor)) { + sendControl(&config, sizeof(ConfigDescriptor)); + return true; + } + + total = 0; + + packMessages(true); + sendControl(&config, sizeof(ConfigDescriptor)); + SendInterfaces(&total); + packMessages(false); + + return true; +} + +bool USBDeviceClass::sendDescriptor(USBSetup &setup) +{ + uint8_t t = setup.wValueH; + uint8_t desc_length = 0; + bool _cdcComposite; + int ret; + const uint8_t *desc_addr = 0; + + if (t == USB_CONFIGURATION_DESCRIPTOR_TYPE) + { + return USBDevice.sendConfiguration(setup.wLength); + } + +#ifdef PLUGGABLE_USB_ENABLED + ret = PluggableUSB().getDescriptor(setup); + if (ret != 0) { + return (ret > 0 ? true : false); + } +#endif + + if (t == USB_DEVICE_DESCRIPTOR_TYPE) + { + if (setup.wLength == 8) + _cdcComposite = 1; + + desc_addr = _cdcComposite ? (const uint8_t*)&USB_DeviceDescriptorB : (const uint8_t*)&USB_DeviceDescriptor; + + if (*desc_addr > setup.wLength) { + desc_length = setup.wLength; + } + } + else if (USB_STRING_DESCRIPTOR_TYPE == t) + { + if (setup.wValueL == 0) { + desc_addr = (const uint8_t*)&STRING_LANGUAGE; + } + else if (setup.wValueL == IPRODUCT) { + return sendStringDescriptor(STRING_PRODUCT, setup.wLength); + } + else if (setup.wValueL == IMANUFACTURER) { + return sendStringDescriptor(STRING_MANUFACTURER, setup.wLength); + } + else if (setup.wValueL == ISERIAL) { + char name[ISERIAL_MAX_LEN]; + memset(name, 0, sizeof(name)); +#ifdef PLUGGABLE_USB_ENABLED + PluggableUSB().getShortName(name); + return sendStringDescriptor((uint8_t*)name, setup.wLength); +#endif + } + else { + return false; + } + if (*desc_addr > setup.wLength) { + desc_length = setup.wLength; + } + } + else + { + } + + if (desc_addr == 0) { + return false; + } + + if (desc_length == 0) { + desc_length = *desc_addr; + } + + sendControl(desc_addr, desc_length); + + return true; +} + +void USBDeviceClass::standby() { + usbd.noRunInStandby(); +} + +void USBDeviceClass::init() +{ +#ifdef PIN_LED_TXL + txLEDPulse = 0; + pinMode(PIN_LED_TXL, OUTPUT); + digitalWrite(PIN_LED_TXL, HIGH); +#endif + +#ifdef PIN_LED_RXL + rxLEDPulse = 0; + pinMode(PIN_LED_RXL, OUTPUT); + digitalWrite(PIN_LED_RXL, HIGH); +#endif + + // Enable USB clock + PM->APBBMASK.reg |= PM_APBBMASK_USB; + + // Set up the USB DP/DN pins + PORT->Group[0].PINCFG[PIN_PA24G_USB_DM].bit.PMUXEN = 1; + PORT->Group[0].PMUX[PIN_PA24G_USB_DM/2].reg &= ~(0xF << (4 * (PIN_PA24G_USB_DM & 0x01u))); + PORT->Group[0].PMUX[PIN_PA24G_USB_DM/2].reg |= MUX_PA24G_USB_DM << (4 * (PIN_PA24G_USB_DM & 0x01u)); + PORT->Group[0].PINCFG[PIN_PA25G_USB_DP].bit.PMUXEN = 1; + PORT->Group[0].PMUX[PIN_PA25G_USB_DP/2].reg &= ~(0xF << (4 * (PIN_PA25G_USB_DP & 0x01u))); + PORT->Group[0].PMUX[PIN_PA25G_USB_DP/2].reg |= MUX_PA25G_USB_DP << (4 * (PIN_PA25G_USB_DP & 0x01u)); + + // Put Generic Clock Generator 0 as source for Generic Clock Multiplexer 6 (USB reference) + GCLK->CLKCTRL.reg = GCLK_CLKCTRL_ID(6) | // Generic Clock Multiplexer 6 + GCLK_CLKCTRL_GEN_GCLK0 | // Generic Clock Generator 0 is source + GCLK_CLKCTRL_CLKEN; + while (GCLK->STATUS.bit.SYNCBUSY) + ; + + USB_SetHandler(&UDD_Handler); + + // Reset USB Device + usbd.reset(); + + usbd.calibrate(); + usbd.setDataSensitiveQoS(); + usbd.setConfigSensitiveQoS(); + usbd.setUSBDeviceMode(); + usbd.runInStandby(); + usbd.setFullSpeed(); + + // Configure interrupts + NVIC_SetPriority((IRQn_Type) USB_IRQn, 0UL); + NVIC_EnableIRQ((IRQn_Type) USB_IRQn); + + usbd.enable(); + + initialized = true; + +#ifdef CDC_ENABLED + SerialUSB.begin(0); +#endif +} + +bool USBDeviceClass::attach() +{ + if (!initialized) + return false; + + usbd.attach(); + usbd.enableEndOfResetInterrupt(); + usbd.enableStartOfFrameInterrupt(); + + _usbConfiguration = 0; + return true; +} + +void USBDeviceClass::setAddress(uint32_t addr) +{ + usbd.epBank1SetByteCount(0, 0); + usbd.epBank1AckTransferComplete(0); + + // RAM buffer is full, we can send data (IN) + usbd.epBank1SetReady(0); + + // Wait for transfer to complete + while (!usbd.epBank1IsTransferComplete(0)) {} + + // Set USB address to addr + USB->DEVICE.DADD.bit.DADD = addr; // Address + USB->DEVICE.DADD.bit.ADDEN = 1; // Enable +} + +bool USBDeviceClass::detach() +{ + if (!initialized) + return false; + usbd.detach(); + return true; +} + +bool USBDeviceClass::end() { + if (!initialized) + return false; + usbd.disable(); + return true; +} + +bool USBDeviceClass::configured() +{ + return _usbConfiguration != 0; +} + +bool USBDeviceClass::handleClassInterfaceSetup(USBSetup& setup) +{ +#if defined(PLUGGABLE_USB_ENABLED) + bool ret = PluggableUSB().setup(setup); + if ( ret == false) { + sendZlp(0); + } + return ret; +#endif + + return false; +} + +uint32_t EndPoints[] = +{ + USB_ENDPOINT_TYPE_CONTROL, + +#ifdef PLUGGABLE_USB_ENABLED + //allocate 9 endpoints and remove const so they can be changed by the user + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, +#endif +}; +#define EP_ARRAY_SIZE (sizeof(EndPoints)/sizeof(EndPoints[0])) + +void USBDeviceClass::initEndpoints() { + for (uint8_t i = 1; (i < EP_ARRAY_SIZE) && (EndPoints[i] != 0); i++) { + initEP(i, EndPoints[i]); + } +} + +void USBDeviceClass::initEP(uint32_t ep, uint32_t config) +{ + if (config == (USB_ENDPOINT_TYPE_INTERRUPT | USB_ENDPOINT_IN(0))) + { + usbd.epBank1SetSize(ep, 64); + usbd.epBank1SetAddress(ep, &udd_ep_in_cache_buffer[ep]); + usbd.epBank1SetType(ep, 4); // INTERRUPT IN + } + else if (config == (USB_ENDPOINT_TYPE_BULK | USB_ENDPOINT_OUT(0))) + { + if (epHandlers[ep] != NULL) { + delete (DoubleBufferedEPOutHandler*)epHandlers[ep]; + } + epHandlers[ep] = new DoubleBufferedEPOutHandler(usbd, ep); + } + else if (config == (USB_ENDPOINT_TYPE_BULK | USB_ENDPOINT_IN(0))) + { + usbd.epBank1SetSize(ep, 64); + usbd.epBank1SetAddress(ep, &udd_ep_in_cache_buffer[ep]); + usbd.epBank1SetType(ep, 3); // BULK IN + } + else if (config == USB_ENDPOINT_TYPE_CONTROL) + { + // Setup Control OUT + usbd.epBank0SetSize(ep, 64); + usbd.epBank0SetAddress(ep, &udd_ep_out_cache_buffer[ep]); + usbd.epBank0SetType(ep, 1); // CONTROL OUT / SETUP + + // Setup Control IN + usbd.epBank1SetSize(ep, 64); + usbd.epBank1SetAddress(ep, &udd_ep_in_cache_buffer[ep]); + usbd.epBank1SetType(ep, 1); // CONTROL IN + + // Release OUT EP + usbd.epReleaseOutBank0(ep, 64); + } +} + +void USBDeviceClass::flush(uint32_t ep) +{ + if (available(ep)) { + // RAM buffer is full, we can send data (IN) + usbd.epBank1SetReady(ep); + + // Clear the transfer complete flag + usbd.epBank1AckTransferComplete(ep); + } +} + +void USBDeviceClass::clear(uint32_t ep) { + usbd.epBank1SetAddress(ep, &udd_ep_in_cache_buffer[ep]); + usbd.epBank1SetByteCount(ep, 0); + + // Clear the transfer complete flag + usbd.epBank1AckTransferComplete(ep); + + // RAM buffer is full, we can send data (IN) + usbd.epBank1SetReady(ep); +} + +void USBDeviceClass::stall(uint32_t ep) +{ + // TODO: test + // TODO: use .bit. notation + + // Stall endpoint + USB->DEVICE.DeviceEndpoint[ep].EPSTATUSSET.reg = USB_DEVICE_EPSTATUSSET_STALLRQ(2); +} + +bool USBDeviceClass::connected() +{ + // Count frame numbers + uint16_t f = USB->DEVICE.FNUM.bit.FNUM; + delay(1); // wait for next SOF + return f != USB->DEVICE.FNUM.bit.FNUM; +} + + +uint32_t USBDeviceClass::recvControl(void *_data, uint32_t len) +{ + uint8_t *data = reinterpret_cast(_data); + + //usbd.epBank0AckSetupReceived(0); + uint32_t read = armRecvCtrlOUT(0); + if (read > len) + read = len; + //while (!usbd.epBank0AckTransferComplete(0)) {} + uint8_t *buffer = udd_ep_out_cache_buffer[0]; + for (uint32_t i=0; iavailable(); + } else { + return usbd.epBank0ByteCount(ep); + } +} + +// Non Blocking receive +// Return number of bytes read +uint32_t USBDeviceClass::recv(uint32_t ep, void *_data, uint32_t len) +{ + if (!_usbConfiguration) + return -1; + +#ifdef PIN_LED_RXL + if (rxLEDPulse == 0) + digitalWrite(PIN_LED_RXL, LOW); + + rxLEDPulse = TX_RX_LED_PULSE_MS; +#endif + + if (epHandlers[ep]) { + return epHandlers[ep]->recv(_data, len); + } + + if (available(ep) < len) + len = available(ep); + + usbd.epBank0SetByteCount(ep, 0); + usbd.epBank0DisableTransferComplete(ep); + + memcpy(_data, udd_ep_out_cache_buffer[ep], len); + + // release empty buffer + if (len && !available(ep)) { + // The RAM Buffer is empty: we can receive data + usbd.epBank0ResetReady(ep); + + // Clear Transfer complete 0 flag + usbd.epBank0AckTransferComplete(ep); + + // Enable Transfer complete 0 interrupt + usbd.epBank0EnableTransferComplete(ep); + } + + return len; +} + +// Recv 1 byte if ready +int USBDeviceClass::recv(uint32_t ep) +{ + uint8_t c; + if (recv(ep, &c, 1) != 1) { + return -1; + } else { + return c; + } +} + +uint8_t USBDeviceClass::armRecvCtrlOUT(uint32_t ep) +{ + // Get endpoint configuration from setting register + usbd.epBank0SetAddress(ep, &udd_ep_out_cache_buffer[ep]); + /* Atmel-42181G–SAM-D21_Datasheet–09/2015 / Page 806 + * + * For OUT endpoints, MULTI_PACKET_SIZE holds the total + * data size for the complete transfer. This value must + * be a multiple of the maximum packet size. + * + * Since SIZE is 64 (see 'USBDeviceClass::initEP') for + * all endpoints MULTI_PACKET_SIZE should not be set to + * a value < SIZE, this means at least to 64. + */ + usbd.epBank0SetMultiPacketSize(ep, 64); + usbd.epBank0SetByteCount(ep, 0); + + usbd.epBank0ResetReady(ep); + + // Wait OUT + while (!usbd.epBank0IsReady(ep)) {} + while (!usbd.epBank0IsTransferComplete(ep)) {} + return usbd.epBank0ByteCount(ep); +} + +// Timeout for sends +#define TX_TIMEOUT_MS 70 + +static char LastTransmitTimedOut[7] = { + 0, + 0, + 0, + 0, + 0, + 0, + 0 +}; + +// Blocking Send of data to an endpoint +uint32_t USBDeviceClass::send(uint32_t ep, const void *data, uint32_t len) +{ + uint32_t written = 0; + uint32_t length = 0; + + if (!_usbConfiguration) + return -1; + if (len > 16384) + return -1; + +#ifdef PIN_LED_TXL + if (txLEDPulse == 0) + digitalWrite(PIN_LED_TXL, LOW); + + txLEDPulse = TX_RX_LED_PULSE_MS; +#endif + + // Flash area + while (len != 0) + { + if (usbd.epBank1IsReady(ep)) { + // previous transfer is still not complete + + // convert the timeout from microseconds to a number of times through + // the wait loop; it takes (roughly) 23 clock cycles per iteration. + uint32_t timeout = microsecondsToClockCycles(TX_TIMEOUT_MS * 1000) / 23; + + // Wait for (previous) transfer to complete + // inspired by Paul Stoffregen's work on Teensy + while (!usbd.epBank1IsTransferComplete(ep)) { + if (LastTransmitTimedOut[ep] || timeout-- == 0) { + LastTransmitTimedOut[ep] = 1; + + // set byte count to zero, so that ZLP is sent + // instead of stale data + usbd.epBank1SetByteCount(ep, 0); + return -1; + } + } + } + + LastTransmitTimedOut[ep] = 0; + + if (len >= EPX_SIZE) { + usbd.epBank1EnableAutoZLP(ep); + length = EPX_SIZE; + } else { + length = len; + } + + /* memcopy could be safer in multi threaded environment */ + memcpy(&udd_ep_in_cache_buffer[ep], data, length); + + usbd.epBank1SetAddress(ep, &udd_ep_in_cache_buffer[ep]); + usbd.epBank1SetByteCount(ep, length); + + // Clear the transfer complete flag + usbd.epBank1AckTransferComplete(ep); + + // RAM buffer is full, we can send data (IN) + usbd.epBank1SetReady(ep); + + written += length; + len -= length; + data = (char *)data + length; + } + return written; +} + +uint32_t USBDeviceClass::armSend(uint32_t ep, const void* data, uint32_t len) +{ + memcpy(&udd_ep_in_cache_buffer[ep], data, len); + + // Get endpoint configuration from setting register + usbd.epBank1SetAddress(ep, &udd_ep_in_cache_buffer[ep]); + usbd.epBank1SetMultiPacketSize(ep, 0); + usbd.epBank1SetByteCount(ep, len); + + return len; +} + +uint32_t USBDeviceClass::sendControl(const void* _data, uint32_t len) +{ + const uint8_t *data = reinterpret_cast(_data); + uint32_t length = len; + uint32_t sent = 0; + uint32_t pos = 0; + + if (_dry_run == true) + return length; + + if (_pack_message == true) { + memcpy(&_pack_buffer[_pack_size], data, len); + _pack_size += len; + return length; + } + + while (len > 0) + { + sent = armSend(EP0, data + pos, len); + pos += sent; + len -= sent; + } + + return length; +} + +void USBDeviceClass::sendZlp(uint32_t ep) +{ + // Set the byte count as zero + usbd.epBank1SetByteCount(ep, 0); +} + +bool USBDeviceClass::handleStandardSetup(USBSetup &setup) +{ + switch (setup.bRequest) { + case GET_STATUS: + if (setup.bmRequestType == 0) // device + { + // Send the device status + // TODO: Check current configuration for power mode (if device is configured) + // TODO: Check if remote wake-up is enabled + uint8_t buff[] = { 0, 0 }; + armSend(0, buff, 2); + return true; + } + // if( setup.bmRequestType == 2 ) // Endpoint: + else + { + // Send the endpoint status + // Check if the endpoint if currently halted + uint8_t buff[] = { 0, 0 }; + if (isEndpointHalt == 1) + buff[0] = 1; + armSend(0, buff, 2); + return true; + } + + case CLEAR_FEATURE: + // Check which is the selected feature + if (setup.wValueL == 1) // DEVICEREMOTEWAKEUP + { + // Enable remote wake-up and send a ZLP + uint8_t buff[] = { 0, 0 }; + if (isRemoteWakeUpEnabled == 1) + buff[0] = 1; + armSend(0, buff, 2); + return true; + } + else // if( setup.wValueL == 0) // ENDPOINTHALT + { + isEndpointHalt = 0; + sendZlp(0); + return true; + } + + case SET_FEATURE: + // Check which is the selected feature + if (setup.wValueL == 1) // DEVICEREMOTEWAKEUP + { + // Enable remote wake-up and send a ZLP + isRemoteWakeUpEnabled = 1; + uint8_t buff[] = { 0 }; + armSend(0, buff, 1); + return true; + } + if (setup.wValueL == 0) // ENDPOINTHALT + { + // Halt endpoint + isEndpointHalt = 1; + sendZlp(0); + return true; + } + break; + + case SET_ADDRESS: + setAddress(setup.wValueL); + return true; + + case GET_DESCRIPTOR: + return sendDescriptor(setup); + + case SET_DESCRIPTOR: + return false; + + case GET_CONFIGURATION: + armSend(0, (void*)&_usbConfiguration, 1); + return true; + + case SET_CONFIGURATION: + if (REQUEST_DEVICE == (setup.bmRequestType & REQUEST_RECIPIENT)) { + + initEndpoints(); + _usbConfiguration = setup.wValueL; + + #ifdef CDC_ENABLED + SerialUSB.enableInterrupt(); + #endif + + sendZlp(0); + return true; + } else { + return false; + } + + case GET_INTERFACE: + armSend(0, (void*)&_usbSetInterface, 1); + return true; + + case SET_INTERFACE: + _usbSetInterface = setup.wValueL; + sendZlp(0); + return true; + + default: + return true; + } + return true; +} + +void USBDeviceClass::ISRHandler() +{ + if (_pack_message == true) { + return; + } + + // End-Of-Reset + if (usbd.isEndOfResetInterrupt()) + { + usbd.ackEndOfResetInterrupt(); + + // Configure EP 0 + initEP(0, USB_ENDPOINT_TYPE_CONTROL); + + // Enable Setup-Received interrupt + usbd.epBank0EnableSetupReceived(0); + + _usbConfiguration = 0; + } + + // Start-Of-Frame + if (usbd.isStartOfFrameInterrupt()) + { + usbd.ackStartOfFrameInterrupt(); + + // check whether the one-shot period has elapsed. if so, turn off the LED +#ifdef PIN_LED_TXL + if (txLEDPulse > 0) { + txLEDPulse--; + if (txLEDPulse == 0) + digitalWrite(PIN_LED_TXL, HIGH); + } +#endif + +#ifdef PIN_LED_RXL + if (rxLEDPulse > 0) { + rxLEDPulse--; + if (rxLEDPulse == 0) + digitalWrite(PIN_LED_RXL, HIGH); + } +#endif + } + + /* Remove any stall requests for endpoint #0 */ + if (usbd.epBank0IsStalled(0)) { usbd.epBank0DisableStalled(0); } + + // Endpoint 0 Received Setup interrupt + if (usbd.epBank0IsSetupReceived(0)) + { + /* Retrieve received endpoint #0 data from buffer */ + USBSetup setup; + memcpy(&setup, udd_ep_out_cache_buffer[0], sizeof(USBSetup)); + + /* Tell the USB hardware that we are ready to receive more data for endpoint #0 and also reset the byte count + * for endpoint #0 - the clearing seems to be necessary for the code to function correctly, although the datasheet + * is not clear on the subject. + * + * Atmel-42181G–SAM-D21_Datasheet–09/2015 / Page 806 + * For IN endpoints, BYTE_COUNT holds the number of bytes to be sent in the next IN transaction. + * For OUT endpoint or SETUP endpoints, BYTE_COUNT holds the number of bytes received upon the last OUT or SETUP transaction. + */ + usbd.epBank0SetByteCount(0, 0); + usbd.epBank0ResetReady(0); + + bool ok; + if (REQUEST_STANDARD == (setup.bmRequestType & REQUEST_TYPE)) { + // Standard Requests + ok = handleStandardSetup(setup); + } else { + // Class Interface Requests + ok = handleClassInterfaceSetup(setup); + } + + if (ok) { + usbd.epBank1SetReady(0); + } else { + stall(0); + } + + if (usbd.epBank1IsStalled(0)) + { + // Remove stall request + usbd.epBank1DisableStalled(0); + } + } // end Received Setup handler + usbd.epAckPendingInterrupts(0); + + for (int ep = 1; ep < USB_EPT_NUM; ep++) { + // Endpoint Transfer Complete (0/1) Interrupt + if (usbd.epHasPendingInterrupts(ep)) { + if (epHandlers[ep]) { + epHandlers[ep]->handleEndpoint(); + } else { + #if defined(PLUGGABLE_USB_ENABLED) + SerialUSB.handleEndpoint(ep); + usbd.epAckPendingInterrupts(ep); + #endif + } + } + } +} + +// PluggableUSB contructor +PluggableUSB_::PluggableUSB_() : lastIf(0), + lastEp(1), + rootNode(NULL), totalEP(USB_ENDPOINTS) +{ + // Empty +} + +void* epBuffer(unsigned int lastEp) { + return &(EndPoints[lastEp]); +} + +#endif diff --git a/cores/arduino/USB/USBCore.h b/cores/arduino/USB/USBCore.h new file mode 100644 index 0000000..8018ae3 --- /dev/null +++ b/cores/arduino/USB/USBCore.h @@ -0,0 +1,218 @@ +/* + Copyright (c) 2014 Arduino LLC. 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 __USBCORE_H__ +#define __USBCORE_H__ + +// Standard requests +#define GET_STATUS 0 +#define CLEAR_FEATURE 1 +#define SET_FEATURE 3 +#define SET_ADDRESS 5 +#define GET_DESCRIPTOR 6 +#define SET_DESCRIPTOR 7 +#define GET_CONFIGURATION 8 +#define SET_CONFIGURATION 9 +#define GET_INTERFACE 10 +#define SET_INTERFACE 11 + +// bEndpointAddress in Endpoint Descriptor +#define USB_ENDPOINT_DIRECTION_MASK 0x80 +#define USB_ENDPOINT_OUT(addr) uint8_t((addr) | 0x00) +#define USB_ENDPOINT_IN(addr) uint8_t((addr) | 0x80) + +#define USB_ENDPOINTS 7 + +#define USB_ENDPOINT_TYPE_MASK 0x03 +#define USB_ENDPOINT_TYPE_CONTROL 0x00 +#define USB_ENDPOINT_TYPE_ISOCHRONOUS 0x01 +#define USB_ENDPOINT_TYPE_BULK 0x02 +#define USB_ENDPOINT_TYPE_INTERRUPT 0x03 + +// bmRequestType +#define REQUEST_HOSTTODEVICE 0x00 +#define REQUEST_DEVICETOHOST 0x80 +#define REQUEST_DIRECTION 0x80 + +#define REQUEST_STANDARD 0x00 +#define REQUEST_CLASS 0x20 +#define REQUEST_VENDOR 0x40 +#define REQUEST_TYPE 0x60 + +#define REQUEST_DEVICE 0x00 +#define REQUEST_INTERFACE 0x01 +#define REQUEST_ENDPOINT 0x02 +#define REQUEST_OTHER 0x03 +#define REQUEST_RECIPIENT 0x1F + +#define REQUEST_DEVICETOHOST_CLASS_INTERFACE (REQUEST_DEVICETOHOST | REQUEST_CLASS | REQUEST_INTERFACE) +#define REQUEST_HOSTTODEVICE_CLASS_INTERFACE (REQUEST_HOSTTODEVICE | REQUEST_CLASS | REQUEST_INTERFACE) +#define REQUEST_DEVICETOHOST_STANDARD_INTERFACE (REQUEST_DEVICETOHOST | REQUEST_STANDARD | REQUEST_INTERFACE) +// Class requests + +#define CDC_SET_LINE_CODING 0x20 +#define CDC_GET_LINE_CODING 0x21 +#define CDC_SET_CONTROL_LINE_STATE 0x22 +#define CDC_SEND_BREAK 0x23 + +#define MSC_RESET 0xFF +#define MSC_GET_MAX_LUN 0xFE + +// Descriptors + +// #define USB_DEVICE_DESC_SIZE 18 +// #define USB_CONFIGUARTION_DESC_SIZE 9 +// #define USB_INTERFACE_DESC_SIZE 9 +// #define USB_ENDPOINT_DESC_SIZE 7 + +#define USB_DEVICE_DESCRIPTOR_TYPE 1 +#define USB_CONFIGURATION_DESCRIPTOR_TYPE 2 +#define USB_STRING_DESCRIPTOR_TYPE 3 +#define USB_INTERFACE_DESCRIPTOR_TYPE 4 +#define USB_ENDPOINT_DESCRIPTOR_TYPE 5 +#define USB_DEVICE_QUALIFIER 6 +#define USB_OTHER_SPEED_CONFIGURATION 7 + +#define USB_DEVICE_CLASS_COMMUNICATIONS 0x02 +#define USB_DEVICE_CLASS_HUMAN_INTERFACE 0x03 +#define USB_DEVICE_CLASS_STORAGE 0x08 +#define USB_DEVICE_CLASS_VENDOR_SPECIFIC 0xFF + +#define USB_CONFIG_POWERED_MASK 0x40 +#define USB_CONFIG_BUS_POWERED 0x80 +#define USB_CONFIG_SELF_POWERED 0xC0 +#define USB_CONFIG_REMOTE_WAKEUP 0x20 + +// bMaxPower in Configuration Descriptor +#define USB_CONFIG_POWER_MA(mA) ((mA)/2) +#ifndef USB_CONFIG_POWER + #define USB_CONFIG_POWER (500) +#endif + +#define MSC_SUBCLASS_SCSI 0x06 +#define MSC_PROTOCOL_BULK_ONLY 0x50 + +// Device +typedef struct __attribute__((packed)) { + uint8_t len; // 18 + uint8_t dtype; // 1 USB_DEVICE_DESCRIPTOR_TYPE + uint16_t usbVersion; // 0x200 + uint8_t deviceClass; + uint8_t deviceSubClass; + uint8_t deviceProtocol; + uint8_t packetSize0; // Packet 0 + uint16_t idVendor; + uint16_t idProduct; + uint16_t deviceVersion; // 0x100 + uint8_t iManufacturer; + uint8_t iProduct; + uint8_t iSerialNumber; + uint8_t bNumConfigurations; +} DeviceDescriptor; + +// Config +typedef struct __attribute__((packed)) { + uint8_t len; // 9 + uint8_t dtype; // 2 + uint16_t clen; // total length + uint8_t numInterfaces; + uint8_t config; + uint8_t iconfig; + uint8_t attributes; + uint8_t maxPower; +} ConfigDescriptor; + +// String + +// Interface +typedef struct __attribute__((packed)) { + uint8_t len; // 9 + uint8_t dtype; // 4 + uint8_t number; + uint8_t alternate; + uint8_t numEndpoints; + uint8_t interfaceClass; + uint8_t interfaceSubClass; + uint8_t protocol; + uint8_t iInterface; +} InterfaceDescriptor; + +// Endpoint +typedef struct __attribute__((packed)) { + uint8_t len; // 7 + uint8_t dtype; // 5 + uint8_t addr; + uint8_t attr; + uint16_t packetSize; + uint8_t interval; +} EndpointDescriptor; + +// Interface Association Descriptor +// Used to bind 2 interfaces together in CDC compostite device +typedef struct __attribute__((packed)) { + uint8_t len; // 8 + uint8_t dtype; // 11 + uint8_t firstInterface; + uint8_t interfaceCount; + uint8_t functionClass; + uint8_t funtionSubClass; + uint8_t functionProtocol; + uint8_t iInterface; +} IADDescriptor; + +typedef struct __attribute__((packed)) { + InterfaceDescriptor msc; + EndpointDescriptor in; + EndpointDescriptor out; +} MSCDescriptor; + +#define D_DEVICE(_class,_subClass,_proto,_packetSize0,_vid,_pid,_version,_im,_ip,_is,_configs) \ + { 18, 1, 0x200, _class,_subClass,_proto,_packetSize0,_vid,_pid,_version,_im,_ip,_is,_configs } +/* Table 9-8. Standard Device Descriptor + * bLength, bDescriptorType, bcdUSB, bDeviceClass, bDeviceSubClass, bDeviceProtocol, bMaxPacketSize0, + * idVendor, idProduct, bcdDevice, iManufacturer, iProduct, iSerialNumber, bNumConfigurations */ + +#define D_CONFIG(_totalLength,_interfaces) \ + { 9, 2, _totalLength,_interfaces, 1, 0, USB_CONFIG_BUS_POWERED | USB_CONFIG_REMOTE_WAKEUP, USB_CONFIG_POWER_MA(USB_CONFIG_POWER) } +/* Table 9-10. Standard Configuration Descriptor + * bLength, bDescriptorType, wTotalLength, bNumInterfaces, bConfigurationValue, iConfiguration + * bmAttributes, bMaxPower */ + +#define D_INTERFACE(_n,_numEndpoints,_class,_subClass,_protocol) \ + { 9, 4, _n, 0, _numEndpoints, _class,_subClass, _protocol, 0 } +/* Table 9-12. Standard Interface Descriptor + * bLength, bDescriptorType, bInterfaceNumber, bAlternateSetting, bNumEndpoints, bInterfaceClass, + * bInterfaceSubClass, bInterfaceProtocol, iInterface */ + +#define D_ENDPOINT(_addr,_attr,_packetSize, _interval) \ + { 7, 5, _addr,_attr,_packetSize, _interval } +/* Table 9-13. Standard Endpoint Descriptor + * bLength, bDescriptorType, bEndpointAddress, bmAttributes, wMaxPacketSize, bInterval */ + +#define D_IAD(_firstInterface, _count, _class, _subClass, _protocol) \ + { 8, 11, _firstInterface, _count, _class, _subClass, _protocol, 0 } +/* iadclasscode_r10.pdf, Table 9\96Z. Standard Interface Association Descriptor + * bLength, bDescriptorType, bFirstInterface, bInterfaceCount, bFunctionClass, bFunctionSubClass, bFunctionProtocol, iFunction */ + +// Functional Descriptor General Format +#define D_CDCCS(_subtype,_d0,_d1) { 5, 0x24, _subtype, _d0, _d1 } +#define D_CDCCS4(_subtype,_d0) { 4, 0x24, _subtype, _d0 } +/* bFunctionLength, bDescriptorType, bDescriptorSubtype, function specific data0, functional specific data N-1 + * CS_INTERFACE 24h */ + +#endif diff --git a/cores/arduino/USB/USBDesc.h b/cores/arduino/USB/USBDesc.h new file mode 100644 index 0000000..05f420c --- /dev/null +++ b/cores/arduino/USB/USBDesc.h @@ -0,0 +1,42 @@ +/* + Copyright (c) 2014 Arduino LLC. 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 __USBDESC_H__ +#define __USBDESC_H__ + +#ifdef USBCON + +// CDC or HID can be enabled together. +#ifndef CDC_DISABLED +#define CDC_ENABLED +#endif + +#ifndef PLUGGABLE_USB_DISABLED +#define PLUGGABLE_USB_ENABLED +#endif + +#define ISERIAL_MAX_LEN 65 + +// Defined string description +#define IMANUFACTURER 1 +#define IPRODUCT 2 +#define ISERIAL 3 + +#endif /* USBCON */ + +#endif /* __USBDESC_H__ */ diff --git a/cores/arduino/USB/USB_host.h b/cores/arduino/USB/USB_host.h new file mode 100644 index 0000000..319dffe --- /dev/null +++ b/cores/arduino/USB/USB_host.h @@ -0,0 +1,66 @@ +/* + Copyright (c) 2014 Arduino LLC. 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 USB_HOST_H_INCLUDED +#define USB_HOST_H_INCLUDED + +#include +#include "samd21_host.h" +#ifdef __cplusplus +extern "C" { +#endif + +#define tokSETUP USB_HOST_PCFG_PTOKEN_SETUP +#define tokIN USB_HOST_PCFG_PTOKEN_IN +#define tokOUT USB_HOST_PCFG_PTOKEN_OUT +#define tokINHS USB_HOST_PCFG_PTOKEN_IN +#define tokOUTHS USB_HOST_PCFG_PTOKEN_OUT + +//! \brief Device speed +/*typedef enum { + UHD_SPEED_LOW = 0, + UHD_SPEED_FULL = 1, + UHD_SPEED_HIGH = 2, +} uhd_speed_t;*/ + +//! States of USBB interface +typedef enum { + UHD_STATE_NO_VBUS = 0, + UHD_STATE_DISCONNECTED = 1, + UHD_STATE_CONNECTED = 2, + UHD_STATE_ERROR = 3, +} uhd_vbus_state_t; + +extern void UHD_Init(void); +extern void UHD_Handler(void); +extern void USB_SetHandler(void (*pf_isr)(void)); +extern uhd_vbus_state_t UHD_GetVBUSState(void); +extern uint32_t UHD_Pipe0_Alloc(uint32_t ul_add, uint32_t ul_ep_size); +extern uint32_t UHD_Pipe_Alloc(uint32_t ul_dev_addr, uint32_t ul_dev_ep, uint32_t ul_type, uint32_t ul_dir, uint32_t ul_maxsize, uint32_t ul_interval, uint32_t ul_nb_bank); +extern void UHD_Pipe_CountZero(uint32_t ul_pipe); +extern void UHD_Pipe_Free(uint32_t ul_pipe); +extern uint32_t UHD_Pipe_Read(uint32_t ul_pipe, uint32_t ul_size, uint8_t* data); +extern void UHD_Pipe_Write(uint32_t ul_pipe, uint32_t ul_size, uint8_t* data); +extern void UHD_Pipe_Send(uint32_t ul_pipe, uint32_t ul_token_type); +extern uint32_t UHD_Pipe_Is_Transfer_Complete(uint32_t ul_pipe, uint32_t ul_token_type); + +#ifdef __cplusplus +} +#endif + +#endif /* USB_HOST_H_INCLUDED */ diff --git a/cores/arduino/USB/samd21_host.c b/cores/arduino/USB/samd21_host.c new file mode 100644 index 0000000..ef6a0b2 --- /dev/null +++ b/cores/arduino/USB/samd21_host.c @@ -0,0 +1,518 @@ +/* + Copyright (c) 2014 Arduino LLC. 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 +*/ + + +#include +#include +#include + +#include "Arduino.h" +#include "variant.h" +#include "USB_host.h" +#include "samd21_host.h" +#include "wiring_private.h" + +#define HOST_DEFINED +#ifdef HOST_DEFINED + +//#define TRACE_UOTGHS_HOST(x) x +#define TRACE_UOTGHS_HOST(x) + +// Handle UOTGHS Host driver state +static uhd_vbus_state_t uhd_state = UHD_STATE_NO_VBUS; + +__attribute__((__aligned__(4))) volatile UsbHostDescriptor usb_pipe_table[USB_EPT_NUM]; + +extern void (*gpf_isr)(void); + + +// NVM Software Calibration Area Mapping +// USB TRANSN calibration value. Should be written to the USB PADCAL register. +#define NVM_USB_PAD_TRANSN_POS 45 +#define NVM_USB_PAD_TRANSN_SIZE 5 +// USB TRANSP calibration value. Should be written to the USB PADCAL register. +#define NVM_USB_PAD_TRANSP_POS 50 +#define NVM_USB_PAD_TRANSP_SIZE 5 +// USB TRIM calibration value. Should be written to the USB PADCAL register. +#define NVM_USB_PAD_TRIM_POS 55 +#define NVM_USB_PAD_TRIM_SIZE 3 + +/** + * \brief Initialize the SAMD21 host driver. + */ +void UHD_Init(void) +{ + uint32_t pad_transn; + uint32_t pad_transp; + uint32_t pad_trim; + + USB_SetHandler(&UHD_Handler); + + /* Enable USB clock */ + PM->APBBMASK.reg |= PM_APBBMASK_USB; + + /* Set up the USB DP/DM pins */ + pinPeripheral( PIN_USB_DM, PIO_COM ); + pinPeripheral( PIN_USB_DP, PIO_COM ); +// PORT->Group[0].PINCFG[PIN_PA24G_USB_DM].bit.PMUXEN = 1; +// PORT->Group[0].PMUX[PIN_PA24G_USB_DM/2].reg &= ~(0xF << (4 * (PIN_PA24G_USB_DM & 0x01u))); +// PORT->Group[0].PMUX[PIN_PA24G_USB_DM/2].reg |= MUX_PA24G_USB_DM << (4 * (PIN_PA24G_USB_DM & 0x01u)); +// PORT->Group[0].PINCFG[PIN_PA25G_USB_DP].bit.PMUXEN = 1; +// PORT->Group[0].PMUX[PIN_PA25G_USB_DP/2].reg &= ~(0xF << (4 * (PIN_PA25G_USB_DP & 0x01u))); +// PORT->Group[0].PMUX[PIN_PA25G_USB_DP/2].reg |= MUX_PA25G_USB_DP << (4 * (PIN_PA25G_USB_DP & 0x01u)); + + /* ---------------------------------------------------------------------------------------------- + * Put Generic Clock Generator 0 as source for Generic Clock Multiplexer 6 (USB reference) + */ + GCLK->CLKCTRL.reg = GCLK_CLKCTRL_ID(6) | // Generic Clock Multiplexer 6 + GCLK_CLKCTRL_GEN_GCLK0 | // Generic Clock Generator 0 is source + GCLK_CLKCTRL_CLKEN; + + while (GCLK->STATUS.reg & GCLK_STATUS_SYNCBUSY) + { + /* Wait for synchronization */ + } + + /* Reset */ + USB->HOST.CTRLA.bit.SWRST = 1; + while (USB->HOST.SYNCBUSY.bit.SWRST) + { + /* Sync wait */ + } + + // uhd_enable(); + USB->DEVICE.CTRLA.reg |= USB_CTRLA_ENABLE | USB_CTRLA_MODE; + uhd_force_host_mode(); + while (USB->HOST.SYNCBUSY.reg == USB_SYNCBUSY_ENABLE); + + /* Load Pad Calibration */ + pad_transn = (*((uint32_t *)(NVMCTRL_OTP4) // Non-Volatile Memory Controller + + (NVM_USB_PAD_TRANSN_POS / 32)) + >> (NVM_USB_PAD_TRANSN_POS % 32)) + & ((1 << NVM_USB_PAD_TRANSN_SIZE) - 1); + + if (pad_transn == 0x1F) // maximum value (31) + { + pad_transn = 5; + } + + USB->HOST.PADCAL.bit.TRANSN = pad_transn; + + pad_transp = (*((uint32_t *)(NVMCTRL_OTP4) + + (NVM_USB_PAD_TRANSP_POS / 32)) + >> (NVM_USB_PAD_TRANSP_POS % 32)) + & ((1 << NVM_USB_PAD_TRANSP_SIZE) - 1); + + if (pad_transp == 0x1F) // maximum value (31) + { + pad_transp = 29; + } + + USB->HOST.PADCAL.bit.TRANSP = pad_transp; + + pad_trim = (*((uint32_t *)(NVMCTRL_OTP4) + + (NVM_USB_PAD_TRIM_POS / 32)) + >> (NVM_USB_PAD_TRIM_POS % 32)) + & ((1 << NVM_USB_PAD_TRIM_SIZE) - 1); + + if (pad_trim == 0x7) // maximum value (7) + { + pad_trim = 3; + } + + USB->HOST.PADCAL.bit.TRIM = pad_trim; + + + /* Set the configuration */ + uhd_run_in_standby(); + // Set address of USB SRAM + USB->HOST.DESCADD.reg = (uint32_t)(&usb_pipe_table[0]); + // For USB_SPEED_FULL + uhd_force_full_speed(); + memset((void *)usb_pipe_table, 0, sizeof(usb_pipe_table)); + + uhd_state = UHD_STATE_NO_VBUS; + + // Put VBUS on USB port + #ifdef PIN_USB_HOST_ENABLE + pinMode( PIN_USB_HOST_ENABLE, OUTPUT ); + digitalWrite( PIN_USB_HOST_ENABLE, HIGH ); + #endif + + uhd_enable_connection_int(); + + USB->HOST.INTENSET.reg = USB_HOST_INTENSET_DCONN; + USB->HOST.INTENSET.reg = USB_HOST_INTENSET_WAKEUP; + USB->HOST.INTENSET.reg = USB_HOST_INTENSET_DDISC; + + USB->HOST.CTRLB.bit.VBUSOK = 1; + + // Configure interrupts + NVIC_SetPriority((IRQn_Type)USB_IRQn, 0UL); + NVIC_EnableIRQ((IRQn_Type)USB_IRQn); +} + + +/** + * \brief Interrupt sub routine for USB Host state machine management. + */ +void UHD_Handler(void) +{ + uint16_t flags; + + if (USB->HOST.CTRLA.bit.MODE) { + /*host mode ISR */ + + /* get interrupt flags */ + flags = USB->HOST.INTFLAG.reg; + + /* host SOF interrupt */ + if (flags & USB_HOST_INTFLAG_HSOF) + { + /* clear the flag */ + USB->HOST.INTFLAG.reg = USB_HOST_INTFLAG_HSOF; + uhd_state = UHD_STATE_CONNECTED; + return; + } + + /* host reset interrupt */ + if (flags & USB_HOST_INTFLAG_RST) + { + /* clear the flag */ + USB->HOST.INTFLAG.reg = USB_HOST_INTFLAG_RST; + uhd_state = UHD_STATE_DISCONNECTED; //UHD_STATE_ERROR; + return; + } + + /* host upstream resume interrupts */ + if (flags & USB_HOST_INTFLAG_UPRSM) + { + /* clear the flags */ + USB->HOST.INTFLAG.reg = USB_HOST_INTFLAG_UPRSM; + uhd_state = UHD_STATE_DISCONNECTED; //UHD_STATE_ERROR; + return; + } + + /* host downstream resume interrupts */ + if (flags & USB_HOST_INTFLAG_DNRSM) + { + /* clear the flags */ + USB->HOST.INTFLAG.reg = USB_HOST_INTFLAG_DNRSM; + uhd_state = UHD_STATE_DISCONNECTED; //UHD_STATE_ERROR; + return; + } + + /* host wakeup interrupts */ + if (flags & USB_HOST_INTFLAG_WAKEUP) + { + /* clear the flags */ + USB->HOST.INTFLAG.reg = USB_HOST_INTFLAG_WAKEUP; + uhd_state = UHD_STATE_CONNECTED; //UHD_STATE_ERROR; + return; + } + + /* host ram access interrupt */ + if (flags & USB_HOST_INTFLAG_RAMACER) + { + /* clear the flag */ + USB->HOST.INTFLAG.reg = USB_HOST_INTFLAG_RAMACER; + uhd_state = UHD_STATE_DISCONNECTED; //UHD_STATE_ERROR; + return; + } + + /* host connect interrupt */ + if (flags & USB_HOST_INTFLAG_DCONN) + { + TRACE_UOTGHS_HOST(printf(">>> UHD_ISR : Connection INT\r\n"); + ) + /* clear the flag */ + uhd_ack_connection(); + uhd_disable_connection_int(); + uhd_ack_disconnection(); + uhd_enable_disconnection_int(); + //uhd_enable_sof(); + uhd_state = UHD_STATE_CONNECTED; + return; + } + + /* host disconnect interrupt */ + if (flags & USB_HOST_INTFLAG_DDISC) + { + TRACE_UOTGHS_HOST(printf(">>> UHD_ISR : Disconnection INT\r\n"); + ) + /* clear the flag */ + uhd_ack_disconnection(); + uhd_disable_disconnection_int(); + // Stop reset signal, in case of disconnection during reset + uhd_stop_reset(); + // Disable wakeup/resumes interrupts, + // in case of disconnection during suspend mode + uhd_ack_connection(); + uhd_enable_connection_int(); + uhd_state = UHD_STATE_DISCONNECTED; + return; + } + } + else { + while(1); + } +} + + + +/** + * \brief Get VBUS state. + * + * \return VBUS status. + */ +uhd_vbus_state_t UHD_GetVBUSState(void) +{ + return uhd_state; +} + + +/** + * \brief Allocate FIFO for pipe 0. + * + * \param ul_add Address of remote device for pipe 0. + * \param ul_ep_size Actual size of the FIFO in bytes. + * + * \retval 0 success. + * \retval 1 error. + */ +uint32_t UHD_Pipe0_Alloc(uint32_t ul_add , uint32_t ul_ep_size) +{ + (void)(ul_add); // Unused argument + + if( USB->HOST.STATUS.reg & USB_HOST_STATUS_SPEED(1) ) + ul_ep_size = USB_PCKSIZE_SIZE_8_BYTES; // Low Speed + else + ul_ep_size = USB_PCKSIZE_SIZE_64_BYTES; // Full Speed + + USB->HOST.HostPipe[0].PCFG.bit.PTYPE = 1; //USB_HOST_PCFG_PTYPE_CTRL; + usb_pipe_table[0].HostDescBank[0].CTRL_PIPE.bit.PEPNUM = 0; + usb_pipe_table[0].HostDescBank[0].PCKSIZE.bit.SIZE = ul_ep_size; + + return 0; +} + + +/** + * \brief Allocate a new pipe. + * + * \note UOTGHS maximum pipe number is limited to 10, meaning that only a limited + * amount of devices can be connected. Unfortunately, using only one pipe shared accross + * various endpoints and devices is not possible because the UOTGHS IP does not allow to + * change the data toggle value through register interface. + * + * \param ul_dev_addr Address of remote device. + * \param ul_dev_ep Targeted endpoint of remote device. + * \param ul_type Pipe type. + * \param ul_dir Pipe direction. + * \param ul_maxsize Pipe size. + * \param ul_interval Polling interval (if applicable to pipe type). + * \param ul_nb_bank Number of banks associated with this pipe. + * + * \return 1. + */ +uint32_t UHD_Pipe_Alloc(uint32_t ul_dev_addr, uint32_t ul_dev_ep, uint32_t ul_type, uint32_t ul_dir, uint32_t ul_maxsize, uint32_t ul_interval, uint32_t ul_nb_bank) +{ + /* set pipe config */ + USB->HOST.HostPipe[ul_dev_ep].PCFG.bit.BK = ul_nb_bank; + // PTYPE: + USB->HOST.HostPipe[ul_dev_ep].PCFG.reg &= ~USB_HOST_PCFG_MASK; // USB->HOST.HostPipe[0].PCFG.bit.PTYPE = 1; //USB_HOST_PCFG_PTYPE_CTRL; + USB->HOST.HostPipe[ul_dev_ep].PCFG.reg |= ul_type; + USB->HOST.HostPipe[ul_dev_ep].BINTERVAL.reg = ul_interval; + + if (ul_dir & USB_EP_DIR_IN) + { + USB->HOST.HostPipe[ul_dev_ep].PCFG.bit.PTOKEN = USB_HOST_PCFG_PTOKEN_IN; + USB->HOST.HostPipe[ul_dev_ep].PSTATUSSET.reg = USB_HOST_PSTATUSSET_BK0RDY; + } + else + { + USB->HOST.HostPipe[ul_dev_ep].PCFG.bit.PTOKEN = USB_HOST_PCFG_PTOKEN_OUT; + USB->HOST.HostPipe[ul_dev_ep].PSTATUSCLR.reg = USB_HOST_PSTATUSCLR_BK0RDY; + } + + if( USB->HOST.STATUS.reg & USB_HOST_STATUS_SPEED(1) ) + ul_maxsize = USB_PCKSIZE_SIZE_8_BYTES; // Low Speed + else + ul_maxsize = USB_PCKSIZE_SIZE_64_BYTES; // Full Speed + + memset((uint8_t *)&usb_pipe_table[ul_dev_ep], 0, sizeof(usb_pipe_table[ul_dev_ep])); + + usb_pipe_table[ul_dev_ep].HostDescBank[0].CTRL_PIPE.bit.PDADDR = ul_dev_addr; + usb_pipe_table[ul_dev_ep].HostDescBank[0].CTRL_PIPE.bit.PEPNUM = ul_dev_ep; + usb_pipe_table[ul_dev_ep].HostDescBank[0].PCKSIZE.bit.SIZE = ul_maxsize; + + return 1; +} + + +void UHD_Pipe_CountZero(uint32_t ul_pipe) +{ + usb_pipe_table[ul_pipe].HostDescBank[0].PCKSIZE.bit.BYTE_COUNT = 0; +} + +/** + * \brief Free a pipe. + * + * \param ul_pipe Pipe number to free. + */ +void UHD_Pipe_Free(uint32_t ul_pipe) +{ + // The Pipe is frozen and no additional requests will be sent to the device on this pipe address. + USB->HOST.HostPipe[ul_pipe].PSTATUSSET.reg = USB_HOST_PSTATUSSET_PFREEZE; +} + + +/** + * \brief Read from a pipe. + * + * \param ul_pipe Pipe number. + * \param ul_size Maximum number of data to read. + * \param data Buffer to store the data. + * + * \return number of data read. + */ +uint32_t UHD_Pipe_Read(uint32_t pipe_num, uint32_t buf_size, uint8_t *buf) +{ + if (USB->HOST.HostPipe[pipe_num].PCFG.bit.PTYPE == USB_HOST_PTYPE_DIS) + { + return 0; + } + + /* get pipe config from setting register */ + usb_pipe_table[pipe_num].HostDescBank[0].ADDR.reg = (uint32_t)buf; + usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.BYTE_COUNT = 0; + usb_pipe_table[pipe_num].HostDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE = buf_size; + USB->HOST.HostPipe[pipe_num].PCFG.bit.PTOKEN = USB_HOST_PCFG_PTOKEN_IN; + + /* Start transfer */ + USB->HOST.HostPipe[pipe_num].PSTATUSCLR.reg = USB_HOST_PSTATUSCLR_BK0RDY; + + // Unfreeze pipe + USB->HOST.HostPipe[pipe_num].PSTATUSCLR.reg = USB_HOST_PSTATUSCLR_PFREEZE; + + return buf_size; +} + + +/** + * \brief Write into a pipe. + * + * \param ul_pipe Pipe number. + * \param ul_size Maximum number of data to read. + * \param data Buffer containing data to write. + */ +void UHD_Pipe_Write(uint32_t ul_pipe, uint32_t ul_size, uint8_t *buf) +{ + /* get pipe config from setting register */ + usb_pipe_table[ul_pipe].HostDescBank[0].ADDR.reg = (uint32_t)buf; + usb_pipe_table[ul_pipe].HostDescBank[0].PCKSIZE.bit.BYTE_COUNT = ul_size; + usb_pipe_table[ul_pipe].HostDescBank[0].PCKSIZE.bit.MULTI_PACKET_SIZE = 0; +} + +/** + * \brief Send a pipe content. + * + * \param ul_pipe Pipe number. + * \param ul_token_type Token type. + */ +void UHD_Pipe_Send(uint32_t ul_pipe, uint32_t ul_token_type) +{ + USB->HOST.HostPipe[ul_pipe].PCFG.bit.PTOKEN = ul_token_type; + + /* Start transfer */ + if(ul_token_type == USB_HOST_PCFG_PTOKEN_SETUP ) + { + USB->HOST.HostPipe[ul_pipe].PINTFLAG.reg = USB_HOST_PINTFLAG_TXSTP; + USB->HOST.HostPipe[ul_pipe].PSTATUSSET.reg = USB_HOST_PSTATUSSET_BK0RDY; + } + else if(ul_token_type == USB_HOST_PCFG_PTOKEN_IN ) + { + USB->HOST.HostPipe[ul_pipe].PSTATUSCLR.reg = USB_HOST_PSTATUSCLR_BK0RDY; + } + else + { + USB->HOST.HostPipe[ul_pipe].PINTFLAG.reg = USB_HOST_PINTFLAG_TRCPT(1); // Transfer Complete 0 + USB->HOST.HostPipe[ul_pipe].PSTATUSSET.reg = USB_HOST_PSTATUSSET_BK0RDY; + } + + // Unfreeze pipe + uhd_unfreeze_pipe(ul_pipe); +} + +/** + * \brief Check for pipe transfer completion. + * + * \param ul_pipe Pipe number. + * \param ul_token_type Token type. + * + * \retval 0 transfer is not complete. + * \retval 1 transfer is complete. + */ +uint32_t UHD_Pipe_Is_Transfer_Complete(uint32_t ul_pipe, uint32_t ul_token_type) +{ + // Check for transfer completion depending on token type + switch (ul_token_type) + { + case USB_HOST_PCFG_PTOKEN_SETUP: + if (Is_uhd_setup_ready(ul_pipe)) + { + uhd_ack_setup_ready(ul_pipe); + uhd_freeze_pipe(ul_pipe); + return 1; + } + break; + + case USB_HOST_PCFG_PTOKEN_IN: + if (Is_uhd_in_received(ul_pipe)) + { + // IN packet received + uhd_ack_in_received(ul_pipe); + // Freeze will stop after the transfer + uhd_freeze_pipe(ul_pipe); + return 1; + } + break; + + case USB_HOST_PCFG_PTOKEN_OUT: + if (Is_uhd_out_ready(ul_pipe)) + { + // OUT packet sent + uhd_ack_out_ready(ul_pipe); + uhd_freeze_pipe(ul_pipe); + return 1; + } + break; + } + + return 0; +} + + + + +// USB_Handler ISR +// void USB_Handler(void) { +// UHD_Handler(); +// } + +#endif // HOST_DEFINED diff --git a/cores/arduino/USB/samd21_host.h b/cores/arduino/USB/samd21_host.h new file mode 100644 index 0000000..d2d9c9e --- /dev/null +++ b/cores/arduino/USB/samd21_host.h @@ -0,0 +1,129 @@ +/* + Copyright (c) 2014 Arduino LLC. 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 SAMD21_HOST_H_INCLUDED +#define SAMD21_HOST_H_INCLUDED + +#ifdef __cplusplus +extern "C" { +#endif + +extern __attribute__((__aligned__(4))) volatile UsbHostDescriptor usb_pipe_table[USB_EPT_NUM]; + +#define USB_EP_DIR_IN 0x80 // USB_SETUP_DEVICE_TO_HOST +#define USB_EP_DIR_OUT 0x00 // USB_SETUP_HOST_TO_DEVICE + +#define USB_HOST_PTYPE_DIS USB_HOST_PCFG_PTYPE(0x0) // Pipe is disabled +#define USB_HOST_PTYPE_CTRL USB_HOST_PCFG_PTYPE(0x1) // Pipe is enabled and configured as CONTROL +#define USB_HOST_PTYPE_ISO USB_HOST_PCFG_PTYPE(0x2) // Pipe is enabled and configured as ISO +#define USB_HOST_PTYPE_BULK USB_HOST_PCFG_PTYPE(0x3) // Pipe is enabled and configured as BULK +#define USB_HOST_PTYPE_INT USB_HOST_PCFG_PTYPE(0x4) // Pipe is enabled and configured as INTERRUPT +#define USB_HOST_PTYPE_EXT USB_HOST_PCFG_PTYPE(0x5) // Pipe is enabled and configured as EXTENDED + +#define USB_HOST_NB_BK_1 1 + +#define USB_HOST_PCFG_PTOKEN_SETUP USB_HOST_PCFG_PTOKEN(0x0) +#define USB_HOST_PCFG_PTOKEN_IN USB_HOST_PCFG_PTOKEN(0x1) +#define USB_HOST_PCFG_PTOKEN_OUT USB_HOST_PCFG_PTOKEN(0x2) + +#define USB_ERRORFLOW USB_HOST_STATUS_BK_ERRORFLOW +#define USB_ERRORTIMEOUT USB_HOST_STATUS_PIPE_TOUTER +#define USB_ERROR_DATATOGGLE USB_HOST_STATUS_PIPE_DTGLER + +#define USB_PCKSIZE_SIZE_8_BYTES 0 +#define USB_PCKSIZE_SIZE_16_BYTES 1 +#define USB_PCKSIZE_SIZE_32_BYTES 2 +#define USB_PCKSIZE_SIZE_64_BYTES 3 +#define USB_PCKSIZE_SIZE_128_BYTES 4 +#define USB_PCKSIZE_SIZE_256_BYTES 5 +#define USB_PCKSIZE_SIZE_512_BYTES 6 +#define USB_PCKSIZE_SIZE_1023_BYTES_FS 7 +#define USB_PCKSIZE_SIZE_1024_BYTES_HS 7 + +#define USB_HOST_DTGL(p) (USB->HOST.HostPipe[p].PSTATUS.reg & USB_HOST_PSTATUS_DTGL)>>USB_HOST_PSTATUS_DTGL_Pos + +// USB host connection/disconnection monitoring +#define uhd_enable_connection_int() USB->HOST.INTENSET.reg = USB_HOST_INTENSET_DCONN +#define uhd_disable_connection_int() USB->HOST.INTENCLR.reg = USB_HOST_INTENCLR_DCONN +#define uhd_ack_connection() USB->HOST.INTFLAG.reg = USB_HOST_INTFLAG_DCONN + +#define uhd_enable_disconnection_int() USB->HOST.INTENSET.reg = USB_HOST_INTENSET_DDISC +#define uhd_disable_disconnection_int() USB->HOST.INTENCLR.reg = USB_HOST_INTENCLR_DDISC +#define uhd_ack_disconnection() USB->HOST.INTFLAG.reg = USB_HOST_INTFLAG_DDISC + +// Initiates a USB register reset +#define uhd_start_USB_reg_reset() USB->HOST.CTRLA.bit.SWRST = 1; + +// Bus Reset +#define Is_uhd_starting_reset() (USB->HOST.CTRLB.bit.BUSRESET == 1) +#define UHD_BusReset() USB->HOST.CTRLB.bit.BUSRESET = 1 +#define uhd_stop_reset() // nothing to do + +#define uhd_ack_reset_sent() USB->HOST.INTFLAG.reg = USB_HOST_INTFLAG_RST +#define Is_uhd_reset_sent() (USB->HOST.INTFLAG.reg & USB_HOST_INTFLAG_RST) + +// Initiates a SOF events +#define uhd_enable_sof() USB->HOST.CTRLB.bit.SOFE = 1 +#define uhd_disable_sof() USB->HOST.CTRLB.bit.SOFE = 0 +#define Is_uhd_sof_enabled() (USB->HOST.CTRLB & USB_HOST_CTRLB_SOFE) +#define Is_uhd_sof() (USB->HOST.INTFLAG.reg & USB_HOST_INTFLAG_HSOF) + +// USB address of pipes +#define uhd_configure_address(pipe_num, addr) usb_pipe_table[pipe_num].HostDescBank[0].CTRL_PIPE.bit.PDADDR = addr +#define uhd_get_configured_address(pipe_num) usb_pipe_table[pipe_num].HostDescBank[0].CTRL_PIPE.bit.PDADDR + +// Pipes +#define uhd_freeze_pipe(p) USB->HOST.HostPipe[p].PSTATUSSET.reg = USB_HOST_PSTATUSSET_PFREEZE +#define uhd_unfreeze_pipe(p) USB->HOST.HostPipe[p].PSTATUSCLR.reg = USB_HOST_PSTATUSCLR_PFREEZE +#define Is_uhd_pipe_frozen(p) ((USB->HOST.HostPipe[p].PSTATUS.reg&USB_HOST_PSTATUS_PFREEZE)==USB_HOST_PSTATUS_PFREEZE) + +// Pipe configuration +#define uhd_configure_pipe_token(p, token) USB->HOST.HostPipe[p].PCFG.bit.PTOKEN = token + +// Pipe data management +#define uhd_byte_count(p) usb_pipe_table[p].HostDescBank[0].PCKSIZE.bit.BYTE_COUNT +#define uhd_ack_setup_ready(p) USB->HOST.HostPipe[p].PINTFLAG.reg = USB_HOST_PINTFLAG_TXSTP +#define Is_uhd_setup_ready(p) ((USB->HOST.HostPipe[p].PINTFLAG.reg&USB_HOST_PINTFLAG_TXSTP) == USB_HOST_PINTFLAG_TXSTP) +#define uhd_ack_in_received(p) USB->HOST.HostPipe[p].PINTFLAG.reg = USB_HOST_PINTFLAG_TRCPT(1) +#define Is_uhd_in_received(p) ((USB->HOST.HostPipe[p].PINTFLAG.reg&USB_HOST_PINTFLAG_TRCPT(1)) == USB_HOST_PINTFLAG_TRCPT(1)) +#define uhd_ack_out_ready(p) USB->HOST.HostPipe[p].PINTFLAG.reg = USB_HOST_PINTFLAG_TRCPT(1) +#define Is_uhd_out_ready(p) ((USB->HOST.HostPipe[p].PINTFLAG.reg&USB_HOST_PINTFLAG_TRCPT(1)) == USB_HOST_PINTFLAG_TRCPT(1)) +#define uhd_ack_nak_received(p) usb_pipe_table[p].HostDescBank[1].STATUS_BK.reg &= ~USB_HOST_STATUS_BK_ERRORFLOW +#define Is_uhd_nak_received(p) (usb_pipe_table[p].HostDescBank[1].STATUS_BK.reg & USB_HOST_STATUS_BK_ERRORFLOW) + +// Endpoint Interrupt Summary +#define uhd_endpoint_interrupt() USB->HOST.PINTSMRY.reg + +// Run in Standby +#define uhd_run_in_standby() USB->HOST.CTRLA.reg |= USB_CTRLA_RUNSTDBY +// Force host mode +#define uhd_force_host_mode() USB->HOST.CTRLA.reg |= USB_CTRLA_MODE + +// Enable USB macro +#define uhd_enable() USB->HOST.CTRLA.reg |= USB_CTRLA_ENABLE +// Disable USB macro +#define uhd_disable() USB->HOST.CTRLA.reg &= ~USB_CTRLA_ENABLE + +// Force full speed mode +#define uhd_force_full_speed() USB->HOST.CTRLB.reg &= ~USB_HOST_CTRLB_SPDCONF_Msk + +#ifdef __cplusplus +} +#endif + +#endif /* SAMD21_HOST_H_INCLUDED */ diff --git a/cores/arduino/Uart.cpp b/cores/arduino/Uart.cpp new file mode 100644 index 0000000..5f7b3d8 --- /dev/null +++ b/cores/arduino/Uart.cpp @@ -0,0 +1,240 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#include "Arduino.h" +#include "wiring_private.h" +#include "Uart.h" + +#define NO_RTS_PIN 255 +#define NO_CTS_PIN 255 +#define RTS_RX_THRESHOLD 10 + +Uart::Uart(SERCOM *_s, uint8_t _pinRX, uint8_t _pinTX, SercomRXPad _padRX, SercomUartTXPad _padTX) : + Uart(_s, _pinRX, _pinTX, _padRX, _padTX, NO_RTS_PIN, NO_CTS_PIN) +{ +} + +Uart::Uart(SERCOM *_s, uint8_t _pinRX, uint8_t _pinTX, SercomRXPad _padRX, SercomUartTXPad _padTX, uint8_t _pinRTS, uint8_t _pinCTS) +{ + sercom = _s; + uc_pinRX = _pinRX; + uc_pinTX = _pinTX; + uc_padRX = _padRX ; + uc_padTX = _padTX; + uc_pinRTS = _pinRTS; + uc_pinCTS = _pinCTS; +} + +void Uart::begin(unsigned long baudrate) +{ + begin(baudrate, SERIAL_8N1); +} + +void Uart::begin(unsigned long baudrate, uint16_t config) +{ + pinPeripheral(uc_pinRX, g_APinDescription[uc_pinRX].ulPinType); + pinPeripheral(uc_pinTX, g_APinDescription[uc_pinTX].ulPinType); + + if (uc_padTX == UART_TX_RTS_CTS_PAD_0_2_3) { + if (uc_pinCTS != NO_CTS_PIN) { + pinPeripheral(uc_pinCTS, g_APinDescription[uc_pinCTS].ulPinType); + } + } + + if (uc_pinRTS != NO_RTS_PIN) { + pinMode(uc_pinRTS, OUTPUT); + + EPortType rtsPort = g_APinDescription[uc_pinRTS].ulPort; + pul_outsetRTS = &PORT->Group[rtsPort].OUTSET.reg; + pul_outclrRTS = &PORT->Group[rtsPort].OUTCLR.reg; + ul_pinMaskRTS = (1ul << g_APinDescription[uc_pinRTS].ulPin); + + *pul_outclrRTS = ul_pinMaskRTS; + } + + sercom->initUART(UART_INT_CLOCK, SAMPLE_RATE_x16, baudrate); + sercom->initFrame(extractCharSize(config), LSB_FIRST, extractParity(config), extractNbStopBit(config)); + sercom->initPads(uc_padTX, uc_padRX); + + sercom->enableUART(); +} + +void Uart::end() +{ + sercom->resetUART(); + rxBuffer.clear(); + txBuffer.clear(); +} + +void Uart::flush() +{ + while(txBuffer.available()); // wait until TX buffer is empty + + sercom->flushUART(); +} + +void Uart::IrqHandler() +{ + if (sercom->isFrameErrorUART()) { + // frame error, next byte is invalid so read and discard it + sercom->readDataUART(); + + sercom->clearFrameErrorUART(); + } + + if (sercom->availableDataUART()) { + rxBuffer.store_char(sercom->readDataUART()); + + if (uc_pinRTS != NO_RTS_PIN) { + // RX buffer space is below the threshold, de-assert RTS + if (rxBuffer.availableForStore() < RTS_RX_THRESHOLD) { + *pul_outsetRTS = ul_pinMaskRTS; + } + } + } + + if (sercom->isDataRegisterEmptyUART()) { + if (txBuffer.available()) { + uint8_t data = txBuffer.read_char(); + + sercom->writeDataUART(data); + } else { + sercom->disableDataRegisterEmptyInterruptUART(); + } + } + + if (sercom->isUARTError()) { + sercom->acknowledgeUARTError(); + // TODO: if (sercom->isBufferOverflowErrorUART()) .... + // TODO: if (sercom->isParityErrorUART()) .... + sercom->clearStatusUART(); + } +} + +int Uart::available() +{ + return rxBuffer.available(); +} + +int Uart::availableForWrite() +{ + return txBuffer.availableForStore(); +} + +int Uart::peek() +{ + return rxBuffer.peek(); +} + +int Uart::read() +{ + int c = rxBuffer.read_char(); + + if (uc_pinRTS != NO_RTS_PIN) { + // if there is enough space in the RX buffer, assert RTS + if (rxBuffer.availableForStore() > RTS_RX_THRESHOLD) { + *pul_outclrRTS = ul_pinMaskRTS; + } + } + + return c; +} + +size_t Uart::write(const uint8_t data) +{ + if (sercom->isDataRegisterEmptyUART() && txBuffer.available() == 0) { + sercom->writeDataUART(data); + } else { + // spin lock until a spot opens up in the buffer + while(txBuffer.isFull()) { + uint8_t interruptsEnabled = ((__get_PRIMASK() & 0x1) == 0); + + if (interruptsEnabled) { + uint32_t exceptionNumber = (SCB->ICSR & SCB_ICSR_VECTACTIVE_Msk); + + if (exceptionNumber == 0 || + NVIC_GetPriority((IRQn_Type)(exceptionNumber - 16)) > SERCOM_NVIC_PRIORITY) { + // no exception or called from an ISR with lower priority, + // wait for free buffer spot via IRQ + continue; + } + } + + // interrupts are disabled or called from ISR with higher or equal priority than the SERCOM IRQ + // manually call the UART IRQ handler when the data register is empty + if (sercom->isDataRegisterEmptyUART()) { + IrqHandler(); + } + } + + txBuffer.store_char(data); + + sercom->enableDataRegisterEmptyInterruptUART(); + } + + return 1; +} + +SercomNumberStopBit Uart::extractNbStopBit(uint16_t config) +{ + switch(config & SERIAL_STOP_BIT_MASK) + { + case SERIAL_STOP_BIT_1: + default: + return SERCOM_STOP_BIT_1; + + case SERIAL_STOP_BIT_2: + return SERCOM_STOP_BITS_2; + } +} + +SercomUartCharSize Uart::extractCharSize(uint16_t config) +{ + switch(config & SERIAL_DATA_MASK) + { + case SERIAL_DATA_5: + return UART_CHAR_SIZE_5_BITS; + + case SERIAL_DATA_6: + return UART_CHAR_SIZE_6_BITS; + + case SERIAL_DATA_7: + return UART_CHAR_SIZE_7_BITS; + + case SERIAL_DATA_8: + default: + return UART_CHAR_SIZE_8_BITS; + + } +} + +SercomParityMode Uart::extractParity(uint16_t config) +{ + switch(config & SERIAL_PARITY_MASK) + { + case SERIAL_PARITY_NONE: + default: + return SERCOM_NO_PARITY; + + case SERIAL_PARITY_EVEN: + return SERCOM_EVEN_PARITY; + + case SERIAL_PARITY_ODD: + return SERCOM_ODD_PARITY; + } +} diff --git a/cores/arduino/Uart.h b/cores/arduino/Uart.h new file mode 100644 index 0000000..8f2e812 --- /dev/null +++ b/cores/arduino/Uart.h @@ -0,0 +1,70 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#pragma once + +#include "api/HardwareSerial.h" +#include "SERCOM.h" +#include "SafeRingBuffer.h" + +#ifdef SERIAL_BUFFER_SIZE +#undef SERIAL_BUFFER_SIZE +#endif + +#define SERIAL_BUFFER_SIZE 256 + +class Uart : public arduino::HardwareSerial +{ + public: + Uart(SERCOM *_s, uint8_t _pinRX, uint8_t _pinTX, SercomRXPad _padRX, SercomUartTXPad _padTX); + Uart(SERCOM *_s, uint8_t _pinRX, uint8_t _pinTX, SercomRXPad _padRX, SercomUartTXPad _padTX, uint8_t _pinRTS, uint8_t _pinCTS); + void begin(unsigned long baudRate); + void begin(unsigned long baudrate, uint16_t config); + void end(); + int available(); + int availableForWrite(); + int peek(); + int read(); + void flush(); + size_t write(const uint8_t data); + using Print::write; // pull in write(str) and write(buf, size) from Print + + void IrqHandler(); + + operator bool() { return true; } + + private: + SERCOM *sercom; + + arduino::SafeRingBufferN rxBuffer; + arduino::SafeRingBufferN txBuffer; + + uint8_t uc_pinRX; + uint8_t uc_pinTX; + SercomRXPad uc_padRX; + SercomUartTXPad uc_padTX; + uint8_t uc_pinRTS; + volatile uint32_t* pul_outsetRTS; + volatile uint32_t* pul_outclrRTS; + uint32_t ul_pinMaskRTS; + uint8_t uc_pinCTS; + + SercomNumberStopBit extractNbStopBit(uint16_t config); + SercomUartCharSize extractCharSize(uint16_t config); + SercomParityMode extractParity(uint16_t config); +}; diff --git a/cores/arduino/Udp.h b/cores/arduino/Udp.h new file mode 100644 index 0000000..89f31c6 --- /dev/null +++ b/cores/arduino/Udp.h @@ -0,0 +1,89 @@ +/* + * Udp.cpp: Library to send/receive UDP packets. + * + * NOTE: UDP is fast, but has some important limitations (thanks to Warren Gray for mentioning these) + * 1) UDP does not guarantee the order in which assembled UDP packets are received. This + * might not happen often in practice, but in larger network topologies, a UDP + * packet can be received out of sequence. + * 2) UDP does not guard against lost packets - so packets *can* disappear without the sender being + * aware of it. Again, this may not be a concern in practice on small local networks. + * For more information, see http://www.cafeaulait.org/course/week12/35.html + * + * MIT License: + * Copyright (c) 2008 Bjoern Hartmann + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + * + * bjoern@cs.stanford.edu 12/30/2008 + */ + +#ifndef udp_h +#define udp_h + +#include +#include + +class UDP : public Stream { + +public: + virtual uint8_t begin(uint16_t) =0; // initialize, start listening on specified port. Returns 1 if successful, 0 if there are no sockets available to use + virtual uint8_t beginMulticast(IPAddress, uint16_t) { return 0; } // initialize, start listening on specified multicast IP address and port. Returns 1 if successful, 0 on failure + virtual void stop() =0; // Finish with the UDP socket + + // Sending UDP packets + + // Start building up a packet to send to the remote host specific in ip and port + // Returns 1 if successful, 0 if there was a problem with the supplied IP address or port + virtual int beginPacket(IPAddress ip, uint16_t port) =0; + // Start building up a packet to send to the remote host specific in host and port + // Returns 1 if successful, 0 if there was a problem resolving the hostname or port + virtual int beginPacket(const char *host, uint16_t port) =0; + // Finish off this packet and send it + // Returns 1 if the packet was sent successfully, 0 if there was an error + virtual int endPacket() =0; + // Write a single byte into the packet + virtual size_t write(uint8_t) =0; + // Write size bytes from buffer into the packet + virtual size_t write(const uint8_t *buffer, size_t size) =0; + + // Start processing the next available incoming packet + // Returns the size of the packet in bytes, or 0 if no packets are available + virtual int parsePacket() =0; + // Number of bytes remaining in the current packet + virtual int available() =0; + // Read a single byte from the current packet + virtual int read() =0; + // Read up to len bytes from the current packet and place them into buffer + // Returns the number of bytes read, or 0 if none are available + virtual int read(unsigned char* buffer, size_t len) =0; + // Read up to len characters from the current packet and place them into buffer + // Returns the number of characters read, or 0 if none are available + virtual int read(char* buffer, size_t len) =0; + // Return the next byte from the current packet without moving on to the next byte + virtual int peek() =0; + virtual void flush() =0; // Finish reading the current packet + + // Return the IP address of the host who sent the current incoming packet + virtual IPAddress remoteIP() =0; + // Return the port of the host who sent the current incoming packet + virtual uint16_t remotePort() =0; +protected: + uint8_t* rawIPAddress(IPAddress& addr) { return addr.raw_address(); }; +}; + +#endif diff --git a/cores/arduino/WInterrupts.c b/cores/arduino/WInterrupts.c new file mode 100644 index 0000000..9b542a2 --- /dev/null +++ b/cores/arduino/WInterrupts.c @@ -0,0 +1,199 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#include "Arduino.h" +#include "wiring_private.h" + +#include + +static voidFuncPtr ISRcallback[EXTERNAL_NUM_INTERRUPTS]; +static uint32_t ISRlist[EXTERNAL_NUM_INTERRUPTS]; +static uint32_t nints; // Stores total number of attached interrupts + +/* Configure I/O interrupt sources */ +static void __initialize() +{ + memset(ISRlist, 0, sizeof(ISRlist)); + memset(ISRcallback, 0, sizeof(ISRcallback)); + nints = 0; + + NVIC_DisableIRQ(EIC_IRQn); + NVIC_ClearPendingIRQ(EIC_IRQn); + NVIC_SetPriority(EIC_IRQn, 0); + NVIC_EnableIRQ(EIC_IRQn); + + // Enable GCLK for IEC (External Interrupt Controller) + GCLK->CLKCTRL.reg = (uint16_t) (GCLK_CLKCTRL_CLKEN | GCLK_CLKCTRL_GEN_GCLK0 | GCLK_CLKCTRL_ID(GCM_EIC)); + +/* Shall we do that? + // Do a software reset on EIC + EIC->CTRL.SWRST.bit = 1 ; + while ((EIC->CTRL.SWRST.bit == 1) && (EIC->STATUS.SYNCBUSY.bit == 1)) { } +*/ + + // Enable EIC + EIC->CTRL.bit.ENABLE = 1; + while (EIC->STATUS.bit.SYNCBUSY == 1) { } +} + +/* + * \brief Specifies a named Interrupt Service Routine (ISR) to call when an interrupt occurs. + * Replaces any previous function that was attached to the interrupt. + */ +void attachInterrupt(pin_size_t pin, voidFuncPtr callback, PinStatus mode) +{ + static int enabled = 0; + uint32_t config; + uint32_t pos; + +#if ARDUINO_SAMD_VARIANT_COMPLIANCE >= 10606 + EExt_Interrupts in = g_APinDescription[pin].ulExtInt; +#else + EExt_Interrupts in = digitalPinToInterrupt(pin); +#endif + if (in == NOT_AN_INTERRUPT || in == EXTERNAL_INT_NMI) + return; + + if (!enabled) { + __initialize(); + enabled = 1; + } + + // Enable wakeup capability on pin in case being used during sleep + uint32_t inMask = 1 << in; + EIC->WAKEUP.reg |= inMask; + + // Assign pin to EIC + pinPeripheral(pin, PIO_EXTINT); + + // Only store when there is really an ISR to call. + // This allow for calling attachInterrupt(pin, NULL, mode), we set up all needed register + // but won't service the interrupt, this way we also don't need to check it inside the ISR. + if (callback) + { + // Store interrupts to service in order of when they were attached + // to allow for first come first serve handler + uint32_t current = 0; + + // Check if we already have this interrupt + for (current=0; current EXTERNAL_INT_7) { + config = 1; + pos = (in - 8) << 2; + } else { + config = 0; + pos = in << 2; + } + + // Configure the interrupt mode + EIC->CONFIG[config].reg &=~ (EIC_CONFIG_SENSE0_Msk << pos); // Reset sense mode, important when changing trigger mode during runtime + switch (mode) + { + case LOW: + EIC->CONFIG[config].reg |= EIC_CONFIG_SENSE0_LOW_Val << pos; + break; + + case HIGH: + EIC->CONFIG[config].reg |= EIC_CONFIG_SENSE0_HIGH_Val << pos; + break; + + case CHANGE: + EIC->CONFIG[config].reg |= EIC_CONFIG_SENSE0_BOTH_Val << pos; + break; + + case FALLING: + EIC->CONFIG[config].reg |= EIC_CONFIG_SENSE0_FALL_Val << pos; + break; + + case RISING: + EIC->CONFIG[config].reg |= EIC_CONFIG_SENSE0_RISE_Val << pos; + break; + } + } + // Enable the interrupt + EIC->INTENSET.reg = EIC_INTENSET_EXTINT(inMask); +} + +/* + * \brief Turns off the given interrupt. + */ +void detachInterrupt(pin_size_t pin) +{ +#if (ARDUINO_SAMD_VARIANT_COMPLIANCE >= 10606) + EExt_Interrupts in = g_APinDescription[pin].ulExtInt; +#else + EExt_Interrupts in = digitalPinToInterrupt(pin); +#endif + if (in == NOT_AN_INTERRUPT || in == EXTERNAL_INT_NMI) + return; + + uint32_t inMask = 1 << in; + EIC->INTENCLR.reg = EIC_INTENCLR_EXTINT(inMask); + + // Disable wakeup capability on pin during sleep + EIC->WAKEUP.reg &= ~inMask; + + // Remove callback from the ISR list + uint32_t current; + for (current=0; currentINTFLAG.reg & ISRlist[i]) != 0) + { + // Call the callback function + ISRcallback[i](); + // Clear the interrupt + EIC->INTFLAG.reg = ISRlist[i]; + } + } +} diff --git a/cores/arduino/WMath.cpp b/cores/arduino/WMath.cpp new file mode 100644 index 0000000..2c6cdc3 --- /dev/null +++ b/cores/arduino/WMath.cpp @@ -0,0 +1,52 @@ +/* + 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 +*/ + +extern "C" { + #include "stdlib.h" + #include "stdint.h" +} + +void randomSeed( uint32_t dwSeed ) +{ + if ( dwSeed != 0 ) + { + srand( dwSeed ) ; + } +} + +long random( long howbig ) +{ + if ( howbig == 0 ) + { + return 0 ; + } + + return rand() % howbig; +} + +long random( long howsmall, long howbig ) +{ + if (howsmall >= howbig) + { + return howsmall; + } + + long diff = howbig - howsmall; + + return random(diff) + howsmall; +} diff --git a/cores/arduino/WVariant.h b/cores/arduino/WVariant.h new file mode 100644 index 0000000..d44a0e2 --- /dev/null +++ b/cores/arduino/WVariant.h @@ -0,0 +1,257 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#pragma once + +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +/* Definitions and types for pins */ +typedef enum _EAnalogChannel +{ + No_ADC_Channel=-1, + ADC_Channel0=0, + ADC_Channel1=1, + ADC_Channel2=2, + ADC_Channel3=3, + ADC_Channel4=4, + ADC_Channel5=5, + ADC_Channel6=6, + ADC_Channel7=7, +#if defined __SAMD21J18A__ + ADC_Channel8=8, + ADC_Channel9=9, +#endif // __SAMD21J18A__ + ADC_Channel10=10, + ADC_Channel11=11, +#if defined __SAMD21J18A__ + ADC_Channel12=12, + ADC_Channel13=13, + ADC_Channel14=14, + ADC_Channel15=15, +#endif // __SAMD21J18A__ + ADC_Channel16=16, + ADC_Channel17=17, + ADC_Channel18=18, + ADC_Channel19=19, + DAC_Channel0, +} EAnalogChannel ; + +// Definitions for TC channels +typedef enum _ETCChannel +{ + NOT_ON_TIMER=-1, + TCC0_CH0 = (0<<8)|(0), + TCC0_CH1 = (0<<8)|(1), + TCC0_CH2 = (0<<8)|(2), + TCC0_CH3 = (0<<8)|(3), + TCC0_CH4 = (0<<8)|(0), // Channel 4 is 0! + TCC0_CH5 = (0<<8)|(1), // Channel 5 is 1! + TCC0_CH6 = (0<<8)|(2), // Channel 6 is 2! + TCC0_CH7 = (0<<8)|(3), // Channel 7 is 3! + TCC1_CH0 = (1<<8)|(0), + TCC1_CH1 = (1<<8)|(1), + TCC1_CH2 = (1<<8)|(0), // Channel 2 is 0! + TCC1_CH3 = (1<<8)|(1), // Channel 3 is 1! + TCC2_CH0 = (2<<8)|(0), + TCC2_CH1 = (2<<8)|(1), + TCC2_CH2 = (2<<8)|(0), // Channel 2 is 0! + TCC2_CH3 = (2<<8)|(1), // Channel 3 is 1! + TC3_CH0 = (3<<8)|(0), + TC3_CH1 = (3<<8)|(1), + TC4_CH0 = (4<<8)|(0), + TC4_CH1 = (4<<8)|(1), + TC5_CH0 = (5<<8)|(0), + TC5_CH1 = (5<<8)|(1), +#if defined __SAMD21J18A__ + TC6_CH0 = (6<<8)|(0), + TC6_CH1 = (6<<8)|(1), + TC7_CH0 = (7<<8)|(0), + TC7_CH1 = (7<<8)|(1), +#endif // __SAMD21J18A__ +} ETCChannel ; + +extern const void* g_apTCInstances[TCC_INST_NUM+TC_INST_NUM] ; + +#define GetTCNumber( x ) ( (x) >> 8 ) +#define GetTCChannelNumber( x ) ( (x) & 0xff ) +#define GetTC( x ) ( g_apTCInstances[(x) >> 8] ) + +// Definitions for PWM channels +typedef enum _EPWMChannel +{ + NOT_ON_PWM=-1, + PWM0_CH0=TCC0_CH0, + PWM0_CH1=TCC0_CH1, + PWM0_CH2=TCC0_CH2, + PWM0_CH3=TCC0_CH3, + PWM0_CH4=TCC0_CH4, + PWM0_CH5=TCC0_CH5, + PWM0_CH6=TCC0_CH6, + PWM0_CH7=TCC0_CH7, + PWM1_CH0=TCC1_CH0, + PWM1_CH1=TCC1_CH1, + PWM1_CH2=TCC1_CH2, + PWM1_CH3=TCC1_CH3, + PWM2_CH0=TCC2_CH0, + PWM2_CH1=TCC2_CH1, + PWM2_CH2=TCC2_CH2, + PWM2_CH3=TCC2_CH3, + PWM3_CH0=TC3_CH0, + PWM3_CH1=TC3_CH1, + PWM4_CH0=TC4_CH0, + PWM4_CH1=TC4_CH1, + PWM5_CH0=TC5_CH0, + PWM5_CH1=TC5_CH1, +#if defined __SAMD21J18A__ + PWM6_CH0=TC6_CH0, + PWM6_CH1=TC6_CH1, + PWM7_CH0=TC7_CH0, + PWM7_CH1=TC7_CH1, +#endif // __SAMD21J18A__ +} EPWMChannel ; + +typedef enum _EPortType +{ + NOT_A_PORT=-1, + PORTA=0, + PORTB=1, + PORTC=2, +} EPortType ; + +typedef enum +{ + EXTERNAL_INT_0 = 0, + EXTERNAL_INT_1, + EXTERNAL_INT_2, + EXTERNAL_INT_3, + EXTERNAL_INT_4, + EXTERNAL_INT_5, + EXTERNAL_INT_6, + EXTERNAL_INT_7, + EXTERNAL_INT_8, + EXTERNAL_INT_9, + EXTERNAL_INT_10, + EXTERNAL_INT_11, + EXTERNAL_INT_12, + EXTERNAL_INT_13, + EXTERNAL_INT_14, + EXTERNAL_INT_15, + EXTERNAL_INT_NMI, + EXTERNAL_NUM_INTERRUPTS, + NOT_AN_INTERRUPT = -1, + EXTERNAL_INT_NONE = NOT_AN_INTERRUPT, +} EExt_Interrupts ; + +//A B C D E F G H +//EIC REF ADC AC PTC DAC SERCOM SERCOM_ALT TC/TCC TCC COM AC/GCLK + +typedef enum _EPioType +{ + PIO_NOT_A_PIN=-1, /* Not under control of a peripheral. */ + PIO_EXTINT=0, /* The pin is controlled by the associated signal of peripheral A. */ + PIO_ANALOG, /* The pin is controlled by the associated signal of peripheral B. */ + PIO_SERCOM, /* The pin is controlled by the associated signal of peripheral C. */ + PIO_SERCOM_ALT, /* The pin is controlled by the associated signal of peripheral D. */ + PIO_TIMER, /* The pin is controlled by the associated signal of peripheral E. */ + PIO_TIMER_ALT, /* The pin is controlled by the associated signal of peripheral F. */ + PIO_COM, /* The pin is controlled by the associated signal of peripheral G. */ + PIO_AC_CLK, /* The pin is controlled by the associated signal of peripheral H. */ + PIO_DIGITAL, /* The pin is controlled by PORT. */ + PIO_INPUT, /* The pin is controlled by PORT and is an input. */ + PIO_INPUT_PULLUP, /* The pin is controlled by PORT and is an input with internal pull-up resistor enabled. */ + PIO_OUTPUT, /* The pin is controlled by PORT and is an output. */ + + PIO_PWM=PIO_TIMER, + PIO_PWM_ALT=PIO_TIMER_ALT, +} EPioType ; + +/** + * Pin Attributes to be OR-ed + */ +#define PIN_ATTR_NONE (0UL<<0) +#define PIN_ATTR_COMBO (1UL<<0) +#define PIN_ATTR_ANALOG (1UL<<1) +#define PIN_ATTR_DIGITAL (1UL<<2) +#define PIN_ATTR_PWM (1UL<<3) +#define PIN_ATTR_TIMER (1UL<<4) +#define PIN_ATTR_TIMER_ALT (1UL<<5) +#define PIN_ATTR_EXTINT (1UL<<6) + +/* Types used for the table below */ +typedef struct _PinDescription +{ + EPortType ulPort ; + uint32_t ulPin ; + EPioType ulPinType ; + uint32_t ulPinAttribute ; + EAnalogChannel ulADCChannelNumber ; /* ADC Channel number in the SAM device */ + EPWMChannel ulPWMChannel ; + ETCChannel ulTCChannel ; + EExt_Interrupts ulExtInt ; +} PinDescription ; + +/* Pins table to be instantiated into variant.cpp */ +extern const PinDescription g_APinDescription[] ; + +/* Generic Clock Multiplexer IDs */ +#define GCM_DFLL48M_REF (0x00U) +#define GCM_FDPLL96M_INPUT (0x01U) +#define GCM_FDPLL96M_32K (0x02U) +#define GCM_WDT (0x03U) +#define GCM_RTC (0x04U) +#define GCM_EIC (0x05U) +#define GCM_USB (0x06U) +#define GCM_EVSYS_CHANNEL_0 (0x07U) +#define GCM_EVSYS_CHANNEL_1 (0x08U) +#define GCM_EVSYS_CHANNEL_2 (0x09U) +#define GCM_EVSYS_CHANNEL_3 (0x0AU) +#define GCM_EVSYS_CHANNEL_4 (0x0BU) +#define GCM_EVSYS_CHANNEL_5 (0x0CU) +#define GCM_EVSYS_CHANNEL_6 (0x0DU) +#define GCM_EVSYS_CHANNEL_7 (0x0EU) +#define GCM_EVSYS_CHANNEL_8 (0x0FU) +#define GCM_EVSYS_CHANNEL_9 (0x10U) +#define GCM_EVSYS_CHANNEL_10 (0x11U) +#define GCM_EVSYS_CHANNEL_11 (0x12U) +#define GCM_SERCOMx_SLOW (0x13U) +#define GCM_SERCOM0_CORE (0x14U) +#define GCM_SERCOM1_CORE (0x15U) +#define GCM_SERCOM2_CORE (0x16U) +#define GCM_SERCOM3_CORE (0x17U) +#define GCM_SERCOM4_CORE (0x18U) +#define GCM_SERCOM5_CORE (0x19U) +#define GCM_TCC0_TCC1 (0x1AU) +#define GCM_TCC2_TC3 (0x1BU) +#define GCM_TC4_TC5 (0x1CU) +#define GCM_TC6_TC7 (0x1DU) +#define GCM_ADC (0x1EU) +#define GCM_AC_DIG (0x1FU) +#define GCM_AC_ANA (0x20U) +#define GCM_DAC (0x21U) +#define GCM_PTC (0x22U) +#define GCM_I2S_0 (0x23U) +#define GCM_I2S_1 (0x24U) + +#ifdef __cplusplus +} // extern "C" +#endif diff --git a/cores/arduino/abi.cpp b/cores/arduino/abi.cpp new file mode 100644 index 0000000..bd2f43a --- /dev/null +++ b/cores/arduino/abi.cpp @@ -0,0 +1,37 @@ +/* + Copyright (c) 2014 Arduino LLC. 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 +*/ + +#include + +extern "C" void __cxa_pure_virtual(void) __attribute__ ((__noreturn__)); +extern "C" void __cxa_deleted_virtual(void) __attribute__ ((__noreturn__)); + +void __cxa_pure_virtual(void) { + // We might want to write some diagnostics to uart in this case + //std::terminate(); + while (1) + ; +} + +void __cxa_deleted_virtual(void) { + // We might want to write some diagnostics to uart in this case + //std::terminate(); + while (1) + ; +} + diff --git a/cores/arduino/compact/dtostrf.c b/cores/arduino/compact/dtostrf.c new file mode 100644 index 0000000..c0d62ab --- /dev/null +++ b/cores/arduino/compact/dtostrf.c @@ -0,0 +1 @@ +#include "../api/deprecated-avr-comp/avr/dtostrf.c.impl" \ No newline at end of file diff --git a/cores/arduino/cortex_handlers.c b/cores/arduino/cortex_handlers.c new file mode 100644 index 0000000..e125b6e --- /dev/null +++ b/cores/arduino/cortex_handlers.c @@ -0,0 +1,188 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#include +#include +#include + +/* RTOS Hooks */ +extern void svcHook(void); +extern void pendSVHook(void); +extern int sysTickHook(void); + +/* Default empty handler */ +void Dummy_Handler(void) +{ +#if defined DEBUG + __BKPT(3); +#endif + for (;;) { } +} + +/* Cortex-M0+ core handlers */ +void HardFault_Handler(void) __attribute__ ((weak, alias("Dummy_Handler"))); +void Reset_Handler (void); +void NMI_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void SVC_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void PendSV_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void SysTick_Handler (void); + +/* Peripherals handlers */ +void PM_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void SYSCTRL_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void WDT_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void RTC_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void EIC_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void NVMCTRL_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void DMAC_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void USB_Handler (void) __attribute__ ((weak)); +void EVSYS_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void SERCOM0_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void SERCOM1_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void SERCOM2_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void SERCOM3_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void SERCOM4_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void SERCOM5_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void TCC0_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void TCC1_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void TCC2_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void TC3_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void TC4_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void TC5_Handler (void) __attribute__ ((weak)); // Used in Tone.cpp +void TC6_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void TC7_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void ADC_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void AC_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void DAC_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void PTC_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); +void I2S_Handler (void) __attribute__ ((weak, alias("Dummy_Handler"))); + +/* Initialize segments */ +extern uint32_t __etext; +extern uint32_t __data_start__; +extern uint32_t __data_end__; +extern uint32_t __bss_start__; +extern uint32_t __bss_end__; +extern uint32_t __StackTop; + +/* Exception Table */ +__attribute__ ((section(".isr_vector"))) const DeviceVectors exception_table = +{ + /* Configure Initial Stack Pointer, using linker-generated symbols */ + (void*) (&__StackTop), + + (void*) Reset_Handler, + (void*) NMI_Handler, + (void*) HardFault_Handler, + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) SVC_Handler, + (void*) (0UL), /* Reserved */ + (void*) (0UL), /* Reserved */ + (void*) PendSV_Handler, + (void*) SysTick_Handler, + + /* Configurable interrupts */ + (void*) PM_Handler, /* 0 Power Manager */ + (void*) SYSCTRL_Handler, /* 1 System Control */ + (void*) WDT_Handler, /* 2 Watchdog Timer */ + (void*) RTC_Handler, /* 3 Real-Time Counter */ + (void*) EIC_Handler, /* 4 External Interrupt Controller */ + (void*) NVMCTRL_Handler, /* 5 Non-Volatile Memory Controller */ + (void*) DMAC_Handler, /* 6 Direct Memory Access Controller */ + (void*) USB_Handler, /* 7 Universal Serial Bus */ + (void*) EVSYS_Handler, /* 8 Event System Interface */ + (void*) SERCOM0_Handler, /* 9 Serial Communication Interface 0 */ + (void*) SERCOM1_Handler, /* 10 Serial Communication Interface 1 */ + (void*) SERCOM2_Handler, /* 11 Serial Communication Interface 2 */ + (void*) SERCOM3_Handler, /* 12 Serial Communication Interface 3 */ + (void*) SERCOM4_Handler, /* 13 Serial Communication Interface 4 */ + (void*) SERCOM5_Handler, /* 14 Serial Communication Interface 5 */ + (void*) TCC0_Handler, /* 15 Timer Counter Control 0 */ + (void*) TCC1_Handler, /* 16 Timer Counter Control 1 */ + (void*) TCC2_Handler, /* 17 Timer Counter Control 2 */ + (void*) TC3_Handler, /* 18 Basic Timer Counter 0 */ + (void*) TC4_Handler, /* 19 Basic Timer Counter 1 */ + (void*) TC5_Handler, /* 20 Basic Timer Counter 2 */ + (void*) TC6_Handler, /* 21 Basic Timer Counter 3 */ + (void*) TC7_Handler, /* 22 Basic Timer Counter 4 */ + (void*) ADC_Handler, /* 23 Analog Digital Converter */ + (void*) AC_Handler, /* 24 Analog Comparators */ + (void*) DAC_Handler, /* 25 Digital Analog Converter */ + (void*) PTC_Handler, /* 26 Peripheral Touch Controller */ + (void*) I2S_Handler, /* 27 Inter-IC Sound Interface */ + (void*) (0UL), /* Reserved */ +}; + +extern int main(void); + +/* This is called on processor reset to initialize the device and call main() */ +void Reset_Handler(void) +{ + uint32_t *pSrc, *pDest; + + /* Initialize the initialized data section */ + pSrc = &__etext; + pDest = &__data_start__; + + if ((&__data_start__ != &__data_end__) && (pSrc != pDest)) { + for (; pDest < &__data_end__; pDest++, pSrc++) + *pDest = *pSrc; + } + + /* Clear the zero section */ + if ((&__data_start__ != &__data_end__) && (pSrc != pDest)) { + for (pDest = &__bss_start__; pDest < &__bss_end__; pDest++) + *pDest = 0; + } + + SystemInit(); + + main(); + + while (1) + ; +} + +/* Default Arduino systick handler */ +extern void SysTick_DefaultHandler(void); + +void SysTick_Handler(void) +{ + if (sysTickHook()) + return; + SysTick_DefaultHandler(); +} + +static void (*usb_isr)(void) = NULL; + +void USB_Handler(void) +{ + if (usb_isr) + usb_isr(); +} + +void USB_SetHandler(void (*new_usb_isr)(void)) +{ + usb_isr = new_usb_isr; +} diff --git a/cores/arduino/delay.c b/cores/arduino/delay.c new file mode 100644 index 0000000..bf6db0e --- /dev/null +++ b/cores/arduino/delay.c @@ -0,0 +1,135 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#include "Arduino.h" + +#ifdef __cplusplus +extern "C" { +#endif + +/** Tick Counter united by ms */ +static volatile uint32_t _ulTickCount=0 ; + +unsigned long millis( void ) +{ +// todo: ensure no interrupts + return _ulTickCount ; +} + +// Interrupt-compatible version of micros +// Theory: repeatedly take readings of SysTick counter, millis counter and SysTick interrupt pending flag. +// When it appears that millis counter and pending is stable and SysTick hasn't rolled over, use these +// values to calculate micros. If there is a pending SysTick, add one to the millis counter in the calculation. +unsigned long micros( void ) +{ + uint32_t ticks, ticks2; + uint32_t pend, pend2; + uint32_t count, count2; + + ticks2 = SysTick->VAL; + pend2 = !!(SCB->ICSR & SCB_ICSR_PENDSTSET_Msk) ; + count2 = _ulTickCount ; + + do + { + ticks=ticks2; + pend=pend2; + count=count2; + ticks2 = SysTick->VAL; + pend2 = !!(SCB->ICSR & SCB_ICSR_PENDSTSET_Msk) ; + count2 = _ulTickCount ; + } while ((pend != pend2) || (count != count2) || (ticks < ticks2)); + + return ((count+pend) * 1000) + (((SysTick->LOAD - ticks)*(1048576/(VARIANT_MCK/1000000)))>>20) ; + // this is an optimization to turn a runtime division into two compile-time divisions and + // a runtime multiplication and shift, saving a few cycles +} + +void delay( unsigned long ms ) +{ + if (ms == 0) + { + return; + } + + uint32_t start = micros(); + + while (ms > 0) + { + yield(); + while (ms > 0 && (micros() - start) >= 1000) + { + ms--; + start += 1000; + } + } +} + +#include "Reset.h" // for tickReset() + +void SysTick_DefaultHandler(void) +{ + // Increment tick count each ms + _ulTickCount++; + tickReset(); +} + +/** + * \brief Pauses the program for the amount of time (in microseconds) specified as parameter. + * + * \param dwUs the number of microseconds to pause (uint32_t) + */ +void delayMicroseconds( unsigned int usec ) +{ + if ( usec == 0 ) + { + return ; + } + + /* + * The following loop: + * + * for (; ul; ul--) { + * __asm__ volatile(""); + * } + * + * produce the following assembly code: + * + * loop: + * subs r3, #1 // 1 Core cycle + * bne.n loop // 1 Core cycle + 1 if branch is taken + */ + + // VARIANT_MCK / 1000000 == cycles needed to delay 1uS + // 3 == cycles used in a loop + uint32_t n = usec * (VARIANT_MCK / 1000000) / 3; + __asm__ __volatile__( + "1: \n" + " sub %0, #1 \n" // substract 1 from %0 (n) + " bne 1b \n" // if result is not 0 jump to 1 + : "+r" (n) // '%0' is n variable with RW constraints + : // no input + : // no clobber + ); + // https://gcc.gnu.org/onlinedocs/gcc/Extended-Asm.html + // https://gcc.gnu.org/onlinedocs/gcc/Extended-Asm.html#Volatile +} + +#ifdef __cplusplus +} +#endif diff --git a/cores/arduino/hooks.c b/cores/arduino/hooks.c new file mode 100644 index 0000000..f87c204 --- /dev/null +++ b/cores/arduino/hooks.c @@ -0,0 +1,58 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +/** + * Empty yield() hook. + * + * This function is intended to be used by library writers to build + * libraries or sketches that supports cooperative threads. + * + * Its defined as a weak symbol and it can be redefined to implement a + * real cooperative scheduler. + */ +static void __empty() { + // Empty +} +void yield(void) __attribute__ ((weak, alias("__empty"))); + +/** + * SysTick hook + * + * This function is called from SysTick handler, before the default + * handler provided by Arduino. + */ +static int __false() { + // Return false + return 0; +} +int sysTickHook(void) __attribute__ ((weak, alias("__false"))); + +/** + * SVC hook + * PendSV hook + * + * These functions are called from SVC handler, and PensSV handler. + * Default action is halting. + */ +static void __halt() { + // Halts + while (1) + ; +} +void svcHook(void) __attribute__ ((weak, alias("__halt"))); +void pendSVHook(void) __attribute__ ((weak, alias("__halt"))); diff --git a/cores/arduino/itoa.c b/cores/arduino/itoa.c new file mode 100644 index 0000000..fb468dc --- /dev/null +++ b/cores/arduino/itoa.c @@ -0,0 +1,125 @@ +/* + Copyright (c) 2014 Arduino LLC. 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 +*/ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +char* ltoa( long value, char *string, int radix ) +{ + char tmp[33]; + char *tp = tmp; + long i; + unsigned long v; + int sign; + char *sp; + + if ( string == NULL ) + { + return 0 ; + } + + if (radix > 36 || radix <= 1) + { + return 0 ; + } + + sign = (radix == 10 && value < 0); + if (sign) + { + v = -value; + } + else + { + v = (unsigned long)value; + } + + while (v || tp == tmp) + { + i = v % radix; + v = v / radix; + if (i < 10) + *tp++ = i+'0'; + else + *tp++ = i + 'a' - 10; + } + + sp = string; + + if (sign) + *sp++ = '-'; + while (tp > tmp) + *sp++ = *--tp; + *sp = 0; + + return string; +} + +char* ultoa( unsigned long value, char *string, int radix ) +{ + char tmp[33]; + char *tp = tmp; + long i; + unsigned long v = value; + char *sp; + + if ( string == NULL ) + { + return 0; + } + + if (radix > 36 || radix <= 1) + { + return 0; + } + + while (v || tp == tmp) + { + i = v % radix; + v = v / radix; + if (i < 10) + *tp++ = i+'0'; + else + *tp++ = i + 'a' - 10; + } + + sp = string; + + + while (tp > tmp) + *sp++ = *--tp; + *sp = 0; + + return string; +} + +char* itoa( int value, char *string, int radix ) +{ + return ltoa( value, string, radix ) ; +} + +char* utoa( unsigned int value, char *string, int radix ) +{ + return ultoa( value, string, radix ) ; +} + +#ifdef __cplusplus +} // extern "C" +#endif diff --git a/cores/arduino/main.cpp b/cores/arduino/main.cpp new file mode 100644 index 0000000..a6d2cb5 --- /dev/null +++ b/cores/arduino/main.cpp @@ -0,0 +1,58 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#define ARDUINO_MAIN +#include "Arduino.h" + +// Weak empty variant initialization function. +// May be redefined by variant files. +void initVariant() __attribute__((weak)); +void initVariant() { } + +extern USBDeviceClass USBDevice; + +// Initialize C library +extern "C" void __libc_init_array(void); + +/* + * \brief Main entry point of Arduino application + */ +int main( void ) +{ + init(); + + __libc_init_array(); + + initVariant(); + + delay(1); +#if defined(USBCON) + USBDevice.init(); + USBDevice.attach(); +#endif + + setup(); + + for (;;) + { + loop(); + if (arduino::serialEventRun) arduino::serialEventRun(); + } + + return 0; +} diff --git a/cores/arduino/new.cpp b/cores/arduino/new.cpp new file mode 100644 index 0000000..f189775 --- /dev/null +++ b/cores/arduino/new.cpp @@ -0,0 +1,36 @@ +/* + 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 +*/ + +#include + +void *operator new(size_t size) { + return malloc(size); +} + +void *operator new[](size_t size) { + return malloc(size); +} + +void operator delete(void * ptr) { + free(ptr); +} + +void operator delete[](void * ptr) { + free(ptr); +} + diff --git a/cores/arduino/pulse.c b/cores/arduino/pulse.c new file mode 100644 index 0000000..89bdf68 --- /dev/null +++ b/cores/arduino/pulse.c @@ -0,0 +1,52 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#include + +// See pulse_asm.S +extern unsigned long countPulseASM(const volatile uint32_t *port, uint32_t bit, uint32_t stateMask, unsigned long maxloops); + +/* Measures the length (in microseconds) of a pulse on the pin; state is HIGH + * or LOW, the type of pulse to measure. Works on pulses from 2-3 microseconds + * to 3 minutes in length, but must be called at least a few dozen microseconds + * before the start of the pulse. */ +uint32_t pulseIn(pin_size_t pin, uint8_t state, uint32_t timeout) +{ + // cache the port and bit of the pin in order to speed up the + // pulse width measuring loop and achieve finer resolution. calling + // digitalRead() instead yields much coarser resolution. + PinDescription p = g_APinDescription[pin]; + uint32_t bit = 1 << p.ulPin; + uint32_t stateMask = state ? bit : 0; + + // convert the timeout from microseconds to a number of times through + // the initial loop; it takes (roughly) 13 clock cycles per iteration. + uint32_t maxloops = microsecondsToClockCycles(timeout) / 13; + + uint32_t width = countPulseASM(&(PORT->Group[p.ulPort].IN.reg), bit, stateMask, maxloops); + + // convert the reading to microseconds. The loop has been determined + // to be 13 clock cycles long and have about 16 clocks between the edge + // and the start of the loop. There will be some error introduced by + // the interrupt handlers. + if (width) + return clockCyclesToMicroseconds(width * 13 + 16); + else + return 0; +} + diff --git a/cores/arduino/pulse_asm.S b/cores/arduino/pulse_asm.S new file mode 100644 index 0000000..7b94f15 --- /dev/null +++ b/cores/arduino/pulse_asm.S @@ -0,0 +1,175 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +/* + +The following function has been compiled to ASM with gcc + + unsigned long countPulseASM(const volatile uint32_t *port, uint32_t bit, uint32_t stateMask, unsigned long maxloops) + { + unsigned long width = 0; + + // wait for any previous pulse to end + while ((*port & bit) == stateMask) + if (--maxloops == 0) + return 0; + + // wait for the pulse to start + while ((*port & bit) != stateMask) + if (--maxloops == 0) + return 0; + + // wait for the pulse to stop + while ((*port & bit) == stateMask) { + if (++width == maxloops) + return 0; + } + return width; + } + +using the command line: + + arm-none-eabi-gcc -mcpu=cortex-m0plus -mthumb -c -Os -W -ffunction-sections -fdata-sections \ + -nostdlib --param max-inline-insns-single=500 -fno-exceptions -MMD \ + -DF_CPU=48000000L -DARDUINO=10602 -DARDUINO_SAMD_ZERO -DARDUINO_ARCH_SAMD \ + -D__SAMD21G18A__ -DUSB_VID=0x2341 -DUSB_PID=0x004d -DUSBCON \ + -DUSB_MANUFACTURER="Arduino LLC" -DUSB_PRODUCT="Arduino Zero" \ + -I/Code/arduino/build/linux/work/hardware/tools/CMSIS/CMSIS/Include/ \ + -I/Code/arduino/build/linux/work/hardware/tools/CMSIS/Device/ATMEL/ \ + -I/Code/arduino/build/linux/work/hardware/arduino/samd/cores/arduino \ + -I/Code/arduino/build/linux/work/hardware/arduino/samd/variants/arduino_zero \ + count.c -Wa,-ahlmsd=output.lst -dp -fverbose-asm -S + +The result has been slightly edited to increase readability. + +*/ + + .cpu cortex-m0plus + .fpu softvfp + .eabi_attribute 20, 1 @ Tag_ABI_FP_denormal + .eabi_attribute 21, 1 @ Tag_ABI_FP_exceptions + .eabi_attribute 23, 3 @ Tag_ABI_FP_number_model + .eabi_attribute 24, 1 @ Tag_ABI_align8_needed + .eabi_attribute 25, 1 @ Tag_ABI_align8_preserved + .eabi_attribute 26, 1 @ Tag_ABI_enum_size + .eabi_attribute 30, 4 @ Tag_ABI_optimization_goals + .eabi_attribute 34, 0 @ Tag_CPU_unaligned_access + .eabi_attribute 18, 4 @ Tag_ABI_PCS_wchar_t + .file "count.c" +@ GNU C (GNU Tools for ARM Embedded Processors (Arduino build)) version 4.8.3 20140228 (release) [ARM/embedded-4_8-branch revision 208322] (arm-none-eabi) +@ compiled by GNU C version 4.3.2, GMP version 4.3.2, MPFR version 2.4.2, MPC version 0.8.1 +@ GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072 +@ options passed: +@ -I /Code/arduino/build/linux/work/hardware/tools/CMSIS/CMSIS/Include/ +@ -I /Code/arduino/build/linux/work/hardware/tools/CMSIS/Device/ATMEL/ +@ -I /Code/arduino/build/linux/work/hardware/arduino/samd/cores/arduino +@ -I /Code/arduino/build/linux/work/hardware/arduino/samd/variants/arduino_zero +@ -imultilib armv6-m +@ -iprefix /Code/arduino/build/linux/work/hardware/tools/gcc-arm-none-eabi-4.8.3-2014q1/bin/../lib/gcc/arm-none-eabi/4.8.3/ +@ -isysroot /Code/arduino/build/linux/work/hardware/tools/gcc-arm-none-eabi-4.8.3-2014q1/bin/../arm-none-eabi +@ -MMD count.d -D__USES_INITFINI__ -D F_CPU=48000000L -D ARDUINO=10602 +@ -D ARDUINO_SAMD_ZERO -D ARDUINO_ARCH_SAMD -D __SAMD21G18A__ +@ -D USB_VID=0x2341 -D USB_PID=0x004d -D USBCON +@ -D USB_MANUFACTURER=Arduino LLC -D USB_PRODUCT=Arduino Zero count.c +@ -mcpu=cortex-m0plus -mthumb -Os -Wextra -ffunction-sections +@ -fdata-sections -fno-exceptions -fverbose-asm +@ --param max-inline-insns-single=500 +@ options enabled: -faggressive-loop-optimizations -fauto-inc-dec +@ -fbranch-count-reg -fcaller-saves -fcombine-stack-adjustments -fcommon +@ -fcompare-elim -fcprop-registers -fcrossjumping -fcse-follow-jumps +@ -fdata-sections -fdefer-pop -fdelete-null-pointer-checks -fdevirtualize +@ -fdwarf2-cfi-asm -fearly-inlining -feliminate-unused-debug-types +@ -fexpensive-optimizations -fforward-propagate -ffunction-cse +@ -ffunction-sections -fgcse -fgcse-lm -fgnu-runtime +@ -fguess-branch-probability -fhoist-adjacent-loads -fident -fif-conversion +@ -fif-conversion2 -findirect-inlining -finline -finline-atomics +@ -finline-functions -finline-functions-called-once +@ -finline-small-functions -fipa-cp -fipa-profile -fipa-pure-const +@ -fipa-reference -fipa-sra -fira-hoist-pressure -fira-share-save-slots +@ -fira-share-spill-slots -fivopts -fkeep-static-consts +@ -fleading-underscore -fmath-errno -fmerge-constants -fmerge-debug-strings +@ -fomit-frame-pointer -foptimize-register-move -foptimize-sibling-calls +@ -fpartial-inlining -fpeephole -fpeephole2 -fprefetch-loop-arrays +@ -freg-struct-return -fregmove -freorder-blocks -freorder-functions +@ -frerun-cse-after-loop -fsched-critical-path-heuristic +@ -fsched-dep-count-heuristic -fsched-group-heuristic -fsched-interblock +@ -fsched-last-insn-heuristic -fsched-pressure -fsched-rank-heuristic +@ -fsched-spec -fsched-spec-insn-heuristic -fsched-stalled-insns-dep +@ -fschedule-insns2 -fsection-anchors -fshow-column -fshrink-wrap +@ -fsigned-zeros -fsplit-ivs-in-unroller -fsplit-wide-types +@ -fstrict-aliasing -fstrict-overflow -fstrict-volatile-bitfields +@ -fsync-libcalls -fthread-jumps -ftoplevel-reorder -ftrapping-math +@ -ftree-bit-ccp -ftree-builtin-call-dce -ftree-ccp -ftree-ch +@ -ftree-coalesce-vars -ftree-copy-prop -ftree-copyrename -ftree-cselim +@ -ftree-dce -ftree-dominator-opts -ftree-dse -ftree-forwprop -ftree-fre +@ -ftree-loop-if-convert -ftree-loop-im -ftree-loop-ivcanon +@ -ftree-loop-optimize -ftree-parallelize-loops= -ftree-phiprop -ftree-pre +@ -ftree-pta -ftree-reassoc -ftree-scev-cprop -ftree-sink +@ -ftree-slp-vectorize -ftree-slsr -ftree-sra -ftree-switch-conversion +@ -ftree-tail-merge -ftree-ter -ftree-vect-loop-version -ftree-vrp +@ -funit-at-a-time -fverbose-asm -fzero-initialized-in-bss -mlittle-endian +@ -mpic-data-is-text-relative -msched-prolog -mthumb +@ -mvectorize-with-neon-quad + + .section .text.countPulseASM,"ax",%progbits + .align 1 + .global countPulseASM + .code 16 + .thumb_func + .type countPulseASM, %function +countPulseASM: + push {r4, r5, lr} @ @ 112 *push_multi [length = 2] +.L2: + ldr r4, [r0] @ D.11539, *port_7(D) @ 22 *thumb1_movsi_insn/7 [length = 2] + and r4, r1 @ D.11539, bit @ 24 *thumb1_andsi3_insn [length = 2] + cmp r4, r2 @ D.11539, stateMask @ 25 cbranchsi4_insn/1 [length = 4] + bne .L5 @, + sub r3, r3, #1 @ maxloops, @ 17 *thumb1_addsi3/2 [length = 2] + cmp r3, #0 @ maxloops, @ 18 cbranchsi4_insn/1 [length = 4] + bne .L2 @, + b .L10 @ @ 127 *thumb_jump [length = 2] +.L6: + sub r3, r3, #1 @ maxloops, @ 30 *thumb1_addsi3/2 [length = 2] + cmp r3, #0 @ maxloops, @ 31 cbranchsi4_insn/1 [length = 4] + beq .L10 @, +.L5: + ldr r4, [r0] @ D.11539, *port_7(D) @ 35 *thumb1_movsi_insn/7 [length = 2] + and r4, r1 @ D.11539, bit @ 37 *thumb1_andsi3_insn [length = 2] + cmp r4, r2 @ D.11539, stateMask @ 38 cbranchsi4_insn/1 [length = 4] + bne .L6 @, + mov r4, #0 @ width, @ 7 *thumb1_movsi_insn/2 [length = 2] +.L7: + ldr r5, [r0] @ D.11539, *port_7(D) @ 48 *thumb1_movsi_insn/7 [length = 2] + and r5, r1 @ D.11539, bit @ 50 *thumb1_andsi3_insn [length = 2] + cmp r5, r2 @ D.11539, stateMask @ 51 cbranchsi4_insn/1 [length = 4] + bne .L13 @, + add r4, r4, #1 @ width, @ 43 *thumb1_addsi3/1 [length = 2] + cmp r4, r3 @ width, maxloops @ 44 cbranchsi4_insn/1 [length = 4] + bne .L7 @, + mov r0, #0 @ D.11539, @ 11 *thumb1_movsi_insn/2 [length = 2] + b .L3 @ @ 130 *thumb_jump [length = 2] +.L13: + mov r0, r4 @ D.11539, width @ 9 *thumb1_movsi_insn/1 [length = 2] + b .L3 @ @ 132 *thumb_jump [length = 2] +.L10: + mov r0, r3 @ D.11539, maxloops @ 8 *thumb1_movsi_insn/1 [length = 2] +.L3: + @ sp needed @ @ 115 force_register_use [length = 0] + pop {r4, r5, pc} + .size countPulseASM, .-countPulseASM + .ident "GCC: (GNU Tools for ARM Embedded Processors (Arduino build)) 4.8.3 20140228 (release) [ARM/embedded-4_8-branch revision 208322]" diff --git a/cores/arduino/startup.c b/cores/arduino/startup.c new file mode 100644 index 0000000..3f990ab --- /dev/null +++ b/cores/arduino/startup.c @@ -0,0 +1,301 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#include +#include "variant.h" + +#include + +/** + * \brief SystemInit() configures the needed clocks and according Flash Read Wait States. + * At reset: + * - OSC8M clock source is enabled with a divider by 8 (1MHz). + * - Generic Clock Generator 0 (GCLKMAIN) is using OSC8M as source. + * We need to: + * 1) Enable XOSC32K clock (External on-board 32.768Hz oscillator), will be used as DFLL48M reference. + * 2) Put XOSC32K as source of Generic Clock Generator 1 + * 3) Put Generic Clock Generator 1 as source for Generic Clock Multiplexer 0 (DFLL48M reference) + * 4) Enable DFLL48M clock + * 5) Switch Generic Clock Generator 0 to DFLL48M. CPU will run at 48MHz. + * 6) Modify PRESCaler value of OSCM to have 8MHz + * 7) Put OSC8M as source for Generic Clock Generator 3 + */ +// Constants for Clock generators +#define GENERIC_CLOCK_GENERATOR_MAIN (0u) +#define GENERIC_CLOCK_GENERATOR_XOSC32K (1u) +#define GENERIC_CLOCK_GENERATOR_OSC32K (1u) +#define GENERIC_CLOCK_GENERATOR_OSCULP32K (2u) /* Initialized at reset for WDT */ +#define GENERIC_CLOCK_GENERATOR_OSC8M (3u) +// Constants for Clock multiplexers +#define GENERIC_CLOCK_MULTIPLEXER_DFLL48M (0u) + +void SystemInit( void ) +{ + /* Set 1 Flash Wait State for 48MHz, cf tables 20.9 and 35.27 in SAMD21 Datasheet */ + NVMCTRL->CTRLB.bit.RWS = NVMCTRL_CTRLB_RWS_HALF_Val ; + + /* Turn on the digital interface clock */ + PM->APBAMASK.reg |= PM_APBAMASK_GCLK ; + + +#if defined(CRYSTALLESS) + + /* ---------------------------------------------------------------------------------------------- + * 1) Enable OSC32K clock (Internal 32.768Hz oscillator) + */ + + uint32_t calib = (*((uint32_t *) FUSES_OSC32K_CAL_ADDR) & FUSES_OSC32K_CAL_Msk) >> FUSES_OSC32K_CAL_Pos; + + SYSCTRL->OSC32K.reg = SYSCTRL_OSC32K_CALIB(calib) | + SYSCTRL_OSC32K_STARTUP( 0x6u ) | // cf table 15.10 of product datasheet in chapter 15.8.6 + SYSCTRL_OSC32K_EN32K | + SYSCTRL_OSC32K_ENABLE; + + while ( (SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_OSC32KRDY) == 0 ); // Wait for oscillator stabilization + +#else // has crystal + + /* ---------------------------------------------------------------------------------------------- + * 1) Enable XOSC32K clock (External on-board 32.768Hz oscillator) + */ + SYSCTRL->XOSC32K.reg = SYSCTRL_XOSC32K_STARTUP( 0x6u ) | /* cf table 15.10 of product datasheet in chapter 15.8.6 */ + SYSCTRL_XOSC32K_XTALEN | SYSCTRL_XOSC32K_EN32K ; + SYSCTRL->XOSC32K.bit.ENABLE = 1 ; /* separate call, as described in chapter 15.6.3 */ + + while ( (SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_XOSC32KRDY) == 0 ) + { + /* Wait for oscillator stabilization */ + } + +#endif + + /* Software reset the module to ensure it is re-initialized correctly */ + /* Note: Due to synchronization, there is a delay from writing CTRL.SWRST until the reset is complete. + * CTRL.SWRST and STATUS.SYNCBUSY will both be cleared when the reset is complete, as described in chapter 13.8.1 + */ + GCLK->CTRL.reg = GCLK_CTRL_SWRST ; + + while ( (GCLK->CTRL.reg & GCLK_CTRL_SWRST) && (GCLK->STATUS.reg & GCLK_STATUS_SYNCBUSY) ) + { + /* Wait for reset to complete */ + } + + /* ---------------------------------------------------------------------------------------------- + * 2) Put XOSC32K as source of Generic Clock Generator 1 + */ + GCLK->GENDIV.reg = GCLK_GENDIV_ID( GENERIC_CLOCK_GENERATOR_XOSC32K ) ; // Generic Clock Generator 1 + + while ( GCLK->STATUS.reg & GCLK_STATUS_SYNCBUSY ) + { + /* Wait for synchronization */ + } + + /* Write Generic Clock Generator 1 configuration */ + GCLK->GENCTRL.reg = GCLK_GENCTRL_ID( GENERIC_CLOCK_GENERATOR_OSC32K ) | // Generic Clock Generator 1 +#if defined(CRYSTALLESS) + GCLK_GENCTRL_SRC_OSC32K | // Selected source is Internal 32KHz Oscillator +#else + GCLK_GENCTRL_SRC_XOSC32K | // Selected source is External 32KHz Oscillator +#endif +// GCLK_GENCTRL_OE | // Output clock to a pin for tests + GCLK_GENCTRL_GENEN ; + + while ( GCLK->STATUS.reg & GCLK_STATUS_SYNCBUSY ) + { + /* Wait for synchronization */ + } + + /* ---------------------------------------------------------------------------------------------- + * 3) Put Generic Clock Generator 1 as source for Generic Clock Multiplexer 0 (DFLL48M reference) + */ + GCLK->CLKCTRL.reg = GCLK_CLKCTRL_ID( GENERIC_CLOCK_MULTIPLEXER_DFLL48M ) | // Generic Clock Multiplexer 0 + GCLK_CLKCTRL_GEN_GCLK1 | // Generic Clock Generator 1 is source + GCLK_CLKCTRL_CLKEN ; + + while ( GCLK->STATUS.reg & GCLK_STATUS_SYNCBUSY ) + { + /* Wait for synchronization */ + } + + /* ---------------------------------------------------------------------------------------------- + * 4) Enable DFLL48M clock + */ + + /* DFLL Configuration in Closed Loop mode, cf product datasheet chapter 15.6.7.1 - Closed-Loop Operation */ + + /* Remove the OnDemand mode, Bug http://avr32.icgroup.norway.atmel.com/bugzilla/show_bug.cgi?id=9905 */ + SYSCTRL->DFLLCTRL.reg = SYSCTRL_DFLLCTRL_ENABLE; + + while ( (SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_DFLLRDY) == 0 ) + { + /* Wait for synchronization */ + } + + SYSCTRL->DFLLMUL.reg = SYSCTRL_DFLLMUL_CSTEP( 31 ) | // Coarse step is 31, half of the max value + SYSCTRL_DFLLMUL_FSTEP( 511 ) | // Fine step is 511, half of the max value + SYSCTRL_DFLLMUL_MUL( (VARIANT_MCK + VARIANT_MAINOSC/2) / VARIANT_MAINOSC ) ; // External 32KHz is the reference + + while ( (SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_DFLLRDY) == 0 ) + { + /* Wait for synchronization */ + } + +#if defined(CRYSTALLESS) + + #define NVM_SW_CALIB_DFLL48M_COARSE_VAL 58 + + // Turn on DFLL + uint32_t coarse =( *((uint32_t *)(NVMCTRL_OTP4) + (NVM_SW_CALIB_DFLL48M_COARSE_VAL / 32)) >> (NVM_SW_CALIB_DFLL48M_COARSE_VAL % 32) ) + & ((1 << 6) - 1); + if (coarse == 0x3f) { + coarse = 0x1f; + } + // TODO(tannewt): Load this value from memory we've written previously. There + // isn't a value from the Atmel factory. + uint32_t fine = 0x1ff; + + SYSCTRL->DFLLVAL.bit.COARSE = coarse; + SYSCTRL->DFLLVAL.bit.FINE = fine; + /* Write full configuration to DFLL control register */ + SYSCTRL->DFLLMUL.reg = SYSCTRL_DFLLMUL_CSTEP( 0x1f / 4 ) | // Coarse step is 31, half of the max value + SYSCTRL_DFLLMUL_FSTEP( 10 ) | + SYSCTRL_DFLLMUL_MUL( (48000) ) ; + + SYSCTRL->DFLLCTRL.reg = 0; + + while ( (SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_DFLLRDY) == 0 ) + { + /* Wait for synchronization */ + } + + SYSCTRL->DFLLCTRL.reg = SYSCTRL_DFLLCTRL_MODE | + SYSCTRL_DFLLCTRL_CCDIS | + SYSCTRL_DFLLCTRL_USBCRM | /* USB correction */ + SYSCTRL_DFLLCTRL_BPLCKC; + + while ( (SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_DFLLRDY) == 0 ) + { + /* Wait for synchronization */ + } + + /* Enable the DFLL */ + SYSCTRL->DFLLCTRL.reg |= SYSCTRL_DFLLCTRL_ENABLE ; + +#else // has crystal + + /* Write full configuration to DFLL control register */ + SYSCTRL->DFLLCTRL.reg |= SYSCTRL_DFLLCTRL_MODE | /* Enable the closed loop mode */ + SYSCTRL_DFLLCTRL_WAITLOCK | + SYSCTRL_DFLLCTRL_QLDIS ; /* Disable Quick lock */ + + while ( (SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_DFLLRDY) == 0 ) + { + /* Wait for synchronization */ + } + + /* Enable the DFLL */ + SYSCTRL->DFLLCTRL.reg |= SYSCTRL_DFLLCTRL_ENABLE ; + + while ( (SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_DFLLLCKC) == 0 || + (SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_DFLLLCKF) == 0 ) + { + /* Wait for locks flags */ + } + +#endif + + while ( (SYSCTRL->PCLKSR.reg & SYSCTRL_PCLKSR_DFLLRDY) == 0 ) + { + /* Wait for synchronization */ + } + + /* ---------------------------------------------------------------------------------------------- + * 5) Switch Generic Clock Generator 0 to DFLL48M. CPU will run at 48MHz. + */ + GCLK->GENDIV.reg = GCLK_GENDIV_ID( GENERIC_CLOCK_GENERATOR_MAIN ) ; // Generic Clock Generator 0 + + while ( GCLK->STATUS.reg & GCLK_STATUS_SYNCBUSY ) + { + /* Wait for synchronization */ + } + + /* Write Generic Clock Generator 0 configuration */ + GCLK->GENCTRL.reg = GCLK_GENCTRL_ID( GENERIC_CLOCK_GENERATOR_MAIN ) | // Generic Clock Generator 0 + GCLK_GENCTRL_SRC_DFLL48M | // Selected source is DFLL 48MHz +// GCLK_GENCTRL_OE | // Output clock to a pin for tests + GCLK_GENCTRL_IDC | // Set 50/50 duty cycle + GCLK_GENCTRL_GENEN ; + + while ( GCLK->STATUS.reg & GCLK_STATUS_SYNCBUSY ) + { + /* Wait for synchronization */ + } + + /* ---------------------------------------------------------------------------------------------- + * 6) Modify PRESCaler value of OSC8M to have 8MHz + */ + SYSCTRL->OSC8M.bit.PRESC = SYSCTRL_OSC8M_PRESC_0_Val ; //CMSIS 4.5 changed the prescaler defines + SYSCTRL->OSC8M.bit.ONDEMAND = 0 ; + + /* ---------------------------------------------------------------------------------------------- + * 7) Put OSC8M as source for Generic Clock Generator 3 + */ + GCLK->GENDIV.reg = GCLK_GENDIV_ID( GENERIC_CLOCK_GENERATOR_OSC8M ) ; // Generic Clock Generator 3 + + /* Write Generic Clock Generator 3 configuration */ + GCLK->GENCTRL.reg = GCLK_GENCTRL_ID( GENERIC_CLOCK_GENERATOR_OSC8M ) | // Generic Clock Generator 3 + GCLK_GENCTRL_SRC_OSC8M | // Selected source is RC OSC 8MHz (already enabled at reset) +// GCLK_GENCTRL_OE | // Output clock to a pin for tests + GCLK_GENCTRL_GENEN ; + + while ( GCLK->STATUS.reg & GCLK_STATUS_SYNCBUSY ) + { + /* Wait for synchronization */ + } + + /* + * Now that all system clocks are configured, we can set CPU and APBx BUS clocks. + * There values are normally the one present after Reset. + */ + PM->CPUSEL.reg = PM_CPUSEL_CPUDIV_DIV1 ; + PM->APBASEL.reg = PM_APBASEL_APBADIV_DIV1_Val ; + PM->APBBSEL.reg = PM_APBBSEL_APBBDIV_DIV1_Val ; + PM->APBCSEL.reg = PM_APBCSEL_APBCDIV_DIV1_Val ; + + SystemCoreClock=VARIANT_MCK ; + + /* ---------------------------------------------------------------------------------------------- + * 8) Load ADC factory calibration values + */ + + // ADC Bias Calibration + uint32_t bias = (*((uint32_t *) ADC_FUSES_BIASCAL_ADDR) & ADC_FUSES_BIASCAL_Msk) >> ADC_FUSES_BIASCAL_Pos; + + // ADC Linearity bits 4:0 + uint32_t linearity = (*((uint32_t *) ADC_FUSES_LINEARITY_0_ADDR) & ADC_FUSES_LINEARITY_0_Msk) >> ADC_FUSES_LINEARITY_0_Pos; + + // ADC Linearity bits 7:5 + linearity |= ((*((uint32_t *) ADC_FUSES_LINEARITY_1_ADDR) & ADC_FUSES_LINEARITY_1_Msk) >> ADC_FUSES_LINEARITY_1_Pos) << 5; + + ADC->CALIB.reg = ADC_CALIB_BIAS_CAL(bias) | ADC_CALIB_LINEARITY_CAL(linearity); + + /* + * 9) Disable automatic NVM write operations + */ + NVMCTRL->CTRLB.bit.MANW = 1; +} diff --git a/cores/arduino/sync.h b/cores/arduino/sync.h new file mode 100644 index 0000000..2750a29 --- /dev/null +++ b/cores/arduino/sync.h @@ -0,0 +1,30 @@ +#include + +#ifndef _SYNC_H_ +#define _SYNC_H_ +/* + * Synchronization primitives. + * TODO: Move into a separate header file and make an API out of it + */ + +class __Guard { +public: + __Guard() : primask(__get_PRIMASK()), loops(1) { + __disable_irq(); + } + ~__Guard() { + if (primask == 0) { + __enable_irq(); + // http://infocenter.arm.com/help/topic/com.arm.doc.dai0321a/BIHBFEIB.html + __ISB(); + } + } + uint32_t enter() { return loops--; } +private: + uint32_t primask; + uint32_t loops; +}; + +#define synchronized for (__Guard __guard; __guard.enter(); ) + +#endif \ No newline at end of file diff --git a/cores/arduino/wiring.c b/cores/arduino/wiring.c new file mode 100644 index 0000000..894e91b --- /dev/null +++ b/cores/arduino/wiring.c @@ -0,0 +1,132 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#include "Arduino.h" + +#ifdef __cplusplus +extern "C" { +#endif + +/* + * System Core Clock is at 1MHz (8MHz/8) at Reset. + * It is switched to 48MHz in the Reset Handler (startup.c) + */ +uint32_t SystemCoreClock=1000000ul ; + +/* +void calibrateADC() +{ + volatile uint32_t valeur = 0; + + for(int i = 0; i < 5; ++i) + { + ADC->SWTRIG.bit.START = 1; + while( ADC->INTFLAG.bit.RESRDY == 0 || ADC->STATUS.bit.SYNCBUSY == 1 ) + { + // Waiting for a complete conversion and complete synchronization + } + + valeur += ADC->RESULT.bit.RESULT; + } + + valeur = valeur/5; +}*/ + +/* + * Arduino Zero board initialization + * + * Good to know: + * - At reset, ResetHandler did the system clock configuration. Core is running at 48MHz. + * - Watchdog is disabled by default, unless someone plays with NVM User page + * - During reset, all PORT lines are configured as inputs with input buffers, output buffers and pull disabled. + */ +void init( void ) +{ + // Set Systick to 1ms interval, common to all Cortex-M variants + if ( SysTick_Config( SystemCoreClock / 1000 ) ) + { + // Capture error + while ( 1 ) ; + } + NVIC_SetPriority (SysTick_IRQn, (1 << __NVIC_PRIO_BITS) - 2); /* set Priority for Systick Interrupt (2nd lowest) */ + + // Clock PORT for Digital I/O +// PM->APBBMASK.reg |= PM_APBBMASK_PORT ; +// +// // Clock EIC for I/O interrupts +// PM->APBAMASK.reg |= PM_APBAMASK_EIC ; + + // Clock SERCOM for Serial + PM->APBCMASK.reg |= PM_APBCMASK_SERCOM0 | PM_APBCMASK_SERCOM1 | PM_APBCMASK_SERCOM2 | PM_APBCMASK_SERCOM3 | PM_APBCMASK_SERCOM4 | PM_APBCMASK_SERCOM5 ; + + // Clock TC/TCC for Pulse and Analog + PM->APBCMASK.reg |= PM_APBCMASK_TCC0 | PM_APBCMASK_TCC1 | PM_APBCMASK_TCC2 | PM_APBCMASK_TC3 | PM_APBCMASK_TC4 | PM_APBCMASK_TC5 ; + + // Clock ADC/DAC for Analog + PM->APBCMASK.reg |= PM_APBCMASK_ADC | PM_APBCMASK_DAC ; + +// Defining VERY_LOW_POWER breaks Arduino APIs since all pins are considered INPUT at startup +// However, it really lowers the power consumption by a factor of 20 in low power mode (0.03mA vs 0.6mA) +#ifndef VERY_LOW_POWER + // Setup all pins (digital and analog) in INPUT mode (default is nothing) + for (uint32_t ul = 0 ; ul < NUM_DIGITAL_PINS ; ul++ ) + { + pinMode( ul, INPUT ) ; + } +#endif + + // Initialize Analog Controller + // Setting clock + while(GCLK->STATUS.reg & GCLK_STATUS_SYNCBUSY); + + GCLK->CLKCTRL.reg = GCLK_CLKCTRL_ID( GCM_ADC ) | // Generic Clock ADC + GCLK_CLKCTRL_GEN_GCLK0 | // Generic Clock Generator 0 is source + GCLK_CLKCTRL_CLKEN ; + + while( ADC->STATUS.bit.SYNCBUSY == 1 ); // Wait for synchronization of registers between the clock domains + + ADC->CTRLB.reg = ADC_CTRLB_PRESCALER_DIV512 | // Divide Clock by 512. + ADC_CTRLB_RESSEL_10BIT; // 10 bits resolution as default + + ADC->SAMPCTRL.reg = 0x3f; // Set max Sampling Time Length + + while( ADC->STATUS.bit.SYNCBUSY == 1 ); // Wait for synchronization of registers between the clock domains + + ADC->INPUTCTRL.reg = ADC_INPUTCTRL_MUXNEG_GND; // No Negative input (Internal Ground) + + // Averaging (see datasheet table in AVGCTRL register description) + ADC->AVGCTRL.reg = ADC_AVGCTRL_SAMPLENUM_1 | // 1 sample only (no oversampling nor averaging) + ADC_AVGCTRL_ADJRES(0x0ul); // Adjusting result by 0 + + analogReference( AR_DEFAULT ) ; // Analog Reference is AREF pin (3.3v) + + // Initialize DAC + // Setting clock + while ( GCLK->STATUS.reg & GCLK_STATUS_SYNCBUSY ); + GCLK->CLKCTRL.reg = GCLK_CLKCTRL_ID( GCM_DAC ) | // Generic Clock ADC + GCLK_CLKCTRL_GEN_GCLK0 | // Generic Clock Generator 0 is source + GCLK_CLKCTRL_CLKEN ; + + while ( DAC->STATUS.bit.SYNCBUSY == 1 ); // Wait for synchronization of registers between the clock domains + DAC->CTRLB.reg = DAC_CTRLB_REFSEL_AVCC | // Using the 3.3V reference + DAC_CTRLB_EOEN ; // External Output Enable (Vout) +} + +#ifdef __cplusplus +} +#endif diff --git a/cores/arduino/wiring_analog.c b/cores/arduino/wiring_analog.c new file mode 100644 index 0000000..2476e01 --- /dev/null +++ b/cores/arduino/wiring_analog.c @@ -0,0 +1,321 @@ +/* + Copyright (c) 2014 Arduino LLC. 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 +*/ + +#include "Arduino.h" +#include "wiring_private.h" + +#ifdef __cplusplus +extern "C" { +#endif + +static int _readResolution = 10; +static int _ADCResolution = 10; +static int _writeResolution = 8; + +// Wait for synchronization of registers between the clock domains +static __inline__ void syncADC() __attribute__((always_inline, unused)); +static void syncADC() { + while (ADC->STATUS.bit.SYNCBUSY == 1) + ; +} + +// Wait for synchronization of registers between the clock domains +static __inline__ void syncDAC() __attribute__((always_inline, unused)); +static void syncDAC() { + while (DAC->STATUS.bit.SYNCBUSY == 1) + ; +} + +// Wait for synchronization of registers between the clock domains +static __inline__ void syncTC_16(Tc* TCx) __attribute__((always_inline, unused)); +static void syncTC_16(Tc* TCx) { + while (TCx->COUNT16.STATUS.bit.SYNCBUSY); +} + +// Wait for synchronization of registers between the clock domains +static __inline__ void syncTCC(Tcc* TCCx) __attribute__((always_inline, unused)); +static void syncTCC(Tcc* TCCx) { + while (TCCx->SYNCBUSY.reg & TCC_SYNCBUSY_MASK); +} + +void analogReadResolution(int res) +{ + _readResolution = res; + if (res > 10) { + ADC->CTRLB.bit.RESSEL = ADC_CTRLB_RESSEL_12BIT_Val; + _ADCResolution = 12; + } else if (res > 8) { + ADC->CTRLB.bit.RESSEL = ADC_CTRLB_RESSEL_10BIT_Val; + _ADCResolution = 10; + } else { + ADC->CTRLB.bit.RESSEL = ADC_CTRLB_RESSEL_8BIT_Val; + _ADCResolution = 8; + } + syncADC(); +} + +void analogWriteResolution(int res) +{ + _writeResolution = res; +} + +static inline uint32_t mapResolution(uint32_t value, uint32_t from, uint32_t to) +{ + if (from == to) { + return value; + } + if (from > to) { + return value >> (from-to); + } + return value << (to-from); +} + +/* + * Internal Reference is at 1.0v + * External Reference should be between 1v and VDDANA-0.6v=2.7v + * + * Warning : On Arduino Zero board the input/output voltage for SAMD21G18 is 3.3 volts maximum + */ +void analogReference(eAnalogReference mode) +{ + syncADC(); + switch (mode) + { + case AR_INTERNAL: + case AR_INTERNAL2V23: + ADC->INPUTCTRL.bit.GAIN = ADC_INPUTCTRL_GAIN_1X_Val; // Gain Factor Selection + ADC->REFCTRL.bit.REFSEL = ADC_REFCTRL_REFSEL_INTVCC0_Val; // 1/1.48 VDDANA = 1/1.48* 3V3 = 2.2297 + break; + + case AR_EXTERNAL: + ADC->INPUTCTRL.bit.GAIN = ADC_INPUTCTRL_GAIN_1X_Val; // Gain Factor Selection + ADC->REFCTRL.bit.REFSEL = ADC_REFCTRL_REFSEL_AREFA_Val; + break; + + case AR_INTERNAL1V0: + ADC->INPUTCTRL.bit.GAIN = ADC_INPUTCTRL_GAIN_1X_Val; // Gain Factor Selection + ADC->REFCTRL.bit.REFSEL = ADC_REFCTRL_REFSEL_INT1V_Val; // 1.0V voltage reference + break; + + case AR_INTERNAL1V65: + ADC->INPUTCTRL.bit.GAIN = ADC_INPUTCTRL_GAIN_1X_Val; // Gain Factor Selection + ADC->REFCTRL.bit.REFSEL = ADC_REFCTRL_REFSEL_INTVCC1_Val; // 1/2 VDDANA = 0.5* 3V3 = 1.65V + break; + + case AR_DEFAULT: + default: + ADC->INPUTCTRL.bit.GAIN = ADC_INPUTCTRL_GAIN_DIV2_Val; + ADC->REFCTRL.bit.REFSEL = ADC_REFCTRL_REFSEL_INTVCC1_Val; // 1/2 VDDANA = 0.5* 3V3 = 1.65V + break; + } +} + +int analogRead(pin_size_t pin) +{ + uint32_t valueRead = 0; + + if (pin < A0) { + pin += A0; + } + + pinPeripheral(pin, PIO_ANALOG); + + // Disable DAC, if analogWrite() was used previously to enable the DAC + if ((g_APinDescription[pin].ulADCChannelNumber == ADC_Channel0) || (g_APinDescription[pin].ulADCChannelNumber == DAC_Channel0)) { + syncDAC(); + DAC->CTRLA.bit.ENABLE = 0x00; // Disable DAC + //DAC->CTRLB.bit.EOEN = 0x00; // The DAC output is turned off. + syncDAC(); + } + + syncADC(); + ADC->INPUTCTRL.bit.MUXPOS = g_APinDescription[pin].ulADCChannelNumber; // Selection for the positive ADC input + + // Control A + /* + * Bit 1 ENABLE: Enable + * 0: The ADC is disabled. + * 1: The ADC is enabled. + * Due to synchronization, there is a delay from writing CTRLA.ENABLE until the peripheral is enabled/disabled. The + * value written to CTRL.ENABLE will read back immediately and the Synchronization Busy bit in the Status register + * (STATUS.SYNCBUSY) will be set. STATUS.SYNCBUSY will be cleared when the operation is complete. + * + * Before enabling the ADC, the asynchronous clock source must be selected and enabled, and the ADC reference must be + * configured. The first conversion after the reference is changed must not be used. + */ + syncADC(); + ADC->CTRLA.bit.ENABLE = 0x01; // Enable ADC + + // Start conversion + syncADC(); + ADC->SWTRIG.bit.START = 1; + + // Waiting for the 1st conversion to complete + while (ADC->INTFLAG.bit.RESRDY == 0); + + // Clear the Data Ready flag + ADC->INTFLAG.reg = ADC_INTFLAG_RESRDY; + + // Start conversion again, since The first conversion after the reference is changed must not be used. + syncADC(); + ADC->SWTRIG.bit.START = 1; + + // Store the value + while (ADC->INTFLAG.bit.RESRDY == 0); // Waiting for conversion to complete + valueRead = ADC->RESULT.reg; + + syncADC(); + ADC->CTRLA.bit.ENABLE = 0x00; // Disable ADC + syncADC(); + + return mapResolution(valueRead, _ADCResolution, _readResolution); +} + + +// Right now, PWM output only works on the pins with +// hardware support. These are defined in the appropriate +// pins_*.c file. For the rest of the pins, we default +// to digital output. +void analogWrite(pin_size_t pin, int value) +{ + PinDescription pinDesc = g_APinDescription[pin]; + uint32_t attr = pinDesc.ulPinAttribute; + + if ((attr & PIN_ATTR_ANALOG) == PIN_ATTR_ANALOG) + { + // DAC handling code + + if ((pinDesc.ulADCChannelNumber != ADC_Channel0) && (pinDesc.ulADCChannelNumber != DAC_Channel0)) { // Only 1 DAC on AIN0 / PA02 + return; + } + + value = mapResolution(value, _writeResolution, 10); + + syncDAC(); + DAC->DATA.reg = value & 0x3FF; // DAC on 10 bits. + syncDAC(); + DAC->CTRLA.bit.ENABLE = 0x01; // Enable DAC + syncDAC(); + return; + } + + if ((attr & PIN_ATTR_PWM) == PIN_ATTR_PWM) + { + value = mapResolution(value, _writeResolution, 16); + + uint32_t tcNum = GetTCNumber(pinDesc.ulPWMChannel); + uint8_t tcChannel = GetTCChannelNumber(pinDesc.ulPWMChannel); + static bool tcEnabled[TCC_INST_NUM+TC_INST_NUM]; + + if (attr & PIN_ATTR_TIMER) { + #if !(ARDUINO_SAMD_VARIANT_COMPLIANCE >= 10603) + // Compatibility for cores based on SAMD core <=1.6.2 + if (pinDesc.ulPinType == PIO_TIMER_ALT) { + pinPeripheral(pin, PIO_TIMER_ALT); + } else + #endif + { + pinPeripheral(pin, PIO_TIMER); + } + } else { + // We suppose that attr has PIN_ATTR_TIMER_ALT bit set... + pinPeripheral(pin, PIO_TIMER_ALT); + } + + if (!tcEnabled[tcNum]) { + tcEnabled[tcNum] = true; + + uint16_t GCLK_CLKCTRL_IDs[] = { + GCLK_CLKCTRL_ID(GCM_TCC0_TCC1), // TCC0 + GCLK_CLKCTRL_ID(GCM_TCC0_TCC1), // TCC1 + GCLK_CLKCTRL_ID(GCM_TCC2_TC3), // TCC2 + GCLK_CLKCTRL_ID(GCM_TCC2_TC3), // TC3 + GCLK_CLKCTRL_ID(GCM_TC4_TC5), // TC4 + GCLK_CLKCTRL_ID(GCM_TC4_TC5), // TC5 + GCLK_CLKCTRL_ID(GCM_TC6_TC7), // TC6 + GCLK_CLKCTRL_ID(GCM_TC6_TC7), // TC7 + }; + GCLK->CLKCTRL.reg = (uint16_t) (GCLK_CLKCTRL_CLKEN | GCLK_CLKCTRL_GEN_GCLK0 | GCLK_CLKCTRL_IDs[tcNum]); + while (GCLK->STATUS.bit.SYNCBUSY == 1); + + // Set PORT + if (tcNum >= TCC_INST_NUM) { + // -- Configure TC + Tc* TCx = (Tc*) GetTC(pinDesc.ulPWMChannel); + // Disable TCx + TCx->COUNT16.CTRLA.bit.ENABLE = 0; + syncTC_16(TCx); + // Set Timer counter Mode to 16 bits, normal PWM + TCx->COUNT16.CTRLA.reg |= TC_CTRLA_MODE_COUNT16 | TC_CTRLA_WAVEGEN_NPWM; + syncTC_16(TCx); + // Set the initial value + TCx->COUNT16.CC[tcChannel].reg = (uint32_t) value; + syncTC_16(TCx); + // Enable TCx + TCx->COUNT16.CTRLA.bit.ENABLE = 1; + syncTC_16(TCx); + } else { + // -- Configure TCC + Tcc* TCCx = (Tcc*) GetTC(pinDesc.ulPWMChannel); + // Disable TCCx + TCCx->CTRLA.bit.ENABLE = 0; + syncTCC(TCCx); + // Set TCCx as normal PWM + TCCx->WAVE.reg |= TCC_WAVE_WAVEGEN_NPWM; + syncTCC(TCCx); + // Set the initial value + TCCx->CC[tcChannel].reg = (uint32_t) value; + syncTCC(TCCx); + // Set PER to maximum counter value (resolution : 0xFFFF) + TCCx->PER.reg = 0xFFFF; + syncTCC(TCCx); + // Enable TCCx + TCCx->CTRLA.bit.ENABLE = 1; + syncTCC(TCCx); + } + } else { + if (tcNum >= TCC_INST_NUM) { + Tc* TCx = (Tc*) GetTC(pinDesc.ulPWMChannel); + TCx->COUNT16.CC[tcChannel].reg = (uint32_t) value; + syncTC_16(TCx); + } else { + Tcc* TCCx = (Tcc*) GetTC(pinDesc.ulPWMChannel); + TCCx->CTRLBSET.bit.LUPD = 1; + syncTCC(TCCx); + TCCx->CCB[tcChannel].reg = (uint32_t) value; + syncTCC(TCCx); + TCCx->CTRLBCLR.bit.LUPD = 1; + syncTCC(TCCx); + } + } + return; + } + + // -- Defaults to digital write + pinMode(pin, OUTPUT); + value = mapResolution(value, _writeResolution, 8); + if (value < 128) { + digitalWrite(pin, LOW); + } else { + digitalWrite(pin, HIGH); + } +} + +#ifdef __cplusplus +} +#endif diff --git a/cores/arduino/wiring_digital.c b/cores/arduino/wiring_digital.c new file mode 100644 index 0000000..f9d8b68 --- /dev/null +++ b/cores/arduino/wiring_digital.c @@ -0,0 +1,124 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#include "Arduino.h" + +#ifdef __cplusplus + extern "C" { +#endif + +void pinMode( pin_size_t ulPin, PinMode ulMode ) +{ + // Handle the case the pin isn't usable as PIO + if ( g_APinDescription[ulPin].ulPinType == PIO_NOT_A_PIN ) + { + return ; + } + + // Set pin mode according to chapter '22.6.3 I/O Pin Configuration' + switch ( ulMode ) + { + case INPUT: + // Set pin to input mode + PORT->Group[g_APinDescription[ulPin].ulPort].PINCFG[g_APinDescription[ulPin].ulPin].reg=(uint8_t)(PORT_PINCFG_INEN) ; + PORT->Group[g_APinDescription[ulPin].ulPort].DIRCLR.reg = (uint32_t)(1<Group[g_APinDescription[ulPin].ulPort].PINCFG[g_APinDescription[ulPin].ulPin].reg=(uint8_t)(PORT_PINCFG_INEN|PORT_PINCFG_PULLEN) ; + PORT->Group[g_APinDescription[ulPin].ulPort].DIRCLR.reg = (uint32_t)(1<Group[g_APinDescription[ulPin].ulPort].OUTSET.reg = (uint32_t)(1<Group[g_APinDescription[ulPin].ulPort].PINCFG[g_APinDescription[ulPin].ulPin].reg=(uint8_t)(PORT_PINCFG_INEN|PORT_PINCFG_PULLEN) ; + PORT->Group[g_APinDescription[ulPin].ulPort].DIRCLR.reg = (uint32_t)(1<Group[g_APinDescription[ulPin].ulPort].OUTCLR.reg = (uint32_t)(1<Group[g_APinDescription[ulPin].ulPort].PINCFG[g_APinDescription[ulPin].ulPin].reg=(uint8_t)(PORT_PINCFG_INEN) ; + + // Set pin to output mode + PORT->Group[g_APinDescription[ulPin].ulPort].DIRSET.reg = (uint32_t)(1<Group[port].DIRSET.reg & pinMask) == 0 ) { + // the pin is not an output, disable pull-up if val is LOW, otherwise enable pull-up + PORT->Group[port].PINCFG[pin].bit.PULLEN = ((ulVal == LOW) ? 0 : 1) ; + } + + switch ( ulVal ) + { + case LOW: + PORT->Group[port].OUTCLR.reg = pinMask; + break ; + + default: + PORT->Group[port].OUTSET.reg = pinMask; + break ; + } + + return ; +} + +PinStatus digitalRead( pin_size_t ulPin ) +{ + // Handle the case the pin isn't usable as PIO + if ( g_APinDescription[ulPin].ulPinType == PIO_NOT_A_PIN ) + { + return LOW ; + } + + if ( (PORT->Group[g_APinDescription[ulPin].ulPort].IN.reg & (1ul << g_APinDescription[ulPin].ulPin)) != 0 ) + { + return HIGH ; + } + + return LOW ; +} + +#ifdef __cplusplus +} +#endif + diff --git a/cores/arduino/wiring_private.c b/cores/arduino/wiring_private.c new file mode 100644 index 0000000..a5aaba4 --- /dev/null +++ b/cores/arduino/wiring_private.c @@ -0,0 +1,118 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#include "Arduino.h" +#include "wiring_private.h" + +int pinPeripheral( uint32_t ulPin, EPioType ulPeripheral ) +{ + // Handle the case the pin isn't usable as PIO + if ( g_APinDescription[ulPin].ulPinType == PIO_NOT_A_PIN ) + { + return -1 ; + } + + switch ( ulPeripheral ) + { + case PIO_DIGITAL: + case PIO_INPUT: + case PIO_INPUT_PULLUP: + case PIO_OUTPUT: + // Disable peripheral muxing, done in pinMode +// PORT->Group[g_APinDescription[ulPin].ulPort].PINCFG[g_APinDescription[ulPin].ulPin].bit.PMUXEN = 0 ; + + // Configure pin mode, if requested + if ( ulPeripheral == PIO_INPUT ) + { + pinMode( ulPin, INPUT ) ; + } + else + { + if ( ulPeripheral == PIO_INPUT_PULLUP ) + { + pinMode( ulPin, INPUT_PULLUP ) ; + } + else + { + if ( ulPeripheral == PIO_OUTPUT ) + { + pinMode( ulPin, OUTPUT ) ; + } + else + { + // PIO_DIGITAL, do we have to do something as all cases are covered? + } + } + } + break ; + + case PIO_ANALOG: + case PIO_SERCOM: + case PIO_SERCOM_ALT: + case PIO_TIMER: + case PIO_TIMER_ALT: + case PIO_EXTINT: + case PIO_COM: + case PIO_AC_CLK: +#if 0 + // Is the pio pin in the lower 16 ones? + // The WRCONFIG register allows update of only 16 pin max out of 32 + if ( g_APinDescription[ulPin].ulPin < 16 ) + { + PORT->Group[g_APinDescription[ulPin].ulPort].WRCONFIG.reg = PORT_WRCONFIG_WRPMUX | PORT_WRCONFIG_PMUXEN | PORT_WRCONFIG_PMUX( ulPeripheral ) | + PORT_WRCONFIG_WRPINCFG | + PORT_WRCONFIG_PINMASK( g_APinDescription[ulPin].ulPin ) ; + } + else + { + PORT->Group[g_APinDescription[ulPin].ulPort].WRCONFIG.reg = PORT_WRCONFIG_HWSEL | + PORT_WRCONFIG_WRPMUX | PORT_WRCONFIG_PMUXEN | PORT_WRCONFIG_PMUX( ulPeripheral ) | + PORT_WRCONFIG_WRPINCFG | + PORT_WRCONFIG_PINMASK( g_APinDescription[ulPin].ulPin - 16 ) ; + } +#else + if ( g_APinDescription[ulPin].ulPin & 1 ) // is pin odd? + { + uint32_t temp ; + + // Get whole current setup for both odd and even pins and remove odd one + temp = (PORT->Group[g_APinDescription[ulPin].ulPort].PMUX[g_APinDescription[ulPin].ulPin >> 1].reg) & PORT_PMUX_PMUXE( 0xF ) ; + // Set new muxing + PORT->Group[g_APinDescription[ulPin].ulPort].PMUX[g_APinDescription[ulPin].ulPin >> 1].reg = temp|PORT_PMUX_PMUXO( ulPeripheral ) ; + // Enable port mux + PORT->Group[g_APinDescription[ulPin].ulPort].PINCFG[g_APinDescription[ulPin].ulPin].reg |= PORT_PINCFG_PMUXEN ; + } + else // even pin + { + uint32_t temp ; + + temp = (PORT->Group[g_APinDescription[ulPin].ulPort].PMUX[g_APinDescription[ulPin].ulPin >> 1].reg) & PORT_PMUX_PMUXO( 0xF ) ; + PORT->Group[g_APinDescription[ulPin].ulPort].PMUX[g_APinDescription[ulPin].ulPin >> 1].reg = temp|PORT_PMUX_PMUXE( ulPeripheral ) ; + PORT->Group[g_APinDescription[ulPin].ulPort].PINCFG[g_APinDescription[ulPin].ulPin].reg |= PORT_PINCFG_PMUXEN ; // Enable port mux + } +#endif + break ; + + case PIO_NOT_A_PIN: + return -1l ; + break ; + } + + return 0l ; +} + diff --git a/cores/arduino/wiring_private.h b/cores/arduino/wiring_private.h new file mode 100644 index 0000000..a0fa152 --- /dev/null +++ b/cores/arduino/wiring_private.h @@ -0,0 +1,37 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#pragma once + +#include +#include +#include + +#ifdef __cplusplus +extern "C" { +#endif + +// Includes Atmel CMSIS +#include + +int pinPeripheral( uint32_t ulPin, EPioType ulPeripheral ); + +#ifdef __cplusplus +} // extern "C" + +#endif diff --git a/cores/arduino/wiring_shift.c b/cores/arduino/wiring_shift.c new file mode 100644 index 0000000..7a855ee --- /dev/null +++ b/cores/arduino/wiring_shift.c @@ -0,0 +1,73 @@ +/* + 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 +*/ + +#include +#include +#include "wiring_private.h" + +#ifdef __cplusplus +extern "C"{ +#endif + +uint8_t shiftIn( pin_size_t ulDataPin, pin_size_t ulClockPin, BitOrder ulBitOrder ) +{ + uint8_t value = 0 ; + uint8_t i ; + + for ( i=0 ; i < 8 ; ++i ) + { + digitalWrite( ulClockPin, HIGH ) ; + + if ( ulBitOrder == LSBFIRST ) + { + value |= digitalRead( ulDataPin ) << i ; + } + else + { + value |= digitalRead( ulDataPin ) << (7 - i) ; + } + + digitalWrite( ulClockPin, LOW ) ; + } + + return value ; +} + +void shiftOut( pin_size_t ulDataPin, pin_size_t ulClockPin, BitOrder ulBitOrder, uint8_t ulVal ) +{ + uint8_t i ; + + for ( i=0 ; i < 8 ; i++ ) + { + if ( ulBitOrder == LSBFIRST ) + { + digitalWrite( ulDataPin, !!(ulVal & (1 << i)) ) ; + } + else + { + digitalWrite( ulDataPin, !!(ulVal & (1 << (7 - i))) ) ; + } + + digitalWrite( ulClockPin, HIGH ) ; + digitalWrite( ulClockPin, LOW ) ; + } +} + +#ifdef __cplusplus +} // extern "C" +#endif diff --git a/drivers/arduino-samd.cat b/drivers/arduino-samd.cat new file mode 100755 index 0000000..872ccad Binary files /dev/null and b/drivers/arduino-samd.cat differ diff --git a/drivers/arduino-samd.inf b/drivers/arduino-samd.inf new file mode 100644 index 0000000..13ed0cc --- /dev/null +++ b/drivers/arduino-samd.inf @@ -0,0 +1,184 @@ +; +; Copyright 2017 Arduino AG (http://www.arduino.cc/) +; +; 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 (for SAMD boards)" +ManufacturerName="Arduino AG (www.arduino.cc)" +ServiceName="USB RS-232 Emulation Driver" +bossa.name="Bossa Program Port" +mkr1000.sketch.name="Arduino MKR1000" +mkr1000.bootloader.name="Arduino MKR1000 bootloader" +mkrfox.sketch.name="Arduino MKR FOX 1200" +mkrfox.bootloader.name="Arduino MKR FOX 1200 bootloader" +mkrgsm.sketch.name="Arduino MKR GSM 1400" +mkrgsm.bootloader.name="Arduino MKR GSM 1400 bootloader" +mkrzero.sketch.name="Arduino MKRZERO" +mkrzero.bootloader.name="Arduino MKRZERO bootloader" +mkrwan.sketch.name="Arduino MKR WAN 1300" +mkrwan.bootloader.name="Arduino MKR WAN 1300 bootloader" +mkrwan1310.sketch.name="Arduino MKR WAN 1310" +mkrwan1310.bootloader.name="Arduino MKR WAN 1310 bootloader" +mkrwifi1010.sketch.name="Arduino MKR WiFi 1010" +mkrwifi1010.bootloader.name="Arduino MKR WiFi 1010 bootloader" +mkrvidor4000.sketch.name="Arduino MKR Vidor 4000" +mkrvidor4000.bootloader.name="Arduino MKR Vidor 4000 bootloader" +mkrnb1500.sketch.name="Arduino MKR NB 1500" +mkrnb1500.bootloader.name="Arduino MKR NB 1500 bootloader" +nano33iot.sketch.name="Arduino NANO 33 IoT" +nano33iot.bootloader.name="Arduino NANO 33 IoT bootloader" +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-samd.inf + +[Version] +Class=Ports +ClassGuid={4D36E978-E325-11CE-BFC1-08002BE10318} +Signature="$Windows NT$" +Provider=%ManufacturerName% +DriverPackageDisplayName=%DriverPackageDisplayName% +CatalogFile=arduino-samd.cat +; DriverVer date is MM/DD/YYYY +DriverVer=07/08/2019,1.4.3.0 + +[Manufacturer] +%ManufacturerName%=DeviceList, NTamd64, NTia64 + +[DestinationDirs] +FakeModemCopyFileSection=12 +DefaultDestDir=12 + +[DeviceList] +%bossa.name%=DriverInstall, USB\VID_03EB&PID_6124 +%mkr1000.sketch.name%=DriverInstall, USB\VID_2341&PID_804E&MI_00 +%mkr1000.bootloader.name%=DriverInstall, USB\VID_2341&PID_004E +%mkrfox.sketch.name%=DriverInstall, USB\VID_2341&PID_8050&MI_00 +%mkrfox.bootloader.name%=DriverInstall, USB\VID_2341&PID_0050 +%mkrgsm.sketch.name%=DriverInstall, USB\VID_2341&PID_8052&MI_00 +%mkrgsm.bootloader.name%=DriverInstall, USB\VID_2341&PID_0052 +%mkrwan.sketch.name%=DriverInstall, USB\VID_2341&PID_8053&MI_00 +%mkrwan.bootloader.name%=DriverInstall, USB\VID_2341&PID_0053 +%mkrwan1310.sketch.name%=DriverInstall, USB\VID_2341&PID_8059&MI_00 +%mkrwan1310.bootloader.name%=DriverInstall, USB\VID_2341&PID_0059 +%mkrzero.sketch.name%=DriverInstall, USB\VID_2341&PID_804F&MI_00 +%mkrzero.bootloader.name%=DriverInstall, USB\VID_2341&PID_004F +%mkrwifi1010.sketch.name%=DriverInstall, USB\VID_2341&PID_8054&MI_00 +%mkrwifi1010.bootloader.name%=DriverInstall, USB\VID_2341&PID_0054 +%mkrvidor4000.sketch.name%=DriverInstall, USB\VID_2341&PID_8056&MI_00 +%mkrvidor4000.bootloader.name%=DriverInstall, USB\VID_2341&PID_0056 +%mkrnb1500.sketch.name%=DriverInstall, USB\VID_2341&PID_8055&MI_00 +%mkrnb1500.bootloader.name%=DriverInstall, USB\VID_2341&PID_0055 +%nano33iot.sketch.name%=DriverInstall, USB\VID_2341&PID_8057&MI_00 +%nano33iot.bootloader.name%=DriverInstall, USB\VID_2341&PID_0057 +%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 +%mkr1000.sketch.name%=DriverInstall, USB\VID_2341&PID_804E&MI_00 +%mkr1000.bootloader.name%=DriverInstall, USB\VID_2341&PID_004E +%mkrfox.sketch.name%=DriverInstall, USB\VID_2341&PID_8050&MI_00 +%mkrfox.bootloader.name%=DriverInstall, USB\VID_2341&PID_0050 +%mkrgsm.sketch.name%=DriverInstall, USB\VID_2341&PID_8052&MI_00 +%mkrgsm.bootloader.name%=DriverInstall, USB\VID_2341&PID_0052 +%mkrwan.sketch.name%=DriverInstall, USB\VID_2341&PID_8053&MI_00 +%mkrwan.bootloader.name%=DriverInstall, USB\VID_2341&PID_0053 +%mkrwan1310.sketch.name%=DriverInstall, USB\VID_2341&PID_8059&MI_00 +%mkrwan1310.bootloader.name%=DriverInstall, USB\VID_2341&PID_0059 +%mkrwifi1010.sketch.name%=DriverInstall, USB\VID_2341&PID_8054&MI_00 +%mkrwifi1010.bootloader.name%=DriverInstall, USB\VID_2341&PID_0054 +%mkrvidor4000.sketch.name%=DriverInstall, USB\VID_2341&PID_8056&MI_00 +%mkrvidor4000.bootloader.name%=DriverInstall, USB\VID_2341&PID_0056 +%mkrnb1500.sketch.name%=DriverInstall, USB\VID_2341&PID_8055&MI_00 +%mkrnb1500.bootloader.name%=DriverInstall, USB\VID_2341&PID_0055 +%nano33iot.sketch.name%=DriverInstall, USB\VID_2341&PID_8057&MI_00 +%nano33iot.bootloader.name%=DriverInstall, USB\VID_2341&PID_0057 +%mkrzero.sketch.name%=DriverInstall, USB\VID_2341&PID_804F&MI_00 +%mkrzero.bootloader.name%=DriverInstall, USB\VID_2341&PID_004F +%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 +%mkr1000.sketch.name%=DriverInstall, USB\VID_2341&PID_804E&MI_00 +%mkr1000.bootloader.name%=DriverInstall, USB\VID_2341&PID_004E +%mkrfox.sketch.name%=DriverInstall, USB\VID_2341&PID_8050&MI_00 +%mkrfox.bootloader.name%=DriverInstall, USB\VID_2341&PID_0050 +%mkrgsm.sketch.name%=DriverInstall, USB\VID_2341&PID_8052&MI_00 +%mkrgsm.bootloader.name%=DriverInstall, USB\VID_2341&PID_0052 +%mkrwan.sketch.name%=DriverInstall, USB\VID_2341&PID_8053&MI_00 +%mkrwan.bootloader.name%=DriverInstall, USB\VID_2341&PID_0053 +%mkrwan1310.sketch.name%=DriverInstall, USB\VID_2341&PID_8059&MI_00 +%mkrwan1310.bootloader.name%=DriverInstall, USB\VID_2341&PID_0059 +%mkrwifi1010.sketch.name%=DriverInstall, USB\VID_2341&PID_8054&MI_00 +%mkrwifi1010.bootloader.name%=DriverInstall, USB\VID_2341&PID_0054 +%mkrvidor4000.sketch.name%=DriverInstall, USB\VID_2341&PID_8056&MI_00 +%mkrvidor4000.bootloader.name%=DriverInstall, USB\VID_2341&PID_0056 +%mkrnb1500.sketch.name%=DriverInstall, USB\VID_2341&PID_8055&MI_00 +%mkrnb1500.bootloader.name%=DriverInstall, USB\VID_2341&PID_0055 +%nano33iot.sketch.name%=DriverInstall, USB\VID_2341&PID_8057&MI_00 +%nano33iot.bootloader.name%=DriverInstall, USB\VID_2341&PID_0057 +%mkrzero.sketch.name%=DriverInstall, USB\VID_2341&PID_804F&MI_00 +%mkrzero.bootloader.name%=DriverInstall, USB\VID_2341&PID_004F +%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 0000000..0507e73 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 0000000..41a890d Binary files /dev/null and b/drivers/dpinst-x86.exe differ diff --git a/drivers/genuino-samd.cat b/drivers/genuino-samd.cat new file mode 100644 index 0000000..f8172e4 Binary files /dev/null and b/drivers/genuino-samd.cat differ diff --git a/drivers/genuino-samd.inf b/drivers/genuino-samd.inf new file mode 100644 index 0000000..3ecce79 --- /dev/null +++ b/drivers/genuino-samd.inf @@ -0,0 +1,96 @@ +; +; Copyright 2016 Arduino LLC (http://www.arduino.cc/) +; +; 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 (for SAMD boards)" +ManufacturerName="Arduino LLC (www.arduino.cc)" +ServiceName="USB RS-232 Emulation Driver" +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-samd.inf + +[Version] +Class=Ports +ClassGuid={4D36E978-E325-11CE-BFC1-08002BE10318} +Signature="$Windows NT$" +Provider=%ManufacturerName% +DriverPackageDisplayName=%DriverPackageDisplayName% +CatalogFile=genuino-samd.cat +; DriverVer date is MM/DD/YYYY +DriverVer=02/11/2016,1.0.0.0 + +[Manufacturer] +%ManufacturerName%=DeviceList, NTamd64, NTia64 + +[DestinationDirs] +FakeModemCopyFileSection=12 +DefaultDestDir=12 + +[DeviceList] +%mkr1000.sketch.name%=DriverInstall, USB\VID_2341&PID_824E&MI_00 +%mkr1000.bootloader.name%=DriverInstall, USB\VID_2341&PID_024E +%zero.sketch.name%=DriverInstall, USB\VID_2341&PID_824D&MI_00 +%zero.bootloader.name%=DriverInstall, USB\VID_2341&PID_024D + +[DeviceList.NTamd64] +%mkr1000.sketch.name%=DriverInstall, USB\VID_2341&PID_824E&MI_00 +%mkr1000.bootloader.name%=DriverInstall, USB\VID_2341&PID_024E +%zero.sketch.name%=DriverInstall, USB\VID_2341&PID_824D&MI_00 +%zero.bootloader.name%=DriverInstall, USB\VID_2341&PID_024D + +[DeviceList.NTia64] +%mkr1000.sketch.name%=DriverInstall, USB\VID_2341&PID_824E&MI_00 +%mkr1000.bootloader.name%=DriverInstall, USB\VID_2341&PID_024E +%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/prewin10/adafruit_circuit_playground_express.cat b/drivers/prewin10/adafruit_circuit_playground_express.cat new file mode 100644 index 0000000..1a54878 Binary files /dev/null and b/drivers/prewin10/adafruit_circuit_playground_express.cat differ diff --git a/drivers/prewin10/adafruit_circuit_playground_express.inf b/drivers/prewin10/adafruit_circuit_playground_express.inf new file mode 100644 index 0000000..248caec --- /dev/null +++ b/drivers/prewin10/adafruit_circuit_playground_express.inf @@ -0,0 +1,113 @@ +;************************************************************ +; 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% +LayoutFile=layout.inf +CatalogFile=%MFGFILENAME%.cat +DriverVer=07/29/2018,10.0.0.0 + +[Manufacturer] +%MFGNAME%=DeviceList, NTamd64 + +[DestinationDirs] +DefaultDestDir=12 + + +;------------------------------------------------------------------------------ +; Windows 2000/XP/Vista-32bit 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-64bit 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% UF2 Bootloader (0018:00) BSP"=DriverInstall, USB\VID_239A&PID_0018&MI_00 +"%DESCRIPTION% UF2 WebUSB dummy (0018:04) BSP"=DriverInstall, USB\VID_239A&PID_0018&MI_00 +"%DESCRIPTION% (0019:00) BSP"=DriverInstall, USB\VID_239A&PID_0019&MI_00 +"%DESCRIPTION% Arduino (8018:00) BSP"=DriverInstall, USB\VID_239A&PID_8018&MI_00 +"%DESCRIPTION% CircuitPython (8019:00) BSP"=DriverInstall, USB\VID_239A&PID_8019&MI_00 + +[DeviceList.NTamd64] +"%DESCRIPTION% UF2 Bootloader (0018:00) BSP"=DriverInstall, USB\VID_239A&PID_0018&MI_00 +"%DESCRIPTION% UF2 WebUSB dummy (0018:04) BSP"=DriverInstall, USB\VID_239A&PID_0018&MI_00 +"%DESCRIPTION% (0019:00) BSP"=DriverInstall, USB\VID_239A&PID_0019&MI_00 +"%DESCRIPTION% Arduino (8018:00) BSP"=DriverInstall, USB\VID_239A&PID_8018&MI_00 +"%DESCRIPTION% CircuitPython (8019:00) BSP"=DriverInstall, USB\VID_239A&PID_8019&MI_00 + +;------------------------------------------------------------------------------ +; String Definitions +;------------------------------------------------------------------------------ +;Modify these strings to customize your device +;------------------------------------------------------------------------------ +[Strings] +MFGFILENAME="Adafruit_Circuit_Playground_Express" +DRIVERFILENAME ="usbser" +MFGNAME="Adafruit Industries LLC" +INSTDISK="Circuit Playground Express Driver Installer" +DESCRIPTION="Adafruit Circuit Playground Express" +SERVICE="USB RS-232 Emulation Driver" \ No newline at end of file diff --git a/extras/pack.hourlybuild.bash b/extras/pack.hourlybuild.bash new file mode 100755 index 0000000..2819e05 --- /dev/null +++ b/extras/pack.hourlybuild.bash @@ -0,0 +1,51 @@ +#!/bin/bash -ex + +# pack.*.bash - Bash script to help packaging samd core releases. +# Copyright (c) 2015 Arduino LLC. 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 + +BUILD_NUMBER=$1 +CURR_TIME=`date "+%Y-%m-%d %H:%M"` +CURR_TIME_SED=`date "+%Y\\-%m\\-%d %H:%M"` +VERSION=9.9.9-Hourly + +PWD=`pwd` +FOLDERNAME=`basename $PWD` +THIS_SCRIPT_NAME=`basename $0` +FILENAME=package_samd-hourly-b${BUILD_NUMBER}.tar.bz2 + +rm -f $FILENAME + +# Change name in platform.txt +sed -i "s/name=.*/name=SAMD Hourly Build ${BUILD_NUMBER} (${CURR_TIME})/" platform.txt + +cd .. +tar --transform "s|$FOLDERNAME|samd-hourly_b${BUILD_NUMBER}|g" --exclude=extras/** --exclude=.git* --exclude=.idea -cjf $FILENAME $FOLDERNAME +cd - + +mv ../$FILENAME . + +CHKSUM=`sha256sum $FILENAME | awk '{ print $1 }'` +SIZE=`wc -c $FILENAME | awk '{ print $1 }'` + +cat extras/package_index.json.Hourly.template | +sed "s/%%BUILD_NUMBER%%/${BUILD_NUMBER}/" | +sed "s/%%CURR_TIME%%/${CURR_TIME_SED}/" | +sed "s/%%VERSION%%/${VERSION}/" | +sed "s/%%FILENAME%%/${FILENAME}/" | +sed "s/%%CHECKSUM%%/${CHKSUM}/" | +sed "s/%%SIZE%%/${SIZE}/" > package_samd-hourly-build_index.json + diff --git a/extras/pack.pullrequest.bash b/extras/pack.pullrequest.bash new file mode 100755 index 0000000..7991401 --- /dev/null +++ b/extras/pack.pullrequest.bash @@ -0,0 +1,50 @@ +#!/bin/bash -ex + +# pack.*.bash - Bash script to help packaging samd core releases. +# Copyright (c) 2015 Arduino LLC. 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 + +PR_NUMBER=$1 +BUILD_NUMBER=$2 +VERSION=`grep version= platform.txt | sed 's/version=//g'` + +PWD=`pwd` +FOLDERNAME=`basename $PWD` +THIS_SCRIPT_NAME=`basename $0` +FILENAME=package_samd-b${BUILD_NUMBER}.tar.bz2 + +rm -f $FILENAME + +# Change name in platform.txt +sed -i "s/name=.*/name=SAMD Pull request #${PR_NUMBER} (Build ${BUILD_NUMBER})/" platform.txt + +cd .. +tar --transform "s|$FOLDERNAME|samd-PR${PR_NUMBER}_b${BUILD_NUMBER}|g" --exclude=extras/** --exclude=.git* --exclude=.idea -cjf $FILENAME $FOLDERNAME +cd - + +mv ../$FILENAME . + +CHKSUM=`sha256sum $FILENAME | awk '{ print $1 }'` +SIZE=`wc -c $FILENAME | awk '{ print $1 }'` + +cat extras/package_index.json.PR.template | +sed s/%%PR_NUMBER%%/${PR_NUMBER}/ | +sed s/%%BUILD_NUMBER%%/${BUILD_NUMBER}/ | +sed s/%%VERSION%%/${VERSION}-build-${BUILD_NUMBER}/ | +sed s/%%FILENAME%%/${FILENAME}/ | +sed s/%%CHECKSUM%%/${CHKSUM}/ | +sed s/%%SIZE%%/${SIZE}/ > package_samd-b${BUILD_NUMBER}_index.json + diff --git a/extras/pack.release.bash b/extras/pack.release.bash new file mode 100755 index 0000000..3321340 --- /dev/null +++ b/extras/pack.release.bash @@ -0,0 +1,56 @@ +#!/bin/bash -ex + +# pack.*.bash - Bash script to help packaging samd core releases. +# Copyright (c) 2015 Arduino LLC. 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 + +# Version check removed because version string passed from jenkins was incorrect +VERSION_FROM_TAG=$1 +CORE_NAME=$2 +echo $VERSION_FROM_TAG +echo $CORE_NAME +VERSION=`grep version= platform.txt | sed 's/version=//g'` +echo $VERSION + +if [ $VERSION != $VERSION_FROM_TAG ]; then + exit 0 +fi + +PWD=`pwd` +FOLDERNAME=`basename $PWD` +THIS_SCRIPT_NAME=`basename $0` +FILENAME=core-$CORE_NAME-$VERSION.tar.bz2 +echo $FILENAME + +rm -f *.tar.bz2 +rm -f *.json + +cd .. +tar --exclude=extras/** --exclude=.git* --exclude=.idea -cjhf $FILENAME $FOLDERNAME +cd - + +mv ../$FILENAME . + +CHKSUM=`sha256sum $FILENAME | awk '{ print $1 }'` +SIZE=`wc -c $FILENAME | awk '{ print $1 }'` + +cat extras/package_index.json.NewTag.template | +# sed "s/%%BUILD_NUMBER%%/${BUILD_NUMBER}/" | +# sed "s/%%CURR_TIME%%/${CURR_TIME_SED}/" | +sed "s/%%VERSION%%/${VERSION}/" | +sed "s/%%FILENAME%%/${FILENAME}/" | +sed "s/%%CHECKSUM%%/${CHKSUM}/" | +sed "s/%%SIZE%%/${SIZE}/" > package_${CORE_NAME}_${VERSION}_index.json \ No newline at end of file diff --git a/extras/package_index.json.Hourly.template b/extras/package_index.json.Hourly.template new file mode 100644 index 0000000..c29babc --- /dev/null +++ b/extras/package_index.json.Hourly.template @@ -0,0 +1,64 @@ +{ + "packages": [ + { + "name": "arduino-beta", + "maintainer": "Arduino Betatesting", + "websiteURL": "http://www.arduino.cc/", + "email": "packages@arduino.cc", + "help": { + "online": "http://www.arduino.cc/en/Reference/HomePage" + }, + "platforms": [ + { + "name": "Arduino SAMD core - Hourly build", + "architecture": "samd", + "version": "%%VERSION%%", + "category": "Arduino", + "url": "http://downloads.arduino.cc/Hourly/samd/%%FILENAME%%", + "archiveFileName": "%%FILENAME%%", + "checksum": "SHA-256:%%CHECKSUM%%", + "size": "%%SIZE%%", + "boards": [ + { + "name": "Arduino Zero" + } + ], + "toolsDependencies": [ + { + "packager": "arduino", + "name": "arm-none-eabi-gcc", + "version": "4.8.3-2014q1" + }, + { + "packager": "arduino", + "name": "bossac", + "version": "1.7.0" + }, + { + "packager": "arduino", + "name": "openocd", + "version": "0.9.0-arduino6-static" + }, + { + "packager": "arduino", + "name": "CMSIS", + "version": "4.5.0" + }, + { + "packager": "arduino", + "name": "CMSIS-Atmel", + "version": "1.1.0" + }, + { + "packager": "arduino", + "name": "arduinoOTA", + "version": "1.2.0" + } + ] + } + ], + "tools": [ + ] + } + ] +} diff --git a/extras/package_index.json.NewTag.template b/extras/package_index.json.NewTag.template new file mode 100644 index 0000000..6758be7 --- /dev/null +++ b/extras/package_index.json.NewTag.template @@ -0,0 +1,79 @@ +{ + "packages": [ + { + "name": "arduino", + "maintainer": "Arduino Betatesting", + "websiteURL": "http://www.arduino.cc/", + "email": "packages@arduino.cc", + "help": { + "online": "http://www.arduino.cc/en/Reference/HomePage" + }, + "platforms": [ + { + "name": "Arduino SAMD Boards (32-bits ARM Cortex-M0+) - Pre-release", + "architecture": "samd", + "version": "%%VERSION%%", + "category": "Arduino", + "help": { + "online": "http://www.arduino.cc/en/Reference/HomePage" + }, + "url": "http://downloads.arduino.cc/cores/staging/%%FILENAME%%", + "archiveFileName": "%%FILENAME%%", + "checksum": "SHA-256:%%CHECKSUM%%", + "size": "%%SIZE%%", + "boards": [ + { "name": "Arduino MKR WiFi 1010" }, + { "name": "Arduino Zero" }, + { "name": "Arduino MKR 1000" }, + { "name": "Arduino MKR Zero" }, + { "name": "Arduino MKR FOX 1200" }, + { "name": "Arduino MKR WAN 1300" }, + { "name": "Arduino MKR WAN 1310" }, + { "name": "Arduino MKR GSM 1400" }, + { "name": "Arduino MKR NB 1500" }, + { "name": "Arduino MKR Vidor 4000" }, + { "name": "Arduino Nano 33 IoT" }, + { "name": "Arduino M0 Pro" }, + { "name": "Arduino M0" }, + { "name": "Arduino Tian" }, + { "name": "Adafruit Circuit Playground Express" } + ], + "toolsDependencies": [ + { + "packager": "arduino", + "name": "arm-none-eabi-gcc", + "version": "7-2017q4" + }, + { + "packager": "arduino", + "name": "bossac", + "version": "1.7.0-arduino3" + }, + { + "packager": "arduino", + "name": "openocd", + "version": "0.10.0-arduino7" + }, + { + "packager": "arduino", + "name": "CMSIS", + "version": "4.5.0" + }, + { + "packager": "arduino", + "name": "CMSIS-Atmel", + "version": "1.2.0" + }, + { + "packager": "arduino", + "name": "arduinoOTA", + "version": "1.2.1" + } + ] + } + ], + "tools": [ + ] + } + ] +} diff --git a/extras/package_index.json.PR.template b/extras/package_index.json.PR.template new file mode 100644 index 0000000..ca0c1a5 --- /dev/null +++ b/extras/package_index.json.PR.template @@ -0,0 +1,64 @@ +{ + "packages": [ + { + "name": "arduino-beta", + "maintainer": "Arduino Betatesting", + "websiteURL": "http://www.arduino.cc/", + "email": "packages@arduino.cc", + "help": { + "online": "http://www.arduino.cc/en/Reference/HomePage" + }, + "platforms": [ + { + "name": "Arduino SAMD core - Pull request #%%PR_NUMBER%% (build %%BUILD_NUMBER%%)", + "architecture": "samd", + "version": "%%VERSION%%", + "category": "Arduino", + "url": "http://downloads.arduino.cc/PR/samd/%%FILENAME%%", + "archiveFileName": "%%FILENAME%%", + "checksum": "SHA-256:%%CHECKSUM%%", + "size": "%%SIZE%%", + "boards": [ + { + "name": "Arduino Zero" + } + ], + "toolsDependencies": [ + { + "packager": "arduino", + "name": "arm-none-eabi-gcc", + "version": "4.8.3-2014q1" + }, + { + "packager": "arduino", + "name": "bossac", + "version": "1.7.0" + }, + { + "packager": "arduino", + "name": "openocd", + "version": "0.9.0-arduino6-static" + }, + { + "packager": "arduino", + "name": "CMSIS", + "version": "4.5.0" + }, + { + "packager": "arduino", + "name": "CMSIS-Atmel", + "version": "1.1.0" + }, + { + "packager": "arduino", + "name": "arduinoOTA", + "version": "1.2.0" + } + ] + } + ], + "tools": [ + ] + } + ] +} diff --git a/keywords.txt b/keywords.txt new file mode 100644 index 0000000..a44f9ce --- /dev/null +++ b/keywords.txt @@ -0,0 +1,3 @@ +SerialGSM KEYWORD1 +SerialSARA KEYWORD1 +INPUT_PULLDOWN LITERAL1 Constants RESERVED_WORD_2 diff --git a/libraries/HID/HID.cpp b/libraries/HID/HID.cpp new file mode 100644 index 0000000..f4cffc5 --- /dev/null +++ b/libraries/HID/HID.cpp @@ -0,0 +1,162 @@ +/* Copyright (c) 2015, Arduino LLC +** +** Original code (pre-library): Copyright (c) 2011, Peter Barrett +** +** Permission to use, copy, modify, and/or distribute this software for +** any purpose with or without fee is hereby granted, provided that the +** above copyright notice and this permission notice appear in all copies. +** +** THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL +** WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED +** WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR +** BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES +** OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, +** WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, +** ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS +** SOFTWARE. +*/ + +#include "api/PluggableUSB.h" +#include "HID.h" + +#if defined(USBCON) + +extern USBDeviceClass USBDevice; + +HID_& HID() +{ + static HID_ obj; + return obj; +} + +int HID_::getInterface(uint8_t* interfaceCount) +{ + *interfaceCount += 1; // uses 1 + HIDDescriptor hidInterface = { + D_INTERFACE(pluggedInterface, 1, USB_DEVICE_CLASS_HUMAN_INTERFACE, HID_SUBCLASS_NONE, HID_PROTOCOL_NONE), + D_HIDREPORT(descriptorSize), + D_ENDPOINT(USB_ENDPOINT_IN(pluggedEndpoint), USB_ENDPOINT_TYPE_INTERRUPT, 0x40, 0x01) + }; + return USBDevice.sendControl(&hidInterface, sizeof(hidInterface)); +} + +int HID_::getDescriptor(USBSetup& setup) +{ + // Check if this is a HID Class Descriptor request + 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 + if (setup.wIndex != pluggedInterface) { return 0; } + + int total = 0; + HIDSubDescriptor* node; + USBDevice.packMessages(true); + for (node = rootNode; node; node = node->next) { + int res = USBDevice.sendControl(node->data, node->length); + if (res == -1) + return -1; + total += res; + } + USBDevice.packMessages(false); + return total; +} + +uint8_t HID_::getShortName(char *name) +{ + name[0] = 'H'; + name[1] = 'I'; + name[2] = 'D'; + name[3] = 'A' + (descriptorSize & 0x0F); + name[4] = 'A' + ((descriptorSize >> 4) & 0x0F); + return 5; +} + +void HID_::AppendDescriptor(HIDSubDescriptor *node) +{ + if (!rootNode) { + rootNode = node; + } else { + HIDSubDescriptor *current = rootNode; + while (current->next) { + current = current->next; + } + current->next = node; + } + descriptorSize += node->length; +} + +int HID_::SendReport(uint8_t id, const void* data, int len) +{ + uint8_t p[64]; + p[0] = id; + memcpy(&p[1], data, len); + return USBDevice.send(pluggedEndpoint, p, len+1); +} + +bool HID_::setup(USBSetup& setup) +{ + if (pluggedInterface != setup.wIndex) { + return false; + } + + uint8_t request = setup.bRequest; + uint8_t requestType = setup.bmRequestType; + + if (requestType == REQUEST_DEVICETOHOST_CLASS_INTERFACE) + { + if (request == HID_GET_REPORT) { + // TODO: HID_GetReport(); + return true; + } + if (request == HID_GET_PROTOCOL) { + // TODO: Send8(protocol); + return true; + } + if (request == HID_GET_IDLE) { + USBDevice.armSend(0, &idle, 1); + return true; + } + } + + if (requestType == REQUEST_HOSTTODEVICE_CLASS_INTERFACE) + { + if (request == HID_SET_PROTOCOL) { + // The USB Host tells us if we are in boot or report mode. + // This only works with a real boot compatible device. + protocol = setup.wValueL; + return true; + } + if (request == HID_SET_IDLE) { + idle = setup.wValueL; + return true; + } + if (request == HID_SET_REPORT) + { + //uint8_t reportID = setup.wValueL; + //uint16_t length = setup.wLength; + //uint8_t data[length]; + // Make sure to not read more data than USB_EP_SIZE. + // You can read multiple times through a loop. + // The first byte (may!) contain the reportID on a multreport. + //USB_RecvControl(data, length); + } + } + + return false; +} + +HID_::HID_(void) : PluggableUSBModule(1, 1, epType), + rootNode(NULL), descriptorSize(0), + protocol(1), idle(1) +{ + epType[0] = USB_ENDPOINT_TYPE_INTERRUPT | USB_ENDPOINT_IN(0);; + PluggableUSB().plug(this); +} + +int HID_::begin(void) +{ + return 0; +} + +#endif /* if defined(USBCON) */ diff --git a/libraries/HID/HID.h b/libraries/HID/HID.h new file mode 100644 index 0000000..698c4a0 --- /dev/null +++ b/libraries/HID/HID.h @@ -0,0 +1,125 @@ +/* + Copyright (c) 2015, Arduino LLC + Original code (pre-library): Copyright (c) 2011, Peter Barrett + + Permission to use, copy, modify, and/or distribute this software for + any purpose with or without fee is hereby granted, provided that the + above copyright notice and this permission notice appear in all copies. + + THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL + WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED + WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR + BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES + OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, + WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, + ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS + SOFTWARE. + */ + +#ifndef HID_h +#define HID_h + +#include +#include +#include "api/PluggableUSB.h" + +#if defined(USBCON) + +#define _USING_HID + +// HID 'Driver' +// ------------ +#define HID_GET_REPORT 0x01 +#define HID_GET_IDLE 0x02 +#define HID_GET_PROTOCOL 0x03 +#define HID_SET_REPORT 0x09 +#define HID_SET_IDLE 0x0A +#define HID_SET_PROTOCOL 0x0B + +#define HID_HID_DESCRIPTOR_TYPE 0x21 +#define HID_REPORT_DESCRIPTOR_TYPE 0x22 +#define HID_PHYSICAL_DESCRIPTOR_TYPE 0x23 + +// HID subclass HID1.11 Page 8 4.2 Subclass +#define HID_SUBCLASS_NONE 0 +#define HID_SUBCLASS_BOOT_INTERFACE 1 + +// HID Keyboard/Mouse bios compatible protocols HID1.11 Page 9 4.3 Protocols +#define HID_PROTOCOL_NONE 0 +#define HID_PROTOCOL_KEYBOARD 1 +#define HID_PROTOCOL_MOUSE 2 + +// Normal or bios protocol (Keyboard/Mouse) HID1.11 Page 54 7.2.5 Get_Protocol Request +// "protocol" variable is used for this purpose. +#define HID_BOOT_PROTOCOL 0 +#define HID_REPORT_PROTOCOL 1 + +// HID Request Type HID1.11 Page 51 7.2.1 Get_Report Request +#define HID_REPORT_TYPE_INPUT 1 +#define HID_REPORT_TYPE_OUTPUT 2 +#define HID_REPORT_TYPE_FEATURE 3 + +typedef struct +{ + uint8_t len; // 9 + uint8_t dtype; // 0x21 + uint8_t addr; + uint8_t versionL; // 0x101 + uint8_t versionH; // 0x101 + uint8_t country; + uint8_t desctype; // 0x22 report + uint8_t descLenL; + uint8_t descLenH; +} HIDDescDescriptor; + +typedef struct +{ + InterfaceDescriptor hid; + HIDDescDescriptor desc; + EndpointDescriptor in; +} HIDDescriptor; + +class HIDSubDescriptor { +public: + HIDSubDescriptor *next = NULL; + HIDSubDescriptor(const void *d, const uint16_t l) : data(d), length(l) { } + + const void* data; + const uint16_t length; +}; + +class HID_ : public PluggableUSBModule +{ +public: + HID_(void); + int begin(void); + int SendReport(uint8_t id, const void* data, int len); + void AppendDescriptor(HIDSubDescriptor* node); + +protected: + // Implementation of the PluggableUSBModule + int getInterface(uint8_t* interfaceCount); + int getDescriptor(USBSetup& setup); + bool setup(USBSetup& setup); + uint8_t getShortName(char* name); + +private: + unsigned int epType[1]; + + HIDSubDescriptor* rootNode; + uint16_t descriptorSize; + + uint8_t protocol; + uint8_t idle; +}; + +// Replacement for global singleton. +// This function prevents static-initialization-order-fiasco +// https://isocpp.org/wiki/faq/ctors#static-init-order-on-first-use +HID_& HID(); + +#define D_HIDREPORT(length) { 9, 0x21, 0x01, 0x01, 0, 1, 0x22, lowByte(length), highByte(length) } + +#endif + +#endif diff --git a/libraries/HID/keywords.txt b/libraries/HID/keywords.txt new file mode 100644 index 0000000..32a9ba5 --- /dev/null +++ b/libraries/HID/keywords.txt @@ -0,0 +1,21 @@ +####################################### +# Syntax Coloring Map HID +####################################### + +####################################### +# Datatypes (KEYWORD1) +####################################### + +HID KEYWORD1 + +####################################### +# Methods and Functions (KEYWORD2) +####################################### +begin KEYWORD2 +SendReport KEYWORD2 +AppendDescriptor KEYWORD2 + +####################################### +# Constants (LITERAL1) +####################################### +HID_TX LITERAL1 \ No newline at end of file diff --git a/libraries/HID/library.properties b/libraries/HID/library.properties new file mode 100644 index 0000000..ff9377b --- /dev/null +++ b/libraries/HID/library.properties @@ -0,0 +1,9 @@ +name=HID +version=1.0 +author=Arduino +maintainer=Arduino +sentence=Module for PluggableUSB infrastructure. Exposes an API for devices like Keyboards, Mice and Gamepads +paragraph= +category=Other +url=http://www.arduino.cc/en/Reference/HID +architectures=samd diff --git a/libraries/I2S/examples/InputSerialPlotter/InputSerialPlotter.ino b/libraries/I2S/examples/InputSerialPlotter/InputSerialPlotter.ino new file mode 100644 index 0000000..48b2a0a --- /dev/null +++ b/libraries/I2S/examples/InputSerialPlotter/InputSerialPlotter.ino @@ -0,0 +1,46 @@ +/* + This example reads audio data from an Invensense's ICS43432 I2S microphone + breakout board, and prints out the samples to the Serial console. The + Serial Plotter built into the Arduino IDE can be used to plot the audio + data (Tools -> Serial Plotter) + + Circuit: + * Arduino/Genuino Zero, MKR family and Nano 33 IoT + * ICS43432: + * GND connected GND + * 3.3V connected to 3.3V (Zero, Nano) or VCC (MKR) + * WS connected to pin 0 (Zero) or 3 (MKR) or A2 (Nano) + * CLK connected to pin 1 (Zero) or 2 (MKR) or A3 (Nano) + * SD connected to pin 9 (Zero) or A6 (MKR) or 4 (Nano) + + created 17 November 2016 + by Sandeep Mistry + */ + +#include + +void setup() { + // Open serial communications and wait for port to open: + // A baud rate of 115200 is used instead of 9600 for a faster data rate + // on non-native USB ports + Serial.begin(115200); + while (!Serial) { + ; // wait for serial port to connect. Needed for native USB port only + } + + // start I2S at 8 kHz with 32-bits per sample + if (!I2S.begin(I2S_PHILIPS_MODE, 8000, 32)) { + Serial.println("Failed to initialize I2S!"); + while (1); // do nothing + } +} + +void loop() { + // read a sample + int sample = I2S.read(); + + if (sample) { + // if it's non-zero print value to serial + Serial.println(sample); + } +} diff --git a/libraries/I2S/examples/SimpleTone/SimpleTone.ino b/libraries/I2S/examples/SimpleTone/SimpleTone.ino new file mode 100644 index 0000000..de67ed9 --- /dev/null +++ b/libraries/I2S/examples/SimpleTone/SimpleTone.ino @@ -0,0 +1,53 @@ +/* + This example generates a square wave based tone at a specified frequency + and sample rate. Then outputs the data using the I2S interface to a + MAX08357 I2S Amp Breakout board. + + Circuit: + * Arduino/Genuino Zero, MKR family and Nano 33 IoT + * MAX08357: + * GND connected GND + * VIN connected 5V + * LRC connected to pin 0 (Zero) or 3 (MKR) or A2 (Nano) + * BCLK connected to pin 1 (Zero) or 2 (MKR) or A3 (Nano) + * DIN connected to pin 9 (Zero) or A6 (MKR) or 4 (Nano) + + created 17 November 2016 + by Sandeep Mistry + */ + +#include + +const int frequency = 440; // frequency of square wave in Hz +const int amplitude = 500; // amplitude of square wave +const int sampleRate = 8000; // sample rate in Hz + +const int halfWavelength = (sampleRate / frequency); // half wavelength of square wave + +short sample = amplitude; // current sample value +int count = 0; + +void setup() { + Serial.begin(9600); + Serial.println("I2S simple tone"); + + // start I2S at the sample rate with 16-bits per sample + if (!I2S.begin(I2S_PHILIPS_MODE, sampleRate, 16)) { + Serial.println("Failed to initialize I2S!"); + while (1); // do nothing + } +} + +void loop() { + if (count % halfWavelength == 0) { + // invert the sample every half wavelength count multiple to generate square wave + sample = -1 * sample; + } + + // write the same sample twice, once for left and once for the right channel + I2S.write(sample); + I2S.write(sample); + + // increment the counter for the next sample + count++; +} diff --git a/libraries/I2S/keywords.txt b/libraries/I2S/keywords.txt new file mode 100644 index 0000000..70b6303 --- /dev/null +++ b/libraries/I2S/keywords.txt @@ -0,0 +1,27 @@ +####################################### +# Syntax Coloring Map I2S +####################################### + +####################################### +# Datatypes (KEYWORD1) +####################################### + +I2S KEYWORD1 + +####################################### +# Methods and Functions (KEYWORD2) +####################################### +begin KEYWORD2 +end KEYWORD2 + +onReceive KEYWORD2 +onTransmit KEYWORD2 + +setBufferSize KEYWORD2 + +####################################### +# Constants (LITERAL1) +####################################### +I2S_PHILIPS_MODE LITERAL1 +I2S_RIGHT_JUSTIFIED_MODE LITERAL1 +I2S_LEFT_JUSTIFIED_MODE LITERAL1 diff --git a/libraries/I2S/library.properties b/libraries/I2S/library.properties new file mode 100644 index 0000000..ed172e9 --- /dev/null +++ b/libraries/I2S/library.properties @@ -0,0 +1,9 @@ +name=I2S +version=1.0 +author=Arduino +maintainer=Arduino +sentence=Enables the communication with devices that use the Inter-IC Sound (I2S) Bus. Specific implementation for Arduino Zero. +paragraph= +category=Communication +url=http://www.arduino.cc/en/Reference/I2S +architectures=samd diff --git a/libraries/I2S/src/I2S.cpp b/libraries/I2S/src/I2S.cpp new file mode 100644 index 0000000..8b0cc39 --- /dev/null +++ b/libraries/I2S/src/I2S.cpp @@ -0,0 +1,534 @@ +/* + Copyright (c) 2016 Arduino LLC. 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 +*/ + +#include +#include + +#include "utility/DMA.h" +#include "utility/SAMD21_I2SDevice.h" + +static I2SDevice_SAMD21G18x i2sd(*I2S); + +#include "I2S.h" + +int I2SClass::_beginCount = 0; + +I2SClass::I2SClass(uint8_t deviceIndex, uint8_t clockGenerator, uint8_t sdPin, uint8_t sckPin, uint8_t fsPin) : + _deviceIndex(deviceIndex), + _clockGenerator(clockGenerator), + _sdPin(sdPin), + _sckPin(sckPin), + _fsPin(fsPin), + + _state(I2S_STATE_IDLE), + _dmaChannel(-1), + _bitsPerSample(0), + _dmaTransferInProgress(false), + + _onTransmit(NULL), + _onReceive(NULL) +{ +} + +int I2SClass::begin(int mode, long sampleRate, int bitsPerSample) +{ + // master mode (driving clock and frame select pins - output) + return begin(mode, sampleRate, bitsPerSample, true); +} + +int I2SClass::begin(int mode, int bitsPerSample) +{ + // slave mode (not driving clock and frame select pin - input) + return begin(mode, 0, bitsPerSample, false); +} + +int I2SClass::begin(int mode, long sampleRate, int bitsPerSample, bool driveClock) +{ + if (_state != I2S_STATE_IDLE) { + return 0; + } + + switch (mode) { + case I2S_PHILIPS_MODE: + case I2S_RIGHT_JUSTIFIED_MODE: + case I2S_LEFT_JUSTIFIED_MODE: + break; + + default: + // invalid mode + return 0; + } + + switch (bitsPerSample) { + case 8: + case 16: + case 32: + _bitsPerSample = bitsPerSample; + break; + + default: + // invalid bits per sample + return 0; + } + + // try to allocate a DMA channel + DMA.begin(); + + _dmaChannel = DMA.allocateChannel(); + + if (_dmaChannel < 0) { + // no DMA channel available + return 0; + } + + if (_beginCount == 0) { + // enable the I2S interface + PM->APBCMASK.reg |= PM_APBCMASK_I2S; + + // reset the device + i2sd.reset(); + } + + _beginCount++; + + if (driveClock) { + // set up clock + enableClock(sampleRate * 2 * bitsPerSample); + + i2sd.setSerialClockSelectMasterClockDiv(_deviceIndex); + i2sd.setFrameSyncSelectSerialClockDiv(_deviceIndex); + } else { + // use input signal from SCK and FS pins + i2sd.setSerialClockSelectPin(_deviceIndex); + i2sd.setFrameSyncSelectPin(_deviceIndex); + } + + // disable device before continuing + i2sd.disable(); + + if (mode == I2S_PHILIPS_MODE) { + i2sd.set1BitDelay(_deviceIndex); + } else { + i2sd.set0BitDelay(_deviceIndex); + } + i2sd.setNumberOfSlots(_deviceIndex, 1); + i2sd.setSlotSize(_deviceIndex, bitsPerSample); + i2sd.setDataSize(_deviceIndex, bitsPerSample); + + pinPeripheral(_sckPin, PIO_COM); + pinPeripheral(_fsPin, PIO_COM); + + if (mode == I2S_RIGHT_JUSTIFIED_MODE) { + i2sd.setSlotAdjustedRight(_deviceIndex); + } else { + i2sd.setSlotAdjustedLeft(_deviceIndex); + } + + i2sd.setClockUnit(_deviceIndex); + + pinPeripheral(_sdPin, PIO_COM); + + // done configure enable + i2sd.enable(); + + _doubleBuffer.reset(); + + return 1; +} + +void I2SClass::end() +{ + if (_dmaChannel > -1) { + DMA.freeChannel(_dmaChannel); + } + + _state = I2S_STATE_IDLE; + _dmaTransferInProgress = false; + + i2sd.disableSerializer(_deviceIndex); + i2sd.disableClockUnit(_deviceIndex); + + // set the pins back to input mode + pinMode(_sdPin, INPUT); + pinMode(_fsPin, INPUT); + pinMode(_sckPin, INPUT); + + disableClock(); + + _beginCount--; + + if (_beginCount == 0) { + i2sd.disable(); + + // disable the I2S interface + PM->APBCMASK.reg &= ~PM_APBCMASK_I2S; + } +} + +int I2SClass::available() +{ + if (_state != I2S_STATE_RECEIVER) { + enableReceiver(); + } + + uint8_t enableInterrupts = ((__get_PRIMASK() & 0x1) == 0); + size_t avail; + + // disable interrupts, + __disable_irq(); + + avail = _doubleBuffer.available(); + + if (_dmaTransferInProgress == false && _doubleBuffer.available() == 0) { + // no DMA transfer in progress, start a receive process + _dmaTransferInProgress = true; + + DMA.transfer(_dmaChannel, i2sd.data(_deviceIndex), _doubleBuffer.data(), _doubleBuffer.availableForWrite()); + + // switch to the next buffer for user output (will be empty) + _doubleBuffer.swap(); + } + + if (enableInterrupts) { + // re-enable the interrupts + __enable_irq(); + } + + return avail; +} + +union i2s_sample_t { + uint8_t b8; + int16_t b16; + int32_t b32; +}; + +int I2SClass::read() +{ + i2s_sample_t sample; + + sample.b32 = 0; + + read(&sample, _bitsPerSample / 8); + + if (_bitsPerSample == 32) { + return sample.b32; + } else if (_bitsPerSample == 16) { + return sample.b16; + } else if (_bitsPerSample == 8) { + return sample.b8; + } else { + return 0; + } +} + +int I2SClass::peek() +{ + uint8_t enableInterrupts = ((__get_PRIMASK() & 0x1) == 0); + i2s_sample_t sample; + + sample.b32 = 0; + + // disable interrupts, + __disable_irq(); + + _doubleBuffer.peek(&sample, _bitsPerSample / 8); + + if (enableInterrupts) { + // re-enable the interrupts + __enable_irq(); + } + + if (_bitsPerSample == 32) { + return sample.b32; + } else if (_bitsPerSample == 16) { + return sample.b16; + } else if (_bitsPerSample == 8) { + return sample.b8; + } else { + return 0; + } +} + +void I2SClass::flush() +{ + // do nothing, writes are DMA triggered +} + +size_t I2SClass::write(uint8_t data) +{ + return write((int32_t)data); +} + +size_t I2SClass::write(const uint8_t *buffer, size_t size) +{ + return write((const void*)buffer, size); +} + +int I2SClass::availableForWrite() +{ + if (_state != I2S_STATE_TRANSMITTER) { + enableTransmitter(); + } + + uint8_t enableInterrupts = ((__get_PRIMASK() & 0x1) == 0); + size_t space; + + // disable interrupts, + __disable_irq(); + + space = _doubleBuffer.availableForWrite(); + + if (enableInterrupts) { + // re-enable the interrupts + __enable_irq(); + } + + return space; +} + +int I2SClass::read(void* buffer, size_t size) +{ + if (_state != I2S_STATE_RECEIVER) { + enableReceiver(); + } + + uint8_t enableInterrupts = ((__get_PRIMASK() & 0x1) == 0); + + // disable interrupts, + __disable_irq(); + + int read = _doubleBuffer.read(buffer, size); + + if (_dmaTransferInProgress == false && _doubleBuffer.available() == 0) { + // no DMA transfer in progress, start a receive process + _dmaTransferInProgress = true; + + DMA.transfer(_dmaChannel, i2sd.data(_deviceIndex), _doubleBuffer.data(), _doubleBuffer.availableForWrite()); + + // switch to the next buffer for user output (will be empty) + _doubleBuffer.swap(); + } + + if (enableInterrupts) { + // re-enable the interrupts + __enable_irq(); + } + + return read; +} + +size_t I2SClass::write(int sample) +{ + return write((int32_t)sample); +} + +size_t I2SClass::write(int32_t sample) +{ + if (_state != I2S_STATE_TRANSMITTER) { + enableTransmitter(); + } + + // this is a blocking write + while(!i2sd.txReady(_deviceIndex)); + + i2sd.writeData(_deviceIndex, sample); + + i2sd.clearTxReady(_deviceIndex); + + return 1; +} + +size_t I2SClass::write(const void *buffer, size_t size) +{ + if (_state != I2S_STATE_TRANSMITTER) { + enableTransmitter(); + } + + uint8_t enableInterrupts = ((__get_PRIMASK() & 0x1) == 0); + size_t written; + + // disable interrupts, + __disable_irq(); + + written = _doubleBuffer.write(buffer, size); + + if (_dmaTransferInProgress == false && _doubleBuffer.available()) { + // no DMA transfer in progress, start a transmit process + _dmaTransferInProgress = true; + + DMA.transfer(_dmaChannel, _doubleBuffer.data(), i2sd.data(_deviceIndex), _doubleBuffer.available()); + + // switch to the next buffer for input + _doubleBuffer.swap(); + } + + if (enableInterrupts) { + // re-enable the interrupts + __enable_irq(); + } + + return written; +} + +void I2SClass::onTransmit(void(*function)(void)) +{ + _onTransmit = function; +} + +void I2SClass::onReceive(void(*function)(void)) +{ + _onReceive = function; +} + +void I2SClass::setBufferSize(int bufferSize) +{ + _doubleBuffer.setSize(bufferSize); +} + +void I2SClass::enableClock(int divider) +{ + int div = SystemCoreClock / divider; + int src = GCLK_GENCTRL_SRC_DFLL48M_Val; + + if (div > 255) { + // divider is too big, use 8 MHz oscillator instead + div = 8000000 / divider; + src = GCLK_GENCTRL_SRC_OSC8M_Val; + } + + // configure the clock divider + while (GCLK->STATUS.bit.SYNCBUSY); + GCLK->GENDIV.bit.ID = _clockGenerator; + GCLK->GENDIV.bit.DIV = div; + + // use the DFLL as the source + while (GCLK->STATUS.bit.SYNCBUSY); + GCLK->GENCTRL.bit.ID = _clockGenerator; + GCLK->GENCTRL.bit.SRC = src; + GCLK->GENCTRL.bit.IDC = 1; + GCLK->GENCTRL.bit.DIVSEL = 0; + GCLK->GENCTRL.bit.GENEN = 1; + + // enable + while (GCLK->STATUS.bit.SYNCBUSY); + GCLK->CLKCTRL.bit.ID = i2sd.glckId(_deviceIndex); + GCLK->CLKCTRL.bit.GEN = _clockGenerator; + GCLK->CLKCTRL.bit.CLKEN = 1; + + while (GCLK->STATUS.bit.SYNCBUSY); +} + +void I2SClass::disableClock() +{ + while (GCLK->STATUS.bit.SYNCBUSY); + GCLK->GENCTRL.bit.ID = _clockGenerator; + GCLK->GENCTRL.bit.SRC = GCLK_GENCTRL_SRC_DFLL48M_Val; + GCLK->GENCTRL.bit.IDC = 1; + GCLK->GENCTRL.bit.GENEN = 0; + + while (GCLK->STATUS.bit.SYNCBUSY); + GCLK->CLKCTRL.bit.ID = i2sd.glckId(_deviceIndex); + GCLK->CLKCTRL.bit.GEN = _clockGenerator; + GCLK->CLKCTRL.bit.CLKEN = 0; + + while (GCLK->STATUS.bit.SYNCBUSY); +} + +void I2SClass::enableTransmitter() +{ + i2sd.setTxMode(_deviceIndex); + i2sd.enableClockUnit(_deviceIndex); + i2sd.enableSerializer(_deviceIndex); + + DMA.incSrc(_dmaChannel); + DMA.onTransferComplete(_dmaChannel, I2SClass::onDmaTransferComplete); + DMA.setTriggerSource(_dmaChannel, i2sd.dmaTriggerSource(_deviceIndex)); + DMA.setTransferWidth(_dmaChannel, _bitsPerSample); + + _state = I2S_STATE_TRANSMITTER; +} + +void I2SClass::enableReceiver() +{ + i2sd.setRxMode(_deviceIndex); + i2sd.enableClockUnit(_deviceIndex); + i2sd.enableSerializer(_deviceIndex); + + DMA.incDst(_dmaChannel); + DMA.onTransferComplete(_dmaChannel, I2SClass::onDmaTransferComplete); + DMA.setTriggerSource(_dmaChannel, i2sd.dmaTriggerSource(_deviceIndex)); + DMA.setTransferWidth(_dmaChannel, _bitsPerSample); + + _state = I2S_STATE_RECEIVER; +} + +void I2SClass::onTransferComplete(void) +{ + if (_state == I2S_STATE_TRANSMITTER) { + // transmit complete + + if (_doubleBuffer.available()) { + // output is available to transfer, start the DMA process for the current buffer + + DMA.transfer(_dmaChannel, _doubleBuffer.data(), i2sd.data(_deviceIndex), _doubleBuffer.available()); + + // swap to the next user buffer for input + _doubleBuffer.swap(); + } else { + // no user data buffered to send + _dmaTransferInProgress = false; + } + + // call the users transmit callback if provided + if (_onTransmit) { + _onTransmit(); + } + } else { + // receive complete + + if (_doubleBuffer.available() == 0) { + // the user has read all the current input, start the DMA process to fill it again + DMA.transfer(_dmaChannel, i2sd.data(_deviceIndex), _doubleBuffer.data(), _doubleBuffer.availableForWrite()); + + // swap to the next buffer that has previously been filled, so that the user can read it + _doubleBuffer.swap(_doubleBuffer.availableForWrite()); + } else { + // user has not read current data, no free buffer to transfer into + _dmaTransferInProgress = false; + } + + // call the users receveive callback if provided + if (_onReceive) { + _onReceive(); + } + } +} + +void I2SClass::onDmaTransferComplete(int channel) +{ +#if I2S_INTERFACES_COUNT > 0 + if (I2S._dmaChannel == channel) { + I2S.onTransferComplete(); + } +#endif +} + +#if I2S_INTERFACES_COUNT > 0 +I2SClass I2S(I2S_DEVICE, I2S_CLOCK_GENERATOR, PIN_I2S_SD, PIN_I2S_SCK, PIN_I2S_FS); +#endif diff --git a/libraries/I2S/src/I2S.h b/libraries/I2S/src/I2S.h new file mode 100644 index 0000000..7f78b71 --- /dev/null +++ b/libraries/I2S/src/I2S.h @@ -0,0 +1,118 @@ +/* + Copyright (c) 2016 Arduino LLC. 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 _I2S_H_INCLUDED +#define _I2S_H_INCLUDED + +#include + +#include "utility/I2SDoubleBuffer.h" + +#define I2S_HAS_SET_BUFFER_SIZE 1 + +typedef enum { + I2S_PHILIPS_MODE, + I2S_RIGHT_JUSTIFIED_MODE, + I2S_LEFT_JUSTIFIED_MODE +} i2s_mode_t; + +class I2SClass : public Stream +{ +public: + // the device index and pins must map to the "COM" pads in Table 6-1 of the datasheet + I2SClass(uint8_t deviceIndex, uint8_t clockGenerator, uint8_t sdPin, uint8_t sckPin, uint8_t fsPin); + + // the SCK and FS pins are driven as outputs using the sample rate + int begin(int mode, long sampleRate, int bitsPerSample); + // the SCK and FS pins are inputs, other side controls sample rate + int begin(int mode, int bitsPerSample); + void end(); + + // from Stream + virtual int available(); + virtual int read(); + virtual int peek(); + virtual void flush(); + + // from Print + virtual size_t write(uint8_t); + virtual size_t write(const uint8_t *buffer, size_t size); + + virtual int availableForWrite(); + + int read(void* buffer, size_t size); + + size_t write(int); + size_t write(int32_t); + size_t write(const void *buffer, size_t size); + + void onTransmit(void(*)(void)); + void onReceive(void(*)(void)); + + void setBufferSize(int bufferSize); + +private: + int begin(int mode, long sampleRate, int bitsPerSample, bool driveClock); + + void enableClock(int divider); + void disableClock(); + + void enableTransmitter(); + void enableReceiver(); + + void onTransferComplete(void); + + static void onDmaTransferComplete(int); + +private: + typedef enum { + I2S_STATE_IDLE, + I2S_STATE_TRANSMITTER, + I2S_STATE_RECEIVER + } i2s_state_t; + + static int _beginCount; + + uint8_t _deviceIndex; + uint8_t _clockGenerator; + uint8_t _sdPin; + uint8_t _sckPin; + uint8_t _fsPin; + + i2s_state_t _state; + int _dmaChannel; + int _bitsPerSample; + + volatile bool _dmaTransferInProgress; + I2SDoubleBuffer _doubleBuffer; + + void (*_onTransmit)(void); + void (*_onReceive)(void); +}; + +// "I2S" is already defined by the CMSIS device, undefine it so the I2SClass +// instance can be called I2S +#undef I2S + +#if I2S_INTERFACES_COUNT > 0 +extern I2SClass I2S; +#else +#error "I2S is not supported on your board!" +#endif + +#endif diff --git a/libraries/I2S/src/utility/DMA.cpp b/libraries/I2S/src/utility/DMA.cpp new file mode 100644 index 0000000..74eb58d --- /dev/null +++ b/libraries/I2S/src/utility/DMA.cpp @@ -0,0 +1,284 @@ +/* + Copyright (c) 2016 Arduino LLC. 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 +*/ + +#include + +#include "DMA.h" + +int DMAClass::_beginCount = 0; + +DMAClass::DMAClass() : + _channelMask(0) +{ + memset(_transferCompleteCallbacks, 0x00, sizeof(_transferCompleteCallbacks)); + memset(_transferErrorCallbacks, 0x00, sizeof(_transferErrorCallbacks)); + + memset(_descriptors, 0x00, sizeof(_descriptors)); + memset(_descriptorsWriteBack, 0x00, sizeof(_descriptorsWriteBack)); +} + +DMAClass::~DMAClass() +{ +} + +void DMAClass::begin() +{ + if (_beginCount == 0) { + // enable the DMA interface + PM->AHBMASK.bit.DMAC_ = 1; + PM->APBBMASK.bit.DMAC_ = 1; + + // perform a reset + DMAC->CTRL.bit.SWRST = 1; + + // configure the descriptor addresses + DMAC->BASEADDR.bit.BASEADDR = (uint32_t)_descriptors; + DMAC->WRBADDR.bit.WRBADDR = (uint32_t)_descriptorsWriteBack; + + // enable with all levels + DMAC->CTRL.bit.LVLEN0 = 1; + DMAC->CTRL.bit.LVLEN1 = 1; + DMAC->CTRL.bit.LVLEN2 = 1; + DMAC->CTRL.bit.LVLEN3 = 1; + DMAC->CTRL.bit.DMAENABLE = 1; + + // enable the interrupt at lowest priority + NVIC_EnableIRQ(DMAC_IRQn); + NVIC_SetPriority(DMAC_IRQn, (1 << __NVIC_PRIO_BITS) - 1); + } + + _beginCount++; +} + +void DMAClass::end() +{ + _beginCount--; + + if (_beginCount == 0) { + // disable the interrupt + NVIC_DisableIRQ(DMAC_IRQn); + + // disable + DMAC->CTRL.bit.DMAENABLE = 0; + + // disable the DMA interface + PM->APBBMASK.bit.DMAC_ = 0; + PM->AHBMASK.bit.DMAC_ = 0; + } +} + +int DMAClass::allocateChannel() +{ + int channel = -1; + + // try to find a free DMA channel + for (int i = 0; i < NUM_DMA_CHANNELS; i++) { + if ((_channelMask & (1 << i)) == 0) { + // found one, set the mask bit to indicate it is allocated + _channelMask |= (1 << i); + + // clear the descriptor for the channel + memset((void*)&_descriptors[i], 0x00, sizeof(_descriptors[i])); + + // select the channel and reset it + DMAC->CHID.bit.ID = i; + DMAC->CHCTRLA.bit.ENABLE = 0; + DMAC->CHCTRLA.bit.SWRST = 1; + + channel = i; + break; + } + } + + return channel; +} + +void DMAClass::freeChannel(int channel) +{ + // select the channel and disable it + DMAC->CHID.bit.ID = channel; + DMAC->CHCTRLA.bit.ENABLE = 0; + + _channelMask &= ~(1 << channel); +} + +void DMAClass::setPriorityLevel(int channel, int level) +{ + // select the channel and set priority level + DMAC->CHID.bit.ID = channel; + DMAC->CHCTRLB.bit.LVL = level; +} + +void DMAClass::setTriggerSource(int channel, int source) +{ + // select the channel and set a trigger source + DMAC->CHID.bit.ID = channel; + DMAC->CHCTRLB.bit.TRIGSRC = source; + + if (DMAC->CHCTRLB.bit.TRIGSRC) { + // if it's not a software source (0), set trigger action a a beat + DMAC->CHCTRLB.bit.TRIGACT = DMAC_CHCTRLB_TRIGACT_BEAT_Val; + } else { + DMAC->CHCTRLB.bit.TRIGACT = DMAC_CHCTRLB_TRIGACT_BLOCK_Val; + } +} + +void DMAClass::setTransferWidth(int channel, int transferWidth) +{ + // select the channel and set transfer width + switch (transferWidth) { + case 8: + default: + _descriptors[channel].BTCTRL.bit.BEATSIZE = DMAC_BTCTRL_BEATSIZE_BYTE_Val; + break; + + case 16: + _descriptors[channel].BTCTRL.bit.BEATSIZE = DMAC_BTCTRL_BEATSIZE_HWORD_Val; + break; + + case 32: + _descriptors[channel].BTCTRL.bit.BEATSIZE = DMAC_BTCTRL_BEATSIZE_WORD_Val; + break; + } +} + +void DMAClass::incSrc(int channel) +{ + // select the channel and enable source increment + _descriptors[channel].BTCTRL.bit.STEPSEL = DMAC_BTCTRL_STEPSEL_SRC_Val; + _descriptors[channel].BTCTRL.bit.SRCINC = 1; +} + +void DMAClass::incDst(int channel) +{ + // select the channel and enable destination increment + _descriptors[channel].BTCTRL.bit.STEPSEL = DMAC_BTCTRL_STEPSEL_DST_Val; + _descriptors[channel].BTCTRL.bit.DSTINC = 1; +} + +int DMAClass::transfer(int channel, void* src, void* dst, uint16_t size) +{ + if (_descriptors[channel].BTCTRL.bit.VALID) { + // transfer in progress, fail + return 1; + } + + // select the channel + DMAC->CHID.bit.ID = channel; + + // disable event output generation and block actions + _descriptors[channel].BTCTRL.bit.EVOSEL = DMAC_BTCTRL_EVOSEL_DISABLE_Val; + _descriptors[channel].BTCTRL.bit.BLOCKACT = DMAC_BTCTRL_BLOCKACT_NOACT_Val; + + // map beat size to transfer width in bytes + int transferWidth; + + switch (_descriptors[channel].BTCTRL.bit.BEATSIZE) { + case DMAC_BTCTRL_BEATSIZE_BYTE_Val: + default: + transferWidth = 1; + break; + + case DMAC_BTCTRL_BEATSIZE_HWORD_Val: + transferWidth = 2; + break; + + case DMAC_BTCTRL_BEATSIZE_WORD_Val: + transferWidth = 4; + break; + } + + // set step size to 1, source + destination addresses, no next descriptor block count + _descriptors[channel].BTCTRL.bit.STEPSIZE = DMAC_BTCTRL_STEPSIZE_X1_Val; + _descriptors[channel].SRCADDR.bit.SRCADDR = (uint32_t)src; + _descriptors[channel].DSTADDR.bit.DSTADDR = (uint32_t)dst; + _descriptors[channel].DESCADDR.bit.DESCADDR = 0; + _descriptors[channel].BTCNT.bit.BTCNT = size / transferWidth; + + if (_descriptors[channel].BTCTRL.bit.SRCINC) { + // if increment source is set, the source address must be the end address + _descriptors[channel].SRCADDR.bit.SRCADDR += size; + } + + if (_descriptors[channel].BTCTRL.bit.DSTINC) { + // if increment destination is set, the destination address must be the end address + _descriptors[channel].DSTADDR.bit.DSTADDR += size; + } + + // validate the descriptor + _descriptors[channel].BTCTRL.bit.VALID = 1; + + // enable channel and transfer error + complete interrupts + DMAC->CHINTENSET.bit.TERR = 1; + DMAC->CHINTENSET.bit.TCMPL = 1; + DMAC->CHCTRLA.bit.ENABLE = 1; + + + if (DMAC->CHCTRLB.bit.TRIGSRC == 0) { + // uses software trigger, so trigger it + DMAC->SWTRIGCTRL.reg |= (1 << channel); + } + + return 0; +} + +void DMAClass::onTransferComplete(int channel, void(*function)(int)) +{ + _transferCompleteCallbacks[channel] = function; +} + +void DMAClass::onTransferError(int channel, void(*function)(int)) +{ + _transferErrorCallbacks[channel] = function; +} + +void DMAClass::onService() +{ + // get the channel and select it + int channel = DMAC->INTPEND.bit.ID; + DMAC->CHID.bit.ID = channel; + + // invalidate the channel + _descriptors[channel].BTCTRL.bit.VALID = 0; + + if (DMAC->CHINTFLAG.bit.TERR) { + // clear the error interrupt and call the error callback if there is one + DMAC->CHINTFLAG.bit.TERR = 1; + + if (_transferErrorCallbacks[channel]) { + _transferErrorCallbacks[channel](channel); + } + } + + if (DMAC->CHINTFLAG.bit.TCMPL) { + // clear the complete interrupt and call the callback if there is one + DMAC->CHINTFLAG.bit.TCMPL = 1; + + if (_transferCompleteCallbacks[channel]) { + _transferCompleteCallbacks[channel](channel); + } + } +} + +extern "C" { + void DMAC_Handler() { + DMA.onService(); + } +} + +DMAClass DMA; diff --git a/libraries/I2S/src/utility/DMA.h b/libraries/I2S/src/utility/DMA.h new file mode 100644 index 0000000..19b7b62 --- /dev/null +++ b/libraries/I2S/src/utility/DMA.h @@ -0,0 +1,60 @@ +/* + Copyright (c) 2016 Arduino LLC. 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 +*/ +#pragma once + +#define NUM_DMA_CHANNELS 1 + +/* + WARNING: The API for this class may change and it's not intended for public use! +*/ +class DMAClass +{ + public: + DMAClass(); + virtual ~DMAClass(); + + void begin(); + void end(); + + int allocateChannel(); + void freeChannel(int channel); + + void setPriorityLevel(int channel, int level); + void setTriggerSource(int channel, int source); + void setTransferWidth(int channel, int transferWidth); + void incSrc(int channel); + void incDst(int channel); + int transfer(int channel, void* src, void* dst, uint16_t size); + + void onTransferComplete(int channel, void(*function)(int)); + void onTransferError(int channel, void(*function)(int)); + + void onService(); + + private: + static int _beginCount; + uint32_t _channelMask; + + void (*_transferCompleteCallbacks[NUM_DMA_CHANNELS])(int); + void (*_transferErrorCallbacks[NUM_DMA_CHANNELS])(int); + + DmacDescriptor _descriptors[NUM_DMA_CHANNELS] __attribute__ ((aligned (16))); + DmacDescriptor _descriptorsWriteBack[NUM_DMA_CHANNELS] __attribute__ ((aligned (16))); +}; + +extern DMAClass DMA; diff --git a/libraries/I2S/src/utility/I2SDoubleBuffer.cpp b/libraries/I2S/src/utility/I2SDoubleBuffer.cpp new file mode 100644 index 0000000..5c131a7 --- /dev/null +++ b/libraries/I2S/src/utility/I2SDoubleBuffer.cpp @@ -0,0 +1,130 @@ +/* + Copyright (c) 2016 Arduino LLC. 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 +*/ + +#include +#include + +#include "I2SDoubleBuffer.h" + +I2SDoubleBuffer::I2SDoubleBuffer() : + _size(DEFAULT_I2S_BUFFER_SIZE) +{ + reset(); +} + +I2SDoubleBuffer::~I2SDoubleBuffer() +{ +} + +void I2SDoubleBuffer::setSize(int size) +{ + _size = size; +} + +void I2SDoubleBuffer::reset() +{ + _buffer[0] = (uint8_t*)realloc(_buffer[0], _size); + _buffer[1] = (uint8_t*)realloc(_buffer[1], _size); + + _index = 0; + _length[0] = 0; + _length[1] = 0; + _readOffset[0] = 0; + _readOffset[1] = 0; +} + +size_t I2SDoubleBuffer::availableForWrite() +{ + return (_size - (_length[_index] - _readOffset[_index])); +} + +size_t I2SDoubleBuffer::write(const void *buffer, size_t size) +{ + size_t space = availableForWrite(); + + if (size > space) { + size = space; + } + + if (size == 0) { + return 0; + } + + memcpy(&_buffer[_index][_length[_index]], buffer, size); + + _length[_index] += size; + + return size; +} + +size_t I2SDoubleBuffer::read(void *buffer, size_t size) +{ + size_t avail = available(); + + if (size > avail) { + size = avail; + } + + if (size == 0) { + return 0; + } + + memcpy(buffer, &_buffer[_index][_readOffset[_index]], size); + _readOffset[_index] += size; + + return size; +} + +size_t I2SDoubleBuffer::peek(void *buffer, size_t size) +{ + size_t avail = available(); + + if (size > avail) { + size = avail; + } + + if (size == 0) { + return 0; + } + + memcpy(buffer, &_buffer[_index][_readOffset[_index]], size); + + return size; +} + +void* I2SDoubleBuffer::data() +{ + return (void*)_buffer[_index]; +} + +size_t I2SDoubleBuffer::available() +{ + return _length[_index] - _readOffset[_index]; +} + +void I2SDoubleBuffer::swap(int length) +{ + if (_index == 0) { + _index = 1; + } else { + _index = 0; + } + + _length[_index] = length; + _readOffset[_index] = 0; +} diff --git a/libraries/I2S/src/utility/I2SDoubleBuffer.h b/libraries/I2S/src/utility/I2SDoubleBuffer.h new file mode 100644 index 0000000..8bdc04d --- /dev/null +++ b/libraries/I2S/src/utility/I2SDoubleBuffer.h @@ -0,0 +1,53 @@ +/* + Copyright (c) 2016 Arduino LLC. 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 _I2S_DOUBLE_BUFFER_H_INCLUDED +#define _I2S_DOUBLE_BUFFER_H_INCLUDED + +#include +#include + +#define DEFAULT_I2S_BUFFER_SIZE 512 + +class I2SDoubleBuffer +{ +public: + I2SDoubleBuffer(); + virtual ~I2SDoubleBuffer(); + + void setSize(int size); + + void reset(); + + size_t availableForWrite(); + size_t write(const void *buffer, size_t size); + size_t read(void *buffer, size_t size); + size_t peek(void *buffer, size_t size); + void* data(); + size_t available(); + void swap(int length = 0); + +private: + uint8_t* _buffer[2]; + int _size; + volatile int _length[2]; + volatile int _readOffset[2]; + volatile int _index; +}; + +#endif diff --git a/libraries/I2S/src/utility/SAMD21_I2SDevice.h b/libraries/I2S/src/utility/SAMD21_I2SDevice.h new file mode 100644 index 0000000..2615839 --- /dev/null +++ b/libraries/I2S/src/utility/SAMD21_I2SDevice.h @@ -0,0 +1,236 @@ +/* + Copyright (c) 2016 Arduino LLC. 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 +*/ + +#pragma once + +#include + +class I2SDevice_SAMD21G18x { +public: + I2SDevice_SAMD21G18x(I2s& _i2s) : + i2s(_i2s) + { + // Empty + } + + inline void reset() { + while(i2s.SYNCBUSY.bit.SWRST); + i2s.CTRLA.bit.SWRST = 1; + } + + inline void disable() { + while(i2s.SYNCBUSY.bit.ENABLE); + i2s.CTRLA.bit.ENABLE = 0; + } + + inline void enable() { + while(i2s.SYNCBUSY.bit.ENABLE); + i2s.CTRLA.bit.ENABLE = 1; + } + + inline int glckId(int index) { + return (index == 0) ? I2S_GCLK_ID_0 : I2S_GCLK_ID_1; + } + + inline void setSerialClockSelectMasterClockDiv(int index) { + i2s.CLKCTRL[index].bit.SCKSEL = I2S_CLKCTRL_SCKSEL_MCKDIV_Val; + } + + inline void setSerialClockSelectPin(int index) { + i2s.CLKCTRL[index].bit.SCKSEL = I2S_CLKCTRL_SCKSEL_SCKPIN_Val; + } + + inline void setFrameSyncSelectSerialClockDiv(int index) { + i2s.CLKCTRL[index].bit.FSSEL = I2S_CLKCTRL_FSSEL_SCKDIV_Val; + } + + inline void setFrameSyncSelectPin(int index) { + i2s.CLKCTRL[index].bit.FSSEL = I2S_CLKCTRL_FSSEL_FSPIN_Val; + } + + inline void set0BitDelay(int index) { + i2s.CLKCTRL[index].bit.BITDELAY = I2S_CLKCTRL_BITDELAY_LJ_Val; + } + + inline void set1BitDelay(int index) { + i2s.CLKCTRL[index].bit.BITDELAY = I2S_CLKCTRL_BITDELAY_I2S_Val; + } + + inline void setNumberOfSlots(int index, int nbslots) { + i2s.CLKCTRL[index].bit.NBSLOTS = nbslots; + } + + inline void setSlotSize(int index, int size) { + switch (size) { + case 32: + i2s.CLKCTRL[index].bit.SLOTSIZE = I2S_CLKCTRL_SLOTSIZE_32_Val; + break; + + case 24: + i2s.CLKCTRL[index].bit.SLOTSIZE = I2S_CLKCTRL_SLOTSIZE_24_Val; + break; + + case 16: + i2s.CLKCTRL[index].bit.SLOTSIZE = I2S_CLKCTRL_SLOTSIZE_16_Val; + break; + + case 8: + i2s.CLKCTRL[index].bit.SLOTSIZE = I2S_CLKCTRL_SLOTSIZE_8_Val; + break; + } + } + + inline void setDataSize(int index, int size) { + switch (size) { + case 32: + i2s.SERCTRL[index].bit.DATASIZE = I2S_SERCTRL_DATASIZE_32_Val; + break; + + case 24: + i2s.SERCTRL[index].bit.DATASIZE = I2S_SERCTRL_DATASIZE_24_Val; + break; + + case 16: + i2s.SERCTRL[index].bit.DATASIZE = I2S_SERCTRL_DATASIZE_16_Val; + break; + + case 8: + i2s.SERCTRL[index].bit.DATASIZE = I2S_SERCTRL_DATASIZE_8_Val; + break; + } + } + + inline void setSlotAdjustedRight(int index) { + i2s.SERCTRL[index].bit.SLOTADJ = I2S_SERCTRL_SLOTADJ_RIGHT_Val; + } + + inline void setSlotAdjustedLeft(int index) { + i2s.SERCTRL[index].bit.SLOTADJ = I2S_SERCTRL_SLOTADJ_LEFT_Val; + } + + inline void setClockUnit(int index) { + i2s.SERCTRL[index].bit.CLKSEL = (index == 0) ? I2S_SERCTRL_CLKSEL_CLK0_Val : I2S_SERCTRL_CLKSEL_CLK1_Val; + } + + inline void setTxMode(int index) { + i2s.SERCTRL[index].bit.SERMODE = I2S_SERCTRL_SERMODE_TX_Val; + } + + inline void setRxMode(int index) { + i2s.SERCTRL[index].bit.SERMODE = I2S_SERCTRL_SERMODE_RX_Val; + } + + inline void enableClockUnit(int index) { + if (index == 0) { + while(i2s.SYNCBUSY.bit.CKEN0); + i2s.CTRLA.bit.CKEN0 = 1; + } else { + while(i2s.SYNCBUSY.bit.CKEN1); + i2s.CTRLA.bit.CKEN1 = 1; + } + } + + inline void disableClockUnit(int index) { + if (index == 0) { + while(i2s.SYNCBUSY.bit.CKEN0); + i2s.CTRLA.bit.CKEN0 = 0; + } else { + while(i2s.SYNCBUSY.bit.CKEN1); + i2s.CTRLA.bit.CKEN1 = 0; + } + } + + inline void enableSerializer(int index) { + if (index == 0) { + while(i2s.SYNCBUSY.bit.SEREN0); + i2s.CTRLA.bit.SEREN0 = 1; + } else { + while(i2s.SYNCBUSY.bit.SEREN1); + i2s.CTRLA.bit.SEREN1 = 1; + } + } + + inline void disableSerializer(int index) { + if (index == 0) { + while(i2s.SYNCBUSY.bit.SEREN0); + i2s.CTRLA.bit.SEREN0 = 0; + } else { + while(i2s.SYNCBUSY.bit.SEREN1); + i2s.CTRLA.bit.SEREN1 = 0; + } + } + + inline int dmaTriggerSource(int index) { + if (i2s.SERCTRL[index].bit.SERMODE == I2S_SERCTRL_SERMODE_TX_Val) { + return (index == 0) ? I2S_DMAC_ID_TX_0 : I2S_DMAC_ID_TX_1; + } else { + return (index == 0) ? I2S_DMAC_ID_RX_0 : I2S_DMAC_ID_RX_1; + } + } + + inline int txReady(int index) { + return (index == 0) ? i2s.INTFLAG.bit.TXRDY0 :i2s.INTFLAG.bit.TXRDY1; + } + + inline void writeData(int index, int32_t value) { + if (index == 0) { + while (i2s.SYNCBUSY.bit.DATA0); + } else { + while (i2s.SYNCBUSY.bit.DATA1); + } + + i2s.DATA[index].bit.DATA = value; + } + + inline void clearTxReady(int index) { + if (index == 0) { + i2s.INTFLAG.bit.TXRDY0 = 1; + } else { + i2s.INTFLAG.bit.TXRDY1 = 1; + } + } + + inline int rxReady(int index) { + return (index == 0) ? i2s.INTFLAG.bit.RXRDY0 :i2s.INTFLAG.bit.RXRDY1; + } + + inline int32_t readData(int index) { + if (index == 0) { + while (i2s.SYNCBUSY.bit.DATA0); + } else { + while (i2s.SYNCBUSY.bit.DATA1); + } + + return i2s.DATA[index].bit.DATA; + } + + inline void clearRxReady(int index) { + if (index == 0) { + i2s.INTFLAG.bit.RXRDY0 = 1; + } else { + i2s.INTFLAG.bit.RXRDY1 = 1; + } + } + + inline void* data(int index) { + return (void*)&i2s.DATA[index].reg; + } + +private: + volatile I2s &i2s; +}; diff --git a/libraries/SAMD_AnalogCorrection/examples/CorrectADCResponse/CorrectADCResponse.ino b/libraries/SAMD_AnalogCorrection/examples/CorrectADCResponse/CorrectADCResponse.ino new file mode 100644 index 0000000..d4a4a64 --- /dev/null +++ b/libraries/SAMD_AnalogCorrection/examples/CorrectADCResponse/CorrectADCResponse.ino @@ -0,0 +1,211 @@ +/* + This sketch easily and quickly finds the right ADC correction values for a particular Arduino ZERO board. + The correction values that are found are only valid for the board where the sketch is executed. + + This example code is in the public domain. + + Written 6 May 2015 by Claudio Indellicati +*/ + +/* + How to use this sketch + + 1) Remove any connection cable, shield or jumper from your Arduino ZERO + 2) Connect pin A1 to the nearest GND pin using the shortest jumper possible + 3) Connect pin A2 to the 3.3V pin using the shortest jumper possible + 4) Connect the Arduino ZERO to your PC using a USB cable plugged in the USB programming port of the board + 5) Upload this sketch and leave the board powered on for at least one minute + 6) Open the Serial Monitor and press the reset button on the Arduino ZERO + 7) At the and of the procedure you can find logged + - the offset and gain values for the board where the sketch has been just executed + - the code to copy/paste in sketches using this library +*/ + +#include "SAMD_AnalogCorrection.h" + +#define ADC_GND_PIN A1 +#define ADC_3V3_PIN A2 + +#define ADC_READS_SHIFT 8 +#define ADC_READS_COUNT (1 << ADC_READS_SHIFT) + +#define ADC_MIN_GAIN 0x0400 +#define ADC_UNITY_GAIN 0x0800 +#define ADC_MAX_GAIN (0x1000 - 1) +#define ADC_RESOLUTION_BITS 12 // do not change. This library only supports 12 bit resolution. +#define ADC_RANGE (1 << ADC_RESOLUTION_BITS) +#define ADC_TOP_VALUE (ADC_RANGE - 1) + +#define MAX_TOP_VALUE_READS 10 + +void setup() +{ + Serial.begin(9600); + + Serial.println("\r\nCalibrating ADC with factory values"); + + analogReadResolution(ADC_RESOLUTION_BITS); + + Serial.println("\r\nReading GND and 3.3V ADC levels"); + Serial.print(" "); + readGndLevel(); + Serial.print(" "); + read3V3Level(); + + int offsetCorrectionValue = 0; + uint16_t gainCorrectionValue = ADC_UNITY_GAIN; + + Serial.print("\r\nOffset correction (@gain = "); + Serial.print(gainCorrectionValue); + Serial.println(" (unity gain))"); + + // Set default correction values and enable correction + analogReadCorrection(offsetCorrectionValue, gainCorrectionValue); + + for (int offset = 0; offset < (int)(ADC_OFFSETCORR_MASK >> 1); ++offset) + { + analogReadCorrection(offset, gainCorrectionValue); + + Serial.print(" Offset = "); + Serial.print(offset); + Serial.print(", "); + + if (readGndLevel() == 0) + { + offsetCorrectionValue = offset; + break; + } + } + + Serial.println("\r\nGain correction"); + + uint8_t topValueReadsCount = 0U; + + uint16_t minGain = 0U, + maxGain = 0U; + + analogReadCorrection(offsetCorrectionValue, gainCorrectionValue); + Serial.print(" Gain = "); + Serial.print(gainCorrectionValue); + Serial.print(", "); + uint16_t highLevelRead = read3V3Level(); + + if (highLevelRead < ADC_TOP_VALUE) + { + for (uint16_t gain = ADC_UNITY_GAIN + 1; gain <= ADC_MAX_GAIN; ++gain) + { + analogReadCorrection(offsetCorrectionValue, gain); + + Serial.print(" Gain = "); + Serial.print(gain); + Serial.print(", "); + highLevelRead = read3V3Level(); + + if (highLevelRead == ADC_TOP_VALUE) + { + if (minGain == 0U) + minGain = gain; + + if (++topValueReadsCount >= MAX_TOP_VALUE_READS) + { + maxGain = minGain; + break; + } + + maxGain = gain; + } + + if (highLevelRead > ADC_TOP_VALUE) + break; + } + } + else if (highLevelRead >= ADC_TOP_VALUE) + { + if (highLevelRead == ADC_TOP_VALUE) + maxGain = ADC_UNITY_GAIN; + + for (uint16_t gain = ADC_UNITY_GAIN - 1; gain >= ADC_MIN_GAIN; --gain) + { + analogReadCorrection(offsetCorrectionValue, gain); + + Serial.print(" Gain = "); + Serial.print(gain); + Serial.print(", "); + highLevelRead = read3V3Level(); + + if (highLevelRead == ADC_TOP_VALUE) + { + if (maxGain == 0U) + maxGain = gain; + + minGain = gain; + } + + if (highLevelRead < ADC_TOP_VALUE) + break; + } + } + + gainCorrectionValue = (minGain + maxGain) >> 1; + + analogReadCorrection(offsetCorrectionValue, gainCorrectionValue); + + Serial.println("\r\nReadings after corrections"); + Serial.print(" "); + readGndLevel(); + Serial.print(" "); + read3V3Level(); + + Serial.println("\r\n=================="); + Serial.println("\r\nCorrection values:"); + Serial.print(" Offset = "); + Serial.println(offsetCorrectionValue); + Serial.print(" Gain = "); + Serial.println(gainCorrectionValue); + Serial.println("\r\nAdd the next lines to your sketch:"); + Serial.println(" analogReadResolution(12);"); + Serial.print(" analogReadCorrection("); + Serial.print(offsetCorrectionValue); + Serial.print(", "); + Serial.print(gainCorrectionValue); + Serial.println(");"); + Serial.println("\r\n=================="); +} + +void loop() +{ +} + +uint16_t readGndLevel() +{ + uint32_t readAccumulator = 0; + + for (int i = 0; i < ADC_READS_COUNT; ++i) + readAccumulator += analogRead(ADC_GND_PIN); + + uint16_t readValue = readAccumulator >> ADC_READS_SHIFT; + + Serial.print("ADC(GND) = "); + Serial.println(readValue); + + return readValue; +} + +uint16_t read3V3Level() +{ + uint32_t readAccumulator = 0; + + for (int i = 0; i < ADC_READS_COUNT; ++i) + readAccumulator += analogRead(ADC_3V3_PIN); + + uint16_t readValue = readAccumulator >> ADC_READS_SHIFT; + + if (readValue < (ADC_RANGE >> 1)) + readValue += ADC_RANGE; + + Serial.print("ADC(3.3V) = "); + Serial.println(readValue); + + return readValue; +} + diff --git a/libraries/SAMD_AnalogCorrection/library.properties b/libraries/SAMD_AnalogCorrection/library.properties new file mode 100644 index 0000000..b8ba59a --- /dev/null +++ b/libraries/SAMD_AnalogCorrection/library.properties @@ -0,0 +1,9 @@ +name=SAMD_AnalogCorrection +version=1.0 +author=Arduino +maintainer=Arduino +sentence=Sets and enables the digital correction logic of the SAMD ADC. +paragraph=Useful to correct the values returned by the ADC. +category=Other +url= +architectures=samd diff --git a/libraries/SAMD_AnalogCorrection/src/SAMD_AnalogCorrection.cpp b/libraries/SAMD_AnalogCorrection/src/SAMD_AnalogCorrection.cpp new file mode 100644 index 0000000..1681b0a --- /dev/null +++ b/libraries/SAMD_AnalogCorrection/src/SAMD_AnalogCorrection.cpp @@ -0,0 +1,31 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#include "SAMD_AnalogCorrection.h" + +void analogReadCorrection (int offset, uint16_t gain) +{ + // Set correction values + ADC->OFFSETCORR.reg = ADC_OFFSETCORR_OFFSETCORR(offset); + ADC->GAINCORR.reg = ADC_GAINCORR_GAINCORR(gain); + + // Enable digital correction logic + ADC->CTRLB.bit.CORREN = 1; + while(ADC->STATUS.bit.SYNCBUSY); +} + diff --git a/libraries/SAMD_AnalogCorrection/src/SAMD_AnalogCorrection.h b/libraries/SAMD_AnalogCorrection/src/SAMD_AnalogCorrection.h new file mode 100644 index 0000000..5edb91e --- /dev/null +++ b/libraries/SAMD_AnalogCorrection/src/SAMD_AnalogCorrection.h @@ -0,0 +1,24 @@ +/* + Copyright (c) 2015 Arduino LLC. 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 +*/ + +#pragma once + +#include + +void analogReadCorrection (int offset, uint16_t gain); + diff --git a/libraries/SAMD_BootloaderUpdater/examples/UpdateBootloader/UpdateBootloader.ino b/libraries/SAMD_BootloaderUpdater/examples/UpdateBootloader/UpdateBootloader.ino new file mode 100644 index 0000000..1bb76bf --- /dev/null +++ b/libraries/SAMD_BootloaderUpdater/examples/UpdateBootloader/UpdateBootloader.ino @@ -0,0 +1,88 @@ +/* + Update Bootloader + + This sketch checks if your Arduino SAMD board is running the latest bootloader. + + If it is not, it prompts you to update it. + + Circuit: + - MKR Vidor 4000 + + This example code is in the public domain. +*/ + + +#include + +void setup() { + + Serial.begin(9600); + while (!Serial); + + Serial.println("Welcome to the Arduino SAMD bootloader updater"); + Serial.println("----------------------------------------------"); + Serial.println(); + +retry: + Serial.print("Checking if bootloader requires an update ... "); + if (SAMD_BootloaderUpdater.needsUpdate()) { + Serial.println("bootloader is already the latest version"); + Serial.println(); + Serial.println("Update is not required :)"); + + while (1); + } + + Serial.println("bootloader is NOT running the latest"); + Serial.println(); + Serial.println(); + Serial.println("Would you like to proceed with updating it? (y/N)"); + Serial.println(); + + + while (Serial.available() == 0) { + delay(100); + } + char in = Serial.read(); + if (in != 'y' && in != 'Y') { + Serial.println("That's all folks!"); + while (1); + } + + pinMode(LED_BUILTIN, OUTPUT); + + Serial.println("WARNING: DO NOT UNPLUG the USB cable during the update!!!"); + Serial.println(); + Serial.println("Updating bootloader ..."); + Serial.println(); + + if (!SAMD_BootloaderUpdater.update(onUpdateProgress)) { + Serial.println("oh no! the bootloader failed to update :("); + Serial.println(); + goto retry; + } + + Serial.println(); + Serial.println("The bootloader was successfully updated \\o/"); + Serial.println(); + Serial.println("Your board will now start blinking in joy :)"); +} + +void onUpdateProgress(float percentage) +{ + // toggle the LED + digitalWrite(LED_BUILTIN, digitalRead(LED_BUILTIN) ? LOW : HIGH); + + // print out the percentage + Serial.print(percentage); + Serial.println("%"); +} + +void loop() { + digitalWrite(LED_BUILTIN, HIGH); + delay(100); + + digitalWrite(LED_BUILTIN, LOW); + delay(100); +} + diff --git a/libraries/SAMD_BootloaderUpdater/extras/build.sh b/libraries/SAMD_BootloaderUpdater/extras/build.sh new file mode 100755 index 0000000..c2f4538 --- /dev/null +++ b/libraries/SAMD_BootloaderUpdater/extras/build.sh @@ -0,0 +1,12 @@ +#!/bin/sh -x + +ARDUINO=arduino +BOOTLOADER_DIR=" ../../../bootloaders" +OUTPUT_PATH="../src/bootloaders" + +if [[ "$OSTYPE" == "darwin"* ]]; then + ARDUINO="/Applications/Arduino.app/Contents/MacOS/Arduino" +fi + +ls $BOOTLOADER_DIR/mkrvidor4000 +cat $BOOTLOADER_DIR/mkrvidor4000/samd21_sam_ba_arduino_mkrvidor4000.bin | xxd -i > $OUTPUT_PATH/mkrvidor4000.h diff --git a/libraries/SAMD_BootloaderUpdater/keywords.txt b/libraries/SAMD_BootloaderUpdater/keywords.txt new file mode 100644 index 0000000..07164e9 --- /dev/null +++ b/libraries/SAMD_BootloaderUpdater/keywords.txt @@ -0,0 +1,21 @@ +################################################ +# Syntax Coloring Map For SAMD_BootloaderUpdater +################################################ + +################################################ +# Datatypes (KEYWORD1) +################################################ + +SAMD_BootloaderUpdater KEYWORD2 + +################################################ +# Methods and Functions (KEYWORD2) +################################################ + +needsUpdate KEYWORD2 +update KEYWORD2 + +####################################### +# Constants (LITERAL1) +####################################### + diff --git a/libraries/SAMD_BootloaderUpdater/library.properties b/libraries/SAMD_BootloaderUpdater/library.properties new file mode 100644 index 0000000..d5148eb --- /dev/null +++ b/libraries/SAMD_BootloaderUpdater/library.properties @@ -0,0 +1,9 @@ +name=SAMD_BootloaderUpdater +version=1.0 +author=Arduino +maintainer=Arduino +sentence=Update the bootloader running on your Arduino SAMD board to the latest. +paragraph= +category=Other +url= +architectures=samd_beta diff --git a/libraries/SAMD_BootloaderUpdater/src/SAMD_BootloaderUpdater.cpp b/libraries/SAMD_BootloaderUpdater/src/SAMD_BootloaderUpdater.cpp new file mode 100644 index 0000000..0392536 --- /dev/null +++ b/libraries/SAMD_BootloaderUpdater/src/SAMD_BootloaderUpdater.cpp @@ -0,0 +1,116 @@ +/* + This file is part of the SAMD Bootloader Updater library. + Copyright (c) 2018 Arduino SA. All rights 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 Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ + +#include "SAMD_BootloaderUpdater.h" + +#define PAGE_SIZE (64) +#define PAGES (4096) +#define MAX_FLASH (PAGE_SIZE * PAGES) +#define ROW_SIZE (PAGE_SIZE * 4) + +__attribute__((aligned (4))) +const uint8_t booloaderData[8192] = { +#if defined(ARDUINO_SAMD_MKRVIDOR4000) + #include "bootloaders/mkrvidor4000.h" +#else + #error "Unsupported board!" +#endif +}; + +#define BOOTLOADER_START 0x00000000 +#define USER_ROW_START 0x00804000 + +extern "C" { + // these functions must be in RAM (.data) and NOT inlined + // as they erase and copy the sketch data in flash + + __attribute__ ((long_call, noinline, section (".data#"))) + static void eraseFlash(uint32_t address, int length) + { + for (int i = 0; i < length; i += ROW_SIZE) { + NVMCTRL->ADDR.reg = ((uint32_t)((uint32_t)address + i)) / 2; + NVMCTRL->CTRLA.reg = NVMCTRL_CTRLA_CMDEX_KEY | NVMCTRL_CTRLA_CMD_ER; + + while (!NVMCTRL->INTFLAG.bit.READY); + } + } + + __attribute__ ((long_call, noinline, section (".data#"))) + static void readFlash(uint32_t src, void* dest, int length) + { + memcpy(dest, (void*)src, length); + } + + __attribute__ ((long_call, noinline, section (".data#"))) + static void writeFlash(uint32_t dest, const void* src, int length) + { + volatile uint32_t* d = (uint32_t*)dest; + const volatile uint32_t* s = (const uint32_t*)src; + + for (int i = 0; i < length; i += 4) { + *d++ = *s++; + + while (!NVMCTRL->INTFLAG.bit.READY); + } + } +} + +bool SAMD_BootloaderUpdaterClass::needsUpdate() +{ + return (memcmp(BOOTLOADER_START, booloaderData, sizeof(booloaderData)) == 0); +} + +int SAMD_BootloaderUpdaterClass::update(void(*progressCallback)(float)) +{ + // enable auto page writes + NVMCTRL->CTRLB.bit.MANW = 0; + + // read the user row + uint32_t userRow[PAGE_SIZE / sizeof(uint32_t)]; + readFlash(USER_ROW_START, userRow, sizeof(userRow)); + + if ((userRow[0] & 0x00000007) != 0x00000007) { + // bootloader is protected, unprotect it + userRow[0] |= 0x00000007; + + // erase the user row and flash the updated value + eraseFlash(USER_ROW_START, sizeof(userRow)); + writeFlash(USER_ROW_START, userRow, sizeof(userRow)); + } + + if (progressCallback) { + progressCallback(0.0); + } + + #define CHUNK_SIZE (ROW_SIZE * 2) + + // erase and copy the flash row by row + for (size_t i = 0; i < sizeof(booloaderData); i += CHUNK_SIZE) { + eraseFlash(BOOTLOADER_START + i, CHUNK_SIZE); + writeFlash(BOOTLOADER_START + i, &booloaderData[i], CHUNK_SIZE); + + if (progressCallback) { + progressCallback((i + CHUNK_SIZE) * 100.0 / sizeof(booloaderData)); + } + } + + return needsUpdate() ? 1 : 0; +} + +SAMD_BootloaderUpdaterClass SAMD_BootloaderUpdater; diff --git a/libraries/SAMD_BootloaderUpdater/src/SAMD_BootloaderUpdater.h b/libraries/SAMD_BootloaderUpdater/src/SAMD_BootloaderUpdater.h new file mode 100644 index 0000000..5598dff --- /dev/null +++ b/libraries/SAMD_BootloaderUpdater/src/SAMD_BootloaderUpdater.h @@ -0,0 +1,34 @@ +/* + This file is part of the SAMD Bootloader Updater library. + Copyright (c) 2018 Arduino SA. All rights 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 Street, Fifth Floor, Boston, MA 02110-1301 USA +*/ + +#ifndef _SAMD_BOOTLOADER_UPDATER_H_ +#define _SAMD_BOOTLOADER_UPDATER_H_ + +#include + +class SAMD_BootloaderUpdaterClass { +public: + bool needsUpdate(); + + int update(void(*progressCallback)(float)); +}; + +extern SAMD_BootloaderUpdaterClass SAMD_BootloaderUpdater; + +#endif diff --git a/libraries/SAMD_BootloaderUpdater/src/bootloaders/mkrvidor4000.h b/libraries/SAMD_BootloaderUpdater/src/bootloaders/mkrvidor4000.h new file mode 100644 index 0000000..07e33fd --- /dev/null +++ b/libraries/SAMD_BootloaderUpdater/src/bootloaders/mkrvidor4000.h @@ -0,0 +1,680 @@ + 0xfc, 0x7f, 0x00, 0x20, 0xc5, 0x16, 0x00, 0x00, 0x99, 0x01, 0x00, 0x00, + 0x95, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x91, 0x01, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x8d, 0x01, 0x00, 0x00, + 0x11, 0x01, 0x00, 0x00, 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, + 0x07, 0xd1, 0x05, 0x4b, 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, + 0x00, 0xbf, 0x01, 0x23, 0x23, 0x70, 0x10, 0xbd, 0x5c, 0x00, 0x00, 0x20, + 0x00, 0x00, 0x00, 0x00, 0x7c, 0x1f, 0x00, 0x00, 0x04, 0x4b, 0x10, 0xb5, + 0x00, 0x2b, 0x03, 0xd0, 0x03, 0x49, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, + 0x10, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x20, + 0x7c, 0x1f, 0x00, 0x00, 0x03, 0x00, 0x10, 0xb5, 0x08, 0x00, 0x11, 0x00, + 0x98, 0x47, 0x64, 0x22, 0x01, 0x4b, 0x1a, 0x80, 0x10, 0xbd, 0xc0, 0x46, + 0x78, 0x00, 0x00, 0x20, 0xf0, 0xb5, 0x19, 0x4b, 0x0a, 0x00, 0x99, 0x78, + 0x85, 0xb0, 0x5c, 0x68, 0x00, 0x29, 0x29, 0xd0, 0x04, 0x2a, 0x1f, 0xd1, + 0x00, 0x68, 0x0f, 0x26, 0x30, 0x27, 0x52, 0x00, 0x04, 0xab, 0x9b, 0x18, + 0x0b, 0x3b, 0x9d, 0x1a, 0x01, 0x00, 0x31, 0x40, 0x09, 0x29, 0x19, 0xd8, + 0x39, 0x43, 0x19, 0x70, 0x01, 0x3b, 0x00, 0x09, 0x9d, 0x42, 0xf5, 0xd1, + 0x0a, 0x20, 0x0c, 0x4b, 0x01, 0xa9, 0x0b, 0x80, 0x8b, 0x18, 0x98, 0x70, + 0x03, 0x30, 0xd8, 0x70, 0x04, 0x32, 0xe0, 0x68, 0xff, 0xf7, 0xcc, 0xff, + 0x05, 0xb0, 0xf0, 0xbd, 0x02, 0x2a, 0x01, 0xd1, 0x00, 0x88, 0xdc, 0xe7, + 0x00, 0x78, 0xda, 0xe7, 0x37, 0x31, 0xe4, 0xe7, 0x01, 0x00, 0xf0, 0xe7, + 0x78, 0x00, 0x00, 0x20, 0x30, 0x78, 0x00, 0x00, 0x1b, 0x4a, 0x1c, 0x4b, + 0x11, 0x7a, 0x00, 0x29, 0x08, 0xd1, 0x19, 0x78, 0x58, 0x78, 0x09, 0x18, + 0x80, 0x20, 0xc9, 0xb2, 0x59, 0x70, 0x18, 0x49, 0x40, 0x00, 0x08, 0x60, + 0x11, 0x7a, 0x01, 0x31, 0xc9, 0xb2, 0x11, 0x72, 0x59, 0x78, 0xf0, 0x29, + 0x02, 0xd8, 0x59, 0x78, 0x09, 0x29, 0x08, 0xd8, 0x19, 0x78, 0x49, 0x42, + 0x49, 0xb2, 0x19, 0x70, 0x19, 0x78, 0x58, 0x78, 0x09, 0x18, 0xc9, 0xb2, + 0x59, 0x70, 0x11, 0x7a, 0x5b, 0x78, 0x99, 0x42, 0x03, 0xd1, 0x80, 0x21, + 0x0a, 0x4b, 0x49, 0x00, 0x19, 0x60, 0x13, 0x88, 0x00, 0x2b, 0x03, 0xd0, + 0x13, 0x88, 0x01, 0x3b, 0x9b, 0xb2, 0x13, 0x80, 0x53, 0x89, 0x00, 0x2b, + 0x03, 0xd0, 0x53, 0x89, 0x01, 0x3b, 0x9b, 0xb2, 0x53, 0x81, 0x70, 0x47, + 0x78, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0x9c, 0x44, 0x00, 0x41, + 0x02, 0xbe, 0xfe, 0xe7, 0x05, 0xbe, 0xfe, 0xe7, 0x0d, 0xbe, 0xfe, 0xe7, + 0x0e, 0xbe, 0xfe, 0xe7, 0x07, 0x4a, 0xff, 0x30, 0x53, 0x69, 0x9b, 0x0b, + 0x9b, 0x03, 0x53, 0x61, 0x02, 0x23, 0x03, 0x72, 0x82, 0x79, 0x82, 0x3b, + 0x13, 0x43, 0x83, 0x71, 0x03, 0x7a, 0x9b, 0x07, 0xfc, 0xd5, 0x70, 0x47, + 0x2c, 0x02, 0x00, 0x20, 0x80, 0x21, 0x02, 0x00, 0x0a, 0x4b, 0xc9, 0x01, + 0x00, 0x28, 0x0e, 0xd0, 0x99, 0x61, 0x80, 0x21, 0x89, 0x01, 0x99, 0x61, + 0x59, 0x61, 0x07, 0x4b, 0x18, 0x7b, 0x40, 0x00, 0x80, 0x18, 0x06, 0x4a, + 0x80, 0x00, 0x80, 0x58, 0x18, 0x73, 0xc0, 0xb2, 0x70, 0x47, 0x59, 0x61, + 0xef, 0xe7, 0xc0, 0x46, 0x00, 0x44, 0x00, 0x41, 0x78, 0x00, 0x00, 0x20, + 0xac, 0x1c, 0x00, 0x00, 0x0c, 0x4b, 0x10, 0xb5, 0x1b, 0x7b, 0x08, 0x2b, + 0x10, 0xd0, 0x0f, 0x2b, 0x0e, 0xd0, 0x01, 0x20, 0xff, 0xf7, 0xd8, 0xff, + 0x01, 0x20, 0xff, 0xf7, 0xd5, 0xff, 0x01, 0x20, 0xff, 0xf7, 0xd2, 0xff, + 0x01, 0x20, 0xff, 0xf7, 0xcf, 0xff, 0x01, 0x20, 0xff, 0xf7, 0xcc, 0xff, + 0x00, 0x20, 0xff, 0xf7, 0xc9, 0xff, 0x10, 0xbd, 0x78, 0x00, 0x00, 0x20, + 0x0d, 0x4b, 0x10, 0xb5, 0x1b, 0x7b, 0x0f, 0x2b, 0x0a, 0xd0, 0x08, 0x2b, + 0x08, 0xd0, 0x01, 0x24, 0xa3, 0x42, 0x0f, 0xd8, 0x00, 0x20, 0xff, 0xf7, + 0xb9, 0xff, 0x00, 0x20, 0xff, 0xf7, 0xb6, 0xff, 0x01, 0x20, 0xff, 0xf7, + 0xb3, 0xff, 0x00, 0x20, 0xff, 0xf7, 0xb0, 0xff, 0x00, 0x20, 0xff, 0xf7, + 0xad, 0xff, 0x00, 0x24, 0x20, 0x00, 0x10, 0xbd, 0x78, 0x00, 0x00, 0x20, + 0x07, 0x4b, 0x10, 0xb5, 0x1b, 0x7b, 0x01, 0x24, 0x0b, 0x2b, 0x06, 0xd1, + 0x20, 0x00, 0xff, 0xf7, 0x9f, 0xff, 0x20, 0x00, 0xff, 0xf7, 0x9c, 0xff, + 0x00, 0x24, 0x20, 0x00, 0x10, 0xbd, 0xc0, 0x46, 0x78, 0x00, 0x00, 0x20, + 0xf0, 0xb5, 0x87, 0xb0, 0x03, 0x90, 0x00, 0x20, 0x01, 0x26, 0x04, 0x00, + 0x07, 0x00, 0xb4, 0x46, 0x5e, 0x40, 0x01, 0x92, 0x05, 0x96, 0x03, 0x9b, + 0x9f, 0x42, 0x01, 0xd1, 0x07, 0xb0, 0xf0, 0xbd, 0x00, 0x2c, 0x04, 0xd1, + 0xff, 0x25, 0x00, 0x29, 0x01, 0xd0, 0x0d, 0x78, 0x01, 0x31, 0x62, 0x46, + 0x18, 0x4b, 0x40, 0x08, 0x1e, 0x6a, 0xf6, 0x0b, 0x16, 0x40, 0xf6, 0x01, + 0x30, 0x43, 0x66, 0x46, 0x03, 0x9a, 0x2e, 0x40, 0x04, 0x96, 0x56, 0x1e, + 0x62, 0x46, 0x02, 0x92, 0xbe, 0x42, 0x01, 0xd1, 0x05, 0x9a, 0x02, 0x92, + 0x04, 0x9a, 0x00, 0x2a, 0x18, 0xd0, 0x80, 0x22, 0x52, 0x01, 0x9a, 0x61, + 0x02, 0x9a, 0x00, 0x2a, 0x03, 0xd0, 0x80, 0x26, 0xb6, 0x01, 0x9e, 0x61, + 0x5e, 0x61, 0x07, 0x23, 0x6d, 0x08, 0x01, 0x34, 0xed, 0xb2, 0x1c, 0x40, + 0x06, 0xd1, 0x01, 0x9b, 0x00, 0x2b, 0x03, 0xd0, 0x18, 0x70, 0x20, 0x00, + 0x01, 0x33, 0x01, 0x93, 0x01, 0x37, 0xc4, 0xe7, 0x80, 0x22, 0x52, 0x01, + 0x5a, 0x61, 0xe5, 0xe7, 0x00, 0x44, 0x00, 0x41, 0xf7, 0xb5, 0x01, 0x24, + 0x62, 0x40, 0x01, 0x92, 0x80, 0x22, 0x00, 0x23, 0x52, 0x01, 0x06, 0x00, + 0x94, 0x46, 0x18, 0x00, 0xb3, 0x42, 0x00, 0xd1, 0xfe, 0xbd, 0x0f, 0x4a, + 0x27, 0x00, 0x15, 0x6a, 0xed, 0x0b, 0x25, 0x40, 0x9d, 0x40, 0x28, 0x43, + 0x0d, 0x00, 0x25, 0x40, 0x00, 0x95, 0x75, 0x1e, 0x9d, 0x42, 0x00, 0xd1, + 0x01, 0x9f, 0x00, 0x9d, 0x00, 0x2d, 0x0a, 0xd0, 0x65, 0x46, 0x95, 0x61, + 0x00, 0x2f, 0x03, 0xd0, 0x80, 0x25, 0xad, 0x01, 0x95, 0x61, 0x55, 0x61, + 0x49, 0x10, 0x01, 0x33, 0xe0, 0xe7, 0x65, 0x46, 0x55, 0x61, 0xf3, 0xe7, + 0x00, 0x44, 0x00, 0x41, 0x15, 0x4b, 0x10, 0xb5, 0x1b, 0x7b, 0x04, 0x00, + 0x01, 0x2b, 0x01, 0xd9, 0xff, 0xf7, 0x32, 0xff, 0x00, 0x20, 0xff, 0xf7, + 0x11, 0xff, 0x01, 0x20, 0xff, 0xf7, 0x0e, 0xff, 0x01, 0x20, 0xff, 0xf7, + 0x0b, 0xff, 0x00, 0x20, 0xff, 0xf7, 0x08, 0xff, 0x00, 0x20, 0xff, 0xf7, + 0x05, 0xff, 0x01, 0x22, 0x21, 0x00, 0x0a, 0x20, 0xff, 0xf7, 0xb6, 0xff, + 0x56, 0x23, 0xff, 0x33, 0x98, 0x42, 0x07, 0xd1, 0x01, 0x20, 0xff, 0xf7, + 0xf9, 0xfe, 0x01, 0x20, 0xff, 0xf7, 0xf6, 0xfe, 0x00, 0x20, 0x10, 0xbd, + 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, 0xc0, 0x46, 0x78, 0x00, 0x00, 0x20, + 0xf7, 0xb5, 0x0d, 0x4d, 0x07, 0x00, 0xeb, 0x7b, 0x0e, 0x20, 0x2c, 0x7c, + 0x01, 0x93, 0xff, 0xf7, 0xc9, 0xff, 0x06, 0x1e, 0x0e, 0xdb, 0xff, 0xf7, + 0x1b, 0xff, 0x01, 0x9b, 0x61, 0x1c, 0x99, 0x40, 0xe8, 0x7b, 0xab, 0x7b, + 0x39, 0x43, 0xc0, 0x18, 0x01, 0x22, 0xff, 0xf7, 0x8d, 0xff, 0xff, 0xf7, + 0x2d, 0xff, 0x6f, 0x74, 0x30, 0x00, 0xfe, 0xbd, 0x78, 0x00, 0x00, 0x20, + 0x37, 0xb5, 0x05, 0x00, 0x00, 0x20, 0x12, 0x4b, 0x01, 0x90, 0x5b, 0x7c, + 0x0c, 0x00, 0x83, 0x42, 0x18, 0xd1, 0x0c, 0x20, 0xff, 0xf7, 0xa8, 0xff, + 0xff, 0xf7, 0xfc, 0xfe, 0x01, 0x9b, 0x01, 0xa9, 0x9a, 0x00, 0x03, 0x23, + 0x13, 0x43, 0x01, 0x93, 0x00, 0x23, 0x20, 0x20, 0x1a, 0x00, 0xff, 0xf7, + 0x21, 0xff, 0x00, 0x23, 0x60, 0x01, 0x02, 0x30, 0x1a, 0x00, 0x29, 0x00, + 0xff, 0xf7, 0x1a, 0xff, 0x20, 0x00, 0x3e, 0xbd, 0xff, 0xf7, 0xbe, 0xff, + 0x00, 0x28, 0xfa, 0xdb, 0xe1, 0xe7, 0xc0, 0x46, 0x78, 0x00, 0x00, 0x20, + 0x02, 0x22, 0x63, 0x4b, 0xf0, 0xb5, 0x1a, 0x70, 0x80, 0x23, 0x62, 0x4c, + 0x80, 0x27, 0x80, 0x26, 0x80, 0x25, 0x1b, 0x02, 0x63, 0x60, 0x00, 0x23, + 0x85, 0xb0, 0xad, 0x01, 0xff, 0x01, 0x76, 0x01, 0xa7, 0x60, 0x01, 0x21, + 0xa6, 0x60, 0x03, 0xa8, 0xa5, 0x60, 0x03, 0x93, 0xff, 0xf7, 0xbe, 0xff, + 0x80, 0x23, 0x5b, 0x05, 0xa3, 0x60, 0x63, 0x61, 0xa7, 0x61, 0xa6, 0x61, + 0x65, 0x61, 0xff, 0xf7, 0xa3, 0xfe, 0x55, 0x4d, 0x2b, 0x7b, 0x01, 0x2b, + 0x01, 0xd9, 0xff, 0xf7, 0x9d, 0xfe, 0x00, 0x20, 0xff, 0xf7, 0x7c, 0xfe, + 0x01, 0x20, 0xff, 0xf7, 0x79, 0xfe, 0x01, 0x20, 0xff, 0xf7, 0x76, 0xfe, + 0x00, 0x20, 0xff, 0xf7, 0x73, 0xfe, 0x00, 0x20, 0xff, 0xf7, 0x70, 0xfe, + 0x01, 0x22, 0x04, 0x21, 0x0a, 0x20, 0xff, 0xf7, 0x21, 0xff, 0x01, 0x20, + 0xff, 0xf7, 0x68, 0xfe, 0x01, 0x20, 0xff, 0xf7, 0x65, 0xfe, 0x9a, 0x27, + 0xff, 0xf7, 0x9c, 0xfe, 0x80, 0x22, 0x80, 0x23, 0xff, 0x37, 0x52, 0x01, + 0x9b, 0x01, 0x01, 0x3f, 0x62, 0x61, 0xa3, 0x61, 0x63, 0x61, 0x00, 0x2f, + 0xf9, 0xd1, 0x3a, 0x00, 0x39, 0x00, 0x01, 0x20, 0xff, 0xf7, 0x08, 0xff, + 0x04, 0x00, 0xff, 0xf7, 0xa7, 0xfe, 0xff, 0xf7, 0x6b, 0xfe, 0x00, 0x2c, + 0x03, 0xd1, 0x01, 0x20, 0x40, 0x42, 0x05, 0xb0, 0xf0, 0xbd, 0x0e, 0x20, + 0xff, 0xf7, 0x28, 0xff, 0xff, 0xf7, 0x7c, 0xfe, 0x3a, 0x00, 0x39, 0x00, + 0x40, 0x20, 0xff, 0xf7, 0xf3, 0xfe, 0xff, 0xf7, 0x93, 0xfe, 0x0c, 0x20, + 0xff, 0xf7, 0x1c, 0xff, 0x08, 0x26, 0x3c, 0x00, 0xff, 0xf7, 0x6e, 0xfe, + 0x00, 0x22, 0x04, 0x20, 0x11, 0x00, 0xff, 0xf7, 0xe5, 0xfe, 0x24, 0x09, + 0x00, 0x07, 0x01, 0x3e, 0x04, 0x43, 0xff, 0xf7, 0x81, 0xfe, 0xff, 0xf7, + 0x45, 0xfe, 0x00, 0x2e, 0xee, 0xd1, 0xff, 0x23, 0x62, 0x03, 0x2b, 0x74, + 0x6b, 0x74, 0x52, 0x0d, 0x6e, 0x2a, 0xd2, 0xd1, 0x31, 0x00, 0x01, 0x20, + 0xe2, 0x0c, 0x00, 0x93, 0x13, 0x40, 0x6a, 0x73, 0xae, 0x73, 0x01, 0x93, + 0x32, 0x00, 0x00, 0x9b, 0xf7, 0xb2, 0x1a, 0x40, 0x94, 0x46, 0x02, 0x00, + 0x63, 0x46, 0x9a, 0x40, 0x01, 0x9b, 0x01, 0x36, 0x93, 0x42, 0x26, 0xda, + 0x00, 0x29, 0x00, 0xd0, 0xaf, 0x73, 0x00, 0x27, 0xec, 0x73, 0x6b, 0x7b, + 0x9f, 0x42, 0xb6, 0xda, 0x08, 0x26, 0x00, 0x24, 0xff, 0xf7, 0x38, 0xfe, + 0x00, 0x22, 0x04, 0x20, 0x11, 0x00, 0xff, 0xf7, 0xaf, 0xfe, 0x24, 0x09, + 0x00, 0x07, 0x01, 0x3e, 0x04, 0x43, 0xff, 0xf7, 0x4b, 0xfe, 0xff, 0xf7, + 0x0f, 0xfe, 0x00, 0x2e, 0xee, 0xd1, 0xff, 0x22, 0xe3, 0x0c, 0x13, 0x40, + 0x84, 0x2b, 0x08, 0xd1, 0x64, 0x03, 0x64, 0x0d, 0x6e, 0x2c, 0x04, 0xd1, + 0x2f, 0x74, 0x30, 0x00, 0x99, 0xe7, 0x01, 0x00, 0xca, 0xe7, 0x01, 0x37, + 0xd9, 0xe7, 0xc0, 0x46, 0x4f, 0x44, 0x00, 0x41, 0x00, 0x44, 0x00, 0x41, + 0x78, 0x00, 0x00, 0x20, 0x03, 0x21, 0x0a, 0x4b, 0x01, 0x40, 0x5a, 0x68, + 0x09, 0x48, 0x09, 0x04, 0x10, 0x40, 0x08, 0x43, 0x08, 0x4a, 0x58, 0x60, + 0xd8, 0x69, 0x40, 0x07, 0xc0, 0x0f, 0x00, 0xd1, 0x70, 0x47, 0x01, 0x3a, + 0x00, 0x2a, 0xf7, 0xd1, 0x01, 0x20, 0x40, 0x42, 0xf8, 0xe7, 0xc0, 0x46, + 0x00, 0x08, 0x00, 0x42, 0xff, 0xff, 0xfc, 0xff, 0x52, 0xc3, 0x00, 0x00, + 0xf8, 0xb5, 0x2a, 0x4d, 0x2a, 0x4a, 0x29, 0x00, 0x93, 0x7c, 0x2a, 0x48, + 0x5b, 0x00, 0xdc, 0xb2, 0x6b, 0x8b, 0x9b, 0x06, 0x9b, 0x0f, 0x01, 0x2b, + 0x04, 0xd0, 0x6b, 0x8b, 0x9b, 0x06, 0x9b, 0x0f, 0x02, 0x2b, 0x17, 0xd1, + 0x4b, 0x6a, 0xdb, 0x0a, 0xdb, 0x02, 0x23, 0x43, 0x4b, 0x62, 0x0b, 0x7e, + 0xdb, 0x07, 0x18, 0xd5, 0x4b, 0x8b, 0x5b, 0x07, 0xdb, 0x0f, 0x0e, 0xd1, + 0x18, 0x00, 0x01, 0x27, 0xd4, 0x7c, 0x00, 0x2c, 0x13, 0xd1, 0x00, 0x28, + 0x00, 0xd0, 0xd4, 0x74, 0x03, 0x20, 0xff, 0xf7, 0xbb, 0xff, 0x06, 0xe0, + 0x01, 0x38, 0x83, 0x1c, 0xda, 0xd1, 0x03, 0x20, 0xff, 0xf7, 0xb4, 0xff, + 0x02, 0x24, 0x20, 0x00, 0xf8, 0xbd, 0x01, 0x38, 0x83, 0x1c, 0xe0, 0xd1, + 0xf5, 0xe7, 0x12, 0x4d, 0x12, 0x4e, 0x5d, 0x5d, 0x35, 0x70, 0x12, 0x4d, + 0x0e, 0x7e, 0xf6, 0x07, 0x07, 0xd5, 0x4d, 0x8b, 0x01, 0x33, 0x6d, 0x07, + 0x06, 0xd4, 0x01, 0x3c, 0xe4, 0xb2, 0x38, 0x00, 0xd9, 0xe7, 0x01, 0x3d, + 0x00, 0x2d, 0x07, 0xd1, 0x00, 0x28, 0x00, 0xd0, 0xd4, 0x74, 0x03, 0x20, + 0xff, 0xf7, 0x94, 0xff, 0x03, 0x24, 0xde, 0xe7, 0x4e, 0x8b, 0xf6, 0x07, + 0xe6, 0xd5, 0xf3, 0xe7, 0x00, 0x08, 0x00, 0x42, 0x78, 0x00, 0x00, 0x20, + 0x50, 0xc3, 0x00, 0x00, 0x8c, 0x00, 0x00, 0x20, 0x28, 0x08, 0x00, 0x42, + 0x52, 0xc3, 0x00, 0x00, 0x10, 0xb5, 0x6b, 0x22, 0x02, 0x24, 0x04, 0x4b, + 0x9a, 0x74, 0x18, 0x75, 0xdc, 0x74, 0x59, 0x75, 0xff, 0xf7, 0x94, 0xff, + 0x20, 0x00, 0x10, 0xbd, 0x78, 0x00, 0x00, 0x20, 0x6b, 0x23, 0x10, 0xb5, + 0x23, 0x4c, 0xa3, 0x74, 0x6a, 0x3b, 0xe3, 0x74, 0x20, 0x75, 0xff, 0xf7, + 0x87, 0xff, 0x00, 0x23, 0x98, 0x42, 0x2e, 0xd1, 0xa0, 0x75, 0x1f, 0x48, + 0x1f, 0x4a, 0x03, 0x00, 0x41, 0x8b, 0x89, 0x06, 0x89, 0x0f, 0x01, 0x29, + 0x1c, 0xd1, 0xd7, 0x20, 0x59, 0x6a, 0xc9, 0x0a, 0xc9, 0x02, 0x01, 0x43, + 0x59, 0x62, 0x19, 0x7e, 0x89, 0x07, 0x1e, 0xd5, 0x5a, 0x8b, 0x52, 0x07, + 0x18, 0xd4, 0x01, 0x22, 0xa2, 0x75, 0x1a, 0x7e, 0x92, 0x07, 0xfc, 0xd5, + 0x14, 0x4a, 0x03, 0x20, 0x12, 0x78, 0xe2, 0x75, 0x80, 0x22, 0x59, 0x68, + 0xd2, 0x02, 0x0a, 0x43, 0x5a, 0x60, 0xff, 0xf7, 0x43, 0xff, 0x07, 0xe0, + 0x41, 0x8b, 0x89, 0x06, 0x89, 0x0f, 0x02, 0x29, 0xdd, 0xd0, 0x01, 0x3a, + 0x91, 0x1c, 0xd5, 0xd1, 0xe3, 0x7d, 0x18, 0x00, 0x10, 0xbd, 0x01, 0x3a, + 0x91, 0x1c, 0xf9, 0xd0, 0x19, 0x7e, 0xc9, 0x07, 0xd7, 0xd5, 0xc0, 0x22, + 0x59, 0x68, 0x92, 0x02, 0x0a, 0x43, 0x5a, 0x60, 0xf0, 0xe7, 0xc0, 0x46, + 0x78, 0x00, 0x00, 0x20, 0x00, 0x08, 0x00, 0x42, 0x50, 0xc3, 0x00, 0x00, + 0x28, 0x08, 0x00, 0x42, 0x37, 0xb5, 0x19, 0x4c, 0x01, 0x90, 0x63, 0x7c, + 0x0d, 0x00, 0x00, 0x2b, 0x1f, 0xd1, 0x0c, 0x20, 0xff, 0xf7, 0xd4, 0xfd, + 0xff, 0xf7, 0x28, 0xfd, 0x01, 0x9b, 0x01, 0xa9, 0x9a, 0x00, 0x03, 0x23, + 0x13, 0x43, 0x01, 0x93, 0x00, 0x23, 0x20, 0x20, 0x1a, 0x00, 0xff, 0xf7, + 0x4d, 0xfd, 0x63, 0x7c, 0x01, 0x2b, 0x12, 0xd1, 0x0c, 0x20, 0xff, 0xf7, + 0xc1, 0xfd, 0xff, 0xf7, 0x15, 0xfd, 0x00, 0x23, 0x20, 0x20, 0x2a, 0x00, + 0x19, 0x00, 0xff, 0xf7, 0x3f, 0xfd, 0x00, 0x20, 0x04, 0xe0, 0x00, 0x20, + 0xff, 0xf7, 0xe2, 0xfd, 0x00, 0x28, 0xda, 0xda, 0x3e, 0xbd, 0x01, 0x20, + 0xff, 0xf7, 0xdc, 0xfd, 0x00, 0x28, 0xf9, 0xdb, 0xe6, 0xe7, 0xc0, 0x46, + 0x78, 0x00, 0x00, 0x20, 0x13, 0xb5, 0x0c, 0x00, 0xff, 0xf7, 0xf0, 0xfd, + 0x01, 0x90, 0xa0, 0x42, 0x15, 0xd1, 0x80, 0x22, 0x0c, 0x4b, 0x52, 0x05, + 0x0c, 0x4c, 0x9a, 0x61, 0x5a, 0x61, 0x01, 0x3c, 0x00, 0x2c, 0x0f, 0xd0, + 0x01, 0xa9, 0x00, 0x20, 0xff, 0xf7, 0xb6, 0xff, 0x01, 0x9b, 0x00, 0x2b, + 0xf5, 0xd1, 0x01, 0xa9, 0x01, 0x20, 0xff, 0xf7, 0xaf, 0xff, 0x01, 0x98, + 0x16, 0xbd, 0x0a, 0x20, 0x40, 0x42, 0xfb, 0xe7, 0x01, 0x20, 0xfb, 0xe7, + 0x00, 0x44, 0x00, 0x41, 0xea, 0x03, 0x00, 0x00, 0xf0, 0xb5, 0x12, 0x4c, + 0x0d, 0x00, 0xa5, 0x44, 0x11, 0x4b, 0x01, 0x90, 0x02, 0x91, 0x68, 0x46, + 0x03, 0x21, 0x16, 0x00, 0x00, 0x93, 0x02, 0x27, 0xff, 0xf7, 0xcc, 0xff, + 0xec, 0x1c, 0xa4, 0x08, 0x01, 0x34, 0xb9, 0x00, 0x38, 0x00, 0x69, 0x44, + 0xff, 0xf7, 0x8e, 0xff, 0x7b, 0x1e, 0x01, 0x37, 0x9c, 0x42, 0xf6, 0xdc, + 0x00, 0x23, 0x1a, 0x00, 0x6a, 0x44, 0x12, 0x7b, 0xf2, 0x54, 0x01, 0x33, + 0xab, 0x42, 0xf8, 0xd1, 0x03, 0x4b, 0x9d, 0x44, 0xf0, 0xbd, 0xc0, 0x46, + 0xfc, 0xfb, 0xff, 0xff, 0x05, 0x00, 0x00, 0x01, 0x04, 0x04, 0x00, 0x00, + 0xf8, 0xb5, 0x1a, 0x4f, 0x06, 0x00, 0x3b, 0x7e, 0x08, 0x00, 0x14, 0x00, + 0x00, 0x2b, 0x12, 0xd1, 0x17, 0x4b, 0x18, 0x4a, 0x18, 0x49, 0x1a, 0x64, + 0x5a, 0x6c, 0x92, 0x0b, 0x92, 0x03, 0x5a, 0x64, 0x5a, 0x6c, 0x0a, 0x40, + 0x5a, 0x64, 0xa2, 0x22, 0x40, 0x23, 0x52, 0x00, 0xb1, 0x5c, 0x0b, 0x43, + 0xb3, 0x54, 0x01, 0x23, 0x3b, 0x76, 0x48, 0x25, 0xff, 0x35, 0x73, 0x5d, + 0xdb, 0x07, 0xdb, 0x0f, 0x12, 0xd0, 0x0b, 0x4a, 0x53, 0x6c, 0x9b, 0x04, + 0x9b, 0x0c, 0x9c, 0x42, 0x02, 0xd9, 0x54, 0x6c, 0xa4, 0x04, 0xa4, 0x0c, + 0x22, 0x00, 0x07, 0x49, 0x01, 0xf0, 0x69, 0xf9, 0x01, 0x23, 0x73, 0x55, + 0x00, 0x23, 0x3b, 0x76, 0x20, 0x00, 0xf8, 0xbd, 0x1c, 0x00, 0xfb, 0xe7, + 0x78, 0x00, 0x00, 0x20, 0x2c, 0x02, 0x00, 0x20, 0xec, 0x01, 0x00, 0x20, + 0xff, 0x3f, 0x00, 0xf0, 0x13, 0xb5, 0x6b, 0x46, 0xdc, 0x1d, 0x04, 0x4b, + 0x01, 0x22, 0x21, 0x00, 0xd8, 0x69, 0xff, 0xf7, 0xb9, 0xff, 0x20, 0x78, + 0x16, 0xbd, 0xc0, 0x46, 0x78, 0x00, 0x00, 0x20, 0xf7, 0xb5, 0x00, 0x90, + 0x01, 0x20, 0x1c, 0x4d, 0x1c, 0x00, 0x5b, 0x01, 0x16, 0x00, 0x01, 0x93, + 0xea, 0x18, 0x53, 0x69, 0x10, 0x32, 0x5b, 0x00, 0x5b, 0x0f, 0x03, 0x33, + 0x98, 0x40, 0xb0, 0x42, 0x21, 0xd8, 0x80, 0x23, 0x50, 0x68, 0x1b, 0x06, + 0x03, 0x43, 0x53, 0x60, 0x63, 0x01, 0xed, 0x18, 0x29, 0x61, 0x6b, 0x69, + 0xb1, 0x04, 0x9b, 0x0b, 0x89, 0x0c, 0x9b, 0x03, 0x0b, 0x43, 0x6b, 0x61, + 0x6b, 0x69, 0x0e, 0x49, 0x08, 0x34, 0x0b, 0x40, 0x6b, 0x61, 0x00, 0x9b, + 0x64, 0x01, 0x1c, 0x19, 0x02, 0x23, 0xe3, 0x71, 0x62, 0x79, 0x82, 0x3b, + 0x13, 0x43, 0x63, 0x71, 0xe3, 0x79, 0x9b, 0x07, 0xfc, 0xd5, 0x30, 0x00, + 0xfe, 0xbd, 0x06, 0x4b, 0xa7, 0x01, 0xff, 0x18, 0x32, 0x00, 0x38, 0x00, + 0x01, 0xf0, 0x11, 0xf9, 0x39, 0x00, 0xd9, 0xe7, 0x2c, 0x02, 0x00, 0x20, + 0xff, 0x3f, 0x00, 0xf0, 0x2c, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x0c, 0x00, + 0x0a, 0x00, 0x01, 0x00, 0x03, 0x48, 0x01, 0x23, 0xc0, 0x69, 0xff, 0xf7, + 0xb5, 0xff, 0x20, 0x00, 0x10, 0xbd, 0xc0, 0x46, 0x78, 0x00, 0x00, 0x20, + 0x01, 0x23, 0x07, 0xb5, 0x01, 0x90, 0x04, 0x48, 0x1a, 0x00, 0x01, 0xa9, + 0xc0, 0x69, 0xff, 0xf7, 0xa7, 0xff, 0x01, 0x20, 0x0e, 0xbd, 0xc0, 0x46, + 0x78, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x0b, 0x4c, 0x0b, 0x4b, 0xa5, 0x44, + 0x0c, 0x00, 0x01, 0x90, 0x11, 0x00, 0x03, 0xa8, 0x22, 0x00, 0x00, 0x93, + 0x02, 0x94, 0x01, 0xf0, 0xe0, 0xf8, 0xe1, 0x1c, 0x89, 0x08, 0x03, 0x31, + 0x68, 0x46, 0xff, 0xf7, 0xf1, 0xfe, 0x80, 0x23, 0xdb, 0x00, 0x9d, 0x44, + 0x10, 0xbd, 0xc0, 0x46, 0x00, 0xfc, 0xff, 0xff, 0x04, 0x00, 0x00, 0x01, + 0xf0, 0xb5, 0xcb, 0x4b, 0xcb, 0x4c, 0xca, 0x48, 0x5b, 0x68, 0xa5, 0x44, + 0x00, 0xaf, 0x28, 0x30, 0x1b, 0x69, 0x40, 0x21, 0x98, 0x47, 0x00, 0x28, + 0x02, 0xd0, 0x64, 0x23, 0xc4, 0x4a, 0x53, 0x81, 0xc3, 0x4b, 0xc3, 0x4a, + 0x98, 0x66, 0x28, 0x33, 0xd3, 0x66, 0x00, 0x23, 0x13, 0x67, 0xc0, 0x4b, + 0x1b, 0x6f, 0xfb, 0x60, 0xbe, 0x4b, 0x9b, 0x6e, 0xbb, 0x60, 0xba, 0x68, + 0xfb, 0x68, 0x93, 0x42, 0x00, 0xd3, 0xb2, 0xe1, 0xba, 0x4b, 0xdb, 0x6e, + 0xfb, 0x60, 0x1b, 0x78, 0xff, 0x2b, 0x63, 0xd0, 0x23, 0x2b, 0x00, 0xd0, + 0x5c, 0xe3, 0xb6, 0x4b, 0x9b, 0x78, 0x00, 0x2b, 0x06, 0xd0, 0xb4, 0x4b, + 0x02, 0x22, 0x5b, 0x68, 0xb4, 0x49, 0xd8, 0x68, 0xff, 0xf7, 0xda, 0xfa, + 0xb0, 0x48, 0x74, 0x30, 0x03, 0x78, 0x53, 0x2b, 0x5d, 0xd1, 0xae, 0x4b, + 0xad, 0x4a, 0x9b, 0x6e, 0x14, 0x6f, 0xa3, 0x42, 0x1f, 0xd9, 0xab, 0x49, + 0x92, 0x6f, 0xc9, 0x6e, 0x01, 0x34, 0x4d, 0x1c, 0xf9, 0x60, 0xa8, 0x49, + 0x1b, 0x1b, 0xcd, 0x66, 0x0c, 0x67, 0x93, 0x42, 0x48, 0xd2, 0xcb, 0x67, + 0xa4, 0x4b, 0xa7, 0x4e, 0xdb, 0x6f, 0x29, 0x00, 0x1a, 0x00, 0x30, 0x68, + 0xfb, 0x60, 0x01, 0xf0, 0x7a, 0xf8, 0xfb, 0x68, 0xe4, 0x18, 0x9f, 0x4b, + 0x1c, 0x67, 0xfb, 0x68, 0xed, 0x18, 0x9d, 0x4b, 0xdd, 0x66, 0x3b, 0x7b, + 0x33, 0x71, 0x9b, 0x4b, 0x9a, 0x4a, 0x1b, 0x6f, 0x99, 0x49, 0x01, 0x3b, + 0x13, 0x67, 0xd3, 0x6e, 0x89, 0x6f, 0xfb, 0x60, 0x01, 0x3b, 0xd3, 0x66, + 0x98, 0x4b, 0x1a, 0x79, 0x8a, 0x42, 0x0a, 0xd2, 0x89, 0x1a, 0x93, 0x4a, + 0x18, 0x68, 0x52, 0x68, 0x92, 0x69, 0x90, 0x47, 0x00, 0x28, 0x02, 0xd0, + 0x64, 0x23, 0x8f, 0x4a, 0x53, 0x81, 0xc0, 0x46, 0x7a, 0x22, 0x8d, 0x4b, + 0x74, 0x33, 0x1a, 0x70, 0x00, 0x23, 0x8b, 0x4a, 0x93, 0x67, 0x93, 0x78, + 0x00, 0x2b, 0x05, 0xd0, 0x53, 0x68, 0x8c, 0x49, 0x01, 0x22, 0xd8, 0x68, + 0xff, 0xf7, 0x84, 0xfa, 0x85, 0x4b, 0x85, 0x4a, 0x1b, 0x6f, 0x01, 0x33, + 0x13, 0x67, 0xd3, 0x6e, 0xfb, 0x60, 0x01, 0x33, 0xd3, 0x66, 0x80, 0xe7, + 0x80, 0x4b, 0xda, 0x67, 0xb4, 0xe7, 0x52, 0x2b, 0x09, 0xd1, 0x7e, 0x4b, + 0x7d, 0x4a, 0x5b, 0x68, 0x7f, 0x49, 0x92, 0x6f, 0x09, 0x68, 0x58, 0x69, + 0xff, 0xf7, 0x6c, 0xfa, 0xd6, 0xe7, 0x4f, 0x2b, 0x07, 0xd1, 0x78, 0x4a, + 0x7a, 0x4b, 0x92, 0x6f, 0x1b, 0x68, 0xfa, 0x60, 0x3a, 0x7b, 0x1a, 0x70, + 0xcc, 0xe7, 0x48, 0x2b, 0x07, 0xd1, 0x73, 0x4a, 0x75, 0x4b, 0x92, 0x6f, + 0x1b, 0x68, 0xfa, 0x60, 0xba, 0x89, 0x1a, 0x80, 0xc2, 0xe7, 0x57, 0x2b, + 0x06, 0xd1, 0x71, 0x4b, 0x6d, 0x4a, 0x1b, 0x68, 0x92, 0x6f, 0xfa, 0x60, + 0x1a, 0x60, 0xb9, 0xe7, 0x6f, 0x2b, 0x05, 0xd1, 0x01, 0x21, 0x6c, 0x4b, + 0x18, 0x68, 0xff, 0xf7, 0x53, 0xfa, 0xb1, 0xe7, 0x68, 0x2b, 0x07, 0xd1, + 0x68, 0x4b, 0x65, 0x4a, 0x1b, 0x68, 0x04, 0x30, 0x1b, 0x88, 0x02, 0x21, + 0x93, 0x67, 0xf2, 0xe7, 0x77, 0x2b, 0x09, 0xd1, 0x63, 0x4b, 0x04, 0x30, + 0x1b, 0x68, 0x04, 0x21, 0x1b, 0x68, 0xfb, 0x60, 0xfa, 0x68, 0x5d, 0x4b, + 0x9a, 0x67, 0xe6, 0xe7, 0x47, 0x2b, 0x19, 0xd1, 0x5a, 0x4b, 0x99, 0x6f, + 0x72, 0xb6, 0xef, 0xf3, 0x08, 0x82, 0x5b, 0x4b, 0x9a, 0x60, 0x0a, 0x68, + 0x82, 0xf3, 0x08, 0x88, 0x4a, 0x68, 0x10, 0x47, 0x9a, 0x68, 0x82, 0xf3, + 0x08, 0x88, 0x62, 0xb6, 0x1b, 0x7b, 0x00, 0x2b, 0x00, 0xd1, 0x85, 0xe7, + 0x50, 0x4b, 0x06, 0x20, 0x5b, 0x68, 0x1b, 0x68, 0x98, 0x47, 0x7f, 0xe7, + 0x54, 0x2b, 0x0a, 0xd1, 0x4c, 0x4a, 0x53, 0x3b, 0x93, 0x70, 0x13, 0x00, + 0x02, 0x22, 0x5b, 0x68, 0x4b, 0x49, 0xd8, 0x68, 0xff, 0xf7, 0x08, 0xfa, + 0x72, 0xe7, 0x4e, 0x2b, 0x0e, 0xd1, 0x46, 0x4b, 0x9b, 0x78, 0x00, 0x2b, + 0x06, 0xd1, 0x44, 0x4b, 0x02, 0x22, 0x5b, 0x68, 0x44, 0x49, 0xd8, 0x68, + 0xff, 0xf7, 0xfa, 0xf9, 0x00, 0x23, 0x40, 0x4a, 0x93, 0x70, 0x61, 0xe7, + 0x56, 0x2b, 0x62, 0xd1, 0x3d, 0x4b, 0x01, 0x22, 0x5b, 0x68, 0x41, 0x49, + 0xd8, 0x68, 0xff, 0xf7, 0xed, 0xf9, 0x3a, 0x4b, 0x3f, 0x4d, 0x5b, 0x68, + 0x03, 0x22, 0x29, 0x00, 0xd8, 0x68, 0xff, 0xf7, 0xe5, 0xf9, 0x36, 0x4b, + 0x3c, 0x4c, 0x5b, 0x68, 0x01, 0x22, 0x21, 0x00, 0xd8, 0x68, 0xff, 0xf7, + 0xdd, 0xf9, 0x32, 0x4b, 0x29, 0x1d, 0x5b, 0x68, 0x0d, 0x22, 0xd8, 0x68, + 0xff, 0xf7, 0xd6, 0xf9, 0x2e, 0x4b, 0x01, 0x22, 0x5b, 0x68, 0x21, 0x00, + 0xd8, 0x68, 0xff, 0xf7, 0xcf, 0xf9, 0x00, 0x23, 0x01, 0x20, 0x2a, 0x4a, + 0x84, 0x46, 0x13, 0x67, 0x1a, 0x00, 0x30, 0x49, 0x4e, 0x1c, 0x8d, 0x5c, + 0xb0, 0x18, 0x00, 0x2d, 0x2b, 0xd1, 0x00, 0x2b, 0x01, 0xd0, 0x24, 0x4b, + 0x1a, 0x67, 0x23, 0x4b, 0x22, 0x4a, 0xd8, 0x66, 0x5b, 0x68, 0x12, 0x6f, + 0xd8, 0x68, 0xff, 0xf7, 0xb7, 0xf9, 0x1f, 0x4b, 0x01, 0x22, 0x5b, 0x68, + 0x21, 0x00, 0xd8, 0x68, 0xff, 0xf7, 0xb0, 0xf9, 0x00, 0x23, 0x1b, 0x4a, + 0x01, 0x26, 0x13, 0x67, 0x1a, 0x00, 0x22, 0x49, 0x4d, 0x1c, 0x8c, 0x5c, + 0xa8, 0x18, 0x00, 0x2c, 0x10, 0xd1, 0x00, 0x2b, 0x01, 0xd0, 0x15, 0x4b, + 0x1a, 0x67, 0x14, 0x4b, 0x13, 0x4a, 0xd8, 0x66, 0x5b, 0x68, 0x12, 0x6f, + 0xd8, 0x68, 0xff, 0xf7, 0x99, 0xf9, 0x10, 0x4b, 0x88, 0xe7, 0x01, 0x32, + 0x63, 0x46, 0xcc, 0xe7, 0x01, 0x32, 0x33, 0x00, 0xe7, 0xe7, 0x58, 0x2b, + 0x30, 0xd1, 0x0e, 0x4a, 0x0a, 0x4b, 0x10, 0x69, 0x52, 0x69, 0x9b, 0x6f, + 0x12, 0x49, 0x13, 0x4c, 0x92, 0x00, 0x98, 0x42, 0x04, 0xd8, 0x06, 0x4b, + 0x03, 0x22, 0x5b, 0x68, 0x10, 0x49, 0x74, 0xe7, 0x5d, 0x08, 0xcd, 0x61, + 0x0c, 0x80, 0x0d, 0x7d, 0xed, 0x07, 0xfc, 0xd5, 0x9b, 0x18, 0xf0, 0xe7, + 0x78, 0x00, 0x00, 0x20, 0x5c, 0xef, 0xff, 0xff, 0x54, 0x1f, 0x00, 0x00, + 0xf8, 0x00, 0x00, 0x20, 0x57, 0x1f, 0x00, 0x00, 0x2c, 0x1f, 0x00, 0x00, + 0x44, 0x1c, 0x00, 0x00, 0x2e, 0x1f, 0x00, 0x00, 0x30, 0x1f, 0x00, 0x00, + 0x3c, 0x1f, 0x00, 0x00, 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, + 0x45, 0x1f, 0x00, 0x00, 0x59, 0x2b, 0x00, 0xd0, 0x41, 0xe1, 0xc9, 0x4b, + 0xc9, 0x4a, 0x9b, 0x6f, 0x14, 0x68, 0x00, 0x2b, 0x05, 0xd1, 0x94, 0x61, + 0xc5, 0x4b, 0x03, 0x22, 0x5b, 0x68, 0xc6, 0x49, 0x43, 0xe7, 0x9b, 0x08, + 0xfb, 0x60, 0x93, 0x69, 0xbb, 0x60, 0x80, 0x23, 0xdb, 0x02, 0x9c, 0x42, + 0x00, 0xd0, 0xc6, 0xe0, 0xff, 0xf7, 0x3a, 0xfb, 0x05, 0x1e, 0x0a, 0xd0, + 0xbc, 0x4b, 0x03, 0x22, 0x5b, 0x68, 0xbe, 0x49, 0xd8, 0x68, 0xff, 0xf7, + 0x3b, 0xf9, 0xbd, 0x46, 0xbc, 0x4b, 0x9d, 0x44, 0xf0, 0xbd, 0x10, 0x23, + 0xfe, 0x18, 0x32, 0x00, 0x90, 0x21, 0xba, 0x48, 0xff, 0xf7, 0x2e, 0xfd, + 0x08, 0x23, 0x3e, 0x60, 0xbc, 0x68, 0xb8, 0x4e, 0x7b, 0x60, 0x22, 0x00, + 0x23, 0x00, 0x2d, 0x32, 0x2c, 0x33, 0x12, 0x78, 0x1b, 0x78, 0x12, 0x02, + 0x1a, 0x43, 0x23, 0x00, 0x2e, 0x33, 0x1b, 0x78, 0x1b, 0x04, 0x1a, 0x43, + 0x23, 0x00, 0x2f, 0x33, 0x1b, 0x78, 0x1b, 0x06, 0x13, 0x43, 0x51, 0xd0, + 0x62, 0x78, 0x23, 0x78, 0x12, 0x02, 0x1a, 0x43, 0xa3, 0x78, 0x1b, 0x04, + 0x1a, 0x43, 0xe3, 0x78, 0x1b, 0x06, 0x13, 0x43, 0xa8, 0x4a, 0x53, 0x60, + 0x01, 0x22, 0xa2, 0x4b, 0x1a, 0x77, 0x00, 0x24, 0xbb, 0x68, 0x19, 0x19, + 0x0a, 0x00, 0x0b, 0x00, 0x29, 0x32, 0x28, 0x33, 0x12, 0x78, 0x1b, 0x78, + 0x12, 0x02, 0x1a, 0x43, 0x0b, 0x00, 0x2a, 0x33, 0x1b, 0x78, 0x1b, 0x04, + 0x1a, 0x43, 0x0b, 0x00, 0x2b, 0x33, 0x1b, 0x78, 0x1b, 0x06, 0x13, 0x43, + 0x01, 0x33, 0x05, 0xd0, 0x10, 0x23, 0xfb, 0x18, 0x18, 0x19, 0x30, 0x22, + 0x00, 0xf0, 0xad, 0xfe, 0x30, 0x34, 0x90, 0x2c, 0xe0, 0xd1, 0x10, 0x21, + 0x90, 0x22, 0x96, 0x4b, 0x79, 0x18, 0x89, 0x18, 0x10, 0x20, 0x0b, 0x60, + 0x94, 0x21, 0x02, 0x23, 0x38, 0x18, 0x41, 0x18, 0x10, 0x20, 0x0b, 0x60, + 0xff, 0x23, 0x98, 0x21, 0x38, 0x18, 0x41, 0x18, 0x5b, 0x03, 0x0b, 0x60, + 0x80, 0x18, 0x03, 0x21, 0xff, 0xf7, 0xaa, 0xfc, 0x71, 0x34, 0xff, 0x34, + 0xfb, 0x68, 0xab, 0x42, 0x40, 0xd8, 0x10, 0x23, 0x90, 0x21, 0xfa, 0x18, + 0x85, 0x48, 0xff, 0xf7, 0x9b, 0xfd, 0x71, 0xe7, 0x7a, 0x68, 0x3b, 0x68, + 0x9b, 0x18, 0x22, 0x00, 0x19, 0x6a, 0x23, 0x00, 0x29, 0x32, 0x28, 0x33, + 0x12, 0x78, 0x1b, 0x78, 0x12, 0x02, 0x1a, 0x43, 0x23, 0x00, 0x2a, 0x33, + 0x1b, 0x78, 0x1b, 0x04, 0x1a, 0x43, 0x23, 0x00, 0x2b, 0x33, 0x1b, 0x78, + 0x1b, 0x06, 0x13, 0x43, 0x99, 0x42, 0x01, 0xd0, 0x4b, 0x1c, 0x17, 0xd1, + 0x62, 0x78, 0x23, 0x78, 0x12, 0x02, 0x1a, 0x43, 0xa3, 0x78, 0x1b, 0x04, + 0x1a, 0x43, 0xe3, 0x78, 0x1b, 0x06, 0x13, 0x43, 0x72, 0x68, 0x93, 0x42, + 0x00, 0xd2, 0x73, 0x60, 0x21, 0x00, 0x7a, 0x68, 0x3b, 0x68, 0x08, 0x31, + 0x98, 0x18, 0x20, 0x22, 0x00, 0xf0, 0x48, 0xfe, 0x00, 0x28, 0x87, 0xd1, + 0x7b, 0x68, 0x30, 0x34, 0x30, 0x33, 0x7b, 0x60, 0x98, 0x2b, 0x00, 0xd0, + 0x61, 0xe7, 0x82, 0xe7, 0xff, 0x23, 0xdb, 0x02, 0xe8, 0x18, 0x68, 0x4b, + 0x80, 0x00, 0xc2, 0x18, 0xbb, 0x68, 0x21, 0x00, 0x9a, 0x18, 0xff, 0xf7, + 0x55, 0xfd, 0x80, 0x35, 0xae, 0xe7, 0x64, 0x4b, 0x9c, 0x42, 0x39, 0xd9, + 0x13, 0x7f, 0x00, 0x2b, 0x00, 0xd1, 0x23, 0xe7, 0x5d, 0x4b, 0x61, 0x4a, + 0x5b, 0x68, 0x9b, 0x18, 0x1c, 0x19, 0xa3, 0xb2, 0x00, 0x2b, 0x12, 0xd1, + 0x10, 0x21, 0x90, 0x22, 0x59, 0x4b, 0x79, 0x18, 0x89, 0x18, 0x10, 0x20, + 0x0b, 0x60, 0x94, 0x21, 0x02, 0x23, 0x38, 0x18, 0x41, 0x18, 0x0b, 0x60, + 0x96, 0x33, 0xc3, 0x18, 0x03, 0x21, 0x80, 0x18, 0x1c, 0x60, 0xff, 0xf7, + 0x35, 0xfc, 0xfb, 0x68, 0x80, 0x26, 0x7f, 0x33, 0xdb, 0x09, 0x5a, 0x02, + 0x80, 0x23, 0x20, 0x00, 0x9b, 0x00, 0xe3, 0x18, 0xd3, 0x18, 0xfb, 0x60, + 0xb6, 0x00, 0x80, 0x23, 0x9b, 0x00, 0xc5, 0x18, 0xfb, 0x68, 0x9d, 0x42, + 0x00, 0xd1, 0xf5, 0xe6, 0xbb, 0x68, 0x31, 0x00, 0x1a, 0x18, 0x12, 0x1b, + 0xff, 0xf7, 0x18, 0xfd, 0x28, 0x00, 0xf0, 0xe7, 0x80, 0x20, 0x47, 0x4b, + 0x59, 0x68, 0x81, 0x43, 0x59, 0x60, 0x51, 0x69, 0x45, 0x4a, 0x89, 0x08, + 0x94, 0x46, 0xfa, 0x68, 0x00, 0x2a, 0x00, 0xd1, 0xe0, 0xe6, 0x43, 0x4a, + 0x1a, 0x80, 0x1a, 0x7d, 0xd2, 0x07, 0xfc, 0xd5, 0x20, 0x00, 0x00, 0x22, + 0xbd, 0x68, 0x04, 0x00, 0xbd, 0x60, 0x91, 0x42, 0x02, 0xd0, 0xfe, 0x68, + 0x96, 0x42, 0x08, 0xd1, 0x60, 0x46, 0x18, 0x80, 0x18, 0x7d, 0xc0, 0x07, + 0xfc, 0xd5, 0xf8, 0x68, 0x82, 0x1a, 0xfa, 0x60, 0xe3, 0xe7, 0x10, 0xcd, + 0x01, 0x32, 0x10, 0xc0, 0xeb, 0xe7, 0x5a, 0x2b, 0x00, 0xd0, 0x81, 0xe5, + 0x26, 0x4b, 0x9d, 0x6f, 0x26, 0x4b, 0x1c, 0x68, 0x80, 0x23, 0xdb, 0x02, + 0x9c, 0x42, 0x3f, 0xd1, 0x80, 0x26, 0x00, 0x24, 0x76, 0x00, 0x0c, 0xe0, + 0x10, 0x22, 0x90, 0x23, 0xba, 0x18, 0xd3, 0x18, 0x1a, 0x19, 0xff, 0x23, + 0x5b, 0x03, 0xe0, 0x18, 0x31, 0x00, 0xff, 0xf7, 0xfd, 0xfb, 0x01, 0x34, + 0xff, 0x34, 0xa5, 0x42, 0xf0, 0xd8, 0x10, 0x22, 0x90, 0x23, 0xba, 0x18, + 0xd4, 0x18, 0x00, 0x26, 0x24, 0x4a, 0x65, 0x19, 0xac, 0x42, 0x5f, 0xd1, + 0x14, 0x4b, 0x01, 0x22, 0x5b, 0x68, 0x22, 0x49, 0xd8, 0x68, 0xfe, 0xf7, + 0xeb, 0xff, 0x0f, 0x24, 0x07, 0x23, 0x32, 0x00, 0x22, 0x40, 0xd0, 0xb2, + 0x01, 0x00, 0x36, 0x09, 0x30, 0x31, 0x09, 0x2a, 0x00, 0xdd, 0x07, 0x31, + 0x10, 0x22, 0xba, 0x18, 0xd1, 0x54, 0x01, 0x3b, 0xf1, 0xd2, 0x10, 0x21, + 0x08, 0x4b, 0x08, 0x22, 0x5b, 0x68, 0x79, 0x18, 0xd8, 0x68, 0xfe, 0xf7, + 0xd3, 0xff, 0x05, 0x4b, 0x03, 0x22, 0x5b, 0x68, 0x13, 0x49, 0xc2, 0xe5, + 0x0b, 0x4b, 0x9c, 0x42, 0xd3, 0xd9, 0x00, 0x26, 0x33, 0xe0, 0xc0, 0x46, + 0x78, 0x00, 0x00, 0x20, 0xf8, 0x00, 0x00, 0x20, 0x4d, 0x1f, 0x00, 0x00, + 0x49, 0x1f, 0x00, 0x00, 0xa4, 0x10, 0x00, 0x00, 0x00, 0xf0, 0x1f, 0x00, + 0x00, 0x00, 0x00, 0x20, 0x03, 0x00, 0x00, 0x01, 0x00, 0x20, 0xe0, 0xff, + 0xff, 0x0f, 0x04, 0x00, 0x00, 0xf0, 0xfb, 0xff, 0x00, 0x40, 0x00, 0x41, + 0x04, 0xa5, 0xff, 0xff, 0x44, 0xa5, 0xff, 0xff, 0x2c, 0x1d, 0x00, 0x00, + 0x51, 0x1f, 0x00, 0x00, 0x53, 0x1f, 0x00, 0x00, 0x10, 0x22, 0x90, 0x23, + 0x80, 0x21, 0xba, 0x18, 0xd3, 0x18, 0x9a, 0x19, 0x24, 0x4b, 0x49, 0x00, + 0x58, 0x68, 0x24, 0x4b, 0xc0, 0x18, 0x20, 0x18, 0x80, 0x19, 0xff, 0xf7, + 0x95, 0xfb, 0x01, 0x36, 0xff, 0x36, 0xae, 0x42, 0xec, 0xd3, 0x96, 0xe7, + 0x21, 0x78, 0x33, 0x0a, 0x4b, 0x40, 0x5b, 0x00, 0x31, 0x02, 0x9e, 0x5a, + 0x01, 0x34, 0x4e, 0x40, 0xb6, 0xb2, 0x93, 0xe7, 0x1a, 0x00, 0x30, 0x3a, + 0xd1, 0xb2, 0x09, 0x29, 0x07, 0xd8, 0x18, 0x4b, 0x9b, 0x6f, 0xfb, 0x60, + 0x1b, 0x01, 0x13, 0x43, 0x15, 0x4a, 0x93, 0x67, 0xf6, 0xe4, 0x1a, 0x00, + 0x41, 0x3a, 0x05, 0x2a, 0x05, 0xd8, 0x12, 0x4a, 0x37, 0x3b, 0x92, 0x6f, + 0xfa, 0x60, 0x12, 0x01, 0xf1, 0xe7, 0x1a, 0x00, 0x61, 0x3a, 0x05, 0x2a, + 0x05, 0xd8, 0x0d, 0x4a, 0x57, 0x3b, 0x92, 0x6f, 0xfa, 0x60, 0x12, 0x01, + 0xe7, 0xe7, 0x00, 0x22, 0x2c, 0x2b, 0x08, 0xd1, 0x08, 0x4b, 0x9b, 0x6f, + 0xfb, 0x60, 0xf9, 0x68, 0x07, 0x4b, 0x19, 0x60, 0x05, 0x4b, 0x9a, 0x67, + 0xd6, 0xe4, 0x04, 0x49, 0x74, 0x31, 0x0b, 0x70, 0xf8, 0xe7, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x20, 0x00, 0xf0, 0xfb, 0xff, 0x78, 0x00, 0x00, 0x20, + 0xf8, 0x00, 0x00, 0x20, 0x70, 0xb5, 0x05, 0x00, 0xc0, 0xb0, 0x08, 0x00, + 0x16, 0x00, 0x0c, 0x00, 0x00, 0xf0, 0x10, 0xfd, 0x6b, 0x46, 0x40, 0x00, + 0x02, 0x30, 0x18, 0x70, 0x6a, 0x46, 0x03, 0x23, 0x76, 0x08, 0x53, 0x70, + 0x02, 0x3b, 0x5a, 0x1e, 0xa1, 0x5c, 0x5a, 0x00, 0x00, 0x29, 0x01, 0xd0, + 0x9e, 0x42, 0x06, 0xdc, 0x00, 0x23, 0x69, 0x46, 0x28, 0x00, 0xff, 0xf7, + 0xa7, 0xfb, 0x40, 0xb0, 0x70, 0xbd, 0x68, 0x46, 0x01, 0x33, 0x81, 0x52, + 0xed, 0xe7, 0xf7, 0xb5, 0x05, 0x68, 0x08, 0x22, 0x29, 0x00, 0xab, 0x8b, + 0x06, 0x00, 0x13, 0x40, 0xff, 0x31, 0x00, 0x2b, 0x27, 0xd0, 0x80, 0x23, + 0x40, 0x20, 0xc0, 0x24, 0xaa, 0x83, 0x09, 0x32, 0xab, 0x72, 0x4a, 0x70, + 0x88, 0x71, 0x4b, 0x71, 0xb3, 0x4b, 0xb4, 0x4d, 0x5a, 0x68, 0xa4, 0x05, + 0x2a, 0x40, 0x22, 0x43, 0x5a, 0x60, 0x5a, 0x69, 0x2a, 0x40, 0x14, 0x43, + 0xb0, 0x4a, 0x5c, 0x61, 0x1a, 0x60, 0xb0, 0x4a, 0xb0, 0x4c, 0x1a, 0x61, + 0x5a, 0x68, 0x14, 0x40, 0x80, 0x22, 0x92, 0x02, 0x22, 0x43, 0x5a, 0x60, + 0x5a, 0x68, 0x92, 0x0b, 0x92, 0x03, 0x5a, 0x60, 0x00, 0x23, 0x48, 0x71, + 0x33, 0x71, 0x30, 0x79, 0xfe, 0xbd, 0x10, 0x20, 0x0a, 0x7a, 0x02, 0x42, + 0xf9, 0xd0, 0xa4, 0x4a, 0xa6, 0x4c, 0x17, 0x78, 0x08, 0x72, 0x67, 0x77, + 0x57, 0x78, 0xa7, 0x77, 0x97, 0x78, 0x27, 0x84, 0x27, 0x8c, 0xbc, 0x46, + 0x60, 0x46, 0xd7, 0x78, 0x3f, 0x02, 0x07, 0x43, 0x27, 0x84, 0x17, 0x79, + 0x67, 0x84, 0x57, 0x79, 0x60, 0x8c, 0x3f, 0x02, 0x07, 0x43, 0x67, 0x84, + 0x97, 0x79, 0xa7, 0x84, 0xd2, 0x79, 0xa7, 0x8c, 0x12, 0x02, 0x3a, 0x43, + 0x40, 0x27, 0xa2, 0x84, 0x4f, 0x71, 0xa2, 0x7f, 0x60, 0x7f, 0x12, 0x02, + 0x02, 0x43, 0x96, 0x48, 0x82, 0x42, 0x00, 0xd1, 0xf2, 0xe0, 0x26, 0xdc, + 0x80, 0x20, 0x40, 0x00, 0x82, 0x42, 0x1c, 0xd0, 0x0b, 0xdc, 0x81, 0x2a, + 0x04, 0xd0, 0x82, 0x2a, 0x00, 0xd1, 0xbe, 0xe0, 0x80, 0x2a, 0x14, 0xd1, + 0x21, 0x00, 0xe3, 0x84, 0x26, 0x31, 0x02, 0x22, 0x4e, 0xe0, 0x81, 0x23, + 0x5b, 0x00, 0x9a, 0x42, 0x00, 0xd1, 0x27, 0xe1, 0x00, 0xda, 0xf8, 0xe0, + 0xff, 0x33, 0xff, 0x33, 0x9a, 0x42, 0x00, 0xd1, 0xcf, 0xe0, 0x86, 0x4b, + 0x9a, 0x42, 0x00, 0xd1, 0xef, 0xe0, 0x20, 0x23, 0xff, 0x35, 0xaa, 0x79, + 0x13, 0x43, 0xab, 0x71, 0xa9, 0xe7, 0x90, 0x21, 0x09, 0x01, 0x8a, 0x42, + 0x6c, 0xd0, 0x17, 0xdc, 0xd0, 0x21, 0xc9, 0x00, 0x8a, 0x42, 0x22, 0xd0, + 0x88, 0x21, 0x09, 0x01, 0x8a, 0x42, 0x00, 0xd1, 0x90, 0xe0, 0xa0, 0x23, + 0xdb, 0x00, 0x9a, 0x42, 0xe7, 0xd1, 0x28, 0x00, 0xfe, 0xf7, 0x1a, 0xff, + 0x80, 0x23, 0x22, 0x8c, 0x5b, 0x42, 0x13, 0x43, 0x32, 0x68, 0xdb, 0xb2, + 0x93, 0x72, 0x8c, 0xe7, 0x73, 0x4b, 0x9a, 0x42, 0x00, 0xd1, 0xc8, 0xe0, + 0xd7, 0xdd, 0x72, 0x4b, 0x9a, 0x42, 0x00, 0xd1, 0x4d, 0xe1, 0x71, 0x4b, + 0x9a, 0x42, 0xd0, 0xd1, 0x23, 0x8c, 0x73, 0x71, 0xbd, 0xe0, 0x23, 0x8c, + 0x1b, 0x0a, 0x01, 0x2b, 0x0c, 0xd1, 0x12, 0x22, 0xa3, 0x8c, 0x93, 0x42, + 0x01, 0xd8, 0xa2, 0x8c, 0x92, 0xb2, 0x00, 0x23, 0x69, 0x49, 0x14, 0x31, + 0x28, 0x00, 0xff, 0xf7, 0xdf, 0xfa, 0x6c, 0xe7, 0x23, 0x8c, 0x1b, 0x0a, + 0x02, 0x2b, 0x09, 0xd1, 0x43, 0x22, 0xa3, 0x8c, 0x93, 0x42, 0x01, 0xd8, + 0xa2, 0x8c, 0x92, 0xb2, 0x62, 0x49, 0x00, 0x23, 0x08, 0x31, 0xed, 0xe7, + 0x23, 0x8c, 0x1b, 0x0a, 0x03, 0x2b, 0xaa, 0xd1, 0x23, 0x8c, 0xdb, 0xb2, + 0x01, 0x2b, 0x16, 0xd0, 0x00, 0x2b, 0x05, 0xd0, 0x02, 0x2b, 0xa2, 0xd1, + 0xa2, 0x8c, 0x5b, 0x49, 0xd2, 0xb2, 0x11, 0xe0, 0x57, 0x49, 0x04, 0x22, + 0x26, 0x31, 0x01, 0xa8, 0x00, 0xf0, 0x05, 0xfc, 0x04, 0x22, 0xa3, 0x8c, + 0x93, 0x42, 0x01, 0xd8, 0xa2, 0x8c, 0x92, 0xb2, 0x00, 0x23, 0x01, 0xa9, + 0xce, 0xe7, 0xa2, 0x8c, 0x52, 0x49, 0xd2, 0xb2, 0x28, 0x00, 0xff, 0xf7, + 0xe7, 0xfe, 0x38, 0xe7, 0x23, 0x8c, 0x28, 0x00, 0x33, 0x71, 0xfe, 0xf7, + 0xb9, 0xfe, 0xa0, 0x23, 0x03, 0x22, 0xc0, 0x21, 0x5b, 0x00, 0xea, 0x54, + 0x3c, 0x4b, 0x3d, 0x48, 0x5a, 0x6c, 0x89, 0x05, 0x02, 0x40, 0x0a, 0x43, + 0x5a, 0x64, 0x46, 0x22, 0xff, 0x32, 0xaf, 0x54, 0x46, 0x4a, 0x30, 0x24, + 0x1a, 0x64, 0x90, 0x22, 0x52, 0x00, 0xac, 0x54, 0x5a, 0x6b, 0x02, 0x40, + 0x11, 0x43, 0x92, 0x22, 0x59, 0x63, 0x80, 0x21, 0x52, 0x00, 0xa9, 0x54, + 0x40, 0x4a, 0x1a, 0x63, 0xb0, 0x22, 0x52, 0x00, 0xaf, 0x54, 0x5a, 0x6f, + 0x10, 0x40, 0x58, 0x67, 0xb2, 0x23, 0x5b, 0x00, 0xe9, 0x54, 0x0a, 0xe7, + 0x31, 0x1d, 0x01, 0x22, 0x96, 0xe7, 0x50, 0x22, 0xe3, 0x84, 0x63, 0x8c, + 0x0f, 0x20, 0x13, 0x40, 0x22, 0x00, 0x28, 0x32, 0x13, 0x70, 0x63, 0x8c, + 0x03, 0x40, 0x63, 0x84, 0x63, 0x8c, 0x03, 0x2b, 0x15, 0xd8, 0x13, 0x78, + 0x00, 0x2b, 0x0b, 0xd0, 0x63, 0x8c, 0x08, 0x33, 0x5b, 0x01, 0xeb, 0x18, + 0x9b, 0x79, 0x9b, 0x06, 0x21, 0x00, 0xdb, 0x0f, 0xe3, 0x84, 0x26, 0x31, + 0x00, 0x23, 0x28, 0xe7, 0x63, 0x8c, 0x08, 0x33, 0x5b, 0x01, 0xeb, 0x18, + 0x9b, 0x79, 0xdb, 0x06, 0xf2, 0xe7, 0x20, 0x23, 0x8a, 0x79, 0x13, 0x43, + 0x8b, 0x71, 0xde, 0xe6, 0x80, 0x22, 0x63, 0x8c, 0x0f, 0x21, 0x13, 0x40, + 0x22, 0x00, 0x28, 0x32, 0x13, 0x70, 0x63, 0x8c, 0x0b, 0x40, 0x63, 0x84, + 0x23, 0x8c, 0x00, 0x2b, 0x00, 0xd0, 0x20, 0xe7, 0x63, 0x8c, 0x00, 0x2b, + 0x00, 0xd1, 0x1c, 0xe7, 0x63, 0x8c, 0x03, 0x2b, 0x00, 0xd9, 0x18, 0xe7, + 0x13, 0x78, 0x00, 0x2b, 0x09, 0xd0, 0x20, 0x22, 0x63, 0x8c, 0x08, 0x33, + 0x5b, 0x01, 0xeb, 0x18, 0x5a, 0x71, 0x28, 0x00, 0xfe, 0xf7, 0x42, 0xfe, + 0xbb, 0xe6, 0x63, 0x8c, 0x10, 0x22, 0x08, 0x33, 0x5b, 0x01, 0xeb, 0x18, + 0xf4, 0xe7, 0xc0, 0x46, 0x2c, 0x02, 0x00, 0x20, 0xff, 0xff, 0xff, 0x8f, + 0xac, 0x01, 0x00, 0x20, 0x2c, 0x01, 0x00, 0x20, 0xff, 0x3f, 0x00, 0xf0, + 0xf8, 0x00, 0x00, 0x20, 0x02, 0x03, 0x00, 0x00, 0x01, 0x03, 0x00, 0x00, + 0x21, 0x20, 0x00, 0x00, 0xa1, 0x21, 0x00, 0x00, 0x21, 0x22, 0x00, 0x00, + 0x44, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x65, 0x1f, 0x00, 0x00, + 0x59, 0x1f, 0x00, 0x00, 0xec, 0x01, 0x00, 0x20, 0x6c, 0x01, 0x00, 0x20, + 0x80, 0x22, 0x63, 0x8c, 0x13, 0x40, 0x22, 0x00, 0x28, 0x32, 0x13, 0x70, + 0x0f, 0x22, 0x63, 0x8c, 0x13, 0x40, 0x63, 0x84, 0x23, 0x8c, 0x00, 0x2b, + 0x00, 0xd0, 0xd4, 0xe6, 0x63, 0x8c, 0x00, 0x2b, 0x00, 0xd1, 0xd0, 0xe6, + 0x63, 0x8c, 0x03, 0x2b, 0x00, 0xd9, 0xcc, 0xe6, 0x23, 0x00, 0x28, 0x33, + 0x1b, 0x78, 0x00, 0x2b, 0x20, 0xd0, 0x63, 0x8c, 0x08, 0x33, 0x5b, 0x01, + 0xeb, 0x18, 0x9b, 0x79, 0x9b, 0x06, 0xb0, 0xd5, 0x63, 0x8c, 0x11, 0x32, + 0x08, 0x33, 0x5b, 0x01, 0xeb, 0x18, 0x1a, 0x71, 0x63, 0x8c, 0x08, 0x33, + 0x5b, 0x01, 0xeb, 0x18, 0xdb, 0x79, 0x5b, 0x06, 0xa3, 0xd5, 0x63, 0x8c, + 0x20, 0x32, 0x08, 0x33, 0x5b, 0x01, 0xeb, 0x18, 0xda, 0x71, 0x63, 0x8c, + 0x3e, 0x3a, 0x08, 0x33, 0x5b, 0x01, 0xeb, 0x18, 0x1a, 0x71, 0x96, 0xe7, + 0x63, 0x8c, 0x08, 0x33, 0x5b, 0x01, 0xeb, 0x18, 0x9b, 0x79, 0xdb, 0x06, + 0x8f, 0xd5, 0x10, 0x22, 0x63, 0x8c, 0x08, 0x33, 0x5b, 0x01, 0xeb, 0x18, + 0x1a, 0x71, 0x63, 0x8c, 0x08, 0x33, 0x5b, 0x01, 0xeb, 0x18, 0xdb, 0x79, + 0x9b, 0x06, 0x00, 0xd4, 0x81, 0xe7, 0x63, 0x8c, 0x92, 0x18, 0x08, 0x33, + 0x5b, 0x01, 0xeb, 0x18, 0xda, 0x71, 0x63, 0x8c, 0x1f, 0x3a, 0x08, 0x33, + 0x5b, 0x01, 0xeb, 0x18, 0xdc, 0xe7, 0x08, 0x22, 0xa3, 0x8c, 0x93, 0x42, + 0x01, 0xd8, 0xa2, 0x8c, 0x92, 0xb2, 0x02, 0x49, 0x00, 0x23, 0x4c, 0x31, + 0xba, 0xe6, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, 0xf8, 0xb5, 0x0b, 0x4f, + 0x06, 0x00, 0x38, 0x00, 0x1c, 0x30, 0x0d, 0x00, 0xff, 0xf7, 0xf1, 0xfd, + 0x2c, 0x00, 0x00, 0x28, 0x08, 0xd1, 0x05, 0x00, 0x08, 0xe0, 0x22, 0x00, + 0x31, 0x00, 0xf8, 0x69, 0xff, 0xf7, 0x3c, 0xf9, 0x24, 0x1a, 0x36, 0x18, + 0x00, 0x2c, 0xf6, 0xd1, 0x28, 0x00, 0xf8, 0xbd, 0x78, 0x00, 0x00, 0x20, + 0x70, 0xb5, 0x08, 0x4c, 0x05, 0x00, 0x20, 0x00, 0x1c, 0x30, 0x0e, 0x00, + 0xff, 0xf7, 0xd7, 0xfd, 0x03, 0x00, 0x00, 0x20, 0x83, 0x42, 0x04, 0xd0, + 0x32, 0x00, 0x29, 0x00, 0xe0, 0x69, 0xff, 0xf7, 0x23, 0xf9, 0x70, 0xbd, + 0x78, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x08, 0x4c, 0x20, 0x00, 0x1c, 0x30, + 0xff, 0xf7, 0xc5, 0xfd, 0x03, 0x00, 0x00, 0x20, 0x83, 0x42, 0x05, 0xd0, + 0x48, 0x23, 0xe2, 0x69, 0xff, 0x33, 0xd0, 0x5c, 0xc0, 0x07, 0xc0, 0x0f, + 0x10, 0xbd, 0xc0, 0x46, 0x78, 0x00, 0x00, 0x20, 0x0d, 0x4a, 0x0e, 0x48, + 0x70, 0xb5, 0x82, 0x42, 0x06, 0xd1, 0x0d, 0x4a, 0x0d, 0x4b, 0x00, 0x21, + 0x93, 0x42, 0x0d, 0xd1, 0x00, 0xf0, 0x1a, 0xf8, 0x0b, 0x4c, 0x00, 0x23, + 0x94, 0x42, 0xf4, 0xd0, 0xd1, 0x18, 0x88, 0x42, 0xf1, 0xd9, 0xe5, 0x58, + 0x04, 0x33, 0x0d, 0x60, 0xf8, 0xe7, 0x02, 0xc3, 0x93, 0x42, 0xfc, 0xd3, + 0xee, 0xe7, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, 0x5c, 0x00, 0x00, 0x20, + 0xac, 0x02, 0x00, 0x20, 0x5c, 0x00, 0x00, 0x20, 0x80, 0x1f, 0x00, 0x00, + 0xf0, 0xb5, 0x0b, 0x49, 0x8b, 0xb0, 0x0b, 0x68, 0x00, 0xaf, 0x01, 0x33, + 0x20, 0xd0, 0x09, 0x48, 0x09, 0x4b, 0xc9, 0xb2, 0xc3, 0x62, 0x00, 0x29, + 0x1a, 0xd1, 0x08, 0x4b, 0x08, 0x4a, 0x1b, 0x78, 0xdb, 0x07, 0xdb, 0x0f, + 0x0e, 0xd0, 0x11, 0x60, 0x01, 0x23, 0x30, 0x30, 0x03, 0x70, 0x0f, 0xe0, + 0x00, 0x20, 0x00, 0x00, 0xf8, 0x00, 0x00, 0x20, 0x04, 0x20, 0x00, 0x00, + 0x38, 0x04, 0x00, 0x40, 0xfc, 0x7f, 0x00, 0x20, 0x14, 0x68, 0xda, 0x49, + 0x8c, 0x42, 0x00, 0xd0, 0x28, 0xe2, 0x13, 0x60, 0x1e, 0x22, 0xd8, 0x49, + 0x4b, 0x68, 0x93, 0x43, 0x1c, 0x3a, 0x13, 0x43, 0x4b, 0x60, 0x08, 0x23, + 0xd5, 0x49, 0x88, 0x69, 0x03, 0x43, 0x8b, 0x61, 0xd4, 0x48, 0xd5, 0x4b, + 0x98, 0x82, 0x98, 0x8a, 0x10, 0x43, 0x98, 0x82, 0xd8, 0x68, 0x10, 0x42, + 0xfc, 0xd0, 0x01, 0x22, 0xd1, 0x48, 0x02, 0x70, 0x04, 0x78, 0x14, 0x42, + 0x03, 0xd0, 0x44, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xf8, 0xdb, 0x01, 0x22, + 0x82, 0x60, 0x42, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, 0xcb, 0x4a, + 0x42, 0x60, 0x42, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, 0x82, 0x22, + 0xd2, 0x01, 0x42, 0x80, 0x42, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, + 0x80, 0x24, 0x9a, 0x8c, 0xa2, 0x43, 0x9a, 0x84, 0x10, 0x22, 0xdc, 0x68, + 0x14, 0x42, 0xfc, 0xd0, 0xc1, 0x4a, 0xda, 0x62, 0x10, 0x22, 0xdc, 0x68, + 0x14, 0x42, 0xfc, 0xd0, 0x9c, 0x8c, 0xbf, 0x4a, 0x22, 0x43, 0x9a, 0x84, + 0x10, 0x22, 0xdc, 0x68, 0x14, 0x42, 0xfc, 0xd0, 0x02, 0x22, 0x9c, 0x8c, + 0x80, 0x25, 0x22, 0x43, 0x9a, 0x84, 0x40, 0x22, 0xdc, 0x68, 0x2c, 0x42, + 0xfc, 0xd0, 0xdc, 0x68, 0x14, 0x42, 0xf9, 0xd0, 0x10, 0x22, 0xdc, 0x68, + 0x14, 0x42, 0xfc, 0xd0, 0x00, 0x23, 0x83, 0x60, 0x43, 0x78, 0x5b, 0xb2, + 0x00, 0x2b, 0xfb, 0xdb, 0xb1, 0x4b, 0x43, 0x60, 0x7b, 0x60, 0x43, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x00, 0x23, 0x0b, 0x72, 0x4b, 0x72, + 0x8b, 0x72, 0xcb, 0x72, 0x62, 0xb6, 0xac, 0x4b, 0x43, 0x80, 0x43, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x04, 0x23, 0x0a, 0x6a, 0xa9, 0x4c, + 0x13, 0x43, 0x0b, 0x62, 0x01, 0x23, 0x22, 0x68, 0x13, 0x43, 0x23, 0x60, + 0x23, 0x68, 0xdb, 0x07, 0xfc, 0xd4, 0xe3, 0x69, 0xdb, 0x07, 0xf9, 0xd4, + 0x14, 0x23, 0xff, 0x22, 0x23, 0x60, 0xe3, 0x68, 0x93, 0x43, 0x1a, 0x00, + 0xef, 0x23, 0x13, 0x43, 0xe3, 0x60, 0x02, 0x23, 0x22, 0x68, 0x13, 0x43, + 0x23, 0x60, 0xe3, 0x69, 0x9b, 0x07, 0xfc, 0xd4, 0x30, 0x22, 0x63, 0x8b, + 0x93, 0x43, 0x1a, 0x00, 0x10, 0x23, 0x13, 0x43, 0x63, 0x83, 0xe5, 0x69, + 0x6d, 0x07, 0xed, 0x0f, 0xfb, 0xd1, 0x01, 0x26, 0x0f, 0x20, 0x02, 0x21, + 0x94, 0x4a, 0x13, 0x78, 0x33, 0x43, 0x13, 0x70, 0x93, 0x4b, 0x1a, 0x78, + 0x82, 0x43, 0x1a, 0x70, 0x1a, 0x78, 0x0a, 0x43, 0x1a, 0x70, 0x91, 0x4a, + 0x11, 0x78, 0x31, 0x43, 0x11, 0x70, 0x1a, 0x78, 0x02, 0x40, 0x1a, 0x70, + 0x20, 0x22, 0x19, 0x78, 0x0a, 0x38, 0x0a, 0x43, 0x1a, 0x70, 0xfe, 0xf7, + 0x2d, 0xff, 0x00, 0x28, 0x3b, 0xd0, 0xce, 0x21, 0x01, 0x40, 0x05, 0x20, + 0xfe, 0xf7, 0x18, 0xff, 0x30, 0x00, 0xfe, 0xf7, 0x23, 0xff, 0x30, 0x23, + 0x98, 0x43, 0xc1, 0xb2, 0x30, 0x00, 0xfe, 0xf7, 0x0f, 0xff, 0x28, 0x00, + 0xfe, 0xf7, 0x1a, 0xff, 0x78, 0x23, 0x01, 0x00, 0x99, 0x43, 0x48, 0x3b, + 0x19, 0x43, 0xc9, 0xb2, 0x28, 0x00, 0xfe, 0xf7, 0x03, 0xff, 0x28, 0x00, + 0xfe, 0xf7, 0x0e, 0xff, 0x07, 0x21, 0x01, 0x43, 0xc9, 0xb2, 0x28, 0x00, + 0xfe, 0xf7, 0xfa, 0xfe, 0x02, 0x20, 0xfe, 0xf7, 0x05, 0xff, 0x01, 0x00, + 0x02, 0x20, 0x31, 0x40, 0xfe, 0xf7, 0xf2, 0xfe, 0x04, 0x20, 0xfe, 0xf7, + 0xfd, 0xfe, 0x03, 0x21, 0x01, 0x40, 0x98, 0x20, 0x01, 0x43, 0x94, 0x38, + 0xfe, 0xf7, 0xe8, 0xfe, 0x02, 0x22, 0x23, 0x68, 0x93, 0x43, 0x23, 0x60, + 0xe3, 0x69, 0x9b, 0x07, 0xfc, 0xd4, 0x0f, 0x22, 0x6b, 0x49, 0x01, 0x25, + 0x0b, 0x78, 0x60, 0x4c, 0x1a, 0x40, 0x70, 0x23, 0x13, 0x43, 0x69, 0x4a, + 0x0b, 0x70, 0x13, 0x78, 0x2b, 0x43, 0x13, 0x70, 0x80, 0x23, 0x5b, 0x00, + 0xa3, 0x60, 0x80, 0x23, 0x7a, 0x68, 0x1b, 0x03, 0x13, 0x43, 0x63, 0x60, + 0xfe, 0xf7, 0x7e, 0xfd, 0x08, 0x23, 0x29, 0x00, 0xf8, 0x18, 0xbd, 0x60, + 0xfe, 0xf7, 0x5a, 0xff, 0x00, 0x0e, 0xb0, 0x28, 0x04, 0xd0, 0x28, 0x00, + 0xfe, 0xf7, 0xfc, 0xfc, 0xfe, 0xf7, 0x50, 0xfc, 0x5b, 0x4d, 0x2b, 0x00, + 0x30, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x0a, 0xd0, 0x59, 0x4b, 0x1a, 0x68, + 0x82, 0xf3, 0x08, 0x88, 0xff, 0x22, 0x93, 0x43, 0x57, 0x4a, 0x93, 0x60, + 0xeb, 0x6a, 0x1b, 0x68, 0x18, 0x47, 0x20, 0x23, 0x43, 0x4a, 0x0f, 0x20, + 0xd1, 0x69, 0x0b, 0x43, 0xd3, 0x61, 0x01, 0x23, 0x52, 0x49, 0x0a, 0x78, + 0x1a, 0x43, 0x0a, 0x70, 0x51, 0x4a, 0x11, 0x78, 0x81, 0x43, 0x11, 0x70, + 0x06, 0x21, 0x16, 0x78, 0x31, 0x43, 0x11, 0x70, 0x4e, 0x49, 0x0e, 0x78, + 0x33, 0x43, 0x0b, 0x70, 0x13, 0x78, 0x03, 0x40, 0x13, 0x70, 0x60, 0x23, + 0x11, 0x78, 0x0b, 0x43, 0x13, 0x70, 0x4a, 0x4b, 0x63, 0x80, 0x63, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x01, 0x23, 0x47, 0x4e, 0x32, 0x78, + 0x13, 0x43, 0x33, 0x70, 0xb3, 0x78, 0xdb, 0x07, 0xfc, 0xd4, 0x1f, 0x21, + 0x44, 0x4a, 0x13, 0x68, 0x5b, 0x0b, 0x0b, 0x40, 0x8b, 0x42, 0x00, 0xd1, + 0x05, 0x23, 0x30, 0x8d, 0x41, 0x4c, 0x0b, 0x40, 0x9b, 0x01, 0x20, 0x40, + 0x03, 0x43, 0x33, 0x85, 0x13, 0x68, 0x9b, 0x0c, 0x0b, 0x40, 0x1f, 0x2b, + 0x00, 0xd1, 0x02, 0x3b, 0x1f, 0x20, 0x31, 0x8d, 0x03, 0x40, 0x81, 0x43, + 0x0b, 0x43, 0x33, 0x85, 0x13, 0x68, 0x07, 0x22, 0xdb, 0x0d, 0x13, 0x40, + 0x7a, 0x60, 0x93, 0x42, 0x00, 0xd1, 0x03, 0x23, 0x07, 0x21, 0x32, 0x8d, + 0x0b, 0x40, 0x34, 0x49, 0x1b, 0x03, 0x0a, 0x40, 0x13, 0x43, 0x7f, 0x22, + 0x33, 0x85, 0x33, 0x78, 0x31, 0x48, 0x13, 0x40, 0x33, 0x70, 0x04, 0x23, + 0x32, 0x78, 0x00, 0x21, 0x13, 0x43, 0x0c, 0x22, 0x33, 0x70, 0x70, 0x62, + 0x33, 0x89, 0x93, 0x43, 0x33, 0x81, 0x33, 0x89, 0x0b, 0x3a, 0x93, 0x43, + 0x33, 0x81, 0x7f, 0x32, 0x00, 0xf0, 0xa6, 0xf8, 0x00, 0x21, 0x28, 0x4c, + 0x28, 0x4b, 0xe6, 0x61, 0x63, 0x62, 0x02, 0x23, 0x21, 0x84, 0x32, 0x78, + 0x1a, 0x48, 0x13, 0x43, 0x80, 0x22, 0x33, 0x70, 0xc0, 0x26, 0x24, 0x4b, + 0x52, 0x00, 0x1a, 0x60, 0x23, 0x4a, 0x24, 0x4b, 0x36, 0x06, 0x53, 0x60, + 0x03, 0x6a, 0x1b, 0x02, 0x1b, 0x0a, 0x43, 0xe0, 0x35, 0x81, 0x73, 0x07, + 0x00, 0x40, 0x00, 0x41, 0x00, 0x04, 0x00, 0x40, 0x0c, 0x06, 0x00, 0x00, + 0x00, 0x08, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, 0x01, 0x05, 0x01, 0x00, + 0xb8, 0x05, 0xff, 0x7d, 0x04, 0x0a, 0x00, 0x00, 0x00, 0x07, 0x03, 0x00, + 0x14, 0x40, 0x00, 0x00, 0x00, 0x08, 0x00, 0x42, 0x48, 0x44, 0x00, 0x41, + 0x34, 0x44, 0x00, 0x41, 0x49, 0x44, 0x00, 0x41, 0x3d, 0x44, 0x00, 0x41, + 0x5b, 0x44, 0x00, 0x41, 0xf8, 0x00, 0x00, 0x20, 0x00, 0x20, 0x00, 0x00, + 0x00, 0xed, 0x00, 0xe0, 0x58, 0x44, 0x00, 0x41, 0x3c, 0x44, 0x00, 0x41, + 0x59, 0x44, 0x00, 0x41, 0x06, 0x40, 0x00, 0x00, 0x00, 0x50, 0x00, 0x41, + 0x24, 0x60, 0x80, 0x00, 0x3f, 0xf8, 0xff, 0xff, 0xff, 0x8f, 0xff, 0xff, + 0x2c, 0x02, 0x00, 0x20, 0x78, 0x00, 0x00, 0x20, 0x33, 0x12, 0x00, 0x00, + 0x88, 0x44, 0x00, 0x41, 0x10, 0xe0, 0x00, 0xe0, 0xe7, 0x03, 0x00, 0x00, + 0x33, 0x43, 0x03, 0x62, 0x07, 0x23, 0x01, 0x26, 0x91, 0x60, 0x13, 0x60, + 0x20, 0x00, 0x63, 0x6a, 0x1c, 0x30, 0x98, 0x47, 0x00, 0x28, 0x01, 0xd0, + 0x19, 0x4b, 0x1e, 0x70, 0x18, 0x4b, 0x1b, 0x78, 0x00, 0x2b, 0xf3, 0xd0, + 0x17, 0x4b, 0x1a, 0x00, 0x2c, 0x32, 0x62, 0x60, 0x08, 0x22, 0x48, 0x33, + 0xba, 0x18, 0x43, 0xcb, 0x43, 0xc2, 0x43, 0xcb, 0x43, 0xc2, 0x03, 0xcb, + 0x03, 0xc2, 0x08, 0x21, 0x11, 0x4a, 0x79, 0x18, 0x93, 0x68, 0x74, 0x34, + 0x5b, 0x03, 0x5b, 0x0f, 0x9b, 0x00, 0xcb, 0x58, 0x6b, 0x61, 0x92, 0x68, + 0x92, 0xb2, 0x53, 0x43, 0x2b, 0x61, 0x00, 0x23, 0x2b, 0x60, 0x7a, 0x33, + 0x23, 0x70, 0xfe, 0xf7, 0x5d, 0xff, 0xfc, 0xe7, 0x08, 0x4b, 0x01, 0x3b, + 0x00, 0x2b, 0xfc, 0xd1, 0x07, 0x4b, 0x11, 0x60, 0x01, 0x3b, 0x00, 0x2b, + 0xfc, 0xd1, 0x13, 0x60, 0xb8, 0xe5, 0xc0, 0x46, 0x29, 0x01, 0x00, 0x20, + 0x44, 0x1c, 0x00, 0x00, 0x00, 0x40, 0x00, 0x41, 0xc4, 0x09, 0x00, 0x00, + 0x48, 0xe8, 0x01, 0x00, 0x03, 0x00, 0x12, 0x18, 0x93, 0x42, 0x00, 0xd1, + 0x70, 0x47, 0x19, 0x70, 0x01, 0x33, 0xf9, 0xe7, 0x30, 0xb5, 0x00, 0x24, + 0xa2, 0x42, 0x01, 0xd1, 0x00, 0x20, 0x05, 0xe0, 0x03, 0x5d, 0x65, 0x1c, + 0x0c, 0x5d, 0xa3, 0x42, 0x01, 0xd0, 0x18, 0x1b, 0x30, 0xbd, 0x2c, 0x00, + 0xf2, 0xe7, 0x00, 0x23, 0x10, 0xb5, 0x9a, 0x42, 0x00, 0xd1, 0x10, 0xbd, + 0xcc, 0x5c, 0xc4, 0x54, 0x01, 0x33, 0xf8, 0xe7, 0x00, 0x23, 0xc2, 0x5c, + 0x01, 0x33, 0x00, 0x2a, 0xfb, 0xd1, 0x58, 0x1e, 0x70, 0x47, 0x00, 0x00, + 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, + 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, + 0x32, 0x2e, 0x30, 0x00, 0x5b, 0x41, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, + 0x3a, 0x58, 0x59, 0x5a, 0x5d, 0x00, 0x00, 0x00, 0x12, 0x01, 0x00, 0x02, + 0x02, 0x00, 0x00, 0x40, 0x41, 0x23, 0x56, 0x00, 0x00, 0x02, 0x01, 0x02, + 0x00, 0x01, 0x04, 0x03, 0x09, 0x04, 0x00, 0x00, 0x15, 0x0a, 0x00, 0x00, + 0x59, 0x09, 0x00, 0x00, 0x9d, 0x16, 0x00, 0x00, 0xf9, 0x09, 0x00, 0x00, + 0x75, 0x16, 0x00, 0x00, 0xf9, 0x09, 0x00, 0x00, 0x41, 0x16, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, + 0x40, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x05, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x07, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x0b, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, + 0x0f, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x0b, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x21, 0x10, 0x42, 0x20, 0x63, 0x30, + 0x84, 0x40, 0xa5, 0x50, 0xc6, 0x60, 0xe7, 0x70, 0x08, 0x81, 0x29, 0x91, + 0x4a, 0xa1, 0x6b, 0xb1, 0x8c, 0xc1, 0xad, 0xd1, 0xce, 0xe1, 0xef, 0xf1, + 0x31, 0x12, 0x10, 0x02, 0x73, 0x32, 0x52, 0x22, 0xb5, 0x52, 0x94, 0x42, + 0xf7, 0x72, 0xd6, 0x62, 0x39, 0x93, 0x18, 0x83, 0x7b, 0xb3, 0x5a, 0xa3, + 0xbd, 0xd3, 0x9c, 0xc3, 0xff, 0xf3, 0xde, 0xe3, 0x62, 0x24, 0x43, 0x34, + 0x20, 0x04, 0x01, 0x14, 0xe6, 0x64, 0xc7, 0x74, 0xa4, 0x44, 0x85, 0x54, + 0x6a, 0xa5, 0x4b, 0xb5, 0x28, 0x85, 0x09, 0x95, 0xee, 0xe5, 0xcf, 0xf5, + 0xac, 0xc5, 0x8d, 0xd5, 0x53, 0x36, 0x72, 0x26, 0x11, 0x16, 0x30, 0x06, + 0xd7, 0x76, 0xf6, 0x66, 0x95, 0x56, 0xb4, 0x46, 0x5b, 0xb7, 0x7a, 0xa7, + 0x19, 0x97, 0x38, 0x87, 0xdf, 0xf7, 0xfe, 0xe7, 0x9d, 0xd7, 0xbc, 0xc7, + 0xc4, 0x48, 0xe5, 0x58, 0x86, 0x68, 0xa7, 0x78, 0x40, 0x08, 0x61, 0x18, + 0x02, 0x28, 0x23, 0x38, 0xcc, 0xc9, 0xed, 0xd9, 0x8e, 0xe9, 0xaf, 0xf9, + 0x48, 0x89, 0x69, 0x99, 0x0a, 0xa9, 0x2b, 0xb9, 0xf5, 0x5a, 0xd4, 0x4a, + 0xb7, 0x7a, 0x96, 0x6a, 0x71, 0x1a, 0x50, 0x0a, 0x33, 0x3a, 0x12, 0x2a, + 0xfd, 0xdb, 0xdc, 0xcb, 0xbf, 0xfb, 0x9e, 0xeb, 0x79, 0x9b, 0x58, 0x8b, + 0x3b, 0xbb, 0x1a, 0xab, 0xa6, 0x6c, 0x87, 0x7c, 0xe4, 0x4c, 0xc5, 0x5c, + 0x22, 0x2c, 0x03, 0x3c, 0x60, 0x0c, 0x41, 0x1c, 0xae, 0xed, 0x8f, 0xfd, + 0xec, 0xcd, 0xcd, 0xdd, 0x2a, 0xad, 0x0b, 0xbd, 0x68, 0x8d, 0x49, 0x9d, + 0x97, 0x7e, 0xb6, 0x6e, 0xd5, 0x5e, 0xf4, 0x4e, 0x13, 0x3e, 0x32, 0x2e, + 0x51, 0x1e, 0x70, 0x0e, 0x9f, 0xff, 0xbe, 0xef, 0xdd, 0xdf, 0xfc, 0xcf, + 0x1b, 0xbf, 0x3a, 0xaf, 0x59, 0x9f, 0x78, 0x8f, 0x88, 0x91, 0xa9, 0x81, + 0xca, 0xb1, 0xeb, 0xa1, 0x0c, 0xd1, 0x2d, 0xc1, 0x4e, 0xf1, 0x6f, 0xe1, + 0x80, 0x10, 0xa1, 0x00, 0xc2, 0x30, 0xe3, 0x20, 0x04, 0x50, 0x25, 0x40, + 0x46, 0x70, 0x67, 0x60, 0xb9, 0x83, 0x98, 0x93, 0xfb, 0xa3, 0xda, 0xb3, + 0x3d, 0xc3, 0x1c, 0xd3, 0x7f, 0xe3, 0x5e, 0xf3, 0xb1, 0x02, 0x90, 0x12, + 0xf3, 0x22, 0xd2, 0x32, 0x35, 0x42, 0x14, 0x52, 0x77, 0x62, 0x56, 0x72, + 0xea, 0xb5, 0xcb, 0xa5, 0xa8, 0x95, 0x89, 0x85, 0x6e, 0xf5, 0x4f, 0xe5, + 0x2c, 0xd5, 0x0d, 0xc5, 0xe2, 0x34, 0xc3, 0x24, 0xa0, 0x14, 0x81, 0x04, + 0x66, 0x74, 0x47, 0x64, 0x24, 0x54, 0x05, 0x44, 0xdb, 0xa7, 0xfa, 0xb7, + 0x99, 0x87, 0xb8, 0x97, 0x5f, 0xe7, 0x7e, 0xf7, 0x1d, 0xc7, 0x3c, 0xd7, + 0xd3, 0x26, 0xf2, 0x36, 0x91, 0x06, 0xb0, 0x16, 0x57, 0x66, 0x76, 0x76, + 0x15, 0x46, 0x34, 0x56, 0x4c, 0xd9, 0x6d, 0xc9, 0x0e, 0xf9, 0x2f, 0xe9, + 0xc8, 0x99, 0xe9, 0x89, 0x8a, 0xb9, 0xab, 0xa9, 0x44, 0x58, 0x65, 0x48, + 0x06, 0x78, 0x27, 0x68, 0xc0, 0x18, 0xe1, 0x08, 0x82, 0x38, 0xa3, 0x28, + 0x7d, 0xcb, 0x5c, 0xdb, 0x3f, 0xeb, 0x1e, 0xfb, 0xf9, 0x8b, 0xd8, 0x9b, + 0xbb, 0xab, 0x9a, 0xbb, 0x75, 0x4a, 0x54, 0x5a, 0x37, 0x6a, 0x16, 0x7a, + 0xf1, 0x0a, 0xd0, 0x1a, 0xb3, 0x2a, 0x92, 0x3a, 0x2e, 0xfd, 0x0f, 0xed, + 0x6c, 0xdd, 0x4d, 0xcd, 0xaa, 0xbd, 0x8b, 0xad, 0xe8, 0x9d, 0xc9, 0x8d, + 0x26, 0x7c, 0x07, 0x6c, 0x64, 0x5c, 0x45, 0x4c, 0xa2, 0x3c, 0x83, 0x2c, + 0xe0, 0x1c, 0xc1, 0x0c, 0x1f, 0xef, 0x3e, 0xff, 0x5d, 0xcf, 0x7c, 0xdf, + 0x9b, 0xaf, 0xba, 0xbf, 0xd9, 0x8f, 0xf8, 0x9f, 0x17, 0x6e, 0x36, 0x7e, + 0x55, 0x4e, 0x74, 0x5e, 0x93, 0x2e, 0xb2, 0x3e, 0xd1, 0x0e, 0xf0, 0x1e, + 0x76, 0x00, 0x20, 0x00, 0x41, 0x75, 0x67, 0x20, 0x20, 0x39, 0x20, 0x32, + 0x30, 0x31, 0x38, 0x00, 0x31, 0x31, 0x3a, 0x31, 0x37, 0x3a, 0x33, 0x30, + 0x00, 0x58, 0x0a, 0x0d, 0x00, 0x79, 0x0a, 0x0d, 0x00, 0x59, 0x0a, 0x0d, + 0x00, 0x5a, 0x00, 0x23, 0x0a, 0x0d, 0x00, 0x3e, 0x00, 0x41, 0x72, 0x64, + 0x75, 0x69, 0x6e, 0x6f, 0x20, 0x4c, 0x4c, 0x43, 0x00, 0x41, 0x72, 0x64, + 0x75, 0x69, 0x6e, 0x6f, 0x20, 0x4d, 0x4b, 0x52, 0x20, 0x56, 0x69, 0x64, + 0x6f, 0x72, 0x20, 0x34, 0x30, 0x30, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x01, 0x14, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0x09, 0x02, 0x43, 0x00, + 0x02, 0x01, 0x00, 0x80, 0xfa, 0x09, 0x04, 0x00, 0x00, 0x01, 0x02, 0x02, + 0x00, 0x00, 0x05, 0x24, 0x00, 0x10, 0x01, 0x04, 0x24, 0x02, 0x00, 0x05, + 0x24, 0x06, 0x00, 0x01, 0x05, 0x24, 0x01, 0x00, 0x01, 0x07, 0x05, 0x83, + 0x03, 0x08, 0x00, 0xff, 0x09, 0x04, 0x01, 0x00, 0x02, 0x0a, 0x00, 0x00, + 0x00, 0x07, 0x05, 0x81, 0x02, 0x40, 0x00, 0x00, 0x07, 0x05, 0x02, 0x02, + 0x40, 0x00, 0x00, 0x00, 0x00, 0xc2, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, + 0x69, 0x00, 0x00, 0x00, 0x41, 0x00, 0x00, 0x00 diff --git a/libraries/SBU/examples/SBU_LoadBinary/SBU_LoadBinary.ino b/libraries/SBU/examples/SBU_LoadBinary/SBU_LoadBinary.ino new file mode 100644 index 0000000..12be605 --- /dev/null +++ b/libraries/SBU/examples/SBU_LoadBinary/SBU_LoadBinary.ino @@ -0,0 +1,96 @@ +#include +#include + +static char const BINARY[] = +{ + #include "Binary.h" +}; + +static char const CHECK_FILE[] = +{ + "OK" +}; + +static constexpr char CHECK_FILE_NAME[] = "UPDATE.OK"; + +NBFileUtils fileUtils; +bool update_available = false; + +void setup() { + Serial.begin(9600); + while(!Serial) { } + + unsigned long const start = millis(); + for(unsigned long now = millis(); !Serial && ((now - start) < 5000); now = millis()) { }; + + Serial.print("Accessing SARA Filesystem... "); + if(!fileUtils.begin(false)) { + Serial.println("failed."); + return; + + } + Serial.println("OK"); + Serial.print("Writing \"UPDATE.BIN\" ... "); + + uint32_t bytes_to_write = sizeof(BINARY); + Serial.print("Size of BINARY: "); + Serial.println(bytes_to_write); + int index = 0; + bool append = false; + int new_bytes = 0; + //int bytes_written = 0; + + for (int i=0; i<(bytes_to_write/512); i++) { + auto new_bytes = fileUtils.downloadFile("UPDATE.BIN", BINARY+index, 512, append); + if (new_bytes != 512) { + Serial.print("New_bytes = "); + Serial.print(new_bytes); + Serial.println(" != 512"); + } + index = index + new_bytes; + append = true; + } + if ((bytes_to_write%512)!=0) { + auto new_bytes = fileUtils.downloadFile("UPDATE.BIN", BINARY+index, bytes_to_write%512, append); + if (new_bytes != bytes_to_write%512) { + Serial.print("Last bytes read = "); + Serial.print(new_bytes); + Serial.print(". They should have been "); + Serial.println(bytes_to_write%512); + } + index = index + new_bytes; + } + + if(index != bytes_to_write) { + Serial.print("Written only "); + Serial.println(index); //bytes_written + Serial.print(bytes_to_write); + Serial.println(" should have been written. System is restarting..."); + delay(100); + NVIC_SystemReset(); + + } else { + Serial.print("Download complete! "); + Serial.print(index); + Serial.println(" bytes written"); + + auto status = 0; + while (status != 2) { + status = fileUtils.createFile(CHECK_FILE_NAME, CHECK_FILE, 2); + delay(100); + } + + Serial.println("Please type \"restart\" to apply the update"); + update_available = true; + } + +} + +void loop() { + if (update_available == true) { + String command = Serial.readStringUntil('\n'); + if (command.indexOf("restart") >= 0) { + NVIC_SystemReset(); + } + } +} diff --git a/libraries/SBU/examples/SBU_LoadLZSS/SBU_LoadLZSS.ino b/libraries/SBU/examples/SBU_LoadLZSS/SBU_LoadLZSS.ino new file mode 100644 index 0000000..6f5e8ca --- /dev/null +++ b/libraries/SBU/examples/SBU_LoadLZSS/SBU_LoadLZSS.ino @@ -0,0 +1,73 @@ +#include +#include + +#include "lzssEncode.h" + +static char const BINARY[] = +{ +#include "Binary.h" +}; + +static char const CHECK_FILE[] = +{ + "OK" +}; + +static constexpr char CHECK_FILE_NAME[] = "UPDATE.OK"; +const char * UPDATE_FILE_NAME_LZSS = "UPDATE.BIN.LZSS"; + +NBFileUtils fileUtils; +bool update_available = false; + +void setup() { + Serial.begin(9600); + while (!Serial) { } + + unsigned long const start = millis(); + for (unsigned long now = millis(); !Serial && ((now - start) < 5000); now = millis()) { }; + + Serial.print("Accessing SARA Filesystem... "); + if (!fileUtils.begin(false)) { + Serial.println("failed."); + return; + + } + Serial.println("OK"); + + uint32_t bytes_to_write = sizeof(BINARY); + Serial.print("Size of BINARY.H: "); + Serial.println(bytes_to_write); + + Serial.print("Encoding \"BINARY.H\" into \"UPDATE.BIN.LZSS\" and writing it into the Sara-R410M module ... "); + + //Encode into .lzss and write to the Sara modem + int bytes_written = lzss_encode(BINARY, bytes_to_write); + + if (bytes_written == 0) { + Serial.println("something went wrong!"); + } else { + Serial.println("OK!"); + } + + Serial.print("Size of UPDATE.BIN.LZSS: "); + Serial.println(bytes_written); + + auto status = 0; + while (status != 2) { + status = fileUtils.createFile(CHECK_FILE_NAME, CHECK_FILE, 2); + delay(100); + } + + Serial.println("Please type \"restart\" to apply the update"); + update_available = true; +} + + +void loop() { + if (update_available == true) { + String command = Serial.readStringUntil('\n'); + if (command.indexOf("restart") >= 0) { + NVIC_SystemReset(); + } + } +} diff --git a/libraries/SBU/examples/SBU_LoadLZSS/lzssEncode.cpp b/libraries/SBU/examples/SBU_LoadLZSS/lzssEncode.cpp new file mode 100644 index 0000000..7f7934e --- /dev/null +++ b/libraries/SBU/examples/SBU_LoadLZSS/lzssEncode.cpp @@ -0,0 +1,182 @@ +/************************************************************************************** + INCLUDE + **************************************************************************************/ + +#include "lzssEncode.h" + +#include +#include + +#include + +/************************************************************************************** + DEFINE + **************************************************************************************/ + +#define EI 11 /* typically 10..13 */ +#define EJ 4 /* typically 4..5 */ +#define P 1 /* If match length <= P then output one character */ +#define N (1 << EI) /* buffer size */ +#define F ((1 << EJ) + 1) /* lookahead buffer size */ + +#define LZSS_EOF (-1) + +#define FPUTC_BUF_SIZE (512) +#define FGETC_BUF_SIZE (512) + +/************************************************************************************** + GLOBAL VARIABLES + **************************************************************************************/ + +extern NBFileUtils fileUtils; +extern const char * UPDATE_FILE_NAME_LZSS; + +int bit_buffer = 0, bit_mask = 128; +unsigned long textcount = 0; +unsigned char buffer[N * 2]; + +static char write_buf[FPUTC_BUF_SIZE]; +static size_t write_buf_num_bytes = 0; +static size_t bytes_written_fputc = 0; + +bool append = false; +bool endOfFile = false; + +/************************************************************************************** + PUBLIC FUNCTIONS + **************************************************************************************/ + +void lzss_flush() +{ + bytes_written_fputc += write_buf_num_bytes; + + fileUtils.downloadFile(UPDATE_FILE_NAME_LZSS, write_buf, write_buf_num_bytes, append); //UPDATE.BIN.LZSS + append = true; + + write_buf_num_bytes = 0; +} + +/************************************************************************************** + PRIVATE FUNCTIONS + **************************************************************************************/ + +void lzss_fputc(int const c) +{ + /* Buffer the compressed data into a buffer so + * we can perform block writes and don't need to + * write every byte singly on the modem + */ + write_buf[write_buf_num_bytes] = static_cast(c); + write_buf_num_bytes++; + + /* The write buffer is full of compressed + * data, write it to the modem now. + */ + if (write_buf_num_bytes == FPUTC_BUF_SIZE || endOfFile) + lzss_flush(); +} + +/************************************************************************************** + LZSS FUNCTIONS + **************************************************************************************/ + +void putbit1(void) +{ + bit_buffer |= bit_mask; + if ((bit_mask >>= 1) == 0) { + lzss_fputc(bit_buffer); + bit_buffer = 0; bit_mask = 128; + } +} + +void putbit0(void) +{ + if ((bit_mask >>= 1) == 0) { + lzss_fputc(bit_buffer); + bit_buffer = 0; bit_mask = 128; + } +} + +void flush_bit_buffer(void) +{ + if (bit_mask != 128) { + lzss_fputc(bit_buffer); + } +} + +void output1(int c) +{ + int mask; + + putbit1(); + mask = 256; + while (mask >>= 1) { + if (c & mask) putbit1(); + else putbit0(); + } +} + +void output2(int x, int y) +{ + int mask; + + putbit0(); + mask = N; + while (mask >>= 1) { + if (x & mask) putbit1(); + else putbit0(); + } + mask = (1 << EJ); + while (mask >>= 1) { + if (y & mask) putbit1(); + else putbit0(); + } +} + +int lzss_encode(const char buf_in[], uint32_t size) +{ + int i, j, f1, x, y, r, s, bufferend, c; + + for (i = 0; i < N - F; i++) buffer[i] = ' '; + for (i = N - F; i < N * 2; i++) { + if (textcount >= size) { + endOfFile = true; + break; + } else { + buffer[i] = buf_in[textcount]; + textcount++; + } + } + bufferend = i; r = N - F; s = 0; + while (r < bufferend) { + f1 = (F <= bufferend - r) ? F : bufferend - r; + x = 0; y = 1; c = buffer[r]; + for (i = r - 1; i >= s; i--) + if (buffer[i] == c) { + for (j = 1; j < f1; j++) + if (buffer[i + j] != buffer[r + j]) break; + if (j > y) { + x = i; y = j; + } + } + if (y <= P) { y = 1; output1(c); } + else output2(x & (N - 1), y - 2); + r += y; s += y; + if (r >= N * 2 - F) { + for (i = 0; i < N; i++) buffer[i] = buffer[i + N]; + bufferend -= N; r -= N; s -= N; + while (bufferend < N * 2) { + if (textcount >= size) { + endOfFile = true; + break; + } else { + buffer[bufferend++] = buf_in[textcount]; + textcount++; + } + } + } + } + flush_bit_buffer(); + + return bytes_written_fputc; +} \ No newline at end of file diff --git a/libraries/SBU/examples/SBU_LoadLZSS/lzssEncode.h b/libraries/SBU/examples/SBU_LoadLZSS/lzssEncode.h new file mode 100644 index 0000000..2212c82 --- /dev/null +++ b/libraries/SBU/examples/SBU_LoadLZSS/lzssEncode.h @@ -0,0 +1,17 @@ +#ifndef SBU_LZSS_H_ +#define SBU_LZSS_H_ + +/************************************************************************************** + INCLUDE + **************************************************************************************/ + +#include + +/************************************************************************************** + FUNCTION DEFINITION + **************************************************************************************/ + +void lzss_flush(); +int lzss_encode(const char buf_in[], uint32_t size); + +#endif /* SBU_LZSS_H_ */ \ No newline at end of file diff --git a/libraries/SBU/examples/SBU_Usage/SBU_Usage.ino b/libraries/SBU/examples/SBU_Usage/SBU_Usage.ino new file mode 100644 index 0000000..85d781b --- /dev/null +++ b/libraries/SBU/examples/SBU_Usage/SBU_Usage.ino @@ -0,0 +1,48 @@ +/* + Usage + This example demonstrates how to use the SAMD SBU library to update a + sketch on any Arduino MKR board via the storage on the SARA-R410M module. + This sketch prints out the current date and time. + Steps to update sketch: + 1) Upload this sketch or another sketch that includes the SBU library + 2) Update the sketch as desired. For this example the sketch prints out + the compiled date and time. + 3) In the IDE select: Sketch -> Export compiled Binary + 4) Open the location of the sketch and convert the .bin file to a C byte array. + cat SKETCH.bin | xxd --include > Binary.h + 5) Copy Binary.h file from the sketch's folder to the SBU_LoadBinary sketch + and load it to the SARA-R410M via SBU_LoadBinary sketch. +*/ + +/* + Include the SBU library + + This will add some code to the sketch before setup() is called + to check if UPDATE.BIN and UPDATE.OK are present on the storage of + the SARA-R410M module. If this check is positive UPDATE.BIN is used to update + the sketch running on the board. + After this UPDATE.BIN and UPDATE.OK are deleted from the flash. +*/ + + +#include + +void setup() +{ + Serial.begin(9600); + while (!Serial) { } + // wait a bit + delay(1000); + String message; + message += "Sketch compile date and time: "; + message += __DATE__; + message += " "; + message += __TIME__; + // print out the sketch compile date and time on the serial port + Serial.println(message); +} + +void loop() +{ + // add you own code here +} diff --git a/libraries/SBU/extras/SBUBoot/SBUBoot.ino b/libraries/SBU/extras/SBUBoot/SBUBoot.ino new file mode 100644 index 0000000..9335c7a --- /dev/null +++ b/libraries/SBU/extras/SBUBoot/SBUBoot.ino @@ -0,0 +1,135 @@ +/* + Copyright (c) 2020 Arduino LLC. 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 +*/ + +#include +#include + +#include "lzss.h" + +#define SBU_START 0x2000 +#define SBU_SIZE 0x8000 + +#define SKETCH_START (uint32_t*)(SBU_START + SBU_SIZE) + + const char * UPDATE_FILE_NAME = "UPDATE.BIN"; + const char * UPDATE_FILE_NAME_LZSS = "UPDATE.BIN.LZSS"; +static const char * CHECK_FILE_NAME = "UPDATE.OK"; + +FlashClass mcu_flash; + +NBFileUtils fileUtils(true); + +extern "C" void __libc_init_array(void); + +int main() +{ + init(); + + __libc_init_array(); + + delay(1); + + constexpr size_t blockSize = 512; + fileUtils.begin(); + + bool update_success = false; + + // Try to update only if update file + // has been download successfully. + + if (fileUtils.listFile(CHECK_FILE_NAME)) + { + /*This is for LZSS compressed binaries. */ + if (fileUtils.listFile(UPDATE_FILE_NAME_LZSS)) + { + /* Erase the complete flash starting from the SBU forward + * because we've got no possibility of knowing how large + * the decompressed binary will finally be. + */ + mcu_flash.erase((void*)SKETCH_START, 0x40000 - (uint32_t)SKETCH_START); + /* Initialize the lzss module with the data which + * it requires. + */ + lzss_init((uint32_t)SKETCH_START); + /* During the process of decoding UPDATE.BIN.LZSS + * is decompressed and stored as UPDATE.BIN. + */ + lzss_decode(); + /* Write the data remaining in the write buffer to + * the file. + */ + lzss_flush(); + /* Signal a successul update. */ + update_success = true; + } + /* This is for uncompressed binaries. */ + else if (fileUtils.listFile(UPDATE_FILE_NAME) > 0) + { + uint32_t updateSize = fileUtils.listFile(UPDATE_FILE_NAME); + uint32_t tot_bytes = 0; + uint32_t read_bytes = 0; + + if (updateSize > SBU_SIZE) { + updateSize = updateSize - SBU_SIZE; + size_t cycles = (updateSize / blockSize) + 1; + size_t spare_bytes = (updateSize % blockSize); + + /* Erase the MCU flash */ + uint32_t flash_address = (uint32_t)SKETCH_START; + mcu_flash.erase((void*)flash_address, updateSize); + + for (auto i = 0; i < cycles; i++) { + uint8_t block[blockSize] { 0 }; + digitalWrite(LED_BUILTIN, LOW); + read_bytes = fileUtils.readBlock(UPDATE_FILE_NAME, (i * blockSize) + SBU_SIZE, blockSize, block); + digitalWrite(LED_BUILTIN, HIGH); + mcu_flash.write((void*)flash_address, block, read_bytes); + flash_address += read_bytes; + tot_bytes += read_bytes; + } + + if (spare_bytes){ + uint8_t block[spare_bytes] { 0 }; + digitalWrite(LED_BUILTIN, LOW); + read_bytes = fileUtils.readBlock(UPDATE_FILE_NAME, tot_bytes + SBU_SIZE, spare_bytes, block); + digitalWrite(LED_BUILTIN, HIGH); + mcu_flash.write((void*)flash_address, block, read_bytes); + flash_address += read_bytes; + } + update_success = true; + } + } + if (update_success) { + fileUtils.deleteFile(UPDATE_FILE_NAME); + fileUtils.deleteFile(UPDATE_FILE_NAME_LZSS); + fileUtils.deleteFile(CHECK_FILE_NAME); + } + } + +boot: + /* Jump to the sketch */ + __set_MSP(*SKETCH_START); + + /* Reset vector table address */ + SCB->VTOR = ((uint32_t)(SKETCH_START) & SCB_VTOR_TBLOFF_Msk); + + /* Address of Reset_Handler is written by the linker at the beginning of the .text section (see linker script) */ + uint32_t resetHandlerAddress = (uint32_t) * (SKETCH_START + 1); + /* Jump to reset handler */ + asm("bx %0"::"r"(resetHandlerAddress)); +} diff --git a/libraries/SBU/extras/SBUBoot/build.sh b/libraries/SBU/extras/SBUBoot/build.sh new file mode 100644 index 0000000..fb41af3 --- /dev/null +++ b/libraries/SBU/extras/SBUBoot/build.sh @@ -0,0 +1,23 @@ +#!/bin/sh -x + +#Sara R410M +ARDUINO=arduino +SKETCH_NAME="SBUBoot.ino" +SKETCH="$PWD/$SKETCH_NAME" +BUILD_PATH="$PWD/build" +OUTPUT_PATH="../../src/boot" + +if [[ "$OSTYPE" == "darwin"* ]]; then + ARDUINO="/Applications/Arduino.app/Contents/MacOS/Arduino" +fi + +buildSBUBootSketch() { + BOARD=$1 + DESTINATION=$2 + + $ARDUINO --verify --board $BOARD --preserve-temp-files --pref build.path="$BUILD_PATH" $SKETCH + cat "$BUILD_PATH/$SKETCH_NAME.bin" | xxd -include > $DESTINATION + rm -rf "$BUILD_PATH" +} + +buildSBUBootSketch "arduino:samd:mkrnb1500" "$OUTPUT_PATH/mkrnb1500.h" diff --git a/libraries/SBU/extras/SBUBoot/lzss.cpp b/libraries/SBU/extras/SBUBoot/lzss.cpp new file mode 100644 index 0000000..6a51b58 --- /dev/null +++ b/libraries/SBU/extras/SBUBoot/lzss.cpp @@ -0,0 +1,219 @@ +/************************************************************************************** + INCLUDE + **************************************************************************************/ + +#include "lzss.h" + +#include +#include + +#include +#include + +/************************************************************************************** + DEFINE + **************************************************************************************/ + +#define EI 11 /* typically 10..13 */ +#define EJ 4 /* typically 4..5 */ +#define P 1 /* If match length <= P then output one character */ +#define N (1 << EI) /* buffer size */ +#define F ((1 << EJ) + 1) /* lookahead buffer size */ + +#define LZSS_EOF (-1) + +#define FPUTC_BUF_SIZE (512) +#define FGETC_BUF_SIZE (512) + +/************************************************************************************** + GLOBAL VARIABLES + **************************************************************************************/ + +extern NBFileUtils fileUtils; +extern FlashClass mcu_flash; +extern const char * UPDATE_FILE_NAME_LZSS; + +static uint32_t SKETCH_START = 0; +static uint32_t LZSS_FILE_SIZE = 0; + +int bit_buffer = 0, bit_mask = 128; +unsigned char buffer[N * 2]; + +static char write_buf[FPUTC_BUF_SIZE]; +static size_t write_buf_num_bytes = 0; +static size_t bytes_written_fputc = 0; +static size_t bytes_written_flash = 0; +static uint32_t flash_addr = 0; + +/************************************************************************************** + PUBLIC FUNCTIONS + **************************************************************************************/ + +void lzss_init(uint32_t const sketch_start) +{ + SKETCH_START = sketch_start; + flash_addr = sketch_start; + LZSS_FILE_SIZE = fileUtils.listFile(UPDATE_FILE_NAME_LZSS); +} + +void lzss_flush() +{ + bytes_written_fputc += write_buf_num_bytes; + + /* Only write to the flash once we've surpassed + * the SBU in the update binary. + */ + if (bytes_written_fputc > (SKETCH_START - 0x2000)) + { + mcu_flash.write((void*)flash_addr, write_buf, write_buf_num_bytes); + flash_addr += write_buf_num_bytes; + } + + write_buf_num_bytes = 0; +} + +/************************************************************************************** + PRIVATE FUNCTIONS + **************************************************************************************/ + +void lzss_fputc(int const c) +{ + /* Buffer the decompressed data into a buffer so + * we can perform block writes and don't need to + * write every byte singly on the flash (which + * wouldn't be possible anyway). + */ + write_buf[write_buf_num_bytes] = static_cast(c); + write_buf_num_bytes++; + + /* The write buffer is full of decompressed + * data, write it to the flash now. + */ + if (write_buf_num_bytes == FPUTC_BUF_SIZE) + lzss_flush(); +} + +int lzss_fgetc() +{ + static uint8_t read_buf[FGETC_BUF_SIZE]; + static size_t read_buf_pos = FGETC_BUF_SIZE; + static size_t bytes_read_fgetc = 0; + static size_t bytes_read_from_modem = 0; + + /* lzss_file_size is set within SBUBoot:main + * and contains the size of the LZSS file. Once + * all those bytes have been read its time to return + * LZSS_EOF in order to signal that the end of + * the file has been reached. + */ + if (bytes_read_fgetc == LZSS_FILE_SIZE) + return LZSS_EOF; + + /* If there is no data left to be read from the read buffer + * than read a new block and store it into the read buffer. + */ + if (read_buf_pos == FGETC_BUF_SIZE) + { + /* Read the next block from the flash memory. */ + bytes_read_from_modem += fileUtils.readBlock(UPDATE_FILE_NAME_LZSS, bytes_read_from_modem, FGETC_BUF_SIZE, read_buf); + /* Reset the read buffer position. */ + read_buf_pos = 0; + } + + uint8_t const c = read_buf[read_buf_pos]; + read_buf_pos++; + bytes_read_fgetc++; + + return c; +} + +/************************************************************************************** + LZSS FUNCTIONS + **************************************************************************************/ + +void putbit1(void) +{ + bit_buffer |= bit_mask; + if ((bit_mask >>= 1) == 0) { + lzss_fputc(bit_buffer); + bit_buffer = 0; bit_mask = 128; + } +} + +void putbit0(void) +{ + if ((bit_mask >>= 1) == 0) { + lzss_fputc(bit_buffer); + bit_buffer = 0; bit_mask = 128; + } +} + +void output1(int c) +{ + int mask; + + putbit1(); + mask = 256; + while (mask >>= 1) { + if (c & mask) putbit1(); + else putbit0(); + } +} + +void output2(int x, int y) +{ + int mask; + + putbit0(); + mask = N; + while (mask >>= 1) { + if (x & mask) putbit1(); + else putbit0(); + } + mask = (1 << EJ); + while (mask >>= 1) { + if (y & mask) putbit1(); + else putbit0(); + } +} + +int getbit(int n) /* get n bits */ +{ + int i, x; + static int buf, mask = 0; + + x = 0; + for (i = 0; i < n; i++) { + if (mask == 0) { + if ((buf = lzss_fgetc()) == LZSS_EOF) return LZSS_EOF; + mask = 128; + } + x <<= 1; + if (buf & mask) x++; + mask >>= 1; + } + return x; +} + +void lzss_decode(void) +{ + int i, j, k, r, c; + + for (i = 0; i < N - F; i++) buffer[i] = ' '; + r = N - F; + while ((c = getbit(1)) != LZSS_EOF) { + if (c) { + if ((c = getbit(8)) == LZSS_EOF) break; + lzss_fputc(c); + buffer[r++] = c; r &= (N - 1); + } else { + if ((i = getbit(EI)) == LZSS_EOF) break; + if ((j = getbit(EJ)) == LZSS_EOF) break; + for (k = 0; k <= j + 1; k++) { + c = buffer[(i + k) & (N - 1)]; + lzss_fputc(c); + buffer[r++] = c; r &= (N - 1); + } + } + } +} diff --git a/libraries/SBU/extras/SBUBoot/lzss.h b/libraries/SBU/extras/SBUBoot/lzss.h new file mode 100644 index 0000000..130c537 --- /dev/null +++ b/libraries/SBU/extras/SBUBoot/lzss.h @@ -0,0 +1,18 @@ +#ifndef SBU_LZSS_H_ +#define SBU_LZSS_H_ + +/************************************************************************************** + INCLUDE + **************************************************************************************/ + +#include + +/************************************************************************************** + FUNCTION DEFINITION + **************************************************************************************/ + +void lzss_init(uint32_t const sketch_start); +void lzss_decode(); +void lzss_flush(); + +#endif /* SBU_LZSS_H_ */ \ No newline at end of file diff --git a/libraries/SBU/keywords.txt b/libraries/SBU/keywords.txt new file mode 100644 index 0000000..7ca8fcf --- /dev/null +++ b/libraries/SBU/keywords.txt @@ -0,0 +1,17 @@ +####################################### +# Syntax Coloring Map For SBU +####################################### + +####################################### +# Datatypes (KEYWORD1) +####################################### + +SBU KEYWORD1 + +####################################### +# Methods and Functions (KEYWORD2) +####################################### + +####################################### +# Constants (LITERAL1) +####################################### diff --git a/libraries/SBU/library.properties b/libraries/SBU/library.properties new file mode 100644 index 0000000..073dc33 --- /dev/null +++ b/libraries/SBU/library.properties @@ -0,0 +1,9 @@ +name=SBU +version=1.0.0 +author=Arduino +maintainer=Arduino +sentence=Update the sketch on your Arduino MKRNB1500 from SARA-R410M flash. +paragraph= +category=Other +url= +architectures=samd diff --git a/libraries/SBU/src/SBU.cpp b/libraries/SBU/src/SBU.cpp new file mode 100644 index 0000000..b35dce7 --- /dev/null +++ b/libraries/SBU/src/SBU.cpp @@ -0,0 +1,30 @@ +/* + Copyright (c) 2020 Arduino LLC. 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 +*/ + +#include + +#include "SBU.h" + +__attribute__ ((section(".sketch_boot"))) +unsigned char SBU_BOOT[0x8000] = { +#if defined(ARDUINO_SAMD_MKRNB1500) + #include "boot/mkrnb1500.h" +#else + #error "Unsupported board!" +#endif +}; diff --git a/libraries/SBU/src/SBU.h b/libraries/SBU/src/SBU.h new file mode 100644 index 0000000..689c8a6 --- /dev/null +++ b/libraries/SBU/src/SBU.h @@ -0,0 +1,24 @@ +/* + Copyright (c) 2020 Arduino LLC. 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 _SBU_H_INCLUDED +#define _SBU_H_INCLUDED + +/* Nothing to do */ + +#endif /* _SBU_H_INCLUDED */ diff --git a/libraries/SBU/src/boot/mkrnb1500.h b/libraries/SBU/src/boot/mkrnb1500.h new file mode 100644 index 0000000..f830f43 --- /dev/null +++ b/libraries/SBU/src/boot/mkrnb1500.h @@ -0,0 +1,2671 @@ + 0x00, 0x80, 0x00, 0x20, 0xad, 0x30, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, + 0x95, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, + 0x01, 0x31, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, + 0x95, 0x30, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, + 0x95, 0x30, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, 0x99, 0x30, 0x00, 0x00, + 0x95, 0x30, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, + 0x95, 0x30, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, 0xed, 0x2f, 0x00, 0x00, + 0xdd, 0x2f, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, + 0x95, 0x30, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, + 0x95, 0x30, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, + 0x95, 0x30, 0x00, 0x00, 0x95, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0x30, 0x02, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xf8, 0x9a, 0x00, 0x00, 0x04, 0x4b, 0x10, 0xb5, 0x00, 0x2b, 0x03, 0xd0, + 0x03, 0x49, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x10, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x00, 0x34, 0x02, 0x00, 0x20, 0xf8, 0x9a, 0x00, 0x00, + 0x10, 0xb5, 0x04, 0x00, 0x04, 0x30, 0x02, 0xf0, 0xbb, 0xfa, 0x20, 0x00, + 0x10, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x10, 0x26, 0x9b, 0x4c, 0xa5, 0x44, + 0x02, 0xaf, 0x01, 0xf0, 0x09, 0xf9, 0x04, 0xf0, 0xe5, 0xfb, 0x01, 0x20, + 0x01, 0xf0, 0x2c, 0xf8, 0x97, 0x4c, 0x01, 0x21, 0x20, 0x00, 0x00, 0xf0, + 0xdf, 0xfd, 0xbb, 0x19, 0x98, 0x19, 0x95, 0x49, 0x02, 0xf0, 0xec, 0xfa, + 0xba, 0x19, 0x91, 0x19, 0x20, 0x00, 0x00, 0xf0, 0x33, 0xfe, 0xbb, 0x19, + 0x05, 0x00, 0x98, 0x19, 0x02, 0xf0, 0x98, 0xfa, 0x00, 0x2d, 0x4f, 0xd0, + 0x8e, 0x4b, 0x19, 0x68, 0xbb, 0x19, 0x98, 0x19, 0x02, 0xf0, 0xda, 0xfa, + 0xbb, 0x19, 0x99, 0x19, 0x20, 0x00, 0x00, 0xf0, 0x21, 0xfe, 0xbb, 0x19, + 0xf8, 0x60, 0x98, 0x19, 0x02, 0xf0, 0x86, 0xfa, 0xfb, 0x68, 0x00, 0x2b, + 0x4c, 0xd0, 0xd8, 0x22, 0xa0, 0x21, 0x92, 0x02, 0x09, 0x02, 0x84, 0x48, + 0x00, 0xf0, 0xc0, 0xfa, 0xa0, 0x20, 0x00, 0x02, 0x00, 0xf0, 0x30, 0xf9, + 0x00, 0xf0, 0xec, 0xf9, 0x00, 0xf0, 0x4c, 0xf9, 0x10, 0x25, 0x7f, 0x4b, + 0x19, 0x68, 0x7b, 0x19, 0x58, 0x19, 0x02, 0xf0, 0xb7, 0xfa, 0x78, 0x4c, + 0x7b, 0x19, 0x59, 0x19, 0x20, 0x00, 0x00, 0xf0, 0xd5, 0xfd, 0x7b, 0x19, + 0x58, 0x19, 0x02, 0xf0, 0x63, 0xfa, 0x75, 0x4b, 0x19, 0x68, 0x7b, 0x19, + 0x58, 0x19, 0x02, 0xf0, 0xa7, 0xfa, 0x7b, 0x19, 0x59, 0x19, 0x20, 0x00, + 0x00, 0xf0, 0xc6, 0xfd, 0x7b, 0x19, 0x58, 0x19, 0x02, 0xf0, 0x54, 0xfa, + 0x7b, 0x19, 0x6c, 0x49, 0x58, 0x19, 0x02, 0xf0, 0x99, 0xfa, 0x7b, 0x19, + 0x59, 0x19, 0x20, 0x00, 0x00, 0xf0, 0xb8, 0xfd, 0x7b, 0x19, 0x58, 0x19, + 0x02, 0xf0, 0x46, 0xfa, 0xa0, 0x23, 0x1b, 0x02, 0x1a, 0x68, 0x82, 0xf3, + 0x08, 0x88, 0x67, 0x4a, 0x93, 0x60, 0x67, 0x4b, 0x1b, 0x68, 0x18, 0x47, + 0x00, 0x20, 0xbd, 0x46, 0x89, 0x23, 0x9b, 0x00, 0x9d, 0x44, 0xf0, 0xbd, + 0x10, 0x26, 0x60, 0x4d, 0xbb, 0x19, 0x98, 0x19, 0x29, 0x68, 0x02, 0xf0, + 0x79, 0xfa, 0xbb, 0x19, 0x99, 0x19, 0x20, 0x00, 0x00, 0xf0, 0xc0, 0xfd, + 0x10, 0x23, 0xfa, 0x18, 0x06, 0x00, 0xd0, 0x18, 0x02, 0xf0, 0x24, 0xfa, + 0x00, 0x2e, 0xdb, 0xd0, 0x29, 0x68, 0x10, 0x25, 0x7b, 0x19, 0x58, 0x19, + 0x02, 0xf0, 0x66, 0xfa, 0x7b, 0x19, 0x59, 0x19, 0x20, 0x00, 0x00, 0xf0, + 0xad, 0xfd, 0x7b, 0x19, 0x04, 0x00, 0x58, 0x19, 0x80, 0x25, 0x02, 0xf0, + 0x11, 0xfa, 0x2d, 0x02, 0xac, 0x42, 0xc7, 0xd9, 0xa0, 0x21, 0x4f, 0x4b, + 0x09, 0x02, 0xe4, 0x18, 0xe6, 0x05, 0x22, 0x00, 0x64, 0x0a, 0x41, 0x34, + 0x47, 0x48, 0x00, 0xf0, 0x47, 0xfa, 0x63, 0x02, 0xa0, 0x24, 0x7b, 0x60, + 0xfb, 0x68, 0xf6, 0x0d, 0xbb, 0x60, 0x24, 0x02, 0x10, 0x23, 0x80, 0x22, + 0xf8, 0x18, 0x92, 0x00, 0xc0, 0x18, 0x00, 0x21, 0x04, 0xf0, 0xaa, 0xfb, + 0x00, 0x21, 0x06, 0x20, 0x01, 0xf0, 0x3e, 0xf9, 0x3d, 0x4b, 0x19, 0x68, + 0x14, 0x23, 0xf8, 0x18, 0x02, 0xf0, 0x34, 0xfa, 0x10, 0x23, 0xf8, 0x18, + 0xc1, 0x18, 0x00, 0x91, 0x14, 0x21, 0xf1, 0x33, 0x2a, 0x00, 0x79, 0x18, + 0xff, 0x33, 0x32, 0x48, 0x00, 0xf0, 0xa4, 0xfd, 0x14, 0x23, 0xf8, 0x60, + 0xf8, 0x18, 0x02, 0xf0, 0xd9, 0xf9, 0x01, 0x21, 0x06, 0x20, 0x01, 0xf0, + 0x23, 0xf9, 0x10, 0x22, 0xb9, 0x18, 0x8a, 0x18, 0xfb, 0x68, 0x21, 0x00, + 0x2c, 0x48, 0x00, 0xf0, 0xc1, 0xf9, 0xfa, 0x68, 0xfb, 0x68, 0x94, 0x46, + 0xe4, 0x18, 0xbb, 0x68, 0x63, 0x44, 0xbb, 0x60, 0x80, 0x23, 0x9b, 0x00, + 0xed, 0x18, 0x7b, 0x68, 0xab, 0x42, 0xc3, 0xd1, 0x00, 0x2e, 0x00, 0xd1, + 0x48, 0xe7, 0x6b, 0x46, 0x6a, 0x46, 0xfb, 0x60, 0xf3, 0x1d, 0xdb, 0x08, + 0xdb, 0x00, 0xd3, 0x1a, 0x9d, 0x46, 0x00, 0x22, 0x09, 0x23, 0x02, 0xad, + 0x2a, 0x70, 0x6b, 0x44, 0xa9, 0x19, 0x8b, 0x42, 0x02, 0xd0, 0x1a, 0x70, + 0x01, 0x33, 0xfa, 0xe7, 0x00, 0x21, 0x06, 0x20, 0x01, 0xf0, 0xf4, 0xf8, + 0x18, 0x4b, 0x19, 0x68, 0x10, 0x23, 0xfa, 0x18, 0xd0, 0x18, 0x02, 0xf0, + 0xe9, 0xf9, 0x80, 0x20, 0x10, 0x21, 0x00, 0x02, 0x84, 0x46, 0xba, 0x68, + 0x33, 0x00, 0x7e, 0x18, 0x70, 0x18, 0x62, 0x44, 0x01, 0x00, 0x00, 0x95, + 0x0b, 0x48, 0x00, 0xf0, 0x57, 0xfd, 0x10, 0x21, 0x06, 0x00, 0x7b, 0x18, + 0x58, 0x18, 0x02, 0xf0, 0x8b, 0xf9, 0x01, 0x21, 0x06, 0x20, 0x01, 0xf0, + 0xd5, 0xf8, 0x33, 0x00, 0x2a, 0x00, 0x21, 0x00, 0x06, 0x48, 0x00, 0xf0, + 0x75, 0xf9, 0xfb, 0x68, 0x9d, 0x46, 0x09, 0xe7, 0xd4, 0xfd, 0xff, 0xff, + 0x54, 0x02, 0x00, 0x20, 0x68, 0x8d, 0x00, 0x00, 0x08, 0x00, 0x00, 0x20, + 0x68, 0x02, 0x00, 0x20, 0x04, 0x00, 0x00, 0x20, 0x00, 0xed, 0x00, 0xe0, + 0x04, 0xa0, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x13, 0xb5, 0x00, 0x24, + 0x0b, 0x48, 0x23, 0x00, 0x00, 0x94, 0x22, 0x00, 0x21, 0x00, 0x01, 0xf0, + 0x77, 0xf9, 0x22, 0x00, 0x21, 0x00, 0x08, 0x48, 0x00, 0xf0, 0x3a, 0xf9, + 0x07, 0x4c, 0x01, 0x21, 0x20, 0x00, 0x00, 0xf0, 0x35, 0xfc, 0x06, 0x4a, + 0x06, 0x49, 0x20, 0x00, 0x02, 0xf0, 0x2e, 0xfb, 0x13, 0xbd, 0xc0, 0x46, + 0x4c, 0x02, 0x00, 0x20, 0x68, 0x02, 0x00, 0x20, 0x54, 0x02, 0x00, 0x20, + 0x00, 0x00, 0x00, 0x20, 0xfd, 0x20, 0x00, 0x00, 0x1f, 0xb5, 0x0a, 0x4b, + 0x18, 0x60, 0x0a, 0x4b, 0x18, 0x60, 0x0a, 0x4b, 0x01, 0xa8, 0x19, 0x68, + 0x02, 0xf0, 0x88, 0xf9, 0x01, 0xa9, 0x08, 0x48, 0x00, 0xf0, 0xd0, 0xfc, + 0x07, 0x4b, 0x18, 0x60, 0x01, 0xa8, 0x02, 0xf0, 0x35, 0xf9, 0x05, 0xb0, + 0x00, 0xbd, 0xc0, 0x46, 0x8c, 0x02, 0x00, 0x20, 0x80, 0x02, 0x00, 0x20, + 0x08, 0x00, 0x00, 0x20, 0x54, 0x02, 0x00, 0x20, 0x90, 0x02, 0x00, 0x20, + 0x0c, 0x49, 0x70, 0xb5, 0x0c, 0x4c, 0x0a, 0x68, 0x23, 0x68, 0x0c, 0x48, + 0x9a, 0x18, 0x0a, 0x60, 0x0b, 0x49, 0x09, 0x68, 0x09, 0x18, 0x8a, 0x42, + 0x09, 0xd9, 0x0a, 0x4d, 0x0a, 0x4a, 0x29, 0x68, 0x0a, 0x48, 0x00, 0xf0, + 0x09, 0xf9, 0x2b, 0x68, 0x22, 0x68, 0x9b, 0x18, 0x2b, 0x60, 0x00, 0x23, + 0x23, 0x60, 0x70, 0xbd, 0x94, 0x02, 0x00, 0x20, 0x98, 0x02, 0x00, 0x20, + 0x00, 0xe0, 0xff, 0xff, 0x8c, 0x02, 0x00, 0x20, 0x80, 0x02, 0x00, 0x20, + 0x9c, 0x02, 0x00, 0x20, 0x68, 0x02, 0x00, 0x20, 0x06, 0x4a, 0x07, 0x49, + 0x13, 0x68, 0x10, 0xb5, 0xc8, 0x54, 0x01, 0x33, 0x13, 0x60, 0x80, 0x22, + 0x92, 0x00, 0x93, 0x42, 0x01, 0xd1, 0xff, 0xf7, 0xcb, 0xff, 0x10, 0xbd, + 0x98, 0x02, 0x00, 0x20, 0x9c, 0x02, 0x00, 0x20, 0xf0, 0xb5, 0x18, 0x4b, + 0x18, 0x4d, 0x1b, 0x68, 0x2a, 0x68, 0x87, 0xb0, 0x9a, 0x42, 0x25, 0xd0, + 0x80, 0x23, 0x16, 0x4c, 0x9b, 0x00, 0x27, 0x68, 0x9f, 0x42, 0x15, 0xd1, + 0x14, 0x4b, 0x03, 0xa8, 0x19, 0x68, 0x02, 0xf0, 0x25, 0xf9, 0x13, 0x4b, + 0x13, 0x4e, 0x00, 0x93, 0x32, 0x68, 0x3b, 0x00, 0x03, 0xa9, 0x12, 0x48, + 0x00, 0xf0, 0x98, 0xfc, 0x33, 0x68, 0x18, 0x18, 0x30, 0x60, 0x03, 0xa8, + 0x02, 0xf0, 0xcc, 0xf8, 0x00, 0x23, 0x23, 0x60, 0x23, 0x68, 0x0a, 0x4a, + 0xd0, 0x5c, 0x01, 0x33, 0x23, 0x60, 0x2b, 0x68, 0x01, 0x33, 0x2b, 0x60, + 0x07, 0xb0, 0xf0, 0xbd, 0x01, 0x20, 0x40, 0x42, 0xfa, 0xe7, 0xc0, 0x46, + 0x90, 0x02, 0x00, 0x20, 0x9c, 0x04, 0x00, 0x20, 0x0c, 0x00, 0x00, 0x20, + 0x08, 0x00, 0x00, 0x20, 0xa4, 0x04, 0x00, 0x20, 0xa0, 0x04, 0x00, 0x20, + 0x54, 0x02, 0x00, 0x20, 0xf7, 0xb5, 0x00, 0x24, 0x26, 0x00, 0x01, 0x90, + 0x01, 0x9b, 0x9e, 0x42, 0x16, 0xda, 0x0c, 0x4d, 0x0c, 0x4f, 0x2b, 0x68, + 0x00, 0x2b, 0x06, 0xd1, 0xff, 0xf7, 0xb2, 0xff, 0x38, 0x60, 0x43, 0x1c, + 0x0d, 0xd0, 0x80, 0x23, 0x2b, 0x60, 0x2a, 0x68, 0x3b, 0x68, 0x64, 0x00, + 0x13, 0x40, 0x59, 0x1e, 0x8b, 0x41, 0x52, 0x10, 0xe4, 0x18, 0x2a, 0x60, + 0x01, 0x36, 0xe5, 0xe7, 0x20, 0x00, 0xfe, 0xbd, 0xa8, 0x06, 0x00, 0x20, + 0xa4, 0x06, 0x00, 0x20, 0xf7, 0xb5, 0x00, 0x24, 0x20, 0x22, 0x1e, 0x4d, + 0x1e, 0x4b, 0x2a, 0x55, 0x01, 0x34, 0x9c, 0x42, 0xfb, 0xd1, 0x01, 0x20, + 0xff, 0xf7, 0xd0, 0xff, 0x43, 0x1c, 0x30, 0xd0, 0x00, 0x28, 0x0c, 0xd0, + 0x08, 0x20, 0xff, 0xf7, 0xc9, 0xff, 0x06, 0x00, 0x43, 0x1c, 0x28, 0xd0, + 0xff, 0xf7, 0x72, 0xff, 0x63, 0x1c, 0x2e, 0x55, 0x5c, 0x05, 0x64, 0x0d, + 0xeb, 0xe7, 0x0b, 0x20, 0xff, 0xf7, 0xbc, 0xff, 0x06, 0x00, 0x43, 0x1c, + 0x1b, 0xd0, 0x04, 0x20, 0xff, 0xf7, 0xb6, 0xff, 0x03, 0x00, 0x01, 0x90, + 0x01, 0x33, 0x14, 0xd0, 0x37, 0x00, 0x01, 0x9b, 0xba, 0x1b, 0x01, 0x33, + 0x93, 0x42, 0xd8, 0xdb, 0x7b, 0x05, 0x5b, 0x0d, 0xeb, 0x5c, 0x01, 0x37, + 0x18, 0x00, 0x00, 0x93, 0xff, 0xf7, 0x52, 0xff, 0x6a, 0x46, 0x12, 0x78, + 0x63, 0x1c, 0x2a, 0x55, 0x5c, 0x05, 0x64, 0x0d, 0xeb, 0xe7, 0xf7, 0xbd, + 0xac, 0x06, 0x00, 0x20, 0xef, 0x07, 0x00, 0x00, 0x07, 0xb5, 0x00, 0x21, + 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, 0x01, 0xf0, 0x52, 0xf8, + 0x07, 0xbd, 0xc0, 0x46, 0x84, 0x02, 0x00, 0x20, 0x10, 0xb5, 0x05, 0x4a, + 0x05, 0x49, 0x06, 0x48, 0x00, 0xf0, 0x10, 0xf8, 0x00, 0x22, 0x05, 0x4b, + 0x05, 0x49, 0x1a, 0x70, 0x5a, 0x54, 0x10, 0xbd, 0x01, 0x04, 0x00, 0x00, + 0x00, 0x8e, 0x00, 0x00, 0xb0, 0x1a, 0x00, 0x20, 0xac, 0x16, 0x00, 0x20, + 0x02, 0x04, 0x00, 0x00, 0x30, 0xb5, 0x09, 0x4d, 0x09, 0x4c, 0xab, 0x68, + 0x5b, 0x03, 0x5b, 0x0f, 0x9b, 0x00, 0x1c, 0x59, 0x04, 0x60, 0xab, 0x68, + 0x01, 0x61, 0x9b, 0xb2, 0x43, 0x60, 0x63, 0x43, 0xa4, 0x00, 0x83, 0x60, + 0xc4, 0x60, 0x42, 0x61, 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x00, 0x93, 0x00, 0x00, 0xf7, 0xb5, 0x80, 0x26, 0x1a, 0x4d, 0x01, 0x91, + 0x6f, 0x68, 0x03, 0x33, 0x3e, 0x43, 0x9b, 0x08, 0x6e, 0x60, 0x00, 0x2b, + 0x2b, 0xd0, 0x17, 0x4e, 0x2e, 0x80, 0x2e, 0x7d, 0xf1, 0x07, 0xfc, 0xd5, + 0x1e, 0x00, 0x07, 0x68, 0x99, 0x1b, 0xbf, 0x08, 0x8f, 0x42, 0x19, 0xd9, + 0x00, 0x2e, 0x17, 0xd0, 0xff, 0x21, 0x17, 0x78, 0x8c, 0x43, 0x3c, 0x43, + 0x0f, 0x49, 0x57, 0x78, 0x0c, 0x40, 0x3f, 0x02, 0x3c, 0x43, 0x97, 0x78, + 0x01, 0x3e, 0x39, 0x04, 0x0c, 0x4f, 0x27, 0x40, 0xd4, 0x78, 0xbf, 0xb2, + 0x0f, 0x43, 0x24, 0x06, 0x01, 0x99, 0x3c, 0x43, 0x10, 0xc1, 0x01, 0x91, + 0x04, 0x32, 0xe0, 0xe7, 0x07, 0x4b, 0x2b, 0x80, 0x2b, 0x7d, 0xdb, 0x07, + 0xfc, 0xd5, 0x33, 0x00, 0xd1, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, + 0x44, 0xa5, 0xff, 0xff, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, + 0x04, 0xa5, 0xff, 0xff, 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, + 0x1a, 0x80, 0x1a, 0x7d, 0xd2, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, + 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x04, 0x00, + 0x0d, 0x00, 0x16, 0x00, 0xe3, 0x68, 0x29, 0x00, 0x20, 0x00, 0xb3, 0x42, + 0x05, 0xd2, 0xff, 0xf7, 0xe7, 0xff, 0xe3, 0x68, 0xed, 0x18, 0xf6, 0x1a, + 0xf4, 0xe7, 0xff, 0xf7, 0xe1, 0xff, 0x70, 0xbd, 0x07, 0xb5, 0x00, 0x21, + 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, 0x00, 0xf0, 0xb6, 0xff, + 0x07, 0xbd, 0xc0, 0x46, 0xc8, 0x1a, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, + 0x20, 0x30, 0x01, 0xf0, 0x99, 0xff, 0x20, 0x00, 0x10, 0xbd, 0x00, 0x00, + 0x70, 0xb5, 0x83, 0x60, 0x04, 0x9b, 0x06, 0x00, 0xc3, 0x60, 0x05, 0x9b, + 0x00, 0x25, 0x03, 0x61, 0x01, 0x23, 0x04, 0x00, 0x20, 0x36, 0x42, 0x60, + 0x45, 0x61, 0x05, 0x76, 0xc3, 0x61, 0x01, 0x60, 0x30, 0x00, 0x05, 0x49, + 0x01, 0xf0, 0xcc, 0xff, 0xe5, 0x62, 0x30, 0x00, 0x40, 0x21, 0x01, 0xf0, + 0x9e, 0xff, 0x20, 0x00, 0x70, 0xbd, 0xc0, 0x46, 0x27, 0x93, 0x00, 0x00, + 0x03, 0x69, 0x02, 0x33, 0x00, 0xd3, 0x01, 0x61, 0x70, 0x47, 0x03, 0x69, + 0x10, 0xb5, 0x00, 0x20, 0x5a, 0x1c, 0x05, 0xd0, 0x01, 0x30, 0x9a, 0x1c, + 0x02, 0xd0, 0x18, 0x00, 0x00, 0xf0, 0xe2, 0xfe, 0x10, 0xbd, 0x00, 0x00, + 0x10, 0xb5, 0x04, 0x00, 0x00, 0x68, 0x03, 0x68, 0x5b, 0x6a, 0x98, 0x47, + 0x20, 0x00, 0xff, 0xf7, 0xea, 0xff, 0x00, 0x28, 0x0f, 0xd0, 0x01, 0x21, + 0xe0, 0x68, 0x00, 0xf0, 0xa5, 0xfe, 0x06, 0x48, 0x00, 0xf0, 0xd4, 0xfc, + 0x00, 0x21, 0xe0, 0x68, 0x00, 0xf0, 0x9e, 0xfe, 0x01, 0x21, 0x20, 0x00, + 0x49, 0x42, 0xff, 0xf7, 0xd3, 0xff, 0x10, 0xbd, 0xdc, 0x05, 0x00, 0x00, + 0x01, 0x4b, 0x02, 0x4a, 0x1a, 0x60, 0x70, 0x47, 0x00, 0x1b, 0x00, 0x20, + 0x2c, 0x20, 0x00, 0x20, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x00, 0xf0, + 0x85, 0xfc, 0x63, 0x69, 0xc0, 0x1a, 0x13, 0x28, 0x03, 0xd8, 0x14, 0x23, + 0x18, 0x1a, 0x00, 0xf0, 0xb3, 0xfc, 0x29, 0x00, 0x20, 0x68, 0x00, 0xf0, + 0x87, 0xff, 0x20, 0x68, 0x03, 0x68, 0xdb, 0x68, 0x98, 0x47, 0x00, 0x23, + 0x23, 0x76, 0xe3, 0x61, 0x70, 0xbd, 0x00, 0x00, 0x0e, 0xb4, 0x10, 0xb5, + 0x0a, 0x4c, 0x0b, 0x49, 0xa5, 0x44, 0x04, 0x00, 0xff, 0xab, 0x18, 0x33, + 0x04, 0xcb, 0x02, 0xa8, 0x01, 0x93, 0x04, 0xf0, 0x21, 0xff, 0x02, 0xa9, + 0x20, 0x00, 0xff, 0xf7, 0xd5, 0xff, 0x05, 0x4b, 0x9d, 0x44, 0x10, 0xbc, + 0x08, 0xbc, 0x03, 0xb0, 0x18, 0x47, 0xc0, 0x46, 0xf4, 0xfb, 0xff, 0xff, + 0xff, 0x03, 0x00, 0x00, 0x0c, 0x04, 0x00, 0x00, 0xf0, 0xb5, 0x04, 0x00, + 0x87, 0xb0, 0x20, 0x68, 0x03, 0x68, 0x1b, 0x69, 0x98, 0x47, 0x00, 0x28, + 0x00, 0xd1, 0x92, 0xe0, 0x20, 0x68, 0x03, 0x68, 0x5b, 0x69, 0x98, 0x47, + 0x63, 0x4b, 0xc6, 0xb2, 0x18, 0x68, 0x00, 0x28, 0x03, 0xd0, 0x03, 0x68, + 0x31, 0x00, 0x1b, 0x68, 0x98, 0x47, 0x25, 0x00, 0x20, 0x35, 0x31, 0x00, + 0x28, 0x00, 0x01, 0xf0, 0xba, 0xff, 0x27, 0x7e, 0x01, 0x2f, 0x48, 0xd0, + 0x5b, 0x49, 0x68, 0x46, 0x01, 0xf0, 0x2e, 0xff, 0x69, 0x46, 0x28, 0x00, + 0x01, 0xf0, 0xcf, 0xff, 0x00, 0x26, 0xb0, 0x42, 0x0d, 0xd0, 0x57, 0x49, + 0x03, 0xa8, 0x01, 0xf0, 0x23, 0xff, 0x03, 0xa9, 0x28, 0x00, 0x01, 0xf0, + 0xd0, 0xff, 0x46, 0x1e, 0xb0, 0x41, 0xc6, 0xb2, 0x03, 0xa8, 0x01, 0xf0, + 0xcf, 0xfe, 0x68, 0x46, 0x01, 0xf0, 0xcc, 0xfe, 0x00, 0x2e, 0x06, 0xd0, + 0x01, 0x23, 0x23, 0x76, 0x4d, 0x49, 0x28, 0x00, 0x01, 0xf0, 0x6f, 0xff, + 0xbd, 0xe7, 0x4a, 0x49, 0x03, 0xa8, 0x01, 0xf0, 0x09, 0xff, 0x03, 0xa9, + 0x28, 0x00, 0x01, 0xf0, 0xb6, 0xff, 0x07, 0x00, 0x03, 0xa8, 0x01, 0xf0, + 0xb7, 0xfe, 0x00, 0x2f, 0xaf, 0xd0, 0x28, 0x00, 0x02, 0xf0, 0x56, 0xf8, + 0xa3, 0x6a, 0x00, 0x2b, 0xe6, 0xd0, 0x00, 0xf0, 0xf7, 0xfb, 0x60, 0x61, + 0x40, 0x4b, 0xb2, 0x00, 0xd0, 0x58, 0x00, 0x28, 0x03, 0xd0, 0x03, 0x68, + 0x29, 0x00, 0x1b, 0x68, 0x98, 0x47, 0x01, 0x36, 0x08, 0x2e, 0xf3, 0xd1, + 0xd6, 0xe7, 0x0a, 0x2e, 0x97, 0xd1, 0x00, 0xf0, 0xe5, 0xfb, 0x39, 0x49, + 0x60, 0x61, 0x03, 0xa8, 0x01, 0xf0, 0xe0, 0xfe, 0x03, 0xa9, 0x28, 0x00, + 0x01, 0xf0, 0xea, 0xff, 0x06, 0x00, 0x03, 0xa8, 0x01, 0xf0, 0x8e, 0xfe, + 0x73, 0x1c, 0x22, 0xd0, 0xe7, 0x61, 0xe3, 0x69, 0x00, 0x2b, 0x82, 0xd0, + 0xe2, 0x6a, 0x00, 0x2a, 0x13, 0xd0, 0x01, 0x2b, 0x4a, 0xdd, 0x03, 0xa8, + 0xa3, 0x6a, 0x32, 0x00, 0x29, 0x00, 0x01, 0xf0, 0xdd, 0xff, 0x03, 0xa8, + 0x01, 0xf0, 0x7a, 0xfe, 0x28, 0x00, 0x02, 0xf0, 0x1b, 0xf8, 0x29, 0x00, + 0xe0, 0x6a, 0x01, 0xf0, 0xfc, 0xfe, 0x00, 0x23, 0xe3, 0x62, 0x00, 0x23, + 0x21, 0x49, 0x23, 0x76, 0x28, 0x00, 0x01, 0xf0, 0x16, 0xff, 0x07, 0xb0, + 0xf0, 0xbd, 0x21, 0x49, 0x03, 0xa8, 0x01, 0xf0, 0xaf, 0xfe, 0x03, 0xa9, + 0x28, 0x00, 0x01, 0xf0, 0xb9, 0xff, 0x06, 0x00, 0x03, 0xa8, 0x01, 0xf0, + 0x5d, 0xfe, 0x73, 0x1c, 0x02, 0xd0, 0x02, 0x23, 0xe3, 0x61, 0xcc, 0xe7, + 0x19, 0x49, 0x03, 0xa8, 0x01, 0xf0, 0x9e, 0xfe, 0x03, 0xa9, 0x28, 0x00, + 0x01, 0xf0, 0xa8, 0xff, 0x06, 0x00, 0x03, 0xa8, 0x01, 0xf0, 0x4c, 0xfe, + 0x73, 0x1c, 0x01, 0xd0, 0x03, 0x23, 0xed, 0xe7, 0x12, 0x49, 0x03, 0xa8, + 0x01, 0xf0, 0x8e, 0xfe, 0x03, 0xa9, 0x28, 0x00, 0x01, 0xf0, 0x98, 0xff, + 0x06, 0x00, 0x03, 0xa8, 0x01, 0xf0, 0x3c, 0xfe, 0x73, 0x1c, 0xae, 0xd0, + 0x04, 0x23, 0xdd, 0xe7, 0x31, 0x00, 0x28, 0x00, 0x01, 0xf0, 0xd2, 0xff, + 0xb8, 0xe7, 0xc0, 0x46, 0x00, 0x1b, 0x00, 0x20, 0x20, 0x93, 0x00, 0x00, + 0x25, 0x93, 0x00, 0x00, 0x27, 0x93, 0x00, 0x00, 0x04, 0x1b, 0x00, 0x20, + 0x23, 0x93, 0x00, 0x00, 0x28, 0x93, 0x00, 0x00, 0x30, 0x93, 0x00, 0x00, + 0x3d, 0x93, 0x00, 0x00, 0x70, 0xb5, 0xc2, 0x62, 0x04, 0x00, 0x0e, 0x00, + 0x00, 0xf0, 0x64, 0xfb, 0x05, 0x00, 0x00, 0xf0, 0x61, 0xfb, 0x40, 0x1b, + 0xb0, 0x42, 0x08, 0xd2, 0x20, 0x00, 0xff, 0xf7, 0x09, 0xff, 0xe0, 0x69, + 0x00, 0x28, 0xf4, 0xd0, 0x00, 0x23, 0xe3, 0x62, 0x70, 0xbd, 0x00, 0x23, + 0x20, 0x00, 0xe3, 0x62, 0x20, 0x30, 0x03, 0x49, 0x01, 0xf0, 0xaf, 0xfe, + 0x01, 0x20, 0x40, 0x42, 0xf4, 0xe7, 0xc0, 0x46, 0x27, 0x93, 0x00, 0x00, + 0x70, 0xb5, 0x05, 0x00, 0xff, 0xf7, 0x87, 0xfe, 0x01, 0x24, 0x00, 0x28, + 0x10, 0xd0, 0x0a, 0x49, 0x28, 0x00, 0xff, 0xf7, 0xb3, 0xfe, 0x00, 0x22, + 0x08, 0x49, 0x28, 0x00, 0xff, 0xf7, 0xce, 0xff, 0x04, 0x00, 0x01, 0x28, + 0x06, 0xd1, 0x01, 0x21, 0x28, 0x00, 0x49, 0x42, 0xff, 0xf7, 0x6e, 0xfe, + 0x20, 0x00, 0x70, 0xbd, 0x00, 0x24, 0xfb, 0xe7, 0x52, 0x93, 0x00, 0x00, + 0x40, 0x9c, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x00, 0x05, 0x49, 0xff, 0xf7, + 0x99, 0xfe, 0x00, 0x22, 0xc8, 0x21, 0x20, 0x00, 0xff, 0xf7, 0xb4, 0xff, + 0x01, 0x38, 0x43, 0x42, 0x58, 0x41, 0x10, 0xbd, 0x20, 0x93, 0x00, 0x00, + 0x70, 0xb5, 0x05, 0x00, 0x0e, 0x00, 0x00, 0xf0, 0x13, 0xfb, 0x04, 0x00, + 0x00, 0xf0, 0x10, 0xfb, 0x00, 0x1b, 0xb0, 0x42, 0x08, 0xd2, 0x28, 0x00, + 0xff, 0xf7, 0xe2, 0xff, 0x01, 0x28, 0x04, 0xd0, 0x64, 0x20, 0x00, 0xf0, + 0x3b, 0xfb, 0xf1, 0xe7, 0x00, 0x20, 0x70, 0xbd, 0x70, 0xb5, 0x0d, 0x00, + 0x04, 0x00, 0x00, 0x21, 0x80, 0x68, 0x00, 0xf0, 0xff, 0xfc, 0x00, 0x2d, + 0x05, 0xd0, 0x20, 0x00, 0xff, 0xf7, 0xae, 0xff, 0x20, 0x00, 0xff, 0xf7, + 0x43, 0xfe, 0xe1, 0x23, 0x61, 0x68, 0x20, 0x68, 0x5b, 0x02, 0x99, 0x42, + 0x00, 0xd9, 0x19, 0x00, 0x03, 0x68, 0xdb, 0x69, 0x98, 0x47, 0x20, 0x00, + 0xff, 0xf7, 0x29, 0xfe, 0x05, 0x1e, 0x39, 0xd1, 0x01, 0x21, 0xe0, 0x68, + 0x00, 0xf0, 0xe4, 0xfc, 0x96, 0x20, 0x00, 0xf0, 0x13, 0xfb, 0x29, 0x00, + 0xe0, 0x68, 0x00, 0xf0, 0xdd, 0xfc, 0x02, 0x21, 0x20, 0x00, 0x49, 0x42, + 0xff, 0xf7, 0x12, 0xfe, 0x18, 0x49, 0x20, 0x00, 0xff, 0xf7, 0xb8, 0xff, + 0x00, 0x28, 0x29, 0xd0, 0xe1, 0x23, 0x62, 0x68, 0x5b, 0x02, 0x01, 0x20, + 0x9a, 0x42, 0x24, 0xd9, 0x13, 0x49, 0x20, 0x00, 0xff, 0xf7, 0x54, 0xfe, + 0x00, 0x22, 0xc8, 0x21, 0x20, 0x00, 0xff, 0xf7, 0x55, 0xff, 0x01, 0x28, + 0x18, 0xd1, 0x20, 0x68, 0x03, 0x68, 0x5b, 0x6a, 0x98, 0x47, 0x64, 0x20, + 0x00, 0xf0, 0xec, 0xfa, 0x20, 0x68, 0x61, 0x68, 0x03, 0x68, 0xdb, 0x69, + 0x98, 0x47, 0x07, 0x49, 0x20, 0x00, 0xff, 0xf7, 0x95, 0xff, 0x43, 0x1e, + 0x98, 0x41, 0x06, 0xe0, 0x03, 0x49, 0x20, 0x00, 0xff, 0xf7, 0x8e, 0xff, + 0x00, 0x28, 0xcf, 0xd1, 0x00, 0x20, 0x70, 0xbd, 0x10, 0x27, 0x00, 0x00, + 0x47, 0x93, 0x00, 0x00, 0x01, 0x23, 0xe1, 0x22, 0x13, 0xb5, 0x5b, 0x42, + 0x07, 0x4c, 0x01, 0x93, 0x24, 0x33, 0x00, 0x93, 0x52, 0x02, 0x04, 0x3b, + 0x05, 0x49, 0x20, 0x00, 0xff, 0xf7, 0xb0, 0xfd, 0x04, 0x4a, 0x05, 0x49, + 0x20, 0x00, 0x01, 0xf0, 0x1b, 0xff, 0x13, 0xbd, 0xd0, 0x1a, 0x00, 0x20, + 0xd0, 0x1d, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0x41, 0x27, 0x00, 0x00, + 0x07, 0xb5, 0x00, 0x21, 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, + 0x00, 0xf0, 0x44, 0xfd, 0x07, 0xbd, 0xc0, 0x46, 0x24, 0x1b, 0x00, 0x20, + 0x10, 0xb5, 0x04, 0x00, 0x8b, 0x68, 0x01, 0xf0, 0x87, 0xfe, 0x20, 0x00, + 0x10, 0xbd, 0x00, 0x00, 0x00, 0x23, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, + 0x08, 0xc0, 0x03, 0x49, 0x01, 0xf0, 0x66, 0xfd, 0x25, 0x74, 0x20, 0x00, + 0x70, 0xbd, 0xc0, 0x46, 0x27, 0x93, 0x00, 0x00, 0x30, 0xb5, 0x87, 0xb0, + 0x04, 0x00, 0x12, 0x49, 0x68, 0x46, 0x01, 0xf0, 0x59, 0xfd, 0x11, 0x4d, + 0x11, 0x49, 0x28, 0x00, 0xff, 0xf7, 0xca, 0xfd, 0x28, 0x00, 0x6a, 0x46, + 0x0f, 0x49, 0xff, 0xf7, 0xe5, 0xfe, 0x05, 0x1e, 0xf3, 0xd0, 0x0b, 0x22, + 0x69, 0x46, 0x03, 0xa8, 0xff, 0xf7, 0xd2, 0xff, 0x03, 0xa8, 0x01, 0xf0, + 0x9f, 0xfe, 0x03, 0xa9, 0x20, 0x1d, 0x01, 0xf0, 0x80, 0xfd, 0x03, 0xa8, + 0x01, 0xf0, 0xf4, 0xfc, 0x68, 0x46, 0x01, 0xf0, 0xf1, 0xfc, 0x28, 0x00, + 0x07, 0xb0, 0x30, 0xbd, 0x27, 0x93, 0x00, 0x00, 0xd0, 0x1a, 0x00, 0x20, + 0x6e, 0x93, 0x00, 0x00, 0x88, 0x13, 0x00, 0x00, 0x30, 0xb5, 0x00, 0x24, + 0x85, 0xb0, 0x01, 0x1d, 0x05, 0x00, 0x01, 0xa8, 0x01, 0xf0, 0x77, 0xfd, + 0x03, 0x9b, 0xa3, 0x42, 0x0c, 0xd0, 0x2c, 0x21, 0x01, 0xa8, 0x01, 0xf0, + 0x04, 0xfe, 0x01, 0x34, 0x43, 0x1c, 0x05, 0xd0, 0x42, 0x1c, 0x00, 0x21, + 0x01, 0xa8, 0x01, 0xf0, 0x53, 0xfe, 0xf2, 0xe7, 0x2c, 0x60, 0x01, 0xa8, + 0x01, 0xf0, 0xca, 0xfc, 0x05, 0xb0, 0x30, 0xbd, 0xf8, 0xb5, 0x06, 0x00, + 0x16, 0x4d, 0x28, 0x00, 0xff, 0xf7, 0x0a, 0xff, 0x33, 0x7c, 0x00, 0x2b, + 0x0b, 0xd0, 0x28, 0x00, 0xff, 0xf7, 0x74, 0xfd, 0x12, 0x49, 0x28, 0x00, + 0xff, 0xf7, 0x78, 0xfd, 0x00, 0x22, 0xc8, 0x21, 0x28, 0x00, 0xff, 0xf7, + 0x93, 0xfe, 0x00, 0xf0, 0xfb, 0xf9, 0x07, 0x00, 0x00, 0xf0, 0xf8, 0xf9, + 0x0c, 0x4b, 0xc0, 0x1b, 0x98, 0x42, 0x0e, 0xd8, 0x30, 0x00, 0xff, 0xf7, + 0x91, 0xff, 0x04, 0x00, 0x01, 0x28, 0x04, 0xd1, 0x30, 0x00, 0xff, 0xf7, + 0xbb, 0xff, 0x20, 0x00, 0xf8, 0xbd, 0x28, 0x00, 0xff, 0xf7, 0x94, 0xfd, + 0xea, 0xe7, 0x00, 0x20, 0xf8, 0xe7, 0xc0, 0x46, 0xd0, 0x1a, 0x00, 0x20, + 0x7c, 0x93, 0x00, 0x00, 0x0f, 0x27, 0x00, 0x00, 0x7f, 0xb5, 0x0e, 0x00, + 0x05, 0x00, 0x0f, 0x49, 0x01, 0xa8, 0x01, 0xf0, 0xd5, 0xfc, 0x0e, 0x4c, + 0x32, 0x68, 0x20, 0x00, 0x0d, 0x49, 0xff, 0xf7, 0x5f, 0xfd, 0x20, 0x00, + 0x01, 0xaa, 0x64, 0x21, 0xff, 0xf7, 0x60, 0xfe, 0x00, 0x24, 0xa0, 0x42, + 0x06, 0xd0, 0x28, 0x00, 0xff, 0xf7, 0x64, 0xff, 0x28, 0x00, 0xff, 0xf7, + 0x91, 0xff, 0x01, 0x34, 0x01, 0xa8, 0x01, 0xf0, 0x73, 0xfc, 0x20, 0x00, + 0x04, 0xb0, 0x70, 0xbd, 0x27, 0x93, 0x00, 0x00, 0xd0, 0x1a, 0x00, 0x20, + 0x5d, 0x93, 0x00, 0x00, 0x30, 0xb5, 0x0d, 0x00, 0x87, 0xb0, 0x12, 0x49, + 0x68, 0x46, 0x01, 0xf0, 0xad, 0xfc, 0x11, 0x4c, 0x2a, 0x68, 0x20, 0x00, + 0x10, 0x49, 0xff, 0xf7, 0x37, 0xfd, 0x20, 0x00, 0x6a, 0x46, 0x0f, 0x49, + 0xff, 0xf7, 0x38, 0xfe, 0x00, 0x24, 0x01, 0x28, 0x0b, 0xd1, 0x0b, 0x22, + 0x69, 0x46, 0x03, 0xa8, 0xff, 0xf7, 0x24, 0xff, 0x03, 0xa8, 0x01, 0xf0, + 0x1a, 0xfe, 0x04, 0x00, 0x03, 0xa8, 0x01, 0xf0, 0x49, 0xfc, 0x68, 0x46, + 0x01, 0xf0, 0x46, 0xfc, 0x60, 0x08, 0x07, 0xb0, 0x30, 0xbd, 0xc0, 0x46, + 0x27, 0x93, 0x00, 0x00, 0xd0, 0x1a, 0x00, 0x20, 0x9d, 0x93, 0x00, 0x00, + 0x88, 0x13, 0x00, 0x00, 0xf0, 0xb5, 0x0e, 0x00, 0x04, 0x00, 0x8f, 0xb0, + 0x3e, 0x49, 0x05, 0xa8, 0x15, 0x00, 0x03, 0x93, 0x01, 0xf0, 0x7a, 0xfc, + 0x31, 0x00, 0x0b, 0xa8, 0x01, 0xf0, 0xc5, 0xfc, 0x0b, 0xa9, 0x20, 0x00, + 0xff, 0xf7, 0xbe, 0xff, 0x00, 0x24, 0x07, 0x00, 0x0b, 0xa8, 0x01, 0xf0, + 0x23, 0xfc, 0xa7, 0x42, 0x62, 0xd0, 0x03, 0x9a, 0x34, 0x4f, 0x52, 0x00, + 0x00, 0x92, 0x6b, 0x00, 0x38, 0x00, 0x32, 0x68, 0x32, 0x49, 0xff, 0xf7, + 0xf1, 0xfc, 0xfa, 0x21, 0x05, 0xaa, 0x89, 0x00, 0x38, 0x00, 0xff, 0xf7, + 0xf1, 0xfd, 0x0a, 0x22, 0x05, 0xa9, 0x08, 0xa8, 0xff, 0xf7, 0xe0, 0xfe, + 0x2c, 0x21, 0x08, 0xa8, 0x01, 0xf0, 0x35, 0xfd, 0x08, 0xa9, 0x42, 0x1c, + 0x05, 0x00, 0x0b, 0xa8, 0xff, 0xf7, 0xd6, 0xfe, 0x0b, 0xa9, 0x08, 0xa8, + 0x01, 0xf0, 0xa1, 0xfc, 0x0b, 0xa8, 0x01, 0xf0, 0xfb, 0xfb, 0x2c, 0x21, + 0x08, 0xa8, 0x01, 0xf0, 0x24, 0xfd, 0x22, 0x00, 0x03, 0x00, 0x2d, 0x18, + 0x08, 0xa9, 0x0b, 0xa8, 0x01, 0xf0, 0x50, 0xfd, 0x0b, 0xa8, 0x01, 0xf0, + 0xba, 0xfd, 0xc4, 0x0f, 0x24, 0x18, 0x64, 0x10, 0x0d, 0x35, 0x63, 0x00, + 0x5b, 0x19, 0x14, 0x9f, 0x03, 0x93, 0x03, 0x9b, 0x9d, 0x42, 0x1d, 0xd0, + 0x29, 0x00, 0x05, 0xa8, 0x01, 0xf0, 0xee, 0xfc, 0x06, 0x78, 0x69, 0x1c, + 0x05, 0xa8, 0x01, 0xf0, 0xe9, 0xfc, 0x33, 0x00, 0x30, 0x3b, 0x02, 0x78, + 0xdb, 0xb2, 0x39, 0x2e, 0x01, 0xd9, 0x37, 0x3e, 0xf3, 0xb2, 0x16, 0x00, + 0x30, 0x3e, 0xf6, 0xb2, 0x39, 0x2a, 0x01, 0xd9, 0x37, 0x3a, 0xd6, 0xb2, + 0x1b, 0x01, 0x33, 0x43, 0x3b, 0x70, 0x02, 0x35, 0x01, 0x37, 0xde, 0xe7, + 0x0b, 0xa8, 0x01, 0xf0, 0xc1, 0xfb, 0x08, 0xa8, 0x01, 0xf0, 0xbe, 0xfb, + 0x05, 0xa8, 0x01, 0xf0, 0xbb, 0xfb, 0x20, 0x00, 0x0f, 0xb0, 0xf0, 0xbd, + 0x27, 0x93, 0x00, 0x00, 0xd0, 0x1a, 0x00, 0x20, 0x86, 0x93, 0x00, 0x00, + 0x07, 0xb5, 0x00, 0x21, 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, + 0x00, 0xf0, 0xbe, 0xfb, 0x07, 0xbd, 0xc0, 0x46, 0x2c, 0x1b, 0x00, 0x20, + 0x07, 0xb5, 0x00, 0x21, 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, + 0x00, 0xf0, 0xb2, 0xfb, 0x07, 0xbd, 0xc0, 0x46, 0x34, 0x1b, 0x00, 0x20, + 0x10, 0xb5, 0x04, 0x00, 0x04, 0x4b, 0x54, 0x22, 0x08, 0x33, 0x08, 0xc0, + 0x00, 0x21, 0x03, 0xf0, 0x47, 0xfd, 0x20, 0x00, 0x10, 0xbd, 0xc0, 0x46, + 0xb0, 0x93, 0x00, 0x00, 0x10, 0xb5, 0x0c, 0x24, 0x4c, 0x43, 0x04, 0x19, + 0x60, 0x68, 0x00, 0x28, 0x05, 0xd0, 0x03, 0xf0, 0x01, 0xfd, 0x00, 0x23, + 0xa3, 0x60, 0x63, 0x60, 0xe3, 0x60, 0x10, 0xbd, 0x70, 0xb5, 0x05, 0x00, + 0x00, 0x24, 0x06, 0x4b, 0x08, 0x33, 0x03, 0x60, 0x21, 0x00, 0x28, 0x00, + 0x01, 0x34, 0xff, 0xf7, 0xe7, 0xff, 0x07, 0x2c, 0xf8, 0xd1, 0x28, 0x00, + 0x70, 0xbd, 0xc0, 0x46, 0xb0, 0x93, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x00, + 0xff, 0xf7, 0xea, 0xff, 0x20, 0x00, 0x01, 0xf0, 0x3b, 0xfd, 0x20, 0x00, + 0x10, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x05, 0x4c, 0x20, 0x00, 0xff, 0xf7, + 0xc3, 0xff, 0x04, 0x4a, 0x04, 0x49, 0x20, 0x00, 0x01, 0xf0, 0x32, 0xfd, + 0x10, 0xbd, 0xc0, 0x46, 0x3c, 0x1b, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, + 0x81, 0x2f, 0x00, 0x00, 0x10, 0xb5, 0x02, 0x48, 0x01, 0xf0, 0x65, 0xfa, + 0x10, 0xbd, 0xc0, 0x46, 0x94, 0x1b, 0x00, 0x20, 0x10, 0xb5, 0x02, 0x48, + 0x01, 0xf0, 0x5d, 0xfa, 0x10, 0xbd, 0xc0, 0x46, 0xd0, 0x1d, 0x00, 0x20, + 0x73, 0xb5, 0x17, 0x49, 0x17, 0x48, 0x00, 0xf0, 0x1f, 0xfc, 0x17, 0x49, + 0x17, 0x48, 0x00, 0xf0, 0x1b, 0xfc, 0x17, 0x49, 0x17, 0x48, 0x00, 0xf0, + 0x17, 0xfc, 0x17, 0x49, 0x17, 0x48, 0x00, 0xf0, 0x13, 0xfc, 0x17, 0x4c, + 0x17, 0x49, 0x20, 0x00, 0x00, 0xf0, 0x0e, 0xfc, 0x16, 0x4e, 0x17, 0x49, + 0x30, 0x00, 0x00, 0xf0, 0x09, 0xfc, 0x01, 0x25, 0x03, 0x23, 0x31, 0x00, + 0x01, 0x95, 0x00, 0x93, 0x0d, 0x22, 0x0b, 0x33, 0x12, 0x48, 0x01, 0xf0, + 0xc9, 0xf9, 0x00, 0x23, 0x00, 0x95, 0x01, 0x93, 0x1b, 0x22, 0x1a, 0x33, + 0x21, 0x00, 0x0f, 0x48, 0x01, 0xf0, 0xc0, 0xf9, 0x73, 0xbd, 0xc0, 0x46, + 0x00, 0x08, 0x00, 0x42, 0x0c, 0x20, 0x00, 0x20, 0x00, 0x0c, 0x00, 0x42, + 0x10, 0x20, 0x00, 0x20, 0x00, 0x10, 0x00, 0x42, 0x14, 0x20, 0x00, 0x20, + 0x00, 0x14, 0x00, 0x42, 0x18, 0x20, 0x00, 0x20, 0x1c, 0x20, 0x00, 0x20, + 0x00, 0x18, 0x00, 0x42, 0x20, 0x20, 0x00, 0x20, 0x00, 0x1c, 0x00, 0x42, + 0x94, 0x1b, 0x00, 0x20, 0xd0, 0x1d, 0x00, 0x20, 0xfe, 0xe7, 0x00, 0x00, + 0x03, 0x4b, 0x10, 0xb5, 0x1b, 0x68, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, + 0x10, 0xbd, 0xc0, 0x46, 0x24, 0x20, 0x00, 0x20, 0x70, 0xb5, 0x0f, 0x49, + 0x0f, 0x4c, 0xa1, 0x42, 0x04, 0xd1, 0x00, 0xf0, 0x89, 0xf8, 0xff, 0xf7, + 0x27, 0xf8, 0xfe, 0xe7, 0x0c, 0x4d, 0x00, 0x23, 0x8d, 0x42, 0xf6, 0xd0, + 0xca, 0x18, 0xe8, 0x18, 0xa2, 0x42, 0x05, 0xd3, 0x09, 0x4b, 0x82, 0x42, + 0xef, 0xd0, 0x09, 0x49, 0x00, 0x22, 0x04, 0xe0, 0x00, 0x68, 0x04, 0x33, + 0x10, 0x60, 0xf1, 0xe7, 0x04, 0xc3, 0x8b, 0x42, 0xfc, 0xd3, 0xe4, 0xe7, + 0x00, 0x00, 0x00, 0x20, 0x30, 0x02, 0x00, 0x20, 0xfc, 0x9a, 0x00, 0x00, + 0x30, 0x02, 0x00, 0x20, 0x5c, 0x26, 0x00, 0x20, 0x10, 0xb5, 0x00, 0xf0, + 0x60, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x00, 0xf0, 0x51, 0xf8, 0x10, 0xbd, + 0x01, 0x4b, 0x18, 0x68, 0x70, 0x47, 0xc0, 0x46, 0x28, 0x20, 0x00, 0x20, + 0xf7, 0xb5, 0x13, 0x48, 0x01, 0x22, 0x84, 0x46, 0x12, 0x49, 0x13, 0x4c, + 0x8e, 0x68, 0x63, 0x68, 0x05, 0x68, 0x9b, 0x0e, 0x13, 0x40, 0x01, 0x92, + 0x88, 0x68, 0x62, 0x68, 0x01, 0x9f, 0x92, 0x0e, 0x3a, 0x40, 0x67, 0x46, + 0x3f, 0x68, 0x93, 0x42, 0x0e, 0xd1, 0xbd, 0x42, 0x0c, 0xd1, 0x86, 0x42, + 0x0a, 0xd3, 0x5b, 0x19, 0xfa, 0x25, 0x48, 0x68, 0xad, 0x00, 0x86, 0x1b, + 0x07, 0x48, 0x6b, 0x43, 0x70, 0x43, 0x00, 0x0d, 0xc0, 0x18, 0xfe, 0xbd, + 0x3d, 0x00, 0x13, 0x00, 0x06, 0x00, 0xe3, 0xe7, 0x28, 0x20, 0x00, 0x20, + 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, 0x55, 0x55, 0x00, 0x00, + 0x70, 0xb5, 0x04, 0x1e, 0x10, 0xd0, 0xff, 0xf7, 0xcb, 0xff, 0x05, 0x00, + 0x00, 0xf0, 0x1c, 0xf8, 0xff, 0xf7, 0xc6, 0xff, 0x05, 0x4b, 0x40, 0x1b, + 0x98, 0x42, 0xf7, 0xd9, 0xfa, 0x23, 0x01, 0x3c, 0x9b, 0x00, 0xed, 0x18, + 0x00, 0x2c, 0xf3, 0xd1, 0x70, 0xbd, 0xc0, 0x46, 0xe7, 0x03, 0x00, 0x00, + 0x70, 0x47, 0x00, 0x00, 0x10, 0xb5, 0x03, 0x4a, 0x13, 0x68, 0x01, 0x33, + 0x13, 0x60, 0x00, 0xf0, 0x07, 0xfb, 0x10, 0xbd, 0x28, 0x20, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, 0x1e, 0x22, 0x70, 0xb5, + 0x46, 0x48, 0x47, 0x49, 0x43, 0x68, 0x93, 0x43, 0x1c, 0x3a, 0x13, 0x43, + 0x43, 0x60, 0x08, 0x23, 0x8c, 0x69, 0x23, 0x43, 0x8b, 0x61, 0x43, 0x4c, + 0x43, 0x4b, 0x9c, 0x82, 0x9c, 0x8a, 0x14, 0x43, 0x9c, 0x82, 0xdc, 0x68, + 0x14, 0x42, 0xfc, 0xd0, 0x01, 0x24, 0x40, 0x4a, 0x14, 0x70, 0x15, 0x78, + 0x25, 0x42, 0x03, 0xd0, 0x55, 0x78, 0x6d, 0xb2, 0x00, 0x2d, 0xf8, 0xdb, + 0x01, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, + 0x39, 0x4c, 0x54, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, + 0x82, 0x24, 0xe4, 0x01, 0x54, 0x80, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x02, 0x24, 0x9c, 0x84, 0x0e, 0x34, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x31, 0x4c, 0xdc, 0x62, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x9d, 0x8c, 0x2e, 0x4c, 0x2c, 0x43, 0x9c, 0x84, 0x10, 0x24, + 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x02, 0x24, 0x9d, 0x8c, 0x80, 0x26, + 0x2c, 0x43, 0x9c, 0x84, 0x40, 0x24, 0xdd, 0x68, 0x35, 0x42, 0xfc, 0xd0, + 0xdd, 0x68, 0x25, 0x42, 0xf9, 0xd0, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x00, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x21, 0x4c, 0x54, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x1c, 0x6a, 0x1e, 0x4d, 0x2c, 0x40, 0x80, 0x25, 0x1c, 0x62, + 0x1c, 0x6a, 0xac, 0x43, 0x1c, 0x62, 0x03, 0x23, 0x93, 0x60, 0x1b, 0x4b, + 0x53, 0x60, 0x53, 0x78, 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x00, 0x23, + 0xff, 0x24, 0x0b, 0x72, 0x17, 0x4a, 0x4b, 0x72, 0x8b, 0x72, 0xcb, 0x72, + 0x16, 0x4b, 0x1a, 0x60, 0x16, 0x4b, 0x17, 0x4a, 0x1b, 0x68, 0x11, 0x68, + 0x9a, 0x06, 0x5b, 0x01, 0xc9, 0x0e, 0x23, 0x40, 0x52, 0x0f, 0x12, 0x02, + 0x0b, 0x43, 0x13, 0x43, 0x12, 0x4a, 0x13, 0x85, 0x80, 0x23, 0x42, 0x68, + 0x13, 0x43, 0x43, 0x60, 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x00, 0x04, 0x00, 0x40, 0x0c, 0x06, 0x00, 0x00, 0x00, 0x08, 0x00, 0x40, + 0x00, 0x0c, 0x00, 0x40, 0x01, 0x05, 0x01, 0x00, 0xb9, 0x05, 0xff, 0x7d, + 0x04, 0x0a, 0x00, 0x00, 0x00, 0x07, 0x03, 0x00, 0xff, 0xfc, 0xff, 0xff, + 0x03, 0x06, 0x01, 0x00, 0x00, 0x6c, 0xdc, 0x02, 0x10, 0x00, 0x00, 0x20, + 0x24, 0x60, 0x80, 0x00, 0x20, 0x60, 0x80, 0x00, 0x00, 0x40, 0x00, 0x42, + 0xfa, 0x21, 0x31, 0x4b, 0x10, 0xb5, 0x18, 0x68, 0x89, 0x00, 0x01, 0xf0, + 0x8d, 0xfb, 0x2f, 0x4b, 0x01, 0x38, 0x98, 0x42, 0x56, 0xd8, 0x2e, 0x49, + 0x2e, 0x4a, 0x48, 0x60, 0xc0, 0x20, 0x13, 0x6a, 0x00, 0x06, 0x1b, 0x02, + 0x1b, 0x0a, 0x03, 0x43, 0x13, 0x62, 0x00, 0x24, 0x07, 0x23, 0x8c, 0x60, + 0x0b, 0x60, 0x80, 0x21, 0x13, 0x6a, 0x09, 0x06, 0x1b, 0x02, 0x1b, 0x0a, + 0x0b, 0x43, 0x13, 0x62, 0xfc, 0x22, 0x25, 0x4b, 0x19, 0x6a, 0x0a, 0x43, + 0x1a, 0x62, 0xfc, 0x22, 0x19, 0x6a, 0x92, 0x01, 0x0a, 0x43, 0x1a, 0x62, + 0xa0, 0x22, 0x19, 0x6a, 0xd2, 0x02, 0x0a, 0x43, 0x1a, 0x62, 0x20, 0x00, + 0x00, 0x21, 0x01, 0x34, 0x00, 0xf0, 0x76, 0xf8, 0x0f, 0x2c, 0xf8, 0xd1, + 0x1b, 0x4b, 0x1c, 0x00, 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, + 0x19, 0x4a, 0x5a, 0x80, 0x19, 0x4b, 0x1a, 0x00, 0x59, 0x7e, 0xc9, 0x09, + 0x01, 0x29, 0xfb, 0xd0, 0xe4, 0x21, 0xc9, 0x00, 0x99, 0x80, 0x3f, 0x21, + 0xd9, 0x70, 0x53, 0x7e, 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0xc0, 0x23, + 0x00, 0x20, 0x5b, 0x01, 0x13, 0x61, 0x90, 0x70, 0x00, 0xf0, 0x24, 0xf8, + 0x63, 0x78, 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x0d, 0x4b, 0x0e, 0x4a, + 0x63, 0x80, 0xd3, 0x79, 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0x41, 0x23, + 0x53, 0x70, 0x10, 0xbd, 0xfe, 0xe7, 0xc0, 0x46, 0x10, 0x00, 0x00, 0x20, + 0xff, 0xff, 0xff, 0x00, 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, + 0x00, 0x04, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, 0x1e, 0x40, 0x00, 0x00, + 0x00, 0x40, 0x00, 0x42, 0x21, 0x40, 0x00, 0x00, 0x00, 0x48, 0x00, 0x42, + 0x16, 0x4a, 0x00, 0xb5, 0x13, 0x00, 0x51, 0x7e, 0xc9, 0x09, 0x01, 0x29, + 0xfb, 0xd0, 0x01, 0x38, 0x04, 0x28, 0x16, 0xd8, 0x19, 0x69, 0x12, 0x4a, + 0x0a, 0x40, 0x0f, 0x21, 0x1a, 0x61, 0x5a, 0x78, 0x8a, 0x43, 0x01, 0xf0, + 0xff, 0xfa, 0x03, 0x08, 0x06, 0x0b, 0x03, 0x00, 0x11, 0x00, 0x01, 0x22, + 0x0a, 0x43, 0x5a, 0x70, 0x00, 0xbd, 0x11, 0x00, 0x03, 0x22, 0xf9, 0xe7, + 0x11, 0x00, 0x02, 0x22, 0xf6, 0xe7, 0xf0, 0x23, 0x11, 0x69, 0x1b, 0x05, + 0x0b, 0x43, 0x0f, 0x21, 0x13, 0x61, 0x53, 0x78, 0x8b, 0x43, 0x19, 0x00, + 0x02, 0x23, 0x0b, 0x43, 0x53, 0x70, 0xeb, 0xe7, 0x00, 0x40, 0x00, 0x42, + 0xff, 0xff, 0xff, 0xf0, 0x18, 0x23, 0x30, 0xb5, 0x1d, 0x00, 0x04, 0x00, + 0x45, 0x43, 0x08, 0x20, 0x20, 0x4a, 0x55, 0x19, 0x28, 0x56, 0x01, 0x30, + 0x14, 0xd0, 0x03, 0x29, 0x12, 0xd8, 0x08, 0x00, 0x63, 0x43, 0xd1, 0x56, + 0xd3, 0x18, 0x01, 0xf0, 0xcd, 0xfa, 0x02, 0x28, 0x0e, 0x1b, 0x58, 0x68, + 0xcb, 0x01, 0x02, 0x21, 0x18, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, + 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x30, 0xbd, 0x58, 0x68, + 0xcb, 0x01, 0x06, 0x21, 0x12, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, + 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x9a, 0x61, 0xf1, 0xe7, + 0x58, 0x68, 0xcb, 0x01, 0x06, 0x21, 0x0c, 0x4a, 0x9b, 0x18, 0x1a, 0x18, + 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x5a, 0x61, + 0xe4, 0xe7, 0x58, 0x68, 0xcb, 0x01, 0x02, 0x21, 0x05, 0x4a, 0x9b, 0x18, + 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x9a, 0x60, + 0xd8, 0xe7, 0xc0, 0x46, 0xc0, 0x93, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x18, 0x23, 0xf0, 0xb5, 0x08, 0x24, 0x58, 0x43, 0x11, 0x4a, 0x13, 0x18, + 0x1c, 0x57, 0x01, 0x34, 0x1b, 0xd0, 0x01, 0x26, 0x35, 0x00, 0x5f, 0x68, + 0x83, 0x56, 0xbd, 0x40, 0x0d, 0x4a, 0xdb, 0x01, 0x9a, 0x18, 0x90, 0x68, + 0x05, 0x42, 0x0b, 0xd1, 0x0c, 0x00, 0x60, 0x1e, 0x84, 0x41, 0xd2, 0x19, + 0x40, 0x32, 0x10, 0x78, 0x34, 0x40, 0x03, 0x36, 0xa4, 0x00, 0xb0, 0x43, + 0x20, 0x43, 0x10, 0x70, 0x04, 0x4a, 0x9b, 0x18, 0x00, 0x29, 0x01, 0xd1, + 0x5d, 0x61, 0xf0, 0xbd, 0x9d, 0x61, 0xfc, 0xe7, 0xc0, 0x93, 0x00, 0x00, + 0x00, 0x44, 0x00, 0x41, 0x18, 0x23, 0x10, 0xb5, 0x08, 0x24, 0x43, 0x43, + 0x07, 0x49, 0x00, 0x20, 0xca, 0x18, 0x14, 0x57, 0x01, 0x34, 0x08, 0xd0, + 0x5b, 0x56, 0x05, 0x49, 0xdb, 0x01, 0x5b, 0x18, 0x18, 0x6a, 0x53, 0x68, + 0xd8, 0x40, 0x01, 0x23, 0x18, 0x40, 0x10, 0xbd, 0xc0, 0x93, 0x00, 0x00, + 0x00, 0x44, 0x00, 0x41, 0x18, 0x22, 0x42, 0x43, 0xf8, 0xb5, 0x2c, 0x4e, + 0x03, 0x00, 0xb2, 0x18, 0x12, 0x7a, 0x52, 0xb2, 0x14, 0x00, 0x01, 0x32, + 0x0e, 0xd0, 0x48, 0x1c, 0x00, 0x24, 0x0c, 0x28, 0x0a, 0xd8, 0x01, 0xf0, + 0x3f, 0xfa, 0x07, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x0b, + 0x0b, 0x0b, 0x0b, 0x00, 0x01, 0x24, 0x64, 0x42, 0x20, 0x00, 0xf8, 0xbd, + 0x09, 0x29, 0x05, 0xd1, 0x00, 0x21, 0x18, 0x00, 0xff, 0xf7, 0x4e, 0xff, + 0x00, 0x24, 0xf5, 0xe7, 0x0a, 0x29, 0x01, 0xd1, 0x08, 0x39, 0xf6, 0xe7, + 0x00, 0x24, 0x0b, 0x29, 0xee, 0xd1, 0x0a, 0x39, 0x18, 0x00, 0xff, 0xf7, + 0x41, 0xff, 0xe9, 0xe7, 0x18, 0x22, 0x53, 0x43, 0xf2, 0x18, 0x55, 0x68, + 0x01, 0x20, 0x2c, 0x00, 0xf3, 0x56, 0x13, 0x4a, 0xdb, 0x01, 0x6e, 0x08, + 0x9b, 0x18, 0xc9, 0xb2, 0x04, 0x40, 0x9e, 0x19, 0x00, 0x2c, 0x0d, 0xd0, + 0x0f, 0x24, 0x30, 0x36, 0x32, 0x78, 0x09, 0x01, 0x22, 0x40, 0x11, 0x43, + 0xc9, 0xb2, 0x5b, 0x19, 0x31, 0x70, 0x40, 0x33, 0x1a, 0x78, 0x10, 0x43, + 0x18, 0x70, 0xd3, 0xe7, 0x32, 0x00, 0x0f, 0x27, 0x30, 0x32, 0x16, 0x78, + 0x5b, 0x19, 0xbe, 0x43, 0x31, 0x43, 0x11, 0x70, 0x40, 0x33, 0x1a, 0x78, + 0x10, 0x43, 0x18, 0x70, 0xbe, 0xe7, 0xc0, 0x46, 0xc0, 0x93, 0x00, 0x00, + 0x00, 0x44, 0x00, 0x41, 0xf7, 0xb5, 0xc3, 0x1d, 0x01, 0x93, 0x00, 0x23, + 0x06, 0x00, 0x0d, 0x00, 0x04, 0x1d, 0x00, 0x93, 0x21, 0x78, 0x0a, 0x22, + 0x28, 0x00, 0x00, 0xf0, 0x93, 0xf8, 0x2e, 0x21, 0x07, 0x00, 0x28, 0x00, + 0x00, 0xf0, 0x47, 0xf8, 0x00, 0x9b, 0x3f, 0x18, 0xdb, 0x19, 0x00, 0x93, + 0x01, 0x9b, 0x01, 0x34, 0x9c, 0x42, 0xed, 0xd1, 0xf1, 0x79, 0x28, 0x00, + 0x0a, 0x22, 0x00, 0xf0, 0x81, 0xf8, 0x00, 0x9b, 0x18, 0x18, 0xfe, 0xbd, + 0x30, 0xb5, 0x03, 0xac, 0x25, 0x78, 0x04, 0x4c, 0xc5, 0x71, 0x08, 0x34, + 0x04, 0x60, 0x01, 0x71, 0x42, 0x71, 0x83, 0x71, 0x30, 0xbd, 0xc0, 0x46, + 0x20, 0x97, 0x00, 0x00, 0xf7, 0xb5, 0x06, 0x00, 0x0d, 0x00, 0x0c, 0x00, + 0x8b, 0x18, 0x01, 0x93, 0x01, 0x9b, 0x67, 0x1b, 0x9c, 0x42, 0x07, 0xd0, + 0x33, 0x68, 0x21, 0x78, 0x1b, 0x68, 0x30, 0x00, 0x98, 0x47, 0x01, 0x34, + 0x00, 0x28, 0xf3, 0xd1, 0x38, 0x00, 0xfe, 0xbd, 0x70, 0xb5, 0x04, 0x00, + 0x08, 0x00, 0x0d, 0x00, 0x03, 0xf0, 0xc4, 0xfe, 0x23, 0x68, 0x02, 0x00, + 0x29, 0x00, 0x5b, 0x68, 0x20, 0x00, 0x98, 0x47, 0x70, 0xbd, 0x10, 0xb5, + 0x0b, 0x1e, 0x02, 0xd0, 0xff, 0xf7, 0xee, 0xff, 0x03, 0x00, 0x18, 0x00, + 0x10, 0xbd, 0x10, 0xb5, 0x03, 0x68, 0x1b, 0x68, 0x98, 0x47, 0x10, 0xbd, + 0x10, 0xb5, 0x02, 0x49, 0xff, 0xf7, 0xe2, 0xff, 0x10, 0xbd, 0xc0, 0x46, + 0x25, 0x93, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x00, 0xff, 0xf7, 0xe7, 0xff, + 0x05, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xf0, 0xff, 0x40, 0x19, 0x70, 0xbd, + 0xf0, 0xb5, 0x8b, 0xb0, 0x6b, 0x46, 0x15, 0x00, 0x00, 0x22, 0x05, 0x33, + 0x06, 0x00, 0xda, 0x77, 0x08, 0x00, 0x01, 0x2d, 0x00, 0xd8, 0x0a, 0x25, + 0x09, 0xac, 0x29, 0x00, 0x01, 0xf0, 0x00, 0xfa, 0xca, 0xb2, 0x13, 0x00, + 0x37, 0x33, 0x07, 0x00, 0xdb, 0xb2, 0x09, 0x29, 0x02, 0xd8, 0x13, 0x00, + 0x30, 0x33, 0xdb, 0xb2, 0x01, 0x3c, 0x23, 0x70, 0x00, 0x2f, 0xee, 0xd1, + 0x21, 0x00, 0x30, 0x00, 0xff, 0xf7, 0xbf, 0xff, 0x0b, 0xb0, 0xf0, 0xbd, + 0x10, 0xb5, 0x00, 0x2a, 0x04, 0xd1, 0x03, 0x68, 0xc9, 0xb2, 0x1b, 0x68, + 0x98, 0x47, 0x10, 0xbd, 0xd2, 0xb2, 0xff, 0xf7, 0xd1, 0xff, 0xfa, 0xe7, + 0x10, 0xb5, 0xff, 0xf7, 0xf1, 0xff, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, + 0xff, 0xf7, 0xfe, 0xfc, 0x01, 0x4b, 0x1c, 0x60, 0x10, 0xbd, 0xc0, 0x46, + 0x14, 0x00, 0x00, 0x20, 0x01, 0x22, 0x02, 0x4b, 0x52, 0x42, 0x1a, 0x60, + 0x70, 0x47, 0xc0, 0x46, 0x14, 0x00, 0x00, 0x20, 0x16, 0x4a, 0x10, 0xb5, + 0x13, 0x68, 0x59, 0x1c, 0x26, 0xd0, 0x01, 0x3b, 0x13, 0x60, 0x00, 0x2b, + 0x22, 0xd1, 0x72, 0xb6, 0x12, 0x4b, 0x13, 0x4a, 0x04, 0x33, 0x93, 0x42, + 0x13, 0xd9, 0x12, 0x4a, 0x01, 0x21, 0x10, 0x00, 0x14, 0x7d, 0x0c, 0x42, + 0xfc, 0xd0, 0x20, 0x21, 0x14, 0x8b, 0xff, 0x31, 0x9b, 0x08, 0x5b, 0x00, + 0x21, 0x43, 0x11, 0x83, 0xd3, 0x61, 0x0c, 0x4b, 0x13, 0x80, 0x01, 0x23, + 0x02, 0x7d, 0x1a, 0x42, 0xfc, 0xd0, 0xbf, 0xf3, 0x4f, 0x8f, 0x09, 0x4b, + 0x09, 0x4a, 0xda, 0x60, 0xbf, 0xf3, 0x4f, 0x8f, 0xc0, 0x46, 0xfd, 0xe7, + 0x10, 0xbd, 0xc0, 0x46, 0x14, 0x00, 0x00, 0x20, 0x00, 0x20, 0x00, 0x00, + 0x03, 0x02, 0x00, 0x00, 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, + 0x00, 0xed, 0x00, 0xe0, 0x04, 0x00, 0xfa, 0x05, 0x01, 0x60, 0x70, 0x47, + 0x94, 0x46, 0xf0, 0xb5, 0x9e, 0x1e, 0x72, 0x1e, 0x96, 0x41, 0x62, 0x46, + 0x05, 0x68, 0x92, 0x07, 0x2f, 0x68, 0x36, 0x06, 0x3a, 0x43, 0x32, 0x43, + 0x2a, 0x60, 0x07, 0x25, 0x05, 0xac, 0x24, 0x78, 0x00, 0x68, 0xa4, 0x01, + 0x29, 0x40, 0x21, 0x43, 0x42, 0x68, 0x00, 0x24, 0x02, 0x2b, 0x00, 0xd0, + 0x5c, 0x03, 0x11, 0x43, 0x21, 0x43, 0x41, 0x60, 0xf0, 0xbd, 0x30, 0xb5, + 0xc0, 0x25, 0x03, 0x68, 0xad, 0x03, 0x1c, 0x68, 0x12, 0x05, 0x2a, 0x40, + 0x22, 0x43, 0xc0, 0x24, 0x09, 0x04, 0xa4, 0x02, 0x21, 0x40, 0x11, 0x43, + 0x19, 0x60, 0x03, 0x68, 0x5a, 0x68, 0x14, 0x43, 0x5c, 0x60, 0x30, 0xbd, + 0x01, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, 0x03, 0x68, + 0x1a, 0x68, 0xd2, 0x07, 0xfc, 0xd4, 0xda, 0x69, 0xd2, 0x07, 0xf9, 0xd4, + 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, + 0x02, 0x68, 0xd3, 0x69, 0x9b, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, + 0x1a, 0x7e, 0xd2, 0x07, 0x02, 0xd4, 0x1a, 0x7e, 0x92, 0x07, 0xfc, 0xd5, + 0x70, 0x47, 0x00, 0x22, 0x03, 0x68, 0x5a, 0x83, 0x70, 0x47, 0x03, 0x68, + 0x18, 0x7e, 0x40, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, + 0xc0, 0x09, 0x70, 0x47, 0x80, 0x23, 0x02, 0x68, 0x5b, 0x42, 0x11, 0x7e, + 0x0b, 0x43, 0x13, 0x76, 0x70, 0x47, 0x03, 0x68, 0x58, 0x8b, 0x80, 0x07, + 0xc0, 0x0f, 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, 0x51, 0x8b, 0x0b, 0x43, + 0x53, 0x83, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x07, 0xc0, 0x0f, + 0x70, 0x47, 0x03, 0x68, 0x18, 0x8d, 0xc0, 0xb2, 0x70, 0x47, 0x03, 0x68, + 0x1a, 0x7e, 0xd2, 0x07, 0xfc, 0xd5, 0x89, 0xb2, 0x01, 0x20, 0x19, 0x85, + 0x70, 0x47, 0x01, 0x22, 0x03, 0x68, 0x9a, 0x75, 0x70, 0x47, 0x01, 0x22, + 0x03, 0x68, 0x1a, 0x75, 0x70, 0x47, 0x00, 0x00, 0x03, 0x68, 0x21, 0x4a, + 0x30, 0xb5, 0x93, 0x42, 0x2f, 0xd0, 0x20, 0x4a, 0x93, 0x42, 0x2f, 0xd0, + 0x1f, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x2f, 0xd0, + 0x1e, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1e, 0x4a, 0x93, 0x42, 0x1f, 0xd1, + 0x0e, 0x23, 0x19, 0x22, 0x01, 0x21, 0x03, 0x25, 0x99, 0x40, 0x1b, 0x48, + 0xc0, 0x24, 0x01, 0x60, 0x99, 0x08, 0x2b, 0x40, 0xab, 0x40, 0xfc, 0x35, + 0x9d, 0x40, 0x89, 0x00, 0x09, 0x18, 0xa4, 0x00, 0x08, 0x59, 0xa8, 0x43, + 0xc0, 0x25, 0x9d, 0x40, 0x2b, 0x00, 0x03, 0x43, 0x0b, 0x51, 0x80, 0x23, + 0xdb, 0x01, 0x1a, 0x43, 0x11, 0x4b, 0x5a, 0x80, 0x5a, 0x78, 0x52, 0xb2, + 0x00, 0x2a, 0xfb, 0xdb, 0x30, 0xbd, 0x09, 0x23, 0x14, 0x22, 0xdd, 0xe7, + 0x0a, 0x23, 0x15, 0x22, 0xda, 0xe7, 0x0b, 0x23, 0x16, 0x22, 0xd7, 0xe7, + 0x0c, 0x23, 0x17, 0x22, 0xd4, 0xe7, 0x0d, 0x23, 0x18, 0x22, 0xd1, 0xe7, + 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, 0x00, 0x10, 0x00, 0x42, + 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, 0x00, 0x1c, 0x00, 0x42, + 0x00, 0xe1, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x40, 0xf8, 0xb5, 0x04, 0x00, + 0x0f, 0x00, 0x16, 0x00, 0x1d, 0x00, 0xff, 0xf7, 0xa5, 0xff, 0x20, 0x00, + 0xff, 0xf7, 0x4a, 0xff, 0x1c, 0x21, 0xbb, 0x00, 0x0b, 0x40, 0x71, 0x07, + 0x22, 0x68, 0x09, 0x0c, 0x0b, 0x43, 0x13, 0x60, 0x84, 0x23, 0x22, 0x68, + 0x93, 0x75, 0x01, 0x2f, 0x1a, 0xd1, 0x10, 0x21, 0x01, 0x2e, 0x00, 0xd0, + 0x08, 0x39, 0x0c, 0x4b, 0x69, 0x43, 0x18, 0x68, 0xc0, 0x00, 0x01, 0xf0, + 0x09, 0xf8, 0x07, 0x22, 0x21, 0x68, 0x02, 0x40, 0x8b, 0x89, 0x52, 0x03, + 0xdb, 0x04, 0xdb, 0x0c, 0x13, 0x43, 0x8b, 0x81, 0x22, 0x68, 0x03, 0x04, + 0x90, 0x89, 0xdb, 0x0c, 0x40, 0x0b, 0x40, 0x03, 0x18, 0x43, 0x90, 0x81, + 0xf8, 0xbd, 0xc0, 0x46, 0x10, 0x00, 0x00, 0x20, 0x00, 0x20, 0x70, 0x47, + 0x70, 0xb5, 0x0f, 0x26, 0xcb, 0x1d, 0x01, 0x39, 0x02, 0x00, 0x32, 0x40, + 0xd5, 0xb2, 0x2c, 0x00, 0x00, 0x09, 0x30, 0x34, 0x09, 0x2a, 0x00, 0xdd, + 0x07, 0x34, 0x1c, 0x70, 0x01, 0x3b, 0x8b, 0x42, 0xf2, 0xd1, 0x70, 0xbd, + 0x10, 0xb5, 0x0c, 0x00, 0x0b, 0x4b, 0x18, 0x68, 0xff, 0xf7, 0xe8, 0xff, + 0x21, 0x00, 0x0a, 0x4b, 0x08, 0x31, 0x18, 0x68, 0xff, 0xf7, 0xe2, 0xff, + 0x21, 0x00, 0x08, 0x4b, 0x10, 0x31, 0x18, 0x68, 0xff, 0xf7, 0xdc, 0xff, + 0x21, 0x00, 0x06, 0x4b, 0x18, 0x31, 0x18, 0x68, 0xff, 0xf7, 0xd6, 0xff, + 0x20, 0x20, 0x10, 0xbd, 0x0c, 0xa0, 0x80, 0x00, 0x40, 0xa0, 0x80, 0x00, + 0x44, 0xa0, 0x80, 0x00, 0x48, 0xa0, 0x80, 0x00, 0x08, 0xb4, 0x02, 0x4b, + 0x9c, 0x46, 0x10, 0x38, 0x08, 0xbc, 0x60, 0x47, 0x95, 0x3a, 0x00, 0x00, + 0x70, 0x47, 0x3f, 0x20, 0x70, 0x47, 0x13, 0xb5, 0x6b, 0x46, 0x02, 0x68, + 0xd9, 0x71, 0x07, 0x33, 0x54, 0x68, 0x19, 0x00, 0x01, 0x22, 0xa0, 0x47, + 0x16, 0xbd, 0x00, 0x00, 0x70, 0xb5, 0x0a, 0x26, 0x0b, 0x78, 0x92, 0xb0, + 0x6e, 0x44, 0x02, 0x33, 0x05, 0x00, 0x0b, 0x70, 0x3c, 0x22, 0x00, 0x21, + 0x30, 0x00, 0x02, 0xf0, 0x65, 0xff, 0x39, 0x48, 0x01, 0xac, 0x06, 0x90, + 0x38, 0x48, 0x24, 0x21, 0x07, 0x90, 0x06, 0x20, 0x20, 0x77, 0x68, 0x46, + 0x36, 0x4a, 0xa1, 0x74, 0x22, 0x81, 0x36, 0x4a, 0x36, 0x4b, 0xa2, 0x81, + 0xfd, 0x3a, 0xff, 0x3a, 0x80, 0x18, 0xc1, 0x77, 0x68, 0x46, 0x23, 0x39, + 0x06, 0x30, 0xc1, 0x77, 0x68, 0x46, 0x07, 0x30, 0xc1, 0x77, 0x02, 0xa8, + 0xc1, 0x77, 0x07, 0x20, 0xf2, 0x77, 0x03, 0x26, 0x08, 0x31, 0x69, 0x44, + 0xc8, 0x77, 0x03, 0xa9, 0xce, 0x77, 0x10, 0x21, 0x2b, 0x36, 0x6e, 0x44, + 0x31, 0x70, 0x09, 0x26, 0x21, 0x85, 0x1f, 0x31, 0x69, 0x44, 0x0e, 0x70, + 0x0c, 0xa9, 0x05, 0x3e, 0x0e, 0x70, 0x33, 0x21, 0x23, 0x80, 0x02, 0x23, + 0x69, 0x44, 0x0b, 0x70, 0x06, 0x36, 0x0d, 0xa9, 0x0e, 0x70, 0x22, 0x49, + 0x35, 0x36, 0xa1, 0x86, 0x3b, 0x21, 0x6e, 0x44, 0x30, 0x70, 0x10, 0xa8, + 0x62, 0x74, 0xe2, 0x77, 0x02, 0x70, 0x3d, 0x32, 0x69, 0x44, 0x6a, 0x44, + 0x0b, 0x70, 0x13, 0x70, 0x40, 0x21, 0x00, 0x22, 0xe3, 0x70, 0x23, 0x71, + 0x63, 0x71, 0xa3, 0x73, 0x41, 0x33, 0x6b, 0x44, 0x21, 0x87, 0x19, 0x70, + 0x5a, 0x70, 0x2b, 0x7d, 0xc0, 0x39, 0xa3, 0x70, 0xa3, 0x72, 0x63, 0x77, + 0x01, 0x33, 0xdb, 0xb2, 0xa3, 0x77, 0x6a, 0x7d, 0x0b, 0x20, 0x0d, 0x00, + 0x68, 0x44, 0x15, 0x43, 0xc5, 0x77, 0x31, 0x20, 0x68, 0x44, 0x03, 0x70, + 0x3a, 0x23, 0x50, 0x1c, 0x6b, 0x44, 0x18, 0x70, 0x41, 0x23, 0x02, 0x32, + 0x0a, 0x43, 0x6b, 0x44, 0x1a, 0x70, 0x21, 0x00, 0x42, 0x22, 0x08, 0x48, + 0x00, 0xf0, 0xd8, 0xfa, 0x12, 0xb0, 0x70, 0xbd, 0x10, 0x01, 0x04, 0x24, + 0x02, 0x06, 0x05, 0x24, 0x09, 0x04, 0x00, 0x00, 0x01, 0x02, 0x00, 0x00, + 0x08, 0x0b, 0x00, 0x00, 0x07, 0x05, 0x00, 0x00, 0x94, 0x20, 0x00, 0x20, + 0x08, 0xb4, 0x02, 0x4b, 0x9c, 0x46, 0x10, 0x38, 0x08, 0xbc, 0x60, 0x47, + 0x05, 0x3b, 0x00, 0x00, 0x70, 0xb5, 0x02, 0x7d, 0x0b, 0x79, 0x0c, 0x00, + 0x00, 0x25, 0x9a, 0x42, 0x0b, 0xd1, 0x0b, 0x78, 0x4e, 0x78, 0xa1, 0x2b, + 0x09, 0xd1, 0x21, 0x2e, 0x05, 0xd1, 0x07, 0x22, 0x1f, 0x49, 0x20, 0x48, + 0x00, 0xf0, 0xae, 0xfa, 0x01, 0x35, 0x28, 0x00, 0x70, 0xbd, 0x21, 0x2b, + 0xfb, 0xd1, 0x20, 0x2e, 0x2b, 0xd1, 0x07, 0x22, 0x19, 0x49, 0x1a, 0x48, + 0x00, 0xf0, 0xe4, 0xf9, 0x17, 0x4b, 0x1a, 0x78, 0x59, 0x78, 0x09, 0x02, + 0x11, 0x43, 0x9a, 0x78, 0x12, 0x04, 0x11, 0x43, 0xda, 0x78, 0x12, 0x06, + 0x0a, 0x43, 0x96, 0x21, 0xc9, 0x00, 0x8a, 0x42, 0x1d, 0xd1, 0xdb, 0x79, + 0xdb, 0x07, 0x1a, 0xd4, 0xfa, 0x20, 0xff, 0xf7, 0x89, 0xfd, 0x00, 0x21, + 0x0d, 0x48, 0x00, 0xf0, 0xb3, 0xfa, 0x01, 0x25, 0x23, 0x2e, 0xd8, 0xd1, + 0xe3, 0x78, 0xa2, 0x78, 0x1b, 0x02, 0x13, 0x43, 0x09, 0x4a, 0x00, 0x21, + 0x07, 0x48, 0x13, 0x60, 0x00, 0xf0, 0xa6, 0xfa, 0xcd, 0xe7, 0x22, 0x2e, + 0xef, 0xd1, 0x8a, 0x78, 0x02, 0x4b, 0xda, 0x71, 0xd2, 0xe7, 0xff, 0xf7, + 0x79, 0xfd, 0xe4, 0xe7, 0x1c, 0x00, 0x00, 0x20, 0x94, 0x20, 0x00, 0x20, + 0x18, 0x00, 0x00, 0x20, 0x08, 0xb4, 0x02, 0x4b, 0x9c, 0x46, 0x10, 0x38, + 0x08, 0xbc, 0x60, 0x47, 0x31, 0x3c, 0x00, 0x00, 0x10, 0xb5, 0x41, 0x7d, + 0x00, 0x6a, 0x01, 0x31, 0x00, 0xf0, 0xd8, 0xf8, 0x03, 0x4b, 0x1b, 0x68, + 0x01, 0x33, 0x5a, 0x1e, 0x93, 0x41, 0x18, 0x18, 0x10, 0xbd, 0xc0, 0x46, + 0x24, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x41, 0x7d, 0x00, 0x6a, 0x02, 0x31, + 0x00, 0xf0, 0xde, 0xf8, 0x10, 0xbd, 0x10, 0xb5, 0x41, 0x7d, 0x00, 0x6a, + 0x02, 0x31, 0x00, 0xf0, 0xa5, 0xf8, 0x10, 0xbd, 0x70, 0xb5, 0x0d, 0x00, + 0x41, 0x7d, 0x04, 0x00, 0x13, 0x00, 0x02, 0x31, 0x2a, 0x00, 0x00, 0x6a, + 0x00, 0xf0, 0x92, 0xf9, 0x00, 0x28, 0x01, 0xd1, 0x01, 0x23, 0x63, 0x60, + 0x70, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x05, 0x4c, 0x23, 0x68, 0x5a, 0x1c, + 0x04, 0xd1, 0x03, 0x68, 0x5b, 0x69, 0x98, 0x47, 0x03, 0x00, 0x20, 0x60, + 0x18, 0x00, 0x10, 0xbd, 0x24, 0x00, 0x00, 0x20, 0x07, 0x4a, 0x03, 0x00, + 0x10, 0x68, 0x10, 0xb5, 0x41, 0x1c, 0x03, 0xd0, 0x01, 0x23, 0x5b, 0x42, + 0x13, 0x60, 0x10, 0xbd, 0x59, 0x7d, 0x18, 0x6a, 0x01, 0x31, 0x00, 0xf0, + 0x1f, 0xf9, 0xf8, 0xe7, 0x24, 0x00, 0x00, 0x20, 0x70, 0x47, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x00, 0xfa, 0x23, 0x9b, 0x00, 0x10, 0xb5, 0x83, 0x60, + 0x0f, 0x4b, 0x00, 0x22, 0xc3, 0x82, 0x03, 0x00, 0x28, 0x33, 0x83, 0x61, + 0x0d, 0x4b, 0x04, 0x00, 0x42, 0x60, 0xc2, 0x61, 0x18, 0x00, 0x44, 0x33, + 0x23, 0x61, 0x08, 0x30, 0x63, 0x1d, 0x21, 0x62, 0x20, 0x60, 0xda, 0x77, + 0x83, 0x23, 0xa3, 0x62, 0x81, 0x3b, 0xe3, 0x62, 0x80, 0x33, 0x23, 0x63, + 0x00, 0xf0, 0x40, 0xf8, 0x21, 0x00, 0x10, 0x31, 0x00, 0xf0, 0x10, 0xf8, + 0x20, 0x00, 0x10, 0xbd, 0x03, 0x02, 0x00, 0x00, 0x2c, 0x97, 0x00, 0x00, + 0x10, 0xb5, 0x02, 0x49, 0x02, 0x48, 0xff, 0xf7, 0xd3, 0xff, 0x10, 0xbd, + 0x94, 0x20, 0x00, 0x20, 0x2c, 0x20, 0x00, 0x20, 0xf0, 0xb5, 0x8c, 0x79, + 0x45, 0x78, 0x03, 0x00, 0x2a, 0x19, 0x00, 0x20, 0x07, 0x2a, 0x1f, 0xdc, + 0x5a, 0x68, 0x82, 0x42, 0x16, 0xd1, 0x59, 0x60, 0x1a, 0x78, 0xc8, 0x79, + 0x0a, 0x71, 0x12, 0x18, 0x4d, 0x71, 0x1a, 0x70, 0x00, 0x22, 0x0b, 0x4d, + 0xd0, 0xb2, 0x84, 0x42, 0x0f, 0xd9, 0x8f, 0x68, 0x58, 0x78, 0x96, 0x00, + 0xf7, 0x59, 0x86, 0x00, 0x01, 0x30, 0x77, 0x51, 0x01, 0x32, 0x58, 0x70, + 0xf2, 0xe7, 0x02, 0x00, 0xd0, 0x68, 0x00, 0x28, 0xfb, 0xd1, 0xd1, 0x60, + 0xe4, 0xe7, 0x01, 0x20, 0xf0, 0xbd, 0xc0, 0x46, 0x6c, 0x20, 0x00, 0x20, + 0x01, 0x21, 0x06, 0x4a, 0x10, 0xb5, 0x13, 0x68, 0x05, 0x48, 0x0b, 0x40, + 0x04, 0xd1, 0x80, 0x24, 0x64, 0x00, 0x04, 0x80, 0x43, 0x60, 0x11, 0x60, + 0x10, 0xbd, 0xc0, 0x46, 0x60, 0x20, 0x00, 0x20, 0x64, 0x20, 0x00, 0x20, + 0x0b, 0x4b, 0xca, 0xb2, 0x0b, 0x48, 0x89, 0x01, 0xc9, 0x18, 0x53, 0x01, + 0xc3, 0x18, 0x59, 0x61, 0x99, 0x69, 0x08, 0x32, 0x89, 0x0b, 0x89, 0x03, + 0x99, 0x61, 0x03, 0x68, 0x52, 0x01, 0x9a, 0x18, 0x02, 0x23, 0xd3, 0x71, + 0x51, 0x79, 0x82, 0x3b, 0x0b, 0x43, 0x53, 0x71, 0x70, 0x47, 0xc0, 0x46, + 0xbc, 0x20, 0x00, 0x20, 0x44, 0x25, 0x00, 0x20, 0x08, 0x4b, 0x8a, 0x00, + 0xd0, 0x58, 0x10, 0xb5, 0x00, 0x28, 0x03, 0xd0, 0x03, 0x68, 0x9b, 0x68, + 0x98, 0x47, 0x10, 0xbd, 0xc9, 0xb2, 0x04, 0x4b, 0x49, 0x01, 0x59, 0x18, + 0x88, 0x68, 0x80, 0x04, 0x80, 0x0c, 0xf6, 0xe7, 0x98, 0x20, 0x00, 0x20, + 0x44, 0x25, 0x00, 0x20, 0x10, 0xb5, 0x0c, 0x00, 0xff, 0xf7, 0xe6, 0xff, + 0x00, 0x28, 0x0c, 0xd0, 0x06, 0x4b, 0xe4, 0xb2, 0x1b, 0x68, 0x08, 0x34, + 0x64, 0x01, 0x1c, 0x19, 0x80, 0x23, 0x62, 0x79, 0x5b, 0x42, 0x13, 0x43, + 0x63, 0x71, 0x02, 0x23, 0xe3, 0x71, 0x10, 0xbd, 0x44, 0x25, 0x00, 0x20, + 0xf0, 0xb5, 0x1c, 0x00, 0x2a, 0x4b, 0x85, 0xb0, 0x1b, 0x68, 0x07, 0x00, + 0x0d, 0x00, 0x02, 0x92, 0x00, 0x2b, 0x4a, 0xd0, 0x27, 0x4b, 0x8a, 0x00, + 0xd0, 0x58, 0x00, 0x28, 0x08, 0xd0, 0x03, 0x68, 0x22, 0x00, 0x5b, 0x68, + 0x02, 0x99, 0x98, 0x47, 0x04, 0x00, 0x20, 0x00, 0x05, 0xb0, 0xf0, 0xbd, + 0x38, 0x00, 0xff, 0xf7, 0xb9, 0xff, 0x84, 0x42, 0x04, 0xd9, 0x29, 0x00, + 0x38, 0x00, 0xff, 0xf7, 0xb3, 0xff, 0x04, 0x00, 0x01, 0x21, 0xeb, 0xb2, + 0x1b, 0x4e, 0x03, 0x93, 0x5b, 0x01, 0x01, 0x93, 0xf2, 0x18, 0x93, 0x68, + 0x9b, 0x0b, 0x9b, 0x03, 0x93, 0x60, 0x01, 0x9a, 0x33, 0x68, 0x02, 0x98, + 0x9b, 0x18, 0xff, 0x33, 0x5a, 0x7a, 0x0a, 0x43, 0x5a, 0x72, 0x14, 0x4b, + 0xa9, 0x01, 0xc9, 0x18, 0x22, 0x00, 0x02, 0xf0, 0x1f, 0xfd, 0x00, 0x2c, + 0xd7, 0xd0, 0x29, 0x00, 0x38, 0x00, 0xff, 0xf7, 0x93, 0xff, 0x00, 0x28, + 0xd1, 0xd1, 0x40, 0x21, 0x03, 0x9b, 0x32, 0x68, 0x08, 0x33, 0x5b, 0x01, + 0xd3, 0x18, 0x18, 0x79, 0x01, 0x43, 0x19, 0x71, 0x01, 0x21, 0xd9, 0x71, + 0x01, 0x9b, 0xd3, 0x18, 0xff, 0x33, 0x9a, 0x7a, 0x0a, 0x43, 0x9a, 0x72, + 0xbf, 0xe7, 0x01, 0x24, 0x64, 0x42, 0xbc, 0xe7, 0x40, 0x25, 0x00, 0x20, + 0x98, 0x20, 0x00, 0x20, 0x44, 0x25, 0x00, 0x20, 0x7c, 0x22, 0x00, 0x20, + 0x13, 0xb5, 0x6b, 0x46, 0xdc, 0x1d, 0x22, 0x00, 0x01, 0x23, 0xff, 0xf7, + 0x99, 0xff, 0x01, 0x28, 0x01, 0xd1, 0x20, 0x78, 0x16, 0xbd, 0x01, 0x20, + 0x40, 0x42, 0xfb, 0xe7, 0x70, 0xb5, 0xcb, 0xb2, 0x12, 0x4a, 0x13, 0x48, + 0x5c, 0x01, 0x89, 0x01, 0x89, 0x18, 0x02, 0x19, 0x51, 0x60, 0x91, 0x68, + 0x10, 0x4d, 0x08, 0x33, 0x0d, 0x40, 0x80, 0x21, 0x49, 0x03, 0x29, 0x43, + 0x40, 0x25, 0x91, 0x60, 0x91, 0x68, 0x89, 0x0b, 0x89, 0x03, 0x91, 0x60, + 0x01, 0x68, 0x5a, 0x01, 0x8a, 0x18, 0x16, 0x79, 0x35, 0x43, 0x15, 0x71, + 0x95, 0x79, 0x6d, 0x06, 0xfc, 0xd5, 0x5b, 0x01, 0xc9, 0x18, 0xcb, 0x79, + 0xdb, 0x07, 0xfc, 0xd5, 0x00, 0x19, 0x80, 0x68, 0xc0, 0xb2, 0x70, 0xbd, + 0x7c, 0x22, 0x00, 0x20, 0x44, 0x25, 0x00, 0x20, 0xff, 0x3f, 0x00, 0xf0, + 0x70, 0xb5, 0x0d, 0x00, 0x00, 0x21, 0x14, 0x00, 0xff, 0xf7, 0xcc, 0xff, + 0xa0, 0x42, 0x00, 0xd9, 0x20, 0x00, 0x00, 0x23, 0x03, 0x49, 0xa3, 0x42, + 0x03, 0xd0, 0xca, 0x5c, 0xea, 0x54, 0x01, 0x33, 0xf9, 0xe7, 0x70, 0xbd, + 0x7c, 0x22, 0x00, 0x20, 0xf0, 0xb5, 0x1e, 0x00, 0x3a, 0x4b, 0x85, 0xb0, + 0x1b, 0x68, 0x0f, 0x00, 0x01, 0x92, 0x00, 0x2b, 0x35, 0xd0, 0x80, 0x23, + 0xdb, 0x01, 0x9e, 0x42, 0x31, 0xd8, 0x00, 0x25, 0x35, 0x4b, 0x8a, 0x01, + 0xd3, 0x18, 0x02, 0x93, 0x00, 0x2e, 0x2c, 0xd0, 0x33, 0x4b, 0x1b, 0x68, + 0x03, 0x93, 0xff, 0x23, 0x3b, 0x40, 0x1c, 0x00, 0x00, 0x93, 0x08, 0x34, + 0x03, 0x9b, 0x64, 0x01, 0x1c, 0x19, 0xa3, 0x79, 0xdb, 0x09, 0x21, 0xd0, + 0x2d, 0x4b, 0x2e, 0x49, 0x18, 0x68, 0x00, 0xf0, 0xd5, 0xfc, 0x2d, 0x4b, + 0x17, 0x21, 0x58, 0x43, 0x00, 0xf0, 0xd0, 0xfc, 0x2b, 0x4b, 0xe2, 0x79, + 0x92, 0x07, 0x13, 0xd4, 0xda, 0x5d, 0x00, 0x2a, 0x01, 0xd1, 0x01, 0x38, + 0xf7, 0xd2, 0x01, 0x22, 0xda, 0x55, 0x00, 0x9b, 0x5a, 0x01, 0x21, 0x4b, + 0x9b, 0x18, 0x9a, 0x69, 0x92, 0x0b, 0x92, 0x03, 0x9a, 0x61, 0x01, 0x25, + 0x6d, 0x42, 0x28, 0x00, 0x05, 0xb0, 0xf0, 0xbd, 0x00, 0x22, 0x1f, 0x4b, + 0x34, 0x00, 0xda, 0x55, 0x3f, 0x2e, 0x09, 0xd9, 0x00, 0x9b, 0x40, 0x24, + 0x5a, 0x01, 0x17, 0x4b, 0x9b, 0x18, 0x80, 0x22, 0x99, 0x69, 0x12, 0x06, + 0x0a, 0x43, 0x9a, 0x61, 0x22, 0x00, 0x01, 0x99, 0x02, 0x98, 0x02, 0xf0, + 0x51, 0xfc, 0x00, 0x9b, 0xa1, 0x04, 0x5a, 0x01, 0x0f, 0x4b, 0x89, 0x0c, + 0x9b, 0x18, 0x02, 0x9a, 0x2d, 0x19, 0x5a, 0x61, 0x9a, 0x69, 0x36, 0x1b, + 0x92, 0x0b, 0x92, 0x03, 0x0a, 0x43, 0x9a, 0x61, 0x00, 0x9b, 0x03, 0x9a, + 0x08, 0x33, 0x5b, 0x01, 0xd3, 0x18, 0x02, 0x22, 0xda, 0x71, 0x59, 0x79, + 0x82, 0x3a, 0x0a, 0x43, 0x5a, 0x71, 0x01, 0x9b, 0x1b, 0x19, 0x01, 0x93, + 0x9a, 0xe7, 0xc0, 0x46, 0x40, 0x25, 0x00, 0x20, 0xbc, 0x20, 0x00, 0x20, + 0x44, 0x25, 0x00, 0x20, 0x10, 0x00, 0x00, 0x20, 0x40, 0x42, 0x0f, 0x00, + 0x70, 0x11, 0x01, 0x00, 0xb4, 0x20, 0x00, 0x20, 0x70, 0xb5, 0x0d, 0x00, + 0x1c, 0x00, 0x0d, 0x4b, 0xae, 0x01, 0xf6, 0x18, 0x11, 0x00, 0x30, 0x00, + 0x22, 0x00, 0x02, 0xf0, 0x19, 0xfc, 0xed, 0xb2, 0x09, 0x49, 0x6d, 0x01, + 0x4d, 0x19, 0x6e, 0x61, 0xab, 0x69, 0x08, 0x4a, 0x20, 0x00, 0x13, 0x40, + 0xab, 0x61, 0xab, 0x69, 0xa2, 0x04, 0x9b, 0x0b, 0x92, 0x0c, 0x9b, 0x03, + 0x13, 0x43, 0xab, 0x61, 0x70, 0xbd, 0xc0, 0x46, 0xbc, 0x20, 0x00, 0x20, + 0x44, 0x25, 0x00, 0x20, 0xff, 0x3f, 0x00, 0xf0, 0xf7, 0xb5, 0x10, 0x4b, + 0x01, 0x90, 0x1b, 0x78, 0x0f, 0x00, 0x15, 0x00, 0x00, 0x2b, 0x0c, 0xd1, + 0x0d, 0x4b, 0x16, 0x00, 0x1c, 0x78, 0x00, 0x2c, 0x09, 0xd0, 0x0c, 0x4e, + 0x0c, 0x48, 0x34, 0x88, 0x20, 0x18, 0x64, 0x19, 0x02, 0xf0, 0xec, 0xfb, + 0x34, 0x80, 0x28, 0x00, 0xfe, 0xbd, 0x00, 0x2e, 0xfb, 0xd0, 0x3a, 0x19, + 0x33, 0x00, 0x00, 0x21, 0x01, 0x98, 0xff, 0xf7, 0xbd, 0xff, 0x24, 0x18, + 0x36, 0x1a, 0xf4, 0xe7, 0x3c, 0x24, 0x00, 0x20, 0x3d, 0x25, 0x00, 0x20, + 0x3e, 0x25, 0x00, 0x20, 0x3d, 0x24, 0x00, 0x20, 0xcb, 0xb2, 0x04, 0x49, + 0x5b, 0x01, 0xc9, 0x18, 0x8b, 0x69, 0x9b, 0x0b, 0x9b, 0x03, 0x8b, 0x61, + 0x70, 0x47, 0xc0, 0x46, 0x44, 0x25, 0x00, 0x20, 0x01, 0x4b, 0x02, 0x4a, + 0x1a, 0x60, 0x70, 0x47, 0x44, 0x25, 0x00, 0x20, 0x00, 0x50, 0x00, 0x41, + 0x01, 0x20, 0x70, 0x47, 0x10, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, + 0x98, 0x47, 0x10, 0xbd, 0x13, 0x04, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, + 0xd9, 0x69, 0x9a, 0x69, 0x91, 0x42, 0x03, 0xd0, 0xdb, 0x69, 0xc0, 0x18, + 0x00, 0x7d, 0x70, 0x47, 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, 0x10, 0xb5, + 0x04, 0x00, 0x00, 0x69, 0xff, 0xf7, 0x22, 0xfb, 0x22, 0x00, 0x00, 0x23, + 0xfc, 0x32, 0x93, 0x61, 0xd3, 0x61, 0x86, 0x22, 0x92, 0x00, 0xa4, 0x18, + 0x63, 0x60, 0xa3, 0x60, 0x10, 0xbd, 0xf0, 0x20, 0x01, 0x40, 0x30, 0x39, + 0x48, 0x42, 0x48, 0x41, 0x70, 0x47, 0xf0, 0x23, 0x1b, 0x01, 0x19, 0x40, + 0x80, 0x23, 0x06, 0x20, 0x9b, 0x00, 0x99, 0x42, 0x0a, 0xd0, 0x01, 0x33, + 0xff, 0x33, 0x01, 0x30, 0x99, 0x42, 0x05, 0xd0, 0x80, 0x23, 0x02, 0x38, + 0x5b, 0x00, 0x99, 0x42, 0x00, 0xd0, 0x00, 0x20, 0x70, 0x47, 0x0f, 0x20, + 0x01, 0x40, 0x00, 0x20, 0x01, 0x29, 0x03, 0xd0, 0x02, 0x39, 0x48, 0x1e, + 0x81, 0x41, 0x48, 0x1c, 0x70, 0x47, 0x00, 0x00, 0x89, 0x23, 0xf0, 0xb5, + 0x18, 0x26, 0x85, 0xb0, 0x02, 0x91, 0x9b, 0x00, 0x04, 0x00, 0xc0, 0x5c, + 0x33, 0x00, 0x08, 0x21, 0x43, 0x43, 0x32, 0x4d, 0x17, 0x00, 0xeb, 0x18, + 0x59, 0x56, 0xff, 0xf7, 0x5d, 0xf9, 0x30, 0x4b, 0x08, 0x21, 0xe0, 0x5c, + 0x33, 0x00, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, 0xff, 0xf7, 0x54, 0xf9, + 0x2c, 0x4b, 0xe2, 0x5c, 0x03, 0x93, 0x02, 0x2a, 0x09, 0xd1, 0x11, 0x33, + 0xe0, 0x5c, 0xff, 0x28, 0x05, 0xd0, 0x08, 0x21, 0x46, 0x43, 0xae, 0x19, + 0x71, 0x56, 0xff, 0xf7, 0x45, 0xf9, 0x8a, 0x26, 0xb6, 0x00, 0xa0, 0x5d, + 0xff, 0x28, 0x19, 0xd0, 0x01, 0x21, 0xff, 0xf7, 0xad, 0xf8, 0x18, 0x22, + 0xa3, 0x5d, 0x21, 0x49, 0x5a, 0x43, 0xab, 0x56, 0xad, 0x18, 0xdb, 0x01, + 0x58, 0x18, 0x8b, 0x21, 0x89, 0x00, 0x60, 0x50, 0x1d, 0x49, 0x01, 0x22, + 0x5b, 0x18, 0x8c, 0x21, 0x89, 0x00, 0x63, 0x50, 0x69, 0x68, 0x8a, 0x40, + 0x8d, 0x21, 0x89, 0x00, 0x62, 0x50, 0x1a, 0x60, 0x01, 0x22, 0x02, 0x9b, + 0x11, 0x00, 0x20, 0x69, 0xff, 0xf7, 0x50, 0xfb, 0x39, 0x00, 0x20, 0x00, + 0xff, 0xf7, 0x8f, 0xff, 0x39, 0x00, 0x05, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0x9e, 0xff, 0x39, 0x00, 0x06, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x7f, 0xff, + 0x33, 0x00, 0x00, 0x90, 0x29, 0x00, 0x20, 0x69, 0x01, 0x22, 0xff, 0xf7, + 0x5f, 0xfa, 0x0b, 0x4b, 0x20, 0x69, 0xe2, 0x5c, 0x03, 0x9b, 0xe1, 0x5c, + 0xff, 0xf7, 0x75, 0xfa, 0x20, 0x69, 0xff, 0xf7, 0x92, 0xfa, 0x05, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0xc0, 0x93, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, + 0x27, 0x02, 0x00, 0x00, 0x18, 0x44, 0x00, 0x41, 0x14, 0x44, 0x00, 0x41, + 0x26, 0x02, 0x00, 0x00, 0x80, 0x22, 0x10, 0xb5, 0x04, 0x00, 0x52, 0x00, + 0x00, 0x21, 0x02, 0xf0, 0x0f, 0xfb, 0x23, 0x00, 0x00, 0x22, 0xfc, 0x33, + 0x5a, 0x60, 0x20, 0x00, 0x9a, 0x60, 0x10, 0xbd, 0xf7, 0xb5, 0x1d, 0x00, + 0x08, 0xab, 0x1b, 0x78, 0x04, 0x00, 0x00, 0x93, 0x09, 0xab, 0x1b, 0x78, + 0x16, 0x00, 0x01, 0x93, 0x00, 0x23, 0x43, 0x60, 0xfa, 0x23, 0x9b, 0x00, + 0x83, 0x60, 0x11, 0x4b, 0x0f, 0x00, 0x08, 0x33, 0x03, 0x60, 0x14, 0x30, + 0xff, 0xf7, 0xdc, 0xff, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, + 0xd7, 0xff, 0x89, 0x23, 0x6a, 0x46, 0x9b, 0x00, 0x27, 0x61, 0xe6, 0x54, + 0x09, 0x4b, 0x12, 0x78, 0xe5, 0x54, 0x09, 0x4b, 0x20, 0x00, 0xe2, 0x54, + 0x6a, 0x46, 0x08, 0x4b, 0x12, 0x79, 0xe2, 0x54, 0x8a, 0x22, 0x29, 0x3b, + 0xff, 0x3b, 0x92, 0x00, 0xa3, 0x54, 0x10, 0x32, 0xa3, 0x54, 0xfe, 0xbd, + 0x84, 0x97, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, 0x26, 0x02, 0x00, 0x00, + 0x27, 0x02, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, 0x58, 0x68, 0x9b, 0x68, + 0xc0, 0x1a, 0x01, 0xd5, 0x01, 0x30, 0xff, 0x30, 0x70, 0x47, 0x10, 0xb5, + 0x04, 0x00, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0xf0, 0xff, + 0x00, 0x28, 0xf8, 0xd1, 0x20, 0x69, 0xff, 0xf7, 0x30, 0xfa, 0x10, 0xbd, + 0x10, 0xb5, 0x14, 0x30, 0xff, 0xf7, 0xe6, 0xff, 0x10, 0xbd, 0x03, 0x00, + 0xfc, 0x33, 0x59, 0x68, 0x9a, 0x68, 0x91, 0x42, 0x04, 0xdb, 0x5a, 0x68, + 0x98, 0x68, 0x80, 0x1a, 0xff, 0x30, 0x70, 0x47, 0x98, 0x68, 0x5b, 0x68, + 0xc0, 0x1a, 0x01, 0x38, 0xf9, 0xe7, 0x10, 0xb5, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0xeb, 0xff, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x69, + 0xff, 0xf7, 0x2b, 0xfa, 0x00, 0x28, 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, + 0x36, 0xfa, 0x20, 0x69, 0xff, 0xf7, 0x28, 0xfa, 0x20, 0x69, 0xff, 0xf7, + 0x10, 0xfa, 0x00, 0x28, 0x20, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x2b, 0xfa, + 0x22, 0x00, 0xfc, 0x32, 0x93, 0x69, 0xd1, 0x69, 0x01, 0x33, 0xdb, 0xb2, + 0x8b, 0x42, 0x03, 0xd0, 0x91, 0x69, 0x61, 0x18, 0x08, 0x75, 0x93, 0x61, + 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, 0x20, 0x00, + 0x14, 0x30, 0xff, 0xf7, 0xc0, 0xff, 0x09, 0x28, 0x06, 0xdc, 0x8b, 0x23, + 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, 0x1a, 0x60, + 0x20, 0x69, 0xff, 0xf7, 0x05, 0xfa, 0x00, 0x28, 0x1a, 0xd0, 0x20, 0x00, + 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0x92, 0xff, 0x00, 0x28, 0x22, 0xd0, + 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x99, 0x68, 0x5a, 0x68, 0x91, 0x42, + 0x18, 0xd0, 0x8e, 0x21, 0x9a, 0x68, 0x49, 0x00, 0xa2, 0x18, 0x51, 0x5c, + 0x9a, 0x68, 0x01, 0x32, 0xd2, 0xb2, 0x9a, 0x60, 0xc9, 0xb2, 0x20, 0x69, + 0xff, 0xf7, 0xf1, 0xf9, 0x20, 0x69, 0xff, 0xf7, 0xcf, 0xf9, 0x00, 0x28, + 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0xce, 0xf9, 0x20, 0x69, 0xff, 0xf7, + 0xbe, 0xf9, 0x10, 0xbd, 0x01, 0x21, 0x49, 0x42, 0xec, 0xe7, 0x20, 0x69, + 0xff, 0xf7, 0xeb, 0xf9, 0xec, 0xe7, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x00, + 0x00, 0x69, 0x0d, 0x00, 0xff, 0xf7, 0xce, 0xf9, 0x00, 0x28, 0x3e, 0xd1, + 0xff, 0x26, 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x5a, 0x68, 0x99, 0x68, + 0x01, 0x32, 0x32, 0x40, 0x8a, 0x42, 0x23, 0xd1, 0xef, 0xf3, 0x10, 0x83, + 0xdb, 0x07, 0x10, 0xd4, 0x1e, 0x4b, 0x5b, 0x68, 0xdb, 0x05, 0xdb, 0x0d, + 0xed, 0xd0, 0x10, 0x3b, 0x5b, 0xb2, 0x00, 0x2b, 0x10, 0xda, 0x0f, 0x22, + 0x13, 0x40, 0x08, 0x3b, 0x9b, 0x08, 0x19, 0x4a, 0x9b, 0x00, 0x9b, 0x18, + 0x1b, 0x68, 0x20, 0x69, 0xff, 0xf7, 0xaa, 0xf9, 0x00, 0x28, 0xdc, 0xd0, + 0x20, 0x00, 0xff, 0xf7, 0x6a, 0xff, 0xd8, 0xe7, 0x9b, 0x08, 0xc0, 0x33, + 0x12, 0x4a, 0x9b, 0x00, 0x9b, 0x58, 0xf0, 0xe7, 0x5a, 0x68, 0x01, 0x32, + 0x16, 0x40, 0x9a, 0x68, 0x96, 0x42, 0x05, 0xd0, 0x8e, 0x21, 0x5a, 0x68, + 0x49, 0x00, 0xa2, 0x18, 0x55, 0x54, 0x5e, 0x60, 0x20, 0x69, 0xff, 0xf7, + 0xa0, 0xf9, 0x01, 0x20, 0x70, 0xbd, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0x1c, 0xff, 0x00, 0x28, 0xb9, 0xd1, 0x29, 0x00, 0x20, 0x69, + 0xff, 0xf7, 0x8b, 0xf9, 0xf1, 0xe7, 0xc0, 0x46, 0x00, 0xed, 0x00, 0xe0, + 0x1c, 0xed, 0x00, 0xe0, 0x00, 0xe1, 0x00, 0xe0, 0x03, 0x00, 0x70, 0xb5, + 0xfc, 0x33, 0xd9, 0x69, 0x9a, 0x69, 0x04, 0x00, 0x91, 0x42, 0x1a, 0xd0, + 0xda, 0x69, 0x82, 0x18, 0x15, 0x7d, 0xda, 0x69, 0x01, 0x32, 0xd2, 0xb2, + 0xda, 0x61, 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, + 0x20, 0x00, 0x14, 0x30, 0xff, 0xf7, 0x11, 0xff, 0x0a, 0x28, 0x06, 0xdd, + 0x8c, 0x23, 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, + 0x1a, 0x60, 0x28, 0x00, 0x70, 0xbd, 0x01, 0x25, 0x6d, 0x42, 0xe8, 0xe7, + 0x10, 0xb5, 0x04, 0x00, 0x00, 0x68, 0x00, 0x28, 0x01, 0xd0, 0x02, 0xf0, + 0x77, 0xf9, 0x20, 0x00, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x68, + 0x00, 0x28, 0x01, 0xd0, 0x02, 0xf0, 0x6e, 0xf9, 0x00, 0x23, 0x23, 0x60, + 0xa3, 0x60, 0x63, 0x60, 0x10, 0xbd, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, + 0x00, 0x68, 0x01, 0x31, 0x02, 0xf0, 0xa8, 0xfe, 0x03, 0x1e, 0x01, 0xd0, + 0x01, 0x20, 0x28, 0xc4, 0x70, 0xbd, 0x03, 0x68, 0x10, 0xb5, 0x04, 0x00, + 0x00, 0x2b, 0x04, 0xd0, 0x43, 0x68, 0x8b, 0x42, 0x01, 0xd3, 0x01, 0x20, + 0x10, 0xbd, 0x20, 0x00, 0xff, 0xf7, 0xe7, 0xff, 0x00, 0x28, 0xf9, 0xd0, + 0xa3, 0x68, 0x00, 0x2b, 0xf5, 0xd1, 0x22, 0x68, 0x13, 0x70, 0xf2, 0xe7, + 0x70, 0xb5, 0x0e, 0x00, 0x11, 0x00, 0x04, 0x00, 0x15, 0x00, 0xff, 0xf7, + 0xe4, 0xff, 0x00, 0x28, 0x04, 0xd1, 0x20, 0x00, 0xff, 0xf7, 0xc7, 0xff, + 0x20, 0x00, 0x70, 0xbd, 0xa5, 0x60, 0x31, 0x00, 0x20, 0x68, 0x02, 0xf0, + 0xaf, 0xfe, 0xf7, 0xe7, 0x00, 0x23, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, + 0x03, 0x60, 0x43, 0x60, 0x83, 0x60, 0x99, 0x42, 0x07, 0xd0, 0x08, 0x00, + 0x02, 0xf0, 0xaa, 0xfe, 0x29, 0x00, 0x02, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0xdb, 0xff, 0x20, 0x00, 0x70, 0xbd, 0x70, 0xb5, 0x05, 0x00, 0x08, 0x00, + 0x0c, 0x00, 0x02, 0xf0, 0x9d, 0xfe, 0x21, 0x00, 0x02, 0x00, 0x28, 0x00, + 0xff, 0xf7, 0xce, 0xff, 0x70, 0xbd, 0x70, 0xb5, 0x05, 0x00, 0x00, 0x68, + 0x0c, 0x00, 0x00, 0x28, 0x0f, 0xd0, 0x09, 0x68, 0x00, 0x29, 0x0a, 0xd0, + 0x6b, 0x68, 0xa2, 0x68, 0x93, 0x42, 0x06, 0xd3, 0x02, 0xf0, 0x80, 0xfe, + 0xa3, 0x68, 0xab, 0x60, 0x00, 0x23, 0xa3, 0x60, 0x70, 0xbd, 0x02, 0xf0, + 0xff, 0xf8, 0x23, 0x68, 0x2b, 0x60, 0x63, 0x68, 0x6b, 0x60, 0xa3, 0x68, + 0xab, 0x60, 0x00, 0x23, 0x23, 0x60, 0x63, 0x60, 0xf1, 0xe7, 0x10, 0xb5, + 0x0b, 0x00, 0x04, 0x00, 0x88, 0x42, 0x05, 0xd0, 0x09, 0x68, 0x00, 0x29, + 0x04, 0xd0, 0x9a, 0x68, 0xff, 0xf7, 0xa2, 0xff, 0x20, 0x00, 0x10, 0xbd, + 0xff, 0xf7, 0x71, 0xff, 0xfa, 0xe7, 0x00, 0x23, 0x10, 0xb5, 0x04, 0x00, + 0x03, 0x60, 0x43, 0x60, 0x83, 0x60, 0xff, 0xf7, 0xe8, 0xff, 0x20, 0x00, + 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x88, 0x42, 0x01, 0xd0, 0xff, 0xf7, + 0xc0, 0xff, 0x20, 0x00, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x29, + 0x03, 0xd0, 0xff, 0xf7, 0xac, 0xff, 0x20, 0x00, 0x10, 0xbd, 0xff, 0xf7, + 0x54, 0xff, 0xfa, 0xe7, 0xf8, 0xb5, 0x04, 0x00, 0x0f, 0x1e, 0x02, 0xd1, + 0x00, 0x26, 0x30, 0x00, 0xf8, 0xbd, 0x01, 0x26, 0x00, 0x2a, 0xfa, 0xd0, + 0x83, 0x68, 0xd5, 0x18, 0x29, 0x00, 0xff, 0xf7, 0x5c, 0xff, 0x00, 0x28, + 0xf2, 0xd0, 0x23, 0x68, 0xa2, 0x68, 0x39, 0x00, 0x98, 0x18, 0x02, 0xf0, + 0x2b, 0xfe, 0xa5, 0x60, 0xeb, 0xe7, 0x07, 0xb5, 0x00, 0x22, 0x01, 0xab, + 0x19, 0x70, 0x5a, 0x70, 0x19, 0x00, 0x01, 0x32, 0xff, 0xf7, 0xde, 0xff, + 0x0e, 0xbd, 0x70, 0xb5, 0x83, 0x68, 0x8d, 0x68, 0x5c, 0x1b, 0x00, 0x23, + 0x94, 0x42, 0x0c, 0xd3, 0x00, 0x68, 0x98, 0x42, 0x09, 0xd0, 0x09, 0x68, + 0x99, 0x42, 0x06, 0xd0, 0x80, 0x18, 0x2a, 0x00, 0x02, 0xf0, 0x1d, 0xfe, + 0x43, 0x42, 0x43, 0x41, 0xdb, 0xb2, 0x18, 0x00, 0x70, 0xbd, 0x83, 0x68, + 0x10, 0xb5, 0x9c, 0x46, 0x8b, 0x68, 0x00, 0x22, 0x9c, 0x45, 0x02, 0xd3, + 0xff, 0xf7, 0xe1, 0xff, 0x02, 0x00, 0x10, 0x00, 0x10, 0xbd, 0x10, 0xb5, + 0x82, 0x68, 0x8c, 0x68, 0x00, 0x23, 0xa2, 0x42, 0x0c, 0xd3, 0x00, 0x68, + 0x98, 0x42, 0x09, 0xd0, 0x09, 0x68, 0x99, 0x42, 0x06, 0xd0, 0x12, 0x1b, + 0x80, 0x18, 0x02, 0xf0, 0xe3, 0xfd, 0x43, 0x42, 0x43, 0x41, 0xdb, 0xb2, + 0x18, 0x00, 0x10, 0xbd, 0x83, 0x68, 0x8b, 0x42, 0x03, 0xd9, 0x03, 0x68, + 0x58, 0x18, 0x00, 0x2b, 0x02, 0xd1, 0x00, 0x23, 0x01, 0x48, 0x03, 0x70, + 0x70, 0x47, 0xc0, 0x46, 0x48, 0x26, 0x00, 0x20, 0x83, 0x68, 0x10, 0xb5, + 0x93, 0x42, 0x07, 0xd9, 0x04, 0x68, 0xa0, 0x18, 0x02, 0xf0, 0xba, 0xfd, + 0x00, 0x28, 0x01, 0xd0, 0x00, 0x1b, 0x10, 0xbd, 0x01, 0x20, 0x40, 0x42, + 0xfb, 0xe7, 0x10, 0xb5, 0x00, 0x22, 0xff, 0xf7, 0xed, 0xff, 0x10, 0xbd, + 0xf7, 0xb5, 0x15, 0x00, 0x8a, 0x68, 0x0f, 0x00, 0x00, 0x2a, 0x1b, 0xd0, + 0x83, 0x68, 0x00, 0x2b, 0x18, 0xd0, 0x9a, 0x42, 0x16, 0xd8, 0xab, 0x42, + 0x00, 0xd8, 0x5d, 0x1e, 0x06, 0x68, 0x01, 0x24, 0x30, 0x00, 0x73, 0x19, + 0x64, 0x42, 0x01, 0x93, 0x01, 0x9b, 0x98, 0x42, 0x0c, 0xd8, 0x39, 0x68, + 0x02, 0xf0, 0xe0, 0xfd, 0x00, 0x28, 0x07, 0xd0, 0x83, 0x1b, 0xab, 0x42, + 0x00, 0xd8, 0x1c, 0x00, 0x01, 0x30, 0xf1, 0xe7, 0x01, 0x24, 0x64, 0x42, + 0x20, 0x00, 0xfe, 0xbd, 0x10, 0xb5, 0x83, 0x68, 0x8a, 0x68, 0x9a, 0x1a, + 0xff, 0xf7, 0xd4, 0xff, 0x10, 0xbd, 0x00, 0x00, 0xf7, 0xb5, 0x0e, 0x00, + 0x01, 0x90, 0x14, 0x00, 0x1d, 0x00, 0x9a, 0x42, 0x01, 0xd9, 0x2c, 0x00, + 0x15, 0x00, 0x0c, 0x49, 0x01, 0x98, 0xff, 0xf7, 0xdd, 0xfe, 0xb7, 0x68, + 0xa7, 0x42, 0x0e, 0xd9, 0xaf, 0x42, 0x00, 0xd9, 0x2f, 0x00, 0x00, 0x22, + 0x33, 0x68, 0x01, 0x98, 0xdb, 0x19, 0x1d, 0x78, 0x1a, 0x70, 0x33, 0x68, + 0x19, 0x19, 0xff, 0xf7, 0x2e, 0xff, 0x33, 0x68, 0xdd, 0x55, 0x01, 0x98, + 0xfe, 0xbd, 0xc0, 0x46, 0x27, 0x93, 0x00, 0x00, 0x70, 0xb5, 0x85, 0x68, + 0x04, 0x00, 0x8d, 0x42, 0x13, 0xd9, 0x00, 0x2a, 0x11, 0xd0, 0x6b, 0x1a, + 0x93, 0x42, 0x00, 0xd9, 0x13, 0x00, 0x20, 0x68, 0xed, 0x1a, 0xcb, 0x18, + 0xc3, 0x18, 0x6a, 0x1a, 0x40, 0x18, 0xa5, 0x60, 0x19, 0x00, 0x02, 0xf0, + 0x7f, 0xfd, 0x00, 0x21, 0x22, 0x68, 0xa3, 0x68, 0xd1, 0x54, 0x70, 0xbd, + 0x01, 0x22, 0x10, 0xb5, 0x52, 0x42, 0xff, 0xf7, 0xe1, 0xff, 0x10, 0xbd, + 0xf8, 0xb5, 0x07, 0x68, 0x06, 0x00, 0x00, 0x2f, 0x22, 0xd0, 0x84, 0x68, + 0x00, 0x2c, 0x1f, 0xd0, 0x3d, 0x00, 0x28, 0x78, 0x01, 0xf0, 0xaa, 0xff, + 0x00, 0x28, 0x01, 0xd0, 0x01, 0x35, 0xf8, 0xe7, 0x01, 0x3c, 0x3c, 0x19, + 0x20, 0x78, 0x01, 0xf0, 0xa1, 0xff, 0x00, 0x28, 0x03, 0xd0, 0xa5, 0x42, + 0x01, 0xd8, 0x01, 0x3c, 0xf6, 0xe7, 0x01, 0x34, 0x62, 0x1b, 0xb2, 0x60, + 0xaf, 0x42, 0x03, 0xd2, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, 0xd2, 0xff, + 0x00, 0x21, 0x32, 0x68, 0xb3, 0x68, 0xd1, 0x54, 0xf8, 0xbd, 0x03, 0x68, + 0x00, 0x20, 0x10, 0xb5, 0x83, 0x42, 0x02, 0xd0, 0x18, 0x00, 0x01, 0xf0, + 0x4d, 0xff, 0x10, 0xbd, 0x10, 0xb5, 0x01, 0xf0, 0xa5, 0xff, 0x10, 0xbd, + 0x0b, 0x00, 0x10, 0xb5, 0x01, 0x00, 0x18, 0x00, 0x01, 0xf0, 0x48, 0xff, + 0x10, 0xbd, 0x00, 0x00, 0x02, 0xb4, 0x71, 0x46, 0x49, 0x08, 0x49, 0x00, + 0x09, 0x5c, 0x49, 0x00, 0x8e, 0x44, 0x02, 0xbc, 0x70, 0x47, 0xc0, 0x46, + 0x00, 0x22, 0x43, 0x08, 0x8b, 0x42, 0x74, 0xd3, 0x03, 0x09, 0x8b, 0x42, + 0x5f, 0xd3, 0x03, 0x0a, 0x8b, 0x42, 0x44, 0xd3, 0x03, 0x0b, 0x8b, 0x42, + 0x28, 0xd3, 0x03, 0x0c, 0x8b, 0x42, 0x0d, 0xd3, 0xff, 0x22, 0x09, 0x02, + 0x12, 0xba, 0x03, 0x0c, 0x8b, 0x42, 0x02, 0xd3, 0x12, 0x12, 0x09, 0x02, + 0x65, 0xd0, 0x03, 0x0b, 0x8b, 0x42, 0x19, 0xd3, 0x00, 0xe0, 0x09, 0x0a, + 0xc3, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x03, 0xc0, 0x1a, 0x52, 0x41, + 0x83, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x03, 0xc0, 0x1a, 0x52, 0x41, + 0x43, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x03, 0xc0, 0x1a, 0x52, 0x41, + 0x03, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x03, 0xc0, 0x1a, 0x52, 0x41, + 0xc3, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x02, 0xc0, 0x1a, 0x52, 0x41, + 0x83, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x02, 0xc0, 0x1a, 0x52, 0x41, + 0x43, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x02, 0xc0, 0x1a, 0x52, 0x41, + 0x03, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x02, 0xc0, 0x1a, 0x52, 0x41, + 0xcd, 0xd2, 0xc3, 0x09, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x01, 0xc0, 0x1a, + 0x52, 0x41, 0x83, 0x09, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x01, 0xc0, 0x1a, + 0x52, 0x41, 0x43, 0x09, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x01, 0xc0, 0x1a, + 0x52, 0x41, 0x03, 0x09, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x01, 0xc0, 0x1a, + 0x52, 0x41, 0xc3, 0x08, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x00, 0xc0, 0x1a, + 0x52, 0x41, 0x83, 0x08, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x00, 0xc0, 0x1a, + 0x52, 0x41, 0x43, 0x08, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x00, 0xc0, 0x1a, + 0x52, 0x41, 0x41, 0x1a, 0x00, 0xd2, 0x01, 0x46, 0x52, 0x41, 0x10, 0x46, + 0x70, 0x47, 0xff, 0xe7, 0x01, 0xb5, 0x00, 0x20, 0x00, 0xf0, 0xf0, 0xf8, + 0x02, 0xbd, 0xc0, 0x46, 0x00, 0x29, 0xf7, 0xd0, 0x76, 0xe7, 0x70, 0x47, + 0x03, 0x46, 0x0b, 0x43, 0x7f, 0xd4, 0x00, 0x22, 0x43, 0x08, 0x8b, 0x42, + 0x74, 0xd3, 0x03, 0x09, 0x8b, 0x42, 0x5f, 0xd3, 0x03, 0x0a, 0x8b, 0x42, + 0x44, 0xd3, 0x03, 0x0b, 0x8b, 0x42, 0x28, 0xd3, 0x03, 0x0c, 0x8b, 0x42, + 0x0d, 0xd3, 0xff, 0x22, 0x09, 0x02, 0x12, 0xba, 0x03, 0x0c, 0x8b, 0x42, + 0x02, 0xd3, 0x12, 0x12, 0x09, 0x02, 0x65, 0xd0, 0x03, 0x0b, 0x8b, 0x42, + 0x19, 0xd3, 0x00, 0xe0, 0x09, 0x0a, 0xc3, 0x0b, 0x8b, 0x42, 0x01, 0xd3, + 0xcb, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0b, 0x8b, 0x42, 0x01, 0xd3, + 0x8b, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0b, 0x8b, 0x42, 0x01, 0xd3, + 0x4b, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0b, 0x8b, 0x42, 0x01, 0xd3, + 0x0b, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x0a, 0x8b, 0x42, 0x01, 0xd3, + 0xcb, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0a, 0x8b, 0x42, 0x01, 0xd3, + 0x8b, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0a, 0x8b, 0x42, 0x01, 0xd3, + 0x4b, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0a, 0x8b, 0x42, 0x01, 0xd3, + 0x0b, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0xcd, 0xd2, 0xc3, 0x09, 0x8b, 0x42, + 0x01, 0xd3, 0xcb, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x09, 0x8b, 0x42, + 0x01, 0xd3, 0x8b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x09, 0x8b, 0x42, + 0x01, 0xd3, 0x4b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x09, 0x8b, 0x42, + 0x01, 0xd3, 0x0b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x08, 0x8b, 0x42, + 0x01, 0xd3, 0xcb, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x08, 0x8b, 0x42, + 0x01, 0xd3, 0x8b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x08, 0x8b, 0x42, + 0x01, 0xd3, 0x4b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x41, 0x1a, 0x00, 0xd2, + 0x01, 0x46, 0x52, 0x41, 0x10, 0x46, 0x70, 0x47, 0x5d, 0xe0, 0xca, 0x0f, + 0x00, 0xd0, 0x49, 0x42, 0x03, 0x10, 0x00, 0xd3, 0x40, 0x42, 0x53, 0x40, + 0x00, 0x22, 0x9c, 0x46, 0x03, 0x09, 0x8b, 0x42, 0x2d, 0xd3, 0x03, 0x0a, + 0x8b, 0x42, 0x12, 0xd3, 0xfc, 0x22, 0x89, 0x01, 0x12, 0xba, 0x03, 0x0a, + 0x8b, 0x42, 0x0c, 0xd3, 0x89, 0x01, 0x92, 0x11, 0x8b, 0x42, 0x08, 0xd3, + 0x89, 0x01, 0x92, 0x11, 0x8b, 0x42, 0x04, 0xd3, 0x89, 0x01, 0x3a, 0xd0, + 0x92, 0x11, 0x00, 0xe0, 0x89, 0x09, 0xc3, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0xcb, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0x8b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0x4b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0x0b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x08, 0x8b, 0x42, 0x01, 0xd3, + 0xcb, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x08, 0x8b, 0x42, 0x01, 0xd3, + 0x8b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0xd9, 0xd2, 0x43, 0x08, 0x8b, 0x42, + 0x01, 0xd3, 0x4b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x41, 0x1a, 0x00, 0xd2, + 0x01, 0x46, 0x63, 0x46, 0x52, 0x41, 0x5b, 0x10, 0x10, 0x46, 0x01, 0xd3, + 0x40, 0x42, 0x00, 0x2b, 0x00, 0xd5, 0x49, 0x42, 0x70, 0x47, 0x63, 0x46, + 0x5b, 0x10, 0x00, 0xd3, 0x40, 0x42, 0x01, 0xb5, 0x00, 0x20, 0x00, 0xf0, + 0x05, 0xf8, 0x02, 0xbd, 0x00, 0x29, 0xf8, 0xd0, 0x16, 0xe7, 0x70, 0x47, + 0x70, 0x47, 0xc0, 0x46, 0x84, 0x46, 0x10, 0x1c, 0x62, 0x46, 0x8c, 0x46, + 0x19, 0x1c, 0x63, 0x46, 0x00, 0xe0, 0xc0, 0x46, 0x1f, 0xb5, 0x00, 0xf0, + 0xf1, 0xfe, 0x00, 0x28, 0x01, 0xd4, 0x00, 0x21, 0xc8, 0x42, 0x1f, 0xbd, + 0x10, 0xb5, 0x00, 0xf0, 0x49, 0xfe, 0x40, 0x42, 0x01, 0x30, 0x10, 0xbd, + 0x10, 0xb5, 0x00, 0xf0, 0xe3, 0xfe, 0x00, 0x28, 0x01, 0xdb, 0x00, 0x20, + 0x10, 0xbd, 0x01, 0x20, 0x10, 0xbd, 0xc0, 0x46, 0x10, 0xb5, 0x00, 0xf0, + 0xd9, 0xfe, 0x00, 0x28, 0x01, 0xdd, 0x00, 0x20, 0x10, 0xbd, 0x01, 0x20, + 0x10, 0xbd, 0xc0, 0x46, 0x10, 0xb5, 0x00, 0xf0, 0x6b, 0xfe, 0x00, 0x28, + 0x01, 0xdc, 0x00, 0x20, 0x10, 0xbd, 0x01, 0x20, 0x10, 0xbd, 0xc0, 0x46, + 0x10, 0xb5, 0x00, 0xf0, 0x61, 0xfe, 0x00, 0x28, 0x01, 0xda, 0x00, 0x20, + 0x10, 0xbd, 0x01, 0x20, 0x10, 0xbd, 0xc0, 0x46, 0xf0, 0xb5, 0x4f, 0x46, + 0x46, 0x46, 0xd6, 0x46, 0x0c, 0x00, 0x09, 0x03, 0xc0, 0xb5, 0x49, 0x0a, + 0x47, 0x0f, 0x5e, 0x00, 0x39, 0x43, 0x1f, 0x03, 0xdb, 0x0f, 0x9c, 0x46, + 0x65, 0x00, 0x7b, 0x0a, 0x57, 0x0f, 0x1f, 0x43, 0x6d, 0x0d, 0xe4, 0x0f, + 0x76, 0x0d, 0xa1, 0x46, 0xc0, 0x00, 0xb8, 0x46, 0xd2, 0x00, 0xab, 0x1b, + 0x64, 0x45, 0x7b, 0xd0, 0x00, 0x2b, 0x5f, 0xdd, 0x00, 0x2e, 0x00, 0xd0, + 0xa4, 0xe0, 0x3e, 0x00, 0x16, 0x43, 0x00, 0xd1, 0x12, 0xe1, 0x5e, 0x1e, + 0x00, 0x2e, 0x00, 0xd0, 0x9e, 0xe1, 0x87, 0x1a, 0x43, 0x46, 0xb8, 0x42, + 0x80, 0x41, 0x01, 0x25, 0xc9, 0x1a, 0x40, 0x42, 0x09, 0x1a, 0x0b, 0x02, + 0x00, 0xd4, 0x31, 0xe1, 0x49, 0x02, 0x4e, 0x0a, 0x00, 0x2e, 0x00, 0xd1, + 0x6e, 0xe1, 0x30, 0x00, 0x01, 0xf0, 0x28, 0xfd, 0x03, 0x00, 0x08, 0x3b, + 0x1f, 0x2b, 0x00, 0xdd, 0x61, 0xe1, 0x20, 0x22, 0x39, 0x00, 0xd2, 0x1a, + 0x9e, 0x40, 0xd1, 0x40, 0x9f, 0x40, 0x0e, 0x43, 0x9d, 0x42, 0x00, 0xdd, + 0x51, 0xe1, 0x5d, 0x1b, 0x6b, 0x1c, 0x1f, 0x2b, 0x00, 0xdd, 0x7c, 0xe1, + 0x20, 0x21, 0xc9, 0x1a, 0x3d, 0x00, 0x30, 0x00, 0x8f, 0x40, 0x88, 0x40, + 0xdd, 0x40, 0x79, 0x1e, 0x8f, 0x41, 0x31, 0x00, 0x07, 0x22, 0x28, 0x43, + 0xd9, 0x40, 0x00, 0x25, 0x07, 0x43, 0x3a, 0x40, 0x00, 0x2a, 0x09, 0xd0, + 0x0f, 0x23, 0x3b, 0x40, 0x04, 0x2b, 0x05, 0xd0, 0x3b, 0x1d, 0xbb, 0x42, + 0xbf, 0x41, 0x7f, 0x42, 0xc9, 0x19, 0x1f, 0x00, 0x0b, 0x02, 0x00, 0xd4, + 0x26, 0xe2, 0x6a, 0x1c, 0xc6, 0x4b, 0x55, 0x05, 0x6d, 0x0d, 0x9a, 0x42, + 0x00, 0xd1, 0x06, 0xe1, 0xc4, 0x4a, 0xff, 0x08, 0x0a, 0x40, 0x53, 0x07, + 0x52, 0x02, 0x3b, 0x43, 0x12, 0x0b, 0x8e, 0xe0, 0x00, 0x2b, 0x00, 0xd0, + 0xb8, 0xe0, 0x6b, 0x1c, 0x5b, 0x05, 0x5b, 0x0d, 0x01, 0x2b, 0x00, 0xdc, + 0x30, 0xe1, 0x87, 0x1a, 0x43, 0x46, 0xb8, 0x42, 0xb6, 0x41, 0xcb, 0x1a, + 0x76, 0x42, 0x9e, 0x1b, 0x33, 0x02, 0x00, 0xd5, 0x4c, 0xe1, 0x3b, 0x00, + 0x33, 0x43, 0xa1, 0xd1, 0x00, 0x22, 0x00, 0x24, 0x00, 0x25, 0x70, 0xe0, + 0x00, 0x2b, 0x00, 0xdc, 0xe5, 0xe0, 0x00, 0x2e, 0x00, 0xd1, 0x83, 0xe0, + 0xaf, 0x4e, 0xb5, 0x42, 0x60, 0xd0, 0x80, 0x26, 0x36, 0x04, 0x37, 0x43, + 0xb8, 0x46, 0x38, 0x2b, 0x00, 0xdc, 0x3e, 0xe1, 0x43, 0x46, 0x13, 0x43, + 0x1f, 0x00, 0x7a, 0x1e, 0x97, 0x41, 0x3f, 0x18, 0x87, 0x42, 0x80, 0x41, + 0x40, 0x42, 0x09, 0x18, 0x0b, 0x02, 0x00, 0xd4, 0xb0, 0xe0, 0xa4, 0x4b, + 0x01, 0x35, 0x9d, 0x42, 0x00, 0xd1, 0xc3, 0xe0, 0xa2, 0x4a, 0x7b, 0x08, + 0x0a, 0x40, 0x01, 0x21, 0x0f, 0x40, 0x1f, 0x43, 0x51, 0x08, 0xd3, 0x07, + 0x07, 0x22, 0x1f, 0x43, 0x3a, 0x40, 0x99, 0xe7, 0x9b, 0x4e, 0xb5, 0x42, + 0x38, 0xd0, 0x80, 0x26, 0x36, 0x04, 0x37, 0x43, 0xb8, 0x46, 0x38, 0x2b, + 0x00, 0xdd, 0xdc, 0xe0, 0x1f, 0x2b, 0x00, 0xdc, 0x30, 0xe1, 0x1e, 0x00, + 0x47, 0x46, 0x20, 0x3e, 0xf7, 0x40, 0xbc, 0x46, 0x20, 0x2b, 0x04, 0xd0, + 0x40, 0x26, 0xf3, 0x1a, 0x46, 0x46, 0x9e, 0x40, 0x32, 0x43, 0x17, 0x00, + 0x63, 0x46, 0x7a, 0x1e, 0x97, 0x41, 0x1f, 0x43, 0xcc, 0xe0, 0x00, 0x2b, + 0x00, 0xd1, 0x04, 0xe2, 0x43, 0x46, 0x13, 0x43, 0x00, 0xd1, 0x59, 0xe1, + 0x4b, 0x07, 0xc0, 0x08, 0x18, 0x43, 0x80, 0x23, 0xc9, 0x08, 0x1b, 0x03, + 0x19, 0x42, 0x08, 0xd0, 0x45, 0x46, 0xed, 0x08, 0x1d, 0x42, 0x04, 0xd1, + 0x43, 0x46, 0xd0, 0x08, 0x59, 0x07, 0x08, 0x43, 0x29, 0x00, 0x42, 0x0f, + 0xc9, 0x00, 0x7f, 0x4d, 0x11, 0x43, 0xc0, 0x00, 0x4b, 0x07, 0xca, 0x08, + 0x7c, 0x49, 0xc0, 0x08, 0x03, 0x43, 0x8d, 0x42, 0x68, 0xd0, 0x12, 0x03, + 0x6d, 0x05, 0x12, 0x0b, 0x6d, 0x0d, 0x00, 0x21, 0x12, 0x03, 0x18, 0x00, + 0x13, 0x0b, 0x0a, 0x0d, 0x12, 0x05, 0x1a, 0x43, 0x76, 0x4b, 0x2d, 0x05, + 0x13, 0x40, 0x2b, 0x43, 0x5b, 0x00, 0xe4, 0x07, 0x5b, 0x08, 0x23, 0x43, + 0x19, 0x00, 0x1c, 0xbc, 0x90, 0x46, 0x99, 0x46, 0xa2, 0x46, 0xf0, 0xbd, + 0x3e, 0x00, 0x16, 0x43, 0x12, 0xd0, 0x5e, 0x1e, 0x00, 0x2e, 0x00, 0xd0, + 0x00, 0xe1, 0x87, 0x18, 0x87, 0x42, 0x80, 0x41, 0x41, 0x44, 0x40, 0x42, + 0x09, 0x18, 0x01, 0x25, 0x0b, 0x02, 0x33, 0xd5, 0x02, 0x25, 0x85, 0xe7, + 0x64, 0x46, 0x33, 0x00, 0x41, 0x46, 0x10, 0x00, 0x1d, 0x00, 0xc7, 0xe7, + 0x00, 0x2d, 0x00, 0xd0, 0xda, 0xe0, 0x0c, 0x00, 0x04, 0x43, 0xf3, 0xd0, + 0x5c, 0x1c, 0x00, 0xd1, 0x9f, 0xe1, 0x5d, 0x4c, 0xa6, 0x42, 0x00, 0xd1, + 0x2f, 0xe1, 0xdb, 0x43, 0x38, 0x2b, 0x00, 0xdd, 0x66, 0xe1, 0x1f, 0x2b, + 0x00, 0xdd, 0x83, 0xe1, 0x20, 0x24, 0x05, 0x00, 0xe4, 0x1a, 0x0f, 0x00, + 0xdd, 0x40, 0xd9, 0x40, 0xa0, 0x40, 0x43, 0x46, 0xa7, 0x40, 0x5b, 0x1a, + 0x44, 0x1e, 0xa0, 0x41, 0x98, 0x46, 0x2f, 0x43, 0x38, 0x43, 0x17, 0x1a, + 0xba, 0x42, 0x92, 0x41, 0x43, 0x46, 0x52, 0x42, 0x99, 0x1a, 0x64, 0x46, + 0x35, 0x00, 0xca, 0xe6, 0x07, 0x22, 0x3a, 0x40, 0x00, 0x2a, 0x00, 0xd0, + 0xf6, 0xe6, 0x4b, 0x07, 0xca, 0x08, 0x48, 0x49, 0xff, 0x08, 0x3b, 0x43, + 0x8d, 0x42, 0x96, 0xd1, 0x19, 0x00, 0x11, 0x43, 0x00, 0xd1, 0x9e, 0xe1, + 0x80, 0x21, 0x09, 0x03, 0x0a, 0x43, 0x12, 0x03, 0x12, 0x0b, 0x41, 0x4d, + 0x8f, 0xe7, 0x15, 0x00, 0x00, 0x22, 0x00, 0x23, 0x8b, 0xe7, 0x00, 0x2b, + 0x00, 0xd0, 0xc7, 0xe0, 0x6b, 0x1c, 0x5f, 0x05, 0x7f, 0x0d, 0x01, 0x2f, + 0x00, 0xdc, 0xf1, 0xe0, 0x39, 0x4d, 0xab, 0x42, 0x00, 0xd1, 0xb9, 0xe0, + 0x85, 0x18, 0x0a, 0x00, 0x85, 0x42, 0x89, 0x41, 0x42, 0x44, 0x49, 0x42, + 0x51, 0x18, 0x07, 0x22, 0xcf, 0x07, 0x6d, 0x08, 0x2f, 0x43, 0x49, 0x08, + 0x3a, 0x40, 0x1d, 0x00, 0xc2, 0xe6, 0x07, 0x22, 0x30, 0x49, 0xed, 0x1a, + 0x31, 0x40, 0x3a, 0x40, 0xbc, 0xe6, 0x3e, 0x00, 0x28, 0x38, 0x86, 0x40, + 0x00, 0x27, 0x9f, 0xe6, 0x38, 0x00, 0x01, 0xf0, 0xb9, 0xfb, 0x20, 0x30, + 0x8e, 0xe6, 0x43, 0x46, 0x13, 0x43, 0x1f, 0x00, 0x7a, 0x1e, 0x97, 0x41, + 0xc7, 0x1b, 0xb8, 0x42, 0x80, 0x41, 0x40, 0x42, 0x09, 0x1a, 0x78, 0xe6, + 0x0e, 0x00, 0x3b, 0x00, 0x06, 0x43, 0x13, 0x43, 0x00, 0x2d, 0x61, 0xd1, + 0x00, 0x2e, 0x00, 0xd0, 0xf4, 0xe0, 0x00, 0x2b, 0x00, 0xd1, 0x1b, 0xe1, + 0x64, 0x46, 0x39, 0x00, 0x10, 0x00, 0x39, 0xe7, 0x1a, 0x4f, 0xbb, 0x42, + 0x7a, 0xd0, 0x33, 0x00, 0xff, 0xe6, 0x30, 0x00, 0x1f, 0x3d, 0xe8, 0x40, + 0x20, 0x2b, 0x03, 0xd0, 0x40, 0x21, 0xcb, 0x1a, 0x9e, 0x40, 0x37, 0x43, + 0x7b, 0x1e, 0x9f, 0x41, 0x07, 0x22, 0x07, 0x43, 0x3a, 0x40, 0x00, 0x21, + 0x00, 0x25, 0x89, 0xe7, 0x17, 0x1a, 0x43, 0x46, 0xba, 0x42, 0xb6, 0x41, + 0x59, 0x1a, 0x76, 0x42, 0x8e, 0x1b, 0x64, 0x46, 0x4e, 0xe6, 0x1f, 0x2b, + 0x00, 0xdd, 0xad, 0xe0, 0x20, 0x26, 0x47, 0x46, 0xf6, 0x1a, 0xb7, 0x40, + 0xb9, 0x46, 0x17, 0x00, 0xb2, 0x46, 0xdf, 0x40, 0x4e, 0x46, 0x3e, 0x43, + 0x37, 0x00, 0x56, 0x46, 0xb2, 0x40, 0x56, 0x1e, 0xb2, 0x41, 0x17, 0x43, + 0x42, 0x46, 0xda, 0x40, 0x89, 0x18, 0xae, 0xe6, 0xff, 0x07, 0x00, 0x00, + 0xff, 0xff, 0x7f, 0xff, 0xff, 0xff, 0x0f, 0x80, 0x20, 0x26, 0x47, 0x46, + 0xf6, 0x1a, 0xb7, 0x40, 0xb9, 0x46, 0x17, 0x00, 0xb2, 0x46, 0xdf, 0x40, + 0x4e, 0x46, 0x3e, 0x43, 0x37, 0x00, 0x56, 0x46, 0xb2, 0x40, 0x56, 0x1e, + 0xb2, 0x41, 0x17, 0x43, 0x42, 0x46, 0xda, 0x40, 0x89, 0x1a, 0x99, 0xe7, + 0x7f, 0x4c, 0xa6, 0x42, 0x5b, 0xd0, 0x80, 0x24, 0x24, 0x04, 0x5b, 0x42, + 0x21, 0x43, 0x27, 0xe7, 0x00, 0x2e, 0x0c, 0xd1, 0x00, 0x2b, 0x00, 0xd1, + 0xcb, 0xe0, 0x64, 0x46, 0x39, 0x00, 0x10, 0x00, 0x77, 0x4d, 0xd7, 0xe6, + 0x76, 0x4f, 0xbb, 0x42, 0x18, 0xd0, 0x33, 0x00, 0x75, 0xe6, 0x00, 0x2b, + 0x14, 0xd0, 0x4b, 0x07, 0xc0, 0x08, 0x18, 0x43, 0x80, 0x23, 0xc9, 0x08, + 0x1b, 0x03, 0x19, 0x42, 0x07, 0xd0, 0xfc, 0x08, 0x1c, 0x42, 0x04, 0xd1, + 0x79, 0x07, 0xd0, 0x08, 0x08, 0x43, 0xe1, 0x46, 0x21, 0x00, 0x4c, 0x46, + 0x42, 0x0f, 0xc9, 0x00, 0x11, 0x43, 0xc0, 0x00, 0x68, 0x4d, 0xb9, 0xe6, + 0x1d, 0x00, 0x00, 0x22, 0x00, 0x23, 0xc0, 0xe6, 0x00, 0x2d, 0x5b, 0xd1, + 0x0d, 0x00, 0x05, 0x43, 0x00, 0xd1, 0xe2, 0xe6, 0x5d, 0x1c, 0x00, 0xd1, + 0xb0, 0xe0, 0x61, 0x4d, 0xae, 0x42, 0x1f, 0xd0, 0xdb, 0x43, 0x38, 0x2b, + 0x71, 0xdc, 0x1f, 0x2b, 0x00, 0xdd, 0x96, 0xe0, 0x20, 0x25, 0x0f, 0x00, + 0xed, 0x1a, 0xaf, 0x40, 0xb9, 0x46, 0x07, 0x00, 0xaa, 0x46, 0xdf, 0x40, + 0x4d, 0x46, 0x3d, 0x43, 0x2f, 0x00, 0x55, 0x46, 0xa8, 0x40, 0xd9, 0x40, + 0x45, 0x1e, 0xa8, 0x41, 0x88, 0x44, 0x07, 0x43, 0xbf, 0x18, 0x97, 0x42, + 0x92, 0x41, 0x51, 0x42, 0x41, 0x44, 0x35, 0x00, 0x3a, 0xe6, 0x64, 0x46, + 0x35, 0x00, 0x41, 0x46, 0x10, 0x00, 0x85, 0xe6, 0x0b, 0x00, 0x03, 0x43, + 0x00, 0x2d, 0x00, 0xd0, 0x63, 0xe6, 0x00, 0x2b, 0xf5, 0xd0, 0x43, 0x46, + 0x13, 0x43, 0x00, 0xd1, 0x7a, 0xe6, 0x87, 0x18, 0x87, 0x42, 0x80, 0x41, + 0x07, 0x22, 0x41, 0x44, 0x40, 0x42, 0x09, 0x18, 0x3a, 0x40, 0x0b, 0x02, + 0x00, 0xd4, 0xd5, 0xe6, 0x43, 0x4b, 0x01, 0x35, 0x19, 0x40, 0xc9, 0xe5, + 0x38, 0x00, 0x69, 0xe6, 0x1e, 0x00, 0x47, 0x46, 0x20, 0x3e, 0xf7, 0x40, + 0xbc, 0x46, 0x20, 0x2b, 0x04, 0xd0, 0x40, 0x26, 0xf3, 0x1a, 0x46, 0x46, + 0x9e, 0x40, 0x32, 0x43, 0x17, 0x00, 0x63, 0x46, 0x7a, 0x1e, 0x97, 0x41, + 0x1f, 0x43, 0x02, 0xe6, 0x36, 0x4d, 0xae, 0x42, 0xca, 0xd0, 0x80, 0x25, + 0x2d, 0x04, 0x5b, 0x42, 0x29, 0x43, 0xa6, 0xe7, 0x08, 0x43, 0x41, 0x1e, + 0x88, 0x41, 0xa6, 0xe6, 0x00, 0x2b, 0x00, 0xd1, 0x48, 0xe6, 0x87, 0x1a, + 0x43, 0x46, 0xb8, 0x42, 0xb6, 0x41, 0xcb, 0x1a, 0x76, 0x42, 0x9e, 0x1b, + 0x33, 0x02, 0x4b, 0xd5, 0x17, 0x1a, 0x43, 0x46, 0xba, 0x42, 0x92, 0x41, + 0x59, 0x1a, 0x52, 0x42, 0x89, 0x1a, 0x07, 0x22, 0x64, 0x46, 0x3a, 0x40, + 0x92, 0xe5, 0x01, 0x43, 0x0f, 0x00, 0x79, 0x1e, 0x8f, 0x41, 0x9d, 0xe7, + 0x1c, 0x00, 0x0f, 0x00, 0x20, 0x3c, 0xe7, 0x40, 0x20, 0x2b, 0x03, 0xd0, + 0x40, 0x24, 0xe3, 0x1a, 0x99, 0x40, 0x08, 0x43, 0x41, 0x1e, 0x88, 0x41, + 0x38, 0x43, 0x7c, 0xe6, 0x00, 0x22, 0x00, 0x24, 0x25, 0xe6, 0x17, 0x1a, + 0x43, 0x46, 0xba, 0x42, 0x92, 0x41, 0x59, 0x1a, 0x52, 0x42, 0x89, 0x1a, + 0x64, 0x46, 0x35, 0x00, 0x43, 0xe5, 0x41, 0x46, 0x10, 0x00, 0x14, 0x4d, + 0x10, 0xe6, 0x80, 0x22, 0x00, 0x24, 0x12, 0x03, 0x80, 0xe6, 0x1d, 0x00, + 0x0f, 0x00, 0x20, 0x3d, 0xef, 0x40, 0xbc, 0x46, 0x20, 0x2b, 0x03, 0xd0, + 0x40, 0x25, 0xeb, 0x1a, 0x99, 0x40, 0x08, 0x43, 0x07, 0x00, 0x63, 0x46, + 0x78, 0x1e, 0x87, 0x41, 0x1f, 0x43, 0x69, 0xe7, 0x87, 0x18, 0x97, 0x42, + 0x9b, 0x41, 0x41, 0x44, 0x5b, 0x42, 0xc9, 0x18, 0x35, 0x00, 0xa3, 0xe5, + 0x3b, 0x00, 0x33, 0x43, 0xce, 0xd0, 0x07, 0x22, 0x31, 0x00, 0x3a, 0x40, + 0x52, 0xe6, 0x00, 0x23, 0x1a, 0x00, 0xf4, 0xe5, 0xff, 0x07, 0x00, 0x00, + 0xff, 0xff, 0x7f, 0xff, 0xf0, 0xb5, 0x57, 0x46, 0xde, 0x46, 0x4e, 0x46, + 0x45, 0x46, 0xe0, 0xb5, 0x83, 0x46, 0x07, 0x00, 0x0e, 0x03, 0x48, 0x00, + 0x85, 0xb0, 0x92, 0x46, 0x1c, 0x00, 0x36, 0x0b, 0x40, 0x0d, 0xcd, 0x0f, + 0x00, 0x28, 0x00, 0xd1, 0x9d, 0xe0, 0x95, 0x4b, 0x98, 0x42, 0x39, 0xd0, + 0x80, 0x23, 0xf6, 0x00, 0x1b, 0x04, 0x1e, 0x43, 0x92, 0x4a, 0x7b, 0x0f, + 0x33, 0x43, 0x99, 0x46, 0x94, 0x46, 0x03, 0x00, 0x63, 0x44, 0x00, 0x93, + 0x00, 0x23, 0x00, 0x26, 0xff, 0x00, 0x02, 0x93, 0x23, 0x03, 0x1b, 0x0b, + 0x98, 0x46, 0x63, 0x00, 0xe4, 0x0f, 0x52, 0x46, 0x5b, 0x0d, 0x01, 0x94, + 0x00, 0xd1, 0xb3, 0xe0, 0x86, 0x49, 0x8b, 0x42, 0x00, 0xd1, 0x9e, 0xe0, + 0x42, 0x46, 0xd1, 0x00, 0x80, 0x22, 0x12, 0x04, 0x0a, 0x43, 0x51, 0x46, + 0x49, 0x0f, 0x11, 0x43, 0x8b, 0x46, 0x81, 0x49, 0x52, 0x46, 0x8c, 0x46, + 0x00, 0x99, 0x63, 0x44, 0xcb, 0x1a, 0x00, 0x21, 0xd2, 0x00, 0x00, 0x93, + 0x2b, 0x00, 0x63, 0x40, 0x9a, 0x46, 0x0f, 0x2e, 0x00, 0xd9, 0x05, 0xe1, + 0x7a, 0x4b, 0xb6, 0x00, 0x9b, 0x59, 0x9f, 0x46, 0x5b, 0x46, 0x33, 0x43, + 0x99, 0x46, 0x00, 0xd0, 0xb8, 0xe0, 0x02, 0x23, 0x08, 0x26, 0x00, 0x27, + 0x00, 0x90, 0x02, 0x93, 0xca, 0xe7, 0xcb, 0x46, 0x3a, 0x00, 0x02, 0x99, + 0x01, 0x95, 0x01, 0x9b, 0x9a, 0x46, 0x02, 0x29, 0x27, 0xd0, 0x03, 0x29, + 0x00, 0xd1, 0x80, 0xe2, 0x01, 0x29, 0x44, 0xd0, 0x6d, 0x49, 0x00, 0x9b, + 0x8c, 0x46, 0x63, 0x44, 0x1c, 0x00, 0x00, 0x2c, 0x38, 0xdd, 0x53, 0x07, + 0x00, 0xd0, 0x13, 0xe2, 0xd2, 0x08, 0x5b, 0x46, 0xdb, 0x01, 0x09, 0xd5, + 0x59, 0x46, 0x67, 0x4b, 0x19, 0x40, 0x8b, 0x46, 0x80, 0x21, 0xc9, 0x00, + 0x8c, 0x46, 0x00, 0x9b, 0x63, 0x44, 0x1c, 0x00, 0x63, 0x4b, 0x9c, 0x42, + 0x07, 0xdc, 0x5b, 0x46, 0x64, 0x05, 0x5f, 0x07, 0x5b, 0x02, 0x17, 0x43, + 0x1b, 0x0b, 0x62, 0x0d, 0x02, 0xe0, 0x00, 0x23, 0x00, 0x27, 0x58, 0x4a, + 0x00, 0x21, 0x1b, 0x03, 0x1c, 0x0b, 0x0b, 0x0d, 0x1b, 0x05, 0x23, 0x43, + 0x14, 0x05, 0x5a, 0x4a, 0x38, 0x00, 0x13, 0x40, 0x1c, 0x43, 0x53, 0x46, + 0x64, 0x00, 0xdb, 0x07, 0x64, 0x08, 0x1c, 0x43, 0x21, 0x00, 0x05, 0xb0, + 0x3c, 0xbc, 0x90, 0x46, 0x99, 0x46, 0xa2, 0x46, 0xab, 0x46, 0xf0, 0xbd, + 0x01, 0x22, 0x52, 0x42, 0x01, 0x23, 0x1b, 0x1b, 0x38, 0x2b, 0x00, 0xdc, + 0xad, 0xe1, 0x00, 0x22, 0x00, 0x23, 0x00, 0x27, 0xdc, 0xe7, 0x5b, 0x46, + 0x33, 0x43, 0x99, 0x46, 0x5e, 0xd0, 0x00, 0x2e, 0x00, 0xd1, 0x8a, 0xe1, + 0x30, 0x00, 0x01, 0xf0, 0x8d, 0xf9, 0x03, 0x00, 0x0b, 0x3b, 0x1c, 0x2b, + 0x00, 0xdd, 0x7b, 0xe1, 0x1d, 0x22, 0xd3, 0x1a, 0x5a, 0x46, 0x01, 0x00, + 0xda, 0x40, 0x08, 0x39, 0x8e, 0x40, 0x13, 0x00, 0x5f, 0x46, 0x33, 0x43, + 0x99, 0x46, 0x8f, 0x40, 0x3f, 0x4b, 0x00, 0x26, 0x1b, 0x1a, 0x00, 0x93, + 0x00, 0x23, 0x02, 0x93, 0x52, 0xe7, 0x41, 0x46, 0x53, 0x46, 0x0b, 0x43, + 0x3b, 0x49, 0x9b, 0x46, 0x8c, 0x46, 0x00, 0x9b, 0x63, 0x44, 0x00, 0x93, + 0x5b, 0x46, 0x00, 0x2b, 0x3b, 0xd1, 0x02, 0x23, 0x00, 0x22, 0x1e, 0x43, + 0x02, 0x21, 0x61, 0xe7, 0x43, 0x46, 0x13, 0x43, 0x9b, 0x46, 0x37, 0xd0, + 0x43, 0x46, 0x00, 0x2b, 0x00, 0xd1, 0x62, 0xe1, 0x40, 0x46, 0x01, 0xf0, + 0x59, 0xf9, 0x03, 0x00, 0x0b, 0x3b, 0x1c, 0x2b, 0x00, 0xdd, 0x53, 0xe1, + 0x02, 0x00, 0x41, 0x46, 0x08, 0x3a, 0x91, 0x40, 0x88, 0x46, 0x1d, 0x21, + 0xcb, 0x1a, 0x51, 0x46, 0xd9, 0x40, 0x0b, 0x00, 0x41, 0x46, 0x0b, 0x43, + 0x9b, 0x46, 0x53, 0x46, 0x93, 0x40, 0x1a, 0x00, 0x00, 0x9b, 0x25, 0x49, + 0x9c, 0x46, 0x60, 0x44, 0x03, 0x00, 0x8c, 0x46, 0x63, 0x44, 0x00, 0x93, + 0x00, 0x21, 0x37, 0xe7, 0x03, 0x23, 0xb1, 0x46, 0x00, 0x90, 0x0c, 0x26, + 0x02, 0x93, 0x11, 0xe7, 0x00, 0x23, 0x00, 0x93, 0x01, 0x33, 0x04, 0x26, + 0x00, 0x27, 0x02, 0x93, 0x0a, 0xe7, 0x03, 0x23, 0xc3, 0x46, 0x1e, 0x43, + 0x03, 0x21, 0x25, 0xe7, 0x01, 0x33, 0x1e, 0x43, 0x00, 0x22, 0x01, 0x21, + 0x20, 0xe7, 0x00, 0x23, 0x9a, 0x46, 0x80, 0x23, 0x00, 0x27, 0x1b, 0x03, + 0x09, 0x4a, 0x61, 0xe7, 0x80, 0x23, 0x49, 0x46, 0x1b, 0x03, 0x19, 0x42, + 0x00, 0xd1, 0xe2, 0xe0, 0x59, 0x46, 0x19, 0x42, 0x00, 0xd0, 0xde, 0xe0, + 0x0b, 0x43, 0x1b, 0x03, 0x17, 0x00, 0x1b, 0x0b, 0xa2, 0x46, 0x01, 0x4a, + 0x50, 0xe7, 0xc0, 0x46, 0xff, 0x07, 0x00, 0x00, 0x01, 0xfc, 0xff, 0xff, + 0xb8, 0x97, 0x00, 0x00, 0xff, 0x03, 0x00, 0x00, 0xff, 0xff, 0xff, 0xfe, + 0xfe, 0x07, 0x00, 0x00, 0xff, 0xff, 0x0f, 0x80, 0x0d, 0xfc, 0xff, 0xff, + 0x01, 0xf8, 0xff, 0xff, 0xf3, 0x03, 0x00, 0x00, 0xd9, 0x45, 0x00, 0xd9, + 0xcb, 0xe0, 0x00, 0xd1, 0xc6, 0xe0, 0x3c, 0x00, 0x48, 0x46, 0x00, 0x27, + 0x00, 0x9b, 0x01, 0x3b, 0x00, 0x93, 0x5b, 0x46, 0x16, 0x0e, 0x1b, 0x02, + 0x1e, 0x43, 0x13, 0x02, 0x98, 0x46, 0x33, 0x04, 0x1b, 0x0c, 0x99, 0x46, + 0x31, 0x0c, 0x01, 0x91, 0xff, 0xf7, 0x4c, 0xfa, 0x4a, 0x46, 0x42, 0x43, + 0x0b, 0x04, 0x21, 0x0c, 0x05, 0x00, 0x19, 0x43, 0x8a, 0x42, 0x07, 0xd9, + 0x89, 0x19, 0x01, 0x3d, 0x8e, 0x42, 0x03, 0xd8, 0x8a, 0x42, 0x01, 0xd9, + 0x85, 0x1e, 0x89, 0x19, 0x88, 0x1a, 0x01, 0x99, 0xff, 0xf7, 0x38, 0xfa, + 0x09, 0x04, 0x8c, 0x46, 0x4a, 0x46, 0x21, 0x04, 0x64, 0x46, 0x42, 0x43, + 0x09, 0x0c, 0x03, 0x00, 0x21, 0x43, 0x8a, 0x42, 0x04, 0xd9, 0x89, 0x19, + 0x01, 0x3b, 0x8e, 0x42, 0x00, 0xd8, 0xf1, 0xe0, 0x2d, 0x04, 0x1d, 0x43, + 0xab, 0x46, 0x43, 0x46, 0x89, 0x1a, 0x42, 0x46, 0x28, 0x0c, 0x12, 0x04, + 0x1d, 0x0c, 0x5b, 0x46, 0x14, 0x0c, 0x22, 0x00, 0x1b, 0x04, 0x1b, 0x0c, + 0x5a, 0x43, 0x03, 0x94, 0x6b, 0x43, 0x44, 0x43, 0x02, 0x95, 0x68, 0x43, + 0x1b, 0x19, 0x15, 0x0c, 0xeb, 0x18, 0x9c, 0x42, 0x03, 0xd9, 0x80, 0x24, + 0x64, 0x02, 0xa4, 0x46, 0x60, 0x44, 0x1c, 0x0c, 0x15, 0x04, 0x1b, 0x04, + 0x2d, 0x0c, 0x20, 0x18, 0x5d, 0x19, 0x81, 0x42, 0x77, 0xd3, 0x73, 0xd0, + 0x0c, 0x1a, 0xa2, 0x4a, 0x7d, 0x1b, 0xaf, 0x42, 0xbf, 0x41, 0x94, 0x46, + 0x00, 0x9b, 0x7f, 0x42, 0x63, 0x44, 0xe0, 0x1b, 0x1c, 0x00, 0x86, 0x42, + 0x00, 0xd1, 0xdb, 0xe0, 0x01, 0x99, 0xff, 0xf7, 0xf1, 0xf9, 0x4a, 0x46, + 0x42, 0x43, 0x0b, 0x04, 0x29, 0x0c, 0x07, 0x00, 0x19, 0x43, 0x8a, 0x42, + 0x07, 0xd9, 0x89, 0x19, 0x01, 0x3f, 0x8e, 0x42, 0x03, 0xd8, 0x8a, 0x42, + 0x01, 0xd9, 0x87, 0x1e, 0x89, 0x19, 0x88, 0x1a, 0x01, 0x99, 0xff, 0xf7, + 0xdd, 0xf9, 0x09, 0x04, 0x4a, 0x46, 0x89, 0x46, 0x29, 0x04, 0x4d, 0x46, + 0x42, 0x43, 0x09, 0x0c, 0x03, 0x00, 0x29, 0x43, 0x8a, 0x42, 0x07, 0xd9, + 0x89, 0x19, 0x01, 0x3b, 0x8e, 0x42, 0x03, 0xd8, 0x8a, 0x42, 0x01, 0xd9, + 0x83, 0x1e, 0x89, 0x19, 0x3f, 0x04, 0x89, 0x1a, 0x3a, 0x00, 0x03, 0x9f, + 0x1a, 0x43, 0x38, 0x00, 0x13, 0x04, 0x1b, 0x0c, 0x58, 0x43, 0x81, 0x46, + 0x02, 0x98, 0x15, 0x0c, 0x6f, 0x43, 0x43, 0x43, 0x45, 0x43, 0x48, 0x46, + 0x00, 0x0c, 0x84, 0x46, 0xdb, 0x19, 0x63, 0x44, 0x9f, 0x42, 0x03, 0xd9, + 0x80, 0x20, 0x40, 0x02, 0x84, 0x46, 0x65, 0x44, 0x48, 0x46, 0x1f, 0x0c, + 0x00, 0x04, 0x1b, 0x04, 0x00, 0x0c, 0x7d, 0x19, 0x18, 0x18, 0xa9, 0x42, + 0x00, 0xd2, 0x84, 0xe0, 0x00, 0xd1, 0x7f, 0xe0, 0x01, 0x23, 0x1a, 0x43, + 0x57, 0xe6, 0x80, 0x23, 0x4a, 0x46, 0x1b, 0x03, 0x13, 0x43, 0x1b, 0x03, + 0x1b, 0x0b, 0xaa, 0x46, 0x6f, 0x4a, 0x6f, 0xe6, 0xba, 0x42, 0x00, 0xd9, + 0x35, 0xe7, 0x4b, 0x46, 0xdc, 0x07, 0x58, 0x08, 0x7b, 0x08, 0x1c, 0x43, + 0xff, 0x07, 0x34, 0xe7, 0x00, 0x24, 0xaf, 0x42, 0x89, 0xd2, 0x47, 0x44, + 0x47, 0x45, 0xa4, 0x41, 0x5b, 0x46, 0x64, 0x42, 0xa4, 0x19, 0x64, 0x18, + 0x01, 0x3b, 0xa6, 0x42, 0x1e, 0xd2, 0xa0, 0x42, 0x6d, 0xd8, 0x00, 0xd1, + 0xb6, 0xe0, 0x24, 0x1a, 0x9b, 0x46, 0x78, 0xe7, 0x03, 0x00, 0x5a, 0x46, + 0x28, 0x3b, 0x9a, 0x40, 0x00, 0x27, 0x91, 0x46, 0x88, 0xe6, 0x58, 0x46, + 0x01, 0xf0, 0x02, 0xf8, 0x20, 0x30, 0x72, 0xe6, 0x03, 0x00, 0x52, 0x46, + 0x28, 0x3b, 0x9a, 0x40, 0x93, 0x46, 0x00, 0x22, 0xb4, 0xe6, 0x50, 0x46, + 0x00, 0xf0, 0xf6, 0xff, 0x20, 0x30, 0x9a, 0xe6, 0xa6, 0x42, 0xe2, 0xd1, + 0xb8, 0x45, 0xdc, 0xd9, 0x34, 0x1a, 0x9b, 0x46, 0x59, 0xe7, 0x1f, 0x2b, + 0x65, 0xdc, 0x50, 0x4c, 0x00, 0x99, 0xa4, 0x46, 0x5c, 0x46, 0x61, 0x44, + 0x08, 0x00, 0x8c, 0x40, 0x11, 0x00, 0x82, 0x40, 0xd9, 0x40, 0x50, 0x1e, + 0x82, 0x41, 0x0c, 0x43, 0x14, 0x43, 0x5a, 0x46, 0xda, 0x40, 0x13, 0x00, + 0x62, 0x07, 0x09, 0xd0, 0x0f, 0x22, 0x22, 0x40, 0x04, 0x2a, 0x05, 0xd0, + 0x22, 0x00, 0x14, 0x1d, 0x94, 0x42, 0x89, 0x41, 0x49, 0x42, 0x5b, 0x18, + 0x1a, 0x02, 0x62, 0xd5, 0x01, 0x22, 0x00, 0x23, 0x00, 0x27, 0x0d, 0xe6, + 0x8a, 0x42, 0x00, 0xd8, 0x0a, 0xe7, 0x83, 0x1e, 0x89, 0x19, 0x07, 0xe7, + 0x0f, 0x23, 0x13, 0x40, 0x04, 0x2b, 0x00, 0xd1, 0xe6, 0xe5, 0x17, 0x1d, + 0x97, 0x42, 0x92, 0x41, 0x53, 0x42, 0x9b, 0x44, 0xfa, 0x08, 0xe0, 0xe5, + 0x00, 0x28, 0x00, 0xd1, 0xd7, 0xe5, 0x71, 0x18, 0x53, 0x1e, 0xb1, 0x42, + 0x27, 0xd3, 0xa9, 0x42, 0x15, 0xd3, 0x58, 0xd0, 0x1a, 0x00, 0x73, 0xe7, + 0x00, 0x2b, 0x00, 0xdc, 0x04, 0xe6, 0x01, 0x23, 0x00, 0x22, 0x9b, 0x44, + 0xcd, 0xe5, 0x02, 0x23, 0x47, 0x44, 0x47, 0x45, 0x89, 0x41, 0x5b, 0x42, + 0x9c, 0x46, 0x49, 0x42, 0x89, 0x19, 0x0c, 0x19, 0xe3, 0x44, 0x24, 0x1a, + 0x03, 0xe7, 0x43, 0x46, 0x5f, 0x00, 0x47, 0x45, 0x9b, 0x41, 0xb8, 0x46, + 0x5b, 0x42, 0x9e, 0x19, 0x02, 0x3a, 0x89, 0x19, 0xa9, 0x42, 0x00, 0xd0, + 0x54, 0xe7, 0x40, 0x45, 0x00, 0xd0, 0x51, 0xe7, 0xab, 0xe5, 0x1a, 0x00, + 0xf6, 0xe7, 0x1f, 0x21, 0x5f, 0x46, 0x49, 0x42, 0x0c, 0x1b, 0xe7, 0x40, + 0x20, 0x2b, 0x07, 0xd0, 0x1a, 0x49, 0x00, 0x9b, 0x8c, 0x46, 0x63, 0x44, + 0x18, 0x00, 0x5b, 0x46, 0x83, 0x40, 0x1a, 0x43, 0x50, 0x1e, 0x82, 0x41, + 0x3a, 0x43, 0x07, 0x27, 0x00, 0x23, 0x17, 0x40, 0x09, 0xd0, 0x0f, 0x21, + 0x00, 0x23, 0x11, 0x40, 0x14, 0x00, 0x04, 0x29, 0x95, 0xd1, 0x22, 0x00, + 0x5f, 0x07, 0x5b, 0x02, 0x1b, 0x0b, 0xd2, 0x08, 0x17, 0x43, 0x00, 0x22, + 0xa6, 0xe5, 0x80, 0x23, 0x59, 0x46, 0x1b, 0x03, 0x0b, 0x43, 0x1b, 0x03, + 0x17, 0x00, 0x1b, 0x0b, 0x06, 0x4a, 0x9d, 0xe5, 0xbd, 0x42, 0xb2, 0xd8, + 0x9b, 0x46, 0x00, 0x24, 0xbf, 0xe6, 0x80, 0x45, 0xb9, 0xd3, 0x1a, 0x00, + 0xc3, 0xe7, 0xc0, 0x46, 0xff, 0x03, 0x00, 0x00, 0xff, 0x07, 0x00, 0x00, + 0x1e, 0x04, 0x00, 0x00, 0x3e, 0x04, 0x00, 0x00, 0xf0, 0xb5, 0x4f, 0x46, + 0x46, 0x46, 0xd6, 0x46, 0x84, 0x46, 0xc0, 0xb5, 0x80, 0x46, 0x19, 0x4e, + 0x18, 0x03, 0x0f, 0x03, 0x4d, 0x00, 0x00, 0x0b, 0x5c, 0x00, 0x82, 0x46, + 0x3f, 0x0b, 0x6d, 0x0d, 0xc9, 0x0f, 0x91, 0x46, 0x64, 0x0d, 0xdb, 0x0f, + 0x01, 0x20, 0xb5, 0x42, 0x0a, 0xd0, 0xb4, 0x42, 0x03, 0xd0, 0xa5, 0x42, + 0x01, 0xd1, 0x57, 0x45, 0x0c, 0xd0, 0x1c, 0xbc, 0x90, 0x46, 0x99, 0x46, + 0xa2, 0x46, 0xf0, 0xbd, 0x66, 0x46, 0x3e, 0x43, 0xf7, 0xd1, 0xac, 0x42, + 0xf5, 0xd1, 0x54, 0x46, 0x14, 0x43, 0xf2, 0xd1, 0x01, 0x20, 0xc8, 0x45, + 0xef, 0xd1, 0x99, 0x42, 0x07, 0xd0, 0x00, 0x2d, 0xeb, 0xd1, 0x63, 0x46, + 0x1f, 0x43, 0x38, 0x00, 0x47, 0x1e, 0xb8, 0x41, 0xe5, 0xe7, 0x00, 0x20, + 0xe3, 0xe7, 0xc0, 0x46, 0xff, 0x07, 0x00, 0x00, 0xf0, 0xb5, 0x4f, 0x46, + 0x46, 0x46, 0xd6, 0x46, 0x4d, 0x00, 0xc0, 0xb5, 0x0e, 0x03, 0xc9, 0x0f, + 0x8a, 0x46, 0x2c, 0x49, 0x1f, 0x03, 0x5c, 0x00, 0x80, 0x46, 0x36, 0x0b, + 0x6d, 0x0d, 0x91, 0x46, 0x3f, 0x0b, 0x64, 0x0d, 0xdb, 0x0f, 0x8d, 0x42, + 0x1e, 0xd0, 0x8c, 0x42, 0x16, 0xd0, 0x00, 0x2d, 0x1e, 0xd1, 0x30, 0x43, + 0x84, 0x46, 0x00, 0x2c, 0x01, 0xd1, 0x3a, 0x43, 0x23, 0xd0, 0x62, 0x46, + 0x00, 0x2a, 0x1a, 0xd0, 0x9a, 0x45, 0x29, 0xd0, 0x51, 0x46, 0x02, 0x20, + 0x01, 0x39, 0x08, 0x40, 0x01, 0x38, 0x1c, 0xbc, 0x90, 0x46, 0x99, 0x46, + 0xa2, 0x46, 0xf0, 0xbd, 0x39, 0x00, 0x11, 0x43, 0xe5, 0xd0, 0x02, 0x20, + 0x40, 0x42, 0xf4, 0xe7, 0x30, 0x43, 0xfa, 0xd1, 0xac, 0x42, 0x0f, 0xd0, + 0x00, 0x2c, 0x0f, 0xd1, 0x3a, 0x43, 0xe7, 0xd0, 0x0c, 0xe0, 0x01, 0x22, + 0x01, 0x3b, 0x93, 0x43, 0x18, 0x00, 0x01, 0x30, 0xe5, 0xe7, 0x63, 0x46, + 0x00, 0x20, 0x00, 0x2b, 0xe1, 0xd0, 0xdb, 0xe7, 0x3a, 0x43, 0xe6, 0xd1, + 0x9a, 0x45, 0xd7, 0xd1, 0xa5, 0x42, 0xd5, 0xdc, 0xa5, 0x42, 0x05, 0xdb, + 0xbe, 0x42, 0xd1, 0xd8, 0x08, 0xd0, 0x00, 0x20, 0xbe, 0x42, 0xd2, 0xd2, + 0x50, 0x46, 0x01, 0x23, 0x01, 0x38, 0x98, 0x43, 0x01, 0x30, 0xcc, 0xe7, + 0xc8, 0x45, 0xc5, 0xd8, 0x00, 0x20, 0xc8, 0x45, 0xf4, 0xd3, 0xc6, 0xe7, + 0xff, 0x07, 0x00, 0x00, 0xf0, 0xb5, 0x4f, 0x46, 0x46, 0x46, 0xd6, 0x46, + 0x4d, 0x00, 0xc0, 0xb5, 0x0e, 0x03, 0xc9, 0x0f, 0x8a, 0x46, 0x2e, 0x49, + 0x1f, 0x03, 0x5c, 0x00, 0x80, 0x46, 0x36, 0x0b, 0x6d, 0x0d, 0x91, 0x46, + 0x3f, 0x0b, 0x64, 0x0d, 0xdb, 0x0f, 0x8d, 0x42, 0x18, 0xd0, 0x8c, 0x42, + 0x11, 0xd0, 0x00, 0x2d, 0x18, 0xd1, 0x30, 0x43, 0x84, 0x46, 0x00, 0x2c, + 0x1e, 0xd1, 0x3a, 0x43, 0x1c, 0xd1, 0x63, 0x46, 0x00, 0x20, 0x00, 0x2b, + 0x30, 0xd0, 0x51, 0x46, 0x02, 0x20, 0x01, 0x39, 0x08, 0x40, 0x01, 0x38, + 0x2a, 0xe0, 0x39, 0x00, 0x11, 0x43, 0xea, 0xd0, 0x02, 0x20, 0x25, 0xe0, + 0x30, 0x43, 0xfb, 0xd1, 0xac, 0x42, 0x26, 0xd0, 0x00, 0x2c, 0x26, 0xd1, + 0x3a, 0x43, 0x24, 0xd1, 0x51, 0x46, 0x02, 0x20, 0x01, 0x39, 0x08, 0x40, + 0x01, 0x38, 0x17, 0xe0, 0x62, 0x46, 0x00, 0x2a, 0x0f, 0xd0, 0x9a, 0x45, + 0xe1, 0xd1, 0xa5, 0x42, 0x05, 0xdb, 0xbe, 0x42, 0xdd, 0xd8, 0x19, 0xd0, + 0x00, 0x20, 0xbe, 0x42, 0x0a, 0xd2, 0x50, 0x46, 0x01, 0x23, 0x01, 0x38, + 0x98, 0x43, 0x01, 0x30, 0x04, 0xe0, 0x01, 0x22, 0x01, 0x3b, 0x93, 0x43, + 0x18, 0x00, 0x01, 0x30, 0x1c, 0xbc, 0x90, 0x46, 0x99, 0x46, 0xa2, 0x46, + 0xf0, 0xbd, 0x3a, 0x43, 0xd0, 0xd1, 0x9a, 0x45, 0xc5, 0xd1, 0xa5, 0x42, + 0xc3, 0xdc, 0xe0, 0xe7, 0xc8, 0x45, 0xc0, 0xd8, 0x00, 0x20, 0xc8, 0x45, + 0xe3, 0xd3, 0xed, 0xe7, 0xff, 0x07, 0x00, 0x00, 0xf0, 0xb5, 0x57, 0x46, + 0xde, 0x46, 0x4e, 0x46, 0x45, 0x46, 0xe0, 0xb5, 0x83, 0x46, 0x06, 0x00, + 0x0f, 0x03, 0x48, 0x00, 0x87, 0xb0, 0x92, 0x46, 0x1d, 0x00, 0x3f, 0x0b, + 0x40, 0x0d, 0xcc, 0x0f, 0x00, 0x28, 0x00, 0xd1, 0x6f, 0xe0, 0xde, 0x4b, + 0x98, 0x42, 0x38, 0xd0, 0x80, 0x23, 0xff, 0x00, 0x1b, 0x04, 0x1f, 0x43, + 0x73, 0x0f, 0x3b, 0x43, 0x01, 0x93, 0xda, 0x4b, 0x00, 0x27, 0x99, 0x46, + 0x00, 0x23, 0x9b, 0x46, 0xf6, 0x00, 0x81, 0x44, 0x2b, 0x03, 0x69, 0x00, + 0x1b, 0x0b, 0x52, 0x46, 0x98, 0x46, 0x49, 0x0d, 0xed, 0x0f, 0x00, 0x29, + 0x00, 0xd1, 0x85, 0xe0, 0xd0, 0x4b, 0x99, 0x42, 0x00, 0xd1, 0x73, 0xe0, + 0x43, 0x46, 0xda, 0x00, 0x80, 0x23, 0x1b, 0x04, 0x13, 0x43, 0x52, 0x46, + 0xcc, 0x48, 0x52, 0x0f, 0x84, 0x46, 0x13, 0x43, 0x52, 0x46, 0x00, 0x20, + 0x61, 0x44, 0xd2, 0x00, 0x89, 0x44, 0x21, 0x00, 0x69, 0x40, 0x00, 0x91, + 0x8c, 0x46, 0x01, 0x21, 0x49, 0x44, 0x8a, 0x46, 0x0f, 0x2f, 0x00, 0xd9, + 0x90, 0xe0, 0xc4, 0x49, 0xbf, 0x00, 0xcf, 0x59, 0xbf, 0x46, 0x5b, 0x46, + 0x3b, 0x43, 0x01, 0x93, 0x00, 0xd0, 0x6a, 0xe1, 0x02, 0x23, 0x08, 0x27, + 0x00, 0x26, 0x81, 0x46, 0x9b, 0x46, 0xc9, 0xe7, 0x32, 0x00, 0x58, 0x46, + 0x01, 0x9b, 0x61, 0x46, 0x00, 0x91, 0x02, 0x28, 0x00, 0xd1, 0x75, 0xe0, + 0x03, 0x28, 0x00, 0xd1, 0xfe, 0xe1, 0x01, 0x28, 0x00, 0xd0, 0x2c, 0xe1, + 0x00, 0x23, 0x00, 0x27, 0x00, 0x26, 0x00, 0x25, 0x3f, 0x03, 0x2a, 0x0d, + 0x3f, 0x0b, 0xb3, 0x48, 0x12, 0x05, 0x3a, 0x43, 0x02, 0x40, 0x1b, 0x05, + 0x13, 0x43, 0x00, 0x9a, 0x5b, 0x00, 0xd1, 0x07, 0x5b, 0x08, 0x0b, 0x43, + 0x30, 0x00, 0x19, 0x00, 0x07, 0xb0, 0x3c, 0xbc, 0x90, 0x46, 0x99, 0x46, + 0xa2, 0x46, 0xab, 0x46, 0xf0, 0xbd, 0x5b, 0x46, 0x3b, 0x43, 0x01, 0x93, + 0x00, 0xd1, 0x2f, 0xe1, 0x00, 0x2f, 0x00, 0xd1, 0xa5, 0xe1, 0x38, 0x00, + 0x00, 0xf0, 0xb0, 0xfd, 0x03, 0x00, 0x0b, 0x3b, 0x1c, 0x2b, 0x00, 0xdd, + 0x96, 0xe1, 0x1d, 0x22, 0xd3, 0x1a, 0x5a, 0x46, 0x01, 0x00, 0xda, 0x40, + 0x5e, 0x46, 0x08, 0x39, 0x8f, 0x40, 0x13, 0x00, 0x8e, 0x40, 0x3b, 0x43, + 0x01, 0x93, 0x9c, 0x4b, 0x00, 0x27, 0x1b, 0x1a, 0x99, 0x46, 0x00, 0x23, + 0x9b, 0x46, 0x7d, 0xe7, 0x41, 0x46, 0x53, 0x46, 0x0b, 0x43, 0x93, 0x49, + 0x8c, 0x46, 0xe1, 0x44, 0x00, 0x2b, 0x00, 0xd0, 0x1a, 0xe1, 0x02, 0x22, + 0x02, 0x20, 0x17, 0x43, 0x00, 0x22, 0x8c, 0xe7, 0x13, 0x43, 0x00, 0xd1, + 0x0d, 0xe1, 0x43, 0x46, 0x00, 0x2b, 0x00, 0xd1, 0x81, 0xe1, 0x40, 0x46, + 0x00, 0xf0, 0x80, 0xfd, 0x02, 0x00, 0x0b, 0x3a, 0x1c, 0x2a, 0x00, 0xdd, + 0x72, 0xe1, 0x01, 0x00, 0x43, 0x46, 0x08, 0x39, 0x8b, 0x40, 0x98, 0x46, + 0x1d, 0x23, 0x9a, 0x1a, 0x53, 0x46, 0xd3, 0x40, 0x1a, 0x00, 0x43, 0x46, + 0x13, 0x43, 0x52, 0x46, 0x8a, 0x40, 0x49, 0x46, 0x08, 0x1a, 0x82, 0x49, + 0x89, 0x46, 0x81, 0x44, 0x00, 0x20, 0x68, 0xe7, 0x7b, 0x4b, 0x00, 0x27, + 0x00, 0x26, 0x8e, 0xe7, 0x14, 0x0c, 0x12, 0x04, 0x12, 0x0c, 0x11, 0x00, + 0x37, 0x0c, 0x36, 0x04, 0x35, 0x0c, 0x79, 0x43, 0x28, 0x00, 0x8c, 0x46, + 0x2e, 0x00, 0x60, 0x43, 0x60, 0x44, 0x83, 0x46, 0x56, 0x43, 0x21, 0x00, + 0x30, 0x0c, 0x80, 0x46, 0x58, 0x46, 0x79, 0x43, 0x40, 0x44, 0x02, 0x91, + 0x84, 0x45, 0x06, 0xd9, 0x88, 0x46, 0x80, 0x21, 0x49, 0x02, 0x8c, 0x46, + 0xe0, 0x44, 0x41, 0x46, 0x02, 0x91, 0x36, 0x04, 0x01, 0x0c, 0x36, 0x0c, + 0x00, 0x04, 0x8b, 0x46, 0x81, 0x19, 0x1e, 0x0c, 0x1b, 0x04, 0x1b, 0x0c, + 0x03, 0x91, 0x19, 0x00, 0x79, 0x43, 0x8c, 0x46, 0x28, 0x00, 0x75, 0x43, + 0x65, 0x44, 0xa8, 0x46, 0x58, 0x43, 0x05, 0x0c, 0x45, 0x44, 0x77, 0x43, + 0xa9, 0x42, 0x03, 0xd9, 0x80, 0x21, 0x49, 0x02, 0x8c, 0x46, 0x67, 0x44, + 0x29, 0x0c, 0x8c, 0x46, 0x39, 0x00, 0x00, 0x04, 0x00, 0x0c, 0x2d, 0x04, + 0x2d, 0x18, 0x61, 0x44, 0xab, 0x44, 0x05, 0x91, 0x59, 0x46, 0x04, 0x91, + 0x01, 0x99, 0x0f, 0x04, 0x3f, 0x0c, 0x08, 0x0c, 0x39, 0x00, 0x51, 0x43, + 0x42, 0x43, 0x90, 0x46, 0x02, 0x00, 0x8c, 0x46, 0x09, 0x0c, 0x8b, 0x46, + 0x62, 0x43, 0x7c, 0x43, 0x44, 0x44, 0x5c, 0x44, 0xa0, 0x45, 0x03, 0xd9, + 0x80, 0x21, 0x49, 0x02, 0x88, 0x46, 0x42, 0x44, 0x21, 0x0c, 0x88, 0x46, + 0x61, 0x46, 0x09, 0x04, 0x09, 0x0c, 0x8c, 0x46, 0x39, 0x00, 0x59, 0x43, + 0x43, 0x43, 0x70, 0x43, 0x7e, 0x43, 0x0f, 0x0c, 0xf6, 0x18, 0x24, 0x04, + 0xbe, 0x19, 0x64, 0x44, 0x42, 0x44, 0x8c, 0x46, 0xb3, 0x42, 0x03, 0xd9, + 0x80, 0x23, 0x5b, 0x02, 0x98, 0x46, 0x40, 0x44, 0x02, 0x9b, 0x61, 0x46, + 0x98, 0x46, 0x04, 0x9b, 0x37, 0x04, 0x43, 0x44, 0x9b, 0x46, 0xab, 0x45, + 0xad, 0x41, 0x6b, 0x42, 0x0d, 0x04, 0x05, 0x99, 0x2d, 0x0c, 0x8c, 0x46, + 0x7f, 0x19, 0x67, 0x44, 0xfd, 0x18, 0xa8, 0x46, 0x5d, 0x46, 0x2d, 0x19, + 0xa5, 0x42, 0xa4, 0x41, 0x93, 0x46, 0x64, 0x42, 0xa4, 0x46, 0xc3, 0x44, + 0xdc, 0x44, 0x8f, 0x42, 0xbf, 0x41, 0x98, 0x45, 0x9b, 0x41, 0x93, 0x45, + 0x92, 0x41, 0xa4, 0x45, 0xa4, 0x41, 0x5b, 0x42, 0x7f, 0x42, 0x1f, 0x43, + 0x36, 0x0c, 0x52, 0x42, 0x64, 0x42, 0xbf, 0x19, 0x22, 0x43, 0xbf, 0x18, + 0x62, 0x46, 0x38, 0x18, 0x43, 0x02, 0xd2, 0x0d, 0x03, 0x99, 0x13, 0x43, + 0x6a, 0x02, 0x0a, 0x43, 0x50, 0x1e, 0x82, 0x41, 0x61, 0x46, 0xed, 0x0d, + 0x2a, 0x43, 0x4e, 0x02, 0x32, 0x43, 0xd9, 0x01, 0x00, 0xd4, 0xb3, 0xe0, + 0x01, 0x26, 0x50, 0x08, 0x32, 0x40, 0x02, 0x43, 0xde, 0x07, 0x32, 0x43, + 0x5b, 0x08, 0x22, 0x4c, 0x54, 0x44, 0x00, 0x2c, 0x62, 0xdd, 0x51, 0x07, + 0x09, 0xd0, 0x0f, 0x20, 0x10, 0x40, 0x04, 0x28, 0x05, 0xd0, 0x10, 0x1d, + 0x90, 0x42, 0x92, 0x41, 0x52, 0x42, 0x9b, 0x18, 0x02, 0x00, 0xd9, 0x01, + 0x04, 0xd5, 0x80, 0x24, 0x19, 0x48, 0xe4, 0x00, 0x03, 0x40, 0x54, 0x44, + 0x18, 0x48, 0x84, 0x42, 0x00, 0xdd, 0x27, 0xe7, 0x5e, 0x07, 0x5b, 0x02, + 0xd2, 0x08, 0x1f, 0x0b, 0x63, 0x05, 0x16, 0x43, 0x5b, 0x0d, 0xb2, 0xe6, + 0x00, 0x23, 0x99, 0x46, 0x01, 0x33, 0x04, 0x27, 0x00, 0x26, 0x9b, 0x46, + 0x64, 0xe6, 0x03, 0x23, 0x01, 0x97, 0x81, 0x46, 0x0c, 0x27, 0x9b, 0x46, + 0x5e, 0xe6, 0x01, 0x22, 0x01, 0x20, 0x17, 0x43, 0x00, 0x22, 0x76, 0xe6, + 0x03, 0x23, 0x03, 0x20, 0x1f, 0x43, 0x43, 0x46, 0x71, 0xe6, 0xc0, 0x46, + 0xff, 0x07, 0x00, 0x00, 0x01, 0xfc, 0xff, 0xff, 0xf8, 0x97, 0x00, 0x00, + 0xff, 0xff, 0x0f, 0x80, 0x0d, 0xfc, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, + 0xff, 0xff, 0xff, 0xfe, 0xfe, 0x07, 0x00, 0x00, 0x00, 0x23, 0x80, 0x27, + 0x00, 0x93, 0x3f, 0x03, 0x00, 0x26, 0x43, 0x4b, 0x83, 0xe6, 0x01, 0x9b, + 0x32, 0x00, 0xa4, 0x46, 0x58, 0x46, 0x70, 0xe6, 0xac, 0x46, 0x6e, 0xe6, + 0x80, 0x27, 0x01, 0x99, 0x3f, 0x03, 0x39, 0x42, 0x2d, 0xd0, 0x3b, 0x42, + 0x2b, 0xd1, 0x1f, 0x43, 0x3f, 0x03, 0x3f, 0x0b, 0x00, 0x95, 0x16, 0x00, + 0x38, 0x4b, 0x6e, 0xe6, 0x01, 0x25, 0x2d, 0x1b, 0x38, 0x2d, 0x00, 0xdd, + 0x66, 0xe6, 0x1f, 0x2d, 0x40, 0xdc, 0x35, 0x48, 0x1c, 0x00, 0x50, 0x44, + 0x16, 0x00, 0x82, 0x40, 0x84, 0x40, 0xee, 0x40, 0x50, 0x1e, 0x82, 0x41, + 0x34, 0x43, 0x14, 0x43, 0xeb, 0x40, 0x62, 0x07, 0x09, 0xd0, 0x0f, 0x22, + 0x22, 0x40, 0x04, 0x2a, 0x05, 0xd0, 0x22, 0x00, 0x14, 0x1d, 0x94, 0x42, + 0x80, 0x41, 0x40, 0x42, 0x1b, 0x18, 0x1a, 0x02, 0x3e, 0xd5, 0x01, 0x23, + 0x00, 0x27, 0x00, 0x26, 0x49, 0xe6, 0x80, 0x27, 0x01, 0x9b, 0x3f, 0x03, + 0x1f, 0x43, 0x3f, 0x03, 0x3f, 0x0b, 0x00, 0x94, 0x21, 0x4b, 0x40, 0xe6, + 0x03, 0x00, 0x5a, 0x46, 0x28, 0x3b, 0x9a, 0x40, 0x00, 0x26, 0x01, 0x92, + 0x6d, 0xe6, 0x58, 0x46, 0x00, 0xf0, 0x0a, 0xfc, 0x20, 0x30, 0x57, 0xe6, + 0x03, 0x00, 0x52, 0x46, 0x28, 0x3b, 0x9a, 0x40, 0x13, 0x00, 0x00, 0x22, + 0x93, 0xe6, 0x50, 0x46, 0x00, 0xf0, 0xfe, 0xfb, 0x20, 0x30, 0x7b, 0xe6, + 0xca, 0x46, 0x50, 0xe7, 0x1f, 0x20, 0x1e, 0x00, 0x40, 0x42, 0x04, 0x1b, + 0xe6, 0x40, 0x20, 0x2d, 0x03, 0xd0, 0x12, 0x4c, 0x54, 0x44, 0xa3, 0x40, + 0x1a, 0x43, 0x50, 0x1e, 0x82, 0x41, 0x32, 0x43, 0x07, 0x26, 0x00, 0x27, + 0x16, 0x40, 0x09, 0xd0, 0x0f, 0x20, 0x00, 0x23, 0x10, 0x40, 0x14, 0x00, + 0x04, 0x28, 0xb9, 0xd1, 0x22, 0x00, 0x5e, 0x07, 0x5b, 0x02, 0x1f, 0x0b, + 0xd2, 0x08, 0x16, 0x43, 0x00, 0x23, 0x06, 0xe6, 0x80, 0x27, 0x3f, 0x03, + 0x1f, 0x43, 0x3f, 0x03, 0x3f, 0x0b, 0x16, 0x00, 0x00, 0x4b, 0xfe, 0xe5, + 0xff, 0x07, 0x00, 0x00, 0x1e, 0x04, 0x00, 0x00, 0x3e, 0x04, 0x00, 0x00, + 0xf8, 0xb5, 0x57, 0x46, 0x4e, 0x46, 0x45, 0x46, 0xde, 0x46, 0x0c, 0x00, + 0x09, 0x03, 0xe0, 0xb5, 0x49, 0x0a, 0x46, 0x0f, 0x5f, 0x00, 0x31, 0x43, + 0x1e, 0x03, 0xdb, 0x0f, 0x76, 0x0a, 0x9b, 0x46, 0x53, 0x0f, 0x33, 0x43, + 0xc8, 0x4e, 0x65, 0x00, 0xc0, 0x00, 0xe4, 0x0f, 0xd2, 0x00, 0x6d, 0x0d, + 0xa2, 0x46, 0x81, 0x46, 0x7f, 0x0d, 0x9c, 0x46, 0x90, 0x46, 0xb7, 0x42, + 0x00, 0xd1, 0xb9, 0xe0, 0x5b, 0x46, 0x01, 0x26, 0x73, 0x40, 0x9b, 0x46, + 0xee, 0x1b, 0xa3, 0x45, 0x00, 0xd1, 0x83, 0xe0, 0x00, 0x2e, 0x63, 0xdd, + 0x00, 0x2f, 0x00, 0xd0, 0xb1, 0xe0, 0x63, 0x46, 0x13, 0x43, 0x00, 0xd1, + 0x23, 0xe1, 0x73, 0x1e, 0x00, 0x2b, 0x00, 0xd0, 0xba, 0xe1, 0x86, 0x1a, + 0x63, 0x46, 0xb0, 0x42, 0x80, 0x41, 0x01, 0x25, 0xc9, 0x1a, 0x40, 0x42, + 0x09, 0x1a, 0x0b, 0x02, 0x00, 0xd4, 0x47, 0xe1, 0x49, 0x02, 0x4b, 0x0a, + 0x98, 0x46, 0x43, 0x46, 0x00, 0x2b, 0x00, 0xd1, 0x89, 0xe1, 0x40, 0x46, + 0x00, 0xf0, 0x82, 0xfb, 0x03, 0x00, 0x08, 0x3b, 0x1f, 0x2b, 0x00, 0xdd, + 0x7c, 0xe1, 0x20, 0x22, 0x30, 0x00, 0xd2, 0x1a, 0x41, 0x46, 0xd0, 0x40, + 0x99, 0x40, 0x02, 0x00, 0x9e, 0x40, 0x0a, 0x43, 0x9d, 0x42, 0x00, 0xdd, + 0x6a, 0xe1, 0x5d, 0x1b, 0x6b, 0x1c, 0x1f, 0x2b, 0x00, 0xdd, 0x94, 0xe1, + 0x20, 0x21, 0x10, 0x00, 0x35, 0x00, 0xc9, 0x1a, 0x8e, 0x40, 0xda, 0x40, + 0x88, 0x40, 0xdd, 0x40, 0x71, 0x1e, 0x8e, 0x41, 0x11, 0x00, 0x07, 0x22, + 0x28, 0x43, 0x00, 0x25, 0x06, 0x43, 0x32, 0x40, 0x00, 0x2a, 0x09, 0xd0, + 0x0f, 0x23, 0x33, 0x40, 0x04, 0x2b, 0x05, 0xd0, 0x33, 0x1d, 0xb3, 0x42, + 0xb6, 0x41, 0x76, 0x42, 0x89, 0x19, 0x1e, 0x00, 0x0b, 0x02, 0x00, 0xd4, + 0x3d, 0xe2, 0x6a, 0x1c, 0x91, 0x4b, 0x55, 0x05, 0x6d, 0x0d, 0x9a, 0x42, + 0x00, 0xd1, 0x19, 0xe1, 0x8f, 0x4a, 0xf6, 0x08, 0x0a, 0x40, 0x57, 0x07, + 0x52, 0x02, 0x37, 0x43, 0x12, 0x0b, 0x9b, 0xe0, 0x00, 0x2e, 0x00, 0xd0, + 0xc5, 0xe0, 0x6e, 0x1c, 0x76, 0x05, 0x76, 0x0d, 0x01, 0x2e, 0x00, 0xdc, + 0x48, 0xe1, 0x67, 0x46, 0x86, 0x1a, 0xcb, 0x1b, 0xb0, 0x42, 0xbf, 0x41, + 0x7f, 0x42, 0xb8, 0x46, 0x1f, 0x00, 0x43, 0x46, 0xff, 0x1a, 0x3b, 0x00, + 0xb8, 0x46, 0x1b, 0x02, 0x00, 0xd5, 0x5f, 0xe1, 0x37, 0x43, 0x9a, 0xd1, + 0x00, 0x22, 0x00, 0x24, 0x00, 0x25, 0x79, 0xe0, 0x00, 0x2e, 0x00, 0xdc, + 0xfa, 0xe0, 0x00, 0x2f, 0x00, 0xd1, 0x8d, 0xe0, 0x78, 0x4b, 0x9d, 0x42, + 0x67, 0xd0, 0x80, 0x23, 0x67, 0x46, 0x1b, 0x04, 0x1f, 0x43, 0xbc, 0x46, + 0x38, 0x2e, 0x00, 0xdc, 0x52, 0xe1, 0x63, 0x46, 0x13, 0x43, 0x5a, 0x1e, + 0x93, 0x41, 0x1e, 0x18, 0x86, 0x42, 0x80, 0x41, 0x40, 0x42, 0x09, 0x18, + 0x0b, 0x02, 0x00, 0xd4, 0xbe, 0xe0, 0x6d, 0x4b, 0x01, 0x35, 0x9d, 0x42, + 0x00, 0xd1, 0xd2, 0xe0, 0x6b, 0x4a, 0x73, 0x08, 0x0a, 0x40, 0x01, 0x21, + 0x0e, 0x40, 0x1e, 0x43, 0x51, 0x08, 0xd3, 0x07, 0x07, 0x22, 0x1e, 0x43, + 0x32, 0x40, 0x95, 0xe7, 0x1e, 0x00, 0x16, 0x43, 0x00, 0xd0, 0x45, 0xe7, + 0x40, 0xe7, 0x62, 0x4b, 0x9d, 0x42, 0x3a, 0xd0, 0x80, 0x23, 0x67, 0x46, + 0x1b, 0x04, 0x1f, 0x43, 0xbc, 0x46, 0x38, 0x2e, 0x00, 0xdd, 0xeb, 0xe0, + 0x1f, 0x2e, 0x00, 0xdc, 0x3a, 0xe1, 0x33, 0x00, 0x67, 0x46, 0x20, 0x3b, + 0xdf, 0x40, 0x3b, 0x00, 0x20, 0x2e, 0x05, 0xd0, 0x40, 0x27, 0xbf, 0x1b, + 0x66, 0x46, 0xbe, 0x40, 0x32, 0x43, 0x90, 0x46, 0x46, 0x46, 0x72, 0x1e, + 0x96, 0x41, 0x33, 0x43, 0xda, 0xe0, 0x00, 0x2b, 0x00, 0xd1, 0x14, 0xe2, + 0x63, 0x46, 0x13, 0x43, 0x00, 0xd1, 0x68, 0xe1, 0x80, 0x23, 0x4e, 0x07, + 0xc0, 0x08, 0xc9, 0x08, 0x1b, 0x03, 0x06, 0x43, 0x19, 0x42, 0x08, 0xd0, + 0x60, 0x46, 0xc0, 0x08, 0x18, 0x42, 0x04, 0xd1, 0x63, 0x46, 0x01, 0x00, + 0xd2, 0x08, 0x5e, 0x07, 0x16, 0x43, 0xf3, 0x00, 0x99, 0x46, 0xc9, 0x00, + 0x72, 0x0f, 0x44, 0x4d, 0x11, 0x43, 0x4b, 0x46, 0xde, 0x08, 0x42, 0x4b, + 0x4f, 0x07, 0x37, 0x43, 0xca, 0x08, 0x9d, 0x42, 0x00, 0xd1, 0x6e, 0xe0, + 0x12, 0x03, 0x6d, 0x05, 0x12, 0x0b, 0x6d, 0x0d, 0x00, 0x21, 0x12, 0x03, + 0x13, 0x0b, 0x0a, 0x0d, 0x12, 0x05, 0x1a, 0x43, 0x3b, 0x4b, 0x2d, 0x05, + 0x13, 0x40, 0x2b, 0x43, 0x5b, 0x00, 0xe4, 0x07, 0x5b, 0x08, 0x23, 0x43, + 0x38, 0x00, 0x19, 0x00, 0x3c, 0xbc, 0x90, 0x46, 0x99, 0x46, 0xa2, 0x46, + 0xab, 0x46, 0xf8, 0xbd, 0x63, 0x46, 0x13, 0x43, 0x11, 0xd0, 0x73, 0x1e, + 0x00, 0x2b, 0x00, 0xd0, 0x07, 0xe1, 0x86, 0x18, 0x86, 0x42, 0x80, 0x41, + 0x61, 0x44, 0x40, 0x42, 0x09, 0x18, 0x01, 0x25, 0x0b, 0x02, 0x37, 0xd5, + 0x02, 0x25, 0x7b, 0xe7, 0x3e, 0x00, 0x61, 0x46, 0x91, 0x46, 0x35, 0x00, + 0xc5, 0xe7, 0x5c, 0x46, 0x00, 0x2d, 0x00, 0xd0, 0xe1, 0xe0, 0x0b, 0x00, + 0x03, 0x43, 0xf3, 0xd0, 0x73, 0x1c, 0x00, 0xd1, 0xac, 0xe1, 0x21, 0x4b, + 0x9f, 0x42, 0x00, 0xd1, 0x3a, 0xe1, 0xf3, 0x43, 0x38, 0x2b, 0x00, 0xdd, + 0x6f, 0xe1, 0x1f, 0x2b, 0x00, 0xdd, 0x8c, 0xe1, 0x20, 0x25, 0x0e, 0x00, + 0xed, 0x1a, 0xae, 0x40, 0xb0, 0x46, 0x06, 0x00, 0xaa, 0x46, 0xde, 0x40, + 0x45, 0x46, 0x35, 0x43, 0x2e, 0x00, 0x55, 0x46, 0xd9, 0x40, 0xa8, 0x40, + 0x63, 0x46, 0x45, 0x1e, 0xa8, 0x41, 0x5b, 0x1a, 0x9c, 0x46, 0x30, 0x43, + 0x16, 0x1a, 0xb2, 0x42, 0x92, 0x41, 0x63, 0x46, 0x52, 0x42, 0x99, 0x1a, + 0x3d, 0x00, 0xb4, 0xe6, 0x07, 0x22, 0x32, 0x40, 0x00, 0x2a, 0x00, 0xd0, + 0xe4, 0xe6, 0x0b, 0x4b, 0xf6, 0x08, 0x4f, 0x07, 0x37, 0x43, 0xca, 0x08, + 0x9d, 0x42, 0x00, 0xd0, 0x90, 0xe7, 0x3b, 0x00, 0x13, 0x43, 0x00, 0xd1, + 0xa6, 0xe1, 0x80, 0x23, 0x1b, 0x03, 0x1a, 0x43, 0x12, 0x03, 0x12, 0x0b, + 0x02, 0x4d, 0x89, 0xe7, 0x15, 0x00, 0x00, 0x22, 0x00, 0x27, 0x85, 0xe7, + 0xff, 0x07, 0x00, 0x00, 0xff, 0xff, 0x7f, 0xff, 0xff, 0xff, 0x0f, 0x80, + 0x00, 0x2e, 0x00, 0xd0, 0xc7, 0xe0, 0x6b, 0x1c, 0x5e, 0x05, 0x76, 0x0d, + 0x01, 0x2e, 0x00, 0xdc, 0xf0, 0xe0, 0xc8, 0x4d, 0xab, 0x42, 0x00, 0xd1, + 0xb9, 0xe0, 0x85, 0x18, 0x0a, 0x00, 0x85, 0x42, 0x89, 0x41, 0x62, 0x44, + 0x49, 0x42, 0x51, 0x18, 0x07, 0x22, 0xce, 0x07, 0x6d, 0x08, 0x2e, 0x43, + 0x49, 0x08, 0x32, 0x40, 0x1d, 0x00, 0xa9, 0xe6, 0xbf, 0x49, 0xed, 0x1a, + 0x11, 0x40, 0x07, 0x22, 0x32, 0x40, 0xa3, 0xe6, 0x32, 0x00, 0x28, 0x38, + 0x82, 0x40, 0x00, 0x26, 0x86, 0xe6, 0x30, 0x00, 0x00, 0xf0, 0xf8, 0xf9, + 0x20, 0x30, 0x73, 0xe6, 0x63, 0x46, 0x13, 0x43, 0x5a, 0x1e, 0x93, 0x41, + 0xc6, 0x1a, 0xb0, 0x42, 0x80, 0x41, 0x40, 0x42, 0x09, 0x1a, 0x5c, 0xe6, + 0x0e, 0x00, 0x67, 0x46, 0x06, 0x43, 0x17, 0x43, 0x00, 0x2d, 0x5e, 0xd1, + 0x00, 0x2e, 0x00, 0xd0, 0xf3, 0xe0, 0x00, 0x2f, 0x00, 0xd1, 0x1e, 0xe1, + 0x5c, 0x46, 0x61, 0x46, 0x91, 0x46, 0x2c, 0xe7, 0xa9, 0x4f, 0xbe, 0x42, + 0x7b, 0xd0, 0x1e, 0x00, 0xf1, 0xe6, 0x10, 0x00, 0x1f, 0x3d, 0xe8, 0x40, + 0x20, 0x2b, 0x03, 0xd0, 0x40, 0x21, 0xcb, 0x1a, 0x9a, 0x40, 0x16, 0x43, + 0x73, 0x1e, 0x9e, 0x41, 0x07, 0x22, 0x06, 0x43, 0x32, 0x40, 0x00, 0x21, + 0x00, 0x25, 0x83, 0xe7, 0x16, 0x1a, 0x63, 0x46, 0xb2, 0x42, 0x80, 0x41, + 0x59, 0x1a, 0x40, 0x42, 0x0b, 0x1a, 0x98, 0x46, 0x5c, 0x46, 0x32, 0xe6, + 0x1f, 0x2e, 0x00, 0xdd, 0xab, 0xe0, 0x20, 0x27, 0xbb, 0x1b, 0x9a, 0x46, + 0x63, 0x46, 0x57, 0x46, 0xbb, 0x40, 0x99, 0x46, 0x13, 0x00, 0x4f, 0x46, + 0xf3, 0x40, 0x1f, 0x43, 0x3b, 0x00, 0x57, 0x46, 0xba, 0x40, 0x57, 0x1e, + 0xba, 0x41, 0x13, 0x43, 0x62, 0x46, 0xf2, 0x40, 0x89, 0x18, 0x98, 0xe6, + 0x20, 0x27, 0xbb, 0x1b, 0x9a, 0x46, 0x63, 0x46, 0x57, 0x46, 0xbb, 0x40, + 0x99, 0x46, 0x13, 0x00, 0x4f, 0x46, 0xf3, 0x40, 0x1f, 0x43, 0x3b, 0x00, + 0x57, 0x46, 0xba, 0x40, 0x57, 0x1e, 0xba, 0x41, 0x13, 0x43, 0x62, 0x46, + 0xf2, 0x40, 0x89, 0x1a, 0x9c, 0xe7, 0x83, 0x4b, 0x9f, 0x42, 0x5f, 0xd0, + 0x80, 0x25, 0x2d, 0x04, 0x73, 0x42, 0x29, 0x43, 0x20, 0xe7, 0x00, 0x2e, + 0x0c, 0xd1, 0x00, 0x2f, 0x00, 0xd1, 0xd0, 0xe0, 0x5c, 0x46, 0x61, 0x46, + 0x91, 0x46, 0x7b, 0x4d, 0xcd, 0xe6, 0x7a, 0x4f, 0xbe, 0x42, 0x1c, 0xd0, + 0x1e, 0x00, 0x65, 0xe6, 0x00, 0x2f, 0x18, 0xd0, 0xc0, 0x08, 0x4e, 0x07, + 0x06, 0x43, 0x80, 0x20, 0xc9, 0x08, 0x00, 0x03, 0x01, 0x42, 0x08, 0xd0, + 0x63, 0x46, 0xdc, 0x08, 0x04, 0x42, 0x04, 0xd1, 0x21, 0x00, 0xda, 0x46, + 0xd2, 0x08, 0x5e, 0x07, 0x16, 0x43, 0xf3, 0x00, 0x99, 0x46, 0x01, 0x24, + 0x53, 0x46, 0xc9, 0x00, 0x72, 0x0f, 0x11, 0x43, 0x1c, 0x40, 0x6a, 0x4d, + 0xab, 0xe6, 0x1d, 0x00, 0x00, 0x22, 0x00, 0x27, 0xb4, 0xe6, 0x00, 0x2d, + 0x59, 0xd1, 0x0b, 0x00, 0x03, 0x43, 0x00, 0xd1, 0xd6, 0xe6, 0x73, 0x1c, + 0x00, 0xd1, 0xb2, 0xe0, 0x62, 0x4b, 0x9f, 0x42, 0x1e, 0xd0, 0xf3, 0x43, + 0x38, 0x2b, 0x6f, 0xdc, 0x1f, 0x2b, 0x00, 0xdd, 0x97, 0xe0, 0x20, 0x25, + 0x0e, 0x00, 0xed, 0x1a, 0xae, 0x40, 0xb0, 0x46, 0x06, 0x00, 0xaa, 0x46, + 0xde, 0x40, 0x45, 0x46, 0x35, 0x43, 0x2e, 0x00, 0x55, 0x46, 0xa8, 0x40, + 0xd9, 0x40, 0x45, 0x1e, 0xa8, 0x41, 0x8c, 0x44, 0x06, 0x43, 0xb6, 0x18, + 0x96, 0x42, 0x92, 0x41, 0x51, 0x42, 0x61, 0x44, 0x3d, 0x00, 0x25, 0xe6, + 0x3d, 0x00, 0x61, 0x46, 0x91, 0x46, 0x78, 0xe6, 0x0b, 0x00, 0x03, 0x43, + 0x00, 0x2d, 0x00, 0xd0, 0x55, 0xe6, 0x00, 0x2b, 0xf5, 0xd0, 0x63, 0x46, + 0x13, 0x43, 0x00, 0xd1, 0x6d, 0xe6, 0x86, 0x18, 0x86, 0x42, 0x80, 0x41, + 0x61, 0x44, 0x40, 0x42, 0x09, 0x18, 0x00, 0x22, 0x0b, 0x02, 0x00, 0xd4, + 0xd0, 0xe6, 0x46, 0x4b, 0x01, 0x35, 0x19, 0x40, 0xb2, 0xe5, 0xb1, 0x46, + 0x5d, 0xe6, 0x33, 0x00, 0x67, 0x46, 0x20, 0x3b, 0xdf, 0x40, 0x3b, 0x00, + 0x20, 0x2e, 0x05, 0xd0, 0x40, 0x27, 0xbf, 0x1b, 0x66, 0x46, 0xbe, 0x40, + 0x32, 0x43, 0x90, 0x46, 0x46, 0x46, 0x72, 0x1e, 0x96, 0x41, 0x33, 0x43, + 0xef, 0xe5, 0x39, 0x4b, 0x9f, 0x42, 0xcb, 0xd0, 0x80, 0x25, 0x2d, 0x04, + 0x73, 0x42, 0x29, 0x43, 0xa8, 0xe7, 0x08, 0x43, 0x41, 0x1e, 0x88, 0x41, + 0xa2, 0xe6, 0x00, 0x2f, 0x00, 0xd1, 0x3c, 0xe6, 0x63, 0x46, 0x86, 0x1a, + 0xcf, 0x1a, 0xb0, 0x42, 0x9b, 0x41, 0x5b, 0x42, 0xfb, 0x1a, 0x98, 0x46, + 0x1b, 0x02, 0x4e, 0xd5, 0x16, 0x1a, 0x63, 0x46, 0xb2, 0x42, 0x92, 0x41, + 0x59, 0x1a, 0x52, 0x42, 0x89, 0x1a, 0x5c, 0x46, 0x00, 0x22, 0x7b, 0xe5, + 0x01, 0x43, 0x0e, 0x00, 0x71, 0x1e, 0x8e, 0x41, 0x9f, 0xe7, 0x1d, 0x00, + 0x0e, 0x00, 0x20, 0x3d, 0xee, 0x40, 0xb0, 0x46, 0x20, 0x2b, 0x04, 0xd0, + 0x40, 0x25, 0xeb, 0x1a, 0x99, 0x40, 0x08, 0x43, 0x81, 0x46, 0x48, 0x46, + 0x43, 0x46, 0x41, 0x1e, 0x88, 0x41, 0x18, 0x43, 0x74, 0xe6, 0x00, 0x22, + 0x00, 0x24, 0x17, 0xe6, 0x16, 0x1a, 0x63, 0x46, 0xb2, 0x42, 0x92, 0x41, + 0x59, 0x1a, 0x52, 0x42, 0x89, 0x1a, 0x3d, 0x00, 0x25, 0xe5, 0x61, 0x46, + 0x91, 0x46, 0x15, 0x4d, 0x01, 0xe6, 0x80, 0x22, 0x00, 0x24, 0x12, 0x03, + 0x79, 0xe6, 0x1d, 0x00, 0x0e, 0x00, 0x20, 0x3d, 0xee, 0x40, 0xb0, 0x46, + 0x20, 0x2b, 0x04, 0xd0, 0x40, 0x25, 0xeb, 0x1a, 0x99, 0x40, 0x08, 0x43, + 0x81, 0x46, 0x4e, 0x46, 0x43, 0x46, 0x71, 0x1e, 0x8e, 0x41, 0x1e, 0x43, + 0x67, 0xe7, 0x86, 0x18, 0x96, 0x42, 0x9b, 0x41, 0x61, 0x44, 0x5b, 0x42, + 0xc9, 0x18, 0x3d, 0x00, 0x8c, 0xe5, 0x47, 0x46, 0x37, 0x43, 0xce, 0xd0, + 0x07, 0x22, 0x41, 0x46, 0x32, 0x40, 0x49, 0xe6, 0x00, 0x27, 0x3a, 0x00, + 0xe6, 0xe5, 0xc0, 0x46, 0xff, 0x07, 0x00, 0x00, 0xff, 0xff, 0x7f, 0xff, + 0x70, 0xb5, 0x0c, 0x4e, 0x0d, 0x03, 0x1c, 0x03, 0x49, 0x00, 0x5b, 0x00, + 0x2d, 0x0b, 0x49, 0x0d, 0x24, 0x0b, 0x5b, 0x0d, 0xb1, 0x42, 0x08, 0xd0, + 0x06, 0x49, 0x00, 0x20, 0x8b, 0x42, 0x03, 0xd1, 0x14, 0x43, 0x20, 0x00, + 0x44, 0x1e, 0xa0, 0x41, 0x70, 0xbd, 0x05, 0x43, 0x01, 0x20, 0x00, 0x2d, + 0xfa, 0xd1, 0xf1, 0xe7, 0xff, 0x07, 0x00, 0x00, 0x30, 0xb5, 0x14, 0x4d, + 0x0a, 0x03, 0x4b, 0x00, 0x12, 0x0b, 0x5b, 0x0d, 0xc9, 0x0f, 0x00, 0x24, + 0xab, 0x42, 0x11, 0xdd, 0x10, 0x4c, 0xa3, 0x42, 0x10, 0xdc, 0x80, 0x24, + 0x64, 0x03, 0x22, 0x43, 0x0e, 0x4c, 0xe4, 0x1a, 0x1f, 0x2c, 0x0c, 0xdd, + 0x0d, 0x48, 0xc3, 0x1a, 0xda, 0x40, 0x13, 0x00, 0x5c, 0x42, 0x00, 0x29, + 0x00, 0xd1, 0x1c, 0x00, 0x20, 0x00, 0x30, 0xbd, 0x09, 0x4b, 0xcc, 0x18, + 0xfa, 0xe7, 0x09, 0x4d, 0xe0, 0x40, 0xac, 0x46, 0x63, 0x44, 0x9a, 0x40, + 0x13, 0x00, 0x03, 0x43, 0xee, 0xe7, 0xc0, 0x46, 0xfe, 0x03, 0x00, 0x00, + 0x1d, 0x04, 0x00, 0x00, 0x33, 0x04, 0x00, 0x00, 0x13, 0x04, 0x00, 0x00, + 0xff, 0xff, 0xff, 0x7f, 0xed, 0xfb, 0xff, 0xff, 0x10, 0xb5, 0x04, 0x1e, + 0x25, 0xd0, 0x00, 0xf0, 0x2d, 0xf8, 0x14, 0x4b, 0x1b, 0x1a, 0x5b, 0x05, + 0x5b, 0x0d, 0x0a, 0x28, 0x12, 0xdd, 0x0b, 0x38, 0x84, 0x40, 0x00, 0x22, + 0x24, 0x03, 0x24, 0x0b, 0x00, 0x21, 0x10, 0x00, 0x24, 0x03, 0x0a, 0x0d, + 0x24, 0x0b, 0x12, 0x05, 0x22, 0x43, 0x0c, 0x4c, 0x1b, 0x05, 0x22, 0x40, + 0x13, 0x43, 0x5b, 0x00, 0x59, 0x08, 0x10, 0xbd, 0x02, 0x00, 0x21, 0x00, + 0x15, 0x32, 0x91, 0x40, 0x0a, 0x00, 0x0b, 0x21, 0x08, 0x1a, 0xc4, 0x40, + 0x24, 0x03, 0x24, 0x0b, 0xe6, 0xe7, 0x00, 0x23, 0x00, 0x24, 0x00, 0x22, + 0xe2, 0xe7, 0xc0, 0x46, 0x1e, 0x04, 0x00, 0x00, 0xff, 0xff, 0x0f, 0x80, + 0x1c, 0x21, 0x01, 0x23, 0x1b, 0x04, 0x98, 0x42, 0x01, 0xd3, 0x00, 0x0c, + 0x10, 0x39, 0x1b, 0x0a, 0x98, 0x42, 0x01, 0xd3, 0x00, 0x0a, 0x08, 0x39, + 0x1b, 0x09, 0x98, 0x42, 0x01, 0xd3, 0x00, 0x09, 0x04, 0x39, 0x02, 0xa2, + 0x10, 0x5c, 0x40, 0x18, 0x70, 0x47, 0xc0, 0x46, 0x04, 0x03, 0x02, 0x02, + 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x0a, 0x22, 0x00, 0x21, 0x00, 0xf0, 0xa1, 0xfe, 0x10, 0xbd, + 0x10, 0xb5, 0x04, 0x00, 0x04, 0x48, 0x13, 0x00, 0x00, 0x28, 0x04, 0xd0, + 0x0a, 0x00, 0x02, 0x20, 0x21, 0x00, 0x00, 0xe0, 0x00, 0xbf, 0x10, 0xbd, + 0x00, 0x00, 0x00, 0x00, 0x70, 0xb5, 0x00, 0x26, 0x0c, 0x4d, 0x0d, 0x4c, + 0x64, 0x1b, 0xa4, 0x10, 0xa6, 0x42, 0x09, 0xd1, 0x00, 0x26, 0x02, 0xf0, + 0x29, 0xfa, 0x0a, 0x4d, 0x0a, 0x4c, 0x64, 0x1b, 0xa4, 0x10, 0xa6, 0x42, + 0x05, 0xd1, 0x70, 0xbd, 0xb3, 0x00, 0xeb, 0x58, 0x98, 0x47, 0x01, 0x36, + 0xee, 0xe7, 0xb3, 0x00, 0xeb, 0x58, 0x98, 0x47, 0x01, 0x36, 0xf2, 0xe7, + 0xf8, 0x01, 0x00, 0x20, 0xf8, 0x01, 0x00, 0x20, 0xf8, 0x01, 0x00, 0x20, + 0x2c, 0x02, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, 0x00, 0xf0, 0x08, 0xf8, + 0x08, 0x23, 0x00, 0x19, 0x40, 0x78, 0x18, 0x40, 0x10, 0xbd, 0xec, 0x30, + 0x00, 0x68, 0x70, 0x47, 0x04, 0x4b, 0x1b, 0x68, 0x1b, 0x6a, 0x00, 0x2b, + 0x00, 0xd1, 0x03, 0x4b, 0xec, 0x33, 0x18, 0x68, 0x70, 0x47, 0xc0, 0x46, + 0x28, 0x00, 0x00, 0x20, 0x8c, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x03, 0x4b, + 0x01, 0x00, 0x18, 0x68, 0x00, 0xf0, 0x8e, 0xf8, 0x10, 0xbd, 0xc0, 0x46, + 0x28, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x03, 0x4b, 0x01, 0x00, 0x18, 0x68, + 0x00, 0xf0, 0x3a, 0xf8, 0x10, 0xbd, 0xc0, 0x46, 0x28, 0x00, 0x00, 0x20, + 0x82, 0xb0, 0x00, 0x29, 0x00, 0xd1, 0x01, 0xa9, 0x10, 0x1e, 0x06, 0xd0, + 0x00, 0x2b, 0x06, 0xd0, 0x13, 0x78, 0x0b, 0x60, 0x10, 0x78, 0x43, 0x1e, + 0x98, 0x41, 0x02, 0xb0, 0x70, 0x47, 0x02, 0x20, 0x40, 0x42, 0xfa, 0xe7, + 0x00, 0x23, 0x10, 0xb5, 0x9a, 0x42, 0x00, 0xd1, 0x10, 0xbd, 0xcc, 0x5c, + 0xc4, 0x54, 0x01, 0x33, 0xf8, 0xe7, 0x10, 0xb5, 0x88, 0x42, 0x02, 0xd9, + 0x8b, 0x18, 0x98, 0x42, 0x03, 0xd3, 0x00, 0x23, 0x07, 0xe0, 0x8b, 0x5c, + 0x83, 0x54, 0x01, 0x3a, 0xfb, 0xd2, 0x10, 0xbd, 0xcc, 0x5c, 0xc4, 0x54, + 0x01, 0x33, 0x9a, 0x42, 0xfa, 0xd1, 0xf8, 0xe7, 0x03, 0x00, 0x12, 0x18, + 0x93, 0x42, 0x00, 0xd1, 0x70, 0x47, 0x19, 0x70, 0x01, 0x33, 0xf9, 0xe7, + 0x70, 0xb5, 0x05, 0x00, 0x00, 0x29, 0x10, 0xd0, 0x0c, 0x1f, 0x23, 0x68, + 0x00, 0x2b, 0x00, 0xda, 0xe4, 0x18, 0x28, 0x00, 0x01, 0xf0, 0xd3, 0xfc, + 0x1d, 0x4a, 0x13, 0x68, 0x00, 0x2b, 0x05, 0xd1, 0x63, 0x60, 0x14, 0x60, + 0x28, 0x00, 0x01, 0xf0, 0xcb, 0xfc, 0x70, 0xbd, 0xa3, 0x42, 0x09, 0xd9, + 0x21, 0x68, 0x60, 0x18, 0x83, 0x42, 0xf3, 0xd1, 0x18, 0x68, 0x5b, 0x68, + 0x41, 0x18, 0x21, 0x60, 0xee, 0xe7, 0x13, 0x00, 0x5a, 0x68, 0x00, 0x2a, + 0x01, 0xd0, 0xa2, 0x42, 0xf9, 0xd9, 0x19, 0x68, 0x58, 0x18, 0xa0, 0x42, + 0x0b, 0xd1, 0x20, 0x68, 0x09, 0x18, 0x58, 0x18, 0x19, 0x60, 0x82, 0x42, + 0xe0, 0xd1, 0x10, 0x68, 0x52, 0x68, 0x41, 0x18, 0x19, 0x60, 0x5a, 0x60, + 0xda, 0xe7, 0xa0, 0x42, 0x02, 0xd9, 0x0c, 0x23, 0x2b, 0x60, 0xd5, 0xe7, + 0x21, 0x68, 0x60, 0x18, 0x82, 0x42, 0x03, 0xd1, 0x10, 0x68, 0x52, 0x68, + 0x41, 0x18, 0x21, 0x60, 0x62, 0x60, 0x5c, 0x60, 0xca, 0xe7, 0xc0, 0x46, + 0x4c, 0x26, 0x00, 0x20, 0x03, 0x23, 0x70, 0xb5, 0xcd, 0x1c, 0x9d, 0x43, + 0x08, 0x35, 0x06, 0x00, 0x0c, 0x2d, 0x1e, 0xd2, 0x0c, 0x25, 0xa9, 0x42, + 0x1d, 0xd8, 0x30, 0x00, 0x01, 0xf0, 0x87, 0xfc, 0x25, 0x4a, 0x14, 0x68, + 0x21, 0x00, 0x00, 0x29, 0x19, 0xd1, 0x24, 0x4c, 0x23, 0x68, 0x00, 0x2b, + 0x03, 0xd1, 0x30, 0x00, 0x00, 0xf0, 0xac, 0xfc, 0x20, 0x60, 0x29, 0x00, + 0x30, 0x00, 0x00, 0xf0, 0xa7, 0xfc, 0x43, 0x1c, 0x2b, 0xd1, 0x0c, 0x23, + 0x30, 0x00, 0x33, 0x60, 0x01, 0xf0, 0x70, 0xfc, 0x03, 0xe0, 0x00, 0x2d, + 0xdf, 0xda, 0x0c, 0x23, 0x33, 0x60, 0x00, 0x20, 0x70, 0xbd, 0x0b, 0x68, + 0x5b, 0x1b, 0x19, 0xd4, 0x0b, 0x2b, 0x03, 0xd9, 0x0b, 0x60, 0xcc, 0x18, + 0x25, 0x60, 0x03, 0xe0, 0x4b, 0x68, 0x8c, 0x42, 0x0d, 0xd1, 0x13, 0x60, + 0x30, 0x00, 0x01, 0xf0, 0x59, 0xfc, 0x20, 0x00, 0x07, 0x22, 0x0b, 0x30, + 0x23, 0x1d, 0x90, 0x43, 0xc3, 0x1a, 0xe7, 0xd0, 0x5a, 0x42, 0xe2, 0x50, + 0xe4, 0xe7, 0x63, 0x60, 0x0c, 0x00, 0xef, 0xe7, 0x0c, 0x00, 0x49, 0x68, + 0xc3, 0xe7, 0x03, 0x23, 0xc4, 0x1c, 0x9c, 0x43, 0xa0, 0x42, 0xe1, 0xd0, + 0x21, 0x1a, 0x30, 0x00, 0x00, 0xf0, 0x70, 0xfc, 0x43, 0x1c, 0xdb, 0xd1, + 0xc7, 0xe7, 0xc0, 0x46, 0x4c, 0x26, 0x00, 0x20, 0x50, 0x26, 0x00, 0x20, + 0xf0, 0xb5, 0x8b, 0xb0, 0x14, 0x00, 0x1d, 0x1e, 0x12, 0x99, 0x53, 0xda, + 0x80, 0x24, 0x24, 0x06, 0x1b, 0x19, 0x1d, 0x00, 0x14, 0x00, 0x2d, 0x23, + 0x0b, 0x70, 0x20, 0x23, 0x14, 0x9e, 0x03, 0x22, 0x9e, 0x43, 0x46, 0x2e, + 0x07, 0xd0, 0x33, 0x00, 0x45, 0x3b, 0x59, 0x42, 0x4b, 0x41, 0x10, 0x99, + 0x01, 0x3a, 0xcb, 0x18, 0x10, 0x93, 0x09, 0xab, 0x04, 0x93, 0x08, 0xab, + 0x03, 0x93, 0x13, 0x9b, 0x00, 0x92, 0x02, 0x93, 0x10, 0x9b, 0x22, 0x00, + 0x01, 0x93, 0x2b, 0x00, 0x00, 0xf0, 0x18, 0xfe, 0x07, 0x00, 0x47, 0x2e, + 0x02, 0xd1, 0x11, 0x9b, 0xdb, 0x07, 0x24, 0xd5, 0x10, 0x9b, 0xfb, 0x18, + 0x07, 0x93, 0x46, 0x2e, 0x14, 0xd1, 0x3b, 0x78, 0x30, 0x2b, 0x0c, 0xd1, + 0x00, 0x22, 0x00, 0x23, 0x20, 0x00, 0x29, 0x00, 0xfe, 0xf7, 0xd0, 0xf8, + 0x00, 0x28, 0x04, 0xd1, 0x01, 0x23, 0x10, 0x9a, 0x9b, 0x1a, 0x13, 0x9a, + 0x13, 0x60, 0x13, 0x9b, 0x07, 0x9a, 0x1b, 0x68, 0xd3, 0x18, 0x07, 0x93, + 0x00, 0x22, 0x00, 0x23, 0x20, 0x00, 0x29, 0x00, 0xfe, 0xf7, 0xbe, 0xf8, + 0x30, 0x22, 0x00, 0x28, 0x0d, 0xd0, 0x07, 0x9b, 0x09, 0x93, 0x38, 0x00, + 0x09, 0x9b, 0x15, 0x9a, 0xdb, 0x1b, 0x13, 0x60, 0x0b, 0xb0, 0xf0, 0xbd, + 0x00, 0x23, 0xaf, 0xe7, 0x59, 0x1c, 0x09, 0x91, 0x1a, 0x70, 0x09, 0x9b, + 0x07, 0x99, 0x8b, 0x42, 0xf8, 0xd3, 0xee, 0xe7, 0xf0, 0xb5, 0x83, 0x1c, + 0x85, 0xb0, 0x01, 0x93, 0x06, 0x00, 0x0c, 0x00, 0x02, 0x70, 0x2b, 0x23, + 0x00, 0x29, 0x01, 0xda, 0x2d, 0x23, 0x4c, 0x42, 0x73, 0x70, 0x09, 0x2c, + 0x22, 0xdd, 0x02, 0xab, 0xdd, 0x1d, 0x20, 0x00, 0x0a, 0x21, 0xfe, 0xf7, + 0x7d, 0xf8, 0x6f, 0x1e, 0x30, 0x31, 0x39, 0x70, 0x20, 0x00, 0x0a, 0x21, + 0xfd, 0xf7, 0x90, 0xff, 0x04, 0x00, 0x09, 0x28, 0x0b, 0xdc, 0x02, 0x3d, + 0x30, 0x34, 0x01, 0x9b, 0x2c, 0x70, 0x02, 0xaa, 0x07, 0x32, 0x18, 0x00, + 0xaa, 0x42, 0x04, 0xd8, 0x80, 0x1b, 0x05, 0xb0, 0xf0, 0xbd, 0x3d, 0x00, + 0xe3, 0xe7, 0x2a, 0x78, 0x01, 0x35, 0x1a, 0x70, 0x01, 0x33, 0xf0, 0xe7, + 0x30, 0x23, 0xe4, 0x18, 0xb3, 0x70, 0x30, 0x1d, 0xf4, 0x70, 0xef, 0xe7, + 0xf0, 0xb5, 0x95, 0xb0, 0x0c, 0x00, 0x0a, 0x92, 0x0b, 0x93, 0x1a, 0x9d, + 0x09, 0x90, 0x01, 0xf0, 0x7b, 0xfb, 0x03, 0x68, 0x18, 0x00, 0x0c, 0x93, + 0x00, 0xf0, 0xf0, 0xfb, 0x00, 0x23, 0x12, 0x93, 0x23, 0x68, 0x0e, 0x90, + 0x0d, 0x93, 0x0d, 0x99, 0x27, 0x7e, 0x2b, 0x68, 0x07, 0x22, 0xc9, 0x05, + 0x45, 0xd5, 0x9b, 0x18, 0x93, 0x43, 0x1a, 0x00, 0x08, 0x32, 0x2a, 0x60, + 0x1a, 0x68, 0x5b, 0x68, 0xa2, 0x64, 0xe3, 0x64, 0x01, 0x22, 0xe5, 0x6c, + 0xa6, 0x6c, 0x6b, 0x00, 0x5b, 0x08, 0x0f, 0x93, 0x52, 0x42, 0xac, 0x4b, + 0x30, 0x00, 0x0f, 0x99, 0xff, 0xf7, 0x50, 0xfd, 0x00, 0x28, 0x30, 0xd1, + 0x01, 0x22, 0xa8, 0x4b, 0x52, 0x42, 0x30, 0x00, 0x0f, 0x99, 0xfe, 0xf7, + 0x49, 0xf8, 0x00, 0x28, 0x27, 0xd1, 0x00, 0x22, 0x00, 0x23, 0x30, 0x00, + 0x29, 0x00, 0xfe, 0xf7, 0x37, 0xf8, 0x00, 0x28, 0x03, 0xd0, 0x23, 0x00, + 0x2d, 0x22, 0x43, 0x33, 0x1a, 0x70, 0x9f, 0x4d, 0x47, 0x2f, 0x00, 0xd8, + 0x9e, 0x4d, 0x03, 0x23, 0x00, 0x26, 0x0d, 0x9a, 0x23, 0x61, 0x01, 0x33, + 0x9a, 0x43, 0x22, 0x60, 0x0b, 0x9b, 0x13, 0xaa, 0x00, 0x93, 0x21, 0x00, + 0x0a, 0x9b, 0x09, 0x98, 0x00, 0xf0, 0xf4, 0xf9, 0x43, 0x1c, 0x00, 0xd0, + 0x93, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x15, 0xb0, 0xf0, 0xbd, 0x07, 0x33, + 0xb8, 0xe7, 0x32, 0x00, 0x2b, 0x00, 0x30, 0x00, 0x29, 0x00, 0xff, 0xf7, + 0x17, 0xfd, 0x00, 0x28, 0x04, 0xd0, 0x8f, 0x4d, 0x47, 0x2f, 0xdc, 0xd8, + 0x8e, 0x4d, 0xda, 0xe7, 0x80, 0x23, 0x0d, 0x99, 0x62, 0x68, 0xdb, 0x00, + 0x0b, 0x43, 0x51, 0x1c, 0x43, 0xd1, 0x07, 0x32, 0x62, 0x60, 0x12, 0xaa, + 0x00, 0x21, 0x05, 0x92, 0x11, 0xaa, 0x03, 0x92, 0x23, 0x22, 0x23, 0x60, + 0x06, 0x91, 0x01, 0x93, 0x08, 0xa9, 0x63, 0x68, 0x52, 0x18, 0x02, 0x92, + 0x00, 0x93, 0x32, 0x00, 0x2b, 0x00, 0x04, 0x97, 0x09, 0x98, 0xff, 0xf7, + 0xd9, 0xfe, 0x20, 0x23, 0x3a, 0x00, 0x05, 0x00, 0x9a, 0x43, 0x47, 0x2a, + 0x07, 0xd1, 0x11, 0x9b, 0xda, 0x1c, 0x02, 0xdb, 0x62, 0x68, 0x93, 0x42, + 0x45, 0xdd, 0x02, 0x3f, 0xff, 0xb2, 0x11, 0x99, 0x65, 0x2f, 0x25, 0xd8, + 0x20, 0x00, 0x01, 0x39, 0x3a, 0x00, 0x50, 0x30, 0x11, 0x91, 0xff, 0xf7, + 0x25, 0xff, 0x12, 0x9a, 0x06, 0x00, 0x13, 0x18, 0x23, 0x61, 0x01, 0x2a, + 0x02, 0xdc, 0x22, 0x68, 0xd2, 0x07, 0x01, 0xd5, 0x01, 0x33, 0x23, 0x61, + 0x23, 0x23, 0x08, 0xaa, 0x9b, 0x18, 0x1b, 0x78, 0x00, 0x2b, 0x9b, 0xd0, + 0x23, 0x00, 0x2d, 0x22, 0x43, 0x33, 0x1a, 0x70, 0x96, 0xe7, 0x67, 0x2f, + 0x00, 0xd1, 0x76, 0xe1, 0x47, 0x2f, 0xb8, 0xd1, 0x00, 0x2a, 0xb6, 0xd1, + 0x01, 0x22, 0xb3, 0xe7, 0x66, 0x2f, 0x19, 0xd1, 0x63, 0x68, 0x00, 0x29, + 0x0c, 0xdd, 0x21, 0x61, 0x00, 0x2b, 0x02, 0xd1, 0x22, 0x68, 0xd2, 0x07, + 0x02, 0xd5, 0x01, 0x33, 0x5b, 0x18, 0x23, 0x61, 0x11, 0x9b, 0x00, 0x26, + 0xa3, 0x65, 0xd9, 0xe7, 0x00, 0x2b, 0x03, 0xd1, 0x01, 0x22, 0x21, 0x68, + 0x11, 0x42, 0x00, 0xd0, 0x9a, 0x1c, 0x22, 0x61, 0xf2, 0xe7, 0x67, 0x27, + 0x11, 0x9b, 0x12, 0x9a, 0x93, 0x42, 0x05, 0xdb, 0x22, 0x68, 0x23, 0x61, + 0xd2, 0x07, 0xe9, 0xd5, 0x01, 0x33, 0xe6, 0xe7, 0x01, 0x21, 0x00, 0x2b, + 0x01, 0xdc, 0x49, 0x18, 0xc9, 0x1a, 0x52, 0x18, 0xeb, 0xe7, 0x22, 0x68, + 0x53, 0x05, 0x08, 0xd4, 0x23, 0x69, 0x2a, 0x00, 0x0a, 0x99, 0x09, 0x98, + 0x0b, 0x9d, 0xa8, 0x47, 0x43, 0x1c, 0x29, 0xd1, 0x5f, 0xe7, 0x65, 0x2f, + 0x00, 0xd8, 0xe0, 0xe0, 0xa0, 0x6c, 0xe1, 0x6c, 0x00, 0x22, 0x00, 0x23, + 0xfd, 0xf7, 0x6c, 0xff, 0x00, 0x28, 0x34, 0xd0, 0x01, 0x23, 0x42, 0x4a, + 0x0a, 0x99, 0x09, 0x98, 0x0b, 0x9d, 0xa8, 0x47, 0x43, 0x1c, 0x00, 0xd1, + 0x4b, 0xe7, 0x11, 0x9b, 0x12, 0x9a, 0x93, 0x42, 0x02, 0xdb, 0x23, 0x68, + 0xdb, 0x07, 0x0d, 0xd5, 0x0b, 0x9d, 0x0e, 0x9b, 0x0c, 0x9a, 0x0a, 0x99, + 0x09, 0x98, 0xa8, 0x47, 0x00, 0x25, 0x43, 0x1c, 0x00, 0xd1, 0x3a, 0xe7, + 0x12, 0x9b, 0x01, 0x3b, 0xab, 0x42, 0x0a, 0xdc, 0x23, 0x68, 0x9b, 0x07, + 0x00, 0xd5, 0x08, 0xe1, 0x13, 0x9b, 0xe0, 0x68, 0x98, 0x42, 0x00, 0xdb, + 0x2f, 0xe7, 0x18, 0x00, 0x2d, 0xe7, 0x22, 0x00, 0x01, 0x23, 0x1a, 0x32, + 0x0a, 0x99, 0x09, 0x98, 0x0b, 0x9e, 0xb0, 0x47, 0x43, 0x1c, 0x00, 0xd1, + 0x21, 0xe7, 0x01, 0x35, 0xe4, 0xe7, 0x11, 0x9b, 0x00, 0x2b, 0x2d, 0xdc, + 0x01, 0x23, 0x26, 0x4a, 0x0a, 0x99, 0x09, 0x98, 0x0b, 0x9e, 0xb0, 0x47, + 0x43, 0x1c, 0x00, 0xd1, 0x13, 0xe7, 0x11, 0x9b, 0x00, 0x2b, 0x05, 0xd1, + 0x12, 0x9b, 0x00, 0x2b, 0x02, 0xd1, 0x23, 0x68, 0xdb, 0x07, 0xd3, 0xd5, + 0x0b, 0x9e, 0x0e, 0x9b, 0x0c, 0x9a, 0x0a, 0x99, 0x09, 0x98, 0xb0, 0x47, + 0x00, 0x26, 0x43, 0x1c, 0x00, 0xd1, 0x00, 0xe7, 0x11, 0x9b, 0x5b, 0x42, + 0xb3, 0x42, 0x01, 0xdc, 0x12, 0x9b, 0x92, 0xe7, 0x22, 0x00, 0x01, 0x23, + 0x1a, 0x32, 0x0a, 0x99, 0x09, 0x98, 0x0b, 0x9f, 0xb8, 0x47, 0x43, 0x1c, + 0x00, 0xd1, 0xf0, 0xe6, 0x01, 0x36, 0xed, 0xe7, 0xa3, 0x6d, 0x12, 0x9f, + 0x9f, 0x42, 0x00, 0xdd, 0x1f, 0x00, 0x00, 0x2f, 0x08, 0xdd, 0x3b, 0x00, + 0x2a, 0x00, 0x0a, 0x99, 0x09, 0x98, 0x0b, 0x9e, 0xb0, 0x47, 0x43, 0x1c, + 0x00, 0xd1, 0xde, 0xe6, 0x00, 0x23, 0x0d, 0x93, 0xfb, 0x43, 0xdb, 0x17, + 0x0f, 0x93, 0x18, 0xe0, 0xff, 0xff, 0xef, 0x7f, 0x46, 0x98, 0x00, 0x00, + 0x42, 0x98, 0x00, 0x00, 0x4e, 0x98, 0x00, 0x00, 0x4a, 0x98, 0x00, 0x00, + 0x7a, 0x93, 0x00, 0x00, 0x22, 0x00, 0x01, 0x23, 0x1a, 0x32, 0x0a, 0x99, + 0x09, 0x98, 0x0b, 0x9e, 0xb0, 0x47, 0x43, 0x1c, 0x00, 0xd1, 0xc2, 0xe6, + 0x0d, 0x9b, 0x01, 0x33, 0x0d, 0x93, 0x0f, 0x9b, 0xa6, 0x6d, 0x0d, 0x9a, + 0x3b, 0x40, 0xf3, 0x1a, 0x93, 0x42, 0xeb, 0xdc, 0x11, 0x9b, 0x12, 0x9a, + 0xad, 0x19, 0x93, 0x42, 0x10, 0xdb, 0x23, 0x68, 0xdb, 0x07, 0x0d, 0xd4, + 0x12, 0x9f, 0x11, 0x9b, 0xbe, 0x1b, 0xff, 0x1a, 0xb7, 0x42, 0x00, 0xdd, + 0x37, 0x00, 0x00, 0x2f, 0x0d, 0xdc, 0xfe, 0x43, 0xf3, 0x17, 0x00, 0x25, + 0x0c, 0x93, 0x1c, 0xe0, 0x0e, 0x9b, 0x0c, 0x9a, 0x0a, 0x99, 0x09, 0x98, + 0x0b, 0x9f, 0xb8, 0x47, 0x43, 0x1c, 0xe9, 0xd1, 0x99, 0xe6, 0x3b, 0x00, + 0x2a, 0x00, 0x0a, 0x99, 0x09, 0x98, 0x0b, 0x9d, 0xa8, 0x47, 0x43, 0x1c, + 0xe9, 0xd1, 0x90, 0xe6, 0x22, 0x00, 0x01, 0x23, 0x1a, 0x32, 0x0a, 0x99, + 0x09, 0x98, 0x0b, 0x9e, 0xb0, 0x47, 0x43, 0x1c, 0x00, 0xd1, 0x86, 0xe6, + 0x01, 0x35, 0x11, 0x9a, 0x12, 0x9b, 0x0c, 0x99, 0x9b, 0x1a, 0x3a, 0x00, + 0x0a, 0x40, 0x9b, 0x1a, 0xab, 0x42, 0xeb, 0xdc, 0x44, 0xe7, 0x12, 0x9b, + 0x01, 0x2b, 0x02, 0xdc, 0x01, 0x23, 0x1a, 0x42, 0x32, 0xd0, 0x01, 0x23, + 0x2a, 0x00, 0x0a, 0x99, 0x09, 0x98, 0x0b, 0x9f, 0xb8, 0x47, 0x43, 0x1c, + 0x00, 0xd1, 0x6c, 0xe6, 0x0e, 0x9b, 0x0c, 0x9a, 0x0a, 0x99, 0x09, 0x98, + 0x0b, 0x9f, 0x01, 0x35, 0xb8, 0x47, 0x43, 0x1c, 0x00, 0xd1, 0x62, 0xe6, + 0xa0, 0x6c, 0xe1, 0x6c, 0x12, 0x9b, 0x00, 0x22, 0x5f, 0x1e, 0x00, 0x23, + 0xfd, 0xf7, 0x70, 0xfe, 0x3b, 0x00, 0x00, 0x28, 0x14, 0xd0, 0x00, 0x25, + 0x0a, 0xe0, 0x22, 0x00, 0x01, 0x23, 0x1a, 0x32, 0x0a, 0x99, 0x09, 0x98, + 0x0b, 0x9f, 0xb8, 0x47, 0x43, 0x1c, 0x00, 0xd1, 0x4b, 0xe6, 0x01, 0x35, + 0x12, 0x9b, 0x01, 0x3b, 0xab, 0x42, 0xf0, 0xdc, 0x22, 0x00, 0x33, 0x00, + 0x50, 0x32, 0xdb, 0xe6, 0x2a, 0x00, 0x0a, 0x99, 0x09, 0x98, 0x0b, 0x9d, + 0xa8, 0x47, 0x43, 0x1c, 0xf4, 0xd1, 0x3a, 0xe6, 0x22, 0x00, 0x01, 0x23, + 0x19, 0x32, 0x0a, 0x99, 0x09, 0x98, 0x0b, 0x9e, 0xb0, 0x47, 0x43, 0x1c, + 0x00, 0xd1, 0x30, 0xe6, 0x01, 0x35, 0xe3, 0x68, 0x13, 0x9a, 0x9b, 0x1a, + 0xab, 0x42, 0xef, 0xdc, 0xf6, 0xe6, 0x00, 0x25, 0xf7, 0xe7, 0x00, 0x2a, + 0x00, 0xd1, 0x89, 0xe6, 0x00, 0x21, 0x06, 0x91, 0x12, 0xa9, 0x05, 0x91, + 0x11, 0xa9, 0x03, 0x91, 0x23, 0x21, 0x08, 0xa8, 0x09, 0x18, 0x23, 0x60, + 0x01, 0x93, 0x00, 0x92, 0x2b, 0x00, 0x04, 0x97, 0x02, 0x91, 0x32, 0x00, + 0x09, 0x98, 0xff, 0xf7, 0x1b, 0xfd, 0x05, 0x00, 0x45, 0xe6, 0xc0, 0x46, + 0xf7, 0xb5, 0x15, 0x00, 0x01, 0x93, 0x8a, 0x68, 0x0b, 0x69, 0x00, 0x90, + 0x0c, 0x00, 0x93, 0x42, 0x00, 0xda, 0x13, 0x00, 0x22, 0x00, 0x2b, 0x60, + 0x43, 0x32, 0x12, 0x78, 0x00, 0x2a, 0x01, 0xd0, 0x01, 0x33, 0x2b, 0x60, + 0x23, 0x68, 0x9b, 0x06, 0x02, 0xd5, 0x2b, 0x68, 0x02, 0x33, 0x2b, 0x60, + 0x06, 0x27, 0x23, 0x68, 0x1f, 0x40, 0x27, 0xd0, 0x23, 0x00, 0x43, 0x33, + 0x1b, 0x78, 0x5a, 0x1e, 0x93, 0x41, 0x22, 0x68, 0x92, 0x06, 0x30, 0xd4, + 0x22, 0x00, 0x01, 0x99, 0x43, 0x32, 0x00, 0x98, 0x08, 0x9e, 0xb0, 0x47, + 0x43, 0x1c, 0x25, 0xd0, 0x06, 0x23, 0x20, 0x68, 0x2a, 0x68, 0xe1, 0x68, + 0x03, 0x40, 0x00, 0x25, 0x04, 0x2b, 0x03, 0xd1, 0x8d, 0x1a, 0xeb, 0x43, + 0xdb, 0x17, 0x1d, 0x40, 0xa3, 0x68, 0x22, 0x69, 0x93, 0x42, 0x01, 0xdd, + 0x9b, 0x1a, 0xed, 0x18, 0x00, 0x27, 0xbd, 0x42, 0x20, 0xd1, 0x00, 0x20, + 0x10, 0xe0, 0x01, 0x37, 0xe3, 0x68, 0x2a, 0x68, 0x9b, 0x1a, 0xbb, 0x42, + 0xd2, 0xdd, 0x22, 0x00, 0x01, 0x23, 0x19, 0x32, 0x01, 0x99, 0x00, 0x98, + 0x08, 0x9e, 0xb0, 0x47, 0x43, 0x1c, 0xf0, 0xd1, 0x01, 0x20, 0x40, 0x42, + 0xfe, 0xbd, 0x30, 0x20, 0xe1, 0x18, 0x43, 0x31, 0x08, 0x70, 0x21, 0x00, + 0x5a, 0x1c, 0x45, 0x31, 0x09, 0x78, 0xa2, 0x18, 0x43, 0x32, 0x02, 0x33, + 0x11, 0x70, 0xc1, 0xe7, 0x22, 0x00, 0x01, 0x23, 0x1a, 0x32, 0x01, 0x99, + 0x00, 0x98, 0x08, 0x9e, 0xb0, 0x47, 0x43, 0x1c, 0xe6, 0xd0, 0x01, 0x37, + 0xd1, 0xe7, 0x00, 0x00, 0xf0, 0xb5, 0x89, 0xb0, 0x04, 0x92, 0x0a, 0x00, + 0x43, 0x32, 0x05, 0x93, 0x03, 0x90, 0x02, 0x92, 0x0a, 0x7e, 0x0c, 0x00, + 0x0e, 0x9b, 0x6e, 0x2a, 0x00, 0xd1, 0x86, 0xe0, 0x1f, 0xd8, 0x63, 0x2a, + 0x33, 0xd0, 0x08, 0xd8, 0x00, 0x2a, 0x00, 0xd1, 0x8c, 0xe0, 0x58, 0x2a, + 0x4d, 0xd0, 0x25, 0x00, 0x42, 0x35, 0x2a, 0x70, 0x30, 0xe0, 0x64, 0x2a, + 0x01, 0xd0, 0x69, 0x2a, 0xf7, 0xd1, 0x19, 0x68, 0x25, 0x68, 0x0a, 0x1d, + 0x28, 0x06, 0x29, 0xd5, 0x08, 0x68, 0x1a, 0x60, 0x00, 0x28, 0x03, 0xda, + 0x2d, 0x23, 0x02, 0x9a, 0x40, 0x42, 0x13, 0x70, 0x6b, 0x4e, 0x0a, 0x27, + 0x4f, 0xe0, 0x73, 0x2a, 0x74, 0xd0, 0x08, 0xd8, 0x6f, 0x2a, 0x1f, 0xd0, + 0x70, 0x2a, 0xe0, 0xd1, 0x20, 0x22, 0x09, 0x68, 0x0a, 0x43, 0x22, 0x60, + 0x03, 0xe0, 0x75, 0x2a, 0x16, 0xd0, 0x78, 0x2a, 0xd7, 0xd1, 0x22, 0x00, + 0x78, 0x21, 0x45, 0x32, 0x11, 0x70, 0x61, 0x4e, 0x22, 0xe0, 0x25, 0x00, + 0x1a, 0x68, 0x42, 0x35, 0x11, 0x1d, 0x19, 0x60, 0x13, 0x68, 0x2b, 0x70, + 0x01, 0x23, 0x65, 0xe0, 0x08, 0x68, 0x1a, 0x60, 0x69, 0x06, 0xd3, 0xd5, + 0x00, 0xb2, 0xd1, 0xe7, 0x19, 0x68, 0x25, 0x68, 0x08, 0x1d, 0x18, 0x60, + 0x08, 0x68, 0x2e, 0x06, 0x05, 0xd5, 0x54, 0x4e, 0x08, 0x27, 0x6f, 0x2a, + 0x1b, 0xd0, 0x0a, 0x27, 0x19, 0xe0, 0x6d, 0x06, 0xf7, 0xd5, 0x80, 0xb2, + 0xf5, 0xe7, 0x45, 0x31, 0x4e, 0x4e, 0x0a, 0x70, 0x18, 0x68, 0x22, 0x68, + 0x01, 0x1d, 0x00, 0x68, 0x19, 0x60, 0x15, 0x06, 0x21, 0xd5, 0xd3, 0x07, + 0x02, 0xd5, 0x20, 0x23, 0x1a, 0x43, 0x22, 0x60, 0x10, 0x27, 0x00, 0x28, + 0x03, 0xd1, 0x20, 0x23, 0x22, 0x68, 0x9a, 0x43, 0x22, 0x60, 0x23, 0x00, + 0x00, 0x22, 0x43, 0x33, 0x1a, 0x70, 0x63, 0x68, 0xa3, 0x60, 0x00, 0x2b, + 0x58, 0xdb, 0x04, 0x22, 0x21, 0x68, 0x91, 0x43, 0x21, 0x60, 0x00, 0x28, + 0x54, 0xd1, 0x02, 0x9d, 0x00, 0x2b, 0x5a, 0xd0, 0x25, 0x00, 0x33, 0x78, + 0x42, 0x35, 0x2b, 0x70, 0x55, 0xe0, 0x55, 0x06, 0xdb, 0xd5, 0x80, 0xb2, + 0xd9, 0xe7, 0x1a, 0x68, 0x0d, 0x68, 0x10, 0x1d, 0x49, 0x69, 0x18, 0x60, + 0x13, 0x68, 0x2e, 0x06, 0x01, 0xd5, 0x19, 0x60, 0x02, 0xe0, 0x6d, 0x06, + 0xfb, 0xd5, 0x19, 0x80, 0x00, 0x23, 0x02, 0x9d, 0x23, 0x61, 0x4f, 0xe0, + 0x1a, 0x68, 0x11, 0x1d, 0x19, 0x60, 0x15, 0x68, 0x00, 0x21, 0x62, 0x68, + 0x28, 0x00, 0x01, 0xf0, 0x27, 0xf8, 0x00, 0x28, 0x01, 0xd0, 0x40, 0x1b, + 0x60, 0x60, 0x63, 0x68, 0x23, 0x61, 0x00, 0x23, 0x02, 0x9a, 0x13, 0x70, + 0x3c, 0xe0, 0x23, 0x69, 0x2a, 0x00, 0x04, 0x99, 0x03, 0x98, 0x05, 0x9d, + 0xa8, 0x47, 0x43, 0x1c, 0x3e, 0xd0, 0x23, 0x68, 0x9b, 0x07, 0x15, 0xd4, + 0x07, 0x9b, 0xe0, 0x68, 0x98, 0x42, 0x39, 0xda, 0x18, 0x00, 0x37, 0xe0, + 0x22, 0x00, 0x01, 0x23, 0x19, 0x32, 0x04, 0x99, 0x03, 0x98, 0x05, 0x9e, + 0xb0, 0x47, 0x43, 0x1c, 0x2c, 0xd0, 0x01, 0x35, 0xe3, 0x68, 0x07, 0x9a, + 0x9b, 0x1a, 0xab, 0x42, 0xf0, 0xdc, 0xe9, 0xe7, 0x00, 0x25, 0xf7, 0xe7, + 0x00, 0x28, 0xad, 0xd0, 0x02, 0x9d, 0x39, 0x00, 0xfd, 0xf7, 0xd4, 0xfb, + 0x73, 0x5c, 0x01, 0x3d, 0x2b, 0x70, 0x00, 0x28, 0xf7, 0xd1, 0x08, 0x2f, + 0x09, 0xd1, 0x23, 0x68, 0xdb, 0x07, 0x06, 0xd5, 0x63, 0x68, 0x22, 0x69, + 0x93, 0x42, 0x02, 0xdc, 0x30, 0x23, 0x01, 0x3d, 0x2b, 0x70, 0x02, 0x9b, + 0x5b, 0x1b, 0x23, 0x61, 0x05, 0x9b, 0x07, 0xaa, 0x00, 0x93, 0x21, 0x00, + 0x04, 0x9b, 0x03, 0x98, 0xff, 0xf7, 0x94, 0xfe, 0x43, 0x1c, 0xb8, 0xd1, + 0x01, 0x20, 0x40, 0x42, 0x09, 0xb0, 0xf0, 0xbd, 0x52, 0x98, 0x00, 0x00, + 0x63, 0x98, 0x00, 0x00, 0x10, 0xb5, 0x03, 0x4b, 0x0a, 0x00, 0x01, 0x00, + 0x18, 0x68, 0x01, 0xf0, 0xc9, 0xfa, 0x10, 0xbd, 0x28, 0x00, 0x00, 0x20, + 0x00, 0x23, 0x70, 0xb5, 0x06, 0x4c, 0x05, 0x00, 0x08, 0x00, 0x23, 0x60, + 0x01, 0xf0, 0x86, 0xfc, 0x43, 0x1c, 0x03, 0xd1, 0x23, 0x68, 0x00, 0x2b, + 0x00, 0xd0, 0x2b, 0x60, 0x70, 0xbd, 0xc0, 0x46, 0x58, 0x26, 0x00, 0x20, + 0xc9, 0xb2, 0x03, 0x78, 0x00, 0x2b, 0x04, 0xd0, 0x8b, 0x42, 0x00, 0xd1, + 0x70, 0x47, 0x01, 0x30, 0xf7, 0xe7, 0x4b, 0x42, 0x59, 0x41, 0x49, 0x42, + 0x08, 0x40, 0xf7, 0xe7, 0x02, 0x78, 0x0b, 0x78, 0x00, 0x2a, 0x03, 0xd0, + 0x01, 0x30, 0x01, 0x31, 0x9a, 0x42, 0xf7, 0xd0, 0xd0, 0x1a, 0x70, 0x47, + 0x03, 0x00, 0x0a, 0x78, 0x01, 0x31, 0x1a, 0x70, 0x01, 0x33, 0x00, 0x2a, + 0xf9, 0xd1, 0x70, 0x47, 0x00, 0x23, 0xc2, 0x5c, 0x01, 0x33, 0x00, 0x2a, + 0xfb, 0xd1, 0x58, 0x1e, 0x70, 0x47, 0x00, 0x23, 0x30, 0xb5, 0x9a, 0x42, + 0x0a, 0xd0, 0x01, 0x3a, 0xc4, 0x5c, 0xcd, 0x5c, 0xac, 0x42, 0x04, 0xd1, + 0x93, 0x42, 0x02, 0xd0, 0x01, 0x33, 0x00, 0x2c, 0xf6, 0xd1, 0x63, 0x1b, + 0x18, 0x00, 0x30, 0xbd, 0x30, 0xb5, 0x05, 0x00, 0x00, 0x2a, 0x00, 0xd1, + 0x30, 0xbd, 0x0c, 0x78, 0x01, 0x3a, 0x6b, 0x1c, 0x2c, 0x70, 0x01, 0x31, + 0x00, 0x2c, 0x05, 0xd1, 0x9a, 0x18, 0x9a, 0x42, 0xf4, 0xd0, 0x1c, 0x70, + 0x01, 0x33, 0xfa, 0xe7, 0x1d, 0x00, 0xed, 0xe7, 0x10, 0xb5, 0x03, 0x78, + 0x00, 0x2b, 0x0f, 0xd1, 0x0b, 0x78, 0x5a, 0x42, 0x53, 0x41, 0x5b, 0x42, + 0x18, 0x40, 0x10, 0xbd, 0x00, 0x23, 0xca, 0x5c, 0x00, 0x2a, 0xfa, 0xd0, + 0xc4, 0x5c, 0x94, 0x42, 0x01, 0xd1, 0x01, 0x33, 0xf7, 0xe7, 0x01, 0x30, + 0x03, 0x78, 0x00, 0x2b, 0xf2, 0xd1, 0x18, 0x00, 0xef, 0xe7, 0x00, 0x00, + 0xf0, 0xb5, 0x1f, 0x00, 0x0e, 0x00, 0x87, 0xb0, 0x05, 0x90, 0x01, 0x91, + 0x02, 0x92, 0x0c, 0x98, 0x34, 0x78, 0xff, 0xf7, 0x12, 0xfa, 0x08, 0x22, + 0x00, 0x19, 0x43, 0x78, 0x75, 0x1c, 0x13, 0x40, 0x36, 0xd1, 0x2d, 0x2c, + 0x36, 0xd1, 0xb5, 0x1c, 0x74, 0x78, 0x01, 0x26, 0x00, 0x2f, 0x62, 0xd0, + 0x10, 0x2f, 0x09, 0xd1, 0x30, 0x2c, 0x07, 0xd1, 0x20, 0x22, 0x2b, 0x78, + 0x93, 0x43, 0x58, 0x2b, 0x54, 0xd1, 0x10, 0x27, 0x6c, 0x78, 0x02, 0x35, + 0x2d, 0x4b, 0x39, 0x00, 0xf3, 0x18, 0x18, 0x00, 0x03, 0x93, 0xfd, 0xf7, + 0x01, 0xfb, 0x04, 0x91, 0x01, 0x21, 0x00, 0x23, 0x49, 0x42, 0x02, 0x00, + 0x8c, 0x46, 0x18, 0x00, 0x21, 0x00, 0x30, 0x39, 0x09, 0x29, 0x1a, 0xd8, + 0x0c, 0x00, 0xa7, 0x42, 0x23, 0xdd, 0x59, 0x1c, 0x09, 0xd0, 0x63, 0x46, + 0x82, 0x42, 0x06, 0xd3, 0x02, 0xd1, 0x04, 0x99, 0xa1, 0x42, 0x02, 0xdb, + 0x01, 0x23, 0x78, 0x43, 0x20, 0x18, 0x2c, 0x78, 0x01, 0x35, 0xe9, 0xe7, + 0x2e, 0x00, 0xbc, 0xe7, 0x2b, 0x2c, 0x01, 0xd0, 0x1e, 0x00, 0xc7, 0xe7, + 0xb5, 0x1c, 0x74, 0x78, 0xfa, 0xe7, 0x21, 0x00, 0x41, 0x39, 0x19, 0x29, + 0x01, 0xd8, 0x37, 0x3c, 0xdf, 0xe7, 0x21, 0x00, 0x61, 0x39, 0x19, 0x29, + 0x01, 0xd8, 0x57, 0x3c, 0xd9, 0xe7, 0x5a, 0x1c, 0x08, 0xd1, 0x05, 0x9a, + 0x23, 0x33, 0x13, 0x60, 0x02, 0x9b, 0x03, 0x98, 0x00, 0x2b, 0x09, 0xd1, + 0x07, 0xb0, 0xf0, 0xbd, 0x00, 0x2e, 0x00, 0xd0, 0x40, 0x42, 0x02, 0x9a, + 0x00, 0x2a, 0xf7, 0xd0, 0x00, 0x2b, 0x01, 0xd0, 0x6b, 0x1e, 0x01, 0x93, + 0x02, 0x9b, 0x01, 0x9a, 0x1a, 0x60, 0xef, 0xe7, 0x30, 0x24, 0x00, 0x2f, + 0xaa, 0xd1, 0x08, 0x27, 0xa8, 0xe7, 0x30, 0x2c, 0x9e, 0xd0, 0x0a, 0x27, + 0xa4, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0xff, 0x7f, 0x37, 0xb5, 0x13, 0x00, + 0x06, 0x4a, 0x05, 0x00, 0x10, 0x68, 0x04, 0x6a, 0x00, 0x2c, 0x00, 0xd1, + 0x04, 0x4c, 0x0a, 0x00, 0x00, 0x94, 0x29, 0x00, 0xff, 0xf7, 0x70, 0xff, + 0x3e, 0xbd, 0xc0, 0x46, 0x28, 0x00, 0x00, 0x20, 0x8c, 0x00, 0x00, 0x20, + 0x30, 0xb5, 0x14, 0x00, 0x9b, 0xb0, 0x05, 0x00, 0x1a, 0x00, 0x00, 0x2c, + 0x05, 0xda, 0x8b, 0x23, 0x03, 0x60, 0x01, 0x20, 0x40, 0x42, 0x1b, 0xb0, + 0x30, 0xbd, 0x82, 0x23, 0x68, 0x46, 0x9b, 0x00, 0x83, 0x81, 0x00, 0x23, + 0x00, 0x91, 0x04, 0x91, 0x9c, 0x42, 0x00, 0xd0, 0x63, 0x1e, 0x02, 0x93, + 0x05, 0x93, 0x01, 0x23, 0x69, 0x46, 0x5b, 0x42, 0xcb, 0x81, 0x28, 0x00, + 0x1e, 0x9b, 0x01, 0xf0, 0x1f, 0xfa, 0x43, 0x1c, 0x01, 0xda, 0x8b, 0x23, + 0x2b, 0x60, 0x00, 0x2c, 0xe3, 0xd0, 0x00, 0x23, 0x00, 0x9a, 0x13, 0x70, + 0xdf, 0xe7, 0x00, 0x00, 0x07, 0xb5, 0x00, 0x93, 0x13, 0x00, 0x0a, 0x00, + 0x01, 0x00, 0x02, 0x48, 0x00, 0x68, 0xff, 0xf7, 0xcb, 0xff, 0x0e, 0xbd, + 0x28, 0x00, 0x00, 0x20, 0x0b, 0x1e, 0x04, 0xd0, 0xff, 0x2a, 0x04, 0xd9, + 0x8a, 0x23, 0x03, 0x60, 0x8b, 0x3b, 0x18, 0x00, 0x70, 0x47, 0x0a, 0x70, + 0x01, 0x23, 0xfa, 0xe7, 0xf0, 0xb5, 0x03, 0x69, 0x0c, 0x69, 0x89, 0xb0, + 0x07, 0x00, 0x05, 0x91, 0x00, 0x26, 0xa3, 0x42, 0x65, 0xdb, 0x0b, 0x00, + 0x01, 0x3c, 0x14, 0x33, 0xa5, 0x00, 0x03, 0x93, 0x5b, 0x19, 0x04, 0x93, + 0x03, 0x00, 0x14, 0x33, 0x02, 0x93, 0x5d, 0x19, 0x04, 0x9b, 0x28, 0x68, + 0x1b, 0x68, 0x59, 0x1c, 0x01, 0x93, 0xfd, 0xf7, 0xb1, 0xf9, 0x01, 0x90, + 0xb0, 0x42, 0x29, 0xd0, 0x03, 0x9b, 0x02, 0x98, 0x9c, 0x46, 0x06, 0x96, + 0x62, 0x46, 0x08, 0xca, 0x94, 0x46, 0x01, 0x9a, 0x99, 0xb2, 0x51, 0x43, + 0x1b, 0x0c, 0x53, 0x43, 0x89, 0x19, 0x0a, 0x0c, 0x9b, 0x18, 0x07, 0x93, + 0x1e, 0x0c, 0x03, 0x68, 0x89, 0xb2, 0x9a, 0xb2, 0x06, 0x9b, 0xd2, 0x18, + 0x03, 0x68, 0x52, 0x1a, 0x19, 0x0c, 0x6b, 0x46, 0x9b, 0x8b, 0xcb, 0x1a, + 0x11, 0x14, 0x5b, 0x18, 0x19, 0x14, 0x92, 0xb2, 0x1b, 0x04, 0x1a, 0x43, + 0x04, 0x9b, 0x06, 0x91, 0x04, 0xc0, 0x63, 0x45, 0xdc, 0xd2, 0x2b, 0x68, + 0x00, 0x2b, 0x2d, 0xd0, 0x05, 0x99, 0x38, 0x00, 0x01, 0xf0, 0x48, 0xf8, + 0x00, 0x28, 0x1f, 0xdb, 0x00, 0x25, 0x01, 0x9b, 0x02, 0x98, 0x01, 0x33, + 0x03, 0x99, 0x01, 0x93, 0x02, 0x68, 0x08, 0xc9, 0x92, 0xb2, 0x55, 0x19, + 0x9a, 0xb2, 0xaa, 0x1a, 0x05, 0x68, 0x1b, 0x0c, 0x2d, 0x0c, 0xeb, 0x1a, + 0x15, 0x14, 0x5b, 0x19, 0x1d, 0x14, 0x92, 0xb2, 0x1b, 0x04, 0x13, 0x43, + 0x08, 0xc0, 0x04, 0x9b, 0x8b, 0x42, 0xeb, 0xd2, 0x02, 0x9a, 0xa3, 0x00, + 0xd3, 0x18, 0x1a, 0x68, 0x00, 0x2a, 0x11, 0xd0, 0x01, 0x9e, 0x30, 0x00, + 0x09, 0xb0, 0xf0, 0xbd, 0x2b, 0x68, 0x00, 0x2b, 0x04, 0xd1, 0x01, 0x3c, + 0x02, 0x9b, 0x04, 0x3d, 0xab, 0x42, 0xf7, 0xd3, 0x3c, 0x61, 0xcb, 0xe7, + 0x1a, 0x68, 0x00, 0x2a, 0x04, 0xd1, 0x01, 0x3c, 0x02, 0x9a, 0x04, 0x3b, + 0x9a, 0x42, 0xf7, 0xd3, 0x3c, 0x61, 0xe7, 0xe7, 0xf0, 0xb5, 0x16, 0x00, + 0x1f, 0x00, 0x44, 0x6a, 0x9b, 0xb0, 0x02, 0x90, 0x23, 0x9d, 0x06, 0x96, + 0x07, 0x97, 0x00, 0x2c, 0x08, 0xd1, 0x10, 0x20, 0xff, 0xf7, 0xc0, 0xf8, + 0x02, 0x9b, 0x58, 0x62, 0x44, 0x60, 0x84, 0x60, 0x04, 0x60, 0xc4, 0x60, + 0x02, 0x9b, 0x5b, 0x6a, 0x19, 0x68, 0x00, 0x29, 0x0b, 0xd0, 0x5a, 0x68, + 0x01, 0x23, 0x93, 0x40, 0x4a, 0x60, 0x8b, 0x60, 0x02, 0x98, 0x00, 0xf0, + 0x10, 0xfe, 0x00, 0x22, 0x02, 0x9b, 0x5b, 0x6a, 0x1a, 0x60, 0x00, 0x2f, + 0x20, 0xda, 0x01, 0x23, 0x2b, 0x60, 0x7b, 0x00, 0x5b, 0x08, 0x07, 0x93, + 0x07, 0x9c, 0xb2, 0x4b, 0x22, 0x00, 0x17, 0x93, 0x1a, 0x40, 0x9a, 0x42, + 0x17, 0xd1, 0xb0, 0x4b, 0x22, 0x9a, 0x13, 0x60, 0x06, 0x9b, 0x00, 0x2b, + 0x03, 0xd1, 0x24, 0x03, 0x01, 0xd1, 0x00, 0xf0, 0x87, 0xfd, 0xac, 0x4b, + 0x24, 0x9a, 0x08, 0x93, 0x00, 0x2a, 0x02, 0xd0, 0xaa, 0x4b, 0x24, 0x9a, + 0x13, 0x60, 0x08, 0x98, 0x1b, 0xb0, 0xf0, 0xbd, 0x00, 0x23, 0x2b, 0x60, + 0xe0, 0xe7, 0x06, 0x9e, 0x07, 0x9f, 0x00, 0x22, 0x00, 0x23, 0x30, 0x00, + 0x39, 0x00, 0xfd, 0xf7, 0x79, 0xfa, 0x05, 0x1e, 0x0b, 0xd0, 0x01, 0x23, + 0x22, 0x9a, 0x13, 0x60, 0xa0, 0x4b, 0x24, 0x9a, 0x08, 0x93, 0x00, 0x2a, + 0xe7, 0xd0, 0x9f, 0x4a, 0x24, 0x99, 0x0a, 0x60, 0xe3, 0xe7, 0x18, 0xab, + 0x01, 0x93, 0x19, 0xab, 0x00, 0x93, 0x32, 0x00, 0x3b, 0x00, 0x02, 0x98, + 0x01, 0xf0, 0x22, 0xf8, 0x63, 0x00, 0x03, 0x90, 0x5b, 0x0d, 0x74, 0xd0, + 0x3a, 0x03, 0x97, 0x4c, 0x12, 0x0b, 0x14, 0x43, 0x21, 0x00, 0x96, 0x4a, + 0x30, 0x00, 0x16, 0x95, 0x9e, 0x18, 0x00, 0x22, 0x94, 0x4b, 0xfe, 0xf7, + 0x17, 0xfc, 0x94, 0x4a, 0x94, 0x4b, 0xfe, 0xf7, 0xa1, 0xf9, 0x94, 0x4a, + 0x94, 0x4b, 0xfd, 0xf7, 0x77, 0xfa, 0x04, 0x00, 0x30, 0x00, 0x0d, 0x00, + 0x01, 0xf0, 0xf4, 0xf9, 0x91, 0x4a, 0x92, 0x4b, 0xfe, 0xf7, 0x94, 0xf9, + 0x02, 0x00, 0x0b, 0x00, 0x20, 0x00, 0x29, 0x00, 0xfd, 0xf7, 0x68, 0xfa, + 0x04, 0x00, 0x0d, 0x00, 0xfe, 0xf7, 0x60, 0xff, 0x00, 0x22, 0x07, 0x00, + 0x00, 0x23, 0x20, 0x00, 0x29, 0x00, 0xfd, 0xf7, 0x35, 0xfa, 0x00, 0x28, + 0x09, 0xd0, 0x38, 0x00, 0x01, 0xf0, 0xda, 0xf9, 0x2b, 0x00, 0x22, 0x00, + 0xfd, 0xf7, 0x26, 0xfa, 0x43, 0x42, 0x58, 0x41, 0x3f, 0x1a, 0x01, 0x23, + 0x14, 0x93, 0x16, 0x2f, 0x0d, 0xd8, 0x81, 0x49, 0xfb, 0x00, 0xc9, 0x18, + 0x08, 0x68, 0x49, 0x68, 0x06, 0x9a, 0x07, 0x9b, 0xfd, 0xf7, 0x30, 0xfa, + 0x00, 0x28, 0x46, 0xd0, 0x00, 0x23, 0x01, 0x3f, 0x14, 0x93, 0x18, 0x9b, + 0x9e, 0x1b, 0x00, 0x23, 0x0a, 0x93, 0x33, 0x00, 0x01, 0x3b, 0x0b, 0x93, + 0x04, 0xd5, 0x01, 0x23, 0x9b, 0x1b, 0x0a, 0x93, 0x00, 0x23, 0x0b, 0x93, + 0x00, 0x2f, 0x36, 0xdb, 0x0b, 0x9b, 0x11, 0x97, 0xdb, 0x19, 0x0b, 0x93, + 0x00, 0x23, 0x04, 0x93, 0x20, 0x9b, 0x01, 0x24, 0x09, 0x2b, 0x00, 0xd9, + 0x84, 0xe0, 0x05, 0x2b, 0x02, 0xdd, 0x00, 0x24, 0x04, 0x3b, 0x20, 0x93, + 0x20, 0x9b, 0x98, 0x1e, 0x03, 0x28, 0x00, 0xd9, 0x84, 0xe0, 0xfd, 0xf7, + 0x5b, 0xf8, 0x75, 0x77, 0x28, 0x6a, 0x18, 0x9b, 0x19, 0x9a, 0x9e, 0x18, + 0x65, 0x4b, 0xf2, 0x18, 0x20, 0x2a, 0x0f, 0xdd, 0x40, 0x23, 0x9b, 0x1a, + 0x9c, 0x40, 0x63, 0x4b, 0x06, 0x98, 0xf3, 0x18, 0xd8, 0x40, 0x20, 0x43, + 0xfe, 0xf7, 0x38, 0xff, 0x01, 0x23, 0x60, 0x4c, 0x01, 0x3e, 0x09, 0x19, + 0x16, 0x93, 0x7c, 0xe7, 0x20, 0x23, 0x06, 0x98, 0x9b, 0x1a, 0x98, 0x40, + 0xf2, 0xe7, 0x14, 0x90, 0xb9, 0xe7, 0x0a, 0x9b, 0xdb, 0x1b, 0x0a, 0x93, + 0x7b, 0x42, 0x04, 0x93, 0x00, 0x23, 0x11, 0x93, 0xc6, 0xe7, 0x01, 0x23, + 0x0d, 0x93, 0x21, 0x9b, 0x00, 0x2b, 0x59, 0xdd, 0x0c, 0x93, 0x09, 0x93, + 0x02, 0x9a, 0x55, 0x6a, 0x00, 0x22, 0x6a, 0x60, 0x04, 0x32, 0x10, 0x00, + 0x14, 0x30, 0x69, 0x68, 0x98, 0x42, 0x52, 0xd9, 0x02, 0x98, 0x00, 0xf0, + 0xdc, 0xfc, 0x02, 0x9b, 0x28, 0x60, 0x5b, 0x6a, 0x1b, 0x68, 0x08, 0x93, + 0x09, 0x9b, 0x0e, 0x2b, 0x00, 0xd9, 0x0a, 0xe1, 0x00, 0x2c, 0x00, 0xd1, + 0x07, 0xe1, 0x06, 0x9b, 0x07, 0x9c, 0x12, 0x93, 0x13, 0x94, 0x00, 0x2f, + 0x00, 0xdc, 0x89, 0xe0, 0x0f, 0x21, 0x3a, 0x00, 0x3e, 0x4b, 0x0a, 0x40, + 0xd2, 0x00, 0x9b, 0x18, 0x1d, 0x68, 0x5e, 0x68, 0x02, 0x23, 0x3c, 0x11, + 0x0e, 0x93, 0xe3, 0x06, 0x0b, 0xd5, 0x3d, 0x4b, 0x0c, 0x40, 0x1a, 0x6a, + 0x5b, 0x6a, 0x12, 0x98, 0x13, 0x99, 0xfd, 0xf7, 0xd1, 0xfc, 0x03, 0x23, + 0x06, 0x90, 0x07, 0x91, 0x0e, 0x93, 0x00, 0x23, 0x3a, 0xe0, 0x01, 0x23, + 0x0d, 0x93, 0x21, 0x9b, 0xfb, 0x18, 0x0c, 0x93, 0x01, 0x33, 0x09, 0x93, + 0x00, 0x2b, 0xbb, 0xdc, 0x01, 0x23, 0xb9, 0xe7, 0x00, 0x23, 0xb1, 0xe7, + 0x00, 0x23, 0xf1, 0xe7, 0x00, 0x23, 0x0d, 0x94, 0x20, 0x93, 0x01, 0x3b, + 0x00, 0x22, 0x0c, 0x93, 0x09, 0x93, 0x13, 0x33, 0x21, 0x92, 0xab, 0xe7, + 0x01, 0x23, 0x0d, 0x93, 0x02, 0x3b, 0xf5, 0xe7, 0x01, 0x23, 0x0c, 0x93, + 0x09, 0x93, 0x1a, 0x00, 0xf4, 0xe7, 0x01, 0x31, 0x69, 0x60, 0x52, 0x00, + 0xa3, 0xe7, 0x01, 0x23, 0x1c, 0x42, 0x0e, 0xd0, 0x0e, 0x9b, 0x21, 0x4a, + 0x01, 0x33, 0x0e, 0x93, 0x10, 0x9b, 0x28, 0x00, 0xdb, 0x00, 0x9b, 0x18, + 0x31, 0x00, 0x1a, 0x68, 0x5b, 0x68, 0xfe, 0xf7, 0x9f, 0xf8, 0x05, 0x00, + 0x0e, 0x00, 0x10, 0x9b, 0x64, 0x10, 0x01, 0x33, 0x10, 0x93, 0x00, 0x2c, + 0xe7, 0xd1, 0x06, 0x98, 0x07, 0x99, 0x2a, 0x00, 0x33, 0x00, 0xfd, 0xf7, + 0x87, 0xfc, 0x06, 0x90, 0x07, 0x91, 0x42, 0xe0, 0x00, 0x00, 0xf0, 0x7f, + 0x0f, 0x27, 0x00, 0x00, 0x7e, 0x99, 0x00, 0x00, 0x81, 0x99, 0x00, 0x00, + 0x7a, 0x93, 0x00, 0x00, 0x7b, 0x93, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x3f, + 0x01, 0xfc, 0xff, 0xff, 0x00, 0x00, 0xf8, 0x3f, 0x61, 0x43, 0x6f, 0x63, + 0xa7, 0x87, 0xd2, 0x3f, 0xb3, 0xc8, 0x60, 0x8b, 0x28, 0x8a, 0xc6, 0x3f, + 0xfb, 0x79, 0x9f, 0x50, 0x13, 0x44, 0xd3, 0x3f, 0xb0, 0x99, 0x00, 0x00, + 0x32, 0x04, 0x00, 0x00, 0x12, 0x04, 0x00, 0x00, 0x00, 0x00, 0x10, 0xfe, + 0x88, 0x99, 0x00, 0x00, 0x02, 0x23, 0x0e, 0x93, 0x00, 0x2f, 0x16, 0xd0, + 0x12, 0x98, 0x13, 0x99, 0x7c, 0x42, 0x0d, 0x33, 0x23, 0x40, 0xce, 0x4a, + 0xdb, 0x00, 0xd3, 0x18, 0x1a, 0x68, 0x5b, 0x68, 0xfe, 0xf7, 0x56, 0xf8, + 0x00, 0x23, 0x01, 0x26, 0x1d, 0x00, 0x06, 0x90, 0x07, 0x91, 0x24, 0x11, + 0x00, 0x2c, 0x00, 0xd0, 0x8c, 0xe0, 0x00, 0x2b, 0xb9, 0xd1, 0x14, 0x9b, + 0x00, 0x2b, 0x00, 0xd1, 0x96, 0xe0, 0x06, 0x9c, 0x07, 0x9d, 0x00, 0x22, + 0xc2, 0x4b, 0x20, 0x00, 0x29, 0x00, 0xfd, 0xf7, 0xf1, 0xf8, 0x00, 0x28, + 0x00, 0xd1, 0x8b, 0xe0, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd1, 0x87, 0xe0, + 0x0c, 0x9b, 0x00, 0x2b, 0x41, 0xdd, 0xbc, 0x4b, 0x00, 0x22, 0x20, 0x00, + 0x29, 0x00, 0xfe, 0xf7, 0x2f, 0xf8, 0x0e, 0x9b, 0x06, 0x90, 0x07, 0x91, + 0x01, 0x33, 0x0e, 0x93, 0x0c, 0x9b, 0x7e, 0x1e, 0x0e, 0x98, 0x10, 0x93, + 0x01, 0xf0, 0x80, 0xf8, 0x06, 0x9a, 0x07, 0x9b, 0xfe, 0xf7, 0x20, 0xf8, + 0x00, 0x22, 0xb2, 0x4b, 0xfd, 0xf7, 0xf6, 0xf8, 0xb1, 0x4a, 0x0e, 0x90, + 0x0f, 0x91, 0x0e, 0x9c, 0x0f, 0x9d, 0x94, 0x46, 0x0f, 0x9b, 0x63, 0x44, + 0x15, 0x93, 0x1d, 0x00, 0x10, 0x9b, 0x00, 0x2b, 0x61, 0xd1, 0x06, 0x98, + 0x07, 0x99, 0x00, 0x22, 0xaa, 0x4b, 0xfe, 0xf7, 0x7b, 0xfa, 0x22, 0x00, + 0x15, 0x9b, 0x06, 0x90, 0x07, 0x91, 0xfd, 0xf7, 0xc9, 0xf8, 0x00, 0x28, + 0x00, 0xd0, 0xa8, 0xe2, 0xa5, 0x48, 0x0f, 0x99, 0x84, 0x46, 0x61, 0x44, + 0x0b, 0x00, 0x06, 0x98, 0x07, 0x99, 0x22, 0x00, 0xfd, 0xf7, 0xa8, 0xf8, + 0x00, 0x28, 0x00, 0xd0, 0x95, 0xe2, 0x12, 0x9b, 0x13, 0x9c, 0x06, 0x93, + 0x07, 0x94, 0x19, 0x9b, 0x00, 0x2b, 0x00, 0xda, 0x5c, 0xe1, 0x0e, 0x2f, + 0x00, 0xdd, 0x59, 0xe1, 0x93, 0x4b, 0xfa, 0x00, 0x9b, 0x18, 0x5c, 0x68, + 0x1b, 0x68, 0x04, 0x93, 0x05, 0x94, 0x21, 0x9b, 0x00, 0x2b, 0x00, 0xdb, + 0xd8, 0xe0, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xdd, 0xd4, 0xe0, 0x00, 0xd0, + 0x7d, 0xe2, 0x04, 0x98, 0x05, 0x99, 0x00, 0x22, 0x8e, 0x4b, 0xfd, 0xf7, + 0xd1, 0xff, 0x06, 0x9a, 0x07, 0x9b, 0xfd, 0xf7, 0x9d, 0xf8, 0x09, 0x9b, + 0x04, 0x93, 0x1e, 0x00, 0x00, 0x28, 0x00, 0xd0, 0x4f, 0xe2, 0x08, 0x9b, + 0x08, 0x9a, 0x5d, 0x1c, 0x31, 0x23, 0x01, 0x37, 0x13, 0x70, 0x4b, 0xe2, + 0x34, 0x42, 0x0a, 0xd0, 0x0e, 0x9b, 0x85, 0x4a, 0x01, 0x33, 0x0e, 0x93, + 0xeb, 0x00, 0x9b, 0x18, 0x1a, 0x68, 0x5b, 0x68, 0xfd, 0xf7, 0xb4, 0xff, + 0x33, 0x00, 0x64, 0x10, 0x01, 0x35, 0x5f, 0xe7, 0x3e, 0x00, 0x09, 0x9b, + 0x84, 0xe7, 0x10, 0x9b, 0x0d, 0x99, 0x5a, 0x1e, 0x74, 0x4b, 0xd2, 0x00, + 0x9b, 0x18, 0x1a, 0x68, 0x5b, 0x68, 0x00, 0x29, 0x49, 0xd0, 0x00, 0x20, + 0x78, 0x49, 0xfd, 0xf7, 0x95, 0xfb, 0x2b, 0x00, 0x22, 0x00, 0xfe, 0xf7, + 0x0d, 0xfa, 0x08, 0x9b, 0x0e, 0x90, 0x0f, 0x91, 0x15, 0x93, 0x06, 0x98, + 0x07, 0x99, 0xfe, 0xf7, 0x69, 0xfd, 0x04, 0x00, 0x00, 0xf0, 0xec, 0xff, + 0x02, 0x00, 0x0b, 0x00, 0x06, 0x98, 0x07, 0x99, 0xfe, 0xf7, 0xfc, 0xf9, + 0x15, 0x9b, 0x30, 0x34, 0x5d, 0x1c, 0x1c, 0x70, 0x0e, 0x9a, 0x0f, 0x9b, + 0x06, 0x90, 0x07, 0x91, 0xfd, 0xf7, 0x32, 0xf8, 0x00, 0x28, 0x6c, 0xd1, + 0x06, 0x9a, 0x07, 0x9b, 0x00, 0x20, 0x5e, 0x49, 0xfe, 0xf7, 0xea, 0xf9, + 0x0e, 0x9a, 0x0f, 0x9b, 0xfd, 0xf7, 0x26, 0xf8, 0x00, 0x28, 0x00, 0xd0, + 0xc3, 0xe0, 0x08, 0x9b, 0x10, 0x9a, 0xeb, 0x1a, 0x9a, 0x42, 0x00, 0xdc, + 0x77, 0xe7, 0x0e, 0x98, 0x0f, 0x99, 0x00, 0x22, 0x55, 0x4b, 0xfd, 0xf7, + 0x65, 0xff, 0x00, 0x22, 0x0e, 0x90, 0x0f, 0x91, 0x06, 0x98, 0x07, 0x99, + 0x51, 0x4b, 0xfd, 0xf7, 0x5d, 0xff, 0x15, 0x95, 0x06, 0x90, 0x07, 0x91, + 0xc1, 0xe7, 0x20, 0x00, 0x29, 0x00, 0xfd, 0xf7, 0x55, 0xff, 0x08, 0x9c, + 0x10, 0x9a, 0x23, 0x00, 0x94, 0x46, 0x0e, 0x90, 0x0f, 0x91, 0x63, 0x44, + 0x15, 0x93, 0x06, 0x98, 0x07, 0x99, 0xfe, 0xf7, 0x1f, 0xfd, 0x05, 0x00, + 0x00, 0xf0, 0xa2, 0xff, 0x0b, 0x00, 0x02, 0x00, 0x06, 0x98, 0x07, 0x99, + 0xfe, 0xf7, 0xb2, 0xf9, 0x30, 0x35, 0x15, 0x9b, 0x25, 0x70, 0x01, 0x34, + 0x06, 0x90, 0x07, 0x91, 0xa3, 0x42, 0x2a, 0xd1, 0x0e, 0x98, 0x0f, 0x99, + 0x08, 0x9a, 0x10, 0x9b, 0x94, 0x46, 0x63, 0x44, 0x00, 0x22, 0x1d, 0x00, + 0x3f, 0x4b, 0xfd, 0xf7, 0x07, 0xf8, 0x02, 0x00, 0x0b, 0x00, 0x06, 0x98, + 0x07, 0x99, 0xfc, 0xf7, 0xed, 0xff, 0x00, 0x28, 0x00, 0xd0, 0x76, 0xe0, + 0x0e, 0x9a, 0x0f, 0x9b, 0x00, 0x20, 0x38, 0x49, 0xfe, 0xf7, 0x90, 0xf9, + 0x02, 0x00, 0x0b, 0x00, 0x06, 0x98, 0x07, 0x99, 0xfc, 0xf7, 0xca, 0xff, + 0x00, 0x28, 0x00, 0xd1, 0x21, 0xe7, 0x6b, 0x1e, 0x1a, 0x78, 0x30, 0x2a, + 0x01, 0xd0, 0x37, 0x00, 0x3f, 0xe0, 0x1d, 0x00, 0xf7, 0xe7, 0x06, 0x98, + 0x07, 0x99, 0x00, 0x22, 0x26, 0x4b, 0xfd, 0xf7, 0x07, 0xff, 0x06, 0x90, + 0x07, 0x91, 0xb6, 0xe7, 0x08, 0x9e, 0x04, 0x9a, 0x05, 0x9b, 0x06, 0x98, + 0x07, 0x99, 0xfd, 0xf7, 0xf3, 0xfa, 0xfe, 0xf7, 0xd1, 0xfc, 0x04, 0x00, + 0x00, 0xf0, 0x54, 0xff, 0x04, 0x9a, 0x05, 0x9b, 0xfd, 0xf7, 0xf4, 0xfe, + 0x02, 0x00, 0x0b, 0x00, 0x06, 0x98, 0x07, 0x99, 0xfe, 0xf7, 0x60, 0xf9, + 0x23, 0x00, 0x30, 0x33, 0x33, 0x70, 0x09, 0x9a, 0x08, 0x9b, 0x75, 0x1c, + 0xeb, 0x1a, 0x9a, 0x42, 0x48, 0xd1, 0x02, 0x00, 0x0b, 0x00, 0xfc, 0xf7, + 0xbb, 0xff, 0x04, 0x9a, 0x05, 0x9b, 0x06, 0x90, 0x07, 0x91, 0xfc, 0xf7, + 0xa1, 0xff, 0x00, 0x28, 0x2a, 0xd1, 0x04, 0x9a, 0x05, 0x9b, 0x06, 0x98, + 0x07, 0x99, 0xfc, 0xf7, 0x7f, 0xff, 0x00, 0x28, 0x01, 0xd0, 0xe3, 0x07, + 0x20, 0xd4, 0x03, 0x99, 0x02, 0x98, 0x00, 0xf0, 0xdc, 0xfa, 0x00, 0x23, + 0x2b, 0x70, 0x22, 0x9b, 0x01, 0x37, 0x1f, 0x60, 0x24, 0x9b, 0x00, 0x2b, + 0x00, 0xd1, 0xe6, 0xe4, 0x1d, 0x60, 0xe4, 0xe4, 0xb0, 0x99, 0x00, 0x00, + 0x00, 0x00, 0xf0, 0x3f, 0x00, 0x00, 0x24, 0x40, 0x00, 0x00, 0x1c, 0x40, + 0x00, 0x00, 0xc0, 0xfc, 0x00, 0x00, 0x14, 0x40, 0x00, 0x00, 0xc0, 0x7c, + 0x88, 0x99, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x3f, 0x3e, 0x00, 0x6b, 0x1e, + 0x1a, 0x78, 0x39, 0x2a, 0x06, 0xd1, 0x08, 0x9a, 0x9a, 0x42, 0x07, 0xd1, + 0x30, 0x23, 0x13, 0x70, 0x13, 0x00, 0x01, 0x36, 0x1a, 0x78, 0x01, 0x32, + 0x1a, 0x70, 0x8c, 0xe7, 0x1d, 0x00, 0xee, 0xe7, 0x00, 0x22, 0xa4, 0x4b, + 0xfd, 0xf7, 0x98, 0xfe, 0x00, 0x22, 0x00, 0x23, 0x06, 0x90, 0x07, 0x91, + 0x2e, 0x00, 0xfc, 0xf7, 0x3d, 0xff, 0x00, 0x28, 0x8b, 0xd0, 0xbe, 0xe7, + 0x0d, 0x9a, 0x00, 0x2a, 0x00, 0xd1, 0xda, 0xe0, 0x20, 0x9a, 0x01, 0x2a, + 0x00, 0xdd, 0xbd, 0xe0, 0x16, 0x9a, 0x00, 0x2a, 0x00, 0xd1, 0xb5, 0xe0, + 0x98, 0x4a, 0x9b, 0x18, 0x04, 0x9d, 0x0a, 0x9c, 0x0a, 0x9a, 0x01, 0x21, + 0xd2, 0x18, 0x0a, 0x92, 0x0b, 0x9a, 0x02, 0x98, 0xd3, 0x18, 0x0b, 0x93, + 0x00, 0xf0, 0x25, 0xfb, 0x06, 0x00, 0x00, 0x2c, 0x0e, 0xdd, 0x0b, 0x9b, + 0x00, 0x2b, 0x0b, 0xdd, 0x0b, 0x9a, 0x23, 0x00, 0x94, 0x42, 0x00, 0xdd, + 0x13, 0x00, 0x0a, 0x9a, 0xe4, 0x1a, 0xd2, 0x1a, 0x0a, 0x92, 0x0b, 0x9a, + 0xd3, 0x1a, 0x0b, 0x93, 0x04, 0x9b, 0x00, 0x2b, 0x1f, 0xd0, 0x0d, 0x9b, + 0x00, 0x2b, 0x00, 0xd1, 0xaf, 0xe0, 0x00, 0x2d, 0x11, 0xd0, 0x31, 0x00, + 0x2a, 0x00, 0x02, 0x98, 0x00, 0xf0, 0x9e, 0xfb, 0x03, 0x9a, 0x01, 0x00, + 0x06, 0x00, 0x02, 0x98, 0x00, 0xf0, 0x08, 0xfb, 0x03, 0x99, 0x10, 0x90, + 0x02, 0x98, 0x00, 0xf0, 0x5a, 0xfa, 0x10, 0x9b, 0x03, 0x93, 0x04, 0x9b, + 0x5a, 0x1b, 0x04, 0xd0, 0x03, 0x99, 0x02, 0x98, 0x00, 0xf0, 0x8a, 0xfb, + 0x03, 0x90, 0x01, 0x21, 0x02, 0x98, 0x00, 0xf0, 0xec, 0xfa, 0x11, 0x9b, + 0x04, 0x90, 0x00, 0x2b, 0x00, 0xd1, 0xe3, 0xe1, 0x1a, 0x00, 0x01, 0x00, + 0x02, 0x98, 0x00, 0xf0, 0x7b, 0xfb, 0x20, 0x9b, 0x04, 0x90, 0x01, 0x2b, + 0x00, 0xdd, 0x82, 0xe0, 0x00, 0x25, 0x06, 0x9b, 0xab, 0x42, 0x0e, 0xd1, + 0x07, 0x9b, 0x1b, 0x03, 0xab, 0x42, 0x0a, 0xd1, 0x17, 0x9b, 0x07, 0x9a, + 0x13, 0x42, 0x06, 0xd0, 0x0a, 0x9b, 0x01, 0x35, 0x01, 0x33, 0x0a, 0x93, + 0x0b, 0x9b, 0x01, 0x33, 0x0b, 0x93, 0x11, 0x9b, 0x01, 0x20, 0x00, 0x2b, + 0x6c, 0xd1, 0x0b, 0x9b, 0x18, 0x18, 0x1f, 0x23, 0x18, 0x40, 0x7e, 0xd0, + 0x01, 0x33, 0x1b, 0x1a, 0x04, 0x2b, 0x70, 0xdd, 0x1c, 0x23, 0x18, 0x1a, + 0x0a, 0x9b, 0x24, 0x18, 0x1b, 0x18, 0x0a, 0x93, 0x0b, 0x9b, 0x1b, 0x18, + 0x0b, 0x93, 0x0a, 0x9b, 0x00, 0x2b, 0x05, 0xdd, 0x1a, 0x00, 0x03, 0x99, + 0x02, 0x98, 0x00, 0xf0, 0x97, 0xfb, 0x03, 0x90, 0x0b, 0x9b, 0x00, 0x2b, + 0x05, 0xdd, 0x1a, 0x00, 0x04, 0x99, 0x02, 0x98, 0x00, 0xf0, 0x8e, 0xfb, + 0x04, 0x90, 0x14, 0x9b, 0x00, 0x2b, 0x5e, 0xd0, 0x04, 0x99, 0x03, 0x98, + 0x00, 0xf0, 0xd8, 0xfb, 0x00, 0x28, 0x58, 0xda, 0x00, 0x23, 0x0a, 0x22, + 0x03, 0x99, 0x02, 0x98, 0x00, 0xf0, 0x0c, 0xfa, 0x0d, 0x9b, 0x01, 0x3f, + 0x03, 0x90, 0x00, 0x2b, 0x00, 0xd1, 0x90, 0xe1, 0x00, 0x23, 0x31, 0x00, + 0x0a, 0x22, 0x02, 0x98, 0x00, 0xf0, 0x00, 0xfa, 0x0c, 0x9b, 0x06, 0x00, + 0x00, 0x2b, 0x00, 0xdd, 0x88, 0xe0, 0x20, 0x9b, 0x02, 0x2b, 0x00, 0xdc, + 0x84, 0xe0, 0x44, 0xe0, 0x36, 0x23, 0x18, 0x9a, 0x9b, 0x1a, 0x47, 0xe7, + 0x09, 0x9b, 0x5d, 0x1e, 0x04, 0x9b, 0xab, 0x42, 0x08, 0xdb, 0x5d, 0x1b, + 0x09, 0x9b, 0x00, 0x2b, 0x0c, 0xda, 0x0a, 0x9b, 0x09, 0x9a, 0x9c, 0x1a, + 0x00, 0x23, 0x3b, 0xe7, 0x04, 0x9b, 0x04, 0x95, 0xea, 0x1a, 0x11, 0x9b, + 0x00, 0x25, 0x9b, 0x18, 0x11, 0x93, 0xef, 0xe7, 0x0a, 0x9c, 0x09, 0x9b, + 0x30, 0xe7, 0x04, 0x9d, 0x0a, 0x9c, 0x0d, 0x9e, 0x37, 0xe7, 0x04, 0x9a, + 0x64, 0xe7, 0x00, 0x25, 0x04, 0x9b, 0x04, 0x9a, 0x1b, 0x69, 0x10, 0x93, + 0x03, 0x33, 0x9b, 0x00, 0xd3, 0x18, 0x58, 0x68, 0x00, 0xf0, 0x06, 0xfa, + 0x20, 0x23, 0x18, 0x1a, 0x85, 0xe7, 0x04, 0x2b, 0x95, 0xd0, 0x0a, 0x9a, + 0x1c, 0x33, 0xd2, 0x18, 0x0a, 0x92, 0x0b, 0x9a, 0xe4, 0x18, 0xd3, 0x18, + 0x8c, 0xe7, 0x03, 0x00, 0xf5, 0xe7, 0x09, 0x9b, 0x00, 0x2b, 0x3d, 0xdc, + 0x20, 0x9b, 0x02, 0x2b, 0x3a, 0xdd, 0x09, 0x9b, 0x0c, 0x93, 0x0c, 0x9b, + 0x00, 0x2b, 0x0c, 0xd1, 0x04, 0x99, 0x05, 0x22, 0x02, 0x98, 0x00, 0xf0, + 0xa9, 0xf9, 0x04, 0x90, 0x01, 0x00, 0x03, 0x98, 0x00, 0xf0, 0x68, 0xfb, + 0x00, 0x28, 0x00, 0xdd, 0xaf, 0xe5, 0x21, 0x9b, 0x08, 0x9d, 0xdf, 0x43, + 0x00, 0x23, 0x09, 0x93, 0x04, 0x99, 0x02, 0x98, 0x00, 0xf0, 0x7f, 0xf9, + 0x00, 0x2e, 0x00, 0xd1, 0x9b, 0xe6, 0x09, 0x9b, 0x00, 0x2b, 0x05, 0xd0, + 0xb3, 0x42, 0x03, 0xd0, 0x19, 0x00, 0x02, 0x98, 0x00, 0xf0, 0x73, 0xf9, + 0x31, 0x00, 0x02, 0x98, 0x00, 0xf0, 0x6f, 0xf9, 0x8d, 0xe6, 0x10, 0x9b, + 0x04, 0x93, 0x1e, 0x00, 0xe1, 0xe7, 0x00, 0x23, 0xfa, 0xe7, 0x10, 0x9b, + 0x37, 0x00, 0x04, 0x93, 0x1e, 0x00, 0x8a, 0xe5, 0x00, 0x00, 0x24, 0x40, + 0x33, 0x04, 0x00, 0x00, 0x0d, 0x9b, 0x00, 0x2b, 0x00, 0xd1, 0xb2, 0xe0, + 0x09, 0x9b, 0x0c, 0x93, 0x00, 0x2c, 0x05, 0xdd, 0x31, 0x00, 0x22, 0x00, + 0x02, 0x98, 0x00, 0xf0, 0xdd, 0xfa, 0x06, 0x00, 0x30, 0x00, 0x00, 0x2d, + 0x11, 0xd0, 0x71, 0x68, 0x02, 0x98, 0x00, 0xf0, 0x12, 0xf9, 0x31, 0x00, + 0x04, 0x00, 0x33, 0x69, 0x0c, 0x31, 0x9a, 0x1c, 0x92, 0x00, 0x0c, 0x30, + 0xfe, 0xf7, 0x04, 0xfc, 0x01, 0x22, 0x21, 0x00, 0x02, 0x98, 0x00, 0xf0, + 0xc7, 0xfa, 0x09, 0x96, 0x06, 0x00, 0x08, 0x9b, 0x0a, 0x93, 0x04, 0x99, + 0x03, 0x98, 0xff, 0xf7, 0x7d, 0xfa, 0x09, 0x99, 0x0d, 0x90, 0x04, 0x00, + 0x03, 0x98, 0x00, 0xf0, 0x0b, 0xfb, 0x32, 0x00, 0x10, 0x90, 0x04, 0x99, + 0x02, 0x98, 0x00, 0xf0, 0x1f, 0xfb, 0x01, 0x23, 0x0b, 0x93, 0xc3, 0x68, + 0x30, 0x34, 0x05, 0x00, 0x00, 0x2b, 0x04, 0xd1, 0x01, 0x00, 0x03, 0x98, + 0x00, 0xf0, 0xfa, 0xfa, 0x0b, 0x90, 0x29, 0x00, 0x02, 0x98, 0x00, 0xf0, + 0x18, 0xf9, 0x0b, 0x9b, 0x20, 0x9a, 0x13, 0x43, 0x0e, 0xd1, 0x06, 0x9a, + 0x01, 0x33, 0x13, 0x42, 0x0a, 0xd1, 0x39, 0x2c, 0x26, 0xd0, 0x10, 0x9b, + 0x00, 0x2b, 0x01, 0xdd, 0x0d, 0x9c, 0x31, 0x34, 0x0a, 0x9b, 0x5d, 0x1c, + 0x1c, 0x70, 0x81, 0xe7, 0x10, 0x9b, 0x00, 0x2b, 0x07, 0xdb, 0x1d, 0x00, + 0x20, 0x9b, 0x1d, 0x43, 0x22, 0xd1, 0x01, 0x23, 0x06, 0x9a, 0x13, 0x42, + 0x1e, 0xd1, 0x0b, 0x9b, 0x00, 0x2b, 0xed, 0xdd, 0x03, 0x99, 0x01, 0x22, + 0x02, 0x98, 0x00, 0xf0, 0x7d, 0xfa, 0x04, 0x99, 0x03, 0x90, 0x00, 0xf0, + 0xcb, 0xfa, 0x00, 0x28, 0x02, 0xdc, 0xe1, 0xd1, 0xe3, 0x07, 0xdf, 0xd5, + 0x39, 0x2c, 0xdb, 0xd1, 0x0a, 0x9b, 0x0a, 0x9a, 0x5d, 0x1c, 0x39, 0x23, + 0x13, 0x70, 0x6b, 0x1e, 0x1a, 0x78, 0x39, 0x2a, 0x67, 0xd0, 0x01, 0x32, + 0x1a, 0x70, 0x57, 0xe7, 0x0a, 0x9b, 0x5d, 0x1c, 0x0b, 0x9b, 0x00, 0x2b, + 0x04, 0xdd, 0x39, 0x2c, 0xec, 0xd0, 0x01, 0x34, 0x0a, 0x9b, 0xc9, 0xe7, + 0x0a, 0x9b, 0x0c, 0x9a, 0x1c, 0x70, 0x08, 0x9b, 0xeb, 0x1a, 0x93, 0x42, + 0x3e, 0xd0, 0x00, 0x23, 0x0a, 0x22, 0x03, 0x99, 0x02, 0x98, 0x00, 0xf0, + 0xdd, 0xf8, 0x09, 0x9b, 0x03, 0x90, 0xb3, 0x42, 0x09, 0xd1, 0x00, 0x23, + 0x0a, 0x22, 0x09, 0x99, 0x02, 0x98, 0x00, 0xf0, 0xd3, 0xf8, 0x09, 0x90, + 0x06, 0x00, 0x0a, 0x95, 0x7d, 0xe7, 0x09, 0x99, 0x00, 0x23, 0x0a, 0x22, + 0x02, 0x98, 0x00, 0xf0, 0xc9, 0xf8, 0x00, 0x23, 0x09, 0x90, 0x0a, 0x22, + 0x31, 0x00, 0x02, 0x98, 0x00, 0xf0, 0xc2, 0xf8, 0xee, 0xe7, 0x09, 0x9b, + 0x0c, 0x93, 0x08, 0x9b, 0x06, 0x93, 0x04, 0x99, 0x03, 0x98, 0xff, 0xf7, + 0xe9, 0xf9, 0x06, 0x9b, 0x30, 0x30, 0x5d, 0x1c, 0x18, 0x70, 0x0c, 0x9a, + 0x08, 0x9b, 0x04, 0x00, 0xeb, 0x1a, 0x9a, 0x42, 0x08, 0xdd, 0x00, 0x23, + 0x0a, 0x22, 0x03, 0x99, 0x02, 0x98, 0x00, 0xf0, 0xa9, 0xf8, 0x06, 0x95, + 0x03, 0x90, 0xe8, 0xe7, 0x00, 0x23, 0x09, 0x93, 0x03, 0x99, 0x01, 0x22, + 0x02, 0x98, 0x00, 0xf0, 0x11, 0xfa, 0x04, 0x99, 0x03, 0x90, 0x00, 0xf0, + 0x5f, 0xfa, 0x00, 0x28, 0x9d, 0xdc, 0x01, 0xd1, 0xe3, 0x07, 0x9a, 0xd4, + 0x6b, 0x1e, 0x1a, 0x78, 0x30, 0x2a, 0x00, 0xd0, 0xf4, 0xe6, 0x1d, 0x00, + 0xf8, 0xe7, 0x08, 0x9a, 0x9a, 0x42, 0x03, 0xd1, 0x31, 0x23, 0x01, 0x37, + 0x13, 0x70, 0xeb, 0xe6, 0x1d, 0x00, 0x8a, 0xe7, 0x0b, 0x4b, 0x24, 0x9a, + 0x08, 0x93, 0x0b, 0x4b, 0x00, 0x2a, 0x01, 0xd0, 0xff, 0xf7, 0x77, 0xfa, + 0xff, 0xf7, 0x77, 0xfa, 0x20, 0x9b, 0x01, 0x2b, 0x00, 0xdc, 0x21, 0xe6, + 0x11, 0x9d, 0x01, 0x20, 0x35, 0xe6, 0x0c, 0x9b, 0x00, 0x2b, 0xb2, 0xdc, + 0x20, 0x9b, 0x02, 0x2b, 0xaf, 0xdd, 0xbc, 0xe6, 0x75, 0x99, 0x00, 0x00, + 0x7d, 0x99, 0x00, 0x00, 0x03, 0x4b, 0x1b, 0x68, 0x18, 0x6a, 0x00, 0x28, + 0x00, 0xd1, 0x02, 0x48, 0xf0, 0x30, 0x70, 0x47, 0x28, 0x00, 0x00, 0x20, + 0x8c, 0x00, 0x00, 0x20, 0xc9, 0xb2, 0x82, 0x18, 0x90, 0x42, 0x01, 0xd1, + 0x00, 0x20, 0x70, 0x47, 0x03, 0x78, 0x8b, 0x42, 0xfb, 0xd0, 0x01, 0x30, + 0xf6, 0xe7, 0x70, 0x47, 0x70, 0x47, 0x70, 0xb5, 0x46, 0x6a, 0x04, 0x00, + 0x0d, 0x00, 0x00, 0x2e, 0x07, 0xd1, 0x10, 0x20, 0xfe, 0xf7, 0xcc, 0xfa, + 0x60, 0x62, 0x46, 0x60, 0x86, 0x60, 0x06, 0x60, 0xc6, 0x60, 0x66, 0x6a, + 0xf3, 0x68, 0x00, 0x2b, 0x13, 0xd0, 0x63, 0x6a, 0xaa, 0x00, 0xdb, 0x68, + 0x9b, 0x18, 0x18, 0x68, 0x00, 0x28, 0x18, 0xd1, 0x01, 0x21, 0x0e, 0x00, + 0xae, 0x40, 0x72, 0x1d, 0x92, 0x00, 0x20, 0x00, 0x00, 0xf0, 0xc6, 0xfa, + 0x00, 0x28, 0x0c, 0xd0, 0x45, 0x60, 0x86, 0x60, 0x0d, 0xe0, 0x21, 0x22, + 0x04, 0x21, 0x20, 0x00, 0x00, 0xf0, 0xbc, 0xfa, 0x63, 0x6a, 0xf0, 0x60, + 0xdb, 0x68, 0x00, 0x2b, 0xe1, 0xd1, 0x00, 0x20, 0x70, 0xbd, 0x02, 0x68, + 0x1a, 0x60, 0x00, 0x23, 0x03, 0x61, 0xc3, 0x60, 0xf8, 0xe7, 0x70, 0xb5, + 0x44, 0x6a, 0x06, 0x00, 0x0d, 0x00, 0x00, 0x2c, 0x07, 0xd1, 0x10, 0x20, + 0xfe, 0xf7, 0x94, 0xfa, 0x70, 0x62, 0x44, 0x60, 0x84, 0x60, 0x04, 0x60, + 0xc4, 0x60, 0x00, 0x2d, 0x07, 0xd0, 0x73, 0x6a, 0x6a, 0x68, 0xdb, 0x68, + 0x92, 0x00, 0x9b, 0x18, 0x1a, 0x68, 0x2a, 0x60, 0x1d, 0x60, 0x70, 0xbd, + 0xf7, 0xb5, 0x1e, 0x00, 0x14, 0x23, 0x9c, 0x46, 0x07, 0x00, 0x0c, 0x00, + 0x00, 0x20, 0x0d, 0x69, 0x8c, 0x44, 0x63, 0x46, 0x1b, 0x68, 0x01, 0x30, + 0x99, 0xb2, 0x63, 0x46, 0x1b, 0x68, 0x51, 0x43, 0x1b, 0x0c, 0x53, 0x43, + 0x89, 0x19, 0x0e, 0x0c, 0x9b, 0x19, 0x89, 0xb2, 0x1e, 0x0c, 0x1b, 0x04, + 0x5b, 0x18, 0x61, 0x46, 0x08, 0xc1, 0x8c, 0x46, 0x85, 0x42, 0xea, 0xdc, + 0x00, 0x2e, 0x1b, 0xd0, 0xa3, 0x68, 0xab, 0x42, 0x12, 0xdc, 0x63, 0x68, + 0x38, 0x00, 0x59, 0x1c, 0xff, 0xf7, 0x87, 0xff, 0x21, 0x00, 0x23, 0x69, + 0x01, 0x90, 0x9a, 0x1c, 0x92, 0x00, 0x0c, 0x31, 0x0c, 0x30, 0xfe, 0xf7, + 0x79, 0xfa, 0x21, 0x00, 0x38, 0x00, 0xff, 0xf7, 0xb2, 0xff, 0x01, 0x9c, + 0x2b, 0x1d, 0x9b, 0x00, 0xe3, 0x18, 0x01, 0x35, 0x5e, 0x60, 0x25, 0x61, + 0x20, 0x00, 0xfe, 0xbd, 0x03, 0x00, 0x02, 0x0c, 0x00, 0x20, 0x82, 0x42, + 0x01, 0xd1, 0x1b, 0x04, 0x10, 0x30, 0x1a, 0x0e, 0x01, 0xd1, 0x08, 0x30, + 0x1b, 0x02, 0x1a, 0x0f, 0x01, 0xd1, 0x04, 0x30, 0x1b, 0x01, 0x9a, 0x0f, + 0x01, 0xd1, 0x02, 0x30, 0x9b, 0x00, 0x00, 0x2b, 0x03, 0xdb, 0x01, 0x30, + 0x5b, 0x00, 0x00, 0xd4, 0x20, 0x20, 0x70, 0x47, 0x07, 0x22, 0x03, 0x68, + 0x10, 0xb5, 0x01, 0x00, 0x1a, 0x40, 0x0d, 0xd0, 0x01, 0x24, 0x00, 0x20, + 0x23, 0x42, 0x05, 0xd1, 0x02, 0x30, 0x03, 0x42, 0x03, 0xd0, 0xe3, 0x40, + 0x20, 0x00, 0x0b, 0x60, 0x10, 0xbd, 0x9b, 0x08, 0x0b, 0x60, 0xfb, 0xe7, + 0x9c, 0xb2, 0x10, 0x00, 0x00, 0x2c, 0x01, 0xd1, 0x10, 0x20, 0x1b, 0x0c, + 0xda, 0xb2, 0x00, 0x2a, 0x01, 0xd1, 0x08, 0x30, 0x1b, 0x0a, 0x1a, 0x07, + 0x01, 0xd1, 0x04, 0x30, 0x1b, 0x09, 0x9a, 0x07, 0x01, 0xd1, 0x02, 0x30, + 0x9b, 0x08, 0xda, 0x07, 0xe8, 0xd4, 0x5b, 0x08, 0x01, 0xd0, 0x01, 0x30, + 0xe4, 0xe7, 0x20, 0x20, 0xe0, 0xe7, 0x10, 0xb5, 0x0c, 0x00, 0x01, 0x21, + 0xff, 0xf7, 0x23, 0xff, 0x01, 0x23, 0x44, 0x61, 0x03, 0x61, 0x10, 0xbd, + 0xf0, 0xb5, 0x0b, 0x69, 0x14, 0x00, 0x12, 0x69, 0x89, 0xb0, 0x0d, 0x00, + 0x93, 0x42, 0x01, 0xda, 0x25, 0x00, 0x0c, 0x00, 0x2f, 0x69, 0x26, 0x69, + 0x69, 0x68, 0xbb, 0x19, 0x02, 0x93, 0xab, 0x68, 0xba, 0x19, 0x93, 0x42, + 0x00, 0xda, 0x01, 0x31, 0xff, 0xf7, 0x09, 0xff, 0x02, 0x00, 0xbb, 0x19, + 0x14, 0x32, 0x9b, 0x00, 0xd3, 0x18, 0x9c, 0x46, 0x00, 0x21, 0x13, 0x00, + 0x04, 0x90, 0x63, 0x45, 0x1d, 0xd3, 0x14, 0x35, 0xbf, 0x00, 0xeb, 0x19, + 0x14, 0x34, 0xb6, 0x00, 0x05, 0x93, 0xa3, 0x19, 0x03, 0x95, 0x01, 0x94, + 0x07, 0x93, 0x07, 0x9b, 0x01, 0x99, 0x99, 0x42, 0x11, 0xd3, 0x02, 0x9b, + 0x00, 0x2b, 0x06, 0xdd, 0x04, 0x23, 0x5b, 0x42, 0x9c, 0x44, 0x63, 0x46, + 0x1b, 0x68, 0x00, 0x2b, 0x51, 0xd0, 0x04, 0x9b, 0x02, 0x9a, 0x18, 0x00, + 0x1a, 0x61, 0x09, 0xb0, 0xf0, 0xbd, 0x02, 0xc3, 0xdd, 0xe7, 0x01, 0x9b, + 0x1b, 0x68, 0x98, 0xb2, 0x00, 0x28, 0x1c, 0xd0, 0x15, 0x00, 0x00, 0x26, + 0x03, 0x9f, 0x02, 0xcf, 0x2c, 0x68, 0x8b, 0xb2, 0x43, 0x43, 0x09, 0x0c, + 0x41, 0x43, 0xa4, 0xb2, 0x1b, 0x19, 0x9b, 0x19, 0x0e, 0x00, 0x29, 0x68, + 0x06, 0x95, 0x09, 0x0c, 0x71, 0x18, 0x1e, 0x0c, 0x89, 0x19, 0x0e, 0x0c, + 0x9b, 0xb2, 0x09, 0x04, 0x0b, 0x43, 0x08, 0xc5, 0x05, 0x9b, 0xbb, 0x42, + 0xe7, 0xd8, 0x06, 0x9b, 0x5e, 0x60, 0x01, 0x9b, 0x1b, 0x68, 0x1d, 0x0c, + 0x1e, 0xd0, 0x10, 0x00, 0x00, 0x27, 0x13, 0x68, 0x03, 0x9e, 0x31, 0x68, + 0x04, 0x68, 0x89, 0xb2, 0x69, 0x43, 0x24, 0x0c, 0x09, 0x19, 0xc9, 0x19, + 0x0f, 0x04, 0x9b, 0xb2, 0x3b, 0x43, 0x03, 0x60, 0x80, 0xce, 0x43, 0x68, + 0x3f, 0x0c, 0x6f, 0x43, 0x9b, 0xb2, 0xfb, 0x18, 0x09, 0x0c, 0x5b, 0x18, + 0x05, 0x99, 0x06, 0x90, 0x1f, 0x0c, 0x04, 0x30, 0xb1, 0x42, 0xe6, 0xd8, + 0x06, 0x99, 0x4b, 0x60, 0x01, 0x9b, 0x04, 0x32, 0x04, 0x33, 0x01, 0x93, + 0x9f, 0xe7, 0x02, 0x9b, 0x01, 0x3b, 0x02, 0x93, 0x9f, 0xe7, 0x00, 0x00, + 0x03, 0x23, 0xf7, 0xb5, 0x13, 0x40, 0x05, 0x00, 0x0e, 0x00, 0x14, 0x00, + 0x00, 0x2b, 0x08, 0xd0, 0x22, 0x49, 0x01, 0x3b, 0x9a, 0x00, 0x52, 0x58, + 0x00, 0x23, 0x31, 0x00, 0xff, 0xf7, 0xd0, 0xfe, 0x06, 0x00, 0xa3, 0x10, + 0x01, 0x93, 0x36, 0xd0, 0x6c, 0x6a, 0x00, 0x2c, 0x07, 0xd1, 0x10, 0x20, + 0xfe, 0xf7, 0x4a, 0xf9, 0x68, 0x62, 0x44, 0x60, 0x84, 0x60, 0x04, 0x60, + 0xc4, 0x60, 0x6f, 0x6a, 0xbc, 0x68, 0x00, 0x2c, 0x07, 0xd1, 0x16, 0x49, + 0x28, 0x00, 0xff, 0xf7, 0x40, 0xff, 0x00, 0x23, 0x04, 0x00, 0xb8, 0x60, + 0x03, 0x60, 0x01, 0x22, 0x01, 0x9b, 0x13, 0x42, 0x0a, 0xd0, 0x31, 0x00, + 0x22, 0x00, 0x28, 0x00, 0xff, 0xf7, 0x3c, 0xff, 0x07, 0x00, 0x31, 0x00, + 0x28, 0x00, 0xff, 0xf7, 0x8e, 0xfe, 0x3e, 0x00, 0x01, 0x9b, 0x5b, 0x10, + 0x01, 0x93, 0x0c, 0xd0, 0x20, 0x68, 0x00, 0x28, 0x07, 0xd1, 0x22, 0x00, + 0x21, 0x00, 0x28, 0x00, 0xff, 0xf7, 0x2a, 0xff, 0x00, 0x23, 0x20, 0x60, + 0x03, 0x60, 0x04, 0x00, 0xdf, 0xe7, 0x30, 0x00, 0xfe, 0xbd, 0xc0, 0x46, + 0x78, 0x9a, 0x00, 0x00, 0x71, 0x02, 0x00, 0x00, 0xf0, 0xb5, 0x0d, 0x00, + 0x17, 0x00, 0x2b, 0x69, 0x54, 0x11, 0x85, 0xb0, 0xe3, 0x18, 0x01, 0x93, + 0x01, 0x33, 0x00, 0x93, 0x49, 0x68, 0xab, 0x68, 0x02, 0x90, 0x00, 0x9a, + 0x93, 0x42, 0x35, 0xdb, 0x02, 0x98, 0xff, 0xf7, 0x2a, 0xfe, 0x00, 0x23, + 0x02, 0x00, 0x06, 0x00, 0x19, 0x00, 0x14, 0x32, 0xa3, 0x42, 0x2e, 0xdb, + 0xe3, 0x43, 0xdb, 0x17, 0x1c, 0x40, 0x2b, 0x00, 0xa4, 0x00, 0x14, 0x19, + 0x2a, 0x69, 0x14, 0x33, 0x92, 0x00, 0x9a, 0x18, 0x94, 0x46, 0x1f, 0x22, + 0x17, 0x40, 0x24, 0xd0, 0x01, 0x32, 0xd2, 0x1b, 0x03, 0x92, 0x00, 0x22, + 0x19, 0x68, 0x20, 0x00, 0xb9, 0x40, 0x0a, 0x43, 0x04, 0xc4, 0x04, 0xcb, + 0x03, 0x99, 0xca, 0x40, 0x9c, 0x45, 0xf5, 0xd8, 0x42, 0x60, 0x00, 0x2a, + 0x02, 0xd0, 0x01, 0x9b, 0x02, 0x33, 0x00, 0x93, 0x00, 0x9b, 0x02, 0x98, + 0x01, 0x3b, 0x33, 0x61, 0x29, 0x00, 0xff, 0xf7, 0x32, 0xfe, 0x30, 0x00, + 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x31, 0x5b, 0x00, 0xc3, 0xe7, 0x98, 0x00, + 0x11, 0x50, 0x01, 0x33, 0xca, 0xe7, 0x04, 0xcb, 0x04, 0xc4, 0x9c, 0x45, + 0xfb, 0xd8, 0xe9, 0xe7, 0x0a, 0x69, 0x03, 0x69, 0x30, 0xb5, 0x9b, 0x1a, + 0x0d, 0xd1, 0x92, 0x00, 0x14, 0x30, 0x14, 0x31, 0x84, 0x18, 0x89, 0x18, + 0x04, 0x3c, 0x04, 0x39, 0x25, 0x68, 0x0a, 0x68, 0x95, 0x42, 0x04, 0xd0, + 0x01, 0x23, 0x95, 0x42, 0x04, 0xd3, 0x18, 0x00, 0x30, 0xbd, 0xa0, 0x42, + 0xf2, 0xd3, 0xfa, 0xe7, 0x5b, 0x42, 0xf8, 0xe7, 0xf0, 0xb5, 0x0d, 0x00, + 0x85, 0xb0, 0x07, 0x00, 0x11, 0x00, 0x28, 0x00, 0x14, 0x00, 0xff, 0xf7, + 0xdd, 0xff, 0x06, 0x1e, 0x08, 0xd1, 0x01, 0x00, 0x38, 0x00, 0xff, 0xf7, + 0xc2, 0xfd, 0x01, 0x23, 0x46, 0x61, 0x03, 0x61, 0x05, 0xb0, 0xf0, 0xbd, + 0x01, 0x23, 0x01, 0x93, 0x00, 0x28, 0x04, 0xdb, 0x23, 0x00, 0x2c, 0x00, + 0x1d, 0x00, 0x00, 0x23, 0x01, 0x93, 0x61, 0x68, 0x38, 0x00, 0xff, 0xf7, + 0xb0, 0xfd, 0x2f, 0x00, 0x00, 0x22, 0x01, 0x9b, 0x26, 0x69, 0xc3, 0x60, + 0x14, 0x34, 0xb3, 0x00, 0xe3, 0x18, 0x02, 0x93, 0x2b, 0x69, 0x14, 0x37, + 0x9b, 0x00, 0xfb, 0x18, 0x03, 0x93, 0x03, 0x00, 0x94, 0x46, 0x14, 0x33, + 0x20, 0xcc, 0x04, 0xcf, 0x01, 0x92, 0xaa, 0xb2, 0x94, 0x44, 0x6a, 0x46, + 0x61, 0x46, 0x92, 0x88, 0x2d, 0x0c, 0x8a, 0x1a, 0x01, 0x99, 0x09, 0x0c, + 0x69, 0x1a, 0x15, 0x14, 0x49, 0x19, 0x0d, 0x14, 0x92, 0xb2, 0x09, 0x04, + 0x0a, 0x43, 0x1a, 0x60, 0x03, 0x9a, 0xac, 0x46, 0x04, 0x33, 0xba, 0x42, + 0xe6, 0xd8, 0x02, 0x99, 0x1a, 0x00, 0x8c, 0x42, 0x05, 0xd3, 0x04, 0x3a, + 0x13, 0x68, 0x00, 0x2b, 0x0e, 0xd0, 0x06, 0x61, 0xbc, 0xe7, 0x04, 0xcc, + 0x91, 0xb2, 0x61, 0x44, 0x0d, 0x14, 0x12, 0x0c, 0x52, 0x19, 0x15, 0x14, + 0x89, 0xb2, 0x12, 0x04, 0x0a, 0x43, 0xac, 0x46, 0x04, 0xc3, 0xe8, 0xe7, + 0x01, 0x3e, 0xea, 0xe7, 0xf7, 0xb5, 0x1d, 0x00, 0x01, 0x21, 0x14, 0x00, + 0x08, 0x9f, 0xff, 0xf7, 0x66, 0xfd, 0x2b, 0x03, 0x6d, 0x00, 0x06, 0x00, + 0x1b, 0x0b, 0x6d, 0x0d, 0x24, 0xd1, 0x01, 0x93, 0x00, 0x2c, 0x27, 0xd0, + 0x68, 0x46, 0x00, 0x94, 0xff, 0xf7, 0x02, 0xfe, 0x00, 0x9c, 0x00, 0x28, + 0x1e, 0xd0, 0x01, 0x9b, 0x20, 0x21, 0x1a, 0x00, 0x09, 0x1a, 0x8a, 0x40, + 0xc3, 0x40, 0x22, 0x43, 0x72, 0x61, 0x01, 0x93, 0x01, 0x9c, 0xb4, 0x61, + 0x63, 0x1e, 0x9c, 0x41, 0x01, 0x34, 0x34, 0x61, 0x00, 0x2d, 0x18, 0xd0, + 0x12, 0x4b, 0xed, 0x18, 0x35, 0x23, 0x2d, 0x18, 0x3d, 0x60, 0x18, 0x1a, + 0x09, 0x9b, 0x18, 0x60, 0x30, 0x00, 0xfe, 0xbd, 0x80, 0x22, 0x52, 0x03, + 0x13, 0x43, 0xd6, 0xe7, 0x74, 0x61, 0xe7, 0xe7, 0x01, 0xa8, 0xff, 0xf7, + 0xdb, 0xfd, 0x01, 0x24, 0x01, 0x9b, 0x34, 0x61, 0x73, 0x61, 0x20, 0x30, + 0xe4, 0xe7, 0x07, 0x4b, 0xc0, 0x18, 0x07, 0x4b, 0x38, 0x60, 0xe3, 0x18, + 0x9b, 0x00, 0xf3, 0x18, 0x58, 0x69, 0xff, 0xf7, 0xb1, 0xfd, 0x64, 0x01, + 0x20, 0x1a, 0xdf, 0xe7, 0xcd, 0xfb, 0xff, 0xff, 0xce, 0xfb, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x3f, 0x4a, 0x43, 0x70, 0xb5, 0x11, 0x00, 0x14, 0x00, + 0xfe, 0xf7, 0x7c, 0xf8, 0x05, 0x1e, 0x03, 0xd0, 0x22, 0x00, 0x00, 0x21, + 0xfe, 0xf7, 0x24, 0xf8, 0x28, 0x00, 0x70, 0xbd, 0xf8, 0xb5, 0x07, 0x00, + 0x0d, 0x00, 0x16, 0x00, 0x00, 0x29, 0x05, 0xd1, 0x11, 0x00, 0xfe, 0xf7, + 0x6b, 0xf8, 0x04, 0x00, 0x20, 0x00, 0xf8, 0xbd, 0x00, 0x2a, 0x03, 0xd1, + 0xfe, 0xf7, 0x1a, 0xf8, 0x34, 0x00, 0xf7, 0xe7, 0x00, 0xf0, 0x72, 0xf9, + 0x2c, 0x00, 0xb0, 0x42, 0xf2, 0xd2, 0x31, 0x00, 0x38, 0x00, 0xfe, 0xf7, + 0x59, 0xf8, 0x04, 0x1e, 0xec, 0xd0, 0x29, 0x00, 0x32, 0x00, 0xfd, 0xf7, + 0xe5, 0xff, 0x29, 0x00, 0x38, 0x00, 0xfe, 0xf7, 0x05, 0xf8, 0xe3, 0xe7, + 0xf0, 0xb5, 0x8e, 0x68, 0x85, 0xb0, 0x07, 0x00, 0x0c, 0x00, 0x03, 0x92, + 0x01, 0x93, 0x9e, 0x42, 0x3c, 0xd8, 0x90, 0x23, 0x8a, 0x89, 0xdb, 0x00, + 0x1a, 0x42, 0x34, 0xd0, 0x03, 0x25, 0x09, 0x69, 0x23, 0x68, 0x5b, 0x1a, + 0x02, 0x93, 0x63, 0x69, 0x02, 0x98, 0x5d, 0x43, 0xeb, 0x0f, 0x5d, 0x19, + 0x01, 0x9b, 0x6d, 0x10, 0x01, 0x33, 0x1b, 0x18, 0xab, 0x42, 0x00, 0xd9, + 0x1d, 0x00, 0x53, 0x05, 0x32, 0xd5, 0x29, 0x00, 0x38, 0x00, 0xfe, 0xf7, + 0x29, 0xf8, 0x06, 0x1e, 0x09, 0xd1, 0x0c, 0x23, 0x3b, 0x60, 0x40, 0x23, + 0x01, 0x20, 0xa2, 0x89, 0x40, 0x42, 0x13, 0x43, 0xa3, 0x81, 0x05, 0xb0, + 0xf0, 0xbd, 0x02, 0x9a, 0x21, 0x69, 0xfd, 0xf7, 0xab, 0xff, 0xa3, 0x89, + 0x14, 0x4a, 0x1a, 0x40, 0x80, 0x23, 0x13, 0x43, 0xa3, 0x81, 0x02, 0x9b, + 0x26, 0x61, 0xf6, 0x18, 0x26, 0x60, 0x65, 0x61, 0x01, 0x9e, 0xed, 0x1a, + 0xa5, 0x60, 0x01, 0x9b, 0x9e, 0x42, 0x00, 0xd9, 0x01, 0x9e, 0x32, 0x00, + 0x03, 0x99, 0x20, 0x68, 0xfd, 0xf7, 0x9d, 0xff, 0xa3, 0x68, 0x00, 0x20, + 0x9b, 0x1b, 0xa3, 0x60, 0x23, 0x68, 0x9e, 0x19, 0x26, 0x60, 0xda, 0xe7, + 0x2a, 0x00, 0x38, 0x00, 0xff, 0xf7, 0x82, 0xff, 0x06, 0x1e, 0xe0, 0xd1, + 0x21, 0x69, 0x38, 0x00, 0xfd, 0xf7, 0xa6, 0xff, 0xc7, 0xe7, 0xc0, 0x46, + 0x7f, 0xfb, 0xff, 0xff, 0xf0, 0xb5, 0x9f, 0xb0, 0x02, 0x90, 0x05, 0x93, + 0x8b, 0x89, 0x0f, 0x00, 0x16, 0x00, 0x1b, 0x06, 0x11, 0xd5, 0x0b, 0x69, + 0x00, 0x2b, 0x0e, 0xd1, 0x40, 0x21, 0xfd, 0xf7, 0xdd, 0xff, 0x38, 0x60, + 0x38, 0x61, 0x00, 0x28, 0x05, 0xd1, 0x0c, 0x23, 0x02, 0x9a, 0x01, 0x38, + 0x13, 0x60, 0x1f, 0xb0, 0xf0, 0xbd, 0x40, 0x23, 0x7b, 0x61, 0x00, 0x23, + 0x06, 0xac, 0x63, 0x61, 0x20, 0x33, 0x63, 0x76, 0x10, 0x33, 0xa3, 0x76, + 0x35, 0x00, 0x2b, 0x78, 0x00, 0x2b, 0x01, 0xd0, 0x25, 0x2b, 0x46, 0xd1, + 0xab, 0x1b, 0x04, 0x93, 0x0c, 0xd0, 0x32, 0x00, 0x39, 0x00, 0x02, 0x98, + 0xff, 0xf7, 0x6e, 0xff, 0x43, 0x1c, 0x00, 0xd1, 0xae, 0xe0, 0x62, 0x69, + 0x04, 0x9b, 0x94, 0x46, 0x63, 0x44, 0x63, 0x61, 0x2b, 0x78, 0x00, 0x2b, + 0x00, 0xd1, 0xa5, 0xe0, 0x01, 0x22, 0x00, 0x23, 0x52, 0x42, 0x62, 0x60, + 0x02, 0xa9, 0x54, 0x32, 0x52, 0x18, 0x6e, 0x1c, 0x23, 0x60, 0xe3, 0x60, + 0xa3, 0x60, 0x13, 0x70, 0xa3, 0x65, 0x31, 0x78, 0x05, 0x22, 0x54, 0x48, + 0xff, 0xf7, 0x28, 0xfc, 0x75, 0x1c, 0x00, 0x28, 0x1f, 0xd1, 0x22, 0x68, + 0xd3, 0x06, 0x04, 0xd5, 0x53, 0x23, 0x02, 0xa9, 0x5b, 0x18, 0x20, 0x21, + 0x19, 0x70, 0x13, 0x07, 0x04, 0xd5, 0x53, 0x23, 0x02, 0xa9, 0x5b, 0x18, + 0x2b, 0x21, 0x19, 0x70, 0x33, 0x78, 0x2a, 0x2b, 0x16, 0xd0, 0x35, 0x00, + 0x00, 0x21, 0x0a, 0x20, 0xe3, 0x68, 0x2a, 0x78, 0x6e, 0x1c, 0x30, 0x3a, + 0x09, 0x2a, 0x4e, 0xd9, 0x00, 0x29, 0x18, 0xd0, 0x10, 0xe0, 0x01, 0x35, + 0xb1, 0xe7, 0x41, 0x4b, 0x22, 0x68, 0xc0, 0x1a, 0x01, 0x23, 0x83, 0x40, + 0x13, 0x43, 0x23, 0x60, 0x2e, 0x00, 0xce, 0xe7, 0x05, 0x9b, 0x19, 0x1d, + 0x1b, 0x68, 0x05, 0x91, 0x00, 0x2b, 0x01, 0xdb, 0x09, 0x93, 0x04, 0xe0, + 0x5b, 0x42, 0xe3, 0x60, 0x02, 0x23, 0x13, 0x43, 0x23, 0x60, 0x2b, 0x78, + 0x2e, 0x2b, 0x0a, 0xd1, 0x6b, 0x78, 0x2a, 0x2b, 0x35, 0xd1, 0x05, 0x9b, + 0x02, 0x35, 0x1a, 0x1d, 0x1b, 0x68, 0x05, 0x92, 0x00, 0x2b, 0x2b, 0xdb, + 0x07, 0x93, 0x30, 0x4e, 0x29, 0x78, 0x03, 0x22, 0x30, 0x00, 0xff, 0xf7, + 0xdb, 0xfb, 0x00, 0x28, 0x06, 0xd0, 0x40, 0x23, 0x80, 0x1b, 0x83, 0x40, + 0x22, 0x68, 0x01, 0x35, 0x13, 0x43, 0x23, 0x60, 0x29, 0x78, 0x06, 0x22, + 0x28, 0x48, 0x6e, 0x1c, 0x21, 0x76, 0xff, 0xf7, 0xcb, 0xfb, 0x00, 0x28, + 0x3c, 0xd0, 0x26, 0x4b, 0x00, 0x2b, 0x25, 0xd1, 0x07, 0x22, 0x05, 0x9b, + 0x07, 0x33, 0x93, 0x43, 0x08, 0x33, 0x05, 0x93, 0x63, 0x69, 0x03, 0x9a, + 0x9b, 0x18, 0x63, 0x61, 0x66, 0xe7, 0x43, 0x43, 0x01, 0x21, 0x9b, 0x18, + 0x35, 0x00, 0xa6, 0xe7, 0x01, 0x23, 0x5b, 0x42, 0xd0, 0xe7, 0x00, 0x23, + 0x0a, 0x20, 0x1a, 0x00, 0x01, 0x35, 0x63, 0x60, 0x29, 0x78, 0x6e, 0x1c, + 0x30, 0x39, 0x09, 0x29, 0x03, 0xd9, 0x00, 0x2b, 0xc5, 0xd0, 0x07, 0x92, + 0xc3, 0xe7, 0x42, 0x43, 0x01, 0x23, 0x52, 0x18, 0x35, 0x00, 0xf1, 0xe7, + 0x05, 0xab, 0x00, 0x93, 0x3a, 0x00, 0x11, 0x4b, 0x21, 0x00, 0x02, 0x98, + 0xfe, 0xf7, 0x08, 0xf8, 0x03, 0x90, 0x03, 0x9b, 0x01, 0x33, 0xd3, 0xd1, + 0xbb, 0x89, 0x0b, 0x98, 0x5b, 0x06, 0x00, 0xd4, 0x2f, 0xe7, 0x01, 0x20, + 0x40, 0x42, 0x2c, 0xe7, 0x05, 0xab, 0x00, 0x93, 0x3a, 0x00, 0x07, 0x4b, + 0x21, 0x00, 0x02, 0x98, 0xfe, 0xf7, 0xae, 0xfa, 0xea, 0xe7, 0xc0, 0x46, + 0x84, 0x9a, 0x00, 0x00, 0x8a, 0x9a, 0x00, 0x00, 0x8e, 0x9a, 0x00, 0x00, + 0x81, 0x6c, 0x00, 0x00, 0xf1, 0x89, 0x00, 0x00, 0x0b, 0x1f, 0x1b, 0x68, + 0x18, 0x1f, 0x00, 0x2b, 0x01, 0xda, 0x0b, 0x58, 0xc0, 0x18, 0x70, 0x47, + 0x70, 0xb5, 0x00, 0x28, 0x2d, 0xd0, 0xc3, 0x17, 0xc5, 0x18, 0x5d, 0x40, + 0xc4, 0x0f, 0x28, 0x00, 0xfd, 0xf7, 0xd8, 0xfd, 0x15, 0x4b, 0x1b, 0x1a, + 0x5b, 0x05, 0x5b, 0x0d, 0x0a, 0x28, 0x15, 0xdd, 0x0b, 0x38, 0x85, 0x40, + 0x00, 0x22, 0x2d, 0x03, 0x2d, 0x0b, 0x00, 0x21, 0x10, 0x00, 0x2d, 0x03, + 0x0a, 0x0d, 0x2d, 0x0b, 0x12, 0x05, 0x2a, 0x43, 0x0d, 0x4d, 0x1b, 0x05, + 0x2a, 0x40, 0x13, 0x43, 0x5b, 0x00, 0xe4, 0x07, 0x5b, 0x08, 0x23, 0x43, + 0x19, 0x00, 0x70, 0xbd, 0x02, 0x00, 0x29, 0x00, 0x15, 0x32, 0x91, 0x40, + 0x0a, 0x00, 0x0b, 0x21, 0x08, 0x1a, 0xc5, 0x40, 0x2d, 0x03, 0x2d, 0x0b, + 0xe3, 0xe7, 0x00, 0x24, 0x00, 0x23, 0x00, 0x25, 0x00, 0x22, 0xde, 0xe7, + 0x1e, 0x04, 0x00, 0x00, 0xff, 0xff, 0x0f, 0x80, 0x04, 0x4a, 0x13, 0x68, + 0x00, 0x2b, 0x00, 0xd1, 0x03, 0x4b, 0x18, 0x18, 0x10, 0x60, 0x18, 0x00, + 0x70, 0x47, 0xc0, 0x46, 0x54, 0x26, 0x00, 0x20, 0x5c, 0x26, 0x00, 0x20, + 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, + 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, + 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x2e, 0x4f, 0x4b, 0x00, 0x55, 0x50, + 0x44, 0x41, 0x54, 0x45, 0x2e, 0x42, 0x49, 0x4e, 0x2e, 0x4c, 0x5a, 0x53, + 0x53, 0x00, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x2e, 0x42, 0x49, 0x4e, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x20, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, + 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, + 0x41, 0x54, 0x00, 0x4f, 0x4b, 0x0d, 0x0a, 0x00, 0x45, 0x52, 0x52, 0x4f, + 0x52, 0x0d, 0x0a, 0x00, 0x4e, 0x4f, 0x20, 0x43, 0x41, 0x52, 0x52, 0x49, + 0x45, 0x52, 0x0d, 0x0a, 0x00, 0x43, 0x4d, 0x45, 0x20, 0x45, 0x52, 0x52, + 0x4f, 0x52, 0x00, 0x41, 0x54, 0x2b, 0x49, 0x50, 0x52, 0x3d, 0x25, 0x6c, + 0x64, 0x00, 0x41, 0x54, 0x2b, 0x43, 0x50, 0x57, 0x52, 0x4f, 0x46, 0x46, + 0x00, 0x41, 0x54, 0x2b, 0x55, 0x44, 0x45, 0x4c, 0x46, 0x49, 0x4c, 0x45, + 0x3d, 0x22, 0x25, 0x73, 0x22, 0x00, 0x41, 0x54, 0x2b, 0x55, 0x4c, 0x53, + 0x54, 0x46, 0x49, 0x4c, 0x45, 0x3d, 0x30, 0x00, 0x41, 0x54, 0x2b, 0x43, + 0x4d, 0x45, 0x45, 0x3d, 0x32, 0x00, 0x41, 0x54, 0x2b, 0x55, 0x52, 0x44, + 0x42, 0x4c, 0x4f, 0x43, 0x4b, 0x3d, 0x22, 0x25, 0x73, 0x22, 0x2c, 0x25, + 0x64, 0x2c, 0x25, 0x64, 0x00, 0x41, 0x54, 0x2b, 0x55, 0x4c, 0x53, 0x54, + 0x46, 0x49, 0x4c, 0x45, 0x3d, 0x32, 0x2c, 0x22, 0x25, 0x73, 0x22, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x81, 0x2f, 0x00, 0x00, + 0xa5, 0x2f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x04, + 0x00, 0x04, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x01, + 0x00, 0x01, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x13, 0x00, 0x01, 0x01, + 0x01, 0x01, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x05, + 0x00, 0x05, 0x0a, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x05, + 0x01, 0x05, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x02, 0x00, + 0x02, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, + 0x03, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x02, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x03, + 0x01, 0x03, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x10, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x11, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0a, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0b, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x05, 0x00, 0x01, 0x00, + 0x01, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x06, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x07, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x0f, 0x00, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x02, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x03, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x61, 0x36, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xef, 0x3a, 0x00, 0x00, 0x25, 0x3d, 0x00, 0x00, 0xeb, 0x3a, 0x00, 0x00, + 0x09, 0x3d, 0x00, 0x00, 0xe9, 0x3c, 0x00, 0x00, 0x61, 0x3d, 0x00, 0x00, + 0x45, 0x3d, 0x00, 0x00, 0x17, 0x3d, 0x00, 0x00, 0x05, 0x3b, 0x00, 0x00, + 0x6d, 0x3a, 0x00, 0x00, 0x31, 0x3c, 0x00, 0x00, 0x95, 0x3a, 0x00, 0x00, + 0xe9, 0x3a, 0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, + 0xd9, 0x3c, 0x00, 0x00, 0x21, 0x3c, 0x00, 0x00, 0x87, 0x3d, 0x00, 0x00, + 0x85, 0x3d, 0x00, 0x00, 0xd9, 0x3a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x7d, 0x45, 0x00, 0x00, 0xc1, 0x36, 0x00, 0x00, + 0xa3, 0x44, 0x00, 0x00, 0x5f, 0x44, 0x00, 0x00, 0x79, 0x44, 0x00, 0x00, + 0x31, 0x46, 0x00, 0x00, 0x41, 0x42, 0x00, 0x00, 0x31, 0x42, 0x00, 0x00, + 0xc5, 0x42, 0x00, 0x00, 0x5b, 0x42, 0x00, 0x00, 0x2d, 0x42, 0x00, 0x00, + 0x98, 0x56, 0x00, 0x00, 0x0a, 0x55, 0x00, 0x00, 0x4e, 0x55, 0x00, 0x00, + 0xb2, 0x54, 0x00, 0x00, 0x4e, 0x55, 0x00, 0x00, 0x3e, 0x56, 0x00, 0x00, + 0x4e, 0x55, 0x00, 0x00, 0xb2, 0x54, 0x00, 0x00, 0x0a, 0x55, 0x00, 0x00, + 0x0a, 0x55, 0x00, 0x00, 0x3e, 0x56, 0x00, 0x00, 0xb2, 0x54, 0x00, 0x00, + 0xaa, 0x54, 0x00, 0x00, 0xaa, 0x54, 0x00, 0x00, 0xaa, 0x54, 0x00, 0x00, + 0x4c, 0x56, 0x00, 0x00, 0xc0, 0x5d, 0x00, 0x00, 0xc2, 0x5c, 0x00, 0x00, + 0xc2, 0x5c, 0x00, 0x00, 0xe0, 0x5f, 0x00, 0x00, 0xbc, 0x5c, 0x00, 0x00, + 0xbc, 0x5c, 0x00, 0x00, 0xc8, 0x5f, 0x00, 0x00, 0xe0, 0x5f, 0x00, 0x00, + 0xbc, 0x5c, 0x00, 0x00, 0xc8, 0x5f, 0x00, 0x00, 0xbc, 0x5c, 0x00, 0x00, + 0xe0, 0x5f, 0x00, 0x00, 0xd6, 0x5f, 0x00, 0x00, 0xd6, 0x5f, 0x00, 0x00, + 0xd6, 0x5f, 0x00, 0x00, 0xe4, 0x5f, 0x00, 0x00, 0x43, 0x00, 0x50, 0x4f, + 0x53, 0x49, 0x58, 0x00, 0x2e, 0x00, 0x49, 0x4e, 0x46, 0x00, 0x69, 0x6e, + 0x66, 0x00, 0x4e, 0x41, 0x4e, 0x00, 0x6e, 0x61, 0x6e, 0x00, 0x30, 0x31, + 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x41, 0x42, 0x43, 0x44, + 0x45, 0x46, 0x00, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, + 0x39, 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, 0x00, 0x00, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x28, 0x28, 0x28, 0x28, 0x28, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x88, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, + 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x04, 0x04, 0x04, + 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x10, 0x10, 0x10, 0x10, 0x10, + 0x10, 0x10, 0x41, 0x41, 0x41, 0x41, 0x41, 0x41, 0x01, 0x01, 0x01, 0x01, + 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, + 0x01, 0x01, 0x01, 0x01, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x42, 0x42, + 0x42, 0x42, 0x42, 0x42, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, + 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, + 0x10, 0x10, 0x10, 0x10, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x49, 0x6e, 0x66, 0x69, 0x6e, 0x69, 0x74, 0x79, 0x00, 0x4e, 0x61, + 0x4e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xe0, 0x37, + 0x79, 0xc3, 0x41, 0x43, 0x17, 0x6e, 0x05, 0xb5, 0xb5, 0xb8, 0x93, 0x46, + 0xf5, 0xf9, 0x3f, 0xe9, 0x03, 0x4f, 0x38, 0x4d, 0x32, 0x1d, 0x30, 0xf9, + 0x48, 0x77, 0x82, 0x5a, 0x3c, 0xbf, 0x73, 0x7f, 0xdd, 0x4f, 0x15, 0x75, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x3f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x24, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x59, 0x40, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x8f, 0x40, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x88, 0xc3, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x6a, 0xf8, 0x40, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x84, 0x2e, 0x41, 0x00, 0x00, 0x00, 0x00, + 0xd0, 0x12, 0x63, 0x41, 0x00, 0x00, 0x00, 0x00, 0x84, 0xd7, 0x97, 0x41, + 0x00, 0x00, 0x00, 0x00, 0x65, 0xcd, 0xcd, 0x41, 0x00, 0x00, 0x00, 0x20, + 0x5f, 0xa0, 0x02, 0x42, 0x00, 0x00, 0x00, 0xe8, 0x76, 0x48, 0x37, 0x42, + 0x00, 0x00, 0x00, 0xa2, 0x94, 0x1a, 0x6d, 0x42, 0x00, 0x00, 0x40, 0xe5, + 0x9c, 0x30, 0xa2, 0x42, 0x00, 0x00, 0x90, 0x1e, 0xc4, 0xbc, 0xd6, 0x42, + 0x00, 0x00, 0x34, 0x26, 0xf5, 0x6b, 0x0c, 0x43, 0x00, 0x80, 0xe0, 0x37, + 0x79, 0xc3, 0x41, 0x43, 0x00, 0xa0, 0xd8, 0x85, 0x57, 0x34, 0x76, 0x43, + 0x00, 0xc8, 0x4e, 0x67, 0x6d, 0xc1, 0xab, 0x43, 0x00, 0x3d, 0x91, 0x60, + 0xe4, 0x58, 0xe1, 0x43, 0x40, 0x8c, 0xb5, 0x78, 0x1d, 0xaf, 0x15, 0x44, + 0x50, 0xef, 0xe2, 0xd6, 0xe4, 0x1a, 0x4b, 0x44, 0x92, 0xd5, 0x4d, 0x06, + 0xcf, 0xf0, 0x80, 0x44, 0xf6, 0x4a, 0xe1, 0xc7, 0x02, 0x2d, 0xb5, 0x44, + 0xb4, 0x9d, 0xd9, 0x79, 0x43, 0x78, 0xea, 0x44, 0x05, 0x00, 0x00, 0x00, + 0x19, 0x00, 0x00, 0x00, 0x7d, 0x00, 0x00, 0x00, 0x23, 0x2d, 0x30, 0x2b, + 0x20, 0x00, 0x68, 0x6c, 0x4c, 0x00, 0x65, 0x66, 0x67, 0x45, 0x46, 0x47, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x82, 0x8d, 0x00, 0x00, 0x72, 0x8d, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, + 0x40, 0x42, 0x0f, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x00, 0xc2, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0xff, 0xff, 0xff, 0xff, + 0x2c, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0xb8, 0x9a, 0x00, 0x00, + 0xd8, 0x9a, 0x00, 0x00, 0x98, 0x9a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xa5, 0x76, 0x00, 0x00, 0x8d, 0x69, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x74, 0x98, 0x00, 0x00, 0x40, 0x98, 0x00, 0x00, 0x27, 0x93, 0x00, 0x00, + 0x27, 0x93, 0x00, 0x00, 0x27, 0x93, 0x00, 0x00, 0x27, 0x93, 0x00, 0x00, + 0x27, 0x93, 0x00, 0x00, 0x27, 0x93, 0x00, 0x00, 0x27, 0x93, 0x00, 0x00, + 0x27, 0x93, 0x00, 0x00, 0x27, 0x93, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, + 0x01, 0x00, 0x41, 0x53, 0x43, 0x49, 0x49, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x41, 0x53, + 0x43, 0x49, 0x49, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xdd, 0x20, 0x00, 0x00, + 0xa5, 0x23, 0x00, 0x00, 0xf1, 0x25, 0x00, 0x00, 0x09, 0x26, 0x00, 0x00, + 0x29, 0x27, 0x00, 0x00, 0xd5, 0x2b, 0x00, 0x00, 0x0d, 0x2c, 0x00, 0x00, + 0x19, 0x2f, 0x00, 0x00, 0x31, 0x2f, 0x00, 0x00, 0xb9, 0x2f, 0x00, 0x00, + 0xfd, 0x2f, 0x00, 0x00, 0xdd, 0x3d, 0x00, 0x00, 0x1d, 0x42, 0x00, 0x00, + 0xb5, 0x20, 0x00, 0x00 diff --git a/libraries/SDU/examples/Usage/Usage.ino b/libraries/SDU/examples/Usage/Usage.ino new file mode 100644 index 0000000..443a754 --- /dev/null +++ b/libraries/SDU/examples/Usage/Usage.ino @@ -0,0 +1,73 @@ +/* + Usage + This example demonstrates how to use the SAMD SDU library to update a + sketch on an Arduino/Genuino Zero, MKRZero or MKR1000 board using an + SD card. It prints out the date and time the sketch was compiled at + to both Serial and Serial1. + + Circuit: + * Arduino MKRZero board with SD card + OR + * Arduino/Genuino Zero or MKR1000 board + * SD shield or breakout connected with CS pin of 4 + * SD card + + Non-Arduino/Genuino Zero, MKRZero or MKR1000 board are NOT supported. + + Steps to update sketch via SD card: + + 1) Upload this sketch or another sketch that includes the SDU library + via #include + + 2) Update the sketch as desired. For this example the sketch prints out + the compiled date and time so no updates are needed. + + 3) In the IDE select: Sketch -> Export compiled Binary + + 4) Copy the .bin file from the sketch's folder to the SD card and rename + the file to UPDATE.bin. Eject the SD card from your PC. + + 5) Insert the SD card into the board, shield or breakout and press the + reset button or power cycle the board. The SDU library will then update + the sketch on the board with the contents of UPDATE.bin + + created 23 March 2017 + by Sandeep Mistry +*/ + +/* + Include the SDU library + + This will add some code to the sketch before setup() is called + to check if an SD card is present and UPDATE.bin exists on the + SD card. + + If UPDATE.bin is present, the file is used to update the sketch + running on the board. After this UPDATE.bin is deleted from the + SD card. +*/ +#include + +String message; + +void setup() { + Serial.begin(9600); + Serial1.begin(9600); + + // wait a bit + delay(1000); + + message += "Sketch compile date and time: "; + message += __DATE__; + message += " "; + message += __TIME__; + + // print out the sketch compile date and time on the serial port + Serial.println(message); + Serial1.println(message); +} + +void loop() { + // add you own code here +} + diff --git a/libraries/SDU/extras/SDUBoot/SDUBoot.ino b/libraries/SDU/extras/SDUBoot/SDUBoot.ino new file mode 100644 index 0000000..6a3d875 --- /dev/null +++ b/libraries/SDU/extras/SDUBoot/SDUBoot.ino @@ -0,0 +1,97 @@ +/* + Copyright (c) 2017 Arduino LLC. 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 +*/ + +#include +#include + +#ifdef ARDUINO_SAM_ZERO +#define SDU_START 0x4000 +#else +#define SDU_START 0x2000 +#endif +#define SDU_SIZE 0x4000 + +#define SKETCH_START (uint32_t*)(SDU_START + SDU_SIZE) + +#ifndef SDCARD_SS_PIN +#define SDCARD_SS_PIN 4 +#endif + +#define UPDATE_FILE "UPDATE.BIN" + +FlashClass flash; + +// Initialize C library +extern "C" void __libc_init_array(void); + +int main() { + init(); + + __libc_init_array(); + + delay(1); + + if (SD.begin(SDCARD_SS_PIN) && SD.exists(UPDATE_FILE)) { + File updateFile = SD.open(UPDATE_FILE); + uint32_t updateSize = updateFile.size(); + bool updateFlashed = false; + + if (updateSize > SDU_SIZE) { + // skip the SDU section + updateFile.seek(SDU_SIZE); + updateSize -= SDU_SIZE; + + uint32_t flashAddress = (uint32_t)SKETCH_START; + + // erase the pages + flash.erase((void*)flashAddress, updateSize); + + uint8_t buffer[512]; + + // write the pages + for (uint32_t i = 0; i < updateSize; i += sizeof(buffer)) { + updateFile.read(buffer, sizeof(buffer)); + + flash.write((void*)flashAddress, buffer, sizeof(buffer)); + + flashAddress += sizeof(buffer); + } + + updateFlashed = true; + } + + updateFile.close(); + + if (updateFlashed) { + SD.remove(UPDATE_FILE); + } + } + + // jump to the sketch + __set_MSP(*SKETCH_START); + + //Reset vector table address + SCB->VTOR = ((uint32_t)(SKETCH_START) & SCB_VTOR_TBLOFF_Msk); + + // address of Reset_Handler is written by the linker at the beginning of the .text section (see linker script) + uint32_t resetHandlerAddress = (uint32_t) * (SKETCH_START + 1); + // jump to reset handler + asm("bx %0"::"r"(resetHandlerAddress)); +} + + diff --git a/libraries/SDU/extras/SDUBoot/build.sh b/libraries/SDU/extras/SDUBoot/build.sh new file mode 100755 index 0000000..2f52b3b --- /dev/null +++ b/libraries/SDU/extras/SDUBoot/build.sh @@ -0,0 +1,32 @@ +#!/bin/sh -x + +ARDUINO=arduino +SKETCH_NAME="SDUBoot.ino" +SKETCH="$PWD/$SKETCH_NAME" +BUILD_PATH="$PWD/build" +OUTPUT_PATH="../../src/boot" + +if [[ "$OSTYPE" == "darwin"* ]]; then + ARDUINO="/Applications/Arduino.app/Contents/MacOS/Arduino" +fi + +buildSDUBootSketch() { + BOARD=$1 + DESTINATION=$2 + + $ARDUINO --verify --board $BOARD --preserve-temp-files --pref build.path="$BUILD_PATH" $SKETCH + cat "$BUILD_PATH/$SKETCH_NAME.bin" | xxd -i > $DESTINATION + rm -rf "$BUILD_PATH" +} + +mkdir -p "$OUTPUT_PATH" + +buildSDUBootSketch "arduino:samd:arduino_zero_edbg" "$OUTPUT_PATH/zero.h" +buildSDUBootSketch "arduino:samd:mkr1000" "$OUTPUT_PATH/mkr1000.h" +buildSDUBootSketch "arduino:samd:mkrzero" "$OUTPUT_PATH/mkrzero.h" +buildSDUBootSketch "arduino:samd:mkrfox1200" "$OUTPUT_PATH/mkrfox1200.h" +buildSDUBootSketch "arduino:samd:mkrgsm1400" "$OUTPUT_PATH/mkrgsm1400.h" +buildSDUBootSketch "arduino:samd:mkrwan1300" "$OUTPUT_PATH/mkrwan1300.h" +buildSDUBootSketch "arduino:samd:mkrwifi1010" "$OUTPUT_PATH/mkrwifi1010.h" +buildSDUBootSketch "arduino:samd:mkrnb1500" "$OUTPUT_PATH/mkrnb1500.h" +buildSDUBootSketch "arduino:samd:mzero_bl" "$OUTPUT_PATH/mzero.h" diff --git a/libraries/SDU/keywords.txt b/libraries/SDU/keywords.txt new file mode 100644 index 0000000..a9db990 --- /dev/null +++ b/libraries/SDU/keywords.txt @@ -0,0 +1,17 @@ +####################################### +# Syntax Coloring Map For SDU +####################################### + +####################################### +# Datatypes (KEYWORD1) +####################################### + +SDU KEYWORD1 + +####################################### +# Methods and Functions (KEYWORD2) +####################################### + +####################################### +# Constants (LITERAL1) +####################################### diff --git a/libraries/SDU/library.properties b/libraries/SDU/library.properties new file mode 100644 index 0000000..68113ae --- /dev/null +++ b/libraries/SDU/library.properties @@ -0,0 +1,9 @@ +name=SDU +version=1.0.0 +author=Arduino +maintainer=Arduino +sentence=Update the sketch on your board from an SD card +paragraph=Requires an SD card +category=Other +url=http://www.arduino.cc/en/Reference/SDU +architectures=samd diff --git a/libraries/SDU/src/SDU.cpp b/libraries/SDU/src/SDU.cpp new file mode 100644 index 0000000..1fccee6 --- /dev/null +++ b/libraries/SDU/src/SDU.cpp @@ -0,0 +1,46 @@ +/* + Copyright (c) 2017 Arduino LLC. 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 +*/ + +#include + +#include "SDU.h" + +__attribute__ ((section(".sketch_boot"))) +unsigned char sduBoot[0x4000] = { +#if defined(ARDUINO_SAMD_ZERO) + #include "boot/zero.h" +#elif defined(ARDUINO_SAMD_MKR1000) + #include "boot/mkr1000.h" +#elif defined(ARDUINO_SAMD_MKRZERO) + #include "boot/mkrzero.h" +#elif defined(ARDUINO_SAMD_MKRFox1200) + #include "boot/mkrfox1200.h" +#elif defined(ARDUINO_SAMD_MKRGSM1400) + #include "boot/mkrgsm1400.h" +#elif defined(ARDUINO_SAMD_MKRWAN1300) + #include "boot/mkrwan1300.h" +#elif defined(ARDUINO_SAMD_MKRWIFI1010) + #include "boot/mkrwifi1010.h" +#elif defined(ARDUINO_SAMD_MKRNB1500) + #include "boot/mkrnb1500.h" +#elif defined(ARDUINO_SAM_ZERO) + #include "boot/mzero.h" +#else + #error "Unsupported board!" +#endif +}; diff --git a/libraries/SDU/src/SDU.h b/libraries/SDU/src/SDU.h new file mode 100644 index 0000000..59fcc16 --- /dev/null +++ b/libraries/SDU/src/SDU.h @@ -0,0 +1,24 @@ +/* + Copyright (c) 2017 Arduino LLC. 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 _SDU_H_INCLUDED +#define _SDU_H_INCLUDED + +// nothing for now + +#endif diff --git a/libraries/SDU/src/boot/mkr1000.h b/libraries/SDU/src/boot/mkr1000.h new file mode 100644 index 0000000..b10087d --- /dev/null +++ b/libraries/SDU/src/boot/mkr1000.h @@ -0,0 +1,1236 @@ + 0x00, 0x80, 0x00, 0x20, 0x85, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0xd9, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0xdd, 0x3a, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0xa0, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0x44, 0x59, 0x00, 0x00, 0x08, 0xb5, 0x08, 0x4b, 0x00, 0x2b, 0x03, 0xd0, + 0x07, 0x48, 0x08, 0x49, 0x00, 0xe0, 0x00, 0xbf, 0x07, 0x48, 0x03, 0x68, + 0x00, 0x2b, 0x03, 0xd0, 0x06, 0x4b, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, + 0x08, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x00, 0x44, 0x59, 0x00, 0x00, + 0xa4, 0x00, 0x00, 0x20, 0x9c, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xf0, 0xb5, 0x33, 0x4c, 0xa5, 0x44, 0x01, 0xf0, 0x3d, 0xfe, 0x02, 0xf0, + 0x75, 0xfd, 0x01, 0x20, 0x01, 0xf0, 0x66, 0xfd, 0x2f, 0x4d, 0x04, 0x21, + 0x28, 0x1c, 0x00, 0xf0, 0xe7, 0xf9, 0x00, 0x28, 0x44, 0xd0, 0x2d, 0x4e, + 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0xbe, 0xfa, 0x00, 0x28, 0x3d, 0xd0, + 0x29, 0x1c, 0x01, 0xa8, 0x32, 0x1c, 0x01, 0x23, 0x00, 0xf0, 0x6e, 0xfa, + 0x01, 0xa8, 0x00, 0xf0, 0x00, 0xf9, 0x80, 0x21, 0x04, 0x1c, 0xc9, 0x01, + 0x88, 0x42, 0x2d, 0xd9, 0x01, 0xa8, 0x00, 0xf0, 0xe6, 0xf8, 0x22, 0x4a, + 0xc0, 0x21, 0xa7, 0x18, 0x21, 0x48, 0xc9, 0x01, 0x3a, 0x1c, 0x01, 0xf0, + 0xf5, 0xfb, 0xc0, 0x24, 0xe4, 0x01, 0x80, 0x22, 0x0a, 0xa9, 0x92, 0x00, + 0x01, 0xa8, 0x00, 0xf0, 0xcf, 0xf8, 0x80, 0x23, 0x21, 0x1c, 0x0a, 0xaa, + 0x9b, 0x00, 0x19, 0x48, 0x01, 0xf0, 0x8e, 0xfb, 0x80, 0x22, 0x92, 0x00, + 0xa3, 0x18, 0x17, 0x4a, 0xa4, 0x18, 0xbc, 0x42, 0x01, 0xd2, 0x1c, 0x1c, + 0xe9, 0xe7, 0x01, 0x24, 0x01, 0xa8, 0x00, 0xf0, 0xed, 0xf8, 0x00, 0x2c, + 0x06, 0xd0, 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0x8d, 0xfa, 0x01, 0xe0, + 0x00, 0x24, 0xf3, 0xe7, 0xc0, 0x23, 0xdb, 0x01, 0x1b, 0x68, 0x83, 0xf3, + 0x08, 0x88, 0x0c, 0x4b, 0xc0, 0x22, 0xd2, 0x01, 0x9a, 0x60, 0x0b, 0x4b, + 0x1b, 0x68, 0x18, 0x47, 0x00, 0x20, 0x8b, 0x23, 0x9b, 0x00, 0x9d, 0x44, + 0xf0, 0xbd, 0xc0, 0x46, 0xd4, 0xfd, 0xff, 0xff, 0xd4, 0x00, 0x00, 0x20, + 0xa8, 0x4e, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xbc, 0x00, 0x00, 0x20, + 0x00, 0xa2, 0xff, 0xff, 0x00, 0xed, 0x00, 0xe0, 0x04, 0x60, 0x00, 0x00, + 0x08, 0xb5, 0x00, 0x21, 0x02, 0x48, 0x0a, 0x1c, 0x01, 0xf0, 0x38, 0xfb, + 0x08, 0xbd, 0xc0, 0x46, 0xbc, 0x00, 0x00, 0x20, 0x00, 0x20, 0x70, 0x47, + 0x70, 0x47, 0x13, 0xb5, 0x02, 0x68, 0x6b, 0x46, 0xd9, 0x71, 0x07, 0x33, + 0x54, 0x68, 0x19, 0x1c, 0x01, 0x22, 0xa0, 0x47, 0x16, 0xbd, 0x38, 0xb5, + 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x25, 0xa8, 0x42, 0x02, 0xd1, 0x01, 0x23, + 0x63, 0x60, 0x0a, 0xe0, 0x45, 0x60, 0x92, 0xb2, 0x01, 0xf0, 0x04, 0xf8, + 0x23, 0x6a, 0x5b, 0x68, 0x00, 0x2b, 0x02, 0xd0, 0x01, 0x23, 0x63, 0x60, + 0x28, 0x1c, 0x38, 0xbd, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x01, 0xd0, + 0x00, 0xf0, 0x42, 0xfe, 0x08, 0xbd, 0x00, 0x00, 0x13, 0xb5, 0x6c, 0x46, + 0x07, 0x34, 0x21, 0x1c, 0x01, 0x22, 0x00, 0xf0, 0x5d, 0xfd, 0x01, 0x28, + 0x01, 0xd1, 0x20, 0x78, 0x00, 0xe0, 0x01, 0x48, 0x00, 0xb2, 0x16, 0xbd, + 0xff, 0xff, 0x00, 0x00, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x02, 0xd0, + 0xff, 0xf7, 0xea, 0xff, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x08, 0xbd, + 0x38, 0xb5, 0x05, 0x1c, 0x00, 0x6a, 0x00, 0x28, 0x0a, 0xd0, 0xff, 0xf7, + 0xdf, 0xff, 0x04, 0x1c, 0x63, 0x1c, 0x05, 0xd0, 0x28, 0x6a, 0x01, 0x69, + 0x01, 0x39, 0x00, 0xf0, 0xe5, 0xfd, 0x20, 0x1c, 0x38, 0xbd, 0x00, 0x00, + 0xf8, 0xb5, 0xfa, 0x23, 0x9b, 0x00, 0x83, 0x60, 0x0d, 0x4b, 0x00, 0x25, + 0x08, 0x33, 0x04, 0x1c, 0x45, 0x60, 0x03, 0x60, 0x28, 0x20, 0x0f, 0x1c, + 0x16, 0x1c, 0x02, 0xf0, 0xbb, 0xfc, 0x20, 0x62, 0xa8, 0x42, 0x0a, 0xd0, + 0x39, 0x1c, 0x28, 0x22, 0x02, 0xf0, 0xd7, 0xfc, 0x20, 0x1c, 0x10, 0x30, + 0x31, 0x1c, 0x0c, 0x22, 0x02, 0xf0, 0x9c, 0xfd, 0x25, 0x77, 0x20, 0x1c, + 0xf8, 0xbd, 0xc0, 0x46, 0xb8, 0x4e, 0x00, 0x00, 0xfa, 0x22, 0x92, 0x00, + 0x82, 0x60, 0x04, 0x4a, 0x00, 0x23, 0x08, 0x32, 0x43, 0x60, 0x02, 0x60, + 0x03, 0x62, 0x03, 0x74, 0x70, 0x47, 0xc0, 0x46, 0xb8, 0x4e, 0x00, 0x00, + 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x01, 0xd0, 0x00, 0xf0, 0x02, 0xfd, + 0x08, 0xbd, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x04, 0xd0, 0x00, 0xf0, + 0xa5, 0xfd, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x08, 0xbd, 0x03, 0x6a, + 0x00, 0x2b, 0x01, 0xd0, 0x18, 0x69, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, + 0x70, 0x47, 0x00, 0x6a, 0x00, 0x28, 0x00, 0xd0, 0xc0, 0x69, 0x70, 0x47, + 0x38, 0xb5, 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x28, 0x0b, 0xd0, 0x20, 0x1c, + 0xff, 0xf7, 0xf3, 0xff, 0x05, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0xe7, 0xff, + 0x02, 0x4b, 0x28, 0x1a, 0x98, 0x42, 0x00, 0xd9, 0x18, 0x1c, 0x38, 0xbd, + 0xff, 0x7f, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x28, + 0x06, 0xd0, 0x00, 0xf0, 0xe7, 0xfd, 0x20, 0x6a, 0x02, 0xf0, 0x68, 0xfc, + 0x00, 0x23, 0x23, 0x62, 0x10, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x0a, 0x1c, + 0x0c, 0x49, 0x8a, 0xb0, 0x04, 0x1c, 0x00, 0x23, 0x00, 0x91, 0x69, 0x46, + 0x4b, 0x72, 0x01, 0x93, 0x21, 0x1c, 0x68, 0x46, 0x01, 0x23, 0x00, 0xf0, + 0x81, 0xfe, 0x04, 0x1c, 0x60, 0x1e, 0x84, 0x41, 0xe4, 0xb2, 0x00, 0x2c, + 0x02, 0xd0, 0x68, 0x46, 0x00, 0xf0, 0xc8, 0xfd, 0x20, 0x1c, 0x0a, 0xb0, + 0x10, 0xbd, 0xc0, 0x46, 0x00, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x01, 0x23, + 0x00, 0x2a, 0x05, 0xd0, 0x00, 0xf0, 0x1a, 0xff, 0x03, 0x1c, 0x58, 0x1e, + 0x83, 0x41, 0xdb, 0xb2, 0x18, 0x1c, 0x08, 0xbd, 0x38, 0xb5, 0x01, 0x22, + 0x05, 0x1c, 0x0c, 0x1c, 0x01, 0xf0, 0x94, 0xf9, 0x02, 0x1c, 0x01, 0x20, + 0x00, 0x2a, 0x03, 0xd1, 0x28, 0x1c, 0x21, 0x1c, 0x01, 0xf0, 0x8c, 0xf9, + 0x38, 0xbd, 0xf0, 0xb5, 0x0c, 0x68, 0x03, 0x5d, 0x2f, 0x3b, 0x5d, 0x42, + 0x6b, 0x41, 0xe4, 0x18, 0x27, 0x1c, 0x0c, 0x37, 0x23, 0x1c, 0xc5, 0x5c, + 0x1e, 0x1b, 0x2f, 0x2d, 0x09, 0xd0, 0x00, 0x2d, 0x07, 0xd0, 0x01, 0x33, + 0x16, 0x1b, 0xf6, 0x18, 0x01, 0x3e, 0x35, 0x70, 0xbb, 0x42, 0xf2, 0xd1, + 0x0c, 0x26, 0x00, 0x24, 0x94, 0x55, 0xc2, 0x5c, 0x2f, 0x3a, 0x54, 0x42, + 0x62, 0x41, 0x9b, 0x18, 0x0b, 0x60, 0xc0, 0x5c, 0x43, 0x1e, 0x98, 0x41, + 0xc0, 0xb2, 0xf0, 0xbd, 0xf0, 0xb5, 0xa1, 0xb0, 0x03, 0x90, 0x25, 0x48, + 0x0d, 0x1c, 0x04, 0x92, 0x05, 0x93, 0x0c, 0xaa, 0x00, 0x23, 0x16, 0xa9, + 0x0d, 0x93, 0x0c, 0x90, 0x53, 0x72, 0x17, 0x93, 0x16, 0x90, 0x4b, 0x72, + 0x07, 0x93, 0x2c, 0x1c, 0x00, 0x92, 0x07, 0xa9, 0x08, 0xaa, 0x03, 0x98, + 0xff, 0xf7, 0xc3, 0xff, 0x01, 0x26, 0x02, 0x1c, 0x72, 0x40, 0x01, 0x90, + 0xd2, 0xb2, 0x20, 0x1c, 0x08, 0xa9, 0x05, 0x9b, 0x04, 0x9f, 0xb8, 0x47, + 0x00, 0x28, 0x07, 0xd1, 0xac, 0x42, 0x01, 0xd1, 0x00, 0x20, 0x23, 0xe0, + 0x20, 0x1c, 0x00, 0xf0, 0x57, 0xfd, 0xf9, 0xe7, 0x01, 0x9f, 0x00, 0x2f, + 0x11, 0xd0, 0x33, 0x1c, 0x00, 0x98, 0x21, 0x1c, 0x08, 0xaa, 0x00, 0xf0, + 0xfd, 0xfd, 0x06, 0x1c, 0xac, 0x42, 0x0f, 0xd0, 0x20, 0x1c, 0x00, 0xf0, + 0x47, 0xfd, 0x00, 0x2e, 0xe8, 0xd0, 0x23, 0x1c, 0x00, 0x9c, 0x00, 0x93, + 0xd1, 0xe7, 0xac, 0x42, 0x02, 0xd0, 0x20, 0x1c, 0x00, 0xf0, 0x3c, 0xfd, + 0x30, 0x1c, 0x03, 0xe0, 0x00, 0x28, 0xdb, 0xd0, 0x16, 0xac, 0xf0, 0xe7, + 0x21, 0xb0, 0xf0, 0xbd, 0x00, 0x4f, 0x00, 0x00, 0x38, 0xb5, 0x03, 0x1c, + 0x41, 0x33, 0x1b, 0x78, 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x2b, 0x02, 0xd0, + 0x38, 0x30, 0x00, 0xf0, 0x27, 0xfd, 0x20, 0x1c, 0x01, 0x21, 0x2a, 0x1c, + 0x00, 0xf0, 0xc8, 0xf9, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x0f, 0xe0, + 0x25, 0x1c, 0x10, 0x35, 0x28, 0x1c, 0x21, 0x1c, 0xff, 0xf7, 0x62, 0xff, + 0x00, 0x28, 0xf5, 0xd0, 0x20, 0x1c, 0x38, 0x30, 0x29, 0x1c, 0x00, 0xf0, + 0xcf, 0xfb, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x38, 0xbd, 0x00, 0x00, + 0x4b, 0x68, 0x43, 0x60, 0x0a, 0x4b, 0x03, 0x60, 0x0b, 0x7a, 0x03, 0x72, + 0x4b, 0x7a, 0x43, 0x72, 0xcb, 0x68, 0xc3, 0x60, 0x0b, 0x69, 0x03, 0x61, + 0x4b, 0x69, 0x43, 0x61, 0x0b, 0x7e, 0x03, 0x76, 0xcb, 0x69, 0xc3, 0x61, + 0x0b, 0x6a, 0x49, 0x6a, 0x03, 0x62, 0x41, 0x62, 0x70, 0x47, 0xc0, 0x46, + 0x00, 0x4f, 0x00, 0x00, 0xf0, 0xb5, 0x9d, 0xb0, 0x08, 0xae, 0x02, 0x92, + 0x03, 0x93, 0x27, 0x4a, 0x00, 0x23, 0x12, 0xaf, 0x05, 0x1c, 0x73, 0x60, + 0x7b, 0x60, 0x10, 0x31, 0x30, 0x1c, 0x08, 0x92, 0x73, 0x72, 0x12, 0x92, + 0x7b, 0x72, 0x00, 0xf0, 0x9d, 0xfb, 0x02, 0x9c, 0x20, 0x1c, 0x2f, 0x21, + 0x02, 0xf0, 0x36, 0xfc, 0x00, 0x28, 0x2e, 0xd0, 0x23, 0x78, 0x2f, 0x2b, + 0x01, 0xd1, 0x01, 0x34, 0xf4, 0xe7, 0x00, 0x1b, 0xc0, 0xb2, 0x03, 0x1c, + 0x0c, 0x28, 0x00, 0xd9, 0x0c, 0x23, 0xdb, 0xb2, 0x1a, 0x1c, 0x21, 0x1c, + 0x04, 0xa8, 0x01, 0x93, 0x02, 0xf0, 0x2e, 0xfc, 0x01, 0x9a, 0x00, 0x23, + 0x04, 0xa9, 0x38, 0x1c, 0x8b, 0x54, 0x00, 0xf0, 0xbf, 0xfc, 0x38, 0x1c, + 0x31, 0x1c, 0x04, 0xaa, 0x01, 0x23, 0x00, 0xf0, 0x69, 0xfd, 0x00, 0x28, + 0x04, 0xd1, 0x0c, 0x4b, 0x68, 0x60, 0x2b, 0x60, 0x68, 0x72, 0x10, 0xe0, + 0x01, 0x9b, 0x30, 0x1c, 0xe4, 0x18, 0x00, 0xf0, 0xad, 0xfc, 0x33, 0x1c, + 0x3e, 0x1c, 0x1f, 0x1c, 0xca, 0xe7, 0x02, 0x99, 0x03, 0x9a, 0x64, 0x1a, + 0x14, 0x60, 0x28, 0x1c, 0x31, 0x1c, 0xff, 0xf7, 0x95, 0xff, 0x28, 0x1c, + 0x1d, 0xb0, 0xf0, 0xbd, 0x00, 0x4f, 0x00, 0x00, 0xf0, 0xb5, 0xa1, 0xb0, + 0x05, 0x1c, 0x1f, 0x1c, 0x02, 0xa8, 0x01, 0xab, 0x16, 0x1c, 0xff, 0xf7, + 0xa1, 0xff, 0x01, 0x9b, 0xf6, 0x18, 0x33, 0x78, 0x00, 0x2b, 0x07, 0xd1, + 0x02, 0xa9, 0x16, 0xa8, 0xff, 0xf7, 0x7e, 0xff, 0x28, 0x1c, 0x16, 0xa9, + 0x17, 0x4a, 0x28, 0xe0, 0x00, 0x23, 0x0c, 0xac, 0x63, 0x60, 0x63, 0x72, + 0x6b, 0x46, 0x11, 0x33, 0x14, 0x4a, 0x1b, 0x78, 0x0c, 0x92, 0x00, 0x2b, + 0x03, 0xd1, 0x28, 0x1c, 0xff, 0xf7, 0x4a, 0xfe, 0x1b, 0xe0, 0x20, 0x1c, + 0x02, 0xa9, 0x32, 0x1c, 0x3b, 0x1c, 0x00, 0xf0, 0x21, 0xfd, 0x00, 0x28, + 0xf3, 0xd0, 0x02, 0xa8, 0x00, 0xf0, 0x6c, 0xfc, 0x06, 0x23, 0x1f, 0x40, + 0x9f, 0x42, 0x03, 0xd1, 0x20, 0x1c, 0x13, 0x99, 0x00, 0xf0, 0xf6, 0xfb, + 0x21, 0x1c, 0x16, 0xa8, 0xff, 0xf7, 0x54, 0xff, 0x28, 0x1c, 0x16, 0xa9, + 0x32, 0x1c, 0xff, 0xf7, 0x0b, 0xfe, 0x28, 0x1c, 0x21, 0xb0, 0xf0, 0xbd, + 0xe0, 0x4e, 0x00, 0x00, 0x00, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x1c, + 0x08, 0x1c, 0x19, 0x1c, 0x38, 0x31, 0x02, 0x4a, 0x00, 0x23, 0xff, 0xf7, + 0xc9, 0xfe, 0x08, 0xbd, 0xa5, 0x23, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x1c, + 0x08, 0x1c, 0x19, 0x1c, 0x38, 0x31, 0x02, 0x4a, 0x00, 0x23, 0xff, 0xf7, + 0xbd, 0xfe, 0x08, 0xbd, 0xe1, 0x23, 0x00, 0x00, 0x08, 0x4b, 0x02, 0x21, + 0x19, 0x61, 0x19, 0x1c, 0x00, 0x22, 0x30, 0x31, 0x0a, 0x70, 0x06, 0x49, + 0x5a, 0x71, 0x9a, 0x71, 0x9a, 0x72, 0x1a, 0x73, 0xda, 0x63, 0x99, 0x63, + 0x41, 0x33, 0x1a, 0x70, 0x70, 0x47, 0xc0, 0x46, 0xd4, 0x00, 0x00, 0x20, + 0x00, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x01, 0x1c, 0x01, 0x48, 0x01, 0xf0, + 0xab, 0xf9, 0x08, 0xbd, 0x78, 0x07, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, + 0xff, 0x21, 0x01, 0xf0, 0xa3, 0xf9, 0x08, 0xbd, 0x78, 0x07, 0x00, 0x20, + 0x08, 0xb5, 0x01, 0x21, 0x00, 0x79, 0x01, 0xf0, 0x2b, 0xfc, 0x05, 0x4b, + 0x1a, 0x78, 0x00, 0x2a, 0x04, 0xd0, 0x00, 0x22, 0x03, 0x48, 0x1a, 0x70, + 0x01, 0xf0, 0x80, 0xf9, 0x08, 0xbd, 0xc0, 0x46, 0x40, 0x01, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x10, 0xb5, 0x08, 0x4b, 0x04, 0x1c, 0x1a, 0x78, + 0x00, 0x2a, 0x06, 0xd1, 0x01, 0x22, 0x1a, 0x70, 0x05, 0x4b, 0x06, 0x48, + 0x06, 0xcb, 0x01, 0xf0, 0x51, 0xf9, 0x20, 0x79, 0x00, 0x21, 0x01, 0xf0, + 0x0b, 0xfc, 0x10, 0xbd, 0x40, 0x01, 0x00, 0x20, 0x38, 0x01, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x10, 0xb5, 0x83, 0x79, 0x04, 0x1c, 0x00, 0x2b, + 0x0d, 0xd0, 0x23, 0x89, 0x5a, 0x1c, 0x22, 0x81, 0x05, 0x4a, 0x93, 0x42, + 0x02, 0xd8, 0xff, 0xf7, 0xbf, 0xff, 0xf6, 0xe7, 0x20, 0x1c, 0xff, 0xf7, + 0xc3, 0xff, 0x00, 0x23, 0xa3, 0x71, 0x10, 0xbd, 0x01, 0x02, 0x00, 0x00, + 0x00, 0xb5, 0x06, 0x29, 0x03, 0xd9, 0x16, 0x23, 0x43, 0x71, 0x00, 0x20, + 0x1c, 0xe0, 0x0f, 0x4b, 0x05, 0x29, 0x13, 0xd8, 0x08, 0x1c, 0x00, 0x22, + 0x02, 0xf0, 0xc0, 0xf9, 0x03, 0x05, 0x07, 0x09, 0x0b, 0x0d, 0x0b, 0x49, + 0x08, 0xe0, 0x0b, 0x49, 0x06, 0xe0, 0x0b, 0x49, 0x04, 0xe0, 0x0b, 0x49, + 0x02, 0xe0, 0x0b, 0x49, 0x00, 0xe0, 0x0b, 0x49, 0x19, 0x60, 0x02, 0xe0, + 0x0a, 0x4a, 0x1a, 0x60, 0x00, 0x22, 0x1a, 0x71, 0x5a, 0x71, 0x01, 0x20, + 0x00, 0xbd, 0xc0, 0x46, 0x38, 0x01, 0x00, 0x20, 0x00, 0x1b, 0xb7, 0x00, + 0x00, 0x09, 0x3d, 0x00, 0x80, 0x84, 0x1e, 0x00, 0x40, 0x42, 0x0f, 0x00, + 0x20, 0xa1, 0x07, 0x00, 0x90, 0xd0, 0x03, 0x00, 0x48, 0xe8, 0x01, 0x00, + 0x38, 0xb5, 0x0c, 0x1c, 0x01, 0xf0, 0xdc, 0xf9, 0x05, 0x1c, 0xff, 0xf7, + 0x79, 0xff, 0xff, 0x28, 0x06, 0xd0, 0x01, 0xf0, 0xd5, 0xf9, 0x40, 0x1b, + 0xa0, 0x42, 0xf6, 0xd3, 0x00, 0x20, 0x00, 0xe0, 0x01, 0x20, 0x38, 0xbd, + 0xf8, 0xb5, 0x04, 0x1c, 0x0e, 0x1c, 0x17, 0x1c, 0xff, 0xf7, 0x9c, 0xff, + 0x20, 0x1c, 0xff, 0xf7, 0x81, 0xff, 0x96, 0x21, 0x49, 0x00, 0x20, 0x1c, + 0xff, 0xf7, 0xe0, 0xff, 0x40, 0x20, 0x30, 0x43, 0xff, 0xf7, 0x54, 0xff, + 0x18, 0x25, 0x38, 0x1c, 0xe8, 0x40, 0xc0, 0xb2, 0x08, 0x3d, 0xff, 0xf7, + 0x4d, 0xff, 0x2b, 0x1c, 0x08, 0x33, 0xf6, 0xd1, 0x95, 0x20, 0x00, 0x2e, + 0x03, 0xd0, 0x87, 0x20, 0x08, 0x2e, 0x00, 0xd0, 0xff, 0x20, 0xff, 0xf7, + 0x41, 0xff, 0x00, 0x25, 0xff, 0xf7, 0x46, 0xff, 0x43, 0xb2, 0xe0, 0x72, + 0x00, 0x2b, 0x04, 0xda, 0xff, 0x2d, 0x02, 0xd0, 0x01, 0x35, 0xed, 0xb2, + 0xf4, 0xe7, 0xf8, 0xbd, 0xf7, 0xb5, 0x00, 0x25, 0x02, 0x71, 0x05, 0x73, + 0x85, 0x72, 0x85, 0x71, 0x45, 0x71, 0x04, 0x1c, 0x01, 0x91, 0x01, 0xf0, + 0x91, 0xf9, 0x01, 0x21, 0x07, 0x1c, 0x20, 0x79, 0x01, 0xf0, 0x0a, 0xfb, + 0x01, 0x21, 0x20, 0x79, 0x01, 0xf0, 0x60, 0xfb, 0x42, 0x4e, 0x30, 0x1c, + 0x01, 0xf0, 0x76, 0xf8, 0x41, 0x4b, 0x42, 0x49, 0x1d, 0x71, 0x5d, 0x71, + 0x19, 0x60, 0x30, 0x1c, 0x5a, 0x68, 0x01, 0xf0, 0x95, 0xf8, 0x0a, 0x25, + 0x01, 0x3d, 0xff, 0x20, 0xed, 0xb2, 0xff, 0xf7, 0x0d, 0xff, 0x00, 0x2d, + 0xf8, 0xd1, 0x30, 0x1c, 0x01, 0xf0, 0xa6, 0xf8, 0x20, 0x1c, 0xff, 0xf7, + 0x29, 0xff, 0x00, 0x21, 0x20, 0x1c, 0x0a, 0x1c, 0xff, 0xf7, 0x9a, 0xff, + 0x06, 0x1c, 0xe0, 0x72, 0x01, 0x28, 0x08, 0xd0, 0x01, 0xf0, 0x62, 0xf9, + 0xfa, 0x23, 0xc0, 0x1b, 0xdb, 0x00, 0x98, 0x42, 0xef, 0xd9, 0x01, 0x23, + 0x3b, 0xe0, 0xd5, 0x22, 0x20, 0x1c, 0x08, 0x21, 0x52, 0x00, 0xff, 0xf7, + 0x87, 0xff, 0x04, 0x23, 0x18, 0x42, 0x01, 0xd0, 0x26, 0x73, 0x0b, 0xe0, + 0x1e, 0x1c, 0xff, 0xf7, 0xed, 0xfe, 0x01, 0x3e, 0xf6, 0xb2, 0xe0, 0x72, + 0x00, 0x2e, 0xf8, 0xd1, 0x02, 0x23, 0xaa, 0x28, 0x25, 0xd1, 0x23, 0x73, + 0x26, 0x7b, 0x02, 0x3e, 0x73, 0x42, 0x5e, 0x41, 0xb6, 0x07, 0x37, 0x21, + 0x00, 0x22, 0x20, 0x1c, 0xff, 0xf7, 0x6c, 0xff, 0x32, 0x1c, 0x20, 0x1c, + 0x29, 0x21, 0xff, 0xf7, 0x67, 0xff, 0x02, 0x1c, 0xe0, 0x72, 0x08, 0xd0, + 0x01, 0xf0, 0x30, 0xf9, 0xfa, 0x23, 0xc0, 0x1b, 0xdb, 0x00, 0x98, 0x42, + 0xeb, 0xd9, 0x08, 0x23, 0x09, 0xe0, 0x23, 0x7b, 0x02, 0x2b, 0x19, 0xd1, + 0x20, 0x1c, 0x3a, 0x21, 0xff, 0xf7, 0x54, 0xff, 0x00, 0x28, 0x05, 0xd0, + 0x06, 0x23, 0x63, 0x71, 0x20, 0x1c, 0xff, 0xf7, 0xc3, 0xfe, 0x15, 0xe0, + 0xff, 0xf7, 0xb8, 0xfe, 0xc0, 0x23, 0x18, 0x40, 0x98, 0x42, 0x01, 0xd1, + 0x03, 0x23, 0x23, 0x73, 0xff, 0xf7, 0xb0, 0xfe, 0xff, 0xf7, 0xae, 0xfe, + 0xff, 0xf7, 0xac, 0xfe, 0x20, 0x1c, 0xff, 0xf7, 0xb1, 0xfe, 0x20, 0x1c, + 0x01, 0x99, 0xff, 0xf7, 0xef, 0xfe, 0x05, 0x1c, 0x28, 0x1c, 0xfe, 0xbd, + 0x78, 0x07, 0x00, 0x20, 0x38, 0x01, 0x00, 0x20, 0x90, 0xd0, 0x03, 0x00, + 0x38, 0xb5, 0x04, 0x1c, 0x01, 0xf0, 0xf8, 0xf8, 0x05, 0x1c, 0xff, 0xf7, + 0x95, 0xfe, 0xe0, 0x72, 0xff, 0x28, 0x08, 0xd1, 0x01, 0xf0, 0xf0, 0xf8, + 0x96, 0x23, 0x40, 0x1b, 0x5b, 0x00, 0x98, 0x42, 0xf3, 0xd9, 0x0f, 0x23, + 0x02, 0xe0, 0xfe, 0x28, 0x06, 0xd0, 0x0d, 0x23, 0x20, 0x1c, 0x63, 0x71, + 0xff, 0xf7, 0x8a, 0xfe, 0x00, 0x20, 0x00, 0xe0, 0x01, 0x20, 0x38, 0xbd, + 0xf8, 0xb5, 0x04, 0x1c, 0x0f, 0x1c, 0x15, 0x1c, 0x1e, 0x1e, 0x45, 0xd0, + 0x9a, 0x18, 0x80, 0x23, 0x9b, 0x00, 0x9a, 0x42, 0x42, 0xdc, 0x83, 0x79, + 0x00, 0x2b, 0x05, 0xd0, 0x02, 0x68, 0x91, 0x42, 0x02, 0xd1, 0x03, 0x89, + 0xab, 0x42, 0x16, 0xd9, 0x23, 0x7b, 0x27, 0x60, 0x03, 0x2b, 0x00, 0xd0, + 0x7f, 0x02, 0x3a, 0x1c, 0x20, 0x1c, 0x11, 0x21, 0xff, 0xf7, 0xf2, 0xfe, + 0x07, 0x1e, 0x02, 0xd0, 0x03, 0x23, 0x63, 0x71, 0x2a, 0xe0, 0x20, 0x1c, + 0xff, 0xf7, 0xbc, 0xff, 0x00, 0x28, 0x25, 0xd0, 0x01, 0x23, 0x27, 0x81, + 0xa3, 0x71, 0x23, 0x89, 0xab, 0x42, 0x05, 0xd2, 0xff, 0xf7, 0x4e, 0xfe, + 0x23, 0x89, 0x01, 0x33, 0x23, 0x81, 0xf6, 0xe7, 0x06, 0x9d, 0x06, 0x9a, + 0xab, 0x1a, 0x9b, 0xb2, 0xb3, 0x42, 0x04, 0xd2, 0xff, 0xf7, 0x42, 0xfe, + 0x28, 0x70, 0x01, 0x35, 0xf5, 0xe7, 0x23, 0x89, 0xa2, 0x7a, 0xf3, 0x18, + 0x9b, 0xb2, 0x23, 0x81, 0x00, 0x2a, 0x02, 0xd0, 0x06, 0x4a, 0x93, 0x42, + 0x02, 0xd9, 0x20, 0x1c, 0xff, 0xf7, 0x66, 0xfe, 0x01, 0x20, 0x03, 0xe0, + 0x20, 0x1c, 0xff, 0xf7, 0x35, 0xfe, 0x00, 0x20, 0xf8, 0xbd, 0xc0, 0x46, + 0xff, 0x01, 0x00, 0x00, 0x07, 0xb5, 0x80, 0x23, 0x00, 0x92, 0x9b, 0x00, + 0x00, 0x22, 0xff, 0xf7, 0xa3, 0xff, 0x0e, 0xbd, 0x70, 0xb5, 0x05, 0x1c, + 0x08, 0x1c, 0x16, 0x1c, 0xff, 0xf7, 0x12, 0xfe, 0x00, 0x24, 0x30, 0x5d, + 0xff, 0xf7, 0x0e, 0xfe, 0x01, 0x34, 0x80, 0x23, 0x9b, 0x00, 0x9c, 0x42, + 0xf7, 0xd1, 0xff, 0x20, 0xff, 0xf7, 0x06, 0xfe, 0xff, 0x20, 0xff, 0xf7, + 0x03, 0xfe, 0xff, 0xf7, 0x09, 0xfe, 0x1f, 0x23, 0xe8, 0x72, 0x03, 0x40, + 0x01, 0x20, 0x05, 0x2b, 0x05, 0xd0, 0x11, 0x23, 0x28, 0x1c, 0x6b, 0x71, + 0xff, 0xf7, 0x06, 0xfe, 0x00, 0x20, 0x70, 0xbd, 0x70, 0xb5, 0x0b, 0x1c, + 0x04, 0x1c, 0x16, 0x1c, 0x00, 0x29, 0x01, 0xd1, 0x12, 0x23, 0x28, 0xe0, + 0x02, 0x7b, 0x03, 0x2a, 0x00, 0xd0, 0x4b, 0x02, 0x20, 0x1c, 0x18, 0x21, + 0x1a, 0x1c, 0xff, 0xf7, 0x7d, 0xfe, 0x05, 0x1e, 0x01, 0xd0, 0x04, 0x23, + 0x1b, 0xe0, 0x20, 0x1c, 0xfe, 0x21, 0x32, 0x1c, 0xff, 0xf7, 0xc2, 0xff, + 0x00, 0x28, 0x15, 0xd0, 0x96, 0x21, 0x20, 0x1c, 0x89, 0x00, 0xff, 0xf7, + 0x5b, 0xfe, 0x00, 0x28, 0x01, 0xd1, 0x15, 0x23, 0x0b, 0xe0, 0x20, 0x1c, + 0x0d, 0x21, 0x2a, 0x1c, 0xff, 0xf7, 0x64, 0xfe, 0x00, 0x28, 0x03, 0xd1, + 0xff, 0xf7, 0xce, 0xfd, 0x00, 0x28, 0x06, 0xd0, 0x14, 0x23, 0x63, 0x71, + 0x20, 0x1c, 0xff, 0xf7, 0xcf, 0xfd, 0x00, 0x20, 0x03, 0xe0, 0x20, 0x1c, + 0xff, 0xf7, 0xca, 0xfd, 0x01, 0x20, 0x70, 0xbd, 0x03, 0x4b, 0x04, 0x4a, + 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x70, 0x47, 0xc0, 0x46, + 0x38, 0x01, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, 0x02, 0x1c, 0x10, 0xb5, + 0x0c, 0x32, 0x04, 0x1c, 0x01, 0x21, 0x40, 0x6a, 0x00, 0xf0, 0x24, 0xfd, + 0x00, 0x28, 0x0a, 0xd0, 0x23, 0x6a, 0x01, 0x20, 0x00, 0x2b, 0x06, 0xd1, + 0xe3, 0x68, 0x22, 0x7a, 0x23, 0x62, 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, + 0x23, 0x72, 0x10, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xe6, 0xff, + 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x1b, 0xe0, 0x63, 0x6a, 0xe6, 0x68, + 0x1a, 0x7c, 0x02, 0x3e, 0x96, 0x40, 0x5a, 0x69, 0x1d, 0x79, 0xb6, 0x18, + 0x00, 0x2d, 0x08, 0xd0, 0x70, 0x1e, 0x40, 0x19, 0x00, 0xf0, 0x4c, 0xfc, + 0x00, 0x28, 0xed, 0xd0, 0x01, 0x3d, 0xed, 0xb2, 0xf4, 0xe7, 0x63, 0x6a, + 0x01, 0x20, 0x1a, 0x7c, 0x80, 0x23, 0x9b, 0x00, 0x93, 0x40, 0xe2, 0x69, + 0xd3, 0x18, 0xe3, 0x61, 0x70, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, + 0x40, 0x69, 0x00, 0xf0, 0x13, 0xfc, 0x00, 0x28, 0x03, 0xd0, 0x20, 0x7e, + 0x01, 0x4b, 0x40, 0x01, 0xc0, 0x18, 0x10, 0xbd, 0x50, 0x01, 0x00, 0x20, + 0xf0, 0xb5, 0x00, 0x23, 0x87, 0xb0, 0x07, 0x1c, 0x0e, 0x1c, 0x20, 0x22, + 0xf2, 0x54, 0x01, 0x33, 0x0b, 0x2b, 0xfa, 0xd1, 0x07, 0x21, 0x00, 0x25, + 0x01, 0x91, 0x3c, 0x78, 0x00, 0x2c, 0x2a, 0xd0, 0x2e, 0x2c, 0x06, 0xd1, + 0x01, 0x9b, 0x0a, 0x2b, 0x2b, 0xd0, 0x0a, 0x21, 0x08, 0x25, 0x01, 0x91, + 0x1f, 0xe0, 0x02, 0xa8, 0x14, 0x49, 0x10, 0x22, 0x02, 0xf0, 0x07, 0xf8, + 0x00, 0x23, 0x02, 0xa9, 0xca, 0x5c, 0x00, 0x2a, 0x03, 0xd0, 0x01, 0x33, + 0xa2, 0x42, 0xf8, 0xd1, 0x19, 0xe0, 0x01, 0x9b, 0x9d, 0x42, 0x16, 0xd8, + 0x23, 0x1c, 0x21, 0x3b, 0x5d, 0x2b, 0x12, 0xd8, 0x22, 0x1c, 0x6b, 0x1c, + 0x61, 0x3a, 0xdb, 0xb2, 0x75, 0x19, 0x19, 0x2a, 0x01, 0xd8, 0x20, 0x3c, + 0xe4, 0xb2, 0x2c, 0x70, 0x1d, 0x1c, 0x01, 0x37, 0xd1, 0xe7, 0x30, 0x78, + 0x20, 0x38, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x00, 0xe0, 0x00, 0x20, + 0x07, 0xb0, 0xf0, 0xbd, 0xe2, 0x4e, 0x00, 0x00, 0x38, 0xb5, 0x42, 0x7a, + 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x2a, 0x01, 0xd0, 0x00, 0x20, 0x1f, 0xe0, + 0x4b, 0x1c, 0xdb, 0x7f, 0x10, 0x2b, 0x06, 0xd1, 0x02, 0x23, 0x43, 0x72, + 0x02, 0x62, 0x4b, 0x8c, 0x5b, 0x01, 0xc3, 0x61, 0x0c, 0xe0, 0x20, 0x2b, + 0xf0, 0xd1, 0x03, 0x23, 0x43, 0x72, 0x49, 0x6a, 0x22, 0x1c, 0x01, 0x62, + 0x1c, 0x32, 0x28, 0x1c, 0x00, 0xf0, 0x18, 0xfc, 0x00, 0x28, 0xe5, 0xd0, + 0x00, 0x23, 0x01, 0x20, 0x65, 0x62, 0x20, 0x72, 0xe3, 0x60, 0x23, 0x61, + 0x63, 0x61, 0x23, 0x76, 0x38, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x43, 0x7a, + 0x85, 0xb0, 0x04, 0x1c, 0x0e, 0x1c, 0x03, 0x92, 0x00, 0x2b, 0x01, 0xd1, + 0x3a, 0x48, 0x11, 0xe0, 0x03, 0x7a, 0xd8, 0x07, 0xfa, 0xd5, 0xe2, 0x69, + 0x20, 0x69, 0x03, 0x99, 0x13, 0x1a, 0x99, 0x42, 0x01, 0xd9, 0x9b, 0xb2, + 0x03, 0x93, 0x03, 0x99, 0x02, 0x91, 0x02, 0x9b, 0x00, 0x2b, 0x04, 0xd1, + 0x03, 0x99, 0x88, 0xb2, 0x00, 0xb2, 0x05, 0xb0, 0xf0, 0xbd, 0x23, 0x69, + 0x61, 0x7a, 0xdf, 0x05, 0xff, 0x0d, 0x5a, 0x0a, 0x60, 0x6a, 0x02, 0x29, + 0x02, 0xd1, 0x41, 0x6a, 0x51, 0x18, 0x1b, 0xe0, 0x05, 0x79, 0x01, 0x3d, + 0x2a, 0x40, 0xd5, 0xb2, 0x00, 0x2f, 0x0d, 0xd1, 0x00, 0x2d, 0x0b, 0xd1, + 0x00, 0x2b, 0x02, 0xd1, 0x22, 0x6a, 0xe2, 0x60, 0x06, 0xe0, 0x22, 0x1c, + 0xe1, 0x68, 0x0c, 0x32, 0x00, 0xf0, 0xa0, 0xfb, 0x00, 0x28, 0xc9, 0xd0, + 0x63, 0x6a, 0xe1, 0x68, 0x1a, 0x7c, 0x02, 0x39, 0x5b, 0x69, 0x91, 0x40, + 0xc9, 0x18, 0x49, 0x19, 0x80, 0x22, 0x02, 0x9d, 0x92, 0x00, 0xd3, 0x1b, + 0x9d, 0x42, 0x00, 0xdd, 0x9d, 0xb2, 0x23, 0x7a, 0x58, 0x06, 0x01, 0xd4, + 0x95, 0x42, 0x18, 0xd1, 0x16, 0x4b, 0x1b, 0x68, 0x99, 0x42, 0x14, 0xd0, + 0x15, 0x4b, 0x3a, 0x1c, 0x18, 0x68, 0x00, 0x96, 0x2b, 0x1c, 0xff, 0xf7, + 0x1f, 0xfe, 0x00, 0x28, 0xa8, 0xd0, 0x76, 0x19, 0x01, 0xe0, 0xdf, 0x1b, + 0xf6, 0x19, 0x21, 0x69, 0x02, 0x9a, 0x4b, 0x19, 0x55, 0x1b, 0xad, 0xb2, + 0x23, 0x61, 0x02, 0x95, 0xab, 0xe7, 0x08, 0x1c, 0x00, 0x21, 0x00, 0xf0, + 0x2b, 0xfb, 0x00, 0x28, 0x96, 0xd0, 0x09, 0x4b, 0x32, 0x1c, 0xff, 0x18, + 0x79, 0x19, 0x3b, 0x1c, 0x8b, 0x42, 0xe8, 0xd0, 0x18, 0x78, 0x01, 0x33, + 0x10, 0x70, 0x01, 0x32, 0xf8, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x73, 0xb5, 0x43, 0x7a, 0x04, 0x1c, 0x01, 0x2b, 0x01, 0xd8, 0x00, 0x20, + 0x16, 0xe0, 0x03, 0x69, 0x6d, 0x46, 0x07, 0x35, 0xde, 0x05, 0x29, 0x1c, + 0x01, 0x22, 0x36, 0x0f, 0xff, 0xf7, 0x6a, 0xff, 0x01, 0x28, 0x01, 0xd1, + 0x2b, 0x78, 0x00, 0xe0, 0x05, 0x4b, 0x1b, 0xb2, 0x01, 0x33, 0xec, 0xd0, + 0x23, 0x69, 0x70, 0x01, 0x1f, 0x33, 0x23, 0x61, 0x02, 0x4b, 0xc0, 0x18, + 0x76, 0xbd, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0x50, 0x01, 0x00, 0x20, + 0x70, 0xb5, 0x04, 0x1c, 0x40, 0x7a, 0x0d, 0x1c, 0x00, 0x28, 0x2a, 0xd0, + 0xe2, 0x69, 0x91, 0x42, 0x01, 0xd9, 0x00, 0x20, 0x25, 0xe0, 0x02, 0x28, + 0x21, 0xd0, 0x00, 0x2d, 0x01, 0xd1, 0xe5, 0x60, 0x1d, 0xe0, 0x62, 0x6a, + 0x21, 0x69, 0x13, 0x7c, 0x68, 0x1e, 0x09, 0x33, 0x4a, 0x1e, 0xd8, 0x40, + 0xda, 0x40, 0x03, 0x1e, 0x93, 0x42, 0x01, 0xd3, 0x00, 0x29, 0x02, 0xd1, + 0x22, 0x6a, 0xe2, 0x60, 0x00, 0xe0, 0x83, 0x1a, 0x1e, 0x1c, 0x00, 0x2e, + 0x09, 0xd0, 0x22, 0x1c, 0x60, 0x6a, 0xe1, 0x68, 0x0c, 0x32, 0x00, 0xf0, + 0x07, 0xfb, 0x01, 0x3e, 0x00, 0x28, 0xf4, 0xd1, 0x01, 0xe0, 0x25, 0x61, + 0x01, 0x20, 0x70, 0xbd, 0x38, 0xb5, 0x05, 0x1c, 0x40, 0x7a, 0x00, 0x28, + 0x33, 0xd0, 0x2b, 0x7a, 0x7f, 0x2b, 0x2d, 0xd9, 0x28, 0x1c, 0x01, 0x21, + 0xff, 0xf7, 0x9a, 0xfe, 0x04, 0x1e, 0x2a, 0xd0, 0x6b, 0x7a, 0x01, 0x2b, + 0x07, 0xd8, 0x2b, 0x7f, 0x03, 0x77, 0x6b, 0x7f, 0x43, 0x77, 0xab, 0x7f, + 0x83, 0x77, 0xeb, 0x7f, 0xc3, 0x77, 0x2b, 0x6a, 0x9a, 0xb2, 0x1b, 0x0c, + 0x23, 0x75, 0x1b, 0x0a, 0x63, 0x75, 0x0d, 0x4b, 0xa2, 0x76, 0x1b, 0x68, + 0x12, 0x0a, 0xe2, 0x76, 0x00, 0x2b, 0x0b, 0xd0, 0x20, 0x1c, 0x21, 0x1c, + 0x18, 0x30, 0x16, 0x31, 0x98, 0x47, 0x63, 0x7e, 0x22, 0x7e, 0x1b, 0x02, + 0x13, 0x43, 0xa3, 0x74, 0x1b, 0x0a, 0xe3, 0x74, 0x2a, 0x7a, 0x7f, 0x23, + 0x13, 0x40, 0x2b, 0x72, 0x00, 0xf0, 0x5c, 0xfa, 0xff, 0xe7, 0x38, 0xbd, + 0x44, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xc0, 0xff, + 0x00, 0x28, 0x02, 0xd0, 0x00, 0x23, 0x63, 0x72, 0x01, 0x20, 0x10, 0xbd, + 0x73, 0xb5, 0x42, 0x7a, 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x20, 0x01, 0x2a, + 0x4b, 0xd1, 0x20, 0x7a, 0x02, 0x23, 0x18, 0x40, 0x47, 0xd0, 0xe3, 0x69, + 0x00, 0x20, 0x99, 0x42, 0x43, 0xd8, 0x10, 0x1c, 0x00, 0x2b, 0x40, 0xd0, + 0x20, 0x1c, 0x29, 0x1c, 0x26, 0x69, 0xff, 0xf7, 0x71, 0xff, 0x00, 0x28, + 0x25, 0xd0, 0x60, 0x6a, 0x00, 0x2d, 0x06, 0xd1, 0x21, 0x6a, 0x00, 0xf0, + 0x95, 0xfb, 0x00, 0x28, 0x1d, 0xd0, 0x25, 0x62, 0x1d, 0xe0, 0xe1, 0x68, + 0x01, 0xaa, 0x00, 0xf0, 0x93, 0xfa, 0x00, 0x28, 0x15, 0xd0, 0x60, 0x6a, + 0x01, 0x99, 0x43, 0x1c, 0xdb, 0x7f, 0x10, 0x2b, 0x01, 0xd1, 0x12, 0x4b, + 0x00, 0xe0, 0x12, 0x4b, 0x99, 0x42, 0x0c, 0xd2, 0x00, 0xf0, 0x7e, 0xfb, + 0x00, 0x28, 0x06, 0xd0, 0x60, 0x6a, 0xe1, 0x68, 0x0e, 0x4a, 0x00, 0xf0, + 0xcf, 0xfa, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x11, 0xe0, 0x22, 0x7a, + 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, 0xe5, 0x61, 0x23, 0x72, 0x20, 0x1c, + 0xff, 0xf7, 0x70, 0xff, 0x00, 0x28, 0xf2, 0xd0, 0x29, 0x1e, 0xb1, 0x42, + 0x00, 0xd9, 0x31, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x35, 0xff, 0x76, 0xbd, + 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, 0xff, 0xff, 0xff, 0x0f, + 0x38, 0xb5, 0x23, 0x4b, 0x15, 0x1c, 0x4a, 0x01, 0xd3, 0x18, 0x04, 0x1c, + 0xd8, 0x7a, 0x11, 0x22, 0x10, 0x42, 0x04, 0xd0, 0x42, 0x22, 0x15, 0x42, + 0x01, 0xd0, 0x00, 0x20, 0x36, 0xe0, 0x1d, 0x4a, 0x21, 0x76, 0x12, 0x68, + 0x62, 0x61, 0x5a, 0x7d, 0x18, 0x7d, 0xd9, 0x7e, 0x12, 0x02, 0x02, 0x43, + 0x98, 0x7e, 0x09, 0x02, 0x12, 0x04, 0x01, 0x43, 0x11, 0x43, 0x21, 0x62, + 0xd8, 0x7a, 0x18, 0x22, 0x02, 0x40, 0x0c, 0xd1, 0x5a, 0x7f, 0x19, 0x7f, + 0x12, 0x02, 0x0a, 0x43, 0x99, 0x7f, 0xdb, 0x7f, 0x09, 0x04, 0x0a, 0x43, + 0x1b, 0x06, 0x13, 0x43, 0xe3, 0x61, 0x01, 0x23, 0x09, 0xe0, 0x10, 0x2a, + 0xdb, 0xd1, 0x22, 0x1c, 0x60, 0x6a, 0x1c, 0x32, 0x00, 0xf0, 0x5a, 0xfa, + 0x00, 0x28, 0xd4, 0xd0, 0x04, 0x23, 0x63, 0x72, 0x0f, 0x23, 0x00, 0x21, + 0x2b, 0x40, 0x23, 0x72, 0xe1, 0x60, 0x21, 0x61, 0x01, 0x20, 0x6a, 0x06, + 0x02, 0xd5, 0x20, 0x1c, 0xff, 0xf7, 0x60, 0xff, 0x38, 0xbd, 0xc0, 0x46, + 0x50, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0xf0, 0xb5, 0x45, 0x7a, + 0x87, 0xb0, 0x04, 0x1c, 0x0e, 0x1c, 0x01, 0x93, 0x00, 0x2d, 0x00, 0xd0, + 0x86, 0xe0, 0x10, 0x1c, 0x03, 0xa9, 0xff, 0xf7, 0xbb, 0xfd, 0x00, 0x28, + 0x00, 0xd1, 0x80, 0xe0, 0x72, 0x6a, 0x2f, 0x1c, 0x62, 0x62, 0xf5, 0x60, + 0x35, 0x61, 0x33, 0x69, 0xf2, 0x69, 0x93, 0x42, 0x26, 0xd2, 0xdb, 0x05, + 0x1b, 0x0f, 0x30, 0x1c, 0x00, 0x93, 0xff, 0xf7, 0x9f, 0xfe, 0x01, 0x1e, + 0x6f, 0xd0, 0x03, 0x78, 0x00, 0x2b, 0x01, 0xd0, 0xe5, 0x2b, 0x0b, 0xd1, + 0x00, 0x2f, 0x04, 0xd1, 0x00, 0x9b, 0x23, 0x76, 0x34, 0x4b, 0x1b, 0x68, + 0x63, 0x61, 0x0b, 0x78, 0x01, 0x27, 0x00, 0x2b, 0xe3, 0xd1, 0x0d, 0xe0, + 0x03, 0xa8, 0x0b, 0x22, 0x01, 0xf0, 0xa8, 0xfd, 0x00, 0x28, 0xdc, 0xd1, + 0x01, 0x9a, 0x30, 0x23, 0x13, 0x40, 0x30, 0x2b, 0x53, 0xd0, 0x20, 0x1c, + 0x00, 0x99, 0x4b, 0xe0, 0x01, 0x9a, 0x12, 0x23, 0x13, 0x40, 0x12, 0x2b, + 0x4b, 0xd1, 0x00, 0x2f, 0x06, 0xd0, 0x20, 0x1c, 0x01, 0x21, 0xff, 0xf7, + 0x6f, 0xfd, 0x06, 0x1e, 0x0a, 0xd1, 0x42, 0xe0, 0x73, 0x7a, 0x02, 0x2b, + 0x3f, 0xd0, 0x30, 0x1c, 0xff, 0xf7, 0x40, 0xfd, 0x00, 0x28, 0x3a, 0xd0, + 0x1f, 0x4e, 0x27, 0x76, 0x00, 0x21, 0x20, 0x22, 0x30, 0x1c, 0x01, 0xf0, + 0x99, 0xfd, 0x30, 0x1c, 0x03, 0xa9, 0x0b, 0x22, 0x01, 0xf0, 0x8b, 0xfd, + 0x1a, 0x4b, 0x1b, 0x68, 0x00, 0x2b, 0x05, 0xd0, 0x30, 0x1c, 0x31, 0x1c, + 0x10, 0x30, 0x0e, 0x31, 0x98, 0x47, 0x06, 0xe0, 0x21, 0x22, 0x32, 0x74, + 0xb3, 0x73, 0x28, 0x22, 0x08, 0x23, 0x72, 0x74, 0xf3, 0x73, 0x73, 0x7c, + 0x32, 0x7c, 0x1b, 0x02, 0x13, 0x43, 0xff, 0x22, 0x1a, 0x40, 0x1b, 0x0a, + 0xf3, 0x74, 0x73, 0x76, 0xf3, 0x7b, 0xb2, 0x74, 0x32, 0x76, 0xb2, 0x7b, + 0x1b, 0x02, 0x13, 0x43, 0xb3, 0x75, 0x1b, 0x0a, 0xf3, 0x75, 0x00, 0xf0, + 0x21, 0xf9, 0x00, 0x28, 0x07, 0xd0, 0x21, 0x7e, 0x01, 0x9a, 0x20, 0x1c, + 0xff, 0xf7, 0x26, 0xff, 0x05, 0x1c, 0x00, 0xe0, 0x00, 0x25, 0x28, 0x1c, + 0x07, 0xb0, 0xf0, 0xbd, 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x44, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x00, 0x21, 0x04, 0x1c, 0xff, 0xf7, + 0xbb, 0xfe, 0x00, 0x28, 0x0b, 0xd0, 0x20, 0x1c, 0x01, 0x21, 0xff, 0xf7, + 0x15, 0xfd, 0x00, 0x28, 0x05, 0xd0, 0xe5, 0x23, 0x03, 0x70, 0x00, 0x23, + 0x63, 0x72, 0x00, 0xf0, 0xfb, 0xf8, 0x10, 0xbd, 0x10, 0xb5, 0x0a, 0x1c, + 0x0a, 0x49, 0x8a, 0xb0, 0x08, 0x31, 0x00, 0x23, 0x04, 0x1c, 0x00, 0x91, + 0x69, 0x46, 0x4b, 0x72, 0x01, 0x93, 0x68, 0x46, 0x21, 0x1c, 0x02, 0x23, + 0xff, 0xf7, 0x42, 0xff, 0x00, 0x28, 0x02, 0xd0, 0x68, 0x46, 0xff, 0xf7, + 0xd7, 0xff, 0x0a, 0xb0, 0x10, 0xbd, 0xc0, 0x46, 0xf8, 0x4e, 0x00, 0x00, + 0xf0, 0xb5, 0x43, 0x7a, 0x87, 0xb0, 0x04, 0x1c, 0x0d, 0x1c, 0x03, 0x92, + 0x01, 0x2b, 0x0d, 0xd1, 0x03, 0x7a, 0x99, 0x07, 0x0a, 0xd5, 0x5a, 0x07, + 0x0c, 0xd5, 0xe1, 0x69, 0x22, 0x69, 0x8a, 0x42, 0x08, 0xd0, 0x20, 0x1c, + 0xff, 0xf7, 0x06, 0xfe, 0x00, 0x28, 0x03, 0xd1, 0x01, 0x23, 0x63, 0x60, + 0x00, 0x20, 0xaa, 0xe0, 0x03, 0x9b, 0x01, 0x93, 0x3b, 0xe0, 0x60, 0x6a, + 0x73, 0x0a, 0x07, 0x79, 0xf6, 0x05, 0x01, 0x3f, 0x1f, 0x40, 0xff, 0xb2, + 0xf6, 0x0d, 0x00, 0x2f, 0x36, 0xd0, 0x80, 0x22, 0x92, 0x00, 0x92, 0x1b, + 0x01, 0x99, 0x92, 0xb2, 0x0b, 0x1c, 0x91, 0x42, 0x00, 0xd9, 0x13, 0x1c, + 0x9b, 0xb2, 0x02, 0x93, 0x63, 0x6a, 0xe1, 0x68, 0x1a, 0x7c, 0x02, 0x39, + 0x91, 0x40, 0x5a, 0x69, 0x8b, 0x18, 0x02, 0x9a, 0xdf, 0x19, 0x80, 0x23, + 0x9b, 0x00, 0x9a, 0x42, 0x3f, 0xd1, 0x44, 0x4b, 0x19, 0x68, 0xb9, 0x42, + 0x02, 0xd1, 0x01, 0x22, 0x52, 0x42, 0x1a, 0x60, 0x41, 0x4b, 0x39, 0x1c, + 0x18, 0x68, 0x2a, 0x1c, 0xff, 0xf7, 0x22, 0xfc, 0x00, 0x28, 0xc7, 0xd0, + 0x80, 0x22, 0x92, 0x00, 0xad, 0x18, 0x01, 0x99, 0x02, 0x9a, 0x8b, 0x1a, + 0x21, 0x69, 0x9b, 0xb2, 0x01, 0x93, 0x8b, 0x18, 0x23, 0x61, 0x01, 0x9a, + 0x26, 0x69, 0x00, 0x2a, 0xbf, 0xd1, 0x49, 0xe0, 0x00, 0x2e, 0xc6, 0xd1, + 0xe1, 0x68, 0x00, 0x29, 0x03, 0xd1, 0x23, 0x6a, 0x00, 0x2b, 0x16, 0xd1, + 0x0f, 0xe0, 0x05, 0xaa, 0x00, 0xf0, 0xe2, 0xf8, 0x00, 0x28, 0x58, 0xd0, + 0x62, 0x6a, 0x05, 0x9b, 0x01, 0x32, 0xd2, 0x7f, 0x10, 0x2a, 0x01, 0xd1, + 0x2c, 0x4a, 0x00, 0xe0, 0x2c, 0x4a, 0x93, 0x42, 0x05, 0xd3, 0x20, 0x1c, + 0xff, 0xf7, 0x3c, 0xfc, 0x00, 0x28, 0xaa, 0xd1, 0x98, 0xe7, 0xe3, 0x60, + 0xa7, 0xe7, 0x00, 0x2e, 0x0f, 0xd1, 0x23, 0x69, 0xe1, 0x69, 0x8b, 0x42, + 0x0b, 0xd3, 0x00, 0xf0, 0x59, 0xf8, 0x00, 0x28, 0x8c, 0xd0, 0x1f, 0x4b, + 0x01, 0x21, 0x1f, 0x60, 0x21, 0x4b, 0x1a, 0x78, 0x0a, 0x43, 0x1a, 0x70, + 0x06, 0xe0, 0x38, 0x1c, 0x01, 0x21, 0x00, 0xf0, 0x75, 0xf8, 0x00, 0x28, + 0x00, 0xd1, 0x7d, 0xe7, 0x1c, 0x4b, 0x2a, 0x1c, 0xf6, 0x18, 0x02, 0x9b, + 0xf1, 0x18, 0x33, 0x1c, 0x8b, 0x42, 0x04, 0xd0, 0x10, 0x78, 0x01, 0x32, + 0x18, 0x70, 0x01, 0x33, 0xf8, 0xe7, 0x9e, 0x1b, 0xad, 0x19, 0xa8, 0xe7, + 0xe1, 0x69, 0x23, 0x7a, 0x8e, 0x42, 0x01, 0xd9, 0xe6, 0x61, 0x06, 0xe0, + 0x12, 0x4a, 0x12, 0x68, 0x00, 0x2a, 0x06, 0xd0, 0x03, 0x9a, 0x00, 0x2a, + 0x03, 0xd0, 0x80, 0x22, 0x52, 0x42, 0x13, 0x43, 0x23, 0x72, 0x23, 0x7a, + 0x19, 0x07, 0x01, 0xd4, 0x03, 0x98, 0x06, 0xe0, 0x20, 0x1c, 0xff, 0xf7, + 0x8b, 0xfd, 0x00, 0x28, 0x00, 0xd1, 0x51, 0xe7, 0xf6, 0xe7, 0x07, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, + 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, 0x50, 0x03, 0x00, 0x20, + 0x50, 0x01, 0x00, 0x20, 0x44, 0x01, 0x00, 0x20, 0x07, 0xb5, 0x6b, 0x46, + 0xd9, 0x71, 0x07, 0x33, 0x19, 0x1c, 0x01, 0x22, 0xff, 0xf7, 0x22, 0xff, + 0x0e, 0xbd, 0x00, 0x00, 0xf8, 0xb5, 0x0f, 0x4f, 0x01, 0x20, 0x3b, 0x78, + 0x00, 0x2b, 0x18, 0xd0, 0x0d, 0x4e, 0x0e, 0x4b, 0x0e, 0x4d, 0x19, 0x68, + 0x30, 0x68, 0x2a, 0x1c, 0xff, 0xf7, 0x80, 0xfb, 0x00, 0x28, 0x0e, 0xd0, + 0x0b, 0x4c, 0x21, 0x68, 0x00, 0x29, 0x07, 0xd0, 0x30, 0x68, 0x2a, 0x1c, + 0xff, 0xf7, 0x76, 0xfb, 0x00, 0x28, 0x04, 0xd0, 0x00, 0x23, 0x23, 0x60, + 0x00, 0x23, 0x3b, 0x70, 0x01, 0x20, 0xf8, 0xbd, 0x50, 0x03, 0x00, 0x20, + 0x4c, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x48, 0x01, 0x00, 0x20, 0x70, 0xb5, 0x0d, 0x4d, 0x04, 0x1c, 0x2b, 0x68, + 0x0e, 0x1c, 0x83, 0x42, 0x0e, 0xd0, 0xff, 0xf7, 0xcd, 0xff, 0x00, 0x28, + 0x01, 0xd1, 0x00, 0x20, 0x0d, 0xe0, 0x08, 0x4b, 0x21, 0x1c, 0x18, 0x68, + 0x07, 0x4a, 0xff, 0xf7, 0x25, 0xfb, 0x00, 0x28, 0xf5, 0xd0, 0x2c, 0x60, + 0x05, 0x4b, 0x01, 0x20, 0x1a, 0x78, 0x16, 0x43, 0x1e, 0x70, 0x70, 0xbd, + 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x50, 0x03, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xae, 0xff, + 0x00, 0x28, 0x0f, 0xd0, 0x00, 0x23, 0x08, 0x4a, 0x00, 0x21, 0x99, 0x54, + 0x80, 0x22, 0x01, 0x33, 0x92, 0x00, 0x93, 0x42, 0xf7, 0xd1, 0x05, 0x4b, + 0x01, 0x20, 0x1c, 0x60, 0x04, 0x4b, 0x1a, 0x78, 0x02, 0x43, 0x1a, 0x70, + 0x10, 0xbd, 0xc0, 0x46, 0x50, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, + 0x50, 0x03, 0x00, 0x20, 0xc3, 0x68, 0x70, 0xb5, 0x01, 0x33, 0x0c, 0x1c, + 0x15, 0x1c, 0x99, 0x42, 0x01, 0xd9, 0x00, 0x20, 0x21, 0xe0, 0x46, 0x1c, + 0xf1, 0x7f, 0xc2, 0x69, 0xe3, 0x09, 0x10, 0x29, 0x00, 0xd1, 0x23, 0x0a, + 0x98, 0x18, 0x0d, 0x4b, 0x1b, 0x68, 0x98, 0x42, 0x07, 0xd1, 0xf2, 0x7f, + 0x0b, 0x4b, 0x10, 0x2a, 0x09, 0xd1, 0xe4, 0xb2, 0x64, 0x00, 0x1b, 0x5b, + 0x0b, 0xe0, 0x00, 0x21, 0xff, 0xf7, 0x9e, 0xff, 0x00, 0x28, 0xf2, 0xd1, + 0xe3, 0xe7, 0x7f, 0x22, 0x14, 0x40, 0xa4, 0x00, 0x1b, 0x59, 0x1b, 0x01, + 0x1b, 0x09, 0x2b, 0x60, 0x01, 0x20, 0x70, 0xbd, 0x00, 0x00, 0x00, 0x20, + 0x50, 0x01, 0x00, 0x20, 0x73, 0xb5, 0x05, 0x1c, 0x01, 0x91, 0x16, 0x1c, + 0x00, 0x24, 0x28, 0x1c, 0x01, 0x99, 0x01, 0xaa, 0xff, 0xf7, 0xc6, 0xff, + 0x00, 0x28, 0x10, 0xd0, 0x2a, 0x7c, 0x80, 0x23, 0x9b, 0x00, 0x93, 0x40, + 0xe4, 0x18, 0x6b, 0x1c, 0xdb, 0x7f, 0x01, 0x9a, 0x10, 0x2b, 0x01, 0xd1, + 0x03, 0x4b, 0x00, 0xe0, 0x03, 0x4b, 0x9a, 0x42, 0xe9, 0xd3, 0x34, 0x60, + 0x01, 0x20, 0x76, 0xbd, 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, + 0xf7, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x01, 0x92, 0x01, 0x29, 0x32, 0xd9, + 0xc3, 0x68, 0x00, 0x20, 0x01, 0x33, 0x99, 0x42, 0x2e, 0xd8, 0x6f, 0x1c, + 0xfa, 0x7f, 0xee, 0x69, 0xcb, 0x09, 0x10, 0x2a, 0x00, 0xd1, 0x0b, 0x0a, + 0x9e, 0x19, 0x14, 0x4b, 0x1b, 0x68, 0x9e, 0x42, 0x08, 0xd1, 0xfa, 0x7f, + 0x12, 0x4b, 0x10, 0x2a, 0x0b, 0xd1, 0xe4, 0xb2, 0x01, 0x9a, 0x64, 0x00, + 0x1a, 0x53, 0x0b, 0xe0, 0x30, 0x1c, 0x00, 0x21, 0xff, 0xf7, 0x48, 0xff, + 0x00, 0x28, 0xf0, 0xd1, 0x12, 0xe0, 0x7f, 0x22, 0x14, 0x40, 0x01, 0x9a, + 0xa4, 0x00, 0x1a, 0x51, 0x09, 0x4b, 0x01, 0x20, 0x1a, 0x78, 0x02, 0x43, + 0x1a, 0x70, 0x2b, 0x7e, 0x83, 0x42, 0x05, 0xd9, 0xab, 0x68, 0xf6, 0x18, + 0x05, 0x4b, 0x1e, 0x60, 0x00, 0xe0, 0x00, 0x20, 0xfe, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, 0x50, 0x03, 0x00, 0x20, + 0x48, 0x01, 0x00, 0x20, 0xf0, 0xb5, 0x15, 0x68, 0x87, 0xb0, 0x06, 0x1c, + 0x02, 0x91, 0x17, 0x1c, 0x00, 0x2d, 0x03, 0xd0, 0x00, 0x21, 0x01, 0x35, + 0x01, 0x91, 0x06, 0xe0, 0x02, 0x9b, 0x05, 0x68, 0x01, 0x3b, 0x5a, 0x42, + 0x53, 0x41, 0xdb, 0xb2, 0x01, 0x93, 0xf2, 0x68, 0x00, 0x23, 0x01, 0x32, + 0x03, 0x92, 0x2c, 0x1c, 0x00, 0x93, 0x00, 0x99, 0xf2, 0x68, 0x91, 0x42, + 0x21, 0xd2, 0x03, 0x9b, 0x9c, 0x42, 0x01, 0xd9, 0x02, 0x24, 0x25, 0x1c, + 0x30, 0x1c, 0x21, 0x1c, 0x05, 0xaa, 0xff, 0xf7, 0x43, 0xff, 0x00, 0x28, + 0x15, 0xd0, 0x05, 0x99, 0x63, 0x1c, 0x00, 0x29, 0x01, 0xd0, 0x1d, 0x1c, + 0x03, 0xe0, 0x02, 0x99, 0x5a, 0x1b, 0x8a, 0x42, 0x04, 0xd0, 0x00, 0x9a, + 0x1c, 0x1c, 0x01, 0x32, 0x00, 0x92, 0xe0, 0xe7, 0x30, 0x1c, 0x21, 0x1c, + 0x13, 0x4a, 0xff, 0xf7, 0x7f, 0xff, 0x00, 0x28, 0x0b, 0xd1, 0x00, 0x20, + 0x1d, 0xe0, 0x63, 0x1e, 0x30, 0x1c, 0x19, 0x1c, 0x22, 0x1c, 0x00, 0x93, + 0xff, 0xf7, 0x74, 0xff, 0x00, 0x28, 0xf4, 0xd0, 0x00, 0x9c, 0xac, 0x42, + 0xf3, 0xd8, 0x39, 0x68, 0x00, 0x29, 0x06, 0xd1, 0x01, 0x99, 0x3d, 0x60, + 0x00, 0x29, 0x09, 0xd0, 0x01, 0x35, 0x35, 0x60, 0x06, 0xe0, 0x30, 0x1c, + 0x2a, 0x1c, 0xff, 0xf7, 0x61, 0xff, 0x00, 0x28, 0xf2, 0xd1, 0xe0, 0xe7, + 0x01, 0x20, 0x07, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0xff, 0xff, 0xff, 0x0f, + 0x02, 0x23, 0x37, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x03, 0x60, 0x28, 0x1c, + 0x21, 0x1c, 0x01, 0xaa, 0xff, 0xf7, 0xfc, 0xfe, 0x00, 0x28, 0x12, 0xd0, + 0x28, 0x1c, 0x21, 0x1c, 0x00, 0x22, 0xff, 0xf7, 0x47, 0xff, 0x00, 0x28, + 0x0b, 0xd0, 0x6b, 0x1c, 0xdb, 0x7f, 0x01, 0x9c, 0x10, 0x2b, 0x01, 0xd1, + 0x04, 0x4b, 0x00, 0xe0, 0x04, 0x4b, 0x9c, 0x42, 0xe7, 0xd3, 0x01, 0x20, + 0x00, 0xe0, 0x00, 0x20, 0x3e, 0xbd, 0xc0, 0x46, 0xf8, 0xff, 0x00, 0x00, + 0xf8, 0xff, 0xff, 0x0f, 0xf8, 0xb5, 0x44, 0x4b, 0x04, 0x1c, 0x15, 0x1c, + 0x19, 0x60, 0x29, 0xd0, 0x04, 0x2a, 0x01, 0xd9, 0x00, 0x20, 0x7d, 0xe0, + 0x00, 0x20, 0x01, 0x1c, 0xff, 0xf7, 0x90, 0xfe, 0x00, 0x28, 0xf7, 0xd0, + 0x2d, 0x01, 0x3d, 0x4b, 0xa9, 0x35, 0xff, 0x35, 0x5d, 0x19, 0xaa, 0x79, + 0xab, 0x1d, 0x50, 0x06, 0xee, 0xd1, 0xea, 0x7c, 0xa9, 0x7c, 0x12, 0x02, + 0x0a, 0x43, 0x29, 0x7d, 0x09, 0x04, 0x0a, 0x43, 0x69, 0x7d, 0x09, 0x06, + 0x0a, 0x43, 0x63, 0x2a, 0xe2, 0xd9, 0xaa, 0x7b, 0xed, 0x7b, 0x2d, 0x02, + 0x15, 0x43, 0x9a, 0x7a, 0xdb, 0x7a, 0x12, 0x04, 0x15, 0x43, 0x1b, 0x06, + 0x1d, 0x43, 0xd7, 0xd0, 0x28, 0x1c, 0x00, 0x21, 0xff, 0xf7, 0x6a, 0xfe, + 0x00, 0x28, 0xd1, 0xd0, 0x2a, 0x4b, 0x19, 0x7b, 0xda, 0x7a, 0x09, 0x02, + 0x11, 0x43, 0x80, 0x22, 0x92, 0x00, 0x91, 0x42, 0xc8, 0xd1, 0x1a, 0x7c, + 0x00, 0x2a, 0xc5, 0xd0, 0xd9, 0x89, 0x00, 0x29, 0xc2, 0xd0, 0x59, 0x7b, + 0x00, 0x29, 0xbf, 0xd0, 0x22, 0x76, 0x00, 0x22, 0x21, 0x71, 0x22, 0x74, + 0x22, 0x7c, 0x01, 0x20, 0x90, 0x40, 0x81, 0x42, 0x04, 0xd0, 0x50, 0x1c, + 0x20, 0x74, 0x07, 0x2a, 0xf6, 0xd9, 0xb1, 0xe7, 0xd9, 0x8a, 0x00, 0x29, + 0x00, 0xd1, 0x59, 0x6a, 0xa1, 0x60, 0xd8, 0x89, 0x28, 0x18, 0xe0, 0x61, + 0x1f, 0x69, 0x3e, 0x02, 0x36, 0x0c, 0x66, 0x84, 0xb7, 0xb2, 0x1e, 0x7c, + 0x71, 0x43, 0x0e, 0x18, 0x13, 0x48, 0x79, 0x01, 0x09, 0x18, 0x49, 0x12, + 0x71, 0x18, 0x66, 0x62, 0x61, 0x61, 0x18, 0x7d, 0xde, 0x7c, 0x00, 0x02, + 0x30, 0x43, 0x00, 0xd1, 0x18, 0x6a, 0x6d, 0x1a, 0x28, 0x18, 0xd0, 0x40, + 0x02, 0x1c, 0xe0, 0x60, 0x0b, 0x48, 0x61, 0x1c, 0x82, 0x42, 0x01, 0xd8, + 0x0c, 0x23, 0x07, 0xe0, 0x09, 0x48, 0x82, 0x42, 0x01, 0xd8, 0x10, 0x23, + 0x02, 0xe0, 0xdb, 0x6a, 0x63, 0x62, 0x20, 0x23, 0xcb, 0x77, 0x01, 0x20, + 0xf8, 0xbd, 0xc0, 0x46, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0xff, 0x01, 0x00, 0x00, 0xf4, 0x0f, 0x00, 0x00, 0xf4, 0xff, 0x00, 0x00, + 0x08, 0xb5, 0x05, 0x49, 0x05, 0x4a, 0x06, 0x48, 0x00, 0xf0, 0x10, 0xf8, + 0x05, 0x4b, 0x06, 0x49, 0x00, 0x22, 0x1a, 0x70, 0x5a, 0x54, 0x08, 0xbd, + 0x00, 0x50, 0x00, 0x00, 0x01, 0x04, 0x00, 0x00, 0x54, 0x03, 0x00, 0x20, + 0x6c, 0x03, 0x00, 0x20, 0x02, 0x04, 0x00, 0x00, 0x30, 0xb5, 0x09, 0x4c, + 0x09, 0x4b, 0xa5, 0x68, 0x6d, 0x03, 0x6d, 0x0f, 0xad, 0x00, 0xeb, 0x58, + 0x03, 0x60, 0xa4, 0x68, 0x01, 0x61, 0xa4, 0xb2, 0x44, 0x60, 0x5c, 0x43, + 0x9b, 0x00, 0x84, 0x60, 0xc3, 0x60, 0x42, 0x61, 0x30, 0xbd, 0xc0, 0x46, + 0x00, 0x40, 0x00, 0x41, 0x00, 0x55, 0x00, 0x00, 0xf7, 0xb5, 0x1f, 0x4e, + 0x80, 0x27, 0x75, 0x68, 0x03, 0x33, 0x3d, 0x43, 0x9b, 0x08, 0x75, 0x60, + 0x00, 0x2b, 0x34, 0xd0, 0x1b, 0x4d, 0x35, 0x80, 0x35, 0x7d, 0xef, 0x07, + 0xfc, 0xd5, 0x1d, 0x1c, 0x5f, 0x1b, 0x01, 0x97, 0x07, 0x68, 0xbf, 0x08, + 0xbc, 0x46, 0x01, 0x9f, 0x67, 0x45, 0x1f, 0xd2, 0x00, 0x2d, 0x1d, 0xd0, + 0x17, 0x78, 0x01, 0x3d, 0x01, 0x97, 0xff, 0x27, 0xbc, 0x43, 0x01, 0x9f, + 0x3c, 0x43, 0x57, 0x78, 0x3f, 0x02, 0x01, 0x97, 0x0f, 0x4f, 0x3c, 0x40, + 0x01, 0x9f, 0x3c, 0x43, 0x97, 0x78, 0x3f, 0x04, 0xbc, 0x46, 0x0d, 0x4f, + 0x3c, 0x40, 0xd7, 0x78, 0xa4, 0xb2, 0x3f, 0x06, 0x00, 0x97, 0x67, 0x46, + 0x3c, 0x43, 0x00, 0x9f, 0x04, 0x32, 0x3c, 0x43, 0x10, 0xc1, 0xd7, 0xe7, + 0x07, 0x4b, 0x33, 0x80, 0x33, 0x7d, 0xdf, 0x07, 0xfc, 0xd5, 0x2b, 0x1c, + 0xc8, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x44, 0xa5, 0xff, 0xff, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, 0x04, 0xa5, 0xff, 0xff, + 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, 0x1a, 0x80, 0x1a, 0x7d, + 0xd1, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x16, 0x1c, + 0xeb, 0x68, 0x28, 0x1c, 0x21, 0x1c, 0x9e, 0x42, 0x05, 0xd9, 0xff, 0xf7, + 0xe7, 0xff, 0xeb, 0x68, 0xe4, 0x18, 0xf6, 0x1a, 0xf4, 0xe7, 0xff, 0xf7, + 0xe1, 0xff, 0x70, 0xbd, 0x43, 0x7a, 0x00, 0x2b, 0x04, 0xd1, 0x83, 0x72, + 0xc3, 0x72, 0xc3, 0x60, 0x01, 0x23, 0x43, 0x72, 0x70, 0x47, 0x30, 0xb5, + 0x85, 0xb0, 0x04, 0x1c, 0x02, 0xad, 0x00, 0x68, 0x02, 0x91, 0x03, 0x92, + 0x00, 0xf0, 0x88, 0xfc, 0x6b, 0x79, 0xe1, 0x79, 0x22, 0x7a, 0x00, 0x93, + 0x20, 0x68, 0x00, 0x23, 0x00, 0xf0, 0x22, 0xfd, 0x29, 0x79, 0x20, 0x68, + 0x02, 0x9a, 0x00, 0xf0, 0x4b, 0xfc, 0x20, 0x68, 0x00, 0xf0, 0x6e, 0xfc, + 0x05, 0xb0, 0x30, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0x18, 0x26, 0xff, 0xf7, + 0xd7, 0xff, 0x20, 0x79, 0x33, 0x1c, 0x43, 0x43, 0x0d, 0x4d, 0x08, 0x21, + 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x08, 0xfb, 0xa0, 0x79, 0x33, 0x1c, + 0x43, 0x43, 0x08, 0x21, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x00, 0xfb, + 0x60, 0x79, 0x08, 0x21, 0x46, 0x43, 0xad, 0x19, 0x69, 0x56, 0x00, 0xf0, + 0xf9, 0xfa, 0x04, 0x4b, 0x20, 0x1c, 0x06, 0xcb, 0xff, 0xf7, 0xc3, 0xff, + 0x70, 0xbd, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, 0x70, 0x07, 0x00, 0x20, + 0x07, 0xb5, 0x83, 0x7a, 0x00, 0x91, 0x01, 0x92, 0x00, 0x2b, 0x0d, 0xd0, + 0x9a, 0x07, 0x06, 0xd5, 0xef, 0xf3, 0x10, 0x83, 0x5a, 0x42, 0x53, 0x41, + 0xc3, 0x72, 0x72, 0xb6, 0x04, 0xe0, 0xda, 0x07, 0x02, 0xd5, 0x82, 0x89, + 0x03, 0x4b, 0x9a, 0x60, 0x00, 0x99, 0x01, 0x9a, 0xff, 0xf7, 0xa5, 0xff, + 0x07, 0xbd, 0xc0, 0x46, 0x00, 0x18, 0x00, 0x40, 0x83, 0x7a, 0x00, 0x2b, + 0x0b, 0xd0, 0x9a, 0x07, 0x04, 0xd5, 0xc3, 0x7a, 0x00, 0x2b, 0x06, 0xd0, + 0x62, 0xb6, 0x04, 0xe0, 0xda, 0x07, 0x02, 0xd5, 0x82, 0x89, 0x01, 0x4b, + 0xda, 0x60, 0x70, 0x47, 0x00, 0x18, 0x00, 0x40, 0x08, 0xb5, 0x00, 0x68, + 0x00, 0xf0, 0x25, 0xfc, 0x08, 0xbd, 0x00, 0x00, 0x0f, 0x4b, 0x10, 0x4a, + 0x10, 0x49, 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x0f, 0x4b, + 0x0f, 0x48, 0x19, 0x60, 0x0a, 0x21, 0x19, 0x71, 0x09, 0x21, 0x99, 0x71, + 0x08, 0x21, 0x59, 0x71, 0x03, 0x21, 0x5a, 0x72, 0xda, 0x71, 0x19, 0x72, + 0x0a, 0x4b, 0x18, 0x60, 0x1d, 0x20, 0x18, 0x71, 0x1b, 0x20, 0x98, 0x71, + 0x1a, 0x20, 0x5a, 0x72, 0x58, 0x71, 0xda, 0x71, 0x19, 0x72, 0x70, 0x47, + 0x70, 0x07, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, 0x5c, 0x08, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x60, 0x08, 0x00, 0x20, 0x88, 0x07, 0x00, 0x20, + 0x08, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x66, 0xfd, 0x08, 0xbd, 0xc0, 0x46, + 0x98, 0x07, 0x00, 0x20, 0x13, 0xb5, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, + 0x31, 0xfb, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, 0x2d, 0xfb, 0x12, 0x49, + 0x12, 0x48, 0x00, 0xf0, 0x29, 0xfb, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, + 0x25, 0xfb, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, 0x21, 0xfb, 0x12, 0x4c, + 0x12, 0x49, 0x20, 0x1c, 0x00, 0xf0, 0x1c, 0xfb, 0x03, 0x23, 0x00, 0x93, + 0x01, 0x23, 0x01, 0x93, 0x21, 0x1c, 0x0d, 0x22, 0x0e, 0x23, 0x0e, 0x48, + 0x00, 0xf0, 0x2c, 0xfd, 0x13, 0xbd, 0xc0, 0x46, 0x00, 0x08, 0x00, 0x42, + 0x58, 0x08, 0x00, 0x20, 0x00, 0x0c, 0x00, 0x42, 0x5c, 0x08, 0x00, 0x20, + 0x00, 0x10, 0x00, 0x42, 0x60, 0x08, 0x00, 0x20, 0x00, 0x14, 0x00, 0x42, + 0x54, 0x08, 0x00, 0x20, 0x00, 0x18, 0x00, 0x42, 0x64, 0x08, 0x00, 0x20, + 0x68, 0x08, 0x00, 0x20, 0x00, 0x1c, 0x00, 0x42, 0x98, 0x07, 0x00, 0x20, + 0xfe, 0xe7, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x4b, 0x1b, 0x68, 0x00, 0x2b, + 0x00, 0xd0, 0x98, 0x47, 0x08, 0xbd, 0xc0, 0x46, 0x6c, 0x08, 0x00, 0x20, + 0x38, 0xb5, 0x0f, 0x49, 0x0f, 0x4c, 0xa1, 0x42, 0x04, 0xd1, 0x00, 0xf0, + 0x4f, 0xf8, 0xfe, 0xf7, 0xbf, 0xfa, 0x0b, 0xe0, 0x0c, 0x4d, 0x8d, 0x42, + 0xf7, 0xd0, 0x00, 0x23, 0xca, 0x18, 0xe8, 0x18, 0xa2, 0x42, 0x04, 0xd2, + 0x00, 0x68, 0x04, 0x33, 0x10, 0x60, 0xf7, 0xe7, 0xfe, 0xe7, 0x90, 0x42, + 0xeb, 0xd0, 0x06, 0x4b, 0x06, 0x4a, 0x93, 0x42, 0xe7, 0xd2, 0x00, 0x22, + 0x04, 0xc3, 0xf9, 0xe7, 0x00, 0x00, 0x00, 0x20, 0xa0, 0x00, 0x00, 0x20, + 0x48, 0x59, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x20, 0x50, 0x0d, 0x00, 0x20, + 0x08, 0xb5, 0x00, 0xf0, 0x26, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x00, 0xf0, + 0x17, 0xf8, 0x08, 0xbd, 0x01, 0x4b, 0x18, 0x68, 0x70, 0x47, 0xc0, 0x46, + 0x70, 0x08, 0x00, 0x20, 0x70, 0xb5, 0x04, 0x1e, 0x08, 0xd0, 0x05, 0x4b, + 0x1d, 0x68, 0x1e, 0x1c, 0x00, 0xf0, 0x12, 0xf8, 0x33, 0x68, 0x5b, 0x1b, + 0xa3, 0x42, 0xf9, 0xd3, 0x70, 0xbd, 0xc0, 0x46, 0x70, 0x08, 0x00, 0x20, + 0x08, 0xb5, 0x03, 0x4b, 0x1a, 0x68, 0x01, 0x32, 0x1a, 0x60, 0x00, 0xf0, + 0x61, 0xfa, 0x08, 0xbd, 0x70, 0x08, 0x00, 0x20, 0x70, 0x47, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x00, 0x70, 0xb5, 0x49, 0x4a, 0x1e, 0x21, 0x53, 0x68, + 0x02, 0x20, 0x8b, 0x43, 0x03, 0x43, 0x47, 0x49, 0x53, 0x60, 0x8b, 0x69, + 0x08, 0x24, 0x23, 0x43, 0x8b, 0x61, 0x45, 0x4c, 0x45, 0x4b, 0x9c, 0x82, + 0x9c, 0x8a, 0x20, 0x43, 0x98, 0x82, 0x10, 0x1c, 0xda, 0x68, 0x94, 0x07, + 0xfc, 0xd5, 0x42, 0x4a, 0x01, 0x24, 0x14, 0x70, 0x14, 0x78, 0xe5, 0x07, + 0x04, 0xd5, 0x3f, 0x4c, 0x64, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xf7, 0xdb, + 0x01, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, + 0x3a, 0x4d, 0x39, 0x4c, 0x65, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x82, 0x25, 0x35, 0x4c, 0xed, 0x01, 0x65, 0x80, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x02, 0x24, 0x9c, 0x84, 0xdc, 0x68, + 0xe6, 0x06, 0xfc, 0xd5, 0x31, 0x4d, 0x2e, 0x4c, 0xe5, 0x62, 0xdd, 0x68, + 0x2c, 0x4c, 0xee, 0x06, 0xfb, 0xd5, 0xa5, 0x8c, 0x2e, 0x4e, 0x35, 0x43, + 0xa5, 0x84, 0xdd, 0x68, 0x28, 0x4c, 0xee, 0x06, 0xfb, 0xd5, 0xa5, 0x8c, + 0x02, 0x26, 0x35, 0x43, 0xa5, 0x84, 0xdc, 0x68, 0x25, 0x06, 0xfc, 0xd5, + 0x23, 0x4c, 0xe4, 0x68, 0x66, 0x06, 0xf8, 0xd5, 0xdc, 0x68, 0xe5, 0x06, + 0xfc, 0xd5, 0x00, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x22, 0x4d, 0x1d, 0x4c, 0x65, 0x60, 0x55, 0x78, 0x1c, 0x4c, + 0x6d, 0xb2, 0x00, 0x2d, 0xfa, 0xdb, 0x1e, 0x6a, 0x1e, 0x4d, 0x35, 0x40, + 0x1d, 0x62, 0x1d, 0x6a, 0x80, 0x26, 0xb5, 0x43, 0x1d, 0x62, 0x03, 0x23, + 0xa3, 0x60, 0x1b, 0x4b, 0x63, 0x60, 0x53, 0x78, 0x5b, 0xb2, 0x00, 0x2b, + 0xfb, 0xdb, 0x00, 0x23, 0x0b, 0x72, 0x18, 0x4a, 0x4b, 0x72, 0x8b, 0x72, + 0xcb, 0x72, 0x17, 0x4b, 0xff, 0x21, 0x1a, 0x60, 0x16, 0x4b, 0x17, 0x4a, + 0x1b, 0x68, 0x12, 0x68, 0x5c, 0x01, 0xd2, 0x0e, 0x21, 0x40, 0x11, 0x43, + 0x9a, 0x06, 0x52, 0x0f, 0x12, 0x02, 0x0b, 0x1c, 0x13, 0x43, 0x12, 0x4a, + 0x13, 0x85, 0x43, 0x68, 0x80, 0x22, 0x13, 0x43, 0x43, 0x60, 0x70, 0xbd, + 0x00, 0x40, 0x00, 0x41, 0x00, 0x04, 0x00, 0x40, 0x0c, 0x06, 0x00, 0x00, + 0x00, 0x08, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, 0x01, 0x05, 0x01, 0x00, + 0xb9, 0x05, 0xff, 0x7d, 0x04, 0x0a, 0x00, 0x00, 0x00, 0x07, 0x03, 0x00, + 0xff, 0xfc, 0xff, 0xff, 0x03, 0x06, 0x01, 0x00, 0x00, 0x6c, 0xdc, 0x02, + 0x04, 0x00, 0x00, 0x20, 0x24, 0x60, 0x80, 0x00, 0x20, 0x60, 0x80, 0x00, + 0x00, 0x40, 0x00, 0x42, 0x31, 0x4b, 0xfa, 0x21, 0x18, 0x68, 0x10, 0xb5, + 0x89, 0x00, 0x00, 0xf0, 0xe3, 0xfe, 0x2f, 0x4b, 0x01, 0x38, 0x98, 0x42, + 0x24, 0xd8, 0x2e, 0x4a, 0x2e, 0x4b, 0x50, 0x60, 0x18, 0x6a, 0xc0, 0x21, + 0x00, 0x02, 0x00, 0x0a, 0x09, 0x06, 0x01, 0x43, 0x19, 0x62, 0x00, 0x24, + 0x07, 0x21, 0x94, 0x60, 0x11, 0x60, 0x19, 0x6a, 0x80, 0x22, 0x09, 0x02, + 0x09, 0x0a, 0x12, 0x06, 0x0a, 0x43, 0x1a, 0x62, 0x25, 0x4b, 0xfc, 0x21, + 0x1a, 0x6a, 0x0a, 0x43, 0x1a, 0x62, 0x19, 0x6a, 0xfc, 0x22, 0x92, 0x01, + 0x0a, 0x43, 0x1a, 0x62, 0x19, 0x6a, 0xa0, 0x22, 0xd2, 0x02, 0x0a, 0x43, + 0x1a, 0x62, 0x00, 0xe0, 0xfe, 0xe7, 0x20, 0x1c, 0x00, 0x21, 0x01, 0x34, + 0x00, 0xf0, 0x70, 0xf8, 0x16, 0x2c, 0xf8, 0xd1, 0x1a, 0x4c, 0x63, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfa, 0xdb, 0x19, 0x4b, 0x63, 0x80, 0x19, 0x4b, + 0x5a, 0x7e, 0xd2, 0x09, 0x01, 0x2a, 0xfa, 0xd0, 0xe4, 0x22, 0xd2, 0x00, + 0x9a, 0x80, 0x3f, 0x22, 0xda, 0x70, 0x59, 0x7e, 0x13, 0x4a, 0xc9, 0x09, + 0x01, 0x29, 0xfa, 0xd0, 0xc0, 0x23, 0x5b, 0x01, 0x00, 0x20, 0x13, 0x61, + 0x90, 0x70, 0x00, 0xf0, 0x23, 0xf8, 0x63, 0x78, 0x5b, 0xb2, 0x00, 0x2b, + 0xfb, 0xdb, 0x0d, 0x4a, 0x09, 0x4b, 0x5a, 0x80, 0x0c, 0x4b, 0xda, 0x79, + 0xd2, 0x09, 0x01, 0x2a, 0xfa, 0xd0, 0x41, 0x22, 0x5a, 0x70, 0x10, 0xbd, + 0x04, 0x00, 0x00, 0x20, 0xff, 0xff, 0xff, 0x00, 0x10, 0xe0, 0x00, 0xe0, + 0x00, 0xed, 0x00, 0xe0, 0x00, 0x04, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, + 0x1e, 0x40, 0x00, 0x00, 0x00, 0x40, 0x00, 0x42, 0x21, 0x40, 0x00, 0x00, + 0x00, 0x48, 0x00, 0x42, 0x00, 0xb5, 0x14, 0x4a, 0x51, 0x7e, 0x13, 0x1c, + 0xc9, 0x09, 0x01, 0x29, 0xf9, 0xd0, 0x01, 0x38, 0x04, 0x28, 0x13, 0xd8, + 0x19, 0x69, 0x10, 0x4a, 0x0a, 0x40, 0x1a, 0x61, 0x5a, 0x78, 0x0f, 0x21, + 0x8a, 0x43, 0x00, 0xf0, 0x55, 0xfe, 0x03, 0x05, 0x09, 0x07, 0x03, 0x00, + 0x01, 0x21, 0x02, 0xe0, 0x03, 0x21, 0x00, 0xe0, 0x02, 0x21, 0x0a, 0x43, + 0x5a, 0x70, 0x0a, 0xe0, 0x11, 0x69, 0xf0, 0x23, 0x1b, 0x05, 0x0b, 0x43, + 0x13, 0x61, 0x53, 0x78, 0x0f, 0x21, 0x8b, 0x43, 0x02, 0x21, 0x0b, 0x43, + 0x53, 0x70, 0x00, 0xbd, 0x00, 0x40, 0x00, 0x42, 0xff, 0xff, 0xff, 0xf0, + 0x10, 0xb5, 0x18, 0x24, 0x02, 0x1c, 0x20, 0x1c, 0x50, 0x43, 0x27, 0x4b, + 0x18, 0x18, 0x00, 0x7a, 0x40, 0xb2, 0x01, 0x30, 0x46, 0xd0, 0x03, 0x29, + 0x44, 0xd8, 0x08, 0x1c, 0x21, 0x1c, 0x00, 0xf0, 0x29, 0xfe, 0x02, 0x33, + 0x11, 0x21, 0x62, 0x43, 0x98, 0x56, 0x9a, 0x18, 0xc3, 0x01, 0x1f, 0x48, + 0x52, 0x68, 0x1b, 0x18, 0x99, 0x18, 0x40, 0x31, 0x02, 0x20, 0x08, 0x70, + 0x01, 0x21, 0x91, 0x40, 0x59, 0x60, 0x2f, 0xe0, 0x62, 0x43, 0x98, 0x56, + 0x18, 0x49, 0x9a, 0x18, 0x52, 0x68, 0xc3, 0x01, 0x5b, 0x18, 0x99, 0x18, + 0x40, 0x31, 0x06, 0x20, 0x08, 0x70, 0x01, 0x21, 0x91, 0x40, 0x59, 0x60, + 0x99, 0x61, 0x1f, 0xe0, 0x51, 0x43, 0x5a, 0x56, 0x10, 0x48, 0x59, 0x18, + 0x4b, 0x68, 0xd2, 0x01, 0x11, 0x18, 0xc8, 0x18, 0x40, 0x30, 0x06, 0x24, + 0x04, 0x70, 0x01, 0x20, 0x98, 0x40, 0x48, 0x60, 0x0b, 0x49, 0x52, 0x18, + 0x50, 0x60, 0x0d, 0xe0, 0x62, 0x43, 0x98, 0x56, 0x9a, 0x18, 0xc3, 0x01, + 0x06, 0x48, 0x52, 0x68, 0x1b, 0x18, 0x99, 0x18, 0x40, 0x31, 0x02, 0x20, + 0x08, 0x70, 0x01, 0x21, 0x91, 0x40, 0x99, 0x60, 0x10, 0xbd, 0xc0, 0x46, + 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0x10, 0x44, 0x00, 0x41, + 0x18, 0x23, 0x58, 0x43, 0x13, 0x4a, 0xf0, 0xb5, 0x13, 0x18, 0x08, 0x24, + 0x1c, 0x57, 0x01, 0x34, 0x1f, 0xd0, 0x82, 0x56, 0x10, 0x4e, 0xd2, 0x01, + 0x5d, 0x68, 0x01, 0x24, 0x90, 0x19, 0x23, 0x1c, 0x86, 0x68, 0xab, 0x40, + 0x1e, 0x42, 0x0b, 0xd1, 0x0e, 0x1c, 0x77, 0x1e, 0xbe, 0x41, 0x40, 0x19, + 0x34, 0x40, 0x40, 0x30, 0xa5, 0x00, 0x04, 0x78, 0x04, 0x26, 0xb4, 0x43, + 0x2c, 0x43, 0x04, 0x70, 0x00, 0x29, 0x03, 0xd1, 0x05, 0x49, 0x52, 0x18, + 0x53, 0x60, 0x02, 0xe0, 0x02, 0x4e, 0x92, 0x19, 0x93, 0x61, 0xf0, 0xbd, + 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0x10, 0x44, 0x00, 0x41, + 0x18, 0x22, 0x42, 0x43, 0xf8, 0xb5, 0x2d, 0x4d, 0x08, 0x24, 0xaa, 0x18, + 0x14, 0x57, 0x03, 0x1c, 0x62, 0x1c, 0x50, 0xd0, 0x48, 0x1c, 0x00, 0x24, + 0x0c, 0x28, 0x4c, 0xd8, 0x00, 0xf0, 0xa0, 0xfd, 0x07, 0x1e, 0x1e, 0x1e, + 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x0a, 0x0a, 0x0a, 0x0a, 0x00, 0x01, 0x24, + 0x64, 0x42, 0x40, 0xe0, 0x09, 0x29, 0x02, 0xd1, 0x18, 0x1c, 0x00, 0x21, + 0x03, 0xe0, 0x0a, 0x29, 0x04, 0xd1, 0x18, 0x1c, 0x02, 0x21, 0xff, 0xf7, + 0x51, 0xff, 0x23, 0xe0, 0x00, 0x24, 0x0b, 0x29, 0x31, 0xd1, 0x18, 0x1c, + 0x01, 0x21, 0xff, 0xf7, 0x49, 0xff, 0x2c, 0xe0, 0x18, 0x22, 0x53, 0x43, + 0xea, 0x18, 0x52, 0x68, 0xeb, 0x56, 0x01, 0x20, 0x14, 0x1c, 0x04, 0x40, + 0x55, 0x08, 0xdb, 0x01, 0x00, 0x2c, 0x11, 0xd0, 0x12, 0x4c, 0x1b, 0x19, + 0x5d, 0x19, 0x30, 0x35, 0x2e, 0x78, 0x0c, 0x01, 0x0f, 0x21, 0x31, 0x40, + 0x21, 0x43, 0x9a, 0x18, 0xc9, 0xb2, 0x29, 0x70, 0x40, 0x32, 0x13, 0x78, + 0x18, 0x43, 0x10, 0x70, 0x00, 0x24, 0x0e, 0xe0, 0x09, 0x4e, 0x0f, 0x27, + 0x9b, 0x19, 0x5d, 0x19, 0x30, 0x35, 0x2e, 0x78, 0x9a, 0x18, 0xbe, 0x43, + 0x31, 0x43, 0xc9, 0xb2, 0x29, 0x70, 0x40, 0x32, 0x13, 0x78, 0x18, 0x43, + 0x10, 0x70, 0x20, 0x1c, 0xf8, 0xbd, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, + 0x00, 0x44, 0x00, 0x41, 0xf7, 0xb5, 0x8a, 0x18, 0x06, 0x1c, 0x0d, 0x1c, + 0x01, 0x92, 0x0c, 0x1c, 0x01, 0x9b, 0x67, 0x1b, 0x9c, 0x42, 0x07, 0xd0, + 0x33, 0x68, 0x21, 0x78, 0x1b, 0x68, 0x30, 0x1c, 0x98, 0x47, 0x01, 0x34, + 0x00, 0x28, 0xf3, 0xd1, 0x38, 0x1c, 0xfe, 0xbd, 0x15, 0x4a, 0x13, 0x68, + 0x58, 0x1c, 0x25, 0xd0, 0x01, 0x3b, 0x13, 0x60, 0x00, 0x2b, 0x21, 0xd1, + 0x72, 0xb6, 0x12, 0x4a, 0x12, 0x4b, 0x04, 0x32, 0x9a, 0x42, 0x07, 0xd8, + 0xbf, 0xf3, 0x4f, 0x8f, 0x10, 0x4a, 0x11, 0x4b, 0xda, 0x60, 0xbf, 0xf3, + 0x4f, 0x8f, 0x11, 0xe0, 0x0f, 0x4b, 0x19, 0x7d, 0xc8, 0x07, 0xfb, 0xd5, + 0x18, 0x8b, 0x20, 0x21, 0xff, 0x31, 0x92, 0x08, 0x52, 0x00, 0x01, 0x43, + 0x19, 0x83, 0xda, 0x61, 0x0a, 0x4a, 0x1a, 0x80, 0x1a, 0x7d, 0xd1, 0x07, + 0xfc, 0xd5, 0xe5, 0xe7, 0xc0, 0x46, 0xfd, 0xe7, 0x70, 0x47, 0xc0, 0x46, + 0x08, 0x00, 0x00, 0x20, 0x00, 0x20, 0x00, 0x00, 0x03, 0x02, 0x00, 0x00, + 0x04, 0x00, 0xfa, 0x05, 0x00, 0xed, 0x00, 0xe0, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x01, 0x60, 0x70, 0x47, 0xf7, 0xb5, 0x08, 0xac, + 0x26, 0x78, 0x04, 0x68, 0x9d, 0x1e, 0x27, 0x68, 0x6c, 0x1e, 0xa5, 0x41, + 0xec, 0xb2, 0x92, 0x07, 0x05, 0x68, 0x3a, 0x43, 0x27, 0x06, 0x3a, 0x43, + 0x2a, 0x60, 0x02, 0x68, 0x07, 0x25, 0x29, 0x40, 0x50, 0x68, 0xb5, 0x01, + 0x00, 0x2c, 0x00, 0xd0, 0x5c, 0x03, 0x29, 0x43, 0x01, 0x43, 0x0c, 0x43, + 0x54, 0x60, 0xf7, 0xbd, 0x30, 0xb5, 0x03, 0x68, 0xc0, 0x25, 0x1c, 0x68, + 0xad, 0x03, 0x12, 0x05, 0x2a, 0x40, 0x22, 0x43, 0xc0, 0x24, 0xa4, 0x02, + 0x09, 0x04, 0x21, 0x40, 0x11, 0x43, 0x19, 0x60, 0x03, 0x68, 0x5a, 0x68, + 0x14, 0x43, 0x5c, 0x60, 0x30, 0xbd, 0x03, 0x68, 0x01, 0x21, 0x1a, 0x68, + 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, 0x11, 0x68, 0x01, 0x23, 0x19, 0x42, + 0xfb, 0xd1, 0xd1, 0x69, 0x19, 0x42, 0xf8, 0xd1, 0x70, 0x47, 0x03, 0x68, + 0x02, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, 0xd3, 0x69, + 0x99, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd1, 0x07, + 0x02, 0xd4, 0x1a, 0x7e, 0x91, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0x03, 0x68, + 0x00, 0x22, 0x5a, 0x83, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x40, 0x07, + 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x09, 0x70, 0x47, + 0x03, 0x68, 0x80, 0x22, 0x19, 0x7e, 0x52, 0x42, 0x0a, 0x43, 0x1a, 0x76, + 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x01, 0x23, 0x18, 0x40, 0x70, 0x47, + 0x03, 0x68, 0x18, 0x8d, 0xc0, 0xb2, 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, + 0x01, 0x20, 0x02, 0x42, 0xfb, 0xd0, 0x19, 0x85, 0x70, 0x47, 0x03, 0x68, + 0x01, 0x21, 0x9a, 0x7d, 0x0a, 0x43, 0x9a, 0x75, 0x70, 0x47, 0x03, 0x68, + 0x01, 0x22, 0x1a, 0x75, 0x70, 0x47, 0x00, 0x00, 0x70, 0xb5, 0x03, 0x68, + 0x01, 0x26, 0x8d, 0x07, 0xed, 0x0f, 0x31, 0x40, 0x1c, 0x68, 0x6d, 0x07, + 0x09, 0x07, 0x29, 0x43, 0x21, 0x43, 0x19, 0x60, 0x04, 0x68, 0x51, 0x00, + 0x03, 0x48, 0x00, 0xf0, 0x79, 0xfc, 0x01, 0x38, 0xc0, 0xb2, 0x20, 0x73, + 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x6c, 0xdc, 0x02, 0x03, 0x68, 0x01, 0x21, + 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, 0x11, 0x68, 0x01, 0x23, + 0x19, 0x42, 0xfb, 0xd1, 0xd1, 0x69, 0x19, 0x42, 0xf8, 0xd1, 0x70, 0x47, + 0x03, 0x68, 0x02, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, + 0xd3, 0x69, 0x99, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, 0xda, 0x69, + 0x91, 0x07, 0xfc, 0xd4, 0x1a, 0x68, 0x02, 0x21, 0x8a, 0x43, 0x1a, 0x60, + 0x70, 0x47, 0x03, 0x68, 0x9a, 0x6a, 0x52, 0x0a, 0x52, 0x02, 0x11, 0x43, + 0x99, 0x62, 0x03, 0x68, 0x1a, 0x7e, 0x51, 0x07, 0xfc, 0xd5, 0x98, 0x6a, + 0xc0, 0xb2, 0x70, 0x47, 0x03, 0x68, 0x22, 0x4a, 0x30, 0xb5, 0x93, 0x42, + 0x11, 0xd0, 0x21, 0x4a, 0x93, 0x42, 0x11, 0xd0, 0x20, 0x4a, 0x93, 0x42, + 0x11, 0xd0, 0x20, 0x4a, 0x93, 0x42, 0x11, 0xd0, 0x1f, 0x4a, 0x93, 0x42, + 0x11, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x30, 0xd1, 0x0e, 0x23, 0x19, 0x22, + 0x0d, 0xe0, 0x09, 0x23, 0x14, 0x22, 0x0a, 0xe0, 0x0a, 0x23, 0x15, 0x22, + 0x07, 0xe0, 0x0b, 0x23, 0x16, 0x22, 0x04, 0xe0, 0x0c, 0x23, 0x17, 0x22, + 0x01, 0xe0, 0x0d, 0x23, 0x18, 0x22, 0xdc, 0xb2, 0x15, 0x49, 0x01, 0x20, + 0x9b, 0x08, 0xa0, 0x40, 0x9b, 0x00, 0x08, 0x60, 0x5b, 0x18, 0x03, 0x20, + 0xc0, 0x21, 0x89, 0x00, 0x04, 0x40, 0x5d, 0x58, 0xe0, 0x00, 0xff, 0x24, + 0x84, 0x40, 0xa5, 0x43, 0x2c, 0x1c, 0xc0, 0x25, 0x85, 0x40, 0x28, 0x1c, + 0x20, 0x43, 0x58, 0x50, 0x80, 0x23, 0xdb, 0x01, 0x1a, 0x43, 0x0a, 0x4b, + 0x5a, 0x80, 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, 0x30, 0xbd, + 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, 0x00, 0x10, 0x00, 0x42, + 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, 0x00, 0x1c, 0x00, 0x42, + 0x00, 0xe1, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x40, 0xf8, 0xb5, 0x04, 0x1c, + 0x15, 0x1c, 0x0e, 0x1c, 0x1f, 0x1c, 0xff, 0xf7, 0xa3, 0xff, 0x20, 0x1c, + 0xff, 0xf7, 0x0b, 0xff, 0xb1, 0x00, 0x1c, 0x22, 0x0a, 0x40, 0x69, 0x07, + 0x23, 0x68, 0x09, 0x0c, 0x0a, 0x43, 0x1a, 0x60, 0x22, 0x68, 0x84, 0x23, + 0x93, 0x75, 0x01, 0x2e, 0x1a, 0xd1, 0x08, 0x21, 0x01, 0x2d, 0x00, 0xd1, + 0x10, 0x21, 0x0c, 0x4b, 0x79, 0x43, 0x18, 0x68, 0xc0, 0x00, 0x00, 0xf0, + 0xcd, 0xfb, 0x23, 0x68, 0x07, 0x21, 0x9a, 0x89, 0x01, 0x40, 0xd2, 0x04, + 0x49, 0x03, 0xd2, 0x0c, 0x0a, 0x43, 0x9a, 0x81, 0x23, 0x68, 0x00, 0x04, + 0xc2, 0x0c, 0x98, 0x89, 0x40, 0x0b, 0x40, 0x03, 0x10, 0x43, 0x98, 0x81, + 0xf8, 0xbd, 0xc0, 0x46, 0x04, 0x00, 0x00, 0x20, 0xf7, 0xb5, 0x01, 0x93, + 0x08, 0xab, 0x04, 0x1c, 0x1f, 0x78, 0x0d, 0x1c, 0x16, 0x1c, 0xff, 0xf7, + 0x3d, 0xff, 0x20, 0x1c, 0xff, 0xf7, 0x68, 0xff, 0xbf, 0x07, 0x0c, 0x22, + 0x17, 0x43, 0xc0, 0x22, 0x92, 0x03, 0x36, 0x05, 0x16, 0x40, 0xc0, 0x22, + 0x92, 0x02, 0x2d, 0x04, 0x23, 0x68, 0x3e, 0x43, 0x01, 0x99, 0x15, 0x40, + 0x35, 0x43, 0x07, 0x22, 0x1d, 0x60, 0x0a, 0x40, 0x80, 0x21, 0x23, 0x68, + 0x89, 0x02, 0x0a, 0x43, 0x5a, 0x60, 0xf7, 0xbd, 0x01, 0x20, 0x70, 0x47, + 0x08, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, 0x98, 0x47, 0x08, 0xbd, + 0x13, 0x04, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, 0x00, 0x69, 0xff, 0xf7, + 0xac, 0xfe, 0x20, 0x1c, 0x14, 0x30, 0x00, 0xf0, 0x41, 0xfb, 0x20, 0x1c, + 0x5c, 0x30, 0x00, 0xf0, 0x3d, 0xfb, 0x10, 0xbd, 0x08, 0xb5, 0x14, 0x30, + 0x00, 0xf0, 0x4a, 0xfb, 0x08, 0xbd, 0x10, 0xb5, 0x04, 0x1c, 0x20, 0x1c, + 0x5c, 0x30, 0x00, 0xf0, 0x43, 0xfb, 0x00, 0x28, 0xf9, 0xd1, 0x20, 0x69, + 0xff, 0xf7, 0xab, 0xfe, 0x10, 0xbd, 0x08, 0xb5, 0x5c, 0x30, 0x00, 0xf0, + 0x3f, 0xfb, 0x08, 0xbd, 0x70, 0xb5, 0x05, 0x1c, 0x14, 0x35, 0x04, 0x1c, + 0x28, 0x1c, 0x00, 0xf0, 0x23, 0xfb, 0x23, 0x1c, 0xa8, 0x33, 0x1b, 0x78, + 0x06, 0x1c, 0xff, 0x2b, 0x0a, 0xd0, 0x28, 0x1c, 0x00, 0xf0, 0x2e, 0xfb, + 0x0a, 0x28, 0x05, 0xdd, 0x23, 0x1c, 0xb0, 0x33, 0xb4, 0x34, 0x1b, 0x68, + 0x22, 0x68, 0x1a, 0x60, 0x30, 0x1c, 0x70, 0xbd, 0x08, 0xb5, 0x14, 0x30, + 0x00, 0xf0, 0x2a, 0xfb, 0x08, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0x00, 0x69, + 0x0e, 0x1c, 0xff, 0xf7, 0x9c, 0xfe, 0x25, 0x1c, 0x5c, 0x35, 0x00, 0x28, + 0x04, 0xd0, 0x28, 0x1c, 0x00, 0xf0, 0x0c, 0xfb, 0x00, 0x28, 0x0c, 0xd0, + 0x28, 0x1c, 0x00, 0xf0, 0x20, 0xfb, 0x00, 0x28, 0xfa, 0xd1, 0x28, 0x1c, + 0x31, 0x1c, 0x00, 0xf0, 0xe4, 0xfa, 0x20, 0x69, 0xff, 0xf7, 0x97, 0xfe, + 0x03, 0xe0, 0x20, 0x69, 0x31, 0x1c, 0xff, 0xf7, 0x8b, 0xfe, 0x01, 0x20, + 0x70, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x85, 0xb0, 0x1d, 0x1c, 0x0a, 0xab, + 0x1b, 0x78, 0x04, 0x1c, 0x00, 0x93, 0x0b, 0xab, 0x1b, 0x78, 0x16, 0x1c, + 0x01, 0x93, 0x0c, 0xab, 0x1b, 0x78, 0x0f, 0x1c, 0x02, 0x93, 0x0d, 0xab, + 0x1b, 0x78, 0x03, 0x93, 0x00, 0x23, 0x43, 0x60, 0xfa, 0x23, 0x9b, 0x00, + 0x83, 0x60, 0x0d, 0x4b, 0x08, 0x33, 0x03, 0x60, 0x14, 0x30, 0x00, 0xf0, + 0xb1, 0xfa, 0x20, 0x1c, 0x5c, 0x30, 0x00, 0xf0, 0xad, 0xfa, 0x00, 0x9a, + 0x23, 0x1c, 0xa4, 0x33, 0x27, 0x61, 0x9a, 0x70, 0x01, 0x9a, 0x20, 0x1c, + 0xda, 0x70, 0x02, 0x9a, 0x1e, 0x70, 0x1a, 0x71, 0x03, 0x9a, 0x5d, 0x70, + 0x1a, 0x75, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0x80, 0x58, 0x00, 0x00, + 0x30, 0xb5, 0x85, 0xb0, 0x04, 0x1c, 0x08, 0xa8, 0x05, 0x78, 0x09, 0xa8, + 0x00, 0x78, 0x00, 0x95, 0x01, 0x90, 0xff, 0x20, 0x02, 0x90, 0x03, 0x90, + 0x20, 0x1c, 0xff, 0xf7, 0xbd, 0xff, 0x20, 0x1c, 0x05, 0xb0, 0x30, 0xbd, + 0x38, 0xb5, 0x04, 0x1c, 0x00, 0x69, 0xff, 0xf7, 0x24, 0xfe, 0x00, 0x28, + 0x19, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x34, 0xfe, 0x25, 0x1c, 0x14, 0x35, + 0x01, 0x1c, 0x28, 0x1c, 0x00, 0xf0, 0x83, 0xfa, 0x23, 0x1c, 0xa8, 0x33, + 0x1b, 0x78, 0xff, 0x2b, 0x0b, 0xd0, 0x28, 0x1c, 0x00, 0xf0, 0x9e, 0xfa, + 0x09, 0x28, 0x06, 0xdc, 0x23, 0x1c, 0x22, 0x1c, 0xac, 0x33, 0xb4, 0x32, + 0x1b, 0x68, 0x12, 0x68, 0x1a, 0x60, 0x20, 0x69, 0xff, 0xf7, 0x15, 0xfe, + 0x00, 0x28, 0x11, 0xd0, 0x25, 0x1c, 0x5c, 0x35, 0x28, 0x1c, 0x00, 0xf0, + 0x85, 0xfa, 0x00, 0x28, 0x07, 0xd0, 0x28, 0x1c, 0x00, 0xf0, 0x72, 0xfa, + 0xc1, 0xb2, 0x20, 0x69, 0xff, 0xf7, 0x0e, 0xfe, 0x02, 0xe0, 0x20, 0x69, + 0xff, 0xf7, 0x17, 0xfe, 0x20, 0x69, 0xff, 0xf7, 0xf3, 0xfd, 0x00, 0x28, + 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0xf2, 0xfd, 0x20, 0x69, 0xff, 0xf7, + 0xe2, 0xfd, 0x38, 0xbd, 0xf0, 0x23, 0x08, 0x1c, 0x18, 0x40, 0x30, 0x38, + 0x43, 0x42, 0x58, 0x41, 0x70, 0x47, 0xf0, 0x23, 0x1b, 0x01, 0x19, 0x40, + 0x80, 0x23, 0x9b, 0x00, 0x99, 0x42, 0x0c, 0xd0, 0xc0, 0x23, 0x9b, 0x00, + 0x99, 0x42, 0x06, 0xd0, 0x80, 0x23, 0x5b, 0x00, 0x05, 0x20, 0x99, 0x42, + 0x04, 0xd0, 0x00, 0x20, 0x02, 0xe0, 0x07, 0x20, 0x00, 0xe0, 0x06, 0x20, + 0x70, 0x47, 0x0f, 0x23, 0x19, 0x40, 0x01, 0x29, 0x05, 0xd0, 0x02, 0x39, + 0x4b, 0x42, 0x4b, 0x41, 0x02, 0x20, 0xc0, 0x1a, 0x00, 0xe0, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x00, 0xf0, 0xb5, 0x03, 0x1c, 0x85, 0xb0, 0x03, 0x91, + 0xa4, 0x33, 0x04, 0x1c, 0x18, 0x27, 0x18, 0x78, 0x3b, 0x1c, 0x43, 0x43, + 0x34, 0x4e, 0x08, 0x21, 0xf3, 0x18, 0x59, 0x56, 0x15, 0x1c, 0xff, 0xf7, + 0xa5, 0xfc, 0x23, 0x1c, 0xa5, 0x33, 0x18, 0x78, 0x3b, 0x1c, 0x43, 0x43, + 0x08, 0x21, 0xf3, 0x18, 0x59, 0x56, 0xff, 0xf7, 0x9b, 0xfc, 0x23, 0x1c, + 0xa7, 0x33, 0x1b, 0x78, 0x02, 0x2b, 0x0a, 0xd1, 0x23, 0x1c, 0xb8, 0x33, + 0x18, 0x78, 0xff, 0x28, 0x05, 0xd0, 0x47, 0x43, 0x08, 0x21, 0xf7, 0x19, + 0x79, 0x56, 0xff, 0xf7, 0x8b, 0xfc, 0x27, 0x1c, 0xa8, 0x37, 0x38, 0x78, + 0xff, 0x28, 0x1a, 0xd0, 0x01, 0x21, 0xff, 0xf7, 0xf9, 0xfb, 0x3b, 0x78, + 0x18, 0x22, 0x5a, 0x43, 0xb3, 0x56, 0x1f, 0x4f, 0xdb, 0x01, 0x21, 0x1c, + 0xac, 0x31, 0xd8, 0x19, 0x08, 0x60, 0x1d, 0x49, 0xb6, 0x18, 0x5b, 0x18, + 0x21, 0x1c, 0x72, 0x68, 0xb0, 0x31, 0x0b, 0x60, 0x01, 0x21, 0x91, 0x40, + 0x0a, 0x1c, 0x21, 0x1c, 0xb4, 0x31, 0x0a, 0x60, 0x1a, 0x60, 0x01, 0x21, + 0x0a, 0x1c, 0x03, 0x9b, 0x20, 0x69, 0xff, 0xf7, 0x31, 0xfe, 0x29, 0x1c, + 0x20, 0x1c, 0xff, 0xf7, 0x88, 0xff, 0x29, 0x1c, 0x07, 0x1c, 0x20, 0x1c, + 0xff, 0xf7, 0x99, 0xff, 0x29, 0x1c, 0x06, 0x1c, 0x20, 0x1c, 0xff, 0xf7, + 0x77, 0xff, 0x39, 0x1c, 0x00, 0x90, 0x33, 0x1c, 0x20, 0x69, 0x01, 0x22, + 0xff, 0xf7, 0x02, 0xfd, 0x23, 0x1c, 0xa7, 0x33, 0x19, 0x78, 0x01, 0x3b, + 0x1a, 0x78, 0x20, 0x69, 0xff, 0xf7, 0x16, 0xfd, 0x20, 0x69, 0xff, 0xf7, + 0x34, 0xfd, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, + 0x18, 0x44, 0x00, 0x41, 0x14, 0x44, 0x00, 0x41, 0x3f, 0x20, 0x70, 0x47, + 0x13, 0xb5, 0x02, 0x68, 0x6b, 0x46, 0xd9, 0x71, 0x07, 0x33, 0x54, 0x68, + 0x19, 0x1c, 0x01, 0x22, 0xa0, 0x47, 0x16, 0xbd, 0x08, 0xb5, 0x00, 0x69, + 0x02, 0x21, 0x00, 0xf0, 0x49, 0xf8, 0x08, 0xbd, 0x08, 0xb5, 0x00, 0x69, + 0x03, 0x21, 0x00, 0xf0, 0x59, 0xf8, 0x08, 0xbd, 0x38, 0xb5, 0x0d, 0x1c, + 0x04, 0x1c, 0x13, 0x1c, 0x00, 0x69, 0x03, 0x21, 0x2a, 0x1c, 0x00, 0xf0, + 0xf1, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x01, 0x23, 0x63, 0x60, 0x38, 0xbd, + 0x10, 0xb5, 0x05, 0x4c, 0x23, 0x68, 0x5a, 0x1c, 0x04, 0xd1, 0x03, 0x68, + 0x5b, 0x69, 0x98, 0x47, 0x20, 0x60, 0x03, 0x1c, 0x18, 0x1c, 0x10, 0xbd, + 0x0c, 0x00, 0x00, 0x20, 0x07, 0x4a, 0x08, 0xb5, 0x13, 0x68, 0x59, 0x1c, + 0x04, 0xd0, 0x01, 0x21, 0x49, 0x42, 0x11, 0x60, 0x18, 0x1c, 0x03, 0xe0, + 0x00, 0x69, 0x02, 0x21, 0x00, 0xf0, 0xc2, 0xf8, 0x08, 0xbd, 0xc0, 0x46, + 0x0c, 0x00, 0x00, 0x20, 0x06, 0x4b, 0xfa, 0x21, 0x89, 0x00, 0x99, 0x60, + 0x05, 0x49, 0x00, 0x22, 0x08, 0x31, 0x19, 0x60, 0x04, 0x49, 0x5a, 0x60, + 0x19, 0x61, 0x1a, 0x76, 0x70, 0x47, 0xc0, 0x46, 0x74, 0x08, 0x00, 0x20, + 0xb8, 0x58, 0x00, 0x00, 0x34, 0x0c, 0x00, 0x20, 0x08, 0xb5, 0x08, 0x4b, + 0x8a, 0x00, 0xd0, 0x58, 0x00, 0x28, 0x03, 0xd0, 0x03, 0x68, 0x9b, 0x68, + 0x98, 0x47, 0x06, 0xe0, 0xc9, 0xb2, 0x04, 0x4b, 0x49, 0x01, 0x59, 0x18, + 0x88, 0x68, 0x80, 0x04, 0x80, 0x0c, 0x08, 0xbd, 0x18, 0x0c, 0x00, 0x20, + 0x38, 0x0c, 0x00, 0x20, 0x10, 0xb5, 0x0c, 0x1c, 0xff, 0xf7, 0xe6, 0xff, + 0x00, 0x28, 0x0c, 0xd0, 0x06, 0x4b, 0xe1, 0xb2, 0x1b, 0x68, 0x08, 0x31, + 0x49, 0x01, 0x59, 0x18, 0x4a, 0x79, 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, + 0x4b, 0x71, 0x02, 0x23, 0xcb, 0x71, 0x10, 0xbd, 0x38, 0x0c, 0x00, 0x20, + 0x10, 0xb5, 0xc9, 0xb2, 0x0c, 0x48, 0x49, 0x01, 0x43, 0x18, 0x9a, 0x68, + 0x92, 0x04, 0x92, 0x0c, 0x3f, 0x2a, 0x08, 0xd9, 0x14, 0x1c, 0x9a, 0x68, + 0x40, 0x3c, 0xa4, 0x04, 0x92, 0x0b, 0xa4, 0x0c, 0x92, 0x03, 0x22, 0x43, + 0x02, 0xe0, 0x9a, 0x68, 0x92, 0x0b, 0x92, 0x03, 0x9a, 0x60, 0x41, 0x18, + 0x88, 0x68, 0xc0, 0xb2, 0x10, 0xbd, 0xc0, 0x46, 0x38, 0x0c, 0x00, 0x20, + 0xf0, 0xb5, 0x1c, 0x1c, 0x2a, 0x4b, 0x85, 0xb0, 0x1b, 0x68, 0x06, 0x1c, + 0x0d, 0x1c, 0x02, 0x92, 0x00, 0x2b, 0x46, 0xd0, 0x27, 0x4b, 0x8a, 0x00, + 0xd0, 0x58, 0x00, 0x28, 0x05, 0xd0, 0x03, 0x68, 0x02, 0x99, 0x5b, 0x68, + 0x22, 0x1c, 0x98, 0x47, 0x3f, 0xe0, 0x30, 0x1c, 0xff, 0xf7, 0x9e, 0xff, + 0xa0, 0x42, 0x04, 0xd2, 0x30, 0x1c, 0x29, 0x1c, 0xff, 0xf7, 0x98, 0xff, + 0x04, 0x1c, 0x29, 0x1c, 0x30, 0x1c, 0xff, 0xf7, 0xbf, 0xff, 0x1c, 0x4f, + 0xe9, 0xb2, 0x4a, 0x01, 0x01, 0x91, 0x39, 0x68, 0x03, 0x92, 0x8b, 0x18, + 0xff, 0x33, 0x5a, 0x7a, 0x01, 0x21, 0x0a, 0x43, 0x17, 0x49, 0x5a, 0x72, + 0xab, 0x01, 0xc9, 0x18, 0x02, 0x98, 0x22, 0x1c, 0x00, 0xf0, 0xb5, 0xf9, + 0x00, 0x2c, 0x1b, 0xd0, 0x30, 0x1c, 0x29, 0x1c, 0xff, 0xf7, 0x7a, 0xff, + 0x00, 0x28, 0x15, 0xd1, 0x01, 0x9b, 0x3a, 0x68, 0x08, 0x33, 0x5b, 0x01, + 0xd3, 0x18, 0x19, 0x79, 0x40, 0x20, 0x01, 0x43, 0x19, 0x71, 0x01, 0x21, + 0xd9, 0x71, 0x03, 0x99, 0x53, 0x18, 0xff, 0x33, 0x9a, 0x7a, 0x01, 0x21, + 0x0a, 0x43, 0x9a, 0x72, 0x02, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x00, 0xe0, + 0x20, 0x1c, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0x3c, 0x0d, 0x00, 0x20, + 0x18, 0x0c, 0x00, 0x20, 0x38, 0x0c, 0x00, 0x20, 0x58, 0x0a, 0x00, 0x20, + 0x13, 0xb5, 0x6c, 0x46, 0x07, 0x34, 0x22, 0x1c, 0x01, 0x23, 0xff, 0xf7, + 0x99, 0xff, 0x01, 0x28, 0x01, 0xd1, 0x20, 0x78, 0x01, 0xe0, 0x01, 0x20, + 0x40, 0x42, 0x16, 0xbd, 0xf0, 0xb5, 0x1c, 0x1c, 0x3a, 0x4b, 0x85, 0xb0, + 0x1b, 0x68, 0x0e, 0x1c, 0x02, 0x92, 0x00, 0x2b, 0x60, 0xd0, 0x80, 0x23, + 0xdb, 0x01, 0x9c, 0x42, 0x5c, 0xd8, 0x00, 0x22, 0x00, 0x92, 0x00, 0x2c, + 0x56, 0xd0, 0x34, 0x4d, 0xf7, 0xb2, 0x2b, 0x68, 0x01, 0x93, 0x3b, 0x1c, + 0x08, 0x33, 0x01, 0x9a, 0x5b, 0x01, 0xd3, 0x18, 0x9b, 0x79, 0xdb, 0x09, + 0x1a, 0xd0, 0x2f, 0x4b, 0x2f, 0x49, 0x18, 0x68, 0x00, 0xf0, 0xc2, 0xf8, + 0x2e, 0x4b, 0x17, 0x21, 0x58, 0x43, 0x00, 0xf0, 0xbd, 0xf8, 0x3b, 0x1c, + 0x08, 0x33, 0x01, 0x9a, 0x5b, 0x01, 0xd3, 0x18, 0xdb, 0x79, 0x9a, 0x07, + 0x08, 0xd4, 0x29, 0x4b, 0x9a, 0x5d, 0x00, 0x2a, 0x38, 0xd1, 0x42, 0x1e, + 0x00, 0x28, 0x35, 0xd0, 0x10, 0x1c, 0xee, 0xe7, 0x24, 0x4b, 0x00, 0x22, + 0x9a, 0x55, 0x25, 0x1e, 0x3f, 0x2d, 0x00, 0xd9, 0x3f, 0x25, 0x22, 0x4a, + 0xb3, 0x01, 0xd3, 0x18, 0x18, 0x1c, 0x02, 0x99, 0x2a, 0x1c, 0x03, 0x93, + 0x00, 0xf0, 0x35, 0xf9, 0x18, 0x4a, 0x7b, 0x01, 0xd3, 0x18, 0x03, 0x9a, + 0xa9, 0x04, 0x5a, 0x61, 0x9a, 0x69, 0x89, 0x0c, 0x92, 0x0b, 0x92, 0x03, + 0x0a, 0x43, 0x9a, 0x61, 0x3b, 0x1c, 0x01, 0x9a, 0x08, 0x33, 0x5b, 0x01, + 0xd3, 0x18, 0x02, 0x22, 0xda, 0x71, 0x59, 0x79, 0x80, 0x22, 0x52, 0x42, + 0x0a, 0x43, 0x5a, 0x71, 0x00, 0x9b, 0x02, 0x9a, 0x5b, 0x19, 0x52, 0x19, + 0x00, 0x93, 0x64, 0x1b, 0x02, 0x92, 0xa6, 0xe7, 0x00, 0x98, 0x0b, 0xe0, + 0x01, 0x20, 0x08, 0xe0, 0x01, 0x22, 0x9a, 0x55, 0x7b, 0x01, 0xed, 0x18, + 0xab, 0x69, 0x10, 0x1c, 0x9b, 0x0b, 0x9b, 0x03, 0xab, 0x61, 0x40, 0x42, + 0x05, 0xb0, 0xf0, 0xbd, 0x3c, 0x0d, 0x00, 0x20, 0x38, 0x0c, 0x00, 0x20, + 0x04, 0x00, 0x00, 0x20, 0x40, 0x42, 0x0f, 0x00, 0x70, 0x11, 0x01, 0x00, + 0x90, 0x08, 0x00, 0x20, 0x98, 0x08, 0x00, 0x20, 0x01, 0x4a, 0x02, 0x4b, + 0x1a, 0x60, 0x70, 0x47, 0x00, 0x50, 0x00, 0x41, 0x38, 0x0c, 0x00, 0x20, + 0x10, 0xb5, 0x00, 0x21, 0x40, 0x22, 0x04, 0x1c, 0x00, 0xf0, 0xf2, 0xf8, + 0x00, 0x23, 0x20, 0x1c, 0x23, 0x64, 0x63, 0x64, 0x10, 0xbd, 0x02, 0x6c, + 0x10, 0xb5, 0x3f, 0x23, 0x54, 0x1c, 0x23, 0x40, 0x44, 0x6c, 0xa3, 0x42, + 0x01, 0xd0, 0x81, 0x54, 0x03, 0x64, 0x10, 0xbd, 0x00, 0x23, 0x03, 0x64, + 0x43, 0x64, 0x70, 0x47, 0x43, 0x6c, 0x02, 0x6c, 0x93, 0x42, 0x06, 0xd0, + 0xc2, 0x5c, 0x3f, 0x21, 0x01, 0x33, 0x0b, 0x40, 0x43, 0x64, 0x10, 0x1c, + 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x70, 0x47, 0x02, 0x6c, 0x43, 0x6c, + 0xd0, 0x1a, 0x00, 0xd5, 0x40, 0x30, 0x70, 0x47, 0x03, 0x6c, 0x40, 0x6c, + 0x83, 0x42, 0x02, 0xdb, 0xc0, 0x1a, 0x3f, 0x30, 0x01, 0xe0, 0xc0, 0x1a, + 0x01, 0x38, 0x70, 0x47, 0x43, 0x6c, 0x02, 0x6c, 0x93, 0x42, 0x01, 0xd0, + 0xc0, 0x5c, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x70, 0x47, 0x02, 0x6c, + 0x3f, 0x23, 0x01, 0x32, 0x1a, 0x40, 0x43, 0x6c, 0xd0, 0x1a, 0x43, 0x42, + 0x58, 0x41, 0xc0, 0xb2, 0x70, 0x47, 0x00, 0x00, 0x02, 0xb4, 0x71, 0x46, + 0x49, 0x08, 0x49, 0x00, 0x09, 0x5c, 0x49, 0x00, 0x8e, 0x44, 0x02, 0xbc, + 0x70, 0x47, 0xc0, 0x46, 0x00, 0x29, 0x34, 0xd0, 0x01, 0x23, 0x00, 0x22, + 0x10, 0xb4, 0x88, 0x42, 0x2c, 0xd3, 0x01, 0x24, 0x24, 0x07, 0xa1, 0x42, + 0x04, 0xd2, 0x81, 0x42, 0x02, 0xd2, 0x09, 0x01, 0x1b, 0x01, 0xf8, 0xe7, + 0xe4, 0x00, 0xa1, 0x42, 0x04, 0xd2, 0x81, 0x42, 0x02, 0xd2, 0x49, 0x00, + 0x5b, 0x00, 0xf8, 0xe7, 0x88, 0x42, 0x01, 0xd3, 0x40, 0x1a, 0x1a, 0x43, + 0x4c, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, 0x5c, 0x08, 0x22, 0x43, + 0x8c, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, 0x9c, 0x08, 0x22, 0x43, + 0xcc, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, 0xdc, 0x08, 0x22, 0x43, + 0x00, 0x28, 0x03, 0xd0, 0x1b, 0x09, 0x01, 0xd0, 0x09, 0x09, 0xe3, 0xe7, + 0x10, 0x1c, 0x10, 0xbc, 0x70, 0x47, 0x00, 0x28, 0x01, 0xd0, 0x00, 0x20, + 0xc0, 0x43, 0x07, 0xb4, 0x02, 0x48, 0x02, 0xa1, 0x40, 0x18, 0x02, 0x90, + 0x03, 0xbd, 0xc0, 0x46, 0x19, 0x00, 0x00, 0x00, 0x00, 0x29, 0xf0, 0xd0, + 0x03, 0xb5, 0xff, 0xf7, 0xb9, 0xff, 0x0e, 0xbc, 0x42, 0x43, 0x89, 0x1a, + 0x18, 0x47, 0xc0, 0x46, 0x70, 0x47, 0xc0, 0x46, 0x70, 0xb5, 0x0e, 0x4b, + 0x0e, 0x4d, 0x00, 0x24, 0xed, 0x1a, 0xad, 0x10, 0x1e, 0x1c, 0xac, 0x42, + 0x04, 0xd0, 0xa3, 0x00, 0xf3, 0x58, 0x98, 0x47, 0x01, 0x34, 0xf8, 0xe7, + 0x00, 0xf0, 0x32, 0xf9, 0x08, 0x4b, 0x09, 0x4d, 0x00, 0x24, 0xed, 0x1a, + 0xad, 0x10, 0x1e, 0x1c, 0xac, 0x42, 0x04, 0xd0, 0xa3, 0x00, 0xf3, 0x58, + 0x98, 0x47, 0x01, 0x34, 0xf8, 0xe7, 0x70, 0xbd, 0x74, 0x00, 0x00, 0x20, + 0x74, 0x00, 0x00, 0x20, 0x74, 0x00, 0x00, 0x20, 0x98, 0x00, 0x00, 0x20, + 0x08, 0xb5, 0x03, 0x4b, 0x01, 0x1c, 0x18, 0x68, 0x00, 0xf0, 0x76, 0xf8, + 0x08, 0xbd, 0xc0, 0x46, 0x70, 0x00, 0x00, 0x20, 0x08, 0xb5, 0x03, 0x4b, + 0x01, 0x1c, 0x18, 0x68, 0x00, 0xf0, 0x24, 0xf8, 0x08, 0xbd, 0xc0, 0x46, + 0x70, 0x00, 0x00, 0x20, 0x30, 0xb5, 0x00, 0x23, 0x93, 0x42, 0x08, 0xd0, + 0xc5, 0x5c, 0x01, 0x33, 0xcc, 0x18, 0x01, 0x3c, 0x24, 0x78, 0xa5, 0x42, + 0xf6, 0xd0, 0x28, 0x1b, 0x00, 0xe0, 0x00, 0x20, 0x30, 0xbd, 0x10, 0xb5, + 0x00, 0x23, 0x93, 0x42, 0x03, 0xd0, 0xcc, 0x5c, 0xc4, 0x54, 0x01, 0x33, + 0xf9, 0xe7, 0x10, 0xbd, 0x03, 0x1c, 0x82, 0x18, 0x93, 0x42, 0x02, 0xd0, + 0x19, 0x70, 0x01, 0x33, 0xfa, 0xe7, 0x70, 0x47, 0x30, 0xb5, 0x00, 0x29, + 0x40, 0xd0, 0x04, 0x39, 0x0b, 0x68, 0x00, 0x2b, 0x00, 0xda, 0xc9, 0x18, + 0x1e, 0x4a, 0x13, 0x68, 0x14, 0x1c, 0x00, 0x2b, 0x02, 0xd1, 0x4b, 0x60, + 0x11, 0x60, 0x33, 0xe0, 0x99, 0x42, 0x0f, 0xd2, 0x08, 0x68, 0x0a, 0x18, + 0x9a, 0x42, 0x05, 0xd1, 0x13, 0x68, 0x52, 0x68, 0xc0, 0x18, 0x08, 0x60, + 0x4a, 0x60, 0x00, 0xe0, 0x4b, 0x60, 0x21, 0x60, 0x24, 0xe0, 0x8a, 0x42, + 0x03, 0xd8, 0x13, 0x1c, 0x5a, 0x68, 0x00, 0x2a, 0xf9, 0xd1, 0x1d, 0x68, + 0x5c, 0x19, 0x8c, 0x42, 0x0b, 0xd1, 0x09, 0x68, 0x69, 0x18, 0x58, 0x18, + 0x19, 0x60, 0x90, 0x42, 0x14, 0xd1, 0x14, 0x68, 0x52, 0x68, 0x09, 0x19, + 0x19, 0x60, 0x5a, 0x60, 0x0e, 0xe0, 0x8c, 0x42, 0x02, 0xd9, 0x0c, 0x23, + 0x03, 0x60, 0x09, 0xe0, 0x08, 0x68, 0x0c, 0x18, 0x94, 0x42, 0x03, 0xd1, + 0x14, 0x68, 0x52, 0x68, 0x00, 0x19, 0x08, 0x60, 0x4a, 0x60, 0x59, 0x60, + 0x30, 0xbd, 0xc0, 0x46, 0x44, 0x0d, 0x00, 0x20, 0x70, 0xb5, 0x03, 0x23, + 0xcd, 0x1c, 0x9d, 0x43, 0x08, 0x35, 0x06, 0x1c, 0x0c, 0x2d, 0x01, 0xd2, + 0x0c, 0x25, 0x01, 0xe0, 0x00, 0x2d, 0x3f, 0xdb, 0x8d, 0x42, 0x3d, 0xd3, + 0x20, 0x4b, 0x1c, 0x68, 0x1a, 0x1c, 0x21, 0x1c, 0x00, 0x29, 0x13, 0xd0, + 0x08, 0x68, 0x43, 0x1b, 0x0d, 0xd4, 0x0b, 0x2b, 0x02, 0xd9, 0x0b, 0x60, + 0xcc, 0x18, 0x1e, 0xe0, 0x8c, 0x42, 0x02, 0xd1, 0x63, 0x68, 0x13, 0x60, + 0x1a, 0xe0, 0x48, 0x68, 0x60, 0x60, 0x0c, 0x1c, 0x16, 0xe0, 0x0c, 0x1c, + 0x49, 0x68, 0xe9, 0xe7, 0x14, 0x4c, 0x20, 0x68, 0x00, 0x28, 0x03, 0xd1, + 0x30, 0x1c, 0x00, 0xf0, 0x25, 0xf8, 0x20, 0x60, 0x30, 0x1c, 0x29, 0x1c, + 0x00, 0xf0, 0x20, 0xf8, 0x43, 0x1c, 0x15, 0xd0, 0xc4, 0x1c, 0x03, 0x23, + 0x9c, 0x43, 0x84, 0x42, 0x0a, 0xd1, 0x25, 0x60, 0x20, 0x1c, 0x0b, 0x30, + 0x07, 0x22, 0x23, 0x1d, 0x90, 0x43, 0xc3, 0x1a, 0x0b, 0xd0, 0x5a, 0x42, + 0xe2, 0x50, 0x08, 0xe0, 0x21, 0x1a, 0x30, 0x1c, 0x00, 0xf0, 0x0a, 0xf8, + 0x01, 0x30, 0xee, 0xd1, 0x0c, 0x23, 0x33, 0x60, 0x00, 0x20, 0x70, 0xbd, + 0x44, 0x0d, 0x00, 0x20, 0x40, 0x0d, 0x00, 0x20, 0x38, 0xb5, 0x07, 0x4c, + 0x00, 0x23, 0x05, 0x1c, 0x08, 0x1c, 0x23, 0x60, 0x00, 0xf0, 0x2a, 0xf8, + 0x43, 0x1c, 0x03, 0xd1, 0x23, 0x68, 0x00, 0x2b, 0x00, 0xd0, 0x2b, 0x60, + 0x38, 0xbd, 0xc0, 0x46, 0x4c, 0x0d, 0x00, 0x20, 0xc9, 0xb2, 0x03, 0x78, + 0x00, 0x2b, 0x03, 0xd0, 0x8b, 0x42, 0x04, 0xd0, 0x01, 0x30, 0xf8, 0xe7, + 0x00, 0x29, 0x00, 0xd0, 0x18, 0x1c, 0x70, 0x47, 0x30, 0xb5, 0x03, 0x1c, + 0x00, 0x2a, 0x07, 0xd0, 0x0c, 0x78, 0x01, 0x33, 0x5d, 0x1e, 0x01, 0x3a, + 0x2c, 0x70, 0x01, 0x31, 0x00, 0x2c, 0xf5, 0xd1, 0x9a, 0x18, 0x93, 0x42, + 0x03, 0xd0, 0x00, 0x21, 0x19, 0x70, 0x01, 0x33, 0xf9, 0xe7, 0x30, 0xbd, + 0x09, 0x4a, 0x13, 0x68, 0x00, 0x2b, 0x0c, 0xd0, 0x18, 0x18, 0x69, 0x46, + 0x88, 0x42, 0x02, 0xd8, 0x10, 0x60, 0x18, 0x1c, 0x70, 0x47, 0x05, 0x4b, + 0x0c, 0x22, 0x01, 0x20, 0x1a, 0x60, 0x40, 0x42, 0xf8, 0xe7, 0x03, 0x4b, + 0x13, 0x60, 0xef, 0xe7, 0x48, 0x0d, 0x00, 0x20, 0x4c, 0x0d, 0x00, 0x20, + 0x50, 0x0d, 0x00, 0x20, 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, + 0x9e, 0x46, 0x70, 0x47, 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, + 0x9e, 0x46, 0x70, 0x47, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x2e, 0x42, + 0x49, 0x4e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x1f, 0x22, 0x00, 0x00, 0x33, 0x22, 0x00, 0x00, + 0x19, 0x22, 0x00, 0x00, 0x5d, 0x22, 0x00, 0x00, 0x61, 0x23, 0x00, 0x00, + 0x8d, 0x22, 0x00, 0x00, 0xa1, 0x22, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x2f, 0x00, 0x7c, 0x3c, 0x3e, 0x5e, 0x2b, 0x3d, 0x3f, 0x2f, 0x5b, 0x5d, + 0x3b, 0x2c, 0x2a, 0x22, 0x5c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x34, 0x00, 0x00, + 0xbd, 0x40, 0x00, 0x00, 0x19, 0x22, 0x00, 0x00, 0x1d, 0x22, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x10, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, + 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, + 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x04, + 0x00, 0x04, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x01, + 0x00, 0x01, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x13, 0x00, 0x01, 0x01, + 0x01, 0x01, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x05, + 0x00, 0x05, 0x0a, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x05, + 0x01, 0x05, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x02, 0x00, + 0x02, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, + 0x03, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x02, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x03, + 0x01, 0x03, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x11, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0a, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0b, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x05, 0x00, 0x01, 0x00, + 0x01, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x06, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x07, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xdf, 0x44, 0x00, 0x00, 0xbd, 0x40, 0x00, 0x00, 0x97, 0x44, 0x00, 0x00, + 0x7f, 0x44, 0x00, 0x00, 0x75, 0x44, 0x00, 0x00, 0xa1, 0x44, 0x00, 0x00, + 0xd5, 0x44, 0x00, 0x00, 0x49, 0x44, 0x00, 0x00, 0x8d, 0x46, 0x00, 0x00, + 0x59, 0x44, 0x00, 0x00, 0x45, 0x44, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x85, 0x47, 0x00, 0x00, + 0xb1, 0x47, 0x00, 0x00, 0x81, 0x47, 0x00, 0x00, 0xa5, 0x47, 0x00, 0x00, + 0x99, 0x47, 0x00, 0x00, 0xe9, 0x47, 0x00, 0x00, 0xcd, 0x47, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0xff, 0xff, 0xff, 0x40, 0x42, 0x0f, 0x00, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0xe4, 0x58, 0x00, 0x00, + 0x04, 0x59, 0x00, 0x00, 0x24, 0x59, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xe0, 0x58, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x20, 0xdd, 0x20, 0x00, 0x00, + 0x05, 0x22, 0x00, 0x00, 0xed, 0x26, 0x00, 0x00, 0xa9, 0x2b, 0x00, 0x00, + 0x55, 0x38, 0x00, 0x00, 0x85, 0x3a, 0x00, 0x00, 0xed, 0x3a, 0x00, 0x00, + 0x0d, 0x48, 0x00, 0x00, 0xb1, 0x4a, 0x00, 0x00, 0xb5, 0x20, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00 diff --git a/libraries/SDU/src/boot/mkrfox1200.h b/libraries/SDU/src/boot/mkrfox1200.h new file mode 100644 index 0000000..df9ce32 --- /dev/null +++ b/libraries/SDU/src/boot/mkrfox1200.h @@ -0,0 +1,1236 @@ + 0x00, 0x80, 0x00, 0x20, 0x85, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0xd9, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0xdd, 0x3a, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0xa0, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0x44, 0x59, 0x00, 0x00, 0x08, 0xb5, 0x08, 0x4b, 0x00, 0x2b, 0x03, 0xd0, + 0x07, 0x48, 0x08, 0x49, 0x00, 0xe0, 0x00, 0xbf, 0x07, 0x48, 0x03, 0x68, + 0x00, 0x2b, 0x03, 0xd0, 0x06, 0x4b, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, + 0x08, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x00, 0x44, 0x59, 0x00, 0x00, + 0xa4, 0x00, 0x00, 0x20, 0x9c, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xf0, 0xb5, 0x33, 0x4c, 0xa5, 0x44, 0x01, 0xf0, 0x3d, 0xfe, 0x02, 0xf0, + 0x75, 0xfd, 0x01, 0x20, 0x01, 0xf0, 0x66, 0xfd, 0x2f, 0x4d, 0x04, 0x21, + 0x28, 0x1c, 0x00, 0xf0, 0xe7, 0xf9, 0x00, 0x28, 0x44, 0xd0, 0x2d, 0x4e, + 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0xbe, 0xfa, 0x00, 0x28, 0x3d, 0xd0, + 0x29, 0x1c, 0x01, 0xa8, 0x32, 0x1c, 0x01, 0x23, 0x00, 0xf0, 0x6e, 0xfa, + 0x01, 0xa8, 0x00, 0xf0, 0x00, 0xf9, 0x80, 0x21, 0x04, 0x1c, 0xc9, 0x01, + 0x88, 0x42, 0x2d, 0xd9, 0x01, 0xa8, 0x00, 0xf0, 0xe6, 0xf8, 0x22, 0x4a, + 0xc0, 0x21, 0xa7, 0x18, 0x21, 0x48, 0xc9, 0x01, 0x3a, 0x1c, 0x01, 0xf0, + 0xf5, 0xfb, 0xc0, 0x24, 0xe4, 0x01, 0x80, 0x22, 0x0a, 0xa9, 0x92, 0x00, + 0x01, 0xa8, 0x00, 0xf0, 0xcf, 0xf8, 0x80, 0x23, 0x21, 0x1c, 0x0a, 0xaa, + 0x9b, 0x00, 0x19, 0x48, 0x01, 0xf0, 0x8e, 0xfb, 0x80, 0x22, 0x92, 0x00, + 0xa3, 0x18, 0x17, 0x4a, 0xa4, 0x18, 0xbc, 0x42, 0x01, 0xd2, 0x1c, 0x1c, + 0xe9, 0xe7, 0x01, 0x24, 0x01, 0xa8, 0x00, 0xf0, 0xed, 0xf8, 0x00, 0x2c, + 0x06, 0xd0, 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0x8d, 0xfa, 0x01, 0xe0, + 0x00, 0x24, 0xf3, 0xe7, 0xc0, 0x23, 0xdb, 0x01, 0x1b, 0x68, 0x83, 0xf3, + 0x08, 0x88, 0x0c, 0x4b, 0xc0, 0x22, 0xd2, 0x01, 0x9a, 0x60, 0x0b, 0x4b, + 0x1b, 0x68, 0x18, 0x47, 0x00, 0x20, 0x8b, 0x23, 0x9b, 0x00, 0x9d, 0x44, + 0xf0, 0xbd, 0xc0, 0x46, 0xd4, 0xfd, 0xff, 0xff, 0xd4, 0x00, 0x00, 0x20, + 0xa8, 0x4e, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xbc, 0x00, 0x00, 0x20, + 0x00, 0xa2, 0xff, 0xff, 0x00, 0xed, 0x00, 0xe0, 0x04, 0x60, 0x00, 0x00, + 0x08, 0xb5, 0x00, 0x21, 0x02, 0x48, 0x0a, 0x1c, 0x01, 0xf0, 0x38, 0xfb, + 0x08, 0xbd, 0xc0, 0x46, 0xbc, 0x00, 0x00, 0x20, 0x00, 0x20, 0x70, 0x47, + 0x70, 0x47, 0x13, 0xb5, 0x02, 0x68, 0x6b, 0x46, 0xd9, 0x71, 0x07, 0x33, + 0x54, 0x68, 0x19, 0x1c, 0x01, 0x22, 0xa0, 0x47, 0x16, 0xbd, 0x38, 0xb5, + 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x25, 0xa8, 0x42, 0x02, 0xd1, 0x01, 0x23, + 0x63, 0x60, 0x0a, 0xe0, 0x45, 0x60, 0x92, 0xb2, 0x01, 0xf0, 0x04, 0xf8, + 0x23, 0x6a, 0x5b, 0x68, 0x00, 0x2b, 0x02, 0xd0, 0x01, 0x23, 0x63, 0x60, + 0x28, 0x1c, 0x38, 0xbd, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x01, 0xd0, + 0x00, 0xf0, 0x42, 0xfe, 0x08, 0xbd, 0x00, 0x00, 0x13, 0xb5, 0x6c, 0x46, + 0x07, 0x34, 0x21, 0x1c, 0x01, 0x22, 0x00, 0xf0, 0x5d, 0xfd, 0x01, 0x28, + 0x01, 0xd1, 0x20, 0x78, 0x00, 0xe0, 0x01, 0x48, 0x00, 0xb2, 0x16, 0xbd, + 0xff, 0xff, 0x00, 0x00, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x02, 0xd0, + 0xff, 0xf7, 0xea, 0xff, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x08, 0xbd, + 0x38, 0xb5, 0x05, 0x1c, 0x00, 0x6a, 0x00, 0x28, 0x0a, 0xd0, 0xff, 0xf7, + 0xdf, 0xff, 0x04, 0x1c, 0x63, 0x1c, 0x05, 0xd0, 0x28, 0x6a, 0x01, 0x69, + 0x01, 0x39, 0x00, 0xf0, 0xe5, 0xfd, 0x20, 0x1c, 0x38, 0xbd, 0x00, 0x00, + 0xf8, 0xb5, 0xfa, 0x23, 0x9b, 0x00, 0x83, 0x60, 0x0d, 0x4b, 0x00, 0x25, + 0x08, 0x33, 0x04, 0x1c, 0x45, 0x60, 0x03, 0x60, 0x28, 0x20, 0x0f, 0x1c, + 0x16, 0x1c, 0x02, 0xf0, 0xbb, 0xfc, 0x20, 0x62, 0xa8, 0x42, 0x0a, 0xd0, + 0x39, 0x1c, 0x28, 0x22, 0x02, 0xf0, 0xd7, 0xfc, 0x20, 0x1c, 0x10, 0x30, + 0x31, 0x1c, 0x0c, 0x22, 0x02, 0xf0, 0x9c, 0xfd, 0x25, 0x77, 0x20, 0x1c, + 0xf8, 0xbd, 0xc0, 0x46, 0xb8, 0x4e, 0x00, 0x00, 0xfa, 0x22, 0x92, 0x00, + 0x82, 0x60, 0x04, 0x4a, 0x00, 0x23, 0x08, 0x32, 0x43, 0x60, 0x02, 0x60, + 0x03, 0x62, 0x03, 0x74, 0x70, 0x47, 0xc0, 0x46, 0xb8, 0x4e, 0x00, 0x00, + 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x01, 0xd0, 0x00, 0xf0, 0x02, 0xfd, + 0x08, 0xbd, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x04, 0xd0, 0x00, 0xf0, + 0xa5, 0xfd, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x08, 0xbd, 0x03, 0x6a, + 0x00, 0x2b, 0x01, 0xd0, 0x18, 0x69, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, + 0x70, 0x47, 0x00, 0x6a, 0x00, 0x28, 0x00, 0xd0, 0xc0, 0x69, 0x70, 0x47, + 0x38, 0xb5, 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x28, 0x0b, 0xd0, 0x20, 0x1c, + 0xff, 0xf7, 0xf3, 0xff, 0x05, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0xe7, 0xff, + 0x02, 0x4b, 0x28, 0x1a, 0x98, 0x42, 0x00, 0xd9, 0x18, 0x1c, 0x38, 0xbd, + 0xff, 0x7f, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x28, + 0x06, 0xd0, 0x00, 0xf0, 0xe7, 0xfd, 0x20, 0x6a, 0x02, 0xf0, 0x68, 0xfc, + 0x00, 0x23, 0x23, 0x62, 0x10, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x0a, 0x1c, + 0x0c, 0x49, 0x8a, 0xb0, 0x04, 0x1c, 0x00, 0x23, 0x00, 0x91, 0x69, 0x46, + 0x4b, 0x72, 0x01, 0x93, 0x21, 0x1c, 0x68, 0x46, 0x01, 0x23, 0x00, 0xf0, + 0x81, 0xfe, 0x04, 0x1c, 0x60, 0x1e, 0x84, 0x41, 0xe4, 0xb2, 0x00, 0x2c, + 0x02, 0xd0, 0x68, 0x46, 0x00, 0xf0, 0xc8, 0xfd, 0x20, 0x1c, 0x0a, 0xb0, + 0x10, 0xbd, 0xc0, 0x46, 0x00, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x01, 0x23, + 0x00, 0x2a, 0x05, 0xd0, 0x00, 0xf0, 0x1a, 0xff, 0x03, 0x1c, 0x58, 0x1e, + 0x83, 0x41, 0xdb, 0xb2, 0x18, 0x1c, 0x08, 0xbd, 0x38, 0xb5, 0x01, 0x22, + 0x05, 0x1c, 0x0c, 0x1c, 0x01, 0xf0, 0x94, 0xf9, 0x02, 0x1c, 0x01, 0x20, + 0x00, 0x2a, 0x03, 0xd1, 0x28, 0x1c, 0x21, 0x1c, 0x01, 0xf0, 0x8c, 0xf9, + 0x38, 0xbd, 0xf0, 0xb5, 0x0c, 0x68, 0x03, 0x5d, 0x2f, 0x3b, 0x5d, 0x42, + 0x6b, 0x41, 0xe4, 0x18, 0x27, 0x1c, 0x0c, 0x37, 0x23, 0x1c, 0xc5, 0x5c, + 0x1e, 0x1b, 0x2f, 0x2d, 0x09, 0xd0, 0x00, 0x2d, 0x07, 0xd0, 0x01, 0x33, + 0x16, 0x1b, 0xf6, 0x18, 0x01, 0x3e, 0x35, 0x70, 0xbb, 0x42, 0xf2, 0xd1, + 0x0c, 0x26, 0x00, 0x24, 0x94, 0x55, 0xc2, 0x5c, 0x2f, 0x3a, 0x54, 0x42, + 0x62, 0x41, 0x9b, 0x18, 0x0b, 0x60, 0xc0, 0x5c, 0x43, 0x1e, 0x98, 0x41, + 0xc0, 0xb2, 0xf0, 0xbd, 0xf0, 0xb5, 0xa1, 0xb0, 0x03, 0x90, 0x25, 0x48, + 0x0d, 0x1c, 0x04, 0x92, 0x05, 0x93, 0x0c, 0xaa, 0x00, 0x23, 0x16, 0xa9, + 0x0d, 0x93, 0x0c, 0x90, 0x53, 0x72, 0x17, 0x93, 0x16, 0x90, 0x4b, 0x72, + 0x07, 0x93, 0x2c, 0x1c, 0x00, 0x92, 0x07, 0xa9, 0x08, 0xaa, 0x03, 0x98, + 0xff, 0xf7, 0xc3, 0xff, 0x01, 0x26, 0x02, 0x1c, 0x72, 0x40, 0x01, 0x90, + 0xd2, 0xb2, 0x20, 0x1c, 0x08, 0xa9, 0x05, 0x9b, 0x04, 0x9f, 0xb8, 0x47, + 0x00, 0x28, 0x07, 0xd1, 0xac, 0x42, 0x01, 0xd1, 0x00, 0x20, 0x23, 0xe0, + 0x20, 0x1c, 0x00, 0xf0, 0x57, 0xfd, 0xf9, 0xe7, 0x01, 0x9f, 0x00, 0x2f, + 0x11, 0xd0, 0x33, 0x1c, 0x00, 0x98, 0x21, 0x1c, 0x08, 0xaa, 0x00, 0xf0, + 0xfd, 0xfd, 0x06, 0x1c, 0xac, 0x42, 0x0f, 0xd0, 0x20, 0x1c, 0x00, 0xf0, + 0x47, 0xfd, 0x00, 0x2e, 0xe8, 0xd0, 0x23, 0x1c, 0x00, 0x9c, 0x00, 0x93, + 0xd1, 0xe7, 0xac, 0x42, 0x02, 0xd0, 0x20, 0x1c, 0x00, 0xf0, 0x3c, 0xfd, + 0x30, 0x1c, 0x03, 0xe0, 0x00, 0x28, 0xdb, 0xd0, 0x16, 0xac, 0xf0, 0xe7, + 0x21, 0xb0, 0xf0, 0xbd, 0x00, 0x4f, 0x00, 0x00, 0x38, 0xb5, 0x03, 0x1c, + 0x41, 0x33, 0x1b, 0x78, 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x2b, 0x02, 0xd0, + 0x38, 0x30, 0x00, 0xf0, 0x27, 0xfd, 0x20, 0x1c, 0x01, 0x21, 0x2a, 0x1c, + 0x00, 0xf0, 0xc8, 0xf9, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x0f, 0xe0, + 0x25, 0x1c, 0x10, 0x35, 0x28, 0x1c, 0x21, 0x1c, 0xff, 0xf7, 0x62, 0xff, + 0x00, 0x28, 0xf5, 0xd0, 0x20, 0x1c, 0x38, 0x30, 0x29, 0x1c, 0x00, 0xf0, + 0xcf, 0xfb, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x38, 0xbd, 0x00, 0x00, + 0x4b, 0x68, 0x43, 0x60, 0x0a, 0x4b, 0x03, 0x60, 0x0b, 0x7a, 0x03, 0x72, + 0x4b, 0x7a, 0x43, 0x72, 0xcb, 0x68, 0xc3, 0x60, 0x0b, 0x69, 0x03, 0x61, + 0x4b, 0x69, 0x43, 0x61, 0x0b, 0x7e, 0x03, 0x76, 0xcb, 0x69, 0xc3, 0x61, + 0x0b, 0x6a, 0x49, 0x6a, 0x03, 0x62, 0x41, 0x62, 0x70, 0x47, 0xc0, 0x46, + 0x00, 0x4f, 0x00, 0x00, 0xf0, 0xb5, 0x9d, 0xb0, 0x08, 0xae, 0x02, 0x92, + 0x03, 0x93, 0x27, 0x4a, 0x00, 0x23, 0x12, 0xaf, 0x05, 0x1c, 0x73, 0x60, + 0x7b, 0x60, 0x10, 0x31, 0x30, 0x1c, 0x08, 0x92, 0x73, 0x72, 0x12, 0x92, + 0x7b, 0x72, 0x00, 0xf0, 0x9d, 0xfb, 0x02, 0x9c, 0x20, 0x1c, 0x2f, 0x21, + 0x02, 0xf0, 0x36, 0xfc, 0x00, 0x28, 0x2e, 0xd0, 0x23, 0x78, 0x2f, 0x2b, + 0x01, 0xd1, 0x01, 0x34, 0xf4, 0xe7, 0x00, 0x1b, 0xc0, 0xb2, 0x03, 0x1c, + 0x0c, 0x28, 0x00, 0xd9, 0x0c, 0x23, 0xdb, 0xb2, 0x1a, 0x1c, 0x21, 0x1c, + 0x04, 0xa8, 0x01, 0x93, 0x02, 0xf0, 0x2e, 0xfc, 0x01, 0x9a, 0x00, 0x23, + 0x04, 0xa9, 0x38, 0x1c, 0x8b, 0x54, 0x00, 0xf0, 0xbf, 0xfc, 0x38, 0x1c, + 0x31, 0x1c, 0x04, 0xaa, 0x01, 0x23, 0x00, 0xf0, 0x69, 0xfd, 0x00, 0x28, + 0x04, 0xd1, 0x0c, 0x4b, 0x68, 0x60, 0x2b, 0x60, 0x68, 0x72, 0x10, 0xe0, + 0x01, 0x9b, 0x30, 0x1c, 0xe4, 0x18, 0x00, 0xf0, 0xad, 0xfc, 0x33, 0x1c, + 0x3e, 0x1c, 0x1f, 0x1c, 0xca, 0xe7, 0x02, 0x99, 0x03, 0x9a, 0x64, 0x1a, + 0x14, 0x60, 0x28, 0x1c, 0x31, 0x1c, 0xff, 0xf7, 0x95, 0xff, 0x28, 0x1c, + 0x1d, 0xb0, 0xf0, 0xbd, 0x00, 0x4f, 0x00, 0x00, 0xf0, 0xb5, 0xa1, 0xb0, + 0x05, 0x1c, 0x1f, 0x1c, 0x02, 0xa8, 0x01, 0xab, 0x16, 0x1c, 0xff, 0xf7, + 0xa1, 0xff, 0x01, 0x9b, 0xf6, 0x18, 0x33, 0x78, 0x00, 0x2b, 0x07, 0xd1, + 0x02, 0xa9, 0x16, 0xa8, 0xff, 0xf7, 0x7e, 0xff, 0x28, 0x1c, 0x16, 0xa9, + 0x17, 0x4a, 0x28, 0xe0, 0x00, 0x23, 0x0c, 0xac, 0x63, 0x60, 0x63, 0x72, + 0x6b, 0x46, 0x11, 0x33, 0x14, 0x4a, 0x1b, 0x78, 0x0c, 0x92, 0x00, 0x2b, + 0x03, 0xd1, 0x28, 0x1c, 0xff, 0xf7, 0x4a, 0xfe, 0x1b, 0xe0, 0x20, 0x1c, + 0x02, 0xa9, 0x32, 0x1c, 0x3b, 0x1c, 0x00, 0xf0, 0x21, 0xfd, 0x00, 0x28, + 0xf3, 0xd0, 0x02, 0xa8, 0x00, 0xf0, 0x6c, 0xfc, 0x06, 0x23, 0x1f, 0x40, + 0x9f, 0x42, 0x03, 0xd1, 0x20, 0x1c, 0x13, 0x99, 0x00, 0xf0, 0xf6, 0xfb, + 0x21, 0x1c, 0x16, 0xa8, 0xff, 0xf7, 0x54, 0xff, 0x28, 0x1c, 0x16, 0xa9, + 0x32, 0x1c, 0xff, 0xf7, 0x0b, 0xfe, 0x28, 0x1c, 0x21, 0xb0, 0xf0, 0xbd, + 0xe0, 0x4e, 0x00, 0x00, 0x00, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x1c, + 0x08, 0x1c, 0x19, 0x1c, 0x38, 0x31, 0x02, 0x4a, 0x00, 0x23, 0xff, 0xf7, + 0xc9, 0xfe, 0x08, 0xbd, 0xa5, 0x23, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x1c, + 0x08, 0x1c, 0x19, 0x1c, 0x38, 0x31, 0x02, 0x4a, 0x00, 0x23, 0xff, 0xf7, + 0xbd, 0xfe, 0x08, 0xbd, 0xe1, 0x23, 0x00, 0x00, 0x08, 0x4b, 0x02, 0x21, + 0x19, 0x61, 0x19, 0x1c, 0x00, 0x22, 0x30, 0x31, 0x0a, 0x70, 0x06, 0x49, + 0x5a, 0x71, 0x9a, 0x71, 0x9a, 0x72, 0x1a, 0x73, 0xda, 0x63, 0x99, 0x63, + 0x41, 0x33, 0x1a, 0x70, 0x70, 0x47, 0xc0, 0x46, 0xd4, 0x00, 0x00, 0x20, + 0x00, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x01, 0x1c, 0x01, 0x48, 0x01, 0xf0, + 0xab, 0xf9, 0x08, 0xbd, 0x78, 0x07, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, + 0xff, 0x21, 0x01, 0xf0, 0xa3, 0xf9, 0x08, 0xbd, 0x78, 0x07, 0x00, 0x20, + 0x08, 0xb5, 0x01, 0x21, 0x00, 0x79, 0x01, 0xf0, 0x2b, 0xfc, 0x05, 0x4b, + 0x1a, 0x78, 0x00, 0x2a, 0x04, 0xd0, 0x00, 0x22, 0x03, 0x48, 0x1a, 0x70, + 0x01, 0xf0, 0x80, 0xf9, 0x08, 0xbd, 0xc0, 0x46, 0x40, 0x01, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x10, 0xb5, 0x08, 0x4b, 0x04, 0x1c, 0x1a, 0x78, + 0x00, 0x2a, 0x06, 0xd1, 0x01, 0x22, 0x1a, 0x70, 0x05, 0x4b, 0x06, 0x48, + 0x06, 0xcb, 0x01, 0xf0, 0x51, 0xf9, 0x20, 0x79, 0x00, 0x21, 0x01, 0xf0, + 0x0b, 0xfc, 0x10, 0xbd, 0x40, 0x01, 0x00, 0x20, 0x38, 0x01, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x10, 0xb5, 0x83, 0x79, 0x04, 0x1c, 0x00, 0x2b, + 0x0d, 0xd0, 0x23, 0x89, 0x5a, 0x1c, 0x22, 0x81, 0x05, 0x4a, 0x93, 0x42, + 0x02, 0xd8, 0xff, 0xf7, 0xbf, 0xff, 0xf6, 0xe7, 0x20, 0x1c, 0xff, 0xf7, + 0xc3, 0xff, 0x00, 0x23, 0xa3, 0x71, 0x10, 0xbd, 0x01, 0x02, 0x00, 0x00, + 0x00, 0xb5, 0x06, 0x29, 0x03, 0xd9, 0x16, 0x23, 0x43, 0x71, 0x00, 0x20, + 0x1c, 0xe0, 0x0f, 0x4b, 0x05, 0x29, 0x13, 0xd8, 0x08, 0x1c, 0x00, 0x22, + 0x02, 0xf0, 0xc0, 0xf9, 0x03, 0x05, 0x07, 0x09, 0x0b, 0x0d, 0x0b, 0x49, + 0x08, 0xe0, 0x0b, 0x49, 0x06, 0xe0, 0x0b, 0x49, 0x04, 0xe0, 0x0b, 0x49, + 0x02, 0xe0, 0x0b, 0x49, 0x00, 0xe0, 0x0b, 0x49, 0x19, 0x60, 0x02, 0xe0, + 0x0a, 0x4a, 0x1a, 0x60, 0x00, 0x22, 0x1a, 0x71, 0x5a, 0x71, 0x01, 0x20, + 0x00, 0xbd, 0xc0, 0x46, 0x38, 0x01, 0x00, 0x20, 0x00, 0x1b, 0xb7, 0x00, + 0x00, 0x09, 0x3d, 0x00, 0x80, 0x84, 0x1e, 0x00, 0x40, 0x42, 0x0f, 0x00, + 0x20, 0xa1, 0x07, 0x00, 0x90, 0xd0, 0x03, 0x00, 0x48, 0xe8, 0x01, 0x00, + 0x38, 0xb5, 0x0c, 0x1c, 0x01, 0xf0, 0xdc, 0xf9, 0x05, 0x1c, 0xff, 0xf7, + 0x79, 0xff, 0xff, 0x28, 0x06, 0xd0, 0x01, 0xf0, 0xd5, 0xf9, 0x40, 0x1b, + 0xa0, 0x42, 0xf6, 0xd3, 0x00, 0x20, 0x00, 0xe0, 0x01, 0x20, 0x38, 0xbd, + 0xf8, 0xb5, 0x04, 0x1c, 0x0e, 0x1c, 0x17, 0x1c, 0xff, 0xf7, 0x9c, 0xff, + 0x20, 0x1c, 0xff, 0xf7, 0x81, 0xff, 0x96, 0x21, 0x49, 0x00, 0x20, 0x1c, + 0xff, 0xf7, 0xe0, 0xff, 0x40, 0x20, 0x30, 0x43, 0xff, 0xf7, 0x54, 0xff, + 0x18, 0x25, 0x38, 0x1c, 0xe8, 0x40, 0xc0, 0xb2, 0x08, 0x3d, 0xff, 0xf7, + 0x4d, 0xff, 0x2b, 0x1c, 0x08, 0x33, 0xf6, 0xd1, 0x95, 0x20, 0x00, 0x2e, + 0x03, 0xd0, 0x87, 0x20, 0x08, 0x2e, 0x00, 0xd0, 0xff, 0x20, 0xff, 0xf7, + 0x41, 0xff, 0x00, 0x25, 0xff, 0xf7, 0x46, 0xff, 0x43, 0xb2, 0xe0, 0x72, + 0x00, 0x2b, 0x04, 0xda, 0xff, 0x2d, 0x02, 0xd0, 0x01, 0x35, 0xed, 0xb2, + 0xf4, 0xe7, 0xf8, 0xbd, 0xf7, 0xb5, 0x00, 0x25, 0x02, 0x71, 0x05, 0x73, + 0x85, 0x72, 0x85, 0x71, 0x45, 0x71, 0x04, 0x1c, 0x01, 0x91, 0x01, 0xf0, + 0x91, 0xf9, 0x01, 0x21, 0x07, 0x1c, 0x20, 0x79, 0x01, 0xf0, 0x0a, 0xfb, + 0x01, 0x21, 0x20, 0x79, 0x01, 0xf0, 0x60, 0xfb, 0x42, 0x4e, 0x30, 0x1c, + 0x01, 0xf0, 0x76, 0xf8, 0x41, 0x4b, 0x42, 0x49, 0x1d, 0x71, 0x5d, 0x71, + 0x19, 0x60, 0x30, 0x1c, 0x5a, 0x68, 0x01, 0xf0, 0x95, 0xf8, 0x0a, 0x25, + 0x01, 0x3d, 0xff, 0x20, 0xed, 0xb2, 0xff, 0xf7, 0x0d, 0xff, 0x00, 0x2d, + 0xf8, 0xd1, 0x30, 0x1c, 0x01, 0xf0, 0xa6, 0xf8, 0x20, 0x1c, 0xff, 0xf7, + 0x29, 0xff, 0x00, 0x21, 0x20, 0x1c, 0x0a, 0x1c, 0xff, 0xf7, 0x9a, 0xff, + 0x06, 0x1c, 0xe0, 0x72, 0x01, 0x28, 0x08, 0xd0, 0x01, 0xf0, 0x62, 0xf9, + 0xfa, 0x23, 0xc0, 0x1b, 0xdb, 0x00, 0x98, 0x42, 0xef, 0xd9, 0x01, 0x23, + 0x3b, 0xe0, 0xd5, 0x22, 0x20, 0x1c, 0x08, 0x21, 0x52, 0x00, 0xff, 0xf7, + 0x87, 0xff, 0x04, 0x23, 0x18, 0x42, 0x01, 0xd0, 0x26, 0x73, 0x0b, 0xe0, + 0x1e, 0x1c, 0xff, 0xf7, 0xed, 0xfe, 0x01, 0x3e, 0xf6, 0xb2, 0xe0, 0x72, + 0x00, 0x2e, 0xf8, 0xd1, 0x02, 0x23, 0xaa, 0x28, 0x25, 0xd1, 0x23, 0x73, + 0x26, 0x7b, 0x02, 0x3e, 0x73, 0x42, 0x5e, 0x41, 0xb6, 0x07, 0x37, 0x21, + 0x00, 0x22, 0x20, 0x1c, 0xff, 0xf7, 0x6c, 0xff, 0x32, 0x1c, 0x20, 0x1c, + 0x29, 0x21, 0xff, 0xf7, 0x67, 0xff, 0x02, 0x1c, 0xe0, 0x72, 0x08, 0xd0, + 0x01, 0xf0, 0x30, 0xf9, 0xfa, 0x23, 0xc0, 0x1b, 0xdb, 0x00, 0x98, 0x42, + 0xeb, 0xd9, 0x08, 0x23, 0x09, 0xe0, 0x23, 0x7b, 0x02, 0x2b, 0x19, 0xd1, + 0x20, 0x1c, 0x3a, 0x21, 0xff, 0xf7, 0x54, 0xff, 0x00, 0x28, 0x05, 0xd0, + 0x06, 0x23, 0x63, 0x71, 0x20, 0x1c, 0xff, 0xf7, 0xc3, 0xfe, 0x15, 0xe0, + 0xff, 0xf7, 0xb8, 0xfe, 0xc0, 0x23, 0x18, 0x40, 0x98, 0x42, 0x01, 0xd1, + 0x03, 0x23, 0x23, 0x73, 0xff, 0xf7, 0xb0, 0xfe, 0xff, 0xf7, 0xae, 0xfe, + 0xff, 0xf7, 0xac, 0xfe, 0x20, 0x1c, 0xff, 0xf7, 0xb1, 0xfe, 0x20, 0x1c, + 0x01, 0x99, 0xff, 0xf7, 0xef, 0xfe, 0x05, 0x1c, 0x28, 0x1c, 0xfe, 0xbd, + 0x78, 0x07, 0x00, 0x20, 0x38, 0x01, 0x00, 0x20, 0x90, 0xd0, 0x03, 0x00, + 0x38, 0xb5, 0x04, 0x1c, 0x01, 0xf0, 0xf8, 0xf8, 0x05, 0x1c, 0xff, 0xf7, + 0x95, 0xfe, 0xe0, 0x72, 0xff, 0x28, 0x08, 0xd1, 0x01, 0xf0, 0xf0, 0xf8, + 0x96, 0x23, 0x40, 0x1b, 0x5b, 0x00, 0x98, 0x42, 0xf3, 0xd9, 0x0f, 0x23, + 0x02, 0xe0, 0xfe, 0x28, 0x06, 0xd0, 0x0d, 0x23, 0x20, 0x1c, 0x63, 0x71, + 0xff, 0xf7, 0x8a, 0xfe, 0x00, 0x20, 0x00, 0xe0, 0x01, 0x20, 0x38, 0xbd, + 0xf8, 0xb5, 0x04, 0x1c, 0x0f, 0x1c, 0x15, 0x1c, 0x1e, 0x1e, 0x45, 0xd0, + 0x9a, 0x18, 0x80, 0x23, 0x9b, 0x00, 0x9a, 0x42, 0x42, 0xdc, 0x83, 0x79, + 0x00, 0x2b, 0x05, 0xd0, 0x02, 0x68, 0x91, 0x42, 0x02, 0xd1, 0x03, 0x89, + 0xab, 0x42, 0x16, 0xd9, 0x23, 0x7b, 0x27, 0x60, 0x03, 0x2b, 0x00, 0xd0, + 0x7f, 0x02, 0x3a, 0x1c, 0x20, 0x1c, 0x11, 0x21, 0xff, 0xf7, 0xf2, 0xfe, + 0x07, 0x1e, 0x02, 0xd0, 0x03, 0x23, 0x63, 0x71, 0x2a, 0xe0, 0x20, 0x1c, + 0xff, 0xf7, 0xbc, 0xff, 0x00, 0x28, 0x25, 0xd0, 0x01, 0x23, 0x27, 0x81, + 0xa3, 0x71, 0x23, 0x89, 0xab, 0x42, 0x05, 0xd2, 0xff, 0xf7, 0x4e, 0xfe, + 0x23, 0x89, 0x01, 0x33, 0x23, 0x81, 0xf6, 0xe7, 0x06, 0x9d, 0x06, 0x9a, + 0xab, 0x1a, 0x9b, 0xb2, 0xb3, 0x42, 0x04, 0xd2, 0xff, 0xf7, 0x42, 0xfe, + 0x28, 0x70, 0x01, 0x35, 0xf5, 0xe7, 0x23, 0x89, 0xa2, 0x7a, 0xf3, 0x18, + 0x9b, 0xb2, 0x23, 0x81, 0x00, 0x2a, 0x02, 0xd0, 0x06, 0x4a, 0x93, 0x42, + 0x02, 0xd9, 0x20, 0x1c, 0xff, 0xf7, 0x66, 0xfe, 0x01, 0x20, 0x03, 0xe0, + 0x20, 0x1c, 0xff, 0xf7, 0x35, 0xfe, 0x00, 0x20, 0xf8, 0xbd, 0xc0, 0x46, + 0xff, 0x01, 0x00, 0x00, 0x07, 0xb5, 0x80, 0x23, 0x00, 0x92, 0x9b, 0x00, + 0x00, 0x22, 0xff, 0xf7, 0xa3, 0xff, 0x0e, 0xbd, 0x70, 0xb5, 0x05, 0x1c, + 0x08, 0x1c, 0x16, 0x1c, 0xff, 0xf7, 0x12, 0xfe, 0x00, 0x24, 0x30, 0x5d, + 0xff, 0xf7, 0x0e, 0xfe, 0x01, 0x34, 0x80, 0x23, 0x9b, 0x00, 0x9c, 0x42, + 0xf7, 0xd1, 0xff, 0x20, 0xff, 0xf7, 0x06, 0xfe, 0xff, 0x20, 0xff, 0xf7, + 0x03, 0xfe, 0xff, 0xf7, 0x09, 0xfe, 0x1f, 0x23, 0xe8, 0x72, 0x03, 0x40, + 0x01, 0x20, 0x05, 0x2b, 0x05, 0xd0, 0x11, 0x23, 0x28, 0x1c, 0x6b, 0x71, + 0xff, 0xf7, 0x06, 0xfe, 0x00, 0x20, 0x70, 0xbd, 0x70, 0xb5, 0x0b, 0x1c, + 0x04, 0x1c, 0x16, 0x1c, 0x00, 0x29, 0x01, 0xd1, 0x12, 0x23, 0x28, 0xe0, + 0x02, 0x7b, 0x03, 0x2a, 0x00, 0xd0, 0x4b, 0x02, 0x20, 0x1c, 0x18, 0x21, + 0x1a, 0x1c, 0xff, 0xf7, 0x7d, 0xfe, 0x05, 0x1e, 0x01, 0xd0, 0x04, 0x23, + 0x1b, 0xe0, 0x20, 0x1c, 0xfe, 0x21, 0x32, 0x1c, 0xff, 0xf7, 0xc2, 0xff, + 0x00, 0x28, 0x15, 0xd0, 0x96, 0x21, 0x20, 0x1c, 0x89, 0x00, 0xff, 0xf7, + 0x5b, 0xfe, 0x00, 0x28, 0x01, 0xd1, 0x15, 0x23, 0x0b, 0xe0, 0x20, 0x1c, + 0x0d, 0x21, 0x2a, 0x1c, 0xff, 0xf7, 0x64, 0xfe, 0x00, 0x28, 0x03, 0xd1, + 0xff, 0xf7, 0xce, 0xfd, 0x00, 0x28, 0x06, 0xd0, 0x14, 0x23, 0x63, 0x71, + 0x20, 0x1c, 0xff, 0xf7, 0xcf, 0xfd, 0x00, 0x20, 0x03, 0xe0, 0x20, 0x1c, + 0xff, 0xf7, 0xca, 0xfd, 0x01, 0x20, 0x70, 0xbd, 0x03, 0x4b, 0x04, 0x4a, + 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x70, 0x47, 0xc0, 0x46, + 0x38, 0x01, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, 0x02, 0x1c, 0x10, 0xb5, + 0x0c, 0x32, 0x04, 0x1c, 0x01, 0x21, 0x40, 0x6a, 0x00, 0xf0, 0x24, 0xfd, + 0x00, 0x28, 0x0a, 0xd0, 0x23, 0x6a, 0x01, 0x20, 0x00, 0x2b, 0x06, 0xd1, + 0xe3, 0x68, 0x22, 0x7a, 0x23, 0x62, 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, + 0x23, 0x72, 0x10, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xe6, 0xff, + 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x1b, 0xe0, 0x63, 0x6a, 0xe6, 0x68, + 0x1a, 0x7c, 0x02, 0x3e, 0x96, 0x40, 0x5a, 0x69, 0x1d, 0x79, 0xb6, 0x18, + 0x00, 0x2d, 0x08, 0xd0, 0x70, 0x1e, 0x40, 0x19, 0x00, 0xf0, 0x4c, 0xfc, + 0x00, 0x28, 0xed, 0xd0, 0x01, 0x3d, 0xed, 0xb2, 0xf4, 0xe7, 0x63, 0x6a, + 0x01, 0x20, 0x1a, 0x7c, 0x80, 0x23, 0x9b, 0x00, 0x93, 0x40, 0xe2, 0x69, + 0xd3, 0x18, 0xe3, 0x61, 0x70, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, + 0x40, 0x69, 0x00, 0xf0, 0x13, 0xfc, 0x00, 0x28, 0x03, 0xd0, 0x20, 0x7e, + 0x01, 0x4b, 0x40, 0x01, 0xc0, 0x18, 0x10, 0xbd, 0x50, 0x01, 0x00, 0x20, + 0xf0, 0xb5, 0x00, 0x23, 0x87, 0xb0, 0x07, 0x1c, 0x0e, 0x1c, 0x20, 0x22, + 0xf2, 0x54, 0x01, 0x33, 0x0b, 0x2b, 0xfa, 0xd1, 0x07, 0x21, 0x00, 0x25, + 0x01, 0x91, 0x3c, 0x78, 0x00, 0x2c, 0x2a, 0xd0, 0x2e, 0x2c, 0x06, 0xd1, + 0x01, 0x9b, 0x0a, 0x2b, 0x2b, 0xd0, 0x0a, 0x21, 0x08, 0x25, 0x01, 0x91, + 0x1f, 0xe0, 0x02, 0xa8, 0x14, 0x49, 0x10, 0x22, 0x02, 0xf0, 0x07, 0xf8, + 0x00, 0x23, 0x02, 0xa9, 0xca, 0x5c, 0x00, 0x2a, 0x03, 0xd0, 0x01, 0x33, + 0xa2, 0x42, 0xf8, 0xd1, 0x19, 0xe0, 0x01, 0x9b, 0x9d, 0x42, 0x16, 0xd8, + 0x23, 0x1c, 0x21, 0x3b, 0x5d, 0x2b, 0x12, 0xd8, 0x22, 0x1c, 0x6b, 0x1c, + 0x61, 0x3a, 0xdb, 0xb2, 0x75, 0x19, 0x19, 0x2a, 0x01, 0xd8, 0x20, 0x3c, + 0xe4, 0xb2, 0x2c, 0x70, 0x1d, 0x1c, 0x01, 0x37, 0xd1, 0xe7, 0x30, 0x78, + 0x20, 0x38, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x00, 0xe0, 0x00, 0x20, + 0x07, 0xb0, 0xf0, 0xbd, 0xe2, 0x4e, 0x00, 0x00, 0x38, 0xb5, 0x42, 0x7a, + 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x2a, 0x01, 0xd0, 0x00, 0x20, 0x1f, 0xe0, + 0x4b, 0x1c, 0xdb, 0x7f, 0x10, 0x2b, 0x06, 0xd1, 0x02, 0x23, 0x43, 0x72, + 0x02, 0x62, 0x4b, 0x8c, 0x5b, 0x01, 0xc3, 0x61, 0x0c, 0xe0, 0x20, 0x2b, + 0xf0, 0xd1, 0x03, 0x23, 0x43, 0x72, 0x49, 0x6a, 0x22, 0x1c, 0x01, 0x62, + 0x1c, 0x32, 0x28, 0x1c, 0x00, 0xf0, 0x18, 0xfc, 0x00, 0x28, 0xe5, 0xd0, + 0x00, 0x23, 0x01, 0x20, 0x65, 0x62, 0x20, 0x72, 0xe3, 0x60, 0x23, 0x61, + 0x63, 0x61, 0x23, 0x76, 0x38, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x43, 0x7a, + 0x85, 0xb0, 0x04, 0x1c, 0x0e, 0x1c, 0x03, 0x92, 0x00, 0x2b, 0x01, 0xd1, + 0x3a, 0x48, 0x11, 0xe0, 0x03, 0x7a, 0xd8, 0x07, 0xfa, 0xd5, 0xe2, 0x69, + 0x20, 0x69, 0x03, 0x99, 0x13, 0x1a, 0x99, 0x42, 0x01, 0xd9, 0x9b, 0xb2, + 0x03, 0x93, 0x03, 0x99, 0x02, 0x91, 0x02, 0x9b, 0x00, 0x2b, 0x04, 0xd1, + 0x03, 0x99, 0x88, 0xb2, 0x00, 0xb2, 0x05, 0xb0, 0xf0, 0xbd, 0x23, 0x69, + 0x61, 0x7a, 0xdf, 0x05, 0xff, 0x0d, 0x5a, 0x0a, 0x60, 0x6a, 0x02, 0x29, + 0x02, 0xd1, 0x41, 0x6a, 0x51, 0x18, 0x1b, 0xe0, 0x05, 0x79, 0x01, 0x3d, + 0x2a, 0x40, 0xd5, 0xb2, 0x00, 0x2f, 0x0d, 0xd1, 0x00, 0x2d, 0x0b, 0xd1, + 0x00, 0x2b, 0x02, 0xd1, 0x22, 0x6a, 0xe2, 0x60, 0x06, 0xe0, 0x22, 0x1c, + 0xe1, 0x68, 0x0c, 0x32, 0x00, 0xf0, 0xa0, 0xfb, 0x00, 0x28, 0xc9, 0xd0, + 0x63, 0x6a, 0xe1, 0x68, 0x1a, 0x7c, 0x02, 0x39, 0x5b, 0x69, 0x91, 0x40, + 0xc9, 0x18, 0x49, 0x19, 0x80, 0x22, 0x02, 0x9d, 0x92, 0x00, 0xd3, 0x1b, + 0x9d, 0x42, 0x00, 0xdd, 0x9d, 0xb2, 0x23, 0x7a, 0x58, 0x06, 0x01, 0xd4, + 0x95, 0x42, 0x18, 0xd1, 0x16, 0x4b, 0x1b, 0x68, 0x99, 0x42, 0x14, 0xd0, + 0x15, 0x4b, 0x3a, 0x1c, 0x18, 0x68, 0x00, 0x96, 0x2b, 0x1c, 0xff, 0xf7, + 0x1f, 0xfe, 0x00, 0x28, 0xa8, 0xd0, 0x76, 0x19, 0x01, 0xe0, 0xdf, 0x1b, + 0xf6, 0x19, 0x21, 0x69, 0x02, 0x9a, 0x4b, 0x19, 0x55, 0x1b, 0xad, 0xb2, + 0x23, 0x61, 0x02, 0x95, 0xab, 0xe7, 0x08, 0x1c, 0x00, 0x21, 0x00, 0xf0, + 0x2b, 0xfb, 0x00, 0x28, 0x96, 0xd0, 0x09, 0x4b, 0x32, 0x1c, 0xff, 0x18, + 0x79, 0x19, 0x3b, 0x1c, 0x8b, 0x42, 0xe8, 0xd0, 0x18, 0x78, 0x01, 0x33, + 0x10, 0x70, 0x01, 0x32, 0xf8, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x73, 0xb5, 0x43, 0x7a, 0x04, 0x1c, 0x01, 0x2b, 0x01, 0xd8, 0x00, 0x20, + 0x16, 0xe0, 0x03, 0x69, 0x6d, 0x46, 0x07, 0x35, 0xde, 0x05, 0x29, 0x1c, + 0x01, 0x22, 0x36, 0x0f, 0xff, 0xf7, 0x6a, 0xff, 0x01, 0x28, 0x01, 0xd1, + 0x2b, 0x78, 0x00, 0xe0, 0x05, 0x4b, 0x1b, 0xb2, 0x01, 0x33, 0xec, 0xd0, + 0x23, 0x69, 0x70, 0x01, 0x1f, 0x33, 0x23, 0x61, 0x02, 0x4b, 0xc0, 0x18, + 0x76, 0xbd, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0x50, 0x01, 0x00, 0x20, + 0x70, 0xb5, 0x04, 0x1c, 0x40, 0x7a, 0x0d, 0x1c, 0x00, 0x28, 0x2a, 0xd0, + 0xe2, 0x69, 0x91, 0x42, 0x01, 0xd9, 0x00, 0x20, 0x25, 0xe0, 0x02, 0x28, + 0x21, 0xd0, 0x00, 0x2d, 0x01, 0xd1, 0xe5, 0x60, 0x1d, 0xe0, 0x62, 0x6a, + 0x21, 0x69, 0x13, 0x7c, 0x68, 0x1e, 0x09, 0x33, 0x4a, 0x1e, 0xd8, 0x40, + 0xda, 0x40, 0x03, 0x1e, 0x93, 0x42, 0x01, 0xd3, 0x00, 0x29, 0x02, 0xd1, + 0x22, 0x6a, 0xe2, 0x60, 0x00, 0xe0, 0x83, 0x1a, 0x1e, 0x1c, 0x00, 0x2e, + 0x09, 0xd0, 0x22, 0x1c, 0x60, 0x6a, 0xe1, 0x68, 0x0c, 0x32, 0x00, 0xf0, + 0x07, 0xfb, 0x01, 0x3e, 0x00, 0x28, 0xf4, 0xd1, 0x01, 0xe0, 0x25, 0x61, + 0x01, 0x20, 0x70, 0xbd, 0x38, 0xb5, 0x05, 0x1c, 0x40, 0x7a, 0x00, 0x28, + 0x33, 0xd0, 0x2b, 0x7a, 0x7f, 0x2b, 0x2d, 0xd9, 0x28, 0x1c, 0x01, 0x21, + 0xff, 0xf7, 0x9a, 0xfe, 0x04, 0x1e, 0x2a, 0xd0, 0x6b, 0x7a, 0x01, 0x2b, + 0x07, 0xd8, 0x2b, 0x7f, 0x03, 0x77, 0x6b, 0x7f, 0x43, 0x77, 0xab, 0x7f, + 0x83, 0x77, 0xeb, 0x7f, 0xc3, 0x77, 0x2b, 0x6a, 0x9a, 0xb2, 0x1b, 0x0c, + 0x23, 0x75, 0x1b, 0x0a, 0x63, 0x75, 0x0d, 0x4b, 0xa2, 0x76, 0x1b, 0x68, + 0x12, 0x0a, 0xe2, 0x76, 0x00, 0x2b, 0x0b, 0xd0, 0x20, 0x1c, 0x21, 0x1c, + 0x18, 0x30, 0x16, 0x31, 0x98, 0x47, 0x63, 0x7e, 0x22, 0x7e, 0x1b, 0x02, + 0x13, 0x43, 0xa3, 0x74, 0x1b, 0x0a, 0xe3, 0x74, 0x2a, 0x7a, 0x7f, 0x23, + 0x13, 0x40, 0x2b, 0x72, 0x00, 0xf0, 0x5c, 0xfa, 0xff, 0xe7, 0x38, 0xbd, + 0x44, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xc0, 0xff, + 0x00, 0x28, 0x02, 0xd0, 0x00, 0x23, 0x63, 0x72, 0x01, 0x20, 0x10, 0xbd, + 0x73, 0xb5, 0x42, 0x7a, 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x20, 0x01, 0x2a, + 0x4b, 0xd1, 0x20, 0x7a, 0x02, 0x23, 0x18, 0x40, 0x47, 0xd0, 0xe3, 0x69, + 0x00, 0x20, 0x99, 0x42, 0x43, 0xd8, 0x10, 0x1c, 0x00, 0x2b, 0x40, 0xd0, + 0x20, 0x1c, 0x29, 0x1c, 0x26, 0x69, 0xff, 0xf7, 0x71, 0xff, 0x00, 0x28, + 0x25, 0xd0, 0x60, 0x6a, 0x00, 0x2d, 0x06, 0xd1, 0x21, 0x6a, 0x00, 0xf0, + 0x95, 0xfb, 0x00, 0x28, 0x1d, 0xd0, 0x25, 0x62, 0x1d, 0xe0, 0xe1, 0x68, + 0x01, 0xaa, 0x00, 0xf0, 0x93, 0xfa, 0x00, 0x28, 0x15, 0xd0, 0x60, 0x6a, + 0x01, 0x99, 0x43, 0x1c, 0xdb, 0x7f, 0x10, 0x2b, 0x01, 0xd1, 0x12, 0x4b, + 0x00, 0xe0, 0x12, 0x4b, 0x99, 0x42, 0x0c, 0xd2, 0x00, 0xf0, 0x7e, 0xfb, + 0x00, 0x28, 0x06, 0xd0, 0x60, 0x6a, 0xe1, 0x68, 0x0e, 0x4a, 0x00, 0xf0, + 0xcf, 0xfa, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x11, 0xe0, 0x22, 0x7a, + 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, 0xe5, 0x61, 0x23, 0x72, 0x20, 0x1c, + 0xff, 0xf7, 0x70, 0xff, 0x00, 0x28, 0xf2, 0xd0, 0x29, 0x1e, 0xb1, 0x42, + 0x00, 0xd9, 0x31, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x35, 0xff, 0x76, 0xbd, + 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, 0xff, 0xff, 0xff, 0x0f, + 0x38, 0xb5, 0x23, 0x4b, 0x15, 0x1c, 0x4a, 0x01, 0xd3, 0x18, 0x04, 0x1c, + 0xd8, 0x7a, 0x11, 0x22, 0x10, 0x42, 0x04, 0xd0, 0x42, 0x22, 0x15, 0x42, + 0x01, 0xd0, 0x00, 0x20, 0x36, 0xe0, 0x1d, 0x4a, 0x21, 0x76, 0x12, 0x68, + 0x62, 0x61, 0x5a, 0x7d, 0x18, 0x7d, 0xd9, 0x7e, 0x12, 0x02, 0x02, 0x43, + 0x98, 0x7e, 0x09, 0x02, 0x12, 0x04, 0x01, 0x43, 0x11, 0x43, 0x21, 0x62, + 0xd8, 0x7a, 0x18, 0x22, 0x02, 0x40, 0x0c, 0xd1, 0x5a, 0x7f, 0x19, 0x7f, + 0x12, 0x02, 0x0a, 0x43, 0x99, 0x7f, 0xdb, 0x7f, 0x09, 0x04, 0x0a, 0x43, + 0x1b, 0x06, 0x13, 0x43, 0xe3, 0x61, 0x01, 0x23, 0x09, 0xe0, 0x10, 0x2a, + 0xdb, 0xd1, 0x22, 0x1c, 0x60, 0x6a, 0x1c, 0x32, 0x00, 0xf0, 0x5a, 0xfa, + 0x00, 0x28, 0xd4, 0xd0, 0x04, 0x23, 0x63, 0x72, 0x0f, 0x23, 0x00, 0x21, + 0x2b, 0x40, 0x23, 0x72, 0xe1, 0x60, 0x21, 0x61, 0x01, 0x20, 0x6a, 0x06, + 0x02, 0xd5, 0x20, 0x1c, 0xff, 0xf7, 0x60, 0xff, 0x38, 0xbd, 0xc0, 0x46, + 0x50, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0xf0, 0xb5, 0x45, 0x7a, + 0x87, 0xb0, 0x04, 0x1c, 0x0e, 0x1c, 0x01, 0x93, 0x00, 0x2d, 0x00, 0xd0, + 0x86, 0xe0, 0x10, 0x1c, 0x03, 0xa9, 0xff, 0xf7, 0xbb, 0xfd, 0x00, 0x28, + 0x00, 0xd1, 0x80, 0xe0, 0x72, 0x6a, 0x2f, 0x1c, 0x62, 0x62, 0xf5, 0x60, + 0x35, 0x61, 0x33, 0x69, 0xf2, 0x69, 0x93, 0x42, 0x26, 0xd2, 0xdb, 0x05, + 0x1b, 0x0f, 0x30, 0x1c, 0x00, 0x93, 0xff, 0xf7, 0x9f, 0xfe, 0x01, 0x1e, + 0x6f, 0xd0, 0x03, 0x78, 0x00, 0x2b, 0x01, 0xd0, 0xe5, 0x2b, 0x0b, 0xd1, + 0x00, 0x2f, 0x04, 0xd1, 0x00, 0x9b, 0x23, 0x76, 0x34, 0x4b, 0x1b, 0x68, + 0x63, 0x61, 0x0b, 0x78, 0x01, 0x27, 0x00, 0x2b, 0xe3, 0xd1, 0x0d, 0xe0, + 0x03, 0xa8, 0x0b, 0x22, 0x01, 0xf0, 0xa8, 0xfd, 0x00, 0x28, 0xdc, 0xd1, + 0x01, 0x9a, 0x30, 0x23, 0x13, 0x40, 0x30, 0x2b, 0x53, 0xd0, 0x20, 0x1c, + 0x00, 0x99, 0x4b, 0xe0, 0x01, 0x9a, 0x12, 0x23, 0x13, 0x40, 0x12, 0x2b, + 0x4b, 0xd1, 0x00, 0x2f, 0x06, 0xd0, 0x20, 0x1c, 0x01, 0x21, 0xff, 0xf7, + 0x6f, 0xfd, 0x06, 0x1e, 0x0a, 0xd1, 0x42, 0xe0, 0x73, 0x7a, 0x02, 0x2b, + 0x3f, 0xd0, 0x30, 0x1c, 0xff, 0xf7, 0x40, 0xfd, 0x00, 0x28, 0x3a, 0xd0, + 0x1f, 0x4e, 0x27, 0x76, 0x00, 0x21, 0x20, 0x22, 0x30, 0x1c, 0x01, 0xf0, + 0x99, 0xfd, 0x30, 0x1c, 0x03, 0xa9, 0x0b, 0x22, 0x01, 0xf0, 0x8b, 0xfd, + 0x1a, 0x4b, 0x1b, 0x68, 0x00, 0x2b, 0x05, 0xd0, 0x30, 0x1c, 0x31, 0x1c, + 0x10, 0x30, 0x0e, 0x31, 0x98, 0x47, 0x06, 0xe0, 0x21, 0x22, 0x32, 0x74, + 0xb3, 0x73, 0x28, 0x22, 0x08, 0x23, 0x72, 0x74, 0xf3, 0x73, 0x73, 0x7c, + 0x32, 0x7c, 0x1b, 0x02, 0x13, 0x43, 0xff, 0x22, 0x1a, 0x40, 0x1b, 0x0a, + 0xf3, 0x74, 0x73, 0x76, 0xf3, 0x7b, 0xb2, 0x74, 0x32, 0x76, 0xb2, 0x7b, + 0x1b, 0x02, 0x13, 0x43, 0xb3, 0x75, 0x1b, 0x0a, 0xf3, 0x75, 0x00, 0xf0, + 0x21, 0xf9, 0x00, 0x28, 0x07, 0xd0, 0x21, 0x7e, 0x01, 0x9a, 0x20, 0x1c, + 0xff, 0xf7, 0x26, 0xff, 0x05, 0x1c, 0x00, 0xe0, 0x00, 0x25, 0x28, 0x1c, + 0x07, 0xb0, 0xf0, 0xbd, 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x44, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x00, 0x21, 0x04, 0x1c, 0xff, 0xf7, + 0xbb, 0xfe, 0x00, 0x28, 0x0b, 0xd0, 0x20, 0x1c, 0x01, 0x21, 0xff, 0xf7, + 0x15, 0xfd, 0x00, 0x28, 0x05, 0xd0, 0xe5, 0x23, 0x03, 0x70, 0x00, 0x23, + 0x63, 0x72, 0x00, 0xf0, 0xfb, 0xf8, 0x10, 0xbd, 0x10, 0xb5, 0x0a, 0x1c, + 0x0a, 0x49, 0x8a, 0xb0, 0x08, 0x31, 0x00, 0x23, 0x04, 0x1c, 0x00, 0x91, + 0x69, 0x46, 0x4b, 0x72, 0x01, 0x93, 0x68, 0x46, 0x21, 0x1c, 0x02, 0x23, + 0xff, 0xf7, 0x42, 0xff, 0x00, 0x28, 0x02, 0xd0, 0x68, 0x46, 0xff, 0xf7, + 0xd7, 0xff, 0x0a, 0xb0, 0x10, 0xbd, 0xc0, 0x46, 0xf8, 0x4e, 0x00, 0x00, + 0xf0, 0xb5, 0x43, 0x7a, 0x87, 0xb0, 0x04, 0x1c, 0x0d, 0x1c, 0x03, 0x92, + 0x01, 0x2b, 0x0d, 0xd1, 0x03, 0x7a, 0x99, 0x07, 0x0a, 0xd5, 0x5a, 0x07, + 0x0c, 0xd5, 0xe1, 0x69, 0x22, 0x69, 0x8a, 0x42, 0x08, 0xd0, 0x20, 0x1c, + 0xff, 0xf7, 0x06, 0xfe, 0x00, 0x28, 0x03, 0xd1, 0x01, 0x23, 0x63, 0x60, + 0x00, 0x20, 0xaa, 0xe0, 0x03, 0x9b, 0x01, 0x93, 0x3b, 0xe0, 0x60, 0x6a, + 0x73, 0x0a, 0x07, 0x79, 0xf6, 0x05, 0x01, 0x3f, 0x1f, 0x40, 0xff, 0xb2, + 0xf6, 0x0d, 0x00, 0x2f, 0x36, 0xd0, 0x80, 0x22, 0x92, 0x00, 0x92, 0x1b, + 0x01, 0x99, 0x92, 0xb2, 0x0b, 0x1c, 0x91, 0x42, 0x00, 0xd9, 0x13, 0x1c, + 0x9b, 0xb2, 0x02, 0x93, 0x63, 0x6a, 0xe1, 0x68, 0x1a, 0x7c, 0x02, 0x39, + 0x91, 0x40, 0x5a, 0x69, 0x8b, 0x18, 0x02, 0x9a, 0xdf, 0x19, 0x80, 0x23, + 0x9b, 0x00, 0x9a, 0x42, 0x3f, 0xd1, 0x44, 0x4b, 0x19, 0x68, 0xb9, 0x42, + 0x02, 0xd1, 0x01, 0x22, 0x52, 0x42, 0x1a, 0x60, 0x41, 0x4b, 0x39, 0x1c, + 0x18, 0x68, 0x2a, 0x1c, 0xff, 0xf7, 0x22, 0xfc, 0x00, 0x28, 0xc7, 0xd0, + 0x80, 0x22, 0x92, 0x00, 0xad, 0x18, 0x01, 0x99, 0x02, 0x9a, 0x8b, 0x1a, + 0x21, 0x69, 0x9b, 0xb2, 0x01, 0x93, 0x8b, 0x18, 0x23, 0x61, 0x01, 0x9a, + 0x26, 0x69, 0x00, 0x2a, 0xbf, 0xd1, 0x49, 0xe0, 0x00, 0x2e, 0xc6, 0xd1, + 0xe1, 0x68, 0x00, 0x29, 0x03, 0xd1, 0x23, 0x6a, 0x00, 0x2b, 0x16, 0xd1, + 0x0f, 0xe0, 0x05, 0xaa, 0x00, 0xf0, 0xe2, 0xf8, 0x00, 0x28, 0x58, 0xd0, + 0x62, 0x6a, 0x05, 0x9b, 0x01, 0x32, 0xd2, 0x7f, 0x10, 0x2a, 0x01, 0xd1, + 0x2c, 0x4a, 0x00, 0xe0, 0x2c, 0x4a, 0x93, 0x42, 0x05, 0xd3, 0x20, 0x1c, + 0xff, 0xf7, 0x3c, 0xfc, 0x00, 0x28, 0xaa, 0xd1, 0x98, 0xe7, 0xe3, 0x60, + 0xa7, 0xe7, 0x00, 0x2e, 0x0f, 0xd1, 0x23, 0x69, 0xe1, 0x69, 0x8b, 0x42, + 0x0b, 0xd3, 0x00, 0xf0, 0x59, 0xf8, 0x00, 0x28, 0x8c, 0xd0, 0x1f, 0x4b, + 0x01, 0x21, 0x1f, 0x60, 0x21, 0x4b, 0x1a, 0x78, 0x0a, 0x43, 0x1a, 0x70, + 0x06, 0xe0, 0x38, 0x1c, 0x01, 0x21, 0x00, 0xf0, 0x75, 0xf8, 0x00, 0x28, + 0x00, 0xd1, 0x7d, 0xe7, 0x1c, 0x4b, 0x2a, 0x1c, 0xf6, 0x18, 0x02, 0x9b, + 0xf1, 0x18, 0x33, 0x1c, 0x8b, 0x42, 0x04, 0xd0, 0x10, 0x78, 0x01, 0x32, + 0x18, 0x70, 0x01, 0x33, 0xf8, 0xe7, 0x9e, 0x1b, 0xad, 0x19, 0xa8, 0xe7, + 0xe1, 0x69, 0x23, 0x7a, 0x8e, 0x42, 0x01, 0xd9, 0xe6, 0x61, 0x06, 0xe0, + 0x12, 0x4a, 0x12, 0x68, 0x00, 0x2a, 0x06, 0xd0, 0x03, 0x9a, 0x00, 0x2a, + 0x03, 0xd0, 0x80, 0x22, 0x52, 0x42, 0x13, 0x43, 0x23, 0x72, 0x23, 0x7a, + 0x19, 0x07, 0x01, 0xd4, 0x03, 0x98, 0x06, 0xe0, 0x20, 0x1c, 0xff, 0xf7, + 0x8b, 0xfd, 0x00, 0x28, 0x00, 0xd1, 0x51, 0xe7, 0xf6, 0xe7, 0x07, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, + 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, 0x50, 0x03, 0x00, 0x20, + 0x50, 0x01, 0x00, 0x20, 0x44, 0x01, 0x00, 0x20, 0x07, 0xb5, 0x6b, 0x46, + 0xd9, 0x71, 0x07, 0x33, 0x19, 0x1c, 0x01, 0x22, 0xff, 0xf7, 0x22, 0xff, + 0x0e, 0xbd, 0x00, 0x00, 0xf8, 0xb5, 0x0f, 0x4f, 0x01, 0x20, 0x3b, 0x78, + 0x00, 0x2b, 0x18, 0xd0, 0x0d, 0x4e, 0x0e, 0x4b, 0x0e, 0x4d, 0x19, 0x68, + 0x30, 0x68, 0x2a, 0x1c, 0xff, 0xf7, 0x80, 0xfb, 0x00, 0x28, 0x0e, 0xd0, + 0x0b, 0x4c, 0x21, 0x68, 0x00, 0x29, 0x07, 0xd0, 0x30, 0x68, 0x2a, 0x1c, + 0xff, 0xf7, 0x76, 0xfb, 0x00, 0x28, 0x04, 0xd0, 0x00, 0x23, 0x23, 0x60, + 0x00, 0x23, 0x3b, 0x70, 0x01, 0x20, 0xf8, 0xbd, 0x50, 0x03, 0x00, 0x20, + 0x4c, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x48, 0x01, 0x00, 0x20, 0x70, 0xb5, 0x0d, 0x4d, 0x04, 0x1c, 0x2b, 0x68, + 0x0e, 0x1c, 0x83, 0x42, 0x0e, 0xd0, 0xff, 0xf7, 0xcd, 0xff, 0x00, 0x28, + 0x01, 0xd1, 0x00, 0x20, 0x0d, 0xe0, 0x08, 0x4b, 0x21, 0x1c, 0x18, 0x68, + 0x07, 0x4a, 0xff, 0xf7, 0x25, 0xfb, 0x00, 0x28, 0xf5, 0xd0, 0x2c, 0x60, + 0x05, 0x4b, 0x01, 0x20, 0x1a, 0x78, 0x16, 0x43, 0x1e, 0x70, 0x70, 0xbd, + 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x50, 0x03, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xae, 0xff, + 0x00, 0x28, 0x0f, 0xd0, 0x00, 0x23, 0x08, 0x4a, 0x00, 0x21, 0x99, 0x54, + 0x80, 0x22, 0x01, 0x33, 0x92, 0x00, 0x93, 0x42, 0xf7, 0xd1, 0x05, 0x4b, + 0x01, 0x20, 0x1c, 0x60, 0x04, 0x4b, 0x1a, 0x78, 0x02, 0x43, 0x1a, 0x70, + 0x10, 0xbd, 0xc0, 0x46, 0x50, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, + 0x50, 0x03, 0x00, 0x20, 0xc3, 0x68, 0x70, 0xb5, 0x01, 0x33, 0x0c, 0x1c, + 0x15, 0x1c, 0x99, 0x42, 0x01, 0xd9, 0x00, 0x20, 0x21, 0xe0, 0x46, 0x1c, + 0xf1, 0x7f, 0xc2, 0x69, 0xe3, 0x09, 0x10, 0x29, 0x00, 0xd1, 0x23, 0x0a, + 0x98, 0x18, 0x0d, 0x4b, 0x1b, 0x68, 0x98, 0x42, 0x07, 0xd1, 0xf2, 0x7f, + 0x0b, 0x4b, 0x10, 0x2a, 0x09, 0xd1, 0xe4, 0xb2, 0x64, 0x00, 0x1b, 0x5b, + 0x0b, 0xe0, 0x00, 0x21, 0xff, 0xf7, 0x9e, 0xff, 0x00, 0x28, 0xf2, 0xd1, + 0xe3, 0xe7, 0x7f, 0x22, 0x14, 0x40, 0xa4, 0x00, 0x1b, 0x59, 0x1b, 0x01, + 0x1b, 0x09, 0x2b, 0x60, 0x01, 0x20, 0x70, 0xbd, 0x00, 0x00, 0x00, 0x20, + 0x50, 0x01, 0x00, 0x20, 0x73, 0xb5, 0x05, 0x1c, 0x01, 0x91, 0x16, 0x1c, + 0x00, 0x24, 0x28, 0x1c, 0x01, 0x99, 0x01, 0xaa, 0xff, 0xf7, 0xc6, 0xff, + 0x00, 0x28, 0x10, 0xd0, 0x2a, 0x7c, 0x80, 0x23, 0x9b, 0x00, 0x93, 0x40, + 0xe4, 0x18, 0x6b, 0x1c, 0xdb, 0x7f, 0x01, 0x9a, 0x10, 0x2b, 0x01, 0xd1, + 0x03, 0x4b, 0x00, 0xe0, 0x03, 0x4b, 0x9a, 0x42, 0xe9, 0xd3, 0x34, 0x60, + 0x01, 0x20, 0x76, 0xbd, 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, + 0xf7, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x01, 0x92, 0x01, 0x29, 0x32, 0xd9, + 0xc3, 0x68, 0x00, 0x20, 0x01, 0x33, 0x99, 0x42, 0x2e, 0xd8, 0x6f, 0x1c, + 0xfa, 0x7f, 0xee, 0x69, 0xcb, 0x09, 0x10, 0x2a, 0x00, 0xd1, 0x0b, 0x0a, + 0x9e, 0x19, 0x14, 0x4b, 0x1b, 0x68, 0x9e, 0x42, 0x08, 0xd1, 0xfa, 0x7f, + 0x12, 0x4b, 0x10, 0x2a, 0x0b, 0xd1, 0xe4, 0xb2, 0x01, 0x9a, 0x64, 0x00, + 0x1a, 0x53, 0x0b, 0xe0, 0x30, 0x1c, 0x00, 0x21, 0xff, 0xf7, 0x48, 0xff, + 0x00, 0x28, 0xf0, 0xd1, 0x12, 0xe0, 0x7f, 0x22, 0x14, 0x40, 0x01, 0x9a, + 0xa4, 0x00, 0x1a, 0x51, 0x09, 0x4b, 0x01, 0x20, 0x1a, 0x78, 0x02, 0x43, + 0x1a, 0x70, 0x2b, 0x7e, 0x83, 0x42, 0x05, 0xd9, 0xab, 0x68, 0xf6, 0x18, + 0x05, 0x4b, 0x1e, 0x60, 0x00, 0xe0, 0x00, 0x20, 0xfe, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, 0x50, 0x03, 0x00, 0x20, + 0x48, 0x01, 0x00, 0x20, 0xf0, 0xb5, 0x15, 0x68, 0x87, 0xb0, 0x06, 0x1c, + 0x02, 0x91, 0x17, 0x1c, 0x00, 0x2d, 0x03, 0xd0, 0x00, 0x21, 0x01, 0x35, + 0x01, 0x91, 0x06, 0xe0, 0x02, 0x9b, 0x05, 0x68, 0x01, 0x3b, 0x5a, 0x42, + 0x53, 0x41, 0xdb, 0xb2, 0x01, 0x93, 0xf2, 0x68, 0x00, 0x23, 0x01, 0x32, + 0x03, 0x92, 0x2c, 0x1c, 0x00, 0x93, 0x00, 0x99, 0xf2, 0x68, 0x91, 0x42, + 0x21, 0xd2, 0x03, 0x9b, 0x9c, 0x42, 0x01, 0xd9, 0x02, 0x24, 0x25, 0x1c, + 0x30, 0x1c, 0x21, 0x1c, 0x05, 0xaa, 0xff, 0xf7, 0x43, 0xff, 0x00, 0x28, + 0x15, 0xd0, 0x05, 0x99, 0x63, 0x1c, 0x00, 0x29, 0x01, 0xd0, 0x1d, 0x1c, + 0x03, 0xe0, 0x02, 0x99, 0x5a, 0x1b, 0x8a, 0x42, 0x04, 0xd0, 0x00, 0x9a, + 0x1c, 0x1c, 0x01, 0x32, 0x00, 0x92, 0xe0, 0xe7, 0x30, 0x1c, 0x21, 0x1c, + 0x13, 0x4a, 0xff, 0xf7, 0x7f, 0xff, 0x00, 0x28, 0x0b, 0xd1, 0x00, 0x20, + 0x1d, 0xe0, 0x63, 0x1e, 0x30, 0x1c, 0x19, 0x1c, 0x22, 0x1c, 0x00, 0x93, + 0xff, 0xf7, 0x74, 0xff, 0x00, 0x28, 0xf4, 0xd0, 0x00, 0x9c, 0xac, 0x42, + 0xf3, 0xd8, 0x39, 0x68, 0x00, 0x29, 0x06, 0xd1, 0x01, 0x99, 0x3d, 0x60, + 0x00, 0x29, 0x09, 0xd0, 0x01, 0x35, 0x35, 0x60, 0x06, 0xe0, 0x30, 0x1c, + 0x2a, 0x1c, 0xff, 0xf7, 0x61, 0xff, 0x00, 0x28, 0xf2, 0xd1, 0xe0, 0xe7, + 0x01, 0x20, 0x07, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0xff, 0xff, 0xff, 0x0f, + 0x02, 0x23, 0x37, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x03, 0x60, 0x28, 0x1c, + 0x21, 0x1c, 0x01, 0xaa, 0xff, 0xf7, 0xfc, 0xfe, 0x00, 0x28, 0x12, 0xd0, + 0x28, 0x1c, 0x21, 0x1c, 0x00, 0x22, 0xff, 0xf7, 0x47, 0xff, 0x00, 0x28, + 0x0b, 0xd0, 0x6b, 0x1c, 0xdb, 0x7f, 0x01, 0x9c, 0x10, 0x2b, 0x01, 0xd1, + 0x04, 0x4b, 0x00, 0xe0, 0x04, 0x4b, 0x9c, 0x42, 0xe7, 0xd3, 0x01, 0x20, + 0x00, 0xe0, 0x00, 0x20, 0x3e, 0xbd, 0xc0, 0x46, 0xf8, 0xff, 0x00, 0x00, + 0xf8, 0xff, 0xff, 0x0f, 0xf8, 0xb5, 0x44, 0x4b, 0x04, 0x1c, 0x15, 0x1c, + 0x19, 0x60, 0x29, 0xd0, 0x04, 0x2a, 0x01, 0xd9, 0x00, 0x20, 0x7d, 0xe0, + 0x00, 0x20, 0x01, 0x1c, 0xff, 0xf7, 0x90, 0xfe, 0x00, 0x28, 0xf7, 0xd0, + 0x2d, 0x01, 0x3d, 0x4b, 0xa9, 0x35, 0xff, 0x35, 0x5d, 0x19, 0xaa, 0x79, + 0xab, 0x1d, 0x50, 0x06, 0xee, 0xd1, 0xea, 0x7c, 0xa9, 0x7c, 0x12, 0x02, + 0x0a, 0x43, 0x29, 0x7d, 0x09, 0x04, 0x0a, 0x43, 0x69, 0x7d, 0x09, 0x06, + 0x0a, 0x43, 0x63, 0x2a, 0xe2, 0xd9, 0xaa, 0x7b, 0xed, 0x7b, 0x2d, 0x02, + 0x15, 0x43, 0x9a, 0x7a, 0xdb, 0x7a, 0x12, 0x04, 0x15, 0x43, 0x1b, 0x06, + 0x1d, 0x43, 0xd7, 0xd0, 0x28, 0x1c, 0x00, 0x21, 0xff, 0xf7, 0x6a, 0xfe, + 0x00, 0x28, 0xd1, 0xd0, 0x2a, 0x4b, 0x19, 0x7b, 0xda, 0x7a, 0x09, 0x02, + 0x11, 0x43, 0x80, 0x22, 0x92, 0x00, 0x91, 0x42, 0xc8, 0xd1, 0x1a, 0x7c, + 0x00, 0x2a, 0xc5, 0xd0, 0xd9, 0x89, 0x00, 0x29, 0xc2, 0xd0, 0x59, 0x7b, + 0x00, 0x29, 0xbf, 0xd0, 0x22, 0x76, 0x00, 0x22, 0x21, 0x71, 0x22, 0x74, + 0x22, 0x7c, 0x01, 0x20, 0x90, 0x40, 0x81, 0x42, 0x04, 0xd0, 0x50, 0x1c, + 0x20, 0x74, 0x07, 0x2a, 0xf6, 0xd9, 0xb1, 0xe7, 0xd9, 0x8a, 0x00, 0x29, + 0x00, 0xd1, 0x59, 0x6a, 0xa1, 0x60, 0xd8, 0x89, 0x28, 0x18, 0xe0, 0x61, + 0x1f, 0x69, 0x3e, 0x02, 0x36, 0x0c, 0x66, 0x84, 0xb7, 0xb2, 0x1e, 0x7c, + 0x71, 0x43, 0x0e, 0x18, 0x13, 0x48, 0x79, 0x01, 0x09, 0x18, 0x49, 0x12, + 0x71, 0x18, 0x66, 0x62, 0x61, 0x61, 0x18, 0x7d, 0xde, 0x7c, 0x00, 0x02, + 0x30, 0x43, 0x00, 0xd1, 0x18, 0x6a, 0x6d, 0x1a, 0x28, 0x18, 0xd0, 0x40, + 0x02, 0x1c, 0xe0, 0x60, 0x0b, 0x48, 0x61, 0x1c, 0x82, 0x42, 0x01, 0xd8, + 0x0c, 0x23, 0x07, 0xe0, 0x09, 0x48, 0x82, 0x42, 0x01, 0xd8, 0x10, 0x23, + 0x02, 0xe0, 0xdb, 0x6a, 0x63, 0x62, 0x20, 0x23, 0xcb, 0x77, 0x01, 0x20, + 0xf8, 0xbd, 0xc0, 0x46, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0xff, 0x01, 0x00, 0x00, 0xf4, 0x0f, 0x00, 0x00, 0xf4, 0xff, 0x00, 0x00, + 0x08, 0xb5, 0x05, 0x49, 0x05, 0x4a, 0x06, 0x48, 0x00, 0xf0, 0x10, 0xf8, + 0x05, 0x4b, 0x06, 0x49, 0x00, 0x22, 0x1a, 0x70, 0x5a, 0x54, 0x08, 0xbd, + 0x00, 0x50, 0x00, 0x00, 0x01, 0x04, 0x00, 0x00, 0x54, 0x03, 0x00, 0x20, + 0x6c, 0x03, 0x00, 0x20, 0x02, 0x04, 0x00, 0x00, 0x30, 0xb5, 0x09, 0x4c, + 0x09, 0x4b, 0xa5, 0x68, 0x6d, 0x03, 0x6d, 0x0f, 0xad, 0x00, 0xeb, 0x58, + 0x03, 0x60, 0xa4, 0x68, 0x01, 0x61, 0xa4, 0xb2, 0x44, 0x60, 0x5c, 0x43, + 0x9b, 0x00, 0x84, 0x60, 0xc3, 0x60, 0x42, 0x61, 0x30, 0xbd, 0xc0, 0x46, + 0x00, 0x40, 0x00, 0x41, 0x00, 0x55, 0x00, 0x00, 0xf7, 0xb5, 0x1f, 0x4e, + 0x80, 0x27, 0x75, 0x68, 0x03, 0x33, 0x3d, 0x43, 0x9b, 0x08, 0x75, 0x60, + 0x00, 0x2b, 0x34, 0xd0, 0x1b, 0x4d, 0x35, 0x80, 0x35, 0x7d, 0xef, 0x07, + 0xfc, 0xd5, 0x1d, 0x1c, 0x5f, 0x1b, 0x01, 0x97, 0x07, 0x68, 0xbf, 0x08, + 0xbc, 0x46, 0x01, 0x9f, 0x67, 0x45, 0x1f, 0xd2, 0x00, 0x2d, 0x1d, 0xd0, + 0x17, 0x78, 0x01, 0x3d, 0x01, 0x97, 0xff, 0x27, 0xbc, 0x43, 0x01, 0x9f, + 0x3c, 0x43, 0x57, 0x78, 0x3f, 0x02, 0x01, 0x97, 0x0f, 0x4f, 0x3c, 0x40, + 0x01, 0x9f, 0x3c, 0x43, 0x97, 0x78, 0x3f, 0x04, 0xbc, 0x46, 0x0d, 0x4f, + 0x3c, 0x40, 0xd7, 0x78, 0xa4, 0xb2, 0x3f, 0x06, 0x00, 0x97, 0x67, 0x46, + 0x3c, 0x43, 0x00, 0x9f, 0x04, 0x32, 0x3c, 0x43, 0x10, 0xc1, 0xd7, 0xe7, + 0x07, 0x4b, 0x33, 0x80, 0x33, 0x7d, 0xdf, 0x07, 0xfc, 0xd5, 0x2b, 0x1c, + 0xc8, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x44, 0xa5, 0xff, 0xff, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, 0x04, 0xa5, 0xff, 0xff, + 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, 0x1a, 0x80, 0x1a, 0x7d, + 0xd1, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x16, 0x1c, + 0xeb, 0x68, 0x28, 0x1c, 0x21, 0x1c, 0x9e, 0x42, 0x05, 0xd9, 0xff, 0xf7, + 0xe7, 0xff, 0xeb, 0x68, 0xe4, 0x18, 0xf6, 0x1a, 0xf4, 0xe7, 0xff, 0xf7, + 0xe1, 0xff, 0x70, 0xbd, 0x43, 0x7a, 0x00, 0x2b, 0x04, 0xd1, 0x83, 0x72, + 0xc3, 0x72, 0xc3, 0x60, 0x01, 0x23, 0x43, 0x72, 0x70, 0x47, 0x30, 0xb5, + 0x85, 0xb0, 0x04, 0x1c, 0x02, 0xad, 0x00, 0x68, 0x02, 0x91, 0x03, 0x92, + 0x00, 0xf0, 0x88, 0xfc, 0x6b, 0x79, 0xe1, 0x79, 0x22, 0x7a, 0x00, 0x93, + 0x20, 0x68, 0x00, 0x23, 0x00, 0xf0, 0x22, 0xfd, 0x29, 0x79, 0x20, 0x68, + 0x02, 0x9a, 0x00, 0xf0, 0x4b, 0xfc, 0x20, 0x68, 0x00, 0xf0, 0x6e, 0xfc, + 0x05, 0xb0, 0x30, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0x18, 0x26, 0xff, 0xf7, + 0xd7, 0xff, 0x20, 0x79, 0x33, 0x1c, 0x43, 0x43, 0x0d, 0x4d, 0x08, 0x21, + 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x08, 0xfb, 0xa0, 0x79, 0x33, 0x1c, + 0x43, 0x43, 0x08, 0x21, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x00, 0xfb, + 0x60, 0x79, 0x08, 0x21, 0x46, 0x43, 0xad, 0x19, 0x69, 0x56, 0x00, 0xf0, + 0xf9, 0xfa, 0x04, 0x4b, 0x20, 0x1c, 0x06, 0xcb, 0xff, 0xf7, 0xc3, 0xff, + 0x70, 0xbd, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, 0x70, 0x07, 0x00, 0x20, + 0x07, 0xb5, 0x83, 0x7a, 0x00, 0x91, 0x01, 0x92, 0x00, 0x2b, 0x0d, 0xd0, + 0x9a, 0x07, 0x06, 0xd5, 0xef, 0xf3, 0x10, 0x83, 0x5a, 0x42, 0x53, 0x41, + 0xc3, 0x72, 0x72, 0xb6, 0x04, 0xe0, 0xda, 0x07, 0x02, 0xd5, 0x82, 0x89, + 0x03, 0x4b, 0x9a, 0x60, 0x00, 0x99, 0x01, 0x9a, 0xff, 0xf7, 0xa5, 0xff, + 0x07, 0xbd, 0xc0, 0x46, 0x00, 0x18, 0x00, 0x40, 0x83, 0x7a, 0x00, 0x2b, + 0x0b, 0xd0, 0x9a, 0x07, 0x04, 0xd5, 0xc3, 0x7a, 0x00, 0x2b, 0x06, 0xd0, + 0x62, 0xb6, 0x04, 0xe0, 0xda, 0x07, 0x02, 0xd5, 0x82, 0x89, 0x01, 0x4b, + 0xda, 0x60, 0x70, 0x47, 0x00, 0x18, 0x00, 0x40, 0x08, 0xb5, 0x00, 0x68, + 0x00, 0xf0, 0x25, 0xfc, 0x08, 0xbd, 0x00, 0x00, 0x0f, 0x4b, 0x10, 0x4a, + 0x10, 0x49, 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x0f, 0x4b, + 0x0f, 0x48, 0x19, 0x60, 0x0a, 0x21, 0x19, 0x71, 0x09, 0x21, 0x99, 0x71, + 0x08, 0x21, 0x59, 0x71, 0x03, 0x21, 0x5a, 0x72, 0xda, 0x71, 0x19, 0x72, + 0x0a, 0x4b, 0x18, 0x60, 0x1d, 0x20, 0x18, 0x71, 0x1b, 0x20, 0x98, 0x71, + 0x1a, 0x20, 0x5a, 0x72, 0x58, 0x71, 0xda, 0x71, 0x19, 0x72, 0x70, 0x47, + 0x70, 0x07, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, 0x5c, 0x08, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x60, 0x08, 0x00, 0x20, 0x88, 0x07, 0x00, 0x20, + 0x08, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x66, 0xfd, 0x08, 0xbd, 0xc0, 0x46, + 0x98, 0x07, 0x00, 0x20, 0x13, 0xb5, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, + 0x31, 0xfb, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, 0x2d, 0xfb, 0x12, 0x49, + 0x12, 0x48, 0x00, 0xf0, 0x29, 0xfb, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, + 0x25, 0xfb, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, 0x21, 0xfb, 0x12, 0x4c, + 0x12, 0x49, 0x20, 0x1c, 0x00, 0xf0, 0x1c, 0xfb, 0x03, 0x23, 0x00, 0x93, + 0x01, 0x23, 0x01, 0x93, 0x21, 0x1c, 0x0d, 0x22, 0x0e, 0x23, 0x0e, 0x48, + 0x00, 0xf0, 0x2c, 0xfd, 0x13, 0xbd, 0xc0, 0x46, 0x00, 0x08, 0x00, 0x42, + 0x58, 0x08, 0x00, 0x20, 0x00, 0x0c, 0x00, 0x42, 0x5c, 0x08, 0x00, 0x20, + 0x00, 0x10, 0x00, 0x42, 0x60, 0x08, 0x00, 0x20, 0x00, 0x14, 0x00, 0x42, + 0x54, 0x08, 0x00, 0x20, 0x00, 0x18, 0x00, 0x42, 0x64, 0x08, 0x00, 0x20, + 0x68, 0x08, 0x00, 0x20, 0x00, 0x1c, 0x00, 0x42, 0x98, 0x07, 0x00, 0x20, + 0xfe, 0xe7, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x4b, 0x1b, 0x68, 0x00, 0x2b, + 0x00, 0xd0, 0x98, 0x47, 0x08, 0xbd, 0xc0, 0x46, 0x6c, 0x08, 0x00, 0x20, + 0x38, 0xb5, 0x0f, 0x49, 0x0f, 0x4c, 0xa1, 0x42, 0x04, 0xd1, 0x00, 0xf0, + 0x4f, 0xf8, 0xfe, 0xf7, 0xbf, 0xfa, 0x0b, 0xe0, 0x0c, 0x4d, 0x8d, 0x42, + 0xf7, 0xd0, 0x00, 0x23, 0xca, 0x18, 0xe8, 0x18, 0xa2, 0x42, 0x04, 0xd2, + 0x00, 0x68, 0x04, 0x33, 0x10, 0x60, 0xf7, 0xe7, 0xfe, 0xe7, 0x90, 0x42, + 0xeb, 0xd0, 0x06, 0x4b, 0x06, 0x4a, 0x93, 0x42, 0xe7, 0xd2, 0x00, 0x22, + 0x04, 0xc3, 0xf9, 0xe7, 0x00, 0x00, 0x00, 0x20, 0xa0, 0x00, 0x00, 0x20, + 0x48, 0x59, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x20, 0x50, 0x0d, 0x00, 0x20, + 0x08, 0xb5, 0x00, 0xf0, 0x26, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x00, 0xf0, + 0x17, 0xf8, 0x08, 0xbd, 0x01, 0x4b, 0x18, 0x68, 0x70, 0x47, 0xc0, 0x46, + 0x70, 0x08, 0x00, 0x20, 0x70, 0xb5, 0x04, 0x1e, 0x08, 0xd0, 0x05, 0x4b, + 0x1d, 0x68, 0x1e, 0x1c, 0x00, 0xf0, 0x12, 0xf8, 0x33, 0x68, 0x5b, 0x1b, + 0xa3, 0x42, 0xf9, 0xd3, 0x70, 0xbd, 0xc0, 0x46, 0x70, 0x08, 0x00, 0x20, + 0x08, 0xb5, 0x03, 0x4b, 0x1a, 0x68, 0x01, 0x32, 0x1a, 0x60, 0x00, 0xf0, + 0x61, 0xfa, 0x08, 0xbd, 0x70, 0x08, 0x00, 0x20, 0x70, 0x47, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x00, 0x70, 0xb5, 0x49, 0x4a, 0x1e, 0x21, 0x53, 0x68, + 0x02, 0x20, 0x8b, 0x43, 0x03, 0x43, 0x47, 0x49, 0x53, 0x60, 0x8b, 0x69, + 0x08, 0x24, 0x23, 0x43, 0x8b, 0x61, 0x45, 0x4c, 0x45, 0x4b, 0x9c, 0x82, + 0x9c, 0x8a, 0x20, 0x43, 0x98, 0x82, 0x10, 0x1c, 0xda, 0x68, 0x94, 0x07, + 0xfc, 0xd5, 0x42, 0x4a, 0x01, 0x24, 0x14, 0x70, 0x14, 0x78, 0xe5, 0x07, + 0x04, 0xd5, 0x3f, 0x4c, 0x64, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xf7, 0xdb, + 0x01, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, + 0x3a, 0x4d, 0x39, 0x4c, 0x65, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x82, 0x25, 0x35, 0x4c, 0xed, 0x01, 0x65, 0x80, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x02, 0x24, 0x9c, 0x84, 0xdc, 0x68, + 0xe6, 0x06, 0xfc, 0xd5, 0x31, 0x4d, 0x2e, 0x4c, 0xe5, 0x62, 0xdd, 0x68, + 0x2c, 0x4c, 0xee, 0x06, 0xfb, 0xd5, 0xa5, 0x8c, 0x2e, 0x4e, 0x35, 0x43, + 0xa5, 0x84, 0xdd, 0x68, 0x28, 0x4c, 0xee, 0x06, 0xfb, 0xd5, 0xa5, 0x8c, + 0x02, 0x26, 0x35, 0x43, 0xa5, 0x84, 0xdc, 0x68, 0x25, 0x06, 0xfc, 0xd5, + 0x23, 0x4c, 0xe4, 0x68, 0x66, 0x06, 0xf8, 0xd5, 0xdc, 0x68, 0xe5, 0x06, + 0xfc, 0xd5, 0x00, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x22, 0x4d, 0x1d, 0x4c, 0x65, 0x60, 0x55, 0x78, 0x1c, 0x4c, + 0x6d, 0xb2, 0x00, 0x2d, 0xfa, 0xdb, 0x1e, 0x6a, 0x1e, 0x4d, 0x35, 0x40, + 0x1d, 0x62, 0x1d, 0x6a, 0x80, 0x26, 0xb5, 0x43, 0x1d, 0x62, 0x03, 0x23, + 0xa3, 0x60, 0x1b, 0x4b, 0x63, 0x60, 0x53, 0x78, 0x5b, 0xb2, 0x00, 0x2b, + 0xfb, 0xdb, 0x00, 0x23, 0x0b, 0x72, 0x18, 0x4a, 0x4b, 0x72, 0x8b, 0x72, + 0xcb, 0x72, 0x17, 0x4b, 0xff, 0x21, 0x1a, 0x60, 0x16, 0x4b, 0x17, 0x4a, + 0x1b, 0x68, 0x12, 0x68, 0x5c, 0x01, 0xd2, 0x0e, 0x21, 0x40, 0x11, 0x43, + 0x9a, 0x06, 0x52, 0x0f, 0x12, 0x02, 0x0b, 0x1c, 0x13, 0x43, 0x12, 0x4a, + 0x13, 0x85, 0x43, 0x68, 0x80, 0x22, 0x13, 0x43, 0x43, 0x60, 0x70, 0xbd, + 0x00, 0x40, 0x00, 0x41, 0x00, 0x04, 0x00, 0x40, 0x0c, 0x06, 0x00, 0x00, + 0x00, 0x08, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, 0x01, 0x05, 0x01, 0x00, + 0xb9, 0x05, 0xff, 0x7d, 0x04, 0x0a, 0x00, 0x00, 0x00, 0x07, 0x03, 0x00, + 0xff, 0xfc, 0xff, 0xff, 0x03, 0x06, 0x01, 0x00, 0x00, 0x6c, 0xdc, 0x02, + 0x04, 0x00, 0x00, 0x20, 0x24, 0x60, 0x80, 0x00, 0x20, 0x60, 0x80, 0x00, + 0x00, 0x40, 0x00, 0x42, 0x31, 0x4b, 0xfa, 0x21, 0x18, 0x68, 0x10, 0xb5, + 0x89, 0x00, 0x00, 0xf0, 0xe3, 0xfe, 0x2f, 0x4b, 0x01, 0x38, 0x98, 0x42, + 0x24, 0xd8, 0x2e, 0x4a, 0x2e, 0x4b, 0x50, 0x60, 0x18, 0x6a, 0xc0, 0x21, + 0x00, 0x02, 0x00, 0x0a, 0x09, 0x06, 0x01, 0x43, 0x19, 0x62, 0x00, 0x24, + 0x07, 0x21, 0x94, 0x60, 0x11, 0x60, 0x19, 0x6a, 0x80, 0x22, 0x09, 0x02, + 0x09, 0x0a, 0x12, 0x06, 0x0a, 0x43, 0x1a, 0x62, 0x25, 0x4b, 0xfc, 0x21, + 0x1a, 0x6a, 0x0a, 0x43, 0x1a, 0x62, 0x19, 0x6a, 0xfc, 0x22, 0x92, 0x01, + 0x0a, 0x43, 0x1a, 0x62, 0x19, 0x6a, 0xa0, 0x22, 0xd2, 0x02, 0x0a, 0x43, + 0x1a, 0x62, 0x00, 0xe0, 0xfe, 0xe7, 0x20, 0x1c, 0x00, 0x21, 0x01, 0x34, + 0x00, 0xf0, 0x70, 0xf8, 0x0f, 0x2c, 0xf8, 0xd1, 0x1a, 0x4c, 0x63, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfa, 0xdb, 0x19, 0x4b, 0x63, 0x80, 0x19, 0x4b, + 0x5a, 0x7e, 0xd2, 0x09, 0x01, 0x2a, 0xfa, 0xd0, 0xe4, 0x22, 0xd2, 0x00, + 0x9a, 0x80, 0x3f, 0x22, 0xda, 0x70, 0x59, 0x7e, 0x13, 0x4a, 0xc9, 0x09, + 0x01, 0x29, 0xfa, 0xd0, 0xc0, 0x23, 0x5b, 0x01, 0x00, 0x20, 0x13, 0x61, + 0x90, 0x70, 0x00, 0xf0, 0x23, 0xf8, 0x63, 0x78, 0x5b, 0xb2, 0x00, 0x2b, + 0xfb, 0xdb, 0x0d, 0x4a, 0x09, 0x4b, 0x5a, 0x80, 0x0c, 0x4b, 0xda, 0x79, + 0xd2, 0x09, 0x01, 0x2a, 0xfa, 0xd0, 0x41, 0x22, 0x5a, 0x70, 0x10, 0xbd, + 0x04, 0x00, 0x00, 0x20, 0xff, 0xff, 0xff, 0x00, 0x10, 0xe0, 0x00, 0xe0, + 0x00, 0xed, 0x00, 0xe0, 0x00, 0x04, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, + 0x1e, 0x40, 0x00, 0x00, 0x00, 0x40, 0x00, 0x42, 0x21, 0x40, 0x00, 0x00, + 0x00, 0x48, 0x00, 0x42, 0x00, 0xb5, 0x14, 0x4a, 0x51, 0x7e, 0x13, 0x1c, + 0xc9, 0x09, 0x01, 0x29, 0xf9, 0xd0, 0x01, 0x38, 0x04, 0x28, 0x13, 0xd8, + 0x19, 0x69, 0x10, 0x4a, 0x0a, 0x40, 0x1a, 0x61, 0x5a, 0x78, 0x0f, 0x21, + 0x8a, 0x43, 0x00, 0xf0, 0x55, 0xfe, 0x03, 0x05, 0x09, 0x07, 0x03, 0x00, + 0x01, 0x21, 0x02, 0xe0, 0x03, 0x21, 0x00, 0xe0, 0x02, 0x21, 0x0a, 0x43, + 0x5a, 0x70, 0x0a, 0xe0, 0x11, 0x69, 0xf0, 0x23, 0x1b, 0x05, 0x0b, 0x43, + 0x13, 0x61, 0x53, 0x78, 0x0f, 0x21, 0x8b, 0x43, 0x02, 0x21, 0x0b, 0x43, + 0x53, 0x70, 0x00, 0xbd, 0x00, 0x40, 0x00, 0x42, 0xff, 0xff, 0xff, 0xf0, + 0x10, 0xb5, 0x18, 0x24, 0x02, 0x1c, 0x20, 0x1c, 0x50, 0x43, 0x27, 0x4b, + 0x18, 0x18, 0x00, 0x7a, 0x40, 0xb2, 0x01, 0x30, 0x46, 0xd0, 0x03, 0x29, + 0x44, 0xd8, 0x08, 0x1c, 0x21, 0x1c, 0x00, 0xf0, 0x29, 0xfe, 0x02, 0x33, + 0x11, 0x21, 0x62, 0x43, 0x98, 0x56, 0x9a, 0x18, 0xc3, 0x01, 0x1f, 0x48, + 0x52, 0x68, 0x1b, 0x18, 0x99, 0x18, 0x40, 0x31, 0x02, 0x20, 0x08, 0x70, + 0x01, 0x21, 0x91, 0x40, 0x59, 0x60, 0x2f, 0xe0, 0x62, 0x43, 0x98, 0x56, + 0x18, 0x49, 0x9a, 0x18, 0x52, 0x68, 0xc3, 0x01, 0x5b, 0x18, 0x99, 0x18, + 0x40, 0x31, 0x06, 0x20, 0x08, 0x70, 0x01, 0x21, 0x91, 0x40, 0x59, 0x60, + 0x99, 0x61, 0x1f, 0xe0, 0x51, 0x43, 0x5a, 0x56, 0x10, 0x48, 0x59, 0x18, + 0x4b, 0x68, 0xd2, 0x01, 0x11, 0x18, 0xc8, 0x18, 0x40, 0x30, 0x06, 0x24, + 0x04, 0x70, 0x01, 0x20, 0x98, 0x40, 0x48, 0x60, 0x0b, 0x49, 0x52, 0x18, + 0x50, 0x60, 0x0d, 0xe0, 0x62, 0x43, 0x98, 0x56, 0x9a, 0x18, 0xc3, 0x01, + 0x06, 0x48, 0x52, 0x68, 0x1b, 0x18, 0x99, 0x18, 0x40, 0x31, 0x02, 0x20, + 0x08, 0x70, 0x01, 0x21, 0x91, 0x40, 0x99, 0x60, 0x10, 0xbd, 0xc0, 0x46, + 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0x10, 0x44, 0x00, 0x41, + 0x18, 0x23, 0x58, 0x43, 0x13, 0x4a, 0xf0, 0xb5, 0x13, 0x18, 0x08, 0x24, + 0x1c, 0x57, 0x01, 0x34, 0x1f, 0xd0, 0x82, 0x56, 0x10, 0x4e, 0xd2, 0x01, + 0x5d, 0x68, 0x01, 0x24, 0x90, 0x19, 0x23, 0x1c, 0x86, 0x68, 0xab, 0x40, + 0x1e, 0x42, 0x0b, 0xd1, 0x0e, 0x1c, 0x77, 0x1e, 0xbe, 0x41, 0x40, 0x19, + 0x34, 0x40, 0x40, 0x30, 0xa5, 0x00, 0x04, 0x78, 0x04, 0x26, 0xb4, 0x43, + 0x2c, 0x43, 0x04, 0x70, 0x00, 0x29, 0x03, 0xd1, 0x05, 0x49, 0x52, 0x18, + 0x53, 0x60, 0x02, 0xe0, 0x02, 0x4e, 0x92, 0x19, 0x93, 0x61, 0xf0, 0xbd, + 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0x10, 0x44, 0x00, 0x41, + 0x18, 0x22, 0x42, 0x43, 0xf8, 0xb5, 0x2d, 0x4d, 0x08, 0x24, 0xaa, 0x18, + 0x14, 0x57, 0x03, 0x1c, 0x62, 0x1c, 0x50, 0xd0, 0x48, 0x1c, 0x00, 0x24, + 0x0c, 0x28, 0x4c, 0xd8, 0x00, 0xf0, 0xa0, 0xfd, 0x07, 0x1e, 0x1e, 0x1e, + 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x0a, 0x0a, 0x0a, 0x0a, 0x00, 0x01, 0x24, + 0x64, 0x42, 0x40, 0xe0, 0x09, 0x29, 0x02, 0xd1, 0x18, 0x1c, 0x00, 0x21, + 0x03, 0xe0, 0x0a, 0x29, 0x04, 0xd1, 0x18, 0x1c, 0x02, 0x21, 0xff, 0xf7, + 0x51, 0xff, 0x23, 0xe0, 0x00, 0x24, 0x0b, 0x29, 0x31, 0xd1, 0x18, 0x1c, + 0x01, 0x21, 0xff, 0xf7, 0x49, 0xff, 0x2c, 0xe0, 0x18, 0x22, 0x53, 0x43, + 0xea, 0x18, 0x52, 0x68, 0xeb, 0x56, 0x01, 0x20, 0x14, 0x1c, 0x04, 0x40, + 0x55, 0x08, 0xdb, 0x01, 0x00, 0x2c, 0x11, 0xd0, 0x12, 0x4c, 0x1b, 0x19, + 0x5d, 0x19, 0x30, 0x35, 0x2e, 0x78, 0x0c, 0x01, 0x0f, 0x21, 0x31, 0x40, + 0x21, 0x43, 0x9a, 0x18, 0xc9, 0xb2, 0x29, 0x70, 0x40, 0x32, 0x13, 0x78, + 0x18, 0x43, 0x10, 0x70, 0x00, 0x24, 0x0e, 0xe0, 0x09, 0x4e, 0x0f, 0x27, + 0x9b, 0x19, 0x5d, 0x19, 0x30, 0x35, 0x2e, 0x78, 0x9a, 0x18, 0xbe, 0x43, + 0x31, 0x43, 0xc9, 0xb2, 0x29, 0x70, 0x40, 0x32, 0x13, 0x78, 0x18, 0x43, + 0x10, 0x70, 0x20, 0x1c, 0xf8, 0xbd, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, + 0x00, 0x44, 0x00, 0x41, 0xf7, 0xb5, 0x8a, 0x18, 0x06, 0x1c, 0x0d, 0x1c, + 0x01, 0x92, 0x0c, 0x1c, 0x01, 0x9b, 0x67, 0x1b, 0x9c, 0x42, 0x07, 0xd0, + 0x33, 0x68, 0x21, 0x78, 0x1b, 0x68, 0x30, 0x1c, 0x98, 0x47, 0x01, 0x34, + 0x00, 0x28, 0xf3, 0xd1, 0x38, 0x1c, 0xfe, 0xbd, 0x15, 0x4a, 0x13, 0x68, + 0x58, 0x1c, 0x25, 0xd0, 0x01, 0x3b, 0x13, 0x60, 0x00, 0x2b, 0x21, 0xd1, + 0x72, 0xb6, 0x12, 0x4a, 0x12, 0x4b, 0x04, 0x32, 0x9a, 0x42, 0x07, 0xd8, + 0xbf, 0xf3, 0x4f, 0x8f, 0x10, 0x4a, 0x11, 0x4b, 0xda, 0x60, 0xbf, 0xf3, + 0x4f, 0x8f, 0x11, 0xe0, 0x0f, 0x4b, 0x19, 0x7d, 0xc8, 0x07, 0xfb, 0xd5, + 0x18, 0x8b, 0x20, 0x21, 0xff, 0x31, 0x92, 0x08, 0x52, 0x00, 0x01, 0x43, + 0x19, 0x83, 0xda, 0x61, 0x0a, 0x4a, 0x1a, 0x80, 0x1a, 0x7d, 0xd1, 0x07, + 0xfc, 0xd5, 0xe5, 0xe7, 0xc0, 0x46, 0xfd, 0xe7, 0x70, 0x47, 0xc0, 0x46, + 0x08, 0x00, 0x00, 0x20, 0x00, 0x20, 0x00, 0x00, 0x03, 0x02, 0x00, 0x00, + 0x04, 0x00, 0xfa, 0x05, 0x00, 0xed, 0x00, 0xe0, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x01, 0x60, 0x70, 0x47, 0xf7, 0xb5, 0x08, 0xac, + 0x26, 0x78, 0x04, 0x68, 0x9d, 0x1e, 0x27, 0x68, 0x6c, 0x1e, 0xa5, 0x41, + 0xec, 0xb2, 0x92, 0x07, 0x05, 0x68, 0x3a, 0x43, 0x27, 0x06, 0x3a, 0x43, + 0x2a, 0x60, 0x02, 0x68, 0x07, 0x25, 0x29, 0x40, 0x50, 0x68, 0xb5, 0x01, + 0x00, 0x2c, 0x00, 0xd0, 0x5c, 0x03, 0x29, 0x43, 0x01, 0x43, 0x0c, 0x43, + 0x54, 0x60, 0xf7, 0xbd, 0x30, 0xb5, 0x03, 0x68, 0xc0, 0x25, 0x1c, 0x68, + 0xad, 0x03, 0x12, 0x05, 0x2a, 0x40, 0x22, 0x43, 0xc0, 0x24, 0xa4, 0x02, + 0x09, 0x04, 0x21, 0x40, 0x11, 0x43, 0x19, 0x60, 0x03, 0x68, 0x5a, 0x68, + 0x14, 0x43, 0x5c, 0x60, 0x30, 0xbd, 0x03, 0x68, 0x01, 0x21, 0x1a, 0x68, + 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, 0x11, 0x68, 0x01, 0x23, 0x19, 0x42, + 0xfb, 0xd1, 0xd1, 0x69, 0x19, 0x42, 0xf8, 0xd1, 0x70, 0x47, 0x03, 0x68, + 0x02, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, 0xd3, 0x69, + 0x99, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd1, 0x07, + 0x02, 0xd4, 0x1a, 0x7e, 0x91, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0x03, 0x68, + 0x00, 0x22, 0x5a, 0x83, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x40, 0x07, + 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x09, 0x70, 0x47, + 0x03, 0x68, 0x80, 0x22, 0x19, 0x7e, 0x52, 0x42, 0x0a, 0x43, 0x1a, 0x76, + 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x01, 0x23, 0x18, 0x40, 0x70, 0x47, + 0x03, 0x68, 0x18, 0x8d, 0xc0, 0xb2, 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, + 0x01, 0x20, 0x02, 0x42, 0xfb, 0xd0, 0x19, 0x85, 0x70, 0x47, 0x03, 0x68, + 0x01, 0x21, 0x9a, 0x7d, 0x0a, 0x43, 0x9a, 0x75, 0x70, 0x47, 0x03, 0x68, + 0x01, 0x22, 0x1a, 0x75, 0x70, 0x47, 0x00, 0x00, 0x70, 0xb5, 0x03, 0x68, + 0x01, 0x26, 0x8d, 0x07, 0xed, 0x0f, 0x31, 0x40, 0x1c, 0x68, 0x6d, 0x07, + 0x09, 0x07, 0x29, 0x43, 0x21, 0x43, 0x19, 0x60, 0x04, 0x68, 0x51, 0x00, + 0x03, 0x48, 0x00, 0xf0, 0x79, 0xfc, 0x01, 0x38, 0xc0, 0xb2, 0x20, 0x73, + 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x6c, 0xdc, 0x02, 0x03, 0x68, 0x01, 0x21, + 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, 0x11, 0x68, 0x01, 0x23, + 0x19, 0x42, 0xfb, 0xd1, 0xd1, 0x69, 0x19, 0x42, 0xf8, 0xd1, 0x70, 0x47, + 0x03, 0x68, 0x02, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, + 0xd3, 0x69, 0x99, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, 0xda, 0x69, + 0x91, 0x07, 0xfc, 0xd4, 0x1a, 0x68, 0x02, 0x21, 0x8a, 0x43, 0x1a, 0x60, + 0x70, 0x47, 0x03, 0x68, 0x9a, 0x6a, 0x52, 0x0a, 0x52, 0x02, 0x11, 0x43, + 0x99, 0x62, 0x03, 0x68, 0x1a, 0x7e, 0x51, 0x07, 0xfc, 0xd5, 0x98, 0x6a, + 0xc0, 0xb2, 0x70, 0x47, 0x03, 0x68, 0x22, 0x4a, 0x30, 0xb5, 0x93, 0x42, + 0x11, 0xd0, 0x21, 0x4a, 0x93, 0x42, 0x11, 0xd0, 0x20, 0x4a, 0x93, 0x42, + 0x11, 0xd0, 0x20, 0x4a, 0x93, 0x42, 0x11, 0xd0, 0x1f, 0x4a, 0x93, 0x42, + 0x11, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x30, 0xd1, 0x0e, 0x23, 0x19, 0x22, + 0x0d, 0xe0, 0x09, 0x23, 0x14, 0x22, 0x0a, 0xe0, 0x0a, 0x23, 0x15, 0x22, + 0x07, 0xe0, 0x0b, 0x23, 0x16, 0x22, 0x04, 0xe0, 0x0c, 0x23, 0x17, 0x22, + 0x01, 0xe0, 0x0d, 0x23, 0x18, 0x22, 0xdc, 0xb2, 0x15, 0x49, 0x01, 0x20, + 0x9b, 0x08, 0xa0, 0x40, 0x9b, 0x00, 0x08, 0x60, 0x5b, 0x18, 0x03, 0x20, + 0xc0, 0x21, 0x89, 0x00, 0x04, 0x40, 0x5d, 0x58, 0xe0, 0x00, 0xff, 0x24, + 0x84, 0x40, 0xa5, 0x43, 0x2c, 0x1c, 0xc0, 0x25, 0x85, 0x40, 0x28, 0x1c, + 0x20, 0x43, 0x58, 0x50, 0x80, 0x23, 0xdb, 0x01, 0x1a, 0x43, 0x0a, 0x4b, + 0x5a, 0x80, 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, 0x30, 0xbd, + 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, 0x00, 0x10, 0x00, 0x42, + 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, 0x00, 0x1c, 0x00, 0x42, + 0x00, 0xe1, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x40, 0xf8, 0xb5, 0x04, 0x1c, + 0x15, 0x1c, 0x0e, 0x1c, 0x1f, 0x1c, 0xff, 0xf7, 0xa3, 0xff, 0x20, 0x1c, + 0xff, 0xf7, 0x0b, 0xff, 0xb1, 0x00, 0x1c, 0x22, 0x0a, 0x40, 0x69, 0x07, + 0x23, 0x68, 0x09, 0x0c, 0x0a, 0x43, 0x1a, 0x60, 0x22, 0x68, 0x84, 0x23, + 0x93, 0x75, 0x01, 0x2e, 0x1a, 0xd1, 0x08, 0x21, 0x01, 0x2d, 0x00, 0xd1, + 0x10, 0x21, 0x0c, 0x4b, 0x79, 0x43, 0x18, 0x68, 0xc0, 0x00, 0x00, 0xf0, + 0xcd, 0xfb, 0x23, 0x68, 0x07, 0x21, 0x9a, 0x89, 0x01, 0x40, 0xd2, 0x04, + 0x49, 0x03, 0xd2, 0x0c, 0x0a, 0x43, 0x9a, 0x81, 0x23, 0x68, 0x00, 0x04, + 0xc2, 0x0c, 0x98, 0x89, 0x40, 0x0b, 0x40, 0x03, 0x10, 0x43, 0x98, 0x81, + 0xf8, 0xbd, 0xc0, 0x46, 0x04, 0x00, 0x00, 0x20, 0xf7, 0xb5, 0x01, 0x93, + 0x08, 0xab, 0x04, 0x1c, 0x1f, 0x78, 0x0d, 0x1c, 0x16, 0x1c, 0xff, 0xf7, + 0x3d, 0xff, 0x20, 0x1c, 0xff, 0xf7, 0x68, 0xff, 0xbf, 0x07, 0x0c, 0x22, + 0x17, 0x43, 0xc0, 0x22, 0x92, 0x03, 0x36, 0x05, 0x16, 0x40, 0xc0, 0x22, + 0x92, 0x02, 0x2d, 0x04, 0x23, 0x68, 0x3e, 0x43, 0x01, 0x99, 0x15, 0x40, + 0x35, 0x43, 0x07, 0x22, 0x1d, 0x60, 0x0a, 0x40, 0x80, 0x21, 0x23, 0x68, + 0x89, 0x02, 0x0a, 0x43, 0x5a, 0x60, 0xf7, 0xbd, 0x01, 0x20, 0x70, 0x47, + 0x08, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, 0x98, 0x47, 0x08, 0xbd, + 0x13, 0x04, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, 0x00, 0x69, 0xff, 0xf7, + 0xac, 0xfe, 0x20, 0x1c, 0x14, 0x30, 0x00, 0xf0, 0x41, 0xfb, 0x20, 0x1c, + 0x5c, 0x30, 0x00, 0xf0, 0x3d, 0xfb, 0x10, 0xbd, 0x08, 0xb5, 0x14, 0x30, + 0x00, 0xf0, 0x4a, 0xfb, 0x08, 0xbd, 0x10, 0xb5, 0x04, 0x1c, 0x20, 0x1c, + 0x5c, 0x30, 0x00, 0xf0, 0x43, 0xfb, 0x00, 0x28, 0xf9, 0xd1, 0x20, 0x69, + 0xff, 0xf7, 0xab, 0xfe, 0x10, 0xbd, 0x08, 0xb5, 0x5c, 0x30, 0x00, 0xf0, + 0x3f, 0xfb, 0x08, 0xbd, 0x70, 0xb5, 0x05, 0x1c, 0x14, 0x35, 0x04, 0x1c, + 0x28, 0x1c, 0x00, 0xf0, 0x23, 0xfb, 0x23, 0x1c, 0xa8, 0x33, 0x1b, 0x78, + 0x06, 0x1c, 0xff, 0x2b, 0x0a, 0xd0, 0x28, 0x1c, 0x00, 0xf0, 0x2e, 0xfb, + 0x0a, 0x28, 0x05, 0xdd, 0x23, 0x1c, 0xb0, 0x33, 0xb4, 0x34, 0x1b, 0x68, + 0x22, 0x68, 0x1a, 0x60, 0x30, 0x1c, 0x70, 0xbd, 0x08, 0xb5, 0x14, 0x30, + 0x00, 0xf0, 0x2a, 0xfb, 0x08, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0x00, 0x69, + 0x0e, 0x1c, 0xff, 0xf7, 0x9c, 0xfe, 0x25, 0x1c, 0x5c, 0x35, 0x00, 0x28, + 0x04, 0xd0, 0x28, 0x1c, 0x00, 0xf0, 0x0c, 0xfb, 0x00, 0x28, 0x0c, 0xd0, + 0x28, 0x1c, 0x00, 0xf0, 0x20, 0xfb, 0x00, 0x28, 0xfa, 0xd1, 0x28, 0x1c, + 0x31, 0x1c, 0x00, 0xf0, 0xe4, 0xfa, 0x20, 0x69, 0xff, 0xf7, 0x97, 0xfe, + 0x03, 0xe0, 0x20, 0x69, 0x31, 0x1c, 0xff, 0xf7, 0x8b, 0xfe, 0x01, 0x20, + 0x70, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x85, 0xb0, 0x1d, 0x1c, 0x0a, 0xab, + 0x1b, 0x78, 0x04, 0x1c, 0x00, 0x93, 0x0b, 0xab, 0x1b, 0x78, 0x16, 0x1c, + 0x01, 0x93, 0x0c, 0xab, 0x1b, 0x78, 0x0f, 0x1c, 0x02, 0x93, 0x0d, 0xab, + 0x1b, 0x78, 0x03, 0x93, 0x00, 0x23, 0x43, 0x60, 0xfa, 0x23, 0x9b, 0x00, + 0x83, 0x60, 0x0d, 0x4b, 0x08, 0x33, 0x03, 0x60, 0x14, 0x30, 0x00, 0xf0, + 0xb1, 0xfa, 0x20, 0x1c, 0x5c, 0x30, 0x00, 0xf0, 0xad, 0xfa, 0x00, 0x9a, + 0x23, 0x1c, 0xa4, 0x33, 0x27, 0x61, 0x9a, 0x70, 0x01, 0x9a, 0x20, 0x1c, + 0xda, 0x70, 0x02, 0x9a, 0x1e, 0x70, 0x1a, 0x71, 0x03, 0x9a, 0x5d, 0x70, + 0x1a, 0x75, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0x80, 0x58, 0x00, 0x00, + 0x30, 0xb5, 0x85, 0xb0, 0x04, 0x1c, 0x08, 0xa8, 0x05, 0x78, 0x09, 0xa8, + 0x00, 0x78, 0x00, 0x95, 0x01, 0x90, 0xff, 0x20, 0x02, 0x90, 0x03, 0x90, + 0x20, 0x1c, 0xff, 0xf7, 0xbd, 0xff, 0x20, 0x1c, 0x05, 0xb0, 0x30, 0xbd, + 0x38, 0xb5, 0x04, 0x1c, 0x00, 0x69, 0xff, 0xf7, 0x24, 0xfe, 0x00, 0x28, + 0x19, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x34, 0xfe, 0x25, 0x1c, 0x14, 0x35, + 0x01, 0x1c, 0x28, 0x1c, 0x00, 0xf0, 0x83, 0xfa, 0x23, 0x1c, 0xa8, 0x33, + 0x1b, 0x78, 0xff, 0x2b, 0x0b, 0xd0, 0x28, 0x1c, 0x00, 0xf0, 0x9e, 0xfa, + 0x09, 0x28, 0x06, 0xdc, 0x23, 0x1c, 0x22, 0x1c, 0xac, 0x33, 0xb4, 0x32, + 0x1b, 0x68, 0x12, 0x68, 0x1a, 0x60, 0x20, 0x69, 0xff, 0xf7, 0x15, 0xfe, + 0x00, 0x28, 0x11, 0xd0, 0x25, 0x1c, 0x5c, 0x35, 0x28, 0x1c, 0x00, 0xf0, + 0x85, 0xfa, 0x00, 0x28, 0x07, 0xd0, 0x28, 0x1c, 0x00, 0xf0, 0x72, 0xfa, + 0xc1, 0xb2, 0x20, 0x69, 0xff, 0xf7, 0x0e, 0xfe, 0x02, 0xe0, 0x20, 0x69, + 0xff, 0xf7, 0x17, 0xfe, 0x20, 0x69, 0xff, 0xf7, 0xf3, 0xfd, 0x00, 0x28, + 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0xf2, 0xfd, 0x20, 0x69, 0xff, 0xf7, + 0xe2, 0xfd, 0x38, 0xbd, 0xf0, 0x23, 0x08, 0x1c, 0x18, 0x40, 0x30, 0x38, + 0x43, 0x42, 0x58, 0x41, 0x70, 0x47, 0xf0, 0x23, 0x1b, 0x01, 0x19, 0x40, + 0x80, 0x23, 0x9b, 0x00, 0x99, 0x42, 0x0c, 0xd0, 0xc0, 0x23, 0x9b, 0x00, + 0x99, 0x42, 0x06, 0xd0, 0x80, 0x23, 0x5b, 0x00, 0x05, 0x20, 0x99, 0x42, + 0x04, 0xd0, 0x00, 0x20, 0x02, 0xe0, 0x07, 0x20, 0x00, 0xe0, 0x06, 0x20, + 0x70, 0x47, 0x0f, 0x23, 0x19, 0x40, 0x01, 0x29, 0x05, 0xd0, 0x02, 0x39, + 0x4b, 0x42, 0x4b, 0x41, 0x02, 0x20, 0xc0, 0x1a, 0x00, 0xe0, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x00, 0xf0, 0xb5, 0x03, 0x1c, 0x85, 0xb0, 0x03, 0x91, + 0xa4, 0x33, 0x04, 0x1c, 0x18, 0x27, 0x18, 0x78, 0x3b, 0x1c, 0x43, 0x43, + 0x34, 0x4e, 0x08, 0x21, 0xf3, 0x18, 0x59, 0x56, 0x15, 0x1c, 0xff, 0xf7, + 0xa5, 0xfc, 0x23, 0x1c, 0xa5, 0x33, 0x18, 0x78, 0x3b, 0x1c, 0x43, 0x43, + 0x08, 0x21, 0xf3, 0x18, 0x59, 0x56, 0xff, 0xf7, 0x9b, 0xfc, 0x23, 0x1c, + 0xa7, 0x33, 0x1b, 0x78, 0x02, 0x2b, 0x0a, 0xd1, 0x23, 0x1c, 0xb8, 0x33, + 0x18, 0x78, 0xff, 0x28, 0x05, 0xd0, 0x47, 0x43, 0x08, 0x21, 0xf7, 0x19, + 0x79, 0x56, 0xff, 0xf7, 0x8b, 0xfc, 0x27, 0x1c, 0xa8, 0x37, 0x38, 0x78, + 0xff, 0x28, 0x1a, 0xd0, 0x01, 0x21, 0xff, 0xf7, 0xf9, 0xfb, 0x3b, 0x78, + 0x18, 0x22, 0x5a, 0x43, 0xb3, 0x56, 0x1f, 0x4f, 0xdb, 0x01, 0x21, 0x1c, + 0xac, 0x31, 0xd8, 0x19, 0x08, 0x60, 0x1d, 0x49, 0xb6, 0x18, 0x5b, 0x18, + 0x21, 0x1c, 0x72, 0x68, 0xb0, 0x31, 0x0b, 0x60, 0x01, 0x21, 0x91, 0x40, + 0x0a, 0x1c, 0x21, 0x1c, 0xb4, 0x31, 0x0a, 0x60, 0x1a, 0x60, 0x01, 0x21, + 0x0a, 0x1c, 0x03, 0x9b, 0x20, 0x69, 0xff, 0xf7, 0x31, 0xfe, 0x29, 0x1c, + 0x20, 0x1c, 0xff, 0xf7, 0x88, 0xff, 0x29, 0x1c, 0x07, 0x1c, 0x20, 0x1c, + 0xff, 0xf7, 0x99, 0xff, 0x29, 0x1c, 0x06, 0x1c, 0x20, 0x1c, 0xff, 0xf7, + 0x77, 0xff, 0x39, 0x1c, 0x00, 0x90, 0x33, 0x1c, 0x20, 0x69, 0x01, 0x22, + 0xff, 0xf7, 0x02, 0xfd, 0x23, 0x1c, 0xa7, 0x33, 0x19, 0x78, 0x01, 0x3b, + 0x1a, 0x78, 0x20, 0x69, 0xff, 0xf7, 0x16, 0xfd, 0x20, 0x69, 0xff, 0xf7, + 0x34, 0xfd, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, + 0x18, 0x44, 0x00, 0x41, 0x14, 0x44, 0x00, 0x41, 0x3f, 0x20, 0x70, 0x47, + 0x13, 0xb5, 0x02, 0x68, 0x6b, 0x46, 0xd9, 0x71, 0x07, 0x33, 0x54, 0x68, + 0x19, 0x1c, 0x01, 0x22, 0xa0, 0x47, 0x16, 0xbd, 0x08, 0xb5, 0x00, 0x69, + 0x02, 0x21, 0x00, 0xf0, 0x49, 0xf8, 0x08, 0xbd, 0x08, 0xb5, 0x00, 0x69, + 0x03, 0x21, 0x00, 0xf0, 0x59, 0xf8, 0x08, 0xbd, 0x38, 0xb5, 0x0d, 0x1c, + 0x04, 0x1c, 0x13, 0x1c, 0x00, 0x69, 0x03, 0x21, 0x2a, 0x1c, 0x00, 0xf0, + 0xf1, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x01, 0x23, 0x63, 0x60, 0x38, 0xbd, + 0x10, 0xb5, 0x05, 0x4c, 0x23, 0x68, 0x5a, 0x1c, 0x04, 0xd1, 0x03, 0x68, + 0x5b, 0x69, 0x98, 0x47, 0x20, 0x60, 0x03, 0x1c, 0x18, 0x1c, 0x10, 0xbd, + 0x0c, 0x00, 0x00, 0x20, 0x07, 0x4a, 0x08, 0xb5, 0x13, 0x68, 0x59, 0x1c, + 0x04, 0xd0, 0x01, 0x21, 0x49, 0x42, 0x11, 0x60, 0x18, 0x1c, 0x03, 0xe0, + 0x00, 0x69, 0x02, 0x21, 0x00, 0xf0, 0xc2, 0xf8, 0x08, 0xbd, 0xc0, 0x46, + 0x0c, 0x00, 0x00, 0x20, 0x06, 0x4b, 0xfa, 0x21, 0x89, 0x00, 0x99, 0x60, + 0x05, 0x49, 0x00, 0x22, 0x08, 0x31, 0x19, 0x60, 0x04, 0x49, 0x5a, 0x60, + 0x19, 0x61, 0x1a, 0x76, 0x70, 0x47, 0xc0, 0x46, 0x74, 0x08, 0x00, 0x20, + 0xb8, 0x58, 0x00, 0x00, 0x34, 0x0c, 0x00, 0x20, 0x08, 0xb5, 0x08, 0x4b, + 0x8a, 0x00, 0xd0, 0x58, 0x00, 0x28, 0x03, 0xd0, 0x03, 0x68, 0x9b, 0x68, + 0x98, 0x47, 0x06, 0xe0, 0xc9, 0xb2, 0x04, 0x4b, 0x49, 0x01, 0x59, 0x18, + 0x88, 0x68, 0x80, 0x04, 0x80, 0x0c, 0x08, 0xbd, 0x18, 0x0c, 0x00, 0x20, + 0x38, 0x0c, 0x00, 0x20, 0x10, 0xb5, 0x0c, 0x1c, 0xff, 0xf7, 0xe6, 0xff, + 0x00, 0x28, 0x0c, 0xd0, 0x06, 0x4b, 0xe1, 0xb2, 0x1b, 0x68, 0x08, 0x31, + 0x49, 0x01, 0x59, 0x18, 0x4a, 0x79, 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, + 0x4b, 0x71, 0x02, 0x23, 0xcb, 0x71, 0x10, 0xbd, 0x38, 0x0c, 0x00, 0x20, + 0x10, 0xb5, 0xc9, 0xb2, 0x0c, 0x48, 0x49, 0x01, 0x43, 0x18, 0x9a, 0x68, + 0x92, 0x04, 0x92, 0x0c, 0x3f, 0x2a, 0x08, 0xd9, 0x14, 0x1c, 0x9a, 0x68, + 0x40, 0x3c, 0xa4, 0x04, 0x92, 0x0b, 0xa4, 0x0c, 0x92, 0x03, 0x22, 0x43, + 0x02, 0xe0, 0x9a, 0x68, 0x92, 0x0b, 0x92, 0x03, 0x9a, 0x60, 0x41, 0x18, + 0x88, 0x68, 0xc0, 0xb2, 0x10, 0xbd, 0xc0, 0x46, 0x38, 0x0c, 0x00, 0x20, + 0xf0, 0xb5, 0x1c, 0x1c, 0x2a, 0x4b, 0x85, 0xb0, 0x1b, 0x68, 0x06, 0x1c, + 0x0d, 0x1c, 0x02, 0x92, 0x00, 0x2b, 0x46, 0xd0, 0x27, 0x4b, 0x8a, 0x00, + 0xd0, 0x58, 0x00, 0x28, 0x05, 0xd0, 0x03, 0x68, 0x02, 0x99, 0x5b, 0x68, + 0x22, 0x1c, 0x98, 0x47, 0x3f, 0xe0, 0x30, 0x1c, 0xff, 0xf7, 0x9e, 0xff, + 0xa0, 0x42, 0x04, 0xd2, 0x30, 0x1c, 0x29, 0x1c, 0xff, 0xf7, 0x98, 0xff, + 0x04, 0x1c, 0x29, 0x1c, 0x30, 0x1c, 0xff, 0xf7, 0xbf, 0xff, 0x1c, 0x4f, + 0xe9, 0xb2, 0x4a, 0x01, 0x01, 0x91, 0x39, 0x68, 0x03, 0x92, 0x8b, 0x18, + 0xff, 0x33, 0x5a, 0x7a, 0x01, 0x21, 0x0a, 0x43, 0x17, 0x49, 0x5a, 0x72, + 0xab, 0x01, 0xc9, 0x18, 0x02, 0x98, 0x22, 0x1c, 0x00, 0xf0, 0xb5, 0xf9, + 0x00, 0x2c, 0x1b, 0xd0, 0x30, 0x1c, 0x29, 0x1c, 0xff, 0xf7, 0x7a, 0xff, + 0x00, 0x28, 0x15, 0xd1, 0x01, 0x9b, 0x3a, 0x68, 0x08, 0x33, 0x5b, 0x01, + 0xd3, 0x18, 0x19, 0x79, 0x40, 0x20, 0x01, 0x43, 0x19, 0x71, 0x01, 0x21, + 0xd9, 0x71, 0x03, 0x99, 0x53, 0x18, 0xff, 0x33, 0x9a, 0x7a, 0x01, 0x21, + 0x0a, 0x43, 0x9a, 0x72, 0x02, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x00, 0xe0, + 0x20, 0x1c, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0x3c, 0x0d, 0x00, 0x20, + 0x18, 0x0c, 0x00, 0x20, 0x38, 0x0c, 0x00, 0x20, 0x58, 0x0a, 0x00, 0x20, + 0x13, 0xb5, 0x6c, 0x46, 0x07, 0x34, 0x22, 0x1c, 0x01, 0x23, 0xff, 0xf7, + 0x99, 0xff, 0x01, 0x28, 0x01, 0xd1, 0x20, 0x78, 0x01, 0xe0, 0x01, 0x20, + 0x40, 0x42, 0x16, 0xbd, 0xf0, 0xb5, 0x1c, 0x1c, 0x3a, 0x4b, 0x85, 0xb0, + 0x1b, 0x68, 0x0e, 0x1c, 0x02, 0x92, 0x00, 0x2b, 0x60, 0xd0, 0x80, 0x23, + 0xdb, 0x01, 0x9c, 0x42, 0x5c, 0xd8, 0x00, 0x22, 0x00, 0x92, 0x00, 0x2c, + 0x56, 0xd0, 0x34, 0x4d, 0xf7, 0xb2, 0x2b, 0x68, 0x01, 0x93, 0x3b, 0x1c, + 0x08, 0x33, 0x01, 0x9a, 0x5b, 0x01, 0xd3, 0x18, 0x9b, 0x79, 0xdb, 0x09, + 0x1a, 0xd0, 0x2f, 0x4b, 0x2f, 0x49, 0x18, 0x68, 0x00, 0xf0, 0xc2, 0xf8, + 0x2e, 0x4b, 0x17, 0x21, 0x58, 0x43, 0x00, 0xf0, 0xbd, 0xf8, 0x3b, 0x1c, + 0x08, 0x33, 0x01, 0x9a, 0x5b, 0x01, 0xd3, 0x18, 0xdb, 0x79, 0x9a, 0x07, + 0x08, 0xd4, 0x29, 0x4b, 0x9a, 0x5d, 0x00, 0x2a, 0x38, 0xd1, 0x42, 0x1e, + 0x00, 0x28, 0x35, 0xd0, 0x10, 0x1c, 0xee, 0xe7, 0x24, 0x4b, 0x00, 0x22, + 0x9a, 0x55, 0x25, 0x1e, 0x3f, 0x2d, 0x00, 0xd9, 0x3f, 0x25, 0x22, 0x4a, + 0xb3, 0x01, 0xd3, 0x18, 0x18, 0x1c, 0x02, 0x99, 0x2a, 0x1c, 0x03, 0x93, + 0x00, 0xf0, 0x35, 0xf9, 0x18, 0x4a, 0x7b, 0x01, 0xd3, 0x18, 0x03, 0x9a, + 0xa9, 0x04, 0x5a, 0x61, 0x9a, 0x69, 0x89, 0x0c, 0x92, 0x0b, 0x92, 0x03, + 0x0a, 0x43, 0x9a, 0x61, 0x3b, 0x1c, 0x01, 0x9a, 0x08, 0x33, 0x5b, 0x01, + 0xd3, 0x18, 0x02, 0x22, 0xda, 0x71, 0x59, 0x79, 0x80, 0x22, 0x52, 0x42, + 0x0a, 0x43, 0x5a, 0x71, 0x00, 0x9b, 0x02, 0x9a, 0x5b, 0x19, 0x52, 0x19, + 0x00, 0x93, 0x64, 0x1b, 0x02, 0x92, 0xa6, 0xe7, 0x00, 0x98, 0x0b, 0xe0, + 0x01, 0x20, 0x08, 0xe0, 0x01, 0x22, 0x9a, 0x55, 0x7b, 0x01, 0xed, 0x18, + 0xab, 0x69, 0x10, 0x1c, 0x9b, 0x0b, 0x9b, 0x03, 0xab, 0x61, 0x40, 0x42, + 0x05, 0xb0, 0xf0, 0xbd, 0x3c, 0x0d, 0x00, 0x20, 0x38, 0x0c, 0x00, 0x20, + 0x04, 0x00, 0x00, 0x20, 0x40, 0x42, 0x0f, 0x00, 0x70, 0x11, 0x01, 0x00, + 0x90, 0x08, 0x00, 0x20, 0x98, 0x08, 0x00, 0x20, 0x01, 0x4a, 0x02, 0x4b, + 0x1a, 0x60, 0x70, 0x47, 0x00, 0x50, 0x00, 0x41, 0x38, 0x0c, 0x00, 0x20, + 0x10, 0xb5, 0x00, 0x21, 0x40, 0x22, 0x04, 0x1c, 0x00, 0xf0, 0xf2, 0xf8, + 0x00, 0x23, 0x20, 0x1c, 0x23, 0x64, 0x63, 0x64, 0x10, 0xbd, 0x02, 0x6c, + 0x10, 0xb5, 0x3f, 0x23, 0x54, 0x1c, 0x23, 0x40, 0x44, 0x6c, 0xa3, 0x42, + 0x01, 0xd0, 0x81, 0x54, 0x03, 0x64, 0x10, 0xbd, 0x00, 0x23, 0x03, 0x64, + 0x43, 0x64, 0x70, 0x47, 0x43, 0x6c, 0x02, 0x6c, 0x93, 0x42, 0x06, 0xd0, + 0xc2, 0x5c, 0x3f, 0x21, 0x01, 0x33, 0x0b, 0x40, 0x43, 0x64, 0x10, 0x1c, + 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x70, 0x47, 0x02, 0x6c, 0x43, 0x6c, + 0xd0, 0x1a, 0x00, 0xd5, 0x40, 0x30, 0x70, 0x47, 0x03, 0x6c, 0x40, 0x6c, + 0x83, 0x42, 0x02, 0xdb, 0xc0, 0x1a, 0x3f, 0x30, 0x01, 0xe0, 0xc0, 0x1a, + 0x01, 0x38, 0x70, 0x47, 0x43, 0x6c, 0x02, 0x6c, 0x93, 0x42, 0x01, 0xd0, + 0xc0, 0x5c, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x70, 0x47, 0x02, 0x6c, + 0x3f, 0x23, 0x01, 0x32, 0x1a, 0x40, 0x43, 0x6c, 0xd0, 0x1a, 0x43, 0x42, + 0x58, 0x41, 0xc0, 0xb2, 0x70, 0x47, 0x00, 0x00, 0x02, 0xb4, 0x71, 0x46, + 0x49, 0x08, 0x49, 0x00, 0x09, 0x5c, 0x49, 0x00, 0x8e, 0x44, 0x02, 0xbc, + 0x70, 0x47, 0xc0, 0x46, 0x00, 0x29, 0x34, 0xd0, 0x01, 0x23, 0x00, 0x22, + 0x10, 0xb4, 0x88, 0x42, 0x2c, 0xd3, 0x01, 0x24, 0x24, 0x07, 0xa1, 0x42, + 0x04, 0xd2, 0x81, 0x42, 0x02, 0xd2, 0x09, 0x01, 0x1b, 0x01, 0xf8, 0xe7, + 0xe4, 0x00, 0xa1, 0x42, 0x04, 0xd2, 0x81, 0x42, 0x02, 0xd2, 0x49, 0x00, + 0x5b, 0x00, 0xf8, 0xe7, 0x88, 0x42, 0x01, 0xd3, 0x40, 0x1a, 0x1a, 0x43, + 0x4c, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, 0x5c, 0x08, 0x22, 0x43, + 0x8c, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, 0x9c, 0x08, 0x22, 0x43, + 0xcc, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, 0xdc, 0x08, 0x22, 0x43, + 0x00, 0x28, 0x03, 0xd0, 0x1b, 0x09, 0x01, 0xd0, 0x09, 0x09, 0xe3, 0xe7, + 0x10, 0x1c, 0x10, 0xbc, 0x70, 0x47, 0x00, 0x28, 0x01, 0xd0, 0x00, 0x20, + 0xc0, 0x43, 0x07, 0xb4, 0x02, 0x48, 0x02, 0xa1, 0x40, 0x18, 0x02, 0x90, + 0x03, 0xbd, 0xc0, 0x46, 0x19, 0x00, 0x00, 0x00, 0x00, 0x29, 0xf0, 0xd0, + 0x03, 0xb5, 0xff, 0xf7, 0xb9, 0xff, 0x0e, 0xbc, 0x42, 0x43, 0x89, 0x1a, + 0x18, 0x47, 0xc0, 0x46, 0x70, 0x47, 0xc0, 0x46, 0x70, 0xb5, 0x0e, 0x4b, + 0x0e, 0x4d, 0x00, 0x24, 0xed, 0x1a, 0xad, 0x10, 0x1e, 0x1c, 0xac, 0x42, + 0x04, 0xd0, 0xa3, 0x00, 0xf3, 0x58, 0x98, 0x47, 0x01, 0x34, 0xf8, 0xe7, + 0x00, 0xf0, 0x32, 0xf9, 0x08, 0x4b, 0x09, 0x4d, 0x00, 0x24, 0xed, 0x1a, + 0xad, 0x10, 0x1e, 0x1c, 0xac, 0x42, 0x04, 0xd0, 0xa3, 0x00, 0xf3, 0x58, + 0x98, 0x47, 0x01, 0x34, 0xf8, 0xe7, 0x70, 0xbd, 0x74, 0x00, 0x00, 0x20, + 0x74, 0x00, 0x00, 0x20, 0x74, 0x00, 0x00, 0x20, 0x98, 0x00, 0x00, 0x20, + 0x08, 0xb5, 0x03, 0x4b, 0x01, 0x1c, 0x18, 0x68, 0x00, 0xf0, 0x76, 0xf8, + 0x08, 0xbd, 0xc0, 0x46, 0x70, 0x00, 0x00, 0x20, 0x08, 0xb5, 0x03, 0x4b, + 0x01, 0x1c, 0x18, 0x68, 0x00, 0xf0, 0x24, 0xf8, 0x08, 0xbd, 0xc0, 0x46, + 0x70, 0x00, 0x00, 0x20, 0x30, 0xb5, 0x00, 0x23, 0x93, 0x42, 0x08, 0xd0, + 0xc5, 0x5c, 0x01, 0x33, 0xcc, 0x18, 0x01, 0x3c, 0x24, 0x78, 0xa5, 0x42, + 0xf6, 0xd0, 0x28, 0x1b, 0x00, 0xe0, 0x00, 0x20, 0x30, 0xbd, 0x10, 0xb5, + 0x00, 0x23, 0x93, 0x42, 0x03, 0xd0, 0xcc, 0x5c, 0xc4, 0x54, 0x01, 0x33, + 0xf9, 0xe7, 0x10, 0xbd, 0x03, 0x1c, 0x82, 0x18, 0x93, 0x42, 0x02, 0xd0, + 0x19, 0x70, 0x01, 0x33, 0xfa, 0xe7, 0x70, 0x47, 0x30, 0xb5, 0x00, 0x29, + 0x40, 0xd0, 0x04, 0x39, 0x0b, 0x68, 0x00, 0x2b, 0x00, 0xda, 0xc9, 0x18, + 0x1e, 0x4a, 0x13, 0x68, 0x14, 0x1c, 0x00, 0x2b, 0x02, 0xd1, 0x4b, 0x60, + 0x11, 0x60, 0x33, 0xe0, 0x99, 0x42, 0x0f, 0xd2, 0x08, 0x68, 0x0a, 0x18, + 0x9a, 0x42, 0x05, 0xd1, 0x13, 0x68, 0x52, 0x68, 0xc0, 0x18, 0x08, 0x60, + 0x4a, 0x60, 0x00, 0xe0, 0x4b, 0x60, 0x21, 0x60, 0x24, 0xe0, 0x8a, 0x42, + 0x03, 0xd8, 0x13, 0x1c, 0x5a, 0x68, 0x00, 0x2a, 0xf9, 0xd1, 0x1d, 0x68, + 0x5c, 0x19, 0x8c, 0x42, 0x0b, 0xd1, 0x09, 0x68, 0x69, 0x18, 0x58, 0x18, + 0x19, 0x60, 0x90, 0x42, 0x14, 0xd1, 0x14, 0x68, 0x52, 0x68, 0x09, 0x19, + 0x19, 0x60, 0x5a, 0x60, 0x0e, 0xe0, 0x8c, 0x42, 0x02, 0xd9, 0x0c, 0x23, + 0x03, 0x60, 0x09, 0xe0, 0x08, 0x68, 0x0c, 0x18, 0x94, 0x42, 0x03, 0xd1, + 0x14, 0x68, 0x52, 0x68, 0x00, 0x19, 0x08, 0x60, 0x4a, 0x60, 0x59, 0x60, + 0x30, 0xbd, 0xc0, 0x46, 0x44, 0x0d, 0x00, 0x20, 0x70, 0xb5, 0x03, 0x23, + 0xcd, 0x1c, 0x9d, 0x43, 0x08, 0x35, 0x06, 0x1c, 0x0c, 0x2d, 0x01, 0xd2, + 0x0c, 0x25, 0x01, 0xe0, 0x00, 0x2d, 0x3f, 0xdb, 0x8d, 0x42, 0x3d, 0xd3, + 0x20, 0x4b, 0x1c, 0x68, 0x1a, 0x1c, 0x21, 0x1c, 0x00, 0x29, 0x13, 0xd0, + 0x08, 0x68, 0x43, 0x1b, 0x0d, 0xd4, 0x0b, 0x2b, 0x02, 0xd9, 0x0b, 0x60, + 0xcc, 0x18, 0x1e, 0xe0, 0x8c, 0x42, 0x02, 0xd1, 0x63, 0x68, 0x13, 0x60, + 0x1a, 0xe0, 0x48, 0x68, 0x60, 0x60, 0x0c, 0x1c, 0x16, 0xe0, 0x0c, 0x1c, + 0x49, 0x68, 0xe9, 0xe7, 0x14, 0x4c, 0x20, 0x68, 0x00, 0x28, 0x03, 0xd1, + 0x30, 0x1c, 0x00, 0xf0, 0x25, 0xf8, 0x20, 0x60, 0x30, 0x1c, 0x29, 0x1c, + 0x00, 0xf0, 0x20, 0xf8, 0x43, 0x1c, 0x15, 0xd0, 0xc4, 0x1c, 0x03, 0x23, + 0x9c, 0x43, 0x84, 0x42, 0x0a, 0xd1, 0x25, 0x60, 0x20, 0x1c, 0x0b, 0x30, + 0x07, 0x22, 0x23, 0x1d, 0x90, 0x43, 0xc3, 0x1a, 0x0b, 0xd0, 0x5a, 0x42, + 0xe2, 0x50, 0x08, 0xe0, 0x21, 0x1a, 0x30, 0x1c, 0x00, 0xf0, 0x0a, 0xf8, + 0x01, 0x30, 0xee, 0xd1, 0x0c, 0x23, 0x33, 0x60, 0x00, 0x20, 0x70, 0xbd, + 0x44, 0x0d, 0x00, 0x20, 0x40, 0x0d, 0x00, 0x20, 0x38, 0xb5, 0x07, 0x4c, + 0x00, 0x23, 0x05, 0x1c, 0x08, 0x1c, 0x23, 0x60, 0x00, 0xf0, 0x2a, 0xf8, + 0x43, 0x1c, 0x03, 0xd1, 0x23, 0x68, 0x00, 0x2b, 0x00, 0xd0, 0x2b, 0x60, + 0x38, 0xbd, 0xc0, 0x46, 0x4c, 0x0d, 0x00, 0x20, 0xc9, 0xb2, 0x03, 0x78, + 0x00, 0x2b, 0x03, 0xd0, 0x8b, 0x42, 0x04, 0xd0, 0x01, 0x30, 0xf8, 0xe7, + 0x00, 0x29, 0x00, 0xd0, 0x18, 0x1c, 0x70, 0x47, 0x30, 0xb5, 0x03, 0x1c, + 0x00, 0x2a, 0x07, 0xd0, 0x0c, 0x78, 0x01, 0x33, 0x5d, 0x1e, 0x01, 0x3a, + 0x2c, 0x70, 0x01, 0x31, 0x00, 0x2c, 0xf5, 0xd1, 0x9a, 0x18, 0x93, 0x42, + 0x03, 0xd0, 0x00, 0x21, 0x19, 0x70, 0x01, 0x33, 0xf9, 0xe7, 0x30, 0xbd, + 0x09, 0x4a, 0x13, 0x68, 0x00, 0x2b, 0x0c, 0xd0, 0x18, 0x18, 0x69, 0x46, + 0x88, 0x42, 0x02, 0xd8, 0x10, 0x60, 0x18, 0x1c, 0x70, 0x47, 0x05, 0x4b, + 0x0c, 0x22, 0x01, 0x20, 0x1a, 0x60, 0x40, 0x42, 0xf8, 0xe7, 0x03, 0x4b, + 0x13, 0x60, 0xef, 0xe7, 0x48, 0x0d, 0x00, 0x20, 0x4c, 0x0d, 0x00, 0x20, + 0x50, 0x0d, 0x00, 0x20, 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, + 0x9e, 0x46, 0x70, 0x47, 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, + 0x9e, 0x46, 0x70, 0x47, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x2e, 0x42, + 0x49, 0x4e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x1f, 0x22, 0x00, 0x00, 0x33, 0x22, 0x00, 0x00, + 0x19, 0x22, 0x00, 0x00, 0x5d, 0x22, 0x00, 0x00, 0x61, 0x23, 0x00, 0x00, + 0x8d, 0x22, 0x00, 0x00, 0xa1, 0x22, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x2f, 0x00, 0x7c, 0x3c, 0x3e, 0x5e, 0x2b, 0x3d, 0x3f, 0x2f, 0x5b, 0x5d, + 0x3b, 0x2c, 0x2a, 0x22, 0x5c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x34, 0x00, 0x00, + 0xbd, 0x40, 0x00, 0x00, 0x19, 0x22, 0x00, 0x00, 0x1d, 0x22, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x10, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, + 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, + 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x04, + 0x00, 0x04, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x01, + 0x00, 0x01, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x13, 0x00, 0x01, 0x01, + 0x01, 0x01, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x05, + 0x00, 0x05, 0x0a, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x05, + 0x01, 0x05, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x02, 0x00, + 0x02, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, + 0x03, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x02, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x03, + 0x01, 0x03, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x10, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x11, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0a, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0b, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x05, 0x00, 0x01, 0x00, + 0x01, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x06, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x07, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x02, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x03, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xdf, 0x44, 0x00, 0x00, 0xbd, 0x40, 0x00, 0x00, 0x97, 0x44, 0x00, 0x00, + 0x7f, 0x44, 0x00, 0x00, 0x75, 0x44, 0x00, 0x00, 0xa1, 0x44, 0x00, 0x00, + 0xd5, 0x44, 0x00, 0x00, 0x49, 0x44, 0x00, 0x00, 0x8d, 0x46, 0x00, 0x00, + 0x59, 0x44, 0x00, 0x00, 0x45, 0x44, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x85, 0x47, 0x00, 0x00, + 0xb1, 0x47, 0x00, 0x00, 0x81, 0x47, 0x00, 0x00, 0xa5, 0x47, 0x00, 0x00, + 0x99, 0x47, 0x00, 0x00, 0xe9, 0x47, 0x00, 0x00, 0xcd, 0x47, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0xff, 0xff, 0xff, 0x40, 0x42, 0x0f, 0x00, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0xe4, 0x58, 0x00, 0x00, + 0x04, 0x59, 0x00, 0x00, 0x24, 0x59, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xe0, 0x58, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x20, 0xdd, 0x20, 0x00, 0x00, + 0x05, 0x22, 0x00, 0x00, 0xed, 0x26, 0x00, 0x00, 0xa9, 0x2b, 0x00, 0x00, + 0x55, 0x38, 0x00, 0x00, 0x85, 0x3a, 0x00, 0x00, 0xed, 0x3a, 0x00, 0x00, + 0x0d, 0x48, 0x00, 0x00, 0xb1, 0x4a, 0x00, 0x00, 0xb5, 0x20, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00 diff --git a/libraries/SDU/src/boot/mkrgsm1400.h b/libraries/SDU/src/boot/mkrgsm1400.h new file mode 100644 index 0000000..c8aa7d1 --- /dev/null +++ b/libraries/SDU/src/boot/mkrgsm1400.h @@ -0,0 +1,1236 @@ + 0x00, 0x80, 0x00, 0x20, 0x95, 0x3b, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, + 0x7d, 0x3b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, + 0xe9, 0x3b, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, + 0x7d, 0x3b, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, + 0x7d, 0x3b, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, 0x81, 0x3b, 0x00, 0x00, + 0x7d, 0x3b, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, + 0xcd, 0x3a, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, + 0xbd, 0x3a, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, + 0x7d, 0x3b, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, + 0x7d, 0x3b, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, + 0x7d, 0x3b, 0x00, 0x00, 0x7d, 0x3b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0xa0, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0x44, 0x59, 0x00, 0x00, 0x08, 0xb5, 0x08, 0x4b, 0x00, 0x2b, 0x03, 0xd0, + 0x07, 0x48, 0x08, 0x49, 0x00, 0xe0, 0x00, 0xbf, 0x07, 0x48, 0x03, 0x68, + 0x00, 0x2b, 0x03, 0xd0, 0x06, 0x4b, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, + 0x08, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x00, 0x44, 0x59, 0x00, 0x00, + 0xa4, 0x00, 0x00, 0x20, 0x9c, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xf0, 0xb5, 0x33, 0x4c, 0xa5, 0x44, 0x01, 0xf0, 0x45, 0xfe, 0x02, 0xf0, + 0x7d, 0xfd, 0x01, 0x20, 0x01, 0xf0, 0x6e, 0xfd, 0x2f, 0x4d, 0x04, 0x21, + 0x28, 0x1c, 0x00, 0xf0, 0xe7, 0xf9, 0x00, 0x28, 0x44, 0xd0, 0x2d, 0x4e, + 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0xbe, 0xfa, 0x00, 0x28, 0x3d, 0xd0, + 0x29, 0x1c, 0x01, 0xa8, 0x32, 0x1c, 0x01, 0x23, 0x00, 0xf0, 0x6e, 0xfa, + 0x01, 0xa8, 0x00, 0xf0, 0x00, 0xf9, 0x80, 0x21, 0x04, 0x1c, 0xc9, 0x01, + 0x88, 0x42, 0x2d, 0xd9, 0x01, 0xa8, 0x00, 0xf0, 0xe6, 0xf8, 0x22, 0x4a, + 0xc0, 0x21, 0xa7, 0x18, 0x21, 0x48, 0xc9, 0x01, 0x3a, 0x1c, 0x01, 0xf0, + 0xf5, 0xfb, 0xc0, 0x24, 0xe4, 0x01, 0x80, 0x22, 0x0a, 0xa9, 0x92, 0x00, + 0x01, 0xa8, 0x00, 0xf0, 0xcf, 0xf8, 0x80, 0x23, 0x21, 0x1c, 0x0a, 0xaa, + 0x9b, 0x00, 0x19, 0x48, 0x01, 0xf0, 0x8e, 0xfb, 0x80, 0x22, 0x92, 0x00, + 0xa3, 0x18, 0x17, 0x4a, 0xa4, 0x18, 0xbc, 0x42, 0x01, 0xd2, 0x1c, 0x1c, + 0xe9, 0xe7, 0x01, 0x24, 0x01, 0xa8, 0x00, 0xf0, 0xed, 0xf8, 0x00, 0x2c, + 0x06, 0xd0, 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0x8d, 0xfa, 0x01, 0xe0, + 0x00, 0x24, 0xf3, 0xe7, 0xc0, 0x23, 0xdb, 0x01, 0x1b, 0x68, 0x83, 0xf3, + 0x08, 0x88, 0x0c, 0x4b, 0xc0, 0x22, 0xd2, 0x01, 0x9a, 0x60, 0x0b, 0x4b, + 0x1b, 0x68, 0x18, 0x47, 0x00, 0x20, 0x8b, 0x23, 0x9b, 0x00, 0x9d, 0x44, + 0xf0, 0xbd, 0xc0, 0x46, 0xd4, 0xfd, 0xff, 0xff, 0xd4, 0x00, 0x00, 0x20, + 0xb8, 0x4e, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xbc, 0x00, 0x00, 0x20, + 0x00, 0xa2, 0xff, 0xff, 0x00, 0xed, 0x00, 0xe0, 0x04, 0x60, 0x00, 0x00, + 0x08, 0xb5, 0x00, 0x21, 0x02, 0x48, 0x0a, 0x1c, 0x01, 0xf0, 0x38, 0xfb, + 0x08, 0xbd, 0xc0, 0x46, 0xbc, 0x00, 0x00, 0x20, 0x00, 0x20, 0x70, 0x47, + 0x70, 0x47, 0x13, 0xb5, 0x02, 0x68, 0x6b, 0x46, 0xd9, 0x71, 0x07, 0x33, + 0x54, 0x68, 0x19, 0x1c, 0x01, 0x22, 0xa0, 0x47, 0x16, 0xbd, 0x38, 0xb5, + 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x25, 0xa8, 0x42, 0x02, 0xd1, 0x01, 0x23, + 0x63, 0x60, 0x0a, 0xe0, 0x45, 0x60, 0x92, 0xb2, 0x01, 0xf0, 0x04, 0xf8, + 0x23, 0x6a, 0x5b, 0x68, 0x00, 0x2b, 0x02, 0xd0, 0x01, 0x23, 0x63, 0x60, + 0x28, 0x1c, 0x38, 0xbd, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x01, 0xd0, + 0x00, 0xf0, 0x42, 0xfe, 0x08, 0xbd, 0x00, 0x00, 0x13, 0xb5, 0x6c, 0x46, + 0x07, 0x34, 0x21, 0x1c, 0x01, 0x22, 0x00, 0xf0, 0x5d, 0xfd, 0x01, 0x28, + 0x01, 0xd1, 0x20, 0x78, 0x00, 0xe0, 0x01, 0x48, 0x00, 0xb2, 0x16, 0xbd, + 0xff, 0xff, 0x00, 0x00, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x02, 0xd0, + 0xff, 0xf7, 0xea, 0xff, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x08, 0xbd, + 0x38, 0xb5, 0x05, 0x1c, 0x00, 0x6a, 0x00, 0x28, 0x0a, 0xd0, 0xff, 0xf7, + 0xdf, 0xff, 0x04, 0x1c, 0x63, 0x1c, 0x05, 0xd0, 0x28, 0x6a, 0x01, 0x69, + 0x01, 0x39, 0x00, 0xf0, 0xe5, 0xfd, 0x20, 0x1c, 0x38, 0xbd, 0x00, 0x00, + 0xf8, 0xb5, 0xfa, 0x23, 0x9b, 0x00, 0x83, 0x60, 0x0d, 0x4b, 0x00, 0x25, + 0x08, 0x33, 0x04, 0x1c, 0x45, 0x60, 0x03, 0x60, 0x28, 0x20, 0x0f, 0x1c, + 0x16, 0x1c, 0x02, 0xf0, 0xc3, 0xfc, 0x20, 0x62, 0xa8, 0x42, 0x0a, 0xd0, + 0x39, 0x1c, 0x28, 0x22, 0x02, 0xf0, 0xdf, 0xfc, 0x20, 0x1c, 0x10, 0x30, + 0x31, 0x1c, 0x0c, 0x22, 0x02, 0xf0, 0xa4, 0xfd, 0x25, 0x77, 0x20, 0x1c, + 0xf8, 0xbd, 0xc0, 0x46, 0xc8, 0x4e, 0x00, 0x00, 0xfa, 0x22, 0x92, 0x00, + 0x82, 0x60, 0x04, 0x4a, 0x00, 0x23, 0x08, 0x32, 0x43, 0x60, 0x02, 0x60, + 0x03, 0x62, 0x03, 0x74, 0x70, 0x47, 0xc0, 0x46, 0xc8, 0x4e, 0x00, 0x00, + 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x01, 0xd0, 0x00, 0xf0, 0x02, 0xfd, + 0x08, 0xbd, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x04, 0xd0, 0x00, 0xf0, + 0xa5, 0xfd, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x08, 0xbd, 0x03, 0x6a, + 0x00, 0x2b, 0x01, 0xd0, 0x18, 0x69, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, + 0x70, 0x47, 0x00, 0x6a, 0x00, 0x28, 0x00, 0xd0, 0xc0, 0x69, 0x70, 0x47, + 0x38, 0xb5, 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x28, 0x0b, 0xd0, 0x20, 0x1c, + 0xff, 0xf7, 0xf3, 0xff, 0x05, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0xe7, 0xff, + 0x02, 0x4b, 0x28, 0x1a, 0x98, 0x42, 0x00, 0xd9, 0x18, 0x1c, 0x38, 0xbd, + 0xff, 0x7f, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x28, + 0x06, 0xd0, 0x00, 0xf0, 0xe7, 0xfd, 0x20, 0x6a, 0x02, 0xf0, 0x70, 0xfc, + 0x00, 0x23, 0x23, 0x62, 0x10, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x0a, 0x1c, + 0x0c, 0x49, 0x8a, 0xb0, 0x04, 0x1c, 0x00, 0x23, 0x00, 0x91, 0x69, 0x46, + 0x4b, 0x72, 0x01, 0x93, 0x21, 0x1c, 0x68, 0x46, 0x01, 0x23, 0x00, 0xf0, + 0x81, 0xfe, 0x04, 0x1c, 0x60, 0x1e, 0x84, 0x41, 0xe4, 0xb2, 0x00, 0x2c, + 0x02, 0xd0, 0x68, 0x46, 0x00, 0xf0, 0xc8, 0xfd, 0x20, 0x1c, 0x0a, 0xb0, + 0x10, 0xbd, 0xc0, 0x46, 0x10, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x01, 0x23, + 0x00, 0x2a, 0x05, 0xd0, 0x00, 0xf0, 0x1a, 0xff, 0x03, 0x1c, 0x58, 0x1e, + 0x83, 0x41, 0xdb, 0xb2, 0x18, 0x1c, 0x08, 0xbd, 0x38, 0xb5, 0x01, 0x22, + 0x05, 0x1c, 0x0c, 0x1c, 0x01, 0xf0, 0x94, 0xf9, 0x02, 0x1c, 0x01, 0x20, + 0x00, 0x2a, 0x03, 0xd1, 0x28, 0x1c, 0x21, 0x1c, 0x01, 0xf0, 0x8c, 0xf9, + 0x38, 0xbd, 0xf0, 0xb5, 0x0c, 0x68, 0x03, 0x5d, 0x2f, 0x3b, 0x5d, 0x42, + 0x6b, 0x41, 0xe4, 0x18, 0x27, 0x1c, 0x0c, 0x37, 0x23, 0x1c, 0xc5, 0x5c, + 0x1e, 0x1b, 0x2f, 0x2d, 0x09, 0xd0, 0x00, 0x2d, 0x07, 0xd0, 0x01, 0x33, + 0x16, 0x1b, 0xf6, 0x18, 0x01, 0x3e, 0x35, 0x70, 0xbb, 0x42, 0xf2, 0xd1, + 0x0c, 0x26, 0x00, 0x24, 0x94, 0x55, 0xc2, 0x5c, 0x2f, 0x3a, 0x54, 0x42, + 0x62, 0x41, 0x9b, 0x18, 0x0b, 0x60, 0xc0, 0x5c, 0x43, 0x1e, 0x98, 0x41, + 0xc0, 0xb2, 0xf0, 0xbd, 0xf0, 0xb5, 0xa1, 0xb0, 0x03, 0x90, 0x25, 0x48, + 0x0d, 0x1c, 0x04, 0x92, 0x05, 0x93, 0x0c, 0xaa, 0x00, 0x23, 0x16, 0xa9, + 0x0d, 0x93, 0x0c, 0x90, 0x53, 0x72, 0x17, 0x93, 0x16, 0x90, 0x4b, 0x72, + 0x07, 0x93, 0x2c, 0x1c, 0x00, 0x92, 0x07, 0xa9, 0x08, 0xaa, 0x03, 0x98, + 0xff, 0xf7, 0xc3, 0xff, 0x01, 0x26, 0x02, 0x1c, 0x72, 0x40, 0x01, 0x90, + 0xd2, 0xb2, 0x20, 0x1c, 0x08, 0xa9, 0x05, 0x9b, 0x04, 0x9f, 0xb8, 0x47, + 0x00, 0x28, 0x07, 0xd1, 0xac, 0x42, 0x01, 0xd1, 0x00, 0x20, 0x23, 0xe0, + 0x20, 0x1c, 0x00, 0xf0, 0x57, 0xfd, 0xf9, 0xe7, 0x01, 0x9f, 0x00, 0x2f, + 0x11, 0xd0, 0x33, 0x1c, 0x00, 0x98, 0x21, 0x1c, 0x08, 0xaa, 0x00, 0xf0, + 0xfd, 0xfd, 0x06, 0x1c, 0xac, 0x42, 0x0f, 0xd0, 0x20, 0x1c, 0x00, 0xf0, + 0x47, 0xfd, 0x00, 0x2e, 0xe8, 0xd0, 0x23, 0x1c, 0x00, 0x9c, 0x00, 0x93, + 0xd1, 0xe7, 0xac, 0x42, 0x02, 0xd0, 0x20, 0x1c, 0x00, 0xf0, 0x3c, 0xfd, + 0x30, 0x1c, 0x03, 0xe0, 0x00, 0x28, 0xdb, 0xd0, 0x16, 0xac, 0xf0, 0xe7, + 0x21, 0xb0, 0xf0, 0xbd, 0x10, 0x4f, 0x00, 0x00, 0x38, 0xb5, 0x03, 0x1c, + 0x41, 0x33, 0x1b, 0x78, 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x2b, 0x02, 0xd0, + 0x38, 0x30, 0x00, 0xf0, 0x27, 0xfd, 0x20, 0x1c, 0x01, 0x21, 0x2a, 0x1c, + 0x00, 0xf0, 0xc8, 0xf9, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x0f, 0xe0, + 0x25, 0x1c, 0x10, 0x35, 0x28, 0x1c, 0x21, 0x1c, 0xff, 0xf7, 0x62, 0xff, + 0x00, 0x28, 0xf5, 0xd0, 0x20, 0x1c, 0x38, 0x30, 0x29, 0x1c, 0x00, 0xf0, + 0xcf, 0xfb, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x38, 0xbd, 0x00, 0x00, + 0x4b, 0x68, 0x43, 0x60, 0x0a, 0x4b, 0x03, 0x60, 0x0b, 0x7a, 0x03, 0x72, + 0x4b, 0x7a, 0x43, 0x72, 0xcb, 0x68, 0xc3, 0x60, 0x0b, 0x69, 0x03, 0x61, + 0x4b, 0x69, 0x43, 0x61, 0x0b, 0x7e, 0x03, 0x76, 0xcb, 0x69, 0xc3, 0x61, + 0x0b, 0x6a, 0x49, 0x6a, 0x03, 0x62, 0x41, 0x62, 0x70, 0x47, 0xc0, 0x46, + 0x10, 0x4f, 0x00, 0x00, 0xf0, 0xb5, 0x9d, 0xb0, 0x08, 0xae, 0x02, 0x92, + 0x03, 0x93, 0x27, 0x4a, 0x00, 0x23, 0x12, 0xaf, 0x05, 0x1c, 0x73, 0x60, + 0x7b, 0x60, 0x10, 0x31, 0x30, 0x1c, 0x08, 0x92, 0x73, 0x72, 0x12, 0x92, + 0x7b, 0x72, 0x00, 0xf0, 0x9d, 0xfb, 0x02, 0x9c, 0x20, 0x1c, 0x2f, 0x21, + 0x02, 0xf0, 0x3e, 0xfc, 0x00, 0x28, 0x2e, 0xd0, 0x23, 0x78, 0x2f, 0x2b, + 0x01, 0xd1, 0x01, 0x34, 0xf4, 0xe7, 0x00, 0x1b, 0xc0, 0xb2, 0x03, 0x1c, + 0x0c, 0x28, 0x00, 0xd9, 0x0c, 0x23, 0xdb, 0xb2, 0x1a, 0x1c, 0x21, 0x1c, + 0x04, 0xa8, 0x01, 0x93, 0x02, 0xf0, 0x36, 0xfc, 0x01, 0x9a, 0x00, 0x23, + 0x04, 0xa9, 0x38, 0x1c, 0x8b, 0x54, 0x00, 0xf0, 0xbf, 0xfc, 0x38, 0x1c, + 0x31, 0x1c, 0x04, 0xaa, 0x01, 0x23, 0x00, 0xf0, 0x69, 0xfd, 0x00, 0x28, + 0x04, 0xd1, 0x0c, 0x4b, 0x68, 0x60, 0x2b, 0x60, 0x68, 0x72, 0x10, 0xe0, + 0x01, 0x9b, 0x30, 0x1c, 0xe4, 0x18, 0x00, 0xf0, 0xad, 0xfc, 0x33, 0x1c, + 0x3e, 0x1c, 0x1f, 0x1c, 0xca, 0xe7, 0x02, 0x99, 0x03, 0x9a, 0x64, 0x1a, + 0x14, 0x60, 0x28, 0x1c, 0x31, 0x1c, 0xff, 0xf7, 0x95, 0xff, 0x28, 0x1c, + 0x1d, 0xb0, 0xf0, 0xbd, 0x10, 0x4f, 0x00, 0x00, 0xf0, 0xb5, 0xa1, 0xb0, + 0x05, 0x1c, 0x1f, 0x1c, 0x02, 0xa8, 0x01, 0xab, 0x16, 0x1c, 0xff, 0xf7, + 0xa1, 0xff, 0x01, 0x9b, 0xf6, 0x18, 0x33, 0x78, 0x00, 0x2b, 0x07, 0xd1, + 0x02, 0xa9, 0x16, 0xa8, 0xff, 0xf7, 0x7e, 0xff, 0x28, 0x1c, 0x16, 0xa9, + 0x17, 0x4a, 0x28, 0xe0, 0x00, 0x23, 0x0c, 0xac, 0x63, 0x60, 0x63, 0x72, + 0x6b, 0x46, 0x11, 0x33, 0x14, 0x4a, 0x1b, 0x78, 0x0c, 0x92, 0x00, 0x2b, + 0x03, 0xd1, 0x28, 0x1c, 0xff, 0xf7, 0x4a, 0xfe, 0x1b, 0xe0, 0x20, 0x1c, + 0x02, 0xa9, 0x32, 0x1c, 0x3b, 0x1c, 0x00, 0xf0, 0x21, 0xfd, 0x00, 0x28, + 0xf3, 0xd0, 0x02, 0xa8, 0x00, 0xf0, 0x6c, 0xfc, 0x06, 0x23, 0x1f, 0x40, + 0x9f, 0x42, 0x03, 0xd1, 0x20, 0x1c, 0x13, 0x99, 0x00, 0xf0, 0xf6, 0xfb, + 0x21, 0x1c, 0x16, 0xa8, 0xff, 0xf7, 0x54, 0xff, 0x28, 0x1c, 0x16, 0xa9, + 0x32, 0x1c, 0xff, 0xf7, 0x0b, 0xfe, 0x28, 0x1c, 0x21, 0xb0, 0xf0, 0xbd, + 0xf0, 0x4e, 0x00, 0x00, 0x10, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x1c, + 0x08, 0x1c, 0x19, 0x1c, 0x38, 0x31, 0x02, 0x4a, 0x00, 0x23, 0xff, 0xf7, + 0xc9, 0xfe, 0x08, 0xbd, 0xa5, 0x23, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x1c, + 0x08, 0x1c, 0x19, 0x1c, 0x38, 0x31, 0x02, 0x4a, 0x00, 0x23, 0xff, 0xf7, + 0xbd, 0xfe, 0x08, 0xbd, 0xe1, 0x23, 0x00, 0x00, 0x08, 0x4b, 0x02, 0x21, + 0x19, 0x61, 0x19, 0x1c, 0x00, 0x22, 0x30, 0x31, 0x0a, 0x70, 0x06, 0x49, + 0x5a, 0x71, 0x9a, 0x71, 0x9a, 0x72, 0x1a, 0x73, 0xda, 0x63, 0x99, 0x63, + 0x41, 0x33, 0x1a, 0x70, 0x70, 0x47, 0xc0, 0x46, 0xd4, 0x00, 0x00, 0x20, + 0x10, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x01, 0x1c, 0x01, 0x48, 0x01, 0xf0, + 0xab, 0xf9, 0x08, 0xbd, 0x78, 0x07, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, + 0xff, 0x21, 0x01, 0xf0, 0xa3, 0xf9, 0x08, 0xbd, 0x78, 0x07, 0x00, 0x20, + 0x08, 0xb5, 0x01, 0x21, 0x00, 0x79, 0x01, 0xf0, 0x33, 0xfc, 0x05, 0x4b, + 0x1a, 0x78, 0x00, 0x2a, 0x04, 0xd0, 0x00, 0x22, 0x03, 0x48, 0x1a, 0x70, + 0x01, 0xf0, 0x80, 0xf9, 0x08, 0xbd, 0xc0, 0x46, 0x40, 0x01, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x10, 0xb5, 0x08, 0x4b, 0x04, 0x1c, 0x1a, 0x78, + 0x00, 0x2a, 0x06, 0xd1, 0x01, 0x22, 0x1a, 0x70, 0x05, 0x4b, 0x06, 0x48, + 0x06, 0xcb, 0x01, 0xf0, 0x51, 0xf9, 0x20, 0x79, 0x00, 0x21, 0x01, 0xf0, + 0x13, 0xfc, 0x10, 0xbd, 0x40, 0x01, 0x00, 0x20, 0x38, 0x01, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x10, 0xb5, 0x83, 0x79, 0x04, 0x1c, 0x00, 0x2b, + 0x0d, 0xd0, 0x23, 0x89, 0x5a, 0x1c, 0x22, 0x81, 0x05, 0x4a, 0x93, 0x42, + 0x02, 0xd8, 0xff, 0xf7, 0xbf, 0xff, 0xf6, 0xe7, 0x20, 0x1c, 0xff, 0xf7, + 0xc3, 0xff, 0x00, 0x23, 0xa3, 0x71, 0x10, 0xbd, 0x01, 0x02, 0x00, 0x00, + 0x00, 0xb5, 0x06, 0x29, 0x03, 0xd9, 0x16, 0x23, 0x43, 0x71, 0x00, 0x20, + 0x1c, 0xe0, 0x0f, 0x4b, 0x05, 0x29, 0x13, 0xd8, 0x08, 0x1c, 0x00, 0x22, + 0x02, 0xf0, 0xc8, 0xf9, 0x03, 0x05, 0x07, 0x09, 0x0b, 0x0d, 0x0b, 0x49, + 0x08, 0xe0, 0x0b, 0x49, 0x06, 0xe0, 0x0b, 0x49, 0x04, 0xe0, 0x0b, 0x49, + 0x02, 0xe0, 0x0b, 0x49, 0x00, 0xe0, 0x0b, 0x49, 0x19, 0x60, 0x02, 0xe0, + 0x0a, 0x4a, 0x1a, 0x60, 0x00, 0x22, 0x1a, 0x71, 0x5a, 0x71, 0x01, 0x20, + 0x00, 0xbd, 0xc0, 0x46, 0x38, 0x01, 0x00, 0x20, 0x00, 0x1b, 0xb7, 0x00, + 0x00, 0x09, 0x3d, 0x00, 0x80, 0x84, 0x1e, 0x00, 0x40, 0x42, 0x0f, 0x00, + 0x20, 0xa1, 0x07, 0x00, 0x90, 0xd0, 0x03, 0x00, 0x48, 0xe8, 0x01, 0x00, + 0x38, 0xb5, 0x0c, 0x1c, 0x01, 0xf0, 0xe4, 0xf9, 0x05, 0x1c, 0xff, 0xf7, + 0x79, 0xff, 0xff, 0x28, 0x06, 0xd0, 0x01, 0xf0, 0xdd, 0xf9, 0x40, 0x1b, + 0xa0, 0x42, 0xf6, 0xd3, 0x00, 0x20, 0x00, 0xe0, 0x01, 0x20, 0x38, 0xbd, + 0xf8, 0xb5, 0x04, 0x1c, 0x0e, 0x1c, 0x17, 0x1c, 0xff, 0xf7, 0x9c, 0xff, + 0x20, 0x1c, 0xff, 0xf7, 0x81, 0xff, 0x96, 0x21, 0x49, 0x00, 0x20, 0x1c, + 0xff, 0xf7, 0xe0, 0xff, 0x40, 0x20, 0x30, 0x43, 0xff, 0xf7, 0x54, 0xff, + 0x18, 0x25, 0x38, 0x1c, 0xe8, 0x40, 0xc0, 0xb2, 0x08, 0x3d, 0xff, 0xf7, + 0x4d, 0xff, 0x2b, 0x1c, 0x08, 0x33, 0xf6, 0xd1, 0x95, 0x20, 0x00, 0x2e, + 0x03, 0xd0, 0x87, 0x20, 0x08, 0x2e, 0x00, 0xd0, 0xff, 0x20, 0xff, 0xf7, + 0x41, 0xff, 0x00, 0x25, 0xff, 0xf7, 0x46, 0xff, 0x43, 0xb2, 0xe0, 0x72, + 0x00, 0x2b, 0x04, 0xda, 0xff, 0x2d, 0x02, 0xd0, 0x01, 0x35, 0xed, 0xb2, + 0xf4, 0xe7, 0xf8, 0xbd, 0xf7, 0xb5, 0x00, 0x25, 0x02, 0x71, 0x05, 0x73, + 0x85, 0x72, 0x85, 0x71, 0x45, 0x71, 0x04, 0x1c, 0x01, 0x91, 0x01, 0xf0, + 0x99, 0xf9, 0x01, 0x21, 0x07, 0x1c, 0x20, 0x79, 0x01, 0xf0, 0x12, 0xfb, + 0x01, 0x21, 0x20, 0x79, 0x01, 0xf0, 0x68, 0xfb, 0x42, 0x4e, 0x30, 0x1c, + 0x01, 0xf0, 0x76, 0xf8, 0x41, 0x4b, 0x42, 0x49, 0x1d, 0x71, 0x5d, 0x71, + 0x19, 0x60, 0x30, 0x1c, 0x5a, 0x68, 0x01, 0xf0, 0x95, 0xf8, 0x0a, 0x25, + 0x01, 0x3d, 0xff, 0x20, 0xed, 0xb2, 0xff, 0xf7, 0x0d, 0xff, 0x00, 0x2d, + 0xf8, 0xd1, 0x30, 0x1c, 0x01, 0xf0, 0xa6, 0xf8, 0x20, 0x1c, 0xff, 0xf7, + 0x29, 0xff, 0x00, 0x21, 0x20, 0x1c, 0x0a, 0x1c, 0xff, 0xf7, 0x9a, 0xff, + 0x06, 0x1c, 0xe0, 0x72, 0x01, 0x28, 0x08, 0xd0, 0x01, 0xf0, 0x6a, 0xf9, + 0xfa, 0x23, 0xc0, 0x1b, 0xdb, 0x00, 0x98, 0x42, 0xef, 0xd9, 0x01, 0x23, + 0x3b, 0xe0, 0xd5, 0x22, 0x20, 0x1c, 0x08, 0x21, 0x52, 0x00, 0xff, 0xf7, + 0x87, 0xff, 0x04, 0x23, 0x18, 0x42, 0x01, 0xd0, 0x26, 0x73, 0x0b, 0xe0, + 0x1e, 0x1c, 0xff, 0xf7, 0xed, 0xfe, 0x01, 0x3e, 0xf6, 0xb2, 0xe0, 0x72, + 0x00, 0x2e, 0xf8, 0xd1, 0x02, 0x23, 0xaa, 0x28, 0x25, 0xd1, 0x23, 0x73, + 0x26, 0x7b, 0x02, 0x3e, 0x73, 0x42, 0x5e, 0x41, 0xb6, 0x07, 0x37, 0x21, + 0x00, 0x22, 0x20, 0x1c, 0xff, 0xf7, 0x6c, 0xff, 0x32, 0x1c, 0x20, 0x1c, + 0x29, 0x21, 0xff, 0xf7, 0x67, 0xff, 0x02, 0x1c, 0xe0, 0x72, 0x08, 0xd0, + 0x01, 0xf0, 0x38, 0xf9, 0xfa, 0x23, 0xc0, 0x1b, 0xdb, 0x00, 0x98, 0x42, + 0xeb, 0xd9, 0x08, 0x23, 0x09, 0xe0, 0x23, 0x7b, 0x02, 0x2b, 0x19, 0xd1, + 0x20, 0x1c, 0x3a, 0x21, 0xff, 0xf7, 0x54, 0xff, 0x00, 0x28, 0x05, 0xd0, + 0x06, 0x23, 0x63, 0x71, 0x20, 0x1c, 0xff, 0xf7, 0xc3, 0xfe, 0x15, 0xe0, + 0xff, 0xf7, 0xb8, 0xfe, 0xc0, 0x23, 0x18, 0x40, 0x98, 0x42, 0x01, 0xd1, + 0x03, 0x23, 0x23, 0x73, 0xff, 0xf7, 0xb0, 0xfe, 0xff, 0xf7, 0xae, 0xfe, + 0xff, 0xf7, 0xac, 0xfe, 0x20, 0x1c, 0xff, 0xf7, 0xb1, 0xfe, 0x20, 0x1c, + 0x01, 0x99, 0xff, 0xf7, 0xef, 0xfe, 0x05, 0x1c, 0x28, 0x1c, 0xfe, 0xbd, + 0x78, 0x07, 0x00, 0x20, 0x38, 0x01, 0x00, 0x20, 0x90, 0xd0, 0x03, 0x00, + 0x38, 0xb5, 0x04, 0x1c, 0x01, 0xf0, 0x00, 0xf9, 0x05, 0x1c, 0xff, 0xf7, + 0x95, 0xfe, 0xe0, 0x72, 0xff, 0x28, 0x08, 0xd1, 0x01, 0xf0, 0xf8, 0xf8, + 0x96, 0x23, 0x40, 0x1b, 0x5b, 0x00, 0x98, 0x42, 0xf3, 0xd9, 0x0f, 0x23, + 0x02, 0xe0, 0xfe, 0x28, 0x06, 0xd0, 0x0d, 0x23, 0x20, 0x1c, 0x63, 0x71, + 0xff, 0xf7, 0x8a, 0xfe, 0x00, 0x20, 0x00, 0xe0, 0x01, 0x20, 0x38, 0xbd, + 0xf8, 0xb5, 0x04, 0x1c, 0x0f, 0x1c, 0x15, 0x1c, 0x1e, 0x1e, 0x45, 0xd0, + 0x9a, 0x18, 0x80, 0x23, 0x9b, 0x00, 0x9a, 0x42, 0x42, 0xdc, 0x83, 0x79, + 0x00, 0x2b, 0x05, 0xd0, 0x02, 0x68, 0x91, 0x42, 0x02, 0xd1, 0x03, 0x89, + 0xab, 0x42, 0x16, 0xd9, 0x23, 0x7b, 0x27, 0x60, 0x03, 0x2b, 0x00, 0xd0, + 0x7f, 0x02, 0x3a, 0x1c, 0x20, 0x1c, 0x11, 0x21, 0xff, 0xf7, 0xf2, 0xfe, + 0x07, 0x1e, 0x02, 0xd0, 0x03, 0x23, 0x63, 0x71, 0x2a, 0xe0, 0x20, 0x1c, + 0xff, 0xf7, 0xbc, 0xff, 0x00, 0x28, 0x25, 0xd0, 0x01, 0x23, 0x27, 0x81, + 0xa3, 0x71, 0x23, 0x89, 0xab, 0x42, 0x05, 0xd2, 0xff, 0xf7, 0x4e, 0xfe, + 0x23, 0x89, 0x01, 0x33, 0x23, 0x81, 0xf6, 0xe7, 0x06, 0x9d, 0x06, 0x9a, + 0xab, 0x1a, 0x9b, 0xb2, 0xb3, 0x42, 0x04, 0xd2, 0xff, 0xf7, 0x42, 0xfe, + 0x28, 0x70, 0x01, 0x35, 0xf5, 0xe7, 0x23, 0x89, 0xa2, 0x7a, 0xf3, 0x18, + 0x9b, 0xb2, 0x23, 0x81, 0x00, 0x2a, 0x02, 0xd0, 0x06, 0x4a, 0x93, 0x42, + 0x02, 0xd9, 0x20, 0x1c, 0xff, 0xf7, 0x66, 0xfe, 0x01, 0x20, 0x03, 0xe0, + 0x20, 0x1c, 0xff, 0xf7, 0x35, 0xfe, 0x00, 0x20, 0xf8, 0xbd, 0xc0, 0x46, + 0xff, 0x01, 0x00, 0x00, 0x07, 0xb5, 0x80, 0x23, 0x00, 0x92, 0x9b, 0x00, + 0x00, 0x22, 0xff, 0xf7, 0xa3, 0xff, 0x0e, 0xbd, 0x70, 0xb5, 0x05, 0x1c, + 0x08, 0x1c, 0x16, 0x1c, 0xff, 0xf7, 0x12, 0xfe, 0x00, 0x24, 0x30, 0x5d, + 0xff, 0xf7, 0x0e, 0xfe, 0x01, 0x34, 0x80, 0x23, 0x9b, 0x00, 0x9c, 0x42, + 0xf7, 0xd1, 0xff, 0x20, 0xff, 0xf7, 0x06, 0xfe, 0xff, 0x20, 0xff, 0xf7, + 0x03, 0xfe, 0xff, 0xf7, 0x09, 0xfe, 0x1f, 0x23, 0xe8, 0x72, 0x03, 0x40, + 0x01, 0x20, 0x05, 0x2b, 0x05, 0xd0, 0x11, 0x23, 0x28, 0x1c, 0x6b, 0x71, + 0xff, 0xf7, 0x06, 0xfe, 0x00, 0x20, 0x70, 0xbd, 0x70, 0xb5, 0x0b, 0x1c, + 0x04, 0x1c, 0x16, 0x1c, 0x00, 0x29, 0x01, 0xd1, 0x12, 0x23, 0x28, 0xe0, + 0x02, 0x7b, 0x03, 0x2a, 0x00, 0xd0, 0x4b, 0x02, 0x20, 0x1c, 0x18, 0x21, + 0x1a, 0x1c, 0xff, 0xf7, 0x7d, 0xfe, 0x05, 0x1e, 0x01, 0xd0, 0x04, 0x23, + 0x1b, 0xe0, 0x20, 0x1c, 0xfe, 0x21, 0x32, 0x1c, 0xff, 0xf7, 0xc2, 0xff, + 0x00, 0x28, 0x15, 0xd0, 0x96, 0x21, 0x20, 0x1c, 0x89, 0x00, 0xff, 0xf7, + 0x5b, 0xfe, 0x00, 0x28, 0x01, 0xd1, 0x15, 0x23, 0x0b, 0xe0, 0x20, 0x1c, + 0x0d, 0x21, 0x2a, 0x1c, 0xff, 0xf7, 0x64, 0xfe, 0x00, 0x28, 0x03, 0xd1, + 0xff, 0xf7, 0xce, 0xfd, 0x00, 0x28, 0x06, 0xd0, 0x14, 0x23, 0x63, 0x71, + 0x20, 0x1c, 0xff, 0xf7, 0xcf, 0xfd, 0x00, 0x20, 0x03, 0xe0, 0x20, 0x1c, + 0xff, 0xf7, 0xca, 0xfd, 0x01, 0x20, 0x70, 0xbd, 0x03, 0x4b, 0x04, 0x4a, + 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x70, 0x47, 0xc0, 0x46, + 0x38, 0x01, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, 0x02, 0x1c, 0x10, 0xb5, + 0x0c, 0x32, 0x04, 0x1c, 0x01, 0x21, 0x40, 0x6a, 0x00, 0xf0, 0x24, 0xfd, + 0x00, 0x28, 0x0a, 0xd0, 0x23, 0x6a, 0x01, 0x20, 0x00, 0x2b, 0x06, 0xd1, + 0xe3, 0x68, 0x22, 0x7a, 0x23, 0x62, 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, + 0x23, 0x72, 0x10, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xe6, 0xff, + 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x1b, 0xe0, 0x63, 0x6a, 0xe6, 0x68, + 0x1a, 0x7c, 0x02, 0x3e, 0x96, 0x40, 0x5a, 0x69, 0x1d, 0x79, 0xb6, 0x18, + 0x00, 0x2d, 0x08, 0xd0, 0x70, 0x1e, 0x40, 0x19, 0x00, 0xf0, 0x4c, 0xfc, + 0x00, 0x28, 0xed, 0xd0, 0x01, 0x3d, 0xed, 0xb2, 0xf4, 0xe7, 0x63, 0x6a, + 0x01, 0x20, 0x1a, 0x7c, 0x80, 0x23, 0x9b, 0x00, 0x93, 0x40, 0xe2, 0x69, + 0xd3, 0x18, 0xe3, 0x61, 0x70, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, + 0x40, 0x69, 0x00, 0xf0, 0x13, 0xfc, 0x00, 0x28, 0x03, 0xd0, 0x20, 0x7e, + 0x01, 0x4b, 0x40, 0x01, 0xc0, 0x18, 0x10, 0xbd, 0x50, 0x01, 0x00, 0x20, + 0xf0, 0xb5, 0x00, 0x23, 0x87, 0xb0, 0x07, 0x1c, 0x0e, 0x1c, 0x20, 0x22, + 0xf2, 0x54, 0x01, 0x33, 0x0b, 0x2b, 0xfa, 0xd1, 0x07, 0x21, 0x00, 0x25, + 0x01, 0x91, 0x3c, 0x78, 0x00, 0x2c, 0x2a, 0xd0, 0x2e, 0x2c, 0x06, 0xd1, + 0x01, 0x9b, 0x0a, 0x2b, 0x2b, 0xd0, 0x0a, 0x21, 0x08, 0x25, 0x01, 0x91, + 0x1f, 0xe0, 0x02, 0xa8, 0x14, 0x49, 0x10, 0x22, 0x02, 0xf0, 0x0f, 0xf8, + 0x00, 0x23, 0x02, 0xa9, 0xca, 0x5c, 0x00, 0x2a, 0x03, 0xd0, 0x01, 0x33, + 0xa2, 0x42, 0xf8, 0xd1, 0x19, 0xe0, 0x01, 0x9b, 0x9d, 0x42, 0x16, 0xd8, + 0x23, 0x1c, 0x21, 0x3b, 0x5d, 0x2b, 0x12, 0xd8, 0x22, 0x1c, 0x6b, 0x1c, + 0x61, 0x3a, 0xdb, 0xb2, 0x75, 0x19, 0x19, 0x2a, 0x01, 0xd8, 0x20, 0x3c, + 0xe4, 0xb2, 0x2c, 0x70, 0x1d, 0x1c, 0x01, 0x37, 0xd1, 0xe7, 0x30, 0x78, + 0x20, 0x38, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x00, 0xe0, 0x00, 0x20, + 0x07, 0xb0, 0xf0, 0xbd, 0xf2, 0x4e, 0x00, 0x00, 0x38, 0xb5, 0x42, 0x7a, + 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x2a, 0x01, 0xd0, 0x00, 0x20, 0x1f, 0xe0, + 0x4b, 0x1c, 0xdb, 0x7f, 0x10, 0x2b, 0x06, 0xd1, 0x02, 0x23, 0x43, 0x72, + 0x02, 0x62, 0x4b, 0x8c, 0x5b, 0x01, 0xc3, 0x61, 0x0c, 0xe0, 0x20, 0x2b, + 0xf0, 0xd1, 0x03, 0x23, 0x43, 0x72, 0x49, 0x6a, 0x22, 0x1c, 0x01, 0x62, + 0x1c, 0x32, 0x28, 0x1c, 0x00, 0xf0, 0x18, 0xfc, 0x00, 0x28, 0xe5, 0xd0, + 0x00, 0x23, 0x01, 0x20, 0x65, 0x62, 0x20, 0x72, 0xe3, 0x60, 0x23, 0x61, + 0x63, 0x61, 0x23, 0x76, 0x38, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x43, 0x7a, + 0x85, 0xb0, 0x04, 0x1c, 0x0e, 0x1c, 0x03, 0x92, 0x00, 0x2b, 0x01, 0xd1, + 0x3a, 0x48, 0x11, 0xe0, 0x03, 0x7a, 0xd8, 0x07, 0xfa, 0xd5, 0xe2, 0x69, + 0x20, 0x69, 0x03, 0x99, 0x13, 0x1a, 0x99, 0x42, 0x01, 0xd9, 0x9b, 0xb2, + 0x03, 0x93, 0x03, 0x99, 0x02, 0x91, 0x02, 0x9b, 0x00, 0x2b, 0x04, 0xd1, + 0x03, 0x99, 0x88, 0xb2, 0x00, 0xb2, 0x05, 0xb0, 0xf0, 0xbd, 0x23, 0x69, + 0x61, 0x7a, 0xdf, 0x05, 0xff, 0x0d, 0x5a, 0x0a, 0x60, 0x6a, 0x02, 0x29, + 0x02, 0xd1, 0x41, 0x6a, 0x51, 0x18, 0x1b, 0xe0, 0x05, 0x79, 0x01, 0x3d, + 0x2a, 0x40, 0xd5, 0xb2, 0x00, 0x2f, 0x0d, 0xd1, 0x00, 0x2d, 0x0b, 0xd1, + 0x00, 0x2b, 0x02, 0xd1, 0x22, 0x6a, 0xe2, 0x60, 0x06, 0xe0, 0x22, 0x1c, + 0xe1, 0x68, 0x0c, 0x32, 0x00, 0xf0, 0xa0, 0xfb, 0x00, 0x28, 0xc9, 0xd0, + 0x63, 0x6a, 0xe1, 0x68, 0x1a, 0x7c, 0x02, 0x39, 0x5b, 0x69, 0x91, 0x40, + 0xc9, 0x18, 0x49, 0x19, 0x80, 0x22, 0x02, 0x9d, 0x92, 0x00, 0xd3, 0x1b, + 0x9d, 0x42, 0x00, 0xdd, 0x9d, 0xb2, 0x23, 0x7a, 0x58, 0x06, 0x01, 0xd4, + 0x95, 0x42, 0x18, 0xd1, 0x16, 0x4b, 0x1b, 0x68, 0x99, 0x42, 0x14, 0xd0, + 0x15, 0x4b, 0x3a, 0x1c, 0x18, 0x68, 0x00, 0x96, 0x2b, 0x1c, 0xff, 0xf7, + 0x1f, 0xfe, 0x00, 0x28, 0xa8, 0xd0, 0x76, 0x19, 0x01, 0xe0, 0xdf, 0x1b, + 0xf6, 0x19, 0x21, 0x69, 0x02, 0x9a, 0x4b, 0x19, 0x55, 0x1b, 0xad, 0xb2, + 0x23, 0x61, 0x02, 0x95, 0xab, 0xe7, 0x08, 0x1c, 0x00, 0x21, 0x00, 0xf0, + 0x2b, 0xfb, 0x00, 0x28, 0x96, 0xd0, 0x09, 0x4b, 0x32, 0x1c, 0xff, 0x18, + 0x79, 0x19, 0x3b, 0x1c, 0x8b, 0x42, 0xe8, 0xd0, 0x18, 0x78, 0x01, 0x33, + 0x10, 0x70, 0x01, 0x32, 0xf8, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x73, 0xb5, 0x43, 0x7a, 0x04, 0x1c, 0x01, 0x2b, 0x01, 0xd8, 0x00, 0x20, + 0x16, 0xe0, 0x03, 0x69, 0x6d, 0x46, 0x07, 0x35, 0xde, 0x05, 0x29, 0x1c, + 0x01, 0x22, 0x36, 0x0f, 0xff, 0xf7, 0x6a, 0xff, 0x01, 0x28, 0x01, 0xd1, + 0x2b, 0x78, 0x00, 0xe0, 0x05, 0x4b, 0x1b, 0xb2, 0x01, 0x33, 0xec, 0xd0, + 0x23, 0x69, 0x70, 0x01, 0x1f, 0x33, 0x23, 0x61, 0x02, 0x4b, 0xc0, 0x18, + 0x76, 0xbd, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0x50, 0x01, 0x00, 0x20, + 0x70, 0xb5, 0x04, 0x1c, 0x40, 0x7a, 0x0d, 0x1c, 0x00, 0x28, 0x2a, 0xd0, + 0xe2, 0x69, 0x91, 0x42, 0x01, 0xd9, 0x00, 0x20, 0x25, 0xe0, 0x02, 0x28, + 0x21, 0xd0, 0x00, 0x2d, 0x01, 0xd1, 0xe5, 0x60, 0x1d, 0xe0, 0x62, 0x6a, + 0x21, 0x69, 0x13, 0x7c, 0x68, 0x1e, 0x09, 0x33, 0x4a, 0x1e, 0xd8, 0x40, + 0xda, 0x40, 0x03, 0x1e, 0x93, 0x42, 0x01, 0xd3, 0x00, 0x29, 0x02, 0xd1, + 0x22, 0x6a, 0xe2, 0x60, 0x00, 0xe0, 0x83, 0x1a, 0x1e, 0x1c, 0x00, 0x2e, + 0x09, 0xd0, 0x22, 0x1c, 0x60, 0x6a, 0xe1, 0x68, 0x0c, 0x32, 0x00, 0xf0, + 0x07, 0xfb, 0x01, 0x3e, 0x00, 0x28, 0xf4, 0xd1, 0x01, 0xe0, 0x25, 0x61, + 0x01, 0x20, 0x70, 0xbd, 0x38, 0xb5, 0x05, 0x1c, 0x40, 0x7a, 0x00, 0x28, + 0x33, 0xd0, 0x2b, 0x7a, 0x7f, 0x2b, 0x2d, 0xd9, 0x28, 0x1c, 0x01, 0x21, + 0xff, 0xf7, 0x9a, 0xfe, 0x04, 0x1e, 0x2a, 0xd0, 0x6b, 0x7a, 0x01, 0x2b, + 0x07, 0xd8, 0x2b, 0x7f, 0x03, 0x77, 0x6b, 0x7f, 0x43, 0x77, 0xab, 0x7f, + 0x83, 0x77, 0xeb, 0x7f, 0xc3, 0x77, 0x2b, 0x6a, 0x9a, 0xb2, 0x1b, 0x0c, + 0x23, 0x75, 0x1b, 0x0a, 0x63, 0x75, 0x0d, 0x4b, 0xa2, 0x76, 0x1b, 0x68, + 0x12, 0x0a, 0xe2, 0x76, 0x00, 0x2b, 0x0b, 0xd0, 0x20, 0x1c, 0x21, 0x1c, + 0x18, 0x30, 0x16, 0x31, 0x98, 0x47, 0x63, 0x7e, 0x22, 0x7e, 0x1b, 0x02, + 0x13, 0x43, 0xa3, 0x74, 0x1b, 0x0a, 0xe3, 0x74, 0x2a, 0x7a, 0x7f, 0x23, + 0x13, 0x40, 0x2b, 0x72, 0x00, 0xf0, 0x5c, 0xfa, 0xff, 0xe7, 0x38, 0xbd, + 0x44, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xc0, 0xff, + 0x00, 0x28, 0x02, 0xd0, 0x00, 0x23, 0x63, 0x72, 0x01, 0x20, 0x10, 0xbd, + 0x73, 0xb5, 0x42, 0x7a, 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x20, 0x01, 0x2a, + 0x4b, 0xd1, 0x20, 0x7a, 0x02, 0x23, 0x18, 0x40, 0x47, 0xd0, 0xe3, 0x69, + 0x00, 0x20, 0x99, 0x42, 0x43, 0xd8, 0x10, 0x1c, 0x00, 0x2b, 0x40, 0xd0, + 0x20, 0x1c, 0x29, 0x1c, 0x26, 0x69, 0xff, 0xf7, 0x71, 0xff, 0x00, 0x28, + 0x25, 0xd0, 0x60, 0x6a, 0x00, 0x2d, 0x06, 0xd1, 0x21, 0x6a, 0x00, 0xf0, + 0x95, 0xfb, 0x00, 0x28, 0x1d, 0xd0, 0x25, 0x62, 0x1d, 0xe0, 0xe1, 0x68, + 0x01, 0xaa, 0x00, 0xf0, 0x93, 0xfa, 0x00, 0x28, 0x15, 0xd0, 0x60, 0x6a, + 0x01, 0x99, 0x43, 0x1c, 0xdb, 0x7f, 0x10, 0x2b, 0x01, 0xd1, 0x12, 0x4b, + 0x00, 0xe0, 0x12, 0x4b, 0x99, 0x42, 0x0c, 0xd2, 0x00, 0xf0, 0x7e, 0xfb, + 0x00, 0x28, 0x06, 0xd0, 0x60, 0x6a, 0xe1, 0x68, 0x0e, 0x4a, 0x00, 0xf0, + 0xcf, 0xfa, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x11, 0xe0, 0x22, 0x7a, + 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, 0xe5, 0x61, 0x23, 0x72, 0x20, 0x1c, + 0xff, 0xf7, 0x70, 0xff, 0x00, 0x28, 0xf2, 0xd0, 0x29, 0x1e, 0xb1, 0x42, + 0x00, 0xd9, 0x31, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x35, 0xff, 0x76, 0xbd, + 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, 0xff, 0xff, 0xff, 0x0f, + 0x38, 0xb5, 0x23, 0x4b, 0x15, 0x1c, 0x4a, 0x01, 0xd3, 0x18, 0x04, 0x1c, + 0xd8, 0x7a, 0x11, 0x22, 0x10, 0x42, 0x04, 0xd0, 0x42, 0x22, 0x15, 0x42, + 0x01, 0xd0, 0x00, 0x20, 0x36, 0xe0, 0x1d, 0x4a, 0x21, 0x76, 0x12, 0x68, + 0x62, 0x61, 0x5a, 0x7d, 0x18, 0x7d, 0xd9, 0x7e, 0x12, 0x02, 0x02, 0x43, + 0x98, 0x7e, 0x09, 0x02, 0x12, 0x04, 0x01, 0x43, 0x11, 0x43, 0x21, 0x62, + 0xd8, 0x7a, 0x18, 0x22, 0x02, 0x40, 0x0c, 0xd1, 0x5a, 0x7f, 0x19, 0x7f, + 0x12, 0x02, 0x0a, 0x43, 0x99, 0x7f, 0xdb, 0x7f, 0x09, 0x04, 0x0a, 0x43, + 0x1b, 0x06, 0x13, 0x43, 0xe3, 0x61, 0x01, 0x23, 0x09, 0xe0, 0x10, 0x2a, + 0xdb, 0xd1, 0x22, 0x1c, 0x60, 0x6a, 0x1c, 0x32, 0x00, 0xf0, 0x5a, 0xfa, + 0x00, 0x28, 0xd4, 0xd0, 0x04, 0x23, 0x63, 0x72, 0x0f, 0x23, 0x00, 0x21, + 0x2b, 0x40, 0x23, 0x72, 0xe1, 0x60, 0x21, 0x61, 0x01, 0x20, 0x6a, 0x06, + 0x02, 0xd5, 0x20, 0x1c, 0xff, 0xf7, 0x60, 0xff, 0x38, 0xbd, 0xc0, 0x46, + 0x50, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0xf0, 0xb5, 0x45, 0x7a, + 0x87, 0xb0, 0x04, 0x1c, 0x0e, 0x1c, 0x01, 0x93, 0x00, 0x2d, 0x00, 0xd0, + 0x86, 0xe0, 0x10, 0x1c, 0x03, 0xa9, 0xff, 0xf7, 0xbb, 0xfd, 0x00, 0x28, + 0x00, 0xd1, 0x80, 0xe0, 0x72, 0x6a, 0x2f, 0x1c, 0x62, 0x62, 0xf5, 0x60, + 0x35, 0x61, 0x33, 0x69, 0xf2, 0x69, 0x93, 0x42, 0x26, 0xd2, 0xdb, 0x05, + 0x1b, 0x0f, 0x30, 0x1c, 0x00, 0x93, 0xff, 0xf7, 0x9f, 0xfe, 0x01, 0x1e, + 0x6f, 0xd0, 0x03, 0x78, 0x00, 0x2b, 0x01, 0xd0, 0xe5, 0x2b, 0x0b, 0xd1, + 0x00, 0x2f, 0x04, 0xd1, 0x00, 0x9b, 0x23, 0x76, 0x34, 0x4b, 0x1b, 0x68, + 0x63, 0x61, 0x0b, 0x78, 0x01, 0x27, 0x00, 0x2b, 0xe3, 0xd1, 0x0d, 0xe0, + 0x03, 0xa8, 0x0b, 0x22, 0x01, 0xf0, 0xb0, 0xfd, 0x00, 0x28, 0xdc, 0xd1, + 0x01, 0x9a, 0x30, 0x23, 0x13, 0x40, 0x30, 0x2b, 0x53, 0xd0, 0x20, 0x1c, + 0x00, 0x99, 0x4b, 0xe0, 0x01, 0x9a, 0x12, 0x23, 0x13, 0x40, 0x12, 0x2b, + 0x4b, 0xd1, 0x00, 0x2f, 0x06, 0xd0, 0x20, 0x1c, 0x01, 0x21, 0xff, 0xf7, + 0x6f, 0xfd, 0x06, 0x1e, 0x0a, 0xd1, 0x42, 0xe0, 0x73, 0x7a, 0x02, 0x2b, + 0x3f, 0xd0, 0x30, 0x1c, 0xff, 0xf7, 0x40, 0xfd, 0x00, 0x28, 0x3a, 0xd0, + 0x1f, 0x4e, 0x27, 0x76, 0x00, 0x21, 0x20, 0x22, 0x30, 0x1c, 0x01, 0xf0, + 0xa1, 0xfd, 0x30, 0x1c, 0x03, 0xa9, 0x0b, 0x22, 0x01, 0xf0, 0x93, 0xfd, + 0x1a, 0x4b, 0x1b, 0x68, 0x00, 0x2b, 0x05, 0xd0, 0x30, 0x1c, 0x31, 0x1c, + 0x10, 0x30, 0x0e, 0x31, 0x98, 0x47, 0x06, 0xe0, 0x21, 0x22, 0x32, 0x74, + 0xb3, 0x73, 0x28, 0x22, 0x08, 0x23, 0x72, 0x74, 0xf3, 0x73, 0x73, 0x7c, + 0x32, 0x7c, 0x1b, 0x02, 0x13, 0x43, 0xff, 0x22, 0x1a, 0x40, 0x1b, 0x0a, + 0xf3, 0x74, 0x73, 0x76, 0xf3, 0x7b, 0xb2, 0x74, 0x32, 0x76, 0xb2, 0x7b, + 0x1b, 0x02, 0x13, 0x43, 0xb3, 0x75, 0x1b, 0x0a, 0xf3, 0x75, 0x00, 0xf0, + 0x21, 0xf9, 0x00, 0x28, 0x07, 0xd0, 0x21, 0x7e, 0x01, 0x9a, 0x20, 0x1c, + 0xff, 0xf7, 0x26, 0xff, 0x05, 0x1c, 0x00, 0xe0, 0x00, 0x25, 0x28, 0x1c, + 0x07, 0xb0, 0xf0, 0xbd, 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x44, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x00, 0x21, 0x04, 0x1c, 0xff, 0xf7, + 0xbb, 0xfe, 0x00, 0x28, 0x0b, 0xd0, 0x20, 0x1c, 0x01, 0x21, 0xff, 0xf7, + 0x15, 0xfd, 0x00, 0x28, 0x05, 0xd0, 0xe5, 0x23, 0x03, 0x70, 0x00, 0x23, + 0x63, 0x72, 0x00, 0xf0, 0xfb, 0xf8, 0x10, 0xbd, 0x10, 0xb5, 0x0a, 0x1c, + 0x0a, 0x49, 0x8a, 0xb0, 0x08, 0x31, 0x00, 0x23, 0x04, 0x1c, 0x00, 0x91, + 0x69, 0x46, 0x4b, 0x72, 0x01, 0x93, 0x68, 0x46, 0x21, 0x1c, 0x02, 0x23, + 0xff, 0xf7, 0x42, 0xff, 0x00, 0x28, 0x02, 0xd0, 0x68, 0x46, 0xff, 0xf7, + 0xd7, 0xff, 0x0a, 0xb0, 0x10, 0xbd, 0xc0, 0x46, 0x08, 0x4f, 0x00, 0x00, + 0xf0, 0xb5, 0x43, 0x7a, 0x87, 0xb0, 0x04, 0x1c, 0x0d, 0x1c, 0x03, 0x92, + 0x01, 0x2b, 0x0d, 0xd1, 0x03, 0x7a, 0x99, 0x07, 0x0a, 0xd5, 0x5a, 0x07, + 0x0c, 0xd5, 0xe1, 0x69, 0x22, 0x69, 0x8a, 0x42, 0x08, 0xd0, 0x20, 0x1c, + 0xff, 0xf7, 0x06, 0xfe, 0x00, 0x28, 0x03, 0xd1, 0x01, 0x23, 0x63, 0x60, + 0x00, 0x20, 0xaa, 0xe0, 0x03, 0x9b, 0x01, 0x93, 0x3b, 0xe0, 0x60, 0x6a, + 0x73, 0x0a, 0x07, 0x79, 0xf6, 0x05, 0x01, 0x3f, 0x1f, 0x40, 0xff, 0xb2, + 0xf6, 0x0d, 0x00, 0x2f, 0x36, 0xd0, 0x80, 0x22, 0x92, 0x00, 0x92, 0x1b, + 0x01, 0x99, 0x92, 0xb2, 0x0b, 0x1c, 0x91, 0x42, 0x00, 0xd9, 0x13, 0x1c, + 0x9b, 0xb2, 0x02, 0x93, 0x63, 0x6a, 0xe1, 0x68, 0x1a, 0x7c, 0x02, 0x39, + 0x91, 0x40, 0x5a, 0x69, 0x8b, 0x18, 0x02, 0x9a, 0xdf, 0x19, 0x80, 0x23, + 0x9b, 0x00, 0x9a, 0x42, 0x3f, 0xd1, 0x44, 0x4b, 0x19, 0x68, 0xb9, 0x42, + 0x02, 0xd1, 0x01, 0x22, 0x52, 0x42, 0x1a, 0x60, 0x41, 0x4b, 0x39, 0x1c, + 0x18, 0x68, 0x2a, 0x1c, 0xff, 0xf7, 0x22, 0xfc, 0x00, 0x28, 0xc7, 0xd0, + 0x80, 0x22, 0x92, 0x00, 0xad, 0x18, 0x01, 0x99, 0x02, 0x9a, 0x8b, 0x1a, + 0x21, 0x69, 0x9b, 0xb2, 0x01, 0x93, 0x8b, 0x18, 0x23, 0x61, 0x01, 0x9a, + 0x26, 0x69, 0x00, 0x2a, 0xbf, 0xd1, 0x49, 0xe0, 0x00, 0x2e, 0xc6, 0xd1, + 0xe1, 0x68, 0x00, 0x29, 0x03, 0xd1, 0x23, 0x6a, 0x00, 0x2b, 0x16, 0xd1, + 0x0f, 0xe0, 0x05, 0xaa, 0x00, 0xf0, 0xe2, 0xf8, 0x00, 0x28, 0x58, 0xd0, + 0x62, 0x6a, 0x05, 0x9b, 0x01, 0x32, 0xd2, 0x7f, 0x10, 0x2a, 0x01, 0xd1, + 0x2c, 0x4a, 0x00, 0xe0, 0x2c, 0x4a, 0x93, 0x42, 0x05, 0xd3, 0x20, 0x1c, + 0xff, 0xf7, 0x3c, 0xfc, 0x00, 0x28, 0xaa, 0xd1, 0x98, 0xe7, 0xe3, 0x60, + 0xa7, 0xe7, 0x00, 0x2e, 0x0f, 0xd1, 0x23, 0x69, 0xe1, 0x69, 0x8b, 0x42, + 0x0b, 0xd3, 0x00, 0xf0, 0x59, 0xf8, 0x00, 0x28, 0x8c, 0xd0, 0x1f, 0x4b, + 0x01, 0x21, 0x1f, 0x60, 0x21, 0x4b, 0x1a, 0x78, 0x0a, 0x43, 0x1a, 0x70, + 0x06, 0xe0, 0x38, 0x1c, 0x01, 0x21, 0x00, 0xf0, 0x75, 0xf8, 0x00, 0x28, + 0x00, 0xd1, 0x7d, 0xe7, 0x1c, 0x4b, 0x2a, 0x1c, 0xf6, 0x18, 0x02, 0x9b, + 0xf1, 0x18, 0x33, 0x1c, 0x8b, 0x42, 0x04, 0xd0, 0x10, 0x78, 0x01, 0x32, + 0x18, 0x70, 0x01, 0x33, 0xf8, 0xe7, 0x9e, 0x1b, 0xad, 0x19, 0xa8, 0xe7, + 0xe1, 0x69, 0x23, 0x7a, 0x8e, 0x42, 0x01, 0xd9, 0xe6, 0x61, 0x06, 0xe0, + 0x12, 0x4a, 0x12, 0x68, 0x00, 0x2a, 0x06, 0xd0, 0x03, 0x9a, 0x00, 0x2a, + 0x03, 0xd0, 0x80, 0x22, 0x52, 0x42, 0x13, 0x43, 0x23, 0x72, 0x23, 0x7a, + 0x19, 0x07, 0x01, 0xd4, 0x03, 0x98, 0x06, 0xe0, 0x20, 0x1c, 0xff, 0xf7, + 0x8b, 0xfd, 0x00, 0x28, 0x00, 0xd1, 0x51, 0xe7, 0xf6, 0xe7, 0x07, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, + 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, 0x50, 0x03, 0x00, 0x20, + 0x50, 0x01, 0x00, 0x20, 0x44, 0x01, 0x00, 0x20, 0x07, 0xb5, 0x6b, 0x46, + 0xd9, 0x71, 0x07, 0x33, 0x19, 0x1c, 0x01, 0x22, 0xff, 0xf7, 0x22, 0xff, + 0x0e, 0xbd, 0x00, 0x00, 0xf8, 0xb5, 0x0f, 0x4f, 0x01, 0x20, 0x3b, 0x78, + 0x00, 0x2b, 0x18, 0xd0, 0x0d, 0x4e, 0x0e, 0x4b, 0x0e, 0x4d, 0x19, 0x68, + 0x30, 0x68, 0x2a, 0x1c, 0xff, 0xf7, 0x80, 0xfb, 0x00, 0x28, 0x0e, 0xd0, + 0x0b, 0x4c, 0x21, 0x68, 0x00, 0x29, 0x07, 0xd0, 0x30, 0x68, 0x2a, 0x1c, + 0xff, 0xf7, 0x76, 0xfb, 0x00, 0x28, 0x04, 0xd0, 0x00, 0x23, 0x23, 0x60, + 0x00, 0x23, 0x3b, 0x70, 0x01, 0x20, 0xf8, 0xbd, 0x50, 0x03, 0x00, 0x20, + 0x4c, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x48, 0x01, 0x00, 0x20, 0x70, 0xb5, 0x0d, 0x4d, 0x04, 0x1c, 0x2b, 0x68, + 0x0e, 0x1c, 0x83, 0x42, 0x0e, 0xd0, 0xff, 0xf7, 0xcd, 0xff, 0x00, 0x28, + 0x01, 0xd1, 0x00, 0x20, 0x0d, 0xe0, 0x08, 0x4b, 0x21, 0x1c, 0x18, 0x68, + 0x07, 0x4a, 0xff, 0xf7, 0x25, 0xfb, 0x00, 0x28, 0xf5, 0xd0, 0x2c, 0x60, + 0x05, 0x4b, 0x01, 0x20, 0x1a, 0x78, 0x16, 0x43, 0x1e, 0x70, 0x70, 0xbd, + 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x50, 0x03, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xae, 0xff, + 0x00, 0x28, 0x0f, 0xd0, 0x00, 0x23, 0x08, 0x4a, 0x00, 0x21, 0x99, 0x54, + 0x80, 0x22, 0x01, 0x33, 0x92, 0x00, 0x93, 0x42, 0xf7, 0xd1, 0x05, 0x4b, + 0x01, 0x20, 0x1c, 0x60, 0x04, 0x4b, 0x1a, 0x78, 0x02, 0x43, 0x1a, 0x70, + 0x10, 0xbd, 0xc0, 0x46, 0x50, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, + 0x50, 0x03, 0x00, 0x20, 0xc3, 0x68, 0x70, 0xb5, 0x01, 0x33, 0x0c, 0x1c, + 0x15, 0x1c, 0x99, 0x42, 0x01, 0xd9, 0x00, 0x20, 0x21, 0xe0, 0x46, 0x1c, + 0xf1, 0x7f, 0xc2, 0x69, 0xe3, 0x09, 0x10, 0x29, 0x00, 0xd1, 0x23, 0x0a, + 0x98, 0x18, 0x0d, 0x4b, 0x1b, 0x68, 0x98, 0x42, 0x07, 0xd1, 0xf2, 0x7f, + 0x0b, 0x4b, 0x10, 0x2a, 0x09, 0xd1, 0xe4, 0xb2, 0x64, 0x00, 0x1b, 0x5b, + 0x0b, 0xe0, 0x00, 0x21, 0xff, 0xf7, 0x9e, 0xff, 0x00, 0x28, 0xf2, 0xd1, + 0xe3, 0xe7, 0x7f, 0x22, 0x14, 0x40, 0xa4, 0x00, 0x1b, 0x59, 0x1b, 0x01, + 0x1b, 0x09, 0x2b, 0x60, 0x01, 0x20, 0x70, 0xbd, 0x00, 0x00, 0x00, 0x20, + 0x50, 0x01, 0x00, 0x20, 0x73, 0xb5, 0x05, 0x1c, 0x01, 0x91, 0x16, 0x1c, + 0x00, 0x24, 0x28, 0x1c, 0x01, 0x99, 0x01, 0xaa, 0xff, 0xf7, 0xc6, 0xff, + 0x00, 0x28, 0x10, 0xd0, 0x2a, 0x7c, 0x80, 0x23, 0x9b, 0x00, 0x93, 0x40, + 0xe4, 0x18, 0x6b, 0x1c, 0xdb, 0x7f, 0x01, 0x9a, 0x10, 0x2b, 0x01, 0xd1, + 0x03, 0x4b, 0x00, 0xe0, 0x03, 0x4b, 0x9a, 0x42, 0xe9, 0xd3, 0x34, 0x60, + 0x01, 0x20, 0x76, 0xbd, 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, + 0xf7, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x01, 0x92, 0x01, 0x29, 0x32, 0xd9, + 0xc3, 0x68, 0x00, 0x20, 0x01, 0x33, 0x99, 0x42, 0x2e, 0xd8, 0x6f, 0x1c, + 0xfa, 0x7f, 0xee, 0x69, 0xcb, 0x09, 0x10, 0x2a, 0x00, 0xd1, 0x0b, 0x0a, + 0x9e, 0x19, 0x14, 0x4b, 0x1b, 0x68, 0x9e, 0x42, 0x08, 0xd1, 0xfa, 0x7f, + 0x12, 0x4b, 0x10, 0x2a, 0x0b, 0xd1, 0xe4, 0xb2, 0x01, 0x9a, 0x64, 0x00, + 0x1a, 0x53, 0x0b, 0xe0, 0x30, 0x1c, 0x00, 0x21, 0xff, 0xf7, 0x48, 0xff, + 0x00, 0x28, 0xf0, 0xd1, 0x12, 0xe0, 0x7f, 0x22, 0x14, 0x40, 0x01, 0x9a, + 0xa4, 0x00, 0x1a, 0x51, 0x09, 0x4b, 0x01, 0x20, 0x1a, 0x78, 0x02, 0x43, + 0x1a, 0x70, 0x2b, 0x7e, 0x83, 0x42, 0x05, 0xd9, 0xab, 0x68, 0xf6, 0x18, + 0x05, 0x4b, 0x1e, 0x60, 0x00, 0xe0, 0x00, 0x20, 0xfe, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, 0x50, 0x03, 0x00, 0x20, + 0x48, 0x01, 0x00, 0x20, 0xf0, 0xb5, 0x15, 0x68, 0x87, 0xb0, 0x06, 0x1c, + 0x02, 0x91, 0x17, 0x1c, 0x00, 0x2d, 0x03, 0xd0, 0x00, 0x21, 0x01, 0x35, + 0x01, 0x91, 0x06, 0xe0, 0x02, 0x9b, 0x05, 0x68, 0x01, 0x3b, 0x5a, 0x42, + 0x53, 0x41, 0xdb, 0xb2, 0x01, 0x93, 0xf2, 0x68, 0x00, 0x23, 0x01, 0x32, + 0x03, 0x92, 0x2c, 0x1c, 0x00, 0x93, 0x00, 0x99, 0xf2, 0x68, 0x91, 0x42, + 0x21, 0xd2, 0x03, 0x9b, 0x9c, 0x42, 0x01, 0xd9, 0x02, 0x24, 0x25, 0x1c, + 0x30, 0x1c, 0x21, 0x1c, 0x05, 0xaa, 0xff, 0xf7, 0x43, 0xff, 0x00, 0x28, + 0x15, 0xd0, 0x05, 0x99, 0x63, 0x1c, 0x00, 0x29, 0x01, 0xd0, 0x1d, 0x1c, + 0x03, 0xe0, 0x02, 0x99, 0x5a, 0x1b, 0x8a, 0x42, 0x04, 0xd0, 0x00, 0x9a, + 0x1c, 0x1c, 0x01, 0x32, 0x00, 0x92, 0xe0, 0xe7, 0x30, 0x1c, 0x21, 0x1c, + 0x13, 0x4a, 0xff, 0xf7, 0x7f, 0xff, 0x00, 0x28, 0x0b, 0xd1, 0x00, 0x20, + 0x1d, 0xe0, 0x63, 0x1e, 0x30, 0x1c, 0x19, 0x1c, 0x22, 0x1c, 0x00, 0x93, + 0xff, 0xf7, 0x74, 0xff, 0x00, 0x28, 0xf4, 0xd0, 0x00, 0x9c, 0xac, 0x42, + 0xf3, 0xd8, 0x39, 0x68, 0x00, 0x29, 0x06, 0xd1, 0x01, 0x99, 0x3d, 0x60, + 0x00, 0x29, 0x09, 0xd0, 0x01, 0x35, 0x35, 0x60, 0x06, 0xe0, 0x30, 0x1c, + 0x2a, 0x1c, 0xff, 0xf7, 0x61, 0xff, 0x00, 0x28, 0xf2, 0xd1, 0xe0, 0xe7, + 0x01, 0x20, 0x07, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0xff, 0xff, 0xff, 0x0f, + 0x02, 0x23, 0x37, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x03, 0x60, 0x28, 0x1c, + 0x21, 0x1c, 0x01, 0xaa, 0xff, 0xf7, 0xfc, 0xfe, 0x00, 0x28, 0x12, 0xd0, + 0x28, 0x1c, 0x21, 0x1c, 0x00, 0x22, 0xff, 0xf7, 0x47, 0xff, 0x00, 0x28, + 0x0b, 0xd0, 0x6b, 0x1c, 0xdb, 0x7f, 0x01, 0x9c, 0x10, 0x2b, 0x01, 0xd1, + 0x04, 0x4b, 0x00, 0xe0, 0x04, 0x4b, 0x9c, 0x42, 0xe7, 0xd3, 0x01, 0x20, + 0x00, 0xe0, 0x00, 0x20, 0x3e, 0xbd, 0xc0, 0x46, 0xf8, 0xff, 0x00, 0x00, + 0xf8, 0xff, 0xff, 0x0f, 0xf8, 0xb5, 0x44, 0x4b, 0x04, 0x1c, 0x15, 0x1c, + 0x19, 0x60, 0x29, 0xd0, 0x04, 0x2a, 0x01, 0xd9, 0x00, 0x20, 0x7d, 0xe0, + 0x00, 0x20, 0x01, 0x1c, 0xff, 0xf7, 0x90, 0xfe, 0x00, 0x28, 0xf7, 0xd0, + 0x2d, 0x01, 0x3d, 0x4b, 0xa9, 0x35, 0xff, 0x35, 0x5d, 0x19, 0xaa, 0x79, + 0xab, 0x1d, 0x50, 0x06, 0xee, 0xd1, 0xea, 0x7c, 0xa9, 0x7c, 0x12, 0x02, + 0x0a, 0x43, 0x29, 0x7d, 0x09, 0x04, 0x0a, 0x43, 0x69, 0x7d, 0x09, 0x06, + 0x0a, 0x43, 0x63, 0x2a, 0xe2, 0xd9, 0xaa, 0x7b, 0xed, 0x7b, 0x2d, 0x02, + 0x15, 0x43, 0x9a, 0x7a, 0xdb, 0x7a, 0x12, 0x04, 0x15, 0x43, 0x1b, 0x06, + 0x1d, 0x43, 0xd7, 0xd0, 0x28, 0x1c, 0x00, 0x21, 0xff, 0xf7, 0x6a, 0xfe, + 0x00, 0x28, 0xd1, 0xd0, 0x2a, 0x4b, 0x19, 0x7b, 0xda, 0x7a, 0x09, 0x02, + 0x11, 0x43, 0x80, 0x22, 0x92, 0x00, 0x91, 0x42, 0xc8, 0xd1, 0x1a, 0x7c, + 0x00, 0x2a, 0xc5, 0xd0, 0xd9, 0x89, 0x00, 0x29, 0xc2, 0xd0, 0x59, 0x7b, + 0x00, 0x29, 0xbf, 0xd0, 0x22, 0x76, 0x00, 0x22, 0x21, 0x71, 0x22, 0x74, + 0x22, 0x7c, 0x01, 0x20, 0x90, 0x40, 0x81, 0x42, 0x04, 0xd0, 0x50, 0x1c, + 0x20, 0x74, 0x07, 0x2a, 0xf6, 0xd9, 0xb1, 0xe7, 0xd9, 0x8a, 0x00, 0x29, + 0x00, 0xd1, 0x59, 0x6a, 0xa1, 0x60, 0xd8, 0x89, 0x28, 0x18, 0xe0, 0x61, + 0x1f, 0x69, 0x3e, 0x02, 0x36, 0x0c, 0x66, 0x84, 0xb7, 0xb2, 0x1e, 0x7c, + 0x71, 0x43, 0x0e, 0x18, 0x13, 0x48, 0x79, 0x01, 0x09, 0x18, 0x49, 0x12, + 0x71, 0x18, 0x66, 0x62, 0x61, 0x61, 0x18, 0x7d, 0xde, 0x7c, 0x00, 0x02, + 0x30, 0x43, 0x00, 0xd1, 0x18, 0x6a, 0x6d, 0x1a, 0x28, 0x18, 0xd0, 0x40, + 0x02, 0x1c, 0xe0, 0x60, 0x0b, 0x48, 0x61, 0x1c, 0x82, 0x42, 0x01, 0xd8, + 0x0c, 0x23, 0x07, 0xe0, 0x09, 0x48, 0x82, 0x42, 0x01, 0xd8, 0x10, 0x23, + 0x02, 0xe0, 0xdb, 0x6a, 0x63, 0x62, 0x20, 0x23, 0xcb, 0x77, 0x01, 0x20, + 0xf8, 0xbd, 0xc0, 0x46, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0xff, 0x01, 0x00, 0x00, 0xf4, 0x0f, 0x00, 0x00, 0xf4, 0xff, 0x00, 0x00, + 0x08, 0xb5, 0x05, 0x49, 0x05, 0x4a, 0x06, 0x48, 0x00, 0xf0, 0x10, 0xf8, + 0x05, 0x4b, 0x06, 0x49, 0x00, 0x22, 0x1a, 0x70, 0x5a, 0x54, 0x08, 0xbd, + 0x00, 0x50, 0x00, 0x00, 0x01, 0x04, 0x00, 0x00, 0x54, 0x03, 0x00, 0x20, + 0x6c, 0x03, 0x00, 0x20, 0x02, 0x04, 0x00, 0x00, 0x30, 0xb5, 0x09, 0x4c, + 0x09, 0x4b, 0xa5, 0x68, 0x6d, 0x03, 0x6d, 0x0f, 0xad, 0x00, 0xeb, 0x58, + 0x03, 0x60, 0xa4, 0x68, 0x01, 0x61, 0xa4, 0xb2, 0x44, 0x60, 0x5c, 0x43, + 0x9b, 0x00, 0x84, 0x60, 0xc3, 0x60, 0x42, 0x61, 0x30, 0xbd, 0xc0, 0x46, + 0x00, 0x40, 0x00, 0x41, 0x00, 0x55, 0x00, 0x00, 0xf7, 0xb5, 0x1f, 0x4e, + 0x80, 0x27, 0x75, 0x68, 0x03, 0x33, 0x3d, 0x43, 0x9b, 0x08, 0x75, 0x60, + 0x00, 0x2b, 0x34, 0xd0, 0x1b, 0x4d, 0x35, 0x80, 0x35, 0x7d, 0xef, 0x07, + 0xfc, 0xd5, 0x1d, 0x1c, 0x5f, 0x1b, 0x01, 0x97, 0x07, 0x68, 0xbf, 0x08, + 0xbc, 0x46, 0x01, 0x9f, 0x67, 0x45, 0x1f, 0xd2, 0x00, 0x2d, 0x1d, 0xd0, + 0x17, 0x78, 0x01, 0x3d, 0x01, 0x97, 0xff, 0x27, 0xbc, 0x43, 0x01, 0x9f, + 0x3c, 0x43, 0x57, 0x78, 0x3f, 0x02, 0x01, 0x97, 0x0f, 0x4f, 0x3c, 0x40, + 0x01, 0x9f, 0x3c, 0x43, 0x97, 0x78, 0x3f, 0x04, 0xbc, 0x46, 0x0d, 0x4f, + 0x3c, 0x40, 0xd7, 0x78, 0xa4, 0xb2, 0x3f, 0x06, 0x00, 0x97, 0x67, 0x46, + 0x3c, 0x43, 0x00, 0x9f, 0x04, 0x32, 0x3c, 0x43, 0x10, 0xc1, 0xd7, 0xe7, + 0x07, 0x4b, 0x33, 0x80, 0x33, 0x7d, 0xdf, 0x07, 0xfc, 0xd5, 0x2b, 0x1c, + 0xc8, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x44, 0xa5, 0xff, 0xff, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, 0x04, 0xa5, 0xff, 0xff, + 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, 0x1a, 0x80, 0x1a, 0x7d, + 0xd1, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x16, 0x1c, + 0xeb, 0x68, 0x28, 0x1c, 0x21, 0x1c, 0x9e, 0x42, 0x05, 0xd9, 0xff, 0xf7, + 0xe7, 0xff, 0xeb, 0x68, 0xe4, 0x18, 0xf6, 0x1a, 0xf4, 0xe7, 0xff, 0xf7, + 0xe1, 0xff, 0x70, 0xbd, 0x43, 0x7a, 0x00, 0x2b, 0x04, 0xd1, 0x83, 0x72, + 0xc3, 0x72, 0xc3, 0x60, 0x01, 0x23, 0x43, 0x72, 0x70, 0x47, 0x30, 0xb5, + 0x85, 0xb0, 0x04, 0x1c, 0x02, 0xad, 0x00, 0x68, 0x02, 0x91, 0x03, 0x92, + 0x00, 0xf0, 0x90, 0xfc, 0x6b, 0x79, 0xe1, 0x79, 0x22, 0x7a, 0x00, 0x93, + 0x20, 0x68, 0x00, 0x23, 0x00, 0xf0, 0x2a, 0xfd, 0x29, 0x79, 0x20, 0x68, + 0x02, 0x9a, 0x00, 0xf0, 0x53, 0xfc, 0x20, 0x68, 0x00, 0xf0, 0x76, 0xfc, + 0x05, 0xb0, 0x30, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0x18, 0x26, 0xff, 0xf7, + 0xd7, 0xff, 0x20, 0x79, 0x33, 0x1c, 0x43, 0x43, 0x0d, 0x4d, 0x08, 0x21, + 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x10, 0xfb, 0xa0, 0x79, 0x33, 0x1c, + 0x43, 0x43, 0x08, 0x21, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x08, 0xfb, + 0x60, 0x79, 0x08, 0x21, 0x46, 0x43, 0xad, 0x19, 0x69, 0x56, 0x00, 0xf0, + 0x01, 0xfb, 0x04, 0x4b, 0x20, 0x1c, 0x06, 0xcb, 0xff, 0xf7, 0xc3, 0xff, + 0x70, 0xbd, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, 0x70, 0x07, 0x00, 0x20, + 0x07, 0xb5, 0x83, 0x7a, 0x00, 0x91, 0x01, 0x92, 0x00, 0x2b, 0x0d, 0xd0, + 0x9a, 0x07, 0x06, 0xd5, 0xef, 0xf3, 0x10, 0x83, 0x5a, 0x42, 0x53, 0x41, + 0xc3, 0x72, 0x72, 0xb6, 0x04, 0xe0, 0xda, 0x07, 0x02, 0xd5, 0x82, 0x89, + 0x03, 0x4b, 0x9a, 0x60, 0x00, 0x99, 0x01, 0x9a, 0xff, 0xf7, 0xa5, 0xff, + 0x07, 0xbd, 0xc0, 0x46, 0x00, 0x18, 0x00, 0x40, 0x83, 0x7a, 0x00, 0x2b, + 0x0b, 0xd0, 0x9a, 0x07, 0x04, 0xd5, 0xc3, 0x7a, 0x00, 0x2b, 0x06, 0xd0, + 0x62, 0xb6, 0x04, 0xe0, 0xda, 0x07, 0x02, 0xd5, 0x82, 0x89, 0x01, 0x4b, + 0xda, 0x60, 0x70, 0x47, 0x00, 0x18, 0x00, 0x40, 0x08, 0xb5, 0x00, 0x68, + 0x00, 0xf0, 0x2d, 0xfc, 0x08, 0xbd, 0x00, 0x00, 0x09, 0x4b, 0x0a, 0x4a, + 0x0a, 0x49, 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x09, 0x4b, + 0x19, 0x60, 0x0a, 0x21, 0x19, 0x71, 0x09, 0x21, 0x5a, 0x72, 0x99, 0x71, + 0xda, 0x71, 0x08, 0x21, 0x03, 0x22, 0x59, 0x71, 0x1a, 0x72, 0x70, 0x47, + 0x70, 0x07, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, 0x08, 0x09, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x7e, 0xfd, + 0x08, 0xbd, 0xc0, 0x46, 0x88, 0x07, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, + 0x00, 0xf0, 0x76, 0xfd, 0x08, 0xbd, 0xc0, 0x46, 0x44, 0x08, 0x00, 0x20, + 0x7f, 0xb5, 0x19, 0x49, 0x19, 0x48, 0x00, 0xf0, 0x41, 0xfb, 0x19, 0x49, + 0x19, 0x48, 0x00, 0xf0, 0x3d, 0xfb, 0x19, 0x4c, 0x19, 0x49, 0x20, 0x1c, + 0x00, 0xf0, 0x38, 0xfb, 0x18, 0x49, 0x19, 0x48, 0x00, 0xf0, 0x34, 0xfb, + 0x18, 0x49, 0x19, 0x48, 0x00, 0xf0, 0x30, 0xfb, 0x18, 0x4e, 0x19, 0x49, + 0x30, 0x1c, 0x00, 0xf0, 0x2b, 0xfb, 0x01, 0x25, 0x03, 0x23, 0x31, 0x1c, + 0x00, 0x93, 0x01, 0x95, 0x0d, 0x22, 0x0e, 0x23, 0x14, 0x48, 0x00, 0xf0, + 0x3b, 0xfd, 0x02, 0x23, 0x01, 0x93, 0x1c, 0x23, 0x02, 0x93, 0x1d, 0x23, + 0x00, 0x95, 0x03, 0x93, 0x21, 0x1c, 0x1b, 0x22, 0x1a, 0x23, 0x0f, 0x48, + 0x00, 0xf0, 0xfa, 0xfc, 0x7f, 0xbd, 0xc0, 0x46, 0x00, 0x08, 0x00, 0x42, + 0x04, 0x09, 0x00, 0x20, 0x00, 0x0c, 0x00, 0x42, 0x08, 0x09, 0x00, 0x20, + 0x0c, 0x09, 0x00, 0x20, 0x00, 0x10, 0x00, 0x42, 0x00, 0x14, 0x00, 0x42, + 0x00, 0x09, 0x00, 0x20, 0x00, 0x18, 0x00, 0x42, 0x10, 0x09, 0x00, 0x20, + 0x14, 0x09, 0x00, 0x20, 0x00, 0x1c, 0x00, 0x42, 0x88, 0x07, 0x00, 0x20, + 0x44, 0x08, 0x00, 0x20, 0xfe, 0xe7, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x4b, + 0x1b, 0x68, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, 0x08, 0xbd, 0xc0, 0x46, + 0x18, 0x09, 0x00, 0x20, 0x38, 0xb5, 0x0f, 0x49, 0x0f, 0x4c, 0xa1, 0x42, + 0x04, 0xd1, 0x00, 0xf0, 0x4f, 0xf8, 0xfe, 0xf7, 0xb7, 0xfa, 0x0b, 0xe0, + 0x0c, 0x4d, 0x8d, 0x42, 0xf7, 0xd0, 0x00, 0x23, 0xca, 0x18, 0xe8, 0x18, + 0xa2, 0x42, 0x04, 0xd2, 0x00, 0x68, 0x04, 0x33, 0x10, 0x60, 0xf7, 0xe7, + 0xfe, 0xe7, 0x90, 0x42, 0xeb, 0xd0, 0x06, 0x4b, 0x06, 0x4a, 0x93, 0x42, + 0xe7, 0xd2, 0x00, 0x22, 0x04, 0xc3, 0xf9, 0xe7, 0x00, 0x00, 0x00, 0x20, + 0xa0, 0x00, 0x00, 0x20, 0x48, 0x59, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x20, + 0xfc, 0x0d, 0x00, 0x20, 0x08, 0xb5, 0x00, 0xf0, 0x26, 0xf8, 0x00, 0x28, + 0x01, 0xd1, 0x00, 0xf0, 0x17, 0xf8, 0x08, 0xbd, 0x01, 0x4b, 0x18, 0x68, + 0x70, 0x47, 0xc0, 0x46, 0x1c, 0x09, 0x00, 0x20, 0x70, 0xb5, 0x04, 0x1e, + 0x08, 0xd0, 0x05, 0x4b, 0x1d, 0x68, 0x1e, 0x1c, 0x00, 0xf0, 0x12, 0xf8, + 0x33, 0x68, 0x5b, 0x1b, 0xa3, 0x42, 0xf9, 0xd3, 0x70, 0xbd, 0xc0, 0x46, + 0x1c, 0x09, 0x00, 0x20, 0x08, 0xb5, 0x03, 0x4b, 0x1a, 0x68, 0x01, 0x32, + 0x1a, 0x60, 0x00, 0xf0, 0x61, 0xfa, 0x08, 0xbd, 0x1c, 0x09, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, 0x70, 0xb5, 0x49, 0x4a, + 0x1e, 0x21, 0x53, 0x68, 0x02, 0x20, 0x8b, 0x43, 0x03, 0x43, 0x47, 0x49, + 0x53, 0x60, 0x8b, 0x69, 0x08, 0x24, 0x23, 0x43, 0x8b, 0x61, 0x45, 0x4c, + 0x45, 0x4b, 0x9c, 0x82, 0x9c, 0x8a, 0x20, 0x43, 0x98, 0x82, 0x10, 0x1c, + 0xda, 0x68, 0x94, 0x07, 0xfc, 0xd5, 0x42, 0x4a, 0x01, 0x24, 0x14, 0x70, + 0x14, 0x78, 0xe5, 0x07, 0x04, 0xd5, 0x3f, 0x4c, 0x64, 0x78, 0x64, 0xb2, + 0x00, 0x2c, 0xf7, 0xdb, 0x01, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, + 0x00, 0x2c, 0xfb, 0xdb, 0x3a, 0x4d, 0x39, 0x4c, 0x65, 0x60, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x82, 0x25, 0x35, 0x4c, 0xed, 0x01, + 0x65, 0x80, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x02, 0x24, + 0x9c, 0x84, 0xdc, 0x68, 0xe6, 0x06, 0xfc, 0xd5, 0x31, 0x4d, 0x2e, 0x4c, + 0xe5, 0x62, 0xdd, 0x68, 0x2c, 0x4c, 0xee, 0x06, 0xfb, 0xd5, 0xa5, 0x8c, + 0x2e, 0x4e, 0x35, 0x43, 0xa5, 0x84, 0xdd, 0x68, 0x28, 0x4c, 0xee, 0x06, + 0xfb, 0xd5, 0xa5, 0x8c, 0x02, 0x26, 0x35, 0x43, 0xa5, 0x84, 0xdc, 0x68, + 0x25, 0x06, 0xfc, 0xd5, 0x23, 0x4c, 0xe4, 0x68, 0x66, 0x06, 0xf8, 0xd5, + 0xdc, 0x68, 0xe5, 0x06, 0xfc, 0xd5, 0x00, 0x24, 0x94, 0x60, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x22, 0x4d, 0x1d, 0x4c, 0x65, 0x60, + 0x55, 0x78, 0x1c, 0x4c, 0x6d, 0xb2, 0x00, 0x2d, 0xfa, 0xdb, 0x1e, 0x6a, + 0x1e, 0x4d, 0x35, 0x40, 0x1d, 0x62, 0x1d, 0x6a, 0x80, 0x26, 0xb5, 0x43, + 0x1d, 0x62, 0x03, 0x23, 0xa3, 0x60, 0x1b, 0x4b, 0x63, 0x60, 0x53, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x00, 0x23, 0x0b, 0x72, 0x18, 0x4a, + 0x4b, 0x72, 0x8b, 0x72, 0xcb, 0x72, 0x17, 0x4b, 0xff, 0x21, 0x1a, 0x60, + 0x16, 0x4b, 0x17, 0x4a, 0x1b, 0x68, 0x12, 0x68, 0x5c, 0x01, 0xd2, 0x0e, + 0x21, 0x40, 0x11, 0x43, 0x9a, 0x06, 0x52, 0x0f, 0x12, 0x02, 0x0b, 0x1c, + 0x13, 0x43, 0x12, 0x4a, 0x13, 0x85, 0x43, 0x68, 0x80, 0x22, 0x13, 0x43, + 0x43, 0x60, 0x70, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x00, 0x04, 0x00, 0x40, + 0x0c, 0x06, 0x00, 0x00, 0x00, 0x08, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, + 0x01, 0x05, 0x01, 0x00, 0xb9, 0x05, 0xff, 0x7d, 0x04, 0x0a, 0x00, 0x00, + 0x00, 0x07, 0x03, 0x00, 0xff, 0xfc, 0xff, 0xff, 0x03, 0x06, 0x01, 0x00, + 0x00, 0x6c, 0xdc, 0x02, 0x04, 0x00, 0x00, 0x20, 0x24, 0x60, 0x80, 0x00, + 0x20, 0x60, 0x80, 0x00, 0x00, 0x40, 0x00, 0x42, 0x31, 0x4b, 0xfa, 0x21, + 0x18, 0x68, 0x10, 0xb5, 0x89, 0x00, 0x00, 0xf0, 0xe3, 0xfe, 0x2f, 0x4b, + 0x01, 0x38, 0x98, 0x42, 0x24, 0xd8, 0x2e, 0x4a, 0x2e, 0x4b, 0x50, 0x60, + 0x18, 0x6a, 0xc0, 0x21, 0x00, 0x02, 0x00, 0x0a, 0x09, 0x06, 0x01, 0x43, + 0x19, 0x62, 0x00, 0x24, 0x07, 0x21, 0x94, 0x60, 0x11, 0x60, 0x19, 0x6a, + 0x80, 0x22, 0x09, 0x02, 0x09, 0x0a, 0x12, 0x06, 0x0a, 0x43, 0x1a, 0x62, + 0x25, 0x4b, 0xfc, 0x21, 0x1a, 0x6a, 0x0a, 0x43, 0x1a, 0x62, 0x19, 0x6a, + 0xfc, 0x22, 0x92, 0x01, 0x0a, 0x43, 0x1a, 0x62, 0x19, 0x6a, 0xa0, 0x22, + 0xd2, 0x02, 0x0a, 0x43, 0x1a, 0x62, 0x00, 0xe0, 0xfe, 0xe7, 0x20, 0x1c, + 0x00, 0x21, 0x01, 0x34, 0x00, 0xf0, 0x70, 0xf8, 0x0f, 0x2c, 0xf8, 0xd1, + 0x1a, 0x4c, 0x63, 0x78, 0x5b, 0xb2, 0x00, 0x2b, 0xfa, 0xdb, 0x19, 0x4b, + 0x63, 0x80, 0x19, 0x4b, 0x5a, 0x7e, 0xd2, 0x09, 0x01, 0x2a, 0xfa, 0xd0, + 0xe4, 0x22, 0xd2, 0x00, 0x9a, 0x80, 0x3f, 0x22, 0xda, 0x70, 0x59, 0x7e, + 0x13, 0x4a, 0xc9, 0x09, 0x01, 0x29, 0xfa, 0xd0, 0xc0, 0x23, 0x5b, 0x01, + 0x00, 0x20, 0x13, 0x61, 0x90, 0x70, 0x00, 0xf0, 0x23, 0xf8, 0x63, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x0d, 0x4a, 0x09, 0x4b, 0x5a, 0x80, + 0x0c, 0x4b, 0xda, 0x79, 0xd2, 0x09, 0x01, 0x2a, 0xfa, 0xd0, 0x41, 0x22, + 0x5a, 0x70, 0x10, 0xbd, 0x04, 0x00, 0x00, 0x20, 0xff, 0xff, 0xff, 0x00, + 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, 0x00, 0x04, 0x00, 0x40, + 0x00, 0x0c, 0x00, 0x40, 0x1e, 0x40, 0x00, 0x00, 0x00, 0x40, 0x00, 0x42, + 0x21, 0x40, 0x00, 0x00, 0x00, 0x48, 0x00, 0x42, 0x00, 0xb5, 0x14, 0x4a, + 0x51, 0x7e, 0x13, 0x1c, 0xc9, 0x09, 0x01, 0x29, 0xf9, 0xd0, 0x01, 0x38, + 0x04, 0x28, 0x13, 0xd8, 0x19, 0x69, 0x10, 0x4a, 0x0a, 0x40, 0x1a, 0x61, + 0x5a, 0x78, 0x0f, 0x21, 0x8a, 0x43, 0x00, 0xf0, 0x55, 0xfe, 0x03, 0x05, + 0x09, 0x07, 0x03, 0x00, 0x01, 0x21, 0x02, 0xe0, 0x03, 0x21, 0x00, 0xe0, + 0x02, 0x21, 0x0a, 0x43, 0x5a, 0x70, 0x0a, 0xe0, 0x11, 0x69, 0xf0, 0x23, + 0x1b, 0x05, 0x0b, 0x43, 0x13, 0x61, 0x53, 0x78, 0x0f, 0x21, 0x8b, 0x43, + 0x02, 0x21, 0x0b, 0x43, 0x53, 0x70, 0x00, 0xbd, 0x00, 0x40, 0x00, 0x42, + 0xff, 0xff, 0xff, 0xf0, 0x10, 0xb5, 0x18, 0x24, 0x02, 0x1c, 0x20, 0x1c, + 0x50, 0x43, 0x27, 0x4b, 0x18, 0x18, 0x00, 0x7a, 0x40, 0xb2, 0x01, 0x30, + 0x46, 0xd0, 0x03, 0x29, 0x44, 0xd8, 0x08, 0x1c, 0x21, 0x1c, 0x00, 0xf0, + 0x29, 0xfe, 0x02, 0x33, 0x11, 0x21, 0x62, 0x43, 0x98, 0x56, 0x9a, 0x18, + 0xc3, 0x01, 0x1f, 0x48, 0x52, 0x68, 0x1b, 0x18, 0x99, 0x18, 0x40, 0x31, + 0x02, 0x20, 0x08, 0x70, 0x01, 0x21, 0x91, 0x40, 0x59, 0x60, 0x2f, 0xe0, + 0x62, 0x43, 0x98, 0x56, 0x18, 0x49, 0x9a, 0x18, 0x52, 0x68, 0xc3, 0x01, + 0x5b, 0x18, 0x99, 0x18, 0x40, 0x31, 0x06, 0x20, 0x08, 0x70, 0x01, 0x21, + 0x91, 0x40, 0x59, 0x60, 0x99, 0x61, 0x1f, 0xe0, 0x51, 0x43, 0x5a, 0x56, + 0x10, 0x48, 0x59, 0x18, 0x4b, 0x68, 0xd2, 0x01, 0x11, 0x18, 0xc8, 0x18, + 0x40, 0x30, 0x06, 0x24, 0x04, 0x70, 0x01, 0x20, 0x98, 0x40, 0x48, 0x60, + 0x0b, 0x49, 0x52, 0x18, 0x50, 0x60, 0x0d, 0xe0, 0x62, 0x43, 0x98, 0x56, + 0x9a, 0x18, 0xc3, 0x01, 0x06, 0x48, 0x52, 0x68, 0x1b, 0x18, 0x99, 0x18, + 0x40, 0x31, 0x02, 0x20, 0x08, 0x70, 0x01, 0x21, 0x91, 0x40, 0x99, 0x60, + 0x10, 0xbd, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x10, 0x44, 0x00, 0x41, 0x18, 0x23, 0x58, 0x43, 0x13, 0x4a, 0xf0, 0xb5, + 0x13, 0x18, 0x08, 0x24, 0x1c, 0x57, 0x01, 0x34, 0x1f, 0xd0, 0x82, 0x56, + 0x10, 0x4e, 0xd2, 0x01, 0x5d, 0x68, 0x01, 0x24, 0x90, 0x19, 0x23, 0x1c, + 0x86, 0x68, 0xab, 0x40, 0x1e, 0x42, 0x0b, 0xd1, 0x0e, 0x1c, 0x77, 0x1e, + 0xbe, 0x41, 0x40, 0x19, 0x34, 0x40, 0x40, 0x30, 0xa5, 0x00, 0x04, 0x78, + 0x04, 0x26, 0xb4, 0x43, 0x2c, 0x43, 0x04, 0x70, 0x00, 0x29, 0x03, 0xd1, + 0x05, 0x49, 0x52, 0x18, 0x53, 0x60, 0x02, 0xe0, 0x02, 0x4e, 0x92, 0x19, + 0x93, 0x61, 0xf0, 0xbd, 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x10, 0x44, 0x00, 0x41, 0x18, 0x22, 0x42, 0x43, 0xf8, 0xb5, 0x2d, 0x4d, + 0x08, 0x24, 0xaa, 0x18, 0x14, 0x57, 0x03, 0x1c, 0x62, 0x1c, 0x50, 0xd0, + 0x48, 0x1c, 0x00, 0x24, 0x0c, 0x28, 0x4c, 0xd8, 0x00, 0xf0, 0xa0, 0xfd, + 0x07, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x0a, 0x0a, 0x0a, + 0x0a, 0x00, 0x01, 0x24, 0x64, 0x42, 0x40, 0xe0, 0x09, 0x29, 0x02, 0xd1, + 0x18, 0x1c, 0x00, 0x21, 0x03, 0xe0, 0x0a, 0x29, 0x04, 0xd1, 0x18, 0x1c, + 0x02, 0x21, 0xff, 0xf7, 0x51, 0xff, 0x23, 0xe0, 0x00, 0x24, 0x0b, 0x29, + 0x31, 0xd1, 0x18, 0x1c, 0x01, 0x21, 0xff, 0xf7, 0x49, 0xff, 0x2c, 0xe0, + 0x18, 0x22, 0x53, 0x43, 0xea, 0x18, 0x52, 0x68, 0xeb, 0x56, 0x01, 0x20, + 0x14, 0x1c, 0x04, 0x40, 0x55, 0x08, 0xdb, 0x01, 0x00, 0x2c, 0x11, 0xd0, + 0x12, 0x4c, 0x1b, 0x19, 0x5d, 0x19, 0x30, 0x35, 0x2e, 0x78, 0x0c, 0x01, + 0x0f, 0x21, 0x31, 0x40, 0x21, 0x43, 0x9a, 0x18, 0xc9, 0xb2, 0x29, 0x70, + 0x40, 0x32, 0x13, 0x78, 0x18, 0x43, 0x10, 0x70, 0x00, 0x24, 0x0e, 0xe0, + 0x09, 0x4e, 0x0f, 0x27, 0x9b, 0x19, 0x5d, 0x19, 0x30, 0x35, 0x2e, 0x78, + 0x9a, 0x18, 0xbe, 0x43, 0x31, 0x43, 0xc9, 0xb2, 0x29, 0x70, 0x40, 0x32, + 0x13, 0x78, 0x18, 0x43, 0x10, 0x70, 0x20, 0x1c, 0xf8, 0xbd, 0xc0, 0x46, + 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0xf7, 0xb5, 0x8a, 0x18, + 0x06, 0x1c, 0x0d, 0x1c, 0x01, 0x92, 0x0c, 0x1c, 0x01, 0x9b, 0x67, 0x1b, + 0x9c, 0x42, 0x07, 0xd0, 0x33, 0x68, 0x21, 0x78, 0x1b, 0x68, 0x30, 0x1c, + 0x98, 0x47, 0x01, 0x34, 0x00, 0x28, 0xf3, 0xd1, 0x38, 0x1c, 0xfe, 0xbd, + 0x15, 0x4a, 0x13, 0x68, 0x58, 0x1c, 0x25, 0xd0, 0x01, 0x3b, 0x13, 0x60, + 0x00, 0x2b, 0x21, 0xd1, 0x72, 0xb6, 0x12, 0x4a, 0x12, 0x4b, 0x04, 0x32, + 0x9a, 0x42, 0x07, 0xd8, 0xbf, 0xf3, 0x4f, 0x8f, 0x10, 0x4a, 0x11, 0x4b, + 0xda, 0x60, 0xbf, 0xf3, 0x4f, 0x8f, 0x11, 0xe0, 0x0f, 0x4b, 0x19, 0x7d, + 0xc8, 0x07, 0xfb, 0xd5, 0x18, 0x8b, 0x20, 0x21, 0xff, 0x31, 0x92, 0x08, + 0x52, 0x00, 0x01, 0x43, 0x19, 0x83, 0xda, 0x61, 0x0a, 0x4a, 0x1a, 0x80, + 0x1a, 0x7d, 0xd1, 0x07, 0xfc, 0xd5, 0xe5, 0xe7, 0xc0, 0x46, 0xfd, 0xe7, + 0x70, 0x47, 0xc0, 0x46, 0x08, 0x00, 0x00, 0x20, 0x00, 0x20, 0x00, 0x00, + 0x03, 0x02, 0x00, 0x00, 0x04, 0x00, 0xfa, 0x05, 0x00, 0xed, 0x00, 0xe0, + 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, 0x01, 0x60, 0x70, 0x47, + 0xf7, 0xb5, 0x08, 0xac, 0x26, 0x78, 0x04, 0x68, 0x9d, 0x1e, 0x27, 0x68, + 0x6c, 0x1e, 0xa5, 0x41, 0xec, 0xb2, 0x92, 0x07, 0x05, 0x68, 0x3a, 0x43, + 0x27, 0x06, 0x3a, 0x43, 0x2a, 0x60, 0x02, 0x68, 0x07, 0x25, 0x29, 0x40, + 0x50, 0x68, 0xb5, 0x01, 0x00, 0x2c, 0x00, 0xd0, 0x5c, 0x03, 0x29, 0x43, + 0x01, 0x43, 0x0c, 0x43, 0x54, 0x60, 0xf7, 0xbd, 0x30, 0xb5, 0x03, 0x68, + 0xc0, 0x25, 0x1c, 0x68, 0xad, 0x03, 0x12, 0x05, 0x2a, 0x40, 0x22, 0x43, + 0xc0, 0x24, 0xa4, 0x02, 0x09, 0x04, 0x21, 0x40, 0x11, 0x43, 0x19, 0x60, + 0x03, 0x68, 0x5a, 0x68, 0x14, 0x43, 0x5c, 0x60, 0x30, 0xbd, 0x03, 0x68, + 0x01, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, 0x11, 0x68, + 0x01, 0x23, 0x19, 0x42, 0xfb, 0xd1, 0xd1, 0x69, 0x19, 0x42, 0xf8, 0xd1, + 0x70, 0x47, 0x03, 0x68, 0x02, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, + 0x02, 0x68, 0xd3, 0x69, 0x99, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, + 0x1a, 0x7e, 0xd1, 0x07, 0x02, 0xd4, 0x1a, 0x7e, 0x91, 0x07, 0xfc, 0xd5, + 0x70, 0x47, 0x03, 0x68, 0x00, 0x22, 0x5a, 0x83, 0x70, 0x47, 0x03, 0x68, + 0x18, 0x7e, 0x40, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, + 0xc0, 0x09, 0x70, 0x47, 0x03, 0x68, 0x80, 0x22, 0x19, 0x7e, 0x52, 0x42, + 0x0a, 0x43, 0x1a, 0x76, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x01, 0x23, + 0x18, 0x40, 0x70, 0x47, 0x03, 0x68, 0x18, 0x8d, 0xc0, 0xb2, 0x70, 0x47, + 0x03, 0x68, 0x1a, 0x7e, 0x01, 0x20, 0x02, 0x42, 0xfb, 0xd0, 0x19, 0x85, + 0x70, 0x47, 0x03, 0x68, 0x01, 0x21, 0x9a, 0x7d, 0x0a, 0x43, 0x9a, 0x75, + 0x70, 0x47, 0x03, 0x68, 0x01, 0x22, 0x1a, 0x75, 0x70, 0x47, 0x00, 0x00, + 0x70, 0xb5, 0x03, 0x68, 0x01, 0x26, 0x8d, 0x07, 0xed, 0x0f, 0x31, 0x40, + 0x1c, 0x68, 0x6d, 0x07, 0x09, 0x07, 0x29, 0x43, 0x21, 0x43, 0x19, 0x60, + 0x04, 0x68, 0x51, 0x00, 0x03, 0x48, 0x00, 0xf0, 0x79, 0xfc, 0x01, 0x38, + 0xc0, 0xb2, 0x20, 0x73, 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x6c, 0xdc, 0x02, + 0x03, 0x68, 0x01, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, + 0x11, 0x68, 0x01, 0x23, 0x19, 0x42, 0xfb, 0xd1, 0xd1, 0x69, 0x19, 0x42, + 0xf8, 0xd1, 0x70, 0x47, 0x03, 0x68, 0x02, 0x21, 0x1a, 0x68, 0x0a, 0x43, + 0x1a, 0x60, 0x02, 0x68, 0xd3, 0x69, 0x99, 0x07, 0xfc, 0xd4, 0x70, 0x47, + 0x03, 0x68, 0xda, 0x69, 0x91, 0x07, 0xfc, 0xd4, 0x1a, 0x68, 0x02, 0x21, + 0x8a, 0x43, 0x1a, 0x60, 0x70, 0x47, 0x03, 0x68, 0x9a, 0x6a, 0x52, 0x0a, + 0x52, 0x02, 0x11, 0x43, 0x99, 0x62, 0x03, 0x68, 0x1a, 0x7e, 0x51, 0x07, + 0xfc, 0xd5, 0x98, 0x6a, 0xc0, 0xb2, 0x70, 0x47, 0x03, 0x68, 0x22, 0x4a, + 0x30, 0xb5, 0x93, 0x42, 0x11, 0xd0, 0x21, 0x4a, 0x93, 0x42, 0x11, 0xd0, + 0x20, 0x4a, 0x93, 0x42, 0x11, 0xd0, 0x20, 0x4a, 0x93, 0x42, 0x11, 0xd0, + 0x1f, 0x4a, 0x93, 0x42, 0x11, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x30, 0xd1, + 0x0e, 0x23, 0x19, 0x22, 0x0d, 0xe0, 0x09, 0x23, 0x14, 0x22, 0x0a, 0xe0, + 0x0a, 0x23, 0x15, 0x22, 0x07, 0xe0, 0x0b, 0x23, 0x16, 0x22, 0x04, 0xe0, + 0x0c, 0x23, 0x17, 0x22, 0x01, 0xe0, 0x0d, 0x23, 0x18, 0x22, 0xdc, 0xb2, + 0x15, 0x49, 0x01, 0x20, 0x9b, 0x08, 0xa0, 0x40, 0x9b, 0x00, 0x08, 0x60, + 0x5b, 0x18, 0x03, 0x20, 0xc0, 0x21, 0x89, 0x00, 0x04, 0x40, 0x5d, 0x58, + 0xe0, 0x00, 0xff, 0x24, 0x84, 0x40, 0xa5, 0x43, 0x2c, 0x1c, 0xc0, 0x25, + 0x85, 0x40, 0x28, 0x1c, 0x20, 0x43, 0x58, 0x50, 0x80, 0x23, 0xdb, 0x01, + 0x1a, 0x43, 0x0a, 0x4b, 0x5a, 0x80, 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, + 0xfb, 0xdb, 0x30, 0xbd, 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, + 0x00, 0x10, 0x00, 0x42, 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, + 0x00, 0x1c, 0x00, 0x42, 0x00, 0xe1, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x40, + 0xf8, 0xb5, 0x04, 0x1c, 0x15, 0x1c, 0x0e, 0x1c, 0x1f, 0x1c, 0xff, 0xf7, + 0xa3, 0xff, 0x20, 0x1c, 0xff, 0xf7, 0x0b, 0xff, 0xb1, 0x00, 0x1c, 0x22, + 0x0a, 0x40, 0x69, 0x07, 0x23, 0x68, 0x09, 0x0c, 0x0a, 0x43, 0x1a, 0x60, + 0x22, 0x68, 0x84, 0x23, 0x93, 0x75, 0x01, 0x2e, 0x1a, 0xd1, 0x08, 0x21, + 0x01, 0x2d, 0x00, 0xd1, 0x10, 0x21, 0x0c, 0x4b, 0x79, 0x43, 0x18, 0x68, + 0xc0, 0x00, 0x00, 0xf0, 0xcd, 0xfb, 0x23, 0x68, 0x07, 0x21, 0x9a, 0x89, + 0x01, 0x40, 0xd2, 0x04, 0x49, 0x03, 0xd2, 0x0c, 0x0a, 0x43, 0x9a, 0x81, + 0x23, 0x68, 0x00, 0x04, 0xc2, 0x0c, 0x98, 0x89, 0x40, 0x0b, 0x40, 0x03, + 0x10, 0x43, 0x98, 0x81, 0xf8, 0xbd, 0xc0, 0x46, 0x04, 0x00, 0x00, 0x20, + 0xf7, 0xb5, 0x01, 0x93, 0x08, 0xab, 0x04, 0x1c, 0x1f, 0x78, 0x0d, 0x1c, + 0x16, 0x1c, 0xff, 0xf7, 0x3d, 0xff, 0x20, 0x1c, 0xff, 0xf7, 0x68, 0xff, + 0xbf, 0x07, 0x0c, 0x22, 0x17, 0x43, 0xc0, 0x22, 0x92, 0x03, 0x36, 0x05, + 0x16, 0x40, 0xc0, 0x22, 0x92, 0x02, 0x2d, 0x04, 0x23, 0x68, 0x3e, 0x43, + 0x01, 0x99, 0x15, 0x40, 0x35, 0x43, 0x07, 0x22, 0x1d, 0x60, 0x0a, 0x40, + 0x80, 0x21, 0x23, 0x68, 0x89, 0x02, 0x0a, 0x43, 0x5a, 0x60, 0xf7, 0xbd, + 0x01, 0x20, 0x70, 0x47, 0x08, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, + 0x98, 0x47, 0x08, 0xbd, 0x13, 0x04, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, + 0x00, 0x69, 0xff, 0xf7, 0xac, 0xfe, 0x20, 0x1c, 0x14, 0x30, 0x00, 0xf0, + 0x41, 0xfb, 0x20, 0x1c, 0x5c, 0x30, 0x00, 0xf0, 0x3d, 0xfb, 0x10, 0xbd, + 0x08, 0xb5, 0x14, 0x30, 0x00, 0xf0, 0x4a, 0xfb, 0x08, 0xbd, 0x10, 0xb5, + 0x04, 0x1c, 0x20, 0x1c, 0x5c, 0x30, 0x00, 0xf0, 0x43, 0xfb, 0x00, 0x28, + 0xf9, 0xd1, 0x20, 0x69, 0xff, 0xf7, 0xab, 0xfe, 0x10, 0xbd, 0x08, 0xb5, + 0x5c, 0x30, 0x00, 0xf0, 0x3f, 0xfb, 0x08, 0xbd, 0x70, 0xb5, 0x05, 0x1c, + 0x14, 0x35, 0x04, 0x1c, 0x28, 0x1c, 0x00, 0xf0, 0x23, 0xfb, 0x23, 0x1c, + 0xa8, 0x33, 0x1b, 0x78, 0x06, 0x1c, 0xff, 0x2b, 0x0a, 0xd0, 0x28, 0x1c, + 0x00, 0xf0, 0x2e, 0xfb, 0x0a, 0x28, 0x05, 0xdd, 0x23, 0x1c, 0xb0, 0x33, + 0xb4, 0x34, 0x1b, 0x68, 0x22, 0x68, 0x1a, 0x60, 0x30, 0x1c, 0x70, 0xbd, + 0x08, 0xb5, 0x14, 0x30, 0x00, 0xf0, 0x2a, 0xfb, 0x08, 0xbd, 0x70, 0xb5, + 0x04, 0x1c, 0x00, 0x69, 0x0e, 0x1c, 0xff, 0xf7, 0x9c, 0xfe, 0x25, 0x1c, + 0x5c, 0x35, 0x00, 0x28, 0x04, 0xd0, 0x28, 0x1c, 0x00, 0xf0, 0x0c, 0xfb, + 0x00, 0x28, 0x0c, 0xd0, 0x28, 0x1c, 0x00, 0xf0, 0x20, 0xfb, 0x00, 0x28, + 0xfa, 0xd1, 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0xe4, 0xfa, 0x20, 0x69, + 0xff, 0xf7, 0x97, 0xfe, 0x03, 0xe0, 0x20, 0x69, 0x31, 0x1c, 0xff, 0xf7, + 0x8b, 0xfe, 0x01, 0x20, 0x70, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x85, 0xb0, + 0x1d, 0x1c, 0x0a, 0xab, 0x1b, 0x78, 0x04, 0x1c, 0x00, 0x93, 0x0b, 0xab, + 0x1b, 0x78, 0x16, 0x1c, 0x01, 0x93, 0x0c, 0xab, 0x1b, 0x78, 0x0f, 0x1c, + 0x02, 0x93, 0x0d, 0xab, 0x1b, 0x78, 0x03, 0x93, 0x00, 0x23, 0x43, 0x60, + 0xfa, 0x23, 0x9b, 0x00, 0x83, 0x60, 0x0d, 0x4b, 0x08, 0x33, 0x03, 0x60, + 0x14, 0x30, 0x00, 0xf0, 0xb1, 0xfa, 0x20, 0x1c, 0x5c, 0x30, 0x00, 0xf0, + 0xad, 0xfa, 0x00, 0x9a, 0x23, 0x1c, 0xa4, 0x33, 0x27, 0x61, 0x9a, 0x70, + 0x01, 0x9a, 0x20, 0x1c, 0xda, 0x70, 0x02, 0x9a, 0x1e, 0x70, 0x1a, 0x71, + 0x03, 0x9a, 0x5d, 0x70, 0x1a, 0x75, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, + 0x80, 0x58, 0x00, 0x00, 0x30, 0xb5, 0x85, 0xb0, 0x04, 0x1c, 0x08, 0xa8, + 0x05, 0x78, 0x09, 0xa8, 0x00, 0x78, 0x00, 0x95, 0x01, 0x90, 0xff, 0x20, + 0x02, 0x90, 0x03, 0x90, 0x20, 0x1c, 0xff, 0xf7, 0xbd, 0xff, 0x20, 0x1c, + 0x05, 0xb0, 0x30, 0xbd, 0x38, 0xb5, 0x04, 0x1c, 0x00, 0x69, 0xff, 0xf7, + 0x24, 0xfe, 0x00, 0x28, 0x19, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x34, 0xfe, + 0x25, 0x1c, 0x14, 0x35, 0x01, 0x1c, 0x28, 0x1c, 0x00, 0xf0, 0x83, 0xfa, + 0x23, 0x1c, 0xa8, 0x33, 0x1b, 0x78, 0xff, 0x2b, 0x0b, 0xd0, 0x28, 0x1c, + 0x00, 0xf0, 0x9e, 0xfa, 0x09, 0x28, 0x06, 0xdc, 0x23, 0x1c, 0x22, 0x1c, + 0xac, 0x33, 0xb4, 0x32, 0x1b, 0x68, 0x12, 0x68, 0x1a, 0x60, 0x20, 0x69, + 0xff, 0xf7, 0x15, 0xfe, 0x00, 0x28, 0x11, 0xd0, 0x25, 0x1c, 0x5c, 0x35, + 0x28, 0x1c, 0x00, 0xf0, 0x85, 0xfa, 0x00, 0x28, 0x07, 0xd0, 0x28, 0x1c, + 0x00, 0xf0, 0x72, 0xfa, 0xc1, 0xb2, 0x20, 0x69, 0xff, 0xf7, 0x0e, 0xfe, + 0x02, 0xe0, 0x20, 0x69, 0xff, 0xf7, 0x17, 0xfe, 0x20, 0x69, 0xff, 0xf7, + 0xf3, 0xfd, 0x00, 0x28, 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0xf2, 0xfd, + 0x20, 0x69, 0xff, 0xf7, 0xe2, 0xfd, 0x38, 0xbd, 0xf0, 0x23, 0x08, 0x1c, + 0x18, 0x40, 0x30, 0x38, 0x43, 0x42, 0x58, 0x41, 0x70, 0x47, 0xf0, 0x23, + 0x1b, 0x01, 0x19, 0x40, 0x80, 0x23, 0x9b, 0x00, 0x99, 0x42, 0x0c, 0xd0, + 0xc0, 0x23, 0x9b, 0x00, 0x99, 0x42, 0x06, 0xd0, 0x80, 0x23, 0x5b, 0x00, + 0x05, 0x20, 0x99, 0x42, 0x04, 0xd0, 0x00, 0x20, 0x02, 0xe0, 0x07, 0x20, + 0x00, 0xe0, 0x06, 0x20, 0x70, 0x47, 0x0f, 0x23, 0x19, 0x40, 0x01, 0x29, + 0x05, 0xd0, 0x02, 0x39, 0x4b, 0x42, 0x4b, 0x41, 0x02, 0x20, 0xc0, 0x1a, + 0x00, 0xe0, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, 0xf0, 0xb5, 0x03, 0x1c, + 0x85, 0xb0, 0x03, 0x91, 0xa4, 0x33, 0x04, 0x1c, 0x18, 0x27, 0x18, 0x78, + 0x3b, 0x1c, 0x43, 0x43, 0x34, 0x4e, 0x08, 0x21, 0xf3, 0x18, 0x59, 0x56, + 0x15, 0x1c, 0xff, 0xf7, 0xa5, 0xfc, 0x23, 0x1c, 0xa5, 0x33, 0x18, 0x78, + 0x3b, 0x1c, 0x43, 0x43, 0x08, 0x21, 0xf3, 0x18, 0x59, 0x56, 0xff, 0xf7, + 0x9b, 0xfc, 0x23, 0x1c, 0xa7, 0x33, 0x1b, 0x78, 0x02, 0x2b, 0x0a, 0xd1, + 0x23, 0x1c, 0xb8, 0x33, 0x18, 0x78, 0xff, 0x28, 0x05, 0xd0, 0x47, 0x43, + 0x08, 0x21, 0xf7, 0x19, 0x79, 0x56, 0xff, 0xf7, 0x8b, 0xfc, 0x27, 0x1c, + 0xa8, 0x37, 0x38, 0x78, 0xff, 0x28, 0x1a, 0xd0, 0x01, 0x21, 0xff, 0xf7, + 0xf9, 0xfb, 0x3b, 0x78, 0x18, 0x22, 0x5a, 0x43, 0xb3, 0x56, 0x1f, 0x4f, + 0xdb, 0x01, 0x21, 0x1c, 0xac, 0x31, 0xd8, 0x19, 0x08, 0x60, 0x1d, 0x49, + 0xb6, 0x18, 0x5b, 0x18, 0x21, 0x1c, 0x72, 0x68, 0xb0, 0x31, 0x0b, 0x60, + 0x01, 0x21, 0x91, 0x40, 0x0a, 0x1c, 0x21, 0x1c, 0xb4, 0x31, 0x0a, 0x60, + 0x1a, 0x60, 0x01, 0x21, 0x0a, 0x1c, 0x03, 0x9b, 0x20, 0x69, 0xff, 0xf7, + 0x31, 0xfe, 0x29, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x88, 0xff, 0x29, 0x1c, + 0x07, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x99, 0xff, 0x29, 0x1c, 0x06, 0x1c, + 0x20, 0x1c, 0xff, 0xf7, 0x77, 0xff, 0x39, 0x1c, 0x00, 0x90, 0x33, 0x1c, + 0x20, 0x69, 0x01, 0x22, 0xff, 0xf7, 0x02, 0xfd, 0x23, 0x1c, 0xa7, 0x33, + 0x19, 0x78, 0x01, 0x3b, 0x1a, 0x78, 0x20, 0x69, 0xff, 0xf7, 0x16, 0xfd, + 0x20, 0x69, 0xff, 0xf7, 0x34, 0xfd, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, + 0x20, 0x55, 0x00, 0x00, 0x18, 0x44, 0x00, 0x41, 0x14, 0x44, 0x00, 0x41, + 0x3f, 0x20, 0x70, 0x47, 0x13, 0xb5, 0x02, 0x68, 0x6b, 0x46, 0xd9, 0x71, + 0x07, 0x33, 0x54, 0x68, 0x19, 0x1c, 0x01, 0x22, 0xa0, 0x47, 0x16, 0xbd, + 0x08, 0xb5, 0x00, 0x69, 0x02, 0x21, 0x00, 0xf0, 0x49, 0xf8, 0x08, 0xbd, + 0x08, 0xb5, 0x00, 0x69, 0x03, 0x21, 0x00, 0xf0, 0x59, 0xf8, 0x08, 0xbd, + 0x38, 0xb5, 0x0d, 0x1c, 0x04, 0x1c, 0x13, 0x1c, 0x00, 0x69, 0x03, 0x21, + 0x2a, 0x1c, 0x00, 0xf0, 0xf1, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x01, 0x23, + 0x63, 0x60, 0x38, 0xbd, 0x10, 0xb5, 0x05, 0x4c, 0x23, 0x68, 0x5a, 0x1c, + 0x04, 0xd1, 0x03, 0x68, 0x5b, 0x69, 0x98, 0x47, 0x20, 0x60, 0x03, 0x1c, + 0x18, 0x1c, 0x10, 0xbd, 0x0c, 0x00, 0x00, 0x20, 0x07, 0x4a, 0x08, 0xb5, + 0x13, 0x68, 0x59, 0x1c, 0x04, 0xd0, 0x01, 0x21, 0x49, 0x42, 0x11, 0x60, + 0x18, 0x1c, 0x03, 0xe0, 0x00, 0x69, 0x02, 0x21, 0x00, 0xf0, 0xc2, 0xf8, + 0x08, 0xbd, 0xc0, 0x46, 0x0c, 0x00, 0x00, 0x20, 0x06, 0x4b, 0xfa, 0x21, + 0x89, 0x00, 0x99, 0x60, 0x05, 0x49, 0x00, 0x22, 0x08, 0x31, 0x19, 0x60, + 0x04, 0x49, 0x5a, 0x60, 0x19, 0x61, 0x1a, 0x76, 0x70, 0x47, 0xc0, 0x46, + 0x20, 0x09, 0x00, 0x20, 0xb8, 0x58, 0x00, 0x00, 0xe0, 0x0c, 0x00, 0x20, + 0x08, 0xb5, 0x08, 0x4b, 0x8a, 0x00, 0xd0, 0x58, 0x00, 0x28, 0x03, 0xd0, + 0x03, 0x68, 0x9b, 0x68, 0x98, 0x47, 0x06, 0xe0, 0xc9, 0xb2, 0x04, 0x4b, + 0x49, 0x01, 0x59, 0x18, 0x88, 0x68, 0x80, 0x04, 0x80, 0x0c, 0x08, 0xbd, + 0xc4, 0x0c, 0x00, 0x20, 0xe4, 0x0c, 0x00, 0x20, 0x10, 0xb5, 0x0c, 0x1c, + 0xff, 0xf7, 0xe6, 0xff, 0x00, 0x28, 0x0c, 0xd0, 0x06, 0x4b, 0xe1, 0xb2, + 0x1b, 0x68, 0x08, 0x31, 0x49, 0x01, 0x59, 0x18, 0x4a, 0x79, 0x80, 0x23, + 0x5b, 0x42, 0x13, 0x43, 0x4b, 0x71, 0x02, 0x23, 0xcb, 0x71, 0x10, 0xbd, + 0xe4, 0x0c, 0x00, 0x20, 0x10, 0xb5, 0xc9, 0xb2, 0x0c, 0x48, 0x49, 0x01, + 0x43, 0x18, 0x9a, 0x68, 0x92, 0x04, 0x92, 0x0c, 0x3f, 0x2a, 0x08, 0xd9, + 0x14, 0x1c, 0x9a, 0x68, 0x40, 0x3c, 0xa4, 0x04, 0x92, 0x0b, 0xa4, 0x0c, + 0x92, 0x03, 0x22, 0x43, 0x02, 0xe0, 0x9a, 0x68, 0x92, 0x0b, 0x92, 0x03, + 0x9a, 0x60, 0x41, 0x18, 0x88, 0x68, 0xc0, 0xb2, 0x10, 0xbd, 0xc0, 0x46, + 0xe4, 0x0c, 0x00, 0x20, 0xf0, 0xb5, 0x1c, 0x1c, 0x2a, 0x4b, 0x85, 0xb0, + 0x1b, 0x68, 0x06, 0x1c, 0x0d, 0x1c, 0x02, 0x92, 0x00, 0x2b, 0x46, 0xd0, + 0x27, 0x4b, 0x8a, 0x00, 0xd0, 0x58, 0x00, 0x28, 0x05, 0xd0, 0x03, 0x68, + 0x02, 0x99, 0x5b, 0x68, 0x22, 0x1c, 0x98, 0x47, 0x3f, 0xe0, 0x30, 0x1c, + 0xff, 0xf7, 0x9e, 0xff, 0xa0, 0x42, 0x04, 0xd2, 0x30, 0x1c, 0x29, 0x1c, + 0xff, 0xf7, 0x98, 0xff, 0x04, 0x1c, 0x29, 0x1c, 0x30, 0x1c, 0xff, 0xf7, + 0xbf, 0xff, 0x1c, 0x4f, 0xe9, 0xb2, 0x4a, 0x01, 0x01, 0x91, 0x39, 0x68, + 0x03, 0x92, 0x8b, 0x18, 0xff, 0x33, 0x5a, 0x7a, 0x01, 0x21, 0x0a, 0x43, + 0x17, 0x49, 0x5a, 0x72, 0xab, 0x01, 0xc9, 0x18, 0x02, 0x98, 0x22, 0x1c, + 0x00, 0xf0, 0xb5, 0xf9, 0x00, 0x2c, 0x1b, 0xd0, 0x30, 0x1c, 0x29, 0x1c, + 0xff, 0xf7, 0x7a, 0xff, 0x00, 0x28, 0x15, 0xd1, 0x01, 0x9b, 0x3a, 0x68, + 0x08, 0x33, 0x5b, 0x01, 0xd3, 0x18, 0x19, 0x79, 0x40, 0x20, 0x01, 0x43, + 0x19, 0x71, 0x01, 0x21, 0xd9, 0x71, 0x03, 0x99, 0x53, 0x18, 0xff, 0x33, + 0x9a, 0x7a, 0x01, 0x21, 0x0a, 0x43, 0x9a, 0x72, 0x02, 0xe0, 0x01, 0x20, + 0x40, 0x42, 0x00, 0xe0, 0x20, 0x1c, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, + 0xe8, 0x0d, 0x00, 0x20, 0xc4, 0x0c, 0x00, 0x20, 0xe4, 0x0c, 0x00, 0x20, + 0x04, 0x0b, 0x00, 0x20, 0x13, 0xb5, 0x6c, 0x46, 0x07, 0x34, 0x22, 0x1c, + 0x01, 0x23, 0xff, 0xf7, 0x99, 0xff, 0x01, 0x28, 0x01, 0xd1, 0x20, 0x78, + 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x16, 0xbd, 0xf0, 0xb5, 0x1c, 0x1c, + 0x3a, 0x4b, 0x85, 0xb0, 0x1b, 0x68, 0x0e, 0x1c, 0x02, 0x92, 0x00, 0x2b, + 0x60, 0xd0, 0x80, 0x23, 0xdb, 0x01, 0x9c, 0x42, 0x5c, 0xd8, 0x00, 0x22, + 0x00, 0x92, 0x00, 0x2c, 0x56, 0xd0, 0x34, 0x4d, 0xf7, 0xb2, 0x2b, 0x68, + 0x01, 0x93, 0x3b, 0x1c, 0x08, 0x33, 0x01, 0x9a, 0x5b, 0x01, 0xd3, 0x18, + 0x9b, 0x79, 0xdb, 0x09, 0x1a, 0xd0, 0x2f, 0x4b, 0x2f, 0x49, 0x18, 0x68, + 0x00, 0xf0, 0xc2, 0xf8, 0x2e, 0x4b, 0x17, 0x21, 0x58, 0x43, 0x00, 0xf0, + 0xbd, 0xf8, 0x3b, 0x1c, 0x08, 0x33, 0x01, 0x9a, 0x5b, 0x01, 0xd3, 0x18, + 0xdb, 0x79, 0x9a, 0x07, 0x08, 0xd4, 0x29, 0x4b, 0x9a, 0x5d, 0x00, 0x2a, + 0x38, 0xd1, 0x42, 0x1e, 0x00, 0x28, 0x35, 0xd0, 0x10, 0x1c, 0xee, 0xe7, + 0x24, 0x4b, 0x00, 0x22, 0x9a, 0x55, 0x25, 0x1e, 0x3f, 0x2d, 0x00, 0xd9, + 0x3f, 0x25, 0x22, 0x4a, 0xb3, 0x01, 0xd3, 0x18, 0x18, 0x1c, 0x02, 0x99, + 0x2a, 0x1c, 0x03, 0x93, 0x00, 0xf0, 0x35, 0xf9, 0x18, 0x4a, 0x7b, 0x01, + 0xd3, 0x18, 0x03, 0x9a, 0xa9, 0x04, 0x5a, 0x61, 0x9a, 0x69, 0x89, 0x0c, + 0x92, 0x0b, 0x92, 0x03, 0x0a, 0x43, 0x9a, 0x61, 0x3b, 0x1c, 0x01, 0x9a, + 0x08, 0x33, 0x5b, 0x01, 0xd3, 0x18, 0x02, 0x22, 0xda, 0x71, 0x59, 0x79, + 0x80, 0x22, 0x52, 0x42, 0x0a, 0x43, 0x5a, 0x71, 0x00, 0x9b, 0x02, 0x9a, + 0x5b, 0x19, 0x52, 0x19, 0x00, 0x93, 0x64, 0x1b, 0x02, 0x92, 0xa6, 0xe7, + 0x00, 0x98, 0x0b, 0xe0, 0x01, 0x20, 0x08, 0xe0, 0x01, 0x22, 0x9a, 0x55, + 0x7b, 0x01, 0xed, 0x18, 0xab, 0x69, 0x10, 0x1c, 0x9b, 0x0b, 0x9b, 0x03, + 0xab, 0x61, 0x40, 0x42, 0x05, 0xb0, 0xf0, 0xbd, 0xe8, 0x0d, 0x00, 0x20, + 0xe4, 0x0c, 0x00, 0x20, 0x04, 0x00, 0x00, 0x20, 0x40, 0x42, 0x0f, 0x00, + 0x70, 0x11, 0x01, 0x00, 0x3c, 0x09, 0x00, 0x20, 0x44, 0x09, 0x00, 0x20, + 0x01, 0x4a, 0x02, 0x4b, 0x1a, 0x60, 0x70, 0x47, 0x00, 0x50, 0x00, 0x41, + 0xe4, 0x0c, 0x00, 0x20, 0x10, 0xb5, 0x00, 0x21, 0x40, 0x22, 0x04, 0x1c, + 0x00, 0xf0, 0xf2, 0xf8, 0x00, 0x23, 0x20, 0x1c, 0x23, 0x64, 0x63, 0x64, + 0x10, 0xbd, 0x02, 0x6c, 0x10, 0xb5, 0x3f, 0x23, 0x54, 0x1c, 0x23, 0x40, + 0x44, 0x6c, 0xa3, 0x42, 0x01, 0xd0, 0x81, 0x54, 0x03, 0x64, 0x10, 0xbd, + 0x00, 0x23, 0x03, 0x64, 0x43, 0x64, 0x70, 0x47, 0x43, 0x6c, 0x02, 0x6c, + 0x93, 0x42, 0x06, 0xd0, 0xc2, 0x5c, 0x3f, 0x21, 0x01, 0x33, 0x0b, 0x40, + 0x43, 0x64, 0x10, 0x1c, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x70, 0x47, + 0x02, 0x6c, 0x43, 0x6c, 0xd0, 0x1a, 0x00, 0xd5, 0x40, 0x30, 0x70, 0x47, + 0x03, 0x6c, 0x40, 0x6c, 0x83, 0x42, 0x02, 0xdb, 0xc0, 0x1a, 0x3f, 0x30, + 0x01, 0xe0, 0xc0, 0x1a, 0x01, 0x38, 0x70, 0x47, 0x43, 0x6c, 0x02, 0x6c, + 0x93, 0x42, 0x01, 0xd0, 0xc0, 0x5c, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, + 0x70, 0x47, 0x02, 0x6c, 0x3f, 0x23, 0x01, 0x32, 0x1a, 0x40, 0x43, 0x6c, + 0xd0, 0x1a, 0x43, 0x42, 0x58, 0x41, 0xc0, 0xb2, 0x70, 0x47, 0x00, 0x00, + 0x02, 0xb4, 0x71, 0x46, 0x49, 0x08, 0x49, 0x00, 0x09, 0x5c, 0x49, 0x00, + 0x8e, 0x44, 0x02, 0xbc, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x29, 0x34, 0xd0, + 0x01, 0x23, 0x00, 0x22, 0x10, 0xb4, 0x88, 0x42, 0x2c, 0xd3, 0x01, 0x24, + 0x24, 0x07, 0xa1, 0x42, 0x04, 0xd2, 0x81, 0x42, 0x02, 0xd2, 0x09, 0x01, + 0x1b, 0x01, 0xf8, 0xe7, 0xe4, 0x00, 0xa1, 0x42, 0x04, 0xd2, 0x81, 0x42, + 0x02, 0xd2, 0x49, 0x00, 0x5b, 0x00, 0xf8, 0xe7, 0x88, 0x42, 0x01, 0xd3, + 0x40, 0x1a, 0x1a, 0x43, 0x4c, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, + 0x5c, 0x08, 0x22, 0x43, 0x8c, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, + 0x9c, 0x08, 0x22, 0x43, 0xcc, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, + 0xdc, 0x08, 0x22, 0x43, 0x00, 0x28, 0x03, 0xd0, 0x1b, 0x09, 0x01, 0xd0, + 0x09, 0x09, 0xe3, 0xe7, 0x10, 0x1c, 0x10, 0xbc, 0x70, 0x47, 0x00, 0x28, + 0x01, 0xd0, 0x00, 0x20, 0xc0, 0x43, 0x07, 0xb4, 0x02, 0x48, 0x02, 0xa1, + 0x40, 0x18, 0x02, 0x90, 0x03, 0xbd, 0xc0, 0x46, 0x19, 0x00, 0x00, 0x00, + 0x00, 0x29, 0xf0, 0xd0, 0x03, 0xb5, 0xff, 0xf7, 0xb9, 0xff, 0x0e, 0xbc, + 0x42, 0x43, 0x89, 0x1a, 0x18, 0x47, 0xc0, 0x46, 0x70, 0x47, 0xc0, 0x46, + 0x70, 0xb5, 0x0e, 0x4b, 0x0e, 0x4d, 0x00, 0x24, 0xed, 0x1a, 0xad, 0x10, + 0x1e, 0x1c, 0xac, 0x42, 0x04, 0xd0, 0xa3, 0x00, 0xf3, 0x58, 0x98, 0x47, + 0x01, 0x34, 0xf8, 0xe7, 0x00, 0xf0, 0x32, 0xf9, 0x08, 0x4b, 0x09, 0x4d, + 0x00, 0x24, 0xed, 0x1a, 0xad, 0x10, 0x1e, 0x1c, 0xac, 0x42, 0x04, 0xd0, + 0xa3, 0x00, 0xf3, 0x58, 0x98, 0x47, 0x01, 0x34, 0xf8, 0xe7, 0x70, 0xbd, + 0x74, 0x00, 0x00, 0x20, 0x74, 0x00, 0x00, 0x20, 0x74, 0x00, 0x00, 0x20, + 0x98, 0x00, 0x00, 0x20, 0x08, 0xb5, 0x03, 0x4b, 0x01, 0x1c, 0x18, 0x68, + 0x00, 0xf0, 0x76, 0xf8, 0x08, 0xbd, 0xc0, 0x46, 0x70, 0x00, 0x00, 0x20, + 0x08, 0xb5, 0x03, 0x4b, 0x01, 0x1c, 0x18, 0x68, 0x00, 0xf0, 0x24, 0xf8, + 0x08, 0xbd, 0xc0, 0x46, 0x70, 0x00, 0x00, 0x20, 0x30, 0xb5, 0x00, 0x23, + 0x93, 0x42, 0x08, 0xd0, 0xc5, 0x5c, 0x01, 0x33, 0xcc, 0x18, 0x01, 0x3c, + 0x24, 0x78, 0xa5, 0x42, 0xf6, 0xd0, 0x28, 0x1b, 0x00, 0xe0, 0x00, 0x20, + 0x30, 0xbd, 0x10, 0xb5, 0x00, 0x23, 0x93, 0x42, 0x03, 0xd0, 0xcc, 0x5c, + 0xc4, 0x54, 0x01, 0x33, 0xf9, 0xe7, 0x10, 0xbd, 0x03, 0x1c, 0x82, 0x18, + 0x93, 0x42, 0x02, 0xd0, 0x19, 0x70, 0x01, 0x33, 0xfa, 0xe7, 0x70, 0x47, + 0x30, 0xb5, 0x00, 0x29, 0x40, 0xd0, 0x04, 0x39, 0x0b, 0x68, 0x00, 0x2b, + 0x00, 0xda, 0xc9, 0x18, 0x1e, 0x4a, 0x13, 0x68, 0x14, 0x1c, 0x00, 0x2b, + 0x02, 0xd1, 0x4b, 0x60, 0x11, 0x60, 0x33, 0xe0, 0x99, 0x42, 0x0f, 0xd2, + 0x08, 0x68, 0x0a, 0x18, 0x9a, 0x42, 0x05, 0xd1, 0x13, 0x68, 0x52, 0x68, + 0xc0, 0x18, 0x08, 0x60, 0x4a, 0x60, 0x00, 0xe0, 0x4b, 0x60, 0x21, 0x60, + 0x24, 0xe0, 0x8a, 0x42, 0x03, 0xd8, 0x13, 0x1c, 0x5a, 0x68, 0x00, 0x2a, + 0xf9, 0xd1, 0x1d, 0x68, 0x5c, 0x19, 0x8c, 0x42, 0x0b, 0xd1, 0x09, 0x68, + 0x69, 0x18, 0x58, 0x18, 0x19, 0x60, 0x90, 0x42, 0x14, 0xd1, 0x14, 0x68, + 0x52, 0x68, 0x09, 0x19, 0x19, 0x60, 0x5a, 0x60, 0x0e, 0xe0, 0x8c, 0x42, + 0x02, 0xd9, 0x0c, 0x23, 0x03, 0x60, 0x09, 0xe0, 0x08, 0x68, 0x0c, 0x18, + 0x94, 0x42, 0x03, 0xd1, 0x14, 0x68, 0x52, 0x68, 0x00, 0x19, 0x08, 0x60, + 0x4a, 0x60, 0x59, 0x60, 0x30, 0xbd, 0xc0, 0x46, 0xf0, 0x0d, 0x00, 0x20, + 0x70, 0xb5, 0x03, 0x23, 0xcd, 0x1c, 0x9d, 0x43, 0x08, 0x35, 0x06, 0x1c, + 0x0c, 0x2d, 0x01, 0xd2, 0x0c, 0x25, 0x01, 0xe0, 0x00, 0x2d, 0x3f, 0xdb, + 0x8d, 0x42, 0x3d, 0xd3, 0x20, 0x4b, 0x1c, 0x68, 0x1a, 0x1c, 0x21, 0x1c, + 0x00, 0x29, 0x13, 0xd0, 0x08, 0x68, 0x43, 0x1b, 0x0d, 0xd4, 0x0b, 0x2b, + 0x02, 0xd9, 0x0b, 0x60, 0xcc, 0x18, 0x1e, 0xe0, 0x8c, 0x42, 0x02, 0xd1, + 0x63, 0x68, 0x13, 0x60, 0x1a, 0xe0, 0x48, 0x68, 0x60, 0x60, 0x0c, 0x1c, + 0x16, 0xe0, 0x0c, 0x1c, 0x49, 0x68, 0xe9, 0xe7, 0x14, 0x4c, 0x20, 0x68, + 0x00, 0x28, 0x03, 0xd1, 0x30, 0x1c, 0x00, 0xf0, 0x25, 0xf8, 0x20, 0x60, + 0x30, 0x1c, 0x29, 0x1c, 0x00, 0xf0, 0x20, 0xf8, 0x43, 0x1c, 0x15, 0xd0, + 0xc4, 0x1c, 0x03, 0x23, 0x9c, 0x43, 0x84, 0x42, 0x0a, 0xd1, 0x25, 0x60, + 0x20, 0x1c, 0x0b, 0x30, 0x07, 0x22, 0x23, 0x1d, 0x90, 0x43, 0xc3, 0x1a, + 0x0b, 0xd0, 0x5a, 0x42, 0xe2, 0x50, 0x08, 0xe0, 0x21, 0x1a, 0x30, 0x1c, + 0x00, 0xf0, 0x0a, 0xf8, 0x01, 0x30, 0xee, 0xd1, 0x0c, 0x23, 0x33, 0x60, + 0x00, 0x20, 0x70, 0xbd, 0xf0, 0x0d, 0x00, 0x20, 0xec, 0x0d, 0x00, 0x20, + 0x38, 0xb5, 0x07, 0x4c, 0x00, 0x23, 0x05, 0x1c, 0x08, 0x1c, 0x23, 0x60, + 0x00, 0xf0, 0x2a, 0xf8, 0x43, 0x1c, 0x03, 0xd1, 0x23, 0x68, 0x00, 0x2b, + 0x00, 0xd0, 0x2b, 0x60, 0x38, 0xbd, 0xc0, 0x46, 0xf8, 0x0d, 0x00, 0x20, + 0xc9, 0xb2, 0x03, 0x78, 0x00, 0x2b, 0x03, 0xd0, 0x8b, 0x42, 0x04, 0xd0, + 0x01, 0x30, 0xf8, 0xe7, 0x00, 0x29, 0x00, 0xd0, 0x18, 0x1c, 0x70, 0x47, + 0x30, 0xb5, 0x03, 0x1c, 0x00, 0x2a, 0x07, 0xd0, 0x0c, 0x78, 0x01, 0x33, + 0x5d, 0x1e, 0x01, 0x3a, 0x2c, 0x70, 0x01, 0x31, 0x00, 0x2c, 0xf5, 0xd1, + 0x9a, 0x18, 0x93, 0x42, 0x03, 0xd0, 0x00, 0x21, 0x19, 0x70, 0x01, 0x33, + 0xf9, 0xe7, 0x30, 0xbd, 0x09, 0x4a, 0x13, 0x68, 0x00, 0x2b, 0x0c, 0xd0, + 0x18, 0x18, 0x69, 0x46, 0x88, 0x42, 0x02, 0xd8, 0x10, 0x60, 0x18, 0x1c, + 0x70, 0x47, 0x05, 0x4b, 0x0c, 0x22, 0x01, 0x20, 0x1a, 0x60, 0x40, 0x42, + 0xf8, 0xe7, 0x03, 0x4b, 0x13, 0x60, 0xef, 0xe7, 0xf4, 0x0d, 0x00, 0x20, + 0xf8, 0x0d, 0x00, 0x20, 0xfc, 0x0d, 0x00, 0x20, 0xf8, 0xb5, 0xc0, 0x46, + 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, 0xf8, 0xb5, 0xc0, 0x46, + 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, 0x55, 0x50, 0x44, 0x41, + 0x54, 0x45, 0x2e, 0x42, 0x49, 0x4e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1f, 0x22, 0x00, 0x00, + 0x33, 0x22, 0x00, 0x00, 0x19, 0x22, 0x00, 0x00, 0x5d, 0x22, 0x00, 0x00, + 0x61, 0x23, 0x00, 0x00, 0x8d, 0x22, 0x00, 0x00, 0xa1, 0x22, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x2f, 0x00, 0x7c, 0x3c, 0x3e, 0x5e, 0x2b, 0x3d, + 0x3f, 0x2f, 0x5b, 0x5d, 0x3b, 0x2c, 0x2a, 0x22, 0x5c, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x01, 0x34, 0x00, 0x00, 0xcd, 0x40, 0x00, 0x00, 0x19, 0x22, 0x00, 0x00, + 0x1d, 0x22, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x10, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, + 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, + 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x04, + 0x00, 0x04, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x01, + 0x00, 0x01, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x13, 0x00, 0x01, 0x01, + 0x01, 0x01, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x05, + 0x00, 0x05, 0x0a, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x05, + 0x01, 0x05, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x02, 0x00, + 0x02, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, + 0x03, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x02, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x03, + 0x01, 0x03, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x10, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x11, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0a, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0b, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x05, 0x00, 0x01, 0x00, + 0x01, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x06, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x07, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x0f, 0x00, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x02, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x03, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xef, 0x44, 0x00, 0x00, 0xcd, 0x40, 0x00, 0x00, 0xa7, 0x44, 0x00, 0x00, + 0x8f, 0x44, 0x00, 0x00, 0x85, 0x44, 0x00, 0x00, 0xb1, 0x44, 0x00, 0x00, + 0xe5, 0x44, 0x00, 0x00, 0x59, 0x44, 0x00, 0x00, 0x9d, 0x46, 0x00, 0x00, + 0x69, 0x44, 0x00, 0x00, 0x55, 0x44, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x95, 0x47, 0x00, 0x00, + 0xc1, 0x47, 0x00, 0x00, 0x91, 0x47, 0x00, 0x00, 0xb5, 0x47, 0x00, 0x00, + 0xa9, 0x47, 0x00, 0x00, 0xf9, 0x47, 0x00, 0x00, 0xdd, 0x47, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0xff, 0xff, 0xff, 0x40, 0x42, 0x0f, 0x00, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0xe4, 0x58, 0x00, 0x00, + 0x04, 0x59, 0x00, 0x00, 0x24, 0x59, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xe0, 0x58, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x20, 0xdd, 0x20, 0x00, 0x00, + 0x05, 0x22, 0x00, 0x00, 0xed, 0x26, 0x00, 0x00, 0xa9, 0x2b, 0x00, 0x00, + 0x55, 0x38, 0x00, 0x00, 0x85, 0x3a, 0x00, 0x00, 0xdd, 0x3a, 0x00, 0x00, + 0x1d, 0x48, 0x00, 0x00, 0xc1, 0x4a, 0x00, 0x00, 0xb5, 0x20, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00 diff --git a/libraries/SDU/src/boot/mkrnb1500.h b/libraries/SDU/src/boot/mkrnb1500.h new file mode 100644 index 0000000..c5a9e7a --- /dev/null +++ b/libraries/SDU/src/boot/mkrnb1500.h @@ -0,0 +1,1236 @@ + 0x00, 0x80, 0x00, 0x20, 0x7d, 0x46, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, + 0x65, 0x46, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, + 0xd1, 0x46, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, + 0x65, 0x46, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, + 0x65, 0x46, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, 0x69, 0x46, 0x00, 0x00, + 0x65, 0x46, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, + 0xcd, 0x3a, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, + 0xbd, 0x3a, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, + 0x65, 0x46, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, + 0x65, 0x46, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, + 0x65, 0x46, 0x00, 0x00, 0x65, 0x46, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0xa0, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0x44, 0x59, 0x00, 0x00, 0x08, 0xb5, 0x08, 0x4b, 0x00, 0x2b, 0x03, 0xd0, + 0x07, 0x48, 0x08, 0x49, 0x00, 0xe0, 0x00, 0xbf, 0x07, 0x48, 0x03, 0x68, + 0x00, 0x2b, 0x03, 0xd0, 0x06, 0x4b, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, + 0x08, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x00, 0x44, 0x59, 0x00, 0x00, + 0xa4, 0x00, 0x00, 0x20, 0x9c, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xf0, 0xb5, 0x33, 0x4c, 0xa5, 0x44, 0x02, 0xf0, 0xb9, 0xfb, 0x02, 0xf0, + 0xdd, 0xfd, 0x01, 0x20, 0x02, 0xf0, 0xe2, 0xfa, 0x2f, 0x4d, 0x04, 0x21, + 0x28, 0x1c, 0x00, 0xf0, 0xe7, 0xf9, 0x00, 0x28, 0x44, 0xd0, 0x2d, 0x4e, + 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0xbe, 0xfa, 0x00, 0x28, 0x3d, 0xd0, + 0x29, 0x1c, 0x01, 0xa8, 0x32, 0x1c, 0x01, 0x23, 0x00, 0xf0, 0x6e, 0xfa, + 0x01, 0xa8, 0x00, 0xf0, 0x00, 0xf9, 0x80, 0x21, 0x04, 0x1c, 0xc9, 0x01, + 0x88, 0x42, 0x2d, 0xd9, 0x01, 0xa8, 0x00, 0xf0, 0xe6, 0xf8, 0x22, 0x4a, + 0xc0, 0x21, 0xa7, 0x18, 0x21, 0x48, 0xc9, 0x01, 0x3a, 0x1c, 0x01, 0xf0, + 0xf5, 0xfb, 0xc0, 0x24, 0xe4, 0x01, 0x80, 0x22, 0x0a, 0xa9, 0x92, 0x00, + 0x01, 0xa8, 0x00, 0xf0, 0xcf, 0xf8, 0x80, 0x23, 0x21, 0x1c, 0x0a, 0xaa, + 0x9b, 0x00, 0x19, 0x48, 0x01, 0xf0, 0x8e, 0xfb, 0x80, 0x22, 0x92, 0x00, + 0xa3, 0x18, 0x17, 0x4a, 0xa4, 0x18, 0xbc, 0x42, 0x01, 0xd2, 0x1c, 0x1c, + 0xe9, 0xe7, 0x01, 0x24, 0x01, 0xa8, 0x00, 0xf0, 0xed, 0xf8, 0x00, 0x2c, + 0x06, 0xd0, 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0x8d, 0xfa, 0x01, 0xe0, + 0x00, 0x24, 0xf3, 0xe7, 0xc0, 0x23, 0xdb, 0x01, 0x1b, 0x68, 0x83, 0xf3, + 0x08, 0x88, 0x0c, 0x4b, 0xc0, 0x22, 0xd2, 0x01, 0x9a, 0x60, 0x0b, 0x4b, + 0x1b, 0x68, 0x18, 0x47, 0x00, 0x20, 0x8b, 0x23, 0x9b, 0x00, 0x9d, 0x44, + 0xf0, 0xbd, 0xc0, 0x46, 0xd4, 0xfd, 0xff, 0xff, 0xd4, 0x00, 0x00, 0x20, + 0x78, 0x4f, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xbc, 0x00, 0x00, 0x20, + 0x00, 0xa2, 0xff, 0xff, 0x00, 0xed, 0x00, 0xe0, 0x04, 0x60, 0x00, 0x00, + 0x08, 0xb5, 0x00, 0x21, 0x02, 0x48, 0x0a, 0x1c, 0x01, 0xf0, 0x38, 0xfb, + 0x08, 0xbd, 0xc0, 0x46, 0xbc, 0x00, 0x00, 0x20, 0x00, 0x20, 0x70, 0x47, + 0x70, 0x47, 0x13, 0xb5, 0x02, 0x68, 0x6b, 0x46, 0xd9, 0x71, 0x07, 0x33, + 0x54, 0x68, 0x19, 0x1c, 0x01, 0x22, 0xa0, 0x47, 0x16, 0xbd, 0x38, 0xb5, + 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x25, 0xa8, 0x42, 0x02, 0xd1, 0x01, 0x23, + 0x63, 0x60, 0x0a, 0xe0, 0x45, 0x60, 0x92, 0xb2, 0x01, 0xf0, 0x04, 0xf8, + 0x23, 0x6a, 0x5b, 0x68, 0x00, 0x2b, 0x02, 0xd0, 0x01, 0x23, 0x63, 0x60, + 0x28, 0x1c, 0x38, 0xbd, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x01, 0xd0, + 0x00, 0xf0, 0x42, 0xfe, 0x08, 0xbd, 0x00, 0x00, 0x13, 0xb5, 0x6c, 0x46, + 0x07, 0x34, 0x21, 0x1c, 0x01, 0x22, 0x00, 0xf0, 0x5d, 0xfd, 0x01, 0x28, + 0x01, 0xd1, 0x20, 0x78, 0x00, 0xe0, 0x01, 0x48, 0x00, 0xb2, 0x16, 0xbd, + 0xff, 0xff, 0x00, 0x00, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x02, 0xd0, + 0xff, 0xf7, 0xea, 0xff, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x08, 0xbd, + 0x38, 0xb5, 0x05, 0x1c, 0x00, 0x6a, 0x00, 0x28, 0x0a, 0xd0, 0xff, 0xf7, + 0xdf, 0xff, 0x04, 0x1c, 0x63, 0x1c, 0x05, 0xd0, 0x28, 0x6a, 0x01, 0x69, + 0x01, 0x39, 0x00, 0xf0, 0xe5, 0xfd, 0x20, 0x1c, 0x38, 0xbd, 0x00, 0x00, + 0xf8, 0xb5, 0xfa, 0x23, 0x9b, 0x00, 0x83, 0x60, 0x0d, 0x4b, 0x00, 0x25, + 0x08, 0x33, 0x04, 0x1c, 0x45, 0x60, 0x03, 0x60, 0x28, 0x20, 0x0f, 0x1c, + 0x16, 0x1c, 0x02, 0xf0, 0x23, 0xfd, 0x20, 0x62, 0xa8, 0x42, 0x0a, 0xd0, + 0x39, 0x1c, 0x28, 0x22, 0x02, 0xf0, 0x3f, 0xfd, 0x20, 0x1c, 0x10, 0x30, + 0x31, 0x1c, 0x0c, 0x22, 0x02, 0xf0, 0x04, 0xfe, 0x25, 0x77, 0x20, 0x1c, + 0xf8, 0xbd, 0xc0, 0x46, 0x88, 0x4f, 0x00, 0x00, 0xfa, 0x22, 0x92, 0x00, + 0x82, 0x60, 0x04, 0x4a, 0x00, 0x23, 0x08, 0x32, 0x43, 0x60, 0x02, 0x60, + 0x03, 0x62, 0x03, 0x74, 0x70, 0x47, 0xc0, 0x46, 0x88, 0x4f, 0x00, 0x00, + 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x01, 0xd0, 0x00, 0xf0, 0x02, 0xfd, + 0x08, 0xbd, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x04, 0xd0, 0x00, 0xf0, + 0xa5, 0xfd, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x08, 0xbd, 0x03, 0x6a, + 0x00, 0x2b, 0x01, 0xd0, 0x18, 0x69, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, + 0x70, 0x47, 0x00, 0x6a, 0x00, 0x28, 0x00, 0xd0, 0xc0, 0x69, 0x70, 0x47, + 0x38, 0xb5, 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x28, 0x0b, 0xd0, 0x20, 0x1c, + 0xff, 0xf7, 0xf3, 0xff, 0x05, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0xe7, 0xff, + 0x02, 0x4b, 0x28, 0x1a, 0x98, 0x42, 0x00, 0xd9, 0x18, 0x1c, 0x38, 0xbd, + 0xff, 0x7f, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x28, + 0x06, 0xd0, 0x00, 0xf0, 0xe7, 0xfd, 0x20, 0x6a, 0x02, 0xf0, 0xd0, 0xfc, + 0x00, 0x23, 0x23, 0x62, 0x10, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x0a, 0x1c, + 0x0c, 0x49, 0x8a, 0xb0, 0x04, 0x1c, 0x00, 0x23, 0x00, 0x91, 0x69, 0x46, + 0x4b, 0x72, 0x01, 0x93, 0x21, 0x1c, 0x68, 0x46, 0x01, 0x23, 0x00, 0xf0, + 0x81, 0xfe, 0x04, 0x1c, 0x60, 0x1e, 0x84, 0x41, 0xe4, 0xb2, 0x00, 0x2c, + 0x02, 0xd0, 0x68, 0x46, 0x00, 0xf0, 0xc8, 0xfd, 0x20, 0x1c, 0x0a, 0xb0, + 0x10, 0xbd, 0xc0, 0x46, 0xd0, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x01, 0x23, + 0x00, 0x2a, 0x05, 0xd0, 0x00, 0xf0, 0x1a, 0xff, 0x03, 0x1c, 0x58, 0x1e, + 0x83, 0x41, 0xdb, 0xb2, 0x18, 0x1c, 0x08, 0xbd, 0x38, 0xb5, 0x01, 0x22, + 0x05, 0x1c, 0x0c, 0x1c, 0x01, 0xf0, 0x94, 0xf9, 0x02, 0x1c, 0x01, 0x20, + 0x00, 0x2a, 0x03, 0xd1, 0x28, 0x1c, 0x21, 0x1c, 0x01, 0xf0, 0x8c, 0xf9, + 0x38, 0xbd, 0xf0, 0xb5, 0x0c, 0x68, 0x03, 0x5d, 0x2f, 0x3b, 0x5d, 0x42, + 0x6b, 0x41, 0xe4, 0x18, 0x27, 0x1c, 0x0c, 0x37, 0x23, 0x1c, 0xc5, 0x5c, + 0x1e, 0x1b, 0x2f, 0x2d, 0x09, 0xd0, 0x00, 0x2d, 0x07, 0xd0, 0x01, 0x33, + 0x16, 0x1b, 0xf6, 0x18, 0x01, 0x3e, 0x35, 0x70, 0xbb, 0x42, 0xf2, 0xd1, + 0x0c, 0x26, 0x00, 0x24, 0x94, 0x55, 0xc2, 0x5c, 0x2f, 0x3a, 0x54, 0x42, + 0x62, 0x41, 0x9b, 0x18, 0x0b, 0x60, 0xc0, 0x5c, 0x43, 0x1e, 0x98, 0x41, + 0xc0, 0xb2, 0xf0, 0xbd, 0xf0, 0xb5, 0xa1, 0xb0, 0x03, 0x90, 0x25, 0x48, + 0x0d, 0x1c, 0x04, 0x92, 0x05, 0x93, 0x0c, 0xaa, 0x00, 0x23, 0x16, 0xa9, + 0x0d, 0x93, 0x0c, 0x90, 0x53, 0x72, 0x17, 0x93, 0x16, 0x90, 0x4b, 0x72, + 0x07, 0x93, 0x2c, 0x1c, 0x00, 0x92, 0x07, 0xa9, 0x08, 0xaa, 0x03, 0x98, + 0xff, 0xf7, 0xc3, 0xff, 0x01, 0x26, 0x02, 0x1c, 0x72, 0x40, 0x01, 0x90, + 0xd2, 0xb2, 0x20, 0x1c, 0x08, 0xa9, 0x05, 0x9b, 0x04, 0x9f, 0xb8, 0x47, + 0x00, 0x28, 0x07, 0xd1, 0xac, 0x42, 0x01, 0xd1, 0x00, 0x20, 0x23, 0xe0, + 0x20, 0x1c, 0x00, 0xf0, 0x57, 0xfd, 0xf9, 0xe7, 0x01, 0x9f, 0x00, 0x2f, + 0x11, 0xd0, 0x33, 0x1c, 0x00, 0x98, 0x21, 0x1c, 0x08, 0xaa, 0x00, 0xf0, + 0xfd, 0xfd, 0x06, 0x1c, 0xac, 0x42, 0x0f, 0xd0, 0x20, 0x1c, 0x00, 0xf0, + 0x47, 0xfd, 0x00, 0x2e, 0xe8, 0xd0, 0x23, 0x1c, 0x00, 0x9c, 0x00, 0x93, + 0xd1, 0xe7, 0xac, 0x42, 0x02, 0xd0, 0x20, 0x1c, 0x00, 0xf0, 0x3c, 0xfd, + 0x30, 0x1c, 0x03, 0xe0, 0x00, 0x28, 0xdb, 0xd0, 0x16, 0xac, 0xf0, 0xe7, + 0x21, 0xb0, 0xf0, 0xbd, 0xd0, 0x4f, 0x00, 0x00, 0x38, 0xb5, 0x03, 0x1c, + 0x41, 0x33, 0x1b, 0x78, 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x2b, 0x02, 0xd0, + 0x38, 0x30, 0x00, 0xf0, 0x27, 0xfd, 0x20, 0x1c, 0x01, 0x21, 0x2a, 0x1c, + 0x00, 0xf0, 0xc8, 0xf9, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x0f, 0xe0, + 0x25, 0x1c, 0x10, 0x35, 0x28, 0x1c, 0x21, 0x1c, 0xff, 0xf7, 0x62, 0xff, + 0x00, 0x28, 0xf5, 0xd0, 0x20, 0x1c, 0x38, 0x30, 0x29, 0x1c, 0x00, 0xf0, + 0xcf, 0xfb, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x38, 0xbd, 0x00, 0x00, + 0x4b, 0x68, 0x43, 0x60, 0x0a, 0x4b, 0x03, 0x60, 0x0b, 0x7a, 0x03, 0x72, + 0x4b, 0x7a, 0x43, 0x72, 0xcb, 0x68, 0xc3, 0x60, 0x0b, 0x69, 0x03, 0x61, + 0x4b, 0x69, 0x43, 0x61, 0x0b, 0x7e, 0x03, 0x76, 0xcb, 0x69, 0xc3, 0x61, + 0x0b, 0x6a, 0x49, 0x6a, 0x03, 0x62, 0x41, 0x62, 0x70, 0x47, 0xc0, 0x46, + 0xd0, 0x4f, 0x00, 0x00, 0xf0, 0xb5, 0x9d, 0xb0, 0x08, 0xae, 0x02, 0x92, + 0x03, 0x93, 0x27, 0x4a, 0x00, 0x23, 0x12, 0xaf, 0x05, 0x1c, 0x73, 0x60, + 0x7b, 0x60, 0x10, 0x31, 0x30, 0x1c, 0x08, 0x92, 0x73, 0x72, 0x12, 0x92, + 0x7b, 0x72, 0x00, 0xf0, 0x9d, 0xfb, 0x02, 0x9c, 0x20, 0x1c, 0x2f, 0x21, + 0x02, 0xf0, 0x9e, 0xfc, 0x00, 0x28, 0x2e, 0xd0, 0x23, 0x78, 0x2f, 0x2b, + 0x01, 0xd1, 0x01, 0x34, 0xf4, 0xe7, 0x00, 0x1b, 0xc0, 0xb2, 0x03, 0x1c, + 0x0c, 0x28, 0x00, 0xd9, 0x0c, 0x23, 0xdb, 0xb2, 0x1a, 0x1c, 0x21, 0x1c, + 0x04, 0xa8, 0x01, 0x93, 0x02, 0xf0, 0x96, 0xfc, 0x01, 0x9a, 0x00, 0x23, + 0x04, 0xa9, 0x38, 0x1c, 0x8b, 0x54, 0x00, 0xf0, 0xbf, 0xfc, 0x38, 0x1c, + 0x31, 0x1c, 0x04, 0xaa, 0x01, 0x23, 0x00, 0xf0, 0x69, 0xfd, 0x00, 0x28, + 0x04, 0xd1, 0x0c, 0x4b, 0x68, 0x60, 0x2b, 0x60, 0x68, 0x72, 0x10, 0xe0, + 0x01, 0x9b, 0x30, 0x1c, 0xe4, 0x18, 0x00, 0xf0, 0xad, 0xfc, 0x33, 0x1c, + 0x3e, 0x1c, 0x1f, 0x1c, 0xca, 0xe7, 0x02, 0x99, 0x03, 0x9a, 0x64, 0x1a, + 0x14, 0x60, 0x28, 0x1c, 0x31, 0x1c, 0xff, 0xf7, 0x95, 0xff, 0x28, 0x1c, + 0x1d, 0xb0, 0xf0, 0xbd, 0xd0, 0x4f, 0x00, 0x00, 0xf0, 0xb5, 0xa1, 0xb0, + 0x05, 0x1c, 0x1f, 0x1c, 0x02, 0xa8, 0x01, 0xab, 0x16, 0x1c, 0xff, 0xf7, + 0xa1, 0xff, 0x01, 0x9b, 0xf6, 0x18, 0x33, 0x78, 0x00, 0x2b, 0x07, 0xd1, + 0x02, 0xa9, 0x16, 0xa8, 0xff, 0xf7, 0x7e, 0xff, 0x28, 0x1c, 0x16, 0xa9, + 0x17, 0x4a, 0x28, 0xe0, 0x00, 0x23, 0x0c, 0xac, 0x63, 0x60, 0x63, 0x72, + 0x6b, 0x46, 0x11, 0x33, 0x14, 0x4a, 0x1b, 0x78, 0x0c, 0x92, 0x00, 0x2b, + 0x03, 0xd1, 0x28, 0x1c, 0xff, 0xf7, 0x4a, 0xfe, 0x1b, 0xe0, 0x20, 0x1c, + 0x02, 0xa9, 0x32, 0x1c, 0x3b, 0x1c, 0x00, 0xf0, 0x21, 0xfd, 0x00, 0x28, + 0xf3, 0xd0, 0x02, 0xa8, 0x00, 0xf0, 0x6c, 0xfc, 0x06, 0x23, 0x1f, 0x40, + 0x9f, 0x42, 0x03, 0xd1, 0x20, 0x1c, 0x13, 0x99, 0x00, 0xf0, 0xf6, 0xfb, + 0x21, 0x1c, 0x16, 0xa8, 0xff, 0xf7, 0x54, 0xff, 0x28, 0x1c, 0x16, 0xa9, + 0x32, 0x1c, 0xff, 0xf7, 0x0b, 0xfe, 0x28, 0x1c, 0x21, 0xb0, 0xf0, 0xbd, + 0xb0, 0x4f, 0x00, 0x00, 0xd0, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x1c, + 0x08, 0x1c, 0x19, 0x1c, 0x38, 0x31, 0x02, 0x4a, 0x00, 0x23, 0xff, 0xf7, + 0xc9, 0xfe, 0x08, 0xbd, 0xa5, 0x23, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x1c, + 0x08, 0x1c, 0x19, 0x1c, 0x38, 0x31, 0x02, 0x4a, 0x00, 0x23, 0xff, 0xf7, + 0xbd, 0xfe, 0x08, 0xbd, 0xe1, 0x23, 0x00, 0x00, 0x08, 0x4b, 0x02, 0x21, + 0x19, 0x61, 0x19, 0x1c, 0x00, 0x22, 0x30, 0x31, 0x0a, 0x70, 0x06, 0x49, + 0x5a, 0x71, 0x9a, 0x71, 0x9a, 0x72, 0x1a, 0x73, 0xda, 0x63, 0x99, 0x63, + 0x41, 0x33, 0x1a, 0x70, 0x70, 0x47, 0xc0, 0x46, 0xd4, 0x00, 0x00, 0x20, + 0xd0, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x01, 0x1c, 0x01, 0x48, 0x01, 0xf0, + 0xab, 0xf9, 0x08, 0xbd, 0x78, 0x07, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, + 0xff, 0x21, 0x01, 0xf0, 0xa3, 0xf9, 0x08, 0xbd, 0x78, 0x07, 0x00, 0x20, + 0x08, 0xb5, 0x01, 0x21, 0x00, 0x79, 0x02, 0xf0, 0xa7, 0xf9, 0x05, 0x4b, + 0x1a, 0x78, 0x00, 0x2a, 0x04, 0xd0, 0x00, 0x22, 0x03, 0x48, 0x1a, 0x70, + 0x01, 0xf0, 0x80, 0xf9, 0x08, 0xbd, 0xc0, 0x46, 0x40, 0x01, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x10, 0xb5, 0x08, 0x4b, 0x04, 0x1c, 0x1a, 0x78, + 0x00, 0x2a, 0x06, 0xd1, 0x01, 0x22, 0x1a, 0x70, 0x05, 0x4b, 0x06, 0x48, + 0x06, 0xcb, 0x01, 0xf0, 0x51, 0xf9, 0x20, 0x79, 0x00, 0x21, 0x02, 0xf0, + 0x87, 0xf9, 0x10, 0xbd, 0x40, 0x01, 0x00, 0x20, 0x38, 0x01, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x10, 0xb5, 0x83, 0x79, 0x04, 0x1c, 0x00, 0x2b, + 0x0d, 0xd0, 0x23, 0x89, 0x5a, 0x1c, 0x22, 0x81, 0x05, 0x4a, 0x93, 0x42, + 0x02, 0xd8, 0xff, 0xf7, 0xbf, 0xff, 0xf6, 0xe7, 0x20, 0x1c, 0xff, 0xf7, + 0xc3, 0xff, 0x00, 0x23, 0xa3, 0x71, 0x10, 0xbd, 0x01, 0x02, 0x00, 0x00, + 0x00, 0xb5, 0x06, 0x29, 0x03, 0xd9, 0x16, 0x23, 0x43, 0x71, 0x00, 0x20, + 0x1c, 0xe0, 0x0f, 0x4b, 0x05, 0x29, 0x13, 0xd8, 0x08, 0x1c, 0x00, 0x22, + 0x02, 0xf0, 0x28, 0xfa, 0x03, 0x05, 0x07, 0x09, 0x0b, 0x0d, 0x0b, 0x49, + 0x08, 0xe0, 0x0b, 0x49, 0x06, 0xe0, 0x0b, 0x49, 0x04, 0xe0, 0x0b, 0x49, + 0x02, 0xe0, 0x0b, 0x49, 0x00, 0xe0, 0x0b, 0x49, 0x19, 0x60, 0x02, 0xe0, + 0x0a, 0x4a, 0x1a, 0x60, 0x00, 0x22, 0x1a, 0x71, 0x5a, 0x71, 0x01, 0x20, + 0x00, 0xbd, 0xc0, 0x46, 0x38, 0x01, 0x00, 0x20, 0x00, 0x1b, 0xb7, 0x00, + 0x00, 0x09, 0x3d, 0x00, 0x80, 0x84, 0x1e, 0x00, 0x40, 0x42, 0x0f, 0x00, + 0x20, 0xa1, 0x07, 0x00, 0x90, 0xd0, 0x03, 0x00, 0x48, 0xe8, 0x01, 0x00, + 0x38, 0xb5, 0x0c, 0x1c, 0x01, 0xf0, 0x58, 0xff, 0x05, 0x1c, 0xff, 0xf7, + 0x79, 0xff, 0xff, 0x28, 0x06, 0xd0, 0x01, 0xf0, 0x51, 0xff, 0x40, 0x1b, + 0xa0, 0x42, 0xf6, 0xd3, 0x00, 0x20, 0x00, 0xe0, 0x01, 0x20, 0x38, 0xbd, + 0xf8, 0xb5, 0x04, 0x1c, 0x0e, 0x1c, 0x17, 0x1c, 0xff, 0xf7, 0x9c, 0xff, + 0x20, 0x1c, 0xff, 0xf7, 0x81, 0xff, 0x96, 0x21, 0x49, 0x00, 0x20, 0x1c, + 0xff, 0xf7, 0xe0, 0xff, 0x40, 0x20, 0x30, 0x43, 0xff, 0xf7, 0x54, 0xff, + 0x18, 0x25, 0x38, 0x1c, 0xe8, 0x40, 0xc0, 0xb2, 0x08, 0x3d, 0xff, 0xf7, + 0x4d, 0xff, 0x2b, 0x1c, 0x08, 0x33, 0xf6, 0xd1, 0x95, 0x20, 0x00, 0x2e, + 0x03, 0xd0, 0x87, 0x20, 0x08, 0x2e, 0x00, 0xd0, 0xff, 0x20, 0xff, 0xf7, + 0x41, 0xff, 0x00, 0x25, 0xff, 0xf7, 0x46, 0xff, 0x43, 0xb2, 0xe0, 0x72, + 0x00, 0x2b, 0x04, 0xda, 0xff, 0x2d, 0x02, 0xd0, 0x01, 0x35, 0xed, 0xb2, + 0xf4, 0xe7, 0xf8, 0xbd, 0xf7, 0xb5, 0x00, 0x25, 0x02, 0x71, 0x05, 0x73, + 0x85, 0x72, 0x85, 0x71, 0x45, 0x71, 0x04, 0x1c, 0x01, 0x91, 0x01, 0xf0, + 0x0d, 0xff, 0x01, 0x21, 0x07, 0x1c, 0x20, 0x79, 0x02, 0xf0, 0x86, 0xf8, + 0x01, 0x21, 0x20, 0x79, 0x02, 0xf0, 0xdc, 0xf8, 0x42, 0x4e, 0x30, 0x1c, + 0x01, 0xf0, 0x76, 0xf8, 0x41, 0x4b, 0x42, 0x49, 0x1d, 0x71, 0x5d, 0x71, + 0x19, 0x60, 0x30, 0x1c, 0x5a, 0x68, 0x01, 0xf0, 0x95, 0xf8, 0x0a, 0x25, + 0x01, 0x3d, 0xff, 0x20, 0xed, 0xb2, 0xff, 0xf7, 0x0d, 0xff, 0x00, 0x2d, + 0xf8, 0xd1, 0x30, 0x1c, 0x01, 0xf0, 0xa6, 0xf8, 0x20, 0x1c, 0xff, 0xf7, + 0x29, 0xff, 0x00, 0x21, 0x20, 0x1c, 0x0a, 0x1c, 0xff, 0xf7, 0x9a, 0xff, + 0x06, 0x1c, 0xe0, 0x72, 0x01, 0x28, 0x08, 0xd0, 0x01, 0xf0, 0xde, 0xfe, + 0xfa, 0x23, 0xc0, 0x1b, 0xdb, 0x00, 0x98, 0x42, 0xef, 0xd9, 0x01, 0x23, + 0x3b, 0xe0, 0xd5, 0x22, 0x20, 0x1c, 0x08, 0x21, 0x52, 0x00, 0xff, 0xf7, + 0x87, 0xff, 0x04, 0x23, 0x18, 0x42, 0x01, 0xd0, 0x26, 0x73, 0x0b, 0xe0, + 0x1e, 0x1c, 0xff, 0xf7, 0xed, 0xfe, 0x01, 0x3e, 0xf6, 0xb2, 0xe0, 0x72, + 0x00, 0x2e, 0xf8, 0xd1, 0x02, 0x23, 0xaa, 0x28, 0x25, 0xd1, 0x23, 0x73, + 0x26, 0x7b, 0x02, 0x3e, 0x73, 0x42, 0x5e, 0x41, 0xb6, 0x07, 0x37, 0x21, + 0x00, 0x22, 0x20, 0x1c, 0xff, 0xf7, 0x6c, 0xff, 0x32, 0x1c, 0x20, 0x1c, + 0x29, 0x21, 0xff, 0xf7, 0x67, 0xff, 0x02, 0x1c, 0xe0, 0x72, 0x08, 0xd0, + 0x01, 0xf0, 0xac, 0xfe, 0xfa, 0x23, 0xc0, 0x1b, 0xdb, 0x00, 0x98, 0x42, + 0xeb, 0xd9, 0x08, 0x23, 0x09, 0xe0, 0x23, 0x7b, 0x02, 0x2b, 0x19, 0xd1, + 0x20, 0x1c, 0x3a, 0x21, 0xff, 0xf7, 0x54, 0xff, 0x00, 0x28, 0x05, 0xd0, + 0x06, 0x23, 0x63, 0x71, 0x20, 0x1c, 0xff, 0xf7, 0xc3, 0xfe, 0x15, 0xe0, + 0xff, 0xf7, 0xb8, 0xfe, 0xc0, 0x23, 0x18, 0x40, 0x98, 0x42, 0x01, 0xd1, + 0x03, 0x23, 0x23, 0x73, 0xff, 0xf7, 0xb0, 0xfe, 0xff, 0xf7, 0xae, 0xfe, + 0xff, 0xf7, 0xac, 0xfe, 0x20, 0x1c, 0xff, 0xf7, 0xb1, 0xfe, 0x20, 0x1c, + 0x01, 0x99, 0xff, 0xf7, 0xef, 0xfe, 0x05, 0x1c, 0x28, 0x1c, 0xfe, 0xbd, + 0x78, 0x07, 0x00, 0x20, 0x38, 0x01, 0x00, 0x20, 0x90, 0xd0, 0x03, 0x00, + 0x38, 0xb5, 0x04, 0x1c, 0x01, 0xf0, 0x74, 0xfe, 0x05, 0x1c, 0xff, 0xf7, + 0x95, 0xfe, 0xe0, 0x72, 0xff, 0x28, 0x08, 0xd1, 0x01, 0xf0, 0x6c, 0xfe, + 0x96, 0x23, 0x40, 0x1b, 0x5b, 0x00, 0x98, 0x42, 0xf3, 0xd9, 0x0f, 0x23, + 0x02, 0xe0, 0xfe, 0x28, 0x06, 0xd0, 0x0d, 0x23, 0x20, 0x1c, 0x63, 0x71, + 0xff, 0xf7, 0x8a, 0xfe, 0x00, 0x20, 0x00, 0xe0, 0x01, 0x20, 0x38, 0xbd, + 0xf8, 0xb5, 0x04, 0x1c, 0x0f, 0x1c, 0x15, 0x1c, 0x1e, 0x1e, 0x45, 0xd0, + 0x9a, 0x18, 0x80, 0x23, 0x9b, 0x00, 0x9a, 0x42, 0x42, 0xdc, 0x83, 0x79, + 0x00, 0x2b, 0x05, 0xd0, 0x02, 0x68, 0x91, 0x42, 0x02, 0xd1, 0x03, 0x89, + 0xab, 0x42, 0x16, 0xd9, 0x23, 0x7b, 0x27, 0x60, 0x03, 0x2b, 0x00, 0xd0, + 0x7f, 0x02, 0x3a, 0x1c, 0x20, 0x1c, 0x11, 0x21, 0xff, 0xf7, 0xf2, 0xfe, + 0x07, 0x1e, 0x02, 0xd0, 0x03, 0x23, 0x63, 0x71, 0x2a, 0xe0, 0x20, 0x1c, + 0xff, 0xf7, 0xbc, 0xff, 0x00, 0x28, 0x25, 0xd0, 0x01, 0x23, 0x27, 0x81, + 0xa3, 0x71, 0x23, 0x89, 0xab, 0x42, 0x05, 0xd2, 0xff, 0xf7, 0x4e, 0xfe, + 0x23, 0x89, 0x01, 0x33, 0x23, 0x81, 0xf6, 0xe7, 0x06, 0x9d, 0x06, 0x9a, + 0xab, 0x1a, 0x9b, 0xb2, 0xb3, 0x42, 0x04, 0xd2, 0xff, 0xf7, 0x42, 0xfe, + 0x28, 0x70, 0x01, 0x35, 0xf5, 0xe7, 0x23, 0x89, 0xa2, 0x7a, 0xf3, 0x18, + 0x9b, 0xb2, 0x23, 0x81, 0x00, 0x2a, 0x02, 0xd0, 0x06, 0x4a, 0x93, 0x42, + 0x02, 0xd9, 0x20, 0x1c, 0xff, 0xf7, 0x66, 0xfe, 0x01, 0x20, 0x03, 0xe0, + 0x20, 0x1c, 0xff, 0xf7, 0x35, 0xfe, 0x00, 0x20, 0xf8, 0xbd, 0xc0, 0x46, + 0xff, 0x01, 0x00, 0x00, 0x07, 0xb5, 0x80, 0x23, 0x00, 0x92, 0x9b, 0x00, + 0x00, 0x22, 0xff, 0xf7, 0xa3, 0xff, 0x0e, 0xbd, 0x70, 0xb5, 0x05, 0x1c, + 0x08, 0x1c, 0x16, 0x1c, 0xff, 0xf7, 0x12, 0xfe, 0x00, 0x24, 0x30, 0x5d, + 0xff, 0xf7, 0x0e, 0xfe, 0x01, 0x34, 0x80, 0x23, 0x9b, 0x00, 0x9c, 0x42, + 0xf7, 0xd1, 0xff, 0x20, 0xff, 0xf7, 0x06, 0xfe, 0xff, 0x20, 0xff, 0xf7, + 0x03, 0xfe, 0xff, 0xf7, 0x09, 0xfe, 0x1f, 0x23, 0xe8, 0x72, 0x03, 0x40, + 0x01, 0x20, 0x05, 0x2b, 0x05, 0xd0, 0x11, 0x23, 0x28, 0x1c, 0x6b, 0x71, + 0xff, 0xf7, 0x06, 0xfe, 0x00, 0x20, 0x70, 0xbd, 0x70, 0xb5, 0x0b, 0x1c, + 0x04, 0x1c, 0x16, 0x1c, 0x00, 0x29, 0x01, 0xd1, 0x12, 0x23, 0x28, 0xe0, + 0x02, 0x7b, 0x03, 0x2a, 0x00, 0xd0, 0x4b, 0x02, 0x20, 0x1c, 0x18, 0x21, + 0x1a, 0x1c, 0xff, 0xf7, 0x7d, 0xfe, 0x05, 0x1e, 0x01, 0xd0, 0x04, 0x23, + 0x1b, 0xe0, 0x20, 0x1c, 0xfe, 0x21, 0x32, 0x1c, 0xff, 0xf7, 0xc2, 0xff, + 0x00, 0x28, 0x15, 0xd0, 0x96, 0x21, 0x20, 0x1c, 0x89, 0x00, 0xff, 0xf7, + 0x5b, 0xfe, 0x00, 0x28, 0x01, 0xd1, 0x15, 0x23, 0x0b, 0xe0, 0x20, 0x1c, + 0x0d, 0x21, 0x2a, 0x1c, 0xff, 0xf7, 0x64, 0xfe, 0x00, 0x28, 0x03, 0xd1, + 0xff, 0xf7, 0xce, 0xfd, 0x00, 0x28, 0x06, 0xd0, 0x14, 0x23, 0x63, 0x71, + 0x20, 0x1c, 0xff, 0xf7, 0xcf, 0xfd, 0x00, 0x20, 0x03, 0xe0, 0x20, 0x1c, + 0xff, 0xf7, 0xca, 0xfd, 0x01, 0x20, 0x70, 0xbd, 0x03, 0x4b, 0x04, 0x4a, + 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x70, 0x47, 0xc0, 0x46, + 0x38, 0x01, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, 0x02, 0x1c, 0x10, 0xb5, + 0x0c, 0x32, 0x04, 0x1c, 0x01, 0x21, 0x40, 0x6a, 0x00, 0xf0, 0x24, 0xfd, + 0x00, 0x28, 0x0a, 0xd0, 0x23, 0x6a, 0x01, 0x20, 0x00, 0x2b, 0x06, 0xd1, + 0xe3, 0x68, 0x22, 0x7a, 0x23, 0x62, 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, + 0x23, 0x72, 0x10, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xe6, 0xff, + 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x1b, 0xe0, 0x63, 0x6a, 0xe6, 0x68, + 0x1a, 0x7c, 0x02, 0x3e, 0x96, 0x40, 0x5a, 0x69, 0x1d, 0x79, 0xb6, 0x18, + 0x00, 0x2d, 0x08, 0xd0, 0x70, 0x1e, 0x40, 0x19, 0x00, 0xf0, 0x4c, 0xfc, + 0x00, 0x28, 0xed, 0xd0, 0x01, 0x3d, 0xed, 0xb2, 0xf4, 0xe7, 0x63, 0x6a, + 0x01, 0x20, 0x1a, 0x7c, 0x80, 0x23, 0x9b, 0x00, 0x93, 0x40, 0xe2, 0x69, + 0xd3, 0x18, 0xe3, 0x61, 0x70, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, + 0x40, 0x69, 0x00, 0xf0, 0x13, 0xfc, 0x00, 0x28, 0x03, 0xd0, 0x20, 0x7e, + 0x01, 0x4b, 0x40, 0x01, 0xc0, 0x18, 0x10, 0xbd, 0x50, 0x01, 0x00, 0x20, + 0xf0, 0xb5, 0x00, 0x23, 0x87, 0xb0, 0x07, 0x1c, 0x0e, 0x1c, 0x20, 0x22, + 0xf2, 0x54, 0x01, 0x33, 0x0b, 0x2b, 0xfa, 0xd1, 0x07, 0x21, 0x00, 0x25, + 0x01, 0x91, 0x3c, 0x78, 0x00, 0x2c, 0x2a, 0xd0, 0x2e, 0x2c, 0x06, 0xd1, + 0x01, 0x9b, 0x0a, 0x2b, 0x2b, 0xd0, 0x0a, 0x21, 0x08, 0x25, 0x01, 0x91, + 0x1f, 0xe0, 0x02, 0xa8, 0x14, 0x49, 0x10, 0x22, 0x02, 0xf0, 0x6f, 0xf8, + 0x00, 0x23, 0x02, 0xa9, 0xca, 0x5c, 0x00, 0x2a, 0x03, 0xd0, 0x01, 0x33, + 0xa2, 0x42, 0xf8, 0xd1, 0x19, 0xe0, 0x01, 0x9b, 0x9d, 0x42, 0x16, 0xd8, + 0x23, 0x1c, 0x21, 0x3b, 0x5d, 0x2b, 0x12, 0xd8, 0x22, 0x1c, 0x6b, 0x1c, + 0x61, 0x3a, 0xdb, 0xb2, 0x75, 0x19, 0x19, 0x2a, 0x01, 0xd8, 0x20, 0x3c, + 0xe4, 0xb2, 0x2c, 0x70, 0x1d, 0x1c, 0x01, 0x37, 0xd1, 0xe7, 0x30, 0x78, + 0x20, 0x38, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x00, 0xe0, 0x00, 0x20, + 0x07, 0xb0, 0xf0, 0xbd, 0xb2, 0x4f, 0x00, 0x00, 0x38, 0xb5, 0x42, 0x7a, + 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x2a, 0x01, 0xd0, 0x00, 0x20, 0x1f, 0xe0, + 0x4b, 0x1c, 0xdb, 0x7f, 0x10, 0x2b, 0x06, 0xd1, 0x02, 0x23, 0x43, 0x72, + 0x02, 0x62, 0x4b, 0x8c, 0x5b, 0x01, 0xc3, 0x61, 0x0c, 0xe0, 0x20, 0x2b, + 0xf0, 0xd1, 0x03, 0x23, 0x43, 0x72, 0x49, 0x6a, 0x22, 0x1c, 0x01, 0x62, + 0x1c, 0x32, 0x28, 0x1c, 0x00, 0xf0, 0x18, 0xfc, 0x00, 0x28, 0xe5, 0xd0, + 0x00, 0x23, 0x01, 0x20, 0x65, 0x62, 0x20, 0x72, 0xe3, 0x60, 0x23, 0x61, + 0x63, 0x61, 0x23, 0x76, 0x38, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x43, 0x7a, + 0x85, 0xb0, 0x04, 0x1c, 0x0e, 0x1c, 0x03, 0x92, 0x00, 0x2b, 0x01, 0xd1, + 0x3a, 0x48, 0x11, 0xe0, 0x03, 0x7a, 0xd8, 0x07, 0xfa, 0xd5, 0xe2, 0x69, + 0x20, 0x69, 0x03, 0x99, 0x13, 0x1a, 0x99, 0x42, 0x01, 0xd9, 0x9b, 0xb2, + 0x03, 0x93, 0x03, 0x99, 0x02, 0x91, 0x02, 0x9b, 0x00, 0x2b, 0x04, 0xd1, + 0x03, 0x99, 0x88, 0xb2, 0x00, 0xb2, 0x05, 0xb0, 0xf0, 0xbd, 0x23, 0x69, + 0x61, 0x7a, 0xdf, 0x05, 0xff, 0x0d, 0x5a, 0x0a, 0x60, 0x6a, 0x02, 0x29, + 0x02, 0xd1, 0x41, 0x6a, 0x51, 0x18, 0x1b, 0xe0, 0x05, 0x79, 0x01, 0x3d, + 0x2a, 0x40, 0xd5, 0xb2, 0x00, 0x2f, 0x0d, 0xd1, 0x00, 0x2d, 0x0b, 0xd1, + 0x00, 0x2b, 0x02, 0xd1, 0x22, 0x6a, 0xe2, 0x60, 0x06, 0xe0, 0x22, 0x1c, + 0xe1, 0x68, 0x0c, 0x32, 0x00, 0xf0, 0xa0, 0xfb, 0x00, 0x28, 0xc9, 0xd0, + 0x63, 0x6a, 0xe1, 0x68, 0x1a, 0x7c, 0x02, 0x39, 0x5b, 0x69, 0x91, 0x40, + 0xc9, 0x18, 0x49, 0x19, 0x80, 0x22, 0x02, 0x9d, 0x92, 0x00, 0xd3, 0x1b, + 0x9d, 0x42, 0x00, 0xdd, 0x9d, 0xb2, 0x23, 0x7a, 0x58, 0x06, 0x01, 0xd4, + 0x95, 0x42, 0x18, 0xd1, 0x16, 0x4b, 0x1b, 0x68, 0x99, 0x42, 0x14, 0xd0, + 0x15, 0x4b, 0x3a, 0x1c, 0x18, 0x68, 0x00, 0x96, 0x2b, 0x1c, 0xff, 0xf7, + 0x1f, 0xfe, 0x00, 0x28, 0xa8, 0xd0, 0x76, 0x19, 0x01, 0xe0, 0xdf, 0x1b, + 0xf6, 0x19, 0x21, 0x69, 0x02, 0x9a, 0x4b, 0x19, 0x55, 0x1b, 0xad, 0xb2, + 0x23, 0x61, 0x02, 0x95, 0xab, 0xe7, 0x08, 0x1c, 0x00, 0x21, 0x00, 0xf0, + 0x2b, 0xfb, 0x00, 0x28, 0x96, 0xd0, 0x09, 0x4b, 0x32, 0x1c, 0xff, 0x18, + 0x79, 0x19, 0x3b, 0x1c, 0x8b, 0x42, 0xe8, 0xd0, 0x18, 0x78, 0x01, 0x33, + 0x10, 0x70, 0x01, 0x32, 0xf8, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x73, 0xb5, 0x43, 0x7a, 0x04, 0x1c, 0x01, 0x2b, 0x01, 0xd8, 0x00, 0x20, + 0x16, 0xe0, 0x03, 0x69, 0x6d, 0x46, 0x07, 0x35, 0xde, 0x05, 0x29, 0x1c, + 0x01, 0x22, 0x36, 0x0f, 0xff, 0xf7, 0x6a, 0xff, 0x01, 0x28, 0x01, 0xd1, + 0x2b, 0x78, 0x00, 0xe0, 0x05, 0x4b, 0x1b, 0xb2, 0x01, 0x33, 0xec, 0xd0, + 0x23, 0x69, 0x70, 0x01, 0x1f, 0x33, 0x23, 0x61, 0x02, 0x4b, 0xc0, 0x18, + 0x76, 0xbd, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0x50, 0x01, 0x00, 0x20, + 0x70, 0xb5, 0x04, 0x1c, 0x40, 0x7a, 0x0d, 0x1c, 0x00, 0x28, 0x2a, 0xd0, + 0xe2, 0x69, 0x91, 0x42, 0x01, 0xd9, 0x00, 0x20, 0x25, 0xe0, 0x02, 0x28, + 0x21, 0xd0, 0x00, 0x2d, 0x01, 0xd1, 0xe5, 0x60, 0x1d, 0xe0, 0x62, 0x6a, + 0x21, 0x69, 0x13, 0x7c, 0x68, 0x1e, 0x09, 0x33, 0x4a, 0x1e, 0xd8, 0x40, + 0xda, 0x40, 0x03, 0x1e, 0x93, 0x42, 0x01, 0xd3, 0x00, 0x29, 0x02, 0xd1, + 0x22, 0x6a, 0xe2, 0x60, 0x00, 0xe0, 0x83, 0x1a, 0x1e, 0x1c, 0x00, 0x2e, + 0x09, 0xd0, 0x22, 0x1c, 0x60, 0x6a, 0xe1, 0x68, 0x0c, 0x32, 0x00, 0xf0, + 0x07, 0xfb, 0x01, 0x3e, 0x00, 0x28, 0xf4, 0xd1, 0x01, 0xe0, 0x25, 0x61, + 0x01, 0x20, 0x70, 0xbd, 0x38, 0xb5, 0x05, 0x1c, 0x40, 0x7a, 0x00, 0x28, + 0x33, 0xd0, 0x2b, 0x7a, 0x7f, 0x2b, 0x2d, 0xd9, 0x28, 0x1c, 0x01, 0x21, + 0xff, 0xf7, 0x9a, 0xfe, 0x04, 0x1e, 0x2a, 0xd0, 0x6b, 0x7a, 0x01, 0x2b, + 0x07, 0xd8, 0x2b, 0x7f, 0x03, 0x77, 0x6b, 0x7f, 0x43, 0x77, 0xab, 0x7f, + 0x83, 0x77, 0xeb, 0x7f, 0xc3, 0x77, 0x2b, 0x6a, 0x9a, 0xb2, 0x1b, 0x0c, + 0x23, 0x75, 0x1b, 0x0a, 0x63, 0x75, 0x0d, 0x4b, 0xa2, 0x76, 0x1b, 0x68, + 0x12, 0x0a, 0xe2, 0x76, 0x00, 0x2b, 0x0b, 0xd0, 0x20, 0x1c, 0x21, 0x1c, + 0x18, 0x30, 0x16, 0x31, 0x98, 0x47, 0x63, 0x7e, 0x22, 0x7e, 0x1b, 0x02, + 0x13, 0x43, 0xa3, 0x74, 0x1b, 0x0a, 0xe3, 0x74, 0x2a, 0x7a, 0x7f, 0x23, + 0x13, 0x40, 0x2b, 0x72, 0x00, 0xf0, 0x5c, 0xfa, 0xff, 0xe7, 0x38, 0xbd, + 0x44, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xc0, 0xff, + 0x00, 0x28, 0x02, 0xd0, 0x00, 0x23, 0x63, 0x72, 0x01, 0x20, 0x10, 0xbd, + 0x73, 0xb5, 0x42, 0x7a, 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x20, 0x01, 0x2a, + 0x4b, 0xd1, 0x20, 0x7a, 0x02, 0x23, 0x18, 0x40, 0x47, 0xd0, 0xe3, 0x69, + 0x00, 0x20, 0x99, 0x42, 0x43, 0xd8, 0x10, 0x1c, 0x00, 0x2b, 0x40, 0xd0, + 0x20, 0x1c, 0x29, 0x1c, 0x26, 0x69, 0xff, 0xf7, 0x71, 0xff, 0x00, 0x28, + 0x25, 0xd0, 0x60, 0x6a, 0x00, 0x2d, 0x06, 0xd1, 0x21, 0x6a, 0x00, 0xf0, + 0x95, 0xfb, 0x00, 0x28, 0x1d, 0xd0, 0x25, 0x62, 0x1d, 0xe0, 0xe1, 0x68, + 0x01, 0xaa, 0x00, 0xf0, 0x93, 0xfa, 0x00, 0x28, 0x15, 0xd0, 0x60, 0x6a, + 0x01, 0x99, 0x43, 0x1c, 0xdb, 0x7f, 0x10, 0x2b, 0x01, 0xd1, 0x12, 0x4b, + 0x00, 0xe0, 0x12, 0x4b, 0x99, 0x42, 0x0c, 0xd2, 0x00, 0xf0, 0x7e, 0xfb, + 0x00, 0x28, 0x06, 0xd0, 0x60, 0x6a, 0xe1, 0x68, 0x0e, 0x4a, 0x00, 0xf0, + 0xcf, 0xfa, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x11, 0xe0, 0x22, 0x7a, + 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, 0xe5, 0x61, 0x23, 0x72, 0x20, 0x1c, + 0xff, 0xf7, 0x70, 0xff, 0x00, 0x28, 0xf2, 0xd0, 0x29, 0x1e, 0xb1, 0x42, + 0x00, 0xd9, 0x31, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x35, 0xff, 0x76, 0xbd, + 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, 0xff, 0xff, 0xff, 0x0f, + 0x38, 0xb5, 0x23, 0x4b, 0x15, 0x1c, 0x4a, 0x01, 0xd3, 0x18, 0x04, 0x1c, + 0xd8, 0x7a, 0x11, 0x22, 0x10, 0x42, 0x04, 0xd0, 0x42, 0x22, 0x15, 0x42, + 0x01, 0xd0, 0x00, 0x20, 0x36, 0xe0, 0x1d, 0x4a, 0x21, 0x76, 0x12, 0x68, + 0x62, 0x61, 0x5a, 0x7d, 0x18, 0x7d, 0xd9, 0x7e, 0x12, 0x02, 0x02, 0x43, + 0x98, 0x7e, 0x09, 0x02, 0x12, 0x04, 0x01, 0x43, 0x11, 0x43, 0x21, 0x62, + 0xd8, 0x7a, 0x18, 0x22, 0x02, 0x40, 0x0c, 0xd1, 0x5a, 0x7f, 0x19, 0x7f, + 0x12, 0x02, 0x0a, 0x43, 0x99, 0x7f, 0xdb, 0x7f, 0x09, 0x04, 0x0a, 0x43, + 0x1b, 0x06, 0x13, 0x43, 0xe3, 0x61, 0x01, 0x23, 0x09, 0xe0, 0x10, 0x2a, + 0xdb, 0xd1, 0x22, 0x1c, 0x60, 0x6a, 0x1c, 0x32, 0x00, 0xf0, 0x5a, 0xfa, + 0x00, 0x28, 0xd4, 0xd0, 0x04, 0x23, 0x63, 0x72, 0x0f, 0x23, 0x00, 0x21, + 0x2b, 0x40, 0x23, 0x72, 0xe1, 0x60, 0x21, 0x61, 0x01, 0x20, 0x6a, 0x06, + 0x02, 0xd5, 0x20, 0x1c, 0xff, 0xf7, 0x60, 0xff, 0x38, 0xbd, 0xc0, 0x46, + 0x50, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0xf0, 0xb5, 0x45, 0x7a, + 0x87, 0xb0, 0x04, 0x1c, 0x0e, 0x1c, 0x01, 0x93, 0x00, 0x2d, 0x00, 0xd0, + 0x86, 0xe0, 0x10, 0x1c, 0x03, 0xa9, 0xff, 0xf7, 0xbb, 0xfd, 0x00, 0x28, + 0x00, 0xd1, 0x80, 0xe0, 0x72, 0x6a, 0x2f, 0x1c, 0x62, 0x62, 0xf5, 0x60, + 0x35, 0x61, 0x33, 0x69, 0xf2, 0x69, 0x93, 0x42, 0x26, 0xd2, 0xdb, 0x05, + 0x1b, 0x0f, 0x30, 0x1c, 0x00, 0x93, 0xff, 0xf7, 0x9f, 0xfe, 0x01, 0x1e, + 0x6f, 0xd0, 0x03, 0x78, 0x00, 0x2b, 0x01, 0xd0, 0xe5, 0x2b, 0x0b, 0xd1, + 0x00, 0x2f, 0x04, 0xd1, 0x00, 0x9b, 0x23, 0x76, 0x34, 0x4b, 0x1b, 0x68, + 0x63, 0x61, 0x0b, 0x78, 0x01, 0x27, 0x00, 0x2b, 0xe3, 0xd1, 0x0d, 0xe0, + 0x03, 0xa8, 0x0b, 0x22, 0x01, 0xf0, 0x10, 0xfe, 0x00, 0x28, 0xdc, 0xd1, + 0x01, 0x9a, 0x30, 0x23, 0x13, 0x40, 0x30, 0x2b, 0x53, 0xd0, 0x20, 0x1c, + 0x00, 0x99, 0x4b, 0xe0, 0x01, 0x9a, 0x12, 0x23, 0x13, 0x40, 0x12, 0x2b, + 0x4b, 0xd1, 0x00, 0x2f, 0x06, 0xd0, 0x20, 0x1c, 0x01, 0x21, 0xff, 0xf7, + 0x6f, 0xfd, 0x06, 0x1e, 0x0a, 0xd1, 0x42, 0xe0, 0x73, 0x7a, 0x02, 0x2b, + 0x3f, 0xd0, 0x30, 0x1c, 0xff, 0xf7, 0x40, 0xfd, 0x00, 0x28, 0x3a, 0xd0, + 0x1f, 0x4e, 0x27, 0x76, 0x00, 0x21, 0x20, 0x22, 0x30, 0x1c, 0x01, 0xf0, + 0x01, 0xfe, 0x30, 0x1c, 0x03, 0xa9, 0x0b, 0x22, 0x01, 0xf0, 0xf3, 0xfd, + 0x1a, 0x4b, 0x1b, 0x68, 0x00, 0x2b, 0x05, 0xd0, 0x30, 0x1c, 0x31, 0x1c, + 0x10, 0x30, 0x0e, 0x31, 0x98, 0x47, 0x06, 0xe0, 0x21, 0x22, 0x32, 0x74, + 0xb3, 0x73, 0x28, 0x22, 0x08, 0x23, 0x72, 0x74, 0xf3, 0x73, 0x73, 0x7c, + 0x32, 0x7c, 0x1b, 0x02, 0x13, 0x43, 0xff, 0x22, 0x1a, 0x40, 0x1b, 0x0a, + 0xf3, 0x74, 0x73, 0x76, 0xf3, 0x7b, 0xb2, 0x74, 0x32, 0x76, 0xb2, 0x7b, + 0x1b, 0x02, 0x13, 0x43, 0xb3, 0x75, 0x1b, 0x0a, 0xf3, 0x75, 0x00, 0xf0, + 0x21, 0xf9, 0x00, 0x28, 0x07, 0xd0, 0x21, 0x7e, 0x01, 0x9a, 0x20, 0x1c, + 0xff, 0xf7, 0x26, 0xff, 0x05, 0x1c, 0x00, 0xe0, 0x00, 0x25, 0x28, 0x1c, + 0x07, 0xb0, 0xf0, 0xbd, 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x44, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x00, 0x21, 0x04, 0x1c, 0xff, 0xf7, + 0xbb, 0xfe, 0x00, 0x28, 0x0b, 0xd0, 0x20, 0x1c, 0x01, 0x21, 0xff, 0xf7, + 0x15, 0xfd, 0x00, 0x28, 0x05, 0xd0, 0xe5, 0x23, 0x03, 0x70, 0x00, 0x23, + 0x63, 0x72, 0x00, 0xf0, 0xfb, 0xf8, 0x10, 0xbd, 0x10, 0xb5, 0x0a, 0x1c, + 0x0a, 0x49, 0x8a, 0xb0, 0x08, 0x31, 0x00, 0x23, 0x04, 0x1c, 0x00, 0x91, + 0x69, 0x46, 0x4b, 0x72, 0x01, 0x93, 0x68, 0x46, 0x21, 0x1c, 0x02, 0x23, + 0xff, 0xf7, 0x42, 0xff, 0x00, 0x28, 0x02, 0xd0, 0x68, 0x46, 0xff, 0xf7, + 0xd7, 0xff, 0x0a, 0xb0, 0x10, 0xbd, 0xc0, 0x46, 0xc8, 0x4f, 0x00, 0x00, + 0xf0, 0xb5, 0x43, 0x7a, 0x87, 0xb0, 0x04, 0x1c, 0x0d, 0x1c, 0x03, 0x92, + 0x01, 0x2b, 0x0d, 0xd1, 0x03, 0x7a, 0x99, 0x07, 0x0a, 0xd5, 0x5a, 0x07, + 0x0c, 0xd5, 0xe1, 0x69, 0x22, 0x69, 0x8a, 0x42, 0x08, 0xd0, 0x20, 0x1c, + 0xff, 0xf7, 0x06, 0xfe, 0x00, 0x28, 0x03, 0xd1, 0x01, 0x23, 0x63, 0x60, + 0x00, 0x20, 0xaa, 0xe0, 0x03, 0x9b, 0x01, 0x93, 0x3b, 0xe0, 0x60, 0x6a, + 0x73, 0x0a, 0x07, 0x79, 0xf6, 0x05, 0x01, 0x3f, 0x1f, 0x40, 0xff, 0xb2, + 0xf6, 0x0d, 0x00, 0x2f, 0x36, 0xd0, 0x80, 0x22, 0x92, 0x00, 0x92, 0x1b, + 0x01, 0x99, 0x92, 0xb2, 0x0b, 0x1c, 0x91, 0x42, 0x00, 0xd9, 0x13, 0x1c, + 0x9b, 0xb2, 0x02, 0x93, 0x63, 0x6a, 0xe1, 0x68, 0x1a, 0x7c, 0x02, 0x39, + 0x91, 0x40, 0x5a, 0x69, 0x8b, 0x18, 0x02, 0x9a, 0xdf, 0x19, 0x80, 0x23, + 0x9b, 0x00, 0x9a, 0x42, 0x3f, 0xd1, 0x44, 0x4b, 0x19, 0x68, 0xb9, 0x42, + 0x02, 0xd1, 0x01, 0x22, 0x52, 0x42, 0x1a, 0x60, 0x41, 0x4b, 0x39, 0x1c, + 0x18, 0x68, 0x2a, 0x1c, 0xff, 0xf7, 0x22, 0xfc, 0x00, 0x28, 0xc7, 0xd0, + 0x80, 0x22, 0x92, 0x00, 0xad, 0x18, 0x01, 0x99, 0x02, 0x9a, 0x8b, 0x1a, + 0x21, 0x69, 0x9b, 0xb2, 0x01, 0x93, 0x8b, 0x18, 0x23, 0x61, 0x01, 0x9a, + 0x26, 0x69, 0x00, 0x2a, 0xbf, 0xd1, 0x49, 0xe0, 0x00, 0x2e, 0xc6, 0xd1, + 0xe1, 0x68, 0x00, 0x29, 0x03, 0xd1, 0x23, 0x6a, 0x00, 0x2b, 0x16, 0xd1, + 0x0f, 0xe0, 0x05, 0xaa, 0x00, 0xf0, 0xe2, 0xf8, 0x00, 0x28, 0x58, 0xd0, + 0x62, 0x6a, 0x05, 0x9b, 0x01, 0x32, 0xd2, 0x7f, 0x10, 0x2a, 0x01, 0xd1, + 0x2c, 0x4a, 0x00, 0xe0, 0x2c, 0x4a, 0x93, 0x42, 0x05, 0xd3, 0x20, 0x1c, + 0xff, 0xf7, 0x3c, 0xfc, 0x00, 0x28, 0xaa, 0xd1, 0x98, 0xe7, 0xe3, 0x60, + 0xa7, 0xe7, 0x00, 0x2e, 0x0f, 0xd1, 0x23, 0x69, 0xe1, 0x69, 0x8b, 0x42, + 0x0b, 0xd3, 0x00, 0xf0, 0x59, 0xf8, 0x00, 0x28, 0x8c, 0xd0, 0x1f, 0x4b, + 0x01, 0x21, 0x1f, 0x60, 0x21, 0x4b, 0x1a, 0x78, 0x0a, 0x43, 0x1a, 0x70, + 0x06, 0xe0, 0x38, 0x1c, 0x01, 0x21, 0x00, 0xf0, 0x75, 0xf8, 0x00, 0x28, + 0x00, 0xd1, 0x7d, 0xe7, 0x1c, 0x4b, 0x2a, 0x1c, 0xf6, 0x18, 0x02, 0x9b, + 0xf1, 0x18, 0x33, 0x1c, 0x8b, 0x42, 0x04, 0xd0, 0x10, 0x78, 0x01, 0x32, + 0x18, 0x70, 0x01, 0x33, 0xf8, 0xe7, 0x9e, 0x1b, 0xad, 0x19, 0xa8, 0xe7, + 0xe1, 0x69, 0x23, 0x7a, 0x8e, 0x42, 0x01, 0xd9, 0xe6, 0x61, 0x06, 0xe0, + 0x12, 0x4a, 0x12, 0x68, 0x00, 0x2a, 0x06, 0xd0, 0x03, 0x9a, 0x00, 0x2a, + 0x03, 0xd0, 0x80, 0x22, 0x52, 0x42, 0x13, 0x43, 0x23, 0x72, 0x23, 0x7a, + 0x19, 0x07, 0x01, 0xd4, 0x03, 0x98, 0x06, 0xe0, 0x20, 0x1c, 0xff, 0xf7, + 0x8b, 0xfd, 0x00, 0x28, 0x00, 0xd1, 0x51, 0xe7, 0xf6, 0xe7, 0x07, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, + 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, 0x50, 0x03, 0x00, 0x20, + 0x50, 0x01, 0x00, 0x20, 0x44, 0x01, 0x00, 0x20, 0x07, 0xb5, 0x6b, 0x46, + 0xd9, 0x71, 0x07, 0x33, 0x19, 0x1c, 0x01, 0x22, 0xff, 0xf7, 0x22, 0xff, + 0x0e, 0xbd, 0x00, 0x00, 0xf8, 0xb5, 0x0f, 0x4f, 0x01, 0x20, 0x3b, 0x78, + 0x00, 0x2b, 0x18, 0xd0, 0x0d, 0x4e, 0x0e, 0x4b, 0x0e, 0x4d, 0x19, 0x68, + 0x30, 0x68, 0x2a, 0x1c, 0xff, 0xf7, 0x80, 0xfb, 0x00, 0x28, 0x0e, 0xd0, + 0x0b, 0x4c, 0x21, 0x68, 0x00, 0x29, 0x07, 0xd0, 0x30, 0x68, 0x2a, 0x1c, + 0xff, 0xf7, 0x76, 0xfb, 0x00, 0x28, 0x04, 0xd0, 0x00, 0x23, 0x23, 0x60, + 0x00, 0x23, 0x3b, 0x70, 0x01, 0x20, 0xf8, 0xbd, 0x50, 0x03, 0x00, 0x20, + 0x4c, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x48, 0x01, 0x00, 0x20, 0x70, 0xb5, 0x0d, 0x4d, 0x04, 0x1c, 0x2b, 0x68, + 0x0e, 0x1c, 0x83, 0x42, 0x0e, 0xd0, 0xff, 0xf7, 0xcd, 0xff, 0x00, 0x28, + 0x01, 0xd1, 0x00, 0x20, 0x0d, 0xe0, 0x08, 0x4b, 0x21, 0x1c, 0x18, 0x68, + 0x07, 0x4a, 0xff, 0xf7, 0x25, 0xfb, 0x00, 0x28, 0xf5, 0xd0, 0x2c, 0x60, + 0x05, 0x4b, 0x01, 0x20, 0x1a, 0x78, 0x16, 0x43, 0x1e, 0x70, 0x70, 0xbd, + 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x50, 0x03, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xae, 0xff, + 0x00, 0x28, 0x0f, 0xd0, 0x00, 0x23, 0x08, 0x4a, 0x00, 0x21, 0x99, 0x54, + 0x80, 0x22, 0x01, 0x33, 0x92, 0x00, 0x93, 0x42, 0xf7, 0xd1, 0x05, 0x4b, + 0x01, 0x20, 0x1c, 0x60, 0x04, 0x4b, 0x1a, 0x78, 0x02, 0x43, 0x1a, 0x70, + 0x10, 0xbd, 0xc0, 0x46, 0x50, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, + 0x50, 0x03, 0x00, 0x20, 0xc3, 0x68, 0x70, 0xb5, 0x01, 0x33, 0x0c, 0x1c, + 0x15, 0x1c, 0x99, 0x42, 0x01, 0xd9, 0x00, 0x20, 0x21, 0xe0, 0x46, 0x1c, + 0xf1, 0x7f, 0xc2, 0x69, 0xe3, 0x09, 0x10, 0x29, 0x00, 0xd1, 0x23, 0x0a, + 0x98, 0x18, 0x0d, 0x4b, 0x1b, 0x68, 0x98, 0x42, 0x07, 0xd1, 0xf2, 0x7f, + 0x0b, 0x4b, 0x10, 0x2a, 0x09, 0xd1, 0xe4, 0xb2, 0x64, 0x00, 0x1b, 0x5b, + 0x0b, 0xe0, 0x00, 0x21, 0xff, 0xf7, 0x9e, 0xff, 0x00, 0x28, 0xf2, 0xd1, + 0xe3, 0xe7, 0x7f, 0x22, 0x14, 0x40, 0xa4, 0x00, 0x1b, 0x59, 0x1b, 0x01, + 0x1b, 0x09, 0x2b, 0x60, 0x01, 0x20, 0x70, 0xbd, 0x00, 0x00, 0x00, 0x20, + 0x50, 0x01, 0x00, 0x20, 0x73, 0xb5, 0x05, 0x1c, 0x01, 0x91, 0x16, 0x1c, + 0x00, 0x24, 0x28, 0x1c, 0x01, 0x99, 0x01, 0xaa, 0xff, 0xf7, 0xc6, 0xff, + 0x00, 0x28, 0x10, 0xd0, 0x2a, 0x7c, 0x80, 0x23, 0x9b, 0x00, 0x93, 0x40, + 0xe4, 0x18, 0x6b, 0x1c, 0xdb, 0x7f, 0x01, 0x9a, 0x10, 0x2b, 0x01, 0xd1, + 0x03, 0x4b, 0x00, 0xe0, 0x03, 0x4b, 0x9a, 0x42, 0xe9, 0xd3, 0x34, 0x60, + 0x01, 0x20, 0x76, 0xbd, 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, + 0xf7, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x01, 0x92, 0x01, 0x29, 0x32, 0xd9, + 0xc3, 0x68, 0x00, 0x20, 0x01, 0x33, 0x99, 0x42, 0x2e, 0xd8, 0x6f, 0x1c, + 0xfa, 0x7f, 0xee, 0x69, 0xcb, 0x09, 0x10, 0x2a, 0x00, 0xd1, 0x0b, 0x0a, + 0x9e, 0x19, 0x14, 0x4b, 0x1b, 0x68, 0x9e, 0x42, 0x08, 0xd1, 0xfa, 0x7f, + 0x12, 0x4b, 0x10, 0x2a, 0x0b, 0xd1, 0xe4, 0xb2, 0x01, 0x9a, 0x64, 0x00, + 0x1a, 0x53, 0x0b, 0xe0, 0x30, 0x1c, 0x00, 0x21, 0xff, 0xf7, 0x48, 0xff, + 0x00, 0x28, 0xf0, 0xd1, 0x12, 0xe0, 0x7f, 0x22, 0x14, 0x40, 0x01, 0x9a, + 0xa4, 0x00, 0x1a, 0x51, 0x09, 0x4b, 0x01, 0x20, 0x1a, 0x78, 0x02, 0x43, + 0x1a, 0x70, 0x2b, 0x7e, 0x83, 0x42, 0x05, 0xd9, 0xab, 0x68, 0xf6, 0x18, + 0x05, 0x4b, 0x1e, 0x60, 0x00, 0xe0, 0x00, 0x20, 0xfe, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, 0x50, 0x03, 0x00, 0x20, + 0x48, 0x01, 0x00, 0x20, 0xf0, 0xb5, 0x15, 0x68, 0x87, 0xb0, 0x06, 0x1c, + 0x02, 0x91, 0x17, 0x1c, 0x00, 0x2d, 0x03, 0xd0, 0x00, 0x21, 0x01, 0x35, + 0x01, 0x91, 0x06, 0xe0, 0x02, 0x9b, 0x05, 0x68, 0x01, 0x3b, 0x5a, 0x42, + 0x53, 0x41, 0xdb, 0xb2, 0x01, 0x93, 0xf2, 0x68, 0x00, 0x23, 0x01, 0x32, + 0x03, 0x92, 0x2c, 0x1c, 0x00, 0x93, 0x00, 0x99, 0xf2, 0x68, 0x91, 0x42, + 0x21, 0xd2, 0x03, 0x9b, 0x9c, 0x42, 0x01, 0xd9, 0x02, 0x24, 0x25, 0x1c, + 0x30, 0x1c, 0x21, 0x1c, 0x05, 0xaa, 0xff, 0xf7, 0x43, 0xff, 0x00, 0x28, + 0x15, 0xd0, 0x05, 0x99, 0x63, 0x1c, 0x00, 0x29, 0x01, 0xd0, 0x1d, 0x1c, + 0x03, 0xe0, 0x02, 0x99, 0x5a, 0x1b, 0x8a, 0x42, 0x04, 0xd0, 0x00, 0x9a, + 0x1c, 0x1c, 0x01, 0x32, 0x00, 0x92, 0xe0, 0xe7, 0x30, 0x1c, 0x21, 0x1c, + 0x13, 0x4a, 0xff, 0xf7, 0x7f, 0xff, 0x00, 0x28, 0x0b, 0xd1, 0x00, 0x20, + 0x1d, 0xe0, 0x63, 0x1e, 0x30, 0x1c, 0x19, 0x1c, 0x22, 0x1c, 0x00, 0x93, + 0xff, 0xf7, 0x74, 0xff, 0x00, 0x28, 0xf4, 0xd0, 0x00, 0x9c, 0xac, 0x42, + 0xf3, 0xd8, 0x39, 0x68, 0x00, 0x29, 0x06, 0xd1, 0x01, 0x99, 0x3d, 0x60, + 0x00, 0x29, 0x09, 0xd0, 0x01, 0x35, 0x35, 0x60, 0x06, 0xe0, 0x30, 0x1c, + 0x2a, 0x1c, 0xff, 0xf7, 0x61, 0xff, 0x00, 0x28, 0xf2, 0xd1, 0xe0, 0xe7, + 0x01, 0x20, 0x07, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0xff, 0xff, 0xff, 0x0f, + 0x02, 0x23, 0x37, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x03, 0x60, 0x28, 0x1c, + 0x21, 0x1c, 0x01, 0xaa, 0xff, 0xf7, 0xfc, 0xfe, 0x00, 0x28, 0x12, 0xd0, + 0x28, 0x1c, 0x21, 0x1c, 0x00, 0x22, 0xff, 0xf7, 0x47, 0xff, 0x00, 0x28, + 0x0b, 0xd0, 0x6b, 0x1c, 0xdb, 0x7f, 0x01, 0x9c, 0x10, 0x2b, 0x01, 0xd1, + 0x04, 0x4b, 0x00, 0xe0, 0x04, 0x4b, 0x9c, 0x42, 0xe7, 0xd3, 0x01, 0x20, + 0x00, 0xe0, 0x00, 0x20, 0x3e, 0xbd, 0xc0, 0x46, 0xf8, 0xff, 0x00, 0x00, + 0xf8, 0xff, 0xff, 0x0f, 0xf8, 0xb5, 0x44, 0x4b, 0x04, 0x1c, 0x15, 0x1c, + 0x19, 0x60, 0x29, 0xd0, 0x04, 0x2a, 0x01, 0xd9, 0x00, 0x20, 0x7d, 0xe0, + 0x00, 0x20, 0x01, 0x1c, 0xff, 0xf7, 0x90, 0xfe, 0x00, 0x28, 0xf7, 0xd0, + 0x2d, 0x01, 0x3d, 0x4b, 0xa9, 0x35, 0xff, 0x35, 0x5d, 0x19, 0xaa, 0x79, + 0xab, 0x1d, 0x50, 0x06, 0xee, 0xd1, 0xea, 0x7c, 0xa9, 0x7c, 0x12, 0x02, + 0x0a, 0x43, 0x29, 0x7d, 0x09, 0x04, 0x0a, 0x43, 0x69, 0x7d, 0x09, 0x06, + 0x0a, 0x43, 0x63, 0x2a, 0xe2, 0xd9, 0xaa, 0x7b, 0xed, 0x7b, 0x2d, 0x02, + 0x15, 0x43, 0x9a, 0x7a, 0xdb, 0x7a, 0x12, 0x04, 0x15, 0x43, 0x1b, 0x06, + 0x1d, 0x43, 0xd7, 0xd0, 0x28, 0x1c, 0x00, 0x21, 0xff, 0xf7, 0x6a, 0xfe, + 0x00, 0x28, 0xd1, 0xd0, 0x2a, 0x4b, 0x19, 0x7b, 0xda, 0x7a, 0x09, 0x02, + 0x11, 0x43, 0x80, 0x22, 0x92, 0x00, 0x91, 0x42, 0xc8, 0xd1, 0x1a, 0x7c, + 0x00, 0x2a, 0xc5, 0xd0, 0xd9, 0x89, 0x00, 0x29, 0xc2, 0xd0, 0x59, 0x7b, + 0x00, 0x29, 0xbf, 0xd0, 0x22, 0x76, 0x00, 0x22, 0x21, 0x71, 0x22, 0x74, + 0x22, 0x7c, 0x01, 0x20, 0x90, 0x40, 0x81, 0x42, 0x04, 0xd0, 0x50, 0x1c, + 0x20, 0x74, 0x07, 0x2a, 0xf6, 0xd9, 0xb1, 0xe7, 0xd9, 0x8a, 0x00, 0x29, + 0x00, 0xd1, 0x59, 0x6a, 0xa1, 0x60, 0xd8, 0x89, 0x28, 0x18, 0xe0, 0x61, + 0x1f, 0x69, 0x3e, 0x02, 0x36, 0x0c, 0x66, 0x84, 0xb7, 0xb2, 0x1e, 0x7c, + 0x71, 0x43, 0x0e, 0x18, 0x13, 0x48, 0x79, 0x01, 0x09, 0x18, 0x49, 0x12, + 0x71, 0x18, 0x66, 0x62, 0x61, 0x61, 0x18, 0x7d, 0xde, 0x7c, 0x00, 0x02, + 0x30, 0x43, 0x00, 0xd1, 0x18, 0x6a, 0x6d, 0x1a, 0x28, 0x18, 0xd0, 0x40, + 0x02, 0x1c, 0xe0, 0x60, 0x0b, 0x48, 0x61, 0x1c, 0x82, 0x42, 0x01, 0xd8, + 0x0c, 0x23, 0x07, 0xe0, 0x09, 0x48, 0x82, 0x42, 0x01, 0xd8, 0x10, 0x23, + 0x02, 0xe0, 0xdb, 0x6a, 0x63, 0x62, 0x20, 0x23, 0xcb, 0x77, 0x01, 0x20, + 0xf8, 0xbd, 0xc0, 0x46, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0xff, 0x01, 0x00, 0x00, 0xf4, 0x0f, 0x00, 0x00, 0xf4, 0xff, 0x00, 0x00, + 0x08, 0xb5, 0x05, 0x49, 0x05, 0x4a, 0x06, 0x48, 0x00, 0xf0, 0x10, 0xf8, + 0x05, 0x4b, 0x06, 0x49, 0x00, 0x22, 0x1a, 0x70, 0x5a, 0x54, 0x08, 0xbd, + 0x00, 0x50, 0x00, 0x00, 0x01, 0x04, 0x00, 0x00, 0x54, 0x03, 0x00, 0x20, + 0x6c, 0x03, 0x00, 0x20, 0x02, 0x04, 0x00, 0x00, 0x30, 0xb5, 0x09, 0x4c, + 0x09, 0x4b, 0xa5, 0x68, 0x6d, 0x03, 0x6d, 0x0f, 0xad, 0x00, 0xeb, 0x58, + 0x03, 0x60, 0xa4, 0x68, 0x01, 0x61, 0xa4, 0xb2, 0x44, 0x60, 0x5c, 0x43, + 0x9b, 0x00, 0x84, 0x60, 0xc3, 0x60, 0x42, 0x61, 0x30, 0xbd, 0xc0, 0x46, + 0x00, 0x40, 0x00, 0x41, 0x00, 0x55, 0x00, 0x00, 0xf7, 0xb5, 0x1f, 0x4e, + 0x80, 0x27, 0x75, 0x68, 0x03, 0x33, 0x3d, 0x43, 0x9b, 0x08, 0x75, 0x60, + 0x00, 0x2b, 0x34, 0xd0, 0x1b, 0x4d, 0x35, 0x80, 0x35, 0x7d, 0xef, 0x07, + 0xfc, 0xd5, 0x1d, 0x1c, 0x5f, 0x1b, 0x01, 0x97, 0x07, 0x68, 0xbf, 0x08, + 0xbc, 0x46, 0x01, 0x9f, 0x67, 0x45, 0x1f, 0xd2, 0x00, 0x2d, 0x1d, 0xd0, + 0x17, 0x78, 0x01, 0x3d, 0x01, 0x97, 0xff, 0x27, 0xbc, 0x43, 0x01, 0x9f, + 0x3c, 0x43, 0x57, 0x78, 0x3f, 0x02, 0x01, 0x97, 0x0f, 0x4f, 0x3c, 0x40, + 0x01, 0x9f, 0x3c, 0x43, 0x97, 0x78, 0x3f, 0x04, 0xbc, 0x46, 0x0d, 0x4f, + 0x3c, 0x40, 0xd7, 0x78, 0xa4, 0xb2, 0x3f, 0x06, 0x00, 0x97, 0x67, 0x46, + 0x3c, 0x43, 0x00, 0x9f, 0x04, 0x32, 0x3c, 0x43, 0x10, 0xc1, 0xd7, 0xe7, + 0x07, 0x4b, 0x33, 0x80, 0x33, 0x7d, 0xdf, 0x07, 0xfc, 0xd5, 0x2b, 0x1c, + 0xc8, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x44, 0xa5, 0xff, 0xff, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, 0x04, 0xa5, 0xff, 0xff, + 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, 0x1a, 0x80, 0x1a, 0x7d, + 0xd1, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x16, 0x1c, + 0xeb, 0x68, 0x28, 0x1c, 0x21, 0x1c, 0x9e, 0x42, 0x05, 0xd9, 0xff, 0xf7, + 0xe7, 0xff, 0xeb, 0x68, 0xe4, 0x18, 0xf6, 0x1a, 0xf4, 0xe7, 0xff, 0xf7, + 0xe1, 0xff, 0x70, 0xbd, 0x43, 0x7a, 0x00, 0x2b, 0x04, 0xd1, 0x83, 0x72, + 0xc3, 0x72, 0xc3, 0x60, 0x01, 0x23, 0x43, 0x72, 0x70, 0x47, 0x30, 0xb5, + 0x85, 0xb0, 0x04, 0x1c, 0x02, 0xad, 0x00, 0x68, 0x02, 0x91, 0x03, 0x92, + 0x00, 0xf0, 0xb2, 0xf9, 0x6b, 0x79, 0xe1, 0x79, 0x22, 0x7a, 0x00, 0x93, + 0x20, 0x68, 0x00, 0x23, 0x00, 0xf0, 0x4c, 0xfa, 0x29, 0x79, 0x20, 0x68, + 0x02, 0x9a, 0x00, 0xf0, 0x75, 0xf9, 0x20, 0x68, 0x00, 0xf0, 0x98, 0xf9, + 0x05, 0xb0, 0x30, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0x18, 0x26, 0xff, 0xf7, + 0xd7, 0xff, 0x20, 0x79, 0x33, 0x1c, 0x43, 0x43, 0x0d, 0x4d, 0x08, 0x21, + 0xeb, 0x18, 0x59, 0x56, 0x01, 0xf0, 0x84, 0xf8, 0xa0, 0x79, 0x33, 0x1c, + 0x43, 0x43, 0x08, 0x21, 0xeb, 0x18, 0x59, 0x56, 0x01, 0xf0, 0x7c, 0xf8, + 0x60, 0x79, 0x08, 0x21, 0x46, 0x43, 0xad, 0x19, 0x69, 0x56, 0x01, 0xf0, + 0x75, 0xf8, 0x04, 0x4b, 0x20, 0x1c, 0x06, 0xcb, 0xff, 0xf7, 0xc3, 0xff, + 0x70, 0xbd, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, 0x70, 0x07, 0x00, 0x20, + 0x07, 0xb5, 0x83, 0x7a, 0x00, 0x91, 0x01, 0x92, 0x00, 0x2b, 0x0d, 0xd0, + 0x9a, 0x07, 0x06, 0xd5, 0xef, 0xf3, 0x10, 0x83, 0x5a, 0x42, 0x53, 0x41, + 0xc3, 0x72, 0x72, 0xb6, 0x04, 0xe0, 0xda, 0x07, 0x02, 0xd5, 0x82, 0x89, + 0x03, 0x4b, 0x9a, 0x60, 0x00, 0x99, 0x01, 0x9a, 0xff, 0xf7, 0xa5, 0xff, + 0x07, 0xbd, 0xc0, 0x46, 0x00, 0x18, 0x00, 0x40, 0x83, 0x7a, 0x00, 0x2b, + 0x0b, 0xd0, 0x9a, 0x07, 0x04, 0xd5, 0xc3, 0x7a, 0x00, 0x2b, 0x06, 0xd0, + 0x62, 0xb6, 0x04, 0xe0, 0xda, 0x07, 0x02, 0xd5, 0x82, 0x89, 0x01, 0x4b, + 0xda, 0x60, 0x70, 0x47, 0x00, 0x18, 0x00, 0x40, 0x08, 0xb5, 0x00, 0x68, + 0x00, 0xf0, 0x4f, 0xf9, 0x08, 0xbd, 0x00, 0x00, 0x09, 0x4b, 0x0a, 0x4a, + 0x0a, 0x49, 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x09, 0x4b, + 0x19, 0x60, 0x0a, 0x21, 0x19, 0x71, 0x09, 0x21, 0x5a, 0x72, 0x99, 0x71, + 0xda, 0x71, 0x08, 0x21, 0x03, 0x22, 0x59, 0x71, 0x1a, 0x72, 0x70, 0x47, + 0x70, 0x07, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, 0x08, 0x0c, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0xec, 0xfc, + 0x08, 0xbd, 0xc0, 0x46, 0x88, 0x07, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, + 0x00, 0xf0, 0xe4, 0xfc, 0x08, 0xbd, 0xc0, 0x46, 0xc4, 0x09, 0x00, 0x20, + 0x73, 0xb5, 0x17, 0x49, 0x17, 0x48, 0x00, 0xf0, 0x5b, 0xf8, 0x17, 0x49, + 0x17, 0x48, 0x00, 0xf0, 0x57, 0xf8, 0x17, 0x4c, 0x17, 0x49, 0x20, 0x1c, + 0x00, 0xf0, 0x52, 0xf8, 0x16, 0x49, 0x17, 0x48, 0x00, 0xf0, 0x4e, 0xf8, + 0x16, 0x49, 0x17, 0x48, 0x00, 0xf0, 0x4a, 0xf8, 0x16, 0x4e, 0x17, 0x49, + 0x30, 0x1c, 0x00, 0xf0, 0x45, 0xf8, 0x01, 0x25, 0x03, 0x23, 0x31, 0x1c, + 0x00, 0x93, 0x01, 0x95, 0x0d, 0x22, 0x0e, 0x23, 0x12, 0x48, 0x00, 0xf0, + 0xd3, 0xfb, 0x00, 0x23, 0x00, 0x95, 0x01, 0x93, 0x21, 0x1c, 0x1b, 0x22, + 0x1a, 0x23, 0x0f, 0x48, 0x00, 0xf0, 0xca, 0xfb, 0x73, 0xbd, 0xc0, 0x46, + 0x00, 0x08, 0x00, 0x42, 0x04, 0x0c, 0x00, 0x20, 0x00, 0x0c, 0x00, 0x42, + 0x08, 0x0c, 0x00, 0x20, 0x0c, 0x0c, 0x00, 0x20, 0x00, 0x10, 0x00, 0x42, + 0x00, 0x14, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x20, 0x00, 0x18, 0x00, 0x42, + 0x10, 0x0c, 0x00, 0x20, 0x14, 0x0c, 0x00, 0x20, 0x00, 0x1c, 0x00, 0x42, + 0x88, 0x07, 0x00, 0x20, 0xc4, 0x09, 0x00, 0x20, 0xf7, 0xb5, 0x8a, 0x18, + 0x06, 0x1c, 0x0d, 0x1c, 0x01, 0x92, 0x0c, 0x1c, 0x01, 0x9b, 0x67, 0x1b, + 0x9c, 0x42, 0x07, 0xd0, 0x33, 0x68, 0x21, 0x78, 0x1b, 0x68, 0x30, 0x1c, + 0x98, 0x47, 0x01, 0x34, 0x00, 0x28, 0xf3, 0xd1, 0x38, 0x1c, 0xfe, 0xbd, + 0x01, 0x60, 0x70, 0x47, 0xf7, 0xb5, 0x08, 0xac, 0x26, 0x78, 0x04, 0x68, + 0x9d, 0x1e, 0x27, 0x68, 0x6c, 0x1e, 0xa5, 0x41, 0xec, 0xb2, 0x92, 0x07, + 0x05, 0x68, 0x3a, 0x43, 0x27, 0x06, 0x3a, 0x43, 0x2a, 0x60, 0x02, 0x68, + 0x07, 0x25, 0x29, 0x40, 0x50, 0x68, 0xb5, 0x01, 0x00, 0x2c, 0x00, 0xd0, + 0x5c, 0x03, 0x29, 0x43, 0x01, 0x43, 0x0c, 0x43, 0x54, 0x60, 0xf7, 0xbd, + 0x30, 0xb5, 0x03, 0x68, 0xc0, 0x25, 0x1c, 0x68, 0xad, 0x03, 0x12, 0x05, + 0x2a, 0x40, 0x22, 0x43, 0xc0, 0x24, 0xa4, 0x02, 0x09, 0x04, 0x21, 0x40, + 0x11, 0x43, 0x19, 0x60, 0x03, 0x68, 0x5a, 0x68, 0x14, 0x43, 0x5c, 0x60, + 0x30, 0xbd, 0x03, 0x68, 0x01, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, + 0x02, 0x68, 0x11, 0x68, 0x01, 0x23, 0x19, 0x42, 0xfb, 0xd1, 0xd1, 0x69, + 0x19, 0x42, 0xf8, 0xd1, 0x70, 0x47, 0x03, 0x68, 0x02, 0x21, 0x1a, 0x68, + 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, 0xd3, 0x69, 0x99, 0x07, 0xfc, 0xd4, + 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd1, 0x07, 0x02, 0xd4, 0x1a, 0x7e, + 0x91, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0x03, 0x68, 0x00, 0x22, 0x5a, 0x83, + 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x40, 0x07, 0xc0, 0x0f, 0x70, 0x47, + 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x09, 0x70, 0x47, 0x03, 0x68, 0x80, 0x22, + 0x19, 0x7e, 0x52, 0x42, 0x0a, 0x43, 0x1a, 0x76, 0x70, 0x47, 0x03, 0x68, + 0x58, 0x8b, 0x80, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x02, 0x21, + 0x5a, 0x8b, 0x0a, 0x43, 0x5a, 0x83, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, + 0x01, 0x23, 0x18, 0x40, 0x70, 0x47, 0x03, 0x68, 0x18, 0x8d, 0xc0, 0xb2, + 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0x01, 0x20, 0x02, 0x42, 0xfb, 0xd0, + 0x19, 0x85, 0x70, 0x47, 0x03, 0x68, 0x01, 0x22, 0x9a, 0x75, 0x70, 0x47, + 0x03, 0x68, 0x01, 0x22, 0x1a, 0x75, 0x70, 0x47, 0x70, 0xb5, 0x03, 0x68, + 0x01, 0x26, 0x8d, 0x07, 0xed, 0x0f, 0x31, 0x40, 0x1c, 0x68, 0x6d, 0x07, + 0x09, 0x07, 0x29, 0x43, 0x21, 0x43, 0x19, 0x60, 0x04, 0x68, 0x51, 0x00, + 0x03, 0x48, 0x00, 0xf0, 0xb7, 0xff, 0x01, 0x38, 0xc0, 0xb2, 0x20, 0x73, + 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x6c, 0xdc, 0x02, 0x03, 0x68, 0x01, 0x21, + 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, 0x11, 0x68, 0x01, 0x23, + 0x19, 0x42, 0xfb, 0xd1, 0xd1, 0x69, 0x19, 0x42, 0xf8, 0xd1, 0x70, 0x47, + 0x03, 0x68, 0x02, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, + 0xd3, 0x69, 0x99, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, 0xda, 0x69, + 0x91, 0x07, 0xfc, 0xd4, 0x1a, 0x68, 0x02, 0x21, 0x8a, 0x43, 0x1a, 0x60, + 0x70, 0x47, 0x03, 0x68, 0x9a, 0x6a, 0x52, 0x0a, 0x52, 0x02, 0x11, 0x43, + 0x99, 0x62, 0x03, 0x68, 0x1a, 0x7e, 0x51, 0x07, 0xfc, 0xd5, 0x98, 0x6a, + 0xc0, 0xb2, 0x70, 0x47, 0x03, 0x68, 0x22, 0x4a, 0x30, 0xb5, 0x93, 0x42, + 0x11, 0xd0, 0x21, 0x4a, 0x93, 0x42, 0x11, 0xd0, 0x20, 0x4a, 0x93, 0x42, + 0x11, 0xd0, 0x20, 0x4a, 0x93, 0x42, 0x11, 0xd0, 0x1f, 0x4a, 0x93, 0x42, + 0x11, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x30, 0xd1, 0x0e, 0x23, 0x19, 0x22, + 0x0d, 0xe0, 0x09, 0x23, 0x14, 0x22, 0x0a, 0xe0, 0x0a, 0x23, 0x15, 0x22, + 0x07, 0xe0, 0x0b, 0x23, 0x16, 0x22, 0x04, 0xe0, 0x0c, 0x23, 0x17, 0x22, + 0x01, 0xe0, 0x0d, 0x23, 0x18, 0x22, 0xdc, 0xb2, 0x15, 0x49, 0x01, 0x20, + 0x9b, 0x08, 0xa0, 0x40, 0x9b, 0x00, 0x08, 0x60, 0x5b, 0x18, 0x03, 0x20, + 0xc0, 0x21, 0x89, 0x00, 0x04, 0x40, 0x5d, 0x58, 0xe0, 0x00, 0xff, 0x24, + 0x84, 0x40, 0xa5, 0x43, 0x2c, 0x1c, 0xc0, 0x25, 0x85, 0x40, 0x28, 0x1c, + 0x20, 0x43, 0x58, 0x50, 0x80, 0x23, 0xdb, 0x01, 0x1a, 0x43, 0x0a, 0x4b, + 0x5a, 0x80, 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, 0x30, 0xbd, + 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, 0x00, 0x10, 0x00, 0x42, + 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, 0x00, 0x1c, 0x00, 0x42, + 0x00, 0xe1, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x40, 0xf8, 0xb5, 0x04, 0x1c, + 0x15, 0x1c, 0x0e, 0x1c, 0x1f, 0x1c, 0xff, 0xf7, 0xa3, 0xff, 0x20, 0x1c, + 0xff, 0xf7, 0x03, 0xff, 0xb1, 0x00, 0x1c, 0x22, 0x0a, 0x40, 0x69, 0x07, + 0x23, 0x68, 0x09, 0x0c, 0x0a, 0x43, 0x1a, 0x60, 0x22, 0x68, 0x84, 0x23, + 0x93, 0x75, 0x01, 0x2e, 0x1a, 0xd1, 0x08, 0x21, 0x01, 0x2d, 0x00, 0xd1, + 0x10, 0x21, 0x0c, 0x4b, 0x79, 0x43, 0x18, 0x68, 0xc0, 0x00, 0x00, 0xf0, + 0x0b, 0xff, 0x23, 0x68, 0x07, 0x21, 0x9a, 0x89, 0x01, 0x40, 0xd2, 0x04, + 0x49, 0x03, 0xd2, 0x0c, 0x0a, 0x43, 0x9a, 0x81, 0x23, 0x68, 0x00, 0x04, + 0xc2, 0x0c, 0x98, 0x89, 0x40, 0x0b, 0x40, 0x03, 0x10, 0x43, 0x98, 0x81, + 0xf8, 0xbd, 0xc0, 0x46, 0x08, 0x00, 0x00, 0x20, 0xf7, 0xb5, 0x01, 0x93, + 0x08, 0xab, 0x04, 0x1c, 0x1f, 0x78, 0x0d, 0x1c, 0x16, 0x1c, 0xff, 0xf7, + 0x3d, 0xff, 0x20, 0x1c, 0xff, 0xf7, 0x68, 0xff, 0xbf, 0x07, 0x0c, 0x22, + 0x17, 0x43, 0xc0, 0x22, 0x92, 0x03, 0x36, 0x05, 0x16, 0x40, 0xc0, 0x22, + 0x92, 0x02, 0x2d, 0x04, 0x23, 0x68, 0x3e, 0x43, 0x01, 0x99, 0x15, 0x40, + 0x35, 0x43, 0x07, 0x22, 0x1d, 0x60, 0x0a, 0x40, 0x80, 0x21, 0x23, 0x68, + 0x89, 0x02, 0x0a, 0x43, 0x5a, 0x60, 0xf7, 0xbd, 0x3f, 0x20, 0x70, 0x47, + 0x13, 0xb5, 0x02, 0x68, 0x6b, 0x46, 0xd9, 0x71, 0x07, 0x33, 0x54, 0x68, + 0x19, 0x1c, 0x01, 0x22, 0xa0, 0x47, 0x16, 0xbd, 0x08, 0xb5, 0x00, 0x69, + 0x02, 0x21, 0x00, 0xf0, 0x49, 0xf8, 0x08, 0xbd, 0x08, 0xb5, 0x00, 0x69, + 0x03, 0x21, 0x00, 0xf0, 0x59, 0xf8, 0x08, 0xbd, 0x38, 0xb5, 0x0d, 0x1c, + 0x04, 0x1c, 0x13, 0x1c, 0x00, 0x69, 0x03, 0x21, 0x2a, 0x1c, 0x00, 0xf0, + 0xf1, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x01, 0x23, 0x63, 0x60, 0x38, 0xbd, + 0x10, 0xb5, 0x05, 0x4c, 0x23, 0x68, 0x5a, 0x1c, 0x04, 0xd1, 0x03, 0x68, + 0x5b, 0x69, 0x98, 0x47, 0x20, 0x60, 0x03, 0x1c, 0x18, 0x1c, 0x10, 0xbd, + 0x04, 0x00, 0x00, 0x20, 0x07, 0x4a, 0x08, 0xb5, 0x13, 0x68, 0x59, 0x1c, + 0x04, 0xd0, 0x01, 0x21, 0x49, 0x42, 0x11, 0x60, 0x18, 0x1c, 0x03, 0xe0, + 0x00, 0x69, 0x02, 0x21, 0x00, 0xf0, 0xc2, 0xf8, 0x08, 0xbd, 0xc0, 0x46, + 0x04, 0x00, 0x00, 0x20, 0x06, 0x4b, 0xfa, 0x21, 0x89, 0x00, 0x99, 0x60, + 0x05, 0x49, 0x00, 0x22, 0x08, 0x31, 0x19, 0x60, 0x04, 0x49, 0x5a, 0x60, + 0x19, 0x61, 0x1a, 0x76, 0x70, 0x47, 0xc0, 0x46, 0x18, 0x0c, 0x00, 0x20, + 0x80, 0x58, 0x00, 0x00, 0xd8, 0x0f, 0x00, 0x20, 0x08, 0xb5, 0x08, 0x4b, + 0x8a, 0x00, 0xd0, 0x58, 0x00, 0x28, 0x03, 0xd0, 0x03, 0x68, 0x9b, 0x68, + 0x98, 0x47, 0x06, 0xe0, 0xc9, 0xb2, 0x04, 0x4b, 0x49, 0x01, 0x59, 0x18, + 0x88, 0x68, 0x80, 0x04, 0x80, 0x0c, 0x08, 0xbd, 0xbc, 0x0f, 0x00, 0x20, + 0xdc, 0x0f, 0x00, 0x20, 0x10, 0xb5, 0x0c, 0x1c, 0xff, 0xf7, 0xe6, 0xff, + 0x00, 0x28, 0x0c, 0xd0, 0x06, 0x4b, 0xe1, 0xb2, 0x1b, 0x68, 0x08, 0x31, + 0x49, 0x01, 0x59, 0x18, 0x4a, 0x79, 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, + 0x4b, 0x71, 0x02, 0x23, 0xcb, 0x71, 0x10, 0xbd, 0xdc, 0x0f, 0x00, 0x20, + 0x10, 0xb5, 0xc9, 0xb2, 0x0c, 0x48, 0x49, 0x01, 0x43, 0x18, 0x9a, 0x68, + 0x92, 0x04, 0x92, 0x0c, 0x3f, 0x2a, 0x08, 0xd9, 0x14, 0x1c, 0x9a, 0x68, + 0x40, 0x3c, 0xa4, 0x04, 0x92, 0x0b, 0xa4, 0x0c, 0x92, 0x03, 0x22, 0x43, + 0x02, 0xe0, 0x9a, 0x68, 0x92, 0x0b, 0x92, 0x03, 0x9a, 0x60, 0x41, 0x18, + 0x88, 0x68, 0xc0, 0xb2, 0x10, 0xbd, 0xc0, 0x46, 0xdc, 0x0f, 0x00, 0x20, + 0xf0, 0xb5, 0x1c, 0x1c, 0x2a, 0x4b, 0x85, 0xb0, 0x1b, 0x68, 0x06, 0x1c, + 0x0d, 0x1c, 0x02, 0x92, 0x00, 0x2b, 0x46, 0xd0, 0x27, 0x4b, 0x8a, 0x00, + 0xd0, 0x58, 0x00, 0x28, 0x05, 0xd0, 0x03, 0x68, 0x02, 0x99, 0x5b, 0x68, + 0x22, 0x1c, 0x98, 0x47, 0x3f, 0xe0, 0x30, 0x1c, 0xff, 0xf7, 0x9e, 0xff, + 0xa0, 0x42, 0x04, 0xd2, 0x30, 0x1c, 0x29, 0x1c, 0xff, 0xf7, 0x98, 0xff, + 0x04, 0x1c, 0x29, 0x1c, 0x30, 0x1c, 0xff, 0xf7, 0xbf, 0xff, 0x1c, 0x4f, + 0xe9, 0xb2, 0x4a, 0x01, 0x01, 0x91, 0x39, 0x68, 0x03, 0x92, 0x8b, 0x18, + 0xff, 0x33, 0x5a, 0x7a, 0x01, 0x21, 0x0a, 0x43, 0x17, 0x49, 0x5a, 0x72, + 0xab, 0x01, 0xc9, 0x18, 0x02, 0x98, 0x22, 0x1c, 0x00, 0xf0, 0x91, 0xfe, + 0x00, 0x2c, 0x1b, 0xd0, 0x30, 0x1c, 0x29, 0x1c, 0xff, 0xf7, 0x7a, 0xff, + 0x00, 0x28, 0x15, 0xd1, 0x01, 0x9b, 0x3a, 0x68, 0x08, 0x33, 0x5b, 0x01, + 0xd3, 0x18, 0x19, 0x79, 0x40, 0x20, 0x01, 0x43, 0x19, 0x71, 0x01, 0x21, + 0xd9, 0x71, 0x03, 0x99, 0x53, 0x18, 0xff, 0x33, 0x9a, 0x7a, 0x01, 0x21, + 0x0a, 0x43, 0x9a, 0x72, 0x02, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x00, 0xe0, + 0x20, 0x1c, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0xe0, 0x10, 0x00, 0x20, + 0xbc, 0x0f, 0x00, 0x20, 0xdc, 0x0f, 0x00, 0x20, 0xfc, 0x0d, 0x00, 0x20, + 0x13, 0xb5, 0x6c, 0x46, 0x07, 0x34, 0x22, 0x1c, 0x01, 0x23, 0xff, 0xf7, + 0x99, 0xff, 0x01, 0x28, 0x01, 0xd1, 0x20, 0x78, 0x01, 0xe0, 0x01, 0x20, + 0x40, 0x42, 0x16, 0xbd, 0xf0, 0xb5, 0x1c, 0x1c, 0x3a, 0x4b, 0x85, 0xb0, + 0x1b, 0x68, 0x0e, 0x1c, 0x02, 0x92, 0x00, 0x2b, 0x60, 0xd0, 0x80, 0x23, + 0xdb, 0x01, 0x9c, 0x42, 0x5c, 0xd8, 0x00, 0x22, 0x00, 0x92, 0x00, 0x2c, + 0x56, 0xd0, 0x34, 0x4d, 0xf7, 0xb2, 0x2b, 0x68, 0x01, 0x93, 0x3b, 0x1c, + 0x08, 0x33, 0x01, 0x9a, 0x5b, 0x01, 0xd3, 0x18, 0x9b, 0x79, 0xdb, 0x09, + 0x1a, 0xd0, 0x2f, 0x4b, 0x2f, 0x49, 0x18, 0x68, 0x00, 0xf0, 0x9e, 0xfd, + 0x2e, 0x4b, 0x17, 0x21, 0x58, 0x43, 0x00, 0xf0, 0x99, 0xfd, 0x3b, 0x1c, + 0x08, 0x33, 0x01, 0x9a, 0x5b, 0x01, 0xd3, 0x18, 0xdb, 0x79, 0x9a, 0x07, + 0x08, 0xd4, 0x29, 0x4b, 0x9a, 0x5d, 0x00, 0x2a, 0x38, 0xd1, 0x42, 0x1e, + 0x00, 0x28, 0x35, 0xd0, 0x10, 0x1c, 0xee, 0xe7, 0x24, 0x4b, 0x00, 0x22, + 0x9a, 0x55, 0x25, 0x1e, 0x3f, 0x2d, 0x00, 0xd9, 0x3f, 0x25, 0x22, 0x4a, + 0xb3, 0x01, 0xd3, 0x18, 0x18, 0x1c, 0x02, 0x99, 0x2a, 0x1c, 0x03, 0x93, + 0x00, 0xf0, 0x11, 0xfe, 0x18, 0x4a, 0x7b, 0x01, 0xd3, 0x18, 0x03, 0x9a, + 0xa9, 0x04, 0x5a, 0x61, 0x9a, 0x69, 0x89, 0x0c, 0x92, 0x0b, 0x92, 0x03, + 0x0a, 0x43, 0x9a, 0x61, 0x3b, 0x1c, 0x01, 0x9a, 0x08, 0x33, 0x5b, 0x01, + 0xd3, 0x18, 0x02, 0x22, 0xda, 0x71, 0x59, 0x79, 0x80, 0x22, 0x52, 0x42, + 0x0a, 0x43, 0x5a, 0x71, 0x00, 0x9b, 0x02, 0x9a, 0x5b, 0x19, 0x52, 0x19, + 0x00, 0x93, 0x64, 0x1b, 0x02, 0x92, 0xa6, 0xe7, 0x00, 0x98, 0x0b, 0xe0, + 0x01, 0x20, 0x08, 0xe0, 0x01, 0x22, 0x9a, 0x55, 0x7b, 0x01, 0xed, 0x18, + 0xab, 0x69, 0x10, 0x1c, 0x9b, 0x0b, 0x9b, 0x03, 0xab, 0x61, 0x40, 0x42, + 0x05, 0xb0, 0xf0, 0xbd, 0xe0, 0x10, 0x00, 0x20, 0xdc, 0x0f, 0x00, 0x20, + 0x08, 0x00, 0x00, 0x20, 0x40, 0x42, 0x0f, 0x00, 0x70, 0x11, 0x01, 0x00, + 0x34, 0x0c, 0x00, 0x20, 0x3c, 0x0c, 0x00, 0x20, 0x01, 0x4a, 0x02, 0x4b, + 0x1a, 0x60, 0x70, 0x47, 0x00, 0x50, 0x00, 0x41, 0xdc, 0x0f, 0x00, 0x20, + 0x01, 0x20, 0x70, 0x47, 0x08, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, + 0x98, 0x47, 0x08, 0xbd, 0x13, 0x04, 0x00, 0x00, 0x03, 0x1c, 0xfc, 0x33, + 0xd9, 0x69, 0x9a, 0x69, 0x91, 0x42, 0x03, 0xd0, 0xdb, 0x69, 0xc0, 0x18, + 0x00, 0x7d, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x70, 0x47, 0x10, 0xb5, + 0x04, 0x1c, 0x00, 0x69, 0xff, 0xf7, 0xf7, 0xfc, 0x22, 0x1c, 0x00, 0x23, + 0xfc, 0x32, 0x93, 0x61, 0xd3, 0x61, 0x86, 0x22, 0x92, 0x00, 0xa4, 0x18, + 0x63, 0x60, 0xa3, 0x60, 0x10, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x87, 0xb0, + 0x01, 0x93, 0x0c, 0xab, 0x1b, 0x78, 0x80, 0x26, 0x02, 0x93, 0x0d, 0xab, + 0x1b, 0x78, 0x00, 0x25, 0x03, 0x93, 0x0e, 0xab, 0x1b, 0x78, 0x76, 0x00, + 0x04, 0x93, 0x0f, 0xab, 0x1b, 0x78, 0x04, 0x1c, 0x05, 0x93, 0xfa, 0x23, + 0x9b, 0x00, 0x83, 0x60, 0x19, 0x4b, 0x0f, 0x1c, 0x08, 0x33, 0x00, 0x92, + 0x45, 0x60, 0x03, 0x60, 0x29, 0x1c, 0x32, 0x1c, 0x14, 0x30, 0x00, 0xf0, + 0x8b, 0xfd, 0x23, 0x1c, 0x8e, 0x22, 0xfc, 0x33, 0x52, 0x00, 0x9d, 0x61, + 0xa0, 0x18, 0xdd, 0x61, 0x32, 0x1c, 0x29, 0x1c, 0x00, 0xf0, 0x80, 0xfd, + 0x86, 0x22, 0x92, 0x00, 0xa3, 0x18, 0x5d, 0x60, 0x00, 0x9a, 0x9d, 0x60, + 0x89, 0x23, 0x9b, 0x00, 0x27, 0x61, 0xe2, 0x54, 0x01, 0x9a, 0x0a, 0x4b, + 0x20, 0x1c, 0xe2, 0x54, 0x02, 0x9a, 0x09, 0x4b, 0xe2, 0x54, 0x03, 0x9a, + 0x08, 0x4b, 0xe2, 0x54, 0x04, 0x9a, 0x8a, 0x23, 0x9b, 0x00, 0xe2, 0x54, + 0x05, 0x9a, 0x8e, 0x23, 0x9b, 0x00, 0xe2, 0x54, 0x07, 0xb0, 0xf0, 0xbd, + 0xa8, 0x58, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, 0x26, 0x02, 0x00, 0x00, + 0x27, 0x02, 0x00, 0x00, 0x30, 0xb5, 0x85, 0xb0, 0x04, 0x1c, 0x08, 0xa8, + 0x05, 0x78, 0x09, 0xa8, 0x00, 0x78, 0x00, 0x95, 0x01, 0x90, 0xff, 0x20, + 0x02, 0x90, 0x03, 0x90, 0x20, 0x1c, 0xff, 0xf7, 0x9f, 0xff, 0x20, 0x1c, + 0x05, 0xb0, 0x30, 0xbd, 0xf0, 0x23, 0x08, 0x1c, 0x18, 0x40, 0x30, 0x38, + 0x43, 0x42, 0x58, 0x41, 0x70, 0x47, 0xf0, 0x23, 0x1b, 0x01, 0x19, 0x40, + 0x80, 0x23, 0x9b, 0x00, 0x99, 0x42, 0x0c, 0xd0, 0xc0, 0x23, 0x9b, 0x00, + 0x99, 0x42, 0x06, 0xd0, 0x80, 0x23, 0x5b, 0x00, 0x05, 0x20, 0x99, 0x42, + 0x04, 0xd0, 0x00, 0x20, 0x02, 0xe0, 0x07, 0x20, 0x00, 0xe0, 0x06, 0x20, + 0x70, 0x47, 0x0f, 0x23, 0x19, 0x40, 0x01, 0x29, 0x05, 0xd0, 0x02, 0x39, + 0x4b, 0x42, 0x4b, 0x41, 0x02, 0x20, 0xc0, 0x1a, 0x00, 0xe0, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x00, 0xf0, 0xb5, 0x89, 0x23, 0x85, 0xb0, 0x03, 0x91, + 0x9b, 0x00, 0x04, 0x1c, 0x18, 0x27, 0xc0, 0x5c, 0x3b, 0x1c, 0x43, 0x43, + 0x32, 0x4e, 0x08, 0x21, 0xf3, 0x18, 0x59, 0x56, 0x15, 0x1c, 0x00, 0xf0, + 0xc5, 0xfb, 0x30, 0x4b, 0x08, 0x21, 0xe0, 0x5c, 0x3b, 0x1c, 0x43, 0x43, + 0xf3, 0x18, 0x59, 0x56, 0x00, 0xf0, 0xbc, 0xfb, 0x2c, 0x4b, 0xe2, 0x5c, + 0x02, 0x2a, 0x0a, 0xd1, 0x8e, 0x23, 0x9b, 0x00, 0xe0, 0x5c, 0xff, 0x28, + 0x05, 0xd0, 0x47, 0x43, 0x08, 0x21, 0xf7, 0x19, 0x79, 0x56, 0x00, 0xf0, + 0xad, 0xfb, 0x8a, 0x27, 0xbf, 0x00, 0xe0, 0x5d, 0xff, 0x28, 0x1a, 0xd0, + 0x01, 0x21, 0x00, 0xf0, 0x1b, 0xfb, 0xe3, 0x5d, 0x18, 0x22, 0x5a, 0x43, + 0xb3, 0x56, 0x20, 0x49, 0xdb, 0x01, 0x58, 0x18, 0x8b, 0x21, 0x89, 0x00, + 0x60, 0x50, 0x1e, 0x49, 0xb6, 0x18, 0x5b, 0x18, 0x8c, 0x21, 0x72, 0x68, + 0x89, 0x00, 0x63, 0x50, 0x01, 0x21, 0x91, 0x40, 0x0a, 0x1c, 0x8d, 0x21, + 0x89, 0x00, 0x62, 0x50, 0x1a, 0x60, 0x01, 0x21, 0x0a, 0x1c, 0x03, 0x9b, + 0x20, 0x69, 0xff, 0xf7, 0x01, 0xfd, 0x29, 0x1c, 0x20, 0x1c, 0xff, 0xf7, + 0x8a, 0xff, 0x29, 0x1c, 0x07, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x9b, 0xff, + 0x29, 0x1c, 0x06, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x79, 0xff, 0x39, 0x1c, + 0x00, 0x90, 0x33, 0x1c, 0x20, 0x69, 0x01, 0x22, 0xff, 0xf7, 0xca, 0xfb, + 0x07, 0x4b, 0x20, 0x69, 0xe1, 0x5c, 0x09, 0x4b, 0xe2, 0x5c, 0xff, 0xf7, + 0xdf, 0xfb, 0x20, 0x69, 0xff, 0xf7, 0xfd, 0xfb, 0x05, 0xb0, 0xf0, 0xbd, + 0x20, 0x55, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, 0x27, 0x02, 0x00, 0x00, + 0x18, 0x44, 0x00, 0x41, 0x14, 0x44, 0x00, 0x41, 0x26, 0x02, 0x00, 0x00, + 0x03, 0x1c, 0xfc, 0x33, 0x58, 0x68, 0x9b, 0x68, 0xc0, 0x1a, 0x01, 0xd5, + 0x01, 0x30, 0xff, 0x30, 0x70, 0x47, 0x10, 0xb5, 0x04, 0x1c, 0x8e, 0x23, + 0x5b, 0x00, 0xe0, 0x18, 0xff, 0xf7, 0xf0, 0xff, 0x00, 0x28, 0xf8, 0xd1, + 0x20, 0x69, 0xff, 0xf7, 0xe4, 0xfb, 0x10, 0xbd, 0x08, 0xb5, 0x14, 0x30, + 0xff, 0xf7, 0xe6, 0xff, 0x08, 0xbd, 0xfc, 0x30, 0x42, 0x68, 0x83, 0x68, + 0x9a, 0x42, 0x04, 0xdb, 0x43, 0x68, 0x80, 0x68, 0xc0, 0x1a, 0xff, 0x30, + 0x03, 0xe0, 0x82, 0x68, 0x43, 0x68, 0xd0, 0x1a, 0x01, 0x38, 0x70, 0x47, + 0x08, 0xb5, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0xec, 0xff, 0x08, 0xbd, + 0x38, 0xb5, 0x04, 0x1c, 0x00, 0x69, 0xff, 0xf7, 0xe0, 0xfb, 0x00, 0x28, + 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0xeb, 0xfb, 0x20, 0x69, 0xff, 0xf7, + 0xdd, 0xfb, 0x20, 0x69, 0xff, 0xf7, 0xc5, 0xfb, 0x00, 0x28, 0x20, 0xd0, + 0x20, 0x69, 0xff, 0xf7, 0xe0, 0xfb, 0x23, 0x1c, 0xfc, 0x33, 0x9a, 0x69, + 0xd9, 0x69, 0x01, 0x32, 0xd2, 0xb2, 0x8a, 0x42, 0x03, 0xd0, 0x99, 0x69, + 0x61, 0x18, 0x08, 0x75, 0x9a, 0x61, 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, + 0xff, 0x2b, 0x0c, 0xd0, 0x20, 0x1c, 0x14, 0x30, 0xff, 0xf7, 0xc1, 0xff, + 0x09, 0x28, 0x06, 0xdc, 0x8b, 0x23, 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, + 0xe3, 0x58, 0xa2, 0x58, 0x1a, 0x60, 0x20, 0x69, 0xff, 0xf7, 0xba, 0xfb, + 0x00, 0x28, 0x1f, 0xd0, 0x8e, 0x22, 0x52, 0x00, 0xa5, 0x18, 0x28, 0x1c, + 0xff, 0xf7, 0x92, 0xff, 0x03, 0x1c, 0x20, 0x69, 0x00, 0x2b, 0x13, 0xd0, + 0x86, 0x22, 0x92, 0x00, 0xa3, 0x18, 0x99, 0x68, 0x5a, 0x68, 0x91, 0x42, + 0x06, 0xd0, 0x9a, 0x68, 0xa9, 0x5c, 0x9a, 0x68, 0x01, 0x32, 0xd2, 0xb2, + 0x9a, 0x60, 0x01, 0xe0, 0x01, 0x21, 0x49, 0x42, 0xc9, 0xb2, 0xff, 0xf7, + 0xa4, 0xfb, 0x01, 0xe0, 0xff, 0xf7, 0xac, 0xfb, 0x20, 0x69, 0xff, 0xf7, + 0x7f, 0xfb, 0x00, 0x28, 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x7e, 0xfb, + 0x20, 0x69, 0xff, 0xf7, 0x6e, 0xfb, 0x38, 0xbd, 0x70, 0xb5, 0x04, 0x1c, + 0x00, 0x69, 0x0d, 0x1c, 0xff, 0xf7, 0x86, 0xfb, 0x8e, 0x22, 0x52, 0x00, + 0xa6, 0x18, 0x00, 0x28, 0x0e, 0xd0, 0x30, 0x1c, 0xff, 0xf7, 0x5e, 0xff, + 0x00, 0x28, 0x3d, 0xd0, 0x08, 0xe0, 0xef, 0xf3, 0x10, 0x83, 0xda, 0x07, + 0x22, 0xd4, 0x1f, 0x4b, 0x5a, 0x68, 0xd2, 0x05, 0xd2, 0x0d, 0x0a, 0xd1, + 0x86, 0x22, 0x92, 0x00, 0xa3, 0x18, 0x58, 0x68, 0x9a, 0x68, 0x01, 0x30, + 0xff, 0x21, 0x08, 0x40, 0x90, 0x42, 0xec, 0xd0, 0x1b, 0xe0, 0x10, 0x3a, + 0xd2, 0xb2, 0x53, 0xb2, 0x00, 0x2b, 0x08, 0xda, 0x0f, 0x23, 0x1a, 0x40, + 0x08, 0x3a, 0x14, 0x4b, 0x92, 0x08, 0x92, 0x00, 0xd2, 0x18, 0x53, 0x68, + 0x04, 0xe0, 0x9b, 0x08, 0xc0, 0x33, 0x11, 0x4a, 0x9b, 0x00, 0x9b, 0x58, + 0x20, 0x69, 0xff, 0xf7, 0x51, 0xfb, 0x00, 0x28, 0xdc, 0xd0, 0x20, 0x1c, + 0xff, 0xf7, 0x5c, 0xff, 0xd8, 0xe7, 0x5a, 0x68, 0x01, 0x32, 0x0a, 0x40, + 0x99, 0x68, 0x8a, 0x42, 0x02, 0xd0, 0x59, 0x68, 0x75, 0x54, 0x5a, 0x60, + 0x20, 0x69, 0xff, 0xf7, 0x4f, 0xfb, 0x03, 0xe0, 0x20, 0x69, 0x29, 0x1c, + 0xff, 0xf7, 0x43, 0xfb, 0x01, 0x20, 0x70, 0xbd, 0x00, 0xed, 0x00, 0xe0, + 0x18, 0xed, 0x00, 0xe0, 0x00, 0xe1, 0x00, 0xe0, 0x38, 0xb5, 0x03, 0x1c, + 0xfc, 0x33, 0xd9, 0x69, 0x9a, 0x69, 0x04, 0x1c, 0x91, 0x42, 0x07, 0xd0, + 0xda, 0x69, 0x82, 0x18, 0x15, 0x7d, 0xda, 0x69, 0x01, 0x32, 0xd2, 0xb2, + 0xda, 0x61, 0x01, 0xe0, 0x01, 0x25, 0x6d, 0x42, 0x8a, 0x23, 0x9b, 0x00, + 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, 0x20, 0x1c, 0x14, 0x30, 0xff, 0xf7, + 0x12, 0xff, 0x0a, 0x28, 0x06, 0xdd, 0x8c, 0x23, 0x8d, 0x22, 0x9b, 0x00, + 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, 0x1a, 0x60, 0x28, 0x1c, 0x38, 0xbd, + 0xfe, 0xe7, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x4b, 0x1b, 0x68, 0x00, 0x2b, + 0x00, 0xd0, 0x98, 0x47, 0x08, 0xbd, 0xc0, 0x46, 0xe4, 0x10, 0x00, 0x20, + 0x38, 0xb5, 0x0f, 0x49, 0x0f, 0x4c, 0xa1, 0x42, 0x04, 0xd1, 0x00, 0xf0, + 0x4f, 0xf8, 0xfd, 0xf7, 0x43, 0xfd, 0x0b, 0xe0, 0x0c, 0x4d, 0x8d, 0x42, + 0xf7, 0xd0, 0x00, 0x23, 0xca, 0x18, 0xe8, 0x18, 0xa2, 0x42, 0x04, 0xd2, + 0x00, 0x68, 0x04, 0x33, 0x10, 0x60, 0xf7, 0xe7, 0xfe, 0xe7, 0x90, 0x42, + 0xeb, 0xd0, 0x06, 0x4b, 0x06, 0x4a, 0x93, 0x42, 0xe7, 0xd2, 0x00, 0x22, + 0x04, 0xc3, 0xf9, 0xe7, 0x00, 0x00, 0x00, 0x20, 0xa0, 0x00, 0x00, 0x20, + 0x48, 0x59, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x20, 0xfc, 0x10, 0x00, 0x20, + 0x08, 0xb5, 0x00, 0xf0, 0x26, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x00, 0xf0, + 0x17, 0xf8, 0x08, 0xbd, 0x01, 0x4b, 0x18, 0x68, 0x70, 0x47, 0xc0, 0x46, + 0xe8, 0x10, 0x00, 0x20, 0x70, 0xb5, 0x04, 0x1e, 0x08, 0xd0, 0x05, 0x4b, + 0x1d, 0x68, 0x1e, 0x1c, 0x00, 0xf0, 0x12, 0xf8, 0x33, 0x68, 0x5b, 0x1b, + 0xa3, 0x42, 0xf9, 0xd3, 0x70, 0xbd, 0xc0, 0x46, 0xe8, 0x10, 0x00, 0x20, + 0x08, 0xb5, 0x03, 0x4b, 0x1a, 0x68, 0x01, 0x32, 0x1a, 0x60, 0x00, 0xf0, + 0x4d, 0xfa, 0x08, 0xbd, 0xe8, 0x10, 0x00, 0x20, 0x70, 0x47, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x00, 0x70, 0xb5, 0x49, 0x4a, 0x1e, 0x21, 0x53, 0x68, + 0x02, 0x20, 0x8b, 0x43, 0x03, 0x43, 0x47, 0x49, 0x53, 0x60, 0x8b, 0x69, + 0x08, 0x24, 0x23, 0x43, 0x8b, 0x61, 0x45, 0x4c, 0x45, 0x4b, 0x9c, 0x82, + 0x9c, 0x8a, 0x20, 0x43, 0x98, 0x82, 0x10, 0x1c, 0xda, 0x68, 0x94, 0x07, + 0xfc, 0xd5, 0x42, 0x4a, 0x01, 0x24, 0x14, 0x70, 0x14, 0x78, 0xe5, 0x07, + 0x04, 0xd5, 0x3f, 0x4c, 0x64, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xf7, 0xdb, + 0x01, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, + 0x3a, 0x4d, 0x39, 0x4c, 0x65, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x82, 0x25, 0x35, 0x4c, 0xed, 0x01, 0x65, 0x80, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x02, 0x24, 0x9c, 0x84, 0xdc, 0x68, + 0xe6, 0x06, 0xfc, 0xd5, 0x31, 0x4d, 0x2e, 0x4c, 0xe5, 0x62, 0xdd, 0x68, + 0x2c, 0x4c, 0xee, 0x06, 0xfb, 0xd5, 0xa5, 0x8c, 0x2e, 0x4e, 0x35, 0x43, + 0xa5, 0x84, 0xdd, 0x68, 0x28, 0x4c, 0xee, 0x06, 0xfb, 0xd5, 0xa5, 0x8c, + 0x02, 0x26, 0x35, 0x43, 0xa5, 0x84, 0xdc, 0x68, 0x25, 0x06, 0xfc, 0xd5, + 0x23, 0x4c, 0xe4, 0x68, 0x66, 0x06, 0xf8, 0xd5, 0xdc, 0x68, 0xe5, 0x06, + 0xfc, 0xd5, 0x00, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x22, 0x4d, 0x1d, 0x4c, 0x65, 0x60, 0x55, 0x78, 0x1c, 0x4c, + 0x6d, 0xb2, 0x00, 0x2d, 0xfa, 0xdb, 0x1e, 0x6a, 0x1e, 0x4d, 0x35, 0x40, + 0x1d, 0x62, 0x1d, 0x6a, 0x80, 0x26, 0xb5, 0x43, 0x1d, 0x62, 0x03, 0x23, + 0xa3, 0x60, 0x1b, 0x4b, 0x63, 0x60, 0x53, 0x78, 0x5b, 0xb2, 0x00, 0x2b, + 0xfb, 0xdb, 0x00, 0x23, 0x0b, 0x72, 0x18, 0x4a, 0x4b, 0x72, 0x8b, 0x72, + 0xcb, 0x72, 0x17, 0x4b, 0xff, 0x21, 0x1a, 0x60, 0x16, 0x4b, 0x17, 0x4a, + 0x1b, 0x68, 0x12, 0x68, 0x5c, 0x01, 0xd2, 0x0e, 0x21, 0x40, 0x11, 0x43, + 0x9a, 0x06, 0x52, 0x0f, 0x12, 0x02, 0x0b, 0x1c, 0x13, 0x43, 0x12, 0x4a, + 0x13, 0x85, 0x43, 0x68, 0x80, 0x22, 0x13, 0x43, 0x43, 0x60, 0x70, 0xbd, + 0x00, 0x40, 0x00, 0x41, 0x00, 0x04, 0x00, 0x40, 0x0c, 0x06, 0x00, 0x00, + 0x00, 0x08, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, 0x01, 0x05, 0x01, 0x00, + 0xb9, 0x05, 0xff, 0x7d, 0x04, 0x0a, 0x00, 0x00, 0x00, 0x07, 0x03, 0x00, + 0xff, 0xfc, 0xff, 0xff, 0x03, 0x06, 0x01, 0x00, 0x00, 0x6c, 0xdc, 0x02, + 0x08, 0x00, 0x00, 0x20, 0x24, 0x60, 0x80, 0x00, 0x20, 0x60, 0x80, 0x00, + 0x00, 0x40, 0x00, 0x42, 0x31, 0x4b, 0xfa, 0x21, 0x18, 0x68, 0x10, 0xb5, + 0x89, 0x00, 0x00, 0xf0, 0xcf, 0xf9, 0x2f, 0x4b, 0x01, 0x38, 0x98, 0x42, + 0x24, 0xd8, 0x2e, 0x4a, 0x2e, 0x4b, 0x50, 0x60, 0x18, 0x6a, 0xc0, 0x21, + 0x00, 0x02, 0x00, 0x0a, 0x09, 0x06, 0x01, 0x43, 0x19, 0x62, 0x00, 0x24, + 0x07, 0x21, 0x94, 0x60, 0x11, 0x60, 0x19, 0x6a, 0x80, 0x22, 0x09, 0x02, + 0x09, 0x0a, 0x12, 0x06, 0x0a, 0x43, 0x1a, 0x62, 0x25, 0x4b, 0xfc, 0x21, + 0x1a, 0x6a, 0x0a, 0x43, 0x1a, 0x62, 0x19, 0x6a, 0xfc, 0x22, 0x92, 0x01, + 0x0a, 0x43, 0x1a, 0x62, 0x19, 0x6a, 0xa0, 0x22, 0xd2, 0x02, 0x0a, 0x43, + 0x1a, 0x62, 0x00, 0xe0, 0xfe, 0xe7, 0x20, 0x1c, 0x00, 0x21, 0x01, 0x34, + 0x00, 0xf0, 0x70, 0xf8, 0x0f, 0x2c, 0xf8, 0xd1, 0x1a, 0x4c, 0x63, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfa, 0xdb, 0x19, 0x4b, 0x63, 0x80, 0x19, 0x4b, + 0x5a, 0x7e, 0xd2, 0x09, 0x01, 0x2a, 0xfa, 0xd0, 0xe4, 0x22, 0xd2, 0x00, + 0x9a, 0x80, 0x3f, 0x22, 0xda, 0x70, 0x59, 0x7e, 0x13, 0x4a, 0xc9, 0x09, + 0x01, 0x29, 0xfa, 0xd0, 0xc0, 0x23, 0x5b, 0x01, 0x00, 0x20, 0x13, 0x61, + 0x90, 0x70, 0x00, 0xf0, 0x23, 0xf8, 0x63, 0x78, 0x5b, 0xb2, 0x00, 0x2b, + 0xfb, 0xdb, 0x0d, 0x4a, 0x09, 0x4b, 0x5a, 0x80, 0x0c, 0x4b, 0xda, 0x79, + 0xd2, 0x09, 0x01, 0x2a, 0xfa, 0xd0, 0x41, 0x22, 0x5a, 0x70, 0x10, 0xbd, + 0x08, 0x00, 0x00, 0x20, 0xff, 0xff, 0xff, 0x00, 0x10, 0xe0, 0x00, 0xe0, + 0x00, 0xed, 0x00, 0xe0, 0x00, 0x04, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, + 0x1e, 0x40, 0x00, 0x00, 0x00, 0x40, 0x00, 0x42, 0x21, 0x40, 0x00, 0x00, + 0x00, 0x48, 0x00, 0x42, 0x00, 0xb5, 0x14, 0x4a, 0x51, 0x7e, 0x13, 0x1c, + 0xc9, 0x09, 0x01, 0x29, 0xf9, 0xd0, 0x01, 0x38, 0x04, 0x28, 0x13, 0xd8, + 0x19, 0x69, 0x10, 0x4a, 0x0a, 0x40, 0x1a, 0x61, 0x5a, 0x78, 0x0f, 0x21, + 0x8a, 0x43, 0x00, 0xf0, 0x41, 0xf9, 0x03, 0x05, 0x09, 0x07, 0x03, 0x00, + 0x01, 0x21, 0x02, 0xe0, 0x03, 0x21, 0x00, 0xe0, 0x02, 0x21, 0x0a, 0x43, + 0x5a, 0x70, 0x0a, 0xe0, 0x11, 0x69, 0xf0, 0x23, 0x1b, 0x05, 0x0b, 0x43, + 0x13, 0x61, 0x53, 0x78, 0x0f, 0x21, 0x8b, 0x43, 0x02, 0x21, 0x0b, 0x43, + 0x53, 0x70, 0x00, 0xbd, 0x00, 0x40, 0x00, 0x42, 0xff, 0xff, 0xff, 0xf0, + 0x10, 0xb5, 0x18, 0x24, 0x02, 0x1c, 0x20, 0x1c, 0x50, 0x43, 0x27, 0x4b, + 0x18, 0x18, 0x00, 0x7a, 0x40, 0xb2, 0x01, 0x30, 0x46, 0xd0, 0x03, 0x29, + 0x44, 0xd8, 0x08, 0x1c, 0x21, 0x1c, 0x00, 0xf0, 0x15, 0xf9, 0x02, 0x33, + 0x11, 0x21, 0x62, 0x43, 0x98, 0x56, 0x9a, 0x18, 0xc3, 0x01, 0x1f, 0x48, + 0x52, 0x68, 0x1b, 0x18, 0x99, 0x18, 0x40, 0x31, 0x02, 0x20, 0x08, 0x70, + 0x01, 0x21, 0x91, 0x40, 0x59, 0x60, 0x2f, 0xe0, 0x62, 0x43, 0x98, 0x56, + 0x18, 0x49, 0x9a, 0x18, 0x52, 0x68, 0xc3, 0x01, 0x5b, 0x18, 0x99, 0x18, + 0x40, 0x31, 0x06, 0x20, 0x08, 0x70, 0x01, 0x21, 0x91, 0x40, 0x59, 0x60, + 0x99, 0x61, 0x1f, 0xe0, 0x51, 0x43, 0x5a, 0x56, 0x10, 0x48, 0x59, 0x18, + 0x4b, 0x68, 0xd2, 0x01, 0x11, 0x18, 0xc8, 0x18, 0x40, 0x30, 0x06, 0x24, + 0x04, 0x70, 0x01, 0x20, 0x98, 0x40, 0x48, 0x60, 0x0b, 0x49, 0x52, 0x18, + 0x50, 0x60, 0x0d, 0xe0, 0x62, 0x43, 0x98, 0x56, 0x9a, 0x18, 0xc3, 0x01, + 0x06, 0x48, 0x52, 0x68, 0x1b, 0x18, 0x99, 0x18, 0x40, 0x31, 0x02, 0x20, + 0x08, 0x70, 0x01, 0x21, 0x91, 0x40, 0x99, 0x60, 0x10, 0xbd, 0xc0, 0x46, + 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0x10, 0x44, 0x00, 0x41, + 0x18, 0x23, 0x58, 0x43, 0x13, 0x4a, 0xf0, 0xb5, 0x13, 0x18, 0x08, 0x24, + 0x1c, 0x57, 0x01, 0x34, 0x1f, 0xd0, 0x82, 0x56, 0x10, 0x4e, 0xd2, 0x01, + 0x5d, 0x68, 0x01, 0x24, 0x90, 0x19, 0x23, 0x1c, 0x86, 0x68, 0xab, 0x40, + 0x1e, 0x42, 0x0b, 0xd1, 0x0e, 0x1c, 0x77, 0x1e, 0xbe, 0x41, 0x40, 0x19, + 0x34, 0x40, 0x40, 0x30, 0xa5, 0x00, 0x04, 0x78, 0x04, 0x26, 0xb4, 0x43, + 0x2c, 0x43, 0x04, 0x70, 0x00, 0x29, 0x03, 0xd1, 0x05, 0x49, 0x52, 0x18, + 0x53, 0x60, 0x02, 0xe0, 0x02, 0x4e, 0x92, 0x19, 0x93, 0x61, 0xf0, 0xbd, + 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0x10, 0x44, 0x00, 0x41, + 0x18, 0x22, 0x42, 0x43, 0xf8, 0xb5, 0x2d, 0x4d, 0x08, 0x24, 0xaa, 0x18, + 0x14, 0x57, 0x03, 0x1c, 0x62, 0x1c, 0x50, 0xd0, 0x48, 0x1c, 0x00, 0x24, + 0x0c, 0x28, 0x4c, 0xd8, 0x00, 0xf0, 0x8c, 0xf8, 0x07, 0x1e, 0x1e, 0x1e, + 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x0a, 0x0a, 0x0a, 0x0a, 0x00, 0x01, 0x24, + 0x64, 0x42, 0x40, 0xe0, 0x09, 0x29, 0x02, 0xd1, 0x18, 0x1c, 0x00, 0x21, + 0x03, 0xe0, 0x0a, 0x29, 0x04, 0xd1, 0x18, 0x1c, 0x02, 0x21, 0xff, 0xf7, + 0x51, 0xff, 0x23, 0xe0, 0x00, 0x24, 0x0b, 0x29, 0x31, 0xd1, 0x18, 0x1c, + 0x01, 0x21, 0xff, 0xf7, 0x49, 0xff, 0x2c, 0xe0, 0x18, 0x22, 0x53, 0x43, + 0xea, 0x18, 0x52, 0x68, 0xeb, 0x56, 0x01, 0x20, 0x14, 0x1c, 0x04, 0x40, + 0x55, 0x08, 0xdb, 0x01, 0x00, 0x2c, 0x11, 0xd0, 0x12, 0x4c, 0x1b, 0x19, + 0x5d, 0x19, 0x30, 0x35, 0x2e, 0x78, 0x0c, 0x01, 0x0f, 0x21, 0x31, 0x40, + 0x21, 0x43, 0x9a, 0x18, 0xc9, 0xb2, 0x29, 0x70, 0x40, 0x32, 0x13, 0x78, + 0x18, 0x43, 0x10, 0x70, 0x00, 0x24, 0x0e, 0xe0, 0x09, 0x4e, 0x0f, 0x27, + 0x9b, 0x19, 0x5d, 0x19, 0x30, 0x35, 0x2e, 0x78, 0x9a, 0x18, 0xbe, 0x43, + 0x31, 0x43, 0xc9, 0xb2, 0x29, 0x70, 0x40, 0x32, 0x13, 0x78, 0x18, 0x43, + 0x10, 0x70, 0x20, 0x1c, 0xf8, 0xbd, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, + 0x00, 0x44, 0x00, 0x41, 0x15, 0x4a, 0x13, 0x68, 0x58, 0x1c, 0x25, 0xd0, + 0x01, 0x3b, 0x13, 0x60, 0x00, 0x2b, 0x21, 0xd1, 0x72, 0xb6, 0x12, 0x4a, + 0x12, 0x4b, 0x04, 0x32, 0x9a, 0x42, 0x07, 0xd8, 0xbf, 0xf3, 0x4f, 0x8f, + 0x10, 0x4a, 0x11, 0x4b, 0xda, 0x60, 0xbf, 0xf3, 0x4f, 0x8f, 0x11, 0xe0, + 0x0f, 0x4b, 0x19, 0x7d, 0xc8, 0x07, 0xfb, 0xd5, 0x18, 0x8b, 0x20, 0x21, + 0xff, 0x31, 0x92, 0x08, 0x52, 0x00, 0x01, 0x43, 0x19, 0x83, 0xda, 0x61, + 0x0a, 0x4a, 0x1a, 0x80, 0x1a, 0x7d, 0xd1, 0x07, 0xfc, 0xd5, 0xe5, 0xe7, + 0xc0, 0x46, 0xfd, 0xe7, 0x70, 0x47, 0xc0, 0x46, 0x0c, 0x00, 0x00, 0x20, + 0x00, 0x20, 0x00, 0x00, 0x03, 0x02, 0x00, 0x00, 0x04, 0x00, 0xfa, 0x05, + 0x00, 0xed, 0x00, 0xe0, 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, + 0x02, 0xb4, 0x71, 0x46, 0x49, 0x08, 0x49, 0x00, 0x09, 0x5c, 0x49, 0x00, + 0x8e, 0x44, 0x02, 0xbc, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x29, 0x34, 0xd0, + 0x01, 0x23, 0x00, 0x22, 0x10, 0xb4, 0x88, 0x42, 0x2c, 0xd3, 0x01, 0x24, + 0x24, 0x07, 0xa1, 0x42, 0x04, 0xd2, 0x81, 0x42, 0x02, 0xd2, 0x09, 0x01, + 0x1b, 0x01, 0xf8, 0xe7, 0xe4, 0x00, 0xa1, 0x42, 0x04, 0xd2, 0x81, 0x42, + 0x02, 0xd2, 0x49, 0x00, 0x5b, 0x00, 0xf8, 0xe7, 0x88, 0x42, 0x01, 0xd3, + 0x40, 0x1a, 0x1a, 0x43, 0x4c, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, + 0x5c, 0x08, 0x22, 0x43, 0x8c, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, + 0x9c, 0x08, 0x22, 0x43, 0xcc, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, + 0xdc, 0x08, 0x22, 0x43, 0x00, 0x28, 0x03, 0xd0, 0x1b, 0x09, 0x01, 0xd0, + 0x09, 0x09, 0xe3, 0xe7, 0x10, 0x1c, 0x10, 0xbc, 0x70, 0x47, 0x00, 0x28, + 0x01, 0xd0, 0x00, 0x20, 0xc0, 0x43, 0x07, 0xb4, 0x02, 0x48, 0x02, 0xa1, + 0x40, 0x18, 0x02, 0x90, 0x03, 0xbd, 0xc0, 0x46, 0x19, 0x00, 0x00, 0x00, + 0x00, 0x29, 0xf0, 0xd0, 0x03, 0xb5, 0xff, 0xf7, 0xb9, 0xff, 0x0e, 0xbc, + 0x42, 0x43, 0x89, 0x1a, 0x18, 0x47, 0xc0, 0x46, 0x70, 0x47, 0xc0, 0x46, + 0x70, 0xb5, 0x0e, 0x4b, 0x0e, 0x4d, 0x00, 0x24, 0xed, 0x1a, 0xad, 0x10, + 0x1e, 0x1c, 0xac, 0x42, 0x04, 0xd0, 0xa3, 0x00, 0xf3, 0x58, 0x98, 0x47, + 0x01, 0x34, 0xf8, 0xe7, 0x00, 0xf0, 0x32, 0xf9, 0x08, 0x4b, 0x09, 0x4d, + 0x00, 0x24, 0xed, 0x1a, 0xad, 0x10, 0x1e, 0x1c, 0xac, 0x42, 0x04, 0xd0, + 0xa3, 0x00, 0xf3, 0x58, 0x98, 0x47, 0x01, 0x34, 0xf8, 0xe7, 0x70, 0xbd, + 0x74, 0x00, 0x00, 0x20, 0x74, 0x00, 0x00, 0x20, 0x74, 0x00, 0x00, 0x20, + 0x98, 0x00, 0x00, 0x20, 0x08, 0xb5, 0x03, 0x4b, 0x01, 0x1c, 0x18, 0x68, + 0x00, 0xf0, 0x76, 0xf8, 0x08, 0xbd, 0xc0, 0x46, 0x70, 0x00, 0x00, 0x20, + 0x08, 0xb5, 0x03, 0x4b, 0x01, 0x1c, 0x18, 0x68, 0x00, 0xf0, 0x24, 0xf8, + 0x08, 0xbd, 0xc0, 0x46, 0x70, 0x00, 0x00, 0x20, 0x30, 0xb5, 0x00, 0x23, + 0x93, 0x42, 0x08, 0xd0, 0xc5, 0x5c, 0x01, 0x33, 0xcc, 0x18, 0x01, 0x3c, + 0x24, 0x78, 0xa5, 0x42, 0xf6, 0xd0, 0x28, 0x1b, 0x00, 0xe0, 0x00, 0x20, + 0x30, 0xbd, 0x10, 0xb5, 0x00, 0x23, 0x93, 0x42, 0x03, 0xd0, 0xcc, 0x5c, + 0xc4, 0x54, 0x01, 0x33, 0xf9, 0xe7, 0x10, 0xbd, 0x03, 0x1c, 0x82, 0x18, + 0x93, 0x42, 0x02, 0xd0, 0x19, 0x70, 0x01, 0x33, 0xfa, 0xe7, 0x70, 0x47, + 0x30, 0xb5, 0x00, 0x29, 0x40, 0xd0, 0x04, 0x39, 0x0b, 0x68, 0x00, 0x2b, + 0x00, 0xda, 0xc9, 0x18, 0x1e, 0x4a, 0x13, 0x68, 0x14, 0x1c, 0x00, 0x2b, + 0x02, 0xd1, 0x4b, 0x60, 0x11, 0x60, 0x33, 0xe0, 0x99, 0x42, 0x0f, 0xd2, + 0x08, 0x68, 0x0a, 0x18, 0x9a, 0x42, 0x05, 0xd1, 0x13, 0x68, 0x52, 0x68, + 0xc0, 0x18, 0x08, 0x60, 0x4a, 0x60, 0x00, 0xe0, 0x4b, 0x60, 0x21, 0x60, + 0x24, 0xe0, 0x8a, 0x42, 0x03, 0xd8, 0x13, 0x1c, 0x5a, 0x68, 0x00, 0x2a, + 0xf9, 0xd1, 0x1d, 0x68, 0x5c, 0x19, 0x8c, 0x42, 0x0b, 0xd1, 0x09, 0x68, + 0x69, 0x18, 0x58, 0x18, 0x19, 0x60, 0x90, 0x42, 0x14, 0xd1, 0x14, 0x68, + 0x52, 0x68, 0x09, 0x19, 0x19, 0x60, 0x5a, 0x60, 0x0e, 0xe0, 0x8c, 0x42, + 0x02, 0xd9, 0x0c, 0x23, 0x03, 0x60, 0x09, 0xe0, 0x08, 0x68, 0x0c, 0x18, + 0x94, 0x42, 0x03, 0xd1, 0x14, 0x68, 0x52, 0x68, 0x00, 0x19, 0x08, 0x60, + 0x4a, 0x60, 0x59, 0x60, 0x30, 0xbd, 0xc0, 0x46, 0xf0, 0x10, 0x00, 0x20, + 0x70, 0xb5, 0x03, 0x23, 0xcd, 0x1c, 0x9d, 0x43, 0x08, 0x35, 0x06, 0x1c, + 0x0c, 0x2d, 0x01, 0xd2, 0x0c, 0x25, 0x01, 0xe0, 0x00, 0x2d, 0x3f, 0xdb, + 0x8d, 0x42, 0x3d, 0xd3, 0x20, 0x4b, 0x1c, 0x68, 0x1a, 0x1c, 0x21, 0x1c, + 0x00, 0x29, 0x13, 0xd0, 0x08, 0x68, 0x43, 0x1b, 0x0d, 0xd4, 0x0b, 0x2b, + 0x02, 0xd9, 0x0b, 0x60, 0xcc, 0x18, 0x1e, 0xe0, 0x8c, 0x42, 0x02, 0xd1, + 0x63, 0x68, 0x13, 0x60, 0x1a, 0xe0, 0x48, 0x68, 0x60, 0x60, 0x0c, 0x1c, + 0x16, 0xe0, 0x0c, 0x1c, 0x49, 0x68, 0xe9, 0xe7, 0x14, 0x4c, 0x20, 0x68, + 0x00, 0x28, 0x03, 0xd1, 0x30, 0x1c, 0x00, 0xf0, 0x25, 0xf8, 0x20, 0x60, + 0x30, 0x1c, 0x29, 0x1c, 0x00, 0xf0, 0x20, 0xf8, 0x43, 0x1c, 0x15, 0xd0, + 0xc4, 0x1c, 0x03, 0x23, 0x9c, 0x43, 0x84, 0x42, 0x0a, 0xd1, 0x25, 0x60, + 0x20, 0x1c, 0x0b, 0x30, 0x07, 0x22, 0x23, 0x1d, 0x90, 0x43, 0xc3, 0x1a, + 0x0b, 0xd0, 0x5a, 0x42, 0xe2, 0x50, 0x08, 0xe0, 0x21, 0x1a, 0x30, 0x1c, + 0x00, 0xf0, 0x0a, 0xf8, 0x01, 0x30, 0xee, 0xd1, 0x0c, 0x23, 0x33, 0x60, + 0x00, 0x20, 0x70, 0xbd, 0xf0, 0x10, 0x00, 0x20, 0xec, 0x10, 0x00, 0x20, + 0x38, 0xb5, 0x07, 0x4c, 0x00, 0x23, 0x05, 0x1c, 0x08, 0x1c, 0x23, 0x60, + 0x00, 0xf0, 0x2a, 0xf8, 0x43, 0x1c, 0x03, 0xd1, 0x23, 0x68, 0x00, 0x2b, + 0x00, 0xd0, 0x2b, 0x60, 0x38, 0xbd, 0xc0, 0x46, 0xf8, 0x10, 0x00, 0x20, + 0xc9, 0xb2, 0x03, 0x78, 0x00, 0x2b, 0x03, 0xd0, 0x8b, 0x42, 0x04, 0xd0, + 0x01, 0x30, 0xf8, 0xe7, 0x00, 0x29, 0x00, 0xd0, 0x18, 0x1c, 0x70, 0x47, + 0x30, 0xb5, 0x03, 0x1c, 0x00, 0x2a, 0x07, 0xd0, 0x0c, 0x78, 0x01, 0x33, + 0x5d, 0x1e, 0x01, 0x3a, 0x2c, 0x70, 0x01, 0x31, 0x00, 0x2c, 0xf5, 0xd1, + 0x9a, 0x18, 0x93, 0x42, 0x03, 0xd0, 0x00, 0x21, 0x19, 0x70, 0x01, 0x33, + 0xf9, 0xe7, 0x30, 0xbd, 0x09, 0x4a, 0x13, 0x68, 0x00, 0x2b, 0x0c, 0xd0, + 0x18, 0x18, 0x69, 0x46, 0x88, 0x42, 0x02, 0xd8, 0x10, 0x60, 0x18, 0x1c, + 0x70, 0x47, 0x05, 0x4b, 0x0c, 0x22, 0x01, 0x20, 0x1a, 0x60, 0x40, 0x42, + 0xf8, 0xe7, 0x03, 0x4b, 0x13, 0x60, 0xef, 0xe7, 0xf4, 0x10, 0x00, 0x20, + 0xf8, 0x10, 0x00, 0x20, 0xfc, 0x10, 0x00, 0x20, 0xf8, 0xb5, 0xc0, 0x46, + 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, 0xf8, 0xb5, 0xc0, 0x46, + 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, 0x55, 0x50, 0x44, 0x41, + 0x54, 0x45, 0x2e, 0x42, 0x49, 0x4e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1f, 0x22, 0x00, 0x00, + 0x33, 0x22, 0x00, 0x00, 0x19, 0x22, 0x00, 0x00, 0x5d, 0x22, 0x00, 0x00, + 0x61, 0x23, 0x00, 0x00, 0x8d, 0x22, 0x00, 0x00, 0xa1, 0x22, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x2f, 0x00, 0x7c, 0x3c, 0x3e, 0x5e, 0x2b, 0x3d, + 0x3f, 0x2f, 0x5b, 0x5d, 0x3b, 0x2c, 0x2a, 0x22, 0x5c, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x01, 0x34, 0x00, 0x00, 0x75, 0x3b, 0x00, 0x00, 0x19, 0x22, 0x00, 0x00, + 0x1d, 0x22, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x10, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, + 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, + 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x04, + 0x00, 0x04, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x01, + 0x00, 0x01, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x13, 0x00, 0x01, 0x01, + 0x01, 0x01, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x05, + 0x00, 0x05, 0x0a, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x05, + 0x01, 0x05, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x02, 0x00, + 0x02, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, + 0x03, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x02, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x03, + 0x01, 0x03, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x10, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x11, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0a, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0b, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x05, 0x00, 0x01, 0x00, + 0x01, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x06, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x07, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x0f, 0x00, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x02, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x03, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x9d, 0x3e, 0x00, 0x00, 0xc9, 0x3e, 0x00, 0x00, 0x99, 0x3e, 0x00, 0x00, + 0xbd, 0x3e, 0x00, 0x00, 0xb1, 0x3e, 0x00, 0x00, 0x01, 0x3f, 0x00, 0x00, + 0xe5, 0x3e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x65, 0x45, 0x00, 0x00, 0x75, 0x3b, 0x00, 0x00, + 0x91, 0x44, 0x00, 0x00, 0x4f, 0x44, 0x00, 0x00, 0x69, 0x44, 0x00, 0x00, + 0x19, 0x46, 0x00, 0x00, 0xed, 0x41, 0x00, 0x00, 0xdd, 0x41, 0x00, 0x00, + 0x45, 0x43, 0x00, 0x00, 0x07, 0x42, 0x00, 0x00, 0xd9, 0x41, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x40, 0x42, 0x0f, 0x00, + 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0xe4, 0x58, 0x00, 0x00, + 0x04, 0x59, 0x00, 0x00, 0x24, 0x59, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xe0, 0x58, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x20, 0xdd, 0x20, 0x00, 0x00, + 0x05, 0x22, 0x00, 0x00, 0xed, 0x26, 0x00, 0x00, 0xa9, 0x2b, 0x00, 0x00, + 0x55, 0x38, 0x00, 0x00, 0x85, 0x3a, 0x00, 0x00, 0xdd, 0x3a, 0x00, 0x00, + 0x25, 0x3f, 0x00, 0x00, 0xc9, 0x41, 0x00, 0x00, 0xb5, 0x20, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00 diff --git a/libraries/SDU/src/boot/mkrwan1300.h b/libraries/SDU/src/boot/mkrwan1300.h new file mode 100644 index 0000000..f67c5d3 --- /dev/null +++ b/libraries/SDU/src/boot/mkrwan1300.h @@ -0,0 +1,1242 @@ + 0x00, 0x80, 0x00, 0x20, 0xad, 0x3b, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, + 0x95, 0x3b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, + 0x01, 0x3c, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, + 0x95, 0x3b, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, + 0x95, 0x3b, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, 0x99, 0x3b, 0x00, 0x00, + 0x95, 0x3b, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, + 0x95, 0x3b, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, 0xed, 0x3a, 0x00, 0x00, + 0xdd, 0x3a, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, + 0x95, 0x3b, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, + 0x95, 0x3b, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, + 0x95, 0x3b, 0x00, 0x00, 0x95, 0x3b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0xa0, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0x8c, 0x59, 0x00, 0x00, 0x08, 0xb5, 0x08, 0x4b, 0x00, 0x2b, 0x03, 0xd0, + 0x07, 0x48, 0x08, 0x49, 0x00, 0xe0, 0x00, 0xbf, 0x07, 0x48, 0x03, 0x68, + 0x00, 0x2b, 0x03, 0xd0, 0x06, 0x4b, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, + 0x08, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x00, 0x8c, 0x59, 0x00, 0x00, + 0xa4, 0x00, 0x00, 0x20, 0x9c, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xf0, 0xb5, 0x33, 0x4c, 0xa5, 0x44, 0x01, 0xf0, 0x51, 0xfe, 0x02, 0xf0, + 0x89, 0xfd, 0x01, 0x20, 0x01, 0xf0, 0x7a, 0xfd, 0x2f, 0x4d, 0x04, 0x21, + 0x28, 0x1c, 0x00, 0xf0, 0xe7, 0xf9, 0x00, 0x28, 0x44, 0xd0, 0x2d, 0x4e, + 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0xbe, 0xfa, 0x00, 0x28, 0x3d, 0xd0, + 0x29, 0x1c, 0x01, 0xa8, 0x32, 0x1c, 0x01, 0x23, 0x00, 0xf0, 0x6e, 0xfa, + 0x01, 0xa8, 0x00, 0xf0, 0x00, 0xf9, 0x80, 0x21, 0x04, 0x1c, 0xc9, 0x01, + 0x88, 0x42, 0x2d, 0xd9, 0x01, 0xa8, 0x00, 0xf0, 0xe6, 0xf8, 0x22, 0x4a, + 0xc0, 0x21, 0xa7, 0x18, 0x21, 0x48, 0xc9, 0x01, 0x3a, 0x1c, 0x01, 0xf0, + 0xf5, 0xfb, 0xc0, 0x24, 0xe4, 0x01, 0x80, 0x22, 0x0a, 0xa9, 0x92, 0x00, + 0x01, 0xa8, 0x00, 0xf0, 0xcf, 0xf8, 0x80, 0x23, 0x21, 0x1c, 0x0a, 0xaa, + 0x9b, 0x00, 0x19, 0x48, 0x01, 0xf0, 0x8e, 0xfb, 0x80, 0x22, 0x92, 0x00, + 0xa3, 0x18, 0x17, 0x4a, 0xa4, 0x18, 0xbc, 0x42, 0x01, 0xd2, 0x1c, 0x1c, + 0xe9, 0xe7, 0x01, 0x24, 0x01, 0xa8, 0x00, 0xf0, 0xed, 0xf8, 0x00, 0x2c, + 0x06, 0xd0, 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0x8d, 0xfa, 0x01, 0xe0, + 0x00, 0x24, 0xf3, 0xe7, 0xc0, 0x23, 0xdb, 0x01, 0x1b, 0x68, 0x83, 0xf3, + 0x08, 0x88, 0x0c, 0x4b, 0xc0, 0x22, 0xd2, 0x01, 0x9a, 0x60, 0x0b, 0x4b, + 0x1b, 0x68, 0x18, 0x47, 0x00, 0x20, 0x8b, 0x23, 0x9b, 0x00, 0x9d, 0x44, + 0xf0, 0xbd, 0xc0, 0x46, 0xd4, 0xfd, 0xff, 0xff, 0xd4, 0x00, 0x00, 0x20, + 0xd0, 0x4e, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xbc, 0x00, 0x00, 0x20, + 0x00, 0xa2, 0xff, 0xff, 0x00, 0xed, 0x00, 0xe0, 0x04, 0x60, 0x00, 0x00, + 0x08, 0xb5, 0x00, 0x21, 0x02, 0x48, 0x0a, 0x1c, 0x01, 0xf0, 0x38, 0xfb, + 0x08, 0xbd, 0xc0, 0x46, 0xbc, 0x00, 0x00, 0x20, 0x00, 0x20, 0x70, 0x47, + 0x70, 0x47, 0x13, 0xb5, 0x02, 0x68, 0x6b, 0x46, 0xd9, 0x71, 0x07, 0x33, + 0x54, 0x68, 0x19, 0x1c, 0x01, 0x22, 0xa0, 0x47, 0x16, 0xbd, 0x38, 0xb5, + 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x25, 0xa8, 0x42, 0x02, 0xd1, 0x01, 0x23, + 0x63, 0x60, 0x0a, 0xe0, 0x45, 0x60, 0x92, 0xb2, 0x01, 0xf0, 0x04, 0xf8, + 0x23, 0x6a, 0x5b, 0x68, 0x00, 0x2b, 0x02, 0xd0, 0x01, 0x23, 0x63, 0x60, + 0x28, 0x1c, 0x38, 0xbd, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x01, 0xd0, + 0x00, 0xf0, 0x42, 0xfe, 0x08, 0xbd, 0x00, 0x00, 0x13, 0xb5, 0x6c, 0x46, + 0x07, 0x34, 0x21, 0x1c, 0x01, 0x22, 0x00, 0xf0, 0x5d, 0xfd, 0x01, 0x28, + 0x01, 0xd1, 0x20, 0x78, 0x00, 0xe0, 0x01, 0x48, 0x00, 0xb2, 0x16, 0xbd, + 0xff, 0xff, 0x00, 0x00, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x02, 0xd0, + 0xff, 0xf7, 0xea, 0xff, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x08, 0xbd, + 0x38, 0xb5, 0x05, 0x1c, 0x00, 0x6a, 0x00, 0x28, 0x0a, 0xd0, 0xff, 0xf7, + 0xdf, 0xff, 0x04, 0x1c, 0x63, 0x1c, 0x05, 0xd0, 0x28, 0x6a, 0x01, 0x69, + 0x01, 0x39, 0x00, 0xf0, 0xe5, 0xfd, 0x20, 0x1c, 0x38, 0xbd, 0x00, 0x00, + 0xf8, 0xb5, 0xfa, 0x23, 0x9b, 0x00, 0x83, 0x60, 0x0d, 0x4b, 0x00, 0x25, + 0x08, 0x33, 0x04, 0x1c, 0x45, 0x60, 0x03, 0x60, 0x28, 0x20, 0x0f, 0x1c, + 0x16, 0x1c, 0x02, 0xf0, 0xcf, 0xfc, 0x20, 0x62, 0xa8, 0x42, 0x0a, 0xd0, + 0x39, 0x1c, 0x28, 0x22, 0x02, 0xf0, 0xeb, 0xfc, 0x20, 0x1c, 0x10, 0x30, + 0x31, 0x1c, 0x0c, 0x22, 0x02, 0xf0, 0xb0, 0xfd, 0x25, 0x77, 0x20, 0x1c, + 0xf8, 0xbd, 0xc0, 0x46, 0xe0, 0x4e, 0x00, 0x00, 0xfa, 0x22, 0x92, 0x00, + 0x82, 0x60, 0x04, 0x4a, 0x00, 0x23, 0x08, 0x32, 0x43, 0x60, 0x02, 0x60, + 0x03, 0x62, 0x03, 0x74, 0x70, 0x47, 0xc0, 0x46, 0xe0, 0x4e, 0x00, 0x00, + 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x01, 0xd0, 0x00, 0xf0, 0x02, 0xfd, + 0x08, 0xbd, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x04, 0xd0, 0x00, 0xf0, + 0xa5, 0xfd, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x08, 0xbd, 0x03, 0x6a, + 0x00, 0x2b, 0x01, 0xd0, 0x18, 0x69, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, + 0x70, 0x47, 0x00, 0x6a, 0x00, 0x28, 0x00, 0xd0, 0xc0, 0x69, 0x70, 0x47, + 0x38, 0xb5, 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x28, 0x0b, 0xd0, 0x20, 0x1c, + 0xff, 0xf7, 0xf3, 0xff, 0x05, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0xe7, 0xff, + 0x02, 0x4b, 0x28, 0x1a, 0x98, 0x42, 0x00, 0xd9, 0x18, 0x1c, 0x38, 0xbd, + 0xff, 0x7f, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x28, + 0x06, 0xd0, 0x00, 0xf0, 0xe7, 0xfd, 0x20, 0x6a, 0x02, 0xf0, 0x7c, 0xfc, + 0x00, 0x23, 0x23, 0x62, 0x10, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x0a, 0x1c, + 0x0c, 0x49, 0x8a, 0xb0, 0x04, 0x1c, 0x00, 0x23, 0x00, 0x91, 0x69, 0x46, + 0x4b, 0x72, 0x01, 0x93, 0x21, 0x1c, 0x68, 0x46, 0x01, 0x23, 0x00, 0xf0, + 0x81, 0xfe, 0x04, 0x1c, 0x60, 0x1e, 0x84, 0x41, 0xe4, 0xb2, 0x00, 0x2c, + 0x02, 0xd0, 0x68, 0x46, 0x00, 0xf0, 0xc8, 0xfd, 0x20, 0x1c, 0x0a, 0xb0, + 0x10, 0xbd, 0xc0, 0x46, 0x28, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x01, 0x23, + 0x00, 0x2a, 0x05, 0xd0, 0x00, 0xf0, 0x1a, 0xff, 0x03, 0x1c, 0x58, 0x1e, + 0x83, 0x41, 0xdb, 0xb2, 0x18, 0x1c, 0x08, 0xbd, 0x38, 0xb5, 0x01, 0x22, + 0x05, 0x1c, 0x0c, 0x1c, 0x01, 0xf0, 0x94, 0xf9, 0x02, 0x1c, 0x01, 0x20, + 0x00, 0x2a, 0x03, 0xd1, 0x28, 0x1c, 0x21, 0x1c, 0x01, 0xf0, 0x8c, 0xf9, + 0x38, 0xbd, 0xf0, 0xb5, 0x0c, 0x68, 0x03, 0x5d, 0x2f, 0x3b, 0x5d, 0x42, + 0x6b, 0x41, 0xe4, 0x18, 0x27, 0x1c, 0x0c, 0x37, 0x23, 0x1c, 0xc5, 0x5c, + 0x1e, 0x1b, 0x2f, 0x2d, 0x09, 0xd0, 0x00, 0x2d, 0x07, 0xd0, 0x01, 0x33, + 0x16, 0x1b, 0xf6, 0x18, 0x01, 0x3e, 0x35, 0x70, 0xbb, 0x42, 0xf2, 0xd1, + 0x0c, 0x26, 0x00, 0x24, 0x94, 0x55, 0xc2, 0x5c, 0x2f, 0x3a, 0x54, 0x42, + 0x62, 0x41, 0x9b, 0x18, 0x0b, 0x60, 0xc0, 0x5c, 0x43, 0x1e, 0x98, 0x41, + 0xc0, 0xb2, 0xf0, 0xbd, 0xf0, 0xb5, 0xa1, 0xb0, 0x03, 0x90, 0x25, 0x48, + 0x0d, 0x1c, 0x04, 0x92, 0x05, 0x93, 0x0c, 0xaa, 0x00, 0x23, 0x16, 0xa9, + 0x0d, 0x93, 0x0c, 0x90, 0x53, 0x72, 0x17, 0x93, 0x16, 0x90, 0x4b, 0x72, + 0x07, 0x93, 0x2c, 0x1c, 0x00, 0x92, 0x07, 0xa9, 0x08, 0xaa, 0x03, 0x98, + 0xff, 0xf7, 0xc3, 0xff, 0x01, 0x26, 0x02, 0x1c, 0x72, 0x40, 0x01, 0x90, + 0xd2, 0xb2, 0x20, 0x1c, 0x08, 0xa9, 0x05, 0x9b, 0x04, 0x9f, 0xb8, 0x47, + 0x00, 0x28, 0x07, 0xd1, 0xac, 0x42, 0x01, 0xd1, 0x00, 0x20, 0x23, 0xe0, + 0x20, 0x1c, 0x00, 0xf0, 0x57, 0xfd, 0xf9, 0xe7, 0x01, 0x9f, 0x00, 0x2f, + 0x11, 0xd0, 0x33, 0x1c, 0x00, 0x98, 0x21, 0x1c, 0x08, 0xaa, 0x00, 0xf0, + 0xfd, 0xfd, 0x06, 0x1c, 0xac, 0x42, 0x0f, 0xd0, 0x20, 0x1c, 0x00, 0xf0, + 0x47, 0xfd, 0x00, 0x2e, 0xe8, 0xd0, 0x23, 0x1c, 0x00, 0x9c, 0x00, 0x93, + 0xd1, 0xe7, 0xac, 0x42, 0x02, 0xd0, 0x20, 0x1c, 0x00, 0xf0, 0x3c, 0xfd, + 0x30, 0x1c, 0x03, 0xe0, 0x00, 0x28, 0xdb, 0xd0, 0x16, 0xac, 0xf0, 0xe7, + 0x21, 0xb0, 0xf0, 0xbd, 0x28, 0x4f, 0x00, 0x00, 0x38, 0xb5, 0x03, 0x1c, + 0x41, 0x33, 0x1b, 0x78, 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x2b, 0x02, 0xd0, + 0x38, 0x30, 0x00, 0xf0, 0x27, 0xfd, 0x20, 0x1c, 0x01, 0x21, 0x2a, 0x1c, + 0x00, 0xf0, 0xc8, 0xf9, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x0f, 0xe0, + 0x25, 0x1c, 0x10, 0x35, 0x28, 0x1c, 0x21, 0x1c, 0xff, 0xf7, 0x62, 0xff, + 0x00, 0x28, 0xf5, 0xd0, 0x20, 0x1c, 0x38, 0x30, 0x29, 0x1c, 0x00, 0xf0, + 0xcf, 0xfb, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x38, 0xbd, 0x00, 0x00, + 0x4b, 0x68, 0x43, 0x60, 0x0a, 0x4b, 0x03, 0x60, 0x0b, 0x7a, 0x03, 0x72, + 0x4b, 0x7a, 0x43, 0x72, 0xcb, 0x68, 0xc3, 0x60, 0x0b, 0x69, 0x03, 0x61, + 0x4b, 0x69, 0x43, 0x61, 0x0b, 0x7e, 0x03, 0x76, 0xcb, 0x69, 0xc3, 0x61, + 0x0b, 0x6a, 0x49, 0x6a, 0x03, 0x62, 0x41, 0x62, 0x70, 0x47, 0xc0, 0x46, + 0x28, 0x4f, 0x00, 0x00, 0xf0, 0xb5, 0x9d, 0xb0, 0x08, 0xae, 0x02, 0x92, + 0x03, 0x93, 0x27, 0x4a, 0x00, 0x23, 0x12, 0xaf, 0x05, 0x1c, 0x73, 0x60, + 0x7b, 0x60, 0x10, 0x31, 0x30, 0x1c, 0x08, 0x92, 0x73, 0x72, 0x12, 0x92, + 0x7b, 0x72, 0x00, 0xf0, 0x9d, 0xfb, 0x02, 0x9c, 0x20, 0x1c, 0x2f, 0x21, + 0x02, 0xf0, 0x4a, 0xfc, 0x00, 0x28, 0x2e, 0xd0, 0x23, 0x78, 0x2f, 0x2b, + 0x01, 0xd1, 0x01, 0x34, 0xf4, 0xe7, 0x00, 0x1b, 0xc0, 0xb2, 0x03, 0x1c, + 0x0c, 0x28, 0x00, 0xd9, 0x0c, 0x23, 0xdb, 0xb2, 0x1a, 0x1c, 0x21, 0x1c, + 0x04, 0xa8, 0x01, 0x93, 0x02, 0xf0, 0x42, 0xfc, 0x01, 0x9a, 0x00, 0x23, + 0x04, 0xa9, 0x38, 0x1c, 0x8b, 0x54, 0x00, 0xf0, 0xbf, 0xfc, 0x38, 0x1c, + 0x31, 0x1c, 0x04, 0xaa, 0x01, 0x23, 0x00, 0xf0, 0x69, 0xfd, 0x00, 0x28, + 0x04, 0xd1, 0x0c, 0x4b, 0x68, 0x60, 0x2b, 0x60, 0x68, 0x72, 0x10, 0xe0, + 0x01, 0x9b, 0x30, 0x1c, 0xe4, 0x18, 0x00, 0xf0, 0xad, 0xfc, 0x33, 0x1c, + 0x3e, 0x1c, 0x1f, 0x1c, 0xca, 0xe7, 0x02, 0x99, 0x03, 0x9a, 0x64, 0x1a, + 0x14, 0x60, 0x28, 0x1c, 0x31, 0x1c, 0xff, 0xf7, 0x95, 0xff, 0x28, 0x1c, + 0x1d, 0xb0, 0xf0, 0xbd, 0x28, 0x4f, 0x00, 0x00, 0xf0, 0xb5, 0xa1, 0xb0, + 0x05, 0x1c, 0x1f, 0x1c, 0x02, 0xa8, 0x01, 0xab, 0x16, 0x1c, 0xff, 0xf7, + 0xa1, 0xff, 0x01, 0x9b, 0xf6, 0x18, 0x33, 0x78, 0x00, 0x2b, 0x07, 0xd1, + 0x02, 0xa9, 0x16, 0xa8, 0xff, 0xf7, 0x7e, 0xff, 0x28, 0x1c, 0x16, 0xa9, + 0x17, 0x4a, 0x28, 0xe0, 0x00, 0x23, 0x0c, 0xac, 0x63, 0x60, 0x63, 0x72, + 0x6b, 0x46, 0x11, 0x33, 0x14, 0x4a, 0x1b, 0x78, 0x0c, 0x92, 0x00, 0x2b, + 0x03, 0xd1, 0x28, 0x1c, 0xff, 0xf7, 0x4a, 0xfe, 0x1b, 0xe0, 0x20, 0x1c, + 0x02, 0xa9, 0x32, 0x1c, 0x3b, 0x1c, 0x00, 0xf0, 0x21, 0xfd, 0x00, 0x28, + 0xf3, 0xd0, 0x02, 0xa8, 0x00, 0xf0, 0x6c, 0xfc, 0x06, 0x23, 0x1f, 0x40, + 0x9f, 0x42, 0x03, 0xd1, 0x20, 0x1c, 0x13, 0x99, 0x00, 0xf0, 0xf6, 0xfb, + 0x21, 0x1c, 0x16, 0xa8, 0xff, 0xf7, 0x54, 0xff, 0x28, 0x1c, 0x16, 0xa9, + 0x32, 0x1c, 0xff, 0xf7, 0x0b, 0xfe, 0x28, 0x1c, 0x21, 0xb0, 0xf0, 0xbd, + 0x08, 0x4f, 0x00, 0x00, 0x28, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x1c, + 0x08, 0x1c, 0x19, 0x1c, 0x38, 0x31, 0x02, 0x4a, 0x00, 0x23, 0xff, 0xf7, + 0xc9, 0xfe, 0x08, 0xbd, 0xa5, 0x23, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x1c, + 0x08, 0x1c, 0x19, 0x1c, 0x38, 0x31, 0x02, 0x4a, 0x00, 0x23, 0xff, 0xf7, + 0xbd, 0xfe, 0x08, 0xbd, 0xe1, 0x23, 0x00, 0x00, 0x08, 0x4b, 0x02, 0x21, + 0x19, 0x61, 0x19, 0x1c, 0x00, 0x22, 0x30, 0x31, 0x0a, 0x70, 0x06, 0x49, + 0x5a, 0x71, 0x9a, 0x71, 0x9a, 0x72, 0x1a, 0x73, 0xda, 0x63, 0x99, 0x63, + 0x41, 0x33, 0x1a, 0x70, 0x70, 0x47, 0xc0, 0x46, 0xd4, 0x00, 0x00, 0x20, + 0x28, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x01, 0x1c, 0x01, 0x48, 0x01, 0xf0, + 0xab, 0xf9, 0x08, 0xbd, 0x78, 0x07, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, + 0xff, 0x21, 0x01, 0xf0, 0xa3, 0xf9, 0x08, 0xbd, 0x78, 0x07, 0x00, 0x20, + 0x08, 0xb5, 0x01, 0x21, 0x00, 0x79, 0x01, 0xf0, 0x3f, 0xfc, 0x05, 0x4b, + 0x1a, 0x78, 0x00, 0x2a, 0x04, 0xd0, 0x00, 0x22, 0x03, 0x48, 0x1a, 0x70, + 0x01, 0xf0, 0x80, 0xf9, 0x08, 0xbd, 0xc0, 0x46, 0x40, 0x01, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x10, 0xb5, 0x08, 0x4b, 0x04, 0x1c, 0x1a, 0x78, + 0x00, 0x2a, 0x06, 0xd1, 0x01, 0x22, 0x1a, 0x70, 0x05, 0x4b, 0x06, 0x48, + 0x06, 0xcb, 0x01, 0xf0, 0x51, 0xf9, 0x20, 0x79, 0x00, 0x21, 0x01, 0xf0, + 0x1f, 0xfc, 0x10, 0xbd, 0x40, 0x01, 0x00, 0x20, 0x38, 0x01, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x10, 0xb5, 0x83, 0x79, 0x04, 0x1c, 0x00, 0x2b, + 0x0d, 0xd0, 0x23, 0x89, 0x5a, 0x1c, 0x22, 0x81, 0x05, 0x4a, 0x93, 0x42, + 0x02, 0xd8, 0xff, 0xf7, 0xbf, 0xff, 0xf6, 0xe7, 0x20, 0x1c, 0xff, 0xf7, + 0xc3, 0xff, 0x00, 0x23, 0xa3, 0x71, 0x10, 0xbd, 0x01, 0x02, 0x00, 0x00, + 0x00, 0xb5, 0x06, 0x29, 0x03, 0xd9, 0x16, 0x23, 0x43, 0x71, 0x00, 0x20, + 0x1c, 0xe0, 0x0f, 0x4b, 0x05, 0x29, 0x13, 0xd8, 0x08, 0x1c, 0x00, 0x22, + 0x02, 0xf0, 0xd4, 0xf9, 0x03, 0x05, 0x07, 0x09, 0x0b, 0x0d, 0x0b, 0x49, + 0x08, 0xe0, 0x0b, 0x49, 0x06, 0xe0, 0x0b, 0x49, 0x04, 0xe0, 0x0b, 0x49, + 0x02, 0xe0, 0x0b, 0x49, 0x00, 0xe0, 0x0b, 0x49, 0x19, 0x60, 0x02, 0xe0, + 0x0a, 0x4a, 0x1a, 0x60, 0x00, 0x22, 0x1a, 0x71, 0x5a, 0x71, 0x01, 0x20, + 0x00, 0xbd, 0xc0, 0x46, 0x38, 0x01, 0x00, 0x20, 0x00, 0x1b, 0xb7, 0x00, + 0x00, 0x09, 0x3d, 0x00, 0x80, 0x84, 0x1e, 0x00, 0x40, 0x42, 0x0f, 0x00, + 0x20, 0xa1, 0x07, 0x00, 0x90, 0xd0, 0x03, 0x00, 0x48, 0xe8, 0x01, 0x00, + 0x38, 0xb5, 0x0c, 0x1c, 0x01, 0xf0, 0xf0, 0xf9, 0x05, 0x1c, 0xff, 0xf7, + 0x79, 0xff, 0xff, 0x28, 0x06, 0xd0, 0x01, 0xf0, 0xe9, 0xf9, 0x40, 0x1b, + 0xa0, 0x42, 0xf6, 0xd3, 0x00, 0x20, 0x00, 0xe0, 0x01, 0x20, 0x38, 0xbd, + 0xf8, 0xb5, 0x04, 0x1c, 0x0e, 0x1c, 0x17, 0x1c, 0xff, 0xf7, 0x9c, 0xff, + 0x20, 0x1c, 0xff, 0xf7, 0x81, 0xff, 0x96, 0x21, 0x49, 0x00, 0x20, 0x1c, + 0xff, 0xf7, 0xe0, 0xff, 0x40, 0x20, 0x30, 0x43, 0xff, 0xf7, 0x54, 0xff, + 0x18, 0x25, 0x38, 0x1c, 0xe8, 0x40, 0xc0, 0xb2, 0x08, 0x3d, 0xff, 0xf7, + 0x4d, 0xff, 0x2b, 0x1c, 0x08, 0x33, 0xf6, 0xd1, 0x95, 0x20, 0x00, 0x2e, + 0x03, 0xd0, 0x87, 0x20, 0x08, 0x2e, 0x00, 0xd0, 0xff, 0x20, 0xff, 0xf7, + 0x41, 0xff, 0x00, 0x25, 0xff, 0xf7, 0x46, 0xff, 0x43, 0xb2, 0xe0, 0x72, + 0x00, 0x2b, 0x04, 0xda, 0xff, 0x2d, 0x02, 0xd0, 0x01, 0x35, 0xed, 0xb2, + 0xf4, 0xe7, 0xf8, 0xbd, 0xf7, 0xb5, 0x00, 0x25, 0x02, 0x71, 0x05, 0x73, + 0x85, 0x72, 0x85, 0x71, 0x45, 0x71, 0x04, 0x1c, 0x01, 0x91, 0x01, 0xf0, + 0xa5, 0xf9, 0x01, 0x21, 0x07, 0x1c, 0x20, 0x79, 0x01, 0xf0, 0x1e, 0xfb, + 0x01, 0x21, 0x20, 0x79, 0x01, 0xf0, 0x74, 0xfb, 0x42, 0x4e, 0x30, 0x1c, + 0x01, 0xf0, 0x76, 0xf8, 0x41, 0x4b, 0x42, 0x49, 0x1d, 0x71, 0x5d, 0x71, + 0x19, 0x60, 0x30, 0x1c, 0x5a, 0x68, 0x01, 0xf0, 0x95, 0xf8, 0x0a, 0x25, + 0x01, 0x3d, 0xff, 0x20, 0xed, 0xb2, 0xff, 0xf7, 0x0d, 0xff, 0x00, 0x2d, + 0xf8, 0xd1, 0x30, 0x1c, 0x01, 0xf0, 0xa6, 0xf8, 0x20, 0x1c, 0xff, 0xf7, + 0x29, 0xff, 0x00, 0x21, 0x20, 0x1c, 0x0a, 0x1c, 0xff, 0xf7, 0x9a, 0xff, + 0x06, 0x1c, 0xe0, 0x72, 0x01, 0x28, 0x08, 0xd0, 0x01, 0xf0, 0x76, 0xf9, + 0xfa, 0x23, 0xc0, 0x1b, 0xdb, 0x00, 0x98, 0x42, 0xef, 0xd9, 0x01, 0x23, + 0x3b, 0xe0, 0xd5, 0x22, 0x20, 0x1c, 0x08, 0x21, 0x52, 0x00, 0xff, 0xf7, + 0x87, 0xff, 0x04, 0x23, 0x18, 0x42, 0x01, 0xd0, 0x26, 0x73, 0x0b, 0xe0, + 0x1e, 0x1c, 0xff, 0xf7, 0xed, 0xfe, 0x01, 0x3e, 0xf6, 0xb2, 0xe0, 0x72, + 0x00, 0x2e, 0xf8, 0xd1, 0x02, 0x23, 0xaa, 0x28, 0x25, 0xd1, 0x23, 0x73, + 0x26, 0x7b, 0x02, 0x3e, 0x73, 0x42, 0x5e, 0x41, 0xb6, 0x07, 0x37, 0x21, + 0x00, 0x22, 0x20, 0x1c, 0xff, 0xf7, 0x6c, 0xff, 0x32, 0x1c, 0x20, 0x1c, + 0x29, 0x21, 0xff, 0xf7, 0x67, 0xff, 0x02, 0x1c, 0xe0, 0x72, 0x08, 0xd0, + 0x01, 0xf0, 0x44, 0xf9, 0xfa, 0x23, 0xc0, 0x1b, 0xdb, 0x00, 0x98, 0x42, + 0xeb, 0xd9, 0x08, 0x23, 0x09, 0xe0, 0x23, 0x7b, 0x02, 0x2b, 0x19, 0xd1, + 0x20, 0x1c, 0x3a, 0x21, 0xff, 0xf7, 0x54, 0xff, 0x00, 0x28, 0x05, 0xd0, + 0x06, 0x23, 0x63, 0x71, 0x20, 0x1c, 0xff, 0xf7, 0xc3, 0xfe, 0x15, 0xe0, + 0xff, 0xf7, 0xb8, 0xfe, 0xc0, 0x23, 0x18, 0x40, 0x98, 0x42, 0x01, 0xd1, + 0x03, 0x23, 0x23, 0x73, 0xff, 0xf7, 0xb0, 0xfe, 0xff, 0xf7, 0xae, 0xfe, + 0xff, 0xf7, 0xac, 0xfe, 0x20, 0x1c, 0xff, 0xf7, 0xb1, 0xfe, 0x20, 0x1c, + 0x01, 0x99, 0xff, 0xf7, 0xef, 0xfe, 0x05, 0x1c, 0x28, 0x1c, 0xfe, 0xbd, + 0x78, 0x07, 0x00, 0x20, 0x38, 0x01, 0x00, 0x20, 0x90, 0xd0, 0x03, 0x00, + 0x38, 0xb5, 0x04, 0x1c, 0x01, 0xf0, 0x0c, 0xf9, 0x05, 0x1c, 0xff, 0xf7, + 0x95, 0xfe, 0xe0, 0x72, 0xff, 0x28, 0x08, 0xd1, 0x01, 0xf0, 0x04, 0xf9, + 0x96, 0x23, 0x40, 0x1b, 0x5b, 0x00, 0x98, 0x42, 0xf3, 0xd9, 0x0f, 0x23, + 0x02, 0xe0, 0xfe, 0x28, 0x06, 0xd0, 0x0d, 0x23, 0x20, 0x1c, 0x63, 0x71, + 0xff, 0xf7, 0x8a, 0xfe, 0x00, 0x20, 0x00, 0xe0, 0x01, 0x20, 0x38, 0xbd, + 0xf8, 0xb5, 0x04, 0x1c, 0x0f, 0x1c, 0x15, 0x1c, 0x1e, 0x1e, 0x45, 0xd0, + 0x9a, 0x18, 0x80, 0x23, 0x9b, 0x00, 0x9a, 0x42, 0x42, 0xdc, 0x83, 0x79, + 0x00, 0x2b, 0x05, 0xd0, 0x02, 0x68, 0x91, 0x42, 0x02, 0xd1, 0x03, 0x89, + 0xab, 0x42, 0x16, 0xd9, 0x23, 0x7b, 0x27, 0x60, 0x03, 0x2b, 0x00, 0xd0, + 0x7f, 0x02, 0x3a, 0x1c, 0x20, 0x1c, 0x11, 0x21, 0xff, 0xf7, 0xf2, 0xfe, + 0x07, 0x1e, 0x02, 0xd0, 0x03, 0x23, 0x63, 0x71, 0x2a, 0xe0, 0x20, 0x1c, + 0xff, 0xf7, 0xbc, 0xff, 0x00, 0x28, 0x25, 0xd0, 0x01, 0x23, 0x27, 0x81, + 0xa3, 0x71, 0x23, 0x89, 0xab, 0x42, 0x05, 0xd2, 0xff, 0xf7, 0x4e, 0xfe, + 0x23, 0x89, 0x01, 0x33, 0x23, 0x81, 0xf6, 0xe7, 0x06, 0x9d, 0x06, 0x9a, + 0xab, 0x1a, 0x9b, 0xb2, 0xb3, 0x42, 0x04, 0xd2, 0xff, 0xf7, 0x42, 0xfe, + 0x28, 0x70, 0x01, 0x35, 0xf5, 0xe7, 0x23, 0x89, 0xa2, 0x7a, 0xf3, 0x18, + 0x9b, 0xb2, 0x23, 0x81, 0x00, 0x2a, 0x02, 0xd0, 0x06, 0x4a, 0x93, 0x42, + 0x02, 0xd9, 0x20, 0x1c, 0xff, 0xf7, 0x66, 0xfe, 0x01, 0x20, 0x03, 0xe0, + 0x20, 0x1c, 0xff, 0xf7, 0x35, 0xfe, 0x00, 0x20, 0xf8, 0xbd, 0xc0, 0x46, + 0xff, 0x01, 0x00, 0x00, 0x07, 0xb5, 0x80, 0x23, 0x00, 0x92, 0x9b, 0x00, + 0x00, 0x22, 0xff, 0xf7, 0xa3, 0xff, 0x0e, 0xbd, 0x70, 0xb5, 0x05, 0x1c, + 0x08, 0x1c, 0x16, 0x1c, 0xff, 0xf7, 0x12, 0xfe, 0x00, 0x24, 0x30, 0x5d, + 0xff, 0xf7, 0x0e, 0xfe, 0x01, 0x34, 0x80, 0x23, 0x9b, 0x00, 0x9c, 0x42, + 0xf7, 0xd1, 0xff, 0x20, 0xff, 0xf7, 0x06, 0xfe, 0xff, 0x20, 0xff, 0xf7, + 0x03, 0xfe, 0xff, 0xf7, 0x09, 0xfe, 0x1f, 0x23, 0xe8, 0x72, 0x03, 0x40, + 0x01, 0x20, 0x05, 0x2b, 0x05, 0xd0, 0x11, 0x23, 0x28, 0x1c, 0x6b, 0x71, + 0xff, 0xf7, 0x06, 0xfe, 0x00, 0x20, 0x70, 0xbd, 0x70, 0xb5, 0x0b, 0x1c, + 0x04, 0x1c, 0x16, 0x1c, 0x00, 0x29, 0x01, 0xd1, 0x12, 0x23, 0x28, 0xe0, + 0x02, 0x7b, 0x03, 0x2a, 0x00, 0xd0, 0x4b, 0x02, 0x20, 0x1c, 0x18, 0x21, + 0x1a, 0x1c, 0xff, 0xf7, 0x7d, 0xfe, 0x05, 0x1e, 0x01, 0xd0, 0x04, 0x23, + 0x1b, 0xe0, 0x20, 0x1c, 0xfe, 0x21, 0x32, 0x1c, 0xff, 0xf7, 0xc2, 0xff, + 0x00, 0x28, 0x15, 0xd0, 0x96, 0x21, 0x20, 0x1c, 0x89, 0x00, 0xff, 0xf7, + 0x5b, 0xfe, 0x00, 0x28, 0x01, 0xd1, 0x15, 0x23, 0x0b, 0xe0, 0x20, 0x1c, + 0x0d, 0x21, 0x2a, 0x1c, 0xff, 0xf7, 0x64, 0xfe, 0x00, 0x28, 0x03, 0xd1, + 0xff, 0xf7, 0xce, 0xfd, 0x00, 0x28, 0x06, 0xd0, 0x14, 0x23, 0x63, 0x71, + 0x20, 0x1c, 0xff, 0xf7, 0xcf, 0xfd, 0x00, 0x20, 0x03, 0xe0, 0x20, 0x1c, + 0xff, 0xf7, 0xca, 0xfd, 0x01, 0x20, 0x70, 0xbd, 0x03, 0x4b, 0x04, 0x4a, + 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x70, 0x47, 0xc0, 0x46, + 0x38, 0x01, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, 0x02, 0x1c, 0x10, 0xb5, + 0x0c, 0x32, 0x04, 0x1c, 0x01, 0x21, 0x40, 0x6a, 0x00, 0xf0, 0x24, 0xfd, + 0x00, 0x28, 0x0a, 0xd0, 0x23, 0x6a, 0x01, 0x20, 0x00, 0x2b, 0x06, 0xd1, + 0xe3, 0x68, 0x22, 0x7a, 0x23, 0x62, 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, + 0x23, 0x72, 0x10, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xe6, 0xff, + 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x1b, 0xe0, 0x63, 0x6a, 0xe6, 0x68, + 0x1a, 0x7c, 0x02, 0x3e, 0x96, 0x40, 0x5a, 0x69, 0x1d, 0x79, 0xb6, 0x18, + 0x00, 0x2d, 0x08, 0xd0, 0x70, 0x1e, 0x40, 0x19, 0x00, 0xf0, 0x4c, 0xfc, + 0x00, 0x28, 0xed, 0xd0, 0x01, 0x3d, 0xed, 0xb2, 0xf4, 0xe7, 0x63, 0x6a, + 0x01, 0x20, 0x1a, 0x7c, 0x80, 0x23, 0x9b, 0x00, 0x93, 0x40, 0xe2, 0x69, + 0xd3, 0x18, 0xe3, 0x61, 0x70, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, + 0x40, 0x69, 0x00, 0xf0, 0x13, 0xfc, 0x00, 0x28, 0x03, 0xd0, 0x20, 0x7e, + 0x01, 0x4b, 0x40, 0x01, 0xc0, 0x18, 0x10, 0xbd, 0x50, 0x01, 0x00, 0x20, + 0xf0, 0xb5, 0x00, 0x23, 0x87, 0xb0, 0x07, 0x1c, 0x0e, 0x1c, 0x20, 0x22, + 0xf2, 0x54, 0x01, 0x33, 0x0b, 0x2b, 0xfa, 0xd1, 0x07, 0x21, 0x00, 0x25, + 0x01, 0x91, 0x3c, 0x78, 0x00, 0x2c, 0x2a, 0xd0, 0x2e, 0x2c, 0x06, 0xd1, + 0x01, 0x9b, 0x0a, 0x2b, 0x2b, 0xd0, 0x0a, 0x21, 0x08, 0x25, 0x01, 0x91, + 0x1f, 0xe0, 0x02, 0xa8, 0x14, 0x49, 0x10, 0x22, 0x02, 0xf0, 0x1b, 0xf8, + 0x00, 0x23, 0x02, 0xa9, 0xca, 0x5c, 0x00, 0x2a, 0x03, 0xd0, 0x01, 0x33, + 0xa2, 0x42, 0xf8, 0xd1, 0x19, 0xe0, 0x01, 0x9b, 0x9d, 0x42, 0x16, 0xd8, + 0x23, 0x1c, 0x21, 0x3b, 0x5d, 0x2b, 0x12, 0xd8, 0x22, 0x1c, 0x6b, 0x1c, + 0x61, 0x3a, 0xdb, 0xb2, 0x75, 0x19, 0x19, 0x2a, 0x01, 0xd8, 0x20, 0x3c, + 0xe4, 0xb2, 0x2c, 0x70, 0x1d, 0x1c, 0x01, 0x37, 0xd1, 0xe7, 0x30, 0x78, + 0x20, 0x38, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x00, 0xe0, 0x00, 0x20, + 0x07, 0xb0, 0xf0, 0xbd, 0x0a, 0x4f, 0x00, 0x00, 0x38, 0xb5, 0x42, 0x7a, + 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x2a, 0x01, 0xd0, 0x00, 0x20, 0x1f, 0xe0, + 0x4b, 0x1c, 0xdb, 0x7f, 0x10, 0x2b, 0x06, 0xd1, 0x02, 0x23, 0x43, 0x72, + 0x02, 0x62, 0x4b, 0x8c, 0x5b, 0x01, 0xc3, 0x61, 0x0c, 0xe0, 0x20, 0x2b, + 0xf0, 0xd1, 0x03, 0x23, 0x43, 0x72, 0x49, 0x6a, 0x22, 0x1c, 0x01, 0x62, + 0x1c, 0x32, 0x28, 0x1c, 0x00, 0xf0, 0x18, 0xfc, 0x00, 0x28, 0xe5, 0xd0, + 0x00, 0x23, 0x01, 0x20, 0x65, 0x62, 0x20, 0x72, 0xe3, 0x60, 0x23, 0x61, + 0x63, 0x61, 0x23, 0x76, 0x38, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x43, 0x7a, + 0x85, 0xb0, 0x04, 0x1c, 0x0e, 0x1c, 0x03, 0x92, 0x00, 0x2b, 0x01, 0xd1, + 0x3a, 0x48, 0x11, 0xe0, 0x03, 0x7a, 0xd8, 0x07, 0xfa, 0xd5, 0xe2, 0x69, + 0x20, 0x69, 0x03, 0x99, 0x13, 0x1a, 0x99, 0x42, 0x01, 0xd9, 0x9b, 0xb2, + 0x03, 0x93, 0x03, 0x99, 0x02, 0x91, 0x02, 0x9b, 0x00, 0x2b, 0x04, 0xd1, + 0x03, 0x99, 0x88, 0xb2, 0x00, 0xb2, 0x05, 0xb0, 0xf0, 0xbd, 0x23, 0x69, + 0x61, 0x7a, 0xdf, 0x05, 0xff, 0x0d, 0x5a, 0x0a, 0x60, 0x6a, 0x02, 0x29, + 0x02, 0xd1, 0x41, 0x6a, 0x51, 0x18, 0x1b, 0xe0, 0x05, 0x79, 0x01, 0x3d, + 0x2a, 0x40, 0xd5, 0xb2, 0x00, 0x2f, 0x0d, 0xd1, 0x00, 0x2d, 0x0b, 0xd1, + 0x00, 0x2b, 0x02, 0xd1, 0x22, 0x6a, 0xe2, 0x60, 0x06, 0xe0, 0x22, 0x1c, + 0xe1, 0x68, 0x0c, 0x32, 0x00, 0xf0, 0xa0, 0xfb, 0x00, 0x28, 0xc9, 0xd0, + 0x63, 0x6a, 0xe1, 0x68, 0x1a, 0x7c, 0x02, 0x39, 0x5b, 0x69, 0x91, 0x40, + 0xc9, 0x18, 0x49, 0x19, 0x80, 0x22, 0x02, 0x9d, 0x92, 0x00, 0xd3, 0x1b, + 0x9d, 0x42, 0x00, 0xdd, 0x9d, 0xb2, 0x23, 0x7a, 0x58, 0x06, 0x01, 0xd4, + 0x95, 0x42, 0x18, 0xd1, 0x16, 0x4b, 0x1b, 0x68, 0x99, 0x42, 0x14, 0xd0, + 0x15, 0x4b, 0x3a, 0x1c, 0x18, 0x68, 0x00, 0x96, 0x2b, 0x1c, 0xff, 0xf7, + 0x1f, 0xfe, 0x00, 0x28, 0xa8, 0xd0, 0x76, 0x19, 0x01, 0xe0, 0xdf, 0x1b, + 0xf6, 0x19, 0x21, 0x69, 0x02, 0x9a, 0x4b, 0x19, 0x55, 0x1b, 0xad, 0xb2, + 0x23, 0x61, 0x02, 0x95, 0xab, 0xe7, 0x08, 0x1c, 0x00, 0x21, 0x00, 0xf0, + 0x2b, 0xfb, 0x00, 0x28, 0x96, 0xd0, 0x09, 0x4b, 0x32, 0x1c, 0xff, 0x18, + 0x79, 0x19, 0x3b, 0x1c, 0x8b, 0x42, 0xe8, 0xd0, 0x18, 0x78, 0x01, 0x33, + 0x10, 0x70, 0x01, 0x32, 0xf8, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x73, 0xb5, 0x43, 0x7a, 0x04, 0x1c, 0x01, 0x2b, 0x01, 0xd8, 0x00, 0x20, + 0x16, 0xe0, 0x03, 0x69, 0x6d, 0x46, 0x07, 0x35, 0xde, 0x05, 0x29, 0x1c, + 0x01, 0x22, 0x36, 0x0f, 0xff, 0xf7, 0x6a, 0xff, 0x01, 0x28, 0x01, 0xd1, + 0x2b, 0x78, 0x00, 0xe0, 0x05, 0x4b, 0x1b, 0xb2, 0x01, 0x33, 0xec, 0xd0, + 0x23, 0x69, 0x70, 0x01, 0x1f, 0x33, 0x23, 0x61, 0x02, 0x4b, 0xc0, 0x18, + 0x76, 0xbd, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0x50, 0x01, 0x00, 0x20, + 0x70, 0xb5, 0x04, 0x1c, 0x40, 0x7a, 0x0d, 0x1c, 0x00, 0x28, 0x2a, 0xd0, + 0xe2, 0x69, 0x91, 0x42, 0x01, 0xd9, 0x00, 0x20, 0x25, 0xe0, 0x02, 0x28, + 0x21, 0xd0, 0x00, 0x2d, 0x01, 0xd1, 0xe5, 0x60, 0x1d, 0xe0, 0x62, 0x6a, + 0x21, 0x69, 0x13, 0x7c, 0x68, 0x1e, 0x09, 0x33, 0x4a, 0x1e, 0xd8, 0x40, + 0xda, 0x40, 0x03, 0x1e, 0x93, 0x42, 0x01, 0xd3, 0x00, 0x29, 0x02, 0xd1, + 0x22, 0x6a, 0xe2, 0x60, 0x00, 0xe0, 0x83, 0x1a, 0x1e, 0x1c, 0x00, 0x2e, + 0x09, 0xd0, 0x22, 0x1c, 0x60, 0x6a, 0xe1, 0x68, 0x0c, 0x32, 0x00, 0xf0, + 0x07, 0xfb, 0x01, 0x3e, 0x00, 0x28, 0xf4, 0xd1, 0x01, 0xe0, 0x25, 0x61, + 0x01, 0x20, 0x70, 0xbd, 0x38, 0xb5, 0x05, 0x1c, 0x40, 0x7a, 0x00, 0x28, + 0x33, 0xd0, 0x2b, 0x7a, 0x7f, 0x2b, 0x2d, 0xd9, 0x28, 0x1c, 0x01, 0x21, + 0xff, 0xf7, 0x9a, 0xfe, 0x04, 0x1e, 0x2a, 0xd0, 0x6b, 0x7a, 0x01, 0x2b, + 0x07, 0xd8, 0x2b, 0x7f, 0x03, 0x77, 0x6b, 0x7f, 0x43, 0x77, 0xab, 0x7f, + 0x83, 0x77, 0xeb, 0x7f, 0xc3, 0x77, 0x2b, 0x6a, 0x9a, 0xb2, 0x1b, 0x0c, + 0x23, 0x75, 0x1b, 0x0a, 0x63, 0x75, 0x0d, 0x4b, 0xa2, 0x76, 0x1b, 0x68, + 0x12, 0x0a, 0xe2, 0x76, 0x00, 0x2b, 0x0b, 0xd0, 0x20, 0x1c, 0x21, 0x1c, + 0x18, 0x30, 0x16, 0x31, 0x98, 0x47, 0x63, 0x7e, 0x22, 0x7e, 0x1b, 0x02, + 0x13, 0x43, 0xa3, 0x74, 0x1b, 0x0a, 0xe3, 0x74, 0x2a, 0x7a, 0x7f, 0x23, + 0x13, 0x40, 0x2b, 0x72, 0x00, 0xf0, 0x5c, 0xfa, 0xff, 0xe7, 0x38, 0xbd, + 0x44, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xc0, 0xff, + 0x00, 0x28, 0x02, 0xd0, 0x00, 0x23, 0x63, 0x72, 0x01, 0x20, 0x10, 0xbd, + 0x73, 0xb5, 0x42, 0x7a, 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x20, 0x01, 0x2a, + 0x4b, 0xd1, 0x20, 0x7a, 0x02, 0x23, 0x18, 0x40, 0x47, 0xd0, 0xe3, 0x69, + 0x00, 0x20, 0x99, 0x42, 0x43, 0xd8, 0x10, 0x1c, 0x00, 0x2b, 0x40, 0xd0, + 0x20, 0x1c, 0x29, 0x1c, 0x26, 0x69, 0xff, 0xf7, 0x71, 0xff, 0x00, 0x28, + 0x25, 0xd0, 0x60, 0x6a, 0x00, 0x2d, 0x06, 0xd1, 0x21, 0x6a, 0x00, 0xf0, + 0x95, 0xfb, 0x00, 0x28, 0x1d, 0xd0, 0x25, 0x62, 0x1d, 0xe0, 0xe1, 0x68, + 0x01, 0xaa, 0x00, 0xf0, 0x93, 0xfa, 0x00, 0x28, 0x15, 0xd0, 0x60, 0x6a, + 0x01, 0x99, 0x43, 0x1c, 0xdb, 0x7f, 0x10, 0x2b, 0x01, 0xd1, 0x12, 0x4b, + 0x00, 0xe0, 0x12, 0x4b, 0x99, 0x42, 0x0c, 0xd2, 0x00, 0xf0, 0x7e, 0xfb, + 0x00, 0x28, 0x06, 0xd0, 0x60, 0x6a, 0xe1, 0x68, 0x0e, 0x4a, 0x00, 0xf0, + 0xcf, 0xfa, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x11, 0xe0, 0x22, 0x7a, + 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, 0xe5, 0x61, 0x23, 0x72, 0x20, 0x1c, + 0xff, 0xf7, 0x70, 0xff, 0x00, 0x28, 0xf2, 0xd0, 0x29, 0x1e, 0xb1, 0x42, + 0x00, 0xd9, 0x31, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x35, 0xff, 0x76, 0xbd, + 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, 0xff, 0xff, 0xff, 0x0f, + 0x38, 0xb5, 0x23, 0x4b, 0x15, 0x1c, 0x4a, 0x01, 0xd3, 0x18, 0x04, 0x1c, + 0xd8, 0x7a, 0x11, 0x22, 0x10, 0x42, 0x04, 0xd0, 0x42, 0x22, 0x15, 0x42, + 0x01, 0xd0, 0x00, 0x20, 0x36, 0xe0, 0x1d, 0x4a, 0x21, 0x76, 0x12, 0x68, + 0x62, 0x61, 0x5a, 0x7d, 0x18, 0x7d, 0xd9, 0x7e, 0x12, 0x02, 0x02, 0x43, + 0x98, 0x7e, 0x09, 0x02, 0x12, 0x04, 0x01, 0x43, 0x11, 0x43, 0x21, 0x62, + 0xd8, 0x7a, 0x18, 0x22, 0x02, 0x40, 0x0c, 0xd1, 0x5a, 0x7f, 0x19, 0x7f, + 0x12, 0x02, 0x0a, 0x43, 0x99, 0x7f, 0xdb, 0x7f, 0x09, 0x04, 0x0a, 0x43, + 0x1b, 0x06, 0x13, 0x43, 0xe3, 0x61, 0x01, 0x23, 0x09, 0xe0, 0x10, 0x2a, + 0xdb, 0xd1, 0x22, 0x1c, 0x60, 0x6a, 0x1c, 0x32, 0x00, 0xf0, 0x5a, 0xfa, + 0x00, 0x28, 0xd4, 0xd0, 0x04, 0x23, 0x63, 0x72, 0x0f, 0x23, 0x00, 0x21, + 0x2b, 0x40, 0x23, 0x72, 0xe1, 0x60, 0x21, 0x61, 0x01, 0x20, 0x6a, 0x06, + 0x02, 0xd5, 0x20, 0x1c, 0xff, 0xf7, 0x60, 0xff, 0x38, 0xbd, 0xc0, 0x46, + 0x50, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0xf0, 0xb5, 0x45, 0x7a, + 0x87, 0xb0, 0x04, 0x1c, 0x0e, 0x1c, 0x01, 0x93, 0x00, 0x2d, 0x00, 0xd0, + 0x86, 0xe0, 0x10, 0x1c, 0x03, 0xa9, 0xff, 0xf7, 0xbb, 0xfd, 0x00, 0x28, + 0x00, 0xd1, 0x80, 0xe0, 0x72, 0x6a, 0x2f, 0x1c, 0x62, 0x62, 0xf5, 0x60, + 0x35, 0x61, 0x33, 0x69, 0xf2, 0x69, 0x93, 0x42, 0x26, 0xd2, 0xdb, 0x05, + 0x1b, 0x0f, 0x30, 0x1c, 0x00, 0x93, 0xff, 0xf7, 0x9f, 0xfe, 0x01, 0x1e, + 0x6f, 0xd0, 0x03, 0x78, 0x00, 0x2b, 0x01, 0xd0, 0xe5, 0x2b, 0x0b, 0xd1, + 0x00, 0x2f, 0x04, 0xd1, 0x00, 0x9b, 0x23, 0x76, 0x34, 0x4b, 0x1b, 0x68, + 0x63, 0x61, 0x0b, 0x78, 0x01, 0x27, 0x00, 0x2b, 0xe3, 0xd1, 0x0d, 0xe0, + 0x03, 0xa8, 0x0b, 0x22, 0x01, 0xf0, 0xbc, 0xfd, 0x00, 0x28, 0xdc, 0xd1, + 0x01, 0x9a, 0x30, 0x23, 0x13, 0x40, 0x30, 0x2b, 0x53, 0xd0, 0x20, 0x1c, + 0x00, 0x99, 0x4b, 0xe0, 0x01, 0x9a, 0x12, 0x23, 0x13, 0x40, 0x12, 0x2b, + 0x4b, 0xd1, 0x00, 0x2f, 0x06, 0xd0, 0x20, 0x1c, 0x01, 0x21, 0xff, 0xf7, + 0x6f, 0xfd, 0x06, 0x1e, 0x0a, 0xd1, 0x42, 0xe0, 0x73, 0x7a, 0x02, 0x2b, + 0x3f, 0xd0, 0x30, 0x1c, 0xff, 0xf7, 0x40, 0xfd, 0x00, 0x28, 0x3a, 0xd0, + 0x1f, 0x4e, 0x27, 0x76, 0x00, 0x21, 0x20, 0x22, 0x30, 0x1c, 0x01, 0xf0, + 0xad, 0xfd, 0x30, 0x1c, 0x03, 0xa9, 0x0b, 0x22, 0x01, 0xf0, 0x9f, 0xfd, + 0x1a, 0x4b, 0x1b, 0x68, 0x00, 0x2b, 0x05, 0xd0, 0x30, 0x1c, 0x31, 0x1c, + 0x10, 0x30, 0x0e, 0x31, 0x98, 0x47, 0x06, 0xe0, 0x21, 0x22, 0x32, 0x74, + 0xb3, 0x73, 0x28, 0x22, 0x08, 0x23, 0x72, 0x74, 0xf3, 0x73, 0x73, 0x7c, + 0x32, 0x7c, 0x1b, 0x02, 0x13, 0x43, 0xff, 0x22, 0x1a, 0x40, 0x1b, 0x0a, + 0xf3, 0x74, 0x73, 0x76, 0xf3, 0x7b, 0xb2, 0x74, 0x32, 0x76, 0xb2, 0x7b, + 0x1b, 0x02, 0x13, 0x43, 0xb3, 0x75, 0x1b, 0x0a, 0xf3, 0x75, 0x00, 0xf0, + 0x21, 0xf9, 0x00, 0x28, 0x07, 0xd0, 0x21, 0x7e, 0x01, 0x9a, 0x20, 0x1c, + 0xff, 0xf7, 0x26, 0xff, 0x05, 0x1c, 0x00, 0xe0, 0x00, 0x25, 0x28, 0x1c, + 0x07, 0xb0, 0xf0, 0xbd, 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x44, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x00, 0x21, 0x04, 0x1c, 0xff, 0xf7, + 0xbb, 0xfe, 0x00, 0x28, 0x0b, 0xd0, 0x20, 0x1c, 0x01, 0x21, 0xff, 0xf7, + 0x15, 0xfd, 0x00, 0x28, 0x05, 0xd0, 0xe5, 0x23, 0x03, 0x70, 0x00, 0x23, + 0x63, 0x72, 0x00, 0xf0, 0xfb, 0xf8, 0x10, 0xbd, 0x10, 0xb5, 0x0a, 0x1c, + 0x0a, 0x49, 0x8a, 0xb0, 0x08, 0x31, 0x00, 0x23, 0x04, 0x1c, 0x00, 0x91, + 0x69, 0x46, 0x4b, 0x72, 0x01, 0x93, 0x68, 0x46, 0x21, 0x1c, 0x02, 0x23, + 0xff, 0xf7, 0x42, 0xff, 0x00, 0x28, 0x02, 0xd0, 0x68, 0x46, 0xff, 0xf7, + 0xd7, 0xff, 0x0a, 0xb0, 0x10, 0xbd, 0xc0, 0x46, 0x20, 0x4f, 0x00, 0x00, + 0xf0, 0xb5, 0x43, 0x7a, 0x87, 0xb0, 0x04, 0x1c, 0x0d, 0x1c, 0x03, 0x92, + 0x01, 0x2b, 0x0d, 0xd1, 0x03, 0x7a, 0x99, 0x07, 0x0a, 0xd5, 0x5a, 0x07, + 0x0c, 0xd5, 0xe1, 0x69, 0x22, 0x69, 0x8a, 0x42, 0x08, 0xd0, 0x20, 0x1c, + 0xff, 0xf7, 0x06, 0xfe, 0x00, 0x28, 0x03, 0xd1, 0x01, 0x23, 0x63, 0x60, + 0x00, 0x20, 0xaa, 0xe0, 0x03, 0x9b, 0x01, 0x93, 0x3b, 0xe0, 0x60, 0x6a, + 0x73, 0x0a, 0x07, 0x79, 0xf6, 0x05, 0x01, 0x3f, 0x1f, 0x40, 0xff, 0xb2, + 0xf6, 0x0d, 0x00, 0x2f, 0x36, 0xd0, 0x80, 0x22, 0x92, 0x00, 0x92, 0x1b, + 0x01, 0x99, 0x92, 0xb2, 0x0b, 0x1c, 0x91, 0x42, 0x00, 0xd9, 0x13, 0x1c, + 0x9b, 0xb2, 0x02, 0x93, 0x63, 0x6a, 0xe1, 0x68, 0x1a, 0x7c, 0x02, 0x39, + 0x91, 0x40, 0x5a, 0x69, 0x8b, 0x18, 0x02, 0x9a, 0xdf, 0x19, 0x80, 0x23, + 0x9b, 0x00, 0x9a, 0x42, 0x3f, 0xd1, 0x44, 0x4b, 0x19, 0x68, 0xb9, 0x42, + 0x02, 0xd1, 0x01, 0x22, 0x52, 0x42, 0x1a, 0x60, 0x41, 0x4b, 0x39, 0x1c, + 0x18, 0x68, 0x2a, 0x1c, 0xff, 0xf7, 0x22, 0xfc, 0x00, 0x28, 0xc7, 0xd0, + 0x80, 0x22, 0x92, 0x00, 0xad, 0x18, 0x01, 0x99, 0x02, 0x9a, 0x8b, 0x1a, + 0x21, 0x69, 0x9b, 0xb2, 0x01, 0x93, 0x8b, 0x18, 0x23, 0x61, 0x01, 0x9a, + 0x26, 0x69, 0x00, 0x2a, 0xbf, 0xd1, 0x49, 0xe0, 0x00, 0x2e, 0xc6, 0xd1, + 0xe1, 0x68, 0x00, 0x29, 0x03, 0xd1, 0x23, 0x6a, 0x00, 0x2b, 0x16, 0xd1, + 0x0f, 0xe0, 0x05, 0xaa, 0x00, 0xf0, 0xe2, 0xf8, 0x00, 0x28, 0x58, 0xd0, + 0x62, 0x6a, 0x05, 0x9b, 0x01, 0x32, 0xd2, 0x7f, 0x10, 0x2a, 0x01, 0xd1, + 0x2c, 0x4a, 0x00, 0xe0, 0x2c, 0x4a, 0x93, 0x42, 0x05, 0xd3, 0x20, 0x1c, + 0xff, 0xf7, 0x3c, 0xfc, 0x00, 0x28, 0xaa, 0xd1, 0x98, 0xe7, 0xe3, 0x60, + 0xa7, 0xe7, 0x00, 0x2e, 0x0f, 0xd1, 0x23, 0x69, 0xe1, 0x69, 0x8b, 0x42, + 0x0b, 0xd3, 0x00, 0xf0, 0x59, 0xf8, 0x00, 0x28, 0x8c, 0xd0, 0x1f, 0x4b, + 0x01, 0x21, 0x1f, 0x60, 0x21, 0x4b, 0x1a, 0x78, 0x0a, 0x43, 0x1a, 0x70, + 0x06, 0xe0, 0x38, 0x1c, 0x01, 0x21, 0x00, 0xf0, 0x75, 0xf8, 0x00, 0x28, + 0x00, 0xd1, 0x7d, 0xe7, 0x1c, 0x4b, 0x2a, 0x1c, 0xf6, 0x18, 0x02, 0x9b, + 0xf1, 0x18, 0x33, 0x1c, 0x8b, 0x42, 0x04, 0xd0, 0x10, 0x78, 0x01, 0x32, + 0x18, 0x70, 0x01, 0x33, 0xf8, 0xe7, 0x9e, 0x1b, 0xad, 0x19, 0xa8, 0xe7, + 0xe1, 0x69, 0x23, 0x7a, 0x8e, 0x42, 0x01, 0xd9, 0xe6, 0x61, 0x06, 0xe0, + 0x12, 0x4a, 0x12, 0x68, 0x00, 0x2a, 0x06, 0xd0, 0x03, 0x9a, 0x00, 0x2a, + 0x03, 0xd0, 0x80, 0x22, 0x52, 0x42, 0x13, 0x43, 0x23, 0x72, 0x23, 0x7a, + 0x19, 0x07, 0x01, 0xd4, 0x03, 0x98, 0x06, 0xe0, 0x20, 0x1c, 0xff, 0xf7, + 0x8b, 0xfd, 0x00, 0x28, 0x00, 0xd1, 0x51, 0xe7, 0xf6, 0xe7, 0x07, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, + 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, 0x50, 0x03, 0x00, 0x20, + 0x50, 0x01, 0x00, 0x20, 0x44, 0x01, 0x00, 0x20, 0x07, 0xb5, 0x6b, 0x46, + 0xd9, 0x71, 0x07, 0x33, 0x19, 0x1c, 0x01, 0x22, 0xff, 0xf7, 0x22, 0xff, + 0x0e, 0xbd, 0x00, 0x00, 0xf8, 0xb5, 0x0f, 0x4f, 0x01, 0x20, 0x3b, 0x78, + 0x00, 0x2b, 0x18, 0xd0, 0x0d, 0x4e, 0x0e, 0x4b, 0x0e, 0x4d, 0x19, 0x68, + 0x30, 0x68, 0x2a, 0x1c, 0xff, 0xf7, 0x80, 0xfb, 0x00, 0x28, 0x0e, 0xd0, + 0x0b, 0x4c, 0x21, 0x68, 0x00, 0x29, 0x07, 0xd0, 0x30, 0x68, 0x2a, 0x1c, + 0xff, 0xf7, 0x76, 0xfb, 0x00, 0x28, 0x04, 0xd0, 0x00, 0x23, 0x23, 0x60, + 0x00, 0x23, 0x3b, 0x70, 0x01, 0x20, 0xf8, 0xbd, 0x50, 0x03, 0x00, 0x20, + 0x4c, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x48, 0x01, 0x00, 0x20, 0x70, 0xb5, 0x0d, 0x4d, 0x04, 0x1c, 0x2b, 0x68, + 0x0e, 0x1c, 0x83, 0x42, 0x0e, 0xd0, 0xff, 0xf7, 0xcd, 0xff, 0x00, 0x28, + 0x01, 0xd1, 0x00, 0x20, 0x0d, 0xe0, 0x08, 0x4b, 0x21, 0x1c, 0x18, 0x68, + 0x07, 0x4a, 0xff, 0xf7, 0x25, 0xfb, 0x00, 0x28, 0xf5, 0xd0, 0x2c, 0x60, + 0x05, 0x4b, 0x01, 0x20, 0x1a, 0x78, 0x16, 0x43, 0x1e, 0x70, 0x70, 0xbd, + 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x50, 0x03, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xae, 0xff, + 0x00, 0x28, 0x0f, 0xd0, 0x00, 0x23, 0x08, 0x4a, 0x00, 0x21, 0x99, 0x54, + 0x80, 0x22, 0x01, 0x33, 0x92, 0x00, 0x93, 0x42, 0xf7, 0xd1, 0x05, 0x4b, + 0x01, 0x20, 0x1c, 0x60, 0x04, 0x4b, 0x1a, 0x78, 0x02, 0x43, 0x1a, 0x70, + 0x10, 0xbd, 0xc0, 0x46, 0x50, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, + 0x50, 0x03, 0x00, 0x20, 0xc3, 0x68, 0x70, 0xb5, 0x01, 0x33, 0x0c, 0x1c, + 0x15, 0x1c, 0x99, 0x42, 0x01, 0xd9, 0x00, 0x20, 0x21, 0xe0, 0x46, 0x1c, + 0xf1, 0x7f, 0xc2, 0x69, 0xe3, 0x09, 0x10, 0x29, 0x00, 0xd1, 0x23, 0x0a, + 0x98, 0x18, 0x0d, 0x4b, 0x1b, 0x68, 0x98, 0x42, 0x07, 0xd1, 0xf2, 0x7f, + 0x0b, 0x4b, 0x10, 0x2a, 0x09, 0xd1, 0xe4, 0xb2, 0x64, 0x00, 0x1b, 0x5b, + 0x0b, 0xe0, 0x00, 0x21, 0xff, 0xf7, 0x9e, 0xff, 0x00, 0x28, 0xf2, 0xd1, + 0xe3, 0xe7, 0x7f, 0x22, 0x14, 0x40, 0xa4, 0x00, 0x1b, 0x59, 0x1b, 0x01, + 0x1b, 0x09, 0x2b, 0x60, 0x01, 0x20, 0x70, 0xbd, 0x00, 0x00, 0x00, 0x20, + 0x50, 0x01, 0x00, 0x20, 0x73, 0xb5, 0x05, 0x1c, 0x01, 0x91, 0x16, 0x1c, + 0x00, 0x24, 0x28, 0x1c, 0x01, 0x99, 0x01, 0xaa, 0xff, 0xf7, 0xc6, 0xff, + 0x00, 0x28, 0x10, 0xd0, 0x2a, 0x7c, 0x80, 0x23, 0x9b, 0x00, 0x93, 0x40, + 0xe4, 0x18, 0x6b, 0x1c, 0xdb, 0x7f, 0x01, 0x9a, 0x10, 0x2b, 0x01, 0xd1, + 0x03, 0x4b, 0x00, 0xe0, 0x03, 0x4b, 0x9a, 0x42, 0xe9, 0xd3, 0x34, 0x60, + 0x01, 0x20, 0x76, 0xbd, 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, + 0xf7, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x01, 0x92, 0x01, 0x29, 0x32, 0xd9, + 0xc3, 0x68, 0x00, 0x20, 0x01, 0x33, 0x99, 0x42, 0x2e, 0xd8, 0x6f, 0x1c, + 0xfa, 0x7f, 0xee, 0x69, 0xcb, 0x09, 0x10, 0x2a, 0x00, 0xd1, 0x0b, 0x0a, + 0x9e, 0x19, 0x14, 0x4b, 0x1b, 0x68, 0x9e, 0x42, 0x08, 0xd1, 0xfa, 0x7f, + 0x12, 0x4b, 0x10, 0x2a, 0x0b, 0xd1, 0xe4, 0xb2, 0x01, 0x9a, 0x64, 0x00, + 0x1a, 0x53, 0x0b, 0xe0, 0x30, 0x1c, 0x00, 0x21, 0xff, 0xf7, 0x48, 0xff, + 0x00, 0x28, 0xf0, 0xd1, 0x12, 0xe0, 0x7f, 0x22, 0x14, 0x40, 0x01, 0x9a, + 0xa4, 0x00, 0x1a, 0x51, 0x09, 0x4b, 0x01, 0x20, 0x1a, 0x78, 0x02, 0x43, + 0x1a, 0x70, 0x2b, 0x7e, 0x83, 0x42, 0x05, 0xd9, 0xab, 0x68, 0xf6, 0x18, + 0x05, 0x4b, 0x1e, 0x60, 0x00, 0xe0, 0x00, 0x20, 0xfe, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, 0x50, 0x03, 0x00, 0x20, + 0x48, 0x01, 0x00, 0x20, 0xf0, 0xb5, 0x15, 0x68, 0x87, 0xb0, 0x06, 0x1c, + 0x02, 0x91, 0x17, 0x1c, 0x00, 0x2d, 0x03, 0xd0, 0x00, 0x21, 0x01, 0x35, + 0x01, 0x91, 0x06, 0xe0, 0x02, 0x9b, 0x05, 0x68, 0x01, 0x3b, 0x5a, 0x42, + 0x53, 0x41, 0xdb, 0xb2, 0x01, 0x93, 0xf2, 0x68, 0x00, 0x23, 0x01, 0x32, + 0x03, 0x92, 0x2c, 0x1c, 0x00, 0x93, 0x00, 0x99, 0xf2, 0x68, 0x91, 0x42, + 0x21, 0xd2, 0x03, 0x9b, 0x9c, 0x42, 0x01, 0xd9, 0x02, 0x24, 0x25, 0x1c, + 0x30, 0x1c, 0x21, 0x1c, 0x05, 0xaa, 0xff, 0xf7, 0x43, 0xff, 0x00, 0x28, + 0x15, 0xd0, 0x05, 0x99, 0x63, 0x1c, 0x00, 0x29, 0x01, 0xd0, 0x1d, 0x1c, + 0x03, 0xe0, 0x02, 0x99, 0x5a, 0x1b, 0x8a, 0x42, 0x04, 0xd0, 0x00, 0x9a, + 0x1c, 0x1c, 0x01, 0x32, 0x00, 0x92, 0xe0, 0xe7, 0x30, 0x1c, 0x21, 0x1c, + 0x13, 0x4a, 0xff, 0xf7, 0x7f, 0xff, 0x00, 0x28, 0x0b, 0xd1, 0x00, 0x20, + 0x1d, 0xe0, 0x63, 0x1e, 0x30, 0x1c, 0x19, 0x1c, 0x22, 0x1c, 0x00, 0x93, + 0xff, 0xf7, 0x74, 0xff, 0x00, 0x28, 0xf4, 0xd0, 0x00, 0x9c, 0xac, 0x42, + 0xf3, 0xd8, 0x39, 0x68, 0x00, 0x29, 0x06, 0xd1, 0x01, 0x99, 0x3d, 0x60, + 0x00, 0x29, 0x09, 0xd0, 0x01, 0x35, 0x35, 0x60, 0x06, 0xe0, 0x30, 0x1c, + 0x2a, 0x1c, 0xff, 0xf7, 0x61, 0xff, 0x00, 0x28, 0xf2, 0xd1, 0xe0, 0xe7, + 0x01, 0x20, 0x07, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0xff, 0xff, 0xff, 0x0f, + 0x02, 0x23, 0x37, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x03, 0x60, 0x28, 0x1c, + 0x21, 0x1c, 0x01, 0xaa, 0xff, 0xf7, 0xfc, 0xfe, 0x00, 0x28, 0x12, 0xd0, + 0x28, 0x1c, 0x21, 0x1c, 0x00, 0x22, 0xff, 0xf7, 0x47, 0xff, 0x00, 0x28, + 0x0b, 0xd0, 0x6b, 0x1c, 0xdb, 0x7f, 0x01, 0x9c, 0x10, 0x2b, 0x01, 0xd1, + 0x04, 0x4b, 0x00, 0xe0, 0x04, 0x4b, 0x9c, 0x42, 0xe7, 0xd3, 0x01, 0x20, + 0x00, 0xe0, 0x00, 0x20, 0x3e, 0xbd, 0xc0, 0x46, 0xf8, 0xff, 0x00, 0x00, + 0xf8, 0xff, 0xff, 0x0f, 0xf8, 0xb5, 0x44, 0x4b, 0x04, 0x1c, 0x15, 0x1c, + 0x19, 0x60, 0x29, 0xd0, 0x04, 0x2a, 0x01, 0xd9, 0x00, 0x20, 0x7d, 0xe0, + 0x00, 0x20, 0x01, 0x1c, 0xff, 0xf7, 0x90, 0xfe, 0x00, 0x28, 0xf7, 0xd0, + 0x2d, 0x01, 0x3d, 0x4b, 0xa9, 0x35, 0xff, 0x35, 0x5d, 0x19, 0xaa, 0x79, + 0xab, 0x1d, 0x50, 0x06, 0xee, 0xd1, 0xea, 0x7c, 0xa9, 0x7c, 0x12, 0x02, + 0x0a, 0x43, 0x29, 0x7d, 0x09, 0x04, 0x0a, 0x43, 0x69, 0x7d, 0x09, 0x06, + 0x0a, 0x43, 0x63, 0x2a, 0xe2, 0xd9, 0xaa, 0x7b, 0xed, 0x7b, 0x2d, 0x02, + 0x15, 0x43, 0x9a, 0x7a, 0xdb, 0x7a, 0x12, 0x04, 0x15, 0x43, 0x1b, 0x06, + 0x1d, 0x43, 0xd7, 0xd0, 0x28, 0x1c, 0x00, 0x21, 0xff, 0xf7, 0x6a, 0xfe, + 0x00, 0x28, 0xd1, 0xd0, 0x2a, 0x4b, 0x19, 0x7b, 0xda, 0x7a, 0x09, 0x02, + 0x11, 0x43, 0x80, 0x22, 0x92, 0x00, 0x91, 0x42, 0xc8, 0xd1, 0x1a, 0x7c, + 0x00, 0x2a, 0xc5, 0xd0, 0xd9, 0x89, 0x00, 0x29, 0xc2, 0xd0, 0x59, 0x7b, + 0x00, 0x29, 0xbf, 0xd0, 0x22, 0x76, 0x00, 0x22, 0x21, 0x71, 0x22, 0x74, + 0x22, 0x7c, 0x01, 0x20, 0x90, 0x40, 0x81, 0x42, 0x04, 0xd0, 0x50, 0x1c, + 0x20, 0x74, 0x07, 0x2a, 0xf6, 0xd9, 0xb1, 0xe7, 0xd9, 0x8a, 0x00, 0x29, + 0x00, 0xd1, 0x59, 0x6a, 0xa1, 0x60, 0xd8, 0x89, 0x28, 0x18, 0xe0, 0x61, + 0x1f, 0x69, 0x3e, 0x02, 0x36, 0x0c, 0x66, 0x84, 0xb7, 0xb2, 0x1e, 0x7c, + 0x71, 0x43, 0x0e, 0x18, 0x13, 0x48, 0x79, 0x01, 0x09, 0x18, 0x49, 0x12, + 0x71, 0x18, 0x66, 0x62, 0x61, 0x61, 0x18, 0x7d, 0xde, 0x7c, 0x00, 0x02, + 0x30, 0x43, 0x00, 0xd1, 0x18, 0x6a, 0x6d, 0x1a, 0x28, 0x18, 0xd0, 0x40, + 0x02, 0x1c, 0xe0, 0x60, 0x0b, 0x48, 0x61, 0x1c, 0x82, 0x42, 0x01, 0xd8, + 0x0c, 0x23, 0x07, 0xe0, 0x09, 0x48, 0x82, 0x42, 0x01, 0xd8, 0x10, 0x23, + 0x02, 0xe0, 0xdb, 0x6a, 0x63, 0x62, 0x20, 0x23, 0xcb, 0x77, 0x01, 0x20, + 0xf8, 0xbd, 0xc0, 0x46, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0xff, 0x01, 0x00, 0x00, 0xf4, 0x0f, 0x00, 0x00, 0xf4, 0xff, 0x00, 0x00, + 0x08, 0xb5, 0x05, 0x49, 0x05, 0x4a, 0x06, 0x48, 0x00, 0xf0, 0x10, 0xf8, + 0x05, 0x4b, 0x06, 0x49, 0x00, 0x22, 0x1a, 0x70, 0x5a, 0x54, 0x08, 0xbd, + 0x00, 0x50, 0x00, 0x00, 0x01, 0x04, 0x00, 0x00, 0x54, 0x03, 0x00, 0x20, + 0x6c, 0x03, 0x00, 0x20, 0x02, 0x04, 0x00, 0x00, 0x30, 0xb5, 0x09, 0x4c, + 0x09, 0x4b, 0xa5, 0x68, 0x6d, 0x03, 0x6d, 0x0f, 0xad, 0x00, 0xeb, 0x58, + 0x03, 0x60, 0xa4, 0x68, 0x01, 0x61, 0xa4, 0xb2, 0x44, 0x60, 0x5c, 0x43, + 0x9b, 0x00, 0x84, 0x60, 0xc3, 0x60, 0x42, 0x61, 0x30, 0xbd, 0xc0, 0x46, + 0x00, 0x40, 0x00, 0x41, 0x00, 0x55, 0x00, 0x00, 0xf7, 0xb5, 0x1f, 0x4e, + 0x80, 0x27, 0x75, 0x68, 0x03, 0x33, 0x3d, 0x43, 0x9b, 0x08, 0x75, 0x60, + 0x00, 0x2b, 0x34, 0xd0, 0x1b, 0x4d, 0x35, 0x80, 0x35, 0x7d, 0xef, 0x07, + 0xfc, 0xd5, 0x1d, 0x1c, 0x5f, 0x1b, 0x01, 0x97, 0x07, 0x68, 0xbf, 0x08, + 0xbc, 0x46, 0x01, 0x9f, 0x67, 0x45, 0x1f, 0xd2, 0x00, 0x2d, 0x1d, 0xd0, + 0x17, 0x78, 0x01, 0x3d, 0x01, 0x97, 0xff, 0x27, 0xbc, 0x43, 0x01, 0x9f, + 0x3c, 0x43, 0x57, 0x78, 0x3f, 0x02, 0x01, 0x97, 0x0f, 0x4f, 0x3c, 0x40, + 0x01, 0x9f, 0x3c, 0x43, 0x97, 0x78, 0x3f, 0x04, 0xbc, 0x46, 0x0d, 0x4f, + 0x3c, 0x40, 0xd7, 0x78, 0xa4, 0xb2, 0x3f, 0x06, 0x00, 0x97, 0x67, 0x46, + 0x3c, 0x43, 0x00, 0x9f, 0x04, 0x32, 0x3c, 0x43, 0x10, 0xc1, 0xd7, 0xe7, + 0x07, 0x4b, 0x33, 0x80, 0x33, 0x7d, 0xdf, 0x07, 0xfc, 0xd5, 0x2b, 0x1c, + 0xc8, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x44, 0xa5, 0xff, 0xff, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, 0x04, 0xa5, 0xff, 0xff, + 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, 0x1a, 0x80, 0x1a, 0x7d, + 0xd1, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x16, 0x1c, + 0xeb, 0x68, 0x28, 0x1c, 0x21, 0x1c, 0x9e, 0x42, 0x05, 0xd9, 0xff, 0xf7, + 0xe7, 0xff, 0xeb, 0x68, 0xe4, 0x18, 0xf6, 0x1a, 0xf4, 0xe7, 0xff, 0xf7, + 0xe1, 0xff, 0x70, 0xbd, 0x43, 0x7a, 0x00, 0x2b, 0x04, 0xd1, 0x83, 0x72, + 0xc3, 0x72, 0xc3, 0x60, 0x01, 0x23, 0x43, 0x72, 0x70, 0x47, 0x30, 0xb5, + 0x85, 0xb0, 0x04, 0x1c, 0x02, 0xad, 0x00, 0x68, 0x02, 0x91, 0x03, 0x92, + 0x00, 0xf0, 0x9c, 0xfc, 0x6b, 0x79, 0xe1, 0x79, 0x22, 0x7a, 0x00, 0x93, + 0x20, 0x68, 0x00, 0x23, 0x00, 0xf0, 0x36, 0xfd, 0x29, 0x79, 0x20, 0x68, + 0x02, 0x9a, 0x00, 0xf0, 0x5f, 0xfc, 0x20, 0x68, 0x00, 0xf0, 0x82, 0xfc, + 0x05, 0xb0, 0x30, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0x18, 0x26, 0xff, 0xf7, + 0xd7, 0xff, 0x20, 0x79, 0x33, 0x1c, 0x43, 0x43, 0x0d, 0x4d, 0x08, 0x21, + 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x1c, 0xfb, 0xa0, 0x79, 0x33, 0x1c, + 0x43, 0x43, 0x08, 0x21, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x14, 0xfb, + 0x60, 0x79, 0x08, 0x21, 0x46, 0x43, 0xad, 0x19, 0x69, 0x56, 0x00, 0xf0, + 0x0d, 0xfb, 0x04, 0x4b, 0x20, 0x1c, 0x06, 0xcb, 0xff, 0xf7, 0xc3, 0xff, + 0x70, 0xbd, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, 0x70, 0x07, 0x00, 0x20, + 0x07, 0xb5, 0x83, 0x7a, 0x00, 0x91, 0x01, 0x92, 0x00, 0x2b, 0x0d, 0xd0, + 0x9a, 0x07, 0x06, 0xd5, 0xef, 0xf3, 0x10, 0x83, 0x5a, 0x42, 0x53, 0x41, + 0xc3, 0x72, 0x72, 0xb6, 0x04, 0xe0, 0xda, 0x07, 0x02, 0xd5, 0x82, 0x89, + 0x03, 0x4b, 0x9a, 0x60, 0x00, 0x99, 0x01, 0x9a, 0xff, 0xf7, 0xa5, 0xff, + 0x07, 0xbd, 0xc0, 0x46, 0x00, 0x18, 0x00, 0x40, 0x83, 0x7a, 0x00, 0x2b, + 0x0b, 0xd0, 0x9a, 0x07, 0x04, 0xd5, 0xc3, 0x7a, 0x00, 0x2b, 0x06, 0xd0, + 0x62, 0xb6, 0x04, 0xe0, 0xda, 0x07, 0x02, 0xd5, 0x82, 0x89, 0x01, 0x4b, + 0xda, 0x60, 0x70, 0x47, 0x00, 0x18, 0x00, 0x40, 0x08, 0xb5, 0x00, 0x68, + 0x00, 0xf0, 0x39, 0xfc, 0x08, 0xbd, 0x00, 0x00, 0x0f, 0x4b, 0x10, 0x4a, + 0x10, 0x49, 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x0f, 0x4b, + 0x0f, 0x48, 0x19, 0x60, 0x0a, 0x21, 0x19, 0x71, 0x09, 0x21, 0x99, 0x71, + 0x08, 0x21, 0x59, 0x71, 0x03, 0x21, 0x5a, 0x72, 0xda, 0x71, 0x19, 0x72, + 0x0a, 0x4b, 0x18, 0x60, 0x26, 0x20, 0x18, 0x71, 0x25, 0x20, 0x98, 0x71, + 0x24, 0x20, 0x5a, 0x72, 0x58, 0x71, 0xda, 0x71, 0x19, 0x72, 0x70, 0x47, + 0x70, 0x07, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, 0x18, 0x09, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x1c, 0x09, 0x00, 0x20, 0x88, 0x07, 0x00, 0x20, + 0x08, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x7a, 0xfd, 0x08, 0xbd, 0xc0, 0x46, + 0x98, 0x07, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x72, 0xfd, + 0x08, 0xbd, 0xc0, 0x46, 0x54, 0x08, 0x00, 0x20, 0x73, 0xb5, 0x17, 0x49, + 0x17, 0x48, 0x00, 0xf0, 0x3d, 0xfb, 0x17, 0x49, 0x17, 0x48, 0x00, 0xf0, + 0x39, 0xfb, 0x17, 0x49, 0x17, 0x48, 0x00, 0xf0, 0x35, 0xfb, 0x17, 0x49, + 0x17, 0x48, 0x00, 0xf0, 0x31, 0xfb, 0x17, 0x4c, 0x17, 0x49, 0x20, 0x1c, + 0x00, 0xf0, 0x2c, 0xfb, 0x16, 0x4e, 0x17, 0x49, 0x30, 0x1c, 0x00, 0xf0, + 0x27, 0xfb, 0x03, 0x25, 0x01, 0x23, 0x31, 0x1c, 0x00, 0x95, 0x01, 0x93, + 0x0d, 0x22, 0x0e, 0x23, 0x12, 0x48, 0x00, 0xf0, 0x37, 0xfd, 0x00, 0x23, + 0x00, 0x95, 0x01, 0x93, 0x21, 0x1c, 0x1d, 0x22, 0x1a, 0x23, 0x0f, 0x48, + 0x00, 0xf0, 0x2e, 0xfd, 0x73, 0xbd, 0xc0, 0x46, 0x00, 0x08, 0x00, 0x42, + 0x14, 0x09, 0x00, 0x20, 0x00, 0x0c, 0x00, 0x42, 0x18, 0x09, 0x00, 0x20, + 0x00, 0x10, 0x00, 0x42, 0x1c, 0x09, 0x00, 0x20, 0x00, 0x14, 0x00, 0x42, + 0x10, 0x09, 0x00, 0x20, 0x20, 0x09, 0x00, 0x20, 0x00, 0x18, 0x00, 0x42, + 0x24, 0x09, 0x00, 0x20, 0x00, 0x1c, 0x00, 0x42, 0x98, 0x07, 0x00, 0x20, + 0x54, 0x08, 0x00, 0x20, 0xfe, 0xe7, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x4b, + 0x1b, 0x68, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, 0x08, 0xbd, 0xc0, 0x46, + 0x28, 0x09, 0x00, 0x20, 0x38, 0xb5, 0x0f, 0x49, 0x0f, 0x4c, 0xa1, 0x42, + 0x04, 0xd1, 0x00, 0xf0, 0x4f, 0xf8, 0xfe, 0xf7, 0xab, 0xfa, 0x0b, 0xe0, + 0x0c, 0x4d, 0x8d, 0x42, 0xf7, 0xd0, 0x00, 0x23, 0xca, 0x18, 0xe8, 0x18, + 0xa2, 0x42, 0x04, 0xd2, 0x00, 0x68, 0x04, 0x33, 0x10, 0x60, 0xf7, 0xe7, + 0xfe, 0xe7, 0x90, 0x42, 0xeb, 0xd0, 0x06, 0x4b, 0x06, 0x4a, 0x93, 0x42, + 0xe7, 0xd2, 0x00, 0x22, 0x04, 0xc3, 0xf9, 0xe7, 0x00, 0x00, 0x00, 0x20, + 0xa0, 0x00, 0x00, 0x20, 0x90, 0x59, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x20, + 0x0c, 0x0e, 0x00, 0x20, 0x08, 0xb5, 0x00, 0xf0, 0x26, 0xf8, 0x00, 0x28, + 0x01, 0xd1, 0x00, 0xf0, 0x17, 0xf8, 0x08, 0xbd, 0x01, 0x4b, 0x18, 0x68, + 0x70, 0x47, 0xc0, 0x46, 0x2c, 0x09, 0x00, 0x20, 0x70, 0xb5, 0x04, 0x1e, + 0x08, 0xd0, 0x05, 0x4b, 0x1d, 0x68, 0x1e, 0x1c, 0x00, 0xf0, 0x12, 0xf8, + 0x33, 0x68, 0x5b, 0x1b, 0xa3, 0x42, 0xf9, 0xd3, 0x70, 0xbd, 0xc0, 0x46, + 0x2c, 0x09, 0x00, 0x20, 0x08, 0xb5, 0x03, 0x4b, 0x1a, 0x68, 0x01, 0x32, + 0x1a, 0x60, 0x00, 0xf0, 0x61, 0xfa, 0x08, 0xbd, 0x2c, 0x09, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, 0x70, 0xb5, 0x49, 0x4a, + 0x1e, 0x21, 0x53, 0x68, 0x02, 0x20, 0x8b, 0x43, 0x03, 0x43, 0x47, 0x49, + 0x53, 0x60, 0x8b, 0x69, 0x08, 0x24, 0x23, 0x43, 0x8b, 0x61, 0x45, 0x4c, + 0x45, 0x4b, 0x9c, 0x82, 0x9c, 0x8a, 0x20, 0x43, 0x98, 0x82, 0x10, 0x1c, + 0xda, 0x68, 0x94, 0x07, 0xfc, 0xd5, 0x42, 0x4a, 0x01, 0x24, 0x14, 0x70, + 0x14, 0x78, 0xe5, 0x07, 0x04, 0xd5, 0x3f, 0x4c, 0x64, 0x78, 0x64, 0xb2, + 0x00, 0x2c, 0xf7, 0xdb, 0x01, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, + 0x00, 0x2c, 0xfb, 0xdb, 0x3a, 0x4d, 0x39, 0x4c, 0x65, 0x60, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x82, 0x25, 0x35, 0x4c, 0xed, 0x01, + 0x65, 0x80, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x02, 0x24, + 0x9c, 0x84, 0xdc, 0x68, 0xe6, 0x06, 0xfc, 0xd5, 0x31, 0x4d, 0x2e, 0x4c, + 0xe5, 0x62, 0xdd, 0x68, 0x2c, 0x4c, 0xee, 0x06, 0xfb, 0xd5, 0xa5, 0x8c, + 0x2e, 0x4e, 0x35, 0x43, 0xa5, 0x84, 0xdd, 0x68, 0x28, 0x4c, 0xee, 0x06, + 0xfb, 0xd5, 0xa5, 0x8c, 0x02, 0x26, 0x35, 0x43, 0xa5, 0x84, 0xdc, 0x68, + 0x25, 0x06, 0xfc, 0xd5, 0x23, 0x4c, 0xe4, 0x68, 0x66, 0x06, 0xf8, 0xd5, + 0xdc, 0x68, 0xe5, 0x06, 0xfc, 0xd5, 0x00, 0x24, 0x94, 0x60, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x22, 0x4d, 0x1d, 0x4c, 0x65, 0x60, + 0x55, 0x78, 0x1c, 0x4c, 0x6d, 0xb2, 0x00, 0x2d, 0xfa, 0xdb, 0x1e, 0x6a, + 0x1e, 0x4d, 0x35, 0x40, 0x1d, 0x62, 0x1d, 0x6a, 0x80, 0x26, 0xb5, 0x43, + 0x1d, 0x62, 0x03, 0x23, 0xa3, 0x60, 0x1b, 0x4b, 0x63, 0x60, 0x53, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x00, 0x23, 0x0b, 0x72, 0x18, 0x4a, + 0x4b, 0x72, 0x8b, 0x72, 0xcb, 0x72, 0x17, 0x4b, 0xff, 0x21, 0x1a, 0x60, + 0x16, 0x4b, 0x17, 0x4a, 0x1b, 0x68, 0x12, 0x68, 0x5c, 0x01, 0xd2, 0x0e, + 0x21, 0x40, 0x11, 0x43, 0x9a, 0x06, 0x52, 0x0f, 0x12, 0x02, 0x0b, 0x1c, + 0x13, 0x43, 0x12, 0x4a, 0x13, 0x85, 0x43, 0x68, 0x80, 0x22, 0x13, 0x43, + 0x43, 0x60, 0x70, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x00, 0x04, 0x00, 0x40, + 0x0c, 0x06, 0x00, 0x00, 0x00, 0x08, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, + 0x01, 0x05, 0x01, 0x00, 0xb9, 0x05, 0xff, 0x7d, 0x04, 0x0a, 0x00, 0x00, + 0x00, 0x07, 0x03, 0x00, 0xff, 0xfc, 0xff, 0xff, 0x03, 0x06, 0x01, 0x00, + 0x00, 0x6c, 0xdc, 0x02, 0x04, 0x00, 0x00, 0x20, 0x24, 0x60, 0x80, 0x00, + 0x20, 0x60, 0x80, 0x00, 0x00, 0x40, 0x00, 0x42, 0x31, 0x4b, 0xfa, 0x21, + 0x18, 0x68, 0x10, 0xb5, 0x89, 0x00, 0x00, 0xf0, 0xe3, 0xfe, 0x2f, 0x4b, + 0x01, 0x38, 0x98, 0x42, 0x24, 0xd8, 0x2e, 0x4a, 0x2e, 0x4b, 0x50, 0x60, + 0x18, 0x6a, 0xc0, 0x21, 0x00, 0x02, 0x00, 0x0a, 0x09, 0x06, 0x01, 0x43, + 0x19, 0x62, 0x00, 0x24, 0x07, 0x21, 0x94, 0x60, 0x11, 0x60, 0x19, 0x6a, + 0x80, 0x22, 0x09, 0x02, 0x09, 0x0a, 0x12, 0x06, 0x0a, 0x43, 0x1a, 0x62, + 0x25, 0x4b, 0xfc, 0x21, 0x1a, 0x6a, 0x0a, 0x43, 0x1a, 0x62, 0x19, 0x6a, + 0xfc, 0x22, 0x92, 0x01, 0x0a, 0x43, 0x1a, 0x62, 0x19, 0x6a, 0xa0, 0x22, + 0xd2, 0x02, 0x0a, 0x43, 0x1a, 0x62, 0x00, 0xe0, 0xfe, 0xe7, 0x20, 0x1c, + 0x00, 0x21, 0x01, 0x34, 0x00, 0xf0, 0x70, 0xf8, 0x0f, 0x2c, 0xf8, 0xd1, + 0x1a, 0x4c, 0x63, 0x78, 0x5b, 0xb2, 0x00, 0x2b, 0xfa, 0xdb, 0x19, 0x4b, + 0x63, 0x80, 0x19, 0x4b, 0x5a, 0x7e, 0xd2, 0x09, 0x01, 0x2a, 0xfa, 0xd0, + 0xe4, 0x22, 0xd2, 0x00, 0x9a, 0x80, 0x3f, 0x22, 0xda, 0x70, 0x59, 0x7e, + 0x13, 0x4a, 0xc9, 0x09, 0x01, 0x29, 0xfa, 0xd0, 0xc0, 0x23, 0x5b, 0x01, + 0x00, 0x20, 0x13, 0x61, 0x90, 0x70, 0x00, 0xf0, 0x23, 0xf8, 0x63, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x0d, 0x4a, 0x09, 0x4b, 0x5a, 0x80, + 0x0c, 0x4b, 0xda, 0x79, 0xd2, 0x09, 0x01, 0x2a, 0xfa, 0xd0, 0x41, 0x22, + 0x5a, 0x70, 0x10, 0xbd, 0x04, 0x00, 0x00, 0x20, 0xff, 0xff, 0xff, 0x00, + 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, 0x00, 0x04, 0x00, 0x40, + 0x00, 0x0c, 0x00, 0x40, 0x1e, 0x40, 0x00, 0x00, 0x00, 0x40, 0x00, 0x42, + 0x21, 0x40, 0x00, 0x00, 0x00, 0x48, 0x00, 0x42, 0x00, 0xb5, 0x14, 0x4a, + 0x51, 0x7e, 0x13, 0x1c, 0xc9, 0x09, 0x01, 0x29, 0xf9, 0xd0, 0x01, 0x38, + 0x04, 0x28, 0x13, 0xd8, 0x19, 0x69, 0x10, 0x4a, 0x0a, 0x40, 0x1a, 0x61, + 0x5a, 0x78, 0x0f, 0x21, 0x8a, 0x43, 0x00, 0xf0, 0x55, 0xfe, 0x03, 0x05, + 0x09, 0x07, 0x03, 0x00, 0x01, 0x21, 0x02, 0xe0, 0x03, 0x21, 0x00, 0xe0, + 0x02, 0x21, 0x0a, 0x43, 0x5a, 0x70, 0x0a, 0xe0, 0x11, 0x69, 0xf0, 0x23, + 0x1b, 0x05, 0x0b, 0x43, 0x13, 0x61, 0x53, 0x78, 0x0f, 0x21, 0x8b, 0x43, + 0x02, 0x21, 0x0b, 0x43, 0x53, 0x70, 0x00, 0xbd, 0x00, 0x40, 0x00, 0x42, + 0xff, 0xff, 0xff, 0xf0, 0x10, 0xb5, 0x18, 0x24, 0x02, 0x1c, 0x20, 0x1c, + 0x50, 0x43, 0x27, 0x4b, 0x18, 0x18, 0x00, 0x7a, 0x40, 0xb2, 0x01, 0x30, + 0x46, 0xd0, 0x03, 0x29, 0x44, 0xd8, 0x08, 0x1c, 0x21, 0x1c, 0x00, 0xf0, + 0x29, 0xfe, 0x02, 0x33, 0x11, 0x21, 0x62, 0x43, 0x98, 0x56, 0x9a, 0x18, + 0xc3, 0x01, 0x1f, 0x48, 0x52, 0x68, 0x1b, 0x18, 0x99, 0x18, 0x40, 0x31, + 0x02, 0x20, 0x08, 0x70, 0x01, 0x21, 0x91, 0x40, 0x59, 0x60, 0x2f, 0xe0, + 0x62, 0x43, 0x98, 0x56, 0x18, 0x49, 0x9a, 0x18, 0x52, 0x68, 0xc3, 0x01, + 0x5b, 0x18, 0x99, 0x18, 0x40, 0x31, 0x06, 0x20, 0x08, 0x70, 0x01, 0x21, + 0x91, 0x40, 0x59, 0x60, 0x99, 0x61, 0x1f, 0xe0, 0x51, 0x43, 0x5a, 0x56, + 0x10, 0x48, 0x59, 0x18, 0x4b, 0x68, 0xd2, 0x01, 0x11, 0x18, 0xc8, 0x18, + 0x40, 0x30, 0x06, 0x24, 0x04, 0x70, 0x01, 0x20, 0x98, 0x40, 0x48, 0x60, + 0x0b, 0x49, 0x52, 0x18, 0x50, 0x60, 0x0d, 0xe0, 0x62, 0x43, 0x98, 0x56, + 0x9a, 0x18, 0xc3, 0x01, 0x06, 0x48, 0x52, 0x68, 0x1b, 0x18, 0x99, 0x18, + 0x40, 0x31, 0x02, 0x20, 0x08, 0x70, 0x01, 0x21, 0x91, 0x40, 0x99, 0x60, + 0x10, 0xbd, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x10, 0x44, 0x00, 0x41, 0x18, 0x23, 0x58, 0x43, 0x13, 0x4a, 0xf0, 0xb5, + 0x13, 0x18, 0x08, 0x24, 0x1c, 0x57, 0x01, 0x34, 0x1f, 0xd0, 0x82, 0x56, + 0x10, 0x4e, 0xd2, 0x01, 0x5d, 0x68, 0x01, 0x24, 0x90, 0x19, 0x23, 0x1c, + 0x86, 0x68, 0xab, 0x40, 0x1e, 0x42, 0x0b, 0xd1, 0x0e, 0x1c, 0x77, 0x1e, + 0xbe, 0x41, 0x40, 0x19, 0x34, 0x40, 0x40, 0x30, 0xa5, 0x00, 0x04, 0x78, + 0x04, 0x26, 0xb4, 0x43, 0x2c, 0x43, 0x04, 0x70, 0x00, 0x29, 0x03, 0xd1, + 0x05, 0x49, 0x52, 0x18, 0x53, 0x60, 0x02, 0xe0, 0x02, 0x4e, 0x92, 0x19, + 0x93, 0x61, 0xf0, 0xbd, 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x10, 0x44, 0x00, 0x41, 0x18, 0x22, 0x42, 0x43, 0xf8, 0xb5, 0x2d, 0x4d, + 0x08, 0x24, 0xaa, 0x18, 0x14, 0x57, 0x03, 0x1c, 0x62, 0x1c, 0x50, 0xd0, + 0x48, 0x1c, 0x00, 0x24, 0x0c, 0x28, 0x4c, 0xd8, 0x00, 0xf0, 0xa0, 0xfd, + 0x07, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x0a, 0x0a, 0x0a, + 0x0a, 0x00, 0x01, 0x24, 0x64, 0x42, 0x40, 0xe0, 0x09, 0x29, 0x02, 0xd1, + 0x18, 0x1c, 0x00, 0x21, 0x03, 0xe0, 0x0a, 0x29, 0x04, 0xd1, 0x18, 0x1c, + 0x02, 0x21, 0xff, 0xf7, 0x51, 0xff, 0x23, 0xe0, 0x00, 0x24, 0x0b, 0x29, + 0x31, 0xd1, 0x18, 0x1c, 0x01, 0x21, 0xff, 0xf7, 0x49, 0xff, 0x2c, 0xe0, + 0x18, 0x22, 0x53, 0x43, 0xea, 0x18, 0x52, 0x68, 0xeb, 0x56, 0x01, 0x20, + 0x14, 0x1c, 0x04, 0x40, 0x55, 0x08, 0xdb, 0x01, 0x00, 0x2c, 0x11, 0xd0, + 0x12, 0x4c, 0x1b, 0x19, 0x5d, 0x19, 0x30, 0x35, 0x2e, 0x78, 0x0c, 0x01, + 0x0f, 0x21, 0x31, 0x40, 0x21, 0x43, 0x9a, 0x18, 0xc9, 0xb2, 0x29, 0x70, + 0x40, 0x32, 0x13, 0x78, 0x18, 0x43, 0x10, 0x70, 0x00, 0x24, 0x0e, 0xe0, + 0x09, 0x4e, 0x0f, 0x27, 0x9b, 0x19, 0x5d, 0x19, 0x30, 0x35, 0x2e, 0x78, + 0x9a, 0x18, 0xbe, 0x43, 0x31, 0x43, 0xc9, 0xb2, 0x29, 0x70, 0x40, 0x32, + 0x13, 0x78, 0x18, 0x43, 0x10, 0x70, 0x20, 0x1c, 0xf8, 0xbd, 0xc0, 0x46, + 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0xf7, 0xb5, 0x8a, 0x18, + 0x06, 0x1c, 0x0d, 0x1c, 0x01, 0x92, 0x0c, 0x1c, 0x01, 0x9b, 0x67, 0x1b, + 0x9c, 0x42, 0x07, 0xd0, 0x33, 0x68, 0x21, 0x78, 0x1b, 0x68, 0x30, 0x1c, + 0x98, 0x47, 0x01, 0x34, 0x00, 0x28, 0xf3, 0xd1, 0x38, 0x1c, 0xfe, 0xbd, + 0x15, 0x4a, 0x13, 0x68, 0x58, 0x1c, 0x25, 0xd0, 0x01, 0x3b, 0x13, 0x60, + 0x00, 0x2b, 0x21, 0xd1, 0x72, 0xb6, 0x12, 0x4a, 0x12, 0x4b, 0x04, 0x32, + 0x9a, 0x42, 0x07, 0xd8, 0xbf, 0xf3, 0x4f, 0x8f, 0x10, 0x4a, 0x11, 0x4b, + 0xda, 0x60, 0xbf, 0xf3, 0x4f, 0x8f, 0x11, 0xe0, 0x0f, 0x4b, 0x19, 0x7d, + 0xc8, 0x07, 0xfb, 0xd5, 0x18, 0x8b, 0x20, 0x21, 0xff, 0x31, 0x92, 0x08, + 0x52, 0x00, 0x01, 0x43, 0x19, 0x83, 0xda, 0x61, 0x0a, 0x4a, 0x1a, 0x80, + 0x1a, 0x7d, 0xd1, 0x07, 0xfc, 0xd5, 0xe5, 0xe7, 0xc0, 0x46, 0xfd, 0xe7, + 0x70, 0x47, 0xc0, 0x46, 0x08, 0x00, 0x00, 0x20, 0x00, 0x20, 0x00, 0x00, + 0x03, 0x02, 0x00, 0x00, 0x04, 0x00, 0xfa, 0x05, 0x00, 0xed, 0x00, 0xe0, + 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, 0x01, 0x60, 0x70, 0x47, + 0xf7, 0xb5, 0x08, 0xac, 0x26, 0x78, 0x04, 0x68, 0x9d, 0x1e, 0x27, 0x68, + 0x6c, 0x1e, 0xa5, 0x41, 0xec, 0xb2, 0x92, 0x07, 0x05, 0x68, 0x3a, 0x43, + 0x27, 0x06, 0x3a, 0x43, 0x2a, 0x60, 0x02, 0x68, 0x07, 0x25, 0x29, 0x40, + 0x50, 0x68, 0xb5, 0x01, 0x00, 0x2c, 0x00, 0xd0, 0x5c, 0x03, 0x29, 0x43, + 0x01, 0x43, 0x0c, 0x43, 0x54, 0x60, 0xf7, 0xbd, 0x30, 0xb5, 0x03, 0x68, + 0xc0, 0x25, 0x1c, 0x68, 0xad, 0x03, 0x12, 0x05, 0x2a, 0x40, 0x22, 0x43, + 0xc0, 0x24, 0xa4, 0x02, 0x09, 0x04, 0x21, 0x40, 0x11, 0x43, 0x19, 0x60, + 0x03, 0x68, 0x5a, 0x68, 0x14, 0x43, 0x5c, 0x60, 0x30, 0xbd, 0x03, 0x68, + 0x01, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, 0x11, 0x68, + 0x01, 0x23, 0x19, 0x42, 0xfb, 0xd1, 0xd1, 0x69, 0x19, 0x42, 0xf8, 0xd1, + 0x70, 0x47, 0x03, 0x68, 0x02, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, + 0x02, 0x68, 0xd3, 0x69, 0x99, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, + 0x1a, 0x7e, 0xd1, 0x07, 0x02, 0xd4, 0x1a, 0x7e, 0x91, 0x07, 0xfc, 0xd5, + 0x70, 0x47, 0x03, 0x68, 0x00, 0x22, 0x5a, 0x83, 0x70, 0x47, 0x03, 0x68, + 0x18, 0x7e, 0x40, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, + 0xc0, 0x09, 0x70, 0x47, 0x03, 0x68, 0x80, 0x22, 0x19, 0x7e, 0x52, 0x42, + 0x0a, 0x43, 0x1a, 0x76, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x01, 0x23, + 0x18, 0x40, 0x70, 0x47, 0x03, 0x68, 0x18, 0x8d, 0xc0, 0xb2, 0x70, 0x47, + 0x03, 0x68, 0x1a, 0x7e, 0x01, 0x20, 0x02, 0x42, 0xfb, 0xd0, 0x19, 0x85, + 0x70, 0x47, 0x03, 0x68, 0x01, 0x21, 0x9a, 0x7d, 0x0a, 0x43, 0x9a, 0x75, + 0x70, 0x47, 0x03, 0x68, 0x01, 0x22, 0x1a, 0x75, 0x70, 0x47, 0x00, 0x00, + 0x70, 0xb5, 0x03, 0x68, 0x01, 0x26, 0x8d, 0x07, 0xed, 0x0f, 0x31, 0x40, + 0x1c, 0x68, 0x6d, 0x07, 0x09, 0x07, 0x29, 0x43, 0x21, 0x43, 0x19, 0x60, + 0x04, 0x68, 0x51, 0x00, 0x03, 0x48, 0x00, 0xf0, 0x79, 0xfc, 0x01, 0x38, + 0xc0, 0xb2, 0x20, 0x73, 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x6c, 0xdc, 0x02, + 0x03, 0x68, 0x01, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, + 0x11, 0x68, 0x01, 0x23, 0x19, 0x42, 0xfb, 0xd1, 0xd1, 0x69, 0x19, 0x42, + 0xf8, 0xd1, 0x70, 0x47, 0x03, 0x68, 0x02, 0x21, 0x1a, 0x68, 0x0a, 0x43, + 0x1a, 0x60, 0x02, 0x68, 0xd3, 0x69, 0x99, 0x07, 0xfc, 0xd4, 0x70, 0x47, + 0x03, 0x68, 0xda, 0x69, 0x91, 0x07, 0xfc, 0xd4, 0x1a, 0x68, 0x02, 0x21, + 0x8a, 0x43, 0x1a, 0x60, 0x70, 0x47, 0x03, 0x68, 0x9a, 0x6a, 0x52, 0x0a, + 0x52, 0x02, 0x11, 0x43, 0x99, 0x62, 0x03, 0x68, 0x1a, 0x7e, 0x51, 0x07, + 0xfc, 0xd5, 0x98, 0x6a, 0xc0, 0xb2, 0x70, 0x47, 0x03, 0x68, 0x22, 0x4a, + 0x30, 0xb5, 0x93, 0x42, 0x11, 0xd0, 0x21, 0x4a, 0x93, 0x42, 0x11, 0xd0, + 0x20, 0x4a, 0x93, 0x42, 0x11, 0xd0, 0x20, 0x4a, 0x93, 0x42, 0x11, 0xd0, + 0x1f, 0x4a, 0x93, 0x42, 0x11, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x30, 0xd1, + 0x0e, 0x23, 0x19, 0x22, 0x0d, 0xe0, 0x09, 0x23, 0x14, 0x22, 0x0a, 0xe0, + 0x0a, 0x23, 0x15, 0x22, 0x07, 0xe0, 0x0b, 0x23, 0x16, 0x22, 0x04, 0xe0, + 0x0c, 0x23, 0x17, 0x22, 0x01, 0xe0, 0x0d, 0x23, 0x18, 0x22, 0xdc, 0xb2, + 0x15, 0x49, 0x01, 0x20, 0x9b, 0x08, 0xa0, 0x40, 0x9b, 0x00, 0x08, 0x60, + 0x5b, 0x18, 0x03, 0x20, 0xc0, 0x21, 0x89, 0x00, 0x04, 0x40, 0x5d, 0x58, + 0xe0, 0x00, 0xff, 0x24, 0x84, 0x40, 0xa5, 0x43, 0x2c, 0x1c, 0xc0, 0x25, + 0x85, 0x40, 0x28, 0x1c, 0x20, 0x43, 0x58, 0x50, 0x80, 0x23, 0xdb, 0x01, + 0x1a, 0x43, 0x0a, 0x4b, 0x5a, 0x80, 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, + 0xfb, 0xdb, 0x30, 0xbd, 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, + 0x00, 0x10, 0x00, 0x42, 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, + 0x00, 0x1c, 0x00, 0x42, 0x00, 0xe1, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x40, + 0xf8, 0xb5, 0x04, 0x1c, 0x15, 0x1c, 0x0e, 0x1c, 0x1f, 0x1c, 0xff, 0xf7, + 0xa3, 0xff, 0x20, 0x1c, 0xff, 0xf7, 0x0b, 0xff, 0xb1, 0x00, 0x1c, 0x22, + 0x0a, 0x40, 0x69, 0x07, 0x23, 0x68, 0x09, 0x0c, 0x0a, 0x43, 0x1a, 0x60, + 0x22, 0x68, 0x84, 0x23, 0x93, 0x75, 0x01, 0x2e, 0x1a, 0xd1, 0x08, 0x21, + 0x01, 0x2d, 0x00, 0xd1, 0x10, 0x21, 0x0c, 0x4b, 0x79, 0x43, 0x18, 0x68, + 0xc0, 0x00, 0x00, 0xf0, 0xcd, 0xfb, 0x23, 0x68, 0x07, 0x21, 0x9a, 0x89, + 0x01, 0x40, 0xd2, 0x04, 0x49, 0x03, 0xd2, 0x0c, 0x0a, 0x43, 0x9a, 0x81, + 0x23, 0x68, 0x00, 0x04, 0xc2, 0x0c, 0x98, 0x89, 0x40, 0x0b, 0x40, 0x03, + 0x10, 0x43, 0x98, 0x81, 0xf8, 0xbd, 0xc0, 0x46, 0x04, 0x00, 0x00, 0x20, + 0xf7, 0xb5, 0x01, 0x93, 0x08, 0xab, 0x04, 0x1c, 0x1f, 0x78, 0x0d, 0x1c, + 0x16, 0x1c, 0xff, 0xf7, 0x3d, 0xff, 0x20, 0x1c, 0xff, 0xf7, 0x68, 0xff, + 0xbf, 0x07, 0x0c, 0x22, 0x17, 0x43, 0xc0, 0x22, 0x92, 0x03, 0x36, 0x05, + 0x16, 0x40, 0xc0, 0x22, 0x92, 0x02, 0x2d, 0x04, 0x23, 0x68, 0x3e, 0x43, + 0x01, 0x99, 0x15, 0x40, 0x35, 0x43, 0x07, 0x22, 0x1d, 0x60, 0x0a, 0x40, + 0x80, 0x21, 0x23, 0x68, 0x89, 0x02, 0x0a, 0x43, 0x5a, 0x60, 0xf7, 0xbd, + 0x01, 0x20, 0x70, 0x47, 0x08, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, + 0x98, 0x47, 0x08, 0xbd, 0x13, 0x04, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, + 0x00, 0x69, 0xff, 0xf7, 0xac, 0xfe, 0x20, 0x1c, 0x14, 0x30, 0x00, 0xf0, + 0x41, 0xfb, 0x20, 0x1c, 0x5c, 0x30, 0x00, 0xf0, 0x3d, 0xfb, 0x10, 0xbd, + 0x08, 0xb5, 0x14, 0x30, 0x00, 0xf0, 0x4a, 0xfb, 0x08, 0xbd, 0x10, 0xb5, + 0x04, 0x1c, 0x20, 0x1c, 0x5c, 0x30, 0x00, 0xf0, 0x43, 0xfb, 0x00, 0x28, + 0xf9, 0xd1, 0x20, 0x69, 0xff, 0xf7, 0xab, 0xfe, 0x10, 0xbd, 0x08, 0xb5, + 0x5c, 0x30, 0x00, 0xf0, 0x3f, 0xfb, 0x08, 0xbd, 0x70, 0xb5, 0x05, 0x1c, + 0x14, 0x35, 0x04, 0x1c, 0x28, 0x1c, 0x00, 0xf0, 0x23, 0xfb, 0x23, 0x1c, + 0xa8, 0x33, 0x1b, 0x78, 0x06, 0x1c, 0xff, 0x2b, 0x0a, 0xd0, 0x28, 0x1c, + 0x00, 0xf0, 0x2e, 0xfb, 0x0a, 0x28, 0x05, 0xdd, 0x23, 0x1c, 0xb0, 0x33, + 0xb4, 0x34, 0x1b, 0x68, 0x22, 0x68, 0x1a, 0x60, 0x30, 0x1c, 0x70, 0xbd, + 0x08, 0xb5, 0x14, 0x30, 0x00, 0xf0, 0x2a, 0xfb, 0x08, 0xbd, 0x70, 0xb5, + 0x04, 0x1c, 0x00, 0x69, 0x0e, 0x1c, 0xff, 0xf7, 0x9c, 0xfe, 0x25, 0x1c, + 0x5c, 0x35, 0x00, 0x28, 0x04, 0xd0, 0x28, 0x1c, 0x00, 0xf0, 0x0c, 0xfb, + 0x00, 0x28, 0x0c, 0xd0, 0x28, 0x1c, 0x00, 0xf0, 0x20, 0xfb, 0x00, 0x28, + 0xfa, 0xd1, 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0xe4, 0xfa, 0x20, 0x69, + 0xff, 0xf7, 0x97, 0xfe, 0x03, 0xe0, 0x20, 0x69, 0x31, 0x1c, 0xff, 0xf7, + 0x8b, 0xfe, 0x01, 0x20, 0x70, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x85, 0xb0, + 0x1d, 0x1c, 0x0a, 0xab, 0x1b, 0x78, 0x04, 0x1c, 0x00, 0x93, 0x0b, 0xab, + 0x1b, 0x78, 0x16, 0x1c, 0x01, 0x93, 0x0c, 0xab, 0x1b, 0x78, 0x0f, 0x1c, + 0x02, 0x93, 0x0d, 0xab, 0x1b, 0x78, 0x03, 0x93, 0x00, 0x23, 0x43, 0x60, + 0xfa, 0x23, 0x9b, 0x00, 0x83, 0x60, 0x0d, 0x4b, 0x08, 0x33, 0x03, 0x60, + 0x14, 0x30, 0x00, 0xf0, 0xb1, 0xfa, 0x20, 0x1c, 0x5c, 0x30, 0x00, 0xf0, + 0xad, 0xfa, 0x00, 0x9a, 0x23, 0x1c, 0xa4, 0x33, 0x27, 0x61, 0x9a, 0x70, + 0x01, 0x9a, 0x20, 0x1c, 0xda, 0x70, 0x02, 0x9a, 0x1e, 0x70, 0x1a, 0x71, + 0x03, 0x9a, 0x5d, 0x70, 0x1a, 0x75, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, + 0xc8, 0x58, 0x00, 0x00, 0x30, 0xb5, 0x85, 0xb0, 0x04, 0x1c, 0x08, 0xa8, + 0x05, 0x78, 0x09, 0xa8, 0x00, 0x78, 0x00, 0x95, 0x01, 0x90, 0xff, 0x20, + 0x02, 0x90, 0x03, 0x90, 0x20, 0x1c, 0xff, 0xf7, 0xbd, 0xff, 0x20, 0x1c, + 0x05, 0xb0, 0x30, 0xbd, 0x38, 0xb5, 0x04, 0x1c, 0x00, 0x69, 0xff, 0xf7, + 0x24, 0xfe, 0x00, 0x28, 0x19, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x34, 0xfe, + 0x25, 0x1c, 0x14, 0x35, 0x01, 0x1c, 0x28, 0x1c, 0x00, 0xf0, 0x83, 0xfa, + 0x23, 0x1c, 0xa8, 0x33, 0x1b, 0x78, 0xff, 0x2b, 0x0b, 0xd0, 0x28, 0x1c, + 0x00, 0xf0, 0x9e, 0xfa, 0x09, 0x28, 0x06, 0xdc, 0x23, 0x1c, 0x22, 0x1c, + 0xac, 0x33, 0xb4, 0x32, 0x1b, 0x68, 0x12, 0x68, 0x1a, 0x60, 0x20, 0x69, + 0xff, 0xf7, 0x15, 0xfe, 0x00, 0x28, 0x11, 0xd0, 0x25, 0x1c, 0x5c, 0x35, + 0x28, 0x1c, 0x00, 0xf0, 0x85, 0xfa, 0x00, 0x28, 0x07, 0xd0, 0x28, 0x1c, + 0x00, 0xf0, 0x72, 0xfa, 0xc1, 0xb2, 0x20, 0x69, 0xff, 0xf7, 0x0e, 0xfe, + 0x02, 0xe0, 0x20, 0x69, 0xff, 0xf7, 0x17, 0xfe, 0x20, 0x69, 0xff, 0xf7, + 0xf3, 0xfd, 0x00, 0x28, 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0xf2, 0xfd, + 0x20, 0x69, 0xff, 0xf7, 0xe2, 0xfd, 0x38, 0xbd, 0xf0, 0x23, 0x08, 0x1c, + 0x18, 0x40, 0x30, 0x38, 0x43, 0x42, 0x58, 0x41, 0x70, 0x47, 0xf0, 0x23, + 0x1b, 0x01, 0x19, 0x40, 0x80, 0x23, 0x9b, 0x00, 0x99, 0x42, 0x0c, 0xd0, + 0xc0, 0x23, 0x9b, 0x00, 0x99, 0x42, 0x06, 0xd0, 0x80, 0x23, 0x5b, 0x00, + 0x05, 0x20, 0x99, 0x42, 0x04, 0xd0, 0x00, 0x20, 0x02, 0xe0, 0x07, 0x20, + 0x00, 0xe0, 0x06, 0x20, 0x70, 0x47, 0x0f, 0x23, 0x19, 0x40, 0x01, 0x29, + 0x05, 0xd0, 0x02, 0x39, 0x4b, 0x42, 0x4b, 0x41, 0x02, 0x20, 0xc0, 0x1a, + 0x00, 0xe0, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, 0xf0, 0xb5, 0x03, 0x1c, + 0x85, 0xb0, 0x03, 0x91, 0xa4, 0x33, 0x04, 0x1c, 0x18, 0x27, 0x18, 0x78, + 0x3b, 0x1c, 0x43, 0x43, 0x34, 0x4e, 0x08, 0x21, 0xf3, 0x18, 0x59, 0x56, + 0x15, 0x1c, 0xff, 0xf7, 0xa5, 0xfc, 0x23, 0x1c, 0xa5, 0x33, 0x18, 0x78, + 0x3b, 0x1c, 0x43, 0x43, 0x08, 0x21, 0xf3, 0x18, 0x59, 0x56, 0xff, 0xf7, + 0x9b, 0xfc, 0x23, 0x1c, 0xa7, 0x33, 0x1b, 0x78, 0x02, 0x2b, 0x0a, 0xd1, + 0x23, 0x1c, 0xb8, 0x33, 0x18, 0x78, 0xff, 0x28, 0x05, 0xd0, 0x47, 0x43, + 0x08, 0x21, 0xf7, 0x19, 0x79, 0x56, 0xff, 0xf7, 0x8b, 0xfc, 0x27, 0x1c, + 0xa8, 0x37, 0x38, 0x78, 0xff, 0x28, 0x1a, 0xd0, 0x01, 0x21, 0xff, 0xf7, + 0xf9, 0xfb, 0x3b, 0x78, 0x18, 0x22, 0x5a, 0x43, 0xb3, 0x56, 0x1f, 0x4f, + 0xdb, 0x01, 0x21, 0x1c, 0xac, 0x31, 0xd8, 0x19, 0x08, 0x60, 0x1d, 0x49, + 0xb6, 0x18, 0x5b, 0x18, 0x21, 0x1c, 0x72, 0x68, 0xb0, 0x31, 0x0b, 0x60, + 0x01, 0x21, 0x91, 0x40, 0x0a, 0x1c, 0x21, 0x1c, 0xb4, 0x31, 0x0a, 0x60, + 0x1a, 0x60, 0x01, 0x21, 0x0a, 0x1c, 0x03, 0x9b, 0x20, 0x69, 0xff, 0xf7, + 0x31, 0xfe, 0x29, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x88, 0xff, 0x29, 0x1c, + 0x07, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x99, 0xff, 0x29, 0x1c, 0x06, 0x1c, + 0x20, 0x1c, 0xff, 0xf7, 0x77, 0xff, 0x39, 0x1c, 0x00, 0x90, 0x33, 0x1c, + 0x20, 0x69, 0x01, 0x22, 0xff, 0xf7, 0x02, 0xfd, 0x23, 0x1c, 0xa7, 0x33, + 0x19, 0x78, 0x01, 0x3b, 0x1a, 0x78, 0x20, 0x69, 0xff, 0xf7, 0x16, 0xfd, + 0x20, 0x69, 0xff, 0xf7, 0x34, 0xfd, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, + 0x20, 0x55, 0x00, 0x00, 0x18, 0x44, 0x00, 0x41, 0x14, 0x44, 0x00, 0x41, + 0x3f, 0x20, 0x70, 0x47, 0x13, 0xb5, 0x02, 0x68, 0x6b, 0x46, 0xd9, 0x71, + 0x07, 0x33, 0x54, 0x68, 0x19, 0x1c, 0x01, 0x22, 0xa0, 0x47, 0x16, 0xbd, + 0x08, 0xb5, 0x00, 0x69, 0x02, 0x21, 0x00, 0xf0, 0x49, 0xf8, 0x08, 0xbd, + 0x08, 0xb5, 0x00, 0x69, 0x03, 0x21, 0x00, 0xf0, 0x59, 0xf8, 0x08, 0xbd, + 0x38, 0xb5, 0x0d, 0x1c, 0x04, 0x1c, 0x13, 0x1c, 0x00, 0x69, 0x03, 0x21, + 0x2a, 0x1c, 0x00, 0xf0, 0xf1, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x01, 0x23, + 0x63, 0x60, 0x38, 0xbd, 0x10, 0xb5, 0x05, 0x4c, 0x23, 0x68, 0x5a, 0x1c, + 0x04, 0xd1, 0x03, 0x68, 0x5b, 0x69, 0x98, 0x47, 0x20, 0x60, 0x03, 0x1c, + 0x18, 0x1c, 0x10, 0xbd, 0x0c, 0x00, 0x00, 0x20, 0x07, 0x4a, 0x08, 0xb5, + 0x13, 0x68, 0x59, 0x1c, 0x04, 0xd0, 0x01, 0x21, 0x49, 0x42, 0x11, 0x60, + 0x18, 0x1c, 0x03, 0xe0, 0x00, 0x69, 0x02, 0x21, 0x00, 0xf0, 0xc2, 0xf8, + 0x08, 0xbd, 0xc0, 0x46, 0x0c, 0x00, 0x00, 0x20, 0x06, 0x4b, 0xfa, 0x21, + 0x89, 0x00, 0x99, 0x60, 0x05, 0x49, 0x00, 0x22, 0x08, 0x31, 0x19, 0x60, + 0x04, 0x49, 0x5a, 0x60, 0x19, 0x61, 0x1a, 0x76, 0x70, 0x47, 0xc0, 0x46, + 0x30, 0x09, 0x00, 0x20, 0x00, 0x59, 0x00, 0x00, 0xf0, 0x0c, 0x00, 0x20, + 0x08, 0xb5, 0x08, 0x4b, 0x8a, 0x00, 0xd0, 0x58, 0x00, 0x28, 0x03, 0xd0, + 0x03, 0x68, 0x9b, 0x68, 0x98, 0x47, 0x06, 0xe0, 0xc9, 0xb2, 0x04, 0x4b, + 0x49, 0x01, 0x59, 0x18, 0x88, 0x68, 0x80, 0x04, 0x80, 0x0c, 0x08, 0xbd, + 0xd4, 0x0c, 0x00, 0x20, 0xf4, 0x0c, 0x00, 0x20, 0x10, 0xb5, 0x0c, 0x1c, + 0xff, 0xf7, 0xe6, 0xff, 0x00, 0x28, 0x0c, 0xd0, 0x06, 0x4b, 0xe1, 0xb2, + 0x1b, 0x68, 0x08, 0x31, 0x49, 0x01, 0x59, 0x18, 0x4a, 0x79, 0x80, 0x23, + 0x5b, 0x42, 0x13, 0x43, 0x4b, 0x71, 0x02, 0x23, 0xcb, 0x71, 0x10, 0xbd, + 0xf4, 0x0c, 0x00, 0x20, 0x10, 0xb5, 0xc9, 0xb2, 0x0c, 0x48, 0x49, 0x01, + 0x43, 0x18, 0x9a, 0x68, 0x92, 0x04, 0x92, 0x0c, 0x3f, 0x2a, 0x08, 0xd9, + 0x14, 0x1c, 0x9a, 0x68, 0x40, 0x3c, 0xa4, 0x04, 0x92, 0x0b, 0xa4, 0x0c, + 0x92, 0x03, 0x22, 0x43, 0x02, 0xe0, 0x9a, 0x68, 0x92, 0x0b, 0x92, 0x03, + 0x9a, 0x60, 0x41, 0x18, 0x88, 0x68, 0xc0, 0xb2, 0x10, 0xbd, 0xc0, 0x46, + 0xf4, 0x0c, 0x00, 0x20, 0xf0, 0xb5, 0x1c, 0x1c, 0x2a, 0x4b, 0x85, 0xb0, + 0x1b, 0x68, 0x06, 0x1c, 0x0d, 0x1c, 0x02, 0x92, 0x00, 0x2b, 0x46, 0xd0, + 0x27, 0x4b, 0x8a, 0x00, 0xd0, 0x58, 0x00, 0x28, 0x05, 0xd0, 0x03, 0x68, + 0x02, 0x99, 0x5b, 0x68, 0x22, 0x1c, 0x98, 0x47, 0x3f, 0xe0, 0x30, 0x1c, + 0xff, 0xf7, 0x9e, 0xff, 0xa0, 0x42, 0x04, 0xd2, 0x30, 0x1c, 0x29, 0x1c, + 0xff, 0xf7, 0x98, 0xff, 0x04, 0x1c, 0x29, 0x1c, 0x30, 0x1c, 0xff, 0xf7, + 0xbf, 0xff, 0x1c, 0x4f, 0xe9, 0xb2, 0x4a, 0x01, 0x01, 0x91, 0x39, 0x68, + 0x03, 0x92, 0x8b, 0x18, 0xff, 0x33, 0x5a, 0x7a, 0x01, 0x21, 0x0a, 0x43, + 0x17, 0x49, 0x5a, 0x72, 0xab, 0x01, 0xc9, 0x18, 0x02, 0x98, 0x22, 0x1c, + 0x00, 0xf0, 0xb5, 0xf9, 0x00, 0x2c, 0x1b, 0xd0, 0x30, 0x1c, 0x29, 0x1c, + 0xff, 0xf7, 0x7a, 0xff, 0x00, 0x28, 0x15, 0xd1, 0x01, 0x9b, 0x3a, 0x68, + 0x08, 0x33, 0x5b, 0x01, 0xd3, 0x18, 0x19, 0x79, 0x40, 0x20, 0x01, 0x43, + 0x19, 0x71, 0x01, 0x21, 0xd9, 0x71, 0x03, 0x99, 0x53, 0x18, 0xff, 0x33, + 0x9a, 0x7a, 0x01, 0x21, 0x0a, 0x43, 0x9a, 0x72, 0x02, 0xe0, 0x01, 0x20, + 0x40, 0x42, 0x00, 0xe0, 0x20, 0x1c, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, + 0xf8, 0x0d, 0x00, 0x20, 0xd4, 0x0c, 0x00, 0x20, 0xf4, 0x0c, 0x00, 0x20, + 0x14, 0x0b, 0x00, 0x20, 0x13, 0xb5, 0x6c, 0x46, 0x07, 0x34, 0x22, 0x1c, + 0x01, 0x23, 0xff, 0xf7, 0x99, 0xff, 0x01, 0x28, 0x01, 0xd1, 0x20, 0x78, + 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x16, 0xbd, 0xf0, 0xb5, 0x1c, 0x1c, + 0x3a, 0x4b, 0x85, 0xb0, 0x1b, 0x68, 0x0e, 0x1c, 0x02, 0x92, 0x00, 0x2b, + 0x60, 0xd0, 0x80, 0x23, 0xdb, 0x01, 0x9c, 0x42, 0x5c, 0xd8, 0x00, 0x22, + 0x00, 0x92, 0x00, 0x2c, 0x56, 0xd0, 0x34, 0x4d, 0xf7, 0xb2, 0x2b, 0x68, + 0x01, 0x93, 0x3b, 0x1c, 0x08, 0x33, 0x01, 0x9a, 0x5b, 0x01, 0xd3, 0x18, + 0x9b, 0x79, 0xdb, 0x09, 0x1a, 0xd0, 0x2f, 0x4b, 0x2f, 0x49, 0x18, 0x68, + 0x00, 0xf0, 0xc2, 0xf8, 0x2e, 0x4b, 0x17, 0x21, 0x58, 0x43, 0x00, 0xf0, + 0xbd, 0xf8, 0x3b, 0x1c, 0x08, 0x33, 0x01, 0x9a, 0x5b, 0x01, 0xd3, 0x18, + 0xdb, 0x79, 0x9a, 0x07, 0x08, 0xd4, 0x29, 0x4b, 0x9a, 0x5d, 0x00, 0x2a, + 0x38, 0xd1, 0x42, 0x1e, 0x00, 0x28, 0x35, 0xd0, 0x10, 0x1c, 0xee, 0xe7, + 0x24, 0x4b, 0x00, 0x22, 0x9a, 0x55, 0x25, 0x1e, 0x3f, 0x2d, 0x00, 0xd9, + 0x3f, 0x25, 0x22, 0x4a, 0xb3, 0x01, 0xd3, 0x18, 0x18, 0x1c, 0x02, 0x99, + 0x2a, 0x1c, 0x03, 0x93, 0x00, 0xf0, 0x35, 0xf9, 0x18, 0x4a, 0x7b, 0x01, + 0xd3, 0x18, 0x03, 0x9a, 0xa9, 0x04, 0x5a, 0x61, 0x9a, 0x69, 0x89, 0x0c, + 0x92, 0x0b, 0x92, 0x03, 0x0a, 0x43, 0x9a, 0x61, 0x3b, 0x1c, 0x01, 0x9a, + 0x08, 0x33, 0x5b, 0x01, 0xd3, 0x18, 0x02, 0x22, 0xda, 0x71, 0x59, 0x79, + 0x80, 0x22, 0x52, 0x42, 0x0a, 0x43, 0x5a, 0x71, 0x00, 0x9b, 0x02, 0x9a, + 0x5b, 0x19, 0x52, 0x19, 0x00, 0x93, 0x64, 0x1b, 0x02, 0x92, 0xa6, 0xe7, + 0x00, 0x98, 0x0b, 0xe0, 0x01, 0x20, 0x08, 0xe0, 0x01, 0x22, 0x9a, 0x55, + 0x7b, 0x01, 0xed, 0x18, 0xab, 0x69, 0x10, 0x1c, 0x9b, 0x0b, 0x9b, 0x03, + 0xab, 0x61, 0x40, 0x42, 0x05, 0xb0, 0xf0, 0xbd, 0xf8, 0x0d, 0x00, 0x20, + 0xf4, 0x0c, 0x00, 0x20, 0x04, 0x00, 0x00, 0x20, 0x40, 0x42, 0x0f, 0x00, + 0x70, 0x11, 0x01, 0x00, 0x4c, 0x09, 0x00, 0x20, 0x54, 0x09, 0x00, 0x20, + 0x01, 0x4a, 0x02, 0x4b, 0x1a, 0x60, 0x70, 0x47, 0x00, 0x50, 0x00, 0x41, + 0xf4, 0x0c, 0x00, 0x20, 0x10, 0xb5, 0x00, 0x21, 0x40, 0x22, 0x04, 0x1c, + 0x00, 0xf0, 0xf2, 0xf8, 0x00, 0x23, 0x20, 0x1c, 0x23, 0x64, 0x63, 0x64, + 0x10, 0xbd, 0x02, 0x6c, 0x10, 0xb5, 0x3f, 0x23, 0x54, 0x1c, 0x23, 0x40, + 0x44, 0x6c, 0xa3, 0x42, 0x01, 0xd0, 0x81, 0x54, 0x03, 0x64, 0x10, 0xbd, + 0x00, 0x23, 0x03, 0x64, 0x43, 0x64, 0x70, 0x47, 0x43, 0x6c, 0x02, 0x6c, + 0x93, 0x42, 0x06, 0xd0, 0xc2, 0x5c, 0x3f, 0x21, 0x01, 0x33, 0x0b, 0x40, + 0x43, 0x64, 0x10, 0x1c, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x70, 0x47, + 0x02, 0x6c, 0x43, 0x6c, 0xd0, 0x1a, 0x00, 0xd5, 0x40, 0x30, 0x70, 0x47, + 0x03, 0x6c, 0x40, 0x6c, 0x83, 0x42, 0x02, 0xdb, 0xc0, 0x1a, 0x3f, 0x30, + 0x01, 0xe0, 0xc0, 0x1a, 0x01, 0x38, 0x70, 0x47, 0x43, 0x6c, 0x02, 0x6c, + 0x93, 0x42, 0x01, 0xd0, 0xc0, 0x5c, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, + 0x70, 0x47, 0x02, 0x6c, 0x3f, 0x23, 0x01, 0x32, 0x1a, 0x40, 0x43, 0x6c, + 0xd0, 0x1a, 0x43, 0x42, 0x58, 0x41, 0xc0, 0xb2, 0x70, 0x47, 0x00, 0x00, + 0x02, 0xb4, 0x71, 0x46, 0x49, 0x08, 0x49, 0x00, 0x09, 0x5c, 0x49, 0x00, + 0x8e, 0x44, 0x02, 0xbc, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x29, 0x34, 0xd0, + 0x01, 0x23, 0x00, 0x22, 0x10, 0xb4, 0x88, 0x42, 0x2c, 0xd3, 0x01, 0x24, + 0x24, 0x07, 0xa1, 0x42, 0x04, 0xd2, 0x81, 0x42, 0x02, 0xd2, 0x09, 0x01, + 0x1b, 0x01, 0xf8, 0xe7, 0xe4, 0x00, 0xa1, 0x42, 0x04, 0xd2, 0x81, 0x42, + 0x02, 0xd2, 0x49, 0x00, 0x5b, 0x00, 0xf8, 0xe7, 0x88, 0x42, 0x01, 0xd3, + 0x40, 0x1a, 0x1a, 0x43, 0x4c, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, + 0x5c, 0x08, 0x22, 0x43, 0x8c, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, + 0x9c, 0x08, 0x22, 0x43, 0xcc, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, + 0xdc, 0x08, 0x22, 0x43, 0x00, 0x28, 0x03, 0xd0, 0x1b, 0x09, 0x01, 0xd0, + 0x09, 0x09, 0xe3, 0xe7, 0x10, 0x1c, 0x10, 0xbc, 0x70, 0x47, 0x00, 0x28, + 0x01, 0xd0, 0x00, 0x20, 0xc0, 0x43, 0x07, 0xb4, 0x02, 0x48, 0x02, 0xa1, + 0x40, 0x18, 0x02, 0x90, 0x03, 0xbd, 0xc0, 0x46, 0x19, 0x00, 0x00, 0x00, + 0x00, 0x29, 0xf0, 0xd0, 0x03, 0xb5, 0xff, 0xf7, 0xb9, 0xff, 0x0e, 0xbc, + 0x42, 0x43, 0x89, 0x1a, 0x18, 0x47, 0xc0, 0x46, 0x70, 0x47, 0xc0, 0x46, + 0x70, 0xb5, 0x0e, 0x4b, 0x0e, 0x4d, 0x00, 0x24, 0xed, 0x1a, 0xad, 0x10, + 0x1e, 0x1c, 0xac, 0x42, 0x04, 0xd0, 0xa3, 0x00, 0xf3, 0x58, 0x98, 0x47, + 0x01, 0x34, 0xf8, 0xe7, 0x00, 0xf0, 0x32, 0xf9, 0x08, 0x4b, 0x09, 0x4d, + 0x00, 0x24, 0xed, 0x1a, 0xad, 0x10, 0x1e, 0x1c, 0xac, 0x42, 0x04, 0xd0, + 0xa3, 0x00, 0xf3, 0x58, 0x98, 0x47, 0x01, 0x34, 0xf8, 0xe7, 0x70, 0xbd, + 0x74, 0x00, 0x00, 0x20, 0x74, 0x00, 0x00, 0x20, 0x74, 0x00, 0x00, 0x20, + 0x98, 0x00, 0x00, 0x20, 0x08, 0xb5, 0x03, 0x4b, 0x01, 0x1c, 0x18, 0x68, + 0x00, 0xf0, 0x76, 0xf8, 0x08, 0xbd, 0xc0, 0x46, 0x70, 0x00, 0x00, 0x20, + 0x08, 0xb5, 0x03, 0x4b, 0x01, 0x1c, 0x18, 0x68, 0x00, 0xf0, 0x24, 0xf8, + 0x08, 0xbd, 0xc0, 0x46, 0x70, 0x00, 0x00, 0x20, 0x30, 0xb5, 0x00, 0x23, + 0x93, 0x42, 0x08, 0xd0, 0xc5, 0x5c, 0x01, 0x33, 0xcc, 0x18, 0x01, 0x3c, + 0x24, 0x78, 0xa5, 0x42, 0xf6, 0xd0, 0x28, 0x1b, 0x00, 0xe0, 0x00, 0x20, + 0x30, 0xbd, 0x10, 0xb5, 0x00, 0x23, 0x93, 0x42, 0x03, 0xd0, 0xcc, 0x5c, + 0xc4, 0x54, 0x01, 0x33, 0xf9, 0xe7, 0x10, 0xbd, 0x03, 0x1c, 0x82, 0x18, + 0x93, 0x42, 0x02, 0xd0, 0x19, 0x70, 0x01, 0x33, 0xfa, 0xe7, 0x70, 0x47, + 0x30, 0xb5, 0x00, 0x29, 0x40, 0xd0, 0x04, 0x39, 0x0b, 0x68, 0x00, 0x2b, + 0x00, 0xda, 0xc9, 0x18, 0x1e, 0x4a, 0x13, 0x68, 0x14, 0x1c, 0x00, 0x2b, + 0x02, 0xd1, 0x4b, 0x60, 0x11, 0x60, 0x33, 0xe0, 0x99, 0x42, 0x0f, 0xd2, + 0x08, 0x68, 0x0a, 0x18, 0x9a, 0x42, 0x05, 0xd1, 0x13, 0x68, 0x52, 0x68, + 0xc0, 0x18, 0x08, 0x60, 0x4a, 0x60, 0x00, 0xe0, 0x4b, 0x60, 0x21, 0x60, + 0x24, 0xe0, 0x8a, 0x42, 0x03, 0xd8, 0x13, 0x1c, 0x5a, 0x68, 0x00, 0x2a, + 0xf9, 0xd1, 0x1d, 0x68, 0x5c, 0x19, 0x8c, 0x42, 0x0b, 0xd1, 0x09, 0x68, + 0x69, 0x18, 0x58, 0x18, 0x19, 0x60, 0x90, 0x42, 0x14, 0xd1, 0x14, 0x68, + 0x52, 0x68, 0x09, 0x19, 0x19, 0x60, 0x5a, 0x60, 0x0e, 0xe0, 0x8c, 0x42, + 0x02, 0xd9, 0x0c, 0x23, 0x03, 0x60, 0x09, 0xe0, 0x08, 0x68, 0x0c, 0x18, + 0x94, 0x42, 0x03, 0xd1, 0x14, 0x68, 0x52, 0x68, 0x00, 0x19, 0x08, 0x60, + 0x4a, 0x60, 0x59, 0x60, 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x0e, 0x00, 0x20, + 0x70, 0xb5, 0x03, 0x23, 0xcd, 0x1c, 0x9d, 0x43, 0x08, 0x35, 0x06, 0x1c, + 0x0c, 0x2d, 0x01, 0xd2, 0x0c, 0x25, 0x01, 0xe0, 0x00, 0x2d, 0x3f, 0xdb, + 0x8d, 0x42, 0x3d, 0xd3, 0x20, 0x4b, 0x1c, 0x68, 0x1a, 0x1c, 0x21, 0x1c, + 0x00, 0x29, 0x13, 0xd0, 0x08, 0x68, 0x43, 0x1b, 0x0d, 0xd4, 0x0b, 0x2b, + 0x02, 0xd9, 0x0b, 0x60, 0xcc, 0x18, 0x1e, 0xe0, 0x8c, 0x42, 0x02, 0xd1, + 0x63, 0x68, 0x13, 0x60, 0x1a, 0xe0, 0x48, 0x68, 0x60, 0x60, 0x0c, 0x1c, + 0x16, 0xe0, 0x0c, 0x1c, 0x49, 0x68, 0xe9, 0xe7, 0x14, 0x4c, 0x20, 0x68, + 0x00, 0x28, 0x03, 0xd1, 0x30, 0x1c, 0x00, 0xf0, 0x25, 0xf8, 0x20, 0x60, + 0x30, 0x1c, 0x29, 0x1c, 0x00, 0xf0, 0x20, 0xf8, 0x43, 0x1c, 0x15, 0xd0, + 0xc4, 0x1c, 0x03, 0x23, 0x9c, 0x43, 0x84, 0x42, 0x0a, 0xd1, 0x25, 0x60, + 0x20, 0x1c, 0x0b, 0x30, 0x07, 0x22, 0x23, 0x1d, 0x90, 0x43, 0xc3, 0x1a, + 0x0b, 0xd0, 0x5a, 0x42, 0xe2, 0x50, 0x08, 0xe0, 0x21, 0x1a, 0x30, 0x1c, + 0x00, 0xf0, 0x0a, 0xf8, 0x01, 0x30, 0xee, 0xd1, 0x0c, 0x23, 0x33, 0x60, + 0x00, 0x20, 0x70, 0xbd, 0x00, 0x0e, 0x00, 0x20, 0xfc, 0x0d, 0x00, 0x20, + 0x38, 0xb5, 0x07, 0x4c, 0x00, 0x23, 0x05, 0x1c, 0x08, 0x1c, 0x23, 0x60, + 0x00, 0xf0, 0x2a, 0xf8, 0x43, 0x1c, 0x03, 0xd1, 0x23, 0x68, 0x00, 0x2b, + 0x00, 0xd0, 0x2b, 0x60, 0x38, 0xbd, 0xc0, 0x46, 0x08, 0x0e, 0x00, 0x20, + 0xc9, 0xb2, 0x03, 0x78, 0x00, 0x2b, 0x03, 0xd0, 0x8b, 0x42, 0x04, 0xd0, + 0x01, 0x30, 0xf8, 0xe7, 0x00, 0x29, 0x00, 0xd0, 0x18, 0x1c, 0x70, 0x47, + 0x30, 0xb5, 0x03, 0x1c, 0x00, 0x2a, 0x07, 0xd0, 0x0c, 0x78, 0x01, 0x33, + 0x5d, 0x1e, 0x01, 0x3a, 0x2c, 0x70, 0x01, 0x31, 0x00, 0x2c, 0xf5, 0xd1, + 0x9a, 0x18, 0x93, 0x42, 0x03, 0xd0, 0x00, 0x21, 0x19, 0x70, 0x01, 0x33, + 0xf9, 0xe7, 0x30, 0xbd, 0x09, 0x4a, 0x13, 0x68, 0x00, 0x2b, 0x0c, 0xd0, + 0x18, 0x18, 0x69, 0x46, 0x88, 0x42, 0x02, 0xd8, 0x10, 0x60, 0x18, 0x1c, + 0x70, 0x47, 0x05, 0x4b, 0x0c, 0x22, 0x01, 0x20, 0x1a, 0x60, 0x40, 0x42, + 0xf8, 0xe7, 0x03, 0x4b, 0x13, 0x60, 0xef, 0xe7, 0x04, 0x0e, 0x00, 0x20, + 0x08, 0x0e, 0x00, 0x20, 0x0c, 0x0e, 0x00, 0x20, 0xf8, 0xb5, 0xc0, 0x46, + 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, 0xf8, 0xb5, 0xc0, 0x46, + 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, 0x55, 0x50, 0x44, 0x41, + 0x54, 0x45, 0x2e, 0x42, 0x49, 0x4e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1f, 0x22, 0x00, 0x00, + 0x33, 0x22, 0x00, 0x00, 0x19, 0x22, 0x00, 0x00, 0x5d, 0x22, 0x00, 0x00, + 0x61, 0x23, 0x00, 0x00, 0x8d, 0x22, 0x00, 0x00, 0xa1, 0x22, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x2f, 0x00, 0x7c, 0x3c, 0x3e, 0x5e, 0x2b, 0x3d, + 0x3f, 0x2f, 0x5b, 0x5d, 0x3b, 0x2c, 0x2a, 0x22, 0x5c, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x01, 0x34, 0x00, 0x00, 0xe5, 0x40, 0x00, 0x00, 0x19, 0x22, 0x00, 0x00, + 0x1d, 0x22, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x10, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, + 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, + 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x04, + 0x00, 0x04, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x01, + 0x00, 0x01, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x13, 0x00, 0x01, 0x01, + 0x01, 0x01, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x05, + 0x00, 0x05, 0x0a, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x05, + 0x01, 0x05, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x02, 0x00, + 0x02, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, + 0x03, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x02, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x03, + 0x01, 0x03, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x10, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x11, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0a, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0b, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x05, 0x00, 0x01, 0x00, + 0x01, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x06, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x07, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x02, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x03, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x07, 0x45, 0x00, 0x00, 0xe5, 0x40, 0x00, 0x00, 0xbf, 0x44, 0x00, 0x00, + 0xa7, 0x44, 0x00, 0x00, 0x9d, 0x44, 0x00, 0x00, 0xc9, 0x44, 0x00, 0x00, + 0xfd, 0x44, 0x00, 0x00, 0x71, 0x44, 0x00, 0x00, 0xb5, 0x46, 0x00, 0x00, + 0x81, 0x44, 0x00, 0x00, 0x6d, 0x44, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xad, 0x47, 0x00, 0x00, + 0xd9, 0x47, 0x00, 0x00, 0xa9, 0x47, 0x00, 0x00, 0xcd, 0x47, 0x00, 0x00, + 0xc1, 0x47, 0x00, 0x00, 0x11, 0x48, 0x00, 0x00, 0xf5, 0x47, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0xff, 0xff, 0xff, 0x40, 0x42, 0x0f, 0x00, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x2c, 0x59, 0x00, 0x00, + 0x4c, 0x59, 0x00, 0x00, 0x6c, 0x59, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x28, 0x59, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x20, 0xdd, 0x20, 0x00, 0x00, + 0x05, 0x22, 0x00, 0x00, 0xed, 0x26, 0x00, 0x00, 0xa9, 0x2b, 0x00, 0x00, + 0x55, 0x38, 0x00, 0x00, 0x85, 0x3a, 0x00, 0x00, 0xfd, 0x3a, 0x00, 0x00, + 0x35, 0x48, 0x00, 0x00, 0xd9, 0x4a, 0x00, 0x00, 0xb5, 0x20, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00 diff --git a/libraries/SDU/src/boot/mkrwifi1010.h b/libraries/SDU/src/boot/mkrwifi1010.h new file mode 100644 index 0000000..d52b94c --- /dev/null +++ b/libraries/SDU/src/boot/mkrwifi1010.h @@ -0,0 +1,1236 @@ + 0x00, 0x80, 0x00, 0x20, 0xb9, 0x3b, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, + 0xa1, 0x3b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, + 0x0d, 0x3c, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, + 0xa1, 0x3b, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, + 0xa1, 0x3b, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, 0xa5, 0x3b, 0x00, 0x00, + 0xa1, 0x3b, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, + 0xf1, 0x3a, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, + 0xe1, 0x3a, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, + 0xa1, 0x3b, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, + 0xa1, 0x3b, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, + 0xa1, 0x3b, 0x00, 0x00, 0xa1, 0x3b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0xa0, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0x44, 0x59, 0x00, 0x00, 0x08, 0xb5, 0x08, 0x4b, 0x00, 0x2b, 0x03, 0xd0, + 0x07, 0x48, 0x08, 0x49, 0x00, 0xe0, 0x00, 0xbf, 0x07, 0x48, 0x03, 0x68, + 0x00, 0x2b, 0x03, 0xd0, 0x06, 0x4b, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, + 0x08, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x00, 0x44, 0x59, 0x00, 0x00, + 0xa4, 0x00, 0x00, 0x20, 0x9c, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xf0, 0xb5, 0x33, 0x4c, 0xa5, 0x44, 0x01, 0xf0, 0x57, 0xfe, 0x02, 0xf0, + 0xbf, 0xfd, 0x01, 0x20, 0x01, 0xf0, 0x80, 0xfd, 0x2f, 0x4d, 0x04, 0x21, + 0x28, 0x1c, 0x00, 0xf0, 0xe7, 0xf9, 0x00, 0x28, 0x44, 0xd0, 0x2d, 0x4e, + 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0xbe, 0xfa, 0x00, 0x28, 0x3d, 0xd0, + 0x29, 0x1c, 0x01, 0xa8, 0x32, 0x1c, 0x01, 0x23, 0x00, 0xf0, 0x6e, 0xfa, + 0x01, 0xa8, 0x00, 0xf0, 0x00, 0xf9, 0x80, 0x21, 0x04, 0x1c, 0xc9, 0x01, + 0x88, 0x42, 0x2d, 0xd9, 0x01, 0xa8, 0x00, 0xf0, 0xe6, 0xf8, 0x22, 0x4a, + 0xc0, 0x21, 0xa7, 0x18, 0x21, 0x48, 0xc9, 0x01, 0x3a, 0x1c, 0x01, 0xf0, + 0xf5, 0xfb, 0xc0, 0x24, 0xe4, 0x01, 0x80, 0x22, 0x0a, 0xa9, 0x92, 0x00, + 0x01, 0xa8, 0x00, 0xf0, 0xcf, 0xf8, 0x80, 0x23, 0x21, 0x1c, 0x0a, 0xaa, + 0x9b, 0x00, 0x19, 0x48, 0x01, 0xf0, 0x8e, 0xfb, 0x80, 0x22, 0x92, 0x00, + 0xa3, 0x18, 0x17, 0x4a, 0xa4, 0x18, 0xbc, 0x42, 0x01, 0xd2, 0x1c, 0x1c, + 0xe9, 0xe7, 0x01, 0x24, 0x01, 0xa8, 0x00, 0xf0, 0xed, 0xf8, 0x00, 0x2c, + 0x06, 0xd0, 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0x8d, 0xfa, 0x01, 0xe0, + 0x00, 0x24, 0xf3, 0xe7, 0xc0, 0x23, 0xdb, 0x01, 0x1b, 0x68, 0x83, 0xf3, + 0x08, 0x88, 0x0c, 0x4b, 0xc0, 0x22, 0xd2, 0x01, 0x9a, 0x60, 0x0b, 0x4b, + 0x1b, 0x68, 0x18, 0x47, 0x00, 0x20, 0x8b, 0x23, 0x9b, 0x00, 0x9d, 0x44, + 0xf0, 0xbd, 0xc0, 0x46, 0xd4, 0xfd, 0xff, 0xff, 0xd4, 0x00, 0x00, 0x20, + 0x3c, 0x4f, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xbc, 0x00, 0x00, 0x20, + 0x00, 0xa2, 0xff, 0xff, 0x00, 0xed, 0x00, 0xe0, 0x04, 0x60, 0x00, 0x00, + 0x08, 0xb5, 0x00, 0x21, 0x02, 0x48, 0x0a, 0x1c, 0x01, 0xf0, 0x38, 0xfb, + 0x08, 0xbd, 0xc0, 0x46, 0xbc, 0x00, 0x00, 0x20, 0x00, 0x20, 0x70, 0x47, + 0x70, 0x47, 0x13, 0xb5, 0x02, 0x68, 0x6b, 0x46, 0xd9, 0x71, 0x07, 0x33, + 0x54, 0x68, 0x19, 0x1c, 0x01, 0x22, 0xa0, 0x47, 0x16, 0xbd, 0x38, 0xb5, + 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x25, 0xa8, 0x42, 0x02, 0xd1, 0x01, 0x23, + 0x63, 0x60, 0x0a, 0xe0, 0x45, 0x60, 0x92, 0xb2, 0x01, 0xf0, 0x04, 0xf8, + 0x23, 0x6a, 0x5b, 0x68, 0x00, 0x2b, 0x02, 0xd0, 0x01, 0x23, 0x63, 0x60, + 0x28, 0x1c, 0x38, 0xbd, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x01, 0xd0, + 0x00, 0xf0, 0x42, 0xfe, 0x08, 0xbd, 0x00, 0x00, 0x13, 0xb5, 0x6c, 0x46, + 0x07, 0x34, 0x21, 0x1c, 0x01, 0x22, 0x00, 0xf0, 0x5d, 0xfd, 0x01, 0x28, + 0x01, 0xd1, 0x20, 0x78, 0x00, 0xe0, 0x01, 0x48, 0x00, 0xb2, 0x16, 0xbd, + 0xff, 0xff, 0x00, 0x00, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x02, 0xd0, + 0xff, 0xf7, 0xea, 0xff, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x08, 0xbd, + 0x38, 0xb5, 0x05, 0x1c, 0x00, 0x6a, 0x00, 0x28, 0x0a, 0xd0, 0xff, 0xf7, + 0xdf, 0xff, 0x04, 0x1c, 0x63, 0x1c, 0x05, 0xd0, 0x28, 0x6a, 0x01, 0x69, + 0x01, 0x39, 0x00, 0xf0, 0xe5, 0xfd, 0x20, 0x1c, 0x38, 0xbd, 0x00, 0x00, + 0xf8, 0xb5, 0xfa, 0x23, 0x9b, 0x00, 0x83, 0x60, 0x0d, 0x4b, 0x00, 0x25, + 0x08, 0x33, 0x04, 0x1c, 0x45, 0x60, 0x03, 0x60, 0x28, 0x20, 0x0f, 0x1c, + 0x16, 0x1c, 0x02, 0xf0, 0x05, 0xfd, 0x20, 0x62, 0xa8, 0x42, 0x0a, 0xd0, + 0x39, 0x1c, 0x28, 0x22, 0x02, 0xf0, 0x21, 0xfd, 0x20, 0x1c, 0x10, 0x30, + 0x31, 0x1c, 0x0c, 0x22, 0x02, 0xf0, 0xe6, 0xfd, 0x25, 0x77, 0x20, 0x1c, + 0xf8, 0xbd, 0xc0, 0x46, 0x48, 0x4f, 0x00, 0x00, 0xfa, 0x22, 0x92, 0x00, + 0x82, 0x60, 0x04, 0x4a, 0x00, 0x23, 0x08, 0x32, 0x43, 0x60, 0x02, 0x60, + 0x03, 0x62, 0x03, 0x74, 0x70, 0x47, 0xc0, 0x46, 0x48, 0x4f, 0x00, 0x00, + 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x01, 0xd0, 0x00, 0xf0, 0x02, 0xfd, + 0x08, 0xbd, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x04, 0xd0, 0x00, 0xf0, + 0xa5, 0xfd, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x08, 0xbd, 0x03, 0x6a, + 0x00, 0x2b, 0x01, 0xd0, 0x18, 0x69, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, + 0x70, 0x47, 0x00, 0x6a, 0x00, 0x28, 0x00, 0xd0, 0xc0, 0x69, 0x70, 0x47, + 0x38, 0xb5, 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x28, 0x0b, 0xd0, 0x20, 0x1c, + 0xff, 0xf7, 0xf3, 0xff, 0x05, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0xe7, 0xff, + 0x02, 0x4b, 0x28, 0x1a, 0x98, 0x42, 0x00, 0xd9, 0x18, 0x1c, 0x38, 0xbd, + 0xff, 0x7f, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x28, + 0x06, 0xd0, 0x00, 0xf0, 0xe7, 0xfd, 0x20, 0x6a, 0x02, 0xf0, 0xb2, 0xfc, + 0x00, 0x23, 0x23, 0x62, 0x10, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x0a, 0x1c, + 0x0c, 0x49, 0x8a, 0xb0, 0x04, 0x1c, 0x00, 0x23, 0x00, 0x91, 0x69, 0x46, + 0x4b, 0x72, 0x01, 0x93, 0x21, 0x1c, 0x68, 0x46, 0x01, 0x23, 0x00, 0xf0, + 0x81, 0xfe, 0x04, 0x1c, 0x60, 0x1e, 0x84, 0x41, 0xe4, 0xb2, 0x00, 0x2c, + 0x02, 0xd0, 0x68, 0x46, 0x00, 0xf0, 0xc8, 0xfd, 0x20, 0x1c, 0x0a, 0xb0, + 0x10, 0xbd, 0xc0, 0x46, 0x90, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x01, 0x23, + 0x00, 0x2a, 0x05, 0xd0, 0x00, 0xf0, 0x1a, 0xff, 0x03, 0x1c, 0x58, 0x1e, + 0x83, 0x41, 0xdb, 0xb2, 0x18, 0x1c, 0x08, 0xbd, 0x38, 0xb5, 0x01, 0x22, + 0x05, 0x1c, 0x0c, 0x1c, 0x01, 0xf0, 0x94, 0xf9, 0x02, 0x1c, 0x01, 0x20, + 0x00, 0x2a, 0x03, 0xd1, 0x28, 0x1c, 0x21, 0x1c, 0x01, 0xf0, 0x8c, 0xf9, + 0x38, 0xbd, 0xf0, 0xb5, 0x0c, 0x68, 0x03, 0x5d, 0x2f, 0x3b, 0x5d, 0x42, + 0x6b, 0x41, 0xe4, 0x18, 0x27, 0x1c, 0x0c, 0x37, 0x23, 0x1c, 0xc5, 0x5c, + 0x1e, 0x1b, 0x2f, 0x2d, 0x09, 0xd0, 0x00, 0x2d, 0x07, 0xd0, 0x01, 0x33, + 0x16, 0x1b, 0xf6, 0x18, 0x01, 0x3e, 0x35, 0x70, 0xbb, 0x42, 0xf2, 0xd1, + 0x0c, 0x26, 0x00, 0x24, 0x94, 0x55, 0xc2, 0x5c, 0x2f, 0x3a, 0x54, 0x42, + 0x62, 0x41, 0x9b, 0x18, 0x0b, 0x60, 0xc0, 0x5c, 0x43, 0x1e, 0x98, 0x41, + 0xc0, 0xb2, 0xf0, 0xbd, 0xf0, 0xb5, 0xa1, 0xb0, 0x03, 0x90, 0x25, 0x48, + 0x0d, 0x1c, 0x04, 0x92, 0x05, 0x93, 0x0c, 0xaa, 0x00, 0x23, 0x16, 0xa9, + 0x0d, 0x93, 0x0c, 0x90, 0x53, 0x72, 0x17, 0x93, 0x16, 0x90, 0x4b, 0x72, + 0x07, 0x93, 0x2c, 0x1c, 0x00, 0x92, 0x07, 0xa9, 0x08, 0xaa, 0x03, 0x98, + 0xff, 0xf7, 0xc3, 0xff, 0x01, 0x26, 0x02, 0x1c, 0x72, 0x40, 0x01, 0x90, + 0xd2, 0xb2, 0x20, 0x1c, 0x08, 0xa9, 0x05, 0x9b, 0x04, 0x9f, 0xb8, 0x47, + 0x00, 0x28, 0x07, 0xd1, 0xac, 0x42, 0x01, 0xd1, 0x00, 0x20, 0x23, 0xe0, + 0x20, 0x1c, 0x00, 0xf0, 0x57, 0xfd, 0xf9, 0xe7, 0x01, 0x9f, 0x00, 0x2f, + 0x11, 0xd0, 0x33, 0x1c, 0x00, 0x98, 0x21, 0x1c, 0x08, 0xaa, 0x00, 0xf0, + 0xfd, 0xfd, 0x06, 0x1c, 0xac, 0x42, 0x0f, 0xd0, 0x20, 0x1c, 0x00, 0xf0, + 0x47, 0xfd, 0x00, 0x2e, 0xe8, 0xd0, 0x23, 0x1c, 0x00, 0x9c, 0x00, 0x93, + 0xd1, 0xe7, 0xac, 0x42, 0x02, 0xd0, 0x20, 0x1c, 0x00, 0xf0, 0x3c, 0xfd, + 0x30, 0x1c, 0x03, 0xe0, 0x00, 0x28, 0xdb, 0xd0, 0x16, 0xac, 0xf0, 0xe7, + 0x21, 0xb0, 0xf0, 0xbd, 0x90, 0x4f, 0x00, 0x00, 0x38, 0xb5, 0x03, 0x1c, + 0x41, 0x33, 0x1b, 0x78, 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x2b, 0x02, 0xd0, + 0x38, 0x30, 0x00, 0xf0, 0x27, 0xfd, 0x20, 0x1c, 0x01, 0x21, 0x2a, 0x1c, + 0x00, 0xf0, 0xc8, 0xf9, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x0f, 0xe0, + 0x25, 0x1c, 0x10, 0x35, 0x28, 0x1c, 0x21, 0x1c, 0xff, 0xf7, 0x62, 0xff, + 0x00, 0x28, 0xf5, 0xd0, 0x20, 0x1c, 0x38, 0x30, 0x29, 0x1c, 0x00, 0xf0, + 0xcf, 0xfb, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x38, 0xbd, 0x00, 0x00, + 0x4b, 0x68, 0x43, 0x60, 0x0a, 0x4b, 0x03, 0x60, 0x0b, 0x7a, 0x03, 0x72, + 0x4b, 0x7a, 0x43, 0x72, 0xcb, 0x68, 0xc3, 0x60, 0x0b, 0x69, 0x03, 0x61, + 0x4b, 0x69, 0x43, 0x61, 0x0b, 0x7e, 0x03, 0x76, 0xcb, 0x69, 0xc3, 0x61, + 0x0b, 0x6a, 0x49, 0x6a, 0x03, 0x62, 0x41, 0x62, 0x70, 0x47, 0xc0, 0x46, + 0x90, 0x4f, 0x00, 0x00, 0xf0, 0xb5, 0x9d, 0xb0, 0x08, 0xae, 0x02, 0x92, + 0x03, 0x93, 0x27, 0x4a, 0x00, 0x23, 0x12, 0xaf, 0x05, 0x1c, 0x73, 0x60, + 0x7b, 0x60, 0x10, 0x31, 0x30, 0x1c, 0x08, 0x92, 0x73, 0x72, 0x12, 0x92, + 0x7b, 0x72, 0x00, 0xf0, 0x9d, 0xfb, 0x02, 0x9c, 0x20, 0x1c, 0x2f, 0x21, + 0x02, 0xf0, 0x80, 0xfc, 0x00, 0x28, 0x2e, 0xd0, 0x23, 0x78, 0x2f, 0x2b, + 0x01, 0xd1, 0x01, 0x34, 0xf4, 0xe7, 0x00, 0x1b, 0xc0, 0xb2, 0x03, 0x1c, + 0x0c, 0x28, 0x00, 0xd9, 0x0c, 0x23, 0xdb, 0xb2, 0x1a, 0x1c, 0x21, 0x1c, + 0x04, 0xa8, 0x01, 0x93, 0x02, 0xf0, 0x78, 0xfc, 0x01, 0x9a, 0x00, 0x23, + 0x04, 0xa9, 0x38, 0x1c, 0x8b, 0x54, 0x00, 0xf0, 0xbf, 0xfc, 0x38, 0x1c, + 0x31, 0x1c, 0x04, 0xaa, 0x01, 0x23, 0x00, 0xf0, 0x69, 0xfd, 0x00, 0x28, + 0x04, 0xd1, 0x0c, 0x4b, 0x68, 0x60, 0x2b, 0x60, 0x68, 0x72, 0x10, 0xe0, + 0x01, 0x9b, 0x30, 0x1c, 0xe4, 0x18, 0x00, 0xf0, 0xad, 0xfc, 0x33, 0x1c, + 0x3e, 0x1c, 0x1f, 0x1c, 0xca, 0xe7, 0x02, 0x99, 0x03, 0x9a, 0x64, 0x1a, + 0x14, 0x60, 0x28, 0x1c, 0x31, 0x1c, 0xff, 0xf7, 0x95, 0xff, 0x28, 0x1c, + 0x1d, 0xb0, 0xf0, 0xbd, 0x90, 0x4f, 0x00, 0x00, 0xf0, 0xb5, 0xa1, 0xb0, + 0x05, 0x1c, 0x1f, 0x1c, 0x02, 0xa8, 0x01, 0xab, 0x16, 0x1c, 0xff, 0xf7, + 0xa1, 0xff, 0x01, 0x9b, 0xf6, 0x18, 0x33, 0x78, 0x00, 0x2b, 0x07, 0xd1, + 0x02, 0xa9, 0x16, 0xa8, 0xff, 0xf7, 0x7e, 0xff, 0x28, 0x1c, 0x16, 0xa9, + 0x17, 0x4a, 0x28, 0xe0, 0x00, 0x23, 0x0c, 0xac, 0x63, 0x60, 0x63, 0x72, + 0x6b, 0x46, 0x11, 0x33, 0x14, 0x4a, 0x1b, 0x78, 0x0c, 0x92, 0x00, 0x2b, + 0x03, 0xd1, 0x28, 0x1c, 0xff, 0xf7, 0x4a, 0xfe, 0x1b, 0xe0, 0x20, 0x1c, + 0x02, 0xa9, 0x32, 0x1c, 0x3b, 0x1c, 0x00, 0xf0, 0x21, 0xfd, 0x00, 0x28, + 0xf3, 0xd0, 0x02, 0xa8, 0x00, 0xf0, 0x6c, 0xfc, 0x06, 0x23, 0x1f, 0x40, + 0x9f, 0x42, 0x03, 0xd1, 0x20, 0x1c, 0x13, 0x99, 0x00, 0xf0, 0xf6, 0xfb, + 0x21, 0x1c, 0x16, 0xa8, 0xff, 0xf7, 0x54, 0xff, 0x28, 0x1c, 0x16, 0xa9, + 0x32, 0x1c, 0xff, 0xf7, 0x0b, 0xfe, 0x28, 0x1c, 0x21, 0xb0, 0xf0, 0xbd, + 0x70, 0x4f, 0x00, 0x00, 0x90, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x1c, + 0x08, 0x1c, 0x19, 0x1c, 0x38, 0x31, 0x02, 0x4a, 0x00, 0x23, 0xff, 0xf7, + 0xc9, 0xfe, 0x08, 0xbd, 0xa5, 0x23, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x1c, + 0x08, 0x1c, 0x19, 0x1c, 0x38, 0x31, 0x02, 0x4a, 0x00, 0x23, 0xff, 0xf7, + 0xbd, 0xfe, 0x08, 0xbd, 0xe1, 0x23, 0x00, 0x00, 0x08, 0x4b, 0x02, 0x21, + 0x19, 0x61, 0x19, 0x1c, 0x00, 0x22, 0x30, 0x31, 0x0a, 0x70, 0x06, 0x49, + 0x5a, 0x71, 0x9a, 0x71, 0x9a, 0x72, 0x1a, 0x73, 0xda, 0x63, 0x99, 0x63, + 0x41, 0x33, 0x1a, 0x70, 0x70, 0x47, 0xc0, 0x46, 0xd4, 0x00, 0x00, 0x20, + 0x90, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x01, 0x1c, 0x01, 0x48, 0x01, 0xf0, + 0xab, 0xf9, 0x08, 0xbd, 0x78, 0x07, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, + 0xff, 0x21, 0x01, 0xf0, 0xa3, 0xf9, 0x08, 0xbd, 0x78, 0x07, 0x00, 0x20, + 0x08, 0xb5, 0x01, 0x21, 0x00, 0x79, 0x01, 0xf0, 0x45, 0xfc, 0x05, 0x4b, + 0x1a, 0x78, 0x00, 0x2a, 0x04, 0xd0, 0x00, 0x22, 0x03, 0x48, 0x1a, 0x70, + 0x01, 0xf0, 0x80, 0xf9, 0x08, 0xbd, 0xc0, 0x46, 0x40, 0x01, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x10, 0xb5, 0x08, 0x4b, 0x04, 0x1c, 0x1a, 0x78, + 0x00, 0x2a, 0x06, 0xd1, 0x01, 0x22, 0x1a, 0x70, 0x05, 0x4b, 0x06, 0x48, + 0x06, 0xcb, 0x01, 0xf0, 0x51, 0xf9, 0x20, 0x79, 0x00, 0x21, 0x01, 0xf0, + 0x25, 0xfc, 0x10, 0xbd, 0x40, 0x01, 0x00, 0x20, 0x38, 0x01, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x10, 0xb5, 0x83, 0x79, 0x04, 0x1c, 0x00, 0x2b, + 0x0d, 0xd0, 0x23, 0x89, 0x5a, 0x1c, 0x22, 0x81, 0x05, 0x4a, 0x93, 0x42, + 0x02, 0xd8, 0xff, 0xf7, 0xbf, 0xff, 0xf6, 0xe7, 0x20, 0x1c, 0xff, 0xf7, + 0xc3, 0xff, 0x00, 0x23, 0xa3, 0x71, 0x10, 0xbd, 0x01, 0x02, 0x00, 0x00, + 0x00, 0xb5, 0x06, 0x29, 0x03, 0xd9, 0x16, 0x23, 0x43, 0x71, 0x00, 0x20, + 0x1c, 0xe0, 0x0f, 0x4b, 0x05, 0x29, 0x13, 0xd8, 0x08, 0x1c, 0x00, 0x22, + 0x02, 0xf0, 0x0a, 0xfa, 0x03, 0x05, 0x07, 0x09, 0x0b, 0x0d, 0x0b, 0x49, + 0x08, 0xe0, 0x0b, 0x49, 0x06, 0xe0, 0x0b, 0x49, 0x04, 0xe0, 0x0b, 0x49, + 0x02, 0xe0, 0x0b, 0x49, 0x00, 0xe0, 0x0b, 0x49, 0x19, 0x60, 0x02, 0xe0, + 0x0a, 0x4a, 0x1a, 0x60, 0x00, 0x22, 0x1a, 0x71, 0x5a, 0x71, 0x01, 0x20, + 0x00, 0xbd, 0xc0, 0x46, 0x38, 0x01, 0x00, 0x20, 0x00, 0x1b, 0xb7, 0x00, + 0x00, 0x09, 0x3d, 0x00, 0x80, 0x84, 0x1e, 0x00, 0x40, 0x42, 0x0f, 0x00, + 0x20, 0xa1, 0x07, 0x00, 0x90, 0xd0, 0x03, 0x00, 0x48, 0xe8, 0x01, 0x00, + 0x38, 0xb5, 0x0c, 0x1c, 0x01, 0xf0, 0xf6, 0xf9, 0x05, 0x1c, 0xff, 0xf7, + 0x79, 0xff, 0xff, 0x28, 0x06, 0xd0, 0x01, 0xf0, 0xef, 0xf9, 0x40, 0x1b, + 0xa0, 0x42, 0xf6, 0xd3, 0x00, 0x20, 0x00, 0xe0, 0x01, 0x20, 0x38, 0xbd, + 0xf8, 0xb5, 0x04, 0x1c, 0x0e, 0x1c, 0x17, 0x1c, 0xff, 0xf7, 0x9c, 0xff, + 0x20, 0x1c, 0xff, 0xf7, 0x81, 0xff, 0x96, 0x21, 0x49, 0x00, 0x20, 0x1c, + 0xff, 0xf7, 0xe0, 0xff, 0x40, 0x20, 0x30, 0x43, 0xff, 0xf7, 0x54, 0xff, + 0x18, 0x25, 0x38, 0x1c, 0xe8, 0x40, 0xc0, 0xb2, 0x08, 0x3d, 0xff, 0xf7, + 0x4d, 0xff, 0x2b, 0x1c, 0x08, 0x33, 0xf6, 0xd1, 0x95, 0x20, 0x00, 0x2e, + 0x03, 0xd0, 0x87, 0x20, 0x08, 0x2e, 0x00, 0xd0, 0xff, 0x20, 0xff, 0xf7, + 0x41, 0xff, 0x00, 0x25, 0xff, 0xf7, 0x46, 0xff, 0x43, 0xb2, 0xe0, 0x72, + 0x00, 0x2b, 0x04, 0xda, 0xff, 0x2d, 0x02, 0xd0, 0x01, 0x35, 0xed, 0xb2, + 0xf4, 0xe7, 0xf8, 0xbd, 0xf7, 0xb5, 0x00, 0x25, 0x02, 0x71, 0x05, 0x73, + 0x85, 0x72, 0x85, 0x71, 0x45, 0x71, 0x04, 0x1c, 0x01, 0x91, 0x01, 0xf0, + 0xab, 0xf9, 0x01, 0x21, 0x07, 0x1c, 0x20, 0x79, 0x01, 0xf0, 0x24, 0xfb, + 0x01, 0x21, 0x20, 0x79, 0x01, 0xf0, 0x7a, 0xfb, 0x42, 0x4e, 0x30, 0x1c, + 0x01, 0xf0, 0x76, 0xf8, 0x41, 0x4b, 0x42, 0x49, 0x1d, 0x71, 0x5d, 0x71, + 0x19, 0x60, 0x30, 0x1c, 0x5a, 0x68, 0x01, 0xf0, 0x95, 0xf8, 0x0a, 0x25, + 0x01, 0x3d, 0xff, 0x20, 0xed, 0xb2, 0xff, 0xf7, 0x0d, 0xff, 0x00, 0x2d, + 0xf8, 0xd1, 0x30, 0x1c, 0x01, 0xf0, 0xa6, 0xf8, 0x20, 0x1c, 0xff, 0xf7, + 0x29, 0xff, 0x00, 0x21, 0x20, 0x1c, 0x0a, 0x1c, 0xff, 0xf7, 0x9a, 0xff, + 0x06, 0x1c, 0xe0, 0x72, 0x01, 0x28, 0x08, 0xd0, 0x01, 0xf0, 0x7c, 0xf9, + 0xfa, 0x23, 0xc0, 0x1b, 0xdb, 0x00, 0x98, 0x42, 0xef, 0xd9, 0x01, 0x23, + 0x3b, 0xe0, 0xd5, 0x22, 0x20, 0x1c, 0x08, 0x21, 0x52, 0x00, 0xff, 0xf7, + 0x87, 0xff, 0x04, 0x23, 0x18, 0x42, 0x01, 0xd0, 0x26, 0x73, 0x0b, 0xe0, + 0x1e, 0x1c, 0xff, 0xf7, 0xed, 0xfe, 0x01, 0x3e, 0xf6, 0xb2, 0xe0, 0x72, + 0x00, 0x2e, 0xf8, 0xd1, 0x02, 0x23, 0xaa, 0x28, 0x25, 0xd1, 0x23, 0x73, + 0x26, 0x7b, 0x02, 0x3e, 0x73, 0x42, 0x5e, 0x41, 0xb6, 0x07, 0x37, 0x21, + 0x00, 0x22, 0x20, 0x1c, 0xff, 0xf7, 0x6c, 0xff, 0x32, 0x1c, 0x20, 0x1c, + 0x29, 0x21, 0xff, 0xf7, 0x67, 0xff, 0x02, 0x1c, 0xe0, 0x72, 0x08, 0xd0, + 0x01, 0xf0, 0x4a, 0xf9, 0xfa, 0x23, 0xc0, 0x1b, 0xdb, 0x00, 0x98, 0x42, + 0xeb, 0xd9, 0x08, 0x23, 0x09, 0xe0, 0x23, 0x7b, 0x02, 0x2b, 0x19, 0xd1, + 0x20, 0x1c, 0x3a, 0x21, 0xff, 0xf7, 0x54, 0xff, 0x00, 0x28, 0x05, 0xd0, + 0x06, 0x23, 0x63, 0x71, 0x20, 0x1c, 0xff, 0xf7, 0xc3, 0xfe, 0x15, 0xe0, + 0xff, 0xf7, 0xb8, 0xfe, 0xc0, 0x23, 0x18, 0x40, 0x98, 0x42, 0x01, 0xd1, + 0x03, 0x23, 0x23, 0x73, 0xff, 0xf7, 0xb0, 0xfe, 0xff, 0xf7, 0xae, 0xfe, + 0xff, 0xf7, 0xac, 0xfe, 0x20, 0x1c, 0xff, 0xf7, 0xb1, 0xfe, 0x20, 0x1c, + 0x01, 0x99, 0xff, 0xf7, 0xef, 0xfe, 0x05, 0x1c, 0x28, 0x1c, 0xfe, 0xbd, + 0x78, 0x07, 0x00, 0x20, 0x38, 0x01, 0x00, 0x20, 0x90, 0xd0, 0x03, 0x00, + 0x38, 0xb5, 0x04, 0x1c, 0x01, 0xf0, 0x12, 0xf9, 0x05, 0x1c, 0xff, 0xf7, + 0x95, 0xfe, 0xe0, 0x72, 0xff, 0x28, 0x08, 0xd1, 0x01, 0xf0, 0x0a, 0xf9, + 0x96, 0x23, 0x40, 0x1b, 0x5b, 0x00, 0x98, 0x42, 0xf3, 0xd9, 0x0f, 0x23, + 0x02, 0xe0, 0xfe, 0x28, 0x06, 0xd0, 0x0d, 0x23, 0x20, 0x1c, 0x63, 0x71, + 0xff, 0xf7, 0x8a, 0xfe, 0x00, 0x20, 0x00, 0xe0, 0x01, 0x20, 0x38, 0xbd, + 0xf8, 0xb5, 0x04, 0x1c, 0x0f, 0x1c, 0x15, 0x1c, 0x1e, 0x1e, 0x45, 0xd0, + 0x9a, 0x18, 0x80, 0x23, 0x9b, 0x00, 0x9a, 0x42, 0x42, 0xdc, 0x83, 0x79, + 0x00, 0x2b, 0x05, 0xd0, 0x02, 0x68, 0x91, 0x42, 0x02, 0xd1, 0x03, 0x89, + 0xab, 0x42, 0x16, 0xd9, 0x23, 0x7b, 0x27, 0x60, 0x03, 0x2b, 0x00, 0xd0, + 0x7f, 0x02, 0x3a, 0x1c, 0x20, 0x1c, 0x11, 0x21, 0xff, 0xf7, 0xf2, 0xfe, + 0x07, 0x1e, 0x02, 0xd0, 0x03, 0x23, 0x63, 0x71, 0x2a, 0xe0, 0x20, 0x1c, + 0xff, 0xf7, 0xbc, 0xff, 0x00, 0x28, 0x25, 0xd0, 0x01, 0x23, 0x27, 0x81, + 0xa3, 0x71, 0x23, 0x89, 0xab, 0x42, 0x05, 0xd2, 0xff, 0xf7, 0x4e, 0xfe, + 0x23, 0x89, 0x01, 0x33, 0x23, 0x81, 0xf6, 0xe7, 0x06, 0x9d, 0x06, 0x9a, + 0xab, 0x1a, 0x9b, 0xb2, 0xb3, 0x42, 0x04, 0xd2, 0xff, 0xf7, 0x42, 0xfe, + 0x28, 0x70, 0x01, 0x35, 0xf5, 0xe7, 0x23, 0x89, 0xa2, 0x7a, 0xf3, 0x18, + 0x9b, 0xb2, 0x23, 0x81, 0x00, 0x2a, 0x02, 0xd0, 0x06, 0x4a, 0x93, 0x42, + 0x02, 0xd9, 0x20, 0x1c, 0xff, 0xf7, 0x66, 0xfe, 0x01, 0x20, 0x03, 0xe0, + 0x20, 0x1c, 0xff, 0xf7, 0x35, 0xfe, 0x00, 0x20, 0xf8, 0xbd, 0xc0, 0x46, + 0xff, 0x01, 0x00, 0x00, 0x07, 0xb5, 0x80, 0x23, 0x00, 0x92, 0x9b, 0x00, + 0x00, 0x22, 0xff, 0xf7, 0xa3, 0xff, 0x0e, 0xbd, 0x70, 0xb5, 0x05, 0x1c, + 0x08, 0x1c, 0x16, 0x1c, 0xff, 0xf7, 0x12, 0xfe, 0x00, 0x24, 0x30, 0x5d, + 0xff, 0xf7, 0x0e, 0xfe, 0x01, 0x34, 0x80, 0x23, 0x9b, 0x00, 0x9c, 0x42, + 0xf7, 0xd1, 0xff, 0x20, 0xff, 0xf7, 0x06, 0xfe, 0xff, 0x20, 0xff, 0xf7, + 0x03, 0xfe, 0xff, 0xf7, 0x09, 0xfe, 0x1f, 0x23, 0xe8, 0x72, 0x03, 0x40, + 0x01, 0x20, 0x05, 0x2b, 0x05, 0xd0, 0x11, 0x23, 0x28, 0x1c, 0x6b, 0x71, + 0xff, 0xf7, 0x06, 0xfe, 0x00, 0x20, 0x70, 0xbd, 0x70, 0xb5, 0x0b, 0x1c, + 0x04, 0x1c, 0x16, 0x1c, 0x00, 0x29, 0x01, 0xd1, 0x12, 0x23, 0x28, 0xe0, + 0x02, 0x7b, 0x03, 0x2a, 0x00, 0xd0, 0x4b, 0x02, 0x20, 0x1c, 0x18, 0x21, + 0x1a, 0x1c, 0xff, 0xf7, 0x7d, 0xfe, 0x05, 0x1e, 0x01, 0xd0, 0x04, 0x23, + 0x1b, 0xe0, 0x20, 0x1c, 0xfe, 0x21, 0x32, 0x1c, 0xff, 0xf7, 0xc2, 0xff, + 0x00, 0x28, 0x15, 0xd0, 0x96, 0x21, 0x20, 0x1c, 0x89, 0x00, 0xff, 0xf7, + 0x5b, 0xfe, 0x00, 0x28, 0x01, 0xd1, 0x15, 0x23, 0x0b, 0xe0, 0x20, 0x1c, + 0x0d, 0x21, 0x2a, 0x1c, 0xff, 0xf7, 0x64, 0xfe, 0x00, 0x28, 0x03, 0xd1, + 0xff, 0xf7, 0xce, 0xfd, 0x00, 0x28, 0x06, 0xd0, 0x14, 0x23, 0x63, 0x71, + 0x20, 0x1c, 0xff, 0xf7, 0xcf, 0xfd, 0x00, 0x20, 0x03, 0xe0, 0x20, 0x1c, + 0xff, 0xf7, 0xca, 0xfd, 0x01, 0x20, 0x70, 0xbd, 0x03, 0x4b, 0x04, 0x4a, + 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x70, 0x47, 0xc0, 0x46, + 0x38, 0x01, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, 0x02, 0x1c, 0x10, 0xb5, + 0x0c, 0x32, 0x04, 0x1c, 0x01, 0x21, 0x40, 0x6a, 0x00, 0xf0, 0x24, 0xfd, + 0x00, 0x28, 0x0a, 0xd0, 0x23, 0x6a, 0x01, 0x20, 0x00, 0x2b, 0x06, 0xd1, + 0xe3, 0x68, 0x22, 0x7a, 0x23, 0x62, 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, + 0x23, 0x72, 0x10, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xe6, 0xff, + 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x1b, 0xe0, 0x63, 0x6a, 0xe6, 0x68, + 0x1a, 0x7c, 0x02, 0x3e, 0x96, 0x40, 0x5a, 0x69, 0x1d, 0x79, 0xb6, 0x18, + 0x00, 0x2d, 0x08, 0xd0, 0x70, 0x1e, 0x40, 0x19, 0x00, 0xf0, 0x4c, 0xfc, + 0x00, 0x28, 0xed, 0xd0, 0x01, 0x3d, 0xed, 0xb2, 0xf4, 0xe7, 0x63, 0x6a, + 0x01, 0x20, 0x1a, 0x7c, 0x80, 0x23, 0x9b, 0x00, 0x93, 0x40, 0xe2, 0x69, + 0xd3, 0x18, 0xe3, 0x61, 0x70, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, + 0x40, 0x69, 0x00, 0xf0, 0x13, 0xfc, 0x00, 0x28, 0x03, 0xd0, 0x20, 0x7e, + 0x01, 0x4b, 0x40, 0x01, 0xc0, 0x18, 0x10, 0xbd, 0x50, 0x01, 0x00, 0x20, + 0xf0, 0xb5, 0x00, 0x23, 0x87, 0xb0, 0x07, 0x1c, 0x0e, 0x1c, 0x20, 0x22, + 0xf2, 0x54, 0x01, 0x33, 0x0b, 0x2b, 0xfa, 0xd1, 0x07, 0x21, 0x00, 0x25, + 0x01, 0x91, 0x3c, 0x78, 0x00, 0x2c, 0x2a, 0xd0, 0x2e, 0x2c, 0x06, 0xd1, + 0x01, 0x9b, 0x0a, 0x2b, 0x2b, 0xd0, 0x0a, 0x21, 0x08, 0x25, 0x01, 0x91, + 0x1f, 0xe0, 0x02, 0xa8, 0x14, 0x49, 0x10, 0x22, 0x02, 0xf0, 0x51, 0xf8, + 0x00, 0x23, 0x02, 0xa9, 0xca, 0x5c, 0x00, 0x2a, 0x03, 0xd0, 0x01, 0x33, + 0xa2, 0x42, 0xf8, 0xd1, 0x19, 0xe0, 0x01, 0x9b, 0x9d, 0x42, 0x16, 0xd8, + 0x23, 0x1c, 0x21, 0x3b, 0x5d, 0x2b, 0x12, 0xd8, 0x22, 0x1c, 0x6b, 0x1c, + 0x61, 0x3a, 0xdb, 0xb2, 0x75, 0x19, 0x19, 0x2a, 0x01, 0xd8, 0x20, 0x3c, + 0xe4, 0xb2, 0x2c, 0x70, 0x1d, 0x1c, 0x01, 0x37, 0xd1, 0xe7, 0x30, 0x78, + 0x20, 0x38, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x00, 0xe0, 0x00, 0x20, + 0x07, 0xb0, 0xf0, 0xbd, 0x72, 0x4f, 0x00, 0x00, 0x38, 0xb5, 0x42, 0x7a, + 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x2a, 0x01, 0xd0, 0x00, 0x20, 0x1f, 0xe0, + 0x4b, 0x1c, 0xdb, 0x7f, 0x10, 0x2b, 0x06, 0xd1, 0x02, 0x23, 0x43, 0x72, + 0x02, 0x62, 0x4b, 0x8c, 0x5b, 0x01, 0xc3, 0x61, 0x0c, 0xe0, 0x20, 0x2b, + 0xf0, 0xd1, 0x03, 0x23, 0x43, 0x72, 0x49, 0x6a, 0x22, 0x1c, 0x01, 0x62, + 0x1c, 0x32, 0x28, 0x1c, 0x00, 0xf0, 0x18, 0xfc, 0x00, 0x28, 0xe5, 0xd0, + 0x00, 0x23, 0x01, 0x20, 0x65, 0x62, 0x20, 0x72, 0xe3, 0x60, 0x23, 0x61, + 0x63, 0x61, 0x23, 0x76, 0x38, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x43, 0x7a, + 0x85, 0xb0, 0x04, 0x1c, 0x0e, 0x1c, 0x03, 0x92, 0x00, 0x2b, 0x01, 0xd1, + 0x3a, 0x48, 0x11, 0xe0, 0x03, 0x7a, 0xd8, 0x07, 0xfa, 0xd5, 0xe2, 0x69, + 0x20, 0x69, 0x03, 0x99, 0x13, 0x1a, 0x99, 0x42, 0x01, 0xd9, 0x9b, 0xb2, + 0x03, 0x93, 0x03, 0x99, 0x02, 0x91, 0x02, 0x9b, 0x00, 0x2b, 0x04, 0xd1, + 0x03, 0x99, 0x88, 0xb2, 0x00, 0xb2, 0x05, 0xb0, 0xf0, 0xbd, 0x23, 0x69, + 0x61, 0x7a, 0xdf, 0x05, 0xff, 0x0d, 0x5a, 0x0a, 0x60, 0x6a, 0x02, 0x29, + 0x02, 0xd1, 0x41, 0x6a, 0x51, 0x18, 0x1b, 0xe0, 0x05, 0x79, 0x01, 0x3d, + 0x2a, 0x40, 0xd5, 0xb2, 0x00, 0x2f, 0x0d, 0xd1, 0x00, 0x2d, 0x0b, 0xd1, + 0x00, 0x2b, 0x02, 0xd1, 0x22, 0x6a, 0xe2, 0x60, 0x06, 0xe0, 0x22, 0x1c, + 0xe1, 0x68, 0x0c, 0x32, 0x00, 0xf0, 0xa0, 0xfb, 0x00, 0x28, 0xc9, 0xd0, + 0x63, 0x6a, 0xe1, 0x68, 0x1a, 0x7c, 0x02, 0x39, 0x5b, 0x69, 0x91, 0x40, + 0xc9, 0x18, 0x49, 0x19, 0x80, 0x22, 0x02, 0x9d, 0x92, 0x00, 0xd3, 0x1b, + 0x9d, 0x42, 0x00, 0xdd, 0x9d, 0xb2, 0x23, 0x7a, 0x58, 0x06, 0x01, 0xd4, + 0x95, 0x42, 0x18, 0xd1, 0x16, 0x4b, 0x1b, 0x68, 0x99, 0x42, 0x14, 0xd0, + 0x15, 0x4b, 0x3a, 0x1c, 0x18, 0x68, 0x00, 0x96, 0x2b, 0x1c, 0xff, 0xf7, + 0x1f, 0xfe, 0x00, 0x28, 0xa8, 0xd0, 0x76, 0x19, 0x01, 0xe0, 0xdf, 0x1b, + 0xf6, 0x19, 0x21, 0x69, 0x02, 0x9a, 0x4b, 0x19, 0x55, 0x1b, 0xad, 0xb2, + 0x23, 0x61, 0x02, 0x95, 0xab, 0xe7, 0x08, 0x1c, 0x00, 0x21, 0x00, 0xf0, + 0x2b, 0xfb, 0x00, 0x28, 0x96, 0xd0, 0x09, 0x4b, 0x32, 0x1c, 0xff, 0x18, + 0x79, 0x19, 0x3b, 0x1c, 0x8b, 0x42, 0xe8, 0xd0, 0x18, 0x78, 0x01, 0x33, + 0x10, 0x70, 0x01, 0x32, 0xf8, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x73, 0xb5, 0x43, 0x7a, 0x04, 0x1c, 0x01, 0x2b, 0x01, 0xd8, 0x00, 0x20, + 0x16, 0xe0, 0x03, 0x69, 0x6d, 0x46, 0x07, 0x35, 0xde, 0x05, 0x29, 0x1c, + 0x01, 0x22, 0x36, 0x0f, 0xff, 0xf7, 0x6a, 0xff, 0x01, 0x28, 0x01, 0xd1, + 0x2b, 0x78, 0x00, 0xe0, 0x05, 0x4b, 0x1b, 0xb2, 0x01, 0x33, 0xec, 0xd0, + 0x23, 0x69, 0x70, 0x01, 0x1f, 0x33, 0x23, 0x61, 0x02, 0x4b, 0xc0, 0x18, + 0x76, 0xbd, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0x50, 0x01, 0x00, 0x20, + 0x70, 0xb5, 0x04, 0x1c, 0x40, 0x7a, 0x0d, 0x1c, 0x00, 0x28, 0x2a, 0xd0, + 0xe2, 0x69, 0x91, 0x42, 0x01, 0xd9, 0x00, 0x20, 0x25, 0xe0, 0x02, 0x28, + 0x21, 0xd0, 0x00, 0x2d, 0x01, 0xd1, 0xe5, 0x60, 0x1d, 0xe0, 0x62, 0x6a, + 0x21, 0x69, 0x13, 0x7c, 0x68, 0x1e, 0x09, 0x33, 0x4a, 0x1e, 0xd8, 0x40, + 0xda, 0x40, 0x03, 0x1e, 0x93, 0x42, 0x01, 0xd3, 0x00, 0x29, 0x02, 0xd1, + 0x22, 0x6a, 0xe2, 0x60, 0x00, 0xe0, 0x83, 0x1a, 0x1e, 0x1c, 0x00, 0x2e, + 0x09, 0xd0, 0x22, 0x1c, 0x60, 0x6a, 0xe1, 0x68, 0x0c, 0x32, 0x00, 0xf0, + 0x07, 0xfb, 0x01, 0x3e, 0x00, 0x28, 0xf4, 0xd1, 0x01, 0xe0, 0x25, 0x61, + 0x01, 0x20, 0x70, 0xbd, 0x38, 0xb5, 0x05, 0x1c, 0x40, 0x7a, 0x00, 0x28, + 0x33, 0xd0, 0x2b, 0x7a, 0x7f, 0x2b, 0x2d, 0xd9, 0x28, 0x1c, 0x01, 0x21, + 0xff, 0xf7, 0x9a, 0xfe, 0x04, 0x1e, 0x2a, 0xd0, 0x6b, 0x7a, 0x01, 0x2b, + 0x07, 0xd8, 0x2b, 0x7f, 0x03, 0x77, 0x6b, 0x7f, 0x43, 0x77, 0xab, 0x7f, + 0x83, 0x77, 0xeb, 0x7f, 0xc3, 0x77, 0x2b, 0x6a, 0x9a, 0xb2, 0x1b, 0x0c, + 0x23, 0x75, 0x1b, 0x0a, 0x63, 0x75, 0x0d, 0x4b, 0xa2, 0x76, 0x1b, 0x68, + 0x12, 0x0a, 0xe2, 0x76, 0x00, 0x2b, 0x0b, 0xd0, 0x20, 0x1c, 0x21, 0x1c, + 0x18, 0x30, 0x16, 0x31, 0x98, 0x47, 0x63, 0x7e, 0x22, 0x7e, 0x1b, 0x02, + 0x13, 0x43, 0xa3, 0x74, 0x1b, 0x0a, 0xe3, 0x74, 0x2a, 0x7a, 0x7f, 0x23, + 0x13, 0x40, 0x2b, 0x72, 0x00, 0xf0, 0x5c, 0xfa, 0xff, 0xe7, 0x38, 0xbd, + 0x44, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xc0, 0xff, + 0x00, 0x28, 0x02, 0xd0, 0x00, 0x23, 0x63, 0x72, 0x01, 0x20, 0x10, 0xbd, + 0x73, 0xb5, 0x42, 0x7a, 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x20, 0x01, 0x2a, + 0x4b, 0xd1, 0x20, 0x7a, 0x02, 0x23, 0x18, 0x40, 0x47, 0xd0, 0xe3, 0x69, + 0x00, 0x20, 0x99, 0x42, 0x43, 0xd8, 0x10, 0x1c, 0x00, 0x2b, 0x40, 0xd0, + 0x20, 0x1c, 0x29, 0x1c, 0x26, 0x69, 0xff, 0xf7, 0x71, 0xff, 0x00, 0x28, + 0x25, 0xd0, 0x60, 0x6a, 0x00, 0x2d, 0x06, 0xd1, 0x21, 0x6a, 0x00, 0xf0, + 0x95, 0xfb, 0x00, 0x28, 0x1d, 0xd0, 0x25, 0x62, 0x1d, 0xe0, 0xe1, 0x68, + 0x01, 0xaa, 0x00, 0xf0, 0x93, 0xfa, 0x00, 0x28, 0x15, 0xd0, 0x60, 0x6a, + 0x01, 0x99, 0x43, 0x1c, 0xdb, 0x7f, 0x10, 0x2b, 0x01, 0xd1, 0x12, 0x4b, + 0x00, 0xe0, 0x12, 0x4b, 0x99, 0x42, 0x0c, 0xd2, 0x00, 0xf0, 0x7e, 0xfb, + 0x00, 0x28, 0x06, 0xd0, 0x60, 0x6a, 0xe1, 0x68, 0x0e, 0x4a, 0x00, 0xf0, + 0xcf, 0xfa, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x11, 0xe0, 0x22, 0x7a, + 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, 0xe5, 0x61, 0x23, 0x72, 0x20, 0x1c, + 0xff, 0xf7, 0x70, 0xff, 0x00, 0x28, 0xf2, 0xd0, 0x29, 0x1e, 0xb1, 0x42, + 0x00, 0xd9, 0x31, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x35, 0xff, 0x76, 0xbd, + 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, 0xff, 0xff, 0xff, 0x0f, + 0x38, 0xb5, 0x23, 0x4b, 0x15, 0x1c, 0x4a, 0x01, 0xd3, 0x18, 0x04, 0x1c, + 0xd8, 0x7a, 0x11, 0x22, 0x10, 0x42, 0x04, 0xd0, 0x42, 0x22, 0x15, 0x42, + 0x01, 0xd0, 0x00, 0x20, 0x36, 0xe0, 0x1d, 0x4a, 0x21, 0x76, 0x12, 0x68, + 0x62, 0x61, 0x5a, 0x7d, 0x18, 0x7d, 0xd9, 0x7e, 0x12, 0x02, 0x02, 0x43, + 0x98, 0x7e, 0x09, 0x02, 0x12, 0x04, 0x01, 0x43, 0x11, 0x43, 0x21, 0x62, + 0xd8, 0x7a, 0x18, 0x22, 0x02, 0x40, 0x0c, 0xd1, 0x5a, 0x7f, 0x19, 0x7f, + 0x12, 0x02, 0x0a, 0x43, 0x99, 0x7f, 0xdb, 0x7f, 0x09, 0x04, 0x0a, 0x43, + 0x1b, 0x06, 0x13, 0x43, 0xe3, 0x61, 0x01, 0x23, 0x09, 0xe0, 0x10, 0x2a, + 0xdb, 0xd1, 0x22, 0x1c, 0x60, 0x6a, 0x1c, 0x32, 0x00, 0xf0, 0x5a, 0xfa, + 0x00, 0x28, 0xd4, 0xd0, 0x04, 0x23, 0x63, 0x72, 0x0f, 0x23, 0x00, 0x21, + 0x2b, 0x40, 0x23, 0x72, 0xe1, 0x60, 0x21, 0x61, 0x01, 0x20, 0x6a, 0x06, + 0x02, 0xd5, 0x20, 0x1c, 0xff, 0xf7, 0x60, 0xff, 0x38, 0xbd, 0xc0, 0x46, + 0x50, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0xf0, 0xb5, 0x45, 0x7a, + 0x87, 0xb0, 0x04, 0x1c, 0x0e, 0x1c, 0x01, 0x93, 0x00, 0x2d, 0x00, 0xd0, + 0x86, 0xe0, 0x10, 0x1c, 0x03, 0xa9, 0xff, 0xf7, 0xbb, 0xfd, 0x00, 0x28, + 0x00, 0xd1, 0x80, 0xe0, 0x72, 0x6a, 0x2f, 0x1c, 0x62, 0x62, 0xf5, 0x60, + 0x35, 0x61, 0x33, 0x69, 0xf2, 0x69, 0x93, 0x42, 0x26, 0xd2, 0xdb, 0x05, + 0x1b, 0x0f, 0x30, 0x1c, 0x00, 0x93, 0xff, 0xf7, 0x9f, 0xfe, 0x01, 0x1e, + 0x6f, 0xd0, 0x03, 0x78, 0x00, 0x2b, 0x01, 0xd0, 0xe5, 0x2b, 0x0b, 0xd1, + 0x00, 0x2f, 0x04, 0xd1, 0x00, 0x9b, 0x23, 0x76, 0x34, 0x4b, 0x1b, 0x68, + 0x63, 0x61, 0x0b, 0x78, 0x01, 0x27, 0x00, 0x2b, 0xe3, 0xd1, 0x0d, 0xe0, + 0x03, 0xa8, 0x0b, 0x22, 0x01, 0xf0, 0xf2, 0xfd, 0x00, 0x28, 0xdc, 0xd1, + 0x01, 0x9a, 0x30, 0x23, 0x13, 0x40, 0x30, 0x2b, 0x53, 0xd0, 0x20, 0x1c, + 0x00, 0x99, 0x4b, 0xe0, 0x01, 0x9a, 0x12, 0x23, 0x13, 0x40, 0x12, 0x2b, + 0x4b, 0xd1, 0x00, 0x2f, 0x06, 0xd0, 0x20, 0x1c, 0x01, 0x21, 0xff, 0xf7, + 0x6f, 0xfd, 0x06, 0x1e, 0x0a, 0xd1, 0x42, 0xe0, 0x73, 0x7a, 0x02, 0x2b, + 0x3f, 0xd0, 0x30, 0x1c, 0xff, 0xf7, 0x40, 0xfd, 0x00, 0x28, 0x3a, 0xd0, + 0x1f, 0x4e, 0x27, 0x76, 0x00, 0x21, 0x20, 0x22, 0x30, 0x1c, 0x01, 0xf0, + 0xe3, 0xfd, 0x30, 0x1c, 0x03, 0xa9, 0x0b, 0x22, 0x01, 0xf0, 0xd5, 0xfd, + 0x1a, 0x4b, 0x1b, 0x68, 0x00, 0x2b, 0x05, 0xd0, 0x30, 0x1c, 0x31, 0x1c, + 0x10, 0x30, 0x0e, 0x31, 0x98, 0x47, 0x06, 0xe0, 0x21, 0x22, 0x32, 0x74, + 0xb3, 0x73, 0x28, 0x22, 0x08, 0x23, 0x72, 0x74, 0xf3, 0x73, 0x73, 0x7c, + 0x32, 0x7c, 0x1b, 0x02, 0x13, 0x43, 0xff, 0x22, 0x1a, 0x40, 0x1b, 0x0a, + 0xf3, 0x74, 0x73, 0x76, 0xf3, 0x7b, 0xb2, 0x74, 0x32, 0x76, 0xb2, 0x7b, + 0x1b, 0x02, 0x13, 0x43, 0xb3, 0x75, 0x1b, 0x0a, 0xf3, 0x75, 0x00, 0xf0, + 0x21, 0xf9, 0x00, 0x28, 0x07, 0xd0, 0x21, 0x7e, 0x01, 0x9a, 0x20, 0x1c, + 0xff, 0xf7, 0x26, 0xff, 0x05, 0x1c, 0x00, 0xe0, 0x00, 0x25, 0x28, 0x1c, + 0x07, 0xb0, 0xf0, 0xbd, 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x44, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x00, 0x21, 0x04, 0x1c, 0xff, 0xf7, + 0xbb, 0xfe, 0x00, 0x28, 0x0b, 0xd0, 0x20, 0x1c, 0x01, 0x21, 0xff, 0xf7, + 0x15, 0xfd, 0x00, 0x28, 0x05, 0xd0, 0xe5, 0x23, 0x03, 0x70, 0x00, 0x23, + 0x63, 0x72, 0x00, 0xf0, 0xfb, 0xf8, 0x10, 0xbd, 0x10, 0xb5, 0x0a, 0x1c, + 0x0a, 0x49, 0x8a, 0xb0, 0x08, 0x31, 0x00, 0x23, 0x04, 0x1c, 0x00, 0x91, + 0x69, 0x46, 0x4b, 0x72, 0x01, 0x93, 0x68, 0x46, 0x21, 0x1c, 0x02, 0x23, + 0xff, 0xf7, 0x42, 0xff, 0x00, 0x28, 0x02, 0xd0, 0x68, 0x46, 0xff, 0xf7, + 0xd7, 0xff, 0x0a, 0xb0, 0x10, 0xbd, 0xc0, 0x46, 0x88, 0x4f, 0x00, 0x00, + 0xf0, 0xb5, 0x43, 0x7a, 0x87, 0xb0, 0x04, 0x1c, 0x0d, 0x1c, 0x03, 0x92, + 0x01, 0x2b, 0x0d, 0xd1, 0x03, 0x7a, 0x99, 0x07, 0x0a, 0xd5, 0x5a, 0x07, + 0x0c, 0xd5, 0xe1, 0x69, 0x22, 0x69, 0x8a, 0x42, 0x08, 0xd0, 0x20, 0x1c, + 0xff, 0xf7, 0x06, 0xfe, 0x00, 0x28, 0x03, 0xd1, 0x01, 0x23, 0x63, 0x60, + 0x00, 0x20, 0xaa, 0xe0, 0x03, 0x9b, 0x01, 0x93, 0x3b, 0xe0, 0x60, 0x6a, + 0x73, 0x0a, 0x07, 0x79, 0xf6, 0x05, 0x01, 0x3f, 0x1f, 0x40, 0xff, 0xb2, + 0xf6, 0x0d, 0x00, 0x2f, 0x36, 0xd0, 0x80, 0x22, 0x92, 0x00, 0x92, 0x1b, + 0x01, 0x99, 0x92, 0xb2, 0x0b, 0x1c, 0x91, 0x42, 0x00, 0xd9, 0x13, 0x1c, + 0x9b, 0xb2, 0x02, 0x93, 0x63, 0x6a, 0xe1, 0x68, 0x1a, 0x7c, 0x02, 0x39, + 0x91, 0x40, 0x5a, 0x69, 0x8b, 0x18, 0x02, 0x9a, 0xdf, 0x19, 0x80, 0x23, + 0x9b, 0x00, 0x9a, 0x42, 0x3f, 0xd1, 0x44, 0x4b, 0x19, 0x68, 0xb9, 0x42, + 0x02, 0xd1, 0x01, 0x22, 0x52, 0x42, 0x1a, 0x60, 0x41, 0x4b, 0x39, 0x1c, + 0x18, 0x68, 0x2a, 0x1c, 0xff, 0xf7, 0x22, 0xfc, 0x00, 0x28, 0xc7, 0xd0, + 0x80, 0x22, 0x92, 0x00, 0xad, 0x18, 0x01, 0x99, 0x02, 0x9a, 0x8b, 0x1a, + 0x21, 0x69, 0x9b, 0xb2, 0x01, 0x93, 0x8b, 0x18, 0x23, 0x61, 0x01, 0x9a, + 0x26, 0x69, 0x00, 0x2a, 0xbf, 0xd1, 0x49, 0xe0, 0x00, 0x2e, 0xc6, 0xd1, + 0xe1, 0x68, 0x00, 0x29, 0x03, 0xd1, 0x23, 0x6a, 0x00, 0x2b, 0x16, 0xd1, + 0x0f, 0xe0, 0x05, 0xaa, 0x00, 0xf0, 0xe2, 0xf8, 0x00, 0x28, 0x58, 0xd0, + 0x62, 0x6a, 0x05, 0x9b, 0x01, 0x32, 0xd2, 0x7f, 0x10, 0x2a, 0x01, 0xd1, + 0x2c, 0x4a, 0x00, 0xe0, 0x2c, 0x4a, 0x93, 0x42, 0x05, 0xd3, 0x20, 0x1c, + 0xff, 0xf7, 0x3c, 0xfc, 0x00, 0x28, 0xaa, 0xd1, 0x98, 0xe7, 0xe3, 0x60, + 0xa7, 0xe7, 0x00, 0x2e, 0x0f, 0xd1, 0x23, 0x69, 0xe1, 0x69, 0x8b, 0x42, + 0x0b, 0xd3, 0x00, 0xf0, 0x59, 0xf8, 0x00, 0x28, 0x8c, 0xd0, 0x1f, 0x4b, + 0x01, 0x21, 0x1f, 0x60, 0x21, 0x4b, 0x1a, 0x78, 0x0a, 0x43, 0x1a, 0x70, + 0x06, 0xe0, 0x38, 0x1c, 0x01, 0x21, 0x00, 0xf0, 0x75, 0xf8, 0x00, 0x28, + 0x00, 0xd1, 0x7d, 0xe7, 0x1c, 0x4b, 0x2a, 0x1c, 0xf6, 0x18, 0x02, 0x9b, + 0xf1, 0x18, 0x33, 0x1c, 0x8b, 0x42, 0x04, 0xd0, 0x10, 0x78, 0x01, 0x32, + 0x18, 0x70, 0x01, 0x33, 0xf8, 0xe7, 0x9e, 0x1b, 0xad, 0x19, 0xa8, 0xe7, + 0xe1, 0x69, 0x23, 0x7a, 0x8e, 0x42, 0x01, 0xd9, 0xe6, 0x61, 0x06, 0xe0, + 0x12, 0x4a, 0x12, 0x68, 0x00, 0x2a, 0x06, 0xd0, 0x03, 0x9a, 0x00, 0x2a, + 0x03, 0xd0, 0x80, 0x22, 0x52, 0x42, 0x13, 0x43, 0x23, 0x72, 0x23, 0x7a, + 0x19, 0x07, 0x01, 0xd4, 0x03, 0x98, 0x06, 0xe0, 0x20, 0x1c, 0xff, 0xf7, + 0x8b, 0xfd, 0x00, 0x28, 0x00, 0xd1, 0x51, 0xe7, 0xf6, 0xe7, 0x07, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, + 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, 0x50, 0x03, 0x00, 0x20, + 0x50, 0x01, 0x00, 0x20, 0x44, 0x01, 0x00, 0x20, 0x07, 0xb5, 0x6b, 0x46, + 0xd9, 0x71, 0x07, 0x33, 0x19, 0x1c, 0x01, 0x22, 0xff, 0xf7, 0x22, 0xff, + 0x0e, 0xbd, 0x00, 0x00, 0xf8, 0xb5, 0x0f, 0x4f, 0x01, 0x20, 0x3b, 0x78, + 0x00, 0x2b, 0x18, 0xd0, 0x0d, 0x4e, 0x0e, 0x4b, 0x0e, 0x4d, 0x19, 0x68, + 0x30, 0x68, 0x2a, 0x1c, 0xff, 0xf7, 0x80, 0xfb, 0x00, 0x28, 0x0e, 0xd0, + 0x0b, 0x4c, 0x21, 0x68, 0x00, 0x29, 0x07, 0xd0, 0x30, 0x68, 0x2a, 0x1c, + 0xff, 0xf7, 0x76, 0xfb, 0x00, 0x28, 0x04, 0xd0, 0x00, 0x23, 0x23, 0x60, + 0x00, 0x23, 0x3b, 0x70, 0x01, 0x20, 0xf8, 0xbd, 0x50, 0x03, 0x00, 0x20, + 0x4c, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x48, 0x01, 0x00, 0x20, 0x70, 0xb5, 0x0d, 0x4d, 0x04, 0x1c, 0x2b, 0x68, + 0x0e, 0x1c, 0x83, 0x42, 0x0e, 0xd0, 0xff, 0xf7, 0xcd, 0xff, 0x00, 0x28, + 0x01, 0xd1, 0x00, 0x20, 0x0d, 0xe0, 0x08, 0x4b, 0x21, 0x1c, 0x18, 0x68, + 0x07, 0x4a, 0xff, 0xf7, 0x25, 0xfb, 0x00, 0x28, 0xf5, 0xd0, 0x2c, 0x60, + 0x05, 0x4b, 0x01, 0x20, 0x1a, 0x78, 0x16, 0x43, 0x1e, 0x70, 0x70, 0xbd, + 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x50, 0x03, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xae, 0xff, + 0x00, 0x28, 0x0f, 0xd0, 0x00, 0x23, 0x08, 0x4a, 0x00, 0x21, 0x99, 0x54, + 0x80, 0x22, 0x01, 0x33, 0x92, 0x00, 0x93, 0x42, 0xf7, 0xd1, 0x05, 0x4b, + 0x01, 0x20, 0x1c, 0x60, 0x04, 0x4b, 0x1a, 0x78, 0x02, 0x43, 0x1a, 0x70, + 0x10, 0xbd, 0xc0, 0x46, 0x50, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, + 0x50, 0x03, 0x00, 0x20, 0xc3, 0x68, 0x70, 0xb5, 0x01, 0x33, 0x0c, 0x1c, + 0x15, 0x1c, 0x99, 0x42, 0x01, 0xd9, 0x00, 0x20, 0x21, 0xe0, 0x46, 0x1c, + 0xf1, 0x7f, 0xc2, 0x69, 0xe3, 0x09, 0x10, 0x29, 0x00, 0xd1, 0x23, 0x0a, + 0x98, 0x18, 0x0d, 0x4b, 0x1b, 0x68, 0x98, 0x42, 0x07, 0xd1, 0xf2, 0x7f, + 0x0b, 0x4b, 0x10, 0x2a, 0x09, 0xd1, 0xe4, 0xb2, 0x64, 0x00, 0x1b, 0x5b, + 0x0b, 0xe0, 0x00, 0x21, 0xff, 0xf7, 0x9e, 0xff, 0x00, 0x28, 0xf2, 0xd1, + 0xe3, 0xe7, 0x7f, 0x22, 0x14, 0x40, 0xa4, 0x00, 0x1b, 0x59, 0x1b, 0x01, + 0x1b, 0x09, 0x2b, 0x60, 0x01, 0x20, 0x70, 0xbd, 0x00, 0x00, 0x00, 0x20, + 0x50, 0x01, 0x00, 0x20, 0x73, 0xb5, 0x05, 0x1c, 0x01, 0x91, 0x16, 0x1c, + 0x00, 0x24, 0x28, 0x1c, 0x01, 0x99, 0x01, 0xaa, 0xff, 0xf7, 0xc6, 0xff, + 0x00, 0x28, 0x10, 0xd0, 0x2a, 0x7c, 0x80, 0x23, 0x9b, 0x00, 0x93, 0x40, + 0xe4, 0x18, 0x6b, 0x1c, 0xdb, 0x7f, 0x01, 0x9a, 0x10, 0x2b, 0x01, 0xd1, + 0x03, 0x4b, 0x00, 0xe0, 0x03, 0x4b, 0x9a, 0x42, 0xe9, 0xd3, 0x34, 0x60, + 0x01, 0x20, 0x76, 0xbd, 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, + 0xf7, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x01, 0x92, 0x01, 0x29, 0x32, 0xd9, + 0xc3, 0x68, 0x00, 0x20, 0x01, 0x33, 0x99, 0x42, 0x2e, 0xd8, 0x6f, 0x1c, + 0xfa, 0x7f, 0xee, 0x69, 0xcb, 0x09, 0x10, 0x2a, 0x00, 0xd1, 0x0b, 0x0a, + 0x9e, 0x19, 0x14, 0x4b, 0x1b, 0x68, 0x9e, 0x42, 0x08, 0xd1, 0xfa, 0x7f, + 0x12, 0x4b, 0x10, 0x2a, 0x0b, 0xd1, 0xe4, 0xb2, 0x01, 0x9a, 0x64, 0x00, + 0x1a, 0x53, 0x0b, 0xe0, 0x30, 0x1c, 0x00, 0x21, 0xff, 0xf7, 0x48, 0xff, + 0x00, 0x28, 0xf0, 0xd1, 0x12, 0xe0, 0x7f, 0x22, 0x14, 0x40, 0x01, 0x9a, + 0xa4, 0x00, 0x1a, 0x51, 0x09, 0x4b, 0x01, 0x20, 0x1a, 0x78, 0x02, 0x43, + 0x1a, 0x70, 0x2b, 0x7e, 0x83, 0x42, 0x05, 0xd9, 0xab, 0x68, 0xf6, 0x18, + 0x05, 0x4b, 0x1e, 0x60, 0x00, 0xe0, 0x00, 0x20, 0xfe, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, 0x50, 0x03, 0x00, 0x20, + 0x48, 0x01, 0x00, 0x20, 0xf0, 0xb5, 0x15, 0x68, 0x87, 0xb0, 0x06, 0x1c, + 0x02, 0x91, 0x17, 0x1c, 0x00, 0x2d, 0x03, 0xd0, 0x00, 0x21, 0x01, 0x35, + 0x01, 0x91, 0x06, 0xe0, 0x02, 0x9b, 0x05, 0x68, 0x01, 0x3b, 0x5a, 0x42, + 0x53, 0x41, 0xdb, 0xb2, 0x01, 0x93, 0xf2, 0x68, 0x00, 0x23, 0x01, 0x32, + 0x03, 0x92, 0x2c, 0x1c, 0x00, 0x93, 0x00, 0x99, 0xf2, 0x68, 0x91, 0x42, + 0x21, 0xd2, 0x03, 0x9b, 0x9c, 0x42, 0x01, 0xd9, 0x02, 0x24, 0x25, 0x1c, + 0x30, 0x1c, 0x21, 0x1c, 0x05, 0xaa, 0xff, 0xf7, 0x43, 0xff, 0x00, 0x28, + 0x15, 0xd0, 0x05, 0x99, 0x63, 0x1c, 0x00, 0x29, 0x01, 0xd0, 0x1d, 0x1c, + 0x03, 0xe0, 0x02, 0x99, 0x5a, 0x1b, 0x8a, 0x42, 0x04, 0xd0, 0x00, 0x9a, + 0x1c, 0x1c, 0x01, 0x32, 0x00, 0x92, 0xe0, 0xe7, 0x30, 0x1c, 0x21, 0x1c, + 0x13, 0x4a, 0xff, 0xf7, 0x7f, 0xff, 0x00, 0x28, 0x0b, 0xd1, 0x00, 0x20, + 0x1d, 0xe0, 0x63, 0x1e, 0x30, 0x1c, 0x19, 0x1c, 0x22, 0x1c, 0x00, 0x93, + 0xff, 0xf7, 0x74, 0xff, 0x00, 0x28, 0xf4, 0xd0, 0x00, 0x9c, 0xac, 0x42, + 0xf3, 0xd8, 0x39, 0x68, 0x00, 0x29, 0x06, 0xd1, 0x01, 0x99, 0x3d, 0x60, + 0x00, 0x29, 0x09, 0xd0, 0x01, 0x35, 0x35, 0x60, 0x06, 0xe0, 0x30, 0x1c, + 0x2a, 0x1c, 0xff, 0xf7, 0x61, 0xff, 0x00, 0x28, 0xf2, 0xd1, 0xe0, 0xe7, + 0x01, 0x20, 0x07, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0xff, 0xff, 0xff, 0x0f, + 0x02, 0x23, 0x37, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x03, 0x60, 0x28, 0x1c, + 0x21, 0x1c, 0x01, 0xaa, 0xff, 0xf7, 0xfc, 0xfe, 0x00, 0x28, 0x12, 0xd0, + 0x28, 0x1c, 0x21, 0x1c, 0x00, 0x22, 0xff, 0xf7, 0x47, 0xff, 0x00, 0x28, + 0x0b, 0xd0, 0x6b, 0x1c, 0xdb, 0x7f, 0x01, 0x9c, 0x10, 0x2b, 0x01, 0xd1, + 0x04, 0x4b, 0x00, 0xe0, 0x04, 0x4b, 0x9c, 0x42, 0xe7, 0xd3, 0x01, 0x20, + 0x00, 0xe0, 0x00, 0x20, 0x3e, 0xbd, 0xc0, 0x46, 0xf8, 0xff, 0x00, 0x00, + 0xf8, 0xff, 0xff, 0x0f, 0xf8, 0xb5, 0x44, 0x4b, 0x04, 0x1c, 0x15, 0x1c, + 0x19, 0x60, 0x29, 0xd0, 0x04, 0x2a, 0x01, 0xd9, 0x00, 0x20, 0x7d, 0xe0, + 0x00, 0x20, 0x01, 0x1c, 0xff, 0xf7, 0x90, 0xfe, 0x00, 0x28, 0xf7, 0xd0, + 0x2d, 0x01, 0x3d, 0x4b, 0xa9, 0x35, 0xff, 0x35, 0x5d, 0x19, 0xaa, 0x79, + 0xab, 0x1d, 0x50, 0x06, 0xee, 0xd1, 0xea, 0x7c, 0xa9, 0x7c, 0x12, 0x02, + 0x0a, 0x43, 0x29, 0x7d, 0x09, 0x04, 0x0a, 0x43, 0x69, 0x7d, 0x09, 0x06, + 0x0a, 0x43, 0x63, 0x2a, 0xe2, 0xd9, 0xaa, 0x7b, 0xed, 0x7b, 0x2d, 0x02, + 0x15, 0x43, 0x9a, 0x7a, 0xdb, 0x7a, 0x12, 0x04, 0x15, 0x43, 0x1b, 0x06, + 0x1d, 0x43, 0xd7, 0xd0, 0x28, 0x1c, 0x00, 0x21, 0xff, 0xf7, 0x6a, 0xfe, + 0x00, 0x28, 0xd1, 0xd0, 0x2a, 0x4b, 0x19, 0x7b, 0xda, 0x7a, 0x09, 0x02, + 0x11, 0x43, 0x80, 0x22, 0x92, 0x00, 0x91, 0x42, 0xc8, 0xd1, 0x1a, 0x7c, + 0x00, 0x2a, 0xc5, 0xd0, 0xd9, 0x89, 0x00, 0x29, 0xc2, 0xd0, 0x59, 0x7b, + 0x00, 0x29, 0xbf, 0xd0, 0x22, 0x76, 0x00, 0x22, 0x21, 0x71, 0x22, 0x74, + 0x22, 0x7c, 0x01, 0x20, 0x90, 0x40, 0x81, 0x42, 0x04, 0xd0, 0x50, 0x1c, + 0x20, 0x74, 0x07, 0x2a, 0xf6, 0xd9, 0xb1, 0xe7, 0xd9, 0x8a, 0x00, 0x29, + 0x00, 0xd1, 0x59, 0x6a, 0xa1, 0x60, 0xd8, 0x89, 0x28, 0x18, 0xe0, 0x61, + 0x1f, 0x69, 0x3e, 0x02, 0x36, 0x0c, 0x66, 0x84, 0xb7, 0xb2, 0x1e, 0x7c, + 0x71, 0x43, 0x0e, 0x18, 0x13, 0x48, 0x79, 0x01, 0x09, 0x18, 0x49, 0x12, + 0x71, 0x18, 0x66, 0x62, 0x61, 0x61, 0x18, 0x7d, 0xde, 0x7c, 0x00, 0x02, + 0x30, 0x43, 0x00, 0xd1, 0x18, 0x6a, 0x6d, 0x1a, 0x28, 0x18, 0xd0, 0x40, + 0x02, 0x1c, 0xe0, 0x60, 0x0b, 0x48, 0x61, 0x1c, 0x82, 0x42, 0x01, 0xd8, + 0x0c, 0x23, 0x07, 0xe0, 0x09, 0x48, 0x82, 0x42, 0x01, 0xd8, 0x10, 0x23, + 0x02, 0xe0, 0xdb, 0x6a, 0x63, 0x62, 0x20, 0x23, 0xcb, 0x77, 0x01, 0x20, + 0xf8, 0xbd, 0xc0, 0x46, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0xff, 0x01, 0x00, 0x00, 0xf4, 0x0f, 0x00, 0x00, 0xf4, 0xff, 0x00, 0x00, + 0x08, 0xb5, 0x05, 0x49, 0x05, 0x4a, 0x06, 0x48, 0x00, 0xf0, 0x10, 0xf8, + 0x05, 0x4b, 0x06, 0x49, 0x00, 0x22, 0x1a, 0x70, 0x5a, 0x54, 0x08, 0xbd, + 0x00, 0x50, 0x00, 0x00, 0x01, 0x04, 0x00, 0x00, 0x54, 0x03, 0x00, 0x20, + 0x6c, 0x03, 0x00, 0x20, 0x02, 0x04, 0x00, 0x00, 0x30, 0xb5, 0x09, 0x4c, + 0x09, 0x4b, 0xa5, 0x68, 0x6d, 0x03, 0x6d, 0x0f, 0xad, 0x00, 0xeb, 0x58, + 0x03, 0x60, 0xa4, 0x68, 0x01, 0x61, 0xa4, 0xb2, 0x44, 0x60, 0x5c, 0x43, + 0x9b, 0x00, 0x84, 0x60, 0xc3, 0x60, 0x42, 0x61, 0x30, 0xbd, 0xc0, 0x46, + 0x00, 0x40, 0x00, 0x41, 0x00, 0x55, 0x00, 0x00, 0xf7, 0xb5, 0x1f, 0x4e, + 0x80, 0x27, 0x75, 0x68, 0x03, 0x33, 0x3d, 0x43, 0x9b, 0x08, 0x75, 0x60, + 0x00, 0x2b, 0x34, 0xd0, 0x1b, 0x4d, 0x35, 0x80, 0x35, 0x7d, 0xef, 0x07, + 0xfc, 0xd5, 0x1d, 0x1c, 0x5f, 0x1b, 0x01, 0x97, 0x07, 0x68, 0xbf, 0x08, + 0xbc, 0x46, 0x01, 0x9f, 0x67, 0x45, 0x1f, 0xd2, 0x00, 0x2d, 0x1d, 0xd0, + 0x17, 0x78, 0x01, 0x3d, 0x01, 0x97, 0xff, 0x27, 0xbc, 0x43, 0x01, 0x9f, + 0x3c, 0x43, 0x57, 0x78, 0x3f, 0x02, 0x01, 0x97, 0x0f, 0x4f, 0x3c, 0x40, + 0x01, 0x9f, 0x3c, 0x43, 0x97, 0x78, 0x3f, 0x04, 0xbc, 0x46, 0x0d, 0x4f, + 0x3c, 0x40, 0xd7, 0x78, 0xa4, 0xb2, 0x3f, 0x06, 0x00, 0x97, 0x67, 0x46, + 0x3c, 0x43, 0x00, 0x9f, 0x04, 0x32, 0x3c, 0x43, 0x10, 0xc1, 0xd7, 0xe7, + 0x07, 0x4b, 0x33, 0x80, 0x33, 0x7d, 0xdf, 0x07, 0xfc, 0xd5, 0x2b, 0x1c, + 0xc8, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x44, 0xa5, 0xff, 0xff, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, 0x04, 0xa5, 0xff, 0xff, + 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, 0x1a, 0x80, 0x1a, 0x7d, + 0xd1, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x16, 0x1c, + 0xeb, 0x68, 0x28, 0x1c, 0x21, 0x1c, 0x9e, 0x42, 0x05, 0xd9, 0xff, 0xf7, + 0xe7, 0xff, 0xeb, 0x68, 0xe4, 0x18, 0xf6, 0x1a, 0xf4, 0xe7, 0xff, 0xf7, + 0xe1, 0xff, 0x70, 0xbd, 0x43, 0x7a, 0x00, 0x2b, 0x04, 0xd1, 0x83, 0x72, + 0xc3, 0x72, 0xc3, 0x60, 0x01, 0x23, 0x43, 0x72, 0x70, 0x47, 0x30, 0xb5, + 0x85, 0xb0, 0x04, 0x1c, 0x02, 0xad, 0x00, 0x68, 0x02, 0x91, 0x03, 0x92, + 0x00, 0xf0, 0xa0, 0xfc, 0x6b, 0x79, 0xe1, 0x79, 0x22, 0x7a, 0x00, 0x93, + 0x20, 0x68, 0x00, 0x23, 0x00, 0xf0, 0x3a, 0xfd, 0x29, 0x79, 0x20, 0x68, + 0x02, 0x9a, 0x00, 0xf0, 0x63, 0xfc, 0x20, 0x68, 0x00, 0xf0, 0x86, 0xfc, + 0x05, 0xb0, 0x30, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0x18, 0x26, 0xff, 0xf7, + 0xd7, 0xff, 0x20, 0x79, 0x33, 0x1c, 0x43, 0x43, 0x0d, 0x4d, 0x08, 0x21, + 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x22, 0xfb, 0xa0, 0x79, 0x33, 0x1c, + 0x43, 0x43, 0x08, 0x21, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x1a, 0xfb, + 0x60, 0x79, 0x08, 0x21, 0x46, 0x43, 0xad, 0x19, 0x69, 0x56, 0x00, 0xf0, + 0x13, 0xfb, 0x04, 0x4b, 0x20, 0x1c, 0x06, 0xcb, 0xff, 0xf7, 0xc3, 0xff, + 0x70, 0xbd, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, 0x70, 0x07, 0x00, 0x20, + 0x07, 0xb5, 0x83, 0x7a, 0x00, 0x91, 0x01, 0x92, 0x00, 0x2b, 0x0d, 0xd0, + 0x9a, 0x07, 0x06, 0xd5, 0xef, 0xf3, 0x10, 0x83, 0x5a, 0x42, 0x53, 0x41, + 0xc3, 0x72, 0x72, 0xb6, 0x04, 0xe0, 0xda, 0x07, 0x02, 0xd5, 0x82, 0x89, + 0x03, 0x4b, 0x9a, 0x60, 0x00, 0x99, 0x01, 0x9a, 0xff, 0xf7, 0xa5, 0xff, + 0x07, 0xbd, 0xc0, 0x46, 0x00, 0x18, 0x00, 0x40, 0x83, 0x7a, 0x00, 0x2b, + 0x0b, 0xd0, 0x9a, 0x07, 0x04, 0xd5, 0xc3, 0x7a, 0x00, 0x2b, 0x06, 0xd0, + 0x62, 0xb6, 0x04, 0xe0, 0xda, 0x07, 0x02, 0xd5, 0x82, 0x89, 0x01, 0x4b, + 0xda, 0x60, 0x70, 0x47, 0x00, 0x18, 0x00, 0x40, 0x08, 0xb5, 0x00, 0x68, + 0x00, 0xf0, 0x3d, 0xfc, 0x08, 0xbd, 0x00, 0x00, 0x10, 0x4b, 0x11, 0x4a, + 0x11, 0x49, 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x10, 0x4b, + 0x19, 0x60, 0x0a, 0x21, 0x19, 0x71, 0x09, 0x21, 0x99, 0x71, 0x08, 0x21, + 0x59, 0x71, 0x03, 0x21, 0x5a, 0x72, 0xda, 0x71, 0x19, 0x72, 0x0b, 0x4b, + 0x5a, 0x72, 0x0b, 0x4a, 0xd9, 0x71, 0x1a, 0x60, 0x1b, 0x22, 0x1a, 0x71, + 0x1d, 0x22, 0x9a, 0x71, 0x1a, 0x22, 0x5a, 0x71, 0x01, 0x22, 0x1a, 0x72, + 0x70, 0x47, 0xc0, 0x46, 0x70, 0x07, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, + 0x18, 0x09, 0x00, 0x20, 0x78, 0x07, 0x00, 0x20, 0x88, 0x07, 0x00, 0x20, + 0x1c, 0x09, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x08, 0xfe, + 0x08, 0xbd, 0xc0, 0x46, 0x98, 0x07, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, + 0x00, 0xf0, 0x00, 0xfe, 0x08, 0xbd, 0xc0, 0x46, 0x54, 0x08, 0x00, 0x20, + 0x7f, 0xb5, 0x19, 0x49, 0x19, 0x48, 0x00, 0xf0, 0x41, 0xfb, 0x19, 0x49, + 0x19, 0x48, 0x00, 0xf0, 0x3d, 0xfb, 0x19, 0x4c, 0x19, 0x49, 0x20, 0x1c, + 0x00, 0xf0, 0x38, 0xfb, 0x18, 0x49, 0x19, 0x48, 0x00, 0xf0, 0x34, 0xfb, + 0x18, 0x49, 0x19, 0x48, 0x00, 0xf0, 0x30, 0xfb, 0x18, 0x4e, 0x19, 0x49, + 0x30, 0x1c, 0x00, 0xf0, 0x2b, 0xfb, 0x01, 0x25, 0x03, 0x23, 0x31, 0x1c, + 0x00, 0x93, 0x01, 0x95, 0x0d, 0x22, 0x0e, 0x23, 0x14, 0x48, 0x00, 0xf0, + 0xf7, 0xfc, 0x02, 0x23, 0x01, 0x93, 0x1c, 0x23, 0x02, 0x93, 0x1d, 0x23, + 0x00, 0x95, 0x03, 0x93, 0x21, 0x1c, 0x1b, 0x22, 0x1a, 0x23, 0x0f, 0x48, + 0x00, 0xf0, 0xac, 0xfc, 0x7f, 0xbd, 0xc0, 0x46, 0x00, 0x08, 0x00, 0x42, + 0x14, 0x09, 0x00, 0x20, 0x00, 0x0c, 0x00, 0x42, 0x18, 0x09, 0x00, 0x20, + 0x1c, 0x09, 0x00, 0x20, 0x00, 0x10, 0x00, 0x42, 0x00, 0x14, 0x00, 0x42, + 0x10, 0x09, 0x00, 0x20, 0x00, 0x18, 0x00, 0x42, 0x20, 0x09, 0x00, 0x20, + 0x24, 0x09, 0x00, 0x20, 0x00, 0x1c, 0x00, 0x42, 0x98, 0x07, 0x00, 0x20, + 0x54, 0x08, 0x00, 0x20, 0xfe, 0xe7, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x4b, + 0x1b, 0x68, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, 0x08, 0xbd, 0xc0, 0x46, + 0x28, 0x09, 0x00, 0x20, 0x38, 0xb5, 0x0f, 0x49, 0x0f, 0x4c, 0xa1, 0x42, + 0x04, 0xd1, 0x00, 0xf0, 0x4f, 0xf8, 0xfe, 0xf7, 0xa5, 0xfa, 0x0b, 0xe0, + 0x0c, 0x4d, 0x8d, 0x42, 0xf7, 0xd0, 0x00, 0x23, 0xca, 0x18, 0xe8, 0x18, + 0xa2, 0x42, 0x04, 0xd2, 0x00, 0x68, 0x04, 0x33, 0x10, 0x60, 0xf7, 0xe7, + 0xfe, 0xe7, 0x90, 0x42, 0xeb, 0xd0, 0x06, 0x4b, 0x06, 0x4a, 0x93, 0x42, + 0xe7, 0xd2, 0x00, 0x22, 0x04, 0xc3, 0xf9, 0xe7, 0x00, 0x00, 0x00, 0x20, + 0xa0, 0x00, 0x00, 0x20, 0x48, 0x59, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x20, + 0x0c, 0x0e, 0x00, 0x20, 0x08, 0xb5, 0x00, 0xf0, 0x26, 0xf8, 0x00, 0x28, + 0x01, 0xd1, 0x00, 0xf0, 0x17, 0xf8, 0x08, 0xbd, 0x01, 0x4b, 0x18, 0x68, + 0x70, 0x47, 0xc0, 0x46, 0x2c, 0x09, 0x00, 0x20, 0x70, 0xb5, 0x04, 0x1e, + 0x08, 0xd0, 0x05, 0x4b, 0x1d, 0x68, 0x1e, 0x1c, 0x00, 0xf0, 0x12, 0xf8, + 0x33, 0x68, 0x5b, 0x1b, 0xa3, 0x42, 0xf9, 0xd3, 0x70, 0xbd, 0xc0, 0x46, + 0x2c, 0x09, 0x00, 0x20, 0x08, 0xb5, 0x03, 0x4b, 0x1a, 0x68, 0x01, 0x32, + 0x1a, 0x60, 0x00, 0xf0, 0x61, 0xfa, 0x08, 0xbd, 0x2c, 0x09, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, 0x70, 0xb5, 0x49, 0x4a, + 0x1e, 0x21, 0x53, 0x68, 0x02, 0x20, 0x8b, 0x43, 0x03, 0x43, 0x47, 0x49, + 0x53, 0x60, 0x8b, 0x69, 0x08, 0x24, 0x23, 0x43, 0x8b, 0x61, 0x45, 0x4c, + 0x45, 0x4b, 0x9c, 0x82, 0x9c, 0x8a, 0x20, 0x43, 0x98, 0x82, 0x10, 0x1c, + 0xda, 0x68, 0x94, 0x07, 0xfc, 0xd5, 0x42, 0x4a, 0x01, 0x24, 0x14, 0x70, + 0x14, 0x78, 0xe5, 0x07, 0x04, 0xd5, 0x3f, 0x4c, 0x64, 0x78, 0x64, 0xb2, + 0x00, 0x2c, 0xf7, 0xdb, 0x01, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, + 0x00, 0x2c, 0xfb, 0xdb, 0x3a, 0x4d, 0x39, 0x4c, 0x65, 0x60, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x82, 0x25, 0x35, 0x4c, 0xed, 0x01, + 0x65, 0x80, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x02, 0x24, + 0x9c, 0x84, 0xdc, 0x68, 0xe6, 0x06, 0xfc, 0xd5, 0x31, 0x4d, 0x2e, 0x4c, + 0xe5, 0x62, 0xdd, 0x68, 0x2c, 0x4c, 0xee, 0x06, 0xfb, 0xd5, 0xa5, 0x8c, + 0x2e, 0x4e, 0x35, 0x43, 0xa5, 0x84, 0xdd, 0x68, 0x28, 0x4c, 0xee, 0x06, + 0xfb, 0xd5, 0xa5, 0x8c, 0x02, 0x26, 0x35, 0x43, 0xa5, 0x84, 0xdc, 0x68, + 0x25, 0x06, 0xfc, 0xd5, 0x23, 0x4c, 0xe4, 0x68, 0x66, 0x06, 0xf8, 0xd5, + 0xdc, 0x68, 0xe5, 0x06, 0xfc, 0xd5, 0x00, 0x24, 0x94, 0x60, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x22, 0x4d, 0x1d, 0x4c, 0x65, 0x60, + 0x55, 0x78, 0x1c, 0x4c, 0x6d, 0xb2, 0x00, 0x2d, 0xfa, 0xdb, 0x1e, 0x6a, + 0x1e, 0x4d, 0x35, 0x40, 0x1d, 0x62, 0x1d, 0x6a, 0x80, 0x26, 0xb5, 0x43, + 0x1d, 0x62, 0x03, 0x23, 0xa3, 0x60, 0x1b, 0x4b, 0x63, 0x60, 0x53, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x00, 0x23, 0x0b, 0x72, 0x18, 0x4a, + 0x4b, 0x72, 0x8b, 0x72, 0xcb, 0x72, 0x17, 0x4b, 0xff, 0x21, 0x1a, 0x60, + 0x16, 0x4b, 0x17, 0x4a, 0x1b, 0x68, 0x12, 0x68, 0x5c, 0x01, 0xd2, 0x0e, + 0x21, 0x40, 0x11, 0x43, 0x9a, 0x06, 0x52, 0x0f, 0x12, 0x02, 0x0b, 0x1c, + 0x13, 0x43, 0x12, 0x4a, 0x13, 0x85, 0x43, 0x68, 0x80, 0x22, 0x13, 0x43, + 0x43, 0x60, 0x70, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x00, 0x04, 0x00, 0x40, + 0x0c, 0x06, 0x00, 0x00, 0x00, 0x08, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, + 0x01, 0x05, 0x01, 0x00, 0xb9, 0x05, 0xff, 0x7d, 0x04, 0x0a, 0x00, 0x00, + 0x00, 0x07, 0x03, 0x00, 0xff, 0xfc, 0xff, 0xff, 0x03, 0x06, 0x01, 0x00, + 0x00, 0x6c, 0xdc, 0x02, 0x04, 0x00, 0x00, 0x20, 0x24, 0x60, 0x80, 0x00, + 0x20, 0x60, 0x80, 0x00, 0x00, 0x40, 0x00, 0x42, 0x31, 0x4b, 0xfa, 0x21, + 0x18, 0x68, 0x10, 0xb5, 0x89, 0x00, 0x00, 0xf0, 0x13, 0xff, 0x2f, 0x4b, + 0x01, 0x38, 0x98, 0x42, 0x24, 0xd8, 0x2e, 0x4a, 0x2e, 0x4b, 0x50, 0x60, + 0x18, 0x6a, 0xc0, 0x21, 0x00, 0x02, 0x00, 0x0a, 0x09, 0x06, 0x01, 0x43, + 0x19, 0x62, 0x00, 0x24, 0x07, 0x21, 0x94, 0x60, 0x11, 0x60, 0x19, 0x6a, + 0x80, 0x22, 0x09, 0x02, 0x09, 0x0a, 0x12, 0x06, 0x0a, 0x43, 0x1a, 0x62, + 0x25, 0x4b, 0xfc, 0x21, 0x1a, 0x6a, 0x0a, 0x43, 0x1a, 0x62, 0x19, 0x6a, + 0xfc, 0x22, 0x92, 0x01, 0x0a, 0x43, 0x1a, 0x62, 0x19, 0x6a, 0xa0, 0x22, + 0xd2, 0x02, 0x0a, 0x43, 0x1a, 0x62, 0x00, 0xe0, 0xfe, 0xe7, 0x20, 0x1c, + 0x00, 0x21, 0x01, 0x34, 0x00, 0xf0, 0x70, 0xf8, 0x0f, 0x2c, 0xf8, 0xd1, + 0x1a, 0x4c, 0x63, 0x78, 0x5b, 0xb2, 0x00, 0x2b, 0xfa, 0xdb, 0x19, 0x4b, + 0x63, 0x80, 0x19, 0x4b, 0x5a, 0x7e, 0xd2, 0x09, 0x01, 0x2a, 0xfa, 0xd0, + 0xe4, 0x22, 0xd2, 0x00, 0x9a, 0x80, 0x3f, 0x22, 0xda, 0x70, 0x59, 0x7e, + 0x13, 0x4a, 0xc9, 0x09, 0x01, 0x29, 0xfa, 0xd0, 0xc0, 0x23, 0x5b, 0x01, + 0x00, 0x20, 0x13, 0x61, 0x90, 0x70, 0x00, 0xf0, 0x23, 0xf8, 0x63, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x0d, 0x4a, 0x09, 0x4b, 0x5a, 0x80, + 0x0c, 0x4b, 0xda, 0x79, 0xd2, 0x09, 0x01, 0x2a, 0xfa, 0xd0, 0x41, 0x22, + 0x5a, 0x70, 0x10, 0xbd, 0x04, 0x00, 0x00, 0x20, 0xff, 0xff, 0xff, 0x00, + 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, 0x00, 0x04, 0x00, 0x40, + 0x00, 0x0c, 0x00, 0x40, 0x1e, 0x40, 0x00, 0x00, 0x00, 0x40, 0x00, 0x42, + 0x21, 0x40, 0x00, 0x00, 0x00, 0x48, 0x00, 0x42, 0x00, 0xb5, 0x14, 0x4a, + 0x51, 0x7e, 0x13, 0x1c, 0xc9, 0x09, 0x01, 0x29, 0xf9, 0xd0, 0x01, 0x38, + 0x04, 0x28, 0x13, 0xd8, 0x19, 0x69, 0x10, 0x4a, 0x0a, 0x40, 0x1a, 0x61, + 0x5a, 0x78, 0x0f, 0x21, 0x8a, 0x43, 0x00, 0xf0, 0x85, 0xfe, 0x03, 0x05, + 0x09, 0x07, 0x03, 0x00, 0x01, 0x21, 0x02, 0xe0, 0x03, 0x21, 0x00, 0xe0, + 0x02, 0x21, 0x0a, 0x43, 0x5a, 0x70, 0x0a, 0xe0, 0x11, 0x69, 0xf0, 0x23, + 0x1b, 0x05, 0x0b, 0x43, 0x13, 0x61, 0x53, 0x78, 0x0f, 0x21, 0x8b, 0x43, + 0x02, 0x21, 0x0b, 0x43, 0x53, 0x70, 0x00, 0xbd, 0x00, 0x40, 0x00, 0x42, + 0xff, 0xff, 0xff, 0xf0, 0x10, 0xb5, 0x18, 0x24, 0x02, 0x1c, 0x20, 0x1c, + 0x50, 0x43, 0x27, 0x4b, 0x18, 0x18, 0x00, 0x7a, 0x40, 0xb2, 0x01, 0x30, + 0x46, 0xd0, 0x03, 0x29, 0x44, 0xd8, 0x08, 0x1c, 0x21, 0x1c, 0x00, 0xf0, + 0x59, 0xfe, 0x02, 0x33, 0x11, 0x21, 0x62, 0x43, 0x98, 0x56, 0x9a, 0x18, + 0xc3, 0x01, 0x1f, 0x48, 0x52, 0x68, 0x1b, 0x18, 0x99, 0x18, 0x40, 0x31, + 0x02, 0x20, 0x08, 0x70, 0x01, 0x21, 0x91, 0x40, 0x59, 0x60, 0x2f, 0xe0, + 0x62, 0x43, 0x98, 0x56, 0x18, 0x49, 0x9a, 0x18, 0x52, 0x68, 0xc3, 0x01, + 0x5b, 0x18, 0x99, 0x18, 0x40, 0x31, 0x06, 0x20, 0x08, 0x70, 0x01, 0x21, + 0x91, 0x40, 0x59, 0x60, 0x99, 0x61, 0x1f, 0xe0, 0x51, 0x43, 0x5a, 0x56, + 0x10, 0x48, 0x59, 0x18, 0x4b, 0x68, 0xd2, 0x01, 0x11, 0x18, 0xc8, 0x18, + 0x40, 0x30, 0x06, 0x24, 0x04, 0x70, 0x01, 0x20, 0x98, 0x40, 0x48, 0x60, + 0x0b, 0x49, 0x52, 0x18, 0x50, 0x60, 0x0d, 0xe0, 0x62, 0x43, 0x98, 0x56, + 0x9a, 0x18, 0xc3, 0x01, 0x06, 0x48, 0x52, 0x68, 0x1b, 0x18, 0x99, 0x18, + 0x40, 0x31, 0x02, 0x20, 0x08, 0x70, 0x01, 0x21, 0x91, 0x40, 0x99, 0x60, + 0x10, 0xbd, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x10, 0x44, 0x00, 0x41, 0x18, 0x23, 0x58, 0x43, 0x13, 0x4a, 0xf0, 0xb5, + 0x13, 0x18, 0x08, 0x24, 0x1c, 0x57, 0x01, 0x34, 0x1f, 0xd0, 0x82, 0x56, + 0x10, 0x4e, 0xd2, 0x01, 0x5d, 0x68, 0x01, 0x24, 0x90, 0x19, 0x23, 0x1c, + 0x86, 0x68, 0xab, 0x40, 0x1e, 0x42, 0x0b, 0xd1, 0x0e, 0x1c, 0x77, 0x1e, + 0xbe, 0x41, 0x40, 0x19, 0x34, 0x40, 0x40, 0x30, 0xa5, 0x00, 0x04, 0x78, + 0x04, 0x26, 0xb4, 0x43, 0x2c, 0x43, 0x04, 0x70, 0x00, 0x29, 0x03, 0xd1, + 0x05, 0x49, 0x52, 0x18, 0x53, 0x60, 0x02, 0xe0, 0x02, 0x4e, 0x92, 0x19, + 0x93, 0x61, 0xf0, 0xbd, 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x10, 0x44, 0x00, 0x41, 0x18, 0x22, 0x42, 0x43, 0xf8, 0xb5, 0x2d, 0x4d, + 0x08, 0x24, 0xaa, 0x18, 0x14, 0x57, 0x03, 0x1c, 0x62, 0x1c, 0x50, 0xd0, + 0x48, 0x1c, 0x00, 0x24, 0x0c, 0x28, 0x4c, 0xd8, 0x00, 0xf0, 0xd0, 0xfd, + 0x07, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x0a, 0x0a, 0x0a, + 0x0a, 0x00, 0x01, 0x24, 0x64, 0x42, 0x40, 0xe0, 0x09, 0x29, 0x02, 0xd1, + 0x18, 0x1c, 0x00, 0x21, 0x03, 0xe0, 0x0a, 0x29, 0x04, 0xd1, 0x18, 0x1c, + 0x02, 0x21, 0xff, 0xf7, 0x51, 0xff, 0x23, 0xe0, 0x00, 0x24, 0x0b, 0x29, + 0x31, 0xd1, 0x18, 0x1c, 0x01, 0x21, 0xff, 0xf7, 0x49, 0xff, 0x2c, 0xe0, + 0x18, 0x22, 0x53, 0x43, 0xea, 0x18, 0x52, 0x68, 0xeb, 0x56, 0x01, 0x20, + 0x14, 0x1c, 0x04, 0x40, 0x55, 0x08, 0xdb, 0x01, 0x00, 0x2c, 0x11, 0xd0, + 0x12, 0x4c, 0x1b, 0x19, 0x5d, 0x19, 0x30, 0x35, 0x2e, 0x78, 0x0c, 0x01, + 0x0f, 0x21, 0x31, 0x40, 0x21, 0x43, 0x9a, 0x18, 0xc9, 0xb2, 0x29, 0x70, + 0x40, 0x32, 0x13, 0x78, 0x18, 0x43, 0x10, 0x70, 0x00, 0x24, 0x0e, 0xe0, + 0x09, 0x4e, 0x0f, 0x27, 0x9b, 0x19, 0x5d, 0x19, 0x30, 0x35, 0x2e, 0x78, + 0x9a, 0x18, 0xbe, 0x43, 0x31, 0x43, 0xc9, 0xb2, 0x29, 0x70, 0x40, 0x32, + 0x13, 0x78, 0x18, 0x43, 0x10, 0x70, 0x20, 0x1c, 0xf8, 0xbd, 0xc0, 0x46, + 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0xf7, 0xb5, 0x8a, 0x18, + 0x06, 0x1c, 0x0d, 0x1c, 0x01, 0x92, 0x0c, 0x1c, 0x01, 0x9b, 0x67, 0x1b, + 0x9c, 0x42, 0x07, 0xd0, 0x33, 0x68, 0x21, 0x78, 0x1b, 0x68, 0x30, 0x1c, + 0x98, 0x47, 0x01, 0x34, 0x00, 0x28, 0xf3, 0xd1, 0x38, 0x1c, 0xfe, 0xbd, + 0x15, 0x4a, 0x13, 0x68, 0x58, 0x1c, 0x25, 0xd0, 0x01, 0x3b, 0x13, 0x60, + 0x00, 0x2b, 0x21, 0xd1, 0x72, 0xb6, 0x12, 0x4a, 0x12, 0x4b, 0x04, 0x32, + 0x9a, 0x42, 0x07, 0xd8, 0xbf, 0xf3, 0x4f, 0x8f, 0x10, 0x4a, 0x11, 0x4b, + 0xda, 0x60, 0xbf, 0xf3, 0x4f, 0x8f, 0x11, 0xe0, 0x0f, 0x4b, 0x19, 0x7d, + 0xc8, 0x07, 0xfb, 0xd5, 0x18, 0x8b, 0x20, 0x21, 0xff, 0x31, 0x92, 0x08, + 0x52, 0x00, 0x01, 0x43, 0x19, 0x83, 0xda, 0x61, 0x0a, 0x4a, 0x1a, 0x80, + 0x1a, 0x7d, 0xd1, 0x07, 0xfc, 0xd5, 0xe5, 0xe7, 0xc0, 0x46, 0xfd, 0xe7, + 0x70, 0x47, 0xc0, 0x46, 0x08, 0x00, 0x00, 0x20, 0x00, 0x20, 0x00, 0x00, + 0x03, 0x02, 0x00, 0x00, 0x04, 0x00, 0xfa, 0x05, 0x00, 0xed, 0x00, 0xe0, + 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, 0x01, 0x60, 0x70, 0x47, + 0xf7, 0xb5, 0x08, 0xac, 0x26, 0x78, 0x04, 0x68, 0x9d, 0x1e, 0x27, 0x68, + 0x6c, 0x1e, 0xa5, 0x41, 0xec, 0xb2, 0x92, 0x07, 0x05, 0x68, 0x3a, 0x43, + 0x27, 0x06, 0x3a, 0x43, 0x2a, 0x60, 0x02, 0x68, 0x07, 0x25, 0x29, 0x40, + 0x50, 0x68, 0xb5, 0x01, 0x00, 0x2c, 0x00, 0xd0, 0x5c, 0x03, 0x29, 0x43, + 0x01, 0x43, 0x0c, 0x43, 0x54, 0x60, 0xf7, 0xbd, 0x30, 0xb5, 0x03, 0x68, + 0xc0, 0x25, 0x1c, 0x68, 0xad, 0x03, 0x12, 0x05, 0x2a, 0x40, 0x22, 0x43, + 0xc0, 0x24, 0xa4, 0x02, 0x09, 0x04, 0x21, 0x40, 0x11, 0x43, 0x19, 0x60, + 0x03, 0x68, 0x5a, 0x68, 0x14, 0x43, 0x5c, 0x60, 0x30, 0xbd, 0x03, 0x68, + 0x01, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, 0x11, 0x68, + 0x01, 0x23, 0x19, 0x42, 0xfb, 0xd1, 0xd1, 0x69, 0x19, 0x42, 0xf8, 0xd1, + 0x70, 0x47, 0x03, 0x68, 0x02, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, + 0x02, 0x68, 0xd3, 0x69, 0x99, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, + 0x1a, 0x7e, 0xd1, 0x07, 0x02, 0xd4, 0x1a, 0x7e, 0x91, 0x07, 0xfc, 0xd5, + 0x70, 0x47, 0x03, 0x68, 0x00, 0x22, 0x5a, 0x83, 0x70, 0x47, 0x03, 0x68, + 0x18, 0x7e, 0x40, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, + 0xc0, 0x09, 0x70, 0x47, 0x03, 0x68, 0x80, 0x22, 0x19, 0x7e, 0x52, 0x42, + 0x0a, 0x43, 0x1a, 0x76, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x01, 0x23, + 0x18, 0x40, 0x70, 0x47, 0x03, 0x68, 0x18, 0x8d, 0xc0, 0xb2, 0x70, 0x47, + 0x03, 0x68, 0x1a, 0x7e, 0x01, 0x20, 0x02, 0x42, 0xfb, 0xd0, 0x19, 0x85, + 0x70, 0x47, 0x03, 0x68, 0x01, 0x22, 0x9a, 0x75, 0x70, 0x47, 0x03, 0x68, + 0x01, 0x22, 0x1a, 0x75, 0x70, 0x47, 0x00, 0x00, 0x70, 0xb5, 0x03, 0x68, + 0x01, 0x26, 0x8d, 0x07, 0xed, 0x0f, 0x31, 0x40, 0x1c, 0x68, 0x6d, 0x07, + 0x09, 0x07, 0x29, 0x43, 0x21, 0x43, 0x19, 0x60, 0x04, 0x68, 0x51, 0x00, + 0x03, 0x48, 0x00, 0xf0, 0xab, 0xfc, 0x01, 0x38, 0xc0, 0xb2, 0x20, 0x73, + 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x6c, 0xdc, 0x02, 0x03, 0x68, 0x01, 0x21, + 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, 0x11, 0x68, 0x01, 0x23, + 0x19, 0x42, 0xfb, 0xd1, 0xd1, 0x69, 0x19, 0x42, 0xf8, 0xd1, 0x70, 0x47, + 0x03, 0x68, 0x02, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, + 0xd3, 0x69, 0x99, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, 0xda, 0x69, + 0x91, 0x07, 0xfc, 0xd4, 0x1a, 0x68, 0x02, 0x21, 0x8a, 0x43, 0x1a, 0x60, + 0x70, 0x47, 0x03, 0x68, 0x9a, 0x6a, 0x52, 0x0a, 0x52, 0x02, 0x11, 0x43, + 0x99, 0x62, 0x03, 0x68, 0x1a, 0x7e, 0x51, 0x07, 0xfc, 0xd5, 0x98, 0x6a, + 0xc0, 0xb2, 0x70, 0x47, 0x03, 0x68, 0x22, 0x4a, 0x30, 0xb5, 0x93, 0x42, + 0x11, 0xd0, 0x21, 0x4a, 0x93, 0x42, 0x11, 0xd0, 0x20, 0x4a, 0x93, 0x42, + 0x11, 0xd0, 0x20, 0x4a, 0x93, 0x42, 0x11, 0xd0, 0x1f, 0x4a, 0x93, 0x42, + 0x11, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x30, 0xd1, 0x0e, 0x23, 0x19, 0x22, + 0x0d, 0xe0, 0x09, 0x23, 0x14, 0x22, 0x0a, 0xe0, 0x0a, 0x23, 0x15, 0x22, + 0x07, 0xe0, 0x0b, 0x23, 0x16, 0x22, 0x04, 0xe0, 0x0c, 0x23, 0x17, 0x22, + 0x01, 0xe0, 0x0d, 0x23, 0x18, 0x22, 0xdc, 0xb2, 0x15, 0x49, 0x01, 0x20, + 0x9b, 0x08, 0xa0, 0x40, 0x9b, 0x00, 0x08, 0x60, 0x5b, 0x18, 0x03, 0x20, + 0xc0, 0x21, 0x89, 0x00, 0x04, 0x40, 0x5d, 0x58, 0xe0, 0x00, 0xff, 0x24, + 0x84, 0x40, 0xa5, 0x43, 0x2c, 0x1c, 0xc0, 0x25, 0x85, 0x40, 0x28, 0x1c, + 0x20, 0x43, 0x58, 0x50, 0x80, 0x23, 0xdb, 0x01, 0x1a, 0x43, 0x0a, 0x4b, + 0x5a, 0x80, 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, 0x30, 0xbd, + 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, 0x00, 0x10, 0x00, 0x42, + 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, 0x00, 0x1c, 0x00, 0x42, + 0x00, 0xe1, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x40, 0xf8, 0xb5, 0x04, 0x1c, + 0x15, 0x1c, 0x0e, 0x1c, 0x1f, 0x1c, 0xff, 0xf7, 0xa3, 0xff, 0x20, 0x1c, + 0xff, 0xf7, 0x0d, 0xff, 0xb1, 0x00, 0x1c, 0x22, 0x0a, 0x40, 0x69, 0x07, + 0x23, 0x68, 0x09, 0x0c, 0x0a, 0x43, 0x1a, 0x60, 0x22, 0x68, 0x84, 0x23, + 0x93, 0x75, 0x01, 0x2e, 0x1a, 0xd1, 0x08, 0x21, 0x01, 0x2d, 0x00, 0xd1, + 0x10, 0x21, 0x0c, 0x4b, 0x79, 0x43, 0x18, 0x68, 0xc0, 0x00, 0x00, 0xf0, + 0xff, 0xfb, 0x23, 0x68, 0x07, 0x21, 0x9a, 0x89, 0x01, 0x40, 0xd2, 0x04, + 0x49, 0x03, 0xd2, 0x0c, 0x0a, 0x43, 0x9a, 0x81, 0x23, 0x68, 0x00, 0x04, + 0xc2, 0x0c, 0x98, 0x89, 0x40, 0x0b, 0x40, 0x03, 0x10, 0x43, 0x98, 0x81, + 0xf8, 0xbd, 0xc0, 0x46, 0x04, 0x00, 0x00, 0x20, 0xf7, 0xb5, 0x01, 0x93, + 0x08, 0xab, 0x04, 0x1c, 0x1f, 0x78, 0x0d, 0x1c, 0x16, 0x1c, 0xff, 0xf7, + 0x3d, 0xff, 0x20, 0x1c, 0xff, 0xf7, 0x68, 0xff, 0xbf, 0x07, 0x0c, 0x22, + 0x17, 0x43, 0xc0, 0x22, 0x92, 0x03, 0x36, 0x05, 0x16, 0x40, 0xc0, 0x22, + 0x92, 0x02, 0x2d, 0x04, 0x23, 0x68, 0x3e, 0x43, 0x01, 0x99, 0x15, 0x40, + 0x35, 0x43, 0x07, 0x22, 0x1d, 0x60, 0x0a, 0x40, 0x80, 0x21, 0x23, 0x68, + 0x89, 0x02, 0x0a, 0x43, 0x5a, 0x60, 0xf7, 0xbd, 0x01, 0x20, 0x70, 0x47, + 0x08, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, 0x98, 0x47, 0x08, 0xbd, + 0x13, 0x04, 0x00, 0x00, 0x82, 0x6d, 0x43, 0x6d, 0x9a, 0x42, 0x03, 0xd0, + 0x83, 0x6d, 0xc0, 0x18, 0x00, 0x7d, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, + 0x70, 0x47, 0x10, 0xb5, 0x04, 0x1c, 0x00, 0x69, 0xff, 0xf7, 0xa3, 0xfe, + 0x00, 0x23, 0x22, 0x1c, 0x63, 0x65, 0x9c, 0x32, 0xa3, 0x65, 0xa0, 0x34, + 0x13, 0x60, 0x23, 0x60, 0x10, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x87, 0xb0, + 0x01, 0x93, 0x0c, 0xab, 0x1b, 0x78, 0x00, 0x25, 0x02, 0x93, 0x0d, 0xab, + 0x1b, 0x78, 0x40, 0x26, 0x03, 0x93, 0x0e, 0xab, 0x1b, 0x78, 0x04, 0x1c, + 0x04, 0x93, 0x0f, 0xab, 0x1b, 0x78, 0x0f, 0x1c, 0x05, 0x93, 0xfa, 0x23, + 0x9b, 0x00, 0x83, 0x60, 0x12, 0x4b, 0x00, 0x92, 0x08, 0x33, 0x03, 0x60, + 0x45, 0x60, 0x29, 0x1c, 0x32, 0x1c, 0x14, 0x30, 0x00, 0xf0, 0x24, 0xfc, + 0x20, 0x1c, 0x65, 0x65, 0x32, 0x1c, 0xa5, 0x65, 0x29, 0x1c, 0x5c, 0x30, + 0x00, 0xf0, 0x1c, 0xfc, 0x00, 0x9a, 0x23, 0x1c, 0x9c, 0x33, 0x1d, 0x60, + 0x5d, 0x60, 0x27, 0x61, 0x1a, 0x72, 0x01, 0x9a, 0x20, 0x1c, 0x5a, 0x72, + 0x02, 0x9a, 0x9a, 0x72, 0x03, 0x9a, 0xda, 0x72, 0x04, 0x9a, 0x1a, 0x73, + 0x05, 0x9a, 0x1a, 0x77, 0x07, 0xb0, 0xf0, 0xbd, 0x80, 0x58, 0x00, 0x00, + 0x30, 0xb5, 0x85, 0xb0, 0x04, 0x1c, 0x08, 0xa8, 0x05, 0x78, 0x09, 0xa8, + 0x00, 0x78, 0x00, 0x95, 0x01, 0x90, 0xff, 0x20, 0x02, 0x90, 0x03, 0x90, + 0x20, 0x1c, 0xff, 0xf7, 0xb3, 0xff, 0x20, 0x1c, 0x05, 0xb0, 0x30, 0xbd, + 0xf0, 0x23, 0x08, 0x1c, 0x18, 0x40, 0x30, 0x38, 0x43, 0x42, 0x58, 0x41, + 0x70, 0x47, 0xf0, 0x23, 0x1b, 0x01, 0x19, 0x40, 0x80, 0x23, 0x9b, 0x00, + 0x99, 0x42, 0x0c, 0xd0, 0xc0, 0x23, 0x9b, 0x00, 0x99, 0x42, 0x06, 0xd0, + 0x80, 0x23, 0x5b, 0x00, 0x05, 0x20, 0x99, 0x42, 0x04, 0xd0, 0x00, 0x20, + 0x02, 0xe0, 0x07, 0x20, 0x00, 0xe0, 0x06, 0x20, 0x70, 0x47, 0x0f, 0x23, + 0x19, 0x40, 0x01, 0x29, 0x05, 0xd0, 0x02, 0x39, 0x4b, 0x42, 0x4b, 0x41, + 0x02, 0x20, 0xc0, 0x1a, 0x00, 0xe0, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, + 0xf0, 0xb5, 0x03, 0x1c, 0x85, 0xb0, 0x03, 0x91, 0xa4, 0x33, 0x04, 0x1c, + 0x18, 0x27, 0x18, 0x78, 0x3b, 0x1c, 0x43, 0x43, 0x34, 0x4e, 0x08, 0x21, + 0xf3, 0x18, 0x59, 0x56, 0x15, 0x1c, 0xff, 0xf7, 0x2d, 0xfd, 0x23, 0x1c, + 0xa5, 0x33, 0x18, 0x78, 0x3b, 0x1c, 0x43, 0x43, 0x08, 0x21, 0xf3, 0x18, + 0x59, 0x56, 0xff, 0xf7, 0x23, 0xfd, 0x23, 0x1c, 0xa7, 0x33, 0x1b, 0x78, + 0x02, 0x2b, 0x0a, 0xd1, 0x23, 0x1c, 0xb8, 0x33, 0x18, 0x78, 0xff, 0x28, + 0x05, 0xd0, 0x47, 0x43, 0x08, 0x21, 0xf7, 0x19, 0x79, 0x56, 0xff, 0xf7, + 0x13, 0xfd, 0x27, 0x1c, 0xa8, 0x37, 0x38, 0x78, 0xff, 0x28, 0x1a, 0xd0, + 0x01, 0x21, 0xff, 0xf7, 0x81, 0xfc, 0x3b, 0x78, 0x18, 0x22, 0x5a, 0x43, + 0xb3, 0x56, 0x1f, 0x4f, 0xdb, 0x01, 0x21, 0x1c, 0xac, 0x31, 0xd8, 0x19, + 0x08, 0x60, 0x1d, 0x49, 0xb6, 0x18, 0x5b, 0x18, 0x21, 0x1c, 0x72, 0x68, + 0xb0, 0x31, 0x0b, 0x60, 0x01, 0x21, 0x91, 0x40, 0x0a, 0x1c, 0x21, 0x1c, + 0xb4, 0x31, 0x0a, 0x60, 0x1a, 0x60, 0x01, 0x21, 0x0a, 0x1c, 0x03, 0x9b, + 0x20, 0x69, 0xff, 0xf7, 0xb7, 0xfe, 0x29, 0x1c, 0x20, 0x1c, 0xff, 0xf7, + 0x88, 0xff, 0x29, 0x1c, 0x07, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x99, 0xff, + 0x29, 0x1c, 0x06, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x77, 0xff, 0x39, 0x1c, + 0x00, 0x90, 0x33, 0x1c, 0x20, 0x69, 0x01, 0x22, 0xff, 0xf7, 0x8a, 0xfd, + 0x23, 0x1c, 0xa7, 0x33, 0x19, 0x78, 0x01, 0x3b, 0x1a, 0x78, 0x20, 0x69, + 0xff, 0xf7, 0x9e, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0xbc, 0xfd, 0x05, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, 0x18, 0x44, 0x00, 0x41, + 0x14, 0x44, 0x00, 0x41, 0x02, 0x6c, 0x43, 0x6c, 0xd0, 0x1a, 0x00, 0xd5, + 0x40, 0x30, 0x70, 0x47, 0x10, 0xb5, 0x04, 0x1c, 0x20, 0x1c, 0x5c, 0x30, + 0xff, 0xf7, 0xf4, 0xff, 0x00, 0x28, 0xf9, 0xd1, 0x20, 0x69, 0xff, 0xf7, + 0xac, 0xfd, 0x10, 0xbd, 0x08, 0xb5, 0x14, 0x30, 0xff, 0xf7, 0xea, 0xff, + 0x08, 0xbd, 0x02, 0x6c, 0x43, 0x6c, 0x9a, 0x42, 0x04, 0xdb, 0x03, 0x6c, + 0x40, 0x6c, 0xc0, 0x1a, 0x3f, 0x30, 0x03, 0xe0, 0x42, 0x6c, 0x03, 0x6c, + 0xd0, 0x1a, 0x01, 0x38, 0x70, 0x47, 0x08, 0xb5, 0x5c, 0x30, 0xff, 0xf7, + 0xee, 0xff, 0x08, 0xbd, 0x38, 0xb5, 0x04, 0x1c, 0x00, 0x69, 0xff, 0xf7, + 0x9a, 0xfd, 0x00, 0x28, 0x1f, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0xaa, 0xfd, + 0x63, 0x6d, 0x3f, 0x22, 0x01, 0x33, 0x13, 0x40, 0xa2, 0x6d, 0x93, 0x42, + 0x03, 0xd0, 0x62, 0x6d, 0xa2, 0x18, 0x10, 0x75, 0x63, 0x65, 0x23, 0x1c, + 0xa8, 0x33, 0x1b, 0x78, 0xff, 0x2b, 0x0c, 0xd0, 0x20, 0x1c, 0x14, 0x30, + 0xff, 0xf7, 0xcf, 0xff, 0x09, 0x28, 0x06, 0xdc, 0x23, 0x1c, 0x22, 0x1c, + 0xac, 0x33, 0xb4, 0x32, 0x1b, 0x68, 0x12, 0x68, 0x1a, 0x60, 0x20, 0x69, + 0xff, 0xf7, 0x85, 0xfd, 0x00, 0x28, 0x20, 0xd0, 0x25, 0x1c, 0x5c, 0x35, + 0x28, 0x1c, 0xff, 0xf7, 0xa5, 0xff, 0x03, 0x1c, 0x20, 0x69, 0x00, 0x2b, + 0x15, 0xd0, 0x23, 0x1c, 0x22, 0x1c, 0xa0, 0x33, 0x9c, 0x32, 0x19, 0x68, + 0x12, 0x68, 0x91, 0x42, 0x07, 0xd0, 0x1a, 0x68, 0xa9, 0x5c, 0x1a, 0x68, + 0x3f, 0x25, 0x01, 0x32, 0x2a, 0x40, 0x1a, 0x60, 0x01, 0xe0, 0x01, 0x21, + 0x49, 0x42, 0xc9, 0xb2, 0xff, 0xf7, 0x6e, 0xfd, 0x01, 0xe0, 0xff, 0xf7, + 0x76, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x54, 0xfd, 0x00, 0x28, 0x05, 0xd0, + 0x20, 0x69, 0xff, 0xf7, 0x53, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x43, 0xfd, + 0x38, 0xbd, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x1c, 0x00, 0x69, 0x0d, 0x1c, + 0xff, 0xf7, 0x4f, 0xfd, 0x00, 0x28, 0x0f, 0xd0, 0x20, 0x1c, 0x5c, 0x30, + 0xff, 0xf7, 0x70, 0xff, 0x00, 0x28, 0x40, 0xd0, 0x08, 0xe0, 0xef, 0xf3, + 0x10, 0x83, 0xda, 0x07, 0x23, 0xd4, 0x21, 0x4b, 0x5a, 0x68, 0xd2, 0x05, + 0xd2, 0x0d, 0x0b, 0xd1, 0x23, 0x1c, 0x9c, 0x33, 0x21, 0x1c, 0x1e, 0x68, + 0xa0, 0x31, 0x0a, 0x68, 0x01, 0x36, 0x3f, 0x20, 0x06, 0x40, 0x96, 0x42, + 0xeb, 0xd0, 0x1b, 0xe0, 0x10, 0x3a, 0xd2, 0xb2, 0x53, 0xb2, 0x00, 0x2b, + 0x08, 0xda, 0x0f, 0x23, 0x1a, 0x40, 0x08, 0x3a, 0x15, 0x4b, 0x92, 0x08, + 0x92, 0x00, 0xd2, 0x18, 0x53, 0x68, 0x04, 0xe0, 0x9b, 0x08, 0xc0, 0x33, + 0x12, 0x4a, 0x9b, 0x00, 0x9b, 0x58, 0x20, 0x69, 0xff, 0xf7, 0x1b, 0xfd, + 0x00, 0x28, 0xdb, 0xd0, 0x20, 0x1c, 0xff, 0xf7, 0x67, 0xff, 0xd7, 0xe7, + 0x1a, 0x68, 0x09, 0x68, 0x01, 0x32, 0x02, 0x40, 0x8a, 0x42, 0x04, 0xd0, + 0x19, 0x68, 0x20, 0x1c, 0x5c, 0x30, 0x45, 0x54, 0x1a, 0x60, 0x20, 0x69, + 0xff, 0xf7, 0x17, 0xfd, 0x03, 0xe0, 0x20, 0x69, 0x29, 0x1c, 0xff, 0xf7, + 0x0b, 0xfd, 0x01, 0x20, 0x70, 0xbd, 0xc0, 0x46, 0x00, 0xed, 0x00, 0xe0, + 0x18, 0xed, 0x00, 0xe0, 0x00, 0xe1, 0x00, 0xe0, 0x38, 0xb5, 0x82, 0x6d, + 0x43, 0x6d, 0x04, 0x1c, 0x9a, 0x42, 0x08, 0xd0, 0x83, 0x6d, 0x3f, 0x22, + 0xc3, 0x18, 0x1d, 0x7d, 0x83, 0x6d, 0x01, 0x33, 0x13, 0x40, 0x83, 0x65, + 0x01, 0xe0, 0x01, 0x25, 0x6d, 0x42, 0x23, 0x1c, 0xa8, 0x33, 0x1b, 0x78, + 0xff, 0x2b, 0x0b, 0xd0, 0x20, 0x1c, 0x14, 0x30, 0xff, 0xf7, 0x1d, 0xff, + 0x0a, 0x28, 0x05, 0xdd, 0x23, 0x1c, 0xb0, 0x33, 0xb4, 0x34, 0x1b, 0x68, + 0x22, 0x68, 0x1a, 0x60, 0x28, 0x1c, 0x38, 0xbd, 0x3f, 0x20, 0x70, 0x47, + 0x13, 0xb5, 0x02, 0x68, 0x6b, 0x46, 0xd9, 0x71, 0x07, 0x33, 0x54, 0x68, + 0x19, 0x1c, 0x01, 0x22, 0xa0, 0x47, 0x16, 0xbd, 0x08, 0xb5, 0x00, 0x69, + 0x02, 0x21, 0x00, 0xf0, 0x49, 0xf8, 0x08, 0xbd, 0x08, 0xb5, 0x00, 0x69, + 0x03, 0x21, 0x00, 0xf0, 0x59, 0xf8, 0x08, 0xbd, 0x38, 0xb5, 0x0d, 0x1c, + 0x04, 0x1c, 0x13, 0x1c, 0x00, 0x69, 0x03, 0x21, 0x2a, 0x1c, 0x00, 0xf0, + 0xf1, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x01, 0x23, 0x63, 0x60, 0x38, 0xbd, + 0x10, 0xb5, 0x05, 0x4c, 0x23, 0x68, 0x5a, 0x1c, 0x04, 0xd1, 0x03, 0x68, + 0x5b, 0x69, 0x98, 0x47, 0x20, 0x60, 0x03, 0x1c, 0x18, 0x1c, 0x10, 0xbd, + 0x0c, 0x00, 0x00, 0x20, 0x07, 0x4a, 0x08, 0xb5, 0x13, 0x68, 0x59, 0x1c, + 0x04, 0xd0, 0x01, 0x21, 0x49, 0x42, 0x11, 0x60, 0x18, 0x1c, 0x03, 0xe0, + 0x00, 0x69, 0x02, 0x21, 0x00, 0xf0, 0xc2, 0xf8, 0x08, 0xbd, 0xc0, 0x46, + 0x0c, 0x00, 0x00, 0x20, 0x06, 0x4b, 0xfa, 0x21, 0x89, 0x00, 0x99, 0x60, + 0x05, 0x49, 0x00, 0x22, 0x08, 0x31, 0x19, 0x60, 0x04, 0x49, 0x5a, 0x60, + 0x19, 0x61, 0x1a, 0x76, 0x70, 0x47, 0xc0, 0x46, 0x30, 0x09, 0x00, 0x20, + 0xb8, 0x58, 0x00, 0x00, 0xf0, 0x0c, 0x00, 0x20, 0x08, 0xb5, 0x08, 0x4b, + 0x8a, 0x00, 0xd0, 0x58, 0x00, 0x28, 0x03, 0xd0, 0x03, 0x68, 0x9b, 0x68, + 0x98, 0x47, 0x06, 0xe0, 0xc9, 0xb2, 0x04, 0x4b, 0x49, 0x01, 0x59, 0x18, + 0x88, 0x68, 0x80, 0x04, 0x80, 0x0c, 0x08, 0xbd, 0xd4, 0x0c, 0x00, 0x20, + 0xf4, 0x0c, 0x00, 0x20, 0x10, 0xb5, 0x0c, 0x1c, 0xff, 0xf7, 0xe6, 0xff, + 0x00, 0x28, 0x0c, 0xd0, 0x06, 0x4b, 0xe1, 0xb2, 0x1b, 0x68, 0x08, 0x31, + 0x49, 0x01, 0x59, 0x18, 0x4a, 0x79, 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, + 0x4b, 0x71, 0x02, 0x23, 0xcb, 0x71, 0x10, 0xbd, 0xf4, 0x0c, 0x00, 0x20, + 0x10, 0xb5, 0xc9, 0xb2, 0x0c, 0x48, 0x49, 0x01, 0x43, 0x18, 0x9a, 0x68, + 0x92, 0x04, 0x92, 0x0c, 0x3f, 0x2a, 0x08, 0xd9, 0x14, 0x1c, 0x9a, 0x68, + 0x40, 0x3c, 0xa4, 0x04, 0x92, 0x0b, 0xa4, 0x0c, 0x92, 0x03, 0x22, 0x43, + 0x02, 0xe0, 0x9a, 0x68, 0x92, 0x0b, 0x92, 0x03, 0x9a, 0x60, 0x41, 0x18, + 0x88, 0x68, 0xc0, 0xb2, 0x10, 0xbd, 0xc0, 0x46, 0xf4, 0x0c, 0x00, 0x20, + 0xf0, 0xb5, 0x1c, 0x1c, 0x2a, 0x4b, 0x85, 0xb0, 0x1b, 0x68, 0x06, 0x1c, + 0x0d, 0x1c, 0x02, 0x92, 0x00, 0x2b, 0x46, 0xd0, 0x27, 0x4b, 0x8a, 0x00, + 0xd0, 0x58, 0x00, 0x28, 0x05, 0xd0, 0x03, 0x68, 0x02, 0x99, 0x5b, 0x68, + 0x22, 0x1c, 0x98, 0x47, 0x3f, 0xe0, 0x30, 0x1c, 0xff, 0xf7, 0x9e, 0xff, + 0xa0, 0x42, 0x04, 0xd2, 0x30, 0x1c, 0x29, 0x1c, 0xff, 0xf7, 0x98, 0xff, + 0x04, 0x1c, 0x29, 0x1c, 0x30, 0x1c, 0xff, 0xf7, 0xbf, 0xff, 0x1c, 0x4f, + 0xe9, 0xb2, 0x4a, 0x01, 0x01, 0x91, 0x39, 0x68, 0x03, 0x92, 0x8b, 0x18, + 0xff, 0x33, 0x5a, 0x7a, 0x01, 0x21, 0x0a, 0x43, 0x17, 0x49, 0x5a, 0x72, + 0xab, 0x01, 0xc9, 0x18, 0x02, 0x98, 0x22, 0x1c, 0x00, 0xf0, 0x69, 0xf9, + 0x00, 0x2c, 0x1b, 0xd0, 0x30, 0x1c, 0x29, 0x1c, 0xff, 0xf7, 0x7a, 0xff, + 0x00, 0x28, 0x15, 0xd1, 0x01, 0x9b, 0x3a, 0x68, 0x08, 0x33, 0x5b, 0x01, + 0xd3, 0x18, 0x19, 0x79, 0x40, 0x20, 0x01, 0x43, 0x19, 0x71, 0x01, 0x21, + 0xd9, 0x71, 0x03, 0x99, 0x53, 0x18, 0xff, 0x33, 0x9a, 0x7a, 0x01, 0x21, + 0x0a, 0x43, 0x9a, 0x72, 0x02, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x00, 0xe0, + 0x20, 0x1c, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0xf8, 0x0d, 0x00, 0x20, + 0xd4, 0x0c, 0x00, 0x20, 0xf4, 0x0c, 0x00, 0x20, 0x14, 0x0b, 0x00, 0x20, + 0x13, 0xb5, 0x6c, 0x46, 0x07, 0x34, 0x22, 0x1c, 0x01, 0x23, 0xff, 0xf7, + 0x99, 0xff, 0x01, 0x28, 0x01, 0xd1, 0x20, 0x78, 0x01, 0xe0, 0x01, 0x20, + 0x40, 0x42, 0x16, 0xbd, 0xf0, 0xb5, 0x1c, 0x1c, 0x3a, 0x4b, 0x85, 0xb0, + 0x1b, 0x68, 0x0e, 0x1c, 0x02, 0x92, 0x00, 0x2b, 0x60, 0xd0, 0x80, 0x23, + 0xdb, 0x01, 0x9c, 0x42, 0x5c, 0xd8, 0x00, 0x22, 0x00, 0x92, 0x00, 0x2c, + 0x56, 0xd0, 0x34, 0x4d, 0xf7, 0xb2, 0x2b, 0x68, 0x01, 0x93, 0x3b, 0x1c, + 0x08, 0x33, 0x01, 0x9a, 0x5b, 0x01, 0xd3, 0x18, 0x9b, 0x79, 0xdb, 0x09, + 0x1a, 0xd0, 0x2f, 0x4b, 0x2f, 0x49, 0x18, 0x68, 0x00, 0xf0, 0x76, 0xf8, + 0x2e, 0x4b, 0x17, 0x21, 0x58, 0x43, 0x00, 0xf0, 0x71, 0xf8, 0x3b, 0x1c, + 0x08, 0x33, 0x01, 0x9a, 0x5b, 0x01, 0xd3, 0x18, 0xdb, 0x79, 0x9a, 0x07, + 0x08, 0xd4, 0x29, 0x4b, 0x9a, 0x5d, 0x00, 0x2a, 0x38, 0xd1, 0x42, 0x1e, + 0x00, 0x28, 0x35, 0xd0, 0x10, 0x1c, 0xee, 0xe7, 0x24, 0x4b, 0x00, 0x22, + 0x9a, 0x55, 0x25, 0x1e, 0x3f, 0x2d, 0x00, 0xd9, 0x3f, 0x25, 0x22, 0x4a, + 0xb3, 0x01, 0xd3, 0x18, 0x18, 0x1c, 0x02, 0x99, 0x2a, 0x1c, 0x03, 0x93, + 0x00, 0xf0, 0xe9, 0xf8, 0x18, 0x4a, 0x7b, 0x01, 0xd3, 0x18, 0x03, 0x9a, + 0xa9, 0x04, 0x5a, 0x61, 0x9a, 0x69, 0x89, 0x0c, 0x92, 0x0b, 0x92, 0x03, + 0x0a, 0x43, 0x9a, 0x61, 0x3b, 0x1c, 0x01, 0x9a, 0x08, 0x33, 0x5b, 0x01, + 0xd3, 0x18, 0x02, 0x22, 0xda, 0x71, 0x59, 0x79, 0x80, 0x22, 0x52, 0x42, + 0x0a, 0x43, 0x5a, 0x71, 0x00, 0x9b, 0x02, 0x9a, 0x5b, 0x19, 0x52, 0x19, + 0x00, 0x93, 0x64, 0x1b, 0x02, 0x92, 0xa6, 0xe7, 0x00, 0x98, 0x0b, 0xe0, + 0x01, 0x20, 0x08, 0xe0, 0x01, 0x22, 0x9a, 0x55, 0x7b, 0x01, 0xed, 0x18, + 0xab, 0x69, 0x10, 0x1c, 0x9b, 0x0b, 0x9b, 0x03, 0xab, 0x61, 0x40, 0x42, + 0x05, 0xb0, 0xf0, 0xbd, 0xf8, 0x0d, 0x00, 0x20, 0xf4, 0x0c, 0x00, 0x20, + 0x04, 0x00, 0x00, 0x20, 0x40, 0x42, 0x0f, 0x00, 0x70, 0x11, 0x01, 0x00, + 0x4c, 0x09, 0x00, 0x20, 0x54, 0x09, 0x00, 0x20, 0x01, 0x4a, 0x02, 0x4b, + 0x1a, 0x60, 0x70, 0x47, 0x00, 0x50, 0x00, 0x41, 0xf4, 0x0c, 0x00, 0x20, + 0x02, 0xb4, 0x71, 0x46, 0x49, 0x08, 0x49, 0x00, 0x09, 0x5c, 0x49, 0x00, + 0x8e, 0x44, 0x02, 0xbc, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x29, 0x34, 0xd0, + 0x01, 0x23, 0x00, 0x22, 0x10, 0xb4, 0x88, 0x42, 0x2c, 0xd3, 0x01, 0x24, + 0x24, 0x07, 0xa1, 0x42, 0x04, 0xd2, 0x81, 0x42, 0x02, 0xd2, 0x09, 0x01, + 0x1b, 0x01, 0xf8, 0xe7, 0xe4, 0x00, 0xa1, 0x42, 0x04, 0xd2, 0x81, 0x42, + 0x02, 0xd2, 0x49, 0x00, 0x5b, 0x00, 0xf8, 0xe7, 0x88, 0x42, 0x01, 0xd3, + 0x40, 0x1a, 0x1a, 0x43, 0x4c, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, + 0x5c, 0x08, 0x22, 0x43, 0x8c, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, + 0x9c, 0x08, 0x22, 0x43, 0xcc, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, + 0xdc, 0x08, 0x22, 0x43, 0x00, 0x28, 0x03, 0xd0, 0x1b, 0x09, 0x01, 0xd0, + 0x09, 0x09, 0xe3, 0xe7, 0x10, 0x1c, 0x10, 0xbc, 0x70, 0x47, 0x00, 0x28, + 0x01, 0xd0, 0x00, 0x20, 0xc0, 0x43, 0x07, 0xb4, 0x02, 0x48, 0x02, 0xa1, + 0x40, 0x18, 0x02, 0x90, 0x03, 0xbd, 0xc0, 0x46, 0x19, 0x00, 0x00, 0x00, + 0x00, 0x29, 0xf0, 0xd0, 0x03, 0xb5, 0xff, 0xf7, 0xb9, 0xff, 0x0e, 0xbc, + 0x42, 0x43, 0x89, 0x1a, 0x18, 0x47, 0xc0, 0x46, 0x70, 0x47, 0xc0, 0x46, + 0x70, 0xb5, 0x0e, 0x4b, 0x0e, 0x4d, 0x00, 0x24, 0xed, 0x1a, 0xad, 0x10, + 0x1e, 0x1c, 0xac, 0x42, 0x04, 0xd0, 0xa3, 0x00, 0xf3, 0x58, 0x98, 0x47, + 0x01, 0x34, 0xf8, 0xe7, 0x00, 0xf0, 0x32, 0xf9, 0x08, 0x4b, 0x09, 0x4d, + 0x00, 0x24, 0xed, 0x1a, 0xad, 0x10, 0x1e, 0x1c, 0xac, 0x42, 0x04, 0xd0, + 0xa3, 0x00, 0xf3, 0x58, 0x98, 0x47, 0x01, 0x34, 0xf8, 0xe7, 0x70, 0xbd, + 0x74, 0x00, 0x00, 0x20, 0x74, 0x00, 0x00, 0x20, 0x74, 0x00, 0x00, 0x20, + 0x98, 0x00, 0x00, 0x20, 0x08, 0xb5, 0x03, 0x4b, 0x01, 0x1c, 0x18, 0x68, + 0x00, 0xf0, 0x76, 0xf8, 0x08, 0xbd, 0xc0, 0x46, 0x70, 0x00, 0x00, 0x20, + 0x08, 0xb5, 0x03, 0x4b, 0x01, 0x1c, 0x18, 0x68, 0x00, 0xf0, 0x24, 0xf8, + 0x08, 0xbd, 0xc0, 0x46, 0x70, 0x00, 0x00, 0x20, 0x30, 0xb5, 0x00, 0x23, + 0x93, 0x42, 0x08, 0xd0, 0xc5, 0x5c, 0x01, 0x33, 0xcc, 0x18, 0x01, 0x3c, + 0x24, 0x78, 0xa5, 0x42, 0xf6, 0xd0, 0x28, 0x1b, 0x00, 0xe0, 0x00, 0x20, + 0x30, 0xbd, 0x10, 0xb5, 0x00, 0x23, 0x93, 0x42, 0x03, 0xd0, 0xcc, 0x5c, + 0xc4, 0x54, 0x01, 0x33, 0xf9, 0xe7, 0x10, 0xbd, 0x03, 0x1c, 0x82, 0x18, + 0x93, 0x42, 0x02, 0xd0, 0x19, 0x70, 0x01, 0x33, 0xfa, 0xe7, 0x70, 0x47, + 0x30, 0xb5, 0x00, 0x29, 0x40, 0xd0, 0x04, 0x39, 0x0b, 0x68, 0x00, 0x2b, + 0x00, 0xda, 0xc9, 0x18, 0x1e, 0x4a, 0x13, 0x68, 0x14, 0x1c, 0x00, 0x2b, + 0x02, 0xd1, 0x4b, 0x60, 0x11, 0x60, 0x33, 0xe0, 0x99, 0x42, 0x0f, 0xd2, + 0x08, 0x68, 0x0a, 0x18, 0x9a, 0x42, 0x05, 0xd1, 0x13, 0x68, 0x52, 0x68, + 0xc0, 0x18, 0x08, 0x60, 0x4a, 0x60, 0x00, 0xe0, 0x4b, 0x60, 0x21, 0x60, + 0x24, 0xe0, 0x8a, 0x42, 0x03, 0xd8, 0x13, 0x1c, 0x5a, 0x68, 0x00, 0x2a, + 0xf9, 0xd1, 0x1d, 0x68, 0x5c, 0x19, 0x8c, 0x42, 0x0b, 0xd1, 0x09, 0x68, + 0x69, 0x18, 0x58, 0x18, 0x19, 0x60, 0x90, 0x42, 0x14, 0xd1, 0x14, 0x68, + 0x52, 0x68, 0x09, 0x19, 0x19, 0x60, 0x5a, 0x60, 0x0e, 0xe0, 0x8c, 0x42, + 0x02, 0xd9, 0x0c, 0x23, 0x03, 0x60, 0x09, 0xe0, 0x08, 0x68, 0x0c, 0x18, + 0x94, 0x42, 0x03, 0xd1, 0x14, 0x68, 0x52, 0x68, 0x00, 0x19, 0x08, 0x60, + 0x4a, 0x60, 0x59, 0x60, 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x0e, 0x00, 0x20, + 0x70, 0xb5, 0x03, 0x23, 0xcd, 0x1c, 0x9d, 0x43, 0x08, 0x35, 0x06, 0x1c, + 0x0c, 0x2d, 0x01, 0xd2, 0x0c, 0x25, 0x01, 0xe0, 0x00, 0x2d, 0x3f, 0xdb, + 0x8d, 0x42, 0x3d, 0xd3, 0x20, 0x4b, 0x1c, 0x68, 0x1a, 0x1c, 0x21, 0x1c, + 0x00, 0x29, 0x13, 0xd0, 0x08, 0x68, 0x43, 0x1b, 0x0d, 0xd4, 0x0b, 0x2b, + 0x02, 0xd9, 0x0b, 0x60, 0xcc, 0x18, 0x1e, 0xe0, 0x8c, 0x42, 0x02, 0xd1, + 0x63, 0x68, 0x13, 0x60, 0x1a, 0xe0, 0x48, 0x68, 0x60, 0x60, 0x0c, 0x1c, + 0x16, 0xe0, 0x0c, 0x1c, 0x49, 0x68, 0xe9, 0xe7, 0x14, 0x4c, 0x20, 0x68, + 0x00, 0x28, 0x03, 0xd1, 0x30, 0x1c, 0x00, 0xf0, 0x25, 0xf8, 0x20, 0x60, + 0x30, 0x1c, 0x29, 0x1c, 0x00, 0xf0, 0x20, 0xf8, 0x43, 0x1c, 0x15, 0xd0, + 0xc4, 0x1c, 0x03, 0x23, 0x9c, 0x43, 0x84, 0x42, 0x0a, 0xd1, 0x25, 0x60, + 0x20, 0x1c, 0x0b, 0x30, 0x07, 0x22, 0x23, 0x1d, 0x90, 0x43, 0xc3, 0x1a, + 0x0b, 0xd0, 0x5a, 0x42, 0xe2, 0x50, 0x08, 0xe0, 0x21, 0x1a, 0x30, 0x1c, + 0x00, 0xf0, 0x0a, 0xf8, 0x01, 0x30, 0xee, 0xd1, 0x0c, 0x23, 0x33, 0x60, + 0x00, 0x20, 0x70, 0xbd, 0x00, 0x0e, 0x00, 0x20, 0xfc, 0x0d, 0x00, 0x20, + 0x38, 0xb5, 0x07, 0x4c, 0x00, 0x23, 0x05, 0x1c, 0x08, 0x1c, 0x23, 0x60, + 0x00, 0xf0, 0x2a, 0xf8, 0x43, 0x1c, 0x03, 0xd1, 0x23, 0x68, 0x00, 0x2b, + 0x00, 0xd0, 0x2b, 0x60, 0x38, 0xbd, 0xc0, 0x46, 0x08, 0x0e, 0x00, 0x20, + 0xc9, 0xb2, 0x03, 0x78, 0x00, 0x2b, 0x03, 0xd0, 0x8b, 0x42, 0x04, 0xd0, + 0x01, 0x30, 0xf8, 0xe7, 0x00, 0x29, 0x00, 0xd0, 0x18, 0x1c, 0x70, 0x47, + 0x30, 0xb5, 0x03, 0x1c, 0x00, 0x2a, 0x07, 0xd0, 0x0c, 0x78, 0x01, 0x33, + 0x5d, 0x1e, 0x01, 0x3a, 0x2c, 0x70, 0x01, 0x31, 0x00, 0x2c, 0xf5, 0xd1, + 0x9a, 0x18, 0x93, 0x42, 0x03, 0xd0, 0x00, 0x21, 0x19, 0x70, 0x01, 0x33, + 0xf9, 0xe7, 0x30, 0xbd, 0x09, 0x4a, 0x13, 0x68, 0x00, 0x2b, 0x0c, 0xd0, + 0x18, 0x18, 0x69, 0x46, 0x88, 0x42, 0x02, 0xd8, 0x10, 0x60, 0x18, 0x1c, + 0x70, 0x47, 0x05, 0x4b, 0x0c, 0x22, 0x01, 0x20, 0x1a, 0x60, 0x40, 0x42, + 0xf8, 0xe7, 0x03, 0x4b, 0x13, 0x60, 0xef, 0xe7, 0x04, 0x0e, 0x00, 0x20, + 0x08, 0x0e, 0x00, 0x20, 0x0c, 0x0e, 0x00, 0x20, 0xf8, 0xb5, 0xc0, 0x46, + 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, 0xf8, 0xb5, 0xc0, 0x46, + 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, 0x55, 0x50, 0x44, 0x41, + 0x54, 0x45, 0x2e, 0x42, 0x49, 0x4e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x1f, 0x22, 0x00, 0x00, 0x33, 0x22, 0x00, 0x00, + 0x19, 0x22, 0x00, 0x00, 0x5d, 0x22, 0x00, 0x00, 0x61, 0x23, 0x00, 0x00, + 0x8d, 0x22, 0x00, 0x00, 0xa1, 0x22, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x2f, 0x00, 0x7c, 0x3c, 0x3e, 0x5e, 0x2b, 0x3d, 0x3f, 0x2f, 0x5b, 0x5d, + 0x3b, 0x2c, 0x2a, 0x22, 0x5c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x34, 0x00, 0x00, + 0xf1, 0x40, 0x00, 0x00, 0x19, 0x22, 0x00, 0x00, 0x1d, 0x22, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x10, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, + 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, + 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x04, + 0x00, 0x04, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x01, + 0x00, 0x01, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x13, 0x00, 0x01, 0x01, + 0x01, 0x01, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x05, + 0x00, 0x05, 0x0a, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x05, + 0x01, 0x05, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x02, 0x00, + 0x02, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, + 0x03, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x02, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x03, + 0x01, 0x03, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x10, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x11, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0a, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0b, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x05, 0x00, 0x01, 0x00, + 0x01, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x06, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x07, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x0f, 0x00, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x02, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x03, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xad, 0x47, 0x00, 0x00, 0xf1, 0x40, 0x00, 0x00, 0xef, 0x46, 0x00, 0x00, + 0xb1, 0x46, 0x00, 0x00, 0xc9, 0x46, 0x00, 0x00, 0x65, 0x48, 0x00, 0x00, + 0x89, 0x44, 0x00, 0x00, 0x79, 0x44, 0x00, 0x00, 0xb1, 0x45, 0x00, 0x00, + 0x9f, 0x44, 0x00, 0x00, 0x75, 0x44, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb1, 0x48, 0x00, 0x00, + 0xdd, 0x48, 0x00, 0x00, 0xad, 0x48, 0x00, 0x00, 0xd1, 0x48, 0x00, 0x00, + 0xc5, 0x48, 0x00, 0x00, 0x15, 0x49, 0x00, 0x00, 0xf9, 0x48, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0xff, 0xff, 0xff, 0x40, 0x42, 0x0f, 0x00, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0xe4, 0x58, 0x00, 0x00, + 0x04, 0x59, 0x00, 0x00, 0x24, 0x59, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xe0, 0x58, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x20, 0xdd, 0x20, 0x00, 0x00, + 0x05, 0x22, 0x00, 0x00, 0xed, 0x26, 0x00, 0x00, 0xa9, 0x2b, 0x00, 0x00, + 0x55, 0x38, 0x00, 0x00, 0x85, 0x3a, 0x00, 0x00, 0x01, 0x3b, 0x00, 0x00, + 0x39, 0x49, 0x00, 0x00, 0xdd, 0x4b, 0x00, 0x00, 0xb5, 0x20, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00 diff --git a/libraries/SDU/src/boot/mkrzero.h b/libraries/SDU/src/boot/mkrzero.h new file mode 100644 index 0000000..0f1470d --- /dev/null +++ b/libraries/SDU/src/boot/mkrzero.h @@ -0,0 +1,1236 @@ + 0x00, 0x80, 0x00, 0x20, 0x85, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0xd9, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0xdd, 0x3a, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, + 0x6d, 0x3b, 0x00, 0x00, 0x6d, 0x3b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0xa0, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0x44, 0x59, 0x00, 0x00, 0x08, 0xb5, 0x08, 0x4b, 0x00, 0x2b, 0x03, 0xd0, + 0x07, 0x48, 0x08, 0x49, 0x00, 0xe0, 0x00, 0xbf, 0x07, 0x48, 0x03, 0x68, + 0x00, 0x2b, 0x03, 0xd0, 0x06, 0x4b, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, + 0x08, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x00, 0x44, 0x59, 0x00, 0x00, + 0xa4, 0x00, 0x00, 0x20, 0x9c, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xf0, 0xb5, 0x33, 0x4c, 0xa5, 0x44, 0x01, 0xf0, 0x3d, 0xfe, 0x02, 0xf0, + 0x75, 0xfd, 0x01, 0x20, 0x01, 0xf0, 0x66, 0xfd, 0x2f, 0x4d, 0x1c, 0x21, + 0x28, 0x1c, 0x00, 0xf0, 0xe7, 0xf9, 0x00, 0x28, 0x44, 0xd0, 0x2d, 0x4e, + 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0xbe, 0xfa, 0x00, 0x28, 0x3d, 0xd0, + 0x29, 0x1c, 0x01, 0xa8, 0x32, 0x1c, 0x01, 0x23, 0x00, 0xf0, 0x6e, 0xfa, + 0x01, 0xa8, 0x00, 0xf0, 0x00, 0xf9, 0x80, 0x21, 0x04, 0x1c, 0xc9, 0x01, + 0x88, 0x42, 0x2d, 0xd9, 0x01, 0xa8, 0x00, 0xf0, 0xe6, 0xf8, 0x22, 0x4a, + 0xc0, 0x21, 0xa7, 0x18, 0x21, 0x48, 0xc9, 0x01, 0x3a, 0x1c, 0x01, 0xf0, + 0xf5, 0xfb, 0xc0, 0x24, 0xe4, 0x01, 0x80, 0x22, 0x0a, 0xa9, 0x92, 0x00, + 0x01, 0xa8, 0x00, 0xf0, 0xcf, 0xf8, 0x80, 0x23, 0x21, 0x1c, 0x0a, 0xaa, + 0x9b, 0x00, 0x19, 0x48, 0x01, 0xf0, 0x8e, 0xfb, 0x80, 0x22, 0x92, 0x00, + 0xa3, 0x18, 0x17, 0x4a, 0xa4, 0x18, 0xbc, 0x42, 0x01, 0xd2, 0x1c, 0x1c, + 0xe9, 0xe7, 0x01, 0x24, 0x01, 0xa8, 0x00, 0xf0, 0xed, 0xf8, 0x00, 0x2c, + 0x06, 0xd0, 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0x8d, 0xfa, 0x01, 0xe0, + 0x00, 0x24, 0xf3, 0xe7, 0xc0, 0x23, 0xdb, 0x01, 0x1b, 0x68, 0x83, 0xf3, + 0x08, 0x88, 0x0c, 0x4b, 0xc0, 0x22, 0xd2, 0x01, 0x9a, 0x60, 0x0b, 0x4b, + 0x1b, 0x68, 0x18, 0x47, 0x00, 0x20, 0x8b, 0x23, 0x9b, 0x00, 0x9d, 0x44, + 0xf0, 0xbd, 0xc0, 0x46, 0xd4, 0xfd, 0xff, 0xff, 0xd4, 0x00, 0x00, 0x20, + 0xa8, 0x4e, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xbc, 0x00, 0x00, 0x20, + 0x00, 0xa2, 0xff, 0xff, 0x00, 0xed, 0x00, 0xe0, 0x04, 0x60, 0x00, 0x00, + 0x08, 0xb5, 0x00, 0x21, 0x02, 0x48, 0x0a, 0x1c, 0x01, 0xf0, 0x38, 0xfb, + 0x08, 0xbd, 0xc0, 0x46, 0xbc, 0x00, 0x00, 0x20, 0x00, 0x20, 0x70, 0x47, + 0x70, 0x47, 0x13, 0xb5, 0x02, 0x68, 0x6b, 0x46, 0xd9, 0x71, 0x07, 0x33, + 0x54, 0x68, 0x19, 0x1c, 0x01, 0x22, 0xa0, 0x47, 0x16, 0xbd, 0x38, 0xb5, + 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x25, 0xa8, 0x42, 0x02, 0xd1, 0x01, 0x23, + 0x63, 0x60, 0x0a, 0xe0, 0x45, 0x60, 0x92, 0xb2, 0x01, 0xf0, 0x04, 0xf8, + 0x23, 0x6a, 0x5b, 0x68, 0x00, 0x2b, 0x02, 0xd0, 0x01, 0x23, 0x63, 0x60, + 0x28, 0x1c, 0x38, 0xbd, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x01, 0xd0, + 0x00, 0xf0, 0x42, 0xfe, 0x08, 0xbd, 0x00, 0x00, 0x13, 0xb5, 0x6c, 0x46, + 0x07, 0x34, 0x21, 0x1c, 0x01, 0x22, 0x00, 0xf0, 0x5d, 0xfd, 0x01, 0x28, + 0x01, 0xd1, 0x20, 0x78, 0x00, 0xe0, 0x01, 0x48, 0x00, 0xb2, 0x16, 0xbd, + 0xff, 0xff, 0x00, 0x00, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x02, 0xd0, + 0xff, 0xf7, 0xea, 0xff, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x08, 0xbd, + 0x38, 0xb5, 0x05, 0x1c, 0x00, 0x6a, 0x00, 0x28, 0x0a, 0xd0, 0xff, 0xf7, + 0xdf, 0xff, 0x04, 0x1c, 0x63, 0x1c, 0x05, 0xd0, 0x28, 0x6a, 0x01, 0x69, + 0x01, 0x39, 0x00, 0xf0, 0xe5, 0xfd, 0x20, 0x1c, 0x38, 0xbd, 0x00, 0x00, + 0xf8, 0xb5, 0xfa, 0x23, 0x9b, 0x00, 0x83, 0x60, 0x0d, 0x4b, 0x00, 0x25, + 0x08, 0x33, 0x04, 0x1c, 0x45, 0x60, 0x03, 0x60, 0x28, 0x20, 0x0f, 0x1c, + 0x16, 0x1c, 0x02, 0xf0, 0xbb, 0xfc, 0x20, 0x62, 0xa8, 0x42, 0x0a, 0xd0, + 0x39, 0x1c, 0x28, 0x22, 0x02, 0xf0, 0xd7, 0xfc, 0x20, 0x1c, 0x10, 0x30, + 0x31, 0x1c, 0x0c, 0x22, 0x02, 0xf0, 0x9c, 0xfd, 0x25, 0x77, 0x20, 0x1c, + 0xf8, 0xbd, 0xc0, 0x46, 0xb8, 0x4e, 0x00, 0x00, 0xfa, 0x22, 0x92, 0x00, + 0x82, 0x60, 0x04, 0x4a, 0x00, 0x23, 0x08, 0x32, 0x43, 0x60, 0x02, 0x60, + 0x03, 0x62, 0x03, 0x74, 0x70, 0x47, 0xc0, 0x46, 0xb8, 0x4e, 0x00, 0x00, + 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x01, 0xd0, 0x00, 0xf0, 0x02, 0xfd, + 0x08, 0xbd, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x04, 0xd0, 0x00, 0xf0, + 0xa5, 0xfd, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x08, 0xbd, 0x03, 0x6a, + 0x00, 0x2b, 0x01, 0xd0, 0x18, 0x69, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, + 0x70, 0x47, 0x00, 0x6a, 0x00, 0x28, 0x00, 0xd0, 0xc0, 0x69, 0x70, 0x47, + 0x38, 0xb5, 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x28, 0x0b, 0xd0, 0x20, 0x1c, + 0xff, 0xf7, 0xf3, 0xff, 0x05, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0xe7, 0xff, + 0x02, 0x4b, 0x28, 0x1a, 0x98, 0x42, 0x00, 0xd9, 0x18, 0x1c, 0x38, 0xbd, + 0xff, 0x7f, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x28, + 0x06, 0xd0, 0x00, 0xf0, 0xe7, 0xfd, 0x20, 0x6a, 0x02, 0xf0, 0x68, 0xfc, + 0x00, 0x23, 0x23, 0x62, 0x10, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x0a, 0x1c, + 0x0c, 0x49, 0x8a, 0xb0, 0x04, 0x1c, 0x00, 0x23, 0x00, 0x91, 0x69, 0x46, + 0x4b, 0x72, 0x01, 0x93, 0x21, 0x1c, 0x68, 0x46, 0x01, 0x23, 0x00, 0xf0, + 0x81, 0xfe, 0x04, 0x1c, 0x60, 0x1e, 0x84, 0x41, 0xe4, 0xb2, 0x00, 0x2c, + 0x02, 0xd0, 0x68, 0x46, 0x00, 0xf0, 0xc8, 0xfd, 0x20, 0x1c, 0x0a, 0xb0, + 0x10, 0xbd, 0xc0, 0x46, 0x00, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x01, 0x23, + 0x00, 0x2a, 0x05, 0xd0, 0x00, 0xf0, 0x1a, 0xff, 0x03, 0x1c, 0x58, 0x1e, + 0x83, 0x41, 0xdb, 0xb2, 0x18, 0x1c, 0x08, 0xbd, 0x38, 0xb5, 0x01, 0x22, + 0x05, 0x1c, 0x0c, 0x1c, 0x01, 0xf0, 0x94, 0xf9, 0x02, 0x1c, 0x01, 0x20, + 0x00, 0x2a, 0x03, 0xd1, 0x28, 0x1c, 0x21, 0x1c, 0x01, 0xf0, 0x8c, 0xf9, + 0x38, 0xbd, 0xf0, 0xb5, 0x0c, 0x68, 0x03, 0x5d, 0x2f, 0x3b, 0x5d, 0x42, + 0x6b, 0x41, 0xe4, 0x18, 0x27, 0x1c, 0x0c, 0x37, 0x23, 0x1c, 0xc5, 0x5c, + 0x1e, 0x1b, 0x2f, 0x2d, 0x09, 0xd0, 0x00, 0x2d, 0x07, 0xd0, 0x01, 0x33, + 0x16, 0x1b, 0xf6, 0x18, 0x01, 0x3e, 0x35, 0x70, 0xbb, 0x42, 0xf2, 0xd1, + 0x0c, 0x26, 0x00, 0x24, 0x94, 0x55, 0xc2, 0x5c, 0x2f, 0x3a, 0x54, 0x42, + 0x62, 0x41, 0x9b, 0x18, 0x0b, 0x60, 0xc0, 0x5c, 0x43, 0x1e, 0x98, 0x41, + 0xc0, 0xb2, 0xf0, 0xbd, 0xf0, 0xb5, 0xa1, 0xb0, 0x03, 0x90, 0x25, 0x48, + 0x0d, 0x1c, 0x04, 0x92, 0x05, 0x93, 0x0c, 0xaa, 0x00, 0x23, 0x16, 0xa9, + 0x0d, 0x93, 0x0c, 0x90, 0x53, 0x72, 0x17, 0x93, 0x16, 0x90, 0x4b, 0x72, + 0x07, 0x93, 0x2c, 0x1c, 0x00, 0x92, 0x07, 0xa9, 0x08, 0xaa, 0x03, 0x98, + 0xff, 0xf7, 0xc3, 0xff, 0x01, 0x26, 0x02, 0x1c, 0x72, 0x40, 0x01, 0x90, + 0xd2, 0xb2, 0x20, 0x1c, 0x08, 0xa9, 0x05, 0x9b, 0x04, 0x9f, 0xb8, 0x47, + 0x00, 0x28, 0x07, 0xd1, 0xac, 0x42, 0x01, 0xd1, 0x00, 0x20, 0x23, 0xe0, + 0x20, 0x1c, 0x00, 0xf0, 0x57, 0xfd, 0xf9, 0xe7, 0x01, 0x9f, 0x00, 0x2f, + 0x11, 0xd0, 0x33, 0x1c, 0x00, 0x98, 0x21, 0x1c, 0x08, 0xaa, 0x00, 0xf0, + 0xfd, 0xfd, 0x06, 0x1c, 0xac, 0x42, 0x0f, 0xd0, 0x20, 0x1c, 0x00, 0xf0, + 0x47, 0xfd, 0x00, 0x2e, 0xe8, 0xd0, 0x23, 0x1c, 0x00, 0x9c, 0x00, 0x93, + 0xd1, 0xe7, 0xac, 0x42, 0x02, 0xd0, 0x20, 0x1c, 0x00, 0xf0, 0x3c, 0xfd, + 0x30, 0x1c, 0x03, 0xe0, 0x00, 0x28, 0xdb, 0xd0, 0x16, 0xac, 0xf0, 0xe7, + 0x21, 0xb0, 0xf0, 0xbd, 0x00, 0x4f, 0x00, 0x00, 0x38, 0xb5, 0x03, 0x1c, + 0x41, 0x33, 0x1b, 0x78, 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x2b, 0x02, 0xd0, + 0x38, 0x30, 0x00, 0xf0, 0x27, 0xfd, 0x20, 0x1c, 0x01, 0x21, 0x2a, 0x1c, + 0x00, 0xf0, 0xc8, 0xf9, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x0f, 0xe0, + 0x25, 0x1c, 0x10, 0x35, 0x28, 0x1c, 0x21, 0x1c, 0xff, 0xf7, 0x62, 0xff, + 0x00, 0x28, 0xf5, 0xd0, 0x20, 0x1c, 0x38, 0x30, 0x29, 0x1c, 0x00, 0xf0, + 0xcf, 0xfb, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x38, 0xbd, 0x00, 0x00, + 0x4b, 0x68, 0x43, 0x60, 0x0a, 0x4b, 0x03, 0x60, 0x0b, 0x7a, 0x03, 0x72, + 0x4b, 0x7a, 0x43, 0x72, 0xcb, 0x68, 0xc3, 0x60, 0x0b, 0x69, 0x03, 0x61, + 0x4b, 0x69, 0x43, 0x61, 0x0b, 0x7e, 0x03, 0x76, 0xcb, 0x69, 0xc3, 0x61, + 0x0b, 0x6a, 0x49, 0x6a, 0x03, 0x62, 0x41, 0x62, 0x70, 0x47, 0xc0, 0x46, + 0x00, 0x4f, 0x00, 0x00, 0xf0, 0xb5, 0x9d, 0xb0, 0x08, 0xae, 0x02, 0x92, + 0x03, 0x93, 0x27, 0x4a, 0x00, 0x23, 0x12, 0xaf, 0x05, 0x1c, 0x73, 0x60, + 0x7b, 0x60, 0x10, 0x31, 0x30, 0x1c, 0x08, 0x92, 0x73, 0x72, 0x12, 0x92, + 0x7b, 0x72, 0x00, 0xf0, 0x9d, 0xfb, 0x02, 0x9c, 0x20, 0x1c, 0x2f, 0x21, + 0x02, 0xf0, 0x36, 0xfc, 0x00, 0x28, 0x2e, 0xd0, 0x23, 0x78, 0x2f, 0x2b, + 0x01, 0xd1, 0x01, 0x34, 0xf4, 0xe7, 0x00, 0x1b, 0xc0, 0xb2, 0x03, 0x1c, + 0x0c, 0x28, 0x00, 0xd9, 0x0c, 0x23, 0xdb, 0xb2, 0x1a, 0x1c, 0x21, 0x1c, + 0x04, 0xa8, 0x01, 0x93, 0x02, 0xf0, 0x2e, 0xfc, 0x01, 0x9a, 0x00, 0x23, + 0x04, 0xa9, 0x38, 0x1c, 0x8b, 0x54, 0x00, 0xf0, 0xbf, 0xfc, 0x38, 0x1c, + 0x31, 0x1c, 0x04, 0xaa, 0x01, 0x23, 0x00, 0xf0, 0x69, 0xfd, 0x00, 0x28, + 0x04, 0xd1, 0x0c, 0x4b, 0x68, 0x60, 0x2b, 0x60, 0x68, 0x72, 0x10, 0xe0, + 0x01, 0x9b, 0x30, 0x1c, 0xe4, 0x18, 0x00, 0xf0, 0xad, 0xfc, 0x33, 0x1c, + 0x3e, 0x1c, 0x1f, 0x1c, 0xca, 0xe7, 0x02, 0x99, 0x03, 0x9a, 0x64, 0x1a, + 0x14, 0x60, 0x28, 0x1c, 0x31, 0x1c, 0xff, 0xf7, 0x95, 0xff, 0x28, 0x1c, + 0x1d, 0xb0, 0xf0, 0xbd, 0x00, 0x4f, 0x00, 0x00, 0xf0, 0xb5, 0xa1, 0xb0, + 0x05, 0x1c, 0x1f, 0x1c, 0x02, 0xa8, 0x01, 0xab, 0x16, 0x1c, 0xff, 0xf7, + 0xa1, 0xff, 0x01, 0x9b, 0xf6, 0x18, 0x33, 0x78, 0x00, 0x2b, 0x07, 0xd1, + 0x02, 0xa9, 0x16, 0xa8, 0xff, 0xf7, 0x7e, 0xff, 0x28, 0x1c, 0x16, 0xa9, + 0x17, 0x4a, 0x28, 0xe0, 0x00, 0x23, 0x0c, 0xac, 0x63, 0x60, 0x63, 0x72, + 0x6b, 0x46, 0x11, 0x33, 0x14, 0x4a, 0x1b, 0x78, 0x0c, 0x92, 0x00, 0x2b, + 0x03, 0xd1, 0x28, 0x1c, 0xff, 0xf7, 0x4a, 0xfe, 0x1b, 0xe0, 0x20, 0x1c, + 0x02, 0xa9, 0x32, 0x1c, 0x3b, 0x1c, 0x00, 0xf0, 0x21, 0xfd, 0x00, 0x28, + 0xf3, 0xd0, 0x02, 0xa8, 0x00, 0xf0, 0x6c, 0xfc, 0x06, 0x23, 0x1f, 0x40, + 0x9f, 0x42, 0x03, 0xd1, 0x20, 0x1c, 0x13, 0x99, 0x00, 0xf0, 0xf6, 0xfb, + 0x21, 0x1c, 0x16, 0xa8, 0xff, 0xf7, 0x54, 0xff, 0x28, 0x1c, 0x16, 0xa9, + 0x32, 0x1c, 0xff, 0xf7, 0x0b, 0xfe, 0x28, 0x1c, 0x21, 0xb0, 0xf0, 0xbd, + 0xe0, 0x4e, 0x00, 0x00, 0x00, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x1c, + 0x08, 0x1c, 0x19, 0x1c, 0x38, 0x31, 0x02, 0x4a, 0x00, 0x23, 0xff, 0xf7, + 0xc9, 0xfe, 0x08, 0xbd, 0xa5, 0x23, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x1c, + 0x08, 0x1c, 0x19, 0x1c, 0x38, 0x31, 0x02, 0x4a, 0x00, 0x23, 0xff, 0xf7, + 0xbd, 0xfe, 0x08, 0xbd, 0xe1, 0x23, 0x00, 0x00, 0x08, 0x4b, 0x02, 0x21, + 0x19, 0x61, 0x19, 0x1c, 0x00, 0x22, 0x30, 0x31, 0x0a, 0x70, 0x06, 0x49, + 0x5a, 0x71, 0x9a, 0x71, 0x9a, 0x72, 0x1a, 0x73, 0xda, 0x63, 0x99, 0x63, + 0x41, 0x33, 0x1a, 0x70, 0x70, 0x47, 0xc0, 0x46, 0xd4, 0x00, 0x00, 0x20, + 0x00, 0x4f, 0x00, 0x00, 0x08, 0xb5, 0x01, 0x1c, 0x01, 0x48, 0x01, 0xf0, + 0xab, 0xf9, 0x08, 0xbd, 0x88, 0x07, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, + 0xff, 0x21, 0x01, 0xf0, 0xa3, 0xf9, 0x08, 0xbd, 0x88, 0x07, 0x00, 0x20, + 0x08, 0xb5, 0x01, 0x21, 0x00, 0x79, 0x01, 0xf0, 0x2b, 0xfc, 0x05, 0x4b, + 0x1a, 0x78, 0x00, 0x2a, 0x04, 0xd0, 0x00, 0x22, 0x03, 0x48, 0x1a, 0x70, + 0x01, 0xf0, 0x80, 0xf9, 0x08, 0xbd, 0xc0, 0x46, 0x40, 0x01, 0x00, 0x20, + 0x88, 0x07, 0x00, 0x20, 0x10, 0xb5, 0x08, 0x4b, 0x04, 0x1c, 0x1a, 0x78, + 0x00, 0x2a, 0x06, 0xd1, 0x01, 0x22, 0x1a, 0x70, 0x05, 0x4b, 0x06, 0x48, + 0x06, 0xcb, 0x01, 0xf0, 0x51, 0xf9, 0x20, 0x79, 0x00, 0x21, 0x01, 0xf0, + 0x0b, 0xfc, 0x10, 0xbd, 0x40, 0x01, 0x00, 0x20, 0x38, 0x01, 0x00, 0x20, + 0x88, 0x07, 0x00, 0x20, 0x10, 0xb5, 0x83, 0x79, 0x04, 0x1c, 0x00, 0x2b, + 0x0d, 0xd0, 0x23, 0x89, 0x5a, 0x1c, 0x22, 0x81, 0x05, 0x4a, 0x93, 0x42, + 0x02, 0xd8, 0xff, 0xf7, 0xbf, 0xff, 0xf6, 0xe7, 0x20, 0x1c, 0xff, 0xf7, + 0xc3, 0xff, 0x00, 0x23, 0xa3, 0x71, 0x10, 0xbd, 0x01, 0x02, 0x00, 0x00, + 0x00, 0xb5, 0x06, 0x29, 0x03, 0xd9, 0x16, 0x23, 0x43, 0x71, 0x00, 0x20, + 0x1c, 0xe0, 0x0f, 0x4b, 0x05, 0x29, 0x13, 0xd8, 0x08, 0x1c, 0x00, 0x22, + 0x02, 0xf0, 0xc0, 0xf9, 0x03, 0x05, 0x07, 0x09, 0x0b, 0x0d, 0x0b, 0x49, + 0x08, 0xe0, 0x0b, 0x49, 0x06, 0xe0, 0x0b, 0x49, 0x04, 0xe0, 0x0b, 0x49, + 0x02, 0xe0, 0x0b, 0x49, 0x00, 0xe0, 0x0b, 0x49, 0x19, 0x60, 0x02, 0xe0, + 0x0a, 0x4a, 0x1a, 0x60, 0x00, 0x22, 0x1a, 0x71, 0x5a, 0x71, 0x01, 0x20, + 0x00, 0xbd, 0xc0, 0x46, 0x38, 0x01, 0x00, 0x20, 0x00, 0x1b, 0xb7, 0x00, + 0x00, 0x09, 0x3d, 0x00, 0x80, 0x84, 0x1e, 0x00, 0x40, 0x42, 0x0f, 0x00, + 0x20, 0xa1, 0x07, 0x00, 0x90, 0xd0, 0x03, 0x00, 0x48, 0xe8, 0x01, 0x00, + 0x38, 0xb5, 0x0c, 0x1c, 0x01, 0xf0, 0xdc, 0xf9, 0x05, 0x1c, 0xff, 0xf7, + 0x79, 0xff, 0xff, 0x28, 0x06, 0xd0, 0x01, 0xf0, 0xd5, 0xf9, 0x40, 0x1b, + 0xa0, 0x42, 0xf6, 0xd3, 0x00, 0x20, 0x00, 0xe0, 0x01, 0x20, 0x38, 0xbd, + 0xf8, 0xb5, 0x04, 0x1c, 0x0e, 0x1c, 0x17, 0x1c, 0xff, 0xf7, 0x9c, 0xff, + 0x20, 0x1c, 0xff, 0xf7, 0x81, 0xff, 0x96, 0x21, 0x49, 0x00, 0x20, 0x1c, + 0xff, 0xf7, 0xe0, 0xff, 0x40, 0x20, 0x30, 0x43, 0xff, 0xf7, 0x54, 0xff, + 0x18, 0x25, 0x38, 0x1c, 0xe8, 0x40, 0xc0, 0xb2, 0x08, 0x3d, 0xff, 0xf7, + 0x4d, 0xff, 0x2b, 0x1c, 0x08, 0x33, 0xf6, 0xd1, 0x95, 0x20, 0x00, 0x2e, + 0x03, 0xd0, 0x87, 0x20, 0x08, 0x2e, 0x00, 0xd0, 0xff, 0x20, 0xff, 0xf7, + 0x41, 0xff, 0x00, 0x25, 0xff, 0xf7, 0x46, 0xff, 0x43, 0xb2, 0xe0, 0x72, + 0x00, 0x2b, 0x04, 0xda, 0xff, 0x2d, 0x02, 0xd0, 0x01, 0x35, 0xed, 0xb2, + 0xf4, 0xe7, 0xf8, 0xbd, 0xf7, 0xb5, 0x00, 0x25, 0x02, 0x71, 0x05, 0x73, + 0x85, 0x72, 0x85, 0x71, 0x45, 0x71, 0x04, 0x1c, 0x01, 0x91, 0x01, 0xf0, + 0x91, 0xf9, 0x01, 0x21, 0x07, 0x1c, 0x20, 0x79, 0x01, 0xf0, 0x0a, 0xfb, + 0x01, 0x21, 0x20, 0x79, 0x01, 0xf0, 0x60, 0xfb, 0x42, 0x4e, 0x30, 0x1c, + 0x01, 0xf0, 0x76, 0xf8, 0x41, 0x4b, 0x42, 0x49, 0x1d, 0x71, 0x5d, 0x71, + 0x19, 0x60, 0x30, 0x1c, 0x5a, 0x68, 0x01, 0xf0, 0x95, 0xf8, 0x0a, 0x25, + 0x01, 0x3d, 0xff, 0x20, 0xed, 0xb2, 0xff, 0xf7, 0x0d, 0xff, 0x00, 0x2d, + 0xf8, 0xd1, 0x30, 0x1c, 0x01, 0xf0, 0xa6, 0xf8, 0x20, 0x1c, 0xff, 0xf7, + 0x29, 0xff, 0x00, 0x21, 0x20, 0x1c, 0x0a, 0x1c, 0xff, 0xf7, 0x9a, 0xff, + 0x06, 0x1c, 0xe0, 0x72, 0x01, 0x28, 0x08, 0xd0, 0x01, 0xf0, 0x62, 0xf9, + 0xfa, 0x23, 0xc0, 0x1b, 0xdb, 0x00, 0x98, 0x42, 0xef, 0xd9, 0x01, 0x23, + 0x3b, 0xe0, 0xd5, 0x22, 0x20, 0x1c, 0x08, 0x21, 0x52, 0x00, 0xff, 0xf7, + 0x87, 0xff, 0x04, 0x23, 0x18, 0x42, 0x01, 0xd0, 0x26, 0x73, 0x0b, 0xe0, + 0x1e, 0x1c, 0xff, 0xf7, 0xed, 0xfe, 0x01, 0x3e, 0xf6, 0xb2, 0xe0, 0x72, + 0x00, 0x2e, 0xf8, 0xd1, 0x02, 0x23, 0xaa, 0x28, 0x25, 0xd1, 0x23, 0x73, + 0x26, 0x7b, 0x02, 0x3e, 0x73, 0x42, 0x5e, 0x41, 0xb6, 0x07, 0x37, 0x21, + 0x00, 0x22, 0x20, 0x1c, 0xff, 0xf7, 0x6c, 0xff, 0x32, 0x1c, 0x20, 0x1c, + 0x29, 0x21, 0xff, 0xf7, 0x67, 0xff, 0x02, 0x1c, 0xe0, 0x72, 0x08, 0xd0, + 0x01, 0xf0, 0x30, 0xf9, 0xfa, 0x23, 0xc0, 0x1b, 0xdb, 0x00, 0x98, 0x42, + 0xeb, 0xd9, 0x08, 0x23, 0x09, 0xe0, 0x23, 0x7b, 0x02, 0x2b, 0x19, 0xd1, + 0x20, 0x1c, 0x3a, 0x21, 0xff, 0xf7, 0x54, 0xff, 0x00, 0x28, 0x05, 0xd0, + 0x06, 0x23, 0x63, 0x71, 0x20, 0x1c, 0xff, 0xf7, 0xc3, 0xfe, 0x15, 0xe0, + 0xff, 0xf7, 0xb8, 0xfe, 0xc0, 0x23, 0x18, 0x40, 0x98, 0x42, 0x01, 0xd1, + 0x03, 0x23, 0x23, 0x73, 0xff, 0xf7, 0xb0, 0xfe, 0xff, 0xf7, 0xae, 0xfe, + 0xff, 0xf7, 0xac, 0xfe, 0x20, 0x1c, 0xff, 0xf7, 0xb1, 0xfe, 0x20, 0x1c, + 0x01, 0x99, 0xff, 0xf7, 0xef, 0xfe, 0x05, 0x1c, 0x28, 0x1c, 0xfe, 0xbd, + 0x88, 0x07, 0x00, 0x20, 0x38, 0x01, 0x00, 0x20, 0x90, 0xd0, 0x03, 0x00, + 0x38, 0xb5, 0x04, 0x1c, 0x01, 0xf0, 0xf8, 0xf8, 0x05, 0x1c, 0xff, 0xf7, + 0x95, 0xfe, 0xe0, 0x72, 0xff, 0x28, 0x08, 0xd1, 0x01, 0xf0, 0xf0, 0xf8, + 0x96, 0x23, 0x40, 0x1b, 0x5b, 0x00, 0x98, 0x42, 0xf3, 0xd9, 0x0f, 0x23, + 0x02, 0xe0, 0xfe, 0x28, 0x06, 0xd0, 0x0d, 0x23, 0x20, 0x1c, 0x63, 0x71, + 0xff, 0xf7, 0x8a, 0xfe, 0x00, 0x20, 0x00, 0xe0, 0x01, 0x20, 0x38, 0xbd, + 0xf8, 0xb5, 0x04, 0x1c, 0x0f, 0x1c, 0x15, 0x1c, 0x1e, 0x1e, 0x45, 0xd0, + 0x9a, 0x18, 0x80, 0x23, 0x9b, 0x00, 0x9a, 0x42, 0x42, 0xdc, 0x83, 0x79, + 0x00, 0x2b, 0x05, 0xd0, 0x02, 0x68, 0x91, 0x42, 0x02, 0xd1, 0x03, 0x89, + 0xab, 0x42, 0x16, 0xd9, 0x23, 0x7b, 0x27, 0x60, 0x03, 0x2b, 0x00, 0xd0, + 0x7f, 0x02, 0x3a, 0x1c, 0x20, 0x1c, 0x11, 0x21, 0xff, 0xf7, 0xf2, 0xfe, + 0x07, 0x1e, 0x02, 0xd0, 0x03, 0x23, 0x63, 0x71, 0x2a, 0xe0, 0x20, 0x1c, + 0xff, 0xf7, 0xbc, 0xff, 0x00, 0x28, 0x25, 0xd0, 0x01, 0x23, 0x27, 0x81, + 0xa3, 0x71, 0x23, 0x89, 0xab, 0x42, 0x05, 0xd2, 0xff, 0xf7, 0x4e, 0xfe, + 0x23, 0x89, 0x01, 0x33, 0x23, 0x81, 0xf6, 0xe7, 0x06, 0x9d, 0x06, 0x9a, + 0xab, 0x1a, 0x9b, 0xb2, 0xb3, 0x42, 0x04, 0xd2, 0xff, 0xf7, 0x42, 0xfe, + 0x28, 0x70, 0x01, 0x35, 0xf5, 0xe7, 0x23, 0x89, 0xa2, 0x7a, 0xf3, 0x18, + 0x9b, 0xb2, 0x23, 0x81, 0x00, 0x2a, 0x02, 0xd0, 0x06, 0x4a, 0x93, 0x42, + 0x02, 0xd9, 0x20, 0x1c, 0xff, 0xf7, 0x66, 0xfe, 0x01, 0x20, 0x03, 0xe0, + 0x20, 0x1c, 0xff, 0xf7, 0x35, 0xfe, 0x00, 0x20, 0xf8, 0xbd, 0xc0, 0x46, + 0xff, 0x01, 0x00, 0x00, 0x07, 0xb5, 0x80, 0x23, 0x00, 0x92, 0x9b, 0x00, + 0x00, 0x22, 0xff, 0xf7, 0xa3, 0xff, 0x0e, 0xbd, 0x70, 0xb5, 0x05, 0x1c, + 0x08, 0x1c, 0x16, 0x1c, 0xff, 0xf7, 0x12, 0xfe, 0x00, 0x24, 0x30, 0x5d, + 0xff, 0xf7, 0x0e, 0xfe, 0x01, 0x34, 0x80, 0x23, 0x9b, 0x00, 0x9c, 0x42, + 0xf7, 0xd1, 0xff, 0x20, 0xff, 0xf7, 0x06, 0xfe, 0xff, 0x20, 0xff, 0xf7, + 0x03, 0xfe, 0xff, 0xf7, 0x09, 0xfe, 0x1f, 0x23, 0xe8, 0x72, 0x03, 0x40, + 0x01, 0x20, 0x05, 0x2b, 0x05, 0xd0, 0x11, 0x23, 0x28, 0x1c, 0x6b, 0x71, + 0xff, 0xf7, 0x06, 0xfe, 0x00, 0x20, 0x70, 0xbd, 0x70, 0xb5, 0x0b, 0x1c, + 0x04, 0x1c, 0x16, 0x1c, 0x00, 0x29, 0x01, 0xd1, 0x12, 0x23, 0x28, 0xe0, + 0x02, 0x7b, 0x03, 0x2a, 0x00, 0xd0, 0x4b, 0x02, 0x20, 0x1c, 0x18, 0x21, + 0x1a, 0x1c, 0xff, 0xf7, 0x7d, 0xfe, 0x05, 0x1e, 0x01, 0xd0, 0x04, 0x23, + 0x1b, 0xe0, 0x20, 0x1c, 0xfe, 0x21, 0x32, 0x1c, 0xff, 0xf7, 0xc2, 0xff, + 0x00, 0x28, 0x15, 0xd0, 0x96, 0x21, 0x20, 0x1c, 0x89, 0x00, 0xff, 0xf7, + 0x5b, 0xfe, 0x00, 0x28, 0x01, 0xd1, 0x15, 0x23, 0x0b, 0xe0, 0x20, 0x1c, + 0x0d, 0x21, 0x2a, 0x1c, 0xff, 0xf7, 0x64, 0xfe, 0x00, 0x28, 0x03, 0xd1, + 0xff, 0xf7, 0xce, 0xfd, 0x00, 0x28, 0x06, 0xd0, 0x14, 0x23, 0x63, 0x71, + 0x20, 0x1c, 0xff, 0xf7, 0xcf, 0xfd, 0x00, 0x20, 0x03, 0xe0, 0x20, 0x1c, + 0xff, 0xf7, 0xca, 0xfd, 0x01, 0x20, 0x70, 0xbd, 0x03, 0x4b, 0x04, 0x4a, + 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x70, 0x47, 0xc0, 0x46, + 0x38, 0x01, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, 0x02, 0x1c, 0x10, 0xb5, + 0x0c, 0x32, 0x04, 0x1c, 0x01, 0x21, 0x40, 0x6a, 0x00, 0xf0, 0x24, 0xfd, + 0x00, 0x28, 0x0a, 0xd0, 0x23, 0x6a, 0x01, 0x20, 0x00, 0x2b, 0x06, 0xd1, + 0xe3, 0x68, 0x22, 0x7a, 0x23, 0x62, 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, + 0x23, 0x72, 0x10, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xe6, 0xff, + 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x1b, 0xe0, 0x63, 0x6a, 0xe6, 0x68, + 0x1a, 0x7c, 0x02, 0x3e, 0x96, 0x40, 0x5a, 0x69, 0x1d, 0x79, 0xb6, 0x18, + 0x00, 0x2d, 0x08, 0xd0, 0x70, 0x1e, 0x40, 0x19, 0x00, 0xf0, 0x4c, 0xfc, + 0x00, 0x28, 0xed, 0xd0, 0x01, 0x3d, 0xed, 0xb2, 0xf4, 0xe7, 0x63, 0x6a, + 0x01, 0x20, 0x1a, 0x7c, 0x80, 0x23, 0x9b, 0x00, 0x93, 0x40, 0xe2, 0x69, + 0xd3, 0x18, 0xe3, 0x61, 0x70, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, + 0x40, 0x69, 0x00, 0xf0, 0x13, 0xfc, 0x00, 0x28, 0x03, 0xd0, 0x20, 0x7e, + 0x01, 0x4b, 0x40, 0x01, 0xc0, 0x18, 0x10, 0xbd, 0x50, 0x01, 0x00, 0x20, + 0xf0, 0xb5, 0x00, 0x23, 0x87, 0xb0, 0x07, 0x1c, 0x0e, 0x1c, 0x20, 0x22, + 0xf2, 0x54, 0x01, 0x33, 0x0b, 0x2b, 0xfa, 0xd1, 0x07, 0x21, 0x00, 0x25, + 0x01, 0x91, 0x3c, 0x78, 0x00, 0x2c, 0x2a, 0xd0, 0x2e, 0x2c, 0x06, 0xd1, + 0x01, 0x9b, 0x0a, 0x2b, 0x2b, 0xd0, 0x0a, 0x21, 0x08, 0x25, 0x01, 0x91, + 0x1f, 0xe0, 0x02, 0xa8, 0x14, 0x49, 0x10, 0x22, 0x02, 0xf0, 0x07, 0xf8, + 0x00, 0x23, 0x02, 0xa9, 0xca, 0x5c, 0x00, 0x2a, 0x03, 0xd0, 0x01, 0x33, + 0xa2, 0x42, 0xf8, 0xd1, 0x19, 0xe0, 0x01, 0x9b, 0x9d, 0x42, 0x16, 0xd8, + 0x23, 0x1c, 0x21, 0x3b, 0x5d, 0x2b, 0x12, 0xd8, 0x22, 0x1c, 0x6b, 0x1c, + 0x61, 0x3a, 0xdb, 0xb2, 0x75, 0x19, 0x19, 0x2a, 0x01, 0xd8, 0x20, 0x3c, + 0xe4, 0xb2, 0x2c, 0x70, 0x1d, 0x1c, 0x01, 0x37, 0xd1, 0xe7, 0x30, 0x78, + 0x20, 0x38, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x00, 0xe0, 0x00, 0x20, + 0x07, 0xb0, 0xf0, 0xbd, 0xe2, 0x4e, 0x00, 0x00, 0x38, 0xb5, 0x42, 0x7a, + 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x2a, 0x01, 0xd0, 0x00, 0x20, 0x1f, 0xe0, + 0x4b, 0x1c, 0xdb, 0x7f, 0x10, 0x2b, 0x06, 0xd1, 0x02, 0x23, 0x43, 0x72, + 0x02, 0x62, 0x4b, 0x8c, 0x5b, 0x01, 0xc3, 0x61, 0x0c, 0xe0, 0x20, 0x2b, + 0xf0, 0xd1, 0x03, 0x23, 0x43, 0x72, 0x49, 0x6a, 0x22, 0x1c, 0x01, 0x62, + 0x1c, 0x32, 0x28, 0x1c, 0x00, 0xf0, 0x18, 0xfc, 0x00, 0x28, 0xe5, 0xd0, + 0x00, 0x23, 0x01, 0x20, 0x65, 0x62, 0x20, 0x72, 0xe3, 0x60, 0x23, 0x61, + 0x63, 0x61, 0x23, 0x76, 0x38, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x43, 0x7a, + 0x85, 0xb0, 0x04, 0x1c, 0x0e, 0x1c, 0x03, 0x92, 0x00, 0x2b, 0x01, 0xd1, + 0x3a, 0x48, 0x11, 0xe0, 0x03, 0x7a, 0xd8, 0x07, 0xfa, 0xd5, 0xe2, 0x69, + 0x20, 0x69, 0x03, 0x99, 0x13, 0x1a, 0x99, 0x42, 0x01, 0xd9, 0x9b, 0xb2, + 0x03, 0x93, 0x03, 0x99, 0x02, 0x91, 0x02, 0x9b, 0x00, 0x2b, 0x04, 0xd1, + 0x03, 0x99, 0x88, 0xb2, 0x00, 0xb2, 0x05, 0xb0, 0xf0, 0xbd, 0x23, 0x69, + 0x61, 0x7a, 0xdf, 0x05, 0xff, 0x0d, 0x5a, 0x0a, 0x60, 0x6a, 0x02, 0x29, + 0x02, 0xd1, 0x41, 0x6a, 0x51, 0x18, 0x1b, 0xe0, 0x05, 0x79, 0x01, 0x3d, + 0x2a, 0x40, 0xd5, 0xb2, 0x00, 0x2f, 0x0d, 0xd1, 0x00, 0x2d, 0x0b, 0xd1, + 0x00, 0x2b, 0x02, 0xd1, 0x22, 0x6a, 0xe2, 0x60, 0x06, 0xe0, 0x22, 0x1c, + 0xe1, 0x68, 0x0c, 0x32, 0x00, 0xf0, 0xa0, 0xfb, 0x00, 0x28, 0xc9, 0xd0, + 0x63, 0x6a, 0xe1, 0x68, 0x1a, 0x7c, 0x02, 0x39, 0x5b, 0x69, 0x91, 0x40, + 0xc9, 0x18, 0x49, 0x19, 0x80, 0x22, 0x02, 0x9d, 0x92, 0x00, 0xd3, 0x1b, + 0x9d, 0x42, 0x00, 0xdd, 0x9d, 0xb2, 0x23, 0x7a, 0x58, 0x06, 0x01, 0xd4, + 0x95, 0x42, 0x18, 0xd1, 0x16, 0x4b, 0x1b, 0x68, 0x99, 0x42, 0x14, 0xd0, + 0x15, 0x4b, 0x3a, 0x1c, 0x18, 0x68, 0x00, 0x96, 0x2b, 0x1c, 0xff, 0xf7, + 0x1f, 0xfe, 0x00, 0x28, 0xa8, 0xd0, 0x76, 0x19, 0x01, 0xe0, 0xdf, 0x1b, + 0xf6, 0x19, 0x21, 0x69, 0x02, 0x9a, 0x4b, 0x19, 0x55, 0x1b, 0xad, 0xb2, + 0x23, 0x61, 0x02, 0x95, 0xab, 0xe7, 0x08, 0x1c, 0x00, 0x21, 0x00, 0xf0, + 0x2b, 0xfb, 0x00, 0x28, 0x96, 0xd0, 0x09, 0x4b, 0x32, 0x1c, 0xff, 0x18, + 0x79, 0x19, 0x3b, 0x1c, 0x8b, 0x42, 0xe8, 0xd0, 0x18, 0x78, 0x01, 0x33, + 0x10, 0x70, 0x01, 0x32, 0xf8, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x73, 0xb5, 0x43, 0x7a, 0x04, 0x1c, 0x01, 0x2b, 0x01, 0xd8, 0x00, 0x20, + 0x16, 0xe0, 0x03, 0x69, 0x6d, 0x46, 0x07, 0x35, 0xde, 0x05, 0x29, 0x1c, + 0x01, 0x22, 0x36, 0x0f, 0xff, 0xf7, 0x6a, 0xff, 0x01, 0x28, 0x01, 0xd1, + 0x2b, 0x78, 0x00, 0xe0, 0x05, 0x4b, 0x1b, 0xb2, 0x01, 0x33, 0xec, 0xd0, + 0x23, 0x69, 0x70, 0x01, 0x1f, 0x33, 0x23, 0x61, 0x02, 0x4b, 0xc0, 0x18, + 0x76, 0xbd, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0x50, 0x01, 0x00, 0x20, + 0x70, 0xb5, 0x04, 0x1c, 0x40, 0x7a, 0x0d, 0x1c, 0x00, 0x28, 0x2a, 0xd0, + 0xe2, 0x69, 0x91, 0x42, 0x01, 0xd9, 0x00, 0x20, 0x25, 0xe0, 0x02, 0x28, + 0x21, 0xd0, 0x00, 0x2d, 0x01, 0xd1, 0xe5, 0x60, 0x1d, 0xe0, 0x62, 0x6a, + 0x21, 0x69, 0x13, 0x7c, 0x68, 0x1e, 0x09, 0x33, 0x4a, 0x1e, 0xd8, 0x40, + 0xda, 0x40, 0x03, 0x1e, 0x93, 0x42, 0x01, 0xd3, 0x00, 0x29, 0x02, 0xd1, + 0x22, 0x6a, 0xe2, 0x60, 0x00, 0xe0, 0x83, 0x1a, 0x1e, 0x1c, 0x00, 0x2e, + 0x09, 0xd0, 0x22, 0x1c, 0x60, 0x6a, 0xe1, 0x68, 0x0c, 0x32, 0x00, 0xf0, + 0x07, 0xfb, 0x01, 0x3e, 0x00, 0x28, 0xf4, 0xd1, 0x01, 0xe0, 0x25, 0x61, + 0x01, 0x20, 0x70, 0xbd, 0x38, 0xb5, 0x05, 0x1c, 0x40, 0x7a, 0x00, 0x28, + 0x33, 0xd0, 0x2b, 0x7a, 0x7f, 0x2b, 0x2d, 0xd9, 0x28, 0x1c, 0x01, 0x21, + 0xff, 0xf7, 0x9a, 0xfe, 0x04, 0x1e, 0x2a, 0xd0, 0x6b, 0x7a, 0x01, 0x2b, + 0x07, 0xd8, 0x2b, 0x7f, 0x03, 0x77, 0x6b, 0x7f, 0x43, 0x77, 0xab, 0x7f, + 0x83, 0x77, 0xeb, 0x7f, 0xc3, 0x77, 0x2b, 0x6a, 0x9a, 0xb2, 0x1b, 0x0c, + 0x23, 0x75, 0x1b, 0x0a, 0x63, 0x75, 0x0d, 0x4b, 0xa2, 0x76, 0x1b, 0x68, + 0x12, 0x0a, 0xe2, 0x76, 0x00, 0x2b, 0x0b, 0xd0, 0x20, 0x1c, 0x21, 0x1c, + 0x18, 0x30, 0x16, 0x31, 0x98, 0x47, 0x63, 0x7e, 0x22, 0x7e, 0x1b, 0x02, + 0x13, 0x43, 0xa3, 0x74, 0x1b, 0x0a, 0xe3, 0x74, 0x2a, 0x7a, 0x7f, 0x23, + 0x13, 0x40, 0x2b, 0x72, 0x00, 0xf0, 0x5c, 0xfa, 0xff, 0xe7, 0x38, 0xbd, + 0x44, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xc0, 0xff, + 0x00, 0x28, 0x02, 0xd0, 0x00, 0x23, 0x63, 0x72, 0x01, 0x20, 0x10, 0xbd, + 0x73, 0xb5, 0x42, 0x7a, 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x20, 0x01, 0x2a, + 0x4b, 0xd1, 0x20, 0x7a, 0x02, 0x23, 0x18, 0x40, 0x47, 0xd0, 0xe3, 0x69, + 0x00, 0x20, 0x99, 0x42, 0x43, 0xd8, 0x10, 0x1c, 0x00, 0x2b, 0x40, 0xd0, + 0x20, 0x1c, 0x29, 0x1c, 0x26, 0x69, 0xff, 0xf7, 0x71, 0xff, 0x00, 0x28, + 0x25, 0xd0, 0x60, 0x6a, 0x00, 0x2d, 0x06, 0xd1, 0x21, 0x6a, 0x00, 0xf0, + 0x95, 0xfb, 0x00, 0x28, 0x1d, 0xd0, 0x25, 0x62, 0x1d, 0xe0, 0xe1, 0x68, + 0x01, 0xaa, 0x00, 0xf0, 0x93, 0xfa, 0x00, 0x28, 0x15, 0xd0, 0x60, 0x6a, + 0x01, 0x99, 0x43, 0x1c, 0xdb, 0x7f, 0x10, 0x2b, 0x01, 0xd1, 0x12, 0x4b, + 0x00, 0xe0, 0x12, 0x4b, 0x99, 0x42, 0x0c, 0xd2, 0x00, 0xf0, 0x7e, 0xfb, + 0x00, 0x28, 0x06, 0xd0, 0x60, 0x6a, 0xe1, 0x68, 0x0e, 0x4a, 0x00, 0xf0, + 0xcf, 0xfa, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x11, 0xe0, 0x22, 0x7a, + 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, 0xe5, 0x61, 0x23, 0x72, 0x20, 0x1c, + 0xff, 0xf7, 0x70, 0xff, 0x00, 0x28, 0xf2, 0xd0, 0x29, 0x1e, 0xb1, 0x42, + 0x00, 0xd9, 0x31, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x35, 0xff, 0x76, 0xbd, + 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, 0xff, 0xff, 0xff, 0x0f, + 0x38, 0xb5, 0x23, 0x4b, 0x15, 0x1c, 0x4a, 0x01, 0xd3, 0x18, 0x04, 0x1c, + 0xd8, 0x7a, 0x11, 0x22, 0x10, 0x42, 0x04, 0xd0, 0x42, 0x22, 0x15, 0x42, + 0x01, 0xd0, 0x00, 0x20, 0x36, 0xe0, 0x1d, 0x4a, 0x21, 0x76, 0x12, 0x68, + 0x62, 0x61, 0x5a, 0x7d, 0x18, 0x7d, 0xd9, 0x7e, 0x12, 0x02, 0x02, 0x43, + 0x98, 0x7e, 0x09, 0x02, 0x12, 0x04, 0x01, 0x43, 0x11, 0x43, 0x21, 0x62, + 0xd8, 0x7a, 0x18, 0x22, 0x02, 0x40, 0x0c, 0xd1, 0x5a, 0x7f, 0x19, 0x7f, + 0x12, 0x02, 0x0a, 0x43, 0x99, 0x7f, 0xdb, 0x7f, 0x09, 0x04, 0x0a, 0x43, + 0x1b, 0x06, 0x13, 0x43, 0xe3, 0x61, 0x01, 0x23, 0x09, 0xe0, 0x10, 0x2a, + 0xdb, 0xd1, 0x22, 0x1c, 0x60, 0x6a, 0x1c, 0x32, 0x00, 0xf0, 0x5a, 0xfa, + 0x00, 0x28, 0xd4, 0xd0, 0x04, 0x23, 0x63, 0x72, 0x0f, 0x23, 0x00, 0x21, + 0x2b, 0x40, 0x23, 0x72, 0xe1, 0x60, 0x21, 0x61, 0x01, 0x20, 0x6a, 0x06, + 0x02, 0xd5, 0x20, 0x1c, 0xff, 0xf7, 0x60, 0xff, 0x38, 0xbd, 0xc0, 0x46, + 0x50, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0xf0, 0xb5, 0x45, 0x7a, + 0x87, 0xb0, 0x04, 0x1c, 0x0e, 0x1c, 0x01, 0x93, 0x00, 0x2d, 0x00, 0xd0, + 0x86, 0xe0, 0x10, 0x1c, 0x03, 0xa9, 0xff, 0xf7, 0xbb, 0xfd, 0x00, 0x28, + 0x00, 0xd1, 0x80, 0xe0, 0x72, 0x6a, 0x2f, 0x1c, 0x62, 0x62, 0xf5, 0x60, + 0x35, 0x61, 0x33, 0x69, 0xf2, 0x69, 0x93, 0x42, 0x26, 0xd2, 0xdb, 0x05, + 0x1b, 0x0f, 0x30, 0x1c, 0x00, 0x93, 0xff, 0xf7, 0x9f, 0xfe, 0x01, 0x1e, + 0x6f, 0xd0, 0x03, 0x78, 0x00, 0x2b, 0x01, 0xd0, 0xe5, 0x2b, 0x0b, 0xd1, + 0x00, 0x2f, 0x04, 0xd1, 0x00, 0x9b, 0x23, 0x76, 0x34, 0x4b, 0x1b, 0x68, + 0x63, 0x61, 0x0b, 0x78, 0x01, 0x27, 0x00, 0x2b, 0xe3, 0xd1, 0x0d, 0xe0, + 0x03, 0xa8, 0x0b, 0x22, 0x01, 0xf0, 0xa8, 0xfd, 0x00, 0x28, 0xdc, 0xd1, + 0x01, 0x9a, 0x30, 0x23, 0x13, 0x40, 0x30, 0x2b, 0x53, 0xd0, 0x20, 0x1c, + 0x00, 0x99, 0x4b, 0xe0, 0x01, 0x9a, 0x12, 0x23, 0x13, 0x40, 0x12, 0x2b, + 0x4b, 0xd1, 0x00, 0x2f, 0x06, 0xd0, 0x20, 0x1c, 0x01, 0x21, 0xff, 0xf7, + 0x6f, 0xfd, 0x06, 0x1e, 0x0a, 0xd1, 0x42, 0xe0, 0x73, 0x7a, 0x02, 0x2b, + 0x3f, 0xd0, 0x30, 0x1c, 0xff, 0xf7, 0x40, 0xfd, 0x00, 0x28, 0x3a, 0xd0, + 0x1f, 0x4e, 0x27, 0x76, 0x00, 0x21, 0x20, 0x22, 0x30, 0x1c, 0x01, 0xf0, + 0x99, 0xfd, 0x30, 0x1c, 0x03, 0xa9, 0x0b, 0x22, 0x01, 0xf0, 0x8b, 0xfd, + 0x1a, 0x4b, 0x1b, 0x68, 0x00, 0x2b, 0x05, 0xd0, 0x30, 0x1c, 0x31, 0x1c, + 0x10, 0x30, 0x0e, 0x31, 0x98, 0x47, 0x06, 0xe0, 0x21, 0x22, 0x32, 0x74, + 0xb3, 0x73, 0x28, 0x22, 0x08, 0x23, 0x72, 0x74, 0xf3, 0x73, 0x73, 0x7c, + 0x32, 0x7c, 0x1b, 0x02, 0x13, 0x43, 0xff, 0x22, 0x1a, 0x40, 0x1b, 0x0a, + 0xf3, 0x74, 0x73, 0x76, 0xf3, 0x7b, 0xb2, 0x74, 0x32, 0x76, 0xb2, 0x7b, + 0x1b, 0x02, 0x13, 0x43, 0xb3, 0x75, 0x1b, 0x0a, 0xf3, 0x75, 0x00, 0xf0, + 0x21, 0xf9, 0x00, 0x28, 0x07, 0xd0, 0x21, 0x7e, 0x01, 0x9a, 0x20, 0x1c, + 0xff, 0xf7, 0x26, 0xff, 0x05, 0x1c, 0x00, 0xe0, 0x00, 0x25, 0x28, 0x1c, + 0x07, 0xb0, 0xf0, 0xbd, 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x44, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x00, 0x21, 0x04, 0x1c, 0xff, 0xf7, + 0xbb, 0xfe, 0x00, 0x28, 0x0b, 0xd0, 0x20, 0x1c, 0x01, 0x21, 0xff, 0xf7, + 0x15, 0xfd, 0x00, 0x28, 0x05, 0xd0, 0xe5, 0x23, 0x03, 0x70, 0x00, 0x23, + 0x63, 0x72, 0x00, 0xf0, 0xfb, 0xf8, 0x10, 0xbd, 0x10, 0xb5, 0x0a, 0x1c, + 0x0a, 0x49, 0x8a, 0xb0, 0x08, 0x31, 0x00, 0x23, 0x04, 0x1c, 0x00, 0x91, + 0x69, 0x46, 0x4b, 0x72, 0x01, 0x93, 0x68, 0x46, 0x21, 0x1c, 0x02, 0x23, + 0xff, 0xf7, 0x42, 0xff, 0x00, 0x28, 0x02, 0xd0, 0x68, 0x46, 0xff, 0xf7, + 0xd7, 0xff, 0x0a, 0xb0, 0x10, 0xbd, 0xc0, 0x46, 0xf8, 0x4e, 0x00, 0x00, + 0xf0, 0xb5, 0x43, 0x7a, 0x87, 0xb0, 0x04, 0x1c, 0x0d, 0x1c, 0x03, 0x92, + 0x01, 0x2b, 0x0d, 0xd1, 0x03, 0x7a, 0x99, 0x07, 0x0a, 0xd5, 0x5a, 0x07, + 0x0c, 0xd5, 0xe1, 0x69, 0x22, 0x69, 0x8a, 0x42, 0x08, 0xd0, 0x20, 0x1c, + 0xff, 0xf7, 0x06, 0xfe, 0x00, 0x28, 0x03, 0xd1, 0x01, 0x23, 0x63, 0x60, + 0x00, 0x20, 0xaa, 0xe0, 0x03, 0x9b, 0x01, 0x93, 0x3b, 0xe0, 0x60, 0x6a, + 0x73, 0x0a, 0x07, 0x79, 0xf6, 0x05, 0x01, 0x3f, 0x1f, 0x40, 0xff, 0xb2, + 0xf6, 0x0d, 0x00, 0x2f, 0x36, 0xd0, 0x80, 0x22, 0x92, 0x00, 0x92, 0x1b, + 0x01, 0x99, 0x92, 0xb2, 0x0b, 0x1c, 0x91, 0x42, 0x00, 0xd9, 0x13, 0x1c, + 0x9b, 0xb2, 0x02, 0x93, 0x63, 0x6a, 0xe1, 0x68, 0x1a, 0x7c, 0x02, 0x39, + 0x91, 0x40, 0x5a, 0x69, 0x8b, 0x18, 0x02, 0x9a, 0xdf, 0x19, 0x80, 0x23, + 0x9b, 0x00, 0x9a, 0x42, 0x3f, 0xd1, 0x44, 0x4b, 0x19, 0x68, 0xb9, 0x42, + 0x02, 0xd1, 0x01, 0x22, 0x52, 0x42, 0x1a, 0x60, 0x41, 0x4b, 0x39, 0x1c, + 0x18, 0x68, 0x2a, 0x1c, 0xff, 0xf7, 0x22, 0xfc, 0x00, 0x28, 0xc7, 0xd0, + 0x80, 0x22, 0x92, 0x00, 0xad, 0x18, 0x01, 0x99, 0x02, 0x9a, 0x8b, 0x1a, + 0x21, 0x69, 0x9b, 0xb2, 0x01, 0x93, 0x8b, 0x18, 0x23, 0x61, 0x01, 0x9a, + 0x26, 0x69, 0x00, 0x2a, 0xbf, 0xd1, 0x49, 0xe0, 0x00, 0x2e, 0xc6, 0xd1, + 0xe1, 0x68, 0x00, 0x29, 0x03, 0xd1, 0x23, 0x6a, 0x00, 0x2b, 0x16, 0xd1, + 0x0f, 0xe0, 0x05, 0xaa, 0x00, 0xf0, 0xe2, 0xf8, 0x00, 0x28, 0x58, 0xd0, + 0x62, 0x6a, 0x05, 0x9b, 0x01, 0x32, 0xd2, 0x7f, 0x10, 0x2a, 0x01, 0xd1, + 0x2c, 0x4a, 0x00, 0xe0, 0x2c, 0x4a, 0x93, 0x42, 0x05, 0xd3, 0x20, 0x1c, + 0xff, 0xf7, 0x3c, 0xfc, 0x00, 0x28, 0xaa, 0xd1, 0x98, 0xe7, 0xe3, 0x60, + 0xa7, 0xe7, 0x00, 0x2e, 0x0f, 0xd1, 0x23, 0x69, 0xe1, 0x69, 0x8b, 0x42, + 0x0b, 0xd3, 0x00, 0xf0, 0x59, 0xf8, 0x00, 0x28, 0x8c, 0xd0, 0x1f, 0x4b, + 0x01, 0x21, 0x1f, 0x60, 0x21, 0x4b, 0x1a, 0x78, 0x0a, 0x43, 0x1a, 0x70, + 0x06, 0xe0, 0x38, 0x1c, 0x01, 0x21, 0x00, 0xf0, 0x75, 0xf8, 0x00, 0x28, + 0x00, 0xd1, 0x7d, 0xe7, 0x1c, 0x4b, 0x2a, 0x1c, 0xf6, 0x18, 0x02, 0x9b, + 0xf1, 0x18, 0x33, 0x1c, 0x8b, 0x42, 0x04, 0xd0, 0x10, 0x78, 0x01, 0x32, + 0x18, 0x70, 0x01, 0x33, 0xf8, 0xe7, 0x9e, 0x1b, 0xad, 0x19, 0xa8, 0xe7, + 0xe1, 0x69, 0x23, 0x7a, 0x8e, 0x42, 0x01, 0xd9, 0xe6, 0x61, 0x06, 0xe0, + 0x12, 0x4a, 0x12, 0x68, 0x00, 0x2a, 0x06, 0xd0, 0x03, 0x9a, 0x00, 0x2a, + 0x03, 0xd0, 0x80, 0x22, 0x52, 0x42, 0x13, 0x43, 0x23, 0x72, 0x23, 0x7a, + 0x19, 0x07, 0x01, 0xd4, 0x03, 0x98, 0x06, 0xe0, 0x20, 0x1c, 0xff, 0xf7, + 0x8b, 0xfd, 0x00, 0x28, 0x00, 0xd1, 0x51, 0xe7, 0xf6, 0xe7, 0x07, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, + 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, 0x50, 0x03, 0x00, 0x20, + 0x50, 0x01, 0x00, 0x20, 0x44, 0x01, 0x00, 0x20, 0x07, 0xb5, 0x6b, 0x46, + 0xd9, 0x71, 0x07, 0x33, 0x19, 0x1c, 0x01, 0x22, 0xff, 0xf7, 0x22, 0xff, + 0x0e, 0xbd, 0x00, 0x00, 0xf8, 0xb5, 0x0f, 0x4f, 0x01, 0x20, 0x3b, 0x78, + 0x00, 0x2b, 0x18, 0xd0, 0x0d, 0x4e, 0x0e, 0x4b, 0x0e, 0x4d, 0x19, 0x68, + 0x30, 0x68, 0x2a, 0x1c, 0xff, 0xf7, 0x80, 0xfb, 0x00, 0x28, 0x0e, 0xd0, + 0x0b, 0x4c, 0x21, 0x68, 0x00, 0x29, 0x07, 0xd0, 0x30, 0x68, 0x2a, 0x1c, + 0xff, 0xf7, 0x76, 0xfb, 0x00, 0x28, 0x04, 0xd0, 0x00, 0x23, 0x23, 0x60, + 0x00, 0x23, 0x3b, 0x70, 0x01, 0x20, 0xf8, 0xbd, 0x50, 0x03, 0x00, 0x20, + 0x4c, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x48, 0x01, 0x00, 0x20, 0x70, 0xb5, 0x0d, 0x4d, 0x04, 0x1c, 0x2b, 0x68, + 0x0e, 0x1c, 0x83, 0x42, 0x0e, 0xd0, 0xff, 0xf7, 0xcd, 0xff, 0x00, 0x28, + 0x01, 0xd1, 0x00, 0x20, 0x0d, 0xe0, 0x08, 0x4b, 0x21, 0x1c, 0x18, 0x68, + 0x07, 0x4a, 0xff, 0xf7, 0x25, 0xfb, 0x00, 0x28, 0xf5, 0xd0, 0x2c, 0x60, + 0x05, 0x4b, 0x01, 0x20, 0x1a, 0x78, 0x16, 0x43, 0x1e, 0x70, 0x70, 0xbd, + 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x50, 0x03, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xae, 0xff, + 0x00, 0x28, 0x0f, 0xd0, 0x00, 0x23, 0x08, 0x4a, 0x00, 0x21, 0x99, 0x54, + 0x80, 0x22, 0x01, 0x33, 0x92, 0x00, 0x93, 0x42, 0xf7, 0xd1, 0x05, 0x4b, + 0x01, 0x20, 0x1c, 0x60, 0x04, 0x4b, 0x1a, 0x78, 0x02, 0x43, 0x1a, 0x70, + 0x10, 0xbd, 0xc0, 0x46, 0x50, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, + 0x50, 0x03, 0x00, 0x20, 0xc3, 0x68, 0x70, 0xb5, 0x01, 0x33, 0x0c, 0x1c, + 0x15, 0x1c, 0x99, 0x42, 0x01, 0xd9, 0x00, 0x20, 0x21, 0xe0, 0x46, 0x1c, + 0xf1, 0x7f, 0xc2, 0x69, 0xe3, 0x09, 0x10, 0x29, 0x00, 0xd1, 0x23, 0x0a, + 0x98, 0x18, 0x0d, 0x4b, 0x1b, 0x68, 0x98, 0x42, 0x07, 0xd1, 0xf2, 0x7f, + 0x0b, 0x4b, 0x10, 0x2a, 0x09, 0xd1, 0xe4, 0xb2, 0x64, 0x00, 0x1b, 0x5b, + 0x0b, 0xe0, 0x00, 0x21, 0xff, 0xf7, 0x9e, 0xff, 0x00, 0x28, 0xf2, 0xd1, + 0xe3, 0xe7, 0x7f, 0x22, 0x14, 0x40, 0xa4, 0x00, 0x1b, 0x59, 0x1b, 0x01, + 0x1b, 0x09, 0x2b, 0x60, 0x01, 0x20, 0x70, 0xbd, 0x00, 0x00, 0x00, 0x20, + 0x50, 0x01, 0x00, 0x20, 0x73, 0xb5, 0x05, 0x1c, 0x01, 0x91, 0x16, 0x1c, + 0x00, 0x24, 0x28, 0x1c, 0x01, 0x99, 0x01, 0xaa, 0xff, 0xf7, 0xc6, 0xff, + 0x00, 0x28, 0x10, 0xd0, 0x2a, 0x7c, 0x80, 0x23, 0x9b, 0x00, 0x93, 0x40, + 0xe4, 0x18, 0x6b, 0x1c, 0xdb, 0x7f, 0x01, 0x9a, 0x10, 0x2b, 0x01, 0xd1, + 0x03, 0x4b, 0x00, 0xe0, 0x03, 0x4b, 0x9a, 0x42, 0xe9, 0xd3, 0x34, 0x60, + 0x01, 0x20, 0x76, 0xbd, 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, + 0xf7, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x01, 0x92, 0x01, 0x29, 0x32, 0xd9, + 0xc3, 0x68, 0x00, 0x20, 0x01, 0x33, 0x99, 0x42, 0x2e, 0xd8, 0x6f, 0x1c, + 0xfa, 0x7f, 0xee, 0x69, 0xcb, 0x09, 0x10, 0x2a, 0x00, 0xd1, 0x0b, 0x0a, + 0x9e, 0x19, 0x14, 0x4b, 0x1b, 0x68, 0x9e, 0x42, 0x08, 0xd1, 0xfa, 0x7f, + 0x12, 0x4b, 0x10, 0x2a, 0x0b, 0xd1, 0xe4, 0xb2, 0x01, 0x9a, 0x64, 0x00, + 0x1a, 0x53, 0x0b, 0xe0, 0x30, 0x1c, 0x00, 0x21, 0xff, 0xf7, 0x48, 0xff, + 0x00, 0x28, 0xf0, 0xd1, 0x12, 0xe0, 0x7f, 0x22, 0x14, 0x40, 0x01, 0x9a, + 0xa4, 0x00, 0x1a, 0x51, 0x09, 0x4b, 0x01, 0x20, 0x1a, 0x78, 0x02, 0x43, + 0x1a, 0x70, 0x2b, 0x7e, 0x83, 0x42, 0x05, 0xd9, 0xab, 0x68, 0xf6, 0x18, + 0x05, 0x4b, 0x1e, 0x60, 0x00, 0xe0, 0x00, 0x20, 0xfe, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, 0x50, 0x03, 0x00, 0x20, + 0x48, 0x01, 0x00, 0x20, 0xf0, 0xb5, 0x15, 0x68, 0x87, 0xb0, 0x06, 0x1c, + 0x02, 0x91, 0x17, 0x1c, 0x00, 0x2d, 0x03, 0xd0, 0x00, 0x21, 0x01, 0x35, + 0x01, 0x91, 0x06, 0xe0, 0x02, 0x9b, 0x05, 0x68, 0x01, 0x3b, 0x5a, 0x42, + 0x53, 0x41, 0xdb, 0xb2, 0x01, 0x93, 0xf2, 0x68, 0x00, 0x23, 0x01, 0x32, + 0x03, 0x92, 0x2c, 0x1c, 0x00, 0x93, 0x00, 0x99, 0xf2, 0x68, 0x91, 0x42, + 0x21, 0xd2, 0x03, 0x9b, 0x9c, 0x42, 0x01, 0xd9, 0x02, 0x24, 0x25, 0x1c, + 0x30, 0x1c, 0x21, 0x1c, 0x05, 0xaa, 0xff, 0xf7, 0x43, 0xff, 0x00, 0x28, + 0x15, 0xd0, 0x05, 0x99, 0x63, 0x1c, 0x00, 0x29, 0x01, 0xd0, 0x1d, 0x1c, + 0x03, 0xe0, 0x02, 0x99, 0x5a, 0x1b, 0x8a, 0x42, 0x04, 0xd0, 0x00, 0x9a, + 0x1c, 0x1c, 0x01, 0x32, 0x00, 0x92, 0xe0, 0xe7, 0x30, 0x1c, 0x21, 0x1c, + 0x13, 0x4a, 0xff, 0xf7, 0x7f, 0xff, 0x00, 0x28, 0x0b, 0xd1, 0x00, 0x20, + 0x1d, 0xe0, 0x63, 0x1e, 0x30, 0x1c, 0x19, 0x1c, 0x22, 0x1c, 0x00, 0x93, + 0xff, 0xf7, 0x74, 0xff, 0x00, 0x28, 0xf4, 0xd0, 0x00, 0x9c, 0xac, 0x42, + 0xf3, 0xd8, 0x39, 0x68, 0x00, 0x29, 0x06, 0xd1, 0x01, 0x99, 0x3d, 0x60, + 0x00, 0x29, 0x09, 0xd0, 0x01, 0x35, 0x35, 0x60, 0x06, 0xe0, 0x30, 0x1c, + 0x2a, 0x1c, 0xff, 0xf7, 0x61, 0xff, 0x00, 0x28, 0xf2, 0xd1, 0xe0, 0xe7, + 0x01, 0x20, 0x07, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0xff, 0xff, 0xff, 0x0f, + 0x02, 0x23, 0x37, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x03, 0x60, 0x28, 0x1c, + 0x21, 0x1c, 0x01, 0xaa, 0xff, 0xf7, 0xfc, 0xfe, 0x00, 0x28, 0x12, 0xd0, + 0x28, 0x1c, 0x21, 0x1c, 0x00, 0x22, 0xff, 0xf7, 0x47, 0xff, 0x00, 0x28, + 0x0b, 0xd0, 0x6b, 0x1c, 0xdb, 0x7f, 0x01, 0x9c, 0x10, 0x2b, 0x01, 0xd1, + 0x04, 0x4b, 0x00, 0xe0, 0x04, 0x4b, 0x9c, 0x42, 0xe7, 0xd3, 0x01, 0x20, + 0x00, 0xe0, 0x00, 0x20, 0x3e, 0xbd, 0xc0, 0x46, 0xf8, 0xff, 0x00, 0x00, + 0xf8, 0xff, 0xff, 0x0f, 0xf8, 0xb5, 0x44, 0x4b, 0x04, 0x1c, 0x15, 0x1c, + 0x19, 0x60, 0x29, 0xd0, 0x04, 0x2a, 0x01, 0xd9, 0x00, 0x20, 0x7d, 0xe0, + 0x00, 0x20, 0x01, 0x1c, 0xff, 0xf7, 0x90, 0xfe, 0x00, 0x28, 0xf7, 0xd0, + 0x2d, 0x01, 0x3d, 0x4b, 0xa9, 0x35, 0xff, 0x35, 0x5d, 0x19, 0xaa, 0x79, + 0xab, 0x1d, 0x50, 0x06, 0xee, 0xd1, 0xea, 0x7c, 0xa9, 0x7c, 0x12, 0x02, + 0x0a, 0x43, 0x29, 0x7d, 0x09, 0x04, 0x0a, 0x43, 0x69, 0x7d, 0x09, 0x06, + 0x0a, 0x43, 0x63, 0x2a, 0xe2, 0xd9, 0xaa, 0x7b, 0xed, 0x7b, 0x2d, 0x02, + 0x15, 0x43, 0x9a, 0x7a, 0xdb, 0x7a, 0x12, 0x04, 0x15, 0x43, 0x1b, 0x06, + 0x1d, 0x43, 0xd7, 0xd0, 0x28, 0x1c, 0x00, 0x21, 0xff, 0xf7, 0x6a, 0xfe, + 0x00, 0x28, 0xd1, 0xd0, 0x2a, 0x4b, 0x19, 0x7b, 0xda, 0x7a, 0x09, 0x02, + 0x11, 0x43, 0x80, 0x22, 0x92, 0x00, 0x91, 0x42, 0xc8, 0xd1, 0x1a, 0x7c, + 0x00, 0x2a, 0xc5, 0xd0, 0xd9, 0x89, 0x00, 0x29, 0xc2, 0xd0, 0x59, 0x7b, + 0x00, 0x29, 0xbf, 0xd0, 0x22, 0x76, 0x00, 0x22, 0x21, 0x71, 0x22, 0x74, + 0x22, 0x7c, 0x01, 0x20, 0x90, 0x40, 0x81, 0x42, 0x04, 0xd0, 0x50, 0x1c, + 0x20, 0x74, 0x07, 0x2a, 0xf6, 0xd9, 0xb1, 0xe7, 0xd9, 0x8a, 0x00, 0x29, + 0x00, 0xd1, 0x59, 0x6a, 0xa1, 0x60, 0xd8, 0x89, 0x28, 0x18, 0xe0, 0x61, + 0x1f, 0x69, 0x3e, 0x02, 0x36, 0x0c, 0x66, 0x84, 0xb7, 0xb2, 0x1e, 0x7c, + 0x71, 0x43, 0x0e, 0x18, 0x13, 0x48, 0x79, 0x01, 0x09, 0x18, 0x49, 0x12, + 0x71, 0x18, 0x66, 0x62, 0x61, 0x61, 0x18, 0x7d, 0xde, 0x7c, 0x00, 0x02, + 0x30, 0x43, 0x00, 0xd1, 0x18, 0x6a, 0x6d, 0x1a, 0x28, 0x18, 0xd0, 0x40, + 0x02, 0x1c, 0xe0, 0x60, 0x0b, 0x48, 0x61, 0x1c, 0x82, 0x42, 0x01, 0xd8, + 0x0c, 0x23, 0x07, 0xe0, 0x09, 0x48, 0x82, 0x42, 0x01, 0xd8, 0x10, 0x23, + 0x02, 0xe0, 0xdb, 0x6a, 0x63, 0x62, 0x20, 0x23, 0xcb, 0x77, 0x01, 0x20, + 0xf8, 0xbd, 0xc0, 0x46, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0xff, 0x01, 0x00, 0x00, 0xf4, 0x0f, 0x00, 0x00, 0xf4, 0xff, 0x00, 0x00, + 0x08, 0xb5, 0x05, 0x49, 0x05, 0x4a, 0x06, 0x48, 0x00, 0xf0, 0x10, 0xf8, + 0x05, 0x4b, 0x06, 0x49, 0x00, 0x22, 0x1a, 0x70, 0x5a, 0x54, 0x08, 0xbd, + 0x00, 0x50, 0x00, 0x00, 0x01, 0x04, 0x00, 0x00, 0x54, 0x03, 0x00, 0x20, + 0x6c, 0x03, 0x00, 0x20, 0x02, 0x04, 0x00, 0x00, 0x30, 0xb5, 0x09, 0x4c, + 0x09, 0x4b, 0xa5, 0x68, 0x6d, 0x03, 0x6d, 0x0f, 0xad, 0x00, 0xeb, 0x58, + 0x03, 0x60, 0xa4, 0x68, 0x01, 0x61, 0xa4, 0xb2, 0x44, 0x60, 0x5c, 0x43, + 0x9b, 0x00, 0x84, 0x60, 0xc3, 0x60, 0x42, 0x61, 0x30, 0xbd, 0xc0, 0x46, + 0x00, 0x40, 0x00, 0x41, 0x00, 0x55, 0x00, 0x00, 0xf7, 0xb5, 0x1f, 0x4e, + 0x80, 0x27, 0x75, 0x68, 0x03, 0x33, 0x3d, 0x43, 0x9b, 0x08, 0x75, 0x60, + 0x00, 0x2b, 0x34, 0xd0, 0x1b, 0x4d, 0x35, 0x80, 0x35, 0x7d, 0xef, 0x07, + 0xfc, 0xd5, 0x1d, 0x1c, 0x5f, 0x1b, 0x01, 0x97, 0x07, 0x68, 0xbf, 0x08, + 0xbc, 0x46, 0x01, 0x9f, 0x67, 0x45, 0x1f, 0xd2, 0x00, 0x2d, 0x1d, 0xd0, + 0x17, 0x78, 0x01, 0x3d, 0x01, 0x97, 0xff, 0x27, 0xbc, 0x43, 0x01, 0x9f, + 0x3c, 0x43, 0x57, 0x78, 0x3f, 0x02, 0x01, 0x97, 0x0f, 0x4f, 0x3c, 0x40, + 0x01, 0x9f, 0x3c, 0x43, 0x97, 0x78, 0x3f, 0x04, 0xbc, 0x46, 0x0d, 0x4f, + 0x3c, 0x40, 0xd7, 0x78, 0xa4, 0xb2, 0x3f, 0x06, 0x00, 0x97, 0x67, 0x46, + 0x3c, 0x43, 0x00, 0x9f, 0x04, 0x32, 0x3c, 0x43, 0x10, 0xc1, 0xd7, 0xe7, + 0x07, 0x4b, 0x33, 0x80, 0x33, 0x7d, 0xdf, 0x07, 0xfc, 0xd5, 0x2b, 0x1c, + 0xc8, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x44, 0xa5, 0xff, 0xff, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, 0x04, 0xa5, 0xff, 0xff, + 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, 0x1a, 0x80, 0x1a, 0x7d, + 0xd1, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x16, 0x1c, + 0xeb, 0x68, 0x28, 0x1c, 0x21, 0x1c, 0x9e, 0x42, 0x05, 0xd9, 0xff, 0xf7, + 0xe7, 0xff, 0xeb, 0x68, 0xe4, 0x18, 0xf6, 0x1a, 0xf4, 0xe7, 0xff, 0xf7, + 0xe1, 0xff, 0x70, 0xbd, 0x43, 0x7a, 0x00, 0x2b, 0x04, 0xd1, 0x83, 0x72, + 0xc3, 0x72, 0xc3, 0x60, 0x01, 0x23, 0x43, 0x72, 0x70, 0x47, 0x30, 0xb5, + 0x85, 0xb0, 0x04, 0x1c, 0x02, 0xad, 0x00, 0x68, 0x02, 0x91, 0x03, 0x92, + 0x00, 0xf0, 0x88, 0xfc, 0x6b, 0x79, 0xe1, 0x79, 0x22, 0x7a, 0x00, 0x93, + 0x20, 0x68, 0x00, 0x23, 0x00, 0xf0, 0x22, 0xfd, 0x29, 0x79, 0x20, 0x68, + 0x02, 0x9a, 0x00, 0xf0, 0x4b, 0xfc, 0x20, 0x68, 0x00, 0xf0, 0x6e, 0xfc, + 0x05, 0xb0, 0x30, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0x18, 0x26, 0xff, 0xf7, + 0xd7, 0xff, 0x20, 0x79, 0x33, 0x1c, 0x43, 0x43, 0x0d, 0x4d, 0x08, 0x21, + 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x08, 0xfb, 0xa0, 0x79, 0x33, 0x1c, + 0x43, 0x43, 0x08, 0x21, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x00, 0xfb, + 0x60, 0x79, 0x08, 0x21, 0x46, 0x43, 0xad, 0x19, 0x69, 0x56, 0x00, 0xf0, + 0xf9, 0xfa, 0x04, 0x4b, 0x20, 0x1c, 0x06, 0xcb, 0xff, 0xf7, 0xc3, 0xff, + 0x70, 0xbd, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, 0x70, 0x07, 0x00, 0x20, + 0x07, 0xb5, 0x83, 0x7a, 0x00, 0x91, 0x01, 0x92, 0x00, 0x2b, 0x0d, 0xd0, + 0x9a, 0x07, 0x06, 0xd5, 0xef, 0xf3, 0x10, 0x83, 0x5a, 0x42, 0x53, 0x41, + 0xc3, 0x72, 0x72, 0xb6, 0x04, 0xe0, 0xda, 0x07, 0x02, 0xd5, 0x82, 0x89, + 0x03, 0x4b, 0x9a, 0x60, 0x00, 0x99, 0x01, 0x9a, 0xff, 0xf7, 0xa5, 0xff, + 0x07, 0xbd, 0xc0, 0x46, 0x00, 0x18, 0x00, 0x40, 0x83, 0x7a, 0x00, 0x2b, + 0x0b, 0xd0, 0x9a, 0x07, 0x04, 0xd5, 0xc3, 0x7a, 0x00, 0x2b, 0x06, 0xd0, + 0x62, 0xb6, 0x04, 0xe0, 0xda, 0x07, 0x02, 0xd5, 0x82, 0x89, 0x01, 0x4b, + 0xda, 0x60, 0x70, 0x47, 0x00, 0x18, 0x00, 0x40, 0x08, 0xb5, 0x00, 0x68, + 0x00, 0xf0, 0x25, 0xfc, 0x08, 0xbd, 0x00, 0x00, 0x0f, 0x4b, 0x10, 0x4a, + 0x10, 0x49, 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x0f, 0x4b, + 0x0f, 0x48, 0x19, 0x60, 0x0a, 0x21, 0x19, 0x71, 0x09, 0x21, 0x99, 0x71, + 0x08, 0x21, 0x59, 0x71, 0x03, 0x21, 0x5a, 0x72, 0xda, 0x71, 0x19, 0x72, + 0x0a, 0x4b, 0x18, 0x60, 0x1d, 0x20, 0x18, 0x71, 0x1b, 0x20, 0x98, 0x71, + 0x1a, 0x20, 0x5a, 0x72, 0x58, 0x71, 0xda, 0x71, 0x19, 0x72, 0x70, 0x47, + 0x70, 0x07, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, 0x5c, 0x08, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x60, 0x08, 0x00, 0x20, 0x88, 0x07, 0x00, 0x20, + 0x08, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x66, 0xfd, 0x08, 0xbd, 0xc0, 0x46, + 0x98, 0x07, 0x00, 0x20, 0x13, 0xb5, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, + 0x31, 0xfb, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, 0x2d, 0xfb, 0x12, 0x49, + 0x12, 0x48, 0x00, 0xf0, 0x29, 0xfb, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, + 0x25, 0xfb, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, 0x21, 0xfb, 0x12, 0x4c, + 0x12, 0x49, 0x20, 0x1c, 0x00, 0xf0, 0x1c, 0xfb, 0x03, 0x23, 0x00, 0x93, + 0x01, 0x23, 0x01, 0x93, 0x21, 0x1c, 0x0d, 0x22, 0x0e, 0x23, 0x0e, 0x48, + 0x00, 0xf0, 0x2c, 0xfd, 0x13, 0xbd, 0xc0, 0x46, 0x00, 0x08, 0x00, 0x42, + 0x58, 0x08, 0x00, 0x20, 0x00, 0x0c, 0x00, 0x42, 0x5c, 0x08, 0x00, 0x20, + 0x00, 0x10, 0x00, 0x42, 0x60, 0x08, 0x00, 0x20, 0x00, 0x14, 0x00, 0x42, + 0x54, 0x08, 0x00, 0x20, 0x00, 0x18, 0x00, 0x42, 0x64, 0x08, 0x00, 0x20, + 0x68, 0x08, 0x00, 0x20, 0x00, 0x1c, 0x00, 0x42, 0x98, 0x07, 0x00, 0x20, + 0xfe, 0xe7, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x4b, 0x1b, 0x68, 0x00, 0x2b, + 0x00, 0xd0, 0x98, 0x47, 0x08, 0xbd, 0xc0, 0x46, 0x6c, 0x08, 0x00, 0x20, + 0x38, 0xb5, 0x0f, 0x49, 0x0f, 0x4c, 0xa1, 0x42, 0x04, 0xd1, 0x00, 0xf0, + 0x4f, 0xf8, 0xfe, 0xf7, 0xbf, 0xfa, 0x0b, 0xe0, 0x0c, 0x4d, 0x8d, 0x42, + 0xf7, 0xd0, 0x00, 0x23, 0xca, 0x18, 0xe8, 0x18, 0xa2, 0x42, 0x04, 0xd2, + 0x00, 0x68, 0x04, 0x33, 0x10, 0x60, 0xf7, 0xe7, 0xfe, 0xe7, 0x90, 0x42, + 0xeb, 0xd0, 0x06, 0x4b, 0x06, 0x4a, 0x93, 0x42, 0xe7, 0xd2, 0x00, 0x22, + 0x04, 0xc3, 0xf9, 0xe7, 0x00, 0x00, 0x00, 0x20, 0xa0, 0x00, 0x00, 0x20, + 0x48, 0x59, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x20, 0x50, 0x0d, 0x00, 0x20, + 0x08, 0xb5, 0x00, 0xf0, 0x26, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x00, 0xf0, + 0x17, 0xf8, 0x08, 0xbd, 0x01, 0x4b, 0x18, 0x68, 0x70, 0x47, 0xc0, 0x46, + 0x70, 0x08, 0x00, 0x20, 0x70, 0xb5, 0x04, 0x1e, 0x08, 0xd0, 0x05, 0x4b, + 0x1d, 0x68, 0x1e, 0x1c, 0x00, 0xf0, 0x12, 0xf8, 0x33, 0x68, 0x5b, 0x1b, + 0xa3, 0x42, 0xf9, 0xd3, 0x70, 0xbd, 0xc0, 0x46, 0x70, 0x08, 0x00, 0x20, + 0x08, 0xb5, 0x03, 0x4b, 0x1a, 0x68, 0x01, 0x32, 0x1a, 0x60, 0x00, 0xf0, + 0x61, 0xfa, 0x08, 0xbd, 0x70, 0x08, 0x00, 0x20, 0x70, 0x47, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x00, 0x70, 0xb5, 0x49, 0x4a, 0x1e, 0x21, 0x53, 0x68, + 0x02, 0x20, 0x8b, 0x43, 0x03, 0x43, 0x47, 0x49, 0x53, 0x60, 0x8b, 0x69, + 0x08, 0x24, 0x23, 0x43, 0x8b, 0x61, 0x45, 0x4c, 0x45, 0x4b, 0x9c, 0x82, + 0x9c, 0x8a, 0x20, 0x43, 0x98, 0x82, 0x10, 0x1c, 0xda, 0x68, 0x94, 0x07, + 0xfc, 0xd5, 0x42, 0x4a, 0x01, 0x24, 0x14, 0x70, 0x14, 0x78, 0xe5, 0x07, + 0x04, 0xd5, 0x3f, 0x4c, 0x64, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xf7, 0xdb, + 0x01, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, + 0x3a, 0x4d, 0x39, 0x4c, 0x65, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x82, 0x25, 0x35, 0x4c, 0xed, 0x01, 0x65, 0x80, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x02, 0x24, 0x9c, 0x84, 0xdc, 0x68, + 0xe6, 0x06, 0xfc, 0xd5, 0x31, 0x4d, 0x2e, 0x4c, 0xe5, 0x62, 0xdd, 0x68, + 0x2c, 0x4c, 0xee, 0x06, 0xfb, 0xd5, 0xa5, 0x8c, 0x2e, 0x4e, 0x35, 0x43, + 0xa5, 0x84, 0xdd, 0x68, 0x28, 0x4c, 0xee, 0x06, 0xfb, 0xd5, 0xa5, 0x8c, + 0x02, 0x26, 0x35, 0x43, 0xa5, 0x84, 0xdc, 0x68, 0x25, 0x06, 0xfc, 0xd5, + 0x23, 0x4c, 0xe4, 0x68, 0x66, 0x06, 0xf8, 0xd5, 0xdc, 0x68, 0xe5, 0x06, + 0xfc, 0xd5, 0x00, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x22, 0x4d, 0x1d, 0x4c, 0x65, 0x60, 0x55, 0x78, 0x1c, 0x4c, + 0x6d, 0xb2, 0x00, 0x2d, 0xfa, 0xdb, 0x1e, 0x6a, 0x1e, 0x4d, 0x35, 0x40, + 0x1d, 0x62, 0x1d, 0x6a, 0x80, 0x26, 0xb5, 0x43, 0x1d, 0x62, 0x03, 0x23, + 0xa3, 0x60, 0x1b, 0x4b, 0x63, 0x60, 0x53, 0x78, 0x5b, 0xb2, 0x00, 0x2b, + 0xfb, 0xdb, 0x00, 0x23, 0x0b, 0x72, 0x18, 0x4a, 0x4b, 0x72, 0x8b, 0x72, + 0xcb, 0x72, 0x17, 0x4b, 0xff, 0x21, 0x1a, 0x60, 0x16, 0x4b, 0x17, 0x4a, + 0x1b, 0x68, 0x12, 0x68, 0x5c, 0x01, 0xd2, 0x0e, 0x21, 0x40, 0x11, 0x43, + 0x9a, 0x06, 0x52, 0x0f, 0x12, 0x02, 0x0b, 0x1c, 0x13, 0x43, 0x12, 0x4a, + 0x13, 0x85, 0x43, 0x68, 0x80, 0x22, 0x13, 0x43, 0x43, 0x60, 0x70, 0xbd, + 0x00, 0x40, 0x00, 0x41, 0x00, 0x04, 0x00, 0x40, 0x0c, 0x06, 0x00, 0x00, + 0x00, 0x08, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, 0x01, 0x05, 0x01, 0x00, + 0xb9, 0x05, 0xff, 0x7d, 0x04, 0x0a, 0x00, 0x00, 0x00, 0x07, 0x03, 0x00, + 0xff, 0xfc, 0xff, 0xff, 0x03, 0x06, 0x01, 0x00, 0x00, 0x6c, 0xdc, 0x02, + 0x04, 0x00, 0x00, 0x20, 0x24, 0x60, 0x80, 0x00, 0x20, 0x60, 0x80, 0x00, + 0x00, 0x40, 0x00, 0x42, 0x31, 0x4b, 0xfa, 0x21, 0x18, 0x68, 0x10, 0xb5, + 0x89, 0x00, 0x00, 0xf0, 0xe3, 0xfe, 0x2f, 0x4b, 0x01, 0x38, 0x98, 0x42, + 0x24, 0xd8, 0x2e, 0x4a, 0x2e, 0x4b, 0x50, 0x60, 0x18, 0x6a, 0xc0, 0x21, + 0x00, 0x02, 0x00, 0x0a, 0x09, 0x06, 0x01, 0x43, 0x19, 0x62, 0x00, 0x24, + 0x07, 0x21, 0x94, 0x60, 0x11, 0x60, 0x19, 0x6a, 0x80, 0x22, 0x09, 0x02, + 0x09, 0x0a, 0x12, 0x06, 0x0a, 0x43, 0x1a, 0x62, 0x25, 0x4b, 0xfc, 0x21, + 0x1a, 0x6a, 0x0a, 0x43, 0x1a, 0x62, 0x19, 0x6a, 0xfc, 0x22, 0x92, 0x01, + 0x0a, 0x43, 0x1a, 0x62, 0x19, 0x6a, 0xa0, 0x22, 0xd2, 0x02, 0x0a, 0x43, + 0x1a, 0x62, 0x00, 0xe0, 0xfe, 0xe7, 0x20, 0x1c, 0x00, 0x21, 0x01, 0x34, + 0x00, 0xf0, 0x70, 0xf8, 0x0f, 0x2c, 0xf8, 0xd1, 0x1a, 0x4c, 0x63, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfa, 0xdb, 0x19, 0x4b, 0x63, 0x80, 0x19, 0x4b, + 0x5a, 0x7e, 0xd2, 0x09, 0x01, 0x2a, 0xfa, 0xd0, 0xe4, 0x22, 0xd2, 0x00, + 0x9a, 0x80, 0x3f, 0x22, 0xda, 0x70, 0x59, 0x7e, 0x13, 0x4a, 0xc9, 0x09, + 0x01, 0x29, 0xfa, 0xd0, 0xc0, 0x23, 0x5b, 0x01, 0x00, 0x20, 0x13, 0x61, + 0x90, 0x70, 0x00, 0xf0, 0x23, 0xf8, 0x63, 0x78, 0x5b, 0xb2, 0x00, 0x2b, + 0xfb, 0xdb, 0x0d, 0x4a, 0x09, 0x4b, 0x5a, 0x80, 0x0c, 0x4b, 0xda, 0x79, + 0xd2, 0x09, 0x01, 0x2a, 0xfa, 0xd0, 0x41, 0x22, 0x5a, 0x70, 0x10, 0xbd, + 0x04, 0x00, 0x00, 0x20, 0xff, 0xff, 0xff, 0x00, 0x10, 0xe0, 0x00, 0xe0, + 0x00, 0xed, 0x00, 0xe0, 0x00, 0x04, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, + 0x1e, 0x40, 0x00, 0x00, 0x00, 0x40, 0x00, 0x42, 0x21, 0x40, 0x00, 0x00, + 0x00, 0x48, 0x00, 0x42, 0x00, 0xb5, 0x14, 0x4a, 0x51, 0x7e, 0x13, 0x1c, + 0xc9, 0x09, 0x01, 0x29, 0xf9, 0xd0, 0x01, 0x38, 0x04, 0x28, 0x13, 0xd8, + 0x19, 0x69, 0x10, 0x4a, 0x0a, 0x40, 0x1a, 0x61, 0x5a, 0x78, 0x0f, 0x21, + 0x8a, 0x43, 0x00, 0xf0, 0x55, 0xfe, 0x03, 0x05, 0x09, 0x07, 0x03, 0x00, + 0x01, 0x21, 0x02, 0xe0, 0x03, 0x21, 0x00, 0xe0, 0x02, 0x21, 0x0a, 0x43, + 0x5a, 0x70, 0x0a, 0xe0, 0x11, 0x69, 0xf0, 0x23, 0x1b, 0x05, 0x0b, 0x43, + 0x13, 0x61, 0x53, 0x78, 0x0f, 0x21, 0x8b, 0x43, 0x02, 0x21, 0x0b, 0x43, + 0x53, 0x70, 0x00, 0xbd, 0x00, 0x40, 0x00, 0x42, 0xff, 0xff, 0xff, 0xf0, + 0x10, 0xb5, 0x18, 0x24, 0x02, 0x1c, 0x20, 0x1c, 0x50, 0x43, 0x27, 0x4b, + 0x18, 0x18, 0x00, 0x7a, 0x40, 0xb2, 0x01, 0x30, 0x46, 0xd0, 0x03, 0x29, + 0x44, 0xd8, 0x08, 0x1c, 0x21, 0x1c, 0x00, 0xf0, 0x29, 0xfe, 0x02, 0x33, + 0x11, 0x21, 0x62, 0x43, 0x98, 0x56, 0x9a, 0x18, 0xc3, 0x01, 0x1f, 0x48, + 0x52, 0x68, 0x1b, 0x18, 0x99, 0x18, 0x40, 0x31, 0x02, 0x20, 0x08, 0x70, + 0x01, 0x21, 0x91, 0x40, 0x59, 0x60, 0x2f, 0xe0, 0x62, 0x43, 0x98, 0x56, + 0x18, 0x49, 0x9a, 0x18, 0x52, 0x68, 0xc3, 0x01, 0x5b, 0x18, 0x99, 0x18, + 0x40, 0x31, 0x06, 0x20, 0x08, 0x70, 0x01, 0x21, 0x91, 0x40, 0x59, 0x60, + 0x99, 0x61, 0x1f, 0xe0, 0x51, 0x43, 0x5a, 0x56, 0x10, 0x48, 0x59, 0x18, + 0x4b, 0x68, 0xd2, 0x01, 0x11, 0x18, 0xc8, 0x18, 0x40, 0x30, 0x06, 0x24, + 0x04, 0x70, 0x01, 0x20, 0x98, 0x40, 0x48, 0x60, 0x0b, 0x49, 0x52, 0x18, + 0x50, 0x60, 0x0d, 0xe0, 0x62, 0x43, 0x98, 0x56, 0x9a, 0x18, 0xc3, 0x01, + 0x06, 0x48, 0x52, 0x68, 0x1b, 0x18, 0x99, 0x18, 0x40, 0x31, 0x02, 0x20, + 0x08, 0x70, 0x01, 0x21, 0x91, 0x40, 0x99, 0x60, 0x10, 0xbd, 0xc0, 0x46, + 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0x10, 0x44, 0x00, 0x41, + 0x18, 0x23, 0x58, 0x43, 0x13, 0x4a, 0xf0, 0xb5, 0x13, 0x18, 0x08, 0x24, + 0x1c, 0x57, 0x01, 0x34, 0x1f, 0xd0, 0x82, 0x56, 0x10, 0x4e, 0xd2, 0x01, + 0x5d, 0x68, 0x01, 0x24, 0x90, 0x19, 0x23, 0x1c, 0x86, 0x68, 0xab, 0x40, + 0x1e, 0x42, 0x0b, 0xd1, 0x0e, 0x1c, 0x77, 0x1e, 0xbe, 0x41, 0x40, 0x19, + 0x34, 0x40, 0x40, 0x30, 0xa5, 0x00, 0x04, 0x78, 0x04, 0x26, 0xb4, 0x43, + 0x2c, 0x43, 0x04, 0x70, 0x00, 0x29, 0x03, 0xd1, 0x05, 0x49, 0x52, 0x18, + 0x53, 0x60, 0x02, 0xe0, 0x02, 0x4e, 0x92, 0x19, 0x93, 0x61, 0xf0, 0xbd, + 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0x10, 0x44, 0x00, 0x41, + 0x18, 0x22, 0x42, 0x43, 0xf8, 0xb5, 0x2d, 0x4d, 0x08, 0x24, 0xaa, 0x18, + 0x14, 0x57, 0x03, 0x1c, 0x62, 0x1c, 0x50, 0xd0, 0x48, 0x1c, 0x00, 0x24, + 0x0c, 0x28, 0x4c, 0xd8, 0x00, 0xf0, 0xa0, 0xfd, 0x07, 0x1e, 0x1e, 0x1e, + 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x0a, 0x0a, 0x0a, 0x0a, 0x00, 0x01, 0x24, + 0x64, 0x42, 0x40, 0xe0, 0x09, 0x29, 0x02, 0xd1, 0x18, 0x1c, 0x00, 0x21, + 0x03, 0xe0, 0x0a, 0x29, 0x04, 0xd1, 0x18, 0x1c, 0x02, 0x21, 0xff, 0xf7, + 0x51, 0xff, 0x23, 0xe0, 0x00, 0x24, 0x0b, 0x29, 0x31, 0xd1, 0x18, 0x1c, + 0x01, 0x21, 0xff, 0xf7, 0x49, 0xff, 0x2c, 0xe0, 0x18, 0x22, 0x53, 0x43, + 0xea, 0x18, 0x52, 0x68, 0xeb, 0x56, 0x01, 0x20, 0x14, 0x1c, 0x04, 0x40, + 0x55, 0x08, 0xdb, 0x01, 0x00, 0x2c, 0x11, 0xd0, 0x12, 0x4c, 0x1b, 0x19, + 0x5d, 0x19, 0x30, 0x35, 0x2e, 0x78, 0x0c, 0x01, 0x0f, 0x21, 0x31, 0x40, + 0x21, 0x43, 0x9a, 0x18, 0xc9, 0xb2, 0x29, 0x70, 0x40, 0x32, 0x13, 0x78, + 0x18, 0x43, 0x10, 0x70, 0x00, 0x24, 0x0e, 0xe0, 0x09, 0x4e, 0x0f, 0x27, + 0x9b, 0x19, 0x5d, 0x19, 0x30, 0x35, 0x2e, 0x78, 0x9a, 0x18, 0xbe, 0x43, + 0x31, 0x43, 0xc9, 0xb2, 0x29, 0x70, 0x40, 0x32, 0x13, 0x78, 0x18, 0x43, + 0x10, 0x70, 0x20, 0x1c, 0xf8, 0xbd, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, + 0x00, 0x44, 0x00, 0x41, 0xf7, 0xb5, 0x8a, 0x18, 0x06, 0x1c, 0x0d, 0x1c, + 0x01, 0x92, 0x0c, 0x1c, 0x01, 0x9b, 0x67, 0x1b, 0x9c, 0x42, 0x07, 0xd0, + 0x33, 0x68, 0x21, 0x78, 0x1b, 0x68, 0x30, 0x1c, 0x98, 0x47, 0x01, 0x34, + 0x00, 0x28, 0xf3, 0xd1, 0x38, 0x1c, 0xfe, 0xbd, 0x15, 0x4a, 0x13, 0x68, + 0x58, 0x1c, 0x25, 0xd0, 0x01, 0x3b, 0x13, 0x60, 0x00, 0x2b, 0x21, 0xd1, + 0x72, 0xb6, 0x12, 0x4a, 0x12, 0x4b, 0x04, 0x32, 0x9a, 0x42, 0x07, 0xd8, + 0xbf, 0xf3, 0x4f, 0x8f, 0x10, 0x4a, 0x11, 0x4b, 0xda, 0x60, 0xbf, 0xf3, + 0x4f, 0x8f, 0x11, 0xe0, 0x0f, 0x4b, 0x19, 0x7d, 0xc8, 0x07, 0xfb, 0xd5, + 0x18, 0x8b, 0x20, 0x21, 0xff, 0x31, 0x92, 0x08, 0x52, 0x00, 0x01, 0x43, + 0x19, 0x83, 0xda, 0x61, 0x0a, 0x4a, 0x1a, 0x80, 0x1a, 0x7d, 0xd1, 0x07, + 0xfc, 0xd5, 0xe5, 0xe7, 0xc0, 0x46, 0xfd, 0xe7, 0x70, 0x47, 0xc0, 0x46, + 0x08, 0x00, 0x00, 0x20, 0x00, 0x20, 0x00, 0x00, 0x03, 0x02, 0x00, 0x00, + 0x04, 0x00, 0xfa, 0x05, 0x00, 0xed, 0x00, 0xe0, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x01, 0x60, 0x70, 0x47, 0xf7, 0xb5, 0x08, 0xac, + 0x26, 0x78, 0x04, 0x68, 0x9d, 0x1e, 0x27, 0x68, 0x6c, 0x1e, 0xa5, 0x41, + 0xec, 0xb2, 0x92, 0x07, 0x05, 0x68, 0x3a, 0x43, 0x27, 0x06, 0x3a, 0x43, + 0x2a, 0x60, 0x02, 0x68, 0x07, 0x25, 0x29, 0x40, 0x50, 0x68, 0xb5, 0x01, + 0x00, 0x2c, 0x00, 0xd0, 0x5c, 0x03, 0x29, 0x43, 0x01, 0x43, 0x0c, 0x43, + 0x54, 0x60, 0xf7, 0xbd, 0x30, 0xb5, 0x03, 0x68, 0xc0, 0x25, 0x1c, 0x68, + 0xad, 0x03, 0x12, 0x05, 0x2a, 0x40, 0x22, 0x43, 0xc0, 0x24, 0xa4, 0x02, + 0x09, 0x04, 0x21, 0x40, 0x11, 0x43, 0x19, 0x60, 0x03, 0x68, 0x5a, 0x68, + 0x14, 0x43, 0x5c, 0x60, 0x30, 0xbd, 0x03, 0x68, 0x01, 0x21, 0x1a, 0x68, + 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, 0x11, 0x68, 0x01, 0x23, 0x19, 0x42, + 0xfb, 0xd1, 0xd1, 0x69, 0x19, 0x42, 0xf8, 0xd1, 0x70, 0x47, 0x03, 0x68, + 0x02, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, 0xd3, 0x69, + 0x99, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd1, 0x07, + 0x02, 0xd4, 0x1a, 0x7e, 0x91, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0x03, 0x68, + 0x00, 0x22, 0x5a, 0x83, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x40, 0x07, + 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x09, 0x70, 0x47, + 0x03, 0x68, 0x80, 0x22, 0x19, 0x7e, 0x52, 0x42, 0x0a, 0x43, 0x1a, 0x76, + 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x01, 0x23, 0x18, 0x40, 0x70, 0x47, + 0x03, 0x68, 0x18, 0x8d, 0xc0, 0xb2, 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, + 0x01, 0x20, 0x02, 0x42, 0xfb, 0xd0, 0x19, 0x85, 0x70, 0x47, 0x03, 0x68, + 0x01, 0x21, 0x9a, 0x7d, 0x0a, 0x43, 0x9a, 0x75, 0x70, 0x47, 0x03, 0x68, + 0x01, 0x22, 0x1a, 0x75, 0x70, 0x47, 0x00, 0x00, 0x70, 0xb5, 0x03, 0x68, + 0x01, 0x26, 0x8d, 0x07, 0xed, 0x0f, 0x31, 0x40, 0x1c, 0x68, 0x6d, 0x07, + 0x09, 0x07, 0x29, 0x43, 0x21, 0x43, 0x19, 0x60, 0x04, 0x68, 0x51, 0x00, + 0x03, 0x48, 0x00, 0xf0, 0x79, 0xfc, 0x01, 0x38, 0xc0, 0xb2, 0x20, 0x73, + 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x6c, 0xdc, 0x02, 0x03, 0x68, 0x01, 0x21, + 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, 0x11, 0x68, 0x01, 0x23, + 0x19, 0x42, 0xfb, 0xd1, 0xd1, 0x69, 0x19, 0x42, 0xf8, 0xd1, 0x70, 0x47, + 0x03, 0x68, 0x02, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, + 0xd3, 0x69, 0x99, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, 0xda, 0x69, + 0x91, 0x07, 0xfc, 0xd4, 0x1a, 0x68, 0x02, 0x21, 0x8a, 0x43, 0x1a, 0x60, + 0x70, 0x47, 0x03, 0x68, 0x9a, 0x6a, 0x52, 0x0a, 0x52, 0x02, 0x11, 0x43, + 0x99, 0x62, 0x03, 0x68, 0x1a, 0x7e, 0x51, 0x07, 0xfc, 0xd5, 0x98, 0x6a, + 0xc0, 0xb2, 0x70, 0x47, 0x03, 0x68, 0x22, 0x4a, 0x30, 0xb5, 0x93, 0x42, + 0x11, 0xd0, 0x21, 0x4a, 0x93, 0x42, 0x11, 0xd0, 0x20, 0x4a, 0x93, 0x42, + 0x11, 0xd0, 0x20, 0x4a, 0x93, 0x42, 0x11, 0xd0, 0x1f, 0x4a, 0x93, 0x42, + 0x11, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x30, 0xd1, 0x0e, 0x23, 0x19, 0x22, + 0x0d, 0xe0, 0x09, 0x23, 0x14, 0x22, 0x0a, 0xe0, 0x0a, 0x23, 0x15, 0x22, + 0x07, 0xe0, 0x0b, 0x23, 0x16, 0x22, 0x04, 0xe0, 0x0c, 0x23, 0x17, 0x22, + 0x01, 0xe0, 0x0d, 0x23, 0x18, 0x22, 0xdc, 0xb2, 0x15, 0x49, 0x01, 0x20, + 0x9b, 0x08, 0xa0, 0x40, 0x9b, 0x00, 0x08, 0x60, 0x5b, 0x18, 0x03, 0x20, + 0xc0, 0x21, 0x89, 0x00, 0x04, 0x40, 0x5d, 0x58, 0xe0, 0x00, 0xff, 0x24, + 0x84, 0x40, 0xa5, 0x43, 0x2c, 0x1c, 0xc0, 0x25, 0x85, 0x40, 0x28, 0x1c, + 0x20, 0x43, 0x58, 0x50, 0x80, 0x23, 0xdb, 0x01, 0x1a, 0x43, 0x0a, 0x4b, + 0x5a, 0x80, 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, 0x30, 0xbd, + 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, 0x00, 0x10, 0x00, 0x42, + 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, 0x00, 0x1c, 0x00, 0x42, + 0x00, 0xe1, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x40, 0xf8, 0xb5, 0x04, 0x1c, + 0x15, 0x1c, 0x0e, 0x1c, 0x1f, 0x1c, 0xff, 0xf7, 0xa3, 0xff, 0x20, 0x1c, + 0xff, 0xf7, 0x0b, 0xff, 0xb1, 0x00, 0x1c, 0x22, 0x0a, 0x40, 0x69, 0x07, + 0x23, 0x68, 0x09, 0x0c, 0x0a, 0x43, 0x1a, 0x60, 0x22, 0x68, 0x84, 0x23, + 0x93, 0x75, 0x01, 0x2e, 0x1a, 0xd1, 0x08, 0x21, 0x01, 0x2d, 0x00, 0xd1, + 0x10, 0x21, 0x0c, 0x4b, 0x79, 0x43, 0x18, 0x68, 0xc0, 0x00, 0x00, 0xf0, + 0xcd, 0xfb, 0x23, 0x68, 0x07, 0x21, 0x9a, 0x89, 0x01, 0x40, 0xd2, 0x04, + 0x49, 0x03, 0xd2, 0x0c, 0x0a, 0x43, 0x9a, 0x81, 0x23, 0x68, 0x00, 0x04, + 0xc2, 0x0c, 0x98, 0x89, 0x40, 0x0b, 0x40, 0x03, 0x10, 0x43, 0x98, 0x81, + 0xf8, 0xbd, 0xc0, 0x46, 0x04, 0x00, 0x00, 0x20, 0xf7, 0xb5, 0x01, 0x93, + 0x08, 0xab, 0x04, 0x1c, 0x1f, 0x78, 0x0d, 0x1c, 0x16, 0x1c, 0xff, 0xf7, + 0x3d, 0xff, 0x20, 0x1c, 0xff, 0xf7, 0x68, 0xff, 0xbf, 0x07, 0x0c, 0x22, + 0x17, 0x43, 0xc0, 0x22, 0x92, 0x03, 0x36, 0x05, 0x16, 0x40, 0xc0, 0x22, + 0x92, 0x02, 0x2d, 0x04, 0x23, 0x68, 0x3e, 0x43, 0x01, 0x99, 0x15, 0x40, + 0x35, 0x43, 0x07, 0x22, 0x1d, 0x60, 0x0a, 0x40, 0x80, 0x21, 0x23, 0x68, + 0x89, 0x02, 0x0a, 0x43, 0x5a, 0x60, 0xf7, 0xbd, 0x01, 0x20, 0x70, 0x47, + 0x08, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, 0x98, 0x47, 0x08, 0xbd, + 0x13, 0x04, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, 0x00, 0x69, 0xff, 0xf7, + 0xac, 0xfe, 0x20, 0x1c, 0x14, 0x30, 0x00, 0xf0, 0x41, 0xfb, 0x20, 0x1c, + 0x5c, 0x30, 0x00, 0xf0, 0x3d, 0xfb, 0x10, 0xbd, 0x08, 0xb5, 0x14, 0x30, + 0x00, 0xf0, 0x4a, 0xfb, 0x08, 0xbd, 0x10, 0xb5, 0x04, 0x1c, 0x20, 0x1c, + 0x5c, 0x30, 0x00, 0xf0, 0x43, 0xfb, 0x00, 0x28, 0xf9, 0xd1, 0x20, 0x69, + 0xff, 0xf7, 0xab, 0xfe, 0x10, 0xbd, 0x08, 0xb5, 0x5c, 0x30, 0x00, 0xf0, + 0x3f, 0xfb, 0x08, 0xbd, 0x70, 0xb5, 0x05, 0x1c, 0x14, 0x35, 0x04, 0x1c, + 0x28, 0x1c, 0x00, 0xf0, 0x23, 0xfb, 0x23, 0x1c, 0xa8, 0x33, 0x1b, 0x78, + 0x06, 0x1c, 0xff, 0x2b, 0x0a, 0xd0, 0x28, 0x1c, 0x00, 0xf0, 0x2e, 0xfb, + 0x0a, 0x28, 0x05, 0xdd, 0x23, 0x1c, 0xb0, 0x33, 0xb4, 0x34, 0x1b, 0x68, + 0x22, 0x68, 0x1a, 0x60, 0x30, 0x1c, 0x70, 0xbd, 0x08, 0xb5, 0x14, 0x30, + 0x00, 0xf0, 0x2a, 0xfb, 0x08, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0x00, 0x69, + 0x0e, 0x1c, 0xff, 0xf7, 0x9c, 0xfe, 0x25, 0x1c, 0x5c, 0x35, 0x00, 0x28, + 0x04, 0xd0, 0x28, 0x1c, 0x00, 0xf0, 0x0c, 0xfb, 0x00, 0x28, 0x0c, 0xd0, + 0x28, 0x1c, 0x00, 0xf0, 0x20, 0xfb, 0x00, 0x28, 0xfa, 0xd1, 0x28, 0x1c, + 0x31, 0x1c, 0x00, 0xf0, 0xe4, 0xfa, 0x20, 0x69, 0xff, 0xf7, 0x97, 0xfe, + 0x03, 0xe0, 0x20, 0x69, 0x31, 0x1c, 0xff, 0xf7, 0x8b, 0xfe, 0x01, 0x20, + 0x70, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x85, 0xb0, 0x1d, 0x1c, 0x0a, 0xab, + 0x1b, 0x78, 0x04, 0x1c, 0x00, 0x93, 0x0b, 0xab, 0x1b, 0x78, 0x16, 0x1c, + 0x01, 0x93, 0x0c, 0xab, 0x1b, 0x78, 0x0f, 0x1c, 0x02, 0x93, 0x0d, 0xab, + 0x1b, 0x78, 0x03, 0x93, 0x00, 0x23, 0x43, 0x60, 0xfa, 0x23, 0x9b, 0x00, + 0x83, 0x60, 0x0d, 0x4b, 0x08, 0x33, 0x03, 0x60, 0x14, 0x30, 0x00, 0xf0, + 0xb1, 0xfa, 0x20, 0x1c, 0x5c, 0x30, 0x00, 0xf0, 0xad, 0xfa, 0x00, 0x9a, + 0x23, 0x1c, 0xa4, 0x33, 0x27, 0x61, 0x9a, 0x70, 0x01, 0x9a, 0x20, 0x1c, + 0xda, 0x70, 0x02, 0x9a, 0x1e, 0x70, 0x1a, 0x71, 0x03, 0x9a, 0x5d, 0x70, + 0x1a, 0x75, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0x80, 0x58, 0x00, 0x00, + 0x30, 0xb5, 0x85, 0xb0, 0x04, 0x1c, 0x08, 0xa8, 0x05, 0x78, 0x09, 0xa8, + 0x00, 0x78, 0x00, 0x95, 0x01, 0x90, 0xff, 0x20, 0x02, 0x90, 0x03, 0x90, + 0x20, 0x1c, 0xff, 0xf7, 0xbd, 0xff, 0x20, 0x1c, 0x05, 0xb0, 0x30, 0xbd, + 0x38, 0xb5, 0x04, 0x1c, 0x00, 0x69, 0xff, 0xf7, 0x24, 0xfe, 0x00, 0x28, + 0x19, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x34, 0xfe, 0x25, 0x1c, 0x14, 0x35, + 0x01, 0x1c, 0x28, 0x1c, 0x00, 0xf0, 0x83, 0xfa, 0x23, 0x1c, 0xa8, 0x33, + 0x1b, 0x78, 0xff, 0x2b, 0x0b, 0xd0, 0x28, 0x1c, 0x00, 0xf0, 0x9e, 0xfa, + 0x09, 0x28, 0x06, 0xdc, 0x23, 0x1c, 0x22, 0x1c, 0xac, 0x33, 0xb4, 0x32, + 0x1b, 0x68, 0x12, 0x68, 0x1a, 0x60, 0x20, 0x69, 0xff, 0xf7, 0x15, 0xfe, + 0x00, 0x28, 0x11, 0xd0, 0x25, 0x1c, 0x5c, 0x35, 0x28, 0x1c, 0x00, 0xf0, + 0x85, 0xfa, 0x00, 0x28, 0x07, 0xd0, 0x28, 0x1c, 0x00, 0xf0, 0x72, 0xfa, + 0xc1, 0xb2, 0x20, 0x69, 0xff, 0xf7, 0x0e, 0xfe, 0x02, 0xe0, 0x20, 0x69, + 0xff, 0xf7, 0x17, 0xfe, 0x20, 0x69, 0xff, 0xf7, 0xf3, 0xfd, 0x00, 0x28, + 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0xf2, 0xfd, 0x20, 0x69, 0xff, 0xf7, + 0xe2, 0xfd, 0x38, 0xbd, 0xf0, 0x23, 0x08, 0x1c, 0x18, 0x40, 0x30, 0x38, + 0x43, 0x42, 0x58, 0x41, 0x70, 0x47, 0xf0, 0x23, 0x1b, 0x01, 0x19, 0x40, + 0x80, 0x23, 0x9b, 0x00, 0x99, 0x42, 0x0c, 0xd0, 0xc0, 0x23, 0x9b, 0x00, + 0x99, 0x42, 0x06, 0xd0, 0x80, 0x23, 0x5b, 0x00, 0x05, 0x20, 0x99, 0x42, + 0x04, 0xd0, 0x00, 0x20, 0x02, 0xe0, 0x07, 0x20, 0x00, 0xe0, 0x06, 0x20, + 0x70, 0x47, 0x0f, 0x23, 0x19, 0x40, 0x01, 0x29, 0x05, 0xd0, 0x02, 0x39, + 0x4b, 0x42, 0x4b, 0x41, 0x02, 0x20, 0xc0, 0x1a, 0x00, 0xe0, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x00, 0xf0, 0xb5, 0x03, 0x1c, 0x85, 0xb0, 0x03, 0x91, + 0xa4, 0x33, 0x04, 0x1c, 0x18, 0x27, 0x18, 0x78, 0x3b, 0x1c, 0x43, 0x43, + 0x34, 0x4e, 0x08, 0x21, 0xf3, 0x18, 0x59, 0x56, 0x15, 0x1c, 0xff, 0xf7, + 0xa5, 0xfc, 0x23, 0x1c, 0xa5, 0x33, 0x18, 0x78, 0x3b, 0x1c, 0x43, 0x43, + 0x08, 0x21, 0xf3, 0x18, 0x59, 0x56, 0xff, 0xf7, 0x9b, 0xfc, 0x23, 0x1c, + 0xa7, 0x33, 0x1b, 0x78, 0x02, 0x2b, 0x0a, 0xd1, 0x23, 0x1c, 0xb8, 0x33, + 0x18, 0x78, 0xff, 0x28, 0x05, 0xd0, 0x47, 0x43, 0x08, 0x21, 0xf7, 0x19, + 0x79, 0x56, 0xff, 0xf7, 0x8b, 0xfc, 0x27, 0x1c, 0xa8, 0x37, 0x38, 0x78, + 0xff, 0x28, 0x1a, 0xd0, 0x01, 0x21, 0xff, 0xf7, 0xf9, 0xfb, 0x3b, 0x78, + 0x18, 0x22, 0x5a, 0x43, 0xb3, 0x56, 0x1f, 0x4f, 0xdb, 0x01, 0x21, 0x1c, + 0xac, 0x31, 0xd8, 0x19, 0x08, 0x60, 0x1d, 0x49, 0xb6, 0x18, 0x5b, 0x18, + 0x21, 0x1c, 0x72, 0x68, 0xb0, 0x31, 0x0b, 0x60, 0x01, 0x21, 0x91, 0x40, + 0x0a, 0x1c, 0x21, 0x1c, 0xb4, 0x31, 0x0a, 0x60, 0x1a, 0x60, 0x01, 0x21, + 0x0a, 0x1c, 0x03, 0x9b, 0x20, 0x69, 0xff, 0xf7, 0x31, 0xfe, 0x29, 0x1c, + 0x20, 0x1c, 0xff, 0xf7, 0x88, 0xff, 0x29, 0x1c, 0x07, 0x1c, 0x20, 0x1c, + 0xff, 0xf7, 0x99, 0xff, 0x29, 0x1c, 0x06, 0x1c, 0x20, 0x1c, 0xff, 0xf7, + 0x77, 0xff, 0x39, 0x1c, 0x00, 0x90, 0x33, 0x1c, 0x20, 0x69, 0x01, 0x22, + 0xff, 0xf7, 0x02, 0xfd, 0x23, 0x1c, 0xa7, 0x33, 0x19, 0x78, 0x01, 0x3b, + 0x1a, 0x78, 0x20, 0x69, 0xff, 0xf7, 0x16, 0xfd, 0x20, 0x69, 0xff, 0xf7, + 0x34, 0xfd, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, + 0x18, 0x44, 0x00, 0x41, 0x14, 0x44, 0x00, 0x41, 0x3f, 0x20, 0x70, 0x47, + 0x13, 0xb5, 0x02, 0x68, 0x6b, 0x46, 0xd9, 0x71, 0x07, 0x33, 0x54, 0x68, + 0x19, 0x1c, 0x01, 0x22, 0xa0, 0x47, 0x16, 0xbd, 0x08, 0xb5, 0x00, 0x69, + 0x02, 0x21, 0x00, 0xf0, 0x49, 0xf8, 0x08, 0xbd, 0x08, 0xb5, 0x00, 0x69, + 0x03, 0x21, 0x00, 0xf0, 0x59, 0xf8, 0x08, 0xbd, 0x38, 0xb5, 0x0d, 0x1c, + 0x04, 0x1c, 0x13, 0x1c, 0x00, 0x69, 0x03, 0x21, 0x2a, 0x1c, 0x00, 0xf0, + 0xf1, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x01, 0x23, 0x63, 0x60, 0x38, 0xbd, + 0x10, 0xb5, 0x05, 0x4c, 0x23, 0x68, 0x5a, 0x1c, 0x04, 0xd1, 0x03, 0x68, + 0x5b, 0x69, 0x98, 0x47, 0x20, 0x60, 0x03, 0x1c, 0x18, 0x1c, 0x10, 0xbd, + 0x0c, 0x00, 0x00, 0x20, 0x07, 0x4a, 0x08, 0xb5, 0x13, 0x68, 0x59, 0x1c, + 0x04, 0xd0, 0x01, 0x21, 0x49, 0x42, 0x11, 0x60, 0x18, 0x1c, 0x03, 0xe0, + 0x00, 0x69, 0x02, 0x21, 0x00, 0xf0, 0xc2, 0xf8, 0x08, 0xbd, 0xc0, 0x46, + 0x0c, 0x00, 0x00, 0x20, 0x06, 0x4b, 0xfa, 0x21, 0x89, 0x00, 0x99, 0x60, + 0x05, 0x49, 0x00, 0x22, 0x08, 0x31, 0x19, 0x60, 0x04, 0x49, 0x5a, 0x60, + 0x19, 0x61, 0x1a, 0x76, 0x70, 0x47, 0xc0, 0x46, 0x74, 0x08, 0x00, 0x20, + 0xb8, 0x58, 0x00, 0x00, 0x34, 0x0c, 0x00, 0x20, 0x08, 0xb5, 0x08, 0x4b, + 0x8a, 0x00, 0xd0, 0x58, 0x00, 0x28, 0x03, 0xd0, 0x03, 0x68, 0x9b, 0x68, + 0x98, 0x47, 0x06, 0xe0, 0xc9, 0xb2, 0x04, 0x4b, 0x49, 0x01, 0x59, 0x18, + 0x88, 0x68, 0x80, 0x04, 0x80, 0x0c, 0x08, 0xbd, 0x18, 0x0c, 0x00, 0x20, + 0x38, 0x0c, 0x00, 0x20, 0x10, 0xb5, 0x0c, 0x1c, 0xff, 0xf7, 0xe6, 0xff, + 0x00, 0x28, 0x0c, 0xd0, 0x06, 0x4b, 0xe1, 0xb2, 0x1b, 0x68, 0x08, 0x31, + 0x49, 0x01, 0x59, 0x18, 0x4a, 0x79, 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, + 0x4b, 0x71, 0x02, 0x23, 0xcb, 0x71, 0x10, 0xbd, 0x38, 0x0c, 0x00, 0x20, + 0x10, 0xb5, 0xc9, 0xb2, 0x0c, 0x48, 0x49, 0x01, 0x43, 0x18, 0x9a, 0x68, + 0x92, 0x04, 0x92, 0x0c, 0x3f, 0x2a, 0x08, 0xd9, 0x14, 0x1c, 0x9a, 0x68, + 0x40, 0x3c, 0xa4, 0x04, 0x92, 0x0b, 0xa4, 0x0c, 0x92, 0x03, 0x22, 0x43, + 0x02, 0xe0, 0x9a, 0x68, 0x92, 0x0b, 0x92, 0x03, 0x9a, 0x60, 0x41, 0x18, + 0x88, 0x68, 0xc0, 0xb2, 0x10, 0xbd, 0xc0, 0x46, 0x38, 0x0c, 0x00, 0x20, + 0xf0, 0xb5, 0x1c, 0x1c, 0x2a, 0x4b, 0x85, 0xb0, 0x1b, 0x68, 0x06, 0x1c, + 0x0d, 0x1c, 0x02, 0x92, 0x00, 0x2b, 0x46, 0xd0, 0x27, 0x4b, 0x8a, 0x00, + 0xd0, 0x58, 0x00, 0x28, 0x05, 0xd0, 0x03, 0x68, 0x02, 0x99, 0x5b, 0x68, + 0x22, 0x1c, 0x98, 0x47, 0x3f, 0xe0, 0x30, 0x1c, 0xff, 0xf7, 0x9e, 0xff, + 0xa0, 0x42, 0x04, 0xd2, 0x30, 0x1c, 0x29, 0x1c, 0xff, 0xf7, 0x98, 0xff, + 0x04, 0x1c, 0x29, 0x1c, 0x30, 0x1c, 0xff, 0xf7, 0xbf, 0xff, 0x1c, 0x4f, + 0xe9, 0xb2, 0x4a, 0x01, 0x01, 0x91, 0x39, 0x68, 0x03, 0x92, 0x8b, 0x18, + 0xff, 0x33, 0x5a, 0x7a, 0x01, 0x21, 0x0a, 0x43, 0x17, 0x49, 0x5a, 0x72, + 0xab, 0x01, 0xc9, 0x18, 0x02, 0x98, 0x22, 0x1c, 0x00, 0xf0, 0xb5, 0xf9, + 0x00, 0x2c, 0x1b, 0xd0, 0x30, 0x1c, 0x29, 0x1c, 0xff, 0xf7, 0x7a, 0xff, + 0x00, 0x28, 0x15, 0xd1, 0x01, 0x9b, 0x3a, 0x68, 0x08, 0x33, 0x5b, 0x01, + 0xd3, 0x18, 0x19, 0x79, 0x40, 0x20, 0x01, 0x43, 0x19, 0x71, 0x01, 0x21, + 0xd9, 0x71, 0x03, 0x99, 0x53, 0x18, 0xff, 0x33, 0x9a, 0x7a, 0x01, 0x21, + 0x0a, 0x43, 0x9a, 0x72, 0x02, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x00, 0xe0, + 0x20, 0x1c, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0x3c, 0x0d, 0x00, 0x20, + 0x18, 0x0c, 0x00, 0x20, 0x38, 0x0c, 0x00, 0x20, 0x58, 0x0a, 0x00, 0x20, + 0x13, 0xb5, 0x6c, 0x46, 0x07, 0x34, 0x22, 0x1c, 0x01, 0x23, 0xff, 0xf7, + 0x99, 0xff, 0x01, 0x28, 0x01, 0xd1, 0x20, 0x78, 0x01, 0xe0, 0x01, 0x20, + 0x40, 0x42, 0x16, 0xbd, 0xf0, 0xb5, 0x1c, 0x1c, 0x3a, 0x4b, 0x85, 0xb0, + 0x1b, 0x68, 0x0e, 0x1c, 0x02, 0x92, 0x00, 0x2b, 0x60, 0xd0, 0x80, 0x23, + 0xdb, 0x01, 0x9c, 0x42, 0x5c, 0xd8, 0x00, 0x22, 0x00, 0x92, 0x00, 0x2c, + 0x56, 0xd0, 0x34, 0x4d, 0xf7, 0xb2, 0x2b, 0x68, 0x01, 0x93, 0x3b, 0x1c, + 0x08, 0x33, 0x01, 0x9a, 0x5b, 0x01, 0xd3, 0x18, 0x9b, 0x79, 0xdb, 0x09, + 0x1a, 0xd0, 0x2f, 0x4b, 0x2f, 0x49, 0x18, 0x68, 0x00, 0xf0, 0xc2, 0xf8, + 0x2e, 0x4b, 0x17, 0x21, 0x58, 0x43, 0x00, 0xf0, 0xbd, 0xf8, 0x3b, 0x1c, + 0x08, 0x33, 0x01, 0x9a, 0x5b, 0x01, 0xd3, 0x18, 0xdb, 0x79, 0x9a, 0x07, + 0x08, 0xd4, 0x29, 0x4b, 0x9a, 0x5d, 0x00, 0x2a, 0x38, 0xd1, 0x42, 0x1e, + 0x00, 0x28, 0x35, 0xd0, 0x10, 0x1c, 0xee, 0xe7, 0x24, 0x4b, 0x00, 0x22, + 0x9a, 0x55, 0x25, 0x1e, 0x3f, 0x2d, 0x00, 0xd9, 0x3f, 0x25, 0x22, 0x4a, + 0xb3, 0x01, 0xd3, 0x18, 0x18, 0x1c, 0x02, 0x99, 0x2a, 0x1c, 0x03, 0x93, + 0x00, 0xf0, 0x35, 0xf9, 0x18, 0x4a, 0x7b, 0x01, 0xd3, 0x18, 0x03, 0x9a, + 0xa9, 0x04, 0x5a, 0x61, 0x9a, 0x69, 0x89, 0x0c, 0x92, 0x0b, 0x92, 0x03, + 0x0a, 0x43, 0x9a, 0x61, 0x3b, 0x1c, 0x01, 0x9a, 0x08, 0x33, 0x5b, 0x01, + 0xd3, 0x18, 0x02, 0x22, 0xda, 0x71, 0x59, 0x79, 0x80, 0x22, 0x52, 0x42, + 0x0a, 0x43, 0x5a, 0x71, 0x00, 0x9b, 0x02, 0x9a, 0x5b, 0x19, 0x52, 0x19, + 0x00, 0x93, 0x64, 0x1b, 0x02, 0x92, 0xa6, 0xe7, 0x00, 0x98, 0x0b, 0xe0, + 0x01, 0x20, 0x08, 0xe0, 0x01, 0x22, 0x9a, 0x55, 0x7b, 0x01, 0xed, 0x18, + 0xab, 0x69, 0x10, 0x1c, 0x9b, 0x0b, 0x9b, 0x03, 0xab, 0x61, 0x40, 0x42, + 0x05, 0xb0, 0xf0, 0xbd, 0x3c, 0x0d, 0x00, 0x20, 0x38, 0x0c, 0x00, 0x20, + 0x04, 0x00, 0x00, 0x20, 0x40, 0x42, 0x0f, 0x00, 0x70, 0x11, 0x01, 0x00, + 0x90, 0x08, 0x00, 0x20, 0x98, 0x08, 0x00, 0x20, 0x01, 0x4a, 0x02, 0x4b, + 0x1a, 0x60, 0x70, 0x47, 0x00, 0x50, 0x00, 0x41, 0x38, 0x0c, 0x00, 0x20, + 0x10, 0xb5, 0x00, 0x21, 0x40, 0x22, 0x04, 0x1c, 0x00, 0xf0, 0xf2, 0xf8, + 0x00, 0x23, 0x20, 0x1c, 0x23, 0x64, 0x63, 0x64, 0x10, 0xbd, 0x02, 0x6c, + 0x10, 0xb5, 0x3f, 0x23, 0x54, 0x1c, 0x23, 0x40, 0x44, 0x6c, 0xa3, 0x42, + 0x01, 0xd0, 0x81, 0x54, 0x03, 0x64, 0x10, 0xbd, 0x00, 0x23, 0x03, 0x64, + 0x43, 0x64, 0x70, 0x47, 0x43, 0x6c, 0x02, 0x6c, 0x93, 0x42, 0x06, 0xd0, + 0xc2, 0x5c, 0x3f, 0x21, 0x01, 0x33, 0x0b, 0x40, 0x43, 0x64, 0x10, 0x1c, + 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x70, 0x47, 0x02, 0x6c, 0x43, 0x6c, + 0xd0, 0x1a, 0x00, 0xd5, 0x40, 0x30, 0x70, 0x47, 0x03, 0x6c, 0x40, 0x6c, + 0x83, 0x42, 0x02, 0xdb, 0xc0, 0x1a, 0x3f, 0x30, 0x01, 0xe0, 0xc0, 0x1a, + 0x01, 0x38, 0x70, 0x47, 0x43, 0x6c, 0x02, 0x6c, 0x93, 0x42, 0x01, 0xd0, + 0xc0, 0x5c, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x70, 0x47, 0x02, 0x6c, + 0x3f, 0x23, 0x01, 0x32, 0x1a, 0x40, 0x43, 0x6c, 0xd0, 0x1a, 0x43, 0x42, + 0x58, 0x41, 0xc0, 0xb2, 0x70, 0x47, 0x00, 0x00, 0x02, 0xb4, 0x71, 0x46, + 0x49, 0x08, 0x49, 0x00, 0x09, 0x5c, 0x49, 0x00, 0x8e, 0x44, 0x02, 0xbc, + 0x70, 0x47, 0xc0, 0x46, 0x00, 0x29, 0x34, 0xd0, 0x01, 0x23, 0x00, 0x22, + 0x10, 0xb4, 0x88, 0x42, 0x2c, 0xd3, 0x01, 0x24, 0x24, 0x07, 0xa1, 0x42, + 0x04, 0xd2, 0x81, 0x42, 0x02, 0xd2, 0x09, 0x01, 0x1b, 0x01, 0xf8, 0xe7, + 0xe4, 0x00, 0xa1, 0x42, 0x04, 0xd2, 0x81, 0x42, 0x02, 0xd2, 0x49, 0x00, + 0x5b, 0x00, 0xf8, 0xe7, 0x88, 0x42, 0x01, 0xd3, 0x40, 0x1a, 0x1a, 0x43, + 0x4c, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, 0x5c, 0x08, 0x22, 0x43, + 0x8c, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, 0x9c, 0x08, 0x22, 0x43, + 0xcc, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, 0xdc, 0x08, 0x22, 0x43, + 0x00, 0x28, 0x03, 0xd0, 0x1b, 0x09, 0x01, 0xd0, 0x09, 0x09, 0xe3, 0xe7, + 0x10, 0x1c, 0x10, 0xbc, 0x70, 0x47, 0x00, 0x28, 0x01, 0xd0, 0x00, 0x20, + 0xc0, 0x43, 0x07, 0xb4, 0x02, 0x48, 0x02, 0xa1, 0x40, 0x18, 0x02, 0x90, + 0x03, 0xbd, 0xc0, 0x46, 0x19, 0x00, 0x00, 0x00, 0x00, 0x29, 0xf0, 0xd0, + 0x03, 0xb5, 0xff, 0xf7, 0xb9, 0xff, 0x0e, 0xbc, 0x42, 0x43, 0x89, 0x1a, + 0x18, 0x47, 0xc0, 0x46, 0x70, 0x47, 0xc0, 0x46, 0x70, 0xb5, 0x0e, 0x4b, + 0x0e, 0x4d, 0x00, 0x24, 0xed, 0x1a, 0xad, 0x10, 0x1e, 0x1c, 0xac, 0x42, + 0x04, 0xd0, 0xa3, 0x00, 0xf3, 0x58, 0x98, 0x47, 0x01, 0x34, 0xf8, 0xe7, + 0x00, 0xf0, 0x32, 0xf9, 0x08, 0x4b, 0x09, 0x4d, 0x00, 0x24, 0xed, 0x1a, + 0xad, 0x10, 0x1e, 0x1c, 0xac, 0x42, 0x04, 0xd0, 0xa3, 0x00, 0xf3, 0x58, + 0x98, 0x47, 0x01, 0x34, 0xf8, 0xe7, 0x70, 0xbd, 0x74, 0x00, 0x00, 0x20, + 0x74, 0x00, 0x00, 0x20, 0x74, 0x00, 0x00, 0x20, 0x98, 0x00, 0x00, 0x20, + 0x08, 0xb5, 0x03, 0x4b, 0x01, 0x1c, 0x18, 0x68, 0x00, 0xf0, 0x76, 0xf8, + 0x08, 0xbd, 0xc0, 0x46, 0x70, 0x00, 0x00, 0x20, 0x08, 0xb5, 0x03, 0x4b, + 0x01, 0x1c, 0x18, 0x68, 0x00, 0xf0, 0x24, 0xf8, 0x08, 0xbd, 0xc0, 0x46, + 0x70, 0x00, 0x00, 0x20, 0x30, 0xb5, 0x00, 0x23, 0x93, 0x42, 0x08, 0xd0, + 0xc5, 0x5c, 0x01, 0x33, 0xcc, 0x18, 0x01, 0x3c, 0x24, 0x78, 0xa5, 0x42, + 0xf6, 0xd0, 0x28, 0x1b, 0x00, 0xe0, 0x00, 0x20, 0x30, 0xbd, 0x10, 0xb5, + 0x00, 0x23, 0x93, 0x42, 0x03, 0xd0, 0xcc, 0x5c, 0xc4, 0x54, 0x01, 0x33, + 0xf9, 0xe7, 0x10, 0xbd, 0x03, 0x1c, 0x82, 0x18, 0x93, 0x42, 0x02, 0xd0, + 0x19, 0x70, 0x01, 0x33, 0xfa, 0xe7, 0x70, 0x47, 0x30, 0xb5, 0x00, 0x29, + 0x40, 0xd0, 0x04, 0x39, 0x0b, 0x68, 0x00, 0x2b, 0x00, 0xda, 0xc9, 0x18, + 0x1e, 0x4a, 0x13, 0x68, 0x14, 0x1c, 0x00, 0x2b, 0x02, 0xd1, 0x4b, 0x60, + 0x11, 0x60, 0x33, 0xe0, 0x99, 0x42, 0x0f, 0xd2, 0x08, 0x68, 0x0a, 0x18, + 0x9a, 0x42, 0x05, 0xd1, 0x13, 0x68, 0x52, 0x68, 0xc0, 0x18, 0x08, 0x60, + 0x4a, 0x60, 0x00, 0xe0, 0x4b, 0x60, 0x21, 0x60, 0x24, 0xe0, 0x8a, 0x42, + 0x03, 0xd8, 0x13, 0x1c, 0x5a, 0x68, 0x00, 0x2a, 0xf9, 0xd1, 0x1d, 0x68, + 0x5c, 0x19, 0x8c, 0x42, 0x0b, 0xd1, 0x09, 0x68, 0x69, 0x18, 0x58, 0x18, + 0x19, 0x60, 0x90, 0x42, 0x14, 0xd1, 0x14, 0x68, 0x52, 0x68, 0x09, 0x19, + 0x19, 0x60, 0x5a, 0x60, 0x0e, 0xe0, 0x8c, 0x42, 0x02, 0xd9, 0x0c, 0x23, + 0x03, 0x60, 0x09, 0xe0, 0x08, 0x68, 0x0c, 0x18, 0x94, 0x42, 0x03, 0xd1, + 0x14, 0x68, 0x52, 0x68, 0x00, 0x19, 0x08, 0x60, 0x4a, 0x60, 0x59, 0x60, + 0x30, 0xbd, 0xc0, 0x46, 0x44, 0x0d, 0x00, 0x20, 0x70, 0xb5, 0x03, 0x23, + 0xcd, 0x1c, 0x9d, 0x43, 0x08, 0x35, 0x06, 0x1c, 0x0c, 0x2d, 0x01, 0xd2, + 0x0c, 0x25, 0x01, 0xe0, 0x00, 0x2d, 0x3f, 0xdb, 0x8d, 0x42, 0x3d, 0xd3, + 0x20, 0x4b, 0x1c, 0x68, 0x1a, 0x1c, 0x21, 0x1c, 0x00, 0x29, 0x13, 0xd0, + 0x08, 0x68, 0x43, 0x1b, 0x0d, 0xd4, 0x0b, 0x2b, 0x02, 0xd9, 0x0b, 0x60, + 0xcc, 0x18, 0x1e, 0xe0, 0x8c, 0x42, 0x02, 0xd1, 0x63, 0x68, 0x13, 0x60, + 0x1a, 0xe0, 0x48, 0x68, 0x60, 0x60, 0x0c, 0x1c, 0x16, 0xe0, 0x0c, 0x1c, + 0x49, 0x68, 0xe9, 0xe7, 0x14, 0x4c, 0x20, 0x68, 0x00, 0x28, 0x03, 0xd1, + 0x30, 0x1c, 0x00, 0xf0, 0x25, 0xf8, 0x20, 0x60, 0x30, 0x1c, 0x29, 0x1c, + 0x00, 0xf0, 0x20, 0xf8, 0x43, 0x1c, 0x15, 0xd0, 0xc4, 0x1c, 0x03, 0x23, + 0x9c, 0x43, 0x84, 0x42, 0x0a, 0xd1, 0x25, 0x60, 0x20, 0x1c, 0x0b, 0x30, + 0x07, 0x22, 0x23, 0x1d, 0x90, 0x43, 0xc3, 0x1a, 0x0b, 0xd0, 0x5a, 0x42, + 0xe2, 0x50, 0x08, 0xe0, 0x21, 0x1a, 0x30, 0x1c, 0x00, 0xf0, 0x0a, 0xf8, + 0x01, 0x30, 0xee, 0xd1, 0x0c, 0x23, 0x33, 0x60, 0x00, 0x20, 0x70, 0xbd, + 0x44, 0x0d, 0x00, 0x20, 0x40, 0x0d, 0x00, 0x20, 0x38, 0xb5, 0x07, 0x4c, + 0x00, 0x23, 0x05, 0x1c, 0x08, 0x1c, 0x23, 0x60, 0x00, 0xf0, 0x2a, 0xf8, + 0x43, 0x1c, 0x03, 0xd1, 0x23, 0x68, 0x00, 0x2b, 0x00, 0xd0, 0x2b, 0x60, + 0x38, 0xbd, 0xc0, 0x46, 0x4c, 0x0d, 0x00, 0x20, 0xc9, 0xb2, 0x03, 0x78, + 0x00, 0x2b, 0x03, 0xd0, 0x8b, 0x42, 0x04, 0xd0, 0x01, 0x30, 0xf8, 0xe7, + 0x00, 0x29, 0x00, 0xd0, 0x18, 0x1c, 0x70, 0x47, 0x30, 0xb5, 0x03, 0x1c, + 0x00, 0x2a, 0x07, 0xd0, 0x0c, 0x78, 0x01, 0x33, 0x5d, 0x1e, 0x01, 0x3a, + 0x2c, 0x70, 0x01, 0x31, 0x00, 0x2c, 0xf5, 0xd1, 0x9a, 0x18, 0x93, 0x42, + 0x03, 0xd0, 0x00, 0x21, 0x19, 0x70, 0x01, 0x33, 0xf9, 0xe7, 0x30, 0xbd, + 0x09, 0x4a, 0x13, 0x68, 0x00, 0x2b, 0x0c, 0xd0, 0x18, 0x18, 0x69, 0x46, + 0x88, 0x42, 0x02, 0xd8, 0x10, 0x60, 0x18, 0x1c, 0x70, 0x47, 0x05, 0x4b, + 0x0c, 0x22, 0x01, 0x20, 0x1a, 0x60, 0x40, 0x42, 0xf8, 0xe7, 0x03, 0x4b, + 0x13, 0x60, 0xef, 0xe7, 0x48, 0x0d, 0x00, 0x20, 0x4c, 0x0d, 0x00, 0x20, + 0x50, 0x0d, 0x00, 0x20, 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, + 0x9e, 0x46, 0x70, 0x47, 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, + 0x9e, 0x46, 0x70, 0x47, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x2e, 0x42, + 0x49, 0x4e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x1f, 0x22, 0x00, 0x00, 0x33, 0x22, 0x00, 0x00, + 0x19, 0x22, 0x00, 0x00, 0x5d, 0x22, 0x00, 0x00, 0x61, 0x23, 0x00, 0x00, + 0x8d, 0x22, 0x00, 0x00, 0xa1, 0x22, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x2f, 0x00, 0x7c, 0x3c, 0x3e, 0x5e, 0x2b, 0x3d, 0x3f, 0x2f, 0x5b, 0x5d, + 0x3b, 0x2c, 0x2a, 0x22, 0x5c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x34, 0x00, 0x00, + 0xbd, 0x40, 0x00, 0x00, 0x19, 0x22, 0x00, 0x00, 0x1d, 0x22, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x10, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, + 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, + 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x04, + 0x00, 0x04, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x01, + 0x00, 0x01, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x13, 0x00, 0x01, 0x01, + 0x01, 0x01, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x05, + 0x00, 0x05, 0x0a, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x05, + 0x01, 0x05, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x02, 0x00, + 0x02, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, + 0x03, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x02, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x03, + 0x01, 0x03, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x10, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x11, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0a, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0b, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x05, 0x00, 0x01, 0x00, + 0x01, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x06, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x07, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x03, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xdf, 0x44, 0x00, 0x00, 0xbd, 0x40, 0x00, 0x00, 0x97, 0x44, 0x00, 0x00, + 0x7f, 0x44, 0x00, 0x00, 0x75, 0x44, 0x00, 0x00, 0xa1, 0x44, 0x00, 0x00, + 0xd5, 0x44, 0x00, 0x00, 0x49, 0x44, 0x00, 0x00, 0x8d, 0x46, 0x00, 0x00, + 0x59, 0x44, 0x00, 0x00, 0x45, 0x44, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x85, 0x47, 0x00, 0x00, + 0xb1, 0x47, 0x00, 0x00, 0x81, 0x47, 0x00, 0x00, 0xa5, 0x47, 0x00, 0x00, + 0x99, 0x47, 0x00, 0x00, 0xe9, 0x47, 0x00, 0x00, 0xcd, 0x47, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0xff, 0xff, 0xff, 0x40, 0x42, 0x0f, 0x00, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0xe4, 0x58, 0x00, 0x00, + 0x04, 0x59, 0x00, 0x00, 0x24, 0x59, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xe0, 0x58, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x20, 0xdd, 0x20, 0x00, 0x00, + 0x05, 0x22, 0x00, 0x00, 0xed, 0x26, 0x00, 0x00, 0xa9, 0x2b, 0x00, 0x00, + 0x55, 0x38, 0x00, 0x00, 0x85, 0x3a, 0x00, 0x00, 0xed, 0x3a, 0x00, 0x00, + 0x0d, 0x48, 0x00, 0x00, 0xb1, 0x4a, 0x00, 0x00, 0xb5, 0x20, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00 diff --git a/libraries/SDU/src/boot/mzero.h b/libraries/SDU/src/boot/mzero.h new file mode 100644 index 0000000..f69e155 --- /dev/null +++ b/libraries/SDU/src/boot/mzero.h @@ -0,0 +1,1191 @@ + 0x00, 0x80, 0x00, 0x20, 0x89, 0x5b, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, + 0x71, 0x5b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, + 0xdd, 0x5b, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, + 0x71, 0x5b, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, + 0x71, 0x5b, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, 0x75, 0x5b, 0x00, 0x00, + 0x71, 0x5b, 0x00, 0x00, 0xbd, 0x5a, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, + 0x71, 0x5b, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, + 0xcd, 0x5a, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, + 0x71, 0x5b, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, + 0x71, 0x5b, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, + 0x71, 0x5b, 0x00, 0x00, 0x71, 0x5b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0x94, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0x3c, 0x77, 0x00, 0x00, 0x08, 0xb5, 0x08, 0x4b, 0x00, 0x2b, 0x03, 0xd0, + 0x07, 0x48, 0x08, 0x49, 0x00, 0xe0, 0x00, 0xbf, 0x07, 0x48, 0x03, 0x68, + 0x00, 0x2b, 0x03, 0xd0, 0x06, 0x4b, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, + 0x08, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x77, 0x00, 0x00, + 0x98, 0x00, 0x00, 0x20, 0x90, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xf0, 0xb5, 0x33, 0x4c, 0xa5, 0x44, 0x01, 0xf0, 0x3f, 0xfe, 0x02, 0xf0, + 0x07, 0xfc, 0x01, 0x20, 0x01, 0xf0, 0x68, 0xfd, 0x2f, 0x4d, 0x04, 0x21, + 0x28, 0x1c, 0x00, 0xf0, 0xe7, 0xf9, 0x00, 0x28, 0x44, 0xd0, 0x2d, 0x4e, + 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0xbe, 0xfa, 0x00, 0x28, 0x3d, 0xd0, + 0x29, 0x1c, 0x01, 0xa8, 0x32, 0x1c, 0x01, 0x23, 0x00, 0xf0, 0x6e, 0xfa, + 0x01, 0xa8, 0x00, 0xf0, 0x00, 0xf9, 0x80, 0x21, 0x04, 0x1c, 0xc9, 0x01, + 0x88, 0x42, 0x2d, 0xd9, 0x01, 0xa8, 0x00, 0xf0, 0xe6, 0xf8, 0x22, 0x4a, + 0x80, 0x21, 0xa7, 0x18, 0x21, 0x48, 0x09, 0x02, 0x3a, 0x1c, 0x01, 0xf0, + 0xf5, 0xfb, 0x80, 0x24, 0x24, 0x02, 0x80, 0x22, 0x0a, 0xa9, 0x92, 0x00, + 0x01, 0xa8, 0x00, 0xf0, 0xcf, 0xf8, 0x80, 0x23, 0x21, 0x1c, 0x0a, 0xaa, + 0x9b, 0x00, 0x19, 0x48, 0x01, 0xf0, 0x8e, 0xfb, 0x80, 0x22, 0x92, 0x00, + 0xa3, 0x18, 0x17, 0x4a, 0xa4, 0x18, 0xbc, 0x42, 0x01, 0xd2, 0x1c, 0x1c, + 0xe9, 0xe7, 0x01, 0x24, 0x01, 0xa8, 0x00, 0xf0, 0xed, 0xf8, 0x00, 0x2c, + 0x06, 0xd0, 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0x8d, 0xfa, 0x01, 0xe0, + 0x00, 0x24, 0xf3, 0xe7, 0x80, 0x23, 0x1b, 0x02, 0x1b, 0x68, 0x83, 0xf3, + 0x08, 0x88, 0x0c, 0x4b, 0x80, 0x22, 0x12, 0x02, 0x9a, 0x60, 0x0b, 0x4b, + 0x1b, 0x68, 0x18, 0x47, 0x00, 0x20, 0x8b, 0x23, 0x9b, 0x00, 0x9d, 0x44, + 0xf0, 0xbd, 0xc0, 0x46, 0xd4, 0xfd, 0xff, 0xff, 0xc8, 0x00, 0x00, 0x20, + 0xcc, 0x6b, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xb0, 0x00, 0x00, 0x20, + 0x00, 0x82, 0xff, 0xff, 0x00, 0xed, 0x00, 0xe0, 0x04, 0x80, 0x00, 0x00, + 0x08, 0xb5, 0x00, 0x21, 0x02, 0x48, 0x0a, 0x1c, 0x01, 0xf0, 0x38, 0xfb, + 0x08, 0xbd, 0xc0, 0x46, 0xb0, 0x00, 0x00, 0x20, 0x00, 0x20, 0x70, 0x47, + 0x70, 0x47, 0x13, 0xb5, 0x02, 0x68, 0x6b, 0x46, 0xd9, 0x71, 0x07, 0x33, + 0x54, 0x68, 0x19, 0x1c, 0x01, 0x22, 0xa0, 0x47, 0x16, 0xbd, 0x38, 0xb5, + 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x25, 0xa8, 0x42, 0x02, 0xd1, 0x01, 0x23, + 0x63, 0x60, 0x0a, 0xe0, 0x45, 0x60, 0x92, 0xb2, 0x01, 0xf0, 0x04, 0xf8, + 0x23, 0x6a, 0x5b, 0x68, 0x00, 0x2b, 0x02, 0xd0, 0x01, 0x23, 0x63, 0x60, + 0x28, 0x1c, 0x38, 0xbd, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x01, 0xd0, + 0x00, 0xf0, 0x42, 0xfe, 0x08, 0xbd, 0x00, 0x00, 0x13, 0xb5, 0x6c, 0x46, + 0x07, 0x34, 0x21, 0x1c, 0x01, 0x22, 0x00, 0xf0, 0x5d, 0xfd, 0x01, 0x28, + 0x01, 0xd1, 0x20, 0x78, 0x00, 0xe0, 0x01, 0x48, 0x00, 0xb2, 0x16, 0xbd, + 0xff, 0xff, 0x00, 0x00, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x02, 0xd0, + 0xff, 0xf7, 0xea, 0xff, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x08, 0xbd, + 0x38, 0xb5, 0x05, 0x1c, 0x00, 0x6a, 0x00, 0x28, 0x0a, 0xd0, 0xff, 0xf7, + 0xdf, 0xff, 0x04, 0x1c, 0x63, 0x1c, 0x05, 0xd0, 0x28, 0x6a, 0x01, 0x69, + 0x01, 0x39, 0x00, 0xf0, 0xe5, 0xfd, 0x20, 0x1c, 0x38, 0xbd, 0x00, 0x00, + 0xf8, 0xb5, 0xfa, 0x23, 0x9b, 0x00, 0x83, 0x60, 0x0d, 0x4b, 0x00, 0x25, + 0x08, 0x33, 0x04, 0x1c, 0x45, 0x60, 0x03, 0x60, 0x28, 0x20, 0x0f, 0x1c, + 0x16, 0x1c, 0x02, 0xf0, 0x4d, 0xfb, 0x20, 0x62, 0xa8, 0x42, 0x0a, 0xd0, + 0x39, 0x1c, 0x28, 0x22, 0x02, 0xf0, 0x69, 0xfb, 0x20, 0x1c, 0x10, 0x30, + 0x31, 0x1c, 0x0c, 0x22, 0x02, 0xf0, 0x2e, 0xfc, 0x25, 0x77, 0x20, 0x1c, + 0xf8, 0xbd, 0xc0, 0x46, 0xd8, 0x6b, 0x00, 0x00, 0xfa, 0x22, 0x92, 0x00, + 0x82, 0x60, 0x04, 0x4a, 0x00, 0x23, 0x08, 0x32, 0x43, 0x60, 0x02, 0x60, + 0x03, 0x62, 0x03, 0x74, 0x70, 0x47, 0xc0, 0x46, 0xd8, 0x6b, 0x00, 0x00, + 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x01, 0xd0, 0x00, 0xf0, 0x02, 0xfd, + 0x08, 0xbd, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x04, 0xd0, 0x00, 0xf0, + 0xa5, 0xfd, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x08, 0xbd, 0x03, 0x6a, + 0x00, 0x2b, 0x01, 0xd0, 0x18, 0x69, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, + 0x70, 0x47, 0x00, 0x6a, 0x00, 0x28, 0x00, 0xd0, 0xc0, 0x69, 0x70, 0x47, + 0x38, 0xb5, 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x28, 0x0b, 0xd0, 0x20, 0x1c, + 0xff, 0xf7, 0xf3, 0xff, 0x05, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0xe7, 0xff, + 0x02, 0x4b, 0x28, 0x1a, 0x98, 0x42, 0x00, 0xd9, 0x18, 0x1c, 0x38, 0xbd, + 0xff, 0x7f, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x28, + 0x06, 0xd0, 0x00, 0xf0, 0xe7, 0xfd, 0x20, 0x6a, 0x02, 0xf0, 0xfa, 0xfa, + 0x00, 0x23, 0x23, 0x62, 0x10, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x0a, 0x1c, + 0x0c, 0x49, 0x8a, 0xb0, 0x04, 0x1c, 0x00, 0x23, 0x00, 0x91, 0x69, 0x46, + 0x4b, 0x72, 0x01, 0x93, 0x21, 0x1c, 0x68, 0x46, 0x01, 0x23, 0x00, 0xf0, + 0x81, 0xfe, 0x04, 0x1c, 0x60, 0x1e, 0x84, 0x41, 0xe4, 0xb2, 0x00, 0x2c, + 0x02, 0xd0, 0x68, 0x46, 0x00, 0xf0, 0xc8, 0xfd, 0x20, 0x1c, 0x0a, 0xb0, + 0x10, 0xbd, 0xc0, 0x46, 0x20, 0x6c, 0x00, 0x00, 0x08, 0xb5, 0x01, 0x23, + 0x00, 0x2a, 0x05, 0xd0, 0x00, 0xf0, 0x1a, 0xff, 0x03, 0x1c, 0x58, 0x1e, + 0x83, 0x41, 0xdb, 0xb2, 0x18, 0x1c, 0x08, 0xbd, 0x38, 0xb5, 0x01, 0x22, + 0x05, 0x1c, 0x0c, 0x1c, 0x01, 0xf0, 0x94, 0xf9, 0x02, 0x1c, 0x01, 0x20, + 0x00, 0x2a, 0x03, 0xd1, 0x28, 0x1c, 0x21, 0x1c, 0x01, 0xf0, 0x8c, 0xf9, + 0x38, 0xbd, 0xf0, 0xb5, 0x0c, 0x68, 0x03, 0x5d, 0x2f, 0x3b, 0x5d, 0x42, + 0x6b, 0x41, 0xe4, 0x18, 0x27, 0x1c, 0x0c, 0x37, 0x23, 0x1c, 0xc5, 0x5c, + 0x1e, 0x1b, 0x2f, 0x2d, 0x09, 0xd0, 0x00, 0x2d, 0x07, 0xd0, 0x01, 0x33, + 0x16, 0x1b, 0xf6, 0x18, 0x01, 0x3e, 0x35, 0x70, 0xbb, 0x42, 0xf2, 0xd1, + 0x0c, 0x26, 0x00, 0x24, 0x94, 0x55, 0xc2, 0x5c, 0x2f, 0x3a, 0x54, 0x42, + 0x62, 0x41, 0x9b, 0x18, 0x0b, 0x60, 0xc0, 0x5c, 0x43, 0x1e, 0x98, 0x41, + 0xc0, 0xb2, 0xf0, 0xbd, 0xf0, 0xb5, 0xa1, 0xb0, 0x03, 0x90, 0x25, 0x48, + 0x0d, 0x1c, 0x04, 0x92, 0x05, 0x93, 0x0c, 0xaa, 0x00, 0x23, 0x16, 0xa9, + 0x0d, 0x93, 0x0c, 0x90, 0x53, 0x72, 0x17, 0x93, 0x16, 0x90, 0x4b, 0x72, + 0x07, 0x93, 0x2c, 0x1c, 0x00, 0x92, 0x07, 0xa9, 0x08, 0xaa, 0x03, 0x98, + 0xff, 0xf7, 0xc3, 0xff, 0x01, 0x26, 0x02, 0x1c, 0x72, 0x40, 0x01, 0x90, + 0xd2, 0xb2, 0x20, 0x1c, 0x08, 0xa9, 0x05, 0x9b, 0x04, 0x9f, 0xb8, 0x47, + 0x00, 0x28, 0x07, 0xd1, 0xac, 0x42, 0x01, 0xd1, 0x00, 0x20, 0x23, 0xe0, + 0x20, 0x1c, 0x00, 0xf0, 0x57, 0xfd, 0xf9, 0xe7, 0x01, 0x9f, 0x00, 0x2f, + 0x11, 0xd0, 0x33, 0x1c, 0x00, 0x98, 0x21, 0x1c, 0x08, 0xaa, 0x00, 0xf0, + 0xfd, 0xfd, 0x06, 0x1c, 0xac, 0x42, 0x0f, 0xd0, 0x20, 0x1c, 0x00, 0xf0, + 0x47, 0xfd, 0x00, 0x2e, 0xe8, 0xd0, 0x23, 0x1c, 0x00, 0x9c, 0x00, 0x93, + 0xd1, 0xe7, 0xac, 0x42, 0x02, 0xd0, 0x20, 0x1c, 0x00, 0xf0, 0x3c, 0xfd, + 0x30, 0x1c, 0x03, 0xe0, 0x00, 0x28, 0xdb, 0xd0, 0x16, 0xac, 0xf0, 0xe7, + 0x21, 0xb0, 0xf0, 0xbd, 0x20, 0x6c, 0x00, 0x00, 0x38, 0xb5, 0x03, 0x1c, + 0x41, 0x33, 0x1b, 0x78, 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x2b, 0x02, 0xd0, + 0x38, 0x30, 0x00, 0xf0, 0x27, 0xfd, 0x20, 0x1c, 0x01, 0x21, 0x2a, 0x1c, + 0x00, 0xf0, 0xc8, 0xf9, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x0f, 0xe0, + 0x25, 0x1c, 0x10, 0x35, 0x28, 0x1c, 0x21, 0x1c, 0xff, 0xf7, 0x62, 0xff, + 0x00, 0x28, 0xf5, 0xd0, 0x20, 0x1c, 0x38, 0x30, 0x29, 0x1c, 0x00, 0xf0, + 0xcf, 0xfb, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x38, 0xbd, 0x00, 0x00, + 0x4b, 0x68, 0x43, 0x60, 0x0a, 0x4b, 0x03, 0x60, 0x0b, 0x7a, 0x03, 0x72, + 0x4b, 0x7a, 0x43, 0x72, 0xcb, 0x68, 0xc3, 0x60, 0x0b, 0x69, 0x03, 0x61, + 0x4b, 0x69, 0x43, 0x61, 0x0b, 0x7e, 0x03, 0x76, 0xcb, 0x69, 0xc3, 0x61, + 0x0b, 0x6a, 0x49, 0x6a, 0x03, 0x62, 0x41, 0x62, 0x70, 0x47, 0xc0, 0x46, + 0x20, 0x6c, 0x00, 0x00, 0xf0, 0xb5, 0x9d, 0xb0, 0x08, 0xae, 0x02, 0x92, + 0x03, 0x93, 0x27, 0x4a, 0x00, 0x23, 0x12, 0xaf, 0x05, 0x1c, 0x73, 0x60, + 0x7b, 0x60, 0x10, 0x31, 0x30, 0x1c, 0x08, 0x92, 0x73, 0x72, 0x12, 0x92, + 0x7b, 0x72, 0x00, 0xf0, 0x9d, 0xfb, 0x02, 0x9c, 0x20, 0x1c, 0x2f, 0x21, + 0x02, 0xf0, 0xc8, 0xfa, 0x00, 0x28, 0x2e, 0xd0, 0x23, 0x78, 0x2f, 0x2b, + 0x01, 0xd1, 0x01, 0x34, 0xf4, 0xe7, 0x00, 0x1b, 0xc0, 0xb2, 0x03, 0x1c, + 0x0c, 0x28, 0x00, 0xd9, 0x0c, 0x23, 0xdb, 0xb2, 0x1a, 0x1c, 0x21, 0x1c, + 0x04, 0xa8, 0x01, 0x93, 0x02, 0xf0, 0xc0, 0xfa, 0x01, 0x9a, 0x00, 0x23, + 0x04, 0xa9, 0x38, 0x1c, 0x8b, 0x54, 0x00, 0xf0, 0xbf, 0xfc, 0x38, 0x1c, + 0x31, 0x1c, 0x04, 0xaa, 0x01, 0x23, 0x00, 0xf0, 0x69, 0xfd, 0x00, 0x28, + 0x04, 0xd1, 0x0c, 0x4b, 0x68, 0x60, 0x2b, 0x60, 0x68, 0x72, 0x10, 0xe0, + 0x01, 0x9b, 0x30, 0x1c, 0xe4, 0x18, 0x00, 0xf0, 0xad, 0xfc, 0x33, 0x1c, + 0x3e, 0x1c, 0x1f, 0x1c, 0xca, 0xe7, 0x02, 0x99, 0x03, 0x9a, 0x64, 0x1a, + 0x14, 0x60, 0x28, 0x1c, 0x31, 0x1c, 0xff, 0xf7, 0x95, 0xff, 0x28, 0x1c, + 0x1d, 0xb0, 0xf0, 0xbd, 0x20, 0x6c, 0x00, 0x00, 0xf0, 0xb5, 0xa1, 0xb0, + 0x05, 0x1c, 0x1f, 0x1c, 0x02, 0xa8, 0x01, 0xab, 0x16, 0x1c, 0xff, 0xf7, + 0xa1, 0xff, 0x01, 0x9b, 0xf6, 0x18, 0x33, 0x78, 0x00, 0x2b, 0x07, 0xd1, + 0x02, 0xa9, 0x16, 0xa8, 0xff, 0xf7, 0x7e, 0xff, 0x28, 0x1c, 0x16, 0xa9, + 0x17, 0x4a, 0x28, 0xe0, 0x00, 0x23, 0x0c, 0xac, 0x63, 0x60, 0x63, 0x72, + 0x6b, 0x46, 0x11, 0x33, 0x14, 0x4a, 0x1b, 0x78, 0x0c, 0x92, 0x00, 0x2b, + 0x03, 0xd1, 0x28, 0x1c, 0xff, 0xf7, 0x4a, 0xfe, 0x1b, 0xe0, 0x20, 0x1c, + 0x02, 0xa9, 0x32, 0x1c, 0x3b, 0x1c, 0x00, 0xf0, 0x21, 0xfd, 0x00, 0x28, + 0xf3, 0xd0, 0x02, 0xa8, 0x00, 0xf0, 0x6c, 0xfc, 0x06, 0x23, 0x1f, 0x40, + 0x9f, 0x42, 0x03, 0xd1, 0x20, 0x1c, 0x13, 0x99, 0x00, 0xf0, 0xf6, 0xfb, + 0x21, 0x1c, 0x16, 0xa8, 0xff, 0xf7, 0x54, 0xff, 0x28, 0x1c, 0x16, 0xa9, + 0x32, 0x1c, 0xff, 0xf7, 0x0b, 0xfe, 0x28, 0x1c, 0x21, 0xb0, 0xf0, 0xbd, + 0x00, 0x6c, 0x00, 0x00, 0x20, 0x6c, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x1c, + 0x08, 0x1c, 0x19, 0x1c, 0x38, 0x31, 0x02, 0x4a, 0x00, 0x23, 0xff, 0xf7, + 0xc9, 0xfe, 0x08, 0xbd, 0xa5, 0x43, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x1c, + 0x08, 0x1c, 0x19, 0x1c, 0x38, 0x31, 0x02, 0x4a, 0x00, 0x23, 0xff, 0xf7, + 0xbd, 0xfe, 0x08, 0xbd, 0xe1, 0x43, 0x00, 0x00, 0x08, 0x4b, 0x02, 0x21, + 0x19, 0x61, 0x19, 0x1c, 0x00, 0x22, 0x30, 0x31, 0x0a, 0x70, 0x06, 0x49, + 0x5a, 0x71, 0x9a, 0x71, 0x9a, 0x72, 0x1a, 0x73, 0xda, 0x63, 0x99, 0x63, + 0x41, 0x33, 0x1a, 0x70, 0x70, 0x47, 0xc0, 0x46, 0xc8, 0x00, 0x00, 0x20, + 0x20, 0x6c, 0x00, 0x00, 0x08, 0xb5, 0x01, 0x1c, 0x01, 0x48, 0x01, 0xf0, + 0xab, 0xf9, 0x08, 0xbd, 0x6c, 0x07, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, + 0xff, 0x21, 0x01, 0xf0, 0xa3, 0xf9, 0x08, 0xbd, 0x6c, 0x07, 0x00, 0x20, + 0x08, 0xb5, 0x01, 0x21, 0x00, 0x79, 0x01, 0xf0, 0x2d, 0xfc, 0x05, 0x4b, + 0x1a, 0x78, 0x00, 0x2a, 0x04, 0xd0, 0x00, 0x22, 0x03, 0x48, 0x1a, 0x70, + 0x01, 0xf0, 0x80, 0xf9, 0x08, 0xbd, 0xc0, 0x46, 0x34, 0x01, 0x00, 0x20, + 0x6c, 0x07, 0x00, 0x20, 0x10, 0xb5, 0x08, 0x4b, 0x04, 0x1c, 0x1a, 0x78, + 0x00, 0x2a, 0x06, 0xd1, 0x01, 0x22, 0x1a, 0x70, 0x05, 0x4b, 0x06, 0x48, + 0x06, 0xcb, 0x01, 0xf0, 0x51, 0xf9, 0x20, 0x79, 0x00, 0x21, 0x01, 0xf0, + 0x0d, 0xfc, 0x10, 0xbd, 0x34, 0x01, 0x00, 0x20, 0x2c, 0x01, 0x00, 0x20, + 0x6c, 0x07, 0x00, 0x20, 0x10, 0xb5, 0x83, 0x79, 0x04, 0x1c, 0x00, 0x2b, + 0x0d, 0xd0, 0x23, 0x89, 0x5a, 0x1c, 0x22, 0x81, 0x05, 0x4a, 0x93, 0x42, + 0x02, 0xd8, 0xff, 0xf7, 0xbf, 0xff, 0xf6, 0xe7, 0x20, 0x1c, 0xff, 0xf7, + 0xc3, 0xff, 0x00, 0x23, 0xa3, 0x71, 0x10, 0xbd, 0x01, 0x02, 0x00, 0x00, + 0x00, 0xb5, 0x06, 0x29, 0x03, 0xd9, 0x16, 0x23, 0x43, 0x71, 0x00, 0x20, + 0x1c, 0xe0, 0x0f, 0x4b, 0x05, 0x29, 0x13, 0xd8, 0x08, 0x1c, 0x00, 0x22, + 0x02, 0xf0, 0x52, 0xf8, 0x03, 0x05, 0x07, 0x09, 0x0b, 0x0d, 0x0b, 0x49, + 0x08, 0xe0, 0x0b, 0x49, 0x06, 0xe0, 0x0b, 0x49, 0x04, 0xe0, 0x0b, 0x49, + 0x02, 0xe0, 0x0b, 0x49, 0x00, 0xe0, 0x0b, 0x49, 0x19, 0x60, 0x02, 0xe0, + 0x0a, 0x4a, 0x1a, 0x60, 0x00, 0x22, 0x1a, 0x71, 0x5a, 0x71, 0x01, 0x20, + 0x00, 0xbd, 0xc0, 0x46, 0x2c, 0x01, 0x00, 0x20, 0x00, 0x1b, 0xb7, 0x00, + 0x00, 0x09, 0x3d, 0x00, 0x80, 0x84, 0x1e, 0x00, 0x40, 0x42, 0x0f, 0x00, + 0x20, 0xa1, 0x07, 0x00, 0x90, 0xd0, 0x03, 0x00, 0x48, 0xe8, 0x01, 0x00, + 0x38, 0xb5, 0x0c, 0x1c, 0x01, 0xf0, 0xde, 0xf9, 0x05, 0x1c, 0xff, 0xf7, + 0x79, 0xff, 0xff, 0x28, 0x06, 0xd0, 0x01, 0xf0, 0xd7, 0xf9, 0x40, 0x1b, + 0xa0, 0x42, 0xf6, 0xd3, 0x00, 0x20, 0x00, 0xe0, 0x01, 0x20, 0x38, 0xbd, + 0xf8, 0xb5, 0x04, 0x1c, 0x0e, 0x1c, 0x17, 0x1c, 0xff, 0xf7, 0x9c, 0xff, + 0x20, 0x1c, 0xff, 0xf7, 0x81, 0xff, 0x96, 0x21, 0x49, 0x00, 0x20, 0x1c, + 0xff, 0xf7, 0xe0, 0xff, 0x40, 0x20, 0x30, 0x43, 0xff, 0xf7, 0x54, 0xff, + 0x18, 0x25, 0x38, 0x1c, 0xe8, 0x40, 0xc0, 0xb2, 0x08, 0x3d, 0xff, 0xf7, + 0x4d, 0xff, 0x2b, 0x1c, 0x08, 0x33, 0xf6, 0xd1, 0x95, 0x20, 0x00, 0x2e, + 0x03, 0xd0, 0x87, 0x20, 0x08, 0x2e, 0x00, 0xd0, 0xff, 0x20, 0xff, 0xf7, + 0x41, 0xff, 0x00, 0x25, 0xff, 0xf7, 0x46, 0xff, 0x43, 0xb2, 0xe0, 0x72, + 0x00, 0x2b, 0x04, 0xda, 0xff, 0x2d, 0x02, 0xd0, 0x01, 0x35, 0xed, 0xb2, + 0xf4, 0xe7, 0xf8, 0xbd, 0xf7, 0xb5, 0x00, 0x25, 0x02, 0x71, 0x05, 0x73, + 0x85, 0x72, 0x85, 0x71, 0x45, 0x71, 0x04, 0x1c, 0x01, 0x91, 0x01, 0xf0, + 0x93, 0xf9, 0x01, 0x21, 0x07, 0x1c, 0x20, 0x79, 0x01, 0xf0, 0x0c, 0xfb, + 0x01, 0x21, 0x20, 0x79, 0x01, 0xf0, 0x62, 0xfb, 0x42, 0x4e, 0x30, 0x1c, + 0x01, 0xf0, 0x76, 0xf8, 0x41, 0x4b, 0x42, 0x49, 0x1d, 0x71, 0x5d, 0x71, + 0x19, 0x60, 0x30, 0x1c, 0x5a, 0x68, 0x01, 0xf0, 0x95, 0xf8, 0x0a, 0x25, + 0x01, 0x3d, 0xff, 0x20, 0xed, 0xb2, 0xff, 0xf7, 0x0d, 0xff, 0x00, 0x2d, + 0xf8, 0xd1, 0x30, 0x1c, 0x01, 0xf0, 0xa6, 0xf8, 0x20, 0x1c, 0xff, 0xf7, + 0x29, 0xff, 0x00, 0x21, 0x20, 0x1c, 0x0a, 0x1c, 0xff, 0xf7, 0x9a, 0xff, + 0x06, 0x1c, 0xe0, 0x72, 0x01, 0x28, 0x08, 0xd0, 0x01, 0xf0, 0x64, 0xf9, + 0xfa, 0x23, 0xc0, 0x1b, 0xdb, 0x00, 0x98, 0x42, 0xef, 0xd9, 0x01, 0x23, + 0x3b, 0xe0, 0xd5, 0x22, 0x20, 0x1c, 0x08, 0x21, 0x52, 0x00, 0xff, 0xf7, + 0x87, 0xff, 0x04, 0x23, 0x18, 0x42, 0x01, 0xd0, 0x26, 0x73, 0x0b, 0xe0, + 0x1e, 0x1c, 0xff, 0xf7, 0xed, 0xfe, 0x01, 0x3e, 0xf6, 0xb2, 0xe0, 0x72, + 0x00, 0x2e, 0xf8, 0xd1, 0x02, 0x23, 0xaa, 0x28, 0x25, 0xd1, 0x23, 0x73, + 0x26, 0x7b, 0x02, 0x3e, 0x73, 0x42, 0x5e, 0x41, 0xb6, 0x07, 0x37, 0x21, + 0x00, 0x22, 0x20, 0x1c, 0xff, 0xf7, 0x6c, 0xff, 0x32, 0x1c, 0x20, 0x1c, + 0x29, 0x21, 0xff, 0xf7, 0x67, 0xff, 0x02, 0x1c, 0xe0, 0x72, 0x08, 0xd0, + 0x01, 0xf0, 0x32, 0xf9, 0xfa, 0x23, 0xc0, 0x1b, 0xdb, 0x00, 0x98, 0x42, + 0xeb, 0xd9, 0x08, 0x23, 0x09, 0xe0, 0x23, 0x7b, 0x02, 0x2b, 0x19, 0xd1, + 0x20, 0x1c, 0x3a, 0x21, 0xff, 0xf7, 0x54, 0xff, 0x00, 0x28, 0x05, 0xd0, + 0x06, 0x23, 0x63, 0x71, 0x20, 0x1c, 0xff, 0xf7, 0xc3, 0xfe, 0x15, 0xe0, + 0xff, 0xf7, 0xb8, 0xfe, 0xc0, 0x23, 0x18, 0x40, 0x98, 0x42, 0x01, 0xd1, + 0x03, 0x23, 0x23, 0x73, 0xff, 0xf7, 0xb0, 0xfe, 0xff, 0xf7, 0xae, 0xfe, + 0xff, 0xf7, 0xac, 0xfe, 0x20, 0x1c, 0xff, 0xf7, 0xb1, 0xfe, 0x20, 0x1c, + 0x01, 0x99, 0xff, 0xf7, 0xef, 0xfe, 0x05, 0x1c, 0x28, 0x1c, 0xfe, 0xbd, + 0x6c, 0x07, 0x00, 0x20, 0x2c, 0x01, 0x00, 0x20, 0x90, 0xd0, 0x03, 0x00, + 0x38, 0xb5, 0x04, 0x1c, 0x01, 0xf0, 0xfa, 0xf8, 0x05, 0x1c, 0xff, 0xf7, + 0x95, 0xfe, 0xe0, 0x72, 0xff, 0x28, 0x08, 0xd1, 0x01, 0xf0, 0xf2, 0xf8, + 0x96, 0x23, 0x40, 0x1b, 0x5b, 0x00, 0x98, 0x42, 0xf3, 0xd9, 0x0f, 0x23, + 0x02, 0xe0, 0xfe, 0x28, 0x06, 0xd0, 0x0d, 0x23, 0x20, 0x1c, 0x63, 0x71, + 0xff, 0xf7, 0x8a, 0xfe, 0x00, 0x20, 0x00, 0xe0, 0x01, 0x20, 0x38, 0xbd, + 0xf8, 0xb5, 0x04, 0x1c, 0x0f, 0x1c, 0x15, 0x1c, 0x1e, 0x1e, 0x45, 0xd0, + 0x9a, 0x18, 0x80, 0x23, 0x9b, 0x00, 0x9a, 0x42, 0x42, 0xdc, 0x83, 0x79, + 0x00, 0x2b, 0x05, 0xd0, 0x02, 0x68, 0x91, 0x42, 0x02, 0xd1, 0x03, 0x89, + 0xab, 0x42, 0x16, 0xd9, 0x23, 0x7b, 0x27, 0x60, 0x03, 0x2b, 0x00, 0xd0, + 0x7f, 0x02, 0x3a, 0x1c, 0x20, 0x1c, 0x11, 0x21, 0xff, 0xf7, 0xf2, 0xfe, + 0x07, 0x1e, 0x02, 0xd0, 0x03, 0x23, 0x63, 0x71, 0x2a, 0xe0, 0x20, 0x1c, + 0xff, 0xf7, 0xbc, 0xff, 0x00, 0x28, 0x25, 0xd0, 0x01, 0x23, 0x27, 0x81, + 0xa3, 0x71, 0x23, 0x89, 0xab, 0x42, 0x05, 0xd2, 0xff, 0xf7, 0x4e, 0xfe, + 0x23, 0x89, 0x01, 0x33, 0x23, 0x81, 0xf6, 0xe7, 0x06, 0x9d, 0x06, 0x9a, + 0xab, 0x1a, 0x9b, 0xb2, 0xb3, 0x42, 0x04, 0xd2, 0xff, 0xf7, 0x42, 0xfe, + 0x28, 0x70, 0x01, 0x35, 0xf5, 0xe7, 0x23, 0x89, 0xa2, 0x7a, 0xf3, 0x18, + 0x9b, 0xb2, 0x23, 0x81, 0x00, 0x2a, 0x02, 0xd0, 0x06, 0x4a, 0x93, 0x42, + 0x02, 0xd9, 0x20, 0x1c, 0xff, 0xf7, 0x66, 0xfe, 0x01, 0x20, 0x03, 0xe0, + 0x20, 0x1c, 0xff, 0xf7, 0x35, 0xfe, 0x00, 0x20, 0xf8, 0xbd, 0xc0, 0x46, + 0xff, 0x01, 0x00, 0x00, 0x07, 0xb5, 0x80, 0x23, 0x00, 0x92, 0x9b, 0x00, + 0x00, 0x22, 0xff, 0xf7, 0xa3, 0xff, 0x0e, 0xbd, 0x70, 0xb5, 0x05, 0x1c, + 0x08, 0x1c, 0x16, 0x1c, 0xff, 0xf7, 0x12, 0xfe, 0x00, 0x24, 0x30, 0x5d, + 0xff, 0xf7, 0x0e, 0xfe, 0x01, 0x34, 0x80, 0x23, 0x9b, 0x00, 0x9c, 0x42, + 0xf7, 0xd1, 0xff, 0x20, 0xff, 0xf7, 0x06, 0xfe, 0xff, 0x20, 0xff, 0xf7, + 0x03, 0xfe, 0xff, 0xf7, 0x09, 0xfe, 0x1f, 0x23, 0xe8, 0x72, 0x03, 0x40, + 0x01, 0x20, 0x05, 0x2b, 0x05, 0xd0, 0x11, 0x23, 0x28, 0x1c, 0x6b, 0x71, + 0xff, 0xf7, 0x06, 0xfe, 0x00, 0x20, 0x70, 0xbd, 0x70, 0xb5, 0x0b, 0x1c, + 0x04, 0x1c, 0x16, 0x1c, 0x00, 0x29, 0x01, 0xd1, 0x12, 0x23, 0x28, 0xe0, + 0x02, 0x7b, 0x03, 0x2a, 0x00, 0xd0, 0x4b, 0x02, 0x20, 0x1c, 0x18, 0x21, + 0x1a, 0x1c, 0xff, 0xf7, 0x7d, 0xfe, 0x05, 0x1e, 0x01, 0xd0, 0x04, 0x23, + 0x1b, 0xe0, 0x20, 0x1c, 0xfe, 0x21, 0x32, 0x1c, 0xff, 0xf7, 0xc2, 0xff, + 0x00, 0x28, 0x15, 0xd0, 0x96, 0x21, 0x20, 0x1c, 0x89, 0x00, 0xff, 0xf7, + 0x5b, 0xfe, 0x00, 0x28, 0x01, 0xd1, 0x15, 0x23, 0x0b, 0xe0, 0x20, 0x1c, + 0x0d, 0x21, 0x2a, 0x1c, 0xff, 0xf7, 0x64, 0xfe, 0x00, 0x28, 0x03, 0xd1, + 0xff, 0xf7, 0xce, 0xfd, 0x00, 0x28, 0x06, 0xd0, 0x14, 0x23, 0x63, 0x71, + 0x20, 0x1c, 0xff, 0xf7, 0xcf, 0xfd, 0x00, 0x20, 0x03, 0xe0, 0x20, 0x1c, + 0xff, 0xf7, 0xca, 0xfd, 0x01, 0x20, 0x70, 0xbd, 0x03, 0x4b, 0x04, 0x4a, + 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x70, 0x47, 0xc0, 0x46, + 0x2c, 0x01, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, 0x02, 0x1c, 0x10, 0xb5, + 0x0c, 0x32, 0x04, 0x1c, 0x01, 0x21, 0x40, 0x6a, 0x00, 0xf0, 0x24, 0xfd, + 0x00, 0x28, 0x0a, 0xd0, 0x23, 0x6a, 0x01, 0x20, 0x00, 0x2b, 0x06, 0xd1, + 0xe3, 0x68, 0x22, 0x7a, 0x23, 0x62, 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, + 0x23, 0x72, 0x10, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xe6, 0xff, + 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x1b, 0xe0, 0x63, 0x6a, 0xe6, 0x68, + 0x1a, 0x7c, 0x02, 0x3e, 0x96, 0x40, 0x5a, 0x69, 0x1d, 0x79, 0xb6, 0x18, + 0x00, 0x2d, 0x08, 0xd0, 0x70, 0x1e, 0x40, 0x19, 0x00, 0xf0, 0x4c, 0xfc, + 0x00, 0x28, 0xed, 0xd0, 0x01, 0x3d, 0xed, 0xb2, 0xf4, 0xe7, 0x63, 0x6a, + 0x01, 0x20, 0x1a, 0x7c, 0x80, 0x23, 0x9b, 0x00, 0x93, 0x40, 0xe2, 0x69, + 0xd3, 0x18, 0xe3, 0x61, 0x70, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, + 0x40, 0x69, 0x00, 0xf0, 0x13, 0xfc, 0x00, 0x28, 0x03, 0xd0, 0x20, 0x7e, + 0x01, 0x4b, 0x40, 0x01, 0xc0, 0x18, 0x10, 0xbd, 0x44, 0x01, 0x00, 0x20, + 0xf0, 0xb5, 0x00, 0x23, 0x87, 0xb0, 0x07, 0x1c, 0x0e, 0x1c, 0x20, 0x22, + 0xf2, 0x54, 0x01, 0x33, 0x0b, 0x2b, 0xfa, 0xd1, 0x07, 0x21, 0x00, 0x25, + 0x01, 0x91, 0x3c, 0x78, 0x00, 0x2c, 0x2a, 0xd0, 0x2e, 0x2c, 0x06, 0xd1, + 0x01, 0x9b, 0x0a, 0x2b, 0x2b, 0xd0, 0x0a, 0x21, 0x08, 0x25, 0x01, 0x91, + 0x1f, 0xe0, 0x02, 0xa8, 0x14, 0x49, 0x10, 0x22, 0x01, 0xf0, 0x99, 0xfe, + 0x00, 0x23, 0x02, 0xa9, 0xca, 0x5c, 0x00, 0x2a, 0x03, 0xd0, 0x01, 0x33, + 0xa2, 0x42, 0xf8, 0xd1, 0x19, 0xe0, 0x01, 0x9b, 0x9d, 0x42, 0x16, 0xd8, + 0x23, 0x1c, 0x21, 0x3b, 0x5d, 0x2b, 0x12, 0xd8, 0x22, 0x1c, 0x6b, 0x1c, + 0x61, 0x3a, 0xdb, 0xb2, 0x75, 0x19, 0x19, 0x2a, 0x01, 0xd8, 0x20, 0x3c, + 0xe4, 0xb2, 0x2c, 0x70, 0x1d, 0x1c, 0x01, 0x37, 0xd1, 0xe7, 0x30, 0x78, + 0x20, 0x38, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x00, 0xe0, 0x00, 0x20, + 0x07, 0xb0, 0xf0, 0xbd, 0x02, 0x6c, 0x00, 0x00, 0x38, 0xb5, 0x42, 0x7a, + 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x2a, 0x01, 0xd0, 0x00, 0x20, 0x1f, 0xe0, + 0x4b, 0x1c, 0xdb, 0x7f, 0x10, 0x2b, 0x06, 0xd1, 0x02, 0x23, 0x43, 0x72, + 0x02, 0x62, 0x4b, 0x8c, 0x5b, 0x01, 0xc3, 0x61, 0x0c, 0xe0, 0x20, 0x2b, + 0xf0, 0xd1, 0x03, 0x23, 0x43, 0x72, 0x49, 0x6a, 0x22, 0x1c, 0x01, 0x62, + 0x1c, 0x32, 0x28, 0x1c, 0x00, 0xf0, 0x18, 0xfc, 0x00, 0x28, 0xe5, 0xd0, + 0x00, 0x23, 0x01, 0x20, 0x65, 0x62, 0x20, 0x72, 0xe3, 0x60, 0x23, 0x61, + 0x63, 0x61, 0x23, 0x76, 0x38, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x43, 0x7a, + 0x85, 0xb0, 0x04, 0x1c, 0x0e, 0x1c, 0x03, 0x92, 0x00, 0x2b, 0x01, 0xd1, + 0x3a, 0x48, 0x11, 0xe0, 0x03, 0x7a, 0xd8, 0x07, 0xfa, 0xd5, 0xe2, 0x69, + 0x20, 0x69, 0x03, 0x99, 0x13, 0x1a, 0x99, 0x42, 0x01, 0xd9, 0x9b, 0xb2, + 0x03, 0x93, 0x03, 0x99, 0x02, 0x91, 0x02, 0x9b, 0x00, 0x2b, 0x04, 0xd1, + 0x03, 0x99, 0x88, 0xb2, 0x00, 0xb2, 0x05, 0xb0, 0xf0, 0xbd, 0x23, 0x69, + 0x61, 0x7a, 0xdf, 0x05, 0xff, 0x0d, 0x5a, 0x0a, 0x60, 0x6a, 0x02, 0x29, + 0x02, 0xd1, 0x41, 0x6a, 0x51, 0x18, 0x1b, 0xe0, 0x05, 0x79, 0x01, 0x3d, + 0x2a, 0x40, 0xd5, 0xb2, 0x00, 0x2f, 0x0d, 0xd1, 0x00, 0x2d, 0x0b, 0xd1, + 0x00, 0x2b, 0x02, 0xd1, 0x22, 0x6a, 0xe2, 0x60, 0x06, 0xe0, 0x22, 0x1c, + 0xe1, 0x68, 0x0c, 0x32, 0x00, 0xf0, 0xa0, 0xfb, 0x00, 0x28, 0xc9, 0xd0, + 0x63, 0x6a, 0xe1, 0x68, 0x1a, 0x7c, 0x02, 0x39, 0x5b, 0x69, 0x91, 0x40, + 0xc9, 0x18, 0x49, 0x19, 0x80, 0x22, 0x02, 0x9d, 0x92, 0x00, 0xd3, 0x1b, + 0x9d, 0x42, 0x00, 0xdd, 0x9d, 0xb2, 0x23, 0x7a, 0x58, 0x06, 0x01, 0xd4, + 0x95, 0x42, 0x18, 0xd1, 0x16, 0x4b, 0x1b, 0x68, 0x99, 0x42, 0x14, 0xd0, + 0x15, 0x4b, 0x3a, 0x1c, 0x18, 0x68, 0x00, 0x96, 0x2b, 0x1c, 0xff, 0xf7, + 0x1f, 0xfe, 0x00, 0x28, 0xa8, 0xd0, 0x76, 0x19, 0x01, 0xe0, 0xdf, 0x1b, + 0xf6, 0x19, 0x21, 0x69, 0x02, 0x9a, 0x4b, 0x19, 0x55, 0x1b, 0xad, 0xb2, + 0x23, 0x61, 0x02, 0x95, 0xab, 0xe7, 0x08, 0x1c, 0x00, 0x21, 0x00, 0xf0, + 0x2b, 0xfb, 0x00, 0x28, 0x96, 0xd0, 0x09, 0x4b, 0x32, 0x1c, 0xff, 0x18, + 0x79, 0x19, 0x3b, 0x1c, 0x8b, 0x42, 0xe8, 0xd0, 0x18, 0x78, 0x01, 0x33, + 0x10, 0x70, 0x01, 0x32, 0xf8, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x20, 0x40, 0x01, 0x00, 0x20, 0x44, 0x01, 0x00, 0x20, + 0x73, 0xb5, 0x43, 0x7a, 0x04, 0x1c, 0x01, 0x2b, 0x01, 0xd8, 0x00, 0x20, + 0x16, 0xe0, 0x03, 0x69, 0x6d, 0x46, 0x07, 0x35, 0xde, 0x05, 0x29, 0x1c, + 0x01, 0x22, 0x36, 0x0f, 0xff, 0xf7, 0x6a, 0xff, 0x01, 0x28, 0x01, 0xd1, + 0x2b, 0x78, 0x00, 0xe0, 0x05, 0x4b, 0x1b, 0xb2, 0x01, 0x33, 0xec, 0xd0, + 0x23, 0x69, 0x70, 0x01, 0x1f, 0x33, 0x23, 0x61, 0x02, 0x4b, 0xc0, 0x18, + 0x76, 0xbd, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0x44, 0x01, 0x00, 0x20, + 0x70, 0xb5, 0x04, 0x1c, 0x40, 0x7a, 0x0d, 0x1c, 0x00, 0x28, 0x2a, 0xd0, + 0xe2, 0x69, 0x91, 0x42, 0x01, 0xd9, 0x00, 0x20, 0x25, 0xe0, 0x02, 0x28, + 0x21, 0xd0, 0x00, 0x2d, 0x01, 0xd1, 0xe5, 0x60, 0x1d, 0xe0, 0x62, 0x6a, + 0x21, 0x69, 0x13, 0x7c, 0x68, 0x1e, 0x09, 0x33, 0x4a, 0x1e, 0xd8, 0x40, + 0xda, 0x40, 0x03, 0x1e, 0x93, 0x42, 0x01, 0xd3, 0x00, 0x29, 0x02, 0xd1, + 0x22, 0x6a, 0xe2, 0x60, 0x00, 0xe0, 0x83, 0x1a, 0x1e, 0x1c, 0x00, 0x2e, + 0x09, 0xd0, 0x22, 0x1c, 0x60, 0x6a, 0xe1, 0x68, 0x0c, 0x32, 0x00, 0xf0, + 0x07, 0xfb, 0x01, 0x3e, 0x00, 0x28, 0xf4, 0xd1, 0x01, 0xe0, 0x25, 0x61, + 0x01, 0x20, 0x70, 0xbd, 0x38, 0xb5, 0x05, 0x1c, 0x40, 0x7a, 0x00, 0x28, + 0x33, 0xd0, 0x2b, 0x7a, 0x7f, 0x2b, 0x2d, 0xd9, 0x28, 0x1c, 0x01, 0x21, + 0xff, 0xf7, 0x9a, 0xfe, 0x04, 0x1e, 0x2a, 0xd0, 0x6b, 0x7a, 0x01, 0x2b, + 0x07, 0xd8, 0x2b, 0x7f, 0x03, 0x77, 0x6b, 0x7f, 0x43, 0x77, 0xab, 0x7f, + 0x83, 0x77, 0xeb, 0x7f, 0xc3, 0x77, 0x2b, 0x6a, 0x9a, 0xb2, 0x1b, 0x0c, + 0x23, 0x75, 0x1b, 0x0a, 0x63, 0x75, 0x0d, 0x4b, 0xa2, 0x76, 0x1b, 0x68, + 0x12, 0x0a, 0xe2, 0x76, 0x00, 0x2b, 0x0b, 0xd0, 0x20, 0x1c, 0x21, 0x1c, + 0x18, 0x30, 0x16, 0x31, 0x98, 0x47, 0x63, 0x7e, 0x22, 0x7e, 0x1b, 0x02, + 0x13, 0x43, 0xa3, 0x74, 0x1b, 0x0a, 0xe3, 0x74, 0x2a, 0x7a, 0x7f, 0x23, + 0x13, 0x40, 0x2b, 0x72, 0x00, 0xf0, 0x5c, 0xfa, 0xff, 0xe7, 0x38, 0xbd, + 0x38, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xc0, 0xff, + 0x00, 0x28, 0x02, 0xd0, 0x00, 0x23, 0x63, 0x72, 0x01, 0x20, 0x10, 0xbd, + 0x73, 0xb5, 0x42, 0x7a, 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x20, 0x01, 0x2a, + 0x4b, 0xd1, 0x20, 0x7a, 0x02, 0x23, 0x18, 0x40, 0x47, 0xd0, 0xe3, 0x69, + 0x00, 0x20, 0x99, 0x42, 0x43, 0xd8, 0x10, 0x1c, 0x00, 0x2b, 0x40, 0xd0, + 0x20, 0x1c, 0x29, 0x1c, 0x26, 0x69, 0xff, 0xf7, 0x71, 0xff, 0x00, 0x28, + 0x25, 0xd0, 0x60, 0x6a, 0x00, 0x2d, 0x06, 0xd1, 0x21, 0x6a, 0x00, 0xf0, + 0x95, 0xfb, 0x00, 0x28, 0x1d, 0xd0, 0x25, 0x62, 0x1d, 0xe0, 0xe1, 0x68, + 0x01, 0xaa, 0x00, 0xf0, 0x93, 0xfa, 0x00, 0x28, 0x15, 0xd0, 0x60, 0x6a, + 0x01, 0x99, 0x43, 0x1c, 0xdb, 0x7f, 0x10, 0x2b, 0x01, 0xd1, 0x12, 0x4b, + 0x00, 0xe0, 0x12, 0x4b, 0x99, 0x42, 0x0c, 0xd2, 0x00, 0xf0, 0x7e, 0xfb, + 0x00, 0x28, 0x06, 0xd0, 0x60, 0x6a, 0xe1, 0x68, 0x0e, 0x4a, 0x00, 0xf0, + 0xcf, 0xfa, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x11, 0xe0, 0x22, 0x7a, + 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, 0xe5, 0x61, 0x23, 0x72, 0x20, 0x1c, + 0xff, 0xf7, 0x70, 0xff, 0x00, 0x28, 0xf2, 0xd0, 0x29, 0x1e, 0xb1, 0x42, + 0x00, 0xd9, 0x31, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x35, 0xff, 0x76, 0xbd, + 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, 0xff, 0xff, 0xff, 0x0f, + 0x38, 0xb5, 0x23, 0x4b, 0x15, 0x1c, 0x4a, 0x01, 0xd3, 0x18, 0x04, 0x1c, + 0xd8, 0x7a, 0x11, 0x22, 0x10, 0x42, 0x04, 0xd0, 0x42, 0x22, 0x15, 0x42, + 0x01, 0xd0, 0x00, 0x20, 0x36, 0xe0, 0x1d, 0x4a, 0x21, 0x76, 0x12, 0x68, + 0x62, 0x61, 0x5a, 0x7d, 0x18, 0x7d, 0xd9, 0x7e, 0x12, 0x02, 0x02, 0x43, + 0x98, 0x7e, 0x09, 0x02, 0x12, 0x04, 0x01, 0x43, 0x11, 0x43, 0x21, 0x62, + 0xd8, 0x7a, 0x18, 0x22, 0x02, 0x40, 0x0c, 0xd1, 0x5a, 0x7f, 0x19, 0x7f, + 0x12, 0x02, 0x0a, 0x43, 0x99, 0x7f, 0xdb, 0x7f, 0x09, 0x04, 0x0a, 0x43, + 0x1b, 0x06, 0x13, 0x43, 0xe3, 0x61, 0x01, 0x23, 0x09, 0xe0, 0x10, 0x2a, + 0xdb, 0xd1, 0x22, 0x1c, 0x60, 0x6a, 0x1c, 0x32, 0x00, 0xf0, 0x5a, 0xfa, + 0x00, 0x28, 0xd4, 0xd0, 0x04, 0x23, 0x63, 0x72, 0x0f, 0x23, 0x00, 0x21, + 0x2b, 0x40, 0x23, 0x72, 0xe1, 0x60, 0x21, 0x61, 0x01, 0x20, 0x6a, 0x06, + 0x02, 0xd5, 0x20, 0x1c, 0xff, 0xf7, 0x60, 0xff, 0x38, 0xbd, 0xc0, 0x46, + 0x44, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0xf0, 0xb5, 0x45, 0x7a, + 0x87, 0xb0, 0x04, 0x1c, 0x0e, 0x1c, 0x01, 0x93, 0x00, 0x2d, 0x00, 0xd0, + 0x86, 0xe0, 0x10, 0x1c, 0x03, 0xa9, 0xff, 0xf7, 0xbb, 0xfd, 0x00, 0x28, + 0x00, 0xd1, 0x80, 0xe0, 0x72, 0x6a, 0x2f, 0x1c, 0x62, 0x62, 0xf5, 0x60, + 0x35, 0x61, 0x33, 0x69, 0xf2, 0x69, 0x93, 0x42, 0x26, 0xd2, 0xdb, 0x05, + 0x1b, 0x0f, 0x30, 0x1c, 0x00, 0x93, 0xff, 0xf7, 0x9f, 0xfe, 0x01, 0x1e, + 0x6f, 0xd0, 0x03, 0x78, 0x00, 0x2b, 0x01, 0xd0, 0xe5, 0x2b, 0x0b, 0xd1, + 0x00, 0x2f, 0x04, 0xd1, 0x00, 0x9b, 0x23, 0x76, 0x34, 0x4b, 0x1b, 0x68, + 0x63, 0x61, 0x0b, 0x78, 0x01, 0x27, 0x00, 0x2b, 0xe3, 0xd1, 0x0d, 0xe0, + 0x03, 0xa8, 0x0b, 0x22, 0x01, 0xf0, 0x3a, 0xfc, 0x00, 0x28, 0xdc, 0xd1, + 0x01, 0x9a, 0x30, 0x23, 0x13, 0x40, 0x30, 0x2b, 0x53, 0xd0, 0x20, 0x1c, + 0x00, 0x99, 0x4b, 0xe0, 0x01, 0x9a, 0x12, 0x23, 0x13, 0x40, 0x12, 0x2b, + 0x4b, 0xd1, 0x00, 0x2f, 0x06, 0xd0, 0x20, 0x1c, 0x01, 0x21, 0xff, 0xf7, + 0x6f, 0xfd, 0x06, 0x1e, 0x0a, 0xd1, 0x42, 0xe0, 0x73, 0x7a, 0x02, 0x2b, + 0x3f, 0xd0, 0x30, 0x1c, 0xff, 0xf7, 0x40, 0xfd, 0x00, 0x28, 0x3a, 0xd0, + 0x1f, 0x4e, 0x27, 0x76, 0x00, 0x21, 0x20, 0x22, 0x30, 0x1c, 0x01, 0xf0, + 0x2b, 0xfc, 0x30, 0x1c, 0x03, 0xa9, 0x0b, 0x22, 0x01, 0xf0, 0x1d, 0xfc, + 0x1a, 0x4b, 0x1b, 0x68, 0x00, 0x2b, 0x05, 0xd0, 0x30, 0x1c, 0x31, 0x1c, + 0x10, 0x30, 0x0e, 0x31, 0x98, 0x47, 0x06, 0xe0, 0x21, 0x22, 0x32, 0x74, + 0xb3, 0x73, 0x28, 0x22, 0x08, 0x23, 0x72, 0x74, 0xf3, 0x73, 0x73, 0x7c, + 0x32, 0x7c, 0x1b, 0x02, 0x13, 0x43, 0xff, 0x22, 0x1a, 0x40, 0x1b, 0x0a, + 0xf3, 0x74, 0x73, 0x76, 0xf3, 0x7b, 0xb2, 0x74, 0x32, 0x76, 0xb2, 0x7b, + 0x1b, 0x02, 0x13, 0x43, 0xb3, 0x75, 0x1b, 0x0a, 0xf3, 0x75, 0x00, 0xf0, + 0x21, 0xf9, 0x00, 0x28, 0x07, 0xd0, 0x21, 0x7e, 0x01, 0x9a, 0x20, 0x1c, + 0xff, 0xf7, 0x26, 0xff, 0x05, 0x1c, 0x00, 0xe0, 0x00, 0x25, 0x28, 0x1c, + 0x07, 0xb0, 0xf0, 0xbd, 0x00, 0x00, 0x00, 0x20, 0x44, 0x01, 0x00, 0x20, + 0x38, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x00, 0x21, 0x04, 0x1c, 0xff, 0xf7, + 0xbb, 0xfe, 0x00, 0x28, 0x0b, 0xd0, 0x20, 0x1c, 0x01, 0x21, 0xff, 0xf7, + 0x15, 0xfd, 0x00, 0x28, 0x05, 0xd0, 0xe5, 0x23, 0x03, 0x70, 0x00, 0x23, + 0x63, 0x72, 0x00, 0xf0, 0xfb, 0xf8, 0x10, 0xbd, 0x10, 0xb5, 0x0a, 0x1c, + 0x0a, 0x49, 0x8a, 0xb0, 0x08, 0x31, 0x00, 0x23, 0x04, 0x1c, 0x00, 0x91, + 0x69, 0x46, 0x4b, 0x72, 0x01, 0x93, 0x68, 0x46, 0x21, 0x1c, 0x02, 0x23, + 0xff, 0xf7, 0x42, 0xff, 0x00, 0x28, 0x02, 0xd0, 0x68, 0x46, 0xff, 0xf7, + 0xd7, 0xff, 0x0a, 0xb0, 0x10, 0xbd, 0xc0, 0x46, 0x18, 0x6c, 0x00, 0x00, + 0xf0, 0xb5, 0x43, 0x7a, 0x87, 0xb0, 0x04, 0x1c, 0x0d, 0x1c, 0x03, 0x92, + 0x01, 0x2b, 0x0d, 0xd1, 0x03, 0x7a, 0x99, 0x07, 0x0a, 0xd5, 0x5a, 0x07, + 0x0c, 0xd5, 0xe1, 0x69, 0x22, 0x69, 0x8a, 0x42, 0x08, 0xd0, 0x20, 0x1c, + 0xff, 0xf7, 0x06, 0xfe, 0x00, 0x28, 0x03, 0xd1, 0x01, 0x23, 0x63, 0x60, + 0x00, 0x20, 0xaa, 0xe0, 0x03, 0x9b, 0x01, 0x93, 0x3b, 0xe0, 0x60, 0x6a, + 0x73, 0x0a, 0x07, 0x79, 0xf6, 0x05, 0x01, 0x3f, 0x1f, 0x40, 0xff, 0xb2, + 0xf6, 0x0d, 0x00, 0x2f, 0x36, 0xd0, 0x80, 0x22, 0x92, 0x00, 0x92, 0x1b, + 0x01, 0x99, 0x92, 0xb2, 0x0b, 0x1c, 0x91, 0x42, 0x00, 0xd9, 0x13, 0x1c, + 0x9b, 0xb2, 0x02, 0x93, 0x63, 0x6a, 0xe1, 0x68, 0x1a, 0x7c, 0x02, 0x39, + 0x91, 0x40, 0x5a, 0x69, 0x8b, 0x18, 0x02, 0x9a, 0xdf, 0x19, 0x80, 0x23, + 0x9b, 0x00, 0x9a, 0x42, 0x3f, 0xd1, 0x44, 0x4b, 0x19, 0x68, 0xb9, 0x42, + 0x02, 0xd1, 0x01, 0x22, 0x52, 0x42, 0x1a, 0x60, 0x41, 0x4b, 0x39, 0x1c, + 0x18, 0x68, 0x2a, 0x1c, 0xff, 0xf7, 0x22, 0xfc, 0x00, 0x28, 0xc7, 0xd0, + 0x80, 0x22, 0x92, 0x00, 0xad, 0x18, 0x01, 0x99, 0x02, 0x9a, 0x8b, 0x1a, + 0x21, 0x69, 0x9b, 0xb2, 0x01, 0x93, 0x8b, 0x18, 0x23, 0x61, 0x01, 0x9a, + 0x26, 0x69, 0x00, 0x2a, 0xbf, 0xd1, 0x49, 0xe0, 0x00, 0x2e, 0xc6, 0xd1, + 0xe1, 0x68, 0x00, 0x29, 0x03, 0xd1, 0x23, 0x6a, 0x00, 0x2b, 0x16, 0xd1, + 0x0f, 0xe0, 0x05, 0xaa, 0x00, 0xf0, 0xe2, 0xf8, 0x00, 0x28, 0x58, 0xd0, + 0x62, 0x6a, 0x05, 0x9b, 0x01, 0x32, 0xd2, 0x7f, 0x10, 0x2a, 0x01, 0xd1, + 0x2c, 0x4a, 0x00, 0xe0, 0x2c, 0x4a, 0x93, 0x42, 0x05, 0xd3, 0x20, 0x1c, + 0xff, 0xf7, 0x3c, 0xfc, 0x00, 0x28, 0xaa, 0xd1, 0x98, 0xe7, 0xe3, 0x60, + 0xa7, 0xe7, 0x00, 0x2e, 0x0f, 0xd1, 0x23, 0x69, 0xe1, 0x69, 0x8b, 0x42, + 0x0b, 0xd3, 0x00, 0xf0, 0x59, 0xf8, 0x00, 0x28, 0x8c, 0xd0, 0x1f, 0x4b, + 0x01, 0x21, 0x1f, 0x60, 0x21, 0x4b, 0x1a, 0x78, 0x0a, 0x43, 0x1a, 0x70, + 0x06, 0xe0, 0x38, 0x1c, 0x01, 0x21, 0x00, 0xf0, 0x75, 0xf8, 0x00, 0x28, + 0x00, 0xd1, 0x7d, 0xe7, 0x1c, 0x4b, 0x2a, 0x1c, 0xf6, 0x18, 0x02, 0x9b, + 0xf1, 0x18, 0x33, 0x1c, 0x8b, 0x42, 0x04, 0xd0, 0x10, 0x78, 0x01, 0x32, + 0x18, 0x70, 0x01, 0x33, 0xf8, 0xe7, 0x9e, 0x1b, 0xad, 0x19, 0xa8, 0xe7, + 0xe1, 0x69, 0x23, 0x7a, 0x8e, 0x42, 0x01, 0xd9, 0xe6, 0x61, 0x06, 0xe0, + 0x12, 0x4a, 0x12, 0x68, 0x00, 0x2a, 0x06, 0xd0, 0x03, 0x9a, 0x00, 0x2a, + 0x03, 0xd0, 0x80, 0x22, 0x52, 0x42, 0x13, 0x43, 0x23, 0x72, 0x23, 0x7a, + 0x19, 0x07, 0x01, 0xd4, 0x03, 0x98, 0x06, 0xe0, 0x20, 0x1c, 0xff, 0xf7, + 0x8b, 0xfd, 0x00, 0x28, 0x00, 0xd1, 0x51, 0xe7, 0xf6, 0xe7, 0x07, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, 0x40, 0x01, 0x00, 0x20, + 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, 0x44, 0x03, 0x00, 0x20, + 0x44, 0x01, 0x00, 0x20, 0x38, 0x01, 0x00, 0x20, 0x07, 0xb5, 0x6b, 0x46, + 0xd9, 0x71, 0x07, 0x33, 0x19, 0x1c, 0x01, 0x22, 0xff, 0xf7, 0x22, 0xff, + 0x0e, 0xbd, 0x00, 0x00, 0xf8, 0xb5, 0x0f, 0x4f, 0x01, 0x20, 0x3b, 0x78, + 0x00, 0x2b, 0x18, 0xd0, 0x0d, 0x4e, 0x0e, 0x4b, 0x0e, 0x4d, 0x19, 0x68, + 0x30, 0x68, 0x2a, 0x1c, 0xff, 0xf7, 0x80, 0xfb, 0x00, 0x28, 0x0e, 0xd0, + 0x0b, 0x4c, 0x21, 0x68, 0x00, 0x29, 0x07, 0xd0, 0x30, 0x68, 0x2a, 0x1c, + 0xff, 0xf7, 0x76, 0xfb, 0x00, 0x28, 0x04, 0xd0, 0x00, 0x23, 0x23, 0x60, + 0x00, 0x23, 0x3b, 0x70, 0x01, 0x20, 0xf8, 0xbd, 0x44, 0x03, 0x00, 0x20, + 0x40, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0x44, 0x01, 0x00, 0x20, + 0x3c, 0x01, 0x00, 0x20, 0x70, 0xb5, 0x0d, 0x4d, 0x04, 0x1c, 0x2b, 0x68, + 0x0e, 0x1c, 0x83, 0x42, 0x0e, 0xd0, 0xff, 0xf7, 0xcd, 0xff, 0x00, 0x28, + 0x01, 0xd1, 0x00, 0x20, 0x0d, 0xe0, 0x08, 0x4b, 0x21, 0x1c, 0x18, 0x68, + 0x07, 0x4a, 0xff, 0xf7, 0x25, 0xfb, 0x00, 0x28, 0xf5, 0xd0, 0x2c, 0x60, + 0x05, 0x4b, 0x01, 0x20, 0x1a, 0x78, 0x16, 0x43, 0x1e, 0x70, 0x70, 0xbd, + 0x00, 0x00, 0x00, 0x20, 0x40, 0x01, 0x00, 0x20, 0x44, 0x01, 0x00, 0x20, + 0x44, 0x03, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xae, 0xff, + 0x00, 0x28, 0x0f, 0xd0, 0x00, 0x23, 0x08, 0x4a, 0x00, 0x21, 0x99, 0x54, + 0x80, 0x22, 0x01, 0x33, 0x92, 0x00, 0x93, 0x42, 0xf7, 0xd1, 0x05, 0x4b, + 0x01, 0x20, 0x1c, 0x60, 0x04, 0x4b, 0x1a, 0x78, 0x02, 0x43, 0x1a, 0x70, + 0x10, 0xbd, 0xc0, 0x46, 0x44, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, + 0x44, 0x03, 0x00, 0x20, 0xc3, 0x68, 0x70, 0xb5, 0x01, 0x33, 0x0c, 0x1c, + 0x15, 0x1c, 0x99, 0x42, 0x01, 0xd9, 0x00, 0x20, 0x21, 0xe0, 0x46, 0x1c, + 0xf1, 0x7f, 0xc2, 0x69, 0xe3, 0x09, 0x10, 0x29, 0x00, 0xd1, 0x23, 0x0a, + 0x98, 0x18, 0x0d, 0x4b, 0x1b, 0x68, 0x98, 0x42, 0x07, 0xd1, 0xf2, 0x7f, + 0x0b, 0x4b, 0x10, 0x2a, 0x09, 0xd1, 0xe4, 0xb2, 0x64, 0x00, 0x1b, 0x5b, + 0x0b, 0xe0, 0x00, 0x21, 0xff, 0xf7, 0x9e, 0xff, 0x00, 0x28, 0xf2, 0xd1, + 0xe3, 0xe7, 0x7f, 0x22, 0x14, 0x40, 0xa4, 0x00, 0x1b, 0x59, 0x1b, 0x01, + 0x1b, 0x09, 0x2b, 0x60, 0x01, 0x20, 0x70, 0xbd, 0x00, 0x00, 0x00, 0x20, + 0x44, 0x01, 0x00, 0x20, 0x73, 0xb5, 0x05, 0x1c, 0x01, 0x91, 0x16, 0x1c, + 0x00, 0x24, 0x28, 0x1c, 0x01, 0x99, 0x01, 0xaa, 0xff, 0xf7, 0xc6, 0xff, + 0x00, 0x28, 0x10, 0xd0, 0x2a, 0x7c, 0x80, 0x23, 0x9b, 0x00, 0x93, 0x40, + 0xe4, 0x18, 0x6b, 0x1c, 0xdb, 0x7f, 0x01, 0x9a, 0x10, 0x2b, 0x01, 0xd1, + 0x03, 0x4b, 0x00, 0xe0, 0x03, 0x4b, 0x9a, 0x42, 0xe9, 0xd3, 0x34, 0x60, + 0x01, 0x20, 0x76, 0xbd, 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, + 0xf7, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x01, 0x92, 0x01, 0x29, 0x32, 0xd9, + 0xc3, 0x68, 0x00, 0x20, 0x01, 0x33, 0x99, 0x42, 0x2e, 0xd8, 0x6f, 0x1c, + 0xfa, 0x7f, 0xee, 0x69, 0xcb, 0x09, 0x10, 0x2a, 0x00, 0xd1, 0x0b, 0x0a, + 0x9e, 0x19, 0x14, 0x4b, 0x1b, 0x68, 0x9e, 0x42, 0x08, 0xd1, 0xfa, 0x7f, + 0x12, 0x4b, 0x10, 0x2a, 0x0b, 0xd1, 0xe4, 0xb2, 0x01, 0x9a, 0x64, 0x00, + 0x1a, 0x53, 0x0b, 0xe0, 0x30, 0x1c, 0x00, 0x21, 0xff, 0xf7, 0x48, 0xff, + 0x00, 0x28, 0xf0, 0xd1, 0x12, 0xe0, 0x7f, 0x22, 0x14, 0x40, 0x01, 0x9a, + 0xa4, 0x00, 0x1a, 0x51, 0x09, 0x4b, 0x01, 0x20, 0x1a, 0x78, 0x02, 0x43, + 0x1a, 0x70, 0x2b, 0x7e, 0x83, 0x42, 0x05, 0xd9, 0xab, 0x68, 0xf6, 0x18, + 0x05, 0x4b, 0x1e, 0x60, 0x00, 0xe0, 0x00, 0x20, 0xfe, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x20, 0x44, 0x01, 0x00, 0x20, 0x44, 0x03, 0x00, 0x20, + 0x3c, 0x01, 0x00, 0x20, 0xf0, 0xb5, 0x15, 0x68, 0x87, 0xb0, 0x06, 0x1c, + 0x02, 0x91, 0x17, 0x1c, 0x00, 0x2d, 0x03, 0xd0, 0x00, 0x21, 0x01, 0x35, + 0x01, 0x91, 0x06, 0xe0, 0x02, 0x9b, 0x05, 0x68, 0x01, 0x3b, 0x5a, 0x42, + 0x53, 0x41, 0xdb, 0xb2, 0x01, 0x93, 0xf2, 0x68, 0x00, 0x23, 0x01, 0x32, + 0x03, 0x92, 0x2c, 0x1c, 0x00, 0x93, 0x00, 0x99, 0xf2, 0x68, 0x91, 0x42, + 0x21, 0xd2, 0x03, 0x9b, 0x9c, 0x42, 0x01, 0xd9, 0x02, 0x24, 0x25, 0x1c, + 0x30, 0x1c, 0x21, 0x1c, 0x05, 0xaa, 0xff, 0xf7, 0x43, 0xff, 0x00, 0x28, + 0x15, 0xd0, 0x05, 0x99, 0x63, 0x1c, 0x00, 0x29, 0x01, 0xd0, 0x1d, 0x1c, + 0x03, 0xe0, 0x02, 0x99, 0x5a, 0x1b, 0x8a, 0x42, 0x04, 0xd0, 0x00, 0x9a, + 0x1c, 0x1c, 0x01, 0x32, 0x00, 0x92, 0xe0, 0xe7, 0x30, 0x1c, 0x21, 0x1c, + 0x13, 0x4a, 0xff, 0xf7, 0x7f, 0xff, 0x00, 0x28, 0x0b, 0xd1, 0x00, 0x20, + 0x1d, 0xe0, 0x63, 0x1e, 0x30, 0x1c, 0x19, 0x1c, 0x22, 0x1c, 0x00, 0x93, + 0xff, 0xf7, 0x74, 0xff, 0x00, 0x28, 0xf4, 0xd0, 0x00, 0x9c, 0xac, 0x42, + 0xf3, 0xd8, 0x39, 0x68, 0x00, 0x29, 0x06, 0xd1, 0x01, 0x99, 0x3d, 0x60, + 0x00, 0x29, 0x09, 0xd0, 0x01, 0x35, 0x35, 0x60, 0x06, 0xe0, 0x30, 0x1c, + 0x2a, 0x1c, 0xff, 0xf7, 0x61, 0xff, 0x00, 0x28, 0xf2, 0xd1, 0xe0, 0xe7, + 0x01, 0x20, 0x07, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0xff, 0xff, 0xff, 0x0f, + 0x02, 0x23, 0x37, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x03, 0x60, 0x28, 0x1c, + 0x21, 0x1c, 0x01, 0xaa, 0xff, 0xf7, 0xfc, 0xfe, 0x00, 0x28, 0x12, 0xd0, + 0x28, 0x1c, 0x21, 0x1c, 0x00, 0x22, 0xff, 0xf7, 0x47, 0xff, 0x00, 0x28, + 0x0b, 0xd0, 0x6b, 0x1c, 0xdb, 0x7f, 0x01, 0x9c, 0x10, 0x2b, 0x01, 0xd1, + 0x04, 0x4b, 0x00, 0xe0, 0x04, 0x4b, 0x9c, 0x42, 0xe7, 0xd3, 0x01, 0x20, + 0x00, 0xe0, 0x00, 0x20, 0x3e, 0xbd, 0xc0, 0x46, 0xf8, 0xff, 0x00, 0x00, + 0xf8, 0xff, 0xff, 0x0f, 0xf8, 0xb5, 0x44, 0x4b, 0x04, 0x1c, 0x15, 0x1c, + 0x19, 0x60, 0x29, 0xd0, 0x04, 0x2a, 0x01, 0xd9, 0x00, 0x20, 0x7d, 0xe0, + 0x00, 0x20, 0x01, 0x1c, 0xff, 0xf7, 0x90, 0xfe, 0x00, 0x28, 0xf7, 0xd0, + 0x2d, 0x01, 0x3d, 0x4b, 0xa9, 0x35, 0xff, 0x35, 0x5d, 0x19, 0xaa, 0x79, + 0xab, 0x1d, 0x50, 0x06, 0xee, 0xd1, 0xea, 0x7c, 0xa9, 0x7c, 0x12, 0x02, + 0x0a, 0x43, 0x29, 0x7d, 0x09, 0x04, 0x0a, 0x43, 0x69, 0x7d, 0x09, 0x06, + 0x0a, 0x43, 0x63, 0x2a, 0xe2, 0xd9, 0xaa, 0x7b, 0xed, 0x7b, 0x2d, 0x02, + 0x15, 0x43, 0x9a, 0x7a, 0xdb, 0x7a, 0x12, 0x04, 0x15, 0x43, 0x1b, 0x06, + 0x1d, 0x43, 0xd7, 0xd0, 0x28, 0x1c, 0x00, 0x21, 0xff, 0xf7, 0x6a, 0xfe, + 0x00, 0x28, 0xd1, 0xd0, 0x2a, 0x4b, 0x19, 0x7b, 0xda, 0x7a, 0x09, 0x02, + 0x11, 0x43, 0x80, 0x22, 0x92, 0x00, 0x91, 0x42, 0xc8, 0xd1, 0x1a, 0x7c, + 0x00, 0x2a, 0xc5, 0xd0, 0xd9, 0x89, 0x00, 0x29, 0xc2, 0xd0, 0x59, 0x7b, + 0x00, 0x29, 0xbf, 0xd0, 0x22, 0x76, 0x00, 0x22, 0x21, 0x71, 0x22, 0x74, + 0x22, 0x7c, 0x01, 0x20, 0x90, 0x40, 0x81, 0x42, 0x04, 0xd0, 0x50, 0x1c, + 0x20, 0x74, 0x07, 0x2a, 0xf6, 0xd9, 0xb1, 0xe7, 0xd9, 0x8a, 0x00, 0x29, + 0x00, 0xd1, 0x59, 0x6a, 0xa1, 0x60, 0xd8, 0x89, 0x28, 0x18, 0xe0, 0x61, + 0x1f, 0x69, 0x3e, 0x02, 0x36, 0x0c, 0x66, 0x84, 0xb7, 0xb2, 0x1e, 0x7c, + 0x71, 0x43, 0x0e, 0x18, 0x13, 0x48, 0x79, 0x01, 0x09, 0x18, 0x49, 0x12, + 0x71, 0x18, 0x66, 0x62, 0x61, 0x61, 0x18, 0x7d, 0xde, 0x7c, 0x00, 0x02, + 0x30, 0x43, 0x00, 0xd1, 0x18, 0x6a, 0x6d, 0x1a, 0x28, 0x18, 0xd0, 0x40, + 0x02, 0x1c, 0xe0, 0x60, 0x0b, 0x48, 0x61, 0x1c, 0x82, 0x42, 0x01, 0xd8, + 0x0c, 0x23, 0x07, 0xe0, 0x09, 0x48, 0x82, 0x42, 0x01, 0xd8, 0x10, 0x23, + 0x02, 0xe0, 0xdb, 0x6a, 0x63, 0x62, 0x20, 0x23, 0xcb, 0x77, 0x01, 0x20, + 0xf8, 0xbd, 0xc0, 0x46, 0x40, 0x01, 0x00, 0x20, 0x44, 0x01, 0x00, 0x20, + 0xff, 0x01, 0x00, 0x00, 0xf4, 0x0f, 0x00, 0x00, 0xf4, 0xff, 0x00, 0x00, + 0x08, 0xb5, 0x05, 0x49, 0x05, 0x4a, 0x06, 0x48, 0x00, 0xf0, 0x10, 0xf8, + 0x05, 0x4b, 0x06, 0x49, 0x00, 0x22, 0x1a, 0x70, 0x5a, 0x54, 0x08, 0xbd, + 0x00, 0x6d, 0x00, 0x00, 0x01, 0x04, 0x00, 0x00, 0x48, 0x03, 0x00, 0x20, + 0x60, 0x03, 0x00, 0x20, 0x02, 0x04, 0x00, 0x00, 0x30, 0xb5, 0x09, 0x4c, + 0x09, 0x4b, 0xa5, 0x68, 0x6d, 0x03, 0x6d, 0x0f, 0xad, 0x00, 0xeb, 0x58, + 0x03, 0x60, 0xa4, 0x68, 0x01, 0x61, 0xa4, 0xb2, 0x44, 0x60, 0x5c, 0x43, + 0x9b, 0x00, 0x84, 0x60, 0xc3, 0x60, 0x42, 0x61, 0x30, 0xbd, 0xc0, 0x46, + 0x00, 0x40, 0x00, 0x41, 0x00, 0x72, 0x00, 0x00, 0xf7, 0xb5, 0x1f, 0x4e, + 0x80, 0x27, 0x75, 0x68, 0x03, 0x33, 0x3d, 0x43, 0x9b, 0x08, 0x75, 0x60, + 0x00, 0x2b, 0x34, 0xd0, 0x1b, 0x4d, 0x35, 0x80, 0x35, 0x7d, 0xef, 0x07, + 0xfc, 0xd5, 0x1d, 0x1c, 0x5f, 0x1b, 0x01, 0x97, 0x07, 0x68, 0xbf, 0x08, + 0xbc, 0x46, 0x01, 0x9f, 0x67, 0x45, 0x1f, 0xd2, 0x00, 0x2d, 0x1d, 0xd0, + 0x17, 0x78, 0x01, 0x3d, 0x01, 0x97, 0xff, 0x27, 0xbc, 0x43, 0x01, 0x9f, + 0x3c, 0x43, 0x57, 0x78, 0x3f, 0x02, 0x01, 0x97, 0x0f, 0x4f, 0x3c, 0x40, + 0x01, 0x9f, 0x3c, 0x43, 0x97, 0x78, 0x3f, 0x04, 0xbc, 0x46, 0x0d, 0x4f, + 0x3c, 0x40, 0xd7, 0x78, 0xa4, 0xb2, 0x3f, 0x06, 0x00, 0x97, 0x67, 0x46, + 0x3c, 0x43, 0x00, 0x9f, 0x04, 0x32, 0x3c, 0x43, 0x10, 0xc1, 0xd7, 0xe7, + 0x07, 0x4b, 0x33, 0x80, 0x33, 0x7d, 0xdf, 0x07, 0xfc, 0xd5, 0x2b, 0x1c, + 0xc8, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x44, 0xa5, 0xff, 0xff, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, 0x04, 0xa5, 0xff, 0xff, + 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, 0x1a, 0x80, 0x1a, 0x7d, + 0xd1, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x16, 0x1c, + 0xeb, 0x68, 0x28, 0x1c, 0x21, 0x1c, 0x9e, 0x42, 0x05, 0xd9, 0xff, 0xf7, + 0xe7, 0xff, 0xeb, 0x68, 0xe4, 0x18, 0xf6, 0x1a, 0xf4, 0xe7, 0xff, 0xf7, + 0xe1, 0xff, 0x70, 0xbd, 0x43, 0x7a, 0x00, 0x2b, 0x04, 0xd1, 0x83, 0x72, + 0xc3, 0x72, 0xc3, 0x60, 0x01, 0x23, 0x43, 0x72, 0x70, 0x47, 0x30, 0xb5, + 0x85, 0xb0, 0x04, 0x1c, 0x02, 0xad, 0x00, 0x68, 0x02, 0x91, 0x03, 0x92, + 0x00, 0xf0, 0x88, 0xfc, 0x6b, 0x79, 0xe1, 0x79, 0x22, 0x7a, 0x00, 0x93, + 0x20, 0x68, 0x00, 0x23, 0x00, 0xf0, 0x22, 0xfd, 0x29, 0x79, 0x20, 0x68, + 0x02, 0x9a, 0x00, 0xf0, 0x4b, 0xfc, 0x20, 0x68, 0x00, 0xf0, 0x6e, 0xfc, + 0x05, 0xb0, 0x30, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0x18, 0x26, 0xff, 0xf7, + 0xd7, 0xff, 0x20, 0x79, 0x33, 0x1c, 0x43, 0x43, 0x0d, 0x4d, 0x08, 0x21, + 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x0a, 0xfb, 0xa0, 0x79, 0x33, 0x1c, + 0x43, 0x43, 0x08, 0x21, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x02, 0xfb, + 0x60, 0x79, 0x08, 0x21, 0x46, 0x43, 0xad, 0x19, 0x69, 0x56, 0x00, 0xf0, + 0xfb, 0xfa, 0x04, 0x4b, 0x20, 0x1c, 0x06, 0xcb, 0xff, 0xf7, 0xc3, 0xff, + 0x70, 0xbd, 0xc0, 0x46, 0x20, 0x72, 0x00, 0x00, 0x64, 0x07, 0x00, 0x20, + 0x07, 0xb5, 0x83, 0x7a, 0x00, 0x91, 0x01, 0x92, 0x00, 0x2b, 0x0d, 0xd0, + 0x9a, 0x07, 0x06, 0xd5, 0xef, 0xf3, 0x10, 0x83, 0x5a, 0x42, 0x53, 0x41, + 0xc3, 0x72, 0x72, 0xb6, 0x04, 0xe0, 0xda, 0x07, 0x02, 0xd5, 0x82, 0x89, + 0x03, 0x4b, 0x9a, 0x60, 0x00, 0x99, 0x01, 0x9a, 0xff, 0xf7, 0xa5, 0xff, + 0x07, 0xbd, 0xc0, 0x46, 0x00, 0x18, 0x00, 0x40, 0x83, 0x7a, 0x00, 0x2b, + 0x0b, 0xd0, 0x9a, 0x07, 0x04, 0xd5, 0xc3, 0x7a, 0x00, 0x2b, 0x06, 0xd0, + 0x62, 0xb6, 0x04, 0xe0, 0xda, 0x07, 0x02, 0xd5, 0x82, 0x89, 0x01, 0x4b, + 0xda, 0x60, 0x70, 0x47, 0x00, 0x18, 0x00, 0x40, 0x08, 0xb5, 0x00, 0x68, + 0x00, 0xf0, 0x25, 0xfc, 0x08, 0xbd, 0x00, 0x00, 0x09, 0x4b, 0x0a, 0x4a, + 0x0a, 0x49, 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x09, 0x4b, + 0x19, 0x60, 0x12, 0x21, 0x19, 0x71, 0x14, 0x21, 0x99, 0x71, 0x15, 0x21, + 0x59, 0x71, 0x01, 0x21, 0x5a, 0x72, 0xd9, 0x71, 0x1a, 0x72, 0x70, 0x47, + 0x64, 0x07, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, 0x04, 0x09, 0x00, 0x20, + 0x6c, 0x07, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x02, 0xfe, + 0x08, 0xbd, 0xc0, 0x46, 0x38, 0x08, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, + 0x00, 0xf0, 0xfa, 0xfd, 0x08, 0xbd, 0xc0, 0x46, 0x7c, 0x07, 0x00, 0x20, + 0xf7, 0xb5, 0x16, 0x4f, 0x16, 0x49, 0x38, 0x1c, 0x00, 0xf0, 0x3a, 0xfb, + 0x15, 0x49, 0x16, 0x48, 0x00, 0xf0, 0x36, 0xfb, 0x15, 0x49, 0x16, 0x48, + 0x00, 0xf0, 0x32, 0xfb, 0x15, 0x49, 0x16, 0x48, 0x00, 0xf0, 0x2e, 0xfb, + 0x15, 0x49, 0x16, 0x48, 0x00, 0xf0, 0x2a, 0xfb, 0x15, 0x4d, 0x03, 0x26, + 0x01, 0x24, 0x28, 0x1c, 0x14, 0x49, 0x00, 0xf0, 0x23, 0xfb, 0x39, 0x1c, + 0x00, 0x96, 0x23, 0x1c, 0x01, 0x94, 0x00, 0x22, 0x11, 0x48, 0x00, 0xf0, + 0xf1, 0xfc, 0x00, 0x96, 0x29, 0x1c, 0x01, 0x94, 0x24, 0x22, 0x23, 0x23, + 0x0e, 0x48, 0x00, 0xf0, 0xe9, 0xfc, 0xf7, 0xbd, 0xf8, 0x08, 0x00, 0x20, + 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, 0xfc, 0x08, 0x00, 0x20, + 0x00, 0x10, 0x00, 0x42, 0x00, 0x09, 0x00, 0x20, 0x00, 0x14, 0x00, 0x42, + 0xf4, 0x08, 0x00, 0x20, 0x00, 0x18, 0x00, 0x42, 0x04, 0x09, 0x00, 0x20, + 0x08, 0x09, 0x00, 0x20, 0x00, 0x1c, 0x00, 0x42, 0x38, 0x08, 0x00, 0x20, + 0x7c, 0x07, 0x00, 0x20, 0xfe, 0xe7, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x4b, + 0x1b, 0x68, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, 0x08, 0xbd, 0xc0, 0x46, + 0x0c, 0x09, 0x00, 0x20, 0x38, 0xb5, 0x0f, 0x49, 0x0f, 0x4c, 0xa1, 0x42, + 0x04, 0xd1, 0x00, 0xf0, 0x4f, 0xf8, 0xfe, 0xf7, 0xbd, 0xfa, 0x0b, 0xe0, + 0x0c, 0x4d, 0x8d, 0x42, 0xf7, 0xd0, 0x00, 0x23, 0xca, 0x18, 0xe8, 0x18, + 0xa2, 0x42, 0x04, 0xd2, 0x00, 0x68, 0x04, 0x33, 0x10, 0x60, 0xf7, 0xe7, + 0xfe, 0xe7, 0x90, 0x42, 0xeb, 0xd0, 0x06, 0x4b, 0x06, 0x4a, 0x93, 0x42, + 0xe7, 0xd2, 0x00, 0x22, 0x04, 0xc3, 0xf9, 0xe7, 0x00, 0x00, 0x00, 0x20, + 0x94, 0x00, 0x00, 0x20, 0x40, 0x77, 0x00, 0x00, 0x94, 0x00, 0x00, 0x20, + 0x24, 0x09, 0x00, 0x20, 0x08, 0xb5, 0x00, 0xf0, 0x26, 0xf8, 0x00, 0x28, + 0x01, 0xd1, 0x00, 0xf0, 0x17, 0xf8, 0x08, 0xbd, 0x01, 0x4b, 0x18, 0x68, + 0x70, 0x47, 0xc0, 0x46, 0x10, 0x09, 0x00, 0x20, 0x70, 0xb5, 0x04, 0x1e, + 0x08, 0xd0, 0x05, 0x4b, 0x1d, 0x68, 0x1e, 0x1c, 0x00, 0xf0, 0x12, 0xf8, + 0x33, 0x68, 0x5b, 0x1b, 0xa3, 0x42, 0xf9, 0xd3, 0x70, 0xbd, 0xc0, 0x46, + 0x10, 0x09, 0x00, 0x20, 0x08, 0xb5, 0x03, 0x4b, 0x1a, 0x68, 0x01, 0x32, + 0x1a, 0x60, 0x00, 0xf0, 0x61, 0xfa, 0x08, 0xbd, 0x10, 0x09, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, 0x70, 0xb5, 0x49, 0x4a, + 0x1e, 0x21, 0x53, 0x68, 0x02, 0x20, 0x8b, 0x43, 0x03, 0x43, 0x47, 0x49, + 0x53, 0x60, 0x8b, 0x69, 0x08, 0x24, 0x23, 0x43, 0x8b, 0x61, 0x45, 0x4c, + 0x45, 0x4b, 0x9c, 0x82, 0x9c, 0x8a, 0x20, 0x43, 0x98, 0x82, 0x10, 0x1c, + 0xda, 0x68, 0x94, 0x07, 0xfc, 0xd5, 0x42, 0x4a, 0x01, 0x24, 0x14, 0x70, + 0x14, 0x78, 0xe5, 0x07, 0x04, 0xd5, 0x3f, 0x4c, 0x64, 0x78, 0x64, 0xb2, + 0x00, 0x2c, 0xf7, 0xdb, 0x01, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, + 0x00, 0x2c, 0xfb, 0xdb, 0x3a, 0x4d, 0x39, 0x4c, 0x65, 0x60, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x82, 0x25, 0x35, 0x4c, 0xed, 0x01, + 0x65, 0x80, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x02, 0x24, + 0x9c, 0x84, 0xdc, 0x68, 0xe6, 0x06, 0xfc, 0xd5, 0x31, 0x4d, 0x2e, 0x4c, + 0xe5, 0x62, 0xdd, 0x68, 0x2c, 0x4c, 0xee, 0x06, 0xfb, 0xd5, 0xa5, 0x8c, + 0x2e, 0x4e, 0x35, 0x43, 0xa5, 0x84, 0xdd, 0x68, 0x28, 0x4c, 0xee, 0x06, + 0xfb, 0xd5, 0xa5, 0x8c, 0x02, 0x26, 0x35, 0x43, 0xa5, 0x84, 0xdc, 0x68, + 0x25, 0x06, 0xfc, 0xd5, 0x23, 0x4c, 0xe4, 0x68, 0x66, 0x06, 0xf8, 0xd5, + 0xdc, 0x68, 0xe5, 0x06, 0xfc, 0xd5, 0x00, 0x24, 0x94, 0x60, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x22, 0x4d, 0x1d, 0x4c, 0x65, 0x60, + 0x55, 0x78, 0x1c, 0x4c, 0x6d, 0xb2, 0x00, 0x2d, 0xfa, 0xdb, 0x1e, 0x6a, + 0x1e, 0x4d, 0x35, 0x40, 0x1d, 0x62, 0x1d, 0x6a, 0x80, 0x26, 0xb5, 0x43, + 0x1d, 0x62, 0x03, 0x23, 0xa3, 0x60, 0x1b, 0x4b, 0x63, 0x60, 0x53, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x00, 0x23, 0x0b, 0x72, 0x18, 0x4a, + 0x4b, 0x72, 0x8b, 0x72, 0xcb, 0x72, 0x17, 0x4b, 0xff, 0x21, 0x1a, 0x60, + 0x16, 0x4b, 0x17, 0x4a, 0x1b, 0x68, 0x12, 0x68, 0x5c, 0x01, 0xd2, 0x0e, + 0x21, 0x40, 0x11, 0x43, 0x9a, 0x06, 0x52, 0x0f, 0x12, 0x02, 0x0b, 0x1c, + 0x13, 0x43, 0x12, 0x4a, 0x13, 0x85, 0x43, 0x68, 0x80, 0x22, 0x13, 0x43, + 0x43, 0x60, 0x70, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x00, 0x04, 0x00, 0x40, + 0x0c, 0x06, 0x00, 0x00, 0x00, 0x08, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, + 0x01, 0x05, 0x01, 0x00, 0xb9, 0x05, 0xff, 0x7d, 0x04, 0x0a, 0x00, 0x00, + 0x00, 0x07, 0x03, 0x00, 0xff, 0xfc, 0xff, 0xff, 0x03, 0x06, 0x01, 0x00, + 0x00, 0x6c, 0xdc, 0x02, 0x04, 0x00, 0x00, 0x20, 0x24, 0x60, 0x80, 0x00, + 0x20, 0x60, 0x80, 0x00, 0x00, 0x40, 0x00, 0x42, 0x31, 0x4b, 0xfa, 0x21, + 0x18, 0x68, 0x10, 0xb5, 0x89, 0x00, 0x00, 0xf0, 0x73, 0xfd, 0x2f, 0x4b, + 0x01, 0x38, 0x98, 0x42, 0x24, 0xd8, 0x2e, 0x4a, 0x2e, 0x4b, 0x50, 0x60, + 0x18, 0x6a, 0xc0, 0x21, 0x00, 0x02, 0x00, 0x0a, 0x09, 0x06, 0x01, 0x43, + 0x19, 0x62, 0x00, 0x24, 0x07, 0x21, 0x94, 0x60, 0x11, 0x60, 0x19, 0x6a, + 0x80, 0x22, 0x09, 0x02, 0x09, 0x0a, 0x12, 0x06, 0x0a, 0x43, 0x1a, 0x62, + 0x25, 0x4b, 0xfc, 0x21, 0x1a, 0x6a, 0x0a, 0x43, 0x1a, 0x62, 0x19, 0x6a, + 0xfc, 0x22, 0x92, 0x01, 0x0a, 0x43, 0x1a, 0x62, 0x19, 0x6a, 0xa0, 0x22, + 0xd2, 0x02, 0x0a, 0x43, 0x1a, 0x62, 0x00, 0xe0, 0xfe, 0xe7, 0x20, 0x1c, + 0x00, 0x21, 0x01, 0x34, 0x00, 0xf0, 0x70, 0xf8, 0x13, 0x2c, 0xf8, 0xd1, + 0x1a, 0x4c, 0x63, 0x78, 0x5b, 0xb2, 0x00, 0x2b, 0xfa, 0xdb, 0x19, 0x4b, + 0x63, 0x80, 0x19, 0x4b, 0x5a, 0x7e, 0xd2, 0x09, 0x01, 0x2a, 0xfa, 0xd0, + 0xe4, 0x22, 0xd2, 0x00, 0x9a, 0x80, 0x3f, 0x22, 0xda, 0x70, 0x59, 0x7e, + 0x13, 0x4a, 0xc9, 0x09, 0x01, 0x29, 0xfa, 0xd0, 0xc0, 0x23, 0x5b, 0x01, + 0x00, 0x20, 0x13, 0x61, 0x90, 0x70, 0x00, 0xf0, 0x23, 0xf8, 0x63, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x0d, 0x4a, 0x09, 0x4b, 0x5a, 0x80, + 0x0c, 0x4b, 0xda, 0x79, 0xd2, 0x09, 0x01, 0x2a, 0xfa, 0xd0, 0x41, 0x22, + 0x5a, 0x70, 0x10, 0xbd, 0x04, 0x00, 0x00, 0x20, 0xff, 0xff, 0xff, 0x00, + 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, 0x00, 0x04, 0x00, 0x40, + 0x00, 0x0c, 0x00, 0x40, 0x1e, 0x40, 0x00, 0x00, 0x00, 0x40, 0x00, 0x42, + 0x21, 0x40, 0x00, 0x00, 0x00, 0x48, 0x00, 0x42, 0x00, 0xb5, 0x14, 0x4a, + 0x51, 0x7e, 0x13, 0x1c, 0xc9, 0x09, 0x01, 0x29, 0xf9, 0xd0, 0x01, 0x38, + 0x04, 0x28, 0x13, 0xd8, 0x19, 0x69, 0x10, 0x4a, 0x0a, 0x40, 0x1a, 0x61, + 0x5a, 0x78, 0x0f, 0x21, 0x8a, 0x43, 0x00, 0xf0, 0xe5, 0xfc, 0x03, 0x05, + 0x09, 0x07, 0x03, 0x00, 0x01, 0x21, 0x02, 0xe0, 0x03, 0x21, 0x00, 0xe0, + 0x02, 0x21, 0x0a, 0x43, 0x5a, 0x70, 0x0a, 0xe0, 0x11, 0x69, 0xf0, 0x23, + 0x1b, 0x05, 0x0b, 0x43, 0x13, 0x61, 0x53, 0x78, 0x0f, 0x21, 0x8b, 0x43, + 0x02, 0x21, 0x0b, 0x43, 0x53, 0x70, 0x00, 0xbd, 0x00, 0x40, 0x00, 0x42, + 0xff, 0xff, 0xff, 0xf0, 0x10, 0xb5, 0x18, 0x24, 0x02, 0x1c, 0x20, 0x1c, + 0x50, 0x43, 0x27, 0x4b, 0x18, 0x18, 0x00, 0x7a, 0x40, 0xb2, 0x01, 0x30, + 0x46, 0xd0, 0x03, 0x29, 0x44, 0xd8, 0x08, 0x1c, 0x21, 0x1c, 0x00, 0xf0, + 0xb9, 0xfc, 0x02, 0x33, 0x11, 0x21, 0x62, 0x43, 0x98, 0x56, 0x9a, 0x18, + 0xc3, 0x01, 0x1f, 0x48, 0x52, 0x68, 0x1b, 0x18, 0x99, 0x18, 0x40, 0x31, + 0x02, 0x20, 0x08, 0x70, 0x01, 0x21, 0x91, 0x40, 0x59, 0x60, 0x2f, 0xe0, + 0x62, 0x43, 0x98, 0x56, 0x18, 0x49, 0x9a, 0x18, 0x52, 0x68, 0xc3, 0x01, + 0x5b, 0x18, 0x99, 0x18, 0x40, 0x31, 0x06, 0x20, 0x08, 0x70, 0x01, 0x21, + 0x91, 0x40, 0x59, 0x60, 0x99, 0x61, 0x1f, 0xe0, 0x51, 0x43, 0x5a, 0x56, + 0x10, 0x48, 0x59, 0x18, 0x4b, 0x68, 0xd2, 0x01, 0x11, 0x18, 0xc8, 0x18, + 0x40, 0x30, 0x06, 0x24, 0x04, 0x70, 0x01, 0x20, 0x98, 0x40, 0x48, 0x60, + 0x0b, 0x49, 0x52, 0x18, 0x50, 0x60, 0x0d, 0xe0, 0x62, 0x43, 0x98, 0x56, + 0x9a, 0x18, 0xc3, 0x01, 0x06, 0x48, 0x52, 0x68, 0x1b, 0x18, 0x99, 0x18, + 0x40, 0x31, 0x02, 0x20, 0x08, 0x70, 0x01, 0x21, 0x91, 0x40, 0x99, 0x60, + 0x10, 0xbd, 0xc0, 0x46, 0x20, 0x72, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x10, 0x44, 0x00, 0x41, 0x18, 0x23, 0x58, 0x43, 0x13, 0x4a, 0xf0, 0xb5, + 0x13, 0x18, 0x08, 0x24, 0x1c, 0x57, 0x01, 0x34, 0x1f, 0xd0, 0x82, 0x56, + 0x10, 0x4e, 0xd2, 0x01, 0x5d, 0x68, 0x01, 0x24, 0x90, 0x19, 0x23, 0x1c, + 0x86, 0x68, 0xab, 0x40, 0x1e, 0x42, 0x0b, 0xd1, 0x0e, 0x1c, 0x77, 0x1e, + 0xbe, 0x41, 0x40, 0x19, 0x34, 0x40, 0x40, 0x30, 0xa5, 0x00, 0x04, 0x78, + 0x04, 0x26, 0xb4, 0x43, 0x2c, 0x43, 0x04, 0x70, 0x00, 0x29, 0x03, 0xd1, + 0x05, 0x49, 0x52, 0x18, 0x53, 0x60, 0x02, 0xe0, 0x02, 0x4e, 0x92, 0x19, + 0x93, 0x61, 0xf0, 0xbd, 0x20, 0x72, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x10, 0x44, 0x00, 0x41, 0x18, 0x22, 0x42, 0x43, 0xf8, 0xb5, 0x2d, 0x4d, + 0x08, 0x24, 0xaa, 0x18, 0x14, 0x57, 0x03, 0x1c, 0x62, 0x1c, 0x50, 0xd0, + 0x48, 0x1c, 0x00, 0x24, 0x0c, 0x28, 0x4c, 0xd8, 0x00, 0xf0, 0x30, 0xfc, + 0x07, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x0a, 0x0a, 0x0a, + 0x0a, 0x00, 0x01, 0x24, 0x64, 0x42, 0x40, 0xe0, 0x09, 0x29, 0x02, 0xd1, + 0x18, 0x1c, 0x00, 0x21, 0x03, 0xe0, 0x0a, 0x29, 0x04, 0xd1, 0x18, 0x1c, + 0x02, 0x21, 0xff, 0xf7, 0x51, 0xff, 0x23, 0xe0, 0x00, 0x24, 0x0b, 0x29, + 0x31, 0xd1, 0x18, 0x1c, 0x01, 0x21, 0xff, 0xf7, 0x49, 0xff, 0x2c, 0xe0, + 0x18, 0x22, 0x53, 0x43, 0xea, 0x18, 0x52, 0x68, 0xeb, 0x56, 0x01, 0x20, + 0x14, 0x1c, 0x04, 0x40, 0x55, 0x08, 0xdb, 0x01, 0x00, 0x2c, 0x11, 0xd0, + 0x12, 0x4c, 0x1b, 0x19, 0x5d, 0x19, 0x30, 0x35, 0x2e, 0x78, 0x0c, 0x01, + 0x0f, 0x21, 0x31, 0x40, 0x21, 0x43, 0x9a, 0x18, 0xc9, 0xb2, 0x29, 0x70, + 0x40, 0x32, 0x13, 0x78, 0x18, 0x43, 0x10, 0x70, 0x00, 0x24, 0x0e, 0xe0, + 0x09, 0x4e, 0x0f, 0x27, 0x9b, 0x19, 0x5d, 0x19, 0x30, 0x35, 0x2e, 0x78, + 0x9a, 0x18, 0xbe, 0x43, 0x31, 0x43, 0xc9, 0xb2, 0x29, 0x70, 0x40, 0x32, + 0x13, 0x78, 0x18, 0x43, 0x10, 0x70, 0x20, 0x1c, 0xf8, 0xbd, 0xc0, 0x46, + 0x20, 0x72, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0xf7, 0xb5, 0x8a, 0x18, + 0x06, 0x1c, 0x0d, 0x1c, 0x01, 0x92, 0x0c, 0x1c, 0x01, 0x9b, 0x67, 0x1b, + 0x9c, 0x42, 0x07, 0xd0, 0x33, 0x68, 0x21, 0x78, 0x1b, 0x68, 0x30, 0x1c, + 0x98, 0x47, 0x01, 0x34, 0x00, 0x28, 0xf3, 0xd1, 0x38, 0x1c, 0xfe, 0xbd, + 0x15, 0x4a, 0x13, 0x68, 0x58, 0x1c, 0x25, 0xd0, 0x01, 0x3b, 0x13, 0x60, + 0x00, 0x2b, 0x21, 0xd1, 0x72, 0xb6, 0x12, 0x4a, 0x12, 0x4b, 0x04, 0x32, + 0x9a, 0x42, 0x07, 0xd8, 0xbf, 0xf3, 0x4f, 0x8f, 0x10, 0x4a, 0x11, 0x4b, + 0xda, 0x60, 0xbf, 0xf3, 0x4f, 0x8f, 0x11, 0xe0, 0x0f, 0x4b, 0x19, 0x7d, + 0xc8, 0x07, 0xfb, 0xd5, 0x18, 0x8b, 0x20, 0x21, 0xff, 0x31, 0x92, 0x08, + 0x52, 0x00, 0x01, 0x43, 0x19, 0x83, 0xda, 0x61, 0x0a, 0x4a, 0x1a, 0x80, + 0x1a, 0x7d, 0xd1, 0x07, 0xfc, 0xd5, 0xe5, 0xe7, 0xc0, 0x46, 0xfd, 0xe7, + 0x70, 0x47, 0xc0, 0x46, 0x08, 0x00, 0x00, 0x20, 0x00, 0x40, 0x00, 0x00, + 0x03, 0x02, 0x00, 0x00, 0x04, 0x00, 0xfa, 0x05, 0x00, 0xed, 0x00, 0xe0, + 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, 0x01, 0x60, 0x70, 0x47, + 0xf7, 0xb5, 0x08, 0xac, 0x26, 0x78, 0x04, 0x68, 0x9d, 0x1e, 0x27, 0x68, + 0x6c, 0x1e, 0xa5, 0x41, 0xec, 0xb2, 0x92, 0x07, 0x05, 0x68, 0x3a, 0x43, + 0x27, 0x06, 0x3a, 0x43, 0x2a, 0x60, 0x02, 0x68, 0x07, 0x25, 0x29, 0x40, + 0x50, 0x68, 0xb5, 0x01, 0x00, 0x2c, 0x00, 0xd0, 0x5c, 0x03, 0x29, 0x43, + 0x01, 0x43, 0x0c, 0x43, 0x54, 0x60, 0xf7, 0xbd, 0x30, 0xb5, 0x03, 0x68, + 0xc0, 0x25, 0x1c, 0x68, 0xad, 0x03, 0x12, 0x05, 0x2a, 0x40, 0x22, 0x43, + 0xc0, 0x24, 0xa4, 0x02, 0x09, 0x04, 0x21, 0x40, 0x11, 0x43, 0x19, 0x60, + 0x03, 0x68, 0x5a, 0x68, 0x14, 0x43, 0x5c, 0x60, 0x30, 0xbd, 0x03, 0x68, + 0x01, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, 0x11, 0x68, + 0x01, 0x23, 0x19, 0x42, 0xfb, 0xd1, 0xd1, 0x69, 0x19, 0x42, 0xf8, 0xd1, + 0x70, 0x47, 0x03, 0x68, 0x02, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, + 0x02, 0x68, 0xd3, 0x69, 0x99, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, + 0x1a, 0x7e, 0xd1, 0x07, 0x02, 0xd4, 0x1a, 0x7e, 0x91, 0x07, 0xfc, 0xd5, + 0x70, 0x47, 0x03, 0x68, 0x00, 0x22, 0x5a, 0x83, 0x70, 0x47, 0x03, 0x68, + 0x18, 0x7e, 0x40, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, + 0xc0, 0x09, 0x70, 0x47, 0x03, 0x68, 0x80, 0x22, 0x19, 0x7e, 0x52, 0x42, + 0x0a, 0x43, 0x1a, 0x76, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x01, 0x23, + 0x18, 0x40, 0x70, 0x47, 0x03, 0x68, 0x18, 0x8d, 0xc0, 0xb2, 0x70, 0x47, + 0x03, 0x68, 0x1a, 0x7e, 0x01, 0x20, 0x02, 0x42, 0xfb, 0xd0, 0x19, 0x85, + 0x70, 0x47, 0x03, 0x68, 0x01, 0x22, 0x9a, 0x75, 0x70, 0x47, 0x03, 0x68, + 0x01, 0x22, 0x1a, 0x75, 0x70, 0x47, 0x00, 0x00, 0x70, 0xb5, 0x03, 0x68, + 0x01, 0x26, 0x8d, 0x07, 0xed, 0x0f, 0x31, 0x40, 0x1c, 0x68, 0x6d, 0x07, + 0x09, 0x07, 0x29, 0x43, 0x21, 0x43, 0x19, 0x60, 0x04, 0x68, 0x51, 0x00, + 0x03, 0x48, 0x00, 0xf0, 0x0b, 0xfb, 0x01, 0x38, 0xc0, 0xb2, 0x20, 0x73, + 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x6c, 0xdc, 0x02, 0x03, 0x68, 0x01, 0x21, + 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, 0x11, 0x68, 0x01, 0x23, + 0x19, 0x42, 0xfb, 0xd1, 0xd1, 0x69, 0x19, 0x42, 0xf8, 0xd1, 0x70, 0x47, + 0x03, 0x68, 0x02, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, + 0xd3, 0x69, 0x99, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, 0xda, 0x69, + 0x91, 0x07, 0xfc, 0xd4, 0x1a, 0x68, 0x02, 0x21, 0x8a, 0x43, 0x1a, 0x60, + 0x70, 0x47, 0x03, 0x68, 0x9a, 0x6a, 0x52, 0x0a, 0x52, 0x02, 0x11, 0x43, + 0x99, 0x62, 0x03, 0x68, 0x1a, 0x7e, 0x51, 0x07, 0xfc, 0xd5, 0x98, 0x6a, + 0xc0, 0xb2, 0x70, 0x47, 0x03, 0x68, 0x22, 0x4a, 0x30, 0xb5, 0x93, 0x42, + 0x11, 0xd0, 0x21, 0x4a, 0x93, 0x42, 0x11, 0xd0, 0x20, 0x4a, 0x93, 0x42, + 0x11, 0xd0, 0x20, 0x4a, 0x93, 0x42, 0x11, 0xd0, 0x1f, 0x4a, 0x93, 0x42, + 0x11, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x30, 0xd1, 0x0e, 0x23, 0x19, 0x22, + 0x0d, 0xe0, 0x09, 0x23, 0x14, 0x22, 0x0a, 0xe0, 0x0a, 0x23, 0x15, 0x22, + 0x07, 0xe0, 0x0b, 0x23, 0x16, 0x22, 0x04, 0xe0, 0x0c, 0x23, 0x17, 0x22, + 0x01, 0xe0, 0x0d, 0x23, 0x18, 0x22, 0xdc, 0xb2, 0x15, 0x49, 0x01, 0x20, + 0x9b, 0x08, 0xa0, 0x40, 0x9b, 0x00, 0x08, 0x60, 0x5b, 0x18, 0x03, 0x20, + 0xc0, 0x21, 0x89, 0x00, 0x04, 0x40, 0x5d, 0x58, 0xe0, 0x00, 0xff, 0x24, + 0x84, 0x40, 0xa5, 0x43, 0x2c, 0x1c, 0xc0, 0x25, 0x85, 0x40, 0x28, 0x1c, + 0x20, 0x43, 0x58, 0x50, 0x80, 0x23, 0xdb, 0x01, 0x1a, 0x43, 0x0a, 0x4b, + 0x5a, 0x80, 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, 0x30, 0xbd, + 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, 0x00, 0x10, 0x00, 0x42, + 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, 0x00, 0x1c, 0x00, 0x42, + 0x00, 0xe1, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x40, 0xf8, 0xb5, 0x04, 0x1c, + 0x15, 0x1c, 0x0e, 0x1c, 0x1f, 0x1c, 0xff, 0xf7, 0xa3, 0xff, 0x20, 0x1c, + 0xff, 0xf7, 0x0d, 0xff, 0xb1, 0x00, 0x1c, 0x22, 0x0a, 0x40, 0x69, 0x07, + 0x23, 0x68, 0x09, 0x0c, 0x0a, 0x43, 0x1a, 0x60, 0x22, 0x68, 0x84, 0x23, + 0x93, 0x75, 0x01, 0x2e, 0x1a, 0xd1, 0x08, 0x21, 0x01, 0x2d, 0x00, 0xd1, + 0x10, 0x21, 0x0c, 0x4b, 0x79, 0x43, 0x18, 0x68, 0xc0, 0x00, 0x00, 0xf0, + 0x5f, 0xfa, 0x23, 0x68, 0x07, 0x21, 0x9a, 0x89, 0x01, 0x40, 0xd2, 0x04, + 0x49, 0x03, 0xd2, 0x0c, 0x0a, 0x43, 0x9a, 0x81, 0x23, 0x68, 0x00, 0x04, + 0xc2, 0x0c, 0x98, 0x89, 0x40, 0x0b, 0x40, 0x03, 0x10, 0x43, 0x98, 0x81, + 0xf8, 0xbd, 0xc0, 0x46, 0x04, 0x00, 0x00, 0x20, 0xf7, 0xb5, 0x01, 0x93, + 0x08, 0xab, 0x04, 0x1c, 0x1f, 0x78, 0x0d, 0x1c, 0x16, 0x1c, 0xff, 0xf7, + 0x3d, 0xff, 0x20, 0x1c, 0xff, 0xf7, 0x68, 0xff, 0xbf, 0x07, 0x0c, 0x22, + 0x17, 0x43, 0xc0, 0x22, 0x92, 0x03, 0x36, 0x05, 0x16, 0x40, 0xc0, 0x22, + 0x92, 0x02, 0x2d, 0x04, 0x23, 0x68, 0x3e, 0x43, 0x01, 0x99, 0x15, 0x40, + 0x35, 0x43, 0x07, 0x22, 0x1d, 0x60, 0x0a, 0x40, 0x80, 0x21, 0x23, 0x68, + 0x89, 0x02, 0x0a, 0x43, 0x5a, 0x60, 0xf7, 0xbd, 0x01, 0x20, 0x70, 0x47, + 0x08, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, 0x98, 0x47, 0x08, 0xbd, + 0x13, 0x04, 0x00, 0x00, 0x82, 0x6d, 0x43, 0x6d, 0x9a, 0x42, 0x03, 0xd0, + 0x83, 0x6d, 0xc0, 0x18, 0x00, 0x7d, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, + 0x70, 0x47, 0x10, 0xb5, 0x04, 0x1c, 0x00, 0x69, 0xff, 0xf7, 0xa3, 0xfe, + 0x00, 0x23, 0x22, 0x1c, 0x63, 0x65, 0x9c, 0x32, 0xa3, 0x65, 0xa0, 0x34, + 0x13, 0x60, 0x23, 0x60, 0x10, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x87, 0xb0, + 0x01, 0x93, 0x0c, 0xab, 0x1b, 0x78, 0x00, 0x25, 0x02, 0x93, 0x0d, 0xab, + 0x1b, 0x78, 0x40, 0x26, 0x03, 0x93, 0x0e, 0xab, 0x1b, 0x78, 0x04, 0x1c, + 0x04, 0x93, 0x0f, 0xab, 0x1b, 0x78, 0x0f, 0x1c, 0x05, 0x93, 0xfa, 0x23, + 0x9b, 0x00, 0x83, 0x60, 0x12, 0x4b, 0x00, 0x92, 0x08, 0x33, 0x03, 0x60, + 0x45, 0x60, 0x29, 0x1c, 0x32, 0x1c, 0x14, 0x30, 0x00, 0xf0, 0x84, 0xfa, + 0x20, 0x1c, 0x65, 0x65, 0x32, 0x1c, 0xa5, 0x65, 0x29, 0x1c, 0x5c, 0x30, + 0x00, 0xf0, 0x7c, 0xfa, 0x00, 0x9a, 0x23, 0x1c, 0x9c, 0x33, 0x1d, 0x60, + 0x5d, 0x60, 0x27, 0x61, 0x1a, 0x72, 0x01, 0x9a, 0x20, 0x1c, 0x5a, 0x72, + 0x02, 0x9a, 0x9a, 0x72, 0x03, 0x9a, 0xda, 0x72, 0x04, 0x9a, 0x1a, 0x73, + 0x05, 0x9a, 0x1a, 0x77, 0x07, 0xb0, 0xf0, 0xbd, 0xa0, 0x76, 0x00, 0x00, + 0x30, 0xb5, 0x85, 0xb0, 0x04, 0x1c, 0x08, 0xa8, 0x05, 0x78, 0x09, 0xa8, + 0x00, 0x78, 0x00, 0x95, 0x01, 0x90, 0xff, 0x20, 0x02, 0x90, 0x03, 0x90, + 0x20, 0x1c, 0xff, 0xf7, 0xb3, 0xff, 0x20, 0x1c, 0x05, 0xb0, 0x30, 0xbd, + 0xf0, 0x23, 0x08, 0x1c, 0x18, 0x40, 0x30, 0x38, 0x43, 0x42, 0x58, 0x41, + 0x70, 0x47, 0xf0, 0x23, 0x1b, 0x01, 0x19, 0x40, 0x80, 0x23, 0x9b, 0x00, + 0x99, 0x42, 0x0c, 0xd0, 0xc0, 0x23, 0x9b, 0x00, 0x99, 0x42, 0x06, 0xd0, + 0x80, 0x23, 0x5b, 0x00, 0x05, 0x20, 0x99, 0x42, 0x04, 0xd0, 0x00, 0x20, + 0x02, 0xe0, 0x07, 0x20, 0x00, 0xe0, 0x06, 0x20, 0x70, 0x47, 0x0f, 0x23, + 0x19, 0x40, 0x01, 0x29, 0x05, 0xd0, 0x02, 0x39, 0x4b, 0x42, 0x4b, 0x41, + 0x02, 0x20, 0xc0, 0x1a, 0x00, 0xe0, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, + 0xf0, 0xb5, 0x03, 0x1c, 0x85, 0xb0, 0x03, 0x91, 0xa4, 0x33, 0x04, 0x1c, + 0x18, 0x27, 0x18, 0x78, 0x3b, 0x1c, 0x43, 0x43, 0x34, 0x4e, 0x08, 0x21, + 0xf3, 0x18, 0x59, 0x56, 0x15, 0x1c, 0xff, 0xf7, 0x2d, 0xfd, 0x23, 0x1c, + 0xa5, 0x33, 0x18, 0x78, 0x3b, 0x1c, 0x43, 0x43, 0x08, 0x21, 0xf3, 0x18, + 0x59, 0x56, 0xff, 0xf7, 0x23, 0xfd, 0x23, 0x1c, 0xa7, 0x33, 0x1b, 0x78, + 0x02, 0x2b, 0x0a, 0xd1, 0x23, 0x1c, 0xb8, 0x33, 0x18, 0x78, 0xff, 0x28, + 0x05, 0xd0, 0x47, 0x43, 0x08, 0x21, 0xf7, 0x19, 0x79, 0x56, 0xff, 0xf7, + 0x13, 0xfd, 0x27, 0x1c, 0xa8, 0x37, 0x38, 0x78, 0xff, 0x28, 0x1a, 0xd0, + 0x01, 0x21, 0xff, 0xf7, 0x81, 0xfc, 0x3b, 0x78, 0x18, 0x22, 0x5a, 0x43, + 0xb3, 0x56, 0x1f, 0x4f, 0xdb, 0x01, 0x21, 0x1c, 0xac, 0x31, 0xd8, 0x19, + 0x08, 0x60, 0x1d, 0x49, 0xb6, 0x18, 0x5b, 0x18, 0x21, 0x1c, 0x72, 0x68, + 0xb0, 0x31, 0x0b, 0x60, 0x01, 0x21, 0x91, 0x40, 0x0a, 0x1c, 0x21, 0x1c, + 0xb4, 0x31, 0x0a, 0x60, 0x1a, 0x60, 0x01, 0x21, 0x0a, 0x1c, 0x03, 0x9b, + 0x20, 0x69, 0xff, 0xf7, 0xb7, 0xfe, 0x29, 0x1c, 0x20, 0x1c, 0xff, 0xf7, + 0x88, 0xff, 0x29, 0x1c, 0x07, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x99, 0xff, + 0x29, 0x1c, 0x06, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x77, 0xff, 0x39, 0x1c, + 0x00, 0x90, 0x33, 0x1c, 0x20, 0x69, 0x01, 0x22, 0xff, 0xf7, 0x8a, 0xfd, + 0x23, 0x1c, 0xa7, 0x33, 0x19, 0x78, 0x01, 0x3b, 0x1a, 0x78, 0x20, 0x69, + 0xff, 0xf7, 0x9e, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0xbc, 0xfd, 0x05, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x20, 0x72, 0x00, 0x00, 0x18, 0x44, 0x00, 0x41, + 0x14, 0x44, 0x00, 0x41, 0x02, 0x6c, 0x43, 0x6c, 0xd0, 0x1a, 0x00, 0xd5, + 0x40, 0x30, 0x70, 0x47, 0x10, 0xb5, 0x04, 0x1c, 0x20, 0x1c, 0x5c, 0x30, + 0xff, 0xf7, 0xf4, 0xff, 0x00, 0x28, 0xf9, 0xd1, 0x20, 0x69, 0xff, 0xf7, + 0xac, 0xfd, 0x10, 0xbd, 0x08, 0xb5, 0x14, 0x30, 0xff, 0xf7, 0xea, 0xff, + 0x08, 0xbd, 0x02, 0x6c, 0x43, 0x6c, 0x9a, 0x42, 0x04, 0xdb, 0x03, 0x6c, + 0x40, 0x6c, 0xc0, 0x1a, 0x3f, 0x30, 0x03, 0xe0, 0x42, 0x6c, 0x03, 0x6c, + 0xd0, 0x1a, 0x01, 0x38, 0x70, 0x47, 0x08, 0xb5, 0x5c, 0x30, 0xff, 0xf7, + 0xee, 0xff, 0x08, 0xbd, 0x38, 0xb5, 0x04, 0x1c, 0x00, 0x69, 0xff, 0xf7, + 0x9a, 0xfd, 0x00, 0x28, 0x1f, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0xaa, 0xfd, + 0x63, 0x6d, 0x3f, 0x22, 0x01, 0x33, 0x13, 0x40, 0xa2, 0x6d, 0x93, 0x42, + 0x03, 0xd0, 0x62, 0x6d, 0xa2, 0x18, 0x10, 0x75, 0x63, 0x65, 0x23, 0x1c, + 0xa8, 0x33, 0x1b, 0x78, 0xff, 0x2b, 0x0c, 0xd0, 0x20, 0x1c, 0x14, 0x30, + 0xff, 0xf7, 0xcf, 0xff, 0x09, 0x28, 0x06, 0xdc, 0x23, 0x1c, 0x22, 0x1c, + 0xac, 0x33, 0xb4, 0x32, 0x1b, 0x68, 0x12, 0x68, 0x1a, 0x60, 0x20, 0x69, + 0xff, 0xf7, 0x85, 0xfd, 0x00, 0x28, 0x20, 0xd0, 0x25, 0x1c, 0x5c, 0x35, + 0x28, 0x1c, 0xff, 0xf7, 0xa5, 0xff, 0x03, 0x1c, 0x20, 0x69, 0x00, 0x2b, + 0x15, 0xd0, 0x23, 0x1c, 0x22, 0x1c, 0xa0, 0x33, 0x9c, 0x32, 0x19, 0x68, + 0x12, 0x68, 0x91, 0x42, 0x07, 0xd0, 0x1a, 0x68, 0xa9, 0x5c, 0x1a, 0x68, + 0x3f, 0x25, 0x01, 0x32, 0x2a, 0x40, 0x1a, 0x60, 0x01, 0xe0, 0x01, 0x21, + 0x49, 0x42, 0xc9, 0xb2, 0xff, 0xf7, 0x6e, 0xfd, 0x01, 0xe0, 0xff, 0xf7, + 0x76, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x54, 0xfd, 0x00, 0x28, 0x05, 0xd0, + 0x20, 0x69, 0xff, 0xf7, 0x53, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x43, 0xfd, + 0x38, 0xbd, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x1c, 0x00, 0x69, 0x0d, 0x1c, + 0xff, 0xf7, 0x4f, 0xfd, 0x00, 0x28, 0x0f, 0xd0, 0x20, 0x1c, 0x5c, 0x30, + 0xff, 0xf7, 0x70, 0xff, 0x00, 0x28, 0x40, 0xd0, 0x08, 0xe0, 0xef, 0xf3, + 0x10, 0x83, 0xda, 0x07, 0x23, 0xd4, 0x21, 0x4b, 0x5a, 0x68, 0xd2, 0x05, + 0xd2, 0x0d, 0x0b, 0xd1, 0x23, 0x1c, 0x9c, 0x33, 0x21, 0x1c, 0x1e, 0x68, + 0xa0, 0x31, 0x0a, 0x68, 0x01, 0x36, 0x3f, 0x20, 0x06, 0x40, 0x96, 0x42, + 0xeb, 0xd0, 0x1b, 0xe0, 0x10, 0x3a, 0xd2, 0xb2, 0x53, 0xb2, 0x00, 0x2b, + 0x08, 0xda, 0x0f, 0x23, 0x1a, 0x40, 0x08, 0x3a, 0x15, 0x4b, 0x92, 0x08, + 0x92, 0x00, 0xd2, 0x18, 0x53, 0x68, 0x04, 0xe0, 0x9b, 0x08, 0xc0, 0x33, + 0x12, 0x4a, 0x9b, 0x00, 0x9b, 0x58, 0x20, 0x69, 0xff, 0xf7, 0x1b, 0xfd, + 0x00, 0x28, 0xdb, 0xd0, 0x20, 0x1c, 0xff, 0xf7, 0x67, 0xff, 0xd7, 0xe7, + 0x1a, 0x68, 0x09, 0x68, 0x01, 0x32, 0x02, 0x40, 0x8a, 0x42, 0x04, 0xd0, + 0x19, 0x68, 0x20, 0x1c, 0x5c, 0x30, 0x45, 0x54, 0x1a, 0x60, 0x20, 0x69, + 0xff, 0xf7, 0x17, 0xfd, 0x03, 0xe0, 0x20, 0x69, 0x29, 0x1c, 0xff, 0xf7, + 0x0b, 0xfd, 0x01, 0x20, 0x70, 0xbd, 0xc0, 0x46, 0x00, 0xed, 0x00, 0xe0, + 0x18, 0xed, 0x00, 0xe0, 0x00, 0xe1, 0x00, 0xe0, 0x38, 0xb5, 0x82, 0x6d, + 0x43, 0x6d, 0x04, 0x1c, 0x9a, 0x42, 0x08, 0xd0, 0x83, 0x6d, 0x3f, 0x22, + 0xc3, 0x18, 0x1d, 0x7d, 0x83, 0x6d, 0x01, 0x33, 0x13, 0x40, 0x83, 0x65, + 0x01, 0xe0, 0x01, 0x25, 0x6d, 0x42, 0x23, 0x1c, 0xa8, 0x33, 0x1b, 0x78, + 0xff, 0x2b, 0x0b, 0xd0, 0x20, 0x1c, 0x14, 0x30, 0xff, 0xf7, 0x1d, 0xff, + 0x0a, 0x28, 0x05, 0xdd, 0x23, 0x1c, 0xb0, 0x33, 0xb4, 0x34, 0x1b, 0x68, + 0x22, 0x68, 0x1a, 0x60, 0x28, 0x1c, 0x38, 0xbd, 0x02, 0xb4, 0x71, 0x46, + 0x49, 0x08, 0x49, 0x00, 0x09, 0x5c, 0x49, 0x00, 0x8e, 0x44, 0x02, 0xbc, + 0x70, 0x47, 0xc0, 0x46, 0x00, 0x29, 0x34, 0xd0, 0x01, 0x23, 0x00, 0x22, + 0x10, 0xb4, 0x88, 0x42, 0x2c, 0xd3, 0x01, 0x24, 0x24, 0x07, 0xa1, 0x42, + 0x04, 0xd2, 0x81, 0x42, 0x02, 0xd2, 0x09, 0x01, 0x1b, 0x01, 0xf8, 0xe7, + 0xe4, 0x00, 0xa1, 0x42, 0x04, 0xd2, 0x81, 0x42, 0x02, 0xd2, 0x49, 0x00, + 0x5b, 0x00, 0xf8, 0xe7, 0x88, 0x42, 0x01, 0xd3, 0x40, 0x1a, 0x1a, 0x43, + 0x4c, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, 0x5c, 0x08, 0x22, 0x43, + 0x8c, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, 0x9c, 0x08, 0x22, 0x43, + 0xcc, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, 0xdc, 0x08, 0x22, 0x43, + 0x00, 0x28, 0x03, 0xd0, 0x1b, 0x09, 0x01, 0xd0, 0x09, 0x09, 0xe3, 0xe7, + 0x10, 0x1c, 0x10, 0xbc, 0x70, 0x47, 0x00, 0x28, 0x01, 0xd0, 0x00, 0x20, + 0xc0, 0x43, 0x07, 0xb4, 0x02, 0x48, 0x02, 0xa1, 0x40, 0x18, 0x02, 0x90, + 0x03, 0xbd, 0xc0, 0x46, 0x19, 0x00, 0x00, 0x00, 0x00, 0x29, 0xf0, 0xd0, + 0x03, 0xb5, 0xff, 0xf7, 0xb9, 0xff, 0x0e, 0xbc, 0x42, 0x43, 0x89, 0x1a, + 0x18, 0x47, 0xc0, 0x46, 0x70, 0x47, 0xc0, 0x46, 0x70, 0xb5, 0x0e, 0x4b, + 0x0e, 0x4d, 0x00, 0x24, 0xed, 0x1a, 0xad, 0x10, 0x1e, 0x1c, 0xac, 0x42, + 0x04, 0xd0, 0xa3, 0x00, 0xf3, 0x58, 0x98, 0x47, 0x01, 0x34, 0xf8, 0xe7, + 0x00, 0xf0, 0x32, 0xf9, 0x08, 0x4b, 0x09, 0x4d, 0x00, 0x24, 0xed, 0x1a, + 0xad, 0x10, 0x1e, 0x1c, 0xac, 0x42, 0x04, 0xd0, 0xa3, 0x00, 0xf3, 0x58, + 0x98, 0x47, 0x01, 0x34, 0xf8, 0xe7, 0x70, 0xbd, 0x70, 0x00, 0x00, 0x20, + 0x70, 0x00, 0x00, 0x20, 0x70, 0x00, 0x00, 0x20, 0x8c, 0x00, 0x00, 0x20, + 0x08, 0xb5, 0x03, 0x4b, 0x01, 0x1c, 0x18, 0x68, 0x00, 0xf0, 0x76, 0xf8, + 0x08, 0xbd, 0xc0, 0x46, 0x6c, 0x00, 0x00, 0x20, 0x08, 0xb5, 0x03, 0x4b, + 0x01, 0x1c, 0x18, 0x68, 0x00, 0xf0, 0x24, 0xf8, 0x08, 0xbd, 0xc0, 0x46, + 0x6c, 0x00, 0x00, 0x20, 0x30, 0xb5, 0x00, 0x23, 0x93, 0x42, 0x08, 0xd0, + 0xc5, 0x5c, 0x01, 0x33, 0xcc, 0x18, 0x01, 0x3c, 0x24, 0x78, 0xa5, 0x42, + 0xf6, 0xd0, 0x28, 0x1b, 0x00, 0xe0, 0x00, 0x20, 0x30, 0xbd, 0x10, 0xb5, + 0x00, 0x23, 0x93, 0x42, 0x03, 0xd0, 0xcc, 0x5c, 0xc4, 0x54, 0x01, 0x33, + 0xf9, 0xe7, 0x10, 0xbd, 0x03, 0x1c, 0x82, 0x18, 0x93, 0x42, 0x02, 0xd0, + 0x19, 0x70, 0x01, 0x33, 0xfa, 0xe7, 0x70, 0x47, 0x30, 0xb5, 0x00, 0x29, + 0x40, 0xd0, 0x04, 0x39, 0x0b, 0x68, 0x00, 0x2b, 0x00, 0xda, 0xc9, 0x18, + 0x1e, 0x4a, 0x13, 0x68, 0x14, 0x1c, 0x00, 0x2b, 0x02, 0xd1, 0x4b, 0x60, + 0x11, 0x60, 0x33, 0xe0, 0x99, 0x42, 0x0f, 0xd2, 0x08, 0x68, 0x0a, 0x18, + 0x9a, 0x42, 0x05, 0xd1, 0x13, 0x68, 0x52, 0x68, 0xc0, 0x18, 0x08, 0x60, + 0x4a, 0x60, 0x00, 0xe0, 0x4b, 0x60, 0x21, 0x60, 0x24, 0xe0, 0x8a, 0x42, + 0x03, 0xd8, 0x13, 0x1c, 0x5a, 0x68, 0x00, 0x2a, 0xf9, 0xd1, 0x1d, 0x68, + 0x5c, 0x19, 0x8c, 0x42, 0x0b, 0xd1, 0x09, 0x68, 0x69, 0x18, 0x58, 0x18, + 0x19, 0x60, 0x90, 0x42, 0x14, 0xd1, 0x14, 0x68, 0x52, 0x68, 0x09, 0x19, + 0x19, 0x60, 0x5a, 0x60, 0x0e, 0xe0, 0x8c, 0x42, 0x02, 0xd9, 0x0c, 0x23, + 0x03, 0x60, 0x09, 0xe0, 0x08, 0x68, 0x0c, 0x18, 0x94, 0x42, 0x03, 0xd1, + 0x14, 0x68, 0x52, 0x68, 0x00, 0x19, 0x08, 0x60, 0x4a, 0x60, 0x59, 0x60, + 0x30, 0xbd, 0xc0, 0x46, 0x18, 0x09, 0x00, 0x20, 0x70, 0xb5, 0x03, 0x23, + 0xcd, 0x1c, 0x9d, 0x43, 0x08, 0x35, 0x06, 0x1c, 0x0c, 0x2d, 0x01, 0xd2, + 0x0c, 0x25, 0x01, 0xe0, 0x00, 0x2d, 0x3f, 0xdb, 0x8d, 0x42, 0x3d, 0xd3, + 0x20, 0x4b, 0x1c, 0x68, 0x1a, 0x1c, 0x21, 0x1c, 0x00, 0x29, 0x13, 0xd0, + 0x08, 0x68, 0x43, 0x1b, 0x0d, 0xd4, 0x0b, 0x2b, 0x02, 0xd9, 0x0b, 0x60, + 0xcc, 0x18, 0x1e, 0xe0, 0x8c, 0x42, 0x02, 0xd1, 0x63, 0x68, 0x13, 0x60, + 0x1a, 0xe0, 0x48, 0x68, 0x60, 0x60, 0x0c, 0x1c, 0x16, 0xe0, 0x0c, 0x1c, + 0x49, 0x68, 0xe9, 0xe7, 0x14, 0x4c, 0x20, 0x68, 0x00, 0x28, 0x03, 0xd1, + 0x30, 0x1c, 0x00, 0xf0, 0x25, 0xf8, 0x20, 0x60, 0x30, 0x1c, 0x29, 0x1c, + 0x00, 0xf0, 0x20, 0xf8, 0x43, 0x1c, 0x15, 0xd0, 0xc4, 0x1c, 0x03, 0x23, + 0x9c, 0x43, 0x84, 0x42, 0x0a, 0xd1, 0x25, 0x60, 0x20, 0x1c, 0x0b, 0x30, + 0x07, 0x22, 0x23, 0x1d, 0x90, 0x43, 0xc3, 0x1a, 0x0b, 0xd0, 0x5a, 0x42, + 0xe2, 0x50, 0x08, 0xe0, 0x21, 0x1a, 0x30, 0x1c, 0x00, 0xf0, 0x0a, 0xf8, + 0x01, 0x30, 0xee, 0xd1, 0x0c, 0x23, 0x33, 0x60, 0x00, 0x20, 0x70, 0xbd, + 0x18, 0x09, 0x00, 0x20, 0x14, 0x09, 0x00, 0x20, 0x38, 0xb5, 0x07, 0x4c, + 0x00, 0x23, 0x05, 0x1c, 0x08, 0x1c, 0x23, 0x60, 0x00, 0xf0, 0x2a, 0xf8, + 0x43, 0x1c, 0x03, 0xd1, 0x23, 0x68, 0x00, 0x2b, 0x00, 0xd0, 0x2b, 0x60, + 0x38, 0xbd, 0xc0, 0x46, 0x20, 0x09, 0x00, 0x20, 0xc9, 0xb2, 0x03, 0x78, + 0x00, 0x2b, 0x03, 0xd0, 0x8b, 0x42, 0x04, 0xd0, 0x01, 0x30, 0xf8, 0xe7, + 0x00, 0x29, 0x00, 0xd0, 0x18, 0x1c, 0x70, 0x47, 0x30, 0xb5, 0x03, 0x1c, + 0x00, 0x2a, 0x07, 0xd0, 0x0c, 0x78, 0x01, 0x33, 0x5d, 0x1e, 0x01, 0x3a, + 0x2c, 0x70, 0x01, 0x31, 0x00, 0x2c, 0xf5, 0xd1, 0x9a, 0x18, 0x93, 0x42, + 0x03, 0xd0, 0x00, 0x21, 0x19, 0x70, 0x01, 0x33, 0xf9, 0xe7, 0x30, 0xbd, + 0x09, 0x4a, 0x13, 0x68, 0x00, 0x2b, 0x0c, 0xd0, 0x18, 0x18, 0x69, 0x46, + 0x88, 0x42, 0x02, 0xd8, 0x10, 0x60, 0x18, 0x1c, 0x70, 0x47, 0x05, 0x4b, + 0x0c, 0x22, 0x01, 0x20, 0x1a, 0x60, 0x40, 0x42, 0xf8, 0xe7, 0x03, 0x4b, + 0x13, 0x60, 0xef, 0xe7, 0x1c, 0x09, 0x00, 0x20, 0x20, 0x09, 0x00, 0x20, + 0x24, 0x09, 0x00, 0x20, 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, + 0x9e, 0x46, 0x70, 0x47, 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, + 0x9e, 0x46, 0x70, 0x47, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x2e, 0x42, + 0x49, 0x4e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x1f, 0x42, 0x00, 0x00, 0x33, 0x42, 0x00, 0x00, 0x19, 0x42, 0x00, 0x00, + 0x5d, 0x42, 0x00, 0x00, 0x61, 0x43, 0x00, 0x00, 0x8d, 0x42, 0x00, 0x00, + 0xa1, 0x42, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x2f, 0x00, 0x7c, 0x3c, + 0x3e, 0x5e, 0x2b, 0x3d, 0x3f, 0x2f, 0x5b, 0x5d, 0x3b, 0x2c, 0x2a, 0x22, + 0x5c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x01, 0x54, 0x00, 0x00, 0xc1, 0x60, 0x00, 0x00, + 0x19, 0x42, 0x00, 0x00, 0x1d, 0x42, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x10, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, + 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, + 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x0a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x00, + 0x01, 0x00, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x03, + 0x00, 0x03, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x03, + 0x01, 0x03, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x05, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x02, 0x00, + 0x02, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, + 0x05, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, + 0x03, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x01, + 0x00, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x01, + 0x01, 0x01, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x03, + 0x00, 0x03, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x02, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x03, + 0x01, 0x03, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x02, + 0x01, 0x02, 0x01, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x0c, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x0b, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x0a, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x08, 0x00, 0x01, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x03, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x05, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x05, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x0a, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x0b, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, + 0x0b, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x00, + 0xff, 0xff, 0x0d, 0x00, 0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, + 0x05, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x01, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x01, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x14, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x7d, 0x67, 0x00, 0x00, 0xc1, 0x60, 0x00, 0x00, 0xbf, 0x66, 0x00, 0x00, + 0x81, 0x66, 0x00, 0x00, 0x99, 0x66, 0x00, 0x00, 0x35, 0x68, 0x00, 0x00, + 0x59, 0x64, 0x00, 0x00, 0x49, 0x64, 0x00, 0x00, 0x81, 0x65, 0x00, 0x00, + 0x6f, 0x64, 0x00, 0x00, 0x45, 0x64, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, + 0x40, 0x42, 0x0f, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, + 0xdc, 0x76, 0x00, 0x00, 0xfc, 0x76, 0x00, 0x00, 0x1c, 0x77, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xd8, 0x76, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x20, + 0xdd, 0x40, 0x00, 0x00, 0x05, 0x42, 0x00, 0x00, 0xed, 0x46, 0x00, 0x00, + 0xa9, 0x4b, 0x00, 0x00, 0x55, 0x58, 0x00, 0x00, 0x85, 0x5a, 0x00, 0x00, + 0xdd, 0x5a, 0x00, 0x00, 0xb5, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 diff --git a/libraries/SDU/src/boot/zero.h b/libraries/SDU/src/boot/zero.h new file mode 100644 index 0000000..eb44fe2 --- /dev/null +++ b/libraries/SDU/src/boot/zero.h @@ -0,0 +1,1163 @@ + 0x00, 0x80, 0x00, 0x20, 0x89, 0x3b, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, + 0x71, 0x3b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, + 0xdd, 0x3b, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, + 0x71, 0x3b, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, + 0x71, 0x3b, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, 0x75, 0x3b, 0x00, 0x00, + 0x71, 0x3b, 0x00, 0x00, 0xbd, 0x3a, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, + 0x71, 0x3b, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, + 0xcd, 0x3a, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, + 0x71, 0x3b, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, + 0x71, 0x3b, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, + 0x71, 0x3b, 0x00, 0x00, 0x71, 0x3b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0xa0, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xdc, 0x55, 0x00, 0x00, 0x08, 0xb5, 0x08, 0x4b, 0x00, 0x2b, 0x03, 0xd0, + 0x07, 0x48, 0x08, 0x49, 0x00, 0xe0, 0x00, 0xbf, 0x07, 0x48, 0x03, 0x68, + 0x00, 0x2b, 0x03, 0xd0, 0x06, 0x4b, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, + 0x08, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x00, 0xdc, 0x55, 0x00, 0x00, + 0xa4, 0x00, 0x00, 0x20, 0x90, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xf0, 0xb5, 0x33, 0x4c, 0xa5, 0x44, 0x01, 0xf0, 0x3f, 0xfe, 0x02, 0xf0, + 0xd7, 0xfb, 0x01, 0x20, 0x01, 0xf0, 0x68, 0xfd, 0x2f, 0x4d, 0x04, 0x21, + 0x28, 0x1c, 0x00, 0xf0, 0xe7, 0xf9, 0x00, 0x28, 0x44, 0xd0, 0x2d, 0x4e, + 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0xbe, 0xfa, 0x00, 0x28, 0x3d, 0xd0, + 0x29, 0x1c, 0x01, 0xa8, 0x32, 0x1c, 0x01, 0x23, 0x00, 0xf0, 0x6e, 0xfa, + 0x01, 0xa8, 0x00, 0xf0, 0x00, 0xf9, 0x80, 0x21, 0x04, 0x1c, 0xc9, 0x01, + 0x88, 0x42, 0x2d, 0xd9, 0x01, 0xa8, 0x00, 0xf0, 0xe6, 0xf8, 0x22, 0x4a, + 0xc0, 0x21, 0xa7, 0x18, 0x21, 0x48, 0xc9, 0x01, 0x3a, 0x1c, 0x01, 0xf0, + 0xf5, 0xfb, 0xc0, 0x24, 0xe4, 0x01, 0x80, 0x22, 0x0a, 0xa9, 0x92, 0x00, + 0x01, 0xa8, 0x00, 0xf0, 0xcf, 0xf8, 0x80, 0x23, 0x21, 0x1c, 0x0a, 0xaa, + 0x9b, 0x00, 0x19, 0x48, 0x01, 0xf0, 0x8e, 0xfb, 0x80, 0x22, 0x92, 0x00, + 0xa3, 0x18, 0x17, 0x4a, 0xa4, 0x18, 0xbc, 0x42, 0x01, 0xd2, 0x1c, 0x1c, + 0xe9, 0xe7, 0x01, 0x24, 0x01, 0xa8, 0x00, 0xf0, 0xed, 0xf8, 0x00, 0x2c, + 0x06, 0xd0, 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0x8d, 0xfa, 0x01, 0xe0, + 0x00, 0x24, 0xf3, 0xe7, 0xc0, 0x23, 0xdb, 0x01, 0x1b, 0x68, 0x83, 0xf3, + 0x08, 0x88, 0x0c, 0x4b, 0xc0, 0x22, 0xd2, 0x01, 0x9a, 0x60, 0x0b, 0x4b, + 0x1b, 0x68, 0x18, 0x47, 0x00, 0x20, 0x8b, 0x23, 0x9b, 0x00, 0x9d, 0x44, + 0xf0, 0xbd, 0xc0, 0x46, 0xd4, 0xfd, 0xff, 0xff, 0xd4, 0x00, 0x00, 0x20, + 0x6c, 0x4b, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xbc, 0x00, 0x00, 0x20, + 0x00, 0xa2, 0xff, 0xff, 0x00, 0xed, 0x00, 0xe0, 0x04, 0x60, 0x00, 0x00, + 0x08, 0xb5, 0x00, 0x21, 0x02, 0x48, 0x0a, 0x1c, 0x01, 0xf0, 0x38, 0xfb, + 0x08, 0xbd, 0xc0, 0x46, 0xbc, 0x00, 0x00, 0x20, 0x00, 0x20, 0x70, 0x47, + 0x70, 0x47, 0x13, 0xb5, 0x02, 0x68, 0x6b, 0x46, 0xd9, 0x71, 0x07, 0x33, + 0x54, 0x68, 0x19, 0x1c, 0x01, 0x22, 0xa0, 0x47, 0x16, 0xbd, 0x38, 0xb5, + 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x25, 0xa8, 0x42, 0x02, 0xd1, 0x01, 0x23, + 0x63, 0x60, 0x0a, 0xe0, 0x45, 0x60, 0x92, 0xb2, 0x01, 0xf0, 0x04, 0xf8, + 0x23, 0x6a, 0x5b, 0x68, 0x00, 0x2b, 0x02, 0xd0, 0x01, 0x23, 0x63, 0x60, + 0x28, 0x1c, 0x38, 0xbd, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x01, 0xd0, + 0x00, 0xf0, 0x42, 0xfe, 0x08, 0xbd, 0x00, 0x00, 0x13, 0xb5, 0x6c, 0x46, + 0x07, 0x34, 0x21, 0x1c, 0x01, 0x22, 0x00, 0xf0, 0x5d, 0xfd, 0x01, 0x28, + 0x01, 0xd1, 0x20, 0x78, 0x00, 0xe0, 0x01, 0x48, 0x00, 0xb2, 0x16, 0xbd, + 0xff, 0xff, 0x00, 0x00, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x02, 0xd0, + 0xff, 0xf7, 0xea, 0xff, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x08, 0xbd, + 0x38, 0xb5, 0x05, 0x1c, 0x00, 0x6a, 0x00, 0x28, 0x0a, 0xd0, 0xff, 0xf7, + 0xdf, 0xff, 0x04, 0x1c, 0x63, 0x1c, 0x05, 0xd0, 0x28, 0x6a, 0x01, 0x69, + 0x01, 0x39, 0x00, 0xf0, 0xe5, 0xfd, 0x20, 0x1c, 0x38, 0xbd, 0x00, 0x00, + 0xf8, 0xb5, 0xfa, 0x23, 0x9b, 0x00, 0x83, 0x60, 0x0d, 0x4b, 0x00, 0x25, + 0x08, 0x33, 0x04, 0x1c, 0x45, 0x60, 0x03, 0x60, 0x28, 0x20, 0x0f, 0x1c, + 0x16, 0x1c, 0x02, 0xf0, 0x1d, 0xfb, 0x20, 0x62, 0xa8, 0x42, 0x0a, 0xd0, + 0x39, 0x1c, 0x28, 0x22, 0x02, 0xf0, 0x39, 0xfb, 0x20, 0x1c, 0x10, 0x30, + 0x31, 0x1c, 0x0c, 0x22, 0x02, 0xf0, 0xfe, 0xfb, 0x25, 0x77, 0x20, 0x1c, + 0xf8, 0xbd, 0xc0, 0x46, 0x78, 0x4b, 0x00, 0x00, 0xfa, 0x22, 0x92, 0x00, + 0x82, 0x60, 0x04, 0x4a, 0x00, 0x23, 0x08, 0x32, 0x43, 0x60, 0x02, 0x60, + 0x03, 0x62, 0x03, 0x74, 0x70, 0x47, 0xc0, 0x46, 0x78, 0x4b, 0x00, 0x00, + 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x01, 0xd0, 0x00, 0xf0, 0x02, 0xfd, + 0x08, 0xbd, 0x00, 0x6a, 0x08, 0xb5, 0x00, 0x28, 0x04, 0xd0, 0x00, 0xf0, + 0xa5, 0xfd, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x08, 0xbd, 0x03, 0x6a, + 0x00, 0x2b, 0x01, 0xd0, 0x18, 0x69, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, + 0x70, 0x47, 0x00, 0x6a, 0x00, 0x28, 0x00, 0xd0, 0xc0, 0x69, 0x70, 0x47, + 0x38, 0xb5, 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x28, 0x0b, 0xd0, 0x20, 0x1c, + 0xff, 0xf7, 0xf3, 0xff, 0x05, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0xe7, 0xff, + 0x02, 0x4b, 0x28, 0x1a, 0x98, 0x42, 0x00, 0xd9, 0x18, 0x1c, 0x38, 0xbd, + 0xff, 0x7f, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, 0x00, 0x6a, 0x00, 0x28, + 0x06, 0xd0, 0x00, 0xf0, 0xe7, 0xfd, 0x20, 0x6a, 0x02, 0xf0, 0xca, 0xfa, + 0x00, 0x23, 0x23, 0x62, 0x10, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x0a, 0x1c, + 0x0c, 0x49, 0x8a, 0xb0, 0x04, 0x1c, 0x00, 0x23, 0x00, 0x91, 0x69, 0x46, + 0x4b, 0x72, 0x01, 0x93, 0x21, 0x1c, 0x68, 0x46, 0x01, 0x23, 0x00, 0xf0, + 0x81, 0xfe, 0x04, 0x1c, 0x60, 0x1e, 0x84, 0x41, 0xe4, 0xb2, 0x00, 0x2c, + 0x02, 0xd0, 0x68, 0x46, 0x00, 0xf0, 0xc8, 0xfd, 0x20, 0x1c, 0x0a, 0xb0, + 0x10, 0xbd, 0xc0, 0x46, 0xc0, 0x4b, 0x00, 0x00, 0x08, 0xb5, 0x01, 0x23, + 0x00, 0x2a, 0x05, 0xd0, 0x00, 0xf0, 0x1a, 0xff, 0x03, 0x1c, 0x58, 0x1e, + 0x83, 0x41, 0xdb, 0xb2, 0x18, 0x1c, 0x08, 0xbd, 0x38, 0xb5, 0x01, 0x22, + 0x05, 0x1c, 0x0c, 0x1c, 0x01, 0xf0, 0x94, 0xf9, 0x02, 0x1c, 0x01, 0x20, + 0x00, 0x2a, 0x03, 0xd1, 0x28, 0x1c, 0x21, 0x1c, 0x01, 0xf0, 0x8c, 0xf9, + 0x38, 0xbd, 0xf0, 0xb5, 0x0c, 0x68, 0x03, 0x5d, 0x2f, 0x3b, 0x5d, 0x42, + 0x6b, 0x41, 0xe4, 0x18, 0x27, 0x1c, 0x0c, 0x37, 0x23, 0x1c, 0xc5, 0x5c, + 0x1e, 0x1b, 0x2f, 0x2d, 0x09, 0xd0, 0x00, 0x2d, 0x07, 0xd0, 0x01, 0x33, + 0x16, 0x1b, 0xf6, 0x18, 0x01, 0x3e, 0x35, 0x70, 0xbb, 0x42, 0xf2, 0xd1, + 0x0c, 0x26, 0x00, 0x24, 0x94, 0x55, 0xc2, 0x5c, 0x2f, 0x3a, 0x54, 0x42, + 0x62, 0x41, 0x9b, 0x18, 0x0b, 0x60, 0xc0, 0x5c, 0x43, 0x1e, 0x98, 0x41, + 0xc0, 0xb2, 0xf0, 0xbd, 0xf0, 0xb5, 0xa1, 0xb0, 0x03, 0x90, 0x25, 0x48, + 0x0d, 0x1c, 0x04, 0x92, 0x05, 0x93, 0x0c, 0xaa, 0x00, 0x23, 0x16, 0xa9, + 0x0d, 0x93, 0x0c, 0x90, 0x53, 0x72, 0x17, 0x93, 0x16, 0x90, 0x4b, 0x72, + 0x07, 0x93, 0x2c, 0x1c, 0x00, 0x92, 0x07, 0xa9, 0x08, 0xaa, 0x03, 0x98, + 0xff, 0xf7, 0xc3, 0xff, 0x01, 0x26, 0x02, 0x1c, 0x72, 0x40, 0x01, 0x90, + 0xd2, 0xb2, 0x20, 0x1c, 0x08, 0xa9, 0x05, 0x9b, 0x04, 0x9f, 0xb8, 0x47, + 0x00, 0x28, 0x07, 0xd1, 0xac, 0x42, 0x01, 0xd1, 0x00, 0x20, 0x23, 0xe0, + 0x20, 0x1c, 0x00, 0xf0, 0x57, 0xfd, 0xf9, 0xe7, 0x01, 0x9f, 0x00, 0x2f, + 0x11, 0xd0, 0x33, 0x1c, 0x00, 0x98, 0x21, 0x1c, 0x08, 0xaa, 0x00, 0xf0, + 0xfd, 0xfd, 0x06, 0x1c, 0xac, 0x42, 0x0f, 0xd0, 0x20, 0x1c, 0x00, 0xf0, + 0x47, 0xfd, 0x00, 0x2e, 0xe8, 0xd0, 0x23, 0x1c, 0x00, 0x9c, 0x00, 0x93, + 0xd1, 0xe7, 0xac, 0x42, 0x02, 0xd0, 0x20, 0x1c, 0x00, 0xf0, 0x3c, 0xfd, + 0x30, 0x1c, 0x03, 0xe0, 0x00, 0x28, 0xdb, 0xd0, 0x16, 0xac, 0xf0, 0xe7, + 0x21, 0xb0, 0xf0, 0xbd, 0xc0, 0x4b, 0x00, 0x00, 0x38, 0xb5, 0x03, 0x1c, + 0x41, 0x33, 0x1b, 0x78, 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x2b, 0x02, 0xd0, + 0x38, 0x30, 0x00, 0xf0, 0x27, 0xfd, 0x20, 0x1c, 0x01, 0x21, 0x2a, 0x1c, + 0x00, 0xf0, 0xc8, 0xf9, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x0f, 0xe0, + 0x25, 0x1c, 0x10, 0x35, 0x28, 0x1c, 0x21, 0x1c, 0xff, 0xf7, 0x62, 0xff, + 0x00, 0x28, 0xf5, 0xd0, 0x20, 0x1c, 0x38, 0x30, 0x29, 0x1c, 0x00, 0xf0, + 0xcf, 0xfb, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x38, 0xbd, 0x00, 0x00, + 0x4b, 0x68, 0x43, 0x60, 0x0a, 0x4b, 0x03, 0x60, 0x0b, 0x7a, 0x03, 0x72, + 0x4b, 0x7a, 0x43, 0x72, 0xcb, 0x68, 0xc3, 0x60, 0x0b, 0x69, 0x03, 0x61, + 0x4b, 0x69, 0x43, 0x61, 0x0b, 0x7e, 0x03, 0x76, 0xcb, 0x69, 0xc3, 0x61, + 0x0b, 0x6a, 0x49, 0x6a, 0x03, 0x62, 0x41, 0x62, 0x70, 0x47, 0xc0, 0x46, + 0xc0, 0x4b, 0x00, 0x00, 0xf0, 0xb5, 0x9d, 0xb0, 0x08, 0xae, 0x02, 0x92, + 0x03, 0x93, 0x27, 0x4a, 0x00, 0x23, 0x12, 0xaf, 0x05, 0x1c, 0x73, 0x60, + 0x7b, 0x60, 0x10, 0x31, 0x30, 0x1c, 0x08, 0x92, 0x73, 0x72, 0x12, 0x92, + 0x7b, 0x72, 0x00, 0xf0, 0x9d, 0xfb, 0x02, 0x9c, 0x20, 0x1c, 0x2f, 0x21, + 0x02, 0xf0, 0x98, 0xfa, 0x00, 0x28, 0x2e, 0xd0, 0x23, 0x78, 0x2f, 0x2b, + 0x01, 0xd1, 0x01, 0x34, 0xf4, 0xe7, 0x00, 0x1b, 0xc0, 0xb2, 0x03, 0x1c, + 0x0c, 0x28, 0x00, 0xd9, 0x0c, 0x23, 0xdb, 0xb2, 0x1a, 0x1c, 0x21, 0x1c, + 0x04, 0xa8, 0x01, 0x93, 0x02, 0xf0, 0x90, 0xfa, 0x01, 0x9a, 0x00, 0x23, + 0x04, 0xa9, 0x38, 0x1c, 0x8b, 0x54, 0x00, 0xf0, 0xbf, 0xfc, 0x38, 0x1c, + 0x31, 0x1c, 0x04, 0xaa, 0x01, 0x23, 0x00, 0xf0, 0x69, 0xfd, 0x00, 0x28, + 0x04, 0xd1, 0x0c, 0x4b, 0x68, 0x60, 0x2b, 0x60, 0x68, 0x72, 0x10, 0xe0, + 0x01, 0x9b, 0x30, 0x1c, 0xe4, 0x18, 0x00, 0xf0, 0xad, 0xfc, 0x33, 0x1c, + 0x3e, 0x1c, 0x1f, 0x1c, 0xca, 0xe7, 0x02, 0x99, 0x03, 0x9a, 0x64, 0x1a, + 0x14, 0x60, 0x28, 0x1c, 0x31, 0x1c, 0xff, 0xf7, 0x95, 0xff, 0x28, 0x1c, + 0x1d, 0xb0, 0xf0, 0xbd, 0xc0, 0x4b, 0x00, 0x00, 0xf0, 0xb5, 0xa1, 0xb0, + 0x05, 0x1c, 0x1f, 0x1c, 0x02, 0xa8, 0x01, 0xab, 0x16, 0x1c, 0xff, 0xf7, + 0xa1, 0xff, 0x01, 0x9b, 0xf6, 0x18, 0x33, 0x78, 0x00, 0x2b, 0x07, 0xd1, + 0x02, 0xa9, 0x16, 0xa8, 0xff, 0xf7, 0x7e, 0xff, 0x28, 0x1c, 0x16, 0xa9, + 0x17, 0x4a, 0x28, 0xe0, 0x00, 0x23, 0x0c, 0xac, 0x63, 0x60, 0x63, 0x72, + 0x6b, 0x46, 0x11, 0x33, 0x14, 0x4a, 0x1b, 0x78, 0x0c, 0x92, 0x00, 0x2b, + 0x03, 0xd1, 0x28, 0x1c, 0xff, 0xf7, 0x4a, 0xfe, 0x1b, 0xe0, 0x20, 0x1c, + 0x02, 0xa9, 0x32, 0x1c, 0x3b, 0x1c, 0x00, 0xf0, 0x21, 0xfd, 0x00, 0x28, + 0xf3, 0xd0, 0x02, 0xa8, 0x00, 0xf0, 0x6c, 0xfc, 0x06, 0x23, 0x1f, 0x40, + 0x9f, 0x42, 0x03, 0xd1, 0x20, 0x1c, 0x13, 0x99, 0x00, 0xf0, 0xf6, 0xfb, + 0x21, 0x1c, 0x16, 0xa8, 0xff, 0xf7, 0x54, 0xff, 0x28, 0x1c, 0x16, 0xa9, + 0x32, 0x1c, 0xff, 0xf7, 0x0b, 0xfe, 0x28, 0x1c, 0x21, 0xb0, 0xf0, 0xbd, + 0xa0, 0x4b, 0x00, 0x00, 0xc0, 0x4b, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x1c, + 0x08, 0x1c, 0x19, 0x1c, 0x38, 0x31, 0x02, 0x4a, 0x00, 0x23, 0xff, 0xf7, + 0xc9, 0xfe, 0x08, 0xbd, 0xa5, 0x23, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x1c, + 0x08, 0x1c, 0x19, 0x1c, 0x38, 0x31, 0x02, 0x4a, 0x00, 0x23, 0xff, 0xf7, + 0xbd, 0xfe, 0x08, 0xbd, 0xe1, 0x23, 0x00, 0x00, 0x08, 0x4b, 0x02, 0x21, + 0x19, 0x61, 0x19, 0x1c, 0x00, 0x22, 0x30, 0x31, 0x0a, 0x70, 0x06, 0x49, + 0x5a, 0x71, 0x9a, 0x71, 0x9a, 0x72, 0x1a, 0x73, 0xda, 0x63, 0x99, 0x63, + 0x41, 0x33, 0x1a, 0x70, 0x70, 0x47, 0xc0, 0x46, 0xd4, 0x00, 0x00, 0x20, + 0xc0, 0x4b, 0x00, 0x00, 0x08, 0xb5, 0x01, 0x1c, 0x01, 0x48, 0x01, 0xf0, + 0xab, 0xf9, 0x08, 0xbd, 0x78, 0x07, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, + 0xff, 0x21, 0x01, 0xf0, 0xa3, 0xf9, 0x08, 0xbd, 0x78, 0x07, 0x00, 0x20, + 0x08, 0xb5, 0x01, 0x21, 0x00, 0x79, 0x01, 0xf0, 0x2d, 0xfc, 0x05, 0x4b, + 0x1a, 0x78, 0x00, 0x2a, 0x04, 0xd0, 0x00, 0x22, 0x03, 0x48, 0x1a, 0x70, + 0x01, 0xf0, 0x80, 0xf9, 0x08, 0xbd, 0xc0, 0x46, 0x40, 0x01, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x10, 0xb5, 0x08, 0x4b, 0x04, 0x1c, 0x1a, 0x78, + 0x00, 0x2a, 0x06, 0xd1, 0x01, 0x22, 0x1a, 0x70, 0x05, 0x4b, 0x06, 0x48, + 0x06, 0xcb, 0x01, 0xf0, 0x51, 0xf9, 0x20, 0x79, 0x00, 0x21, 0x01, 0xf0, + 0x0d, 0xfc, 0x10, 0xbd, 0x40, 0x01, 0x00, 0x20, 0x38, 0x01, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x10, 0xb5, 0x83, 0x79, 0x04, 0x1c, 0x00, 0x2b, + 0x0d, 0xd0, 0x23, 0x89, 0x5a, 0x1c, 0x22, 0x81, 0x05, 0x4a, 0x93, 0x42, + 0x02, 0xd8, 0xff, 0xf7, 0xbf, 0xff, 0xf6, 0xe7, 0x20, 0x1c, 0xff, 0xf7, + 0xc3, 0xff, 0x00, 0x23, 0xa3, 0x71, 0x10, 0xbd, 0x01, 0x02, 0x00, 0x00, + 0x00, 0xb5, 0x06, 0x29, 0x03, 0xd9, 0x16, 0x23, 0x43, 0x71, 0x00, 0x20, + 0x1c, 0xe0, 0x0f, 0x4b, 0x05, 0x29, 0x13, 0xd8, 0x08, 0x1c, 0x00, 0x22, + 0x02, 0xf0, 0x22, 0xf8, 0x03, 0x05, 0x07, 0x09, 0x0b, 0x0d, 0x0b, 0x49, + 0x08, 0xe0, 0x0b, 0x49, 0x06, 0xe0, 0x0b, 0x49, 0x04, 0xe0, 0x0b, 0x49, + 0x02, 0xe0, 0x0b, 0x49, 0x00, 0xe0, 0x0b, 0x49, 0x19, 0x60, 0x02, 0xe0, + 0x0a, 0x4a, 0x1a, 0x60, 0x00, 0x22, 0x1a, 0x71, 0x5a, 0x71, 0x01, 0x20, + 0x00, 0xbd, 0xc0, 0x46, 0x38, 0x01, 0x00, 0x20, 0x00, 0x1b, 0xb7, 0x00, + 0x00, 0x09, 0x3d, 0x00, 0x80, 0x84, 0x1e, 0x00, 0x40, 0x42, 0x0f, 0x00, + 0x20, 0xa1, 0x07, 0x00, 0x90, 0xd0, 0x03, 0x00, 0x48, 0xe8, 0x01, 0x00, + 0x38, 0xb5, 0x0c, 0x1c, 0x01, 0xf0, 0xde, 0xf9, 0x05, 0x1c, 0xff, 0xf7, + 0x79, 0xff, 0xff, 0x28, 0x06, 0xd0, 0x01, 0xf0, 0xd7, 0xf9, 0x40, 0x1b, + 0xa0, 0x42, 0xf6, 0xd3, 0x00, 0x20, 0x00, 0xe0, 0x01, 0x20, 0x38, 0xbd, + 0xf8, 0xb5, 0x04, 0x1c, 0x0e, 0x1c, 0x17, 0x1c, 0xff, 0xf7, 0x9c, 0xff, + 0x20, 0x1c, 0xff, 0xf7, 0x81, 0xff, 0x96, 0x21, 0x49, 0x00, 0x20, 0x1c, + 0xff, 0xf7, 0xe0, 0xff, 0x40, 0x20, 0x30, 0x43, 0xff, 0xf7, 0x54, 0xff, + 0x18, 0x25, 0x38, 0x1c, 0xe8, 0x40, 0xc0, 0xb2, 0x08, 0x3d, 0xff, 0xf7, + 0x4d, 0xff, 0x2b, 0x1c, 0x08, 0x33, 0xf6, 0xd1, 0x95, 0x20, 0x00, 0x2e, + 0x03, 0xd0, 0x87, 0x20, 0x08, 0x2e, 0x00, 0xd0, 0xff, 0x20, 0xff, 0xf7, + 0x41, 0xff, 0x00, 0x25, 0xff, 0xf7, 0x46, 0xff, 0x43, 0xb2, 0xe0, 0x72, + 0x00, 0x2b, 0x04, 0xda, 0xff, 0x2d, 0x02, 0xd0, 0x01, 0x35, 0xed, 0xb2, + 0xf4, 0xe7, 0xf8, 0xbd, 0xf7, 0xb5, 0x00, 0x25, 0x02, 0x71, 0x05, 0x73, + 0x85, 0x72, 0x85, 0x71, 0x45, 0x71, 0x04, 0x1c, 0x01, 0x91, 0x01, 0xf0, + 0x93, 0xf9, 0x01, 0x21, 0x07, 0x1c, 0x20, 0x79, 0x01, 0xf0, 0x0c, 0xfb, + 0x01, 0x21, 0x20, 0x79, 0x01, 0xf0, 0x62, 0xfb, 0x42, 0x4e, 0x30, 0x1c, + 0x01, 0xf0, 0x76, 0xf8, 0x41, 0x4b, 0x42, 0x49, 0x1d, 0x71, 0x5d, 0x71, + 0x19, 0x60, 0x30, 0x1c, 0x5a, 0x68, 0x01, 0xf0, 0x95, 0xf8, 0x0a, 0x25, + 0x01, 0x3d, 0xff, 0x20, 0xed, 0xb2, 0xff, 0xf7, 0x0d, 0xff, 0x00, 0x2d, + 0xf8, 0xd1, 0x30, 0x1c, 0x01, 0xf0, 0xa6, 0xf8, 0x20, 0x1c, 0xff, 0xf7, + 0x29, 0xff, 0x00, 0x21, 0x20, 0x1c, 0x0a, 0x1c, 0xff, 0xf7, 0x9a, 0xff, + 0x06, 0x1c, 0xe0, 0x72, 0x01, 0x28, 0x08, 0xd0, 0x01, 0xf0, 0x64, 0xf9, + 0xfa, 0x23, 0xc0, 0x1b, 0xdb, 0x00, 0x98, 0x42, 0xef, 0xd9, 0x01, 0x23, + 0x3b, 0xe0, 0xd5, 0x22, 0x20, 0x1c, 0x08, 0x21, 0x52, 0x00, 0xff, 0xf7, + 0x87, 0xff, 0x04, 0x23, 0x18, 0x42, 0x01, 0xd0, 0x26, 0x73, 0x0b, 0xe0, + 0x1e, 0x1c, 0xff, 0xf7, 0xed, 0xfe, 0x01, 0x3e, 0xf6, 0xb2, 0xe0, 0x72, + 0x00, 0x2e, 0xf8, 0xd1, 0x02, 0x23, 0xaa, 0x28, 0x25, 0xd1, 0x23, 0x73, + 0x26, 0x7b, 0x02, 0x3e, 0x73, 0x42, 0x5e, 0x41, 0xb6, 0x07, 0x37, 0x21, + 0x00, 0x22, 0x20, 0x1c, 0xff, 0xf7, 0x6c, 0xff, 0x32, 0x1c, 0x20, 0x1c, + 0x29, 0x21, 0xff, 0xf7, 0x67, 0xff, 0x02, 0x1c, 0xe0, 0x72, 0x08, 0xd0, + 0x01, 0xf0, 0x32, 0xf9, 0xfa, 0x23, 0xc0, 0x1b, 0xdb, 0x00, 0x98, 0x42, + 0xeb, 0xd9, 0x08, 0x23, 0x09, 0xe0, 0x23, 0x7b, 0x02, 0x2b, 0x19, 0xd1, + 0x20, 0x1c, 0x3a, 0x21, 0xff, 0xf7, 0x54, 0xff, 0x00, 0x28, 0x05, 0xd0, + 0x06, 0x23, 0x63, 0x71, 0x20, 0x1c, 0xff, 0xf7, 0xc3, 0xfe, 0x15, 0xe0, + 0xff, 0xf7, 0xb8, 0xfe, 0xc0, 0x23, 0x18, 0x40, 0x98, 0x42, 0x01, 0xd1, + 0x03, 0x23, 0x23, 0x73, 0xff, 0xf7, 0xb0, 0xfe, 0xff, 0xf7, 0xae, 0xfe, + 0xff, 0xf7, 0xac, 0xfe, 0x20, 0x1c, 0xff, 0xf7, 0xb1, 0xfe, 0x20, 0x1c, + 0x01, 0x99, 0xff, 0xf7, 0xef, 0xfe, 0x05, 0x1c, 0x28, 0x1c, 0xfe, 0xbd, + 0x78, 0x07, 0x00, 0x20, 0x38, 0x01, 0x00, 0x20, 0x90, 0xd0, 0x03, 0x00, + 0x38, 0xb5, 0x04, 0x1c, 0x01, 0xf0, 0xfa, 0xf8, 0x05, 0x1c, 0xff, 0xf7, + 0x95, 0xfe, 0xe0, 0x72, 0xff, 0x28, 0x08, 0xd1, 0x01, 0xf0, 0xf2, 0xf8, + 0x96, 0x23, 0x40, 0x1b, 0x5b, 0x00, 0x98, 0x42, 0xf3, 0xd9, 0x0f, 0x23, + 0x02, 0xe0, 0xfe, 0x28, 0x06, 0xd0, 0x0d, 0x23, 0x20, 0x1c, 0x63, 0x71, + 0xff, 0xf7, 0x8a, 0xfe, 0x00, 0x20, 0x00, 0xe0, 0x01, 0x20, 0x38, 0xbd, + 0xf8, 0xb5, 0x04, 0x1c, 0x0f, 0x1c, 0x15, 0x1c, 0x1e, 0x1e, 0x45, 0xd0, + 0x9a, 0x18, 0x80, 0x23, 0x9b, 0x00, 0x9a, 0x42, 0x42, 0xdc, 0x83, 0x79, + 0x00, 0x2b, 0x05, 0xd0, 0x02, 0x68, 0x91, 0x42, 0x02, 0xd1, 0x03, 0x89, + 0xab, 0x42, 0x16, 0xd9, 0x23, 0x7b, 0x27, 0x60, 0x03, 0x2b, 0x00, 0xd0, + 0x7f, 0x02, 0x3a, 0x1c, 0x20, 0x1c, 0x11, 0x21, 0xff, 0xf7, 0xf2, 0xfe, + 0x07, 0x1e, 0x02, 0xd0, 0x03, 0x23, 0x63, 0x71, 0x2a, 0xe0, 0x20, 0x1c, + 0xff, 0xf7, 0xbc, 0xff, 0x00, 0x28, 0x25, 0xd0, 0x01, 0x23, 0x27, 0x81, + 0xa3, 0x71, 0x23, 0x89, 0xab, 0x42, 0x05, 0xd2, 0xff, 0xf7, 0x4e, 0xfe, + 0x23, 0x89, 0x01, 0x33, 0x23, 0x81, 0xf6, 0xe7, 0x06, 0x9d, 0x06, 0x9a, + 0xab, 0x1a, 0x9b, 0xb2, 0xb3, 0x42, 0x04, 0xd2, 0xff, 0xf7, 0x42, 0xfe, + 0x28, 0x70, 0x01, 0x35, 0xf5, 0xe7, 0x23, 0x89, 0xa2, 0x7a, 0xf3, 0x18, + 0x9b, 0xb2, 0x23, 0x81, 0x00, 0x2a, 0x02, 0xd0, 0x06, 0x4a, 0x93, 0x42, + 0x02, 0xd9, 0x20, 0x1c, 0xff, 0xf7, 0x66, 0xfe, 0x01, 0x20, 0x03, 0xe0, + 0x20, 0x1c, 0xff, 0xf7, 0x35, 0xfe, 0x00, 0x20, 0xf8, 0xbd, 0xc0, 0x46, + 0xff, 0x01, 0x00, 0x00, 0x07, 0xb5, 0x80, 0x23, 0x00, 0x92, 0x9b, 0x00, + 0x00, 0x22, 0xff, 0xf7, 0xa3, 0xff, 0x0e, 0xbd, 0x70, 0xb5, 0x05, 0x1c, + 0x08, 0x1c, 0x16, 0x1c, 0xff, 0xf7, 0x12, 0xfe, 0x00, 0x24, 0x30, 0x5d, + 0xff, 0xf7, 0x0e, 0xfe, 0x01, 0x34, 0x80, 0x23, 0x9b, 0x00, 0x9c, 0x42, + 0xf7, 0xd1, 0xff, 0x20, 0xff, 0xf7, 0x06, 0xfe, 0xff, 0x20, 0xff, 0xf7, + 0x03, 0xfe, 0xff, 0xf7, 0x09, 0xfe, 0x1f, 0x23, 0xe8, 0x72, 0x03, 0x40, + 0x01, 0x20, 0x05, 0x2b, 0x05, 0xd0, 0x11, 0x23, 0x28, 0x1c, 0x6b, 0x71, + 0xff, 0xf7, 0x06, 0xfe, 0x00, 0x20, 0x70, 0xbd, 0x70, 0xb5, 0x0b, 0x1c, + 0x04, 0x1c, 0x16, 0x1c, 0x00, 0x29, 0x01, 0xd1, 0x12, 0x23, 0x28, 0xe0, + 0x02, 0x7b, 0x03, 0x2a, 0x00, 0xd0, 0x4b, 0x02, 0x20, 0x1c, 0x18, 0x21, + 0x1a, 0x1c, 0xff, 0xf7, 0x7d, 0xfe, 0x05, 0x1e, 0x01, 0xd0, 0x04, 0x23, + 0x1b, 0xe0, 0x20, 0x1c, 0xfe, 0x21, 0x32, 0x1c, 0xff, 0xf7, 0xc2, 0xff, + 0x00, 0x28, 0x15, 0xd0, 0x96, 0x21, 0x20, 0x1c, 0x89, 0x00, 0xff, 0xf7, + 0x5b, 0xfe, 0x00, 0x28, 0x01, 0xd1, 0x15, 0x23, 0x0b, 0xe0, 0x20, 0x1c, + 0x0d, 0x21, 0x2a, 0x1c, 0xff, 0xf7, 0x64, 0xfe, 0x00, 0x28, 0x03, 0xd1, + 0xff, 0xf7, 0xce, 0xfd, 0x00, 0x28, 0x06, 0xd0, 0x14, 0x23, 0x63, 0x71, + 0x20, 0x1c, 0xff, 0xf7, 0xcf, 0xfd, 0x00, 0x20, 0x03, 0xe0, 0x20, 0x1c, + 0xff, 0xf7, 0xca, 0xfd, 0x01, 0x20, 0x70, 0xbd, 0x03, 0x4b, 0x04, 0x4a, + 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x70, 0x47, 0xc0, 0x46, + 0x38, 0x01, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, 0x02, 0x1c, 0x10, 0xb5, + 0x0c, 0x32, 0x04, 0x1c, 0x01, 0x21, 0x40, 0x6a, 0x00, 0xf0, 0x24, 0xfd, + 0x00, 0x28, 0x0a, 0xd0, 0x23, 0x6a, 0x01, 0x20, 0x00, 0x2b, 0x06, 0xd1, + 0xe3, 0x68, 0x22, 0x7a, 0x23, 0x62, 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, + 0x23, 0x72, 0x10, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xe6, 0xff, + 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x1b, 0xe0, 0x63, 0x6a, 0xe6, 0x68, + 0x1a, 0x7c, 0x02, 0x3e, 0x96, 0x40, 0x5a, 0x69, 0x1d, 0x79, 0xb6, 0x18, + 0x00, 0x2d, 0x08, 0xd0, 0x70, 0x1e, 0x40, 0x19, 0x00, 0xf0, 0x4c, 0xfc, + 0x00, 0x28, 0xed, 0xd0, 0x01, 0x3d, 0xed, 0xb2, 0xf4, 0xe7, 0x63, 0x6a, + 0x01, 0x20, 0x1a, 0x7c, 0x80, 0x23, 0x9b, 0x00, 0x93, 0x40, 0xe2, 0x69, + 0xd3, 0x18, 0xe3, 0x61, 0x70, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, + 0x40, 0x69, 0x00, 0xf0, 0x13, 0xfc, 0x00, 0x28, 0x03, 0xd0, 0x20, 0x7e, + 0x01, 0x4b, 0x40, 0x01, 0xc0, 0x18, 0x10, 0xbd, 0x50, 0x01, 0x00, 0x20, + 0xf0, 0xb5, 0x00, 0x23, 0x87, 0xb0, 0x07, 0x1c, 0x0e, 0x1c, 0x20, 0x22, + 0xf2, 0x54, 0x01, 0x33, 0x0b, 0x2b, 0xfa, 0xd1, 0x07, 0x21, 0x00, 0x25, + 0x01, 0x91, 0x3c, 0x78, 0x00, 0x2c, 0x2a, 0xd0, 0x2e, 0x2c, 0x06, 0xd1, + 0x01, 0x9b, 0x0a, 0x2b, 0x2b, 0xd0, 0x0a, 0x21, 0x08, 0x25, 0x01, 0x91, + 0x1f, 0xe0, 0x02, 0xa8, 0x14, 0x49, 0x10, 0x22, 0x01, 0xf0, 0x69, 0xfe, + 0x00, 0x23, 0x02, 0xa9, 0xca, 0x5c, 0x00, 0x2a, 0x03, 0xd0, 0x01, 0x33, + 0xa2, 0x42, 0xf8, 0xd1, 0x19, 0xe0, 0x01, 0x9b, 0x9d, 0x42, 0x16, 0xd8, + 0x23, 0x1c, 0x21, 0x3b, 0x5d, 0x2b, 0x12, 0xd8, 0x22, 0x1c, 0x6b, 0x1c, + 0x61, 0x3a, 0xdb, 0xb2, 0x75, 0x19, 0x19, 0x2a, 0x01, 0xd8, 0x20, 0x3c, + 0xe4, 0xb2, 0x2c, 0x70, 0x1d, 0x1c, 0x01, 0x37, 0xd1, 0xe7, 0x30, 0x78, + 0x20, 0x38, 0x43, 0x1e, 0x98, 0x41, 0xc0, 0xb2, 0x00, 0xe0, 0x00, 0x20, + 0x07, 0xb0, 0xf0, 0xbd, 0xa2, 0x4b, 0x00, 0x00, 0x38, 0xb5, 0x42, 0x7a, + 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x2a, 0x01, 0xd0, 0x00, 0x20, 0x1f, 0xe0, + 0x4b, 0x1c, 0xdb, 0x7f, 0x10, 0x2b, 0x06, 0xd1, 0x02, 0x23, 0x43, 0x72, + 0x02, 0x62, 0x4b, 0x8c, 0x5b, 0x01, 0xc3, 0x61, 0x0c, 0xe0, 0x20, 0x2b, + 0xf0, 0xd1, 0x03, 0x23, 0x43, 0x72, 0x49, 0x6a, 0x22, 0x1c, 0x01, 0x62, + 0x1c, 0x32, 0x28, 0x1c, 0x00, 0xf0, 0x18, 0xfc, 0x00, 0x28, 0xe5, 0xd0, + 0x00, 0x23, 0x01, 0x20, 0x65, 0x62, 0x20, 0x72, 0xe3, 0x60, 0x23, 0x61, + 0x63, 0x61, 0x23, 0x76, 0x38, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x43, 0x7a, + 0x85, 0xb0, 0x04, 0x1c, 0x0e, 0x1c, 0x03, 0x92, 0x00, 0x2b, 0x01, 0xd1, + 0x3a, 0x48, 0x11, 0xe0, 0x03, 0x7a, 0xd8, 0x07, 0xfa, 0xd5, 0xe2, 0x69, + 0x20, 0x69, 0x03, 0x99, 0x13, 0x1a, 0x99, 0x42, 0x01, 0xd9, 0x9b, 0xb2, + 0x03, 0x93, 0x03, 0x99, 0x02, 0x91, 0x02, 0x9b, 0x00, 0x2b, 0x04, 0xd1, + 0x03, 0x99, 0x88, 0xb2, 0x00, 0xb2, 0x05, 0xb0, 0xf0, 0xbd, 0x23, 0x69, + 0x61, 0x7a, 0xdf, 0x05, 0xff, 0x0d, 0x5a, 0x0a, 0x60, 0x6a, 0x02, 0x29, + 0x02, 0xd1, 0x41, 0x6a, 0x51, 0x18, 0x1b, 0xe0, 0x05, 0x79, 0x01, 0x3d, + 0x2a, 0x40, 0xd5, 0xb2, 0x00, 0x2f, 0x0d, 0xd1, 0x00, 0x2d, 0x0b, 0xd1, + 0x00, 0x2b, 0x02, 0xd1, 0x22, 0x6a, 0xe2, 0x60, 0x06, 0xe0, 0x22, 0x1c, + 0xe1, 0x68, 0x0c, 0x32, 0x00, 0xf0, 0xa0, 0xfb, 0x00, 0x28, 0xc9, 0xd0, + 0x63, 0x6a, 0xe1, 0x68, 0x1a, 0x7c, 0x02, 0x39, 0x5b, 0x69, 0x91, 0x40, + 0xc9, 0x18, 0x49, 0x19, 0x80, 0x22, 0x02, 0x9d, 0x92, 0x00, 0xd3, 0x1b, + 0x9d, 0x42, 0x00, 0xdd, 0x9d, 0xb2, 0x23, 0x7a, 0x58, 0x06, 0x01, 0xd4, + 0x95, 0x42, 0x18, 0xd1, 0x16, 0x4b, 0x1b, 0x68, 0x99, 0x42, 0x14, 0xd0, + 0x15, 0x4b, 0x3a, 0x1c, 0x18, 0x68, 0x00, 0x96, 0x2b, 0x1c, 0xff, 0xf7, + 0x1f, 0xfe, 0x00, 0x28, 0xa8, 0xd0, 0x76, 0x19, 0x01, 0xe0, 0xdf, 0x1b, + 0xf6, 0x19, 0x21, 0x69, 0x02, 0x9a, 0x4b, 0x19, 0x55, 0x1b, 0xad, 0xb2, + 0x23, 0x61, 0x02, 0x95, 0xab, 0xe7, 0x08, 0x1c, 0x00, 0x21, 0x00, 0xf0, + 0x2b, 0xfb, 0x00, 0x28, 0x96, 0xd0, 0x09, 0x4b, 0x32, 0x1c, 0xff, 0x18, + 0x79, 0x19, 0x3b, 0x1c, 0x8b, 0x42, 0xe8, 0xd0, 0x18, 0x78, 0x01, 0x33, + 0x10, 0x70, 0x01, 0x32, 0xf8, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x73, 0xb5, 0x43, 0x7a, 0x04, 0x1c, 0x01, 0x2b, 0x01, 0xd8, 0x00, 0x20, + 0x16, 0xe0, 0x03, 0x69, 0x6d, 0x46, 0x07, 0x35, 0xde, 0x05, 0x29, 0x1c, + 0x01, 0x22, 0x36, 0x0f, 0xff, 0xf7, 0x6a, 0xff, 0x01, 0x28, 0x01, 0xd1, + 0x2b, 0x78, 0x00, 0xe0, 0x05, 0x4b, 0x1b, 0xb2, 0x01, 0x33, 0xec, 0xd0, + 0x23, 0x69, 0x70, 0x01, 0x1f, 0x33, 0x23, 0x61, 0x02, 0x4b, 0xc0, 0x18, + 0x76, 0xbd, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0x50, 0x01, 0x00, 0x20, + 0x70, 0xb5, 0x04, 0x1c, 0x40, 0x7a, 0x0d, 0x1c, 0x00, 0x28, 0x2a, 0xd0, + 0xe2, 0x69, 0x91, 0x42, 0x01, 0xd9, 0x00, 0x20, 0x25, 0xe0, 0x02, 0x28, + 0x21, 0xd0, 0x00, 0x2d, 0x01, 0xd1, 0xe5, 0x60, 0x1d, 0xe0, 0x62, 0x6a, + 0x21, 0x69, 0x13, 0x7c, 0x68, 0x1e, 0x09, 0x33, 0x4a, 0x1e, 0xd8, 0x40, + 0xda, 0x40, 0x03, 0x1e, 0x93, 0x42, 0x01, 0xd3, 0x00, 0x29, 0x02, 0xd1, + 0x22, 0x6a, 0xe2, 0x60, 0x00, 0xe0, 0x83, 0x1a, 0x1e, 0x1c, 0x00, 0x2e, + 0x09, 0xd0, 0x22, 0x1c, 0x60, 0x6a, 0xe1, 0x68, 0x0c, 0x32, 0x00, 0xf0, + 0x07, 0xfb, 0x01, 0x3e, 0x00, 0x28, 0xf4, 0xd1, 0x01, 0xe0, 0x25, 0x61, + 0x01, 0x20, 0x70, 0xbd, 0x38, 0xb5, 0x05, 0x1c, 0x40, 0x7a, 0x00, 0x28, + 0x33, 0xd0, 0x2b, 0x7a, 0x7f, 0x2b, 0x2d, 0xd9, 0x28, 0x1c, 0x01, 0x21, + 0xff, 0xf7, 0x9a, 0xfe, 0x04, 0x1e, 0x2a, 0xd0, 0x6b, 0x7a, 0x01, 0x2b, + 0x07, 0xd8, 0x2b, 0x7f, 0x03, 0x77, 0x6b, 0x7f, 0x43, 0x77, 0xab, 0x7f, + 0x83, 0x77, 0xeb, 0x7f, 0xc3, 0x77, 0x2b, 0x6a, 0x9a, 0xb2, 0x1b, 0x0c, + 0x23, 0x75, 0x1b, 0x0a, 0x63, 0x75, 0x0d, 0x4b, 0xa2, 0x76, 0x1b, 0x68, + 0x12, 0x0a, 0xe2, 0x76, 0x00, 0x2b, 0x0b, 0xd0, 0x20, 0x1c, 0x21, 0x1c, + 0x18, 0x30, 0x16, 0x31, 0x98, 0x47, 0x63, 0x7e, 0x22, 0x7e, 0x1b, 0x02, + 0x13, 0x43, 0xa3, 0x74, 0x1b, 0x0a, 0xe3, 0x74, 0x2a, 0x7a, 0x7f, 0x23, + 0x13, 0x40, 0x2b, 0x72, 0x00, 0xf0, 0x5c, 0xfa, 0xff, 0xe7, 0x38, 0xbd, + 0x44, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xc0, 0xff, + 0x00, 0x28, 0x02, 0xd0, 0x00, 0x23, 0x63, 0x72, 0x01, 0x20, 0x10, 0xbd, + 0x73, 0xb5, 0x42, 0x7a, 0x04, 0x1c, 0x0d, 0x1c, 0x00, 0x20, 0x01, 0x2a, + 0x4b, 0xd1, 0x20, 0x7a, 0x02, 0x23, 0x18, 0x40, 0x47, 0xd0, 0xe3, 0x69, + 0x00, 0x20, 0x99, 0x42, 0x43, 0xd8, 0x10, 0x1c, 0x00, 0x2b, 0x40, 0xd0, + 0x20, 0x1c, 0x29, 0x1c, 0x26, 0x69, 0xff, 0xf7, 0x71, 0xff, 0x00, 0x28, + 0x25, 0xd0, 0x60, 0x6a, 0x00, 0x2d, 0x06, 0xd1, 0x21, 0x6a, 0x00, 0xf0, + 0x95, 0xfb, 0x00, 0x28, 0x1d, 0xd0, 0x25, 0x62, 0x1d, 0xe0, 0xe1, 0x68, + 0x01, 0xaa, 0x00, 0xf0, 0x93, 0xfa, 0x00, 0x28, 0x15, 0xd0, 0x60, 0x6a, + 0x01, 0x99, 0x43, 0x1c, 0xdb, 0x7f, 0x10, 0x2b, 0x01, 0xd1, 0x12, 0x4b, + 0x00, 0xe0, 0x12, 0x4b, 0x99, 0x42, 0x0c, 0xd2, 0x00, 0xf0, 0x7e, 0xfb, + 0x00, 0x28, 0x06, 0xd0, 0x60, 0x6a, 0xe1, 0x68, 0x0e, 0x4a, 0x00, 0xf0, + 0xcf, 0xfa, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x11, 0xe0, 0x22, 0x7a, + 0x80, 0x23, 0x5b, 0x42, 0x13, 0x43, 0xe5, 0x61, 0x23, 0x72, 0x20, 0x1c, + 0xff, 0xf7, 0x70, 0xff, 0x00, 0x28, 0xf2, 0xd0, 0x29, 0x1e, 0xb1, 0x42, + 0x00, 0xd9, 0x31, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x35, 0xff, 0x76, 0xbd, + 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, 0xff, 0xff, 0xff, 0x0f, + 0x38, 0xb5, 0x23, 0x4b, 0x15, 0x1c, 0x4a, 0x01, 0xd3, 0x18, 0x04, 0x1c, + 0xd8, 0x7a, 0x11, 0x22, 0x10, 0x42, 0x04, 0xd0, 0x42, 0x22, 0x15, 0x42, + 0x01, 0xd0, 0x00, 0x20, 0x36, 0xe0, 0x1d, 0x4a, 0x21, 0x76, 0x12, 0x68, + 0x62, 0x61, 0x5a, 0x7d, 0x18, 0x7d, 0xd9, 0x7e, 0x12, 0x02, 0x02, 0x43, + 0x98, 0x7e, 0x09, 0x02, 0x12, 0x04, 0x01, 0x43, 0x11, 0x43, 0x21, 0x62, + 0xd8, 0x7a, 0x18, 0x22, 0x02, 0x40, 0x0c, 0xd1, 0x5a, 0x7f, 0x19, 0x7f, + 0x12, 0x02, 0x0a, 0x43, 0x99, 0x7f, 0xdb, 0x7f, 0x09, 0x04, 0x0a, 0x43, + 0x1b, 0x06, 0x13, 0x43, 0xe3, 0x61, 0x01, 0x23, 0x09, 0xe0, 0x10, 0x2a, + 0xdb, 0xd1, 0x22, 0x1c, 0x60, 0x6a, 0x1c, 0x32, 0x00, 0xf0, 0x5a, 0xfa, + 0x00, 0x28, 0xd4, 0xd0, 0x04, 0x23, 0x63, 0x72, 0x0f, 0x23, 0x00, 0x21, + 0x2b, 0x40, 0x23, 0x72, 0xe1, 0x60, 0x21, 0x61, 0x01, 0x20, 0x6a, 0x06, + 0x02, 0xd5, 0x20, 0x1c, 0xff, 0xf7, 0x60, 0xff, 0x38, 0xbd, 0xc0, 0x46, + 0x50, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0xf0, 0xb5, 0x45, 0x7a, + 0x87, 0xb0, 0x04, 0x1c, 0x0e, 0x1c, 0x01, 0x93, 0x00, 0x2d, 0x00, 0xd0, + 0x86, 0xe0, 0x10, 0x1c, 0x03, 0xa9, 0xff, 0xf7, 0xbb, 0xfd, 0x00, 0x28, + 0x00, 0xd1, 0x80, 0xe0, 0x72, 0x6a, 0x2f, 0x1c, 0x62, 0x62, 0xf5, 0x60, + 0x35, 0x61, 0x33, 0x69, 0xf2, 0x69, 0x93, 0x42, 0x26, 0xd2, 0xdb, 0x05, + 0x1b, 0x0f, 0x30, 0x1c, 0x00, 0x93, 0xff, 0xf7, 0x9f, 0xfe, 0x01, 0x1e, + 0x6f, 0xd0, 0x03, 0x78, 0x00, 0x2b, 0x01, 0xd0, 0xe5, 0x2b, 0x0b, 0xd1, + 0x00, 0x2f, 0x04, 0xd1, 0x00, 0x9b, 0x23, 0x76, 0x34, 0x4b, 0x1b, 0x68, + 0x63, 0x61, 0x0b, 0x78, 0x01, 0x27, 0x00, 0x2b, 0xe3, 0xd1, 0x0d, 0xe0, + 0x03, 0xa8, 0x0b, 0x22, 0x01, 0xf0, 0x0a, 0xfc, 0x00, 0x28, 0xdc, 0xd1, + 0x01, 0x9a, 0x30, 0x23, 0x13, 0x40, 0x30, 0x2b, 0x53, 0xd0, 0x20, 0x1c, + 0x00, 0x99, 0x4b, 0xe0, 0x01, 0x9a, 0x12, 0x23, 0x13, 0x40, 0x12, 0x2b, + 0x4b, 0xd1, 0x00, 0x2f, 0x06, 0xd0, 0x20, 0x1c, 0x01, 0x21, 0xff, 0xf7, + 0x6f, 0xfd, 0x06, 0x1e, 0x0a, 0xd1, 0x42, 0xe0, 0x73, 0x7a, 0x02, 0x2b, + 0x3f, 0xd0, 0x30, 0x1c, 0xff, 0xf7, 0x40, 0xfd, 0x00, 0x28, 0x3a, 0xd0, + 0x1f, 0x4e, 0x27, 0x76, 0x00, 0x21, 0x20, 0x22, 0x30, 0x1c, 0x01, 0xf0, + 0xfb, 0xfb, 0x30, 0x1c, 0x03, 0xa9, 0x0b, 0x22, 0x01, 0xf0, 0xed, 0xfb, + 0x1a, 0x4b, 0x1b, 0x68, 0x00, 0x2b, 0x05, 0xd0, 0x30, 0x1c, 0x31, 0x1c, + 0x10, 0x30, 0x0e, 0x31, 0x98, 0x47, 0x06, 0xe0, 0x21, 0x22, 0x32, 0x74, + 0xb3, 0x73, 0x28, 0x22, 0x08, 0x23, 0x72, 0x74, 0xf3, 0x73, 0x73, 0x7c, + 0x32, 0x7c, 0x1b, 0x02, 0x13, 0x43, 0xff, 0x22, 0x1a, 0x40, 0x1b, 0x0a, + 0xf3, 0x74, 0x73, 0x76, 0xf3, 0x7b, 0xb2, 0x74, 0x32, 0x76, 0xb2, 0x7b, + 0x1b, 0x02, 0x13, 0x43, 0xb3, 0x75, 0x1b, 0x0a, 0xf3, 0x75, 0x00, 0xf0, + 0x21, 0xf9, 0x00, 0x28, 0x07, 0xd0, 0x21, 0x7e, 0x01, 0x9a, 0x20, 0x1c, + 0xff, 0xf7, 0x26, 0xff, 0x05, 0x1c, 0x00, 0xe0, 0x00, 0x25, 0x28, 0x1c, + 0x07, 0xb0, 0xf0, 0xbd, 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x44, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x00, 0x21, 0x04, 0x1c, 0xff, 0xf7, + 0xbb, 0xfe, 0x00, 0x28, 0x0b, 0xd0, 0x20, 0x1c, 0x01, 0x21, 0xff, 0xf7, + 0x15, 0xfd, 0x00, 0x28, 0x05, 0xd0, 0xe5, 0x23, 0x03, 0x70, 0x00, 0x23, + 0x63, 0x72, 0x00, 0xf0, 0xfb, 0xf8, 0x10, 0xbd, 0x10, 0xb5, 0x0a, 0x1c, + 0x0a, 0x49, 0x8a, 0xb0, 0x08, 0x31, 0x00, 0x23, 0x04, 0x1c, 0x00, 0x91, + 0x69, 0x46, 0x4b, 0x72, 0x01, 0x93, 0x68, 0x46, 0x21, 0x1c, 0x02, 0x23, + 0xff, 0xf7, 0x42, 0xff, 0x00, 0x28, 0x02, 0xd0, 0x68, 0x46, 0xff, 0xf7, + 0xd7, 0xff, 0x0a, 0xb0, 0x10, 0xbd, 0xc0, 0x46, 0xb8, 0x4b, 0x00, 0x00, + 0xf0, 0xb5, 0x43, 0x7a, 0x87, 0xb0, 0x04, 0x1c, 0x0d, 0x1c, 0x03, 0x92, + 0x01, 0x2b, 0x0d, 0xd1, 0x03, 0x7a, 0x99, 0x07, 0x0a, 0xd5, 0x5a, 0x07, + 0x0c, 0xd5, 0xe1, 0x69, 0x22, 0x69, 0x8a, 0x42, 0x08, 0xd0, 0x20, 0x1c, + 0xff, 0xf7, 0x06, 0xfe, 0x00, 0x28, 0x03, 0xd1, 0x01, 0x23, 0x63, 0x60, + 0x00, 0x20, 0xaa, 0xe0, 0x03, 0x9b, 0x01, 0x93, 0x3b, 0xe0, 0x60, 0x6a, + 0x73, 0x0a, 0x07, 0x79, 0xf6, 0x05, 0x01, 0x3f, 0x1f, 0x40, 0xff, 0xb2, + 0xf6, 0x0d, 0x00, 0x2f, 0x36, 0xd0, 0x80, 0x22, 0x92, 0x00, 0x92, 0x1b, + 0x01, 0x99, 0x92, 0xb2, 0x0b, 0x1c, 0x91, 0x42, 0x00, 0xd9, 0x13, 0x1c, + 0x9b, 0xb2, 0x02, 0x93, 0x63, 0x6a, 0xe1, 0x68, 0x1a, 0x7c, 0x02, 0x39, + 0x91, 0x40, 0x5a, 0x69, 0x8b, 0x18, 0x02, 0x9a, 0xdf, 0x19, 0x80, 0x23, + 0x9b, 0x00, 0x9a, 0x42, 0x3f, 0xd1, 0x44, 0x4b, 0x19, 0x68, 0xb9, 0x42, + 0x02, 0xd1, 0x01, 0x22, 0x52, 0x42, 0x1a, 0x60, 0x41, 0x4b, 0x39, 0x1c, + 0x18, 0x68, 0x2a, 0x1c, 0xff, 0xf7, 0x22, 0xfc, 0x00, 0x28, 0xc7, 0xd0, + 0x80, 0x22, 0x92, 0x00, 0xad, 0x18, 0x01, 0x99, 0x02, 0x9a, 0x8b, 0x1a, + 0x21, 0x69, 0x9b, 0xb2, 0x01, 0x93, 0x8b, 0x18, 0x23, 0x61, 0x01, 0x9a, + 0x26, 0x69, 0x00, 0x2a, 0xbf, 0xd1, 0x49, 0xe0, 0x00, 0x2e, 0xc6, 0xd1, + 0xe1, 0x68, 0x00, 0x29, 0x03, 0xd1, 0x23, 0x6a, 0x00, 0x2b, 0x16, 0xd1, + 0x0f, 0xe0, 0x05, 0xaa, 0x00, 0xf0, 0xe2, 0xf8, 0x00, 0x28, 0x58, 0xd0, + 0x62, 0x6a, 0x05, 0x9b, 0x01, 0x32, 0xd2, 0x7f, 0x10, 0x2a, 0x01, 0xd1, + 0x2c, 0x4a, 0x00, 0xe0, 0x2c, 0x4a, 0x93, 0x42, 0x05, 0xd3, 0x20, 0x1c, + 0xff, 0xf7, 0x3c, 0xfc, 0x00, 0x28, 0xaa, 0xd1, 0x98, 0xe7, 0xe3, 0x60, + 0xa7, 0xe7, 0x00, 0x2e, 0x0f, 0xd1, 0x23, 0x69, 0xe1, 0x69, 0x8b, 0x42, + 0x0b, 0xd3, 0x00, 0xf0, 0x59, 0xf8, 0x00, 0x28, 0x8c, 0xd0, 0x1f, 0x4b, + 0x01, 0x21, 0x1f, 0x60, 0x21, 0x4b, 0x1a, 0x78, 0x0a, 0x43, 0x1a, 0x70, + 0x06, 0xe0, 0x38, 0x1c, 0x01, 0x21, 0x00, 0xf0, 0x75, 0xf8, 0x00, 0x28, + 0x00, 0xd1, 0x7d, 0xe7, 0x1c, 0x4b, 0x2a, 0x1c, 0xf6, 0x18, 0x02, 0x9b, + 0xf1, 0x18, 0x33, 0x1c, 0x8b, 0x42, 0x04, 0xd0, 0x10, 0x78, 0x01, 0x32, + 0x18, 0x70, 0x01, 0x33, 0xf8, 0xe7, 0x9e, 0x1b, 0xad, 0x19, 0xa8, 0xe7, + 0xe1, 0x69, 0x23, 0x7a, 0x8e, 0x42, 0x01, 0xd9, 0xe6, 0x61, 0x06, 0xe0, + 0x12, 0x4a, 0x12, 0x68, 0x00, 0x2a, 0x06, 0xd0, 0x03, 0x9a, 0x00, 0x2a, + 0x03, 0xd0, 0x80, 0x22, 0x52, 0x42, 0x13, 0x43, 0x23, 0x72, 0x23, 0x7a, + 0x19, 0x07, 0x01, 0xd4, 0x03, 0x98, 0x06, 0xe0, 0x20, 0x1c, 0xff, 0xf7, + 0x8b, 0xfd, 0x00, 0x28, 0x00, 0xd1, 0x51, 0xe7, 0xf6, 0xe7, 0x07, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, + 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, 0x50, 0x03, 0x00, 0x20, + 0x50, 0x01, 0x00, 0x20, 0x44, 0x01, 0x00, 0x20, 0x07, 0xb5, 0x6b, 0x46, + 0xd9, 0x71, 0x07, 0x33, 0x19, 0x1c, 0x01, 0x22, 0xff, 0xf7, 0x22, 0xff, + 0x0e, 0xbd, 0x00, 0x00, 0xf8, 0xb5, 0x0f, 0x4f, 0x01, 0x20, 0x3b, 0x78, + 0x00, 0x2b, 0x18, 0xd0, 0x0d, 0x4e, 0x0e, 0x4b, 0x0e, 0x4d, 0x19, 0x68, + 0x30, 0x68, 0x2a, 0x1c, 0xff, 0xf7, 0x80, 0xfb, 0x00, 0x28, 0x0e, 0xd0, + 0x0b, 0x4c, 0x21, 0x68, 0x00, 0x29, 0x07, 0xd0, 0x30, 0x68, 0x2a, 0x1c, + 0xff, 0xf7, 0x76, 0xfb, 0x00, 0x28, 0x04, 0xd0, 0x00, 0x23, 0x23, 0x60, + 0x00, 0x23, 0x3b, 0x70, 0x01, 0x20, 0xf8, 0xbd, 0x50, 0x03, 0x00, 0x20, + 0x4c, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x48, 0x01, 0x00, 0x20, 0x70, 0xb5, 0x0d, 0x4d, 0x04, 0x1c, 0x2b, 0x68, + 0x0e, 0x1c, 0x83, 0x42, 0x0e, 0xd0, 0xff, 0xf7, 0xcd, 0xff, 0x00, 0x28, + 0x01, 0xd1, 0x00, 0x20, 0x0d, 0xe0, 0x08, 0x4b, 0x21, 0x1c, 0x18, 0x68, + 0x07, 0x4a, 0xff, 0xf7, 0x25, 0xfb, 0x00, 0x28, 0xf5, 0xd0, 0x2c, 0x60, + 0x05, 0x4b, 0x01, 0x20, 0x1a, 0x78, 0x16, 0x43, 0x1e, 0x70, 0x70, 0xbd, + 0x00, 0x00, 0x00, 0x20, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0x50, 0x03, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x1c, 0xff, 0xf7, 0xae, 0xff, + 0x00, 0x28, 0x0f, 0xd0, 0x00, 0x23, 0x08, 0x4a, 0x00, 0x21, 0x99, 0x54, + 0x80, 0x22, 0x01, 0x33, 0x92, 0x00, 0x93, 0x42, 0xf7, 0xd1, 0x05, 0x4b, + 0x01, 0x20, 0x1c, 0x60, 0x04, 0x4b, 0x1a, 0x78, 0x02, 0x43, 0x1a, 0x70, + 0x10, 0xbd, 0xc0, 0x46, 0x50, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, + 0x50, 0x03, 0x00, 0x20, 0xc3, 0x68, 0x70, 0xb5, 0x01, 0x33, 0x0c, 0x1c, + 0x15, 0x1c, 0x99, 0x42, 0x01, 0xd9, 0x00, 0x20, 0x21, 0xe0, 0x46, 0x1c, + 0xf1, 0x7f, 0xc2, 0x69, 0xe3, 0x09, 0x10, 0x29, 0x00, 0xd1, 0x23, 0x0a, + 0x98, 0x18, 0x0d, 0x4b, 0x1b, 0x68, 0x98, 0x42, 0x07, 0xd1, 0xf2, 0x7f, + 0x0b, 0x4b, 0x10, 0x2a, 0x09, 0xd1, 0xe4, 0xb2, 0x64, 0x00, 0x1b, 0x5b, + 0x0b, 0xe0, 0x00, 0x21, 0xff, 0xf7, 0x9e, 0xff, 0x00, 0x28, 0xf2, 0xd1, + 0xe3, 0xe7, 0x7f, 0x22, 0x14, 0x40, 0xa4, 0x00, 0x1b, 0x59, 0x1b, 0x01, + 0x1b, 0x09, 0x2b, 0x60, 0x01, 0x20, 0x70, 0xbd, 0x00, 0x00, 0x00, 0x20, + 0x50, 0x01, 0x00, 0x20, 0x73, 0xb5, 0x05, 0x1c, 0x01, 0x91, 0x16, 0x1c, + 0x00, 0x24, 0x28, 0x1c, 0x01, 0x99, 0x01, 0xaa, 0xff, 0xf7, 0xc6, 0xff, + 0x00, 0x28, 0x10, 0xd0, 0x2a, 0x7c, 0x80, 0x23, 0x9b, 0x00, 0x93, 0x40, + 0xe4, 0x18, 0x6b, 0x1c, 0xdb, 0x7f, 0x01, 0x9a, 0x10, 0x2b, 0x01, 0xd1, + 0x03, 0x4b, 0x00, 0xe0, 0x03, 0x4b, 0x9a, 0x42, 0xe9, 0xd3, 0x34, 0x60, + 0x01, 0x20, 0x76, 0xbd, 0xf8, 0xff, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x0f, + 0xf7, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x01, 0x92, 0x01, 0x29, 0x32, 0xd9, + 0xc3, 0x68, 0x00, 0x20, 0x01, 0x33, 0x99, 0x42, 0x2e, 0xd8, 0x6f, 0x1c, + 0xfa, 0x7f, 0xee, 0x69, 0xcb, 0x09, 0x10, 0x2a, 0x00, 0xd1, 0x0b, 0x0a, + 0x9e, 0x19, 0x14, 0x4b, 0x1b, 0x68, 0x9e, 0x42, 0x08, 0xd1, 0xfa, 0x7f, + 0x12, 0x4b, 0x10, 0x2a, 0x0b, 0xd1, 0xe4, 0xb2, 0x01, 0x9a, 0x64, 0x00, + 0x1a, 0x53, 0x0b, 0xe0, 0x30, 0x1c, 0x00, 0x21, 0xff, 0xf7, 0x48, 0xff, + 0x00, 0x28, 0xf0, 0xd1, 0x12, 0xe0, 0x7f, 0x22, 0x14, 0x40, 0x01, 0x9a, + 0xa4, 0x00, 0x1a, 0x51, 0x09, 0x4b, 0x01, 0x20, 0x1a, 0x78, 0x02, 0x43, + 0x1a, 0x70, 0x2b, 0x7e, 0x83, 0x42, 0x05, 0xd9, 0xab, 0x68, 0xf6, 0x18, + 0x05, 0x4b, 0x1e, 0x60, 0x00, 0xe0, 0x00, 0x20, 0xfe, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, 0x50, 0x03, 0x00, 0x20, + 0x48, 0x01, 0x00, 0x20, 0xf0, 0xb5, 0x15, 0x68, 0x87, 0xb0, 0x06, 0x1c, + 0x02, 0x91, 0x17, 0x1c, 0x00, 0x2d, 0x03, 0xd0, 0x00, 0x21, 0x01, 0x35, + 0x01, 0x91, 0x06, 0xe0, 0x02, 0x9b, 0x05, 0x68, 0x01, 0x3b, 0x5a, 0x42, + 0x53, 0x41, 0xdb, 0xb2, 0x01, 0x93, 0xf2, 0x68, 0x00, 0x23, 0x01, 0x32, + 0x03, 0x92, 0x2c, 0x1c, 0x00, 0x93, 0x00, 0x99, 0xf2, 0x68, 0x91, 0x42, + 0x21, 0xd2, 0x03, 0x9b, 0x9c, 0x42, 0x01, 0xd9, 0x02, 0x24, 0x25, 0x1c, + 0x30, 0x1c, 0x21, 0x1c, 0x05, 0xaa, 0xff, 0xf7, 0x43, 0xff, 0x00, 0x28, + 0x15, 0xd0, 0x05, 0x99, 0x63, 0x1c, 0x00, 0x29, 0x01, 0xd0, 0x1d, 0x1c, + 0x03, 0xe0, 0x02, 0x99, 0x5a, 0x1b, 0x8a, 0x42, 0x04, 0xd0, 0x00, 0x9a, + 0x1c, 0x1c, 0x01, 0x32, 0x00, 0x92, 0xe0, 0xe7, 0x30, 0x1c, 0x21, 0x1c, + 0x13, 0x4a, 0xff, 0xf7, 0x7f, 0xff, 0x00, 0x28, 0x0b, 0xd1, 0x00, 0x20, + 0x1d, 0xe0, 0x63, 0x1e, 0x30, 0x1c, 0x19, 0x1c, 0x22, 0x1c, 0x00, 0x93, + 0xff, 0xf7, 0x74, 0xff, 0x00, 0x28, 0xf4, 0xd0, 0x00, 0x9c, 0xac, 0x42, + 0xf3, 0xd8, 0x39, 0x68, 0x00, 0x29, 0x06, 0xd1, 0x01, 0x99, 0x3d, 0x60, + 0x00, 0x29, 0x09, 0xd0, 0x01, 0x35, 0x35, 0x60, 0x06, 0xe0, 0x30, 0x1c, + 0x2a, 0x1c, 0xff, 0xf7, 0x61, 0xff, 0x00, 0x28, 0xf2, 0xd1, 0xe0, 0xe7, + 0x01, 0x20, 0x07, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0xff, 0xff, 0xff, 0x0f, + 0x02, 0x23, 0x37, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x03, 0x60, 0x28, 0x1c, + 0x21, 0x1c, 0x01, 0xaa, 0xff, 0xf7, 0xfc, 0xfe, 0x00, 0x28, 0x12, 0xd0, + 0x28, 0x1c, 0x21, 0x1c, 0x00, 0x22, 0xff, 0xf7, 0x47, 0xff, 0x00, 0x28, + 0x0b, 0xd0, 0x6b, 0x1c, 0xdb, 0x7f, 0x01, 0x9c, 0x10, 0x2b, 0x01, 0xd1, + 0x04, 0x4b, 0x00, 0xe0, 0x04, 0x4b, 0x9c, 0x42, 0xe7, 0xd3, 0x01, 0x20, + 0x00, 0xe0, 0x00, 0x20, 0x3e, 0xbd, 0xc0, 0x46, 0xf8, 0xff, 0x00, 0x00, + 0xf8, 0xff, 0xff, 0x0f, 0xf8, 0xb5, 0x44, 0x4b, 0x04, 0x1c, 0x15, 0x1c, + 0x19, 0x60, 0x29, 0xd0, 0x04, 0x2a, 0x01, 0xd9, 0x00, 0x20, 0x7d, 0xe0, + 0x00, 0x20, 0x01, 0x1c, 0xff, 0xf7, 0x90, 0xfe, 0x00, 0x28, 0xf7, 0xd0, + 0x2d, 0x01, 0x3d, 0x4b, 0xa9, 0x35, 0xff, 0x35, 0x5d, 0x19, 0xaa, 0x79, + 0xab, 0x1d, 0x50, 0x06, 0xee, 0xd1, 0xea, 0x7c, 0xa9, 0x7c, 0x12, 0x02, + 0x0a, 0x43, 0x29, 0x7d, 0x09, 0x04, 0x0a, 0x43, 0x69, 0x7d, 0x09, 0x06, + 0x0a, 0x43, 0x63, 0x2a, 0xe2, 0xd9, 0xaa, 0x7b, 0xed, 0x7b, 0x2d, 0x02, + 0x15, 0x43, 0x9a, 0x7a, 0xdb, 0x7a, 0x12, 0x04, 0x15, 0x43, 0x1b, 0x06, + 0x1d, 0x43, 0xd7, 0xd0, 0x28, 0x1c, 0x00, 0x21, 0xff, 0xf7, 0x6a, 0xfe, + 0x00, 0x28, 0xd1, 0xd0, 0x2a, 0x4b, 0x19, 0x7b, 0xda, 0x7a, 0x09, 0x02, + 0x11, 0x43, 0x80, 0x22, 0x92, 0x00, 0x91, 0x42, 0xc8, 0xd1, 0x1a, 0x7c, + 0x00, 0x2a, 0xc5, 0xd0, 0xd9, 0x89, 0x00, 0x29, 0xc2, 0xd0, 0x59, 0x7b, + 0x00, 0x29, 0xbf, 0xd0, 0x22, 0x76, 0x00, 0x22, 0x21, 0x71, 0x22, 0x74, + 0x22, 0x7c, 0x01, 0x20, 0x90, 0x40, 0x81, 0x42, 0x04, 0xd0, 0x50, 0x1c, + 0x20, 0x74, 0x07, 0x2a, 0xf6, 0xd9, 0xb1, 0xe7, 0xd9, 0x8a, 0x00, 0x29, + 0x00, 0xd1, 0x59, 0x6a, 0xa1, 0x60, 0xd8, 0x89, 0x28, 0x18, 0xe0, 0x61, + 0x1f, 0x69, 0x3e, 0x02, 0x36, 0x0c, 0x66, 0x84, 0xb7, 0xb2, 0x1e, 0x7c, + 0x71, 0x43, 0x0e, 0x18, 0x13, 0x48, 0x79, 0x01, 0x09, 0x18, 0x49, 0x12, + 0x71, 0x18, 0x66, 0x62, 0x61, 0x61, 0x18, 0x7d, 0xde, 0x7c, 0x00, 0x02, + 0x30, 0x43, 0x00, 0xd1, 0x18, 0x6a, 0x6d, 0x1a, 0x28, 0x18, 0xd0, 0x40, + 0x02, 0x1c, 0xe0, 0x60, 0x0b, 0x48, 0x61, 0x1c, 0x82, 0x42, 0x01, 0xd8, + 0x0c, 0x23, 0x07, 0xe0, 0x09, 0x48, 0x82, 0x42, 0x01, 0xd8, 0x10, 0x23, + 0x02, 0xe0, 0xdb, 0x6a, 0x63, 0x62, 0x20, 0x23, 0xcb, 0x77, 0x01, 0x20, + 0xf8, 0xbd, 0xc0, 0x46, 0x4c, 0x01, 0x00, 0x20, 0x50, 0x01, 0x00, 0x20, + 0xff, 0x01, 0x00, 0x00, 0xf4, 0x0f, 0x00, 0x00, 0xf4, 0xff, 0x00, 0x00, + 0x08, 0xb5, 0x05, 0x49, 0x05, 0x4a, 0x06, 0x48, 0x00, 0xf0, 0x10, 0xf8, + 0x05, 0x4b, 0x06, 0x49, 0x00, 0x22, 0x1a, 0x70, 0x5a, 0x54, 0x08, 0xbd, + 0x00, 0x4c, 0x00, 0x00, 0x01, 0x04, 0x00, 0x00, 0x54, 0x03, 0x00, 0x20, + 0x6c, 0x03, 0x00, 0x20, 0x02, 0x04, 0x00, 0x00, 0x30, 0xb5, 0x09, 0x4c, + 0x09, 0x4b, 0xa5, 0x68, 0x6d, 0x03, 0x6d, 0x0f, 0xad, 0x00, 0xeb, 0x58, + 0x03, 0x60, 0xa4, 0x68, 0x01, 0x61, 0xa4, 0xb2, 0x44, 0x60, 0x5c, 0x43, + 0x9b, 0x00, 0x84, 0x60, 0xc3, 0x60, 0x42, 0x61, 0x30, 0xbd, 0xc0, 0x46, + 0x00, 0x40, 0x00, 0x41, 0x00, 0x51, 0x00, 0x00, 0xf7, 0xb5, 0x1f, 0x4e, + 0x80, 0x27, 0x75, 0x68, 0x03, 0x33, 0x3d, 0x43, 0x9b, 0x08, 0x75, 0x60, + 0x00, 0x2b, 0x34, 0xd0, 0x1b, 0x4d, 0x35, 0x80, 0x35, 0x7d, 0xef, 0x07, + 0xfc, 0xd5, 0x1d, 0x1c, 0x5f, 0x1b, 0x01, 0x97, 0x07, 0x68, 0xbf, 0x08, + 0xbc, 0x46, 0x01, 0x9f, 0x67, 0x45, 0x1f, 0xd2, 0x00, 0x2d, 0x1d, 0xd0, + 0x17, 0x78, 0x01, 0x3d, 0x01, 0x97, 0xff, 0x27, 0xbc, 0x43, 0x01, 0x9f, + 0x3c, 0x43, 0x57, 0x78, 0x3f, 0x02, 0x01, 0x97, 0x0f, 0x4f, 0x3c, 0x40, + 0x01, 0x9f, 0x3c, 0x43, 0x97, 0x78, 0x3f, 0x04, 0xbc, 0x46, 0x0d, 0x4f, + 0x3c, 0x40, 0xd7, 0x78, 0xa4, 0xb2, 0x3f, 0x06, 0x00, 0x97, 0x67, 0x46, + 0x3c, 0x43, 0x00, 0x9f, 0x04, 0x32, 0x3c, 0x43, 0x10, 0xc1, 0xd7, 0xe7, + 0x07, 0x4b, 0x33, 0x80, 0x33, 0x7d, 0xdf, 0x07, 0xfc, 0xd5, 0x2b, 0x1c, + 0xc8, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x44, 0xa5, 0xff, 0xff, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, 0x04, 0xa5, 0xff, 0xff, + 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, 0x1a, 0x80, 0x1a, 0x7d, + 0xd1, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x05, 0x1c, 0x0c, 0x1c, 0x16, 0x1c, + 0xeb, 0x68, 0x28, 0x1c, 0x21, 0x1c, 0x9e, 0x42, 0x05, 0xd9, 0xff, 0xf7, + 0xe7, 0xff, 0xeb, 0x68, 0xe4, 0x18, 0xf6, 0x1a, 0xf4, 0xe7, 0xff, 0xf7, + 0xe1, 0xff, 0x70, 0xbd, 0x43, 0x7a, 0x00, 0x2b, 0x04, 0xd1, 0x83, 0x72, + 0xc3, 0x72, 0xc3, 0x60, 0x01, 0x23, 0x43, 0x72, 0x70, 0x47, 0x30, 0xb5, + 0x85, 0xb0, 0x04, 0x1c, 0x02, 0xad, 0x00, 0x68, 0x02, 0x91, 0x03, 0x92, + 0x00, 0xf0, 0x8a, 0xfc, 0x6b, 0x79, 0xe1, 0x79, 0x22, 0x7a, 0x00, 0x93, + 0x20, 0x68, 0x00, 0x23, 0x00, 0xf0, 0x24, 0xfd, 0x29, 0x79, 0x20, 0x68, + 0x02, 0x9a, 0x00, 0xf0, 0x4d, 0xfc, 0x20, 0x68, 0x00, 0xf0, 0x70, 0xfc, + 0x05, 0xb0, 0x30, 0xbd, 0x70, 0xb5, 0x04, 0x1c, 0x18, 0x26, 0xff, 0xf7, + 0xd7, 0xff, 0x20, 0x79, 0x33, 0x1c, 0x43, 0x43, 0x0d, 0x4d, 0x08, 0x21, + 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x0a, 0xfb, 0xa0, 0x79, 0x33, 0x1c, + 0x43, 0x43, 0x08, 0x21, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x02, 0xfb, + 0x60, 0x79, 0x08, 0x21, 0x46, 0x43, 0xad, 0x19, 0x69, 0x56, 0x00, 0xf0, + 0xfb, 0xfa, 0x04, 0x4b, 0x20, 0x1c, 0x06, 0xcb, 0xff, 0xf7, 0xc3, 0xff, + 0x70, 0xbd, 0xc0, 0x46, 0x20, 0x51, 0x00, 0x00, 0x70, 0x07, 0x00, 0x20, + 0x07, 0xb5, 0x83, 0x7a, 0x00, 0x91, 0x01, 0x92, 0x00, 0x2b, 0x0d, 0xd0, + 0x9a, 0x07, 0x06, 0xd5, 0xef, 0xf3, 0x10, 0x83, 0x5a, 0x42, 0x53, 0x41, + 0xc3, 0x72, 0x72, 0xb6, 0x04, 0xe0, 0xda, 0x07, 0x02, 0xd5, 0x82, 0x89, + 0x03, 0x4b, 0x9a, 0x60, 0x00, 0x99, 0x01, 0x9a, 0xff, 0xf7, 0xa5, 0xff, + 0x07, 0xbd, 0xc0, 0x46, 0x00, 0x18, 0x00, 0x40, 0x83, 0x7a, 0x00, 0x2b, + 0x0b, 0xd0, 0x9a, 0x07, 0x04, 0xd5, 0xc3, 0x7a, 0x00, 0x2b, 0x06, 0xd0, + 0x62, 0xb6, 0x04, 0xe0, 0xda, 0x07, 0x02, 0xd5, 0x82, 0x89, 0x01, 0x4b, + 0xda, 0x60, 0x70, 0x47, 0x00, 0x18, 0x00, 0x40, 0x08, 0xb5, 0x00, 0x68, + 0x00, 0xf0, 0x27, 0xfc, 0x08, 0xbd, 0x00, 0x00, 0x09, 0x4b, 0x0a, 0x4a, + 0x0a, 0x49, 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x09, 0x4b, + 0x19, 0x60, 0x16, 0x21, 0x19, 0x71, 0x18, 0x21, 0x99, 0x71, 0x17, 0x21, + 0x59, 0x71, 0x01, 0x21, 0x5a, 0x72, 0xd9, 0x71, 0x1a, 0x72, 0x70, 0x47, + 0x70, 0x07, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, 0x10, 0x09, 0x00, 0x20, + 0x78, 0x07, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x78, 0xfd, + 0x08, 0xbd, 0xc0, 0x46, 0x44, 0x08, 0x00, 0x20, 0x08, 0xb5, 0x02, 0x48, + 0x00, 0xf0, 0x70, 0xfd, 0x08, 0xbd, 0xc0, 0x46, 0x88, 0x07, 0x00, 0x20, + 0xf7, 0xb5, 0x16, 0x4f, 0x16, 0x49, 0x38, 0x1c, 0x00, 0xf0, 0x3a, 0xfb, + 0x15, 0x49, 0x16, 0x48, 0x00, 0xf0, 0x36, 0xfb, 0x15, 0x49, 0x16, 0x48, + 0x00, 0xf0, 0x32, 0xfb, 0x15, 0x49, 0x16, 0x48, 0x00, 0xf0, 0x2e, 0xfb, + 0x15, 0x49, 0x16, 0x48, 0x00, 0xf0, 0x2a, 0xfb, 0x15, 0x4d, 0x03, 0x26, + 0x01, 0x24, 0x28, 0x1c, 0x14, 0x49, 0x00, 0xf0, 0x23, 0xfb, 0x39, 0x1c, + 0x00, 0x96, 0x23, 0x1c, 0x01, 0x94, 0x00, 0x22, 0x11, 0x48, 0x00, 0xf0, + 0x35, 0xfd, 0x00, 0x96, 0x29, 0x1c, 0x01, 0x94, 0x1f, 0x22, 0x1e, 0x23, + 0x0e, 0x48, 0x00, 0xf0, 0x2d, 0xfd, 0xf7, 0xbd, 0x04, 0x09, 0x00, 0x20, + 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, 0x08, 0x09, 0x00, 0x20, + 0x00, 0x10, 0x00, 0x42, 0x0c, 0x09, 0x00, 0x20, 0x00, 0x14, 0x00, 0x42, + 0x00, 0x09, 0x00, 0x20, 0x00, 0x18, 0x00, 0x42, 0x10, 0x09, 0x00, 0x20, + 0x14, 0x09, 0x00, 0x20, 0x00, 0x1c, 0x00, 0x42, 0x44, 0x08, 0x00, 0x20, + 0x88, 0x07, 0x00, 0x20, 0xfe, 0xe7, 0x00, 0x00, 0x08, 0xb5, 0x03, 0x4b, + 0x1b, 0x68, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, 0x08, 0xbd, 0xc0, 0x46, + 0x18, 0x09, 0x00, 0x20, 0x38, 0xb5, 0x0f, 0x49, 0x0f, 0x4c, 0xa1, 0x42, + 0x04, 0xd1, 0x00, 0xf0, 0x4f, 0xf8, 0xfe, 0xf7, 0xbd, 0xfa, 0x0b, 0xe0, + 0x0c, 0x4d, 0x8d, 0x42, 0xf7, 0xd0, 0x00, 0x23, 0xca, 0x18, 0xe8, 0x18, + 0xa2, 0x42, 0x04, 0xd2, 0x00, 0x68, 0x04, 0x33, 0x10, 0x60, 0xf7, 0xe7, + 0xfe, 0xe7, 0x90, 0x42, 0xeb, 0xd0, 0x06, 0x4b, 0x06, 0x4a, 0x93, 0x42, + 0xe7, 0xd2, 0x00, 0x22, 0x04, 0xc3, 0xf9, 0xe7, 0x00, 0x00, 0x00, 0x20, + 0xa0, 0x00, 0x00, 0x20, 0xe0, 0x55, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x20, + 0x30, 0x09, 0x00, 0x20, 0x08, 0xb5, 0x00, 0xf0, 0x26, 0xf8, 0x00, 0x28, + 0x01, 0xd1, 0x00, 0xf0, 0x17, 0xf8, 0x08, 0xbd, 0x01, 0x4b, 0x18, 0x68, + 0x70, 0x47, 0xc0, 0x46, 0x1c, 0x09, 0x00, 0x20, 0x70, 0xb5, 0x04, 0x1e, + 0x08, 0xd0, 0x05, 0x4b, 0x1d, 0x68, 0x1e, 0x1c, 0x00, 0xf0, 0x12, 0xf8, + 0x33, 0x68, 0x5b, 0x1b, 0xa3, 0x42, 0xf9, 0xd3, 0x70, 0xbd, 0xc0, 0x46, + 0x1c, 0x09, 0x00, 0x20, 0x08, 0xb5, 0x03, 0x4b, 0x1a, 0x68, 0x01, 0x32, + 0x1a, 0x60, 0x00, 0xf0, 0x61, 0xfa, 0x08, 0xbd, 0x1c, 0x09, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, 0x70, 0xb5, 0x49, 0x4a, + 0x1e, 0x21, 0x53, 0x68, 0x02, 0x20, 0x8b, 0x43, 0x03, 0x43, 0x47, 0x49, + 0x53, 0x60, 0x8b, 0x69, 0x08, 0x24, 0x23, 0x43, 0x8b, 0x61, 0x45, 0x4c, + 0x45, 0x4b, 0x9c, 0x82, 0x9c, 0x8a, 0x20, 0x43, 0x98, 0x82, 0x10, 0x1c, + 0xda, 0x68, 0x94, 0x07, 0xfc, 0xd5, 0x42, 0x4a, 0x01, 0x24, 0x14, 0x70, + 0x14, 0x78, 0xe5, 0x07, 0x04, 0xd5, 0x3f, 0x4c, 0x64, 0x78, 0x64, 0xb2, + 0x00, 0x2c, 0xf7, 0xdb, 0x01, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, + 0x00, 0x2c, 0xfb, 0xdb, 0x3a, 0x4d, 0x39, 0x4c, 0x65, 0x60, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x82, 0x25, 0x35, 0x4c, 0xed, 0x01, + 0x65, 0x80, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x02, 0x24, + 0x9c, 0x84, 0xdc, 0x68, 0xe6, 0x06, 0xfc, 0xd5, 0x31, 0x4d, 0x2e, 0x4c, + 0xe5, 0x62, 0xdd, 0x68, 0x2c, 0x4c, 0xee, 0x06, 0xfb, 0xd5, 0xa5, 0x8c, + 0x2e, 0x4e, 0x35, 0x43, 0xa5, 0x84, 0xdd, 0x68, 0x28, 0x4c, 0xee, 0x06, + 0xfb, 0xd5, 0xa5, 0x8c, 0x02, 0x26, 0x35, 0x43, 0xa5, 0x84, 0xdc, 0x68, + 0x25, 0x06, 0xfc, 0xd5, 0x23, 0x4c, 0xe4, 0x68, 0x66, 0x06, 0xf8, 0xd5, + 0xdc, 0x68, 0xe5, 0x06, 0xfc, 0xd5, 0x00, 0x24, 0x94, 0x60, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x22, 0x4d, 0x1d, 0x4c, 0x65, 0x60, + 0x55, 0x78, 0x1c, 0x4c, 0x6d, 0xb2, 0x00, 0x2d, 0xfa, 0xdb, 0x1e, 0x6a, + 0x1e, 0x4d, 0x35, 0x40, 0x1d, 0x62, 0x1d, 0x6a, 0x80, 0x26, 0xb5, 0x43, + 0x1d, 0x62, 0x03, 0x23, 0xa3, 0x60, 0x1b, 0x4b, 0x63, 0x60, 0x53, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x00, 0x23, 0x0b, 0x72, 0x18, 0x4a, + 0x4b, 0x72, 0x8b, 0x72, 0xcb, 0x72, 0x17, 0x4b, 0xff, 0x21, 0x1a, 0x60, + 0x16, 0x4b, 0x17, 0x4a, 0x1b, 0x68, 0x12, 0x68, 0x5c, 0x01, 0xd2, 0x0e, + 0x21, 0x40, 0x11, 0x43, 0x9a, 0x06, 0x52, 0x0f, 0x12, 0x02, 0x0b, 0x1c, + 0x13, 0x43, 0x12, 0x4a, 0x13, 0x85, 0x43, 0x68, 0x80, 0x22, 0x13, 0x43, + 0x43, 0x60, 0x70, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x00, 0x04, 0x00, 0x40, + 0x0c, 0x06, 0x00, 0x00, 0x00, 0x08, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, + 0x01, 0x05, 0x01, 0x00, 0xb9, 0x05, 0xff, 0x7d, 0x04, 0x0a, 0x00, 0x00, + 0x00, 0x07, 0x03, 0x00, 0xff, 0xfc, 0xff, 0xff, 0x03, 0x06, 0x01, 0x00, + 0x00, 0x6c, 0xdc, 0x02, 0x04, 0x00, 0x00, 0x20, 0x24, 0x60, 0x80, 0x00, + 0x20, 0x60, 0x80, 0x00, 0x00, 0x40, 0x00, 0x42, 0x31, 0x4b, 0xfa, 0x21, + 0x18, 0x68, 0x10, 0xb5, 0x89, 0x00, 0x00, 0xf0, 0x43, 0xfd, 0x2f, 0x4b, + 0x01, 0x38, 0x98, 0x42, 0x24, 0xd8, 0x2e, 0x4a, 0x2e, 0x4b, 0x50, 0x60, + 0x18, 0x6a, 0xc0, 0x21, 0x00, 0x02, 0x00, 0x0a, 0x09, 0x06, 0x01, 0x43, + 0x19, 0x62, 0x00, 0x24, 0x07, 0x21, 0x94, 0x60, 0x11, 0x60, 0x19, 0x6a, + 0x80, 0x22, 0x09, 0x02, 0x09, 0x0a, 0x12, 0x06, 0x0a, 0x43, 0x1a, 0x62, + 0x25, 0x4b, 0xfc, 0x21, 0x1a, 0x6a, 0x0a, 0x43, 0x1a, 0x62, 0x19, 0x6a, + 0xfc, 0x22, 0x92, 0x01, 0x0a, 0x43, 0x1a, 0x62, 0x19, 0x6a, 0xa0, 0x22, + 0xd2, 0x02, 0x0a, 0x43, 0x1a, 0x62, 0x00, 0xe0, 0xfe, 0xe7, 0x20, 0x1c, + 0x00, 0x21, 0x01, 0x34, 0x00, 0xf0, 0x70, 0xf8, 0x14, 0x2c, 0xf8, 0xd1, + 0x1a, 0x4c, 0x63, 0x78, 0x5b, 0xb2, 0x00, 0x2b, 0xfa, 0xdb, 0x19, 0x4b, + 0x63, 0x80, 0x19, 0x4b, 0x5a, 0x7e, 0xd2, 0x09, 0x01, 0x2a, 0xfa, 0xd0, + 0xe4, 0x22, 0xd2, 0x00, 0x9a, 0x80, 0x3f, 0x22, 0xda, 0x70, 0x59, 0x7e, + 0x13, 0x4a, 0xc9, 0x09, 0x01, 0x29, 0xfa, 0xd0, 0xc0, 0x23, 0x5b, 0x01, + 0x00, 0x20, 0x13, 0x61, 0x90, 0x70, 0x00, 0xf0, 0x23, 0xf8, 0x63, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x0d, 0x4a, 0x09, 0x4b, 0x5a, 0x80, + 0x0c, 0x4b, 0xda, 0x79, 0xd2, 0x09, 0x01, 0x2a, 0xfa, 0xd0, 0x41, 0x22, + 0x5a, 0x70, 0x10, 0xbd, 0x04, 0x00, 0x00, 0x20, 0xff, 0xff, 0xff, 0x00, + 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, 0x00, 0x04, 0x00, 0x40, + 0x00, 0x0c, 0x00, 0x40, 0x1e, 0x40, 0x00, 0x00, 0x00, 0x40, 0x00, 0x42, + 0x21, 0x40, 0x00, 0x00, 0x00, 0x48, 0x00, 0x42, 0x00, 0xb5, 0x14, 0x4a, + 0x51, 0x7e, 0x13, 0x1c, 0xc9, 0x09, 0x01, 0x29, 0xf9, 0xd0, 0x01, 0x38, + 0x04, 0x28, 0x13, 0xd8, 0x19, 0x69, 0x10, 0x4a, 0x0a, 0x40, 0x1a, 0x61, + 0x5a, 0x78, 0x0f, 0x21, 0x8a, 0x43, 0x00, 0xf0, 0xb5, 0xfc, 0x03, 0x05, + 0x09, 0x07, 0x03, 0x00, 0x01, 0x21, 0x02, 0xe0, 0x03, 0x21, 0x00, 0xe0, + 0x02, 0x21, 0x0a, 0x43, 0x5a, 0x70, 0x0a, 0xe0, 0x11, 0x69, 0xf0, 0x23, + 0x1b, 0x05, 0x0b, 0x43, 0x13, 0x61, 0x53, 0x78, 0x0f, 0x21, 0x8b, 0x43, + 0x02, 0x21, 0x0b, 0x43, 0x53, 0x70, 0x00, 0xbd, 0x00, 0x40, 0x00, 0x42, + 0xff, 0xff, 0xff, 0xf0, 0x10, 0xb5, 0x18, 0x24, 0x02, 0x1c, 0x20, 0x1c, + 0x50, 0x43, 0x27, 0x4b, 0x18, 0x18, 0x00, 0x7a, 0x40, 0xb2, 0x01, 0x30, + 0x46, 0xd0, 0x03, 0x29, 0x44, 0xd8, 0x08, 0x1c, 0x21, 0x1c, 0x00, 0xf0, + 0x89, 0xfc, 0x02, 0x33, 0x11, 0x21, 0x62, 0x43, 0x98, 0x56, 0x9a, 0x18, + 0xc3, 0x01, 0x1f, 0x48, 0x52, 0x68, 0x1b, 0x18, 0x99, 0x18, 0x40, 0x31, + 0x02, 0x20, 0x08, 0x70, 0x01, 0x21, 0x91, 0x40, 0x59, 0x60, 0x2f, 0xe0, + 0x62, 0x43, 0x98, 0x56, 0x18, 0x49, 0x9a, 0x18, 0x52, 0x68, 0xc3, 0x01, + 0x5b, 0x18, 0x99, 0x18, 0x40, 0x31, 0x06, 0x20, 0x08, 0x70, 0x01, 0x21, + 0x91, 0x40, 0x59, 0x60, 0x99, 0x61, 0x1f, 0xe0, 0x51, 0x43, 0x5a, 0x56, + 0x10, 0x48, 0x59, 0x18, 0x4b, 0x68, 0xd2, 0x01, 0x11, 0x18, 0xc8, 0x18, + 0x40, 0x30, 0x06, 0x24, 0x04, 0x70, 0x01, 0x20, 0x98, 0x40, 0x48, 0x60, + 0x0b, 0x49, 0x52, 0x18, 0x50, 0x60, 0x0d, 0xe0, 0x62, 0x43, 0x98, 0x56, + 0x9a, 0x18, 0xc3, 0x01, 0x06, 0x48, 0x52, 0x68, 0x1b, 0x18, 0x99, 0x18, + 0x40, 0x31, 0x02, 0x20, 0x08, 0x70, 0x01, 0x21, 0x91, 0x40, 0x99, 0x60, + 0x10, 0xbd, 0xc0, 0x46, 0x20, 0x51, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x10, 0x44, 0x00, 0x41, 0x18, 0x23, 0x58, 0x43, 0x13, 0x4a, 0xf0, 0xb5, + 0x13, 0x18, 0x08, 0x24, 0x1c, 0x57, 0x01, 0x34, 0x1f, 0xd0, 0x82, 0x56, + 0x10, 0x4e, 0xd2, 0x01, 0x5d, 0x68, 0x01, 0x24, 0x90, 0x19, 0x23, 0x1c, + 0x86, 0x68, 0xab, 0x40, 0x1e, 0x42, 0x0b, 0xd1, 0x0e, 0x1c, 0x77, 0x1e, + 0xbe, 0x41, 0x40, 0x19, 0x34, 0x40, 0x40, 0x30, 0xa5, 0x00, 0x04, 0x78, + 0x04, 0x26, 0xb4, 0x43, 0x2c, 0x43, 0x04, 0x70, 0x00, 0x29, 0x03, 0xd1, + 0x05, 0x49, 0x52, 0x18, 0x53, 0x60, 0x02, 0xe0, 0x02, 0x4e, 0x92, 0x19, + 0x93, 0x61, 0xf0, 0xbd, 0x20, 0x51, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x10, 0x44, 0x00, 0x41, 0x18, 0x22, 0x42, 0x43, 0xf8, 0xb5, 0x2d, 0x4d, + 0x08, 0x24, 0xaa, 0x18, 0x14, 0x57, 0x03, 0x1c, 0x62, 0x1c, 0x50, 0xd0, + 0x48, 0x1c, 0x00, 0x24, 0x0c, 0x28, 0x4c, 0xd8, 0x00, 0xf0, 0x00, 0xfc, + 0x07, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x1e, 0x0a, 0x0a, 0x0a, + 0x0a, 0x00, 0x01, 0x24, 0x64, 0x42, 0x40, 0xe0, 0x09, 0x29, 0x02, 0xd1, + 0x18, 0x1c, 0x00, 0x21, 0x03, 0xe0, 0x0a, 0x29, 0x04, 0xd1, 0x18, 0x1c, + 0x02, 0x21, 0xff, 0xf7, 0x51, 0xff, 0x23, 0xe0, 0x00, 0x24, 0x0b, 0x29, + 0x31, 0xd1, 0x18, 0x1c, 0x01, 0x21, 0xff, 0xf7, 0x49, 0xff, 0x2c, 0xe0, + 0x18, 0x22, 0x53, 0x43, 0xea, 0x18, 0x52, 0x68, 0xeb, 0x56, 0x01, 0x20, + 0x14, 0x1c, 0x04, 0x40, 0x55, 0x08, 0xdb, 0x01, 0x00, 0x2c, 0x11, 0xd0, + 0x12, 0x4c, 0x1b, 0x19, 0x5d, 0x19, 0x30, 0x35, 0x2e, 0x78, 0x0c, 0x01, + 0x0f, 0x21, 0x31, 0x40, 0x21, 0x43, 0x9a, 0x18, 0xc9, 0xb2, 0x29, 0x70, + 0x40, 0x32, 0x13, 0x78, 0x18, 0x43, 0x10, 0x70, 0x00, 0x24, 0x0e, 0xe0, + 0x09, 0x4e, 0x0f, 0x27, 0x9b, 0x19, 0x5d, 0x19, 0x30, 0x35, 0x2e, 0x78, + 0x9a, 0x18, 0xbe, 0x43, 0x31, 0x43, 0xc9, 0xb2, 0x29, 0x70, 0x40, 0x32, + 0x13, 0x78, 0x18, 0x43, 0x10, 0x70, 0x20, 0x1c, 0xf8, 0xbd, 0xc0, 0x46, + 0x20, 0x51, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0xf7, 0xb5, 0x8a, 0x18, + 0x06, 0x1c, 0x0d, 0x1c, 0x01, 0x92, 0x0c, 0x1c, 0x01, 0x9b, 0x67, 0x1b, + 0x9c, 0x42, 0x07, 0xd0, 0x33, 0x68, 0x21, 0x78, 0x1b, 0x68, 0x30, 0x1c, + 0x98, 0x47, 0x01, 0x34, 0x00, 0x28, 0xf3, 0xd1, 0x38, 0x1c, 0xfe, 0xbd, + 0x15, 0x4a, 0x13, 0x68, 0x58, 0x1c, 0x25, 0xd0, 0x01, 0x3b, 0x13, 0x60, + 0x00, 0x2b, 0x21, 0xd1, 0x72, 0xb6, 0x12, 0x4a, 0x12, 0x4b, 0x04, 0x32, + 0x9a, 0x42, 0x07, 0xd8, 0xbf, 0xf3, 0x4f, 0x8f, 0x10, 0x4a, 0x11, 0x4b, + 0xda, 0x60, 0xbf, 0xf3, 0x4f, 0x8f, 0x11, 0xe0, 0x0f, 0x4b, 0x19, 0x7d, + 0xc8, 0x07, 0xfb, 0xd5, 0x18, 0x8b, 0x20, 0x21, 0xff, 0x31, 0x92, 0x08, + 0x52, 0x00, 0x01, 0x43, 0x19, 0x83, 0xda, 0x61, 0x0a, 0x4a, 0x1a, 0x80, + 0x1a, 0x7d, 0xd1, 0x07, 0xfc, 0xd5, 0xe5, 0xe7, 0xc0, 0x46, 0xfd, 0xe7, + 0x70, 0x47, 0xc0, 0x46, 0x08, 0x00, 0x00, 0x20, 0x00, 0x20, 0x00, 0x00, + 0x03, 0x02, 0x00, 0x00, 0x04, 0x00, 0xfa, 0x05, 0x00, 0xed, 0x00, 0xe0, + 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, 0x01, 0x60, 0x70, 0x47, + 0xf7, 0xb5, 0x08, 0xac, 0x26, 0x78, 0x04, 0x68, 0x9d, 0x1e, 0x27, 0x68, + 0x6c, 0x1e, 0xa5, 0x41, 0xec, 0xb2, 0x92, 0x07, 0x05, 0x68, 0x3a, 0x43, + 0x27, 0x06, 0x3a, 0x43, 0x2a, 0x60, 0x02, 0x68, 0x07, 0x25, 0x29, 0x40, + 0x50, 0x68, 0xb5, 0x01, 0x00, 0x2c, 0x00, 0xd0, 0x5c, 0x03, 0x29, 0x43, + 0x01, 0x43, 0x0c, 0x43, 0x54, 0x60, 0xf7, 0xbd, 0x30, 0xb5, 0x03, 0x68, + 0xc0, 0x25, 0x1c, 0x68, 0xad, 0x03, 0x12, 0x05, 0x2a, 0x40, 0x22, 0x43, + 0xc0, 0x24, 0xa4, 0x02, 0x09, 0x04, 0x21, 0x40, 0x11, 0x43, 0x19, 0x60, + 0x03, 0x68, 0x5a, 0x68, 0x14, 0x43, 0x5c, 0x60, 0x30, 0xbd, 0x03, 0x68, + 0x01, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, 0x11, 0x68, + 0x01, 0x23, 0x19, 0x42, 0xfb, 0xd1, 0xd1, 0x69, 0x19, 0x42, 0xf8, 0xd1, + 0x70, 0x47, 0x03, 0x68, 0x02, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, + 0x02, 0x68, 0xd3, 0x69, 0x99, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, + 0x1a, 0x7e, 0xd1, 0x07, 0x02, 0xd4, 0x1a, 0x7e, 0x91, 0x07, 0xfc, 0xd5, + 0x70, 0x47, 0x03, 0x68, 0x00, 0x22, 0x5a, 0x83, 0x70, 0x47, 0x03, 0x68, + 0x18, 0x7e, 0x40, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, + 0xc0, 0x09, 0x70, 0x47, 0x03, 0x68, 0x80, 0x22, 0x19, 0x7e, 0x52, 0x42, + 0x0a, 0x43, 0x1a, 0x76, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x01, 0x23, + 0x18, 0x40, 0x70, 0x47, 0x03, 0x68, 0x18, 0x8d, 0xc0, 0xb2, 0x70, 0x47, + 0x03, 0x68, 0x1a, 0x7e, 0x01, 0x20, 0x02, 0x42, 0xfb, 0xd0, 0x19, 0x85, + 0x70, 0x47, 0x03, 0x68, 0x01, 0x21, 0x9a, 0x7d, 0x0a, 0x43, 0x9a, 0x75, + 0x70, 0x47, 0x03, 0x68, 0x01, 0x22, 0x1a, 0x75, 0x70, 0x47, 0x00, 0x00, + 0x70, 0xb5, 0x03, 0x68, 0x01, 0x26, 0x8d, 0x07, 0xed, 0x0f, 0x31, 0x40, + 0x1c, 0x68, 0x6d, 0x07, 0x09, 0x07, 0x29, 0x43, 0x21, 0x43, 0x19, 0x60, + 0x04, 0x68, 0x51, 0x00, 0x03, 0x48, 0x00, 0xf0, 0xd9, 0xfa, 0x01, 0x38, + 0xc0, 0xb2, 0x20, 0x73, 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x6c, 0xdc, 0x02, + 0x03, 0x68, 0x01, 0x21, 0x1a, 0x68, 0x0a, 0x43, 0x1a, 0x60, 0x02, 0x68, + 0x11, 0x68, 0x01, 0x23, 0x19, 0x42, 0xfb, 0xd1, 0xd1, 0x69, 0x19, 0x42, + 0xf8, 0xd1, 0x70, 0x47, 0x03, 0x68, 0x02, 0x21, 0x1a, 0x68, 0x0a, 0x43, + 0x1a, 0x60, 0x02, 0x68, 0xd3, 0x69, 0x99, 0x07, 0xfc, 0xd4, 0x70, 0x47, + 0x03, 0x68, 0xda, 0x69, 0x91, 0x07, 0xfc, 0xd4, 0x1a, 0x68, 0x02, 0x21, + 0x8a, 0x43, 0x1a, 0x60, 0x70, 0x47, 0x03, 0x68, 0x9a, 0x6a, 0x52, 0x0a, + 0x52, 0x02, 0x11, 0x43, 0x99, 0x62, 0x03, 0x68, 0x1a, 0x7e, 0x51, 0x07, + 0xfc, 0xd5, 0x98, 0x6a, 0xc0, 0xb2, 0x70, 0x47, 0x03, 0x68, 0x22, 0x4a, + 0x30, 0xb5, 0x93, 0x42, 0x11, 0xd0, 0x21, 0x4a, 0x93, 0x42, 0x11, 0xd0, + 0x20, 0x4a, 0x93, 0x42, 0x11, 0xd0, 0x20, 0x4a, 0x93, 0x42, 0x11, 0xd0, + 0x1f, 0x4a, 0x93, 0x42, 0x11, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x30, 0xd1, + 0x0e, 0x23, 0x19, 0x22, 0x0d, 0xe0, 0x09, 0x23, 0x14, 0x22, 0x0a, 0xe0, + 0x0a, 0x23, 0x15, 0x22, 0x07, 0xe0, 0x0b, 0x23, 0x16, 0x22, 0x04, 0xe0, + 0x0c, 0x23, 0x17, 0x22, 0x01, 0xe0, 0x0d, 0x23, 0x18, 0x22, 0xdc, 0xb2, + 0x15, 0x49, 0x01, 0x20, 0x9b, 0x08, 0xa0, 0x40, 0x9b, 0x00, 0x08, 0x60, + 0x5b, 0x18, 0x03, 0x20, 0xc0, 0x21, 0x89, 0x00, 0x04, 0x40, 0x5d, 0x58, + 0xe0, 0x00, 0xff, 0x24, 0x84, 0x40, 0xa5, 0x43, 0x2c, 0x1c, 0xc0, 0x25, + 0x85, 0x40, 0x28, 0x1c, 0x20, 0x43, 0x58, 0x50, 0x80, 0x23, 0xdb, 0x01, + 0x1a, 0x43, 0x0a, 0x4b, 0x5a, 0x80, 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, + 0xfb, 0xdb, 0x30, 0xbd, 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, + 0x00, 0x10, 0x00, 0x42, 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, + 0x00, 0x1c, 0x00, 0x42, 0x00, 0xe1, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x40, + 0xf8, 0xb5, 0x04, 0x1c, 0x15, 0x1c, 0x0e, 0x1c, 0x1f, 0x1c, 0xff, 0xf7, + 0xa3, 0xff, 0x20, 0x1c, 0xff, 0xf7, 0x0b, 0xff, 0xb1, 0x00, 0x1c, 0x22, + 0x0a, 0x40, 0x69, 0x07, 0x23, 0x68, 0x09, 0x0c, 0x0a, 0x43, 0x1a, 0x60, + 0x22, 0x68, 0x84, 0x23, 0x93, 0x75, 0x01, 0x2e, 0x1a, 0xd1, 0x08, 0x21, + 0x01, 0x2d, 0x00, 0xd1, 0x10, 0x21, 0x0c, 0x4b, 0x79, 0x43, 0x18, 0x68, + 0xc0, 0x00, 0x00, 0xf0, 0x2d, 0xfa, 0x23, 0x68, 0x07, 0x21, 0x9a, 0x89, + 0x01, 0x40, 0xd2, 0x04, 0x49, 0x03, 0xd2, 0x0c, 0x0a, 0x43, 0x9a, 0x81, + 0x23, 0x68, 0x00, 0x04, 0xc2, 0x0c, 0x98, 0x89, 0x40, 0x0b, 0x40, 0x03, + 0x10, 0x43, 0x98, 0x81, 0xf8, 0xbd, 0xc0, 0x46, 0x04, 0x00, 0x00, 0x20, + 0xf7, 0xb5, 0x01, 0x93, 0x08, 0xab, 0x04, 0x1c, 0x1f, 0x78, 0x0d, 0x1c, + 0x16, 0x1c, 0xff, 0xf7, 0x3d, 0xff, 0x20, 0x1c, 0xff, 0xf7, 0x68, 0xff, + 0xbf, 0x07, 0x0c, 0x22, 0x17, 0x43, 0xc0, 0x22, 0x92, 0x03, 0x36, 0x05, + 0x16, 0x40, 0xc0, 0x22, 0x92, 0x02, 0x2d, 0x04, 0x23, 0x68, 0x3e, 0x43, + 0x01, 0x99, 0x15, 0x40, 0x35, 0x43, 0x07, 0x22, 0x1d, 0x60, 0x0a, 0x40, + 0x80, 0x21, 0x23, 0x68, 0x89, 0x02, 0x0a, 0x43, 0x5a, 0x60, 0xf7, 0xbd, + 0x01, 0x20, 0x70, 0x47, 0x08, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, + 0x98, 0x47, 0x08, 0xbd, 0x13, 0x04, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x1c, + 0x00, 0x69, 0xff, 0xf7, 0xac, 0xfe, 0x20, 0x1c, 0x14, 0x30, 0x00, 0xf0, + 0xa1, 0xf9, 0x20, 0x1c, 0x5c, 0x30, 0x00, 0xf0, 0x9d, 0xf9, 0x10, 0xbd, + 0x08, 0xb5, 0x14, 0x30, 0x00, 0xf0, 0xaa, 0xf9, 0x08, 0xbd, 0x10, 0xb5, + 0x04, 0x1c, 0x20, 0x1c, 0x5c, 0x30, 0x00, 0xf0, 0xa3, 0xf9, 0x00, 0x28, + 0xf9, 0xd1, 0x20, 0x69, 0xff, 0xf7, 0xab, 0xfe, 0x10, 0xbd, 0x08, 0xb5, + 0x5c, 0x30, 0x00, 0xf0, 0x9f, 0xf9, 0x08, 0xbd, 0x70, 0xb5, 0x05, 0x1c, + 0x14, 0x35, 0x04, 0x1c, 0x28, 0x1c, 0x00, 0xf0, 0x83, 0xf9, 0x23, 0x1c, + 0xa8, 0x33, 0x1b, 0x78, 0x06, 0x1c, 0xff, 0x2b, 0x0a, 0xd0, 0x28, 0x1c, + 0x00, 0xf0, 0x8e, 0xf9, 0x0a, 0x28, 0x05, 0xdd, 0x23, 0x1c, 0xb0, 0x33, + 0xb4, 0x34, 0x1b, 0x68, 0x22, 0x68, 0x1a, 0x60, 0x30, 0x1c, 0x70, 0xbd, + 0x08, 0xb5, 0x14, 0x30, 0x00, 0xf0, 0x8a, 0xf9, 0x08, 0xbd, 0x70, 0xb5, + 0x04, 0x1c, 0x00, 0x69, 0x0e, 0x1c, 0xff, 0xf7, 0x9c, 0xfe, 0x25, 0x1c, + 0x5c, 0x35, 0x00, 0x28, 0x04, 0xd0, 0x28, 0x1c, 0x00, 0xf0, 0x6c, 0xf9, + 0x00, 0x28, 0x0c, 0xd0, 0x28, 0x1c, 0x00, 0xf0, 0x80, 0xf9, 0x00, 0x28, + 0xfa, 0xd1, 0x28, 0x1c, 0x31, 0x1c, 0x00, 0xf0, 0x44, 0xf9, 0x20, 0x69, + 0xff, 0xf7, 0x97, 0xfe, 0x03, 0xe0, 0x20, 0x69, 0x31, 0x1c, 0xff, 0xf7, + 0x8b, 0xfe, 0x01, 0x20, 0x70, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x85, 0xb0, + 0x1d, 0x1c, 0x0a, 0xab, 0x1b, 0x78, 0x04, 0x1c, 0x00, 0x93, 0x0b, 0xab, + 0x1b, 0x78, 0x16, 0x1c, 0x01, 0x93, 0x0c, 0xab, 0x1b, 0x78, 0x0f, 0x1c, + 0x02, 0x93, 0x0d, 0xab, 0x1b, 0x78, 0x03, 0x93, 0x00, 0x23, 0x43, 0x60, + 0xfa, 0x23, 0x9b, 0x00, 0x83, 0x60, 0x0d, 0x4b, 0x08, 0x33, 0x03, 0x60, + 0x14, 0x30, 0x00, 0xf0, 0x11, 0xf9, 0x20, 0x1c, 0x5c, 0x30, 0x00, 0xf0, + 0x0d, 0xf9, 0x00, 0x9a, 0x23, 0x1c, 0xa4, 0x33, 0x27, 0x61, 0x9a, 0x70, + 0x01, 0x9a, 0x20, 0x1c, 0xda, 0x70, 0x02, 0x9a, 0x1e, 0x70, 0x1a, 0x71, + 0x03, 0x9a, 0x5d, 0x70, 0x1a, 0x75, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, + 0x40, 0x55, 0x00, 0x00, 0x30, 0xb5, 0x85, 0xb0, 0x04, 0x1c, 0x08, 0xa8, + 0x05, 0x78, 0x09, 0xa8, 0x00, 0x78, 0x00, 0x95, 0x01, 0x90, 0xff, 0x20, + 0x02, 0x90, 0x03, 0x90, 0x20, 0x1c, 0xff, 0xf7, 0xbd, 0xff, 0x20, 0x1c, + 0x05, 0xb0, 0x30, 0xbd, 0x38, 0xb5, 0x04, 0x1c, 0x00, 0x69, 0xff, 0xf7, + 0x24, 0xfe, 0x00, 0x28, 0x19, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x34, 0xfe, + 0x25, 0x1c, 0x14, 0x35, 0x01, 0x1c, 0x28, 0x1c, 0x00, 0xf0, 0xe3, 0xf8, + 0x23, 0x1c, 0xa8, 0x33, 0x1b, 0x78, 0xff, 0x2b, 0x0b, 0xd0, 0x28, 0x1c, + 0x00, 0xf0, 0xfe, 0xf8, 0x09, 0x28, 0x06, 0xdc, 0x23, 0x1c, 0x22, 0x1c, + 0xac, 0x33, 0xb4, 0x32, 0x1b, 0x68, 0x12, 0x68, 0x1a, 0x60, 0x20, 0x69, + 0xff, 0xf7, 0x15, 0xfe, 0x00, 0x28, 0x11, 0xd0, 0x25, 0x1c, 0x5c, 0x35, + 0x28, 0x1c, 0x00, 0xf0, 0xe5, 0xf8, 0x00, 0x28, 0x07, 0xd0, 0x28, 0x1c, + 0x00, 0xf0, 0xd2, 0xf8, 0xc1, 0xb2, 0x20, 0x69, 0xff, 0xf7, 0x0e, 0xfe, + 0x02, 0xe0, 0x20, 0x69, 0xff, 0xf7, 0x17, 0xfe, 0x20, 0x69, 0xff, 0xf7, + 0xf3, 0xfd, 0x00, 0x28, 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0xf2, 0xfd, + 0x20, 0x69, 0xff, 0xf7, 0xe2, 0xfd, 0x38, 0xbd, 0xf0, 0x23, 0x08, 0x1c, + 0x18, 0x40, 0x30, 0x38, 0x43, 0x42, 0x58, 0x41, 0x70, 0x47, 0xf0, 0x23, + 0x1b, 0x01, 0x19, 0x40, 0x80, 0x23, 0x9b, 0x00, 0x99, 0x42, 0x0c, 0xd0, + 0xc0, 0x23, 0x9b, 0x00, 0x99, 0x42, 0x06, 0xd0, 0x80, 0x23, 0x5b, 0x00, + 0x05, 0x20, 0x99, 0x42, 0x04, 0xd0, 0x00, 0x20, 0x02, 0xe0, 0x07, 0x20, + 0x00, 0xe0, 0x06, 0x20, 0x70, 0x47, 0x0f, 0x23, 0x19, 0x40, 0x01, 0x29, + 0x05, 0xd0, 0x02, 0x39, 0x4b, 0x42, 0x4b, 0x41, 0x02, 0x20, 0xc0, 0x1a, + 0x00, 0xe0, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, 0xf0, 0xb5, 0x03, 0x1c, + 0x85, 0xb0, 0x03, 0x91, 0xa4, 0x33, 0x04, 0x1c, 0x18, 0x27, 0x18, 0x78, + 0x3b, 0x1c, 0x43, 0x43, 0x34, 0x4e, 0x08, 0x21, 0xf3, 0x18, 0x59, 0x56, + 0x15, 0x1c, 0xff, 0xf7, 0xa5, 0xfc, 0x23, 0x1c, 0xa5, 0x33, 0x18, 0x78, + 0x3b, 0x1c, 0x43, 0x43, 0x08, 0x21, 0xf3, 0x18, 0x59, 0x56, 0xff, 0xf7, + 0x9b, 0xfc, 0x23, 0x1c, 0xa7, 0x33, 0x1b, 0x78, 0x02, 0x2b, 0x0a, 0xd1, + 0x23, 0x1c, 0xb8, 0x33, 0x18, 0x78, 0xff, 0x28, 0x05, 0xd0, 0x47, 0x43, + 0x08, 0x21, 0xf7, 0x19, 0x79, 0x56, 0xff, 0xf7, 0x8b, 0xfc, 0x27, 0x1c, + 0xa8, 0x37, 0x38, 0x78, 0xff, 0x28, 0x1a, 0xd0, 0x01, 0x21, 0xff, 0xf7, + 0xf9, 0xfb, 0x3b, 0x78, 0x18, 0x22, 0x5a, 0x43, 0xb3, 0x56, 0x1f, 0x4f, + 0xdb, 0x01, 0x21, 0x1c, 0xac, 0x31, 0xd8, 0x19, 0x08, 0x60, 0x1d, 0x49, + 0xb6, 0x18, 0x5b, 0x18, 0x21, 0x1c, 0x72, 0x68, 0xb0, 0x31, 0x0b, 0x60, + 0x01, 0x21, 0x91, 0x40, 0x0a, 0x1c, 0x21, 0x1c, 0xb4, 0x31, 0x0a, 0x60, + 0x1a, 0x60, 0x01, 0x21, 0x0a, 0x1c, 0x03, 0x9b, 0x20, 0x69, 0xff, 0xf7, + 0x31, 0xfe, 0x29, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x88, 0xff, 0x29, 0x1c, + 0x07, 0x1c, 0x20, 0x1c, 0xff, 0xf7, 0x99, 0xff, 0x29, 0x1c, 0x06, 0x1c, + 0x20, 0x1c, 0xff, 0xf7, 0x77, 0xff, 0x39, 0x1c, 0x00, 0x90, 0x33, 0x1c, + 0x20, 0x69, 0x01, 0x22, 0xff, 0xf7, 0x02, 0xfd, 0x23, 0x1c, 0xa7, 0x33, + 0x19, 0x78, 0x01, 0x3b, 0x1a, 0x78, 0x20, 0x69, 0xff, 0xf7, 0x16, 0xfd, + 0x20, 0x69, 0xff, 0xf7, 0x34, 0xfd, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, + 0x20, 0x51, 0x00, 0x00, 0x18, 0x44, 0x00, 0x41, 0x14, 0x44, 0x00, 0x41, + 0x10, 0xb5, 0x00, 0x21, 0x40, 0x22, 0x04, 0x1c, 0x00, 0xf0, 0xf2, 0xf8, + 0x00, 0x23, 0x20, 0x1c, 0x23, 0x64, 0x63, 0x64, 0x10, 0xbd, 0x02, 0x6c, + 0x10, 0xb5, 0x3f, 0x23, 0x54, 0x1c, 0x23, 0x40, 0x44, 0x6c, 0xa3, 0x42, + 0x01, 0xd0, 0x81, 0x54, 0x03, 0x64, 0x10, 0xbd, 0x00, 0x23, 0x03, 0x64, + 0x43, 0x64, 0x70, 0x47, 0x43, 0x6c, 0x02, 0x6c, 0x93, 0x42, 0x06, 0xd0, + 0xc2, 0x5c, 0x3f, 0x21, 0x01, 0x33, 0x0b, 0x40, 0x43, 0x64, 0x10, 0x1c, + 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x70, 0x47, 0x02, 0x6c, 0x43, 0x6c, + 0xd0, 0x1a, 0x00, 0xd5, 0x40, 0x30, 0x70, 0x47, 0x03, 0x6c, 0x40, 0x6c, + 0x83, 0x42, 0x02, 0xdb, 0xc0, 0x1a, 0x3f, 0x30, 0x01, 0xe0, 0xc0, 0x1a, + 0x01, 0x38, 0x70, 0x47, 0x43, 0x6c, 0x02, 0x6c, 0x93, 0x42, 0x01, 0xd0, + 0xc0, 0x5c, 0x01, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x70, 0x47, 0x02, 0x6c, + 0x3f, 0x23, 0x01, 0x32, 0x1a, 0x40, 0x43, 0x6c, 0xd0, 0x1a, 0x43, 0x42, + 0x58, 0x41, 0xc0, 0xb2, 0x70, 0x47, 0x00, 0x00, 0x02, 0xb4, 0x71, 0x46, + 0x49, 0x08, 0x49, 0x00, 0x09, 0x5c, 0x49, 0x00, 0x8e, 0x44, 0x02, 0xbc, + 0x70, 0x47, 0xc0, 0x46, 0x00, 0x29, 0x34, 0xd0, 0x01, 0x23, 0x00, 0x22, + 0x10, 0xb4, 0x88, 0x42, 0x2c, 0xd3, 0x01, 0x24, 0x24, 0x07, 0xa1, 0x42, + 0x04, 0xd2, 0x81, 0x42, 0x02, 0xd2, 0x09, 0x01, 0x1b, 0x01, 0xf8, 0xe7, + 0xe4, 0x00, 0xa1, 0x42, 0x04, 0xd2, 0x81, 0x42, 0x02, 0xd2, 0x49, 0x00, + 0x5b, 0x00, 0xf8, 0xe7, 0x88, 0x42, 0x01, 0xd3, 0x40, 0x1a, 0x1a, 0x43, + 0x4c, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, 0x5c, 0x08, 0x22, 0x43, + 0x8c, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, 0x9c, 0x08, 0x22, 0x43, + 0xcc, 0x08, 0xa0, 0x42, 0x02, 0xd3, 0x00, 0x1b, 0xdc, 0x08, 0x22, 0x43, + 0x00, 0x28, 0x03, 0xd0, 0x1b, 0x09, 0x01, 0xd0, 0x09, 0x09, 0xe3, 0xe7, + 0x10, 0x1c, 0x10, 0xbc, 0x70, 0x47, 0x00, 0x28, 0x01, 0xd0, 0x00, 0x20, + 0xc0, 0x43, 0x07, 0xb4, 0x02, 0x48, 0x02, 0xa1, 0x40, 0x18, 0x02, 0x90, + 0x03, 0xbd, 0xc0, 0x46, 0x19, 0x00, 0x00, 0x00, 0x00, 0x29, 0xf0, 0xd0, + 0x03, 0xb5, 0xff, 0xf7, 0xb9, 0xff, 0x0e, 0xbc, 0x42, 0x43, 0x89, 0x1a, + 0x18, 0x47, 0xc0, 0x46, 0x70, 0x47, 0xc0, 0x46, 0x70, 0xb5, 0x0e, 0x4b, + 0x0e, 0x4d, 0x00, 0x24, 0xed, 0x1a, 0xad, 0x10, 0x1e, 0x1c, 0xac, 0x42, + 0x04, 0xd0, 0xa3, 0x00, 0xf3, 0x58, 0x98, 0x47, 0x01, 0x34, 0xf8, 0xe7, + 0x00, 0xf0, 0x32, 0xf9, 0x08, 0x4b, 0x09, 0x4d, 0x00, 0x24, 0xed, 0x1a, + 0xad, 0x10, 0x1e, 0x1c, 0xac, 0x42, 0x04, 0xd0, 0xa3, 0x00, 0xf3, 0x58, + 0x98, 0x47, 0x01, 0x34, 0xf8, 0xe7, 0x70, 0xbd, 0x70, 0x00, 0x00, 0x20, + 0x70, 0x00, 0x00, 0x20, 0x70, 0x00, 0x00, 0x20, 0x8c, 0x00, 0x00, 0x20, + 0x08, 0xb5, 0x03, 0x4b, 0x01, 0x1c, 0x18, 0x68, 0x00, 0xf0, 0x76, 0xf8, + 0x08, 0xbd, 0xc0, 0x46, 0x6c, 0x00, 0x00, 0x20, 0x08, 0xb5, 0x03, 0x4b, + 0x01, 0x1c, 0x18, 0x68, 0x00, 0xf0, 0x24, 0xf8, 0x08, 0xbd, 0xc0, 0x46, + 0x6c, 0x00, 0x00, 0x20, 0x30, 0xb5, 0x00, 0x23, 0x93, 0x42, 0x08, 0xd0, + 0xc5, 0x5c, 0x01, 0x33, 0xcc, 0x18, 0x01, 0x3c, 0x24, 0x78, 0xa5, 0x42, + 0xf6, 0xd0, 0x28, 0x1b, 0x00, 0xe0, 0x00, 0x20, 0x30, 0xbd, 0x10, 0xb5, + 0x00, 0x23, 0x93, 0x42, 0x03, 0xd0, 0xcc, 0x5c, 0xc4, 0x54, 0x01, 0x33, + 0xf9, 0xe7, 0x10, 0xbd, 0x03, 0x1c, 0x82, 0x18, 0x93, 0x42, 0x02, 0xd0, + 0x19, 0x70, 0x01, 0x33, 0xfa, 0xe7, 0x70, 0x47, 0x30, 0xb5, 0x00, 0x29, + 0x40, 0xd0, 0x04, 0x39, 0x0b, 0x68, 0x00, 0x2b, 0x00, 0xda, 0xc9, 0x18, + 0x1e, 0x4a, 0x13, 0x68, 0x14, 0x1c, 0x00, 0x2b, 0x02, 0xd1, 0x4b, 0x60, + 0x11, 0x60, 0x33, 0xe0, 0x99, 0x42, 0x0f, 0xd2, 0x08, 0x68, 0x0a, 0x18, + 0x9a, 0x42, 0x05, 0xd1, 0x13, 0x68, 0x52, 0x68, 0xc0, 0x18, 0x08, 0x60, + 0x4a, 0x60, 0x00, 0xe0, 0x4b, 0x60, 0x21, 0x60, 0x24, 0xe0, 0x8a, 0x42, + 0x03, 0xd8, 0x13, 0x1c, 0x5a, 0x68, 0x00, 0x2a, 0xf9, 0xd1, 0x1d, 0x68, + 0x5c, 0x19, 0x8c, 0x42, 0x0b, 0xd1, 0x09, 0x68, 0x69, 0x18, 0x58, 0x18, + 0x19, 0x60, 0x90, 0x42, 0x14, 0xd1, 0x14, 0x68, 0x52, 0x68, 0x09, 0x19, + 0x19, 0x60, 0x5a, 0x60, 0x0e, 0xe0, 0x8c, 0x42, 0x02, 0xd9, 0x0c, 0x23, + 0x03, 0x60, 0x09, 0xe0, 0x08, 0x68, 0x0c, 0x18, 0x94, 0x42, 0x03, 0xd1, + 0x14, 0x68, 0x52, 0x68, 0x00, 0x19, 0x08, 0x60, 0x4a, 0x60, 0x59, 0x60, + 0x30, 0xbd, 0xc0, 0x46, 0x24, 0x09, 0x00, 0x20, 0x70, 0xb5, 0x03, 0x23, + 0xcd, 0x1c, 0x9d, 0x43, 0x08, 0x35, 0x06, 0x1c, 0x0c, 0x2d, 0x01, 0xd2, + 0x0c, 0x25, 0x01, 0xe0, 0x00, 0x2d, 0x3f, 0xdb, 0x8d, 0x42, 0x3d, 0xd3, + 0x20, 0x4b, 0x1c, 0x68, 0x1a, 0x1c, 0x21, 0x1c, 0x00, 0x29, 0x13, 0xd0, + 0x08, 0x68, 0x43, 0x1b, 0x0d, 0xd4, 0x0b, 0x2b, 0x02, 0xd9, 0x0b, 0x60, + 0xcc, 0x18, 0x1e, 0xe0, 0x8c, 0x42, 0x02, 0xd1, 0x63, 0x68, 0x13, 0x60, + 0x1a, 0xe0, 0x48, 0x68, 0x60, 0x60, 0x0c, 0x1c, 0x16, 0xe0, 0x0c, 0x1c, + 0x49, 0x68, 0xe9, 0xe7, 0x14, 0x4c, 0x20, 0x68, 0x00, 0x28, 0x03, 0xd1, + 0x30, 0x1c, 0x00, 0xf0, 0x25, 0xf8, 0x20, 0x60, 0x30, 0x1c, 0x29, 0x1c, + 0x00, 0xf0, 0x20, 0xf8, 0x43, 0x1c, 0x15, 0xd0, 0xc4, 0x1c, 0x03, 0x23, + 0x9c, 0x43, 0x84, 0x42, 0x0a, 0xd1, 0x25, 0x60, 0x20, 0x1c, 0x0b, 0x30, + 0x07, 0x22, 0x23, 0x1d, 0x90, 0x43, 0xc3, 0x1a, 0x0b, 0xd0, 0x5a, 0x42, + 0xe2, 0x50, 0x08, 0xe0, 0x21, 0x1a, 0x30, 0x1c, 0x00, 0xf0, 0x0a, 0xf8, + 0x01, 0x30, 0xee, 0xd1, 0x0c, 0x23, 0x33, 0x60, 0x00, 0x20, 0x70, 0xbd, + 0x24, 0x09, 0x00, 0x20, 0x20, 0x09, 0x00, 0x20, 0x38, 0xb5, 0x07, 0x4c, + 0x00, 0x23, 0x05, 0x1c, 0x08, 0x1c, 0x23, 0x60, 0x00, 0xf0, 0x2a, 0xf8, + 0x43, 0x1c, 0x03, 0xd1, 0x23, 0x68, 0x00, 0x2b, 0x00, 0xd0, 0x2b, 0x60, + 0x38, 0xbd, 0xc0, 0x46, 0x2c, 0x09, 0x00, 0x20, 0xc9, 0xb2, 0x03, 0x78, + 0x00, 0x2b, 0x03, 0xd0, 0x8b, 0x42, 0x04, 0xd0, 0x01, 0x30, 0xf8, 0xe7, + 0x00, 0x29, 0x00, 0xd0, 0x18, 0x1c, 0x70, 0x47, 0x30, 0xb5, 0x03, 0x1c, + 0x00, 0x2a, 0x07, 0xd0, 0x0c, 0x78, 0x01, 0x33, 0x5d, 0x1e, 0x01, 0x3a, + 0x2c, 0x70, 0x01, 0x31, 0x00, 0x2c, 0xf5, 0xd1, 0x9a, 0x18, 0x93, 0x42, + 0x03, 0xd0, 0x00, 0x21, 0x19, 0x70, 0x01, 0x33, 0xf9, 0xe7, 0x30, 0xbd, + 0x09, 0x4a, 0x13, 0x68, 0x00, 0x2b, 0x0c, 0xd0, 0x18, 0x18, 0x69, 0x46, + 0x88, 0x42, 0x02, 0xd8, 0x10, 0x60, 0x18, 0x1c, 0x70, 0x47, 0x05, 0x4b, + 0x0c, 0x22, 0x01, 0x20, 0x1a, 0x60, 0x40, 0x42, 0xf8, 0xe7, 0x03, 0x4b, + 0x13, 0x60, 0xef, 0xe7, 0x28, 0x09, 0x00, 0x20, 0x2c, 0x09, 0x00, 0x20, + 0x30, 0x09, 0x00, 0x20, 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, + 0x9e, 0x46, 0x70, 0x47, 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, + 0x9e, 0x46, 0x70, 0x47, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x2e, 0x42, + 0x49, 0x4e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x1f, 0x22, 0x00, 0x00, 0x33, 0x22, 0x00, 0x00, 0x19, 0x22, 0x00, 0x00, + 0x5d, 0x22, 0x00, 0x00, 0x61, 0x23, 0x00, 0x00, 0x8d, 0x22, 0x00, 0x00, + 0xa1, 0x22, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x2f, 0x00, 0x7c, 0x3c, + 0x3e, 0x5e, 0x2b, 0x3d, 0x3f, 0x2f, 0x5b, 0x5d, 0x3b, 0x2c, 0x2a, 0x22, + 0x5c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x01, 0x34, 0x00, 0x00, 0xc1, 0x40, 0x00, 0x00, + 0x19, 0x22, 0x00, 0x00, 0x1d, 0x22, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x20, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, + 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x0b, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x0a, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x0e, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x00, 0x01, 0x00, 0x09, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x03, 0x01, 0x03, 0x0f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x02, 0x00, 0x02, 0x00, 0x04, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, 0x03, 0x00, 0x05, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x01, 0x00, 0x01, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x01, 0x01, 0x01, 0x07, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x03, 0x00, 0x03, 0x02, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x02, 0x00, 0x02, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, 0x03, 0x00, 0x03, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x02, 0x01, 0x02, 0x01, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0x02, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x18, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x04, 0x00, 0x04, 0x08, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x18, 0x00, 0x00, 0x00, 0x03, 0x00, 0x01, 0x04, 0x01, 0x04, 0x09, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0xff, 0xff, 0xff, 0xff, 0x04, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0xff, 0xff, 0xff, 0xff, 0x05, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0xff, 0xff, 0xff, 0xff, 0x02, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x0c, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x0a, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x0b, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x0c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x00, 0xff, 0xff, 0x0d, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x0c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x0c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x01, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x0c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x14, 0x00, 0xff, 0xff, 0xff, 0xff, 0x02, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe3, 0x44, 0x00, 0x00, + 0xc1, 0x40, 0x00, 0x00, 0x9b, 0x44, 0x00, 0x00, 0x83, 0x44, 0x00, 0x00, + 0x79, 0x44, 0x00, 0x00, 0xa5, 0x44, 0x00, 0x00, 0xd9, 0x44, 0x00, 0x00, + 0x4d, 0x44, 0x00, 0x00, 0x91, 0x46, 0x00, 0x00, 0x5d, 0x44, 0x00, 0x00, + 0x49, 0x44, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0x40, 0x42, 0x0f, 0x00, + 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x7c, 0x55, 0x00, 0x00, + 0x9c, 0x55, 0x00, 0x00, 0xbc, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x78, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x20, 0xdd, 0x20, 0x00, 0x00, + 0x05, 0x22, 0x00, 0x00, 0xed, 0x26, 0x00, 0x00, 0xa9, 0x2b, 0x00, 0x00, + 0x55, 0x38, 0x00, 0x00, 0x85, 0x3a, 0x00, 0x00, 0xdd, 0x3a, 0x00, 0x00, + 0xb5, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 diff --git a/libraries/SFU/examples/SFU_LoadBinary/Binary.h b/libraries/SFU/examples/SFU_LoadBinary/Binary.h new file mode 100644 index 0000000..e69de29 diff --git a/libraries/SFU/examples/SFU_LoadBinary/SFU_LoadBinary.ino b/libraries/SFU/examples/SFU_LoadBinary/SFU_LoadBinary.ino new file mode 100644 index 0000000..1b2754c --- /dev/null +++ b/libraries/SFU/examples/SFU_LoadBinary/SFU_LoadBinary.ino @@ -0,0 +1,63 @@ +/************************************************************************************** + * INCLUDE + **************************************************************************************/ + +#include + +/************************************************************************************** + * CONSTANTS + **************************************************************************************/ + +static uint8_t const BINARY[] = +{ + #include "Binary.h" +}; + +/************************************************************************************** + * SETUP/LOOP + **************************************************************************************/ + +void setup() { + Serial.begin(9600); + + unsigned long const start = millis(); + for(unsigned long now = millis(); !Serial && ((now - start) < 5000); now = millis()) { }; + + flash.begin(); + + Serial.print("Mounting ... "); + if(SPIFFS_OK != filesystem.mount()) { + Serial.println("mount() failed with error code "); Serial.println(filesystem.err()); return; + } + Serial.println("OK"); + + + Serial.print("Checking ... "); + if(SPIFFS_OK != filesystem.check()) { + Serial.println("check() failed with error code "); Serial.println(filesystem.err()); return; + } + Serial.println("OK"); + + + Serial.print("Writing \"UPDATE.BIN\" ... "); + File file = filesystem.open("UPDATE.BIN", CREATE | READ_WRITE| TRUNCATE); + + int const bytes_to_write = sizeof(BINARY); + int const bytes_written = file.write((void *)BINARY, bytes_to_write); + + if(bytes_written != bytes_to_write) { + Serial.println("write() failed with error code "); Serial.println(filesystem.err()); return; + } else { + Serial.print("OK ("); + Serial.print(bytes_written); + Serial.println(" bytes written)"); + } + + Serial.print("Unmounting ... "); + filesystem.unmount(); + Serial.println("OK"); +} + +void loop() { + +} diff --git a/libraries/SFU/examples/SFU_Usage/SFU_Usage.ino b/libraries/SFU/examples/SFU_Usage/SFU_Usage.ino new file mode 100644 index 0000000..db6efd1 --- /dev/null +++ b/libraries/SFU/examples/SFU_Usage/SFU_Usage.ino @@ -0,0 +1,54 @@ +/* + Usage + This example demonstrates how to use the SAMD SFU library to update a + sketch on any Arduino MKR board connected to a MKRMEM Shield. This sketch + prints out the date and time the sketch was compiled. + + Steps to update sketch via MKRMEM shield: + + 1) Upload this sketch or another sketch that includes the SFU library + via #include + + 2) Update the sketch as desired. For this example the sketch prints out + the compiled date and time so no updates are needed. + + 3) In the IDE select: Sketch -> Export compiled Binary + + 4) Open the location of the sketch and convert the .bin file to a C byte array. + cat SKETCH.bin | xxd --include > Binary.h + + 5) Copy Binary.h file from the sketch's folder to the SFU_LoadBinary sketch + and load it to the MKRMEM via SFU_LoadBinary sketch. +*/ + +/* + Include the SFU library + + This will add some code to the sketch before setup() is called + to check if UPDATE.bin is present on the flash chip of the MKRMEM + shield. If this theck is positive the file is used to update the sketch + running on the board. After this UPDATE.BIN is deleted from the flash. +*/ + +#include + +void setup() { + Serial.begin(9600); + while(!Serial) { } + + // wait a bit + delay(1000); + + String message; + message += "Sketch compile date and time: "; + message += __DATE__; + message += " "; + message += __TIME__; + + // print out the sketch compile date and time on the serial port + Serial.println(message); +} + +void loop() { + // add you own code here +} diff --git a/libraries/SFU/extras/SFUBoot/SFUBoot.ino b/libraries/SFU/extras/SFUBoot/SFUBoot.ino new file mode 100644 index 0000000..e63cd16 --- /dev/null +++ b/libraries/SFU/extras/SFUBoot/SFUBoot.ino @@ -0,0 +1,115 @@ +/* + Copyright (c) 2020 Arduino LLC. 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 +*/ + +/************************************************************************************** + * INCLUDE + **************************************************************************************/ + +#include +#include + +/************************************************************************************** + * DEFINE + **************************************************************************************/ + +#define SFU_START 0x2000 +#define SFU_SIZE 0x8000 + +#define SKETCH_START (uint32_t*)(SFU_START + SFU_SIZE) + +/************************************************************************************** + * GLOBAL CONSTANTS + **************************************************************************************/ + +static char const UPDATE_FILE_NAME[] = "UPDATE.BIN"; + +/************************************************************************************** + * GLOBAL VARIABLES + **************************************************************************************/ + +FlashClass mcu_flash; + +/************************************************************************************** + * FUNCTION DECLARATION + **************************************************************************************/ + +extern "C" void __libc_init_array(void); + +/************************************************************************************** + * MAIN + **************************************************************************************/ + +int main() +{ + init(); + + __libc_init_array(); + + delay(1); + + /* Initialize W25Q16DV flash chip found on Arduino MKRMEM Shield */ + flash.begin(); + + /* Mount and verify filesystem */ + if ((SPIFFS_OK == filesystem.mount()) && (SPIFFS_OK == filesystem.check())) + { + /* Open update file */ + filesystem.clearerr(); + File file = filesystem.open(UPDATE_FILE_NAME, READ_ONLY); + if(SPIFFS_OK == filesystem.err()) + { + bool update_success = false; + /* Determine the size of the update file */ + int file_size = file.lseek(0, END); + if (file_size > SFU_SIZE) + { + /* Skip the SFU section */ + file.lseek(SFU_SIZE, START); + file_size -= SFU_SIZE; + + /* Erase the MCU flash */ + uint32_t flash_address = (uint32_t)SKETCH_START; + mcu_flash.erase((void*)flash_address, file_size); + + /* Write the MCU flash */ + uint8_t buffer[512]; + for (int b = 0; b < file_size; b += sizeof(buffer)) + { + file.read(buffer, sizeof(buffer)); + mcu_flash.write((void*)flash_address, buffer, sizeof(buffer)); + flash_address += sizeof(buffer); + } + update_success = true; + } + file.close(); + if (update_success) { filesystem.remove(UPDATE_FILE_NAME); } + filesystem.unmount(); + } + } + + /* Jump to the sketch */ + __set_MSP(*SKETCH_START); + + /* Reset vector table address */ + SCB->VTOR = ((uint32_t)(SKETCH_START) & SCB_VTOR_TBLOFF_Msk); + + /* Address of Reset_Handler is written by the linker at the beginning of the .text section (see linker script) */ + uint32_t resetHandlerAddress = (uint32_t) * (SKETCH_START + 1); + /* Jump to reset handler */ + asm("bx %0"::"r"(resetHandlerAddress)); +} diff --git a/libraries/SFU/extras/SFUBoot/build.sh b/libraries/SFU/extras/SFUBoot/build.sh new file mode 100755 index 0000000..d9fb74c --- /dev/null +++ b/libraries/SFU/extras/SFUBoot/build.sh @@ -0,0 +1,31 @@ +#!/bin/sh -x + +ARDUINO=arduino +SKETCH_NAME="SFUBoot.ino" +SKETCH="$PWD/$SKETCH_NAME" +BUILD_PATH="$PWD/build" +OUTPUT_PATH="../../src/boot" + +if [[ "$OSTYPE" == "darwin"* ]]; then + ARDUINO="/Applications/Arduino.app/Contents/MacOS/Arduino" +fi + +buildSFUBootSketch() { + BOARD=$1 + DESTINATION=$2 + + $ARDUINO --verify --board $BOARD --preserve-temp-files --pref build.path="$BUILD_PATH" $SKETCH + cat "$BUILD_PATH/$SKETCH_NAME.bin" | xxd -include > $DESTINATION + rm -rf "$BUILD_PATH" +} + +mkdir -p "$OUTPUT_PATH" + +buildSFUBootSketch "arduino:samd:mkrzero" "$OUTPUT_PATH/mkrzero.h" +buildSFUBootSketch "arduino:samd:mkr1000" "$OUTPUT_PATH/mkr1000.h" +buildSFUBootSketch "arduino:samd:mkrwifi1010" "$OUTPUT_PATH/mkrwifi1010.h" +buildSFUBootSketch "arduino:samd:mkrgsm1400" "$OUTPUT_PATH/mkrgsm1400.h" +buildSFUBootSketch "arduino:samd:mkrnb1500" "$OUTPUT_PATH/mkrnb1500.h" +buildSFUBootSketch "arduino:samd:mkrvidor4000" "$OUTPUT_PATH/mkrvidor4000.h" +buildSFUBootSketch "arduino:samd:mkrwan1310" "$OUTPUT_PATH/mkrwan1310.h" +buildSFUBootSketch "arduino:samd:mkrfox1200" "$OUTPUT_PATH/mkrfox1200.h" diff --git a/libraries/SFU/keywords.txt b/libraries/SFU/keywords.txt new file mode 100644 index 0000000..58fa772 --- /dev/null +++ b/libraries/SFU/keywords.txt @@ -0,0 +1,17 @@ +####################################### +# Syntax Coloring Map For SDU +####################################### + +####################################### +# Datatypes (KEYWORD1) +####################################### + +SFU KEYWORD1 + +####################################### +# Methods and Functions (KEYWORD2) +####################################### + +####################################### +# Constants (LITERAL1) +####################################### diff --git a/libraries/SFU/library.properties b/libraries/SFU/library.properties new file mode 100644 index 0000000..45ab3b2 --- /dev/null +++ b/libraries/SFU/library.properties @@ -0,0 +1,9 @@ +name=SFU +version=1.0.0 +author=Arduino +maintainer=Arduino +sentence=Update the sketch on your board from a Arduino MKRMEM Shield. +paragraph=Requires a Arduino MKRMEM Shield. +category=Other +url=https://www.arduino.cc/en/Reference/SFU +architectures=samd diff --git a/libraries/SFU/src/SFU.cpp b/libraries/SFU/src/SFU.cpp new file mode 100644 index 0000000..d51d94c --- /dev/null +++ b/libraries/SFU/src/SFU.cpp @@ -0,0 +1,44 @@ +/* + Copyright (c) 2020 Arduino LLC. 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 +*/ + +#include + +#include "SFU.h" + +__attribute__ ((section(".sketch_boot"))) +unsigned char SFU_BOOT[0x8000] = { +#if defined(ARDUINO_SAMD_MKRZERO) + #include "boot/mkrzero.h" +#elif defined(ARDUINO_SAMD_MKR1000) + #include "boot/mkr1000.h" +#elif defined(ARDUINO_SAMD_MKRWIFI1010) + #include "boot/mkrwifi1010.h" +#elif defined(ARDUINO_SAMD_MKRGSM1400) + #include "boot/mkrgsm1400.h" +#elif defined(ARDUINO_SAMD_MKRNB1500) + #include "boot/mkrnb1500.h" +#elif defined(ARDUINO_SAMD_MKRVIDOR4000) + #include "boot/mkrvidor4000.h" +#elif defined(ARDUINO_SAMD_MKRWAN1310) + #include "boot/mkrwan1310.h" +#elif defined(ARDUINO_SAMD_MKRFOX1200) + #include "boot/mkrfox1200.h" +#else + #error "Unsupported board!" +#endif +}; diff --git a/libraries/SFU/src/SFU.h b/libraries/SFU/src/SFU.h new file mode 100644 index 0000000..1aca0e2 --- /dev/null +++ b/libraries/SFU/src/SFU.h @@ -0,0 +1,24 @@ +/* + Copyright (c) 2020 Arduino LLC. 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 _SFU_H_INCLUDED +#define _SFU_H_INCLUDED + +/* Nothing to do */ + +#endif /* _SFU_H_INCLUDED */ diff --git a/libraries/SFU/src/boot/mkr1000.h b/libraries/SFU/src/boot/mkr1000.h new file mode 100644 index 0000000..6518992 --- /dev/null +++ b/libraries/SFU/src/boot/mkr1000.h @@ -0,0 +1,2174 @@ + 0x00, 0x80, 0x00, 0x20, 0x9d, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0xf1, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0xa5, 0x6c, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0x30, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xb4, 0x85, 0x00, 0x00, 0x04, 0x4b, 0x10, 0xb5, 0x00, 0x2b, 0x03, 0xd0, + 0x03, 0x49, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x10, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x00, 0x34, 0x00, 0x00, 0x20, 0xb4, 0x85, 0x00, 0x00, + 0xf0, 0xb5, 0x40, 0x4c, 0xa5, 0x44, 0x00, 0xaf, 0x05, 0xf0, 0x02, 0xfb, + 0x05, 0xf0, 0x68, 0xfd, 0x01, 0x20, 0x05, 0xf0, 0x27, 0xfa, 0x3c, 0x48, + 0x00, 0xf0, 0x8c, 0xf9, 0x3b, 0x4c, 0x20, 0x00, 0x00, 0xf0, 0x1c, 0xf9, + 0x00, 0x28, 0x5d, 0xd1, 0x20, 0x00, 0x02, 0xf0, 0x29, 0xfb, 0x00, 0x28, + 0x58, 0xd1, 0x20, 0x00, 0x02, 0xf0, 0x44, 0xf9, 0x0c, 0x20, 0x08, 0x23, + 0x34, 0x4a, 0x21, 0x00, 0x38, 0x18, 0x00, 0xf0, 0x23, 0xf9, 0x20, 0x00, + 0x02, 0xf0, 0x38, 0xf9, 0x05, 0x1e, 0x45, 0xd1, 0x0c, 0x23, 0x01, 0x00, + 0x02, 0x22, 0xf8, 0x18, 0x00, 0xf0, 0x42, 0xf9, 0x80, 0x21, 0x78, 0x60, + 0x09, 0x02, 0x2e, 0x00, 0x88, 0x42, 0x2c, 0xdd, 0x0c, 0x23, 0x2a, 0x00, + 0xf8, 0x18, 0x00, 0xf0, 0x37, 0xf9, 0x28, 0x4a, 0xa0, 0x21, 0x94, 0x46, + 0x7b, 0x68, 0x09, 0x02, 0x63, 0x44, 0x1a, 0x00, 0x25, 0x48, 0xa0, 0x25, + 0x80, 0x26, 0x7b, 0x60, 0x00, 0xf0, 0xd6, 0xf8, 0x2d, 0x02, 0xb6, 0x00, + 0x08, 0x23, 0xf8, 0x18, 0xc1, 0x18, 0x04, 0x33, 0x32, 0x00, 0xf8, 0x18, + 0x00, 0xf0, 0x14, 0xf9, 0x08, 0x22, 0xb9, 0x18, 0x8a, 0x18, 0x33, 0x00, + 0x29, 0x00, 0x1b, 0x48, 0x00, 0xf0, 0x74, 0xf8, 0x80, 0x22, 0x1a, 0x4b, + 0x92, 0x00, 0xeb, 0x18, 0xad, 0x18, 0x7a, 0x68, 0x93, 0x42, 0xe7, 0xdb, + 0x01, 0x26, 0x0c, 0x23, 0xf8, 0x18, 0x00, 0xf0, 0x17, 0xf9, 0x00, 0x2e, + 0x03, 0xd0, 0x10, 0x49, 0x20, 0x00, 0x02, 0xf0, 0x55, 0xfa, 0x20, 0x00, + 0x02, 0xf0, 0xca, 0xf8, 0x0c, 0x23, 0xf8, 0x18, 0x00, 0xf0, 0x14, 0xf9, + 0xa0, 0x23, 0x1b, 0x02, 0x1a, 0x68, 0x82, 0xf3, 0x08, 0x88, 0x0c, 0x4a, + 0x93, 0x60, 0x0c, 0x4b, 0x1b, 0x68, 0x18, 0x47, 0x00, 0x20, 0xbd, 0x46, + 0x85, 0x23, 0x9b, 0x00, 0x9d, 0x44, 0xf0, 0xbd, 0xec, 0xfd, 0xff, 0xff, + 0xf4, 0x0b, 0x00, 0x20, 0x8c, 0x04, 0x00, 0x20, 0xa8, 0x7c, 0x00, 0x00, + 0x00, 0x80, 0xff, 0xff, 0x4c, 0x00, 0x00, 0x20, 0x00, 0x62, 0xff, 0xff, + 0x00, 0xed, 0x00, 0xe0, 0x04, 0xa0, 0x00, 0x00, 0x00, 0x22, 0x10, 0xb5, + 0x11, 0x00, 0x02, 0x48, 0x00, 0xf0, 0x1a, 0xf8, 0x10, 0xbd, 0xc0, 0x46, + 0x4c, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x05, 0x4a, 0x05, 0x49, 0x06, 0x48, + 0x00, 0xf0, 0x10, 0xf8, 0x00, 0x22, 0x05, 0x4b, 0x05, 0x49, 0x1a, 0x70, + 0x5a, 0x54, 0x10, 0xbd, 0x01, 0x04, 0x00, 0x00, 0x00, 0x7d, 0x00, 0x00, + 0x68, 0x04, 0x00, 0x20, 0x64, 0x00, 0x00, 0x20, 0x02, 0x04, 0x00, 0x00, + 0x30, 0xb5, 0x09, 0x4d, 0x09, 0x4c, 0xab, 0x68, 0x5b, 0x03, 0x5b, 0x0f, + 0x9b, 0x00, 0x1c, 0x59, 0x04, 0x60, 0xab, 0x68, 0x01, 0x61, 0x9b, 0xb2, + 0x43, 0x60, 0x63, 0x43, 0xa4, 0x00, 0x83, 0x60, 0xc4, 0x60, 0x42, 0x61, + 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, 0x00, 0x82, 0x00, 0x00, + 0xf7, 0xb5, 0x80, 0x26, 0x1a, 0x4d, 0x01, 0x91, 0x6f, 0x68, 0x03, 0x33, + 0x3e, 0x43, 0x9b, 0x08, 0x6e, 0x60, 0x00, 0x2b, 0x2b, 0xd0, 0x17, 0x4e, + 0x2e, 0x80, 0x2e, 0x7d, 0xf1, 0x07, 0xfc, 0xd5, 0x1e, 0x00, 0x07, 0x68, + 0x99, 0x1b, 0xbf, 0x08, 0x8f, 0x42, 0x19, 0xd9, 0x00, 0x2e, 0x17, 0xd0, + 0xff, 0x21, 0x17, 0x78, 0x8c, 0x43, 0x3c, 0x43, 0x0f, 0x49, 0x57, 0x78, + 0x0c, 0x40, 0x3f, 0x02, 0x3c, 0x43, 0x97, 0x78, 0x01, 0x3e, 0x39, 0x04, + 0x0c, 0x4f, 0x27, 0x40, 0xd4, 0x78, 0xbf, 0xb2, 0x0f, 0x43, 0x24, 0x06, + 0x01, 0x99, 0x3c, 0x43, 0x10, 0xc1, 0x01, 0x91, 0x04, 0x32, 0xe0, 0xe7, + 0x07, 0x4b, 0x2b, 0x80, 0x2b, 0x7d, 0xdb, 0x07, 0xfc, 0xd5, 0x33, 0x00, + 0xd1, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x44, 0xa5, 0xff, 0xff, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, 0x04, 0xa5, 0xff, 0xff, + 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, 0x1a, 0x80, 0x1a, 0x7d, + 0xd2, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x16, 0x00, + 0xe3, 0x68, 0x29, 0x00, 0x20, 0x00, 0xb3, 0x42, 0x05, 0xd2, 0xff, 0xf7, + 0xe7, 0xff, 0xe3, 0x68, 0xed, 0x18, 0xf6, 0x1a, 0xf4, 0xe7, 0xff, 0xf7, + 0xe1, 0xff, 0x70, 0xbd, 0x1f, 0xb5, 0x00, 0x21, 0x03, 0x91, 0x90, 0x21, + 0xc9, 0x00, 0x02, 0x91, 0xa1, 0x39, 0xff, 0x39, 0x41, 0x18, 0x98, 0x23, + 0x01, 0x91, 0x02, 0x00, 0x80, 0x21, 0x9b, 0x00, 0x00, 0x91, 0xc3, 0x18, + 0x60, 0x32, 0x02, 0x49, 0x01, 0xf0, 0x9c, 0xff, 0x05, 0xb0, 0x00, 0xbd, + 0x80, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, 0x08, 0x00, 0x11, 0x00, + 0x1a, 0x00, 0x00, 0x23, 0x02, 0xf0, 0x16, 0xf8, 0x01, 0x00, 0x20, 0x00, + 0x00, 0xf0, 0x3a, 0xf8, 0x20, 0x00, 0x10, 0xbd, 0x03, 0x4b, 0x04, 0x4a, + 0x1a, 0x60, 0x04, 0x4a, 0x5a, 0x60, 0x04, 0x4a, 0x9a, 0x60, 0x70, 0x47, + 0x80, 0x04, 0x00, 0x20, 0x01, 0x26, 0x00, 0x00, 0x15, 0x26, 0x00, 0x00, + 0x29, 0x26, 0x00, 0x00, 0x10, 0xb5, 0x0c, 0x00, 0x13, 0x00, 0x00, 0x22, + 0x81, 0x5e, 0x22, 0x00, 0x01, 0x48, 0x02, 0xf0, 0x87, 0xf8, 0x10, 0xbd, + 0x8c, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x0c, 0x00, 0x13, 0x00, 0x00, 0x22, + 0x81, 0x5e, 0x22, 0x00, 0x01, 0x48, 0x02, 0xf0, 0xdd, 0xf8, 0x10, 0xbd, + 0x8c, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x00, 0x23, 0xc1, 0x5e, 0x02, 0x48, + 0x02, 0xf0, 0x9c, 0xf9, 0x10, 0xbd, 0xc0, 0x46, 0x8c, 0x04, 0x00, 0x20, + 0x10, 0xb5, 0x04, 0x00, 0xff, 0xf7, 0xf2, 0xff, 0x20, 0x00, 0x10, 0xbd, + 0x01, 0x80, 0x70, 0x47, 0x10, 0xb5, 0x00, 0x21, 0x40, 0x68, 0x05, 0xf0, + 0x6b, 0xfa, 0x10, 0xbd, 0x10, 0xb5, 0x01, 0x21, 0x40, 0x68, 0x05, 0xf0, + 0x65, 0xfa, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x68, 0x04, 0xf0, + 0xb9, 0xfb, 0x01, 0x21, 0x60, 0x68, 0x05, 0xf0, 0x0f, 0xfa, 0x20, 0x00, + 0xff, 0xf7, 0xee, 0xff, 0x10, 0xbd, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x00, + 0xff, 0xf7, 0xe2, 0xff, 0x09, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, + 0xcf, 0xfb, 0x05, 0x21, 0x20, 0x68, 0x04, 0xf0, 0xe7, 0xfb, 0x00, 0x21, + 0x20, 0x68, 0x04, 0xf0, 0xe3, 0xfb, 0x05, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0xd7, 0xff, 0x28, 0x00, 0x70, 0xbd, 0xc0, 0x46, 0xec, 0x0b, 0x00, 0x20, + 0x10, 0xb5, 0xff, 0xf7, 0xe3, 0xff, 0x01, 0x23, 0x18, 0x40, 0x10, 0xbd, + 0xf7, 0xb5, 0x04, 0x00, 0x0e, 0x00, 0x15, 0x00, 0x10, 0x27, 0x01, 0x93, + 0x20, 0x00, 0xff, 0xf7, 0xf1, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x3b, 0x00, + 0x01, 0x3b, 0xfd, 0xd1, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xb4, 0xff, + 0x12, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, 0xa1, 0xfb, 0x03, 0x21, + 0x20, 0x68, 0x04, 0xf0, 0xb9, 0xfb, 0x31, 0x0c, 0xc9, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0xb4, 0xfb, 0x31, 0x0a, 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, + 0xaf, 0xfb, 0xf1, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0xab, 0xfb, 0x01, 0x9b, + 0xee, 0x18, 0xb5, 0x42, 0x06, 0xd0, 0x00, 0x21, 0x20, 0x68, 0x04, 0xf0, + 0xa3, 0xfb, 0x28, 0x70, 0x01, 0x35, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, + 0x95, 0xff, 0xf7, 0xbd, 0xec, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, + 0xff, 0xf7, 0x88, 0xff, 0x06, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, + 0x75, 0xfb, 0x06, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x8d, 0xfb, 0x20, 0x00, + 0xff, 0xf7, 0x82, 0xff, 0x10, 0xbd, 0xc0, 0x46, 0xec, 0x0b, 0x00, 0x20, + 0xf7, 0xb5, 0x04, 0x00, 0x0e, 0x00, 0x15, 0x00, 0x10, 0x27, 0x01, 0x93, + 0x20, 0x00, 0xff, 0xf7, 0xa3, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x3b, 0x00, + 0x01, 0x3b, 0xfd, 0xd1, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xda, 0xff, + 0x20, 0x00, 0xff, 0xf7, 0x63, 0xff, 0x12, 0x4b, 0x20, 0x68, 0x06, 0xcb, + 0x04, 0xf0, 0x50, 0xfb, 0x02, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x68, 0xfb, + 0x31, 0x0c, 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x63, 0xfb, 0x31, 0x0a, + 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x5e, 0xfb, 0xf1, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0x5a, 0xfb, 0x01, 0x9b, 0xee, 0x18, 0xb5, 0x42, 0x05, 0xd0, + 0x29, 0x78, 0x20, 0x68, 0x04, 0xf0, 0x52, 0xfb, 0x01, 0x35, 0xf7, 0xe7, + 0x20, 0x00, 0xff, 0xf7, 0x45, 0xff, 0xf7, 0xbd, 0xec, 0x0b, 0x00, 0x20, + 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x10, 0x26, 0x20, 0x00, 0xff, 0xf7, + 0x69, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x33, 0x00, 0x01, 0x3b, 0xfd, 0xd1, + 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xa0, 0xff, 0x20, 0x00, 0xff, 0xf7, + 0x29, 0xff, 0x0d, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, 0x16, 0xfb, + 0x20, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x2e, 0xfb, 0x29, 0x0c, 0xc9, 0xb2, + 0x20, 0x68, 0x04, 0xf0, 0x29, 0xfb, 0x29, 0x0a, 0xc9, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0x24, 0xfb, 0xe9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x20, 0xfb, + 0x20, 0x00, 0xff, 0xf7, 0x15, 0xff, 0x70, 0xbd, 0xec, 0x0b, 0x00, 0x20, + 0x10, 0xb5, 0x0b, 0x00, 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, 0x40, 0xff, + 0x00, 0x20, 0x10, 0xbd, 0xf4, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x0b, 0x00, + 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, 0x84, 0xff, 0x00, 0x20, 0x10, 0xbd, + 0xf4, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, + 0xb7, 0xff, 0x00, 0x20, 0x10, 0xbd, 0xc0, 0x46, 0xf4, 0x0b, 0x00, 0x20, + 0x05, 0x4b, 0x06, 0x4a, 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, + 0x04, 0x4b, 0x05, 0x4a, 0x1a, 0x60, 0x05, 0x22, 0x5a, 0x60, 0x70, 0x47, + 0xec, 0x0b, 0x00, 0x20, 0x00, 0x1b, 0xb7, 0x00, 0xf4, 0x0b, 0x00, 0x20, + 0xfc, 0x0b, 0x00, 0x20, 0x01, 0x23, 0x8b, 0x40, 0xf7, 0xb5, 0x44, 0x6c, + 0x01, 0x93, 0x01, 0x9d, 0xa3, 0x68, 0x06, 0x00, 0x00, 0x20, 0x2b, 0x42, + 0x1c, 0xd0, 0x8a, 0x25, 0x6d, 0x00, 0x69, 0x43, 0x23, 0x69, 0x5d, 0x18, + 0x82, 0x42, 0x0f, 0xd0, 0x2a, 0x78, 0x57, 0xb2, 0x87, 0x42, 0x0b, 0xdb, + 0x01, 0x27, 0x3a, 0x42, 0x08, 0xd0, 0x0a, 0x00, 0x80, 0x21, 0x28, 0x89, + 0x14, 0x32, 0x9a, 0x18, 0x00, 0x02, 0x73, 0x68, 0x49, 0x00, 0x98, 0x47, + 0xa3, 0x68, 0x01, 0x9a, 0x93, 0x43, 0xa3, 0x60, 0x00, 0x23, 0x2b, 0x70, + 0xfe, 0xbd, 0xc3, 0x68, 0xf0, 0xb5, 0x84, 0x68, 0x02, 0x00, 0x23, 0x40, + 0x18, 0x1e, 0x17, 0xd0, 0x8a, 0x27, 0x00, 0x23, 0x15, 0x78, 0x7f, 0x00, + 0xab, 0x42, 0x01, 0xdb, 0x00, 0x20, 0x0f, 0xe0, 0x01, 0x20, 0x98, 0x40, + 0x04, 0x42, 0x0c, 0xd0, 0x38, 0x00, 0x58, 0x43, 0x16, 0x69, 0x30, 0x18, + 0x06, 0x78, 0x7f, 0x2e, 0x05, 0xd8, 0x06, 0x89, 0x8e, 0x42, 0x02, 0xd1, + 0x53, 0x68, 0x43, 0x60, 0xf0, 0xbd, 0x01, 0x33, 0xe8, 0xe7, 0x82, 0x68, + 0x01, 0x00, 0x30, 0xb5, 0x00, 0x20, 0x53, 0x1c, 0x13, 0xd0, 0x00, 0x23, + 0x01, 0x25, 0x08, 0x78, 0x83, 0x42, 0x01, 0xdb, 0x00, 0x20, 0x0c, 0xe0, + 0x2c, 0x00, 0x9c, 0x40, 0x14, 0x42, 0x09, 0xd1, 0x8a, 0x20, 0x40, 0x00, + 0x58, 0x43, 0x0b, 0x69, 0x22, 0x43, 0x18, 0x18, 0x4b, 0x68, 0x8a, 0x60, + 0x43, 0x60, 0x30, 0xbd, 0x01, 0x33, 0xeb, 0xe7, 0xf8, 0xb5, 0x44, 0x6c, + 0x07, 0x00, 0xe2, 0x68, 0xa3, 0x68, 0x00, 0x20, 0x13, 0x40, 0x9a, 0x42, + 0x0e, 0xd1, 0x23, 0x78, 0x01, 0x21, 0x9c, 0x46, 0x02, 0x00, 0x03, 0x00, + 0x49, 0x42, 0x62, 0x45, 0x07, 0xdb, 0x00, 0x20, 0x4b, 0x1c, 0x03, 0xd0, + 0x01, 0x22, 0x38, 0x00, 0xff, 0xf7, 0x80, 0xff, 0xf8, 0xbd, 0x8a, 0x26, + 0x76, 0x00, 0x56, 0x43, 0x25, 0x69, 0xae, 0x19, 0x70, 0x68, 0x65, 0x68, + 0x2d, 0x1a, 0x9d, 0x42, 0x04, 0xd9, 0x36, 0x78, 0x7f, 0x2e, 0x01, 0xd8, + 0x2b, 0x00, 0x11, 0x00, 0x01, 0x32, 0xe4, 0xe7, 0x10, 0xb5, 0x04, 0x00, + 0x40, 0x6c, 0xff, 0xf7, 0x92, 0xff, 0x00, 0x28, 0x04, 0xd0, 0x41, 0x78, + 0x00, 0x22, 0x20, 0x00, 0xff, 0xf7, 0x62, 0xff, 0x10, 0xbd, 0xf7, 0xb5, + 0x46, 0x6c, 0x1c, 0x00, 0x1b, 0x0a, 0x9b, 0xb2, 0x05, 0x00, 0x0f, 0x00, + 0x30, 0x00, 0x19, 0x00, 0x01, 0x93, 0xff, 0xf7, 0x7e, 0xff, 0x73, 0x68, + 0x01, 0x33, 0x73, 0x60, 0x00, 0x28, 0x10, 0xd0, 0x8a, 0x21, 0x43, 0x60, + 0x43, 0x78, 0x49, 0x00, 0x59, 0x43, 0xe4, 0xb2, 0x14, 0x34, 0x09, 0x19, + 0x34, 0x69, 0x08, 0x9a, 0x61, 0x18, 0x09, 0x98, 0x05, 0xf0, 0x22, 0xfa, + 0x00, 0x27, 0x38, 0x00, 0xfe, 0xbd, 0x03, 0x23, 0x1f, 0x40, 0x01, 0x2f, + 0x06, 0xd1, 0x2b, 0x68, 0x09, 0x9a, 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, + 0x07, 0x00, 0xf2, 0xe7, 0x28, 0x00, 0xff, 0xf7, 0x99, 0xff, 0x07, 0x00, + 0x68, 0x6c, 0xff, 0xf7, 0x78, 0xff, 0x00, 0x90, 0x00, 0x28, 0x24, 0xd0, + 0x02, 0x23, 0x6a, 0x46, 0x03, 0x70, 0x8a, 0x23, 0x92, 0x88, 0x5b, 0x00, + 0x02, 0x81, 0x42, 0x78, 0x80, 0x21, 0x5a, 0x43, 0x33, 0x69, 0x14, 0x32, + 0x9a, 0x18, 0x20, 0x00, 0xff, 0x23, 0x49, 0x00, 0x98, 0x43, 0x2b, 0x68, + 0x98, 0x47, 0x8a, 0x21, 0x49, 0x00, 0x00, 0x28, 0x00, 0xd0, 0x07, 0x00, + 0x00, 0x9b, 0xe4, 0xb2, 0x5b, 0x78, 0x14, 0x34, 0x59, 0x43, 0x09, 0x19, + 0x34, 0x69, 0x08, 0x9a, 0x61, 0x18, 0x09, 0x98, 0x05, 0xf0, 0xe6, 0xf9, + 0xc3, 0xe7, 0x2b, 0x68, 0x09, 0x9a, 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, + 0x00, 0x28, 0xc7, 0xd1, 0xbb, 0xe7, 0xf7, 0xb5, 0x47, 0x6c, 0x01, 0x91, + 0x19, 0x0a, 0x05, 0x00, 0x89, 0xb2, 0x38, 0x00, 0x1c, 0x00, 0xff, 0xf7, + 0x1c, 0xff, 0x06, 0x1e, 0x0c, 0xd0, 0x1c, 0x22, 0x01, 0x9b, 0x1a, 0x40, + 0x18, 0x2a, 0x07, 0xd0, 0x41, 0x78, 0x00, 0x2a, 0x0a, 0xd1, 0x9b, 0x07, + 0x08, 0xd0, 0x28, 0x00, 0xff, 0xf7, 0xe4, 0xfe, 0x6b, 0x68, 0x09, 0x9a, + 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, 0x14, 0xe0, 0x8a, 0x23, 0x5b, 0x00, + 0x59, 0x43, 0xe0, 0xb2, 0x3b, 0x69, 0x14, 0x30, 0x40, 0x18, 0x18, 0x18, + 0x08, 0x9a, 0x09, 0x99, 0x05, 0xf0, 0xb2, 0xf9, 0x02, 0x22, 0x7b, 0x68, + 0x01, 0x33, 0x7b, 0x60, 0x73, 0x60, 0x33, 0x78, 0x13, 0x40, 0x18, 0x1e, + 0xe4, 0xd1, 0xfe, 0xbd, 0xf7, 0xb5, 0x42, 0x6c, 0x94, 0x68, 0xd3, 0x68, + 0x23, 0x40, 0x18, 0x1e, 0x09, 0xd0, 0x13, 0x78, 0x8a, 0x26, 0x01, 0x93, + 0x01, 0x25, 0x00, 0x23, 0x76, 0x00, 0x01, 0x98, 0x98, 0x42, 0x01, 0xdc, + 0x00, 0x20, 0xfe, 0xbd, 0x28, 0x00, 0x98, 0x40, 0x04, 0x42, 0x0b, 0xd0, + 0x30, 0x00, 0x58, 0x43, 0x17, 0x69, 0x38, 0x18, 0x07, 0x78, 0x7f, 0x2f, + 0x04, 0xd9, 0x07, 0x89, 0xbc, 0x46, 0xcf, 0x88, 0xbc, 0x45, 0xee, 0xd0, + 0x01, 0x33, 0xe8, 0xe7, 0x70, 0xb5, 0x0c, 0x1e, 0x0f, 0xd0, 0x30, 0x21, + 0xc5, 0x6a, 0x83, 0x6a, 0x69, 0x43, 0x1a, 0x1d, 0x5b, 0x18, 0x00, 0x21, + 0x04, 0x33, 0x9a, 0x42, 0x06, 0xd1, 0x61, 0x78, 0x00, 0x22, 0xff, 0xf7, + 0x93, 0xfe, 0x00, 0x23, 0x23, 0x81, 0x70, 0xbd, 0x00, 0x26, 0x95, 0x5f, + 0x00, 0x2d, 0x03, 0xd0, 0xd5, 0x69, 0xa5, 0x42, 0x00, 0xd1, 0xd1, 0x61, + 0x30, 0x32, 0xec, 0xe7, 0xf0, 0xb5, 0x47, 0x6c, 0x89, 0xb0, 0x06, 0x00, + 0x00, 0x2f, 0x36, 0xd0, 0x8a, 0x21, 0x80, 0x6c, 0x49, 0x00, 0x14, 0x38, + 0x05, 0xf0, 0xaa, 0xf8, 0x04, 0x1e, 0x2e, 0xd0, 0x00, 0x23, 0x01, 0x21, + 0x01, 0x93, 0x01, 0x9a, 0x01, 0x33, 0x52, 0x00, 0x0a, 0x43, 0x01, 0x92, + 0x9c, 0x42, 0xf8, 0xdc, 0x03, 0xad, 0x08, 0x22, 0x00, 0x21, 0x28, 0x00, + 0x05, 0xf0, 0x51, 0xf9, 0x3b, 0x00, 0x14, 0x33, 0x2b, 0x61, 0x01, 0x23, + 0x5b, 0x42, 0xab, 0x60, 0x01, 0x9b, 0x29, 0x00, 0x14, 0x22, 0x38, 0x00, + 0xeb, 0x60, 0x2c, 0x70, 0x05, 0xf0, 0x3a, 0xf9, 0x75, 0x6c, 0x8a, 0x26, + 0x2a, 0x78, 0x76, 0x00, 0x72, 0x43, 0x00, 0x21, 0x28, 0x69, 0x05, 0xf0, + 0x3a, 0xf9, 0xab, 0x68, 0xea, 0x68, 0xe4, 0xb2, 0x93, 0x43, 0xab, 0x60, + 0x00, 0x23, 0x9c, 0x42, 0x01, 0xdc, 0x09, 0xb0, 0xf0, 0xbd, 0x32, 0x00, + 0x5a, 0x43, 0x29, 0x69, 0x8a, 0x18, 0x53, 0x70, 0x01, 0x33, 0xf4, 0xe7, + 0xf0, 0xb5, 0x85, 0xb0, 0x06, 0x00, 0x0d, 0x00, 0x14, 0x00, 0x03, 0x93, + 0x00, 0x27, 0x68, 0x2a, 0x06, 0xd9, 0x10, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x05, 0xf0, 0x62, 0xf8, 0x01, 0x30, 0x87, 0xb2, 0x80, 0x21, 0x0a, 0x9b, + 0x09, 0x02, 0x00, 0x93, 0x29, 0x43, 0x00, 0x23, 0x3a, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0xfa, 0xfa, 0x00, 0x28, 0x11, 0xdb, 0x0a, 0x9b, 0x1d, 0x88, + 0x2d, 0x02, 0x00, 0x2f, 0x0e, 0xd1, 0x23, 0x00, 0x17, 0x33, 0x03, 0x9a, + 0x5b, 0x00, 0x01, 0x92, 0x02, 0x22, 0x5b, 0x19, 0x00, 0x92, 0x15, 0x21, + 0x00, 0x22, 0x30, 0x00, 0xff, 0xf7, 0xb1, 0xfe, 0x05, 0xb0, 0xf0, 0xbd, + 0x23, 0x1d, 0x68, 0x2c, 0xef, 0xd9, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x05, 0xf0, 0xbe, 0xf8, 0x0b, 0x1d, 0xe8, 0xe7, 0x30, 0xb5, 0x0e, 0x25, + 0x00, 0x23, 0x85, 0xb0, 0x6d, 0x44, 0x1a, 0x00, 0x00, 0x95, 0x04, 0x00, + 0x02, 0xf0, 0xd0, 0xfa, 0x0b, 0x4b, 0x98, 0x42, 0x12, 0xd0, 0x00, 0x28, + 0x0e, 0xdb, 0x0d, 0x22, 0xbf, 0x23, 0x6a, 0x44, 0x13, 0x70, 0x2b, 0x88, + 0x01, 0x92, 0x01, 0x22, 0x1b, 0x02, 0x00, 0x92, 0x04, 0x33, 0x00, 0x22, + 0x04, 0x21, 0x20, 0x00, 0xff, 0xf7, 0xeb, 0xfe, 0x05, 0xb0, 0x30, 0xbd, + 0x00, 0x20, 0xfb, 0xe7, 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x8b, 0xb0, + 0x04, 0x93, 0x10, 0xab, 0x1b, 0x88, 0x12, 0x25, 0x05, 0x93, 0x50, 0x4b, + 0x14, 0x00, 0x19, 0x43, 0x0e, 0x23, 0x04, 0xaa, 0x9b, 0x18, 0x19, 0x80, + 0x09, 0xab, 0xad, 0x18, 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x2b, 0x00, + 0x06, 0x00, 0x02, 0xf0, 0x65, 0xfa, 0x00, 0x28, 0x33, 0xdb, 0x09, 0x9b, + 0x2d, 0x88, 0x06, 0x93, 0x68, 0x2c, 0x30, 0xd9, 0x27, 0x00, 0x69, 0x3f, + 0x7c, 0x21, 0x38, 0x00, 0x04, 0xf0, 0xee, 0xff, 0x01, 0x30, 0x83, 0xb2, + 0x7c, 0x21, 0x38, 0x00, 0x03, 0x93, 0x05, 0xf0, 0x6d, 0xf8, 0x09, 0x91, + 0x32, 0x6a, 0x05, 0x9b, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, + 0x1b, 0x02, 0x00, 0x22, 0x15, 0x21, 0x30, 0x00, 0xff, 0xf7, 0x49, 0xfe, + 0x00, 0x28, 0x12, 0xdb, 0x06, 0x9b, 0x37, 0x6a, 0x2d, 0x01, 0xed, 0x18, + 0x04, 0xaa, 0x7b, 0x78, 0x39, 0x78, 0xd2, 0x89, 0x01, 0x35, 0x1b, 0x02, + 0xad, 0xb2, 0x0b, 0x43, 0x9a, 0x42, 0x0a, 0xd0, 0x29, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0x5c, 0xfb, 0x2e, 0x48, 0x0b, 0xb0, 0xf0, 0xbd, 0x00, 0x23, + 0x09, 0x94, 0x03, 0x93, 0xd8, 0xe7, 0xfb, 0x78, 0xba, 0x78, 0x1b, 0x02, + 0x13, 0x43, 0x03, 0x9a, 0x93, 0x42, 0x05, 0xd0, 0x29, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0x4a, 0xfb, 0x26, 0x48, 0xec, 0xe7, 0x38, 0x22, 0x3b, 0x79, + 0x93, 0x43, 0xc0, 0x2b, 0x05, 0xd0, 0x29, 0x00, 0x30, 0x00, 0x02, 0xf0, + 0x3f, 0xfb, 0x22, 0x48, 0xe1, 0xe7, 0x03, 0x9b, 0x00, 0x2b, 0x2a, 0xd1, + 0x6b, 0x46, 0x64, 0x00, 0x1b, 0x8a, 0x3c, 0x19, 0xe3, 0x85, 0x80, 0x22, + 0x52, 0x00, 0x00, 0x92, 0x2b, 0x02, 0x01, 0x97, 0x00, 0x22, 0x07, 0x21, + 0x30, 0x00, 0xff, 0xf7, 0x68, 0xfe, 0x00, 0x28, 0xcd, 0xdb, 0x0f, 0x23, + 0x17, 0x4a, 0x2b, 0x40, 0x9b, 0x18, 0x0e, 0x22, 0x04, 0xa9, 0x52, 0x18, + 0x01, 0x92, 0x02, 0x22, 0x2d, 0x09, 0x5b, 0x00, 0x2d, 0x03, 0x00, 0x92, + 0x5b, 0x19, 0x00, 0x22, 0x04, 0x21, 0x30, 0x00, 0xff, 0xf7, 0x53, 0xfe, + 0x00, 0x28, 0xb8, 0xdb, 0x05, 0x99, 0x30, 0x00, 0x02, 0xf0, 0x10, 0xfb, + 0xb3, 0xe7, 0x68, 0x2c, 0x05, 0xd8, 0x64, 0x00, 0x6b, 0x46, 0x1b, 0x8a, + 0x3c, 0x19, 0x23, 0x81, 0xd1, 0xe7, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x04, 0xf0, 0xf2, 0xff, 0x4c, 0x00, 0xf3, 0xe7, 0x00, 0x80, 0xff, 0xff, + 0xbd, 0xd8, 0xff, 0xff, 0xbc, 0xd8, 0xff, 0xff, 0xbb, 0xd8, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x00, 0x24, 0x85, 0xb0, 0x0e, 0x00, + 0x1f, 0x00, 0x11, 0x88, 0x03, 0x93, 0x02, 0x94, 0x01, 0x94, 0x00, 0x94, + 0x23, 0x00, 0x05, 0x00, 0x02, 0xf0, 0x66, 0xfa, 0xa0, 0x42, 0x0a, 0xdb, + 0xfb, 0x21, 0x3a, 0x88, 0x33, 0x02, 0x12, 0x02, 0x00, 0x91, 0x05, 0x33, + 0x05, 0x32, 0x21, 0x00, 0x28, 0x00, 0x01, 0xf0, 0xe3, 0xff, 0x05, 0xb0, + 0xf0, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x93, 0xb0, 0x06, 0x91, 0x01, 0x33, + 0x11, 0x01, 0xcb, 0x18, 0xc4, 0x6c, 0x9b, 0xb2, 0x07, 0x00, 0x05, 0x93, + 0x00, 0x2c, 0x08, 0xd0, 0x10, 0x02, 0xf9, 0x68, 0x04, 0xf0, 0x32, 0xff, + 0x00, 0x23, 0x02, 0x00, 0x19, 0x00, 0x18, 0x00, 0xa0, 0x47, 0x05, 0x9b, + 0x0e, 0xad, 0x1b, 0x02, 0x08, 0x93, 0x05, 0x23, 0x01, 0x95, 0x00, 0x93, + 0x00, 0x22, 0x08, 0x9b, 0x15, 0x21, 0x38, 0x00, 0xff, 0xf7, 0x8f, 0xfd, + 0x04, 0x1e, 0x00, 0xda, 0xd5, 0xe0, 0x06, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0x81, 0xe0, 0x2b, 0x79, 0x7f, 0x2b, 0x00, 0xd9, 0x86, 0xe0, 0x06, 0x9b, + 0x1c, 0x00, 0x1d, 0x00, 0x04, 0x93, 0x06, 0x9b, 0x83, 0x4a, 0x01, 0x3b, + 0x9b, 0xb2, 0x93, 0x42, 0x00, 0xd9, 0x02, 0xe2, 0x81, 0x48, 0x06, 0x9b, + 0x02, 0x00, 0x0e, 0xae, 0x03, 0x43, 0x9b, 0xb2, 0x31, 0x88, 0x07, 0x93, + 0x33, 0x79, 0x0a, 0x43, 0x09, 0x90, 0x07, 0x98, 0x92, 0xb2, 0x82, 0x42, + 0x00, 0xd1, 0xb2, 0xe1, 0x5a, 0xb2, 0x00, 0x2a, 0x51, 0xda, 0x9a, 0x07, + 0x4f, 0xd4, 0x44, 0x22, 0x13, 0x42, 0x4c, 0xd0, 0x04, 0x25, 0x72, 0x88, + 0x1d, 0x40, 0x00, 0xd1, 0xee, 0xe0, 0x12, 0x23, 0x06, 0xa8, 0x1b, 0x18, + 0x0b, 0xad, 0x00, 0x93, 0x38, 0x00, 0x2b, 0x00, 0xff, 0xf7, 0x74, 0xfe, + 0x6f, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x3a, 0xd0, 0x00, 0x28, 0x00, 0xda, + 0x95, 0xe0, 0x2b, 0x88, 0x05, 0x9a, 0x93, 0x42, 0x33, 0xd1, 0x10, 0xad, + 0x2b, 0x00, 0x32, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0x72, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0x87, 0xe0, 0x12, 0x20, 0x06, 0xac, 0x00, 0x19, + 0x00, 0x88, 0x0e, 0xae, 0x2b, 0x88, 0x72, 0x88, 0x31, 0x88, 0x00, 0x90, + 0x38, 0x00, 0xff, 0xf7, 0xb1, 0xfe, 0x60, 0x4b, 0x04, 0x00, 0xc3, 0x18, + 0x02, 0x2b, 0x16, 0xd8, 0x29, 0x88, 0x38, 0x00, 0x02, 0xf0, 0x50, 0xfa, + 0x04, 0x1e, 0x70, 0xdb, 0x31, 0x88, 0x38, 0x00, 0xff, 0xf7, 0x7e, 0xfe, + 0x01, 0x23, 0xfd, 0x6c, 0x04, 0x00, 0x04, 0x93, 0x00, 0x2d, 0x06, 0xd0, + 0x00, 0x23, 0x32, 0x88, 0x18, 0x00, 0x06, 0x21, 0xa8, 0x47, 0x01, 0x23, + 0x04, 0x93, 0x00, 0x2c, 0x5d, 0xdb, 0xfc, 0x6c, 0x00, 0x2c, 0x04, 0xd0, + 0x00, 0x23, 0x05, 0x9a, 0x05, 0x21, 0x18, 0x00, 0xa0, 0x47, 0x05, 0x99, + 0x38, 0x00, 0x02, 0xf0, 0x2f, 0xfa, 0x04, 0x00, 0x92, 0xe1, 0x4b, 0x4b, + 0x06, 0x9a, 0x9a, 0x42, 0x00, 0xd0, 0x82, 0xe0, 0x2b, 0x79, 0xdb, 0x07, + 0x00, 0xd5, 0x7e, 0xe0, 0x04, 0x23, 0x2e, 0x79, 0x29, 0x88, 0x6a, 0x88, + 0x1e, 0x40, 0x4b, 0xd0, 0x06, 0xa8, 0x0e, 0x33, 0x1b, 0x18, 0x0b, 0xae, + 0x00, 0x93, 0x38, 0x00, 0x33, 0x00, 0xff, 0xf7, 0x0f, 0xfe, 0x3d, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x00, 0xd1, 0x6c, 0xe0, 0x00, 0x28, 0x30, 0xdb, + 0x33, 0x88, 0x05, 0x9a, 0x93, 0x42, 0x00, 0xd0, 0x60, 0xe0, 0x10, 0xae, + 0x33, 0x00, 0x2a, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0x0c, 0xff, + 0x04, 0x1e, 0x22, 0xdb, 0x06, 0xa8, 0x40, 0x8a, 0x33, 0x88, 0x6a, 0x88, + 0x29, 0x88, 0x00, 0x90, 0x38, 0x00, 0xff, 0xf7, 0x4f, 0xfe, 0x2f, 0x4b, + 0x04, 0x00, 0xc3, 0x18, 0x02, 0x2b, 0x17, 0xd8, 0x31, 0x88, 0x38, 0x00, + 0x02, 0xf0, 0xee, 0xf9, 0x04, 0x1e, 0x0e, 0xdb, 0x29, 0x88, 0x38, 0x00, + 0xff, 0xf7, 0x1c, 0xfe, 0xfe, 0x6c, 0x04, 0x00, 0x00, 0x2e, 0x04, 0xd0, + 0x00, 0x23, 0x06, 0x21, 0x18, 0x00, 0x2a, 0x88, 0xb0, 0x47, 0x00, 0x2c, + 0x34, 0xda, 0x20, 0x00, 0x13, 0xb0, 0xf0, 0xbd, 0xfe, 0x6c, 0x00, 0x2e, + 0xf7, 0xd0, 0x6b, 0x88, 0x2a, 0x88, 0x02, 0x21, 0x00, 0x20, 0xf1, 0xe7, + 0x1a, 0x4b, 0x00, 0x96, 0x19, 0x43, 0x89, 0xb2, 0x05, 0x9b, 0x38, 0x00, + 0x02, 0xf0, 0xd8, 0xf8, 0x17, 0x4b, 0x04, 0x00, 0x98, 0x42, 0xe6, 0xd1, + 0x29, 0x88, 0x14, 0x4b, 0x00, 0x96, 0x0b, 0x43, 0x99, 0xb2, 0x32, 0x00, + 0x33, 0x00, 0x38, 0x00, 0x02, 0xf0, 0x02, 0xf9, 0x04, 0x1e, 0x11, 0xd1, + 0x10, 0xab, 0x2a, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0xbe, 0xfe, + 0x04, 0x1e, 0xd4, 0xdb, 0xfb, 0x6c, 0x9c, 0x46, 0x00, 0x2b, 0x05, 0xd0, + 0x6b, 0x88, 0x2a, 0x88, 0x03, 0x21, 0x30, 0x00, 0x65, 0x46, 0xa8, 0x47, + 0x01, 0x23, 0x04, 0x93, 0x04, 0xe0, 0x00, 0x23, 0xf8, 0xe6, 0x01, 0x23, + 0x00, 0x24, 0x04, 0x93, 0x1d, 0x00, 0xf6, 0xe6, 0xfd, 0xff, 0x00, 0x00, + 0x00, 0x80, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, + 0xff, 0xff, 0x00, 0x00, 0x16, 0x26, 0x06, 0xab, 0xf6, 0x18, 0x00, 0x96, + 0x2b, 0x00, 0x07, 0x99, 0x38, 0x00, 0x02, 0xf0, 0x99, 0xf8, 0xc1, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x00, 0xd0, 0x75, 0xe0, 0x35, 0x80, 0x0e, 0xae, + 0x31, 0x88, 0x09, 0x9b, 0x0c, 0xad, 0x19, 0x43, 0x72, 0x88, 0x00, 0x23, + 0x89, 0xb2, 0x00, 0x95, 0x38, 0x00, 0x02, 0xf0, 0x87, 0xf8, 0xb8, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x68, 0xd1, 0x00, 0x23, 0x2b, 0x80, 0x2b, 0x88, + 0x00, 0x2b, 0x06, 0xd0, 0x16, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0x00, 0x2b, 0x00, 0xd0, 0x2d, 0xe7, 0x06, 0x9b, 0x06, 0xaa, 0x59, 0x04, + 0x1a, 0x23, 0x9b, 0x18, 0x00, 0x93, 0x00, 0x23, 0x49, 0x0c, 0x1a, 0x00, + 0x38, 0x00, 0x02, 0xf0, 0x6b, 0xf8, 0xaa, 0x4b, 0x04, 0x00, 0x98, 0x42, + 0x4f, 0xd1, 0x16, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x00, 0x22, 0x1a, 0x80, + 0x00, 0x23, 0x31, 0x88, 0x0d, 0xad, 0x49, 0x04, 0x1a, 0x00, 0x49, 0x0c, + 0x00, 0x95, 0x38, 0x00, 0x02, 0xf0, 0x58, 0xf8, 0xa0, 0x4b, 0x04, 0x00, + 0x98, 0x42, 0x3f, 0xd1, 0x00, 0x22, 0x0c, 0xab, 0x1a, 0x80, 0xf8, 0x23, + 0x16, 0x21, 0x10, 0xaa, 0x06, 0xa8, 0x13, 0x71, 0x09, 0x18, 0x73, 0x88, + 0x08, 0x88, 0x53, 0x80, 0x00, 0x28, 0x05, 0xd0, 0x1a, 0x21, 0x06, 0xac, + 0x09, 0x19, 0x09, 0x88, 0x00, 0x29, 0x2e, 0xd0, 0x29, 0x88, 0x00, 0x29, + 0x2b, 0xd0, 0x0c, 0xa9, 0x09, 0x88, 0x06, 0x91, 0x00, 0x29, 0x26, 0xd1, + 0x33, 0x88, 0x09, 0x99, 0x38, 0x00, 0x19, 0x43, 0x1e, 0x23, 0x11, 0x80, + 0x06, 0xa9, 0x5b, 0x18, 0x05, 0x99, 0xff, 0xf7, 0x29, 0xfe, 0xfd, 0x6c, + 0x04, 0x00, 0x00, 0x2d, 0x04, 0xd0, 0x73, 0x88, 0x32, 0x88, 0x03, 0x21, + 0x06, 0x98, 0xa8, 0x47, 0x00, 0x2c, 0x00, 0xda, 0x35, 0xe7, 0x01, 0x23, + 0x04, 0x93, 0xd4, 0xe6, 0x00, 0x28, 0x00, 0xdb, 0x87, 0xe7, 0x2e, 0xe7, + 0x00, 0x28, 0x96, 0xda, 0x2b, 0xe7, 0x00, 0x28, 0xb2, 0xda, 0x28, 0xe7, + 0x00, 0x28, 0xc0, 0xda, 0x25, 0xe7, 0x0c, 0xaa, 0x12, 0x88, 0x00, 0x2a, + 0x03, 0xd0, 0x2a, 0x88, 0x00, 0x2a, 0x00, 0xd1, 0xbf, 0xe6, 0x1a, 0x22, + 0x06, 0xa9, 0x52, 0x18, 0x12, 0x88, 0x00, 0x2a, 0x00, 0xd1, 0xb8, 0xe6, + 0x00, 0x28, 0x00, 0xd0, 0xb5, 0xe6, 0x6a, 0x46, 0xfd, 0x6c, 0x92, 0x8b, + 0x10, 0xac, 0x22, 0x80, 0x00, 0x2d, 0x02, 0xd0, 0x32, 0x88, 0x03, 0x21, + 0xa8, 0x47, 0x1e, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x05, 0x99, 0x22, 0x00, + 0x38, 0x00, 0xff, 0xf7, 0xe9, 0xfd, 0x04, 0x00, 0xc6, 0xe7, 0x69, 0x46, + 0x04, 0x22, 0x18, 0x20, 0x09, 0x5e, 0x1a, 0x40, 0x00, 0x29, 0x44, 0xda, + 0x00, 0x2a, 0x44, 0xd1, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0x94, 0xe6, + 0x9b, 0x07, 0x30, 0xd5, 0x12, 0x23, 0x06, 0xa9, 0x5b, 0x18, 0x0e, 0xae, + 0x72, 0x88, 0x06, 0x99, 0x00, 0x93, 0x38, 0x00, 0x0b, 0xab, 0xff, 0xf7, + 0xbd, 0xfc, 0x5d, 0x4b, 0x04, 0x00, 0x98, 0x42, 0xab, 0xd0, 0x00, 0x28, + 0x00, 0xda, 0xde, 0xe6, 0x01, 0x22, 0x06, 0xab, 0x04, 0x92, 0x9b, 0x8a, + 0x05, 0x9a, 0x93, 0x42, 0x00, 0xd0, 0x78, 0xe6, 0xfc, 0x6c, 0x00, 0x2c, + 0x04, 0xd0, 0x73, 0x88, 0x32, 0x88, 0x03, 0x21, 0x00, 0x20, 0xa0, 0x47, + 0xfd, 0x23, 0x01, 0x26, 0x10, 0xaa, 0x13, 0x70, 0x08, 0x9b, 0x01, 0x92, + 0x04, 0x33, 0x00, 0x96, 0x00, 0x22, 0x07, 0x21, 0x38, 0x00, 0xff, 0xf7, + 0xdc, 0xfb, 0x04, 0x00, 0x04, 0x96, 0x00, 0x2d, 0x00, 0xd0, 0x5e, 0xe6, + 0x00, 0x2c, 0x00, 0xd0, 0xb9, 0xe6, 0x04, 0x9c, 0x47, 0x4b, 0x67, 0x42, + 0x7c, 0x41, 0xe4, 0x18, 0xb3, 0xe6, 0x00, 0x2a, 0xba, 0xd1, 0x1a, 0x26, + 0x06, 0x9b, 0x0e, 0xad, 0x5b, 0x04, 0x5b, 0x0c, 0x09, 0x93, 0x06, 0xab, + 0xf6, 0x18, 0x6a, 0x88, 0x05, 0x9b, 0x00, 0x96, 0x09, 0x99, 0x38, 0x00, + 0x01, 0xf0, 0x8e, 0xff, 0x3b, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x4c, 0xd1, + 0x00, 0x23, 0x33, 0x80, 0x6a, 0x88, 0x0d, 0xad, 0x05, 0x9b, 0x00, 0x95, + 0x07, 0x99, 0x38, 0x00, 0x01, 0xf0, 0x80, 0xff, 0x34, 0x4b, 0x04, 0x00, + 0x98, 0x42, 0x41, 0xd1, 0x00, 0x23, 0x2b, 0x80, 0x1a, 0x23, 0x06, 0xaa, + 0x9b, 0x18, 0x28, 0x88, 0x1d, 0x88, 0xfc, 0x6c, 0x00, 0x2d, 0x3a, 0xd0, + 0x00, 0x28, 0x00, 0xd0, 0x25, 0xe6, 0x00, 0x2c, 0x04, 0xd0, 0x0e, 0xab, + 0x5b, 0x88, 0x06, 0x9a, 0x02, 0x21, 0xa0, 0x47, 0xf8, 0x23, 0x10, 0xaa, + 0x13, 0x71, 0x6b, 0x46, 0x1e, 0x26, 0x9b, 0x8b, 0x00, 0x25, 0x13, 0x80, + 0x0e, 0xab, 0x5b, 0x88, 0x07, 0x99, 0x53, 0x80, 0x06, 0xab, 0xf6, 0x18, + 0x01, 0x23, 0x02, 0x93, 0x2b, 0x00, 0x03, 0x96, 0x01, 0x95, 0x00, 0x95, + 0x38, 0x00, 0x01, 0xf0, 0xc1, 0xff, 0x04, 0x00, 0xa8, 0x42, 0x00, 0xda, + 0x61, 0xe6, 0xfb, 0x21, 0x32, 0x88, 0x08, 0x9b, 0x12, 0x02, 0x00, 0x91, + 0x05, 0x33, 0x05, 0x32, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, 0x3c, 0xfd, + 0x04, 0x00, 0xa8, 0x42, 0x00, 0xdb, 0xf4, 0xe5, 0x51, 0xe6, 0x00, 0x28, + 0xb2, 0xda, 0x4e, 0xe6, 0x00, 0x28, 0xbd, 0xda, 0x4b, 0xe6, 0x00, 0x28, + 0x00, 0xd1, 0xea, 0xe5, 0x0e, 0xab, 0x5b, 0x88, 0x00, 0x2c, 0x03, 0xd0, + 0x06, 0x9a, 0x03, 0x21, 0x28, 0x00, 0xa0, 0x47, 0xfc, 0x23, 0x10, 0xaa, + 0x13, 0x71, 0x6b, 0x46, 0x1e, 0x26, 0x9b, 0x8c, 0x00, 0x25, 0x13, 0x80, + 0x0e, 0xab, 0x5b, 0x88, 0x09, 0x99, 0x53, 0x80, 0x06, 0xab, 0xf6, 0x18, + 0x01, 0x23, 0x03, 0x96, 0x02, 0x93, 0x01, 0x95, 0x00, 0x95, 0x2b, 0x00, + 0xc2, 0xe7, 0xc0, 0x46, 0xee, 0xd8, 0xff, 0xff, 0xa9, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x8b, 0xb0, 0x05, 0x93, 0xc7, 0x6c, 0x43, 0x6a, 0x04, 0x00, + 0x03, 0x91, 0x16, 0x00, 0x11, 0x9d, 0x04, 0x93, 0x00, 0x2f, 0x08, 0xd0, + 0x10, 0x02, 0xe1, 0x68, 0x04, 0xf0, 0x5e, 0xfc, 0x00, 0x23, 0x02, 0x00, + 0x19, 0x00, 0x01, 0x20, 0xb8, 0x47, 0x03, 0x9b, 0x4f, 0x49, 0x50, 0x4a, + 0x5b, 0x18, 0x9b, 0xb2, 0x93, 0x42, 0x00, 0xd9, 0x94, 0xe0, 0x05, 0x22, + 0x05, 0x9b, 0x36, 0x01, 0x01, 0x33, 0xf6, 0x18, 0xb7, 0xb2, 0x08, 0xae, + 0x00, 0x92, 0x3b, 0x02, 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, + 0xff, 0xf7, 0xb1, 0xfa, 0x00, 0x28, 0x16, 0xdb, 0x39, 0x22, 0x33, 0x79, + 0x93, 0x43, 0x72, 0x88, 0x00, 0x2a, 0x12, 0xd1, 0x80, 0x2b, 0x6e, 0xd1, + 0xe5, 0x6c, 0x00, 0x2d, 0x04, 0xd0, 0x03, 0x9b, 0x3a, 0x00, 0x05, 0x21, + 0x01, 0x20, 0xa8, 0x47, 0x39, 0x00, 0x20, 0x00, 0x01, 0xf0, 0xc2, 0xff, + 0x00, 0x28, 0x00, 0xdb, 0x3a, 0x48, 0x05, 0x00, 0x6b, 0xe0, 0xc0, 0x2b, + 0xfa, 0xd0, 0x03, 0x9b, 0x38, 0x4a, 0x5e, 0x04, 0x94, 0x46, 0x00, 0x23, + 0x60, 0x6a, 0x76, 0x0c, 0x61, 0x46, 0xc2, 0x5a, 0x0a, 0x40, 0xb2, 0x42, + 0x12, 0xd1, 0x04, 0x9a, 0xd3, 0x5e, 0x00, 0x2b, 0x58, 0xda, 0x30, 0x4d, + 0x36, 0xe0, 0x02, 0x33, 0x9c, 0x42, 0x4f, 0xd1, 0x2b, 0x68, 0x04, 0x98, + 0x59, 0x00, 0x01, 0x33, 0x0a, 0x52, 0x7f, 0x2b, 0x00, 0xd9, 0x00, 0x23, + 0x2b, 0x60, 0x49, 0xe0, 0x80, 0x22, 0x02, 0x33, 0x52, 0x00, 0x93, 0x42, + 0xe2, 0xd1, 0x0e, 0x23, 0x04, 0xaa, 0x9b, 0x18, 0x00, 0x93, 0x00, 0x23, + 0x03, 0x99, 0x1a, 0x00, 0x20, 0x00, 0x01, 0xf0, 0x9b, 0xfe, 0x00, 0x28, + 0x0a, 0xd0, 0x22, 0x4b, 0x98, 0x42, 0x24, 0xd1, 0x69, 0x46, 0x2b, 0x68, + 0x04, 0x9a, 0x89, 0x89, 0x5b, 0x00, 0x99, 0x52, 0x01, 0x22, 0x04, 0xe0, + 0x2b, 0x68, 0x04, 0x9a, 0x5b, 0x00, 0x9e, 0x52, 0x02, 0x00, 0x2b, 0x68, + 0x01, 0x33, 0x7f, 0x2b, 0x00, 0xd9, 0x00, 0x23, 0x2b, 0x60, 0x18, 0x4d, + 0x00, 0x2a, 0x20, 0xd0, 0xe6, 0x6c, 0x00, 0x2e, 0x04, 0xd0, 0x03, 0x9b, + 0x3a, 0x00, 0x04, 0x21, 0x01, 0x20, 0xb0, 0x47, 0x39, 0x00, 0x20, 0x00, + 0x01, 0xf0, 0x66, 0xff, 0x00, 0x28, 0x12, 0xda, 0xa3, 0xe7, 0x00, 0x22, + 0x90, 0x42, 0xe4, 0xda, 0x9f, 0xe7, 0xc0, 0x2b, 0x9c, 0xd0, 0x03, 0x9b, + 0x09, 0x48, 0x5a, 0x04, 0x63, 0x6a, 0x52, 0x0c, 0x5c, 0x1c, 0xff, 0x34, + 0x19, 0x88, 0x01, 0x40, 0x91, 0x42, 0xa8, 0xd1, 0x03, 0x4d, 0x28, 0x00, + 0x0b, 0xb0, 0xf0, 0xbd, 0x00, 0x80, 0xff, 0xff, 0xfe, 0x7f, 0x00, 0x00, + 0xaa, 0xd8, 0xff, 0xff, 0xff, 0x7f, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xa9, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0xc4, 0x6c, 0x87, 0xb0, 0x06, 0x00, + 0x00, 0x2c, 0x04, 0xd0, 0x00, 0x23, 0x1a, 0x00, 0x19, 0x00, 0x18, 0x00, + 0xa0, 0x47, 0x00, 0x24, 0x14, 0x4b, 0x05, 0x94, 0x01, 0x93, 0x04, 0x94, + 0x23, 0x00, 0x03, 0x94, 0x02, 0x94, 0x00, 0x94, 0x22, 0x00, 0x21, 0x00, + 0x30, 0x00, 0x01, 0xf0, 0x5b, 0xfc, 0x0f, 0x4b, 0x05, 0x00, 0x98, 0x42, + 0x15, 0xd0, 0xa0, 0x42, 0x07, 0xd0, 0xf7, 0x6c, 0xa7, 0x42, 0x04, 0xd0, + 0x02, 0x00, 0x23, 0x00, 0x01, 0x21, 0x20, 0x00, 0xb8, 0x47, 0xf4, 0x6c, + 0x00, 0x2c, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, 0x19, 0x00, 0x52, 0x00, + 0x18, 0x00, 0xa0, 0x47, 0x28, 0x00, 0x07, 0xb0, 0xf0, 0xbd, 0x25, 0x00, + 0xf1, 0xe7, 0xc0, 0x46, 0x41, 0x2c, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0xc4, 0x6c, 0x97, 0xb0, 0x05, 0x00, 0x00, 0x2c, 0x04, 0xd0, + 0x00, 0x23, 0x02, 0x20, 0x1a, 0x00, 0x19, 0x00, 0xa0, 0x47, 0x00, 0x23, + 0x07, 0x93, 0x1c, 0x00, 0xb0, 0xe1, 0x80, 0x22, 0x00, 0x21, 0x52, 0x00, + 0x68, 0x6a, 0x04, 0xf0, 0x16, 0xfc, 0x07, 0x9b, 0x1b, 0x02, 0x0f, 0x93, + 0x00, 0x23, 0x0a, 0x93, 0xee, 0x68, 0x0a, 0x9b, 0x9e, 0x42, 0x09, 0xd8, + 0x00, 0x23, 0x06, 0x93, 0x06, 0x9b, 0x07, 0x9a, 0x5b, 0x00, 0xd3, 0x18, + 0x9b, 0xb2, 0x0a, 0x93, 0x00, 0x23, 0x0a, 0xe2, 0xeb, 0x6c, 0x05, 0x93, + 0x00, 0x2b, 0x13, 0xd0, 0x0a, 0x9b, 0x37, 0x01, 0x58, 0x04, 0x39, 0x00, + 0x04, 0xf0, 0x40, 0xfb, 0x31, 0x00, 0x04, 0xf0, 0x3d, 0xfb, 0x39, 0x00, + 0x06, 0x00, 0x0f, 0x98, 0x04, 0xf0, 0x38, 0xfb, 0x00, 0x23, 0x32, 0x18, + 0x19, 0x00, 0x02, 0x20, 0x05, 0x9e, 0xb0, 0x47, 0x0a, 0x9b, 0x1b, 0x01, + 0x01, 0x33, 0x9b, 0xb2, 0x06, 0x93, 0x0a, 0x9b, 0x01, 0x33, 0x1b, 0x01, + 0x0e, 0x93, 0x06, 0x9b, 0x0e, 0x9a, 0x93, 0x42, 0x01, 0xdb, 0x00, 0x23, + 0x69, 0xe1, 0x06, 0x9b, 0x00, 0x22, 0x1e, 0x02, 0x12, 0xab, 0x01, 0x93, + 0x05, 0x23, 0x15, 0x21, 0x00, 0x93, 0x28, 0x00, 0x33, 0x00, 0xff, 0xf7, + 0x86, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0xe5, 0xe0, 0x07, 0x9b, 0x06, 0x99, + 0x00, 0x22, 0x8b, 0x42, 0x07, 0xd8, 0xca, 0x0f, 0x07, 0x9b, 0xc6, 0x49, + 0x06, 0x98, 0x5b, 0x18, 0xd9, 0x17, 0x83, 0x42, 0x4a, 0x41, 0x06, 0x9b, + 0x07, 0x99, 0x58, 0x1a, 0x01, 0x21, 0x43, 0x08, 0x05, 0x93, 0x06, 0x9b, + 0x19, 0x40, 0x89, 0x00, 0x00, 0x2a, 0x0f, 0xd0, 0x12, 0xab, 0x1b, 0x79, + 0x5f, 0xb2, 0x00, 0x2f, 0x0a, 0xda, 0x01, 0x20, 0x03, 0x42, 0x07, 0xd1, + 0x6b, 0x6a, 0x05, 0x98, 0x1b, 0x18, 0x01, 0x20, 0x88, 0x40, 0x1f, 0x78, + 0x07, 0x43, 0x1f, 0x70, 0x12, 0xab, 0x1f, 0x79, 0x7b, 0xb2, 0x9c, 0x46, + 0x00, 0x23, 0x60, 0x46, 0x98, 0x42, 0x00, 0xdb, 0x22, 0xe1, 0x45, 0x20, + 0x07, 0x40, 0x40, 0x2f, 0x00, 0xd0, 0x1d, 0xe1, 0x9a, 0x42, 0x08, 0xd0, + 0x6b, 0x6a, 0x05, 0x9a, 0x02, 0x31, 0x98, 0x18, 0x01, 0x23, 0x8b, 0x40, + 0x02, 0x78, 0x13, 0x43, 0x03, 0x70, 0x2b, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x15, 0x21, 0x33, 0x00, 0x28, 0x00, + 0xff, 0xf7, 0x37, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0x96, 0xe0, 0x2b, 0x6a, + 0x05, 0x93, 0x12, 0xab, 0x5b, 0x88, 0x09, 0x93, 0x00, 0x2b, 0x00, 0xd0, + 0x81, 0xe0, 0x05, 0x9b, 0x2e, 0x33, 0x0b, 0x93, 0x69, 0x23, 0x0c, 0x93, + 0x00, 0x23, 0x08, 0x93, 0x08, 0x9b, 0x0b, 0x9a, 0x5b, 0x00, 0xd6, 0x5a, + 0x07, 0x9a, 0x00, 0x23, 0xb2, 0x42, 0x06, 0xd8, 0x13, 0x00, 0x96, 0x4a, + 0xf1, 0x0f, 0x9a, 0x18, 0xd3, 0x17, 0xb2, 0x42, 0x4b, 0x41, 0x94, 0x4a, + 0x94, 0x49, 0xb2, 0x18, 0x92, 0xb2, 0x8a, 0x42, 0x05, 0xd9, 0x00, 0x2b, + 0x00, 0xd1, 0x8b, 0xe0, 0x33, 0x07, 0x00, 0xd0, 0x92, 0xe0, 0x16, 0x27, + 0x09, 0x9b, 0x08, 0x9a, 0x28, 0x00, 0x9e, 0x18, 0x05, 0x9a, 0x05, 0x9b, + 0x51, 0x78, 0x1b, 0x78, 0x09, 0x02, 0x19, 0x43, 0x0c, 0xab, 0xff, 0x18, + 0xb6, 0xb2, 0x49, 0x04, 0x00, 0x23, 0x49, 0x0c, 0x00, 0x97, 0x32, 0x00, + 0x01, 0xf0, 0x2a, 0xfd, 0x85, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x51, 0xd1, + 0x00, 0x23, 0x3b, 0x80, 0x3b, 0x88, 0x00, 0x2b, 0x16, 0xd1, 0xfc, 0x20, + 0x05, 0x99, 0x05, 0x9a, 0x49, 0x78, 0x12, 0x78, 0x09, 0x02, 0x11, 0x43, + 0x14, 0xaa, 0x10, 0x71, 0x01, 0x20, 0x49, 0x04, 0x49, 0x0c, 0x11, 0x80, + 0x56, 0x80, 0x02, 0x90, 0x03, 0x97, 0x01, 0x93, 0x00, 0x93, 0x28, 0x00, + 0x01, 0xf0, 0x7c, 0xfd, 0x04, 0x1e, 0x37, 0xdb, 0x16, 0x23, 0x0c, 0xaa, + 0x05, 0x99, 0x9b, 0x18, 0x05, 0x9a, 0x49, 0x78, 0x12, 0x78, 0x09, 0x02, + 0x11, 0x43, 0x80, 0x22, 0x12, 0x02, 0x11, 0x43, 0x06, 0x9a, 0x1b, 0x88, + 0x28, 0x00, 0x00, 0x92, 0x32, 0x00, 0xff, 0xf7, 0x41, 0xfa, 0x6d, 0x4b, + 0x04, 0x00, 0xc3, 0x18, 0xee, 0x6c, 0x02, 0x2b, 0x28, 0xd8, 0x00, 0x2e, + 0x09, 0xd0, 0x05, 0x9a, 0x05, 0x9b, 0x52, 0x78, 0x1b, 0x78, 0x12, 0x02, + 0x1a, 0x43, 0x06, 0x21, 0x00, 0x23, 0x02, 0x20, 0xb0, 0x47, 0x06, 0x99, + 0x28, 0x00, 0x01, 0xf0, 0xd3, 0xfd, 0x04, 0x00, 0x25, 0xe0, 0x7c, 0x22, + 0x09, 0x9b, 0x0c, 0x92, 0x53, 0x43, 0x13, 0x3b, 0x9b, 0xb2, 0x09, 0x93, + 0x05, 0x9b, 0x08, 0x33, 0x0b, 0x93, 0x77, 0xe7, 0x00, 0x28, 0xad, 0xda, + 0xee, 0x6c, 0x00, 0x2e, 0x00, 0xd1, 0x80, 0xe0, 0x00, 0x23, 0x22, 0x00, + 0x01, 0x21, 0x02, 0x20, 0xb0, 0x47, 0x7a, 0xe0, 0x00, 0x2e, 0x0c, 0xd0, + 0x05, 0x9b, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, 0x13, 0x43, 0x05, 0x9a, + 0x11, 0x78, 0x52, 0x78, 0x12, 0x02, 0x0a, 0x43, 0x02, 0x21, 0x08, 0x00, + 0xb0, 0x47, 0x00, 0x2c, 0xe4, 0xdb, 0x01, 0x23, 0x08, 0x9a, 0x01, 0x32, + 0x08, 0x92, 0x00, 0x2b, 0x4c, 0xd1, 0x0c, 0x99, 0x8a, 0x42, 0x00, 0xd0, + 0x52, 0xe7, 0x47, 0xe0, 0x05, 0x22, 0x14, 0xaf, 0x00, 0x92, 0x33, 0x02, + 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xff, 0xf7, 0x6d, 0xf8, + 0x04, 0x1e, 0xcd, 0xdb, 0x12, 0xab, 0x1a, 0x88, 0x39, 0x88, 0x41, 0x4b, + 0x13, 0x40, 0x99, 0x42, 0x0b, 0xd1, 0x09, 0x9b, 0x08, 0x98, 0x79, 0x88, + 0x1b, 0x18, 0x99, 0x42, 0x05, 0xd1, 0x7a, 0x21, 0x3b, 0x79, 0x8b, 0x43, + 0x84, 0x2b, 0x00, 0xd1, 0x7d, 0xe0, 0x16, 0x27, 0x08, 0x99, 0x09, 0x9b, + 0x52, 0x04, 0x5b, 0x18, 0x9b, 0xb2, 0x0d, 0x93, 0x0c, 0xab, 0xff, 0x18, + 0x51, 0x0c, 0x33, 0x00, 0x00, 0x97, 0x0d, 0x9a, 0x28, 0x00, 0x01, 0xf0, + 0x7d, 0xfc, 0x2f, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x37, 0xd1, 0x00, 0x23, + 0x3b, 0x80, 0x3b, 0x88, 0x12, 0xae, 0x31, 0x88, 0x00, 0x2b, 0x33, 0xd1, + 0xec, 0x6c, 0x00, 0x2c, 0x03, 0xd0, 0x0a, 0x00, 0x02, 0x20, 0x06, 0x21, + 0xa0, 0x47, 0x31, 0x88, 0x28, 0x00, 0xff, 0xf7, 0x8d, 0xf9, 0x04, 0x1e, + 0x92, 0xdb, 0x00, 0x23, 0x06, 0x9a, 0x01, 0x32, 0x92, 0xb2, 0x06, 0x92, + 0x00, 0x2b, 0x00, 0xd1, 0x8f, 0xe6, 0x0a, 0x9a, 0x01, 0x32, 0x92, 0xb2, + 0x0a, 0x92, 0x00, 0x2b, 0x00, 0xd1, 0x59, 0xe6, 0xeb, 0x68, 0x07, 0x9a, + 0x1b, 0x01, 0x9a, 0x42, 0x00, 0xd2, 0x48, 0xe6, 0x00, 0x2c, 0x00, 0xd0, + 0x7a, 0xe7, 0xed, 0x6c, 0x00, 0x2d, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, + 0x19, 0x00, 0x52, 0x00, 0x02, 0x20, 0xa8, 0x47, 0x20, 0x00, 0x17, 0xb0, + 0xf0, 0xbd, 0x00, 0x28, 0xc7, 0xda, 0x6b, 0xe7, 0x06, 0x9a, 0x28, 0x00, + 0x00, 0x92, 0x0d, 0x9a, 0xff, 0xf7, 0x82, 0xf9, 0x0d, 0x4b, 0x04, 0x00, + 0xc3, 0x18, 0xef, 0x6c, 0x02, 0x2b, 0x19, 0xd8, 0x32, 0x88, 0x00, 0x2f, + 0x03, 0xd0, 0x00, 0x23, 0x06, 0x21, 0x02, 0x20, 0xb8, 0x47, 0x12, 0xab, + 0x19, 0x88, 0x28, 0x00, 0xff, 0xf7, 0x4c, 0xf9, 0x43, 0xe7, 0xc0, 0x46, + 0xff, 0x01, 0x00, 0x00, 0xff, 0xdf, 0xff, 0xff, 0xfd, 0xdf, 0x00, 0x00, + 0xee, 0xd8, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, 0xff, 0x7f, 0xff, 0xff, + 0x00, 0x2f, 0x00, 0xd1, 0x5b, 0xe7, 0x02, 0x21, 0x73, 0x88, 0x32, 0x88, + 0x08, 0x00, 0xb8, 0x47, 0x55, 0xe7, 0x01, 0x21, 0x07, 0x9b, 0xf7, 0x1a, + 0x6b, 0x6a, 0x7f, 0x08, 0x0e, 0x40, 0xb6, 0x00, 0xdb, 0x5d, 0x76, 0x18, + 0x33, 0x41, 0x0b, 0x40, 0x16, 0xd0, 0xec, 0x6c, 0x00, 0x2c, 0x03, 0xd0, + 0x00, 0x23, 0x05, 0x31, 0x02, 0x20, 0xa0, 0x47, 0x12, 0xab, 0x19, 0x88, + 0x28, 0x00, 0xff, 0xf7, 0x1d, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0x21, 0xe7, + 0x06, 0x99, 0x28, 0x00, 0x01, 0xf0, 0xe2, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0x1a, 0xe7, 0x01, 0x23, 0x01, 0x21, 0xb1, 0x40, 0x6a, 0x6a, 0xd7, 0x19, + 0x3a, 0x78, 0x0a, 0x43, 0x3a, 0x70, 0x2d, 0xe7, 0x01, 0x23, 0x08, 0x93, + 0x06, 0x9a, 0x6b, 0x6a, 0x9b, 0x5c, 0x08, 0x9a, 0x92, 0x00, 0x13, 0x41, + 0x07, 0x22, 0x1a, 0x40, 0x09, 0x92, 0x01, 0x2a, 0x00, 0xd0, 0x93, 0xe0, + 0x08, 0x9a, 0x0a, 0x9b, 0x12, 0xae, 0x9b, 0x18, 0x05, 0x22, 0x9b, 0xb2, + 0x05, 0x93, 0x00, 0x92, 0x1b, 0x02, 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, + 0x28, 0x00, 0xfe, 0xf7, 0x92, 0xff, 0x04, 0x1e, 0x00, 0xda, 0xf1, 0xe6, + 0x16, 0x27, 0x0c, 0xab, 0xff, 0x18, 0x11, 0xab, 0x72, 0x88, 0x31, 0x88, + 0x28, 0x00, 0x00, 0x93, 0x3b, 0x00, 0xff, 0xf7, 0xa5, 0xf8, 0x04, 0x1e, + 0x61, 0xd1, 0x80, 0x22, 0x3b, 0x88, 0x92, 0x01, 0x93, 0x42, 0x20, 0xd8, + 0x1a, 0x07, 0x1e, 0xd0, 0x05, 0x22, 0x14, 0xaf, 0x00, 0x92, 0x1b, 0x02, + 0x02, 0x00, 0x01, 0x97, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x71, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0xd0, 0xe6, 0x38, 0x4a, 0x33, 0x88, 0x13, 0x40, + 0x3a, 0x88, 0x93, 0x42, 0x04, 0xd1, 0x78, 0x22, 0x3b, 0x79, 0x93, 0x43, + 0x84, 0x2b, 0x45, 0xd0, 0x16, 0x23, 0x0c, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0x05, 0x9a, 0x93, 0x42, 0x4e, 0xd0, 0x11, 0xab, 0x1b, 0x88, 0x12, 0xae, + 0x72, 0x88, 0x31, 0x88, 0x28, 0x00, 0x00, 0x93, 0x05, 0x9b, 0xff, 0xf7, + 0xd1, 0xf8, 0x2b, 0x4b, 0x04, 0x00, 0xc3, 0x18, 0xef, 0x6c, 0x02, 0x2b, + 0x45, 0xd8, 0x00, 0x2f, 0x04, 0xd0, 0x32, 0x88, 0x00, 0x23, 0x06, 0x21, + 0x02, 0x20, 0xb8, 0x47, 0x05, 0x99, 0x28, 0x00, 0x01, 0xf0, 0x68, 0xfc, + 0x04, 0x1e, 0x00, 0xda, 0xa0, 0xe6, 0x31, 0x88, 0x28, 0x00, 0xff, 0xf7, + 0x95, 0xf8, 0x04, 0x00, 0x00, 0x2c, 0x00, 0xda, 0x98, 0xe6, 0x06, 0x9b, + 0x01, 0x33, 0x06, 0x93, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x0d, 0xe7, + 0x06, 0x9b, 0x1a, 0x00, 0x80, 0x23, 0x5b, 0x00, 0x9a, 0x42, 0x00, 0xd0, + 0x66, 0xe5, 0x80, 0x22, 0x92, 0x00, 0x94, 0x46, 0x07, 0x9b, 0x63, 0x44, + 0x9b, 0xb2, 0x07, 0x93, 0xfe, 0xe6, 0x13, 0x4b, 0x98, 0x42, 0x0c, 0xd1, + 0xec, 0x6c, 0x00, 0x2c, 0x04, 0xd0, 0x00, 0x23, 0x05, 0x9a, 0x05, 0x21, + 0x02, 0x20, 0xa0, 0x47, 0x05, 0x99, 0x28, 0x00, 0x01, 0xf0, 0x38, 0xfc, + 0x04, 0x00, 0x00, 0x2c, 0x00, 0xda, 0x6f, 0xe6, 0x08, 0x9b, 0x01, 0x2b, + 0x00, 0xd0, 0x59, 0xe7, 0x00, 0x23, 0x09, 0x93, 0xcf, 0xe7, 0x00, 0x2f, + 0xca, 0xd0, 0x02, 0x21, 0x73, 0x88, 0x32, 0x88, 0x08, 0x00, 0xb8, 0x47, + 0xc4, 0xe7, 0xc0, 0x46, 0xff, 0x7f, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, + 0xee, 0xd8, 0xff, 0xff, 0x80, 0x22, 0xf0, 0xb5, 0x06, 0x00, 0x89, 0xb0, + 0x00, 0x21, 0x52, 0x00, 0x40, 0x6a, 0x04, 0xf0, 0x38, 0xf9, 0x00, 0x21, + 0xf4, 0x6c, 0x07, 0x91, 0x8c, 0x42, 0x03, 0xd0, 0x0b, 0x00, 0x0a, 0x00, + 0x01, 0x20, 0xa0, 0x47, 0x00, 0x24, 0x07, 0xab, 0x03, 0x93, 0x14, 0x4b, + 0x05, 0x94, 0x01, 0x93, 0x04, 0x94, 0x23, 0x00, 0x02, 0x94, 0x00, 0x94, + 0x22, 0x00, 0x21, 0x00, 0x30, 0x00, 0x01, 0xf0, 0x2f, 0xf9, 0x0f, 0x4b, + 0x05, 0x00, 0x98, 0x42, 0x15, 0xd0, 0xa0, 0x42, 0x07, 0xd0, 0xf7, 0x6c, + 0xa7, 0x42, 0x04, 0xd0, 0x01, 0x21, 0x02, 0x00, 0x23, 0x00, 0x08, 0x00, + 0xb8, 0x47, 0xf4, 0x6c, 0x00, 0x2c, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, + 0x19, 0x00, 0x52, 0x00, 0x01, 0x20, 0xa0, 0x47, 0x28, 0x00, 0x09, 0xb0, + 0xf0, 0xbd, 0x25, 0x00, 0xf1, 0xe7, 0xc0, 0x46, 0xe9, 0x31, 0x00, 0x00, + 0xa8, 0xd8, 0xff, 0xff, 0xf8, 0xb5, 0x06, 0x00, 0x0c, 0x00, 0x01, 0xf0, + 0xcf, 0xf9, 0x05, 0x1e, 0x0c, 0xdb, 0x24, 0x01, 0xa4, 0xb2, 0x27, 0x00, + 0x10, 0x37, 0xbf, 0xb2, 0x21, 0x00, 0x01, 0x34, 0x30, 0x00, 0xa4, 0xb2, + 0xfe, 0xf7, 0x96, 0xfe, 0xbc, 0x42, 0xf7, 0xd1, 0x28, 0x00, 0xf8, 0xbd, + 0xf0, 0xb5, 0x05, 0x00, 0x0f, 0x00, 0x00, 0x24, 0xc3, 0x68, 0x87, 0xb0, + 0x03, 0x93, 0x03, 0x6a, 0x02, 0x93, 0xa2, 0xb2, 0x04, 0x92, 0x03, 0x9a, + 0x23, 0x03, 0xa2, 0x42, 0x01, 0xd1, 0x1e, 0x48, 0x35, 0xe0, 0x2a, 0x6a, + 0x14, 0x21, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x28, 0x00, + 0x00, 0x22, 0xfe, 0xf7, 0x84, 0xfe, 0x02, 0x99, 0x18, 0x4e, 0x0b, 0x00, + 0x1e, 0x33, 0x05, 0x93, 0x00, 0x23, 0xb4, 0x46, 0x1a, 0x00, 0x98, 0x42, + 0x0b, 0xd0, 0x01, 0x28, 0x13, 0xd9, 0x01, 0x34, 0x00, 0x28, 0x1c, 0xd1, + 0xdd, 0xe7, 0x08, 0x88, 0x00, 0x28, 0x06, 0xd1, 0x01, 0x32, 0x92, 0xb2, + 0x02, 0x31, 0x05, 0x98, 0x81, 0x42, 0xf6, 0xd1, 0x05, 0xe0, 0x60, 0x45, + 0x03, 0xd1, 0x01, 0x33, 0x9b, 0xb2, 0xbb, 0x42, 0xf4, 0xd9, 0xd1, 0x18, + 0x0f, 0x29, 0x0a, 0xd1, 0xbb, 0x42, 0x08, 0xd8, 0xeb, 0x6b, 0x04, 0x99, + 0x9a, 0x1a, 0xea, 0x63, 0x28, 0x00, 0xff, 0xf7, 0xa3, 0xff, 0x07, 0xb0, + 0xf0, 0xbd, 0x01, 0x34, 0xbd, 0xe7, 0xc0, 0x46, 0xd3, 0xd8, 0xff, 0xff, + 0xff, 0xff, 0x00, 0x00, 0xf7, 0xb5, 0x80, 0x22, 0x04, 0x6a, 0x52, 0x00, + 0x0b, 0x03, 0x00, 0x92, 0x14, 0x21, 0x00, 0x22, 0x01, 0x94, 0x05, 0x00, + 0x26, 0x00, 0xfe, 0xf7, 0x42, 0xfe, 0x00, 0x22, 0x23, 0x00, 0x1e, 0x36, + 0x11, 0x00, 0x0b, 0x4f, 0x90, 0x42, 0x0d, 0xd0, 0xab, 0x6b, 0x9a, 0x1a, + 0xeb, 0x6b, 0xaa, 0x63, 0x59, 0x1a, 0xe9, 0x63, 0xfe, 0xbd, 0x1c, 0x88, + 0xbc, 0x42, 0x02, 0xd0, 0x00, 0x2c, 0x04, 0xd1, 0x01, 0x31, 0x02, 0x33, + 0x9e, 0x42, 0xf6, 0xd1, 0xee, 0xe7, 0x01, 0x32, 0xf9, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xf0, 0xb5, 0x1d, 0x00, 0xc3, 0x68, 0x93, 0xb0, + 0x05, 0x93, 0x03, 0x6a, 0x04, 0x00, 0x0c, 0x93, 0x05, 0x9b, 0x0f, 0x00, + 0x08, 0x92, 0x03, 0x93, 0x29, 0x2b, 0x01, 0xd9, 0x29, 0x23, 0x03, 0x93, + 0x00, 0x26, 0x80, 0x22, 0x08, 0x9b, 0x52, 0x00, 0x1e, 0x60, 0xff, 0x21, + 0x60, 0x6a, 0x04, 0xf0, 0x56, 0xf8, 0x63, 0x6a, 0x02, 0x96, 0x06, 0x93, + 0x03, 0x9b, 0x06, 0x9a, 0x5b, 0x00, 0xd3, 0x18, 0x03, 0x22, 0x09, 0x93, + 0x03, 0x33, 0x93, 0x43, 0x0a, 0x93, 0x06, 0x9b, 0x0a, 0x9a, 0x3b, 0x60, + 0x6b, 0x42, 0x5d, 0x41, 0x32, 0x23, 0x6d, 0x42, 0x2b, 0x40, 0x0f, 0x93, + 0x03, 0x9b, 0x9b, 0x00, 0x9b, 0x18, 0x0e, 0x93, 0x6a, 0x46, 0x12, 0x89, + 0x02, 0x9b, 0x0d, 0x92, 0x05, 0x99, 0x02, 0x9a, 0x1b, 0x03, 0x8a, 0x42, + 0x01, 0xd1, 0x00, 0x20, 0x4f, 0xe0, 0x22, 0x6a, 0x14, 0x21, 0x01, 0x92, + 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x20, 0x00, 0x00, 0x22, 0xfe, 0xf7, + 0xde, 0xfd, 0x0c, 0x9b, 0x00, 0x25, 0x19, 0x00, 0x2f, 0x00, 0x1e, 0x31, + 0x3a, 0x4e, 0xa8, 0x42, 0x47, 0xd0, 0x01, 0x28, 0x3b, 0xd1, 0x0e, 0x26, + 0x6b, 0x46, 0x0e, 0xaa, 0xb6, 0x18, 0x02, 0x22, 0x1b, 0x89, 0x15, 0x21, + 0x1b, 0x03, 0x00, 0x92, 0xfe, 0x33, 0x01, 0x96, 0x00, 0x22, 0x20, 0x00, + 0xfe, 0xf7, 0xc5, 0xfd, 0x00, 0x28, 0x2a, 0xdb, 0x23, 0x1d, 0xda, 0x8f, + 0x33, 0x88, 0x9a, 0x42, 0x35, 0xd9, 0xd3, 0x1a, 0x05, 0x22, 0x57, 0x43, + 0x0f, 0x9a, 0x9b, 0xb2, 0x53, 0x43, 0x7d, 0x1b, 0xeb, 0x18, 0x07, 0x93, + 0x00, 0x23, 0x06, 0x99, 0x27, 0x4d, 0x03, 0x9a, 0x93, 0x42, 0x0b, 0xda, + 0x0a, 0x9e, 0x9a, 0x00, 0x92, 0x19, 0x0e, 0x88, 0x0b, 0x91, 0xae, 0x42, + 0x22, 0xd1, 0x6b, 0x46, 0x9b, 0x8e, 0x0b, 0x80, 0x07, 0x9b, 0x13, 0x60, + 0x08, 0x9b, 0x08, 0x9a, 0x1b, 0x68, 0x04, 0x93, 0x01, 0x33, 0x13, 0x60, + 0x02, 0x9b, 0x01, 0x33, 0x02, 0x93, 0x00, 0x28, 0xa4, 0xd0, 0x13, 0xb0, + 0xf0, 0xbd, 0x1a, 0x88, 0xb2, 0x42, 0xbe, 0xd0, 0x00, 0x2a, 0x05, 0xd1, + 0x01, 0x37, 0xbf, 0xb2, 0x02, 0x33, 0x99, 0x42, 0xf5, 0xd1, 0xb6, 0xe7, + 0x01, 0x35, 0xad, 0xb2, 0xf8, 0xe7, 0x9b, 0x1a, 0xdb, 0x43, 0xc7, 0xe7, + 0x0b, 0x99, 0x16, 0x68, 0x07, 0x9f, 0x02, 0x31, 0xbe, 0x42, 0x19, 0xda, + 0x03, 0x99, 0x09, 0x9d, 0x02, 0x39, 0x04, 0x91, 0x0e, 0x99, 0x04, 0x9e, + 0x02, 0x3d, 0x0f, 0x1f, 0xb3, 0x42, 0x04, 0xdd, 0x69, 0x46, 0x0b, 0x9b, + 0x89, 0x8e, 0x19, 0x80, 0xca, 0xe7, 0xae, 0x1e, 0x08, 0x39, 0x36, 0x88, + 0x09, 0x68, 0x2e, 0x80, 0x39, 0x60, 0x04, 0x99, 0x01, 0x39, 0x04, 0x91, + 0x39, 0x00, 0xea, 0xe7, 0x01, 0x33, 0xb0, 0xe7, 0xff, 0xff, 0x00, 0x00, + 0xf0, 0xb5, 0x05, 0x00, 0x03, 0x6a, 0x9b, 0xb0, 0x0f, 0x93, 0x43, 0x6a, + 0x0c, 0x00, 0x14, 0x22, 0x00, 0x21, 0x15, 0xa8, 0x0a, 0x93, 0x03, 0xf0, + 0x9e, 0xff, 0x2b, 0x8a, 0xa3, 0x42, 0x06, 0xd1, 0x60, 0x1c, 0xe9, 0x68, + 0x03, 0xf0, 0x64, 0xff, 0x00, 0x23, 0x29, 0x82, 0x6b, 0x61, 0x23, 0x01, + 0x01, 0x33, 0x9b, 0xb2, 0x11, 0x93, 0x0f, 0x9b, 0x24, 0x03, 0x1b, 0x19, + 0x10, 0x93, 0x00, 0x23, 0x08, 0x93, 0x8f, 0xe1, 0x0c, 0x9a, 0x10, 0x9b, + 0x14, 0x21, 0x9b, 0x1a, 0x0d, 0x93, 0x2b, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x28, 0x00, 0x0d, 0x9b, 0xfe, 0xf7, + 0x30, 0xfd, 0x04, 0x00, 0x00, 0x2c, 0x07, 0xd1, 0x07, 0x9b, 0x0e, 0x9a, + 0x9b, 0x1a, 0x7f, 0x2b, 0x02, 0xdc, 0x07, 0x9b, 0x0e, 0x2b, 0x01, 0xdd, + 0x3b, 0x00, 0x88, 0xe0, 0x07, 0x9b, 0x0c, 0x9a, 0x5b, 0x00, 0xd3, 0x5a, + 0x07, 0x9a, 0x09, 0x93, 0x11, 0x9b, 0x9b, 0x18, 0x9b, 0xb2, 0x15, 0xaa, + 0x08, 0x93, 0x13, 0x78, 0x01, 0x2b, 0x15, 0xd0, 0x00, 0x2b, 0x04, 0xd0, + 0x02, 0x2b, 0x00, 0xd1, 0x8f, 0xe0, 0x23, 0x00, 0x6d, 0xe0, 0x6b, 0x46, + 0x24, 0x21, 0x59, 0x5e, 0x3b, 0x00, 0x00, 0x29, 0x00, 0xdc, 0x66, 0xe0, + 0x6b, 0x46, 0x9b, 0x8c, 0x17, 0x74, 0x53, 0x80, 0x6b, 0x46, 0x1b, 0x8c, + 0x13, 0x81, 0xee, 0xe7, 0x52, 0x88, 0x09, 0x99, 0x3b, 0x00, 0x8a, 0x42, + 0x59, 0xd1, 0x05, 0x22, 0x08, 0x9b, 0x13, 0xae, 0x00, 0x92, 0x1b, 0x02, + 0x22, 0x00, 0x01, 0x96, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0xef, 0xfc, + 0x04, 0x1e, 0x2d, 0xdb, 0x73, 0x88, 0x00, 0x20, 0x68, 0x2b, 0x05, 0xd9, + 0x69, 0x3b, 0x18, 0x00, 0x7c, 0x21, 0x03, 0xf0, 0x75, 0xfe, 0x01, 0x30, + 0x15, 0xab, 0x9e, 0x88, 0x86, 0x42, 0x3d, 0xd1, 0x13, 0xab, 0x1a, 0x79, + 0x7f, 0x2a, 0x1e, 0xd9, 0x1a, 0x22, 0x0c, 0xa9, 0x52, 0x18, 0x02, 0x92, + 0x08, 0x9a, 0x00, 0x93, 0x01, 0x92, 0x00, 0x22, 0x09, 0x9b, 0x11, 0x00, + 0x28, 0x00, 0x01, 0xf0, 0x25, 0xfa, 0x04, 0x1e, 0x0c, 0xdb, 0x2b, 0x6a, + 0x00, 0x22, 0x01, 0x93, 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x14, 0x21, + 0x0d, 0x9b, 0x28, 0x00, 0xfe, 0xf7, 0xc1, 0xfc, 0x04, 0x1e, 0x0e, 0xda, + 0x20, 0x00, 0x1b, 0xb0, 0xf0, 0xbd, 0x08, 0x99, 0x28, 0x00, 0x01, 0xf0, + 0xdf, 0xf9, 0x04, 0x1e, 0xf6, 0xdb, 0x1a, 0x23, 0x0c, 0xaa, 0x9b, 0x18, + 0x01, 0x22, 0x52, 0x42, 0x1a, 0x80, 0x13, 0xab, 0x58, 0x88, 0x1a, 0x23, + 0x0c, 0xaa, 0x9b, 0x18, 0x1b, 0x88, 0x09, 0x93, 0x00, 0x2e, 0x1c, 0xd1, + 0x17, 0x30, 0x6a, 0x46, 0x0a, 0x9b, 0x92, 0x8c, 0x40, 0x00, 0x1a, 0x52, + 0x3b, 0x00, 0x07, 0x9a, 0x01, 0x32, 0x07, 0x92, 0x00, 0x2b, 0x00, 0xd0, + 0x6a, 0xe7, 0x0b, 0x9a, 0x01, 0x32, 0x0b, 0x92, 0x00, 0x2b, 0x6b, 0xd0, + 0x0e, 0x9b, 0x80, 0x33, 0x0e, 0x93, 0x0c, 0x9b, 0x01, 0x3b, 0xff, 0x3b, + 0x0c, 0x93, 0x00, 0x2c, 0x00, 0xd1, 0x2d, 0xe1, 0xca, 0xe7, 0x68, 0x28, + 0x01, 0xd8, 0x04, 0x30, 0xdf, 0xe7, 0x69, 0x38, 0x7c, 0x21, 0x03, 0xf0, + 0x99, 0xfe, 0x08, 0x1d, 0xd9, 0xe7, 0x09, 0x9b, 0x98, 0x4a, 0x99, 0x49, + 0x9a, 0x18, 0x92, 0xb2, 0x3b, 0x00, 0x8a, 0x42, 0xd7, 0xd8, 0x05, 0x22, + 0x08, 0x9b, 0x13, 0xae, 0x00, 0x92, 0x1b, 0x02, 0x22, 0x00, 0x01, 0x96, + 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x6d, 0xfc, 0x04, 0x1e, 0xab, 0xdb, + 0x33, 0x79, 0x7f, 0x2b, 0x2b, 0xd9, 0x1a, 0x23, 0x0c, 0xaa, 0x9b, 0x18, + 0x00, 0x22, 0x02, 0x93, 0x08, 0x9b, 0x00, 0x96, 0x01, 0x93, 0x11, 0x00, + 0x09, 0x9b, 0x28, 0x00, 0x01, 0xf0, 0xb2, 0xf9, 0x04, 0x1e, 0x00, 0xda, + 0x98, 0xe7, 0x00, 0x24, 0x0c, 0xab, 0x02, 0x94, 0x5b, 0x8b, 0x13, 0xa9, + 0x01, 0x93, 0x4b, 0x88, 0x03, 0x22, 0x00, 0x93, 0x28, 0x00, 0x09, 0x9b, + 0x01, 0xf0, 0x20, 0xfa, 0x2b, 0x6a, 0x22, 0x00, 0x01, 0x93, 0x80, 0x23, + 0x5b, 0x00, 0x00, 0x93, 0x14, 0x21, 0x0d, 0x9b, 0x28, 0x00, 0xfe, 0xf7, + 0x40, 0xfc, 0x04, 0x00, 0x00, 0x2c, 0x9b, 0xda, 0x7c, 0xe7, 0x08, 0x99, + 0x28, 0x00, 0x01, 0xf0, 0x5f, 0xf9, 0x04, 0x1e, 0xf6, 0xd1, 0x00, 0x21, + 0x08, 0x9b, 0x02, 0x91, 0x01, 0x93, 0x13, 0xab, 0x5b, 0x88, 0x02, 0x22, + 0x00, 0x93, 0x28, 0x00, 0x09, 0x9b, 0x01, 0xf0, 0xff, 0xf9, 0x87, 0xe7, + 0x00, 0x2c, 0x00, 0xd1, 0xcc, 0xe0, 0x65, 0xe7, 0x0b, 0x7c, 0x00, 0x2b, + 0x70, 0xd0, 0x07, 0x9b, 0x05, 0x22, 0xcb, 0x60, 0x01, 0x23, 0x0b, 0x70, + 0x08, 0x9b, 0x13, 0xaf, 0x00, 0x92, 0x1b, 0x02, 0x01, 0x97, 0x32, 0x00, + 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x13, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0x50, 0xe7, 0x78, 0x88, 0x37, 0x00, 0x68, 0x28, 0x05, 0xd9, 0x69, 0x38, + 0x7c, 0x21, 0x03, 0xf0, 0x99, 0xfd, 0x01, 0x30, 0x87, 0xb2, 0x80, 0x23, + 0x15, 0xae, 0x71, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1a, 0x23, 0x0c, 0xaa, + 0x9b, 0x18, 0xb7, 0x80, 0x3a, 0x00, 0x00, 0x93, 0x28, 0x00, 0x00, 0x23, + 0x01, 0xf0, 0x2c, 0xf8, 0x56, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x0c, 0xd1, + 0x31, 0x89, 0x28, 0x00, 0x01, 0xf0, 0x16, 0xf9, 0x04, 0x1e, 0x00, 0xda, + 0x2c, 0xe7, 0x00, 0x23, 0x33, 0x70, 0x00, 0x2c, 0x00, 0xd0, 0x27, 0xe7, + 0x71, 0xe0, 0x00, 0x28, 0x00, 0xda, 0x23, 0xe7, 0x6a, 0x6a, 0x0c, 0xab, + 0x5b, 0x8b, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x1b, 0x02, + 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0xd6, 0xfb, 0x04, 0x1e, + 0x00, 0xda, 0x13, 0xe7, 0x0a, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x13, 0xd4, + 0x5a, 0xb2, 0x00, 0x2a, 0x12, 0xda, 0x9a, 0x07, 0x12, 0xd4, 0x04, 0x22, + 0x1a, 0x40, 0x11, 0xd1, 0x0a, 0x9b, 0x99, 0x78, 0xdb, 0x78, 0x1b, 0x02, + 0x0b, 0x43, 0xbb, 0x42, 0x0c, 0xd1, 0x0c, 0xab, 0x5b, 0x8b, 0x07, 0x92, + 0xf3, 0x80, 0xd0, 0xe7, 0x39, 0x4c, 0xf9, 0xe6, 0x39, 0x4c, 0xf7, 0xe6, + 0x39, 0x4c, 0xf5, 0xe6, 0x39, 0x4c, 0xf3, 0xe6, 0x39, 0x4c, 0xf1, 0xe6, + 0x02, 0x22, 0x0a, 0x70, 0x07, 0x93, 0x38, 0xe0, 0x80, 0x22, 0x00, 0x26, + 0xcb, 0x68, 0x12, 0x02, 0x07, 0x93, 0x4b, 0x88, 0x0e, 0x70, 0x09, 0x93, + 0x1a, 0x43, 0xcb, 0x88, 0x89, 0x88, 0x68, 0x6a, 0x13, 0xaf, 0xb1, 0x42, + 0x0b, 0xd1, 0x00, 0x90, 0x04, 0x97, 0x03, 0x91, 0x02, 0x91, 0x01, 0x91, + 0x28, 0x00, 0x01, 0xf0, 0x93, 0xfa, 0x04, 0x00, 0xb0, 0x42, 0xa8, 0xda, + 0xd2, 0xe6, 0x01, 0x93, 0x02, 0x97, 0x13, 0x00, 0x00, 0x96, 0x02, 0x00, + 0x31, 0x00, 0x28, 0x00, 0x01, 0xf0, 0xe0, 0xf8, 0x04, 0x1e, 0x00, 0xda, + 0xc6, 0xe6, 0x02, 0x96, 0x3b, 0x88, 0x69, 0x6a, 0x01, 0x93, 0x0a, 0x9b, + 0x28, 0x00, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, 0x13, 0x43, 0x00, 0x93, + 0x32, 0x00, 0x09, 0x9b, 0x01, 0xf0, 0x4c, 0xf9, 0x8b, 0xe7, 0x03, 0x23, + 0x0b, 0x70, 0x15, 0xab, 0x1a, 0x78, 0x00, 0x24, 0x03, 0x2a, 0x00, 0xd1, + 0xae, 0xe6, 0x7f, 0x22, 0x01, 0x27, 0x1c, 0x74, 0x07, 0x9b, 0xdb, 0x17, + 0x13, 0x40, 0x07, 0x9a, 0x9b, 0x18, 0xdb, 0x11, 0x0b, 0x93, 0xdb, 0x01, + 0x0e, 0x93, 0x0b, 0x9b, 0x0f, 0x9a, 0x1b, 0x02, 0xd3, 0x1a, 0x0c, 0x93, + 0x0b, 0x9b, 0x00, 0x2b, 0x00, 0xdc, 0x19, 0xe6, 0x15, 0xa9, 0x0e, 0x78, + 0x01, 0x2e, 0xa7, 0xd0, 0x00, 0x2e, 0x00, 0xd1, 0x2c, 0xe7, 0x02, 0x2e, + 0xd9, 0xd0, 0x00, 0x23, 0x9e, 0xe7, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, + 0xfe, 0x7f, 0x00, 0x00, 0xee, 0xd8, 0xff, 0xff, 0xe4, 0xd8, 0xff, 0xff, + 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, + 0xe3, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0f, 0x26, 0xc3, 0x68, 0x87, 0xb0, + 0x5e, 0x43, 0x83, 0x6b, 0x04, 0x00, 0xf6, 0x1a, 0xc3, 0x6b, 0x1e, 0x3e, + 0xf5, 0x1a, 0x43, 0x6b, 0x0f, 0x00, 0x03, 0x2b, 0x04, 0xd9, 0xfb, 0x23, + 0x6b, 0x43, 0x00, 0x20, 0x8b, 0x42, 0x19, 0xdc, 0x38, 0x00, 0xfb, 0x21, + 0xfa, 0x30, 0x03, 0xf0, 0xb5, 0xfc, 0x02, 0x90, 0x86, 0x42, 0x44, 0xdb, + 0x05, 0x23, 0x01, 0x93, 0x6b, 0x1e, 0x2b, 0x43, 0xdb, 0x0f, 0x05, 0xaa, + 0x04, 0xa9, 0x20, 0x00, 0xff, 0xf7, 0xf2, 0xfc, 0x00, 0x28, 0x05, 0xdb, + 0x05, 0x98, 0x00, 0x28, 0x04, 0xd1, 0x02, 0x9b, 0xab, 0x42, 0x32, 0xda, + 0x07, 0xb0, 0xf0, 0xbd, 0x04, 0x9b, 0x01, 0x22, 0x1e, 0x88, 0x23, 0x00, + 0x40, 0x33, 0x1a, 0x70, 0x31, 0x00, 0x20, 0x00, 0x03, 0x93, 0xff, 0xf7, + 0xa1, 0xfd, 0x00, 0x23, 0x03, 0x9a, 0x13, 0x70, 0x98, 0x42, 0xed, 0xdb, + 0x31, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xaa, 0xfc, 0x00, 0x28, 0xe7, 0xdb, + 0x31, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x3e, 0xfc, 0x00, 0x28, 0xe1, 0xdb, + 0x0f, 0x22, 0xe3, 0x68, 0x53, 0x43, 0xa2, 0x6b, 0x9b, 0x1a, 0xe2, 0x6b, + 0x1e, 0x3b, 0x9b, 0x1a, 0x00, 0x2d, 0x01, 0xdc, 0x9d, 0x42, 0x04, 0xd0, + 0x01, 0x9a, 0x01, 0x3a, 0x01, 0x92, 0x00, 0x2a, 0x05, 0xd1, 0xfb, 0x22, + 0x53, 0x43, 0xbb, 0x42, 0xcc, 0xda, 0x05, 0x48, 0xca, 0xe7, 0x62, 0x6b, + 0x02, 0x2a, 0x03, 0xd9, 0xfb, 0x22, 0x5a, 0x43, 0xba, 0x42, 0xf2, 0xda, + 0x1d, 0x00, 0xb1, 0xe7, 0xef, 0xd8, 0xff, 0xff, 0xf7, 0xb5, 0x84, 0x68, + 0x07, 0x00, 0x01, 0x91, 0x15, 0x00, 0x1e, 0x00, 0x63, 0x1c, 0x17, 0xd0, + 0x33, 0x00, 0x94, 0x42, 0x10, 0xd9, 0xa4, 0x1a, 0xb4, 0x42, 0x00, 0xdd, + 0x34, 0x00, 0x23, 0x00, 0x01, 0x9a, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, + 0x47, 0xfd, 0x00, 0x28, 0x07, 0xdb, 0x01, 0x9a, 0x33, 0x1b, 0x12, 0x19, + 0x01, 0x92, 0x2d, 0x19, 0x00, 0x2b, 0x03, 0xdc, 0x30, 0x00, 0xfe, 0xbd, + 0x33, 0x00, 0xf9, 0xe7, 0x01, 0x9a, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, + 0x7d, 0xfa, 0x00, 0x28, 0xf4, 0xda, 0xf4, 0xe7, 0x73, 0xb5, 0x01, 0xaa, + 0x05, 0x00, 0x02, 0xf0, 0x59, 0xfc, 0x04, 0x1e, 0x02, 0xda, 0x28, 0x63, + 0x20, 0x00, 0x76, 0xbd, 0x01, 0x9e, 0xb3, 0x8b, 0x9b, 0x06, 0xf9, 0xd4, + 0x33, 0x6a, 0x00, 0x2b, 0x04, 0xd1, 0x31, 0x00, 0x28, 0x00, 0xfe, 0xf7, + 0x29, 0xfb, 0x30, 0x62, 0x01, 0x98, 0x02, 0x6a, 0x00, 0x2a, 0xed, 0xd0, + 0x8a, 0x21, 0x56, 0x78, 0x49, 0x00, 0x71, 0x43, 0x6c, 0x6c, 0x14, 0x31, + 0x24, 0x69, 0x13, 0x8a, 0x61, 0x18, 0xd2, 0x68, 0xff, 0xf7, 0xb0, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0x28, 0x63, 0x01, 0x9b, 0x28, 0x00, 0x19, 0x6a, + 0xfe, 0xf7, 0x34, 0xfb, 0xd8, 0xe7, 0x00, 0x00, 0xf7, 0xb5, 0x04, 0x00, + 0x1d, 0x00, 0x83, 0x6d, 0x17, 0x00, 0x01, 0x91, 0x60, 0x22, 0x00, 0x21, + 0x00, 0x93, 0x0a, 0x9e, 0x03, 0xf0, 0xb3, 0xfc, 0x0c, 0x22, 0x01, 0x99, + 0x20, 0x00, 0x03, 0xf0, 0xa5, 0xfc, 0x00, 0x9b, 0x08, 0x9a, 0xa3, 0x65, + 0x80, 0x23, 0x9b, 0x00, 0xe3, 0x60, 0x7b, 0x1c, 0xff, 0x33, 0x67, 0x62, + 0x23, 0x62, 0x00, 0x21, 0x28, 0x00, 0x03, 0xf0, 0xa0, 0xfc, 0x03, 0x22, + 0x2a, 0x40, 0x05, 0xd0, 0x04, 0x23, 0x9b, 0x1a, 0x08, 0x9a, 0xed, 0x18, + 0xd3, 0x1a, 0x08, 0x93, 0xa5, 0x62, 0x30, 0x21, 0x08, 0x98, 0x03, 0xf0, + 0xd9, 0xfb, 0x03, 0x22, 0x09, 0x9b, 0xe0, 0x62, 0x1a, 0x40, 0x05, 0xd0, + 0x04, 0x23, 0x9b, 0x1a, 0x09, 0x9a, 0xf6, 0x1a, 0xd2, 0x18, 0x09, 0x92, + 0x03, 0x23, 0x1e, 0x42, 0x00, 0xd0, 0x9e, 0x43, 0x80, 0x22, 0x09, 0x9b, + 0x92, 0x01, 0x63, 0x64, 0x33, 0x00, 0x96, 0x42, 0x00, 0xd9, 0x13, 0x00, + 0xa3, 0x64, 0x20, 0x00, 0xfe, 0xf7, 0x08, 0xfb, 0x07, 0x4b, 0x20, 0x00, + 0xe3, 0x65, 0x00, 0xf0, 0x83, 0xfd, 0x00, 0x28, 0x01, 0xda, 0x20, 0x63, + 0xfe, 0xbd, 0x0b, 0x9b, 0x00, 0x20, 0xe3, 0x64, 0x01, 0x23, 0x54, 0x34, + 0x23, 0x70, 0xf7, 0xe7, 0x15, 0x03, 0x09, 0x20, 0xf8, 0xb5, 0xc2, 0x6d, + 0x10, 0x4b, 0x04, 0x00, 0x9a, 0x42, 0x0c, 0xd1, 0x07, 0x00, 0x54, 0x37, + 0x3b, 0x78, 0x00, 0x2b, 0x07, 0xd0, 0x00, 0x26, 0x83, 0x6a, 0x1d, 0x1d, + 0xe3, 0x6a, 0xb3, 0x42, 0x02, 0xd8, 0x00, 0x23, 0x3b, 0x70, 0xf8, 0xbd, + 0x00, 0x23, 0xe9, 0x5e, 0x00, 0x29, 0x07, 0xd0, 0x20, 0x00, 0xff, 0xf7, + 0x5b, 0xff, 0x00, 0x23, 0xe9, 0x5e, 0x20, 0x00, 0x02, 0xf0, 0x98, 0xfb, + 0x01, 0x36, 0x30, 0x35, 0xea, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, + 0x00, 0x6b, 0x70, 0x47, 0x00, 0x23, 0x03, 0x63, 0x70, 0x47, 0x00, 0x00, + 0xf0, 0xb5, 0x87, 0xb0, 0x17, 0x00, 0x03, 0x93, 0xc2, 0x6d, 0x3f, 0x4b, + 0x05, 0x00, 0x0e, 0x00, 0x9a, 0x42, 0x04, 0xd0, 0x3d, 0x4c, 0x2c, 0x63, + 0x20, 0x00, 0x07, 0xb0, 0xf0, 0xbd, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, + 0x00, 0x2b, 0x01, 0xd1, 0x39, 0x4c, 0xf4, 0xe7, 0x08, 0x00, 0x03, 0xf0, + 0x32, 0xfc, 0x1f, 0x28, 0x01, 0xd9, 0x37, 0x4c, 0xed, 0xe7, 0x32, 0x00, + 0x05, 0xa9, 0x28, 0x00, 0x02, 0xf0, 0xf8, 0xfa, 0x00, 0x28, 0x02, 0xda, + 0x28, 0x63, 0x04, 0xb2, 0xe4, 0xe7, 0x04, 0xaa, 0x31, 0x00, 0x28, 0x00, + 0x01, 0xf0, 0xb2, 0xfe, 0x04, 0x00, 0x7b, 0x07, 0x34, 0xd4, 0x00, 0x28, + 0x24, 0xda, 0x05, 0x9b, 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, + 0x55, 0xfb, 0x2c, 0x63, 0x24, 0xb2, 0xd1, 0xe7, 0x00, 0x2c, 0xf4, 0xdb, + 0x02, 0xab, 0x19, 0x89, 0x03, 0x9b, 0x05, 0x9a, 0x00, 0x93, 0x28, 0x00, + 0x3b, 0x00, 0x01, 0xf0, 0x27, 0xf9, 0x04, 0x1e, 0xe9, 0xdb, 0xbb, 0x07, + 0x06, 0xd5, 0x00, 0x22, 0x05, 0x98, 0x11, 0x00, 0x01, 0xf0, 0xbe, 0xfe, + 0x04, 0x1e, 0xe0, 0xdb, 0x00, 0x22, 0x05, 0x9b, 0x9a, 0x61, 0x04, 0x24, + 0x1c, 0x5f, 0xb5, 0xe7, 0x00, 0x28, 0xe3, 0xd1, 0x44, 0x23, 0x3b, 0x40, + 0x44, 0x2b, 0xdf, 0xd1, 0x05, 0x9b, 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, + 0x02, 0xf0, 0x2a, 0xfb, 0x14, 0x4c, 0xa6, 0xe7, 0x00, 0x28, 0xf1, 0xd0, + 0x13, 0x4b, 0x9c, 0x42, 0xd0, 0xd1, 0x0a, 0x23, 0x02, 0xa9, 0x5b, 0x18, + 0x00, 0x22, 0x19, 0x00, 0x28, 0x00, 0x02, 0xf0, 0xfb, 0xf9, 0x04, 0x1e, + 0xbd, 0xdb, 0x02, 0xab, 0x59, 0x89, 0x04, 0xab, 0x01, 0x93, 0x01, 0x23, + 0x32, 0x00, 0x00, 0x93, 0x28, 0x00, 0x00, 0x23, 0x00, 0xf0, 0xf2, 0xff, + 0x04, 0x1e, 0xb0, 0xdb, 0x02, 0x23, 0x9f, 0x43, 0xb8, 0xe7, 0xc0, 0x46, + 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, 0xf0, 0xd8, 0xff, 0xff, + 0xcc, 0xd8, 0xff, 0xff, 0xd2, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xf7, 0xb5, 0x16, 0x00, 0x1c, 0x00, 0xc2, 0x6d, 0x29, 0x4b, 0x05, 0x00, + 0x0f, 0x00, 0x9a, 0x42, 0x03, 0xd0, 0x28, 0x4c, 0x2c, 0x63, 0x20, 0x00, + 0xfe, 0xbd, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, + 0x24, 0x4c, 0xf5, 0xe7, 0x01, 0xaa, 0x02, 0xf0, 0x01, 0xfb, 0x00, 0x28, + 0x05, 0xda, 0x04, 0x00, 0x28, 0x63, 0x21, 0x4b, 0x9c, 0x42, 0x0d, 0xd0, + 0xeb, 0xe7, 0x01, 0x9b, 0x9a, 0x8b, 0x12, 0x07, 0x01, 0xd4, 0x1e, 0x4c, + 0xe4, 0xe7, 0x9b, 0x68, 0x01, 0x33, 0x05, 0xd1, 0x00, 0x2c, 0x03, 0xdd, + 0x19, 0x4b, 0x2b, 0x63, 0x00, 0x24, 0xdc, 0xe7, 0x39, 0x00, 0x28, 0x00, + 0xff, 0xf7, 0x88, 0xfe, 0x01, 0x98, 0x81, 0x69, 0x83, 0x68, 0x0a, 0x19, + 0x9a, 0x42, 0x14, 0xd3, 0x5c, 0x1a, 0x00, 0x2c, 0xee, 0xdd, 0x33, 0x00, + 0x22, 0x00, 0x02, 0xf0, 0xa5, 0xf8, 0x0f, 0x4b, 0x98, 0x42, 0x06, 0xd1, + 0x20, 0x00, 0x01, 0x9a, 0x93, 0x69, 0x1b, 0x19, 0x93, 0x61, 0x04, 0x00, + 0xc1, 0xe7, 0x00, 0x28, 0x07, 0xda, 0x28, 0x63, 0xf9, 0xe7, 0x33, 0x00, + 0x22, 0x00, 0x02, 0xf0, 0x93, 0xf8, 0x00, 0x28, 0xc5, 0xdb, 0x01, 0x9a, + 0x93, 0x69, 0x1b, 0x19, 0x93, 0x61, 0xc2, 0xe7, 0x15, 0x03, 0x09, 0x20, + 0xd8, 0xd8, 0xff, 0xff, 0xf0, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xda, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x15, 0x00, 0x1e, 0x00, 0xc2, 0x6d, + 0x2d, 0x4b, 0x85, 0xb0, 0x04, 0x00, 0x0f, 0x00, 0x9a, 0x42, 0x03, 0xd0, + 0x2b, 0x48, 0x20, 0x63, 0x05, 0xb0, 0xf0, 0xbd, 0x03, 0x00, 0x54, 0x33, + 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x28, 0x48, 0xf5, 0xe7, 0x03, 0xaa, + 0x02, 0xf0, 0x9e, 0xfa, 0x00, 0x28, 0xf0, 0xdb, 0x39, 0x00, 0x20, 0x00, + 0xff, 0xf7, 0x3a, 0xfe, 0x03, 0x9f, 0xbb, 0x68, 0x5a, 0x1c, 0x00, 0xd1, + 0x00, 0x23, 0x01, 0x2e, 0x05, 0xd0, 0x02, 0x2e, 0x06, 0xd0, 0x00, 0x2d, + 0x06, 0xda, 0x1e, 0x48, 0xdf, 0xe7, 0xba, 0x69, 0xad, 0x18, 0xf8, 0xe7, + 0xed, 0x18, 0xf6, 0xe7, 0x9d, 0x42, 0x02, 0xdd, 0xbb, 0x61, 0x1a, 0x48, + 0xd5, 0xe7, 0x00, 0x26, 0xb5, 0x42, 0x0d, 0xdd, 0x68, 0x1e, 0xfb, 0x21, + 0x03, 0xf0, 0x52, 0xfa, 0x83, 0xb2, 0x68, 0x2b, 0x06, 0xd9, 0x18, 0x00, + 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0x4a, 0xfa, 0x01, 0x30, 0x86, 0xb2, + 0x3b, 0x8a, 0xb3, 0x42, 0x11, 0xd0, 0xf9, 0x88, 0x80, 0x23, 0x0a, 0x27, + 0x1b, 0x02, 0x6f, 0x44, 0x19, 0x43, 0x00, 0x97, 0x00, 0x23, 0x32, 0x00, + 0x20, 0x00, 0x00, 0xf0, 0xdd, 0xfc, 0x00, 0x28, 0xb3, 0xdb, 0x03, 0x9b, + 0x3a, 0x88, 0x1e, 0x82, 0xda, 0x81, 0x03, 0x9b, 0x28, 0x00, 0x9d, 0x61, + 0xac, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xc8, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x2a, 0x4b, 0xc2, 0x6d, 0x85, 0xb0, 0x05, 0x00, 0x0f, 0x00, + 0x9a, 0x42, 0x02, 0xd0, 0x27, 0x4c, 0x2c, 0x63, 0x3e, 0xe0, 0x03, 0x00, + 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x24, 0x4c, 0xf6, 0xe7, + 0x08, 0x00, 0x03, 0xf0, 0xda, 0xfa, 0x1f, 0x28, 0x01, 0xd9, 0x22, 0x4c, + 0xef, 0xe7, 0x00, 0x22, 0x03, 0xa9, 0x28, 0x00, 0x02, 0xf0, 0xa0, 0xf9, + 0x04, 0x1e, 0xe8, 0xdb, 0x0a, 0x26, 0x6e, 0x44, 0x32, 0x00, 0x39, 0x00, + 0x28, 0x00, 0x01, 0xf0, 0x5b, 0xfd, 0x04, 0x1e, 0x07, 0xd0, 0x03, 0x9b, + 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0x01, 0xfa, 0x00, 0x2c, + 0xd7, 0xdb, 0x00, 0x23, 0x31, 0x88, 0x03, 0x9a, 0x00, 0x93, 0x28, 0x00, + 0x00, 0xf0, 0xd8, 0xff, 0x04, 0x1e, 0x07, 0xd0, 0x03, 0x9b, 0x28, 0x00, + 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0xf0, 0xf9, 0x00, 0x2c, 0xc6, 0xdb, + 0x01, 0x22, 0x00, 0x21, 0x03, 0x98, 0x01, 0xf0, 0x69, 0xfd, 0x04, 0x1e, + 0x03, 0xd1, 0x00, 0x24, 0x20, 0x00, 0x05, 0xb0, 0xf0, 0xbd, 0x03, 0x9b, + 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0xdd, 0xf9, 0x00, 0x2c, + 0xb3, 0xdb, 0xf2, 0xe7, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xcc, 0xd8, 0xff, 0xff, 0x0d, 0x4b, 0xc2, 0x6d, + 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x9a, 0x42, 0x02, 0xd0, 0x0b, 0x48, + 0x20, 0x63, 0x10, 0xe0, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, + 0x01, 0xd1, 0x08, 0x48, 0xf6, 0xe7, 0xff, 0xf7, 0x7d, 0xfd, 0x00, 0x28, + 0xf2, 0xdb, 0x29, 0x00, 0x20, 0x00, 0x02, 0xf0, 0xb9, 0xf9, 0x00, 0x28, + 0xec, 0xdb, 0x70, 0xbd, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0x0e, 0x4b, 0xc2, 0x6d, 0x10, 0xb5, 0x04, 0x00, + 0x9a, 0x42, 0x02, 0xd0, 0x0c, 0x48, 0x20, 0x63, 0x10, 0xbd, 0x03, 0x00, + 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x09, 0x48, 0xf6, 0xe7, + 0x00, 0x21, 0xfe, 0xf7, 0xe5, 0xfd, 0x20, 0x00, 0xff, 0xf7, 0x06, 0xf9, + 0x20, 0x00, 0xfe, 0xf7, 0x19, 0xfe, 0x20, 0x00, 0x00, 0xf0, 0x52, 0xfb, + 0xea, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x12, 0x01, 0x5c, 0x1c, 0x14, 0x19, + 0x05, 0x22, 0x85, 0xb0, 0xa4, 0xb2, 0x02, 0xad, 0x0f, 0x00, 0x00, 0x92, + 0x23, 0x02, 0x01, 0x95, 0x10, 0x32, 0x00, 0x21, 0x0a, 0x9e, 0xfd, 0xf7, + 0xde, 0xff, 0x00, 0x28, 0x1d, 0xdb, 0x2b, 0x88, 0xbb, 0x42, 0x1c, 0xd1, + 0x0b, 0x9a, 0x69, 0x88, 0x12, 0x88, 0x8a, 0x42, 0x17, 0xd1, 0x29, 0x79, + 0x7c, 0x20, 0x0d, 0x00, 0x85, 0x43, 0x80, 0x2d, 0x11, 0xd1, 0x1b, 0xb2, + 0x00, 0x2b, 0x03, 0xda, 0x4b, 0x06, 0x01, 0xd4, 0x00, 0x2a, 0x0a, 0xd0, + 0x30, 0x1e, 0x06, 0xd0, 0x30, 0x88, 0x00, 0x1b, 0x44, 0x42, 0x60, 0x41, + 0x03, 0x4c, 0x40, 0x42, 0x20, 0x40, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x48, + 0xfb, 0xe7, 0xc0, 0x46, 0xaa, 0xd8, 0xff, 0xff, 0x7f, 0xb5, 0x1d, 0x00, + 0x1b, 0x4b, 0x0c, 0x00, 0x9a, 0x42, 0x24, 0xd0, 0x13, 0x07, 0x25, 0xd0, + 0x80, 0x23, 0x9b, 0x01, 0x9a, 0x42, 0x23, 0xd8, 0x13, 0x02, 0x04, 0x21, + 0x62, 0x5e, 0x05, 0x21, 0x02, 0xae, 0x00, 0x91, 0x01, 0x96, 0x11, 0x31, + 0xfd, 0xf7, 0xa1, 0xff, 0x00, 0x28, 0x13, 0xdb, 0x33, 0x79, 0xda, 0x07, + 0x16, 0xd4, 0x5a, 0xb2, 0x00, 0x2a, 0x15, 0xda, 0x9a, 0x07, 0x15, 0xd4, + 0x5b, 0x07, 0x15, 0xd4, 0x06, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x11, 0xda, + 0x73, 0x88, 0xab, 0x42, 0x02, 0xd0, 0x09, 0x48, 0x00, 0xe0, 0x09, 0x48, + 0x04, 0xb0, 0x70, 0xbd, 0x08, 0x48, 0xfb, 0xe7, 0x08, 0x48, 0xf9, 0xe7, + 0x08, 0x48, 0xf7, 0xe7, 0x08, 0x48, 0xf5, 0xe7, 0x08, 0x48, 0xf3, 0xe7, + 0x08, 0x48, 0xf1, 0xe7, 0xff, 0xff, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, + 0xde, 0xd8, 0xff, 0xff, 0xdd, 0xd8, 0xff, 0xff, 0xdc, 0xd8, 0xff, 0xff, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0x12, 0x01, 0x30, 0xb5, 0x01, 0x33, 0xd3, 0x18, + 0x13, 0x4a, 0x8f, 0xb0, 0x89, 0x18, 0x13, 0x4a, 0x89, 0xb2, 0x9b, 0xb2, + 0x91, 0x42, 0x1b, 0xd8, 0x2e, 0x22, 0x02, 0xac, 0x00, 0x92, 0x1b, 0x02, + 0x01, 0x94, 0x00, 0x22, 0x15, 0x21, 0xfd, 0xf7, 0x56, 0xff, 0x00, 0x28, + 0x11, 0xdb, 0x65, 0x88, 0x00, 0x2d, 0x0d, 0xd1, 0x3d, 0x22, 0x23, 0x79, + 0x93, 0x43, 0xc0, 0x2b, 0x08, 0xd1, 0x15, 0x21, 0x12, 0x98, 0x69, 0x44, + 0x03, 0xf0, 0x99, 0xf9, 0x03, 0x00, 0x28, 0x00, 0x00, 0x2b, 0x00, 0xd0, + 0x03, 0x48, 0x0f, 0xb0, 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, + 0xfe, 0x7f, 0x00, 0x00, 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x05, 0x00, + 0x0c, 0x00, 0x21, 0x48, 0x01, 0x39, 0x89, 0xb2, 0x8f, 0xb0, 0x81, 0x42, + 0x01, 0xd9, 0x1f, 0x48, 0x27, 0xe0, 0x15, 0x99, 0x0e, 0x88, 0x14, 0x99, + 0x00, 0x29, 0x24, 0xd0, 0x21, 0xb2, 0x00, 0x29, 0x21, 0xda, 0x12, 0x01, + 0x01, 0x33, 0xd3, 0x18, 0x2e, 0x22, 0x9b, 0xb2, 0x02, 0xaf, 0x00, 0x92, + 0x1b, 0x02, 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xfd, 0xf7, + 0x18, 0xff, 0x00, 0x28, 0x0f, 0xdb, 0x7b, 0x88, 0x00, 0x2b, 0x0e, 0xd1, + 0x3d, 0x22, 0x3b, 0x79, 0x93, 0x43, 0xc0, 0x2b, 0x09, 0xd1, 0x15, 0x21, + 0x14, 0x98, 0x69, 0x44, 0x03, 0xf0, 0x5b, 0xf9, 0x00, 0x28, 0x02, 0xd1, + 0x0b, 0x48, 0x0f, 0xb0, 0xf0, 0xbd, 0x64, 0x04, 0x64, 0x0c, 0xa4, 0x1b, + 0xe3, 0x10, 0xff, 0x2b, 0xcd, 0xd8, 0x6a, 0x6a, 0xd2, 0x18, 0x07, 0x23, + 0x1c, 0x40, 0x06, 0x3b, 0xa3, 0x40, 0x11, 0x78, 0x0b, 0x43, 0x13, 0x70, + 0xc3, 0xe7, 0xc0, 0x46, 0xfd, 0xff, 0x00, 0x00, 0xaa, 0xd8, 0xff, 0xff, + 0xd9, 0xd8, 0xff, 0xff, 0x09, 0x4a, 0x91, 0x42, 0x06, 0xd1, 0x00, 0x2b, + 0x02, 0xd1, 0x43, 0x6b, 0x01, 0x33, 0x43, 0x63, 0x06, 0x48, 0x70, 0x47, + 0x00, 0x29, 0x03, 0xd1, 0xc3, 0x6b, 0x01, 0x33, 0xc3, 0x63, 0xf7, 0xe7, + 0x83, 0x6b, 0x01, 0x33, 0x83, 0x63, 0xf3, 0xe7, 0xff, 0xff, 0x00, 0x00, + 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x85, 0xb0, 0x01, 0x91, 0x02, 0x92, + 0x07, 0x89, 0x06, 0x00, 0x00, 0x25, 0x68, 0x2f, 0x06, 0xd9, 0x38, 0x00, + 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0x58, 0xf8, 0x01, 0x30, 0x85, 0xb2, + 0x74, 0x89, 0x00, 0x20, 0x68, 0x2c, 0x06, 0xd9, 0x20, 0x00, 0x7c, 0x21, + 0x69, 0x38, 0x03, 0xf0, 0x4d, 0xf8, 0x01, 0x30, 0x80, 0xb2, 0x01, 0x9b, + 0x9d, 0x42, 0x1c, 0xd8, 0x83, 0x42, 0x1a, 0xd8, 0x00, 0x2b, 0x1a, 0xd0, + 0x7c, 0x23, 0x01, 0x9a, 0x5a, 0x43, 0x13, 0x3a, 0x92, 0xb2, 0x9b, 0x18, + 0x01, 0x34, 0x9b, 0xb2, 0xa3, 0x42, 0x00, 0xdd, 0x23, 0x00, 0x9b, 0xb2, + 0x03, 0x93, 0x3c, 0x1c, 0x97, 0x42, 0x00, 0xd2, 0x14, 0x1c, 0xa4, 0xb2, + 0x25, 0x1d, 0x14, 0x4f, 0x6d, 0x00, 0x03, 0x9a, 0xa3, 0xb2, 0x9a, 0x42, + 0x04, 0xd8, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x9a, 0x69, 0x23, 0xe6, 0xe7, + 0x01, 0x9a, 0x00, 0x2a, 0x0c, 0xd1, 0x02, 0x9b, 0x5b, 0x19, 0xda, 0x8c, + 0x02, 0x35, 0xba, 0x42, 0xf1, 0xd0, 0x33, 0x89, 0x31, 0x68, 0xe3, 0x1a, + 0x5b, 0x00, 0x5a, 0x52, 0x01, 0x34, 0xe6, 0xe7, 0x29, 0x00, 0x68, 0x2b, + 0x06, 0xd9, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0x94, 0xf8, + 0x04, 0x31, 0x49, 0x00, 0x02, 0x9b, 0x5a, 0x5a, 0xe8, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0x01, 0x00, 0x10, 0xb5, 0x21, 0x24, 0x03, 0x00, + 0x05, 0x48, 0x20, 0x31, 0x1a, 0x78, 0x00, 0x2a, 0x02, 0xd0, 0x01, 0x33, + 0x8b, 0x42, 0x00, 0xd1, 0x10, 0xbd, 0x60, 0x43, 0x50, 0x40, 0xf5, 0xe7, + 0x05, 0x15, 0x00, 0x00, 0x30, 0xb5, 0x1c, 0x00, 0x19, 0x4b, 0x85, 0xb0, + 0x9a, 0x42, 0x20, 0xd0, 0x13, 0x07, 0x21, 0xd0, 0x80, 0x23, 0x9b, 0x01, + 0x9a, 0x42, 0x1f, 0xd8, 0x13, 0x02, 0x00, 0x22, 0x8a, 0x5e, 0x05, 0x21, + 0x02, 0xad, 0x00, 0x91, 0x01, 0x95, 0x12, 0x31, 0xfd, 0xf7, 0x4d, 0xfe, + 0x00, 0x28, 0x0f, 0xdb, 0x2b, 0x79, 0xda, 0x07, 0x12, 0xd4, 0x5a, 0xb2, + 0x00, 0x2a, 0x11, 0xda, 0x9a, 0x07, 0x11, 0xd4, 0x5b, 0x07, 0x11, 0xd5, + 0x6b, 0x88, 0xa3, 0x42, 0x02, 0xd0, 0x09, 0x48, 0x00, 0xe0, 0x09, 0x48, + 0x05, 0xb0, 0x30, 0xbd, 0x08, 0x48, 0xfb, 0xe7, 0x08, 0x48, 0xf9, 0xe7, + 0x08, 0x48, 0xf7, 0xe7, 0x08, 0x48, 0xf5, 0xe7, 0x08, 0x48, 0xf3, 0xe7, + 0x08, 0x48, 0xf1, 0xe7, 0xff, 0xff, 0x00, 0x00, 0xe2, 0xd8, 0xff, 0xff, + 0xe1, 0xd8, 0xff, 0xff, 0xe0, 0xd8, 0xff, 0xff, 0xdf, 0xd8, 0xff, 0xff, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xe5, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0c, 0x00, 0x1f, 0x49, 0x06, 0x00, + 0x61, 0x18, 0x1f, 0x48, 0x8f, 0xb0, 0x89, 0xb2, 0x14, 0x9d, 0x81, 0x42, + 0x33, 0xd8, 0x01, 0x33, 0x12, 0x03, 0x1b, 0x02, 0x9b, 0x18, 0x2e, 0x22, + 0x02, 0xaf, 0x00, 0x92, 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x30, 0x00, + 0xfd, 0xf7, 0x03, 0xfe, 0x00, 0x28, 0x24, 0xd1, 0x7b, 0x88, 0x00, 0x2b, + 0x21, 0xd1, 0x79, 0x22, 0x3b, 0x79, 0x93, 0x43, 0x80, 0x2b, 0x1c, 0xd1, + 0xa8, 0x68, 0x00, 0x28, 0x08, 0xd0, 0x15, 0x21, 0x69, 0x44, 0x03, 0xf0, + 0x44, 0xf8, 0x00, 0x28, 0x02, 0xd1, 0x0d, 0x48, 0x0f, 0xb0, 0xf0, 0xbd, + 0x28, 0x88, 0x61, 0x04, 0x49, 0x0c, 0x81, 0x42, 0x0b, 0xd3, 0x6b, 0x88, + 0x8b, 0x42, 0x08, 0xd3, 0x08, 0x1a, 0x69, 0x68, 0x02, 0xf0, 0x72, 0xff, + 0x73, 0x6a, 0x18, 0x18, 0x03, 0x78, 0x01, 0x33, 0x03, 0x70, 0x04, 0x48, + 0xea, 0xe7, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, 0xfe, 0x7f, 0x00, 0x00, + 0xd9, 0xd8, 0xff, 0xff, 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x15, 0x00, + 0x1e, 0x00, 0x95, 0xb0, 0x1a, 0x9f, 0x02, 0x90, 0x03, 0x91, 0x00, 0x2f, + 0x02, 0xd1, 0x38, 0x00, 0x15, 0xb0, 0xf0, 0xbd, 0x3c, 0x00, 0x40, 0x2f, + 0x00, 0xd9, 0x40, 0x24, 0x04, 0xab, 0x01, 0x93, 0x00, 0x94, 0x33, 0x00, + 0x03, 0x9a, 0x0b, 0x21, 0x02, 0x98, 0xfd, 0xf7, 0xb8, 0xfd, 0x00, 0x28, + 0xee, 0xdb, 0x04, 0xab, 0x01, 0x93, 0x00, 0x94, 0x2b, 0x00, 0x03, 0x9a, + 0x0f, 0x21, 0x02, 0x98, 0xfd, 0xf7, 0x11, 0xfe, 0x00, 0x28, 0xe3, 0xdb, + 0x3f, 0x1b, 0x36, 0x19, 0x2d, 0x19, 0xdc, 0xe7, 0xf0, 0xb5, 0x14, 0x00, + 0x0f, 0x22, 0x8d, 0xb0, 0x06, 0x93, 0x12, 0xab, 0x1b, 0x88, 0x06, 0x00, + 0x0b, 0x93, 0xc3, 0x68, 0x0f, 0x00, 0x5a, 0x43, 0x07, 0x92, 0x02, 0x6a, + 0x09, 0x92, 0x0e, 0x2c, 0x00, 0xdc, 0xa4, 0xe0, 0x01, 0x37, 0xbf, 0xb2, + 0xbb, 0x42, 0x51, 0xd9, 0x00, 0x24, 0x3b, 0x03, 0x03, 0x93, 0x07, 0x9b, + 0x00, 0x2b, 0x4f, 0xdd, 0x7f, 0x22, 0xe3, 0x17, 0x13, 0x40, 0x1b, 0x19, + 0xdb, 0x11, 0xda, 0x01, 0x05, 0x92, 0x09, 0x9a, 0x1b, 0x02, 0xd3, 0x1a, + 0x04, 0x93, 0x03, 0x9a, 0x09, 0x9b, 0x14, 0x21, 0x9b, 0x18, 0x04, 0x9a, + 0x30, 0x00, 0x9b, 0x1a, 0x0a, 0x93, 0x33, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x0a, 0x9b, 0xfd, 0xf7, 0x6f, 0xfd, + 0x25, 0x00, 0x07, 0x9b, 0x02, 0x90, 0x08, 0x93, 0x08, 0x9b, 0x2c, 0x00, + 0x07, 0x93, 0x02, 0x9b, 0x00, 0x2b, 0x05, 0xd1, 0x05, 0x9b, 0xeb, 0x1a, + 0x7f, 0x2b, 0x01, 0xdc, 0x0e, 0x2d, 0x28, 0xdd, 0x05, 0x9b, 0x80, 0x33, + 0x05, 0x93, 0x04, 0x9b, 0x01, 0x3b, 0xff, 0x3b, 0x04, 0x93, 0x02, 0x9b, + 0x00, 0x2b, 0x02, 0xd1, 0x05, 0x9b, 0x80, 0x2b, 0xd1, 0xd1, 0x01, 0x37, + 0xf3, 0x68, 0xbf, 0xb2, 0x9f, 0x42, 0x55, 0xd2, 0x80, 0x22, 0x52, 0x01, + 0x94, 0x46, 0x03, 0x9b, 0x63, 0x44, 0x03, 0x93, 0x00, 0x24, 0x02, 0x9b, + 0xa3, 0x42, 0xb4, 0xd0, 0x02, 0x9b, 0x00, 0x2b, 0x06, 0xdb, 0x03, 0xe0, + 0x04, 0x24, 0x06, 0x9b, 0x1c, 0x40, 0x4d, 0xd0, 0x29, 0x4b, 0x02, 0x93, + 0x02, 0x98, 0x0d, 0xb0, 0xf0, 0xbd, 0x01, 0x22, 0x06, 0x9b, 0x13, 0x42, + 0x05, 0xd0, 0x04, 0x9a, 0x6b, 0x00, 0xd3, 0x5a, 0x0b, 0x9a, 0x93, 0x42, + 0x2f, 0xd1, 0x16, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x1f, 0x80, 0x17, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x1d, 0x60, 0x13, 0x9b, 0x00, 0x2b, 0xe7, 0xd0, + 0x02, 0x22, 0x06, 0x9b, 0x0b, 0x99, 0x13, 0x42, 0x02, 0xd1, 0x04, 0x9a, + 0x6b, 0x00, 0xd1, 0x5a, 0x15, 0x9b, 0x3a, 0x00, 0x01, 0x93, 0x14, 0x9b, + 0x30, 0x00, 0x00, 0x93, 0x13, 0x9c, 0x2b, 0x00, 0xa0, 0x47, 0x15, 0x4b, + 0xc3, 0x18, 0x01, 0x2b, 0x21, 0xd8, 0x14, 0x4b, 0x98, 0x42, 0x0c, 0xd1, + 0x33, 0x6a, 0x00, 0x22, 0x01, 0x93, 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, + 0x14, 0x21, 0x0a, 0x9b, 0x30, 0x00, 0xfd, 0xf7, 0xfe, 0xfc, 0x00, 0x28, + 0x11, 0xdb, 0x08, 0x9b, 0x01, 0x35, 0x01, 0x3b, 0x08, 0x93, 0x8b, 0xe7, + 0x04, 0x23, 0x06, 0x9a, 0x13, 0x40, 0xb7, 0xd1, 0x03, 0x93, 0x1f, 0x00, + 0xa8, 0xe7, 0x0b, 0x03, 0x03, 0x93, 0x5e, 0xe7, 0x03, 0x94, 0x27, 0x00, + 0x5b, 0xe7, 0x02, 0x90, 0xae, 0xe7, 0xc0, 0x46, 0xa8, 0xd8, 0xff, 0xff, + 0x57, 0x27, 0x00, 0x00, 0xa9, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x04, 0x00, + 0x0d, 0x03, 0x0f, 0x00, 0x80, 0x21, 0x85, 0xb0, 0x49, 0x01, 0xa3, 0x68, + 0x28, 0x00, 0x98, 0x47, 0x63, 0x6b, 0x22, 0x00, 0x01, 0x33, 0x63, 0x63, + 0x02, 0x26, 0x2b, 0x00, 0x42, 0x32, 0x01, 0x92, 0xfe, 0x33, 0x00, 0x96, + 0x00, 0x22, 0x19, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x2c, 0xfd, 0x00, 0x28, + 0x1a, 0xdb, 0xe3, 0x68, 0x0e, 0x22, 0xdb, 0x1b, 0x0d, 0x4f, 0x6a, 0x44, + 0x5f, 0x40, 0x2b, 0x00, 0x17, 0x80, 0xfc, 0x33, 0x01, 0x92, 0x00, 0x96, + 0x00, 0x22, 0x19, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x1a, 0xfd, 0x00, 0x28, + 0x08, 0xdb, 0x80, 0x22, 0x04, 0x34, 0xe3, 0x8f, 0x12, 0x02, 0x01, 0x33, + 0x9b, 0xb2, 0x93, 0x42, 0x02, 0xd0, 0xe3, 0x87, 0x05, 0xb0, 0xf0, 0xbd, + 0x00, 0x23, 0xfa, 0xe7, 0x29, 0x04, 0x00, 0x00, 0xf0, 0xb5, 0x00, 0x27, + 0x04, 0x00, 0x8b, 0xb0, 0x3b, 0x4d, 0x08, 0xab, 0x1f, 0x80, 0x07, 0x95, + 0x08, 0xae, 0x33, 0x88, 0xe2, 0x68, 0x93, 0x42, 0x24, 0xd3, 0x38, 0x4a, + 0x7b, 0x1b, 0x01, 0x35, 0x93, 0x42, 0x00, 0xdc, 0x7d, 0x1c, 0x23, 0x1d, + 0xad, 0xb2, 0xdd, 0x87, 0x07, 0x9b, 0x1a, 0x00, 0x31, 0x4b, 0x9a, 0x42, + 0x58, 0xd1, 0x00, 0x25, 0x09, 0xab, 0x05, 0x93, 0x30, 0x4b, 0x65, 0x63, + 0x01, 0x93, 0xa5, 0x63, 0x2b, 0x00, 0xe5, 0x63, 0x04, 0x96, 0x03, 0x95, + 0x02, 0x95, 0x00, 0x95, 0x2a, 0x00, 0x29, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0xd1, 0xfe, 0x2a, 0x4b, 0x98, 0x42, 0x41, 0xd1, 0x28, 0x00, 0x3f, 0xe0, + 0x1a, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, 0x1b, 0x03, + 0x00, 0x92, 0xfc, 0x33, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, 0xfd, 0xf7, + 0x66, 0xfc, 0x00, 0x28, 0x30, 0xdb, 0xe2, 0x68, 0x33, 0x88, 0xd1, 0x1a, + 0x1f, 0x4a, 0x4a, 0x40, 0x02, 0xa9, 0x49, 0x8b, 0x92, 0xb2, 0x91, 0x42, + 0x05, 0xd0, 0x07, 0x9a, 0x11, 0x00, 0x17, 0x4a, 0x91, 0x42, 0x20, 0xd1, + 0x07, 0x93, 0x02, 0x22, 0x1b, 0x03, 0x09, 0xae, 0x00, 0x92, 0xfe, 0x33, + 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x49, 0xfc, + 0x00, 0x28, 0x13, 0xdb, 0x33, 0x88, 0x0e, 0x4a, 0x93, 0x42, 0x09, 0xd0, + 0x1a, 0x1c, 0xab, 0x42, 0x00, 0xd9, 0x2a, 0x1c, 0x95, 0xb2, 0x1a, 0x1c, + 0xbb, 0x42, 0x00, 0xd2, 0x3a, 0x1c, 0x97, 0xb2, 0x08, 0xaa, 0x13, 0x88, + 0x01, 0x33, 0x13, 0x80, 0x96, 0xe7, 0x0a, 0x48, 0x0b, 0xb0, 0xf0, 0xbd, + 0x07, 0x99, 0x20, 0x00, 0xff, 0xf7, 0x4c, 0xff, 0x00, 0x28, 0xa0, 0xda, + 0xf6, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0xff, 0x7f, 0x00, 0x00, + 0xc9, 0x49, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, 0x29, 0x04, 0x00, 0x00, + 0xd7, 0xd8, 0xff, 0xff, 0x10, 0xb5, 0x86, 0xb0, 0x09, 0x9c, 0x00, 0x93, + 0x05, 0x94, 0x08, 0x9c, 0x01, 0x23, 0x04, 0x94, 0x00, 0x24, 0x03, 0x94, + 0x02, 0x94, 0x01, 0x94, 0xff, 0xf7, 0x68, 0xfe, 0x02, 0x4b, 0x98, 0x42, + 0x00, 0xd1, 0x02, 0x48, 0x06, 0xb0, 0x10, 0xbd, 0xa8, 0xd8, 0xff, 0xff, + 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x1e, 0x00, 0x03, 0x00, 0x85, 0xb0, + 0x03, 0x92, 0x40, 0x33, 0x0f, 0x00, 0x19, 0x78, 0x04, 0x00, 0x0a, 0x9d, + 0x00, 0x29, 0x0b, 0xd0, 0x01, 0x95, 0x00, 0x96, 0x12, 0x4b, 0x03, 0x9a, + 0x39, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xd4, 0xff, 0x00, 0x28, 0x10, 0xd0, + 0x05, 0xb0, 0xf0, 0xbd, 0x43, 0x6b, 0x01, 0x2b, 0xf0, 0xd8, 0xfe, 0xf7, + 0x49, 0xfd, 0x0c, 0x4b, 0x98, 0x42, 0x01, 0xd0, 0x00, 0x28, 0xf3, 0xdb, + 0x63, 0x6b, 0x01, 0x2b, 0xe6, 0xd8, 0x09, 0x48, 0xee, 0xe7, 0x33, 0x88, + 0x23, 0x82, 0x2b, 0x68, 0x01, 0x33, 0x63, 0x61, 0x2b, 0x68, 0x00, 0x2b, + 0xe6, 0xd1, 0x63, 0x6b, 0x01, 0x3b, 0x63, 0x63, 0xe2, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xd3, 0xd8, 0xff, 0xff, 0xef, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x1e, 0x27, 0x8b, 0xb0, 0x6f, 0x44, 0x07, 0xae, 0x3a, 0x80, + 0x33, 0x80, 0x04, 0x00, 0x0d, 0x00, 0xc2, 0x69, 0x01, 0x8b, 0x00, 0x20, + 0x83, 0x42, 0x00, 0xd0, 0x30, 0x00, 0x22, 0x26, 0x09, 0xab, 0x05, 0x93, + 0x0f, 0x4b, 0x6e, 0x44, 0x02, 0x90, 0x01, 0x93, 0x04, 0x96, 0x01, 0x23, + 0x03, 0x97, 0x00, 0x95, 0x20, 0x00, 0xff, 0xf7, 0x07, 0xfe, 0x0b, 0x4b, + 0x98, 0x42, 0x0f, 0xd0, 0x00, 0x28, 0x0b, 0xdb, 0x10, 0x9b, 0x31, 0x88, + 0x09, 0x9a, 0x00, 0x2b, 0x04, 0xd0, 0x0b, 0x01, 0x9b, 0x18, 0x10, 0x9d, + 0x01, 0x33, 0x2b, 0x80, 0x21, 0x83, 0xe2, 0x61, 0x0b, 0xb0, 0xf0, 0xbd, + 0x02, 0x48, 0xfb, 0xe7, 0xc5, 0x47, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x1e, 0x27, 0x8b, 0xb0, 0x6f, 0x44, + 0x07, 0xae, 0x3a, 0x80, 0x33, 0x80, 0x04, 0x00, 0x0d, 0x00, 0xc2, 0x69, + 0x01, 0x8b, 0x00, 0x20, 0x83, 0x42, 0x00, 0xd0, 0x30, 0x00, 0x22, 0x26, + 0x09, 0xab, 0x05, 0x93, 0x0f, 0x4b, 0x6e, 0x44, 0x02, 0x90, 0x01, 0x93, + 0x04, 0x96, 0x02, 0x23, 0x03, 0x97, 0x00, 0x95, 0x20, 0x00, 0xff, 0xf7, + 0xcf, 0xfd, 0x0b, 0x4b, 0x98, 0x42, 0x0f, 0xd0, 0x00, 0x28, 0x0b, 0xdb, + 0x10, 0x9b, 0x31, 0x88, 0x09, 0x9a, 0x00, 0x2b, 0x04, 0xd0, 0x0b, 0x01, + 0x9b, 0x18, 0x10, 0x9d, 0x01, 0x33, 0x2b, 0x80, 0x21, 0x83, 0xe2, 0x61, + 0x0b, 0xb0, 0xf0, 0xbd, 0x02, 0x48, 0xfb, 0xe7, 0xc5, 0x47, 0x00, 0x00, + 0xa8, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0e, 0x27, + 0x12, 0x26, 0x89, 0xb0, 0x03, 0x93, 0x10, 0xab, 0x1b, 0x78, 0x15, 0x00, + 0x04, 0x93, 0x02, 0xab, 0xff, 0x18, 0x39, 0x80, 0xf6, 0x18, 0x07, 0xab, + 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x33, 0x00, 0x04, 0x00, 0xff, 0xf7, + 0x41, 0xff, 0x00, 0x28, 0x67, 0xdb, 0x33, 0x88, 0x07, 0x9a, 0x1b, 0x03, + 0x52, 0x00, 0x9b, 0x18, 0x02, 0x22, 0x01, 0x97, 0x00, 0x92, 0x04, 0x21, + 0x00, 0x22, 0x20, 0x00, 0xfd, 0xf7, 0x9b, 0xfb, 0x00, 0x28, 0x58, 0xdb, + 0x01, 0x22, 0xa3, 0x6b, 0x07, 0x21, 0x01, 0x33, 0xa3, 0x63, 0x2b, 0x79, + 0x20, 0x00, 0x93, 0x43, 0x2b, 0x71, 0x07, 0x9b, 0x9b, 0x18, 0x32, 0x88, + 0x1b, 0x02, 0x12, 0x03, 0x9b, 0x18, 0x05, 0x22, 0x01, 0x95, 0x00, 0x92, + 0x00, 0x22, 0xfd, 0xf7, 0x84, 0xfb, 0x00, 0x28, 0x41, 0xdb, 0x03, 0x9b, + 0x00, 0x2b, 0x13, 0xd0, 0x07, 0x9b, 0x32, 0x88, 0x01, 0x33, 0x12, 0x03, + 0x1b, 0x02, 0x9b, 0x18, 0x0f, 0x9a, 0x05, 0x33, 0x9b, 0x18, 0x03, 0x9a, + 0x07, 0x21, 0x01, 0x92, 0x0e, 0x9a, 0x20, 0x00, 0x00, 0x92, 0x00, 0x22, + 0xfd, 0xf7, 0x6d, 0xfb, 0x00, 0x28, 0x2a, 0xdb, 0x04, 0x9b, 0x00, 0x2b, + 0x1a, 0xd0, 0x02, 0x22, 0x2b, 0x79, 0x13, 0x42, 0x16, 0xd0, 0x93, 0x43, + 0x02, 0xa9, 0x10, 0x32, 0x2b, 0x71, 0x52, 0x18, 0x07, 0x9b, 0x12, 0x88, + 0x01, 0x33, 0x12, 0x03, 0x1b, 0x02, 0x9b, 0x18, 0x01, 0x22, 0x04, 0x35, + 0x00, 0x92, 0x04, 0x33, 0x01, 0x95, 0x00, 0x22, 0x07, 0x21, 0x20, 0x00, + 0xfd, 0xf7, 0x4f, 0xfb, 0x00, 0x28, 0x0c, 0xdb, 0x11, 0x9b, 0x00, 0x2b, + 0x09, 0xd0, 0x12, 0x23, 0x02, 0xaa, 0x9b, 0x18, 0x1b, 0x88, 0x07, 0x9a, + 0x1b, 0x01, 0xd3, 0x18, 0x11, 0x9a, 0x01, 0x33, 0x13, 0x80, 0x09, 0xb0, + 0xf0, 0xbd, 0x00, 0x00, 0x7f, 0xb5, 0x0e, 0x22, 0x00, 0x26, 0x0f, 0x23, + 0x0c, 0x00, 0x6a, 0x44, 0x16, 0x80, 0x01, 0x92, 0x02, 0x22, 0x0b, 0x40, + 0x11, 0x49, 0x00, 0x92, 0x5b, 0x18, 0x21, 0x09, 0x09, 0x03, 0x5b, 0x00, + 0x5b, 0x18, 0x32, 0x00, 0x31, 0x00, 0x05, 0x00, 0xfd, 0xf7, 0x27, 0xfb, + 0xb0, 0x42, 0x13, 0xdb, 0xeb, 0x6b, 0x0d, 0x22, 0x01, 0x33, 0xeb, 0x63, + 0xab, 0x6b, 0x6a, 0x44, 0x01, 0x3b, 0xab, 0x63, 0x7e, 0x23, 0x13, 0x70, + 0x01, 0x92, 0x01, 0x22, 0x24, 0x02, 0x00, 0x92, 0x23, 0x1d, 0x32, 0x00, + 0x03, 0x21, 0x28, 0x00, 0xfd, 0xf7, 0x11, 0xfb, 0x04, 0xb0, 0x70, 0xbd, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x89, 0xb0, 0x15, 0x00, 0x0e, 0xaa, + 0x03, 0x91, 0x02, 0xca, 0x12, 0x24, 0x12, 0x88, 0x02, 0x91, 0x04, 0x92, + 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x13, 0x80, 0x07, 0xab, 0x64, 0x18, + 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x23, 0x00, 0x06, 0x00, 0x10, 0x9f, + 0xff, 0xf7, 0x8c, 0xfe, 0x00, 0x28, 0x5f, 0xdb, 0x24, 0x88, 0x07, 0x9b, + 0x24, 0x01, 0x1c, 0x19, 0x01, 0x34, 0xa4, 0xb2, 0x00, 0x2f, 0x00, 0xd0, + 0x3c, 0x80, 0x27, 0x02, 0x00, 0x2d, 0x1e, 0xd1, 0x80, 0x22, 0x04, 0x9b, + 0x52, 0x00, 0x1b, 0x02, 0x00, 0x92, 0x03, 0x99, 0x3a, 0x00, 0x30, 0x00, + 0xff, 0xf7, 0xa8, 0xfc, 0x00, 0x23, 0x02, 0x9d, 0x02, 0x93, 0x24, 0xe0, + 0x03, 0x22, 0x2b, 0x79, 0x04, 0x35, 0x93, 0x43, 0x2b, 0x70, 0x02, 0x3a, + 0x00, 0x92, 0x3b, 0x1d, 0x01, 0x95, 0x03, 0x9a, 0x07, 0x21, 0x30, 0x00, + 0xfd, 0xf7, 0xcb, 0xfa, 0x00, 0x28, 0x31, 0xda, 0x34, 0xe0, 0x01, 0x22, + 0x2b, 0x79, 0x10, 0x00, 0x59, 0x08, 0x93, 0x43, 0x92, 0x18, 0x13, 0x43, + 0x2b, 0x71, 0x80, 0x23, 0x88, 0x43, 0x5b, 0x00, 0x02, 0x90, 0x00, 0x93, + 0x01, 0x95, 0x3b, 0x00, 0x00, 0x22, 0x07, 0x21, 0x30, 0x00, 0xfd, 0xf7, + 0xb4, 0xfa, 0x00, 0x28, 0x1e, 0xdb, 0x0f, 0x23, 0x0f, 0x4a, 0x23, 0x40, + 0x9b, 0x18, 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, + 0x24, 0x09, 0x5b, 0x00, 0x24, 0x03, 0x00, 0x92, 0x1b, 0x19, 0x00, 0x22, + 0x04, 0x21, 0x30, 0x00, 0xfd, 0xf7, 0x9f, 0xfa, 0x00, 0x28, 0x09, 0xdb, + 0xb3, 0x6b, 0x01, 0x33, 0xb3, 0x63, 0x02, 0x9b, 0x00, 0x2b, 0xbd, 0xd1, + 0x04, 0x99, 0x30, 0x00, 0xff, 0xf7, 0x56, 0xff, 0x09, 0xb0, 0xf0, 0xbd, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x87, 0xb0, 0x04, 0x93, 0x0c, 0xab, + 0x1b, 0x88, 0x07, 0x00, 0x00, 0x93, 0x0d, 0xab, 0x1b, 0x88, 0x15, 0x00, + 0x03, 0x93, 0x04, 0x9b, 0x05, 0x91, 0x5b, 0x04, 0x5b, 0x0c, 0x02, 0x93, + 0x83, 0x6a, 0x1e, 0x1d, 0x00, 0x23, 0x34, 0x00, 0x01, 0x93, 0xfb, 0x6a, + 0x01, 0x9a, 0x93, 0x42, 0x08, 0xd8, 0x01, 0x2d, 0x00, 0xd8, 0x6e, 0xe0, + 0x3c, 0x6d, 0x00, 0x2c, 0x00, 0xd0, 0x6c, 0xe0, 0x07, 0xb0, 0xf0, 0xbd, + 0x43, 0x4a, 0x63, 0x88, 0x13, 0x40, 0x02, 0x9a, 0x93, 0x42, 0x38, 0xd1, + 0x00, 0x9b, 0x00, 0x2b, 0x2b, 0xd1, 0x02, 0x2d, 0x38, 0xd0, 0xa3, 0x8c, + 0x00, 0x2b, 0x30, 0xd0, 0x6b, 0x46, 0x9b, 0x89, 0x23, 0x81, 0x0e, 0x9b, + 0x00, 0x2b, 0x20, 0xd0, 0x0e, 0x9a, 0x63, 0x60, 0xe1, 0x69, 0x00, 0x9b, + 0x01, 0x32, 0x09, 0xd0, 0x0e, 0x9b, 0x00, 0x29, 0x06, 0xd0, 0xca, 0x68, + 0x0b, 0x8a, 0x9b, 0x18, 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd2, 0x13, 0x00, + 0x22, 0x69, 0x9a, 0x42, 0x00, 0xd9, 0x23, 0x61, 0x62, 0x69, 0x9a, 0x42, + 0x00, 0xd9, 0x63, 0x61, 0x00, 0x29, 0x06, 0xd0, 0xca, 0x68, 0x01, 0x33, + 0x9a, 0x42, 0x02, 0xd9, 0x38, 0x00, 0xfd, 0xf7, 0x91, 0xfa, 0xa3, 0x89, + 0x00, 0x9a, 0x93, 0x42, 0x05, 0xd1, 0x00, 0x23, 0x02, 0x2d, 0x01, 0xd0, + 0x6b, 0x46, 0x9b, 0x89, 0x63, 0x81, 0x01, 0x9b, 0x30, 0x34, 0x01, 0x33, + 0x01, 0x93, 0xae, 0xe7, 0x00, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x05, 0xd0, + 0xe1, 0x69, 0x00, 0x29, 0x02, 0xd0, 0x38, 0x00, 0xfd, 0xf7, 0x78, 0xfa, + 0x00, 0x23, 0x23, 0x80, 0x63, 0x80, 0xe2, 0xe7, 0x00, 0x22, 0xb3, 0x5e, + 0x00, 0x2b, 0x0c, 0xd0, 0xb0, 0x6a, 0x00, 0x28, 0x09, 0xd0, 0x17, 0x4a, + 0x73, 0x88, 0x13, 0x40, 0x02, 0x9a, 0x93, 0x42, 0x03, 0xd1, 0x05, 0x9a, + 0x00, 0x99, 0xff, 0xf7, 0xd1, 0xfa, 0x01, 0x34, 0x30, 0x36, 0xfb, 0x6a, + 0xa3, 0x42, 0xe9, 0xd8, 0x90, 0xe7, 0x00, 0x24, 0xf9, 0xe7, 0x00, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x8e, 0xe7, 0x6b, 0x46, 0x10, 0x22, 0x9b, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0x88, 0xe7, 0x00, 0x99, 0x01, 0x2d, 0x08, 0xd0, + 0x00, 0x2d, 0x0b, 0xd0, 0xeb, 0x1e, 0x01, 0x2b, 0x08, 0xd9, 0x29, 0x00, + 0x02, 0x2d, 0x00, 0xd0, 0x7c, 0xe7, 0x03, 0x9b, 0x02, 0x9a, 0x38, 0x00, + 0xa0, 0x47, 0x77, 0xe7, 0x01, 0x21, 0xf8, 0xe7, 0xff, 0x7f, 0xff, 0xff, + 0xf0, 0xb5, 0x16, 0x27, 0x97, 0xb0, 0x1c, 0xab, 0x1b, 0x78, 0x04, 0x00, + 0x06, 0x93, 0x02, 0xab, 0xff, 0x18, 0x39, 0x80, 0xfb, 0x21, 0x05, 0x92, + 0xfe, 0xf7, 0x34, 0xfe, 0x05, 0x1e, 0x65, 0xdb, 0x3a, 0x88, 0x34, 0x4b, + 0x20, 0x00, 0x13, 0x43, 0x3b, 0x80, 0x09, 0xab, 0x00, 0x93, 0x1a, 0x23, + 0x02, 0xaa, 0x9b, 0x18, 0x21, 0x8a, 0x62, 0x69, 0xff, 0xf7, 0x5c, 0xfd, + 0x05, 0x1e, 0x55, 0xdb, 0x02, 0xab, 0x5b, 0x8b, 0x09, 0x9a, 0x1b, 0x03, + 0x52, 0x00, 0x9b, 0x18, 0x02, 0x22, 0x01, 0x97, 0x00, 0x92, 0x04, 0x21, + 0x00, 0x22, 0x20, 0x00, 0xfd, 0xf7, 0xb5, 0xf9, 0x05, 0x1e, 0x45, 0xdb, + 0xa3, 0x6b, 0x0a, 0xae, 0x01, 0x33, 0xa3, 0x63, 0x3b, 0x88, 0x2d, 0x20, + 0x33, 0x80, 0x00, 0x23, 0x73, 0x80, 0xf8, 0x33, 0x33, 0x71, 0x6b, 0x46, + 0x19, 0x7e, 0x02, 0xab, 0x31, 0x73, 0x01, 0x21, 0x49, 0x42, 0x0c, 0x91, + 0x20, 0x22, 0x05, 0x99, 0xc0, 0x18, 0x02, 0xf0, 0x9b, 0xfb, 0x09, 0x98, + 0x07, 0x21, 0x43, 0x1c, 0x02, 0xa8, 0x42, 0x8b, 0x1b, 0x02, 0x12, 0x03, + 0x9b, 0x18, 0x2e, 0x22, 0x01, 0x96, 0x00, 0x92, 0x20, 0x00, 0x00, 0x22, + 0xfd, 0xf7, 0x8d, 0xf9, 0x05, 0x1e, 0x1d, 0xdb, 0x01, 0x21, 0x49, 0x42, + 0x3b, 0x88, 0x02, 0x91, 0x02, 0xa9, 0x4a, 0x8b, 0x09, 0x99, 0x12, 0x01, + 0x8a, 0x18, 0x01, 0x32, 0x92, 0xb2, 0x01, 0x92, 0x00, 0x22, 0x31, 0x00, + 0x00, 0x92, 0x20, 0x00, 0x01, 0x32, 0xff, 0xf7, 0xe9, 0xfe, 0x1d, 0x9b, + 0x00, 0x2b, 0x07, 0xd0, 0x02, 0xab, 0x5b, 0x8b, 0x09, 0x9a, 0x1b, 0x01, + 0xd3, 0x18, 0x1d, 0x9a, 0x01, 0x33, 0x13, 0x80, 0x28, 0x00, 0x17, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, 0xf0, 0xb5, 0x89, 0xb0, + 0x05, 0x93, 0x80, 0x23, 0x0e, 0x9c, 0x1b, 0x02, 0x1a, 0x43, 0x06, 0x00, + 0x0f, 0x00, 0x04, 0x92, 0x00, 0x2c, 0x0e, 0xd1, 0x04, 0x21, 0x7a, 0x5e, + 0x41, 0x6a, 0x05, 0x9b, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, + 0x1b, 0x02, 0xea, 0x39, 0xfd, 0xf7, 0xeb, 0xf8, 0x05, 0x1e, 0x4e, 0xdb, + 0x74, 0x6a, 0x23, 0x79, 0xda, 0x07, 0x4d, 0xd4, 0x5a, 0xb2, 0x00, 0x2a, + 0x4c, 0xda, 0x9a, 0x07, 0x4c, 0xd4, 0x5b, 0x07, 0x4c, 0xd4, 0x63, 0x88, + 0x00, 0x2b, 0x4b, 0xd1, 0x0f, 0x9b, 0x00, 0x2b, 0x05, 0xd0, 0x20, 0x00, + 0x20, 0x22, 0x19, 0x00, 0x0d, 0x30, 0x02, 0xf0, 0x35, 0xfb, 0x11, 0x9b, + 0x00, 0x2b, 0x03, 0xd0, 0x23, 0x81, 0x11, 0x9b, 0x1b, 0x0c, 0x63, 0x81, + 0x39, 0x1e, 0x01, 0xd0, 0x04, 0x23, 0xf9, 0x5e, 0x16, 0x23, 0x02, 0xaa, + 0x9b, 0x18, 0x02, 0x93, 0x05, 0x9b, 0x22, 0x00, 0x01, 0x93, 0x00, 0x23, + 0x30, 0x00, 0x00, 0x93, 0x04, 0x9b, 0xff, 0xf7, 0x11, 0xfe, 0x05, 0x1e, + 0x1d, 0xd1, 0x02, 0xab, 0xd9, 0x8a, 0x12, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0x19, 0x80, 0x0e, 0x9a, 0x20, 0x89, 0x53, 0x42, 0x5a, 0x41, 0x63, 0x89, + 0x01, 0x91, 0x1b, 0x04, 0x03, 0x43, 0x02, 0x93, 0x63, 0x88, 0x92, 0x00, + 0x00, 0x93, 0x21, 0x00, 0x04, 0x9b, 0x30, 0x00, 0xff, 0xf7, 0x76, 0xfe, + 0x00, 0x2f, 0x04, 0xd0, 0x16, 0x23, 0x02, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0xbb, 0x81, 0x28, 0x00, 0x09, 0xb0, 0xf0, 0xbd, 0x04, 0x4d, 0xfa, 0xe7, + 0x04, 0x4d, 0xf8, 0xe7, 0x04, 0x4d, 0xf6, 0xe7, 0x04, 0x4d, 0xf4, 0xe7, + 0x04, 0x4d, 0xf2, 0xe7, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x93, 0xb0, 0x03, 0x93, 0x0d, 0x00, 0x0b, 0x02, 0x14, 0x00, + 0x04, 0x21, 0x52, 0x5e, 0x2e, 0x21, 0x06, 0xae, 0x00, 0x91, 0x01, 0x96, + 0x18, 0x39, 0x07, 0x00, 0xfd, 0xf7, 0x73, 0xf8, 0x00, 0x28, 0x33, 0xdb, + 0x0f, 0x23, 0x2b, 0x40, 0x2a, 0x09, 0x01, 0x3b, 0x12, 0x03, 0x5b, 0x00, + 0x9b, 0x18, 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, + 0x14, 0x21, 0x00, 0x92, 0x38, 0x00, 0x00, 0x22, 0xfd, 0xf7, 0x5f, 0xf8, + 0xa5, 0x81, 0x27, 0x60, 0xb3, 0x68, 0x6a, 0x46, 0xa3, 0x60, 0x00, 0x23, + 0x63, 0x61, 0x23, 0x82, 0x02, 0xab, 0xe5, 0x81, 0xdb, 0x89, 0x95, 0x89, + 0xe3, 0x80, 0xa5, 0x83, 0x32, 0x79, 0xd4, 0x07, 0x0f, 0xd4, 0x51, 0xb2, + 0x00, 0x29, 0x0f, 0xda, 0x02, 0x21, 0x0a, 0x42, 0x0e, 0xd1, 0x52, 0x07, + 0x0e, 0xd4, 0x1b, 0xb2, 0x00, 0x2b, 0x0b, 0xda, 0x73, 0x88, 0x00, 0x2b, + 0x02, 0xd0, 0x05, 0x48, 0x00, 0xe0, 0x05, 0x48, 0x13, 0xb0, 0xf0, 0xbd, + 0x04, 0x48, 0xfb, 0xe7, 0x04, 0x48, 0xf9, 0xe7, 0x04, 0x48, 0xf7, 0xe7, + 0xe3, 0xd8, 0xff, 0xff, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x95, 0xb0, + 0x0e, 0x93, 0x07, 0x68, 0x0d, 0x00, 0x0e, 0x99, 0x83, 0x68, 0x06, 0x00, + 0xfb, 0x31, 0x38, 0x00, 0x0f, 0x92, 0x06, 0x93, 0xfe, 0xf7, 0xe0, 0xfc, + 0x04, 0x1e, 0x00, 0xda, 0x0b, 0xe2, 0x06, 0x9b, 0x0a, 0x93, 0xab, 0x42, + 0x00, 0xd9, 0x0a, 0x95, 0x7b, 0x6a, 0xb2, 0x89, 0x06, 0x93, 0x10, 0xab, + 0x1a, 0x80, 0xfb, 0x21, 0x0a, 0x98, 0x02, 0xf0, 0x9d, 0xf9, 0xfb, 0x21, + 0x83, 0xb2, 0x0a, 0x98, 0x09, 0x93, 0x02, 0xf0, 0x1d, 0xfa, 0x4e, 0x4b, + 0x0c, 0x91, 0x0b, 0x93, 0x00, 0x23, 0x07, 0x93, 0x08, 0x93, 0x9c, 0x42, + 0x00, 0xd1, 0x2e, 0xe1, 0x0a, 0x9a, 0x08, 0x9b, 0x94, 0x46, 0x63, 0x44, + 0x09, 0x93, 0xb3, 0x60, 0x73, 0x61, 0x6b, 0x46, 0x9b, 0x8b, 0x10, 0xad, + 0x2a, 0x88, 0x33, 0x82, 0x07, 0x9b, 0xf2, 0x81, 0x00, 0x2b, 0x00, 0xd1, + 0x26, 0xe2, 0x31, 0x00, 0x38, 0x00, 0xff, 0xf7, 0x31, 0xf8, 0x00, 0x28, + 0x31, 0xdb, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfd, 0xf7, 0x3d, 0xf8, 0x00, 0x28, 0x22, 0xdb, 0x00, 0x22, 0x02, 0x92, + 0x2a, 0x88, 0x06, 0x98, 0x01, 0x92, 0xc2, 0x78, 0x81, 0x78, 0x12, 0x02, + 0x0a, 0x43, 0x00, 0x92, 0xf3, 0x88, 0x00, 0x22, 0x79, 0x6a, 0x38, 0x00, + 0xff, 0xf7, 0x9c, 0xfd, 0x1a, 0x21, 0x0a, 0xa8, 0x09, 0x18, 0x04, 0x91, + 0x00, 0x21, 0x09, 0x98, 0xb3, 0x89, 0xf2, 0x88, 0x03, 0x90, 0x02, 0x91, + 0x01, 0x91, 0x00, 0x91, 0x38, 0x00, 0x31, 0x00, 0xff, 0xf7, 0xb4, 0xfe, + 0x00, 0x28, 0x00, 0xdb, 0xa5, 0xe1, 0x04, 0x00, 0xa3, 0xe1, 0x1a, 0x20, + 0x03, 0x91, 0x0a, 0xac, 0x0b, 0x99, 0x00, 0x19, 0x04, 0x90, 0x02, 0x91, + 0x01, 0x91, 0x79, 0x6a, 0xb3, 0x89, 0xf2, 0x88, 0x00, 0x91, 0x31, 0x00, + 0x38, 0x00, 0xff, 0xf7, 0x9f, 0xfe, 0x11, 0xe1, 0x10, 0xad, 0x2a, 0x88, + 0x0b, 0x9b, 0x31, 0x00, 0x38, 0x00, 0xfe, 0xf7, 0xe3, 0xff, 0x04, 0x1e, + 0x00, 0xda, 0x88, 0xe1, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, + 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, + 0x38, 0x00, 0xfc, 0xf7, 0xee, 0xff, 0x04, 0x1e, 0x00, 0xda, 0x78, 0xe1, + 0x00, 0x24, 0x02, 0x94, 0x2a, 0x88, 0xf3, 0x88, 0x01, 0x92, 0x06, 0x9a, + 0x38, 0x00, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, 0x00, 0x92, + 0x79, 0x6a, 0x22, 0x00, 0xff, 0xf7, 0x4c, 0xfd, 0x1a, 0x21, 0x0a, 0xa8, + 0x09, 0x18, 0x04, 0x91, 0x0a, 0x98, 0x08, 0x99, 0xb3, 0x89, 0x09, 0x18, + 0xf2, 0x88, 0x03, 0x91, 0x02, 0x94, 0x01, 0x94, 0x00, 0x94, 0xc2, 0xe7, + 0xff, 0xff, 0x00, 0x00, 0xb3, 0x68, 0x58, 0x1e, 0xc6, 0x4b, 0x98, 0x42, + 0x0f, 0xd9, 0x08, 0x9b, 0x00, 0x2b, 0x0c, 0xd1, 0xfb, 0x21, 0x02, 0xf0, + 0xed, 0xf8, 0x7c, 0x21, 0x69, 0x38, 0x02, 0xf0, 0xe9, 0xf8, 0x07, 0x9b, + 0x01, 0x30, 0x80, 0xb2, 0x83, 0x42, 0x00, 0xd8, 0xfb, 0xe0, 0x80, 0x23, + 0xf1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x6b, 0x46, 0x9b, 0x8b, 0x12, 0xad, + 0x6b, 0x80, 0xf9, 0x23, 0x2b, 0x71, 0x10, 0xab, 0x29, 0x80, 0x03, 0x93, + 0x01, 0x23, 0x02, 0x93, 0x00, 0x23, 0x2a, 0x00, 0x01, 0x93, 0x00, 0x93, + 0x38, 0x00, 0xff, 0xf7, 0xe1, 0xfb, 0x04, 0x1e, 0x00, 0xda, 0x2a, 0xe1, + 0x80, 0x22, 0xff, 0x21, 0x52, 0x00, 0x78, 0x6a, 0x02, 0xf0, 0x7d, 0xf9, + 0x05, 0x22, 0x29, 0x00, 0x78, 0x6a, 0x02, 0xf0, 0x6f, 0xf9, 0x00, 0x22, + 0x02, 0x92, 0x0a, 0xaa, 0x12, 0x8b, 0xf3, 0x88, 0x01, 0x92, 0x07, 0x9a, + 0x38, 0x00, 0x00, 0x92, 0x79, 0x6a, 0x01, 0x22, 0xff, 0xf7, 0xf6, 0xfc, + 0x10, 0xab, 0x1b, 0x88, 0x0a, 0x9a, 0xf3, 0x81, 0x6b, 0x46, 0x9b, 0x8b, + 0x33, 0x82, 0x08, 0x9b, 0x9b, 0x18, 0x73, 0x61, 0xb3, 0x60, 0x07, 0x9b, + 0x0b, 0x93, 0x08, 0x9a, 0x0e, 0x9b, 0x0c, 0x99, 0x9b, 0x1a, 0xfb, 0x22, + 0x52, 0x1a, 0x0d, 0x92, 0x9a, 0x42, 0x00, 0xd9, 0x0d, 0x93, 0x0c, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0xfa, 0xe0, 0x6b, 0x46, 0x9b, 0x8c, 0x12, 0xaa, + 0xf1, 0x88, 0x53, 0x80, 0xfd, 0x23, 0x08, 0x98, 0x13, 0x71, 0x0f, 0x9b, + 0x49, 0x04, 0x49, 0x0c, 0x1b, 0x18, 0x11, 0xa8, 0x11, 0x80, 0x03, 0x90, + 0x01, 0x20, 0x02, 0x90, 0x0c, 0x98, 0x01, 0x90, 0x0d, 0x98, 0x00, 0x90, + 0x38, 0x00, 0xff, 0xf7, 0x93, 0xfb, 0x04, 0x1e, 0x00, 0xd0, 0xed, 0xe6, + 0x11, 0xab, 0x1d, 0x88, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x11, 0xe1, + 0x09, 0x9b, 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9d, 0x52, 0x0a, 0x9a, + 0x08, 0x9b, 0x9b, 0x18, 0x06, 0x9a, 0x13, 0x81, 0x1b, 0x0c, 0x53, 0x81, + 0x0d, 0x9a, 0x09, 0x98, 0x94, 0x46, 0x01, 0x30, 0x83, 0xb2, 0x09, 0x93, + 0x08, 0x9b, 0x63, 0x44, 0x08, 0x93, 0x00, 0x23, 0x0c, 0x93, 0x08, 0x9b, + 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd3, 0xcb, 0xe6, 0x00, 0x23, 0x07, 0x93, + 0x09, 0x9b, 0x68, 0x2b, 0x07, 0xd9, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x02, 0xf0, 0x50, 0xf8, 0x01, 0x30, 0x83, 0xb2, 0x07, 0x93, 0x0b, 0x9b, + 0x07, 0x9a, 0x93, 0x42, 0xa3, 0xd0, 0x08, 0x9b, 0x00, 0x2b, 0x2d, 0xd0, + 0x0b, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x0f, 0xe7, 0x08, 0x9b, 0x0a, 0x9a, + 0x99, 0x18, 0x06, 0x9b, 0x06, 0x9a, 0x19, 0x81, 0x0b, 0x0c, 0x53, 0x81, + 0x0a, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0xf2, 0xe6, 0x10, 0xad, 0x2a, 0x88, + 0x31, 0x00, 0x38, 0x00, 0xfe, 0xf7, 0xe8, 0xfe, 0x04, 0x1e, 0x00, 0xda, + 0x8d, 0xe0, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfc, 0xf7, 0xf3, 0xfe, 0x04, 0x1e, 0x00, 0xda, 0x7d, 0xe0, 0x08, 0x9b, + 0x0a, 0x9a, 0x9b, 0x18, 0xb3, 0x60, 0x73, 0x61, 0x07, 0x9b, 0x00, 0x2b, + 0x00, 0xd0, 0x1b, 0xe7, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x10, 0xab, + 0x1b, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, + 0xea, 0x39, 0x38, 0x00, 0xfc, 0xf7, 0x75, 0xfe, 0x04, 0x1e, 0x64, 0xdb, + 0x01, 0x22, 0x06, 0x9b, 0x1b, 0x79, 0x13, 0x42, 0x00, 0xd0, 0xe9, 0xe0, + 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xe7, 0xe0, 0x9a, 0x07, 0x00, 0xd5, + 0xe6, 0xe0, 0x5b, 0x07, 0x00, 0xd5, 0xe5, 0xe0, 0x06, 0x22, 0xb3, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0xe0, 0xe0, 0x06, 0x9b, 0x5b, 0x88, 0x0b, 0x93, + 0x00, 0x2b, 0x00, 0xd1, 0x43, 0xe7, 0x41, 0x4c, 0x47, 0xe0, 0x33, 0x8a, + 0x07, 0x9a, 0x93, 0x42, 0x34, 0xd1, 0x1e, 0x23, 0xf2, 0x89, 0x0a, 0xa9, + 0x5b, 0x18, 0x1a, 0x80, 0x1e, 0x25, 0x0a, 0xab, 0x04, 0x21, 0x72, 0x5e, + 0x79, 0x6a, 0xed, 0x18, 0x2b, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, + 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x38, 0x00, 0xfc, 0xf7, 0x3d, 0xfe, + 0x04, 0x1e, 0x2c, 0xdb, 0x01, 0x22, 0x06, 0x9b, 0x1b, 0x79, 0x13, 0x42, + 0x00, 0xd0, 0xb1, 0xe0, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xaf, 0xe0, + 0x9a, 0x07, 0x00, 0xd5, 0xae, 0xe0, 0x5b, 0x07, 0x00, 0xd5, 0xad, 0xe0, + 0x06, 0x22, 0xb3, 0x5e, 0x00, 0x2b, 0x00, 0xdb, 0xa8, 0xe0, 0x06, 0x9b, + 0x07, 0x9a, 0x5b, 0x88, 0x93, 0x42, 0xc8, 0xd1, 0x2a, 0x88, 0x10, 0xab, + 0x1a, 0x80, 0xfb, 0xe6, 0x80, 0x23, 0xf1, 0x88, 0x1b, 0x02, 0x19, 0x43, + 0x1e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, 0x00, 0x93, 0x07, 0x9a, 0x08, 0x9b, + 0x38, 0x00, 0xff, 0xf7, 0x45, 0xfa, 0x04, 0x1e, 0xc0, 0xda, 0x20, 0x00, + 0x15, 0xb0, 0xf0, 0xbd, 0x07, 0x9b, 0x00, 0x2b, 0x21, 0xd1, 0x09, 0x9b, + 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9a, 0x5a, 0x11, 0xab, 0x1a, 0x80, + 0x11, 0xad, 0x2a, 0x88, 0x31, 0x1d, 0x09, 0x9b, 0x38, 0x00, 0xfe, 0xf7, + 0x97, 0xff, 0x04, 0x1e, 0xe9, 0xdb, 0x2b, 0x88, 0x0c, 0x9a, 0x1b, 0x02, + 0x05, 0x33, 0x08, 0x98, 0x9b, 0x18, 0x04, 0x21, 0x72, 0x5e, 0x0f, 0x99, + 0x09, 0x18, 0x01, 0x91, 0x0d, 0x99, 0x38, 0x00, 0x00, 0x91, 0x07, 0x21, + 0xfc, 0xf7, 0x4b, 0xfe, 0xf7, 0xe6, 0x09, 0x9b, 0x19, 0x1d, 0x68, 0x2b, + 0x05, 0xd9, 0x09, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0xf4, 0xff, + 0x04, 0x31, 0x06, 0x9b, 0x49, 0x00, 0x5a, 0x5a, 0xd4, 0xe7, 0xc0, 0x46, + 0xf2, 0x66, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, 0x09, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x09, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0xe1, 0xff, 0x04, 0x31, 0x06, 0x9b, 0x49, 0x00, 0x5d, 0x52, 0xeb, 0xe6, + 0x0a, 0x9b, 0x00, 0x2b, 0x31, 0xd1, 0x69, 0x46, 0x06, 0x9b, 0x09, 0x8c, + 0x38, 0x00, 0x19, 0x81, 0x08, 0x9b, 0x06, 0x99, 0x1b, 0x0c, 0x4b, 0x81, + 0x0a, 0x9b, 0x31, 0x00, 0xfe, 0xf7, 0xfe, 0xfd, 0x00, 0x28, 0x00, 0xda, + 0xfd, 0xe5, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfc, 0xf7, 0x09, 0xfe, 0x00, 0x28, 0x00, 0xda, 0xed, 0xe5, 0x06, 0x9a, + 0xf3, 0x88, 0x11, 0x89, 0x52, 0x89, 0x38, 0x00, 0x12, 0x04, 0x0a, 0x43, + 0x02, 0x92, 0x2a, 0x88, 0x01, 0x92, 0x06, 0x9a, 0x52, 0x88, 0x00, 0x92, + 0x79, 0x6a, 0x04, 0x22, 0xff, 0xf7, 0x66, 0xfb, 0x81, 0xe7, 0x1a, 0x21, + 0x0a, 0xa8, 0x09, 0x18, 0x04, 0x91, 0x09, 0x99, 0xb3, 0x89, 0x03, 0x91, + 0x07, 0x99, 0xf2, 0x88, 0x02, 0x91, 0x01, 0x91, 0x79, 0x6a, 0xc6, 0xe5, + 0x03, 0x4c, 0x72, 0xe7, 0x03, 0x4c, 0x70, 0xe7, 0x03, 0x4c, 0x6e, 0xe7, + 0x03, 0x4c, 0x6c, 0xe7, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x95, 0xb0, + 0x0d, 0x91, 0x19, 0x00, 0x05, 0x68, 0x07, 0x00, 0xfb, 0x31, 0x28, 0x00, + 0x0f, 0x92, 0x0e, 0x93, 0xfe, 0xf7, 0x2a, 0xfa, 0x04, 0x1e, 0x00, 0xda, + 0x6e, 0xe1, 0x6b, 0x6a, 0xfb, 0x21, 0x07, 0x93, 0xbb, 0x89, 0x0d, 0x98, + 0x0b, 0x93, 0x01, 0xf0, 0xed, 0xfe, 0xfb, 0x21, 0x83, 0xb2, 0x0d, 0x98, + 0x08, 0x93, 0x01, 0xf0, 0x6d, 0xff, 0x00, 0x23, 0x0a, 0x91, 0xc1, 0x4e, + 0x06, 0x93, 0x09, 0x93, 0x9c, 0x42, 0x00, 0xd1, 0x2c, 0xe1, 0x0d, 0x9a, + 0x09, 0x9b, 0x94, 0x46, 0x63, 0x44, 0x7b, 0x61, 0x6b, 0x46, 0x9b, 0x8d, + 0xfb, 0x81, 0x6b, 0x46, 0x1b, 0x8b, 0x3b, 0x82, 0x06, 0x9b, 0x00, 0x2b, + 0x00, 0xd1, 0xf4, 0xe1, 0x0b, 0x9a, 0x39, 0x00, 0x28, 0x00, 0xfe, 0xf7, + 0x83, 0xfd, 0x00, 0x28, 0x00, 0xda, 0xff, 0xe1, 0x04, 0x22, 0xb9, 0x5e, + 0x1e, 0x22, 0x00, 0x26, 0x0a, 0xa8, 0x12, 0x18, 0xfb, 0x88, 0x02, 0x92, + 0x0b, 0x9a, 0x00, 0x96, 0x01, 0x92, 0x28, 0x00, 0x07, 0x9a, 0xff, 0xf7, + 0x7f, 0xfa, 0x0a, 0xab, 0xda, 0x8b, 0x6b, 0x46, 0x1b, 0x8b, 0xfa, 0x81, + 0x3b, 0x82, 0xb0, 0x42, 0x00, 0xda, 0xe7, 0xe1, 0xfb, 0x88, 0x01, 0x92, + 0x07, 0x9a, 0x02, 0x96, 0x91, 0x78, 0xd2, 0x78, 0x28, 0x00, 0x12, 0x02, + 0x0a, 0x43, 0x00, 0x92, 0x07, 0x99, 0x32, 0x00, 0xff, 0xf7, 0xe6, 0xfa, + 0x1a, 0xe1, 0x00, 0x23, 0x06, 0x93, 0x33, 0x00, 0x0b, 0x9a, 0x39, 0x00, + 0x28, 0x00, 0xfe, 0xf7, 0x51, 0xfd, 0x04, 0x1e, 0x00, 0xda, 0x0f, 0xe1, + 0x04, 0x22, 0xb9, 0x5e, 0x1e, 0x22, 0x00, 0x26, 0x0a, 0xa8, 0x12, 0x18, + 0xfb, 0x88, 0x02, 0x92, 0x0b, 0x9a, 0x00, 0x96, 0x01, 0x92, 0x28, 0x00, + 0x07, 0x9a, 0xff, 0xf7, 0x4d, 0xfa, 0x04, 0x00, 0xb0, 0x42, 0x00, 0xda, + 0xfc, 0xe0, 0xfb, 0x88, 0x0a, 0xaa, 0x02, 0x96, 0xd2, 0x8b, 0x28, 0x00, + 0x01, 0x92, 0x07, 0x9a, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, + 0x00, 0x92, 0x07, 0x99, 0x32, 0x00, 0xff, 0xf7, 0xb7, 0xfa, 0x06, 0x9b, + 0xb3, 0x42, 0x29, 0xd1, 0x04, 0x21, 0x7a, 0x5e, 0x69, 0x6a, 0x0b, 0x9b, + 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, + 0x28, 0x00, 0xfc, 0xf7, 0xd2, 0xfc, 0x04, 0x1e, 0x00, 0xda, 0xd9, 0xe0, + 0x07, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x00, 0xd5, 0x94, 0xe1, 0x5a, 0xb2, + 0x00, 0x2a, 0x00, 0xdb, 0x92, 0xe1, 0x9a, 0x07, 0x00, 0xd5, 0x91, 0xe1, + 0x5b, 0x07, 0x00, 0xd5, 0x90, 0xe1, 0x06, 0x22, 0xbb, 0x5e, 0x00, 0x2b, + 0x00, 0xdb, 0x8b, 0xe1, 0x07, 0x9b, 0x5b, 0x88, 0x00, 0x2b, 0x39, 0xd0, + 0x73, 0x4c, 0xbf, 0xe0, 0x3b, 0x8a, 0x06, 0x9a, 0x93, 0x42, 0x00, 0xd0, + 0xbd, 0xe0, 0x1e, 0x23, 0xfa, 0x89, 0x0a, 0xa9, 0x5b, 0x18, 0x1a, 0x80, + 0x1e, 0x26, 0x04, 0x21, 0x7a, 0x5e, 0x0a, 0xab, 0x69, 0x6a, 0xf6, 0x18, + 0x33, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, + 0xea, 0x39, 0x28, 0x00, 0xfc, 0xf7, 0x9b, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0xa2, 0xe0, 0x07, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x00, 0xd5, 0x5d, 0xe1, + 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0x5b, 0xe1, 0x9a, 0x07, 0x00, 0xd5, + 0x5a, 0xe1, 0x5b, 0x07, 0x00, 0xd5, 0x59, 0xe1, 0x06, 0x22, 0xbb, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0x54, 0xe1, 0x07, 0x9b, 0x06, 0x9a, 0x5b, 0x88, + 0x93, 0x42, 0xc7, 0xd1, 0x33, 0x88, 0x0b, 0x93, 0x6b, 0x46, 0x9b, 0x8d, + 0x0d, 0x9a, 0xfb, 0x81, 0x6b, 0x46, 0x1b, 0x8b, 0x3b, 0x82, 0x09, 0x9b, + 0x9b, 0x18, 0x7b, 0x61, 0x09, 0x9a, 0x0e, 0x9b, 0x0a, 0x99, 0x9b, 0x1a, + 0xfb, 0x22, 0x56, 0x1a, 0x9e, 0x42, 0x00, 0xd9, 0x1e, 0x00, 0x06, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x84, 0xe0, 0x08, 0x9b, 0x07, 0x9a, 0x17, 0x33, + 0x5b, 0x00, 0x9b, 0x5a, 0x0c, 0x93, 0x00, 0x23, 0x06, 0x93, 0x6b, 0x46, + 0x1b, 0x8c, 0x12, 0xaa, 0xf9, 0x88, 0x53, 0x80, 0xff, 0x23, 0x49, 0x04, + 0x13, 0x71, 0x0a, 0x9b, 0x49, 0x0c, 0x11, 0x80, 0x00, 0x2b, 0x00, 0xd0, + 0x82, 0xe0, 0xfb, 0x2e, 0x00, 0xd0, 0x7f, 0xe0, 0x09, 0x98, 0x0f, 0x9b, + 0x00, 0x96, 0x1b, 0x18, 0x11, 0xa8, 0x03, 0x90, 0x01, 0x20, 0x02, 0x90, + 0x0a, 0x98, 0x01, 0x90, 0x28, 0x00, 0xff, 0xf7, 0xe5, 0xf8, 0x0c, 0x99, + 0x28, 0x00, 0xff, 0xf7, 0x63, 0xf9, 0x04, 0x1e, 0x00, 0xd0, 0xea, 0xe6, + 0x11, 0xab, 0x1b, 0x88, 0x0a, 0x93, 0x06, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0xd7, 0xe0, 0x69, 0x46, 0x08, 0x9b, 0x07, 0x9a, 0x17, 0x33, 0x09, 0x8d, + 0x5b, 0x00, 0x99, 0x52, 0x08, 0x98, 0x01, 0x30, 0x83, 0xb2, 0x08, 0x93, + 0x09, 0x9b, 0x9b, 0x19, 0x09, 0x93, 0x00, 0x23, 0x06, 0x9e, 0x0a, 0x93, + 0x09, 0x9b, 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd3, 0xcd, 0xe6, 0x08, 0x9b, + 0x68, 0x2b, 0x00, 0xd8, 0xf5, 0xe0, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x01, 0xf0, 0xa4, 0xfd, 0x01, 0x30, 0x83, 0xb2, 0x06, 0x93, 0x9e, 0x42, + 0x9a, 0xd0, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd1, 0x54, 0xe7, 0x00, 0x2e, + 0x00, 0xd0, 0xf8, 0xe6, 0x1a, 0x21, 0x0a, 0xa8, 0x09, 0x18, 0xbb, 0x89, + 0xfa, 0x88, 0x03, 0x94, 0x02, 0x94, 0x01, 0x94, 0x04, 0x91, 0x69, 0x6a, + 0x28, 0x00, 0x00, 0x91, 0x39, 0x00, 0xff, 0xf7, 0xf5, 0xfa, 0x04, 0x1e, + 0x00, 0xdb, 0x3f, 0xe7, 0x20, 0x00, 0x15, 0xb0, 0xf0, 0xbd, 0x80, 0x23, + 0xf9, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x06, 0x9a, 0x00, 0x23, 0x28, 0x00, 0xff, 0xf7, 0x1a, 0xf8, + 0x04, 0x1e, 0x00, 0xdb, 0x36, 0xe7, 0xeb, 0xe7, 0x08, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x08, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0xef, 0xfd, 0x04, 0x31, 0x07, 0x9b, 0x49, 0x00, 0x5b, 0x5a, 0x0c, 0x93, + 0x73, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, + 0x39, 0x1d, 0x08, 0x9b, 0x0c, 0x9a, 0x28, 0x00, 0xfe, 0xf7, 0x64, 0xfd, + 0x04, 0x1e, 0xcf, 0xdb, 0x11, 0xab, 0xf9, 0x88, 0x03, 0x93, 0x00, 0x23, + 0x49, 0x04, 0x49, 0x0c, 0x02, 0x93, 0x01, 0x93, 0x00, 0x93, 0x12, 0xaa, + 0x28, 0x00, 0xff, 0xf7, 0x5d, 0xf8, 0x04, 0x1e, 0x00, 0xd0, 0x66, 0xe6, + 0x0a, 0x9b, 0x00, 0x2b, 0x2e, 0xd1, 0x0a, 0x9b, 0x98, 0x19, 0xfa, 0x28, + 0x3b, 0xd9, 0x0a, 0xab, 0x9b, 0x8b, 0x0a, 0x9a, 0x1b, 0x02, 0x05, 0x33, + 0x09, 0x98, 0x9b, 0x18, 0x04, 0x21, 0x7a, 0x5e, 0x0f, 0x99, 0x00, 0x96, + 0x09, 0x18, 0x01, 0x91, 0x28, 0x00, 0x07, 0x21, 0xfc, 0xf7, 0x01, 0xfc, + 0x04, 0x1e, 0x00, 0xd0, 0x4b, 0xe6, 0x02, 0x21, 0x12, 0xaa, 0x13, 0x79, + 0x28, 0x00, 0x8b, 0x43, 0x13, 0x71, 0x04, 0x21, 0x7a, 0x5e, 0x0a, 0xab, + 0x13, 0xa9, 0x9b, 0x8b, 0x01, 0x91, 0x01, 0x21, 0x1b, 0x02, 0x00, 0x91, + 0x04, 0x33, 0x06, 0x31, 0xfc, 0xf7, 0xeb, 0xfb, 0x04, 0x1e, 0x00, 0xd1, + 0x43, 0xe7, 0x34, 0xe6, 0x0a, 0xaa, 0x92, 0x8b, 0x0c, 0x9b, 0x04, 0x20, + 0x39, 0x5e, 0x0a, 0x98, 0x1b, 0x02, 0x12, 0x02, 0x00, 0x90, 0x05, 0x33, + 0x05, 0x32, 0x28, 0x00, 0xfe, 0xf7, 0xa4, 0xfd, 0x04, 0x1e, 0xc0, 0xd0, + 0x23, 0xe6, 0x0a, 0x9b, 0x0c, 0x9a, 0x05, 0x33, 0x12, 0x02, 0x9b, 0x19, + 0x9b, 0x18, 0x11, 0xaa, 0x12, 0x88, 0x0a, 0x99, 0x12, 0x02, 0x05, 0x32, + 0x52, 0x18, 0x04, 0x24, 0x39, 0x5f, 0xfb, 0x24, 0x20, 0x1a, 0x00, 0x90, + 0x92, 0x19, 0x28, 0x00, 0xfe, 0xf7, 0x8c, 0xfd, 0x04, 0x1e, 0xac, 0xd0, + 0x0b, 0xe6, 0x08, 0x9b, 0x19, 0x1d, 0x68, 0x2b, 0x05, 0xd9, 0x08, 0x98, + 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0x68, 0xfd, 0x04, 0x31, 0x6a, 0x46, + 0x07, 0x9b, 0x12, 0x8d, 0x49, 0x00, 0x5a, 0x52, 0x1e, 0xe7, 0x1a, 0x21, + 0x0a, 0xa8, 0x09, 0x18, 0xbb, 0x89, 0xfa, 0x88, 0x04, 0x91, 0x06, 0x99, + 0x28, 0x00, 0x03, 0x91, 0x02, 0x91, 0x01, 0x91, 0x69, 0x6a, 0x00, 0x91, + 0x39, 0x00, 0xff, 0xf7, 0x37, 0xfa, 0x00, 0x28, 0x00, 0xdb, 0x41, 0xe7, + 0x04, 0x00, 0x3f, 0xe7, 0x0d, 0x4c, 0x3d, 0xe7, 0x0d, 0x4c, 0x3b, 0xe7, + 0x0d, 0x4c, 0x39, 0xe7, 0x0d, 0x4c, 0x37, 0xe7, 0x09, 0x9a, 0x0e, 0x9b, + 0x0a, 0x99, 0x9b, 0x1a, 0xfb, 0x22, 0x56, 0x1a, 0x9e, 0x42, 0x00, 0xd8, + 0xbd, 0xe6, 0x1e, 0x00, 0xbb, 0xe6, 0x00, 0x2e, 0xf2, 0xd0, 0x09, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x0b, 0xe6, 0x06, 0x93, 0x3a, 0xe6, 0xc0, 0x46, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0x70, 0xb5, 0x88, 0xb0, 0x07, 0xab, 0x1a, 0x26, + 0x04, 0x00, 0x05, 0x93, 0x08, 0x00, 0x00, 0x23, 0x15, 0x00, 0x0f, 0x4a, + 0x6e, 0x44, 0x03, 0x93, 0x02, 0x90, 0x01, 0x92, 0x00, 0x93, 0x21, 0x8b, + 0x04, 0x96, 0xe2, 0x69, 0x20, 0x00, 0xfe, 0xf7, 0x55, 0xfd, 0x0a, 0x4b, + 0x98, 0x42, 0x0d, 0xd0, 0x00, 0x28, 0x09, 0xdb, 0x31, 0x88, 0x07, 0x9a, + 0x00, 0x2d, 0x03, 0xd0, 0x0b, 0x01, 0x9b, 0x18, 0x01, 0x33, 0x2b, 0x80, + 0x21, 0x83, 0xe2, 0x61, 0x08, 0xb0, 0x70, 0xbd, 0x02, 0x48, 0xfb, 0xe7, + 0xcd, 0x48, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x83, 0x68, 0x93, 0xb0, 0x01, 0x3b, 0x04, 0x00, 0x0b, 0x91, + 0x07, 0x92, 0x06, 0x68, 0x03, 0x33, 0x00, 0xd8, 0xd6, 0xe0, 0x00, 0x25, + 0xaa, 0x42, 0x00, 0xd1, 0xde, 0xe0, 0x1a, 0x23, 0xa5, 0x89, 0x08, 0xaa, + 0xa7, 0x68, 0x9b, 0x18, 0x1d, 0x80, 0x00, 0x2f, 0x00, 0xd0, 0xd8, 0xe0, + 0x06, 0x97, 0x73, 0x6a, 0x08, 0x93, 0x07, 0x9b, 0x00, 0x2b, 0x13, 0xd0, + 0x0b, 0x9b, 0x00, 0x2b, 0x10, 0xd1, 0x10, 0xa9, 0xb8, 0x33, 0x0b, 0x70, + 0x01, 0x91, 0x01, 0x21, 0x2d, 0x02, 0x2b, 0x1d, 0x04, 0x20, 0x22, 0x5e, + 0x00, 0x91, 0x30, 0x00, 0x05, 0x31, 0xfc, 0xf7, 0x18, 0xfb, 0x05, 0x1e, + 0x00, 0xda, 0xbb, 0xe0, 0x9f, 0x4b, 0x0c, 0x93, 0x00, 0x23, 0x09, 0x93, + 0x0b, 0x9b, 0x9f, 0x42, 0x00, 0xd8, 0xfd, 0xe0, 0x06, 0x9b, 0x68, 0x2b, + 0x00, 0xd8, 0x14, 0xe2, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0x31, 0xfc, 0x01, 0x30, 0x83, 0xb2, 0x0a, 0x93, 0x0a, 0x9a, 0x0c, 0x9b, + 0x93, 0x42, 0x00, 0xd1, 0x0e, 0xe2, 0x0c, 0x9b, 0x1a, 0x00, 0x92, 0x4b, + 0x9a, 0x42, 0x29, 0xd0, 0x08, 0xab, 0x5a, 0x8b, 0x21, 0x00, 0x0c, 0x9b, + 0x30, 0x00, 0xfe, 0xf7, 0xd5, 0xfa, 0x05, 0x1e, 0x00, 0xda, 0x93, 0xe0, + 0x08, 0xab, 0x59, 0x8b, 0x30, 0x00, 0xfe, 0xf7, 0xab, 0xff, 0x05, 0x1e, + 0x00, 0xda, 0x8b, 0xe0, 0x00, 0x21, 0x08, 0xaa, 0x02, 0x91, 0x52, 0x8b, + 0xe3, 0x88, 0x01, 0x92, 0x08, 0x9a, 0x90, 0x78, 0xd2, 0x78, 0x12, 0x02, + 0x02, 0x43, 0x00, 0x92, 0x30, 0x00, 0x02, 0x22, 0xff, 0xf7, 0x46, 0xf8, + 0x0c, 0x9b, 0x00, 0x2b, 0x04, 0xd0, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd1, + 0x82, 0xe0, 0xa7, 0x60, 0x0a, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x8e, 0xe0, + 0xa2, 0x89, 0x1a, 0x33, 0x08, 0xa9, 0x5b, 0x18, 0x1a, 0x80, 0x04, 0x21, + 0x62, 0x5e, 0x71, 0x6a, 0x08, 0xab, 0x5b, 0x8b, 0x01, 0x91, 0x80, 0x21, + 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x30, 0x00, 0xfc, 0xf7, + 0x52, 0xfa, 0x05, 0x1e, 0x5a, 0xdb, 0x08, 0x9b, 0x1b, 0x79, 0xda, 0x07, + 0x00, 0xd5, 0xb0, 0xe1, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xae, 0xe1, + 0x9a, 0x07, 0x00, 0xd5, 0xad, 0xe1, 0x5b, 0x07, 0x00, 0xd5, 0xac, 0xe1, + 0x06, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x00, 0xdb, 0xa7, 0xe1, 0x08, 0x9b, + 0x0a, 0x9a, 0x5b, 0x88, 0x09, 0x93, 0x93, 0x42, 0x00, 0xd0, 0xa2, 0xe1, + 0x08, 0xab, 0x5b, 0x8b, 0x67, 0x61, 0xe3, 0x81, 0x6b, 0x46, 0x1b, 0x8d, + 0x23, 0x82, 0x00, 0x2a, 0x00, 0xd0, 0x65, 0xe0, 0x06, 0x9b, 0x08, 0x9a, + 0x17, 0x33, 0x5b, 0x00, 0xd3, 0x18, 0x1a, 0x88, 0x0d, 0x92, 0x01, 0x22, + 0x52, 0x42, 0x1a, 0x80, 0x00, 0x23, 0x0c, 0x93, 0x09, 0x93, 0x0b, 0x9b, + 0x21, 0x1d, 0x00, 0x2b, 0x07, 0xd0, 0x07, 0x9b, 0x00, 0x2b, 0x04, 0xd1, + 0x0b, 0x9b, 0xfb, 0x1a, 0xfa, 0x2b, 0x00, 0xd8, 0xa6, 0xe0, 0x06, 0x9b, + 0x0d, 0x9a, 0x30, 0x00, 0xfe, 0xf7, 0xaa, 0xfb, 0x4e, 0x4b, 0x98, 0x42, + 0x59, 0xd1, 0xfb, 0x21, 0x38, 0x00, 0x01, 0xf0, 0x1d, 0xfc, 0x00, 0x29, + 0x00, 0xd1, 0x89, 0xe0, 0x7f, 0x1a, 0x88, 0xe0, 0x07, 0x9b, 0x00, 0x2b, + 0x00, 0xd0, 0x28, 0xe7, 0xfb, 0x21, 0x30, 0x00, 0x49, 0x00, 0xfd, 0xf7, + 0xbb, 0xfe, 0x05, 0x1e, 0x00, 0xdb, 0x20, 0xe7, 0x28, 0x00, 0x13, 0xb0, + 0xf0, 0xbd, 0x78, 0x1e, 0xfb, 0x21, 0x01, 0xf0, 0x7f, 0xfb, 0x83, 0xb2, + 0x06, 0x93, 0x7b, 0x1c, 0x00, 0xd0, 0x1e, 0xe7, 0x00, 0x27, 0x1c, 0xe7, + 0x0f, 0xa9, 0x04, 0x91, 0x07, 0x99, 0xa3, 0x89, 0x02, 0x91, 0x01, 0x91, + 0x00, 0x91, 0xe2, 0x88, 0x03, 0x97, 0x21, 0x00, 0x30, 0x00, 0xff, 0xf7, + 0xd7, 0xf8, 0x05, 0x1e, 0x00, 0xdb, 0x6c, 0xe7, 0xe0, 0xe7, 0x80, 0x23, + 0xe1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1a, 0x23, 0x08, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x0a, 0x9a, 0x00, 0x23, 0x30, 0x00, 0xfe, 0xf7, 0xfe, 0xfd, + 0x05, 0x1e, 0x00, 0xdb, 0x65, 0xe7, 0xcf, 0xe7, 0x06, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x06, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0xd3, 0xfb, 0x04, 0x31, 0x08, 0x9b, 0x49, 0x00, 0x59, 0x18, 0x0b, 0x88, + 0x0d, 0x93, 0x01, 0x23, 0x5b, 0x42, 0x0b, 0x80, 0x0a, 0x9b, 0x0c, 0x93, + 0x91, 0xe7, 0x00, 0x28, 0x2c, 0xd0, 0x20, 0x4b, 0x98, 0x42, 0xa0, 0xd0, + 0x08, 0xab, 0x5d, 0x8b, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0xcf, 0xe0, + 0x00, 0x2f, 0x00, 0xd0, 0xc4, 0xe0, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd1, + 0xa7, 0xe0, 0x2a, 0x00, 0x3b, 0x00, 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, + 0xe1, 0xf9, 0x05, 0x1e, 0xa0, 0xdb, 0x08, 0xab, 0x59, 0x8b, 0x30, 0x00, + 0xfe, 0xf7, 0xb8, 0xfe, 0x05, 0x1e, 0x00, 0xda, 0x98, 0xe7, 0x02, 0x97, + 0x08, 0xaa, 0x52, 0x8b, 0xe3, 0x88, 0x01, 0x92, 0x00, 0x97, 0x02, 0x22, + 0x39, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0x58, 0xff, 0xa7, 0x60, 0x8b, 0xe7, + 0x0d, 0x99, 0x30, 0x00, 0xfe, 0xf7, 0xa4, 0xfe, 0x00, 0x28, 0x00, 0xd1, + 0x6f, 0xe7, 0xcd, 0xe7, 0xfb, 0x3f, 0x06, 0x98, 0xa7, 0x60, 0x01, 0x38, + 0x83, 0xb2, 0x67, 0x61, 0x06, 0x93, 0xc3, 0xe6, 0xff, 0xff, 0x00, 0x00, + 0xec, 0xd8, 0xff, 0xff, 0xe1, 0xd8, 0xff, 0xff, 0x06, 0x9b, 0x0d, 0x9a, + 0x30, 0x00, 0xfe, 0xf7, 0x03, 0xfb, 0x00, 0x28, 0xb8, 0xd1, 0x6a, 0x46, + 0xe1, 0x88, 0x12, 0x8b, 0x49, 0x04, 0x08, 0xab, 0x49, 0x0c, 0x5a, 0x84, + 0x19, 0x84, 0xff, 0x23, 0x24, 0x30, 0x08, 0xaa, 0x12, 0x18, 0x13, 0x70, + 0x08, 0xaa, 0xe1, 0x3b, 0x9b, 0x18, 0x03, 0x93, 0x07, 0x9b, 0x10, 0xaa, + 0x02, 0x93, 0x01, 0x93, 0x00, 0x93, 0x30, 0x00, 0xfe, 0xf7, 0xf0, 0xfd, + 0x00, 0x28, 0x9d, 0xd1, 0x0d, 0x9b, 0xfb, 0x21, 0x1b, 0x02, 0x05, 0x33, + 0x0a, 0x93, 0x0b, 0x98, 0x08, 0xab, 0xdd, 0x8b, 0x01, 0xf0, 0x56, 0xfb, + 0x2d, 0x02, 0x05, 0x35, 0x00, 0x91, 0x0a, 0x9b, 0x2a, 0x00, 0x07, 0x99, + 0x30, 0x00, 0xfe, 0xf7, 0x65, 0xfb, 0x00, 0x28, 0x00, 0xd0, 0x87, 0xe7, + 0x0d, 0x99, 0x30, 0x00, 0xfe, 0xf7, 0x56, 0xfe, 0x00, 0x28, 0x00, 0xd0, + 0x80, 0xe7, 0x24, 0x21, 0x02, 0x22, 0x08, 0xab, 0x5b, 0x18, 0x1b, 0x78, + 0x30, 0x00, 0x93, 0x43, 0x08, 0xaa, 0x52, 0x18, 0x13, 0x70, 0x04, 0x21, + 0x62, 0x5e, 0x08, 0xab, 0x11, 0xa9, 0xdb, 0x8b, 0x01, 0x91, 0x01, 0x21, + 0x1b, 0x02, 0x00, 0x91, 0x04, 0x33, 0x06, 0x31, 0xfc, 0xf7, 0x79, 0xf9, + 0x00, 0x28, 0x00, 0xd0, 0x66, 0xe7, 0x08, 0xab, 0xdd, 0x8b, 0x09, 0x9b, + 0x00, 0x2b, 0x09, 0xd1, 0x06, 0x98, 0x17, 0x30, 0x08, 0x9b, 0x40, 0x00, + 0x1d, 0x52, 0x0b, 0x9b, 0xa3, 0x60, 0x63, 0x61, 0x1f, 0x00, 0x57, 0xe7, + 0x06, 0x9b, 0x68, 0x2b, 0x02, 0xd8, 0x18, 0x00, 0x04, 0x30, 0xf1, 0xe7, + 0x06, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0x0f, 0xfb, 0x08, 0x1d, + 0xea, 0xe7, 0x70, 0x6a, 0xd2, 0x22, 0x2e, 0x30, 0xff, 0x21, 0x01, 0xf0, + 0x3a, 0xfb, 0x0f, 0xab, 0x04, 0x93, 0x01, 0x23, 0xe2, 0x88, 0x5b, 0x42, + 0x03, 0x93, 0x02, 0x97, 0x01, 0x97, 0x73, 0x6a, 0x00, 0x93, 0x2b, 0x00, + 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0xde, 0xff, 0x05, 0x1e, 0x00, 0xdb, + 0x5a, 0xe7, 0xe7, 0xe6, 0x0f, 0xab, 0x04, 0x93, 0x09, 0x9b, 0xe2, 0x88, + 0x03, 0x97, 0x02, 0x93, 0x01, 0x93, 0xec, 0xe7, 0x2a, 0x00, 0x09, 0x9b, + 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0x18, 0xf9, 0x05, 0x1e, 0x00, 0xda, + 0xd6, 0xe6, 0x00, 0x25, 0x04, 0x22, 0xa1, 0x5e, 0x10, 0xaa, 0x02, 0x92, + 0x08, 0xaa, 0x52, 0x8b, 0xe3, 0x88, 0x01, 0x92, 0x00, 0x95, 0x08, 0x9a, + 0x30, 0x00, 0xfe, 0xf7, 0x15, 0xfe, 0x05, 0x1e, 0x00, 0xda, 0xc5, 0xe6, + 0x00, 0x25, 0x08, 0xaa, 0x02, 0x95, 0x12, 0x8c, 0xe3, 0x88, 0x01, 0x92, + 0x08, 0x9a, 0x30, 0x00, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, + 0x00, 0x92, 0x08, 0x99, 0x2a, 0x00, 0xfe, 0xf7, 0x7f, 0xfe, 0x08, 0xab, + 0x1b, 0x8c, 0x0f, 0xa9, 0xe3, 0x81, 0x6b, 0x46, 0x9b, 0x8c, 0x67, 0x61, + 0x23, 0x82, 0xe2, 0x88, 0xa3, 0x89, 0x04, 0x91, 0x03, 0x97, 0x02, 0x95, + 0x01, 0x95, 0x00, 0x95, 0xb4, 0xe7, 0x0a, 0x4d, 0xa2, 0xe6, 0x0a, 0x4d, + 0xa0, 0xe6, 0x0a, 0x4d, 0x9e, 0xe6, 0x0a, 0x4d, 0x9c, 0xe6, 0x0a, 0x4d, + 0x9a, 0xe6, 0x00, 0x23, 0x0a, 0x93, 0x0c, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0xf1, 0xe5, 0x5d, 0xe6, 0x0a, 0x9b, 0x09, 0x93, 0xc4, 0xe6, 0xc0, 0x46, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x8f, 0xb0, + 0x07, 0x91, 0x08, 0x93, 0x03, 0x68, 0x04, 0x00, 0xfb, 0x21, 0x07, 0x98, + 0x04, 0x93, 0x0b, 0x92, 0x01, 0xf0, 0x00, 0xfa, 0x87, 0xb2, 0x00, 0x20, + 0x04, 0x9b, 0x5b, 0x6a, 0x06, 0x93, 0x07, 0x9b, 0x03, 0x93, 0x6b, 0x4b, + 0x05, 0x93, 0x0b, 0x9a, 0x07, 0x9b, 0x94, 0x46, 0x03, 0x9a, 0x63, 0x44, + 0x0a, 0x93, 0x93, 0x42, 0x3a, 0xd9, 0xe2, 0x6a, 0x00, 0x2a, 0x0c, 0xd0, + 0x13, 0x89, 0xbb, 0x42, 0x09, 0xd8, 0x51, 0x89, 0xb9, 0x42, 0x06, 0xd3, + 0xfb, 0x1a, 0x12, 0x68, 0x5b, 0x00, 0x9d, 0x5a, 0x00, 0x2d, 0x00, 0xd0, + 0x82, 0xe0, 0x68, 0x2f, 0x3d, 0xd9, 0x38, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x01, 0xf0, 0xd8, 0xf9, 0x05, 0x9b, 0x01, 0x30, 0x85, 0xb2, 0xab, 0x42, + 0x06, 0xd1, 0x38, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0x54, 0xfa, + 0x04, 0x31, 0x1c, 0xe0, 0x23, 0x8a, 0xab, 0x42, 0x05, 0xd1, 0x0e, 0x23, + 0xe2, 0x89, 0x0a, 0xa9, 0x5b, 0x18, 0x1a, 0x80, 0x2c, 0xe0, 0x80, 0x23, + 0xe1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x0e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x2a, 0x00, 0x00, 0x23, 0x04, 0x98, 0xfe, 0xf7, 0x5a, 0xfc, + 0x00, 0x28, 0x1d, 0xda, 0x0f, 0xb0, 0xf0, 0xbd, 0x39, 0x1d, 0x68, 0x2f, + 0xdb, 0xd8, 0x06, 0x9b, 0x49, 0x00, 0x5d, 0x5a, 0x4e, 0xe0, 0x45, 0x48, + 0xf4, 0xe7, 0x45, 0x48, 0xf2, 0xe7, 0x45, 0x48, 0xf0, 0xe7, 0x45, 0x48, + 0xee, 0xe7, 0x45, 0x48, 0xec, 0xe7, 0x45, 0x48, 0xea, 0xe7, 0x05, 0x9b, + 0x00, 0x2b, 0x38, 0xd0, 0x0e, 0x23, 0x00, 0x25, 0xa2, 0x89, 0x0a, 0xa9, + 0x5b, 0x18, 0x1a, 0x80, 0x0e, 0x26, 0x04, 0x21, 0x62, 0x5e, 0x04, 0x99, + 0x0a, 0xab, 0x49, 0x6a, 0xf6, 0x18, 0x33, 0x88, 0x05, 0x91, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x04, 0x98, + 0xfb, 0xf7, 0xf3, 0xff, 0x00, 0x28, 0xcd, 0xdb, 0x01, 0x22, 0x06, 0x9b, + 0x1b, 0x79, 0x13, 0x42, 0xd1, 0xd1, 0x5a, 0xb2, 0x00, 0x2a, 0xd0, 0xda, + 0x9a, 0x07, 0xd0, 0xd4, 0x5b, 0x07, 0xd0, 0xd4, 0x06, 0x22, 0xa3, 0x5e, + 0x00, 0x2b, 0xcc, 0xda, 0x06, 0x9b, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, + 0x13, 0x43, 0x05, 0x93, 0xab, 0x42, 0xc6, 0xd1, 0x03, 0x9b, 0x25, 0x82, + 0x63, 0x61, 0x33, 0x88, 0xe3, 0x81, 0x00, 0x2d, 0xb0, 0xd1, 0x3b, 0x00, + 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9d, 0x5a, 0x00, 0x23, 0x05, 0x93, + 0xfb, 0x21, 0x03, 0x98, 0x01, 0xf0, 0xde, 0xf9, 0x0a, 0x9b, 0x03, 0x9a, + 0x09, 0x91, 0x9a, 0x1a, 0x03, 0x99, 0xa3, 0x68, 0x5b, 0x1a, 0x93, 0x42, + 0x00, 0xd9, 0x13, 0x00, 0xfb, 0x26, 0x09, 0x9a, 0xb6, 0x1a, 0x9e, 0x42, + 0x00, 0xd9, 0x1e, 0x00, 0x00, 0x2e, 0xa4, 0xd0, 0x21, 0x1d, 0x3b, 0x00, + 0x2a, 0x00, 0x04, 0x98, 0xfe, 0xf7, 0x4c, 0xf9, 0x00, 0x28, 0x00, 0xda, + 0x88, 0xe7, 0x09, 0x9b, 0x04, 0x21, 0x62, 0x5e, 0x08, 0x99, 0x2d, 0x02, + 0x05, 0x33, 0x01, 0x91, 0xeb, 0x18, 0x00, 0x96, 0x17, 0x21, 0x04, 0x98, + 0xfb, 0xf7, 0x9f, 0xff, 0x00, 0x28, 0x00, 0xda, 0x78, 0xe7, 0x08, 0x9b, + 0x01, 0x37, 0x9b, 0x19, 0x08, 0x93, 0x03, 0x9b, 0xbf, 0xb2, 0x9b, 0x19, + 0x03, 0x93, 0x63, 0x61, 0x2b, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x0f, 0x23, 0x8d, 0xb0, 0x06, 0x91, 0x01, 0x21, 0x07, 0x92, + 0xc2, 0x68, 0x05, 0x00, 0x53, 0x43, 0x5b, 0x08, 0x09, 0xaa, 0x5b, 0x18, + 0x11, 0x80, 0x99, 0xb2, 0x1b, 0x04, 0x3c, 0xd4, 0x51, 0x80, 0x00, 0x23, + 0x53, 0x60, 0x07, 0x9b, 0x93, 0x60, 0x09, 0xac, 0x23, 0x88, 0x68, 0x6a, + 0x9c, 0x46, 0x62, 0x46, 0x63, 0x88, 0x9b, 0x1a, 0x80, 0x22, 0x12, 0x01, + 0x93, 0x42, 0x37, 0xdc, 0x80, 0x22, 0x00, 0x21, 0x52, 0x00, 0x01, 0xf0, + 0xa8, 0xf9, 0x00, 0x21, 0x07, 0x9b, 0x05, 0x91, 0x02, 0x93, 0x3d, 0x4b, + 0x04, 0x91, 0x01, 0x93, 0x03, 0x94, 0x0b, 0x00, 0x00, 0x91, 0x0a, 0x00, + 0x28, 0x00, 0xfe, 0xf7, 0xa9, 0xf9, 0x39, 0x4b, 0x98, 0x42, 0x01, 0xd0, + 0x00, 0x28, 0x12, 0xdb, 0x80, 0x26, 0x00, 0x22, 0x01, 0x23, 0x6f, 0x6a, + 0x76, 0x00, 0xbd, 0x5c, 0xff, 0x2d, 0x12, 0xd0, 0x00, 0x21, 0x28, 0x00, + 0x08, 0x41, 0x18, 0x40, 0x0a, 0xd1, 0x23, 0x88, 0xd2, 0x00, 0x59, 0x18, + 0x06, 0x9b, 0x8a, 0x18, 0x1a, 0x80, 0x0d, 0xb0, 0xf0, 0xbd, 0x2d, 0x4b, + 0x53, 0x80, 0xc0, 0xe7, 0x01, 0x31, 0x08, 0x29, 0xed, 0xd1, 0x01, 0x32, + 0xb2, 0x42, 0xe6, 0xd1, 0x29, 0x48, 0xf2, 0xe7, 0x62, 0x68, 0x00, 0x2a, + 0x1d, 0xd1, 0x09, 0xac, 0x22, 0x88, 0x63, 0x88, 0x00, 0x26, 0x9b, 0x1a, + 0x80, 0x22, 0x1b, 0x0a, 0x52, 0x00, 0x00, 0x21, 0x63, 0x60, 0x01, 0xf0, + 0x66, 0xf9, 0x22, 0x4b, 0x05, 0x96, 0x01, 0x93, 0x04, 0x96, 0x33, 0x00, + 0x03, 0x96, 0x02, 0x94, 0x00, 0x96, 0x32, 0x00, 0x31, 0x00, 0x28, 0x00, + 0xfe, 0xf7, 0x68, 0xf9, 0x18, 0x4b, 0x98, 0x42, 0x26, 0xd1, 0xa6, 0x60, + 0x9b, 0xe7, 0x00, 0x27, 0xff, 0x23, 0x39, 0x00, 0x46, 0x5c, 0x9e, 0x42, + 0x02, 0xd2, 0x33, 0x1e, 0x06, 0xd0, 0x0f, 0x00, 0x80, 0x26, 0x01, 0x31, + 0x76, 0x00, 0xb1, 0x42, 0xf4, 0xd1, 0x39, 0x00, 0x9a, 0x42, 0xcb, 0xd0, + 0x92, 0xb2, 0x51, 0x43, 0x61, 0x44, 0x89, 0xb2, 0x00, 0x2b, 0x03, 0xd1, + 0x06, 0x9a, 0x18, 0x00, 0x11, 0x80, 0xb6, 0xe7, 0x80, 0x23, 0x52, 0x18, + 0x92, 0xb2, 0x62, 0x80, 0x21, 0x80, 0x52, 0x1a, 0x1b, 0x01, 0x9a, 0x42, + 0xbd, 0xdc, 0x76, 0xe7, 0x00, 0x28, 0xaa, 0xdb, 0xa6, 0x60, 0x00, 0xd1, + 0x71, 0xe7, 0xa6, 0xe7, 0x31, 0x49, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xff, 0x7f, 0x00, 0x00, 0xef, 0xd8, 0xff, 0xff, 0x6d, 0x4b, 0x00, 0x00, + 0xf0, 0xb5, 0x85, 0xb0, 0x05, 0x00, 0x03, 0x91, 0x14, 0x00, 0x10, 0x1e, + 0x01, 0xd0, 0xfe, 0xf7, 0x57, 0xf8, 0xeb, 0x6a, 0xae, 0x6a, 0x02, 0x93, + 0x00, 0x2c, 0x07, 0xd0, 0x30, 0x23, 0x02, 0x99, 0x32, 0x1d, 0x4b, 0x43, + 0xf3, 0x18, 0x04, 0x33, 0x93, 0x42, 0x0e, 0xd1, 0x2a, 0x4a, 0x01, 0x23, + 0x01, 0x92, 0x00, 0x22, 0x31, 0x1d, 0x5b, 0x42, 0x00, 0x92, 0x02, 0x9f, + 0x00, 0x9a, 0xba, 0x42, 0x0e, 0xd1, 0x5a, 0x1c, 0x21, 0xd1, 0x25, 0x48, + 0x3b, 0xe0, 0x00, 0x27, 0xd1, 0x5f, 0x00, 0x29, 0x04, 0xd1, 0x91, 0x8c, + 0x01, 0x29, 0x01, 0xd9, 0x01, 0x39, 0x91, 0x84, 0x30, 0x32, 0xe3, 0xe7, + 0x00, 0x22, 0x8f, 0x5e, 0x00, 0x2f, 0x0a, 0xd1, 0x00, 0x2c, 0x02, 0xd0, + 0x0f, 0x6a, 0x87, 0x42, 0x0a, 0xd0, 0x8f, 0x8c, 0x01, 0x9a, 0x97, 0x42, + 0x01, 0xd2, 0x00, 0x9b, 0x01, 0x97, 0x00, 0x9a, 0x30, 0x31, 0x01, 0x32, + 0x00, 0x92, 0xd8, 0xe7, 0x00, 0x9b, 0x30, 0x22, 0x5a, 0x43, 0xb6, 0x18, + 0x00, 0x2c, 0x11, 0xd0, 0x72, 0x6a, 0x82, 0x42, 0x19, 0xd1, 0x31, 0x8d, + 0x00, 0x29, 0x16, 0xd0, 0xb2, 0x89, 0x10, 0x09, 0x28, 0x83, 0x0f, 0x20, + 0x02, 0x40, 0x01, 0x3a, 0xea, 0x61, 0x0c, 0x4a, 0x91, 0x42, 0x08, 0xd8, + 0x04, 0x31, 0x31, 0x85, 0x00, 0x20, 0x01, 0x33, 0xb3, 0x80, 0x03, 0x9b, + 0x1e, 0x60, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x22, 0x52, 0x42, 0x32, 0x85, + 0xf4, 0xe7, 0x04, 0x22, 0x70, 0x62, 0x32, 0x85, 0xf0, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xe9, 0xd8, 0xff, 0xff, 0xfa, 0xff, 0x00, 0x00, + 0x00, 0x29, 0x10, 0xdd, 0x2c, 0x22, 0x83, 0x5e, 0x8b, 0x42, 0x0c, 0xdb, + 0x30, 0x23, 0x4b, 0x43, 0x81, 0x6a, 0x30, 0x3b, 0xc9, 0x18, 0x04, 0x22, + 0x8b, 0x5e, 0x00, 0x2b, 0x05, 0xd0, 0x00, 0x20, 0x88, 0x80, 0xc8, 0x62, + 0x70, 0x47, 0x02, 0x48, 0xfc, 0xe7, 0x02, 0x48, 0xfa, 0xe7, 0xc0, 0x46, + 0xe6, 0xd8, 0xff, 0xff, 0xe8, 0xd8, 0xff, 0xff, 0x10, 0xb5, 0x00, 0x29, + 0x11, 0xdd, 0x2c, 0x24, 0x03, 0x5f, 0x8b, 0x42, 0x0d, 0xdb, 0x30, 0x23, + 0x59, 0x43, 0x83, 0x6a, 0x30, 0x39, 0x59, 0x18, 0x11, 0x60, 0x04, 0x23, + 0xc8, 0x5e, 0x43, 0x42, 0x58, 0x41, 0x03, 0x4b, 0x40, 0x42, 0x18, 0x40, + 0x10, 0xbd, 0x02, 0x48, 0xfc, 0xe7, 0xc0, 0x46, 0xe8, 0xd8, 0xff, 0xff, + 0xe6, 0xd8, 0xff, 0xff, 0x03, 0x7d, 0x00, 0x2b, 0x04, 0xd1, 0x43, 0x75, + 0x83, 0x75, 0x83, 0x61, 0x01, 0x33, 0x03, 0x75, 0x70, 0x47, 0x7f, 0xb5, + 0xc3, 0x68, 0x02, 0xad, 0x04, 0x00, 0x0e, 0x00, 0x02, 0x91, 0x6a, 0x60, + 0x8b, 0x42, 0x03, 0xd1, 0x02, 0x8a, 0xab, 0x88, 0x9a, 0x42, 0x18, 0xd0, + 0x20, 0x00, 0x06, 0x22, 0x29, 0x00, 0x0c, 0x30, 0x01, 0xf0, 0x50, 0xf8, + 0x20, 0x68, 0x00, 0xf0, 0x8e, 0xf9, 0x6b, 0x79, 0x22, 0x7a, 0xe1, 0x79, + 0x00, 0x93, 0x20, 0x68, 0x00, 0x23, 0x00, 0xf0, 0x27, 0xfa, 0x20, 0x68, + 0x29, 0x79, 0x32, 0x00, 0x00, 0xf0, 0x52, 0xf9, 0x20, 0x68, 0x00, 0xf0, + 0x74, 0xf9, 0x7f, 0xbd, 0x70, 0xb5, 0x18, 0x26, 0x04, 0x00, 0xff, 0xf7, + 0xcb, 0xff, 0x33, 0x00, 0x08, 0x21, 0x20, 0x79, 0x0d, 0x4d, 0x43, 0x43, + 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0xc4, 0xfe, 0x33, 0x00, 0x08, 0x21, + 0xa0, 0x79, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0xbc, 0xfe, + 0x08, 0x21, 0x60, 0x79, 0x46, 0x43, 0xad, 0x19, 0x69, 0x56, 0x00, 0xf0, + 0xb5, 0xfe, 0x04, 0x4b, 0x20, 0x00, 0x06, 0xcb, 0xff, 0xf7, 0xb7, 0xff, + 0x70, 0xbd, 0xc0, 0x46, 0x20, 0x82, 0x00, 0x00, 0x34, 0x0c, 0x00, 0x20, + 0x07, 0xb5, 0x43, 0x7d, 0x00, 0x91, 0x01, 0x92, 0x00, 0x2b, 0x07, 0xd0, + 0x9a, 0x07, 0x0a, 0xd5, 0xef, 0xf3, 0x10, 0x83, 0x5a, 0x42, 0x53, 0x41, + 0x83, 0x75, 0x72, 0xb6, 0x00, 0x99, 0x01, 0x9a, 0xff, 0xf7, 0x9f, 0xff, + 0x07, 0xbd, 0xdb, 0x07, 0xf8, 0xd5, 0x83, 0x69, 0x01, 0x4a, 0x9b, 0xb2, + 0x93, 0x60, 0xf3, 0xe7, 0x00, 0x18, 0x00, 0x40, 0x10, 0xb5, 0x00, 0x68, + 0x00, 0xf0, 0x3e, 0xf9, 0x10, 0xbd, 0x00, 0x00, 0x10, 0x4a, 0x11, 0x4b, + 0x11, 0x49, 0x13, 0x60, 0x00, 0x23, 0x53, 0x71, 0x13, 0x71, 0x10, 0x4a, + 0x10, 0x48, 0x11, 0x60, 0x10, 0x49, 0xd3, 0x60, 0x91, 0x80, 0x09, 0x21, + 0x91, 0x71, 0x06, 0x39, 0x53, 0x74, 0x13, 0x74, 0x13, 0x75, 0xd3, 0x71, + 0x11, 0x72, 0x0c, 0x4a, 0x10, 0x60, 0x0c, 0x48, 0xd3, 0x60, 0x90, 0x80, + 0x1b, 0x20, 0x53, 0x74, 0x13, 0x74, 0x13, 0x75, 0x90, 0x71, 0xd3, 0x71, + 0x11, 0x72, 0x70, 0x47, 0x34, 0x0c, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, + 0x7c, 0x0e, 0x00, 0x20, 0xfc, 0x0b, 0x00, 0x20, 0x88, 0x0e, 0x00, 0x20, + 0x0a, 0x08, 0x00, 0x00, 0x18, 0x0c, 0x00, 0x20, 0x1d, 0x1a, 0x00, 0x00, + 0x10, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x05, 0xfb, 0x10, 0xbd, 0xc0, 0x46, + 0x3c, 0x0c, 0x00, 0x20, 0x13, 0xb5, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, + 0x3b, 0xf8, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, 0x37, 0xf8, 0x12, 0x49, + 0x12, 0x48, 0x00, 0xf0, 0x33, 0xf8, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, + 0x2f, 0xf8, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, 0x2b, 0xf8, 0x12, 0x4c, + 0x12, 0x49, 0x20, 0x00, 0x00, 0xf0, 0x26, 0xf8, 0x01, 0x23, 0x01, 0x93, + 0x02, 0x33, 0x00, 0x93, 0x0d, 0x22, 0x0b, 0x33, 0x21, 0x00, 0x0e, 0x48, + 0x00, 0xf0, 0x72, 0xfa, 0x13, 0xbd, 0xc0, 0x46, 0x00, 0x08, 0x00, 0x42, + 0x78, 0x0e, 0x00, 0x20, 0x00, 0x0c, 0x00, 0x42, 0x7c, 0x0e, 0x00, 0x20, + 0x00, 0x10, 0x00, 0x42, 0x80, 0x0e, 0x00, 0x20, 0x00, 0x14, 0x00, 0x42, + 0x84, 0x0e, 0x00, 0x20, 0x00, 0x18, 0x00, 0x42, 0x88, 0x0e, 0x00, 0x20, + 0x8c, 0x0e, 0x00, 0x20, 0x00, 0x1c, 0x00, 0x42, 0x3c, 0x0c, 0x00, 0x20, + 0x01, 0x60, 0x70, 0x47, 0x94, 0x46, 0xf0, 0xb5, 0x9e, 0x1e, 0x72, 0x1e, + 0x96, 0x41, 0x62, 0x46, 0x05, 0x68, 0x92, 0x07, 0x2f, 0x68, 0x36, 0x06, + 0x3a, 0x43, 0x32, 0x43, 0x2a, 0x60, 0x07, 0x25, 0x05, 0xac, 0x24, 0x78, + 0x00, 0x68, 0xa4, 0x01, 0x29, 0x40, 0x21, 0x43, 0x42, 0x68, 0x00, 0x24, + 0x02, 0x2b, 0x00, 0xd0, 0x5c, 0x03, 0x11, 0x43, 0x21, 0x43, 0x41, 0x60, + 0xf0, 0xbd, 0x30, 0xb5, 0xc0, 0x25, 0x03, 0x68, 0xad, 0x03, 0x1c, 0x68, + 0x12, 0x05, 0x2a, 0x40, 0x22, 0x43, 0xc0, 0x24, 0x09, 0x04, 0xa4, 0x02, + 0x21, 0x40, 0x11, 0x43, 0x19, 0x60, 0x03, 0x68, 0x5a, 0x68, 0x14, 0x43, + 0x5c, 0x60, 0x30, 0xbd, 0x01, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, + 0x13, 0x60, 0x03, 0x68, 0x1a, 0x68, 0xd2, 0x07, 0xfc, 0xd4, 0xda, 0x69, + 0xd2, 0x07, 0xf9, 0xd4, 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, 0x11, 0x68, + 0x0b, 0x43, 0x13, 0x60, 0x02, 0x68, 0xd3, 0x69, 0x9b, 0x07, 0xfc, 0xd4, + 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, 0x02, 0xd4, 0x1a, 0x7e, + 0x92, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0x00, 0x22, 0x03, 0x68, 0x5a, 0x83, + 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x40, 0x07, 0xc0, 0x0f, 0x70, 0x47, + 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x09, 0x70, 0x47, 0x80, 0x23, 0x02, 0x68, + 0x5b, 0x42, 0x11, 0x7e, 0x0b, 0x43, 0x13, 0x76, 0x70, 0x47, 0x03, 0x68, + 0x58, 0x8b, 0x80, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, + 0x51, 0x8b, 0x0b, 0x43, 0x53, 0x83, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, + 0xc0, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x8d, 0xc0, 0xb2, + 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, 0xfc, 0xd5, 0x89, 0xb2, + 0x01, 0x20, 0x19, 0x85, 0x70, 0x47, 0x01, 0x22, 0x03, 0x68, 0x9a, 0x75, + 0x70, 0x47, 0x01, 0x22, 0x03, 0x68, 0x1a, 0x75, 0x70, 0x47, 0x00, 0x00, + 0x70, 0xb5, 0x01, 0x26, 0x04, 0x68, 0x4b, 0x08, 0x33, 0x40, 0x31, 0x40, + 0x25, 0x68, 0x09, 0x07, 0x5b, 0x07, 0x0b, 0x43, 0x2b, 0x43, 0x23, 0x60, + 0x04, 0x68, 0x51, 0x00, 0x03, 0x48, 0x00, 0xf0, 0x2d, 0xfe, 0x01, 0x38, + 0xc0, 0xb2, 0x20, 0x73, 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x6c, 0xdc, 0x02, + 0x01, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, 0x03, 0x68, + 0x1a, 0x68, 0xd2, 0x07, 0xfc, 0xd4, 0xda, 0x69, 0xd2, 0x07, 0xf9, 0xd4, + 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, + 0x02, 0x68, 0xd3, 0x69, 0x9b, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, + 0xda, 0x69, 0x92, 0x07, 0xfc, 0xd4, 0x02, 0x21, 0x1a, 0x68, 0x8a, 0x43, + 0x1a, 0x60, 0x70, 0x47, 0x02, 0x68, 0x93, 0x6a, 0x5b, 0x0a, 0x5b, 0x02, + 0x19, 0x43, 0x91, 0x62, 0x03, 0x68, 0x1a, 0x7e, 0x52, 0x07, 0xfc, 0xd5, + 0x98, 0x6a, 0xc0, 0xb2, 0x70, 0x47, 0x00, 0x00, 0x03, 0x68, 0x21, 0x4a, + 0x30, 0xb5, 0x93, 0x42, 0x2f, 0xd0, 0x20, 0x4a, 0x93, 0x42, 0x2f, 0xd0, + 0x1f, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x2f, 0xd0, + 0x1e, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1e, 0x4a, 0x93, 0x42, 0x1f, 0xd1, + 0x0e, 0x23, 0x19, 0x22, 0x01, 0x21, 0x03, 0x25, 0x99, 0x40, 0x1b, 0x48, + 0xc0, 0x24, 0x01, 0x60, 0x99, 0x08, 0x2b, 0x40, 0xab, 0x40, 0xfc, 0x35, + 0x9d, 0x40, 0x89, 0x00, 0x09, 0x18, 0xa4, 0x00, 0x08, 0x59, 0xa8, 0x43, + 0xc0, 0x25, 0x9d, 0x40, 0x2b, 0x00, 0x03, 0x43, 0x0b, 0x51, 0x80, 0x23, + 0xdb, 0x01, 0x1a, 0x43, 0x11, 0x4b, 0x5a, 0x80, 0x5a, 0x78, 0x52, 0xb2, + 0x00, 0x2a, 0xfb, 0xdb, 0x30, 0xbd, 0x09, 0x23, 0x14, 0x22, 0xdd, 0xe7, + 0x0a, 0x23, 0x15, 0x22, 0xda, 0xe7, 0x0b, 0x23, 0x16, 0x22, 0xd7, 0xe7, + 0x0c, 0x23, 0x17, 0x22, 0xd4, 0xe7, 0x0d, 0x23, 0x18, 0x22, 0xd1, 0xe7, + 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, 0x00, 0x10, 0x00, 0x42, + 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, 0x00, 0x1c, 0x00, 0x42, + 0x00, 0xe1, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x40, 0xf8, 0xb5, 0x04, 0x00, + 0x0f, 0x00, 0x16, 0x00, 0x1d, 0x00, 0xff, 0xf7, 0xa5, 0xff, 0x20, 0x00, + 0xff, 0xf7, 0x04, 0xff, 0x1c, 0x21, 0xbb, 0x00, 0x0b, 0x40, 0x71, 0x07, + 0x22, 0x68, 0x09, 0x0c, 0x0b, 0x43, 0x13, 0x60, 0x84, 0x23, 0x22, 0x68, + 0x93, 0x75, 0x01, 0x2f, 0x1a, 0xd1, 0x10, 0x21, 0x01, 0x2e, 0x00, 0xd0, + 0x08, 0x39, 0x0c, 0x4b, 0x69, 0x43, 0x18, 0x68, 0xc0, 0x00, 0x00, 0xf0, + 0x83, 0xfd, 0x07, 0x22, 0x21, 0x68, 0x02, 0x40, 0x8b, 0x89, 0x52, 0x03, + 0xdb, 0x04, 0xdb, 0x0c, 0x13, 0x43, 0x8b, 0x81, 0x22, 0x68, 0x03, 0x04, + 0x90, 0x89, 0xdb, 0x0c, 0x40, 0x0b, 0x40, 0x03, 0x18, 0x43, 0x90, 0x81, + 0xf8, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, 0xf7, 0xb5, 0x06, 0x00, + 0x01, 0x93, 0x08, 0xab, 0x1f, 0x78, 0x0d, 0x00, 0x14, 0x00, 0xff, 0xf7, + 0x3f, 0xff, 0x30, 0x00, 0xff, 0xf7, 0x6a, 0xff, 0xc0, 0x22, 0x24, 0x05, + 0x92, 0x03, 0x14, 0x40, 0xba, 0x07, 0x0c, 0x27, 0x17, 0x43, 0x3c, 0x43, + 0xc0, 0x27, 0x07, 0x22, 0xbf, 0x02, 0x2d, 0x04, 0x33, 0x68, 0x3d, 0x40, + 0x25, 0x43, 0x1d, 0x60, 0x01, 0x9b, 0x31, 0x68, 0x13, 0x40, 0x1a, 0x00, + 0x80, 0x23, 0x9b, 0x02, 0x13, 0x43, 0x4b, 0x60, 0xf7, 0xbd, 0x01, 0x20, + 0x70, 0x47, 0x00, 0x00, 0x10, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, + 0x98, 0x47, 0x10, 0xbd, 0x13, 0x04, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, + 0xd9, 0x69, 0x9a, 0x69, 0x91, 0x42, 0x03, 0xd0, 0xdb, 0x69, 0xc0, 0x18, + 0x00, 0x7d, 0x70, 0x47, 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, 0x10, 0xb5, + 0x04, 0x00, 0x00, 0x69, 0xff, 0xf7, 0x96, 0xfe, 0x22, 0x00, 0x00, 0x23, + 0xfc, 0x32, 0x93, 0x61, 0xd3, 0x61, 0x86, 0x22, 0x92, 0x00, 0xa4, 0x18, + 0x63, 0x60, 0xa3, 0x60, 0x10, 0xbd, 0xf0, 0x20, 0x01, 0x40, 0x30, 0x39, + 0x48, 0x42, 0x48, 0x41, 0x70, 0x47, 0xf0, 0x23, 0x1b, 0x01, 0x19, 0x40, + 0x80, 0x23, 0x06, 0x20, 0x9b, 0x00, 0x99, 0x42, 0x0a, 0xd0, 0x01, 0x33, + 0xff, 0x33, 0x01, 0x30, 0x99, 0x42, 0x05, 0xd0, 0x80, 0x23, 0x02, 0x38, + 0x5b, 0x00, 0x99, 0x42, 0x00, 0xd0, 0x00, 0x20, 0x70, 0x47, 0x0f, 0x20, + 0x01, 0x40, 0x00, 0x20, 0x01, 0x29, 0x03, 0xd0, 0x02, 0x39, 0x48, 0x1e, + 0x81, 0x41, 0x48, 0x1c, 0x70, 0x47, 0x00, 0x00, 0x89, 0x23, 0xf0, 0xb5, + 0x18, 0x26, 0x85, 0xb0, 0x02, 0x91, 0x9b, 0x00, 0x04, 0x00, 0xc0, 0x5c, + 0x33, 0x00, 0x08, 0x21, 0x43, 0x43, 0x32, 0x4d, 0x17, 0x00, 0xeb, 0x18, + 0x59, 0x56, 0x00, 0xf0, 0x31, 0xfc, 0x30, 0x4b, 0x08, 0x21, 0xe0, 0x5c, + 0x33, 0x00, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x28, 0xfc, + 0x2c, 0x4b, 0xe2, 0x5c, 0x03, 0x93, 0x02, 0x2a, 0x09, 0xd1, 0x11, 0x33, + 0xe0, 0x5c, 0xff, 0x28, 0x05, 0xd0, 0x08, 0x21, 0x46, 0x43, 0xae, 0x19, + 0x71, 0x56, 0x00, 0xf0, 0x19, 0xfc, 0x8a, 0x26, 0xb6, 0x00, 0xa0, 0x5d, + 0xff, 0x28, 0x19, 0xd0, 0x01, 0x21, 0x00, 0xf0, 0x99, 0xfb, 0x18, 0x22, + 0xa3, 0x5d, 0x21, 0x49, 0x5a, 0x43, 0xab, 0x56, 0xad, 0x18, 0xdb, 0x01, + 0x58, 0x18, 0x8b, 0x21, 0x89, 0x00, 0x60, 0x50, 0x1d, 0x49, 0x01, 0x22, + 0x5b, 0x18, 0x8c, 0x21, 0x89, 0x00, 0x63, 0x50, 0x69, 0x68, 0x8a, 0x40, + 0x8d, 0x21, 0x89, 0x00, 0x62, 0x50, 0x1a, 0x60, 0x01, 0x22, 0x02, 0x9b, + 0x11, 0x00, 0x20, 0x69, 0xff, 0xf7, 0x0a, 0xff, 0x39, 0x00, 0x20, 0x00, + 0xff, 0xf7, 0x8f, 0xff, 0x39, 0x00, 0x05, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0x9e, 0xff, 0x39, 0x00, 0x06, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x7f, 0xff, + 0x33, 0x00, 0x00, 0x90, 0x29, 0x00, 0x20, 0x69, 0x01, 0x22, 0xff, 0xf7, + 0xd3, 0xfd, 0x0b, 0x4b, 0x20, 0x69, 0xe2, 0x5c, 0x03, 0x9b, 0xe1, 0x5c, + 0xff, 0xf7, 0xe9, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x06, 0xfe, 0x05, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x20, 0x82, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, + 0x27, 0x02, 0x00, 0x00, 0x18, 0x44, 0x00, 0x41, 0x14, 0x44, 0x00, 0x41, + 0x26, 0x02, 0x00, 0x00, 0x80, 0x22, 0x10, 0xb5, 0x04, 0x00, 0x52, 0x00, + 0x00, 0x21, 0x00, 0xf0, 0x32, 0xfd, 0x23, 0x00, 0x00, 0x22, 0xfc, 0x33, + 0x5a, 0x60, 0x20, 0x00, 0x9a, 0x60, 0x10, 0xbd, 0xf7, 0xb5, 0x1d, 0x00, + 0x08, 0xab, 0x1b, 0x78, 0x04, 0x00, 0x00, 0x93, 0x09, 0xab, 0x1b, 0x78, + 0x16, 0x00, 0x01, 0x93, 0x00, 0x23, 0x43, 0x60, 0xfa, 0x23, 0x9b, 0x00, + 0x83, 0x60, 0x11, 0x4b, 0x0f, 0x00, 0x08, 0x33, 0x03, 0x60, 0x14, 0x30, + 0xff, 0xf7, 0xdc, 0xff, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, + 0xd7, 0xff, 0x89, 0x23, 0x6a, 0x46, 0x9b, 0x00, 0x27, 0x61, 0xe6, 0x54, + 0x09, 0x4b, 0x12, 0x78, 0xe5, 0x54, 0x09, 0x4b, 0x20, 0x00, 0xe2, 0x54, + 0x6a, 0x46, 0x08, 0x4b, 0x12, 0x79, 0xe2, 0x54, 0x8a, 0x22, 0x29, 0x3b, + 0xff, 0x3b, 0x92, 0x00, 0xa3, 0x54, 0x10, 0x32, 0xa3, 0x54, 0xfe, 0xbd, + 0x80, 0x85, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, 0x26, 0x02, 0x00, 0x00, + 0x27, 0x02, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, 0x58, 0x68, 0x9b, 0x68, + 0xc0, 0x1a, 0x01, 0xd5, 0x01, 0x30, 0xff, 0x30, 0x70, 0x47, 0x10, 0xb5, + 0x04, 0x00, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0xf0, 0xff, + 0x00, 0x28, 0xf8, 0xd1, 0x20, 0x69, 0xff, 0xf7, 0xa4, 0xfd, 0x10, 0xbd, + 0x10, 0xb5, 0x14, 0x30, 0xff, 0xf7, 0xe6, 0xff, 0x10, 0xbd, 0x03, 0x00, + 0xfc, 0x33, 0x59, 0x68, 0x9a, 0x68, 0x91, 0x42, 0x04, 0xdb, 0x5a, 0x68, + 0x98, 0x68, 0x80, 0x1a, 0xff, 0x30, 0x70, 0x47, 0x98, 0x68, 0x5b, 0x68, + 0xc0, 0x1a, 0x01, 0x38, 0xf9, 0xe7, 0x10, 0xb5, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0xeb, 0xff, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x69, + 0xff, 0xf7, 0x9f, 0xfd, 0x00, 0x28, 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, + 0xaa, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x9c, 0xfd, 0x20, 0x69, 0xff, 0xf7, + 0x84, 0xfd, 0x00, 0x28, 0x20, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x9f, 0xfd, + 0x22, 0x00, 0xfc, 0x32, 0x93, 0x69, 0xd1, 0x69, 0x01, 0x33, 0xdb, 0xb2, + 0x8b, 0x42, 0x03, 0xd0, 0x91, 0x69, 0x61, 0x18, 0x08, 0x75, 0x93, 0x61, + 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, 0x20, 0x00, + 0x14, 0x30, 0xff, 0xf7, 0xc0, 0xff, 0x09, 0x28, 0x06, 0xdc, 0x8b, 0x23, + 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, 0x1a, 0x60, + 0x20, 0x69, 0xff, 0xf7, 0x79, 0xfd, 0x00, 0x28, 0x1a, 0xd0, 0x20, 0x00, + 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0x92, 0xff, 0x00, 0x28, 0x22, 0xd0, + 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x99, 0x68, 0x5a, 0x68, 0x91, 0x42, + 0x18, 0xd0, 0x8e, 0x21, 0x9a, 0x68, 0x49, 0x00, 0xa2, 0x18, 0x51, 0x5c, + 0x9a, 0x68, 0x01, 0x32, 0xd2, 0xb2, 0x9a, 0x60, 0xc9, 0xb2, 0x20, 0x69, + 0xff, 0xf7, 0x65, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x43, 0xfd, 0x00, 0x28, + 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x42, 0xfd, 0x20, 0x69, 0xff, 0xf7, + 0x32, 0xfd, 0x10, 0xbd, 0x01, 0x21, 0x49, 0x42, 0xec, 0xe7, 0x20, 0x69, + 0xff, 0xf7, 0x5f, 0xfd, 0xec, 0xe7, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x00, + 0x00, 0x69, 0x0d, 0x00, 0xff, 0xf7, 0x42, 0xfd, 0x00, 0x28, 0x3e, 0xd1, + 0xff, 0x26, 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x5a, 0x68, 0x99, 0x68, + 0x01, 0x32, 0x32, 0x40, 0x8a, 0x42, 0x23, 0xd1, 0xef, 0xf3, 0x10, 0x83, + 0xdb, 0x07, 0x10, 0xd4, 0x1e, 0x4b, 0x5b, 0x68, 0xdb, 0x05, 0xdb, 0x0d, + 0xed, 0xd0, 0x10, 0x3b, 0x5b, 0xb2, 0x00, 0x2b, 0x10, 0xda, 0x0f, 0x22, + 0x13, 0x40, 0x08, 0x3b, 0x9b, 0x08, 0x19, 0x4a, 0x9b, 0x00, 0x9b, 0x18, + 0x1b, 0x68, 0x20, 0x69, 0xff, 0xf7, 0x1e, 0xfd, 0x00, 0x28, 0xdc, 0xd0, + 0x20, 0x00, 0xff, 0xf7, 0x6a, 0xff, 0xd8, 0xe7, 0x9b, 0x08, 0xc0, 0x33, + 0x12, 0x4a, 0x9b, 0x00, 0x9b, 0x58, 0xf0, 0xe7, 0x5a, 0x68, 0x01, 0x32, + 0x16, 0x40, 0x9a, 0x68, 0x96, 0x42, 0x05, 0xd0, 0x8e, 0x21, 0x5a, 0x68, + 0x49, 0x00, 0xa2, 0x18, 0x55, 0x54, 0x5e, 0x60, 0x20, 0x69, 0xff, 0xf7, + 0x14, 0xfd, 0x01, 0x20, 0x70, 0xbd, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0x1c, 0xff, 0x00, 0x28, 0xb9, 0xd1, 0x29, 0x00, 0x20, 0x69, + 0xff, 0xf7, 0xff, 0xfc, 0xf1, 0xe7, 0xc0, 0x46, 0x00, 0xed, 0x00, 0xe0, + 0x1c, 0xed, 0x00, 0xe0, 0x00, 0xe1, 0x00, 0xe0, 0x03, 0x00, 0x70, 0xb5, + 0xfc, 0x33, 0xd9, 0x69, 0x9a, 0x69, 0x04, 0x00, 0x91, 0x42, 0x1a, 0xd0, + 0xda, 0x69, 0x82, 0x18, 0x15, 0x7d, 0xda, 0x69, 0x01, 0x32, 0xd2, 0xb2, + 0xda, 0x61, 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, + 0x20, 0x00, 0x14, 0x30, 0xff, 0xf7, 0x11, 0xff, 0x0a, 0x28, 0x06, 0xdd, + 0x8c, 0x23, 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, + 0x1a, 0x60, 0x28, 0x00, 0x70, 0xbd, 0x01, 0x25, 0x6d, 0x42, 0xe8, 0xe7, + 0xfe, 0xe7, 0x00, 0x00, 0x03, 0x4b, 0x10, 0xb5, 0x1b, 0x68, 0x00, 0x2b, + 0x00, 0xd0, 0x98, 0x47, 0x10, 0xbd, 0xc0, 0x46, 0x90, 0x0e, 0x00, 0x20, + 0x70, 0xb5, 0x0f, 0x49, 0x0f, 0x4c, 0xa1, 0x42, 0x04, 0xd1, 0x00, 0xf0, + 0x81, 0xf8, 0xfa, 0xf7, 0x27, 0xfe, 0xfe, 0xe7, 0x0c, 0x4d, 0x00, 0x23, + 0x8d, 0x42, 0xf6, 0xd0, 0xca, 0x18, 0xe8, 0x18, 0xa2, 0x42, 0x05, 0xd3, + 0x09, 0x4b, 0x82, 0x42, 0xef, 0xd0, 0x09, 0x49, 0x00, 0x22, 0x04, 0xe0, + 0x00, 0x68, 0x04, 0x33, 0x10, 0x60, 0xf1, 0xe7, 0x04, 0xc3, 0x8b, 0x42, + 0xfc, 0xd3, 0xe4, 0xe7, 0x00, 0x00, 0x00, 0x20, 0x30, 0x00, 0x00, 0x20, + 0xb8, 0x85, 0x00, 0x00, 0x30, 0x00, 0x00, 0x20, 0x98, 0x0e, 0x00, 0x20, + 0x10, 0xb5, 0x00, 0xf0, 0x58, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x00, 0xf0, + 0x49, 0xf8, 0x10, 0xbd, 0xf7, 0xb5, 0x13, 0x48, 0x01, 0x22, 0x84, 0x46, + 0x12, 0x49, 0x13, 0x4c, 0x8e, 0x68, 0x63, 0x68, 0x05, 0x68, 0x9b, 0x0e, + 0x13, 0x40, 0x01, 0x92, 0x88, 0x68, 0x62, 0x68, 0x01, 0x9f, 0x92, 0x0e, + 0x3a, 0x40, 0x67, 0x46, 0x3f, 0x68, 0x93, 0x42, 0x0e, 0xd1, 0xbd, 0x42, + 0x0c, 0xd1, 0x86, 0x42, 0x0a, 0xd3, 0x5b, 0x19, 0xfa, 0x25, 0x48, 0x68, + 0xad, 0x00, 0x86, 0x1b, 0x07, 0x48, 0x6b, 0x43, 0x70, 0x43, 0x00, 0x0d, + 0xc0, 0x18, 0xfe, 0xbd, 0x3d, 0x00, 0x13, 0x00, 0x06, 0x00, 0xe3, 0xe7, + 0x94, 0x0e, 0x00, 0x20, 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, + 0x55, 0x55, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x1e, 0x10, 0xd0, 0xff, 0xf7, + 0xcb, 0xff, 0x05, 0x00, 0x00, 0xf0, 0x1a, 0xf8, 0xff, 0xf7, 0xc6, 0xff, + 0x05, 0x4b, 0x40, 0x1b, 0x98, 0x42, 0xf7, 0xd9, 0xfa, 0x23, 0x01, 0x3c, + 0x9b, 0x00, 0xed, 0x18, 0x00, 0x2c, 0xf3, 0xd1, 0x70, 0xbd, 0xc0, 0x46, + 0xe7, 0x03, 0x00, 0x00, 0x10, 0xb5, 0x03, 0x4a, 0x13, 0x68, 0x01, 0x33, + 0x13, 0x60, 0x00, 0xf0, 0x4d, 0xfa, 0x10, 0xbd, 0x94, 0x0e, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, 0x1e, 0x22, 0x70, 0xb5, + 0x46, 0x48, 0x47, 0x49, 0x43, 0x68, 0x93, 0x43, 0x1c, 0x3a, 0x13, 0x43, + 0x43, 0x60, 0x08, 0x23, 0x8c, 0x69, 0x23, 0x43, 0x8b, 0x61, 0x43, 0x4c, + 0x43, 0x4b, 0x9c, 0x82, 0x9c, 0x8a, 0x14, 0x43, 0x9c, 0x82, 0xdc, 0x68, + 0x14, 0x42, 0xfc, 0xd0, 0x01, 0x24, 0x40, 0x4a, 0x14, 0x70, 0x15, 0x78, + 0x25, 0x42, 0x03, 0xd0, 0x55, 0x78, 0x6d, 0xb2, 0x00, 0x2d, 0xf8, 0xdb, + 0x01, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, + 0x39, 0x4c, 0x54, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, + 0x82, 0x24, 0xe4, 0x01, 0x54, 0x80, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x02, 0x24, 0x9c, 0x84, 0x0e, 0x34, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x31, 0x4c, 0xdc, 0x62, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x9d, 0x8c, 0x2e, 0x4c, 0x2c, 0x43, 0x9c, 0x84, 0x10, 0x24, + 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x02, 0x24, 0x9d, 0x8c, 0x80, 0x26, + 0x2c, 0x43, 0x9c, 0x84, 0x40, 0x24, 0xdd, 0x68, 0x35, 0x42, 0xfc, 0xd0, + 0xdd, 0x68, 0x25, 0x42, 0xf9, 0xd0, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x00, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x21, 0x4c, 0x54, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x1c, 0x6a, 0x1e, 0x4d, 0x2c, 0x40, 0x80, 0x25, 0x1c, 0x62, + 0x1c, 0x6a, 0xac, 0x43, 0x1c, 0x62, 0x03, 0x23, 0x93, 0x60, 0x1b, 0x4b, + 0x53, 0x60, 0x53, 0x78, 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x00, 0x23, + 0xff, 0x24, 0x0b, 0x72, 0x17, 0x4a, 0x4b, 0x72, 0x8b, 0x72, 0xcb, 0x72, + 0x16, 0x4b, 0x1a, 0x60, 0x16, 0x4b, 0x17, 0x4a, 0x1b, 0x68, 0x11, 0x68, + 0x9a, 0x06, 0x5b, 0x01, 0xc9, 0x0e, 0x23, 0x40, 0x52, 0x0f, 0x12, 0x02, + 0x0b, 0x43, 0x13, 0x43, 0x12, 0x4a, 0x13, 0x85, 0x80, 0x23, 0x42, 0x68, + 0x13, 0x43, 0x43, 0x60, 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x00, 0x04, 0x00, 0x40, 0x0c, 0x06, 0x00, 0x00, 0x00, 0x08, 0x00, 0x40, + 0x00, 0x0c, 0x00, 0x40, 0x01, 0x05, 0x01, 0x00, 0xb9, 0x05, 0xff, 0x7d, + 0x04, 0x0a, 0x00, 0x00, 0x00, 0x07, 0x03, 0x00, 0xff, 0xfc, 0xff, 0xff, + 0x03, 0x06, 0x01, 0x00, 0x00, 0x6c, 0xdc, 0x02, 0x00, 0x00, 0x00, 0x20, + 0x24, 0x60, 0x80, 0x00, 0x20, 0x60, 0x80, 0x00, 0x00, 0x40, 0x00, 0x42, + 0xfa, 0x21, 0x31, 0x4b, 0x10, 0xb5, 0x18, 0x68, 0x89, 0x00, 0x00, 0xf0, + 0xd5, 0xf9, 0x2f, 0x4b, 0x01, 0x38, 0x98, 0x42, 0x56, 0xd8, 0x2e, 0x49, + 0x2e, 0x4a, 0x48, 0x60, 0xc0, 0x20, 0x13, 0x6a, 0x00, 0x06, 0x1b, 0x02, + 0x1b, 0x0a, 0x03, 0x43, 0x13, 0x62, 0x00, 0x24, 0x07, 0x23, 0x8c, 0x60, + 0x0b, 0x60, 0x80, 0x21, 0x13, 0x6a, 0x09, 0x06, 0x1b, 0x02, 0x1b, 0x0a, + 0x0b, 0x43, 0x13, 0x62, 0xfc, 0x22, 0x25, 0x4b, 0x19, 0x6a, 0x0a, 0x43, + 0x1a, 0x62, 0xfc, 0x22, 0x19, 0x6a, 0x92, 0x01, 0x0a, 0x43, 0x1a, 0x62, + 0xa0, 0x22, 0x19, 0x6a, 0xd2, 0x02, 0x0a, 0x43, 0x1a, 0x62, 0x20, 0x00, + 0x00, 0x21, 0x01, 0x34, 0x00, 0xf0, 0x76, 0xf8, 0x16, 0x2c, 0xf8, 0xd1, + 0x1b, 0x4b, 0x1c, 0x00, 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, + 0x19, 0x4a, 0x5a, 0x80, 0x19, 0x4b, 0x1a, 0x00, 0x59, 0x7e, 0xc9, 0x09, + 0x01, 0x29, 0xfb, 0xd0, 0xe4, 0x21, 0xc9, 0x00, 0x99, 0x80, 0x3f, 0x21, + 0xd9, 0x70, 0x53, 0x7e, 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0xc0, 0x23, + 0x00, 0x20, 0x5b, 0x01, 0x13, 0x61, 0x90, 0x70, 0x00, 0xf0, 0x24, 0xf8, + 0x63, 0x78, 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x0d, 0x4b, 0x0e, 0x4a, + 0x63, 0x80, 0xd3, 0x79, 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0x41, 0x23, + 0x53, 0x70, 0x10, 0xbd, 0xfe, 0xe7, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, + 0xff, 0xff, 0xff, 0x00, 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, + 0x00, 0x04, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, 0x1e, 0x40, 0x00, 0x00, + 0x00, 0x40, 0x00, 0x42, 0x21, 0x40, 0x00, 0x00, 0x00, 0x48, 0x00, 0x42, + 0x16, 0x4a, 0x00, 0xb5, 0x13, 0x00, 0x51, 0x7e, 0xc9, 0x09, 0x01, 0x29, + 0xfb, 0xd0, 0x01, 0x38, 0x04, 0x28, 0x16, 0xd8, 0x19, 0x69, 0x12, 0x4a, + 0x0a, 0x40, 0x0f, 0x21, 0x1a, 0x61, 0x5a, 0x78, 0x8a, 0x43, 0x00, 0xf0, + 0x47, 0xf9, 0x03, 0x08, 0x06, 0x0b, 0x03, 0x00, 0x11, 0x00, 0x01, 0x22, + 0x0a, 0x43, 0x5a, 0x70, 0x00, 0xbd, 0x11, 0x00, 0x03, 0x22, 0xf9, 0xe7, + 0x11, 0x00, 0x02, 0x22, 0xf6, 0xe7, 0xf0, 0x23, 0x11, 0x69, 0x1b, 0x05, + 0x0b, 0x43, 0x0f, 0x21, 0x13, 0x61, 0x53, 0x78, 0x8b, 0x43, 0x19, 0x00, + 0x02, 0x23, 0x0b, 0x43, 0x53, 0x70, 0xeb, 0xe7, 0x00, 0x40, 0x00, 0x42, + 0xff, 0xff, 0xff, 0xf0, 0x18, 0x23, 0x30, 0xb5, 0x1d, 0x00, 0x04, 0x00, + 0x45, 0x43, 0x08, 0x20, 0x20, 0x4a, 0x55, 0x19, 0x28, 0x56, 0x01, 0x30, + 0x14, 0xd0, 0x03, 0x29, 0x12, 0xd8, 0x08, 0x00, 0x63, 0x43, 0xd1, 0x56, + 0xd3, 0x18, 0x00, 0xf0, 0x15, 0xf9, 0x02, 0x28, 0x0e, 0x1b, 0x58, 0x68, + 0xcb, 0x01, 0x02, 0x21, 0x18, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, + 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x30, 0xbd, 0x58, 0x68, + 0xcb, 0x01, 0x06, 0x21, 0x12, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, + 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x9a, 0x61, 0xf1, 0xe7, + 0x58, 0x68, 0xcb, 0x01, 0x06, 0x21, 0x0c, 0x4a, 0x9b, 0x18, 0x1a, 0x18, + 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x5a, 0x61, + 0xe4, 0xe7, 0x58, 0x68, 0xcb, 0x01, 0x02, 0x21, 0x05, 0x4a, 0x9b, 0x18, + 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x9a, 0x60, + 0xd8, 0xe7, 0xc0, 0x46, 0x20, 0x82, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x18, 0x23, 0xf0, 0xb5, 0x08, 0x24, 0x58, 0x43, 0x11, 0x4a, 0x13, 0x18, + 0x1c, 0x57, 0x01, 0x34, 0x1b, 0xd0, 0x01, 0x26, 0x35, 0x00, 0x5f, 0x68, + 0x83, 0x56, 0xbd, 0x40, 0x0d, 0x4a, 0xdb, 0x01, 0x9a, 0x18, 0x90, 0x68, + 0x05, 0x42, 0x0b, 0xd1, 0x0c, 0x00, 0x60, 0x1e, 0x84, 0x41, 0xd2, 0x19, + 0x40, 0x32, 0x10, 0x78, 0x34, 0x40, 0x03, 0x36, 0xa4, 0x00, 0xb0, 0x43, + 0x20, 0x43, 0x10, 0x70, 0x04, 0x4a, 0x9b, 0x18, 0x00, 0x29, 0x01, 0xd1, + 0x5d, 0x61, 0xf0, 0xbd, 0x9d, 0x61, 0xfc, 0xe7, 0x20, 0x82, 0x00, 0x00, + 0x00, 0x44, 0x00, 0x41, 0x18, 0x22, 0x42, 0x43, 0xf8, 0xb5, 0x2c, 0x4e, + 0x03, 0x00, 0xb2, 0x18, 0x12, 0x7a, 0x52, 0xb2, 0x14, 0x00, 0x01, 0x32, + 0x0e, 0xd0, 0x48, 0x1c, 0x00, 0x24, 0x0c, 0x28, 0x0a, 0xd8, 0x00, 0xf0, + 0x9f, 0xf8, 0x07, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x0b, + 0x0b, 0x0b, 0x0b, 0x00, 0x01, 0x24, 0x64, 0x42, 0x20, 0x00, 0xf8, 0xbd, + 0x09, 0x29, 0x05, 0xd1, 0x00, 0x21, 0x18, 0x00, 0xff, 0xf7, 0x66, 0xff, + 0x00, 0x24, 0xf5, 0xe7, 0x0a, 0x29, 0x01, 0xd1, 0x08, 0x39, 0xf6, 0xe7, + 0x00, 0x24, 0x0b, 0x29, 0xee, 0xd1, 0x0a, 0x39, 0x18, 0x00, 0xff, 0xf7, + 0x59, 0xff, 0xe9, 0xe7, 0x18, 0x22, 0x53, 0x43, 0xf2, 0x18, 0x55, 0x68, + 0x01, 0x20, 0x2c, 0x00, 0xf3, 0x56, 0x13, 0x4a, 0xdb, 0x01, 0x6e, 0x08, + 0x9b, 0x18, 0xc9, 0xb2, 0x04, 0x40, 0x9e, 0x19, 0x00, 0x2c, 0x0d, 0xd0, + 0x0f, 0x24, 0x30, 0x36, 0x32, 0x78, 0x09, 0x01, 0x22, 0x40, 0x11, 0x43, + 0xc9, 0xb2, 0x5b, 0x19, 0x31, 0x70, 0x40, 0x33, 0x1a, 0x78, 0x10, 0x43, + 0x18, 0x70, 0xd3, 0xe7, 0x32, 0x00, 0x0f, 0x27, 0x30, 0x32, 0x16, 0x78, + 0x5b, 0x19, 0xbe, 0x43, 0x31, 0x43, 0x11, 0x70, 0x40, 0x33, 0x1a, 0x78, + 0x10, 0x43, 0x18, 0x70, 0xbe, 0xe7, 0xc0, 0x46, 0x20, 0x82, 0x00, 0x00, + 0x00, 0x44, 0x00, 0x41, 0xf7, 0xb5, 0x06, 0x00, 0x0d, 0x00, 0x0c, 0x00, + 0x8b, 0x18, 0x01, 0x93, 0x01, 0x9b, 0x67, 0x1b, 0x9c, 0x42, 0x07, 0xd0, + 0x33, 0x68, 0x21, 0x78, 0x1b, 0x68, 0x30, 0x00, 0x98, 0x47, 0x01, 0x34, + 0x00, 0x28, 0xf3, 0xd1, 0x38, 0x00, 0xfe, 0xbd, 0x16, 0x4a, 0x10, 0xb5, + 0x13, 0x68, 0x59, 0x1c, 0x26, 0xd0, 0x01, 0x3b, 0x13, 0x60, 0x00, 0x2b, + 0x22, 0xd1, 0x72, 0xb6, 0x12, 0x4b, 0x13, 0x4a, 0x04, 0x33, 0x93, 0x42, + 0x13, 0xd9, 0x12, 0x4a, 0x01, 0x21, 0x10, 0x00, 0x14, 0x7d, 0x0c, 0x42, + 0xfc, 0xd0, 0x20, 0x21, 0x14, 0x8b, 0xff, 0x31, 0x9b, 0x08, 0x5b, 0x00, + 0x21, 0x43, 0x11, 0x83, 0xd3, 0x61, 0x0c, 0x4b, 0x13, 0x80, 0x01, 0x23, + 0x02, 0x7d, 0x1a, 0x42, 0xfc, 0xd0, 0xbf, 0xf3, 0x4f, 0x8f, 0x09, 0x4b, + 0x09, 0x4a, 0xda, 0x60, 0xbf, 0xf3, 0x4f, 0x8f, 0xc0, 0x46, 0xfd, 0xe7, + 0x10, 0xbd, 0xc0, 0x46, 0x04, 0x00, 0x00, 0x20, 0x00, 0x20, 0x00, 0x00, + 0x03, 0x02, 0x00, 0x00, 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, + 0x00, 0xed, 0x00, 0xe0, 0x04, 0x00, 0xfa, 0x05, 0x02, 0xb4, 0x71, 0x46, + 0x49, 0x08, 0x49, 0x00, 0x09, 0x5c, 0x49, 0x00, 0x8e, 0x44, 0x02, 0xbc, + 0x70, 0x47, 0xc0, 0x46, 0x00, 0x22, 0x43, 0x08, 0x8b, 0x42, 0x74, 0xd3, + 0x03, 0x09, 0x8b, 0x42, 0x5f, 0xd3, 0x03, 0x0a, 0x8b, 0x42, 0x44, 0xd3, + 0x03, 0x0b, 0x8b, 0x42, 0x28, 0xd3, 0x03, 0x0c, 0x8b, 0x42, 0x0d, 0xd3, + 0xff, 0x22, 0x09, 0x02, 0x12, 0xba, 0x03, 0x0c, 0x8b, 0x42, 0x02, 0xd3, + 0x12, 0x12, 0x09, 0x02, 0x65, 0xd0, 0x03, 0x0b, 0x8b, 0x42, 0x19, 0xd3, + 0x00, 0xe0, 0x09, 0x0a, 0xc3, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x03, + 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x03, + 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x03, + 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x03, + 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x02, + 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x02, + 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x02, + 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x02, + 0xc0, 0x1a, 0x52, 0x41, 0xcd, 0xd2, 0xc3, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0xcb, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0x8b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0x4b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0x0b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x08, 0x8b, 0x42, 0x01, 0xd3, + 0xcb, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x08, 0x8b, 0x42, 0x01, 0xd3, + 0x8b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x08, 0x8b, 0x42, 0x01, 0xd3, + 0x4b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x41, 0x1a, 0x00, 0xd2, 0x01, 0x46, + 0x52, 0x41, 0x10, 0x46, 0x70, 0x47, 0xff, 0xe7, 0x01, 0xb5, 0x00, 0x20, + 0x00, 0xf0, 0x06, 0xf8, 0x02, 0xbd, 0xc0, 0x46, 0x00, 0x29, 0xf7, 0xd0, + 0x76, 0xe7, 0x70, 0x47, 0x70, 0x47, 0xc0, 0x46, 0x70, 0xb5, 0x00, 0x26, + 0x0c, 0x4d, 0x0d, 0x4c, 0x64, 0x1b, 0xa4, 0x10, 0xa6, 0x42, 0x09, 0xd1, + 0x00, 0x26, 0x00, 0xf0, 0x4f, 0xf8, 0x0a, 0x4d, 0x0a, 0x4c, 0x64, 0x1b, + 0xa4, 0x10, 0xa6, 0x42, 0x05, 0xd1, 0x70, 0xbd, 0xb3, 0x00, 0xeb, 0x58, + 0x98, 0x47, 0x01, 0x36, 0xee, 0xe7, 0xb3, 0x00, 0xeb, 0x58, 0x98, 0x47, + 0x01, 0x36, 0xf2, 0xe7, 0x08, 0x00, 0x00, 0x20, 0x08, 0x00, 0x00, 0x20, + 0x08, 0x00, 0x00, 0x20, 0x24, 0x00, 0x00, 0x20, 0x00, 0x23, 0x10, 0xb5, + 0x9a, 0x42, 0x00, 0xd1, 0x10, 0xbd, 0xcc, 0x5c, 0xc4, 0x54, 0x01, 0x33, + 0xf8, 0xe7, 0x03, 0x00, 0x12, 0x18, 0x93, 0x42, 0x00, 0xd1, 0x70, 0x47, + 0x19, 0x70, 0x01, 0x33, 0xf9, 0xe7, 0x02, 0x78, 0x0b, 0x78, 0x00, 0x2a, + 0x03, 0xd0, 0x01, 0x30, 0x01, 0x31, 0x9a, 0x42, 0xf7, 0xd0, 0xd0, 0x1a, + 0x70, 0x47, 0x00, 0x23, 0xc2, 0x5c, 0x01, 0x33, 0x00, 0x2a, 0xfb, 0xd1, + 0x58, 0x1e, 0x70, 0x47, 0x30, 0xb5, 0x05, 0x00, 0x00, 0x2a, 0x00, 0xd1, + 0x30, 0xbd, 0x0c, 0x78, 0x01, 0x3a, 0x6b, 0x1c, 0x2c, 0x70, 0x01, 0x31, + 0x00, 0x2c, 0x05, 0xd1, 0x9a, 0x18, 0x9a, 0x42, 0xf4, 0xd0, 0x1c, 0x70, + 0x01, 0x33, 0xfa, 0xe7, 0x1d, 0x00, 0xed, 0xe7, 0xf8, 0xb5, 0xc0, 0x46, + 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, 0xf8, 0xb5, 0xc0, 0x46, + 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, 0x55, 0x50, 0x44, 0x41, + 0x54, 0x45, 0x2e, 0x42, 0x49, 0x4e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x10, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, + 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, + 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x04, + 0x00, 0x04, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x01, + 0x00, 0x01, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x13, 0x00, 0x01, 0x01, + 0x01, 0x01, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x05, + 0x00, 0x05, 0x0a, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x05, + 0x01, 0x05, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x02, 0x00, + 0x02, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, + 0x03, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x02, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x03, + 0x01, 0x03, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x11, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0a, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0b, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x05, 0x00, 0x01, 0x00, + 0x01, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x06, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x07, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x85, 0x73, 0x00, 0x00, 0x11, 0x7a, 0x00, 0x00, 0xab, 0x72, 0x00, 0x00, + 0x67, 0x72, 0x00, 0x00, 0x81, 0x72, 0x00, 0x00, 0x39, 0x74, 0x00, 0x00, + 0x49, 0x70, 0x00, 0x00, 0x39, 0x70, 0x00, 0x00, 0xcd, 0x70, 0x00, 0x00, + 0x63, 0x70, 0x00, 0x00, 0x33, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x40, 0x42, 0x0f, 0x00, 0xff, 0xff, 0xff, 0xff, 0xdd, 0x20, 0x00, 0x00, + 0x25, 0x22, 0x00, 0x00, 0x39, 0x22, 0x00, 0x00, 0xa5, 0x23, 0x00, 0x00, + 0x3d, 0x26, 0x00, 0x00, 0x41, 0x6c, 0x00, 0x00, 0xb5, 0x6c, 0x00, 0x00, + 0xb5, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 diff --git a/libraries/SFU/src/boot/mkrfox1200.h b/libraries/SFU/src/boot/mkrfox1200.h new file mode 100644 index 0000000..8007278 --- /dev/null +++ b/libraries/SFU/src/boot/mkrfox1200.h @@ -0,0 +1,2174 @@ + 0x00, 0x80, 0x00, 0x20, 0x9d, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0xf1, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0xa5, 0x6c, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0x30, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xb4, 0x85, 0x00, 0x00, 0x04, 0x4b, 0x10, 0xb5, 0x00, 0x2b, 0x03, 0xd0, + 0x03, 0x49, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x10, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x00, 0x34, 0x00, 0x00, 0x20, 0xb4, 0x85, 0x00, 0x00, + 0xf0, 0xb5, 0x40, 0x4c, 0xa5, 0x44, 0x00, 0xaf, 0x05, 0xf0, 0x02, 0xfb, + 0x05, 0xf0, 0x60, 0xfd, 0x01, 0x20, 0x05, 0xf0, 0x27, 0xfa, 0x3c, 0x48, + 0x00, 0xf0, 0x8c, 0xf9, 0x3b, 0x4c, 0x20, 0x00, 0x00, 0xf0, 0x1c, 0xf9, + 0x00, 0x28, 0x5d, 0xd1, 0x20, 0x00, 0x02, 0xf0, 0x29, 0xfb, 0x00, 0x28, + 0x58, 0xd1, 0x20, 0x00, 0x02, 0xf0, 0x44, 0xf9, 0x0c, 0x20, 0x08, 0x23, + 0x34, 0x4a, 0x21, 0x00, 0x38, 0x18, 0x00, 0xf0, 0x23, 0xf9, 0x20, 0x00, + 0x02, 0xf0, 0x38, 0xf9, 0x05, 0x1e, 0x45, 0xd1, 0x0c, 0x23, 0x01, 0x00, + 0x02, 0x22, 0xf8, 0x18, 0x00, 0xf0, 0x42, 0xf9, 0x80, 0x21, 0x78, 0x60, + 0x09, 0x02, 0x2e, 0x00, 0x88, 0x42, 0x2c, 0xdd, 0x0c, 0x23, 0x2a, 0x00, + 0xf8, 0x18, 0x00, 0xf0, 0x37, 0xf9, 0x28, 0x4a, 0xa0, 0x21, 0x94, 0x46, + 0x7b, 0x68, 0x09, 0x02, 0x63, 0x44, 0x1a, 0x00, 0x25, 0x48, 0xa0, 0x25, + 0x80, 0x26, 0x7b, 0x60, 0x00, 0xf0, 0xd6, 0xf8, 0x2d, 0x02, 0xb6, 0x00, + 0x08, 0x23, 0xf8, 0x18, 0xc1, 0x18, 0x04, 0x33, 0x32, 0x00, 0xf8, 0x18, + 0x00, 0xf0, 0x14, 0xf9, 0x08, 0x22, 0xb9, 0x18, 0x8a, 0x18, 0x33, 0x00, + 0x29, 0x00, 0x1b, 0x48, 0x00, 0xf0, 0x74, 0xf8, 0x80, 0x22, 0x1a, 0x4b, + 0x92, 0x00, 0xeb, 0x18, 0xad, 0x18, 0x7a, 0x68, 0x93, 0x42, 0xe7, 0xdb, + 0x01, 0x26, 0x0c, 0x23, 0xf8, 0x18, 0x00, 0xf0, 0x17, 0xf9, 0x00, 0x2e, + 0x03, 0xd0, 0x10, 0x49, 0x20, 0x00, 0x02, 0xf0, 0x55, 0xfa, 0x20, 0x00, + 0x02, 0xf0, 0xca, 0xf8, 0x0c, 0x23, 0xf8, 0x18, 0x00, 0xf0, 0x14, 0xf9, + 0xa0, 0x23, 0x1b, 0x02, 0x1a, 0x68, 0x82, 0xf3, 0x08, 0x88, 0x0c, 0x4a, + 0x93, 0x60, 0x0c, 0x4b, 0x1b, 0x68, 0x18, 0x47, 0x00, 0x20, 0xbd, 0x46, + 0x85, 0x23, 0x9b, 0x00, 0x9d, 0x44, 0xf0, 0xbd, 0xec, 0xfd, 0xff, 0xff, + 0xf4, 0x0b, 0x00, 0x20, 0x8c, 0x04, 0x00, 0x20, 0x98, 0x7c, 0x00, 0x00, + 0x00, 0x80, 0xff, 0xff, 0x4c, 0x00, 0x00, 0x20, 0x00, 0x62, 0xff, 0xff, + 0x00, 0xed, 0x00, 0xe0, 0x04, 0xa0, 0x00, 0x00, 0x00, 0x22, 0x10, 0xb5, + 0x11, 0x00, 0x02, 0x48, 0x00, 0xf0, 0x1a, 0xf8, 0x10, 0xbd, 0xc0, 0x46, + 0x4c, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x05, 0x4a, 0x05, 0x49, 0x06, 0x48, + 0x00, 0xf0, 0x10, 0xf8, 0x00, 0x22, 0x05, 0x4b, 0x05, 0x49, 0x1a, 0x70, + 0x5a, 0x54, 0x10, 0xbd, 0x01, 0x04, 0x00, 0x00, 0x00, 0x7d, 0x00, 0x00, + 0x68, 0x04, 0x00, 0x20, 0x64, 0x00, 0x00, 0x20, 0x02, 0x04, 0x00, 0x00, + 0x30, 0xb5, 0x09, 0x4d, 0x09, 0x4c, 0xab, 0x68, 0x5b, 0x03, 0x5b, 0x0f, + 0x9b, 0x00, 0x1c, 0x59, 0x04, 0x60, 0xab, 0x68, 0x01, 0x61, 0x9b, 0xb2, + 0x43, 0x60, 0x63, 0x43, 0xa4, 0x00, 0x83, 0x60, 0xc4, 0x60, 0x42, 0x61, + 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, 0x00, 0x82, 0x00, 0x00, + 0xf7, 0xb5, 0x80, 0x26, 0x1a, 0x4d, 0x01, 0x91, 0x6f, 0x68, 0x03, 0x33, + 0x3e, 0x43, 0x9b, 0x08, 0x6e, 0x60, 0x00, 0x2b, 0x2b, 0xd0, 0x17, 0x4e, + 0x2e, 0x80, 0x2e, 0x7d, 0xf1, 0x07, 0xfc, 0xd5, 0x1e, 0x00, 0x07, 0x68, + 0x99, 0x1b, 0xbf, 0x08, 0x8f, 0x42, 0x19, 0xd9, 0x00, 0x2e, 0x17, 0xd0, + 0xff, 0x21, 0x17, 0x78, 0x8c, 0x43, 0x3c, 0x43, 0x0f, 0x49, 0x57, 0x78, + 0x0c, 0x40, 0x3f, 0x02, 0x3c, 0x43, 0x97, 0x78, 0x01, 0x3e, 0x39, 0x04, + 0x0c, 0x4f, 0x27, 0x40, 0xd4, 0x78, 0xbf, 0xb2, 0x0f, 0x43, 0x24, 0x06, + 0x01, 0x99, 0x3c, 0x43, 0x10, 0xc1, 0x01, 0x91, 0x04, 0x32, 0xe0, 0xe7, + 0x07, 0x4b, 0x2b, 0x80, 0x2b, 0x7d, 0xdb, 0x07, 0xfc, 0xd5, 0x33, 0x00, + 0xd1, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x44, 0xa5, 0xff, 0xff, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, 0x04, 0xa5, 0xff, 0xff, + 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, 0x1a, 0x80, 0x1a, 0x7d, + 0xd2, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x16, 0x00, + 0xe3, 0x68, 0x29, 0x00, 0x20, 0x00, 0xb3, 0x42, 0x05, 0xd2, 0xff, 0xf7, + 0xe7, 0xff, 0xe3, 0x68, 0xed, 0x18, 0xf6, 0x1a, 0xf4, 0xe7, 0xff, 0xf7, + 0xe1, 0xff, 0x70, 0xbd, 0x1f, 0xb5, 0x00, 0x21, 0x03, 0x91, 0x90, 0x21, + 0xc9, 0x00, 0x02, 0x91, 0xa1, 0x39, 0xff, 0x39, 0x41, 0x18, 0x98, 0x23, + 0x01, 0x91, 0x02, 0x00, 0x80, 0x21, 0x9b, 0x00, 0x00, 0x91, 0xc3, 0x18, + 0x60, 0x32, 0x02, 0x49, 0x01, 0xf0, 0x9c, 0xff, 0x05, 0xb0, 0x00, 0xbd, + 0x80, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, 0x08, 0x00, 0x11, 0x00, + 0x1a, 0x00, 0x00, 0x23, 0x02, 0xf0, 0x16, 0xf8, 0x01, 0x00, 0x20, 0x00, + 0x00, 0xf0, 0x3a, 0xf8, 0x20, 0x00, 0x10, 0xbd, 0x03, 0x4b, 0x04, 0x4a, + 0x1a, 0x60, 0x04, 0x4a, 0x5a, 0x60, 0x04, 0x4a, 0x9a, 0x60, 0x70, 0x47, + 0x80, 0x04, 0x00, 0x20, 0x01, 0x26, 0x00, 0x00, 0x15, 0x26, 0x00, 0x00, + 0x29, 0x26, 0x00, 0x00, 0x10, 0xb5, 0x0c, 0x00, 0x13, 0x00, 0x00, 0x22, + 0x81, 0x5e, 0x22, 0x00, 0x01, 0x48, 0x02, 0xf0, 0x87, 0xf8, 0x10, 0xbd, + 0x8c, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x0c, 0x00, 0x13, 0x00, 0x00, 0x22, + 0x81, 0x5e, 0x22, 0x00, 0x01, 0x48, 0x02, 0xf0, 0xdd, 0xf8, 0x10, 0xbd, + 0x8c, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x00, 0x23, 0xc1, 0x5e, 0x02, 0x48, + 0x02, 0xf0, 0x9c, 0xf9, 0x10, 0xbd, 0xc0, 0x46, 0x8c, 0x04, 0x00, 0x20, + 0x10, 0xb5, 0x04, 0x00, 0xff, 0xf7, 0xf2, 0xff, 0x20, 0x00, 0x10, 0xbd, + 0x01, 0x80, 0x70, 0x47, 0x10, 0xb5, 0x00, 0x21, 0x40, 0x68, 0x05, 0xf0, + 0x63, 0xfa, 0x10, 0xbd, 0x10, 0xb5, 0x01, 0x21, 0x40, 0x68, 0x05, 0xf0, + 0x5d, 0xfa, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x68, 0x04, 0xf0, + 0xb9, 0xfb, 0x01, 0x21, 0x60, 0x68, 0x05, 0xf0, 0x07, 0xfa, 0x20, 0x00, + 0xff, 0xf7, 0xee, 0xff, 0x10, 0xbd, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x00, + 0xff, 0xf7, 0xe2, 0xff, 0x09, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, + 0xcf, 0xfb, 0x05, 0x21, 0x20, 0x68, 0x04, 0xf0, 0xe7, 0xfb, 0x00, 0x21, + 0x20, 0x68, 0x04, 0xf0, 0xe3, 0xfb, 0x05, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0xd7, 0xff, 0x28, 0x00, 0x70, 0xbd, 0xc0, 0x46, 0xec, 0x0b, 0x00, 0x20, + 0x10, 0xb5, 0xff, 0xf7, 0xe3, 0xff, 0x01, 0x23, 0x18, 0x40, 0x10, 0xbd, + 0xf7, 0xb5, 0x04, 0x00, 0x0e, 0x00, 0x15, 0x00, 0x10, 0x27, 0x01, 0x93, + 0x20, 0x00, 0xff, 0xf7, 0xf1, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x3b, 0x00, + 0x01, 0x3b, 0xfd, 0xd1, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xb4, 0xff, + 0x12, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, 0xa1, 0xfb, 0x03, 0x21, + 0x20, 0x68, 0x04, 0xf0, 0xb9, 0xfb, 0x31, 0x0c, 0xc9, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0xb4, 0xfb, 0x31, 0x0a, 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, + 0xaf, 0xfb, 0xf1, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0xab, 0xfb, 0x01, 0x9b, + 0xee, 0x18, 0xb5, 0x42, 0x06, 0xd0, 0x00, 0x21, 0x20, 0x68, 0x04, 0xf0, + 0xa3, 0xfb, 0x28, 0x70, 0x01, 0x35, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, + 0x95, 0xff, 0xf7, 0xbd, 0xec, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, + 0xff, 0xf7, 0x88, 0xff, 0x06, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, + 0x75, 0xfb, 0x06, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x8d, 0xfb, 0x20, 0x00, + 0xff, 0xf7, 0x82, 0xff, 0x10, 0xbd, 0xc0, 0x46, 0xec, 0x0b, 0x00, 0x20, + 0xf7, 0xb5, 0x04, 0x00, 0x0e, 0x00, 0x15, 0x00, 0x10, 0x27, 0x01, 0x93, + 0x20, 0x00, 0xff, 0xf7, 0xa3, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x3b, 0x00, + 0x01, 0x3b, 0xfd, 0xd1, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xda, 0xff, + 0x20, 0x00, 0xff, 0xf7, 0x63, 0xff, 0x12, 0x4b, 0x20, 0x68, 0x06, 0xcb, + 0x04, 0xf0, 0x50, 0xfb, 0x02, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x68, 0xfb, + 0x31, 0x0c, 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x63, 0xfb, 0x31, 0x0a, + 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x5e, 0xfb, 0xf1, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0x5a, 0xfb, 0x01, 0x9b, 0xee, 0x18, 0xb5, 0x42, 0x05, 0xd0, + 0x29, 0x78, 0x20, 0x68, 0x04, 0xf0, 0x52, 0xfb, 0x01, 0x35, 0xf7, 0xe7, + 0x20, 0x00, 0xff, 0xf7, 0x45, 0xff, 0xf7, 0xbd, 0xec, 0x0b, 0x00, 0x20, + 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x10, 0x26, 0x20, 0x00, 0xff, 0xf7, + 0x69, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x33, 0x00, 0x01, 0x3b, 0xfd, 0xd1, + 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xa0, 0xff, 0x20, 0x00, 0xff, 0xf7, + 0x29, 0xff, 0x0d, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, 0x16, 0xfb, + 0x20, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x2e, 0xfb, 0x29, 0x0c, 0xc9, 0xb2, + 0x20, 0x68, 0x04, 0xf0, 0x29, 0xfb, 0x29, 0x0a, 0xc9, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0x24, 0xfb, 0xe9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x20, 0xfb, + 0x20, 0x00, 0xff, 0xf7, 0x15, 0xff, 0x70, 0xbd, 0xec, 0x0b, 0x00, 0x20, + 0x10, 0xb5, 0x0b, 0x00, 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, 0x40, 0xff, + 0x00, 0x20, 0x10, 0xbd, 0xf4, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x0b, 0x00, + 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, 0x84, 0xff, 0x00, 0x20, 0x10, 0xbd, + 0xf4, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, + 0xb7, 0xff, 0x00, 0x20, 0x10, 0xbd, 0xc0, 0x46, 0xf4, 0x0b, 0x00, 0x20, + 0x05, 0x4b, 0x06, 0x4a, 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, + 0x04, 0x4b, 0x05, 0x4a, 0x1a, 0x60, 0x05, 0x22, 0x5a, 0x60, 0x70, 0x47, + 0xec, 0x0b, 0x00, 0x20, 0x00, 0x1b, 0xb7, 0x00, 0xf4, 0x0b, 0x00, 0x20, + 0xfc, 0x0b, 0x00, 0x20, 0x01, 0x23, 0x8b, 0x40, 0xf7, 0xb5, 0x44, 0x6c, + 0x01, 0x93, 0x01, 0x9d, 0xa3, 0x68, 0x06, 0x00, 0x00, 0x20, 0x2b, 0x42, + 0x1c, 0xd0, 0x8a, 0x25, 0x6d, 0x00, 0x69, 0x43, 0x23, 0x69, 0x5d, 0x18, + 0x82, 0x42, 0x0f, 0xd0, 0x2a, 0x78, 0x57, 0xb2, 0x87, 0x42, 0x0b, 0xdb, + 0x01, 0x27, 0x3a, 0x42, 0x08, 0xd0, 0x0a, 0x00, 0x80, 0x21, 0x28, 0x89, + 0x14, 0x32, 0x9a, 0x18, 0x00, 0x02, 0x73, 0x68, 0x49, 0x00, 0x98, 0x47, + 0xa3, 0x68, 0x01, 0x9a, 0x93, 0x43, 0xa3, 0x60, 0x00, 0x23, 0x2b, 0x70, + 0xfe, 0xbd, 0xc3, 0x68, 0xf0, 0xb5, 0x84, 0x68, 0x02, 0x00, 0x23, 0x40, + 0x18, 0x1e, 0x17, 0xd0, 0x8a, 0x27, 0x00, 0x23, 0x15, 0x78, 0x7f, 0x00, + 0xab, 0x42, 0x01, 0xdb, 0x00, 0x20, 0x0f, 0xe0, 0x01, 0x20, 0x98, 0x40, + 0x04, 0x42, 0x0c, 0xd0, 0x38, 0x00, 0x58, 0x43, 0x16, 0x69, 0x30, 0x18, + 0x06, 0x78, 0x7f, 0x2e, 0x05, 0xd8, 0x06, 0x89, 0x8e, 0x42, 0x02, 0xd1, + 0x53, 0x68, 0x43, 0x60, 0xf0, 0xbd, 0x01, 0x33, 0xe8, 0xe7, 0x82, 0x68, + 0x01, 0x00, 0x30, 0xb5, 0x00, 0x20, 0x53, 0x1c, 0x13, 0xd0, 0x00, 0x23, + 0x01, 0x25, 0x08, 0x78, 0x83, 0x42, 0x01, 0xdb, 0x00, 0x20, 0x0c, 0xe0, + 0x2c, 0x00, 0x9c, 0x40, 0x14, 0x42, 0x09, 0xd1, 0x8a, 0x20, 0x40, 0x00, + 0x58, 0x43, 0x0b, 0x69, 0x22, 0x43, 0x18, 0x18, 0x4b, 0x68, 0x8a, 0x60, + 0x43, 0x60, 0x30, 0xbd, 0x01, 0x33, 0xeb, 0xe7, 0xf8, 0xb5, 0x44, 0x6c, + 0x07, 0x00, 0xe2, 0x68, 0xa3, 0x68, 0x00, 0x20, 0x13, 0x40, 0x9a, 0x42, + 0x0e, 0xd1, 0x23, 0x78, 0x01, 0x21, 0x9c, 0x46, 0x02, 0x00, 0x03, 0x00, + 0x49, 0x42, 0x62, 0x45, 0x07, 0xdb, 0x00, 0x20, 0x4b, 0x1c, 0x03, 0xd0, + 0x01, 0x22, 0x38, 0x00, 0xff, 0xf7, 0x80, 0xff, 0xf8, 0xbd, 0x8a, 0x26, + 0x76, 0x00, 0x56, 0x43, 0x25, 0x69, 0xae, 0x19, 0x70, 0x68, 0x65, 0x68, + 0x2d, 0x1a, 0x9d, 0x42, 0x04, 0xd9, 0x36, 0x78, 0x7f, 0x2e, 0x01, 0xd8, + 0x2b, 0x00, 0x11, 0x00, 0x01, 0x32, 0xe4, 0xe7, 0x10, 0xb5, 0x04, 0x00, + 0x40, 0x6c, 0xff, 0xf7, 0x92, 0xff, 0x00, 0x28, 0x04, 0xd0, 0x41, 0x78, + 0x00, 0x22, 0x20, 0x00, 0xff, 0xf7, 0x62, 0xff, 0x10, 0xbd, 0xf7, 0xb5, + 0x46, 0x6c, 0x1c, 0x00, 0x1b, 0x0a, 0x9b, 0xb2, 0x05, 0x00, 0x0f, 0x00, + 0x30, 0x00, 0x19, 0x00, 0x01, 0x93, 0xff, 0xf7, 0x7e, 0xff, 0x73, 0x68, + 0x01, 0x33, 0x73, 0x60, 0x00, 0x28, 0x10, 0xd0, 0x8a, 0x21, 0x43, 0x60, + 0x43, 0x78, 0x49, 0x00, 0x59, 0x43, 0xe4, 0xb2, 0x14, 0x34, 0x09, 0x19, + 0x34, 0x69, 0x08, 0x9a, 0x61, 0x18, 0x09, 0x98, 0x05, 0xf0, 0x1a, 0xfa, + 0x00, 0x27, 0x38, 0x00, 0xfe, 0xbd, 0x03, 0x23, 0x1f, 0x40, 0x01, 0x2f, + 0x06, 0xd1, 0x2b, 0x68, 0x09, 0x9a, 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, + 0x07, 0x00, 0xf2, 0xe7, 0x28, 0x00, 0xff, 0xf7, 0x99, 0xff, 0x07, 0x00, + 0x68, 0x6c, 0xff, 0xf7, 0x78, 0xff, 0x00, 0x90, 0x00, 0x28, 0x24, 0xd0, + 0x02, 0x23, 0x6a, 0x46, 0x03, 0x70, 0x8a, 0x23, 0x92, 0x88, 0x5b, 0x00, + 0x02, 0x81, 0x42, 0x78, 0x80, 0x21, 0x5a, 0x43, 0x33, 0x69, 0x14, 0x32, + 0x9a, 0x18, 0x20, 0x00, 0xff, 0x23, 0x49, 0x00, 0x98, 0x43, 0x2b, 0x68, + 0x98, 0x47, 0x8a, 0x21, 0x49, 0x00, 0x00, 0x28, 0x00, 0xd0, 0x07, 0x00, + 0x00, 0x9b, 0xe4, 0xb2, 0x5b, 0x78, 0x14, 0x34, 0x59, 0x43, 0x09, 0x19, + 0x34, 0x69, 0x08, 0x9a, 0x61, 0x18, 0x09, 0x98, 0x05, 0xf0, 0xde, 0xf9, + 0xc3, 0xe7, 0x2b, 0x68, 0x09, 0x9a, 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, + 0x00, 0x28, 0xc7, 0xd1, 0xbb, 0xe7, 0xf7, 0xb5, 0x47, 0x6c, 0x01, 0x91, + 0x19, 0x0a, 0x05, 0x00, 0x89, 0xb2, 0x38, 0x00, 0x1c, 0x00, 0xff, 0xf7, + 0x1c, 0xff, 0x06, 0x1e, 0x0c, 0xd0, 0x1c, 0x22, 0x01, 0x9b, 0x1a, 0x40, + 0x18, 0x2a, 0x07, 0xd0, 0x41, 0x78, 0x00, 0x2a, 0x0a, 0xd1, 0x9b, 0x07, + 0x08, 0xd0, 0x28, 0x00, 0xff, 0xf7, 0xe4, 0xfe, 0x6b, 0x68, 0x09, 0x9a, + 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, 0x14, 0xe0, 0x8a, 0x23, 0x5b, 0x00, + 0x59, 0x43, 0xe0, 0xb2, 0x3b, 0x69, 0x14, 0x30, 0x40, 0x18, 0x18, 0x18, + 0x08, 0x9a, 0x09, 0x99, 0x05, 0xf0, 0xaa, 0xf9, 0x02, 0x22, 0x7b, 0x68, + 0x01, 0x33, 0x7b, 0x60, 0x73, 0x60, 0x33, 0x78, 0x13, 0x40, 0x18, 0x1e, + 0xe4, 0xd1, 0xfe, 0xbd, 0xf7, 0xb5, 0x42, 0x6c, 0x94, 0x68, 0xd3, 0x68, + 0x23, 0x40, 0x18, 0x1e, 0x09, 0xd0, 0x13, 0x78, 0x8a, 0x26, 0x01, 0x93, + 0x01, 0x25, 0x00, 0x23, 0x76, 0x00, 0x01, 0x98, 0x98, 0x42, 0x01, 0xdc, + 0x00, 0x20, 0xfe, 0xbd, 0x28, 0x00, 0x98, 0x40, 0x04, 0x42, 0x0b, 0xd0, + 0x30, 0x00, 0x58, 0x43, 0x17, 0x69, 0x38, 0x18, 0x07, 0x78, 0x7f, 0x2f, + 0x04, 0xd9, 0x07, 0x89, 0xbc, 0x46, 0xcf, 0x88, 0xbc, 0x45, 0xee, 0xd0, + 0x01, 0x33, 0xe8, 0xe7, 0x70, 0xb5, 0x0c, 0x1e, 0x0f, 0xd0, 0x30, 0x21, + 0xc5, 0x6a, 0x83, 0x6a, 0x69, 0x43, 0x1a, 0x1d, 0x5b, 0x18, 0x00, 0x21, + 0x04, 0x33, 0x9a, 0x42, 0x06, 0xd1, 0x61, 0x78, 0x00, 0x22, 0xff, 0xf7, + 0x93, 0xfe, 0x00, 0x23, 0x23, 0x81, 0x70, 0xbd, 0x00, 0x26, 0x95, 0x5f, + 0x00, 0x2d, 0x03, 0xd0, 0xd5, 0x69, 0xa5, 0x42, 0x00, 0xd1, 0xd1, 0x61, + 0x30, 0x32, 0xec, 0xe7, 0xf0, 0xb5, 0x47, 0x6c, 0x89, 0xb0, 0x06, 0x00, + 0x00, 0x2f, 0x36, 0xd0, 0x8a, 0x21, 0x80, 0x6c, 0x49, 0x00, 0x14, 0x38, + 0x05, 0xf0, 0xa2, 0xf8, 0x04, 0x1e, 0x2e, 0xd0, 0x00, 0x23, 0x01, 0x21, + 0x01, 0x93, 0x01, 0x9a, 0x01, 0x33, 0x52, 0x00, 0x0a, 0x43, 0x01, 0x92, + 0x9c, 0x42, 0xf8, 0xdc, 0x03, 0xad, 0x08, 0x22, 0x00, 0x21, 0x28, 0x00, + 0x05, 0xf0, 0x49, 0xf9, 0x3b, 0x00, 0x14, 0x33, 0x2b, 0x61, 0x01, 0x23, + 0x5b, 0x42, 0xab, 0x60, 0x01, 0x9b, 0x29, 0x00, 0x14, 0x22, 0x38, 0x00, + 0xeb, 0x60, 0x2c, 0x70, 0x05, 0xf0, 0x32, 0xf9, 0x75, 0x6c, 0x8a, 0x26, + 0x2a, 0x78, 0x76, 0x00, 0x72, 0x43, 0x00, 0x21, 0x28, 0x69, 0x05, 0xf0, + 0x32, 0xf9, 0xab, 0x68, 0xea, 0x68, 0xe4, 0xb2, 0x93, 0x43, 0xab, 0x60, + 0x00, 0x23, 0x9c, 0x42, 0x01, 0xdc, 0x09, 0xb0, 0xf0, 0xbd, 0x32, 0x00, + 0x5a, 0x43, 0x29, 0x69, 0x8a, 0x18, 0x53, 0x70, 0x01, 0x33, 0xf4, 0xe7, + 0xf0, 0xb5, 0x85, 0xb0, 0x06, 0x00, 0x0d, 0x00, 0x14, 0x00, 0x03, 0x93, + 0x00, 0x27, 0x68, 0x2a, 0x06, 0xd9, 0x10, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x05, 0xf0, 0x5a, 0xf8, 0x01, 0x30, 0x87, 0xb2, 0x80, 0x21, 0x0a, 0x9b, + 0x09, 0x02, 0x00, 0x93, 0x29, 0x43, 0x00, 0x23, 0x3a, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0xfa, 0xfa, 0x00, 0x28, 0x11, 0xdb, 0x0a, 0x9b, 0x1d, 0x88, + 0x2d, 0x02, 0x00, 0x2f, 0x0e, 0xd1, 0x23, 0x00, 0x17, 0x33, 0x03, 0x9a, + 0x5b, 0x00, 0x01, 0x92, 0x02, 0x22, 0x5b, 0x19, 0x00, 0x92, 0x15, 0x21, + 0x00, 0x22, 0x30, 0x00, 0xff, 0xf7, 0xb1, 0xfe, 0x05, 0xb0, 0xf0, 0xbd, + 0x23, 0x1d, 0x68, 0x2c, 0xef, 0xd9, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x05, 0xf0, 0xb6, 0xf8, 0x0b, 0x1d, 0xe8, 0xe7, 0x30, 0xb5, 0x0e, 0x25, + 0x00, 0x23, 0x85, 0xb0, 0x6d, 0x44, 0x1a, 0x00, 0x00, 0x95, 0x04, 0x00, + 0x02, 0xf0, 0xd0, 0xfa, 0x0b, 0x4b, 0x98, 0x42, 0x12, 0xd0, 0x00, 0x28, + 0x0e, 0xdb, 0x0d, 0x22, 0xbf, 0x23, 0x6a, 0x44, 0x13, 0x70, 0x2b, 0x88, + 0x01, 0x92, 0x01, 0x22, 0x1b, 0x02, 0x00, 0x92, 0x04, 0x33, 0x00, 0x22, + 0x04, 0x21, 0x20, 0x00, 0xff, 0xf7, 0xeb, 0xfe, 0x05, 0xb0, 0x30, 0xbd, + 0x00, 0x20, 0xfb, 0xe7, 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x8b, 0xb0, + 0x04, 0x93, 0x10, 0xab, 0x1b, 0x88, 0x12, 0x25, 0x05, 0x93, 0x50, 0x4b, + 0x14, 0x00, 0x19, 0x43, 0x0e, 0x23, 0x04, 0xaa, 0x9b, 0x18, 0x19, 0x80, + 0x09, 0xab, 0xad, 0x18, 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x2b, 0x00, + 0x06, 0x00, 0x02, 0xf0, 0x65, 0xfa, 0x00, 0x28, 0x33, 0xdb, 0x09, 0x9b, + 0x2d, 0x88, 0x06, 0x93, 0x68, 0x2c, 0x30, 0xd9, 0x27, 0x00, 0x69, 0x3f, + 0x7c, 0x21, 0x38, 0x00, 0x04, 0xf0, 0xe6, 0xff, 0x01, 0x30, 0x83, 0xb2, + 0x7c, 0x21, 0x38, 0x00, 0x03, 0x93, 0x05, 0xf0, 0x65, 0xf8, 0x09, 0x91, + 0x32, 0x6a, 0x05, 0x9b, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, + 0x1b, 0x02, 0x00, 0x22, 0x15, 0x21, 0x30, 0x00, 0xff, 0xf7, 0x49, 0xfe, + 0x00, 0x28, 0x12, 0xdb, 0x06, 0x9b, 0x37, 0x6a, 0x2d, 0x01, 0xed, 0x18, + 0x04, 0xaa, 0x7b, 0x78, 0x39, 0x78, 0xd2, 0x89, 0x01, 0x35, 0x1b, 0x02, + 0xad, 0xb2, 0x0b, 0x43, 0x9a, 0x42, 0x0a, 0xd0, 0x29, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0x5c, 0xfb, 0x2e, 0x48, 0x0b, 0xb0, 0xf0, 0xbd, 0x00, 0x23, + 0x09, 0x94, 0x03, 0x93, 0xd8, 0xe7, 0xfb, 0x78, 0xba, 0x78, 0x1b, 0x02, + 0x13, 0x43, 0x03, 0x9a, 0x93, 0x42, 0x05, 0xd0, 0x29, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0x4a, 0xfb, 0x26, 0x48, 0xec, 0xe7, 0x38, 0x22, 0x3b, 0x79, + 0x93, 0x43, 0xc0, 0x2b, 0x05, 0xd0, 0x29, 0x00, 0x30, 0x00, 0x02, 0xf0, + 0x3f, 0xfb, 0x22, 0x48, 0xe1, 0xe7, 0x03, 0x9b, 0x00, 0x2b, 0x2a, 0xd1, + 0x6b, 0x46, 0x64, 0x00, 0x1b, 0x8a, 0x3c, 0x19, 0xe3, 0x85, 0x80, 0x22, + 0x52, 0x00, 0x00, 0x92, 0x2b, 0x02, 0x01, 0x97, 0x00, 0x22, 0x07, 0x21, + 0x30, 0x00, 0xff, 0xf7, 0x68, 0xfe, 0x00, 0x28, 0xcd, 0xdb, 0x0f, 0x23, + 0x17, 0x4a, 0x2b, 0x40, 0x9b, 0x18, 0x0e, 0x22, 0x04, 0xa9, 0x52, 0x18, + 0x01, 0x92, 0x02, 0x22, 0x2d, 0x09, 0x5b, 0x00, 0x2d, 0x03, 0x00, 0x92, + 0x5b, 0x19, 0x00, 0x22, 0x04, 0x21, 0x30, 0x00, 0xff, 0xf7, 0x53, 0xfe, + 0x00, 0x28, 0xb8, 0xdb, 0x05, 0x99, 0x30, 0x00, 0x02, 0xf0, 0x10, 0xfb, + 0xb3, 0xe7, 0x68, 0x2c, 0x05, 0xd8, 0x64, 0x00, 0x6b, 0x46, 0x1b, 0x8a, + 0x3c, 0x19, 0x23, 0x81, 0xd1, 0xe7, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x04, 0xf0, 0xea, 0xff, 0x4c, 0x00, 0xf3, 0xe7, 0x00, 0x80, 0xff, 0xff, + 0xbd, 0xd8, 0xff, 0xff, 0xbc, 0xd8, 0xff, 0xff, 0xbb, 0xd8, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x00, 0x24, 0x85, 0xb0, 0x0e, 0x00, + 0x1f, 0x00, 0x11, 0x88, 0x03, 0x93, 0x02, 0x94, 0x01, 0x94, 0x00, 0x94, + 0x23, 0x00, 0x05, 0x00, 0x02, 0xf0, 0x66, 0xfa, 0xa0, 0x42, 0x0a, 0xdb, + 0xfb, 0x21, 0x3a, 0x88, 0x33, 0x02, 0x12, 0x02, 0x00, 0x91, 0x05, 0x33, + 0x05, 0x32, 0x21, 0x00, 0x28, 0x00, 0x01, 0xf0, 0xe3, 0xff, 0x05, 0xb0, + 0xf0, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x93, 0xb0, 0x06, 0x91, 0x01, 0x33, + 0x11, 0x01, 0xcb, 0x18, 0xc4, 0x6c, 0x9b, 0xb2, 0x07, 0x00, 0x05, 0x93, + 0x00, 0x2c, 0x08, 0xd0, 0x10, 0x02, 0xf9, 0x68, 0x04, 0xf0, 0x2a, 0xff, + 0x00, 0x23, 0x02, 0x00, 0x19, 0x00, 0x18, 0x00, 0xa0, 0x47, 0x05, 0x9b, + 0x0e, 0xad, 0x1b, 0x02, 0x08, 0x93, 0x05, 0x23, 0x01, 0x95, 0x00, 0x93, + 0x00, 0x22, 0x08, 0x9b, 0x15, 0x21, 0x38, 0x00, 0xff, 0xf7, 0x8f, 0xfd, + 0x04, 0x1e, 0x00, 0xda, 0xd5, 0xe0, 0x06, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0x81, 0xe0, 0x2b, 0x79, 0x7f, 0x2b, 0x00, 0xd9, 0x86, 0xe0, 0x06, 0x9b, + 0x1c, 0x00, 0x1d, 0x00, 0x04, 0x93, 0x06, 0x9b, 0x83, 0x4a, 0x01, 0x3b, + 0x9b, 0xb2, 0x93, 0x42, 0x00, 0xd9, 0x02, 0xe2, 0x81, 0x48, 0x06, 0x9b, + 0x02, 0x00, 0x0e, 0xae, 0x03, 0x43, 0x9b, 0xb2, 0x31, 0x88, 0x07, 0x93, + 0x33, 0x79, 0x0a, 0x43, 0x09, 0x90, 0x07, 0x98, 0x92, 0xb2, 0x82, 0x42, + 0x00, 0xd1, 0xb2, 0xe1, 0x5a, 0xb2, 0x00, 0x2a, 0x51, 0xda, 0x9a, 0x07, + 0x4f, 0xd4, 0x44, 0x22, 0x13, 0x42, 0x4c, 0xd0, 0x04, 0x25, 0x72, 0x88, + 0x1d, 0x40, 0x00, 0xd1, 0xee, 0xe0, 0x12, 0x23, 0x06, 0xa8, 0x1b, 0x18, + 0x0b, 0xad, 0x00, 0x93, 0x38, 0x00, 0x2b, 0x00, 0xff, 0xf7, 0x74, 0xfe, + 0x6f, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x3a, 0xd0, 0x00, 0x28, 0x00, 0xda, + 0x95, 0xe0, 0x2b, 0x88, 0x05, 0x9a, 0x93, 0x42, 0x33, 0xd1, 0x10, 0xad, + 0x2b, 0x00, 0x32, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0x72, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0x87, 0xe0, 0x12, 0x20, 0x06, 0xac, 0x00, 0x19, + 0x00, 0x88, 0x0e, 0xae, 0x2b, 0x88, 0x72, 0x88, 0x31, 0x88, 0x00, 0x90, + 0x38, 0x00, 0xff, 0xf7, 0xb1, 0xfe, 0x60, 0x4b, 0x04, 0x00, 0xc3, 0x18, + 0x02, 0x2b, 0x16, 0xd8, 0x29, 0x88, 0x38, 0x00, 0x02, 0xf0, 0x50, 0xfa, + 0x04, 0x1e, 0x70, 0xdb, 0x31, 0x88, 0x38, 0x00, 0xff, 0xf7, 0x7e, 0xfe, + 0x01, 0x23, 0xfd, 0x6c, 0x04, 0x00, 0x04, 0x93, 0x00, 0x2d, 0x06, 0xd0, + 0x00, 0x23, 0x32, 0x88, 0x18, 0x00, 0x06, 0x21, 0xa8, 0x47, 0x01, 0x23, + 0x04, 0x93, 0x00, 0x2c, 0x5d, 0xdb, 0xfc, 0x6c, 0x00, 0x2c, 0x04, 0xd0, + 0x00, 0x23, 0x05, 0x9a, 0x05, 0x21, 0x18, 0x00, 0xa0, 0x47, 0x05, 0x99, + 0x38, 0x00, 0x02, 0xf0, 0x2f, 0xfa, 0x04, 0x00, 0x92, 0xe1, 0x4b, 0x4b, + 0x06, 0x9a, 0x9a, 0x42, 0x00, 0xd0, 0x82, 0xe0, 0x2b, 0x79, 0xdb, 0x07, + 0x00, 0xd5, 0x7e, 0xe0, 0x04, 0x23, 0x2e, 0x79, 0x29, 0x88, 0x6a, 0x88, + 0x1e, 0x40, 0x4b, 0xd0, 0x06, 0xa8, 0x0e, 0x33, 0x1b, 0x18, 0x0b, 0xae, + 0x00, 0x93, 0x38, 0x00, 0x33, 0x00, 0xff, 0xf7, 0x0f, 0xfe, 0x3d, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x00, 0xd1, 0x6c, 0xe0, 0x00, 0x28, 0x30, 0xdb, + 0x33, 0x88, 0x05, 0x9a, 0x93, 0x42, 0x00, 0xd0, 0x60, 0xe0, 0x10, 0xae, + 0x33, 0x00, 0x2a, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0x0c, 0xff, + 0x04, 0x1e, 0x22, 0xdb, 0x06, 0xa8, 0x40, 0x8a, 0x33, 0x88, 0x6a, 0x88, + 0x29, 0x88, 0x00, 0x90, 0x38, 0x00, 0xff, 0xf7, 0x4f, 0xfe, 0x2f, 0x4b, + 0x04, 0x00, 0xc3, 0x18, 0x02, 0x2b, 0x17, 0xd8, 0x31, 0x88, 0x38, 0x00, + 0x02, 0xf0, 0xee, 0xf9, 0x04, 0x1e, 0x0e, 0xdb, 0x29, 0x88, 0x38, 0x00, + 0xff, 0xf7, 0x1c, 0xfe, 0xfe, 0x6c, 0x04, 0x00, 0x00, 0x2e, 0x04, 0xd0, + 0x00, 0x23, 0x06, 0x21, 0x18, 0x00, 0x2a, 0x88, 0xb0, 0x47, 0x00, 0x2c, + 0x34, 0xda, 0x20, 0x00, 0x13, 0xb0, 0xf0, 0xbd, 0xfe, 0x6c, 0x00, 0x2e, + 0xf7, 0xd0, 0x6b, 0x88, 0x2a, 0x88, 0x02, 0x21, 0x00, 0x20, 0xf1, 0xe7, + 0x1a, 0x4b, 0x00, 0x96, 0x19, 0x43, 0x89, 0xb2, 0x05, 0x9b, 0x38, 0x00, + 0x02, 0xf0, 0xd8, 0xf8, 0x17, 0x4b, 0x04, 0x00, 0x98, 0x42, 0xe6, 0xd1, + 0x29, 0x88, 0x14, 0x4b, 0x00, 0x96, 0x0b, 0x43, 0x99, 0xb2, 0x32, 0x00, + 0x33, 0x00, 0x38, 0x00, 0x02, 0xf0, 0x02, 0xf9, 0x04, 0x1e, 0x11, 0xd1, + 0x10, 0xab, 0x2a, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0xbe, 0xfe, + 0x04, 0x1e, 0xd4, 0xdb, 0xfb, 0x6c, 0x9c, 0x46, 0x00, 0x2b, 0x05, 0xd0, + 0x6b, 0x88, 0x2a, 0x88, 0x03, 0x21, 0x30, 0x00, 0x65, 0x46, 0xa8, 0x47, + 0x01, 0x23, 0x04, 0x93, 0x04, 0xe0, 0x00, 0x23, 0xf8, 0xe6, 0x01, 0x23, + 0x00, 0x24, 0x04, 0x93, 0x1d, 0x00, 0xf6, 0xe6, 0xfd, 0xff, 0x00, 0x00, + 0x00, 0x80, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, + 0xff, 0xff, 0x00, 0x00, 0x16, 0x26, 0x06, 0xab, 0xf6, 0x18, 0x00, 0x96, + 0x2b, 0x00, 0x07, 0x99, 0x38, 0x00, 0x02, 0xf0, 0x99, 0xf8, 0xc1, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x00, 0xd0, 0x75, 0xe0, 0x35, 0x80, 0x0e, 0xae, + 0x31, 0x88, 0x09, 0x9b, 0x0c, 0xad, 0x19, 0x43, 0x72, 0x88, 0x00, 0x23, + 0x89, 0xb2, 0x00, 0x95, 0x38, 0x00, 0x02, 0xf0, 0x87, 0xf8, 0xb8, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x68, 0xd1, 0x00, 0x23, 0x2b, 0x80, 0x2b, 0x88, + 0x00, 0x2b, 0x06, 0xd0, 0x16, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0x00, 0x2b, 0x00, 0xd0, 0x2d, 0xe7, 0x06, 0x9b, 0x06, 0xaa, 0x59, 0x04, + 0x1a, 0x23, 0x9b, 0x18, 0x00, 0x93, 0x00, 0x23, 0x49, 0x0c, 0x1a, 0x00, + 0x38, 0x00, 0x02, 0xf0, 0x6b, 0xf8, 0xaa, 0x4b, 0x04, 0x00, 0x98, 0x42, + 0x4f, 0xd1, 0x16, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x00, 0x22, 0x1a, 0x80, + 0x00, 0x23, 0x31, 0x88, 0x0d, 0xad, 0x49, 0x04, 0x1a, 0x00, 0x49, 0x0c, + 0x00, 0x95, 0x38, 0x00, 0x02, 0xf0, 0x58, 0xf8, 0xa0, 0x4b, 0x04, 0x00, + 0x98, 0x42, 0x3f, 0xd1, 0x00, 0x22, 0x0c, 0xab, 0x1a, 0x80, 0xf8, 0x23, + 0x16, 0x21, 0x10, 0xaa, 0x06, 0xa8, 0x13, 0x71, 0x09, 0x18, 0x73, 0x88, + 0x08, 0x88, 0x53, 0x80, 0x00, 0x28, 0x05, 0xd0, 0x1a, 0x21, 0x06, 0xac, + 0x09, 0x19, 0x09, 0x88, 0x00, 0x29, 0x2e, 0xd0, 0x29, 0x88, 0x00, 0x29, + 0x2b, 0xd0, 0x0c, 0xa9, 0x09, 0x88, 0x06, 0x91, 0x00, 0x29, 0x26, 0xd1, + 0x33, 0x88, 0x09, 0x99, 0x38, 0x00, 0x19, 0x43, 0x1e, 0x23, 0x11, 0x80, + 0x06, 0xa9, 0x5b, 0x18, 0x05, 0x99, 0xff, 0xf7, 0x29, 0xfe, 0xfd, 0x6c, + 0x04, 0x00, 0x00, 0x2d, 0x04, 0xd0, 0x73, 0x88, 0x32, 0x88, 0x03, 0x21, + 0x06, 0x98, 0xa8, 0x47, 0x00, 0x2c, 0x00, 0xda, 0x35, 0xe7, 0x01, 0x23, + 0x04, 0x93, 0xd4, 0xe6, 0x00, 0x28, 0x00, 0xdb, 0x87, 0xe7, 0x2e, 0xe7, + 0x00, 0x28, 0x96, 0xda, 0x2b, 0xe7, 0x00, 0x28, 0xb2, 0xda, 0x28, 0xe7, + 0x00, 0x28, 0xc0, 0xda, 0x25, 0xe7, 0x0c, 0xaa, 0x12, 0x88, 0x00, 0x2a, + 0x03, 0xd0, 0x2a, 0x88, 0x00, 0x2a, 0x00, 0xd1, 0xbf, 0xe6, 0x1a, 0x22, + 0x06, 0xa9, 0x52, 0x18, 0x12, 0x88, 0x00, 0x2a, 0x00, 0xd1, 0xb8, 0xe6, + 0x00, 0x28, 0x00, 0xd0, 0xb5, 0xe6, 0x6a, 0x46, 0xfd, 0x6c, 0x92, 0x8b, + 0x10, 0xac, 0x22, 0x80, 0x00, 0x2d, 0x02, 0xd0, 0x32, 0x88, 0x03, 0x21, + 0xa8, 0x47, 0x1e, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x05, 0x99, 0x22, 0x00, + 0x38, 0x00, 0xff, 0xf7, 0xe9, 0xfd, 0x04, 0x00, 0xc6, 0xe7, 0x69, 0x46, + 0x04, 0x22, 0x18, 0x20, 0x09, 0x5e, 0x1a, 0x40, 0x00, 0x29, 0x44, 0xda, + 0x00, 0x2a, 0x44, 0xd1, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0x94, 0xe6, + 0x9b, 0x07, 0x30, 0xd5, 0x12, 0x23, 0x06, 0xa9, 0x5b, 0x18, 0x0e, 0xae, + 0x72, 0x88, 0x06, 0x99, 0x00, 0x93, 0x38, 0x00, 0x0b, 0xab, 0xff, 0xf7, + 0xbd, 0xfc, 0x5d, 0x4b, 0x04, 0x00, 0x98, 0x42, 0xab, 0xd0, 0x00, 0x28, + 0x00, 0xda, 0xde, 0xe6, 0x01, 0x22, 0x06, 0xab, 0x04, 0x92, 0x9b, 0x8a, + 0x05, 0x9a, 0x93, 0x42, 0x00, 0xd0, 0x78, 0xe6, 0xfc, 0x6c, 0x00, 0x2c, + 0x04, 0xd0, 0x73, 0x88, 0x32, 0x88, 0x03, 0x21, 0x00, 0x20, 0xa0, 0x47, + 0xfd, 0x23, 0x01, 0x26, 0x10, 0xaa, 0x13, 0x70, 0x08, 0x9b, 0x01, 0x92, + 0x04, 0x33, 0x00, 0x96, 0x00, 0x22, 0x07, 0x21, 0x38, 0x00, 0xff, 0xf7, + 0xdc, 0xfb, 0x04, 0x00, 0x04, 0x96, 0x00, 0x2d, 0x00, 0xd0, 0x5e, 0xe6, + 0x00, 0x2c, 0x00, 0xd0, 0xb9, 0xe6, 0x04, 0x9c, 0x47, 0x4b, 0x67, 0x42, + 0x7c, 0x41, 0xe4, 0x18, 0xb3, 0xe6, 0x00, 0x2a, 0xba, 0xd1, 0x1a, 0x26, + 0x06, 0x9b, 0x0e, 0xad, 0x5b, 0x04, 0x5b, 0x0c, 0x09, 0x93, 0x06, 0xab, + 0xf6, 0x18, 0x6a, 0x88, 0x05, 0x9b, 0x00, 0x96, 0x09, 0x99, 0x38, 0x00, + 0x01, 0xf0, 0x8e, 0xff, 0x3b, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x4c, 0xd1, + 0x00, 0x23, 0x33, 0x80, 0x6a, 0x88, 0x0d, 0xad, 0x05, 0x9b, 0x00, 0x95, + 0x07, 0x99, 0x38, 0x00, 0x01, 0xf0, 0x80, 0xff, 0x34, 0x4b, 0x04, 0x00, + 0x98, 0x42, 0x41, 0xd1, 0x00, 0x23, 0x2b, 0x80, 0x1a, 0x23, 0x06, 0xaa, + 0x9b, 0x18, 0x28, 0x88, 0x1d, 0x88, 0xfc, 0x6c, 0x00, 0x2d, 0x3a, 0xd0, + 0x00, 0x28, 0x00, 0xd0, 0x25, 0xe6, 0x00, 0x2c, 0x04, 0xd0, 0x0e, 0xab, + 0x5b, 0x88, 0x06, 0x9a, 0x02, 0x21, 0xa0, 0x47, 0xf8, 0x23, 0x10, 0xaa, + 0x13, 0x71, 0x6b, 0x46, 0x1e, 0x26, 0x9b, 0x8b, 0x00, 0x25, 0x13, 0x80, + 0x0e, 0xab, 0x5b, 0x88, 0x07, 0x99, 0x53, 0x80, 0x06, 0xab, 0xf6, 0x18, + 0x01, 0x23, 0x02, 0x93, 0x2b, 0x00, 0x03, 0x96, 0x01, 0x95, 0x00, 0x95, + 0x38, 0x00, 0x01, 0xf0, 0xc1, 0xff, 0x04, 0x00, 0xa8, 0x42, 0x00, 0xda, + 0x61, 0xe6, 0xfb, 0x21, 0x32, 0x88, 0x08, 0x9b, 0x12, 0x02, 0x00, 0x91, + 0x05, 0x33, 0x05, 0x32, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, 0x3c, 0xfd, + 0x04, 0x00, 0xa8, 0x42, 0x00, 0xdb, 0xf4, 0xe5, 0x51, 0xe6, 0x00, 0x28, + 0xb2, 0xda, 0x4e, 0xe6, 0x00, 0x28, 0xbd, 0xda, 0x4b, 0xe6, 0x00, 0x28, + 0x00, 0xd1, 0xea, 0xe5, 0x0e, 0xab, 0x5b, 0x88, 0x00, 0x2c, 0x03, 0xd0, + 0x06, 0x9a, 0x03, 0x21, 0x28, 0x00, 0xa0, 0x47, 0xfc, 0x23, 0x10, 0xaa, + 0x13, 0x71, 0x6b, 0x46, 0x1e, 0x26, 0x9b, 0x8c, 0x00, 0x25, 0x13, 0x80, + 0x0e, 0xab, 0x5b, 0x88, 0x09, 0x99, 0x53, 0x80, 0x06, 0xab, 0xf6, 0x18, + 0x01, 0x23, 0x03, 0x96, 0x02, 0x93, 0x01, 0x95, 0x00, 0x95, 0x2b, 0x00, + 0xc2, 0xe7, 0xc0, 0x46, 0xee, 0xd8, 0xff, 0xff, 0xa9, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x8b, 0xb0, 0x05, 0x93, 0xc7, 0x6c, 0x43, 0x6a, 0x04, 0x00, + 0x03, 0x91, 0x16, 0x00, 0x11, 0x9d, 0x04, 0x93, 0x00, 0x2f, 0x08, 0xd0, + 0x10, 0x02, 0xe1, 0x68, 0x04, 0xf0, 0x56, 0xfc, 0x00, 0x23, 0x02, 0x00, + 0x19, 0x00, 0x01, 0x20, 0xb8, 0x47, 0x03, 0x9b, 0x4f, 0x49, 0x50, 0x4a, + 0x5b, 0x18, 0x9b, 0xb2, 0x93, 0x42, 0x00, 0xd9, 0x94, 0xe0, 0x05, 0x22, + 0x05, 0x9b, 0x36, 0x01, 0x01, 0x33, 0xf6, 0x18, 0xb7, 0xb2, 0x08, 0xae, + 0x00, 0x92, 0x3b, 0x02, 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, + 0xff, 0xf7, 0xb1, 0xfa, 0x00, 0x28, 0x16, 0xdb, 0x39, 0x22, 0x33, 0x79, + 0x93, 0x43, 0x72, 0x88, 0x00, 0x2a, 0x12, 0xd1, 0x80, 0x2b, 0x6e, 0xd1, + 0xe5, 0x6c, 0x00, 0x2d, 0x04, 0xd0, 0x03, 0x9b, 0x3a, 0x00, 0x05, 0x21, + 0x01, 0x20, 0xa8, 0x47, 0x39, 0x00, 0x20, 0x00, 0x01, 0xf0, 0xc2, 0xff, + 0x00, 0x28, 0x00, 0xdb, 0x3a, 0x48, 0x05, 0x00, 0x6b, 0xe0, 0xc0, 0x2b, + 0xfa, 0xd0, 0x03, 0x9b, 0x38, 0x4a, 0x5e, 0x04, 0x94, 0x46, 0x00, 0x23, + 0x60, 0x6a, 0x76, 0x0c, 0x61, 0x46, 0xc2, 0x5a, 0x0a, 0x40, 0xb2, 0x42, + 0x12, 0xd1, 0x04, 0x9a, 0xd3, 0x5e, 0x00, 0x2b, 0x58, 0xda, 0x30, 0x4d, + 0x36, 0xe0, 0x02, 0x33, 0x9c, 0x42, 0x4f, 0xd1, 0x2b, 0x68, 0x04, 0x98, + 0x59, 0x00, 0x01, 0x33, 0x0a, 0x52, 0x7f, 0x2b, 0x00, 0xd9, 0x00, 0x23, + 0x2b, 0x60, 0x49, 0xe0, 0x80, 0x22, 0x02, 0x33, 0x52, 0x00, 0x93, 0x42, + 0xe2, 0xd1, 0x0e, 0x23, 0x04, 0xaa, 0x9b, 0x18, 0x00, 0x93, 0x00, 0x23, + 0x03, 0x99, 0x1a, 0x00, 0x20, 0x00, 0x01, 0xf0, 0x9b, 0xfe, 0x00, 0x28, + 0x0a, 0xd0, 0x22, 0x4b, 0x98, 0x42, 0x24, 0xd1, 0x69, 0x46, 0x2b, 0x68, + 0x04, 0x9a, 0x89, 0x89, 0x5b, 0x00, 0x99, 0x52, 0x01, 0x22, 0x04, 0xe0, + 0x2b, 0x68, 0x04, 0x9a, 0x5b, 0x00, 0x9e, 0x52, 0x02, 0x00, 0x2b, 0x68, + 0x01, 0x33, 0x7f, 0x2b, 0x00, 0xd9, 0x00, 0x23, 0x2b, 0x60, 0x18, 0x4d, + 0x00, 0x2a, 0x20, 0xd0, 0xe6, 0x6c, 0x00, 0x2e, 0x04, 0xd0, 0x03, 0x9b, + 0x3a, 0x00, 0x04, 0x21, 0x01, 0x20, 0xb0, 0x47, 0x39, 0x00, 0x20, 0x00, + 0x01, 0xf0, 0x66, 0xff, 0x00, 0x28, 0x12, 0xda, 0xa3, 0xe7, 0x00, 0x22, + 0x90, 0x42, 0xe4, 0xda, 0x9f, 0xe7, 0xc0, 0x2b, 0x9c, 0xd0, 0x03, 0x9b, + 0x09, 0x48, 0x5a, 0x04, 0x63, 0x6a, 0x52, 0x0c, 0x5c, 0x1c, 0xff, 0x34, + 0x19, 0x88, 0x01, 0x40, 0x91, 0x42, 0xa8, 0xd1, 0x03, 0x4d, 0x28, 0x00, + 0x0b, 0xb0, 0xf0, 0xbd, 0x00, 0x80, 0xff, 0xff, 0xfe, 0x7f, 0x00, 0x00, + 0xaa, 0xd8, 0xff, 0xff, 0xff, 0x7f, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xa9, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0xc4, 0x6c, 0x87, 0xb0, 0x06, 0x00, + 0x00, 0x2c, 0x04, 0xd0, 0x00, 0x23, 0x1a, 0x00, 0x19, 0x00, 0x18, 0x00, + 0xa0, 0x47, 0x00, 0x24, 0x14, 0x4b, 0x05, 0x94, 0x01, 0x93, 0x04, 0x94, + 0x23, 0x00, 0x03, 0x94, 0x02, 0x94, 0x00, 0x94, 0x22, 0x00, 0x21, 0x00, + 0x30, 0x00, 0x01, 0xf0, 0x5b, 0xfc, 0x0f, 0x4b, 0x05, 0x00, 0x98, 0x42, + 0x15, 0xd0, 0xa0, 0x42, 0x07, 0xd0, 0xf7, 0x6c, 0xa7, 0x42, 0x04, 0xd0, + 0x02, 0x00, 0x23, 0x00, 0x01, 0x21, 0x20, 0x00, 0xb8, 0x47, 0xf4, 0x6c, + 0x00, 0x2c, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, 0x19, 0x00, 0x52, 0x00, + 0x18, 0x00, 0xa0, 0x47, 0x28, 0x00, 0x07, 0xb0, 0xf0, 0xbd, 0x25, 0x00, + 0xf1, 0xe7, 0xc0, 0x46, 0x41, 0x2c, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0xc4, 0x6c, 0x97, 0xb0, 0x05, 0x00, 0x00, 0x2c, 0x04, 0xd0, + 0x00, 0x23, 0x02, 0x20, 0x1a, 0x00, 0x19, 0x00, 0xa0, 0x47, 0x00, 0x23, + 0x07, 0x93, 0x1c, 0x00, 0xb0, 0xe1, 0x80, 0x22, 0x00, 0x21, 0x52, 0x00, + 0x68, 0x6a, 0x04, 0xf0, 0x0e, 0xfc, 0x07, 0x9b, 0x1b, 0x02, 0x0f, 0x93, + 0x00, 0x23, 0x0a, 0x93, 0xee, 0x68, 0x0a, 0x9b, 0x9e, 0x42, 0x09, 0xd8, + 0x00, 0x23, 0x06, 0x93, 0x06, 0x9b, 0x07, 0x9a, 0x5b, 0x00, 0xd3, 0x18, + 0x9b, 0xb2, 0x0a, 0x93, 0x00, 0x23, 0x0a, 0xe2, 0xeb, 0x6c, 0x05, 0x93, + 0x00, 0x2b, 0x13, 0xd0, 0x0a, 0x9b, 0x37, 0x01, 0x58, 0x04, 0x39, 0x00, + 0x04, 0xf0, 0x38, 0xfb, 0x31, 0x00, 0x04, 0xf0, 0x35, 0xfb, 0x39, 0x00, + 0x06, 0x00, 0x0f, 0x98, 0x04, 0xf0, 0x30, 0xfb, 0x00, 0x23, 0x32, 0x18, + 0x19, 0x00, 0x02, 0x20, 0x05, 0x9e, 0xb0, 0x47, 0x0a, 0x9b, 0x1b, 0x01, + 0x01, 0x33, 0x9b, 0xb2, 0x06, 0x93, 0x0a, 0x9b, 0x01, 0x33, 0x1b, 0x01, + 0x0e, 0x93, 0x06, 0x9b, 0x0e, 0x9a, 0x93, 0x42, 0x01, 0xdb, 0x00, 0x23, + 0x69, 0xe1, 0x06, 0x9b, 0x00, 0x22, 0x1e, 0x02, 0x12, 0xab, 0x01, 0x93, + 0x05, 0x23, 0x15, 0x21, 0x00, 0x93, 0x28, 0x00, 0x33, 0x00, 0xff, 0xf7, + 0x86, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0xe5, 0xe0, 0x07, 0x9b, 0x06, 0x99, + 0x00, 0x22, 0x8b, 0x42, 0x07, 0xd8, 0xca, 0x0f, 0x07, 0x9b, 0xc6, 0x49, + 0x06, 0x98, 0x5b, 0x18, 0xd9, 0x17, 0x83, 0x42, 0x4a, 0x41, 0x06, 0x9b, + 0x07, 0x99, 0x58, 0x1a, 0x01, 0x21, 0x43, 0x08, 0x05, 0x93, 0x06, 0x9b, + 0x19, 0x40, 0x89, 0x00, 0x00, 0x2a, 0x0f, 0xd0, 0x12, 0xab, 0x1b, 0x79, + 0x5f, 0xb2, 0x00, 0x2f, 0x0a, 0xda, 0x01, 0x20, 0x03, 0x42, 0x07, 0xd1, + 0x6b, 0x6a, 0x05, 0x98, 0x1b, 0x18, 0x01, 0x20, 0x88, 0x40, 0x1f, 0x78, + 0x07, 0x43, 0x1f, 0x70, 0x12, 0xab, 0x1f, 0x79, 0x7b, 0xb2, 0x9c, 0x46, + 0x00, 0x23, 0x60, 0x46, 0x98, 0x42, 0x00, 0xdb, 0x22, 0xe1, 0x45, 0x20, + 0x07, 0x40, 0x40, 0x2f, 0x00, 0xd0, 0x1d, 0xe1, 0x9a, 0x42, 0x08, 0xd0, + 0x6b, 0x6a, 0x05, 0x9a, 0x02, 0x31, 0x98, 0x18, 0x01, 0x23, 0x8b, 0x40, + 0x02, 0x78, 0x13, 0x43, 0x03, 0x70, 0x2b, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x15, 0x21, 0x33, 0x00, 0x28, 0x00, + 0xff, 0xf7, 0x37, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0x96, 0xe0, 0x2b, 0x6a, + 0x05, 0x93, 0x12, 0xab, 0x5b, 0x88, 0x09, 0x93, 0x00, 0x2b, 0x00, 0xd0, + 0x81, 0xe0, 0x05, 0x9b, 0x2e, 0x33, 0x0b, 0x93, 0x69, 0x23, 0x0c, 0x93, + 0x00, 0x23, 0x08, 0x93, 0x08, 0x9b, 0x0b, 0x9a, 0x5b, 0x00, 0xd6, 0x5a, + 0x07, 0x9a, 0x00, 0x23, 0xb2, 0x42, 0x06, 0xd8, 0x13, 0x00, 0x96, 0x4a, + 0xf1, 0x0f, 0x9a, 0x18, 0xd3, 0x17, 0xb2, 0x42, 0x4b, 0x41, 0x94, 0x4a, + 0x94, 0x49, 0xb2, 0x18, 0x92, 0xb2, 0x8a, 0x42, 0x05, 0xd9, 0x00, 0x2b, + 0x00, 0xd1, 0x8b, 0xe0, 0x33, 0x07, 0x00, 0xd0, 0x92, 0xe0, 0x16, 0x27, + 0x09, 0x9b, 0x08, 0x9a, 0x28, 0x00, 0x9e, 0x18, 0x05, 0x9a, 0x05, 0x9b, + 0x51, 0x78, 0x1b, 0x78, 0x09, 0x02, 0x19, 0x43, 0x0c, 0xab, 0xff, 0x18, + 0xb6, 0xb2, 0x49, 0x04, 0x00, 0x23, 0x49, 0x0c, 0x00, 0x97, 0x32, 0x00, + 0x01, 0xf0, 0x2a, 0xfd, 0x85, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x51, 0xd1, + 0x00, 0x23, 0x3b, 0x80, 0x3b, 0x88, 0x00, 0x2b, 0x16, 0xd1, 0xfc, 0x20, + 0x05, 0x99, 0x05, 0x9a, 0x49, 0x78, 0x12, 0x78, 0x09, 0x02, 0x11, 0x43, + 0x14, 0xaa, 0x10, 0x71, 0x01, 0x20, 0x49, 0x04, 0x49, 0x0c, 0x11, 0x80, + 0x56, 0x80, 0x02, 0x90, 0x03, 0x97, 0x01, 0x93, 0x00, 0x93, 0x28, 0x00, + 0x01, 0xf0, 0x7c, 0xfd, 0x04, 0x1e, 0x37, 0xdb, 0x16, 0x23, 0x0c, 0xaa, + 0x05, 0x99, 0x9b, 0x18, 0x05, 0x9a, 0x49, 0x78, 0x12, 0x78, 0x09, 0x02, + 0x11, 0x43, 0x80, 0x22, 0x12, 0x02, 0x11, 0x43, 0x06, 0x9a, 0x1b, 0x88, + 0x28, 0x00, 0x00, 0x92, 0x32, 0x00, 0xff, 0xf7, 0x41, 0xfa, 0x6d, 0x4b, + 0x04, 0x00, 0xc3, 0x18, 0xee, 0x6c, 0x02, 0x2b, 0x28, 0xd8, 0x00, 0x2e, + 0x09, 0xd0, 0x05, 0x9a, 0x05, 0x9b, 0x52, 0x78, 0x1b, 0x78, 0x12, 0x02, + 0x1a, 0x43, 0x06, 0x21, 0x00, 0x23, 0x02, 0x20, 0xb0, 0x47, 0x06, 0x99, + 0x28, 0x00, 0x01, 0xf0, 0xd3, 0xfd, 0x04, 0x00, 0x25, 0xe0, 0x7c, 0x22, + 0x09, 0x9b, 0x0c, 0x92, 0x53, 0x43, 0x13, 0x3b, 0x9b, 0xb2, 0x09, 0x93, + 0x05, 0x9b, 0x08, 0x33, 0x0b, 0x93, 0x77, 0xe7, 0x00, 0x28, 0xad, 0xda, + 0xee, 0x6c, 0x00, 0x2e, 0x00, 0xd1, 0x80, 0xe0, 0x00, 0x23, 0x22, 0x00, + 0x01, 0x21, 0x02, 0x20, 0xb0, 0x47, 0x7a, 0xe0, 0x00, 0x2e, 0x0c, 0xd0, + 0x05, 0x9b, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, 0x13, 0x43, 0x05, 0x9a, + 0x11, 0x78, 0x52, 0x78, 0x12, 0x02, 0x0a, 0x43, 0x02, 0x21, 0x08, 0x00, + 0xb0, 0x47, 0x00, 0x2c, 0xe4, 0xdb, 0x01, 0x23, 0x08, 0x9a, 0x01, 0x32, + 0x08, 0x92, 0x00, 0x2b, 0x4c, 0xd1, 0x0c, 0x99, 0x8a, 0x42, 0x00, 0xd0, + 0x52, 0xe7, 0x47, 0xe0, 0x05, 0x22, 0x14, 0xaf, 0x00, 0x92, 0x33, 0x02, + 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xff, 0xf7, 0x6d, 0xf8, + 0x04, 0x1e, 0xcd, 0xdb, 0x12, 0xab, 0x1a, 0x88, 0x39, 0x88, 0x41, 0x4b, + 0x13, 0x40, 0x99, 0x42, 0x0b, 0xd1, 0x09, 0x9b, 0x08, 0x98, 0x79, 0x88, + 0x1b, 0x18, 0x99, 0x42, 0x05, 0xd1, 0x7a, 0x21, 0x3b, 0x79, 0x8b, 0x43, + 0x84, 0x2b, 0x00, 0xd1, 0x7d, 0xe0, 0x16, 0x27, 0x08, 0x99, 0x09, 0x9b, + 0x52, 0x04, 0x5b, 0x18, 0x9b, 0xb2, 0x0d, 0x93, 0x0c, 0xab, 0xff, 0x18, + 0x51, 0x0c, 0x33, 0x00, 0x00, 0x97, 0x0d, 0x9a, 0x28, 0x00, 0x01, 0xf0, + 0x7d, 0xfc, 0x2f, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x37, 0xd1, 0x00, 0x23, + 0x3b, 0x80, 0x3b, 0x88, 0x12, 0xae, 0x31, 0x88, 0x00, 0x2b, 0x33, 0xd1, + 0xec, 0x6c, 0x00, 0x2c, 0x03, 0xd0, 0x0a, 0x00, 0x02, 0x20, 0x06, 0x21, + 0xa0, 0x47, 0x31, 0x88, 0x28, 0x00, 0xff, 0xf7, 0x8d, 0xf9, 0x04, 0x1e, + 0x92, 0xdb, 0x00, 0x23, 0x06, 0x9a, 0x01, 0x32, 0x92, 0xb2, 0x06, 0x92, + 0x00, 0x2b, 0x00, 0xd1, 0x8f, 0xe6, 0x0a, 0x9a, 0x01, 0x32, 0x92, 0xb2, + 0x0a, 0x92, 0x00, 0x2b, 0x00, 0xd1, 0x59, 0xe6, 0xeb, 0x68, 0x07, 0x9a, + 0x1b, 0x01, 0x9a, 0x42, 0x00, 0xd2, 0x48, 0xe6, 0x00, 0x2c, 0x00, 0xd0, + 0x7a, 0xe7, 0xed, 0x6c, 0x00, 0x2d, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, + 0x19, 0x00, 0x52, 0x00, 0x02, 0x20, 0xa8, 0x47, 0x20, 0x00, 0x17, 0xb0, + 0xf0, 0xbd, 0x00, 0x28, 0xc7, 0xda, 0x6b, 0xe7, 0x06, 0x9a, 0x28, 0x00, + 0x00, 0x92, 0x0d, 0x9a, 0xff, 0xf7, 0x82, 0xf9, 0x0d, 0x4b, 0x04, 0x00, + 0xc3, 0x18, 0xef, 0x6c, 0x02, 0x2b, 0x19, 0xd8, 0x32, 0x88, 0x00, 0x2f, + 0x03, 0xd0, 0x00, 0x23, 0x06, 0x21, 0x02, 0x20, 0xb8, 0x47, 0x12, 0xab, + 0x19, 0x88, 0x28, 0x00, 0xff, 0xf7, 0x4c, 0xf9, 0x43, 0xe7, 0xc0, 0x46, + 0xff, 0x01, 0x00, 0x00, 0xff, 0xdf, 0xff, 0xff, 0xfd, 0xdf, 0x00, 0x00, + 0xee, 0xd8, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, 0xff, 0x7f, 0xff, 0xff, + 0x00, 0x2f, 0x00, 0xd1, 0x5b, 0xe7, 0x02, 0x21, 0x73, 0x88, 0x32, 0x88, + 0x08, 0x00, 0xb8, 0x47, 0x55, 0xe7, 0x01, 0x21, 0x07, 0x9b, 0xf7, 0x1a, + 0x6b, 0x6a, 0x7f, 0x08, 0x0e, 0x40, 0xb6, 0x00, 0xdb, 0x5d, 0x76, 0x18, + 0x33, 0x41, 0x0b, 0x40, 0x16, 0xd0, 0xec, 0x6c, 0x00, 0x2c, 0x03, 0xd0, + 0x00, 0x23, 0x05, 0x31, 0x02, 0x20, 0xa0, 0x47, 0x12, 0xab, 0x19, 0x88, + 0x28, 0x00, 0xff, 0xf7, 0x1d, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0x21, 0xe7, + 0x06, 0x99, 0x28, 0x00, 0x01, 0xf0, 0xe2, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0x1a, 0xe7, 0x01, 0x23, 0x01, 0x21, 0xb1, 0x40, 0x6a, 0x6a, 0xd7, 0x19, + 0x3a, 0x78, 0x0a, 0x43, 0x3a, 0x70, 0x2d, 0xe7, 0x01, 0x23, 0x08, 0x93, + 0x06, 0x9a, 0x6b, 0x6a, 0x9b, 0x5c, 0x08, 0x9a, 0x92, 0x00, 0x13, 0x41, + 0x07, 0x22, 0x1a, 0x40, 0x09, 0x92, 0x01, 0x2a, 0x00, 0xd0, 0x93, 0xe0, + 0x08, 0x9a, 0x0a, 0x9b, 0x12, 0xae, 0x9b, 0x18, 0x05, 0x22, 0x9b, 0xb2, + 0x05, 0x93, 0x00, 0x92, 0x1b, 0x02, 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, + 0x28, 0x00, 0xfe, 0xf7, 0x92, 0xff, 0x04, 0x1e, 0x00, 0xda, 0xf1, 0xe6, + 0x16, 0x27, 0x0c, 0xab, 0xff, 0x18, 0x11, 0xab, 0x72, 0x88, 0x31, 0x88, + 0x28, 0x00, 0x00, 0x93, 0x3b, 0x00, 0xff, 0xf7, 0xa5, 0xf8, 0x04, 0x1e, + 0x61, 0xd1, 0x80, 0x22, 0x3b, 0x88, 0x92, 0x01, 0x93, 0x42, 0x20, 0xd8, + 0x1a, 0x07, 0x1e, 0xd0, 0x05, 0x22, 0x14, 0xaf, 0x00, 0x92, 0x1b, 0x02, + 0x02, 0x00, 0x01, 0x97, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x71, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0xd0, 0xe6, 0x38, 0x4a, 0x33, 0x88, 0x13, 0x40, + 0x3a, 0x88, 0x93, 0x42, 0x04, 0xd1, 0x78, 0x22, 0x3b, 0x79, 0x93, 0x43, + 0x84, 0x2b, 0x45, 0xd0, 0x16, 0x23, 0x0c, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0x05, 0x9a, 0x93, 0x42, 0x4e, 0xd0, 0x11, 0xab, 0x1b, 0x88, 0x12, 0xae, + 0x72, 0x88, 0x31, 0x88, 0x28, 0x00, 0x00, 0x93, 0x05, 0x9b, 0xff, 0xf7, + 0xd1, 0xf8, 0x2b, 0x4b, 0x04, 0x00, 0xc3, 0x18, 0xef, 0x6c, 0x02, 0x2b, + 0x45, 0xd8, 0x00, 0x2f, 0x04, 0xd0, 0x32, 0x88, 0x00, 0x23, 0x06, 0x21, + 0x02, 0x20, 0xb8, 0x47, 0x05, 0x99, 0x28, 0x00, 0x01, 0xf0, 0x68, 0xfc, + 0x04, 0x1e, 0x00, 0xda, 0xa0, 0xe6, 0x31, 0x88, 0x28, 0x00, 0xff, 0xf7, + 0x95, 0xf8, 0x04, 0x00, 0x00, 0x2c, 0x00, 0xda, 0x98, 0xe6, 0x06, 0x9b, + 0x01, 0x33, 0x06, 0x93, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x0d, 0xe7, + 0x06, 0x9b, 0x1a, 0x00, 0x80, 0x23, 0x5b, 0x00, 0x9a, 0x42, 0x00, 0xd0, + 0x66, 0xe5, 0x80, 0x22, 0x92, 0x00, 0x94, 0x46, 0x07, 0x9b, 0x63, 0x44, + 0x9b, 0xb2, 0x07, 0x93, 0xfe, 0xe6, 0x13, 0x4b, 0x98, 0x42, 0x0c, 0xd1, + 0xec, 0x6c, 0x00, 0x2c, 0x04, 0xd0, 0x00, 0x23, 0x05, 0x9a, 0x05, 0x21, + 0x02, 0x20, 0xa0, 0x47, 0x05, 0x99, 0x28, 0x00, 0x01, 0xf0, 0x38, 0xfc, + 0x04, 0x00, 0x00, 0x2c, 0x00, 0xda, 0x6f, 0xe6, 0x08, 0x9b, 0x01, 0x2b, + 0x00, 0xd0, 0x59, 0xe7, 0x00, 0x23, 0x09, 0x93, 0xcf, 0xe7, 0x00, 0x2f, + 0xca, 0xd0, 0x02, 0x21, 0x73, 0x88, 0x32, 0x88, 0x08, 0x00, 0xb8, 0x47, + 0xc4, 0xe7, 0xc0, 0x46, 0xff, 0x7f, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, + 0xee, 0xd8, 0xff, 0xff, 0x80, 0x22, 0xf0, 0xb5, 0x06, 0x00, 0x89, 0xb0, + 0x00, 0x21, 0x52, 0x00, 0x40, 0x6a, 0x04, 0xf0, 0x30, 0xf9, 0x00, 0x21, + 0xf4, 0x6c, 0x07, 0x91, 0x8c, 0x42, 0x03, 0xd0, 0x0b, 0x00, 0x0a, 0x00, + 0x01, 0x20, 0xa0, 0x47, 0x00, 0x24, 0x07, 0xab, 0x03, 0x93, 0x14, 0x4b, + 0x05, 0x94, 0x01, 0x93, 0x04, 0x94, 0x23, 0x00, 0x02, 0x94, 0x00, 0x94, + 0x22, 0x00, 0x21, 0x00, 0x30, 0x00, 0x01, 0xf0, 0x2f, 0xf9, 0x0f, 0x4b, + 0x05, 0x00, 0x98, 0x42, 0x15, 0xd0, 0xa0, 0x42, 0x07, 0xd0, 0xf7, 0x6c, + 0xa7, 0x42, 0x04, 0xd0, 0x01, 0x21, 0x02, 0x00, 0x23, 0x00, 0x08, 0x00, + 0xb8, 0x47, 0xf4, 0x6c, 0x00, 0x2c, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, + 0x19, 0x00, 0x52, 0x00, 0x01, 0x20, 0xa0, 0x47, 0x28, 0x00, 0x09, 0xb0, + 0xf0, 0xbd, 0x25, 0x00, 0xf1, 0xe7, 0xc0, 0x46, 0xe9, 0x31, 0x00, 0x00, + 0xa8, 0xd8, 0xff, 0xff, 0xf8, 0xb5, 0x06, 0x00, 0x0c, 0x00, 0x01, 0xf0, + 0xcf, 0xf9, 0x05, 0x1e, 0x0c, 0xdb, 0x24, 0x01, 0xa4, 0xb2, 0x27, 0x00, + 0x10, 0x37, 0xbf, 0xb2, 0x21, 0x00, 0x01, 0x34, 0x30, 0x00, 0xa4, 0xb2, + 0xfe, 0xf7, 0x96, 0xfe, 0xbc, 0x42, 0xf7, 0xd1, 0x28, 0x00, 0xf8, 0xbd, + 0xf0, 0xb5, 0x05, 0x00, 0x0f, 0x00, 0x00, 0x24, 0xc3, 0x68, 0x87, 0xb0, + 0x03, 0x93, 0x03, 0x6a, 0x02, 0x93, 0xa2, 0xb2, 0x04, 0x92, 0x03, 0x9a, + 0x23, 0x03, 0xa2, 0x42, 0x01, 0xd1, 0x1e, 0x48, 0x35, 0xe0, 0x2a, 0x6a, + 0x14, 0x21, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x28, 0x00, + 0x00, 0x22, 0xfe, 0xf7, 0x84, 0xfe, 0x02, 0x99, 0x18, 0x4e, 0x0b, 0x00, + 0x1e, 0x33, 0x05, 0x93, 0x00, 0x23, 0xb4, 0x46, 0x1a, 0x00, 0x98, 0x42, + 0x0b, 0xd0, 0x01, 0x28, 0x13, 0xd9, 0x01, 0x34, 0x00, 0x28, 0x1c, 0xd1, + 0xdd, 0xe7, 0x08, 0x88, 0x00, 0x28, 0x06, 0xd1, 0x01, 0x32, 0x92, 0xb2, + 0x02, 0x31, 0x05, 0x98, 0x81, 0x42, 0xf6, 0xd1, 0x05, 0xe0, 0x60, 0x45, + 0x03, 0xd1, 0x01, 0x33, 0x9b, 0xb2, 0xbb, 0x42, 0xf4, 0xd9, 0xd1, 0x18, + 0x0f, 0x29, 0x0a, 0xd1, 0xbb, 0x42, 0x08, 0xd8, 0xeb, 0x6b, 0x04, 0x99, + 0x9a, 0x1a, 0xea, 0x63, 0x28, 0x00, 0xff, 0xf7, 0xa3, 0xff, 0x07, 0xb0, + 0xf0, 0xbd, 0x01, 0x34, 0xbd, 0xe7, 0xc0, 0x46, 0xd3, 0xd8, 0xff, 0xff, + 0xff, 0xff, 0x00, 0x00, 0xf7, 0xb5, 0x80, 0x22, 0x04, 0x6a, 0x52, 0x00, + 0x0b, 0x03, 0x00, 0x92, 0x14, 0x21, 0x00, 0x22, 0x01, 0x94, 0x05, 0x00, + 0x26, 0x00, 0xfe, 0xf7, 0x42, 0xfe, 0x00, 0x22, 0x23, 0x00, 0x1e, 0x36, + 0x11, 0x00, 0x0b, 0x4f, 0x90, 0x42, 0x0d, 0xd0, 0xab, 0x6b, 0x9a, 0x1a, + 0xeb, 0x6b, 0xaa, 0x63, 0x59, 0x1a, 0xe9, 0x63, 0xfe, 0xbd, 0x1c, 0x88, + 0xbc, 0x42, 0x02, 0xd0, 0x00, 0x2c, 0x04, 0xd1, 0x01, 0x31, 0x02, 0x33, + 0x9e, 0x42, 0xf6, 0xd1, 0xee, 0xe7, 0x01, 0x32, 0xf9, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xf0, 0xb5, 0x1d, 0x00, 0xc3, 0x68, 0x93, 0xb0, + 0x05, 0x93, 0x03, 0x6a, 0x04, 0x00, 0x0c, 0x93, 0x05, 0x9b, 0x0f, 0x00, + 0x08, 0x92, 0x03, 0x93, 0x29, 0x2b, 0x01, 0xd9, 0x29, 0x23, 0x03, 0x93, + 0x00, 0x26, 0x80, 0x22, 0x08, 0x9b, 0x52, 0x00, 0x1e, 0x60, 0xff, 0x21, + 0x60, 0x6a, 0x04, 0xf0, 0x4e, 0xf8, 0x63, 0x6a, 0x02, 0x96, 0x06, 0x93, + 0x03, 0x9b, 0x06, 0x9a, 0x5b, 0x00, 0xd3, 0x18, 0x03, 0x22, 0x09, 0x93, + 0x03, 0x33, 0x93, 0x43, 0x0a, 0x93, 0x06, 0x9b, 0x0a, 0x9a, 0x3b, 0x60, + 0x6b, 0x42, 0x5d, 0x41, 0x32, 0x23, 0x6d, 0x42, 0x2b, 0x40, 0x0f, 0x93, + 0x03, 0x9b, 0x9b, 0x00, 0x9b, 0x18, 0x0e, 0x93, 0x6a, 0x46, 0x12, 0x89, + 0x02, 0x9b, 0x0d, 0x92, 0x05, 0x99, 0x02, 0x9a, 0x1b, 0x03, 0x8a, 0x42, + 0x01, 0xd1, 0x00, 0x20, 0x4f, 0xe0, 0x22, 0x6a, 0x14, 0x21, 0x01, 0x92, + 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x20, 0x00, 0x00, 0x22, 0xfe, 0xf7, + 0xde, 0xfd, 0x0c, 0x9b, 0x00, 0x25, 0x19, 0x00, 0x2f, 0x00, 0x1e, 0x31, + 0x3a, 0x4e, 0xa8, 0x42, 0x47, 0xd0, 0x01, 0x28, 0x3b, 0xd1, 0x0e, 0x26, + 0x6b, 0x46, 0x0e, 0xaa, 0xb6, 0x18, 0x02, 0x22, 0x1b, 0x89, 0x15, 0x21, + 0x1b, 0x03, 0x00, 0x92, 0xfe, 0x33, 0x01, 0x96, 0x00, 0x22, 0x20, 0x00, + 0xfe, 0xf7, 0xc5, 0xfd, 0x00, 0x28, 0x2a, 0xdb, 0x23, 0x1d, 0xda, 0x8f, + 0x33, 0x88, 0x9a, 0x42, 0x35, 0xd9, 0xd3, 0x1a, 0x05, 0x22, 0x57, 0x43, + 0x0f, 0x9a, 0x9b, 0xb2, 0x53, 0x43, 0x7d, 0x1b, 0xeb, 0x18, 0x07, 0x93, + 0x00, 0x23, 0x06, 0x99, 0x27, 0x4d, 0x03, 0x9a, 0x93, 0x42, 0x0b, 0xda, + 0x0a, 0x9e, 0x9a, 0x00, 0x92, 0x19, 0x0e, 0x88, 0x0b, 0x91, 0xae, 0x42, + 0x22, 0xd1, 0x6b, 0x46, 0x9b, 0x8e, 0x0b, 0x80, 0x07, 0x9b, 0x13, 0x60, + 0x08, 0x9b, 0x08, 0x9a, 0x1b, 0x68, 0x04, 0x93, 0x01, 0x33, 0x13, 0x60, + 0x02, 0x9b, 0x01, 0x33, 0x02, 0x93, 0x00, 0x28, 0xa4, 0xd0, 0x13, 0xb0, + 0xf0, 0xbd, 0x1a, 0x88, 0xb2, 0x42, 0xbe, 0xd0, 0x00, 0x2a, 0x05, 0xd1, + 0x01, 0x37, 0xbf, 0xb2, 0x02, 0x33, 0x99, 0x42, 0xf5, 0xd1, 0xb6, 0xe7, + 0x01, 0x35, 0xad, 0xb2, 0xf8, 0xe7, 0x9b, 0x1a, 0xdb, 0x43, 0xc7, 0xe7, + 0x0b, 0x99, 0x16, 0x68, 0x07, 0x9f, 0x02, 0x31, 0xbe, 0x42, 0x19, 0xda, + 0x03, 0x99, 0x09, 0x9d, 0x02, 0x39, 0x04, 0x91, 0x0e, 0x99, 0x04, 0x9e, + 0x02, 0x3d, 0x0f, 0x1f, 0xb3, 0x42, 0x04, 0xdd, 0x69, 0x46, 0x0b, 0x9b, + 0x89, 0x8e, 0x19, 0x80, 0xca, 0xe7, 0xae, 0x1e, 0x08, 0x39, 0x36, 0x88, + 0x09, 0x68, 0x2e, 0x80, 0x39, 0x60, 0x04, 0x99, 0x01, 0x39, 0x04, 0x91, + 0x39, 0x00, 0xea, 0xe7, 0x01, 0x33, 0xb0, 0xe7, 0xff, 0xff, 0x00, 0x00, + 0xf0, 0xb5, 0x05, 0x00, 0x03, 0x6a, 0x9b, 0xb0, 0x0f, 0x93, 0x43, 0x6a, + 0x0c, 0x00, 0x14, 0x22, 0x00, 0x21, 0x15, 0xa8, 0x0a, 0x93, 0x03, 0xf0, + 0x96, 0xff, 0x2b, 0x8a, 0xa3, 0x42, 0x06, 0xd1, 0x60, 0x1c, 0xe9, 0x68, + 0x03, 0xf0, 0x5c, 0xff, 0x00, 0x23, 0x29, 0x82, 0x6b, 0x61, 0x23, 0x01, + 0x01, 0x33, 0x9b, 0xb2, 0x11, 0x93, 0x0f, 0x9b, 0x24, 0x03, 0x1b, 0x19, + 0x10, 0x93, 0x00, 0x23, 0x08, 0x93, 0x8f, 0xe1, 0x0c, 0x9a, 0x10, 0x9b, + 0x14, 0x21, 0x9b, 0x1a, 0x0d, 0x93, 0x2b, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x28, 0x00, 0x0d, 0x9b, 0xfe, 0xf7, + 0x30, 0xfd, 0x04, 0x00, 0x00, 0x2c, 0x07, 0xd1, 0x07, 0x9b, 0x0e, 0x9a, + 0x9b, 0x1a, 0x7f, 0x2b, 0x02, 0xdc, 0x07, 0x9b, 0x0e, 0x2b, 0x01, 0xdd, + 0x3b, 0x00, 0x88, 0xe0, 0x07, 0x9b, 0x0c, 0x9a, 0x5b, 0x00, 0xd3, 0x5a, + 0x07, 0x9a, 0x09, 0x93, 0x11, 0x9b, 0x9b, 0x18, 0x9b, 0xb2, 0x15, 0xaa, + 0x08, 0x93, 0x13, 0x78, 0x01, 0x2b, 0x15, 0xd0, 0x00, 0x2b, 0x04, 0xd0, + 0x02, 0x2b, 0x00, 0xd1, 0x8f, 0xe0, 0x23, 0x00, 0x6d, 0xe0, 0x6b, 0x46, + 0x24, 0x21, 0x59, 0x5e, 0x3b, 0x00, 0x00, 0x29, 0x00, 0xdc, 0x66, 0xe0, + 0x6b, 0x46, 0x9b, 0x8c, 0x17, 0x74, 0x53, 0x80, 0x6b, 0x46, 0x1b, 0x8c, + 0x13, 0x81, 0xee, 0xe7, 0x52, 0x88, 0x09, 0x99, 0x3b, 0x00, 0x8a, 0x42, + 0x59, 0xd1, 0x05, 0x22, 0x08, 0x9b, 0x13, 0xae, 0x00, 0x92, 0x1b, 0x02, + 0x22, 0x00, 0x01, 0x96, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0xef, 0xfc, + 0x04, 0x1e, 0x2d, 0xdb, 0x73, 0x88, 0x00, 0x20, 0x68, 0x2b, 0x05, 0xd9, + 0x69, 0x3b, 0x18, 0x00, 0x7c, 0x21, 0x03, 0xf0, 0x6d, 0xfe, 0x01, 0x30, + 0x15, 0xab, 0x9e, 0x88, 0x86, 0x42, 0x3d, 0xd1, 0x13, 0xab, 0x1a, 0x79, + 0x7f, 0x2a, 0x1e, 0xd9, 0x1a, 0x22, 0x0c, 0xa9, 0x52, 0x18, 0x02, 0x92, + 0x08, 0x9a, 0x00, 0x93, 0x01, 0x92, 0x00, 0x22, 0x09, 0x9b, 0x11, 0x00, + 0x28, 0x00, 0x01, 0xf0, 0x25, 0xfa, 0x04, 0x1e, 0x0c, 0xdb, 0x2b, 0x6a, + 0x00, 0x22, 0x01, 0x93, 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x14, 0x21, + 0x0d, 0x9b, 0x28, 0x00, 0xfe, 0xf7, 0xc1, 0xfc, 0x04, 0x1e, 0x0e, 0xda, + 0x20, 0x00, 0x1b, 0xb0, 0xf0, 0xbd, 0x08, 0x99, 0x28, 0x00, 0x01, 0xf0, + 0xdf, 0xf9, 0x04, 0x1e, 0xf6, 0xdb, 0x1a, 0x23, 0x0c, 0xaa, 0x9b, 0x18, + 0x01, 0x22, 0x52, 0x42, 0x1a, 0x80, 0x13, 0xab, 0x58, 0x88, 0x1a, 0x23, + 0x0c, 0xaa, 0x9b, 0x18, 0x1b, 0x88, 0x09, 0x93, 0x00, 0x2e, 0x1c, 0xd1, + 0x17, 0x30, 0x6a, 0x46, 0x0a, 0x9b, 0x92, 0x8c, 0x40, 0x00, 0x1a, 0x52, + 0x3b, 0x00, 0x07, 0x9a, 0x01, 0x32, 0x07, 0x92, 0x00, 0x2b, 0x00, 0xd0, + 0x6a, 0xe7, 0x0b, 0x9a, 0x01, 0x32, 0x0b, 0x92, 0x00, 0x2b, 0x6b, 0xd0, + 0x0e, 0x9b, 0x80, 0x33, 0x0e, 0x93, 0x0c, 0x9b, 0x01, 0x3b, 0xff, 0x3b, + 0x0c, 0x93, 0x00, 0x2c, 0x00, 0xd1, 0x2d, 0xe1, 0xca, 0xe7, 0x68, 0x28, + 0x01, 0xd8, 0x04, 0x30, 0xdf, 0xe7, 0x69, 0x38, 0x7c, 0x21, 0x03, 0xf0, + 0x91, 0xfe, 0x08, 0x1d, 0xd9, 0xe7, 0x09, 0x9b, 0x98, 0x4a, 0x99, 0x49, + 0x9a, 0x18, 0x92, 0xb2, 0x3b, 0x00, 0x8a, 0x42, 0xd7, 0xd8, 0x05, 0x22, + 0x08, 0x9b, 0x13, 0xae, 0x00, 0x92, 0x1b, 0x02, 0x22, 0x00, 0x01, 0x96, + 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x6d, 0xfc, 0x04, 0x1e, 0xab, 0xdb, + 0x33, 0x79, 0x7f, 0x2b, 0x2b, 0xd9, 0x1a, 0x23, 0x0c, 0xaa, 0x9b, 0x18, + 0x00, 0x22, 0x02, 0x93, 0x08, 0x9b, 0x00, 0x96, 0x01, 0x93, 0x11, 0x00, + 0x09, 0x9b, 0x28, 0x00, 0x01, 0xf0, 0xb2, 0xf9, 0x04, 0x1e, 0x00, 0xda, + 0x98, 0xe7, 0x00, 0x24, 0x0c, 0xab, 0x02, 0x94, 0x5b, 0x8b, 0x13, 0xa9, + 0x01, 0x93, 0x4b, 0x88, 0x03, 0x22, 0x00, 0x93, 0x28, 0x00, 0x09, 0x9b, + 0x01, 0xf0, 0x20, 0xfa, 0x2b, 0x6a, 0x22, 0x00, 0x01, 0x93, 0x80, 0x23, + 0x5b, 0x00, 0x00, 0x93, 0x14, 0x21, 0x0d, 0x9b, 0x28, 0x00, 0xfe, 0xf7, + 0x40, 0xfc, 0x04, 0x00, 0x00, 0x2c, 0x9b, 0xda, 0x7c, 0xe7, 0x08, 0x99, + 0x28, 0x00, 0x01, 0xf0, 0x5f, 0xf9, 0x04, 0x1e, 0xf6, 0xd1, 0x00, 0x21, + 0x08, 0x9b, 0x02, 0x91, 0x01, 0x93, 0x13, 0xab, 0x5b, 0x88, 0x02, 0x22, + 0x00, 0x93, 0x28, 0x00, 0x09, 0x9b, 0x01, 0xf0, 0xff, 0xf9, 0x87, 0xe7, + 0x00, 0x2c, 0x00, 0xd1, 0xcc, 0xe0, 0x65, 0xe7, 0x0b, 0x7c, 0x00, 0x2b, + 0x70, 0xd0, 0x07, 0x9b, 0x05, 0x22, 0xcb, 0x60, 0x01, 0x23, 0x0b, 0x70, + 0x08, 0x9b, 0x13, 0xaf, 0x00, 0x92, 0x1b, 0x02, 0x01, 0x97, 0x32, 0x00, + 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x13, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0x50, 0xe7, 0x78, 0x88, 0x37, 0x00, 0x68, 0x28, 0x05, 0xd9, 0x69, 0x38, + 0x7c, 0x21, 0x03, 0xf0, 0x91, 0xfd, 0x01, 0x30, 0x87, 0xb2, 0x80, 0x23, + 0x15, 0xae, 0x71, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1a, 0x23, 0x0c, 0xaa, + 0x9b, 0x18, 0xb7, 0x80, 0x3a, 0x00, 0x00, 0x93, 0x28, 0x00, 0x00, 0x23, + 0x01, 0xf0, 0x2c, 0xf8, 0x56, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x0c, 0xd1, + 0x31, 0x89, 0x28, 0x00, 0x01, 0xf0, 0x16, 0xf9, 0x04, 0x1e, 0x00, 0xda, + 0x2c, 0xe7, 0x00, 0x23, 0x33, 0x70, 0x00, 0x2c, 0x00, 0xd0, 0x27, 0xe7, + 0x71, 0xe0, 0x00, 0x28, 0x00, 0xda, 0x23, 0xe7, 0x6a, 0x6a, 0x0c, 0xab, + 0x5b, 0x8b, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x1b, 0x02, + 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0xd6, 0xfb, 0x04, 0x1e, + 0x00, 0xda, 0x13, 0xe7, 0x0a, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x13, 0xd4, + 0x5a, 0xb2, 0x00, 0x2a, 0x12, 0xda, 0x9a, 0x07, 0x12, 0xd4, 0x04, 0x22, + 0x1a, 0x40, 0x11, 0xd1, 0x0a, 0x9b, 0x99, 0x78, 0xdb, 0x78, 0x1b, 0x02, + 0x0b, 0x43, 0xbb, 0x42, 0x0c, 0xd1, 0x0c, 0xab, 0x5b, 0x8b, 0x07, 0x92, + 0xf3, 0x80, 0xd0, 0xe7, 0x39, 0x4c, 0xf9, 0xe6, 0x39, 0x4c, 0xf7, 0xe6, + 0x39, 0x4c, 0xf5, 0xe6, 0x39, 0x4c, 0xf3, 0xe6, 0x39, 0x4c, 0xf1, 0xe6, + 0x02, 0x22, 0x0a, 0x70, 0x07, 0x93, 0x38, 0xe0, 0x80, 0x22, 0x00, 0x26, + 0xcb, 0x68, 0x12, 0x02, 0x07, 0x93, 0x4b, 0x88, 0x0e, 0x70, 0x09, 0x93, + 0x1a, 0x43, 0xcb, 0x88, 0x89, 0x88, 0x68, 0x6a, 0x13, 0xaf, 0xb1, 0x42, + 0x0b, 0xd1, 0x00, 0x90, 0x04, 0x97, 0x03, 0x91, 0x02, 0x91, 0x01, 0x91, + 0x28, 0x00, 0x01, 0xf0, 0x93, 0xfa, 0x04, 0x00, 0xb0, 0x42, 0xa8, 0xda, + 0xd2, 0xe6, 0x01, 0x93, 0x02, 0x97, 0x13, 0x00, 0x00, 0x96, 0x02, 0x00, + 0x31, 0x00, 0x28, 0x00, 0x01, 0xf0, 0xe0, 0xf8, 0x04, 0x1e, 0x00, 0xda, + 0xc6, 0xe6, 0x02, 0x96, 0x3b, 0x88, 0x69, 0x6a, 0x01, 0x93, 0x0a, 0x9b, + 0x28, 0x00, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, 0x13, 0x43, 0x00, 0x93, + 0x32, 0x00, 0x09, 0x9b, 0x01, 0xf0, 0x4c, 0xf9, 0x8b, 0xe7, 0x03, 0x23, + 0x0b, 0x70, 0x15, 0xab, 0x1a, 0x78, 0x00, 0x24, 0x03, 0x2a, 0x00, 0xd1, + 0xae, 0xe6, 0x7f, 0x22, 0x01, 0x27, 0x1c, 0x74, 0x07, 0x9b, 0xdb, 0x17, + 0x13, 0x40, 0x07, 0x9a, 0x9b, 0x18, 0xdb, 0x11, 0x0b, 0x93, 0xdb, 0x01, + 0x0e, 0x93, 0x0b, 0x9b, 0x0f, 0x9a, 0x1b, 0x02, 0xd3, 0x1a, 0x0c, 0x93, + 0x0b, 0x9b, 0x00, 0x2b, 0x00, 0xdc, 0x19, 0xe6, 0x15, 0xa9, 0x0e, 0x78, + 0x01, 0x2e, 0xa7, 0xd0, 0x00, 0x2e, 0x00, 0xd1, 0x2c, 0xe7, 0x02, 0x2e, + 0xd9, 0xd0, 0x00, 0x23, 0x9e, 0xe7, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, + 0xfe, 0x7f, 0x00, 0x00, 0xee, 0xd8, 0xff, 0xff, 0xe4, 0xd8, 0xff, 0xff, + 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, + 0xe3, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0f, 0x26, 0xc3, 0x68, 0x87, 0xb0, + 0x5e, 0x43, 0x83, 0x6b, 0x04, 0x00, 0xf6, 0x1a, 0xc3, 0x6b, 0x1e, 0x3e, + 0xf5, 0x1a, 0x43, 0x6b, 0x0f, 0x00, 0x03, 0x2b, 0x04, 0xd9, 0xfb, 0x23, + 0x6b, 0x43, 0x00, 0x20, 0x8b, 0x42, 0x19, 0xdc, 0x38, 0x00, 0xfb, 0x21, + 0xfa, 0x30, 0x03, 0xf0, 0xad, 0xfc, 0x02, 0x90, 0x86, 0x42, 0x44, 0xdb, + 0x05, 0x23, 0x01, 0x93, 0x6b, 0x1e, 0x2b, 0x43, 0xdb, 0x0f, 0x05, 0xaa, + 0x04, 0xa9, 0x20, 0x00, 0xff, 0xf7, 0xf2, 0xfc, 0x00, 0x28, 0x05, 0xdb, + 0x05, 0x98, 0x00, 0x28, 0x04, 0xd1, 0x02, 0x9b, 0xab, 0x42, 0x32, 0xda, + 0x07, 0xb0, 0xf0, 0xbd, 0x04, 0x9b, 0x01, 0x22, 0x1e, 0x88, 0x23, 0x00, + 0x40, 0x33, 0x1a, 0x70, 0x31, 0x00, 0x20, 0x00, 0x03, 0x93, 0xff, 0xf7, + 0xa1, 0xfd, 0x00, 0x23, 0x03, 0x9a, 0x13, 0x70, 0x98, 0x42, 0xed, 0xdb, + 0x31, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xaa, 0xfc, 0x00, 0x28, 0xe7, 0xdb, + 0x31, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x3e, 0xfc, 0x00, 0x28, 0xe1, 0xdb, + 0x0f, 0x22, 0xe3, 0x68, 0x53, 0x43, 0xa2, 0x6b, 0x9b, 0x1a, 0xe2, 0x6b, + 0x1e, 0x3b, 0x9b, 0x1a, 0x00, 0x2d, 0x01, 0xdc, 0x9d, 0x42, 0x04, 0xd0, + 0x01, 0x9a, 0x01, 0x3a, 0x01, 0x92, 0x00, 0x2a, 0x05, 0xd1, 0xfb, 0x22, + 0x53, 0x43, 0xbb, 0x42, 0xcc, 0xda, 0x05, 0x48, 0xca, 0xe7, 0x62, 0x6b, + 0x02, 0x2a, 0x03, 0xd9, 0xfb, 0x22, 0x5a, 0x43, 0xba, 0x42, 0xf2, 0xda, + 0x1d, 0x00, 0xb1, 0xe7, 0xef, 0xd8, 0xff, 0xff, 0xf7, 0xb5, 0x84, 0x68, + 0x07, 0x00, 0x01, 0x91, 0x15, 0x00, 0x1e, 0x00, 0x63, 0x1c, 0x17, 0xd0, + 0x33, 0x00, 0x94, 0x42, 0x10, 0xd9, 0xa4, 0x1a, 0xb4, 0x42, 0x00, 0xdd, + 0x34, 0x00, 0x23, 0x00, 0x01, 0x9a, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, + 0x47, 0xfd, 0x00, 0x28, 0x07, 0xdb, 0x01, 0x9a, 0x33, 0x1b, 0x12, 0x19, + 0x01, 0x92, 0x2d, 0x19, 0x00, 0x2b, 0x03, 0xdc, 0x30, 0x00, 0xfe, 0xbd, + 0x33, 0x00, 0xf9, 0xe7, 0x01, 0x9a, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, + 0x7d, 0xfa, 0x00, 0x28, 0xf4, 0xda, 0xf4, 0xe7, 0x73, 0xb5, 0x01, 0xaa, + 0x05, 0x00, 0x02, 0xf0, 0x59, 0xfc, 0x04, 0x1e, 0x02, 0xda, 0x28, 0x63, + 0x20, 0x00, 0x76, 0xbd, 0x01, 0x9e, 0xb3, 0x8b, 0x9b, 0x06, 0xf9, 0xd4, + 0x33, 0x6a, 0x00, 0x2b, 0x04, 0xd1, 0x31, 0x00, 0x28, 0x00, 0xfe, 0xf7, + 0x29, 0xfb, 0x30, 0x62, 0x01, 0x98, 0x02, 0x6a, 0x00, 0x2a, 0xed, 0xd0, + 0x8a, 0x21, 0x56, 0x78, 0x49, 0x00, 0x71, 0x43, 0x6c, 0x6c, 0x14, 0x31, + 0x24, 0x69, 0x13, 0x8a, 0x61, 0x18, 0xd2, 0x68, 0xff, 0xf7, 0xb0, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0x28, 0x63, 0x01, 0x9b, 0x28, 0x00, 0x19, 0x6a, + 0xfe, 0xf7, 0x34, 0xfb, 0xd8, 0xe7, 0x00, 0x00, 0xf7, 0xb5, 0x04, 0x00, + 0x1d, 0x00, 0x83, 0x6d, 0x17, 0x00, 0x01, 0x91, 0x60, 0x22, 0x00, 0x21, + 0x00, 0x93, 0x0a, 0x9e, 0x03, 0xf0, 0xab, 0xfc, 0x0c, 0x22, 0x01, 0x99, + 0x20, 0x00, 0x03, 0xf0, 0x9d, 0xfc, 0x00, 0x9b, 0x08, 0x9a, 0xa3, 0x65, + 0x80, 0x23, 0x9b, 0x00, 0xe3, 0x60, 0x7b, 0x1c, 0xff, 0x33, 0x67, 0x62, + 0x23, 0x62, 0x00, 0x21, 0x28, 0x00, 0x03, 0xf0, 0x98, 0xfc, 0x03, 0x22, + 0x2a, 0x40, 0x05, 0xd0, 0x04, 0x23, 0x9b, 0x1a, 0x08, 0x9a, 0xed, 0x18, + 0xd3, 0x1a, 0x08, 0x93, 0xa5, 0x62, 0x30, 0x21, 0x08, 0x98, 0x03, 0xf0, + 0xd1, 0xfb, 0x03, 0x22, 0x09, 0x9b, 0xe0, 0x62, 0x1a, 0x40, 0x05, 0xd0, + 0x04, 0x23, 0x9b, 0x1a, 0x09, 0x9a, 0xf6, 0x1a, 0xd2, 0x18, 0x09, 0x92, + 0x03, 0x23, 0x1e, 0x42, 0x00, 0xd0, 0x9e, 0x43, 0x80, 0x22, 0x09, 0x9b, + 0x92, 0x01, 0x63, 0x64, 0x33, 0x00, 0x96, 0x42, 0x00, 0xd9, 0x13, 0x00, + 0xa3, 0x64, 0x20, 0x00, 0xfe, 0xf7, 0x08, 0xfb, 0x07, 0x4b, 0x20, 0x00, + 0xe3, 0x65, 0x00, 0xf0, 0x83, 0xfd, 0x00, 0x28, 0x01, 0xda, 0x20, 0x63, + 0xfe, 0xbd, 0x0b, 0x9b, 0x00, 0x20, 0xe3, 0x64, 0x01, 0x23, 0x54, 0x34, + 0x23, 0x70, 0xf7, 0xe7, 0x15, 0x03, 0x09, 0x20, 0xf8, 0xb5, 0xc2, 0x6d, + 0x10, 0x4b, 0x04, 0x00, 0x9a, 0x42, 0x0c, 0xd1, 0x07, 0x00, 0x54, 0x37, + 0x3b, 0x78, 0x00, 0x2b, 0x07, 0xd0, 0x00, 0x26, 0x83, 0x6a, 0x1d, 0x1d, + 0xe3, 0x6a, 0xb3, 0x42, 0x02, 0xd8, 0x00, 0x23, 0x3b, 0x70, 0xf8, 0xbd, + 0x00, 0x23, 0xe9, 0x5e, 0x00, 0x29, 0x07, 0xd0, 0x20, 0x00, 0xff, 0xf7, + 0x5b, 0xff, 0x00, 0x23, 0xe9, 0x5e, 0x20, 0x00, 0x02, 0xf0, 0x98, 0xfb, + 0x01, 0x36, 0x30, 0x35, 0xea, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, + 0x00, 0x6b, 0x70, 0x47, 0x00, 0x23, 0x03, 0x63, 0x70, 0x47, 0x00, 0x00, + 0xf0, 0xb5, 0x87, 0xb0, 0x17, 0x00, 0x03, 0x93, 0xc2, 0x6d, 0x3f, 0x4b, + 0x05, 0x00, 0x0e, 0x00, 0x9a, 0x42, 0x04, 0xd0, 0x3d, 0x4c, 0x2c, 0x63, + 0x20, 0x00, 0x07, 0xb0, 0xf0, 0xbd, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, + 0x00, 0x2b, 0x01, 0xd1, 0x39, 0x4c, 0xf4, 0xe7, 0x08, 0x00, 0x03, 0xf0, + 0x2a, 0xfc, 0x1f, 0x28, 0x01, 0xd9, 0x37, 0x4c, 0xed, 0xe7, 0x32, 0x00, + 0x05, 0xa9, 0x28, 0x00, 0x02, 0xf0, 0xf8, 0xfa, 0x00, 0x28, 0x02, 0xda, + 0x28, 0x63, 0x04, 0xb2, 0xe4, 0xe7, 0x04, 0xaa, 0x31, 0x00, 0x28, 0x00, + 0x01, 0xf0, 0xb2, 0xfe, 0x04, 0x00, 0x7b, 0x07, 0x34, 0xd4, 0x00, 0x28, + 0x24, 0xda, 0x05, 0x9b, 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, + 0x55, 0xfb, 0x2c, 0x63, 0x24, 0xb2, 0xd1, 0xe7, 0x00, 0x2c, 0xf4, 0xdb, + 0x02, 0xab, 0x19, 0x89, 0x03, 0x9b, 0x05, 0x9a, 0x00, 0x93, 0x28, 0x00, + 0x3b, 0x00, 0x01, 0xf0, 0x27, 0xf9, 0x04, 0x1e, 0xe9, 0xdb, 0xbb, 0x07, + 0x06, 0xd5, 0x00, 0x22, 0x05, 0x98, 0x11, 0x00, 0x01, 0xf0, 0xbe, 0xfe, + 0x04, 0x1e, 0xe0, 0xdb, 0x00, 0x22, 0x05, 0x9b, 0x9a, 0x61, 0x04, 0x24, + 0x1c, 0x5f, 0xb5, 0xe7, 0x00, 0x28, 0xe3, 0xd1, 0x44, 0x23, 0x3b, 0x40, + 0x44, 0x2b, 0xdf, 0xd1, 0x05, 0x9b, 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, + 0x02, 0xf0, 0x2a, 0xfb, 0x14, 0x4c, 0xa6, 0xe7, 0x00, 0x28, 0xf1, 0xd0, + 0x13, 0x4b, 0x9c, 0x42, 0xd0, 0xd1, 0x0a, 0x23, 0x02, 0xa9, 0x5b, 0x18, + 0x00, 0x22, 0x19, 0x00, 0x28, 0x00, 0x02, 0xf0, 0xfb, 0xf9, 0x04, 0x1e, + 0xbd, 0xdb, 0x02, 0xab, 0x59, 0x89, 0x04, 0xab, 0x01, 0x93, 0x01, 0x23, + 0x32, 0x00, 0x00, 0x93, 0x28, 0x00, 0x00, 0x23, 0x00, 0xf0, 0xf2, 0xff, + 0x04, 0x1e, 0xb0, 0xdb, 0x02, 0x23, 0x9f, 0x43, 0xb8, 0xe7, 0xc0, 0x46, + 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, 0xf0, 0xd8, 0xff, 0xff, + 0xcc, 0xd8, 0xff, 0xff, 0xd2, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xf7, 0xb5, 0x16, 0x00, 0x1c, 0x00, 0xc2, 0x6d, 0x29, 0x4b, 0x05, 0x00, + 0x0f, 0x00, 0x9a, 0x42, 0x03, 0xd0, 0x28, 0x4c, 0x2c, 0x63, 0x20, 0x00, + 0xfe, 0xbd, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, + 0x24, 0x4c, 0xf5, 0xe7, 0x01, 0xaa, 0x02, 0xf0, 0x01, 0xfb, 0x00, 0x28, + 0x05, 0xda, 0x04, 0x00, 0x28, 0x63, 0x21, 0x4b, 0x9c, 0x42, 0x0d, 0xd0, + 0xeb, 0xe7, 0x01, 0x9b, 0x9a, 0x8b, 0x12, 0x07, 0x01, 0xd4, 0x1e, 0x4c, + 0xe4, 0xe7, 0x9b, 0x68, 0x01, 0x33, 0x05, 0xd1, 0x00, 0x2c, 0x03, 0xdd, + 0x19, 0x4b, 0x2b, 0x63, 0x00, 0x24, 0xdc, 0xe7, 0x39, 0x00, 0x28, 0x00, + 0xff, 0xf7, 0x88, 0xfe, 0x01, 0x98, 0x81, 0x69, 0x83, 0x68, 0x0a, 0x19, + 0x9a, 0x42, 0x14, 0xd3, 0x5c, 0x1a, 0x00, 0x2c, 0xee, 0xdd, 0x33, 0x00, + 0x22, 0x00, 0x02, 0xf0, 0xa5, 0xf8, 0x0f, 0x4b, 0x98, 0x42, 0x06, 0xd1, + 0x20, 0x00, 0x01, 0x9a, 0x93, 0x69, 0x1b, 0x19, 0x93, 0x61, 0x04, 0x00, + 0xc1, 0xe7, 0x00, 0x28, 0x07, 0xda, 0x28, 0x63, 0xf9, 0xe7, 0x33, 0x00, + 0x22, 0x00, 0x02, 0xf0, 0x93, 0xf8, 0x00, 0x28, 0xc5, 0xdb, 0x01, 0x9a, + 0x93, 0x69, 0x1b, 0x19, 0x93, 0x61, 0xc2, 0xe7, 0x15, 0x03, 0x09, 0x20, + 0xd8, 0xd8, 0xff, 0xff, 0xf0, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xda, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x15, 0x00, 0x1e, 0x00, 0xc2, 0x6d, + 0x2d, 0x4b, 0x85, 0xb0, 0x04, 0x00, 0x0f, 0x00, 0x9a, 0x42, 0x03, 0xd0, + 0x2b, 0x48, 0x20, 0x63, 0x05, 0xb0, 0xf0, 0xbd, 0x03, 0x00, 0x54, 0x33, + 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x28, 0x48, 0xf5, 0xe7, 0x03, 0xaa, + 0x02, 0xf0, 0x9e, 0xfa, 0x00, 0x28, 0xf0, 0xdb, 0x39, 0x00, 0x20, 0x00, + 0xff, 0xf7, 0x3a, 0xfe, 0x03, 0x9f, 0xbb, 0x68, 0x5a, 0x1c, 0x00, 0xd1, + 0x00, 0x23, 0x01, 0x2e, 0x05, 0xd0, 0x02, 0x2e, 0x06, 0xd0, 0x00, 0x2d, + 0x06, 0xda, 0x1e, 0x48, 0xdf, 0xe7, 0xba, 0x69, 0xad, 0x18, 0xf8, 0xe7, + 0xed, 0x18, 0xf6, 0xe7, 0x9d, 0x42, 0x02, 0xdd, 0xbb, 0x61, 0x1a, 0x48, + 0xd5, 0xe7, 0x00, 0x26, 0xb5, 0x42, 0x0d, 0xdd, 0x68, 0x1e, 0xfb, 0x21, + 0x03, 0xf0, 0x4a, 0xfa, 0x83, 0xb2, 0x68, 0x2b, 0x06, 0xd9, 0x18, 0x00, + 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0x42, 0xfa, 0x01, 0x30, 0x86, 0xb2, + 0x3b, 0x8a, 0xb3, 0x42, 0x11, 0xd0, 0xf9, 0x88, 0x80, 0x23, 0x0a, 0x27, + 0x1b, 0x02, 0x6f, 0x44, 0x19, 0x43, 0x00, 0x97, 0x00, 0x23, 0x32, 0x00, + 0x20, 0x00, 0x00, 0xf0, 0xdd, 0xfc, 0x00, 0x28, 0xb3, 0xdb, 0x03, 0x9b, + 0x3a, 0x88, 0x1e, 0x82, 0xda, 0x81, 0x03, 0x9b, 0x28, 0x00, 0x9d, 0x61, + 0xac, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xc8, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x2a, 0x4b, 0xc2, 0x6d, 0x85, 0xb0, 0x05, 0x00, 0x0f, 0x00, + 0x9a, 0x42, 0x02, 0xd0, 0x27, 0x4c, 0x2c, 0x63, 0x3e, 0xe0, 0x03, 0x00, + 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x24, 0x4c, 0xf6, 0xe7, + 0x08, 0x00, 0x03, 0xf0, 0xd2, 0xfa, 0x1f, 0x28, 0x01, 0xd9, 0x22, 0x4c, + 0xef, 0xe7, 0x00, 0x22, 0x03, 0xa9, 0x28, 0x00, 0x02, 0xf0, 0xa0, 0xf9, + 0x04, 0x1e, 0xe8, 0xdb, 0x0a, 0x26, 0x6e, 0x44, 0x32, 0x00, 0x39, 0x00, + 0x28, 0x00, 0x01, 0xf0, 0x5b, 0xfd, 0x04, 0x1e, 0x07, 0xd0, 0x03, 0x9b, + 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0x01, 0xfa, 0x00, 0x2c, + 0xd7, 0xdb, 0x00, 0x23, 0x31, 0x88, 0x03, 0x9a, 0x00, 0x93, 0x28, 0x00, + 0x00, 0xf0, 0xd8, 0xff, 0x04, 0x1e, 0x07, 0xd0, 0x03, 0x9b, 0x28, 0x00, + 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0xf0, 0xf9, 0x00, 0x2c, 0xc6, 0xdb, + 0x01, 0x22, 0x00, 0x21, 0x03, 0x98, 0x01, 0xf0, 0x69, 0xfd, 0x04, 0x1e, + 0x03, 0xd1, 0x00, 0x24, 0x20, 0x00, 0x05, 0xb0, 0xf0, 0xbd, 0x03, 0x9b, + 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0xdd, 0xf9, 0x00, 0x2c, + 0xb3, 0xdb, 0xf2, 0xe7, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xcc, 0xd8, 0xff, 0xff, 0x0d, 0x4b, 0xc2, 0x6d, + 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x9a, 0x42, 0x02, 0xd0, 0x0b, 0x48, + 0x20, 0x63, 0x10, 0xe0, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, + 0x01, 0xd1, 0x08, 0x48, 0xf6, 0xe7, 0xff, 0xf7, 0x7d, 0xfd, 0x00, 0x28, + 0xf2, 0xdb, 0x29, 0x00, 0x20, 0x00, 0x02, 0xf0, 0xb9, 0xf9, 0x00, 0x28, + 0xec, 0xdb, 0x70, 0xbd, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0x0e, 0x4b, 0xc2, 0x6d, 0x10, 0xb5, 0x04, 0x00, + 0x9a, 0x42, 0x02, 0xd0, 0x0c, 0x48, 0x20, 0x63, 0x10, 0xbd, 0x03, 0x00, + 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x09, 0x48, 0xf6, 0xe7, + 0x00, 0x21, 0xfe, 0xf7, 0xe5, 0xfd, 0x20, 0x00, 0xff, 0xf7, 0x06, 0xf9, + 0x20, 0x00, 0xfe, 0xf7, 0x19, 0xfe, 0x20, 0x00, 0x00, 0xf0, 0x52, 0xfb, + 0xea, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x12, 0x01, 0x5c, 0x1c, 0x14, 0x19, + 0x05, 0x22, 0x85, 0xb0, 0xa4, 0xb2, 0x02, 0xad, 0x0f, 0x00, 0x00, 0x92, + 0x23, 0x02, 0x01, 0x95, 0x10, 0x32, 0x00, 0x21, 0x0a, 0x9e, 0xfd, 0xf7, + 0xde, 0xff, 0x00, 0x28, 0x1d, 0xdb, 0x2b, 0x88, 0xbb, 0x42, 0x1c, 0xd1, + 0x0b, 0x9a, 0x69, 0x88, 0x12, 0x88, 0x8a, 0x42, 0x17, 0xd1, 0x29, 0x79, + 0x7c, 0x20, 0x0d, 0x00, 0x85, 0x43, 0x80, 0x2d, 0x11, 0xd1, 0x1b, 0xb2, + 0x00, 0x2b, 0x03, 0xda, 0x4b, 0x06, 0x01, 0xd4, 0x00, 0x2a, 0x0a, 0xd0, + 0x30, 0x1e, 0x06, 0xd0, 0x30, 0x88, 0x00, 0x1b, 0x44, 0x42, 0x60, 0x41, + 0x03, 0x4c, 0x40, 0x42, 0x20, 0x40, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x48, + 0xfb, 0xe7, 0xc0, 0x46, 0xaa, 0xd8, 0xff, 0xff, 0x7f, 0xb5, 0x1d, 0x00, + 0x1b, 0x4b, 0x0c, 0x00, 0x9a, 0x42, 0x24, 0xd0, 0x13, 0x07, 0x25, 0xd0, + 0x80, 0x23, 0x9b, 0x01, 0x9a, 0x42, 0x23, 0xd8, 0x13, 0x02, 0x04, 0x21, + 0x62, 0x5e, 0x05, 0x21, 0x02, 0xae, 0x00, 0x91, 0x01, 0x96, 0x11, 0x31, + 0xfd, 0xf7, 0xa1, 0xff, 0x00, 0x28, 0x13, 0xdb, 0x33, 0x79, 0xda, 0x07, + 0x16, 0xd4, 0x5a, 0xb2, 0x00, 0x2a, 0x15, 0xda, 0x9a, 0x07, 0x15, 0xd4, + 0x5b, 0x07, 0x15, 0xd4, 0x06, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x11, 0xda, + 0x73, 0x88, 0xab, 0x42, 0x02, 0xd0, 0x09, 0x48, 0x00, 0xe0, 0x09, 0x48, + 0x04, 0xb0, 0x70, 0xbd, 0x08, 0x48, 0xfb, 0xe7, 0x08, 0x48, 0xf9, 0xe7, + 0x08, 0x48, 0xf7, 0xe7, 0x08, 0x48, 0xf5, 0xe7, 0x08, 0x48, 0xf3, 0xe7, + 0x08, 0x48, 0xf1, 0xe7, 0xff, 0xff, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, + 0xde, 0xd8, 0xff, 0xff, 0xdd, 0xd8, 0xff, 0xff, 0xdc, 0xd8, 0xff, 0xff, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0x12, 0x01, 0x30, 0xb5, 0x01, 0x33, 0xd3, 0x18, + 0x13, 0x4a, 0x8f, 0xb0, 0x89, 0x18, 0x13, 0x4a, 0x89, 0xb2, 0x9b, 0xb2, + 0x91, 0x42, 0x1b, 0xd8, 0x2e, 0x22, 0x02, 0xac, 0x00, 0x92, 0x1b, 0x02, + 0x01, 0x94, 0x00, 0x22, 0x15, 0x21, 0xfd, 0xf7, 0x56, 0xff, 0x00, 0x28, + 0x11, 0xdb, 0x65, 0x88, 0x00, 0x2d, 0x0d, 0xd1, 0x3d, 0x22, 0x23, 0x79, + 0x93, 0x43, 0xc0, 0x2b, 0x08, 0xd1, 0x15, 0x21, 0x12, 0x98, 0x69, 0x44, + 0x03, 0xf0, 0x91, 0xf9, 0x03, 0x00, 0x28, 0x00, 0x00, 0x2b, 0x00, 0xd0, + 0x03, 0x48, 0x0f, 0xb0, 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, + 0xfe, 0x7f, 0x00, 0x00, 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x05, 0x00, + 0x0c, 0x00, 0x21, 0x48, 0x01, 0x39, 0x89, 0xb2, 0x8f, 0xb0, 0x81, 0x42, + 0x01, 0xd9, 0x1f, 0x48, 0x27, 0xe0, 0x15, 0x99, 0x0e, 0x88, 0x14, 0x99, + 0x00, 0x29, 0x24, 0xd0, 0x21, 0xb2, 0x00, 0x29, 0x21, 0xda, 0x12, 0x01, + 0x01, 0x33, 0xd3, 0x18, 0x2e, 0x22, 0x9b, 0xb2, 0x02, 0xaf, 0x00, 0x92, + 0x1b, 0x02, 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xfd, 0xf7, + 0x18, 0xff, 0x00, 0x28, 0x0f, 0xdb, 0x7b, 0x88, 0x00, 0x2b, 0x0e, 0xd1, + 0x3d, 0x22, 0x3b, 0x79, 0x93, 0x43, 0xc0, 0x2b, 0x09, 0xd1, 0x15, 0x21, + 0x14, 0x98, 0x69, 0x44, 0x03, 0xf0, 0x53, 0xf9, 0x00, 0x28, 0x02, 0xd1, + 0x0b, 0x48, 0x0f, 0xb0, 0xf0, 0xbd, 0x64, 0x04, 0x64, 0x0c, 0xa4, 0x1b, + 0xe3, 0x10, 0xff, 0x2b, 0xcd, 0xd8, 0x6a, 0x6a, 0xd2, 0x18, 0x07, 0x23, + 0x1c, 0x40, 0x06, 0x3b, 0xa3, 0x40, 0x11, 0x78, 0x0b, 0x43, 0x13, 0x70, + 0xc3, 0xe7, 0xc0, 0x46, 0xfd, 0xff, 0x00, 0x00, 0xaa, 0xd8, 0xff, 0xff, + 0xd9, 0xd8, 0xff, 0xff, 0x09, 0x4a, 0x91, 0x42, 0x06, 0xd1, 0x00, 0x2b, + 0x02, 0xd1, 0x43, 0x6b, 0x01, 0x33, 0x43, 0x63, 0x06, 0x48, 0x70, 0x47, + 0x00, 0x29, 0x03, 0xd1, 0xc3, 0x6b, 0x01, 0x33, 0xc3, 0x63, 0xf7, 0xe7, + 0x83, 0x6b, 0x01, 0x33, 0x83, 0x63, 0xf3, 0xe7, 0xff, 0xff, 0x00, 0x00, + 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x85, 0xb0, 0x01, 0x91, 0x02, 0x92, + 0x07, 0x89, 0x06, 0x00, 0x00, 0x25, 0x68, 0x2f, 0x06, 0xd9, 0x38, 0x00, + 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0x50, 0xf8, 0x01, 0x30, 0x85, 0xb2, + 0x74, 0x89, 0x00, 0x20, 0x68, 0x2c, 0x06, 0xd9, 0x20, 0x00, 0x7c, 0x21, + 0x69, 0x38, 0x03, 0xf0, 0x45, 0xf8, 0x01, 0x30, 0x80, 0xb2, 0x01, 0x9b, + 0x9d, 0x42, 0x1c, 0xd8, 0x83, 0x42, 0x1a, 0xd8, 0x00, 0x2b, 0x1a, 0xd0, + 0x7c, 0x23, 0x01, 0x9a, 0x5a, 0x43, 0x13, 0x3a, 0x92, 0xb2, 0x9b, 0x18, + 0x01, 0x34, 0x9b, 0xb2, 0xa3, 0x42, 0x00, 0xdd, 0x23, 0x00, 0x9b, 0xb2, + 0x03, 0x93, 0x3c, 0x1c, 0x97, 0x42, 0x00, 0xd2, 0x14, 0x1c, 0xa4, 0xb2, + 0x25, 0x1d, 0x14, 0x4f, 0x6d, 0x00, 0x03, 0x9a, 0xa3, 0xb2, 0x9a, 0x42, + 0x04, 0xd8, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x9a, 0x69, 0x23, 0xe6, 0xe7, + 0x01, 0x9a, 0x00, 0x2a, 0x0c, 0xd1, 0x02, 0x9b, 0x5b, 0x19, 0xda, 0x8c, + 0x02, 0x35, 0xba, 0x42, 0xf1, 0xd0, 0x33, 0x89, 0x31, 0x68, 0xe3, 0x1a, + 0x5b, 0x00, 0x5a, 0x52, 0x01, 0x34, 0xe6, 0xe7, 0x29, 0x00, 0x68, 0x2b, + 0x06, 0xd9, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0x8c, 0xf8, + 0x04, 0x31, 0x49, 0x00, 0x02, 0x9b, 0x5a, 0x5a, 0xe8, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0x01, 0x00, 0x10, 0xb5, 0x21, 0x24, 0x03, 0x00, + 0x05, 0x48, 0x20, 0x31, 0x1a, 0x78, 0x00, 0x2a, 0x02, 0xd0, 0x01, 0x33, + 0x8b, 0x42, 0x00, 0xd1, 0x10, 0xbd, 0x60, 0x43, 0x50, 0x40, 0xf5, 0xe7, + 0x05, 0x15, 0x00, 0x00, 0x30, 0xb5, 0x1c, 0x00, 0x19, 0x4b, 0x85, 0xb0, + 0x9a, 0x42, 0x20, 0xd0, 0x13, 0x07, 0x21, 0xd0, 0x80, 0x23, 0x9b, 0x01, + 0x9a, 0x42, 0x1f, 0xd8, 0x13, 0x02, 0x00, 0x22, 0x8a, 0x5e, 0x05, 0x21, + 0x02, 0xad, 0x00, 0x91, 0x01, 0x95, 0x12, 0x31, 0xfd, 0xf7, 0x4d, 0xfe, + 0x00, 0x28, 0x0f, 0xdb, 0x2b, 0x79, 0xda, 0x07, 0x12, 0xd4, 0x5a, 0xb2, + 0x00, 0x2a, 0x11, 0xda, 0x9a, 0x07, 0x11, 0xd4, 0x5b, 0x07, 0x11, 0xd5, + 0x6b, 0x88, 0xa3, 0x42, 0x02, 0xd0, 0x09, 0x48, 0x00, 0xe0, 0x09, 0x48, + 0x05, 0xb0, 0x30, 0xbd, 0x08, 0x48, 0xfb, 0xe7, 0x08, 0x48, 0xf9, 0xe7, + 0x08, 0x48, 0xf7, 0xe7, 0x08, 0x48, 0xf5, 0xe7, 0x08, 0x48, 0xf3, 0xe7, + 0x08, 0x48, 0xf1, 0xe7, 0xff, 0xff, 0x00, 0x00, 0xe2, 0xd8, 0xff, 0xff, + 0xe1, 0xd8, 0xff, 0xff, 0xe0, 0xd8, 0xff, 0xff, 0xdf, 0xd8, 0xff, 0xff, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xe5, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0c, 0x00, 0x1f, 0x49, 0x06, 0x00, + 0x61, 0x18, 0x1f, 0x48, 0x8f, 0xb0, 0x89, 0xb2, 0x14, 0x9d, 0x81, 0x42, + 0x33, 0xd8, 0x01, 0x33, 0x12, 0x03, 0x1b, 0x02, 0x9b, 0x18, 0x2e, 0x22, + 0x02, 0xaf, 0x00, 0x92, 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x30, 0x00, + 0xfd, 0xf7, 0x03, 0xfe, 0x00, 0x28, 0x24, 0xd1, 0x7b, 0x88, 0x00, 0x2b, + 0x21, 0xd1, 0x79, 0x22, 0x3b, 0x79, 0x93, 0x43, 0x80, 0x2b, 0x1c, 0xd1, + 0xa8, 0x68, 0x00, 0x28, 0x08, 0xd0, 0x15, 0x21, 0x69, 0x44, 0x03, 0xf0, + 0x3c, 0xf8, 0x00, 0x28, 0x02, 0xd1, 0x0d, 0x48, 0x0f, 0xb0, 0xf0, 0xbd, + 0x28, 0x88, 0x61, 0x04, 0x49, 0x0c, 0x81, 0x42, 0x0b, 0xd3, 0x6b, 0x88, + 0x8b, 0x42, 0x08, 0xd3, 0x08, 0x1a, 0x69, 0x68, 0x02, 0xf0, 0x6a, 0xff, + 0x73, 0x6a, 0x18, 0x18, 0x03, 0x78, 0x01, 0x33, 0x03, 0x70, 0x04, 0x48, + 0xea, 0xe7, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, 0xfe, 0x7f, 0x00, 0x00, + 0xd9, 0xd8, 0xff, 0xff, 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x15, 0x00, + 0x1e, 0x00, 0x95, 0xb0, 0x1a, 0x9f, 0x02, 0x90, 0x03, 0x91, 0x00, 0x2f, + 0x02, 0xd1, 0x38, 0x00, 0x15, 0xb0, 0xf0, 0xbd, 0x3c, 0x00, 0x40, 0x2f, + 0x00, 0xd9, 0x40, 0x24, 0x04, 0xab, 0x01, 0x93, 0x00, 0x94, 0x33, 0x00, + 0x03, 0x9a, 0x0b, 0x21, 0x02, 0x98, 0xfd, 0xf7, 0xb8, 0xfd, 0x00, 0x28, + 0xee, 0xdb, 0x04, 0xab, 0x01, 0x93, 0x00, 0x94, 0x2b, 0x00, 0x03, 0x9a, + 0x0f, 0x21, 0x02, 0x98, 0xfd, 0xf7, 0x11, 0xfe, 0x00, 0x28, 0xe3, 0xdb, + 0x3f, 0x1b, 0x36, 0x19, 0x2d, 0x19, 0xdc, 0xe7, 0xf0, 0xb5, 0x14, 0x00, + 0x0f, 0x22, 0x8d, 0xb0, 0x06, 0x93, 0x12, 0xab, 0x1b, 0x88, 0x06, 0x00, + 0x0b, 0x93, 0xc3, 0x68, 0x0f, 0x00, 0x5a, 0x43, 0x07, 0x92, 0x02, 0x6a, + 0x09, 0x92, 0x0e, 0x2c, 0x00, 0xdc, 0xa4, 0xe0, 0x01, 0x37, 0xbf, 0xb2, + 0xbb, 0x42, 0x51, 0xd9, 0x00, 0x24, 0x3b, 0x03, 0x03, 0x93, 0x07, 0x9b, + 0x00, 0x2b, 0x4f, 0xdd, 0x7f, 0x22, 0xe3, 0x17, 0x13, 0x40, 0x1b, 0x19, + 0xdb, 0x11, 0xda, 0x01, 0x05, 0x92, 0x09, 0x9a, 0x1b, 0x02, 0xd3, 0x1a, + 0x04, 0x93, 0x03, 0x9a, 0x09, 0x9b, 0x14, 0x21, 0x9b, 0x18, 0x04, 0x9a, + 0x30, 0x00, 0x9b, 0x1a, 0x0a, 0x93, 0x33, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x0a, 0x9b, 0xfd, 0xf7, 0x6f, 0xfd, + 0x25, 0x00, 0x07, 0x9b, 0x02, 0x90, 0x08, 0x93, 0x08, 0x9b, 0x2c, 0x00, + 0x07, 0x93, 0x02, 0x9b, 0x00, 0x2b, 0x05, 0xd1, 0x05, 0x9b, 0xeb, 0x1a, + 0x7f, 0x2b, 0x01, 0xdc, 0x0e, 0x2d, 0x28, 0xdd, 0x05, 0x9b, 0x80, 0x33, + 0x05, 0x93, 0x04, 0x9b, 0x01, 0x3b, 0xff, 0x3b, 0x04, 0x93, 0x02, 0x9b, + 0x00, 0x2b, 0x02, 0xd1, 0x05, 0x9b, 0x80, 0x2b, 0xd1, 0xd1, 0x01, 0x37, + 0xf3, 0x68, 0xbf, 0xb2, 0x9f, 0x42, 0x55, 0xd2, 0x80, 0x22, 0x52, 0x01, + 0x94, 0x46, 0x03, 0x9b, 0x63, 0x44, 0x03, 0x93, 0x00, 0x24, 0x02, 0x9b, + 0xa3, 0x42, 0xb4, 0xd0, 0x02, 0x9b, 0x00, 0x2b, 0x06, 0xdb, 0x03, 0xe0, + 0x04, 0x24, 0x06, 0x9b, 0x1c, 0x40, 0x4d, 0xd0, 0x29, 0x4b, 0x02, 0x93, + 0x02, 0x98, 0x0d, 0xb0, 0xf0, 0xbd, 0x01, 0x22, 0x06, 0x9b, 0x13, 0x42, + 0x05, 0xd0, 0x04, 0x9a, 0x6b, 0x00, 0xd3, 0x5a, 0x0b, 0x9a, 0x93, 0x42, + 0x2f, 0xd1, 0x16, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x1f, 0x80, 0x17, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x1d, 0x60, 0x13, 0x9b, 0x00, 0x2b, 0xe7, 0xd0, + 0x02, 0x22, 0x06, 0x9b, 0x0b, 0x99, 0x13, 0x42, 0x02, 0xd1, 0x04, 0x9a, + 0x6b, 0x00, 0xd1, 0x5a, 0x15, 0x9b, 0x3a, 0x00, 0x01, 0x93, 0x14, 0x9b, + 0x30, 0x00, 0x00, 0x93, 0x13, 0x9c, 0x2b, 0x00, 0xa0, 0x47, 0x15, 0x4b, + 0xc3, 0x18, 0x01, 0x2b, 0x21, 0xd8, 0x14, 0x4b, 0x98, 0x42, 0x0c, 0xd1, + 0x33, 0x6a, 0x00, 0x22, 0x01, 0x93, 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, + 0x14, 0x21, 0x0a, 0x9b, 0x30, 0x00, 0xfd, 0xf7, 0xfe, 0xfc, 0x00, 0x28, + 0x11, 0xdb, 0x08, 0x9b, 0x01, 0x35, 0x01, 0x3b, 0x08, 0x93, 0x8b, 0xe7, + 0x04, 0x23, 0x06, 0x9a, 0x13, 0x40, 0xb7, 0xd1, 0x03, 0x93, 0x1f, 0x00, + 0xa8, 0xe7, 0x0b, 0x03, 0x03, 0x93, 0x5e, 0xe7, 0x03, 0x94, 0x27, 0x00, + 0x5b, 0xe7, 0x02, 0x90, 0xae, 0xe7, 0xc0, 0x46, 0xa8, 0xd8, 0xff, 0xff, + 0x57, 0x27, 0x00, 0x00, 0xa9, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x04, 0x00, + 0x0d, 0x03, 0x0f, 0x00, 0x80, 0x21, 0x85, 0xb0, 0x49, 0x01, 0xa3, 0x68, + 0x28, 0x00, 0x98, 0x47, 0x63, 0x6b, 0x22, 0x00, 0x01, 0x33, 0x63, 0x63, + 0x02, 0x26, 0x2b, 0x00, 0x42, 0x32, 0x01, 0x92, 0xfe, 0x33, 0x00, 0x96, + 0x00, 0x22, 0x19, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x2c, 0xfd, 0x00, 0x28, + 0x1a, 0xdb, 0xe3, 0x68, 0x0e, 0x22, 0xdb, 0x1b, 0x0d, 0x4f, 0x6a, 0x44, + 0x5f, 0x40, 0x2b, 0x00, 0x17, 0x80, 0xfc, 0x33, 0x01, 0x92, 0x00, 0x96, + 0x00, 0x22, 0x19, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x1a, 0xfd, 0x00, 0x28, + 0x08, 0xdb, 0x80, 0x22, 0x04, 0x34, 0xe3, 0x8f, 0x12, 0x02, 0x01, 0x33, + 0x9b, 0xb2, 0x93, 0x42, 0x02, 0xd0, 0xe3, 0x87, 0x05, 0xb0, 0xf0, 0xbd, + 0x00, 0x23, 0xfa, 0xe7, 0x29, 0x04, 0x00, 0x00, 0xf0, 0xb5, 0x00, 0x27, + 0x04, 0x00, 0x8b, 0xb0, 0x3b, 0x4d, 0x08, 0xab, 0x1f, 0x80, 0x07, 0x95, + 0x08, 0xae, 0x33, 0x88, 0xe2, 0x68, 0x93, 0x42, 0x24, 0xd3, 0x38, 0x4a, + 0x7b, 0x1b, 0x01, 0x35, 0x93, 0x42, 0x00, 0xdc, 0x7d, 0x1c, 0x23, 0x1d, + 0xad, 0xb2, 0xdd, 0x87, 0x07, 0x9b, 0x1a, 0x00, 0x31, 0x4b, 0x9a, 0x42, + 0x58, 0xd1, 0x00, 0x25, 0x09, 0xab, 0x05, 0x93, 0x30, 0x4b, 0x65, 0x63, + 0x01, 0x93, 0xa5, 0x63, 0x2b, 0x00, 0xe5, 0x63, 0x04, 0x96, 0x03, 0x95, + 0x02, 0x95, 0x00, 0x95, 0x2a, 0x00, 0x29, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0xd1, 0xfe, 0x2a, 0x4b, 0x98, 0x42, 0x41, 0xd1, 0x28, 0x00, 0x3f, 0xe0, + 0x1a, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, 0x1b, 0x03, + 0x00, 0x92, 0xfc, 0x33, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, 0xfd, 0xf7, + 0x66, 0xfc, 0x00, 0x28, 0x30, 0xdb, 0xe2, 0x68, 0x33, 0x88, 0xd1, 0x1a, + 0x1f, 0x4a, 0x4a, 0x40, 0x02, 0xa9, 0x49, 0x8b, 0x92, 0xb2, 0x91, 0x42, + 0x05, 0xd0, 0x07, 0x9a, 0x11, 0x00, 0x17, 0x4a, 0x91, 0x42, 0x20, 0xd1, + 0x07, 0x93, 0x02, 0x22, 0x1b, 0x03, 0x09, 0xae, 0x00, 0x92, 0xfe, 0x33, + 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x49, 0xfc, + 0x00, 0x28, 0x13, 0xdb, 0x33, 0x88, 0x0e, 0x4a, 0x93, 0x42, 0x09, 0xd0, + 0x1a, 0x1c, 0xab, 0x42, 0x00, 0xd9, 0x2a, 0x1c, 0x95, 0xb2, 0x1a, 0x1c, + 0xbb, 0x42, 0x00, 0xd2, 0x3a, 0x1c, 0x97, 0xb2, 0x08, 0xaa, 0x13, 0x88, + 0x01, 0x33, 0x13, 0x80, 0x96, 0xe7, 0x0a, 0x48, 0x0b, 0xb0, 0xf0, 0xbd, + 0x07, 0x99, 0x20, 0x00, 0xff, 0xf7, 0x4c, 0xff, 0x00, 0x28, 0xa0, 0xda, + 0xf6, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0xff, 0x7f, 0x00, 0x00, + 0xc9, 0x49, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, 0x29, 0x04, 0x00, 0x00, + 0xd7, 0xd8, 0xff, 0xff, 0x10, 0xb5, 0x86, 0xb0, 0x09, 0x9c, 0x00, 0x93, + 0x05, 0x94, 0x08, 0x9c, 0x01, 0x23, 0x04, 0x94, 0x00, 0x24, 0x03, 0x94, + 0x02, 0x94, 0x01, 0x94, 0xff, 0xf7, 0x68, 0xfe, 0x02, 0x4b, 0x98, 0x42, + 0x00, 0xd1, 0x02, 0x48, 0x06, 0xb0, 0x10, 0xbd, 0xa8, 0xd8, 0xff, 0xff, + 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x1e, 0x00, 0x03, 0x00, 0x85, 0xb0, + 0x03, 0x92, 0x40, 0x33, 0x0f, 0x00, 0x19, 0x78, 0x04, 0x00, 0x0a, 0x9d, + 0x00, 0x29, 0x0b, 0xd0, 0x01, 0x95, 0x00, 0x96, 0x12, 0x4b, 0x03, 0x9a, + 0x39, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xd4, 0xff, 0x00, 0x28, 0x10, 0xd0, + 0x05, 0xb0, 0xf0, 0xbd, 0x43, 0x6b, 0x01, 0x2b, 0xf0, 0xd8, 0xfe, 0xf7, + 0x49, 0xfd, 0x0c, 0x4b, 0x98, 0x42, 0x01, 0xd0, 0x00, 0x28, 0xf3, 0xdb, + 0x63, 0x6b, 0x01, 0x2b, 0xe6, 0xd8, 0x09, 0x48, 0xee, 0xe7, 0x33, 0x88, + 0x23, 0x82, 0x2b, 0x68, 0x01, 0x33, 0x63, 0x61, 0x2b, 0x68, 0x00, 0x2b, + 0xe6, 0xd1, 0x63, 0x6b, 0x01, 0x3b, 0x63, 0x63, 0xe2, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xd3, 0xd8, 0xff, 0xff, 0xef, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x1e, 0x27, 0x8b, 0xb0, 0x6f, 0x44, 0x07, 0xae, 0x3a, 0x80, + 0x33, 0x80, 0x04, 0x00, 0x0d, 0x00, 0xc2, 0x69, 0x01, 0x8b, 0x00, 0x20, + 0x83, 0x42, 0x00, 0xd0, 0x30, 0x00, 0x22, 0x26, 0x09, 0xab, 0x05, 0x93, + 0x0f, 0x4b, 0x6e, 0x44, 0x02, 0x90, 0x01, 0x93, 0x04, 0x96, 0x01, 0x23, + 0x03, 0x97, 0x00, 0x95, 0x20, 0x00, 0xff, 0xf7, 0x07, 0xfe, 0x0b, 0x4b, + 0x98, 0x42, 0x0f, 0xd0, 0x00, 0x28, 0x0b, 0xdb, 0x10, 0x9b, 0x31, 0x88, + 0x09, 0x9a, 0x00, 0x2b, 0x04, 0xd0, 0x0b, 0x01, 0x9b, 0x18, 0x10, 0x9d, + 0x01, 0x33, 0x2b, 0x80, 0x21, 0x83, 0xe2, 0x61, 0x0b, 0xb0, 0xf0, 0xbd, + 0x02, 0x48, 0xfb, 0xe7, 0xc5, 0x47, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x1e, 0x27, 0x8b, 0xb0, 0x6f, 0x44, + 0x07, 0xae, 0x3a, 0x80, 0x33, 0x80, 0x04, 0x00, 0x0d, 0x00, 0xc2, 0x69, + 0x01, 0x8b, 0x00, 0x20, 0x83, 0x42, 0x00, 0xd0, 0x30, 0x00, 0x22, 0x26, + 0x09, 0xab, 0x05, 0x93, 0x0f, 0x4b, 0x6e, 0x44, 0x02, 0x90, 0x01, 0x93, + 0x04, 0x96, 0x02, 0x23, 0x03, 0x97, 0x00, 0x95, 0x20, 0x00, 0xff, 0xf7, + 0xcf, 0xfd, 0x0b, 0x4b, 0x98, 0x42, 0x0f, 0xd0, 0x00, 0x28, 0x0b, 0xdb, + 0x10, 0x9b, 0x31, 0x88, 0x09, 0x9a, 0x00, 0x2b, 0x04, 0xd0, 0x0b, 0x01, + 0x9b, 0x18, 0x10, 0x9d, 0x01, 0x33, 0x2b, 0x80, 0x21, 0x83, 0xe2, 0x61, + 0x0b, 0xb0, 0xf0, 0xbd, 0x02, 0x48, 0xfb, 0xe7, 0xc5, 0x47, 0x00, 0x00, + 0xa8, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0e, 0x27, + 0x12, 0x26, 0x89, 0xb0, 0x03, 0x93, 0x10, 0xab, 0x1b, 0x78, 0x15, 0x00, + 0x04, 0x93, 0x02, 0xab, 0xff, 0x18, 0x39, 0x80, 0xf6, 0x18, 0x07, 0xab, + 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x33, 0x00, 0x04, 0x00, 0xff, 0xf7, + 0x41, 0xff, 0x00, 0x28, 0x67, 0xdb, 0x33, 0x88, 0x07, 0x9a, 0x1b, 0x03, + 0x52, 0x00, 0x9b, 0x18, 0x02, 0x22, 0x01, 0x97, 0x00, 0x92, 0x04, 0x21, + 0x00, 0x22, 0x20, 0x00, 0xfd, 0xf7, 0x9b, 0xfb, 0x00, 0x28, 0x58, 0xdb, + 0x01, 0x22, 0xa3, 0x6b, 0x07, 0x21, 0x01, 0x33, 0xa3, 0x63, 0x2b, 0x79, + 0x20, 0x00, 0x93, 0x43, 0x2b, 0x71, 0x07, 0x9b, 0x9b, 0x18, 0x32, 0x88, + 0x1b, 0x02, 0x12, 0x03, 0x9b, 0x18, 0x05, 0x22, 0x01, 0x95, 0x00, 0x92, + 0x00, 0x22, 0xfd, 0xf7, 0x84, 0xfb, 0x00, 0x28, 0x41, 0xdb, 0x03, 0x9b, + 0x00, 0x2b, 0x13, 0xd0, 0x07, 0x9b, 0x32, 0x88, 0x01, 0x33, 0x12, 0x03, + 0x1b, 0x02, 0x9b, 0x18, 0x0f, 0x9a, 0x05, 0x33, 0x9b, 0x18, 0x03, 0x9a, + 0x07, 0x21, 0x01, 0x92, 0x0e, 0x9a, 0x20, 0x00, 0x00, 0x92, 0x00, 0x22, + 0xfd, 0xf7, 0x6d, 0xfb, 0x00, 0x28, 0x2a, 0xdb, 0x04, 0x9b, 0x00, 0x2b, + 0x1a, 0xd0, 0x02, 0x22, 0x2b, 0x79, 0x13, 0x42, 0x16, 0xd0, 0x93, 0x43, + 0x02, 0xa9, 0x10, 0x32, 0x2b, 0x71, 0x52, 0x18, 0x07, 0x9b, 0x12, 0x88, + 0x01, 0x33, 0x12, 0x03, 0x1b, 0x02, 0x9b, 0x18, 0x01, 0x22, 0x04, 0x35, + 0x00, 0x92, 0x04, 0x33, 0x01, 0x95, 0x00, 0x22, 0x07, 0x21, 0x20, 0x00, + 0xfd, 0xf7, 0x4f, 0xfb, 0x00, 0x28, 0x0c, 0xdb, 0x11, 0x9b, 0x00, 0x2b, + 0x09, 0xd0, 0x12, 0x23, 0x02, 0xaa, 0x9b, 0x18, 0x1b, 0x88, 0x07, 0x9a, + 0x1b, 0x01, 0xd3, 0x18, 0x11, 0x9a, 0x01, 0x33, 0x13, 0x80, 0x09, 0xb0, + 0xf0, 0xbd, 0x00, 0x00, 0x7f, 0xb5, 0x0e, 0x22, 0x00, 0x26, 0x0f, 0x23, + 0x0c, 0x00, 0x6a, 0x44, 0x16, 0x80, 0x01, 0x92, 0x02, 0x22, 0x0b, 0x40, + 0x11, 0x49, 0x00, 0x92, 0x5b, 0x18, 0x21, 0x09, 0x09, 0x03, 0x5b, 0x00, + 0x5b, 0x18, 0x32, 0x00, 0x31, 0x00, 0x05, 0x00, 0xfd, 0xf7, 0x27, 0xfb, + 0xb0, 0x42, 0x13, 0xdb, 0xeb, 0x6b, 0x0d, 0x22, 0x01, 0x33, 0xeb, 0x63, + 0xab, 0x6b, 0x6a, 0x44, 0x01, 0x3b, 0xab, 0x63, 0x7e, 0x23, 0x13, 0x70, + 0x01, 0x92, 0x01, 0x22, 0x24, 0x02, 0x00, 0x92, 0x23, 0x1d, 0x32, 0x00, + 0x03, 0x21, 0x28, 0x00, 0xfd, 0xf7, 0x11, 0xfb, 0x04, 0xb0, 0x70, 0xbd, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x89, 0xb0, 0x15, 0x00, 0x0e, 0xaa, + 0x03, 0x91, 0x02, 0xca, 0x12, 0x24, 0x12, 0x88, 0x02, 0x91, 0x04, 0x92, + 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x13, 0x80, 0x07, 0xab, 0x64, 0x18, + 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x23, 0x00, 0x06, 0x00, 0x10, 0x9f, + 0xff, 0xf7, 0x8c, 0xfe, 0x00, 0x28, 0x5f, 0xdb, 0x24, 0x88, 0x07, 0x9b, + 0x24, 0x01, 0x1c, 0x19, 0x01, 0x34, 0xa4, 0xb2, 0x00, 0x2f, 0x00, 0xd0, + 0x3c, 0x80, 0x27, 0x02, 0x00, 0x2d, 0x1e, 0xd1, 0x80, 0x22, 0x04, 0x9b, + 0x52, 0x00, 0x1b, 0x02, 0x00, 0x92, 0x03, 0x99, 0x3a, 0x00, 0x30, 0x00, + 0xff, 0xf7, 0xa8, 0xfc, 0x00, 0x23, 0x02, 0x9d, 0x02, 0x93, 0x24, 0xe0, + 0x03, 0x22, 0x2b, 0x79, 0x04, 0x35, 0x93, 0x43, 0x2b, 0x70, 0x02, 0x3a, + 0x00, 0x92, 0x3b, 0x1d, 0x01, 0x95, 0x03, 0x9a, 0x07, 0x21, 0x30, 0x00, + 0xfd, 0xf7, 0xcb, 0xfa, 0x00, 0x28, 0x31, 0xda, 0x34, 0xe0, 0x01, 0x22, + 0x2b, 0x79, 0x10, 0x00, 0x59, 0x08, 0x93, 0x43, 0x92, 0x18, 0x13, 0x43, + 0x2b, 0x71, 0x80, 0x23, 0x88, 0x43, 0x5b, 0x00, 0x02, 0x90, 0x00, 0x93, + 0x01, 0x95, 0x3b, 0x00, 0x00, 0x22, 0x07, 0x21, 0x30, 0x00, 0xfd, 0xf7, + 0xb4, 0xfa, 0x00, 0x28, 0x1e, 0xdb, 0x0f, 0x23, 0x0f, 0x4a, 0x23, 0x40, + 0x9b, 0x18, 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, + 0x24, 0x09, 0x5b, 0x00, 0x24, 0x03, 0x00, 0x92, 0x1b, 0x19, 0x00, 0x22, + 0x04, 0x21, 0x30, 0x00, 0xfd, 0xf7, 0x9f, 0xfa, 0x00, 0x28, 0x09, 0xdb, + 0xb3, 0x6b, 0x01, 0x33, 0xb3, 0x63, 0x02, 0x9b, 0x00, 0x2b, 0xbd, 0xd1, + 0x04, 0x99, 0x30, 0x00, 0xff, 0xf7, 0x56, 0xff, 0x09, 0xb0, 0xf0, 0xbd, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x87, 0xb0, 0x04, 0x93, 0x0c, 0xab, + 0x1b, 0x88, 0x07, 0x00, 0x00, 0x93, 0x0d, 0xab, 0x1b, 0x88, 0x15, 0x00, + 0x03, 0x93, 0x04, 0x9b, 0x05, 0x91, 0x5b, 0x04, 0x5b, 0x0c, 0x02, 0x93, + 0x83, 0x6a, 0x1e, 0x1d, 0x00, 0x23, 0x34, 0x00, 0x01, 0x93, 0xfb, 0x6a, + 0x01, 0x9a, 0x93, 0x42, 0x08, 0xd8, 0x01, 0x2d, 0x00, 0xd8, 0x6e, 0xe0, + 0x3c, 0x6d, 0x00, 0x2c, 0x00, 0xd0, 0x6c, 0xe0, 0x07, 0xb0, 0xf0, 0xbd, + 0x43, 0x4a, 0x63, 0x88, 0x13, 0x40, 0x02, 0x9a, 0x93, 0x42, 0x38, 0xd1, + 0x00, 0x9b, 0x00, 0x2b, 0x2b, 0xd1, 0x02, 0x2d, 0x38, 0xd0, 0xa3, 0x8c, + 0x00, 0x2b, 0x30, 0xd0, 0x6b, 0x46, 0x9b, 0x89, 0x23, 0x81, 0x0e, 0x9b, + 0x00, 0x2b, 0x20, 0xd0, 0x0e, 0x9a, 0x63, 0x60, 0xe1, 0x69, 0x00, 0x9b, + 0x01, 0x32, 0x09, 0xd0, 0x0e, 0x9b, 0x00, 0x29, 0x06, 0xd0, 0xca, 0x68, + 0x0b, 0x8a, 0x9b, 0x18, 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd2, 0x13, 0x00, + 0x22, 0x69, 0x9a, 0x42, 0x00, 0xd9, 0x23, 0x61, 0x62, 0x69, 0x9a, 0x42, + 0x00, 0xd9, 0x63, 0x61, 0x00, 0x29, 0x06, 0xd0, 0xca, 0x68, 0x01, 0x33, + 0x9a, 0x42, 0x02, 0xd9, 0x38, 0x00, 0xfd, 0xf7, 0x91, 0xfa, 0xa3, 0x89, + 0x00, 0x9a, 0x93, 0x42, 0x05, 0xd1, 0x00, 0x23, 0x02, 0x2d, 0x01, 0xd0, + 0x6b, 0x46, 0x9b, 0x89, 0x63, 0x81, 0x01, 0x9b, 0x30, 0x34, 0x01, 0x33, + 0x01, 0x93, 0xae, 0xe7, 0x00, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x05, 0xd0, + 0xe1, 0x69, 0x00, 0x29, 0x02, 0xd0, 0x38, 0x00, 0xfd, 0xf7, 0x78, 0xfa, + 0x00, 0x23, 0x23, 0x80, 0x63, 0x80, 0xe2, 0xe7, 0x00, 0x22, 0xb3, 0x5e, + 0x00, 0x2b, 0x0c, 0xd0, 0xb0, 0x6a, 0x00, 0x28, 0x09, 0xd0, 0x17, 0x4a, + 0x73, 0x88, 0x13, 0x40, 0x02, 0x9a, 0x93, 0x42, 0x03, 0xd1, 0x05, 0x9a, + 0x00, 0x99, 0xff, 0xf7, 0xd1, 0xfa, 0x01, 0x34, 0x30, 0x36, 0xfb, 0x6a, + 0xa3, 0x42, 0xe9, 0xd8, 0x90, 0xe7, 0x00, 0x24, 0xf9, 0xe7, 0x00, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x8e, 0xe7, 0x6b, 0x46, 0x10, 0x22, 0x9b, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0x88, 0xe7, 0x00, 0x99, 0x01, 0x2d, 0x08, 0xd0, + 0x00, 0x2d, 0x0b, 0xd0, 0xeb, 0x1e, 0x01, 0x2b, 0x08, 0xd9, 0x29, 0x00, + 0x02, 0x2d, 0x00, 0xd0, 0x7c, 0xe7, 0x03, 0x9b, 0x02, 0x9a, 0x38, 0x00, + 0xa0, 0x47, 0x77, 0xe7, 0x01, 0x21, 0xf8, 0xe7, 0xff, 0x7f, 0xff, 0xff, + 0xf0, 0xb5, 0x16, 0x27, 0x97, 0xb0, 0x1c, 0xab, 0x1b, 0x78, 0x04, 0x00, + 0x06, 0x93, 0x02, 0xab, 0xff, 0x18, 0x39, 0x80, 0xfb, 0x21, 0x05, 0x92, + 0xfe, 0xf7, 0x34, 0xfe, 0x05, 0x1e, 0x65, 0xdb, 0x3a, 0x88, 0x34, 0x4b, + 0x20, 0x00, 0x13, 0x43, 0x3b, 0x80, 0x09, 0xab, 0x00, 0x93, 0x1a, 0x23, + 0x02, 0xaa, 0x9b, 0x18, 0x21, 0x8a, 0x62, 0x69, 0xff, 0xf7, 0x5c, 0xfd, + 0x05, 0x1e, 0x55, 0xdb, 0x02, 0xab, 0x5b, 0x8b, 0x09, 0x9a, 0x1b, 0x03, + 0x52, 0x00, 0x9b, 0x18, 0x02, 0x22, 0x01, 0x97, 0x00, 0x92, 0x04, 0x21, + 0x00, 0x22, 0x20, 0x00, 0xfd, 0xf7, 0xb5, 0xf9, 0x05, 0x1e, 0x45, 0xdb, + 0xa3, 0x6b, 0x0a, 0xae, 0x01, 0x33, 0xa3, 0x63, 0x3b, 0x88, 0x2d, 0x20, + 0x33, 0x80, 0x00, 0x23, 0x73, 0x80, 0xf8, 0x33, 0x33, 0x71, 0x6b, 0x46, + 0x19, 0x7e, 0x02, 0xab, 0x31, 0x73, 0x01, 0x21, 0x49, 0x42, 0x0c, 0x91, + 0x20, 0x22, 0x05, 0x99, 0xc0, 0x18, 0x02, 0xf0, 0x93, 0xfb, 0x09, 0x98, + 0x07, 0x21, 0x43, 0x1c, 0x02, 0xa8, 0x42, 0x8b, 0x1b, 0x02, 0x12, 0x03, + 0x9b, 0x18, 0x2e, 0x22, 0x01, 0x96, 0x00, 0x92, 0x20, 0x00, 0x00, 0x22, + 0xfd, 0xf7, 0x8d, 0xf9, 0x05, 0x1e, 0x1d, 0xdb, 0x01, 0x21, 0x49, 0x42, + 0x3b, 0x88, 0x02, 0x91, 0x02, 0xa9, 0x4a, 0x8b, 0x09, 0x99, 0x12, 0x01, + 0x8a, 0x18, 0x01, 0x32, 0x92, 0xb2, 0x01, 0x92, 0x00, 0x22, 0x31, 0x00, + 0x00, 0x92, 0x20, 0x00, 0x01, 0x32, 0xff, 0xf7, 0xe9, 0xfe, 0x1d, 0x9b, + 0x00, 0x2b, 0x07, 0xd0, 0x02, 0xab, 0x5b, 0x8b, 0x09, 0x9a, 0x1b, 0x01, + 0xd3, 0x18, 0x1d, 0x9a, 0x01, 0x33, 0x13, 0x80, 0x28, 0x00, 0x17, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, 0xf0, 0xb5, 0x89, 0xb0, + 0x05, 0x93, 0x80, 0x23, 0x0e, 0x9c, 0x1b, 0x02, 0x1a, 0x43, 0x06, 0x00, + 0x0f, 0x00, 0x04, 0x92, 0x00, 0x2c, 0x0e, 0xd1, 0x04, 0x21, 0x7a, 0x5e, + 0x41, 0x6a, 0x05, 0x9b, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, + 0x1b, 0x02, 0xea, 0x39, 0xfd, 0xf7, 0xeb, 0xf8, 0x05, 0x1e, 0x4e, 0xdb, + 0x74, 0x6a, 0x23, 0x79, 0xda, 0x07, 0x4d, 0xd4, 0x5a, 0xb2, 0x00, 0x2a, + 0x4c, 0xda, 0x9a, 0x07, 0x4c, 0xd4, 0x5b, 0x07, 0x4c, 0xd4, 0x63, 0x88, + 0x00, 0x2b, 0x4b, 0xd1, 0x0f, 0x9b, 0x00, 0x2b, 0x05, 0xd0, 0x20, 0x00, + 0x20, 0x22, 0x19, 0x00, 0x0d, 0x30, 0x02, 0xf0, 0x2d, 0xfb, 0x11, 0x9b, + 0x00, 0x2b, 0x03, 0xd0, 0x23, 0x81, 0x11, 0x9b, 0x1b, 0x0c, 0x63, 0x81, + 0x39, 0x1e, 0x01, 0xd0, 0x04, 0x23, 0xf9, 0x5e, 0x16, 0x23, 0x02, 0xaa, + 0x9b, 0x18, 0x02, 0x93, 0x05, 0x9b, 0x22, 0x00, 0x01, 0x93, 0x00, 0x23, + 0x30, 0x00, 0x00, 0x93, 0x04, 0x9b, 0xff, 0xf7, 0x11, 0xfe, 0x05, 0x1e, + 0x1d, 0xd1, 0x02, 0xab, 0xd9, 0x8a, 0x12, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0x19, 0x80, 0x0e, 0x9a, 0x20, 0x89, 0x53, 0x42, 0x5a, 0x41, 0x63, 0x89, + 0x01, 0x91, 0x1b, 0x04, 0x03, 0x43, 0x02, 0x93, 0x63, 0x88, 0x92, 0x00, + 0x00, 0x93, 0x21, 0x00, 0x04, 0x9b, 0x30, 0x00, 0xff, 0xf7, 0x76, 0xfe, + 0x00, 0x2f, 0x04, 0xd0, 0x16, 0x23, 0x02, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0xbb, 0x81, 0x28, 0x00, 0x09, 0xb0, 0xf0, 0xbd, 0x04, 0x4d, 0xfa, 0xe7, + 0x04, 0x4d, 0xf8, 0xe7, 0x04, 0x4d, 0xf6, 0xe7, 0x04, 0x4d, 0xf4, 0xe7, + 0x04, 0x4d, 0xf2, 0xe7, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x93, 0xb0, 0x03, 0x93, 0x0d, 0x00, 0x0b, 0x02, 0x14, 0x00, + 0x04, 0x21, 0x52, 0x5e, 0x2e, 0x21, 0x06, 0xae, 0x00, 0x91, 0x01, 0x96, + 0x18, 0x39, 0x07, 0x00, 0xfd, 0xf7, 0x73, 0xf8, 0x00, 0x28, 0x33, 0xdb, + 0x0f, 0x23, 0x2b, 0x40, 0x2a, 0x09, 0x01, 0x3b, 0x12, 0x03, 0x5b, 0x00, + 0x9b, 0x18, 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, + 0x14, 0x21, 0x00, 0x92, 0x38, 0x00, 0x00, 0x22, 0xfd, 0xf7, 0x5f, 0xf8, + 0xa5, 0x81, 0x27, 0x60, 0xb3, 0x68, 0x6a, 0x46, 0xa3, 0x60, 0x00, 0x23, + 0x63, 0x61, 0x23, 0x82, 0x02, 0xab, 0xe5, 0x81, 0xdb, 0x89, 0x95, 0x89, + 0xe3, 0x80, 0xa5, 0x83, 0x32, 0x79, 0xd4, 0x07, 0x0f, 0xd4, 0x51, 0xb2, + 0x00, 0x29, 0x0f, 0xda, 0x02, 0x21, 0x0a, 0x42, 0x0e, 0xd1, 0x52, 0x07, + 0x0e, 0xd4, 0x1b, 0xb2, 0x00, 0x2b, 0x0b, 0xda, 0x73, 0x88, 0x00, 0x2b, + 0x02, 0xd0, 0x05, 0x48, 0x00, 0xe0, 0x05, 0x48, 0x13, 0xb0, 0xf0, 0xbd, + 0x04, 0x48, 0xfb, 0xe7, 0x04, 0x48, 0xf9, 0xe7, 0x04, 0x48, 0xf7, 0xe7, + 0xe3, 0xd8, 0xff, 0xff, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x95, 0xb0, + 0x0e, 0x93, 0x07, 0x68, 0x0d, 0x00, 0x0e, 0x99, 0x83, 0x68, 0x06, 0x00, + 0xfb, 0x31, 0x38, 0x00, 0x0f, 0x92, 0x06, 0x93, 0xfe, 0xf7, 0xe0, 0xfc, + 0x04, 0x1e, 0x00, 0xda, 0x0b, 0xe2, 0x06, 0x9b, 0x0a, 0x93, 0xab, 0x42, + 0x00, 0xd9, 0x0a, 0x95, 0x7b, 0x6a, 0xb2, 0x89, 0x06, 0x93, 0x10, 0xab, + 0x1a, 0x80, 0xfb, 0x21, 0x0a, 0x98, 0x02, 0xf0, 0x95, 0xf9, 0xfb, 0x21, + 0x83, 0xb2, 0x0a, 0x98, 0x09, 0x93, 0x02, 0xf0, 0x15, 0xfa, 0x4e, 0x4b, + 0x0c, 0x91, 0x0b, 0x93, 0x00, 0x23, 0x07, 0x93, 0x08, 0x93, 0x9c, 0x42, + 0x00, 0xd1, 0x2e, 0xe1, 0x0a, 0x9a, 0x08, 0x9b, 0x94, 0x46, 0x63, 0x44, + 0x09, 0x93, 0xb3, 0x60, 0x73, 0x61, 0x6b, 0x46, 0x9b, 0x8b, 0x10, 0xad, + 0x2a, 0x88, 0x33, 0x82, 0x07, 0x9b, 0xf2, 0x81, 0x00, 0x2b, 0x00, 0xd1, + 0x26, 0xe2, 0x31, 0x00, 0x38, 0x00, 0xff, 0xf7, 0x31, 0xf8, 0x00, 0x28, + 0x31, 0xdb, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfd, 0xf7, 0x3d, 0xf8, 0x00, 0x28, 0x22, 0xdb, 0x00, 0x22, 0x02, 0x92, + 0x2a, 0x88, 0x06, 0x98, 0x01, 0x92, 0xc2, 0x78, 0x81, 0x78, 0x12, 0x02, + 0x0a, 0x43, 0x00, 0x92, 0xf3, 0x88, 0x00, 0x22, 0x79, 0x6a, 0x38, 0x00, + 0xff, 0xf7, 0x9c, 0xfd, 0x1a, 0x21, 0x0a, 0xa8, 0x09, 0x18, 0x04, 0x91, + 0x00, 0x21, 0x09, 0x98, 0xb3, 0x89, 0xf2, 0x88, 0x03, 0x90, 0x02, 0x91, + 0x01, 0x91, 0x00, 0x91, 0x38, 0x00, 0x31, 0x00, 0xff, 0xf7, 0xb4, 0xfe, + 0x00, 0x28, 0x00, 0xdb, 0xa5, 0xe1, 0x04, 0x00, 0xa3, 0xe1, 0x1a, 0x20, + 0x03, 0x91, 0x0a, 0xac, 0x0b, 0x99, 0x00, 0x19, 0x04, 0x90, 0x02, 0x91, + 0x01, 0x91, 0x79, 0x6a, 0xb3, 0x89, 0xf2, 0x88, 0x00, 0x91, 0x31, 0x00, + 0x38, 0x00, 0xff, 0xf7, 0x9f, 0xfe, 0x11, 0xe1, 0x10, 0xad, 0x2a, 0x88, + 0x0b, 0x9b, 0x31, 0x00, 0x38, 0x00, 0xfe, 0xf7, 0xe3, 0xff, 0x04, 0x1e, + 0x00, 0xda, 0x88, 0xe1, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, + 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, + 0x38, 0x00, 0xfc, 0xf7, 0xee, 0xff, 0x04, 0x1e, 0x00, 0xda, 0x78, 0xe1, + 0x00, 0x24, 0x02, 0x94, 0x2a, 0x88, 0xf3, 0x88, 0x01, 0x92, 0x06, 0x9a, + 0x38, 0x00, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, 0x00, 0x92, + 0x79, 0x6a, 0x22, 0x00, 0xff, 0xf7, 0x4c, 0xfd, 0x1a, 0x21, 0x0a, 0xa8, + 0x09, 0x18, 0x04, 0x91, 0x0a, 0x98, 0x08, 0x99, 0xb3, 0x89, 0x09, 0x18, + 0xf2, 0x88, 0x03, 0x91, 0x02, 0x94, 0x01, 0x94, 0x00, 0x94, 0xc2, 0xe7, + 0xff, 0xff, 0x00, 0x00, 0xb3, 0x68, 0x58, 0x1e, 0xc6, 0x4b, 0x98, 0x42, + 0x0f, 0xd9, 0x08, 0x9b, 0x00, 0x2b, 0x0c, 0xd1, 0xfb, 0x21, 0x02, 0xf0, + 0xe5, 0xf8, 0x7c, 0x21, 0x69, 0x38, 0x02, 0xf0, 0xe1, 0xf8, 0x07, 0x9b, + 0x01, 0x30, 0x80, 0xb2, 0x83, 0x42, 0x00, 0xd8, 0xfb, 0xe0, 0x80, 0x23, + 0xf1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x6b, 0x46, 0x9b, 0x8b, 0x12, 0xad, + 0x6b, 0x80, 0xf9, 0x23, 0x2b, 0x71, 0x10, 0xab, 0x29, 0x80, 0x03, 0x93, + 0x01, 0x23, 0x02, 0x93, 0x00, 0x23, 0x2a, 0x00, 0x01, 0x93, 0x00, 0x93, + 0x38, 0x00, 0xff, 0xf7, 0xe1, 0xfb, 0x04, 0x1e, 0x00, 0xda, 0x2a, 0xe1, + 0x80, 0x22, 0xff, 0x21, 0x52, 0x00, 0x78, 0x6a, 0x02, 0xf0, 0x75, 0xf9, + 0x05, 0x22, 0x29, 0x00, 0x78, 0x6a, 0x02, 0xf0, 0x67, 0xf9, 0x00, 0x22, + 0x02, 0x92, 0x0a, 0xaa, 0x12, 0x8b, 0xf3, 0x88, 0x01, 0x92, 0x07, 0x9a, + 0x38, 0x00, 0x00, 0x92, 0x79, 0x6a, 0x01, 0x22, 0xff, 0xf7, 0xf6, 0xfc, + 0x10, 0xab, 0x1b, 0x88, 0x0a, 0x9a, 0xf3, 0x81, 0x6b, 0x46, 0x9b, 0x8b, + 0x33, 0x82, 0x08, 0x9b, 0x9b, 0x18, 0x73, 0x61, 0xb3, 0x60, 0x07, 0x9b, + 0x0b, 0x93, 0x08, 0x9a, 0x0e, 0x9b, 0x0c, 0x99, 0x9b, 0x1a, 0xfb, 0x22, + 0x52, 0x1a, 0x0d, 0x92, 0x9a, 0x42, 0x00, 0xd9, 0x0d, 0x93, 0x0c, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0xfa, 0xe0, 0x6b, 0x46, 0x9b, 0x8c, 0x12, 0xaa, + 0xf1, 0x88, 0x53, 0x80, 0xfd, 0x23, 0x08, 0x98, 0x13, 0x71, 0x0f, 0x9b, + 0x49, 0x04, 0x49, 0x0c, 0x1b, 0x18, 0x11, 0xa8, 0x11, 0x80, 0x03, 0x90, + 0x01, 0x20, 0x02, 0x90, 0x0c, 0x98, 0x01, 0x90, 0x0d, 0x98, 0x00, 0x90, + 0x38, 0x00, 0xff, 0xf7, 0x93, 0xfb, 0x04, 0x1e, 0x00, 0xd0, 0xed, 0xe6, + 0x11, 0xab, 0x1d, 0x88, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x11, 0xe1, + 0x09, 0x9b, 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9d, 0x52, 0x0a, 0x9a, + 0x08, 0x9b, 0x9b, 0x18, 0x06, 0x9a, 0x13, 0x81, 0x1b, 0x0c, 0x53, 0x81, + 0x0d, 0x9a, 0x09, 0x98, 0x94, 0x46, 0x01, 0x30, 0x83, 0xb2, 0x09, 0x93, + 0x08, 0x9b, 0x63, 0x44, 0x08, 0x93, 0x00, 0x23, 0x0c, 0x93, 0x08, 0x9b, + 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd3, 0xcb, 0xe6, 0x00, 0x23, 0x07, 0x93, + 0x09, 0x9b, 0x68, 0x2b, 0x07, 0xd9, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x02, 0xf0, 0x48, 0xf8, 0x01, 0x30, 0x83, 0xb2, 0x07, 0x93, 0x0b, 0x9b, + 0x07, 0x9a, 0x93, 0x42, 0xa3, 0xd0, 0x08, 0x9b, 0x00, 0x2b, 0x2d, 0xd0, + 0x0b, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x0f, 0xe7, 0x08, 0x9b, 0x0a, 0x9a, + 0x99, 0x18, 0x06, 0x9b, 0x06, 0x9a, 0x19, 0x81, 0x0b, 0x0c, 0x53, 0x81, + 0x0a, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0xf2, 0xe6, 0x10, 0xad, 0x2a, 0x88, + 0x31, 0x00, 0x38, 0x00, 0xfe, 0xf7, 0xe8, 0xfe, 0x04, 0x1e, 0x00, 0xda, + 0x8d, 0xe0, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfc, 0xf7, 0xf3, 0xfe, 0x04, 0x1e, 0x00, 0xda, 0x7d, 0xe0, 0x08, 0x9b, + 0x0a, 0x9a, 0x9b, 0x18, 0xb3, 0x60, 0x73, 0x61, 0x07, 0x9b, 0x00, 0x2b, + 0x00, 0xd0, 0x1b, 0xe7, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x10, 0xab, + 0x1b, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, + 0xea, 0x39, 0x38, 0x00, 0xfc, 0xf7, 0x75, 0xfe, 0x04, 0x1e, 0x64, 0xdb, + 0x01, 0x22, 0x06, 0x9b, 0x1b, 0x79, 0x13, 0x42, 0x00, 0xd0, 0xe9, 0xe0, + 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xe7, 0xe0, 0x9a, 0x07, 0x00, 0xd5, + 0xe6, 0xe0, 0x5b, 0x07, 0x00, 0xd5, 0xe5, 0xe0, 0x06, 0x22, 0xb3, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0xe0, 0xe0, 0x06, 0x9b, 0x5b, 0x88, 0x0b, 0x93, + 0x00, 0x2b, 0x00, 0xd1, 0x43, 0xe7, 0x41, 0x4c, 0x47, 0xe0, 0x33, 0x8a, + 0x07, 0x9a, 0x93, 0x42, 0x34, 0xd1, 0x1e, 0x23, 0xf2, 0x89, 0x0a, 0xa9, + 0x5b, 0x18, 0x1a, 0x80, 0x1e, 0x25, 0x0a, 0xab, 0x04, 0x21, 0x72, 0x5e, + 0x79, 0x6a, 0xed, 0x18, 0x2b, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, + 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x38, 0x00, 0xfc, 0xf7, 0x3d, 0xfe, + 0x04, 0x1e, 0x2c, 0xdb, 0x01, 0x22, 0x06, 0x9b, 0x1b, 0x79, 0x13, 0x42, + 0x00, 0xd0, 0xb1, 0xe0, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xaf, 0xe0, + 0x9a, 0x07, 0x00, 0xd5, 0xae, 0xe0, 0x5b, 0x07, 0x00, 0xd5, 0xad, 0xe0, + 0x06, 0x22, 0xb3, 0x5e, 0x00, 0x2b, 0x00, 0xdb, 0xa8, 0xe0, 0x06, 0x9b, + 0x07, 0x9a, 0x5b, 0x88, 0x93, 0x42, 0xc8, 0xd1, 0x2a, 0x88, 0x10, 0xab, + 0x1a, 0x80, 0xfb, 0xe6, 0x80, 0x23, 0xf1, 0x88, 0x1b, 0x02, 0x19, 0x43, + 0x1e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, 0x00, 0x93, 0x07, 0x9a, 0x08, 0x9b, + 0x38, 0x00, 0xff, 0xf7, 0x45, 0xfa, 0x04, 0x1e, 0xc0, 0xda, 0x20, 0x00, + 0x15, 0xb0, 0xf0, 0xbd, 0x07, 0x9b, 0x00, 0x2b, 0x21, 0xd1, 0x09, 0x9b, + 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9a, 0x5a, 0x11, 0xab, 0x1a, 0x80, + 0x11, 0xad, 0x2a, 0x88, 0x31, 0x1d, 0x09, 0x9b, 0x38, 0x00, 0xfe, 0xf7, + 0x97, 0xff, 0x04, 0x1e, 0xe9, 0xdb, 0x2b, 0x88, 0x0c, 0x9a, 0x1b, 0x02, + 0x05, 0x33, 0x08, 0x98, 0x9b, 0x18, 0x04, 0x21, 0x72, 0x5e, 0x0f, 0x99, + 0x09, 0x18, 0x01, 0x91, 0x0d, 0x99, 0x38, 0x00, 0x00, 0x91, 0x07, 0x21, + 0xfc, 0xf7, 0x4b, 0xfe, 0xf7, 0xe6, 0x09, 0x9b, 0x19, 0x1d, 0x68, 0x2b, + 0x05, 0xd9, 0x09, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0xec, 0xff, + 0x04, 0x31, 0x06, 0x9b, 0x49, 0x00, 0x5a, 0x5a, 0xd4, 0xe7, 0xc0, 0x46, + 0xf2, 0x66, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, 0x09, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x09, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0xd9, 0xff, 0x04, 0x31, 0x06, 0x9b, 0x49, 0x00, 0x5d, 0x52, 0xeb, 0xe6, + 0x0a, 0x9b, 0x00, 0x2b, 0x31, 0xd1, 0x69, 0x46, 0x06, 0x9b, 0x09, 0x8c, + 0x38, 0x00, 0x19, 0x81, 0x08, 0x9b, 0x06, 0x99, 0x1b, 0x0c, 0x4b, 0x81, + 0x0a, 0x9b, 0x31, 0x00, 0xfe, 0xf7, 0xfe, 0xfd, 0x00, 0x28, 0x00, 0xda, + 0xfd, 0xe5, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfc, 0xf7, 0x09, 0xfe, 0x00, 0x28, 0x00, 0xda, 0xed, 0xe5, 0x06, 0x9a, + 0xf3, 0x88, 0x11, 0x89, 0x52, 0x89, 0x38, 0x00, 0x12, 0x04, 0x0a, 0x43, + 0x02, 0x92, 0x2a, 0x88, 0x01, 0x92, 0x06, 0x9a, 0x52, 0x88, 0x00, 0x92, + 0x79, 0x6a, 0x04, 0x22, 0xff, 0xf7, 0x66, 0xfb, 0x81, 0xe7, 0x1a, 0x21, + 0x0a, 0xa8, 0x09, 0x18, 0x04, 0x91, 0x09, 0x99, 0xb3, 0x89, 0x03, 0x91, + 0x07, 0x99, 0xf2, 0x88, 0x02, 0x91, 0x01, 0x91, 0x79, 0x6a, 0xc6, 0xe5, + 0x03, 0x4c, 0x72, 0xe7, 0x03, 0x4c, 0x70, 0xe7, 0x03, 0x4c, 0x6e, 0xe7, + 0x03, 0x4c, 0x6c, 0xe7, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x95, 0xb0, + 0x0d, 0x91, 0x19, 0x00, 0x05, 0x68, 0x07, 0x00, 0xfb, 0x31, 0x28, 0x00, + 0x0f, 0x92, 0x0e, 0x93, 0xfe, 0xf7, 0x2a, 0xfa, 0x04, 0x1e, 0x00, 0xda, + 0x6e, 0xe1, 0x6b, 0x6a, 0xfb, 0x21, 0x07, 0x93, 0xbb, 0x89, 0x0d, 0x98, + 0x0b, 0x93, 0x01, 0xf0, 0xe5, 0xfe, 0xfb, 0x21, 0x83, 0xb2, 0x0d, 0x98, + 0x08, 0x93, 0x01, 0xf0, 0x65, 0xff, 0x00, 0x23, 0x0a, 0x91, 0xc1, 0x4e, + 0x06, 0x93, 0x09, 0x93, 0x9c, 0x42, 0x00, 0xd1, 0x2c, 0xe1, 0x0d, 0x9a, + 0x09, 0x9b, 0x94, 0x46, 0x63, 0x44, 0x7b, 0x61, 0x6b, 0x46, 0x9b, 0x8d, + 0xfb, 0x81, 0x6b, 0x46, 0x1b, 0x8b, 0x3b, 0x82, 0x06, 0x9b, 0x00, 0x2b, + 0x00, 0xd1, 0xf4, 0xe1, 0x0b, 0x9a, 0x39, 0x00, 0x28, 0x00, 0xfe, 0xf7, + 0x83, 0xfd, 0x00, 0x28, 0x00, 0xda, 0xff, 0xe1, 0x04, 0x22, 0xb9, 0x5e, + 0x1e, 0x22, 0x00, 0x26, 0x0a, 0xa8, 0x12, 0x18, 0xfb, 0x88, 0x02, 0x92, + 0x0b, 0x9a, 0x00, 0x96, 0x01, 0x92, 0x28, 0x00, 0x07, 0x9a, 0xff, 0xf7, + 0x7f, 0xfa, 0x0a, 0xab, 0xda, 0x8b, 0x6b, 0x46, 0x1b, 0x8b, 0xfa, 0x81, + 0x3b, 0x82, 0xb0, 0x42, 0x00, 0xda, 0xe7, 0xe1, 0xfb, 0x88, 0x01, 0x92, + 0x07, 0x9a, 0x02, 0x96, 0x91, 0x78, 0xd2, 0x78, 0x28, 0x00, 0x12, 0x02, + 0x0a, 0x43, 0x00, 0x92, 0x07, 0x99, 0x32, 0x00, 0xff, 0xf7, 0xe6, 0xfa, + 0x1a, 0xe1, 0x00, 0x23, 0x06, 0x93, 0x33, 0x00, 0x0b, 0x9a, 0x39, 0x00, + 0x28, 0x00, 0xfe, 0xf7, 0x51, 0xfd, 0x04, 0x1e, 0x00, 0xda, 0x0f, 0xe1, + 0x04, 0x22, 0xb9, 0x5e, 0x1e, 0x22, 0x00, 0x26, 0x0a, 0xa8, 0x12, 0x18, + 0xfb, 0x88, 0x02, 0x92, 0x0b, 0x9a, 0x00, 0x96, 0x01, 0x92, 0x28, 0x00, + 0x07, 0x9a, 0xff, 0xf7, 0x4d, 0xfa, 0x04, 0x00, 0xb0, 0x42, 0x00, 0xda, + 0xfc, 0xe0, 0xfb, 0x88, 0x0a, 0xaa, 0x02, 0x96, 0xd2, 0x8b, 0x28, 0x00, + 0x01, 0x92, 0x07, 0x9a, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, + 0x00, 0x92, 0x07, 0x99, 0x32, 0x00, 0xff, 0xf7, 0xb7, 0xfa, 0x06, 0x9b, + 0xb3, 0x42, 0x29, 0xd1, 0x04, 0x21, 0x7a, 0x5e, 0x69, 0x6a, 0x0b, 0x9b, + 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, + 0x28, 0x00, 0xfc, 0xf7, 0xd2, 0xfc, 0x04, 0x1e, 0x00, 0xda, 0xd9, 0xe0, + 0x07, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x00, 0xd5, 0x94, 0xe1, 0x5a, 0xb2, + 0x00, 0x2a, 0x00, 0xdb, 0x92, 0xe1, 0x9a, 0x07, 0x00, 0xd5, 0x91, 0xe1, + 0x5b, 0x07, 0x00, 0xd5, 0x90, 0xe1, 0x06, 0x22, 0xbb, 0x5e, 0x00, 0x2b, + 0x00, 0xdb, 0x8b, 0xe1, 0x07, 0x9b, 0x5b, 0x88, 0x00, 0x2b, 0x39, 0xd0, + 0x73, 0x4c, 0xbf, 0xe0, 0x3b, 0x8a, 0x06, 0x9a, 0x93, 0x42, 0x00, 0xd0, + 0xbd, 0xe0, 0x1e, 0x23, 0xfa, 0x89, 0x0a, 0xa9, 0x5b, 0x18, 0x1a, 0x80, + 0x1e, 0x26, 0x04, 0x21, 0x7a, 0x5e, 0x0a, 0xab, 0x69, 0x6a, 0xf6, 0x18, + 0x33, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, + 0xea, 0x39, 0x28, 0x00, 0xfc, 0xf7, 0x9b, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0xa2, 0xe0, 0x07, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x00, 0xd5, 0x5d, 0xe1, + 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0x5b, 0xe1, 0x9a, 0x07, 0x00, 0xd5, + 0x5a, 0xe1, 0x5b, 0x07, 0x00, 0xd5, 0x59, 0xe1, 0x06, 0x22, 0xbb, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0x54, 0xe1, 0x07, 0x9b, 0x06, 0x9a, 0x5b, 0x88, + 0x93, 0x42, 0xc7, 0xd1, 0x33, 0x88, 0x0b, 0x93, 0x6b, 0x46, 0x9b, 0x8d, + 0x0d, 0x9a, 0xfb, 0x81, 0x6b, 0x46, 0x1b, 0x8b, 0x3b, 0x82, 0x09, 0x9b, + 0x9b, 0x18, 0x7b, 0x61, 0x09, 0x9a, 0x0e, 0x9b, 0x0a, 0x99, 0x9b, 0x1a, + 0xfb, 0x22, 0x56, 0x1a, 0x9e, 0x42, 0x00, 0xd9, 0x1e, 0x00, 0x06, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x84, 0xe0, 0x08, 0x9b, 0x07, 0x9a, 0x17, 0x33, + 0x5b, 0x00, 0x9b, 0x5a, 0x0c, 0x93, 0x00, 0x23, 0x06, 0x93, 0x6b, 0x46, + 0x1b, 0x8c, 0x12, 0xaa, 0xf9, 0x88, 0x53, 0x80, 0xff, 0x23, 0x49, 0x04, + 0x13, 0x71, 0x0a, 0x9b, 0x49, 0x0c, 0x11, 0x80, 0x00, 0x2b, 0x00, 0xd0, + 0x82, 0xe0, 0xfb, 0x2e, 0x00, 0xd0, 0x7f, 0xe0, 0x09, 0x98, 0x0f, 0x9b, + 0x00, 0x96, 0x1b, 0x18, 0x11, 0xa8, 0x03, 0x90, 0x01, 0x20, 0x02, 0x90, + 0x0a, 0x98, 0x01, 0x90, 0x28, 0x00, 0xff, 0xf7, 0xe5, 0xf8, 0x0c, 0x99, + 0x28, 0x00, 0xff, 0xf7, 0x63, 0xf9, 0x04, 0x1e, 0x00, 0xd0, 0xea, 0xe6, + 0x11, 0xab, 0x1b, 0x88, 0x0a, 0x93, 0x06, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0xd7, 0xe0, 0x69, 0x46, 0x08, 0x9b, 0x07, 0x9a, 0x17, 0x33, 0x09, 0x8d, + 0x5b, 0x00, 0x99, 0x52, 0x08, 0x98, 0x01, 0x30, 0x83, 0xb2, 0x08, 0x93, + 0x09, 0x9b, 0x9b, 0x19, 0x09, 0x93, 0x00, 0x23, 0x06, 0x9e, 0x0a, 0x93, + 0x09, 0x9b, 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd3, 0xcd, 0xe6, 0x08, 0x9b, + 0x68, 0x2b, 0x00, 0xd8, 0xf5, 0xe0, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x01, 0xf0, 0x9c, 0xfd, 0x01, 0x30, 0x83, 0xb2, 0x06, 0x93, 0x9e, 0x42, + 0x9a, 0xd0, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd1, 0x54, 0xe7, 0x00, 0x2e, + 0x00, 0xd0, 0xf8, 0xe6, 0x1a, 0x21, 0x0a, 0xa8, 0x09, 0x18, 0xbb, 0x89, + 0xfa, 0x88, 0x03, 0x94, 0x02, 0x94, 0x01, 0x94, 0x04, 0x91, 0x69, 0x6a, + 0x28, 0x00, 0x00, 0x91, 0x39, 0x00, 0xff, 0xf7, 0xf5, 0xfa, 0x04, 0x1e, + 0x00, 0xdb, 0x3f, 0xe7, 0x20, 0x00, 0x15, 0xb0, 0xf0, 0xbd, 0x80, 0x23, + 0xf9, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x06, 0x9a, 0x00, 0x23, 0x28, 0x00, 0xff, 0xf7, 0x1a, 0xf8, + 0x04, 0x1e, 0x00, 0xdb, 0x36, 0xe7, 0xeb, 0xe7, 0x08, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x08, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0xe7, 0xfd, 0x04, 0x31, 0x07, 0x9b, 0x49, 0x00, 0x5b, 0x5a, 0x0c, 0x93, + 0x73, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, + 0x39, 0x1d, 0x08, 0x9b, 0x0c, 0x9a, 0x28, 0x00, 0xfe, 0xf7, 0x64, 0xfd, + 0x04, 0x1e, 0xcf, 0xdb, 0x11, 0xab, 0xf9, 0x88, 0x03, 0x93, 0x00, 0x23, + 0x49, 0x04, 0x49, 0x0c, 0x02, 0x93, 0x01, 0x93, 0x00, 0x93, 0x12, 0xaa, + 0x28, 0x00, 0xff, 0xf7, 0x5d, 0xf8, 0x04, 0x1e, 0x00, 0xd0, 0x66, 0xe6, + 0x0a, 0x9b, 0x00, 0x2b, 0x2e, 0xd1, 0x0a, 0x9b, 0x98, 0x19, 0xfa, 0x28, + 0x3b, 0xd9, 0x0a, 0xab, 0x9b, 0x8b, 0x0a, 0x9a, 0x1b, 0x02, 0x05, 0x33, + 0x09, 0x98, 0x9b, 0x18, 0x04, 0x21, 0x7a, 0x5e, 0x0f, 0x99, 0x00, 0x96, + 0x09, 0x18, 0x01, 0x91, 0x28, 0x00, 0x07, 0x21, 0xfc, 0xf7, 0x01, 0xfc, + 0x04, 0x1e, 0x00, 0xd0, 0x4b, 0xe6, 0x02, 0x21, 0x12, 0xaa, 0x13, 0x79, + 0x28, 0x00, 0x8b, 0x43, 0x13, 0x71, 0x04, 0x21, 0x7a, 0x5e, 0x0a, 0xab, + 0x13, 0xa9, 0x9b, 0x8b, 0x01, 0x91, 0x01, 0x21, 0x1b, 0x02, 0x00, 0x91, + 0x04, 0x33, 0x06, 0x31, 0xfc, 0xf7, 0xeb, 0xfb, 0x04, 0x1e, 0x00, 0xd1, + 0x43, 0xe7, 0x34, 0xe6, 0x0a, 0xaa, 0x92, 0x8b, 0x0c, 0x9b, 0x04, 0x20, + 0x39, 0x5e, 0x0a, 0x98, 0x1b, 0x02, 0x12, 0x02, 0x00, 0x90, 0x05, 0x33, + 0x05, 0x32, 0x28, 0x00, 0xfe, 0xf7, 0xa4, 0xfd, 0x04, 0x1e, 0xc0, 0xd0, + 0x23, 0xe6, 0x0a, 0x9b, 0x0c, 0x9a, 0x05, 0x33, 0x12, 0x02, 0x9b, 0x19, + 0x9b, 0x18, 0x11, 0xaa, 0x12, 0x88, 0x0a, 0x99, 0x12, 0x02, 0x05, 0x32, + 0x52, 0x18, 0x04, 0x24, 0x39, 0x5f, 0xfb, 0x24, 0x20, 0x1a, 0x00, 0x90, + 0x92, 0x19, 0x28, 0x00, 0xfe, 0xf7, 0x8c, 0xfd, 0x04, 0x1e, 0xac, 0xd0, + 0x0b, 0xe6, 0x08, 0x9b, 0x19, 0x1d, 0x68, 0x2b, 0x05, 0xd9, 0x08, 0x98, + 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0x60, 0xfd, 0x04, 0x31, 0x6a, 0x46, + 0x07, 0x9b, 0x12, 0x8d, 0x49, 0x00, 0x5a, 0x52, 0x1e, 0xe7, 0x1a, 0x21, + 0x0a, 0xa8, 0x09, 0x18, 0xbb, 0x89, 0xfa, 0x88, 0x04, 0x91, 0x06, 0x99, + 0x28, 0x00, 0x03, 0x91, 0x02, 0x91, 0x01, 0x91, 0x69, 0x6a, 0x00, 0x91, + 0x39, 0x00, 0xff, 0xf7, 0x37, 0xfa, 0x00, 0x28, 0x00, 0xdb, 0x41, 0xe7, + 0x04, 0x00, 0x3f, 0xe7, 0x0d, 0x4c, 0x3d, 0xe7, 0x0d, 0x4c, 0x3b, 0xe7, + 0x0d, 0x4c, 0x39, 0xe7, 0x0d, 0x4c, 0x37, 0xe7, 0x09, 0x9a, 0x0e, 0x9b, + 0x0a, 0x99, 0x9b, 0x1a, 0xfb, 0x22, 0x56, 0x1a, 0x9e, 0x42, 0x00, 0xd8, + 0xbd, 0xe6, 0x1e, 0x00, 0xbb, 0xe6, 0x00, 0x2e, 0xf2, 0xd0, 0x09, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x0b, 0xe6, 0x06, 0x93, 0x3a, 0xe6, 0xc0, 0x46, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0x70, 0xb5, 0x88, 0xb0, 0x07, 0xab, 0x1a, 0x26, + 0x04, 0x00, 0x05, 0x93, 0x08, 0x00, 0x00, 0x23, 0x15, 0x00, 0x0f, 0x4a, + 0x6e, 0x44, 0x03, 0x93, 0x02, 0x90, 0x01, 0x92, 0x00, 0x93, 0x21, 0x8b, + 0x04, 0x96, 0xe2, 0x69, 0x20, 0x00, 0xfe, 0xf7, 0x55, 0xfd, 0x0a, 0x4b, + 0x98, 0x42, 0x0d, 0xd0, 0x00, 0x28, 0x09, 0xdb, 0x31, 0x88, 0x07, 0x9a, + 0x00, 0x2d, 0x03, 0xd0, 0x0b, 0x01, 0x9b, 0x18, 0x01, 0x33, 0x2b, 0x80, + 0x21, 0x83, 0xe2, 0x61, 0x08, 0xb0, 0x70, 0xbd, 0x02, 0x48, 0xfb, 0xe7, + 0xcd, 0x48, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x83, 0x68, 0x93, 0xb0, 0x01, 0x3b, 0x04, 0x00, 0x0b, 0x91, + 0x07, 0x92, 0x06, 0x68, 0x03, 0x33, 0x00, 0xd8, 0xd6, 0xe0, 0x00, 0x25, + 0xaa, 0x42, 0x00, 0xd1, 0xde, 0xe0, 0x1a, 0x23, 0xa5, 0x89, 0x08, 0xaa, + 0xa7, 0x68, 0x9b, 0x18, 0x1d, 0x80, 0x00, 0x2f, 0x00, 0xd0, 0xd8, 0xe0, + 0x06, 0x97, 0x73, 0x6a, 0x08, 0x93, 0x07, 0x9b, 0x00, 0x2b, 0x13, 0xd0, + 0x0b, 0x9b, 0x00, 0x2b, 0x10, 0xd1, 0x10, 0xa9, 0xb8, 0x33, 0x0b, 0x70, + 0x01, 0x91, 0x01, 0x21, 0x2d, 0x02, 0x2b, 0x1d, 0x04, 0x20, 0x22, 0x5e, + 0x00, 0x91, 0x30, 0x00, 0x05, 0x31, 0xfc, 0xf7, 0x18, 0xfb, 0x05, 0x1e, + 0x00, 0xda, 0xbb, 0xe0, 0x9f, 0x4b, 0x0c, 0x93, 0x00, 0x23, 0x09, 0x93, + 0x0b, 0x9b, 0x9f, 0x42, 0x00, 0xd8, 0xfd, 0xe0, 0x06, 0x9b, 0x68, 0x2b, + 0x00, 0xd8, 0x14, 0xe2, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0x29, 0xfc, 0x01, 0x30, 0x83, 0xb2, 0x0a, 0x93, 0x0a, 0x9a, 0x0c, 0x9b, + 0x93, 0x42, 0x00, 0xd1, 0x0e, 0xe2, 0x0c, 0x9b, 0x1a, 0x00, 0x92, 0x4b, + 0x9a, 0x42, 0x29, 0xd0, 0x08, 0xab, 0x5a, 0x8b, 0x21, 0x00, 0x0c, 0x9b, + 0x30, 0x00, 0xfe, 0xf7, 0xd5, 0xfa, 0x05, 0x1e, 0x00, 0xda, 0x93, 0xe0, + 0x08, 0xab, 0x59, 0x8b, 0x30, 0x00, 0xfe, 0xf7, 0xab, 0xff, 0x05, 0x1e, + 0x00, 0xda, 0x8b, 0xe0, 0x00, 0x21, 0x08, 0xaa, 0x02, 0x91, 0x52, 0x8b, + 0xe3, 0x88, 0x01, 0x92, 0x08, 0x9a, 0x90, 0x78, 0xd2, 0x78, 0x12, 0x02, + 0x02, 0x43, 0x00, 0x92, 0x30, 0x00, 0x02, 0x22, 0xff, 0xf7, 0x46, 0xf8, + 0x0c, 0x9b, 0x00, 0x2b, 0x04, 0xd0, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd1, + 0x82, 0xe0, 0xa7, 0x60, 0x0a, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x8e, 0xe0, + 0xa2, 0x89, 0x1a, 0x33, 0x08, 0xa9, 0x5b, 0x18, 0x1a, 0x80, 0x04, 0x21, + 0x62, 0x5e, 0x71, 0x6a, 0x08, 0xab, 0x5b, 0x8b, 0x01, 0x91, 0x80, 0x21, + 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x30, 0x00, 0xfc, 0xf7, + 0x52, 0xfa, 0x05, 0x1e, 0x5a, 0xdb, 0x08, 0x9b, 0x1b, 0x79, 0xda, 0x07, + 0x00, 0xd5, 0xb0, 0xe1, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xae, 0xe1, + 0x9a, 0x07, 0x00, 0xd5, 0xad, 0xe1, 0x5b, 0x07, 0x00, 0xd5, 0xac, 0xe1, + 0x06, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x00, 0xdb, 0xa7, 0xe1, 0x08, 0x9b, + 0x0a, 0x9a, 0x5b, 0x88, 0x09, 0x93, 0x93, 0x42, 0x00, 0xd0, 0xa2, 0xe1, + 0x08, 0xab, 0x5b, 0x8b, 0x67, 0x61, 0xe3, 0x81, 0x6b, 0x46, 0x1b, 0x8d, + 0x23, 0x82, 0x00, 0x2a, 0x00, 0xd0, 0x65, 0xe0, 0x06, 0x9b, 0x08, 0x9a, + 0x17, 0x33, 0x5b, 0x00, 0xd3, 0x18, 0x1a, 0x88, 0x0d, 0x92, 0x01, 0x22, + 0x52, 0x42, 0x1a, 0x80, 0x00, 0x23, 0x0c, 0x93, 0x09, 0x93, 0x0b, 0x9b, + 0x21, 0x1d, 0x00, 0x2b, 0x07, 0xd0, 0x07, 0x9b, 0x00, 0x2b, 0x04, 0xd1, + 0x0b, 0x9b, 0xfb, 0x1a, 0xfa, 0x2b, 0x00, 0xd8, 0xa6, 0xe0, 0x06, 0x9b, + 0x0d, 0x9a, 0x30, 0x00, 0xfe, 0xf7, 0xaa, 0xfb, 0x4e, 0x4b, 0x98, 0x42, + 0x59, 0xd1, 0xfb, 0x21, 0x38, 0x00, 0x01, 0xf0, 0x15, 0xfc, 0x00, 0x29, + 0x00, 0xd1, 0x89, 0xe0, 0x7f, 0x1a, 0x88, 0xe0, 0x07, 0x9b, 0x00, 0x2b, + 0x00, 0xd0, 0x28, 0xe7, 0xfb, 0x21, 0x30, 0x00, 0x49, 0x00, 0xfd, 0xf7, + 0xbb, 0xfe, 0x05, 0x1e, 0x00, 0xdb, 0x20, 0xe7, 0x28, 0x00, 0x13, 0xb0, + 0xf0, 0xbd, 0x78, 0x1e, 0xfb, 0x21, 0x01, 0xf0, 0x77, 0xfb, 0x83, 0xb2, + 0x06, 0x93, 0x7b, 0x1c, 0x00, 0xd0, 0x1e, 0xe7, 0x00, 0x27, 0x1c, 0xe7, + 0x0f, 0xa9, 0x04, 0x91, 0x07, 0x99, 0xa3, 0x89, 0x02, 0x91, 0x01, 0x91, + 0x00, 0x91, 0xe2, 0x88, 0x03, 0x97, 0x21, 0x00, 0x30, 0x00, 0xff, 0xf7, + 0xd7, 0xf8, 0x05, 0x1e, 0x00, 0xdb, 0x6c, 0xe7, 0xe0, 0xe7, 0x80, 0x23, + 0xe1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1a, 0x23, 0x08, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x0a, 0x9a, 0x00, 0x23, 0x30, 0x00, 0xfe, 0xf7, 0xfe, 0xfd, + 0x05, 0x1e, 0x00, 0xdb, 0x65, 0xe7, 0xcf, 0xe7, 0x06, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x06, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0xcb, 0xfb, 0x04, 0x31, 0x08, 0x9b, 0x49, 0x00, 0x59, 0x18, 0x0b, 0x88, + 0x0d, 0x93, 0x01, 0x23, 0x5b, 0x42, 0x0b, 0x80, 0x0a, 0x9b, 0x0c, 0x93, + 0x91, 0xe7, 0x00, 0x28, 0x2c, 0xd0, 0x20, 0x4b, 0x98, 0x42, 0xa0, 0xd0, + 0x08, 0xab, 0x5d, 0x8b, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0xcf, 0xe0, + 0x00, 0x2f, 0x00, 0xd0, 0xc4, 0xe0, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd1, + 0xa7, 0xe0, 0x2a, 0x00, 0x3b, 0x00, 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, + 0xe1, 0xf9, 0x05, 0x1e, 0xa0, 0xdb, 0x08, 0xab, 0x59, 0x8b, 0x30, 0x00, + 0xfe, 0xf7, 0xb8, 0xfe, 0x05, 0x1e, 0x00, 0xda, 0x98, 0xe7, 0x02, 0x97, + 0x08, 0xaa, 0x52, 0x8b, 0xe3, 0x88, 0x01, 0x92, 0x00, 0x97, 0x02, 0x22, + 0x39, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0x58, 0xff, 0xa7, 0x60, 0x8b, 0xe7, + 0x0d, 0x99, 0x30, 0x00, 0xfe, 0xf7, 0xa4, 0xfe, 0x00, 0x28, 0x00, 0xd1, + 0x6f, 0xe7, 0xcd, 0xe7, 0xfb, 0x3f, 0x06, 0x98, 0xa7, 0x60, 0x01, 0x38, + 0x83, 0xb2, 0x67, 0x61, 0x06, 0x93, 0xc3, 0xe6, 0xff, 0xff, 0x00, 0x00, + 0xec, 0xd8, 0xff, 0xff, 0xe1, 0xd8, 0xff, 0xff, 0x06, 0x9b, 0x0d, 0x9a, + 0x30, 0x00, 0xfe, 0xf7, 0x03, 0xfb, 0x00, 0x28, 0xb8, 0xd1, 0x6a, 0x46, + 0xe1, 0x88, 0x12, 0x8b, 0x49, 0x04, 0x08, 0xab, 0x49, 0x0c, 0x5a, 0x84, + 0x19, 0x84, 0xff, 0x23, 0x24, 0x30, 0x08, 0xaa, 0x12, 0x18, 0x13, 0x70, + 0x08, 0xaa, 0xe1, 0x3b, 0x9b, 0x18, 0x03, 0x93, 0x07, 0x9b, 0x10, 0xaa, + 0x02, 0x93, 0x01, 0x93, 0x00, 0x93, 0x30, 0x00, 0xfe, 0xf7, 0xf0, 0xfd, + 0x00, 0x28, 0x9d, 0xd1, 0x0d, 0x9b, 0xfb, 0x21, 0x1b, 0x02, 0x05, 0x33, + 0x0a, 0x93, 0x0b, 0x98, 0x08, 0xab, 0xdd, 0x8b, 0x01, 0xf0, 0x4e, 0xfb, + 0x2d, 0x02, 0x05, 0x35, 0x00, 0x91, 0x0a, 0x9b, 0x2a, 0x00, 0x07, 0x99, + 0x30, 0x00, 0xfe, 0xf7, 0x65, 0xfb, 0x00, 0x28, 0x00, 0xd0, 0x87, 0xe7, + 0x0d, 0x99, 0x30, 0x00, 0xfe, 0xf7, 0x56, 0xfe, 0x00, 0x28, 0x00, 0xd0, + 0x80, 0xe7, 0x24, 0x21, 0x02, 0x22, 0x08, 0xab, 0x5b, 0x18, 0x1b, 0x78, + 0x30, 0x00, 0x93, 0x43, 0x08, 0xaa, 0x52, 0x18, 0x13, 0x70, 0x04, 0x21, + 0x62, 0x5e, 0x08, 0xab, 0x11, 0xa9, 0xdb, 0x8b, 0x01, 0x91, 0x01, 0x21, + 0x1b, 0x02, 0x00, 0x91, 0x04, 0x33, 0x06, 0x31, 0xfc, 0xf7, 0x79, 0xf9, + 0x00, 0x28, 0x00, 0xd0, 0x66, 0xe7, 0x08, 0xab, 0xdd, 0x8b, 0x09, 0x9b, + 0x00, 0x2b, 0x09, 0xd1, 0x06, 0x98, 0x17, 0x30, 0x08, 0x9b, 0x40, 0x00, + 0x1d, 0x52, 0x0b, 0x9b, 0xa3, 0x60, 0x63, 0x61, 0x1f, 0x00, 0x57, 0xe7, + 0x06, 0x9b, 0x68, 0x2b, 0x02, 0xd8, 0x18, 0x00, 0x04, 0x30, 0xf1, 0xe7, + 0x06, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0x07, 0xfb, 0x08, 0x1d, + 0xea, 0xe7, 0x70, 0x6a, 0xd2, 0x22, 0x2e, 0x30, 0xff, 0x21, 0x01, 0xf0, + 0x32, 0xfb, 0x0f, 0xab, 0x04, 0x93, 0x01, 0x23, 0xe2, 0x88, 0x5b, 0x42, + 0x03, 0x93, 0x02, 0x97, 0x01, 0x97, 0x73, 0x6a, 0x00, 0x93, 0x2b, 0x00, + 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0xde, 0xff, 0x05, 0x1e, 0x00, 0xdb, + 0x5a, 0xe7, 0xe7, 0xe6, 0x0f, 0xab, 0x04, 0x93, 0x09, 0x9b, 0xe2, 0x88, + 0x03, 0x97, 0x02, 0x93, 0x01, 0x93, 0xec, 0xe7, 0x2a, 0x00, 0x09, 0x9b, + 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0x18, 0xf9, 0x05, 0x1e, 0x00, 0xda, + 0xd6, 0xe6, 0x00, 0x25, 0x04, 0x22, 0xa1, 0x5e, 0x10, 0xaa, 0x02, 0x92, + 0x08, 0xaa, 0x52, 0x8b, 0xe3, 0x88, 0x01, 0x92, 0x00, 0x95, 0x08, 0x9a, + 0x30, 0x00, 0xfe, 0xf7, 0x15, 0xfe, 0x05, 0x1e, 0x00, 0xda, 0xc5, 0xe6, + 0x00, 0x25, 0x08, 0xaa, 0x02, 0x95, 0x12, 0x8c, 0xe3, 0x88, 0x01, 0x92, + 0x08, 0x9a, 0x30, 0x00, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, + 0x00, 0x92, 0x08, 0x99, 0x2a, 0x00, 0xfe, 0xf7, 0x7f, 0xfe, 0x08, 0xab, + 0x1b, 0x8c, 0x0f, 0xa9, 0xe3, 0x81, 0x6b, 0x46, 0x9b, 0x8c, 0x67, 0x61, + 0x23, 0x82, 0xe2, 0x88, 0xa3, 0x89, 0x04, 0x91, 0x03, 0x97, 0x02, 0x95, + 0x01, 0x95, 0x00, 0x95, 0xb4, 0xe7, 0x0a, 0x4d, 0xa2, 0xe6, 0x0a, 0x4d, + 0xa0, 0xe6, 0x0a, 0x4d, 0x9e, 0xe6, 0x0a, 0x4d, 0x9c, 0xe6, 0x0a, 0x4d, + 0x9a, 0xe6, 0x00, 0x23, 0x0a, 0x93, 0x0c, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0xf1, 0xe5, 0x5d, 0xe6, 0x0a, 0x9b, 0x09, 0x93, 0xc4, 0xe6, 0xc0, 0x46, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x8f, 0xb0, + 0x07, 0x91, 0x08, 0x93, 0x03, 0x68, 0x04, 0x00, 0xfb, 0x21, 0x07, 0x98, + 0x04, 0x93, 0x0b, 0x92, 0x01, 0xf0, 0xf8, 0xf9, 0x87, 0xb2, 0x00, 0x20, + 0x04, 0x9b, 0x5b, 0x6a, 0x06, 0x93, 0x07, 0x9b, 0x03, 0x93, 0x6b, 0x4b, + 0x05, 0x93, 0x0b, 0x9a, 0x07, 0x9b, 0x94, 0x46, 0x03, 0x9a, 0x63, 0x44, + 0x0a, 0x93, 0x93, 0x42, 0x3a, 0xd9, 0xe2, 0x6a, 0x00, 0x2a, 0x0c, 0xd0, + 0x13, 0x89, 0xbb, 0x42, 0x09, 0xd8, 0x51, 0x89, 0xb9, 0x42, 0x06, 0xd3, + 0xfb, 0x1a, 0x12, 0x68, 0x5b, 0x00, 0x9d, 0x5a, 0x00, 0x2d, 0x00, 0xd0, + 0x82, 0xe0, 0x68, 0x2f, 0x3d, 0xd9, 0x38, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x01, 0xf0, 0xd0, 0xf9, 0x05, 0x9b, 0x01, 0x30, 0x85, 0xb2, 0xab, 0x42, + 0x06, 0xd1, 0x38, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0x4c, 0xfa, + 0x04, 0x31, 0x1c, 0xe0, 0x23, 0x8a, 0xab, 0x42, 0x05, 0xd1, 0x0e, 0x23, + 0xe2, 0x89, 0x0a, 0xa9, 0x5b, 0x18, 0x1a, 0x80, 0x2c, 0xe0, 0x80, 0x23, + 0xe1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x0e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x2a, 0x00, 0x00, 0x23, 0x04, 0x98, 0xfe, 0xf7, 0x5a, 0xfc, + 0x00, 0x28, 0x1d, 0xda, 0x0f, 0xb0, 0xf0, 0xbd, 0x39, 0x1d, 0x68, 0x2f, + 0xdb, 0xd8, 0x06, 0x9b, 0x49, 0x00, 0x5d, 0x5a, 0x4e, 0xe0, 0x45, 0x48, + 0xf4, 0xe7, 0x45, 0x48, 0xf2, 0xe7, 0x45, 0x48, 0xf0, 0xe7, 0x45, 0x48, + 0xee, 0xe7, 0x45, 0x48, 0xec, 0xe7, 0x45, 0x48, 0xea, 0xe7, 0x05, 0x9b, + 0x00, 0x2b, 0x38, 0xd0, 0x0e, 0x23, 0x00, 0x25, 0xa2, 0x89, 0x0a, 0xa9, + 0x5b, 0x18, 0x1a, 0x80, 0x0e, 0x26, 0x04, 0x21, 0x62, 0x5e, 0x04, 0x99, + 0x0a, 0xab, 0x49, 0x6a, 0xf6, 0x18, 0x33, 0x88, 0x05, 0x91, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x04, 0x98, + 0xfb, 0xf7, 0xf3, 0xff, 0x00, 0x28, 0xcd, 0xdb, 0x01, 0x22, 0x06, 0x9b, + 0x1b, 0x79, 0x13, 0x42, 0xd1, 0xd1, 0x5a, 0xb2, 0x00, 0x2a, 0xd0, 0xda, + 0x9a, 0x07, 0xd0, 0xd4, 0x5b, 0x07, 0xd0, 0xd4, 0x06, 0x22, 0xa3, 0x5e, + 0x00, 0x2b, 0xcc, 0xda, 0x06, 0x9b, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, + 0x13, 0x43, 0x05, 0x93, 0xab, 0x42, 0xc6, 0xd1, 0x03, 0x9b, 0x25, 0x82, + 0x63, 0x61, 0x33, 0x88, 0xe3, 0x81, 0x00, 0x2d, 0xb0, 0xd1, 0x3b, 0x00, + 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9d, 0x5a, 0x00, 0x23, 0x05, 0x93, + 0xfb, 0x21, 0x03, 0x98, 0x01, 0xf0, 0xd6, 0xf9, 0x0a, 0x9b, 0x03, 0x9a, + 0x09, 0x91, 0x9a, 0x1a, 0x03, 0x99, 0xa3, 0x68, 0x5b, 0x1a, 0x93, 0x42, + 0x00, 0xd9, 0x13, 0x00, 0xfb, 0x26, 0x09, 0x9a, 0xb6, 0x1a, 0x9e, 0x42, + 0x00, 0xd9, 0x1e, 0x00, 0x00, 0x2e, 0xa4, 0xd0, 0x21, 0x1d, 0x3b, 0x00, + 0x2a, 0x00, 0x04, 0x98, 0xfe, 0xf7, 0x4c, 0xf9, 0x00, 0x28, 0x00, 0xda, + 0x88, 0xe7, 0x09, 0x9b, 0x04, 0x21, 0x62, 0x5e, 0x08, 0x99, 0x2d, 0x02, + 0x05, 0x33, 0x01, 0x91, 0xeb, 0x18, 0x00, 0x96, 0x17, 0x21, 0x04, 0x98, + 0xfb, 0xf7, 0x9f, 0xff, 0x00, 0x28, 0x00, 0xda, 0x78, 0xe7, 0x08, 0x9b, + 0x01, 0x37, 0x9b, 0x19, 0x08, 0x93, 0x03, 0x9b, 0xbf, 0xb2, 0x9b, 0x19, + 0x03, 0x93, 0x63, 0x61, 0x2b, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x0f, 0x23, 0x8d, 0xb0, 0x06, 0x91, 0x01, 0x21, 0x07, 0x92, + 0xc2, 0x68, 0x05, 0x00, 0x53, 0x43, 0x5b, 0x08, 0x09, 0xaa, 0x5b, 0x18, + 0x11, 0x80, 0x99, 0xb2, 0x1b, 0x04, 0x3c, 0xd4, 0x51, 0x80, 0x00, 0x23, + 0x53, 0x60, 0x07, 0x9b, 0x93, 0x60, 0x09, 0xac, 0x23, 0x88, 0x68, 0x6a, + 0x9c, 0x46, 0x62, 0x46, 0x63, 0x88, 0x9b, 0x1a, 0x80, 0x22, 0x12, 0x01, + 0x93, 0x42, 0x37, 0xdc, 0x80, 0x22, 0x00, 0x21, 0x52, 0x00, 0x01, 0xf0, + 0xa0, 0xf9, 0x00, 0x21, 0x07, 0x9b, 0x05, 0x91, 0x02, 0x93, 0x3d, 0x4b, + 0x04, 0x91, 0x01, 0x93, 0x03, 0x94, 0x0b, 0x00, 0x00, 0x91, 0x0a, 0x00, + 0x28, 0x00, 0xfe, 0xf7, 0xa9, 0xf9, 0x39, 0x4b, 0x98, 0x42, 0x01, 0xd0, + 0x00, 0x28, 0x12, 0xdb, 0x80, 0x26, 0x00, 0x22, 0x01, 0x23, 0x6f, 0x6a, + 0x76, 0x00, 0xbd, 0x5c, 0xff, 0x2d, 0x12, 0xd0, 0x00, 0x21, 0x28, 0x00, + 0x08, 0x41, 0x18, 0x40, 0x0a, 0xd1, 0x23, 0x88, 0xd2, 0x00, 0x59, 0x18, + 0x06, 0x9b, 0x8a, 0x18, 0x1a, 0x80, 0x0d, 0xb0, 0xf0, 0xbd, 0x2d, 0x4b, + 0x53, 0x80, 0xc0, 0xe7, 0x01, 0x31, 0x08, 0x29, 0xed, 0xd1, 0x01, 0x32, + 0xb2, 0x42, 0xe6, 0xd1, 0x29, 0x48, 0xf2, 0xe7, 0x62, 0x68, 0x00, 0x2a, + 0x1d, 0xd1, 0x09, 0xac, 0x22, 0x88, 0x63, 0x88, 0x00, 0x26, 0x9b, 0x1a, + 0x80, 0x22, 0x1b, 0x0a, 0x52, 0x00, 0x00, 0x21, 0x63, 0x60, 0x01, 0xf0, + 0x5e, 0xf9, 0x22, 0x4b, 0x05, 0x96, 0x01, 0x93, 0x04, 0x96, 0x33, 0x00, + 0x03, 0x96, 0x02, 0x94, 0x00, 0x96, 0x32, 0x00, 0x31, 0x00, 0x28, 0x00, + 0xfe, 0xf7, 0x68, 0xf9, 0x18, 0x4b, 0x98, 0x42, 0x26, 0xd1, 0xa6, 0x60, + 0x9b, 0xe7, 0x00, 0x27, 0xff, 0x23, 0x39, 0x00, 0x46, 0x5c, 0x9e, 0x42, + 0x02, 0xd2, 0x33, 0x1e, 0x06, 0xd0, 0x0f, 0x00, 0x80, 0x26, 0x01, 0x31, + 0x76, 0x00, 0xb1, 0x42, 0xf4, 0xd1, 0x39, 0x00, 0x9a, 0x42, 0xcb, 0xd0, + 0x92, 0xb2, 0x51, 0x43, 0x61, 0x44, 0x89, 0xb2, 0x00, 0x2b, 0x03, 0xd1, + 0x06, 0x9a, 0x18, 0x00, 0x11, 0x80, 0xb6, 0xe7, 0x80, 0x23, 0x52, 0x18, + 0x92, 0xb2, 0x62, 0x80, 0x21, 0x80, 0x52, 0x1a, 0x1b, 0x01, 0x9a, 0x42, + 0xbd, 0xdc, 0x76, 0xe7, 0x00, 0x28, 0xaa, 0xdb, 0xa6, 0x60, 0x00, 0xd1, + 0x71, 0xe7, 0xa6, 0xe7, 0x31, 0x49, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xff, 0x7f, 0x00, 0x00, 0xef, 0xd8, 0xff, 0xff, 0x6d, 0x4b, 0x00, 0x00, + 0xf0, 0xb5, 0x85, 0xb0, 0x05, 0x00, 0x03, 0x91, 0x14, 0x00, 0x10, 0x1e, + 0x01, 0xd0, 0xfe, 0xf7, 0x57, 0xf8, 0xeb, 0x6a, 0xae, 0x6a, 0x02, 0x93, + 0x00, 0x2c, 0x07, 0xd0, 0x30, 0x23, 0x02, 0x99, 0x32, 0x1d, 0x4b, 0x43, + 0xf3, 0x18, 0x04, 0x33, 0x93, 0x42, 0x0e, 0xd1, 0x2a, 0x4a, 0x01, 0x23, + 0x01, 0x92, 0x00, 0x22, 0x31, 0x1d, 0x5b, 0x42, 0x00, 0x92, 0x02, 0x9f, + 0x00, 0x9a, 0xba, 0x42, 0x0e, 0xd1, 0x5a, 0x1c, 0x21, 0xd1, 0x25, 0x48, + 0x3b, 0xe0, 0x00, 0x27, 0xd1, 0x5f, 0x00, 0x29, 0x04, 0xd1, 0x91, 0x8c, + 0x01, 0x29, 0x01, 0xd9, 0x01, 0x39, 0x91, 0x84, 0x30, 0x32, 0xe3, 0xe7, + 0x00, 0x22, 0x8f, 0x5e, 0x00, 0x2f, 0x0a, 0xd1, 0x00, 0x2c, 0x02, 0xd0, + 0x0f, 0x6a, 0x87, 0x42, 0x0a, 0xd0, 0x8f, 0x8c, 0x01, 0x9a, 0x97, 0x42, + 0x01, 0xd2, 0x00, 0x9b, 0x01, 0x97, 0x00, 0x9a, 0x30, 0x31, 0x01, 0x32, + 0x00, 0x92, 0xd8, 0xe7, 0x00, 0x9b, 0x30, 0x22, 0x5a, 0x43, 0xb6, 0x18, + 0x00, 0x2c, 0x11, 0xd0, 0x72, 0x6a, 0x82, 0x42, 0x19, 0xd1, 0x31, 0x8d, + 0x00, 0x29, 0x16, 0xd0, 0xb2, 0x89, 0x10, 0x09, 0x28, 0x83, 0x0f, 0x20, + 0x02, 0x40, 0x01, 0x3a, 0xea, 0x61, 0x0c, 0x4a, 0x91, 0x42, 0x08, 0xd8, + 0x04, 0x31, 0x31, 0x85, 0x00, 0x20, 0x01, 0x33, 0xb3, 0x80, 0x03, 0x9b, + 0x1e, 0x60, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x22, 0x52, 0x42, 0x32, 0x85, + 0xf4, 0xe7, 0x04, 0x22, 0x70, 0x62, 0x32, 0x85, 0xf0, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xe9, 0xd8, 0xff, 0xff, 0xfa, 0xff, 0x00, 0x00, + 0x00, 0x29, 0x10, 0xdd, 0x2c, 0x22, 0x83, 0x5e, 0x8b, 0x42, 0x0c, 0xdb, + 0x30, 0x23, 0x4b, 0x43, 0x81, 0x6a, 0x30, 0x3b, 0xc9, 0x18, 0x04, 0x22, + 0x8b, 0x5e, 0x00, 0x2b, 0x05, 0xd0, 0x00, 0x20, 0x88, 0x80, 0xc8, 0x62, + 0x70, 0x47, 0x02, 0x48, 0xfc, 0xe7, 0x02, 0x48, 0xfa, 0xe7, 0xc0, 0x46, + 0xe6, 0xd8, 0xff, 0xff, 0xe8, 0xd8, 0xff, 0xff, 0x10, 0xb5, 0x00, 0x29, + 0x11, 0xdd, 0x2c, 0x24, 0x03, 0x5f, 0x8b, 0x42, 0x0d, 0xdb, 0x30, 0x23, + 0x59, 0x43, 0x83, 0x6a, 0x30, 0x39, 0x59, 0x18, 0x11, 0x60, 0x04, 0x23, + 0xc8, 0x5e, 0x43, 0x42, 0x58, 0x41, 0x03, 0x4b, 0x40, 0x42, 0x18, 0x40, + 0x10, 0xbd, 0x02, 0x48, 0xfc, 0xe7, 0xc0, 0x46, 0xe8, 0xd8, 0xff, 0xff, + 0xe6, 0xd8, 0xff, 0xff, 0x03, 0x7d, 0x00, 0x2b, 0x04, 0xd1, 0x43, 0x75, + 0x83, 0x75, 0x83, 0x61, 0x01, 0x33, 0x03, 0x75, 0x70, 0x47, 0x7f, 0xb5, + 0xc3, 0x68, 0x02, 0xad, 0x04, 0x00, 0x0e, 0x00, 0x02, 0x91, 0x6a, 0x60, + 0x8b, 0x42, 0x03, 0xd1, 0x02, 0x8a, 0xab, 0x88, 0x9a, 0x42, 0x18, 0xd0, + 0x20, 0x00, 0x06, 0x22, 0x29, 0x00, 0x0c, 0x30, 0x01, 0xf0, 0x48, 0xf8, + 0x20, 0x68, 0x00, 0xf0, 0x8e, 0xf9, 0x6b, 0x79, 0x22, 0x7a, 0xe1, 0x79, + 0x00, 0x93, 0x20, 0x68, 0x00, 0x23, 0x00, 0xf0, 0x27, 0xfa, 0x20, 0x68, + 0x29, 0x79, 0x32, 0x00, 0x00, 0xf0, 0x52, 0xf9, 0x20, 0x68, 0x00, 0xf0, + 0x74, 0xf9, 0x7f, 0xbd, 0x70, 0xb5, 0x18, 0x26, 0x04, 0x00, 0xff, 0xf7, + 0xcb, 0xff, 0x33, 0x00, 0x08, 0x21, 0x20, 0x79, 0x0d, 0x4d, 0x43, 0x43, + 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0xbc, 0xfe, 0x33, 0x00, 0x08, 0x21, + 0xa0, 0x79, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0xb4, 0xfe, + 0x08, 0x21, 0x60, 0x79, 0x46, 0x43, 0xad, 0x19, 0x69, 0x56, 0x00, 0xf0, + 0xad, 0xfe, 0x04, 0x4b, 0x20, 0x00, 0x06, 0xcb, 0xff, 0xf7, 0xb7, 0xff, + 0x70, 0xbd, 0xc0, 0x46, 0x20, 0x82, 0x00, 0x00, 0x34, 0x0c, 0x00, 0x20, + 0x07, 0xb5, 0x43, 0x7d, 0x00, 0x91, 0x01, 0x92, 0x00, 0x2b, 0x07, 0xd0, + 0x9a, 0x07, 0x0a, 0xd5, 0xef, 0xf3, 0x10, 0x83, 0x5a, 0x42, 0x53, 0x41, + 0x83, 0x75, 0x72, 0xb6, 0x00, 0x99, 0x01, 0x9a, 0xff, 0xf7, 0x9f, 0xff, + 0x07, 0xbd, 0xdb, 0x07, 0xf8, 0xd5, 0x83, 0x69, 0x01, 0x4a, 0x9b, 0xb2, + 0x93, 0x60, 0xf3, 0xe7, 0x00, 0x18, 0x00, 0x40, 0x10, 0xb5, 0x00, 0x68, + 0x00, 0xf0, 0x3e, 0xf9, 0x10, 0xbd, 0x00, 0x00, 0x10, 0x4a, 0x11, 0x4b, + 0x11, 0x49, 0x13, 0x60, 0x00, 0x23, 0x53, 0x71, 0x13, 0x71, 0x10, 0x4a, + 0x10, 0x48, 0x11, 0x60, 0x10, 0x49, 0xd3, 0x60, 0x91, 0x80, 0x09, 0x21, + 0x91, 0x71, 0x06, 0x39, 0x53, 0x74, 0x13, 0x74, 0x13, 0x75, 0xd3, 0x71, + 0x11, 0x72, 0x0c, 0x4a, 0x10, 0x60, 0x0c, 0x48, 0xd3, 0x60, 0x90, 0x80, + 0x1b, 0x20, 0x53, 0x74, 0x13, 0x74, 0x13, 0x75, 0x90, 0x71, 0xd3, 0x71, + 0x11, 0x72, 0x70, 0x47, 0x34, 0x0c, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, + 0x7c, 0x0e, 0x00, 0x20, 0xfc, 0x0b, 0x00, 0x20, 0x88, 0x0e, 0x00, 0x20, + 0x0a, 0x08, 0x00, 0x00, 0x18, 0x0c, 0x00, 0x20, 0x1d, 0x1a, 0x00, 0x00, + 0x10, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x05, 0xfb, 0x10, 0xbd, 0xc0, 0x46, + 0x3c, 0x0c, 0x00, 0x20, 0x13, 0xb5, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, + 0x3b, 0xf8, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, 0x37, 0xf8, 0x12, 0x49, + 0x12, 0x48, 0x00, 0xf0, 0x33, 0xf8, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, + 0x2f, 0xf8, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, 0x2b, 0xf8, 0x12, 0x4c, + 0x12, 0x49, 0x20, 0x00, 0x00, 0xf0, 0x26, 0xf8, 0x01, 0x23, 0x01, 0x93, + 0x02, 0x33, 0x00, 0x93, 0x0d, 0x22, 0x0b, 0x33, 0x21, 0x00, 0x0e, 0x48, + 0x00, 0xf0, 0x72, 0xfa, 0x13, 0xbd, 0xc0, 0x46, 0x00, 0x08, 0x00, 0x42, + 0x78, 0x0e, 0x00, 0x20, 0x00, 0x0c, 0x00, 0x42, 0x7c, 0x0e, 0x00, 0x20, + 0x00, 0x10, 0x00, 0x42, 0x80, 0x0e, 0x00, 0x20, 0x00, 0x14, 0x00, 0x42, + 0x84, 0x0e, 0x00, 0x20, 0x00, 0x18, 0x00, 0x42, 0x88, 0x0e, 0x00, 0x20, + 0x8c, 0x0e, 0x00, 0x20, 0x00, 0x1c, 0x00, 0x42, 0x3c, 0x0c, 0x00, 0x20, + 0x01, 0x60, 0x70, 0x47, 0x94, 0x46, 0xf0, 0xb5, 0x9e, 0x1e, 0x72, 0x1e, + 0x96, 0x41, 0x62, 0x46, 0x05, 0x68, 0x92, 0x07, 0x2f, 0x68, 0x36, 0x06, + 0x3a, 0x43, 0x32, 0x43, 0x2a, 0x60, 0x07, 0x25, 0x05, 0xac, 0x24, 0x78, + 0x00, 0x68, 0xa4, 0x01, 0x29, 0x40, 0x21, 0x43, 0x42, 0x68, 0x00, 0x24, + 0x02, 0x2b, 0x00, 0xd0, 0x5c, 0x03, 0x11, 0x43, 0x21, 0x43, 0x41, 0x60, + 0xf0, 0xbd, 0x30, 0xb5, 0xc0, 0x25, 0x03, 0x68, 0xad, 0x03, 0x1c, 0x68, + 0x12, 0x05, 0x2a, 0x40, 0x22, 0x43, 0xc0, 0x24, 0x09, 0x04, 0xa4, 0x02, + 0x21, 0x40, 0x11, 0x43, 0x19, 0x60, 0x03, 0x68, 0x5a, 0x68, 0x14, 0x43, + 0x5c, 0x60, 0x30, 0xbd, 0x01, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, + 0x13, 0x60, 0x03, 0x68, 0x1a, 0x68, 0xd2, 0x07, 0xfc, 0xd4, 0xda, 0x69, + 0xd2, 0x07, 0xf9, 0xd4, 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, 0x11, 0x68, + 0x0b, 0x43, 0x13, 0x60, 0x02, 0x68, 0xd3, 0x69, 0x9b, 0x07, 0xfc, 0xd4, + 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, 0x02, 0xd4, 0x1a, 0x7e, + 0x92, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0x00, 0x22, 0x03, 0x68, 0x5a, 0x83, + 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x40, 0x07, 0xc0, 0x0f, 0x70, 0x47, + 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x09, 0x70, 0x47, 0x80, 0x23, 0x02, 0x68, + 0x5b, 0x42, 0x11, 0x7e, 0x0b, 0x43, 0x13, 0x76, 0x70, 0x47, 0x03, 0x68, + 0x58, 0x8b, 0x80, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, + 0x51, 0x8b, 0x0b, 0x43, 0x53, 0x83, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, + 0xc0, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x8d, 0xc0, 0xb2, + 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, 0xfc, 0xd5, 0x89, 0xb2, + 0x01, 0x20, 0x19, 0x85, 0x70, 0x47, 0x01, 0x22, 0x03, 0x68, 0x9a, 0x75, + 0x70, 0x47, 0x01, 0x22, 0x03, 0x68, 0x1a, 0x75, 0x70, 0x47, 0x00, 0x00, + 0x70, 0xb5, 0x01, 0x26, 0x04, 0x68, 0x4b, 0x08, 0x33, 0x40, 0x31, 0x40, + 0x25, 0x68, 0x09, 0x07, 0x5b, 0x07, 0x0b, 0x43, 0x2b, 0x43, 0x23, 0x60, + 0x04, 0x68, 0x51, 0x00, 0x03, 0x48, 0x00, 0xf0, 0x25, 0xfe, 0x01, 0x38, + 0xc0, 0xb2, 0x20, 0x73, 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x6c, 0xdc, 0x02, + 0x01, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, 0x03, 0x68, + 0x1a, 0x68, 0xd2, 0x07, 0xfc, 0xd4, 0xda, 0x69, 0xd2, 0x07, 0xf9, 0xd4, + 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, + 0x02, 0x68, 0xd3, 0x69, 0x9b, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, + 0xda, 0x69, 0x92, 0x07, 0xfc, 0xd4, 0x02, 0x21, 0x1a, 0x68, 0x8a, 0x43, + 0x1a, 0x60, 0x70, 0x47, 0x02, 0x68, 0x93, 0x6a, 0x5b, 0x0a, 0x5b, 0x02, + 0x19, 0x43, 0x91, 0x62, 0x03, 0x68, 0x1a, 0x7e, 0x52, 0x07, 0xfc, 0xd5, + 0x98, 0x6a, 0xc0, 0xb2, 0x70, 0x47, 0x00, 0x00, 0x03, 0x68, 0x21, 0x4a, + 0x30, 0xb5, 0x93, 0x42, 0x2f, 0xd0, 0x20, 0x4a, 0x93, 0x42, 0x2f, 0xd0, + 0x1f, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x2f, 0xd0, + 0x1e, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1e, 0x4a, 0x93, 0x42, 0x1f, 0xd1, + 0x0e, 0x23, 0x19, 0x22, 0x01, 0x21, 0x03, 0x25, 0x99, 0x40, 0x1b, 0x48, + 0xc0, 0x24, 0x01, 0x60, 0x99, 0x08, 0x2b, 0x40, 0xab, 0x40, 0xfc, 0x35, + 0x9d, 0x40, 0x89, 0x00, 0x09, 0x18, 0xa4, 0x00, 0x08, 0x59, 0xa8, 0x43, + 0xc0, 0x25, 0x9d, 0x40, 0x2b, 0x00, 0x03, 0x43, 0x0b, 0x51, 0x80, 0x23, + 0xdb, 0x01, 0x1a, 0x43, 0x11, 0x4b, 0x5a, 0x80, 0x5a, 0x78, 0x52, 0xb2, + 0x00, 0x2a, 0xfb, 0xdb, 0x30, 0xbd, 0x09, 0x23, 0x14, 0x22, 0xdd, 0xe7, + 0x0a, 0x23, 0x15, 0x22, 0xda, 0xe7, 0x0b, 0x23, 0x16, 0x22, 0xd7, 0xe7, + 0x0c, 0x23, 0x17, 0x22, 0xd4, 0xe7, 0x0d, 0x23, 0x18, 0x22, 0xd1, 0xe7, + 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, 0x00, 0x10, 0x00, 0x42, + 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, 0x00, 0x1c, 0x00, 0x42, + 0x00, 0xe1, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x40, 0xf8, 0xb5, 0x04, 0x00, + 0x0f, 0x00, 0x16, 0x00, 0x1d, 0x00, 0xff, 0xf7, 0xa5, 0xff, 0x20, 0x00, + 0xff, 0xf7, 0x04, 0xff, 0x1c, 0x21, 0xbb, 0x00, 0x0b, 0x40, 0x71, 0x07, + 0x22, 0x68, 0x09, 0x0c, 0x0b, 0x43, 0x13, 0x60, 0x84, 0x23, 0x22, 0x68, + 0x93, 0x75, 0x01, 0x2f, 0x1a, 0xd1, 0x10, 0x21, 0x01, 0x2e, 0x00, 0xd0, + 0x08, 0x39, 0x0c, 0x4b, 0x69, 0x43, 0x18, 0x68, 0xc0, 0x00, 0x00, 0xf0, + 0x7b, 0xfd, 0x07, 0x22, 0x21, 0x68, 0x02, 0x40, 0x8b, 0x89, 0x52, 0x03, + 0xdb, 0x04, 0xdb, 0x0c, 0x13, 0x43, 0x8b, 0x81, 0x22, 0x68, 0x03, 0x04, + 0x90, 0x89, 0xdb, 0x0c, 0x40, 0x0b, 0x40, 0x03, 0x18, 0x43, 0x90, 0x81, + 0xf8, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, 0xf7, 0xb5, 0x06, 0x00, + 0x01, 0x93, 0x08, 0xab, 0x1f, 0x78, 0x0d, 0x00, 0x14, 0x00, 0xff, 0xf7, + 0x3f, 0xff, 0x30, 0x00, 0xff, 0xf7, 0x6a, 0xff, 0xc0, 0x22, 0x24, 0x05, + 0x92, 0x03, 0x14, 0x40, 0xba, 0x07, 0x0c, 0x27, 0x17, 0x43, 0x3c, 0x43, + 0xc0, 0x27, 0x07, 0x22, 0xbf, 0x02, 0x2d, 0x04, 0x33, 0x68, 0x3d, 0x40, + 0x25, 0x43, 0x1d, 0x60, 0x01, 0x9b, 0x31, 0x68, 0x13, 0x40, 0x1a, 0x00, + 0x80, 0x23, 0x9b, 0x02, 0x13, 0x43, 0x4b, 0x60, 0xf7, 0xbd, 0x01, 0x20, + 0x70, 0x47, 0x00, 0x00, 0x10, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, + 0x98, 0x47, 0x10, 0xbd, 0x13, 0x04, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, + 0xd9, 0x69, 0x9a, 0x69, 0x91, 0x42, 0x03, 0xd0, 0xdb, 0x69, 0xc0, 0x18, + 0x00, 0x7d, 0x70, 0x47, 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, 0x10, 0xb5, + 0x04, 0x00, 0x00, 0x69, 0xff, 0xf7, 0x96, 0xfe, 0x22, 0x00, 0x00, 0x23, + 0xfc, 0x32, 0x93, 0x61, 0xd3, 0x61, 0x86, 0x22, 0x92, 0x00, 0xa4, 0x18, + 0x63, 0x60, 0xa3, 0x60, 0x10, 0xbd, 0xf0, 0x20, 0x01, 0x40, 0x30, 0x39, + 0x48, 0x42, 0x48, 0x41, 0x70, 0x47, 0xf0, 0x23, 0x1b, 0x01, 0x19, 0x40, + 0x80, 0x23, 0x06, 0x20, 0x9b, 0x00, 0x99, 0x42, 0x0a, 0xd0, 0x01, 0x33, + 0xff, 0x33, 0x01, 0x30, 0x99, 0x42, 0x05, 0xd0, 0x80, 0x23, 0x02, 0x38, + 0x5b, 0x00, 0x99, 0x42, 0x00, 0xd0, 0x00, 0x20, 0x70, 0x47, 0x0f, 0x20, + 0x01, 0x40, 0x00, 0x20, 0x01, 0x29, 0x03, 0xd0, 0x02, 0x39, 0x48, 0x1e, + 0x81, 0x41, 0x48, 0x1c, 0x70, 0x47, 0x00, 0x00, 0x89, 0x23, 0xf0, 0xb5, + 0x18, 0x26, 0x85, 0xb0, 0x02, 0x91, 0x9b, 0x00, 0x04, 0x00, 0xc0, 0x5c, + 0x33, 0x00, 0x08, 0x21, 0x43, 0x43, 0x32, 0x4d, 0x17, 0x00, 0xeb, 0x18, + 0x59, 0x56, 0x00, 0xf0, 0x29, 0xfc, 0x30, 0x4b, 0x08, 0x21, 0xe0, 0x5c, + 0x33, 0x00, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x20, 0xfc, + 0x2c, 0x4b, 0xe2, 0x5c, 0x03, 0x93, 0x02, 0x2a, 0x09, 0xd1, 0x11, 0x33, + 0xe0, 0x5c, 0xff, 0x28, 0x05, 0xd0, 0x08, 0x21, 0x46, 0x43, 0xae, 0x19, + 0x71, 0x56, 0x00, 0xf0, 0x11, 0xfc, 0x8a, 0x26, 0xb6, 0x00, 0xa0, 0x5d, + 0xff, 0x28, 0x19, 0xd0, 0x01, 0x21, 0x00, 0xf0, 0x91, 0xfb, 0x18, 0x22, + 0xa3, 0x5d, 0x21, 0x49, 0x5a, 0x43, 0xab, 0x56, 0xad, 0x18, 0xdb, 0x01, + 0x58, 0x18, 0x8b, 0x21, 0x89, 0x00, 0x60, 0x50, 0x1d, 0x49, 0x01, 0x22, + 0x5b, 0x18, 0x8c, 0x21, 0x89, 0x00, 0x63, 0x50, 0x69, 0x68, 0x8a, 0x40, + 0x8d, 0x21, 0x89, 0x00, 0x62, 0x50, 0x1a, 0x60, 0x01, 0x22, 0x02, 0x9b, + 0x11, 0x00, 0x20, 0x69, 0xff, 0xf7, 0x0a, 0xff, 0x39, 0x00, 0x20, 0x00, + 0xff, 0xf7, 0x8f, 0xff, 0x39, 0x00, 0x05, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0x9e, 0xff, 0x39, 0x00, 0x06, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x7f, 0xff, + 0x33, 0x00, 0x00, 0x90, 0x29, 0x00, 0x20, 0x69, 0x01, 0x22, 0xff, 0xf7, + 0xd3, 0xfd, 0x0b, 0x4b, 0x20, 0x69, 0xe2, 0x5c, 0x03, 0x9b, 0xe1, 0x5c, + 0xff, 0xf7, 0xe9, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x06, 0xfe, 0x05, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x20, 0x82, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, + 0x27, 0x02, 0x00, 0x00, 0x18, 0x44, 0x00, 0x41, 0x14, 0x44, 0x00, 0x41, + 0x26, 0x02, 0x00, 0x00, 0x80, 0x22, 0x10, 0xb5, 0x04, 0x00, 0x52, 0x00, + 0x00, 0x21, 0x00, 0xf0, 0x2a, 0xfd, 0x23, 0x00, 0x00, 0x22, 0xfc, 0x33, + 0x5a, 0x60, 0x20, 0x00, 0x9a, 0x60, 0x10, 0xbd, 0xf7, 0xb5, 0x1d, 0x00, + 0x08, 0xab, 0x1b, 0x78, 0x04, 0x00, 0x00, 0x93, 0x09, 0xab, 0x1b, 0x78, + 0x16, 0x00, 0x01, 0x93, 0x00, 0x23, 0x43, 0x60, 0xfa, 0x23, 0x9b, 0x00, + 0x83, 0x60, 0x11, 0x4b, 0x0f, 0x00, 0x08, 0x33, 0x03, 0x60, 0x14, 0x30, + 0xff, 0xf7, 0xdc, 0xff, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, + 0xd7, 0xff, 0x89, 0x23, 0x6a, 0x46, 0x9b, 0x00, 0x27, 0x61, 0xe6, 0x54, + 0x09, 0x4b, 0x12, 0x78, 0xe5, 0x54, 0x09, 0x4b, 0x20, 0x00, 0xe2, 0x54, + 0x6a, 0x46, 0x08, 0x4b, 0x12, 0x79, 0xe2, 0x54, 0x8a, 0x22, 0x29, 0x3b, + 0xff, 0x3b, 0x92, 0x00, 0xa3, 0x54, 0x10, 0x32, 0xa3, 0x54, 0xfe, 0xbd, + 0x80, 0x85, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, 0x26, 0x02, 0x00, 0x00, + 0x27, 0x02, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, 0x58, 0x68, 0x9b, 0x68, + 0xc0, 0x1a, 0x01, 0xd5, 0x01, 0x30, 0xff, 0x30, 0x70, 0x47, 0x10, 0xb5, + 0x04, 0x00, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0xf0, 0xff, + 0x00, 0x28, 0xf8, 0xd1, 0x20, 0x69, 0xff, 0xf7, 0xa4, 0xfd, 0x10, 0xbd, + 0x10, 0xb5, 0x14, 0x30, 0xff, 0xf7, 0xe6, 0xff, 0x10, 0xbd, 0x03, 0x00, + 0xfc, 0x33, 0x59, 0x68, 0x9a, 0x68, 0x91, 0x42, 0x04, 0xdb, 0x5a, 0x68, + 0x98, 0x68, 0x80, 0x1a, 0xff, 0x30, 0x70, 0x47, 0x98, 0x68, 0x5b, 0x68, + 0xc0, 0x1a, 0x01, 0x38, 0xf9, 0xe7, 0x10, 0xb5, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0xeb, 0xff, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x69, + 0xff, 0xf7, 0x9f, 0xfd, 0x00, 0x28, 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, + 0xaa, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x9c, 0xfd, 0x20, 0x69, 0xff, 0xf7, + 0x84, 0xfd, 0x00, 0x28, 0x20, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x9f, 0xfd, + 0x22, 0x00, 0xfc, 0x32, 0x93, 0x69, 0xd1, 0x69, 0x01, 0x33, 0xdb, 0xb2, + 0x8b, 0x42, 0x03, 0xd0, 0x91, 0x69, 0x61, 0x18, 0x08, 0x75, 0x93, 0x61, + 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, 0x20, 0x00, + 0x14, 0x30, 0xff, 0xf7, 0xc0, 0xff, 0x09, 0x28, 0x06, 0xdc, 0x8b, 0x23, + 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, 0x1a, 0x60, + 0x20, 0x69, 0xff, 0xf7, 0x79, 0xfd, 0x00, 0x28, 0x1a, 0xd0, 0x20, 0x00, + 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0x92, 0xff, 0x00, 0x28, 0x22, 0xd0, + 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x99, 0x68, 0x5a, 0x68, 0x91, 0x42, + 0x18, 0xd0, 0x8e, 0x21, 0x9a, 0x68, 0x49, 0x00, 0xa2, 0x18, 0x51, 0x5c, + 0x9a, 0x68, 0x01, 0x32, 0xd2, 0xb2, 0x9a, 0x60, 0xc9, 0xb2, 0x20, 0x69, + 0xff, 0xf7, 0x65, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x43, 0xfd, 0x00, 0x28, + 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x42, 0xfd, 0x20, 0x69, 0xff, 0xf7, + 0x32, 0xfd, 0x10, 0xbd, 0x01, 0x21, 0x49, 0x42, 0xec, 0xe7, 0x20, 0x69, + 0xff, 0xf7, 0x5f, 0xfd, 0xec, 0xe7, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x00, + 0x00, 0x69, 0x0d, 0x00, 0xff, 0xf7, 0x42, 0xfd, 0x00, 0x28, 0x3e, 0xd1, + 0xff, 0x26, 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x5a, 0x68, 0x99, 0x68, + 0x01, 0x32, 0x32, 0x40, 0x8a, 0x42, 0x23, 0xd1, 0xef, 0xf3, 0x10, 0x83, + 0xdb, 0x07, 0x10, 0xd4, 0x1e, 0x4b, 0x5b, 0x68, 0xdb, 0x05, 0xdb, 0x0d, + 0xed, 0xd0, 0x10, 0x3b, 0x5b, 0xb2, 0x00, 0x2b, 0x10, 0xda, 0x0f, 0x22, + 0x13, 0x40, 0x08, 0x3b, 0x9b, 0x08, 0x19, 0x4a, 0x9b, 0x00, 0x9b, 0x18, + 0x1b, 0x68, 0x20, 0x69, 0xff, 0xf7, 0x1e, 0xfd, 0x00, 0x28, 0xdc, 0xd0, + 0x20, 0x00, 0xff, 0xf7, 0x6a, 0xff, 0xd8, 0xe7, 0x9b, 0x08, 0xc0, 0x33, + 0x12, 0x4a, 0x9b, 0x00, 0x9b, 0x58, 0xf0, 0xe7, 0x5a, 0x68, 0x01, 0x32, + 0x16, 0x40, 0x9a, 0x68, 0x96, 0x42, 0x05, 0xd0, 0x8e, 0x21, 0x5a, 0x68, + 0x49, 0x00, 0xa2, 0x18, 0x55, 0x54, 0x5e, 0x60, 0x20, 0x69, 0xff, 0xf7, + 0x14, 0xfd, 0x01, 0x20, 0x70, 0xbd, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0x1c, 0xff, 0x00, 0x28, 0xb9, 0xd1, 0x29, 0x00, 0x20, 0x69, + 0xff, 0xf7, 0xff, 0xfc, 0xf1, 0xe7, 0xc0, 0x46, 0x00, 0xed, 0x00, 0xe0, + 0x1c, 0xed, 0x00, 0xe0, 0x00, 0xe1, 0x00, 0xe0, 0x03, 0x00, 0x70, 0xb5, + 0xfc, 0x33, 0xd9, 0x69, 0x9a, 0x69, 0x04, 0x00, 0x91, 0x42, 0x1a, 0xd0, + 0xda, 0x69, 0x82, 0x18, 0x15, 0x7d, 0xda, 0x69, 0x01, 0x32, 0xd2, 0xb2, + 0xda, 0x61, 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, + 0x20, 0x00, 0x14, 0x30, 0xff, 0xf7, 0x11, 0xff, 0x0a, 0x28, 0x06, 0xdd, + 0x8c, 0x23, 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, + 0x1a, 0x60, 0x28, 0x00, 0x70, 0xbd, 0x01, 0x25, 0x6d, 0x42, 0xe8, 0xe7, + 0xfe, 0xe7, 0x00, 0x00, 0x03, 0x4b, 0x10, 0xb5, 0x1b, 0x68, 0x00, 0x2b, + 0x00, 0xd0, 0x98, 0x47, 0x10, 0xbd, 0xc0, 0x46, 0x90, 0x0e, 0x00, 0x20, + 0x70, 0xb5, 0x0f, 0x49, 0x0f, 0x4c, 0xa1, 0x42, 0x04, 0xd1, 0x00, 0xf0, + 0x81, 0xf8, 0xfa, 0xf7, 0x27, 0xfe, 0xfe, 0xe7, 0x0c, 0x4d, 0x00, 0x23, + 0x8d, 0x42, 0xf6, 0xd0, 0xca, 0x18, 0xe8, 0x18, 0xa2, 0x42, 0x05, 0xd3, + 0x09, 0x4b, 0x82, 0x42, 0xef, 0xd0, 0x09, 0x49, 0x00, 0x22, 0x04, 0xe0, + 0x00, 0x68, 0x04, 0x33, 0x10, 0x60, 0xf1, 0xe7, 0x04, 0xc3, 0x8b, 0x42, + 0xfc, 0xd3, 0xe4, 0xe7, 0x00, 0x00, 0x00, 0x20, 0x30, 0x00, 0x00, 0x20, + 0xb8, 0x85, 0x00, 0x00, 0x30, 0x00, 0x00, 0x20, 0x98, 0x0e, 0x00, 0x20, + 0x10, 0xb5, 0x00, 0xf0, 0x58, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x00, 0xf0, + 0x49, 0xf8, 0x10, 0xbd, 0xf7, 0xb5, 0x13, 0x48, 0x01, 0x22, 0x84, 0x46, + 0x12, 0x49, 0x13, 0x4c, 0x8e, 0x68, 0x63, 0x68, 0x05, 0x68, 0x9b, 0x0e, + 0x13, 0x40, 0x01, 0x92, 0x88, 0x68, 0x62, 0x68, 0x01, 0x9f, 0x92, 0x0e, + 0x3a, 0x40, 0x67, 0x46, 0x3f, 0x68, 0x93, 0x42, 0x0e, 0xd1, 0xbd, 0x42, + 0x0c, 0xd1, 0x86, 0x42, 0x0a, 0xd3, 0x5b, 0x19, 0xfa, 0x25, 0x48, 0x68, + 0xad, 0x00, 0x86, 0x1b, 0x07, 0x48, 0x6b, 0x43, 0x70, 0x43, 0x00, 0x0d, + 0xc0, 0x18, 0xfe, 0xbd, 0x3d, 0x00, 0x13, 0x00, 0x06, 0x00, 0xe3, 0xe7, + 0x94, 0x0e, 0x00, 0x20, 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, + 0x55, 0x55, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x1e, 0x10, 0xd0, 0xff, 0xf7, + 0xcb, 0xff, 0x05, 0x00, 0x00, 0xf0, 0x1a, 0xf8, 0xff, 0xf7, 0xc6, 0xff, + 0x05, 0x4b, 0x40, 0x1b, 0x98, 0x42, 0xf7, 0xd9, 0xfa, 0x23, 0x01, 0x3c, + 0x9b, 0x00, 0xed, 0x18, 0x00, 0x2c, 0xf3, 0xd1, 0x70, 0xbd, 0xc0, 0x46, + 0xe7, 0x03, 0x00, 0x00, 0x10, 0xb5, 0x03, 0x4a, 0x13, 0x68, 0x01, 0x33, + 0x13, 0x60, 0x00, 0xf0, 0x45, 0xfa, 0x10, 0xbd, 0x94, 0x0e, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, 0x1e, 0x22, 0x70, 0xb5, + 0x46, 0x48, 0x47, 0x49, 0x43, 0x68, 0x93, 0x43, 0x1c, 0x3a, 0x13, 0x43, + 0x43, 0x60, 0x08, 0x23, 0x8c, 0x69, 0x23, 0x43, 0x8b, 0x61, 0x43, 0x4c, + 0x43, 0x4b, 0x9c, 0x82, 0x9c, 0x8a, 0x14, 0x43, 0x9c, 0x82, 0xdc, 0x68, + 0x14, 0x42, 0xfc, 0xd0, 0x01, 0x24, 0x40, 0x4a, 0x14, 0x70, 0x15, 0x78, + 0x25, 0x42, 0x03, 0xd0, 0x55, 0x78, 0x6d, 0xb2, 0x00, 0x2d, 0xf8, 0xdb, + 0x01, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, + 0x39, 0x4c, 0x54, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, + 0x82, 0x24, 0xe4, 0x01, 0x54, 0x80, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x02, 0x24, 0x9c, 0x84, 0x0e, 0x34, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x31, 0x4c, 0xdc, 0x62, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x9d, 0x8c, 0x2e, 0x4c, 0x2c, 0x43, 0x9c, 0x84, 0x10, 0x24, + 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x02, 0x24, 0x9d, 0x8c, 0x80, 0x26, + 0x2c, 0x43, 0x9c, 0x84, 0x40, 0x24, 0xdd, 0x68, 0x35, 0x42, 0xfc, 0xd0, + 0xdd, 0x68, 0x25, 0x42, 0xf9, 0xd0, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x00, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x21, 0x4c, 0x54, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x1c, 0x6a, 0x1e, 0x4d, 0x2c, 0x40, 0x80, 0x25, 0x1c, 0x62, + 0x1c, 0x6a, 0xac, 0x43, 0x1c, 0x62, 0x03, 0x23, 0x93, 0x60, 0x1b, 0x4b, + 0x53, 0x60, 0x53, 0x78, 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x00, 0x23, + 0xff, 0x24, 0x0b, 0x72, 0x17, 0x4a, 0x4b, 0x72, 0x8b, 0x72, 0xcb, 0x72, + 0x16, 0x4b, 0x1a, 0x60, 0x16, 0x4b, 0x17, 0x4a, 0x1b, 0x68, 0x11, 0x68, + 0x9a, 0x06, 0x5b, 0x01, 0xc9, 0x0e, 0x23, 0x40, 0x52, 0x0f, 0x12, 0x02, + 0x0b, 0x43, 0x13, 0x43, 0x12, 0x4a, 0x13, 0x85, 0x80, 0x23, 0x42, 0x68, + 0x13, 0x43, 0x43, 0x60, 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x00, 0x04, 0x00, 0x40, 0x0c, 0x06, 0x00, 0x00, 0x00, 0x08, 0x00, 0x40, + 0x00, 0x0c, 0x00, 0x40, 0x01, 0x05, 0x01, 0x00, 0xb9, 0x05, 0xff, 0x7d, + 0x04, 0x0a, 0x00, 0x00, 0x00, 0x07, 0x03, 0x00, 0xff, 0xfc, 0xff, 0xff, + 0x03, 0x06, 0x01, 0x00, 0x00, 0x6c, 0xdc, 0x02, 0x00, 0x00, 0x00, 0x20, + 0x24, 0x60, 0x80, 0x00, 0x20, 0x60, 0x80, 0x00, 0x00, 0x40, 0x00, 0x42, + 0xfa, 0x21, 0x2d, 0x4b, 0x10, 0xb5, 0x18, 0x68, 0x89, 0x00, 0x00, 0xf0, + 0xcd, 0xf9, 0x2b, 0x4b, 0x01, 0x38, 0x98, 0x42, 0x4f, 0xd8, 0x2a, 0x49, + 0x2a, 0x4a, 0x48, 0x60, 0xc0, 0x20, 0x13, 0x6a, 0x00, 0x06, 0x1b, 0x02, + 0x1b, 0x0a, 0x03, 0x43, 0x13, 0x62, 0x00, 0x23, 0x8b, 0x60, 0x07, 0x33, + 0x0b, 0x60, 0x80, 0x21, 0x13, 0x6a, 0x09, 0x06, 0x1b, 0x02, 0x1b, 0x0a, + 0x0b, 0x43, 0x13, 0x62, 0xfc, 0x22, 0x21, 0x4b, 0x19, 0x6a, 0x0a, 0x43, + 0x1a, 0x62, 0xfc, 0x22, 0x19, 0x6a, 0x92, 0x01, 0x0a, 0x43, 0x1a, 0x62, + 0xa0, 0x22, 0x19, 0x6a, 0xd2, 0x02, 0x0a, 0x43, 0x1a, 0x62, 0x1b, 0x4b, + 0x1c, 0x00, 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, 0x19, 0x4a, + 0x5a, 0x80, 0x19, 0x4b, 0x1a, 0x00, 0x59, 0x7e, 0xc9, 0x09, 0x01, 0x29, + 0xfb, 0xd0, 0xe4, 0x21, 0xc9, 0x00, 0x99, 0x80, 0x3f, 0x21, 0xd9, 0x70, + 0x53, 0x7e, 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0xc0, 0x23, 0x00, 0x20, + 0x5b, 0x01, 0x13, 0x61, 0x90, 0x70, 0x00, 0xf0, 0x23, 0xf8, 0x63, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x0d, 0x4b, 0x0d, 0x4a, 0x63, 0x80, + 0xd3, 0x79, 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0x41, 0x23, 0x53, 0x70, + 0x10, 0xbd, 0xfe, 0xe7, 0x00, 0x00, 0x00, 0x20, 0xff, 0xff, 0xff, 0x00, + 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, 0x00, 0x04, 0x00, 0x40, + 0x00, 0x0c, 0x00, 0x40, 0x1e, 0x40, 0x00, 0x00, 0x00, 0x40, 0x00, 0x42, + 0x21, 0x40, 0x00, 0x00, 0x00, 0x48, 0x00, 0x42, 0x16, 0x4a, 0x00, 0xb5, + 0x13, 0x00, 0x51, 0x7e, 0xc9, 0x09, 0x01, 0x29, 0xfb, 0xd0, 0x01, 0x38, + 0x04, 0x28, 0x16, 0xd8, 0x19, 0x69, 0x12, 0x4a, 0x0a, 0x40, 0x0f, 0x21, + 0x1a, 0x61, 0x5a, 0x78, 0x8a, 0x43, 0x00, 0xf0, 0x47, 0xf9, 0x03, 0x08, + 0x06, 0x0b, 0x03, 0x00, 0x11, 0x00, 0x01, 0x22, 0x0a, 0x43, 0x5a, 0x70, + 0x00, 0xbd, 0x11, 0x00, 0x03, 0x22, 0xf9, 0xe7, 0x11, 0x00, 0x02, 0x22, + 0xf6, 0xe7, 0xf0, 0x23, 0x11, 0x69, 0x1b, 0x05, 0x0b, 0x43, 0x0f, 0x21, + 0x13, 0x61, 0x53, 0x78, 0x8b, 0x43, 0x19, 0x00, 0x02, 0x23, 0x0b, 0x43, + 0x53, 0x70, 0xeb, 0xe7, 0x00, 0x40, 0x00, 0x42, 0xff, 0xff, 0xff, 0xf0, + 0x18, 0x23, 0x30, 0xb5, 0x1d, 0x00, 0x04, 0x00, 0x45, 0x43, 0x08, 0x20, + 0x20, 0x4a, 0x55, 0x19, 0x28, 0x56, 0x01, 0x30, 0x14, 0xd0, 0x03, 0x29, + 0x12, 0xd8, 0x08, 0x00, 0x63, 0x43, 0xd1, 0x56, 0xd3, 0x18, 0x00, 0xf0, + 0x15, 0xf9, 0x02, 0x28, 0x0e, 0x1b, 0x58, 0x68, 0xcb, 0x01, 0x02, 0x21, + 0x18, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, + 0x82, 0x40, 0x5a, 0x60, 0x30, 0xbd, 0x58, 0x68, 0xcb, 0x01, 0x06, 0x21, + 0x12, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, + 0x82, 0x40, 0x5a, 0x60, 0x9a, 0x61, 0xf1, 0xe7, 0x58, 0x68, 0xcb, 0x01, + 0x06, 0x21, 0x0c, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, + 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x5a, 0x61, 0xe4, 0xe7, 0x58, 0x68, + 0xcb, 0x01, 0x02, 0x21, 0x05, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, + 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x9a, 0x60, 0xd8, 0xe7, 0xc0, 0x46, + 0x20, 0x82, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0x18, 0x23, 0xf0, 0xb5, + 0x08, 0x24, 0x58, 0x43, 0x11, 0x4a, 0x13, 0x18, 0x1c, 0x57, 0x01, 0x34, + 0x1b, 0xd0, 0x01, 0x26, 0x35, 0x00, 0x5f, 0x68, 0x83, 0x56, 0xbd, 0x40, + 0x0d, 0x4a, 0xdb, 0x01, 0x9a, 0x18, 0x90, 0x68, 0x05, 0x42, 0x0b, 0xd1, + 0x0c, 0x00, 0x60, 0x1e, 0x84, 0x41, 0xd2, 0x19, 0x40, 0x32, 0x10, 0x78, + 0x34, 0x40, 0x03, 0x36, 0xa4, 0x00, 0xb0, 0x43, 0x20, 0x43, 0x10, 0x70, + 0x04, 0x4a, 0x9b, 0x18, 0x00, 0x29, 0x01, 0xd1, 0x5d, 0x61, 0xf0, 0xbd, + 0x9d, 0x61, 0xfc, 0xe7, 0x20, 0x82, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x18, 0x22, 0x42, 0x43, 0xf8, 0xb5, 0x2c, 0x4e, 0x03, 0x00, 0xb2, 0x18, + 0x12, 0x7a, 0x52, 0xb2, 0x14, 0x00, 0x01, 0x32, 0x0e, 0xd0, 0x48, 0x1c, + 0x00, 0x24, 0x0c, 0x28, 0x0a, 0xd8, 0x00, 0xf0, 0x9f, 0xf8, 0x07, 0x1f, + 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x0b, 0x0b, 0x0b, 0x0b, 0x00, + 0x01, 0x24, 0x64, 0x42, 0x20, 0x00, 0xf8, 0xbd, 0x09, 0x29, 0x05, 0xd1, + 0x00, 0x21, 0x18, 0x00, 0xff, 0xf7, 0x66, 0xff, 0x00, 0x24, 0xf5, 0xe7, + 0x0a, 0x29, 0x01, 0xd1, 0x08, 0x39, 0xf6, 0xe7, 0x00, 0x24, 0x0b, 0x29, + 0xee, 0xd1, 0x0a, 0x39, 0x18, 0x00, 0xff, 0xf7, 0x59, 0xff, 0xe9, 0xe7, + 0x18, 0x22, 0x53, 0x43, 0xf2, 0x18, 0x55, 0x68, 0x01, 0x20, 0x2c, 0x00, + 0xf3, 0x56, 0x13, 0x4a, 0xdb, 0x01, 0x6e, 0x08, 0x9b, 0x18, 0xc9, 0xb2, + 0x04, 0x40, 0x9e, 0x19, 0x00, 0x2c, 0x0d, 0xd0, 0x0f, 0x24, 0x30, 0x36, + 0x32, 0x78, 0x09, 0x01, 0x22, 0x40, 0x11, 0x43, 0xc9, 0xb2, 0x5b, 0x19, + 0x31, 0x70, 0x40, 0x33, 0x1a, 0x78, 0x10, 0x43, 0x18, 0x70, 0xd3, 0xe7, + 0x32, 0x00, 0x0f, 0x27, 0x30, 0x32, 0x16, 0x78, 0x5b, 0x19, 0xbe, 0x43, + 0x31, 0x43, 0x11, 0x70, 0x40, 0x33, 0x1a, 0x78, 0x10, 0x43, 0x18, 0x70, + 0xbe, 0xe7, 0xc0, 0x46, 0x20, 0x82, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0xf7, 0xb5, 0x06, 0x00, 0x0d, 0x00, 0x0c, 0x00, 0x8b, 0x18, 0x01, 0x93, + 0x01, 0x9b, 0x67, 0x1b, 0x9c, 0x42, 0x07, 0xd0, 0x33, 0x68, 0x21, 0x78, + 0x1b, 0x68, 0x30, 0x00, 0x98, 0x47, 0x01, 0x34, 0x00, 0x28, 0xf3, 0xd1, + 0x38, 0x00, 0xfe, 0xbd, 0x16, 0x4a, 0x10, 0xb5, 0x13, 0x68, 0x59, 0x1c, + 0x26, 0xd0, 0x01, 0x3b, 0x13, 0x60, 0x00, 0x2b, 0x22, 0xd1, 0x72, 0xb6, + 0x12, 0x4b, 0x13, 0x4a, 0x04, 0x33, 0x93, 0x42, 0x13, 0xd9, 0x12, 0x4a, + 0x01, 0x21, 0x10, 0x00, 0x14, 0x7d, 0x0c, 0x42, 0xfc, 0xd0, 0x20, 0x21, + 0x14, 0x8b, 0xff, 0x31, 0x9b, 0x08, 0x5b, 0x00, 0x21, 0x43, 0x11, 0x83, + 0xd3, 0x61, 0x0c, 0x4b, 0x13, 0x80, 0x01, 0x23, 0x02, 0x7d, 0x1a, 0x42, + 0xfc, 0xd0, 0xbf, 0xf3, 0x4f, 0x8f, 0x09, 0x4b, 0x09, 0x4a, 0xda, 0x60, + 0xbf, 0xf3, 0x4f, 0x8f, 0xc0, 0x46, 0xfd, 0xe7, 0x10, 0xbd, 0xc0, 0x46, + 0x04, 0x00, 0x00, 0x20, 0x00, 0x20, 0x00, 0x00, 0x03, 0x02, 0x00, 0x00, + 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, 0x00, 0xed, 0x00, 0xe0, + 0x04, 0x00, 0xfa, 0x05, 0x02, 0xb4, 0x71, 0x46, 0x49, 0x08, 0x49, 0x00, + 0x09, 0x5c, 0x49, 0x00, 0x8e, 0x44, 0x02, 0xbc, 0x70, 0x47, 0xc0, 0x46, + 0x00, 0x22, 0x43, 0x08, 0x8b, 0x42, 0x74, 0xd3, 0x03, 0x09, 0x8b, 0x42, + 0x5f, 0xd3, 0x03, 0x0a, 0x8b, 0x42, 0x44, 0xd3, 0x03, 0x0b, 0x8b, 0x42, + 0x28, 0xd3, 0x03, 0x0c, 0x8b, 0x42, 0x0d, 0xd3, 0xff, 0x22, 0x09, 0x02, + 0x12, 0xba, 0x03, 0x0c, 0x8b, 0x42, 0x02, 0xd3, 0x12, 0x12, 0x09, 0x02, + 0x65, 0xd0, 0x03, 0x0b, 0x8b, 0x42, 0x19, 0xd3, 0x00, 0xe0, 0x09, 0x0a, + 0xc3, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x03, 0xc0, 0x1a, 0x52, 0x41, + 0x83, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x03, 0xc0, 0x1a, 0x52, 0x41, + 0x43, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x03, 0xc0, 0x1a, 0x52, 0x41, + 0x03, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x03, 0xc0, 0x1a, 0x52, 0x41, + 0xc3, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x02, 0xc0, 0x1a, 0x52, 0x41, + 0x83, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x02, 0xc0, 0x1a, 0x52, 0x41, + 0x43, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x02, 0xc0, 0x1a, 0x52, 0x41, + 0x03, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x02, 0xc0, 0x1a, 0x52, 0x41, + 0xcd, 0xd2, 0xc3, 0x09, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x01, 0xc0, 0x1a, + 0x52, 0x41, 0x83, 0x09, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x01, 0xc0, 0x1a, + 0x52, 0x41, 0x43, 0x09, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x01, 0xc0, 0x1a, + 0x52, 0x41, 0x03, 0x09, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x01, 0xc0, 0x1a, + 0x52, 0x41, 0xc3, 0x08, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x00, 0xc0, 0x1a, + 0x52, 0x41, 0x83, 0x08, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x00, 0xc0, 0x1a, + 0x52, 0x41, 0x43, 0x08, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x00, 0xc0, 0x1a, + 0x52, 0x41, 0x41, 0x1a, 0x00, 0xd2, 0x01, 0x46, 0x52, 0x41, 0x10, 0x46, + 0x70, 0x47, 0xff, 0xe7, 0x01, 0xb5, 0x00, 0x20, 0x00, 0xf0, 0x06, 0xf8, + 0x02, 0xbd, 0xc0, 0x46, 0x00, 0x29, 0xf7, 0xd0, 0x76, 0xe7, 0x70, 0x47, + 0x70, 0x47, 0xc0, 0x46, 0x70, 0xb5, 0x00, 0x26, 0x0c, 0x4d, 0x0d, 0x4c, + 0x64, 0x1b, 0xa4, 0x10, 0xa6, 0x42, 0x09, 0xd1, 0x00, 0x26, 0x00, 0xf0, + 0x4f, 0xf8, 0x0a, 0x4d, 0x0a, 0x4c, 0x64, 0x1b, 0xa4, 0x10, 0xa6, 0x42, + 0x05, 0xd1, 0x70, 0xbd, 0xb3, 0x00, 0xeb, 0x58, 0x98, 0x47, 0x01, 0x36, + 0xee, 0xe7, 0xb3, 0x00, 0xeb, 0x58, 0x98, 0x47, 0x01, 0x36, 0xf2, 0xe7, + 0x08, 0x00, 0x00, 0x20, 0x08, 0x00, 0x00, 0x20, 0x08, 0x00, 0x00, 0x20, + 0x24, 0x00, 0x00, 0x20, 0x00, 0x23, 0x10, 0xb5, 0x9a, 0x42, 0x00, 0xd1, + 0x10, 0xbd, 0xcc, 0x5c, 0xc4, 0x54, 0x01, 0x33, 0xf8, 0xe7, 0x03, 0x00, + 0x12, 0x18, 0x93, 0x42, 0x00, 0xd1, 0x70, 0x47, 0x19, 0x70, 0x01, 0x33, + 0xf9, 0xe7, 0x02, 0x78, 0x0b, 0x78, 0x00, 0x2a, 0x03, 0xd0, 0x01, 0x30, + 0x01, 0x31, 0x9a, 0x42, 0xf7, 0xd0, 0xd0, 0x1a, 0x70, 0x47, 0x00, 0x23, + 0xc2, 0x5c, 0x01, 0x33, 0x00, 0x2a, 0xfb, 0xd1, 0x58, 0x1e, 0x70, 0x47, + 0x30, 0xb5, 0x05, 0x00, 0x00, 0x2a, 0x00, 0xd1, 0x30, 0xbd, 0x0c, 0x78, + 0x01, 0x3a, 0x6b, 0x1c, 0x2c, 0x70, 0x01, 0x31, 0x00, 0x2c, 0x05, 0xd1, + 0x9a, 0x18, 0x9a, 0x42, 0xf4, 0xd0, 0x1c, 0x70, 0x01, 0x33, 0xfa, 0xe7, + 0x1d, 0x00, 0xed, 0xe7, 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, + 0x9e, 0x46, 0x70, 0x47, 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, + 0x9e, 0x46, 0x70, 0x47, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x2e, 0x42, + 0x49, 0x4e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x10, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, + 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, + 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x04, + 0x00, 0x04, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x01, + 0x00, 0x01, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x13, 0x00, 0x01, 0x01, + 0x01, 0x01, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x05, + 0x00, 0x05, 0x0a, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x05, + 0x01, 0x05, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x02, 0x00, + 0x02, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, + 0x03, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x02, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x03, + 0x01, 0x03, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x10, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x11, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0a, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0b, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x05, 0x00, 0x01, 0x00, + 0x01, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x06, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x07, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x02, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x03, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x85, 0x73, 0x00, 0x00, 0x01, 0x7a, 0x00, 0x00, 0xab, 0x72, 0x00, 0x00, + 0x67, 0x72, 0x00, 0x00, 0x81, 0x72, 0x00, 0x00, 0x39, 0x74, 0x00, 0x00, + 0x49, 0x70, 0x00, 0x00, 0x39, 0x70, 0x00, 0x00, 0xcd, 0x70, 0x00, 0x00, + 0x63, 0x70, 0x00, 0x00, 0x33, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x40, 0x42, 0x0f, 0x00, 0xff, 0xff, 0xff, 0xff, 0xdd, 0x20, 0x00, 0x00, + 0x25, 0x22, 0x00, 0x00, 0x39, 0x22, 0x00, 0x00, 0xa5, 0x23, 0x00, 0x00, + 0x3d, 0x26, 0x00, 0x00, 0x41, 0x6c, 0x00, 0x00, 0xb5, 0x6c, 0x00, 0x00, + 0xb5, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 diff --git a/libraries/SFU/src/boot/mkrgsm1400.h b/libraries/SFU/src/boot/mkrgsm1400.h new file mode 100644 index 0000000..93b7df3 --- /dev/null +++ b/libraries/SFU/src/boot/mkrgsm1400.h @@ -0,0 +1,2196 @@ + 0x00, 0x80, 0x00, 0x20, 0x31, 0x75, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, + 0x19, 0x75, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, + 0x85, 0x75, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, + 0x19, 0x75, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, + 0x19, 0x75, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, 0x1d, 0x75, 0x00, 0x00, + 0x19, 0x75, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, + 0x19, 0x75, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, 0x91, 0x6c, 0x00, 0x00, + 0x81, 0x6c, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, + 0x19, 0x75, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, + 0x19, 0x75, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, + 0x19, 0x75, 0x00, 0x00, 0x19, 0x75, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0x30, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xb4, 0x86, 0x00, 0x00, 0x04, 0x4b, 0x10, 0xb5, 0x00, 0x2b, 0x03, 0xd0, + 0x03, 0x49, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x10, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x00, 0x34, 0x00, 0x00, 0x20, 0xb4, 0x86, 0x00, 0x00, + 0xf0, 0xb5, 0x40, 0x4c, 0xa5, 0x44, 0x00, 0xaf, 0x05, 0xf0, 0x4c, 0xfb, + 0x05, 0xf0, 0xb2, 0xfd, 0x01, 0x20, 0x05, 0xf0, 0x71, 0xfa, 0x3c, 0x48, + 0x00, 0xf0, 0x8c, 0xf9, 0x3b, 0x4c, 0x20, 0x00, 0x00, 0xf0, 0x1c, 0xf9, + 0x00, 0x28, 0x5d, 0xd1, 0x20, 0x00, 0x02, 0xf0, 0x29, 0xfb, 0x00, 0x28, + 0x58, 0xd1, 0x20, 0x00, 0x02, 0xf0, 0x44, 0xf9, 0x0c, 0x20, 0x08, 0x23, + 0x34, 0x4a, 0x21, 0x00, 0x38, 0x18, 0x00, 0xf0, 0x23, 0xf9, 0x20, 0x00, + 0x02, 0xf0, 0x38, 0xf9, 0x05, 0x1e, 0x45, 0xd1, 0x0c, 0x23, 0x01, 0x00, + 0x02, 0x22, 0xf8, 0x18, 0x00, 0xf0, 0x42, 0xf9, 0x80, 0x21, 0x78, 0x60, + 0x09, 0x02, 0x2e, 0x00, 0x88, 0x42, 0x2c, 0xdd, 0x0c, 0x23, 0x2a, 0x00, + 0xf8, 0x18, 0x00, 0xf0, 0x37, 0xf9, 0x28, 0x4a, 0xa0, 0x21, 0x94, 0x46, + 0x7b, 0x68, 0x09, 0x02, 0x63, 0x44, 0x1a, 0x00, 0x25, 0x48, 0xa0, 0x25, + 0x80, 0x26, 0x7b, 0x60, 0x00, 0xf0, 0xd6, 0xf8, 0x2d, 0x02, 0xb6, 0x00, + 0x08, 0x23, 0xf8, 0x18, 0xc1, 0x18, 0x04, 0x33, 0x32, 0x00, 0xf8, 0x18, + 0x00, 0xf0, 0x14, 0xf9, 0x08, 0x22, 0xb9, 0x18, 0x8a, 0x18, 0x33, 0x00, + 0x29, 0x00, 0x1b, 0x48, 0x00, 0xf0, 0x74, 0xf8, 0x80, 0x22, 0x1a, 0x4b, + 0x92, 0x00, 0xeb, 0x18, 0xad, 0x18, 0x7a, 0x68, 0x93, 0x42, 0xe7, 0xdb, + 0x01, 0x26, 0x0c, 0x23, 0xf8, 0x18, 0x00, 0xf0, 0x17, 0xf9, 0x00, 0x2e, + 0x03, 0xd0, 0x10, 0x49, 0x20, 0x00, 0x02, 0xf0, 0x55, 0xfa, 0x20, 0x00, + 0x02, 0xf0, 0xca, 0xf8, 0x0c, 0x23, 0xf8, 0x18, 0x00, 0xf0, 0x14, 0xf9, + 0xa0, 0x23, 0x1b, 0x02, 0x1a, 0x68, 0x82, 0xf3, 0x08, 0x88, 0x0c, 0x4a, + 0x93, 0x60, 0x0c, 0x4b, 0x1b, 0x68, 0x18, 0x47, 0x00, 0x20, 0xbd, 0x46, + 0x85, 0x23, 0x9b, 0x00, 0x9d, 0x44, 0xf0, 0xbd, 0xec, 0xfd, 0xff, 0xff, + 0xf4, 0x0b, 0x00, 0x20, 0x8c, 0x04, 0x00, 0x20, 0x3c, 0x7d, 0x00, 0x00, + 0x00, 0x80, 0xff, 0xff, 0x4c, 0x00, 0x00, 0x20, 0x00, 0x62, 0xff, 0xff, + 0x00, 0xed, 0x00, 0xe0, 0x04, 0xa0, 0x00, 0x00, 0x00, 0x22, 0x10, 0xb5, + 0x11, 0x00, 0x02, 0x48, 0x00, 0xf0, 0x1a, 0xf8, 0x10, 0xbd, 0xc0, 0x46, + 0x4c, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x05, 0x4a, 0x05, 0x49, 0x06, 0x48, + 0x00, 0xf0, 0x10, 0xf8, 0x00, 0x22, 0x05, 0x4b, 0x05, 0x49, 0x1a, 0x70, + 0x5a, 0x54, 0x10, 0xbd, 0x01, 0x04, 0x00, 0x00, 0x00, 0x7e, 0x00, 0x00, + 0x68, 0x04, 0x00, 0x20, 0x64, 0x00, 0x00, 0x20, 0x02, 0x04, 0x00, 0x00, + 0x30, 0xb5, 0x09, 0x4d, 0x09, 0x4c, 0xab, 0x68, 0x5b, 0x03, 0x5b, 0x0f, + 0x9b, 0x00, 0x1c, 0x59, 0x04, 0x60, 0xab, 0x68, 0x01, 0x61, 0x9b, 0xb2, + 0x43, 0x60, 0x63, 0x43, 0xa4, 0x00, 0x83, 0x60, 0xc4, 0x60, 0x42, 0x61, + 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, 0x00, 0x83, 0x00, 0x00, + 0xf7, 0xb5, 0x80, 0x26, 0x1a, 0x4d, 0x01, 0x91, 0x6f, 0x68, 0x03, 0x33, + 0x3e, 0x43, 0x9b, 0x08, 0x6e, 0x60, 0x00, 0x2b, 0x2b, 0xd0, 0x17, 0x4e, + 0x2e, 0x80, 0x2e, 0x7d, 0xf1, 0x07, 0xfc, 0xd5, 0x1e, 0x00, 0x07, 0x68, + 0x99, 0x1b, 0xbf, 0x08, 0x8f, 0x42, 0x19, 0xd9, 0x00, 0x2e, 0x17, 0xd0, + 0xff, 0x21, 0x17, 0x78, 0x8c, 0x43, 0x3c, 0x43, 0x0f, 0x49, 0x57, 0x78, + 0x0c, 0x40, 0x3f, 0x02, 0x3c, 0x43, 0x97, 0x78, 0x01, 0x3e, 0x39, 0x04, + 0x0c, 0x4f, 0x27, 0x40, 0xd4, 0x78, 0xbf, 0xb2, 0x0f, 0x43, 0x24, 0x06, + 0x01, 0x99, 0x3c, 0x43, 0x10, 0xc1, 0x01, 0x91, 0x04, 0x32, 0xe0, 0xe7, + 0x07, 0x4b, 0x2b, 0x80, 0x2b, 0x7d, 0xdb, 0x07, 0xfc, 0xd5, 0x33, 0x00, + 0xd1, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x44, 0xa5, 0xff, 0xff, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, 0x04, 0xa5, 0xff, 0xff, + 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, 0x1a, 0x80, 0x1a, 0x7d, + 0xd2, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x16, 0x00, + 0xe3, 0x68, 0x29, 0x00, 0x20, 0x00, 0xb3, 0x42, 0x05, 0xd2, 0xff, 0xf7, + 0xe7, 0xff, 0xe3, 0x68, 0xed, 0x18, 0xf6, 0x1a, 0xf4, 0xe7, 0xff, 0xf7, + 0xe1, 0xff, 0x70, 0xbd, 0x1f, 0xb5, 0x00, 0x21, 0x03, 0x91, 0x90, 0x21, + 0xc9, 0x00, 0x02, 0x91, 0xa1, 0x39, 0xff, 0x39, 0x41, 0x18, 0x98, 0x23, + 0x01, 0x91, 0x02, 0x00, 0x80, 0x21, 0x9b, 0x00, 0x00, 0x91, 0xc3, 0x18, + 0x60, 0x32, 0x02, 0x49, 0x01, 0xf0, 0x9c, 0xff, 0x05, 0xb0, 0x00, 0xbd, + 0x80, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, 0x08, 0x00, 0x11, 0x00, + 0x1a, 0x00, 0x00, 0x23, 0x02, 0xf0, 0x16, 0xf8, 0x01, 0x00, 0x20, 0x00, + 0x00, 0xf0, 0x3a, 0xf8, 0x20, 0x00, 0x10, 0xbd, 0x03, 0x4b, 0x04, 0x4a, + 0x1a, 0x60, 0x04, 0x4a, 0x5a, 0x60, 0x04, 0x4a, 0x9a, 0x60, 0x70, 0x47, + 0x80, 0x04, 0x00, 0x20, 0x01, 0x26, 0x00, 0x00, 0x15, 0x26, 0x00, 0x00, + 0x29, 0x26, 0x00, 0x00, 0x10, 0xb5, 0x0c, 0x00, 0x13, 0x00, 0x00, 0x22, + 0x81, 0x5e, 0x22, 0x00, 0x01, 0x48, 0x02, 0xf0, 0x87, 0xf8, 0x10, 0xbd, + 0x8c, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x0c, 0x00, 0x13, 0x00, 0x00, 0x22, + 0x81, 0x5e, 0x22, 0x00, 0x01, 0x48, 0x02, 0xf0, 0xdd, 0xf8, 0x10, 0xbd, + 0x8c, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x00, 0x23, 0xc1, 0x5e, 0x02, 0x48, + 0x02, 0xf0, 0x9c, 0xf9, 0x10, 0xbd, 0xc0, 0x46, 0x8c, 0x04, 0x00, 0x20, + 0x10, 0xb5, 0x04, 0x00, 0xff, 0xf7, 0xf2, 0xff, 0x20, 0x00, 0x10, 0xbd, + 0x01, 0x80, 0x70, 0x47, 0x10, 0xb5, 0x00, 0x21, 0x40, 0x68, 0x05, 0xf0, + 0xb5, 0xfa, 0x10, 0xbd, 0x10, 0xb5, 0x01, 0x21, 0x40, 0x68, 0x05, 0xf0, + 0xaf, 0xfa, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x68, 0x04, 0xf0, + 0xb9, 0xfb, 0x01, 0x21, 0x60, 0x68, 0x05, 0xf0, 0x59, 0xfa, 0x20, 0x00, + 0xff, 0xf7, 0xee, 0xff, 0x10, 0xbd, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x00, + 0xff, 0xf7, 0xe2, 0xff, 0x09, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, + 0xcf, 0xfb, 0x05, 0x21, 0x20, 0x68, 0x04, 0xf0, 0xe7, 0xfb, 0x00, 0x21, + 0x20, 0x68, 0x04, 0xf0, 0xe3, 0xfb, 0x05, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0xd7, 0xff, 0x28, 0x00, 0x70, 0xbd, 0xc0, 0x46, 0xec, 0x0b, 0x00, 0x20, + 0x10, 0xb5, 0xff, 0xf7, 0xe3, 0xff, 0x01, 0x23, 0x18, 0x40, 0x10, 0xbd, + 0xf7, 0xb5, 0x04, 0x00, 0x0e, 0x00, 0x15, 0x00, 0x10, 0x27, 0x01, 0x93, + 0x20, 0x00, 0xff, 0xf7, 0xf1, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x3b, 0x00, + 0x01, 0x3b, 0xfd, 0xd1, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xb4, 0xff, + 0x12, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, 0xa1, 0xfb, 0x03, 0x21, + 0x20, 0x68, 0x04, 0xf0, 0xb9, 0xfb, 0x31, 0x0c, 0xc9, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0xb4, 0xfb, 0x31, 0x0a, 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, + 0xaf, 0xfb, 0xf1, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0xab, 0xfb, 0x01, 0x9b, + 0xee, 0x18, 0xb5, 0x42, 0x06, 0xd0, 0x00, 0x21, 0x20, 0x68, 0x04, 0xf0, + 0xa3, 0xfb, 0x28, 0x70, 0x01, 0x35, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, + 0x95, 0xff, 0xf7, 0xbd, 0xec, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, + 0xff, 0xf7, 0x88, 0xff, 0x06, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, + 0x75, 0xfb, 0x06, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x8d, 0xfb, 0x20, 0x00, + 0xff, 0xf7, 0x82, 0xff, 0x10, 0xbd, 0xc0, 0x46, 0xec, 0x0b, 0x00, 0x20, + 0xf7, 0xb5, 0x04, 0x00, 0x0e, 0x00, 0x15, 0x00, 0x10, 0x27, 0x01, 0x93, + 0x20, 0x00, 0xff, 0xf7, 0xa3, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x3b, 0x00, + 0x01, 0x3b, 0xfd, 0xd1, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xda, 0xff, + 0x20, 0x00, 0xff, 0xf7, 0x63, 0xff, 0x12, 0x4b, 0x20, 0x68, 0x06, 0xcb, + 0x04, 0xf0, 0x50, 0xfb, 0x02, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x68, 0xfb, + 0x31, 0x0c, 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x63, 0xfb, 0x31, 0x0a, + 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x5e, 0xfb, 0xf1, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0x5a, 0xfb, 0x01, 0x9b, 0xee, 0x18, 0xb5, 0x42, 0x05, 0xd0, + 0x29, 0x78, 0x20, 0x68, 0x04, 0xf0, 0x52, 0xfb, 0x01, 0x35, 0xf7, 0xe7, + 0x20, 0x00, 0xff, 0xf7, 0x45, 0xff, 0xf7, 0xbd, 0xec, 0x0b, 0x00, 0x20, + 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x10, 0x26, 0x20, 0x00, 0xff, 0xf7, + 0x69, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x33, 0x00, 0x01, 0x3b, 0xfd, 0xd1, + 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xa0, 0xff, 0x20, 0x00, 0xff, 0xf7, + 0x29, 0xff, 0x0d, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, 0x16, 0xfb, + 0x20, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x2e, 0xfb, 0x29, 0x0c, 0xc9, 0xb2, + 0x20, 0x68, 0x04, 0xf0, 0x29, 0xfb, 0x29, 0x0a, 0xc9, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0x24, 0xfb, 0xe9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x20, 0xfb, + 0x20, 0x00, 0xff, 0xf7, 0x15, 0xff, 0x70, 0xbd, 0xec, 0x0b, 0x00, 0x20, + 0x10, 0xb5, 0x0b, 0x00, 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, 0x40, 0xff, + 0x00, 0x20, 0x10, 0xbd, 0xf4, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x0b, 0x00, + 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, 0x84, 0xff, 0x00, 0x20, 0x10, 0xbd, + 0xf4, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, + 0xb7, 0xff, 0x00, 0x20, 0x10, 0xbd, 0xc0, 0x46, 0xf4, 0x0b, 0x00, 0x20, + 0x05, 0x4b, 0x06, 0x4a, 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, + 0x04, 0x4b, 0x05, 0x4a, 0x1a, 0x60, 0x05, 0x22, 0x5a, 0x60, 0x70, 0x47, + 0xec, 0x0b, 0x00, 0x20, 0x00, 0x1b, 0xb7, 0x00, 0xf4, 0x0b, 0x00, 0x20, + 0xfc, 0x0b, 0x00, 0x20, 0x01, 0x23, 0x8b, 0x40, 0xf7, 0xb5, 0x44, 0x6c, + 0x01, 0x93, 0x01, 0x9d, 0xa3, 0x68, 0x06, 0x00, 0x00, 0x20, 0x2b, 0x42, + 0x1c, 0xd0, 0x8a, 0x25, 0x6d, 0x00, 0x69, 0x43, 0x23, 0x69, 0x5d, 0x18, + 0x82, 0x42, 0x0f, 0xd0, 0x2a, 0x78, 0x57, 0xb2, 0x87, 0x42, 0x0b, 0xdb, + 0x01, 0x27, 0x3a, 0x42, 0x08, 0xd0, 0x0a, 0x00, 0x80, 0x21, 0x28, 0x89, + 0x14, 0x32, 0x9a, 0x18, 0x00, 0x02, 0x73, 0x68, 0x49, 0x00, 0x98, 0x47, + 0xa3, 0x68, 0x01, 0x9a, 0x93, 0x43, 0xa3, 0x60, 0x00, 0x23, 0x2b, 0x70, + 0xfe, 0xbd, 0xc3, 0x68, 0xf0, 0xb5, 0x84, 0x68, 0x02, 0x00, 0x23, 0x40, + 0x18, 0x1e, 0x17, 0xd0, 0x8a, 0x27, 0x00, 0x23, 0x15, 0x78, 0x7f, 0x00, + 0xab, 0x42, 0x01, 0xdb, 0x00, 0x20, 0x0f, 0xe0, 0x01, 0x20, 0x98, 0x40, + 0x04, 0x42, 0x0c, 0xd0, 0x38, 0x00, 0x58, 0x43, 0x16, 0x69, 0x30, 0x18, + 0x06, 0x78, 0x7f, 0x2e, 0x05, 0xd8, 0x06, 0x89, 0x8e, 0x42, 0x02, 0xd1, + 0x53, 0x68, 0x43, 0x60, 0xf0, 0xbd, 0x01, 0x33, 0xe8, 0xe7, 0x82, 0x68, + 0x01, 0x00, 0x30, 0xb5, 0x00, 0x20, 0x53, 0x1c, 0x13, 0xd0, 0x00, 0x23, + 0x01, 0x25, 0x08, 0x78, 0x83, 0x42, 0x01, 0xdb, 0x00, 0x20, 0x0c, 0xe0, + 0x2c, 0x00, 0x9c, 0x40, 0x14, 0x42, 0x09, 0xd1, 0x8a, 0x20, 0x40, 0x00, + 0x58, 0x43, 0x0b, 0x69, 0x22, 0x43, 0x18, 0x18, 0x4b, 0x68, 0x8a, 0x60, + 0x43, 0x60, 0x30, 0xbd, 0x01, 0x33, 0xeb, 0xe7, 0xf8, 0xb5, 0x44, 0x6c, + 0x07, 0x00, 0xe2, 0x68, 0xa3, 0x68, 0x00, 0x20, 0x13, 0x40, 0x9a, 0x42, + 0x0e, 0xd1, 0x23, 0x78, 0x01, 0x21, 0x9c, 0x46, 0x02, 0x00, 0x03, 0x00, + 0x49, 0x42, 0x62, 0x45, 0x07, 0xdb, 0x00, 0x20, 0x4b, 0x1c, 0x03, 0xd0, + 0x01, 0x22, 0x38, 0x00, 0xff, 0xf7, 0x80, 0xff, 0xf8, 0xbd, 0x8a, 0x26, + 0x76, 0x00, 0x56, 0x43, 0x25, 0x69, 0xae, 0x19, 0x70, 0x68, 0x65, 0x68, + 0x2d, 0x1a, 0x9d, 0x42, 0x04, 0xd9, 0x36, 0x78, 0x7f, 0x2e, 0x01, 0xd8, + 0x2b, 0x00, 0x11, 0x00, 0x01, 0x32, 0xe4, 0xe7, 0x10, 0xb5, 0x04, 0x00, + 0x40, 0x6c, 0xff, 0xf7, 0x92, 0xff, 0x00, 0x28, 0x04, 0xd0, 0x41, 0x78, + 0x00, 0x22, 0x20, 0x00, 0xff, 0xf7, 0x62, 0xff, 0x10, 0xbd, 0xf7, 0xb5, + 0x46, 0x6c, 0x1c, 0x00, 0x1b, 0x0a, 0x9b, 0xb2, 0x05, 0x00, 0x0f, 0x00, + 0x30, 0x00, 0x19, 0x00, 0x01, 0x93, 0xff, 0xf7, 0x7e, 0xff, 0x73, 0x68, + 0x01, 0x33, 0x73, 0x60, 0x00, 0x28, 0x10, 0xd0, 0x8a, 0x21, 0x43, 0x60, + 0x43, 0x78, 0x49, 0x00, 0x59, 0x43, 0xe4, 0xb2, 0x14, 0x34, 0x09, 0x19, + 0x34, 0x69, 0x08, 0x9a, 0x61, 0x18, 0x09, 0x98, 0x05, 0xf0, 0x6c, 0xfa, + 0x00, 0x27, 0x38, 0x00, 0xfe, 0xbd, 0x03, 0x23, 0x1f, 0x40, 0x01, 0x2f, + 0x06, 0xd1, 0x2b, 0x68, 0x09, 0x9a, 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, + 0x07, 0x00, 0xf2, 0xe7, 0x28, 0x00, 0xff, 0xf7, 0x99, 0xff, 0x07, 0x00, + 0x68, 0x6c, 0xff, 0xf7, 0x78, 0xff, 0x00, 0x90, 0x00, 0x28, 0x24, 0xd0, + 0x02, 0x23, 0x6a, 0x46, 0x03, 0x70, 0x8a, 0x23, 0x92, 0x88, 0x5b, 0x00, + 0x02, 0x81, 0x42, 0x78, 0x80, 0x21, 0x5a, 0x43, 0x33, 0x69, 0x14, 0x32, + 0x9a, 0x18, 0x20, 0x00, 0xff, 0x23, 0x49, 0x00, 0x98, 0x43, 0x2b, 0x68, + 0x98, 0x47, 0x8a, 0x21, 0x49, 0x00, 0x00, 0x28, 0x00, 0xd0, 0x07, 0x00, + 0x00, 0x9b, 0xe4, 0xb2, 0x5b, 0x78, 0x14, 0x34, 0x59, 0x43, 0x09, 0x19, + 0x34, 0x69, 0x08, 0x9a, 0x61, 0x18, 0x09, 0x98, 0x05, 0xf0, 0x30, 0xfa, + 0xc3, 0xe7, 0x2b, 0x68, 0x09, 0x9a, 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, + 0x00, 0x28, 0xc7, 0xd1, 0xbb, 0xe7, 0xf7, 0xb5, 0x47, 0x6c, 0x01, 0x91, + 0x19, 0x0a, 0x05, 0x00, 0x89, 0xb2, 0x38, 0x00, 0x1c, 0x00, 0xff, 0xf7, + 0x1c, 0xff, 0x06, 0x1e, 0x0c, 0xd0, 0x1c, 0x22, 0x01, 0x9b, 0x1a, 0x40, + 0x18, 0x2a, 0x07, 0xd0, 0x41, 0x78, 0x00, 0x2a, 0x0a, 0xd1, 0x9b, 0x07, + 0x08, 0xd0, 0x28, 0x00, 0xff, 0xf7, 0xe4, 0xfe, 0x6b, 0x68, 0x09, 0x9a, + 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, 0x14, 0xe0, 0x8a, 0x23, 0x5b, 0x00, + 0x59, 0x43, 0xe0, 0xb2, 0x3b, 0x69, 0x14, 0x30, 0x40, 0x18, 0x18, 0x18, + 0x08, 0x9a, 0x09, 0x99, 0x05, 0xf0, 0xfc, 0xf9, 0x02, 0x22, 0x7b, 0x68, + 0x01, 0x33, 0x7b, 0x60, 0x73, 0x60, 0x33, 0x78, 0x13, 0x40, 0x18, 0x1e, + 0xe4, 0xd1, 0xfe, 0xbd, 0xf7, 0xb5, 0x42, 0x6c, 0x94, 0x68, 0xd3, 0x68, + 0x23, 0x40, 0x18, 0x1e, 0x09, 0xd0, 0x13, 0x78, 0x8a, 0x26, 0x01, 0x93, + 0x01, 0x25, 0x00, 0x23, 0x76, 0x00, 0x01, 0x98, 0x98, 0x42, 0x01, 0xdc, + 0x00, 0x20, 0xfe, 0xbd, 0x28, 0x00, 0x98, 0x40, 0x04, 0x42, 0x0b, 0xd0, + 0x30, 0x00, 0x58, 0x43, 0x17, 0x69, 0x38, 0x18, 0x07, 0x78, 0x7f, 0x2f, + 0x04, 0xd9, 0x07, 0x89, 0xbc, 0x46, 0xcf, 0x88, 0xbc, 0x45, 0xee, 0xd0, + 0x01, 0x33, 0xe8, 0xe7, 0x70, 0xb5, 0x0c, 0x1e, 0x0f, 0xd0, 0x30, 0x21, + 0xc5, 0x6a, 0x83, 0x6a, 0x69, 0x43, 0x1a, 0x1d, 0x5b, 0x18, 0x00, 0x21, + 0x04, 0x33, 0x9a, 0x42, 0x06, 0xd1, 0x61, 0x78, 0x00, 0x22, 0xff, 0xf7, + 0x93, 0xfe, 0x00, 0x23, 0x23, 0x81, 0x70, 0xbd, 0x00, 0x26, 0x95, 0x5f, + 0x00, 0x2d, 0x03, 0xd0, 0xd5, 0x69, 0xa5, 0x42, 0x00, 0xd1, 0xd1, 0x61, + 0x30, 0x32, 0xec, 0xe7, 0xf0, 0xb5, 0x47, 0x6c, 0x89, 0xb0, 0x06, 0x00, + 0x00, 0x2f, 0x36, 0xd0, 0x8a, 0x21, 0x80, 0x6c, 0x49, 0x00, 0x14, 0x38, + 0x05, 0xf0, 0xf4, 0xf8, 0x04, 0x1e, 0x2e, 0xd0, 0x00, 0x23, 0x01, 0x21, + 0x01, 0x93, 0x01, 0x9a, 0x01, 0x33, 0x52, 0x00, 0x0a, 0x43, 0x01, 0x92, + 0x9c, 0x42, 0xf8, 0xdc, 0x03, 0xad, 0x08, 0x22, 0x00, 0x21, 0x28, 0x00, + 0x05, 0xf0, 0x9b, 0xf9, 0x3b, 0x00, 0x14, 0x33, 0x2b, 0x61, 0x01, 0x23, + 0x5b, 0x42, 0xab, 0x60, 0x01, 0x9b, 0x29, 0x00, 0x14, 0x22, 0x38, 0x00, + 0xeb, 0x60, 0x2c, 0x70, 0x05, 0xf0, 0x84, 0xf9, 0x75, 0x6c, 0x8a, 0x26, + 0x2a, 0x78, 0x76, 0x00, 0x72, 0x43, 0x00, 0x21, 0x28, 0x69, 0x05, 0xf0, + 0x84, 0xf9, 0xab, 0x68, 0xea, 0x68, 0xe4, 0xb2, 0x93, 0x43, 0xab, 0x60, + 0x00, 0x23, 0x9c, 0x42, 0x01, 0xdc, 0x09, 0xb0, 0xf0, 0xbd, 0x32, 0x00, + 0x5a, 0x43, 0x29, 0x69, 0x8a, 0x18, 0x53, 0x70, 0x01, 0x33, 0xf4, 0xe7, + 0xf0, 0xb5, 0x85, 0xb0, 0x06, 0x00, 0x0d, 0x00, 0x14, 0x00, 0x03, 0x93, + 0x00, 0x27, 0x68, 0x2a, 0x06, 0xd9, 0x10, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x05, 0xf0, 0xac, 0xf8, 0x01, 0x30, 0x87, 0xb2, 0x80, 0x21, 0x0a, 0x9b, + 0x09, 0x02, 0x00, 0x93, 0x29, 0x43, 0x00, 0x23, 0x3a, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0xfa, 0xfa, 0x00, 0x28, 0x11, 0xdb, 0x0a, 0x9b, 0x1d, 0x88, + 0x2d, 0x02, 0x00, 0x2f, 0x0e, 0xd1, 0x23, 0x00, 0x17, 0x33, 0x03, 0x9a, + 0x5b, 0x00, 0x01, 0x92, 0x02, 0x22, 0x5b, 0x19, 0x00, 0x92, 0x15, 0x21, + 0x00, 0x22, 0x30, 0x00, 0xff, 0xf7, 0xb1, 0xfe, 0x05, 0xb0, 0xf0, 0xbd, + 0x23, 0x1d, 0x68, 0x2c, 0xef, 0xd9, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x05, 0xf0, 0x08, 0xf9, 0x0b, 0x1d, 0xe8, 0xe7, 0x30, 0xb5, 0x0e, 0x25, + 0x00, 0x23, 0x85, 0xb0, 0x6d, 0x44, 0x1a, 0x00, 0x00, 0x95, 0x04, 0x00, + 0x02, 0xf0, 0xd0, 0xfa, 0x0b, 0x4b, 0x98, 0x42, 0x12, 0xd0, 0x00, 0x28, + 0x0e, 0xdb, 0x0d, 0x22, 0xbf, 0x23, 0x6a, 0x44, 0x13, 0x70, 0x2b, 0x88, + 0x01, 0x92, 0x01, 0x22, 0x1b, 0x02, 0x00, 0x92, 0x04, 0x33, 0x00, 0x22, + 0x04, 0x21, 0x20, 0x00, 0xff, 0xf7, 0xeb, 0xfe, 0x05, 0xb0, 0x30, 0xbd, + 0x00, 0x20, 0xfb, 0xe7, 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x8b, 0xb0, + 0x04, 0x93, 0x10, 0xab, 0x1b, 0x88, 0x12, 0x25, 0x05, 0x93, 0x50, 0x4b, + 0x14, 0x00, 0x19, 0x43, 0x0e, 0x23, 0x04, 0xaa, 0x9b, 0x18, 0x19, 0x80, + 0x09, 0xab, 0xad, 0x18, 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x2b, 0x00, + 0x06, 0x00, 0x02, 0xf0, 0x65, 0xfa, 0x00, 0x28, 0x33, 0xdb, 0x09, 0x9b, + 0x2d, 0x88, 0x06, 0x93, 0x68, 0x2c, 0x30, 0xd9, 0x27, 0x00, 0x69, 0x3f, + 0x7c, 0x21, 0x38, 0x00, 0x05, 0xf0, 0x38, 0xf8, 0x01, 0x30, 0x83, 0xb2, + 0x7c, 0x21, 0x38, 0x00, 0x03, 0x93, 0x05, 0xf0, 0xb7, 0xf8, 0x09, 0x91, + 0x32, 0x6a, 0x05, 0x9b, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, + 0x1b, 0x02, 0x00, 0x22, 0x15, 0x21, 0x30, 0x00, 0xff, 0xf7, 0x49, 0xfe, + 0x00, 0x28, 0x12, 0xdb, 0x06, 0x9b, 0x37, 0x6a, 0x2d, 0x01, 0xed, 0x18, + 0x04, 0xaa, 0x7b, 0x78, 0x39, 0x78, 0xd2, 0x89, 0x01, 0x35, 0x1b, 0x02, + 0xad, 0xb2, 0x0b, 0x43, 0x9a, 0x42, 0x0a, 0xd0, 0x29, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0x5c, 0xfb, 0x2e, 0x48, 0x0b, 0xb0, 0xf0, 0xbd, 0x00, 0x23, + 0x09, 0x94, 0x03, 0x93, 0xd8, 0xe7, 0xfb, 0x78, 0xba, 0x78, 0x1b, 0x02, + 0x13, 0x43, 0x03, 0x9a, 0x93, 0x42, 0x05, 0xd0, 0x29, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0x4a, 0xfb, 0x26, 0x48, 0xec, 0xe7, 0x38, 0x22, 0x3b, 0x79, + 0x93, 0x43, 0xc0, 0x2b, 0x05, 0xd0, 0x29, 0x00, 0x30, 0x00, 0x02, 0xf0, + 0x3f, 0xfb, 0x22, 0x48, 0xe1, 0xe7, 0x03, 0x9b, 0x00, 0x2b, 0x2a, 0xd1, + 0x6b, 0x46, 0x64, 0x00, 0x1b, 0x8a, 0x3c, 0x19, 0xe3, 0x85, 0x80, 0x22, + 0x52, 0x00, 0x00, 0x92, 0x2b, 0x02, 0x01, 0x97, 0x00, 0x22, 0x07, 0x21, + 0x30, 0x00, 0xff, 0xf7, 0x68, 0xfe, 0x00, 0x28, 0xcd, 0xdb, 0x0f, 0x23, + 0x17, 0x4a, 0x2b, 0x40, 0x9b, 0x18, 0x0e, 0x22, 0x04, 0xa9, 0x52, 0x18, + 0x01, 0x92, 0x02, 0x22, 0x2d, 0x09, 0x5b, 0x00, 0x2d, 0x03, 0x00, 0x92, + 0x5b, 0x19, 0x00, 0x22, 0x04, 0x21, 0x30, 0x00, 0xff, 0xf7, 0x53, 0xfe, + 0x00, 0x28, 0xb8, 0xdb, 0x05, 0x99, 0x30, 0x00, 0x02, 0xf0, 0x10, 0xfb, + 0xb3, 0xe7, 0x68, 0x2c, 0x05, 0xd8, 0x64, 0x00, 0x6b, 0x46, 0x1b, 0x8a, + 0x3c, 0x19, 0x23, 0x81, 0xd1, 0xe7, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x05, 0xf0, 0x3c, 0xf8, 0x4c, 0x00, 0xf3, 0xe7, 0x00, 0x80, 0xff, 0xff, + 0xbd, 0xd8, 0xff, 0xff, 0xbc, 0xd8, 0xff, 0xff, 0xbb, 0xd8, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x00, 0x24, 0x85, 0xb0, 0x0e, 0x00, + 0x1f, 0x00, 0x11, 0x88, 0x03, 0x93, 0x02, 0x94, 0x01, 0x94, 0x00, 0x94, + 0x23, 0x00, 0x05, 0x00, 0x02, 0xf0, 0x66, 0xfa, 0xa0, 0x42, 0x0a, 0xdb, + 0xfb, 0x21, 0x3a, 0x88, 0x33, 0x02, 0x12, 0x02, 0x00, 0x91, 0x05, 0x33, + 0x05, 0x32, 0x21, 0x00, 0x28, 0x00, 0x01, 0xf0, 0xe3, 0xff, 0x05, 0xb0, + 0xf0, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x93, 0xb0, 0x06, 0x91, 0x01, 0x33, + 0x11, 0x01, 0xcb, 0x18, 0xc4, 0x6c, 0x9b, 0xb2, 0x07, 0x00, 0x05, 0x93, + 0x00, 0x2c, 0x08, 0xd0, 0x10, 0x02, 0xf9, 0x68, 0x04, 0xf0, 0x7c, 0xff, + 0x00, 0x23, 0x02, 0x00, 0x19, 0x00, 0x18, 0x00, 0xa0, 0x47, 0x05, 0x9b, + 0x0e, 0xad, 0x1b, 0x02, 0x08, 0x93, 0x05, 0x23, 0x01, 0x95, 0x00, 0x93, + 0x00, 0x22, 0x08, 0x9b, 0x15, 0x21, 0x38, 0x00, 0xff, 0xf7, 0x8f, 0xfd, + 0x04, 0x1e, 0x00, 0xda, 0xd5, 0xe0, 0x06, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0x81, 0xe0, 0x2b, 0x79, 0x7f, 0x2b, 0x00, 0xd9, 0x86, 0xe0, 0x06, 0x9b, + 0x1c, 0x00, 0x1d, 0x00, 0x04, 0x93, 0x06, 0x9b, 0x83, 0x4a, 0x01, 0x3b, + 0x9b, 0xb2, 0x93, 0x42, 0x00, 0xd9, 0x02, 0xe2, 0x81, 0x48, 0x06, 0x9b, + 0x02, 0x00, 0x0e, 0xae, 0x03, 0x43, 0x9b, 0xb2, 0x31, 0x88, 0x07, 0x93, + 0x33, 0x79, 0x0a, 0x43, 0x09, 0x90, 0x07, 0x98, 0x92, 0xb2, 0x82, 0x42, + 0x00, 0xd1, 0xb2, 0xe1, 0x5a, 0xb2, 0x00, 0x2a, 0x51, 0xda, 0x9a, 0x07, + 0x4f, 0xd4, 0x44, 0x22, 0x13, 0x42, 0x4c, 0xd0, 0x04, 0x25, 0x72, 0x88, + 0x1d, 0x40, 0x00, 0xd1, 0xee, 0xe0, 0x12, 0x23, 0x06, 0xa8, 0x1b, 0x18, + 0x0b, 0xad, 0x00, 0x93, 0x38, 0x00, 0x2b, 0x00, 0xff, 0xf7, 0x74, 0xfe, + 0x6f, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x3a, 0xd0, 0x00, 0x28, 0x00, 0xda, + 0x95, 0xe0, 0x2b, 0x88, 0x05, 0x9a, 0x93, 0x42, 0x33, 0xd1, 0x10, 0xad, + 0x2b, 0x00, 0x32, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0x72, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0x87, 0xe0, 0x12, 0x20, 0x06, 0xac, 0x00, 0x19, + 0x00, 0x88, 0x0e, 0xae, 0x2b, 0x88, 0x72, 0x88, 0x31, 0x88, 0x00, 0x90, + 0x38, 0x00, 0xff, 0xf7, 0xb1, 0xfe, 0x60, 0x4b, 0x04, 0x00, 0xc3, 0x18, + 0x02, 0x2b, 0x16, 0xd8, 0x29, 0x88, 0x38, 0x00, 0x02, 0xf0, 0x50, 0xfa, + 0x04, 0x1e, 0x70, 0xdb, 0x31, 0x88, 0x38, 0x00, 0xff, 0xf7, 0x7e, 0xfe, + 0x01, 0x23, 0xfd, 0x6c, 0x04, 0x00, 0x04, 0x93, 0x00, 0x2d, 0x06, 0xd0, + 0x00, 0x23, 0x32, 0x88, 0x18, 0x00, 0x06, 0x21, 0xa8, 0x47, 0x01, 0x23, + 0x04, 0x93, 0x00, 0x2c, 0x5d, 0xdb, 0xfc, 0x6c, 0x00, 0x2c, 0x04, 0xd0, + 0x00, 0x23, 0x05, 0x9a, 0x05, 0x21, 0x18, 0x00, 0xa0, 0x47, 0x05, 0x99, + 0x38, 0x00, 0x02, 0xf0, 0x2f, 0xfa, 0x04, 0x00, 0x92, 0xe1, 0x4b, 0x4b, + 0x06, 0x9a, 0x9a, 0x42, 0x00, 0xd0, 0x82, 0xe0, 0x2b, 0x79, 0xdb, 0x07, + 0x00, 0xd5, 0x7e, 0xe0, 0x04, 0x23, 0x2e, 0x79, 0x29, 0x88, 0x6a, 0x88, + 0x1e, 0x40, 0x4b, 0xd0, 0x06, 0xa8, 0x0e, 0x33, 0x1b, 0x18, 0x0b, 0xae, + 0x00, 0x93, 0x38, 0x00, 0x33, 0x00, 0xff, 0xf7, 0x0f, 0xfe, 0x3d, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x00, 0xd1, 0x6c, 0xe0, 0x00, 0x28, 0x30, 0xdb, + 0x33, 0x88, 0x05, 0x9a, 0x93, 0x42, 0x00, 0xd0, 0x60, 0xe0, 0x10, 0xae, + 0x33, 0x00, 0x2a, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0x0c, 0xff, + 0x04, 0x1e, 0x22, 0xdb, 0x06, 0xa8, 0x40, 0x8a, 0x33, 0x88, 0x6a, 0x88, + 0x29, 0x88, 0x00, 0x90, 0x38, 0x00, 0xff, 0xf7, 0x4f, 0xfe, 0x2f, 0x4b, + 0x04, 0x00, 0xc3, 0x18, 0x02, 0x2b, 0x17, 0xd8, 0x31, 0x88, 0x38, 0x00, + 0x02, 0xf0, 0xee, 0xf9, 0x04, 0x1e, 0x0e, 0xdb, 0x29, 0x88, 0x38, 0x00, + 0xff, 0xf7, 0x1c, 0xfe, 0xfe, 0x6c, 0x04, 0x00, 0x00, 0x2e, 0x04, 0xd0, + 0x00, 0x23, 0x06, 0x21, 0x18, 0x00, 0x2a, 0x88, 0xb0, 0x47, 0x00, 0x2c, + 0x34, 0xda, 0x20, 0x00, 0x13, 0xb0, 0xf0, 0xbd, 0xfe, 0x6c, 0x00, 0x2e, + 0xf7, 0xd0, 0x6b, 0x88, 0x2a, 0x88, 0x02, 0x21, 0x00, 0x20, 0xf1, 0xe7, + 0x1a, 0x4b, 0x00, 0x96, 0x19, 0x43, 0x89, 0xb2, 0x05, 0x9b, 0x38, 0x00, + 0x02, 0xf0, 0xd8, 0xf8, 0x17, 0x4b, 0x04, 0x00, 0x98, 0x42, 0xe6, 0xd1, + 0x29, 0x88, 0x14, 0x4b, 0x00, 0x96, 0x0b, 0x43, 0x99, 0xb2, 0x32, 0x00, + 0x33, 0x00, 0x38, 0x00, 0x02, 0xf0, 0x02, 0xf9, 0x04, 0x1e, 0x11, 0xd1, + 0x10, 0xab, 0x2a, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0xbe, 0xfe, + 0x04, 0x1e, 0xd4, 0xdb, 0xfb, 0x6c, 0x9c, 0x46, 0x00, 0x2b, 0x05, 0xd0, + 0x6b, 0x88, 0x2a, 0x88, 0x03, 0x21, 0x30, 0x00, 0x65, 0x46, 0xa8, 0x47, + 0x01, 0x23, 0x04, 0x93, 0x04, 0xe0, 0x00, 0x23, 0xf8, 0xe6, 0x01, 0x23, + 0x00, 0x24, 0x04, 0x93, 0x1d, 0x00, 0xf6, 0xe6, 0xfd, 0xff, 0x00, 0x00, + 0x00, 0x80, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, + 0xff, 0xff, 0x00, 0x00, 0x16, 0x26, 0x06, 0xab, 0xf6, 0x18, 0x00, 0x96, + 0x2b, 0x00, 0x07, 0x99, 0x38, 0x00, 0x02, 0xf0, 0x99, 0xf8, 0xc1, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x00, 0xd0, 0x75, 0xe0, 0x35, 0x80, 0x0e, 0xae, + 0x31, 0x88, 0x09, 0x9b, 0x0c, 0xad, 0x19, 0x43, 0x72, 0x88, 0x00, 0x23, + 0x89, 0xb2, 0x00, 0x95, 0x38, 0x00, 0x02, 0xf0, 0x87, 0xf8, 0xb8, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x68, 0xd1, 0x00, 0x23, 0x2b, 0x80, 0x2b, 0x88, + 0x00, 0x2b, 0x06, 0xd0, 0x16, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0x00, 0x2b, 0x00, 0xd0, 0x2d, 0xe7, 0x06, 0x9b, 0x06, 0xaa, 0x59, 0x04, + 0x1a, 0x23, 0x9b, 0x18, 0x00, 0x93, 0x00, 0x23, 0x49, 0x0c, 0x1a, 0x00, + 0x38, 0x00, 0x02, 0xf0, 0x6b, 0xf8, 0xaa, 0x4b, 0x04, 0x00, 0x98, 0x42, + 0x4f, 0xd1, 0x16, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x00, 0x22, 0x1a, 0x80, + 0x00, 0x23, 0x31, 0x88, 0x0d, 0xad, 0x49, 0x04, 0x1a, 0x00, 0x49, 0x0c, + 0x00, 0x95, 0x38, 0x00, 0x02, 0xf0, 0x58, 0xf8, 0xa0, 0x4b, 0x04, 0x00, + 0x98, 0x42, 0x3f, 0xd1, 0x00, 0x22, 0x0c, 0xab, 0x1a, 0x80, 0xf8, 0x23, + 0x16, 0x21, 0x10, 0xaa, 0x06, 0xa8, 0x13, 0x71, 0x09, 0x18, 0x73, 0x88, + 0x08, 0x88, 0x53, 0x80, 0x00, 0x28, 0x05, 0xd0, 0x1a, 0x21, 0x06, 0xac, + 0x09, 0x19, 0x09, 0x88, 0x00, 0x29, 0x2e, 0xd0, 0x29, 0x88, 0x00, 0x29, + 0x2b, 0xd0, 0x0c, 0xa9, 0x09, 0x88, 0x06, 0x91, 0x00, 0x29, 0x26, 0xd1, + 0x33, 0x88, 0x09, 0x99, 0x38, 0x00, 0x19, 0x43, 0x1e, 0x23, 0x11, 0x80, + 0x06, 0xa9, 0x5b, 0x18, 0x05, 0x99, 0xff, 0xf7, 0x29, 0xfe, 0xfd, 0x6c, + 0x04, 0x00, 0x00, 0x2d, 0x04, 0xd0, 0x73, 0x88, 0x32, 0x88, 0x03, 0x21, + 0x06, 0x98, 0xa8, 0x47, 0x00, 0x2c, 0x00, 0xda, 0x35, 0xe7, 0x01, 0x23, + 0x04, 0x93, 0xd4, 0xe6, 0x00, 0x28, 0x00, 0xdb, 0x87, 0xe7, 0x2e, 0xe7, + 0x00, 0x28, 0x96, 0xda, 0x2b, 0xe7, 0x00, 0x28, 0xb2, 0xda, 0x28, 0xe7, + 0x00, 0x28, 0xc0, 0xda, 0x25, 0xe7, 0x0c, 0xaa, 0x12, 0x88, 0x00, 0x2a, + 0x03, 0xd0, 0x2a, 0x88, 0x00, 0x2a, 0x00, 0xd1, 0xbf, 0xe6, 0x1a, 0x22, + 0x06, 0xa9, 0x52, 0x18, 0x12, 0x88, 0x00, 0x2a, 0x00, 0xd1, 0xb8, 0xe6, + 0x00, 0x28, 0x00, 0xd0, 0xb5, 0xe6, 0x6a, 0x46, 0xfd, 0x6c, 0x92, 0x8b, + 0x10, 0xac, 0x22, 0x80, 0x00, 0x2d, 0x02, 0xd0, 0x32, 0x88, 0x03, 0x21, + 0xa8, 0x47, 0x1e, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x05, 0x99, 0x22, 0x00, + 0x38, 0x00, 0xff, 0xf7, 0xe9, 0xfd, 0x04, 0x00, 0xc6, 0xe7, 0x69, 0x46, + 0x04, 0x22, 0x18, 0x20, 0x09, 0x5e, 0x1a, 0x40, 0x00, 0x29, 0x44, 0xda, + 0x00, 0x2a, 0x44, 0xd1, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0x94, 0xe6, + 0x9b, 0x07, 0x30, 0xd5, 0x12, 0x23, 0x06, 0xa9, 0x5b, 0x18, 0x0e, 0xae, + 0x72, 0x88, 0x06, 0x99, 0x00, 0x93, 0x38, 0x00, 0x0b, 0xab, 0xff, 0xf7, + 0xbd, 0xfc, 0x5d, 0x4b, 0x04, 0x00, 0x98, 0x42, 0xab, 0xd0, 0x00, 0x28, + 0x00, 0xda, 0xde, 0xe6, 0x01, 0x22, 0x06, 0xab, 0x04, 0x92, 0x9b, 0x8a, + 0x05, 0x9a, 0x93, 0x42, 0x00, 0xd0, 0x78, 0xe6, 0xfc, 0x6c, 0x00, 0x2c, + 0x04, 0xd0, 0x73, 0x88, 0x32, 0x88, 0x03, 0x21, 0x00, 0x20, 0xa0, 0x47, + 0xfd, 0x23, 0x01, 0x26, 0x10, 0xaa, 0x13, 0x70, 0x08, 0x9b, 0x01, 0x92, + 0x04, 0x33, 0x00, 0x96, 0x00, 0x22, 0x07, 0x21, 0x38, 0x00, 0xff, 0xf7, + 0xdc, 0xfb, 0x04, 0x00, 0x04, 0x96, 0x00, 0x2d, 0x00, 0xd0, 0x5e, 0xe6, + 0x00, 0x2c, 0x00, 0xd0, 0xb9, 0xe6, 0x04, 0x9c, 0x47, 0x4b, 0x67, 0x42, + 0x7c, 0x41, 0xe4, 0x18, 0xb3, 0xe6, 0x00, 0x2a, 0xba, 0xd1, 0x1a, 0x26, + 0x06, 0x9b, 0x0e, 0xad, 0x5b, 0x04, 0x5b, 0x0c, 0x09, 0x93, 0x06, 0xab, + 0xf6, 0x18, 0x6a, 0x88, 0x05, 0x9b, 0x00, 0x96, 0x09, 0x99, 0x38, 0x00, + 0x01, 0xf0, 0x8e, 0xff, 0x3b, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x4c, 0xd1, + 0x00, 0x23, 0x33, 0x80, 0x6a, 0x88, 0x0d, 0xad, 0x05, 0x9b, 0x00, 0x95, + 0x07, 0x99, 0x38, 0x00, 0x01, 0xf0, 0x80, 0xff, 0x34, 0x4b, 0x04, 0x00, + 0x98, 0x42, 0x41, 0xd1, 0x00, 0x23, 0x2b, 0x80, 0x1a, 0x23, 0x06, 0xaa, + 0x9b, 0x18, 0x28, 0x88, 0x1d, 0x88, 0xfc, 0x6c, 0x00, 0x2d, 0x3a, 0xd0, + 0x00, 0x28, 0x00, 0xd0, 0x25, 0xe6, 0x00, 0x2c, 0x04, 0xd0, 0x0e, 0xab, + 0x5b, 0x88, 0x06, 0x9a, 0x02, 0x21, 0xa0, 0x47, 0xf8, 0x23, 0x10, 0xaa, + 0x13, 0x71, 0x6b, 0x46, 0x1e, 0x26, 0x9b, 0x8b, 0x00, 0x25, 0x13, 0x80, + 0x0e, 0xab, 0x5b, 0x88, 0x07, 0x99, 0x53, 0x80, 0x06, 0xab, 0xf6, 0x18, + 0x01, 0x23, 0x02, 0x93, 0x2b, 0x00, 0x03, 0x96, 0x01, 0x95, 0x00, 0x95, + 0x38, 0x00, 0x01, 0xf0, 0xc1, 0xff, 0x04, 0x00, 0xa8, 0x42, 0x00, 0xda, + 0x61, 0xe6, 0xfb, 0x21, 0x32, 0x88, 0x08, 0x9b, 0x12, 0x02, 0x00, 0x91, + 0x05, 0x33, 0x05, 0x32, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, 0x3c, 0xfd, + 0x04, 0x00, 0xa8, 0x42, 0x00, 0xdb, 0xf4, 0xe5, 0x51, 0xe6, 0x00, 0x28, + 0xb2, 0xda, 0x4e, 0xe6, 0x00, 0x28, 0xbd, 0xda, 0x4b, 0xe6, 0x00, 0x28, + 0x00, 0xd1, 0xea, 0xe5, 0x0e, 0xab, 0x5b, 0x88, 0x00, 0x2c, 0x03, 0xd0, + 0x06, 0x9a, 0x03, 0x21, 0x28, 0x00, 0xa0, 0x47, 0xfc, 0x23, 0x10, 0xaa, + 0x13, 0x71, 0x6b, 0x46, 0x1e, 0x26, 0x9b, 0x8c, 0x00, 0x25, 0x13, 0x80, + 0x0e, 0xab, 0x5b, 0x88, 0x09, 0x99, 0x53, 0x80, 0x06, 0xab, 0xf6, 0x18, + 0x01, 0x23, 0x03, 0x96, 0x02, 0x93, 0x01, 0x95, 0x00, 0x95, 0x2b, 0x00, + 0xc2, 0xe7, 0xc0, 0x46, 0xee, 0xd8, 0xff, 0xff, 0xa9, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x8b, 0xb0, 0x05, 0x93, 0xc7, 0x6c, 0x43, 0x6a, 0x04, 0x00, + 0x03, 0x91, 0x16, 0x00, 0x11, 0x9d, 0x04, 0x93, 0x00, 0x2f, 0x08, 0xd0, + 0x10, 0x02, 0xe1, 0x68, 0x04, 0xf0, 0xa8, 0xfc, 0x00, 0x23, 0x02, 0x00, + 0x19, 0x00, 0x01, 0x20, 0xb8, 0x47, 0x03, 0x9b, 0x4f, 0x49, 0x50, 0x4a, + 0x5b, 0x18, 0x9b, 0xb2, 0x93, 0x42, 0x00, 0xd9, 0x94, 0xe0, 0x05, 0x22, + 0x05, 0x9b, 0x36, 0x01, 0x01, 0x33, 0xf6, 0x18, 0xb7, 0xb2, 0x08, 0xae, + 0x00, 0x92, 0x3b, 0x02, 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, + 0xff, 0xf7, 0xb1, 0xfa, 0x00, 0x28, 0x16, 0xdb, 0x39, 0x22, 0x33, 0x79, + 0x93, 0x43, 0x72, 0x88, 0x00, 0x2a, 0x12, 0xd1, 0x80, 0x2b, 0x6e, 0xd1, + 0xe5, 0x6c, 0x00, 0x2d, 0x04, 0xd0, 0x03, 0x9b, 0x3a, 0x00, 0x05, 0x21, + 0x01, 0x20, 0xa8, 0x47, 0x39, 0x00, 0x20, 0x00, 0x01, 0xf0, 0xc2, 0xff, + 0x00, 0x28, 0x00, 0xdb, 0x3a, 0x48, 0x05, 0x00, 0x6b, 0xe0, 0xc0, 0x2b, + 0xfa, 0xd0, 0x03, 0x9b, 0x38, 0x4a, 0x5e, 0x04, 0x94, 0x46, 0x00, 0x23, + 0x60, 0x6a, 0x76, 0x0c, 0x61, 0x46, 0xc2, 0x5a, 0x0a, 0x40, 0xb2, 0x42, + 0x12, 0xd1, 0x04, 0x9a, 0xd3, 0x5e, 0x00, 0x2b, 0x58, 0xda, 0x30, 0x4d, + 0x36, 0xe0, 0x02, 0x33, 0x9c, 0x42, 0x4f, 0xd1, 0x2b, 0x68, 0x04, 0x98, + 0x59, 0x00, 0x01, 0x33, 0x0a, 0x52, 0x7f, 0x2b, 0x00, 0xd9, 0x00, 0x23, + 0x2b, 0x60, 0x49, 0xe0, 0x80, 0x22, 0x02, 0x33, 0x52, 0x00, 0x93, 0x42, + 0xe2, 0xd1, 0x0e, 0x23, 0x04, 0xaa, 0x9b, 0x18, 0x00, 0x93, 0x00, 0x23, + 0x03, 0x99, 0x1a, 0x00, 0x20, 0x00, 0x01, 0xf0, 0x9b, 0xfe, 0x00, 0x28, + 0x0a, 0xd0, 0x22, 0x4b, 0x98, 0x42, 0x24, 0xd1, 0x69, 0x46, 0x2b, 0x68, + 0x04, 0x9a, 0x89, 0x89, 0x5b, 0x00, 0x99, 0x52, 0x01, 0x22, 0x04, 0xe0, + 0x2b, 0x68, 0x04, 0x9a, 0x5b, 0x00, 0x9e, 0x52, 0x02, 0x00, 0x2b, 0x68, + 0x01, 0x33, 0x7f, 0x2b, 0x00, 0xd9, 0x00, 0x23, 0x2b, 0x60, 0x18, 0x4d, + 0x00, 0x2a, 0x20, 0xd0, 0xe6, 0x6c, 0x00, 0x2e, 0x04, 0xd0, 0x03, 0x9b, + 0x3a, 0x00, 0x04, 0x21, 0x01, 0x20, 0xb0, 0x47, 0x39, 0x00, 0x20, 0x00, + 0x01, 0xf0, 0x66, 0xff, 0x00, 0x28, 0x12, 0xda, 0xa3, 0xe7, 0x00, 0x22, + 0x90, 0x42, 0xe4, 0xda, 0x9f, 0xe7, 0xc0, 0x2b, 0x9c, 0xd0, 0x03, 0x9b, + 0x09, 0x48, 0x5a, 0x04, 0x63, 0x6a, 0x52, 0x0c, 0x5c, 0x1c, 0xff, 0x34, + 0x19, 0x88, 0x01, 0x40, 0x91, 0x42, 0xa8, 0xd1, 0x03, 0x4d, 0x28, 0x00, + 0x0b, 0xb0, 0xf0, 0xbd, 0x00, 0x80, 0xff, 0xff, 0xfe, 0x7f, 0x00, 0x00, + 0xaa, 0xd8, 0xff, 0xff, 0xff, 0x7f, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xa9, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0xc4, 0x6c, 0x87, 0xb0, 0x06, 0x00, + 0x00, 0x2c, 0x04, 0xd0, 0x00, 0x23, 0x1a, 0x00, 0x19, 0x00, 0x18, 0x00, + 0xa0, 0x47, 0x00, 0x24, 0x14, 0x4b, 0x05, 0x94, 0x01, 0x93, 0x04, 0x94, + 0x23, 0x00, 0x03, 0x94, 0x02, 0x94, 0x00, 0x94, 0x22, 0x00, 0x21, 0x00, + 0x30, 0x00, 0x01, 0xf0, 0x5b, 0xfc, 0x0f, 0x4b, 0x05, 0x00, 0x98, 0x42, + 0x15, 0xd0, 0xa0, 0x42, 0x07, 0xd0, 0xf7, 0x6c, 0xa7, 0x42, 0x04, 0xd0, + 0x02, 0x00, 0x23, 0x00, 0x01, 0x21, 0x20, 0x00, 0xb8, 0x47, 0xf4, 0x6c, + 0x00, 0x2c, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, 0x19, 0x00, 0x52, 0x00, + 0x18, 0x00, 0xa0, 0x47, 0x28, 0x00, 0x07, 0xb0, 0xf0, 0xbd, 0x25, 0x00, + 0xf1, 0xe7, 0xc0, 0x46, 0x41, 0x2c, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0xc4, 0x6c, 0x97, 0xb0, 0x05, 0x00, 0x00, 0x2c, 0x04, 0xd0, + 0x00, 0x23, 0x02, 0x20, 0x1a, 0x00, 0x19, 0x00, 0xa0, 0x47, 0x00, 0x23, + 0x07, 0x93, 0x1c, 0x00, 0xb0, 0xe1, 0x80, 0x22, 0x00, 0x21, 0x52, 0x00, + 0x68, 0x6a, 0x04, 0xf0, 0x60, 0xfc, 0x07, 0x9b, 0x1b, 0x02, 0x0f, 0x93, + 0x00, 0x23, 0x0a, 0x93, 0xee, 0x68, 0x0a, 0x9b, 0x9e, 0x42, 0x09, 0xd8, + 0x00, 0x23, 0x06, 0x93, 0x06, 0x9b, 0x07, 0x9a, 0x5b, 0x00, 0xd3, 0x18, + 0x9b, 0xb2, 0x0a, 0x93, 0x00, 0x23, 0x0a, 0xe2, 0xeb, 0x6c, 0x05, 0x93, + 0x00, 0x2b, 0x13, 0xd0, 0x0a, 0x9b, 0x37, 0x01, 0x58, 0x04, 0x39, 0x00, + 0x04, 0xf0, 0x8a, 0xfb, 0x31, 0x00, 0x04, 0xf0, 0x87, 0xfb, 0x39, 0x00, + 0x06, 0x00, 0x0f, 0x98, 0x04, 0xf0, 0x82, 0xfb, 0x00, 0x23, 0x32, 0x18, + 0x19, 0x00, 0x02, 0x20, 0x05, 0x9e, 0xb0, 0x47, 0x0a, 0x9b, 0x1b, 0x01, + 0x01, 0x33, 0x9b, 0xb2, 0x06, 0x93, 0x0a, 0x9b, 0x01, 0x33, 0x1b, 0x01, + 0x0e, 0x93, 0x06, 0x9b, 0x0e, 0x9a, 0x93, 0x42, 0x01, 0xdb, 0x00, 0x23, + 0x69, 0xe1, 0x06, 0x9b, 0x00, 0x22, 0x1e, 0x02, 0x12, 0xab, 0x01, 0x93, + 0x05, 0x23, 0x15, 0x21, 0x00, 0x93, 0x28, 0x00, 0x33, 0x00, 0xff, 0xf7, + 0x86, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0xe5, 0xe0, 0x07, 0x9b, 0x06, 0x99, + 0x00, 0x22, 0x8b, 0x42, 0x07, 0xd8, 0xca, 0x0f, 0x07, 0x9b, 0xc6, 0x49, + 0x06, 0x98, 0x5b, 0x18, 0xd9, 0x17, 0x83, 0x42, 0x4a, 0x41, 0x06, 0x9b, + 0x07, 0x99, 0x58, 0x1a, 0x01, 0x21, 0x43, 0x08, 0x05, 0x93, 0x06, 0x9b, + 0x19, 0x40, 0x89, 0x00, 0x00, 0x2a, 0x0f, 0xd0, 0x12, 0xab, 0x1b, 0x79, + 0x5f, 0xb2, 0x00, 0x2f, 0x0a, 0xda, 0x01, 0x20, 0x03, 0x42, 0x07, 0xd1, + 0x6b, 0x6a, 0x05, 0x98, 0x1b, 0x18, 0x01, 0x20, 0x88, 0x40, 0x1f, 0x78, + 0x07, 0x43, 0x1f, 0x70, 0x12, 0xab, 0x1f, 0x79, 0x7b, 0xb2, 0x9c, 0x46, + 0x00, 0x23, 0x60, 0x46, 0x98, 0x42, 0x00, 0xdb, 0x22, 0xe1, 0x45, 0x20, + 0x07, 0x40, 0x40, 0x2f, 0x00, 0xd0, 0x1d, 0xe1, 0x9a, 0x42, 0x08, 0xd0, + 0x6b, 0x6a, 0x05, 0x9a, 0x02, 0x31, 0x98, 0x18, 0x01, 0x23, 0x8b, 0x40, + 0x02, 0x78, 0x13, 0x43, 0x03, 0x70, 0x2b, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x15, 0x21, 0x33, 0x00, 0x28, 0x00, + 0xff, 0xf7, 0x37, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0x96, 0xe0, 0x2b, 0x6a, + 0x05, 0x93, 0x12, 0xab, 0x5b, 0x88, 0x09, 0x93, 0x00, 0x2b, 0x00, 0xd0, + 0x81, 0xe0, 0x05, 0x9b, 0x2e, 0x33, 0x0b, 0x93, 0x69, 0x23, 0x0c, 0x93, + 0x00, 0x23, 0x08, 0x93, 0x08, 0x9b, 0x0b, 0x9a, 0x5b, 0x00, 0xd6, 0x5a, + 0x07, 0x9a, 0x00, 0x23, 0xb2, 0x42, 0x06, 0xd8, 0x13, 0x00, 0x96, 0x4a, + 0xf1, 0x0f, 0x9a, 0x18, 0xd3, 0x17, 0xb2, 0x42, 0x4b, 0x41, 0x94, 0x4a, + 0x94, 0x49, 0xb2, 0x18, 0x92, 0xb2, 0x8a, 0x42, 0x05, 0xd9, 0x00, 0x2b, + 0x00, 0xd1, 0x8b, 0xe0, 0x33, 0x07, 0x00, 0xd0, 0x92, 0xe0, 0x16, 0x27, + 0x09, 0x9b, 0x08, 0x9a, 0x28, 0x00, 0x9e, 0x18, 0x05, 0x9a, 0x05, 0x9b, + 0x51, 0x78, 0x1b, 0x78, 0x09, 0x02, 0x19, 0x43, 0x0c, 0xab, 0xff, 0x18, + 0xb6, 0xb2, 0x49, 0x04, 0x00, 0x23, 0x49, 0x0c, 0x00, 0x97, 0x32, 0x00, + 0x01, 0xf0, 0x2a, 0xfd, 0x85, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x51, 0xd1, + 0x00, 0x23, 0x3b, 0x80, 0x3b, 0x88, 0x00, 0x2b, 0x16, 0xd1, 0xfc, 0x20, + 0x05, 0x99, 0x05, 0x9a, 0x49, 0x78, 0x12, 0x78, 0x09, 0x02, 0x11, 0x43, + 0x14, 0xaa, 0x10, 0x71, 0x01, 0x20, 0x49, 0x04, 0x49, 0x0c, 0x11, 0x80, + 0x56, 0x80, 0x02, 0x90, 0x03, 0x97, 0x01, 0x93, 0x00, 0x93, 0x28, 0x00, + 0x01, 0xf0, 0x7c, 0xfd, 0x04, 0x1e, 0x37, 0xdb, 0x16, 0x23, 0x0c, 0xaa, + 0x05, 0x99, 0x9b, 0x18, 0x05, 0x9a, 0x49, 0x78, 0x12, 0x78, 0x09, 0x02, + 0x11, 0x43, 0x80, 0x22, 0x12, 0x02, 0x11, 0x43, 0x06, 0x9a, 0x1b, 0x88, + 0x28, 0x00, 0x00, 0x92, 0x32, 0x00, 0xff, 0xf7, 0x41, 0xfa, 0x6d, 0x4b, + 0x04, 0x00, 0xc3, 0x18, 0xee, 0x6c, 0x02, 0x2b, 0x28, 0xd8, 0x00, 0x2e, + 0x09, 0xd0, 0x05, 0x9a, 0x05, 0x9b, 0x52, 0x78, 0x1b, 0x78, 0x12, 0x02, + 0x1a, 0x43, 0x06, 0x21, 0x00, 0x23, 0x02, 0x20, 0xb0, 0x47, 0x06, 0x99, + 0x28, 0x00, 0x01, 0xf0, 0xd3, 0xfd, 0x04, 0x00, 0x25, 0xe0, 0x7c, 0x22, + 0x09, 0x9b, 0x0c, 0x92, 0x53, 0x43, 0x13, 0x3b, 0x9b, 0xb2, 0x09, 0x93, + 0x05, 0x9b, 0x08, 0x33, 0x0b, 0x93, 0x77, 0xe7, 0x00, 0x28, 0xad, 0xda, + 0xee, 0x6c, 0x00, 0x2e, 0x00, 0xd1, 0x80, 0xe0, 0x00, 0x23, 0x22, 0x00, + 0x01, 0x21, 0x02, 0x20, 0xb0, 0x47, 0x7a, 0xe0, 0x00, 0x2e, 0x0c, 0xd0, + 0x05, 0x9b, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, 0x13, 0x43, 0x05, 0x9a, + 0x11, 0x78, 0x52, 0x78, 0x12, 0x02, 0x0a, 0x43, 0x02, 0x21, 0x08, 0x00, + 0xb0, 0x47, 0x00, 0x2c, 0xe4, 0xdb, 0x01, 0x23, 0x08, 0x9a, 0x01, 0x32, + 0x08, 0x92, 0x00, 0x2b, 0x4c, 0xd1, 0x0c, 0x99, 0x8a, 0x42, 0x00, 0xd0, + 0x52, 0xe7, 0x47, 0xe0, 0x05, 0x22, 0x14, 0xaf, 0x00, 0x92, 0x33, 0x02, + 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xff, 0xf7, 0x6d, 0xf8, + 0x04, 0x1e, 0xcd, 0xdb, 0x12, 0xab, 0x1a, 0x88, 0x39, 0x88, 0x41, 0x4b, + 0x13, 0x40, 0x99, 0x42, 0x0b, 0xd1, 0x09, 0x9b, 0x08, 0x98, 0x79, 0x88, + 0x1b, 0x18, 0x99, 0x42, 0x05, 0xd1, 0x7a, 0x21, 0x3b, 0x79, 0x8b, 0x43, + 0x84, 0x2b, 0x00, 0xd1, 0x7d, 0xe0, 0x16, 0x27, 0x08, 0x99, 0x09, 0x9b, + 0x52, 0x04, 0x5b, 0x18, 0x9b, 0xb2, 0x0d, 0x93, 0x0c, 0xab, 0xff, 0x18, + 0x51, 0x0c, 0x33, 0x00, 0x00, 0x97, 0x0d, 0x9a, 0x28, 0x00, 0x01, 0xf0, + 0x7d, 0xfc, 0x2f, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x37, 0xd1, 0x00, 0x23, + 0x3b, 0x80, 0x3b, 0x88, 0x12, 0xae, 0x31, 0x88, 0x00, 0x2b, 0x33, 0xd1, + 0xec, 0x6c, 0x00, 0x2c, 0x03, 0xd0, 0x0a, 0x00, 0x02, 0x20, 0x06, 0x21, + 0xa0, 0x47, 0x31, 0x88, 0x28, 0x00, 0xff, 0xf7, 0x8d, 0xf9, 0x04, 0x1e, + 0x92, 0xdb, 0x00, 0x23, 0x06, 0x9a, 0x01, 0x32, 0x92, 0xb2, 0x06, 0x92, + 0x00, 0x2b, 0x00, 0xd1, 0x8f, 0xe6, 0x0a, 0x9a, 0x01, 0x32, 0x92, 0xb2, + 0x0a, 0x92, 0x00, 0x2b, 0x00, 0xd1, 0x59, 0xe6, 0xeb, 0x68, 0x07, 0x9a, + 0x1b, 0x01, 0x9a, 0x42, 0x00, 0xd2, 0x48, 0xe6, 0x00, 0x2c, 0x00, 0xd0, + 0x7a, 0xe7, 0xed, 0x6c, 0x00, 0x2d, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, + 0x19, 0x00, 0x52, 0x00, 0x02, 0x20, 0xa8, 0x47, 0x20, 0x00, 0x17, 0xb0, + 0xf0, 0xbd, 0x00, 0x28, 0xc7, 0xda, 0x6b, 0xe7, 0x06, 0x9a, 0x28, 0x00, + 0x00, 0x92, 0x0d, 0x9a, 0xff, 0xf7, 0x82, 0xf9, 0x0d, 0x4b, 0x04, 0x00, + 0xc3, 0x18, 0xef, 0x6c, 0x02, 0x2b, 0x19, 0xd8, 0x32, 0x88, 0x00, 0x2f, + 0x03, 0xd0, 0x00, 0x23, 0x06, 0x21, 0x02, 0x20, 0xb8, 0x47, 0x12, 0xab, + 0x19, 0x88, 0x28, 0x00, 0xff, 0xf7, 0x4c, 0xf9, 0x43, 0xe7, 0xc0, 0x46, + 0xff, 0x01, 0x00, 0x00, 0xff, 0xdf, 0xff, 0xff, 0xfd, 0xdf, 0x00, 0x00, + 0xee, 0xd8, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, 0xff, 0x7f, 0xff, 0xff, + 0x00, 0x2f, 0x00, 0xd1, 0x5b, 0xe7, 0x02, 0x21, 0x73, 0x88, 0x32, 0x88, + 0x08, 0x00, 0xb8, 0x47, 0x55, 0xe7, 0x01, 0x21, 0x07, 0x9b, 0xf7, 0x1a, + 0x6b, 0x6a, 0x7f, 0x08, 0x0e, 0x40, 0xb6, 0x00, 0xdb, 0x5d, 0x76, 0x18, + 0x33, 0x41, 0x0b, 0x40, 0x16, 0xd0, 0xec, 0x6c, 0x00, 0x2c, 0x03, 0xd0, + 0x00, 0x23, 0x05, 0x31, 0x02, 0x20, 0xa0, 0x47, 0x12, 0xab, 0x19, 0x88, + 0x28, 0x00, 0xff, 0xf7, 0x1d, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0x21, 0xe7, + 0x06, 0x99, 0x28, 0x00, 0x01, 0xf0, 0xe2, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0x1a, 0xe7, 0x01, 0x23, 0x01, 0x21, 0xb1, 0x40, 0x6a, 0x6a, 0xd7, 0x19, + 0x3a, 0x78, 0x0a, 0x43, 0x3a, 0x70, 0x2d, 0xe7, 0x01, 0x23, 0x08, 0x93, + 0x06, 0x9a, 0x6b, 0x6a, 0x9b, 0x5c, 0x08, 0x9a, 0x92, 0x00, 0x13, 0x41, + 0x07, 0x22, 0x1a, 0x40, 0x09, 0x92, 0x01, 0x2a, 0x00, 0xd0, 0x93, 0xe0, + 0x08, 0x9a, 0x0a, 0x9b, 0x12, 0xae, 0x9b, 0x18, 0x05, 0x22, 0x9b, 0xb2, + 0x05, 0x93, 0x00, 0x92, 0x1b, 0x02, 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, + 0x28, 0x00, 0xfe, 0xf7, 0x92, 0xff, 0x04, 0x1e, 0x00, 0xda, 0xf1, 0xe6, + 0x16, 0x27, 0x0c, 0xab, 0xff, 0x18, 0x11, 0xab, 0x72, 0x88, 0x31, 0x88, + 0x28, 0x00, 0x00, 0x93, 0x3b, 0x00, 0xff, 0xf7, 0xa5, 0xf8, 0x04, 0x1e, + 0x61, 0xd1, 0x80, 0x22, 0x3b, 0x88, 0x92, 0x01, 0x93, 0x42, 0x20, 0xd8, + 0x1a, 0x07, 0x1e, 0xd0, 0x05, 0x22, 0x14, 0xaf, 0x00, 0x92, 0x1b, 0x02, + 0x02, 0x00, 0x01, 0x97, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x71, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0xd0, 0xe6, 0x38, 0x4a, 0x33, 0x88, 0x13, 0x40, + 0x3a, 0x88, 0x93, 0x42, 0x04, 0xd1, 0x78, 0x22, 0x3b, 0x79, 0x93, 0x43, + 0x84, 0x2b, 0x45, 0xd0, 0x16, 0x23, 0x0c, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0x05, 0x9a, 0x93, 0x42, 0x4e, 0xd0, 0x11, 0xab, 0x1b, 0x88, 0x12, 0xae, + 0x72, 0x88, 0x31, 0x88, 0x28, 0x00, 0x00, 0x93, 0x05, 0x9b, 0xff, 0xf7, + 0xd1, 0xf8, 0x2b, 0x4b, 0x04, 0x00, 0xc3, 0x18, 0xef, 0x6c, 0x02, 0x2b, + 0x45, 0xd8, 0x00, 0x2f, 0x04, 0xd0, 0x32, 0x88, 0x00, 0x23, 0x06, 0x21, + 0x02, 0x20, 0xb8, 0x47, 0x05, 0x99, 0x28, 0x00, 0x01, 0xf0, 0x68, 0xfc, + 0x04, 0x1e, 0x00, 0xda, 0xa0, 0xe6, 0x31, 0x88, 0x28, 0x00, 0xff, 0xf7, + 0x95, 0xf8, 0x04, 0x00, 0x00, 0x2c, 0x00, 0xda, 0x98, 0xe6, 0x06, 0x9b, + 0x01, 0x33, 0x06, 0x93, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x0d, 0xe7, + 0x06, 0x9b, 0x1a, 0x00, 0x80, 0x23, 0x5b, 0x00, 0x9a, 0x42, 0x00, 0xd0, + 0x66, 0xe5, 0x80, 0x22, 0x92, 0x00, 0x94, 0x46, 0x07, 0x9b, 0x63, 0x44, + 0x9b, 0xb2, 0x07, 0x93, 0xfe, 0xe6, 0x13, 0x4b, 0x98, 0x42, 0x0c, 0xd1, + 0xec, 0x6c, 0x00, 0x2c, 0x04, 0xd0, 0x00, 0x23, 0x05, 0x9a, 0x05, 0x21, + 0x02, 0x20, 0xa0, 0x47, 0x05, 0x99, 0x28, 0x00, 0x01, 0xf0, 0x38, 0xfc, + 0x04, 0x00, 0x00, 0x2c, 0x00, 0xda, 0x6f, 0xe6, 0x08, 0x9b, 0x01, 0x2b, + 0x00, 0xd0, 0x59, 0xe7, 0x00, 0x23, 0x09, 0x93, 0xcf, 0xe7, 0x00, 0x2f, + 0xca, 0xd0, 0x02, 0x21, 0x73, 0x88, 0x32, 0x88, 0x08, 0x00, 0xb8, 0x47, + 0xc4, 0xe7, 0xc0, 0x46, 0xff, 0x7f, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, + 0xee, 0xd8, 0xff, 0xff, 0x80, 0x22, 0xf0, 0xb5, 0x06, 0x00, 0x89, 0xb0, + 0x00, 0x21, 0x52, 0x00, 0x40, 0x6a, 0x04, 0xf0, 0x82, 0xf9, 0x00, 0x21, + 0xf4, 0x6c, 0x07, 0x91, 0x8c, 0x42, 0x03, 0xd0, 0x0b, 0x00, 0x0a, 0x00, + 0x01, 0x20, 0xa0, 0x47, 0x00, 0x24, 0x07, 0xab, 0x03, 0x93, 0x14, 0x4b, + 0x05, 0x94, 0x01, 0x93, 0x04, 0x94, 0x23, 0x00, 0x02, 0x94, 0x00, 0x94, + 0x22, 0x00, 0x21, 0x00, 0x30, 0x00, 0x01, 0xf0, 0x2f, 0xf9, 0x0f, 0x4b, + 0x05, 0x00, 0x98, 0x42, 0x15, 0xd0, 0xa0, 0x42, 0x07, 0xd0, 0xf7, 0x6c, + 0xa7, 0x42, 0x04, 0xd0, 0x01, 0x21, 0x02, 0x00, 0x23, 0x00, 0x08, 0x00, + 0xb8, 0x47, 0xf4, 0x6c, 0x00, 0x2c, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, + 0x19, 0x00, 0x52, 0x00, 0x01, 0x20, 0xa0, 0x47, 0x28, 0x00, 0x09, 0xb0, + 0xf0, 0xbd, 0x25, 0x00, 0xf1, 0xe7, 0xc0, 0x46, 0xe9, 0x31, 0x00, 0x00, + 0xa8, 0xd8, 0xff, 0xff, 0xf8, 0xb5, 0x06, 0x00, 0x0c, 0x00, 0x01, 0xf0, + 0xcf, 0xf9, 0x05, 0x1e, 0x0c, 0xdb, 0x24, 0x01, 0xa4, 0xb2, 0x27, 0x00, + 0x10, 0x37, 0xbf, 0xb2, 0x21, 0x00, 0x01, 0x34, 0x30, 0x00, 0xa4, 0xb2, + 0xfe, 0xf7, 0x96, 0xfe, 0xbc, 0x42, 0xf7, 0xd1, 0x28, 0x00, 0xf8, 0xbd, + 0xf0, 0xb5, 0x05, 0x00, 0x0f, 0x00, 0x00, 0x24, 0xc3, 0x68, 0x87, 0xb0, + 0x03, 0x93, 0x03, 0x6a, 0x02, 0x93, 0xa2, 0xb2, 0x04, 0x92, 0x03, 0x9a, + 0x23, 0x03, 0xa2, 0x42, 0x01, 0xd1, 0x1e, 0x48, 0x35, 0xe0, 0x2a, 0x6a, + 0x14, 0x21, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x28, 0x00, + 0x00, 0x22, 0xfe, 0xf7, 0x84, 0xfe, 0x02, 0x99, 0x18, 0x4e, 0x0b, 0x00, + 0x1e, 0x33, 0x05, 0x93, 0x00, 0x23, 0xb4, 0x46, 0x1a, 0x00, 0x98, 0x42, + 0x0b, 0xd0, 0x01, 0x28, 0x13, 0xd9, 0x01, 0x34, 0x00, 0x28, 0x1c, 0xd1, + 0xdd, 0xe7, 0x08, 0x88, 0x00, 0x28, 0x06, 0xd1, 0x01, 0x32, 0x92, 0xb2, + 0x02, 0x31, 0x05, 0x98, 0x81, 0x42, 0xf6, 0xd1, 0x05, 0xe0, 0x60, 0x45, + 0x03, 0xd1, 0x01, 0x33, 0x9b, 0xb2, 0xbb, 0x42, 0xf4, 0xd9, 0xd1, 0x18, + 0x0f, 0x29, 0x0a, 0xd1, 0xbb, 0x42, 0x08, 0xd8, 0xeb, 0x6b, 0x04, 0x99, + 0x9a, 0x1a, 0xea, 0x63, 0x28, 0x00, 0xff, 0xf7, 0xa3, 0xff, 0x07, 0xb0, + 0xf0, 0xbd, 0x01, 0x34, 0xbd, 0xe7, 0xc0, 0x46, 0xd3, 0xd8, 0xff, 0xff, + 0xff, 0xff, 0x00, 0x00, 0xf7, 0xb5, 0x80, 0x22, 0x04, 0x6a, 0x52, 0x00, + 0x0b, 0x03, 0x00, 0x92, 0x14, 0x21, 0x00, 0x22, 0x01, 0x94, 0x05, 0x00, + 0x26, 0x00, 0xfe, 0xf7, 0x42, 0xfe, 0x00, 0x22, 0x23, 0x00, 0x1e, 0x36, + 0x11, 0x00, 0x0b, 0x4f, 0x90, 0x42, 0x0d, 0xd0, 0xab, 0x6b, 0x9a, 0x1a, + 0xeb, 0x6b, 0xaa, 0x63, 0x59, 0x1a, 0xe9, 0x63, 0xfe, 0xbd, 0x1c, 0x88, + 0xbc, 0x42, 0x02, 0xd0, 0x00, 0x2c, 0x04, 0xd1, 0x01, 0x31, 0x02, 0x33, + 0x9e, 0x42, 0xf6, 0xd1, 0xee, 0xe7, 0x01, 0x32, 0xf9, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xf0, 0xb5, 0x1d, 0x00, 0xc3, 0x68, 0x93, 0xb0, + 0x05, 0x93, 0x03, 0x6a, 0x04, 0x00, 0x0c, 0x93, 0x05, 0x9b, 0x0f, 0x00, + 0x08, 0x92, 0x03, 0x93, 0x29, 0x2b, 0x01, 0xd9, 0x29, 0x23, 0x03, 0x93, + 0x00, 0x26, 0x80, 0x22, 0x08, 0x9b, 0x52, 0x00, 0x1e, 0x60, 0xff, 0x21, + 0x60, 0x6a, 0x04, 0xf0, 0xa0, 0xf8, 0x63, 0x6a, 0x02, 0x96, 0x06, 0x93, + 0x03, 0x9b, 0x06, 0x9a, 0x5b, 0x00, 0xd3, 0x18, 0x03, 0x22, 0x09, 0x93, + 0x03, 0x33, 0x93, 0x43, 0x0a, 0x93, 0x06, 0x9b, 0x0a, 0x9a, 0x3b, 0x60, + 0x6b, 0x42, 0x5d, 0x41, 0x32, 0x23, 0x6d, 0x42, 0x2b, 0x40, 0x0f, 0x93, + 0x03, 0x9b, 0x9b, 0x00, 0x9b, 0x18, 0x0e, 0x93, 0x6a, 0x46, 0x12, 0x89, + 0x02, 0x9b, 0x0d, 0x92, 0x05, 0x99, 0x02, 0x9a, 0x1b, 0x03, 0x8a, 0x42, + 0x01, 0xd1, 0x00, 0x20, 0x4f, 0xe0, 0x22, 0x6a, 0x14, 0x21, 0x01, 0x92, + 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x20, 0x00, 0x00, 0x22, 0xfe, 0xf7, + 0xde, 0xfd, 0x0c, 0x9b, 0x00, 0x25, 0x19, 0x00, 0x2f, 0x00, 0x1e, 0x31, + 0x3a, 0x4e, 0xa8, 0x42, 0x47, 0xd0, 0x01, 0x28, 0x3b, 0xd1, 0x0e, 0x26, + 0x6b, 0x46, 0x0e, 0xaa, 0xb6, 0x18, 0x02, 0x22, 0x1b, 0x89, 0x15, 0x21, + 0x1b, 0x03, 0x00, 0x92, 0xfe, 0x33, 0x01, 0x96, 0x00, 0x22, 0x20, 0x00, + 0xfe, 0xf7, 0xc5, 0xfd, 0x00, 0x28, 0x2a, 0xdb, 0x23, 0x1d, 0xda, 0x8f, + 0x33, 0x88, 0x9a, 0x42, 0x35, 0xd9, 0xd3, 0x1a, 0x05, 0x22, 0x57, 0x43, + 0x0f, 0x9a, 0x9b, 0xb2, 0x53, 0x43, 0x7d, 0x1b, 0xeb, 0x18, 0x07, 0x93, + 0x00, 0x23, 0x06, 0x99, 0x27, 0x4d, 0x03, 0x9a, 0x93, 0x42, 0x0b, 0xda, + 0x0a, 0x9e, 0x9a, 0x00, 0x92, 0x19, 0x0e, 0x88, 0x0b, 0x91, 0xae, 0x42, + 0x22, 0xd1, 0x6b, 0x46, 0x9b, 0x8e, 0x0b, 0x80, 0x07, 0x9b, 0x13, 0x60, + 0x08, 0x9b, 0x08, 0x9a, 0x1b, 0x68, 0x04, 0x93, 0x01, 0x33, 0x13, 0x60, + 0x02, 0x9b, 0x01, 0x33, 0x02, 0x93, 0x00, 0x28, 0xa4, 0xd0, 0x13, 0xb0, + 0xf0, 0xbd, 0x1a, 0x88, 0xb2, 0x42, 0xbe, 0xd0, 0x00, 0x2a, 0x05, 0xd1, + 0x01, 0x37, 0xbf, 0xb2, 0x02, 0x33, 0x99, 0x42, 0xf5, 0xd1, 0xb6, 0xe7, + 0x01, 0x35, 0xad, 0xb2, 0xf8, 0xe7, 0x9b, 0x1a, 0xdb, 0x43, 0xc7, 0xe7, + 0x0b, 0x99, 0x16, 0x68, 0x07, 0x9f, 0x02, 0x31, 0xbe, 0x42, 0x19, 0xda, + 0x03, 0x99, 0x09, 0x9d, 0x02, 0x39, 0x04, 0x91, 0x0e, 0x99, 0x04, 0x9e, + 0x02, 0x3d, 0x0f, 0x1f, 0xb3, 0x42, 0x04, 0xdd, 0x69, 0x46, 0x0b, 0x9b, + 0x89, 0x8e, 0x19, 0x80, 0xca, 0xe7, 0xae, 0x1e, 0x08, 0x39, 0x36, 0x88, + 0x09, 0x68, 0x2e, 0x80, 0x39, 0x60, 0x04, 0x99, 0x01, 0x39, 0x04, 0x91, + 0x39, 0x00, 0xea, 0xe7, 0x01, 0x33, 0xb0, 0xe7, 0xff, 0xff, 0x00, 0x00, + 0xf0, 0xb5, 0x05, 0x00, 0x03, 0x6a, 0x9b, 0xb0, 0x0f, 0x93, 0x43, 0x6a, + 0x0c, 0x00, 0x14, 0x22, 0x00, 0x21, 0x15, 0xa8, 0x0a, 0x93, 0x03, 0xf0, + 0xe8, 0xff, 0x2b, 0x8a, 0xa3, 0x42, 0x06, 0xd1, 0x60, 0x1c, 0xe9, 0x68, + 0x03, 0xf0, 0xae, 0xff, 0x00, 0x23, 0x29, 0x82, 0x6b, 0x61, 0x23, 0x01, + 0x01, 0x33, 0x9b, 0xb2, 0x11, 0x93, 0x0f, 0x9b, 0x24, 0x03, 0x1b, 0x19, + 0x10, 0x93, 0x00, 0x23, 0x08, 0x93, 0x8f, 0xe1, 0x0c, 0x9a, 0x10, 0x9b, + 0x14, 0x21, 0x9b, 0x1a, 0x0d, 0x93, 0x2b, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x28, 0x00, 0x0d, 0x9b, 0xfe, 0xf7, + 0x30, 0xfd, 0x04, 0x00, 0x00, 0x2c, 0x07, 0xd1, 0x07, 0x9b, 0x0e, 0x9a, + 0x9b, 0x1a, 0x7f, 0x2b, 0x02, 0xdc, 0x07, 0x9b, 0x0e, 0x2b, 0x01, 0xdd, + 0x3b, 0x00, 0x88, 0xe0, 0x07, 0x9b, 0x0c, 0x9a, 0x5b, 0x00, 0xd3, 0x5a, + 0x07, 0x9a, 0x09, 0x93, 0x11, 0x9b, 0x9b, 0x18, 0x9b, 0xb2, 0x15, 0xaa, + 0x08, 0x93, 0x13, 0x78, 0x01, 0x2b, 0x15, 0xd0, 0x00, 0x2b, 0x04, 0xd0, + 0x02, 0x2b, 0x00, 0xd1, 0x8f, 0xe0, 0x23, 0x00, 0x6d, 0xe0, 0x6b, 0x46, + 0x24, 0x21, 0x59, 0x5e, 0x3b, 0x00, 0x00, 0x29, 0x00, 0xdc, 0x66, 0xe0, + 0x6b, 0x46, 0x9b, 0x8c, 0x17, 0x74, 0x53, 0x80, 0x6b, 0x46, 0x1b, 0x8c, + 0x13, 0x81, 0xee, 0xe7, 0x52, 0x88, 0x09, 0x99, 0x3b, 0x00, 0x8a, 0x42, + 0x59, 0xd1, 0x05, 0x22, 0x08, 0x9b, 0x13, 0xae, 0x00, 0x92, 0x1b, 0x02, + 0x22, 0x00, 0x01, 0x96, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0xef, 0xfc, + 0x04, 0x1e, 0x2d, 0xdb, 0x73, 0x88, 0x00, 0x20, 0x68, 0x2b, 0x05, 0xd9, + 0x69, 0x3b, 0x18, 0x00, 0x7c, 0x21, 0x03, 0xf0, 0xbf, 0xfe, 0x01, 0x30, + 0x15, 0xab, 0x9e, 0x88, 0x86, 0x42, 0x3d, 0xd1, 0x13, 0xab, 0x1a, 0x79, + 0x7f, 0x2a, 0x1e, 0xd9, 0x1a, 0x22, 0x0c, 0xa9, 0x52, 0x18, 0x02, 0x92, + 0x08, 0x9a, 0x00, 0x93, 0x01, 0x92, 0x00, 0x22, 0x09, 0x9b, 0x11, 0x00, + 0x28, 0x00, 0x01, 0xf0, 0x25, 0xfa, 0x04, 0x1e, 0x0c, 0xdb, 0x2b, 0x6a, + 0x00, 0x22, 0x01, 0x93, 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x14, 0x21, + 0x0d, 0x9b, 0x28, 0x00, 0xfe, 0xf7, 0xc1, 0xfc, 0x04, 0x1e, 0x0e, 0xda, + 0x20, 0x00, 0x1b, 0xb0, 0xf0, 0xbd, 0x08, 0x99, 0x28, 0x00, 0x01, 0xf0, + 0xdf, 0xf9, 0x04, 0x1e, 0xf6, 0xdb, 0x1a, 0x23, 0x0c, 0xaa, 0x9b, 0x18, + 0x01, 0x22, 0x52, 0x42, 0x1a, 0x80, 0x13, 0xab, 0x58, 0x88, 0x1a, 0x23, + 0x0c, 0xaa, 0x9b, 0x18, 0x1b, 0x88, 0x09, 0x93, 0x00, 0x2e, 0x1c, 0xd1, + 0x17, 0x30, 0x6a, 0x46, 0x0a, 0x9b, 0x92, 0x8c, 0x40, 0x00, 0x1a, 0x52, + 0x3b, 0x00, 0x07, 0x9a, 0x01, 0x32, 0x07, 0x92, 0x00, 0x2b, 0x00, 0xd0, + 0x6a, 0xe7, 0x0b, 0x9a, 0x01, 0x32, 0x0b, 0x92, 0x00, 0x2b, 0x6b, 0xd0, + 0x0e, 0x9b, 0x80, 0x33, 0x0e, 0x93, 0x0c, 0x9b, 0x01, 0x3b, 0xff, 0x3b, + 0x0c, 0x93, 0x00, 0x2c, 0x00, 0xd1, 0x2d, 0xe1, 0xca, 0xe7, 0x68, 0x28, + 0x01, 0xd8, 0x04, 0x30, 0xdf, 0xe7, 0x69, 0x38, 0x7c, 0x21, 0x03, 0xf0, + 0xe3, 0xfe, 0x08, 0x1d, 0xd9, 0xe7, 0x09, 0x9b, 0x98, 0x4a, 0x99, 0x49, + 0x9a, 0x18, 0x92, 0xb2, 0x3b, 0x00, 0x8a, 0x42, 0xd7, 0xd8, 0x05, 0x22, + 0x08, 0x9b, 0x13, 0xae, 0x00, 0x92, 0x1b, 0x02, 0x22, 0x00, 0x01, 0x96, + 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x6d, 0xfc, 0x04, 0x1e, 0xab, 0xdb, + 0x33, 0x79, 0x7f, 0x2b, 0x2b, 0xd9, 0x1a, 0x23, 0x0c, 0xaa, 0x9b, 0x18, + 0x00, 0x22, 0x02, 0x93, 0x08, 0x9b, 0x00, 0x96, 0x01, 0x93, 0x11, 0x00, + 0x09, 0x9b, 0x28, 0x00, 0x01, 0xf0, 0xb2, 0xf9, 0x04, 0x1e, 0x00, 0xda, + 0x98, 0xe7, 0x00, 0x24, 0x0c, 0xab, 0x02, 0x94, 0x5b, 0x8b, 0x13, 0xa9, + 0x01, 0x93, 0x4b, 0x88, 0x03, 0x22, 0x00, 0x93, 0x28, 0x00, 0x09, 0x9b, + 0x01, 0xf0, 0x20, 0xfa, 0x2b, 0x6a, 0x22, 0x00, 0x01, 0x93, 0x80, 0x23, + 0x5b, 0x00, 0x00, 0x93, 0x14, 0x21, 0x0d, 0x9b, 0x28, 0x00, 0xfe, 0xf7, + 0x40, 0xfc, 0x04, 0x00, 0x00, 0x2c, 0x9b, 0xda, 0x7c, 0xe7, 0x08, 0x99, + 0x28, 0x00, 0x01, 0xf0, 0x5f, 0xf9, 0x04, 0x1e, 0xf6, 0xd1, 0x00, 0x21, + 0x08, 0x9b, 0x02, 0x91, 0x01, 0x93, 0x13, 0xab, 0x5b, 0x88, 0x02, 0x22, + 0x00, 0x93, 0x28, 0x00, 0x09, 0x9b, 0x01, 0xf0, 0xff, 0xf9, 0x87, 0xe7, + 0x00, 0x2c, 0x00, 0xd1, 0xcc, 0xe0, 0x65, 0xe7, 0x0b, 0x7c, 0x00, 0x2b, + 0x70, 0xd0, 0x07, 0x9b, 0x05, 0x22, 0xcb, 0x60, 0x01, 0x23, 0x0b, 0x70, + 0x08, 0x9b, 0x13, 0xaf, 0x00, 0x92, 0x1b, 0x02, 0x01, 0x97, 0x32, 0x00, + 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x13, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0x50, 0xe7, 0x78, 0x88, 0x37, 0x00, 0x68, 0x28, 0x05, 0xd9, 0x69, 0x38, + 0x7c, 0x21, 0x03, 0xf0, 0xe3, 0xfd, 0x01, 0x30, 0x87, 0xb2, 0x80, 0x23, + 0x15, 0xae, 0x71, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1a, 0x23, 0x0c, 0xaa, + 0x9b, 0x18, 0xb7, 0x80, 0x3a, 0x00, 0x00, 0x93, 0x28, 0x00, 0x00, 0x23, + 0x01, 0xf0, 0x2c, 0xf8, 0x56, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x0c, 0xd1, + 0x31, 0x89, 0x28, 0x00, 0x01, 0xf0, 0x16, 0xf9, 0x04, 0x1e, 0x00, 0xda, + 0x2c, 0xe7, 0x00, 0x23, 0x33, 0x70, 0x00, 0x2c, 0x00, 0xd0, 0x27, 0xe7, + 0x71, 0xe0, 0x00, 0x28, 0x00, 0xda, 0x23, 0xe7, 0x6a, 0x6a, 0x0c, 0xab, + 0x5b, 0x8b, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x1b, 0x02, + 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0xd6, 0xfb, 0x04, 0x1e, + 0x00, 0xda, 0x13, 0xe7, 0x0a, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x13, 0xd4, + 0x5a, 0xb2, 0x00, 0x2a, 0x12, 0xda, 0x9a, 0x07, 0x12, 0xd4, 0x04, 0x22, + 0x1a, 0x40, 0x11, 0xd1, 0x0a, 0x9b, 0x99, 0x78, 0xdb, 0x78, 0x1b, 0x02, + 0x0b, 0x43, 0xbb, 0x42, 0x0c, 0xd1, 0x0c, 0xab, 0x5b, 0x8b, 0x07, 0x92, + 0xf3, 0x80, 0xd0, 0xe7, 0x39, 0x4c, 0xf9, 0xe6, 0x39, 0x4c, 0xf7, 0xe6, + 0x39, 0x4c, 0xf5, 0xe6, 0x39, 0x4c, 0xf3, 0xe6, 0x39, 0x4c, 0xf1, 0xe6, + 0x02, 0x22, 0x0a, 0x70, 0x07, 0x93, 0x38, 0xe0, 0x80, 0x22, 0x00, 0x26, + 0xcb, 0x68, 0x12, 0x02, 0x07, 0x93, 0x4b, 0x88, 0x0e, 0x70, 0x09, 0x93, + 0x1a, 0x43, 0xcb, 0x88, 0x89, 0x88, 0x68, 0x6a, 0x13, 0xaf, 0xb1, 0x42, + 0x0b, 0xd1, 0x00, 0x90, 0x04, 0x97, 0x03, 0x91, 0x02, 0x91, 0x01, 0x91, + 0x28, 0x00, 0x01, 0xf0, 0x93, 0xfa, 0x04, 0x00, 0xb0, 0x42, 0xa8, 0xda, + 0xd2, 0xe6, 0x01, 0x93, 0x02, 0x97, 0x13, 0x00, 0x00, 0x96, 0x02, 0x00, + 0x31, 0x00, 0x28, 0x00, 0x01, 0xf0, 0xe0, 0xf8, 0x04, 0x1e, 0x00, 0xda, + 0xc6, 0xe6, 0x02, 0x96, 0x3b, 0x88, 0x69, 0x6a, 0x01, 0x93, 0x0a, 0x9b, + 0x28, 0x00, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, 0x13, 0x43, 0x00, 0x93, + 0x32, 0x00, 0x09, 0x9b, 0x01, 0xf0, 0x4c, 0xf9, 0x8b, 0xe7, 0x03, 0x23, + 0x0b, 0x70, 0x15, 0xab, 0x1a, 0x78, 0x00, 0x24, 0x03, 0x2a, 0x00, 0xd1, + 0xae, 0xe6, 0x7f, 0x22, 0x01, 0x27, 0x1c, 0x74, 0x07, 0x9b, 0xdb, 0x17, + 0x13, 0x40, 0x07, 0x9a, 0x9b, 0x18, 0xdb, 0x11, 0x0b, 0x93, 0xdb, 0x01, + 0x0e, 0x93, 0x0b, 0x9b, 0x0f, 0x9a, 0x1b, 0x02, 0xd3, 0x1a, 0x0c, 0x93, + 0x0b, 0x9b, 0x00, 0x2b, 0x00, 0xdc, 0x19, 0xe6, 0x15, 0xa9, 0x0e, 0x78, + 0x01, 0x2e, 0xa7, 0xd0, 0x00, 0x2e, 0x00, 0xd1, 0x2c, 0xe7, 0x02, 0x2e, + 0xd9, 0xd0, 0x00, 0x23, 0x9e, 0xe7, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, + 0xfe, 0x7f, 0x00, 0x00, 0xee, 0xd8, 0xff, 0xff, 0xe4, 0xd8, 0xff, 0xff, + 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, + 0xe3, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0f, 0x26, 0xc3, 0x68, 0x87, 0xb0, + 0x5e, 0x43, 0x83, 0x6b, 0x04, 0x00, 0xf6, 0x1a, 0xc3, 0x6b, 0x1e, 0x3e, + 0xf5, 0x1a, 0x43, 0x6b, 0x0f, 0x00, 0x03, 0x2b, 0x04, 0xd9, 0xfb, 0x23, + 0x6b, 0x43, 0x00, 0x20, 0x8b, 0x42, 0x19, 0xdc, 0x38, 0x00, 0xfb, 0x21, + 0xfa, 0x30, 0x03, 0xf0, 0xff, 0xfc, 0x02, 0x90, 0x86, 0x42, 0x44, 0xdb, + 0x05, 0x23, 0x01, 0x93, 0x6b, 0x1e, 0x2b, 0x43, 0xdb, 0x0f, 0x05, 0xaa, + 0x04, 0xa9, 0x20, 0x00, 0xff, 0xf7, 0xf2, 0xfc, 0x00, 0x28, 0x05, 0xdb, + 0x05, 0x98, 0x00, 0x28, 0x04, 0xd1, 0x02, 0x9b, 0xab, 0x42, 0x32, 0xda, + 0x07, 0xb0, 0xf0, 0xbd, 0x04, 0x9b, 0x01, 0x22, 0x1e, 0x88, 0x23, 0x00, + 0x40, 0x33, 0x1a, 0x70, 0x31, 0x00, 0x20, 0x00, 0x03, 0x93, 0xff, 0xf7, + 0xa1, 0xfd, 0x00, 0x23, 0x03, 0x9a, 0x13, 0x70, 0x98, 0x42, 0xed, 0xdb, + 0x31, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xaa, 0xfc, 0x00, 0x28, 0xe7, 0xdb, + 0x31, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x3e, 0xfc, 0x00, 0x28, 0xe1, 0xdb, + 0x0f, 0x22, 0xe3, 0x68, 0x53, 0x43, 0xa2, 0x6b, 0x9b, 0x1a, 0xe2, 0x6b, + 0x1e, 0x3b, 0x9b, 0x1a, 0x00, 0x2d, 0x01, 0xdc, 0x9d, 0x42, 0x04, 0xd0, + 0x01, 0x9a, 0x01, 0x3a, 0x01, 0x92, 0x00, 0x2a, 0x05, 0xd1, 0xfb, 0x22, + 0x53, 0x43, 0xbb, 0x42, 0xcc, 0xda, 0x05, 0x48, 0xca, 0xe7, 0x62, 0x6b, + 0x02, 0x2a, 0x03, 0xd9, 0xfb, 0x22, 0x5a, 0x43, 0xba, 0x42, 0xf2, 0xda, + 0x1d, 0x00, 0xb1, 0xe7, 0xef, 0xd8, 0xff, 0xff, 0xf7, 0xb5, 0x84, 0x68, + 0x07, 0x00, 0x01, 0x91, 0x15, 0x00, 0x1e, 0x00, 0x63, 0x1c, 0x17, 0xd0, + 0x33, 0x00, 0x94, 0x42, 0x10, 0xd9, 0xa4, 0x1a, 0xb4, 0x42, 0x00, 0xdd, + 0x34, 0x00, 0x23, 0x00, 0x01, 0x9a, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, + 0x47, 0xfd, 0x00, 0x28, 0x07, 0xdb, 0x01, 0x9a, 0x33, 0x1b, 0x12, 0x19, + 0x01, 0x92, 0x2d, 0x19, 0x00, 0x2b, 0x03, 0xdc, 0x30, 0x00, 0xfe, 0xbd, + 0x33, 0x00, 0xf9, 0xe7, 0x01, 0x9a, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, + 0x7d, 0xfa, 0x00, 0x28, 0xf4, 0xda, 0xf4, 0xe7, 0x73, 0xb5, 0x01, 0xaa, + 0x05, 0x00, 0x02, 0xf0, 0x59, 0xfc, 0x04, 0x1e, 0x02, 0xda, 0x28, 0x63, + 0x20, 0x00, 0x76, 0xbd, 0x01, 0x9e, 0xb3, 0x8b, 0x9b, 0x06, 0xf9, 0xd4, + 0x33, 0x6a, 0x00, 0x2b, 0x04, 0xd1, 0x31, 0x00, 0x28, 0x00, 0xfe, 0xf7, + 0x29, 0xfb, 0x30, 0x62, 0x01, 0x98, 0x02, 0x6a, 0x00, 0x2a, 0xed, 0xd0, + 0x8a, 0x21, 0x56, 0x78, 0x49, 0x00, 0x71, 0x43, 0x6c, 0x6c, 0x14, 0x31, + 0x24, 0x69, 0x13, 0x8a, 0x61, 0x18, 0xd2, 0x68, 0xff, 0xf7, 0xb0, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0x28, 0x63, 0x01, 0x9b, 0x28, 0x00, 0x19, 0x6a, + 0xfe, 0xf7, 0x34, 0xfb, 0xd8, 0xe7, 0x00, 0x00, 0xf7, 0xb5, 0x04, 0x00, + 0x1d, 0x00, 0x83, 0x6d, 0x17, 0x00, 0x01, 0x91, 0x60, 0x22, 0x00, 0x21, + 0x00, 0x93, 0x0a, 0x9e, 0x03, 0xf0, 0xfd, 0xfc, 0x0c, 0x22, 0x01, 0x99, + 0x20, 0x00, 0x03, 0xf0, 0xef, 0xfc, 0x00, 0x9b, 0x08, 0x9a, 0xa3, 0x65, + 0x80, 0x23, 0x9b, 0x00, 0xe3, 0x60, 0x7b, 0x1c, 0xff, 0x33, 0x67, 0x62, + 0x23, 0x62, 0x00, 0x21, 0x28, 0x00, 0x03, 0xf0, 0xea, 0xfc, 0x03, 0x22, + 0x2a, 0x40, 0x05, 0xd0, 0x04, 0x23, 0x9b, 0x1a, 0x08, 0x9a, 0xed, 0x18, + 0xd3, 0x1a, 0x08, 0x93, 0xa5, 0x62, 0x30, 0x21, 0x08, 0x98, 0x03, 0xf0, + 0x23, 0xfc, 0x03, 0x22, 0x09, 0x9b, 0xe0, 0x62, 0x1a, 0x40, 0x05, 0xd0, + 0x04, 0x23, 0x9b, 0x1a, 0x09, 0x9a, 0xf6, 0x1a, 0xd2, 0x18, 0x09, 0x92, + 0x03, 0x23, 0x1e, 0x42, 0x00, 0xd0, 0x9e, 0x43, 0x80, 0x22, 0x09, 0x9b, + 0x92, 0x01, 0x63, 0x64, 0x33, 0x00, 0x96, 0x42, 0x00, 0xd9, 0x13, 0x00, + 0xa3, 0x64, 0x20, 0x00, 0xfe, 0xf7, 0x08, 0xfb, 0x07, 0x4b, 0x20, 0x00, + 0xe3, 0x65, 0x00, 0xf0, 0x83, 0xfd, 0x00, 0x28, 0x01, 0xda, 0x20, 0x63, + 0xfe, 0xbd, 0x0b, 0x9b, 0x00, 0x20, 0xe3, 0x64, 0x01, 0x23, 0x54, 0x34, + 0x23, 0x70, 0xf7, 0xe7, 0x15, 0x03, 0x09, 0x20, 0xf8, 0xb5, 0xc2, 0x6d, + 0x10, 0x4b, 0x04, 0x00, 0x9a, 0x42, 0x0c, 0xd1, 0x07, 0x00, 0x54, 0x37, + 0x3b, 0x78, 0x00, 0x2b, 0x07, 0xd0, 0x00, 0x26, 0x83, 0x6a, 0x1d, 0x1d, + 0xe3, 0x6a, 0xb3, 0x42, 0x02, 0xd8, 0x00, 0x23, 0x3b, 0x70, 0xf8, 0xbd, + 0x00, 0x23, 0xe9, 0x5e, 0x00, 0x29, 0x07, 0xd0, 0x20, 0x00, 0xff, 0xf7, + 0x5b, 0xff, 0x00, 0x23, 0xe9, 0x5e, 0x20, 0x00, 0x02, 0xf0, 0x98, 0xfb, + 0x01, 0x36, 0x30, 0x35, 0xea, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, + 0x00, 0x6b, 0x70, 0x47, 0x00, 0x23, 0x03, 0x63, 0x70, 0x47, 0x00, 0x00, + 0xf0, 0xb5, 0x87, 0xb0, 0x17, 0x00, 0x03, 0x93, 0xc2, 0x6d, 0x3f, 0x4b, + 0x05, 0x00, 0x0e, 0x00, 0x9a, 0x42, 0x04, 0xd0, 0x3d, 0x4c, 0x2c, 0x63, + 0x20, 0x00, 0x07, 0xb0, 0xf0, 0xbd, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, + 0x00, 0x2b, 0x01, 0xd1, 0x39, 0x4c, 0xf4, 0xe7, 0x08, 0x00, 0x03, 0xf0, + 0x7c, 0xfc, 0x1f, 0x28, 0x01, 0xd9, 0x37, 0x4c, 0xed, 0xe7, 0x32, 0x00, + 0x05, 0xa9, 0x28, 0x00, 0x02, 0xf0, 0xf8, 0xfa, 0x00, 0x28, 0x02, 0xda, + 0x28, 0x63, 0x04, 0xb2, 0xe4, 0xe7, 0x04, 0xaa, 0x31, 0x00, 0x28, 0x00, + 0x01, 0xf0, 0xb2, 0xfe, 0x04, 0x00, 0x7b, 0x07, 0x34, 0xd4, 0x00, 0x28, + 0x24, 0xda, 0x05, 0x9b, 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, + 0x55, 0xfb, 0x2c, 0x63, 0x24, 0xb2, 0xd1, 0xe7, 0x00, 0x2c, 0xf4, 0xdb, + 0x02, 0xab, 0x19, 0x89, 0x03, 0x9b, 0x05, 0x9a, 0x00, 0x93, 0x28, 0x00, + 0x3b, 0x00, 0x01, 0xf0, 0x27, 0xf9, 0x04, 0x1e, 0xe9, 0xdb, 0xbb, 0x07, + 0x06, 0xd5, 0x00, 0x22, 0x05, 0x98, 0x11, 0x00, 0x01, 0xf0, 0xbe, 0xfe, + 0x04, 0x1e, 0xe0, 0xdb, 0x00, 0x22, 0x05, 0x9b, 0x9a, 0x61, 0x04, 0x24, + 0x1c, 0x5f, 0xb5, 0xe7, 0x00, 0x28, 0xe3, 0xd1, 0x44, 0x23, 0x3b, 0x40, + 0x44, 0x2b, 0xdf, 0xd1, 0x05, 0x9b, 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, + 0x02, 0xf0, 0x2a, 0xfb, 0x14, 0x4c, 0xa6, 0xe7, 0x00, 0x28, 0xf1, 0xd0, + 0x13, 0x4b, 0x9c, 0x42, 0xd0, 0xd1, 0x0a, 0x23, 0x02, 0xa9, 0x5b, 0x18, + 0x00, 0x22, 0x19, 0x00, 0x28, 0x00, 0x02, 0xf0, 0xfb, 0xf9, 0x04, 0x1e, + 0xbd, 0xdb, 0x02, 0xab, 0x59, 0x89, 0x04, 0xab, 0x01, 0x93, 0x01, 0x23, + 0x32, 0x00, 0x00, 0x93, 0x28, 0x00, 0x00, 0x23, 0x00, 0xf0, 0xf2, 0xff, + 0x04, 0x1e, 0xb0, 0xdb, 0x02, 0x23, 0x9f, 0x43, 0xb8, 0xe7, 0xc0, 0x46, + 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, 0xf0, 0xd8, 0xff, 0xff, + 0xcc, 0xd8, 0xff, 0xff, 0xd2, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xf7, 0xb5, 0x16, 0x00, 0x1c, 0x00, 0xc2, 0x6d, 0x29, 0x4b, 0x05, 0x00, + 0x0f, 0x00, 0x9a, 0x42, 0x03, 0xd0, 0x28, 0x4c, 0x2c, 0x63, 0x20, 0x00, + 0xfe, 0xbd, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, + 0x24, 0x4c, 0xf5, 0xe7, 0x01, 0xaa, 0x02, 0xf0, 0x01, 0xfb, 0x00, 0x28, + 0x05, 0xda, 0x04, 0x00, 0x28, 0x63, 0x21, 0x4b, 0x9c, 0x42, 0x0d, 0xd0, + 0xeb, 0xe7, 0x01, 0x9b, 0x9a, 0x8b, 0x12, 0x07, 0x01, 0xd4, 0x1e, 0x4c, + 0xe4, 0xe7, 0x9b, 0x68, 0x01, 0x33, 0x05, 0xd1, 0x00, 0x2c, 0x03, 0xdd, + 0x19, 0x4b, 0x2b, 0x63, 0x00, 0x24, 0xdc, 0xe7, 0x39, 0x00, 0x28, 0x00, + 0xff, 0xf7, 0x88, 0xfe, 0x01, 0x98, 0x81, 0x69, 0x83, 0x68, 0x0a, 0x19, + 0x9a, 0x42, 0x14, 0xd3, 0x5c, 0x1a, 0x00, 0x2c, 0xee, 0xdd, 0x33, 0x00, + 0x22, 0x00, 0x02, 0xf0, 0xa5, 0xf8, 0x0f, 0x4b, 0x98, 0x42, 0x06, 0xd1, + 0x20, 0x00, 0x01, 0x9a, 0x93, 0x69, 0x1b, 0x19, 0x93, 0x61, 0x04, 0x00, + 0xc1, 0xe7, 0x00, 0x28, 0x07, 0xda, 0x28, 0x63, 0xf9, 0xe7, 0x33, 0x00, + 0x22, 0x00, 0x02, 0xf0, 0x93, 0xf8, 0x00, 0x28, 0xc5, 0xdb, 0x01, 0x9a, + 0x93, 0x69, 0x1b, 0x19, 0x93, 0x61, 0xc2, 0xe7, 0x15, 0x03, 0x09, 0x20, + 0xd8, 0xd8, 0xff, 0xff, 0xf0, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xda, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x15, 0x00, 0x1e, 0x00, 0xc2, 0x6d, + 0x2d, 0x4b, 0x85, 0xb0, 0x04, 0x00, 0x0f, 0x00, 0x9a, 0x42, 0x03, 0xd0, + 0x2b, 0x48, 0x20, 0x63, 0x05, 0xb0, 0xf0, 0xbd, 0x03, 0x00, 0x54, 0x33, + 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x28, 0x48, 0xf5, 0xe7, 0x03, 0xaa, + 0x02, 0xf0, 0x9e, 0xfa, 0x00, 0x28, 0xf0, 0xdb, 0x39, 0x00, 0x20, 0x00, + 0xff, 0xf7, 0x3a, 0xfe, 0x03, 0x9f, 0xbb, 0x68, 0x5a, 0x1c, 0x00, 0xd1, + 0x00, 0x23, 0x01, 0x2e, 0x05, 0xd0, 0x02, 0x2e, 0x06, 0xd0, 0x00, 0x2d, + 0x06, 0xda, 0x1e, 0x48, 0xdf, 0xe7, 0xba, 0x69, 0xad, 0x18, 0xf8, 0xe7, + 0xed, 0x18, 0xf6, 0xe7, 0x9d, 0x42, 0x02, 0xdd, 0xbb, 0x61, 0x1a, 0x48, + 0xd5, 0xe7, 0x00, 0x26, 0xb5, 0x42, 0x0d, 0xdd, 0x68, 0x1e, 0xfb, 0x21, + 0x03, 0xf0, 0x9c, 0xfa, 0x83, 0xb2, 0x68, 0x2b, 0x06, 0xd9, 0x18, 0x00, + 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0x94, 0xfa, 0x01, 0x30, 0x86, 0xb2, + 0x3b, 0x8a, 0xb3, 0x42, 0x11, 0xd0, 0xf9, 0x88, 0x80, 0x23, 0x0a, 0x27, + 0x1b, 0x02, 0x6f, 0x44, 0x19, 0x43, 0x00, 0x97, 0x00, 0x23, 0x32, 0x00, + 0x20, 0x00, 0x00, 0xf0, 0xdd, 0xfc, 0x00, 0x28, 0xb3, 0xdb, 0x03, 0x9b, + 0x3a, 0x88, 0x1e, 0x82, 0xda, 0x81, 0x03, 0x9b, 0x28, 0x00, 0x9d, 0x61, + 0xac, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xc8, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x2a, 0x4b, 0xc2, 0x6d, 0x85, 0xb0, 0x05, 0x00, 0x0f, 0x00, + 0x9a, 0x42, 0x02, 0xd0, 0x27, 0x4c, 0x2c, 0x63, 0x3e, 0xe0, 0x03, 0x00, + 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x24, 0x4c, 0xf6, 0xe7, + 0x08, 0x00, 0x03, 0xf0, 0x24, 0xfb, 0x1f, 0x28, 0x01, 0xd9, 0x22, 0x4c, + 0xef, 0xe7, 0x00, 0x22, 0x03, 0xa9, 0x28, 0x00, 0x02, 0xf0, 0xa0, 0xf9, + 0x04, 0x1e, 0xe8, 0xdb, 0x0a, 0x26, 0x6e, 0x44, 0x32, 0x00, 0x39, 0x00, + 0x28, 0x00, 0x01, 0xf0, 0x5b, 0xfd, 0x04, 0x1e, 0x07, 0xd0, 0x03, 0x9b, + 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0x01, 0xfa, 0x00, 0x2c, + 0xd7, 0xdb, 0x00, 0x23, 0x31, 0x88, 0x03, 0x9a, 0x00, 0x93, 0x28, 0x00, + 0x00, 0xf0, 0xd8, 0xff, 0x04, 0x1e, 0x07, 0xd0, 0x03, 0x9b, 0x28, 0x00, + 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0xf0, 0xf9, 0x00, 0x2c, 0xc6, 0xdb, + 0x01, 0x22, 0x00, 0x21, 0x03, 0x98, 0x01, 0xf0, 0x69, 0xfd, 0x04, 0x1e, + 0x03, 0xd1, 0x00, 0x24, 0x20, 0x00, 0x05, 0xb0, 0xf0, 0xbd, 0x03, 0x9b, + 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0xdd, 0xf9, 0x00, 0x2c, + 0xb3, 0xdb, 0xf2, 0xe7, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xcc, 0xd8, 0xff, 0xff, 0x0d, 0x4b, 0xc2, 0x6d, + 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x9a, 0x42, 0x02, 0xd0, 0x0b, 0x48, + 0x20, 0x63, 0x10, 0xe0, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, + 0x01, 0xd1, 0x08, 0x48, 0xf6, 0xe7, 0xff, 0xf7, 0x7d, 0xfd, 0x00, 0x28, + 0xf2, 0xdb, 0x29, 0x00, 0x20, 0x00, 0x02, 0xf0, 0xb9, 0xf9, 0x00, 0x28, + 0xec, 0xdb, 0x70, 0xbd, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0x0e, 0x4b, 0xc2, 0x6d, 0x10, 0xb5, 0x04, 0x00, + 0x9a, 0x42, 0x02, 0xd0, 0x0c, 0x48, 0x20, 0x63, 0x10, 0xbd, 0x03, 0x00, + 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x09, 0x48, 0xf6, 0xe7, + 0x00, 0x21, 0xfe, 0xf7, 0xe5, 0xfd, 0x20, 0x00, 0xff, 0xf7, 0x06, 0xf9, + 0x20, 0x00, 0xfe, 0xf7, 0x19, 0xfe, 0x20, 0x00, 0x00, 0xf0, 0x52, 0xfb, + 0xea, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x12, 0x01, 0x5c, 0x1c, 0x14, 0x19, + 0x05, 0x22, 0x85, 0xb0, 0xa4, 0xb2, 0x02, 0xad, 0x0f, 0x00, 0x00, 0x92, + 0x23, 0x02, 0x01, 0x95, 0x10, 0x32, 0x00, 0x21, 0x0a, 0x9e, 0xfd, 0xf7, + 0xde, 0xff, 0x00, 0x28, 0x1d, 0xdb, 0x2b, 0x88, 0xbb, 0x42, 0x1c, 0xd1, + 0x0b, 0x9a, 0x69, 0x88, 0x12, 0x88, 0x8a, 0x42, 0x17, 0xd1, 0x29, 0x79, + 0x7c, 0x20, 0x0d, 0x00, 0x85, 0x43, 0x80, 0x2d, 0x11, 0xd1, 0x1b, 0xb2, + 0x00, 0x2b, 0x03, 0xda, 0x4b, 0x06, 0x01, 0xd4, 0x00, 0x2a, 0x0a, 0xd0, + 0x30, 0x1e, 0x06, 0xd0, 0x30, 0x88, 0x00, 0x1b, 0x44, 0x42, 0x60, 0x41, + 0x03, 0x4c, 0x40, 0x42, 0x20, 0x40, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x48, + 0xfb, 0xe7, 0xc0, 0x46, 0xaa, 0xd8, 0xff, 0xff, 0x7f, 0xb5, 0x1d, 0x00, + 0x1b, 0x4b, 0x0c, 0x00, 0x9a, 0x42, 0x24, 0xd0, 0x13, 0x07, 0x25, 0xd0, + 0x80, 0x23, 0x9b, 0x01, 0x9a, 0x42, 0x23, 0xd8, 0x13, 0x02, 0x04, 0x21, + 0x62, 0x5e, 0x05, 0x21, 0x02, 0xae, 0x00, 0x91, 0x01, 0x96, 0x11, 0x31, + 0xfd, 0xf7, 0xa1, 0xff, 0x00, 0x28, 0x13, 0xdb, 0x33, 0x79, 0xda, 0x07, + 0x16, 0xd4, 0x5a, 0xb2, 0x00, 0x2a, 0x15, 0xda, 0x9a, 0x07, 0x15, 0xd4, + 0x5b, 0x07, 0x15, 0xd4, 0x06, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x11, 0xda, + 0x73, 0x88, 0xab, 0x42, 0x02, 0xd0, 0x09, 0x48, 0x00, 0xe0, 0x09, 0x48, + 0x04, 0xb0, 0x70, 0xbd, 0x08, 0x48, 0xfb, 0xe7, 0x08, 0x48, 0xf9, 0xe7, + 0x08, 0x48, 0xf7, 0xe7, 0x08, 0x48, 0xf5, 0xe7, 0x08, 0x48, 0xf3, 0xe7, + 0x08, 0x48, 0xf1, 0xe7, 0xff, 0xff, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, + 0xde, 0xd8, 0xff, 0xff, 0xdd, 0xd8, 0xff, 0xff, 0xdc, 0xd8, 0xff, 0xff, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0x12, 0x01, 0x30, 0xb5, 0x01, 0x33, 0xd3, 0x18, + 0x13, 0x4a, 0x8f, 0xb0, 0x89, 0x18, 0x13, 0x4a, 0x89, 0xb2, 0x9b, 0xb2, + 0x91, 0x42, 0x1b, 0xd8, 0x2e, 0x22, 0x02, 0xac, 0x00, 0x92, 0x1b, 0x02, + 0x01, 0x94, 0x00, 0x22, 0x15, 0x21, 0xfd, 0xf7, 0x56, 0xff, 0x00, 0x28, + 0x11, 0xdb, 0x65, 0x88, 0x00, 0x2d, 0x0d, 0xd1, 0x3d, 0x22, 0x23, 0x79, + 0x93, 0x43, 0xc0, 0x2b, 0x08, 0xd1, 0x15, 0x21, 0x12, 0x98, 0x69, 0x44, + 0x03, 0xf0, 0xe3, 0xf9, 0x03, 0x00, 0x28, 0x00, 0x00, 0x2b, 0x00, 0xd0, + 0x03, 0x48, 0x0f, 0xb0, 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, + 0xfe, 0x7f, 0x00, 0x00, 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x05, 0x00, + 0x0c, 0x00, 0x21, 0x48, 0x01, 0x39, 0x89, 0xb2, 0x8f, 0xb0, 0x81, 0x42, + 0x01, 0xd9, 0x1f, 0x48, 0x27, 0xe0, 0x15, 0x99, 0x0e, 0x88, 0x14, 0x99, + 0x00, 0x29, 0x24, 0xd0, 0x21, 0xb2, 0x00, 0x29, 0x21, 0xda, 0x12, 0x01, + 0x01, 0x33, 0xd3, 0x18, 0x2e, 0x22, 0x9b, 0xb2, 0x02, 0xaf, 0x00, 0x92, + 0x1b, 0x02, 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xfd, 0xf7, + 0x18, 0xff, 0x00, 0x28, 0x0f, 0xdb, 0x7b, 0x88, 0x00, 0x2b, 0x0e, 0xd1, + 0x3d, 0x22, 0x3b, 0x79, 0x93, 0x43, 0xc0, 0x2b, 0x09, 0xd1, 0x15, 0x21, + 0x14, 0x98, 0x69, 0x44, 0x03, 0xf0, 0xa5, 0xf9, 0x00, 0x28, 0x02, 0xd1, + 0x0b, 0x48, 0x0f, 0xb0, 0xf0, 0xbd, 0x64, 0x04, 0x64, 0x0c, 0xa4, 0x1b, + 0xe3, 0x10, 0xff, 0x2b, 0xcd, 0xd8, 0x6a, 0x6a, 0xd2, 0x18, 0x07, 0x23, + 0x1c, 0x40, 0x06, 0x3b, 0xa3, 0x40, 0x11, 0x78, 0x0b, 0x43, 0x13, 0x70, + 0xc3, 0xe7, 0xc0, 0x46, 0xfd, 0xff, 0x00, 0x00, 0xaa, 0xd8, 0xff, 0xff, + 0xd9, 0xd8, 0xff, 0xff, 0x09, 0x4a, 0x91, 0x42, 0x06, 0xd1, 0x00, 0x2b, + 0x02, 0xd1, 0x43, 0x6b, 0x01, 0x33, 0x43, 0x63, 0x06, 0x48, 0x70, 0x47, + 0x00, 0x29, 0x03, 0xd1, 0xc3, 0x6b, 0x01, 0x33, 0xc3, 0x63, 0xf7, 0xe7, + 0x83, 0x6b, 0x01, 0x33, 0x83, 0x63, 0xf3, 0xe7, 0xff, 0xff, 0x00, 0x00, + 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x85, 0xb0, 0x01, 0x91, 0x02, 0x92, + 0x07, 0x89, 0x06, 0x00, 0x00, 0x25, 0x68, 0x2f, 0x06, 0xd9, 0x38, 0x00, + 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0xa2, 0xf8, 0x01, 0x30, 0x85, 0xb2, + 0x74, 0x89, 0x00, 0x20, 0x68, 0x2c, 0x06, 0xd9, 0x20, 0x00, 0x7c, 0x21, + 0x69, 0x38, 0x03, 0xf0, 0x97, 0xf8, 0x01, 0x30, 0x80, 0xb2, 0x01, 0x9b, + 0x9d, 0x42, 0x1c, 0xd8, 0x83, 0x42, 0x1a, 0xd8, 0x00, 0x2b, 0x1a, 0xd0, + 0x7c, 0x23, 0x01, 0x9a, 0x5a, 0x43, 0x13, 0x3a, 0x92, 0xb2, 0x9b, 0x18, + 0x01, 0x34, 0x9b, 0xb2, 0xa3, 0x42, 0x00, 0xdd, 0x23, 0x00, 0x9b, 0xb2, + 0x03, 0x93, 0x3c, 0x1c, 0x97, 0x42, 0x00, 0xd2, 0x14, 0x1c, 0xa4, 0xb2, + 0x25, 0x1d, 0x14, 0x4f, 0x6d, 0x00, 0x03, 0x9a, 0xa3, 0xb2, 0x9a, 0x42, + 0x04, 0xd8, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x9a, 0x69, 0x23, 0xe6, 0xe7, + 0x01, 0x9a, 0x00, 0x2a, 0x0c, 0xd1, 0x02, 0x9b, 0x5b, 0x19, 0xda, 0x8c, + 0x02, 0x35, 0xba, 0x42, 0xf1, 0xd0, 0x33, 0x89, 0x31, 0x68, 0xe3, 0x1a, + 0x5b, 0x00, 0x5a, 0x52, 0x01, 0x34, 0xe6, 0xe7, 0x29, 0x00, 0x68, 0x2b, + 0x06, 0xd9, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0xde, 0xf8, + 0x04, 0x31, 0x49, 0x00, 0x02, 0x9b, 0x5a, 0x5a, 0xe8, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0x01, 0x00, 0x10, 0xb5, 0x21, 0x24, 0x03, 0x00, + 0x05, 0x48, 0x20, 0x31, 0x1a, 0x78, 0x00, 0x2a, 0x02, 0xd0, 0x01, 0x33, + 0x8b, 0x42, 0x00, 0xd1, 0x10, 0xbd, 0x60, 0x43, 0x50, 0x40, 0xf5, 0xe7, + 0x05, 0x15, 0x00, 0x00, 0x30, 0xb5, 0x1c, 0x00, 0x19, 0x4b, 0x85, 0xb0, + 0x9a, 0x42, 0x20, 0xd0, 0x13, 0x07, 0x21, 0xd0, 0x80, 0x23, 0x9b, 0x01, + 0x9a, 0x42, 0x1f, 0xd8, 0x13, 0x02, 0x00, 0x22, 0x8a, 0x5e, 0x05, 0x21, + 0x02, 0xad, 0x00, 0x91, 0x01, 0x95, 0x12, 0x31, 0xfd, 0xf7, 0x4d, 0xfe, + 0x00, 0x28, 0x0f, 0xdb, 0x2b, 0x79, 0xda, 0x07, 0x12, 0xd4, 0x5a, 0xb2, + 0x00, 0x2a, 0x11, 0xda, 0x9a, 0x07, 0x11, 0xd4, 0x5b, 0x07, 0x11, 0xd5, + 0x6b, 0x88, 0xa3, 0x42, 0x02, 0xd0, 0x09, 0x48, 0x00, 0xe0, 0x09, 0x48, + 0x05, 0xb0, 0x30, 0xbd, 0x08, 0x48, 0xfb, 0xe7, 0x08, 0x48, 0xf9, 0xe7, + 0x08, 0x48, 0xf7, 0xe7, 0x08, 0x48, 0xf5, 0xe7, 0x08, 0x48, 0xf3, 0xe7, + 0x08, 0x48, 0xf1, 0xe7, 0xff, 0xff, 0x00, 0x00, 0xe2, 0xd8, 0xff, 0xff, + 0xe1, 0xd8, 0xff, 0xff, 0xe0, 0xd8, 0xff, 0xff, 0xdf, 0xd8, 0xff, 0xff, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xe5, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0c, 0x00, 0x1f, 0x49, 0x06, 0x00, + 0x61, 0x18, 0x1f, 0x48, 0x8f, 0xb0, 0x89, 0xb2, 0x14, 0x9d, 0x81, 0x42, + 0x33, 0xd8, 0x01, 0x33, 0x12, 0x03, 0x1b, 0x02, 0x9b, 0x18, 0x2e, 0x22, + 0x02, 0xaf, 0x00, 0x92, 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x30, 0x00, + 0xfd, 0xf7, 0x03, 0xfe, 0x00, 0x28, 0x24, 0xd1, 0x7b, 0x88, 0x00, 0x2b, + 0x21, 0xd1, 0x79, 0x22, 0x3b, 0x79, 0x93, 0x43, 0x80, 0x2b, 0x1c, 0xd1, + 0xa8, 0x68, 0x00, 0x28, 0x08, 0xd0, 0x15, 0x21, 0x69, 0x44, 0x03, 0xf0, + 0x8e, 0xf8, 0x00, 0x28, 0x02, 0xd1, 0x0d, 0x48, 0x0f, 0xb0, 0xf0, 0xbd, + 0x28, 0x88, 0x61, 0x04, 0x49, 0x0c, 0x81, 0x42, 0x0b, 0xd3, 0x6b, 0x88, + 0x8b, 0x42, 0x08, 0xd3, 0x08, 0x1a, 0x69, 0x68, 0x02, 0xf0, 0xbc, 0xff, + 0x73, 0x6a, 0x18, 0x18, 0x03, 0x78, 0x01, 0x33, 0x03, 0x70, 0x04, 0x48, + 0xea, 0xe7, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, 0xfe, 0x7f, 0x00, 0x00, + 0xd9, 0xd8, 0xff, 0xff, 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x15, 0x00, + 0x1e, 0x00, 0x95, 0xb0, 0x1a, 0x9f, 0x02, 0x90, 0x03, 0x91, 0x00, 0x2f, + 0x02, 0xd1, 0x38, 0x00, 0x15, 0xb0, 0xf0, 0xbd, 0x3c, 0x00, 0x40, 0x2f, + 0x00, 0xd9, 0x40, 0x24, 0x04, 0xab, 0x01, 0x93, 0x00, 0x94, 0x33, 0x00, + 0x03, 0x9a, 0x0b, 0x21, 0x02, 0x98, 0xfd, 0xf7, 0xb8, 0xfd, 0x00, 0x28, + 0xee, 0xdb, 0x04, 0xab, 0x01, 0x93, 0x00, 0x94, 0x2b, 0x00, 0x03, 0x9a, + 0x0f, 0x21, 0x02, 0x98, 0xfd, 0xf7, 0x11, 0xfe, 0x00, 0x28, 0xe3, 0xdb, + 0x3f, 0x1b, 0x36, 0x19, 0x2d, 0x19, 0xdc, 0xe7, 0xf0, 0xb5, 0x14, 0x00, + 0x0f, 0x22, 0x8d, 0xb0, 0x06, 0x93, 0x12, 0xab, 0x1b, 0x88, 0x06, 0x00, + 0x0b, 0x93, 0xc3, 0x68, 0x0f, 0x00, 0x5a, 0x43, 0x07, 0x92, 0x02, 0x6a, + 0x09, 0x92, 0x0e, 0x2c, 0x00, 0xdc, 0xa4, 0xe0, 0x01, 0x37, 0xbf, 0xb2, + 0xbb, 0x42, 0x51, 0xd9, 0x00, 0x24, 0x3b, 0x03, 0x03, 0x93, 0x07, 0x9b, + 0x00, 0x2b, 0x4f, 0xdd, 0x7f, 0x22, 0xe3, 0x17, 0x13, 0x40, 0x1b, 0x19, + 0xdb, 0x11, 0xda, 0x01, 0x05, 0x92, 0x09, 0x9a, 0x1b, 0x02, 0xd3, 0x1a, + 0x04, 0x93, 0x03, 0x9a, 0x09, 0x9b, 0x14, 0x21, 0x9b, 0x18, 0x04, 0x9a, + 0x30, 0x00, 0x9b, 0x1a, 0x0a, 0x93, 0x33, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x0a, 0x9b, 0xfd, 0xf7, 0x6f, 0xfd, + 0x25, 0x00, 0x07, 0x9b, 0x02, 0x90, 0x08, 0x93, 0x08, 0x9b, 0x2c, 0x00, + 0x07, 0x93, 0x02, 0x9b, 0x00, 0x2b, 0x05, 0xd1, 0x05, 0x9b, 0xeb, 0x1a, + 0x7f, 0x2b, 0x01, 0xdc, 0x0e, 0x2d, 0x28, 0xdd, 0x05, 0x9b, 0x80, 0x33, + 0x05, 0x93, 0x04, 0x9b, 0x01, 0x3b, 0xff, 0x3b, 0x04, 0x93, 0x02, 0x9b, + 0x00, 0x2b, 0x02, 0xd1, 0x05, 0x9b, 0x80, 0x2b, 0xd1, 0xd1, 0x01, 0x37, + 0xf3, 0x68, 0xbf, 0xb2, 0x9f, 0x42, 0x55, 0xd2, 0x80, 0x22, 0x52, 0x01, + 0x94, 0x46, 0x03, 0x9b, 0x63, 0x44, 0x03, 0x93, 0x00, 0x24, 0x02, 0x9b, + 0xa3, 0x42, 0xb4, 0xd0, 0x02, 0x9b, 0x00, 0x2b, 0x06, 0xdb, 0x03, 0xe0, + 0x04, 0x24, 0x06, 0x9b, 0x1c, 0x40, 0x4d, 0xd0, 0x29, 0x4b, 0x02, 0x93, + 0x02, 0x98, 0x0d, 0xb0, 0xf0, 0xbd, 0x01, 0x22, 0x06, 0x9b, 0x13, 0x42, + 0x05, 0xd0, 0x04, 0x9a, 0x6b, 0x00, 0xd3, 0x5a, 0x0b, 0x9a, 0x93, 0x42, + 0x2f, 0xd1, 0x16, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x1f, 0x80, 0x17, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x1d, 0x60, 0x13, 0x9b, 0x00, 0x2b, 0xe7, 0xd0, + 0x02, 0x22, 0x06, 0x9b, 0x0b, 0x99, 0x13, 0x42, 0x02, 0xd1, 0x04, 0x9a, + 0x6b, 0x00, 0xd1, 0x5a, 0x15, 0x9b, 0x3a, 0x00, 0x01, 0x93, 0x14, 0x9b, + 0x30, 0x00, 0x00, 0x93, 0x13, 0x9c, 0x2b, 0x00, 0xa0, 0x47, 0x15, 0x4b, + 0xc3, 0x18, 0x01, 0x2b, 0x21, 0xd8, 0x14, 0x4b, 0x98, 0x42, 0x0c, 0xd1, + 0x33, 0x6a, 0x00, 0x22, 0x01, 0x93, 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, + 0x14, 0x21, 0x0a, 0x9b, 0x30, 0x00, 0xfd, 0xf7, 0xfe, 0xfc, 0x00, 0x28, + 0x11, 0xdb, 0x08, 0x9b, 0x01, 0x35, 0x01, 0x3b, 0x08, 0x93, 0x8b, 0xe7, + 0x04, 0x23, 0x06, 0x9a, 0x13, 0x40, 0xb7, 0xd1, 0x03, 0x93, 0x1f, 0x00, + 0xa8, 0xe7, 0x0b, 0x03, 0x03, 0x93, 0x5e, 0xe7, 0x03, 0x94, 0x27, 0x00, + 0x5b, 0xe7, 0x02, 0x90, 0xae, 0xe7, 0xc0, 0x46, 0xa8, 0xd8, 0xff, 0xff, + 0x57, 0x27, 0x00, 0x00, 0xa9, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x04, 0x00, + 0x0d, 0x03, 0x0f, 0x00, 0x80, 0x21, 0x85, 0xb0, 0x49, 0x01, 0xa3, 0x68, + 0x28, 0x00, 0x98, 0x47, 0x63, 0x6b, 0x22, 0x00, 0x01, 0x33, 0x63, 0x63, + 0x02, 0x26, 0x2b, 0x00, 0x42, 0x32, 0x01, 0x92, 0xfe, 0x33, 0x00, 0x96, + 0x00, 0x22, 0x19, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x2c, 0xfd, 0x00, 0x28, + 0x1a, 0xdb, 0xe3, 0x68, 0x0e, 0x22, 0xdb, 0x1b, 0x0d, 0x4f, 0x6a, 0x44, + 0x5f, 0x40, 0x2b, 0x00, 0x17, 0x80, 0xfc, 0x33, 0x01, 0x92, 0x00, 0x96, + 0x00, 0x22, 0x19, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x1a, 0xfd, 0x00, 0x28, + 0x08, 0xdb, 0x80, 0x22, 0x04, 0x34, 0xe3, 0x8f, 0x12, 0x02, 0x01, 0x33, + 0x9b, 0xb2, 0x93, 0x42, 0x02, 0xd0, 0xe3, 0x87, 0x05, 0xb0, 0xf0, 0xbd, + 0x00, 0x23, 0xfa, 0xe7, 0x29, 0x04, 0x00, 0x00, 0xf0, 0xb5, 0x00, 0x27, + 0x04, 0x00, 0x8b, 0xb0, 0x3b, 0x4d, 0x08, 0xab, 0x1f, 0x80, 0x07, 0x95, + 0x08, 0xae, 0x33, 0x88, 0xe2, 0x68, 0x93, 0x42, 0x24, 0xd3, 0x38, 0x4a, + 0x7b, 0x1b, 0x01, 0x35, 0x93, 0x42, 0x00, 0xdc, 0x7d, 0x1c, 0x23, 0x1d, + 0xad, 0xb2, 0xdd, 0x87, 0x07, 0x9b, 0x1a, 0x00, 0x31, 0x4b, 0x9a, 0x42, + 0x58, 0xd1, 0x00, 0x25, 0x09, 0xab, 0x05, 0x93, 0x30, 0x4b, 0x65, 0x63, + 0x01, 0x93, 0xa5, 0x63, 0x2b, 0x00, 0xe5, 0x63, 0x04, 0x96, 0x03, 0x95, + 0x02, 0x95, 0x00, 0x95, 0x2a, 0x00, 0x29, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0xd1, 0xfe, 0x2a, 0x4b, 0x98, 0x42, 0x41, 0xd1, 0x28, 0x00, 0x3f, 0xe0, + 0x1a, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, 0x1b, 0x03, + 0x00, 0x92, 0xfc, 0x33, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, 0xfd, 0xf7, + 0x66, 0xfc, 0x00, 0x28, 0x30, 0xdb, 0xe2, 0x68, 0x33, 0x88, 0xd1, 0x1a, + 0x1f, 0x4a, 0x4a, 0x40, 0x02, 0xa9, 0x49, 0x8b, 0x92, 0xb2, 0x91, 0x42, + 0x05, 0xd0, 0x07, 0x9a, 0x11, 0x00, 0x17, 0x4a, 0x91, 0x42, 0x20, 0xd1, + 0x07, 0x93, 0x02, 0x22, 0x1b, 0x03, 0x09, 0xae, 0x00, 0x92, 0xfe, 0x33, + 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x49, 0xfc, + 0x00, 0x28, 0x13, 0xdb, 0x33, 0x88, 0x0e, 0x4a, 0x93, 0x42, 0x09, 0xd0, + 0x1a, 0x1c, 0xab, 0x42, 0x00, 0xd9, 0x2a, 0x1c, 0x95, 0xb2, 0x1a, 0x1c, + 0xbb, 0x42, 0x00, 0xd2, 0x3a, 0x1c, 0x97, 0xb2, 0x08, 0xaa, 0x13, 0x88, + 0x01, 0x33, 0x13, 0x80, 0x96, 0xe7, 0x0a, 0x48, 0x0b, 0xb0, 0xf0, 0xbd, + 0x07, 0x99, 0x20, 0x00, 0xff, 0xf7, 0x4c, 0xff, 0x00, 0x28, 0xa0, 0xda, + 0xf6, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0xff, 0x7f, 0x00, 0x00, + 0xc9, 0x49, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, 0x29, 0x04, 0x00, 0x00, + 0xd7, 0xd8, 0xff, 0xff, 0x10, 0xb5, 0x86, 0xb0, 0x09, 0x9c, 0x00, 0x93, + 0x05, 0x94, 0x08, 0x9c, 0x01, 0x23, 0x04, 0x94, 0x00, 0x24, 0x03, 0x94, + 0x02, 0x94, 0x01, 0x94, 0xff, 0xf7, 0x68, 0xfe, 0x02, 0x4b, 0x98, 0x42, + 0x00, 0xd1, 0x02, 0x48, 0x06, 0xb0, 0x10, 0xbd, 0xa8, 0xd8, 0xff, 0xff, + 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x1e, 0x00, 0x03, 0x00, 0x85, 0xb0, + 0x03, 0x92, 0x40, 0x33, 0x0f, 0x00, 0x19, 0x78, 0x04, 0x00, 0x0a, 0x9d, + 0x00, 0x29, 0x0b, 0xd0, 0x01, 0x95, 0x00, 0x96, 0x12, 0x4b, 0x03, 0x9a, + 0x39, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xd4, 0xff, 0x00, 0x28, 0x10, 0xd0, + 0x05, 0xb0, 0xf0, 0xbd, 0x43, 0x6b, 0x01, 0x2b, 0xf0, 0xd8, 0xfe, 0xf7, + 0x49, 0xfd, 0x0c, 0x4b, 0x98, 0x42, 0x01, 0xd0, 0x00, 0x28, 0xf3, 0xdb, + 0x63, 0x6b, 0x01, 0x2b, 0xe6, 0xd8, 0x09, 0x48, 0xee, 0xe7, 0x33, 0x88, + 0x23, 0x82, 0x2b, 0x68, 0x01, 0x33, 0x63, 0x61, 0x2b, 0x68, 0x00, 0x2b, + 0xe6, 0xd1, 0x63, 0x6b, 0x01, 0x3b, 0x63, 0x63, 0xe2, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xd3, 0xd8, 0xff, 0xff, 0xef, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x1e, 0x27, 0x8b, 0xb0, 0x6f, 0x44, 0x07, 0xae, 0x3a, 0x80, + 0x33, 0x80, 0x04, 0x00, 0x0d, 0x00, 0xc2, 0x69, 0x01, 0x8b, 0x00, 0x20, + 0x83, 0x42, 0x00, 0xd0, 0x30, 0x00, 0x22, 0x26, 0x09, 0xab, 0x05, 0x93, + 0x0f, 0x4b, 0x6e, 0x44, 0x02, 0x90, 0x01, 0x93, 0x04, 0x96, 0x01, 0x23, + 0x03, 0x97, 0x00, 0x95, 0x20, 0x00, 0xff, 0xf7, 0x07, 0xfe, 0x0b, 0x4b, + 0x98, 0x42, 0x0f, 0xd0, 0x00, 0x28, 0x0b, 0xdb, 0x10, 0x9b, 0x31, 0x88, + 0x09, 0x9a, 0x00, 0x2b, 0x04, 0xd0, 0x0b, 0x01, 0x9b, 0x18, 0x10, 0x9d, + 0x01, 0x33, 0x2b, 0x80, 0x21, 0x83, 0xe2, 0x61, 0x0b, 0xb0, 0xf0, 0xbd, + 0x02, 0x48, 0xfb, 0xe7, 0xc5, 0x47, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x1e, 0x27, 0x8b, 0xb0, 0x6f, 0x44, + 0x07, 0xae, 0x3a, 0x80, 0x33, 0x80, 0x04, 0x00, 0x0d, 0x00, 0xc2, 0x69, + 0x01, 0x8b, 0x00, 0x20, 0x83, 0x42, 0x00, 0xd0, 0x30, 0x00, 0x22, 0x26, + 0x09, 0xab, 0x05, 0x93, 0x0f, 0x4b, 0x6e, 0x44, 0x02, 0x90, 0x01, 0x93, + 0x04, 0x96, 0x02, 0x23, 0x03, 0x97, 0x00, 0x95, 0x20, 0x00, 0xff, 0xf7, + 0xcf, 0xfd, 0x0b, 0x4b, 0x98, 0x42, 0x0f, 0xd0, 0x00, 0x28, 0x0b, 0xdb, + 0x10, 0x9b, 0x31, 0x88, 0x09, 0x9a, 0x00, 0x2b, 0x04, 0xd0, 0x0b, 0x01, + 0x9b, 0x18, 0x10, 0x9d, 0x01, 0x33, 0x2b, 0x80, 0x21, 0x83, 0xe2, 0x61, + 0x0b, 0xb0, 0xf0, 0xbd, 0x02, 0x48, 0xfb, 0xe7, 0xc5, 0x47, 0x00, 0x00, + 0xa8, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0e, 0x27, + 0x12, 0x26, 0x89, 0xb0, 0x03, 0x93, 0x10, 0xab, 0x1b, 0x78, 0x15, 0x00, + 0x04, 0x93, 0x02, 0xab, 0xff, 0x18, 0x39, 0x80, 0xf6, 0x18, 0x07, 0xab, + 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x33, 0x00, 0x04, 0x00, 0xff, 0xf7, + 0x41, 0xff, 0x00, 0x28, 0x67, 0xdb, 0x33, 0x88, 0x07, 0x9a, 0x1b, 0x03, + 0x52, 0x00, 0x9b, 0x18, 0x02, 0x22, 0x01, 0x97, 0x00, 0x92, 0x04, 0x21, + 0x00, 0x22, 0x20, 0x00, 0xfd, 0xf7, 0x9b, 0xfb, 0x00, 0x28, 0x58, 0xdb, + 0x01, 0x22, 0xa3, 0x6b, 0x07, 0x21, 0x01, 0x33, 0xa3, 0x63, 0x2b, 0x79, + 0x20, 0x00, 0x93, 0x43, 0x2b, 0x71, 0x07, 0x9b, 0x9b, 0x18, 0x32, 0x88, + 0x1b, 0x02, 0x12, 0x03, 0x9b, 0x18, 0x05, 0x22, 0x01, 0x95, 0x00, 0x92, + 0x00, 0x22, 0xfd, 0xf7, 0x84, 0xfb, 0x00, 0x28, 0x41, 0xdb, 0x03, 0x9b, + 0x00, 0x2b, 0x13, 0xd0, 0x07, 0x9b, 0x32, 0x88, 0x01, 0x33, 0x12, 0x03, + 0x1b, 0x02, 0x9b, 0x18, 0x0f, 0x9a, 0x05, 0x33, 0x9b, 0x18, 0x03, 0x9a, + 0x07, 0x21, 0x01, 0x92, 0x0e, 0x9a, 0x20, 0x00, 0x00, 0x92, 0x00, 0x22, + 0xfd, 0xf7, 0x6d, 0xfb, 0x00, 0x28, 0x2a, 0xdb, 0x04, 0x9b, 0x00, 0x2b, + 0x1a, 0xd0, 0x02, 0x22, 0x2b, 0x79, 0x13, 0x42, 0x16, 0xd0, 0x93, 0x43, + 0x02, 0xa9, 0x10, 0x32, 0x2b, 0x71, 0x52, 0x18, 0x07, 0x9b, 0x12, 0x88, + 0x01, 0x33, 0x12, 0x03, 0x1b, 0x02, 0x9b, 0x18, 0x01, 0x22, 0x04, 0x35, + 0x00, 0x92, 0x04, 0x33, 0x01, 0x95, 0x00, 0x22, 0x07, 0x21, 0x20, 0x00, + 0xfd, 0xf7, 0x4f, 0xfb, 0x00, 0x28, 0x0c, 0xdb, 0x11, 0x9b, 0x00, 0x2b, + 0x09, 0xd0, 0x12, 0x23, 0x02, 0xaa, 0x9b, 0x18, 0x1b, 0x88, 0x07, 0x9a, + 0x1b, 0x01, 0xd3, 0x18, 0x11, 0x9a, 0x01, 0x33, 0x13, 0x80, 0x09, 0xb0, + 0xf0, 0xbd, 0x00, 0x00, 0x7f, 0xb5, 0x0e, 0x22, 0x00, 0x26, 0x0f, 0x23, + 0x0c, 0x00, 0x6a, 0x44, 0x16, 0x80, 0x01, 0x92, 0x02, 0x22, 0x0b, 0x40, + 0x11, 0x49, 0x00, 0x92, 0x5b, 0x18, 0x21, 0x09, 0x09, 0x03, 0x5b, 0x00, + 0x5b, 0x18, 0x32, 0x00, 0x31, 0x00, 0x05, 0x00, 0xfd, 0xf7, 0x27, 0xfb, + 0xb0, 0x42, 0x13, 0xdb, 0xeb, 0x6b, 0x0d, 0x22, 0x01, 0x33, 0xeb, 0x63, + 0xab, 0x6b, 0x6a, 0x44, 0x01, 0x3b, 0xab, 0x63, 0x7e, 0x23, 0x13, 0x70, + 0x01, 0x92, 0x01, 0x22, 0x24, 0x02, 0x00, 0x92, 0x23, 0x1d, 0x32, 0x00, + 0x03, 0x21, 0x28, 0x00, 0xfd, 0xf7, 0x11, 0xfb, 0x04, 0xb0, 0x70, 0xbd, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x89, 0xb0, 0x15, 0x00, 0x0e, 0xaa, + 0x03, 0x91, 0x02, 0xca, 0x12, 0x24, 0x12, 0x88, 0x02, 0x91, 0x04, 0x92, + 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x13, 0x80, 0x07, 0xab, 0x64, 0x18, + 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x23, 0x00, 0x06, 0x00, 0x10, 0x9f, + 0xff, 0xf7, 0x8c, 0xfe, 0x00, 0x28, 0x5f, 0xdb, 0x24, 0x88, 0x07, 0x9b, + 0x24, 0x01, 0x1c, 0x19, 0x01, 0x34, 0xa4, 0xb2, 0x00, 0x2f, 0x00, 0xd0, + 0x3c, 0x80, 0x27, 0x02, 0x00, 0x2d, 0x1e, 0xd1, 0x80, 0x22, 0x04, 0x9b, + 0x52, 0x00, 0x1b, 0x02, 0x00, 0x92, 0x03, 0x99, 0x3a, 0x00, 0x30, 0x00, + 0xff, 0xf7, 0xa8, 0xfc, 0x00, 0x23, 0x02, 0x9d, 0x02, 0x93, 0x24, 0xe0, + 0x03, 0x22, 0x2b, 0x79, 0x04, 0x35, 0x93, 0x43, 0x2b, 0x70, 0x02, 0x3a, + 0x00, 0x92, 0x3b, 0x1d, 0x01, 0x95, 0x03, 0x9a, 0x07, 0x21, 0x30, 0x00, + 0xfd, 0xf7, 0xcb, 0xfa, 0x00, 0x28, 0x31, 0xda, 0x34, 0xe0, 0x01, 0x22, + 0x2b, 0x79, 0x10, 0x00, 0x59, 0x08, 0x93, 0x43, 0x92, 0x18, 0x13, 0x43, + 0x2b, 0x71, 0x80, 0x23, 0x88, 0x43, 0x5b, 0x00, 0x02, 0x90, 0x00, 0x93, + 0x01, 0x95, 0x3b, 0x00, 0x00, 0x22, 0x07, 0x21, 0x30, 0x00, 0xfd, 0xf7, + 0xb4, 0xfa, 0x00, 0x28, 0x1e, 0xdb, 0x0f, 0x23, 0x0f, 0x4a, 0x23, 0x40, + 0x9b, 0x18, 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, + 0x24, 0x09, 0x5b, 0x00, 0x24, 0x03, 0x00, 0x92, 0x1b, 0x19, 0x00, 0x22, + 0x04, 0x21, 0x30, 0x00, 0xfd, 0xf7, 0x9f, 0xfa, 0x00, 0x28, 0x09, 0xdb, + 0xb3, 0x6b, 0x01, 0x33, 0xb3, 0x63, 0x02, 0x9b, 0x00, 0x2b, 0xbd, 0xd1, + 0x04, 0x99, 0x30, 0x00, 0xff, 0xf7, 0x56, 0xff, 0x09, 0xb0, 0xf0, 0xbd, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x87, 0xb0, 0x04, 0x93, 0x0c, 0xab, + 0x1b, 0x88, 0x07, 0x00, 0x00, 0x93, 0x0d, 0xab, 0x1b, 0x88, 0x15, 0x00, + 0x03, 0x93, 0x04, 0x9b, 0x05, 0x91, 0x5b, 0x04, 0x5b, 0x0c, 0x02, 0x93, + 0x83, 0x6a, 0x1e, 0x1d, 0x00, 0x23, 0x34, 0x00, 0x01, 0x93, 0xfb, 0x6a, + 0x01, 0x9a, 0x93, 0x42, 0x08, 0xd8, 0x01, 0x2d, 0x00, 0xd8, 0x6e, 0xe0, + 0x3c, 0x6d, 0x00, 0x2c, 0x00, 0xd0, 0x6c, 0xe0, 0x07, 0xb0, 0xf0, 0xbd, + 0x43, 0x4a, 0x63, 0x88, 0x13, 0x40, 0x02, 0x9a, 0x93, 0x42, 0x38, 0xd1, + 0x00, 0x9b, 0x00, 0x2b, 0x2b, 0xd1, 0x02, 0x2d, 0x38, 0xd0, 0xa3, 0x8c, + 0x00, 0x2b, 0x30, 0xd0, 0x6b, 0x46, 0x9b, 0x89, 0x23, 0x81, 0x0e, 0x9b, + 0x00, 0x2b, 0x20, 0xd0, 0x0e, 0x9a, 0x63, 0x60, 0xe1, 0x69, 0x00, 0x9b, + 0x01, 0x32, 0x09, 0xd0, 0x0e, 0x9b, 0x00, 0x29, 0x06, 0xd0, 0xca, 0x68, + 0x0b, 0x8a, 0x9b, 0x18, 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd2, 0x13, 0x00, + 0x22, 0x69, 0x9a, 0x42, 0x00, 0xd9, 0x23, 0x61, 0x62, 0x69, 0x9a, 0x42, + 0x00, 0xd9, 0x63, 0x61, 0x00, 0x29, 0x06, 0xd0, 0xca, 0x68, 0x01, 0x33, + 0x9a, 0x42, 0x02, 0xd9, 0x38, 0x00, 0xfd, 0xf7, 0x91, 0xfa, 0xa3, 0x89, + 0x00, 0x9a, 0x93, 0x42, 0x05, 0xd1, 0x00, 0x23, 0x02, 0x2d, 0x01, 0xd0, + 0x6b, 0x46, 0x9b, 0x89, 0x63, 0x81, 0x01, 0x9b, 0x30, 0x34, 0x01, 0x33, + 0x01, 0x93, 0xae, 0xe7, 0x00, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x05, 0xd0, + 0xe1, 0x69, 0x00, 0x29, 0x02, 0xd0, 0x38, 0x00, 0xfd, 0xf7, 0x78, 0xfa, + 0x00, 0x23, 0x23, 0x80, 0x63, 0x80, 0xe2, 0xe7, 0x00, 0x22, 0xb3, 0x5e, + 0x00, 0x2b, 0x0c, 0xd0, 0xb0, 0x6a, 0x00, 0x28, 0x09, 0xd0, 0x17, 0x4a, + 0x73, 0x88, 0x13, 0x40, 0x02, 0x9a, 0x93, 0x42, 0x03, 0xd1, 0x05, 0x9a, + 0x00, 0x99, 0xff, 0xf7, 0xd1, 0xfa, 0x01, 0x34, 0x30, 0x36, 0xfb, 0x6a, + 0xa3, 0x42, 0xe9, 0xd8, 0x90, 0xe7, 0x00, 0x24, 0xf9, 0xe7, 0x00, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x8e, 0xe7, 0x6b, 0x46, 0x10, 0x22, 0x9b, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0x88, 0xe7, 0x00, 0x99, 0x01, 0x2d, 0x08, 0xd0, + 0x00, 0x2d, 0x0b, 0xd0, 0xeb, 0x1e, 0x01, 0x2b, 0x08, 0xd9, 0x29, 0x00, + 0x02, 0x2d, 0x00, 0xd0, 0x7c, 0xe7, 0x03, 0x9b, 0x02, 0x9a, 0x38, 0x00, + 0xa0, 0x47, 0x77, 0xe7, 0x01, 0x21, 0xf8, 0xe7, 0xff, 0x7f, 0xff, 0xff, + 0xf0, 0xb5, 0x16, 0x27, 0x97, 0xb0, 0x1c, 0xab, 0x1b, 0x78, 0x04, 0x00, + 0x06, 0x93, 0x02, 0xab, 0xff, 0x18, 0x39, 0x80, 0xfb, 0x21, 0x05, 0x92, + 0xfe, 0xf7, 0x34, 0xfe, 0x05, 0x1e, 0x65, 0xdb, 0x3a, 0x88, 0x34, 0x4b, + 0x20, 0x00, 0x13, 0x43, 0x3b, 0x80, 0x09, 0xab, 0x00, 0x93, 0x1a, 0x23, + 0x02, 0xaa, 0x9b, 0x18, 0x21, 0x8a, 0x62, 0x69, 0xff, 0xf7, 0x5c, 0xfd, + 0x05, 0x1e, 0x55, 0xdb, 0x02, 0xab, 0x5b, 0x8b, 0x09, 0x9a, 0x1b, 0x03, + 0x52, 0x00, 0x9b, 0x18, 0x02, 0x22, 0x01, 0x97, 0x00, 0x92, 0x04, 0x21, + 0x00, 0x22, 0x20, 0x00, 0xfd, 0xf7, 0xb5, 0xf9, 0x05, 0x1e, 0x45, 0xdb, + 0xa3, 0x6b, 0x0a, 0xae, 0x01, 0x33, 0xa3, 0x63, 0x3b, 0x88, 0x2d, 0x20, + 0x33, 0x80, 0x00, 0x23, 0x73, 0x80, 0xf8, 0x33, 0x33, 0x71, 0x6b, 0x46, + 0x19, 0x7e, 0x02, 0xab, 0x31, 0x73, 0x01, 0x21, 0x49, 0x42, 0x0c, 0x91, + 0x20, 0x22, 0x05, 0x99, 0xc0, 0x18, 0x02, 0xf0, 0xe5, 0xfb, 0x09, 0x98, + 0x07, 0x21, 0x43, 0x1c, 0x02, 0xa8, 0x42, 0x8b, 0x1b, 0x02, 0x12, 0x03, + 0x9b, 0x18, 0x2e, 0x22, 0x01, 0x96, 0x00, 0x92, 0x20, 0x00, 0x00, 0x22, + 0xfd, 0xf7, 0x8d, 0xf9, 0x05, 0x1e, 0x1d, 0xdb, 0x01, 0x21, 0x49, 0x42, + 0x3b, 0x88, 0x02, 0x91, 0x02, 0xa9, 0x4a, 0x8b, 0x09, 0x99, 0x12, 0x01, + 0x8a, 0x18, 0x01, 0x32, 0x92, 0xb2, 0x01, 0x92, 0x00, 0x22, 0x31, 0x00, + 0x00, 0x92, 0x20, 0x00, 0x01, 0x32, 0xff, 0xf7, 0xe9, 0xfe, 0x1d, 0x9b, + 0x00, 0x2b, 0x07, 0xd0, 0x02, 0xab, 0x5b, 0x8b, 0x09, 0x9a, 0x1b, 0x01, + 0xd3, 0x18, 0x1d, 0x9a, 0x01, 0x33, 0x13, 0x80, 0x28, 0x00, 0x17, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, 0xf0, 0xb5, 0x89, 0xb0, + 0x05, 0x93, 0x80, 0x23, 0x0e, 0x9c, 0x1b, 0x02, 0x1a, 0x43, 0x06, 0x00, + 0x0f, 0x00, 0x04, 0x92, 0x00, 0x2c, 0x0e, 0xd1, 0x04, 0x21, 0x7a, 0x5e, + 0x41, 0x6a, 0x05, 0x9b, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, + 0x1b, 0x02, 0xea, 0x39, 0xfd, 0xf7, 0xeb, 0xf8, 0x05, 0x1e, 0x4e, 0xdb, + 0x74, 0x6a, 0x23, 0x79, 0xda, 0x07, 0x4d, 0xd4, 0x5a, 0xb2, 0x00, 0x2a, + 0x4c, 0xda, 0x9a, 0x07, 0x4c, 0xd4, 0x5b, 0x07, 0x4c, 0xd4, 0x63, 0x88, + 0x00, 0x2b, 0x4b, 0xd1, 0x0f, 0x9b, 0x00, 0x2b, 0x05, 0xd0, 0x20, 0x00, + 0x20, 0x22, 0x19, 0x00, 0x0d, 0x30, 0x02, 0xf0, 0x7f, 0xfb, 0x11, 0x9b, + 0x00, 0x2b, 0x03, 0xd0, 0x23, 0x81, 0x11, 0x9b, 0x1b, 0x0c, 0x63, 0x81, + 0x39, 0x1e, 0x01, 0xd0, 0x04, 0x23, 0xf9, 0x5e, 0x16, 0x23, 0x02, 0xaa, + 0x9b, 0x18, 0x02, 0x93, 0x05, 0x9b, 0x22, 0x00, 0x01, 0x93, 0x00, 0x23, + 0x30, 0x00, 0x00, 0x93, 0x04, 0x9b, 0xff, 0xf7, 0x11, 0xfe, 0x05, 0x1e, + 0x1d, 0xd1, 0x02, 0xab, 0xd9, 0x8a, 0x12, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0x19, 0x80, 0x0e, 0x9a, 0x20, 0x89, 0x53, 0x42, 0x5a, 0x41, 0x63, 0x89, + 0x01, 0x91, 0x1b, 0x04, 0x03, 0x43, 0x02, 0x93, 0x63, 0x88, 0x92, 0x00, + 0x00, 0x93, 0x21, 0x00, 0x04, 0x9b, 0x30, 0x00, 0xff, 0xf7, 0x76, 0xfe, + 0x00, 0x2f, 0x04, 0xd0, 0x16, 0x23, 0x02, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0xbb, 0x81, 0x28, 0x00, 0x09, 0xb0, 0xf0, 0xbd, 0x04, 0x4d, 0xfa, 0xe7, + 0x04, 0x4d, 0xf8, 0xe7, 0x04, 0x4d, 0xf6, 0xe7, 0x04, 0x4d, 0xf4, 0xe7, + 0x04, 0x4d, 0xf2, 0xe7, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x93, 0xb0, 0x03, 0x93, 0x0d, 0x00, 0x0b, 0x02, 0x14, 0x00, + 0x04, 0x21, 0x52, 0x5e, 0x2e, 0x21, 0x06, 0xae, 0x00, 0x91, 0x01, 0x96, + 0x18, 0x39, 0x07, 0x00, 0xfd, 0xf7, 0x73, 0xf8, 0x00, 0x28, 0x33, 0xdb, + 0x0f, 0x23, 0x2b, 0x40, 0x2a, 0x09, 0x01, 0x3b, 0x12, 0x03, 0x5b, 0x00, + 0x9b, 0x18, 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, + 0x14, 0x21, 0x00, 0x92, 0x38, 0x00, 0x00, 0x22, 0xfd, 0xf7, 0x5f, 0xf8, + 0xa5, 0x81, 0x27, 0x60, 0xb3, 0x68, 0x6a, 0x46, 0xa3, 0x60, 0x00, 0x23, + 0x63, 0x61, 0x23, 0x82, 0x02, 0xab, 0xe5, 0x81, 0xdb, 0x89, 0x95, 0x89, + 0xe3, 0x80, 0xa5, 0x83, 0x32, 0x79, 0xd4, 0x07, 0x0f, 0xd4, 0x51, 0xb2, + 0x00, 0x29, 0x0f, 0xda, 0x02, 0x21, 0x0a, 0x42, 0x0e, 0xd1, 0x52, 0x07, + 0x0e, 0xd4, 0x1b, 0xb2, 0x00, 0x2b, 0x0b, 0xda, 0x73, 0x88, 0x00, 0x2b, + 0x02, 0xd0, 0x05, 0x48, 0x00, 0xe0, 0x05, 0x48, 0x13, 0xb0, 0xf0, 0xbd, + 0x04, 0x48, 0xfb, 0xe7, 0x04, 0x48, 0xf9, 0xe7, 0x04, 0x48, 0xf7, 0xe7, + 0xe3, 0xd8, 0xff, 0xff, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x95, 0xb0, + 0x0e, 0x93, 0x07, 0x68, 0x0d, 0x00, 0x0e, 0x99, 0x83, 0x68, 0x06, 0x00, + 0xfb, 0x31, 0x38, 0x00, 0x0f, 0x92, 0x06, 0x93, 0xfe, 0xf7, 0xe0, 0xfc, + 0x04, 0x1e, 0x00, 0xda, 0x0b, 0xe2, 0x06, 0x9b, 0x0a, 0x93, 0xab, 0x42, + 0x00, 0xd9, 0x0a, 0x95, 0x7b, 0x6a, 0xb2, 0x89, 0x06, 0x93, 0x10, 0xab, + 0x1a, 0x80, 0xfb, 0x21, 0x0a, 0x98, 0x02, 0xf0, 0xe7, 0xf9, 0xfb, 0x21, + 0x83, 0xb2, 0x0a, 0x98, 0x09, 0x93, 0x02, 0xf0, 0x67, 0xfa, 0x4e, 0x4b, + 0x0c, 0x91, 0x0b, 0x93, 0x00, 0x23, 0x07, 0x93, 0x08, 0x93, 0x9c, 0x42, + 0x00, 0xd1, 0x2e, 0xe1, 0x0a, 0x9a, 0x08, 0x9b, 0x94, 0x46, 0x63, 0x44, + 0x09, 0x93, 0xb3, 0x60, 0x73, 0x61, 0x6b, 0x46, 0x9b, 0x8b, 0x10, 0xad, + 0x2a, 0x88, 0x33, 0x82, 0x07, 0x9b, 0xf2, 0x81, 0x00, 0x2b, 0x00, 0xd1, + 0x26, 0xe2, 0x31, 0x00, 0x38, 0x00, 0xff, 0xf7, 0x31, 0xf8, 0x00, 0x28, + 0x31, 0xdb, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfd, 0xf7, 0x3d, 0xf8, 0x00, 0x28, 0x22, 0xdb, 0x00, 0x22, 0x02, 0x92, + 0x2a, 0x88, 0x06, 0x98, 0x01, 0x92, 0xc2, 0x78, 0x81, 0x78, 0x12, 0x02, + 0x0a, 0x43, 0x00, 0x92, 0xf3, 0x88, 0x00, 0x22, 0x79, 0x6a, 0x38, 0x00, + 0xff, 0xf7, 0x9c, 0xfd, 0x1a, 0x21, 0x0a, 0xa8, 0x09, 0x18, 0x04, 0x91, + 0x00, 0x21, 0x09, 0x98, 0xb3, 0x89, 0xf2, 0x88, 0x03, 0x90, 0x02, 0x91, + 0x01, 0x91, 0x00, 0x91, 0x38, 0x00, 0x31, 0x00, 0xff, 0xf7, 0xb4, 0xfe, + 0x00, 0x28, 0x00, 0xdb, 0xa5, 0xe1, 0x04, 0x00, 0xa3, 0xe1, 0x1a, 0x20, + 0x03, 0x91, 0x0a, 0xac, 0x0b, 0x99, 0x00, 0x19, 0x04, 0x90, 0x02, 0x91, + 0x01, 0x91, 0x79, 0x6a, 0xb3, 0x89, 0xf2, 0x88, 0x00, 0x91, 0x31, 0x00, + 0x38, 0x00, 0xff, 0xf7, 0x9f, 0xfe, 0x11, 0xe1, 0x10, 0xad, 0x2a, 0x88, + 0x0b, 0x9b, 0x31, 0x00, 0x38, 0x00, 0xfe, 0xf7, 0xe3, 0xff, 0x04, 0x1e, + 0x00, 0xda, 0x88, 0xe1, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, + 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, + 0x38, 0x00, 0xfc, 0xf7, 0xee, 0xff, 0x04, 0x1e, 0x00, 0xda, 0x78, 0xe1, + 0x00, 0x24, 0x02, 0x94, 0x2a, 0x88, 0xf3, 0x88, 0x01, 0x92, 0x06, 0x9a, + 0x38, 0x00, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, 0x00, 0x92, + 0x79, 0x6a, 0x22, 0x00, 0xff, 0xf7, 0x4c, 0xfd, 0x1a, 0x21, 0x0a, 0xa8, + 0x09, 0x18, 0x04, 0x91, 0x0a, 0x98, 0x08, 0x99, 0xb3, 0x89, 0x09, 0x18, + 0xf2, 0x88, 0x03, 0x91, 0x02, 0x94, 0x01, 0x94, 0x00, 0x94, 0xc2, 0xe7, + 0xff, 0xff, 0x00, 0x00, 0xb3, 0x68, 0x58, 0x1e, 0xc6, 0x4b, 0x98, 0x42, + 0x0f, 0xd9, 0x08, 0x9b, 0x00, 0x2b, 0x0c, 0xd1, 0xfb, 0x21, 0x02, 0xf0, + 0x37, 0xf9, 0x7c, 0x21, 0x69, 0x38, 0x02, 0xf0, 0x33, 0xf9, 0x07, 0x9b, + 0x01, 0x30, 0x80, 0xb2, 0x83, 0x42, 0x00, 0xd8, 0xfb, 0xe0, 0x80, 0x23, + 0xf1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x6b, 0x46, 0x9b, 0x8b, 0x12, 0xad, + 0x6b, 0x80, 0xf9, 0x23, 0x2b, 0x71, 0x10, 0xab, 0x29, 0x80, 0x03, 0x93, + 0x01, 0x23, 0x02, 0x93, 0x00, 0x23, 0x2a, 0x00, 0x01, 0x93, 0x00, 0x93, + 0x38, 0x00, 0xff, 0xf7, 0xe1, 0xfb, 0x04, 0x1e, 0x00, 0xda, 0x2a, 0xe1, + 0x80, 0x22, 0xff, 0x21, 0x52, 0x00, 0x78, 0x6a, 0x02, 0xf0, 0xc7, 0xf9, + 0x05, 0x22, 0x29, 0x00, 0x78, 0x6a, 0x02, 0xf0, 0xb9, 0xf9, 0x00, 0x22, + 0x02, 0x92, 0x0a, 0xaa, 0x12, 0x8b, 0xf3, 0x88, 0x01, 0x92, 0x07, 0x9a, + 0x38, 0x00, 0x00, 0x92, 0x79, 0x6a, 0x01, 0x22, 0xff, 0xf7, 0xf6, 0xfc, + 0x10, 0xab, 0x1b, 0x88, 0x0a, 0x9a, 0xf3, 0x81, 0x6b, 0x46, 0x9b, 0x8b, + 0x33, 0x82, 0x08, 0x9b, 0x9b, 0x18, 0x73, 0x61, 0xb3, 0x60, 0x07, 0x9b, + 0x0b, 0x93, 0x08, 0x9a, 0x0e, 0x9b, 0x0c, 0x99, 0x9b, 0x1a, 0xfb, 0x22, + 0x52, 0x1a, 0x0d, 0x92, 0x9a, 0x42, 0x00, 0xd9, 0x0d, 0x93, 0x0c, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0xfa, 0xe0, 0x6b, 0x46, 0x9b, 0x8c, 0x12, 0xaa, + 0xf1, 0x88, 0x53, 0x80, 0xfd, 0x23, 0x08, 0x98, 0x13, 0x71, 0x0f, 0x9b, + 0x49, 0x04, 0x49, 0x0c, 0x1b, 0x18, 0x11, 0xa8, 0x11, 0x80, 0x03, 0x90, + 0x01, 0x20, 0x02, 0x90, 0x0c, 0x98, 0x01, 0x90, 0x0d, 0x98, 0x00, 0x90, + 0x38, 0x00, 0xff, 0xf7, 0x93, 0xfb, 0x04, 0x1e, 0x00, 0xd0, 0xed, 0xe6, + 0x11, 0xab, 0x1d, 0x88, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x11, 0xe1, + 0x09, 0x9b, 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9d, 0x52, 0x0a, 0x9a, + 0x08, 0x9b, 0x9b, 0x18, 0x06, 0x9a, 0x13, 0x81, 0x1b, 0x0c, 0x53, 0x81, + 0x0d, 0x9a, 0x09, 0x98, 0x94, 0x46, 0x01, 0x30, 0x83, 0xb2, 0x09, 0x93, + 0x08, 0x9b, 0x63, 0x44, 0x08, 0x93, 0x00, 0x23, 0x0c, 0x93, 0x08, 0x9b, + 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd3, 0xcb, 0xe6, 0x00, 0x23, 0x07, 0x93, + 0x09, 0x9b, 0x68, 0x2b, 0x07, 0xd9, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x02, 0xf0, 0x9a, 0xf8, 0x01, 0x30, 0x83, 0xb2, 0x07, 0x93, 0x0b, 0x9b, + 0x07, 0x9a, 0x93, 0x42, 0xa3, 0xd0, 0x08, 0x9b, 0x00, 0x2b, 0x2d, 0xd0, + 0x0b, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x0f, 0xe7, 0x08, 0x9b, 0x0a, 0x9a, + 0x99, 0x18, 0x06, 0x9b, 0x06, 0x9a, 0x19, 0x81, 0x0b, 0x0c, 0x53, 0x81, + 0x0a, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0xf2, 0xe6, 0x10, 0xad, 0x2a, 0x88, + 0x31, 0x00, 0x38, 0x00, 0xfe, 0xf7, 0xe8, 0xfe, 0x04, 0x1e, 0x00, 0xda, + 0x8d, 0xe0, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfc, 0xf7, 0xf3, 0xfe, 0x04, 0x1e, 0x00, 0xda, 0x7d, 0xe0, 0x08, 0x9b, + 0x0a, 0x9a, 0x9b, 0x18, 0xb3, 0x60, 0x73, 0x61, 0x07, 0x9b, 0x00, 0x2b, + 0x00, 0xd0, 0x1b, 0xe7, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x10, 0xab, + 0x1b, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, + 0xea, 0x39, 0x38, 0x00, 0xfc, 0xf7, 0x75, 0xfe, 0x04, 0x1e, 0x64, 0xdb, + 0x01, 0x22, 0x06, 0x9b, 0x1b, 0x79, 0x13, 0x42, 0x00, 0xd0, 0xe9, 0xe0, + 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xe7, 0xe0, 0x9a, 0x07, 0x00, 0xd5, + 0xe6, 0xe0, 0x5b, 0x07, 0x00, 0xd5, 0xe5, 0xe0, 0x06, 0x22, 0xb3, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0xe0, 0xe0, 0x06, 0x9b, 0x5b, 0x88, 0x0b, 0x93, + 0x00, 0x2b, 0x00, 0xd1, 0x43, 0xe7, 0x41, 0x4c, 0x47, 0xe0, 0x33, 0x8a, + 0x07, 0x9a, 0x93, 0x42, 0x34, 0xd1, 0x1e, 0x23, 0xf2, 0x89, 0x0a, 0xa9, + 0x5b, 0x18, 0x1a, 0x80, 0x1e, 0x25, 0x0a, 0xab, 0x04, 0x21, 0x72, 0x5e, + 0x79, 0x6a, 0xed, 0x18, 0x2b, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, + 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x38, 0x00, 0xfc, 0xf7, 0x3d, 0xfe, + 0x04, 0x1e, 0x2c, 0xdb, 0x01, 0x22, 0x06, 0x9b, 0x1b, 0x79, 0x13, 0x42, + 0x00, 0xd0, 0xb1, 0xe0, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xaf, 0xe0, + 0x9a, 0x07, 0x00, 0xd5, 0xae, 0xe0, 0x5b, 0x07, 0x00, 0xd5, 0xad, 0xe0, + 0x06, 0x22, 0xb3, 0x5e, 0x00, 0x2b, 0x00, 0xdb, 0xa8, 0xe0, 0x06, 0x9b, + 0x07, 0x9a, 0x5b, 0x88, 0x93, 0x42, 0xc8, 0xd1, 0x2a, 0x88, 0x10, 0xab, + 0x1a, 0x80, 0xfb, 0xe6, 0x80, 0x23, 0xf1, 0x88, 0x1b, 0x02, 0x19, 0x43, + 0x1e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, 0x00, 0x93, 0x07, 0x9a, 0x08, 0x9b, + 0x38, 0x00, 0xff, 0xf7, 0x45, 0xfa, 0x04, 0x1e, 0xc0, 0xda, 0x20, 0x00, + 0x15, 0xb0, 0xf0, 0xbd, 0x07, 0x9b, 0x00, 0x2b, 0x21, 0xd1, 0x09, 0x9b, + 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9a, 0x5a, 0x11, 0xab, 0x1a, 0x80, + 0x11, 0xad, 0x2a, 0x88, 0x31, 0x1d, 0x09, 0x9b, 0x38, 0x00, 0xfe, 0xf7, + 0x97, 0xff, 0x04, 0x1e, 0xe9, 0xdb, 0x2b, 0x88, 0x0c, 0x9a, 0x1b, 0x02, + 0x05, 0x33, 0x08, 0x98, 0x9b, 0x18, 0x04, 0x21, 0x72, 0x5e, 0x0f, 0x99, + 0x09, 0x18, 0x01, 0x91, 0x0d, 0x99, 0x38, 0x00, 0x00, 0x91, 0x07, 0x21, + 0xfc, 0xf7, 0x4b, 0xfe, 0xf7, 0xe6, 0x09, 0x9b, 0x19, 0x1d, 0x68, 0x2b, + 0x05, 0xd9, 0x09, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x02, 0xf0, 0x3e, 0xf8, + 0x04, 0x31, 0x06, 0x9b, 0x49, 0x00, 0x5a, 0x5a, 0xd4, 0xe7, 0xc0, 0x46, + 0xf2, 0x66, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, 0x09, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x09, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x02, 0xf0, + 0x2b, 0xf8, 0x04, 0x31, 0x06, 0x9b, 0x49, 0x00, 0x5d, 0x52, 0xeb, 0xe6, + 0x0a, 0x9b, 0x00, 0x2b, 0x31, 0xd1, 0x69, 0x46, 0x06, 0x9b, 0x09, 0x8c, + 0x38, 0x00, 0x19, 0x81, 0x08, 0x9b, 0x06, 0x99, 0x1b, 0x0c, 0x4b, 0x81, + 0x0a, 0x9b, 0x31, 0x00, 0xfe, 0xf7, 0xfe, 0xfd, 0x00, 0x28, 0x00, 0xda, + 0xfd, 0xe5, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfc, 0xf7, 0x09, 0xfe, 0x00, 0x28, 0x00, 0xda, 0xed, 0xe5, 0x06, 0x9a, + 0xf3, 0x88, 0x11, 0x89, 0x52, 0x89, 0x38, 0x00, 0x12, 0x04, 0x0a, 0x43, + 0x02, 0x92, 0x2a, 0x88, 0x01, 0x92, 0x06, 0x9a, 0x52, 0x88, 0x00, 0x92, + 0x79, 0x6a, 0x04, 0x22, 0xff, 0xf7, 0x66, 0xfb, 0x81, 0xe7, 0x1a, 0x21, + 0x0a, 0xa8, 0x09, 0x18, 0x04, 0x91, 0x09, 0x99, 0xb3, 0x89, 0x03, 0x91, + 0x07, 0x99, 0xf2, 0x88, 0x02, 0x91, 0x01, 0x91, 0x79, 0x6a, 0xc6, 0xe5, + 0x03, 0x4c, 0x72, 0xe7, 0x03, 0x4c, 0x70, 0xe7, 0x03, 0x4c, 0x6e, 0xe7, + 0x03, 0x4c, 0x6c, 0xe7, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x95, 0xb0, + 0x0d, 0x91, 0x19, 0x00, 0x05, 0x68, 0x07, 0x00, 0xfb, 0x31, 0x28, 0x00, + 0x0f, 0x92, 0x0e, 0x93, 0xfe, 0xf7, 0x2a, 0xfa, 0x04, 0x1e, 0x00, 0xda, + 0x6e, 0xe1, 0x6b, 0x6a, 0xfb, 0x21, 0x07, 0x93, 0xbb, 0x89, 0x0d, 0x98, + 0x0b, 0x93, 0x01, 0xf0, 0x37, 0xff, 0xfb, 0x21, 0x83, 0xb2, 0x0d, 0x98, + 0x08, 0x93, 0x01, 0xf0, 0xb7, 0xff, 0x00, 0x23, 0x0a, 0x91, 0xc1, 0x4e, + 0x06, 0x93, 0x09, 0x93, 0x9c, 0x42, 0x00, 0xd1, 0x2c, 0xe1, 0x0d, 0x9a, + 0x09, 0x9b, 0x94, 0x46, 0x63, 0x44, 0x7b, 0x61, 0x6b, 0x46, 0x9b, 0x8d, + 0xfb, 0x81, 0x6b, 0x46, 0x1b, 0x8b, 0x3b, 0x82, 0x06, 0x9b, 0x00, 0x2b, + 0x00, 0xd1, 0xf4, 0xe1, 0x0b, 0x9a, 0x39, 0x00, 0x28, 0x00, 0xfe, 0xf7, + 0x83, 0xfd, 0x00, 0x28, 0x00, 0xda, 0xff, 0xe1, 0x04, 0x22, 0xb9, 0x5e, + 0x1e, 0x22, 0x00, 0x26, 0x0a, 0xa8, 0x12, 0x18, 0xfb, 0x88, 0x02, 0x92, + 0x0b, 0x9a, 0x00, 0x96, 0x01, 0x92, 0x28, 0x00, 0x07, 0x9a, 0xff, 0xf7, + 0x7f, 0xfa, 0x0a, 0xab, 0xda, 0x8b, 0x6b, 0x46, 0x1b, 0x8b, 0xfa, 0x81, + 0x3b, 0x82, 0xb0, 0x42, 0x00, 0xda, 0xe7, 0xe1, 0xfb, 0x88, 0x01, 0x92, + 0x07, 0x9a, 0x02, 0x96, 0x91, 0x78, 0xd2, 0x78, 0x28, 0x00, 0x12, 0x02, + 0x0a, 0x43, 0x00, 0x92, 0x07, 0x99, 0x32, 0x00, 0xff, 0xf7, 0xe6, 0xfa, + 0x1a, 0xe1, 0x00, 0x23, 0x06, 0x93, 0x33, 0x00, 0x0b, 0x9a, 0x39, 0x00, + 0x28, 0x00, 0xfe, 0xf7, 0x51, 0xfd, 0x04, 0x1e, 0x00, 0xda, 0x0f, 0xe1, + 0x04, 0x22, 0xb9, 0x5e, 0x1e, 0x22, 0x00, 0x26, 0x0a, 0xa8, 0x12, 0x18, + 0xfb, 0x88, 0x02, 0x92, 0x0b, 0x9a, 0x00, 0x96, 0x01, 0x92, 0x28, 0x00, + 0x07, 0x9a, 0xff, 0xf7, 0x4d, 0xfa, 0x04, 0x00, 0xb0, 0x42, 0x00, 0xda, + 0xfc, 0xe0, 0xfb, 0x88, 0x0a, 0xaa, 0x02, 0x96, 0xd2, 0x8b, 0x28, 0x00, + 0x01, 0x92, 0x07, 0x9a, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, + 0x00, 0x92, 0x07, 0x99, 0x32, 0x00, 0xff, 0xf7, 0xb7, 0xfa, 0x06, 0x9b, + 0xb3, 0x42, 0x29, 0xd1, 0x04, 0x21, 0x7a, 0x5e, 0x69, 0x6a, 0x0b, 0x9b, + 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, + 0x28, 0x00, 0xfc, 0xf7, 0xd2, 0xfc, 0x04, 0x1e, 0x00, 0xda, 0xd9, 0xe0, + 0x07, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x00, 0xd5, 0x94, 0xe1, 0x5a, 0xb2, + 0x00, 0x2a, 0x00, 0xdb, 0x92, 0xe1, 0x9a, 0x07, 0x00, 0xd5, 0x91, 0xe1, + 0x5b, 0x07, 0x00, 0xd5, 0x90, 0xe1, 0x06, 0x22, 0xbb, 0x5e, 0x00, 0x2b, + 0x00, 0xdb, 0x8b, 0xe1, 0x07, 0x9b, 0x5b, 0x88, 0x00, 0x2b, 0x39, 0xd0, + 0x73, 0x4c, 0xbf, 0xe0, 0x3b, 0x8a, 0x06, 0x9a, 0x93, 0x42, 0x00, 0xd0, + 0xbd, 0xe0, 0x1e, 0x23, 0xfa, 0x89, 0x0a, 0xa9, 0x5b, 0x18, 0x1a, 0x80, + 0x1e, 0x26, 0x04, 0x21, 0x7a, 0x5e, 0x0a, 0xab, 0x69, 0x6a, 0xf6, 0x18, + 0x33, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, + 0xea, 0x39, 0x28, 0x00, 0xfc, 0xf7, 0x9b, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0xa2, 0xe0, 0x07, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x00, 0xd5, 0x5d, 0xe1, + 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0x5b, 0xe1, 0x9a, 0x07, 0x00, 0xd5, + 0x5a, 0xe1, 0x5b, 0x07, 0x00, 0xd5, 0x59, 0xe1, 0x06, 0x22, 0xbb, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0x54, 0xe1, 0x07, 0x9b, 0x06, 0x9a, 0x5b, 0x88, + 0x93, 0x42, 0xc7, 0xd1, 0x33, 0x88, 0x0b, 0x93, 0x6b, 0x46, 0x9b, 0x8d, + 0x0d, 0x9a, 0xfb, 0x81, 0x6b, 0x46, 0x1b, 0x8b, 0x3b, 0x82, 0x09, 0x9b, + 0x9b, 0x18, 0x7b, 0x61, 0x09, 0x9a, 0x0e, 0x9b, 0x0a, 0x99, 0x9b, 0x1a, + 0xfb, 0x22, 0x56, 0x1a, 0x9e, 0x42, 0x00, 0xd9, 0x1e, 0x00, 0x06, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x84, 0xe0, 0x08, 0x9b, 0x07, 0x9a, 0x17, 0x33, + 0x5b, 0x00, 0x9b, 0x5a, 0x0c, 0x93, 0x00, 0x23, 0x06, 0x93, 0x6b, 0x46, + 0x1b, 0x8c, 0x12, 0xaa, 0xf9, 0x88, 0x53, 0x80, 0xff, 0x23, 0x49, 0x04, + 0x13, 0x71, 0x0a, 0x9b, 0x49, 0x0c, 0x11, 0x80, 0x00, 0x2b, 0x00, 0xd0, + 0x82, 0xe0, 0xfb, 0x2e, 0x00, 0xd0, 0x7f, 0xe0, 0x09, 0x98, 0x0f, 0x9b, + 0x00, 0x96, 0x1b, 0x18, 0x11, 0xa8, 0x03, 0x90, 0x01, 0x20, 0x02, 0x90, + 0x0a, 0x98, 0x01, 0x90, 0x28, 0x00, 0xff, 0xf7, 0xe5, 0xf8, 0x0c, 0x99, + 0x28, 0x00, 0xff, 0xf7, 0x63, 0xf9, 0x04, 0x1e, 0x00, 0xd0, 0xea, 0xe6, + 0x11, 0xab, 0x1b, 0x88, 0x0a, 0x93, 0x06, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0xd7, 0xe0, 0x69, 0x46, 0x08, 0x9b, 0x07, 0x9a, 0x17, 0x33, 0x09, 0x8d, + 0x5b, 0x00, 0x99, 0x52, 0x08, 0x98, 0x01, 0x30, 0x83, 0xb2, 0x08, 0x93, + 0x09, 0x9b, 0x9b, 0x19, 0x09, 0x93, 0x00, 0x23, 0x06, 0x9e, 0x0a, 0x93, + 0x09, 0x9b, 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd3, 0xcd, 0xe6, 0x08, 0x9b, + 0x68, 0x2b, 0x00, 0xd8, 0xf5, 0xe0, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x01, 0xf0, 0xee, 0xfd, 0x01, 0x30, 0x83, 0xb2, 0x06, 0x93, 0x9e, 0x42, + 0x9a, 0xd0, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd1, 0x54, 0xe7, 0x00, 0x2e, + 0x00, 0xd0, 0xf8, 0xe6, 0x1a, 0x21, 0x0a, 0xa8, 0x09, 0x18, 0xbb, 0x89, + 0xfa, 0x88, 0x03, 0x94, 0x02, 0x94, 0x01, 0x94, 0x04, 0x91, 0x69, 0x6a, + 0x28, 0x00, 0x00, 0x91, 0x39, 0x00, 0xff, 0xf7, 0xf5, 0xfa, 0x04, 0x1e, + 0x00, 0xdb, 0x3f, 0xe7, 0x20, 0x00, 0x15, 0xb0, 0xf0, 0xbd, 0x80, 0x23, + 0xf9, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x06, 0x9a, 0x00, 0x23, 0x28, 0x00, 0xff, 0xf7, 0x1a, 0xf8, + 0x04, 0x1e, 0x00, 0xdb, 0x36, 0xe7, 0xeb, 0xe7, 0x08, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x08, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0x39, 0xfe, 0x04, 0x31, 0x07, 0x9b, 0x49, 0x00, 0x5b, 0x5a, 0x0c, 0x93, + 0x73, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, + 0x39, 0x1d, 0x08, 0x9b, 0x0c, 0x9a, 0x28, 0x00, 0xfe, 0xf7, 0x64, 0xfd, + 0x04, 0x1e, 0xcf, 0xdb, 0x11, 0xab, 0xf9, 0x88, 0x03, 0x93, 0x00, 0x23, + 0x49, 0x04, 0x49, 0x0c, 0x02, 0x93, 0x01, 0x93, 0x00, 0x93, 0x12, 0xaa, + 0x28, 0x00, 0xff, 0xf7, 0x5d, 0xf8, 0x04, 0x1e, 0x00, 0xd0, 0x66, 0xe6, + 0x0a, 0x9b, 0x00, 0x2b, 0x2e, 0xd1, 0x0a, 0x9b, 0x98, 0x19, 0xfa, 0x28, + 0x3b, 0xd9, 0x0a, 0xab, 0x9b, 0x8b, 0x0a, 0x9a, 0x1b, 0x02, 0x05, 0x33, + 0x09, 0x98, 0x9b, 0x18, 0x04, 0x21, 0x7a, 0x5e, 0x0f, 0x99, 0x00, 0x96, + 0x09, 0x18, 0x01, 0x91, 0x28, 0x00, 0x07, 0x21, 0xfc, 0xf7, 0x01, 0xfc, + 0x04, 0x1e, 0x00, 0xd0, 0x4b, 0xe6, 0x02, 0x21, 0x12, 0xaa, 0x13, 0x79, + 0x28, 0x00, 0x8b, 0x43, 0x13, 0x71, 0x04, 0x21, 0x7a, 0x5e, 0x0a, 0xab, + 0x13, 0xa9, 0x9b, 0x8b, 0x01, 0x91, 0x01, 0x21, 0x1b, 0x02, 0x00, 0x91, + 0x04, 0x33, 0x06, 0x31, 0xfc, 0xf7, 0xeb, 0xfb, 0x04, 0x1e, 0x00, 0xd1, + 0x43, 0xe7, 0x34, 0xe6, 0x0a, 0xaa, 0x92, 0x8b, 0x0c, 0x9b, 0x04, 0x20, + 0x39, 0x5e, 0x0a, 0x98, 0x1b, 0x02, 0x12, 0x02, 0x00, 0x90, 0x05, 0x33, + 0x05, 0x32, 0x28, 0x00, 0xfe, 0xf7, 0xa4, 0xfd, 0x04, 0x1e, 0xc0, 0xd0, + 0x23, 0xe6, 0x0a, 0x9b, 0x0c, 0x9a, 0x05, 0x33, 0x12, 0x02, 0x9b, 0x19, + 0x9b, 0x18, 0x11, 0xaa, 0x12, 0x88, 0x0a, 0x99, 0x12, 0x02, 0x05, 0x32, + 0x52, 0x18, 0x04, 0x24, 0x39, 0x5f, 0xfb, 0x24, 0x20, 0x1a, 0x00, 0x90, + 0x92, 0x19, 0x28, 0x00, 0xfe, 0xf7, 0x8c, 0xfd, 0x04, 0x1e, 0xac, 0xd0, + 0x0b, 0xe6, 0x08, 0x9b, 0x19, 0x1d, 0x68, 0x2b, 0x05, 0xd9, 0x08, 0x98, + 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0xb2, 0xfd, 0x04, 0x31, 0x6a, 0x46, + 0x07, 0x9b, 0x12, 0x8d, 0x49, 0x00, 0x5a, 0x52, 0x1e, 0xe7, 0x1a, 0x21, + 0x0a, 0xa8, 0x09, 0x18, 0xbb, 0x89, 0xfa, 0x88, 0x04, 0x91, 0x06, 0x99, + 0x28, 0x00, 0x03, 0x91, 0x02, 0x91, 0x01, 0x91, 0x69, 0x6a, 0x00, 0x91, + 0x39, 0x00, 0xff, 0xf7, 0x37, 0xfa, 0x00, 0x28, 0x00, 0xdb, 0x41, 0xe7, + 0x04, 0x00, 0x3f, 0xe7, 0x0d, 0x4c, 0x3d, 0xe7, 0x0d, 0x4c, 0x3b, 0xe7, + 0x0d, 0x4c, 0x39, 0xe7, 0x0d, 0x4c, 0x37, 0xe7, 0x09, 0x9a, 0x0e, 0x9b, + 0x0a, 0x99, 0x9b, 0x1a, 0xfb, 0x22, 0x56, 0x1a, 0x9e, 0x42, 0x00, 0xd8, + 0xbd, 0xe6, 0x1e, 0x00, 0xbb, 0xe6, 0x00, 0x2e, 0xf2, 0xd0, 0x09, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x0b, 0xe6, 0x06, 0x93, 0x3a, 0xe6, 0xc0, 0x46, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0x70, 0xb5, 0x88, 0xb0, 0x07, 0xab, 0x1a, 0x26, + 0x04, 0x00, 0x05, 0x93, 0x08, 0x00, 0x00, 0x23, 0x15, 0x00, 0x0f, 0x4a, + 0x6e, 0x44, 0x03, 0x93, 0x02, 0x90, 0x01, 0x92, 0x00, 0x93, 0x21, 0x8b, + 0x04, 0x96, 0xe2, 0x69, 0x20, 0x00, 0xfe, 0xf7, 0x55, 0xfd, 0x0a, 0x4b, + 0x98, 0x42, 0x0d, 0xd0, 0x00, 0x28, 0x09, 0xdb, 0x31, 0x88, 0x07, 0x9a, + 0x00, 0x2d, 0x03, 0xd0, 0x0b, 0x01, 0x9b, 0x18, 0x01, 0x33, 0x2b, 0x80, + 0x21, 0x83, 0xe2, 0x61, 0x08, 0xb0, 0x70, 0xbd, 0x02, 0x48, 0xfb, 0xe7, + 0xcd, 0x48, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x83, 0x68, 0x93, 0xb0, 0x01, 0x3b, 0x04, 0x00, 0x0b, 0x91, + 0x07, 0x92, 0x06, 0x68, 0x03, 0x33, 0x00, 0xd8, 0xd6, 0xe0, 0x00, 0x25, + 0xaa, 0x42, 0x00, 0xd1, 0xde, 0xe0, 0x1a, 0x23, 0xa5, 0x89, 0x08, 0xaa, + 0xa7, 0x68, 0x9b, 0x18, 0x1d, 0x80, 0x00, 0x2f, 0x00, 0xd0, 0xd8, 0xe0, + 0x06, 0x97, 0x73, 0x6a, 0x08, 0x93, 0x07, 0x9b, 0x00, 0x2b, 0x13, 0xd0, + 0x0b, 0x9b, 0x00, 0x2b, 0x10, 0xd1, 0x10, 0xa9, 0xb8, 0x33, 0x0b, 0x70, + 0x01, 0x91, 0x01, 0x21, 0x2d, 0x02, 0x2b, 0x1d, 0x04, 0x20, 0x22, 0x5e, + 0x00, 0x91, 0x30, 0x00, 0x05, 0x31, 0xfc, 0xf7, 0x18, 0xfb, 0x05, 0x1e, + 0x00, 0xda, 0xbb, 0xe0, 0x9f, 0x4b, 0x0c, 0x93, 0x00, 0x23, 0x09, 0x93, + 0x0b, 0x9b, 0x9f, 0x42, 0x00, 0xd8, 0xfd, 0xe0, 0x06, 0x9b, 0x68, 0x2b, + 0x00, 0xd8, 0x14, 0xe2, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0x7b, 0xfc, 0x01, 0x30, 0x83, 0xb2, 0x0a, 0x93, 0x0a, 0x9a, 0x0c, 0x9b, + 0x93, 0x42, 0x00, 0xd1, 0x0e, 0xe2, 0x0c, 0x9b, 0x1a, 0x00, 0x92, 0x4b, + 0x9a, 0x42, 0x29, 0xd0, 0x08, 0xab, 0x5a, 0x8b, 0x21, 0x00, 0x0c, 0x9b, + 0x30, 0x00, 0xfe, 0xf7, 0xd5, 0xfa, 0x05, 0x1e, 0x00, 0xda, 0x93, 0xe0, + 0x08, 0xab, 0x59, 0x8b, 0x30, 0x00, 0xfe, 0xf7, 0xab, 0xff, 0x05, 0x1e, + 0x00, 0xda, 0x8b, 0xe0, 0x00, 0x21, 0x08, 0xaa, 0x02, 0x91, 0x52, 0x8b, + 0xe3, 0x88, 0x01, 0x92, 0x08, 0x9a, 0x90, 0x78, 0xd2, 0x78, 0x12, 0x02, + 0x02, 0x43, 0x00, 0x92, 0x30, 0x00, 0x02, 0x22, 0xff, 0xf7, 0x46, 0xf8, + 0x0c, 0x9b, 0x00, 0x2b, 0x04, 0xd0, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd1, + 0x82, 0xe0, 0xa7, 0x60, 0x0a, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x8e, 0xe0, + 0xa2, 0x89, 0x1a, 0x33, 0x08, 0xa9, 0x5b, 0x18, 0x1a, 0x80, 0x04, 0x21, + 0x62, 0x5e, 0x71, 0x6a, 0x08, 0xab, 0x5b, 0x8b, 0x01, 0x91, 0x80, 0x21, + 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x30, 0x00, 0xfc, 0xf7, + 0x52, 0xfa, 0x05, 0x1e, 0x5a, 0xdb, 0x08, 0x9b, 0x1b, 0x79, 0xda, 0x07, + 0x00, 0xd5, 0xb0, 0xe1, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xae, 0xe1, + 0x9a, 0x07, 0x00, 0xd5, 0xad, 0xe1, 0x5b, 0x07, 0x00, 0xd5, 0xac, 0xe1, + 0x06, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x00, 0xdb, 0xa7, 0xe1, 0x08, 0x9b, + 0x0a, 0x9a, 0x5b, 0x88, 0x09, 0x93, 0x93, 0x42, 0x00, 0xd0, 0xa2, 0xe1, + 0x08, 0xab, 0x5b, 0x8b, 0x67, 0x61, 0xe3, 0x81, 0x6b, 0x46, 0x1b, 0x8d, + 0x23, 0x82, 0x00, 0x2a, 0x00, 0xd0, 0x65, 0xe0, 0x06, 0x9b, 0x08, 0x9a, + 0x17, 0x33, 0x5b, 0x00, 0xd3, 0x18, 0x1a, 0x88, 0x0d, 0x92, 0x01, 0x22, + 0x52, 0x42, 0x1a, 0x80, 0x00, 0x23, 0x0c, 0x93, 0x09, 0x93, 0x0b, 0x9b, + 0x21, 0x1d, 0x00, 0x2b, 0x07, 0xd0, 0x07, 0x9b, 0x00, 0x2b, 0x04, 0xd1, + 0x0b, 0x9b, 0xfb, 0x1a, 0xfa, 0x2b, 0x00, 0xd8, 0xa6, 0xe0, 0x06, 0x9b, + 0x0d, 0x9a, 0x30, 0x00, 0xfe, 0xf7, 0xaa, 0xfb, 0x4e, 0x4b, 0x98, 0x42, + 0x59, 0xd1, 0xfb, 0x21, 0x38, 0x00, 0x01, 0xf0, 0x67, 0xfc, 0x00, 0x29, + 0x00, 0xd1, 0x89, 0xe0, 0x7f, 0x1a, 0x88, 0xe0, 0x07, 0x9b, 0x00, 0x2b, + 0x00, 0xd0, 0x28, 0xe7, 0xfb, 0x21, 0x30, 0x00, 0x49, 0x00, 0xfd, 0xf7, + 0xbb, 0xfe, 0x05, 0x1e, 0x00, 0xdb, 0x20, 0xe7, 0x28, 0x00, 0x13, 0xb0, + 0xf0, 0xbd, 0x78, 0x1e, 0xfb, 0x21, 0x01, 0xf0, 0xc9, 0xfb, 0x83, 0xb2, + 0x06, 0x93, 0x7b, 0x1c, 0x00, 0xd0, 0x1e, 0xe7, 0x00, 0x27, 0x1c, 0xe7, + 0x0f, 0xa9, 0x04, 0x91, 0x07, 0x99, 0xa3, 0x89, 0x02, 0x91, 0x01, 0x91, + 0x00, 0x91, 0xe2, 0x88, 0x03, 0x97, 0x21, 0x00, 0x30, 0x00, 0xff, 0xf7, + 0xd7, 0xf8, 0x05, 0x1e, 0x00, 0xdb, 0x6c, 0xe7, 0xe0, 0xe7, 0x80, 0x23, + 0xe1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1a, 0x23, 0x08, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x0a, 0x9a, 0x00, 0x23, 0x30, 0x00, 0xfe, 0xf7, 0xfe, 0xfd, + 0x05, 0x1e, 0x00, 0xdb, 0x65, 0xe7, 0xcf, 0xe7, 0x06, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x06, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0x1d, 0xfc, 0x04, 0x31, 0x08, 0x9b, 0x49, 0x00, 0x59, 0x18, 0x0b, 0x88, + 0x0d, 0x93, 0x01, 0x23, 0x5b, 0x42, 0x0b, 0x80, 0x0a, 0x9b, 0x0c, 0x93, + 0x91, 0xe7, 0x00, 0x28, 0x2c, 0xd0, 0x20, 0x4b, 0x98, 0x42, 0xa0, 0xd0, + 0x08, 0xab, 0x5d, 0x8b, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0xcf, 0xe0, + 0x00, 0x2f, 0x00, 0xd0, 0xc4, 0xe0, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd1, + 0xa7, 0xe0, 0x2a, 0x00, 0x3b, 0x00, 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, + 0xe1, 0xf9, 0x05, 0x1e, 0xa0, 0xdb, 0x08, 0xab, 0x59, 0x8b, 0x30, 0x00, + 0xfe, 0xf7, 0xb8, 0xfe, 0x05, 0x1e, 0x00, 0xda, 0x98, 0xe7, 0x02, 0x97, + 0x08, 0xaa, 0x52, 0x8b, 0xe3, 0x88, 0x01, 0x92, 0x00, 0x97, 0x02, 0x22, + 0x39, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0x58, 0xff, 0xa7, 0x60, 0x8b, 0xe7, + 0x0d, 0x99, 0x30, 0x00, 0xfe, 0xf7, 0xa4, 0xfe, 0x00, 0x28, 0x00, 0xd1, + 0x6f, 0xe7, 0xcd, 0xe7, 0xfb, 0x3f, 0x06, 0x98, 0xa7, 0x60, 0x01, 0x38, + 0x83, 0xb2, 0x67, 0x61, 0x06, 0x93, 0xc3, 0xe6, 0xff, 0xff, 0x00, 0x00, + 0xec, 0xd8, 0xff, 0xff, 0xe1, 0xd8, 0xff, 0xff, 0x06, 0x9b, 0x0d, 0x9a, + 0x30, 0x00, 0xfe, 0xf7, 0x03, 0xfb, 0x00, 0x28, 0xb8, 0xd1, 0x6a, 0x46, + 0xe1, 0x88, 0x12, 0x8b, 0x49, 0x04, 0x08, 0xab, 0x49, 0x0c, 0x5a, 0x84, + 0x19, 0x84, 0xff, 0x23, 0x24, 0x30, 0x08, 0xaa, 0x12, 0x18, 0x13, 0x70, + 0x08, 0xaa, 0xe1, 0x3b, 0x9b, 0x18, 0x03, 0x93, 0x07, 0x9b, 0x10, 0xaa, + 0x02, 0x93, 0x01, 0x93, 0x00, 0x93, 0x30, 0x00, 0xfe, 0xf7, 0xf0, 0xfd, + 0x00, 0x28, 0x9d, 0xd1, 0x0d, 0x9b, 0xfb, 0x21, 0x1b, 0x02, 0x05, 0x33, + 0x0a, 0x93, 0x0b, 0x98, 0x08, 0xab, 0xdd, 0x8b, 0x01, 0xf0, 0xa0, 0xfb, + 0x2d, 0x02, 0x05, 0x35, 0x00, 0x91, 0x0a, 0x9b, 0x2a, 0x00, 0x07, 0x99, + 0x30, 0x00, 0xfe, 0xf7, 0x65, 0xfb, 0x00, 0x28, 0x00, 0xd0, 0x87, 0xe7, + 0x0d, 0x99, 0x30, 0x00, 0xfe, 0xf7, 0x56, 0xfe, 0x00, 0x28, 0x00, 0xd0, + 0x80, 0xe7, 0x24, 0x21, 0x02, 0x22, 0x08, 0xab, 0x5b, 0x18, 0x1b, 0x78, + 0x30, 0x00, 0x93, 0x43, 0x08, 0xaa, 0x52, 0x18, 0x13, 0x70, 0x04, 0x21, + 0x62, 0x5e, 0x08, 0xab, 0x11, 0xa9, 0xdb, 0x8b, 0x01, 0x91, 0x01, 0x21, + 0x1b, 0x02, 0x00, 0x91, 0x04, 0x33, 0x06, 0x31, 0xfc, 0xf7, 0x79, 0xf9, + 0x00, 0x28, 0x00, 0xd0, 0x66, 0xe7, 0x08, 0xab, 0xdd, 0x8b, 0x09, 0x9b, + 0x00, 0x2b, 0x09, 0xd1, 0x06, 0x98, 0x17, 0x30, 0x08, 0x9b, 0x40, 0x00, + 0x1d, 0x52, 0x0b, 0x9b, 0xa3, 0x60, 0x63, 0x61, 0x1f, 0x00, 0x57, 0xe7, + 0x06, 0x9b, 0x68, 0x2b, 0x02, 0xd8, 0x18, 0x00, 0x04, 0x30, 0xf1, 0xe7, + 0x06, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0x59, 0xfb, 0x08, 0x1d, + 0xea, 0xe7, 0x70, 0x6a, 0xd2, 0x22, 0x2e, 0x30, 0xff, 0x21, 0x01, 0xf0, + 0x84, 0xfb, 0x0f, 0xab, 0x04, 0x93, 0x01, 0x23, 0xe2, 0x88, 0x5b, 0x42, + 0x03, 0x93, 0x02, 0x97, 0x01, 0x97, 0x73, 0x6a, 0x00, 0x93, 0x2b, 0x00, + 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0xde, 0xff, 0x05, 0x1e, 0x00, 0xdb, + 0x5a, 0xe7, 0xe7, 0xe6, 0x0f, 0xab, 0x04, 0x93, 0x09, 0x9b, 0xe2, 0x88, + 0x03, 0x97, 0x02, 0x93, 0x01, 0x93, 0xec, 0xe7, 0x2a, 0x00, 0x09, 0x9b, + 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0x18, 0xf9, 0x05, 0x1e, 0x00, 0xda, + 0xd6, 0xe6, 0x00, 0x25, 0x04, 0x22, 0xa1, 0x5e, 0x10, 0xaa, 0x02, 0x92, + 0x08, 0xaa, 0x52, 0x8b, 0xe3, 0x88, 0x01, 0x92, 0x00, 0x95, 0x08, 0x9a, + 0x30, 0x00, 0xfe, 0xf7, 0x15, 0xfe, 0x05, 0x1e, 0x00, 0xda, 0xc5, 0xe6, + 0x00, 0x25, 0x08, 0xaa, 0x02, 0x95, 0x12, 0x8c, 0xe3, 0x88, 0x01, 0x92, + 0x08, 0x9a, 0x30, 0x00, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, + 0x00, 0x92, 0x08, 0x99, 0x2a, 0x00, 0xfe, 0xf7, 0x7f, 0xfe, 0x08, 0xab, + 0x1b, 0x8c, 0x0f, 0xa9, 0xe3, 0x81, 0x6b, 0x46, 0x9b, 0x8c, 0x67, 0x61, + 0x23, 0x82, 0xe2, 0x88, 0xa3, 0x89, 0x04, 0x91, 0x03, 0x97, 0x02, 0x95, + 0x01, 0x95, 0x00, 0x95, 0xb4, 0xe7, 0x0a, 0x4d, 0xa2, 0xe6, 0x0a, 0x4d, + 0xa0, 0xe6, 0x0a, 0x4d, 0x9e, 0xe6, 0x0a, 0x4d, 0x9c, 0xe6, 0x0a, 0x4d, + 0x9a, 0xe6, 0x00, 0x23, 0x0a, 0x93, 0x0c, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0xf1, 0xe5, 0x5d, 0xe6, 0x0a, 0x9b, 0x09, 0x93, 0xc4, 0xe6, 0xc0, 0x46, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x8f, 0xb0, + 0x07, 0x91, 0x08, 0x93, 0x03, 0x68, 0x04, 0x00, 0xfb, 0x21, 0x07, 0x98, + 0x04, 0x93, 0x0b, 0x92, 0x01, 0xf0, 0x4a, 0xfa, 0x87, 0xb2, 0x00, 0x20, + 0x04, 0x9b, 0x5b, 0x6a, 0x06, 0x93, 0x07, 0x9b, 0x03, 0x93, 0x6b, 0x4b, + 0x05, 0x93, 0x0b, 0x9a, 0x07, 0x9b, 0x94, 0x46, 0x03, 0x9a, 0x63, 0x44, + 0x0a, 0x93, 0x93, 0x42, 0x3a, 0xd9, 0xe2, 0x6a, 0x00, 0x2a, 0x0c, 0xd0, + 0x13, 0x89, 0xbb, 0x42, 0x09, 0xd8, 0x51, 0x89, 0xb9, 0x42, 0x06, 0xd3, + 0xfb, 0x1a, 0x12, 0x68, 0x5b, 0x00, 0x9d, 0x5a, 0x00, 0x2d, 0x00, 0xd0, + 0x82, 0xe0, 0x68, 0x2f, 0x3d, 0xd9, 0x38, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x01, 0xf0, 0x22, 0xfa, 0x05, 0x9b, 0x01, 0x30, 0x85, 0xb2, 0xab, 0x42, + 0x06, 0xd1, 0x38, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0x9e, 0xfa, + 0x04, 0x31, 0x1c, 0xe0, 0x23, 0x8a, 0xab, 0x42, 0x05, 0xd1, 0x0e, 0x23, + 0xe2, 0x89, 0x0a, 0xa9, 0x5b, 0x18, 0x1a, 0x80, 0x2c, 0xe0, 0x80, 0x23, + 0xe1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x0e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x2a, 0x00, 0x00, 0x23, 0x04, 0x98, 0xfe, 0xf7, 0x5a, 0xfc, + 0x00, 0x28, 0x1d, 0xda, 0x0f, 0xb0, 0xf0, 0xbd, 0x39, 0x1d, 0x68, 0x2f, + 0xdb, 0xd8, 0x06, 0x9b, 0x49, 0x00, 0x5d, 0x5a, 0x4e, 0xe0, 0x45, 0x48, + 0xf4, 0xe7, 0x45, 0x48, 0xf2, 0xe7, 0x45, 0x48, 0xf0, 0xe7, 0x45, 0x48, + 0xee, 0xe7, 0x45, 0x48, 0xec, 0xe7, 0x45, 0x48, 0xea, 0xe7, 0x05, 0x9b, + 0x00, 0x2b, 0x38, 0xd0, 0x0e, 0x23, 0x00, 0x25, 0xa2, 0x89, 0x0a, 0xa9, + 0x5b, 0x18, 0x1a, 0x80, 0x0e, 0x26, 0x04, 0x21, 0x62, 0x5e, 0x04, 0x99, + 0x0a, 0xab, 0x49, 0x6a, 0xf6, 0x18, 0x33, 0x88, 0x05, 0x91, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x04, 0x98, + 0xfb, 0xf7, 0xf3, 0xff, 0x00, 0x28, 0xcd, 0xdb, 0x01, 0x22, 0x06, 0x9b, + 0x1b, 0x79, 0x13, 0x42, 0xd1, 0xd1, 0x5a, 0xb2, 0x00, 0x2a, 0xd0, 0xda, + 0x9a, 0x07, 0xd0, 0xd4, 0x5b, 0x07, 0xd0, 0xd4, 0x06, 0x22, 0xa3, 0x5e, + 0x00, 0x2b, 0xcc, 0xda, 0x06, 0x9b, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, + 0x13, 0x43, 0x05, 0x93, 0xab, 0x42, 0xc6, 0xd1, 0x03, 0x9b, 0x25, 0x82, + 0x63, 0x61, 0x33, 0x88, 0xe3, 0x81, 0x00, 0x2d, 0xb0, 0xd1, 0x3b, 0x00, + 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9d, 0x5a, 0x00, 0x23, 0x05, 0x93, + 0xfb, 0x21, 0x03, 0x98, 0x01, 0xf0, 0x28, 0xfa, 0x0a, 0x9b, 0x03, 0x9a, + 0x09, 0x91, 0x9a, 0x1a, 0x03, 0x99, 0xa3, 0x68, 0x5b, 0x1a, 0x93, 0x42, + 0x00, 0xd9, 0x13, 0x00, 0xfb, 0x26, 0x09, 0x9a, 0xb6, 0x1a, 0x9e, 0x42, + 0x00, 0xd9, 0x1e, 0x00, 0x00, 0x2e, 0xa4, 0xd0, 0x21, 0x1d, 0x3b, 0x00, + 0x2a, 0x00, 0x04, 0x98, 0xfe, 0xf7, 0x4c, 0xf9, 0x00, 0x28, 0x00, 0xda, + 0x88, 0xe7, 0x09, 0x9b, 0x04, 0x21, 0x62, 0x5e, 0x08, 0x99, 0x2d, 0x02, + 0x05, 0x33, 0x01, 0x91, 0xeb, 0x18, 0x00, 0x96, 0x17, 0x21, 0x04, 0x98, + 0xfb, 0xf7, 0x9f, 0xff, 0x00, 0x28, 0x00, 0xda, 0x78, 0xe7, 0x08, 0x9b, + 0x01, 0x37, 0x9b, 0x19, 0x08, 0x93, 0x03, 0x9b, 0xbf, 0xb2, 0x9b, 0x19, + 0x03, 0x93, 0x63, 0x61, 0x2b, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x0f, 0x23, 0x8d, 0xb0, 0x06, 0x91, 0x01, 0x21, 0x07, 0x92, + 0xc2, 0x68, 0x05, 0x00, 0x53, 0x43, 0x5b, 0x08, 0x09, 0xaa, 0x5b, 0x18, + 0x11, 0x80, 0x99, 0xb2, 0x1b, 0x04, 0x3c, 0xd4, 0x51, 0x80, 0x00, 0x23, + 0x53, 0x60, 0x07, 0x9b, 0x93, 0x60, 0x09, 0xac, 0x23, 0x88, 0x68, 0x6a, + 0x9c, 0x46, 0x62, 0x46, 0x63, 0x88, 0x9b, 0x1a, 0x80, 0x22, 0x12, 0x01, + 0x93, 0x42, 0x37, 0xdc, 0x80, 0x22, 0x00, 0x21, 0x52, 0x00, 0x01, 0xf0, + 0xf2, 0xf9, 0x00, 0x21, 0x07, 0x9b, 0x05, 0x91, 0x02, 0x93, 0x3d, 0x4b, + 0x04, 0x91, 0x01, 0x93, 0x03, 0x94, 0x0b, 0x00, 0x00, 0x91, 0x0a, 0x00, + 0x28, 0x00, 0xfe, 0xf7, 0xa9, 0xf9, 0x39, 0x4b, 0x98, 0x42, 0x01, 0xd0, + 0x00, 0x28, 0x12, 0xdb, 0x80, 0x26, 0x00, 0x22, 0x01, 0x23, 0x6f, 0x6a, + 0x76, 0x00, 0xbd, 0x5c, 0xff, 0x2d, 0x12, 0xd0, 0x00, 0x21, 0x28, 0x00, + 0x08, 0x41, 0x18, 0x40, 0x0a, 0xd1, 0x23, 0x88, 0xd2, 0x00, 0x59, 0x18, + 0x06, 0x9b, 0x8a, 0x18, 0x1a, 0x80, 0x0d, 0xb0, 0xf0, 0xbd, 0x2d, 0x4b, + 0x53, 0x80, 0xc0, 0xe7, 0x01, 0x31, 0x08, 0x29, 0xed, 0xd1, 0x01, 0x32, + 0xb2, 0x42, 0xe6, 0xd1, 0x29, 0x48, 0xf2, 0xe7, 0x62, 0x68, 0x00, 0x2a, + 0x1d, 0xd1, 0x09, 0xac, 0x22, 0x88, 0x63, 0x88, 0x00, 0x26, 0x9b, 0x1a, + 0x80, 0x22, 0x1b, 0x0a, 0x52, 0x00, 0x00, 0x21, 0x63, 0x60, 0x01, 0xf0, + 0xb0, 0xf9, 0x22, 0x4b, 0x05, 0x96, 0x01, 0x93, 0x04, 0x96, 0x33, 0x00, + 0x03, 0x96, 0x02, 0x94, 0x00, 0x96, 0x32, 0x00, 0x31, 0x00, 0x28, 0x00, + 0xfe, 0xf7, 0x68, 0xf9, 0x18, 0x4b, 0x98, 0x42, 0x26, 0xd1, 0xa6, 0x60, + 0x9b, 0xe7, 0x00, 0x27, 0xff, 0x23, 0x39, 0x00, 0x46, 0x5c, 0x9e, 0x42, + 0x02, 0xd2, 0x33, 0x1e, 0x06, 0xd0, 0x0f, 0x00, 0x80, 0x26, 0x01, 0x31, + 0x76, 0x00, 0xb1, 0x42, 0xf4, 0xd1, 0x39, 0x00, 0x9a, 0x42, 0xcb, 0xd0, + 0x92, 0xb2, 0x51, 0x43, 0x61, 0x44, 0x89, 0xb2, 0x00, 0x2b, 0x03, 0xd1, + 0x06, 0x9a, 0x18, 0x00, 0x11, 0x80, 0xb6, 0xe7, 0x80, 0x23, 0x52, 0x18, + 0x92, 0xb2, 0x62, 0x80, 0x21, 0x80, 0x52, 0x1a, 0x1b, 0x01, 0x9a, 0x42, + 0xbd, 0xdc, 0x76, 0xe7, 0x00, 0x28, 0xaa, 0xdb, 0xa6, 0x60, 0x00, 0xd1, + 0x71, 0xe7, 0xa6, 0xe7, 0x31, 0x49, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xff, 0x7f, 0x00, 0x00, 0xef, 0xd8, 0xff, 0xff, 0x6d, 0x4b, 0x00, 0x00, + 0xf0, 0xb5, 0x85, 0xb0, 0x05, 0x00, 0x03, 0x91, 0x14, 0x00, 0x10, 0x1e, + 0x01, 0xd0, 0xfe, 0xf7, 0x57, 0xf8, 0xeb, 0x6a, 0xae, 0x6a, 0x02, 0x93, + 0x00, 0x2c, 0x07, 0xd0, 0x30, 0x23, 0x02, 0x99, 0x32, 0x1d, 0x4b, 0x43, + 0xf3, 0x18, 0x04, 0x33, 0x93, 0x42, 0x0e, 0xd1, 0x2a, 0x4a, 0x01, 0x23, + 0x01, 0x92, 0x00, 0x22, 0x31, 0x1d, 0x5b, 0x42, 0x00, 0x92, 0x02, 0x9f, + 0x00, 0x9a, 0xba, 0x42, 0x0e, 0xd1, 0x5a, 0x1c, 0x21, 0xd1, 0x25, 0x48, + 0x3b, 0xe0, 0x00, 0x27, 0xd1, 0x5f, 0x00, 0x29, 0x04, 0xd1, 0x91, 0x8c, + 0x01, 0x29, 0x01, 0xd9, 0x01, 0x39, 0x91, 0x84, 0x30, 0x32, 0xe3, 0xe7, + 0x00, 0x22, 0x8f, 0x5e, 0x00, 0x2f, 0x0a, 0xd1, 0x00, 0x2c, 0x02, 0xd0, + 0x0f, 0x6a, 0x87, 0x42, 0x0a, 0xd0, 0x8f, 0x8c, 0x01, 0x9a, 0x97, 0x42, + 0x01, 0xd2, 0x00, 0x9b, 0x01, 0x97, 0x00, 0x9a, 0x30, 0x31, 0x01, 0x32, + 0x00, 0x92, 0xd8, 0xe7, 0x00, 0x9b, 0x30, 0x22, 0x5a, 0x43, 0xb6, 0x18, + 0x00, 0x2c, 0x11, 0xd0, 0x72, 0x6a, 0x82, 0x42, 0x19, 0xd1, 0x31, 0x8d, + 0x00, 0x29, 0x16, 0xd0, 0xb2, 0x89, 0x10, 0x09, 0x28, 0x83, 0x0f, 0x20, + 0x02, 0x40, 0x01, 0x3a, 0xea, 0x61, 0x0c, 0x4a, 0x91, 0x42, 0x08, 0xd8, + 0x04, 0x31, 0x31, 0x85, 0x00, 0x20, 0x01, 0x33, 0xb3, 0x80, 0x03, 0x9b, + 0x1e, 0x60, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x22, 0x52, 0x42, 0x32, 0x85, + 0xf4, 0xe7, 0x04, 0x22, 0x70, 0x62, 0x32, 0x85, 0xf0, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xe9, 0xd8, 0xff, 0xff, 0xfa, 0xff, 0x00, 0x00, + 0x00, 0x29, 0x10, 0xdd, 0x2c, 0x22, 0x83, 0x5e, 0x8b, 0x42, 0x0c, 0xdb, + 0x30, 0x23, 0x4b, 0x43, 0x81, 0x6a, 0x30, 0x3b, 0xc9, 0x18, 0x04, 0x22, + 0x8b, 0x5e, 0x00, 0x2b, 0x05, 0xd0, 0x00, 0x20, 0x88, 0x80, 0xc8, 0x62, + 0x70, 0x47, 0x02, 0x48, 0xfc, 0xe7, 0x02, 0x48, 0xfa, 0xe7, 0xc0, 0x46, + 0xe6, 0xd8, 0xff, 0xff, 0xe8, 0xd8, 0xff, 0xff, 0x10, 0xb5, 0x00, 0x29, + 0x11, 0xdd, 0x2c, 0x24, 0x03, 0x5f, 0x8b, 0x42, 0x0d, 0xdb, 0x30, 0x23, + 0x59, 0x43, 0x83, 0x6a, 0x30, 0x39, 0x59, 0x18, 0x11, 0x60, 0x04, 0x23, + 0xc8, 0x5e, 0x43, 0x42, 0x58, 0x41, 0x03, 0x4b, 0x40, 0x42, 0x18, 0x40, + 0x10, 0xbd, 0x02, 0x48, 0xfc, 0xe7, 0xc0, 0x46, 0xe8, 0xd8, 0xff, 0xff, + 0xe6, 0xd8, 0xff, 0xff, 0x03, 0x7d, 0x00, 0x2b, 0x04, 0xd1, 0x43, 0x75, + 0x83, 0x75, 0x83, 0x61, 0x01, 0x33, 0x03, 0x75, 0x70, 0x47, 0x7f, 0xb5, + 0xc3, 0x68, 0x02, 0xad, 0x04, 0x00, 0x0e, 0x00, 0x02, 0x91, 0x6a, 0x60, + 0x8b, 0x42, 0x03, 0xd1, 0x02, 0x8a, 0xab, 0x88, 0x9a, 0x42, 0x18, 0xd0, + 0x20, 0x00, 0x06, 0x22, 0x29, 0x00, 0x0c, 0x30, 0x01, 0xf0, 0x9a, 0xf8, + 0x20, 0x68, 0x00, 0xf0, 0x94, 0xf9, 0x6b, 0x79, 0x22, 0x7a, 0xe1, 0x79, + 0x00, 0x93, 0x20, 0x68, 0x00, 0x23, 0x00, 0xf0, 0x2d, 0xfa, 0x20, 0x68, + 0x29, 0x79, 0x32, 0x00, 0x00, 0xf0, 0x58, 0xf9, 0x20, 0x68, 0x00, 0xf0, + 0x7a, 0xf9, 0x7f, 0xbd, 0x70, 0xb5, 0x18, 0x26, 0x04, 0x00, 0xff, 0xf7, + 0xcb, 0xff, 0x33, 0x00, 0x08, 0x21, 0x20, 0x79, 0x0d, 0x4d, 0x43, 0x43, + 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x0e, 0xff, 0x33, 0x00, 0x08, 0x21, + 0xa0, 0x79, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x06, 0xff, + 0x08, 0x21, 0x60, 0x79, 0x46, 0x43, 0xad, 0x19, 0x69, 0x56, 0x00, 0xf0, + 0xff, 0xfe, 0x04, 0x4b, 0x20, 0x00, 0x06, 0xcb, 0xff, 0xf7, 0xb7, 0xff, + 0x70, 0xbd, 0xc0, 0x46, 0x20, 0x83, 0x00, 0x00, 0x18, 0x0c, 0x00, 0x20, + 0x07, 0xb5, 0x43, 0x7d, 0x00, 0x91, 0x01, 0x92, 0x00, 0x2b, 0x07, 0xd0, + 0x9a, 0x07, 0x0a, 0xd5, 0xef, 0xf3, 0x10, 0x83, 0x5a, 0x42, 0x53, 0x41, + 0x83, 0x75, 0x72, 0xb6, 0x00, 0x99, 0x01, 0x9a, 0xff, 0xf7, 0x9f, 0xff, + 0x07, 0xbd, 0xdb, 0x07, 0xf8, 0xd5, 0x83, 0x69, 0x01, 0x4a, 0x9b, 0xb2, + 0x93, 0x60, 0xf3, 0xe7, 0x00, 0x18, 0x00, 0x40, 0x10, 0xb5, 0x00, 0x68, + 0x00, 0xf0, 0x44, 0xf9, 0x10, 0xbd, 0x00, 0x00, 0x0a, 0x4b, 0x0b, 0x4a, + 0x0b, 0x49, 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x0a, 0x4b, + 0x19, 0x60, 0x0a, 0x49, 0xda, 0x60, 0x99, 0x80, 0x09, 0x21, 0x5a, 0x74, + 0x1a, 0x74, 0x1a, 0x75, 0xda, 0x71, 0x03, 0x32, 0x99, 0x71, 0x1a, 0x72, + 0x70, 0x47, 0xc0, 0x46, 0x18, 0x0c, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, + 0x9c, 0x10, 0x00, 0x20, 0xfc, 0x0b, 0x00, 0x20, 0x0a, 0x08, 0x00, 0x00, + 0x10, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x61, 0xfb, 0x10, 0xbd, 0xc0, 0x46, + 0x20, 0x0c, 0x00, 0x20, 0x10, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x59, 0xfb, + 0x10, 0xbd, 0xc0, 0x46, 0x5c, 0x0e, 0x00, 0x20, 0x7f, 0xb5, 0x19, 0x49, + 0x19, 0x48, 0x00, 0xf0, 0x4b, 0xf8, 0x19, 0x49, 0x19, 0x48, 0x00, 0xf0, + 0x47, 0xf8, 0x19, 0x49, 0x19, 0x48, 0x00, 0xf0, 0x43, 0xf8, 0x19, 0x49, + 0x19, 0x48, 0x00, 0xf0, 0x3f, 0xf8, 0x19, 0x4c, 0x19, 0x49, 0x20, 0x00, + 0x00, 0xf0, 0x3a, 0xf8, 0x18, 0x4e, 0x19, 0x49, 0x30, 0x00, 0x00, 0xf0, + 0x35, 0xf8, 0x01, 0x25, 0x03, 0x23, 0x31, 0x00, 0x01, 0x95, 0x00, 0x93, + 0x0d, 0x22, 0x0b, 0x33, 0x14, 0x48, 0x00, 0xf0, 0xc5, 0xfa, 0x1d, 0x23, + 0x03, 0x93, 0x01, 0x3b, 0x02, 0x93, 0x1a, 0x3b, 0x01, 0x93, 0x00, 0x95, + 0x18, 0x33, 0x1b, 0x22, 0x21, 0x00, 0x0f, 0x48, 0x00, 0xf0, 0x74, 0xfa, + 0x7f, 0xbd, 0xc0, 0x46, 0x00, 0x08, 0x00, 0x42, 0x98, 0x10, 0x00, 0x20, + 0x00, 0x0c, 0x00, 0x42, 0x9c, 0x10, 0x00, 0x20, 0x00, 0x10, 0x00, 0x42, + 0xa0, 0x10, 0x00, 0x20, 0x00, 0x14, 0x00, 0x42, 0xa4, 0x10, 0x00, 0x20, + 0xa8, 0x10, 0x00, 0x20, 0x00, 0x18, 0x00, 0x42, 0xac, 0x10, 0x00, 0x20, + 0x00, 0x1c, 0x00, 0x42, 0x20, 0x0c, 0x00, 0x20, 0x5c, 0x0e, 0x00, 0x20, + 0x01, 0x60, 0x70, 0x47, 0x94, 0x46, 0xf0, 0xb5, 0x9e, 0x1e, 0x72, 0x1e, + 0x96, 0x41, 0x62, 0x46, 0x05, 0x68, 0x92, 0x07, 0x2f, 0x68, 0x36, 0x06, + 0x3a, 0x43, 0x32, 0x43, 0x2a, 0x60, 0x07, 0x25, 0x05, 0xac, 0x24, 0x78, + 0x00, 0x68, 0xa4, 0x01, 0x29, 0x40, 0x21, 0x43, 0x42, 0x68, 0x00, 0x24, + 0x02, 0x2b, 0x00, 0xd0, 0x5c, 0x03, 0x11, 0x43, 0x21, 0x43, 0x41, 0x60, + 0xf0, 0xbd, 0x30, 0xb5, 0xc0, 0x25, 0x03, 0x68, 0xad, 0x03, 0x1c, 0x68, + 0x12, 0x05, 0x2a, 0x40, 0x22, 0x43, 0xc0, 0x24, 0x09, 0x04, 0xa4, 0x02, + 0x21, 0x40, 0x11, 0x43, 0x19, 0x60, 0x03, 0x68, 0x5a, 0x68, 0x14, 0x43, + 0x5c, 0x60, 0x30, 0xbd, 0x01, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, + 0x13, 0x60, 0x03, 0x68, 0x1a, 0x68, 0xd2, 0x07, 0xfc, 0xd4, 0xda, 0x69, + 0xd2, 0x07, 0xf9, 0xd4, 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, 0x11, 0x68, + 0x0b, 0x43, 0x13, 0x60, 0x02, 0x68, 0xd3, 0x69, 0x9b, 0x07, 0xfc, 0xd4, + 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, 0x02, 0xd4, 0x1a, 0x7e, + 0x92, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0x00, 0x22, 0x03, 0x68, 0x5a, 0x83, + 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x40, 0x07, 0xc0, 0x0f, 0x70, 0x47, + 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x09, 0x70, 0x47, 0x80, 0x23, 0x02, 0x68, + 0x5b, 0x42, 0x11, 0x7e, 0x0b, 0x43, 0x13, 0x76, 0x70, 0x47, 0x03, 0x68, + 0x58, 0x8b, 0x80, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, + 0x51, 0x8b, 0x0b, 0x43, 0x53, 0x83, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, + 0xc0, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x8d, 0xc0, 0xb2, + 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, 0xfc, 0xd5, 0x89, 0xb2, + 0x01, 0x20, 0x19, 0x85, 0x70, 0x47, 0x01, 0x22, 0x03, 0x68, 0x9a, 0x75, + 0x70, 0x47, 0x01, 0x22, 0x03, 0x68, 0x1a, 0x75, 0x70, 0x47, 0x00, 0x00, + 0x70, 0xb5, 0x01, 0x26, 0x04, 0x68, 0x4b, 0x08, 0x33, 0x40, 0x31, 0x40, + 0x25, 0x68, 0x09, 0x07, 0x5b, 0x07, 0x0b, 0x43, 0x2b, 0x43, 0x23, 0x60, + 0x04, 0x68, 0x51, 0x00, 0x03, 0x48, 0x00, 0xf0, 0x71, 0xfe, 0x01, 0x38, + 0xc0, 0xb2, 0x20, 0x73, 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x6c, 0xdc, 0x02, + 0x01, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, 0x03, 0x68, + 0x1a, 0x68, 0xd2, 0x07, 0xfc, 0xd4, 0xda, 0x69, 0xd2, 0x07, 0xf9, 0xd4, + 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, + 0x02, 0x68, 0xd3, 0x69, 0x9b, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, + 0xda, 0x69, 0x92, 0x07, 0xfc, 0xd4, 0x02, 0x21, 0x1a, 0x68, 0x8a, 0x43, + 0x1a, 0x60, 0x70, 0x47, 0x02, 0x68, 0x93, 0x6a, 0x5b, 0x0a, 0x5b, 0x02, + 0x19, 0x43, 0x91, 0x62, 0x03, 0x68, 0x1a, 0x7e, 0x52, 0x07, 0xfc, 0xd5, + 0x98, 0x6a, 0xc0, 0xb2, 0x70, 0x47, 0x00, 0x00, 0x03, 0x68, 0x21, 0x4a, + 0x30, 0xb5, 0x93, 0x42, 0x2f, 0xd0, 0x20, 0x4a, 0x93, 0x42, 0x2f, 0xd0, + 0x1f, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x2f, 0xd0, + 0x1e, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1e, 0x4a, 0x93, 0x42, 0x1f, 0xd1, + 0x0e, 0x23, 0x19, 0x22, 0x01, 0x21, 0x03, 0x25, 0x99, 0x40, 0x1b, 0x48, + 0xc0, 0x24, 0x01, 0x60, 0x99, 0x08, 0x2b, 0x40, 0xab, 0x40, 0xfc, 0x35, + 0x9d, 0x40, 0x89, 0x00, 0x09, 0x18, 0xa4, 0x00, 0x08, 0x59, 0xa8, 0x43, + 0xc0, 0x25, 0x9d, 0x40, 0x2b, 0x00, 0x03, 0x43, 0x0b, 0x51, 0x80, 0x23, + 0xdb, 0x01, 0x1a, 0x43, 0x11, 0x4b, 0x5a, 0x80, 0x5a, 0x78, 0x52, 0xb2, + 0x00, 0x2a, 0xfb, 0xdb, 0x30, 0xbd, 0x09, 0x23, 0x14, 0x22, 0xdd, 0xe7, + 0x0a, 0x23, 0x15, 0x22, 0xda, 0xe7, 0x0b, 0x23, 0x16, 0x22, 0xd7, 0xe7, + 0x0c, 0x23, 0x17, 0x22, 0xd4, 0xe7, 0x0d, 0x23, 0x18, 0x22, 0xd1, 0xe7, + 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, 0x00, 0x10, 0x00, 0x42, + 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, 0x00, 0x1c, 0x00, 0x42, + 0x00, 0xe1, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x40, 0xf8, 0xb5, 0x04, 0x00, + 0x0f, 0x00, 0x16, 0x00, 0x1d, 0x00, 0xff, 0xf7, 0xa5, 0xff, 0x20, 0x00, + 0xff, 0xf7, 0x04, 0xff, 0x1c, 0x21, 0xbb, 0x00, 0x0b, 0x40, 0x71, 0x07, + 0x22, 0x68, 0x09, 0x0c, 0x0b, 0x43, 0x13, 0x60, 0x84, 0x23, 0x22, 0x68, + 0x93, 0x75, 0x01, 0x2f, 0x1a, 0xd1, 0x10, 0x21, 0x01, 0x2e, 0x00, 0xd0, + 0x08, 0x39, 0x0c, 0x4b, 0x69, 0x43, 0x18, 0x68, 0xc0, 0x00, 0x00, 0xf0, + 0xc7, 0xfd, 0x07, 0x22, 0x21, 0x68, 0x02, 0x40, 0x8b, 0x89, 0x52, 0x03, + 0xdb, 0x04, 0xdb, 0x0c, 0x13, 0x43, 0x8b, 0x81, 0x22, 0x68, 0x03, 0x04, + 0x90, 0x89, 0xdb, 0x0c, 0x40, 0x0b, 0x40, 0x03, 0x18, 0x43, 0x90, 0x81, + 0xf8, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, 0xf7, 0xb5, 0x06, 0x00, + 0x01, 0x93, 0x08, 0xab, 0x1f, 0x78, 0x0d, 0x00, 0x14, 0x00, 0xff, 0xf7, + 0x3f, 0xff, 0x30, 0x00, 0xff, 0xf7, 0x6a, 0xff, 0xc0, 0x22, 0x24, 0x05, + 0x92, 0x03, 0x14, 0x40, 0xba, 0x07, 0x0c, 0x27, 0x17, 0x43, 0x3c, 0x43, + 0xc0, 0x27, 0x07, 0x22, 0xbf, 0x02, 0x2d, 0x04, 0x33, 0x68, 0x3d, 0x40, + 0x25, 0x43, 0x1d, 0x60, 0x01, 0x9b, 0x31, 0x68, 0x13, 0x40, 0x1a, 0x00, + 0x80, 0x23, 0x9b, 0x02, 0x13, 0x43, 0x4b, 0x60, 0xf7, 0xbd, 0x01, 0x20, + 0x70, 0x47, 0x00, 0x00, 0x10, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, + 0x98, 0x47, 0x10, 0xbd, 0x13, 0x04, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, + 0xd9, 0x69, 0x9a, 0x69, 0x91, 0x42, 0x03, 0xd0, 0xdb, 0x69, 0xc0, 0x18, + 0x00, 0x7d, 0x70, 0x47, 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, 0x10, 0xb5, + 0x04, 0x00, 0x00, 0x69, 0xff, 0xf7, 0x96, 0xfe, 0x22, 0x00, 0x00, 0x23, + 0xfc, 0x32, 0x93, 0x61, 0xd3, 0x61, 0x86, 0x22, 0x92, 0x00, 0xa4, 0x18, + 0x63, 0x60, 0xa3, 0x60, 0x10, 0xbd, 0xf0, 0x20, 0x01, 0x40, 0x30, 0x39, + 0x48, 0x42, 0x48, 0x41, 0x70, 0x47, 0xf0, 0x23, 0x1b, 0x01, 0x19, 0x40, + 0x80, 0x23, 0x06, 0x20, 0x9b, 0x00, 0x99, 0x42, 0x0a, 0xd0, 0x01, 0x33, + 0xff, 0x33, 0x01, 0x30, 0x99, 0x42, 0x05, 0xd0, 0x80, 0x23, 0x02, 0x38, + 0x5b, 0x00, 0x99, 0x42, 0x00, 0xd0, 0x00, 0x20, 0x70, 0x47, 0x0f, 0x20, + 0x01, 0x40, 0x00, 0x20, 0x01, 0x29, 0x03, 0xd0, 0x02, 0x39, 0x48, 0x1e, + 0x81, 0x41, 0x48, 0x1c, 0x70, 0x47, 0x00, 0x00, 0x89, 0x23, 0xf0, 0xb5, + 0x18, 0x26, 0x85, 0xb0, 0x02, 0x91, 0x9b, 0x00, 0x04, 0x00, 0xc0, 0x5c, + 0x33, 0x00, 0x08, 0x21, 0x43, 0x43, 0x32, 0x4d, 0x17, 0x00, 0xeb, 0x18, + 0x59, 0x56, 0x00, 0xf0, 0x75, 0xfc, 0x30, 0x4b, 0x08, 0x21, 0xe0, 0x5c, + 0x33, 0x00, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x6c, 0xfc, + 0x2c, 0x4b, 0xe2, 0x5c, 0x03, 0x93, 0x02, 0x2a, 0x09, 0xd1, 0x11, 0x33, + 0xe0, 0x5c, 0xff, 0x28, 0x05, 0xd0, 0x08, 0x21, 0x46, 0x43, 0xae, 0x19, + 0x71, 0x56, 0x00, 0xf0, 0x5d, 0xfc, 0x8a, 0x26, 0xb6, 0x00, 0xa0, 0x5d, + 0xff, 0x28, 0x19, 0xd0, 0x01, 0x21, 0x00, 0xf0, 0xdd, 0xfb, 0x18, 0x22, + 0xa3, 0x5d, 0x21, 0x49, 0x5a, 0x43, 0xab, 0x56, 0xad, 0x18, 0xdb, 0x01, + 0x58, 0x18, 0x8b, 0x21, 0x89, 0x00, 0x60, 0x50, 0x1d, 0x49, 0x01, 0x22, + 0x5b, 0x18, 0x8c, 0x21, 0x89, 0x00, 0x63, 0x50, 0x69, 0x68, 0x8a, 0x40, + 0x8d, 0x21, 0x89, 0x00, 0x62, 0x50, 0x1a, 0x60, 0x01, 0x22, 0x02, 0x9b, + 0x11, 0x00, 0x20, 0x69, 0xff, 0xf7, 0x0a, 0xff, 0x39, 0x00, 0x20, 0x00, + 0xff, 0xf7, 0x8f, 0xff, 0x39, 0x00, 0x05, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0x9e, 0xff, 0x39, 0x00, 0x06, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x7f, 0xff, + 0x33, 0x00, 0x00, 0x90, 0x29, 0x00, 0x20, 0x69, 0x01, 0x22, 0xff, 0xf7, + 0xd3, 0xfd, 0x0b, 0x4b, 0x20, 0x69, 0xe2, 0x5c, 0x03, 0x9b, 0xe1, 0x5c, + 0xff, 0xf7, 0xe9, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x06, 0xfe, 0x05, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x20, 0x83, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, + 0x27, 0x02, 0x00, 0x00, 0x18, 0x44, 0x00, 0x41, 0x14, 0x44, 0x00, 0x41, + 0x26, 0x02, 0x00, 0x00, 0x80, 0x22, 0x10, 0xb5, 0x04, 0x00, 0x52, 0x00, + 0x00, 0x21, 0x00, 0xf0, 0x76, 0xfd, 0x23, 0x00, 0x00, 0x22, 0xfc, 0x33, + 0x5a, 0x60, 0x20, 0x00, 0x9a, 0x60, 0x10, 0xbd, 0xf0, 0xb5, 0x85, 0xb0, + 0x1d, 0x00, 0x0a, 0xab, 0x1b, 0x78, 0x04, 0x00, 0x00, 0x93, 0x0b, 0xab, + 0x1b, 0x78, 0x16, 0x00, 0x01, 0x93, 0x0c, 0xab, 0x1b, 0x78, 0x0f, 0x00, + 0x02, 0x93, 0x0d, 0xab, 0x1b, 0x78, 0x03, 0x93, 0x00, 0x23, 0x43, 0x60, + 0xfa, 0x23, 0x9b, 0x00, 0x83, 0x60, 0x12, 0x4b, 0x08, 0x33, 0x03, 0x60, + 0x14, 0x30, 0xff, 0xf7, 0xd5, 0xff, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0xd0, 0xff, 0x89, 0x23, 0x6a, 0x46, 0x9b, 0x00, 0x27, 0x61, + 0xe6, 0x54, 0x0b, 0x4b, 0x12, 0x78, 0xe5, 0x54, 0x0a, 0x4b, 0x20, 0x00, + 0xe2, 0x54, 0x6a, 0x46, 0x09, 0x4b, 0x12, 0x79, 0xe2, 0x54, 0x6a, 0x46, + 0x12, 0x7a, 0x01, 0x33, 0xe2, 0x54, 0x6a, 0x46, 0x12, 0x7b, 0x10, 0x33, + 0xe2, 0x54, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0x80, 0x86, 0x00, 0x00, + 0x25, 0x02, 0x00, 0x00, 0x26, 0x02, 0x00, 0x00, 0x27, 0x02, 0x00, 0x00, + 0xf7, 0xb5, 0x1d, 0x00, 0x08, 0xab, 0x1b, 0x78, 0x04, 0x00, 0x00, 0x93, + 0x09, 0xab, 0x1b, 0x78, 0x16, 0x00, 0x01, 0x93, 0x00, 0x23, 0x43, 0x60, + 0xfa, 0x23, 0x9b, 0x00, 0x83, 0x60, 0x11, 0x4b, 0x0f, 0x00, 0x08, 0x33, + 0x03, 0x60, 0x14, 0x30, 0xff, 0xf7, 0x98, 0xff, 0x20, 0x00, 0x1d, 0x30, + 0xff, 0x30, 0xff, 0xf7, 0x93, 0xff, 0x89, 0x23, 0x6a, 0x46, 0x9b, 0x00, + 0x27, 0x61, 0xe6, 0x54, 0x09, 0x4b, 0x12, 0x78, 0xe5, 0x54, 0x09, 0x4b, + 0x20, 0x00, 0xe2, 0x54, 0x6a, 0x46, 0x08, 0x4b, 0x12, 0x79, 0xe2, 0x54, + 0x8a, 0x22, 0x29, 0x3b, 0xff, 0x3b, 0x92, 0x00, 0xa3, 0x54, 0x10, 0x32, + 0xa3, 0x54, 0xfe, 0xbd, 0x80, 0x86, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, + 0x26, 0x02, 0x00, 0x00, 0x27, 0x02, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, + 0x58, 0x68, 0x9b, 0x68, 0xc0, 0x1a, 0x01, 0xd5, 0x01, 0x30, 0xff, 0x30, + 0x70, 0x47, 0x10, 0xb5, 0x04, 0x00, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0xf0, 0xff, 0x00, 0x28, 0xf8, 0xd1, 0x20, 0x69, 0xff, 0xf7, + 0x60, 0xfd, 0x10, 0xbd, 0x10, 0xb5, 0x14, 0x30, 0xff, 0xf7, 0xe6, 0xff, + 0x10, 0xbd, 0x03, 0x00, 0xfc, 0x33, 0x59, 0x68, 0x9a, 0x68, 0x91, 0x42, + 0x04, 0xdb, 0x5a, 0x68, 0x98, 0x68, 0x80, 0x1a, 0xff, 0x30, 0x70, 0x47, + 0x98, 0x68, 0x5b, 0x68, 0xc0, 0x1a, 0x01, 0x38, 0xf9, 0xe7, 0x10, 0xb5, + 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0xeb, 0xff, 0x10, 0xbd, 0x10, 0xb5, + 0x04, 0x00, 0x00, 0x69, 0xff, 0xf7, 0x5b, 0xfd, 0x00, 0x28, 0x05, 0xd0, + 0x20, 0x69, 0xff, 0xf7, 0x66, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x58, 0xfd, + 0x20, 0x69, 0xff, 0xf7, 0x40, 0xfd, 0x00, 0x28, 0x20, 0xd0, 0x20, 0x69, + 0xff, 0xf7, 0x5b, 0xfd, 0x22, 0x00, 0xfc, 0x32, 0x93, 0x69, 0xd1, 0x69, + 0x01, 0x33, 0xdb, 0xb2, 0x8b, 0x42, 0x03, 0xd0, 0x91, 0x69, 0x61, 0x18, + 0x08, 0x75, 0x93, 0x61, 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, + 0x0c, 0xd0, 0x20, 0x00, 0x14, 0x30, 0xff, 0xf7, 0xc0, 0xff, 0x09, 0x28, + 0x06, 0xdc, 0x8b, 0x23, 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, + 0xa2, 0x58, 0x1a, 0x60, 0x20, 0x69, 0xff, 0xf7, 0x35, 0xfd, 0x00, 0x28, + 0x1a, 0xd0, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0x92, 0xff, + 0x00, 0x28, 0x22, 0xd0, 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x99, 0x68, + 0x5a, 0x68, 0x91, 0x42, 0x18, 0xd0, 0x8e, 0x21, 0x9a, 0x68, 0x49, 0x00, + 0xa2, 0x18, 0x51, 0x5c, 0x9a, 0x68, 0x01, 0x32, 0xd2, 0xb2, 0x9a, 0x60, + 0xc9, 0xb2, 0x20, 0x69, 0xff, 0xf7, 0x21, 0xfd, 0x20, 0x69, 0xff, 0xf7, + 0xff, 0xfc, 0x00, 0x28, 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0xfe, 0xfc, + 0x20, 0x69, 0xff, 0xf7, 0xee, 0xfc, 0x10, 0xbd, 0x01, 0x21, 0x49, 0x42, + 0xec, 0xe7, 0x20, 0x69, 0xff, 0xf7, 0x1b, 0xfd, 0xec, 0xe7, 0x00, 0x00, + 0x70, 0xb5, 0x04, 0x00, 0x00, 0x69, 0x0d, 0x00, 0xff, 0xf7, 0xfe, 0xfc, + 0x00, 0x28, 0x3e, 0xd1, 0xff, 0x26, 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, + 0x5a, 0x68, 0x99, 0x68, 0x01, 0x32, 0x32, 0x40, 0x8a, 0x42, 0x23, 0xd1, + 0xef, 0xf3, 0x10, 0x83, 0xdb, 0x07, 0x10, 0xd4, 0x1e, 0x4b, 0x5b, 0x68, + 0xdb, 0x05, 0xdb, 0x0d, 0xed, 0xd0, 0x10, 0x3b, 0x5b, 0xb2, 0x00, 0x2b, + 0x10, 0xda, 0x0f, 0x22, 0x13, 0x40, 0x08, 0x3b, 0x9b, 0x08, 0x19, 0x4a, + 0x9b, 0x00, 0x9b, 0x18, 0x1b, 0x68, 0x20, 0x69, 0xff, 0xf7, 0xda, 0xfc, + 0x00, 0x28, 0xdc, 0xd0, 0x20, 0x00, 0xff, 0xf7, 0x6a, 0xff, 0xd8, 0xe7, + 0x9b, 0x08, 0xc0, 0x33, 0x12, 0x4a, 0x9b, 0x00, 0x9b, 0x58, 0xf0, 0xe7, + 0x5a, 0x68, 0x01, 0x32, 0x16, 0x40, 0x9a, 0x68, 0x96, 0x42, 0x05, 0xd0, + 0x8e, 0x21, 0x5a, 0x68, 0x49, 0x00, 0xa2, 0x18, 0x55, 0x54, 0x5e, 0x60, + 0x20, 0x69, 0xff, 0xf7, 0xd0, 0xfc, 0x01, 0x20, 0x70, 0xbd, 0x20, 0x00, + 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0x1c, 0xff, 0x00, 0x28, 0xb9, 0xd1, + 0x29, 0x00, 0x20, 0x69, 0xff, 0xf7, 0xbb, 0xfc, 0xf1, 0xe7, 0xc0, 0x46, + 0x00, 0xed, 0x00, 0xe0, 0x1c, 0xed, 0x00, 0xe0, 0x00, 0xe1, 0x00, 0xe0, + 0x03, 0x00, 0x70, 0xb5, 0xfc, 0x33, 0xd9, 0x69, 0x9a, 0x69, 0x04, 0x00, + 0x91, 0x42, 0x1a, 0xd0, 0xda, 0x69, 0x82, 0x18, 0x15, 0x7d, 0xda, 0x69, + 0x01, 0x32, 0xd2, 0xb2, 0xda, 0x61, 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, + 0xff, 0x2b, 0x0c, 0xd0, 0x20, 0x00, 0x14, 0x30, 0xff, 0xf7, 0x11, 0xff, + 0x0a, 0x28, 0x06, 0xdd, 0x8c, 0x23, 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, + 0xe3, 0x58, 0xa2, 0x58, 0x1a, 0x60, 0x28, 0x00, 0x70, 0xbd, 0x01, 0x25, + 0x6d, 0x42, 0xe8, 0xe7, 0xfe, 0xe7, 0x00, 0x00, 0x03, 0x4b, 0x10, 0xb5, + 0x1b, 0x68, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, 0x10, 0xbd, 0xc0, 0x46, + 0xb0, 0x10, 0x00, 0x20, 0x70, 0xb5, 0x0f, 0x49, 0x0f, 0x4c, 0xa1, 0x42, + 0x04, 0xd1, 0x00, 0xf0, 0x81, 0xf8, 0xfa, 0xf7, 0xdd, 0xfd, 0xfe, 0xe7, + 0x0c, 0x4d, 0x00, 0x23, 0x8d, 0x42, 0xf6, 0xd0, 0xca, 0x18, 0xe8, 0x18, + 0xa2, 0x42, 0x05, 0xd3, 0x09, 0x4b, 0x82, 0x42, 0xef, 0xd0, 0x09, 0x49, + 0x00, 0x22, 0x04, 0xe0, 0x00, 0x68, 0x04, 0x33, 0x10, 0x60, 0xf1, 0xe7, + 0x04, 0xc3, 0x8b, 0x42, 0xfc, 0xd3, 0xe4, 0xe7, 0x00, 0x00, 0x00, 0x20, + 0x30, 0x00, 0x00, 0x20, 0xb8, 0x86, 0x00, 0x00, 0x30, 0x00, 0x00, 0x20, + 0xb8, 0x10, 0x00, 0x20, 0x10, 0xb5, 0x00, 0xf0, 0x58, 0xf8, 0x00, 0x28, + 0x01, 0xd1, 0x00, 0xf0, 0x49, 0xf8, 0x10, 0xbd, 0xf7, 0xb5, 0x13, 0x48, + 0x01, 0x22, 0x84, 0x46, 0x12, 0x49, 0x13, 0x4c, 0x8e, 0x68, 0x63, 0x68, + 0x05, 0x68, 0x9b, 0x0e, 0x13, 0x40, 0x01, 0x92, 0x88, 0x68, 0x62, 0x68, + 0x01, 0x9f, 0x92, 0x0e, 0x3a, 0x40, 0x67, 0x46, 0x3f, 0x68, 0x93, 0x42, + 0x0e, 0xd1, 0xbd, 0x42, 0x0c, 0xd1, 0x86, 0x42, 0x0a, 0xd3, 0x5b, 0x19, + 0xfa, 0x25, 0x48, 0x68, 0xad, 0x00, 0x86, 0x1b, 0x07, 0x48, 0x6b, 0x43, + 0x70, 0x43, 0x00, 0x0d, 0xc0, 0x18, 0xfe, 0xbd, 0x3d, 0x00, 0x13, 0x00, + 0x06, 0x00, 0xe3, 0xe7, 0xb4, 0x10, 0x00, 0x20, 0x10, 0xe0, 0x00, 0xe0, + 0x00, 0xed, 0x00, 0xe0, 0x55, 0x55, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x1e, + 0x10, 0xd0, 0xff, 0xf7, 0xcb, 0xff, 0x05, 0x00, 0x00, 0xf0, 0x1a, 0xf8, + 0xff, 0xf7, 0xc6, 0xff, 0x05, 0x4b, 0x40, 0x1b, 0x98, 0x42, 0xf7, 0xd9, + 0xfa, 0x23, 0x01, 0x3c, 0x9b, 0x00, 0xed, 0x18, 0x00, 0x2c, 0xf3, 0xd1, + 0x70, 0xbd, 0xc0, 0x46, 0xe7, 0x03, 0x00, 0x00, 0x10, 0xb5, 0x03, 0x4a, + 0x13, 0x68, 0x01, 0x33, 0x13, 0x60, 0x00, 0xf0, 0x4d, 0xfa, 0x10, 0xbd, + 0xb4, 0x10, 0x00, 0x20, 0x70, 0x47, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, + 0x1e, 0x22, 0x70, 0xb5, 0x46, 0x48, 0x47, 0x49, 0x43, 0x68, 0x93, 0x43, + 0x1c, 0x3a, 0x13, 0x43, 0x43, 0x60, 0x08, 0x23, 0x8c, 0x69, 0x23, 0x43, + 0x8b, 0x61, 0x43, 0x4c, 0x43, 0x4b, 0x9c, 0x82, 0x9c, 0x8a, 0x14, 0x43, + 0x9c, 0x82, 0xdc, 0x68, 0x14, 0x42, 0xfc, 0xd0, 0x01, 0x24, 0x40, 0x4a, + 0x14, 0x70, 0x15, 0x78, 0x25, 0x42, 0x03, 0xd0, 0x55, 0x78, 0x6d, 0xb2, + 0x00, 0x2d, 0xf8, 0xdb, 0x01, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, + 0x00, 0x2c, 0xfb, 0xdb, 0x39, 0x4c, 0x54, 0x60, 0x54, 0x78, 0x64, 0xb2, + 0x00, 0x2c, 0xfb, 0xdb, 0x82, 0x24, 0xe4, 0x01, 0x54, 0x80, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x02, 0x24, 0x9c, 0x84, 0x0e, 0x34, + 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x31, 0x4c, 0xdc, 0x62, 0x10, 0x24, + 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x9d, 0x8c, 0x2e, 0x4c, 0x2c, 0x43, + 0x9c, 0x84, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x02, 0x24, + 0x9d, 0x8c, 0x80, 0x26, 0x2c, 0x43, 0x9c, 0x84, 0x40, 0x24, 0xdd, 0x68, + 0x35, 0x42, 0xfc, 0xd0, 0xdd, 0x68, 0x25, 0x42, 0xf9, 0xd0, 0x10, 0x24, + 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x00, 0x24, 0x94, 0x60, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x21, 0x4c, 0x54, 0x60, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x1c, 0x6a, 0x1e, 0x4d, 0x2c, 0x40, + 0x80, 0x25, 0x1c, 0x62, 0x1c, 0x6a, 0xac, 0x43, 0x1c, 0x62, 0x03, 0x23, + 0x93, 0x60, 0x1b, 0x4b, 0x53, 0x60, 0x53, 0x78, 0x5b, 0xb2, 0x00, 0x2b, + 0xfb, 0xdb, 0x00, 0x23, 0xff, 0x24, 0x0b, 0x72, 0x17, 0x4a, 0x4b, 0x72, + 0x8b, 0x72, 0xcb, 0x72, 0x16, 0x4b, 0x1a, 0x60, 0x16, 0x4b, 0x17, 0x4a, + 0x1b, 0x68, 0x11, 0x68, 0x9a, 0x06, 0x5b, 0x01, 0xc9, 0x0e, 0x23, 0x40, + 0x52, 0x0f, 0x12, 0x02, 0x0b, 0x43, 0x13, 0x43, 0x12, 0x4a, 0x13, 0x85, + 0x80, 0x23, 0x42, 0x68, 0x13, 0x43, 0x43, 0x60, 0x70, 0xbd, 0xc0, 0x46, + 0x00, 0x40, 0x00, 0x41, 0x00, 0x04, 0x00, 0x40, 0x0c, 0x06, 0x00, 0x00, + 0x00, 0x08, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, 0x01, 0x05, 0x01, 0x00, + 0xb9, 0x05, 0xff, 0x7d, 0x04, 0x0a, 0x00, 0x00, 0x00, 0x07, 0x03, 0x00, + 0xff, 0xfc, 0xff, 0xff, 0x03, 0x06, 0x01, 0x00, 0x00, 0x6c, 0xdc, 0x02, + 0x00, 0x00, 0x00, 0x20, 0x24, 0x60, 0x80, 0x00, 0x20, 0x60, 0x80, 0x00, + 0x00, 0x40, 0x00, 0x42, 0xfa, 0x21, 0x31, 0x4b, 0x10, 0xb5, 0x18, 0x68, + 0x89, 0x00, 0x00, 0xf0, 0xd5, 0xf9, 0x2f, 0x4b, 0x01, 0x38, 0x98, 0x42, + 0x56, 0xd8, 0x2e, 0x49, 0x2e, 0x4a, 0x48, 0x60, 0xc0, 0x20, 0x13, 0x6a, + 0x00, 0x06, 0x1b, 0x02, 0x1b, 0x0a, 0x03, 0x43, 0x13, 0x62, 0x00, 0x24, + 0x07, 0x23, 0x8c, 0x60, 0x0b, 0x60, 0x80, 0x21, 0x13, 0x6a, 0x09, 0x06, + 0x1b, 0x02, 0x1b, 0x0a, 0x0b, 0x43, 0x13, 0x62, 0xfc, 0x22, 0x25, 0x4b, + 0x19, 0x6a, 0x0a, 0x43, 0x1a, 0x62, 0xfc, 0x22, 0x19, 0x6a, 0x92, 0x01, + 0x0a, 0x43, 0x1a, 0x62, 0xa0, 0x22, 0x19, 0x6a, 0xd2, 0x02, 0x0a, 0x43, + 0x1a, 0x62, 0x20, 0x00, 0x00, 0x21, 0x01, 0x34, 0x00, 0xf0, 0x76, 0xf8, + 0x0f, 0x2c, 0xf8, 0xd1, 0x1b, 0x4b, 0x1c, 0x00, 0x5a, 0x78, 0x52, 0xb2, + 0x00, 0x2a, 0xfb, 0xdb, 0x19, 0x4a, 0x5a, 0x80, 0x19, 0x4b, 0x1a, 0x00, + 0x59, 0x7e, 0xc9, 0x09, 0x01, 0x29, 0xfb, 0xd0, 0xe4, 0x21, 0xc9, 0x00, + 0x99, 0x80, 0x3f, 0x21, 0xd9, 0x70, 0x53, 0x7e, 0xdb, 0x09, 0x01, 0x2b, + 0xfb, 0xd0, 0xc0, 0x23, 0x00, 0x20, 0x5b, 0x01, 0x13, 0x61, 0x90, 0x70, + 0x00, 0xf0, 0x24, 0xf8, 0x63, 0x78, 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, + 0x0d, 0x4b, 0x0e, 0x4a, 0x63, 0x80, 0xd3, 0x79, 0xdb, 0x09, 0x01, 0x2b, + 0xfb, 0xd0, 0x41, 0x23, 0x53, 0x70, 0x10, 0xbd, 0xfe, 0xe7, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x20, 0xff, 0xff, 0xff, 0x00, 0x10, 0xe0, 0x00, 0xe0, + 0x00, 0xed, 0x00, 0xe0, 0x00, 0x04, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, + 0x1e, 0x40, 0x00, 0x00, 0x00, 0x40, 0x00, 0x42, 0x21, 0x40, 0x00, 0x00, + 0x00, 0x48, 0x00, 0x42, 0x16, 0x4a, 0x00, 0xb5, 0x13, 0x00, 0x51, 0x7e, + 0xc9, 0x09, 0x01, 0x29, 0xfb, 0xd0, 0x01, 0x38, 0x04, 0x28, 0x16, 0xd8, + 0x19, 0x69, 0x12, 0x4a, 0x0a, 0x40, 0x0f, 0x21, 0x1a, 0x61, 0x5a, 0x78, + 0x8a, 0x43, 0x00, 0xf0, 0x47, 0xf9, 0x03, 0x08, 0x06, 0x0b, 0x03, 0x00, + 0x11, 0x00, 0x01, 0x22, 0x0a, 0x43, 0x5a, 0x70, 0x00, 0xbd, 0x11, 0x00, + 0x03, 0x22, 0xf9, 0xe7, 0x11, 0x00, 0x02, 0x22, 0xf6, 0xe7, 0xf0, 0x23, + 0x11, 0x69, 0x1b, 0x05, 0x0b, 0x43, 0x0f, 0x21, 0x13, 0x61, 0x53, 0x78, + 0x8b, 0x43, 0x19, 0x00, 0x02, 0x23, 0x0b, 0x43, 0x53, 0x70, 0xeb, 0xe7, + 0x00, 0x40, 0x00, 0x42, 0xff, 0xff, 0xff, 0xf0, 0x18, 0x23, 0x30, 0xb5, + 0x1d, 0x00, 0x04, 0x00, 0x45, 0x43, 0x08, 0x20, 0x20, 0x4a, 0x55, 0x19, + 0x28, 0x56, 0x01, 0x30, 0x14, 0xd0, 0x03, 0x29, 0x12, 0xd8, 0x08, 0x00, + 0x63, 0x43, 0xd1, 0x56, 0xd3, 0x18, 0x00, 0xf0, 0x15, 0xf9, 0x02, 0x28, + 0x0e, 0x1b, 0x58, 0x68, 0xcb, 0x01, 0x02, 0x21, 0x18, 0x4a, 0x9b, 0x18, + 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, + 0x30, 0xbd, 0x58, 0x68, 0xcb, 0x01, 0x06, 0x21, 0x12, 0x4a, 0x9b, 0x18, + 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, + 0x9a, 0x61, 0xf1, 0xe7, 0x58, 0x68, 0xcb, 0x01, 0x06, 0x21, 0x0c, 0x4a, + 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, + 0x5a, 0x60, 0x5a, 0x61, 0xe4, 0xe7, 0x58, 0x68, 0xcb, 0x01, 0x02, 0x21, + 0x05, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, + 0x82, 0x40, 0x9a, 0x60, 0xd8, 0xe7, 0xc0, 0x46, 0x20, 0x83, 0x00, 0x00, + 0x00, 0x44, 0x00, 0x41, 0x18, 0x23, 0xf0, 0xb5, 0x08, 0x24, 0x58, 0x43, + 0x11, 0x4a, 0x13, 0x18, 0x1c, 0x57, 0x01, 0x34, 0x1b, 0xd0, 0x01, 0x26, + 0x35, 0x00, 0x5f, 0x68, 0x83, 0x56, 0xbd, 0x40, 0x0d, 0x4a, 0xdb, 0x01, + 0x9a, 0x18, 0x90, 0x68, 0x05, 0x42, 0x0b, 0xd1, 0x0c, 0x00, 0x60, 0x1e, + 0x84, 0x41, 0xd2, 0x19, 0x40, 0x32, 0x10, 0x78, 0x34, 0x40, 0x03, 0x36, + 0xa4, 0x00, 0xb0, 0x43, 0x20, 0x43, 0x10, 0x70, 0x04, 0x4a, 0x9b, 0x18, + 0x00, 0x29, 0x01, 0xd1, 0x5d, 0x61, 0xf0, 0xbd, 0x9d, 0x61, 0xfc, 0xe7, + 0x20, 0x83, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0x18, 0x22, 0x42, 0x43, + 0xf8, 0xb5, 0x2c, 0x4e, 0x03, 0x00, 0xb2, 0x18, 0x12, 0x7a, 0x52, 0xb2, + 0x14, 0x00, 0x01, 0x32, 0x0e, 0xd0, 0x48, 0x1c, 0x00, 0x24, 0x0c, 0x28, + 0x0a, 0xd8, 0x00, 0xf0, 0x9f, 0xf8, 0x07, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, + 0x1f, 0x1f, 0x1f, 0x0b, 0x0b, 0x0b, 0x0b, 0x00, 0x01, 0x24, 0x64, 0x42, + 0x20, 0x00, 0xf8, 0xbd, 0x09, 0x29, 0x05, 0xd1, 0x00, 0x21, 0x18, 0x00, + 0xff, 0xf7, 0x66, 0xff, 0x00, 0x24, 0xf5, 0xe7, 0x0a, 0x29, 0x01, 0xd1, + 0x08, 0x39, 0xf6, 0xe7, 0x00, 0x24, 0x0b, 0x29, 0xee, 0xd1, 0x0a, 0x39, + 0x18, 0x00, 0xff, 0xf7, 0x59, 0xff, 0xe9, 0xe7, 0x18, 0x22, 0x53, 0x43, + 0xf2, 0x18, 0x55, 0x68, 0x01, 0x20, 0x2c, 0x00, 0xf3, 0x56, 0x13, 0x4a, + 0xdb, 0x01, 0x6e, 0x08, 0x9b, 0x18, 0xc9, 0xb2, 0x04, 0x40, 0x9e, 0x19, + 0x00, 0x2c, 0x0d, 0xd0, 0x0f, 0x24, 0x30, 0x36, 0x32, 0x78, 0x09, 0x01, + 0x22, 0x40, 0x11, 0x43, 0xc9, 0xb2, 0x5b, 0x19, 0x31, 0x70, 0x40, 0x33, + 0x1a, 0x78, 0x10, 0x43, 0x18, 0x70, 0xd3, 0xe7, 0x32, 0x00, 0x0f, 0x27, + 0x30, 0x32, 0x16, 0x78, 0x5b, 0x19, 0xbe, 0x43, 0x31, 0x43, 0x11, 0x70, + 0x40, 0x33, 0x1a, 0x78, 0x10, 0x43, 0x18, 0x70, 0xbe, 0xe7, 0xc0, 0x46, + 0x20, 0x83, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0xf7, 0xb5, 0x06, 0x00, + 0x0d, 0x00, 0x0c, 0x00, 0x8b, 0x18, 0x01, 0x93, 0x01, 0x9b, 0x67, 0x1b, + 0x9c, 0x42, 0x07, 0xd0, 0x33, 0x68, 0x21, 0x78, 0x1b, 0x68, 0x30, 0x00, + 0x98, 0x47, 0x01, 0x34, 0x00, 0x28, 0xf3, 0xd1, 0x38, 0x00, 0xfe, 0xbd, + 0x16, 0x4a, 0x10, 0xb5, 0x13, 0x68, 0x59, 0x1c, 0x26, 0xd0, 0x01, 0x3b, + 0x13, 0x60, 0x00, 0x2b, 0x22, 0xd1, 0x72, 0xb6, 0x12, 0x4b, 0x13, 0x4a, + 0x04, 0x33, 0x93, 0x42, 0x13, 0xd9, 0x12, 0x4a, 0x01, 0x21, 0x10, 0x00, + 0x14, 0x7d, 0x0c, 0x42, 0xfc, 0xd0, 0x20, 0x21, 0x14, 0x8b, 0xff, 0x31, + 0x9b, 0x08, 0x5b, 0x00, 0x21, 0x43, 0x11, 0x83, 0xd3, 0x61, 0x0c, 0x4b, + 0x13, 0x80, 0x01, 0x23, 0x02, 0x7d, 0x1a, 0x42, 0xfc, 0xd0, 0xbf, 0xf3, + 0x4f, 0x8f, 0x09, 0x4b, 0x09, 0x4a, 0xda, 0x60, 0xbf, 0xf3, 0x4f, 0x8f, + 0xc0, 0x46, 0xfd, 0xe7, 0x10, 0xbd, 0xc0, 0x46, 0x04, 0x00, 0x00, 0x20, + 0x00, 0x20, 0x00, 0x00, 0x03, 0x02, 0x00, 0x00, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x00, 0xed, 0x00, 0xe0, 0x04, 0x00, 0xfa, 0x05, + 0x02, 0xb4, 0x71, 0x46, 0x49, 0x08, 0x49, 0x00, 0x09, 0x5c, 0x49, 0x00, + 0x8e, 0x44, 0x02, 0xbc, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x22, 0x43, 0x08, + 0x8b, 0x42, 0x74, 0xd3, 0x03, 0x09, 0x8b, 0x42, 0x5f, 0xd3, 0x03, 0x0a, + 0x8b, 0x42, 0x44, 0xd3, 0x03, 0x0b, 0x8b, 0x42, 0x28, 0xd3, 0x03, 0x0c, + 0x8b, 0x42, 0x0d, 0xd3, 0xff, 0x22, 0x09, 0x02, 0x12, 0xba, 0x03, 0x0c, + 0x8b, 0x42, 0x02, 0xd3, 0x12, 0x12, 0x09, 0x02, 0x65, 0xd0, 0x03, 0x0b, + 0x8b, 0x42, 0x19, 0xd3, 0x00, 0xe0, 0x09, 0x0a, 0xc3, 0x0b, 0x8b, 0x42, + 0x01, 0xd3, 0xcb, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0b, 0x8b, 0x42, + 0x01, 0xd3, 0x8b, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0b, 0x8b, 0x42, + 0x01, 0xd3, 0x4b, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0b, 0x8b, 0x42, + 0x01, 0xd3, 0x0b, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x0a, 0x8b, 0x42, + 0x01, 0xd3, 0xcb, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0a, 0x8b, 0x42, + 0x01, 0xd3, 0x8b, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0a, 0x8b, 0x42, + 0x01, 0xd3, 0x4b, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0a, 0x8b, 0x42, + 0x01, 0xd3, 0x0b, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0xcd, 0xd2, 0xc3, 0x09, + 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x09, + 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x09, + 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x09, + 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x08, + 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x08, + 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x08, + 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x41, 0x1a, + 0x00, 0xd2, 0x01, 0x46, 0x52, 0x41, 0x10, 0x46, 0x70, 0x47, 0xff, 0xe7, + 0x01, 0xb5, 0x00, 0x20, 0x00, 0xf0, 0x06, 0xf8, 0x02, 0xbd, 0xc0, 0x46, + 0x00, 0x29, 0xf7, 0xd0, 0x76, 0xe7, 0x70, 0x47, 0x70, 0x47, 0xc0, 0x46, + 0x70, 0xb5, 0x00, 0x26, 0x0c, 0x4d, 0x0d, 0x4c, 0x64, 0x1b, 0xa4, 0x10, + 0xa6, 0x42, 0x09, 0xd1, 0x00, 0x26, 0x00, 0xf0, 0x4f, 0xf8, 0x0a, 0x4d, + 0x0a, 0x4c, 0x64, 0x1b, 0xa4, 0x10, 0xa6, 0x42, 0x05, 0xd1, 0x70, 0xbd, + 0xb3, 0x00, 0xeb, 0x58, 0x98, 0x47, 0x01, 0x36, 0xee, 0xe7, 0xb3, 0x00, + 0xeb, 0x58, 0x98, 0x47, 0x01, 0x36, 0xf2, 0xe7, 0x08, 0x00, 0x00, 0x20, + 0x08, 0x00, 0x00, 0x20, 0x08, 0x00, 0x00, 0x20, 0x24, 0x00, 0x00, 0x20, + 0x00, 0x23, 0x10, 0xb5, 0x9a, 0x42, 0x00, 0xd1, 0x10, 0xbd, 0xcc, 0x5c, + 0xc4, 0x54, 0x01, 0x33, 0xf8, 0xe7, 0x03, 0x00, 0x12, 0x18, 0x93, 0x42, + 0x00, 0xd1, 0x70, 0x47, 0x19, 0x70, 0x01, 0x33, 0xf9, 0xe7, 0x02, 0x78, + 0x0b, 0x78, 0x00, 0x2a, 0x03, 0xd0, 0x01, 0x30, 0x01, 0x31, 0x9a, 0x42, + 0xf7, 0xd0, 0xd0, 0x1a, 0x70, 0x47, 0x00, 0x23, 0xc2, 0x5c, 0x01, 0x33, + 0x00, 0x2a, 0xfb, 0xd1, 0x58, 0x1e, 0x70, 0x47, 0x30, 0xb5, 0x05, 0x00, + 0x00, 0x2a, 0x00, 0xd1, 0x30, 0xbd, 0x0c, 0x78, 0x01, 0x3a, 0x6b, 0x1c, + 0x2c, 0x70, 0x01, 0x31, 0x00, 0x2c, 0x05, 0xd1, 0x9a, 0x18, 0x9a, 0x42, + 0xf4, 0xd0, 0x1c, 0x70, 0x01, 0x33, 0xfa, 0xe7, 0x1d, 0x00, 0xed, 0xe7, + 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, + 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, + 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x2e, 0x42, 0x49, 0x4e, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, + 0x40, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x16, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x00, 0x04, 0x00, 0x04, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x17, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x01, 0x04, 0x01, 0x04, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0a, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x12, 0x00, 0x00, 0x01, 0x00, 0x01, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0b, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x13, 0x00, 0x01, 0x01, 0x01, 0x01, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x0a, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x00, 0x05, 0x00, 0x05, 0x0a, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x0b, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x01, 0x05, 0x01, 0x05, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x14, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x02, 0x00, 0x02, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x15, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x03, 0x00, 0x03, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x00, 0x02, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x11, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x13, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x01, 0x03, 0x01, 0x03, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x10, 0x00, 0xff, 0xff, 0xff, 0xff, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x09, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x11, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x17, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x16, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x0a, 0x00, 0xff, 0xff, 0xff, 0xff, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x0b, 0x00, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x05, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x05, 0x00, 0x01, 0x00, 0x01, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x06, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x07, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x07, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x18, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x19, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x12, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0c, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0d, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0e, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0f, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x1b, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x02, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x09, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x01, 0x04, 0x01, 0x04, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x1c, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x19, 0x74, 0x00, 0x00, 0xa5, 0x7a, 0x00, 0x00, + 0x3f, 0x73, 0x00, 0x00, 0xfb, 0x72, 0x00, 0x00, 0x15, 0x73, 0x00, 0x00, + 0xcd, 0x74, 0x00, 0x00, 0x55, 0x70, 0x00, 0x00, 0x45, 0x70, 0x00, 0x00, + 0xd9, 0x70, 0x00, 0x00, 0x6f, 0x70, 0x00, 0x00, 0x3f, 0x70, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x40, 0x42, 0x0f, 0x00, 0xff, 0xff, 0xff, 0xff, + 0xdd, 0x20, 0x00, 0x00, 0x25, 0x22, 0x00, 0x00, 0x39, 0x22, 0x00, 0x00, + 0xa5, 0x23, 0x00, 0x00, 0x3d, 0x26, 0x00, 0x00, 0x41, 0x6c, 0x00, 0x00, + 0xa1, 0x6c, 0x00, 0x00, 0xb5, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00 diff --git a/libraries/SFU/src/boot/mkrnb1500.h b/libraries/SFU/src/boot/mkrnb1500.h new file mode 100644 index 0000000..2377184 --- /dev/null +++ b/libraries/SFU/src/boot/mkrnb1500.h @@ -0,0 +1,2174 @@ + 0x00, 0x80, 0x00, 0x20, 0xa1, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, + 0x89, 0x74, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, + 0xf5, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, + 0x89, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, + 0x89, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, 0x8d, 0x74, 0x00, 0x00, + 0x89, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, + 0x89, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, 0x91, 0x6c, 0x00, 0x00, + 0x81, 0x6c, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, + 0x89, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, + 0x89, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, + 0x89, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0x30, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xb4, 0x85, 0x00, 0x00, 0x04, 0x4b, 0x10, 0xb5, 0x00, 0x2b, 0x03, 0xd0, + 0x03, 0x49, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x10, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x00, 0x34, 0x00, 0x00, 0x20, 0xb4, 0x85, 0x00, 0x00, + 0xf0, 0xb5, 0x40, 0x4c, 0xa5, 0x44, 0x00, 0xaf, 0x05, 0xf0, 0x04, 0xfb, + 0x05, 0xf0, 0x6a, 0xfd, 0x01, 0x20, 0x05, 0xf0, 0x29, 0xfa, 0x3c, 0x48, + 0x00, 0xf0, 0x8c, 0xf9, 0x3b, 0x4c, 0x20, 0x00, 0x00, 0xf0, 0x1c, 0xf9, + 0x00, 0x28, 0x5d, 0xd1, 0x20, 0x00, 0x02, 0xf0, 0x29, 0xfb, 0x00, 0x28, + 0x58, 0xd1, 0x20, 0x00, 0x02, 0xf0, 0x44, 0xf9, 0x0c, 0x20, 0x08, 0x23, + 0x34, 0x4a, 0x21, 0x00, 0x38, 0x18, 0x00, 0xf0, 0x23, 0xf9, 0x20, 0x00, + 0x02, 0xf0, 0x38, 0xf9, 0x05, 0x1e, 0x45, 0xd1, 0x0c, 0x23, 0x01, 0x00, + 0x02, 0x22, 0xf8, 0x18, 0x00, 0xf0, 0x42, 0xf9, 0x80, 0x21, 0x78, 0x60, + 0x09, 0x02, 0x2e, 0x00, 0x88, 0x42, 0x2c, 0xdd, 0x0c, 0x23, 0x2a, 0x00, + 0xf8, 0x18, 0x00, 0xf0, 0x37, 0xf9, 0x28, 0x4a, 0xa0, 0x21, 0x94, 0x46, + 0x7b, 0x68, 0x09, 0x02, 0x63, 0x44, 0x1a, 0x00, 0x25, 0x48, 0xa0, 0x25, + 0x80, 0x26, 0x7b, 0x60, 0x00, 0xf0, 0xd6, 0xf8, 0x2d, 0x02, 0xb6, 0x00, + 0x08, 0x23, 0xf8, 0x18, 0xc1, 0x18, 0x04, 0x33, 0x32, 0x00, 0xf8, 0x18, + 0x00, 0xf0, 0x14, 0xf9, 0x08, 0x22, 0xb9, 0x18, 0x8a, 0x18, 0x33, 0x00, + 0x29, 0x00, 0x1b, 0x48, 0x00, 0xf0, 0x74, 0xf8, 0x80, 0x22, 0x1a, 0x4b, + 0x92, 0x00, 0xeb, 0x18, 0xad, 0x18, 0x7a, 0x68, 0x93, 0x42, 0xe7, 0xdb, + 0x01, 0x26, 0x0c, 0x23, 0xf8, 0x18, 0x00, 0xf0, 0x17, 0xf9, 0x00, 0x2e, + 0x03, 0xd0, 0x10, 0x49, 0x20, 0x00, 0x02, 0xf0, 0x55, 0xfa, 0x20, 0x00, + 0x02, 0xf0, 0xca, 0xf8, 0x0c, 0x23, 0xf8, 0x18, 0x00, 0xf0, 0x14, 0xf9, + 0xa0, 0x23, 0x1b, 0x02, 0x1a, 0x68, 0x82, 0xf3, 0x08, 0x88, 0x0c, 0x4a, + 0x93, 0x60, 0x0c, 0x4b, 0x1b, 0x68, 0x18, 0x47, 0x00, 0x20, 0xbd, 0x46, + 0x85, 0x23, 0x9b, 0x00, 0x9d, 0x44, 0xf0, 0xbd, 0xec, 0xfd, 0xff, 0xff, + 0xf4, 0x0b, 0x00, 0x20, 0x8c, 0x04, 0x00, 0x20, 0xac, 0x7c, 0x00, 0x00, + 0x00, 0x80, 0xff, 0xff, 0x4c, 0x00, 0x00, 0x20, 0x00, 0x62, 0xff, 0xff, + 0x00, 0xed, 0x00, 0xe0, 0x04, 0xa0, 0x00, 0x00, 0x00, 0x22, 0x10, 0xb5, + 0x11, 0x00, 0x02, 0x48, 0x00, 0xf0, 0x1a, 0xf8, 0x10, 0xbd, 0xc0, 0x46, + 0x4c, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x05, 0x4a, 0x05, 0x49, 0x06, 0x48, + 0x00, 0xf0, 0x10, 0xf8, 0x00, 0x22, 0x05, 0x4b, 0x05, 0x49, 0x1a, 0x70, + 0x5a, 0x54, 0x10, 0xbd, 0x01, 0x04, 0x00, 0x00, 0x00, 0x7d, 0x00, 0x00, + 0x68, 0x04, 0x00, 0x20, 0x64, 0x00, 0x00, 0x20, 0x02, 0x04, 0x00, 0x00, + 0x30, 0xb5, 0x09, 0x4d, 0x09, 0x4c, 0xab, 0x68, 0x5b, 0x03, 0x5b, 0x0f, + 0x9b, 0x00, 0x1c, 0x59, 0x04, 0x60, 0xab, 0x68, 0x01, 0x61, 0x9b, 0xb2, + 0x43, 0x60, 0x63, 0x43, 0xa4, 0x00, 0x83, 0x60, 0xc4, 0x60, 0x42, 0x61, + 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, 0x00, 0x82, 0x00, 0x00, + 0xf7, 0xb5, 0x80, 0x26, 0x1a, 0x4d, 0x01, 0x91, 0x6f, 0x68, 0x03, 0x33, + 0x3e, 0x43, 0x9b, 0x08, 0x6e, 0x60, 0x00, 0x2b, 0x2b, 0xd0, 0x17, 0x4e, + 0x2e, 0x80, 0x2e, 0x7d, 0xf1, 0x07, 0xfc, 0xd5, 0x1e, 0x00, 0x07, 0x68, + 0x99, 0x1b, 0xbf, 0x08, 0x8f, 0x42, 0x19, 0xd9, 0x00, 0x2e, 0x17, 0xd0, + 0xff, 0x21, 0x17, 0x78, 0x8c, 0x43, 0x3c, 0x43, 0x0f, 0x49, 0x57, 0x78, + 0x0c, 0x40, 0x3f, 0x02, 0x3c, 0x43, 0x97, 0x78, 0x01, 0x3e, 0x39, 0x04, + 0x0c, 0x4f, 0x27, 0x40, 0xd4, 0x78, 0xbf, 0xb2, 0x0f, 0x43, 0x24, 0x06, + 0x01, 0x99, 0x3c, 0x43, 0x10, 0xc1, 0x01, 0x91, 0x04, 0x32, 0xe0, 0xe7, + 0x07, 0x4b, 0x2b, 0x80, 0x2b, 0x7d, 0xdb, 0x07, 0xfc, 0xd5, 0x33, 0x00, + 0xd1, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x44, 0xa5, 0xff, 0xff, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, 0x04, 0xa5, 0xff, 0xff, + 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, 0x1a, 0x80, 0x1a, 0x7d, + 0xd2, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x16, 0x00, + 0xe3, 0x68, 0x29, 0x00, 0x20, 0x00, 0xb3, 0x42, 0x05, 0xd2, 0xff, 0xf7, + 0xe7, 0xff, 0xe3, 0x68, 0xed, 0x18, 0xf6, 0x1a, 0xf4, 0xe7, 0xff, 0xf7, + 0xe1, 0xff, 0x70, 0xbd, 0x1f, 0xb5, 0x00, 0x21, 0x03, 0x91, 0x90, 0x21, + 0xc9, 0x00, 0x02, 0x91, 0xa1, 0x39, 0xff, 0x39, 0x41, 0x18, 0x98, 0x23, + 0x01, 0x91, 0x02, 0x00, 0x80, 0x21, 0x9b, 0x00, 0x00, 0x91, 0xc3, 0x18, + 0x60, 0x32, 0x02, 0x49, 0x01, 0xf0, 0x9c, 0xff, 0x05, 0xb0, 0x00, 0xbd, + 0x80, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, 0x08, 0x00, 0x11, 0x00, + 0x1a, 0x00, 0x00, 0x23, 0x02, 0xf0, 0x16, 0xf8, 0x01, 0x00, 0x20, 0x00, + 0x00, 0xf0, 0x3a, 0xf8, 0x20, 0x00, 0x10, 0xbd, 0x03, 0x4b, 0x04, 0x4a, + 0x1a, 0x60, 0x04, 0x4a, 0x5a, 0x60, 0x04, 0x4a, 0x9a, 0x60, 0x70, 0x47, + 0x80, 0x04, 0x00, 0x20, 0x01, 0x26, 0x00, 0x00, 0x15, 0x26, 0x00, 0x00, + 0x29, 0x26, 0x00, 0x00, 0x10, 0xb5, 0x0c, 0x00, 0x13, 0x00, 0x00, 0x22, + 0x81, 0x5e, 0x22, 0x00, 0x01, 0x48, 0x02, 0xf0, 0x87, 0xf8, 0x10, 0xbd, + 0x8c, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x0c, 0x00, 0x13, 0x00, 0x00, 0x22, + 0x81, 0x5e, 0x22, 0x00, 0x01, 0x48, 0x02, 0xf0, 0xdd, 0xf8, 0x10, 0xbd, + 0x8c, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x00, 0x23, 0xc1, 0x5e, 0x02, 0x48, + 0x02, 0xf0, 0x9c, 0xf9, 0x10, 0xbd, 0xc0, 0x46, 0x8c, 0x04, 0x00, 0x20, + 0x10, 0xb5, 0x04, 0x00, 0xff, 0xf7, 0xf2, 0xff, 0x20, 0x00, 0x10, 0xbd, + 0x01, 0x80, 0x70, 0x47, 0x10, 0xb5, 0x00, 0x21, 0x40, 0x68, 0x05, 0xf0, + 0x6d, 0xfa, 0x10, 0xbd, 0x10, 0xb5, 0x01, 0x21, 0x40, 0x68, 0x05, 0xf0, + 0x67, 0xfa, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x68, 0x04, 0xf0, + 0xb9, 0xfb, 0x01, 0x21, 0x60, 0x68, 0x05, 0xf0, 0x11, 0xfa, 0x20, 0x00, + 0xff, 0xf7, 0xee, 0xff, 0x10, 0xbd, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x00, + 0xff, 0xf7, 0xe2, 0xff, 0x09, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, + 0xcf, 0xfb, 0x05, 0x21, 0x20, 0x68, 0x04, 0xf0, 0xe7, 0xfb, 0x00, 0x21, + 0x20, 0x68, 0x04, 0xf0, 0xe3, 0xfb, 0x05, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0xd7, 0xff, 0x28, 0x00, 0x70, 0xbd, 0xc0, 0x46, 0xec, 0x0b, 0x00, 0x20, + 0x10, 0xb5, 0xff, 0xf7, 0xe3, 0xff, 0x01, 0x23, 0x18, 0x40, 0x10, 0xbd, + 0xf7, 0xb5, 0x04, 0x00, 0x0e, 0x00, 0x15, 0x00, 0x10, 0x27, 0x01, 0x93, + 0x20, 0x00, 0xff, 0xf7, 0xf1, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x3b, 0x00, + 0x01, 0x3b, 0xfd, 0xd1, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xb4, 0xff, + 0x12, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, 0xa1, 0xfb, 0x03, 0x21, + 0x20, 0x68, 0x04, 0xf0, 0xb9, 0xfb, 0x31, 0x0c, 0xc9, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0xb4, 0xfb, 0x31, 0x0a, 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, + 0xaf, 0xfb, 0xf1, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0xab, 0xfb, 0x01, 0x9b, + 0xee, 0x18, 0xb5, 0x42, 0x06, 0xd0, 0x00, 0x21, 0x20, 0x68, 0x04, 0xf0, + 0xa3, 0xfb, 0x28, 0x70, 0x01, 0x35, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, + 0x95, 0xff, 0xf7, 0xbd, 0xec, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, + 0xff, 0xf7, 0x88, 0xff, 0x06, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, + 0x75, 0xfb, 0x06, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x8d, 0xfb, 0x20, 0x00, + 0xff, 0xf7, 0x82, 0xff, 0x10, 0xbd, 0xc0, 0x46, 0xec, 0x0b, 0x00, 0x20, + 0xf7, 0xb5, 0x04, 0x00, 0x0e, 0x00, 0x15, 0x00, 0x10, 0x27, 0x01, 0x93, + 0x20, 0x00, 0xff, 0xf7, 0xa3, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x3b, 0x00, + 0x01, 0x3b, 0xfd, 0xd1, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xda, 0xff, + 0x20, 0x00, 0xff, 0xf7, 0x63, 0xff, 0x12, 0x4b, 0x20, 0x68, 0x06, 0xcb, + 0x04, 0xf0, 0x50, 0xfb, 0x02, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x68, 0xfb, + 0x31, 0x0c, 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x63, 0xfb, 0x31, 0x0a, + 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x5e, 0xfb, 0xf1, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0x5a, 0xfb, 0x01, 0x9b, 0xee, 0x18, 0xb5, 0x42, 0x05, 0xd0, + 0x29, 0x78, 0x20, 0x68, 0x04, 0xf0, 0x52, 0xfb, 0x01, 0x35, 0xf7, 0xe7, + 0x20, 0x00, 0xff, 0xf7, 0x45, 0xff, 0xf7, 0xbd, 0xec, 0x0b, 0x00, 0x20, + 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x10, 0x26, 0x20, 0x00, 0xff, 0xf7, + 0x69, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x33, 0x00, 0x01, 0x3b, 0xfd, 0xd1, + 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xa0, 0xff, 0x20, 0x00, 0xff, 0xf7, + 0x29, 0xff, 0x0d, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, 0x16, 0xfb, + 0x20, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x2e, 0xfb, 0x29, 0x0c, 0xc9, 0xb2, + 0x20, 0x68, 0x04, 0xf0, 0x29, 0xfb, 0x29, 0x0a, 0xc9, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0x24, 0xfb, 0xe9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x20, 0xfb, + 0x20, 0x00, 0xff, 0xf7, 0x15, 0xff, 0x70, 0xbd, 0xec, 0x0b, 0x00, 0x20, + 0x10, 0xb5, 0x0b, 0x00, 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, 0x40, 0xff, + 0x00, 0x20, 0x10, 0xbd, 0xf4, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x0b, 0x00, + 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, 0x84, 0xff, 0x00, 0x20, 0x10, 0xbd, + 0xf4, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, + 0xb7, 0xff, 0x00, 0x20, 0x10, 0xbd, 0xc0, 0x46, 0xf4, 0x0b, 0x00, 0x20, + 0x05, 0x4b, 0x06, 0x4a, 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, + 0x04, 0x4b, 0x05, 0x4a, 0x1a, 0x60, 0x05, 0x22, 0x5a, 0x60, 0x70, 0x47, + 0xec, 0x0b, 0x00, 0x20, 0x00, 0x1b, 0xb7, 0x00, 0xf4, 0x0b, 0x00, 0x20, + 0xfc, 0x0b, 0x00, 0x20, 0x01, 0x23, 0x8b, 0x40, 0xf7, 0xb5, 0x44, 0x6c, + 0x01, 0x93, 0x01, 0x9d, 0xa3, 0x68, 0x06, 0x00, 0x00, 0x20, 0x2b, 0x42, + 0x1c, 0xd0, 0x8a, 0x25, 0x6d, 0x00, 0x69, 0x43, 0x23, 0x69, 0x5d, 0x18, + 0x82, 0x42, 0x0f, 0xd0, 0x2a, 0x78, 0x57, 0xb2, 0x87, 0x42, 0x0b, 0xdb, + 0x01, 0x27, 0x3a, 0x42, 0x08, 0xd0, 0x0a, 0x00, 0x80, 0x21, 0x28, 0x89, + 0x14, 0x32, 0x9a, 0x18, 0x00, 0x02, 0x73, 0x68, 0x49, 0x00, 0x98, 0x47, + 0xa3, 0x68, 0x01, 0x9a, 0x93, 0x43, 0xa3, 0x60, 0x00, 0x23, 0x2b, 0x70, + 0xfe, 0xbd, 0xc3, 0x68, 0xf0, 0xb5, 0x84, 0x68, 0x02, 0x00, 0x23, 0x40, + 0x18, 0x1e, 0x17, 0xd0, 0x8a, 0x27, 0x00, 0x23, 0x15, 0x78, 0x7f, 0x00, + 0xab, 0x42, 0x01, 0xdb, 0x00, 0x20, 0x0f, 0xe0, 0x01, 0x20, 0x98, 0x40, + 0x04, 0x42, 0x0c, 0xd0, 0x38, 0x00, 0x58, 0x43, 0x16, 0x69, 0x30, 0x18, + 0x06, 0x78, 0x7f, 0x2e, 0x05, 0xd8, 0x06, 0x89, 0x8e, 0x42, 0x02, 0xd1, + 0x53, 0x68, 0x43, 0x60, 0xf0, 0xbd, 0x01, 0x33, 0xe8, 0xe7, 0x82, 0x68, + 0x01, 0x00, 0x30, 0xb5, 0x00, 0x20, 0x53, 0x1c, 0x13, 0xd0, 0x00, 0x23, + 0x01, 0x25, 0x08, 0x78, 0x83, 0x42, 0x01, 0xdb, 0x00, 0x20, 0x0c, 0xe0, + 0x2c, 0x00, 0x9c, 0x40, 0x14, 0x42, 0x09, 0xd1, 0x8a, 0x20, 0x40, 0x00, + 0x58, 0x43, 0x0b, 0x69, 0x22, 0x43, 0x18, 0x18, 0x4b, 0x68, 0x8a, 0x60, + 0x43, 0x60, 0x30, 0xbd, 0x01, 0x33, 0xeb, 0xe7, 0xf8, 0xb5, 0x44, 0x6c, + 0x07, 0x00, 0xe2, 0x68, 0xa3, 0x68, 0x00, 0x20, 0x13, 0x40, 0x9a, 0x42, + 0x0e, 0xd1, 0x23, 0x78, 0x01, 0x21, 0x9c, 0x46, 0x02, 0x00, 0x03, 0x00, + 0x49, 0x42, 0x62, 0x45, 0x07, 0xdb, 0x00, 0x20, 0x4b, 0x1c, 0x03, 0xd0, + 0x01, 0x22, 0x38, 0x00, 0xff, 0xf7, 0x80, 0xff, 0xf8, 0xbd, 0x8a, 0x26, + 0x76, 0x00, 0x56, 0x43, 0x25, 0x69, 0xae, 0x19, 0x70, 0x68, 0x65, 0x68, + 0x2d, 0x1a, 0x9d, 0x42, 0x04, 0xd9, 0x36, 0x78, 0x7f, 0x2e, 0x01, 0xd8, + 0x2b, 0x00, 0x11, 0x00, 0x01, 0x32, 0xe4, 0xe7, 0x10, 0xb5, 0x04, 0x00, + 0x40, 0x6c, 0xff, 0xf7, 0x92, 0xff, 0x00, 0x28, 0x04, 0xd0, 0x41, 0x78, + 0x00, 0x22, 0x20, 0x00, 0xff, 0xf7, 0x62, 0xff, 0x10, 0xbd, 0xf7, 0xb5, + 0x46, 0x6c, 0x1c, 0x00, 0x1b, 0x0a, 0x9b, 0xb2, 0x05, 0x00, 0x0f, 0x00, + 0x30, 0x00, 0x19, 0x00, 0x01, 0x93, 0xff, 0xf7, 0x7e, 0xff, 0x73, 0x68, + 0x01, 0x33, 0x73, 0x60, 0x00, 0x28, 0x10, 0xd0, 0x8a, 0x21, 0x43, 0x60, + 0x43, 0x78, 0x49, 0x00, 0x59, 0x43, 0xe4, 0xb2, 0x14, 0x34, 0x09, 0x19, + 0x34, 0x69, 0x08, 0x9a, 0x61, 0x18, 0x09, 0x98, 0x05, 0xf0, 0x24, 0xfa, + 0x00, 0x27, 0x38, 0x00, 0xfe, 0xbd, 0x03, 0x23, 0x1f, 0x40, 0x01, 0x2f, + 0x06, 0xd1, 0x2b, 0x68, 0x09, 0x9a, 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, + 0x07, 0x00, 0xf2, 0xe7, 0x28, 0x00, 0xff, 0xf7, 0x99, 0xff, 0x07, 0x00, + 0x68, 0x6c, 0xff, 0xf7, 0x78, 0xff, 0x00, 0x90, 0x00, 0x28, 0x24, 0xd0, + 0x02, 0x23, 0x6a, 0x46, 0x03, 0x70, 0x8a, 0x23, 0x92, 0x88, 0x5b, 0x00, + 0x02, 0x81, 0x42, 0x78, 0x80, 0x21, 0x5a, 0x43, 0x33, 0x69, 0x14, 0x32, + 0x9a, 0x18, 0x20, 0x00, 0xff, 0x23, 0x49, 0x00, 0x98, 0x43, 0x2b, 0x68, + 0x98, 0x47, 0x8a, 0x21, 0x49, 0x00, 0x00, 0x28, 0x00, 0xd0, 0x07, 0x00, + 0x00, 0x9b, 0xe4, 0xb2, 0x5b, 0x78, 0x14, 0x34, 0x59, 0x43, 0x09, 0x19, + 0x34, 0x69, 0x08, 0x9a, 0x61, 0x18, 0x09, 0x98, 0x05, 0xf0, 0xe8, 0xf9, + 0xc3, 0xe7, 0x2b, 0x68, 0x09, 0x9a, 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, + 0x00, 0x28, 0xc7, 0xd1, 0xbb, 0xe7, 0xf7, 0xb5, 0x47, 0x6c, 0x01, 0x91, + 0x19, 0x0a, 0x05, 0x00, 0x89, 0xb2, 0x38, 0x00, 0x1c, 0x00, 0xff, 0xf7, + 0x1c, 0xff, 0x06, 0x1e, 0x0c, 0xd0, 0x1c, 0x22, 0x01, 0x9b, 0x1a, 0x40, + 0x18, 0x2a, 0x07, 0xd0, 0x41, 0x78, 0x00, 0x2a, 0x0a, 0xd1, 0x9b, 0x07, + 0x08, 0xd0, 0x28, 0x00, 0xff, 0xf7, 0xe4, 0xfe, 0x6b, 0x68, 0x09, 0x9a, + 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, 0x14, 0xe0, 0x8a, 0x23, 0x5b, 0x00, + 0x59, 0x43, 0xe0, 0xb2, 0x3b, 0x69, 0x14, 0x30, 0x40, 0x18, 0x18, 0x18, + 0x08, 0x9a, 0x09, 0x99, 0x05, 0xf0, 0xb4, 0xf9, 0x02, 0x22, 0x7b, 0x68, + 0x01, 0x33, 0x7b, 0x60, 0x73, 0x60, 0x33, 0x78, 0x13, 0x40, 0x18, 0x1e, + 0xe4, 0xd1, 0xfe, 0xbd, 0xf7, 0xb5, 0x42, 0x6c, 0x94, 0x68, 0xd3, 0x68, + 0x23, 0x40, 0x18, 0x1e, 0x09, 0xd0, 0x13, 0x78, 0x8a, 0x26, 0x01, 0x93, + 0x01, 0x25, 0x00, 0x23, 0x76, 0x00, 0x01, 0x98, 0x98, 0x42, 0x01, 0xdc, + 0x00, 0x20, 0xfe, 0xbd, 0x28, 0x00, 0x98, 0x40, 0x04, 0x42, 0x0b, 0xd0, + 0x30, 0x00, 0x58, 0x43, 0x17, 0x69, 0x38, 0x18, 0x07, 0x78, 0x7f, 0x2f, + 0x04, 0xd9, 0x07, 0x89, 0xbc, 0x46, 0xcf, 0x88, 0xbc, 0x45, 0xee, 0xd0, + 0x01, 0x33, 0xe8, 0xe7, 0x70, 0xb5, 0x0c, 0x1e, 0x0f, 0xd0, 0x30, 0x21, + 0xc5, 0x6a, 0x83, 0x6a, 0x69, 0x43, 0x1a, 0x1d, 0x5b, 0x18, 0x00, 0x21, + 0x04, 0x33, 0x9a, 0x42, 0x06, 0xd1, 0x61, 0x78, 0x00, 0x22, 0xff, 0xf7, + 0x93, 0xfe, 0x00, 0x23, 0x23, 0x81, 0x70, 0xbd, 0x00, 0x26, 0x95, 0x5f, + 0x00, 0x2d, 0x03, 0xd0, 0xd5, 0x69, 0xa5, 0x42, 0x00, 0xd1, 0xd1, 0x61, + 0x30, 0x32, 0xec, 0xe7, 0xf0, 0xb5, 0x47, 0x6c, 0x89, 0xb0, 0x06, 0x00, + 0x00, 0x2f, 0x36, 0xd0, 0x8a, 0x21, 0x80, 0x6c, 0x49, 0x00, 0x14, 0x38, + 0x05, 0xf0, 0xac, 0xf8, 0x04, 0x1e, 0x2e, 0xd0, 0x00, 0x23, 0x01, 0x21, + 0x01, 0x93, 0x01, 0x9a, 0x01, 0x33, 0x52, 0x00, 0x0a, 0x43, 0x01, 0x92, + 0x9c, 0x42, 0xf8, 0xdc, 0x03, 0xad, 0x08, 0x22, 0x00, 0x21, 0x28, 0x00, + 0x05, 0xf0, 0x53, 0xf9, 0x3b, 0x00, 0x14, 0x33, 0x2b, 0x61, 0x01, 0x23, + 0x5b, 0x42, 0xab, 0x60, 0x01, 0x9b, 0x29, 0x00, 0x14, 0x22, 0x38, 0x00, + 0xeb, 0x60, 0x2c, 0x70, 0x05, 0xf0, 0x3c, 0xf9, 0x75, 0x6c, 0x8a, 0x26, + 0x2a, 0x78, 0x76, 0x00, 0x72, 0x43, 0x00, 0x21, 0x28, 0x69, 0x05, 0xf0, + 0x3c, 0xf9, 0xab, 0x68, 0xea, 0x68, 0xe4, 0xb2, 0x93, 0x43, 0xab, 0x60, + 0x00, 0x23, 0x9c, 0x42, 0x01, 0xdc, 0x09, 0xb0, 0xf0, 0xbd, 0x32, 0x00, + 0x5a, 0x43, 0x29, 0x69, 0x8a, 0x18, 0x53, 0x70, 0x01, 0x33, 0xf4, 0xe7, + 0xf0, 0xb5, 0x85, 0xb0, 0x06, 0x00, 0x0d, 0x00, 0x14, 0x00, 0x03, 0x93, + 0x00, 0x27, 0x68, 0x2a, 0x06, 0xd9, 0x10, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x05, 0xf0, 0x64, 0xf8, 0x01, 0x30, 0x87, 0xb2, 0x80, 0x21, 0x0a, 0x9b, + 0x09, 0x02, 0x00, 0x93, 0x29, 0x43, 0x00, 0x23, 0x3a, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0xfa, 0xfa, 0x00, 0x28, 0x11, 0xdb, 0x0a, 0x9b, 0x1d, 0x88, + 0x2d, 0x02, 0x00, 0x2f, 0x0e, 0xd1, 0x23, 0x00, 0x17, 0x33, 0x03, 0x9a, + 0x5b, 0x00, 0x01, 0x92, 0x02, 0x22, 0x5b, 0x19, 0x00, 0x92, 0x15, 0x21, + 0x00, 0x22, 0x30, 0x00, 0xff, 0xf7, 0xb1, 0xfe, 0x05, 0xb0, 0xf0, 0xbd, + 0x23, 0x1d, 0x68, 0x2c, 0xef, 0xd9, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x05, 0xf0, 0xc0, 0xf8, 0x0b, 0x1d, 0xe8, 0xe7, 0x30, 0xb5, 0x0e, 0x25, + 0x00, 0x23, 0x85, 0xb0, 0x6d, 0x44, 0x1a, 0x00, 0x00, 0x95, 0x04, 0x00, + 0x02, 0xf0, 0xd0, 0xfa, 0x0b, 0x4b, 0x98, 0x42, 0x12, 0xd0, 0x00, 0x28, + 0x0e, 0xdb, 0x0d, 0x22, 0xbf, 0x23, 0x6a, 0x44, 0x13, 0x70, 0x2b, 0x88, + 0x01, 0x92, 0x01, 0x22, 0x1b, 0x02, 0x00, 0x92, 0x04, 0x33, 0x00, 0x22, + 0x04, 0x21, 0x20, 0x00, 0xff, 0xf7, 0xeb, 0xfe, 0x05, 0xb0, 0x30, 0xbd, + 0x00, 0x20, 0xfb, 0xe7, 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x8b, 0xb0, + 0x04, 0x93, 0x10, 0xab, 0x1b, 0x88, 0x12, 0x25, 0x05, 0x93, 0x50, 0x4b, + 0x14, 0x00, 0x19, 0x43, 0x0e, 0x23, 0x04, 0xaa, 0x9b, 0x18, 0x19, 0x80, + 0x09, 0xab, 0xad, 0x18, 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x2b, 0x00, + 0x06, 0x00, 0x02, 0xf0, 0x65, 0xfa, 0x00, 0x28, 0x33, 0xdb, 0x09, 0x9b, + 0x2d, 0x88, 0x06, 0x93, 0x68, 0x2c, 0x30, 0xd9, 0x27, 0x00, 0x69, 0x3f, + 0x7c, 0x21, 0x38, 0x00, 0x04, 0xf0, 0xf0, 0xff, 0x01, 0x30, 0x83, 0xb2, + 0x7c, 0x21, 0x38, 0x00, 0x03, 0x93, 0x05, 0xf0, 0x6f, 0xf8, 0x09, 0x91, + 0x32, 0x6a, 0x05, 0x9b, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, + 0x1b, 0x02, 0x00, 0x22, 0x15, 0x21, 0x30, 0x00, 0xff, 0xf7, 0x49, 0xfe, + 0x00, 0x28, 0x12, 0xdb, 0x06, 0x9b, 0x37, 0x6a, 0x2d, 0x01, 0xed, 0x18, + 0x04, 0xaa, 0x7b, 0x78, 0x39, 0x78, 0xd2, 0x89, 0x01, 0x35, 0x1b, 0x02, + 0xad, 0xb2, 0x0b, 0x43, 0x9a, 0x42, 0x0a, 0xd0, 0x29, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0x5c, 0xfb, 0x2e, 0x48, 0x0b, 0xb0, 0xf0, 0xbd, 0x00, 0x23, + 0x09, 0x94, 0x03, 0x93, 0xd8, 0xe7, 0xfb, 0x78, 0xba, 0x78, 0x1b, 0x02, + 0x13, 0x43, 0x03, 0x9a, 0x93, 0x42, 0x05, 0xd0, 0x29, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0x4a, 0xfb, 0x26, 0x48, 0xec, 0xe7, 0x38, 0x22, 0x3b, 0x79, + 0x93, 0x43, 0xc0, 0x2b, 0x05, 0xd0, 0x29, 0x00, 0x30, 0x00, 0x02, 0xf0, + 0x3f, 0xfb, 0x22, 0x48, 0xe1, 0xe7, 0x03, 0x9b, 0x00, 0x2b, 0x2a, 0xd1, + 0x6b, 0x46, 0x64, 0x00, 0x1b, 0x8a, 0x3c, 0x19, 0xe3, 0x85, 0x80, 0x22, + 0x52, 0x00, 0x00, 0x92, 0x2b, 0x02, 0x01, 0x97, 0x00, 0x22, 0x07, 0x21, + 0x30, 0x00, 0xff, 0xf7, 0x68, 0xfe, 0x00, 0x28, 0xcd, 0xdb, 0x0f, 0x23, + 0x17, 0x4a, 0x2b, 0x40, 0x9b, 0x18, 0x0e, 0x22, 0x04, 0xa9, 0x52, 0x18, + 0x01, 0x92, 0x02, 0x22, 0x2d, 0x09, 0x5b, 0x00, 0x2d, 0x03, 0x00, 0x92, + 0x5b, 0x19, 0x00, 0x22, 0x04, 0x21, 0x30, 0x00, 0xff, 0xf7, 0x53, 0xfe, + 0x00, 0x28, 0xb8, 0xdb, 0x05, 0x99, 0x30, 0x00, 0x02, 0xf0, 0x10, 0xfb, + 0xb3, 0xe7, 0x68, 0x2c, 0x05, 0xd8, 0x64, 0x00, 0x6b, 0x46, 0x1b, 0x8a, + 0x3c, 0x19, 0x23, 0x81, 0xd1, 0xe7, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x04, 0xf0, 0xf4, 0xff, 0x4c, 0x00, 0xf3, 0xe7, 0x00, 0x80, 0xff, 0xff, + 0xbd, 0xd8, 0xff, 0xff, 0xbc, 0xd8, 0xff, 0xff, 0xbb, 0xd8, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x00, 0x24, 0x85, 0xb0, 0x0e, 0x00, + 0x1f, 0x00, 0x11, 0x88, 0x03, 0x93, 0x02, 0x94, 0x01, 0x94, 0x00, 0x94, + 0x23, 0x00, 0x05, 0x00, 0x02, 0xf0, 0x66, 0xfa, 0xa0, 0x42, 0x0a, 0xdb, + 0xfb, 0x21, 0x3a, 0x88, 0x33, 0x02, 0x12, 0x02, 0x00, 0x91, 0x05, 0x33, + 0x05, 0x32, 0x21, 0x00, 0x28, 0x00, 0x01, 0xf0, 0xe3, 0xff, 0x05, 0xb0, + 0xf0, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x93, 0xb0, 0x06, 0x91, 0x01, 0x33, + 0x11, 0x01, 0xcb, 0x18, 0xc4, 0x6c, 0x9b, 0xb2, 0x07, 0x00, 0x05, 0x93, + 0x00, 0x2c, 0x08, 0xd0, 0x10, 0x02, 0xf9, 0x68, 0x04, 0xf0, 0x34, 0xff, + 0x00, 0x23, 0x02, 0x00, 0x19, 0x00, 0x18, 0x00, 0xa0, 0x47, 0x05, 0x9b, + 0x0e, 0xad, 0x1b, 0x02, 0x08, 0x93, 0x05, 0x23, 0x01, 0x95, 0x00, 0x93, + 0x00, 0x22, 0x08, 0x9b, 0x15, 0x21, 0x38, 0x00, 0xff, 0xf7, 0x8f, 0xfd, + 0x04, 0x1e, 0x00, 0xda, 0xd5, 0xe0, 0x06, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0x81, 0xe0, 0x2b, 0x79, 0x7f, 0x2b, 0x00, 0xd9, 0x86, 0xe0, 0x06, 0x9b, + 0x1c, 0x00, 0x1d, 0x00, 0x04, 0x93, 0x06, 0x9b, 0x83, 0x4a, 0x01, 0x3b, + 0x9b, 0xb2, 0x93, 0x42, 0x00, 0xd9, 0x02, 0xe2, 0x81, 0x48, 0x06, 0x9b, + 0x02, 0x00, 0x0e, 0xae, 0x03, 0x43, 0x9b, 0xb2, 0x31, 0x88, 0x07, 0x93, + 0x33, 0x79, 0x0a, 0x43, 0x09, 0x90, 0x07, 0x98, 0x92, 0xb2, 0x82, 0x42, + 0x00, 0xd1, 0xb2, 0xe1, 0x5a, 0xb2, 0x00, 0x2a, 0x51, 0xda, 0x9a, 0x07, + 0x4f, 0xd4, 0x44, 0x22, 0x13, 0x42, 0x4c, 0xd0, 0x04, 0x25, 0x72, 0x88, + 0x1d, 0x40, 0x00, 0xd1, 0xee, 0xe0, 0x12, 0x23, 0x06, 0xa8, 0x1b, 0x18, + 0x0b, 0xad, 0x00, 0x93, 0x38, 0x00, 0x2b, 0x00, 0xff, 0xf7, 0x74, 0xfe, + 0x6f, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x3a, 0xd0, 0x00, 0x28, 0x00, 0xda, + 0x95, 0xe0, 0x2b, 0x88, 0x05, 0x9a, 0x93, 0x42, 0x33, 0xd1, 0x10, 0xad, + 0x2b, 0x00, 0x32, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0x72, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0x87, 0xe0, 0x12, 0x20, 0x06, 0xac, 0x00, 0x19, + 0x00, 0x88, 0x0e, 0xae, 0x2b, 0x88, 0x72, 0x88, 0x31, 0x88, 0x00, 0x90, + 0x38, 0x00, 0xff, 0xf7, 0xb1, 0xfe, 0x60, 0x4b, 0x04, 0x00, 0xc3, 0x18, + 0x02, 0x2b, 0x16, 0xd8, 0x29, 0x88, 0x38, 0x00, 0x02, 0xf0, 0x50, 0xfa, + 0x04, 0x1e, 0x70, 0xdb, 0x31, 0x88, 0x38, 0x00, 0xff, 0xf7, 0x7e, 0xfe, + 0x01, 0x23, 0xfd, 0x6c, 0x04, 0x00, 0x04, 0x93, 0x00, 0x2d, 0x06, 0xd0, + 0x00, 0x23, 0x32, 0x88, 0x18, 0x00, 0x06, 0x21, 0xa8, 0x47, 0x01, 0x23, + 0x04, 0x93, 0x00, 0x2c, 0x5d, 0xdb, 0xfc, 0x6c, 0x00, 0x2c, 0x04, 0xd0, + 0x00, 0x23, 0x05, 0x9a, 0x05, 0x21, 0x18, 0x00, 0xa0, 0x47, 0x05, 0x99, + 0x38, 0x00, 0x02, 0xf0, 0x2f, 0xfa, 0x04, 0x00, 0x92, 0xe1, 0x4b, 0x4b, + 0x06, 0x9a, 0x9a, 0x42, 0x00, 0xd0, 0x82, 0xe0, 0x2b, 0x79, 0xdb, 0x07, + 0x00, 0xd5, 0x7e, 0xe0, 0x04, 0x23, 0x2e, 0x79, 0x29, 0x88, 0x6a, 0x88, + 0x1e, 0x40, 0x4b, 0xd0, 0x06, 0xa8, 0x0e, 0x33, 0x1b, 0x18, 0x0b, 0xae, + 0x00, 0x93, 0x38, 0x00, 0x33, 0x00, 0xff, 0xf7, 0x0f, 0xfe, 0x3d, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x00, 0xd1, 0x6c, 0xe0, 0x00, 0x28, 0x30, 0xdb, + 0x33, 0x88, 0x05, 0x9a, 0x93, 0x42, 0x00, 0xd0, 0x60, 0xe0, 0x10, 0xae, + 0x33, 0x00, 0x2a, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0x0c, 0xff, + 0x04, 0x1e, 0x22, 0xdb, 0x06, 0xa8, 0x40, 0x8a, 0x33, 0x88, 0x6a, 0x88, + 0x29, 0x88, 0x00, 0x90, 0x38, 0x00, 0xff, 0xf7, 0x4f, 0xfe, 0x2f, 0x4b, + 0x04, 0x00, 0xc3, 0x18, 0x02, 0x2b, 0x17, 0xd8, 0x31, 0x88, 0x38, 0x00, + 0x02, 0xf0, 0xee, 0xf9, 0x04, 0x1e, 0x0e, 0xdb, 0x29, 0x88, 0x38, 0x00, + 0xff, 0xf7, 0x1c, 0xfe, 0xfe, 0x6c, 0x04, 0x00, 0x00, 0x2e, 0x04, 0xd0, + 0x00, 0x23, 0x06, 0x21, 0x18, 0x00, 0x2a, 0x88, 0xb0, 0x47, 0x00, 0x2c, + 0x34, 0xda, 0x20, 0x00, 0x13, 0xb0, 0xf0, 0xbd, 0xfe, 0x6c, 0x00, 0x2e, + 0xf7, 0xd0, 0x6b, 0x88, 0x2a, 0x88, 0x02, 0x21, 0x00, 0x20, 0xf1, 0xe7, + 0x1a, 0x4b, 0x00, 0x96, 0x19, 0x43, 0x89, 0xb2, 0x05, 0x9b, 0x38, 0x00, + 0x02, 0xf0, 0xd8, 0xf8, 0x17, 0x4b, 0x04, 0x00, 0x98, 0x42, 0xe6, 0xd1, + 0x29, 0x88, 0x14, 0x4b, 0x00, 0x96, 0x0b, 0x43, 0x99, 0xb2, 0x32, 0x00, + 0x33, 0x00, 0x38, 0x00, 0x02, 0xf0, 0x02, 0xf9, 0x04, 0x1e, 0x11, 0xd1, + 0x10, 0xab, 0x2a, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0xbe, 0xfe, + 0x04, 0x1e, 0xd4, 0xdb, 0xfb, 0x6c, 0x9c, 0x46, 0x00, 0x2b, 0x05, 0xd0, + 0x6b, 0x88, 0x2a, 0x88, 0x03, 0x21, 0x30, 0x00, 0x65, 0x46, 0xa8, 0x47, + 0x01, 0x23, 0x04, 0x93, 0x04, 0xe0, 0x00, 0x23, 0xf8, 0xe6, 0x01, 0x23, + 0x00, 0x24, 0x04, 0x93, 0x1d, 0x00, 0xf6, 0xe6, 0xfd, 0xff, 0x00, 0x00, + 0x00, 0x80, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, + 0xff, 0xff, 0x00, 0x00, 0x16, 0x26, 0x06, 0xab, 0xf6, 0x18, 0x00, 0x96, + 0x2b, 0x00, 0x07, 0x99, 0x38, 0x00, 0x02, 0xf0, 0x99, 0xf8, 0xc1, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x00, 0xd0, 0x75, 0xe0, 0x35, 0x80, 0x0e, 0xae, + 0x31, 0x88, 0x09, 0x9b, 0x0c, 0xad, 0x19, 0x43, 0x72, 0x88, 0x00, 0x23, + 0x89, 0xb2, 0x00, 0x95, 0x38, 0x00, 0x02, 0xf0, 0x87, 0xf8, 0xb8, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x68, 0xd1, 0x00, 0x23, 0x2b, 0x80, 0x2b, 0x88, + 0x00, 0x2b, 0x06, 0xd0, 0x16, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0x00, 0x2b, 0x00, 0xd0, 0x2d, 0xe7, 0x06, 0x9b, 0x06, 0xaa, 0x59, 0x04, + 0x1a, 0x23, 0x9b, 0x18, 0x00, 0x93, 0x00, 0x23, 0x49, 0x0c, 0x1a, 0x00, + 0x38, 0x00, 0x02, 0xf0, 0x6b, 0xf8, 0xaa, 0x4b, 0x04, 0x00, 0x98, 0x42, + 0x4f, 0xd1, 0x16, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x00, 0x22, 0x1a, 0x80, + 0x00, 0x23, 0x31, 0x88, 0x0d, 0xad, 0x49, 0x04, 0x1a, 0x00, 0x49, 0x0c, + 0x00, 0x95, 0x38, 0x00, 0x02, 0xf0, 0x58, 0xf8, 0xa0, 0x4b, 0x04, 0x00, + 0x98, 0x42, 0x3f, 0xd1, 0x00, 0x22, 0x0c, 0xab, 0x1a, 0x80, 0xf8, 0x23, + 0x16, 0x21, 0x10, 0xaa, 0x06, 0xa8, 0x13, 0x71, 0x09, 0x18, 0x73, 0x88, + 0x08, 0x88, 0x53, 0x80, 0x00, 0x28, 0x05, 0xd0, 0x1a, 0x21, 0x06, 0xac, + 0x09, 0x19, 0x09, 0x88, 0x00, 0x29, 0x2e, 0xd0, 0x29, 0x88, 0x00, 0x29, + 0x2b, 0xd0, 0x0c, 0xa9, 0x09, 0x88, 0x06, 0x91, 0x00, 0x29, 0x26, 0xd1, + 0x33, 0x88, 0x09, 0x99, 0x38, 0x00, 0x19, 0x43, 0x1e, 0x23, 0x11, 0x80, + 0x06, 0xa9, 0x5b, 0x18, 0x05, 0x99, 0xff, 0xf7, 0x29, 0xfe, 0xfd, 0x6c, + 0x04, 0x00, 0x00, 0x2d, 0x04, 0xd0, 0x73, 0x88, 0x32, 0x88, 0x03, 0x21, + 0x06, 0x98, 0xa8, 0x47, 0x00, 0x2c, 0x00, 0xda, 0x35, 0xe7, 0x01, 0x23, + 0x04, 0x93, 0xd4, 0xe6, 0x00, 0x28, 0x00, 0xdb, 0x87, 0xe7, 0x2e, 0xe7, + 0x00, 0x28, 0x96, 0xda, 0x2b, 0xe7, 0x00, 0x28, 0xb2, 0xda, 0x28, 0xe7, + 0x00, 0x28, 0xc0, 0xda, 0x25, 0xe7, 0x0c, 0xaa, 0x12, 0x88, 0x00, 0x2a, + 0x03, 0xd0, 0x2a, 0x88, 0x00, 0x2a, 0x00, 0xd1, 0xbf, 0xe6, 0x1a, 0x22, + 0x06, 0xa9, 0x52, 0x18, 0x12, 0x88, 0x00, 0x2a, 0x00, 0xd1, 0xb8, 0xe6, + 0x00, 0x28, 0x00, 0xd0, 0xb5, 0xe6, 0x6a, 0x46, 0xfd, 0x6c, 0x92, 0x8b, + 0x10, 0xac, 0x22, 0x80, 0x00, 0x2d, 0x02, 0xd0, 0x32, 0x88, 0x03, 0x21, + 0xa8, 0x47, 0x1e, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x05, 0x99, 0x22, 0x00, + 0x38, 0x00, 0xff, 0xf7, 0xe9, 0xfd, 0x04, 0x00, 0xc6, 0xe7, 0x69, 0x46, + 0x04, 0x22, 0x18, 0x20, 0x09, 0x5e, 0x1a, 0x40, 0x00, 0x29, 0x44, 0xda, + 0x00, 0x2a, 0x44, 0xd1, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0x94, 0xe6, + 0x9b, 0x07, 0x30, 0xd5, 0x12, 0x23, 0x06, 0xa9, 0x5b, 0x18, 0x0e, 0xae, + 0x72, 0x88, 0x06, 0x99, 0x00, 0x93, 0x38, 0x00, 0x0b, 0xab, 0xff, 0xf7, + 0xbd, 0xfc, 0x5d, 0x4b, 0x04, 0x00, 0x98, 0x42, 0xab, 0xd0, 0x00, 0x28, + 0x00, 0xda, 0xde, 0xe6, 0x01, 0x22, 0x06, 0xab, 0x04, 0x92, 0x9b, 0x8a, + 0x05, 0x9a, 0x93, 0x42, 0x00, 0xd0, 0x78, 0xe6, 0xfc, 0x6c, 0x00, 0x2c, + 0x04, 0xd0, 0x73, 0x88, 0x32, 0x88, 0x03, 0x21, 0x00, 0x20, 0xa0, 0x47, + 0xfd, 0x23, 0x01, 0x26, 0x10, 0xaa, 0x13, 0x70, 0x08, 0x9b, 0x01, 0x92, + 0x04, 0x33, 0x00, 0x96, 0x00, 0x22, 0x07, 0x21, 0x38, 0x00, 0xff, 0xf7, + 0xdc, 0xfb, 0x04, 0x00, 0x04, 0x96, 0x00, 0x2d, 0x00, 0xd0, 0x5e, 0xe6, + 0x00, 0x2c, 0x00, 0xd0, 0xb9, 0xe6, 0x04, 0x9c, 0x47, 0x4b, 0x67, 0x42, + 0x7c, 0x41, 0xe4, 0x18, 0xb3, 0xe6, 0x00, 0x2a, 0xba, 0xd1, 0x1a, 0x26, + 0x06, 0x9b, 0x0e, 0xad, 0x5b, 0x04, 0x5b, 0x0c, 0x09, 0x93, 0x06, 0xab, + 0xf6, 0x18, 0x6a, 0x88, 0x05, 0x9b, 0x00, 0x96, 0x09, 0x99, 0x38, 0x00, + 0x01, 0xf0, 0x8e, 0xff, 0x3b, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x4c, 0xd1, + 0x00, 0x23, 0x33, 0x80, 0x6a, 0x88, 0x0d, 0xad, 0x05, 0x9b, 0x00, 0x95, + 0x07, 0x99, 0x38, 0x00, 0x01, 0xf0, 0x80, 0xff, 0x34, 0x4b, 0x04, 0x00, + 0x98, 0x42, 0x41, 0xd1, 0x00, 0x23, 0x2b, 0x80, 0x1a, 0x23, 0x06, 0xaa, + 0x9b, 0x18, 0x28, 0x88, 0x1d, 0x88, 0xfc, 0x6c, 0x00, 0x2d, 0x3a, 0xd0, + 0x00, 0x28, 0x00, 0xd0, 0x25, 0xe6, 0x00, 0x2c, 0x04, 0xd0, 0x0e, 0xab, + 0x5b, 0x88, 0x06, 0x9a, 0x02, 0x21, 0xa0, 0x47, 0xf8, 0x23, 0x10, 0xaa, + 0x13, 0x71, 0x6b, 0x46, 0x1e, 0x26, 0x9b, 0x8b, 0x00, 0x25, 0x13, 0x80, + 0x0e, 0xab, 0x5b, 0x88, 0x07, 0x99, 0x53, 0x80, 0x06, 0xab, 0xf6, 0x18, + 0x01, 0x23, 0x02, 0x93, 0x2b, 0x00, 0x03, 0x96, 0x01, 0x95, 0x00, 0x95, + 0x38, 0x00, 0x01, 0xf0, 0xc1, 0xff, 0x04, 0x00, 0xa8, 0x42, 0x00, 0xda, + 0x61, 0xe6, 0xfb, 0x21, 0x32, 0x88, 0x08, 0x9b, 0x12, 0x02, 0x00, 0x91, + 0x05, 0x33, 0x05, 0x32, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, 0x3c, 0xfd, + 0x04, 0x00, 0xa8, 0x42, 0x00, 0xdb, 0xf4, 0xe5, 0x51, 0xe6, 0x00, 0x28, + 0xb2, 0xda, 0x4e, 0xe6, 0x00, 0x28, 0xbd, 0xda, 0x4b, 0xe6, 0x00, 0x28, + 0x00, 0xd1, 0xea, 0xe5, 0x0e, 0xab, 0x5b, 0x88, 0x00, 0x2c, 0x03, 0xd0, + 0x06, 0x9a, 0x03, 0x21, 0x28, 0x00, 0xa0, 0x47, 0xfc, 0x23, 0x10, 0xaa, + 0x13, 0x71, 0x6b, 0x46, 0x1e, 0x26, 0x9b, 0x8c, 0x00, 0x25, 0x13, 0x80, + 0x0e, 0xab, 0x5b, 0x88, 0x09, 0x99, 0x53, 0x80, 0x06, 0xab, 0xf6, 0x18, + 0x01, 0x23, 0x03, 0x96, 0x02, 0x93, 0x01, 0x95, 0x00, 0x95, 0x2b, 0x00, + 0xc2, 0xe7, 0xc0, 0x46, 0xee, 0xd8, 0xff, 0xff, 0xa9, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x8b, 0xb0, 0x05, 0x93, 0xc7, 0x6c, 0x43, 0x6a, 0x04, 0x00, + 0x03, 0x91, 0x16, 0x00, 0x11, 0x9d, 0x04, 0x93, 0x00, 0x2f, 0x08, 0xd0, + 0x10, 0x02, 0xe1, 0x68, 0x04, 0xf0, 0x60, 0xfc, 0x00, 0x23, 0x02, 0x00, + 0x19, 0x00, 0x01, 0x20, 0xb8, 0x47, 0x03, 0x9b, 0x4f, 0x49, 0x50, 0x4a, + 0x5b, 0x18, 0x9b, 0xb2, 0x93, 0x42, 0x00, 0xd9, 0x94, 0xe0, 0x05, 0x22, + 0x05, 0x9b, 0x36, 0x01, 0x01, 0x33, 0xf6, 0x18, 0xb7, 0xb2, 0x08, 0xae, + 0x00, 0x92, 0x3b, 0x02, 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, + 0xff, 0xf7, 0xb1, 0xfa, 0x00, 0x28, 0x16, 0xdb, 0x39, 0x22, 0x33, 0x79, + 0x93, 0x43, 0x72, 0x88, 0x00, 0x2a, 0x12, 0xd1, 0x80, 0x2b, 0x6e, 0xd1, + 0xe5, 0x6c, 0x00, 0x2d, 0x04, 0xd0, 0x03, 0x9b, 0x3a, 0x00, 0x05, 0x21, + 0x01, 0x20, 0xa8, 0x47, 0x39, 0x00, 0x20, 0x00, 0x01, 0xf0, 0xc2, 0xff, + 0x00, 0x28, 0x00, 0xdb, 0x3a, 0x48, 0x05, 0x00, 0x6b, 0xe0, 0xc0, 0x2b, + 0xfa, 0xd0, 0x03, 0x9b, 0x38, 0x4a, 0x5e, 0x04, 0x94, 0x46, 0x00, 0x23, + 0x60, 0x6a, 0x76, 0x0c, 0x61, 0x46, 0xc2, 0x5a, 0x0a, 0x40, 0xb2, 0x42, + 0x12, 0xd1, 0x04, 0x9a, 0xd3, 0x5e, 0x00, 0x2b, 0x58, 0xda, 0x30, 0x4d, + 0x36, 0xe0, 0x02, 0x33, 0x9c, 0x42, 0x4f, 0xd1, 0x2b, 0x68, 0x04, 0x98, + 0x59, 0x00, 0x01, 0x33, 0x0a, 0x52, 0x7f, 0x2b, 0x00, 0xd9, 0x00, 0x23, + 0x2b, 0x60, 0x49, 0xe0, 0x80, 0x22, 0x02, 0x33, 0x52, 0x00, 0x93, 0x42, + 0xe2, 0xd1, 0x0e, 0x23, 0x04, 0xaa, 0x9b, 0x18, 0x00, 0x93, 0x00, 0x23, + 0x03, 0x99, 0x1a, 0x00, 0x20, 0x00, 0x01, 0xf0, 0x9b, 0xfe, 0x00, 0x28, + 0x0a, 0xd0, 0x22, 0x4b, 0x98, 0x42, 0x24, 0xd1, 0x69, 0x46, 0x2b, 0x68, + 0x04, 0x9a, 0x89, 0x89, 0x5b, 0x00, 0x99, 0x52, 0x01, 0x22, 0x04, 0xe0, + 0x2b, 0x68, 0x04, 0x9a, 0x5b, 0x00, 0x9e, 0x52, 0x02, 0x00, 0x2b, 0x68, + 0x01, 0x33, 0x7f, 0x2b, 0x00, 0xd9, 0x00, 0x23, 0x2b, 0x60, 0x18, 0x4d, + 0x00, 0x2a, 0x20, 0xd0, 0xe6, 0x6c, 0x00, 0x2e, 0x04, 0xd0, 0x03, 0x9b, + 0x3a, 0x00, 0x04, 0x21, 0x01, 0x20, 0xb0, 0x47, 0x39, 0x00, 0x20, 0x00, + 0x01, 0xf0, 0x66, 0xff, 0x00, 0x28, 0x12, 0xda, 0xa3, 0xe7, 0x00, 0x22, + 0x90, 0x42, 0xe4, 0xda, 0x9f, 0xe7, 0xc0, 0x2b, 0x9c, 0xd0, 0x03, 0x9b, + 0x09, 0x48, 0x5a, 0x04, 0x63, 0x6a, 0x52, 0x0c, 0x5c, 0x1c, 0xff, 0x34, + 0x19, 0x88, 0x01, 0x40, 0x91, 0x42, 0xa8, 0xd1, 0x03, 0x4d, 0x28, 0x00, + 0x0b, 0xb0, 0xf0, 0xbd, 0x00, 0x80, 0xff, 0xff, 0xfe, 0x7f, 0x00, 0x00, + 0xaa, 0xd8, 0xff, 0xff, 0xff, 0x7f, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xa9, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0xc4, 0x6c, 0x87, 0xb0, 0x06, 0x00, + 0x00, 0x2c, 0x04, 0xd0, 0x00, 0x23, 0x1a, 0x00, 0x19, 0x00, 0x18, 0x00, + 0xa0, 0x47, 0x00, 0x24, 0x14, 0x4b, 0x05, 0x94, 0x01, 0x93, 0x04, 0x94, + 0x23, 0x00, 0x03, 0x94, 0x02, 0x94, 0x00, 0x94, 0x22, 0x00, 0x21, 0x00, + 0x30, 0x00, 0x01, 0xf0, 0x5b, 0xfc, 0x0f, 0x4b, 0x05, 0x00, 0x98, 0x42, + 0x15, 0xd0, 0xa0, 0x42, 0x07, 0xd0, 0xf7, 0x6c, 0xa7, 0x42, 0x04, 0xd0, + 0x02, 0x00, 0x23, 0x00, 0x01, 0x21, 0x20, 0x00, 0xb8, 0x47, 0xf4, 0x6c, + 0x00, 0x2c, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, 0x19, 0x00, 0x52, 0x00, + 0x18, 0x00, 0xa0, 0x47, 0x28, 0x00, 0x07, 0xb0, 0xf0, 0xbd, 0x25, 0x00, + 0xf1, 0xe7, 0xc0, 0x46, 0x41, 0x2c, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0xc4, 0x6c, 0x97, 0xb0, 0x05, 0x00, 0x00, 0x2c, 0x04, 0xd0, + 0x00, 0x23, 0x02, 0x20, 0x1a, 0x00, 0x19, 0x00, 0xa0, 0x47, 0x00, 0x23, + 0x07, 0x93, 0x1c, 0x00, 0xb0, 0xe1, 0x80, 0x22, 0x00, 0x21, 0x52, 0x00, + 0x68, 0x6a, 0x04, 0xf0, 0x18, 0xfc, 0x07, 0x9b, 0x1b, 0x02, 0x0f, 0x93, + 0x00, 0x23, 0x0a, 0x93, 0xee, 0x68, 0x0a, 0x9b, 0x9e, 0x42, 0x09, 0xd8, + 0x00, 0x23, 0x06, 0x93, 0x06, 0x9b, 0x07, 0x9a, 0x5b, 0x00, 0xd3, 0x18, + 0x9b, 0xb2, 0x0a, 0x93, 0x00, 0x23, 0x0a, 0xe2, 0xeb, 0x6c, 0x05, 0x93, + 0x00, 0x2b, 0x13, 0xd0, 0x0a, 0x9b, 0x37, 0x01, 0x58, 0x04, 0x39, 0x00, + 0x04, 0xf0, 0x42, 0xfb, 0x31, 0x00, 0x04, 0xf0, 0x3f, 0xfb, 0x39, 0x00, + 0x06, 0x00, 0x0f, 0x98, 0x04, 0xf0, 0x3a, 0xfb, 0x00, 0x23, 0x32, 0x18, + 0x19, 0x00, 0x02, 0x20, 0x05, 0x9e, 0xb0, 0x47, 0x0a, 0x9b, 0x1b, 0x01, + 0x01, 0x33, 0x9b, 0xb2, 0x06, 0x93, 0x0a, 0x9b, 0x01, 0x33, 0x1b, 0x01, + 0x0e, 0x93, 0x06, 0x9b, 0x0e, 0x9a, 0x93, 0x42, 0x01, 0xdb, 0x00, 0x23, + 0x69, 0xe1, 0x06, 0x9b, 0x00, 0x22, 0x1e, 0x02, 0x12, 0xab, 0x01, 0x93, + 0x05, 0x23, 0x15, 0x21, 0x00, 0x93, 0x28, 0x00, 0x33, 0x00, 0xff, 0xf7, + 0x86, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0xe5, 0xe0, 0x07, 0x9b, 0x06, 0x99, + 0x00, 0x22, 0x8b, 0x42, 0x07, 0xd8, 0xca, 0x0f, 0x07, 0x9b, 0xc6, 0x49, + 0x06, 0x98, 0x5b, 0x18, 0xd9, 0x17, 0x83, 0x42, 0x4a, 0x41, 0x06, 0x9b, + 0x07, 0x99, 0x58, 0x1a, 0x01, 0x21, 0x43, 0x08, 0x05, 0x93, 0x06, 0x9b, + 0x19, 0x40, 0x89, 0x00, 0x00, 0x2a, 0x0f, 0xd0, 0x12, 0xab, 0x1b, 0x79, + 0x5f, 0xb2, 0x00, 0x2f, 0x0a, 0xda, 0x01, 0x20, 0x03, 0x42, 0x07, 0xd1, + 0x6b, 0x6a, 0x05, 0x98, 0x1b, 0x18, 0x01, 0x20, 0x88, 0x40, 0x1f, 0x78, + 0x07, 0x43, 0x1f, 0x70, 0x12, 0xab, 0x1f, 0x79, 0x7b, 0xb2, 0x9c, 0x46, + 0x00, 0x23, 0x60, 0x46, 0x98, 0x42, 0x00, 0xdb, 0x22, 0xe1, 0x45, 0x20, + 0x07, 0x40, 0x40, 0x2f, 0x00, 0xd0, 0x1d, 0xe1, 0x9a, 0x42, 0x08, 0xd0, + 0x6b, 0x6a, 0x05, 0x9a, 0x02, 0x31, 0x98, 0x18, 0x01, 0x23, 0x8b, 0x40, + 0x02, 0x78, 0x13, 0x43, 0x03, 0x70, 0x2b, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x15, 0x21, 0x33, 0x00, 0x28, 0x00, + 0xff, 0xf7, 0x37, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0x96, 0xe0, 0x2b, 0x6a, + 0x05, 0x93, 0x12, 0xab, 0x5b, 0x88, 0x09, 0x93, 0x00, 0x2b, 0x00, 0xd0, + 0x81, 0xe0, 0x05, 0x9b, 0x2e, 0x33, 0x0b, 0x93, 0x69, 0x23, 0x0c, 0x93, + 0x00, 0x23, 0x08, 0x93, 0x08, 0x9b, 0x0b, 0x9a, 0x5b, 0x00, 0xd6, 0x5a, + 0x07, 0x9a, 0x00, 0x23, 0xb2, 0x42, 0x06, 0xd8, 0x13, 0x00, 0x96, 0x4a, + 0xf1, 0x0f, 0x9a, 0x18, 0xd3, 0x17, 0xb2, 0x42, 0x4b, 0x41, 0x94, 0x4a, + 0x94, 0x49, 0xb2, 0x18, 0x92, 0xb2, 0x8a, 0x42, 0x05, 0xd9, 0x00, 0x2b, + 0x00, 0xd1, 0x8b, 0xe0, 0x33, 0x07, 0x00, 0xd0, 0x92, 0xe0, 0x16, 0x27, + 0x09, 0x9b, 0x08, 0x9a, 0x28, 0x00, 0x9e, 0x18, 0x05, 0x9a, 0x05, 0x9b, + 0x51, 0x78, 0x1b, 0x78, 0x09, 0x02, 0x19, 0x43, 0x0c, 0xab, 0xff, 0x18, + 0xb6, 0xb2, 0x49, 0x04, 0x00, 0x23, 0x49, 0x0c, 0x00, 0x97, 0x32, 0x00, + 0x01, 0xf0, 0x2a, 0xfd, 0x85, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x51, 0xd1, + 0x00, 0x23, 0x3b, 0x80, 0x3b, 0x88, 0x00, 0x2b, 0x16, 0xd1, 0xfc, 0x20, + 0x05, 0x99, 0x05, 0x9a, 0x49, 0x78, 0x12, 0x78, 0x09, 0x02, 0x11, 0x43, + 0x14, 0xaa, 0x10, 0x71, 0x01, 0x20, 0x49, 0x04, 0x49, 0x0c, 0x11, 0x80, + 0x56, 0x80, 0x02, 0x90, 0x03, 0x97, 0x01, 0x93, 0x00, 0x93, 0x28, 0x00, + 0x01, 0xf0, 0x7c, 0xfd, 0x04, 0x1e, 0x37, 0xdb, 0x16, 0x23, 0x0c, 0xaa, + 0x05, 0x99, 0x9b, 0x18, 0x05, 0x9a, 0x49, 0x78, 0x12, 0x78, 0x09, 0x02, + 0x11, 0x43, 0x80, 0x22, 0x12, 0x02, 0x11, 0x43, 0x06, 0x9a, 0x1b, 0x88, + 0x28, 0x00, 0x00, 0x92, 0x32, 0x00, 0xff, 0xf7, 0x41, 0xfa, 0x6d, 0x4b, + 0x04, 0x00, 0xc3, 0x18, 0xee, 0x6c, 0x02, 0x2b, 0x28, 0xd8, 0x00, 0x2e, + 0x09, 0xd0, 0x05, 0x9a, 0x05, 0x9b, 0x52, 0x78, 0x1b, 0x78, 0x12, 0x02, + 0x1a, 0x43, 0x06, 0x21, 0x00, 0x23, 0x02, 0x20, 0xb0, 0x47, 0x06, 0x99, + 0x28, 0x00, 0x01, 0xf0, 0xd3, 0xfd, 0x04, 0x00, 0x25, 0xe0, 0x7c, 0x22, + 0x09, 0x9b, 0x0c, 0x92, 0x53, 0x43, 0x13, 0x3b, 0x9b, 0xb2, 0x09, 0x93, + 0x05, 0x9b, 0x08, 0x33, 0x0b, 0x93, 0x77, 0xe7, 0x00, 0x28, 0xad, 0xda, + 0xee, 0x6c, 0x00, 0x2e, 0x00, 0xd1, 0x80, 0xe0, 0x00, 0x23, 0x22, 0x00, + 0x01, 0x21, 0x02, 0x20, 0xb0, 0x47, 0x7a, 0xe0, 0x00, 0x2e, 0x0c, 0xd0, + 0x05, 0x9b, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, 0x13, 0x43, 0x05, 0x9a, + 0x11, 0x78, 0x52, 0x78, 0x12, 0x02, 0x0a, 0x43, 0x02, 0x21, 0x08, 0x00, + 0xb0, 0x47, 0x00, 0x2c, 0xe4, 0xdb, 0x01, 0x23, 0x08, 0x9a, 0x01, 0x32, + 0x08, 0x92, 0x00, 0x2b, 0x4c, 0xd1, 0x0c, 0x99, 0x8a, 0x42, 0x00, 0xd0, + 0x52, 0xe7, 0x47, 0xe0, 0x05, 0x22, 0x14, 0xaf, 0x00, 0x92, 0x33, 0x02, + 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xff, 0xf7, 0x6d, 0xf8, + 0x04, 0x1e, 0xcd, 0xdb, 0x12, 0xab, 0x1a, 0x88, 0x39, 0x88, 0x41, 0x4b, + 0x13, 0x40, 0x99, 0x42, 0x0b, 0xd1, 0x09, 0x9b, 0x08, 0x98, 0x79, 0x88, + 0x1b, 0x18, 0x99, 0x42, 0x05, 0xd1, 0x7a, 0x21, 0x3b, 0x79, 0x8b, 0x43, + 0x84, 0x2b, 0x00, 0xd1, 0x7d, 0xe0, 0x16, 0x27, 0x08, 0x99, 0x09, 0x9b, + 0x52, 0x04, 0x5b, 0x18, 0x9b, 0xb2, 0x0d, 0x93, 0x0c, 0xab, 0xff, 0x18, + 0x51, 0x0c, 0x33, 0x00, 0x00, 0x97, 0x0d, 0x9a, 0x28, 0x00, 0x01, 0xf0, + 0x7d, 0xfc, 0x2f, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x37, 0xd1, 0x00, 0x23, + 0x3b, 0x80, 0x3b, 0x88, 0x12, 0xae, 0x31, 0x88, 0x00, 0x2b, 0x33, 0xd1, + 0xec, 0x6c, 0x00, 0x2c, 0x03, 0xd0, 0x0a, 0x00, 0x02, 0x20, 0x06, 0x21, + 0xa0, 0x47, 0x31, 0x88, 0x28, 0x00, 0xff, 0xf7, 0x8d, 0xf9, 0x04, 0x1e, + 0x92, 0xdb, 0x00, 0x23, 0x06, 0x9a, 0x01, 0x32, 0x92, 0xb2, 0x06, 0x92, + 0x00, 0x2b, 0x00, 0xd1, 0x8f, 0xe6, 0x0a, 0x9a, 0x01, 0x32, 0x92, 0xb2, + 0x0a, 0x92, 0x00, 0x2b, 0x00, 0xd1, 0x59, 0xe6, 0xeb, 0x68, 0x07, 0x9a, + 0x1b, 0x01, 0x9a, 0x42, 0x00, 0xd2, 0x48, 0xe6, 0x00, 0x2c, 0x00, 0xd0, + 0x7a, 0xe7, 0xed, 0x6c, 0x00, 0x2d, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, + 0x19, 0x00, 0x52, 0x00, 0x02, 0x20, 0xa8, 0x47, 0x20, 0x00, 0x17, 0xb0, + 0xf0, 0xbd, 0x00, 0x28, 0xc7, 0xda, 0x6b, 0xe7, 0x06, 0x9a, 0x28, 0x00, + 0x00, 0x92, 0x0d, 0x9a, 0xff, 0xf7, 0x82, 0xf9, 0x0d, 0x4b, 0x04, 0x00, + 0xc3, 0x18, 0xef, 0x6c, 0x02, 0x2b, 0x19, 0xd8, 0x32, 0x88, 0x00, 0x2f, + 0x03, 0xd0, 0x00, 0x23, 0x06, 0x21, 0x02, 0x20, 0xb8, 0x47, 0x12, 0xab, + 0x19, 0x88, 0x28, 0x00, 0xff, 0xf7, 0x4c, 0xf9, 0x43, 0xe7, 0xc0, 0x46, + 0xff, 0x01, 0x00, 0x00, 0xff, 0xdf, 0xff, 0xff, 0xfd, 0xdf, 0x00, 0x00, + 0xee, 0xd8, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, 0xff, 0x7f, 0xff, 0xff, + 0x00, 0x2f, 0x00, 0xd1, 0x5b, 0xe7, 0x02, 0x21, 0x73, 0x88, 0x32, 0x88, + 0x08, 0x00, 0xb8, 0x47, 0x55, 0xe7, 0x01, 0x21, 0x07, 0x9b, 0xf7, 0x1a, + 0x6b, 0x6a, 0x7f, 0x08, 0x0e, 0x40, 0xb6, 0x00, 0xdb, 0x5d, 0x76, 0x18, + 0x33, 0x41, 0x0b, 0x40, 0x16, 0xd0, 0xec, 0x6c, 0x00, 0x2c, 0x03, 0xd0, + 0x00, 0x23, 0x05, 0x31, 0x02, 0x20, 0xa0, 0x47, 0x12, 0xab, 0x19, 0x88, + 0x28, 0x00, 0xff, 0xf7, 0x1d, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0x21, 0xe7, + 0x06, 0x99, 0x28, 0x00, 0x01, 0xf0, 0xe2, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0x1a, 0xe7, 0x01, 0x23, 0x01, 0x21, 0xb1, 0x40, 0x6a, 0x6a, 0xd7, 0x19, + 0x3a, 0x78, 0x0a, 0x43, 0x3a, 0x70, 0x2d, 0xe7, 0x01, 0x23, 0x08, 0x93, + 0x06, 0x9a, 0x6b, 0x6a, 0x9b, 0x5c, 0x08, 0x9a, 0x92, 0x00, 0x13, 0x41, + 0x07, 0x22, 0x1a, 0x40, 0x09, 0x92, 0x01, 0x2a, 0x00, 0xd0, 0x93, 0xe0, + 0x08, 0x9a, 0x0a, 0x9b, 0x12, 0xae, 0x9b, 0x18, 0x05, 0x22, 0x9b, 0xb2, + 0x05, 0x93, 0x00, 0x92, 0x1b, 0x02, 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, + 0x28, 0x00, 0xfe, 0xf7, 0x92, 0xff, 0x04, 0x1e, 0x00, 0xda, 0xf1, 0xe6, + 0x16, 0x27, 0x0c, 0xab, 0xff, 0x18, 0x11, 0xab, 0x72, 0x88, 0x31, 0x88, + 0x28, 0x00, 0x00, 0x93, 0x3b, 0x00, 0xff, 0xf7, 0xa5, 0xf8, 0x04, 0x1e, + 0x61, 0xd1, 0x80, 0x22, 0x3b, 0x88, 0x92, 0x01, 0x93, 0x42, 0x20, 0xd8, + 0x1a, 0x07, 0x1e, 0xd0, 0x05, 0x22, 0x14, 0xaf, 0x00, 0x92, 0x1b, 0x02, + 0x02, 0x00, 0x01, 0x97, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x71, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0xd0, 0xe6, 0x38, 0x4a, 0x33, 0x88, 0x13, 0x40, + 0x3a, 0x88, 0x93, 0x42, 0x04, 0xd1, 0x78, 0x22, 0x3b, 0x79, 0x93, 0x43, + 0x84, 0x2b, 0x45, 0xd0, 0x16, 0x23, 0x0c, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0x05, 0x9a, 0x93, 0x42, 0x4e, 0xd0, 0x11, 0xab, 0x1b, 0x88, 0x12, 0xae, + 0x72, 0x88, 0x31, 0x88, 0x28, 0x00, 0x00, 0x93, 0x05, 0x9b, 0xff, 0xf7, + 0xd1, 0xf8, 0x2b, 0x4b, 0x04, 0x00, 0xc3, 0x18, 0xef, 0x6c, 0x02, 0x2b, + 0x45, 0xd8, 0x00, 0x2f, 0x04, 0xd0, 0x32, 0x88, 0x00, 0x23, 0x06, 0x21, + 0x02, 0x20, 0xb8, 0x47, 0x05, 0x99, 0x28, 0x00, 0x01, 0xf0, 0x68, 0xfc, + 0x04, 0x1e, 0x00, 0xda, 0xa0, 0xe6, 0x31, 0x88, 0x28, 0x00, 0xff, 0xf7, + 0x95, 0xf8, 0x04, 0x00, 0x00, 0x2c, 0x00, 0xda, 0x98, 0xe6, 0x06, 0x9b, + 0x01, 0x33, 0x06, 0x93, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x0d, 0xe7, + 0x06, 0x9b, 0x1a, 0x00, 0x80, 0x23, 0x5b, 0x00, 0x9a, 0x42, 0x00, 0xd0, + 0x66, 0xe5, 0x80, 0x22, 0x92, 0x00, 0x94, 0x46, 0x07, 0x9b, 0x63, 0x44, + 0x9b, 0xb2, 0x07, 0x93, 0xfe, 0xe6, 0x13, 0x4b, 0x98, 0x42, 0x0c, 0xd1, + 0xec, 0x6c, 0x00, 0x2c, 0x04, 0xd0, 0x00, 0x23, 0x05, 0x9a, 0x05, 0x21, + 0x02, 0x20, 0xa0, 0x47, 0x05, 0x99, 0x28, 0x00, 0x01, 0xf0, 0x38, 0xfc, + 0x04, 0x00, 0x00, 0x2c, 0x00, 0xda, 0x6f, 0xe6, 0x08, 0x9b, 0x01, 0x2b, + 0x00, 0xd0, 0x59, 0xe7, 0x00, 0x23, 0x09, 0x93, 0xcf, 0xe7, 0x00, 0x2f, + 0xca, 0xd0, 0x02, 0x21, 0x73, 0x88, 0x32, 0x88, 0x08, 0x00, 0xb8, 0x47, + 0xc4, 0xe7, 0xc0, 0x46, 0xff, 0x7f, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, + 0xee, 0xd8, 0xff, 0xff, 0x80, 0x22, 0xf0, 0xb5, 0x06, 0x00, 0x89, 0xb0, + 0x00, 0x21, 0x52, 0x00, 0x40, 0x6a, 0x04, 0xf0, 0x3a, 0xf9, 0x00, 0x21, + 0xf4, 0x6c, 0x07, 0x91, 0x8c, 0x42, 0x03, 0xd0, 0x0b, 0x00, 0x0a, 0x00, + 0x01, 0x20, 0xa0, 0x47, 0x00, 0x24, 0x07, 0xab, 0x03, 0x93, 0x14, 0x4b, + 0x05, 0x94, 0x01, 0x93, 0x04, 0x94, 0x23, 0x00, 0x02, 0x94, 0x00, 0x94, + 0x22, 0x00, 0x21, 0x00, 0x30, 0x00, 0x01, 0xf0, 0x2f, 0xf9, 0x0f, 0x4b, + 0x05, 0x00, 0x98, 0x42, 0x15, 0xd0, 0xa0, 0x42, 0x07, 0xd0, 0xf7, 0x6c, + 0xa7, 0x42, 0x04, 0xd0, 0x01, 0x21, 0x02, 0x00, 0x23, 0x00, 0x08, 0x00, + 0xb8, 0x47, 0xf4, 0x6c, 0x00, 0x2c, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, + 0x19, 0x00, 0x52, 0x00, 0x01, 0x20, 0xa0, 0x47, 0x28, 0x00, 0x09, 0xb0, + 0xf0, 0xbd, 0x25, 0x00, 0xf1, 0xe7, 0xc0, 0x46, 0xe9, 0x31, 0x00, 0x00, + 0xa8, 0xd8, 0xff, 0xff, 0xf8, 0xb5, 0x06, 0x00, 0x0c, 0x00, 0x01, 0xf0, + 0xcf, 0xf9, 0x05, 0x1e, 0x0c, 0xdb, 0x24, 0x01, 0xa4, 0xb2, 0x27, 0x00, + 0x10, 0x37, 0xbf, 0xb2, 0x21, 0x00, 0x01, 0x34, 0x30, 0x00, 0xa4, 0xb2, + 0xfe, 0xf7, 0x96, 0xfe, 0xbc, 0x42, 0xf7, 0xd1, 0x28, 0x00, 0xf8, 0xbd, + 0xf0, 0xb5, 0x05, 0x00, 0x0f, 0x00, 0x00, 0x24, 0xc3, 0x68, 0x87, 0xb0, + 0x03, 0x93, 0x03, 0x6a, 0x02, 0x93, 0xa2, 0xb2, 0x04, 0x92, 0x03, 0x9a, + 0x23, 0x03, 0xa2, 0x42, 0x01, 0xd1, 0x1e, 0x48, 0x35, 0xe0, 0x2a, 0x6a, + 0x14, 0x21, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x28, 0x00, + 0x00, 0x22, 0xfe, 0xf7, 0x84, 0xfe, 0x02, 0x99, 0x18, 0x4e, 0x0b, 0x00, + 0x1e, 0x33, 0x05, 0x93, 0x00, 0x23, 0xb4, 0x46, 0x1a, 0x00, 0x98, 0x42, + 0x0b, 0xd0, 0x01, 0x28, 0x13, 0xd9, 0x01, 0x34, 0x00, 0x28, 0x1c, 0xd1, + 0xdd, 0xe7, 0x08, 0x88, 0x00, 0x28, 0x06, 0xd1, 0x01, 0x32, 0x92, 0xb2, + 0x02, 0x31, 0x05, 0x98, 0x81, 0x42, 0xf6, 0xd1, 0x05, 0xe0, 0x60, 0x45, + 0x03, 0xd1, 0x01, 0x33, 0x9b, 0xb2, 0xbb, 0x42, 0xf4, 0xd9, 0xd1, 0x18, + 0x0f, 0x29, 0x0a, 0xd1, 0xbb, 0x42, 0x08, 0xd8, 0xeb, 0x6b, 0x04, 0x99, + 0x9a, 0x1a, 0xea, 0x63, 0x28, 0x00, 0xff, 0xf7, 0xa3, 0xff, 0x07, 0xb0, + 0xf0, 0xbd, 0x01, 0x34, 0xbd, 0xe7, 0xc0, 0x46, 0xd3, 0xd8, 0xff, 0xff, + 0xff, 0xff, 0x00, 0x00, 0xf7, 0xb5, 0x80, 0x22, 0x04, 0x6a, 0x52, 0x00, + 0x0b, 0x03, 0x00, 0x92, 0x14, 0x21, 0x00, 0x22, 0x01, 0x94, 0x05, 0x00, + 0x26, 0x00, 0xfe, 0xf7, 0x42, 0xfe, 0x00, 0x22, 0x23, 0x00, 0x1e, 0x36, + 0x11, 0x00, 0x0b, 0x4f, 0x90, 0x42, 0x0d, 0xd0, 0xab, 0x6b, 0x9a, 0x1a, + 0xeb, 0x6b, 0xaa, 0x63, 0x59, 0x1a, 0xe9, 0x63, 0xfe, 0xbd, 0x1c, 0x88, + 0xbc, 0x42, 0x02, 0xd0, 0x00, 0x2c, 0x04, 0xd1, 0x01, 0x31, 0x02, 0x33, + 0x9e, 0x42, 0xf6, 0xd1, 0xee, 0xe7, 0x01, 0x32, 0xf9, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xf0, 0xb5, 0x1d, 0x00, 0xc3, 0x68, 0x93, 0xb0, + 0x05, 0x93, 0x03, 0x6a, 0x04, 0x00, 0x0c, 0x93, 0x05, 0x9b, 0x0f, 0x00, + 0x08, 0x92, 0x03, 0x93, 0x29, 0x2b, 0x01, 0xd9, 0x29, 0x23, 0x03, 0x93, + 0x00, 0x26, 0x80, 0x22, 0x08, 0x9b, 0x52, 0x00, 0x1e, 0x60, 0xff, 0x21, + 0x60, 0x6a, 0x04, 0xf0, 0x58, 0xf8, 0x63, 0x6a, 0x02, 0x96, 0x06, 0x93, + 0x03, 0x9b, 0x06, 0x9a, 0x5b, 0x00, 0xd3, 0x18, 0x03, 0x22, 0x09, 0x93, + 0x03, 0x33, 0x93, 0x43, 0x0a, 0x93, 0x06, 0x9b, 0x0a, 0x9a, 0x3b, 0x60, + 0x6b, 0x42, 0x5d, 0x41, 0x32, 0x23, 0x6d, 0x42, 0x2b, 0x40, 0x0f, 0x93, + 0x03, 0x9b, 0x9b, 0x00, 0x9b, 0x18, 0x0e, 0x93, 0x6a, 0x46, 0x12, 0x89, + 0x02, 0x9b, 0x0d, 0x92, 0x05, 0x99, 0x02, 0x9a, 0x1b, 0x03, 0x8a, 0x42, + 0x01, 0xd1, 0x00, 0x20, 0x4f, 0xe0, 0x22, 0x6a, 0x14, 0x21, 0x01, 0x92, + 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x20, 0x00, 0x00, 0x22, 0xfe, 0xf7, + 0xde, 0xfd, 0x0c, 0x9b, 0x00, 0x25, 0x19, 0x00, 0x2f, 0x00, 0x1e, 0x31, + 0x3a, 0x4e, 0xa8, 0x42, 0x47, 0xd0, 0x01, 0x28, 0x3b, 0xd1, 0x0e, 0x26, + 0x6b, 0x46, 0x0e, 0xaa, 0xb6, 0x18, 0x02, 0x22, 0x1b, 0x89, 0x15, 0x21, + 0x1b, 0x03, 0x00, 0x92, 0xfe, 0x33, 0x01, 0x96, 0x00, 0x22, 0x20, 0x00, + 0xfe, 0xf7, 0xc5, 0xfd, 0x00, 0x28, 0x2a, 0xdb, 0x23, 0x1d, 0xda, 0x8f, + 0x33, 0x88, 0x9a, 0x42, 0x35, 0xd9, 0xd3, 0x1a, 0x05, 0x22, 0x57, 0x43, + 0x0f, 0x9a, 0x9b, 0xb2, 0x53, 0x43, 0x7d, 0x1b, 0xeb, 0x18, 0x07, 0x93, + 0x00, 0x23, 0x06, 0x99, 0x27, 0x4d, 0x03, 0x9a, 0x93, 0x42, 0x0b, 0xda, + 0x0a, 0x9e, 0x9a, 0x00, 0x92, 0x19, 0x0e, 0x88, 0x0b, 0x91, 0xae, 0x42, + 0x22, 0xd1, 0x6b, 0x46, 0x9b, 0x8e, 0x0b, 0x80, 0x07, 0x9b, 0x13, 0x60, + 0x08, 0x9b, 0x08, 0x9a, 0x1b, 0x68, 0x04, 0x93, 0x01, 0x33, 0x13, 0x60, + 0x02, 0x9b, 0x01, 0x33, 0x02, 0x93, 0x00, 0x28, 0xa4, 0xd0, 0x13, 0xb0, + 0xf0, 0xbd, 0x1a, 0x88, 0xb2, 0x42, 0xbe, 0xd0, 0x00, 0x2a, 0x05, 0xd1, + 0x01, 0x37, 0xbf, 0xb2, 0x02, 0x33, 0x99, 0x42, 0xf5, 0xd1, 0xb6, 0xe7, + 0x01, 0x35, 0xad, 0xb2, 0xf8, 0xe7, 0x9b, 0x1a, 0xdb, 0x43, 0xc7, 0xe7, + 0x0b, 0x99, 0x16, 0x68, 0x07, 0x9f, 0x02, 0x31, 0xbe, 0x42, 0x19, 0xda, + 0x03, 0x99, 0x09, 0x9d, 0x02, 0x39, 0x04, 0x91, 0x0e, 0x99, 0x04, 0x9e, + 0x02, 0x3d, 0x0f, 0x1f, 0xb3, 0x42, 0x04, 0xdd, 0x69, 0x46, 0x0b, 0x9b, + 0x89, 0x8e, 0x19, 0x80, 0xca, 0xe7, 0xae, 0x1e, 0x08, 0x39, 0x36, 0x88, + 0x09, 0x68, 0x2e, 0x80, 0x39, 0x60, 0x04, 0x99, 0x01, 0x39, 0x04, 0x91, + 0x39, 0x00, 0xea, 0xe7, 0x01, 0x33, 0xb0, 0xe7, 0xff, 0xff, 0x00, 0x00, + 0xf0, 0xb5, 0x05, 0x00, 0x03, 0x6a, 0x9b, 0xb0, 0x0f, 0x93, 0x43, 0x6a, + 0x0c, 0x00, 0x14, 0x22, 0x00, 0x21, 0x15, 0xa8, 0x0a, 0x93, 0x03, 0xf0, + 0xa0, 0xff, 0x2b, 0x8a, 0xa3, 0x42, 0x06, 0xd1, 0x60, 0x1c, 0xe9, 0x68, + 0x03, 0xf0, 0x66, 0xff, 0x00, 0x23, 0x29, 0x82, 0x6b, 0x61, 0x23, 0x01, + 0x01, 0x33, 0x9b, 0xb2, 0x11, 0x93, 0x0f, 0x9b, 0x24, 0x03, 0x1b, 0x19, + 0x10, 0x93, 0x00, 0x23, 0x08, 0x93, 0x8f, 0xe1, 0x0c, 0x9a, 0x10, 0x9b, + 0x14, 0x21, 0x9b, 0x1a, 0x0d, 0x93, 0x2b, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x28, 0x00, 0x0d, 0x9b, 0xfe, 0xf7, + 0x30, 0xfd, 0x04, 0x00, 0x00, 0x2c, 0x07, 0xd1, 0x07, 0x9b, 0x0e, 0x9a, + 0x9b, 0x1a, 0x7f, 0x2b, 0x02, 0xdc, 0x07, 0x9b, 0x0e, 0x2b, 0x01, 0xdd, + 0x3b, 0x00, 0x88, 0xe0, 0x07, 0x9b, 0x0c, 0x9a, 0x5b, 0x00, 0xd3, 0x5a, + 0x07, 0x9a, 0x09, 0x93, 0x11, 0x9b, 0x9b, 0x18, 0x9b, 0xb2, 0x15, 0xaa, + 0x08, 0x93, 0x13, 0x78, 0x01, 0x2b, 0x15, 0xd0, 0x00, 0x2b, 0x04, 0xd0, + 0x02, 0x2b, 0x00, 0xd1, 0x8f, 0xe0, 0x23, 0x00, 0x6d, 0xe0, 0x6b, 0x46, + 0x24, 0x21, 0x59, 0x5e, 0x3b, 0x00, 0x00, 0x29, 0x00, 0xdc, 0x66, 0xe0, + 0x6b, 0x46, 0x9b, 0x8c, 0x17, 0x74, 0x53, 0x80, 0x6b, 0x46, 0x1b, 0x8c, + 0x13, 0x81, 0xee, 0xe7, 0x52, 0x88, 0x09, 0x99, 0x3b, 0x00, 0x8a, 0x42, + 0x59, 0xd1, 0x05, 0x22, 0x08, 0x9b, 0x13, 0xae, 0x00, 0x92, 0x1b, 0x02, + 0x22, 0x00, 0x01, 0x96, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0xef, 0xfc, + 0x04, 0x1e, 0x2d, 0xdb, 0x73, 0x88, 0x00, 0x20, 0x68, 0x2b, 0x05, 0xd9, + 0x69, 0x3b, 0x18, 0x00, 0x7c, 0x21, 0x03, 0xf0, 0x77, 0xfe, 0x01, 0x30, + 0x15, 0xab, 0x9e, 0x88, 0x86, 0x42, 0x3d, 0xd1, 0x13, 0xab, 0x1a, 0x79, + 0x7f, 0x2a, 0x1e, 0xd9, 0x1a, 0x22, 0x0c, 0xa9, 0x52, 0x18, 0x02, 0x92, + 0x08, 0x9a, 0x00, 0x93, 0x01, 0x92, 0x00, 0x22, 0x09, 0x9b, 0x11, 0x00, + 0x28, 0x00, 0x01, 0xf0, 0x25, 0xfa, 0x04, 0x1e, 0x0c, 0xdb, 0x2b, 0x6a, + 0x00, 0x22, 0x01, 0x93, 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x14, 0x21, + 0x0d, 0x9b, 0x28, 0x00, 0xfe, 0xf7, 0xc1, 0xfc, 0x04, 0x1e, 0x0e, 0xda, + 0x20, 0x00, 0x1b, 0xb0, 0xf0, 0xbd, 0x08, 0x99, 0x28, 0x00, 0x01, 0xf0, + 0xdf, 0xf9, 0x04, 0x1e, 0xf6, 0xdb, 0x1a, 0x23, 0x0c, 0xaa, 0x9b, 0x18, + 0x01, 0x22, 0x52, 0x42, 0x1a, 0x80, 0x13, 0xab, 0x58, 0x88, 0x1a, 0x23, + 0x0c, 0xaa, 0x9b, 0x18, 0x1b, 0x88, 0x09, 0x93, 0x00, 0x2e, 0x1c, 0xd1, + 0x17, 0x30, 0x6a, 0x46, 0x0a, 0x9b, 0x92, 0x8c, 0x40, 0x00, 0x1a, 0x52, + 0x3b, 0x00, 0x07, 0x9a, 0x01, 0x32, 0x07, 0x92, 0x00, 0x2b, 0x00, 0xd0, + 0x6a, 0xe7, 0x0b, 0x9a, 0x01, 0x32, 0x0b, 0x92, 0x00, 0x2b, 0x6b, 0xd0, + 0x0e, 0x9b, 0x80, 0x33, 0x0e, 0x93, 0x0c, 0x9b, 0x01, 0x3b, 0xff, 0x3b, + 0x0c, 0x93, 0x00, 0x2c, 0x00, 0xd1, 0x2d, 0xe1, 0xca, 0xe7, 0x68, 0x28, + 0x01, 0xd8, 0x04, 0x30, 0xdf, 0xe7, 0x69, 0x38, 0x7c, 0x21, 0x03, 0xf0, + 0x9b, 0xfe, 0x08, 0x1d, 0xd9, 0xe7, 0x09, 0x9b, 0x98, 0x4a, 0x99, 0x49, + 0x9a, 0x18, 0x92, 0xb2, 0x3b, 0x00, 0x8a, 0x42, 0xd7, 0xd8, 0x05, 0x22, + 0x08, 0x9b, 0x13, 0xae, 0x00, 0x92, 0x1b, 0x02, 0x22, 0x00, 0x01, 0x96, + 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x6d, 0xfc, 0x04, 0x1e, 0xab, 0xdb, + 0x33, 0x79, 0x7f, 0x2b, 0x2b, 0xd9, 0x1a, 0x23, 0x0c, 0xaa, 0x9b, 0x18, + 0x00, 0x22, 0x02, 0x93, 0x08, 0x9b, 0x00, 0x96, 0x01, 0x93, 0x11, 0x00, + 0x09, 0x9b, 0x28, 0x00, 0x01, 0xf0, 0xb2, 0xf9, 0x04, 0x1e, 0x00, 0xda, + 0x98, 0xe7, 0x00, 0x24, 0x0c, 0xab, 0x02, 0x94, 0x5b, 0x8b, 0x13, 0xa9, + 0x01, 0x93, 0x4b, 0x88, 0x03, 0x22, 0x00, 0x93, 0x28, 0x00, 0x09, 0x9b, + 0x01, 0xf0, 0x20, 0xfa, 0x2b, 0x6a, 0x22, 0x00, 0x01, 0x93, 0x80, 0x23, + 0x5b, 0x00, 0x00, 0x93, 0x14, 0x21, 0x0d, 0x9b, 0x28, 0x00, 0xfe, 0xf7, + 0x40, 0xfc, 0x04, 0x00, 0x00, 0x2c, 0x9b, 0xda, 0x7c, 0xe7, 0x08, 0x99, + 0x28, 0x00, 0x01, 0xf0, 0x5f, 0xf9, 0x04, 0x1e, 0xf6, 0xd1, 0x00, 0x21, + 0x08, 0x9b, 0x02, 0x91, 0x01, 0x93, 0x13, 0xab, 0x5b, 0x88, 0x02, 0x22, + 0x00, 0x93, 0x28, 0x00, 0x09, 0x9b, 0x01, 0xf0, 0xff, 0xf9, 0x87, 0xe7, + 0x00, 0x2c, 0x00, 0xd1, 0xcc, 0xe0, 0x65, 0xe7, 0x0b, 0x7c, 0x00, 0x2b, + 0x70, 0xd0, 0x07, 0x9b, 0x05, 0x22, 0xcb, 0x60, 0x01, 0x23, 0x0b, 0x70, + 0x08, 0x9b, 0x13, 0xaf, 0x00, 0x92, 0x1b, 0x02, 0x01, 0x97, 0x32, 0x00, + 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x13, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0x50, 0xe7, 0x78, 0x88, 0x37, 0x00, 0x68, 0x28, 0x05, 0xd9, 0x69, 0x38, + 0x7c, 0x21, 0x03, 0xf0, 0x9b, 0xfd, 0x01, 0x30, 0x87, 0xb2, 0x80, 0x23, + 0x15, 0xae, 0x71, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1a, 0x23, 0x0c, 0xaa, + 0x9b, 0x18, 0xb7, 0x80, 0x3a, 0x00, 0x00, 0x93, 0x28, 0x00, 0x00, 0x23, + 0x01, 0xf0, 0x2c, 0xf8, 0x56, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x0c, 0xd1, + 0x31, 0x89, 0x28, 0x00, 0x01, 0xf0, 0x16, 0xf9, 0x04, 0x1e, 0x00, 0xda, + 0x2c, 0xe7, 0x00, 0x23, 0x33, 0x70, 0x00, 0x2c, 0x00, 0xd0, 0x27, 0xe7, + 0x71, 0xe0, 0x00, 0x28, 0x00, 0xda, 0x23, 0xe7, 0x6a, 0x6a, 0x0c, 0xab, + 0x5b, 0x8b, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x1b, 0x02, + 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0xd6, 0xfb, 0x04, 0x1e, + 0x00, 0xda, 0x13, 0xe7, 0x0a, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x13, 0xd4, + 0x5a, 0xb2, 0x00, 0x2a, 0x12, 0xda, 0x9a, 0x07, 0x12, 0xd4, 0x04, 0x22, + 0x1a, 0x40, 0x11, 0xd1, 0x0a, 0x9b, 0x99, 0x78, 0xdb, 0x78, 0x1b, 0x02, + 0x0b, 0x43, 0xbb, 0x42, 0x0c, 0xd1, 0x0c, 0xab, 0x5b, 0x8b, 0x07, 0x92, + 0xf3, 0x80, 0xd0, 0xe7, 0x39, 0x4c, 0xf9, 0xe6, 0x39, 0x4c, 0xf7, 0xe6, + 0x39, 0x4c, 0xf5, 0xe6, 0x39, 0x4c, 0xf3, 0xe6, 0x39, 0x4c, 0xf1, 0xe6, + 0x02, 0x22, 0x0a, 0x70, 0x07, 0x93, 0x38, 0xe0, 0x80, 0x22, 0x00, 0x26, + 0xcb, 0x68, 0x12, 0x02, 0x07, 0x93, 0x4b, 0x88, 0x0e, 0x70, 0x09, 0x93, + 0x1a, 0x43, 0xcb, 0x88, 0x89, 0x88, 0x68, 0x6a, 0x13, 0xaf, 0xb1, 0x42, + 0x0b, 0xd1, 0x00, 0x90, 0x04, 0x97, 0x03, 0x91, 0x02, 0x91, 0x01, 0x91, + 0x28, 0x00, 0x01, 0xf0, 0x93, 0xfa, 0x04, 0x00, 0xb0, 0x42, 0xa8, 0xda, + 0xd2, 0xe6, 0x01, 0x93, 0x02, 0x97, 0x13, 0x00, 0x00, 0x96, 0x02, 0x00, + 0x31, 0x00, 0x28, 0x00, 0x01, 0xf0, 0xe0, 0xf8, 0x04, 0x1e, 0x00, 0xda, + 0xc6, 0xe6, 0x02, 0x96, 0x3b, 0x88, 0x69, 0x6a, 0x01, 0x93, 0x0a, 0x9b, + 0x28, 0x00, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, 0x13, 0x43, 0x00, 0x93, + 0x32, 0x00, 0x09, 0x9b, 0x01, 0xf0, 0x4c, 0xf9, 0x8b, 0xe7, 0x03, 0x23, + 0x0b, 0x70, 0x15, 0xab, 0x1a, 0x78, 0x00, 0x24, 0x03, 0x2a, 0x00, 0xd1, + 0xae, 0xe6, 0x7f, 0x22, 0x01, 0x27, 0x1c, 0x74, 0x07, 0x9b, 0xdb, 0x17, + 0x13, 0x40, 0x07, 0x9a, 0x9b, 0x18, 0xdb, 0x11, 0x0b, 0x93, 0xdb, 0x01, + 0x0e, 0x93, 0x0b, 0x9b, 0x0f, 0x9a, 0x1b, 0x02, 0xd3, 0x1a, 0x0c, 0x93, + 0x0b, 0x9b, 0x00, 0x2b, 0x00, 0xdc, 0x19, 0xe6, 0x15, 0xa9, 0x0e, 0x78, + 0x01, 0x2e, 0xa7, 0xd0, 0x00, 0x2e, 0x00, 0xd1, 0x2c, 0xe7, 0x02, 0x2e, + 0xd9, 0xd0, 0x00, 0x23, 0x9e, 0xe7, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, + 0xfe, 0x7f, 0x00, 0x00, 0xee, 0xd8, 0xff, 0xff, 0xe4, 0xd8, 0xff, 0xff, + 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, + 0xe3, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0f, 0x26, 0xc3, 0x68, 0x87, 0xb0, + 0x5e, 0x43, 0x83, 0x6b, 0x04, 0x00, 0xf6, 0x1a, 0xc3, 0x6b, 0x1e, 0x3e, + 0xf5, 0x1a, 0x43, 0x6b, 0x0f, 0x00, 0x03, 0x2b, 0x04, 0xd9, 0xfb, 0x23, + 0x6b, 0x43, 0x00, 0x20, 0x8b, 0x42, 0x19, 0xdc, 0x38, 0x00, 0xfb, 0x21, + 0xfa, 0x30, 0x03, 0xf0, 0xb7, 0xfc, 0x02, 0x90, 0x86, 0x42, 0x44, 0xdb, + 0x05, 0x23, 0x01, 0x93, 0x6b, 0x1e, 0x2b, 0x43, 0xdb, 0x0f, 0x05, 0xaa, + 0x04, 0xa9, 0x20, 0x00, 0xff, 0xf7, 0xf2, 0xfc, 0x00, 0x28, 0x05, 0xdb, + 0x05, 0x98, 0x00, 0x28, 0x04, 0xd1, 0x02, 0x9b, 0xab, 0x42, 0x32, 0xda, + 0x07, 0xb0, 0xf0, 0xbd, 0x04, 0x9b, 0x01, 0x22, 0x1e, 0x88, 0x23, 0x00, + 0x40, 0x33, 0x1a, 0x70, 0x31, 0x00, 0x20, 0x00, 0x03, 0x93, 0xff, 0xf7, + 0xa1, 0xfd, 0x00, 0x23, 0x03, 0x9a, 0x13, 0x70, 0x98, 0x42, 0xed, 0xdb, + 0x31, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xaa, 0xfc, 0x00, 0x28, 0xe7, 0xdb, + 0x31, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x3e, 0xfc, 0x00, 0x28, 0xe1, 0xdb, + 0x0f, 0x22, 0xe3, 0x68, 0x53, 0x43, 0xa2, 0x6b, 0x9b, 0x1a, 0xe2, 0x6b, + 0x1e, 0x3b, 0x9b, 0x1a, 0x00, 0x2d, 0x01, 0xdc, 0x9d, 0x42, 0x04, 0xd0, + 0x01, 0x9a, 0x01, 0x3a, 0x01, 0x92, 0x00, 0x2a, 0x05, 0xd1, 0xfb, 0x22, + 0x53, 0x43, 0xbb, 0x42, 0xcc, 0xda, 0x05, 0x48, 0xca, 0xe7, 0x62, 0x6b, + 0x02, 0x2a, 0x03, 0xd9, 0xfb, 0x22, 0x5a, 0x43, 0xba, 0x42, 0xf2, 0xda, + 0x1d, 0x00, 0xb1, 0xe7, 0xef, 0xd8, 0xff, 0xff, 0xf7, 0xb5, 0x84, 0x68, + 0x07, 0x00, 0x01, 0x91, 0x15, 0x00, 0x1e, 0x00, 0x63, 0x1c, 0x17, 0xd0, + 0x33, 0x00, 0x94, 0x42, 0x10, 0xd9, 0xa4, 0x1a, 0xb4, 0x42, 0x00, 0xdd, + 0x34, 0x00, 0x23, 0x00, 0x01, 0x9a, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, + 0x47, 0xfd, 0x00, 0x28, 0x07, 0xdb, 0x01, 0x9a, 0x33, 0x1b, 0x12, 0x19, + 0x01, 0x92, 0x2d, 0x19, 0x00, 0x2b, 0x03, 0xdc, 0x30, 0x00, 0xfe, 0xbd, + 0x33, 0x00, 0xf9, 0xe7, 0x01, 0x9a, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, + 0x7d, 0xfa, 0x00, 0x28, 0xf4, 0xda, 0xf4, 0xe7, 0x73, 0xb5, 0x01, 0xaa, + 0x05, 0x00, 0x02, 0xf0, 0x59, 0xfc, 0x04, 0x1e, 0x02, 0xda, 0x28, 0x63, + 0x20, 0x00, 0x76, 0xbd, 0x01, 0x9e, 0xb3, 0x8b, 0x9b, 0x06, 0xf9, 0xd4, + 0x33, 0x6a, 0x00, 0x2b, 0x04, 0xd1, 0x31, 0x00, 0x28, 0x00, 0xfe, 0xf7, + 0x29, 0xfb, 0x30, 0x62, 0x01, 0x98, 0x02, 0x6a, 0x00, 0x2a, 0xed, 0xd0, + 0x8a, 0x21, 0x56, 0x78, 0x49, 0x00, 0x71, 0x43, 0x6c, 0x6c, 0x14, 0x31, + 0x24, 0x69, 0x13, 0x8a, 0x61, 0x18, 0xd2, 0x68, 0xff, 0xf7, 0xb0, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0x28, 0x63, 0x01, 0x9b, 0x28, 0x00, 0x19, 0x6a, + 0xfe, 0xf7, 0x34, 0xfb, 0xd8, 0xe7, 0x00, 0x00, 0xf7, 0xb5, 0x04, 0x00, + 0x1d, 0x00, 0x83, 0x6d, 0x17, 0x00, 0x01, 0x91, 0x60, 0x22, 0x00, 0x21, + 0x00, 0x93, 0x0a, 0x9e, 0x03, 0xf0, 0xb5, 0xfc, 0x0c, 0x22, 0x01, 0x99, + 0x20, 0x00, 0x03, 0xf0, 0xa7, 0xfc, 0x00, 0x9b, 0x08, 0x9a, 0xa3, 0x65, + 0x80, 0x23, 0x9b, 0x00, 0xe3, 0x60, 0x7b, 0x1c, 0xff, 0x33, 0x67, 0x62, + 0x23, 0x62, 0x00, 0x21, 0x28, 0x00, 0x03, 0xf0, 0xa2, 0xfc, 0x03, 0x22, + 0x2a, 0x40, 0x05, 0xd0, 0x04, 0x23, 0x9b, 0x1a, 0x08, 0x9a, 0xed, 0x18, + 0xd3, 0x1a, 0x08, 0x93, 0xa5, 0x62, 0x30, 0x21, 0x08, 0x98, 0x03, 0xf0, + 0xdb, 0xfb, 0x03, 0x22, 0x09, 0x9b, 0xe0, 0x62, 0x1a, 0x40, 0x05, 0xd0, + 0x04, 0x23, 0x9b, 0x1a, 0x09, 0x9a, 0xf6, 0x1a, 0xd2, 0x18, 0x09, 0x92, + 0x03, 0x23, 0x1e, 0x42, 0x00, 0xd0, 0x9e, 0x43, 0x80, 0x22, 0x09, 0x9b, + 0x92, 0x01, 0x63, 0x64, 0x33, 0x00, 0x96, 0x42, 0x00, 0xd9, 0x13, 0x00, + 0xa3, 0x64, 0x20, 0x00, 0xfe, 0xf7, 0x08, 0xfb, 0x07, 0x4b, 0x20, 0x00, + 0xe3, 0x65, 0x00, 0xf0, 0x83, 0xfd, 0x00, 0x28, 0x01, 0xda, 0x20, 0x63, + 0xfe, 0xbd, 0x0b, 0x9b, 0x00, 0x20, 0xe3, 0x64, 0x01, 0x23, 0x54, 0x34, + 0x23, 0x70, 0xf7, 0xe7, 0x15, 0x03, 0x09, 0x20, 0xf8, 0xb5, 0xc2, 0x6d, + 0x10, 0x4b, 0x04, 0x00, 0x9a, 0x42, 0x0c, 0xd1, 0x07, 0x00, 0x54, 0x37, + 0x3b, 0x78, 0x00, 0x2b, 0x07, 0xd0, 0x00, 0x26, 0x83, 0x6a, 0x1d, 0x1d, + 0xe3, 0x6a, 0xb3, 0x42, 0x02, 0xd8, 0x00, 0x23, 0x3b, 0x70, 0xf8, 0xbd, + 0x00, 0x23, 0xe9, 0x5e, 0x00, 0x29, 0x07, 0xd0, 0x20, 0x00, 0xff, 0xf7, + 0x5b, 0xff, 0x00, 0x23, 0xe9, 0x5e, 0x20, 0x00, 0x02, 0xf0, 0x98, 0xfb, + 0x01, 0x36, 0x30, 0x35, 0xea, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, + 0x00, 0x6b, 0x70, 0x47, 0x00, 0x23, 0x03, 0x63, 0x70, 0x47, 0x00, 0x00, + 0xf0, 0xb5, 0x87, 0xb0, 0x17, 0x00, 0x03, 0x93, 0xc2, 0x6d, 0x3f, 0x4b, + 0x05, 0x00, 0x0e, 0x00, 0x9a, 0x42, 0x04, 0xd0, 0x3d, 0x4c, 0x2c, 0x63, + 0x20, 0x00, 0x07, 0xb0, 0xf0, 0xbd, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, + 0x00, 0x2b, 0x01, 0xd1, 0x39, 0x4c, 0xf4, 0xe7, 0x08, 0x00, 0x03, 0xf0, + 0x34, 0xfc, 0x1f, 0x28, 0x01, 0xd9, 0x37, 0x4c, 0xed, 0xe7, 0x32, 0x00, + 0x05, 0xa9, 0x28, 0x00, 0x02, 0xf0, 0xf8, 0xfa, 0x00, 0x28, 0x02, 0xda, + 0x28, 0x63, 0x04, 0xb2, 0xe4, 0xe7, 0x04, 0xaa, 0x31, 0x00, 0x28, 0x00, + 0x01, 0xf0, 0xb2, 0xfe, 0x04, 0x00, 0x7b, 0x07, 0x34, 0xd4, 0x00, 0x28, + 0x24, 0xda, 0x05, 0x9b, 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, + 0x55, 0xfb, 0x2c, 0x63, 0x24, 0xb2, 0xd1, 0xe7, 0x00, 0x2c, 0xf4, 0xdb, + 0x02, 0xab, 0x19, 0x89, 0x03, 0x9b, 0x05, 0x9a, 0x00, 0x93, 0x28, 0x00, + 0x3b, 0x00, 0x01, 0xf0, 0x27, 0xf9, 0x04, 0x1e, 0xe9, 0xdb, 0xbb, 0x07, + 0x06, 0xd5, 0x00, 0x22, 0x05, 0x98, 0x11, 0x00, 0x01, 0xf0, 0xbe, 0xfe, + 0x04, 0x1e, 0xe0, 0xdb, 0x00, 0x22, 0x05, 0x9b, 0x9a, 0x61, 0x04, 0x24, + 0x1c, 0x5f, 0xb5, 0xe7, 0x00, 0x28, 0xe3, 0xd1, 0x44, 0x23, 0x3b, 0x40, + 0x44, 0x2b, 0xdf, 0xd1, 0x05, 0x9b, 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, + 0x02, 0xf0, 0x2a, 0xfb, 0x14, 0x4c, 0xa6, 0xe7, 0x00, 0x28, 0xf1, 0xd0, + 0x13, 0x4b, 0x9c, 0x42, 0xd0, 0xd1, 0x0a, 0x23, 0x02, 0xa9, 0x5b, 0x18, + 0x00, 0x22, 0x19, 0x00, 0x28, 0x00, 0x02, 0xf0, 0xfb, 0xf9, 0x04, 0x1e, + 0xbd, 0xdb, 0x02, 0xab, 0x59, 0x89, 0x04, 0xab, 0x01, 0x93, 0x01, 0x23, + 0x32, 0x00, 0x00, 0x93, 0x28, 0x00, 0x00, 0x23, 0x00, 0xf0, 0xf2, 0xff, + 0x04, 0x1e, 0xb0, 0xdb, 0x02, 0x23, 0x9f, 0x43, 0xb8, 0xe7, 0xc0, 0x46, + 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, 0xf0, 0xd8, 0xff, 0xff, + 0xcc, 0xd8, 0xff, 0xff, 0xd2, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xf7, 0xb5, 0x16, 0x00, 0x1c, 0x00, 0xc2, 0x6d, 0x29, 0x4b, 0x05, 0x00, + 0x0f, 0x00, 0x9a, 0x42, 0x03, 0xd0, 0x28, 0x4c, 0x2c, 0x63, 0x20, 0x00, + 0xfe, 0xbd, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, + 0x24, 0x4c, 0xf5, 0xe7, 0x01, 0xaa, 0x02, 0xf0, 0x01, 0xfb, 0x00, 0x28, + 0x05, 0xda, 0x04, 0x00, 0x28, 0x63, 0x21, 0x4b, 0x9c, 0x42, 0x0d, 0xd0, + 0xeb, 0xe7, 0x01, 0x9b, 0x9a, 0x8b, 0x12, 0x07, 0x01, 0xd4, 0x1e, 0x4c, + 0xe4, 0xe7, 0x9b, 0x68, 0x01, 0x33, 0x05, 0xd1, 0x00, 0x2c, 0x03, 0xdd, + 0x19, 0x4b, 0x2b, 0x63, 0x00, 0x24, 0xdc, 0xe7, 0x39, 0x00, 0x28, 0x00, + 0xff, 0xf7, 0x88, 0xfe, 0x01, 0x98, 0x81, 0x69, 0x83, 0x68, 0x0a, 0x19, + 0x9a, 0x42, 0x14, 0xd3, 0x5c, 0x1a, 0x00, 0x2c, 0xee, 0xdd, 0x33, 0x00, + 0x22, 0x00, 0x02, 0xf0, 0xa5, 0xf8, 0x0f, 0x4b, 0x98, 0x42, 0x06, 0xd1, + 0x20, 0x00, 0x01, 0x9a, 0x93, 0x69, 0x1b, 0x19, 0x93, 0x61, 0x04, 0x00, + 0xc1, 0xe7, 0x00, 0x28, 0x07, 0xda, 0x28, 0x63, 0xf9, 0xe7, 0x33, 0x00, + 0x22, 0x00, 0x02, 0xf0, 0x93, 0xf8, 0x00, 0x28, 0xc5, 0xdb, 0x01, 0x9a, + 0x93, 0x69, 0x1b, 0x19, 0x93, 0x61, 0xc2, 0xe7, 0x15, 0x03, 0x09, 0x20, + 0xd8, 0xd8, 0xff, 0xff, 0xf0, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xda, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x15, 0x00, 0x1e, 0x00, 0xc2, 0x6d, + 0x2d, 0x4b, 0x85, 0xb0, 0x04, 0x00, 0x0f, 0x00, 0x9a, 0x42, 0x03, 0xd0, + 0x2b, 0x48, 0x20, 0x63, 0x05, 0xb0, 0xf0, 0xbd, 0x03, 0x00, 0x54, 0x33, + 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x28, 0x48, 0xf5, 0xe7, 0x03, 0xaa, + 0x02, 0xf0, 0x9e, 0xfa, 0x00, 0x28, 0xf0, 0xdb, 0x39, 0x00, 0x20, 0x00, + 0xff, 0xf7, 0x3a, 0xfe, 0x03, 0x9f, 0xbb, 0x68, 0x5a, 0x1c, 0x00, 0xd1, + 0x00, 0x23, 0x01, 0x2e, 0x05, 0xd0, 0x02, 0x2e, 0x06, 0xd0, 0x00, 0x2d, + 0x06, 0xda, 0x1e, 0x48, 0xdf, 0xe7, 0xba, 0x69, 0xad, 0x18, 0xf8, 0xe7, + 0xed, 0x18, 0xf6, 0xe7, 0x9d, 0x42, 0x02, 0xdd, 0xbb, 0x61, 0x1a, 0x48, + 0xd5, 0xe7, 0x00, 0x26, 0xb5, 0x42, 0x0d, 0xdd, 0x68, 0x1e, 0xfb, 0x21, + 0x03, 0xf0, 0x54, 0xfa, 0x83, 0xb2, 0x68, 0x2b, 0x06, 0xd9, 0x18, 0x00, + 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0x4c, 0xfa, 0x01, 0x30, 0x86, 0xb2, + 0x3b, 0x8a, 0xb3, 0x42, 0x11, 0xd0, 0xf9, 0x88, 0x80, 0x23, 0x0a, 0x27, + 0x1b, 0x02, 0x6f, 0x44, 0x19, 0x43, 0x00, 0x97, 0x00, 0x23, 0x32, 0x00, + 0x20, 0x00, 0x00, 0xf0, 0xdd, 0xfc, 0x00, 0x28, 0xb3, 0xdb, 0x03, 0x9b, + 0x3a, 0x88, 0x1e, 0x82, 0xda, 0x81, 0x03, 0x9b, 0x28, 0x00, 0x9d, 0x61, + 0xac, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xc8, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x2a, 0x4b, 0xc2, 0x6d, 0x85, 0xb0, 0x05, 0x00, 0x0f, 0x00, + 0x9a, 0x42, 0x02, 0xd0, 0x27, 0x4c, 0x2c, 0x63, 0x3e, 0xe0, 0x03, 0x00, + 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x24, 0x4c, 0xf6, 0xe7, + 0x08, 0x00, 0x03, 0xf0, 0xdc, 0xfa, 0x1f, 0x28, 0x01, 0xd9, 0x22, 0x4c, + 0xef, 0xe7, 0x00, 0x22, 0x03, 0xa9, 0x28, 0x00, 0x02, 0xf0, 0xa0, 0xf9, + 0x04, 0x1e, 0xe8, 0xdb, 0x0a, 0x26, 0x6e, 0x44, 0x32, 0x00, 0x39, 0x00, + 0x28, 0x00, 0x01, 0xf0, 0x5b, 0xfd, 0x04, 0x1e, 0x07, 0xd0, 0x03, 0x9b, + 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0x01, 0xfa, 0x00, 0x2c, + 0xd7, 0xdb, 0x00, 0x23, 0x31, 0x88, 0x03, 0x9a, 0x00, 0x93, 0x28, 0x00, + 0x00, 0xf0, 0xd8, 0xff, 0x04, 0x1e, 0x07, 0xd0, 0x03, 0x9b, 0x28, 0x00, + 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0xf0, 0xf9, 0x00, 0x2c, 0xc6, 0xdb, + 0x01, 0x22, 0x00, 0x21, 0x03, 0x98, 0x01, 0xf0, 0x69, 0xfd, 0x04, 0x1e, + 0x03, 0xd1, 0x00, 0x24, 0x20, 0x00, 0x05, 0xb0, 0xf0, 0xbd, 0x03, 0x9b, + 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0xdd, 0xf9, 0x00, 0x2c, + 0xb3, 0xdb, 0xf2, 0xe7, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xcc, 0xd8, 0xff, 0xff, 0x0d, 0x4b, 0xc2, 0x6d, + 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x9a, 0x42, 0x02, 0xd0, 0x0b, 0x48, + 0x20, 0x63, 0x10, 0xe0, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, + 0x01, 0xd1, 0x08, 0x48, 0xf6, 0xe7, 0xff, 0xf7, 0x7d, 0xfd, 0x00, 0x28, + 0xf2, 0xdb, 0x29, 0x00, 0x20, 0x00, 0x02, 0xf0, 0xb9, 0xf9, 0x00, 0x28, + 0xec, 0xdb, 0x70, 0xbd, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0x0e, 0x4b, 0xc2, 0x6d, 0x10, 0xb5, 0x04, 0x00, + 0x9a, 0x42, 0x02, 0xd0, 0x0c, 0x48, 0x20, 0x63, 0x10, 0xbd, 0x03, 0x00, + 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x09, 0x48, 0xf6, 0xe7, + 0x00, 0x21, 0xfe, 0xf7, 0xe5, 0xfd, 0x20, 0x00, 0xff, 0xf7, 0x06, 0xf9, + 0x20, 0x00, 0xfe, 0xf7, 0x19, 0xfe, 0x20, 0x00, 0x00, 0xf0, 0x52, 0xfb, + 0xea, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x12, 0x01, 0x5c, 0x1c, 0x14, 0x19, + 0x05, 0x22, 0x85, 0xb0, 0xa4, 0xb2, 0x02, 0xad, 0x0f, 0x00, 0x00, 0x92, + 0x23, 0x02, 0x01, 0x95, 0x10, 0x32, 0x00, 0x21, 0x0a, 0x9e, 0xfd, 0xf7, + 0xde, 0xff, 0x00, 0x28, 0x1d, 0xdb, 0x2b, 0x88, 0xbb, 0x42, 0x1c, 0xd1, + 0x0b, 0x9a, 0x69, 0x88, 0x12, 0x88, 0x8a, 0x42, 0x17, 0xd1, 0x29, 0x79, + 0x7c, 0x20, 0x0d, 0x00, 0x85, 0x43, 0x80, 0x2d, 0x11, 0xd1, 0x1b, 0xb2, + 0x00, 0x2b, 0x03, 0xda, 0x4b, 0x06, 0x01, 0xd4, 0x00, 0x2a, 0x0a, 0xd0, + 0x30, 0x1e, 0x06, 0xd0, 0x30, 0x88, 0x00, 0x1b, 0x44, 0x42, 0x60, 0x41, + 0x03, 0x4c, 0x40, 0x42, 0x20, 0x40, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x48, + 0xfb, 0xe7, 0xc0, 0x46, 0xaa, 0xd8, 0xff, 0xff, 0x7f, 0xb5, 0x1d, 0x00, + 0x1b, 0x4b, 0x0c, 0x00, 0x9a, 0x42, 0x24, 0xd0, 0x13, 0x07, 0x25, 0xd0, + 0x80, 0x23, 0x9b, 0x01, 0x9a, 0x42, 0x23, 0xd8, 0x13, 0x02, 0x04, 0x21, + 0x62, 0x5e, 0x05, 0x21, 0x02, 0xae, 0x00, 0x91, 0x01, 0x96, 0x11, 0x31, + 0xfd, 0xf7, 0xa1, 0xff, 0x00, 0x28, 0x13, 0xdb, 0x33, 0x79, 0xda, 0x07, + 0x16, 0xd4, 0x5a, 0xb2, 0x00, 0x2a, 0x15, 0xda, 0x9a, 0x07, 0x15, 0xd4, + 0x5b, 0x07, 0x15, 0xd4, 0x06, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x11, 0xda, + 0x73, 0x88, 0xab, 0x42, 0x02, 0xd0, 0x09, 0x48, 0x00, 0xe0, 0x09, 0x48, + 0x04, 0xb0, 0x70, 0xbd, 0x08, 0x48, 0xfb, 0xe7, 0x08, 0x48, 0xf9, 0xe7, + 0x08, 0x48, 0xf7, 0xe7, 0x08, 0x48, 0xf5, 0xe7, 0x08, 0x48, 0xf3, 0xe7, + 0x08, 0x48, 0xf1, 0xe7, 0xff, 0xff, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, + 0xde, 0xd8, 0xff, 0xff, 0xdd, 0xd8, 0xff, 0xff, 0xdc, 0xd8, 0xff, 0xff, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0x12, 0x01, 0x30, 0xb5, 0x01, 0x33, 0xd3, 0x18, + 0x13, 0x4a, 0x8f, 0xb0, 0x89, 0x18, 0x13, 0x4a, 0x89, 0xb2, 0x9b, 0xb2, + 0x91, 0x42, 0x1b, 0xd8, 0x2e, 0x22, 0x02, 0xac, 0x00, 0x92, 0x1b, 0x02, + 0x01, 0x94, 0x00, 0x22, 0x15, 0x21, 0xfd, 0xf7, 0x56, 0xff, 0x00, 0x28, + 0x11, 0xdb, 0x65, 0x88, 0x00, 0x2d, 0x0d, 0xd1, 0x3d, 0x22, 0x23, 0x79, + 0x93, 0x43, 0xc0, 0x2b, 0x08, 0xd1, 0x15, 0x21, 0x12, 0x98, 0x69, 0x44, + 0x03, 0xf0, 0x9b, 0xf9, 0x03, 0x00, 0x28, 0x00, 0x00, 0x2b, 0x00, 0xd0, + 0x03, 0x48, 0x0f, 0xb0, 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, + 0xfe, 0x7f, 0x00, 0x00, 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x05, 0x00, + 0x0c, 0x00, 0x21, 0x48, 0x01, 0x39, 0x89, 0xb2, 0x8f, 0xb0, 0x81, 0x42, + 0x01, 0xd9, 0x1f, 0x48, 0x27, 0xe0, 0x15, 0x99, 0x0e, 0x88, 0x14, 0x99, + 0x00, 0x29, 0x24, 0xd0, 0x21, 0xb2, 0x00, 0x29, 0x21, 0xda, 0x12, 0x01, + 0x01, 0x33, 0xd3, 0x18, 0x2e, 0x22, 0x9b, 0xb2, 0x02, 0xaf, 0x00, 0x92, + 0x1b, 0x02, 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xfd, 0xf7, + 0x18, 0xff, 0x00, 0x28, 0x0f, 0xdb, 0x7b, 0x88, 0x00, 0x2b, 0x0e, 0xd1, + 0x3d, 0x22, 0x3b, 0x79, 0x93, 0x43, 0xc0, 0x2b, 0x09, 0xd1, 0x15, 0x21, + 0x14, 0x98, 0x69, 0x44, 0x03, 0xf0, 0x5d, 0xf9, 0x00, 0x28, 0x02, 0xd1, + 0x0b, 0x48, 0x0f, 0xb0, 0xf0, 0xbd, 0x64, 0x04, 0x64, 0x0c, 0xa4, 0x1b, + 0xe3, 0x10, 0xff, 0x2b, 0xcd, 0xd8, 0x6a, 0x6a, 0xd2, 0x18, 0x07, 0x23, + 0x1c, 0x40, 0x06, 0x3b, 0xa3, 0x40, 0x11, 0x78, 0x0b, 0x43, 0x13, 0x70, + 0xc3, 0xe7, 0xc0, 0x46, 0xfd, 0xff, 0x00, 0x00, 0xaa, 0xd8, 0xff, 0xff, + 0xd9, 0xd8, 0xff, 0xff, 0x09, 0x4a, 0x91, 0x42, 0x06, 0xd1, 0x00, 0x2b, + 0x02, 0xd1, 0x43, 0x6b, 0x01, 0x33, 0x43, 0x63, 0x06, 0x48, 0x70, 0x47, + 0x00, 0x29, 0x03, 0xd1, 0xc3, 0x6b, 0x01, 0x33, 0xc3, 0x63, 0xf7, 0xe7, + 0x83, 0x6b, 0x01, 0x33, 0x83, 0x63, 0xf3, 0xe7, 0xff, 0xff, 0x00, 0x00, + 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x85, 0xb0, 0x01, 0x91, 0x02, 0x92, + 0x07, 0x89, 0x06, 0x00, 0x00, 0x25, 0x68, 0x2f, 0x06, 0xd9, 0x38, 0x00, + 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0x5a, 0xf8, 0x01, 0x30, 0x85, 0xb2, + 0x74, 0x89, 0x00, 0x20, 0x68, 0x2c, 0x06, 0xd9, 0x20, 0x00, 0x7c, 0x21, + 0x69, 0x38, 0x03, 0xf0, 0x4f, 0xf8, 0x01, 0x30, 0x80, 0xb2, 0x01, 0x9b, + 0x9d, 0x42, 0x1c, 0xd8, 0x83, 0x42, 0x1a, 0xd8, 0x00, 0x2b, 0x1a, 0xd0, + 0x7c, 0x23, 0x01, 0x9a, 0x5a, 0x43, 0x13, 0x3a, 0x92, 0xb2, 0x9b, 0x18, + 0x01, 0x34, 0x9b, 0xb2, 0xa3, 0x42, 0x00, 0xdd, 0x23, 0x00, 0x9b, 0xb2, + 0x03, 0x93, 0x3c, 0x1c, 0x97, 0x42, 0x00, 0xd2, 0x14, 0x1c, 0xa4, 0xb2, + 0x25, 0x1d, 0x14, 0x4f, 0x6d, 0x00, 0x03, 0x9a, 0xa3, 0xb2, 0x9a, 0x42, + 0x04, 0xd8, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x9a, 0x69, 0x23, 0xe6, 0xe7, + 0x01, 0x9a, 0x00, 0x2a, 0x0c, 0xd1, 0x02, 0x9b, 0x5b, 0x19, 0xda, 0x8c, + 0x02, 0x35, 0xba, 0x42, 0xf1, 0xd0, 0x33, 0x89, 0x31, 0x68, 0xe3, 0x1a, + 0x5b, 0x00, 0x5a, 0x52, 0x01, 0x34, 0xe6, 0xe7, 0x29, 0x00, 0x68, 0x2b, + 0x06, 0xd9, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0x96, 0xf8, + 0x04, 0x31, 0x49, 0x00, 0x02, 0x9b, 0x5a, 0x5a, 0xe8, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0x01, 0x00, 0x10, 0xb5, 0x21, 0x24, 0x03, 0x00, + 0x05, 0x48, 0x20, 0x31, 0x1a, 0x78, 0x00, 0x2a, 0x02, 0xd0, 0x01, 0x33, + 0x8b, 0x42, 0x00, 0xd1, 0x10, 0xbd, 0x60, 0x43, 0x50, 0x40, 0xf5, 0xe7, + 0x05, 0x15, 0x00, 0x00, 0x30, 0xb5, 0x1c, 0x00, 0x19, 0x4b, 0x85, 0xb0, + 0x9a, 0x42, 0x20, 0xd0, 0x13, 0x07, 0x21, 0xd0, 0x80, 0x23, 0x9b, 0x01, + 0x9a, 0x42, 0x1f, 0xd8, 0x13, 0x02, 0x00, 0x22, 0x8a, 0x5e, 0x05, 0x21, + 0x02, 0xad, 0x00, 0x91, 0x01, 0x95, 0x12, 0x31, 0xfd, 0xf7, 0x4d, 0xfe, + 0x00, 0x28, 0x0f, 0xdb, 0x2b, 0x79, 0xda, 0x07, 0x12, 0xd4, 0x5a, 0xb2, + 0x00, 0x2a, 0x11, 0xda, 0x9a, 0x07, 0x11, 0xd4, 0x5b, 0x07, 0x11, 0xd5, + 0x6b, 0x88, 0xa3, 0x42, 0x02, 0xd0, 0x09, 0x48, 0x00, 0xe0, 0x09, 0x48, + 0x05, 0xb0, 0x30, 0xbd, 0x08, 0x48, 0xfb, 0xe7, 0x08, 0x48, 0xf9, 0xe7, + 0x08, 0x48, 0xf7, 0xe7, 0x08, 0x48, 0xf5, 0xe7, 0x08, 0x48, 0xf3, 0xe7, + 0x08, 0x48, 0xf1, 0xe7, 0xff, 0xff, 0x00, 0x00, 0xe2, 0xd8, 0xff, 0xff, + 0xe1, 0xd8, 0xff, 0xff, 0xe0, 0xd8, 0xff, 0xff, 0xdf, 0xd8, 0xff, 0xff, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xe5, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0c, 0x00, 0x1f, 0x49, 0x06, 0x00, + 0x61, 0x18, 0x1f, 0x48, 0x8f, 0xb0, 0x89, 0xb2, 0x14, 0x9d, 0x81, 0x42, + 0x33, 0xd8, 0x01, 0x33, 0x12, 0x03, 0x1b, 0x02, 0x9b, 0x18, 0x2e, 0x22, + 0x02, 0xaf, 0x00, 0x92, 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x30, 0x00, + 0xfd, 0xf7, 0x03, 0xfe, 0x00, 0x28, 0x24, 0xd1, 0x7b, 0x88, 0x00, 0x2b, + 0x21, 0xd1, 0x79, 0x22, 0x3b, 0x79, 0x93, 0x43, 0x80, 0x2b, 0x1c, 0xd1, + 0xa8, 0x68, 0x00, 0x28, 0x08, 0xd0, 0x15, 0x21, 0x69, 0x44, 0x03, 0xf0, + 0x46, 0xf8, 0x00, 0x28, 0x02, 0xd1, 0x0d, 0x48, 0x0f, 0xb0, 0xf0, 0xbd, + 0x28, 0x88, 0x61, 0x04, 0x49, 0x0c, 0x81, 0x42, 0x0b, 0xd3, 0x6b, 0x88, + 0x8b, 0x42, 0x08, 0xd3, 0x08, 0x1a, 0x69, 0x68, 0x02, 0xf0, 0x74, 0xff, + 0x73, 0x6a, 0x18, 0x18, 0x03, 0x78, 0x01, 0x33, 0x03, 0x70, 0x04, 0x48, + 0xea, 0xe7, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, 0xfe, 0x7f, 0x00, 0x00, + 0xd9, 0xd8, 0xff, 0xff, 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x15, 0x00, + 0x1e, 0x00, 0x95, 0xb0, 0x1a, 0x9f, 0x02, 0x90, 0x03, 0x91, 0x00, 0x2f, + 0x02, 0xd1, 0x38, 0x00, 0x15, 0xb0, 0xf0, 0xbd, 0x3c, 0x00, 0x40, 0x2f, + 0x00, 0xd9, 0x40, 0x24, 0x04, 0xab, 0x01, 0x93, 0x00, 0x94, 0x33, 0x00, + 0x03, 0x9a, 0x0b, 0x21, 0x02, 0x98, 0xfd, 0xf7, 0xb8, 0xfd, 0x00, 0x28, + 0xee, 0xdb, 0x04, 0xab, 0x01, 0x93, 0x00, 0x94, 0x2b, 0x00, 0x03, 0x9a, + 0x0f, 0x21, 0x02, 0x98, 0xfd, 0xf7, 0x11, 0xfe, 0x00, 0x28, 0xe3, 0xdb, + 0x3f, 0x1b, 0x36, 0x19, 0x2d, 0x19, 0xdc, 0xe7, 0xf0, 0xb5, 0x14, 0x00, + 0x0f, 0x22, 0x8d, 0xb0, 0x06, 0x93, 0x12, 0xab, 0x1b, 0x88, 0x06, 0x00, + 0x0b, 0x93, 0xc3, 0x68, 0x0f, 0x00, 0x5a, 0x43, 0x07, 0x92, 0x02, 0x6a, + 0x09, 0x92, 0x0e, 0x2c, 0x00, 0xdc, 0xa4, 0xe0, 0x01, 0x37, 0xbf, 0xb2, + 0xbb, 0x42, 0x51, 0xd9, 0x00, 0x24, 0x3b, 0x03, 0x03, 0x93, 0x07, 0x9b, + 0x00, 0x2b, 0x4f, 0xdd, 0x7f, 0x22, 0xe3, 0x17, 0x13, 0x40, 0x1b, 0x19, + 0xdb, 0x11, 0xda, 0x01, 0x05, 0x92, 0x09, 0x9a, 0x1b, 0x02, 0xd3, 0x1a, + 0x04, 0x93, 0x03, 0x9a, 0x09, 0x9b, 0x14, 0x21, 0x9b, 0x18, 0x04, 0x9a, + 0x30, 0x00, 0x9b, 0x1a, 0x0a, 0x93, 0x33, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x0a, 0x9b, 0xfd, 0xf7, 0x6f, 0xfd, + 0x25, 0x00, 0x07, 0x9b, 0x02, 0x90, 0x08, 0x93, 0x08, 0x9b, 0x2c, 0x00, + 0x07, 0x93, 0x02, 0x9b, 0x00, 0x2b, 0x05, 0xd1, 0x05, 0x9b, 0xeb, 0x1a, + 0x7f, 0x2b, 0x01, 0xdc, 0x0e, 0x2d, 0x28, 0xdd, 0x05, 0x9b, 0x80, 0x33, + 0x05, 0x93, 0x04, 0x9b, 0x01, 0x3b, 0xff, 0x3b, 0x04, 0x93, 0x02, 0x9b, + 0x00, 0x2b, 0x02, 0xd1, 0x05, 0x9b, 0x80, 0x2b, 0xd1, 0xd1, 0x01, 0x37, + 0xf3, 0x68, 0xbf, 0xb2, 0x9f, 0x42, 0x55, 0xd2, 0x80, 0x22, 0x52, 0x01, + 0x94, 0x46, 0x03, 0x9b, 0x63, 0x44, 0x03, 0x93, 0x00, 0x24, 0x02, 0x9b, + 0xa3, 0x42, 0xb4, 0xd0, 0x02, 0x9b, 0x00, 0x2b, 0x06, 0xdb, 0x03, 0xe0, + 0x04, 0x24, 0x06, 0x9b, 0x1c, 0x40, 0x4d, 0xd0, 0x29, 0x4b, 0x02, 0x93, + 0x02, 0x98, 0x0d, 0xb0, 0xf0, 0xbd, 0x01, 0x22, 0x06, 0x9b, 0x13, 0x42, + 0x05, 0xd0, 0x04, 0x9a, 0x6b, 0x00, 0xd3, 0x5a, 0x0b, 0x9a, 0x93, 0x42, + 0x2f, 0xd1, 0x16, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x1f, 0x80, 0x17, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x1d, 0x60, 0x13, 0x9b, 0x00, 0x2b, 0xe7, 0xd0, + 0x02, 0x22, 0x06, 0x9b, 0x0b, 0x99, 0x13, 0x42, 0x02, 0xd1, 0x04, 0x9a, + 0x6b, 0x00, 0xd1, 0x5a, 0x15, 0x9b, 0x3a, 0x00, 0x01, 0x93, 0x14, 0x9b, + 0x30, 0x00, 0x00, 0x93, 0x13, 0x9c, 0x2b, 0x00, 0xa0, 0x47, 0x15, 0x4b, + 0xc3, 0x18, 0x01, 0x2b, 0x21, 0xd8, 0x14, 0x4b, 0x98, 0x42, 0x0c, 0xd1, + 0x33, 0x6a, 0x00, 0x22, 0x01, 0x93, 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, + 0x14, 0x21, 0x0a, 0x9b, 0x30, 0x00, 0xfd, 0xf7, 0xfe, 0xfc, 0x00, 0x28, + 0x11, 0xdb, 0x08, 0x9b, 0x01, 0x35, 0x01, 0x3b, 0x08, 0x93, 0x8b, 0xe7, + 0x04, 0x23, 0x06, 0x9a, 0x13, 0x40, 0xb7, 0xd1, 0x03, 0x93, 0x1f, 0x00, + 0xa8, 0xe7, 0x0b, 0x03, 0x03, 0x93, 0x5e, 0xe7, 0x03, 0x94, 0x27, 0x00, + 0x5b, 0xe7, 0x02, 0x90, 0xae, 0xe7, 0xc0, 0x46, 0xa8, 0xd8, 0xff, 0xff, + 0x57, 0x27, 0x00, 0x00, 0xa9, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x04, 0x00, + 0x0d, 0x03, 0x0f, 0x00, 0x80, 0x21, 0x85, 0xb0, 0x49, 0x01, 0xa3, 0x68, + 0x28, 0x00, 0x98, 0x47, 0x63, 0x6b, 0x22, 0x00, 0x01, 0x33, 0x63, 0x63, + 0x02, 0x26, 0x2b, 0x00, 0x42, 0x32, 0x01, 0x92, 0xfe, 0x33, 0x00, 0x96, + 0x00, 0x22, 0x19, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x2c, 0xfd, 0x00, 0x28, + 0x1a, 0xdb, 0xe3, 0x68, 0x0e, 0x22, 0xdb, 0x1b, 0x0d, 0x4f, 0x6a, 0x44, + 0x5f, 0x40, 0x2b, 0x00, 0x17, 0x80, 0xfc, 0x33, 0x01, 0x92, 0x00, 0x96, + 0x00, 0x22, 0x19, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x1a, 0xfd, 0x00, 0x28, + 0x08, 0xdb, 0x80, 0x22, 0x04, 0x34, 0xe3, 0x8f, 0x12, 0x02, 0x01, 0x33, + 0x9b, 0xb2, 0x93, 0x42, 0x02, 0xd0, 0xe3, 0x87, 0x05, 0xb0, 0xf0, 0xbd, + 0x00, 0x23, 0xfa, 0xe7, 0x29, 0x04, 0x00, 0x00, 0xf0, 0xb5, 0x00, 0x27, + 0x04, 0x00, 0x8b, 0xb0, 0x3b, 0x4d, 0x08, 0xab, 0x1f, 0x80, 0x07, 0x95, + 0x08, 0xae, 0x33, 0x88, 0xe2, 0x68, 0x93, 0x42, 0x24, 0xd3, 0x38, 0x4a, + 0x7b, 0x1b, 0x01, 0x35, 0x93, 0x42, 0x00, 0xdc, 0x7d, 0x1c, 0x23, 0x1d, + 0xad, 0xb2, 0xdd, 0x87, 0x07, 0x9b, 0x1a, 0x00, 0x31, 0x4b, 0x9a, 0x42, + 0x58, 0xd1, 0x00, 0x25, 0x09, 0xab, 0x05, 0x93, 0x30, 0x4b, 0x65, 0x63, + 0x01, 0x93, 0xa5, 0x63, 0x2b, 0x00, 0xe5, 0x63, 0x04, 0x96, 0x03, 0x95, + 0x02, 0x95, 0x00, 0x95, 0x2a, 0x00, 0x29, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0xd1, 0xfe, 0x2a, 0x4b, 0x98, 0x42, 0x41, 0xd1, 0x28, 0x00, 0x3f, 0xe0, + 0x1a, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, 0x1b, 0x03, + 0x00, 0x92, 0xfc, 0x33, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, 0xfd, 0xf7, + 0x66, 0xfc, 0x00, 0x28, 0x30, 0xdb, 0xe2, 0x68, 0x33, 0x88, 0xd1, 0x1a, + 0x1f, 0x4a, 0x4a, 0x40, 0x02, 0xa9, 0x49, 0x8b, 0x92, 0xb2, 0x91, 0x42, + 0x05, 0xd0, 0x07, 0x9a, 0x11, 0x00, 0x17, 0x4a, 0x91, 0x42, 0x20, 0xd1, + 0x07, 0x93, 0x02, 0x22, 0x1b, 0x03, 0x09, 0xae, 0x00, 0x92, 0xfe, 0x33, + 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x49, 0xfc, + 0x00, 0x28, 0x13, 0xdb, 0x33, 0x88, 0x0e, 0x4a, 0x93, 0x42, 0x09, 0xd0, + 0x1a, 0x1c, 0xab, 0x42, 0x00, 0xd9, 0x2a, 0x1c, 0x95, 0xb2, 0x1a, 0x1c, + 0xbb, 0x42, 0x00, 0xd2, 0x3a, 0x1c, 0x97, 0xb2, 0x08, 0xaa, 0x13, 0x88, + 0x01, 0x33, 0x13, 0x80, 0x96, 0xe7, 0x0a, 0x48, 0x0b, 0xb0, 0xf0, 0xbd, + 0x07, 0x99, 0x20, 0x00, 0xff, 0xf7, 0x4c, 0xff, 0x00, 0x28, 0xa0, 0xda, + 0xf6, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0xff, 0x7f, 0x00, 0x00, + 0xc9, 0x49, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, 0x29, 0x04, 0x00, 0x00, + 0xd7, 0xd8, 0xff, 0xff, 0x10, 0xb5, 0x86, 0xb0, 0x09, 0x9c, 0x00, 0x93, + 0x05, 0x94, 0x08, 0x9c, 0x01, 0x23, 0x04, 0x94, 0x00, 0x24, 0x03, 0x94, + 0x02, 0x94, 0x01, 0x94, 0xff, 0xf7, 0x68, 0xfe, 0x02, 0x4b, 0x98, 0x42, + 0x00, 0xd1, 0x02, 0x48, 0x06, 0xb0, 0x10, 0xbd, 0xa8, 0xd8, 0xff, 0xff, + 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x1e, 0x00, 0x03, 0x00, 0x85, 0xb0, + 0x03, 0x92, 0x40, 0x33, 0x0f, 0x00, 0x19, 0x78, 0x04, 0x00, 0x0a, 0x9d, + 0x00, 0x29, 0x0b, 0xd0, 0x01, 0x95, 0x00, 0x96, 0x12, 0x4b, 0x03, 0x9a, + 0x39, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xd4, 0xff, 0x00, 0x28, 0x10, 0xd0, + 0x05, 0xb0, 0xf0, 0xbd, 0x43, 0x6b, 0x01, 0x2b, 0xf0, 0xd8, 0xfe, 0xf7, + 0x49, 0xfd, 0x0c, 0x4b, 0x98, 0x42, 0x01, 0xd0, 0x00, 0x28, 0xf3, 0xdb, + 0x63, 0x6b, 0x01, 0x2b, 0xe6, 0xd8, 0x09, 0x48, 0xee, 0xe7, 0x33, 0x88, + 0x23, 0x82, 0x2b, 0x68, 0x01, 0x33, 0x63, 0x61, 0x2b, 0x68, 0x00, 0x2b, + 0xe6, 0xd1, 0x63, 0x6b, 0x01, 0x3b, 0x63, 0x63, 0xe2, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xd3, 0xd8, 0xff, 0xff, 0xef, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x1e, 0x27, 0x8b, 0xb0, 0x6f, 0x44, 0x07, 0xae, 0x3a, 0x80, + 0x33, 0x80, 0x04, 0x00, 0x0d, 0x00, 0xc2, 0x69, 0x01, 0x8b, 0x00, 0x20, + 0x83, 0x42, 0x00, 0xd0, 0x30, 0x00, 0x22, 0x26, 0x09, 0xab, 0x05, 0x93, + 0x0f, 0x4b, 0x6e, 0x44, 0x02, 0x90, 0x01, 0x93, 0x04, 0x96, 0x01, 0x23, + 0x03, 0x97, 0x00, 0x95, 0x20, 0x00, 0xff, 0xf7, 0x07, 0xfe, 0x0b, 0x4b, + 0x98, 0x42, 0x0f, 0xd0, 0x00, 0x28, 0x0b, 0xdb, 0x10, 0x9b, 0x31, 0x88, + 0x09, 0x9a, 0x00, 0x2b, 0x04, 0xd0, 0x0b, 0x01, 0x9b, 0x18, 0x10, 0x9d, + 0x01, 0x33, 0x2b, 0x80, 0x21, 0x83, 0xe2, 0x61, 0x0b, 0xb0, 0xf0, 0xbd, + 0x02, 0x48, 0xfb, 0xe7, 0xc5, 0x47, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x1e, 0x27, 0x8b, 0xb0, 0x6f, 0x44, + 0x07, 0xae, 0x3a, 0x80, 0x33, 0x80, 0x04, 0x00, 0x0d, 0x00, 0xc2, 0x69, + 0x01, 0x8b, 0x00, 0x20, 0x83, 0x42, 0x00, 0xd0, 0x30, 0x00, 0x22, 0x26, + 0x09, 0xab, 0x05, 0x93, 0x0f, 0x4b, 0x6e, 0x44, 0x02, 0x90, 0x01, 0x93, + 0x04, 0x96, 0x02, 0x23, 0x03, 0x97, 0x00, 0x95, 0x20, 0x00, 0xff, 0xf7, + 0xcf, 0xfd, 0x0b, 0x4b, 0x98, 0x42, 0x0f, 0xd0, 0x00, 0x28, 0x0b, 0xdb, + 0x10, 0x9b, 0x31, 0x88, 0x09, 0x9a, 0x00, 0x2b, 0x04, 0xd0, 0x0b, 0x01, + 0x9b, 0x18, 0x10, 0x9d, 0x01, 0x33, 0x2b, 0x80, 0x21, 0x83, 0xe2, 0x61, + 0x0b, 0xb0, 0xf0, 0xbd, 0x02, 0x48, 0xfb, 0xe7, 0xc5, 0x47, 0x00, 0x00, + 0xa8, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0e, 0x27, + 0x12, 0x26, 0x89, 0xb0, 0x03, 0x93, 0x10, 0xab, 0x1b, 0x78, 0x15, 0x00, + 0x04, 0x93, 0x02, 0xab, 0xff, 0x18, 0x39, 0x80, 0xf6, 0x18, 0x07, 0xab, + 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x33, 0x00, 0x04, 0x00, 0xff, 0xf7, + 0x41, 0xff, 0x00, 0x28, 0x67, 0xdb, 0x33, 0x88, 0x07, 0x9a, 0x1b, 0x03, + 0x52, 0x00, 0x9b, 0x18, 0x02, 0x22, 0x01, 0x97, 0x00, 0x92, 0x04, 0x21, + 0x00, 0x22, 0x20, 0x00, 0xfd, 0xf7, 0x9b, 0xfb, 0x00, 0x28, 0x58, 0xdb, + 0x01, 0x22, 0xa3, 0x6b, 0x07, 0x21, 0x01, 0x33, 0xa3, 0x63, 0x2b, 0x79, + 0x20, 0x00, 0x93, 0x43, 0x2b, 0x71, 0x07, 0x9b, 0x9b, 0x18, 0x32, 0x88, + 0x1b, 0x02, 0x12, 0x03, 0x9b, 0x18, 0x05, 0x22, 0x01, 0x95, 0x00, 0x92, + 0x00, 0x22, 0xfd, 0xf7, 0x84, 0xfb, 0x00, 0x28, 0x41, 0xdb, 0x03, 0x9b, + 0x00, 0x2b, 0x13, 0xd0, 0x07, 0x9b, 0x32, 0x88, 0x01, 0x33, 0x12, 0x03, + 0x1b, 0x02, 0x9b, 0x18, 0x0f, 0x9a, 0x05, 0x33, 0x9b, 0x18, 0x03, 0x9a, + 0x07, 0x21, 0x01, 0x92, 0x0e, 0x9a, 0x20, 0x00, 0x00, 0x92, 0x00, 0x22, + 0xfd, 0xf7, 0x6d, 0xfb, 0x00, 0x28, 0x2a, 0xdb, 0x04, 0x9b, 0x00, 0x2b, + 0x1a, 0xd0, 0x02, 0x22, 0x2b, 0x79, 0x13, 0x42, 0x16, 0xd0, 0x93, 0x43, + 0x02, 0xa9, 0x10, 0x32, 0x2b, 0x71, 0x52, 0x18, 0x07, 0x9b, 0x12, 0x88, + 0x01, 0x33, 0x12, 0x03, 0x1b, 0x02, 0x9b, 0x18, 0x01, 0x22, 0x04, 0x35, + 0x00, 0x92, 0x04, 0x33, 0x01, 0x95, 0x00, 0x22, 0x07, 0x21, 0x20, 0x00, + 0xfd, 0xf7, 0x4f, 0xfb, 0x00, 0x28, 0x0c, 0xdb, 0x11, 0x9b, 0x00, 0x2b, + 0x09, 0xd0, 0x12, 0x23, 0x02, 0xaa, 0x9b, 0x18, 0x1b, 0x88, 0x07, 0x9a, + 0x1b, 0x01, 0xd3, 0x18, 0x11, 0x9a, 0x01, 0x33, 0x13, 0x80, 0x09, 0xb0, + 0xf0, 0xbd, 0x00, 0x00, 0x7f, 0xb5, 0x0e, 0x22, 0x00, 0x26, 0x0f, 0x23, + 0x0c, 0x00, 0x6a, 0x44, 0x16, 0x80, 0x01, 0x92, 0x02, 0x22, 0x0b, 0x40, + 0x11, 0x49, 0x00, 0x92, 0x5b, 0x18, 0x21, 0x09, 0x09, 0x03, 0x5b, 0x00, + 0x5b, 0x18, 0x32, 0x00, 0x31, 0x00, 0x05, 0x00, 0xfd, 0xf7, 0x27, 0xfb, + 0xb0, 0x42, 0x13, 0xdb, 0xeb, 0x6b, 0x0d, 0x22, 0x01, 0x33, 0xeb, 0x63, + 0xab, 0x6b, 0x6a, 0x44, 0x01, 0x3b, 0xab, 0x63, 0x7e, 0x23, 0x13, 0x70, + 0x01, 0x92, 0x01, 0x22, 0x24, 0x02, 0x00, 0x92, 0x23, 0x1d, 0x32, 0x00, + 0x03, 0x21, 0x28, 0x00, 0xfd, 0xf7, 0x11, 0xfb, 0x04, 0xb0, 0x70, 0xbd, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x89, 0xb0, 0x15, 0x00, 0x0e, 0xaa, + 0x03, 0x91, 0x02, 0xca, 0x12, 0x24, 0x12, 0x88, 0x02, 0x91, 0x04, 0x92, + 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x13, 0x80, 0x07, 0xab, 0x64, 0x18, + 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x23, 0x00, 0x06, 0x00, 0x10, 0x9f, + 0xff, 0xf7, 0x8c, 0xfe, 0x00, 0x28, 0x5f, 0xdb, 0x24, 0x88, 0x07, 0x9b, + 0x24, 0x01, 0x1c, 0x19, 0x01, 0x34, 0xa4, 0xb2, 0x00, 0x2f, 0x00, 0xd0, + 0x3c, 0x80, 0x27, 0x02, 0x00, 0x2d, 0x1e, 0xd1, 0x80, 0x22, 0x04, 0x9b, + 0x52, 0x00, 0x1b, 0x02, 0x00, 0x92, 0x03, 0x99, 0x3a, 0x00, 0x30, 0x00, + 0xff, 0xf7, 0xa8, 0xfc, 0x00, 0x23, 0x02, 0x9d, 0x02, 0x93, 0x24, 0xe0, + 0x03, 0x22, 0x2b, 0x79, 0x04, 0x35, 0x93, 0x43, 0x2b, 0x70, 0x02, 0x3a, + 0x00, 0x92, 0x3b, 0x1d, 0x01, 0x95, 0x03, 0x9a, 0x07, 0x21, 0x30, 0x00, + 0xfd, 0xf7, 0xcb, 0xfa, 0x00, 0x28, 0x31, 0xda, 0x34, 0xe0, 0x01, 0x22, + 0x2b, 0x79, 0x10, 0x00, 0x59, 0x08, 0x93, 0x43, 0x92, 0x18, 0x13, 0x43, + 0x2b, 0x71, 0x80, 0x23, 0x88, 0x43, 0x5b, 0x00, 0x02, 0x90, 0x00, 0x93, + 0x01, 0x95, 0x3b, 0x00, 0x00, 0x22, 0x07, 0x21, 0x30, 0x00, 0xfd, 0xf7, + 0xb4, 0xfa, 0x00, 0x28, 0x1e, 0xdb, 0x0f, 0x23, 0x0f, 0x4a, 0x23, 0x40, + 0x9b, 0x18, 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, + 0x24, 0x09, 0x5b, 0x00, 0x24, 0x03, 0x00, 0x92, 0x1b, 0x19, 0x00, 0x22, + 0x04, 0x21, 0x30, 0x00, 0xfd, 0xf7, 0x9f, 0xfa, 0x00, 0x28, 0x09, 0xdb, + 0xb3, 0x6b, 0x01, 0x33, 0xb3, 0x63, 0x02, 0x9b, 0x00, 0x2b, 0xbd, 0xd1, + 0x04, 0x99, 0x30, 0x00, 0xff, 0xf7, 0x56, 0xff, 0x09, 0xb0, 0xf0, 0xbd, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x87, 0xb0, 0x04, 0x93, 0x0c, 0xab, + 0x1b, 0x88, 0x07, 0x00, 0x00, 0x93, 0x0d, 0xab, 0x1b, 0x88, 0x15, 0x00, + 0x03, 0x93, 0x04, 0x9b, 0x05, 0x91, 0x5b, 0x04, 0x5b, 0x0c, 0x02, 0x93, + 0x83, 0x6a, 0x1e, 0x1d, 0x00, 0x23, 0x34, 0x00, 0x01, 0x93, 0xfb, 0x6a, + 0x01, 0x9a, 0x93, 0x42, 0x08, 0xd8, 0x01, 0x2d, 0x00, 0xd8, 0x6e, 0xe0, + 0x3c, 0x6d, 0x00, 0x2c, 0x00, 0xd0, 0x6c, 0xe0, 0x07, 0xb0, 0xf0, 0xbd, + 0x43, 0x4a, 0x63, 0x88, 0x13, 0x40, 0x02, 0x9a, 0x93, 0x42, 0x38, 0xd1, + 0x00, 0x9b, 0x00, 0x2b, 0x2b, 0xd1, 0x02, 0x2d, 0x38, 0xd0, 0xa3, 0x8c, + 0x00, 0x2b, 0x30, 0xd0, 0x6b, 0x46, 0x9b, 0x89, 0x23, 0x81, 0x0e, 0x9b, + 0x00, 0x2b, 0x20, 0xd0, 0x0e, 0x9a, 0x63, 0x60, 0xe1, 0x69, 0x00, 0x9b, + 0x01, 0x32, 0x09, 0xd0, 0x0e, 0x9b, 0x00, 0x29, 0x06, 0xd0, 0xca, 0x68, + 0x0b, 0x8a, 0x9b, 0x18, 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd2, 0x13, 0x00, + 0x22, 0x69, 0x9a, 0x42, 0x00, 0xd9, 0x23, 0x61, 0x62, 0x69, 0x9a, 0x42, + 0x00, 0xd9, 0x63, 0x61, 0x00, 0x29, 0x06, 0xd0, 0xca, 0x68, 0x01, 0x33, + 0x9a, 0x42, 0x02, 0xd9, 0x38, 0x00, 0xfd, 0xf7, 0x91, 0xfa, 0xa3, 0x89, + 0x00, 0x9a, 0x93, 0x42, 0x05, 0xd1, 0x00, 0x23, 0x02, 0x2d, 0x01, 0xd0, + 0x6b, 0x46, 0x9b, 0x89, 0x63, 0x81, 0x01, 0x9b, 0x30, 0x34, 0x01, 0x33, + 0x01, 0x93, 0xae, 0xe7, 0x00, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x05, 0xd0, + 0xe1, 0x69, 0x00, 0x29, 0x02, 0xd0, 0x38, 0x00, 0xfd, 0xf7, 0x78, 0xfa, + 0x00, 0x23, 0x23, 0x80, 0x63, 0x80, 0xe2, 0xe7, 0x00, 0x22, 0xb3, 0x5e, + 0x00, 0x2b, 0x0c, 0xd0, 0xb0, 0x6a, 0x00, 0x28, 0x09, 0xd0, 0x17, 0x4a, + 0x73, 0x88, 0x13, 0x40, 0x02, 0x9a, 0x93, 0x42, 0x03, 0xd1, 0x05, 0x9a, + 0x00, 0x99, 0xff, 0xf7, 0xd1, 0xfa, 0x01, 0x34, 0x30, 0x36, 0xfb, 0x6a, + 0xa3, 0x42, 0xe9, 0xd8, 0x90, 0xe7, 0x00, 0x24, 0xf9, 0xe7, 0x00, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x8e, 0xe7, 0x6b, 0x46, 0x10, 0x22, 0x9b, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0x88, 0xe7, 0x00, 0x99, 0x01, 0x2d, 0x08, 0xd0, + 0x00, 0x2d, 0x0b, 0xd0, 0xeb, 0x1e, 0x01, 0x2b, 0x08, 0xd9, 0x29, 0x00, + 0x02, 0x2d, 0x00, 0xd0, 0x7c, 0xe7, 0x03, 0x9b, 0x02, 0x9a, 0x38, 0x00, + 0xa0, 0x47, 0x77, 0xe7, 0x01, 0x21, 0xf8, 0xe7, 0xff, 0x7f, 0xff, 0xff, + 0xf0, 0xb5, 0x16, 0x27, 0x97, 0xb0, 0x1c, 0xab, 0x1b, 0x78, 0x04, 0x00, + 0x06, 0x93, 0x02, 0xab, 0xff, 0x18, 0x39, 0x80, 0xfb, 0x21, 0x05, 0x92, + 0xfe, 0xf7, 0x34, 0xfe, 0x05, 0x1e, 0x65, 0xdb, 0x3a, 0x88, 0x34, 0x4b, + 0x20, 0x00, 0x13, 0x43, 0x3b, 0x80, 0x09, 0xab, 0x00, 0x93, 0x1a, 0x23, + 0x02, 0xaa, 0x9b, 0x18, 0x21, 0x8a, 0x62, 0x69, 0xff, 0xf7, 0x5c, 0xfd, + 0x05, 0x1e, 0x55, 0xdb, 0x02, 0xab, 0x5b, 0x8b, 0x09, 0x9a, 0x1b, 0x03, + 0x52, 0x00, 0x9b, 0x18, 0x02, 0x22, 0x01, 0x97, 0x00, 0x92, 0x04, 0x21, + 0x00, 0x22, 0x20, 0x00, 0xfd, 0xf7, 0xb5, 0xf9, 0x05, 0x1e, 0x45, 0xdb, + 0xa3, 0x6b, 0x0a, 0xae, 0x01, 0x33, 0xa3, 0x63, 0x3b, 0x88, 0x2d, 0x20, + 0x33, 0x80, 0x00, 0x23, 0x73, 0x80, 0xf8, 0x33, 0x33, 0x71, 0x6b, 0x46, + 0x19, 0x7e, 0x02, 0xab, 0x31, 0x73, 0x01, 0x21, 0x49, 0x42, 0x0c, 0x91, + 0x20, 0x22, 0x05, 0x99, 0xc0, 0x18, 0x02, 0xf0, 0x9d, 0xfb, 0x09, 0x98, + 0x07, 0x21, 0x43, 0x1c, 0x02, 0xa8, 0x42, 0x8b, 0x1b, 0x02, 0x12, 0x03, + 0x9b, 0x18, 0x2e, 0x22, 0x01, 0x96, 0x00, 0x92, 0x20, 0x00, 0x00, 0x22, + 0xfd, 0xf7, 0x8d, 0xf9, 0x05, 0x1e, 0x1d, 0xdb, 0x01, 0x21, 0x49, 0x42, + 0x3b, 0x88, 0x02, 0x91, 0x02, 0xa9, 0x4a, 0x8b, 0x09, 0x99, 0x12, 0x01, + 0x8a, 0x18, 0x01, 0x32, 0x92, 0xb2, 0x01, 0x92, 0x00, 0x22, 0x31, 0x00, + 0x00, 0x92, 0x20, 0x00, 0x01, 0x32, 0xff, 0xf7, 0xe9, 0xfe, 0x1d, 0x9b, + 0x00, 0x2b, 0x07, 0xd0, 0x02, 0xab, 0x5b, 0x8b, 0x09, 0x9a, 0x1b, 0x01, + 0xd3, 0x18, 0x1d, 0x9a, 0x01, 0x33, 0x13, 0x80, 0x28, 0x00, 0x17, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, 0xf0, 0xb5, 0x89, 0xb0, + 0x05, 0x93, 0x80, 0x23, 0x0e, 0x9c, 0x1b, 0x02, 0x1a, 0x43, 0x06, 0x00, + 0x0f, 0x00, 0x04, 0x92, 0x00, 0x2c, 0x0e, 0xd1, 0x04, 0x21, 0x7a, 0x5e, + 0x41, 0x6a, 0x05, 0x9b, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, + 0x1b, 0x02, 0xea, 0x39, 0xfd, 0xf7, 0xeb, 0xf8, 0x05, 0x1e, 0x4e, 0xdb, + 0x74, 0x6a, 0x23, 0x79, 0xda, 0x07, 0x4d, 0xd4, 0x5a, 0xb2, 0x00, 0x2a, + 0x4c, 0xda, 0x9a, 0x07, 0x4c, 0xd4, 0x5b, 0x07, 0x4c, 0xd4, 0x63, 0x88, + 0x00, 0x2b, 0x4b, 0xd1, 0x0f, 0x9b, 0x00, 0x2b, 0x05, 0xd0, 0x20, 0x00, + 0x20, 0x22, 0x19, 0x00, 0x0d, 0x30, 0x02, 0xf0, 0x37, 0xfb, 0x11, 0x9b, + 0x00, 0x2b, 0x03, 0xd0, 0x23, 0x81, 0x11, 0x9b, 0x1b, 0x0c, 0x63, 0x81, + 0x39, 0x1e, 0x01, 0xd0, 0x04, 0x23, 0xf9, 0x5e, 0x16, 0x23, 0x02, 0xaa, + 0x9b, 0x18, 0x02, 0x93, 0x05, 0x9b, 0x22, 0x00, 0x01, 0x93, 0x00, 0x23, + 0x30, 0x00, 0x00, 0x93, 0x04, 0x9b, 0xff, 0xf7, 0x11, 0xfe, 0x05, 0x1e, + 0x1d, 0xd1, 0x02, 0xab, 0xd9, 0x8a, 0x12, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0x19, 0x80, 0x0e, 0x9a, 0x20, 0x89, 0x53, 0x42, 0x5a, 0x41, 0x63, 0x89, + 0x01, 0x91, 0x1b, 0x04, 0x03, 0x43, 0x02, 0x93, 0x63, 0x88, 0x92, 0x00, + 0x00, 0x93, 0x21, 0x00, 0x04, 0x9b, 0x30, 0x00, 0xff, 0xf7, 0x76, 0xfe, + 0x00, 0x2f, 0x04, 0xd0, 0x16, 0x23, 0x02, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0xbb, 0x81, 0x28, 0x00, 0x09, 0xb0, 0xf0, 0xbd, 0x04, 0x4d, 0xfa, 0xe7, + 0x04, 0x4d, 0xf8, 0xe7, 0x04, 0x4d, 0xf6, 0xe7, 0x04, 0x4d, 0xf4, 0xe7, + 0x04, 0x4d, 0xf2, 0xe7, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x93, 0xb0, 0x03, 0x93, 0x0d, 0x00, 0x0b, 0x02, 0x14, 0x00, + 0x04, 0x21, 0x52, 0x5e, 0x2e, 0x21, 0x06, 0xae, 0x00, 0x91, 0x01, 0x96, + 0x18, 0x39, 0x07, 0x00, 0xfd, 0xf7, 0x73, 0xf8, 0x00, 0x28, 0x33, 0xdb, + 0x0f, 0x23, 0x2b, 0x40, 0x2a, 0x09, 0x01, 0x3b, 0x12, 0x03, 0x5b, 0x00, + 0x9b, 0x18, 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, + 0x14, 0x21, 0x00, 0x92, 0x38, 0x00, 0x00, 0x22, 0xfd, 0xf7, 0x5f, 0xf8, + 0xa5, 0x81, 0x27, 0x60, 0xb3, 0x68, 0x6a, 0x46, 0xa3, 0x60, 0x00, 0x23, + 0x63, 0x61, 0x23, 0x82, 0x02, 0xab, 0xe5, 0x81, 0xdb, 0x89, 0x95, 0x89, + 0xe3, 0x80, 0xa5, 0x83, 0x32, 0x79, 0xd4, 0x07, 0x0f, 0xd4, 0x51, 0xb2, + 0x00, 0x29, 0x0f, 0xda, 0x02, 0x21, 0x0a, 0x42, 0x0e, 0xd1, 0x52, 0x07, + 0x0e, 0xd4, 0x1b, 0xb2, 0x00, 0x2b, 0x0b, 0xda, 0x73, 0x88, 0x00, 0x2b, + 0x02, 0xd0, 0x05, 0x48, 0x00, 0xe0, 0x05, 0x48, 0x13, 0xb0, 0xf0, 0xbd, + 0x04, 0x48, 0xfb, 0xe7, 0x04, 0x48, 0xf9, 0xe7, 0x04, 0x48, 0xf7, 0xe7, + 0xe3, 0xd8, 0xff, 0xff, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x95, 0xb0, + 0x0e, 0x93, 0x07, 0x68, 0x0d, 0x00, 0x0e, 0x99, 0x83, 0x68, 0x06, 0x00, + 0xfb, 0x31, 0x38, 0x00, 0x0f, 0x92, 0x06, 0x93, 0xfe, 0xf7, 0xe0, 0xfc, + 0x04, 0x1e, 0x00, 0xda, 0x0b, 0xe2, 0x06, 0x9b, 0x0a, 0x93, 0xab, 0x42, + 0x00, 0xd9, 0x0a, 0x95, 0x7b, 0x6a, 0xb2, 0x89, 0x06, 0x93, 0x10, 0xab, + 0x1a, 0x80, 0xfb, 0x21, 0x0a, 0x98, 0x02, 0xf0, 0x9f, 0xf9, 0xfb, 0x21, + 0x83, 0xb2, 0x0a, 0x98, 0x09, 0x93, 0x02, 0xf0, 0x1f, 0xfa, 0x4e, 0x4b, + 0x0c, 0x91, 0x0b, 0x93, 0x00, 0x23, 0x07, 0x93, 0x08, 0x93, 0x9c, 0x42, + 0x00, 0xd1, 0x2e, 0xe1, 0x0a, 0x9a, 0x08, 0x9b, 0x94, 0x46, 0x63, 0x44, + 0x09, 0x93, 0xb3, 0x60, 0x73, 0x61, 0x6b, 0x46, 0x9b, 0x8b, 0x10, 0xad, + 0x2a, 0x88, 0x33, 0x82, 0x07, 0x9b, 0xf2, 0x81, 0x00, 0x2b, 0x00, 0xd1, + 0x26, 0xe2, 0x31, 0x00, 0x38, 0x00, 0xff, 0xf7, 0x31, 0xf8, 0x00, 0x28, + 0x31, 0xdb, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfd, 0xf7, 0x3d, 0xf8, 0x00, 0x28, 0x22, 0xdb, 0x00, 0x22, 0x02, 0x92, + 0x2a, 0x88, 0x06, 0x98, 0x01, 0x92, 0xc2, 0x78, 0x81, 0x78, 0x12, 0x02, + 0x0a, 0x43, 0x00, 0x92, 0xf3, 0x88, 0x00, 0x22, 0x79, 0x6a, 0x38, 0x00, + 0xff, 0xf7, 0x9c, 0xfd, 0x1a, 0x21, 0x0a, 0xa8, 0x09, 0x18, 0x04, 0x91, + 0x00, 0x21, 0x09, 0x98, 0xb3, 0x89, 0xf2, 0x88, 0x03, 0x90, 0x02, 0x91, + 0x01, 0x91, 0x00, 0x91, 0x38, 0x00, 0x31, 0x00, 0xff, 0xf7, 0xb4, 0xfe, + 0x00, 0x28, 0x00, 0xdb, 0xa5, 0xe1, 0x04, 0x00, 0xa3, 0xe1, 0x1a, 0x20, + 0x03, 0x91, 0x0a, 0xac, 0x0b, 0x99, 0x00, 0x19, 0x04, 0x90, 0x02, 0x91, + 0x01, 0x91, 0x79, 0x6a, 0xb3, 0x89, 0xf2, 0x88, 0x00, 0x91, 0x31, 0x00, + 0x38, 0x00, 0xff, 0xf7, 0x9f, 0xfe, 0x11, 0xe1, 0x10, 0xad, 0x2a, 0x88, + 0x0b, 0x9b, 0x31, 0x00, 0x38, 0x00, 0xfe, 0xf7, 0xe3, 0xff, 0x04, 0x1e, + 0x00, 0xda, 0x88, 0xe1, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, + 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, + 0x38, 0x00, 0xfc, 0xf7, 0xee, 0xff, 0x04, 0x1e, 0x00, 0xda, 0x78, 0xe1, + 0x00, 0x24, 0x02, 0x94, 0x2a, 0x88, 0xf3, 0x88, 0x01, 0x92, 0x06, 0x9a, + 0x38, 0x00, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, 0x00, 0x92, + 0x79, 0x6a, 0x22, 0x00, 0xff, 0xf7, 0x4c, 0xfd, 0x1a, 0x21, 0x0a, 0xa8, + 0x09, 0x18, 0x04, 0x91, 0x0a, 0x98, 0x08, 0x99, 0xb3, 0x89, 0x09, 0x18, + 0xf2, 0x88, 0x03, 0x91, 0x02, 0x94, 0x01, 0x94, 0x00, 0x94, 0xc2, 0xe7, + 0xff, 0xff, 0x00, 0x00, 0xb3, 0x68, 0x58, 0x1e, 0xc6, 0x4b, 0x98, 0x42, + 0x0f, 0xd9, 0x08, 0x9b, 0x00, 0x2b, 0x0c, 0xd1, 0xfb, 0x21, 0x02, 0xf0, + 0xef, 0xf8, 0x7c, 0x21, 0x69, 0x38, 0x02, 0xf0, 0xeb, 0xf8, 0x07, 0x9b, + 0x01, 0x30, 0x80, 0xb2, 0x83, 0x42, 0x00, 0xd8, 0xfb, 0xe0, 0x80, 0x23, + 0xf1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x6b, 0x46, 0x9b, 0x8b, 0x12, 0xad, + 0x6b, 0x80, 0xf9, 0x23, 0x2b, 0x71, 0x10, 0xab, 0x29, 0x80, 0x03, 0x93, + 0x01, 0x23, 0x02, 0x93, 0x00, 0x23, 0x2a, 0x00, 0x01, 0x93, 0x00, 0x93, + 0x38, 0x00, 0xff, 0xf7, 0xe1, 0xfb, 0x04, 0x1e, 0x00, 0xda, 0x2a, 0xe1, + 0x80, 0x22, 0xff, 0x21, 0x52, 0x00, 0x78, 0x6a, 0x02, 0xf0, 0x7f, 0xf9, + 0x05, 0x22, 0x29, 0x00, 0x78, 0x6a, 0x02, 0xf0, 0x71, 0xf9, 0x00, 0x22, + 0x02, 0x92, 0x0a, 0xaa, 0x12, 0x8b, 0xf3, 0x88, 0x01, 0x92, 0x07, 0x9a, + 0x38, 0x00, 0x00, 0x92, 0x79, 0x6a, 0x01, 0x22, 0xff, 0xf7, 0xf6, 0xfc, + 0x10, 0xab, 0x1b, 0x88, 0x0a, 0x9a, 0xf3, 0x81, 0x6b, 0x46, 0x9b, 0x8b, + 0x33, 0x82, 0x08, 0x9b, 0x9b, 0x18, 0x73, 0x61, 0xb3, 0x60, 0x07, 0x9b, + 0x0b, 0x93, 0x08, 0x9a, 0x0e, 0x9b, 0x0c, 0x99, 0x9b, 0x1a, 0xfb, 0x22, + 0x52, 0x1a, 0x0d, 0x92, 0x9a, 0x42, 0x00, 0xd9, 0x0d, 0x93, 0x0c, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0xfa, 0xe0, 0x6b, 0x46, 0x9b, 0x8c, 0x12, 0xaa, + 0xf1, 0x88, 0x53, 0x80, 0xfd, 0x23, 0x08, 0x98, 0x13, 0x71, 0x0f, 0x9b, + 0x49, 0x04, 0x49, 0x0c, 0x1b, 0x18, 0x11, 0xa8, 0x11, 0x80, 0x03, 0x90, + 0x01, 0x20, 0x02, 0x90, 0x0c, 0x98, 0x01, 0x90, 0x0d, 0x98, 0x00, 0x90, + 0x38, 0x00, 0xff, 0xf7, 0x93, 0xfb, 0x04, 0x1e, 0x00, 0xd0, 0xed, 0xe6, + 0x11, 0xab, 0x1d, 0x88, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x11, 0xe1, + 0x09, 0x9b, 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9d, 0x52, 0x0a, 0x9a, + 0x08, 0x9b, 0x9b, 0x18, 0x06, 0x9a, 0x13, 0x81, 0x1b, 0x0c, 0x53, 0x81, + 0x0d, 0x9a, 0x09, 0x98, 0x94, 0x46, 0x01, 0x30, 0x83, 0xb2, 0x09, 0x93, + 0x08, 0x9b, 0x63, 0x44, 0x08, 0x93, 0x00, 0x23, 0x0c, 0x93, 0x08, 0x9b, + 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd3, 0xcb, 0xe6, 0x00, 0x23, 0x07, 0x93, + 0x09, 0x9b, 0x68, 0x2b, 0x07, 0xd9, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x02, 0xf0, 0x52, 0xf8, 0x01, 0x30, 0x83, 0xb2, 0x07, 0x93, 0x0b, 0x9b, + 0x07, 0x9a, 0x93, 0x42, 0xa3, 0xd0, 0x08, 0x9b, 0x00, 0x2b, 0x2d, 0xd0, + 0x0b, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x0f, 0xe7, 0x08, 0x9b, 0x0a, 0x9a, + 0x99, 0x18, 0x06, 0x9b, 0x06, 0x9a, 0x19, 0x81, 0x0b, 0x0c, 0x53, 0x81, + 0x0a, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0xf2, 0xe6, 0x10, 0xad, 0x2a, 0x88, + 0x31, 0x00, 0x38, 0x00, 0xfe, 0xf7, 0xe8, 0xfe, 0x04, 0x1e, 0x00, 0xda, + 0x8d, 0xe0, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfc, 0xf7, 0xf3, 0xfe, 0x04, 0x1e, 0x00, 0xda, 0x7d, 0xe0, 0x08, 0x9b, + 0x0a, 0x9a, 0x9b, 0x18, 0xb3, 0x60, 0x73, 0x61, 0x07, 0x9b, 0x00, 0x2b, + 0x00, 0xd0, 0x1b, 0xe7, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x10, 0xab, + 0x1b, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, + 0xea, 0x39, 0x38, 0x00, 0xfc, 0xf7, 0x75, 0xfe, 0x04, 0x1e, 0x64, 0xdb, + 0x01, 0x22, 0x06, 0x9b, 0x1b, 0x79, 0x13, 0x42, 0x00, 0xd0, 0xe9, 0xe0, + 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xe7, 0xe0, 0x9a, 0x07, 0x00, 0xd5, + 0xe6, 0xe0, 0x5b, 0x07, 0x00, 0xd5, 0xe5, 0xe0, 0x06, 0x22, 0xb3, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0xe0, 0xe0, 0x06, 0x9b, 0x5b, 0x88, 0x0b, 0x93, + 0x00, 0x2b, 0x00, 0xd1, 0x43, 0xe7, 0x41, 0x4c, 0x47, 0xe0, 0x33, 0x8a, + 0x07, 0x9a, 0x93, 0x42, 0x34, 0xd1, 0x1e, 0x23, 0xf2, 0x89, 0x0a, 0xa9, + 0x5b, 0x18, 0x1a, 0x80, 0x1e, 0x25, 0x0a, 0xab, 0x04, 0x21, 0x72, 0x5e, + 0x79, 0x6a, 0xed, 0x18, 0x2b, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, + 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x38, 0x00, 0xfc, 0xf7, 0x3d, 0xfe, + 0x04, 0x1e, 0x2c, 0xdb, 0x01, 0x22, 0x06, 0x9b, 0x1b, 0x79, 0x13, 0x42, + 0x00, 0xd0, 0xb1, 0xe0, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xaf, 0xe0, + 0x9a, 0x07, 0x00, 0xd5, 0xae, 0xe0, 0x5b, 0x07, 0x00, 0xd5, 0xad, 0xe0, + 0x06, 0x22, 0xb3, 0x5e, 0x00, 0x2b, 0x00, 0xdb, 0xa8, 0xe0, 0x06, 0x9b, + 0x07, 0x9a, 0x5b, 0x88, 0x93, 0x42, 0xc8, 0xd1, 0x2a, 0x88, 0x10, 0xab, + 0x1a, 0x80, 0xfb, 0xe6, 0x80, 0x23, 0xf1, 0x88, 0x1b, 0x02, 0x19, 0x43, + 0x1e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, 0x00, 0x93, 0x07, 0x9a, 0x08, 0x9b, + 0x38, 0x00, 0xff, 0xf7, 0x45, 0xfa, 0x04, 0x1e, 0xc0, 0xda, 0x20, 0x00, + 0x15, 0xb0, 0xf0, 0xbd, 0x07, 0x9b, 0x00, 0x2b, 0x21, 0xd1, 0x09, 0x9b, + 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9a, 0x5a, 0x11, 0xab, 0x1a, 0x80, + 0x11, 0xad, 0x2a, 0x88, 0x31, 0x1d, 0x09, 0x9b, 0x38, 0x00, 0xfe, 0xf7, + 0x97, 0xff, 0x04, 0x1e, 0xe9, 0xdb, 0x2b, 0x88, 0x0c, 0x9a, 0x1b, 0x02, + 0x05, 0x33, 0x08, 0x98, 0x9b, 0x18, 0x04, 0x21, 0x72, 0x5e, 0x0f, 0x99, + 0x09, 0x18, 0x01, 0x91, 0x0d, 0x99, 0x38, 0x00, 0x00, 0x91, 0x07, 0x21, + 0xfc, 0xf7, 0x4b, 0xfe, 0xf7, 0xe6, 0x09, 0x9b, 0x19, 0x1d, 0x68, 0x2b, + 0x05, 0xd9, 0x09, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0xf6, 0xff, + 0x04, 0x31, 0x06, 0x9b, 0x49, 0x00, 0x5a, 0x5a, 0xd4, 0xe7, 0xc0, 0x46, + 0xf2, 0x66, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, 0x09, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x09, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0xe3, 0xff, 0x04, 0x31, 0x06, 0x9b, 0x49, 0x00, 0x5d, 0x52, 0xeb, 0xe6, + 0x0a, 0x9b, 0x00, 0x2b, 0x31, 0xd1, 0x69, 0x46, 0x06, 0x9b, 0x09, 0x8c, + 0x38, 0x00, 0x19, 0x81, 0x08, 0x9b, 0x06, 0x99, 0x1b, 0x0c, 0x4b, 0x81, + 0x0a, 0x9b, 0x31, 0x00, 0xfe, 0xf7, 0xfe, 0xfd, 0x00, 0x28, 0x00, 0xda, + 0xfd, 0xe5, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfc, 0xf7, 0x09, 0xfe, 0x00, 0x28, 0x00, 0xda, 0xed, 0xe5, 0x06, 0x9a, + 0xf3, 0x88, 0x11, 0x89, 0x52, 0x89, 0x38, 0x00, 0x12, 0x04, 0x0a, 0x43, + 0x02, 0x92, 0x2a, 0x88, 0x01, 0x92, 0x06, 0x9a, 0x52, 0x88, 0x00, 0x92, + 0x79, 0x6a, 0x04, 0x22, 0xff, 0xf7, 0x66, 0xfb, 0x81, 0xe7, 0x1a, 0x21, + 0x0a, 0xa8, 0x09, 0x18, 0x04, 0x91, 0x09, 0x99, 0xb3, 0x89, 0x03, 0x91, + 0x07, 0x99, 0xf2, 0x88, 0x02, 0x91, 0x01, 0x91, 0x79, 0x6a, 0xc6, 0xe5, + 0x03, 0x4c, 0x72, 0xe7, 0x03, 0x4c, 0x70, 0xe7, 0x03, 0x4c, 0x6e, 0xe7, + 0x03, 0x4c, 0x6c, 0xe7, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x95, 0xb0, + 0x0d, 0x91, 0x19, 0x00, 0x05, 0x68, 0x07, 0x00, 0xfb, 0x31, 0x28, 0x00, + 0x0f, 0x92, 0x0e, 0x93, 0xfe, 0xf7, 0x2a, 0xfa, 0x04, 0x1e, 0x00, 0xda, + 0x6e, 0xe1, 0x6b, 0x6a, 0xfb, 0x21, 0x07, 0x93, 0xbb, 0x89, 0x0d, 0x98, + 0x0b, 0x93, 0x01, 0xf0, 0xef, 0xfe, 0xfb, 0x21, 0x83, 0xb2, 0x0d, 0x98, + 0x08, 0x93, 0x01, 0xf0, 0x6f, 0xff, 0x00, 0x23, 0x0a, 0x91, 0xc1, 0x4e, + 0x06, 0x93, 0x09, 0x93, 0x9c, 0x42, 0x00, 0xd1, 0x2c, 0xe1, 0x0d, 0x9a, + 0x09, 0x9b, 0x94, 0x46, 0x63, 0x44, 0x7b, 0x61, 0x6b, 0x46, 0x9b, 0x8d, + 0xfb, 0x81, 0x6b, 0x46, 0x1b, 0x8b, 0x3b, 0x82, 0x06, 0x9b, 0x00, 0x2b, + 0x00, 0xd1, 0xf4, 0xe1, 0x0b, 0x9a, 0x39, 0x00, 0x28, 0x00, 0xfe, 0xf7, + 0x83, 0xfd, 0x00, 0x28, 0x00, 0xda, 0xff, 0xe1, 0x04, 0x22, 0xb9, 0x5e, + 0x1e, 0x22, 0x00, 0x26, 0x0a, 0xa8, 0x12, 0x18, 0xfb, 0x88, 0x02, 0x92, + 0x0b, 0x9a, 0x00, 0x96, 0x01, 0x92, 0x28, 0x00, 0x07, 0x9a, 0xff, 0xf7, + 0x7f, 0xfa, 0x0a, 0xab, 0xda, 0x8b, 0x6b, 0x46, 0x1b, 0x8b, 0xfa, 0x81, + 0x3b, 0x82, 0xb0, 0x42, 0x00, 0xda, 0xe7, 0xe1, 0xfb, 0x88, 0x01, 0x92, + 0x07, 0x9a, 0x02, 0x96, 0x91, 0x78, 0xd2, 0x78, 0x28, 0x00, 0x12, 0x02, + 0x0a, 0x43, 0x00, 0x92, 0x07, 0x99, 0x32, 0x00, 0xff, 0xf7, 0xe6, 0xfa, + 0x1a, 0xe1, 0x00, 0x23, 0x06, 0x93, 0x33, 0x00, 0x0b, 0x9a, 0x39, 0x00, + 0x28, 0x00, 0xfe, 0xf7, 0x51, 0xfd, 0x04, 0x1e, 0x00, 0xda, 0x0f, 0xe1, + 0x04, 0x22, 0xb9, 0x5e, 0x1e, 0x22, 0x00, 0x26, 0x0a, 0xa8, 0x12, 0x18, + 0xfb, 0x88, 0x02, 0x92, 0x0b, 0x9a, 0x00, 0x96, 0x01, 0x92, 0x28, 0x00, + 0x07, 0x9a, 0xff, 0xf7, 0x4d, 0xfa, 0x04, 0x00, 0xb0, 0x42, 0x00, 0xda, + 0xfc, 0xe0, 0xfb, 0x88, 0x0a, 0xaa, 0x02, 0x96, 0xd2, 0x8b, 0x28, 0x00, + 0x01, 0x92, 0x07, 0x9a, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, + 0x00, 0x92, 0x07, 0x99, 0x32, 0x00, 0xff, 0xf7, 0xb7, 0xfa, 0x06, 0x9b, + 0xb3, 0x42, 0x29, 0xd1, 0x04, 0x21, 0x7a, 0x5e, 0x69, 0x6a, 0x0b, 0x9b, + 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, + 0x28, 0x00, 0xfc, 0xf7, 0xd2, 0xfc, 0x04, 0x1e, 0x00, 0xda, 0xd9, 0xe0, + 0x07, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x00, 0xd5, 0x94, 0xe1, 0x5a, 0xb2, + 0x00, 0x2a, 0x00, 0xdb, 0x92, 0xe1, 0x9a, 0x07, 0x00, 0xd5, 0x91, 0xe1, + 0x5b, 0x07, 0x00, 0xd5, 0x90, 0xe1, 0x06, 0x22, 0xbb, 0x5e, 0x00, 0x2b, + 0x00, 0xdb, 0x8b, 0xe1, 0x07, 0x9b, 0x5b, 0x88, 0x00, 0x2b, 0x39, 0xd0, + 0x73, 0x4c, 0xbf, 0xe0, 0x3b, 0x8a, 0x06, 0x9a, 0x93, 0x42, 0x00, 0xd0, + 0xbd, 0xe0, 0x1e, 0x23, 0xfa, 0x89, 0x0a, 0xa9, 0x5b, 0x18, 0x1a, 0x80, + 0x1e, 0x26, 0x04, 0x21, 0x7a, 0x5e, 0x0a, 0xab, 0x69, 0x6a, 0xf6, 0x18, + 0x33, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, + 0xea, 0x39, 0x28, 0x00, 0xfc, 0xf7, 0x9b, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0xa2, 0xe0, 0x07, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x00, 0xd5, 0x5d, 0xe1, + 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0x5b, 0xe1, 0x9a, 0x07, 0x00, 0xd5, + 0x5a, 0xe1, 0x5b, 0x07, 0x00, 0xd5, 0x59, 0xe1, 0x06, 0x22, 0xbb, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0x54, 0xe1, 0x07, 0x9b, 0x06, 0x9a, 0x5b, 0x88, + 0x93, 0x42, 0xc7, 0xd1, 0x33, 0x88, 0x0b, 0x93, 0x6b, 0x46, 0x9b, 0x8d, + 0x0d, 0x9a, 0xfb, 0x81, 0x6b, 0x46, 0x1b, 0x8b, 0x3b, 0x82, 0x09, 0x9b, + 0x9b, 0x18, 0x7b, 0x61, 0x09, 0x9a, 0x0e, 0x9b, 0x0a, 0x99, 0x9b, 0x1a, + 0xfb, 0x22, 0x56, 0x1a, 0x9e, 0x42, 0x00, 0xd9, 0x1e, 0x00, 0x06, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x84, 0xe0, 0x08, 0x9b, 0x07, 0x9a, 0x17, 0x33, + 0x5b, 0x00, 0x9b, 0x5a, 0x0c, 0x93, 0x00, 0x23, 0x06, 0x93, 0x6b, 0x46, + 0x1b, 0x8c, 0x12, 0xaa, 0xf9, 0x88, 0x53, 0x80, 0xff, 0x23, 0x49, 0x04, + 0x13, 0x71, 0x0a, 0x9b, 0x49, 0x0c, 0x11, 0x80, 0x00, 0x2b, 0x00, 0xd0, + 0x82, 0xe0, 0xfb, 0x2e, 0x00, 0xd0, 0x7f, 0xe0, 0x09, 0x98, 0x0f, 0x9b, + 0x00, 0x96, 0x1b, 0x18, 0x11, 0xa8, 0x03, 0x90, 0x01, 0x20, 0x02, 0x90, + 0x0a, 0x98, 0x01, 0x90, 0x28, 0x00, 0xff, 0xf7, 0xe5, 0xf8, 0x0c, 0x99, + 0x28, 0x00, 0xff, 0xf7, 0x63, 0xf9, 0x04, 0x1e, 0x00, 0xd0, 0xea, 0xe6, + 0x11, 0xab, 0x1b, 0x88, 0x0a, 0x93, 0x06, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0xd7, 0xe0, 0x69, 0x46, 0x08, 0x9b, 0x07, 0x9a, 0x17, 0x33, 0x09, 0x8d, + 0x5b, 0x00, 0x99, 0x52, 0x08, 0x98, 0x01, 0x30, 0x83, 0xb2, 0x08, 0x93, + 0x09, 0x9b, 0x9b, 0x19, 0x09, 0x93, 0x00, 0x23, 0x06, 0x9e, 0x0a, 0x93, + 0x09, 0x9b, 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd3, 0xcd, 0xe6, 0x08, 0x9b, + 0x68, 0x2b, 0x00, 0xd8, 0xf5, 0xe0, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x01, 0xf0, 0xa6, 0xfd, 0x01, 0x30, 0x83, 0xb2, 0x06, 0x93, 0x9e, 0x42, + 0x9a, 0xd0, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd1, 0x54, 0xe7, 0x00, 0x2e, + 0x00, 0xd0, 0xf8, 0xe6, 0x1a, 0x21, 0x0a, 0xa8, 0x09, 0x18, 0xbb, 0x89, + 0xfa, 0x88, 0x03, 0x94, 0x02, 0x94, 0x01, 0x94, 0x04, 0x91, 0x69, 0x6a, + 0x28, 0x00, 0x00, 0x91, 0x39, 0x00, 0xff, 0xf7, 0xf5, 0xfa, 0x04, 0x1e, + 0x00, 0xdb, 0x3f, 0xe7, 0x20, 0x00, 0x15, 0xb0, 0xf0, 0xbd, 0x80, 0x23, + 0xf9, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x06, 0x9a, 0x00, 0x23, 0x28, 0x00, 0xff, 0xf7, 0x1a, 0xf8, + 0x04, 0x1e, 0x00, 0xdb, 0x36, 0xe7, 0xeb, 0xe7, 0x08, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x08, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0xf1, 0xfd, 0x04, 0x31, 0x07, 0x9b, 0x49, 0x00, 0x5b, 0x5a, 0x0c, 0x93, + 0x73, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, + 0x39, 0x1d, 0x08, 0x9b, 0x0c, 0x9a, 0x28, 0x00, 0xfe, 0xf7, 0x64, 0xfd, + 0x04, 0x1e, 0xcf, 0xdb, 0x11, 0xab, 0xf9, 0x88, 0x03, 0x93, 0x00, 0x23, + 0x49, 0x04, 0x49, 0x0c, 0x02, 0x93, 0x01, 0x93, 0x00, 0x93, 0x12, 0xaa, + 0x28, 0x00, 0xff, 0xf7, 0x5d, 0xf8, 0x04, 0x1e, 0x00, 0xd0, 0x66, 0xe6, + 0x0a, 0x9b, 0x00, 0x2b, 0x2e, 0xd1, 0x0a, 0x9b, 0x98, 0x19, 0xfa, 0x28, + 0x3b, 0xd9, 0x0a, 0xab, 0x9b, 0x8b, 0x0a, 0x9a, 0x1b, 0x02, 0x05, 0x33, + 0x09, 0x98, 0x9b, 0x18, 0x04, 0x21, 0x7a, 0x5e, 0x0f, 0x99, 0x00, 0x96, + 0x09, 0x18, 0x01, 0x91, 0x28, 0x00, 0x07, 0x21, 0xfc, 0xf7, 0x01, 0xfc, + 0x04, 0x1e, 0x00, 0xd0, 0x4b, 0xe6, 0x02, 0x21, 0x12, 0xaa, 0x13, 0x79, + 0x28, 0x00, 0x8b, 0x43, 0x13, 0x71, 0x04, 0x21, 0x7a, 0x5e, 0x0a, 0xab, + 0x13, 0xa9, 0x9b, 0x8b, 0x01, 0x91, 0x01, 0x21, 0x1b, 0x02, 0x00, 0x91, + 0x04, 0x33, 0x06, 0x31, 0xfc, 0xf7, 0xeb, 0xfb, 0x04, 0x1e, 0x00, 0xd1, + 0x43, 0xe7, 0x34, 0xe6, 0x0a, 0xaa, 0x92, 0x8b, 0x0c, 0x9b, 0x04, 0x20, + 0x39, 0x5e, 0x0a, 0x98, 0x1b, 0x02, 0x12, 0x02, 0x00, 0x90, 0x05, 0x33, + 0x05, 0x32, 0x28, 0x00, 0xfe, 0xf7, 0xa4, 0xfd, 0x04, 0x1e, 0xc0, 0xd0, + 0x23, 0xe6, 0x0a, 0x9b, 0x0c, 0x9a, 0x05, 0x33, 0x12, 0x02, 0x9b, 0x19, + 0x9b, 0x18, 0x11, 0xaa, 0x12, 0x88, 0x0a, 0x99, 0x12, 0x02, 0x05, 0x32, + 0x52, 0x18, 0x04, 0x24, 0x39, 0x5f, 0xfb, 0x24, 0x20, 0x1a, 0x00, 0x90, + 0x92, 0x19, 0x28, 0x00, 0xfe, 0xf7, 0x8c, 0xfd, 0x04, 0x1e, 0xac, 0xd0, + 0x0b, 0xe6, 0x08, 0x9b, 0x19, 0x1d, 0x68, 0x2b, 0x05, 0xd9, 0x08, 0x98, + 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0x6a, 0xfd, 0x04, 0x31, 0x6a, 0x46, + 0x07, 0x9b, 0x12, 0x8d, 0x49, 0x00, 0x5a, 0x52, 0x1e, 0xe7, 0x1a, 0x21, + 0x0a, 0xa8, 0x09, 0x18, 0xbb, 0x89, 0xfa, 0x88, 0x04, 0x91, 0x06, 0x99, + 0x28, 0x00, 0x03, 0x91, 0x02, 0x91, 0x01, 0x91, 0x69, 0x6a, 0x00, 0x91, + 0x39, 0x00, 0xff, 0xf7, 0x37, 0xfa, 0x00, 0x28, 0x00, 0xdb, 0x41, 0xe7, + 0x04, 0x00, 0x3f, 0xe7, 0x0d, 0x4c, 0x3d, 0xe7, 0x0d, 0x4c, 0x3b, 0xe7, + 0x0d, 0x4c, 0x39, 0xe7, 0x0d, 0x4c, 0x37, 0xe7, 0x09, 0x9a, 0x0e, 0x9b, + 0x0a, 0x99, 0x9b, 0x1a, 0xfb, 0x22, 0x56, 0x1a, 0x9e, 0x42, 0x00, 0xd8, + 0xbd, 0xe6, 0x1e, 0x00, 0xbb, 0xe6, 0x00, 0x2e, 0xf2, 0xd0, 0x09, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x0b, 0xe6, 0x06, 0x93, 0x3a, 0xe6, 0xc0, 0x46, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0x70, 0xb5, 0x88, 0xb0, 0x07, 0xab, 0x1a, 0x26, + 0x04, 0x00, 0x05, 0x93, 0x08, 0x00, 0x00, 0x23, 0x15, 0x00, 0x0f, 0x4a, + 0x6e, 0x44, 0x03, 0x93, 0x02, 0x90, 0x01, 0x92, 0x00, 0x93, 0x21, 0x8b, + 0x04, 0x96, 0xe2, 0x69, 0x20, 0x00, 0xfe, 0xf7, 0x55, 0xfd, 0x0a, 0x4b, + 0x98, 0x42, 0x0d, 0xd0, 0x00, 0x28, 0x09, 0xdb, 0x31, 0x88, 0x07, 0x9a, + 0x00, 0x2d, 0x03, 0xd0, 0x0b, 0x01, 0x9b, 0x18, 0x01, 0x33, 0x2b, 0x80, + 0x21, 0x83, 0xe2, 0x61, 0x08, 0xb0, 0x70, 0xbd, 0x02, 0x48, 0xfb, 0xe7, + 0xcd, 0x48, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x83, 0x68, 0x93, 0xb0, 0x01, 0x3b, 0x04, 0x00, 0x0b, 0x91, + 0x07, 0x92, 0x06, 0x68, 0x03, 0x33, 0x00, 0xd8, 0xd6, 0xe0, 0x00, 0x25, + 0xaa, 0x42, 0x00, 0xd1, 0xde, 0xe0, 0x1a, 0x23, 0xa5, 0x89, 0x08, 0xaa, + 0xa7, 0x68, 0x9b, 0x18, 0x1d, 0x80, 0x00, 0x2f, 0x00, 0xd0, 0xd8, 0xe0, + 0x06, 0x97, 0x73, 0x6a, 0x08, 0x93, 0x07, 0x9b, 0x00, 0x2b, 0x13, 0xd0, + 0x0b, 0x9b, 0x00, 0x2b, 0x10, 0xd1, 0x10, 0xa9, 0xb8, 0x33, 0x0b, 0x70, + 0x01, 0x91, 0x01, 0x21, 0x2d, 0x02, 0x2b, 0x1d, 0x04, 0x20, 0x22, 0x5e, + 0x00, 0x91, 0x30, 0x00, 0x05, 0x31, 0xfc, 0xf7, 0x18, 0xfb, 0x05, 0x1e, + 0x00, 0xda, 0xbb, 0xe0, 0x9f, 0x4b, 0x0c, 0x93, 0x00, 0x23, 0x09, 0x93, + 0x0b, 0x9b, 0x9f, 0x42, 0x00, 0xd8, 0xfd, 0xe0, 0x06, 0x9b, 0x68, 0x2b, + 0x00, 0xd8, 0x14, 0xe2, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0x33, 0xfc, 0x01, 0x30, 0x83, 0xb2, 0x0a, 0x93, 0x0a, 0x9a, 0x0c, 0x9b, + 0x93, 0x42, 0x00, 0xd1, 0x0e, 0xe2, 0x0c, 0x9b, 0x1a, 0x00, 0x92, 0x4b, + 0x9a, 0x42, 0x29, 0xd0, 0x08, 0xab, 0x5a, 0x8b, 0x21, 0x00, 0x0c, 0x9b, + 0x30, 0x00, 0xfe, 0xf7, 0xd5, 0xfa, 0x05, 0x1e, 0x00, 0xda, 0x93, 0xe0, + 0x08, 0xab, 0x59, 0x8b, 0x30, 0x00, 0xfe, 0xf7, 0xab, 0xff, 0x05, 0x1e, + 0x00, 0xda, 0x8b, 0xe0, 0x00, 0x21, 0x08, 0xaa, 0x02, 0x91, 0x52, 0x8b, + 0xe3, 0x88, 0x01, 0x92, 0x08, 0x9a, 0x90, 0x78, 0xd2, 0x78, 0x12, 0x02, + 0x02, 0x43, 0x00, 0x92, 0x30, 0x00, 0x02, 0x22, 0xff, 0xf7, 0x46, 0xf8, + 0x0c, 0x9b, 0x00, 0x2b, 0x04, 0xd0, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd1, + 0x82, 0xe0, 0xa7, 0x60, 0x0a, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x8e, 0xe0, + 0xa2, 0x89, 0x1a, 0x33, 0x08, 0xa9, 0x5b, 0x18, 0x1a, 0x80, 0x04, 0x21, + 0x62, 0x5e, 0x71, 0x6a, 0x08, 0xab, 0x5b, 0x8b, 0x01, 0x91, 0x80, 0x21, + 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x30, 0x00, 0xfc, 0xf7, + 0x52, 0xfa, 0x05, 0x1e, 0x5a, 0xdb, 0x08, 0x9b, 0x1b, 0x79, 0xda, 0x07, + 0x00, 0xd5, 0xb0, 0xe1, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xae, 0xe1, + 0x9a, 0x07, 0x00, 0xd5, 0xad, 0xe1, 0x5b, 0x07, 0x00, 0xd5, 0xac, 0xe1, + 0x06, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x00, 0xdb, 0xa7, 0xe1, 0x08, 0x9b, + 0x0a, 0x9a, 0x5b, 0x88, 0x09, 0x93, 0x93, 0x42, 0x00, 0xd0, 0xa2, 0xe1, + 0x08, 0xab, 0x5b, 0x8b, 0x67, 0x61, 0xe3, 0x81, 0x6b, 0x46, 0x1b, 0x8d, + 0x23, 0x82, 0x00, 0x2a, 0x00, 0xd0, 0x65, 0xe0, 0x06, 0x9b, 0x08, 0x9a, + 0x17, 0x33, 0x5b, 0x00, 0xd3, 0x18, 0x1a, 0x88, 0x0d, 0x92, 0x01, 0x22, + 0x52, 0x42, 0x1a, 0x80, 0x00, 0x23, 0x0c, 0x93, 0x09, 0x93, 0x0b, 0x9b, + 0x21, 0x1d, 0x00, 0x2b, 0x07, 0xd0, 0x07, 0x9b, 0x00, 0x2b, 0x04, 0xd1, + 0x0b, 0x9b, 0xfb, 0x1a, 0xfa, 0x2b, 0x00, 0xd8, 0xa6, 0xe0, 0x06, 0x9b, + 0x0d, 0x9a, 0x30, 0x00, 0xfe, 0xf7, 0xaa, 0xfb, 0x4e, 0x4b, 0x98, 0x42, + 0x59, 0xd1, 0xfb, 0x21, 0x38, 0x00, 0x01, 0xf0, 0x1f, 0xfc, 0x00, 0x29, + 0x00, 0xd1, 0x89, 0xe0, 0x7f, 0x1a, 0x88, 0xe0, 0x07, 0x9b, 0x00, 0x2b, + 0x00, 0xd0, 0x28, 0xe7, 0xfb, 0x21, 0x30, 0x00, 0x49, 0x00, 0xfd, 0xf7, + 0xbb, 0xfe, 0x05, 0x1e, 0x00, 0xdb, 0x20, 0xe7, 0x28, 0x00, 0x13, 0xb0, + 0xf0, 0xbd, 0x78, 0x1e, 0xfb, 0x21, 0x01, 0xf0, 0x81, 0xfb, 0x83, 0xb2, + 0x06, 0x93, 0x7b, 0x1c, 0x00, 0xd0, 0x1e, 0xe7, 0x00, 0x27, 0x1c, 0xe7, + 0x0f, 0xa9, 0x04, 0x91, 0x07, 0x99, 0xa3, 0x89, 0x02, 0x91, 0x01, 0x91, + 0x00, 0x91, 0xe2, 0x88, 0x03, 0x97, 0x21, 0x00, 0x30, 0x00, 0xff, 0xf7, + 0xd7, 0xf8, 0x05, 0x1e, 0x00, 0xdb, 0x6c, 0xe7, 0xe0, 0xe7, 0x80, 0x23, + 0xe1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1a, 0x23, 0x08, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x0a, 0x9a, 0x00, 0x23, 0x30, 0x00, 0xfe, 0xf7, 0xfe, 0xfd, + 0x05, 0x1e, 0x00, 0xdb, 0x65, 0xe7, 0xcf, 0xe7, 0x06, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x06, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0xd5, 0xfb, 0x04, 0x31, 0x08, 0x9b, 0x49, 0x00, 0x59, 0x18, 0x0b, 0x88, + 0x0d, 0x93, 0x01, 0x23, 0x5b, 0x42, 0x0b, 0x80, 0x0a, 0x9b, 0x0c, 0x93, + 0x91, 0xe7, 0x00, 0x28, 0x2c, 0xd0, 0x20, 0x4b, 0x98, 0x42, 0xa0, 0xd0, + 0x08, 0xab, 0x5d, 0x8b, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0xcf, 0xe0, + 0x00, 0x2f, 0x00, 0xd0, 0xc4, 0xe0, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd1, + 0xa7, 0xe0, 0x2a, 0x00, 0x3b, 0x00, 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, + 0xe1, 0xf9, 0x05, 0x1e, 0xa0, 0xdb, 0x08, 0xab, 0x59, 0x8b, 0x30, 0x00, + 0xfe, 0xf7, 0xb8, 0xfe, 0x05, 0x1e, 0x00, 0xda, 0x98, 0xe7, 0x02, 0x97, + 0x08, 0xaa, 0x52, 0x8b, 0xe3, 0x88, 0x01, 0x92, 0x00, 0x97, 0x02, 0x22, + 0x39, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0x58, 0xff, 0xa7, 0x60, 0x8b, 0xe7, + 0x0d, 0x99, 0x30, 0x00, 0xfe, 0xf7, 0xa4, 0xfe, 0x00, 0x28, 0x00, 0xd1, + 0x6f, 0xe7, 0xcd, 0xe7, 0xfb, 0x3f, 0x06, 0x98, 0xa7, 0x60, 0x01, 0x38, + 0x83, 0xb2, 0x67, 0x61, 0x06, 0x93, 0xc3, 0xe6, 0xff, 0xff, 0x00, 0x00, + 0xec, 0xd8, 0xff, 0xff, 0xe1, 0xd8, 0xff, 0xff, 0x06, 0x9b, 0x0d, 0x9a, + 0x30, 0x00, 0xfe, 0xf7, 0x03, 0xfb, 0x00, 0x28, 0xb8, 0xd1, 0x6a, 0x46, + 0xe1, 0x88, 0x12, 0x8b, 0x49, 0x04, 0x08, 0xab, 0x49, 0x0c, 0x5a, 0x84, + 0x19, 0x84, 0xff, 0x23, 0x24, 0x30, 0x08, 0xaa, 0x12, 0x18, 0x13, 0x70, + 0x08, 0xaa, 0xe1, 0x3b, 0x9b, 0x18, 0x03, 0x93, 0x07, 0x9b, 0x10, 0xaa, + 0x02, 0x93, 0x01, 0x93, 0x00, 0x93, 0x30, 0x00, 0xfe, 0xf7, 0xf0, 0xfd, + 0x00, 0x28, 0x9d, 0xd1, 0x0d, 0x9b, 0xfb, 0x21, 0x1b, 0x02, 0x05, 0x33, + 0x0a, 0x93, 0x0b, 0x98, 0x08, 0xab, 0xdd, 0x8b, 0x01, 0xf0, 0x58, 0xfb, + 0x2d, 0x02, 0x05, 0x35, 0x00, 0x91, 0x0a, 0x9b, 0x2a, 0x00, 0x07, 0x99, + 0x30, 0x00, 0xfe, 0xf7, 0x65, 0xfb, 0x00, 0x28, 0x00, 0xd0, 0x87, 0xe7, + 0x0d, 0x99, 0x30, 0x00, 0xfe, 0xf7, 0x56, 0xfe, 0x00, 0x28, 0x00, 0xd0, + 0x80, 0xe7, 0x24, 0x21, 0x02, 0x22, 0x08, 0xab, 0x5b, 0x18, 0x1b, 0x78, + 0x30, 0x00, 0x93, 0x43, 0x08, 0xaa, 0x52, 0x18, 0x13, 0x70, 0x04, 0x21, + 0x62, 0x5e, 0x08, 0xab, 0x11, 0xa9, 0xdb, 0x8b, 0x01, 0x91, 0x01, 0x21, + 0x1b, 0x02, 0x00, 0x91, 0x04, 0x33, 0x06, 0x31, 0xfc, 0xf7, 0x79, 0xf9, + 0x00, 0x28, 0x00, 0xd0, 0x66, 0xe7, 0x08, 0xab, 0xdd, 0x8b, 0x09, 0x9b, + 0x00, 0x2b, 0x09, 0xd1, 0x06, 0x98, 0x17, 0x30, 0x08, 0x9b, 0x40, 0x00, + 0x1d, 0x52, 0x0b, 0x9b, 0xa3, 0x60, 0x63, 0x61, 0x1f, 0x00, 0x57, 0xe7, + 0x06, 0x9b, 0x68, 0x2b, 0x02, 0xd8, 0x18, 0x00, 0x04, 0x30, 0xf1, 0xe7, + 0x06, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0x11, 0xfb, 0x08, 0x1d, + 0xea, 0xe7, 0x70, 0x6a, 0xd2, 0x22, 0x2e, 0x30, 0xff, 0x21, 0x01, 0xf0, + 0x3c, 0xfb, 0x0f, 0xab, 0x04, 0x93, 0x01, 0x23, 0xe2, 0x88, 0x5b, 0x42, + 0x03, 0x93, 0x02, 0x97, 0x01, 0x97, 0x73, 0x6a, 0x00, 0x93, 0x2b, 0x00, + 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0xde, 0xff, 0x05, 0x1e, 0x00, 0xdb, + 0x5a, 0xe7, 0xe7, 0xe6, 0x0f, 0xab, 0x04, 0x93, 0x09, 0x9b, 0xe2, 0x88, + 0x03, 0x97, 0x02, 0x93, 0x01, 0x93, 0xec, 0xe7, 0x2a, 0x00, 0x09, 0x9b, + 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0x18, 0xf9, 0x05, 0x1e, 0x00, 0xda, + 0xd6, 0xe6, 0x00, 0x25, 0x04, 0x22, 0xa1, 0x5e, 0x10, 0xaa, 0x02, 0x92, + 0x08, 0xaa, 0x52, 0x8b, 0xe3, 0x88, 0x01, 0x92, 0x00, 0x95, 0x08, 0x9a, + 0x30, 0x00, 0xfe, 0xf7, 0x15, 0xfe, 0x05, 0x1e, 0x00, 0xda, 0xc5, 0xe6, + 0x00, 0x25, 0x08, 0xaa, 0x02, 0x95, 0x12, 0x8c, 0xe3, 0x88, 0x01, 0x92, + 0x08, 0x9a, 0x30, 0x00, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, + 0x00, 0x92, 0x08, 0x99, 0x2a, 0x00, 0xfe, 0xf7, 0x7f, 0xfe, 0x08, 0xab, + 0x1b, 0x8c, 0x0f, 0xa9, 0xe3, 0x81, 0x6b, 0x46, 0x9b, 0x8c, 0x67, 0x61, + 0x23, 0x82, 0xe2, 0x88, 0xa3, 0x89, 0x04, 0x91, 0x03, 0x97, 0x02, 0x95, + 0x01, 0x95, 0x00, 0x95, 0xb4, 0xe7, 0x0a, 0x4d, 0xa2, 0xe6, 0x0a, 0x4d, + 0xa0, 0xe6, 0x0a, 0x4d, 0x9e, 0xe6, 0x0a, 0x4d, 0x9c, 0xe6, 0x0a, 0x4d, + 0x9a, 0xe6, 0x00, 0x23, 0x0a, 0x93, 0x0c, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0xf1, 0xe5, 0x5d, 0xe6, 0x0a, 0x9b, 0x09, 0x93, 0xc4, 0xe6, 0xc0, 0x46, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x8f, 0xb0, + 0x07, 0x91, 0x08, 0x93, 0x03, 0x68, 0x04, 0x00, 0xfb, 0x21, 0x07, 0x98, + 0x04, 0x93, 0x0b, 0x92, 0x01, 0xf0, 0x02, 0xfa, 0x87, 0xb2, 0x00, 0x20, + 0x04, 0x9b, 0x5b, 0x6a, 0x06, 0x93, 0x07, 0x9b, 0x03, 0x93, 0x6b, 0x4b, + 0x05, 0x93, 0x0b, 0x9a, 0x07, 0x9b, 0x94, 0x46, 0x03, 0x9a, 0x63, 0x44, + 0x0a, 0x93, 0x93, 0x42, 0x3a, 0xd9, 0xe2, 0x6a, 0x00, 0x2a, 0x0c, 0xd0, + 0x13, 0x89, 0xbb, 0x42, 0x09, 0xd8, 0x51, 0x89, 0xb9, 0x42, 0x06, 0xd3, + 0xfb, 0x1a, 0x12, 0x68, 0x5b, 0x00, 0x9d, 0x5a, 0x00, 0x2d, 0x00, 0xd0, + 0x82, 0xe0, 0x68, 0x2f, 0x3d, 0xd9, 0x38, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x01, 0xf0, 0xda, 0xf9, 0x05, 0x9b, 0x01, 0x30, 0x85, 0xb2, 0xab, 0x42, + 0x06, 0xd1, 0x38, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0x56, 0xfa, + 0x04, 0x31, 0x1c, 0xe0, 0x23, 0x8a, 0xab, 0x42, 0x05, 0xd1, 0x0e, 0x23, + 0xe2, 0x89, 0x0a, 0xa9, 0x5b, 0x18, 0x1a, 0x80, 0x2c, 0xe0, 0x80, 0x23, + 0xe1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x0e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x2a, 0x00, 0x00, 0x23, 0x04, 0x98, 0xfe, 0xf7, 0x5a, 0xfc, + 0x00, 0x28, 0x1d, 0xda, 0x0f, 0xb0, 0xf0, 0xbd, 0x39, 0x1d, 0x68, 0x2f, + 0xdb, 0xd8, 0x06, 0x9b, 0x49, 0x00, 0x5d, 0x5a, 0x4e, 0xe0, 0x45, 0x48, + 0xf4, 0xe7, 0x45, 0x48, 0xf2, 0xe7, 0x45, 0x48, 0xf0, 0xe7, 0x45, 0x48, + 0xee, 0xe7, 0x45, 0x48, 0xec, 0xe7, 0x45, 0x48, 0xea, 0xe7, 0x05, 0x9b, + 0x00, 0x2b, 0x38, 0xd0, 0x0e, 0x23, 0x00, 0x25, 0xa2, 0x89, 0x0a, 0xa9, + 0x5b, 0x18, 0x1a, 0x80, 0x0e, 0x26, 0x04, 0x21, 0x62, 0x5e, 0x04, 0x99, + 0x0a, 0xab, 0x49, 0x6a, 0xf6, 0x18, 0x33, 0x88, 0x05, 0x91, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x04, 0x98, + 0xfb, 0xf7, 0xf3, 0xff, 0x00, 0x28, 0xcd, 0xdb, 0x01, 0x22, 0x06, 0x9b, + 0x1b, 0x79, 0x13, 0x42, 0xd1, 0xd1, 0x5a, 0xb2, 0x00, 0x2a, 0xd0, 0xda, + 0x9a, 0x07, 0xd0, 0xd4, 0x5b, 0x07, 0xd0, 0xd4, 0x06, 0x22, 0xa3, 0x5e, + 0x00, 0x2b, 0xcc, 0xda, 0x06, 0x9b, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, + 0x13, 0x43, 0x05, 0x93, 0xab, 0x42, 0xc6, 0xd1, 0x03, 0x9b, 0x25, 0x82, + 0x63, 0x61, 0x33, 0x88, 0xe3, 0x81, 0x00, 0x2d, 0xb0, 0xd1, 0x3b, 0x00, + 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9d, 0x5a, 0x00, 0x23, 0x05, 0x93, + 0xfb, 0x21, 0x03, 0x98, 0x01, 0xf0, 0xe0, 0xf9, 0x0a, 0x9b, 0x03, 0x9a, + 0x09, 0x91, 0x9a, 0x1a, 0x03, 0x99, 0xa3, 0x68, 0x5b, 0x1a, 0x93, 0x42, + 0x00, 0xd9, 0x13, 0x00, 0xfb, 0x26, 0x09, 0x9a, 0xb6, 0x1a, 0x9e, 0x42, + 0x00, 0xd9, 0x1e, 0x00, 0x00, 0x2e, 0xa4, 0xd0, 0x21, 0x1d, 0x3b, 0x00, + 0x2a, 0x00, 0x04, 0x98, 0xfe, 0xf7, 0x4c, 0xf9, 0x00, 0x28, 0x00, 0xda, + 0x88, 0xe7, 0x09, 0x9b, 0x04, 0x21, 0x62, 0x5e, 0x08, 0x99, 0x2d, 0x02, + 0x05, 0x33, 0x01, 0x91, 0xeb, 0x18, 0x00, 0x96, 0x17, 0x21, 0x04, 0x98, + 0xfb, 0xf7, 0x9f, 0xff, 0x00, 0x28, 0x00, 0xda, 0x78, 0xe7, 0x08, 0x9b, + 0x01, 0x37, 0x9b, 0x19, 0x08, 0x93, 0x03, 0x9b, 0xbf, 0xb2, 0x9b, 0x19, + 0x03, 0x93, 0x63, 0x61, 0x2b, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x0f, 0x23, 0x8d, 0xb0, 0x06, 0x91, 0x01, 0x21, 0x07, 0x92, + 0xc2, 0x68, 0x05, 0x00, 0x53, 0x43, 0x5b, 0x08, 0x09, 0xaa, 0x5b, 0x18, + 0x11, 0x80, 0x99, 0xb2, 0x1b, 0x04, 0x3c, 0xd4, 0x51, 0x80, 0x00, 0x23, + 0x53, 0x60, 0x07, 0x9b, 0x93, 0x60, 0x09, 0xac, 0x23, 0x88, 0x68, 0x6a, + 0x9c, 0x46, 0x62, 0x46, 0x63, 0x88, 0x9b, 0x1a, 0x80, 0x22, 0x12, 0x01, + 0x93, 0x42, 0x37, 0xdc, 0x80, 0x22, 0x00, 0x21, 0x52, 0x00, 0x01, 0xf0, + 0xaa, 0xf9, 0x00, 0x21, 0x07, 0x9b, 0x05, 0x91, 0x02, 0x93, 0x3d, 0x4b, + 0x04, 0x91, 0x01, 0x93, 0x03, 0x94, 0x0b, 0x00, 0x00, 0x91, 0x0a, 0x00, + 0x28, 0x00, 0xfe, 0xf7, 0xa9, 0xf9, 0x39, 0x4b, 0x98, 0x42, 0x01, 0xd0, + 0x00, 0x28, 0x12, 0xdb, 0x80, 0x26, 0x00, 0x22, 0x01, 0x23, 0x6f, 0x6a, + 0x76, 0x00, 0xbd, 0x5c, 0xff, 0x2d, 0x12, 0xd0, 0x00, 0x21, 0x28, 0x00, + 0x08, 0x41, 0x18, 0x40, 0x0a, 0xd1, 0x23, 0x88, 0xd2, 0x00, 0x59, 0x18, + 0x06, 0x9b, 0x8a, 0x18, 0x1a, 0x80, 0x0d, 0xb0, 0xf0, 0xbd, 0x2d, 0x4b, + 0x53, 0x80, 0xc0, 0xe7, 0x01, 0x31, 0x08, 0x29, 0xed, 0xd1, 0x01, 0x32, + 0xb2, 0x42, 0xe6, 0xd1, 0x29, 0x48, 0xf2, 0xe7, 0x62, 0x68, 0x00, 0x2a, + 0x1d, 0xd1, 0x09, 0xac, 0x22, 0x88, 0x63, 0x88, 0x00, 0x26, 0x9b, 0x1a, + 0x80, 0x22, 0x1b, 0x0a, 0x52, 0x00, 0x00, 0x21, 0x63, 0x60, 0x01, 0xf0, + 0x68, 0xf9, 0x22, 0x4b, 0x05, 0x96, 0x01, 0x93, 0x04, 0x96, 0x33, 0x00, + 0x03, 0x96, 0x02, 0x94, 0x00, 0x96, 0x32, 0x00, 0x31, 0x00, 0x28, 0x00, + 0xfe, 0xf7, 0x68, 0xf9, 0x18, 0x4b, 0x98, 0x42, 0x26, 0xd1, 0xa6, 0x60, + 0x9b, 0xe7, 0x00, 0x27, 0xff, 0x23, 0x39, 0x00, 0x46, 0x5c, 0x9e, 0x42, + 0x02, 0xd2, 0x33, 0x1e, 0x06, 0xd0, 0x0f, 0x00, 0x80, 0x26, 0x01, 0x31, + 0x76, 0x00, 0xb1, 0x42, 0xf4, 0xd1, 0x39, 0x00, 0x9a, 0x42, 0xcb, 0xd0, + 0x92, 0xb2, 0x51, 0x43, 0x61, 0x44, 0x89, 0xb2, 0x00, 0x2b, 0x03, 0xd1, + 0x06, 0x9a, 0x18, 0x00, 0x11, 0x80, 0xb6, 0xe7, 0x80, 0x23, 0x52, 0x18, + 0x92, 0xb2, 0x62, 0x80, 0x21, 0x80, 0x52, 0x1a, 0x1b, 0x01, 0x9a, 0x42, + 0xbd, 0xdc, 0x76, 0xe7, 0x00, 0x28, 0xaa, 0xdb, 0xa6, 0x60, 0x00, 0xd1, + 0x71, 0xe7, 0xa6, 0xe7, 0x31, 0x49, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xff, 0x7f, 0x00, 0x00, 0xef, 0xd8, 0xff, 0xff, 0x6d, 0x4b, 0x00, 0x00, + 0xf0, 0xb5, 0x85, 0xb0, 0x05, 0x00, 0x03, 0x91, 0x14, 0x00, 0x10, 0x1e, + 0x01, 0xd0, 0xfe, 0xf7, 0x57, 0xf8, 0xeb, 0x6a, 0xae, 0x6a, 0x02, 0x93, + 0x00, 0x2c, 0x07, 0xd0, 0x30, 0x23, 0x02, 0x99, 0x32, 0x1d, 0x4b, 0x43, + 0xf3, 0x18, 0x04, 0x33, 0x93, 0x42, 0x0e, 0xd1, 0x2a, 0x4a, 0x01, 0x23, + 0x01, 0x92, 0x00, 0x22, 0x31, 0x1d, 0x5b, 0x42, 0x00, 0x92, 0x02, 0x9f, + 0x00, 0x9a, 0xba, 0x42, 0x0e, 0xd1, 0x5a, 0x1c, 0x21, 0xd1, 0x25, 0x48, + 0x3b, 0xe0, 0x00, 0x27, 0xd1, 0x5f, 0x00, 0x29, 0x04, 0xd1, 0x91, 0x8c, + 0x01, 0x29, 0x01, 0xd9, 0x01, 0x39, 0x91, 0x84, 0x30, 0x32, 0xe3, 0xe7, + 0x00, 0x22, 0x8f, 0x5e, 0x00, 0x2f, 0x0a, 0xd1, 0x00, 0x2c, 0x02, 0xd0, + 0x0f, 0x6a, 0x87, 0x42, 0x0a, 0xd0, 0x8f, 0x8c, 0x01, 0x9a, 0x97, 0x42, + 0x01, 0xd2, 0x00, 0x9b, 0x01, 0x97, 0x00, 0x9a, 0x30, 0x31, 0x01, 0x32, + 0x00, 0x92, 0xd8, 0xe7, 0x00, 0x9b, 0x30, 0x22, 0x5a, 0x43, 0xb6, 0x18, + 0x00, 0x2c, 0x11, 0xd0, 0x72, 0x6a, 0x82, 0x42, 0x19, 0xd1, 0x31, 0x8d, + 0x00, 0x29, 0x16, 0xd0, 0xb2, 0x89, 0x10, 0x09, 0x28, 0x83, 0x0f, 0x20, + 0x02, 0x40, 0x01, 0x3a, 0xea, 0x61, 0x0c, 0x4a, 0x91, 0x42, 0x08, 0xd8, + 0x04, 0x31, 0x31, 0x85, 0x00, 0x20, 0x01, 0x33, 0xb3, 0x80, 0x03, 0x9b, + 0x1e, 0x60, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x22, 0x52, 0x42, 0x32, 0x85, + 0xf4, 0xe7, 0x04, 0x22, 0x70, 0x62, 0x32, 0x85, 0xf0, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xe9, 0xd8, 0xff, 0xff, 0xfa, 0xff, 0x00, 0x00, + 0x00, 0x29, 0x10, 0xdd, 0x2c, 0x22, 0x83, 0x5e, 0x8b, 0x42, 0x0c, 0xdb, + 0x30, 0x23, 0x4b, 0x43, 0x81, 0x6a, 0x30, 0x3b, 0xc9, 0x18, 0x04, 0x22, + 0x8b, 0x5e, 0x00, 0x2b, 0x05, 0xd0, 0x00, 0x20, 0x88, 0x80, 0xc8, 0x62, + 0x70, 0x47, 0x02, 0x48, 0xfc, 0xe7, 0x02, 0x48, 0xfa, 0xe7, 0xc0, 0x46, + 0xe6, 0xd8, 0xff, 0xff, 0xe8, 0xd8, 0xff, 0xff, 0x10, 0xb5, 0x00, 0x29, + 0x11, 0xdd, 0x2c, 0x24, 0x03, 0x5f, 0x8b, 0x42, 0x0d, 0xdb, 0x30, 0x23, + 0x59, 0x43, 0x83, 0x6a, 0x30, 0x39, 0x59, 0x18, 0x11, 0x60, 0x04, 0x23, + 0xc8, 0x5e, 0x43, 0x42, 0x58, 0x41, 0x03, 0x4b, 0x40, 0x42, 0x18, 0x40, + 0x10, 0xbd, 0x02, 0x48, 0xfc, 0xe7, 0xc0, 0x46, 0xe8, 0xd8, 0xff, 0xff, + 0xe6, 0xd8, 0xff, 0xff, 0x03, 0x7d, 0x00, 0x2b, 0x04, 0xd1, 0x43, 0x75, + 0x83, 0x75, 0x83, 0x61, 0x01, 0x33, 0x03, 0x75, 0x70, 0x47, 0x7f, 0xb5, + 0xc3, 0x68, 0x02, 0xad, 0x04, 0x00, 0x0e, 0x00, 0x02, 0x91, 0x6a, 0x60, + 0x8b, 0x42, 0x03, 0xd1, 0x02, 0x8a, 0xab, 0x88, 0x9a, 0x42, 0x18, 0xd0, + 0x20, 0x00, 0x06, 0x22, 0x29, 0x00, 0x0c, 0x30, 0x01, 0xf0, 0x52, 0xf8, + 0x20, 0x68, 0x00, 0xf0, 0x90, 0xf9, 0x6b, 0x79, 0x22, 0x7a, 0xe1, 0x79, + 0x00, 0x93, 0x20, 0x68, 0x00, 0x23, 0x00, 0xf0, 0x29, 0xfa, 0x20, 0x68, + 0x29, 0x79, 0x32, 0x00, 0x00, 0xf0, 0x54, 0xf9, 0x20, 0x68, 0x00, 0xf0, + 0x76, 0xf9, 0x7f, 0xbd, 0x70, 0xb5, 0x18, 0x26, 0x04, 0x00, 0xff, 0xf7, + 0xcb, 0xff, 0x33, 0x00, 0x08, 0x21, 0x20, 0x79, 0x0d, 0x4d, 0x43, 0x43, + 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0xc6, 0xfe, 0x33, 0x00, 0x08, 0x21, + 0xa0, 0x79, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0xbe, 0xfe, + 0x08, 0x21, 0x60, 0x79, 0x46, 0x43, 0xad, 0x19, 0x69, 0x56, 0x00, 0xf0, + 0xb7, 0xfe, 0x04, 0x4b, 0x20, 0x00, 0x06, 0xcb, 0xff, 0xf7, 0xb7, 0xff, + 0x70, 0xbd, 0xc0, 0x46, 0x20, 0x82, 0x00, 0x00, 0x18, 0x0c, 0x00, 0x20, + 0x07, 0xb5, 0x43, 0x7d, 0x00, 0x91, 0x01, 0x92, 0x00, 0x2b, 0x07, 0xd0, + 0x9a, 0x07, 0x0a, 0xd5, 0xef, 0xf3, 0x10, 0x83, 0x5a, 0x42, 0x53, 0x41, + 0x83, 0x75, 0x72, 0xb6, 0x00, 0x99, 0x01, 0x9a, 0xff, 0xf7, 0x9f, 0xff, + 0x07, 0xbd, 0xdb, 0x07, 0xf8, 0xd5, 0x83, 0x69, 0x01, 0x4a, 0x9b, 0xb2, + 0x93, 0x60, 0xf3, 0xe7, 0x00, 0x18, 0x00, 0x40, 0x10, 0xb5, 0x00, 0x68, + 0x00, 0xf0, 0x40, 0xf9, 0x10, 0xbd, 0x00, 0x00, 0x0a, 0x4b, 0x0b, 0x4a, + 0x0b, 0x49, 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, 0x0a, 0x4b, + 0x19, 0x60, 0x0a, 0x49, 0xda, 0x60, 0x99, 0x80, 0x09, 0x21, 0x5a, 0x74, + 0x1a, 0x74, 0x1a, 0x75, 0xda, 0x71, 0x03, 0x32, 0x99, 0x71, 0x1a, 0x72, + 0x70, 0x47, 0xc0, 0x46, 0x18, 0x0c, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, + 0x9c, 0x10, 0x00, 0x20, 0xfc, 0x0b, 0x00, 0x20, 0x0a, 0x08, 0x00, 0x00, + 0x10, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x19, 0xfb, 0x10, 0xbd, 0xc0, 0x46, + 0x20, 0x0c, 0x00, 0x20, 0x10, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x11, 0xfb, + 0x10, 0xbd, 0xc0, 0x46, 0x5c, 0x0e, 0x00, 0x20, 0x73, 0xb5, 0x17, 0x49, + 0x17, 0x48, 0x00, 0xf0, 0x47, 0xf8, 0x17, 0x49, 0x17, 0x48, 0x00, 0xf0, + 0x43, 0xf8, 0x17, 0x49, 0x17, 0x48, 0x00, 0xf0, 0x3f, 0xf8, 0x17, 0x49, + 0x17, 0x48, 0x00, 0xf0, 0x3b, 0xf8, 0x17, 0x4c, 0x17, 0x49, 0x20, 0x00, + 0x00, 0xf0, 0x36, 0xf8, 0x16, 0x4e, 0x17, 0x49, 0x30, 0x00, 0x00, 0xf0, + 0x31, 0xf8, 0x01, 0x25, 0x03, 0x23, 0x31, 0x00, 0x01, 0x95, 0x00, 0x93, + 0x0d, 0x22, 0x0b, 0x33, 0x12, 0x48, 0x00, 0xf0, 0x7d, 0xfa, 0x00, 0x23, + 0x00, 0x95, 0x01, 0x93, 0x1b, 0x22, 0x1a, 0x33, 0x21, 0x00, 0x0f, 0x48, + 0x00, 0xf0, 0x74, 0xfa, 0x73, 0xbd, 0xc0, 0x46, 0x00, 0x08, 0x00, 0x42, + 0x98, 0x10, 0x00, 0x20, 0x00, 0x0c, 0x00, 0x42, 0x9c, 0x10, 0x00, 0x20, + 0x00, 0x10, 0x00, 0x42, 0xa0, 0x10, 0x00, 0x20, 0x00, 0x14, 0x00, 0x42, + 0xa4, 0x10, 0x00, 0x20, 0xa8, 0x10, 0x00, 0x20, 0x00, 0x18, 0x00, 0x42, + 0xac, 0x10, 0x00, 0x20, 0x00, 0x1c, 0x00, 0x42, 0x20, 0x0c, 0x00, 0x20, + 0x5c, 0x0e, 0x00, 0x20, 0x01, 0x60, 0x70, 0x47, 0x94, 0x46, 0xf0, 0xb5, + 0x9e, 0x1e, 0x72, 0x1e, 0x96, 0x41, 0x62, 0x46, 0x05, 0x68, 0x92, 0x07, + 0x2f, 0x68, 0x36, 0x06, 0x3a, 0x43, 0x32, 0x43, 0x2a, 0x60, 0x07, 0x25, + 0x05, 0xac, 0x24, 0x78, 0x00, 0x68, 0xa4, 0x01, 0x29, 0x40, 0x21, 0x43, + 0x42, 0x68, 0x00, 0x24, 0x02, 0x2b, 0x00, 0xd0, 0x5c, 0x03, 0x11, 0x43, + 0x21, 0x43, 0x41, 0x60, 0xf0, 0xbd, 0x30, 0xb5, 0xc0, 0x25, 0x03, 0x68, + 0xad, 0x03, 0x1c, 0x68, 0x12, 0x05, 0x2a, 0x40, 0x22, 0x43, 0xc0, 0x24, + 0x09, 0x04, 0xa4, 0x02, 0x21, 0x40, 0x11, 0x43, 0x19, 0x60, 0x03, 0x68, + 0x5a, 0x68, 0x14, 0x43, 0x5c, 0x60, 0x30, 0xbd, 0x01, 0x23, 0x02, 0x68, + 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, 0x03, 0x68, 0x1a, 0x68, 0xd2, 0x07, + 0xfc, 0xd4, 0xda, 0x69, 0xd2, 0x07, 0xf9, 0xd4, 0x70, 0x47, 0x02, 0x23, + 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, 0x02, 0x68, 0xd3, 0x69, + 0x9b, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, + 0x02, 0xd4, 0x1a, 0x7e, 0x92, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0x00, 0x22, + 0x03, 0x68, 0x5a, 0x83, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x40, 0x07, + 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x09, 0x70, 0x47, + 0x80, 0x23, 0x02, 0x68, 0x5b, 0x42, 0x11, 0x7e, 0x0b, 0x43, 0x13, 0x76, + 0x70, 0x47, 0x03, 0x68, 0x58, 0x8b, 0x80, 0x07, 0xc0, 0x0f, 0x70, 0x47, + 0x02, 0x23, 0x02, 0x68, 0x51, 0x8b, 0x0b, 0x43, 0x53, 0x83, 0x70, 0x47, + 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, + 0x18, 0x8d, 0xc0, 0xb2, 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, + 0xfc, 0xd5, 0x89, 0xb2, 0x01, 0x20, 0x19, 0x85, 0x70, 0x47, 0x01, 0x22, + 0x03, 0x68, 0x9a, 0x75, 0x70, 0x47, 0x01, 0x22, 0x03, 0x68, 0x1a, 0x75, + 0x70, 0x47, 0x00, 0x00, 0x70, 0xb5, 0x01, 0x26, 0x04, 0x68, 0x4b, 0x08, + 0x33, 0x40, 0x31, 0x40, 0x25, 0x68, 0x09, 0x07, 0x5b, 0x07, 0x0b, 0x43, + 0x2b, 0x43, 0x23, 0x60, 0x04, 0x68, 0x51, 0x00, 0x03, 0x48, 0x00, 0xf0, + 0x2d, 0xfe, 0x01, 0x38, 0xc0, 0xb2, 0x20, 0x73, 0x70, 0xbd, 0xc0, 0x46, + 0x00, 0x6c, 0xdc, 0x02, 0x01, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, + 0x13, 0x60, 0x03, 0x68, 0x1a, 0x68, 0xd2, 0x07, 0xfc, 0xd4, 0xda, 0x69, + 0xd2, 0x07, 0xf9, 0xd4, 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, 0x11, 0x68, + 0x0b, 0x43, 0x13, 0x60, 0x02, 0x68, 0xd3, 0x69, 0x9b, 0x07, 0xfc, 0xd4, + 0x70, 0x47, 0x03, 0x68, 0xda, 0x69, 0x92, 0x07, 0xfc, 0xd4, 0x02, 0x21, + 0x1a, 0x68, 0x8a, 0x43, 0x1a, 0x60, 0x70, 0x47, 0x02, 0x68, 0x93, 0x6a, + 0x5b, 0x0a, 0x5b, 0x02, 0x19, 0x43, 0x91, 0x62, 0x03, 0x68, 0x1a, 0x7e, + 0x52, 0x07, 0xfc, 0xd5, 0x98, 0x6a, 0xc0, 0xb2, 0x70, 0x47, 0x00, 0x00, + 0x03, 0x68, 0x21, 0x4a, 0x30, 0xb5, 0x93, 0x42, 0x2f, 0xd0, 0x20, 0x4a, + 0x93, 0x42, 0x2f, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1f, 0x4a, + 0x93, 0x42, 0x2f, 0xd0, 0x1e, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1e, 0x4a, + 0x93, 0x42, 0x1f, 0xd1, 0x0e, 0x23, 0x19, 0x22, 0x01, 0x21, 0x03, 0x25, + 0x99, 0x40, 0x1b, 0x48, 0xc0, 0x24, 0x01, 0x60, 0x99, 0x08, 0x2b, 0x40, + 0xab, 0x40, 0xfc, 0x35, 0x9d, 0x40, 0x89, 0x00, 0x09, 0x18, 0xa4, 0x00, + 0x08, 0x59, 0xa8, 0x43, 0xc0, 0x25, 0x9d, 0x40, 0x2b, 0x00, 0x03, 0x43, + 0x0b, 0x51, 0x80, 0x23, 0xdb, 0x01, 0x1a, 0x43, 0x11, 0x4b, 0x5a, 0x80, + 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, 0x30, 0xbd, 0x09, 0x23, + 0x14, 0x22, 0xdd, 0xe7, 0x0a, 0x23, 0x15, 0x22, 0xda, 0xe7, 0x0b, 0x23, + 0x16, 0x22, 0xd7, 0xe7, 0x0c, 0x23, 0x17, 0x22, 0xd4, 0xe7, 0x0d, 0x23, + 0x18, 0x22, 0xd1, 0xe7, 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, + 0x00, 0x10, 0x00, 0x42, 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, + 0x00, 0x1c, 0x00, 0x42, 0x00, 0xe1, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x40, + 0xf8, 0xb5, 0x04, 0x00, 0x0f, 0x00, 0x16, 0x00, 0x1d, 0x00, 0xff, 0xf7, + 0xa5, 0xff, 0x20, 0x00, 0xff, 0xf7, 0x04, 0xff, 0x1c, 0x21, 0xbb, 0x00, + 0x0b, 0x40, 0x71, 0x07, 0x22, 0x68, 0x09, 0x0c, 0x0b, 0x43, 0x13, 0x60, + 0x84, 0x23, 0x22, 0x68, 0x93, 0x75, 0x01, 0x2f, 0x1a, 0xd1, 0x10, 0x21, + 0x01, 0x2e, 0x00, 0xd0, 0x08, 0x39, 0x0c, 0x4b, 0x69, 0x43, 0x18, 0x68, + 0xc0, 0x00, 0x00, 0xf0, 0x83, 0xfd, 0x07, 0x22, 0x21, 0x68, 0x02, 0x40, + 0x8b, 0x89, 0x52, 0x03, 0xdb, 0x04, 0xdb, 0x0c, 0x13, 0x43, 0x8b, 0x81, + 0x22, 0x68, 0x03, 0x04, 0x90, 0x89, 0xdb, 0x0c, 0x40, 0x0b, 0x40, 0x03, + 0x18, 0x43, 0x90, 0x81, 0xf8, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, + 0xf7, 0xb5, 0x06, 0x00, 0x01, 0x93, 0x08, 0xab, 0x1f, 0x78, 0x0d, 0x00, + 0x14, 0x00, 0xff, 0xf7, 0x3f, 0xff, 0x30, 0x00, 0xff, 0xf7, 0x6a, 0xff, + 0xc0, 0x22, 0x24, 0x05, 0x92, 0x03, 0x14, 0x40, 0xba, 0x07, 0x0c, 0x27, + 0x17, 0x43, 0x3c, 0x43, 0xc0, 0x27, 0x07, 0x22, 0xbf, 0x02, 0x2d, 0x04, + 0x33, 0x68, 0x3d, 0x40, 0x25, 0x43, 0x1d, 0x60, 0x01, 0x9b, 0x31, 0x68, + 0x13, 0x40, 0x1a, 0x00, 0x80, 0x23, 0x9b, 0x02, 0x13, 0x43, 0x4b, 0x60, + 0xf7, 0xbd, 0x01, 0x20, 0x70, 0x47, 0x00, 0x00, 0x10, 0xb5, 0x03, 0x68, + 0x01, 0x4a, 0x1b, 0x6a, 0x98, 0x47, 0x10, 0xbd, 0x13, 0x04, 0x00, 0x00, + 0x03, 0x00, 0xfc, 0x33, 0xd9, 0x69, 0x9a, 0x69, 0x91, 0x42, 0x03, 0xd0, + 0xdb, 0x69, 0xc0, 0x18, 0x00, 0x7d, 0x70, 0x47, 0x01, 0x20, 0x40, 0x42, + 0xfb, 0xe7, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x69, 0xff, 0xf7, 0x96, 0xfe, + 0x22, 0x00, 0x00, 0x23, 0xfc, 0x32, 0x93, 0x61, 0xd3, 0x61, 0x86, 0x22, + 0x92, 0x00, 0xa4, 0x18, 0x63, 0x60, 0xa3, 0x60, 0x10, 0xbd, 0xf0, 0x20, + 0x01, 0x40, 0x30, 0x39, 0x48, 0x42, 0x48, 0x41, 0x70, 0x47, 0xf0, 0x23, + 0x1b, 0x01, 0x19, 0x40, 0x80, 0x23, 0x06, 0x20, 0x9b, 0x00, 0x99, 0x42, + 0x0a, 0xd0, 0x01, 0x33, 0xff, 0x33, 0x01, 0x30, 0x99, 0x42, 0x05, 0xd0, + 0x80, 0x23, 0x02, 0x38, 0x5b, 0x00, 0x99, 0x42, 0x00, 0xd0, 0x00, 0x20, + 0x70, 0x47, 0x0f, 0x20, 0x01, 0x40, 0x00, 0x20, 0x01, 0x29, 0x03, 0xd0, + 0x02, 0x39, 0x48, 0x1e, 0x81, 0x41, 0x48, 0x1c, 0x70, 0x47, 0x00, 0x00, + 0x89, 0x23, 0xf0, 0xb5, 0x18, 0x26, 0x85, 0xb0, 0x02, 0x91, 0x9b, 0x00, + 0x04, 0x00, 0xc0, 0x5c, 0x33, 0x00, 0x08, 0x21, 0x43, 0x43, 0x32, 0x4d, + 0x17, 0x00, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x31, 0xfc, 0x30, 0x4b, + 0x08, 0x21, 0xe0, 0x5c, 0x33, 0x00, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, + 0x00, 0xf0, 0x28, 0xfc, 0x2c, 0x4b, 0xe2, 0x5c, 0x03, 0x93, 0x02, 0x2a, + 0x09, 0xd1, 0x11, 0x33, 0xe0, 0x5c, 0xff, 0x28, 0x05, 0xd0, 0x08, 0x21, + 0x46, 0x43, 0xae, 0x19, 0x71, 0x56, 0x00, 0xf0, 0x19, 0xfc, 0x8a, 0x26, + 0xb6, 0x00, 0xa0, 0x5d, 0xff, 0x28, 0x19, 0xd0, 0x01, 0x21, 0x00, 0xf0, + 0x99, 0xfb, 0x18, 0x22, 0xa3, 0x5d, 0x21, 0x49, 0x5a, 0x43, 0xab, 0x56, + 0xad, 0x18, 0xdb, 0x01, 0x58, 0x18, 0x8b, 0x21, 0x89, 0x00, 0x60, 0x50, + 0x1d, 0x49, 0x01, 0x22, 0x5b, 0x18, 0x8c, 0x21, 0x89, 0x00, 0x63, 0x50, + 0x69, 0x68, 0x8a, 0x40, 0x8d, 0x21, 0x89, 0x00, 0x62, 0x50, 0x1a, 0x60, + 0x01, 0x22, 0x02, 0x9b, 0x11, 0x00, 0x20, 0x69, 0xff, 0xf7, 0x0a, 0xff, + 0x39, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x8f, 0xff, 0x39, 0x00, 0x05, 0x00, + 0x20, 0x00, 0xff, 0xf7, 0x9e, 0xff, 0x39, 0x00, 0x06, 0x00, 0x20, 0x00, + 0xff, 0xf7, 0x7f, 0xff, 0x33, 0x00, 0x00, 0x90, 0x29, 0x00, 0x20, 0x69, + 0x01, 0x22, 0xff, 0xf7, 0xd3, 0xfd, 0x0b, 0x4b, 0x20, 0x69, 0xe2, 0x5c, + 0x03, 0x9b, 0xe1, 0x5c, 0xff, 0xf7, 0xe9, 0xfd, 0x20, 0x69, 0xff, 0xf7, + 0x06, 0xfe, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0x20, 0x82, 0x00, 0x00, + 0x25, 0x02, 0x00, 0x00, 0x27, 0x02, 0x00, 0x00, 0x18, 0x44, 0x00, 0x41, + 0x14, 0x44, 0x00, 0x41, 0x26, 0x02, 0x00, 0x00, 0x80, 0x22, 0x10, 0xb5, + 0x04, 0x00, 0x52, 0x00, 0x00, 0x21, 0x00, 0xf0, 0x32, 0xfd, 0x23, 0x00, + 0x00, 0x22, 0xfc, 0x33, 0x5a, 0x60, 0x20, 0x00, 0x9a, 0x60, 0x10, 0xbd, + 0xf7, 0xb5, 0x1d, 0x00, 0x08, 0xab, 0x1b, 0x78, 0x04, 0x00, 0x00, 0x93, + 0x09, 0xab, 0x1b, 0x78, 0x16, 0x00, 0x01, 0x93, 0x00, 0x23, 0x43, 0x60, + 0xfa, 0x23, 0x9b, 0x00, 0x83, 0x60, 0x11, 0x4b, 0x0f, 0x00, 0x08, 0x33, + 0x03, 0x60, 0x14, 0x30, 0xff, 0xf7, 0xdc, 0xff, 0x20, 0x00, 0x1d, 0x30, + 0xff, 0x30, 0xff, 0xf7, 0xd7, 0xff, 0x89, 0x23, 0x6a, 0x46, 0x9b, 0x00, + 0x27, 0x61, 0xe6, 0x54, 0x09, 0x4b, 0x12, 0x78, 0xe5, 0x54, 0x09, 0x4b, + 0x20, 0x00, 0xe2, 0x54, 0x6a, 0x46, 0x08, 0x4b, 0x12, 0x79, 0xe2, 0x54, + 0x8a, 0x22, 0x29, 0x3b, 0xff, 0x3b, 0x92, 0x00, 0xa3, 0x54, 0x10, 0x32, + 0xa3, 0x54, 0xfe, 0xbd, 0x80, 0x85, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, + 0x26, 0x02, 0x00, 0x00, 0x27, 0x02, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, + 0x58, 0x68, 0x9b, 0x68, 0xc0, 0x1a, 0x01, 0xd5, 0x01, 0x30, 0xff, 0x30, + 0x70, 0x47, 0x10, 0xb5, 0x04, 0x00, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0xf0, 0xff, 0x00, 0x28, 0xf8, 0xd1, 0x20, 0x69, 0xff, 0xf7, + 0xa4, 0xfd, 0x10, 0xbd, 0x10, 0xb5, 0x14, 0x30, 0xff, 0xf7, 0xe6, 0xff, + 0x10, 0xbd, 0x03, 0x00, 0xfc, 0x33, 0x59, 0x68, 0x9a, 0x68, 0x91, 0x42, + 0x04, 0xdb, 0x5a, 0x68, 0x98, 0x68, 0x80, 0x1a, 0xff, 0x30, 0x70, 0x47, + 0x98, 0x68, 0x5b, 0x68, 0xc0, 0x1a, 0x01, 0x38, 0xf9, 0xe7, 0x10, 0xb5, + 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0xeb, 0xff, 0x10, 0xbd, 0x10, 0xb5, + 0x04, 0x00, 0x00, 0x69, 0xff, 0xf7, 0x9f, 0xfd, 0x00, 0x28, 0x05, 0xd0, + 0x20, 0x69, 0xff, 0xf7, 0xaa, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x9c, 0xfd, + 0x20, 0x69, 0xff, 0xf7, 0x84, 0xfd, 0x00, 0x28, 0x20, 0xd0, 0x20, 0x69, + 0xff, 0xf7, 0x9f, 0xfd, 0x22, 0x00, 0xfc, 0x32, 0x93, 0x69, 0xd1, 0x69, + 0x01, 0x33, 0xdb, 0xb2, 0x8b, 0x42, 0x03, 0xd0, 0x91, 0x69, 0x61, 0x18, + 0x08, 0x75, 0x93, 0x61, 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, + 0x0c, 0xd0, 0x20, 0x00, 0x14, 0x30, 0xff, 0xf7, 0xc0, 0xff, 0x09, 0x28, + 0x06, 0xdc, 0x8b, 0x23, 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, + 0xa2, 0x58, 0x1a, 0x60, 0x20, 0x69, 0xff, 0xf7, 0x79, 0xfd, 0x00, 0x28, + 0x1a, 0xd0, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0x92, 0xff, + 0x00, 0x28, 0x22, 0xd0, 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x99, 0x68, + 0x5a, 0x68, 0x91, 0x42, 0x18, 0xd0, 0x8e, 0x21, 0x9a, 0x68, 0x49, 0x00, + 0xa2, 0x18, 0x51, 0x5c, 0x9a, 0x68, 0x01, 0x32, 0xd2, 0xb2, 0x9a, 0x60, + 0xc9, 0xb2, 0x20, 0x69, 0xff, 0xf7, 0x65, 0xfd, 0x20, 0x69, 0xff, 0xf7, + 0x43, 0xfd, 0x00, 0x28, 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x42, 0xfd, + 0x20, 0x69, 0xff, 0xf7, 0x32, 0xfd, 0x10, 0xbd, 0x01, 0x21, 0x49, 0x42, + 0xec, 0xe7, 0x20, 0x69, 0xff, 0xf7, 0x5f, 0xfd, 0xec, 0xe7, 0x00, 0x00, + 0x70, 0xb5, 0x04, 0x00, 0x00, 0x69, 0x0d, 0x00, 0xff, 0xf7, 0x42, 0xfd, + 0x00, 0x28, 0x3e, 0xd1, 0xff, 0x26, 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, + 0x5a, 0x68, 0x99, 0x68, 0x01, 0x32, 0x32, 0x40, 0x8a, 0x42, 0x23, 0xd1, + 0xef, 0xf3, 0x10, 0x83, 0xdb, 0x07, 0x10, 0xd4, 0x1e, 0x4b, 0x5b, 0x68, + 0xdb, 0x05, 0xdb, 0x0d, 0xed, 0xd0, 0x10, 0x3b, 0x5b, 0xb2, 0x00, 0x2b, + 0x10, 0xda, 0x0f, 0x22, 0x13, 0x40, 0x08, 0x3b, 0x9b, 0x08, 0x19, 0x4a, + 0x9b, 0x00, 0x9b, 0x18, 0x1b, 0x68, 0x20, 0x69, 0xff, 0xf7, 0x1e, 0xfd, + 0x00, 0x28, 0xdc, 0xd0, 0x20, 0x00, 0xff, 0xf7, 0x6a, 0xff, 0xd8, 0xe7, + 0x9b, 0x08, 0xc0, 0x33, 0x12, 0x4a, 0x9b, 0x00, 0x9b, 0x58, 0xf0, 0xe7, + 0x5a, 0x68, 0x01, 0x32, 0x16, 0x40, 0x9a, 0x68, 0x96, 0x42, 0x05, 0xd0, + 0x8e, 0x21, 0x5a, 0x68, 0x49, 0x00, 0xa2, 0x18, 0x55, 0x54, 0x5e, 0x60, + 0x20, 0x69, 0xff, 0xf7, 0x14, 0xfd, 0x01, 0x20, 0x70, 0xbd, 0x20, 0x00, + 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0x1c, 0xff, 0x00, 0x28, 0xb9, 0xd1, + 0x29, 0x00, 0x20, 0x69, 0xff, 0xf7, 0xff, 0xfc, 0xf1, 0xe7, 0xc0, 0x46, + 0x00, 0xed, 0x00, 0xe0, 0x1c, 0xed, 0x00, 0xe0, 0x00, 0xe1, 0x00, 0xe0, + 0x03, 0x00, 0x70, 0xb5, 0xfc, 0x33, 0xd9, 0x69, 0x9a, 0x69, 0x04, 0x00, + 0x91, 0x42, 0x1a, 0xd0, 0xda, 0x69, 0x82, 0x18, 0x15, 0x7d, 0xda, 0x69, + 0x01, 0x32, 0xd2, 0xb2, 0xda, 0x61, 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, + 0xff, 0x2b, 0x0c, 0xd0, 0x20, 0x00, 0x14, 0x30, 0xff, 0xf7, 0x11, 0xff, + 0x0a, 0x28, 0x06, 0xdd, 0x8c, 0x23, 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, + 0xe3, 0x58, 0xa2, 0x58, 0x1a, 0x60, 0x28, 0x00, 0x70, 0xbd, 0x01, 0x25, + 0x6d, 0x42, 0xe8, 0xe7, 0xfe, 0xe7, 0x00, 0x00, 0x03, 0x4b, 0x10, 0xb5, + 0x1b, 0x68, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, 0x10, 0xbd, 0xc0, 0x46, + 0xb0, 0x10, 0x00, 0x20, 0x70, 0xb5, 0x0f, 0x49, 0x0f, 0x4c, 0xa1, 0x42, + 0x04, 0xd1, 0x00, 0xf0, 0x81, 0xf8, 0xfa, 0xf7, 0x25, 0xfe, 0xfe, 0xe7, + 0x0c, 0x4d, 0x00, 0x23, 0x8d, 0x42, 0xf6, 0xd0, 0xca, 0x18, 0xe8, 0x18, + 0xa2, 0x42, 0x05, 0xd3, 0x09, 0x4b, 0x82, 0x42, 0xef, 0xd0, 0x09, 0x49, + 0x00, 0x22, 0x04, 0xe0, 0x00, 0x68, 0x04, 0x33, 0x10, 0x60, 0xf1, 0xe7, + 0x04, 0xc3, 0x8b, 0x42, 0xfc, 0xd3, 0xe4, 0xe7, 0x00, 0x00, 0x00, 0x20, + 0x30, 0x00, 0x00, 0x20, 0xb8, 0x85, 0x00, 0x00, 0x30, 0x00, 0x00, 0x20, + 0xb8, 0x10, 0x00, 0x20, 0x10, 0xb5, 0x00, 0xf0, 0x58, 0xf8, 0x00, 0x28, + 0x01, 0xd1, 0x00, 0xf0, 0x49, 0xf8, 0x10, 0xbd, 0xf7, 0xb5, 0x13, 0x48, + 0x01, 0x22, 0x84, 0x46, 0x12, 0x49, 0x13, 0x4c, 0x8e, 0x68, 0x63, 0x68, + 0x05, 0x68, 0x9b, 0x0e, 0x13, 0x40, 0x01, 0x92, 0x88, 0x68, 0x62, 0x68, + 0x01, 0x9f, 0x92, 0x0e, 0x3a, 0x40, 0x67, 0x46, 0x3f, 0x68, 0x93, 0x42, + 0x0e, 0xd1, 0xbd, 0x42, 0x0c, 0xd1, 0x86, 0x42, 0x0a, 0xd3, 0x5b, 0x19, + 0xfa, 0x25, 0x48, 0x68, 0xad, 0x00, 0x86, 0x1b, 0x07, 0x48, 0x6b, 0x43, + 0x70, 0x43, 0x00, 0x0d, 0xc0, 0x18, 0xfe, 0xbd, 0x3d, 0x00, 0x13, 0x00, + 0x06, 0x00, 0xe3, 0xe7, 0xb4, 0x10, 0x00, 0x20, 0x10, 0xe0, 0x00, 0xe0, + 0x00, 0xed, 0x00, 0xe0, 0x55, 0x55, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x1e, + 0x10, 0xd0, 0xff, 0xf7, 0xcb, 0xff, 0x05, 0x00, 0x00, 0xf0, 0x1a, 0xf8, + 0xff, 0xf7, 0xc6, 0xff, 0x05, 0x4b, 0x40, 0x1b, 0x98, 0x42, 0xf7, 0xd9, + 0xfa, 0x23, 0x01, 0x3c, 0x9b, 0x00, 0xed, 0x18, 0x00, 0x2c, 0xf3, 0xd1, + 0x70, 0xbd, 0xc0, 0x46, 0xe7, 0x03, 0x00, 0x00, 0x10, 0xb5, 0x03, 0x4a, + 0x13, 0x68, 0x01, 0x33, 0x13, 0x60, 0x00, 0xf0, 0x4d, 0xfa, 0x10, 0xbd, + 0xb4, 0x10, 0x00, 0x20, 0x70, 0x47, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, + 0x1e, 0x22, 0x70, 0xb5, 0x46, 0x48, 0x47, 0x49, 0x43, 0x68, 0x93, 0x43, + 0x1c, 0x3a, 0x13, 0x43, 0x43, 0x60, 0x08, 0x23, 0x8c, 0x69, 0x23, 0x43, + 0x8b, 0x61, 0x43, 0x4c, 0x43, 0x4b, 0x9c, 0x82, 0x9c, 0x8a, 0x14, 0x43, + 0x9c, 0x82, 0xdc, 0x68, 0x14, 0x42, 0xfc, 0xd0, 0x01, 0x24, 0x40, 0x4a, + 0x14, 0x70, 0x15, 0x78, 0x25, 0x42, 0x03, 0xd0, 0x55, 0x78, 0x6d, 0xb2, + 0x00, 0x2d, 0xf8, 0xdb, 0x01, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, + 0x00, 0x2c, 0xfb, 0xdb, 0x39, 0x4c, 0x54, 0x60, 0x54, 0x78, 0x64, 0xb2, + 0x00, 0x2c, 0xfb, 0xdb, 0x82, 0x24, 0xe4, 0x01, 0x54, 0x80, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x02, 0x24, 0x9c, 0x84, 0x0e, 0x34, + 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x31, 0x4c, 0xdc, 0x62, 0x10, 0x24, + 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x9d, 0x8c, 0x2e, 0x4c, 0x2c, 0x43, + 0x9c, 0x84, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x02, 0x24, + 0x9d, 0x8c, 0x80, 0x26, 0x2c, 0x43, 0x9c, 0x84, 0x40, 0x24, 0xdd, 0x68, + 0x35, 0x42, 0xfc, 0xd0, 0xdd, 0x68, 0x25, 0x42, 0xf9, 0xd0, 0x10, 0x24, + 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x00, 0x24, 0x94, 0x60, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x21, 0x4c, 0x54, 0x60, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x1c, 0x6a, 0x1e, 0x4d, 0x2c, 0x40, + 0x80, 0x25, 0x1c, 0x62, 0x1c, 0x6a, 0xac, 0x43, 0x1c, 0x62, 0x03, 0x23, + 0x93, 0x60, 0x1b, 0x4b, 0x53, 0x60, 0x53, 0x78, 0x5b, 0xb2, 0x00, 0x2b, + 0xfb, 0xdb, 0x00, 0x23, 0xff, 0x24, 0x0b, 0x72, 0x17, 0x4a, 0x4b, 0x72, + 0x8b, 0x72, 0xcb, 0x72, 0x16, 0x4b, 0x1a, 0x60, 0x16, 0x4b, 0x17, 0x4a, + 0x1b, 0x68, 0x11, 0x68, 0x9a, 0x06, 0x5b, 0x01, 0xc9, 0x0e, 0x23, 0x40, + 0x52, 0x0f, 0x12, 0x02, 0x0b, 0x43, 0x13, 0x43, 0x12, 0x4a, 0x13, 0x85, + 0x80, 0x23, 0x42, 0x68, 0x13, 0x43, 0x43, 0x60, 0x70, 0xbd, 0xc0, 0x46, + 0x00, 0x40, 0x00, 0x41, 0x00, 0x04, 0x00, 0x40, 0x0c, 0x06, 0x00, 0x00, + 0x00, 0x08, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, 0x01, 0x05, 0x01, 0x00, + 0xb9, 0x05, 0xff, 0x7d, 0x04, 0x0a, 0x00, 0x00, 0x00, 0x07, 0x03, 0x00, + 0xff, 0xfc, 0xff, 0xff, 0x03, 0x06, 0x01, 0x00, 0x00, 0x6c, 0xdc, 0x02, + 0x00, 0x00, 0x00, 0x20, 0x24, 0x60, 0x80, 0x00, 0x20, 0x60, 0x80, 0x00, + 0x00, 0x40, 0x00, 0x42, 0xfa, 0x21, 0x31, 0x4b, 0x10, 0xb5, 0x18, 0x68, + 0x89, 0x00, 0x00, 0xf0, 0xd5, 0xf9, 0x2f, 0x4b, 0x01, 0x38, 0x98, 0x42, + 0x56, 0xd8, 0x2e, 0x49, 0x2e, 0x4a, 0x48, 0x60, 0xc0, 0x20, 0x13, 0x6a, + 0x00, 0x06, 0x1b, 0x02, 0x1b, 0x0a, 0x03, 0x43, 0x13, 0x62, 0x00, 0x24, + 0x07, 0x23, 0x8c, 0x60, 0x0b, 0x60, 0x80, 0x21, 0x13, 0x6a, 0x09, 0x06, + 0x1b, 0x02, 0x1b, 0x0a, 0x0b, 0x43, 0x13, 0x62, 0xfc, 0x22, 0x25, 0x4b, + 0x19, 0x6a, 0x0a, 0x43, 0x1a, 0x62, 0xfc, 0x22, 0x19, 0x6a, 0x92, 0x01, + 0x0a, 0x43, 0x1a, 0x62, 0xa0, 0x22, 0x19, 0x6a, 0xd2, 0x02, 0x0a, 0x43, + 0x1a, 0x62, 0x20, 0x00, 0x00, 0x21, 0x01, 0x34, 0x00, 0xf0, 0x76, 0xf8, + 0x0f, 0x2c, 0xf8, 0xd1, 0x1b, 0x4b, 0x1c, 0x00, 0x5a, 0x78, 0x52, 0xb2, + 0x00, 0x2a, 0xfb, 0xdb, 0x19, 0x4a, 0x5a, 0x80, 0x19, 0x4b, 0x1a, 0x00, + 0x59, 0x7e, 0xc9, 0x09, 0x01, 0x29, 0xfb, 0xd0, 0xe4, 0x21, 0xc9, 0x00, + 0x99, 0x80, 0x3f, 0x21, 0xd9, 0x70, 0x53, 0x7e, 0xdb, 0x09, 0x01, 0x2b, + 0xfb, 0xd0, 0xc0, 0x23, 0x00, 0x20, 0x5b, 0x01, 0x13, 0x61, 0x90, 0x70, + 0x00, 0xf0, 0x24, 0xf8, 0x63, 0x78, 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, + 0x0d, 0x4b, 0x0e, 0x4a, 0x63, 0x80, 0xd3, 0x79, 0xdb, 0x09, 0x01, 0x2b, + 0xfb, 0xd0, 0x41, 0x23, 0x53, 0x70, 0x10, 0xbd, 0xfe, 0xe7, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x20, 0xff, 0xff, 0xff, 0x00, 0x10, 0xe0, 0x00, 0xe0, + 0x00, 0xed, 0x00, 0xe0, 0x00, 0x04, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, + 0x1e, 0x40, 0x00, 0x00, 0x00, 0x40, 0x00, 0x42, 0x21, 0x40, 0x00, 0x00, + 0x00, 0x48, 0x00, 0x42, 0x16, 0x4a, 0x00, 0xb5, 0x13, 0x00, 0x51, 0x7e, + 0xc9, 0x09, 0x01, 0x29, 0xfb, 0xd0, 0x01, 0x38, 0x04, 0x28, 0x16, 0xd8, + 0x19, 0x69, 0x12, 0x4a, 0x0a, 0x40, 0x0f, 0x21, 0x1a, 0x61, 0x5a, 0x78, + 0x8a, 0x43, 0x00, 0xf0, 0x47, 0xf9, 0x03, 0x08, 0x06, 0x0b, 0x03, 0x00, + 0x11, 0x00, 0x01, 0x22, 0x0a, 0x43, 0x5a, 0x70, 0x00, 0xbd, 0x11, 0x00, + 0x03, 0x22, 0xf9, 0xe7, 0x11, 0x00, 0x02, 0x22, 0xf6, 0xe7, 0xf0, 0x23, + 0x11, 0x69, 0x1b, 0x05, 0x0b, 0x43, 0x0f, 0x21, 0x13, 0x61, 0x53, 0x78, + 0x8b, 0x43, 0x19, 0x00, 0x02, 0x23, 0x0b, 0x43, 0x53, 0x70, 0xeb, 0xe7, + 0x00, 0x40, 0x00, 0x42, 0xff, 0xff, 0xff, 0xf0, 0x18, 0x23, 0x30, 0xb5, + 0x1d, 0x00, 0x04, 0x00, 0x45, 0x43, 0x08, 0x20, 0x20, 0x4a, 0x55, 0x19, + 0x28, 0x56, 0x01, 0x30, 0x14, 0xd0, 0x03, 0x29, 0x12, 0xd8, 0x08, 0x00, + 0x63, 0x43, 0xd1, 0x56, 0xd3, 0x18, 0x00, 0xf0, 0x15, 0xf9, 0x02, 0x28, + 0x0e, 0x1b, 0x58, 0x68, 0xcb, 0x01, 0x02, 0x21, 0x18, 0x4a, 0x9b, 0x18, + 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, + 0x30, 0xbd, 0x58, 0x68, 0xcb, 0x01, 0x06, 0x21, 0x12, 0x4a, 0x9b, 0x18, + 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, + 0x9a, 0x61, 0xf1, 0xe7, 0x58, 0x68, 0xcb, 0x01, 0x06, 0x21, 0x0c, 0x4a, + 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, + 0x5a, 0x60, 0x5a, 0x61, 0xe4, 0xe7, 0x58, 0x68, 0xcb, 0x01, 0x02, 0x21, + 0x05, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, + 0x82, 0x40, 0x9a, 0x60, 0xd8, 0xe7, 0xc0, 0x46, 0x20, 0x82, 0x00, 0x00, + 0x00, 0x44, 0x00, 0x41, 0x18, 0x23, 0xf0, 0xb5, 0x08, 0x24, 0x58, 0x43, + 0x11, 0x4a, 0x13, 0x18, 0x1c, 0x57, 0x01, 0x34, 0x1b, 0xd0, 0x01, 0x26, + 0x35, 0x00, 0x5f, 0x68, 0x83, 0x56, 0xbd, 0x40, 0x0d, 0x4a, 0xdb, 0x01, + 0x9a, 0x18, 0x90, 0x68, 0x05, 0x42, 0x0b, 0xd1, 0x0c, 0x00, 0x60, 0x1e, + 0x84, 0x41, 0xd2, 0x19, 0x40, 0x32, 0x10, 0x78, 0x34, 0x40, 0x03, 0x36, + 0xa4, 0x00, 0xb0, 0x43, 0x20, 0x43, 0x10, 0x70, 0x04, 0x4a, 0x9b, 0x18, + 0x00, 0x29, 0x01, 0xd1, 0x5d, 0x61, 0xf0, 0xbd, 0x9d, 0x61, 0xfc, 0xe7, + 0x20, 0x82, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0x18, 0x22, 0x42, 0x43, + 0xf8, 0xb5, 0x2c, 0x4e, 0x03, 0x00, 0xb2, 0x18, 0x12, 0x7a, 0x52, 0xb2, + 0x14, 0x00, 0x01, 0x32, 0x0e, 0xd0, 0x48, 0x1c, 0x00, 0x24, 0x0c, 0x28, + 0x0a, 0xd8, 0x00, 0xf0, 0x9f, 0xf8, 0x07, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, + 0x1f, 0x1f, 0x1f, 0x0b, 0x0b, 0x0b, 0x0b, 0x00, 0x01, 0x24, 0x64, 0x42, + 0x20, 0x00, 0xf8, 0xbd, 0x09, 0x29, 0x05, 0xd1, 0x00, 0x21, 0x18, 0x00, + 0xff, 0xf7, 0x66, 0xff, 0x00, 0x24, 0xf5, 0xe7, 0x0a, 0x29, 0x01, 0xd1, + 0x08, 0x39, 0xf6, 0xe7, 0x00, 0x24, 0x0b, 0x29, 0xee, 0xd1, 0x0a, 0x39, + 0x18, 0x00, 0xff, 0xf7, 0x59, 0xff, 0xe9, 0xe7, 0x18, 0x22, 0x53, 0x43, + 0xf2, 0x18, 0x55, 0x68, 0x01, 0x20, 0x2c, 0x00, 0xf3, 0x56, 0x13, 0x4a, + 0xdb, 0x01, 0x6e, 0x08, 0x9b, 0x18, 0xc9, 0xb2, 0x04, 0x40, 0x9e, 0x19, + 0x00, 0x2c, 0x0d, 0xd0, 0x0f, 0x24, 0x30, 0x36, 0x32, 0x78, 0x09, 0x01, + 0x22, 0x40, 0x11, 0x43, 0xc9, 0xb2, 0x5b, 0x19, 0x31, 0x70, 0x40, 0x33, + 0x1a, 0x78, 0x10, 0x43, 0x18, 0x70, 0xd3, 0xe7, 0x32, 0x00, 0x0f, 0x27, + 0x30, 0x32, 0x16, 0x78, 0x5b, 0x19, 0xbe, 0x43, 0x31, 0x43, 0x11, 0x70, + 0x40, 0x33, 0x1a, 0x78, 0x10, 0x43, 0x18, 0x70, 0xbe, 0xe7, 0xc0, 0x46, + 0x20, 0x82, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0xf7, 0xb5, 0x06, 0x00, + 0x0d, 0x00, 0x0c, 0x00, 0x8b, 0x18, 0x01, 0x93, 0x01, 0x9b, 0x67, 0x1b, + 0x9c, 0x42, 0x07, 0xd0, 0x33, 0x68, 0x21, 0x78, 0x1b, 0x68, 0x30, 0x00, + 0x98, 0x47, 0x01, 0x34, 0x00, 0x28, 0xf3, 0xd1, 0x38, 0x00, 0xfe, 0xbd, + 0x16, 0x4a, 0x10, 0xb5, 0x13, 0x68, 0x59, 0x1c, 0x26, 0xd0, 0x01, 0x3b, + 0x13, 0x60, 0x00, 0x2b, 0x22, 0xd1, 0x72, 0xb6, 0x12, 0x4b, 0x13, 0x4a, + 0x04, 0x33, 0x93, 0x42, 0x13, 0xd9, 0x12, 0x4a, 0x01, 0x21, 0x10, 0x00, + 0x14, 0x7d, 0x0c, 0x42, 0xfc, 0xd0, 0x20, 0x21, 0x14, 0x8b, 0xff, 0x31, + 0x9b, 0x08, 0x5b, 0x00, 0x21, 0x43, 0x11, 0x83, 0xd3, 0x61, 0x0c, 0x4b, + 0x13, 0x80, 0x01, 0x23, 0x02, 0x7d, 0x1a, 0x42, 0xfc, 0xd0, 0xbf, 0xf3, + 0x4f, 0x8f, 0x09, 0x4b, 0x09, 0x4a, 0xda, 0x60, 0xbf, 0xf3, 0x4f, 0x8f, + 0xc0, 0x46, 0xfd, 0xe7, 0x10, 0xbd, 0xc0, 0x46, 0x04, 0x00, 0x00, 0x20, + 0x00, 0x20, 0x00, 0x00, 0x03, 0x02, 0x00, 0x00, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x00, 0xed, 0x00, 0xe0, 0x04, 0x00, 0xfa, 0x05, + 0x02, 0xb4, 0x71, 0x46, 0x49, 0x08, 0x49, 0x00, 0x09, 0x5c, 0x49, 0x00, + 0x8e, 0x44, 0x02, 0xbc, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x22, 0x43, 0x08, + 0x8b, 0x42, 0x74, 0xd3, 0x03, 0x09, 0x8b, 0x42, 0x5f, 0xd3, 0x03, 0x0a, + 0x8b, 0x42, 0x44, 0xd3, 0x03, 0x0b, 0x8b, 0x42, 0x28, 0xd3, 0x03, 0x0c, + 0x8b, 0x42, 0x0d, 0xd3, 0xff, 0x22, 0x09, 0x02, 0x12, 0xba, 0x03, 0x0c, + 0x8b, 0x42, 0x02, 0xd3, 0x12, 0x12, 0x09, 0x02, 0x65, 0xd0, 0x03, 0x0b, + 0x8b, 0x42, 0x19, 0xd3, 0x00, 0xe0, 0x09, 0x0a, 0xc3, 0x0b, 0x8b, 0x42, + 0x01, 0xd3, 0xcb, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0b, 0x8b, 0x42, + 0x01, 0xd3, 0x8b, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0b, 0x8b, 0x42, + 0x01, 0xd3, 0x4b, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0b, 0x8b, 0x42, + 0x01, 0xd3, 0x0b, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x0a, 0x8b, 0x42, + 0x01, 0xd3, 0xcb, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0a, 0x8b, 0x42, + 0x01, 0xd3, 0x8b, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0a, 0x8b, 0x42, + 0x01, 0xd3, 0x4b, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0a, 0x8b, 0x42, + 0x01, 0xd3, 0x0b, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0xcd, 0xd2, 0xc3, 0x09, + 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x09, + 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x09, + 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x09, + 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x08, + 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x08, + 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x08, + 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x41, 0x1a, + 0x00, 0xd2, 0x01, 0x46, 0x52, 0x41, 0x10, 0x46, 0x70, 0x47, 0xff, 0xe7, + 0x01, 0xb5, 0x00, 0x20, 0x00, 0xf0, 0x06, 0xf8, 0x02, 0xbd, 0xc0, 0x46, + 0x00, 0x29, 0xf7, 0xd0, 0x76, 0xe7, 0x70, 0x47, 0x70, 0x47, 0xc0, 0x46, + 0x70, 0xb5, 0x00, 0x26, 0x0c, 0x4d, 0x0d, 0x4c, 0x64, 0x1b, 0xa4, 0x10, + 0xa6, 0x42, 0x09, 0xd1, 0x00, 0x26, 0x00, 0xf0, 0x4f, 0xf8, 0x0a, 0x4d, + 0x0a, 0x4c, 0x64, 0x1b, 0xa4, 0x10, 0xa6, 0x42, 0x05, 0xd1, 0x70, 0xbd, + 0xb3, 0x00, 0xeb, 0x58, 0x98, 0x47, 0x01, 0x36, 0xee, 0xe7, 0xb3, 0x00, + 0xeb, 0x58, 0x98, 0x47, 0x01, 0x36, 0xf2, 0xe7, 0x08, 0x00, 0x00, 0x20, + 0x08, 0x00, 0x00, 0x20, 0x08, 0x00, 0x00, 0x20, 0x24, 0x00, 0x00, 0x20, + 0x00, 0x23, 0x10, 0xb5, 0x9a, 0x42, 0x00, 0xd1, 0x10, 0xbd, 0xcc, 0x5c, + 0xc4, 0x54, 0x01, 0x33, 0xf8, 0xe7, 0x03, 0x00, 0x12, 0x18, 0x93, 0x42, + 0x00, 0xd1, 0x70, 0x47, 0x19, 0x70, 0x01, 0x33, 0xf9, 0xe7, 0x02, 0x78, + 0x0b, 0x78, 0x00, 0x2a, 0x03, 0xd0, 0x01, 0x30, 0x01, 0x31, 0x9a, 0x42, + 0xf7, 0xd0, 0xd0, 0x1a, 0x70, 0x47, 0x00, 0x23, 0xc2, 0x5c, 0x01, 0x33, + 0x00, 0x2a, 0xfb, 0xd1, 0x58, 0x1e, 0x70, 0x47, 0x30, 0xb5, 0x05, 0x00, + 0x00, 0x2a, 0x00, 0xd1, 0x30, 0xbd, 0x0c, 0x78, 0x01, 0x3a, 0x6b, 0x1c, + 0x2c, 0x70, 0x01, 0x31, 0x00, 0x2c, 0x05, 0xd1, 0x9a, 0x18, 0x9a, 0x42, + 0xf4, 0xd0, 0x1c, 0x70, 0x01, 0x33, 0xfa, 0xe7, 0x1d, 0x00, 0xed, 0xe7, + 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, + 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, + 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x2e, 0x42, 0x49, 0x4e, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x10, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, + 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, + 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x04, + 0x00, 0x04, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x01, + 0x00, 0x01, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x13, 0x00, 0x01, 0x01, + 0x01, 0x01, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x05, + 0x00, 0x05, 0x0a, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x05, + 0x01, 0x05, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x02, 0x00, + 0x02, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, + 0x03, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x02, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x03, + 0x01, 0x03, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x10, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x11, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0a, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0b, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x05, 0x00, 0x01, 0x00, + 0x01, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x06, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x07, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x0f, 0x00, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x02, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x03, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x89, 0x73, 0x00, 0x00, 0x15, 0x7a, 0x00, 0x00, 0xaf, 0x72, 0x00, 0x00, + 0x6b, 0x72, 0x00, 0x00, 0x85, 0x72, 0x00, 0x00, 0x3d, 0x74, 0x00, 0x00, + 0x4d, 0x70, 0x00, 0x00, 0x3d, 0x70, 0x00, 0x00, 0xd1, 0x70, 0x00, 0x00, + 0x67, 0x70, 0x00, 0x00, 0x37, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x40, 0x42, 0x0f, 0x00, 0xff, 0xff, 0xff, 0xff, 0xdd, 0x20, 0x00, 0x00, + 0x25, 0x22, 0x00, 0x00, 0x39, 0x22, 0x00, 0x00, 0xa5, 0x23, 0x00, 0x00, + 0x3d, 0x26, 0x00, 0x00, 0x41, 0x6c, 0x00, 0x00, 0xa1, 0x6c, 0x00, 0x00, + 0xb5, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 diff --git a/libraries/SFU/src/boot/mkrvidor4000.h b/libraries/SFU/src/boot/mkrvidor4000.h new file mode 100644 index 0000000..d18b229 --- /dev/null +++ b/libraries/SFU/src/boot/mkrvidor4000.h @@ -0,0 +1,2174 @@ + 0x00, 0x80, 0x00, 0x20, 0x9d, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0xf1, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0xa5, 0x6c, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0x30, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xb4, 0x85, 0x00, 0x00, 0x04, 0x4b, 0x10, 0xb5, 0x00, 0x2b, 0x03, 0xd0, + 0x03, 0x49, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x10, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x00, 0x34, 0x00, 0x00, 0x20, 0xb4, 0x85, 0x00, 0x00, + 0xf0, 0xb5, 0x40, 0x4c, 0xa5, 0x44, 0x00, 0xaf, 0x05, 0xf0, 0x02, 0xfb, + 0x05, 0xf0, 0x68, 0xfd, 0x01, 0x20, 0x05, 0xf0, 0x27, 0xfa, 0x3c, 0x48, + 0x00, 0xf0, 0x8c, 0xf9, 0x3b, 0x4c, 0x20, 0x00, 0x00, 0xf0, 0x1c, 0xf9, + 0x00, 0x28, 0x5d, 0xd1, 0x20, 0x00, 0x02, 0xf0, 0x29, 0xfb, 0x00, 0x28, + 0x58, 0xd1, 0x20, 0x00, 0x02, 0xf0, 0x44, 0xf9, 0x0c, 0x20, 0x08, 0x23, + 0x34, 0x4a, 0x21, 0x00, 0x38, 0x18, 0x00, 0xf0, 0x23, 0xf9, 0x20, 0x00, + 0x02, 0xf0, 0x38, 0xf9, 0x05, 0x1e, 0x45, 0xd1, 0x0c, 0x23, 0x01, 0x00, + 0x02, 0x22, 0xf8, 0x18, 0x00, 0xf0, 0x42, 0xf9, 0x80, 0x21, 0x78, 0x60, + 0x09, 0x02, 0x2e, 0x00, 0x88, 0x42, 0x2c, 0xdd, 0x0c, 0x23, 0x2a, 0x00, + 0xf8, 0x18, 0x00, 0xf0, 0x37, 0xf9, 0x28, 0x4a, 0xa0, 0x21, 0x94, 0x46, + 0x7b, 0x68, 0x09, 0x02, 0x63, 0x44, 0x1a, 0x00, 0x25, 0x48, 0xa0, 0x25, + 0x80, 0x26, 0x7b, 0x60, 0x00, 0xf0, 0xd6, 0xf8, 0x2d, 0x02, 0xb6, 0x00, + 0x08, 0x23, 0xf8, 0x18, 0xc1, 0x18, 0x04, 0x33, 0x32, 0x00, 0xf8, 0x18, + 0x00, 0xf0, 0x14, 0xf9, 0x08, 0x22, 0xb9, 0x18, 0x8a, 0x18, 0x33, 0x00, + 0x29, 0x00, 0x1b, 0x48, 0x00, 0xf0, 0x74, 0xf8, 0x80, 0x22, 0x1a, 0x4b, + 0x92, 0x00, 0xeb, 0x18, 0xad, 0x18, 0x7a, 0x68, 0x93, 0x42, 0xe7, 0xdb, + 0x01, 0x26, 0x0c, 0x23, 0xf8, 0x18, 0x00, 0xf0, 0x17, 0xf9, 0x00, 0x2e, + 0x03, 0xd0, 0x10, 0x49, 0x20, 0x00, 0x02, 0xf0, 0x55, 0xfa, 0x20, 0x00, + 0x02, 0xf0, 0xca, 0xf8, 0x0c, 0x23, 0xf8, 0x18, 0x00, 0xf0, 0x14, 0xf9, + 0xa0, 0x23, 0x1b, 0x02, 0x1a, 0x68, 0x82, 0xf3, 0x08, 0x88, 0x0c, 0x4a, + 0x93, 0x60, 0x0c, 0x4b, 0x1b, 0x68, 0x18, 0x47, 0x00, 0x20, 0xbd, 0x46, + 0x85, 0x23, 0x9b, 0x00, 0x9d, 0x44, 0xf0, 0xbd, 0xec, 0xfd, 0xff, 0xff, + 0xf4, 0x0b, 0x00, 0x20, 0x8c, 0x04, 0x00, 0x20, 0xa8, 0x7c, 0x00, 0x00, + 0x00, 0x80, 0xff, 0xff, 0x4c, 0x00, 0x00, 0x20, 0x00, 0x62, 0xff, 0xff, + 0x00, 0xed, 0x00, 0xe0, 0x04, 0xa0, 0x00, 0x00, 0x00, 0x22, 0x10, 0xb5, + 0x11, 0x00, 0x02, 0x48, 0x00, 0xf0, 0x1a, 0xf8, 0x10, 0xbd, 0xc0, 0x46, + 0x4c, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x05, 0x4a, 0x05, 0x49, 0x06, 0x48, + 0x00, 0xf0, 0x10, 0xf8, 0x00, 0x22, 0x05, 0x4b, 0x05, 0x49, 0x1a, 0x70, + 0x5a, 0x54, 0x10, 0xbd, 0x01, 0x04, 0x00, 0x00, 0x00, 0x7d, 0x00, 0x00, + 0x68, 0x04, 0x00, 0x20, 0x64, 0x00, 0x00, 0x20, 0x02, 0x04, 0x00, 0x00, + 0x30, 0xb5, 0x09, 0x4d, 0x09, 0x4c, 0xab, 0x68, 0x5b, 0x03, 0x5b, 0x0f, + 0x9b, 0x00, 0x1c, 0x59, 0x04, 0x60, 0xab, 0x68, 0x01, 0x61, 0x9b, 0xb2, + 0x43, 0x60, 0x63, 0x43, 0xa4, 0x00, 0x83, 0x60, 0xc4, 0x60, 0x42, 0x61, + 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, 0x00, 0x82, 0x00, 0x00, + 0xf7, 0xb5, 0x80, 0x26, 0x1a, 0x4d, 0x01, 0x91, 0x6f, 0x68, 0x03, 0x33, + 0x3e, 0x43, 0x9b, 0x08, 0x6e, 0x60, 0x00, 0x2b, 0x2b, 0xd0, 0x17, 0x4e, + 0x2e, 0x80, 0x2e, 0x7d, 0xf1, 0x07, 0xfc, 0xd5, 0x1e, 0x00, 0x07, 0x68, + 0x99, 0x1b, 0xbf, 0x08, 0x8f, 0x42, 0x19, 0xd9, 0x00, 0x2e, 0x17, 0xd0, + 0xff, 0x21, 0x17, 0x78, 0x8c, 0x43, 0x3c, 0x43, 0x0f, 0x49, 0x57, 0x78, + 0x0c, 0x40, 0x3f, 0x02, 0x3c, 0x43, 0x97, 0x78, 0x01, 0x3e, 0x39, 0x04, + 0x0c, 0x4f, 0x27, 0x40, 0xd4, 0x78, 0xbf, 0xb2, 0x0f, 0x43, 0x24, 0x06, + 0x01, 0x99, 0x3c, 0x43, 0x10, 0xc1, 0x01, 0x91, 0x04, 0x32, 0xe0, 0xe7, + 0x07, 0x4b, 0x2b, 0x80, 0x2b, 0x7d, 0xdb, 0x07, 0xfc, 0xd5, 0x33, 0x00, + 0xd1, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x44, 0xa5, 0xff, 0xff, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, 0x04, 0xa5, 0xff, 0xff, + 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, 0x1a, 0x80, 0x1a, 0x7d, + 0xd2, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x16, 0x00, + 0xe3, 0x68, 0x29, 0x00, 0x20, 0x00, 0xb3, 0x42, 0x05, 0xd2, 0xff, 0xf7, + 0xe7, 0xff, 0xe3, 0x68, 0xed, 0x18, 0xf6, 0x1a, 0xf4, 0xe7, 0xff, 0xf7, + 0xe1, 0xff, 0x70, 0xbd, 0x1f, 0xb5, 0x00, 0x21, 0x03, 0x91, 0x90, 0x21, + 0xc9, 0x00, 0x02, 0x91, 0xa1, 0x39, 0xff, 0x39, 0x41, 0x18, 0x98, 0x23, + 0x01, 0x91, 0x02, 0x00, 0x80, 0x21, 0x9b, 0x00, 0x00, 0x91, 0xc3, 0x18, + 0x60, 0x32, 0x02, 0x49, 0x01, 0xf0, 0x9c, 0xff, 0x05, 0xb0, 0x00, 0xbd, + 0x80, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, 0x08, 0x00, 0x11, 0x00, + 0x1a, 0x00, 0x00, 0x23, 0x02, 0xf0, 0x16, 0xf8, 0x01, 0x00, 0x20, 0x00, + 0x00, 0xf0, 0x3a, 0xf8, 0x20, 0x00, 0x10, 0xbd, 0x03, 0x4b, 0x04, 0x4a, + 0x1a, 0x60, 0x04, 0x4a, 0x5a, 0x60, 0x04, 0x4a, 0x9a, 0x60, 0x70, 0x47, + 0x80, 0x04, 0x00, 0x20, 0x01, 0x26, 0x00, 0x00, 0x15, 0x26, 0x00, 0x00, + 0x29, 0x26, 0x00, 0x00, 0x10, 0xb5, 0x0c, 0x00, 0x13, 0x00, 0x00, 0x22, + 0x81, 0x5e, 0x22, 0x00, 0x01, 0x48, 0x02, 0xf0, 0x87, 0xf8, 0x10, 0xbd, + 0x8c, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x0c, 0x00, 0x13, 0x00, 0x00, 0x22, + 0x81, 0x5e, 0x22, 0x00, 0x01, 0x48, 0x02, 0xf0, 0xdd, 0xf8, 0x10, 0xbd, + 0x8c, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x00, 0x23, 0xc1, 0x5e, 0x02, 0x48, + 0x02, 0xf0, 0x9c, 0xf9, 0x10, 0xbd, 0xc0, 0x46, 0x8c, 0x04, 0x00, 0x20, + 0x10, 0xb5, 0x04, 0x00, 0xff, 0xf7, 0xf2, 0xff, 0x20, 0x00, 0x10, 0xbd, + 0x01, 0x80, 0x70, 0x47, 0x10, 0xb5, 0x00, 0x21, 0x40, 0x68, 0x05, 0xf0, + 0x6b, 0xfa, 0x10, 0xbd, 0x10, 0xb5, 0x01, 0x21, 0x40, 0x68, 0x05, 0xf0, + 0x65, 0xfa, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x68, 0x04, 0xf0, + 0xb9, 0xfb, 0x01, 0x21, 0x60, 0x68, 0x05, 0xf0, 0x0f, 0xfa, 0x20, 0x00, + 0xff, 0xf7, 0xee, 0xff, 0x10, 0xbd, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x00, + 0xff, 0xf7, 0xe2, 0xff, 0x09, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, + 0xcf, 0xfb, 0x05, 0x21, 0x20, 0x68, 0x04, 0xf0, 0xe7, 0xfb, 0x00, 0x21, + 0x20, 0x68, 0x04, 0xf0, 0xe3, 0xfb, 0x05, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0xd7, 0xff, 0x28, 0x00, 0x70, 0xbd, 0xc0, 0x46, 0xec, 0x0b, 0x00, 0x20, + 0x10, 0xb5, 0xff, 0xf7, 0xe3, 0xff, 0x01, 0x23, 0x18, 0x40, 0x10, 0xbd, + 0xf7, 0xb5, 0x04, 0x00, 0x0e, 0x00, 0x15, 0x00, 0x10, 0x27, 0x01, 0x93, + 0x20, 0x00, 0xff, 0xf7, 0xf1, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x3b, 0x00, + 0x01, 0x3b, 0xfd, 0xd1, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xb4, 0xff, + 0x12, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, 0xa1, 0xfb, 0x03, 0x21, + 0x20, 0x68, 0x04, 0xf0, 0xb9, 0xfb, 0x31, 0x0c, 0xc9, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0xb4, 0xfb, 0x31, 0x0a, 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, + 0xaf, 0xfb, 0xf1, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0xab, 0xfb, 0x01, 0x9b, + 0xee, 0x18, 0xb5, 0x42, 0x06, 0xd0, 0x00, 0x21, 0x20, 0x68, 0x04, 0xf0, + 0xa3, 0xfb, 0x28, 0x70, 0x01, 0x35, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, + 0x95, 0xff, 0xf7, 0xbd, 0xec, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, + 0xff, 0xf7, 0x88, 0xff, 0x06, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, + 0x75, 0xfb, 0x06, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x8d, 0xfb, 0x20, 0x00, + 0xff, 0xf7, 0x82, 0xff, 0x10, 0xbd, 0xc0, 0x46, 0xec, 0x0b, 0x00, 0x20, + 0xf7, 0xb5, 0x04, 0x00, 0x0e, 0x00, 0x15, 0x00, 0x10, 0x27, 0x01, 0x93, + 0x20, 0x00, 0xff, 0xf7, 0xa3, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x3b, 0x00, + 0x01, 0x3b, 0xfd, 0xd1, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xda, 0xff, + 0x20, 0x00, 0xff, 0xf7, 0x63, 0xff, 0x12, 0x4b, 0x20, 0x68, 0x06, 0xcb, + 0x04, 0xf0, 0x50, 0xfb, 0x02, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x68, 0xfb, + 0x31, 0x0c, 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x63, 0xfb, 0x31, 0x0a, + 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x5e, 0xfb, 0xf1, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0x5a, 0xfb, 0x01, 0x9b, 0xee, 0x18, 0xb5, 0x42, 0x05, 0xd0, + 0x29, 0x78, 0x20, 0x68, 0x04, 0xf0, 0x52, 0xfb, 0x01, 0x35, 0xf7, 0xe7, + 0x20, 0x00, 0xff, 0xf7, 0x45, 0xff, 0xf7, 0xbd, 0xec, 0x0b, 0x00, 0x20, + 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x10, 0x26, 0x20, 0x00, 0xff, 0xf7, + 0x69, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x33, 0x00, 0x01, 0x3b, 0xfd, 0xd1, + 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xa0, 0xff, 0x20, 0x00, 0xff, 0xf7, + 0x29, 0xff, 0x0d, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, 0x16, 0xfb, + 0x20, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x2e, 0xfb, 0x29, 0x0c, 0xc9, 0xb2, + 0x20, 0x68, 0x04, 0xf0, 0x29, 0xfb, 0x29, 0x0a, 0xc9, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0x24, 0xfb, 0xe9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x20, 0xfb, + 0x20, 0x00, 0xff, 0xf7, 0x15, 0xff, 0x70, 0xbd, 0xec, 0x0b, 0x00, 0x20, + 0x10, 0xb5, 0x0b, 0x00, 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, 0x40, 0xff, + 0x00, 0x20, 0x10, 0xbd, 0xf4, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x0b, 0x00, + 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, 0x84, 0xff, 0x00, 0x20, 0x10, 0xbd, + 0xf4, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, + 0xb7, 0xff, 0x00, 0x20, 0x10, 0xbd, 0xc0, 0x46, 0xf4, 0x0b, 0x00, 0x20, + 0x05, 0x4b, 0x06, 0x4a, 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, + 0x04, 0x4b, 0x05, 0x4a, 0x1a, 0x60, 0x05, 0x22, 0x5a, 0x60, 0x70, 0x47, + 0xec, 0x0b, 0x00, 0x20, 0x00, 0x1b, 0xb7, 0x00, 0xf4, 0x0b, 0x00, 0x20, + 0xfc, 0x0b, 0x00, 0x20, 0x01, 0x23, 0x8b, 0x40, 0xf7, 0xb5, 0x44, 0x6c, + 0x01, 0x93, 0x01, 0x9d, 0xa3, 0x68, 0x06, 0x00, 0x00, 0x20, 0x2b, 0x42, + 0x1c, 0xd0, 0x8a, 0x25, 0x6d, 0x00, 0x69, 0x43, 0x23, 0x69, 0x5d, 0x18, + 0x82, 0x42, 0x0f, 0xd0, 0x2a, 0x78, 0x57, 0xb2, 0x87, 0x42, 0x0b, 0xdb, + 0x01, 0x27, 0x3a, 0x42, 0x08, 0xd0, 0x0a, 0x00, 0x80, 0x21, 0x28, 0x89, + 0x14, 0x32, 0x9a, 0x18, 0x00, 0x02, 0x73, 0x68, 0x49, 0x00, 0x98, 0x47, + 0xa3, 0x68, 0x01, 0x9a, 0x93, 0x43, 0xa3, 0x60, 0x00, 0x23, 0x2b, 0x70, + 0xfe, 0xbd, 0xc3, 0x68, 0xf0, 0xb5, 0x84, 0x68, 0x02, 0x00, 0x23, 0x40, + 0x18, 0x1e, 0x17, 0xd0, 0x8a, 0x27, 0x00, 0x23, 0x15, 0x78, 0x7f, 0x00, + 0xab, 0x42, 0x01, 0xdb, 0x00, 0x20, 0x0f, 0xe0, 0x01, 0x20, 0x98, 0x40, + 0x04, 0x42, 0x0c, 0xd0, 0x38, 0x00, 0x58, 0x43, 0x16, 0x69, 0x30, 0x18, + 0x06, 0x78, 0x7f, 0x2e, 0x05, 0xd8, 0x06, 0x89, 0x8e, 0x42, 0x02, 0xd1, + 0x53, 0x68, 0x43, 0x60, 0xf0, 0xbd, 0x01, 0x33, 0xe8, 0xe7, 0x82, 0x68, + 0x01, 0x00, 0x30, 0xb5, 0x00, 0x20, 0x53, 0x1c, 0x13, 0xd0, 0x00, 0x23, + 0x01, 0x25, 0x08, 0x78, 0x83, 0x42, 0x01, 0xdb, 0x00, 0x20, 0x0c, 0xe0, + 0x2c, 0x00, 0x9c, 0x40, 0x14, 0x42, 0x09, 0xd1, 0x8a, 0x20, 0x40, 0x00, + 0x58, 0x43, 0x0b, 0x69, 0x22, 0x43, 0x18, 0x18, 0x4b, 0x68, 0x8a, 0x60, + 0x43, 0x60, 0x30, 0xbd, 0x01, 0x33, 0xeb, 0xe7, 0xf8, 0xb5, 0x44, 0x6c, + 0x07, 0x00, 0xe2, 0x68, 0xa3, 0x68, 0x00, 0x20, 0x13, 0x40, 0x9a, 0x42, + 0x0e, 0xd1, 0x23, 0x78, 0x01, 0x21, 0x9c, 0x46, 0x02, 0x00, 0x03, 0x00, + 0x49, 0x42, 0x62, 0x45, 0x07, 0xdb, 0x00, 0x20, 0x4b, 0x1c, 0x03, 0xd0, + 0x01, 0x22, 0x38, 0x00, 0xff, 0xf7, 0x80, 0xff, 0xf8, 0xbd, 0x8a, 0x26, + 0x76, 0x00, 0x56, 0x43, 0x25, 0x69, 0xae, 0x19, 0x70, 0x68, 0x65, 0x68, + 0x2d, 0x1a, 0x9d, 0x42, 0x04, 0xd9, 0x36, 0x78, 0x7f, 0x2e, 0x01, 0xd8, + 0x2b, 0x00, 0x11, 0x00, 0x01, 0x32, 0xe4, 0xe7, 0x10, 0xb5, 0x04, 0x00, + 0x40, 0x6c, 0xff, 0xf7, 0x92, 0xff, 0x00, 0x28, 0x04, 0xd0, 0x41, 0x78, + 0x00, 0x22, 0x20, 0x00, 0xff, 0xf7, 0x62, 0xff, 0x10, 0xbd, 0xf7, 0xb5, + 0x46, 0x6c, 0x1c, 0x00, 0x1b, 0x0a, 0x9b, 0xb2, 0x05, 0x00, 0x0f, 0x00, + 0x30, 0x00, 0x19, 0x00, 0x01, 0x93, 0xff, 0xf7, 0x7e, 0xff, 0x73, 0x68, + 0x01, 0x33, 0x73, 0x60, 0x00, 0x28, 0x10, 0xd0, 0x8a, 0x21, 0x43, 0x60, + 0x43, 0x78, 0x49, 0x00, 0x59, 0x43, 0xe4, 0xb2, 0x14, 0x34, 0x09, 0x19, + 0x34, 0x69, 0x08, 0x9a, 0x61, 0x18, 0x09, 0x98, 0x05, 0xf0, 0x22, 0xfa, + 0x00, 0x27, 0x38, 0x00, 0xfe, 0xbd, 0x03, 0x23, 0x1f, 0x40, 0x01, 0x2f, + 0x06, 0xd1, 0x2b, 0x68, 0x09, 0x9a, 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, + 0x07, 0x00, 0xf2, 0xe7, 0x28, 0x00, 0xff, 0xf7, 0x99, 0xff, 0x07, 0x00, + 0x68, 0x6c, 0xff, 0xf7, 0x78, 0xff, 0x00, 0x90, 0x00, 0x28, 0x24, 0xd0, + 0x02, 0x23, 0x6a, 0x46, 0x03, 0x70, 0x8a, 0x23, 0x92, 0x88, 0x5b, 0x00, + 0x02, 0x81, 0x42, 0x78, 0x80, 0x21, 0x5a, 0x43, 0x33, 0x69, 0x14, 0x32, + 0x9a, 0x18, 0x20, 0x00, 0xff, 0x23, 0x49, 0x00, 0x98, 0x43, 0x2b, 0x68, + 0x98, 0x47, 0x8a, 0x21, 0x49, 0x00, 0x00, 0x28, 0x00, 0xd0, 0x07, 0x00, + 0x00, 0x9b, 0xe4, 0xb2, 0x5b, 0x78, 0x14, 0x34, 0x59, 0x43, 0x09, 0x19, + 0x34, 0x69, 0x08, 0x9a, 0x61, 0x18, 0x09, 0x98, 0x05, 0xf0, 0xe6, 0xf9, + 0xc3, 0xe7, 0x2b, 0x68, 0x09, 0x9a, 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, + 0x00, 0x28, 0xc7, 0xd1, 0xbb, 0xe7, 0xf7, 0xb5, 0x47, 0x6c, 0x01, 0x91, + 0x19, 0x0a, 0x05, 0x00, 0x89, 0xb2, 0x38, 0x00, 0x1c, 0x00, 0xff, 0xf7, + 0x1c, 0xff, 0x06, 0x1e, 0x0c, 0xd0, 0x1c, 0x22, 0x01, 0x9b, 0x1a, 0x40, + 0x18, 0x2a, 0x07, 0xd0, 0x41, 0x78, 0x00, 0x2a, 0x0a, 0xd1, 0x9b, 0x07, + 0x08, 0xd0, 0x28, 0x00, 0xff, 0xf7, 0xe4, 0xfe, 0x6b, 0x68, 0x09, 0x9a, + 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, 0x14, 0xe0, 0x8a, 0x23, 0x5b, 0x00, + 0x59, 0x43, 0xe0, 0xb2, 0x3b, 0x69, 0x14, 0x30, 0x40, 0x18, 0x18, 0x18, + 0x08, 0x9a, 0x09, 0x99, 0x05, 0xf0, 0xb2, 0xf9, 0x02, 0x22, 0x7b, 0x68, + 0x01, 0x33, 0x7b, 0x60, 0x73, 0x60, 0x33, 0x78, 0x13, 0x40, 0x18, 0x1e, + 0xe4, 0xd1, 0xfe, 0xbd, 0xf7, 0xb5, 0x42, 0x6c, 0x94, 0x68, 0xd3, 0x68, + 0x23, 0x40, 0x18, 0x1e, 0x09, 0xd0, 0x13, 0x78, 0x8a, 0x26, 0x01, 0x93, + 0x01, 0x25, 0x00, 0x23, 0x76, 0x00, 0x01, 0x98, 0x98, 0x42, 0x01, 0xdc, + 0x00, 0x20, 0xfe, 0xbd, 0x28, 0x00, 0x98, 0x40, 0x04, 0x42, 0x0b, 0xd0, + 0x30, 0x00, 0x58, 0x43, 0x17, 0x69, 0x38, 0x18, 0x07, 0x78, 0x7f, 0x2f, + 0x04, 0xd9, 0x07, 0x89, 0xbc, 0x46, 0xcf, 0x88, 0xbc, 0x45, 0xee, 0xd0, + 0x01, 0x33, 0xe8, 0xe7, 0x70, 0xb5, 0x0c, 0x1e, 0x0f, 0xd0, 0x30, 0x21, + 0xc5, 0x6a, 0x83, 0x6a, 0x69, 0x43, 0x1a, 0x1d, 0x5b, 0x18, 0x00, 0x21, + 0x04, 0x33, 0x9a, 0x42, 0x06, 0xd1, 0x61, 0x78, 0x00, 0x22, 0xff, 0xf7, + 0x93, 0xfe, 0x00, 0x23, 0x23, 0x81, 0x70, 0xbd, 0x00, 0x26, 0x95, 0x5f, + 0x00, 0x2d, 0x03, 0xd0, 0xd5, 0x69, 0xa5, 0x42, 0x00, 0xd1, 0xd1, 0x61, + 0x30, 0x32, 0xec, 0xe7, 0xf0, 0xb5, 0x47, 0x6c, 0x89, 0xb0, 0x06, 0x00, + 0x00, 0x2f, 0x36, 0xd0, 0x8a, 0x21, 0x80, 0x6c, 0x49, 0x00, 0x14, 0x38, + 0x05, 0xf0, 0xaa, 0xf8, 0x04, 0x1e, 0x2e, 0xd0, 0x00, 0x23, 0x01, 0x21, + 0x01, 0x93, 0x01, 0x9a, 0x01, 0x33, 0x52, 0x00, 0x0a, 0x43, 0x01, 0x92, + 0x9c, 0x42, 0xf8, 0xdc, 0x03, 0xad, 0x08, 0x22, 0x00, 0x21, 0x28, 0x00, + 0x05, 0xf0, 0x51, 0xf9, 0x3b, 0x00, 0x14, 0x33, 0x2b, 0x61, 0x01, 0x23, + 0x5b, 0x42, 0xab, 0x60, 0x01, 0x9b, 0x29, 0x00, 0x14, 0x22, 0x38, 0x00, + 0xeb, 0x60, 0x2c, 0x70, 0x05, 0xf0, 0x3a, 0xf9, 0x75, 0x6c, 0x8a, 0x26, + 0x2a, 0x78, 0x76, 0x00, 0x72, 0x43, 0x00, 0x21, 0x28, 0x69, 0x05, 0xf0, + 0x3a, 0xf9, 0xab, 0x68, 0xea, 0x68, 0xe4, 0xb2, 0x93, 0x43, 0xab, 0x60, + 0x00, 0x23, 0x9c, 0x42, 0x01, 0xdc, 0x09, 0xb0, 0xf0, 0xbd, 0x32, 0x00, + 0x5a, 0x43, 0x29, 0x69, 0x8a, 0x18, 0x53, 0x70, 0x01, 0x33, 0xf4, 0xe7, + 0xf0, 0xb5, 0x85, 0xb0, 0x06, 0x00, 0x0d, 0x00, 0x14, 0x00, 0x03, 0x93, + 0x00, 0x27, 0x68, 0x2a, 0x06, 0xd9, 0x10, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x05, 0xf0, 0x62, 0xf8, 0x01, 0x30, 0x87, 0xb2, 0x80, 0x21, 0x0a, 0x9b, + 0x09, 0x02, 0x00, 0x93, 0x29, 0x43, 0x00, 0x23, 0x3a, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0xfa, 0xfa, 0x00, 0x28, 0x11, 0xdb, 0x0a, 0x9b, 0x1d, 0x88, + 0x2d, 0x02, 0x00, 0x2f, 0x0e, 0xd1, 0x23, 0x00, 0x17, 0x33, 0x03, 0x9a, + 0x5b, 0x00, 0x01, 0x92, 0x02, 0x22, 0x5b, 0x19, 0x00, 0x92, 0x15, 0x21, + 0x00, 0x22, 0x30, 0x00, 0xff, 0xf7, 0xb1, 0xfe, 0x05, 0xb0, 0xf0, 0xbd, + 0x23, 0x1d, 0x68, 0x2c, 0xef, 0xd9, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x05, 0xf0, 0xbe, 0xf8, 0x0b, 0x1d, 0xe8, 0xe7, 0x30, 0xb5, 0x0e, 0x25, + 0x00, 0x23, 0x85, 0xb0, 0x6d, 0x44, 0x1a, 0x00, 0x00, 0x95, 0x04, 0x00, + 0x02, 0xf0, 0xd0, 0xfa, 0x0b, 0x4b, 0x98, 0x42, 0x12, 0xd0, 0x00, 0x28, + 0x0e, 0xdb, 0x0d, 0x22, 0xbf, 0x23, 0x6a, 0x44, 0x13, 0x70, 0x2b, 0x88, + 0x01, 0x92, 0x01, 0x22, 0x1b, 0x02, 0x00, 0x92, 0x04, 0x33, 0x00, 0x22, + 0x04, 0x21, 0x20, 0x00, 0xff, 0xf7, 0xeb, 0xfe, 0x05, 0xb0, 0x30, 0xbd, + 0x00, 0x20, 0xfb, 0xe7, 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x8b, 0xb0, + 0x04, 0x93, 0x10, 0xab, 0x1b, 0x88, 0x12, 0x25, 0x05, 0x93, 0x50, 0x4b, + 0x14, 0x00, 0x19, 0x43, 0x0e, 0x23, 0x04, 0xaa, 0x9b, 0x18, 0x19, 0x80, + 0x09, 0xab, 0xad, 0x18, 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x2b, 0x00, + 0x06, 0x00, 0x02, 0xf0, 0x65, 0xfa, 0x00, 0x28, 0x33, 0xdb, 0x09, 0x9b, + 0x2d, 0x88, 0x06, 0x93, 0x68, 0x2c, 0x30, 0xd9, 0x27, 0x00, 0x69, 0x3f, + 0x7c, 0x21, 0x38, 0x00, 0x04, 0xf0, 0xee, 0xff, 0x01, 0x30, 0x83, 0xb2, + 0x7c, 0x21, 0x38, 0x00, 0x03, 0x93, 0x05, 0xf0, 0x6d, 0xf8, 0x09, 0x91, + 0x32, 0x6a, 0x05, 0x9b, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, + 0x1b, 0x02, 0x00, 0x22, 0x15, 0x21, 0x30, 0x00, 0xff, 0xf7, 0x49, 0xfe, + 0x00, 0x28, 0x12, 0xdb, 0x06, 0x9b, 0x37, 0x6a, 0x2d, 0x01, 0xed, 0x18, + 0x04, 0xaa, 0x7b, 0x78, 0x39, 0x78, 0xd2, 0x89, 0x01, 0x35, 0x1b, 0x02, + 0xad, 0xb2, 0x0b, 0x43, 0x9a, 0x42, 0x0a, 0xd0, 0x29, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0x5c, 0xfb, 0x2e, 0x48, 0x0b, 0xb0, 0xf0, 0xbd, 0x00, 0x23, + 0x09, 0x94, 0x03, 0x93, 0xd8, 0xe7, 0xfb, 0x78, 0xba, 0x78, 0x1b, 0x02, + 0x13, 0x43, 0x03, 0x9a, 0x93, 0x42, 0x05, 0xd0, 0x29, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0x4a, 0xfb, 0x26, 0x48, 0xec, 0xe7, 0x38, 0x22, 0x3b, 0x79, + 0x93, 0x43, 0xc0, 0x2b, 0x05, 0xd0, 0x29, 0x00, 0x30, 0x00, 0x02, 0xf0, + 0x3f, 0xfb, 0x22, 0x48, 0xe1, 0xe7, 0x03, 0x9b, 0x00, 0x2b, 0x2a, 0xd1, + 0x6b, 0x46, 0x64, 0x00, 0x1b, 0x8a, 0x3c, 0x19, 0xe3, 0x85, 0x80, 0x22, + 0x52, 0x00, 0x00, 0x92, 0x2b, 0x02, 0x01, 0x97, 0x00, 0x22, 0x07, 0x21, + 0x30, 0x00, 0xff, 0xf7, 0x68, 0xfe, 0x00, 0x28, 0xcd, 0xdb, 0x0f, 0x23, + 0x17, 0x4a, 0x2b, 0x40, 0x9b, 0x18, 0x0e, 0x22, 0x04, 0xa9, 0x52, 0x18, + 0x01, 0x92, 0x02, 0x22, 0x2d, 0x09, 0x5b, 0x00, 0x2d, 0x03, 0x00, 0x92, + 0x5b, 0x19, 0x00, 0x22, 0x04, 0x21, 0x30, 0x00, 0xff, 0xf7, 0x53, 0xfe, + 0x00, 0x28, 0xb8, 0xdb, 0x05, 0x99, 0x30, 0x00, 0x02, 0xf0, 0x10, 0xfb, + 0xb3, 0xe7, 0x68, 0x2c, 0x05, 0xd8, 0x64, 0x00, 0x6b, 0x46, 0x1b, 0x8a, + 0x3c, 0x19, 0x23, 0x81, 0xd1, 0xe7, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x04, 0xf0, 0xf2, 0xff, 0x4c, 0x00, 0xf3, 0xe7, 0x00, 0x80, 0xff, 0xff, + 0xbd, 0xd8, 0xff, 0xff, 0xbc, 0xd8, 0xff, 0xff, 0xbb, 0xd8, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x00, 0x24, 0x85, 0xb0, 0x0e, 0x00, + 0x1f, 0x00, 0x11, 0x88, 0x03, 0x93, 0x02, 0x94, 0x01, 0x94, 0x00, 0x94, + 0x23, 0x00, 0x05, 0x00, 0x02, 0xf0, 0x66, 0xfa, 0xa0, 0x42, 0x0a, 0xdb, + 0xfb, 0x21, 0x3a, 0x88, 0x33, 0x02, 0x12, 0x02, 0x00, 0x91, 0x05, 0x33, + 0x05, 0x32, 0x21, 0x00, 0x28, 0x00, 0x01, 0xf0, 0xe3, 0xff, 0x05, 0xb0, + 0xf0, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x93, 0xb0, 0x06, 0x91, 0x01, 0x33, + 0x11, 0x01, 0xcb, 0x18, 0xc4, 0x6c, 0x9b, 0xb2, 0x07, 0x00, 0x05, 0x93, + 0x00, 0x2c, 0x08, 0xd0, 0x10, 0x02, 0xf9, 0x68, 0x04, 0xf0, 0x32, 0xff, + 0x00, 0x23, 0x02, 0x00, 0x19, 0x00, 0x18, 0x00, 0xa0, 0x47, 0x05, 0x9b, + 0x0e, 0xad, 0x1b, 0x02, 0x08, 0x93, 0x05, 0x23, 0x01, 0x95, 0x00, 0x93, + 0x00, 0x22, 0x08, 0x9b, 0x15, 0x21, 0x38, 0x00, 0xff, 0xf7, 0x8f, 0xfd, + 0x04, 0x1e, 0x00, 0xda, 0xd5, 0xe0, 0x06, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0x81, 0xe0, 0x2b, 0x79, 0x7f, 0x2b, 0x00, 0xd9, 0x86, 0xe0, 0x06, 0x9b, + 0x1c, 0x00, 0x1d, 0x00, 0x04, 0x93, 0x06, 0x9b, 0x83, 0x4a, 0x01, 0x3b, + 0x9b, 0xb2, 0x93, 0x42, 0x00, 0xd9, 0x02, 0xe2, 0x81, 0x48, 0x06, 0x9b, + 0x02, 0x00, 0x0e, 0xae, 0x03, 0x43, 0x9b, 0xb2, 0x31, 0x88, 0x07, 0x93, + 0x33, 0x79, 0x0a, 0x43, 0x09, 0x90, 0x07, 0x98, 0x92, 0xb2, 0x82, 0x42, + 0x00, 0xd1, 0xb2, 0xe1, 0x5a, 0xb2, 0x00, 0x2a, 0x51, 0xda, 0x9a, 0x07, + 0x4f, 0xd4, 0x44, 0x22, 0x13, 0x42, 0x4c, 0xd0, 0x04, 0x25, 0x72, 0x88, + 0x1d, 0x40, 0x00, 0xd1, 0xee, 0xe0, 0x12, 0x23, 0x06, 0xa8, 0x1b, 0x18, + 0x0b, 0xad, 0x00, 0x93, 0x38, 0x00, 0x2b, 0x00, 0xff, 0xf7, 0x74, 0xfe, + 0x6f, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x3a, 0xd0, 0x00, 0x28, 0x00, 0xda, + 0x95, 0xe0, 0x2b, 0x88, 0x05, 0x9a, 0x93, 0x42, 0x33, 0xd1, 0x10, 0xad, + 0x2b, 0x00, 0x32, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0x72, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0x87, 0xe0, 0x12, 0x20, 0x06, 0xac, 0x00, 0x19, + 0x00, 0x88, 0x0e, 0xae, 0x2b, 0x88, 0x72, 0x88, 0x31, 0x88, 0x00, 0x90, + 0x38, 0x00, 0xff, 0xf7, 0xb1, 0xfe, 0x60, 0x4b, 0x04, 0x00, 0xc3, 0x18, + 0x02, 0x2b, 0x16, 0xd8, 0x29, 0x88, 0x38, 0x00, 0x02, 0xf0, 0x50, 0xfa, + 0x04, 0x1e, 0x70, 0xdb, 0x31, 0x88, 0x38, 0x00, 0xff, 0xf7, 0x7e, 0xfe, + 0x01, 0x23, 0xfd, 0x6c, 0x04, 0x00, 0x04, 0x93, 0x00, 0x2d, 0x06, 0xd0, + 0x00, 0x23, 0x32, 0x88, 0x18, 0x00, 0x06, 0x21, 0xa8, 0x47, 0x01, 0x23, + 0x04, 0x93, 0x00, 0x2c, 0x5d, 0xdb, 0xfc, 0x6c, 0x00, 0x2c, 0x04, 0xd0, + 0x00, 0x23, 0x05, 0x9a, 0x05, 0x21, 0x18, 0x00, 0xa0, 0x47, 0x05, 0x99, + 0x38, 0x00, 0x02, 0xf0, 0x2f, 0xfa, 0x04, 0x00, 0x92, 0xe1, 0x4b, 0x4b, + 0x06, 0x9a, 0x9a, 0x42, 0x00, 0xd0, 0x82, 0xe0, 0x2b, 0x79, 0xdb, 0x07, + 0x00, 0xd5, 0x7e, 0xe0, 0x04, 0x23, 0x2e, 0x79, 0x29, 0x88, 0x6a, 0x88, + 0x1e, 0x40, 0x4b, 0xd0, 0x06, 0xa8, 0x0e, 0x33, 0x1b, 0x18, 0x0b, 0xae, + 0x00, 0x93, 0x38, 0x00, 0x33, 0x00, 0xff, 0xf7, 0x0f, 0xfe, 0x3d, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x00, 0xd1, 0x6c, 0xe0, 0x00, 0x28, 0x30, 0xdb, + 0x33, 0x88, 0x05, 0x9a, 0x93, 0x42, 0x00, 0xd0, 0x60, 0xe0, 0x10, 0xae, + 0x33, 0x00, 0x2a, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0x0c, 0xff, + 0x04, 0x1e, 0x22, 0xdb, 0x06, 0xa8, 0x40, 0x8a, 0x33, 0x88, 0x6a, 0x88, + 0x29, 0x88, 0x00, 0x90, 0x38, 0x00, 0xff, 0xf7, 0x4f, 0xfe, 0x2f, 0x4b, + 0x04, 0x00, 0xc3, 0x18, 0x02, 0x2b, 0x17, 0xd8, 0x31, 0x88, 0x38, 0x00, + 0x02, 0xf0, 0xee, 0xf9, 0x04, 0x1e, 0x0e, 0xdb, 0x29, 0x88, 0x38, 0x00, + 0xff, 0xf7, 0x1c, 0xfe, 0xfe, 0x6c, 0x04, 0x00, 0x00, 0x2e, 0x04, 0xd0, + 0x00, 0x23, 0x06, 0x21, 0x18, 0x00, 0x2a, 0x88, 0xb0, 0x47, 0x00, 0x2c, + 0x34, 0xda, 0x20, 0x00, 0x13, 0xb0, 0xf0, 0xbd, 0xfe, 0x6c, 0x00, 0x2e, + 0xf7, 0xd0, 0x6b, 0x88, 0x2a, 0x88, 0x02, 0x21, 0x00, 0x20, 0xf1, 0xe7, + 0x1a, 0x4b, 0x00, 0x96, 0x19, 0x43, 0x89, 0xb2, 0x05, 0x9b, 0x38, 0x00, + 0x02, 0xf0, 0xd8, 0xf8, 0x17, 0x4b, 0x04, 0x00, 0x98, 0x42, 0xe6, 0xd1, + 0x29, 0x88, 0x14, 0x4b, 0x00, 0x96, 0x0b, 0x43, 0x99, 0xb2, 0x32, 0x00, + 0x33, 0x00, 0x38, 0x00, 0x02, 0xf0, 0x02, 0xf9, 0x04, 0x1e, 0x11, 0xd1, + 0x10, 0xab, 0x2a, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0xbe, 0xfe, + 0x04, 0x1e, 0xd4, 0xdb, 0xfb, 0x6c, 0x9c, 0x46, 0x00, 0x2b, 0x05, 0xd0, + 0x6b, 0x88, 0x2a, 0x88, 0x03, 0x21, 0x30, 0x00, 0x65, 0x46, 0xa8, 0x47, + 0x01, 0x23, 0x04, 0x93, 0x04, 0xe0, 0x00, 0x23, 0xf8, 0xe6, 0x01, 0x23, + 0x00, 0x24, 0x04, 0x93, 0x1d, 0x00, 0xf6, 0xe6, 0xfd, 0xff, 0x00, 0x00, + 0x00, 0x80, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, + 0xff, 0xff, 0x00, 0x00, 0x16, 0x26, 0x06, 0xab, 0xf6, 0x18, 0x00, 0x96, + 0x2b, 0x00, 0x07, 0x99, 0x38, 0x00, 0x02, 0xf0, 0x99, 0xf8, 0xc1, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x00, 0xd0, 0x75, 0xe0, 0x35, 0x80, 0x0e, 0xae, + 0x31, 0x88, 0x09, 0x9b, 0x0c, 0xad, 0x19, 0x43, 0x72, 0x88, 0x00, 0x23, + 0x89, 0xb2, 0x00, 0x95, 0x38, 0x00, 0x02, 0xf0, 0x87, 0xf8, 0xb8, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x68, 0xd1, 0x00, 0x23, 0x2b, 0x80, 0x2b, 0x88, + 0x00, 0x2b, 0x06, 0xd0, 0x16, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0x00, 0x2b, 0x00, 0xd0, 0x2d, 0xe7, 0x06, 0x9b, 0x06, 0xaa, 0x59, 0x04, + 0x1a, 0x23, 0x9b, 0x18, 0x00, 0x93, 0x00, 0x23, 0x49, 0x0c, 0x1a, 0x00, + 0x38, 0x00, 0x02, 0xf0, 0x6b, 0xf8, 0xaa, 0x4b, 0x04, 0x00, 0x98, 0x42, + 0x4f, 0xd1, 0x16, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x00, 0x22, 0x1a, 0x80, + 0x00, 0x23, 0x31, 0x88, 0x0d, 0xad, 0x49, 0x04, 0x1a, 0x00, 0x49, 0x0c, + 0x00, 0x95, 0x38, 0x00, 0x02, 0xf0, 0x58, 0xf8, 0xa0, 0x4b, 0x04, 0x00, + 0x98, 0x42, 0x3f, 0xd1, 0x00, 0x22, 0x0c, 0xab, 0x1a, 0x80, 0xf8, 0x23, + 0x16, 0x21, 0x10, 0xaa, 0x06, 0xa8, 0x13, 0x71, 0x09, 0x18, 0x73, 0x88, + 0x08, 0x88, 0x53, 0x80, 0x00, 0x28, 0x05, 0xd0, 0x1a, 0x21, 0x06, 0xac, + 0x09, 0x19, 0x09, 0x88, 0x00, 0x29, 0x2e, 0xd0, 0x29, 0x88, 0x00, 0x29, + 0x2b, 0xd0, 0x0c, 0xa9, 0x09, 0x88, 0x06, 0x91, 0x00, 0x29, 0x26, 0xd1, + 0x33, 0x88, 0x09, 0x99, 0x38, 0x00, 0x19, 0x43, 0x1e, 0x23, 0x11, 0x80, + 0x06, 0xa9, 0x5b, 0x18, 0x05, 0x99, 0xff, 0xf7, 0x29, 0xfe, 0xfd, 0x6c, + 0x04, 0x00, 0x00, 0x2d, 0x04, 0xd0, 0x73, 0x88, 0x32, 0x88, 0x03, 0x21, + 0x06, 0x98, 0xa8, 0x47, 0x00, 0x2c, 0x00, 0xda, 0x35, 0xe7, 0x01, 0x23, + 0x04, 0x93, 0xd4, 0xe6, 0x00, 0x28, 0x00, 0xdb, 0x87, 0xe7, 0x2e, 0xe7, + 0x00, 0x28, 0x96, 0xda, 0x2b, 0xe7, 0x00, 0x28, 0xb2, 0xda, 0x28, 0xe7, + 0x00, 0x28, 0xc0, 0xda, 0x25, 0xe7, 0x0c, 0xaa, 0x12, 0x88, 0x00, 0x2a, + 0x03, 0xd0, 0x2a, 0x88, 0x00, 0x2a, 0x00, 0xd1, 0xbf, 0xe6, 0x1a, 0x22, + 0x06, 0xa9, 0x52, 0x18, 0x12, 0x88, 0x00, 0x2a, 0x00, 0xd1, 0xb8, 0xe6, + 0x00, 0x28, 0x00, 0xd0, 0xb5, 0xe6, 0x6a, 0x46, 0xfd, 0x6c, 0x92, 0x8b, + 0x10, 0xac, 0x22, 0x80, 0x00, 0x2d, 0x02, 0xd0, 0x32, 0x88, 0x03, 0x21, + 0xa8, 0x47, 0x1e, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x05, 0x99, 0x22, 0x00, + 0x38, 0x00, 0xff, 0xf7, 0xe9, 0xfd, 0x04, 0x00, 0xc6, 0xe7, 0x69, 0x46, + 0x04, 0x22, 0x18, 0x20, 0x09, 0x5e, 0x1a, 0x40, 0x00, 0x29, 0x44, 0xda, + 0x00, 0x2a, 0x44, 0xd1, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0x94, 0xe6, + 0x9b, 0x07, 0x30, 0xd5, 0x12, 0x23, 0x06, 0xa9, 0x5b, 0x18, 0x0e, 0xae, + 0x72, 0x88, 0x06, 0x99, 0x00, 0x93, 0x38, 0x00, 0x0b, 0xab, 0xff, 0xf7, + 0xbd, 0xfc, 0x5d, 0x4b, 0x04, 0x00, 0x98, 0x42, 0xab, 0xd0, 0x00, 0x28, + 0x00, 0xda, 0xde, 0xe6, 0x01, 0x22, 0x06, 0xab, 0x04, 0x92, 0x9b, 0x8a, + 0x05, 0x9a, 0x93, 0x42, 0x00, 0xd0, 0x78, 0xe6, 0xfc, 0x6c, 0x00, 0x2c, + 0x04, 0xd0, 0x73, 0x88, 0x32, 0x88, 0x03, 0x21, 0x00, 0x20, 0xa0, 0x47, + 0xfd, 0x23, 0x01, 0x26, 0x10, 0xaa, 0x13, 0x70, 0x08, 0x9b, 0x01, 0x92, + 0x04, 0x33, 0x00, 0x96, 0x00, 0x22, 0x07, 0x21, 0x38, 0x00, 0xff, 0xf7, + 0xdc, 0xfb, 0x04, 0x00, 0x04, 0x96, 0x00, 0x2d, 0x00, 0xd0, 0x5e, 0xe6, + 0x00, 0x2c, 0x00, 0xd0, 0xb9, 0xe6, 0x04, 0x9c, 0x47, 0x4b, 0x67, 0x42, + 0x7c, 0x41, 0xe4, 0x18, 0xb3, 0xe6, 0x00, 0x2a, 0xba, 0xd1, 0x1a, 0x26, + 0x06, 0x9b, 0x0e, 0xad, 0x5b, 0x04, 0x5b, 0x0c, 0x09, 0x93, 0x06, 0xab, + 0xf6, 0x18, 0x6a, 0x88, 0x05, 0x9b, 0x00, 0x96, 0x09, 0x99, 0x38, 0x00, + 0x01, 0xf0, 0x8e, 0xff, 0x3b, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x4c, 0xd1, + 0x00, 0x23, 0x33, 0x80, 0x6a, 0x88, 0x0d, 0xad, 0x05, 0x9b, 0x00, 0x95, + 0x07, 0x99, 0x38, 0x00, 0x01, 0xf0, 0x80, 0xff, 0x34, 0x4b, 0x04, 0x00, + 0x98, 0x42, 0x41, 0xd1, 0x00, 0x23, 0x2b, 0x80, 0x1a, 0x23, 0x06, 0xaa, + 0x9b, 0x18, 0x28, 0x88, 0x1d, 0x88, 0xfc, 0x6c, 0x00, 0x2d, 0x3a, 0xd0, + 0x00, 0x28, 0x00, 0xd0, 0x25, 0xe6, 0x00, 0x2c, 0x04, 0xd0, 0x0e, 0xab, + 0x5b, 0x88, 0x06, 0x9a, 0x02, 0x21, 0xa0, 0x47, 0xf8, 0x23, 0x10, 0xaa, + 0x13, 0x71, 0x6b, 0x46, 0x1e, 0x26, 0x9b, 0x8b, 0x00, 0x25, 0x13, 0x80, + 0x0e, 0xab, 0x5b, 0x88, 0x07, 0x99, 0x53, 0x80, 0x06, 0xab, 0xf6, 0x18, + 0x01, 0x23, 0x02, 0x93, 0x2b, 0x00, 0x03, 0x96, 0x01, 0x95, 0x00, 0x95, + 0x38, 0x00, 0x01, 0xf0, 0xc1, 0xff, 0x04, 0x00, 0xa8, 0x42, 0x00, 0xda, + 0x61, 0xe6, 0xfb, 0x21, 0x32, 0x88, 0x08, 0x9b, 0x12, 0x02, 0x00, 0x91, + 0x05, 0x33, 0x05, 0x32, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, 0x3c, 0xfd, + 0x04, 0x00, 0xa8, 0x42, 0x00, 0xdb, 0xf4, 0xe5, 0x51, 0xe6, 0x00, 0x28, + 0xb2, 0xda, 0x4e, 0xe6, 0x00, 0x28, 0xbd, 0xda, 0x4b, 0xe6, 0x00, 0x28, + 0x00, 0xd1, 0xea, 0xe5, 0x0e, 0xab, 0x5b, 0x88, 0x00, 0x2c, 0x03, 0xd0, + 0x06, 0x9a, 0x03, 0x21, 0x28, 0x00, 0xa0, 0x47, 0xfc, 0x23, 0x10, 0xaa, + 0x13, 0x71, 0x6b, 0x46, 0x1e, 0x26, 0x9b, 0x8c, 0x00, 0x25, 0x13, 0x80, + 0x0e, 0xab, 0x5b, 0x88, 0x09, 0x99, 0x53, 0x80, 0x06, 0xab, 0xf6, 0x18, + 0x01, 0x23, 0x03, 0x96, 0x02, 0x93, 0x01, 0x95, 0x00, 0x95, 0x2b, 0x00, + 0xc2, 0xe7, 0xc0, 0x46, 0xee, 0xd8, 0xff, 0xff, 0xa9, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x8b, 0xb0, 0x05, 0x93, 0xc7, 0x6c, 0x43, 0x6a, 0x04, 0x00, + 0x03, 0x91, 0x16, 0x00, 0x11, 0x9d, 0x04, 0x93, 0x00, 0x2f, 0x08, 0xd0, + 0x10, 0x02, 0xe1, 0x68, 0x04, 0xf0, 0x5e, 0xfc, 0x00, 0x23, 0x02, 0x00, + 0x19, 0x00, 0x01, 0x20, 0xb8, 0x47, 0x03, 0x9b, 0x4f, 0x49, 0x50, 0x4a, + 0x5b, 0x18, 0x9b, 0xb2, 0x93, 0x42, 0x00, 0xd9, 0x94, 0xe0, 0x05, 0x22, + 0x05, 0x9b, 0x36, 0x01, 0x01, 0x33, 0xf6, 0x18, 0xb7, 0xb2, 0x08, 0xae, + 0x00, 0x92, 0x3b, 0x02, 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, + 0xff, 0xf7, 0xb1, 0xfa, 0x00, 0x28, 0x16, 0xdb, 0x39, 0x22, 0x33, 0x79, + 0x93, 0x43, 0x72, 0x88, 0x00, 0x2a, 0x12, 0xd1, 0x80, 0x2b, 0x6e, 0xd1, + 0xe5, 0x6c, 0x00, 0x2d, 0x04, 0xd0, 0x03, 0x9b, 0x3a, 0x00, 0x05, 0x21, + 0x01, 0x20, 0xa8, 0x47, 0x39, 0x00, 0x20, 0x00, 0x01, 0xf0, 0xc2, 0xff, + 0x00, 0x28, 0x00, 0xdb, 0x3a, 0x48, 0x05, 0x00, 0x6b, 0xe0, 0xc0, 0x2b, + 0xfa, 0xd0, 0x03, 0x9b, 0x38, 0x4a, 0x5e, 0x04, 0x94, 0x46, 0x00, 0x23, + 0x60, 0x6a, 0x76, 0x0c, 0x61, 0x46, 0xc2, 0x5a, 0x0a, 0x40, 0xb2, 0x42, + 0x12, 0xd1, 0x04, 0x9a, 0xd3, 0x5e, 0x00, 0x2b, 0x58, 0xda, 0x30, 0x4d, + 0x36, 0xe0, 0x02, 0x33, 0x9c, 0x42, 0x4f, 0xd1, 0x2b, 0x68, 0x04, 0x98, + 0x59, 0x00, 0x01, 0x33, 0x0a, 0x52, 0x7f, 0x2b, 0x00, 0xd9, 0x00, 0x23, + 0x2b, 0x60, 0x49, 0xe0, 0x80, 0x22, 0x02, 0x33, 0x52, 0x00, 0x93, 0x42, + 0xe2, 0xd1, 0x0e, 0x23, 0x04, 0xaa, 0x9b, 0x18, 0x00, 0x93, 0x00, 0x23, + 0x03, 0x99, 0x1a, 0x00, 0x20, 0x00, 0x01, 0xf0, 0x9b, 0xfe, 0x00, 0x28, + 0x0a, 0xd0, 0x22, 0x4b, 0x98, 0x42, 0x24, 0xd1, 0x69, 0x46, 0x2b, 0x68, + 0x04, 0x9a, 0x89, 0x89, 0x5b, 0x00, 0x99, 0x52, 0x01, 0x22, 0x04, 0xe0, + 0x2b, 0x68, 0x04, 0x9a, 0x5b, 0x00, 0x9e, 0x52, 0x02, 0x00, 0x2b, 0x68, + 0x01, 0x33, 0x7f, 0x2b, 0x00, 0xd9, 0x00, 0x23, 0x2b, 0x60, 0x18, 0x4d, + 0x00, 0x2a, 0x20, 0xd0, 0xe6, 0x6c, 0x00, 0x2e, 0x04, 0xd0, 0x03, 0x9b, + 0x3a, 0x00, 0x04, 0x21, 0x01, 0x20, 0xb0, 0x47, 0x39, 0x00, 0x20, 0x00, + 0x01, 0xf0, 0x66, 0xff, 0x00, 0x28, 0x12, 0xda, 0xa3, 0xe7, 0x00, 0x22, + 0x90, 0x42, 0xe4, 0xda, 0x9f, 0xe7, 0xc0, 0x2b, 0x9c, 0xd0, 0x03, 0x9b, + 0x09, 0x48, 0x5a, 0x04, 0x63, 0x6a, 0x52, 0x0c, 0x5c, 0x1c, 0xff, 0x34, + 0x19, 0x88, 0x01, 0x40, 0x91, 0x42, 0xa8, 0xd1, 0x03, 0x4d, 0x28, 0x00, + 0x0b, 0xb0, 0xf0, 0xbd, 0x00, 0x80, 0xff, 0xff, 0xfe, 0x7f, 0x00, 0x00, + 0xaa, 0xd8, 0xff, 0xff, 0xff, 0x7f, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xa9, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0xc4, 0x6c, 0x87, 0xb0, 0x06, 0x00, + 0x00, 0x2c, 0x04, 0xd0, 0x00, 0x23, 0x1a, 0x00, 0x19, 0x00, 0x18, 0x00, + 0xa0, 0x47, 0x00, 0x24, 0x14, 0x4b, 0x05, 0x94, 0x01, 0x93, 0x04, 0x94, + 0x23, 0x00, 0x03, 0x94, 0x02, 0x94, 0x00, 0x94, 0x22, 0x00, 0x21, 0x00, + 0x30, 0x00, 0x01, 0xf0, 0x5b, 0xfc, 0x0f, 0x4b, 0x05, 0x00, 0x98, 0x42, + 0x15, 0xd0, 0xa0, 0x42, 0x07, 0xd0, 0xf7, 0x6c, 0xa7, 0x42, 0x04, 0xd0, + 0x02, 0x00, 0x23, 0x00, 0x01, 0x21, 0x20, 0x00, 0xb8, 0x47, 0xf4, 0x6c, + 0x00, 0x2c, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, 0x19, 0x00, 0x52, 0x00, + 0x18, 0x00, 0xa0, 0x47, 0x28, 0x00, 0x07, 0xb0, 0xf0, 0xbd, 0x25, 0x00, + 0xf1, 0xe7, 0xc0, 0x46, 0x41, 0x2c, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0xc4, 0x6c, 0x97, 0xb0, 0x05, 0x00, 0x00, 0x2c, 0x04, 0xd0, + 0x00, 0x23, 0x02, 0x20, 0x1a, 0x00, 0x19, 0x00, 0xa0, 0x47, 0x00, 0x23, + 0x07, 0x93, 0x1c, 0x00, 0xb0, 0xe1, 0x80, 0x22, 0x00, 0x21, 0x52, 0x00, + 0x68, 0x6a, 0x04, 0xf0, 0x16, 0xfc, 0x07, 0x9b, 0x1b, 0x02, 0x0f, 0x93, + 0x00, 0x23, 0x0a, 0x93, 0xee, 0x68, 0x0a, 0x9b, 0x9e, 0x42, 0x09, 0xd8, + 0x00, 0x23, 0x06, 0x93, 0x06, 0x9b, 0x07, 0x9a, 0x5b, 0x00, 0xd3, 0x18, + 0x9b, 0xb2, 0x0a, 0x93, 0x00, 0x23, 0x0a, 0xe2, 0xeb, 0x6c, 0x05, 0x93, + 0x00, 0x2b, 0x13, 0xd0, 0x0a, 0x9b, 0x37, 0x01, 0x58, 0x04, 0x39, 0x00, + 0x04, 0xf0, 0x40, 0xfb, 0x31, 0x00, 0x04, 0xf0, 0x3d, 0xfb, 0x39, 0x00, + 0x06, 0x00, 0x0f, 0x98, 0x04, 0xf0, 0x38, 0xfb, 0x00, 0x23, 0x32, 0x18, + 0x19, 0x00, 0x02, 0x20, 0x05, 0x9e, 0xb0, 0x47, 0x0a, 0x9b, 0x1b, 0x01, + 0x01, 0x33, 0x9b, 0xb2, 0x06, 0x93, 0x0a, 0x9b, 0x01, 0x33, 0x1b, 0x01, + 0x0e, 0x93, 0x06, 0x9b, 0x0e, 0x9a, 0x93, 0x42, 0x01, 0xdb, 0x00, 0x23, + 0x69, 0xe1, 0x06, 0x9b, 0x00, 0x22, 0x1e, 0x02, 0x12, 0xab, 0x01, 0x93, + 0x05, 0x23, 0x15, 0x21, 0x00, 0x93, 0x28, 0x00, 0x33, 0x00, 0xff, 0xf7, + 0x86, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0xe5, 0xe0, 0x07, 0x9b, 0x06, 0x99, + 0x00, 0x22, 0x8b, 0x42, 0x07, 0xd8, 0xca, 0x0f, 0x07, 0x9b, 0xc6, 0x49, + 0x06, 0x98, 0x5b, 0x18, 0xd9, 0x17, 0x83, 0x42, 0x4a, 0x41, 0x06, 0x9b, + 0x07, 0x99, 0x58, 0x1a, 0x01, 0x21, 0x43, 0x08, 0x05, 0x93, 0x06, 0x9b, + 0x19, 0x40, 0x89, 0x00, 0x00, 0x2a, 0x0f, 0xd0, 0x12, 0xab, 0x1b, 0x79, + 0x5f, 0xb2, 0x00, 0x2f, 0x0a, 0xda, 0x01, 0x20, 0x03, 0x42, 0x07, 0xd1, + 0x6b, 0x6a, 0x05, 0x98, 0x1b, 0x18, 0x01, 0x20, 0x88, 0x40, 0x1f, 0x78, + 0x07, 0x43, 0x1f, 0x70, 0x12, 0xab, 0x1f, 0x79, 0x7b, 0xb2, 0x9c, 0x46, + 0x00, 0x23, 0x60, 0x46, 0x98, 0x42, 0x00, 0xdb, 0x22, 0xe1, 0x45, 0x20, + 0x07, 0x40, 0x40, 0x2f, 0x00, 0xd0, 0x1d, 0xe1, 0x9a, 0x42, 0x08, 0xd0, + 0x6b, 0x6a, 0x05, 0x9a, 0x02, 0x31, 0x98, 0x18, 0x01, 0x23, 0x8b, 0x40, + 0x02, 0x78, 0x13, 0x43, 0x03, 0x70, 0x2b, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x15, 0x21, 0x33, 0x00, 0x28, 0x00, + 0xff, 0xf7, 0x37, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0x96, 0xe0, 0x2b, 0x6a, + 0x05, 0x93, 0x12, 0xab, 0x5b, 0x88, 0x09, 0x93, 0x00, 0x2b, 0x00, 0xd0, + 0x81, 0xe0, 0x05, 0x9b, 0x2e, 0x33, 0x0b, 0x93, 0x69, 0x23, 0x0c, 0x93, + 0x00, 0x23, 0x08, 0x93, 0x08, 0x9b, 0x0b, 0x9a, 0x5b, 0x00, 0xd6, 0x5a, + 0x07, 0x9a, 0x00, 0x23, 0xb2, 0x42, 0x06, 0xd8, 0x13, 0x00, 0x96, 0x4a, + 0xf1, 0x0f, 0x9a, 0x18, 0xd3, 0x17, 0xb2, 0x42, 0x4b, 0x41, 0x94, 0x4a, + 0x94, 0x49, 0xb2, 0x18, 0x92, 0xb2, 0x8a, 0x42, 0x05, 0xd9, 0x00, 0x2b, + 0x00, 0xd1, 0x8b, 0xe0, 0x33, 0x07, 0x00, 0xd0, 0x92, 0xe0, 0x16, 0x27, + 0x09, 0x9b, 0x08, 0x9a, 0x28, 0x00, 0x9e, 0x18, 0x05, 0x9a, 0x05, 0x9b, + 0x51, 0x78, 0x1b, 0x78, 0x09, 0x02, 0x19, 0x43, 0x0c, 0xab, 0xff, 0x18, + 0xb6, 0xb2, 0x49, 0x04, 0x00, 0x23, 0x49, 0x0c, 0x00, 0x97, 0x32, 0x00, + 0x01, 0xf0, 0x2a, 0xfd, 0x85, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x51, 0xd1, + 0x00, 0x23, 0x3b, 0x80, 0x3b, 0x88, 0x00, 0x2b, 0x16, 0xd1, 0xfc, 0x20, + 0x05, 0x99, 0x05, 0x9a, 0x49, 0x78, 0x12, 0x78, 0x09, 0x02, 0x11, 0x43, + 0x14, 0xaa, 0x10, 0x71, 0x01, 0x20, 0x49, 0x04, 0x49, 0x0c, 0x11, 0x80, + 0x56, 0x80, 0x02, 0x90, 0x03, 0x97, 0x01, 0x93, 0x00, 0x93, 0x28, 0x00, + 0x01, 0xf0, 0x7c, 0xfd, 0x04, 0x1e, 0x37, 0xdb, 0x16, 0x23, 0x0c, 0xaa, + 0x05, 0x99, 0x9b, 0x18, 0x05, 0x9a, 0x49, 0x78, 0x12, 0x78, 0x09, 0x02, + 0x11, 0x43, 0x80, 0x22, 0x12, 0x02, 0x11, 0x43, 0x06, 0x9a, 0x1b, 0x88, + 0x28, 0x00, 0x00, 0x92, 0x32, 0x00, 0xff, 0xf7, 0x41, 0xfa, 0x6d, 0x4b, + 0x04, 0x00, 0xc3, 0x18, 0xee, 0x6c, 0x02, 0x2b, 0x28, 0xd8, 0x00, 0x2e, + 0x09, 0xd0, 0x05, 0x9a, 0x05, 0x9b, 0x52, 0x78, 0x1b, 0x78, 0x12, 0x02, + 0x1a, 0x43, 0x06, 0x21, 0x00, 0x23, 0x02, 0x20, 0xb0, 0x47, 0x06, 0x99, + 0x28, 0x00, 0x01, 0xf0, 0xd3, 0xfd, 0x04, 0x00, 0x25, 0xe0, 0x7c, 0x22, + 0x09, 0x9b, 0x0c, 0x92, 0x53, 0x43, 0x13, 0x3b, 0x9b, 0xb2, 0x09, 0x93, + 0x05, 0x9b, 0x08, 0x33, 0x0b, 0x93, 0x77, 0xe7, 0x00, 0x28, 0xad, 0xda, + 0xee, 0x6c, 0x00, 0x2e, 0x00, 0xd1, 0x80, 0xe0, 0x00, 0x23, 0x22, 0x00, + 0x01, 0x21, 0x02, 0x20, 0xb0, 0x47, 0x7a, 0xe0, 0x00, 0x2e, 0x0c, 0xd0, + 0x05, 0x9b, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, 0x13, 0x43, 0x05, 0x9a, + 0x11, 0x78, 0x52, 0x78, 0x12, 0x02, 0x0a, 0x43, 0x02, 0x21, 0x08, 0x00, + 0xb0, 0x47, 0x00, 0x2c, 0xe4, 0xdb, 0x01, 0x23, 0x08, 0x9a, 0x01, 0x32, + 0x08, 0x92, 0x00, 0x2b, 0x4c, 0xd1, 0x0c, 0x99, 0x8a, 0x42, 0x00, 0xd0, + 0x52, 0xe7, 0x47, 0xe0, 0x05, 0x22, 0x14, 0xaf, 0x00, 0x92, 0x33, 0x02, + 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xff, 0xf7, 0x6d, 0xf8, + 0x04, 0x1e, 0xcd, 0xdb, 0x12, 0xab, 0x1a, 0x88, 0x39, 0x88, 0x41, 0x4b, + 0x13, 0x40, 0x99, 0x42, 0x0b, 0xd1, 0x09, 0x9b, 0x08, 0x98, 0x79, 0x88, + 0x1b, 0x18, 0x99, 0x42, 0x05, 0xd1, 0x7a, 0x21, 0x3b, 0x79, 0x8b, 0x43, + 0x84, 0x2b, 0x00, 0xd1, 0x7d, 0xe0, 0x16, 0x27, 0x08, 0x99, 0x09, 0x9b, + 0x52, 0x04, 0x5b, 0x18, 0x9b, 0xb2, 0x0d, 0x93, 0x0c, 0xab, 0xff, 0x18, + 0x51, 0x0c, 0x33, 0x00, 0x00, 0x97, 0x0d, 0x9a, 0x28, 0x00, 0x01, 0xf0, + 0x7d, 0xfc, 0x2f, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x37, 0xd1, 0x00, 0x23, + 0x3b, 0x80, 0x3b, 0x88, 0x12, 0xae, 0x31, 0x88, 0x00, 0x2b, 0x33, 0xd1, + 0xec, 0x6c, 0x00, 0x2c, 0x03, 0xd0, 0x0a, 0x00, 0x02, 0x20, 0x06, 0x21, + 0xa0, 0x47, 0x31, 0x88, 0x28, 0x00, 0xff, 0xf7, 0x8d, 0xf9, 0x04, 0x1e, + 0x92, 0xdb, 0x00, 0x23, 0x06, 0x9a, 0x01, 0x32, 0x92, 0xb2, 0x06, 0x92, + 0x00, 0x2b, 0x00, 0xd1, 0x8f, 0xe6, 0x0a, 0x9a, 0x01, 0x32, 0x92, 0xb2, + 0x0a, 0x92, 0x00, 0x2b, 0x00, 0xd1, 0x59, 0xe6, 0xeb, 0x68, 0x07, 0x9a, + 0x1b, 0x01, 0x9a, 0x42, 0x00, 0xd2, 0x48, 0xe6, 0x00, 0x2c, 0x00, 0xd0, + 0x7a, 0xe7, 0xed, 0x6c, 0x00, 0x2d, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, + 0x19, 0x00, 0x52, 0x00, 0x02, 0x20, 0xa8, 0x47, 0x20, 0x00, 0x17, 0xb0, + 0xf0, 0xbd, 0x00, 0x28, 0xc7, 0xda, 0x6b, 0xe7, 0x06, 0x9a, 0x28, 0x00, + 0x00, 0x92, 0x0d, 0x9a, 0xff, 0xf7, 0x82, 0xf9, 0x0d, 0x4b, 0x04, 0x00, + 0xc3, 0x18, 0xef, 0x6c, 0x02, 0x2b, 0x19, 0xd8, 0x32, 0x88, 0x00, 0x2f, + 0x03, 0xd0, 0x00, 0x23, 0x06, 0x21, 0x02, 0x20, 0xb8, 0x47, 0x12, 0xab, + 0x19, 0x88, 0x28, 0x00, 0xff, 0xf7, 0x4c, 0xf9, 0x43, 0xe7, 0xc0, 0x46, + 0xff, 0x01, 0x00, 0x00, 0xff, 0xdf, 0xff, 0xff, 0xfd, 0xdf, 0x00, 0x00, + 0xee, 0xd8, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, 0xff, 0x7f, 0xff, 0xff, + 0x00, 0x2f, 0x00, 0xd1, 0x5b, 0xe7, 0x02, 0x21, 0x73, 0x88, 0x32, 0x88, + 0x08, 0x00, 0xb8, 0x47, 0x55, 0xe7, 0x01, 0x21, 0x07, 0x9b, 0xf7, 0x1a, + 0x6b, 0x6a, 0x7f, 0x08, 0x0e, 0x40, 0xb6, 0x00, 0xdb, 0x5d, 0x76, 0x18, + 0x33, 0x41, 0x0b, 0x40, 0x16, 0xd0, 0xec, 0x6c, 0x00, 0x2c, 0x03, 0xd0, + 0x00, 0x23, 0x05, 0x31, 0x02, 0x20, 0xa0, 0x47, 0x12, 0xab, 0x19, 0x88, + 0x28, 0x00, 0xff, 0xf7, 0x1d, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0x21, 0xe7, + 0x06, 0x99, 0x28, 0x00, 0x01, 0xf0, 0xe2, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0x1a, 0xe7, 0x01, 0x23, 0x01, 0x21, 0xb1, 0x40, 0x6a, 0x6a, 0xd7, 0x19, + 0x3a, 0x78, 0x0a, 0x43, 0x3a, 0x70, 0x2d, 0xe7, 0x01, 0x23, 0x08, 0x93, + 0x06, 0x9a, 0x6b, 0x6a, 0x9b, 0x5c, 0x08, 0x9a, 0x92, 0x00, 0x13, 0x41, + 0x07, 0x22, 0x1a, 0x40, 0x09, 0x92, 0x01, 0x2a, 0x00, 0xd0, 0x93, 0xe0, + 0x08, 0x9a, 0x0a, 0x9b, 0x12, 0xae, 0x9b, 0x18, 0x05, 0x22, 0x9b, 0xb2, + 0x05, 0x93, 0x00, 0x92, 0x1b, 0x02, 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, + 0x28, 0x00, 0xfe, 0xf7, 0x92, 0xff, 0x04, 0x1e, 0x00, 0xda, 0xf1, 0xe6, + 0x16, 0x27, 0x0c, 0xab, 0xff, 0x18, 0x11, 0xab, 0x72, 0x88, 0x31, 0x88, + 0x28, 0x00, 0x00, 0x93, 0x3b, 0x00, 0xff, 0xf7, 0xa5, 0xf8, 0x04, 0x1e, + 0x61, 0xd1, 0x80, 0x22, 0x3b, 0x88, 0x92, 0x01, 0x93, 0x42, 0x20, 0xd8, + 0x1a, 0x07, 0x1e, 0xd0, 0x05, 0x22, 0x14, 0xaf, 0x00, 0x92, 0x1b, 0x02, + 0x02, 0x00, 0x01, 0x97, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x71, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0xd0, 0xe6, 0x38, 0x4a, 0x33, 0x88, 0x13, 0x40, + 0x3a, 0x88, 0x93, 0x42, 0x04, 0xd1, 0x78, 0x22, 0x3b, 0x79, 0x93, 0x43, + 0x84, 0x2b, 0x45, 0xd0, 0x16, 0x23, 0x0c, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0x05, 0x9a, 0x93, 0x42, 0x4e, 0xd0, 0x11, 0xab, 0x1b, 0x88, 0x12, 0xae, + 0x72, 0x88, 0x31, 0x88, 0x28, 0x00, 0x00, 0x93, 0x05, 0x9b, 0xff, 0xf7, + 0xd1, 0xf8, 0x2b, 0x4b, 0x04, 0x00, 0xc3, 0x18, 0xef, 0x6c, 0x02, 0x2b, + 0x45, 0xd8, 0x00, 0x2f, 0x04, 0xd0, 0x32, 0x88, 0x00, 0x23, 0x06, 0x21, + 0x02, 0x20, 0xb8, 0x47, 0x05, 0x99, 0x28, 0x00, 0x01, 0xf0, 0x68, 0xfc, + 0x04, 0x1e, 0x00, 0xda, 0xa0, 0xe6, 0x31, 0x88, 0x28, 0x00, 0xff, 0xf7, + 0x95, 0xf8, 0x04, 0x00, 0x00, 0x2c, 0x00, 0xda, 0x98, 0xe6, 0x06, 0x9b, + 0x01, 0x33, 0x06, 0x93, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x0d, 0xe7, + 0x06, 0x9b, 0x1a, 0x00, 0x80, 0x23, 0x5b, 0x00, 0x9a, 0x42, 0x00, 0xd0, + 0x66, 0xe5, 0x80, 0x22, 0x92, 0x00, 0x94, 0x46, 0x07, 0x9b, 0x63, 0x44, + 0x9b, 0xb2, 0x07, 0x93, 0xfe, 0xe6, 0x13, 0x4b, 0x98, 0x42, 0x0c, 0xd1, + 0xec, 0x6c, 0x00, 0x2c, 0x04, 0xd0, 0x00, 0x23, 0x05, 0x9a, 0x05, 0x21, + 0x02, 0x20, 0xa0, 0x47, 0x05, 0x99, 0x28, 0x00, 0x01, 0xf0, 0x38, 0xfc, + 0x04, 0x00, 0x00, 0x2c, 0x00, 0xda, 0x6f, 0xe6, 0x08, 0x9b, 0x01, 0x2b, + 0x00, 0xd0, 0x59, 0xe7, 0x00, 0x23, 0x09, 0x93, 0xcf, 0xe7, 0x00, 0x2f, + 0xca, 0xd0, 0x02, 0x21, 0x73, 0x88, 0x32, 0x88, 0x08, 0x00, 0xb8, 0x47, + 0xc4, 0xe7, 0xc0, 0x46, 0xff, 0x7f, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, + 0xee, 0xd8, 0xff, 0xff, 0x80, 0x22, 0xf0, 0xb5, 0x06, 0x00, 0x89, 0xb0, + 0x00, 0x21, 0x52, 0x00, 0x40, 0x6a, 0x04, 0xf0, 0x38, 0xf9, 0x00, 0x21, + 0xf4, 0x6c, 0x07, 0x91, 0x8c, 0x42, 0x03, 0xd0, 0x0b, 0x00, 0x0a, 0x00, + 0x01, 0x20, 0xa0, 0x47, 0x00, 0x24, 0x07, 0xab, 0x03, 0x93, 0x14, 0x4b, + 0x05, 0x94, 0x01, 0x93, 0x04, 0x94, 0x23, 0x00, 0x02, 0x94, 0x00, 0x94, + 0x22, 0x00, 0x21, 0x00, 0x30, 0x00, 0x01, 0xf0, 0x2f, 0xf9, 0x0f, 0x4b, + 0x05, 0x00, 0x98, 0x42, 0x15, 0xd0, 0xa0, 0x42, 0x07, 0xd0, 0xf7, 0x6c, + 0xa7, 0x42, 0x04, 0xd0, 0x01, 0x21, 0x02, 0x00, 0x23, 0x00, 0x08, 0x00, + 0xb8, 0x47, 0xf4, 0x6c, 0x00, 0x2c, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, + 0x19, 0x00, 0x52, 0x00, 0x01, 0x20, 0xa0, 0x47, 0x28, 0x00, 0x09, 0xb0, + 0xf0, 0xbd, 0x25, 0x00, 0xf1, 0xe7, 0xc0, 0x46, 0xe9, 0x31, 0x00, 0x00, + 0xa8, 0xd8, 0xff, 0xff, 0xf8, 0xb5, 0x06, 0x00, 0x0c, 0x00, 0x01, 0xf0, + 0xcf, 0xf9, 0x05, 0x1e, 0x0c, 0xdb, 0x24, 0x01, 0xa4, 0xb2, 0x27, 0x00, + 0x10, 0x37, 0xbf, 0xb2, 0x21, 0x00, 0x01, 0x34, 0x30, 0x00, 0xa4, 0xb2, + 0xfe, 0xf7, 0x96, 0xfe, 0xbc, 0x42, 0xf7, 0xd1, 0x28, 0x00, 0xf8, 0xbd, + 0xf0, 0xb5, 0x05, 0x00, 0x0f, 0x00, 0x00, 0x24, 0xc3, 0x68, 0x87, 0xb0, + 0x03, 0x93, 0x03, 0x6a, 0x02, 0x93, 0xa2, 0xb2, 0x04, 0x92, 0x03, 0x9a, + 0x23, 0x03, 0xa2, 0x42, 0x01, 0xd1, 0x1e, 0x48, 0x35, 0xe0, 0x2a, 0x6a, + 0x14, 0x21, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x28, 0x00, + 0x00, 0x22, 0xfe, 0xf7, 0x84, 0xfe, 0x02, 0x99, 0x18, 0x4e, 0x0b, 0x00, + 0x1e, 0x33, 0x05, 0x93, 0x00, 0x23, 0xb4, 0x46, 0x1a, 0x00, 0x98, 0x42, + 0x0b, 0xd0, 0x01, 0x28, 0x13, 0xd9, 0x01, 0x34, 0x00, 0x28, 0x1c, 0xd1, + 0xdd, 0xe7, 0x08, 0x88, 0x00, 0x28, 0x06, 0xd1, 0x01, 0x32, 0x92, 0xb2, + 0x02, 0x31, 0x05, 0x98, 0x81, 0x42, 0xf6, 0xd1, 0x05, 0xe0, 0x60, 0x45, + 0x03, 0xd1, 0x01, 0x33, 0x9b, 0xb2, 0xbb, 0x42, 0xf4, 0xd9, 0xd1, 0x18, + 0x0f, 0x29, 0x0a, 0xd1, 0xbb, 0x42, 0x08, 0xd8, 0xeb, 0x6b, 0x04, 0x99, + 0x9a, 0x1a, 0xea, 0x63, 0x28, 0x00, 0xff, 0xf7, 0xa3, 0xff, 0x07, 0xb0, + 0xf0, 0xbd, 0x01, 0x34, 0xbd, 0xe7, 0xc0, 0x46, 0xd3, 0xd8, 0xff, 0xff, + 0xff, 0xff, 0x00, 0x00, 0xf7, 0xb5, 0x80, 0x22, 0x04, 0x6a, 0x52, 0x00, + 0x0b, 0x03, 0x00, 0x92, 0x14, 0x21, 0x00, 0x22, 0x01, 0x94, 0x05, 0x00, + 0x26, 0x00, 0xfe, 0xf7, 0x42, 0xfe, 0x00, 0x22, 0x23, 0x00, 0x1e, 0x36, + 0x11, 0x00, 0x0b, 0x4f, 0x90, 0x42, 0x0d, 0xd0, 0xab, 0x6b, 0x9a, 0x1a, + 0xeb, 0x6b, 0xaa, 0x63, 0x59, 0x1a, 0xe9, 0x63, 0xfe, 0xbd, 0x1c, 0x88, + 0xbc, 0x42, 0x02, 0xd0, 0x00, 0x2c, 0x04, 0xd1, 0x01, 0x31, 0x02, 0x33, + 0x9e, 0x42, 0xf6, 0xd1, 0xee, 0xe7, 0x01, 0x32, 0xf9, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xf0, 0xb5, 0x1d, 0x00, 0xc3, 0x68, 0x93, 0xb0, + 0x05, 0x93, 0x03, 0x6a, 0x04, 0x00, 0x0c, 0x93, 0x05, 0x9b, 0x0f, 0x00, + 0x08, 0x92, 0x03, 0x93, 0x29, 0x2b, 0x01, 0xd9, 0x29, 0x23, 0x03, 0x93, + 0x00, 0x26, 0x80, 0x22, 0x08, 0x9b, 0x52, 0x00, 0x1e, 0x60, 0xff, 0x21, + 0x60, 0x6a, 0x04, 0xf0, 0x56, 0xf8, 0x63, 0x6a, 0x02, 0x96, 0x06, 0x93, + 0x03, 0x9b, 0x06, 0x9a, 0x5b, 0x00, 0xd3, 0x18, 0x03, 0x22, 0x09, 0x93, + 0x03, 0x33, 0x93, 0x43, 0x0a, 0x93, 0x06, 0x9b, 0x0a, 0x9a, 0x3b, 0x60, + 0x6b, 0x42, 0x5d, 0x41, 0x32, 0x23, 0x6d, 0x42, 0x2b, 0x40, 0x0f, 0x93, + 0x03, 0x9b, 0x9b, 0x00, 0x9b, 0x18, 0x0e, 0x93, 0x6a, 0x46, 0x12, 0x89, + 0x02, 0x9b, 0x0d, 0x92, 0x05, 0x99, 0x02, 0x9a, 0x1b, 0x03, 0x8a, 0x42, + 0x01, 0xd1, 0x00, 0x20, 0x4f, 0xe0, 0x22, 0x6a, 0x14, 0x21, 0x01, 0x92, + 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x20, 0x00, 0x00, 0x22, 0xfe, 0xf7, + 0xde, 0xfd, 0x0c, 0x9b, 0x00, 0x25, 0x19, 0x00, 0x2f, 0x00, 0x1e, 0x31, + 0x3a, 0x4e, 0xa8, 0x42, 0x47, 0xd0, 0x01, 0x28, 0x3b, 0xd1, 0x0e, 0x26, + 0x6b, 0x46, 0x0e, 0xaa, 0xb6, 0x18, 0x02, 0x22, 0x1b, 0x89, 0x15, 0x21, + 0x1b, 0x03, 0x00, 0x92, 0xfe, 0x33, 0x01, 0x96, 0x00, 0x22, 0x20, 0x00, + 0xfe, 0xf7, 0xc5, 0xfd, 0x00, 0x28, 0x2a, 0xdb, 0x23, 0x1d, 0xda, 0x8f, + 0x33, 0x88, 0x9a, 0x42, 0x35, 0xd9, 0xd3, 0x1a, 0x05, 0x22, 0x57, 0x43, + 0x0f, 0x9a, 0x9b, 0xb2, 0x53, 0x43, 0x7d, 0x1b, 0xeb, 0x18, 0x07, 0x93, + 0x00, 0x23, 0x06, 0x99, 0x27, 0x4d, 0x03, 0x9a, 0x93, 0x42, 0x0b, 0xda, + 0x0a, 0x9e, 0x9a, 0x00, 0x92, 0x19, 0x0e, 0x88, 0x0b, 0x91, 0xae, 0x42, + 0x22, 0xd1, 0x6b, 0x46, 0x9b, 0x8e, 0x0b, 0x80, 0x07, 0x9b, 0x13, 0x60, + 0x08, 0x9b, 0x08, 0x9a, 0x1b, 0x68, 0x04, 0x93, 0x01, 0x33, 0x13, 0x60, + 0x02, 0x9b, 0x01, 0x33, 0x02, 0x93, 0x00, 0x28, 0xa4, 0xd0, 0x13, 0xb0, + 0xf0, 0xbd, 0x1a, 0x88, 0xb2, 0x42, 0xbe, 0xd0, 0x00, 0x2a, 0x05, 0xd1, + 0x01, 0x37, 0xbf, 0xb2, 0x02, 0x33, 0x99, 0x42, 0xf5, 0xd1, 0xb6, 0xe7, + 0x01, 0x35, 0xad, 0xb2, 0xf8, 0xe7, 0x9b, 0x1a, 0xdb, 0x43, 0xc7, 0xe7, + 0x0b, 0x99, 0x16, 0x68, 0x07, 0x9f, 0x02, 0x31, 0xbe, 0x42, 0x19, 0xda, + 0x03, 0x99, 0x09, 0x9d, 0x02, 0x39, 0x04, 0x91, 0x0e, 0x99, 0x04, 0x9e, + 0x02, 0x3d, 0x0f, 0x1f, 0xb3, 0x42, 0x04, 0xdd, 0x69, 0x46, 0x0b, 0x9b, + 0x89, 0x8e, 0x19, 0x80, 0xca, 0xe7, 0xae, 0x1e, 0x08, 0x39, 0x36, 0x88, + 0x09, 0x68, 0x2e, 0x80, 0x39, 0x60, 0x04, 0x99, 0x01, 0x39, 0x04, 0x91, + 0x39, 0x00, 0xea, 0xe7, 0x01, 0x33, 0xb0, 0xe7, 0xff, 0xff, 0x00, 0x00, + 0xf0, 0xb5, 0x05, 0x00, 0x03, 0x6a, 0x9b, 0xb0, 0x0f, 0x93, 0x43, 0x6a, + 0x0c, 0x00, 0x14, 0x22, 0x00, 0x21, 0x15, 0xa8, 0x0a, 0x93, 0x03, 0xf0, + 0x9e, 0xff, 0x2b, 0x8a, 0xa3, 0x42, 0x06, 0xd1, 0x60, 0x1c, 0xe9, 0x68, + 0x03, 0xf0, 0x64, 0xff, 0x00, 0x23, 0x29, 0x82, 0x6b, 0x61, 0x23, 0x01, + 0x01, 0x33, 0x9b, 0xb2, 0x11, 0x93, 0x0f, 0x9b, 0x24, 0x03, 0x1b, 0x19, + 0x10, 0x93, 0x00, 0x23, 0x08, 0x93, 0x8f, 0xe1, 0x0c, 0x9a, 0x10, 0x9b, + 0x14, 0x21, 0x9b, 0x1a, 0x0d, 0x93, 0x2b, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x28, 0x00, 0x0d, 0x9b, 0xfe, 0xf7, + 0x30, 0xfd, 0x04, 0x00, 0x00, 0x2c, 0x07, 0xd1, 0x07, 0x9b, 0x0e, 0x9a, + 0x9b, 0x1a, 0x7f, 0x2b, 0x02, 0xdc, 0x07, 0x9b, 0x0e, 0x2b, 0x01, 0xdd, + 0x3b, 0x00, 0x88, 0xe0, 0x07, 0x9b, 0x0c, 0x9a, 0x5b, 0x00, 0xd3, 0x5a, + 0x07, 0x9a, 0x09, 0x93, 0x11, 0x9b, 0x9b, 0x18, 0x9b, 0xb2, 0x15, 0xaa, + 0x08, 0x93, 0x13, 0x78, 0x01, 0x2b, 0x15, 0xd0, 0x00, 0x2b, 0x04, 0xd0, + 0x02, 0x2b, 0x00, 0xd1, 0x8f, 0xe0, 0x23, 0x00, 0x6d, 0xe0, 0x6b, 0x46, + 0x24, 0x21, 0x59, 0x5e, 0x3b, 0x00, 0x00, 0x29, 0x00, 0xdc, 0x66, 0xe0, + 0x6b, 0x46, 0x9b, 0x8c, 0x17, 0x74, 0x53, 0x80, 0x6b, 0x46, 0x1b, 0x8c, + 0x13, 0x81, 0xee, 0xe7, 0x52, 0x88, 0x09, 0x99, 0x3b, 0x00, 0x8a, 0x42, + 0x59, 0xd1, 0x05, 0x22, 0x08, 0x9b, 0x13, 0xae, 0x00, 0x92, 0x1b, 0x02, + 0x22, 0x00, 0x01, 0x96, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0xef, 0xfc, + 0x04, 0x1e, 0x2d, 0xdb, 0x73, 0x88, 0x00, 0x20, 0x68, 0x2b, 0x05, 0xd9, + 0x69, 0x3b, 0x18, 0x00, 0x7c, 0x21, 0x03, 0xf0, 0x75, 0xfe, 0x01, 0x30, + 0x15, 0xab, 0x9e, 0x88, 0x86, 0x42, 0x3d, 0xd1, 0x13, 0xab, 0x1a, 0x79, + 0x7f, 0x2a, 0x1e, 0xd9, 0x1a, 0x22, 0x0c, 0xa9, 0x52, 0x18, 0x02, 0x92, + 0x08, 0x9a, 0x00, 0x93, 0x01, 0x92, 0x00, 0x22, 0x09, 0x9b, 0x11, 0x00, + 0x28, 0x00, 0x01, 0xf0, 0x25, 0xfa, 0x04, 0x1e, 0x0c, 0xdb, 0x2b, 0x6a, + 0x00, 0x22, 0x01, 0x93, 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x14, 0x21, + 0x0d, 0x9b, 0x28, 0x00, 0xfe, 0xf7, 0xc1, 0xfc, 0x04, 0x1e, 0x0e, 0xda, + 0x20, 0x00, 0x1b, 0xb0, 0xf0, 0xbd, 0x08, 0x99, 0x28, 0x00, 0x01, 0xf0, + 0xdf, 0xf9, 0x04, 0x1e, 0xf6, 0xdb, 0x1a, 0x23, 0x0c, 0xaa, 0x9b, 0x18, + 0x01, 0x22, 0x52, 0x42, 0x1a, 0x80, 0x13, 0xab, 0x58, 0x88, 0x1a, 0x23, + 0x0c, 0xaa, 0x9b, 0x18, 0x1b, 0x88, 0x09, 0x93, 0x00, 0x2e, 0x1c, 0xd1, + 0x17, 0x30, 0x6a, 0x46, 0x0a, 0x9b, 0x92, 0x8c, 0x40, 0x00, 0x1a, 0x52, + 0x3b, 0x00, 0x07, 0x9a, 0x01, 0x32, 0x07, 0x92, 0x00, 0x2b, 0x00, 0xd0, + 0x6a, 0xe7, 0x0b, 0x9a, 0x01, 0x32, 0x0b, 0x92, 0x00, 0x2b, 0x6b, 0xd0, + 0x0e, 0x9b, 0x80, 0x33, 0x0e, 0x93, 0x0c, 0x9b, 0x01, 0x3b, 0xff, 0x3b, + 0x0c, 0x93, 0x00, 0x2c, 0x00, 0xd1, 0x2d, 0xe1, 0xca, 0xe7, 0x68, 0x28, + 0x01, 0xd8, 0x04, 0x30, 0xdf, 0xe7, 0x69, 0x38, 0x7c, 0x21, 0x03, 0xf0, + 0x99, 0xfe, 0x08, 0x1d, 0xd9, 0xe7, 0x09, 0x9b, 0x98, 0x4a, 0x99, 0x49, + 0x9a, 0x18, 0x92, 0xb2, 0x3b, 0x00, 0x8a, 0x42, 0xd7, 0xd8, 0x05, 0x22, + 0x08, 0x9b, 0x13, 0xae, 0x00, 0x92, 0x1b, 0x02, 0x22, 0x00, 0x01, 0x96, + 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x6d, 0xfc, 0x04, 0x1e, 0xab, 0xdb, + 0x33, 0x79, 0x7f, 0x2b, 0x2b, 0xd9, 0x1a, 0x23, 0x0c, 0xaa, 0x9b, 0x18, + 0x00, 0x22, 0x02, 0x93, 0x08, 0x9b, 0x00, 0x96, 0x01, 0x93, 0x11, 0x00, + 0x09, 0x9b, 0x28, 0x00, 0x01, 0xf0, 0xb2, 0xf9, 0x04, 0x1e, 0x00, 0xda, + 0x98, 0xe7, 0x00, 0x24, 0x0c, 0xab, 0x02, 0x94, 0x5b, 0x8b, 0x13, 0xa9, + 0x01, 0x93, 0x4b, 0x88, 0x03, 0x22, 0x00, 0x93, 0x28, 0x00, 0x09, 0x9b, + 0x01, 0xf0, 0x20, 0xfa, 0x2b, 0x6a, 0x22, 0x00, 0x01, 0x93, 0x80, 0x23, + 0x5b, 0x00, 0x00, 0x93, 0x14, 0x21, 0x0d, 0x9b, 0x28, 0x00, 0xfe, 0xf7, + 0x40, 0xfc, 0x04, 0x00, 0x00, 0x2c, 0x9b, 0xda, 0x7c, 0xe7, 0x08, 0x99, + 0x28, 0x00, 0x01, 0xf0, 0x5f, 0xf9, 0x04, 0x1e, 0xf6, 0xd1, 0x00, 0x21, + 0x08, 0x9b, 0x02, 0x91, 0x01, 0x93, 0x13, 0xab, 0x5b, 0x88, 0x02, 0x22, + 0x00, 0x93, 0x28, 0x00, 0x09, 0x9b, 0x01, 0xf0, 0xff, 0xf9, 0x87, 0xe7, + 0x00, 0x2c, 0x00, 0xd1, 0xcc, 0xe0, 0x65, 0xe7, 0x0b, 0x7c, 0x00, 0x2b, + 0x70, 0xd0, 0x07, 0x9b, 0x05, 0x22, 0xcb, 0x60, 0x01, 0x23, 0x0b, 0x70, + 0x08, 0x9b, 0x13, 0xaf, 0x00, 0x92, 0x1b, 0x02, 0x01, 0x97, 0x32, 0x00, + 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x13, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0x50, 0xe7, 0x78, 0x88, 0x37, 0x00, 0x68, 0x28, 0x05, 0xd9, 0x69, 0x38, + 0x7c, 0x21, 0x03, 0xf0, 0x99, 0xfd, 0x01, 0x30, 0x87, 0xb2, 0x80, 0x23, + 0x15, 0xae, 0x71, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1a, 0x23, 0x0c, 0xaa, + 0x9b, 0x18, 0xb7, 0x80, 0x3a, 0x00, 0x00, 0x93, 0x28, 0x00, 0x00, 0x23, + 0x01, 0xf0, 0x2c, 0xf8, 0x56, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x0c, 0xd1, + 0x31, 0x89, 0x28, 0x00, 0x01, 0xf0, 0x16, 0xf9, 0x04, 0x1e, 0x00, 0xda, + 0x2c, 0xe7, 0x00, 0x23, 0x33, 0x70, 0x00, 0x2c, 0x00, 0xd0, 0x27, 0xe7, + 0x71, 0xe0, 0x00, 0x28, 0x00, 0xda, 0x23, 0xe7, 0x6a, 0x6a, 0x0c, 0xab, + 0x5b, 0x8b, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x1b, 0x02, + 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0xd6, 0xfb, 0x04, 0x1e, + 0x00, 0xda, 0x13, 0xe7, 0x0a, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x13, 0xd4, + 0x5a, 0xb2, 0x00, 0x2a, 0x12, 0xda, 0x9a, 0x07, 0x12, 0xd4, 0x04, 0x22, + 0x1a, 0x40, 0x11, 0xd1, 0x0a, 0x9b, 0x99, 0x78, 0xdb, 0x78, 0x1b, 0x02, + 0x0b, 0x43, 0xbb, 0x42, 0x0c, 0xd1, 0x0c, 0xab, 0x5b, 0x8b, 0x07, 0x92, + 0xf3, 0x80, 0xd0, 0xe7, 0x39, 0x4c, 0xf9, 0xe6, 0x39, 0x4c, 0xf7, 0xe6, + 0x39, 0x4c, 0xf5, 0xe6, 0x39, 0x4c, 0xf3, 0xe6, 0x39, 0x4c, 0xf1, 0xe6, + 0x02, 0x22, 0x0a, 0x70, 0x07, 0x93, 0x38, 0xe0, 0x80, 0x22, 0x00, 0x26, + 0xcb, 0x68, 0x12, 0x02, 0x07, 0x93, 0x4b, 0x88, 0x0e, 0x70, 0x09, 0x93, + 0x1a, 0x43, 0xcb, 0x88, 0x89, 0x88, 0x68, 0x6a, 0x13, 0xaf, 0xb1, 0x42, + 0x0b, 0xd1, 0x00, 0x90, 0x04, 0x97, 0x03, 0x91, 0x02, 0x91, 0x01, 0x91, + 0x28, 0x00, 0x01, 0xf0, 0x93, 0xfa, 0x04, 0x00, 0xb0, 0x42, 0xa8, 0xda, + 0xd2, 0xe6, 0x01, 0x93, 0x02, 0x97, 0x13, 0x00, 0x00, 0x96, 0x02, 0x00, + 0x31, 0x00, 0x28, 0x00, 0x01, 0xf0, 0xe0, 0xf8, 0x04, 0x1e, 0x00, 0xda, + 0xc6, 0xe6, 0x02, 0x96, 0x3b, 0x88, 0x69, 0x6a, 0x01, 0x93, 0x0a, 0x9b, + 0x28, 0x00, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, 0x13, 0x43, 0x00, 0x93, + 0x32, 0x00, 0x09, 0x9b, 0x01, 0xf0, 0x4c, 0xf9, 0x8b, 0xe7, 0x03, 0x23, + 0x0b, 0x70, 0x15, 0xab, 0x1a, 0x78, 0x00, 0x24, 0x03, 0x2a, 0x00, 0xd1, + 0xae, 0xe6, 0x7f, 0x22, 0x01, 0x27, 0x1c, 0x74, 0x07, 0x9b, 0xdb, 0x17, + 0x13, 0x40, 0x07, 0x9a, 0x9b, 0x18, 0xdb, 0x11, 0x0b, 0x93, 0xdb, 0x01, + 0x0e, 0x93, 0x0b, 0x9b, 0x0f, 0x9a, 0x1b, 0x02, 0xd3, 0x1a, 0x0c, 0x93, + 0x0b, 0x9b, 0x00, 0x2b, 0x00, 0xdc, 0x19, 0xe6, 0x15, 0xa9, 0x0e, 0x78, + 0x01, 0x2e, 0xa7, 0xd0, 0x00, 0x2e, 0x00, 0xd1, 0x2c, 0xe7, 0x02, 0x2e, + 0xd9, 0xd0, 0x00, 0x23, 0x9e, 0xe7, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, + 0xfe, 0x7f, 0x00, 0x00, 0xee, 0xd8, 0xff, 0xff, 0xe4, 0xd8, 0xff, 0xff, + 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, + 0xe3, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0f, 0x26, 0xc3, 0x68, 0x87, 0xb0, + 0x5e, 0x43, 0x83, 0x6b, 0x04, 0x00, 0xf6, 0x1a, 0xc3, 0x6b, 0x1e, 0x3e, + 0xf5, 0x1a, 0x43, 0x6b, 0x0f, 0x00, 0x03, 0x2b, 0x04, 0xd9, 0xfb, 0x23, + 0x6b, 0x43, 0x00, 0x20, 0x8b, 0x42, 0x19, 0xdc, 0x38, 0x00, 0xfb, 0x21, + 0xfa, 0x30, 0x03, 0xf0, 0xb5, 0xfc, 0x02, 0x90, 0x86, 0x42, 0x44, 0xdb, + 0x05, 0x23, 0x01, 0x93, 0x6b, 0x1e, 0x2b, 0x43, 0xdb, 0x0f, 0x05, 0xaa, + 0x04, 0xa9, 0x20, 0x00, 0xff, 0xf7, 0xf2, 0xfc, 0x00, 0x28, 0x05, 0xdb, + 0x05, 0x98, 0x00, 0x28, 0x04, 0xd1, 0x02, 0x9b, 0xab, 0x42, 0x32, 0xda, + 0x07, 0xb0, 0xf0, 0xbd, 0x04, 0x9b, 0x01, 0x22, 0x1e, 0x88, 0x23, 0x00, + 0x40, 0x33, 0x1a, 0x70, 0x31, 0x00, 0x20, 0x00, 0x03, 0x93, 0xff, 0xf7, + 0xa1, 0xfd, 0x00, 0x23, 0x03, 0x9a, 0x13, 0x70, 0x98, 0x42, 0xed, 0xdb, + 0x31, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xaa, 0xfc, 0x00, 0x28, 0xe7, 0xdb, + 0x31, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x3e, 0xfc, 0x00, 0x28, 0xe1, 0xdb, + 0x0f, 0x22, 0xe3, 0x68, 0x53, 0x43, 0xa2, 0x6b, 0x9b, 0x1a, 0xe2, 0x6b, + 0x1e, 0x3b, 0x9b, 0x1a, 0x00, 0x2d, 0x01, 0xdc, 0x9d, 0x42, 0x04, 0xd0, + 0x01, 0x9a, 0x01, 0x3a, 0x01, 0x92, 0x00, 0x2a, 0x05, 0xd1, 0xfb, 0x22, + 0x53, 0x43, 0xbb, 0x42, 0xcc, 0xda, 0x05, 0x48, 0xca, 0xe7, 0x62, 0x6b, + 0x02, 0x2a, 0x03, 0xd9, 0xfb, 0x22, 0x5a, 0x43, 0xba, 0x42, 0xf2, 0xda, + 0x1d, 0x00, 0xb1, 0xe7, 0xef, 0xd8, 0xff, 0xff, 0xf7, 0xb5, 0x84, 0x68, + 0x07, 0x00, 0x01, 0x91, 0x15, 0x00, 0x1e, 0x00, 0x63, 0x1c, 0x17, 0xd0, + 0x33, 0x00, 0x94, 0x42, 0x10, 0xd9, 0xa4, 0x1a, 0xb4, 0x42, 0x00, 0xdd, + 0x34, 0x00, 0x23, 0x00, 0x01, 0x9a, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, + 0x47, 0xfd, 0x00, 0x28, 0x07, 0xdb, 0x01, 0x9a, 0x33, 0x1b, 0x12, 0x19, + 0x01, 0x92, 0x2d, 0x19, 0x00, 0x2b, 0x03, 0xdc, 0x30, 0x00, 0xfe, 0xbd, + 0x33, 0x00, 0xf9, 0xe7, 0x01, 0x9a, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, + 0x7d, 0xfa, 0x00, 0x28, 0xf4, 0xda, 0xf4, 0xe7, 0x73, 0xb5, 0x01, 0xaa, + 0x05, 0x00, 0x02, 0xf0, 0x59, 0xfc, 0x04, 0x1e, 0x02, 0xda, 0x28, 0x63, + 0x20, 0x00, 0x76, 0xbd, 0x01, 0x9e, 0xb3, 0x8b, 0x9b, 0x06, 0xf9, 0xd4, + 0x33, 0x6a, 0x00, 0x2b, 0x04, 0xd1, 0x31, 0x00, 0x28, 0x00, 0xfe, 0xf7, + 0x29, 0xfb, 0x30, 0x62, 0x01, 0x98, 0x02, 0x6a, 0x00, 0x2a, 0xed, 0xd0, + 0x8a, 0x21, 0x56, 0x78, 0x49, 0x00, 0x71, 0x43, 0x6c, 0x6c, 0x14, 0x31, + 0x24, 0x69, 0x13, 0x8a, 0x61, 0x18, 0xd2, 0x68, 0xff, 0xf7, 0xb0, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0x28, 0x63, 0x01, 0x9b, 0x28, 0x00, 0x19, 0x6a, + 0xfe, 0xf7, 0x34, 0xfb, 0xd8, 0xe7, 0x00, 0x00, 0xf7, 0xb5, 0x04, 0x00, + 0x1d, 0x00, 0x83, 0x6d, 0x17, 0x00, 0x01, 0x91, 0x60, 0x22, 0x00, 0x21, + 0x00, 0x93, 0x0a, 0x9e, 0x03, 0xf0, 0xb3, 0xfc, 0x0c, 0x22, 0x01, 0x99, + 0x20, 0x00, 0x03, 0xf0, 0xa5, 0xfc, 0x00, 0x9b, 0x08, 0x9a, 0xa3, 0x65, + 0x80, 0x23, 0x9b, 0x00, 0xe3, 0x60, 0x7b, 0x1c, 0xff, 0x33, 0x67, 0x62, + 0x23, 0x62, 0x00, 0x21, 0x28, 0x00, 0x03, 0xf0, 0xa0, 0xfc, 0x03, 0x22, + 0x2a, 0x40, 0x05, 0xd0, 0x04, 0x23, 0x9b, 0x1a, 0x08, 0x9a, 0xed, 0x18, + 0xd3, 0x1a, 0x08, 0x93, 0xa5, 0x62, 0x30, 0x21, 0x08, 0x98, 0x03, 0xf0, + 0xd9, 0xfb, 0x03, 0x22, 0x09, 0x9b, 0xe0, 0x62, 0x1a, 0x40, 0x05, 0xd0, + 0x04, 0x23, 0x9b, 0x1a, 0x09, 0x9a, 0xf6, 0x1a, 0xd2, 0x18, 0x09, 0x92, + 0x03, 0x23, 0x1e, 0x42, 0x00, 0xd0, 0x9e, 0x43, 0x80, 0x22, 0x09, 0x9b, + 0x92, 0x01, 0x63, 0x64, 0x33, 0x00, 0x96, 0x42, 0x00, 0xd9, 0x13, 0x00, + 0xa3, 0x64, 0x20, 0x00, 0xfe, 0xf7, 0x08, 0xfb, 0x07, 0x4b, 0x20, 0x00, + 0xe3, 0x65, 0x00, 0xf0, 0x83, 0xfd, 0x00, 0x28, 0x01, 0xda, 0x20, 0x63, + 0xfe, 0xbd, 0x0b, 0x9b, 0x00, 0x20, 0xe3, 0x64, 0x01, 0x23, 0x54, 0x34, + 0x23, 0x70, 0xf7, 0xe7, 0x15, 0x03, 0x09, 0x20, 0xf8, 0xb5, 0xc2, 0x6d, + 0x10, 0x4b, 0x04, 0x00, 0x9a, 0x42, 0x0c, 0xd1, 0x07, 0x00, 0x54, 0x37, + 0x3b, 0x78, 0x00, 0x2b, 0x07, 0xd0, 0x00, 0x26, 0x83, 0x6a, 0x1d, 0x1d, + 0xe3, 0x6a, 0xb3, 0x42, 0x02, 0xd8, 0x00, 0x23, 0x3b, 0x70, 0xf8, 0xbd, + 0x00, 0x23, 0xe9, 0x5e, 0x00, 0x29, 0x07, 0xd0, 0x20, 0x00, 0xff, 0xf7, + 0x5b, 0xff, 0x00, 0x23, 0xe9, 0x5e, 0x20, 0x00, 0x02, 0xf0, 0x98, 0xfb, + 0x01, 0x36, 0x30, 0x35, 0xea, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, + 0x00, 0x6b, 0x70, 0x47, 0x00, 0x23, 0x03, 0x63, 0x70, 0x47, 0x00, 0x00, + 0xf0, 0xb5, 0x87, 0xb0, 0x17, 0x00, 0x03, 0x93, 0xc2, 0x6d, 0x3f, 0x4b, + 0x05, 0x00, 0x0e, 0x00, 0x9a, 0x42, 0x04, 0xd0, 0x3d, 0x4c, 0x2c, 0x63, + 0x20, 0x00, 0x07, 0xb0, 0xf0, 0xbd, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, + 0x00, 0x2b, 0x01, 0xd1, 0x39, 0x4c, 0xf4, 0xe7, 0x08, 0x00, 0x03, 0xf0, + 0x32, 0xfc, 0x1f, 0x28, 0x01, 0xd9, 0x37, 0x4c, 0xed, 0xe7, 0x32, 0x00, + 0x05, 0xa9, 0x28, 0x00, 0x02, 0xf0, 0xf8, 0xfa, 0x00, 0x28, 0x02, 0xda, + 0x28, 0x63, 0x04, 0xb2, 0xe4, 0xe7, 0x04, 0xaa, 0x31, 0x00, 0x28, 0x00, + 0x01, 0xf0, 0xb2, 0xfe, 0x04, 0x00, 0x7b, 0x07, 0x34, 0xd4, 0x00, 0x28, + 0x24, 0xda, 0x05, 0x9b, 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, + 0x55, 0xfb, 0x2c, 0x63, 0x24, 0xb2, 0xd1, 0xe7, 0x00, 0x2c, 0xf4, 0xdb, + 0x02, 0xab, 0x19, 0x89, 0x03, 0x9b, 0x05, 0x9a, 0x00, 0x93, 0x28, 0x00, + 0x3b, 0x00, 0x01, 0xf0, 0x27, 0xf9, 0x04, 0x1e, 0xe9, 0xdb, 0xbb, 0x07, + 0x06, 0xd5, 0x00, 0x22, 0x05, 0x98, 0x11, 0x00, 0x01, 0xf0, 0xbe, 0xfe, + 0x04, 0x1e, 0xe0, 0xdb, 0x00, 0x22, 0x05, 0x9b, 0x9a, 0x61, 0x04, 0x24, + 0x1c, 0x5f, 0xb5, 0xe7, 0x00, 0x28, 0xe3, 0xd1, 0x44, 0x23, 0x3b, 0x40, + 0x44, 0x2b, 0xdf, 0xd1, 0x05, 0x9b, 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, + 0x02, 0xf0, 0x2a, 0xfb, 0x14, 0x4c, 0xa6, 0xe7, 0x00, 0x28, 0xf1, 0xd0, + 0x13, 0x4b, 0x9c, 0x42, 0xd0, 0xd1, 0x0a, 0x23, 0x02, 0xa9, 0x5b, 0x18, + 0x00, 0x22, 0x19, 0x00, 0x28, 0x00, 0x02, 0xf0, 0xfb, 0xf9, 0x04, 0x1e, + 0xbd, 0xdb, 0x02, 0xab, 0x59, 0x89, 0x04, 0xab, 0x01, 0x93, 0x01, 0x23, + 0x32, 0x00, 0x00, 0x93, 0x28, 0x00, 0x00, 0x23, 0x00, 0xf0, 0xf2, 0xff, + 0x04, 0x1e, 0xb0, 0xdb, 0x02, 0x23, 0x9f, 0x43, 0xb8, 0xe7, 0xc0, 0x46, + 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, 0xf0, 0xd8, 0xff, 0xff, + 0xcc, 0xd8, 0xff, 0xff, 0xd2, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xf7, 0xb5, 0x16, 0x00, 0x1c, 0x00, 0xc2, 0x6d, 0x29, 0x4b, 0x05, 0x00, + 0x0f, 0x00, 0x9a, 0x42, 0x03, 0xd0, 0x28, 0x4c, 0x2c, 0x63, 0x20, 0x00, + 0xfe, 0xbd, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, + 0x24, 0x4c, 0xf5, 0xe7, 0x01, 0xaa, 0x02, 0xf0, 0x01, 0xfb, 0x00, 0x28, + 0x05, 0xda, 0x04, 0x00, 0x28, 0x63, 0x21, 0x4b, 0x9c, 0x42, 0x0d, 0xd0, + 0xeb, 0xe7, 0x01, 0x9b, 0x9a, 0x8b, 0x12, 0x07, 0x01, 0xd4, 0x1e, 0x4c, + 0xe4, 0xe7, 0x9b, 0x68, 0x01, 0x33, 0x05, 0xd1, 0x00, 0x2c, 0x03, 0xdd, + 0x19, 0x4b, 0x2b, 0x63, 0x00, 0x24, 0xdc, 0xe7, 0x39, 0x00, 0x28, 0x00, + 0xff, 0xf7, 0x88, 0xfe, 0x01, 0x98, 0x81, 0x69, 0x83, 0x68, 0x0a, 0x19, + 0x9a, 0x42, 0x14, 0xd3, 0x5c, 0x1a, 0x00, 0x2c, 0xee, 0xdd, 0x33, 0x00, + 0x22, 0x00, 0x02, 0xf0, 0xa5, 0xf8, 0x0f, 0x4b, 0x98, 0x42, 0x06, 0xd1, + 0x20, 0x00, 0x01, 0x9a, 0x93, 0x69, 0x1b, 0x19, 0x93, 0x61, 0x04, 0x00, + 0xc1, 0xe7, 0x00, 0x28, 0x07, 0xda, 0x28, 0x63, 0xf9, 0xe7, 0x33, 0x00, + 0x22, 0x00, 0x02, 0xf0, 0x93, 0xf8, 0x00, 0x28, 0xc5, 0xdb, 0x01, 0x9a, + 0x93, 0x69, 0x1b, 0x19, 0x93, 0x61, 0xc2, 0xe7, 0x15, 0x03, 0x09, 0x20, + 0xd8, 0xd8, 0xff, 0xff, 0xf0, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xda, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x15, 0x00, 0x1e, 0x00, 0xc2, 0x6d, + 0x2d, 0x4b, 0x85, 0xb0, 0x04, 0x00, 0x0f, 0x00, 0x9a, 0x42, 0x03, 0xd0, + 0x2b, 0x48, 0x20, 0x63, 0x05, 0xb0, 0xf0, 0xbd, 0x03, 0x00, 0x54, 0x33, + 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x28, 0x48, 0xf5, 0xe7, 0x03, 0xaa, + 0x02, 0xf0, 0x9e, 0xfa, 0x00, 0x28, 0xf0, 0xdb, 0x39, 0x00, 0x20, 0x00, + 0xff, 0xf7, 0x3a, 0xfe, 0x03, 0x9f, 0xbb, 0x68, 0x5a, 0x1c, 0x00, 0xd1, + 0x00, 0x23, 0x01, 0x2e, 0x05, 0xd0, 0x02, 0x2e, 0x06, 0xd0, 0x00, 0x2d, + 0x06, 0xda, 0x1e, 0x48, 0xdf, 0xe7, 0xba, 0x69, 0xad, 0x18, 0xf8, 0xe7, + 0xed, 0x18, 0xf6, 0xe7, 0x9d, 0x42, 0x02, 0xdd, 0xbb, 0x61, 0x1a, 0x48, + 0xd5, 0xe7, 0x00, 0x26, 0xb5, 0x42, 0x0d, 0xdd, 0x68, 0x1e, 0xfb, 0x21, + 0x03, 0xf0, 0x52, 0xfa, 0x83, 0xb2, 0x68, 0x2b, 0x06, 0xd9, 0x18, 0x00, + 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0x4a, 0xfa, 0x01, 0x30, 0x86, 0xb2, + 0x3b, 0x8a, 0xb3, 0x42, 0x11, 0xd0, 0xf9, 0x88, 0x80, 0x23, 0x0a, 0x27, + 0x1b, 0x02, 0x6f, 0x44, 0x19, 0x43, 0x00, 0x97, 0x00, 0x23, 0x32, 0x00, + 0x20, 0x00, 0x00, 0xf0, 0xdd, 0xfc, 0x00, 0x28, 0xb3, 0xdb, 0x03, 0x9b, + 0x3a, 0x88, 0x1e, 0x82, 0xda, 0x81, 0x03, 0x9b, 0x28, 0x00, 0x9d, 0x61, + 0xac, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xc8, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x2a, 0x4b, 0xc2, 0x6d, 0x85, 0xb0, 0x05, 0x00, 0x0f, 0x00, + 0x9a, 0x42, 0x02, 0xd0, 0x27, 0x4c, 0x2c, 0x63, 0x3e, 0xe0, 0x03, 0x00, + 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x24, 0x4c, 0xf6, 0xe7, + 0x08, 0x00, 0x03, 0xf0, 0xda, 0xfa, 0x1f, 0x28, 0x01, 0xd9, 0x22, 0x4c, + 0xef, 0xe7, 0x00, 0x22, 0x03, 0xa9, 0x28, 0x00, 0x02, 0xf0, 0xa0, 0xf9, + 0x04, 0x1e, 0xe8, 0xdb, 0x0a, 0x26, 0x6e, 0x44, 0x32, 0x00, 0x39, 0x00, + 0x28, 0x00, 0x01, 0xf0, 0x5b, 0xfd, 0x04, 0x1e, 0x07, 0xd0, 0x03, 0x9b, + 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0x01, 0xfa, 0x00, 0x2c, + 0xd7, 0xdb, 0x00, 0x23, 0x31, 0x88, 0x03, 0x9a, 0x00, 0x93, 0x28, 0x00, + 0x00, 0xf0, 0xd8, 0xff, 0x04, 0x1e, 0x07, 0xd0, 0x03, 0x9b, 0x28, 0x00, + 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0xf0, 0xf9, 0x00, 0x2c, 0xc6, 0xdb, + 0x01, 0x22, 0x00, 0x21, 0x03, 0x98, 0x01, 0xf0, 0x69, 0xfd, 0x04, 0x1e, + 0x03, 0xd1, 0x00, 0x24, 0x20, 0x00, 0x05, 0xb0, 0xf0, 0xbd, 0x03, 0x9b, + 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0xdd, 0xf9, 0x00, 0x2c, + 0xb3, 0xdb, 0xf2, 0xe7, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xcc, 0xd8, 0xff, 0xff, 0x0d, 0x4b, 0xc2, 0x6d, + 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x9a, 0x42, 0x02, 0xd0, 0x0b, 0x48, + 0x20, 0x63, 0x10, 0xe0, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, + 0x01, 0xd1, 0x08, 0x48, 0xf6, 0xe7, 0xff, 0xf7, 0x7d, 0xfd, 0x00, 0x28, + 0xf2, 0xdb, 0x29, 0x00, 0x20, 0x00, 0x02, 0xf0, 0xb9, 0xf9, 0x00, 0x28, + 0xec, 0xdb, 0x70, 0xbd, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0x0e, 0x4b, 0xc2, 0x6d, 0x10, 0xb5, 0x04, 0x00, + 0x9a, 0x42, 0x02, 0xd0, 0x0c, 0x48, 0x20, 0x63, 0x10, 0xbd, 0x03, 0x00, + 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x09, 0x48, 0xf6, 0xe7, + 0x00, 0x21, 0xfe, 0xf7, 0xe5, 0xfd, 0x20, 0x00, 0xff, 0xf7, 0x06, 0xf9, + 0x20, 0x00, 0xfe, 0xf7, 0x19, 0xfe, 0x20, 0x00, 0x00, 0xf0, 0x52, 0xfb, + 0xea, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x12, 0x01, 0x5c, 0x1c, 0x14, 0x19, + 0x05, 0x22, 0x85, 0xb0, 0xa4, 0xb2, 0x02, 0xad, 0x0f, 0x00, 0x00, 0x92, + 0x23, 0x02, 0x01, 0x95, 0x10, 0x32, 0x00, 0x21, 0x0a, 0x9e, 0xfd, 0xf7, + 0xde, 0xff, 0x00, 0x28, 0x1d, 0xdb, 0x2b, 0x88, 0xbb, 0x42, 0x1c, 0xd1, + 0x0b, 0x9a, 0x69, 0x88, 0x12, 0x88, 0x8a, 0x42, 0x17, 0xd1, 0x29, 0x79, + 0x7c, 0x20, 0x0d, 0x00, 0x85, 0x43, 0x80, 0x2d, 0x11, 0xd1, 0x1b, 0xb2, + 0x00, 0x2b, 0x03, 0xda, 0x4b, 0x06, 0x01, 0xd4, 0x00, 0x2a, 0x0a, 0xd0, + 0x30, 0x1e, 0x06, 0xd0, 0x30, 0x88, 0x00, 0x1b, 0x44, 0x42, 0x60, 0x41, + 0x03, 0x4c, 0x40, 0x42, 0x20, 0x40, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x48, + 0xfb, 0xe7, 0xc0, 0x46, 0xaa, 0xd8, 0xff, 0xff, 0x7f, 0xb5, 0x1d, 0x00, + 0x1b, 0x4b, 0x0c, 0x00, 0x9a, 0x42, 0x24, 0xd0, 0x13, 0x07, 0x25, 0xd0, + 0x80, 0x23, 0x9b, 0x01, 0x9a, 0x42, 0x23, 0xd8, 0x13, 0x02, 0x04, 0x21, + 0x62, 0x5e, 0x05, 0x21, 0x02, 0xae, 0x00, 0x91, 0x01, 0x96, 0x11, 0x31, + 0xfd, 0xf7, 0xa1, 0xff, 0x00, 0x28, 0x13, 0xdb, 0x33, 0x79, 0xda, 0x07, + 0x16, 0xd4, 0x5a, 0xb2, 0x00, 0x2a, 0x15, 0xda, 0x9a, 0x07, 0x15, 0xd4, + 0x5b, 0x07, 0x15, 0xd4, 0x06, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x11, 0xda, + 0x73, 0x88, 0xab, 0x42, 0x02, 0xd0, 0x09, 0x48, 0x00, 0xe0, 0x09, 0x48, + 0x04, 0xb0, 0x70, 0xbd, 0x08, 0x48, 0xfb, 0xe7, 0x08, 0x48, 0xf9, 0xe7, + 0x08, 0x48, 0xf7, 0xe7, 0x08, 0x48, 0xf5, 0xe7, 0x08, 0x48, 0xf3, 0xe7, + 0x08, 0x48, 0xf1, 0xe7, 0xff, 0xff, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, + 0xde, 0xd8, 0xff, 0xff, 0xdd, 0xd8, 0xff, 0xff, 0xdc, 0xd8, 0xff, 0xff, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0x12, 0x01, 0x30, 0xb5, 0x01, 0x33, 0xd3, 0x18, + 0x13, 0x4a, 0x8f, 0xb0, 0x89, 0x18, 0x13, 0x4a, 0x89, 0xb2, 0x9b, 0xb2, + 0x91, 0x42, 0x1b, 0xd8, 0x2e, 0x22, 0x02, 0xac, 0x00, 0x92, 0x1b, 0x02, + 0x01, 0x94, 0x00, 0x22, 0x15, 0x21, 0xfd, 0xf7, 0x56, 0xff, 0x00, 0x28, + 0x11, 0xdb, 0x65, 0x88, 0x00, 0x2d, 0x0d, 0xd1, 0x3d, 0x22, 0x23, 0x79, + 0x93, 0x43, 0xc0, 0x2b, 0x08, 0xd1, 0x15, 0x21, 0x12, 0x98, 0x69, 0x44, + 0x03, 0xf0, 0x99, 0xf9, 0x03, 0x00, 0x28, 0x00, 0x00, 0x2b, 0x00, 0xd0, + 0x03, 0x48, 0x0f, 0xb0, 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, + 0xfe, 0x7f, 0x00, 0x00, 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x05, 0x00, + 0x0c, 0x00, 0x21, 0x48, 0x01, 0x39, 0x89, 0xb2, 0x8f, 0xb0, 0x81, 0x42, + 0x01, 0xd9, 0x1f, 0x48, 0x27, 0xe0, 0x15, 0x99, 0x0e, 0x88, 0x14, 0x99, + 0x00, 0x29, 0x24, 0xd0, 0x21, 0xb2, 0x00, 0x29, 0x21, 0xda, 0x12, 0x01, + 0x01, 0x33, 0xd3, 0x18, 0x2e, 0x22, 0x9b, 0xb2, 0x02, 0xaf, 0x00, 0x92, + 0x1b, 0x02, 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xfd, 0xf7, + 0x18, 0xff, 0x00, 0x28, 0x0f, 0xdb, 0x7b, 0x88, 0x00, 0x2b, 0x0e, 0xd1, + 0x3d, 0x22, 0x3b, 0x79, 0x93, 0x43, 0xc0, 0x2b, 0x09, 0xd1, 0x15, 0x21, + 0x14, 0x98, 0x69, 0x44, 0x03, 0xf0, 0x5b, 0xf9, 0x00, 0x28, 0x02, 0xd1, + 0x0b, 0x48, 0x0f, 0xb0, 0xf0, 0xbd, 0x64, 0x04, 0x64, 0x0c, 0xa4, 0x1b, + 0xe3, 0x10, 0xff, 0x2b, 0xcd, 0xd8, 0x6a, 0x6a, 0xd2, 0x18, 0x07, 0x23, + 0x1c, 0x40, 0x06, 0x3b, 0xa3, 0x40, 0x11, 0x78, 0x0b, 0x43, 0x13, 0x70, + 0xc3, 0xe7, 0xc0, 0x46, 0xfd, 0xff, 0x00, 0x00, 0xaa, 0xd8, 0xff, 0xff, + 0xd9, 0xd8, 0xff, 0xff, 0x09, 0x4a, 0x91, 0x42, 0x06, 0xd1, 0x00, 0x2b, + 0x02, 0xd1, 0x43, 0x6b, 0x01, 0x33, 0x43, 0x63, 0x06, 0x48, 0x70, 0x47, + 0x00, 0x29, 0x03, 0xd1, 0xc3, 0x6b, 0x01, 0x33, 0xc3, 0x63, 0xf7, 0xe7, + 0x83, 0x6b, 0x01, 0x33, 0x83, 0x63, 0xf3, 0xe7, 0xff, 0xff, 0x00, 0x00, + 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x85, 0xb0, 0x01, 0x91, 0x02, 0x92, + 0x07, 0x89, 0x06, 0x00, 0x00, 0x25, 0x68, 0x2f, 0x06, 0xd9, 0x38, 0x00, + 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0x58, 0xf8, 0x01, 0x30, 0x85, 0xb2, + 0x74, 0x89, 0x00, 0x20, 0x68, 0x2c, 0x06, 0xd9, 0x20, 0x00, 0x7c, 0x21, + 0x69, 0x38, 0x03, 0xf0, 0x4d, 0xf8, 0x01, 0x30, 0x80, 0xb2, 0x01, 0x9b, + 0x9d, 0x42, 0x1c, 0xd8, 0x83, 0x42, 0x1a, 0xd8, 0x00, 0x2b, 0x1a, 0xd0, + 0x7c, 0x23, 0x01, 0x9a, 0x5a, 0x43, 0x13, 0x3a, 0x92, 0xb2, 0x9b, 0x18, + 0x01, 0x34, 0x9b, 0xb2, 0xa3, 0x42, 0x00, 0xdd, 0x23, 0x00, 0x9b, 0xb2, + 0x03, 0x93, 0x3c, 0x1c, 0x97, 0x42, 0x00, 0xd2, 0x14, 0x1c, 0xa4, 0xb2, + 0x25, 0x1d, 0x14, 0x4f, 0x6d, 0x00, 0x03, 0x9a, 0xa3, 0xb2, 0x9a, 0x42, + 0x04, 0xd8, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x9a, 0x69, 0x23, 0xe6, 0xe7, + 0x01, 0x9a, 0x00, 0x2a, 0x0c, 0xd1, 0x02, 0x9b, 0x5b, 0x19, 0xda, 0x8c, + 0x02, 0x35, 0xba, 0x42, 0xf1, 0xd0, 0x33, 0x89, 0x31, 0x68, 0xe3, 0x1a, + 0x5b, 0x00, 0x5a, 0x52, 0x01, 0x34, 0xe6, 0xe7, 0x29, 0x00, 0x68, 0x2b, + 0x06, 0xd9, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0x94, 0xf8, + 0x04, 0x31, 0x49, 0x00, 0x02, 0x9b, 0x5a, 0x5a, 0xe8, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0x01, 0x00, 0x10, 0xb5, 0x21, 0x24, 0x03, 0x00, + 0x05, 0x48, 0x20, 0x31, 0x1a, 0x78, 0x00, 0x2a, 0x02, 0xd0, 0x01, 0x33, + 0x8b, 0x42, 0x00, 0xd1, 0x10, 0xbd, 0x60, 0x43, 0x50, 0x40, 0xf5, 0xe7, + 0x05, 0x15, 0x00, 0x00, 0x30, 0xb5, 0x1c, 0x00, 0x19, 0x4b, 0x85, 0xb0, + 0x9a, 0x42, 0x20, 0xd0, 0x13, 0x07, 0x21, 0xd0, 0x80, 0x23, 0x9b, 0x01, + 0x9a, 0x42, 0x1f, 0xd8, 0x13, 0x02, 0x00, 0x22, 0x8a, 0x5e, 0x05, 0x21, + 0x02, 0xad, 0x00, 0x91, 0x01, 0x95, 0x12, 0x31, 0xfd, 0xf7, 0x4d, 0xfe, + 0x00, 0x28, 0x0f, 0xdb, 0x2b, 0x79, 0xda, 0x07, 0x12, 0xd4, 0x5a, 0xb2, + 0x00, 0x2a, 0x11, 0xda, 0x9a, 0x07, 0x11, 0xd4, 0x5b, 0x07, 0x11, 0xd5, + 0x6b, 0x88, 0xa3, 0x42, 0x02, 0xd0, 0x09, 0x48, 0x00, 0xe0, 0x09, 0x48, + 0x05, 0xb0, 0x30, 0xbd, 0x08, 0x48, 0xfb, 0xe7, 0x08, 0x48, 0xf9, 0xe7, + 0x08, 0x48, 0xf7, 0xe7, 0x08, 0x48, 0xf5, 0xe7, 0x08, 0x48, 0xf3, 0xe7, + 0x08, 0x48, 0xf1, 0xe7, 0xff, 0xff, 0x00, 0x00, 0xe2, 0xd8, 0xff, 0xff, + 0xe1, 0xd8, 0xff, 0xff, 0xe0, 0xd8, 0xff, 0xff, 0xdf, 0xd8, 0xff, 0xff, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xe5, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0c, 0x00, 0x1f, 0x49, 0x06, 0x00, + 0x61, 0x18, 0x1f, 0x48, 0x8f, 0xb0, 0x89, 0xb2, 0x14, 0x9d, 0x81, 0x42, + 0x33, 0xd8, 0x01, 0x33, 0x12, 0x03, 0x1b, 0x02, 0x9b, 0x18, 0x2e, 0x22, + 0x02, 0xaf, 0x00, 0x92, 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x30, 0x00, + 0xfd, 0xf7, 0x03, 0xfe, 0x00, 0x28, 0x24, 0xd1, 0x7b, 0x88, 0x00, 0x2b, + 0x21, 0xd1, 0x79, 0x22, 0x3b, 0x79, 0x93, 0x43, 0x80, 0x2b, 0x1c, 0xd1, + 0xa8, 0x68, 0x00, 0x28, 0x08, 0xd0, 0x15, 0x21, 0x69, 0x44, 0x03, 0xf0, + 0x44, 0xf8, 0x00, 0x28, 0x02, 0xd1, 0x0d, 0x48, 0x0f, 0xb0, 0xf0, 0xbd, + 0x28, 0x88, 0x61, 0x04, 0x49, 0x0c, 0x81, 0x42, 0x0b, 0xd3, 0x6b, 0x88, + 0x8b, 0x42, 0x08, 0xd3, 0x08, 0x1a, 0x69, 0x68, 0x02, 0xf0, 0x72, 0xff, + 0x73, 0x6a, 0x18, 0x18, 0x03, 0x78, 0x01, 0x33, 0x03, 0x70, 0x04, 0x48, + 0xea, 0xe7, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, 0xfe, 0x7f, 0x00, 0x00, + 0xd9, 0xd8, 0xff, 0xff, 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x15, 0x00, + 0x1e, 0x00, 0x95, 0xb0, 0x1a, 0x9f, 0x02, 0x90, 0x03, 0x91, 0x00, 0x2f, + 0x02, 0xd1, 0x38, 0x00, 0x15, 0xb0, 0xf0, 0xbd, 0x3c, 0x00, 0x40, 0x2f, + 0x00, 0xd9, 0x40, 0x24, 0x04, 0xab, 0x01, 0x93, 0x00, 0x94, 0x33, 0x00, + 0x03, 0x9a, 0x0b, 0x21, 0x02, 0x98, 0xfd, 0xf7, 0xb8, 0xfd, 0x00, 0x28, + 0xee, 0xdb, 0x04, 0xab, 0x01, 0x93, 0x00, 0x94, 0x2b, 0x00, 0x03, 0x9a, + 0x0f, 0x21, 0x02, 0x98, 0xfd, 0xf7, 0x11, 0xfe, 0x00, 0x28, 0xe3, 0xdb, + 0x3f, 0x1b, 0x36, 0x19, 0x2d, 0x19, 0xdc, 0xe7, 0xf0, 0xb5, 0x14, 0x00, + 0x0f, 0x22, 0x8d, 0xb0, 0x06, 0x93, 0x12, 0xab, 0x1b, 0x88, 0x06, 0x00, + 0x0b, 0x93, 0xc3, 0x68, 0x0f, 0x00, 0x5a, 0x43, 0x07, 0x92, 0x02, 0x6a, + 0x09, 0x92, 0x0e, 0x2c, 0x00, 0xdc, 0xa4, 0xe0, 0x01, 0x37, 0xbf, 0xb2, + 0xbb, 0x42, 0x51, 0xd9, 0x00, 0x24, 0x3b, 0x03, 0x03, 0x93, 0x07, 0x9b, + 0x00, 0x2b, 0x4f, 0xdd, 0x7f, 0x22, 0xe3, 0x17, 0x13, 0x40, 0x1b, 0x19, + 0xdb, 0x11, 0xda, 0x01, 0x05, 0x92, 0x09, 0x9a, 0x1b, 0x02, 0xd3, 0x1a, + 0x04, 0x93, 0x03, 0x9a, 0x09, 0x9b, 0x14, 0x21, 0x9b, 0x18, 0x04, 0x9a, + 0x30, 0x00, 0x9b, 0x1a, 0x0a, 0x93, 0x33, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x0a, 0x9b, 0xfd, 0xf7, 0x6f, 0xfd, + 0x25, 0x00, 0x07, 0x9b, 0x02, 0x90, 0x08, 0x93, 0x08, 0x9b, 0x2c, 0x00, + 0x07, 0x93, 0x02, 0x9b, 0x00, 0x2b, 0x05, 0xd1, 0x05, 0x9b, 0xeb, 0x1a, + 0x7f, 0x2b, 0x01, 0xdc, 0x0e, 0x2d, 0x28, 0xdd, 0x05, 0x9b, 0x80, 0x33, + 0x05, 0x93, 0x04, 0x9b, 0x01, 0x3b, 0xff, 0x3b, 0x04, 0x93, 0x02, 0x9b, + 0x00, 0x2b, 0x02, 0xd1, 0x05, 0x9b, 0x80, 0x2b, 0xd1, 0xd1, 0x01, 0x37, + 0xf3, 0x68, 0xbf, 0xb2, 0x9f, 0x42, 0x55, 0xd2, 0x80, 0x22, 0x52, 0x01, + 0x94, 0x46, 0x03, 0x9b, 0x63, 0x44, 0x03, 0x93, 0x00, 0x24, 0x02, 0x9b, + 0xa3, 0x42, 0xb4, 0xd0, 0x02, 0x9b, 0x00, 0x2b, 0x06, 0xdb, 0x03, 0xe0, + 0x04, 0x24, 0x06, 0x9b, 0x1c, 0x40, 0x4d, 0xd0, 0x29, 0x4b, 0x02, 0x93, + 0x02, 0x98, 0x0d, 0xb0, 0xf0, 0xbd, 0x01, 0x22, 0x06, 0x9b, 0x13, 0x42, + 0x05, 0xd0, 0x04, 0x9a, 0x6b, 0x00, 0xd3, 0x5a, 0x0b, 0x9a, 0x93, 0x42, + 0x2f, 0xd1, 0x16, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x1f, 0x80, 0x17, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x1d, 0x60, 0x13, 0x9b, 0x00, 0x2b, 0xe7, 0xd0, + 0x02, 0x22, 0x06, 0x9b, 0x0b, 0x99, 0x13, 0x42, 0x02, 0xd1, 0x04, 0x9a, + 0x6b, 0x00, 0xd1, 0x5a, 0x15, 0x9b, 0x3a, 0x00, 0x01, 0x93, 0x14, 0x9b, + 0x30, 0x00, 0x00, 0x93, 0x13, 0x9c, 0x2b, 0x00, 0xa0, 0x47, 0x15, 0x4b, + 0xc3, 0x18, 0x01, 0x2b, 0x21, 0xd8, 0x14, 0x4b, 0x98, 0x42, 0x0c, 0xd1, + 0x33, 0x6a, 0x00, 0x22, 0x01, 0x93, 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, + 0x14, 0x21, 0x0a, 0x9b, 0x30, 0x00, 0xfd, 0xf7, 0xfe, 0xfc, 0x00, 0x28, + 0x11, 0xdb, 0x08, 0x9b, 0x01, 0x35, 0x01, 0x3b, 0x08, 0x93, 0x8b, 0xe7, + 0x04, 0x23, 0x06, 0x9a, 0x13, 0x40, 0xb7, 0xd1, 0x03, 0x93, 0x1f, 0x00, + 0xa8, 0xe7, 0x0b, 0x03, 0x03, 0x93, 0x5e, 0xe7, 0x03, 0x94, 0x27, 0x00, + 0x5b, 0xe7, 0x02, 0x90, 0xae, 0xe7, 0xc0, 0x46, 0xa8, 0xd8, 0xff, 0xff, + 0x57, 0x27, 0x00, 0x00, 0xa9, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x04, 0x00, + 0x0d, 0x03, 0x0f, 0x00, 0x80, 0x21, 0x85, 0xb0, 0x49, 0x01, 0xa3, 0x68, + 0x28, 0x00, 0x98, 0x47, 0x63, 0x6b, 0x22, 0x00, 0x01, 0x33, 0x63, 0x63, + 0x02, 0x26, 0x2b, 0x00, 0x42, 0x32, 0x01, 0x92, 0xfe, 0x33, 0x00, 0x96, + 0x00, 0x22, 0x19, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x2c, 0xfd, 0x00, 0x28, + 0x1a, 0xdb, 0xe3, 0x68, 0x0e, 0x22, 0xdb, 0x1b, 0x0d, 0x4f, 0x6a, 0x44, + 0x5f, 0x40, 0x2b, 0x00, 0x17, 0x80, 0xfc, 0x33, 0x01, 0x92, 0x00, 0x96, + 0x00, 0x22, 0x19, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x1a, 0xfd, 0x00, 0x28, + 0x08, 0xdb, 0x80, 0x22, 0x04, 0x34, 0xe3, 0x8f, 0x12, 0x02, 0x01, 0x33, + 0x9b, 0xb2, 0x93, 0x42, 0x02, 0xd0, 0xe3, 0x87, 0x05, 0xb0, 0xf0, 0xbd, + 0x00, 0x23, 0xfa, 0xe7, 0x29, 0x04, 0x00, 0x00, 0xf0, 0xb5, 0x00, 0x27, + 0x04, 0x00, 0x8b, 0xb0, 0x3b, 0x4d, 0x08, 0xab, 0x1f, 0x80, 0x07, 0x95, + 0x08, 0xae, 0x33, 0x88, 0xe2, 0x68, 0x93, 0x42, 0x24, 0xd3, 0x38, 0x4a, + 0x7b, 0x1b, 0x01, 0x35, 0x93, 0x42, 0x00, 0xdc, 0x7d, 0x1c, 0x23, 0x1d, + 0xad, 0xb2, 0xdd, 0x87, 0x07, 0x9b, 0x1a, 0x00, 0x31, 0x4b, 0x9a, 0x42, + 0x58, 0xd1, 0x00, 0x25, 0x09, 0xab, 0x05, 0x93, 0x30, 0x4b, 0x65, 0x63, + 0x01, 0x93, 0xa5, 0x63, 0x2b, 0x00, 0xe5, 0x63, 0x04, 0x96, 0x03, 0x95, + 0x02, 0x95, 0x00, 0x95, 0x2a, 0x00, 0x29, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0xd1, 0xfe, 0x2a, 0x4b, 0x98, 0x42, 0x41, 0xd1, 0x28, 0x00, 0x3f, 0xe0, + 0x1a, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, 0x1b, 0x03, + 0x00, 0x92, 0xfc, 0x33, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, 0xfd, 0xf7, + 0x66, 0xfc, 0x00, 0x28, 0x30, 0xdb, 0xe2, 0x68, 0x33, 0x88, 0xd1, 0x1a, + 0x1f, 0x4a, 0x4a, 0x40, 0x02, 0xa9, 0x49, 0x8b, 0x92, 0xb2, 0x91, 0x42, + 0x05, 0xd0, 0x07, 0x9a, 0x11, 0x00, 0x17, 0x4a, 0x91, 0x42, 0x20, 0xd1, + 0x07, 0x93, 0x02, 0x22, 0x1b, 0x03, 0x09, 0xae, 0x00, 0x92, 0xfe, 0x33, + 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x49, 0xfc, + 0x00, 0x28, 0x13, 0xdb, 0x33, 0x88, 0x0e, 0x4a, 0x93, 0x42, 0x09, 0xd0, + 0x1a, 0x1c, 0xab, 0x42, 0x00, 0xd9, 0x2a, 0x1c, 0x95, 0xb2, 0x1a, 0x1c, + 0xbb, 0x42, 0x00, 0xd2, 0x3a, 0x1c, 0x97, 0xb2, 0x08, 0xaa, 0x13, 0x88, + 0x01, 0x33, 0x13, 0x80, 0x96, 0xe7, 0x0a, 0x48, 0x0b, 0xb0, 0xf0, 0xbd, + 0x07, 0x99, 0x20, 0x00, 0xff, 0xf7, 0x4c, 0xff, 0x00, 0x28, 0xa0, 0xda, + 0xf6, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0xff, 0x7f, 0x00, 0x00, + 0xc9, 0x49, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, 0x29, 0x04, 0x00, 0x00, + 0xd7, 0xd8, 0xff, 0xff, 0x10, 0xb5, 0x86, 0xb0, 0x09, 0x9c, 0x00, 0x93, + 0x05, 0x94, 0x08, 0x9c, 0x01, 0x23, 0x04, 0x94, 0x00, 0x24, 0x03, 0x94, + 0x02, 0x94, 0x01, 0x94, 0xff, 0xf7, 0x68, 0xfe, 0x02, 0x4b, 0x98, 0x42, + 0x00, 0xd1, 0x02, 0x48, 0x06, 0xb0, 0x10, 0xbd, 0xa8, 0xd8, 0xff, 0xff, + 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x1e, 0x00, 0x03, 0x00, 0x85, 0xb0, + 0x03, 0x92, 0x40, 0x33, 0x0f, 0x00, 0x19, 0x78, 0x04, 0x00, 0x0a, 0x9d, + 0x00, 0x29, 0x0b, 0xd0, 0x01, 0x95, 0x00, 0x96, 0x12, 0x4b, 0x03, 0x9a, + 0x39, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xd4, 0xff, 0x00, 0x28, 0x10, 0xd0, + 0x05, 0xb0, 0xf0, 0xbd, 0x43, 0x6b, 0x01, 0x2b, 0xf0, 0xd8, 0xfe, 0xf7, + 0x49, 0xfd, 0x0c, 0x4b, 0x98, 0x42, 0x01, 0xd0, 0x00, 0x28, 0xf3, 0xdb, + 0x63, 0x6b, 0x01, 0x2b, 0xe6, 0xd8, 0x09, 0x48, 0xee, 0xe7, 0x33, 0x88, + 0x23, 0x82, 0x2b, 0x68, 0x01, 0x33, 0x63, 0x61, 0x2b, 0x68, 0x00, 0x2b, + 0xe6, 0xd1, 0x63, 0x6b, 0x01, 0x3b, 0x63, 0x63, 0xe2, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xd3, 0xd8, 0xff, 0xff, 0xef, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x1e, 0x27, 0x8b, 0xb0, 0x6f, 0x44, 0x07, 0xae, 0x3a, 0x80, + 0x33, 0x80, 0x04, 0x00, 0x0d, 0x00, 0xc2, 0x69, 0x01, 0x8b, 0x00, 0x20, + 0x83, 0x42, 0x00, 0xd0, 0x30, 0x00, 0x22, 0x26, 0x09, 0xab, 0x05, 0x93, + 0x0f, 0x4b, 0x6e, 0x44, 0x02, 0x90, 0x01, 0x93, 0x04, 0x96, 0x01, 0x23, + 0x03, 0x97, 0x00, 0x95, 0x20, 0x00, 0xff, 0xf7, 0x07, 0xfe, 0x0b, 0x4b, + 0x98, 0x42, 0x0f, 0xd0, 0x00, 0x28, 0x0b, 0xdb, 0x10, 0x9b, 0x31, 0x88, + 0x09, 0x9a, 0x00, 0x2b, 0x04, 0xd0, 0x0b, 0x01, 0x9b, 0x18, 0x10, 0x9d, + 0x01, 0x33, 0x2b, 0x80, 0x21, 0x83, 0xe2, 0x61, 0x0b, 0xb0, 0xf0, 0xbd, + 0x02, 0x48, 0xfb, 0xe7, 0xc5, 0x47, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x1e, 0x27, 0x8b, 0xb0, 0x6f, 0x44, + 0x07, 0xae, 0x3a, 0x80, 0x33, 0x80, 0x04, 0x00, 0x0d, 0x00, 0xc2, 0x69, + 0x01, 0x8b, 0x00, 0x20, 0x83, 0x42, 0x00, 0xd0, 0x30, 0x00, 0x22, 0x26, + 0x09, 0xab, 0x05, 0x93, 0x0f, 0x4b, 0x6e, 0x44, 0x02, 0x90, 0x01, 0x93, + 0x04, 0x96, 0x02, 0x23, 0x03, 0x97, 0x00, 0x95, 0x20, 0x00, 0xff, 0xf7, + 0xcf, 0xfd, 0x0b, 0x4b, 0x98, 0x42, 0x0f, 0xd0, 0x00, 0x28, 0x0b, 0xdb, + 0x10, 0x9b, 0x31, 0x88, 0x09, 0x9a, 0x00, 0x2b, 0x04, 0xd0, 0x0b, 0x01, + 0x9b, 0x18, 0x10, 0x9d, 0x01, 0x33, 0x2b, 0x80, 0x21, 0x83, 0xe2, 0x61, + 0x0b, 0xb0, 0xf0, 0xbd, 0x02, 0x48, 0xfb, 0xe7, 0xc5, 0x47, 0x00, 0x00, + 0xa8, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0e, 0x27, + 0x12, 0x26, 0x89, 0xb0, 0x03, 0x93, 0x10, 0xab, 0x1b, 0x78, 0x15, 0x00, + 0x04, 0x93, 0x02, 0xab, 0xff, 0x18, 0x39, 0x80, 0xf6, 0x18, 0x07, 0xab, + 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x33, 0x00, 0x04, 0x00, 0xff, 0xf7, + 0x41, 0xff, 0x00, 0x28, 0x67, 0xdb, 0x33, 0x88, 0x07, 0x9a, 0x1b, 0x03, + 0x52, 0x00, 0x9b, 0x18, 0x02, 0x22, 0x01, 0x97, 0x00, 0x92, 0x04, 0x21, + 0x00, 0x22, 0x20, 0x00, 0xfd, 0xf7, 0x9b, 0xfb, 0x00, 0x28, 0x58, 0xdb, + 0x01, 0x22, 0xa3, 0x6b, 0x07, 0x21, 0x01, 0x33, 0xa3, 0x63, 0x2b, 0x79, + 0x20, 0x00, 0x93, 0x43, 0x2b, 0x71, 0x07, 0x9b, 0x9b, 0x18, 0x32, 0x88, + 0x1b, 0x02, 0x12, 0x03, 0x9b, 0x18, 0x05, 0x22, 0x01, 0x95, 0x00, 0x92, + 0x00, 0x22, 0xfd, 0xf7, 0x84, 0xfb, 0x00, 0x28, 0x41, 0xdb, 0x03, 0x9b, + 0x00, 0x2b, 0x13, 0xd0, 0x07, 0x9b, 0x32, 0x88, 0x01, 0x33, 0x12, 0x03, + 0x1b, 0x02, 0x9b, 0x18, 0x0f, 0x9a, 0x05, 0x33, 0x9b, 0x18, 0x03, 0x9a, + 0x07, 0x21, 0x01, 0x92, 0x0e, 0x9a, 0x20, 0x00, 0x00, 0x92, 0x00, 0x22, + 0xfd, 0xf7, 0x6d, 0xfb, 0x00, 0x28, 0x2a, 0xdb, 0x04, 0x9b, 0x00, 0x2b, + 0x1a, 0xd0, 0x02, 0x22, 0x2b, 0x79, 0x13, 0x42, 0x16, 0xd0, 0x93, 0x43, + 0x02, 0xa9, 0x10, 0x32, 0x2b, 0x71, 0x52, 0x18, 0x07, 0x9b, 0x12, 0x88, + 0x01, 0x33, 0x12, 0x03, 0x1b, 0x02, 0x9b, 0x18, 0x01, 0x22, 0x04, 0x35, + 0x00, 0x92, 0x04, 0x33, 0x01, 0x95, 0x00, 0x22, 0x07, 0x21, 0x20, 0x00, + 0xfd, 0xf7, 0x4f, 0xfb, 0x00, 0x28, 0x0c, 0xdb, 0x11, 0x9b, 0x00, 0x2b, + 0x09, 0xd0, 0x12, 0x23, 0x02, 0xaa, 0x9b, 0x18, 0x1b, 0x88, 0x07, 0x9a, + 0x1b, 0x01, 0xd3, 0x18, 0x11, 0x9a, 0x01, 0x33, 0x13, 0x80, 0x09, 0xb0, + 0xf0, 0xbd, 0x00, 0x00, 0x7f, 0xb5, 0x0e, 0x22, 0x00, 0x26, 0x0f, 0x23, + 0x0c, 0x00, 0x6a, 0x44, 0x16, 0x80, 0x01, 0x92, 0x02, 0x22, 0x0b, 0x40, + 0x11, 0x49, 0x00, 0x92, 0x5b, 0x18, 0x21, 0x09, 0x09, 0x03, 0x5b, 0x00, + 0x5b, 0x18, 0x32, 0x00, 0x31, 0x00, 0x05, 0x00, 0xfd, 0xf7, 0x27, 0xfb, + 0xb0, 0x42, 0x13, 0xdb, 0xeb, 0x6b, 0x0d, 0x22, 0x01, 0x33, 0xeb, 0x63, + 0xab, 0x6b, 0x6a, 0x44, 0x01, 0x3b, 0xab, 0x63, 0x7e, 0x23, 0x13, 0x70, + 0x01, 0x92, 0x01, 0x22, 0x24, 0x02, 0x00, 0x92, 0x23, 0x1d, 0x32, 0x00, + 0x03, 0x21, 0x28, 0x00, 0xfd, 0xf7, 0x11, 0xfb, 0x04, 0xb0, 0x70, 0xbd, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x89, 0xb0, 0x15, 0x00, 0x0e, 0xaa, + 0x03, 0x91, 0x02, 0xca, 0x12, 0x24, 0x12, 0x88, 0x02, 0x91, 0x04, 0x92, + 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x13, 0x80, 0x07, 0xab, 0x64, 0x18, + 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x23, 0x00, 0x06, 0x00, 0x10, 0x9f, + 0xff, 0xf7, 0x8c, 0xfe, 0x00, 0x28, 0x5f, 0xdb, 0x24, 0x88, 0x07, 0x9b, + 0x24, 0x01, 0x1c, 0x19, 0x01, 0x34, 0xa4, 0xb2, 0x00, 0x2f, 0x00, 0xd0, + 0x3c, 0x80, 0x27, 0x02, 0x00, 0x2d, 0x1e, 0xd1, 0x80, 0x22, 0x04, 0x9b, + 0x52, 0x00, 0x1b, 0x02, 0x00, 0x92, 0x03, 0x99, 0x3a, 0x00, 0x30, 0x00, + 0xff, 0xf7, 0xa8, 0xfc, 0x00, 0x23, 0x02, 0x9d, 0x02, 0x93, 0x24, 0xe0, + 0x03, 0x22, 0x2b, 0x79, 0x04, 0x35, 0x93, 0x43, 0x2b, 0x70, 0x02, 0x3a, + 0x00, 0x92, 0x3b, 0x1d, 0x01, 0x95, 0x03, 0x9a, 0x07, 0x21, 0x30, 0x00, + 0xfd, 0xf7, 0xcb, 0xfa, 0x00, 0x28, 0x31, 0xda, 0x34, 0xe0, 0x01, 0x22, + 0x2b, 0x79, 0x10, 0x00, 0x59, 0x08, 0x93, 0x43, 0x92, 0x18, 0x13, 0x43, + 0x2b, 0x71, 0x80, 0x23, 0x88, 0x43, 0x5b, 0x00, 0x02, 0x90, 0x00, 0x93, + 0x01, 0x95, 0x3b, 0x00, 0x00, 0x22, 0x07, 0x21, 0x30, 0x00, 0xfd, 0xf7, + 0xb4, 0xfa, 0x00, 0x28, 0x1e, 0xdb, 0x0f, 0x23, 0x0f, 0x4a, 0x23, 0x40, + 0x9b, 0x18, 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, + 0x24, 0x09, 0x5b, 0x00, 0x24, 0x03, 0x00, 0x92, 0x1b, 0x19, 0x00, 0x22, + 0x04, 0x21, 0x30, 0x00, 0xfd, 0xf7, 0x9f, 0xfa, 0x00, 0x28, 0x09, 0xdb, + 0xb3, 0x6b, 0x01, 0x33, 0xb3, 0x63, 0x02, 0x9b, 0x00, 0x2b, 0xbd, 0xd1, + 0x04, 0x99, 0x30, 0x00, 0xff, 0xf7, 0x56, 0xff, 0x09, 0xb0, 0xf0, 0xbd, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x87, 0xb0, 0x04, 0x93, 0x0c, 0xab, + 0x1b, 0x88, 0x07, 0x00, 0x00, 0x93, 0x0d, 0xab, 0x1b, 0x88, 0x15, 0x00, + 0x03, 0x93, 0x04, 0x9b, 0x05, 0x91, 0x5b, 0x04, 0x5b, 0x0c, 0x02, 0x93, + 0x83, 0x6a, 0x1e, 0x1d, 0x00, 0x23, 0x34, 0x00, 0x01, 0x93, 0xfb, 0x6a, + 0x01, 0x9a, 0x93, 0x42, 0x08, 0xd8, 0x01, 0x2d, 0x00, 0xd8, 0x6e, 0xe0, + 0x3c, 0x6d, 0x00, 0x2c, 0x00, 0xd0, 0x6c, 0xe0, 0x07, 0xb0, 0xf0, 0xbd, + 0x43, 0x4a, 0x63, 0x88, 0x13, 0x40, 0x02, 0x9a, 0x93, 0x42, 0x38, 0xd1, + 0x00, 0x9b, 0x00, 0x2b, 0x2b, 0xd1, 0x02, 0x2d, 0x38, 0xd0, 0xa3, 0x8c, + 0x00, 0x2b, 0x30, 0xd0, 0x6b, 0x46, 0x9b, 0x89, 0x23, 0x81, 0x0e, 0x9b, + 0x00, 0x2b, 0x20, 0xd0, 0x0e, 0x9a, 0x63, 0x60, 0xe1, 0x69, 0x00, 0x9b, + 0x01, 0x32, 0x09, 0xd0, 0x0e, 0x9b, 0x00, 0x29, 0x06, 0xd0, 0xca, 0x68, + 0x0b, 0x8a, 0x9b, 0x18, 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd2, 0x13, 0x00, + 0x22, 0x69, 0x9a, 0x42, 0x00, 0xd9, 0x23, 0x61, 0x62, 0x69, 0x9a, 0x42, + 0x00, 0xd9, 0x63, 0x61, 0x00, 0x29, 0x06, 0xd0, 0xca, 0x68, 0x01, 0x33, + 0x9a, 0x42, 0x02, 0xd9, 0x38, 0x00, 0xfd, 0xf7, 0x91, 0xfa, 0xa3, 0x89, + 0x00, 0x9a, 0x93, 0x42, 0x05, 0xd1, 0x00, 0x23, 0x02, 0x2d, 0x01, 0xd0, + 0x6b, 0x46, 0x9b, 0x89, 0x63, 0x81, 0x01, 0x9b, 0x30, 0x34, 0x01, 0x33, + 0x01, 0x93, 0xae, 0xe7, 0x00, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x05, 0xd0, + 0xe1, 0x69, 0x00, 0x29, 0x02, 0xd0, 0x38, 0x00, 0xfd, 0xf7, 0x78, 0xfa, + 0x00, 0x23, 0x23, 0x80, 0x63, 0x80, 0xe2, 0xe7, 0x00, 0x22, 0xb3, 0x5e, + 0x00, 0x2b, 0x0c, 0xd0, 0xb0, 0x6a, 0x00, 0x28, 0x09, 0xd0, 0x17, 0x4a, + 0x73, 0x88, 0x13, 0x40, 0x02, 0x9a, 0x93, 0x42, 0x03, 0xd1, 0x05, 0x9a, + 0x00, 0x99, 0xff, 0xf7, 0xd1, 0xfa, 0x01, 0x34, 0x30, 0x36, 0xfb, 0x6a, + 0xa3, 0x42, 0xe9, 0xd8, 0x90, 0xe7, 0x00, 0x24, 0xf9, 0xe7, 0x00, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x8e, 0xe7, 0x6b, 0x46, 0x10, 0x22, 0x9b, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0x88, 0xe7, 0x00, 0x99, 0x01, 0x2d, 0x08, 0xd0, + 0x00, 0x2d, 0x0b, 0xd0, 0xeb, 0x1e, 0x01, 0x2b, 0x08, 0xd9, 0x29, 0x00, + 0x02, 0x2d, 0x00, 0xd0, 0x7c, 0xe7, 0x03, 0x9b, 0x02, 0x9a, 0x38, 0x00, + 0xa0, 0x47, 0x77, 0xe7, 0x01, 0x21, 0xf8, 0xe7, 0xff, 0x7f, 0xff, 0xff, + 0xf0, 0xb5, 0x16, 0x27, 0x97, 0xb0, 0x1c, 0xab, 0x1b, 0x78, 0x04, 0x00, + 0x06, 0x93, 0x02, 0xab, 0xff, 0x18, 0x39, 0x80, 0xfb, 0x21, 0x05, 0x92, + 0xfe, 0xf7, 0x34, 0xfe, 0x05, 0x1e, 0x65, 0xdb, 0x3a, 0x88, 0x34, 0x4b, + 0x20, 0x00, 0x13, 0x43, 0x3b, 0x80, 0x09, 0xab, 0x00, 0x93, 0x1a, 0x23, + 0x02, 0xaa, 0x9b, 0x18, 0x21, 0x8a, 0x62, 0x69, 0xff, 0xf7, 0x5c, 0xfd, + 0x05, 0x1e, 0x55, 0xdb, 0x02, 0xab, 0x5b, 0x8b, 0x09, 0x9a, 0x1b, 0x03, + 0x52, 0x00, 0x9b, 0x18, 0x02, 0x22, 0x01, 0x97, 0x00, 0x92, 0x04, 0x21, + 0x00, 0x22, 0x20, 0x00, 0xfd, 0xf7, 0xb5, 0xf9, 0x05, 0x1e, 0x45, 0xdb, + 0xa3, 0x6b, 0x0a, 0xae, 0x01, 0x33, 0xa3, 0x63, 0x3b, 0x88, 0x2d, 0x20, + 0x33, 0x80, 0x00, 0x23, 0x73, 0x80, 0xf8, 0x33, 0x33, 0x71, 0x6b, 0x46, + 0x19, 0x7e, 0x02, 0xab, 0x31, 0x73, 0x01, 0x21, 0x49, 0x42, 0x0c, 0x91, + 0x20, 0x22, 0x05, 0x99, 0xc0, 0x18, 0x02, 0xf0, 0x9b, 0xfb, 0x09, 0x98, + 0x07, 0x21, 0x43, 0x1c, 0x02, 0xa8, 0x42, 0x8b, 0x1b, 0x02, 0x12, 0x03, + 0x9b, 0x18, 0x2e, 0x22, 0x01, 0x96, 0x00, 0x92, 0x20, 0x00, 0x00, 0x22, + 0xfd, 0xf7, 0x8d, 0xf9, 0x05, 0x1e, 0x1d, 0xdb, 0x01, 0x21, 0x49, 0x42, + 0x3b, 0x88, 0x02, 0x91, 0x02, 0xa9, 0x4a, 0x8b, 0x09, 0x99, 0x12, 0x01, + 0x8a, 0x18, 0x01, 0x32, 0x92, 0xb2, 0x01, 0x92, 0x00, 0x22, 0x31, 0x00, + 0x00, 0x92, 0x20, 0x00, 0x01, 0x32, 0xff, 0xf7, 0xe9, 0xfe, 0x1d, 0x9b, + 0x00, 0x2b, 0x07, 0xd0, 0x02, 0xab, 0x5b, 0x8b, 0x09, 0x9a, 0x1b, 0x01, + 0xd3, 0x18, 0x1d, 0x9a, 0x01, 0x33, 0x13, 0x80, 0x28, 0x00, 0x17, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, 0xf0, 0xb5, 0x89, 0xb0, + 0x05, 0x93, 0x80, 0x23, 0x0e, 0x9c, 0x1b, 0x02, 0x1a, 0x43, 0x06, 0x00, + 0x0f, 0x00, 0x04, 0x92, 0x00, 0x2c, 0x0e, 0xd1, 0x04, 0x21, 0x7a, 0x5e, + 0x41, 0x6a, 0x05, 0x9b, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, + 0x1b, 0x02, 0xea, 0x39, 0xfd, 0xf7, 0xeb, 0xf8, 0x05, 0x1e, 0x4e, 0xdb, + 0x74, 0x6a, 0x23, 0x79, 0xda, 0x07, 0x4d, 0xd4, 0x5a, 0xb2, 0x00, 0x2a, + 0x4c, 0xda, 0x9a, 0x07, 0x4c, 0xd4, 0x5b, 0x07, 0x4c, 0xd4, 0x63, 0x88, + 0x00, 0x2b, 0x4b, 0xd1, 0x0f, 0x9b, 0x00, 0x2b, 0x05, 0xd0, 0x20, 0x00, + 0x20, 0x22, 0x19, 0x00, 0x0d, 0x30, 0x02, 0xf0, 0x35, 0xfb, 0x11, 0x9b, + 0x00, 0x2b, 0x03, 0xd0, 0x23, 0x81, 0x11, 0x9b, 0x1b, 0x0c, 0x63, 0x81, + 0x39, 0x1e, 0x01, 0xd0, 0x04, 0x23, 0xf9, 0x5e, 0x16, 0x23, 0x02, 0xaa, + 0x9b, 0x18, 0x02, 0x93, 0x05, 0x9b, 0x22, 0x00, 0x01, 0x93, 0x00, 0x23, + 0x30, 0x00, 0x00, 0x93, 0x04, 0x9b, 0xff, 0xf7, 0x11, 0xfe, 0x05, 0x1e, + 0x1d, 0xd1, 0x02, 0xab, 0xd9, 0x8a, 0x12, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0x19, 0x80, 0x0e, 0x9a, 0x20, 0x89, 0x53, 0x42, 0x5a, 0x41, 0x63, 0x89, + 0x01, 0x91, 0x1b, 0x04, 0x03, 0x43, 0x02, 0x93, 0x63, 0x88, 0x92, 0x00, + 0x00, 0x93, 0x21, 0x00, 0x04, 0x9b, 0x30, 0x00, 0xff, 0xf7, 0x76, 0xfe, + 0x00, 0x2f, 0x04, 0xd0, 0x16, 0x23, 0x02, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0xbb, 0x81, 0x28, 0x00, 0x09, 0xb0, 0xf0, 0xbd, 0x04, 0x4d, 0xfa, 0xe7, + 0x04, 0x4d, 0xf8, 0xe7, 0x04, 0x4d, 0xf6, 0xe7, 0x04, 0x4d, 0xf4, 0xe7, + 0x04, 0x4d, 0xf2, 0xe7, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x93, 0xb0, 0x03, 0x93, 0x0d, 0x00, 0x0b, 0x02, 0x14, 0x00, + 0x04, 0x21, 0x52, 0x5e, 0x2e, 0x21, 0x06, 0xae, 0x00, 0x91, 0x01, 0x96, + 0x18, 0x39, 0x07, 0x00, 0xfd, 0xf7, 0x73, 0xf8, 0x00, 0x28, 0x33, 0xdb, + 0x0f, 0x23, 0x2b, 0x40, 0x2a, 0x09, 0x01, 0x3b, 0x12, 0x03, 0x5b, 0x00, + 0x9b, 0x18, 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, + 0x14, 0x21, 0x00, 0x92, 0x38, 0x00, 0x00, 0x22, 0xfd, 0xf7, 0x5f, 0xf8, + 0xa5, 0x81, 0x27, 0x60, 0xb3, 0x68, 0x6a, 0x46, 0xa3, 0x60, 0x00, 0x23, + 0x63, 0x61, 0x23, 0x82, 0x02, 0xab, 0xe5, 0x81, 0xdb, 0x89, 0x95, 0x89, + 0xe3, 0x80, 0xa5, 0x83, 0x32, 0x79, 0xd4, 0x07, 0x0f, 0xd4, 0x51, 0xb2, + 0x00, 0x29, 0x0f, 0xda, 0x02, 0x21, 0x0a, 0x42, 0x0e, 0xd1, 0x52, 0x07, + 0x0e, 0xd4, 0x1b, 0xb2, 0x00, 0x2b, 0x0b, 0xda, 0x73, 0x88, 0x00, 0x2b, + 0x02, 0xd0, 0x05, 0x48, 0x00, 0xe0, 0x05, 0x48, 0x13, 0xb0, 0xf0, 0xbd, + 0x04, 0x48, 0xfb, 0xe7, 0x04, 0x48, 0xf9, 0xe7, 0x04, 0x48, 0xf7, 0xe7, + 0xe3, 0xd8, 0xff, 0xff, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x95, 0xb0, + 0x0e, 0x93, 0x07, 0x68, 0x0d, 0x00, 0x0e, 0x99, 0x83, 0x68, 0x06, 0x00, + 0xfb, 0x31, 0x38, 0x00, 0x0f, 0x92, 0x06, 0x93, 0xfe, 0xf7, 0xe0, 0xfc, + 0x04, 0x1e, 0x00, 0xda, 0x0b, 0xe2, 0x06, 0x9b, 0x0a, 0x93, 0xab, 0x42, + 0x00, 0xd9, 0x0a, 0x95, 0x7b, 0x6a, 0xb2, 0x89, 0x06, 0x93, 0x10, 0xab, + 0x1a, 0x80, 0xfb, 0x21, 0x0a, 0x98, 0x02, 0xf0, 0x9d, 0xf9, 0xfb, 0x21, + 0x83, 0xb2, 0x0a, 0x98, 0x09, 0x93, 0x02, 0xf0, 0x1d, 0xfa, 0x4e, 0x4b, + 0x0c, 0x91, 0x0b, 0x93, 0x00, 0x23, 0x07, 0x93, 0x08, 0x93, 0x9c, 0x42, + 0x00, 0xd1, 0x2e, 0xe1, 0x0a, 0x9a, 0x08, 0x9b, 0x94, 0x46, 0x63, 0x44, + 0x09, 0x93, 0xb3, 0x60, 0x73, 0x61, 0x6b, 0x46, 0x9b, 0x8b, 0x10, 0xad, + 0x2a, 0x88, 0x33, 0x82, 0x07, 0x9b, 0xf2, 0x81, 0x00, 0x2b, 0x00, 0xd1, + 0x26, 0xe2, 0x31, 0x00, 0x38, 0x00, 0xff, 0xf7, 0x31, 0xf8, 0x00, 0x28, + 0x31, 0xdb, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfd, 0xf7, 0x3d, 0xf8, 0x00, 0x28, 0x22, 0xdb, 0x00, 0x22, 0x02, 0x92, + 0x2a, 0x88, 0x06, 0x98, 0x01, 0x92, 0xc2, 0x78, 0x81, 0x78, 0x12, 0x02, + 0x0a, 0x43, 0x00, 0x92, 0xf3, 0x88, 0x00, 0x22, 0x79, 0x6a, 0x38, 0x00, + 0xff, 0xf7, 0x9c, 0xfd, 0x1a, 0x21, 0x0a, 0xa8, 0x09, 0x18, 0x04, 0x91, + 0x00, 0x21, 0x09, 0x98, 0xb3, 0x89, 0xf2, 0x88, 0x03, 0x90, 0x02, 0x91, + 0x01, 0x91, 0x00, 0x91, 0x38, 0x00, 0x31, 0x00, 0xff, 0xf7, 0xb4, 0xfe, + 0x00, 0x28, 0x00, 0xdb, 0xa5, 0xe1, 0x04, 0x00, 0xa3, 0xe1, 0x1a, 0x20, + 0x03, 0x91, 0x0a, 0xac, 0x0b, 0x99, 0x00, 0x19, 0x04, 0x90, 0x02, 0x91, + 0x01, 0x91, 0x79, 0x6a, 0xb3, 0x89, 0xf2, 0x88, 0x00, 0x91, 0x31, 0x00, + 0x38, 0x00, 0xff, 0xf7, 0x9f, 0xfe, 0x11, 0xe1, 0x10, 0xad, 0x2a, 0x88, + 0x0b, 0x9b, 0x31, 0x00, 0x38, 0x00, 0xfe, 0xf7, 0xe3, 0xff, 0x04, 0x1e, + 0x00, 0xda, 0x88, 0xe1, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, + 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, + 0x38, 0x00, 0xfc, 0xf7, 0xee, 0xff, 0x04, 0x1e, 0x00, 0xda, 0x78, 0xe1, + 0x00, 0x24, 0x02, 0x94, 0x2a, 0x88, 0xf3, 0x88, 0x01, 0x92, 0x06, 0x9a, + 0x38, 0x00, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, 0x00, 0x92, + 0x79, 0x6a, 0x22, 0x00, 0xff, 0xf7, 0x4c, 0xfd, 0x1a, 0x21, 0x0a, 0xa8, + 0x09, 0x18, 0x04, 0x91, 0x0a, 0x98, 0x08, 0x99, 0xb3, 0x89, 0x09, 0x18, + 0xf2, 0x88, 0x03, 0x91, 0x02, 0x94, 0x01, 0x94, 0x00, 0x94, 0xc2, 0xe7, + 0xff, 0xff, 0x00, 0x00, 0xb3, 0x68, 0x58, 0x1e, 0xc6, 0x4b, 0x98, 0x42, + 0x0f, 0xd9, 0x08, 0x9b, 0x00, 0x2b, 0x0c, 0xd1, 0xfb, 0x21, 0x02, 0xf0, + 0xed, 0xf8, 0x7c, 0x21, 0x69, 0x38, 0x02, 0xf0, 0xe9, 0xf8, 0x07, 0x9b, + 0x01, 0x30, 0x80, 0xb2, 0x83, 0x42, 0x00, 0xd8, 0xfb, 0xe0, 0x80, 0x23, + 0xf1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x6b, 0x46, 0x9b, 0x8b, 0x12, 0xad, + 0x6b, 0x80, 0xf9, 0x23, 0x2b, 0x71, 0x10, 0xab, 0x29, 0x80, 0x03, 0x93, + 0x01, 0x23, 0x02, 0x93, 0x00, 0x23, 0x2a, 0x00, 0x01, 0x93, 0x00, 0x93, + 0x38, 0x00, 0xff, 0xf7, 0xe1, 0xfb, 0x04, 0x1e, 0x00, 0xda, 0x2a, 0xe1, + 0x80, 0x22, 0xff, 0x21, 0x52, 0x00, 0x78, 0x6a, 0x02, 0xf0, 0x7d, 0xf9, + 0x05, 0x22, 0x29, 0x00, 0x78, 0x6a, 0x02, 0xf0, 0x6f, 0xf9, 0x00, 0x22, + 0x02, 0x92, 0x0a, 0xaa, 0x12, 0x8b, 0xf3, 0x88, 0x01, 0x92, 0x07, 0x9a, + 0x38, 0x00, 0x00, 0x92, 0x79, 0x6a, 0x01, 0x22, 0xff, 0xf7, 0xf6, 0xfc, + 0x10, 0xab, 0x1b, 0x88, 0x0a, 0x9a, 0xf3, 0x81, 0x6b, 0x46, 0x9b, 0x8b, + 0x33, 0x82, 0x08, 0x9b, 0x9b, 0x18, 0x73, 0x61, 0xb3, 0x60, 0x07, 0x9b, + 0x0b, 0x93, 0x08, 0x9a, 0x0e, 0x9b, 0x0c, 0x99, 0x9b, 0x1a, 0xfb, 0x22, + 0x52, 0x1a, 0x0d, 0x92, 0x9a, 0x42, 0x00, 0xd9, 0x0d, 0x93, 0x0c, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0xfa, 0xe0, 0x6b, 0x46, 0x9b, 0x8c, 0x12, 0xaa, + 0xf1, 0x88, 0x53, 0x80, 0xfd, 0x23, 0x08, 0x98, 0x13, 0x71, 0x0f, 0x9b, + 0x49, 0x04, 0x49, 0x0c, 0x1b, 0x18, 0x11, 0xa8, 0x11, 0x80, 0x03, 0x90, + 0x01, 0x20, 0x02, 0x90, 0x0c, 0x98, 0x01, 0x90, 0x0d, 0x98, 0x00, 0x90, + 0x38, 0x00, 0xff, 0xf7, 0x93, 0xfb, 0x04, 0x1e, 0x00, 0xd0, 0xed, 0xe6, + 0x11, 0xab, 0x1d, 0x88, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x11, 0xe1, + 0x09, 0x9b, 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9d, 0x52, 0x0a, 0x9a, + 0x08, 0x9b, 0x9b, 0x18, 0x06, 0x9a, 0x13, 0x81, 0x1b, 0x0c, 0x53, 0x81, + 0x0d, 0x9a, 0x09, 0x98, 0x94, 0x46, 0x01, 0x30, 0x83, 0xb2, 0x09, 0x93, + 0x08, 0x9b, 0x63, 0x44, 0x08, 0x93, 0x00, 0x23, 0x0c, 0x93, 0x08, 0x9b, + 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd3, 0xcb, 0xe6, 0x00, 0x23, 0x07, 0x93, + 0x09, 0x9b, 0x68, 0x2b, 0x07, 0xd9, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x02, 0xf0, 0x50, 0xf8, 0x01, 0x30, 0x83, 0xb2, 0x07, 0x93, 0x0b, 0x9b, + 0x07, 0x9a, 0x93, 0x42, 0xa3, 0xd0, 0x08, 0x9b, 0x00, 0x2b, 0x2d, 0xd0, + 0x0b, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x0f, 0xe7, 0x08, 0x9b, 0x0a, 0x9a, + 0x99, 0x18, 0x06, 0x9b, 0x06, 0x9a, 0x19, 0x81, 0x0b, 0x0c, 0x53, 0x81, + 0x0a, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0xf2, 0xe6, 0x10, 0xad, 0x2a, 0x88, + 0x31, 0x00, 0x38, 0x00, 0xfe, 0xf7, 0xe8, 0xfe, 0x04, 0x1e, 0x00, 0xda, + 0x8d, 0xe0, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfc, 0xf7, 0xf3, 0xfe, 0x04, 0x1e, 0x00, 0xda, 0x7d, 0xe0, 0x08, 0x9b, + 0x0a, 0x9a, 0x9b, 0x18, 0xb3, 0x60, 0x73, 0x61, 0x07, 0x9b, 0x00, 0x2b, + 0x00, 0xd0, 0x1b, 0xe7, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x10, 0xab, + 0x1b, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, + 0xea, 0x39, 0x38, 0x00, 0xfc, 0xf7, 0x75, 0xfe, 0x04, 0x1e, 0x64, 0xdb, + 0x01, 0x22, 0x06, 0x9b, 0x1b, 0x79, 0x13, 0x42, 0x00, 0xd0, 0xe9, 0xe0, + 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xe7, 0xe0, 0x9a, 0x07, 0x00, 0xd5, + 0xe6, 0xe0, 0x5b, 0x07, 0x00, 0xd5, 0xe5, 0xe0, 0x06, 0x22, 0xb3, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0xe0, 0xe0, 0x06, 0x9b, 0x5b, 0x88, 0x0b, 0x93, + 0x00, 0x2b, 0x00, 0xd1, 0x43, 0xe7, 0x41, 0x4c, 0x47, 0xe0, 0x33, 0x8a, + 0x07, 0x9a, 0x93, 0x42, 0x34, 0xd1, 0x1e, 0x23, 0xf2, 0x89, 0x0a, 0xa9, + 0x5b, 0x18, 0x1a, 0x80, 0x1e, 0x25, 0x0a, 0xab, 0x04, 0x21, 0x72, 0x5e, + 0x79, 0x6a, 0xed, 0x18, 0x2b, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, + 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x38, 0x00, 0xfc, 0xf7, 0x3d, 0xfe, + 0x04, 0x1e, 0x2c, 0xdb, 0x01, 0x22, 0x06, 0x9b, 0x1b, 0x79, 0x13, 0x42, + 0x00, 0xd0, 0xb1, 0xe0, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xaf, 0xe0, + 0x9a, 0x07, 0x00, 0xd5, 0xae, 0xe0, 0x5b, 0x07, 0x00, 0xd5, 0xad, 0xe0, + 0x06, 0x22, 0xb3, 0x5e, 0x00, 0x2b, 0x00, 0xdb, 0xa8, 0xe0, 0x06, 0x9b, + 0x07, 0x9a, 0x5b, 0x88, 0x93, 0x42, 0xc8, 0xd1, 0x2a, 0x88, 0x10, 0xab, + 0x1a, 0x80, 0xfb, 0xe6, 0x80, 0x23, 0xf1, 0x88, 0x1b, 0x02, 0x19, 0x43, + 0x1e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, 0x00, 0x93, 0x07, 0x9a, 0x08, 0x9b, + 0x38, 0x00, 0xff, 0xf7, 0x45, 0xfa, 0x04, 0x1e, 0xc0, 0xda, 0x20, 0x00, + 0x15, 0xb0, 0xf0, 0xbd, 0x07, 0x9b, 0x00, 0x2b, 0x21, 0xd1, 0x09, 0x9b, + 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9a, 0x5a, 0x11, 0xab, 0x1a, 0x80, + 0x11, 0xad, 0x2a, 0x88, 0x31, 0x1d, 0x09, 0x9b, 0x38, 0x00, 0xfe, 0xf7, + 0x97, 0xff, 0x04, 0x1e, 0xe9, 0xdb, 0x2b, 0x88, 0x0c, 0x9a, 0x1b, 0x02, + 0x05, 0x33, 0x08, 0x98, 0x9b, 0x18, 0x04, 0x21, 0x72, 0x5e, 0x0f, 0x99, + 0x09, 0x18, 0x01, 0x91, 0x0d, 0x99, 0x38, 0x00, 0x00, 0x91, 0x07, 0x21, + 0xfc, 0xf7, 0x4b, 0xfe, 0xf7, 0xe6, 0x09, 0x9b, 0x19, 0x1d, 0x68, 0x2b, + 0x05, 0xd9, 0x09, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0xf4, 0xff, + 0x04, 0x31, 0x06, 0x9b, 0x49, 0x00, 0x5a, 0x5a, 0xd4, 0xe7, 0xc0, 0x46, + 0xf2, 0x66, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, 0x09, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x09, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0xe1, 0xff, 0x04, 0x31, 0x06, 0x9b, 0x49, 0x00, 0x5d, 0x52, 0xeb, 0xe6, + 0x0a, 0x9b, 0x00, 0x2b, 0x31, 0xd1, 0x69, 0x46, 0x06, 0x9b, 0x09, 0x8c, + 0x38, 0x00, 0x19, 0x81, 0x08, 0x9b, 0x06, 0x99, 0x1b, 0x0c, 0x4b, 0x81, + 0x0a, 0x9b, 0x31, 0x00, 0xfe, 0xf7, 0xfe, 0xfd, 0x00, 0x28, 0x00, 0xda, + 0xfd, 0xe5, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfc, 0xf7, 0x09, 0xfe, 0x00, 0x28, 0x00, 0xda, 0xed, 0xe5, 0x06, 0x9a, + 0xf3, 0x88, 0x11, 0x89, 0x52, 0x89, 0x38, 0x00, 0x12, 0x04, 0x0a, 0x43, + 0x02, 0x92, 0x2a, 0x88, 0x01, 0x92, 0x06, 0x9a, 0x52, 0x88, 0x00, 0x92, + 0x79, 0x6a, 0x04, 0x22, 0xff, 0xf7, 0x66, 0xfb, 0x81, 0xe7, 0x1a, 0x21, + 0x0a, 0xa8, 0x09, 0x18, 0x04, 0x91, 0x09, 0x99, 0xb3, 0x89, 0x03, 0x91, + 0x07, 0x99, 0xf2, 0x88, 0x02, 0x91, 0x01, 0x91, 0x79, 0x6a, 0xc6, 0xe5, + 0x03, 0x4c, 0x72, 0xe7, 0x03, 0x4c, 0x70, 0xe7, 0x03, 0x4c, 0x6e, 0xe7, + 0x03, 0x4c, 0x6c, 0xe7, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x95, 0xb0, + 0x0d, 0x91, 0x19, 0x00, 0x05, 0x68, 0x07, 0x00, 0xfb, 0x31, 0x28, 0x00, + 0x0f, 0x92, 0x0e, 0x93, 0xfe, 0xf7, 0x2a, 0xfa, 0x04, 0x1e, 0x00, 0xda, + 0x6e, 0xe1, 0x6b, 0x6a, 0xfb, 0x21, 0x07, 0x93, 0xbb, 0x89, 0x0d, 0x98, + 0x0b, 0x93, 0x01, 0xf0, 0xed, 0xfe, 0xfb, 0x21, 0x83, 0xb2, 0x0d, 0x98, + 0x08, 0x93, 0x01, 0xf0, 0x6d, 0xff, 0x00, 0x23, 0x0a, 0x91, 0xc1, 0x4e, + 0x06, 0x93, 0x09, 0x93, 0x9c, 0x42, 0x00, 0xd1, 0x2c, 0xe1, 0x0d, 0x9a, + 0x09, 0x9b, 0x94, 0x46, 0x63, 0x44, 0x7b, 0x61, 0x6b, 0x46, 0x9b, 0x8d, + 0xfb, 0x81, 0x6b, 0x46, 0x1b, 0x8b, 0x3b, 0x82, 0x06, 0x9b, 0x00, 0x2b, + 0x00, 0xd1, 0xf4, 0xe1, 0x0b, 0x9a, 0x39, 0x00, 0x28, 0x00, 0xfe, 0xf7, + 0x83, 0xfd, 0x00, 0x28, 0x00, 0xda, 0xff, 0xe1, 0x04, 0x22, 0xb9, 0x5e, + 0x1e, 0x22, 0x00, 0x26, 0x0a, 0xa8, 0x12, 0x18, 0xfb, 0x88, 0x02, 0x92, + 0x0b, 0x9a, 0x00, 0x96, 0x01, 0x92, 0x28, 0x00, 0x07, 0x9a, 0xff, 0xf7, + 0x7f, 0xfa, 0x0a, 0xab, 0xda, 0x8b, 0x6b, 0x46, 0x1b, 0x8b, 0xfa, 0x81, + 0x3b, 0x82, 0xb0, 0x42, 0x00, 0xda, 0xe7, 0xe1, 0xfb, 0x88, 0x01, 0x92, + 0x07, 0x9a, 0x02, 0x96, 0x91, 0x78, 0xd2, 0x78, 0x28, 0x00, 0x12, 0x02, + 0x0a, 0x43, 0x00, 0x92, 0x07, 0x99, 0x32, 0x00, 0xff, 0xf7, 0xe6, 0xfa, + 0x1a, 0xe1, 0x00, 0x23, 0x06, 0x93, 0x33, 0x00, 0x0b, 0x9a, 0x39, 0x00, + 0x28, 0x00, 0xfe, 0xf7, 0x51, 0xfd, 0x04, 0x1e, 0x00, 0xda, 0x0f, 0xe1, + 0x04, 0x22, 0xb9, 0x5e, 0x1e, 0x22, 0x00, 0x26, 0x0a, 0xa8, 0x12, 0x18, + 0xfb, 0x88, 0x02, 0x92, 0x0b, 0x9a, 0x00, 0x96, 0x01, 0x92, 0x28, 0x00, + 0x07, 0x9a, 0xff, 0xf7, 0x4d, 0xfa, 0x04, 0x00, 0xb0, 0x42, 0x00, 0xda, + 0xfc, 0xe0, 0xfb, 0x88, 0x0a, 0xaa, 0x02, 0x96, 0xd2, 0x8b, 0x28, 0x00, + 0x01, 0x92, 0x07, 0x9a, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, + 0x00, 0x92, 0x07, 0x99, 0x32, 0x00, 0xff, 0xf7, 0xb7, 0xfa, 0x06, 0x9b, + 0xb3, 0x42, 0x29, 0xd1, 0x04, 0x21, 0x7a, 0x5e, 0x69, 0x6a, 0x0b, 0x9b, + 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, + 0x28, 0x00, 0xfc, 0xf7, 0xd2, 0xfc, 0x04, 0x1e, 0x00, 0xda, 0xd9, 0xe0, + 0x07, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x00, 0xd5, 0x94, 0xe1, 0x5a, 0xb2, + 0x00, 0x2a, 0x00, 0xdb, 0x92, 0xe1, 0x9a, 0x07, 0x00, 0xd5, 0x91, 0xe1, + 0x5b, 0x07, 0x00, 0xd5, 0x90, 0xe1, 0x06, 0x22, 0xbb, 0x5e, 0x00, 0x2b, + 0x00, 0xdb, 0x8b, 0xe1, 0x07, 0x9b, 0x5b, 0x88, 0x00, 0x2b, 0x39, 0xd0, + 0x73, 0x4c, 0xbf, 0xe0, 0x3b, 0x8a, 0x06, 0x9a, 0x93, 0x42, 0x00, 0xd0, + 0xbd, 0xe0, 0x1e, 0x23, 0xfa, 0x89, 0x0a, 0xa9, 0x5b, 0x18, 0x1a, 0x80, + 0x1e, 0x26, 0x04, 0x21, 0x7a, 0x5e, 0x0a, 0xab, 0x69, 0x6a, 0xf6, 0x18, + 0x33, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, + 0xea, 0x39, 0x28, 0x00, 0xfc, 0xf7, 0x9b, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0xa2, 0xe0, 0x07, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x00, 0xd5, 0x5d, 0xe1, + 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0x5b, 0xe1, 0x9a, 0x07, 0x00, 0xd5, + 0x5a, 0xe1, 0x5b, 0x07, 0x00, 0xd5, 0x59, 0xe1, 0x06, 0x22, 0xbb, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0x54, 0xe1, 0x07, 0x9b, 0x06, 0x9a, 0x5b, 0x88, + 0x93, 0x42, 0xc7, 0xd1, 0x33, 0x88, 0x0b, 0x93, 0x6b, 0x46, 0x9b, 0x8d, + 0x0d, 0x9a, 0xfb, 0x81, 0x6b, 0x46, 0x1b, 0x8b, 0x3b, 0x82, 0x09, 0x9b, + 0x9b, 0x18, 0x7b, 0x61, 0x09, 0x9a, 0x0e, 0x9b, 0x0a, 0x99, 0x9b, 0x1a, + 0xfb, 0x22, 0x56, 0x1a, 0x9e, 0x42, 0x00, 0xd9, 0x1e, 0x00, 0x06, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x84, 0xe0, 0x08, 0x9b, 0x07, 0x9a, 0x17, 0x33, + 0x5b, 0x00, 0x9b, 0x5a, 0x0c, 0x93, 0x00, 0x23, 0x06, 0x93, 0x6b, 0x46, + 0x1b, 0x8c, 0x12, 0xaa, 0xf9, 0x88, 0x53, 0x80, 0xff, 0x23, 0x49, 0x04, + 0x13, 0x71, 0x0a, 0x9b, 0x49, 0x0c, 0x11, 0x80, 0x00, 0x2b, 0x00, 0xd0, + 0x82, 0xe0, 0xfb, 0x2e, 0x00, 0xd0, 0x7f, 0xe0, 0x09, 0x98, 0x0f, 0x9b, + 0x00, 0x96, 0x1b, 0x18, 0x11, 0xa8, 0x03, 0x90, 0x01, 0x20, 0x02, 0x90, + 0x0a, 0x98, 0x01, 0x90, 0x28, 0x00, 0xff, 0xf7, 0xe5, 0xf8, 0x0c, 0x99, + 0x28, 0x00, 0xff, 0xf7, 0x63, 0xf9, 0x04, 0x1e, 0x00, 0xd0, 0xea, 0xe6, + 0x11, 0xab, 0x1b, 0x88, 0x0a, 0x93, 0x06, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0xd7, 0xe0, 0x69, 0x46, 0x08, 0x9b, 0x07, 0x9a, 0x17, 0x33, 0x09, 0x8d, + 0x5b, 0x00, 0x99, 0x52, 0x08, 0x98, 0x01, 0x30, 0x83, 0xb2, 0x08, 0x93, + 0x09, 0x9b, 0x9b, 0x19, 0x09, 0x93, 0x00, 0x23, 0x06, 0x9e, 0x0a, 0x93, + 0x09, 0x9b, 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd3, 0xcd, 0xe6, 0x08, 0x9b, + 0x68, 0x2b, 0x00, 0xd8, 0xf5, 0xe0, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x01, 0xf0, 0xa4, 0xfd, 0x01, 0x30, 0x83, 0xb2, 0x06, 0x93, 0x9e, 0x42, + 0x9a, 0xd0, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd1, 0x54, 0xe7, 0x00, 0x2e, + 0x00, 0xd0, 0xf8, 0xe6, 0x1a, 0x21, 0x0a, 0xa8, 0x09, 0x18, 0xbb, 0x89, + 0xfa, 0x88, 0x03, 0x94, 0x02, 0x94, 0x01, 0x94, 0x04, 0x91, 0x69, 0x6a, + 0x28, 0x00, 0x00, 0x91, 0x39, 0x00, 0xff, 0xf7, 0xf5, 0xfa, 0x04, 0x1e, + 0x00, 0xdb, 0x3f, 0xe7, 0x20, 0x00, 0x15, 0xb0, 0xf0, 0xbd, 0x80, 0x23, + 0xf9, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x06, 0x9a, 0x00, 0x23, 0x28, 0x00, 0xff, 0xf7, 0x1a, 0xf8, + 0x04, 0x1e, 0x00, 0xdb, 0x36, 0xe7, 0xeb, 0xe7, 0x08, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x08, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0xef, 0xfd, 0x04, 0x31, 0x07, 0x9b, 0x49, 0x00, 0x5b, 0x5a, 0x0c, 0x93, + 0x73, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, + 0x39, 0x1d, 0x08, 0x9b, 0x0c, 0x9a, 0x28, 0x00, 0xfe, 0xf7, 0x64, 0xfd, + 0x04, 0x1e, 0xcf, 0xdb, 0x11, 0xab, 0xf9, 0x88, 0x03, 0x93, 0x00, 0x23, + 0x49, 0x04, 0x49, 0x0c, 0x02, 0x93, 0x01, 0x93, 0x00, 0x93, 0x12, 0xaa, + 0x28, 0x00, 0xff, 0xf7, 0x5d, 0xf8, 0x04, 0x1e, 0x00, 0xd0, 0x66, 0xe6, + 0x0a, 0x9b, 0x00, 0x2b, 0x2e, 0xd1, 0x0a, 0x9b, 0x98, 0x19, 0xfa, 0x28, + 0x3b, 0xd9, 0x0a, 0xab, 0x9b, 0x8b, 0x0a, 0x9a, 0x1b, 0x02, 0x05, 0x33, + 0x09, 0x98, 0x9b, 0x18, 0x04, 0x21, 0x7a, 0x5e, 0x0f, 0x99, 0x00, 0x96, + 0x09, 0x18, 0x01, 0x91, 0x28, 0x00, 0x07, 0x21, 0xfc, 0xf7, 0x01, 0xfc, + 0x04, 0x1e, 0x00, 0xd0, 0x4b, 0xe6, 0x02, 0x21, 0x12, 0xaa, 0x13, 0x79, + 0x28, 0x00, 0x8b, 0x43, 0x13, 0x71, 0x04, 0x21, 0x7a, 0x5e, 0x0a, 0xab, + 0x13, 0xa9, 0x9b, 0x8b, 0x01, 0x91, 0x01, 0x21, 0x1b, 0x02, 0x00, 0x91, + 0x04, 0x33, 0x06, 0x31, 0xfc, 0xf7, 0xeb, 0xfb, 0x04, 0x1e, 0x00, 0xd1, + 0x43, 0xe7, 0x34, 0xe6, 0x0a, 0xaa, 0x92, 0x8b, 0x0c, 0x9b, 0x04, 0x20, + 0x39, 0x5e, 0x0a, 0x98, 0x1b, 0x02, 0x12, 0x02, 0x00, 0x90, 0x05, 0x33, + 0x05, 0x32, 0x28, 0x00, 0xfe, 0xf7, 0xa4, 0xfd, 0x04, 0x1e, 0xc0, 0xd0, + 0x23, 0xe6, 0x0a, 0x9b, 0x0c, 0x9a, 0x05, 0x33, 0x12, 0x02, 0x9b, 0x19, + 0x9b, 0x18, 0x11, 0xaa, 0x12, 0x88, 0x0a, 0x99, 0x12, 0x02, 0x05, 0x32, + 0x52, 0x18, 0x04, 0x24, 0x39, 0x5f, 0xfb, 0x24, 0x20, 0x1a, 0x00, 0x90, + 0x92, 0x19, 0x28, 0x00, 0xfe, 0xf7, 0x8c, 0xfd, 0x04, 0x1e, 0xac, 0xd0, + 0x0b, 0xe6, 0x08, 0x9b, 0x19, 0x1d, 0x68, 0x2b, 0x05, 0xd9, 0x08, 0x98, + 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0x68, 0xfd, 0x04, 0x31, 0x6a, 0x46, + 0x07, 0x9b, 0x12, 0x8d, 0x49, 0x00, 0x5a, 0x52, 0x1e, 0xe7, 0x1a, 0x21, + 0x0a, 0xa8, 0x09, 0x18, 0xbb, 0x89, 0xfa, 0x88, 0x04, 0x91, 0x06, 0x99, + 0x28, 0x00, 0x03, 0x91, 0x02, 0x91, 0x01, 0x91, 0x69, 0x6a, 0x00, 0x91, + 0x39, 0x00, 0xff, 0xf7, 0x37, 0xfa, 0x00, 0x28, 0x00, 0xdb, 0x41, 0xe7, + 0x04, 0x00, 0x3f, 0xe7, 0x0d, 0x4c, 0x3d, 0xe7, 0x0d, 0x4c, 0x3b, 0xe7, + 0x0d, 0x4c, 0x39, 0xe7, 0x0d, 0x4c, 0x37, 0xe7, 0x09, 0x9a, 0x0e, 0x9b, + 0x0a, 0x99, 0x9b, 0x1a, 0xfb, 0x22, 0x56, 0x1a, 0x9e, 0x42, 0x00, 0xd8, + 0xbd, 0xe6, 0x1e, 0x00, 0xbb, 0xe6, 0x00, 0x2e, 0xf2, 0xd0, 0x09, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x0b, 0xe6, 0x06, 0x93, 0x3a, 0xe6, 0xc0, 0x46, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0x70, 0xb5, 0x88, 0xb0, 0x07, 0xab, 0x1a, 0x26, + 0x04, 0x00, 0x05, 0x93, 0x08, 0x00, 0x00, 0x23, 0x15, 0x00, 0x0f, 0x4a, + 0x6e, 0x44, 0x03, 0x93, 0x02, 0x90, 0x01, 0x92, 0x00, 0x93, 0x21, 0x8b, + 0x04, 0x96, 0xe2, 0x69, 0x20, 0x00, 0xfe, 0xf7, 0x55, 0xfd, 0x0a, 0x4b, + 0x98, 0x42, 0x0d, 0xd0, 0x00, 0x28, 0x09, 0xdb, 0x31, 0x88, 0x07, 0x9a, + 0x00, 0x2d, 0x03, 0xd0, 0x0b, 0x01, 0x9b, 0x18, 0x01, 0x33, 0x2b, 0x80, + 0x21, 0x83, 0xe2, 0x61, 0x08, 0xb0, 0x70, 0xbd, 0x02, 0x48, 0xfb, 0xe7, + 0xcd, 0x48, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x83, 0x68, 0x93, 0xb0, 0x01, 0x3b, 0x04, 0x00, 0x0b, 0x91, + 0x07, 0x92, 0x06, 0x68, 0x03, 0x33, 0x00, 0xd8, 0xd6, 0xe0, 0x00, 0x25, + 0xaa, 0x42, 0x00, 0xd1, 0xde, 0xe0, 0x1a, 0x23, 0xa5, 0x89, 0x08, 0xaa, + 0xa7, 0x68, 0x9b, 0x18, 0x1d, 0x80, 0x00, 0x2f, 0x00, 0xd0, 0xd8, 0xe0, + 0x06, 0x97, 0x73, 0x6a, 0x08, 0x93, 0x07, 0x9b, 0x00, 0x2b, 0x13, 0xd0, + 0x0b, 0x9b, 0x00, 0x2b, 0x10, 0xd1, 0x10, 0xa9, 0xb8, 0x33, 0x0b, 0x70, + 0x01, 0x91, 0x01, 0x21, 0x2d, 0x02, 0x2b, 0x1d, 0x04, 0x20, 0x22, 0x5e, + 0x00, 0x91, 0x30, 0x00, 0x05, 0x31, 0xfc, 0xf7, 0x18, 0xfb, 0x05, 0x1e, + 0x00, 0xda, 0xbb, 0xe0, 0x9f, 0x4b, 0x0c, 0x93, 0x00, 0x23, 0x09, 0x93, + 0x0b, 0x9b, 0x9f, 0x42, 0x00, 0xd8, 0xfd, 0xe0, 0x06, 0x9b, 0x68, 0x2b, + 0x00, 0xd8, 0x14, 0xe2, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0x31, 0xfc, 0x01, 0x30, 0x83, 0xb2, 0x0a, 0x93, 0x0a, 0x9a, 0x0c, 0x9b, + 0x93, 0x42, 0x00, 0xd1, 0x0e, 0xe2, 0x0c, 0x9b, 0x1a, 0x00, 0x92, 0x4b, + 0x9a, 0x42, 0x29, 0xd0, 0x08, 0xab, 0x5a, 0x8b, 0x21, 0x00, 0x0c, 0x9b, + 0x30, 0x00, 0xfe, 0xf7, 0xd5, 0xfa, 0x05, 0x1e, 0x00, 0xda, 0x93, 0xe0, + 0x08, 0xab, 0x59, 0x8b, 0x30, 0x00, 0xfe, 0xf7, 0xab, 0xff, 0x05, 0x1e, + 0x00, 0xda, 0x8b, 0xe0, 0x00, 0x21, 0x08, 0xaa, 0x02, 0x91, 0x52, 0x8b, + 0xe3, 0x88, 0x01, 0x92, 0x08, 0x9a, 0x90, 0x78, 0xd2, 0x78, 0x12, 0x02, + 0x02, 0x43, 0x00, 0x92, 0x30, 0x00, 0x02, 0x22, 0xff, 0xf7, 0x46, 0xf8, + 0x0c, 0x9b, 0x00, 0x2b, 0x04, 0xd0, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd1, + 0x82, 0xe0, 0xa7, 0x60, 0x0a, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x8e, 0xe0, + 0xa2, 0x89, 0x1a, 0x33, 0x08, 0xa9, 0x5b, 0x18, 0x1a, 0x80, 0x04, 0x21, + 0x62, 0x5e, 0x71, 0x6a, 0x08, 0xab, 0x5b, 0x8b, 0x01, 0x91, 0x80, 0x21, + 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x30, 0x00, 0xfc, 0xf7, + 0x52, 0xfa, 0x05, 0x1e, 0x5a, 0xdb, 0x08, 0x9b, 0x1b, 0x79, 0xda, 0x07, + 0x00, 0xd5, 0xb0, 0xe1, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xae, 0xe1, + 0x9a, 0x07, 0x00, 0xd5, 0xad, 0xe1, 0x5b, 0x07, 0x00, 0xd5, 0xac, 0xe1, + 0x06, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x00, 0xdb, 0xa7, 0xe1, 0x08, 0x9b, + 0x0a, 0x9a, 0x5b, 0x88, 0x09, 0x93, 0x93, 0x42, 0x00, 0xd0, 0xa2, 0xe1, + 0x08, 0xab, 0x5b, 0x8b, 0x67, 0x61, 0xe3, 0x81, 0x6b, 0x46, 0x1b, 0x8d, + 0x23, 0x82, 0x00, 0x2a, 0x00, 0xd0, 0x65, 0xe0, 0x06, 0x9b, 0x08, 0x9a, + 0x17, 0x33, 0x5b, 0x00, 0xd3, 0x18, 0x1a, 0x88, 0x0d, 0x92, 0x01, 0x22, + 0x52, 0x42, 0x1a, 0x80, 0x00, 0x23, 0x0c, 0x93, 0x09, 0x93, 0x0b, 0x9b, + 0x21, 0x1d, 0x00, 0x2b, 0x07, 0xd0, 0x07, 0x9b, 0x00, 0x2b, 0x04, 0xd1, + 0x0b, 0x9b, 0xfb, 0x1a, 0xfa, 0x2b, 0x00, 0xd8, 0xa6, 0xe0, 0x06, 0x9b, + 0x0d, 0x9a, 0x30, 0x00, 0xfe, 0xf7, 0xaa, 0xfb, 0x4e, 0x4b, 0x98, 0x42, + 0x59, 0xd1, 0xfb, 0x21, 0x38, 0x00, 0x01, 0xf0, 0x1d, 0xfc, 0x00, 0x29, + 0x00, 0xd1, 0x89, 0xe0, 0x7f, 0x1a, 0x88, 0xe0, 0x07, 0x9b, 0x00, 0x2b, + 0x00, 0xd0, 0x28, 0xe7, 0xfb, 0x21, 0x30, 0x00, 0x49, 0x00, 0xfd, 0xf7, + 0xbb, 0xfe, 0x05, 0x1e, 0x00, 0xdb, 0x20, 0xe7, 0x28, 0x00, 0x13, 0xb0, + 0xf0, 0xbd, 0x78, 0x1e, 0xfb, 0x21, 0x01, 0xf0, 0x7f, 0xfb, 0x83, 0xb2, + 0x06, 0x93, 0x7b, 0x1c, 0x00, 0xd0, 0x1e, 0xe7, 0x00, 0x27, 0x1c, 0xe7, + 0x0f, 0xa9, 0x04, 0x91, 0x07, 0x99, 0xa3, 0x89, 0x02, 0x91, 0x01, 0x91, + 0x00, 0x91, 0xe2, 0x88, 0x03, 0x97, 0x21, 0x00, 0x30, 0x00, 0xff, 0xf7, + 0xd7, 0xf8, 0x05, 0x1e, 0x00, 0xdb, 0x6c, 0xe7, 0xe0, 0xe7, 0x80, 0x23, + 0xe1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1a, 0x23, 0x08, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x0a, 0x9a, 0x00, 0x23, 0x30, 0x00, 0xfe, 0xf7, 0xfe, 0xfd, + 0x05, 0x1e, 0x00, 0xdb, 0x65, 0xe7, 0xcf, 0xe7, 0x06, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x06, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0xd3, 0xfb, 0x04, 0x31, 0x08, 0x9b, 0x49, 0x00, 0x59, 0x18, 0x0b, 0x88, + 0x0d, 0x93, 0x01, 0x23, 0x5b, 0x42, 0x0b, 0x80, 0x0a, 0x9b, 0x0c, 0x93, + 0x91, 0xe7, 0x00, 0x28, 0x2c, 0xd0, 0x20, 0x4b, 0x98, 0x42, 0xa0, 0xd0, + 0x08, 0xab, 0x5d, 0x8b, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0xcf, 0xe0, + 0x00, 0x2f, 0x00, 0xd0, 0xc4, 0xe0, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd1, + 0xa7, 0xe0, 0x2a, 0x00, 0x3b, 0x00, 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, + 0xe1, 0xf9, 0x05, 0x1e, 0xa0, 0xdb, 0x08, 0xab, 0x59, 0x8b, 0x30, 0x00, + 0xfe, 0xf7, 0xb8, 0xfe, 0x05, 0x1e, 0x00, 0xda, 0x98, 0xe7, 0x02, 0x97, + 0x08, 0xaa, 0x52, 0x8b, 0xe3, 0x88, 0x01, 0x92, 0x00, 0x97, 0x02, 0x22, + 0x39, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0x58, 0xff, 0xa7, 0x60, 0x8b, 0xe7, + 0x0d, 0x99, 0x30, 0x00, 0xfe, 0xf7, 0xa4, 0xfe, 0x00, 0x28, 0x00, 0xd1, + 0x6f, 0xe7, 0xcd, 0xe7, 0xfb, 0x3f, 0x06, 0x98, 0xa7, 0x60, 0x01, 0x38, + 0x83, 0xb2, 0x67, 0x61, 0x06, 0x93, 0xc3, 0xe6, 0xff, 0xff, 0x00, 0x00, + 0xec, 0xd8, 0xff, 0xff, 0xe1, 0xd8, 0xff, 0xff, 0x06, 0x9b, 0x0d, 0x9a, + 0x30, 0x00, 0xfe, 0xf7, 0x03, 0xfb, 0x00, 0x28, 0xb8, 0xd1, 0x6a, 0x46, + 0xe1, 0x88, 0x12, 0x8b, 0x49, 0x04, 0x08, 0xab, 0x49, 0x0c, 0x5a, 0x84, + 0x19, 0x84, 0xff, 0x23, 0x24, 0x30, 0x08, 0xaa, 0x12, 0x18, 0x13, 0x70, + 0x08, 0xaa, 0xe1, 0x3b, 0x9b, 0x18, 0x03, 0x93, 0x07, 0x9b, 0x10, 0xaa, + 0x02, 0x93, 0x01, 0x93, 0x00, 0x93, 0x30, 0x00, 0xfe, 0xf7, 0xf0, 0xfd, + 0x00, 0x28, 0x9d, 0xd1, 0x0d, 0x9b, 0xfb, 0x21, 0x1b, 0x02, 0x05, 0x33, + 0x0a, 0x93, 0x0b, 0x98, 0x08, 0xab, 0xdd, 0x8b, 0x01, 0xf0, 0x56, 0xfb, + 0x2d, 0x02, 0x05, 0x35, 0x00, 0x91, 0x0a, 0x9b, 0x2a, 0x00, 0x07, 0x99, + 0x30, 0x00, 0xfe, 0xf7, 0x65, 0xfb, 0x00, 0x28, 0x00, 0xd0, 0x87, 0xe7, + 0x0d, 0x99, 0x30, 0x00, 0xfe, 0xf7, 0x56, 0xfe, 0x00, 0x28, 0x00, 0xd0, + 0x80, 0xe7, 0x24, 0x21, 0x02, 0x22, 0x08, 0xab, 0x5b, 0x18, 0x1b, 0x78, + 0x30, 0x00, 0x93, 0x43, 0x08, 0xaa, 0x52, 0x18, 0x13, 0x70, 0x04, 0x21, + 0x62, 0x5e, 0x08, 0xab, 0x11, 0xa9, 0xdb, 0x8b, 0x01, 0x91, 0x01, 0x21, + 0x1b, 0x02, 0x00, 0x91, 0x04, 0x33, 0x06, 0x31, 0xfc, 0xf7, 0x79, 0xf9, + 0x00, 0x28, 0x00, 0xd0, 0x66, 0xe7, 0x08, 0xab, 0xdd, 0x8b, 0x09, 0x9b, + 0x00, 0x2b, 0x09, 0xd1, 0x06, 0x98, 0x17, 0x30, 0x08, 0x9b, 0x40, 0x00, + 0x1d, 0x52, 0x0b, 0x9b, 0xa3, 0x60, 0x63, 0x61, 0x1f, 0x00, 0x57, 0xe7, + 0x06, 0x9b, 0x68, 0x2b, 0x02, 0xd8, 0x18, 0x00, 0x04, 0x30, 0xf1, 0xe7, + 0x06, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0x0f, 0xfb, 0x08, 0x1d, + 0xea, 0xe7, 0x70, 0x6a, 0xd2, 0x22, 0x2e, 0x30, 0xff, 0x21, 0x01, 0xf0, + 0x3a, 0xfb, 0x0f, 0xab, 0x04, 0x93, 0x01, 0x23, 0xe2, 0x88, 0x5b, 0x42, + 0x03, 0x93, 0x02, 0x97, 0x01, 0x97, 0x73, 0x6a, 0x00, 0x93, 0x2b, 0x00, + 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0xde, 0xff, 0x05, 0x1e, 0x00, 0xdb, + 0x5a, 0xe7, 0xe7, 0xe6, 0x0f, 0xab, 0x04, 0x93, 0x09, 0x9b, 0xe2, 0x88, + 0x03, 0x97, 0x02, 0x93, 0x01, 0x93, 0xec, 0xe7, 0x2a, 0x00, 0x09, 0x9b, + 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0x18, 0xf9, 0x05, 0x1e, 0x00, 0xda, + 0xd6, 0xe6, 0x00, 0x25, 0x04, 0x22, 0xa1, 0x5e, 0x10, 0xaa, 0x02, 0x92, + 0x08, 0xaa, 0x52, 0x8b, 0xe3, 0x88, 0x01, 0x92, 0x00, 0x95, 0x08, 0x9a, + 0x30, 0x00, 0xfe, 0xf7, 0x15, 0xfe, 0x05, 0x1e, 0x00, 0xda, 0xc5, 0xe6, + 0x00, 0x25, 0x08, 0xaa, 0x02, 0x95, 0x12, 0x8c, 0xe3, 0x88, 0x01, 0x92, + 0x08, 0x9a, 0x30, 0x00, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, + 0x00, 0x92, 0x08, 0x99, 0x2a, 0x00, 0xfe, 0xf7, 0x7f, 0xfe, 0x08, 0xab, + 0x1b, 0x8c, 0x0f, 0xa9, 0xe3, 0x81, 0x6b, 0x46, 0x9b, 0x8c, 0x67, 0x61, + 0x23, 0x82, 0xe2, 0x88, 0xa3, 0x89, 0x04, 0x91, 0x03, 0x97, 0x02, 0x95, + 0x01, 0x95, 0x00, 0x95, 0xb4, 0xe7, 0x0a, 0x4d, 0xa2, 0xe6, 0x0a, 0x4d, + 0xa0, 0xe6, 0x0a, 0x4d, 0x9e, 0xe6, 0x0a, 0x4d, 0x9c, 0xe6, 0x0a, 0x4d, + 0x9a, 0xe6, 0x00, 0x23, 0x0a, 0x93, 0x0c, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0xf1, 0xe5, 0x5d, 0xe6, 0x0a, 0x9b, 0x09, 0x93, 0xc4, 0xe6, 0xc0, 0x46, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x8f, 0xb0, + 0x07, 0x91, 0x08, 0x93, 0x03, 0x68, 0x04, 0x00, 0xfb, 0x21, 0x07, 0x98, + 0x04, 0x93, 0x0b, 0x92, 0x01, 0xf0, 0x00, 0xfa, 0x87, 0xb2, 0x00, 0x20, + 0x04, 0x9b, 0x5b, 0x6a, 0x06, 0x93, 0x07, 0x9b, 0x03, 0x93, 0x6b, 0x4b, + 0x05, 0x93, 0x0b, 0x9a, 0x07, 0x9b, 0x94, 0x46, 0x03, 0x9a, 0x63, 0x44, + 0x0a, 0x93, 0x93, 0x42, 0x3a, 0xd9, 0xe2, 0x6a, 0x00, 0x2a, 0x0c, 0xd0, + 0x13, 0x89, 0xbb, 0x42, 0x09, 0xd8, 0x51, 0x89, 0xb9, 0x42, 0x06, 0xd3, + 0xfb, 0x1a, 0x12, 0x68, 0x5b, 0x00, 0x9d, 0x5a, 0x00, 0x2d, 0x00, 0xd0, + 0x82, 0xe0, 0x68, 0x2f, 0x3d, 0xd9, 0x38, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x01, 0xf0, 0xd8, 0xf9, 0x05, 0x9b, 0x01, 0x30, 0x85, 0xb2, 0xab, 0x42, + 0x06, 0xd1, 0x38, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0x54, 0xfa, + 0x04, 0x31, 0x1c, 0xe0, 0x23, 0x8a, 0xab, 0x42, 0x05, 0xd1, 0x0e, 0x23, + 0xe2, 0x89, 0x0a, 0xa9, 0x5b, 0x18, 0x1a, 0x80, 0x2c, 0xe0, 0x80, 0x23, + 0xe1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x0e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x2a, 0x00, 0x00, 0x23, 0x04, 0x98, 0xfe, 0xf7, 0x5a, 0xfc, + 0x00, 0x28, 0x1d, 0xda, 0x0f, 0xb0, 0xf0, 0xbd, 0x39, 0x1d, 0x68, 0x2f, + 0xdb, 0xd8, 0x06, 0x9b, 0x49, 0x00, 0x5d, 0x5a, 0x4e, 0xe0, 0x45, 0x48, + 0xf4, 0xe7, 0x45, 0x48, 0xf2, 0xe7, 0x45, 0x48, 0xf0, 0xe7, 0x45, 0x48, + 0xee, 0xe7, 0x45, 0x48, 0xec, 0xe7, 0x45, 0x48, 0xea, 0xe7, 0x05, 0x9b, + 0x00, 0x2b, 0x38, 0xd0, 0x0e, 0x23, 0x00, 0x25, 0xa2, 0x89, 0x0a, 0xa9, + 0x5b, 0x18, 0x1a, 0x80, 0x0e, 0x26, 0x04, 0x21, 0x62, 0x5e, 0x04, 0x99, + 0x0a, 0xab, 0x49, 0x6a, 0xf6, 0x18, 0x33, 0x88, 0x05, 0x91, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x04, 0x98, + 0xfb, 0xf7, 0xf3, 0xff, 0x00, 0x28, 0xcd, 0xdb, 0x01, 0x22, 0x06, 0x9b, + 0x1b, 0x79, 0x13, 0x42, 0xd1, 0xd1, 0x5a, 0xb2, 0x00, 0x2a, 0xd0, 0xda, + 0x9a, 0x07, 0xd0, 0xd4, 0x5b, 0x07, 0xd0, 0xd4, 0x06, 0x22, 0xa3, 0x5e, + 0x00, 0x2b, 0xcc, 0xda, 0x06, 0x9b, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, + 0x13, 0x43, 0x05, 0x93, 0xab, 0x42, 0xc6, 0xd1, 0x03, 0x9b, 0x25, 0x82, + 0x63, 0x61, 0x33, 0x88, 0xe3, 0x81, 0x00, 0x2d, 0xb0, 0xd1, 0x3b, 0x00, + 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9d, 0x5a, 0x00, 0x23, 0x05, 0x93, + 0xfb, 0x21, 0x03, 0x98, 0x01, 0xf0, 0xde, 0xf9, 0x0a, 0x9b, 0x03, 0x9a, + 0x09, 0x91, 0x9a, 0x1a, 0x03, 0x99, 0xa3, 0x68, 0x5b, 0x1a, 0x93, 0x42, + 0x00, 0xd9, 0x13, 0x00, 0xfb, 0x26, 0x09, 0x9a, 0xb6, 0x1a, 0x9e, 0x42, + 0x00, 0xd9, 0x1e, 0x00, 0x00, 0x2e, 0xa4, 0xd0, 0x21, 0x1d, 0x3b, 0x00, + 0x2a, 0x00, 0x04, 0x98, 0xfe, 0xf7, 0x4c, 0xf9, 0x00, 0x28, 0x00, 0xda, + 0x88, 0xe7, 0x09, 0x9b, 0x04, 0x21, 0x62, 0x5e, 0x08, 0x99, 0x2d, 0x02, + 0x05, 0x33, 0x01, 0x91, 0xeb, 0x18, 0x00, 0x96, 0x17, 0x21, 0x04, 0x98, + 0xfb, 0xf7, 0x9f, 0xff, 0x00, 0x28, 0x00, 0xda, 0x78, 0xe7, 0x08, 0x9b, + 0x01, 0x37, 0x9b, 0x19, 0x08, 0x93, 0x03, 0x9b, 0xbf, 0xb2, 0x9b, 0x19, + 0x03, 0x93, 0x63, 0x61, 0x2b, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x0f, 0x23, 0x8d, 0xb0, 0x06, 0x91, 0x01, 0x21, 0x07, 0x92, + 0xc2, 0x68, 0x05, 0x00, 0x53, 0x43, 0x5b, 0x08, 0x09, 0xaa, 0x5b, 0x18, + 0x11, 0x80, 0x99, 0xb2, 0x1b, 0x04, 0x3c, 0xd4, 0x51, 0x80, 0x00, 0x23, + 0x53, 0x60, 0x07, 0x9b, 0x93, 0x60, 0x09, 0xac, 0x23, 0x88, 0x68, 0x6a, + 0x9c, 0x46, 0x62, 0x46, 0x63, 0x88, 0x9b, 0x1a, 0x80, 0x22, 0x12, 0x01, + 0x93, 0x42, 0x37, 0xdc, 0x80, 0x22, 0x00, 0x21, 0x52, 0x00, 0x01, 0xf0, + 0xa8, 0xf9, 0x00, 0x21, 0x07, 0x9b, 0x05, 0x91, 0x02, 0x93, 0x3d, 0x4b, + 0x04, 0x91, 0x01, 0x93, 0x03, 0x94, 0x0b, 0x00, 0x00, 0x91, 0x0a, 0x00, + 0x28, 0x00, 0xfe, 0xf7, 0xa9, 0xf9, 0x39, 0x4b, 0x98, 0x42, 0x01, 0xd0, + 0x00, 0x28, 0x12, 0xdb, 0x80, 0x26, 0x00, 0x22, 0x01, 0x23, 0x6f, 0x6a, + 0x76, 0x00, 0xbd, 0x5c, 0xff, 0x2d, 0x12, 0xd0, 0x00, 0x21, 0x28, 0x00, + 0x08, 0x41, 0x18, 0x40, 0x0a, 0xd1, 0x23, 0x88, 0xd2, 0x00, 0x59, 0x18, + 0x06, 0x9b, 0x8a, 0x18, 0x1a, 0x80, 0x0d, 0xb0, 0xf0, 0xbd, 0x2d, 0x4b, + 0x53, 0x80, 0xc0, 0xe7, 0x01, 0x31, 0x08, 0x29, 0xed, 0xd1, 0x01, 0x32, + 0xb2, 0x42, 0xe6, 0xd1, 0x29, 0x48, 0xf2, 0xe7, 0x62, 0x68, 0x00, 0x2a, + 0x1d, 0xd1, 0x09, 0xac, 0x22, 0x88, 0x63, 0x88, 0x00, 0x26, 0x9b, 0x1a, + 0x80, 0x22, 0x1b, 0x0a, 0x52, 0x00, 0x00, 0x21, 0x63, 0x60, 0x01, 0xf0, + 0x66, 0xf9, 0x22, 0x4b, 0x05, 0x96, 0x01, 0x93, 0x04, 0x96, 0x33, 0x00, + 0x03, 0x96, 0x02, 0x94, 0x00, 0x96, 0x32, 0x00, 0x31, 0x00, 0x28, 0x00, + 0xfe, 0xf7, 0x68, 0xf9, 0x18, 0x4b, 0x98, 0x42, 0x26, 0xd1, 0xa6, 0x60, + 0x9b, 0xe7, 0x00, 0x27, 0xff, 0x23, 0x39, 0x00, 0x46, 0x5c, 0x9e, 0x42, + 0x02, 0xd2, 0x33, 0x1e, 0x06, 0xd0, 0x0f, 0x00, 0x80, 0x26, 0x01, 0x31, + 0x76, 0x00, 0xb1, 0x42, 0xf4, 0xd1, 0x39, 0x00, 0x9a, 0x42, 0xcb, 0xd0, + 0x92, 0xb2, 0x51, 0x43, 0x61, 0x44, 0x89, 0xb2, 0x00, 0x2b, 0x03, 0xd1, + 0x06, 0x9a, 0x18, 0x00, 0x11, 0x80, 0xb6, 0xe7, 0x80, 0x23, 0x52, 0x18, + 0x92, 0xb2, 0x62, 0x80, 0x21, 0x80, 0x52, 0x1a, 0x1b, 0x01, 0x9a, 0x42, + 0xbd, 0xdc, 0x76, 0xe7, 0x00, 0x28, 0xaa, 0xdb, 0xa6, 0x60, 0x00, 0xd1, + 0x71, 0xe7, 0xa6, 0xe7, 0x31, 0x49, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xff, 0x7f, 0x00, 0x00, 0xef, 0xd8, 0xff, 0xff, 0x6d, 0x4b, 0x00, 0x00, + 0xf0, 0xb5, 0x85, 0xb0, 0x05, 0x00, 0x03, 0x91, 0x14, 0x00, 0x10, 0x1e, + 0x01, 0xd0, 0xfe, 0xf7, 0x57, 0xf8, 0xeb, 0x6a, 0xae, 0x6a, 0x02, 0x93, + 0x00, 0x2c, 0x07, 0xd0, 0x30, 0x23, 0x02, 0x99, 0x32, 0x1d, 0x4b, 0x43, + 0xf3, 0x18, 0x04, 0x33, 0x93, 0x42, 0x0e, 0xd1, 0x2a, 0x4a, 0x01, 0x23, + 0x01, 0x92, 0x00, 0x22, 0x31, 0x1d, 0x5b, 0x42, 0x00, 0x92, 0x02, 0x9f, + 0x00, 0x9a, 0xba, 0x42, 0x0e, 0xd1, 0x5a, 0x1c, 0x21, 0xd1, 0x25, 0x48, + 0x3b, 0xe0, 0x00, 0x27, 0xd1, 0x5f, 0x00, 0x29, 0x04, 0xd1, 0x91, 0x8c, + 0x01, 0x29, 0x01, 0xd9, 0x01, 0x39, 0x91, 0x84, 0x30, 0x32, 0xe3, 0xe7, + 0x00, 0x22, 0x8f, 0x5e, 0x00, 0x2f, 0x0a, 0xd1, 0x00, 0x2c, 0x02, 0xd0, + 0x0f, 0x6a, 0x87, 0x42, 0x0a, 0xd0, 0x8f, 0x8c, 0x01, 0x9a, 0x97, 0x42, + 0x01, 0xd2, 0x00, 0x9b, 0x01, 0x97, 0x00, 0x9a, 0x30, 0x31, 0x01, 0x32, + 0x00, 0x92, 0xd8, 0xe7, 0x00, 0x9b, 0x30, 0x22, 0x5a, 0x43, 0xb6, 0x18, + 0x00, 0x2c, 0x11, 0xd0, 0x72, 0x6a, 0x82, 0x42, 0x19, 0xd1, 0x31, 0x8d, + 0x00, 0x29, 0x16, 0xd0, 0xb2, 0x89, 0x10, 0x09, 0x28, 0x83, 0x0f, 0x20, + 0x02, 0x40, 0x01, 0x3a, 0xea, 0x61, 0x0c, 0x4a, 0x91, 0x42, 0x08, 0xd8, + 0x04, 0x31, 0x31, 0x85, 0x00, 0x20, 0x01, 0x33, 0xb3, 0x80, 0x03, 0x9b, + 0x1e, 0x60, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x22, 0x52, 0x42, 0x32, 0x85, + 0xf4, 0xe7, 0x04, 0x22, 0x70, 0x62, 0x32, 0x85, 0xf0, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xe9, 0xd8, 0xff, 0xff, 0xfa, 0xff, 0x00, 0x00, + 0x00, 0x29, 0x10, 0xdd, 0x2c, 0x22, 0x83, 0x5e, 0x8b, 0x42, 0x0c, 0xdb, + 0x30, 0x23, 0x4b, 0x43, 0x81, 0x6a, 0x30, 0x3b, 0xc9, 0x18, 0x04, 0x22, + 0x8b, 0x5e, 0x00, 0x2b, 0x05, 0xd0, 0x00, 0x20, 0x88, 0x80, 0xc8, 0x62, + 0x70, 0x47, 0x02, 0x48, 0xfc, 0xe7, 0x02, 0x48, 0xfa, 0xe7, 0xc0, 0x46, + 0xe6, 0xd8, 0xff, 0xff, 0xe8, 0xd8, 0xff, 0xff, 0x10, 0xb5, 0x00, 0x29, + 0x11, 0xdd, 0x2c, 0x24, 0x03, 0x5f, 0x8b, 0x42, 0x0d, 0xdb, 0x30, 0x23, + 0x59, 0x43, 0x83, 0x6a, 0x30, 0x39, 0x59, 0x18, 0x11, 0x60, 0x04, 0x23, + 0xc8, 0x5e, 0x43, 0x42, 0x58, 0x41, 0x03, 0x4b, 0x40, 0x42, 0x18, 0x40, + 0x10, 0xbd, 0x02, 0x48, 0xfc, 0xe7, 0xc0, 0x46, 0xe8, 0xd8, 0xff, 0xff, + 0xe6, 0xd8, 0xff, 0xff, 0x03, 0x7d, 0x00, 0x2b, 0x04, 0xd1, 0x43, 0x75, + 0x83, 0x75, 0x83, 0x61, 0x01, 0x33, 0x03, 0x75, 0x70, 0x47, 0x7f, 0xb5, + 0xc3, 0x68, 0x02, 0xad, 0x04, 0x00, 0x0e, 0x00, 0x02, 0x91, 0x6a, 0x60, + 0x8b, 0x42, 0x03, 0xd1, 0x02, 0x8a, 0xab, 0x88, 0x9a, 0x42, 0x18, 0xd0, + 0x20, 0x00, 0x06, 0x22, 0x29, 0x00, 0x0c, 0x30, 0x01, 0xf0, 0x50, 0xf8, + 0x20, 0x68, 0x00, 0xf0, 0x8e, 0xf9, 0x6b, 0x79, 0x22, 0x7a, 0xe1, 0x79, + 0x00, 0x93, 0x20, 0x68, 0x00, 0x23, 0x00, 0xf0, 0x27, 0xfa, 0x20, 0x68, + 0x29, 0x79, 0x32, 0x00, 0x00, 0xf0, 0x52, 0xf9, 0x20, 0x68, 0x00, 0xf0, + 0x74, 0xf9, 0x7f, 0xbd, 0x70, 0xb5, 0x18, 0x26, 0x04, 0x00, 0xff, 0xf7, + 0xcb, 0xff, 0x33, 0x00, 0x08, 0x21, 0x20, 0x79, 0x0d, 0x4d, 0x43, 0x43, + 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0xc4, 0xfe, 0x33, 0x00, 0x08, 0x21, + 0xa0, 0x79, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0xbc, 0xfe, + 0x08, 0x21, 0x60, 0x79, 0x46, 0x43, 0xad, 0x19, 0x69, 0x56, 0x00, 0xf0, + 0xb5, 0xfe, 0x04, 0x4b, 0x20, 0x00, 0x06, 0xcb, 0xff, 0xf7, 0xb7, 0xff, + 0x70, 0xbd, 0xc0, 0x46, 0x20, 0x82, 0x00, 0x00, 0x34, 0x0c, 0x00, 0x20, + 0x07, 0xb5, 0x43, 0x7d, 0x00, 0x91, 0x01, 0x92, 0x00, 0x2b, 0x07, 0xd0, + 0x9a, 0x07, 0x0a, 0xd5, 0xef, 0xf3, 0x10, 0x83, 0x5a, 0x42, 0x53, 0x41, + 0x83, 0x75, 0x72, 0xb6, 0x00, 0x99, 0x01, 0x9a, 0xff, 0xf7, 0x9f, 0xff, + 0x07, 0xbd, 0xdb, 0x07, 0xf8, 0xd5, 0x83, 0x69, 0x01, 0x4a, 0x9b, 0xb2, + 0x93, 0x60, 0xf3, 0xe7, 0x00, 0x18, 0x00, 0x40, 0x10, 0xb5, 0x00, 0x68, + 0x00, 0xf0, 0x3e, 0xf9, 0x10, 0xbd, 0x00, 0x00, 0x10, 0x4a, 0x11, 0x4b, + 0x11, 0x49, 0x13, 0x60, 0x00, 0x23, 0x53, 0x71, 0x13, 0x71, 0x10, 0x4a, + 0x10, 0x48, 0x11, 0x60, 0x10, 0x49, 0xd3, 0x60, 0x91, 0x80, 0x09, 0x21, + 0x91, 0x71, 0x06, 0x39, 0x53, 0x74, 0x13, 0x74, 0x13, 0x75, 0xd3, 0x71, + 0x11, 0x72, 0x0c, 0x4a, 0x10, 0x60, 0x0c, 0x48, 0xd3, 0x60, 0x90, 0x80, + 0x1b, 0x20, 0x53, 0x74, 0x13, 0x74, 0x13, 0x75, 0x90, 0x71, 0xd3, 0x71, + 0x11, 0x72, 0x70, 0x47, 0x34, 0x0c, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, + 0x7c, 0x0e, 0x00, 0x20, 0xfc, 0x0b, 0x00, 0x20, 0x80, 0x0e, 0x00, 0x20, + 0x0a, 0x08, 0x00, 0x00, 0x18, 0x0c, 0x00, 0x20, 0x1d, 0x1a, 0x00, 0x00, + 0x10, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x05, 0xfb, 0x10, 0xbd, 0xc0, 0x46, + 0x3c, 0x0c, 0x00, 0x20, 0x13, 0xb5, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, + 0x3b, 0xf8, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, 0x37, 0xf8, 0x12, 0x49, + 0x12, 0x48, 0x00, 0xf0, 0x33, 0xf8, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, + 0x2f, 0xf8, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, 0x2b, 0xf8, 0x12, 0x4c, + 0x12, 0x49, 0x20, 0x00, 0x00, 0xf0, 0x26, 0xf8, 0x01, 0x23, 0x01, 0x93, + 0x02, 0x33, 0x00, 0x93, 0x0d, 0x22, 0x0b, 0x33, 0x21, 0x00, 0x0e, 0x48, + 0x00, 0xf0, 0x72, 0xfa, 0x13, 0xbd, 0xc0, 0x46, 0x00, 0x08, 0x00, 0x42, + 0x78, 0x0e, 0x00, 0x20, 0x00, 0x0c, 0x00, 0x42, 0x7c, 0x0e, 0x00, 0x20, + 0x00, 0x10, 0x00, 0x42, 0x80, 0x0e, 0x00, 0x20, 0x00, 0x14, 0x00, 0x42, + 0x84, 0x0e, 0x00, 0x20, 0x00, 0x18, 0x00, 0x42, 0x88, 0x0e, 0x00, 0x20, + 0x8c, 0x0e, 0x00, 0x20, 0x00, 0x1c, 0x00, 0x42, 0x3c, 0x0c, 0x00, 0x20, + 0x01, 0x60, 0x70, 0x47, 0x94, 0x46, 0xf0, 0xb5, 0x9e, 0x1e, 0x72, 0x1e, + 0x96, 0x41, 0x62, 0x46, 0x05, 0x68, 0x92, 0x07, 0x2f, 0x68, 0x36, 0x06, + 0x3a, 0x43, 0x32, 0x43, 0x2a, 0x60, 0x07, 0x25, 0x05, 0xac, 0x24, 0x78, + 0x00, 0x68, 0xa4, 0x01, 0x29, 0x40, 0x21, 0x43, 0x42, 0x68, 0x00, 0x24, + 0x02, 0x2b, 0x00, 0xd0, 0x5c, 0x03, 0x11, 0x43, 0x21, 0x43, 0x41, 0x60, + 0xf0, 0xbd, 0x30, 0xb5, 0xc0, 0x25, 0x03, 0x68, 0xad, 0x03, 0x1c, 0x68, + 0x12, 0x05, 0x2a, 0x40, 0x22, 0x43, 0xc0, 0x24, 0x09, 0x04, 0xa4, 0x02, + 0x21, 0x40, 0x11, 0x43, 0x19, 0x60, 0x03, 0x68, 0x5a, 0x68, 0x14, 0x43, + 0x5c, 0x60, 0x30, 0xbd, 0x01, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, + 0x13, 0x60, 0x03, 0x68, 0x1a, 0x68, 0xd2, 0x07, 0xfc, 0xd4, 0xda, 0x69, + 0xd2, 0x07, 0xf9, 0xd4, 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, 0x11, 0x68, + 0x0b, 0x43, 0x13, 0x60, 0x02, 0x68, 0xd3, 0x69, 0x9b, 0x07, 0xfc, 0xd4, + 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, 0x02, 0xd4, 0x1a, 0x7e, + 0x92, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0x00, 0x22, 0x03, 0x68, 0x5a, 0x83, + 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x40, 0x07, 0xc0, 0x0f, 0x70, 0x47, + 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x09, 0x70, 0x47, 0x80, 0x23, 0x02, 0x68, + 0x5b, 0x42, 0x11, 0x7e, 0x0b, 0x43, 0x13, 0x76, 0x70, 0x47, 0x03, 0x68, + 0x58, 0x8b, 0x80, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, + 0x51, 0x8b, 0x0b, 0x43, 0x53, 0x83, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, + 0xc0, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x8d, 0xc0, 0xb2, + 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, 0xfc, 0xd5, 0x89, 0xb2, + 0x01, 0x20, 0x19, 0x85, 0x70, 0x47, 0x01, 0x22, 0x03, 0x68, 0x9a, 0x75, + 0x70, 0x47, 0x01, 0x22, 0x03, 0x68, 0x1a, 0x75, 0x70, 0x47, 0x00, 0x00, + 0x70, 0xb5, 0x01, 0x26, 0x04, 0x68, 0x4b, 0x08, 0x33, 0x40, 0x31, 0x40, + 0x25, 0x68, 0x09, 0x07, 0x5b, 0x07, 0x0b, 0x43, 0x2b, 0x43, 0x23, 0x60, + 0x04, 0x68, 0x51, 0x00, 0x03, 0x48, 0x00, 0xf0, 0x2d, 0xfe, 0x01, 0x38, + 0xc0, 0xb2, 0x20, 0x73, 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x6c, 0xdc, 0x02, + 0x01, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, 0x03, 0x68, + 0x1a, 0x68, 0xd2, 0x07, 0xfc, 0xd4, 0xda, 0x69, 0xd2, 0x07, 0xf9, 0xd4, + 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, + 0x02, 0x68, 0xd3, 0x69, 0x9b, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, + 0xda, 0x69, 0x92, 0x07, 0xfc, 0xd4, 0x02, 0x21, 0x1a, 0x68, 0x8a, 0x43, + 0x1a, 0x60, 0x70, 0x47, 0x02, 0x68, 0x93, 0x6a, 0x5b, 0x0a, 0x5b, 0x02, + 0x19, 0x43, 0x91, 0x62, 0x03, 0x68, 0x1a, 0x7e, 0x52, 0x07, 0xfc, 0xd5, + 0x98, 0x6a, 0xc0, 0xb2, 0x70, 0x47, 0x00, 0x00, 0x03, 0x68, 0x21, 0x4a, + 0x30, 0xb5, 0x93, 0x42, 0x2f, 0xd0, 0x20, 0x4a, 0x93, 0x42, 0x2f, 0xd0, + 0x1f, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x2f, 0xd0, + 0x1e, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1e, 0x4a, 0x93, 0x42, 0x1f, 0xd1, + 0x0e, 0x23, 0x19, 0x22, 0x01, 0x21, 0x03, 0x25, 0x99, 0x40, 0x1b, 0x48, + 0xc0, 0x24, 0x01, 0x60, 0x99, 0x08, 0x2b, 0x40, 0xab, 0x40, 0xfc, 0x35, + 0x9d, 0x40, 0x89, 0x00, 0x09, 0x18, 0xa4, 0x00, 0x08, 0x59, 0xa8, 0x43, + 0xc0, 0x25, 0x9d, 0x40, 0x2b, 0x00, 0x03, 0x43, 0x0b, 0x51, 0x80, 0x23, + 0xdb, 0x01, 0x1a, 0x43, 0x11, 0x4b, 0x5a, 0x80, 0x5a, 0x78, 0x52, 0xb2, + 0x00, 0x2a, 0xfb, 0xdb, 0x30, 0xbd, 0x09, 0x23, 0x14, 0x22, 0xdd, 0xe7, + 0x0a, 0x23, 0x15, 0x22, 0xda, 0xe7, 0x0b, 0x23, 0x16, 0x22, 0xd7, 0xe7, + 0x0c, 0x23, 0x17, 0x22, 0xd4, 0xe7, 0x0d, 0x23, 0x18, 0x22, 0xd1, 0xe7, + 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, 0x00, 0x10, 0x00, 0x42, + 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, 0x00, 0x1c, 0x00, 0x42, + 0x00, 0xe1, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x40, 0xf8, 0xb5, 0x04, 0x00, + 0x0f, 0x00, 0x16, 0x00, 0x1d, 0x00, 0xff, 0xf7, 0xa5, 0xff, 0x20, 0x00, + 0xff, 0xf7, 0x04, 0xff, 0x1c, 0x21, 0xbb, 0x00, 0x0b, 0x40, 0x71, 0x07, + 0x22, 0x68, 0x09, 0x0c, 0x0b, 0x43, 0x13, 0x60, 0x84, 0x23, 0x22, 0x68, + 0x93, 0x75, 0x01, 0x2f, 0x1a, 0xd1, 0x10, 0x21, 0x01, 0x2e, 0x00, 0xd0, + 0x08, 0x39, 0x0c, 0x4b, 0x69, 0x43, 0x18, 0x68, 0xc0, 0x00, 0x00, 0xf0, + 0x83, 0xfd, 0x07, 0x22, 0x21, 0x68, 0x02, 0x40, 0x8b, 0x89, 0x52, 0x03, + 0xdb, 0x04, 0xdb, 0x0c, 0x13, 0x43, 0x8b, 0x81, 0x22, 0x68, 0x03, 0x04, + 0x90, 0x89, 0xdb, 0x0c, 0x40, 0x0b, 0x40, 0x03, 0x18, 0x43, 0x90, 0x81, + 0xf8, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, 0xf7, 0xb5, 0x06, 0x00, + 0x01, 0x93, 0x08, 0xab, 0x1f, 0x78, 0x0d, 0x00, 0x14, 0x00, 0xff, 0xf7, + 0x3f, 0xff, 0x30, 0x00, 0xff, 0xf7, 0x6a, 0xff, 0xc0, 0x22, 0x24, 0x05, + 0x92, 0x03, 0x14, 0x40, 0xba, 0x07, 0x0c, 0x27, 0x17, 0x43, 0x3c, 0x43, + 0xc0, 0x27, 0x07, 0x22, 0xbf, 0x02, 0x2d, 0x04, 0x33, 0x68, 0x3d, 0x40, + 0x25, 0x43, 0x1d, 0x60, 0x01, 0x9b, 0x31, 0x68, 0x13, 0x40, 0x1a, 0x00, + 0x80, 0x23, 0x9b, 0x02, 0x13, 0x43, 0x4b, 0x60, 0xf7, 0xbd, 0x01, 0x20, + 0x70, 0x47, 0x00, 0x00, 0x10, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, + 0x98, 0x47, 0x10, 0xbd, 0x13, 0x04, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, + 0xd9, 0x69, 0x9a, 0x69, 0x91, 0x42, 0x03, 0xd0, 0xdb, 0x69, 0xc0, 0x18, + 0x00, 0x7d, 0x70, 0x47, 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, 0x10, 0xb5, + 0x04, 0x00, 0x00, 0x69, 0xff, 0xf7, 0x96, 0xfe, 0x22, 0x00, 0x00, 0x23, + 0xfc, 0x32, 0x93, 0x61, 0xd3, 0x61, 0x86, 0x22, 0x92, 0x00, 0xa4, 0x18, + 0x63, 0x60, 0xa3, 0x60, 0x10, 0xbd, 0xf0, 0x20, 0x01, 0x40, 0x30, 0x39, + 0x48, 0x42, 0x48, 0x41, 0x70, 0x47, 0xf0, 0x23, 0x1b, 0x01, 0x19, 0x40, + 0x80, 0x23, 0x06, 0x20, 0x9b, 0x00, 0x99, 0x42, 0x0a, 0xd0, 0x01, 0x33, + 0xff, 0x33, 0x01, 0x30, 0x99, 0x42, 0x05, 0xd0, 0x80, 0x23, 0x02, 0x38, + 0x5b, 0x00, 0x99, 0x42, 0x00, 0xd0, 0x00, 0x20, 0x70, 0x47, 0x0f, 0x20, + 0x01, 0x40, 0x00, 0x20, 0x01, 0x29, 0x03, 0xd0, 0x02, 0x39, 0x48, 0x1e, + 0x81, 0x41, 0x48, 0x1c, 0x70, 0x47, 0x00, 0x00, 0x89, 0x23, 0xf0, 0xb5, + 0x18, 0x26, 0x85, 0xb0, 0x02, 0x91, 0x9b, 0x00, 0x04, 0x00, 0xc0, 0x5c, + 0x33, 0x00, 0x08, 0x21, 0x43, 0x43, 0x32, 0x4d, 0x17, 0x00, 0xeb, 0x18, + 0x59, 0x56, 0x00, 0xf0, 0x31, 0xfc, 0x30, 0x4b, 0x08, 0x21, 0xe0, 0x5c, + 0x33, 0x00, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x28, 0xfc, + 0x2c, 0x4b, 0xe2, 0x5c, 0x03, 0x93, 0x02, 0x2a, 0x09, 0xd1, 0x11, 0x33, + 0xe0, 0x5c, 0xff, 0x28, 0x05, 0xd0, 0x08, 0x21, 0x46, 0x43, 0xae, 0x19, + 0x71, 0x56, 0x00, 0xf0, 0x19, 0xfc, 0x8a, 0x26, 0xb6, 0x00, 0xa0, 0x5d, + 0xff, 0x28, 0x19, 0xd0, 0x01, 0x21, 0x00, 0xf0, 0x99, 0xfb, 0x18, 0x22, + 0xa3, 0x5d, 0x21, 0x49, 0x5a, 0x43, 0xab, 0x56, 0xad, 0x18, 0xdb, 0x01, + 0x58, 0x18, 0x8b, 0x21, 0x89, 0x00, 0x60, 0x50, 0x1d, 0x49, 0x01, 0x22, + 0x5b, 0x18, 0x8c, 0x21, 0x89, 0x00, 0x63, 0x50, 0x69, 0x68, 0x8a, 0x40, + 0x8d, 0x21, 0x89, 0x00, 0x62, 0x50, 0x1a, 0x60, 0x01, 0x22, 0x02, 0x9b, + 0x11, 0x00, 0x20, 0x69, 0xff, 0xf7, 0x0a, 0xff, 0x39, 0x00, 0x20, 0x00, + 0xff, 0xf7, 0x8f, 0xff, 0x39, 0x00, 0x05, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0x9e, 0xff, 0x39, 0x00, 0x06, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x7f, 0xff, + 0x33, 0x00, 0x00, 0x90, 0x29, 0x00, 0x20, 0x69, 0x01, 0x22, 0xff, 0xf7, + 0xd3, 0xfd, 0x0b, 0x4b, 0x20, 0x69, 0xe2, 0x5c, 0x03, 0x9b, 0xe1, 0x5c, + 0xff, 0xf7, 0xe9, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x06, 0xfe, 0x05, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x20, 0x82, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, + 0x27, 0x02, 0x00, 0x00, 0x18, 0x44, 0x00, 0x41, 0x14, 0x44, 0x00, 0x41, + 0x26, 0x02, 0x00, 0x00, 0x80, 0x22, 0x10, 0xb5, 0x04, 0x00, 0x52, 0x00, + 0x00, 0x21, 0x00, 0xf0, 0x32, 0xfd, 0x23, 0x00, 0x00, 0x22, 0xfc, 0x33, + 0x5a, 0x60, 0x20, 0x00, 0x9a, 0x60, 0x10, 0xbd, 0xf7, 0xb5, 0x1d, 0x00, + 0x08, 0xab, 0x1b, 0x78, 0x04, 0x00, 0x00, 0x93, 0x09, 0xab, 0x1b, 0x78, + 0x16, 0x00, 0x01, 0x93, 0x00, 0x23, 0x43, 0x60, 0xfa, 0x23, 0x9b, 0x00, + 0x83, 0x60, 0x11, 0x4b, 0x0f, 0x00, 0x08, 0x33, 0x03, 0x60, 0x14, 0x30, + 0xff, 0xf7, 0xdc, 0xff, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, + 0xd7, 0xff, 0x89, 0x23, 0x6a, 0x46, 0x9b, 0x00, 0x27, 0x61, 0xe6, 0x54, + 0x09, 0x4b, 0x12, 0x78, 0xe5, 0x54, 0x09, 0x4b, 0x20, 0x00, 0xe2, 0x54, + 0x6a, 0x46, 0x08, 0x4b, 0x12, 0x79, 0xe2, 0x54, 0x8a, 0x22, 0x29, 0x3b, + 0xff, 0x3b, 0x92, 0x00, 0xa3, 0x54, 0x10, 0x32, 0xa3, 0x54, 0xfe, 0xbd, + 0x80, 0x85, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, 0x26, 0x02, 0x00, 0x00, + 0x27, 0x02, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, 0x58, 0x68, 0x9b, 0x68, + 0xc0, 0x1a, 0x01, 0xd5, 0x01, 0x30, 0xff, 0x30, 0x70, 0x47, 0x10, 0xb5, + 0x04, 0x00, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0xf0, 0xff, + 0x00, 0x28, 0xf8, 0xd1, 0x20, 0x69, 0xff, 0xf7, 0xa4, 0xfd, 0x10, 0xbd, + 0x10, 0xb5, 0x14, 0x30, 0xff, 0xf7, 0xe6, 0xff, 0x10, 0xbd, 0x03, 0x00, + 0xfc, 0x33, 0x59, 0x68, 0x9a, 0x68, 0x91, 0x42, 0x04, 0xdb, 0x5a, 0x68, + 0x98, 0x68, 0x80, 0x1a, 0xff, 0x30, 0x70, 0x47, 0x98, 0x68, 0x5b, 0x68, + 0xc0, 0x1a, 0x01, 0x38, 0xf9, 0xe7, 0x10, 0xb5, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0xeb, 0xff, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x69, + 0xff, 0xf7, 0x9f, 0xfd, 0x00, 0x28, 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, + 0xaa, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x9c, 0xfd, 0x20, 0x69, 0xff, 0xf7, + 0x84, 0xfd, 0x00, 0x28, 0x20, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x9f, 0xfd, + 0x22, 0x00, 0xfc, 0x32, 0x93, 0x69, 0xd1, 0x69, 0x01, 0x33, 0xdb, 0xb2, + 0x8b, 0x42, 0x03, 0xd0, 0x91, 0x69, 0x61, 0x18, 0x08, 0x75, 0x93, 0x61, + 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, 0x20, 0x00, + 0x14, 0x30, 0xff, 0xf7, 0xc0, 0xff, 0x09, 0x28, 0x06, 0xdc, 0x8b, 0x23, + 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, 0x1a, 0x60, + 0x20, 0x69, 0xff, 0xf7, 0x79, 0xfd, 0x00, 0x28, 0x1a, 0xd0, 0x20, 0x00, + 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0x92, 0xff, 0x00, 0x28, 0x22, 0xd0, + 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x99, 0x68, 0x5a, 0x68, 0x91, 0x42, + 0x18, 0xd0, 0x8e, 0x21, 0x9a, 0x68, 0x49, 0x00, 0xa2, 0x18, 0x51, 0x5c, + 0x9a, 0x68, 0x01, 0x32, 0xd2, 0xb2, 0x9a, 0x60, 0xc9, 0xb2, 0x20, 0x69, + 0xff, 0xf7, 0x65, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x43, 0xfd, 0x00, 0x28, + 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x42, 0xfd, 0x20, 0x69, 0xff, 0xf7, + 0x32, 0xfd, 0x10, 0xbd, 0x01, 0x21, 0x49, 0x42, 0xec, 0xe7, 0x20, 0x69, + 0xff, 0xf7, 0x5f, 0xfd, 0xec, 0xe7, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x00, + 0x00, 0x69, 0x0d, 0x00, 0xff, 0xf7, 0x42, 0xfd, 0x00, 0x28, 0x3e, 0xd1, + 0xff, 0x26, 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x5a, 0x68, 0x99, 0x68, + 0x01, 0x32, 0x32, 0x40, 0x8a, 0x42, 0x23, 0xd1, 0xef, 0xf3, 0x10, 0x83, + 0xdb, 0x07, 0x10, 0xd4, 0x1e, 0x4b, 0x5b, 0x68, 0xdb, 0x05, 0xdb, 0x0d, + 0xed, 0xd0, 0x10, 0x3b, 0x5b, 0xb2, 0x00, 0x2b, 0x10, 0xda, 0x0f, 0x22, + 0x13, 0x40, 0x08, 0x3b, 0x9b, 0x08, 0x19, 0x4a, 0x9b, 0x00, 0x9b, 0x18, + 0x1b, 0x68, 0x20, 0x69, 0xff, 0xf7, 0x1e, 0xfd, 0x00, 0x28, 0xdc, 0xd0, + 0x20, 0x00, 0xff, 0xf7, 0x6a, 0xff, 0xd8, 0xe7, 0x9b, 0x08, 0xc0, 0x33, + 0x12, 0x4a, 0x9b, 0x00, 0x9b, 0x58, 0xf0, 0xe7, 0x5a, 0x68, 0x01, 0x32, + 0x16, 0x40, 0x9a, 0x68, 0x96, 0x42, 0x05, 0xd0, 0x8e, 0x21, 0x5a, 0x68, + 0x49, 0x00, 0xa2, 0x18, 0x55, 0x54, 0x5e, 0x60, 0x20, 0x69, 0xff, 0xf7, + 0x14, 0xfd, 0x01, 0x20, 0x70, 0xbd, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0x1c, 0xff, 0x00, 0x28, 0xb9, 0xd1, 0x29, 0x00, 0x20, 0x69, + 0xff, 0xf7, 0xff, 0xfc, 0xf1, 0xe7, 0xc0, 0x46, 0x00, 0xed, 0x00, 0xe0, + 0x1c, 0xed, 0x00, 0xe0, 0x00, 0xe1, 0x00, 0xe0, 0x03, 0x00, 0x70, 0xb5, + 0xfc, 0x33, 0xd9, 0x69, 0x9a, 0x69, 0x04, 0x00, 0x91, 0x42, 0x1a, 0xd0, + 0xda, 0x69, 0x82, 0x18, 0x15, 0x7d, 0xda, 0x69, 0x01, 0x32, 0xd2, 0xb2, + 0xda, 0x61, 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, + 0x20, 0x00, 0x14, 0x30, 0xff, 0xf7, 0x11, 0xff, 0x0a, 0x28, 0x06, 0xdd, + 0x8c, 0x23, 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, + 0x1a, 0x60, 0x28, 0x00, 0x70, 0xbd, 0x01, 0x25, 0x6d, 0x42, 0xe8, 0xe7, + 0xfe, 0xe7, 0x00, 0x00, 0x03, 0x4b, 0x10, 0xb5, 0x1b, 0x68, 0x00, 0x2b, + 0x00, 0xd0, 0x98, 0x47, 0x10, 0xbd, 0xc0, 0x46, 0x90, 0x0e, 0x00, 0x20, + 0x70, 0xb5, 0x0f, 0x49, 0x0f, 0x4c, 0xa1, 0x42, 0x04, 0xd1, 0x00, 0xf0, + 0x81, 0xf8, 0xfa, 0xf7, 0x27, 0xfe, 0xfe, 0xe7, 0x0c, 0x4d, 0x00, 0x23, + 0x8d, 0x42, 0xf6, 0xd0, 0xca, 0x18, 0xe8, 0x18, 0xa2, 0x42, 0x05, 0xd3, + 0x09, 0x4b, 0x82, 0x42, 0xef, 0xd0, 0x09, 0x49, 0x00, 0x22, 0x04, 0xe0, + 0x00, 0x68, 0x04, 0x33, 0x10, 0x60, 0xf1, 0xe7, 0x04, 0xc3, 0x8b, 0x42, + 0xfc, 0xd3, 0xe4, 0xe7, 0x00, 0x00, 0x00, 0x20, 0x30, 0x00, 0x00, 0x20, + 0xb8, 0x85, 0x00, 0x00, 0x30, 0x00, 0x00, 0x20, 0x98, 0x0e, 0x00, 0x20, + 0x10, 0xb5, 0x00, 0xf0, 0x58, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x00, 0xf0, + 0x49, 0xf8, 0x10, 0xbd, 0xf7, 0xb5, 0x13, 0x48, 0x01, 0x22, 0x84, 0x46, + 0x12, 0x49, 0x13, 0x4c, 0x8e, 0x68, 0x63, 0x68, 0x05, 0x68, 0x9b, 0x0e, + 0x13, 0x40, 0x01, 0x92, 0x88, 0x68, 0x62, 0x68, 0x01, 0x9f, 0x92, 0x0e, + 0x3a, 0x40, 0x67, 0x46, 0x3f, 0x68, 0x93, 0x42, 0x0e, 0xd1, 0xbd, 0x42, + 0x0c, 0xd1, 0x86, 0x42, 0x0a, 0xd3, 0x5b, 0x19, 0xfa, 0x25, 0x48, 0x68, + 0xad, 0x00, 0x86, 0x1b, 0x07, 0x48, 0x6b, 0x43, 0x70, 0x43, 0x00, 0x0d, + 0xc0, 0x18, 0xfe, 0xbd, 0x3d, 0x00, 0x13, 0x00, 0x06, 0x00, 0xe3, 0xe7, + 0x94, 0x0e, 0x00, 0x20, 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, + 0x55, 0x55, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x1e, 0x10, 0xd0, 0xff, 0xf7, + 0xcb, 0xff, 0x05, 0x00, 0x00, 0xf0, 0x1a, 0xf8, 0xff, 0xf7, 0xc6, 0xff, + 0x05, 0x4b, 0x40, 0x1b, 0x98, 0x42, 0xf7, 0xd9, 0xfa, 0x23, 0x01, 0x3c, + 0x9b, 0x00, 0xed, 0x18, 0x00, 0x2c, 0xf3, 0xd1, 0x70, 0xbd, 0xc0, 0x46, + 0xe7, 0x03, 0x00, 0x00, 0x10, 0xb5, 0x03, 0x4a, 0x13, 0x68, 0x01, 0x33, + 0x13, 0x60, 0x00, 0xf0, 0x4d, 0xfa, 0x10, 0xbd, 0x94, 0x0e, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, 0x1e, 0x22, 0x70, 0xb5, + 0x46, 0x48, 0x47, 0x49, 0x43, 0x68, 0x93, 0x43, 0x1c, 0x3a, 0x13, 0x43, + 0x43, 0x60, 0x08, 0x23, 0x8c, 0x69, 0x23, 0x43, 0x8b, 0x61, 0x43, 0x4c, + 0x43, 0x4b, 0x9c, 0x82, 0x9c, 0x8a, 0x14, 0x43, 0x9c, 0x82, 0xdc, 0x68, + 0x14, 0x42, 0xfc, 0xd0, 0x01, 0x24, 0x40, 0x4a, 0x14, 0x70, 0x15, 0x78, + 0x25, 0x42, 0x03, 0xd0, 0x55, 0x78, 0x6d, 0xb2, 0x00, 0x2d, 0xf8, 0xdb, + 0x01, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, + 0x39, 0x4c, 0x54, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, + 0x82, 0x24, 0xe4, 0x01, 0x54, 0x80, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x02, 0x24, 0x9c, 0x84, 0x0e, 0x34, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x31, 0x4c, 0xdc, 0x62, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x9d, 0x8c, 0x2e, 0x4c, 0x2c, 0x43, 0x9c, 0x84, 0x10, 0x24, + 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x02, 0x24, 0x9d, 0x8c, 0x80, 0x26, + 0x2c, 0x43, 0x9c, 0x84, 0x40, 0x24, 0xdd, 0x68, 0x35, 0x42, 0xfc, 0xd0, + 0xdd, 0x68, 0x25, 0x42, 0xf9, 0xd0, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x00, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x21, 0x4c, 0x54, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x1c, 0x6a, 0x1e, 0x4d, 0x2c, 0x40, 0x80, 0x25, 0x1c, 0x62, + 0x1c, 0x6a, 0xac, 0x43, 0x1c, 0x62, 0x03, 0x23, 0x93, 0x60, 0x1b, 0x4b, + 0x53, 0x60, 0x53, 0x78, 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x00, 0x23, + 0xff, 0x24, 0x0b, 0x72, 0x17, 0x4a, 0x4b, 0x72, 0x8b, 0x72, 0xcb, 0x72, + 0x16, 0x4b, 0x1a, 0x60, 0x16, 0x4b, 0x17, 0x4a, 0x1b, 0x68, 0x11, 0x68, + 0x9a, 0x06, 0x5b, 0x01, 0xc9, 0x0e, 0x23, 0x40, 0x52, 0x0f, 0x12, 0x02, + 0x0b, 0x43, 0x13, 0x43, 0x12, 0x4a, 0x13, 0x85, 0x80, 0x23, 0x42, 0x68, + 0x13, 0x43, 0x43, 0x60, 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x00, 0x04, 0x00, 0x40, 0x0c, 0x06, 0x00, 0x00, 0x00, 0x08, 0x00, 0x40, + 0x00, 0x0c, 0x00, 0x40, 0x01, 0x05, 0x01, 0x00, 0xb9, 0x05, 0xff, 0x7d, + 0x04, 0x0a, 0x00, 0x00, 0x00, 0x07, 0x03, 0x00, 0xff, 0xfc, 0xff, 0xff, + 0x03, 0x06, 0x01, 0x00, 0x00, 0x6c, 0xdc, 0x02, 0x00, 0x00, 0x00, 0x20, + 0x24, 0x60, 0x80, 0x00, 0x20, 0x60, 0x80, 0x00, 0x00, 0x40, 0x00, 0x42, + 0xfa, 0x21, 0x31, 0x4b, 0x10, 0xb5, 0x18, 0x68, 0x89, 0x00, 0x00, 0xf0, + 0xd5, 0xf9, 0x2f, 0x4b, 0x01, 0x38, 0x98, 0x42, 0x56, 0xd8, 0x2e, 0x49, + 0x2e, 0x4a, 0x48, 0x60, 0xc0, 0x20, 0x13, 0x6a, 0x00, 0x06, 0x1b, 0x02, + 0x1b, 0x0a, 0x03, 0x43, 0x13, 0x62, 0x00, 0x24, 0x07, 0x23, 0x8c, 0x60, + 0x0b, 0x60, 0x80, 0x21, 0x13, 0x6a, 0x09, 0x06, 0x1b, 0x02, 0x1b, 0x0a, + 0x0b, 0x43, 0x13, 0x62, 0xfc, 0x22, 0x25, 0x4b, 0x19, 0x6a, 0x0a, 0x43, + 0x1a, 0x62, 0xfc, 0x22, 0x19, 0x6a, 0x92, 0x01, 0x0a, 0x43, 0x1a, 0x62, + 0xa0, 0x22, 0x19, 0x6a, 0xd2, 0x02, 0x0a, 0x43, 0x1a, 0x62, 0x20, 0x00, + 0x00, 0x21, 0x01, 0x34, 0x00, 0xf0, 0x76, 0xf8, 0x0f, 0x2c, 0xf8, 0xd1, + 0x1b, 0x4b, 0x1c, 0x00, 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, + 0x19, 0x4a, 0x5a, 0x80, 0x19, 0x4b, 0x1a, 0x00, 0x59, 0x7e, 0xc9, 0x09, + 0x01, 0x29, 0xfb, 0xd0, 0xe4, 0x21, 0xc9, 0x00, 0x99, 0x80, 0x3f, 0x21, + 0xd9, 0x70, 0x53, 0x7e, 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0xc0, 0x23, + 0x00, 0x20, 0x5b, 0x01, 0x13, 0x61, 0x90, 0x70, 0x00, 0xf0, 0x24, 0xf8, + 0x63, 0x78, 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x0d, 0x4b, 0x0e, 0x4a, + 0x63, 0x80, 0xd3, 0x79, 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0x41, 0x23, + 0x53, 0x70, 0x10, 0xbd, 0xfe, 0xe7, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, + 0xff, 0xff, 0xff, 0x00, 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, + 0x00, 0x04, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, 0x1e, 0x40, 0x00, 0x00, + 0x00, 0x40, 0x00, 0x42, 0x21, 0x40, 0x00, 0x00, 0x00, 0x48, 0x00, 0x42, + 0x16, 0x4a, 0x00, 0xb5, 0x13, 0x00, 0x51, 0x7e, 0xc9, 0x09, 0x01, 0x29, + 0xfb, 0xd0, 0x01, 0x38, 0x04, 0x28, 0x16, 0xd8, 0x19, 0x69, 0x12, 0x4a, + 0x0a, 0x40, 0x0f, 0x21, 0x1a, 0x61, 0x5a, 0x78, 0x8a, 0x43, 0x00, 0xf0, + 0x47, 0xf9, 0x03, 0x08, 0x06, 0x0b, 0x03, 0x00, 0x11, 0x00, 0x01, 0x22, + 0x0a, 0x43, 0x5a, 0x70, 0x00, 0xbd, 0x11, 0x00, 0x03, 0x22, 0xf9, 0xe7, + 0x11, 0x00, 0x02, 0x22, 0xf6, 0xe7, 0xf0, 0x23, 0x11, 0x69, 0x1b, 0x05, + 0x0b, 0x43, 0x0f, 0x21, 0x13, 0x61, 0x53, 0x78, 0x8b, 0x43, 0x19, 0x00, + 0x02, 0x23, 0x0b, 0x43, 0x53, 0x70, 0xeb, 0xe7, 0x00, 0x40, 0x00, 0x42, + 0xff, 0xff, 0xff, 0xf0, 0x18, 0x23, 0x30, 0xb5, 0x1d, 0x00, 0x04, 0x00, + 0x45, 0x43, 0x08, 0x20, 0x20, 0x4a, 0x55, 0x19, 0x28, 0x56, 0x01, 0x30, + 0x14, 0xd0, 0x03, 0x29, 0x12, 0xd8, 0x08, 0x00, 0x63, 0x43, 0xd1, 0x56, + 0xd3, 0x18, 0x00, 0xf0, 0x15, 0xf9, 0x02, 0x28, 0x0e, 0x1b, 0x58, 0x68, + 0xcb, 0x01, 0x02, 0x21, 0x18, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, + 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x30, 0xbd, 0x58, 0x68, + 0xcb, 0x01, 0x06, 0x21, 0x12, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, + 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x9a, 0x61, 0xf1, 0xe7, + 0x58, 0x68, 0xcb, 0x01, 0x06, 0x21, 0x0c, 0x4a, 0x9b, 0x18, 0x1a, 0x18, + 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x5a, 0x61, + 0xe4, 0xe7, 0x58, 0x68, 0xcb, 0x01, 0x02, 0x21, 0x05, 0x4a, 0x9b, 0x18, + 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x9a, 0x60, + 0xd8, 0xe7, 0xc0, 0x46, 0x20, 0x82, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x18, 0x23, 0xf0, 0xb5, 0x08, 0x24, 0x58, 0x43, 0x11, 0x4a, 0x13, 0x18, + 0x1c, 0x57, 0x01, 0x34, 0x1b, 0xd0, 0x01, 0x26, 0x35, 0x00, 0x5f, 0x68, + 0x83, 0x56, 0xbd, 0x40, 0x0d, 0x4a, 0xdb, 0x01, 0x9a, 0x18, 0x90, 0x68, + 0x05, 0x42, 0x0b, 0xd1, 0x0c, 0x00, 0x60, 0x1e, 0x84, 0x41, 0xd2, 0x19, + 0x40, 0x32, 0x10, 0x78, 0x34, 0x40, 0x03, 0x36, 0xa4, 0x00, 0xb0, 0x43, + 0x20, 0x43, 0x10, 0x70, 0x04, 0x4a, 0x9b, 0x18, 0x00, 0x29, 0x01, 0xd1, + 0x5d, 0x61, 0xf0, 0xbd, 0x9d, 0x61, 0xfc, 0xe7, 0x20, 0x82, 0x00, 0x00, + 0x00, 0x44, 0x00, 0x41, 0x18, 0x22, 0x42, 0x43, 0xf8, 0xb5, 0x2c, 0x4e, + 0x03, 0x00, 0xb2, 0x18, 0x12, 0x7a, 0x52, 0xb2, 0x14, 0x00, 0x01, 0x32, + 0x0e, 0xd0, 0x48, 0x1c, 0x00, 0x24, 0x0c, 0x28, 0x0a, 0xd8, 0x00, 0xf0, + 0x9f, 0xf8, 0x07, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x0b, + 0x0b, 0x0b, 0x0b, 0x00, 0x01, 0x24, 0x64, 0x42, 0x20, 0x00, 0xf8, 0xbd, + 0x09, 0x29, 0x05, 0xd1, 0x00, 0x21, 0x18, 0x00, 0xff, 0xf7, 0x66, 0xff, + 0x00, 0x24, 0xf5, 0xe7, 0x0a, 0x29, 0x01, 0xd1, 0x08, 0x39, 0xf6, 0xe7, + 0x00, 0x24, 0x0b, 0x29, 0xee, 0xd1, 0x0a, 0x39, 0x18, 0x00, 0xff, 0xf7, + 0x59, 0xff, 0xe9, 0xe7, 0x18, 0x22, 0x53, 0x43, 0xf2, 0x18, 0x55, 0x68, + 0x01, 0x20, 0x2c, 0x00, 0xf3, 0x56, 0x13, 0x4a, 0xdb, 0x01, 0x6e, 0x08, + 0x9b, 0x18, 0xc9, 0xb2, 0x04, 0x40, 0x9e, 0x19, 0x00, 0x2c, 0x0d, 0xd0, + 0x0f, 0x24, 0x30, 0x36, 0x32, 0x78, 0x09, 0x01, 0x22, 0x40, 0x11, 0x43, + 0xc9, 0xb2, 0x5b, 0x19, 0x31, 0x70, 0x40, 0x33, 0x1a, 0x78, 0x10, 0x43, + 0x18, 0x70, 0xd3, 0xe7, 0x32, 0x00, 0x0f, 0x27, 0x30, 0x32, 0x16, 0x78, + 0x5b, 0x19, 0xbe, 0x43, 0x31, 0x43, 0x11, 0x70, 0x40, 0x33, 0x1a, 0x78, + 0x10, 0x43, 0x18, 0x70, 0xbe, 0xe7, 0xc0, 0x46, 0x20, 0x82, 0x00, 0x00, + 0x00, 0x44, 0x00, 0x41, 0xf7, 0xb5, 0x06, 0x00, 0x0d, 0x00, 0x0c, 0x00, + 0x8b, 0x18, 0x01, 0x93, 0x01, 0x9b, 0x67, 0x1b, 0x9c, 0x42, 0x07, 0xd0, + 0x33, 0x68, 0x21, 0x78, 0x1b, 0x68, 0x30, 0x00, 0x98, 0x47, 0x01, 0x34, + 0x00, 0x28, 0xf3, 0xd1, 0x38, 0x00, 0xfe, 0xbd, 0x16, 0x4a, 0x10, 0xb5, + 0x13, 0x68, 0x59, 0x1c, 0x26, 0xd0, 0x01, 0x3b, 0x13, 0x60, 0x00, 0x2b, + 0x22, 0xd1, 0x72, 0xb6, 0x12, 0x4b, 0x13, 0x4a, 0x04, 0x33, 0x93, 0x42, + 0x13, 0xd9, 0x12, 0x4a, 0x01, 0x21, 0x10, 0x00, 0x14, 0x7d, 0x0c, 0x42, + 0xfc, 0xd0, 0x20, 0x21, 0x14, 0x8b, 0xff, 0x31, 0x9b, 0x08, 0x5b, 0x00, + 0x21, 0x43, 0x11, 0x83, 0xd3, 0x61, 0x0c, 0x4b, 0x13, 0x80, 0x01, 0x23, + 0x02, 0x7d, 0x1a, 0x42, 0xfc, 0xd0, 0xbf, 0xf3, 0x4f, 0x8f, 0x09, 0x4b, + 0x09, 0x4a, 0xda, 0x60, 0xbf, 0xf3, 0x4f, 0x8f, 0xc0, 0x46, 0xfd, 0xe7, + 0x10, 0xbd, 0xc0, 0x46, 0x04, 0x00, 0x00, 0x20, 0x00, 0x20, 0x00, 0x00, + 0x03, 0x02, 0x00, 0x00, 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, + 0x00, 0xed, 0x00, 0xe0, 0x04, 0x00, 0xfa, 0x05, 0x02, 0xb4, 0x71, 0x46, + 0x49, 0x08, 0x49, 0x00, 0x09, 0x5c, 0x49, 0x00, 0x8e, 0x44, 0x02, 0xbc, + 0x70, 0x47, 0xc0, 0x46, 0x00, 0x22, 0x43, 0x08, 0x8b, 0x42, 0x74, 0xd3, + 0x03, 0x09, 0x8b, 0x42, 0x5f, 0xd3, 0x03, 0x0a, 0x8b, 0x42, 0x44, 0xd3, + 0x03, 0x0b, 0x8b, 0x42, 0x28, 0xd3, 0x03, 0x0c, 0x8b, 0x42, 0x0d, 0xd3, + 0xff, 0x22, 0x09, 0x02, 0x12, 0xba, 0x03, 0x0c, 0x8b, 0x42, 0x02, 0xd3, + 0x12, 0x12, 0x09, 0x02, 0x65, 0xd0, 0x03, 0x0b, 0x8b, 0x42, 0x19, 0xd3, + 0x00, 0xe0, 0x09, 0x0a, 0xc3, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x03, + 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x03, + 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x03, + 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x03, + 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x02, + 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x02, + 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x02, + 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x02, + 0xc0, 0x1a, 0x52, 0x41, 0xcd, 0xd2, 0xc3, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0xcb, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0x8b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0x4b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0x0b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x08, 0x8b, 0x42, 0x01, 0xd3, + 0xcb, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x08, 0x8b, 0x42, 0x01, 0xd3, + 0x8b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x08, 0x8b, 0x42, 0x01, 0xd3, + 0x4b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x41, 0x1a, 0x00, 0xd2, 0x01, 0x46, + 0x52, 0x41, 0x10, 0x46, 0x70, 0x47, 0xff, 0xe7, 0x01, 0xb5, 0x00, 0x20, + 0x00, 0xf0, 0x06, 0xf8, 0x02, 0xbd, 0xc0, 0x46, 0x00, 0x29, 0xf7, 0xd0, + 0x76, 0xe7, 0x70, 0x47, 0x70, 0x47, 0xc0, 0x46, 0x70, 0xb5, 0x00, 0x26, + 0x0c, 0x4d, 0x0d, 0x4c, 0x64, 0x1b, 0xa4, 0x10, 0xa6, 0x42, 0x09, 0xd1, + 0x00, 0x26, 0x00, 0xf0, 0x4f, 0xf8, 0x0a, 0x4d, 0x0a, 0x4c, 0x64, 0x1b, + 0xa4, 0x10, 0xa6, 0x42, 0x05, 0xd1, 0x70, 0xbd, 0xb3, 0x00, 0xeb, 0x58, + 0x98, 0x47, 0x01, 0x36, 0xee, 0xe7, 0xb3, 0x00, 0xeb, 0x58, 0x98, 0x47, + 0x01, 0x36, 0xf2, 0xe7, 0x08, 0x00, 0x00, 0x20, 0x08, 0x00, 0x00, 0x20, + 0x08, 0x00, 0x00, 0x20, 0x24, 0x00, 0x00, 0x20, 0x00, 0x23, 0x10, 0xb5, + 0x9a, 0x42, 0x00, 0xd1, 0x10, 0xbd, 0xcc, 0x5c, 0xc4, 0x54, 0x01, 0x33, + 0xf8, 0xe7, 0x03, 0x00, 0x12, 0x18, 0x93, 0x42, 0x00, 0xd1, 0x70, 0x47, + 0x19, 0x70, 0x01, 0x33, 0xf9, 0xe7, 0x02, 0x78, 0x0b, 0x78, 0x00, 0x2a, + 0x03, 0xd0, 0x01, 0x30, 0x01, 0x31, 0x9a, 0x42, 0xf7, 0xd0, 0xd0, 0x1a, + 0x70, 0x47, 0x00, 0x23, 0xc2, 0x5c, 0x01, 0x33, 0x00, 0x2a, 0xfb, 0xd1, + 0x58, 0x1e, 0x70, 0x47, 0x30, 0xb5, 0x05, 0x00, 0x00, 0x2a, 0x00, 0xd1, + 0x30, 0xbd, 0x0c, 0x78, 0x01, 0x3a, 0x6b, 0x1c, 0x2c, 0x70, 0x01, 0x31, + 0x00, 0x2c, 0x05, 0xd1, 0x9a, 0x18, 0x9a, 0x42, 0xf4, 0xd0, 0x1c, 0x70, + 0x01, 0x33, 0xfa, 0xe7, 0x1d, 0x00, 0xed, 0xe7, 0xf8, 0xb5, 0xc0, 0x46, + 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, 0xf8, 0xb5, 0xc0, 0x46, + 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, 0x55, 0x50, 0x44, 0x41, + 0x54, 0x45, 0x2e, 0x42, 0x49, 0x4e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x10, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, + 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, + 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x04, + 0x00, 0x04, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x01, + 0x00, 0x01, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x13, 0x00, 0x01, 0x01, + 0x01, 0x01, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x05, + 0x00, 0x05, 0x0a, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x05, + 0x01, 0x05, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x02, 0x00, + 0x02, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, + 0x03, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x02, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x03, + 0x01, 0x03, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x10, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x11, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0a, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0b, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x05, 0x00, 0x01, 0x00, + 0x01, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x06, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x07, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x03, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x85, 0x73, 0x00, 0x00, 0x11, 0x7a, 0x00, 0x00, 0xab, 0x72, 0x00, 0x00, + 0x67, 0x72, 0x00, 0x00, 0x81, 0x72, 0x00, 0x00, 0x39, 0x74, 0x00, 0x00, + 0x49, 0x70, 0x00, 0x00, 0x39, 0x70, 0x00, 0x00, 0xcd, 0x70, 0x00, 0x00, + 0x63, 0x70, 0x00, 0x00, 0x33, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x40, 0x42, 0x0f, 0x00, 0xff, 0xff, 0xff, 0xff, 0xdd, 0x20, 0x00, 0x00, + 0x25, 0x22, 0x00, 0x00, 0x39, 0x22, 0x00, 0x00, 0xa5, 0x23, 0x00, 0x00, + 0x3d, 0x26, 0x00, 0x00, 0x41, 0x6c, 0x00, 0x00, 0xb5, 0x6c, 0x00, 0x00, + 0xb5, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 diff --git a/libraries/SFU/src/boot/mkrwan1310.h b/libraries/SFU/src/boot/mkrwan1310.h new file mode 100644 index 0000000..e69de29 diff --git a/libraries/SFU/src/boot/mkrwifi1010.h b/libraries/SFU/src/boot/mkrwifi1010.h new file mode 100644 index 0000000..a5f6ff9 --- /dev/null +++ b/libraries/SFU/src/boot/mkrwifi1010.h @@ -0,0 +1,2196 @@ + 0x00, 0x80, 0x00, 0x20, 0x59, 0x75, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, + 0x41, 0x75, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, + 0xad, 0x75, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, + 0x41, 0x75, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, + 0x41, 0x75, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, 0x45, 0x75, 0x00, 0x00, + 0x41, 0x75, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, + 0x41, 0x75, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, 0xb9, 0x6c, 0x00, 0x00, + 0xa9, 0x6c, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, + 0x41, 0x75, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, + 0x41, 0x75, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, + 0x41, 0x75, 0x00, 0x00, 0x41, 0x75, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0x30, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xb4, 0x86, 0x00, 0x00, 0x04, 0x4b, 0x10, 0xb5, 0x00, 0x2b, 0x03, 0xd0, + 0x03, 0x49, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x10, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x00, 0x34, 0x00, 0x00, 0x20, 0xb4, 0x86, 0x00, 0x00, + 0xf0, 0xb5, 0x40, 0x4c, 0xa5, 0x44, 0x00, 0xaf, 0x05, 0xf0, 0x60, 0xfb, + 0x05, 0xf0, 0xc6, 0xfd, 0x01, 0x20, 0x05, 0xf0, 0x85, 0xfa, 0x3c, 0x48, + 0x00, 0xf0, 0x8c, 0xf9, 0x3b, 0x4c, 0x20, 0x00, 0x00, 0xf0, 0x1c, 0xf9, + 0x00, 0x28, 0x5d, 0xd1, 0x20, 0x00, 0x02, 0xf0, 0x29, 0xfb, 0x00, 0x28, + 0x58, 0xd1, 0x20, 0x00, 0x02, 0xf0, 0x44, 0xf9, 0x0c, 0x20, 0x08, 0x23, + 0x34, 0x4a, 0x21, 0x00, 0x38, 0x18, 0x00, 0xf0, 0x23, 0xf9, 0x20, 0x00, + 0x02, 0xf0, 0x38, 0xf9, 0x05, 0x1e, 0x45, 0xd1, 0x0c, 0x23, 0x01, 0x00, + 0x02, 0x22, 0xf8, 0x18, 0x00, 0xf0, 0x42, 0xf9, 0x80, 0x21, 0x78, 0x60, + 0x09, 0x02, 0x2e, 0x00, 0x88, 0x42, 0x2c, 0xdd, 0x0c, 0x23, 0x2a, 0x00, + 0xf8, 0x18, 0x00, 0xf0, 0x37, 0xf9, 0x28, 0x4a, 0xa0, 0x21, 0x94, 0x46, + 0x7b, 0x68, 0x09, 0x02, 0x63, 0x44, 0x1a, 0x00, 0x25, 0x48, 0xa0, 0x25, + 0x80, 0x26, 0x7b, 0x60, 0x00, 0xf0, 0xd6, 0xf8, 0x2d, 0x02, 0xb6, 0x00, + 0x08, 0x23, 0xf8, 0x18, 0xc1, 0x18, 0x04, 0x33, 0x32, 0x00, 0xf8, 0x18, + 0x00, 0xf0, 0x14, 0xf9, 0x08, 0x22, 0xb9, 0x18, 0x8a, 0x18, 0x33, 0x00, + 0x29, 0x00, 0x1b, 0x48, 0x00, 0xf0, 0x74, 0xf8, 0x80, 0x22, 0x1a, 0x4b, + 0x92, 0x00, 0xeb, 0x18, 0xad, 0x18, 0x7a, 0x68, 0x93, 0x42, 0xe7, 0xdb, + 0x01, 0x26, 0x0c, 0x23, 0xf8, 0x18, 0x00, 0xf0, 0x17, 0xf9, 0x00, 0x2e, + 0x03, 0xd0, 0x10, 0x49, 0x20, 0x00, 0x02, 0xf0, 0x55, 0xfa, 0x20, 0x00, + 0x02, 0xf0, 0xca, 0xf8, 0x0c, 0x23, 0xf8, 0x18, 0x00, 0xf0, 0x14, 0xf9, + 0xa0, 0x23, 0x1b, 0x02, 0x1a, 0x68, 0x82, 0xf3, 0x08, 0x88, 0x0c, 0x4a, + 0x93, 0x60, 0x0c, 0x4b, 0x1b, 0x68, 0x18, 0x47, 0x00, 0x20, 0xbd, 0x46, + 0x85, 0x23, 0x9b, 0x00, 0x9d, 0x44, 0xf0, 0xbd, 0xec, 0xfd, 0xff, 0xff, + 0xf4, 0x0b, 0x00, 0x20, 0x8c, 0x04, 0x00, 0x20, 0x64, 0x7d, 0x00, 0x00, + 0x00, 0x80, 0xff, 0xff, 0x4c, 0x00, 0x00, 0x20, 0x00, 0x62, 0xff, 0xff, + 0x00, 0xed, 0x00, 0xe0, 0x04, 0xa0, 0x00, 0x00, 0x00, 0x22, 0x10, 0xb5, + 0x11, 0x00, 0x02, 0x48, 0x00, 0xf0, 0x1a, 0xf8, 0x10, 0xbd, 0xc0, 0x46, + 0x4c, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x05, 0x4a, 0x05, 0x49, 0x06, 0x48, + 0x00, 0xf0, 0x10, 0xf8, 0x00, 0x22, 0x05, 0x4b, 0x05, 0x49, 0x1a, 0x70, + 0x5a, 0x54, 0x10, 0xbd, 0x01, 0x04, 0x00, 0x00, 0x00, 0x7e, 0x00, 0x00, + 0x68, 0x04, 0x00, 0x20, 0x64, 0x00, 0x00, 0x20, 0x02, 0x04, 0x00, 0x00, + 0x30, 0xb5, 0x09, 0x4d, 0x09, 0x4c, 0xab, 0x68, 0x5b, 0x03, 0x5b, 0x0f, + 0x9b, 0x00, 0x1c, 0x59, 0x04, 0x60, 0xab, 0x68, 0x01, 0x61, 0x9b, 0xb2, + 0x43, 0x60, 0x63, 0x43, 0xa4, 0x00, 0x83, 0x60, 0xc4, 0x60, 0x42, 0x61, + 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, 0x00, 0x83, 0x00, 0x00, + 0xf7, 0xb5, 0x80, 0x26, 0x1a, 0x4d, 0x01, 0x91, 0x6f, 0x68, 0x03, 0x33, + 0x3e, 0x43, 0x9b, 0x08, 0x6e, 0x60, 0x00, 0x2b, 0x2b, 0xd0, 0x17, 0x4e, + 0x2e, 0x80, 0x2e, 0x7d, 0xf1, 0x07, 0xfc, 0xd5, 0x1e, 0x00, 0x07, 0x68, + 0x99, 0x1b, 0xbf, 0x08, 0x8f, 0x42, 0x19, 0xd9, 0x00, 0x2e, 0x17, 0xd0, + 0xff, 0x21, 0x17, 0x78, 0x8c, 0x43, 0x3c, 0x43, 0x0f, 0x49, 0x57, 0x78, + 0x0c, 0x40, 0x3f, 0x02, 0x3c, 0x43, 0x97, 0x78, 0x01, 0x3e, 0x39, 0x04, + 0x0c, 0x4f, 0x27, 0x40, 0xd4, 0x78, 0xbf, 0xb2, 0x0f, 0x43, 0x24, 0x06, + 0x01, 0x99, 0x3c, 0x43, 0x10, 0xc1, 0x01, 0x91, 0x04, 0x32, 0xe0, 0xe7, + 0x07, 0x4b, 0x2b, 0x80, 0x2b, 0x7d, 0xdb, 0x07, 0xfc, 0xd5, 0x33, 0x00, + 0xd1, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x44, 0xa5, 0xff, 0xff, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, 0x04, 0xa5, 0xff, 0xff, + 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, 0x1a, 0x80, 0x1a, 0x7d, + 0xd2, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x16, 0x00, + 0xe3, 0x68, 0x29, 0x00, 0x20, 0x00, 0xb3, 0x42, 0x05, 0xd2, 0xff, 0xf7, + 0xe7, 0xff, 0xe3, 0x68, 0xed, 0x18, 0xf6, 0x1a, 0xf4, 0xe7, 0xff, 0xf7, + 0xe1, 0xff, 0x70, 0xbd, 0x1f, 0xb5, 0x00, 0x21, 0x03, 0x91, 0x90, 0x21, + 0xc9, 0x00, 0x02, 0x91, 0xa1, 0x39, 0xff, 0x39, 0x41, 0x18, 0x98, 0x23, + 0x01, 0x91, 0x02, 0x00, 0x80, 0x21, 0x9b, 0x00, 0x00, 0x91, 0xc3, 0x18, + 0x60, 0x32, 0x02, 0x49, 0x01, 0xf0, 0x9c, 0xff, 0x05, 0xb0, 0x00, 0xbd, + 0x80, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, 0x08, 0x00, 0x11, 0x00, + 0x1a, 0x00, 0x00, 0x23, 0x02, 0xf0, 0x16, 0xf8, 0x01, 0x00, 0x20, 0x00, + 0x00, 0xf0, 0x3a, 0xf8, 0x20, 0x00, 0x10, 0xbd, 0x03, 0x4b, 0x04, 0x4a, + 0x1a, 0x60, 0x04, 0x4a, 0x5a, 0x60, 0x04, 0x4a, 0x9a, 0x60, 0x70, 0x47, + 0x80, 0x04, 0x00, 0x20, 0x01, 0x26, 0x00, 0x00, 0x15, 0x26, 0x00, 0x00, + 0x29, 0x26, 0x00, 0x00, 0x10, 0xb5, 0x0c, 0x00, 0x13, 0x00, 0x00, 0x22, + 0x81, 0x5e, 0x22, 0x00, 0x01, 0x48, 0x02, 0xf0, 0x87, 0xf8, 0x10, 0xbd, + 0x8c, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x0c, 0x00, 0x13, 0x00, 0x00, 0x22, + 0x81, 0x5e, 0x22, 0x00, 0x01, 0x48, 0x02, 0xf0, 0xdd, 0xf8, 0x10, 0xbd, + 0x8c, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x00, 0x23, 0xc1, 0x5e, 0x02, 0x48, + 0x02, 0xf0, 0x9c, 0xf9, 0x10, 0xbd, 0xc0, 0x46, 0x8c, 0x04, 0x00, 0x20, + 0x10, 0xb5, 0x04, 0x00, 0xff, 0xf7, 0xf2, 0xff, 0x20, 0x00, 0x10, 0xbd, + 0x01, 0x80, 0x70, 0x47, 0x10, 0xb5, 0x00, 0x21, 0x40, 0x68, 0x05, 0xf0, + 0xc9, 0xfa, 0x10, 0xbd, 0x10, 0xb5, 0x01, 0x21, 0x40, 0x68, 0x05, 0xf0, + 0xc3, 0xfa, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x68, 0x04, 0xf0, + 0xb9, 0xfb, 0x01, 0x21, 0x60, 0x68, 0x05, 0xf0, 0x6d, 0xfa, 0x20, 0x00, + 0xff, 0xf7, 0xee, 0xff, 0x10, 0xbd, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x00, + 0xff, 0xf7, 0xe2, 0xff, 0x09, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, + 0xcf, 0xfb, 0x05, 0x21, 0x20, 0x68, 0x04, 0xf0, 0xe7, 0xfb, 0x00, 0x21, + 0x20, 0x68, 0x04, 0xf0, 0xe3, 0xfb, 0x05, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0xd7, 0xff, 0x28, 0x00, 0x70, 0xbd, 0xc0, 0x46, 0xec, 0x0b, 0x00, 0x20, + 0x10, 0xb5, 0xff, 0xf7, 0xe3, 0xff, 0x01, 0x23, 0x18, 0x40, 0x10, 0xbd, + 0xf7, 0xb5, 0x04, 0x00, 0x0e, 0x00, 0x15, 0x00, 0x10, 0x27, 0x01, 0x93, + 0x20, 0x00, 0xff, 0xf7, 0xf1, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x3b, 0x00, + 0x01, 0x3b, 0xfd, 0xd1, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xb4, 0xff, + 0x12, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, 0xa1, 0xfb, 0x03, 0x21, + 0x20, 0x68, 0x04, 0xf0, 0xb9, 0xfb, 0x31, 0x0c, 0xc9, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0xb4, 0xfb, 0x31, 0x0a, 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, + 0xaf, 0xfb, 0xf1, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0xab, 0xfb, 0x01, 0x9b, + 0xee, 0x18, 0xb5, 0x42, 0x06, 0xd0, 0x00, 0x21, 0x20, 0x68, 0x04, 0xf0, + 0xa3, 0xfb, 0x28, 0x70, 0x01, 0x35, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, + 0x95, 0xff, 0xf7, 0xbd, 0xec, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, + 0xff, 0xf7, 0x88, 0xff, 0x06, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, + 0x75, 0xfb, 0x06, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x8d, 0xfb, 0x20, 0x00, + 0xff, 0xf7, 0x82, 0xff, 0x10, 0xbd, 0xc0, 0x46, 0xec, 0x0b, 0x00, 0x20, + 0xf7, 0xb5, 0x04, 0x00, 0x0e, 0x00, 0x15, 0x00, 0x10, 0x27, 0x01, 0x93, + 0x20, 0x00, 0xff, 0xf7, 0xa3, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x3b, 0x00, + 0x01, 0x3b, 0xfd, 0xd1, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xda, 0xff, + 0x20, 0x00, 0xff, 0xf7, 0x63, 0xff, 0x12, 0x4b, 0x20, 0x68, 0x06, 0xcb, + 0x04, 0xf0, 0x50, 0xfb, 0x02, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x68, 0xfb, + 0x31, 0x0c, 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x63, 0xfb, 0x31, 0x0a, + 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x5e, 0xfb, 0xf1, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0x5a, 0xfb, 0x01, 0x9b, 0xee, 0x18, 0xb5, 0x42, 0x05, 0xd0, + 0x29, 0x78, 0x20, 0x68, 0x04, 0xf0, 0x52, 0xfb, 0x01, 0x35, 0xf7, 0xe7, + 0x20, 0x00, 0xff, 0xf7, 0x45, 0xff, 0xf7, 0xbd, 0xec, 0x0b, 0x00, 0x20, + 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x10, 0x26, 0x20, 0x00, 0xff, 0xf7, + 0x69, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x33, 0x00, 0x01, 0x3b, 0xfd, 0xd1, + 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xa0, 0xff, 0x20, 0x00, 0xff, 0xf7, + 0x29, 0xff, 0x0d, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, 0x16, 0xfb, + 0x20, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x2e, 0xfb, 0x29, 0x0c, 0xc9, 0xb2, + 0x20, 0x68, 0x04, 0xf0, 0x29, 0xfb, 0x29, 0x0a, 0xc9, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0x24, 0xfb, 0xe9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x20, 0xfb, + 0x20, 0x00, 0xff, 0xf7, 0x15, 0xff, 0x70, 0xbd, 0xec, 0x0b, 0x00, 0x20, + 0x10, 0xb5, 0x0b, 0x00, 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, 0x40, 0xff, + 0x00, 0x20, 0x10, 0xbd, 0xf4, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x0b, 0x00, + 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, 0x84, 0xff, 0x00, 0x20, 0x10, 0xbd, + 0xf4, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, + 0xb7, 0xff, 0x00, 0x20, 0x10, 0xbd, 0xc0, 0x46, 0xf4, 0x0b, 0x00, 0x20, + 0x05, 0x4b, 0x06, 0x4a, 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, + 0x04, 0x4b, 0x05, 0x4a, 0x1a, 0x60, 0x05, 0x22, 0x5a, 0x60, 0x70, 0x47, + 0xec, 0x0b, 0x00, 0x20, 0x00, 0x1b, 0xb7, 0x00, 0xf4, 0x0b, 0x00, 0x20, + 0xfc, 0x0b, 0x00, 0x20, 0x01, 0x23, 0x8b, 0x40, 0xf7, 0xb5, 0x44, 0x6c, + 0x01, 0x93, 0x01, 0x9d, 0xa3, 0x68, 0x06, 0x00, 0x00, 0x20, 0x2b, 0x42, + 0x1c, 0xd0, 0x8a, 0x25, 0x6d, 0x00, 0x69, 0x43, 0x23, 0x69, 0x5d, 0x18, + 0x82, 0x42, 0x0f, 0xd0, 0x2a, 0x78, 0x57, 0xb2, 0x87, 0x42, 0x0b, 0xdb, + 0x01, 0x27, 0x3a, 0x42, 0x08, 0xd0, 0x0a, 0x00, 0x80, 0x21, 0x28, 0x89, + 0x14, 0x32, 0x9a, 0x18, 0x00, 0x02, 0x73, 0x68, 0x49, 0x00, 0x98, 0x47, + 0xa3, 0x68, 0x01, 0x9a, 0x93, 0x43, 0xa3, 0x60, 0x00, 0x23, 0x2b, 0x70, + 0xfe, 0xbd, 0xc3, 0x68, 0xf0, 0xb5, 0x84, 0x68, 0x02, 0x00, 0x23, 0x40, + 0x18, 0x1e, 0x17, 0xd0, 0x8a, 0x27, 0x00, 0x23, 0x15, 0x78, 0x7f, 0x00, + 0xab, 0x42, 0x01, 0xdb, 0x00, 0x20, 0x0f, 0xe0, 0x01, 0x20, 0x98, 0x40, + 0x04, 0x42, 0x0c, 0xd0, 0x38, 0x00, 0x58, 0x43, 0x16, 0x69, 0x30, 0x18, + 0x06, 0x78, 0x7f, 0x2e, 0x05, 0xd8, 0x06, 0x89, 0x8e, 0x42, 0x02, 0xd1, + 0x53, 0x68, 0x43, 0x60, 0xf0, 0xbd, 0x01, 0x33, 0xe8, 0xe7, 0x82, 0x68, + 0x01, 0x00, 0x30, 0xb5, 0x00, 0x20, 0x53, 0x1c, 0x13, 0xd0, 0x00, 0x23, + 0x01, 0x25, 0x08, 0x78, 0x83, 0x42, 0x01, 0xdb, 0x00, 0x20, 0x0c, 0xe0, + 0x2c, 0x00, 0x9c, 0x40, 0x14, 0x42, 0x09, 0xd1, 0x8a, 0x20, 0x40, 0x00, + 0x58, 0x43, 0x0b, 0x69, 0x22, 0x43, 0x18, 0x18, 0x4b, 0x68, 0x8a, 0x60, + 0x43, 0x60, 0x30, 0xbd, 0x01, 0x33, 0xeb, 0xe7, 0xf8, 0xb5, 0x44, 0x6c, + 0x07, 0x00, 0xe2, 0x68, 0xa3, 0x68, 0x00, 0x20, 0x13, 0x40, 0x9a, 0x42, + 0x0e, 0xd1, 0x23, 0x78, 0x01, 0x21, 0x9c, 0x46, 0x02, 0x00, 0x03, 0x00, + 0x49, 0x42, 0x62, 0x45, 0x07, 0xdb, 0x00, 0x20, 0x4b, 0x1c, 0x03, 0xd0, + 0x01, 0x22, 0x38, 0x00, 0xff, 0xf7, 0x80, 0xff, 0xf8, 0xbd, 0x8a, 0x26, + 0x76, 0x00, 0x56, 0x43, 0x25, 0x69, 0xae, 0x19, 0x70, 0x68, 0x65, 0x68, + 0x2d, 0x1a, 0x9d, 0x42, 0x04, 0xd9, 0x36, 0x78, 0x7f, 0x2e, 0x01, 0xd8, + 0x2b, 0x00, 0x11, 0x00, 0x01, 0x32, 0xe4, 0xe7, 0x10, 0xb5, 0x04, 0x00, + 0x40, 0x6c, 0xff, 0xf7, 0x92, 0xff, 0x00, 0x28, 0x04, 0xd0, 0x41, 0x78, + 0x00, 0x22, 0x20, 0x00, 0xff, 0xf7, 0x62, 0xff, 0x10, 0xbd, 0xf7, 0xb5, + 0x46, 0x6c, 0x1c, 0x00, 0x1b, 0x0a, 0x9b, 0xb2, 0x05, 0x00, 0x0f, 0x00, + 0x30, 0x00, 0x19, 0x00, 0x01, 0x93, 0xff, 0xf7, 0x7e, 0xff, 0x73, 0x68, + 0x01, 0x33, 0x73, 0x60, 0x00, 0x28, 0x10, 0xd0, 0x8a, 0x21, 0x43, 0x60, + 0x43, 0x78, 0x49, 0x00, 0x59, 0x43, 0xe4, 0xb2, 0x14, 0x34, 0x09, 0x19, + 0x34, 0x69, 0x08, 0x9a, 0x61, 0x18, 0x09, 0x98, 0x05, 0xf0, 0x80, 0xfa, + 0x00, 0x27, 0x38, 0x00, 0xfe, 0xbd, 0x03, 0x23, 0x1f, 0x40, 0x01, 0x2f, + 0x06, 0xd1, 0x2b, 0x68, 0x09, 0x9a, 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, + 0x07, 0x00, 0xf2, 0xe7, 0x28, 0x00, 0xff, 0xf7, 0x99, 0xff, 0x07, 0x00, + 0x68, 0x6c, 0xff, 0xf7, 0x78, 0xff, 0x00, 0x90, 0x00, 0x28, 0x24, 0xd0, + 0x02, 0x23, 0x6a, 0x46, 0x03, 0x70, 0x8a, 0x23, 0x92, 0x88, 0x5b, 0x00, + 0x02, 0x81, 0x42, 0x78, 0x80, 0x21, 0x5a, 0x43, 0x33, 0x69, 0x14, 0x32, + 0x9a, 0x18, 0x20, 0x00, 0xff, 0x23, 0x49, 0x00, 0x98, 0x43, 0x2b, 0x68, + 0x98, 0x47, 0x8a, 0x21, 0x49, 0x00, 0x00, 0x28, 0x00, 0xd0, 0x07, 0x00, + 0x00, 0x9b, 0xe4, 0xb2, 0x5b, 0x78, 0x14, 0x34, 0x59, 0x43, 0x09, 0x19, + 0x34, 0x69, 0x08, 0x9a, 0x61, 0x18, 0x09, 0x98, 0x05, 0xf0, 0x44, 0xfa, + 0xc3, 0xe7, 0x2b, 0x68, 0x09, 0x9a, 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, + 0x00, 0x28, 0xc7, 0xd1, 0xbb, 0xe7, 0xf7, 0xb5, 0x47, 0x6c, 0x01, 0x91, + 0x19, 0x0a, 0x05, 0x00, 0x89, 0xb2, 0x38, 0x00, 0x1c, 0x00, 0xff, 0xf7, + 0x1c, 0xff, 0x06, 0x1e, 0x0c, 0xd0, 0x1c, 0x22, 0x01, 0x9b, 0x1a, 0x40, + 0x18, 0x2a, 0x07, 0xd0, 0x41, 0x78, 0x00, 0x2a, 0x0a, 0xd1, 0x9b, 0x07, + 0x08, 0xd0, 0x28, 0x00, 0xff, 0xf7, 0xe4, 0xfe, 0x6b, 0x68, 0x09, 0x9a, + 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, 0x14, 0xe0, 0x8a, 0x23, 0x5b, 0x00, + 0x59, 0x43, 0xe0, 0xb2, 0x3b, 0x69, 0x14, 0x30, 0x40, 0x18, 0x18, 0x18, + 0x08, 0x9a, 0x09, 0x99, 0x05, 0xf0, 0x10, 0xfa, 0x02, 0x22, 0x7b, 0x68, + 0x01, 0x33, 0x7b, 0x60, 0x73, 0x60, 0x33, 0x78, 0x13, 0x40, 0x18, 0x1e, + 0xe4, 0xd1, 0xfe, 0xbd, 0xf7, 0xb5, 0x42, 0x6c, 0x94, 0x68, 0xd3, 0x68, + 0x23, 0x40, 0x18, 0x1e, 0x09, 0xd0, 0x13, 0x78, 0x8a, 0x26, 0x01, 0x93, + 0x01, 0x25, 0x00, 0x23, 0x76, 0x00, 0x01, 0x98, 0x98, 0x42, 0x01, 0xdc, + 0x00, 0x20, 0xfe, 0xbd, 0x28, 0x00, 0x98, 0x40, 0x04, 0x42, 0x0b, 0xd0, + 0x30, 0x00, 0x58, 0x43, 0x17, 0x69, 0x38, 0x18, 0x07, 0x78, 0x7f, 0x2f, + 0x04, 0xd9, 0x07, 0x89, 0xbc, 0x46, 0xcf, 0x88, 0xbc, 0x45, 0xee, 0xd0, + 0x01, 0x33, 0xe8, 0xe7, 0x70, 0xb5, 0x0c, 0x1e, 0x0f, 0xd0, 0x30, 0x21, + 0xc5, 0x6a, 0x83, 0x6a, 0x69, 0x43, 0x1a, 0x1d, 0x5b, 0x18, 0x00, 0x21, + 0x04, 0x33, 0x9a, 0x42, 0x06, 0xd1, 0x61, 0x78, 0x00, 0x22, 0xff, 0xf7, + 0x93, 0xfe, 0x00, 0x23, 0x23, 0x81, 0x70, 0xbd, 0x00, 0x26, 0x95, 0x5f, + 0x00, 0x2d, 0x03, 0xd0, 0xd5, 0x69, 0xa5, 0x42, 0x00, 0xd1, 0xd1, 0x61, + 0x30, 0x32, 0xec, 0xe7, 0xf0, 0xb5, 0x47, 0x6c, 0x89, 0xb0, 0x06, 0x00, + 0x00, 0x2f, 0x36, 0xd0, 0x8a, 0x21, 0x80, 0x6c, 0x49, 0x00, 0x14, 0x38, + 0x05, 0xf0, 0x08, 0xf9, 0x04, 0x1e, 0x2e, 0xd0, 0x00, 0x23, 0x01, 0x21, + 0x01, 0x93, 0x01, 0x9a, 0x01, 0x33, 0x52, 0x00, 0x0a, 0x43, 0x01, 0x92, + 0x9c, 0x42, 0xf8, 0xdc, 0x03, 0xad, 0x08, 0x22, 0x00, 0x21, 0x28, 0x00, + 0x05, 0xf0, 0xaf, 0xf9, 0x3b, 0x00, 0x14, 0x33, 0x2b, 0x61, 0x01, 0x23, + 0x5b, 0x42, 0xab, 0x60, 0x01, 0x9b, 0x29, 0x00, 0x14, 0x22, 0x38, 0x00, + 0xeb, 0x60, 0x2c, 0x70, 0x05, 0xf0, 0x98, 0xf9, 0x75, 0x6c, 0x8a, 0x26, + 0x2a, 0x78, 0x76, 0x00, 0x72, 0x43, 0x00, 0x21, 0x28, 0x69, 0x05, 0xf0, + 0x98, 0xf9, 0xab, 0x68, 0xea, 0x68, 0xe4, 0xb2, 0x93, 0x43, 0xab, 0x60, + 0x00, 0x23, 0x9c, 0x42, 0x01, 0xdc, 0x09, 0xb0, 0xf0, 0xbd, 0x32, 0x00, + 0x5a, 0x43, 0x29, 0x69, 0x8a, 0x18, 0x53, 0x70, 0x01, 0x33, 0xf4, 0xe7, + 0xf0, 0xb5, 0x85, 0xb0, 0x06, 0x00, 0x0d, 0x00, 0x14, 0x00, 0x03, 0x93, + 0x00, 0x27, 0x68, 0x2a, 0x06, 0xd9, 0x10, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x05, 0xf0, 0xc0, 0xf8, 0x01, 0x30, 0x87, 0xb2, 0x80, 0x21, 0x0a, 0x9b, + 0x09, 0x02, 0x00, 0x93, 0x29, 0x43, 0x00, 0x23, 0x3a, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0xfa, 0xfa, 0x00, 0x28, 0x11, 0xdb, 0x0a, 0x9b, 0x1d, 0x88, + 0x2d, 0x02, 0x00, 0x2f, 0x0e, 0xd1, 0x23, 0x00, 0x17, 0x33, 0x03, 0x9a, + 0x5b, 0x00, 0x01, 0x92, 0x02, 0x22, 0x5b, 0x19, 0x00, 0x92, 0x15, 0x21, + 0x00, 0x22, 0x30, 0x00, 0xff, 0xf7, 0xb1, 0xfe, 0x05, 0xb0, 0xf0, 0xbd, + 0x23, 0x1d, 0x68, 0x2c, 0xef, 0xd9, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x05, 0xf0, 0x1c, 0xf9, 0x0b, 0x1d, 0xe8, 0xe7, 0x30, 0xb5, 0x0e, 0x25, + 0x00, 0x23, 0x85, 0xb0, 0x6d, 0x44, 0x1a, 0x00, 0x00, 0x95, 0x04, 0x00, + 0x02, 0xf0, 0xd0, 0xfa, 0x0b, 0x4b, 0x98, 0x42, 0x12, 0xd0, 0x00, 0x28, + 0x0e, 0xdb, 0x0d, 0x22, 0xbf, 0x23, 0x6a, 0x44, 0x13, 0x70, 0x2b, 0x88, + 0x01, 0x92, 0x01, 0x22, 0x1b, 0x02, 0x00, 0x92, 0x04, 0x33, 0x00, 0x22, + 0x04, 0x21, 0x20, 0x00, 0xff, 0xf7, 0xeb, 0xfe, 0x05, 0xb0, 0x30, 0xbd, + 0x00, 0x20, 0xfb, 0xe7, 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x8b, 0xb0, + 0x04, 0x93, 0x10, 0xab, 0x1b, 0x88, 0x12, 0x25, 0x05, 0x93, 0x50, 0x4b, + 0x14, 0x00, 0x19, 0x43, 0x0e, 0x23, 0x04, 0xaa, 0x9b, 0x18, 0x19, 0x80, + 0x09, 0xab, 0xad, 0x18, 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x2b, 0x00, + 0x06, 0x00, 0x02, 0xf0, 0x65, 0xfa, 0x00, 0x28, 0x33, 0xdb, 0x09, 0x9b, + 0x2d, 0x88, 0x06, 0x93, 0x68, 0x2c, 0x30, 0xd9, 0x27, 0x00, 0x69, 0x3f, + 0x7c, 0x21, 0x38, 0x00, 0x05, 0xf0, 0x4c, 0xf8, 0x01, 0x30, 0x83, 0xb2, + 0x7c, 0x21, 0x38, 0x00, 0x03, 0x93, 0x05, 0xf0, 0xcb, 0xf8, 0x09, 0x91, + 0x32, 0x6a, 0x05, 0x9b, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, + 0x1b, 0x02, 0x00, 0x22, 0x15, 0x21, 0x30, 0x00, 0xff, 0xf7, 0x49, 0xfe, + 0x00, 0x28, 0x12, 0xdb, 0x06, 0x9b, 0x37, 0x6a, 0x2d, 0x01, 0xed, 0x18, + 0x04, 0xaa, 0x7b, 0x78, 0x39, 0x78, 0xd2, 0x89, 0x01, 0x35, 0x1b, 0x02, + 0xad, 0xb2, 0x0b, 0x43, 0x9a, 0x42, 0x0a, 0xd0, 0x29, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0x5c, 0xfb, 0x2e, 0x48, 0x0b, 0xb0, 0xf0, 0xbd, 0x00, 0x23, + 0x09, 0x94, 0x03, 0x93, 0xd8, 0xe7, 0xfb, 0x78, 0xba, 0x78, 0x1b, 0x02, + 0x13, 0x43, 0x03, 0x9a, 0x93, 0x42, 0x05, 0xd0, 0x29, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0x4a, 0xfb, 0x26, 0x48, 0xec, 0xe7, 0x38, 0x22, 0x3b, 0x79, + 0x93, 0x43, 0xc0, 0x2b, 0x05, 0xd0, 0x29, 0x00, 0x30, 0x00, 0x02, 0xf0, + 0x3f, 0xfb, 0x22, 0x48, 0xe1, 0xe7, 0x03, 0x9b, 0x00, 0x2b, 0x2a, 0xd1, + 0x6b, 0x46, 0x64, 0x00, 0x1b, 0x8a, 0x3c, 0x19, 0xe3, 0x85, 0x80, 0x22, + 0x52, 0x00, 0x00, 0x92, 0x2b, 0x02, 0x01, 0x97, 0x00, 0x22, 0x07, 0x21, + 0x30, 0x00, 0xff, 0xf7, 0x68, 0xfe, 0x00, 0x28, 0xcd, 0xdb, 0x0f, 0x23, + 0x17, 0x4a, 0x2b, 0x40, 0x9b, 0x18, 0x0e, 0x22, 0x04, 0xa9, 0x52, 0x18, + 0x01, 0x92, 0x02, 0x22, 0x2d, 0x09, 0x5b, 0x00, 0x2d, 0x03, 0x00, 0x92, + 0x5b, 0x19, 0x00, 0x22, 0x04, 0x21, 0x30, 0x00, 0xff, 0xf7, 0x53, 0xfe, + 0x00, 0x28, 0xb8, 0xdb, 0x05, 0x99, 0x30, 0x00, 0x02, 0xf0, 0x10, 0xfb, + 0xb3, 0xe7, 0x68, 0x2c, 0x05, 0xd8, 0x64, 0x00, 0x6b, 0x46, 0x1b, 0x8a, + 0x3c, 0x19, 0x23, 0x81, 0xd1, 0xe7, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x05, 0xf0, 0x50, 0xf8, 0x4c, 0x00, 0xf3, 0xe7, 0x00, 0x80, 0xff, 0xff, + 0xbd, 0xd8, 0xff, 0xff, 0xbc, 0xd8, 0xff, 0xff, 0xbb, 0xd8, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x00, 0x24, 0x85, 0xb0, 0x0e, 0x00, + 0x1f, 0x00, 0x11, 0x88, 0x03, 0x93, 0x02, 0x94, 0x01, 0x94, 0x00, 0x94, + 0x23, 0x00, 0x05, 0x00, 0x02, 0xf0, 0x66, 0xfa, 0xa0, 0x42, 0x0a, 0xdb, + 0xfb, 0x21, 0x3a, 0x88, 0x33, 0x02, 0x12, 0x02, 0x00, 0x91, 0x05, 0x33, + 0x05, 0x32, 0x21, 0x00, 0x28, 0x00, 0x01, 0xf0, 0xe3, 0xff, 0x05, 0xb0, + 0xf0, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x93, 0xb0, 0x06, 0x91, 0x01, 0x33, + 0x11, 0x01, 0xcb, 0x18, 0xc4, 0x6c, 0x9b, 0xb2, 0x07, 0x00, 0x05, 0x93, + 0x00, 0x2c, 0x08, 0xd0, 0x10, 0x02, 0xf9, 0x68, 0x04, 0xf0, 0x90, 0xff, + 0x00, 0x23, 0x02, 0x00, 0x19, 0x00, 0x18, 0x00, 0xa0, 0x47, 0x05, 0x9b, + 0x0e, 0xad, 0x1b, 0x02, 0x08, 0x93, 0x05, 0x23, 0x01, 0x95, 0x00, 0x93, + 0x00, 0x22, 0x08, 0x9b, 0x15, 0x21, 0x38, 0x00, 0xff, 0xf7, 0x8f, 0xfd, + 0x04, 0x1e, 0x00, 0xda, 0xd5, 0xe0, 0x06, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0x81, 0xe0, 0x2b, 0x79, 0x7f, 0x2b, 0x00, 0xd9, 0x86, 0xe0, 0x06, 0x9b, + 0x1c, 0x00, 0x1d, 0x00, 0x04, 0x93, 0x06, 0x9b, 0x83, 0x4a, 0x01, 0x3b, + 0x9b, 0xb2, 0x93, 0x42, 0x00, 0xd9, 0x02, 0xe2, 0x81, 0x48, 0x06, 0x9b, + 0x02, 0x00, 0x0e, 0xae, 0x03, 0x43, 0x9b, 0xb2, 0x31, 0x88, 0x07, 0x93, + 0x33, 0x79, 0x0a, 0x43, 0x09, 0x90, 0x07, 0x98, 0x92, 0xb2, 0x82, 0x42, + 0x00, 0xd1, 0xb2, 0xe1, 0x5a, 0xb2, 0x00, 0x2a, 0x51, 0xda, 0x9a, 0x07, + 0x4f, 0xd4, 0x44, 0x22, 0x13, 0x42, 0x4c, 0xd0, 0x04, 0x25, 0x72, 0x88, + 0x1d, 0x40, 0x00, 0xd1, 0xee, 0xe0, 0x12, 0x23, 0x06, 0xa8, 0x1b, 0x18, + 0x0b, 0xad, 0x00, 0x93, 0x38, 0x00, 0x2b, 0x00, 0xff, 0xf7, 0x74, 0xfe, + 0x6f, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x3a, 0xd0, 0x00, 0x28, 0x00, 0xda, + 0x95, 0xe0, 0x2b, 0x88, 0x05, 0x9a, 0x93, 0x42, 0x33, 0xd1, 0x10, 0xad, + 0x2b, 0x00, 0x32, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0x72, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0x87, 0xe0, 0x12, 0x20, 0x06, 0xac, 0x00, 0x19, + 0x00, 0x88, 0x0e, 0xae, 0x2b, 0x88, 0x72, 0x88, 0x31, 0x88, 0x00, 0x90, + 0x38, 0x00, 0xff, 0xf7, 0xb1, 0xfe, 0x60, 0x4b, 0x04, 0x00, 0xc3, 0x18, + 0x02, 0x2b, 0x16, 0xd8, 0x29, 0x88, 0x38, 0x00, 0x02, 0xf0, 0x50, 0xfa, + 0x04, 0x1e, 0x70, 0xdb, 0x31, 0x88, 0x38, 0x00, 0xff, 0xf7, 0x7e, 0xfe, + 0x01, 0x23, 0xfd, 0x6c, 0x04, 0x00, 0x04, 0x93, 0x00, 0x2d, 0x06, 0xd0, + 0x00, 0x23, 0x32, 0x88, 0x18, 0x00, 0x06, 0x21, 0xa8, 0x47, 0x01, 0x23, + 0x04, 0x93, 0x00, 0x2c, 0x5d, 0xdb, 0xfc, 0x6c, 0x00, 0x2c, 0x04, 0xd0, + 0x00, 0x23, 0x05, 0x9a, 0x05, 0x21, 0x18, 0x00, 0xa0, 0x47, 0x05, 0x99, + 0x38, 0x00, 0x02, 0xf0, 0x2f, 0xfa, 0x04, 0x00, 0x92, 0xe1, 0x4b, 0x4b, + 0x06, 0x9a, 0x9a, 0x42, 0x00, 0xd0, 0x82, 0xe0, 0x2b, 0x79, 0xdb, 0x07, + 0x00, 0xd5, 0x7e, 0xe0, 0x04, 0x23, 0x2e, 0x79, 0x29, 0x88, 0x6a, 0x88, + 0x1e, 0x40, 0x4b, 0xd0, 0x06, 0xa8, 0x0e, 0x33, 0x1b, 0x18, 0x0b, 0xae, + 0x00, 0x93, 0x38, 0x00, 0x33, 0x00, 0xff, 0xf7, 0x0f, 0xfe, 0x3d, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x00, 0xd1, 0x6c, 0xe0, 0x00, 0x28, 0x30, 0xdb, + 0x33, 0x88, 0x05, 0x9a, 0x93, 0x42, 0x00, 0xd0, 0x60, 0xe0, 0x10, 0xae, + 0x33, 0x00, 0x2a, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0x0c, 0xff, + 0x04, 0x1e, 0x22, 0xdb, 0x06, 0xa8, 0x40, 0x8a, 0x33, 0x88, 0x6a, 0x88, + 0x29, 0x88, 0x00, 0x90, 0x38, 0x00, 0xff, 0xf7, 0x4f, 0xfe, 0x2f, 0x4b, + 0x04, 0x00, 0xc3, 0x18, 0x02, 0x2b, 0x17, 0xd8, 0x31, 0x88, 0x38, 0x00, + 0x02, 0xf0, 0xee, 0xf9, 0x04, 0x1e, 0x0e, 0xdb, 0x29, 0x88, 0x38, 0x00, + 0xff, 0xf7, 0x1c, 0xfe, 0xfe, 0x6c, 0x04, 0x00, 0x00, 0x2e, 0x04, 0xd0, + 0x00, 0x23, 0x06, 0x21, 0x18, 0x00, 0x2a, 0x88, 0xb0, 0x47, 0x00, 0x2c, + 0x34, 0xda, 0x20, 0x00, 0x13, 0xb0, 0xf0, 0xbd, 0xfe, 0x6c, 0x00, 0x2e, + 0xf7, 0xd0, 0x6b, 0x88, 0x2a, 0x88, 0x02, 0x21, 0x00, 0x20, 0xf1, 0xe7, + 0x1a, 0x4b, 0x00, 0x96, 0x19, 0x43, 0x89, 0xb2, 0x05, 0x9b, 0x38, 0x00, + 0x02, 0xf0, 0xd8, 0xf8, 0x17, 0x4b, 0x04, 0x00, 0x98, 0x42, 0xe6, 0xd1, + 0x29, 0x88, 0x14, 0x4b, 0x00, 0x96, 0x0b, 0x43, 0x99, 0xb2, 0x32, 0x00, + 0x33, 0x00, 0x38, 0x00, 0x02, 0xf0, 0x02, 0xf9, 0x04, 0x1e, 0x11, 0xd1, + 0x10, 0xab, 0x2a, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0xbe, 0xfe, + 0x04, 0x1e, 0xd4, 0xdb, 0xfb, 0x6c, 0x9c, 0x46, 0x00, 0x2b, 0x05, 0xd0, + 0x6b, 0x88, 0x2a, 0x88, 0x03, 0x21, 0x30, 0x00, 0x65, 0x46, 0xa8, 0x47, + 0x01, 0x23, 0x04, 0x93, 0x04, 0xe0, 0x00, 0x23, 0xf8, 0xe6, 0x01, 0x23, + 0x00, 0x24, 0x04, 0x93, 0x1d, 0x00, 0xf6, 0xe6, 0xfd, 0xff, 0x00, 0x00, + 0x00, 0x80, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, + 0xff, 0xff, 0x00, 0x00, 0x16, 0x26, 0x06, 0xab, 0xf6, 0x18, 0x00, 0x96, + 0x2b, 0x00, 0x07, 0x99, 0x38, 0x00, 0x02, 0xf0, 0x99, 0xf8, 0xc1, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x00, 0xd0, 0x75, 0xe0, 0x35, 0x80, 0x0e, 0xae, + 0x31, 0x88, 0x09, 0x9b, 0x0c, 0xad, 0x19, 0x43, 0x72, 0x88, 0x00, 0x23, + 0x89, 0xb2, 0x00, 0x95, 0x38, 0x00, 0x02, 0xf0, 0x87, 0xf8, 0xb8, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x68, 0xd1, 0x00, 0x23, 0x2b, 0x80, 0x2b, 0x88, + 0x00, 0x2b, 0x06, 0xd0, 0x16, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0x00, 0x2b, 0x00, 0xd0, 0x2d, 0xe7, 0x06, 0x9b, 0x06, 0xaa, 0x59, 0x04, + 0x1a, 0x23, 0x9b, 0x18, 0x00, 0x93, 0x00, 0x23, 0x49, 0x0c, 0x1a, 0x00, + 0x38, 0x00, 0x02, 0xf0, 0x6b, 0xf8, 0xaa, 0x4b, 0x04, 0x00, 0x98, 0x42, + 0x4f, 0xd1, 0x16, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x00, 0x22, 0x1a, 0x80, + 0x00, 0x23, 0x31, 0x88, 0x0d, 0xad, 0x49, 0x04, 0x1a, 0x00, 0x49, 0x0c, + 0x00, 0x95, 0x38, 0x00, 0x02, 0xf0, 0x58, 0xf8, 0xa0, 0x4b, 0x04, 0x00, + 0x98, 0x42, 0x3f, 0xd1, 0x00, 0x22, 0x0c, 0xab, 0x1a, 0x80, 0xf8, 0x23, + 0x16, 0x21, 0x10, 0xaa, 0x06, 0xa8, 0x13, 0x71, 0x09, 0x18, 0x73, 0x88, + 0x08, 0x88, 0x53, 0x80, 0x00, 0x28, 0x05, 0xd0, 0x1a, 0x21, 0x06, 0xac, + 0x09, 0x19, 0x09, 0x88, 0x00, 0x29, 0x2e, 0xd0, 0x29, 0x88, 0x00, 0x29, + 0x2b, 0xd0, 0x0c, 0xa9, 0x09, 0x88, 0x06, 0x91, 0x00, 0x29, 0x26, 0xd1, + 0x33, 0x88, 0x09, 0x99, 0x38, 0x00, 0x19, 0x43, 0x1e, 0x23, 0x11, 0x80, + 0x06, 0xa9, 0x5b, 0x18, 0x05, 0x99, 0xff, 0xf7, 0x29, 0xfe, 0xfd, 0x6c, + 0x04, 0x00, 0x00, 0x2d, 0x04, 0xd0, 0x73, 0x88, 0x32, 0x88, 0x03, 0x21, + 0x06, 0x98, 0xa8, 0x47, 0x00, 0x2c, 0x00, 0xda, 0x35, 0xe7, 0x01, 0x23, + 0x04, 0x93, 0xd4, 0xe6, 0x00, 0x28, 0x00, 0xdb, 0x87, 0xe7, 0x2e, 0xe7, + 0x00, 0x28, 0x96, 0xda, 0x2b, 0xe7, 0x00, 0x28, 0xb2, 0xda, 0x28, 0xe7, + 0x00, 0x28, 0xc0, 0xda, 0x25, 0xe7, 0x0c, 0xaa, 0x12, 0x88, 0x00, 0x2a, + 0x03, 0xd0, 0x2a, 0x88, 0x00, 0x2a, 0x00, 0xd1, 0xbf, 0xe6, 0x1a, 0x22, + 0x06, 0xa9, 0x52, 0x18, 0x12, 0x88, 0x00, 0x2a, 0x00, 0xd1, 0xb8, 0xe6, + 0x00, 0x28, 0x00, 0xd0, 0xb5, 0xe6, 0x6a, 0x46, 0xfd, 0x6c, 0x92, 0x8b, + 0x10, 0xac, 0x22, 0x80, 0x00, 0x2d, 0x02, 0xd0, 0x32, 0x88, 0x03, 0x21, + 0xa8, 0x47, 0x1e, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x05, 0x99, 0x22, 0x00, + 0x38, 0x00, 0xff, 0xf7, 0xe9, 0xfd, 0x04, 0x00, 0xc6, 0xe7, 0x69, 0x46, + 0x04, 0x22, 0x18, 0x20, 0x09, 0x5e, 0x1a, 0x40, 0x00, 0x29, 0x44, 0xda, + 0x00, 0x2a, 0x44, 0xd1, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0x94, 0xe6, + 0x9b, 0x07, 0x30, 0xd5, 0x12, 0x23, 0x06, 0xa9, 0x5b, 0x18, 0x0e, 0xae, + 0x72, 0x88, 0x06, 0x99, 0x00, 0x93, 0x38, 0x00, 0x0b, 0xab, 0xff, 0xf7, + 0xbd, 0xfc, 0x5d, 0x4b, 0x04, 0x00, 0x98, 0x42, 0xab, 0xd0, 0x00, 0x28, + 0x00, 0xda, 0xde, 0xe6, 0x01, 0x22, 0x06, 0xab, 0x04, 0x92, 0x9b, 0x8a, + 0x05, 0x9a, 0x93, 0x42, 0x00, 0xd0, 0x78, 0xe6, 0xfc, 0x6c, 0x00, 0x2c, + 0x04, 0xd0, 0x73, 0x88, 0x32, 0x88, 0x03, 0x21, 0x00, 0x20, 0xa0, 0x47, + 0xfd, 0x23, 0x01, 0x26, 0x10, 0xaa, 0x13, 0x70, 0x08, 0x9b, 0x01, 0x92, + 0x04, 0x33, 0x00, 0x96, 0x00, 0x22, 0x07, 0x21, 0x38, 0x00, 0xff, 0xf7, + 0xdc, 0xfb, 0x04, 0x00, 0x04, 0x96, 0x00, 0x2d, 0x00, 0xd0, 0x5e, 0xe6, + 0x00, 0x2c, 0x00, 0xd0, 0xb9, 0xe6, 0x04, 0x9c, 0x47, 0x4b, 0x67, 0x42, + 0x7c, 0x41, 0xe4, 0x18, 0xb3, 0xe6, 0x00, 0x2a, 0xba, 0xd1, 0x1a, 0x26, + 0x06, 0x9b, 0x0e, 0xad, 0x5b, 0x04, 0x5b, 0x0c, 0x09, 0x93, 0x06, 0xab, + 0xf6, 0x18, 0x6a, 0x88, 0x05, 0x9b, 0x00, 0x96, 0x09, 0x99, 0x38, 0x00, + 0x01, 0xf0, 0x8e, 0xff, 0x3b, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x4c, 0xd1, + 0x00, 0x23, 0x33, 0x80, 0x6a, 0x88, 0x0d, 0xad, 0x05, 0x9b, 0x00, 0x95, + 0x07, 0x99, 0x38, 0x00, 0x01, 0xf0, 0x80, 0xff, 0x34, 0x4b, 0x04, 0x00, + 0x98, 0x42, 0x41, 0xd1, 0x00, 0x23, 0x2b, 0x80, 0x1a, 0x23, 0x06, 0xaa, + 0x9b, 0x18, 0x28, 0x88, 0x1d, 0x88, 0xfc, 0x6c, 0x00, 0x2d, 0x3a, 0xd0, + 0x00, 0x28, 0x00, 0xd0, 0x25, 0xe6, 0x00, 0x2c, 0x04, 0xd0, 0x0e, 0xab, + 0x5b, 0x88, 0x06, 0x9a, 0x02, 0x21, 0xa0, 0x47, 0xf8, 0x23, 0x10, 0xaa, + 0x13, 0x71, 0x6b, 0x46, 0x1e, 0x26, 0x9b, 0x8b, 0x00, 0x25, 0x13, 0x80, + 0x0e, 0xab, 0x5b, 0x88, 0x07, 0x99, 0x53, 0x80, 0x06, 0xab, 0xf6, 0x18, + 0x01, 0x23, 0x02, 0x93, 0x2b, 0x00, 0x03, 0x96, 0x01, 0x95, 0x00, 0x95, + 0x38, 0x00, 0x01, 0xf0, 0xc1, 0xff, 0x04, 0x00, 0xa8, 0x42, 0x00, 0xda, + 0x61, 0xe6, 0xfb, 0x21, 0x32, 0x88, 0x08, 0x9b, 0x12, 0x02, 0x00, 0x91, + 0x05, 0x33, 0x05, 0x32, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, 0x3c, 0xfd, + 0x04, 0x00, 0xa8, 0x42, 0x00, 0xdb, 0xf4, 0xe5, 0x51, 0xe6, 0x00, 0x28, + 0xb2, 0xda, 0x4e, 0xe6, 0x00, 0x28, 0xbd, 0xda, 0x4b, 0xe6, 0x00, 0x28, + 0x00, 0xd1, 0xea, 0xe5, 0x0e, 0xab, 0x5b, 0x88, 0x00, 0x2c, 0x03, 0xd0, + 0x06, 0x9a, 0x03, 0x21, 0x28, 0x00, 0xa0, 0x47, 0xfc, 0x23, 0x10, 0xaa, + 0x13, 0x71, 0x6b, 0x46, 0x1e, 0x26, 0x9b, 0x8c, 0x00, 0x25, 0x13, 0x80, + 0x0e, 0xab, 0x5b, 0x88, 0x09, 0x99, 0x53, 0x80, 0x06, 0xab, 0xf6, 0x18, + 0x01, 0x23, 0x03, 0x96, 0x02, 0x93, 0x01, 0x95, 0x00, 0x95, 0x2b, 0x00, + 0xc2, 0xe7, 0xc0, 0x46, 0xee, 0xd8, 0xff, 0xff, 0xa9, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x8b, 0xb0, 0x05, 0x93, 0xc7, 0x6c, 0x43, 0x6a, 0x04, 0x00, + 0x03, 0x91, 0x16, 0x00, 0x11, 0x9d, 0x04, 0x93, 0x00, 0x2f, 0x08, 0xd0, + 0x10, 0x02, 0xe1, 0x68, 0x04, 0xf0, 0xbc, 0xfc, 0x00, 0x23, 0x02, 0x00, + 0x19, 0x00, 0x01, 0x20, 0xb8, 0x47, 0x03, 0x9b, 0x4f, 0x49, 0x50, 0x4a, + 0x5b, 0x18, 0x9b, 0xb2, 0x93, 0x42, 0x00, 0xd9, 0x94, 0xe0, 0x05, 0x22, + 0x05, 0x9b, 0x36, 0x01, 0x01, 0x33, 0xf6, 0x18, 0xb7, 0xb2, 0x08, 0xae, + 0x00, 0x92, 0x3b, 0x02, 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, + 0xff, 0xf7, 0xb1, 0xfa, 0x00, 0x28, 0x16, 0xdb, 0x39, 0x22, 0x33, 0x79, + 0x93, 0x43, 0x72, 0x88, 0x00, 0x2a, 0x12, 0xd1, 0x80, 0x2b, 0x6e, 0xd1, + 0xe5, 0x6c, 0x00, 0x2d, 0x04, 0xd0, 0x03, 0x9b, 0x3a, 0x00, 0x05, 0x21, + 0x01, 0x20, 0xa8, 0x47, 0x39, 0x00, 0x20, 0x00, 0x01, 0xf0, 0xc2, 0xff, + 0x00, 0x28, 0x00, 0xdb, 0x3a, 0x48, 0x05, 0x00, 0x6b, 0xe0, 0xc0, 0x2b, + 0xfa, 0xd0, 0x03, 0x9b, 0x38, 0x4a, 0x5e, 0x04, 0x94, 0x46, 0x00, 0x23, + 0x60, 0x6a, 0x76, 0x0c, 0x61, 0x46, 0xc2, 0x5a, 0x0a, 0x40, 0xb2, 0x42, + 0x12, 0xd1, 0x04, 0x9a, 0xd3, 0x5e, 0x00, 0x2b, 0x58, 0xda, 0x30, 0x4d, + 0x36, 0xe0, 0x02, 0x33, 0x9c, 0x42, 0x4f, 0xd1, 0x2b, 0x68, 0x04, 0x98, + 0x59, 0x00, 0x01, 0x33, 0x0a, 0x52, 0x7f, 0x2b, 0x00, 0xd9, 0x00, 0x23, + 0x2b, 0x60, 0x49, 0xe0, 0x80, 0x22, 0x02, 0x33, 0x52, 0x00, 0x93, 0x42, + 0xe2, 0xd1, 0x0e, 0x23, 0x04, 0xaa, 0x9b, 0x18, 0x00, 0x93, 0x00, 0x23, + 0x03, 0x99, 0x1a, 0x00, 0x20, 0x00, 0x01, 0xf0, 0x9b, 0xfe, 0x00, 0x28, + 0x0a, 0xd0, 0x22, 0x4b, 0x98, 0x42, 0x24, 0xd1, 0x69, 0x46, 0x2b, 0x68, + 0x04, 0x9a, 0x89, 0x89, 0x5b, 0x00, 0x99, 0x52, 0x01, 0x22, 0x04, 0xe0, + 0x2b, 0x68, 0x04, 0x9a, 0x5b, 0x00, 0x9e, 0x52, 0x02, 0x00, 0x2b, 0x68, + 0x01, 0x33, 0x7f, 0x2b, 0x00, 0xd9, 0x00, 0x23, 0x2b, 0x60, 0x18, 0x4d, + 0x00, 0x2a, 0x20, 0xd0, 0xe6, 0x6c, 0x00, 0x2e, 0x04, 0xd0, 0x03, 0x9b, + 0x3a, 0x00, 0x04, 0x21, 0x01, 0x20, 0xb0, 0x47, 0x39, 0x00, 0x20, 0x00, + 0x01, 0xf0, 0x66, 0xff, 0x00, 0x28, 0x12, 0xda, 0xa3, 0xe7, 0x00, 0x22, + 0x90, 0x42, 0xe4, 0xda, 0x9f, 0xe7, 0xc0, 0x2b, 0x9c, 0xd0, 0x03, 0x9b, + 0x09, 0x48, 0x5a, 0x04, 0x63, 0x6a, 0x52, 0x0c, 0x5c, 0x1c, 0xff, 0x34, + 0x19, 0x88, 0x01, 0x40, 0x91, 0x42, 0xa8, 0xd1, 0x03, 0x4d, 0x28, 0x00, + 0x0b, 0xb0, 0xf0, 0xbd, 0x00, 0x80, 0xff, 0xff, 0xfe, 0x7f, 0x00, 0x00, + 0xaa, 0xd8, 0xff, 0xff, 0xff, 0x7f, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xa9, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0xc4, 0x6c, 0x87, 0xb0, 0x06, 0x00, + 0x00, 0x2c, 0x04, 0xd0, 0x00, 0x23, 0x1a, 0x00, 0x19, 0x00, 0x18, 0x00, + 0xa0, 0x47, 0x00, 0x24, 0x14, 0x4b, 0x05, 0x94, 0x01, 0x93, 0x04, 0x94, + 0x23, 0x00, 0x03, 0x94, 0x02, 0x94, 0x00, 0x94, 0x22, 0x00, 0x21, 0x00, + 0x30, 0x00, 0x01, 0xf0, 0x5b, 0xfc, 0x0f, 0x4b, 0x05, 0x00, 0x98, 0x42, + 0x15, 0xd0, 0xa0, 0x42, 0x07, 0xd0, 0xf7, 0x6c, 0xa7, 0x42, 0x04, 0xd0, + 0x02, 0x00, 0x23, 0x00, 0x01, 0x21, 0x20, 0x00, 0xb8, 0x47, 0xf4, 0x6c, + 0x00, 0x2c, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, 0x19, 0x00, 0x52, 0x00, + 0x18, 0x00, 0xa0, 0x47, 0x28, 0x00, 0x07, 0xb0, 0xf0, 0xbd, 0x25, 0x00, + 0xf1, 0xe7, 0xc0, 0x46, 0x41, 0x2c, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0xc4, 0x6c, 0x97, 0xb0, 0x05, 0x00, 0x00, 0x2c, 0x04, 0xd0, + 0x00, 0x23, 0x02, 0x20, 0x1a, 0x00, 0x19, 0x00, 0xa0, 0x47, 0x00, 0x23, + 0x07, 0x93, 0x1c, 0x00, 0xb0, 0xe1, 0x80, 0x22, 0x00, 0x21, 0x52, 0x00, + 0x68, 0x6a, 0x04, 0xf0, 0x74, 0xfc, 0x07, 0x9b, 0x1b, 0x02, 0x0f, 0x93, + 0x00, 0x23, 0x0a, 0x93, 0xee, 0x68, 0x0a, 0x9b, 0x9e, 0x42, 0x09, 0xd8, + 0x00, 0x23, 0x06, 0x93, 0x06, 0x9b, 0x07, 0x9a, 0x5b, 0x00, 0xd3, 0x18, + 0x9b, 0xb2, 0x0a, 0x93, 0x00, 0x23, 0x0a, 0xe2, 0xeb, 0x6c, 0x05, 0x93, + 0x00, 0x2b, 0x13, 0xd0, 0x0a, 0x9b, 0x37, 0x01, 0x58, 0x04, 0x39, 0x00, + 0x04, 0xf0, 0x9e, 0xfb, 0x31, 0x00, 0x04, 0xf0, 0x9b, 0xfb, 0x39, 0x00, + 0x06, 0x00, 0x0f, 0x98, 0x04, 0xf0, 0x96, 0xfb, 0x00, 0x23, 0x32, 0x18, + 0x19, 0x00, 0x02, 0x20, 0x05, 0x9e, 0xb0, 0x47, 0x0a, 0x9b, 0x1b, 0x01, + 0x01, 0x33, 0x9b, 0xb2, 0x06, 0x93, 0x0a, 0x9b, 0x01, 0x33, 0x1b, 0x01, + 0x0e, 0x93, 0x06, 0x9b, 0x0e, 0x9a, 0x93, 0x42, 0x01, 0xdb, 0x00, 0x23, + 0x69, 0xe1, 0x06, 0x9b, 0x00, 0x22, 0x1e, 0x02, 0x12, 0xab, 0x01, 0x93, + 0x05, 0x23, 0x15, 0x21, 0x00, 0x93, 0x28, 0x00, 0x33, 0x00, 0xff, 0xf7, + 0x86, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0xe5, 0xe0, 0x07, 0x9b, 0x06, 0x99, + 0x00, 0x22, 0x8b, 0x42, 0x07, 0xd8, 0xca, 0x0f, 0x07, 0x9b, 0xc6, 0x49, + 0x06, 0x98, 0x5b, 0x18, 0xd9, 0x17, 0x83, 0x42, 0x4a, 0x41, 0x06, 0x9b, + 0x07, 0x99, 0x58, 0x1a, 0x01, 0x21, 0x43, 0x08, 0x05, 0x93, 0x06, 0x9b, + 0x19, 0x40, 0x89, 0x00, 0x00, 0x2a, 0x0f, 0xd0, 0x12, 0xab, 0x1b, 0x79, + 0x5f, 0xb2, 0x00, 0x2f, 0x0a, 0xda, 0x01, 0x20, 0x03, 0x42, 0x07, 0xd1, + 0x6b, 0x6a, 0x05, 0x98, 0x1b, 0x18, 0x01, 0x20, 0x88, 0x40, 0x1f, 0x78, + 0x07, 0x43, 0x1f, 0x70, 0x12, 0xab, 0x1f, 0x79, 0x7b, 0xb2, 0x9c, 0x46, + 0x00, 0x23, 0x60, 0x46, 0x98, 0x42, 0x00, 0xdb, 0x22, 0xe1, 0x45, 0x20, + 0x07, 0x40, 0x40, 0x2f, 0x00, 0xd0, 0x1d, 0xe1, 0x9a, 0x42, 0x08, 0xd0, + 0x6b, 0x6a, 0x05, 0x9a, 0x02, 0x31, 0x98, 0x18, 0x01, 0x23, 0x8b, 0x40, + 0x02, 0x78, 0x13, 0x43, 0x03, 0x70, 0x2b, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x15, 0x21, 0x33, 0x00, 0x28, 0x00, + 0xff, 0xf7, 0x37, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0x96, 0xe0, 0x2b, 0x6a, + 0x05, 0x93, 0x12, 0xab, 0x5b, 0x88, 0x09, 0x93, 0x00, 0x2b, 0x00, 0xd0, + 0x81, 0xe0, 0x05, 0x9b, 0x2e, 0x33, 0x0b, 0x93, 0x69, 0x23, 0x0c, 0x93, + 0x00, 0x23, 0x08, 0x93, 0x08, 0x9b, 0x0b, 0x9a, 0x5b, 0x00, 0xd6, 0x5a, + 0x07, 0x9a, 0x00, 0x23, 0xb2, 0x42, 0x06, 0xd8, 0x13, 0x00, 0x96, 0x4a, + 0xf1, 0x0f, 0x9a, 0x18, 0xd3, 0x17, 0xb2, 0x42, 0x4b, 0x41, 0x94, 0x4a, + 0x94, 0x49, 0xb2, 0x18, 0x92, 0xb2, 0x8a, 0x42, 0x05, 0xd9, 0x00, 0x2b, + 0x00, 0xd1, 0x8b, 0xe0, 0x33, 0x07, 0x00, 0xd0, 0x92, 0xe0, 0x16, 0x27, + 0x09, 0x9b, 0x08, 0x9a, 0x28, 0x00, 0x9e, 0x18, 0x05, 0x9a, 0x05, 0x9b, + 0x51, 0x78, 0x1b, 0x78, 0x09, 0x02, 0x19, 0x43, 0x0c, 0xab, 0xff, 0x18, + 0xb6, 0xb2, 0x49, 0x04, 0x00, 0x23, 0x49, 0x0c, 0x00, 0x97, 0x32, 0x00, + 0x01, 0xf0, 0x2a, 0xfd, 0x85, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x51, 0xd1, + 0x00, 0x23, 0x3b, 0x80, 0x3b, 0x88, 0x00, 0x2b, 0x16, 0xd1, 0xfc, 0x20, + 0x05, 0x99, 0x05, 0x9a, 0x49, 0x78, 0x12, 0x78, 0x09, 0x02, 0x11, 0x43, + 0x14, 0xaa, 0x10, 0x71, 0x01, 0x20, 0x49, 0x04, 0x49, 0x0c, 0x11, 0x80, + 0x56, 0x80, 0x02, 0x90, 0x03, 0x97, 0x01, 0x93, 0x00, 0x93, 0x28, 0x00, + 0x01, 0xf0, 0x7c, 0xfd, 0x04, 0x1e, 0x37, 0xdb, 0x16, 0x23, 0x0c, 0xaa, + 0x05, 0x99, 0x9b, 0x18, 0x05, 0x9a, 0x49, 0x78, 0x12, 0x78, 0x09, 0x02, + 0x11, 0x43, 0x80, 0x22, 0x12, 0x02, 0x11, 0x43, 0x06, 0x9a, 0x1b, 0x88, + 0x28, 0x00, 0x00, 0x92, 0x32, 0x00, 0xff, 0xf7, 0x41, 0xfa, 0x6d, 0x4b, + 0x04, 0x00, 0xc3, 0x18, 0xee, 0x6c, 0x02, 0x2b, 0x28, 0xd8, 0x00, 0x2e, + 0x09, 0xd0, 0x05, 0x9a, 0x05, 0x9b, 0x52, 0x78, 0x1b, 0x78, 0x12, 0x02, + 0x1a, 0x43, 0x06, 0x21, 0x00, 0x23, 0x02, 0x20, 0xb0, 0x47, 0x06, 0x99, + 0x28, 0x00, 0x01, 0xf0, 0xd3, 0xfd, 0x04, 0x00, 0x25, 0xe0, 0x7c, 0x22, + 0x09, 0x9b, 0x0c, 0x92, 0x53, 0x43, 0x13, 0x3b, 0x9b, 0xb2, 0x09, 0x93, + 0x05, 0x9b, 0x08, 0x33, 0x0b, 0x93, 0x77, 0xe7, 0x00, 0x28, 0xad, 0xda, + 0xee, 0x6c, 0x00, 0x2e, 0x00, 0xd1, 0x80, 0xe0, 0x00, 0x23, 0x22, 0x00, + 0x01, 0x21, 0x02, 0x20, 0xb0, 0x47, 0x7a, 0xe0, 0x00, 0x2e, 0x0c, 0xd0, + 0x05, 0x9b, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, 0x13, 0x43, 0x05, 0x9a, + 0x11, 0x78, 0x52, 0x78, 0x12, 0x02, 0x0a, 0x43, 0x02, 0x21, 0x08, 0x00, + 0xb0, 0x47, 0x00, 0x2c, 0xe4, 0xdb, 0x01, 0x23, 0x08, 0x9a, 0x01, 0x32, + 0x08, 0x92, 0x00, 0x2b, 0x4c, 0xd1, 0x0c, 0x99, 0x8a, 0x42, 0x00, 0xd0, + 0x52, 0xe7, 0x47, 0xe0, 0x05, 0x22, 0x14, 0xaf, 0x00, 0x92, 0x33, 0x02, + 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xff, 0xf7, 0x6d, 0xf8, + 0x04, 0x1e, 0xcd, 0xdb, 0x12, 0xab, 0x1a, 0x88, 0x39, 0x88, 0x41, 0x4b, + 0x13, 0x40, 0x99, 0x42, 0x0b, 0xd1, 0x09, 0x9b, 0x08, 0x98, 0x79, 0x88, + 0x1b, 0x18, 0x99, 0x42, 0x05, 0xd1, 0x7a, 0x21, 0x3b, 0x79, 0x8b, 0x43, + 0x84, 0x2b, 0x00, 0xd1, 0x7d, 0xe0, 0x16, 0x27, 0x08, 0x99, 0x09, 0x9b, + 0x52, 0x04, 0x5b, 0x18, 0x9b, 0xb2, 0x0d, 0x93, 0x0c, 0xab, 0xff, 0x18, + 0x51, 0x0c, 0x33, 0x00, 0x00, 0x97, 0x0d, 0x9a, 0x28, 0x00, 0x01, 0xf0, + 0x7d, 0xfc, 0x2f, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x37, 0xd1, 0x00, 0x23, + 0x3b, 0x80, 0x3b, 0x88, 0x12, 0xae, 0x31, 0x88, 0x00, 0x2b, 0x33, 0xd1, + 0xec, 0x6c, 0x00, 0x2c, 0x03, 0xd0, 0x0a, 0x00, 0x02, 0x20, 0x06, 0x21, + 0xa0, 0x47, 0x31, 0x88, 0x28, 0x00, 0xff, 0xf7, 0x8d, 0xf9, 0x04, 0x1e, + 0x92, 0xdb, 0x00, 0x23, 0x06, 0x9a, 0x01, 0x32, 0x92, 0xb2, 0x06, 0x92, + 0x00, 0x2b, 0x00, 0xd1, 0x8f, 0xe6, 0x0a, 0x9a, 0x01, 0x32, 0x92, 0xb2, + 0x0a, 0x92, 0x00, 0x2b, 0x00, 0xd1, 0x59, 0xe6, 0xeb, 0x68, 0x07, 0x9a, + 0x1b, 0x01, 0x9a, 0x42, 0x00, 0xd2, 0x48, 0xe6, 0x00, 0x2c, 0x00, 0xd0, + 0x7a, 0xe7, 0xed, 0x6c, 0x00, 0x2d, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, + 0x19, 0x00, 0x52, 0x00, 0x02, 0x20, 0xa8, 0x47, 0x20, 0x00, 0x17, 0xb0, + 0xf0, 0xbd, 0x00, 0x28, 0xc7, 0xda, 0x6b, 0xe7, 0x06, 0x9a, 0x28, 0x00, + 0x00, 0x92, 0x0d, 0x9a, 0xff, 0xf7, 0x82, 0xf9, 0x0d, 0x4b, 0x04, 0x00, + 0xc3, 0x18, 0xef, 0x6c, 0x02, 0x2b, 0x19, 0xd8, 0x32, 0x88, 0x00, 0x2f, + 0x03, 0xd0, 0x00, 0x23, 0x06, 0x21, 0x02, 0x20, 0xb8, 0x47, 0x12, 0xab, + 0x19, 0x88, 0x28, 0x00, 0xff, 0xf7, 0x4c, 0xf9, 0x43, 0xe7, 0xc0, 0x46, + 0xff, 0x01, 0x00, 0x00, 0xff, 0xdf, 0xff, 0xff, 0xfd, 0xdf, 0x00, 0x00, + 0xee, 0xd8, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, 0xff, 0x7f, 0xff, 0xff, + 0x00, 0x2f, 0x00, 0xd1, 0x5b, 0xe7, 0x02, 0x21, 0x73, 0x88, 0x32, 0x88, + 0x08, 0x00, 0xb8, 0x47, 0x55, 0xe7, 0x01, 0x21, 0x07, 0x9b, 0xf7, 0x1a, + 0x6b, 0x6a, 0x7f, 0x08, 0x0e, 0x40, 0xb6, 0x00, 0xdb, 0x5d, 0x76, 0x18, + 0x33, 0x41, 0x0b, 0x40, 0x16, 0xd0, 0xec, 0x6c, 0x00, 0x2c, 0x03, 0xd0, + 0x00, 0x23, 0x05, 0x31, 0x02, 0x20, 0xa0, 0x47, 0x12, 0xab, 0x19, 0x88, + 0x28, 0x00, 0xff, 0xf7, 0x1d, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0x21, 0xe7, + 0x06, 0x99, 0x28, 0x00, 0x01, 0xf0, 0xe2, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0x1a, 0xe7, 0x01, 0x23, 0x01, 0x21, 0xb1, 0x40, 0x6a, 0x6a, 0xd7, 0x19, + 0x3a, 0x78, 0x0a, 0x43, 0x3a, 0x70, 0x2d, 0xe7, 0x01, 0x23, 0x08, 0x93, + 0x06, 0x9a, 0x6b, 0x6a, 0x9b, 0x5c, 0x08, 0x9a, 0x92, 0x00, 0x13, 0x41, + 0x07, 0x22, 0x1a, 0x40, 0x09, 0x92, 0x01, 0x2a, 0x00, 0xd0, 0x93, 0xe0, + 0x08, 0x9a, 0x0a, 0x9b, 0x12, 0xae, 0x9b, 0x18, 0x05, 0x22, 0x9b, 0xb2, + 0x05, 0x93, 0x00, 0x92, 0x1b, 0x02, 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, + 0x28, 0x00, 0xfe, 0xf7, 0x92, 0xff, 0x04, 0x1e, 0x00, 0xda, 0xf1, 0xe6, + 0x16, 0x27, 0x0c, 0xab, 0xff, 0x18, 0x11, 0xab, 0x72, 0x88, 0x31, 0x88, + 0x28, 0x00, 0x00, 0x93, 0x3b, 0x00, 0xff, 0xf7, 0xa5, 0xf8, 0x04, 0x1e, + 0x61, 0xd1, 0x80, 0x22, 0x3b, 0x88, 0x92, 0x01, 0x93, 0x42, 0x20, 0xd8, + 0x1a, 0x07, 0x1e, 0xd0, 0x05, 0x22, 0x14, 0xaf, 0x00, 0x92, 0x1b, 0x02, + 0x02, 0x00, 0x01, 0x97, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x71, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0xd0, 0xe6, 0x38, 0x4a, 0x33, 0x88, 0x13, 0x40, + 0x3a, 0x88, 0x93, 0x42, 0x04, 0xd1, 0x78, 0x22, 0x3b, 0x79, 0x93, 0x43, + 0x84, 0x2b, 0x45, 0xd0, 0x16, 0x23, 0x0c, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0x05, 0x9a, 0x93, 0x42, 0x4e, 0xd0, 0x11, 0xab, 0x1b, 0x88, 0x12, 0xae, + 0x72, 0x88, 0x31, 0x88, 0x28, 0x00, 0x00, 0x93, 0x05, 0x9b, 0xff, 0xf7, + 0xd1, 0xf8, 0x2b, 0x4b, 0x04, 0x00, 0xc3, 0x18, 0xef, 0x6c, 0x02, 0x2b, + 0x45, 0xd8, 0x00, 0x2f, 0x04, 0xd0, 0x32, 0x88, 0x00, 0x23, 0x06, 0x21, + 0x02, 0x20, 0xb8, 0x47, 0x05, 0x99, 0x28, 0x00, 0x01, 0xf0, 0x68, 0xfc, + 0x04, 0x1e, 0x00, 0xda, 0xa0, 0xe6, 0x31, 0x88, 0x28, 0x00, 0xff, 0xf7, + 0x95, 0xf8, 0x04, 0x00, 0x00, 0x2c, 0x00, 0xda, 0x98, 0xe6, 0x06, 0x9b, + 0x01, 0x33, 0x06, 0x93, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x0d, 0xe7, + 0x06, 0x9b, 0x1a, 0x00, 0x80, 0x23, 0x5b, 0x00, 0x9a, 0x42, 0x00, 0xd0, + 0x66, 0xe5, 0x80, 0x22, 0x92, 0x00, 0x94, 0x46, 0x07, 0x9b, 0x63, 0x44, + 0x9b, 0xb2, 0x07, 0x93, 0xfe, 0xe6, 0x13, 0x4b, 0x98, 0x42, 0x0c, 0xd1, + 0xec, 0x6c, 0x00, 0x2c, 0x04, 0xd0, 0x00, 0x23, 0x05, 0x9a, 0x05, 0x21, + 0x02, 0x20, 0xa0, 0x47, 0x05, 0x99, 0x28, 0x00, 0x01, 0xf0, 0x38, 0xfc, + 0x04, 0x00, 0x00, 0x2c, 0x00, 0xda, 0x6f, 0xe6, 0x08, 0x9b, 0x01, 0x2b, + 0x00, 0xd0, 0x59, 0xe7, 0x00, 0x23, 0x09, 0x93, 0xcf, 0xe7, 0x00, 0x2f, + 0xca, 0xd0, 0x02, 0x21, 0x73, 0x88, 0x32, 0x88, 0x08, 0x00, 0xb8, 0x47, + 0xc4, 0xe7, 0xc0, 0x46, 0xff, 0x7f, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, + 0xee, 0xd8, 0xff, 0xff, 0x80, 0x22, 0xf0, 0xb5, 0x06, 0x00, 0x89, 0xb0, + 0x00, 0x21, 0x52, 0x00, 0x40, 0x6a, 0x04, 0xf0, 0x96, 0xf9, 0x00, 0x21, + 0xf4, 0x6c, 0x07, 0x91, 0x8c, 0x42, 0x03, 0xd0, 0x0b, 0x00, 0x0a, 0x00, + 0x01, 0x20, 0xa0, 0x47, 0x00, 0x24, 0x07, 0xab, 0x03, 0x93, 0x14, 0x4b, + 0x05, 0x94, 0x01, 0x93, 0x04, 0x94, 0x23, 0x00, 0x02, 0x94, 0x00, 0x94, + 0x22, 0x00, 0x21, 0x00, 0x30, 0x00, 0x01, 0xf0, 0x2f, 0xf9, 0x0f, 0x4b, + 0x05, 0x00, 0x98, 0x42, 0x15, 0xd0, 0xa0, 0x42, 0x07, 0xd0, 0xf7, 0x6c, + 0xa7, 0x42, 0x04, 0xd0, 0x01, 0x21, 0x02, 0x00, 0x23, 0x00, 0x08, 0x00, + 0xb8, 0x47, 0xf4, 0x6c, 0x00, 0x2c, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, + 0x19, 0x00, 0x52, 0x00, 0x01, 0x20, 0xa0, 0x47, 0x28, 0x00, 0x09, 0xb0, + 0xf0, 0xbd, 0x25, 0x00, 0xf1, 0xe7, 0xc0, 0x46, 0xe9, 0x31, 0x00, 0x00, + 0xa8, 0xd8, 0xff, 0xff, 0xf8, 0xb5, 0x06, 0x00, 0x0c, 0x00, 0x01, 0xf0, + 0xcf, 0xf9, 0x05, 0x1e, 0x0c, 0xdb, 0x24, 0x01, 0xa4, 0xb2, 0x27, 0x00, + 0x10, 0x37, 0xbf, 0xb2, 0x21, 0x00, 0x01, 0x34, 0x30, 0x00, 0xa4, 0xb2, + 0xfe, 0xf7, 0x96, 0xfe, 0xbc, 0x42, 0xf7, 0xd1, 0x28, 0x00, 0xf8, 0xbd, + 0xf0, 0xb5, 0x05, 0x00, 0x0f, 0x00, 0x00, 0x24, 0xc3, 0x68, 0x87, 0xb0, + 0x03, 0x93, 0x03, 0x6a, 0x02, 0x93, 0xa2, 0xb2, 0x04, 0x92, 0x03, 0x9a, + 0x23, 0x03, 0xa2, 0x42, 0x01, 0xd1, 0x1e, 0x48, 0x35, 0xe0, 0x2a, 0x6a, + 0x14, 0x21, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x28, 0x00, + 0x00, 0x22, 0xfe, 0xf7, 0x84, 0xfe, 0x02, 0x99, 0x18, 0x4e, 0x0b, 0x00, + 0x1e, 0x33, 0x05, 0x93, 0x00, 0x23, 0xb4, 0x46, 0x1a, 0x00, 0x98, 0x42, + 0x0b, 0xd0, 0x01, 0x28, 0x13, 0xd9, 0x01, 0x34, 0x00, 0x28, 0x1c, 0xd1, + 0xdd, 0xe7, 0x08, 0x88, 0x00, 0x28, 0x06, 0xd1, 0x01, 0x32, 0x92, 0xb2, + 0x02, 0x31, 0x05, 0x98, 0x81, 0x42, 0xf6, 0xd1, 0x05, 0xe0, 0x60, 0x45, + 0x03, 0xd1, 0x01, 0x33, 0x9b, 0xb2, 0xbb, 0x42, 0xf4, 0xd9, 0xd1, 0x18, + 0x0f, 0x29, 0x0a, 0xd1, 0xbb, 0x42, 0x08, 0xd8, 0xeb, 0x6b, 0x04, 0x99, + 0x9a, 0x1a, 0xea, 0x63, 0x28, 0x00, 0xff, 0xf7, 0xa3, 0xff, 0x07, 0xb0, + 0xf0, 0xbd, 0x01, 0x34, 0xbd, 0xe7, 0xc0, 0x46, 0xd3, 0xd8, 0xff, 0xff, + 0xff, 0xff, 0x00, 0x00, 0xf7, 0xb5, 0x80, 0x22, 0x04, 0x6a, 0x52, 0x00, + 0x0b, 0x03, 0x00, 0x92, 0x14, 0x21, 0x00, 0x22, 0x01, 0x94, 0x05, 0x00, + 0x26, 0x00, 0xfe, 0xf7, 0x42, 0xfe, 0x00, 0x22, 0x23, 0x00, 0x1e, 0x36, + 0x11, 0x00, 0x0b, 0x4f, 0x90, 0x42, 0x0d, 0xd0, 0xab, 0x6b, 0x9a, 0x1a, + 0xeb, 0x6b, 0xaa, 0x63, 0x59, 0x1a, 0xe9, 0x63, 0xfe, 0xbd, 0x1c, 0x88, + 0xbc, 0x42, 0x02, 0xd0, 0x00, 0x2c, 0x04, 0xd1, 0x01, 0x31, 0x02, 0x33, + 0x9e, 0x42, 0xf6, 0xd1, 0xee, 0xe7, 0x01, 0x32, 0xf9, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xf0, 0xb5, 0x1d, 0x00, 0xc3, 0x68, 0x93, 0xb0, + 0x05, 0x93, 0x03, 0x6a, 0x04, 0x00, 0x0c, 0x93, 0x05, 0x9b, 0x0f, 0x00, + 0x08, 0x92, 0x03, 0x93, 0x29, 0x2b, 0x01, 0xd9, 0x29, 0x23, 0x03, 0x93, + 0x00, 0x26, 0x80, 0x22, 0x08, 0x9b, 0x52, 0x00, 0x1e, 0x60, 0xff, 0x21, + 0x60, 0x6a, 0x04, 0xf0, 0xb4, 0xf8, 0x63, 0x6a, 0x02, 0x96, 0x06, 0x93, + 0x03, 0x9b, 0x06, 0x9a, 0x5b, 0x00, 0xd3, 0x18, 0x03, 0x22, 0x09, 0x93, + 0x03, 0x33, 0x93, 0x43, 0x0a, 0x93, 0x06, 0x9b, 0x0a, 0x9a, 0x3b, 0x60, + 0x6b, 0x42, 0x5d, 0x41, 0x32, 0x23, 0x6d, 0x42, 0x2b, 0x40, 0x0f, 0x93, + 0x03, 0x9b, 0x9b, 0x00, 0x9b, 0x18, 0x0e, 0x93, 0x6a, 0x46, 0x12, 0x89, + 0x02, 0x9b, 0x0d, 0x92, 0x05, 0x99, 0x02, 0x9a, 0x1b, 0x03, 0x8a, 0x42, + 0x01, 0xd1, 0x00, 0x20, 0x4f, 0xe0, 0x22, 0x6a, 0x14, 0x21, 0x01, 0x92, + 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x20, 0x00, 0x00, 0x22, 0xfe, 0xf7, + 0xde, 0xfd, 0x0c, 0x9b, 0x00, 0x25, 0x19, 0x00, 0x2f, 0x00, 0x1e, 0x31, + 0x3a, 0x4e, 0xa8, 0x42, 0x47, 0xd0, 0x01, 0x28, 0x3b, 0xd1, 0x0e, 0x26, + 0x6b, 0x46, 0x0e, 0xaa, 0xb6, 0x18, 0x02, 0x22, 0x1b, 0x89, 0x15, 0x21, + 0x1b, 0x03, 0x00, 0x92, 0xfe, 0x33, 0x01, 0x96, 0x00, 0x22, 0x20, 0x00, + 0xfe, 0xf7, 0xc5, 0xfd, 0x00, 0x28, 0x2a, 0xdb, 0x23, 0x1d, 0xda, 0x8f, + 0x33, 0x88, 0x9a, 0x42, 0x35, 0xd9, 0xd3, 0x1a, 0x05, 0x22, 0x57, 0x43, + 0x0f, 0x9a, 0x9b, 0xb2, 0x53, 0x43, 0x7d, 0x1b, 0xeb, 0x18, 0x07, 0x93, + 0x00, 0x23, 0x06, 0x99, 0x27, 0x4d, 0x03, 0x9a, 0x93, 0x42, 0x0b, 0xda, + 0x0a, 0x9e, 0x9a, 0x00, 0x92, 0x19, 0x0e, 0x88, 0x0b, 0x91, 0xae, 0x42, + 0x22, 0xd1, 0x6b, 0x46, 0x9b, 0x8e, 0x0b, 0x80, 0x07, 0x9b, 0x13, 0x60, + 0x08, 0x9b, 0x08, 0x9a, 0x1b, 0x68, 0x04, 0x93, 0x01, 0x33, 0x13, 0x60, + 0x02, 0x9b, 0x01, 0x33, 0x02, 0x93, 0x00, 0x28, 0xa4, 0xd0, 0x13, 0xb0, + 0xf0, 0xbd, 0x1a, 0x88, 0xb2, 0x42, 0xbe, 0xd0, 0x00, 0x2a, 0x05, 0xd1, + 0x01, 0x37, 0xbf, 0xb2, 0x02, 0x33, 0x99, 0x42, 0xf5, 0xd1, 0xb6, 0xe7, + 0x01, 0x35, 0xad, 0xb2, 0xf8, 0xe7, 0x9b, 0x1a, 0xdb, 0x43, 0xc7, 0xe7, + 0x0b, 0x99, 0x16, 0x68, 0x07, 0x9f, 0x02, 0x31, 0xbe, 0x42, 0x19, 0xda, + 0x03, 0x99, 0x09, 0x9d, 0x02, 0x39, 0x04, 0x91, 0x0e, 0x99, 0x04, 0x9e, + 0x02, 0x3d, 0x0f, 0x1f, 0xb3, 0x42, 0x04, 0xdd, 0x69, 0x46, 0x0b, 0x9b, + 0x89, 0x8e, 0x19, 0x80, 0xca, 0xe7, 0xae, 0x1e, 0x08, 0x39, 0x36, 0x88, + 0x09, 0x68, 0x2e, 0x80, 0x39, 0x60, 0x04, 0x99, 0x01, 0x39, 0x04, 0x91, + 0x39, 0x00, 0xea, 0xe7, 0x01, 0x33, 0xb0, 0xe7, 0xff, 0xff, 0x00, 0x00, + 0xf0, 0xb5, 0x05, 0x00, 0x03, 0x6a, 0x9b, 0xb0, 0x0f, 0x93, 0x43, 0x6a, + 0x0c, 0x00, 0x14, 0x22, 0x00, 0x21, 0x15, 0xa8, 0x0a, 0x93, 0x03, 0xf0, + 0xfc, 0xff, 0x2b, 0x8a, 0xa3, 0x42, 0x06, 0xd1, 0x60, 0x1c, 0xe9, 0x68, + 0x03, 0xf0, 0xc2, 0xff, 0x00, 0x23, 0x29, 0x82, 0x6b, 0x61, 0x23, 0x01, + 0x01, 0x33, 0x9b, 0xb2, 0x11, 0x93, 0x0f, 0x9b, 0x24, 0x03, 0x1b, 0x19, + 0x10, 0x93, 0x00, 0x23, 0x08, 0x93, 0x8f, 0xe1, 0x0c, 0x9a, 0x10, 0x9b, + 0x14, 0x21, 0x9b, 0x1a, 0x0d, 0x93, 0x2b, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x28, 0x00, 0x0d, 0x9b, 0xfe, 0xf7, + 0x30, 0xfd, 0x04, 0x00, 0x00, 0x2c, 0x07, 0xd1, 0x07, 0x9b, 0x0e, 0x9a, + 0x9b, 0x1a, 0x7f, 0x2b, 0x02, 0xdc, 0x07, 0x9b, 0x0e, 0x2b, 0x01, 0xdd, + 0x3b, 0x00, 0x88, 0xe0, 0x07, 0x9b, 0x0c, 0x9a, 0x5b, 0x00, 0xd3, 0x5a, + 0x07, 0x9a, 0x09, 0x93, 0x11, 0x9b, 0x9b, 0x18, 0x9b, 0xb2, 0x15, 0xaa, + 0x08, 0x93, 0x13, 0x78, 0x01, 0x2b, 0x15, 0xd0, 0x00, 0x2b, 0x04, 0xd0, + 0x02, 0x2b, 0x00, 0xd1, 0x8f, 0xe0, 0x23, 0x00, 0x6d, 0xe0, 0x6b, 0x46, + 0x24, 0x21, 0x59, 0x5e, 0x3b, 0x00, 0x00, 0x29, 0x00, 0xdc, 0x66, 0xe0, + 0x6b, 0x46, 0x9b, 0x8c, 0x17, 0x74, 0x53, 0x80, 0x6b, 0x46, 0x1b, 0x8c, + 0x13, 0x81, 0xee, 0xe7, 0x52, 0x88, 0x09, 0x99, 0x3b, 0x00, 0x8a, 0x42, + 0x59, 0xd1, 0x05, 0x22, 0x08, 0x9b, 0x13, 0xae, 0x00, 0x92, 0x1b, 0x02, + 0x22, 0x00, 0x01, 0x96, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0xef, 0xfc, + 0x04, 0x1e, 0x2d, 0xdb, 0x73, 0x88, 0x00, 0x20, 0x68, 0x2b, 0x05, 0xd9, + 0x69, 0x3b, 0x18, 0x00, 0x7c, 0x21, 0x03, 0xf0, 0xd3, 0xfe, 0x01, 0x30, + 0x15, 0xab, 0x9e, 0x88, 0x86, 0x42, 0x3d, 0xd1, 0x13, 0xab, 0x1a, 0x79, + 0x7f, 0x2a, 0x1e, 0xd9, 0x1a, 0x22, 0x0c, 0xa9, 0x52, 0x18, 0x02, 0x92, + 0x08, 0x9a, 0x00, 0x93, 0x01, 0x92, 0x00, 0x22, 0x09, 0x9b, 0x11, 0x00, + 0x28, 0x00, 0x01, 0xf0, 0x25, 0xfa, 0x04, 0x1e, 0x0c, 0xdb, 0x2b, 0x6a, + 0x00, 0x22, 0x01, 0x93, 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x14, 0x21, + 0x0d, 0x9b, 0x28, 0x00, 0xfe, 0xf7, 0xc1, 0xfc, 0x04, 0x1e, 0x0e, 0xda, + 0x20, 0x00, 0x1b, 0xb0, 0xf0, 0xbd, 0x08, 0x99, 0x28, 0x00, 0x01, 0xf0, + 0xdf, 0xf9, 0x04, 0x1e, 0xf6, 0xdb, 0x1a, 0x23, 0x0c, 0xaa, 0x9b, 0x18, + 0x01, 0x22, 0x52, 0x42, 0x1a, 0x80, 0x13, 0xab, 0x58, 0x88, 0x1a, 0x23, + 0x0c, 0xaa, 0x9b, 0x18, 0x1b, 0x88, 0x09, 0x93, 0x00, 0x2e, 0x1c, 0xd1, + 0x17, 0x30, 0x6a, 0x46, 0x0a, 0x9b, 0x92, 0x8c, 0x40, 0x00, 0x1a, 0x52, + 0x3b, 0x00, 0x07, 0x9a, 0x01, 0x32, 0x07, 0x92, 0x00, 0x2b, 0x00, 0xd0, + 0x6a, 0xe7, 0x0b, 0x9a, 0x01, 0x32, 0x0b, 0x92, 0x00, 0x2b, 0x6b, 0xd0, + 0x0e, 0x9b, 0x80, 0x33, 0x0e, 0x93, 0x0c, 0x9b, 0x01, 0x3b, 0xff, 0x3b, + 0x0c, 0x93, 0x00, 0x2c, 0x00, 0xd1, 0x2d, 0xe1, 0xca, 0xe7, 0x68, 0x28, + 0x01, 0xd8, 0x04, 0x30, 0xdf, 0xe7, 0x69, 0x38, 0x7c, 0x21, 0x03, 0xf0, + 0xf7, 0xfe, 0x08, 0x1d, 0xd9, 0xe7, 0x09, 0x9b, 0x98, 0x4a, 0x99, 0x49, + 0x9a, 0x18, 0x92, 0xb2, 0x3b, 0x00, 0x8a, 0x42, 0xd7, 0xd8, 0x05, 0x22, + 0x08, 0x9b, 0x13, 0xae, 0x00, 0x92, 0x1b, 0x02, 0x22, 0x00, 0x01, 0x96, + 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x6d, 0xfc, 0x04, 0x1e, 0xab, 0xdb, + 0x33, 0x79, 0x7f, 0x2b, 0x2b, 0xd9, 0x1a, 0x23, 0x0c, 0xaa, 0x9b, 0x18, + 0x00, 0x22, 0x02, 0x93, 0x08, 0x9b, 0x00, 0x96, 0x01, 0x93, 0x11, 0x00, + 0x09, 0x9b, 0x28, 0x00, 0x01, 0xf0, 0xb2, 0xf9, 0x04, 0x1e, 0x00, 0xda, + 0x98, 0xe7, 0x00, 0x24, 0x0c, 0xab, 0x02, 0x94, 0x5b, 0x8b, 0x13, 0xa9, + 0x01, 0x93, 0x4b, 0x88, 0x03, 0x22, 0x00, 0x93, 0x28, 0x00, 0x09, 0x9b, + 0x01, 0xf0, 0x20, 0xfa, 0x2b, 0x6a, 0x22, 0x00, 0x01, 0x93, 0x80, 0x23, + 0x5b, 0x00, 0x00, 0x93, 0x14, 0x21, 0x0d, 0x9b, 0x28, 0x00, 0xfe, 0xf7, + 0x40, 0xfc, 0x04, 0x00, 0x00, 0x2c, 0x9b, 0xda, 0x7c, 0xe7, 0x08, 0x99, + 0x28, 0x00, 0x01, 0xf0, 0x5f, 0xf9, 0x04, 0x1e, 0xf6, 0xd1, 0x00, 0x21, + 0x08, 0x9b, 0x02, 0x91, 0x01, 0x93, 0x13, 0xab, 0x5b, 0x88, 0x02, 0x22, + 0x00, 0x93, 0x28, 0x00, 0x09, 0x9b, 0x01, 0xf0, 0xff, 0xf9, 0x87, 0xe7, + 0x00, 0x2c, 0x00, 0xd1, 0xcc, 0xe0, 0x65, 0xe7, 0x0b, 0x7c, 0x00, 0x2b, + 0x70, 0xd0, 0x07, 0x9b, 0x05, 0x22, 0xcb, 0x60, 0x01, 0x23, 0x0b, 0x70, + 0x08, 0x9b, 0x13, 0xaf, 0x00, 0x92, 0x1b, 0x02, 0x01, 0x97, 0x32, 0x00, + 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x13, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0x50, 0xe7, 0x78, 0x88, 0x37, 0x00, 0x68, 0x28, 0x05, 0xd9, 0x69, 0x38, + 0x7c, 0x21, 0x03, 0xf0, 0xf7, 0xfd, 0x01, 0x30, 0x87, 0xb2, 0x80, 0x23, + 0x15, 0xae, 0x71, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1a, 0x23, 0x0c, 0xaa, + 0x9b, 0x18, 0xb7, 0x80, 0x3a, 0x00, 0x00, 0x93, 0x28, 0x00, 0x00, 0x23, + 0x01, 0xf0, 0x2c, 0xf8, 0x56, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x0c, 0xd1, + 0x31, 0x89, 0x28, 0x00, 0x01, 0xf0, 0x16, 0xf9, 0x04, 0x1e, 0x00, 0xda, + 0x2c, 0xe7, 0x00, 0x23, 0x33, 0x70, 0x00, 0x2c, 0x00, 0xd0, 0x27, 0xe7, + 0x71, 0xe0, 0x00, 0x28, 0x00, 0xda, 0x23, 0xe7, 0x6a, 0x6a, 0x0c, 0xab, + 0x5b, 0x8b, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x1b, 0x02, + 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0xd6, 0xfb, 0x04, 0x1e, + 0x00, 0xda, 0x13, 0xe7, 0x0a, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x13, 0xd4, + 0x5a, 0xb2, 0x00, 0x2a, 0x12, 0xda, 0x9a, 0x07, 0x12, 0xd4, 0x04, 0x22, + 0x1a, 0x40, 0x11, 0xd1, 0x0a, 0x9b, 0x99, 0x78, 0xdb, 0x78, 0x1b, 0x02, + 0x0b, 0x43, 0xbb, 0x42, 0x0c, 0xd1, 0x0c, 0xab, 0x5b, 0x8b, 0x07, 0x92, + 0xf3, 0x80, 0xd0, 0xe7, 0x39, 0x4c, 0xf9, 0xe6, 0x39, 0x4c, 0xf7, 0xe6, + 0x39, 0x4c, 0xf5, 0xe6, 0x39, 0x4c, 0xf3, 0xe6, 0x39, 0x4c, 0xf1, 0xe6, + 0x02, 0x22, 0x0a, 0x70, 0x07, 0x93, 0x38, 0xe0, 0x80, 0x22, 0x00, 0x26, + 0xcb, 0x68, 0x12, 0x02, 0x07, 0x93, 0x4b, 0x88, 0x0e, 0x70, 0x09, 0x93, + 0x1a, 0x43, 0xcb, 0x88, 0x89, 0x88, 0x68, 0x6a, 0x13, 0xaf, 0xb1, 0x42, + 0x0b, 0xd1, 0x00, 0x90, 0x04, 0x97, 0x03, 0x91, 0x02, 0x91, 0x01, 0x91, + 0x28, 0x00, 0x01, 0xf0, 0x93, 0xfa, 0x04, 0x00, 0xb0, 0x42, 0xa8, 0xda, + 0xd2, 0xe6, 0x01, 0x93, 0x02, 0x97, 0x13, 0x00, 0x00, 0x96, 0x02, 0x00, + 0x31, 0x00, 0x28, 0x00, 0x01, 0xf0, 0xe0, 0xf8, 0x04, 0x1e, 0x00, 0xda, + 0xc6, 0xe6, 0x02, 0x96, 0x3b, 0x88, 0x69, 0x6a, 0x01, 0x93, 0x0a, 0x9b, + 0x28, 0x00, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, 0x13, 0x43, 0x00, 0x93, + 0x32, 0x00, 0x09, 0x9b, 0x01, 0xf0, 0x4c, 0xf9, 0x8b, 0xe7, 0x03, 0x23, + 0x0b, 0x70, 0x15, 0xab, 0x1a, 0x78, 0x00, 0x24, 0x03, 0x2a, 0x00, 0xd1, + 0xae, 0xe6, 0x7f, 0x22, 0x01, 0x27, 0x1c, 0x74, 0x07, 0x9b, 0xdb, 0x17, + 0x13, 0x40, 0x07, 0x9a, 0x9b, 0x18, 0xdb, 0x11, 0x0b, 0x93, 0xdb, 0x01, + 0x0e, 0x93, 0x0b, 0x9b, 0x0f, 0x9a, 0x1b, 0x02, 0xd3, 0x1a, 0x0c, 0x93, + 0x0b, 0x9b, 0x00, 0x2b, 0x00, 0xdc, 0x19, 0xe6, 0x15, 0xa9, 0x0e, 0x78, + 0x01, 0x2e, 0xa7, 0xd0, 0x00, 0x2e, 0x00, 0xd1, 0x2c, 0xe7, 0x02, 0x2e, + 0xd9, 0xd0, 0x00, 0x23, 0x9e, 0xe7, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, + 0xfe, 0x7f, 0x00, 0x00, 0xee, 0xd8, 0xff, 0xff, 0xe4, 0xd8, 0xff, 0xff, + 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, + 0xe3, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0f, 0x26, 0xc3, 0x68, 0x87, 0xb0, + 0x5e, 0x43, 0x83, 0x6b, 0x04, 0x00, 0xf6, 0x1a, 0xc3, 0x6b, 0x1e, 0x3e, + 0xf5, 0x1a, 0x43, 0x6b, 0x0f, 0x00, 0x03, 0x2b, 0x04, 0xd9, 0xfb, 0x23, + 0x6b, 0x43, 0x00, 0x20, 0x8b, 0x42, 0x19, 0xdc, 0x38, 0x00, 0xfb, 0x21, + 0xfa, 0x30, 0x03, 0xf0, 0x13, 0xfd, 0x02, 0x90, 0x86, 0x42, 0x44, 0xdb, + 0x05, 0x23, 0x01, 0x93, 0x6b, 0x1e, 0x2b, 0x43, 0xdb, 0x0f, 0x05, 0xaa, + 0x04, 0xa9, 0x20, 0x00, 0xff, 0xf7, 0xf2, 0xfc, 0x00, 0x28, 0x05, 0xdb, + 0x05, 0x98, 0x00, 0x28, 0x04, 0xd1, 0x02, 0x9b, 0xab, 0x42, 0x32, 0xda, + 0x07, 0xb0, 0xf0, 0xbd, 0x04, 0x9b, 0x01, 0x22, 0x1e, 0x88, 0x23, 0x00, + 0x40, 0x33, 0x1a, 0x70, 0x31, 0x00, 0x20, 0x00, 0x03, 0x93, 0xff, 0xf7, + 0xa1, 0xfd, 0x00, 0x23, 0x03, 0x9a, 0x13, 0x70, 0x98, 0x42, 0xed, 0xdb, + 0x31, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xaa, 0xfc, 0x00, 0x28, 0xe7, 0xdb, + 0x31, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x3e, 0xfc, 0x00, 0x28, 0xe1, 0xdb, + 0x0f, 0x22, 0xe3, 0x68, 0x53, 0x43, 0xa2, 0x6b, 0x9b, 0x1a, 0xe2, 0x6b, + 0x1e, 0x3b, 0x9b, 0x1a, 0x00, 0x2d, 0x01, 0xdc, 0x9d, 0x42, 0x04, 0xd0, + 0x01, 0x9a, 0x01, 0x3a, 0x01, 0x92, 0x00, 0x2a, 0x05, 0xd1, 0xfb, 0x22, + 0x53, 0x43, 0xbb, 0x42, 0xcc, 0xda, 0x05, 0x48, 0xca, 0xe7, 0x62, 0x6b, + 0x02, 0x2a, 0x03, 0xd9, 0xfb, 0x22, 0x5a, 0x43, 0xba, 0x42, 0xf2, 0xda, + 0x1d, 0x00, 0xb1, 0xe7, 0xef, 0xd8, 0xff, 0xff, 0xf7, 0xb5, 0x84, 0x68, + 0x07, 0x00, 0x01, 0x91, 0x15, 0x00, 0x1e, 0x00, 0x63, 0x1c, 0x17, 0xd0, + 0x33, 0x00, 0x94, 0x42, 0x10, 0xd9, 0xa4, 0x1a, 0xb4, 0x42, 0x00, 0xdd, + 0x34, 0x00, 0x23, 0x00, 0x01, 0x9a, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, + 0x47, 0xfd, 0x00, 0x28, 0x07, 0xdb, 0x01, 0x9a, 0x33, 0x1b, 0x12, 0x19, + 0x01, 0x92, 0x2d, 0x19, 0x00, 0x2b, 0x03, 0xdc, 0x30, 0x00, 0xfe, 0xbd, + 0x33, 0x00, 0xf9, 0xe7, 0x01, 0x9a, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, + 0x7d, 0xfa, 0x00, 0x28, 0xf4, 0xda, 0xf4, 0xe7, 0x73, 0xb5, 0x01, 0xaa, + 0x05, 0x00, 0x02, 0xf0, 0x59, 0xfc, 0x04, 0x1e, 0x02, 0xda, 0x28, 0x63, + 0x20, 0x00, 0x76, 0xbd, 0x01, 0x9e, 0xb3, 0x8b, 0x9b, 0x06, 0xf9, 0xd4, + 0x33, 0x6a, 0x00, 0x2b, 0x04, 0xd1, 0x31, 0x00, 0x28, 0x00, 0xfe, 0xf7, + 0x29, 0xfb, 0x30, 0x62, 0x01, 0x98, 0x02, 0x6a, 0x00, 0x2a, 0xed, 0xd0, + 0x8a, 0x21, 0x56, 0x78, 0x49, 0x00, 0x71, 0x43, 0x6c, 0x6c, 0x14, 0x31, + 0x24, 0x69, 0x13, 0x8a, 0x61, 0x18, 0xd2, 0x68, 0xff, 0xf7, 0xb0, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0x28, 0x63, 0x01, 0x9b, 0x28, 0x00, 0x19, 0x6a, + 0xfe, 0xf7, 0x34, 0xfb, 0xd8, 0xe7, 0x00, 0x00, 0xf7, 0xb5, 0x04, 0x00, + 0x1d, 0x00, 0x83, 0x6d, 0x17, 0x00, 0x01, 0x91, 0x60, 0x22, 0x00, 0x21, + 0x00, 0x93, 0x0a, 0x9e, 0x03, 0xf0, 0x11, 0xfd, 0x0c, 0x22, 0x01, 0x99, + 0x20, 0x00, 0x03, 0xf0, 0x03, 0xfd, 0x00, 0x9b, 0x08, 0x9a, 0xa3, 0x65, + 0x80, 0x23, 0x9b, 0x00, 0xe3, 0x60, 0x7b, 0x1c, 0xff, 0x33, 0x67, 0x62, + 0x23, 0x62, 0x00, 0x21, 0x28, 0x00, 0x03, 0xf0, 0xfe, 0xfc, 0x03, 0x22, + 0x2a, 0x40, 0x05, 0xd0, 0x04, 0x23, 0x9b, 0x1a, 0x08, 0x9a, 0xed, 0x18, + 0xd3, 0x1a, 0x08, 0x93, 0xa5, 0x62, 0x30, 0x21, 0x08, 0x98, 0x03, 0xf0, + 0x37, 0xfc, 0x03, 0x22, 0x09, 0x9b, 0xe0, 0x62, 0x1a, 0x40, 0x05, 0xd0, + 0x04, 0x23, 0x9b, 0x1a, 0x09, 0x9a, 0xf6, 0x1a, 0xd2, 0x18, 0x09, 0x92, + 0x03, 0x23, 0x1e, 0x42, 0x00, 0xd0, 0x9e, 0x43, 0x80, 0x22, 0x09, 0x9b, + 0x92, 0x01, 0x63, 0x64, 0x33, 0x00, 0x96, 0x42, 0x00, 0xd9, 0x13, 0x00, + 0xa3, 0x64, 0x20, 0x00, 0xfe, 0xf7, 0x08, 0xfb, 0x07, 0x4b, 0x20, 0x00, + 0xe3, 0x65, 0x00, 0xf0, 0x83, 0xfd, 0x00, 0x28, 0x01, 0xda, 0x20, 0x63, + 0xfe, 0xbd, 0x0b, 0x9b, 0x00, 0x20, 0xe3, 0x64, 0x01, 0x23, 0x54, 0x34, + 0x23, 0x70, 0xf7, 0xe7, 0x15, 0x03, 0x09, 0x20, 0xf8, 0xb5, 0xc2, 0x6d, + 0x10, 0x4b, 0x04, 0x00, 0x9a, 0x42, 0x0c, 0xd1, 0x07, 0x00, 0x54, 0x37, + 0x3b, 0x78, 0x00, 0x2b, 0x07, 0xd0, 0x00, 0x26, 0x83, 0x6a, 0x1d, 0x1d, + 0xe3, 0x6a, 0xb3, 0x42, 0x02, 0xd8, 0x00, 0x23, 0x3b, 0x70, 0xf8, 0xbd, + 0x00, 0x23, 0xe9, 0x5e, 0x00, 0x29, 0x07, 0xd0, 0x20, 0x00, 0xff, 0xf7, + 0x5b, 0xff, 0x00, 0x23, 0xe9, 0x5e, 0x20, 0x00, 0x02, 0xf0, 0x98, 0xfb, + 0x01, 0x36, 0x30, 0x35, 0xea, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, + 0x00, 0x6b, 0x70, 0x47, 0x00, 0x23, 0x03, 0x63, 0x70, 0x47, 0x00, 0x00, + 0xf0, 0xb5, 0x87, 0xb0, 0x17, 0x00, 0x03, 0x93, 0xc2, 0x6d, 0x3f, 0x4b, + 0x05, 0x00, 0x0e, 0x00, 0x9a, 0x42, 0x04, 0xd0, 0x3d, 0x4c, 0x2c, 0x63, + 0x20, 0x00, 0x07, 0xb0, 0xf0, 0xbd, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, + 0x00, 0x2b, 0x01, 0xd1, 0x39, 0x4c, 0xf4, 0xe7, 0x08, 0x00, 0x03, 0xf0, + 0x90, 0xfc, 0x1f, 0x28, 0x01, 0xd9, 0x37, 0x4c, 0xed, 0xe7, 0x32, 0x00, + 0x05, 0xa9, 0x28, 0x00, 0x02, 0xf0, 0xf8, 0xfa, 0x00, 0x28, 0x02, 0xda, + 0x28, 0x63, 0x04, 0xb2, 0xe4, 0xe7, 0x04, 0xaa, 0x31, 0x00, 0x28, 0x00, + 0x01, 0xf0, 0xb2, 0xfe, 0x04, 0x00, 0x7b, 0x07, 0x34, 0xd4, 0x00, 0x28, + 0x24, 0xda, 0x05, 0x9b, 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, + 0x55, 0xfb, 0x2c, 0x63, 0x24, 0xb2, 0xd1, 0xe7, 0x00, 0x2c, 0xf4, 0xdb, + 0x02, 0xab, 0x19, 0x89, 0x03, 0x9b, 0x05, 0x9a, 0x00, 0x93, 0x28, 0x00, + 0x3b, 0x00, 0x01, 0xf0, 0x27, 0xf9, 0x04, 0x1e, 0xe9, 0xdb, 0xbb, 0x07, + 0x06, 0xd5, 0x00, 0x22, 0x05, 0x98, 0x11, 0x00, 0x01, 0xf0, 0xbe, 0xfe, + 0x04, 0x1e, 0xe0, 0xdb, 0x00, 0x22, 0x05, 0x9b, 0x9a, 0x61, 0x04, 0x24, + 0x1c, 0x5f, 0xb5, 0xe7, 0x00, 0x28, 0xe3, 0xd1, 0x44, 0x23, 0x3b, 0x40, + 0x44, 0x2b, 0xdf, 0xd1, 0x05, 0x9b, 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, + 0x02, 0xf0, 0x2a, 0xfb, 0x14, 0x4c, 0xa6, 0xe7, 0x00, 0x28, 0xf1, 0xd0, + 0x13, 0x4b, 0x9c, 0x42, 0xd0, 0xd1, 0x0a, 0x23, 0x02, 0xa9, 0x5b, 0x18, + 0x00, 0x22, 0x19, 0x00, 0x28, 0x00, 0x02, 0xf0, 0xfb, 0xf9, 0x04, 0x1e, + 0xbd, 0xdb, 0x02, 0xab, 0x59, 0x89, 0x04, 0xab, 0x01, 0x93, 0x01, 0x23, + 0x32, 0x00, 0x00, 0x93, 0x28, 0x00, 0x00, 0x23, 0x00, 0xf0, 0xf2, 0xff, + 0x04, 0x1e, 0xb0, 0xdb, 0x02, 0x23, 0x9f, 0x43, 0xb8, 0xe7, 0xc0, 0x46, + 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, 0xf0, 0xd8, 0xff, 0xff, + 0xcc, 0xd8, 0xff, 0xff, 0xd2, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xf7, 0xb5, 0x16, 0x00, 0x1c, 0x00, 0xc2, 0x6d, 0x29, 0x4b, 0x05, 0x00, + 0x0f, 0x00, 0x9a, 0x42, 0x03, 0xd0, 0x28, 0x4c, 0x2c, 0x63, 0x20, 0x00, + 0xfe, 0xbd, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, + 0x24, 0x4c, 0xf5, 0xe7, 0x01, 0xaa, 0x02, 0xf0, 0x01, 0xfb, 0x00, 0x28, + 0x05, 0xda, 0x04, 0x00, 0x28, 0x63, 0x21, 0x4b, 0x9c, 0x42, 0x0d, 0xd0, + 0xeb, 0xe7, 0x01, 0x9b, 0x9a, 0x8b, 0x12, 0x07, 0x01, 0xd4, 0x1e, 0x4c, + 0xe4, 0xe7, 0x9b, 0x68, 0x01, 0x33, 0x05, 0xd1, 0x00, 0x2c, 0x03, 0xdd, + 0x19, 0x4b, 0x2b, 0x63, 0x00, 0x24, 0xdc, 0xe7, 0x39, 0x00, 0x28, 0x00, + 0xff, 0xf7, 0x88, 0xfe, 0x01, 0x98, 0x81, 0x69, 0x83, 0x68, 0x0a, 0x19, + 0x9a, 0x42, 0x14, 0xd3, 0x5c, 0x1a, 0x00, 0x2c, 0xee, 0xdd, 0x33, 0x00, + 0x22, 0x00, 0x02, 0xf0, 0xa5, 0xf8, 0x0f, 0x4b, 0x98, 0x42, 0x06, 0xd1, + 0x20, 0x00, 0x01, 0x9a, 0x93, 0x69, 0x1b, 0x19, 0x93, 0x61, 0x04, 0x00, + 0xc1, 0xe7, 0x00, 0x28, 0x07, 0xda, 0x28, 0x63, 0xf9, 0xe7, 0x33, 0x00, + 0x22, 0x00, 0x02, 0xf0, 0x93, 0xf8, 0x00, 0x28, 0xc5, 0xdb, 0x01, 0x9a, + 0x93, 0x69, 0x1b, 0x19, 0x93, 0x61, 0xc2, 0xe7, 0x15, 0x03, 0x09, 0x20, + 0xd8, 0xd8, 0xff, 0xff, 0xf0, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xda, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x15, 0x00, 0x1e, 0x00, 0xc2, 0x6d, + 0x2d, 0x4b, 0x85, 0xb0, 0x04, 0x00, 0x0f, 0x00, 0x9a, 0x42, 0x03, 0xd0, + 0x2b, 0x48, 0x20, 0x63, 0x05, 0xb0, 0xf0, 0xbd, 0x03, 0x00, 0x54, 0x33, + 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x28, 0x48, 0xf5, 0xe7, 0x03, 0xaa, + 0x02, 0xf0, 0x9e, 0xfa, 0x00, 0x28, 0xf0, 0xdb, 0x39, 0x00, 0x20, 0x00, + 0xff, 0xf7, 0x3a, 0xfe, 0x03, 0x9f, 0xbb, 0x68, 0x5a, 0x1c, 0x00, 0xd1, + 0x00, 0x23, 0x01, 0x2e, 0x05, 0xd0, 0x02, 0x2e, 0x06, 0xd0, 0x00, 0x2d, + 0x06, 0xda, 0x1e, 0x48, 0xdf, 0xe7, 0xba, 0x69, 0xad, 0x18, 0xf8, 0xe7, + 0xed, 0x18, 0xf6, 0xe7, 0x9d, 0x42, 0x02, 0xdd, 0xbb, 0x61, 0x1a, 0x48, + 0xd5, 0xe7, 0x00, 0x26, 0xb5, 0x42, 0x0d, 0xdd, 0x68, 0x1e, 0xfb, 0x21, + 0x03, 0xf0, 0xb0, 0xfa, 0x83, 0xb2, 0x68, 0x2b, 0x06, 0xd9, 0x18, 0x00, + 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0xa8, 0xfa, 0x01, 0x30, 0x86, 0xb2, + 0x3b, 0x8a, 0xb3, 0x42, 0x11, 0xd0, 0xf9, 0x88, 0x80, 0x23, 0x0a, 0x27, + 0x1b, 0x02, 0x6f, 0x44, 0x19, 0x43, 0x00, 0x97, 0x00, 0x23, 0x32, 0x00, + 0x20, 0x00, 0x00, 0xf0, 0xdd, 0xfc, 0x00, 0x28, 0xb3, 0xdb, 0x03, 0x9b, + 0x3a, 0x88, 0x1e, 0x82, 0xda, 0x81, 0x03, 0x9b, 0x28, 0x00, 0x9d, 0x61, + 0xac, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xc8, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x2a, 0x4b, 0xc2, 0x6d, 0x85, 0xb0, 0x05, 0x00, 0x0f, 0x00, + 0x9a, 0x42, 0x02, 0xd0, 0x27, 0x4c, 0x2c, 0x63, 0x3e, 0xe0, 0x03, 0x00, + 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x24, 0x4c, 0xf6, 0xe7, + 0x08, 0x00, 0x03, 0xf0, 0x38, 0xfb, 0x1f, 0x28, 0x01, 0xd9, 0x22, 0x4c, + 0xef, 0xe7, 0x00, 0x22, 0x03, 0xa9, 0x28, 0x00, 0x02, 0xf0, 0xa0, 0xf9, + 0x04, 0x1e, 0xe8, 0xdb, 0x0a, 0x26, 0x6e, 0x44, 0x32, 0x00, 0x39, 0x00, + 0x28, 0x00, 0x01, 0xf0, 0x5b, 0xfd, 0x04, 0x1e, 0x07, 0xd0, 0x03, 0x9b, + 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0x01, 0xfa, 0x00, 0x2c, + 0xd7, 0xdb, 0x00, 0x23, 0x31, 0x88, 0x03, 0x9a, 0x00, 0x93, 0x28, 0x00, + 0x00, 0xf0, 0xd8, 0xff, 0x04, 0x1e, 0x07, 0xd0, 0x03, 0x9b, 0x28, 0x00, + 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0xf0, 0xf9, 0x00, 0x2c, 0xc6, 0xdb, + 0x01, 0x22, 0x00, 0x21, 0x03, 0x98, 0x01, 0xf0, 0x69, 0xfd, 0x04, 0x1e, + 0x03, 0xd1, 0x00, 0x24, 0x20, 0x00, 0x05, 0xb0, 0xf0, 0xbd, 0x03, 0x9b, + 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0xdd, 0xf9, 0x00, 0x2c, + 0xb3, 0xdb, 0xf2, 0xe7, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xcc, 0xd8, 0xff, 0xff, 0x0d, 0x4b, 0xc2, 0x6d, + 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x9a, 0x42, 0x02, 0xd0, 0x0b, 0x48, + 0x20, 0x63, 0x10, 0xe0, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, + 0x01, 0xd1, 0x08, 0x48, 0xf6, 0xe7, 0xff, 0xf7, 0x7d, 0xfd, 0x00, 0x28, + 0xf2, 0xdb, 0x29, 0x00, 0x20, 0x00, 0x02, 0xf0, 0xb9, 0xf9, 0x00, 0x28, + 0xec, 0xdb, 0x70, 0xbd, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0x0e, 0x4b, 0xc2, 0x6d, 0x10, 0xb5, 0x04, 0x00, + 0x9a, 0x42, 0x02, 0xd0, 0x0c, 0x48, 0x20, 0x63, 0x10, 0xbd, 0x03, 0x00, + 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x09, 0x48, 0xf6, 0xe7, + 0x00, 0x21, 0xfe, 0xf7, 0xe5, 0xfd, 0x20, 0x00, 0xff, 0xf7, 0x06, 0xf9, + 0x20, 0x00, 0xfe, 0xf7, 0x19, 0xfe, 0x20, 0x00, 0x00, 0xf0, 0x52, 0xfb, + 0xea, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x12, 0x01, 0x5c, 0x1c, 0x14, 0x19, + 0x05, 0x22, 0x85, 0xb0, 0xa4, 0xb2, 0x02, 0xad, 0x0f, 0x00, 0x00, 0x92, + 0x23, 0x02, 0x01, 0x95, 0x10, 0x32, 0x00, 0x21, 0x0a, 0x9e, 0xfd, 0xf7, + 0xde, 0xff, 0x00, 0x28, 0x1d, 0xdb, 0x2b, 0x88, 0xbb, 0x42, 0x1c, 0xd1, + 0x0b, 0x9a, 0x69, 0x88, 0x12, 0x88, 0x8a, 0x42, 0x17, 0xd1, 0x29, 0x79, + 0x7c, 0x20, 0x0d, 0x00, 0x85, 0x43, 0x80, 0x2d, 0x11, 0xd1, 0x1b, 0xb2, + 0x00, 0x2b, 0x03, 0xda, 0x4b, 0x06, 0x01, 0xd4, 0x00, 0x2a, 0x0a, 0xd0, + 0x30, 0x1e, 0x06, 0xd0, 0x30, 0x88, 0x00, 0x1b, 0x44, 0x42, 0x60, 0x41, + 0x03, 0x4c, 0x40, 0x42, 0x20, 0x40, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x48, + 0xfb, 0xe7, 0xc0, 0x46, 0xaa, 0xd8, 0xff, 0xff, 0x7f, 0xb5, 0x1d, 0x00, + 0x1b, 0x4b, 0x0c, 0x00, 0x9a, 0x42, 0x24, 0xd0, 0x13, 0x07, 0x25, 0xd0, + 0x80, 0x23, 0x9b, 0x01, 0x9a, 0x42, 0x23, 0xd8, 0x13, 0x02, 0x04, 0x21, + 0x62, 0x5e, 0x05, 0x21, 0x02, 0xae, 0x00, 0x91, 0x01, 0x96, 0x11, 0x31, + 0xfd, 0xf7, 0xa1, 0xff, 0x00, 0x28, 0x13, 0xdb, 0x33, 0x79, 0xda, 0x07, + 0x16, 0xd4, 0x5a, 0xb2, 0x00, 0x2a, 0x15, 0xda, 0x9a, 0x07, 0x15, 0xd4, + 0x5b, 0x07, 0x15, 0xd4, 0x06, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x11, 0xda, + 0x73, 0x88, 0xab, 0x42, 0x02, 0xd0, 0x09, 0x48, 0x00, 0xe0, 0x09, 0x48, + 0x04, 0xb0, 0x70, 0xbd, 0x08, 0x48, 0xfb, 0xe7, 0x08, 0x48, 0xf9, 0xe7, + 0x08, 0x48, 0xf7, 0xe7, 0x08, 0x48, 0xf5, 0xe7, 0x08, 0x48, 0xf3, 0xe7, + 0x08, 0x48, 0xf1, 0xe7, 0xff, 0xff, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, + 0xde, 0xd8, 0xff, 0xff, 0xdd, 0xd8, 0xff, 0xff, 0xdc, 0xd8, 0xff, 0xff, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0x12, 0x01, 0x30, 0xb5, 0x01, 0x33, 0xd3, 0x18, + 0x13, 0x4a, 0x8f, 0xb0, 0x89, 0x18, 0x13, 0x4a, 0x89, 0xb2, 0x9b, 0xb2, + 0x91, 0x42, 0x1b, 0xd8, 0x2e, 0x22, 0x02, 0xac, 0x00, 0x92, 0x1b, 0x02, + 0x01, 0x94, 0x00, 0x22, 0x15, 0x21, 0xfd, 0xf7, 0x56, 0xff, 0x00, 0x28, + 0x11, 0xdb, 0x65, 0x88, 0x00, 0x2d, 0x0d, 0xd1, 0x3d, 0x22, 0x23, 0x79, + 0x93, 0x43, 0xc0, 0x2b, 0x08, 0xd1, 0x15, 0x21, 0x12, 0x98, 0x69, 0x44, + 0x03, 0xf0, 0xf7, 0xf9, 0x03, 0x00, 0x28, 0x00, 0x00, 0x2b, 0x00, 0xd0, + 0x03, 0x48, 0x0f, 0xb0, 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, + 0xfe, 0x7f, 0x00, 0x00, 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x05, 0x00, + 0x0c, 0x00, 0x21, 0x48, 0x01, 0x39, 0x89, 0xb2, 0x8f, 0xb0, 0x81, 0x42, + 0x01, 0xd9, 0x1f, 0x48, 0x27, 0xe0, 0x15, 0x99, 0x0e, 0x88, 0x14, 0x99, + 0x00, 0x29, 0x24, 0xd0, 0x21, 0xb2, 0x00, 0x29, 0x21, 0xda, 0x12, 0x01, + 0x01, 0x33, 0xd3, 0x18, 0x2e, 0x22, 0x9b, 0xb2, 0x02, 0xaf, 0x00, 0x92, + 0x1b, 0x02, 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xfd, 0xf7, + 0x18, 0xff, 0x00, 0x28, 0x0f, 0xdb, 0x7b, 0x88, 0x00, 0x2b, 0x0e, 0xd1, + 0x3d, 0x22, 0x3b, 0x79, 0x93, 0x43, 0xc0, 0x2b, 0x09, 0xd1, 0x15, 0x21, + 0x14, 0x98, 0x69, 0x44, 0x03, 0xf0, 0xb9, 0xf9, 0x00, 0x28, 0x02, 0xd1, + 0x0b, 0x48, 0x0f, 0xb0, 0xf0, 0xbd, 0x64, 0x04, 0x64, 0x0c, 0xa4, 0x1b, + 0xe3, 0x10, 0xff, 0x2b, 0xcd, 0xd8, 0x6a, 0x6a, 0xd2, 0x18, 0x07, 0x23, + 0x1c, 0x40, 0x06, 0x3b, 0xa3, 0x40, 0x11, 0x78, 0x0b, 0x43, 0x13, 0x70, + 0xc3, 0xe7, 0xc0, 0x46, 0xfd, 0xff, 0x00, 0x00, 0xaa, 0xd8, 0xff, 0xff, + 0xd9, 0xd8, 0xff, 0xff, 0x09, 0x4a, 0x91, 0x42, 0x06, 0xd1, 0x00, 0x2b, + 0x02, 0xd1, 0x43, 0x6b, 0x01, 0x33, 0x43, 0x63, 0x06, 0x48, 0x70, 0x47, + 0x00, 0x29, 0x03, 0xd1, 0xc3, 0x6b, 0x01, 0x33, 0xc3, 0x63, 0xf7, 0xe7, + 0x83, 0x6b, 0x01, 0x33, 0x83, 0x63, 0xf3, 0xe7, 0xff, 0xff, 0x00, 0x00, + 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x85, 0xb0, 0x01, 0x91, 0x02, 0x92, + 0x07, 0x89, 0x06, 0x00, 0x00, 0x25, 0x68, 0x2f, 0x06, 0xd9, 0x38, 0x00, + 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0xb6, 0xf8, 0x01, 0x30, 0x85, 0xb2, + 0x74, 0x89, 0x00, 0x20, 0x68, 0x2c, 0x06, 0xd9, 0x20, 0x00, 0x7c, 0x21, + 0x69, 0x38, 0x03, 0xf0, 0xab, 0xf8, 0x01, 0x30, 0x80, 0xb2, 0x01, 0x9b, + 0x9d, 0x42, 0x1c, 0xd8, 0x83, 0x42, 0x1a, 0xd8, 0x00, 0x2b, 0x1a, 0xd0, + 0x7c, 0x23, 0x01, 0x9a, 0x5a, 0x43, 0x13, 0x3a, 0x92, 0xb2, 0x9b, 0x18, + 0x01, 0x34, 0x9b, 0xb2, 0xa3, 0x42, 0x00, 0xdd, 0x23, 0x00, 0x9b, 0xb2, + 0x03, 0x93, 0x3c, 0x1c, 0x97, 0x42, 0x00, 0xd2, 0x14, 0x1c, 0xa4, 0xb2, + 0x25, 0x1d, 0x14, 0x4f, 0x6d, 0x00, 0x03, 0x9a, 0xa3, 0xb2, 0x9a, 0x42, + 0x04, 0xd8, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x9a, 0x69, 0x23, 0xe6, 0xe7, + 0x01, 0x9a, 0x00, 0x2a, 0x0c, 0xd1, 0x02, 0x9b, 0x5b, 0x19, 0xda, 0x8c, + 0x02, 0x35, 0xba, 0x42, 0xf1, 0xd0, 0x33, 0x89, 0x31, 0x68, 0xe3, 0x1a, + 0x5b, 0x00, 0x5a, 0x52, 0x01, 0x34, 0xe6, 0xe7, 0x29, 0x00, 0x68, 0x2b, + 0x06, 0xd9, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0xf2, 0xf8, + 0x04, 0x31, 0x49, 0x00, 0x02, 0x9b, 0x5a, 0x5a, 0xe8, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0x01, 0x00, 0x10, 0xb5, 0x21, 0x24, 0x03, 0x00, + 0x05, 0x48, 0x20, 0x31, 0x1a, 0x78, 0x00, 0x2a, 0x02, 0xd0, 0x01, 0x33, + 0x8b, 0x42, 0x00, 0xd1, 0x10, 0xbd, 0x60, 0x43, 0x50, 0x40, 0xf5, 0xe7, + 0x05, 0x15, 0x00, 0x00, 0x30, 0xb5, 0x1c, 0x00, 0x19, 0x4b, 0x85, 0xb0, + 0x9a, 0x42, 0x20, 0xd0, 0x13, 0x07, 0x21, 0xd0, 0x80, 0x23, 0x9b, 0x01, + 0x9a, 0x42, 0x1f, 0xd8, 0x13, 0x02, 0x00, 0x22, 0x8a, 0x5e, 0x05, 0x21, + 0x02, 0xad, 0x00, 0x91, 0x01, 0x95, 0x12, 0x31, 0xfd, 0xf7, 0x4d, 0xfe, + 0x00, 0x28, 0x0f, 0xdb, 0x2b, 0x79, 0xda, 0x07, 0x12, 0xd4, 0x5a, 0xb2, + 0x00, 0x2a, 0x11, 0xda, 0x9a, 0x07, 0x11, 0xd4, 0x5b, 0x07, 0x11, 0xd5, + 0x6b, 0x88, 0xa3, 0x42, 0x02, 0xd0, 0x09, 0x48, 0x00, 0xe0, 0x09, 0x48, + 0x05, 0xb0, 0x30, 0xbd, 0x08, 0x48, 0xfb, 0xe7, 0x08, 0x48, 0xf9, 0xe7, + 0x08, 0x48, 0xf7, 0xe7, 0x08, 0x48, 0xf5, 0xe7, 0x08, 0x48, 0xf3, 0xe7, + 0x08, 0x48, 0xf1, 0xe7, 0xff, 0xff, 0x00, 0x00, 0xe2, 0xd8, 0xff, 0xff, + 0xe1, 0xd8, 0xff, 0xff, 0xe0, 0xd8, 0xff, 0xff, 0xdf, 0xd8, 0xff, 0xff, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xe5, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0c, 0x00, 0x1f, 0x49, 0x06, 0x00, + 0x61, 0x18, 0x1f, 0x48, 0x8f, 0xb0, 0x89, 0xb2, 0x14, 0x9d, 0x81, 0x42, + 0x33, 0xd8, 0x01, 0x33, 0x12, 0x03, 0x1b, 0x02, 0x9b, 0x18, 0x2e, 0x22, + 0x02, 0xaf, 0x00, 0x92, 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x30, 0x00, + 0xfd, 0xf7, 0x03, 0xfe, 0x00, 0x28, 0x24, 0xd1, 0x7b, 0x88, 0x00, 0x2b, + 0x21, 0xd1, 0x79, 0x22, 0x3b, 0x79, 0x93, 0x43, 0x80, 0x2b, 0x1c, 0xd1, + 0xa8, 0x68, 0x00, 0x28, 0x08, 0xd0, 0x15, 0x21, 0x69, 0x44, 0x03, 0xf0, + 0xa2, 0xf8, 0x00, 0x28, 0x02, 0xd1, 0x0d, 0x48, 0x0f, 0xb0, 0xf0, 0xbd, + 0x28, 0x88, 0x61, 0x04, 0x49, 0x0c, 0x81, 0x42, 0x0b, 0xd3, 0x6b, 0x88, + 0x8b, 0x42, 0x08, 0xd3, 0x08, 0x1a, 0x69, 0x68, 0x02, 0xf0, 0xd0, 0xff, + 0x73, 0x6a, 0x18, 0x18, 0x03, 0x78, 0x01, 0x33, 0x03, 0x70, 0x04, 0x48, + 0xea, 0xe7, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, 0xfe, 0x7f, 0x00, 0x00, + 0xd9, 0xd8, 0xff, 0xff, 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x15, 0x00, + 0x1e, 0x00, 0x95, 0xb0, 0x1a, 0x9f, 0x02, 0x90, 0x03, 0x91, 0x00, 0x2f, + 0x02, 0xd1, 0x38, 0x00, 0x15, 0xb0, 0xf0, 0xbd, 0x3c, 0x00, 0x40, 0x2f, + 0x00, 0xd9, 0x40, 0x24, 0x04, 0xab, 0x01, 0x93, 0x00, 0x94, 0x33, 0x00, + 0x03, 0x9a, 0x0b, 0x21, 0x02, 0x98, 0xfd, 0xf7, 0xb8, 0xfd, 0x00, 0x28, + 0xee, 0xdb, 0x04, 0xab, 0x01, 0x93, 0x00, 0x94, 0x2b, 0x00, 0x03, 0x9a, + 0x0f, 0x21, 0x02, 0x98, 0xfd, 0xf7, 0x11, 0xfe, 0x00, 0x28, 0xe3, 0xdb, + 0x3f, 0x1b, 0x36, 0x19, 0x2d, 0x19, 0xdc, 0xe7, 0xf0, 0xb5, 0x14, 0x00, + 0x0f, 0x22, 0x8d, 0xb0, 0x06, 0x93, 0x12, 0xab, 0x1b, 0x88, 0x06, 0x00, + 0x0b, 0x93, 0xc3, 0x68, 0x0f, 0x00, 0x5a, 0x43, 0x07, 0x92, 0x02, 0x6a, + 0x09, 0x92, 0x0e, 0x2c, 0x00, 0xdc, 0xa4, 0xe0, 0x01, 0x37, 0xbf, 0xb2, + 0xbb, 0x42, 0x51, 0xd9, 0x00, 0x24, 0x3b, 0x03, 0x03, 0x93, 0x07, 0x9b, + 0x00, 0x2b, 0x4f, 0xdd, 0x7f, 0x22, 0xe3, 0x17, 0x13, 0x40, 0x1b, 0x19, + 0xdb, 0x11, 0xda, 0x01, 0x05, 0x92, 0x09, 0x9a, 0x1b, 0x02, 0xd3, 0x1a, + 0x04, 0x93, 0x03, 0x9a, 0x09, 0x9b, 0x14, 0x21, 0x9b, 0x18, 0x04, 0x9a, + 0x30, 0x00, 0x9b, 0x1a, 0x0a, 0x93, 0x33, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x0a, 0x9b, 0xfd, 0xf7, 0x6f, 0xfd, + 0x25, 0x00, 0x07, 0x9b, 0x02, 0x90, 0x08, 0x93, 0x08, 0x9b, 0x2c, 0x00, + 0x07, 0x93, 0x02, 0x9b, 0x00, 0x2b, 0x05, 0xd1, 0x05, 0x9b, 0xeb, 0x1a, + 0x7f, 0x2b, 0x01, 0xdc, 0x0e, 0x2d, 0x28, 0xdd, 0x05, 0x9b, 0x80, 0x33, + 0x05, 0x93, 0x04, 0x9b, 0x01, 0x3b, 0xff, 0x3b, 0x04, 0x93, 0x02, 0x9b, + 0x00, 0x2b, 0x02, 0xd1, 0x05, 0x9b, 0x80, 0x2b, 0xd1, 0xd1, 0x01, 0x37, + 0xf3, 0x68, 0xbf, 0xb2, 0x9f, 0x42, 0x55, 0xd2, 0x80, 0x22, 0x52, 0x01, + 0x94, 0x46, 0x03, 0x9b, 0x63, 0x44, 0x03, 0x93, 0x00, 0x24, 0x02, 0x9b, + 0xa3, 0x42, 0xb4, 0xd0, 0x02, 0x9b, 0x00, 0x2b, 0x06, 0xdb, 0x03, 0xe0, + 0x04, 0x24, 0x06, 0x9b, 0x1c, 0x40, 0x4d, 0xd0, 0x29, 0x4b, 0x02, 0x93, + 0x02, 0x98, 0x0d, 0xb0, 0xf0, 0xbd, 0x01, 0x22, 0x06, 0x9b, 0x13, 0x42, + 0x05, 0xd0, 0x04, 0x9a, 0x6b, 0x00, 0xd3, 0x5a, 0x0b, 0x9a, 0x93, 0x42, + 0x2f, 0xd1, 0x16, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x1f, 0x80, 0x17, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x1d, 0x60, 0x13, 0x9b, 0x00, 0x2b, 0xe7, 0xd0, + 0x02, 0x22, 0x06, 0x9b, 0x0b, 0x99, 0x13, 0x42, 0x02, 0xd1, 0x04, 0x9a, + 0x6b, 0x00, 0xd1, 0x5a, 0x15, 0x9b, 0x3a, 0x00, 0x01, 0x93, 0x14, 0x9b, + 0x30, 0x00, 0x00, 0x93, 0x13, 0x9c, 0x2b, 0x00, 0xa0, 0x47, 0x15, 0x4b, + 0xc3, 0x18, 0x01, 0x2b, 0x21, 0xd8, 0x14, 0x4b, 0x98, 0x42, 0x0c, 0xd1, + 0x33, 0x6a, 0x00, 0x22, 0x01, 0x93, 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, + 0x14, 0x21, 0x0a, 0x9b, 0x30, 0x00, 0xfd, 0xf7, 0xfe, 0xfc, 0x00, 0x28, + 0x11, 0xdb, 0x08, 0x9b, 0x01, 0x35, 0x01, 0x3b, 0x08, 0x93, 0x8b, 0xe7, + 0x04, 0x23, 0x06, 0x9a, 0x13, 0x40, 0xb7, 0xd1, 0x03, 0x93, 0x1f, 0x00, + 0xa8, 0xe7, 0x0b, 0x03, 0x03, 0x93, 0x5e, 0xe7, 0x03, 0x94, 0x27, 0x00, + 0x5b, 0xe7, 0x02, 0x90, 0xae, 0xe7, 0xc0, 0x46, 0xa8, 0xd8, 0xff, 0xff, + 0x57, 0x27, 0x00, 0x00, 0xa9, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x04, 0x00, + 0x0d, 0x03, 0x0f, 0x00, 0x80, 0x21, 0x85, 0xb0, 0x49, 0x01, 0xa3, 0x68, + 0x28, 0x00, 0x98, 0x47, 0x63, 0x6b, 0x22, 0x00, 0x01, 0x33, 0x63, 0x63, + 0x02, 0x26, 0x2b, 0x00, 0x42, 0x32, 0x01, 0x92, 0xfe, 0x33, 0x00, 0x96, + 0x00, 0x22, 0x19, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x2c, 0xfd, 0x00, 0x28, + 0x1a, 0xdb, 0xe3, 0x68, 0x0e, 0x22, 0xdb, 0x1b, 0x0d, 0x4f, 0x6a, 0x44, + 0x5f, 0x40, 0x2b, 0x00, 0x17, 0x80, 0xfc, 0x33, 0x01, 0x92, 0x00, 0x96, + 0x00, 0x22, 0x19, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x1a, 0xfd, 0x00, 0x28, + 0x08, 0xdb, 0x80, 0x22, 0x04, 0x34, 0xe3, 0x8f, 0x12, 0x02, 0x01, 0x33, + 0x9b, 0xb2, 0x93, 0x42, 0x02, 0xd0, 0xe3, 0x87, 0x05, 0xb0, 0xf0, 0xbd, + 0x00, 0x23, 0xfa, 0xe7, 0x29, 0x04, 0x00, 0x00, 0xf0, 0xb5, 0x00, 0x27, + 0x04, 0x00, 0x8b, 0xb0, 0x3b, 0x4d, 0x08, 0xab, 0x1f, 0x80, 0x07, 0x95, + 0x08, 0xae, 0x33, 0x88, 0xe2, 0x68, 0x93, 0x42, 0x24, 0xd3, 0x38, 0x4a, + 0x7b, 0x1b, 0x01, 0x35, 0x93, 0x42, 0x00, 0xdc, 0x7d, 0x1c, 0x23, 0x1d, + 0xad, 0xb2, 0xdd, 0x87, 0x07, 0x9b, 0x1a, 0x00, 0x31, 0x4b, 0x9a, 0x42, + 0x58, 0xd1, 0x00, 0x25, 0x09, 0xab, 0x05, 0x93, 0x30, 0x4b, 0x65, 0x63, + 0x01, 0x93, 0xa5, 0x63, 0x2b, 0x00, 0xe5, 0x63, 0x04, 0x96, 0x03, 0x95, + 0x02, 0x95, 0x00, 0x95, 0x2a, 0x00, 0x29, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0xd1, 0xfe, 0x2a, 0x4b, 0x98, 0x42, 0x41, 0xd1, 0x28, 0x00, 0x3f, 0xe0, + 0x1a, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, 0x1b, 0x03, + 0x00, 0x92, 0xfc, 0x33, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, 0xfd, 0xf7, + 0x66, 0xfc, 0x00, 0x28, 0x30, 0xdb, 0xe2, 0x68, 0x33, 0x88, 0xd1, 0x1a, + 0x1f, 0x4a, 0x4a, 0x40, 0x02, 0xa9, 0x49, 0x8b, 0x92, 0xb2, 0x91, 0x42, + 0x05, 0xd0, 0x07, 0x9a, 0x11, 0x00, 0x17, 0x4a, 0x91, 0x42, 0x20, 0xd1, + 0x07, 0x93, 0x02, 0x22, 0x1b, 0x03, 0x09, 0xae, 0x00, 0x92, 0xfe, 0x33, + 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x49, 0xfc, + 0x00, 0x28, 0x13, 0xdb, 0x33, 0x88, 0x0e, 0x4a, 0x93, 0x42, 0x09, 0xd0, + 0x1a, 0x1c, 0xab, 0x42, 0x00, 0xd9, 0x2a, 0x1c, 0x95, 0xb2, 0x1a, 0x1c, + 0xbb, 0x42, 0x00, 0xd2, 0x3a, 0x1c, 0x97, 0xb2, 0x08, 0xaa, 0x13, 0x88, + 0x01, 0x33, 0x13, 0x80, 0x96, 0xe7, 0x0a, 0x48, 0x0b, 0xb0, 0xf0, 0xbd, + 0x07, 0x99, 0x20, 0x00, 0xff, 0xf7, 0x4c, 0xff, 0x00, 0x28, 0xa0, 0xda, + 0xf6, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0xff, 0x7f, 0x00, 0x00, + 0xc9, 0x49, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, 0x29, 0x04, 0x00, 0x00, + 0xd7, 0xd8, 0xff, 0xff, 0x10, 0xb5, 0x86, 0xb0, 0x09, 0x9c, 0x00, 0x93, + 0x05, 0x94, 0x08, 0x9c, 0x01, 0x23, 0x04, 0x94, 0x00, 0x24, 0x03, 0x94, + 0x02, 0x94, 0x01, 0x94, 0xff, 0xf7, 0x68, 0xfe, 0x02, 0x4b, 0x98, 0x42, + 0x00, 0xd1, 0x02, 0x48, 0x06, 0xb0, 0x10, 0xbd, 0xa8, 0xd8, 0xff, 0xff, + 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x1e, 0x00, 0x03, 0x00, 0x85, 0xb0, + 0x03, 0x92, 0x40, 0x33, 0x0f, 0x00, 0x19, 0x78, 0x04, 0x00, 0x0a, 0x9d, + 0x00, 0x29, 0x0b, 0xd0, 0x01, 0x95, 0x00, 0x96, 0x12, 0x4b, 0x03, 0x9a, + 0x39, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xd4, 0xff, 0x00, 0x28, 0x10, 0xd0, + 0x05, 0xb0, 0xf0, 0xbd, 0x43, 0x6b, 0x01, 0x2b, 0xf0, 0xd8, 0xfe, 0xf7, + 0x49, 0xfd, 0x0c, 0x4b, 0x98, 0x42, 0x01, 0xd0, 0x00, 0x28, 0xf3, 0xdb, + 0x63, 0x6b, 0x01, 0x2b, 0xe6, 0xd8, 0x09, 0x48, 0xee, 0xe7, 0x33, 0x88, + 0x23, 0x82, 0x2b, 0x68, 0x01, 0x33, 0x63, 0x61, 0x2b, 0x68, 0x00, 0x2b, + 0xe6, 0xd1, 0x63, 0x6b, 0x01, 0x3b, 0x63, 0x63, 0xe2, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xd3, 0xd8, 0xff, 0xff, 0xef, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x1e, 0x27, 0x8b, 0xb0, 0x6f, 0x44, 0x07, 0xae, 0x3a, 0x80, + 0x33, 0x80, 0x04, 0x00, 0x0d, 0x00, 0xc2, 0x69, 0x01, 0x8b, 0x00, 0x20, + 0x83, 0x42, 0x00, 0xd0, 0x30, 0x00, 0x22, 0x26, 0x09, 0xab, 0x05, 0x93, + 0x0f, 0x4b, 0x6e, 0x44, 0x02, 0x90, 0x01, 0x93, 0x04, 0x96, 0x01, 0x23, + 0x03, 0x97, 0x00, 0x95, 0x20, 0x00, 0xff, 0xf7, 0x07, 0xfe, 0x0b, 0x4b, + 0x98, 0x42, 0x0f, 0xd0, 0x00, 0x28, 0x0b, 0xdb, 0x10, 0x9b, 0x31, 0x88, + 0x09, 0x9a, 0x00, 0x2b, 0x04, 0xd0, 0x0b, 0x01, 0x9b, 0x18, 0x10, 0x9d, + 0x01, 0x33, 0x2b, 0x80, 0x21, 0x83, 0xe2, 0x61, 0x0b, 0xb0, 0xf0, 0xbd, + 0x02, 0x48, 0xfb, 0xe7, 0xc5, 0x47, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x1e, 0x27, 0x8b, 0xb0, 0x6f, 0x44, + 0x07, 0xae, 0x3a, 0x80, 0x33, 0x80, 0x04, 0x00, 0x0d, 0x00, 0xc2, 0x69, + 0x01, 0x8b, 0x00, 0x20, 0x83, 0x42, 0x00, 0xd0, 0x30, 0x00, 0x22, 0x26, + 0x09, 0xab, 0x05, 0x93, 0x0f, 0x4b, 0x6e, 0x44, 0x02, 0x90, 0x01, 0x93, + 0x04, 0x96, 0x02, 0x23, 0x03, 0x97, 0x00, 0x95, 0x20, 0x00, 0xff, 0xf7, + 0xcf, 0xfd, 0x0b, 0x4b, 0x98, 0x42, 0x0f, 0xd0, 0x00, 0x28, 0x0b, 0xdb, + 0x10, 0x9b, 0x31, 0x88, 0x09, 0x9a, 0x00, 0x2b, 0x04, 0xd0, 0x0b, 0x01, + 0x9b, 0x18, 0x10, 0x9d, 0x01, 0x33, 0x2b, 0x80, 0x21, 0x83, 0xe2, 0x61, + 0x0b, 0xb0, 0xf0, 0xbd, 0x02, 0x48, 0xfb, 0xe7, 0xc5, 0x47, 0x00, 0x00, + 0xa8, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0e, 0x27, + 0x12, 0x26, 0x89, 0xb0, 0x03, 0x93, 0x10, 0xab, 0x1b, 0x78, 0x15, 0x00, + 0x04, 0x93, 0x02, 0xab, 0xff, 0x18, 0x39, 0x80, 0xf6, 0x18, 0x07, 0xab, + 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x33, 0x00, 0x04, 0x00, 0xff, 0xf7, + 0x41, 0xff, 0x00, 0x28, 0x67, 0xdb, 0x33, 0x88, 0x07, 0x9a, 0x1b, 0x03, + 0x52, 0x00, 0x9b, 0x18, 0x02, 0x22, 0x01, 0x97, 0x00, 0x92, 0x04, 0x21, + 0x00, 0x22, 0x20, 0x00, 0xfd, 0xf7, 0x9b, 0xfb, 0x00, 0x28, 0x58, 0xdb, + 0x01, 0x22, 0xa3, 0x6b, 0x07, 0x21, 0x01, 0x33, 0xa3, 0x63, 0x2b, 0x79, + 0x20, 0x00, 0x93, 0x43, 0x2b, 0x71, 0x07, 0x9b, 0x9b, 0x18, 0x32, 0x88, + 0x1b, 0x02, 0x12, 0x03, 0x9b, 0x18, 0x05, 0x22, 0x01, 0x95, 0x00, 0x92, + 0x00, 0x22, 0xfd, 0xf7, 0x84, 0xfb, 0x00, 0x28, 0x41, 0xdb, 0x03, 0x9b, + 0x00, 0x2b, 0x13, 0xd0, 0x07, 0x9b, 0x32, 0x88, 0x01, 0x33, 0x12, 0x03, + 0x1b, 0x02, 0x9b, 0x18, 0x0f, 0x9a, 0x05, 0x33, 0x9b, 0x18, 0x03, 0x9a, + 0x07, 0x21, 0x01, 0x92, 0x0e, 0x9a, 0x20, 0x00, 0x00, 0x92, 0x00, 0x22, + 0xfd, 0xf7, 0x6d, 0xfb, 0x00, 0x28, 0x2a, 0xdb, 0x04, 0x9b, 0x00, 0x2b, + 0x1a, 0xd0, 0x02, 0x22, 0x2b, 0x79, 0x13, 0x42, 0x16, 0xd0, 0x93, 0x43, + 0x02, 0xa9, 0x10, 0x32, 0x2b, 0x71, 0x52, 0x18, 0x07, 0x9b, 0x12, 0x88, + 0x01, 0x33, 0x12, 0x03, 0x1b, 0x02, 0x9b, 0x18, 0x01, 0x22, 0x04, 0x35, + 0x00, 0x92, 0x04, 0x33, 0x01, 0x95, 0x00, 0x22, 0x07, 0x21, 0x20, 0x00, + 0xfd, 0xf7, 0x4f, 0xfb, 0x00, 0x28, 0x0c, 0xdb, 0x11, 0x9b, 0x00, 0x2b, + 0x09, 0xd0, 0x12, 0x23, 0x02, 0xaa, 0x9b, 0x18, 0x1b, 0x88, 0x07, 0x9a, + 0x1b, 0x01, 0xd3, 0x18, 0x11, 0x9a, 0x01, 0x33, 0x13, 0x80, 0x09, 0xb0, + 0xf0, 0xbd, 0x00, 0x00, 0x7f, 0xb5, 0x0e, 0x22, 0x00, 0x26, 0x0f, 0x23, + 0x0c, 0x00, 0x6a, 0x44, 0x16, 0x80, 0x01, 0x92, 0x02, 0x22, 0x0b, 0x40, + 0x11, 0x49, 0x00, 0x92, 0x5b, 0x18, 0x21, 0x09, 0x09, 0x03, 0x5b, 0x00, + 0x5b, 0x18, 0x32, 0x00, 0x31, 0x00, 0x05, 0x00, 0xfd, 0xf7, 0x27, 0xfb, + 0xb0, 0x42, 0x13, 0xdb, 0xeb, 0x6b, 0x0d, 0x22, 0x01, 0x33, 0xeb, 0x63, + 0xab, 0x6b, 0x6a, 0x44, 0x01, 0x3b, 0xab, 0x63, 0x7e, 0x23, 0x13, 0x70, + 0x01, 0x92, 0x01, 0x22, 0x24, 0x02, 0x00, 0x92, 0x23, 0x1d, 0x32, 0x00, + 0x03, 0x21, 0x28, 0x00, 0xfd, 0xf7, 0x11, 0xfb, 0x04, 0xb0, 0x70, 0xbd, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x89, 0xb0, 0x15, 0x00, 0x0e, 0xaa, + 0x03, 0x91, 0x02, 0xca, 0x12, 0x24, 0x12, 0x88, 0x02, 0x91, 0x04, 0x92, + 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x13, 0x80, 0x07, 0xab, 0x64, 0x18, + 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x23, 0x00, 0x06, 0x00, 0x10, 0x9f, + 0xff, 0xf7, 0x8c, 0xfe, 0x00, 0x28, 0x5f, 0xdb, 0x24, 0x88, 0x07, 0x9b, + 0x24, 0x01, 0x1c, 0x19, 0x01, 0x34, 0xa4, 0xb2, 0x00, 0x2f, 0x00, 0xd0, + 0x3c, 0x80, 0x27, 0x02, 0x00, 0x2d, 0x1e, 0xd1, 0x80, 0x22, 0x04, 0x9b, + 0x52, 0x00, 0x1b, 0x02, 0x00, 0x92, 0x03, 0x99, 0x3a, 0x00, 0x30, 0x00, + 0xff, 0xf7, 0xa8, 0xfc, 0x00, 0x23, 0x02, 0x9d, 0x02, 0x93, 0x24, 0xe0, + 0x03, 0x22, 0x2b, 0x79, 0x04, 0x35, 0x93, 0x43, 0x2b, 0x70, 0x02, 0x3a, + 0x00, 0x92, 0x3b, 0x1d, 0x01, 0x95, 0x03, 0x9a, 0x07, 0x21, 0x30, 0x00, + 0xfd, 0xf7, 0xcb, 0xfa, 0x00, 0x28, 0x31, 0xda, 0x34, 0xe0, 0x01, 0x22, + 0x2b, 0x79, 0x10, 0x00, 0x59, 0x08, 0x93, 0x43, 0x92, 0x18, 0x13, 0x43, + 0x2b, 0x71, 0x80, 0x23, 0x88, 0x43, 0x5b, 0x00, 0x02, 0x90, 0x00, 0x93, + 0x01, 0x95, 0x3b, 0x00, 0x00, 0x22, 0x07, 0x21, 0x30, 0x00, 0xfd, 0xf7, + 0xb4, 0xfa, 0x00, 0x28, 0x1e, 0xdb, 0x0f, 0x23, 0x0f, 0x4a, 0x23, 0x40, + 0x9b, 0x18, 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, + 0x24, 0x09, 0x5b, 0x00, 0x24, 0x03, 0x00, 0x92, 0x1b, 0x19, 0x00, 0x22, + 0x04, 0x21, 0x30, 0x00, 0xfd, 0xf7, 0x9f, 0xfa, 0x00, 0x28, 0x09, 0xdb, + 0xb3, 0x6b, 0x01, 0x33, 0xb3, 0x63, 0x02, 0x9b, 0x00, 0x2b, 0xbd, 0xd1, + 0x04, 0x99, 0x30, 0x00, 0xff, 0xf7, 0x56, 0xff, 0x09, 0xb0, 0xf0, 0xbd, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x87, 0xb0, 0x04, 0x93, 0x0c, 0xab, + 0x1b, 0x88, 0x07, 0x00, 0x00, 0x93, 0x0d, 0xab, 0x1b, 0x88, 0x15, 0x00, + 0x03, 0x93, 0x04, 0x9b, 0x05, 0x91, 0x5b, 0x04, 0x5b, 0x0c, 0x02, 0x93, + 0x83, 0x6a, 0x1e, 0x1d, 0x00, 0x23, 0x34, 0x00, 0x01, 0x93, 0xfb, 0x6a, + 0x01, 0x9a, 0x93, 0x42, 0x08, 0xd8, 0x01, 0x2d, 0x00, 0xd8, 0x6e, 0xe0, + 0x3c, 0x6d, 0x00, 0x2c, 0x00, 0xd0, 0x6c, 0xe0, 0x07, 0xb0, 0xf0, 0xbd, + 0x43, 0x4a, 0x63, 0x88, 0x13, 0x40, 0x02, 0x9a, 0x93, 0x42, 0x38, 0xd1, + 0x00, 0x9b, 0x00, 0x2b, 0x2b, 0xd1, 0x02, 0x2d, 0x38, 0xd0, 0xa3, 0x8c, + 0x00, 0x2b, 0x30, 0xd0, 0x6b, 0x46, 0x9b, 0x89, 0x23, 0x81, 0x0e, 0x9b, + 0x00, 0x2b, 0x20, 0xd0, 0x0e, 0x9a, 0x63, 0x60, 0xe1, 0x69, 0x00, 0x9b, + 0x01, 0x32, 0x09, 0xd0, 0x0e, 0x9b, 0x00, 0x29, 0x06, 0xd0, 0xca, 0x68, + 0x0b, 0x8a, 0x9b, 0x18, 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd2, 0x13, 0x00, + 0x22, 0x69, 0x9a, 0x42, 0x00, 0xd9, 0x23, 0x61, 0x62, 0x69, 0x9a, 0x42, + 0x00, 0xd9, 0x63, 0x61, 0x00, 0x29, 0x06, 0xd0, 0xca, 0x68, 0x01, 0x33, + 0x9a, 0x42, 0x02, 0xd9, 0x38, 0x00, 0xfd, 0xf7, 0x91, 0xfa, 0xa3, 0x89, + 0x00, 0x9a, 0x93, 0x42, 0x05, 0xd1, 0x00, 0x23, 0x02, 0x2d, 0x01, 0xd0, + 0x6b, 0x46, 0x9b, 0x89, 0x63, 0x81, 0x01, 0x9b, 0x30, 0x34, 0x01, 0x33, + 0x01, 0x93, 0xae, 0xe7, 0x00, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x05, 0xd0, + 0xe1, 0x69, 0x00, 0x29, 0x02, 0xd0, 0x38, 0x00, 0xfd, 0xf7, 0x78, 0xfa, + 0x00, 0x23, 0x23, 0x80, 0x63, 0x80, 0xe2, 0xe7, 0x00, 0x22, 0xb3, 0x5e, + 0x00, 0x2b, 0x0c, 0xd0, 0xb0, 0x6a, 0x00, 0x28, 0x09, 0xd0, 0x17, 0x4a, + 0x73, 0x88, 0x13, 0x40, 0x02, 0x9a, 0x93, 0x42, 0x03, 0xd1, 0x05, 0x9a, + 0x00, 0x99, 0xff, 0xf7, 0xd1, 0xfa, 0x01, 0x34, 0x30, 0x36, 0xfb, 0x6a, + 0xa3, 0x42, 0xe9, 0xd8, 0x90, 0xe7, 0x00, 0x24, 0xf9, 0xe7, 0x00, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x8e, 0xe7, 0x6b, 0x46, 0x10, 0x22, 0x9b, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0x88, 0xe7, 0x00, 0x99, 0x01, 0x2d, 0x08, 0xd0, + 0x00, 0x2d, 0x0b, 0xd0, 0xeb, 0x1e, 0x01, 0x2b, 0x08, 0xd9, 0x29, 0x00, + 0x02, 0x2d, 0x00, 0xd0, 0x7c, 0xe7, 0x03, 0x9b, 0x02, 0x9a, 0x38, 0x00, + 0xa0, 0x47, 0x77, 0xe7, 0x01, 0x21, 0xf8, 0xe7, 0xff, 0x7f, 0xff, 0xff, + 0xf0, 0xb5, 0x16, 0x27, 0x97, 0xb0, 0x1c, 0xab, 0x1b, 0x78, 0x04, 0x00, + 0x06, 0x93, 0x02, 0xab, 0xff, 0x18, 0x39, 0x80, 0xfb, 0x21, 0x05, 0x92, + 0xfe, 0xf7, 0x34, 0xfe, 0x05, 0x1e, 0x65, 0xdb, 0x3a, 0x88, 0x34, 0x4b, + 0x20, 0x00, 0x13, 0x43, 0x3b, 0x80, 0x09, 0xab, 0x00, 0x93, 0x1a, 0x23, + 0x02, 0xaa, 0x9b, 0x18, 0x21, 0x8a, 0x62, 0x69, 0xff, 0xf7, 0x5c, 0xfd, + 0x05, 0x1e, 0x55, 0xdb, 0x02, 0xab, 0x5b, 0x8b, 0x09, 0x9a, 0x1b, 0x03, + 0x52, 0x00, 0x9b, 0x18, 0x02, 0x22, 0x01, 0x97, 0x00, 0x92, 0x04, 0x21, + 0x00, 0x22, 0x20, 0x00, 0xfd, 0xf7, 0xb5, 0xf9, 0x05, 0x1e, 0x45, 0xdb, + 0xa3, 0x6b, 0x0a, 0xae, 0x01, 0x33, 0xa3, 0x63, 0x3b, 0x88, 0x2d, 0x20, + 0x33, 0x80, 0x00, 0x23, 0x73, 0x80, 0xf8, 0x33, 0x33, 0x71, 0x6b, 0x46, + 0x19, 0x7e, 0x02, 0xab, 0x31, 0x73, 0x01, 0x21, 0x49, 0x42, 0x0c, 0x91, + 0x20, 0x22, 0x05, 0x99, 0xc0, 0x18, 0x02, 0xf0, 0xf9, 0xfb, 0x09, 0x98, + 0x07, 0x21, 0x43, 0x1c, 0x02, 0xa8, 0x42, 0x8b, 0x1b, 0x02, 0x12, 0x03, + 0x9b, 0x18, 0x2e, 0x22, 0x01, 0x96, 0x00, 0x92, 0x20, 0x00, 0x00, 0x22, + 0xfd, 0xf7, 0x8d, 0xf9, 0x05, 0x1e, 0x1d, 0xdb, 0x01, 0x21, 0x49, 0x42, + 0x3b, 0x88, 0x02, 0x91, 0x02, 0xa9, 0x4a, 0x8b, 0x09, 0x99, 0x12, 0x01, + 0x8a, 0x18, 0x01, 0x32, 0x92, 0xb2, 0x01, 0x92, 0x00, 0x22, 0x31, 0x00, + 0x00, 0x92, 0x20, 0x00, 0x01, 0x32, 0xff, 0xf7, 0xe9, 0xfe, 0x1d, 0x9b, + 0x00, 0x2b, 0x07, 0xd0, 0x02, 0xab, 0x5b, 0x8b, 0x09, 0x9a, 0x1b, 0x01, + 0xd3, 0x18, 0x1d, 0x9a, 0x01, 0x33, 0x13, 0x80, 0x28, 0x00, 0x17, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, 0xf0, 0xb5, 0x89, 0xb0, + 0x05, 0x93, 0x80, 0x23, 0x0e, 0x9c, 0x1b, 0x02, 0x1a, 0x43, 0x06, 0x00, + 0x0f, 0x00, 0x04, 0x92, 0x00, 0x2c, 0x0e, 0xd1, 0x04, 0x21, 0x7a, 0x5e, + 0x41, 0x6a, 0x05, 0x9b, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, + 0x1b, 0x02, 0xea, 0x39, 0xfd, 0xf7, 0xeb, 0xf8, 0x05, 0x1e, 0x4e, 0xdb, + 0x74, 0x6a, 0x23, 0x79, 0xda, 0x07, 0x4d, 0xd4, 0x5a, 0xb2, 0x00, 0x2a, + 0x4c, 0xda, 0x9a, 0x07, 0x4c, 0xd4, 0x5b, 0x07, 0x4c, 0xd4, 0x63, 0x88, + 0x00, 0x2b, 0x4b, 0xd1, 0x0f, 0x9b, 0x00, 0x2b, 0x05, 0xd0, 0x20, 0x00, + 0x20, 0x22, 0x19, 0x00, 0x0d, 0x30, 0x02, 0xf0, 0x93, 0xfb, 0x11, 0x9b, + 0x00, 0x2b, 0x03, 0xd0, 0x23, 0x81, 0x11, 0x9b, 0x1b, 0x0c, 0x63, 0x81, + 0x39, 0x1e, 0x01, 0xd0, 0x04, 0x23, 0xf9, 0x5e, 0x16, 0x23, 0x02, 0xaa, + 0x9b, 0x18, 0x02, 0x93, 0x05, 0x9b, 0x22, 0x00, 0x01, 0x93, 0x00, 0x23, + 0x30, 0x00, 0x00, 0x93, 0x04, 0x9b, 0xff, 0xf7, 0x11, 0xfe, 0x05, 0x1e, + 0x1d, 0xd1, 0x02, 0xab, 0xd9, 0x8a, 0x12, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0x19, 0x80, 0x0e, 0x9a, 0x20, 0x89, 0x53, 0x42, 0x5a, 0x41, 0x63, 0x89, + 0x01, 0x91, 0x1b, 0x04, 0x03, 0x43, 0x02, 0x93, 0x63, 0x88, 0x92, 0x00, + 0x00, 0x93, 0x21, 0x00, 0x04, 0x9b, 0x30, 0x00, 0xff, 0xf7, 0x76, 0xfe, + 0x00, 0x2f, 0x04, 0xd0, 0x16, 0x23, 0x02, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0xbb, 0x81, 0x28, 0x00, 0x09, 0xb0, 0xf0, 0xbd, 0x04, 0x4d, 0xfa, 0xe7, + 0x04, 0x4d, 0xf8, 0xe7, 0x04, 0x4d, 0xf6, 0xe7, 0x04, 0x4d, 0xf4, 0xe7, + 0x04, 0x4d, 0xf2, 0xe7, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x93, 0xb0, 0x03, 0x93, 0x0d, 0x00, 0x0b, 0x02, 0x14, 0x00, + 0x04, 0x21, 0x52, 0x5e, 0x2e, 0x21, 0x06, 0xae, 0x00, 0x91, 0x01, 0x96, + 0x18, 0x39, 0x07, 0x00, 0xfd, 0xf7, 0x73, 0xf8, 0x00, 0x28, 0x33, 0xdb, + 0x0f, 0x23, 0x2b, 0x40, 0x2a, 0x09, 0x01, 0x3b, 0x12, 0x03, 0x5b, 0x00, + 0x9b, 0x18, 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, + 0x14, 0x21, 0x00, 0x92, 0x38, 0x00, 0x00, 0x22, 0xfd, 0xf7, 0x5f, 0xf8, + 0xa5, 0x81, 0x27, 0x60, 0xb3, 0x68, 0x6a, 0x46, 0xa3, 0x60, 0x00, 0x23, + 0x63, 0x61, 0x23, 0x82, 0x02, 0xab, 0xe5, 0x81, 0xdb, 0x89, 0x95, 0x89, + 0xe3, 0x80, 0xa5, 0x83, 0x32, 0x79, 0xd4, 0x07, 0x0f, 0xd4, 0x51, 0xb2, + 0x00, 0x29, 0x0f, 0xda, 0x02, 0x21, 0x0a, 0x42, 0x0e, 0xd1, 0x52, 0x07, + 0x0e, 0xd4, 0x1b, 0xb2, 0x00, 0x2b, 0x0b, 0xda, 0x73, 0x88, 0x00, 0x2b, + 0x02, 0xd0, 0x05, 0x48, 0x00, 0xe0, 0x05, 0x48, 0x13, 0xb0, 0xf0, 0xbd, + 0x04, 0x48, 0xfb, 0xe7, 0x04, 0x48, 0xf9, 0xe7, 0x04, 0x48, 0xf7, 0xe7, + 0xe3, 0xd8, 0xff, 0xff, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x95, 0xb0, + 0x0e, 0x93, 0x07, 0x68, 0x0d, 0x00, 0x0e, 0x99, 0x83, 0x68, 0x06, 0x00, + 0xfb, 0x31, 0x38, 0x00, 0x0f, 0x92, 0x06, 0x93, 0xfe, 0xf7, 0xe0, 0xfc, + 0x04, 0x1e, 0x00, 0xda, 0x0b, 0xe2, 0x06, 0x9b, 0x0a, 0x93, 0xab, 0x42, + 0x00, 0xd9, 0x0a, 0x95, 0x7b, 0x6a, 0xb2, 0x89, 0x06, 0x93, 0x10, 0xab, + 0x1a, 0x80, 0xfb, 0x21, 0x0a, 0x98, 0x02, 0xf0, 0xfb, 0xf9, 0xfb, 0x21, + 0x83, 0xb2, 0x0a, 0x98, 0x09, 0x93, 0x02, 0xf0, 0x7b, 0xfa, 0x4e, 0x4b, + 0x0c, 0x91, 0x0b, 0x93, 0x00, 0x23, 0x07, 0x93, 0x08, 0x93, 0x9c, 0x42, + 0x00, 0xd1, 0x2e, 0xe1, 0x0a, 0x9a, 0x08, 0x9b, 0x94, 0x46, 0x63, 0x44, + 0x09, 0x93, 0xb3, 0x60, 0x73, 0x61, 0x6b, 0x46, 0x9b, 0x8b, 0x10, 0xad, + 0x2a, 0x88, 0x33, 0x82, 0x07, 0x9b, 0xf2, 0x81, 0x00, 0x2b, 0x00, 0xd1, + 0x26, 0xe2, 0x31, 0x00, 0x38, 0x00, 0xff, 0xf7, 0x31, 0xf8, 0x00, 0x28, + 0x31, 0xdb, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfd, 0xf7, 0x3d, 0xf8, 0x00, 0x28, 0x22, 0xdb, 0x00, 0x22, 0x02, 0x92, + 0x2a, 0x88, 0x06, 0x98, 0x01, 0x92, 0xc2, 0x78, 0x81, 0x78, 0x12, 0x02, + 0x0a, 0x43, 0x00, 0x92, 0xf3, 0x88, 0x00, 0x22, 0x79, 0x6a, 0x38, 0x00, + 0xff, 0xf7, 0x9c, 0xfd, 0x1a, 0x21, 0x0a, 0xa8, 0x09, 0x18, 0x04, 0x91, + 0x00, 0x21, 0x09, 0x98, 0xb3, 0x89, 0xf2, 0x88, 0x03, 0x90, 0x02, 0x91, + 0x01, 0x91, 0x00, 0x91, 0x38, 0x00, 0x31, 0x00, 0xff, 0xf7, 0xb4, 0xfe, + 0x00, 0x28, 0x00, 0xdb, 0xa5, 0xe1, 0x04, 0x00, 0xa3, 0xe1, 0x1a, 0x20, + 0x03, 0x91, 0x0a, 0xac, 0x0b, 0x99, 0x00, 0x19, 0x04, 0x90, 0x02, 0x91, + 0x01, 0x91, 0x79, 0x6a, 0xb3, 0x89, 0xf2, 0x88, 0x00, 0x91, 0x31, 0x00, + 0x38, 0x00, 0xff, 0xf7, 0x9f, 0xfe, 0x11, 0xe1, 0x10, 0xad, 0x2a, 0x88, + 0x0b, 0x9b, 0x31, 0x00, 0x38, 0x00, 0xfe, 0xf7, 0xe3, 0xff, 0x04, 0x1e, + 0x00, 0xda, 0x88, 0xe1, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, + 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, + 0x38, 0x00, 0xfc, 0xf7, 0xee, 0xff, 0x04, 0x1e, 0x00, 0xda, 0x78, 0xe1, + 0x00, 0x24, 0x02, 0x94, 0x2a, 0x88, 0xf3, 0x88, 0x01, 0x92, 0x06, 0x9a, + 0x38, 0x00, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, 0x00, 0x92, + 0x79, 0x6a, 0x22, 0x00, 0xff, 0xf7, 0x4c, 0xfd, 0x1a, 0x21, 0x0a, 0xa8, + 0x09, 0x18, 0x04, 0x91, 0x0a, 0x98, 0x08, 0x99, 0xb3, 0x89, 0x09, 0x18, + 0xf2, 0x88, 0x03, 0x91, 0x02, 0x94, 0x01, 0x94, 0x00, 0x94, 0xc2, 0xe7, + 0xff, 0xff, 0x00, 0x00, 0xb3, 0x68, 0x58, 0x1e, 0xc6, 0x4b, 0x98, 0x42, + 0x0f, 0xd9, 0x08, 0x9b, 0x00, 0x2b, 0x0c, 0xd1, 0xfb, 0x21, 0x02, 0xf0, + 0x4b, 0xf9, 0x7c, 0x21, 0x69, 0x38, 0x02, 0xf0, 0x47, 0xf9, 0x07, 0x9b, + 0x01, 0x30, 0x80, 0xb2, 0x83, 0x42, 0x00, 0xd8, 0xfb, 0xe0, 0x80, 0x23, + 0xf1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x6b, 0x46, 0x9b, 0x8b, 0x12, 0xad, + 0x6b, 0x80, 0xf9, 0x23, 0x2b, 0x71, 0x10, 0xab, 0x29, 0x80, 0x03, 0x93, + 0x01, 0x23, 0x02, 0x93, 0x00, 0x23, 0x2a, 0x00, 0x01, 0x93, 0x00, 0x93, + 0x38, 0x00, 0xff, 0xf7, 0xe1, 0xfb, 0x04, 0x1e, 0x00, 0xda, 0x2a, 0xe1, + 0x80, 0x22, 0xff, 0x21, 0x52, 0x00, 0x78, 0x6a, 0x02, 0xf0, 0xdb, 0xf9, + 0x05, 0x22, 0x29, 0x00, 0x78, 0x6a, 0x02, 0xf0, 0xcd, 0xf9, 0x00, 0x22, + 0x02, 0x92, 0x0a, 0xaa, 0x12, 0x8b, 0xf3, 0x88, 0x01, 0x92, 0x07, 0x9a, + 0x38, 0x00, 0x00, 0x92, 0x79, 0x6a, 0x01, 0x22, 0xff, 0xf7, 0xf6, 0xfc, + 0x10, 0xab, 0x1b, 0x88, 0x0a, 0x9a, 0xf3, 0x81, 0x6b, 0x46, 0x9b, 0x8b, + 0x33, 0x82, 0x08, 0x9b, 0x9b, 0x18, 0x73, 0x61, 0xb3, 0x60, 0x07, 0x9b, + 0x0b, 0x93, 0x08, 0x9a, 0x0e, 0x9b, 0x0c, 0x99, 0x9b, 0x1a, 0xfb, 0x22, + 0x52, 0x1a, 0x0d, 0x92, 0x9a, 0x42, 0x00, 0xd9, 0x0d, 0x93, 0x0c, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0xfa, 0xe0, 0x6b, 0x46, 0x9b, 0x8c, 0x12, 0xaa, + 0xf1, 0x88, 0x53, 0x80, 0xfd, 0x23, 0x08, 0x98, 0x13, 0x71, 0x0f, 0x9b, + 0x49, 0x04, 0x49, 0x0c, 0x1b, 0x18, 0x11, 0xa8, 0x11, 0x80, 0x03, 0x90, + 0x01, 0x20, 0x02, 0x90, 0x0c, 0x98, 0x01, 0x90, 0x0d, 0x98, 0x00, 0x90, + 0x38, 0x00, 0xff, 0xf7, 0x93, 0xfb, 0x04, 0x1e, 0x00, 0xd0, 0xed, 0xe6, + 0x11, 0xab, 0x1d, 0x88, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x11, 0xe1, + 0x09, 0x9b, 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9d, 0x52, 0x0a, 0x9a, + 0x08, 0x9b, 0x9b, 0x18, 0x06, 0x9a, 0x13, 0x81, 0x1b, 0x0c, 0x53, 0x81, + 0x0d, 0x9a, 0x09, 0x98, 0x94, 0x46, 0x01, 0x30, 0x83, 0xb2, 0x09, 0x93, + 0x08, 0x9b, 0x63, 0x44, 0x08, 0x93, 0x00, 0x23, 0x0c, 0x93, 0x08, 0x9b, + 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd3, 0xcb, 0xe6, 0x00, 0x23, 0x07, 0x93, + 0x09, 0x9b, 0x68, 0x2b, 0x07, 0xd9, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x02, 0xf0, 0xae, 0xf8, 0x01, 0x30, 0x83, 0xb2, 0x07, 0x93, 0x0b, 0x9b, + 0x07, 0x9a, 0x93, 0x42, 0xa3, 0xd0, 0x08, 0x9b, 0x00, 0x2b, 0x2d, 0xd0, + 0x0b, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x0f, 0xe7, 0x08, 0x9b, 0x0a, 0x9a, + 0x99, 0x18, 0x06, 0x9b, 0x06, 0x9a, 0x19, 0x81, 0x0b, 0x0c, 0x53, 0x81, + 0x0a, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0xf2, 0xe6, 0x10, 0xad, 0x2a, 0x88, + 0x31, 0x00, 0x38, 0x00, 0xfe, 0xf7, 0xe8, 0xfe, 0x04, 0x1e, 0x00, 0xda, + 0x8d, 0xe0, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfc, 0xf7, 0xf3, 0xfe, 0x04, 0x1e, 0x00, 0xda, 0x7d, 0xe0, 0x08, 0x9b, + 0x0a, 0x9a, 0x9b, 0x18, 0xb3, 0x60, 0x73, 0x61, 0x07, 0x9b, 0x00, 0x2b, + 0x00, 0xd0, 0x1b, 0xe7, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x10, 0xab, + 0x1b, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, + 0xea, 0x39, 0x38, 0x00, 0xfc, 0xf7, 0x75, 0xfe, 0x04, 0x1e, 0x64, 0xdb, + 0x01, 0x22, 0x06, 0x9b, 0x1b, 0x79, 0x13, 0x42, 0x00, 0xd0, 0xe9, 0xe0, + 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xe7, 0xe0, 0x9a, 0x07, 0x00, 0xd5, + 0xe6, 0xe0, 0x5b, 0x07, 0x00, 0xd5, 0xe5, 0xe0, 0x06, 0x22, 0xb3, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0xe0, 0xe0, 0x06, 0x9b, 0x5b, 0x88, 0x0b, 0x93, + 0x00, 0x2b, 0x00, 0xd1, 0x43, 0xe7, 0x41, 0x4c, 0x47, 0xe0, 0x33, 0x8a, + 0x07, 0x9a, 0x93, 0x42, 0x34, 0xd1, 0x1e, 0x23, 0xf2, 0x89, 0x0a, 0xa9, + 0x5b, 0x18, 0x1a, 0x80, 0x1e, 0x25, 0x0a, 0xab, 0x04, 0x21, 0x72, 0x5e, + 0x79, 0x6a, 0xed, 0x18, 0x2b, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, + 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x38, 0x00, 0xfc, 0xf7, 0x3d, 0xfe, + 0x04, 0x1e, 0x2c, 0xdb, 0x01, 0x22, 0x06, 0x9b, 0x1b, 0x79, 0x13, 0x42, + 0x00, 0xd0, 0xb1, 0xe0, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xaf, 0xe0, + 0x9a, 0x07, 0x00, 0xd5, 0xae, 0xe0, 0x5b, 0x07, 0x00, 0xd5, 0xad, 0xe0, + 0x06, 0x22, 0xb3, 0x5e, 0x00, 0x2b, 0x00, 0xdb, 0xa8, 0xe0, 0x06, 0x9b, + 0x07, 0x9a, 0x5b, 0x88, 0x93, 0x42, 0xc8, 0xd1, 0x2a, 0x88, 0x10, 0xab, + 0x1a, 0x80, 0xfb, 0xe6, 0x80, 0x23, 0xf1, 0x88, 0x1b, 0x02, 0x19, 0x43, + 0x1e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, 0x00, 0x93, 0x07, 0x9a, 0x08, 0x9b, + 0x38, 0x00, 0xff, 0xf7, 0x45, 0xfa, 0x04, 0x1e, 0xc0, 0xda, 0x20, 0x00, + 0x15, 0xb0, 0xf0, 0xbd, 0x07, 0x9b, 0x00, 0x2b, 0x21, 0xd1, 0x09, 0x9b, + 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9a, 0x5a, 0x11, 0xab, 0x1a, 0x80, + 0x11, 0xad, 0x2a, 0x88, 0x31, 0x1d, 0x09, 0x9b, 0x38, 0x00, 0xfe, 0xf7, + 0x97, 0xff, 0x04, 0x1e, 0xe9, 0xdb, 0x2b, 0x88, 0x0c, 0x9a, 0x1b, 0x02, + 0x05, 0x33, 0x08, 0x98, 0x9b, 0x18, 0x04, 0x21, 0x72, 0x5e, 0x0f, 0x99, + 0x09, 0x18, 0x01, 0x91, 0x0d, 0x99, 0x38, 0x00, 0x00, 0x91, 0x07, 0x21, + 0xfc, 0xf7, 0x4b, 0xfe, 0xf7, 0xe6, 0x09, 0x9b, 0x19, 0x1d, 0x68, 0x2b, + 0x05, 0xd9, 0x09, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x02, 0xf0, 0x52, 0xf8, + 0x04, 0x31, 0x06, 0x9b, 0x49, 0x00, 0x5a, 0x5a, 0xd4, 0xe7, 0xc0, 0x46, + 0xf2, 0x66, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, 0x09, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x09, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x02, 0xf0, + 0x3f, 0xf8, 0x04, 0x31, 0x06, 0x9b, 0x49, 0x00, 0x5d, 0x52, 0xeb, 0xe6, + 0x0a, 0x9b, 0x00, 0x2b, 0x31, 0xd1, 0x69, 0x46, 0x06, 0x9b, 0x09, 0x8c, + 0x38, 0x00, 0x19, 0x81, 0x08, 0x9b, 0x06, 0x99, 0x1b, 0x0c, 0x4b, 0x81, + 0x0a, 0x9b, 0x31, 0x00, 0xfe, 0xf7, 0xfe, 0xfd, 0x00, 0x28, 0x00, 0xda, + 0xfd, 0xe5, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfc, 0xf7, 0x09, 0xfe, 0x00, 0x28, 0x00, 0xda, 0xed, 0xe5, 0x06, 0x9a, + 0xf3, 0x88, 0x11, 0x89, 0x52, 0x89, 0x38, 0x00, 0x12, 0x04, 0x0a, 0x43, + 0x02, 0x92, 0x2a, 0x88, 0x01, 0x92, 0x06, 0x9a, 0x52, 0x88, 0x00, 0x92, + 0x79, 0x6a, 0x04, 0x22, 0xff, 0xf7, 0x66, 0xfb, 0x81, 0xe7, 0x1a, 0x21, + 0x0a, 0xa8, 0x09, 0x18, 0x04, 0x91, 0x09, 0x99, 0xb3, 0x89, 0x03, 0x91, + 0x07, 0x99, 0xf2, 0x88, 0x02, 0x91, 0x01, 0x91, 0x79, 0x6a, 0xc6, 0xe5, + 0x03, 0x4c, 0x72, 0xe7, 0x03, 0x4c, 0x70, 0xe7, 0x03, 0x4c, 0x6e, 0xe7, + 0x03, 0x4c, 0x6c, 0xe7, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x95, 0xb0, + 0x0d, 0x91, 0x19, 0x00, 0x05, 0x68, 0x07, 0x00, 0xfb, 0x31, 0x28, 0x00, + 0x0f, 0x92, 0x0e, 0x93, 0xfe, 0xf7, 0x2a, 0xfa, 0x04, 0x1e, 0x00, 0xda, + 0x6e, 0xe1, 0x6b, 0x6a, 0xfb, 0x21, 0x07, 0x93, 0xbb, 0x89, 0x0d, 0x98, + 0x0b, 0x93, 0x01, 0xf0, 0x4b, 0xff, 0xfb, 0x21, 0x83, 0xb2, 0x0d, 0x98, + 0x08, 0x93, 0x01, 0xf0, 0xcb, 0xff, 0x00, 0x23, 0x0a, 0x91, 0xc1, 0x4e, + 0x06, 0x93, 0x09, 0x93, 0x9c, 0x42, 0x00, 0xd1, 0x2c, 0xe1, 0x0d, 0x9a, + 0x09, 0x9b, 0x94, 0x46, 0x63, 0x44, 0x7b, 0x61, 0x6b, 0x46, 0x9b, 0x8d, + 0xfb, 0x81, 0x6b, 0x46, 0x1b, 0x8b, 0x3b, 0x82, 0x06, 0x9b, 0x00, 0x2b, + 0x00, 0xd1, 0xf4, 0xe1, 0x0b, 0x9a, 0x39, 0x00, 0x28, 0x00, 0xfe, 0xf7, + 0x83, 0xfd, 0x00, 0x28, 0x00, 0xda, 0xff, 0xe1, 0x04, 0x22, 0xb9, 0x5e, + 0x1e, 0x22, 0x00, 0x26, 0x0a, 0xa8, 0x12, 0x18, 0xfb, 0x88, 0x02, 0x92, + 0x0b, 0x9a, 0x00, 0x96, 0x01, 0x92, 0x28, 0x00, 0x07, 0x9a, 0xff, 0xf7, + 0x7f, 0xfa, 0x0a, 0xab, 0xda, 0x8b, 0x6b, 0x46, 0x1b, 0x8b, 0xfa, 0x81, + 0x3b, 0x82, 0xb0, 0x42, 0x00, 0xda, 0xe7, 0xe1, 0xfb, 0x88, 0x01, 0x92, + 0x07, 0x9a, 0x02, 0x96, 0x91, 0x78, 0xd2, 0x78, 0x28, 0x00, 0x12, 0x02, + 0x0a, 0x43, 0x00, 0x92, 0x07, 0x99, 0x32, 0x00, 0xff, 0xf7, 0xe6, 0xfa, + 0x1a, 0xe1, 0x00, 0x23, 0x06, 0x93, 0x33, 0x00, 0x0b, 0x9a, 0x39, 0x00, + 0x28, 0x00, 0xfe, 0xf7, 0x51, 0xfd, 0x04, 0x1e, 0x00, 0xda, 0x0f, 0xe1, + 0x04, 0x22, 0xb9, 0x5e, 0x1e, 0x22, 0x00, 0x26, 0x0a, 0xa8, 0x12, 0x18, + 0xfb, 0x88, 0x02, 0x92, 0x0b, 0x9a, 0x00, 0x96, 0x01, 0x92, 0x28, 0x00, + 0x07, 0x9a, 0xff, 0xf7, 0x4d, 0xfa, 0x04, 0x00, 0xb0, 0x42, 0x00, 0xda, + 0xfc, 0xe0, 0xfb, 0x88, 0x0a, 0xaa, 0x02, 0x96, 0xd2, 0x8b, 0x28, 0x00, + 0x01, 0x92, 0x07, 0x9a, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, + 0x00, 0x92, 0x07, 0x99, 0x32, 0x00, 0xff, 0xf7, 0xb7, 0xfa, 0x06, 0x9b, + 0xb3, 0x42, 0x29, 0xd1, 0x04, 0x21, 0x7a, 0x5e, 0x69, 0x6a, 0x0b, 0x9b, + 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, + 0x28, 0x00, 0xfc, 0xf7, 0xd2, 0xfc, 0x04, 0x1e, 0x00, 0xda, 0xd9, 0xe0, + 0x07, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x00, 0xd5, 0x94, 0xe1, 0x5a, 0xb2, + 0x00, 0x2a, 0x00, 0xdb, 0x92, 0xe1, 0x9a, 0x07, 0x00, 0xd5, 0x91, 0xe1, + 0x5b, 0x07, 0x00, 0xd5, 0x90, 0xe1, 0x06, 0x22, 0xbb, 0x5e, 0x00, 0x2b, + 0x00, 0xdb, 0x8b, 0xe1, 0x07, 0x9b, 0x5b, 0x88, 0x00, 0x2b, 0x39, 0xd0, + 0x73, 0x4c, 0xbf, 0xe0, 0x3b, 0x8a, 0x06, 0x9a, 0x93, 0x42, 0x00, 0xd0, + 0xbd, 0xe0, 0x1e, 0x23, 0xfa, 0x89, 0x0a, 0xa9, 0x5b, 0x18, 0x1a, 0x80, + 0x1e, 0x26, 0x04, 0x21, 0x7a, 0x5e, 0x0a, 0xab, 0x69, 0x6a, 0xf6, 0x18, + 0x33, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, + 0xea, 0x39, 0x28, 0x00, 0xfc, 0xf7, 0x9b, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0xa2, 0xe0, 0x07, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x00, 0xd5, 0x5d, 0xe1, + 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0x5b, 0xe1, 0x9a, 0x07, 0x00, 0xd5, + 0x5a, 0xe1, 0x5b, 0x07, 0x00, 0xd5, 0x59, 0xe1, 0x06, 0x22, 0xbb, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0x54, 0xe1, 0x07, 0x9b, 0x06, 0x9a, 0x5b, 0x88, + 0x93, 0x42, 0xc7, 0xd1, 0x33, 0x88, 0x0b, 0x93, 0x6b, 0x46, 0x9b, 0x8d, + 0x0d, 0x9a, 0xfb, 0x81, 0x6b, 0x46, 0x1b, 0x8b, 0x3b, 0x82, 0x09, 0x9b, + 0x9b, 0x18, 0x7b, 0x61, 0x09, 0x9a, 0x0e, 0x9b, 0x0a, 0x99, 0x9b, 0x1a, + 0xfb, 0x22, 0x56, 0x1a, 0x9e, 0x42, 0x00, 0xd9, 0x1e, 0x00, 0x06, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x84, 0xe0, 0x08, 0x9b, 0x07, 0x9a, 0x17, 0x33, + 0x5b, 0x00, 0x9b, 0x5a, 0x0c, 0x93, 0x00, 0x23, 0x06, 0x93, 0x6b, 0x46, + 0x1b, 0x8c, 0x12, 0xaa, 0xf9, 0x88, 0x53, 0x80, 0xff, 0x23, 0x49, 0x04, + 0x13, 0x71, 0x0a, 0x9b, 0x49, 0x0c, 0x11, 0x80, 0x00, 0x2b, 0x00, 0xd0, + 0x82, 0xe0, 0xfb, 0x2e, 0x00, 0xd0, 0x7f, 0xe0, 0x09, 0x98, 0x0f, 0x9b, + 0x00, 0x96, 0x1b, 0x18, 0x11, 0xa8, 0x03, 0x90, 0x01, 0x20, 0x02, 0x90, + 0x0a, 0x98, 0x01, 0x90, 0x28, 0x00, 0xff, 0xf7, 0xe5, 0xf8, 0x0c, 0x99, + 0x28, 0x00, 0xff, 0xf7, 0x63, 0xf9, 0x04, 0x1e, 0x00, 0xd0, 0xea, 0xe6, + 0x11, 0xab, 0x1b, 0x88, 0x0a, 0x93, 0x06, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0xd7, 0xe0, 0x69, 0x46, 0x08, 0x9b, 0x07, 0x9a, 0x17, 0x33, 0x09, 0x8d, + 0x5b, 0x00, 0x99, 0x52, 0x08, 0x98, 0x01, 0x30, 0x83, 0xb2, 0x08, 0x93, + 0x09, 0x9b, 0x9b, 0x19, 0x09, 0x93, 0x00, 0x23, 0x06, 0x9e, 0x0a, 0x93, + 0x09, 0x9b, 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd3, 0xcd, 0xe6, 0x08, 0x9b, + 0x68, 0x2b, 0x00, 0xd8, 0xf5, 0xe0, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x01, 0xf0, 0x02, 0xfe, 0x01, 0x30, 0x83, 0xb2, 0x06, 0x93, 0x9e, 0x42, + 0x9a, 0xd0, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd1, 0x54, 0xe7, 0x00, 0x2e, + 0x00, 0xd0, 0xf8, 0xe6, 0x1a, 0x21, 0x0a, 0xa8, 0x09, 0x18, 0xbb, 0x89, + 0xfa, 0x88, 0x03, 0x94, 0x02, 0x94, 0x01, 0x94, 0x04, 0x91, 0x69, 0x6a, + 0x28, 0x00, 0x00, 0x91, 0x39, 0x00, 0xff, 0xf7, 0xf5, 0xfa, 0x04, 0x1e, + 0x00, 0xdb, 0x3f, 0xe7, 0x20, 0x00, 0x15, 0xb0, 0xf0, 0xbd, 0x80, 0x23, + 0xf9, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x06, 0x9a, 0x00, 0x23, 0x28, 0x00, 0xff, 0xf7, 0x1a, 0xf8, + 0x04, 0x1e, 0x00, 0xdb, 0x36, 0xe7, 0xeb, 0xe7, 0x08, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x08, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0x4d, 0xfe, 0x04, 0x31, 0x07, 0x9b, 0x49, 0x00, 0x5b, 0x5a, 0x0c, 0x93, + 0x73, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, + 0x39, 0x1d, 0x08, 0x9b, 0x0c, 0x9a, 0x28, 0x00, 0xfe, 0xf7, 0x64, 0xfd, + 0x04, 0x1e, 0xcf, 0xdb, 0x11, 0xab, 0xf9, 0x88, 0x03, 0x93, 0x00, 0x23, + 0x49, 0x04, 0x49, 0x0c, 0x02, 0x93, 0x01, 0x93, 0x00, 0x93, 0x12, 0xaa, + 0x28, 0x00, 0xff, 0xf7, 0x5d, 0xf8, 0x04, 0x1e, 0x00, 0xd0, 0x66, 0xe6, + 0x0a, 0x9b, 0x00, 0x2b, 0x2e, 0xd1, 0x0a, 0x9b, 0x98, 0x19, 0xfa, 0x28, + 0x3b, 0xd9, 0x0a, 0xab, 0x9b, 0x8b, 0x0a, 0x9a, 0x1b, 0x02, 0x05, 0x33, + 0x09, 0x98, 0x9b, 0x18, 0x04, 0x21, 0x7a, 0x5e, 0x0f, 0x99, 0x00, 0x96, + 0x09, 0x18, 0x01, 0x91, 0x28, 0x00, 0x07, 0x21, 0xfc, 0xf7, 0x01, 0xfc, + 0x04, 0x1e, 0x00, 0xd0, 0x4b, 0xe6, 0x02, 0x21, 0x12, 0xaa, 0x13, 0x79, + 0x28, 0x00, 0x8b, 0x43, 0x13, 0x71, 0x04, 0x21, 0x7a, 0x5e, 0x0a, 0xab, + 0x13, 0xa9, 0x9b, 0x8b, 0x01, 0x91, 0x01, 0x21, 0x1b, 0x02, 0x00, 0x91, + 0x04, 0x33, 0x06, 0x31, 0xfc, 0xf7, 0xeb, 0xfb, 0x04, 0x1e, 0x00, 0xd1, + 0x43, 0xe7, 0x34, 0xe6, 0x0a, 0xaa, 0x92, 0x8b, 0x0c, 0x9b, 0x04, 0x20, + 0x39, 0x5e, 0x0a, 0x98, 0x1b, 0x02, 0x12, 0x02, 0x00, 0x90, 0x05, 0x33, + 0x05, 0x32, 0x28, 0x00, 0xfe, 0xf7, 0xa4, 0xfd, 0x04, 0x1e, 0xc0, 0xd0, + 0x23, 0xe6, 0x0a, 0x9b, 0x0c, 0x9a, 0x05, 0x33, 0x12, 0x02, 0x9b, 0x19, + 0x9b, 0x18, 0x11, 0xaa, 0x12, 0x88, 0x0a, 0x99, 0x12, 0x02, 0x05, 0x32, + 0x52, 0x18, 0x04, 0x24, 0x39, 0x5f, 0xfb, 0x24, 0x20, 0x1a, 0x00, 0x90, + 0x92, 0x19, 0x28, 0x00, 0xfe, 0xf7, 0x8c, 0xfd, 0x04, 0x1e, 0xac, 0xd0, + 0x0b, 0xe6, 0x08, 0x9b, 0x19, 0x1d, 0x68, 0x2b, 0x05, 0xd9, 0x08, 0x98, + 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0xc6, 0xfd, 0x04, 0x31, 0x6a, 0x46, + 0x07, 0x9b, 0x12, 0x8d, 0x49, 0x00, 0x5a, 0x52, 0x1e, 0xe7, 0x1a, 0x21, + 0x0a, 0xa8, 0x09, 0x18, 0xbb, 0x89, 0xfa, 0x88, 0x04, 0x91, 0x06, 0x99, + 0x28, 0x00, 0x03, 0x91, 0x02, 0x91, 0x01, 0x91, 0x69, 0x6a, 0x00, 0x91, + 0x39, 0x00, 0xff, 0xf7, 0x37, 0xfa, 0x00, 0x28, 0x00, 0xdb, 0x41, 0xe7, + 0x04, 0x00, 0x3f, 0xe7, 0x0d, 0x4c, 0x3d, 0xe7, 0x0d, 0x4c, 0x3b, 0xe7, + 0x0d, 0x4c, 0x39, 0xe7, 0x0d, 0x4c, 0x37, 0xe7, 0x09, 0x9a, 0x0e, 0x9b, + 0x0a, 0x99, 0x9b, 0x1a, 0xfb, 0x22, 0x56, 0x1a, 0x9e, 0x42, 0x00, 0xd8, + 0xbd, 0xe6, 0x1e, 0x00, 0xbb, 0xe6, 0x00, 0x2e, 0xf2, 0xd0, 0x09, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x0b, 0xe6, 0x06, 0x93, 0x3a, 0xe6, 0xc0, 0x46, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0x70, 0xb5, 0x88, 0xb0, 0x07, 0xab, 0x1a, 0x26, + 0x04, 0x00, 0x05, 0x93, 0x08, 0x00, 0x00, 0x23, 0x15, 0x00, 0x0f, 0x4a, + 0x6e, 0x44, 0x03, 0x93, 0x02, 0x90, 0x01, 0x92, 0x00, 0x93, 0x21, 0x8b, + 0x04, 0x96, 0xe2, 0x69, 0x20, 0x00, 0xfe, 0xf7, 0x55, 0xfd, 0x0a, 0x4b, + 0x98, 0x42, 0x0d, 0xd0, 0x00, 0x28, 0x09, 0xdb, 0x31, 0x88, 0x07, 0x9a, + 0x00, 0x2d, 0x03, 0xd0, 0x0b, 0x01, 0x9b, 0x18, 0x01, 0x33, 0x2b, 0x80, + 0x21, 0x83, 0xe2, 0x61, 0x08, 0xb0, 0x70, 0xbd, 0x02, 0x48, 0xfb, 0xe7, + 0xcd, 0x48, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x83, 0x68, 0x93, 0xb0, 0x01, 0x3b, 0x04, 0x00, 0x0b, 0x91, + 0x07, 0x92, 0x06, 0x68, 0x03, 0x33, 0x00, 0xd8, 0xd6, 0xe0, 0x00, 0x25, + 0xaa, 0x42, 0x00, 0xd1, 0xde, 0xe0, 0x1a, 0x23, 0xa5, 0x89, 0x08, 0xaa, + 0xa7, 0x68, 0x9b, 0x18, 0x1d, 0x80, 0x00, 0x2f, 0x00, 0xd0, 0xd8, 0xe0, + 0x06, 0x97, 0x73, 0x6a, 0x08, 0x93, 0x07, 0x9b, 0x00, 0x2b, 0x13, 0xd0, + 0x0b, 0x9b, 0x00, 0x2b, 0x10, 0xd1, 0x10, 0xa9, 0xb8, 0x33, 0x0b, 0x70, + 0x01, 0x91, 0x01, 0x21, 0x2d, 0x02, 0x2b, 0x1d, 0x04, 0x20, 0x22, 0x5e, + 0x00, 0x91, 0x30, 0x00, 0x05, 0x31, 0xfc, 0xf7, 0x18, 0xfb, 0x05, 0x1e, + 0x00, 0xda, 0xbb, 0xe0, 0x9f, 0x4b, 0x0c, 0x93, 0x00, 0x23, 0x09, 0x93, + 0x0b, 0x9b, 0x9f, 0x42, 0x00, 0xd8, 0xfd, 0xe0, 0x06, 0x9b, 0x68, 0x2b, + 0x00, 0xd8, 0x14, 0xe2, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0x8f, 0xfc, 0x01, 0x30, 0x83, 0xb2, 0x0a, 0x93, 0x0a, 0x9a, 0x0c, 0x9b, + 0x93, 0x42, 0x00, 0xd1, 0x0e, 0xe2, 0x0c, 0x9b, 0x1a, 0x00, 0x92, 0x4b, + 0x9a, 0x42, 0x29, 0xd0, 0x08, 0xab, 0x5a, 0x8b, 0x21, 0x00, 0x0c, 0x9b, + 0x30, 0x00, 0xfe, 0xf7, 0xd5, 0xfa, 0x05, 0x1e, 0x00, 0xda, 0x93, 0xe0, + 0x08, 0xab, 0x59, 0x8b, 0x30, 0x00, 0xfe, 0xf7, 0xab, 0xff, 0x05, 0x1e, + 0x00, 0xda, 0x8b, 0xe0, 0x00, 0x21, 0x08, 0xaa, 0x02, 0x91, 0x52, 0x8b, + 0xe3, 0x88, 0x01, 0x92, 0x08, 0x9a, 0x90, 0x78, 0xd2, 0x78, 0x12, 0x02, + 0x02, 0x43, 0x00, 0x92, 0x30, 0x00, 0x02, 0x22, 0xff, 0xf7, 0x46, 0xf8, + 0x0c, 0x9b, 0x00, 0x2b, 0x04, 0xd0, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd1, + 0x82, 0xe0, 0xa7, 0x60, 0x0a, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x8e, 0xe0, + 0xa2, 0x89, 0x1a, 0x33, 0x08, 0xa9, 0x5b, 0x18, 0x1a, 0x80, 0x04, 0x21, + 0x62, 0x5e, 0x71, 0x6a, 0x08, 0xab, 0x5b, 0x8b, 0x01, 0x91, 0x80, 0x21, + 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x30, 0x00, 0xfc, 0xf7, + 0x52, 0xfa, 0x05, 0x1e, 0x5a, 0xdb, 0x08, 0x9b, 0x1b, 0x79, 0xda, 0x07, + 0x00, 0xd5, 0xb0, 0xe1, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xae, 0xe1, + 0x9a, 0x07, 0x00, 0xd5, 0xad, 0xe1, 0x5b, 0x07, 0x00, 0xd5, 0xac, 0xe1, + 0x06, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x00, 0xdb, 0xa7, 0xe1, 0x08, 0x9b, + 0x0a, 0x9a, 0x5b, 0x88, 0x09, 0x93, 0x93, 0x42, 0x00, 0xd0, 0xa2, 0xe1, + 0x08, 0xab, 0x5b, 0x8b, 0x67, 0x61, 0xe3, 0x81, 0x6b, 0x46, 0x1b, 0x8d, + 0x23, 0x82, 0x00, 0x2a, 0x00, 0xd0, 0x65, 0xe0, 0x06, 0x9b, 0x08, 0x9a, + 0x17, 0x33, 0x5b, 0x00, 0xd3, 0x18, 0x1a, 0x88, 0x0d, 0x92, 0x01, 0x22, + 0x52, 0x42, 0x1a, 0x80, 0x00, 0x23, 0x0c, 0x93, 0x09, 0x93, 0x0b, 0x9b, + 0x21, 0x1d, 0x00, 0x2b, 0x07, 0xd0, 0x07, 0x9b, 0x00, 0x2b, 0x04, 0xd1, + 0x0b, 0x9b, 0xfb, 0x1a, 0xfa, 0x2b, 0x00, 0xd8, 0xa6, 0xe0, 0x06, 0x9b, + 0x0d, 0x9a, 0x30, 0x00, 0xfe, 0xf7, 0xaa, 0xfb, 0x4e, 0x4b, 0x98, 0x42, + 0x59, 0xd1, 0xfb, 0x21, 0x38, 0x00, 0x01, 0xf0, 0x7b, 0xfc, 0x00, 0x29, + 0x00, 0xd1, 0x89, 0xe0, 0x7f, 0x1a, 0x88, 0xe0, 0x07, 0x9b, 0x00, 0x2b, + 0x00, 0xd0, 0x28, 0xe7, 0xfb, 0x21, 0x30, 0x00, 0x49, 0x00, 0xfd, 0xf7, + 0xbb, 0xfe, 0x05, 0x1e, 0x00, 0xdb, 0x20, 0xe7, 0x28, 0x00, 0x13, 0xb0, + 0xf0, 0xbd, 0x78, 0x1e, 0xfb, 0x21, 0x01, 0xf0, 0xdd, 0xfb, 0x83, 0xb2, + 0x06, 0x93, 0x7b, 0x1c, 0x00, 0xd0, 0x1e, 0xe7, 0x00, 0x27, 0x1c, 0xe7, + 0x0f, 0xa9, 0x04, 0x91, 0x07, 0x99, 0xa3, 0x89, 0x02, 0x91, 0x01, 0x91, + 0x00, 0x91, 0xe2, 0x88, 0x03, 0x97, 0x21, 0x00, 0x30, 0x00, 0xff, 0xf7, + 0xd7, 0xf8, 0x05, 0x1e, 0x00, 0xdb, 0x6c, 0xe7, 0xe0, 0xe7, 0x80, 0x23, + 0xe1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1a, 0x23, 0x08, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x0a, 0x9a, 0x00, 0x23, 0x30, 0x00, 0xfe, 0xf7, 0xfe, 0xfd, + 0x05, 0x1e, 0x00, 0xdb, 0x65, 0xe7, 0xcf, 0xe7, 0x06, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x06, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0x31, 0xfc, 0x04, 0x31, 0x08, 0x9b, 0x49, 0x00, 0x59, 0x18, 0x0b, 0x88, + 0x0d, 0x93, 0x01, 0x23, 0x5b, 0x42, 0x0b, 0x80, 0x0a, 0x9b, 0x0c, 0x93, + 0x91, 0xe7, 0x00, 0x28, 0x2c, 0xd0, 0x20, 0x4b, 0x98, 0x42, 0xa0, 0xd0, + 0x08, 0xab, 0x5d, 0x8b, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0xcf, 0xe0, + 0x00, 0x2f, 0x00, 0xd0, 0xc4, 0xe0, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd1, + 0xa7, 0xe0, 0x2a, 0x00, 0x3b, 0x00, 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, + 0xe1, 0xf9, 0x05, 0x1e, 0xa0, 0xdb, 0x08, 0xab, 0x59, 0x8b, 0x30, 0x00, + 0xfe, 0xf7, 0xb8, 0xfe, 0x05, 0x1e, 0x00, 0xda, 0x98, 0xe7, 0x02, 0x97, + 0x08, 0xaa, 0x52, 0x8b, 0xe3, 0x88, 0x01, 0x92, 0x00, 0x97, 0x02, 0x22, + 0x39, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0x58, 0xff, 0xa7, 0x60, 0x8b, 0xe7, + 0x0d, 0x99, 0x30, 0x00, 0xfe, 0xf7, 0xa4, 0xfe, 0x00, 0x28, 0x00, 0xd1, + 0x6f, 0xe7, 0xcd, 0xe7, 0xfb, 0x3f, 0x06, 0x98, 0xa7, 0x60, 0x01, 0x38, + 0x83, 0xb2, 0x67, 0x61, 0x06, 0x93, 0xc3, 0xe6, 0xff, 0xff, 0x00, 0x00, + 0xec, 0xd8, 0xff, 0xff, 0xe1, 0xd8, 0xff, 0xff, 0x06, 0x9b, 0x0d, 0x9a, + 0x30, 0x00, 0xfe, 0xf7, 0x03, 0xfb, 0x00, 0x28, 0xb8, 0xd1, 0x6a, 0x46, + 0xe1, 0x88, 0x12, 0x8b, 0x49, 0x04, 0x08, 0xab, 0x49, 0x0c, 0x5a, 0x84, + 0x19, 0x84, 0xff, 0x23, 0x24, 0x30, 0x08, 0xaa, 0x12, 0x18, 0x13, 0x70, + 0x08, 0xaa, 0xe1, 0x3b, 0x9b, 0x18, 0x03, 0x93, 0x07, 0x9b, 0x10, 0xaa, + 0x02, 0x93, 0x01, 0x93, 0x00, 0x93, 0x30, 0x00, 0xfe, 0xf7, 0xf0, 0xfd, + 0x00, 0x28, 0x9d, 0xd1, 0x0d, 0x9b, 0xfb, 0x21, 0x1b, 0x02, 0x05, 0x33, + 0x0a, 0x93, 0x0b, 0x98, 0x08, 0xab, 0xdd, 0x8b, 0x01, 0xf0, 0xb4, 0xfb, + 0x2d, 0x02, 0x05, 0x35, 0x00, 0x91, 0x0a, 0x9b, 0x2a, 0x00, 0x07, 0x99, + 0x30, 0x00, 0xfe, 0xf7, 0x65, 0xfb, 0x00, 0x28, 0x00, 0xd0, 0x87, 0xe7, + 0x0d, 0x99, 0x30, 0x00, 0xfe, 0xf7, 0x56, 0xfe, 0x00, 0x28, 0x00, 0xd0, + 0x80, 0xe7, 0x24, 0x21, 0x02, 0x22, 0x08, 0xab, 0x5b, 0x18, 0x1b, 0x78, + 0x30, 0x00, 0x93, 0x43, 0x08, 0xaa, 0x52, 0x18, 0x13, 0x70, 0x04, 0x21, + 0x62, 0x5e, 0x08, 0xab, 0x11, 0xa9, 0xdb, 0x8b, 0x01, 0x91, 0x01, 0x21, + 0x1b, 0x02, 0x00, 0x91, 0x04, 0x33, 0x06, 0x31, 0xfc, 0xf7, 0x79, 0xf9, + 0x00, 0x28, 0x00, 0xd0, 0x66, 0xe7, 0x08, 0xab, 0xdd, 0x8b, 0x09, 0x9b, + 0x00, 0x2b, 0x09, 0xd1, 0x06, 0x98, 0x17, 0x30, 0x08, 0x9b, 0x40, 0x00, + 0x1d, 0x52, 0x0b, 0x9b, 0xa3, 0x60, 0x63, 0x61, 0x1f, 0x00, 0x57, 0xe7, + 0x06, 0x9b, 0x68, 0x2b, 0x02, 0xd8, 0x18, 0x00, 0x04, 0x30, 0xf1, 0xe7, + 0x06, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0x6d, 0xfb, 0x08, 0x1d, + 0xea, 0xe7, 0x70, 0x6a, 0xd2, 0x22, 0x2e, 0x30, 0xff, 0x21, 0x01, 0xf0, + 0x98, 0xfb, 0x0f, 0xab, 0x04, 0x93, 0x01, 0x23, 0xe2, 0x88, 0x5b, 0x42, + 0x03, 0x93, 0x02, 0x97, 0x01, 0x97, 0x73, 0x6a, 0x00, 0x93, 0x2b, 0x00, + 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0xde, 0xff, 0x05, 0x1e, 0x00, 0xdb, + 0x5a, 0xe7, 0xe7, 0xe6, 0x0f, 0xab, 0x04, 0x93, 0x09, 0x9b, 0xe2, 0x88, + 0x03, 0x97, 0x02, 0x93, 0x01, 0x93, 0xec, 0xe7, 0x2a, 0x00, 0x09, 0x9b, + 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0x18, 0xf9, 0x05, 0x1e, 0x00, 0xda, + 0xd6, 0xe6, 0x00, 0x25, 0x04, 0x22, 0xa1, 0x5e, 0x10, 0xaa, 0x02, 0x92, + 0x08, 0xaa, 0x52, 0x8b, 0xe3, 0x88, 0x01, 0x92, 0x00, 0x95, 0x08, 0x9a, + 0x30, 0x00, 0xfe, 0xf7, 0x15, 0xfe, 0x05, 0x1e, 0x00, 0xda, 0xc5, 0xe6, + 0x00, 0x25, 0x08, 0xaa, 0x02, 0x95, 0x12, 0x8c, 0xe3, 0x88, 0x01, 0x92, + 0x08, 0x9a, 0x30, 0x00, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, + 0x00, 0x92, 0x08, 0x99, 0x2a, 0x00, 0xfe, 0xf7, 0x7f, 0xfe, 0x08, 0xab, + 0x1b, 0x8c, 0x0f, 0xa9, 0xe3, 0x81, 0x6b, 0x46, 0x9b, 0x8c, 0x67, 0x61, + 0x23, 0x82, 0xe2, 0x88, 0xa3, 0x89, 0x04, 0x91, 0x03, 0x97, 0x02, 0x95, + 0x01, 0x95, 0x00, 0x95, 0xb4, 0xe7, 0x0a, 0x4d, 0xa2, 0xe6, 0x0a, 0x4d, + 0xa0, 0xe6, 0x0a, 0x4d, 0x9e, 0xe6, 0x0a, 0x4d, 0x9c, 0xe6, 0x0a, 0x4d, + 0x9a, 0xe6, 0x00, 0x23, 0x0a, 0x93, 0x0c, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0xf1, 0xe5, 0x5d, 0xe6, 0x0a, 0x9b, 0x09, 0x93, 0xc4, 0xe6, 0xc0, 0x46, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x8f, 0xb0, + 0x07, 0x91, 0x08, 0x93, 0x03, 0x68, 0x04, 0x00, 0xfb, 0x21, 0x07, 0x98, + 0x04, 0x93, 0x0b, 0x92, 0x01, 0xf0, 0x5e, 0xfa, 0x87, 0xb2, 0x00, 0x20, + 0x04, 0x9b, 0x5b, 0x6a, 0x06, 0x93, 0x07, 0x9b, 0x03, 0x93, 0x6b, 0x4b, + 0x05, 0x93, 0x0b, 0x9a, 0x07, 0x9b, 0x94, 0x46, 0x03, 0x9a, 0x63, 0x44, + 0x0a, 0x93, 0x93, 0x42, 0x3a, 0xd9, 0xe2, 0x6a, 0x00, 0x2a, 0x0c, 0xd0, + 0x13, 0x89, 0xbb, 0x42, 0x09, 0xd8, 0x51, 0x89, 0xb9, 0x42, 0x06, 0xd3, + 0xfb, 0x1a, 0x12, 0x68, 0x5b, 0x00, 0x9d, 0x5a, 0x00, 0x2d, 0x00, 0xd0, + 0x82, 0xe0, 0x68, 0x2f, 0x3d, 0xd9, 0x38, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x01, 0xf0, 0x36, 0xfa, 0x05, 0x9b, 0x01, 0x30, 0x85, 0xb2, 0xab, 0x42, + 0x06, 0xd1, 0x38, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0xb2, 0xfa, + 0x04, 0x31, 0x1c, 0xe0, 0x23, 0x8a, 0xab, 0x42, 0x05, 0xd1, 0x0e, 0x23, + 0xe2, 0x89, 0x0a, 0xa9, 0x5b, 0x18, 0x1a, 0x80, 0x2c, 0xe0, 0x80, 0x23, + 0xe1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x0e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x2a, 0x00, 0x00, 0x23, 0x04, 0x98, 0xfe, 0xf7, 0x5a, 0xfc, + 0x00, 0x28, 0x1d, 0xda, 0x0f, 0xb0, 0xf0, 0xbd, 0x39, 0x1d, 0x68, 0x2f, + 0xdb, 0xd8, 0x06, 0x9b, 0x49, 0x00, 0x5d, 0x5a, 0x4e, 0xe0, 0x45, 0x48, + 0xf4, 0xe7, 0x45, 0x48, 0xf2, 0xe7, 0x45, 0x48, 0xf0, 0xe7, 0x45, 0x48, + 0xee, 0xe7, 0x45, 0x48, 0xec, 0xe7, 0x45, 0x48, 0xea, 0xe7, 0x05, 0x9b, + 0x00, 0x2b, 0x38, 0xd0, 0x0e, 0x23, 0x00, 0x25, 0xa2, 0x89, 0x0a, 0xa9, + 0x5b, 0x18, 0x1a, 0x80, 0x0e, 0x26, 0x04, 0x21, 0x62, 0x5e, 0x04, 0x99, + 0x0a, 0xab, 0x49, 0x6a, 0xf6, 0x18, 0x33, 0x88, 0x05, 0x91, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x04, 0x98, + 0xfb, 0xf7, 0xf3, 0xff, 0x00, 0x28, 0xcd, 0xdb, 0x01, 0x22, 0x06, 0x9b, + 0x1b, 0x79, 0x13, 0x42, 0xd1, 0xd1, 0x5a, 0xb2, 0x00, 0x2a, 0xd0, 0xda, + 0x9a, 0x07, 0xd0, 0xd4, 0x5b, 0x07, 0xd0, 0xd4, 0x06, 0x22, 0xa3, 0x5e, + 0x00, 0x2b, 0xcc, 0xda, 0x06, 0x9b, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, + 0x13, 0x43, 0x05, 0x93, 0xab, 0x42, 0xc6, 0xd1, 0x03, 0x9b, 0x25, 0x82, + 0x63, 0x61, 0x33, 0x88, 0xe3, 0x81, 0x00, 0x2d, 0xb0, 0xd1, 0x3b, 0x00, + 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9d, 0x5a, 0x00, 0x23, 0x05, 0x93, + 0xfb, 0x21, 0x03, 0x98, 0x01, 0xf0, 0x3c, 0xfa, 0x0a, 0x9b, 0x03, 0x9a, + 0x09, 0x91, 0x9a, 0x1a, 0x03, 0x99, 0xa3, 0x68, 0x5b, 0x1a, 0x93, 0x42, + 0x00, 0xd9, 0x13, 0x00, 0xfb, 0x26, 0x09, 0x9a, 0xb6, 0x1a, 0x9e, 0x42, + 0x00, 0xd9, 0x1e, 0x00, 0x00, 0x2e, 0xa4, 0xd0, 0x21, 0x1d, 0x3b, 0x00, + 0x2a, 0x00, 0x04, 0x98, 0xfe, 0xf7, 0x4c, 0xf9, 0x00, 0x28, 0x00, 0xda, + 0x88, 0xe7, 0x09, 0x9b, 0x04, 0x21, 0x62, 0x5e, 0x08, 0x99, 0x2d, 0x02, + 0x05, 0x33, 0x01, 0x91, 0xeb, 0x18, 0x00, 0x96, 0x17, 0x21, 0x04, 0x98, + 0xfb, 0xf7, 0x9f, 0xff, 0x00, 0x28, 0x00, 0xda, 0x78, 0xe7, 0x08, 0x9b, + 0x01, 0x37, 0x9b, 0x19, 0x08, 0x93, 0x03, 0x9b, 0xbf, 0xb2, 0x9b, 0x19, + 0x03, 0x93, 0x63, 0x61, 0x2b, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x0f, 0x23, 0x8d, 0xb0, 0x06, 0x91, 0x01, 0x21, 0x07, 0x92, + 0xc2, 0x68, 0x05, 0x00, 0x53, 0x43, 0x5b, 0x08, 0x09, 0xaa, 0x5b, 0x18, + 0x11, 0x80, 0x99, 0xb2, 0x1b, 0x04, 0x3c, 0xd4, 0x51, 0x80, 0x00, 0x23, + 0x53, 0x60, 0x07, 0x9b, 0x93, 0x60, 0x09, 0xac, 0x23, 0x88, 0x68, 0x6a, + 0x9c, 0x46, 0x62, 0x46, 0x63, 0x88, 0x9b, 0x1a, 0x80, 0x22, 0x12, 0x01, + 0x93, 0x42, 0x37, 0xdc, 0x80, 0x22, 0x00, 0x21, 0x52, 0x00, 0x01, 0xf0, + 0x06, 0xfa, 0x00, 0x21, 0x07, 0x9b, 0x05, 0x91, 0x02, 0x93, 0x3d, 0x4b, + 0x04, 0x91, 0x01, 0x93, 0x03, 0x94, 0x0b, 0x00, 0x00, 0x91, 0x0a, 0x00, + 0x28, 0x00, 0xfe, 0xf7, 0xa9, 0xf9, 0x39, 0x4b, 0x98, 0x42, 0x01, 0xd0, + 0x00, 0x28, 0x12, 0xdb, 0x80, 0x26, 0x00, 0x22, 0x01, 0x23, 0x6f, 0x6a, + 0x76, 0x00, 0xbd, 0x5c, 0xff, 0x2d, 0x12, 0xd0, 0x00, 0x21, 0x28, 0x00, + 0x08, 0x41, 0x18, 0x40, 0x0a, 0xd1, 0x23, 0x88, 0xd2, 0x00, 0x59, 0x18, + 0x06, 0x9b, 0x8a, 0x18, 0x1a, 0x80, 0x0d, 0xb0, 0xf0, 0xbd, 0x2d, 0x4b, + 0x53, 0x80, 0xc0, 0xe7, 0x01, 0x31, 0x08, 0x29, 0xed, 0xd1, 0x01, 0x32, + 0xb2, 0x42, 0xe6, 0xd1, 0x29, 0x48, 0xf2, 0xe7, 0x62, 0x68, 0x00, 0x2a, + 0x1d, 0xd1, 0x09, 0xac, 0x22, 0x88, 0x63, 0x88, 0x00, 0x26, 0x9b, 0x1a, + 0x80, 0x22, 0x1b, 0x0a, 0x52, 0x00, 0x00, 0x21, 0x63, 0x60, 0x01, 0xf0, + 0xc4, 0xf9, 0x22, 0x4b, 0x05, 0x96, 0x01, 0x93, 0x04, 0x96, 0x33, 0x00, + 0x03, 0x96, 0x02, 0x94, 0x00, 0x96, 0x32, 0x00, 0x31, 0x00, 0x28, 0x00, + 0xfe, 0xf7, 0x68, 0xf9, 0x18, 0x4b, 0x98, 0x42, 0x26, 0xd1, 0xa6, 0x60, + 0x9b, 0xe7, 0x00, 0x27, 0xff, 0x23, 0x39, 0x00, 0x46, 0x5c, 0x9e, 0x42, + 0x02, 0xd2, 0x33, 0x1e, 0x06, 0xd0, 0x0f, 0x00, 0x80, 0x26, 0x01, 0x31, + 0x76, 0x00, 0xb1, 0x42, 0xf4, 0xd1, 0x39, 0x00, 0x9a, 0x42, 0xcb, 0xd0, + 0x92, 0xb2, 0x51, 0x43, 0x61, 0x44, 0x89, 0xb2, 0x00, 0x2b, 0x03, 0xd1, + 0x06, 0x9a, 0x18, 0x00, 0x11, 0x80, 0xb6, 0xe7, 0x80, 0x23, 0x52, 0x18, + 0x92, 0xb2, 0x62, 0x80, 0x21, 0x80, 0x52, 0x1a, 0x1b, 0x01, 0x9a, 0x42, + 0xbd, 0xdc, 0x76, 0xe7, 0x00, 0x28, 0xaa, 0xdb, 0xa6, 0x60, 0x00, 0xd1, + 0x71, 0xe7, 0xa6, 0xe7, 0x31, 0x49, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xff, 0x7f, 0x00, 0x00, 0xef, 0xd8, 0xff, 0xff, 0x6d, 0x4b, 0x00, 0x00, + 0xf0, 0xb5, 0x85, 0xb0, 0x05, 0x00, 0x03, 0x91, 0x14, 0x00, 0x10, 0x1e, + 0x01, 0xd0, 0xfe, 0xf7, 0x57, 0xf8, 0xeb, 0x6a, 0xae, 0x6a, 0x02, 0x93, + 0x00, 0x2c, 0x07, 0xd0, 0x30, 0x23, 0x02, 0x99, 0x32, 0x1d, 0x4b, 0x43, + 0xf3, 0x18, 0x04, 0x33, 0x93, 0x42, 0x0e, 0xd1, 0x2a, 0x4a, 0x01, 0x23, + 0x01, 0x92, 0x00, 0x22, 0x31, 0x1d, 0x5b, 0x42, 0x00, 0x92, 0x02, 0x9f, + 0x00, 0x9a, 0xba, 0x42, 0x0e, 0xd1, 0x5a, 0x1c, 0x21, 0xd1, 0x25, 0x48, + 0x3b, 0xe0, 0x00, 0x27, 0xd1, 0x5f, 0x00, 0x29, 0x04, 0xd1, 0x91, 0x8c, + 0x01, 0x29, 0x01, 0xd9, 0x01, 0x39, 0x91, 0x84, 0x30, 0x32, 0xe3, 0xe7, + 0x00, 0x22, 0x8f, 0x5e, 0x00, 0x2f, 0x0a, 0xd1, 0x00, 0x2c, 0x02, 0xd0, + 0x0f, 0x6a, 0x87, 0x42, 0x0a, 0xd0, 0x8f, 0x8c, 0x01, 0x9a, 0x97, 0x42, + 0x01, 0xd2, 0x00, 0x9b, 0x01, 0x97, 0x00, 0x9a, 0x30, 0x31, 0x01, 0x32, + 0x00, 0x92, 0xd8, 0xe7, 0x00, 0x9b, 0x30, 0x22, 0x5a, 0x43, 0xb6, 0x18, + 0x00, 0x2c, 0x11, 0xd0, 0x72, 0x6a, 0x82, 0x42, 0x19, 0xd1, 0x31, 0x8d, + 0x00, 0x29, 0x16, 0xd0, 0xb2, 0x89, 0x10, 0x09, 0x28, 0x83, 0x0f, 0x20, + 0x02, 0x40, 0x01, 0x3a, 0xea, 0x61, 0x0c, 0x4a, 0x91, 0x42, 0x08, 0xd8, + 0x04, 0x31, 0x31, 0x85, 0x00, 0x20, 0x01, 0x33, 0xb3, 0x80, 0x03, 0x9b, + 0x1e, 0x60, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x22, 0x52, 0x42, 0x32, 0x85, + 0xf4, 0xe7, 0x04, 0x22, 0x70, 0x62, 0x32, 0x85, 0xf0, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xe9, 0xd8, 0xff, 0xff, 0xfa, 0xff, 0x00, 0x00, + 0x00, 0x29, 0x10, 0xdd, 0x2c, 0x22, 0x83, 0x5e, 0x8b, 0x42, 0x0c, 0xdb, + 0x30, 0x23, 0x4b, 0x43, 0x81, 0x6a, 0x30, 0x3b, 0xc9, 0x18, 0x04, 0x22, + 0x8b, 0x5e, 0x00, 0x2b, 0x05, 0xd0, 0x00, 0x20, 0x88, 0x80, 0xc8, 0x62, + 0x70, 0x47, 0x02, 0x48, 0xfc, 0xe7, 0x02, 0x48, 0xfa, 0xe7, 0xc0, 0x46, + 0xe6, 0xd8, 0xff, 0xff, 0xe8, 0xd8, 0xff, 0xff, 0x10, 0xb5, 0x00, 0x29, + 0x11, 0xdd, 0x2c, 0x24, 0x03, 0x5f, 0x8b, 0x42, 0x0d, 0xdb, 0x30, 0x23, + 0x59, 0x43, 0x83, 0x6a, 0x30, 0x39, 0x59, 0x18, 0x11, 0x60, 0x04, 0x23, + 0xc8, 0x5e, 0x43, 0x42, 0x58, 0x41, 0x03, 0x4b, 0x40, 0x42, 0x18, 0x40, + 0x10, 0xbd, 0x02, 0x48, 0xfc, 0xe7, 0xc0, 0x46, 0xe8, 0xd8, 0xff, 0xff, + 0xe6, 0xd8, 0xff, 0xff, 0x03, 0x7d, 0x00, 0x2b, 0x04, 0xd1, 0x43, 0x75, + 0x83, 0x75, 0x83, 0x61, 0x01, 0x33, 0x03, 0x75, 0x70, 0x47, 0x7f, 0xb5, + 0xc3, 0x68, 0x02, 0xad, 0x04, 0x00, 0x0e, 0x00, 0x02, 0x91, 0x6a, 0x60, + 0x8b, 0x42, 0x03, 0xd1, 0x02, 0x8a, 0xab, 0x88, 0x9a, 0x42, 0x18, 0xd0, + 0x20, 0x00, 0x06, 0x22, 0x29, 0x00, 0x0c, 0x30, 0x01, 0xf0, 0xae, 0xf8, + 0x20, 0x68, 0x00, 0xf0, 0xa8, 0xf9, 0x6b, 0x79, 0x22, 0x7a, 0xe1, 0x79, + 0x00, 0x93, 0x20, 0x68, 0x00, 0x23, 0x00, 0xf0, 0x41, 0xfa, 0x20, 0x68, + 0x29, 0x79, 0x32, 0x00, 0x00, 0xf0, 0x6c, 0xf9, 0x20, 0x68, 0x00, 0xf0, + 0x8e, 0xf9, 0x7f, 0xbd, 0x70, 0xb5, 0x18, 0x26, 0x04, 0x00, 0xff, 0xf7, + 0xcb, 0xff, 0x33, 0x00, 0x08, 0x21, 0x20, 0x79, 0x0d, 0x4d, 0x43, 0x43, + 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x22, 0xff, 0x33, 0x00, 0x08, 0x21, + 0xa0, 0x79, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x1a, 0xff, + 0x08, 0x21, 0x60, 0x79, 0x46, 0x43, 0xad, 0x19, 0x69, 0x56, 0x00, 0xf0, + 0x13, 0xff, 0x04, 0x4b, 0x20, 0x00, 0x06, 0xcb, 0xff, 0xf7, 0xb7, 0xff, + 0x70, 0xbd, 0xc0, 0x46, 0x20, 0x83, 0x00, 0x00, 0x34, 0x0c, 0x00, 0x20, + 0x07, 0xb5, 0x43, 0x7d, 0x00, 0x91, 0x01, 0x92, 0x00, 0x2b, 0x07, 0xd0, + 0x9a, 0x07, 0x0a, 0xd5, 0xef, 0xf3, 0x10, 0x83, 0x5a, 0x42, 0x53, 0x41, + 0x83, 0x75, 0x72, 0xb6, 0x00, 0x99, 0x01, 0x9a, 0xff, 0xf7, 0x9f, 0xff, + 0x07, 0xbd, 0xdb, 0x07, 0xf8, 0xd5, 0x83, 0x69, 0x01, 0x4a, 0x9b, 0xb2, + 0x93, 0x60, 0xf3, 0xe7, 0x00, 0x18, 0x00, 0x40, 0x10, 0xb5, 0x00, 0x68, + 0x00, 0xf0, 0x58, 0xf9, 0x10, 0xbd, 0x00, 0x00, 0x11, 0x4a, 0x12, 0x4b, + 0x12, 0x49, 0x13, 0x60, 0x00, 0x23, 0x53, 0x71, 0x13, 0x71, 0x11, 0x4a, + 0x11, 0x60, 0x11, 0x49, 0xd3, 0x60, 0x91, 0x80, 0x09, 0x21, 0x91, 0x71, + 0x06, 0x39, 0x53, 0x74, 0x13, 0x74, 0x13, 0x75, 0xd3, 0x71, 0x11, 0x72, + 0x0c, 0x4a, 0xd3, 0x60, 0x53, 0x74, 0x13, 0x74, 0x13, 0x75, 0x0b, 0x4b, + 0xd1, 0x71, 0x13, 0x60, 0x0a, 0x4b, 0x93, 0x80, 0x1d, 0x23, 0x93, 0x71, + 0x1c, 0x3b, 0x13, 0x72, 0x70, 0x47, 0xc0, 0x46, 0x34, 0x0c, 0x00, 0x20, + 0x00, 0x09, 0x3d, 0x00, 0xb8, 0x10, 0x00, 0x20, 0xfc, 0x0b, 0x00, 0x20, + 0x0a, 0x08, 0x00, 0x00, 0x18, 0x0c, 0x00, 0x20, 0xc4, 0x10, 0x00, 0x20, + 0x1b, 0x1a, 0x00, 0x00, 0x10, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x61, 0xfb, + 0x10, 0xbd, 0xc0, 0x46, 0x3c, 0x0c, 0x00, 0x20, 0x10, 0xb5, 0x02, 0x48, + 0x00, 0xf0, 0x59, 0xfb, 0x10, 0xbd, 0xc0, 0x46, 0x78, 0x0e, 0x00, 0x20, + 0x7f, 0xb5, 0x19, 0x49, 0x19, 0x48, 0x00, 0xf0, 0x4b, 0xf8, 0x19, 0x49, + 0x19, 0x48, 0x00, 0xf0, 0x47, 0xf8, 0x19, 0x49, 0x19, 0x48, 0x00, 0xf0, + 0x43, 0xf8, 0x19, 0x49, 0x19, 0x48, 0x00, 0xf0, 0x3f, 0xf8, 0x19, 0x4c, + 0x19, 0x49, 0x20, 0x00, 0x00, 0xf0, 0x3a, 0xf8, 0x18, 0x4e, 0x19, 0x49, + 0x30, 0x00, 0x00, 0xf0, 0x35, 0xf8, 0x01, 0x25, 0x03, 0x23, 0x31, 0x00, + 0x01, 0x95, 0x00, 0x93, 0x0d, 0x22, 0x0b, 0x33, 0x14, 0x48, 0x00, 0xf0, + 0xc5, 0xfa, 0x1d, 0x23, 0x03, 0x93, 0x01, 0x3b, 0x02, 0x93, 0x1a, 0x3b, + 0x01, 0x93, 0x00, 0x95, 0x18, 0x33, 0x1b, 0x22, 0x21, 0x00, 0x0f, 0x48, + 0x00, 0xf0, 0x74, 0xfa, 0x7f, 0xbd, 0xc0, 0x46, 0x00, 0x08, 0x00, 0x42, + 0xb4, 0x10, 0x00, 0x20, 0x00, 0x0c, 0x00, 0x42, 0xb8, 0x10, 0x00, 0x20, + 0x00, 0x10, 0x00, 0x42, 0xbc, 0x10, 0x00, 0x20, 0x00, 0x14, 0x00, 0x42, + 0xc0, 0x10, 0x00, 0x20, 0xc4, 0x10, 0x00, 0x20, 0x00, 0x18, 0x00, 0x42, + 0xc8, 0x10, 0x00, 0x20, 0x00, 0x1c, 0x00, 0x42, 0x3c, 0x0c, 0x00, 0x20, + 0x78, 0x0e, 0x00, 0x20, 0x01, 0x60, 0x70, 0x47, 0x94, 0x46, 0xf0, 0xb5, + 0x9e, 0x1e, 0x72, 0x1e, 0x96, 0x41, 0x62, 0x46, 0x05, 0x68, 0x92, 0x07, + 0x2f, 0x68, 0x36, 0x06, 0x3a, 0x43, 0x32, 0x43, 0x2a, 0x60, 0x07, 0x25, + 0x05, 0xac, 0x24, 0x78, 0x00, 0x68, 0xa4, 0x01, 0x29, 0x40, 0x21, 0x43, + 0x42, 0x68, 0x00, 0x24, 0x02, 0x2b, 0x00, 0xd0, 0x5c, 0x03, 0x11, 0x43, + 0x21, 0x43, 0x41, 0x60, 0xf0, 0xbd, 0x30, 0xb5, 0xc0, 0x25, 0x03, 0x68, + 0xad, 0x03, 0x1c, 0x68, 0x12, 0x05, 0x2a, 0x40, 0x22, 0x43, 0xc0, 0x24, + 0x09, 0x04, 0xa4, 0x02, 0x21, 0x40, 0x11, 0x43, 0x19, 0x60, 0x03, 0x68, + 0x5a, 0x68, 0x14, 0x43, 0x5c, 0x60, 0x30, 0xbd, 0x01, 0x23, 0x02, 0x68, + 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, 0x03, 0x68, 0x1a, 0x68, 0xd2, 0x07, + 0xfc, 0xd4, 0xda, 0x69, 0xd2, 0x07, 0xf9, 0xd4, 0x70, 0x47, 0x02, 0x23, + 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, 0x02, 0x68, 0xd3, 0x69, + 0x9b, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, + 0x02, 0xd4, 0x1a, 0x7e, 0x92, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0x00, 0x22, + 0x03, 0x68, 0x5a, 0x83, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x40, 0x07, + 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x09, 0x70, 0x47, + 0x80, 0x23, 0x02, 0x68, 0x5b, 0x42, 0x11, 0x7e, 0x0b, 0x43, 0x13, 0x76, + 0x70, 0x47, 0x03, 0x68, 0x58, 0x8b, 0x80, 0x07, 0xc0, 0x0f, 0x70, 0x47, + 0x02, 0x23, 0x02, 0x68, 0x51, 0x8b, 0x0b, 0x43, 0x53, 0x83, 0x70, 0x47, + 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, + 0x18, 0x8d, 0xc0, 0xb2, 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, + 0xfc, 0xd5, 0x89, 0xb2, 0x01, 0x20, 0x19, 0x85, 0x70, 0x47, 0x01, 0x22, + 0x03, 0x68, 0x9a, 0x75, 0x70, 0x47, 0x01, 0x22, 0x03, 0x68, 0x1a, 0x75, + 0x70, 0x47, 0x00, 0x00, 0x70, 0xb5, 0x01, 0x26, 0x04, 0x68, 0x4b, 0x08, + 0x33, 0x40, 0x31, 0x40, 0x25, 0x68, 0x09, 0x07, 0x5b, 0x07, 0x0b, 0x43, + 0x2b, 0x43, 0x23, 0x60, 0x04, 0x68, 0x51, 0x00, 0x03, 0x48, 0x00, 0xf0, + 0x71, 0xfe, 0x01, 0x38, 0xc0, 0xb2, 0x20, 0x73, 0x70, 0xbd, 0xc0, 0x46, + 0x00, 0x6c, 0xdc, 0x02, 0x01, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, + 0x13, 0x60, 0x03, 0x68, 0x1a, 0x68, 0xd2, 0x07, 0xfc, 0xd4, 0xda, 0x69, + 0xd2, 0x07, 0xf9, 0xd4, 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, 0x11, 0x68, + 0x0b, 0x43, 0x13, 0x60, 0x02, 0x68, 0xd3, 0x69, 0x9b, 0x07, 0xfc, 0xd4, + 0x70, 0x47, 0x03, 0x68, 0xda, 0x69, 0x92, 0x07, 0xfc, 0xd4, 0x02, 0x21, + 0x1a, 0x68, 0x8a, 0x43, 0x1a, 0x60, 0x70, 0x47, 0x02, 0x68, 0x93, 0x6a, + 0x5b, 0x0a, 0x5b, 0x02, 0x19, 0x43, 0x91, 0x62, 0x03, 0x68, 0x1a, 0x7e, + 0x52, 0x07, 0xfc, 0xd5, 0x98, 0x6a, 0xc0, 0xb2, 0x70, 0x47, 0x00, 0x00, + 0x03, 0x68, 0x21, 0x4a, 0x30, 0xb5, 0x93, 0x42, 0x2f, 0xd0, 0x20, 0x4a, + 0x93, 0x42, 0x2f, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1f, 0x4a, + 0x93, 0x42, 0x2f, 0xd0, 0x1e, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1e, 0x4a, + 0x93, 0x42, 0x1f, 0xd1, 0x0e, 0x23, 0x19, 0x22, 0x01, 0x21, 0x03, 0x25, + 0x99, 0x40, 0x1b, 0x48, 0xc0, 0x24, 0x01, 0x60, 0x99, 0x08, 0x2b, 0x40, + 0xab, 0x40, 0xfc, 0x35, 0x9d, 0x40, 0x89, 0x00, 0x09, 0x18, 0xa4, 0x00, + 0x08, 0x59, 0xa8, 0x43, 0xc0, 0x25, 0x9d, 0x40, 0x2b, 0x00, 0x03, 0x43, + 0x0b, 0x51, 0x80, 0x23, 0xdb, 0x01, 0x1a, 0x43, 0x11, 0x4b, 0x5a, 0x80, + 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, 0x30, 0xbd, 0x09, 0x23, + 0x14, 0x22, 0xdd, 0xe7, 0x0a, 0x23, 0x15, 0x22, 0xda, 0xe7, 0x0b, 0x23, + 0x16, 0x22, 0xd7, 0xe7, 0x0c, 0x23, 0x17, 0x22, 0xd4, 0xe7, 0x0d, 0x23, + 0x18, 0x22, 0xd1, 0xe7, 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, + 0x00, 0x10, 0x00, 0x42, 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, + 0x00, 0x1c, 0x00, 0x42, 0x00, 0xe1, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x40, + 0xf8, 0xb5, 0x04, 0x00, 0x0f, 0x00, 0x16, 0x00, 0x1d, 0x00, 0xff, 0xf7, + 0xa5, 0xff, 0x20, 0x00, 0xff, 0xf7, 0x04, 0xff, 0x1c, 0x21, 0xbb, 0x00, + 0x0b, 0x40, 0x71, 0x07, 0x22, 0x68, 0x09, 0x0c, 0x0b, 0x43, 0x13, 0x60, + 0x84, 0x23, 0x22, 0x68, 0x93, 0x75, 0x01, 0x2f, 0x1a, 0xd1, 0x10, 0x21, + 0x01, 0x2e, 0x00, 0xd0, 0x08, 0x39, 0x0c, 0x4b, 0x69, 0x43, 0x18, 0x68, + 0xc0, 0x00, 0x00, 0xf0, 0xc7, 0xfd, 0x07, 0x22, 0x21, 0x68, 0x02, 0x40, + 0x8b, 0x89, 0x52, 0x03, 0xdb, 0x04, 0xdb, 0x0c, 0x13, 0x43, 0x8b, 0x81, + 0x22, 0x68, 0x03, 0x04, 0x90, 0x89, 0xdb, 0x0c, 0x40, 0x0b, 0x40, 0x03, + 0x18, 0x43, 0x90, 0x81, 0xf8, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, + 0xf7, 0xb5, 0x06, 0x00, 0x01, 0x93, 0x08, 0xab, 0x1f, 0x78, 0x0d, 0x00, + 0x14, 0x00, 0xff, 0xf7, 0x3f, 0xff, 0x30, 0x00, 0xff, 0xf7, 0x6a, 0xff, + 0xc0, 0x22, 0x24, 0x05, 0x92, 0x03, 0x14, 0x40, 0xba, 0x07, 0x0c, 0x27, + 0x17, 0x43, 0x3c, 0x43, 0xc0, 0x27, 0x07, 0x22, 0xbf, 0x02, 0x2d, 0x04, + 0x33, 0x68, 0x3d, 0x40, 0x25, 0x43, 0x1d, 0x60, 0x01, 0x9b, 0x31, 0x68, + 0x13, 0x40, 0x1a, 0x00, 0x80, 0x23, 0x9b, 0x02, 0x13, 0x43, 0x4b, 0x60, + 0xf7, 0xbd, 0x01, 0x20, 0x70, 0x47, 0x00, 0x00, 0x10, 0xb5, 0x03, 0x68, + 0x01, 0x4a, 0x1b, 0x6a, 0x98, 0x47, 0x10, 0xbd, 0x13, 0x04, 0x00, 0x00, + 0x03, 0x00, 0xfc, 0x33, 0xd9, 0x69, 0x9a, 0x69, 0x91, 0x42, 0x03, 0xd0, + 0xdb, 0x69, 0xc0, 0x18, 0x00, 0x7d, 0x70, 0x47, 0x01, 0x20, 0x40, 0x42, + 0xfb, 0xe7, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x69, 0xff, 0xf7, 0x96, 0xfe, + 0x22, 0x00, 0x00, 0x23, 0xfc, 0x32, 0x93, 0x61, 0xd3, 0x61, 0x86, 0x22, + 0x92, 0x00, 0xa4, 0x18, 0x63, 0x60, 0xa3, 0x60, 0x10, 0xbd, 0xf0, 0x20, + 0x01, 0x40, 0x30, 0x39, 0x48, 0x42, 0x48, 0x41, 0x70, 0x47, 0xf0, 0x23, + 0x1b, 0x01, 0x19, 0x40, 0x80, 0x23, 0x06, 0x20, 0x9b, 0x00, 0x99, 0x42, + 0x0a, 0xd0, 0x01, 0x33, 0xff, 0x33, 0x01, 0x30, 0x99, 0x42, 0x05, 0xd0, + 0x80, 0x23, 0x02, 0x38, 0x5b, 0x00, 0x99, 0x42, 0x00, 0xd0, 0x00, 0x20, + 0x70, 0x47, 0x0f, 0x20, 0x01, 0x40, 0x00, 0x20, 0x01, 0x29, 0x03, 0xd0, + 0x02, 0x39, 0x48, 0x1e, 0x81, 0x41, 0x48, 0x1c, 0x70, 0x47, 0x00, 0x00, + 0x89, 0x23, 0xf0, 0xb5, 0x18, 0x26, 0x85, 0xb0, 0x02, 0x91, 0x9b, 0x00, + 0x04, 0x00, 0xc0, 0x5c, 0x33, 0x00, 0x08, 0x21, 0x43, 0x43, 0x32, 0x4d, + 0x17, 0x00, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x75, 0xfc, 0x30, 0x4b, + 0x08, 0x21, 0xe0, 0x5c, 0x33, 0x00, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, + 0x00, 0xf0, 0x6c, 0xfc, 0x2c, 0x4b, 0xe2, 0x5c, 0x03, 0x93, 0x02, 0x2a, + 0x09, 0xd1, 0x11, 0x33, 0xe0, 0x5c, 0xff, 0x28, 0x05, 0xd0, 0x08, 0x21, + 0x46, 0x43, 0xae, 0x19, 0x71, 0x56, 0x00, 0xf0, 0x5d, 0xfc, 0x8a, 0x26, + 0xb6, 0x00, 0xa0, 0x5d, 0xff, 0x28, 0x19, 0xd0, 0x01, 0x21, 0x00, 0xf0, + 0xdd, 0xfb, 0x18, 0x22, 0xa3, 0x5d, 0x21, 0x49, 0x5a, 0x43, 0xab, 0x56, + 0xad, 0x18, 0xdb, 0x01, 0x58, 0x18, 0x8b, 0x21, 0x89, 0x00, 0x60, 0x50, + 0x1d, 0x49, 0x01, 0x22, 0x5b, 0x18, 0x8c, 0x21, 0x89, 0x00, 0x63, 0x50, + 0x69, 0x68, 0x8a, 0x40, 0x8d, 0x21, 0x89, 0x00, 0x62, 0x50, 0x1a, 0x60, + 0x01, 0x22, 0x02, 0x9b, 0x11, 0x00, 0x20, 0x69, 0xff, 0xf7, 0x0a, 0xff, + 0x39, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x8f, 0xff, 0x39, 0x00, 0x05, 0x00, + 0x20, 0x00, 0xff, 0xf7, 0x9e, 0xff, 0x39, 0x00, 0x06, 0x00, 0x20, 0x00, + 0xff, 0xf7, 0x7f, 0xff, 0x33, 0x00, 0x00, 0x90, 0x29, 0x00, 0x20, 0x69, + 0x01, 0x22, 0xff, 0xf7, 0xd3, 0xfd, 0x0b, 0x4b, 0x20, 0x69, 0xe2, 0x5c, + 0x03, 0x9b, 0xe1, 0x5c, 0xff, 0xf7, 0xe9, 0xfd, 0x20, 0x69, 0xff, 0xf7, + 0x06, 0xfe, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, 0x20, 0x83, 0x00, 0x00, + 0x25, 0x02, 0x00, 0x00, 0x27, 0x02, 0x00, 0x00, 0x18, 0x44, 0x00, 0x41, + 0x14, 0x44, 0x00, 0x41, 0x26, 0x02, 0x00, 0x00, 0x80, 0x22, 0x10, 0xb5, + 0x04, 0x00, 0x52, 0x00, 0x00, 0x21, 0x00, 0xf0, 0x76, 0xfd, 0x23, 0x00, + 0x00, 0x22, 0xfc, 0x33, 0x5a, 0x60, 0x20, 0x00, 0x9a, 0x60, 0x10, 0xbd, + 0xf0, 0xb5, 0x85, 0xb0, 0x1d, 0x00, 0x0a, 0xab, 0x1b, 0x78, 0x04, 0x00, + 0x00, 0x93, 0x0b, 0xab, 0x1b, 0x78, 0x16, 0x00, 0x01, 0x93, 0x0c, 0xab, + 0x1b, 0x78, 0x0f, 0x00, 0x02, 0x93, 0x0d, 0xab, 0x1b, 0x78, 0x03, 0x93, + 0x00, 0x23, 0x43, 0x60, 0xfa, 0x23, 0x9b, 0x00, 0x83, 0x60, 0x12, 0x4b, + 0x08, 0x33, 0x03, 0x60, 0x14, 0x30, 0xff, 0xf7, 0xd5, 0xff, 0x20, 0x00, + 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0xd0, 0xff, 0x89, 0x23, 0x6a, 0x46, + 0x9b, 0x00, 0x27, 0x61, 0xe6, 0x54, 0x0b, 0x4b, 0x12, 0x78, 0xe5, 0x54, + 0x0a, 0x4b, 0x20, 0x00, 0xe2, 0x54, 0x6a, 0x46, 0x09, 0x4b, 0x12, 0x79, + 0xe2, 0x54, 0x6a, 0x46, 0x12, 0x7a, 0x01, 0x33, 0xe2, 0x54, 0x6a, 0x46, + 0x12, 0x7b, 0x10, 0x33, 0xe2, 0x54, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, + 0x80, 0x86, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, 0x26, 0x02, 0x00, 0x00, + 0x27, 0x02, 0x00, 0x00, 0xf7, 0xb5, 0x1d, 0x00, 0x08, 0xab, 0x1b, 0x78, + 0x04, 0x00, 0x00, 0x93, 0x09, 0xab, 0x1b, 0x78, 0x16, 0x00, 0x01, 0x93, + 0x00, 0x23, 0x43, 0x60, 0xfa, 0x23, 0x9b, 0x00, 0x83, 0x60, 0x11, 0x4b, + 0x0f, 0x00, 0x08, 0x33, 0x03, 0x60, 0x14, 0x30, 0xff, 0xf7, 0x98, 0xff, + 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0x93, 0xff, 0x89, 0x23, + 0x6a, 0x46, 0x9b, 0x00, 0x27, 0x61, 0xe6, 0x54, 0x09, 0x4b, 0x12, 0x78, + 0xe5, 0x54, 0x09, 0x4b, 0x20, 0x00, 0xe2, 0x54, 0x6a, 0x46, 0x08, 0x4b, + 0x12, 0x79, 0xe2, 0x54, 0x8a, 0x22, 0x29, 0x3b, 0xff, 0x3b, 0x92, 0x00, + 0xa3, 0x54, 0x10, 0x32, 0xa3, 0x54, 0xfe, 0xbd, 0x80, 0x86, 0x00, 0x00, + 0x25, 0x02, 0x00, 0x00, 0x26, 0x02, 0x00, 0x00, 0x27, 0x02, 0x00, 0x00, + 0x03, 0x00, 0xfc, 0x33, 0x58, 0x68, 0x9b, 0x68, 0xc0, 0x1a, 0x01, 0xd5, + 0x01, 0x30, 0xff, 0x30, 0x70, 0x47, 0x10, 0xb5, 0x04, 0x00, 0x20, 0x00, + 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0xf0, 0xff, 0x00, 0x28, 0xf8, 0xd1, + 0x20, 0x69, 0xff, 0xf7, 0x60, 0xfd, 0x10, 0xbd, 0x10, 0xb5, 0x14, 0x30, + 0xff, 0xf7, 0xe6, 0xff, 0x10, 0xbd, 0x03, 0x00, 0xfc, 0x33, 0x59, 0x68, + 0x9a, 0x68, 0x91, 0x42, 0x04, 0xdb, 0x5a, 0x68, 0x98, 0x68, 0x80, 0x1a, + 0xff, 0x30, 0x70, 0x47, 0x98, 0x68, 0x5b, 0x68, 0xc0, 0x1a, 0x01, 0x38, + 0xf9, 0xe7, 0x10, 0xb5, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0xeb, 0xff, + 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x69, 0xff, 0xf7, 0x5b, 0xfd, + 0x00, 0x28, 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x66, 0xfd, 0x20, 0x69, + 0xff, 0xf7, 0x58, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x40, 0xfd, 0x00, 0x28, + 0x20, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x5b, 0xfd, 0x22, 0x00, 0xfc, 0x32, + 0x93, 0x69, 0xd1, 0x69, 0x01, 0x33, 0xdb, 0xb2, 0x8b, 0x42, 0x03, 0xd0, + 0x91, 0x69, 0x61, 0x18, 0x08, 0x75, 0x93, 0x61, 0x8a, 0x23, 0x9b, 0x00, + 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, 0x20, 0x00, 0x14, 0x30, 0xff, 0xf7, + 0xc0, 0xff, 0x09, 0x28, 0x06, 0xdc, 0x8b, 0x23, 0x8d, 0x22, 0x9b, 0x00, + 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, 0x1a, 0x60, 0x20, 0x69, 0xff, 0xf7, + 0x35, 0xfd, 0x00, 0x28, 0x1a, 0xd0, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0x92, 0xff, 0x00, 0x28, 0x22, 0xd0, 0x86, 0x23, 0x9b, 0x00, + 0xe3, 0x18, 0x99, 0x68, 0x5a, 0x68, 0x91, 0x42, 0x18, 0xd0, 0x8e, 0x21, + 0x9a, 0x68, 0x49, 0x00, 0xa2, 0x18, 0x51, 0x5c, 0x9a, 0x68, 0x01, 0x32, + 0xd2, 0xb2, 0x9a, 0x60, 0xc9, 0xb2, 0x20, 0x69, 0xff, 0xf7, 0x21, 0xfd, + 0x20, 0x69, 0xff, 0xf7, 0xff, 0xfc, 0x00, 0x28, 0x05, 0xd0, 0x20, 0x69, + 0xff, 0xf7, 0xfe, 0xfc, 0x20, 0x69, 0xff, 0xf7, 0xee, 0xfc, 0x10, 0xbd, + 0x01, 0x21, 0x49, 0x42, 0xec, 0xe7, 0x20, 0x69, 0xff, 0xf7, 0x1b, 0xfd, + 0xec, 0xe7, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x00, 0x00, 0x69, 0x0d, 0x00, + 0xff, 0xf7, 0xfe, 0xfc, 0x00, 0x28, 0x3e, 0xd1, 0xff, 0x26, 0x86, 0x23, + 0x9b, 0x00, 0xe3, 0x18, 0x5a, 0x68, 0x99, 0x68, 0x01, 0x32, 0x32, 0x40, + 0x8a, 0x42, 0x23, 0xd1, 0xef, 0xf3, 0x10, 0x83, 0xdb, 0x07, 0x10, 0xd4, + 0x1e, 0x4b, 0x5b, 0x68, 0xdb, 0x05, 0xdb, 0x0d, 0xed, 0xd0, 0x10, 0x3b, + 0x5b, 0xb2, 0x00, 0x2b, 0x10, 0xda, 0x0f, 0x22, 0x13, 0x40, 0x08, 0x3b, + 0x9b, 0x08, 0x19, 0x4a, 0x9b, 0x00, 0x9b, 0x18, 0x1b, 0x68, 0x20, 0x69, + 0xff, 0xf7, 0xda, 0xfc, 0x00, 0x28, 0xdc, 0xd0, 0x20, 0x00, 0xff, 0xf7, + 0x6a, 0xff, 0xd8, 0xe7, 0x9b, 0x08, 0xc0, 0x33, 0x12, 0x4a, 0x9b, 0x00, + 0x9b, 0x58, 0xf0, 0xe7, 0x5a, 0x68, 0x01, 0x32, 0x16, 0x40, 0x9a, 0x68, + 0x96, 0x42, 0x05, 0xd0, 0x8e, 0x21, 0x5a, 0x68, 0x49, 0x00, 0xa2, 0x18, + 0x55, 0x54, 0x5e, 0x60, 0x20, 0x69, 0xff, 0xf7, 0xd0, 0xfc, 0x01, 0x20, + 0x70, 0xbd, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0x1c, 0xff, + 0x00, 0x28, 0xb9, 0xd1, 0x29, 0x00, 0x20, 0x69, 0xff, 0xf7, 0xbb, 0xfc, + 0xf1, 0xe7, 0xc0, 0x46, 0x00, 0xed, 0x00, 0xe0, 0x1c, 0xed, 0x00, 0xe0, + 0x00, 0xe1, 0x00, 0xe0, 0x03, 0x00, 0x70, 0xb5, 0xfc, 0x33, 0xd9, 0x69, + 0x9a, 0x69, 0x04, 0x00, 0x91, 0x42, 0x1a, 0xd0, 0xda, 0x69, 0x82, 0x18, + 0x15, 0x7d, 0xda, 0x69, 0x01, 0x32, 0xd2, 0xb2, 0xda, 0x61, 0x8a, 0x23, + 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, 0x20, 0x00, 0x14, 0x30, + 0xff, 0xf7, 0x11, 0xff, 0x0a, 0x28, 0x06, 0xdd, 0x8c, 0x23, 0x8d, 0x22, + 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, 0x1a, 0x60, 0x28, 0x00, + 0x70, 0xbd, 0x01, 0x25, 0x6d, 0x42, 0xe8, 0xe7, 0xfe, 0xe7, 0x00, 0x00, + 0x03, 0x4b, 0x10, 0xb5, 0x1b, 0x68, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, + 0x10, 0xbd, 0xc0, 0x46, 0xcc, 0x10, 0x00, 0x20, 0x70, 0xb5, 0x0f, 0x49, + 0x0f, 0x4c, 0xa1, 0x42, 0x04, 0xd1, 0x00, 0xf0, 0x81, 0xf8, 0xfa, 0xf7, + 0xc9, 0xfd, 0xfe, 0xe7, 0x0c, 0x4d, 0x00, 0x23, 0x8d, 0x42, 0xf6, 0xd0, + 0xca, 0x18, 0xe8, 0x18, 0xa2, 0x42, 0x05, 0xd3, 0x09, 0x4b, 0x82, 0x42, + 0xef, 0xd0, 0x09, 0x49, 0x00, 0x22, 0x04, 0xe0, 0x00, 0x68, 0x04, 0x33, + 0x10, 0x60, 0xf1, 0xe7, 0x04, 0xc3, 0x8b, 0x42, 0xfc, 0xd3, 0xe4, 0xe7, + 0x00, 0x00, 0x00, 0x20, 0x30, 0x00, 0x00, 0x20, 0xb8, 0x86, 0x00, 0x00, + 0x30, 0x00, 0x00, 0x20, 0xd4, 0x10, 0x00, 0x20, 0x10, 0xb5, 0x00, 0xf0, + 0x58, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x00, 0xf0, 0x49, 0xf8, 0x10, 0xbd, + 0xf7, 0xb5, 0x13, 0x48, 0x01, 0x22, 0x84, 0x46, 0x12, 0x49, 0x13, 0x4c, + 0x8e, 0x68, 0x63, 0x68, 0x05, 0x68, 0x9b, 0x0e, 0x13, 0x40, 0x01, 0x92, + 0x88, 0x68, 0x62, 0x68, 0x01, 0x9f, 0x92, 0x0e, 0x3a, 0x40, 0x67, 0x46, + 0x3f, 0x68, 0x93, 0x42, 0x0e, 0xd1, 0xbd, 0x42, 0x0c, 0xd1, 0x86, 0x42, + 0x0a, 0xd3, 0x5b, 0x19, 0xfa, 0x25, 0x48, 0x68, 0xad, 0x00, 0x86, 0x1b, + 0x07, 0x48, 0x6b, 0x43, 0x70, 0x43, 0x00, 0x0d, 0xc0, 0x18, 0xfe, 0xbd, + 0x3d, 0x00, 0x13, 0x00, 0x06, 0x00, 0xe3, 0xe7, 0xd0, 0x10, 0x00, 0x20, + 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, 0x55, 0x55, 0x00, 0x00, + 0x70, 0xb5, 0x04, 0x1e, 0x10, 0xd0, 0xff, 0xf7, 0xcb, 0xff, 0x05, 0x00, + 0x00, 0xf0, 0x1a, 0xf8, 0xff, 0xf7, 0xc6, 0xff, 0x05, 0x4b, 0x40, 0x1b, + 0x98, 0x42, 0xf7, 0xd9, 0xfa, 0x23, 0x01, 0x3c, 0x9b, 0x00, 0xed, 0x18, + 0x00, 0x2c, 0xf3, 0xd1, 0x70, 0xbd, 0xc0, 0x46, 0xe7, 0x03, 0x00, 0x00, + 0x10, 0xb5, 0x03, 0x4a, 0x13, 0x68, 0x01, 0x33, 0x13, 0x60, 0x00, 0xf0, + 0x4d, 0xfa, 0x10, 0xbd, 0xd0, 0x10, 0x00, 0x20, 0x70, 0x47, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x00, 0x1e, 0x22, 0x70, 0xb5, 0x46, 0x48, 0x47, 0x49, + 0x43, 0x68, 0x93, 0x43, 0x1c, 0x3a, 0x13, 0x43, 0x43, 0x60, 0x08, 0x23, + 0x8c, 0x69, 0x23, 0x43, 0x8b, 0x61, 0x43, 0x4c, 0x43, 0x4b, 0x9c, 0x82, + 0x9c, 0x8a, 0x14, 0x43, 0x9c, 0x82, 0xdc, 0x68, 0x14, 0x42, 0xfc, 0xd0, + 0x01, 0x24, 0x40, 0x4a, 0x14, 0x70, 0x15, 0x78, 0x25, 0x42, 0x03, 0xd0, + 0x55, 0x78, 0x6d, 0xb2, 0x00, 0x2d, 0xf8, 0xdb, 0x01, 0x24, 0x94, 0x60, + 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x39, 0x4c, 0x54, 0x60, + 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x82, 0x24, 0xe4, 0x01, + 0x54, 0x80, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x02, 0x24, + 0x9c, 0x84, 0x0e, 0x34, 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x31, 0x4c, + 0xdc, 0x62, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x9d, 0x8c, + 0x2e, 0x4c, 0x2c, 0x43, 0x9c, 0x84, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x02, 0x24, 0x9d, 0x8c, 0x80, 0x26, 0x2c, 0x43, 0x9c, 0x84, + 0x40, 0x24, 0xdd, 0x68, 0x35, 0x42, 0xfc, 0xd0, 0xdd, 0x68, 0x25, 0x42, + 0xf9, 0xd0, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x00, 0x24, + 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x21, 0x4c, + 0x54, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x1c, 0x6a, + 0x1e, 0x4d, 0x2c, 0x40, 0x80, 0x25, 0x1c, 0x62, 0x1c, 0x6a, 0xac, 0x43, + 0x1c, 0x62, 0x03, 0x23, 0x93, 0x60, 0x1b, 0x4b, 0x53, 0x60, 0x53, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x00, 0x23, 0xff, 0x24, 0x0b, 0x72, + 0x17, 0x4a, 0x4b, 0x72, 0x8b, 0x72, 0xcb, 0x72, 0x16, 0x4b, 0x1a, 0x60, + 0x16, 0x4b, 0x17, 0x4a, 0x1b, 0x68, 0x11, 0x68, 0x9a, 0x06, 0x5b, 0x01, + 0xc9, 0x0e, 0x23, 0x40, 0x52, 0x0f, 0x12, 0x02, 0x0b, 0x43, 0x13, 0x43, + 0x12, 0x4a, 0x13, 0x85, 0x80, 0x23, 0x42, 0x68, 0x13, 0x43, 0x43, 0x60, + 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, 0x00, 0x04, 0x00, 0x40, + 0x0c, 0x06, 0x00, 0x00, 0x00, 0x08, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, + 0x01, 0x05, 0x01, 0x00, 0xb9, 0x05, 0xff, 0x7d, 0x04, 0x0a, 0x00, 0x00, + 0x00, 0x07, 0x03, 0x00, 0xff, 0xfc, 0xff, 0xff, 0x03, 0x06, 0x01, 0x00, + 0x00, 0x6c, 0xdc, 0x02, 0x00, 0x00, 0x00, 0x20, 0x24, 0x60, 0x80, 0x00, + 0x20, 0x60, 0x80, 0x00, 0x00, 0x40, 0x00, 0x42, 0xfa, 0x21, 0x31, 0x4b, + 0x10, 0xb5, 0x18, 0x68, 0x89, 0x00, 0x00, 0xf0, 0xd5, 0xf9, 0x2f, 0x4b, + 0x01, 0x38, 0x98, 0x42, 0x56, 0xd8, 0x2e, 0x49, 0x2e, 0x4a, 0x48, 0x60, + 0xc0, 0x20, 0x13, 0x6a, 0x00, 0x06, 0x1b, 0x02, 0x1b, 0x0a, 0x03, 0x43, + 0x13, 0x62, 0x00, 0x24, 0x07, 0x23, 0x8c, 0x60, 0x0b, 0x60, 0x80, 0x21, + 0x13, 0x6a, 0x09, 0x06, 0x1b, 0x02, 0x1b, 0x0a, 0x0b, 0x43, 0x13, 0x62, + 0xfc, 0x22, 0x25, 0x4b, 0x19, 0x6a, 0x0a, 0x43, 0x1a, 0x62, 0xfc, 0x22, + 0x19, 0x6a, 0x92, 0x01, 0x0a, 0x43, 0x1a, 0x62, 0xa0, 0x22, 0x19, 0x6a, + 0xd2, 0x02, 0x0a, 0x43, 0x1a, 0x62, 0x20, 0x00, 0x00, 0x21, 0x01, 0x34, + 0x00, 0xf0, 0x76, 0xf8, 0x0f, 0x2c, 0xf8, 0xd1, 0x1b, 0x4b, 0x1c, 0x00, + 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, 0x19, 0x4a, 0x5a, 0x80, + 0x19, 0x4b, 0x1a, 0x00, 0x59, 0x7e, 0xc9, 0x09, 0x01, 0x29, 0xfb, 0xd0, + 0xe4, 0x21, 0xc9, 0x00, 0x99, 0x80, 0x3f, 0x21, 0xd9, 0x70, 0x53, 0x7e, + 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0xc0, 0x23, 0x00, 0x20, 0x5b, 0x01, + 0x13, 0x61, 0x90, 0x70, 0x00, 0xf0, 0x24, 0xf8, 0x63, 0x78, 0x5b, 0xb2, + 0x00, 0x2b, 0xfb, 0xdb, 0x0d, 0x4b, 0x0e, 0x4a, 0x63, 0x80, 0xd3, 0x79, + 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0x41, 0x23, 0x53, 0x70, 0x10, 0xbd, + 0xfe, 0xe7, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, 0xff, 0xff, 0xff, 0x00, + 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, 0x00, 0x04, 0x00, 0x40, + 0x00, 0x0c, 0x00, 0x40, 0x1e, 0x40, 0x00, 0x00, 0x00, 0x40, 0x00, 0x42, + 0x21, 0x40, 0x00, 0x00, 0x00, 0x48, 0x00, 0x42, 0x16, 0x4a, 0x00, 0xb5, + 0x13, 0x00, 0x51, 0x7e, 0xc9, 0x09, 0x01, 0x29, 0xfb, 0xd0, 0x01, 0x38, + 0x04, 0x28, 0x16, 0xd8, 0x19, 0x69, 0x12, 0x4a, 0x0a, 0x40, 0x0f, 0x21, + 0x1a, 0x61, 0x5a, 0x78, 0x8a, 0x43, 0x00, 0xf0, 0x47, 0xf9, 0x03, 0x08, + 0x06, 0x0b, 0x03, 0x00, 0x11, 0x00, 0x01, 0x22, 0x0a, 0x43, 0x5a, 0x70, + 0x00, 0xbd, 0x11, 0x00, 0x03, 0x22, 0xf9, 0xe7, 0x11, 0x00, 0x02, 0x22, + 0xf6, 0xe7, 0xf0, 0x23, 0x11, 0x69, 0x1b, 0x05, 0x0b, 0x43, 0x0f, 0x21, + 0x13, 0x61, 0x53, 0x78, 0x8b, 0x43, 0x19, 0x00, 0x02, 0x23, 0x0b, 0x43, + 0x53, 0x70, 0xeb, 0xe7, 0x00, 0x40, 0x00, 0x42, 0xff, 0xff, 0xff, 0xf0, + 0x18, 0x23, 0x30, 0xb5, 0x1d, 0x00, 0x04, 0x00, 0x45, 0x43, 0x08, 0x20, + 0x20, 0x4a, 0x55, 0x19, 0x28, 0x56, 0x01, 0x30, 0x14, 0xd0, 0x03, 0x29, + 0x12, 0xd8, 0x08, 0x00, 0x63, 0x43, 0xd1, 0x56, 0xd3, 0x18, 0x00, 0xf0, + 0x15, 0xf9, 0x02, 0x28, 0x0e, 0x1b, 0x58, 0x68, 0xcb, 0x01, 0x02, 0x21, + 0x18, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, + 0x82, 0x40, 0x5a, 0x60, 0x30, 0xbd, 0x58, 0x68, 0xcb, 0x01, 0x06, 0x21, + 0x12, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, + 0x82, 0x40, 0x5a, 0x60, 0x9a, 0x61, 0xf1, 0xe7, 0x58, 0x68, 0xcb, 0x01, + 0x06, 0x21, 0x0c, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, + 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x5a, 0x61, 0xe4, 0xe7, 0x58, 0x68, + 0xcb, 0x01, 0x02, 0x21, 0x05, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, + 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x9a, 0x60, 0xd8, 0xe7, 0xc0, 0x46, + 0x20, 0x83, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0x18, 0x23, 0xf0, 0xb5, + 0x08, 0x24, 0x58, 0x43, 0x11, 0x4a, 0x13, 0x18, 0x1c, 0x57, 0x01, 0x34, + 0x1b, 0xd0, 0x01, 0x26, 0x35, 0x00, 0x5f, 0x68, 0x83, 0x56, 0xbd, 0x40, + 0x0d, 0x4a, 0xdb, 0x01, 0x9a, 0x18, 0x90, 0x68, 0x05, 0x42, 0x0b, 0xd1, + 0x0c, 0x00, 0x60, 0x1e, 0x84, 0x41, 0xd2, 0x19, 0x40, 0x32, 0x10, 0x78, + 0x34, 0x40, 0x03, 0x36, 0xa4, 0x00, 0xb0, 0x43, 0x20, 0x43, 0x10, 0x70, + 0x04, 0x4a, 0x9b, 0x18, 0x00, 0x29, 0x01, 0xd1, 0x5d, 0x61, 0xf0, 0xbd, + 0x9d, 0x61, 0xfc, 0xe7, 0x20, 0x83, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x18, 0x22, 0x42, 0x43, 0xf8, 0xb5, 0x2c, 0x4e, 0x03, 0x00, 0xb2, 0x18, + 0x12, 0x7a, 0x52, 0xb2, 0x14, 0x00, 0x01, 0x32, 0x0e, 0xd0, 0x48, 0x1c, + 0x00, 0x24, 0x0c, 0x28, 0x0a, 0xd8, 0x00, 0xf0, 0x9f, 0xf8, 0x07, 0x1f, + 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x0b, 0x0b, 0x0b, 0x0b, 0x00, + 0x01, 0x24, 0x64, 0x42, 0x20, 0x00, 0xf8, 0xbd, 0x09, 0x29, 0x05, 0xd1, + 0x00, 0x21, 0x18, 0x00, 0xff, 0xf7, 0x66, 0xff, 0x00, 0x24, 0xf5, 0xe7, + 0x0a, 0x29, 0x01, 0xd1, 0x08, 0x39, 0xf6, 0xe7, 0x00, 0x24, 0x0b, 0x29, + 0xee, 0xd1, 0x0a, 0x39, 0x18, 0x00, 0xff, 0xf7, 0x59, 0xff, 0xe9, 0xe7, + 0x18, 0x22, 0x53, 0x43, 0xf2, 0x18, 0x55, 0x68, 0x01, 0x20, 0x2c, 0x00, + 0xf3, 0x56, 0x13, 0x4a, 0xdb, 0x01, 0x6e, 0x08, 0x9b, 0x18, 0xc9, 0xb2, + 0x04, 0x40, 0x9e, 0x19, 0x00, 0x2c, 0x0d, 0xd0, 0x0f, 0x24, 0x30, 0x36, + 0x32, 0x78, 0x09, 0x01, 0x22, 0x40, 0x11, 0x43, 0xc9, 0xb2, 0x5b, 0x19, + 0x31, 0x70, 0x40, 0x33, 0x1a, 0x78, 0x10, 0x43, 0x18, 0x70, 0xd3, 0xe7, + 0x32, 0x00, 0x0f, 0x27, 0x30, 0x32, 0x16, 0x78, 0x5b, 0x19, 0xbe, 0x43, + 0x31, 0x43, 0x11, 0x70, 0x40, 0x33, 0x1a, 0x78, 0x10, 0x43, 0x18, 0x70, + 0xbe, 0xe7, 0xc0, 0x46, 0x20, 0x83, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0xf7, 0xb5, 0x06, 0x00, 0x0d, 0x00, 0x0c, 0x00, 0x8b, 0x18, 0x01, 0x93, + 0x01, 0x9b, 0x67, 0x1b, 0x9c, 0x42, 0x07, 0xd0, 0x33, 0x68, 0x21, 0x78, + 0x1b, 0x68, 0x30, 0x00, 0x98, 0x47, 0x01, 0x34, 0x00, 0x28, 0xf3, 0xd1, + 0x38, 0x00, 0xfe, 0xbd, 0x16, 0x4a, 0x10, 0xb5, 0x13, 0x68, 0x59, 0x1c, + 0x26, 0xd0, 0x01, 0x3b, 0x13, 0x60, 0x00, 0x2b, 0x22, 0xd1, 0x72, 0xb6, + 0x12, 0x4b, 0x13, 0x4a, 0x04, 0x33, 0x93, 0x42, 0x13, 0xd9, 0x12, 0x4a, + 0x01, 0x21, 0x10, 0x00, 0x14, 0x7d, 0x0c, 0x42, 0xfc, 0xd0, 0x20, 0x21, + 0x14, 0x8b, 0xff, 0x31, 0x9b, 0x08, 0x5b, 0x00, 0x21, 0x43, 0x11, 0x83, + 0xd3, 0x61, 0x0c, 0x4b, 0x13, 0x80, 0x01, 0x23, 0x02, 0x7d, 0x1a, 0x42, + 0xfc, 0xd0, 0xbf, 0xf3, 0x4f, 0x8f, 0x09, 0x4b, 0x09, 0x4a, 0xda, 0x60, + 0xbf, 0xf3, 0x4f, 0x8f, 0xc0, 0x46, 0xfd, 0xe7, 0x10, 0xbd, 0xc0, 0x46, + 0x04, 0x00, 0x00, 0x20, 0x00, 0x20, 0x00, 0x00, 0x03, 0x02, 0x00, 0x00, + 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, 0x00, 0xed, 0x00, 0xe0, + 0x04, 0x00, 0xfa, 0x05, 0x02, 0xb4, 0x71, 0x46, 0x49, 0x08, 0x49, 0x00, + 0x09, 0x5c, 0x49, 0x00, 0x8e, 0x44, 0x02, 0xbc, 0x70, 0x47, 0xc0, 0x46, + 0x00, 0x22, 0x43, 0x08, 0x8b, 0x42, 0x74, 0xd3, 0x03, 0x09, 0x8b, 0x42, + 0x5f, 0xd3, 0x03, 0x0a, 0x8b, 0x42, 0x44, 0xd3, 0x03, 0x0b, 0x8b, 0x42, + 0x28, 0xd3, 0x03, 0x0c, 0x8b, 0x42, 0x0d, 0xd3, 0xff, 0x22, 0x09, 0x02, + 0x12, 0xba, 0x03, 0x0c, 0x8b, 0x42, 0x02, 0xd3, 0x12, 0x12, 0x09, 0x02, + 0x65, 0xd0, 0x03, 0x0b, 0x8b, 0x42, 0x19, 0xd3, 0x00, 0xe0, 0x09, 0x0a, + 0xc3, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x03, 0xc0, 0x1a, 0x52, 0x41, + 0x83, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x03, 0xc0, 0x1a, 0x52, 0x41, + 0x43, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x03, 0xc0, 0x1a, 0x52, 0x41, + 0x03, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x03, 0xc0, 0x1a, 0x52, 0x41, + 0xc3, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x02, 0xc0, 0x1a, 0x52, 0x41, + 0x83, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x02, 0xc0, 0x1a, 0x52, 0x41, + 0x43, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x02, 0xc0, 0x1a, 0x52, 0x41, + 0x03, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x02, 0xc0, 0x1a, 0x52, 0x41, + 0xcd, 0xd2, 0xc3, 0x09, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x01, 0xc0, 0x1a, + 0x52, 0x41, 0x83, 0x09, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x01, 0xc0, 0x1a, + 0x52, 0x41, 0x43, 0x09, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x01, 0xc0, 0x1a, + 0x52, 0x41, 0x03, 0x09, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x01, 0xc0, 0x1a, + 0x52, 0x41, 0xc3, 0x08, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x00, 0xc0, 0x1a, + 0x52, 0x41, 0x83, 0x08, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x00, 0xc0, 0x1a, + 0x52, 0x41, 0x43, 0x08, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x00, 0xc0, 0x1a, + 0x52, 0x41, 0x41, 0x1a, 0x00, 0xd2, 0x01, 0x46, 0x52, 0x41, 0x10, 0x46, + 0x70, 0x47, 0xff, 0xe7, 0x01, 0xb5, 0x00, 0x20, 0x00, 0xf0, 0x06, 0xf8, + 0x02, 0xbd, 0xc0, 0x46, 0x00, 0x29, 0xf7, 0xd0, 0x76, 0xe7, 0x70, 0x47, + 0x70, 0x47, 0xc0, 0x46, 0x70, 0xb5, 0x00, 0x26, 0x0c, 0x4d, 0x0d, 0x4c, + 0x64, 0x1b, 0xa4, 0x10, 0xa6, 0x42, 0x09, 0xd1, 0x00, 0x26, 0x00, 0xf0, + 0x4f, 0xf8, 0x0a, 0x4d, 0x0a, 0x4c, 0x64, 0x1b, 0xa4, 0x10, 0xa6, 0x42, + 0x05, 0xd1, 0x70, 0xbd, 0xb3, 0x00, 0xeb, 0x58, 0x98, 0x47, 0x01, 0x36, + 0xee, 0xe7, 0xb3, 0x00, 0xeb, 0x58, 0x98, 0x47, 0x01, 0x36, 0xf2, 0xe7, + 0x08, 0x00, 0x00, 0x20, 0x08, 0x00, 0x00, 0x20, 0x08, 0x00, 0x00, 0x20, + 0x24, 0x00, 0x00, 0x20, 0x00, 0x23, 0x10, 0xb5, 0x9a, 0x42, 0x00, 0xd1, + 0x10, 0xbd, 0xcc, 0x5c, 0xc4, 0x54, 0x01, 0x33, 0xf8, 0xe7, 0x03, 0x00, + 0x12, 0x18, 0x93, 0x42, 0x00, 0xd1, 0x70, 0x47, 0x19, 0x70, 0x01, 0x33, + 0xf9, 0xe7, 0x02, 0x78, 0x0b, 0x78, 0x00, 0x2a, 0x03, 0xd0, 0x01, 0x30, + 0x01, 0x31, 0x9a, 0x42, 0xf7, 0xd0, 0xd0, 0x1a, 0x70, 0x47, 0x00, 0x23, + 0xc2, 0x5c, 0x01, 0x33, 0x00, 0x2a, 0xfb, 0xd1, 0x58, 0x1e, 0x70, 0x47, + 0x30, 0xb5, 0x05, 0x00, 0x00, 0x2a, 0x00, 0xd1, 0x30, 0xbd, 0x0c, 0x78, + 0x01, 0x3a, 0x6b, 0x1c, 0x2c, 0x70, 0x01, 0x31, 0x00, 0x2c, 0x05, 0xd1, + 0x9a, 0x18, 0x9a, 0x42, 0xf4, 0xd0, 0x1c, 0x70, 0x01, 0x33, 0xfa, 0xe7, + 0x1d, 0x00, 0xed, 0xe7, 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, + 0x9e, 0x46, 0x70, 0x47, 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, + 0x9e, 0x46, 0x70, 0x47, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x2e, 0x42, + 0x49, 0x4e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, + 0x40, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x16, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x00, 0x04, 0x00, 0x04, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x17, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x01, 0x04, 0x01, 0x04, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0a, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x12, 0x00, 0x00, 0x01, 0x00, 0x01, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0b, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x13, 0x00, 0x01, 0x01, 0x01, 0x01, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x0a, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x00, 0x05, 0x00, 0x05, 0x0a, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x0b, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x01, 0x05, 0x01, 0x05, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x14, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x02, 0x00, 0x02, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x15, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x03, 0x00, 0x03, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x00, 0x02, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x11, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x13, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x01, 0x03, 0x01, 0x03, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x10, 0x00, 0xff, 0xff, 0xff, 0xff, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x09, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x11, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x17, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x16, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x0a, 0x00, 0xff, 0xff, 0xff, 0xff, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x0b, 0x00, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x05, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x05, 0x00, 0x01, 0x00, 0x01, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x06, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x07, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x07, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x18, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x19, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x12, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0c, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0d, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0e, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0f, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x1b, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x02, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x09, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x01, 0x04, 0x01, 0x04, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x1c, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x41, 0x74, 0x00, 0x00, 0xcd, 0x7a, 0x00, 0x00, + 0x67, 0x73, 0x00, 0x00, 0x23, 0x73, 0x00, 0x00, 0x3d, 0x73, 0x00, 0x00, + 0xf5, 0x74, 0x00, 0x00, 0x7d, 0x70, 0x00, 0x00, 0x6d, 0x70, 0x00, 0x00, + 0x01, 0x71, 0x00, 0x00, 0x97, 0x70, 0x00, 0x00, 0x67, 0x70, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x40, 0x42, 0x0f, 0x00, 0xff, 0xff, 0xff, 0xff, + 0xdd, 0x20, 0x00, 0x00, 0x25, 0x22, 0x00, 0x00, 0x39, 0x22, 0x00, 0x00, + 0xa5, 0x23, 0x00, 0x00, 0x3d, 0x26, 0x00, 0x00, 0x41, 0x6c, 0x00, 0x00, + 0xc9, 0x6c, 0x00, 0x00, 0xb5, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00 diff --git a/libraries/SFU/src/boot/mkrzero.h b/libraries/SFU/src/boot/mkrzero.h new file mode 100644 index 0000000..f8a0df1 --- /dev/null +++ b/libraries/SFU/src/boot/mkrzero.h @@ -0,0 +1,2174 @@ + 0x00, 0x80, 0x00, 0x20, 0x9d, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0xf1, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x89, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0xa5, 0x6c, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, + 0x85, 0x74, 0x00, 0x00, 0x85, 0x74, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0x30, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xb4, 0x85, 0x00, 0x00, 0x04, 0x4b, 0x10, 0xb5, 0x00, 0x2b, 0x03, 0xd0, + 0x03, 0x49, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x10, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x00, 0x34, 0x00, 0x00, 0x20, 0xb4, 0x85, 0x00, 0x00, + 0xf0, 0xb5, 0x40, 0x4c, 0xa5, 0x44, 0x00, 0xaf, 0x05, 0xf0, 0x02, 0xfb, + 0x05, 0xf0, 0x68, 0xfd, 0x01, 0x20, 0x05, 0xf0, 0x27, 0xfa, 0x3c, 0x48, + 0x00, 0xf0, 0x8c, 0xf9, 0x3b, 0x4c, 0x20, 0x00, 0x00, 0xf0, 0x1c, 0xf9, + 0x00, 0x28, 0x5d, 0xd1, 0x20, 0x00, 0x02, 0xf0, 0x29, 0xfb, 0x00, 0x28, + 0x58, 0xd1, 0x20, 0x00, 0x02, 0xf0, 0x44, 0xf9, 0x0c, 0x20, 0x08, 0x23, + 0x34, 0x4a, 0x21, 0x00, 0x38, 0x18, 0x00, 0xf0, 0x23, 0xf9, 0x20, 0x00, + 0x02, 0xf0, 0x38, 0xf9, 0x05, 0x1e, 0x45, 0xd1, 0x0c, 0x23, 0x01, 0x00, + 0x02, 0x22, 0xf8, 0x18, 0x00, 0xf0, 0x42, 0xf9, 0x80, 0x21, 0x78, 0x60, + 0x09, 0x02, 0x2e, 0x00, 0x88, 0x42, 0x2c, 0xdd, 0x0c, 0x23, 0x2a, 0x00, + 0xf8, 0x18, 0x00, 0xf0, 0x37, 0xf9, 0x28, 0x4a, 0xa0, 0x21, 0x94, 0x46, + 0x7b, 0x68, 0x09, 0x02, 0x63, 0x44, 0x1a, 0x00, 0x25, 0x48, 0xa0, 0x25, + 0x80, 0x26, 0x7b, 0x60, 0x00, 0xf0, 0xd6, 0xf8, 0x2d, 0x02, 0xb6, 0x00, + 0x08, 0x23, 0xf8, 0x18, 0xc1, 0x18, 0x04, 0x33, 0x32, 0x00, 0xf8, 0x18, + 0x00, 0xf0, 0x14, 0xf9, 0x08, 0x22, 0xb9, 0x18, 0x8a, 0x18, 0x33, 0x00, + 0x29, 0x00, 0x1b, 0x48, 0x00, 0xf0, 0x74, 0xf8, 0x80, 0x22, 0x1a, 0x4b, + 0x92, 0x00, 0xeb, 0x18, 0xad, 0x18, 0x7a, 0x68, 0x93, 0x42, 0xe7, 0xdb, + 0x01, 0x26, 0x0c, 0x23, 0xf8, 0x18, 0x00, 0xf0, 0x17, 0xf9, 0x00, 0x2e, + 0x03, 0xd0, 0x10, 0x49, 0x20, 0x00, 0x02, 0xf0, 0x55, 0xfa, 0x20, 0x00, + 0x02, 0xf0, 0xca, 0xf8, 0x0c, 0x23, 0xf8, 0x18, 0x00, 0xf0, 0x14, 0xf9, + 0xa0, 0x23, 0x1b, 0x02, 0x1a, 0x68, 0x82, 0xf3, 0x08, 0x88, 0x0c, 0x4a, + 0x93, 0x60, 0x0c, 0x4b, 0x1b, 0x68, 0x18, 0x47, 0x00, 0x20, 0xbd, 0x46, + 0x85, 0x23, 0x9b, 0x00, 0x9d, 0x44, 0xf0, 0xbd, 0xec, 0xfd, 0xff, 0xff, + 0xf4, 0x0b, 0x00, 0x20, 0x8c, 0x04, 0x00, 0x20, 0xa8, 0x7c, 0x00, 0x00, + 0x00, 0x80, 0xff, 0xff, 0x4c, 0x00, 0x00, 0x20, 0x00, 0x62, 0xff, 0xff, + 0x00, 0xed, 0x00, 0xe0, 0x04, 0xa0, 0x00, 0x00, 0x00, 0x22, 0x10, 0xb5, + 0x11, 0x00, 0x02, 0x48, 0x00, 0xf0, 0x1a, 0xf8, 0x10, 0xbd, 0xc0, 0x46, + 0x4c, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x05, 0x4a, 0x05, 0x49, 0x06, 0x48, + 0x00, 0xf0, 0x10, 0xf8, 0x00, 0x22, 0x05, 0x4b, 0x05, 0x49, 0x1a, 0x70, + 0x5a, 0x54, 0x10, 0xbd, 0x01, 0x04, 0x00, 0x00, 0x00, 0x7d, 0x00, 0x00, + 0x68, 0x04, 0x00, 0x20, 0x64, 0x00, 0x00, 0x20, 0x02, 0x04, 0x00, 0x00, + 0x30, 0xb5, 0x09, 0x4d, 0x09, 0x4c, 0xab, 0x68, 0x5b, 0x03, 0x5b, 0x0f, + 0x9b, 0x00, 0x1c, 0x59, 0x04, 0x60, 0xab, 0x68, 0x01, 0x61, 0x9b, 0xb2, + 0x43, 0x60, 0x63, 0x43, 0xa4, 0x00, 0x83, 0x60, 0xc4, 0x60, 0x42, 0x61, + 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, 0x00, 0x82, 0x00, 0x00, + 0xf7, 0xb5, 0x80, 0x26, 0x1a, 0x4d, 0x01, 0x91, 0x6f, 0x68, 0x03, 0x33, + 0x3e, 0x43, 0x9b, 0x08, 0x6e, 0x60, 0x00, 0x2b, 0x2b, 0xd0, 0x17, 0x4e, + 0x2e, 0x80, 0x2e, 0x7d, 0xf1, 0x07, 0xfc, 0xd5, 0x1e, 0x00, 0x07, 0x68, + 0x99, 0x1b, 0xbf, 0x08, 0x8f, 0x42, 0x19, 0xd9, 0x00, 0x2e, 0x17, 0xd0, + 0xff, 0x21, 0x17, 0x78, 0x8c, 0x43, 0x3c, 0x43, 0x0f, 0x49, 0x57, 0x78, + 0x0c, 0x40, 0x3f, 0x02, 0x3c, 0x43, 0x97, 0x78, 0x01, 0x3e, 0x39, 0x04, + 0x0c, 0x4f, 0x27, 0x40, 0xd4, 0x78, 0xbf, 0xb2, 0x0f, 0x43, 0x24, 0x06, + 0x01, 0x99, 0x3c, 0x43, 0x10, 0xc1, 0x01, 0x91, 0x04, 0x32, 0xe0, 0xe7, + 0x07, 0x4b, 0x2b, 0x80, 0x2b, 0x7d, 0xdb, 0x07, 0xfc, 0xd5, 0x33, 0x00, + 0xd1, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x44, 0xa5, 0xff, 0xff, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, 0x04, 0xa5, 0xff, 0xff, + 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, 0x1a, 0x80, 0x1a, 0x7d, + 0xd2, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x16, 0x00, + 0xe3, 0x68, 0x29, 0x00, 0x20, 0x00, 0xb3, 0x42, 0x05, 0xd2, 0xff, 0xf7, + 0xe7, 0xff, 0xe3, 0x68, 0xed, 0x18, 0xf6, 0x1a, 0xf4, 0xe7, 0xff, 0xf7, + 0xe1, 0xff, 0x70, 0xbd, 0x1f, 0xb5, 0x00, 0x21, 0x03, 0x91, 0x90, 0x21, + 0xc9, 0x00, 0x02, 0x91, 0xa1, 0x39, 0xff, 0x39, 0x41, 0x18, 0x98, 0x23, + 0x01, 0x91, 0x02, 0x00, 0x80, 0x21, 0x9b, 0x00, 0x00, 0x91, 0xc3, 0x18, + 0x60, 0x32, 0x02, 0x49, 0x01, 0xf0, 0x9c, 0xff, 0x05, 0xb0, 0x00, 0xbd, + 0x80, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, 0x08, 0x00, 0x11, 0x00, + 0x1a, 0x00, 0x00, 0x23, 0x02, 0xf0, 0x16, 0xf8, 0x01, 0x00, 0x20, 0x00, + 0x00, 0xf0, 0x3a, 0xf8, 0x20, 0x00, 0x10, 0xbd, 0x03, 0x4b, 0x04, 0x4a, + 0x1a, 0x60, 0x04, 0x4a, 0x5a, 0x60, 0x04, 0x4a, 0x9a, 0x60, 0x70, 0x47, + 0x80, 0x04, 0x00, 0x20, 0x01, 0x26, 0x00, 0x00, 0x15, 0x26, 0x00, 0x00, + 0x29, 0x26, 0x00, 0x00, 0x10, 0xb5, 0x0c, 0x00, 0x13, 0x00, 0x00, 0x22, + 0x81, 0x5e, 0x22, 0x00, 0x01, 0x48, 0x02, 0xf0, 0x87, 0xf8, 0x10, 0xbd, + 0x8c, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x0c, 0x00, 0x13, 0x00, 0x00, 0x22, + 0x81, 0x5e, 0x22, 0x00, 0x01, 0x48, 0x02, 0xf0, 0xdd, 0xf8, 0x10, 0xbd, + 0x8c, 0x04, 0x00, 0x20, 0x10, 0xb5, 0x00, 0x23, 0xc1, 0x5e, 0x02, 0x48, + 0x02, 0xf0, 0x9c, 0xf9, 0x10, 0xbd, 0xc0, 0x46, 0x8c, 0x04, 0x00, 0x20, + 0x10, 0xb5, 0x04, 0x00, 0xff, 0xf7, 0xf2, 0xff, 0x20, 0x00, 0x10, 0xbd, + 0x01, 0x80, 0x70, 0x47, 0x10, 0xb5, 0x00, 0x21, 0x40, 0x68, 0x05, 0xf0, + 0x6b, 0xfa, 0x10, 0xbd, 0x10, 0xb5, 0x01, 0x21, 0x40, 0x68, 0x05, 0xf0, + 0x65, 0xfa, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x68, 0x04, 0xf0, + 0xb9, 0xfb, 0x01, 0x21, 0x60, 0x68, 0x05, 0xf0, 0x0f, 0xfa, 0x20, 0x00, + 0xff, 0xf7, 0xee, 0xff, 0x10, 0xbd, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x00, + 0xff, 0xf7, 0xe2, 0xff, 0x09, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, + 0xcf, 0xfb, 0x05, 0x21, 0x20, 0x68, 0x04, 0xf0, 0xe7, 0xfb, 0x00, 0x21, + 0x20, 0x68, 0x04, 0xf0, 0xe3, 0xfb, 0x05, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0xd7, 0xff, 0x28, 0x00, 0x70, 0xbd, 0xc0, 0x46, 0xec, 0x0b, 0x00, 0x20, + 0x10, 0xb5, 0xff, 0xf7, 0xe3, 0xff, 0x01, 0x23, 0x18, 0x40, 0x10, 0xbd, + 0xf7, 0xb5, 0x04, 0x00, 0x0e, 0x00, 0x15, 0x00, 0x10, 0x27, 0x01, 0x93, + 0x20, 0x00, 0xff, 0xf7, 0xf1, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x3b, 0x00, + 0x01, 0x3b, 0xfd, 0xd1, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xb4, 0xff, + 0x12, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, 0xa1, 0xfb, 0x03, 0x21, + 0x20, 0x68, 0x04, 0xf0, 0xb9, 0xfb, 0x31, 0x0c, 0xc9, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0xb4, 0xfb, 0x31, 0x0a, 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, + 0xaf, 0xfb, 0xf1, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0xab, 0xfb, 0x01, 0x9b, + 0xee, 0x18, 0xb5, 0x42, 0x06, 0xd0, 0x00, 0x21, 0x20, 0x68, 0x04, 0xf0, + 0xa3, 0xfb, 0x28, 0x70, 0x01, 0x35, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, + 0x95, 0xff, 0xf7, 0xbd, 0xec, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, + 0xff, 0xf7, 0x88, 0xff, 0x06, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, + 0x75, 0xfb, 0x06, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x8d, 0xfb, 0x20, 0x00, + 0xff, 0xf7, 0x82, 0xff, 0x10, 0xbd, 0xc0, 0x46, 0xec, 0x0b, 0x00, 0x20, + 0xf7, 0xb5, 0x04, 0x00, 0x0e, 0x00, 0x15, 0x00, 0x10, 0x27, 0x01, 0x93, + 0x20, 0x00, 0xff, 0xf7, 0xa3, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x3b, 0x00, + 0x01, 0x3b, 0xfd, 0xd1, 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xda, 0xff, + 0x20, 0x00, 0xff, 0xf7, 0x63, 0xff, 0x12, 0x4b, 0x20, 0x68, 0x06, 0xcb, + 0x04, 0xf0, 0x50, 0xfb, 0x02, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x68, 0xfb, + 0x31, 0x0c, 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x63, 0xfb, 0x31, 0x0a, + 0xc9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x5e, 0xfb, 0xf1, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0x5a, 0xfb, 0x01, 0x9b, 0xee, 0x18, 0xb5, 0x42, 0x05, 0xd0, + 0x29, 0x78, 0x20, 0x68, 0x04, 0xf0, 0x52, 0xfb, 0x01, 0x35, 0xf7, 0xe7, + 0x20, 0x00, 0xff, 0xf7, 0x45, 0xff, 0xf7, 0xbd, 0xec, 0x0b, 0x00, 0x20, + 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x10, 0x26, 0x20, 0x00, 0xff, 0xf7, + 0x69, 0xff, 0x00, 0x28, 0x03, 0xd0, 0x33, 0x00, 0x01, 0x3b, 0xfd, 0xd1, + 0xf6, 0xe7, 0x20, 0x00, 0xff, 0xf7, 0xa0, 0xff, 0x20, 0x00, 0xff, 0xf7, + 0x29, 0xff, 0x0d, 0x4b, 0x20, 0x68, 0x06, 0xcb, 0x04, 0xf0, 0x16, 0xfb, + 0x20, 0x21, 0x20, 0x68, 0x04, 0xf0, 0x2e, 0xfb, 0x29, 0x0c, 0xc9, 0xb2, + 0x20, 0x68, 0x04, 0xf0, 0x29, 0xfb, 0x29, 0x0a, 0xc9, 0xb2, 0x20, 0x68, + 0x04, 0xf0, 0x24, 0xfb, 0xe9, 0xb2, 0x20, 0x68, 0x04, 0xf0, 0x20, 0xfb, + 0x20, 0x00, 0xff, 0xf7, 0x15, 0xff, 0x70, 0xbd, 0xec, 0x0b, 0x00, 0x20, + 0x10, 0xb5, 0x0b, 0x00, 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, 0x40, 0xff, + 0x00, 0x20, 0x10, 0xbd, 0xf4, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x0b, 0x00, + 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, 0x84, 0xff, 0x00, 0x20, 0x10, 0xbd, + 0xf4, 0x0b, 0x00, 0x20, 0x10, 0xb5, 0x01, 0x00, 0x02, 0x48, 0xff, 0xf7, + 0xb7, 0xff, 0x00, 0x20, 0x10, 0xbd, 0xc0, 0x46, 0xf4, 0x0b, 0x00, 0x20, + 0x05, 0x4b, 0x06, 0x4a, 0x1a, 0x60, 0x00, 0x22, 0x5a, 0x71, 0x1a, 0x71, + 0x04, 0x4b, 0x05, 0x4a, 0x1a, 0x60, 0x05, 0x22, 0x5a, 0x60, 0x70, 0x47, + 0xec, 0x0b, 0x00, 0x20, 0x00, 0x1b, 0xb7, 0x00, 0xf4, 0x0b, 0x00, 0x20, + 0xfc, 0x0b, 0x00, 0x20, 0x01, 0x23, 0x8b, 0x40, 0xf7, 0xb5, 0x44, 0x6c, + 0x01, 0x93, 0x01, 0x9d, 0xa3, 0x68, 0x06, 0x00, 0x00, 0x20, 0x2b, 0x42, + 0x1c, 0xd0, 0x8a, 0x25, 0x6d, 0x00, 0x69, 0x43, 0x23, 0x69, 0x5d, 0x18, + 0x82, 0x42, 0x0f, 0xd0, 0x2a, 0x78, 0x57, 0xb2, 0x87, 0x42, 0x0b, 0xdb, + 0x01, 0x27, 0x3a, 0x42, 0x08, 0xd0, 0x0a, 0x00, 0x80, 0x21, 0x28, 0x89, + 0x14, 0x32, 0x9a, 0x18, 0x00, 0x02, 0x73, 0x68, 0x49, 0x00, 0x98, 0x47, + 0xa3, 0x68, 0x01, 0x9a, 0x93, 0x43, 0xa3, 0x60, 0x00, 0x23, 0x2b, 0x70, + 0xfe, 0xbd, 0xc3, 0x68, 0xf0, 0xb5, 0x84, 0x68, 0x02, 0x00, 0x23, 0x40, + 0x18, 0x1e, 0x17, 0xd0, 0x8a, 0x27, 0x00, 0x23, 0x15, 0x78, 0x7f, 0x00, + 0xab, 0x42, 0x01, 0xdb, 0x00, 0x20, 0x0f, 0xe0, 0x01, 0x20, 0x98, 0x40, + 0x04, 0x42, 0x0c, 0xd0, 0x38, 0x00, 0x58, 0x43, 0x16, 0x69, 0x30, 0x18, + 0x06, 0x78, 0x7f, 0x2e, 0x05, 0xd8, 0x06, 0x89, 0x8e, 0x42, 0x02, 0xd1, + 0x53, 0x68, 0x43, 0x60, 0xf0, 0xbd, 0x01, 0x33, 0xe8, 0xe7, 0x82, 0x68, + 0x01, 0x00, 0x30, 0xb5, 0x00, 0x20, 0x53, 0x1c, 0x13, 0xd0, 0x00, 0x23, + 0x01, 0x25, 0x08, 0x78, 0x83, 0x42, 0x01, 0xdb, 0x00, 0x20, 0x0c, 0xe0, + 0x2c, 0x00, 0x9c, 0x40, 0x14, 0x42, 0x09, 0xd1, 0x8a, 0x20, 0x40, 0x00, + 0x58, 0x43, 0x0b, 0x69, 0x22, 0x43, 0x18, 0x18, 0x4b, 0x68, 0x8a, 0x60, + 0x43, 0x60, 0x30, 0xbd, 0x01, 0x33, 0xeb, 0xe7, 0xf8, 0xb5, 0x44, 0x6c, + 0x07, 0x00, 0xe2, 0x68, 0xa3, 0x68, 0x00, 0x20, 0x13, 0x40, 0x9a, 0x42, + 0x0e, 0xd1, 0x23, 0x78, 0x01, 0x21, 0x9c, 0x46, 0x02, 0x00, 0x03, 0x00, + 0x49, 0x42, 0x62, 0x45, 0x07, 0xdb, 0x00, 0x20, 0x4b, 0x1c, 0x03, 0xd0, + 0x01, 0x22, 0x38, 0x00, 0xff, 0xf7, 0x80, 0xff, 0xf8, 0xbd, 0x8a, 0x26, + 0x76, 0x00, 0x56, 0x43, 0x25, 0x69, 0xae, 0x19, 0x70, 0x68, 0x65, 0x68, + 0x2d, 0x1a, 0x9d, 0x42, 0x04, 0xd9, 0x36, 0x78, 0x7f, 0x2e, 0x01, 0xd8, + 0x2b, 0x00, 0x11, 0x00, 0x01, 0x32, 0xe4, 0xe7, 0x10, 0xb5, 0x04, 0x00, + 0x40, 0x6c, 0xff, 0xf7, 0x92, 0xff, 0x00, 0x28, 0x04, 0xd0, 0x41, 0x78, + 0x00, 0x22, 0x20, 0x00, 0xff, 0xf7, 0x62, 0xff, 0x10, 0xbd, 0xf7, 0xb5, + 0x46, 0x6c, 0x1c, 0x00, 0x1b, 0x0a, 0x9b, 0xb2, 0x05, 0x00, 0x0f, 0x00, + 0x30, 0x00, 0x19, 0x00, 0x01, 0x93, 0xff, 0xf7, 0x7e, 0xff, 0x73, 0x68, + 0x01, 0x33, 0x73, 0x60, 0x00, 0x28, 0x10, 0xd0, 0x8a, 0x21, 0x43, 0x60, + 0x43, 0x78, 0x49, 0x00, 0x59, 0x43, 0xe4, 0xb2, 0x14, 0x34, 0x09, 0x19, + 0x34, 0x69, 0x08, 0x9a, 0x61, 0x18, 0x09, 0x98, 0x05, 0xf0, 0x22, 0xfa, + 0x00, 0x27, 0x38, 0x00, 0xfe, 0xbd, 0x03, 0x23, 0x1f, 0x40, 0x01, 0x2f, + 0x06, 0xd1, 0x2b, 0x68, 0x09, 0x9a, 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, + 0x07, 0x00, 0xf2, 0xe7, 0x28, 0x00, 0xff, 0xf7, 0x99, 0xff, 0x07, 0x00, + 0x68, 0x6c, 0xff, 0xf7, 0x78, 0xff, 0x00, 0x90, 0x00, 0x28, 0x24, 0xd0, + 0x02, 0x23, 0x6a, 0x46, 0x03, 0x70, 0x8a, 0x23, 0x92, 0x88, 0x5b, 0x00, + 0x02, 0x81, 0x42, 0x78, 0x80, 0x21, 0x5a, 0x43, 0x33, 0x69, 0x14, 0x32, + 0x9a, 0x18, 0x20, 0x00, 0xff, 0x23, 0x49, 0x00, 0x98, 0x43, 0x2b, 0x68, + 0x98, 0x47, 0x8a, 0x21, 0x49, 0x00, 0x00, 0x28, 0x00, 0xd0, 0x07, 0x00, + 0x00, 0x9b, 0xe4, 0xb2, 0x5b, 0x78, 0x14, 0x34, 0x59, 0x43, 0x09, 0x19, + 0x34, 0x69, 0x08, 0x9a, 0x61, 0x18, 0x09, 0x98, 0x05, 0xf0, 0xe6, 0xf9, + 0xc3, 0xe7, 0x2b, 0x68, 0x09, 0x9a, 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, + 0x00, 0x28, 0xc7, 0xd1, 0xbb, 0xe7, 0xf7, 0xb5, 0x47, 0x6c, 0x01, 0x91, + 0x19, 0x0a, 0x05, 0x00, 0x89, 0xb2, 0x38, 0x00, 0x1c, 0x00, 0xff, 0xf7, + 0x1c, 0xff, 0x06, 0x1e, 0x0c, 0xd0, 0x1c, 0x22, 0x01, 0x9b, 0x1a, 0x40, + 0x18, 0x2a, 0x07, 0xd0, 0x41, 0x78, 0x00, 0x2a, 0x0a, 0xd1, 0x9b, 0x07, + 0x08, 0xd0, 0x28, 0x00, 0xff, 0xf7, 0xe4, 0xfe, 0x6b, 0x68, 0x09, 0x9a, + 0x08, 0x99, 0x20, 0x00, 0x98, 0x47, 0x14, 0xe0, 0x8a, 0x23, 0x5b, 0x00, + 0x59, 0x43, 0xe0, 0xb2, 0x3b, 0x69, 0x14, 0x30, 0x40, 0x18, 0x18, 0x18, + 0x08, 0x9a, 0x09, 0x99, 0x05, 0xf0, 0xb2, 0xf9, 0x02, 0x22, 0x7b, 0x68, + 0x01, 0x33, 0x7b, 0x60, 0x73, 0x60, 0x33, 0x78, 0x13, 0x40, 0x18, 0x1e, + 0xe4, 0xd1, 0xfe, 0xbd, 0xf7, 0xb5, 0x42, 0x6c, 0x94, 0x68, 0xd3, 0x68, + 0x23, 0x40, 0x18, 0x1e, 0x09, 0xd0, 0x13, 0x78, 0x8a, 0x26, 0x01, 0x93, + 0x01, 0x25, 0x00, 0x23, 0x76, 0x00, 0x01, 0x98, 0x98, 0x42, 0x01, 0xdc, + 0x00, 0x20, 0xfe, 0xbd, 0x28, 0x00, 0x98, 0x40, 0x04, 0x42, 0x0b, 0xd0, + 0x30, 0x00, 0x58, 0x43, 0x17, 0x69, 0x38, 0x18, 0x07, 0x78, 0x7f, 0x2f, + 0x04, 0xd9, 0x07, 0x89, 0xbc, 0x46, 0xcf, 0x88, 0xbc, 0x45, 0xee, 0xd0, + 0x01, 0x33, 0xe8, 0xe7, 0x70, 0xb5, 0x0c, 0x1e, 0x0f, 0xd0, 0x30, 0x21, + 0xc5, 0x6a, 0x83, 0x6a, 0x69, 0x43, 0x1a, 0x1d, 0x5b, 0x18, 0x00, 0x21, + 0x04, 0x33, 0x9a, 0x42, 0x06, 0xd1, 0x61, 0x78, 0x00, 0x22, 0xff, 0xf7, + 0x93, 0xfe, 0x00, 0x23, 0x23, 0x81, 0x70, 0xbd, 0x00, 0x26, 0x95, 0x5f, + 0x00, 0x2d, 0x03, 0xd0, 0xd5, 0x69, 0xa5, 0x42, 0x00, 0xd1, 0xd1, 0x61, + 0x30, 0x32, 0xec, 0xe7, 0xf0, 0xb5, 0x47, 0x6c, 0x89, 0xb0, 0x06, 0x00, + 0x00, 0x2f, 0x36, 0xd0, 0x8a, 0x21, 0x80, 0x6c, 0x49, 0x00, 0x14, 0x38, + 0x05, 0xf0, 0xaa, 0xf8, 0x04, 0x1e, 0x2e, 0xd0, 0x00, 0x23, 0x01, 0x21, + 0x01, 0x93, 0x01, 0x9a, 0x01, 0x33, 0x52, 0x00, 0x0a, 0x43, 0x01, 0x92, + 0x9c, 0x42, 0xf8, 0xdc, 0x03, 0xad, 0x08, 0x22, 0x00, 0x21, 0x28, 0x00, + 0x05, 0xf0, 0x51, 0xf9, 0x3b, 0x00, 0x14, 0x33, 0x2b, 0x61, 0x01, 0x23, + 0x5b, 0x42, 0xab, 0x60, 0x01, 0x9b, 0x29, 0x00, 0x14, 0x22, 0x38, 0x00, + 0xeb, 0x60, 0x2c, 0x70, 0x05, 0xf0, 0x3a, 0xf9, 0x75, 0x6c, 0x8a, 0x26, + 0x2a, 0x78, 0x76, 0x00, 0x72, 0x43, 0x00, 0x21, 0x28, 0x69, 0x05, 0xf0, + 0x3a, 0xf9, 0xab, 0x68, 0xea, 0x68, 0xe4, 0xb2, 0x93, 0x43, 0xab, 0x60, + 0x00, 0x23, 0x9c, 0x42, 0x01, 0xdc, 0x09, 0xb0, 0xf0, 0xbd, 0x32, 0x00, + 0x5a, 0x43, 0x29, 0x69, 0x8a, 0x18, 0x53, 0x70, 0x01, 0x33, 0xf4, 0xe7, + 0xf0, 0xb5, 0x85, 0xb0, 0x06, 0x00, 0x0d, 0x00, 0x14, 0x00, 0x03, 0x93, + 0x00, 0x27, 0x68, 0x2a, 0x06, 0xd9, 0x10, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x05, 0xf0, 0x62, 0xf8, 0x01, 0x30, 0x87, 0xb2, 0x80, 0x21, 0x0a, 0x9b, + 0x09, 0x02, 0x00, 0x93, 0x29, 0x43, 0x00, 0x23, 0x3a, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0xfa, 0xfa, 0x00, 0x28, 0x11, 0xdb, 0x0a, 0x9b, 0x1d, 0x88, + 0x2d, 0x02, 0x00, 0x2f, 0x0e, 0xd1, 0x23, 0x00, 0x17, 0x33, 0x03, 0x9a, + 0x5b, 0x00, 0x01, 0x92, 0x02, 0x22, 0x5b, 0x19, 0x00, 0x92, 0x15, 0x21, + 0x00, 0x22, 0x30, 0x00, 0xff, 0xf7, 0xb1, 0xfe, 0x05, 0xb0, 0xf0, 0xbd, + 0x23, 0x1d, 0x68, 0x2c, 0xef, 0xd9, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x05, 0xf0, 0xbe, 0xf8, 0x0b, 0x1d, 0xe8, 0xe7, 0x30, 0xb5, 0x0e, 0x25, + 0x00, 0x23, 0x85, 0xb0, 0x6d, 0x44, 0x1a, 0x00, 0x00, 0x95, 0x04, 0x00, + 0x02, 0xf0, 0xd0, 0xfa, 0x0b, 0x4b, 0x98, 0x42, 0x12, 0xd0, 0x00, 0x28, + 0x0e, 0xdb, 0x0d, 0x22, 0xbf, 0x23, 0x6a, 0x44, 0x13, 0x70, 0x2b, 0x88, + 0x01, 0x92, 0x01, 0x22, 0x1b, 0x02, 0x00, 0x92, 0x04, 0x33, 0x00, 0x22, + 0x04, 0x21, 0x20, 0x00, 0xff, 0xf7, 0xeb, 0xfe, 0x05, 0xb0, 0x30, 0xbd, + 0x00, 0x20, 0xfb, 0xe7, 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x8b, 0xb0, + 0x04, 0x93, 0x10, 0xab, 0x1b, 0x88, 0x12, 0x25, 0x05, 0x93, 0x50, 0x4b, + 0x14, 0x00, 0x19, 0x43, 0x0e, 0x23, 0x04, 0xaa, 0x9b, 0x18, 0x19, 0x80, + 0x09, 0xab, 0xad, 0x18, 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x2b, 0x00, + 0x06, 0x00, 0x02, 0xf0, 0x65, 0xfa, 0x00, 0x28, 0x33, 0xdb, 0x09, 0x9b, + 0x2d, 0x88, 0x06, 0x93, 0x68, 0x2c, 0x30, 0xd9, 0x27, 0x00, 0x69, 0x3f, + 0x7c, 0x21, 0x38, 0x00, 0x04, 0xf0, 0xee, 0xff, 0x01, 0x30, 0x83, 0xb2, + 0x7c, 0x21, 0x38, 0x00, 0x03, 0x93, 0x05, 0xf0, 0x6d, 0xf8, 0x09, 0x91, + 0x32, 0x6a, 0x05, 0x9b, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, + 0x1b, 0x02, 0x00, 0x22, 0x15, 0x21, 0x30, 0x00, 0xff, 0xf7, 0x49, 0xfe, + 0x00, 0x28, 0x12, 0xdb, 0x06, 0x9b, 0x37, 0x6a, 0x2d, 0x01, 0xed, 0x18, + 0x04, 0xaa, 0x7b, 0x78, 0x39, 0x78, 0xd2, 0x89, 0x01, 0x35, 0x1b, 0x02, + 0xad, 0xb2, 0x0b, 0x43, 0x9a, 0x42, 0x0a, 0xd0, 0x29, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0x5c, 0xfb, 0x2e, 0x48, 0x0b, 0xb0, 0xf0, 0xbd, 0x00, 0x23, + 0x09, 0x94, 0x03, 0x93, 0xd8, 0xe7, 0xfb, 0x78, 0xba, 0x78, 0x1b, 0x02, + 0x13, 0x43, 0x03, 0x9a, 0x93, 0x42, 0x05, 0xd0, 0x29, 0x00, 0x30, 0x00, + 0x02, 0xf0, 0x4a, 0xfb, 0x26, 0x48, 0xec, 0xe7, 0x38, 0x22, 0x3b, 0x79, + 0x93, 0x43, 0xc0, 0x2b, 0x05, 0xd0, 0x29, 0x00, 0x30, 0x00, 0x02, 0xf0, + 0x3f, 0xfb, 0x22, 0x48, 0xe1, 0xe7, 0x03, 0x9b, 0x00, 0x2b, 0x2a, 0xd1, + 0x6b, 0x46, 0x64, 0x00, 0x1b, 0x8a, 0x3c, 0x19, 0xe3, 0x85, 0x80, 0x22, + 0x52, 0x00, 0x00, 0x92, 0x2b, 0x02, 0x01, 0x97, 0x00, 0x22, 0x07, 0x21, + 0x30, 0x00, 0xff, 0xf7, 0x68, 0xfe, 0x00, 0x28, 0xcd, 0xdb, 0x0f, 0x23, + 0x17, 0x4a, 0x2b, 0x40, 0x9b, 0x18, 0x0e, 0x22, 0x04, 0xa9, 0x52, 0x18, + 0x01, 0x92, 0x02, 0x22, 0x2d, 0x09, 0x5b, 0x00, 0x2d, 0x03, 0x00, 0x92, + 0x5b, 0x19, 0x00, 0x22, 0x04, 0x21, 0x30, 0x00, 0xff, 0xf7, 0x53, 0xfe, + 0x00, 0x28, 0xb8, 0xdb, 0x05, 0x99, 0x30, 0x00, 0x02, 0xf0, 0x10, 0xfb, + 0xb3, 0xe7, 0x68, 0x2c, 0x05, 0xd8, 0x64, 0x00, 0x6b, 0x46, 0x1b, 0x8a, + 0x3c, 0x19, 0x23, 0x81, 0xd1, 0xe7, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x04, 0xf0, 0xf2, 0xff, 0x4c, 0x00, 0xf3, 0xe7, 0x00, 0x80, 0xff, 0xff, + 0xbd, 0xd8, 0xff, 0xff, 0xbc, 0xd8, 0xff, 0xff, 0xbb, 0xd8, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x00, 0x24, 0x85, 0xb0, 0x0e, 0x00, + 0x1f, 0x00, 0x11, 0x88, 0x03, 0x93, 0x02, 0x94, 0x01, 0x94, 0x00, 0x94, + 0x23, 0x00, 0x05, 0x00, 0x02, 0xf0, 0x66, 0xfa, 0xa0, 0x42, 0x0a, 0xdb, + 0xfb, 0x21, 0x3a, 0x88, 0x33, 0x02, 0x12, 0x02, 0x00, 0x91, 0x05, 0x33, + 0x05, 0x32, 0x21, 0x00, 0x28, 0x00, 0x01, 0xf0, 0xe3, 0xff, 0x05, 0xb0, + 0xf0, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x93, 0xb0, 0x06, 0x91, 0x01, 0x33, + 0x11, 0x01, 0xcb, 0x18, 0xc4, 0x6c, 0x9b, 0xb2, 0x07, 0x00, 0x05, 0x93, + 0x00, 0x2c, 0x08, 0xd0, 0x10, 0x02, 0xf9, 0x68, 0x04, 0xf0, 0x32, 0xff, + 0x00, 0x23, 0x02, 0x00, 0x19, 0x00, 0x18, 0x00, 0xa0, 0x47, 0x05, 0x9b, + 0x0e, 0xad, 0x1b, 0x02, 0x08, 0x93, 0x05, 0x23, 0x01, 0x95, 0x00, 0x93, + 0x00, 0x22, 0x08, 0x9b, 0x15, 0x21, 0x38, 0x00, 0xff, 0xf7, 0x8f, 0xfd, + 0x04, 0x1e, 0x00, 0xda, 0xd5, 0xe0, 0x06, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0x81, 0xe0, 0x2b, 0x79, 0x7f, 0x2b, 0x00, 0xd9, 0x86, 0xe0, 0x06, 0x9b, + 0x1c, 0x00, 0x1d, 0x00, 0x04, 0x93, 0x06, 0x9b, 0x83, 0x4a, 0x01, 0x3b, + 0x9b, 0xb2, 0x93, 0x42, 0x00, 0xd9, 0x02, 0xe2, 0x81, 0x48, 0x06, 0x9b, + 0x02, 0x00, 0x0e, 0xae, 0x03, 0x43, 0x9b, 0xb2, 0x31, 0x88, 0x07, 0x93, + 0x33, 0x79, 0x0a, 0x43, 0x09, 0x90, 0x07, 0x98, 0x92, 0xb2, 0x82, 0x42, + 0x00, 0xd1, 0xb2, 0xe1, 0x5a, 0xb2, 0x00, 0x2a, 0x51, 0xda, 0x9a, 0x07, + 0x4f, 0xd4, 0x44, 0x22, 0x13, 0x42, 0x4c, 0xd0, 0x04, 0x25, 0x72, 0x88, + 0x1d, 0x40, 0x00, 0xd1, 0xee, 0xe0, 0x12, 0x23, 0x06, 0xa8, 0x1b, 0x18, + 0x0b, 0xad, 0x00, 0x93, 0x38, 0x00, 0x2b, 0x00, 0xff, 0xf7, 0x74, 0xfe, + 0x6f, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x3a, 0xd0, 0x00, 0x28, 0x00, 0xda, + 0x95, 0xe0, 0x2b, 0x88, 0x05, 0x9a, 0x93, 0x42, 0x33, 0xd1, 0x10, 0xad, + 0x2b, 0x00, 0x32, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0x72, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0x87, 0xe0, 0x12, 0x20, 0x06, 0xac, 0x00, 0x19, + 0x00, 0x88, 0x0e, 0xae, 0x2b, 0x88, 0x72, 0x88, 0x31, 0x88, 0x00, 0x90, + 0x38, 0x00, 0xff, 0xf7, 0xb1, 0xfe, 0x60, 0x4b, 0x04, 0x00, 0xc3, 0x18, + 0x02, 0x2b, 0x16, 0xd8, 0x29, 0x88, 0x38, 0x00, 0x02, 0xf0, 0x50, 0xfa, + 0x04, 0x1e, 0x70, 0xdb, 0x31, 0x88, 0x38, 0x00, 0xff, 0xf7, 0x7e, 0xfe, + 0x01, 0x23, 0xfd, 0x6c, 0x04, 0x00, 0x04, 0x93, 0x00, 0x2d, 0x06, 0xd0, + 0x00, 0x23, 0x32, 0x88, 0x18, 0x00, 0x06, 0x21, 0xa8, 0x47, 0x01, 0x23, + 0x04, 0x93, 0x00, 0x2c, 0x5d, 0xdb, 0xfc, 0x6c, 0x00, 0x2c, 0x04, 0xd0, + 0x00, 0x23, 0x05, 0x9a, 0x05, 0x21, 0x18, 0x00, 0xa0, 0x47, 0x05, 0x99, + 0x38, 0x00, 0x02, 0xf0, 0x2f, 0xfa, 0x04, 0x00, 0x92, 0xe1, 0x4b, 0x4b, + 0x06, 0x9a, 0x9a, 0x42, 0x00, 0xd0, 0x82, 0xe0, 0x2b, 0x79, 0xdb, 0x07, + 0x00, 0xd5, 0x7e, 0xe0, 0x04, 0x23, 0x2e, 0x79, 0x29, 0x88, 0x6a, 0x88, + 0x1e, 0x40, 0x4b, 0xd0, 0x06, 0xa8, 0x0e, 0x33, 0x1b, 0x18, 0x0b, 0xae, + 0x00, 0x93, 0x38, 0x00, 0x33, 0x00, 0xff, 0xf7, 0x0f, 0xfe, 0x3d, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x00, 0xd1, 0x6c, 0xe0, 0x00, 0x28, 0x30, 0xdb, + 0x33, 0x88, 0x05, 0x9a, 0x93, 0x42, 0x00, 0xd0, 0x60, 0xe0, 0x10, 0xae, + 0x33, 0x00, 0x2a, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0x0c, 0xff, + 0x04, 0x1e, 0x22, 0xdb, 0x06, 0xa8, 0x40, 0x8a, 0x33, 0x88, 0x6a, 0x88, + 0x29, 0x88, 0x00, 0x90, 0x38, 0x00, 0xff, 0xf7, 0x4f, 0xfe, 0x2f, 0x4b, + 0x04, 0x00, 0xc3, 0x18, 0x02, 0x2b, 0x17, 0xd8, 0x31, 0x88, 0x38, 0x00, + 0x02, 0xf0, 0xee, 0xf9, 0x04, 0x1e, 0x0e, 0xdb, 0x29, 0x88, 0x38, 0x00, + 0xff, 0xf7, 0x1c, 0xfe, 0xfe, 0x6c, 0x04, 0x00, 0x00, 0x2e, 0x04, 0xd0, + 0x00, 0x23, 0x06, 0x21, 0x18, 0x00, 0x2a, 0x88, 0xb0, 0x47, 0x00, 0x2c, + 0x34, 0xda, 0x20, 0x00, 0x13, 0xb0, 0xf0, 0xbd, 0xfe, 0x6c, 0x00, 0x2e, + 0xf7, 0xd0, 0x6b, 0x88, 0x2a, 0x88, 0x02, 0x21, 0x00, 0x20, 0xf1, 0xe7, + 0x1a, 0x4b, 0x00, 0x96, 0x19, 0x43, 0x89, 0xb2, 0x05, 0x9b, 0x38, 0x00, + 0x02, 0xf0, 0xd8, 0xf8, 0x17, 0x4b, 0x04, 0x00, 0x98, 0x42, 0xe6, 0xd1, + 0x29, 0x88, 0x14, 0x4b, 0x00, 0x96, 0x0b, 0x43, 0x99, 0xb2, 0x32, 0x00, + 0x33, 0x00, 0x38, 0x00, 0x02, 0xf0, 0x02, 0xf9, 0x04, 0x1e, 0x11, 0xd1, + 0x10, 0xab, 0x2a, 0x00, 0x05, 0x99, 0x38, 0x00, 0xff, 0xf7, 0xbe, 0xfe, + 0x04, 0x1e, 0xd4, 0xdb, 0xfb, 0x6c, 0x9c, 0x46, 0x00, 0x2b, 0x05, 0xd0, + 0x6b, 0x88, 0x2a, 0x88, 0x03, 0x21, 0x30, 0x00, 0x65, 0x46, 0xa8, 0x47, + 0x01, 0x23, 0x04, 0x93, 0x04, 0xe0, 0x00, 0x23, 0xf8, 0xe6, 0x01, 0x23, + 0x00, 0x24, 0x04, 0x93, 0x1d, 0x00, 0xf6, 0xe6, 0xfd, 0xff, 0x00, 0x00, + 0x00, 0x80, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, + 0xff, 0xff, 0x00, 0x00, 0x16, 0x26, 0x06, 0xab, 0xf6, 0x18, 0x00, 0x96, + 0x2b, 0x00, 0x07, 0x99, 0x38, 0x00, 0x02, 0xf0, 0x99, 0xf8, 0xc1, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x00, 0xd0, 0x75, 0xe0, 0x35, 0x80, 0x0e, 0xae, + 0x31, 0x88, 0x09, 0x9b, 0x0c, 0xad, 0x19, 0x43, 0x72, 0x88, 0x00, 0x23, + 0x89, 0xb2, 0x00, 0x95, 0x38, 0x00, 0x02, 0xf0, 0x87, 0xf8, 0xb8, 0x4b, + 0x04, 0x00, 0x98, 0x42, 0x68, 0xd1, 0x00, 0x23, 0x2b, 0x80, 0x2b, 0x88, + 0x00, 0x2b, 0x06, 0xd0, 0x16, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0x00, 0x2b, 0x00, 0xd0, 0x2d, 0xe7, 0x06, 0x9b, 0x06, 0xaa, 0x59, 0x04, + 0x1a, 0x23, 0x9b, 0x18, 0x00, 0x93, 0x00, 0x23, 0x49, 0x0c, 0x1a, 0x00, + 0x38, 0x00, 0x02, 0xf0, 0x6b, 0xf8, 0xaa, 0x4b, 0x04, 0x00, 0x98, 0x42, + 0x4f, 0xd1, 0x16, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x00, 0x22, 0x1a, 0x80, + 0x00, 0x23, 0x31, 0x88, 0x0d, 0xad, 0x49, 0x04, 0x1a, 0x00, 0x49, 0x0c, + 0x00, 0x95, 0x38, 0x00, 0x02, 0xf0, 0x58, 0xf8, 0xa0, 0x4b, 0x04, 0x00, + 0x98, 0x42, 0x3f, 0xd1, 0x00, 0x22, 0x0c, 0xab, 0x1a, 0x80, 0xf8, 0x23, + 0x16, 0x21, 0x10, 0xaa, 0x06, 0xa8, 0x13, 0x71, 0x09, 0x18, 0x73, 0x88, + 0x08, 0x88, 0x53, 0x80, 0x00, 0x28, 0x05, 0xd0, 0x1a, 0x21, 0x06, 0xac, + 0x09, 0x19, 0x09, 0x88, 0x00, 0x29, 0x2e, 0xd0, 0x29, 0x88, 0x00, 0x29, + 0x2b, 0xd0, 0x0c, 0xa9, 0x09, 0x88, 0x06, 0x91, 0x00, 0x29, 0x26, 0xd1, + 0x33, 0x88, 0x09, 0x99, 0x38, 0x00, 0x19, 0x43, 0x1e, 0x23, 0x11, 0x80, + 0x06, 0xa9, 0x5b, 0x18, 0x05, 0x99, 0xff, 0xf7, 0x29, 0xfe, 0xfd, 0x6c, + 0x04, 0x00, 0x00, 0x2d, 0x04, 0xd0, 0x73, 0x88, 0x32, 0x88, 0x03, 0x21, + 0x06, 0x98, 0xa8, 0x47, 0x00, 0x2c, 0x00, 0xda, 0x35, 0xe7, 0x01, 0x23, + 0x04, 0x93, 0xd4, 0xe6, 0x00, 0x28, 0x00, 0xdb, 0x87, 0xe7, 0x2e, 0xe7, + 0x00, 0x28, 0x96, 0xda, 0x2b, 0xe7, 0x00, 0x28, 0xb2, 0xda, 0x28, 0xe7, + 0x00, 0x28, 0xc0, 0xda, 0x25, 0xe7, 0x0c, 0xaa, 0x12, 0x88, 0x00, 0x2a, + 0x03, 0xd0, 0x2a, 0x88, 0x00, 0x2a, 0x00, 0xd1, 0xbf, 0xe6, 0x1a, 0x22, + 0x06, 0xa9, 0x52, 0x18, 0x12, 0x88, 0x00, 0x2a, 0x00, 0xd1, 0xb8, 0xe6, + 0x00, 0x28, 0x00, 0xd0, 0xb5, 0xe6, 0x6a, 0x46, 0xfd, 0x6c, 0x92, 0x8b, + 0x10, 0xac, 0x22, 0x80, 0x00, 0x2d, 0x02, 0xd0, 0x32, 0x88, 0x03, 0x21, + 0xa8, 0x47, 0x1e, 0x23, 0x06, 0xaa, 0x9b, 0x18, 0x05, 0x99, 0x22, 0x00, + 0x38, 0x00, 0xff, 0xf7, 0xe9, 0xfd, 0x04, 0x00, 0xc6, 0xe7, 0x69, 0x46, + 0x04, 0x22, 0x18, 0x20, 0x09, 0x5e, 0x1a, 0x40, 0x00, 0x29, 0x44, 0xda, + 0x00, 0x2a, 0x44, 0xd1, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0x94, 0xe6, + 0x9b, 0x07, 0x30, 0xd5, 0x12, 0x23, 0x06, 0xa9, 0x5b, 0x18, 0x0e, 0xae, + 0x72, 0x88, 0x06, 0x99, 0x00, 0x93, 0x38, 0x00, 0x0b, 0xab, 0xff, 0xf7, + 0xbd, 0xfc, 0x5d, 0x4b, 0x04, 0x00, 0x98, 0x42, 0xab, 0xd0, 0x00, 0x28, + 0x00, 0xda, 0xde, 0xe6, 0x01, 0x22, 0x06, 0xab, 0x04, 0x92, 0x9b, 0x8a, + 0x05, 0x9a, 0x93, 0x42, 0x00, 0xd0, 0x78, 0xe6, 0xfc, 0x6c, 0x00, 0x2c, + 0x04, 0xd0, 0x73, 0x88, 0x32, 0x88, 0x03, 0x21, 0x00, 0x20, 0xa0, 0x47, + 0xfd, 0x23, 0x01, 0x26, 0x10, 0xaa, 0x13, 0x70, 0x08, 0x9b, 0x01, 0x92, + 0x04, 0x33, 0x00, 0x96, 0x00, 0x22, 0x07, 0x21, 0x38, 0x00, 0xff, 0xf7, + 0xdc, 0xfb, 0x04, 0x00, 0x04, 0x96, 0x00, 0x2d, 0x00, 0xd0, 0x5e, 0xe6, + 0x00, 0x2c, 0x00, 0xd0, 0xb9, 0xe6, 0x04, 0x9c, 0x47, 0x4b, 0x67, 0x42, + 0x7c, 0x41, 0xe4, 0x18, 0xb3, 0xe6, 0x00, 0x2a, 0xba, 0xd1, 0x1a, 0x26, + 0x06, 0x9b, 0x0e, 0xad, 0x5b, 0x04, 0x5b, 0x0c, 0x09, 0x93, 0x06, 0xab, + 0xf6, 0x18, 0x6a, 0x88, 0x05, 0x9b, 0x00, 0x96, 0x09, 0x99, 0x38, 0x00, + 0x01, 0xf0, 0x8e, 0xff, 0x3b, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x4c, 0xd1, + 0x00, 0x23, 0x33, 0x80, 0x6a, 0x88, 0x0d, 0xad, 0x05, 0x9b, 0x00, 0x95, + 0x07, 0x99, 0x38, 0x00, 0x01, 0xf0, 0x80, 0xff, 0x34, 0x4b, 0x04, 0x00, + 0x98, 0x42, 0x41, 0xd1, 0x00, 0x23, 0x2b, 0x80, 0x1a, 0x23, 0x06, 0xaa, + 0x9b, 0x18, 0x28, 0x88, 0x1d, 0x88, 0xfc, 0x6c, 0x00, 0x2d, 0x3a, 0xd0, + 0x00, 0x28, 0x00, 0xd0, 0x25, 0xe6, 0x00, 0x2c, 0x04, 0xd0, 0x0e, 0xab, + 0x5b, 0x88, 0x06, 0x9a, 0x02, 0x21, 0xa0, 0x47, 0xf8, 0x23, 0x10, 0xaa, + 0x13, 0x71, 0x6b, 0x46, 0x1e, 0x26, 0x9b, 0x8b, 0x00, 0x25, 0x13, 0x80, + 0x0e, 0xab, 0x5b, 0x88, 0x07, 0x99, 0x53, 0x80, 0x06, 0xab, 0xf6, 0x18, + 0x01, 0x23, 0x02, 0x93, 0x2b, 0x00, 0x03, 0x96, 0x01, 0x95, 0x00, 0x95, + 0x38, 0x00, 0x01, 0xf0, 0xc1, 0xff, 0x04, 0x00, 0xa8, 0x42, 0x00, 0xda, + 0x61, 0xe6, 0xfb, 0x21, 0x32, 0x88, 0x08, 0x9b, 0x12, 0x02, 0x00, 0x91, + 0x05, 0x33, 0x05, 0x32, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, 0x3c, 0xfd, + 0x04, 0x00, 0xa8, 0x42, 0x00, 0xdb, 0xf4, 0xe5, 0x51, 0xe6, 0x00, 0x28, + 0xb2, 0xda, 0x4e, 0xe6, 0x00, 0x28, 0xbd, 0xda, 0x4b, 0xe6, 0x00, 0x28, + 0x00, 0xd1, 0xea, 0xe5, 0x0e, 0xab, 0x5b, 0x88, 0x00, 0x2c, 0x03, 0xd0, + 0x06, 0x9a, 0x03, 0x21, 0x28, 0x00, 0xa0, 0x47, 0xfc, 0x23, 0x10, 0xaa, + 0x13, 0x71, 0x6b, 0x46, 0x1e, 0x26, 0x9b, 0x8c, 0x00, 0x25, 0x13, 0x80, + 0x0e, 0xab, 0x5b, 0x88, 0x09, 0x99, 0x53, 0x80, 0x06, 0xab, 0xf6, 0x18, + 0x01, 0x23, 0x03, 0x96, 0x02, 0x93, 0x01, 0x95, 0x00, 0x95, 0x2b, 0x00, + 0xc2, 0xe7, 0xc0, 0x46, 0xee, 0xd8, 0xff, 0xff, 0xa9, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x8b, 0xb0, 0x05, 0x93, 0xc7, 0x6c, 0x43, 0x6a, 0x04, 0x00, + 0x03, 0x91, 0x16, 0x00, 0x11, 0x9d, 0x04, 0x93, 0x00, 0x2f, 0x08, 0xd0, + 0x10, 0x02, 0xe1, 0x68, 0x04, 0xf0, 0x5e, 0xfc, 0x00, 0x23, 0x02, 0x00, + 0x19, 0x00, 0x01, 0x20, 0xb8, 0x47, 0x03, 0x9b, 0x4f, 0x49, 0x50, 0x4a, + 0x5b, 0x18, 0x9b, 0xb2, 0x93, 0x42, 0x00, 0xd9, 0x94, 0xe0, 0x05, 0x22, + 0x05, 0x9b, 0x36, 0x01, 0x01, 0x33, 0xf6, 0x18, 0xb7, 0xb2, 0x08, 0xae, + 0x00, 0x92, 0x3b, 0x02, 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, + 0xff, 0xf7, 0xb1, 0xfa, 0x00, 0x28, 0x16, 0xdb, 0x39, 0x22, 0x33, 0x79, + 0x93, 0x43, 0x72, 0x88, 0x00, 0x2a, 0x12, 0xd1, 0x80, 0x2b, 0x6e, 0xd1, + 0xe5, 0x6c, 0x00, 0x2d, 0x04, 0xd0, 0x03, 0x9b, 0x3a, 0x00, 0x05, 0x21, + 0x01, 0x20, 0xa8, 0x47, 0x39, 0x00, 0x20, 0x00, 0x01, 0xf0, 0xc2, 0xff, + 0x00, 0x28, 0x00, 0xdb, 0x3a, 0x48, 0x05, 0x00, 0x6b, 0xe0, 0xc0, 0x2b, + 0xfa, 0xd0, 0x03, 0x9b, 0x38, 0x4a, 0x5e, 0x04, 0x94, 0x46, 0x00, 0x23, + 0x60, 0x6a, 0x76, 0x0c, 0x61, 0x46, 0xc2, 0x5a, 0x0a, 0x40, 0xb2, 0x42, + 0x12, 0xd1, 0x04, 0x9a, 0xd3, 0x5e, 0x00, 0x2b, 0x58, 0xda, 0x30, 0x4d, + 0x36, 0xe0, 0x02, 0x33, 0x9c, 0x42, 0x4f, 0xd1, 0x2b, 0x68, 0x04, 0x98, + 0x59, 0x00, 0x01, 0x33, 0x0a, 0x52, 0x7f, 0x2b, 0x00, 0xd9, 0x00, 0x23, + 0x2b, 0x60, 0x49, 0xe0, 0x80, 0x22, 0x02, 0x33, 0x52, 0x00, 0x93, 0x42, + 0xe2, 0xd1, 0x0e, 0x23, 0x04, 0xaa, 0x9b, 0x18, 0x00, 0x93, 0x00, 0x23, + 0x03, 0x99, 0x1a, 0x00, 0x20, 0x00, 0x01, 0xf0, 0x9b, 0xfe, 0x00, 0x28, + 0x0a, 0xd0, 0x22, 0x4b, 0x98, 0x42, 0x24, 0xd1, 0x69, 0x46, 0x2b, 0x68, + 0x04, 0x9a, 0x89, 0x89, 0x5b, 0x00, 0x99, 0x52, 0x01, 0x22, 0x04, 0xe0, + 0x2b, 0x68, 0x04, 0x9a, 0x5b, 0x00, 0x9e, 0x52, 0x02, 0x00, 0x2b, 0x68, + 0x01, 0x33, 0x7f, 0x2b, 0x00, 0xd9, 0x00, 0x23, 0x2b, 0x60, 0x18, 0x4d, + 0x00, 0x2a, 0x20, 0xd0, 0xe6, 0x6c, 0x00, 0x2e, 0x04, 0xd0, 0x03, 0x9b, + 0x3a, 0x00, 0x04, 0x21, 0x01, 0x20, 0xb0, 0x47, 0x39, 0x00, 0x20, 0x00, + 0x01, 0xf0, 0x66, 0xff, 0x00, 0x28, 0x12, 0xda, 0xa3, 0xe7, 0x00, 0x22, + 0x90, 0x42, 0xe4, 0xda, 0x9f, 0xe7, 0xc0, 0x2b, 0x9c, 0xd0, 0x03, 0x9b, + 0x09, 0x48, 0x5a, 0x04, 0x63, 0x6a, 0x52, 0x0c, 0x5c, 0x1c, 0xff, 0x34, + 0x19, 0x88, 0x01, 0x40, 0x91, 0x42, 0xa8, 0xd1, 0x03, 0x4d, 0x28, 0x00, + 0x0b, 0xb0, 0xf0, 0xbd, 0x00, 0x80, 0xff, 0xff, 0xfe, 0x7f, 0x00, 0x00, + 0xaa, 0xd8, 0xff, 0xff, 0xff, 0x7f, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xa9, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0xc4, 0x6c, 0x87, 0xb0, 0x06, 0x00, + 0x00, 0x2c, 0x04, 0xd0, 0x00, 0x23, 0x1a, 0x00, 0x19, 0x00, 0x18, 0x00, + 0xa0, 0x47, 0x00, 0x24, 0x14, 0x4b, 0x05, 0x94, 0x01, 0x93, 0x04, 0x94, + 0x23, 0x00, 0x03, 0x94, 0x02, 0x94, 0x00, 0x94, 0x22, 0x00, 0x21, 0x00, + 0x30, 0x00, 0x01, 0xf0, 0x5b, 0xfc, 0x0f, 0x4b, 0x05, 0x00, 0x98, 0x42, + 0x15, 0xd0, 0xa0, 0x42, 0x07, 0xd0, 0xf7, 0x6c, 0xa7, 0x42, 0x04, 0xd0, + 0x02, 0x00, 0x23, 0x00, 0x01, 0x21, 0x20, 0x00, 0xb8, 0x47, 0xf4, 0x6c, + 0x00, 0x2c, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, 0x19, 0x00, 0x52, 0x00, + 0x18, 0x00, 0xa0, 0x47, 0x28, 0x00, 0x07, 0xb0, 0xf0, 0xbd, 0x25, 0x00, + 0xf1, 0xe7, 0xc0, 0x46, 0x41, 0x2c, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0xc4, 0x6c, 0x97, 0xb0, 0x05, 0x00, 0x00, 0x2c, 0x04, 0xd0, + 0x00, 0x23, 0x02, 0x20, 0x1a, 0x00, 0x19, 0x00, 0xa0, 0x47, 0x00, 0x23, + 0x07, 0x93, 0x1c, 0x00, 0xb0, 0xe1, 0x80, 0x22, 0x00, 0x21, 0x52, 0x00, + 0x68, 0x6a, 0x04, 0xf0, 0x16, 0xfc, 0x07, 0x9b, 0x1b, 0x02, 0x0f, 0x93, + 0x00, 0x23, 0x0a, 0x93, 0xee, 0x68, 0x0a, 0x9b, 0x9e, 0x42, 0x09, 0xd8, + 0x00, 0x23, 0x06, 0x93, 0x06, 0x9b, 0x07, 0x9a, 0x5b, 0x00, 0xd3, 0x18, + 0x9b, 0xb2, 0x0a, 0x93, 0x00, 0x23, 0x0a, 0xe2, 0xeb, 0x6c, 0x05, 0x93, + 0x00, 0x2b, 0x13, 0xd0, 0x0a, 0x9b, 0x37, 0x01, 0x58, 0x04, 0x39, 0x00, + 0x04, 0xf0, 0x40, 0xfb, 0x31, 0x00, 0x04, 0xf0, 0x3d, 0xfb, 0x39, 0x00, + 0x06, 0x00, 0x0f, 0x98, 0x04, 0xf0, 0x38, 0xfb, 0x00, 0x23, 0x32, 0x18, + 0x19, 0x00, 0x02, 0x20, 0x05, 0x9e, 0xb0, 0x47, 0x0a, 0x9b, 0x1b, 0x01, + 0x01, 0x33, 0x9b, 0xb2, 0x06, 0x93, 0x0a, 0x9b, 0x01, 0x33, 0x1b, 0x01, + 0x0e, 0x93, 0x06, 0x9b, 0x0e, 0x9a, 0x93, 0x42, 0x01, 0xdb, 0x00, 0x23, + 0x69, 0xe1, 0x06, 0x9b, 0x00, 0x22, 0x1e, 0x02, 0x12, 0xab, 0x01, 0x93, + 0x05, 0x23, 0x15, 0x21, 0x00, 0x93, 0x28, 0x00, 0x33, 0x00, 0xff, 0xf7, + 0x86, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0xe5, 0xe0, 0x07, 0x9b, 0x06, 0x99, + 0x00, 0x22, 0x8b, 0x42, 0x07, 0xd8, 0xca, 0x0f, 0x07, 0x9b, 0xc6, 0x49, + 0x06, 0x98, 0x5b, 0x18, 0xd9, 0x17, 0x83, 0x42, 0x4a, 0x41, 0x06, 0x9b, + 0x07, 0x99, 0x58, 0x1a, 0x01, 0x21, 0x43, 0x08, 0x05, 0x93, 0x06, 0x9b, + 0x19, 0x40, 0x89, 0x00, 0x00, 0x2a, 0x0f, 0xd0, 0x12, 0xab, 0x1b, 0x79, + 0x5f, 0xb2, 0x00, 0x2f, 0x0a, 0xda, 0x01, 0x20, 0x03, 0x42, 0x07, 0xd1, + 0x6b, 0x6a, 0x05, 0x98, 0x1b, 0x18, 0x01, 0x20, 0x88, 0x40, 0x1f, 0x78, + 0x07, 0x43, 0x1f, 0x70, 0x12, 0xab, 0x1f, 0x79, 0x7b, 0xb2, 0x9c, 0x46, + 0x00, 0x23, 0x60, 0x46, 0x98, 0x42, 0x00, 0xdb, 0x22, 0xe1, 0x45, 0x20, + 0x07, 0x40, 0x40, 0x2f, 0x00, 0xd0, 0x1d, 0xe1, 0x9a, 0x42, 0x08, 0xd0, + 0x6b, 0x6a, 0x05, 0x9a, 0x02, 0x31, 0x98, 0x18, 0x01, 0x23, 0x8b, 0x40, + 0x02, 0x78, 0x13, 0x43, 0x03, 0x70, 0x2b, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x15, 0x21, 0x33, 0x00, 0x28, 0x00, + 0xff, 0xf7, 0x37, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0x96, 0xe0, 0x2b, 0x6a, + 0x05, 0x93, 0x12, 0xab, 0x5b, 0x88, 0x09, 0x93, 0x00, 0x2b, 0x00, 0xd0, + 0x81, 0xe0, 0x05, 0x9b, 0x2e, 0x33, 0x0b, 0x93, 0x69, 0x23, 0x0c, 0x93, + 0x00, 0x23, 0x08, 0x93, 0x08, 0x9b, 0x0b, 0x9a, 0x5b, 0x00, 0xd6, 0x5a, + 0x07, 0x9a, 0x00, 0x23, 0xb2, 0x42, 0x06, 0xd8, 0x13, 0x00, 0x96, 0x4a, + 0xf1, 0x0f, 0x9a, 0x18, 0xd3, 0x17, 0xb2, 0x42, 0x4b, 0x41, 0x94, 0x4a, + 0x94, 0x49, 0xb2, 0x18, 0x92, 0xb2, 0x8a, 0x42, 0x05, 0xd9, 0x00, 0x2b, + 0x00, 0xd1, 0x8b, 0xe0, 0x33, 0x07, 0x00, 0xd0, 0x92, 0xe0, 0x16, 0x27, + 0x09, 0x9b, 0x08, 0x9a, 0x28, 0x00, 0x9e, 0x18, 0x05, 0x9a, 0x05, 0x9b, + 0x51, 0x78, 0x1b, 0x78, 0x09, 0x02, 0x19, 0x43, 0x0c, 0xab, 0xff, 0x18, + 0xb6, 0xb2, 0x49, 0x04, 0x00, 0x23, 0x49, 0x0c, 0x00, 0x97, 0x32, 0x00, + 0x01, 0xf0, 0x2a, 0xfd, 0x85, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x51, 0xd1, + 0x00, 0x23, 0x3b, 0x80, 0x3b, 0x88, 0x00, 0x2b, 0x16, 0xd1, 0xfc, 0x20, + 0x05, 0x99, 0x05, 0x9a, 0x49, 0x78, 0x12, 0x78, 0x09, 0x02, 0x11, 0x43, + 0x14, 0xaa, 0x10, 0x71, 0x01, 0x20, 0x49, 0x04, 0x49, 0x0c, 0x11, 0x80, + 0x56, 0x80, 0x02, 0x90, 0x03, 0x97, 0x01, 0x93, 0x00, 0x93, 0x28, 0x00, + 0x01, 0xf0, 0x7c, 0xfd, 0x04, 0x1e, 0x37, 0xdb, 0x16, 0x23, 0x0c, 0xaa, + 0x05, 0x99, 0x9b, 0x18, 0x05, 0x9a, 0x49, 0x78, 0x12, 0x78, 0x09, 0x02, + 0x11, 0x43, 0x80, 0x22, 0x12, 0x02, 0x11, 0x43, 0x06, 0x9a, 0x1b, 0x88, + 0x28, 0x00, 0x00, 0x92, 0x32, 0x00, 0xff, 0xf7, 0x41, 0xfa, 0x6d, 0x4b, + 0x04, 0x00, 0xc3, 0x18, 0xee, 0x6c, 0x02, 0x2b, 0x28, 0xd8, 0x00, 0x2e, + 0x09, 0xd0, 0x05, 0x9a, 0x05, 0x9b, 0x52, 0x78, 0x1b, 0x78, 0x12, 0x02, + 0x1a, 0x43, 0x06, 0x21, 0x00, 0x23, 0x02, 0x20, 0xb0, 0x47, 0x06, 0x99, + 0x28, 0x00, 0x01, 0xf0, 0xd3, 0xfd, 0x04, 0x00, 0x25, 0xe0, 0x7c, 0x22, + 0x09, 0x9b, 0x0c, 0x92, 0x53, 0x43, 0x13, 0x3b, 0x9b, 0xb2, 0x09, 0x93, + 0x05, 0x9b, 0x08, 0x33, 0x0b, 0x93, 0x77, 0xe7, 0x00, 0x28, 0xad, 0xda, + 0xee, 0x6c, 0x00, 0x2e, 0x00, 0xd1, 0x80, 0xe0, 0x00, 0x23, 0x22, 0x00, + 0x01, 0x21, 0x02, 0x20, 0xb0, 0x47, 0x7a, 0xe0, 0x00, 0x2e, 0x0c, 0xd0, + 0x05, 0x9b, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, 0x13, 0x43, 0x05, 0x9a, + 0x11, 0x78, 0x52, 0x78, 0x12, 0x02, 0x0a, 0x43, 0x02, 0x21, 0x08, 0x00, + 0xb0, 0x47, 0x00, 0x2c, 0xe4, 0xdb, 0x01, 0x23, 0x08, 0x9a, 0x01, 0x32, + 0x08, 0x92, 0x00, 0x2b, 0x4c, 0xd1, 0x0c, 0x99, 0x8a, 0x42, 0x00, 0xd0, + 0x52, 0xe7, 0x47, 0xe0, 0x05, 0x22, 0x14, 0xaf, 0x00, 0x92, 0x33, 0x02, + 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xff, 0xf7, 0x6d, 0xf8, + 0x04, 0x1e, 0xcd, 0xdb, 0x12, 0xab, 0x1a, 0x88, 0x39, 0x88, 0x41, 0x4b, + 0x13, 0x40, 0x99, 0x42, 0x0b, 0xd1, 0x09, 0x9b, 0x08, 0x98, 0x79, 0x88, + 0x1b, 0x18, 0x99, 0x42, 0x05, 0xd1, 0x7a, 0x21, 0x3b, 0x79, 0x8b, 0x43, + 0x84, 0x2b, 0x00, 0xd1, 0x7d, 0xe0, 0x16, 0x27, 0x08, 0x99, 0x09, 0x9b, + 0x52, 0x04, 0x5b, 0x18, 0x9b, 0xb2, 0x0d, 0x93, 0x0c, 0xab, 0xff, 0x18, + 0x51, 0x0c, 0x33, 0x00, 0x00, 0x97, 0x0d, 0x9a, 0x28, 0x00, 0x01, 0xf0, + 0x7d, 0xfc, 0x2f, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x37, 0xd1, 0x00, 0x23, + 0x3b, 0x80, 0x3b, 0x88, 0x12, 0xae, 0x31, 0x88, 0x00, 0x2b, 0x33, 0xd1, + 0xec, 0x6c, 0x00, 0x2c, 0x03, 0xd0, 0x0a, 0x00, 0x02, 0x20, 0x06, 0x21, + 0xa0, 0x47, 0x31, 0x88, 0x28, 0x00, 0xff, 0xf7, 0x8d, 0xf9, 0x04, 0x1e, + 0x92, 0xdb, 0x00, 0x23, 0x06, 0x9a, 0x01, 0x32, 0x92, 0xb2, 0x06, 0x92, + 0x00, 0x2b, 0x00, 0xd1, 0x8f, 0xe6, 0x0a, 0x9a, 0x01, 0x32, 0x92, 0xb2, + 0x0a, 0x92, 0x00, 0x2b, 0x00, 0xd1, 0x59, 0xe6, 0xeb, 0x68, 0x07, 0x9a, + 0x1b, 0x01, 0x9a, 0x42, 0x00, 0xd2, 0x48, 0xe6, 0x00, 0x2c, 0x00, 0xd0, + 0x7a, 0xe7, 0xed, 0x6c, 0x00, 0x2d, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, + 0x19, 0x00, 0x52, 0x00, 0x02, 0x20, 0xa8, 0x47, 0x20, 0x00, 0x17, 0xb0, + 0xf0, 0xbd, 0x00, 0x28, 0xc7, 0xda, 0x6b, 0xe7, 0x06, 0x9a, 0x28, 0x00, + 0x00, 0x92, 0x0d, 0x9a, 0xff, 0xf7, 0x82, 0xf9, 0x0d, 0x4b, 0x04, 0x00, + 0xc3, 0x18, 0xef, 0x6c, 0x02, 0x2b, 0x19, 0xd8, 0x32, 0x88, 0x00, 0x2f, + 0x03, 0xd0, 0x00, 0x23, 0x06, 0x21, 0x02, 0x20, 0xb8, 0x47, 0x12, 0xab, + 0x19, 0x88, 0x28, 0x00, 0xff, 0xf7, 0x4c, 0xf9, 0x43, 0xe7, 0xc0, 0x46, + 0xff, 0x01, 0x00, 0x00, 0xff, 0xdf, 0xff, 0xff, 0xfd, 0xdf, 0x00, 0x00, + 0xee, 0xd8, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, 0xff, 0x7f, 0xff, 0xff, + 0x00, 0x2f, 0x00, 0xd1, 0x5b, 0xe7, 0x02, 0x21, 0x73, 0x88, 0x32, 0x88, + 0x08, 0x00, 0xb8, 0x47, 0x55, 0xe7, 0x01, 0x21, 0x07, 0x9b, 0xf7, 0x1a, + 0x6b, 0x6a, 0x7f, 0x08, 0x0e, 0x40, 0xb6, 0x00, 0xdb, 0x5d, 0x76, 0x18, + 0x33, 0x41, 0x0b, 0x40, 0x16, 0xd0, 0xec, 0x6c, 0x00, 0x2c, 0x03, 0xd0, + 0x00, 0x23, 0x05, 0x31, 0x02, 0x20, 0xa0, 0x47, 0x12, 0xab, 0x19, 0x88, + 0x28, 0x00, 0xff, 0xf7, 0x1d, 0xf9, 0x04, 0x1e, 0x00, 0xda, 0x21, 0xe7, + 0x06, 0x99, 0x28, 0x00, 0x01, 0xf0, 0xe2, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0x1a, 0xe7, 0x01, 0x23, 0x01, 0x21, 0xb1, 0x40, 0x6a, 0x6a, 0xd7, 0x19, + 0x3a, 0x78, 0x0a, 0x43, 0x3a, 0x70, 0x2d, 0xe7, 0x01, 0x23, 0x08, 0x93, + 0x06, 0x9a, 0x6b, 0x6a, 0x9b, 0x5c, 0x08, 0x9a, 0x92, 0x00, 0x13, 0x41, + 0x07, 0x22, 0x1a, 0x40, 0x09, 0x92, 0x01, 0x2a, 0x00, 0xd0, 0x93, 0xe0, + 0x08, 0x9a, 0x0a, 0x9b, 0x12, 0xae, 0x9b, 0x18, 0x05, 0x22, 0x9b, 0xb2, + 0x05, 0x93, 0x00, 0x92, 0x1b, 0x02, 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, + 0x28, 0x00, 0xfe, 0xf7, 0x92, 0xff, 0x04, 0x1e, 0x00, 0xda, 0xf1, 0xe6, + 0x16, 0x27, 0x0c, 0xab, 0xff, 0x18, 0x11, 0xab, 0x72, 0x88, 0x31, 0x88, + 0x28, 0x00, 0x00, 0x93, 0x3b, 0x00, 0xff, 0xf7, 0xa5, 0xf8, 0x04, 0x1e, + 0x61, 0xd1, 0x80, 0x22, 0x3b, 0x88, 0x92, 0x01, 0x93, 0x42, 0x20, 0xd8, + 0x1a, 0x07, 0x1e, 0xd0, 0x05, 0x22, 0x14, 0xaf, 0x00, 0x92, 0x1b, 0x02, + 0x02, 0x00, 0x01, 0x97, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x71, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0xd0, 0xe6, 0x38, 0x4a, 0x33, 0x88, 0x13, 0x40, + 0x3a, 0x88, 0x93, 0x42, 0x04, 0xd1, 0x78, 0x22, 0x3b, 0x79, 0x93, 0x43, + 0x84, 0x2b, 0x45, 0xd0, 0x16, 0x23, 0x0c, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0x05, 0x9a, 0x93, 0x42, 0x4e, 0xd0, 0x11, 0xab, 0x1b, 0x88, 0x12, 0xae, + 0x72, 0x88, 0x31, 0x88, 0x28, 0x00, 0x00, 0x93, 0x05, 0x9b, 0xff, 0xf7, + 0xd1, 0xf8, 0x2b, 0x4b, 0x04, 0x00, 0xc3, 0x18, 0xef, 0x6c, 0x02, 0x2b, + 0x45, 0xd8, 0x00, 0x2f, 0x04, 0xd0, 0x32, 0x88, 0x00, 0x23, 0x06, 0x21, + 0x02, 0x20, 0xb8, 0x47, 0x05, 0x99, 0x28, 0x00, 0x01, 0xf0, 0x68, 0xfc, + 0x04, 0x1e, 0x00, 0xda, 0xa0, 0xe6, 0x31, 0x88, 0x28, 0x00, 0xff, 0xf7, + 0x95, 0xf8, 0x04, 0x00, 0x00, 0x2c, 0x00, 0xda, 0x98, 0xe6, 0x06, 0x9b, + 0x01, 0x33, 0x06, 0x93, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x0d, 0xe7, + 0x06, 0x9b, 0x1a, 0x00, 0x80, 0x23, 0x5b, 0x00, 0x9a, 0x42, 0x00, 0xd0, + 0x66, 0xe5, 0x80, 0x22, 0x92, 0x00, 0x94, 0x46, 0x07, 0x9b, 0x63, 0x44, + 0x9b, 0xb2, 0x07, 0x93, 0xfe, 0xe6, 0x13, 0x4b, 0x98, 0x42, 0x0c, 0xd1, + 0xec, 0x6c, 0x00, 0x2c, 0x04, 0xd0, 0x00, 0x23, 0x05, 0x9a, 0x05, 0x21, + 0x02, 0x20, 0xa0, 0x47, 0x05, 0x99, 0x28, 0x00, 0x01, 0xf0, 0x38, 0xfc, + 0x04, 0x00, 0x00, 0x2c, 0x00, 0xda, 0x6f, 0xe6, 0x08, 0x9b, 0x01, 0x2b, + 0x00, 0xd0, 0x59, 0xe7, 0x00, 0x23, 0x09, 0x93, 0xcf, 0xe7, 0x00, 0x2f, + 0xca, 0xd0, 0x02, 0x21, 0x73, 0x88, 0x32, 0x88, 0x08, 0x00, 0xb8, 0x47, + 0xc4, 0xe7, 0xc0, 0x46, 0xff, 0x7f, 0xff, 0xff, 0x45, 0x27, 0x00, 0x00, + 0xee, 0xd8, 0xff, 0xff, 0x80, 0x22, 0xf0, 0xb5, 0x06, 0x00, 0x89, 0xb0, + 0x00, 0x21, 0x52, 0x00, 0x40, 0x6a, 0x04, 0xf0, 0x38, 0xf9, 0x00, 0x21, + 0xf4, 0x6c, 0x07, 0x91, 0x8c, 0x42, 0x03, 0xd0, 0x0b, 0x00, 0x0a, 0x00, + 0x01, 0x20, 0xa0, 0x47, 0x00, 0x24, 0x07, 0xab, 0x03, 0x93, 0x14, 0x4b, + 0x05, 0x94, 0x01, 0x93, 0x04, 0x94, 0x23, 0x00, 0x02, 0x94, 0x00, 0x94, + 0x22, 0x00, 0x21, 0x00, 0x30, 0x00, 0x01, 0xf0, 0x2f, 0xf9, 0x0f, 0x4b, + 0x05, 0x00, 0x98, 0x42, 0x15, 0xd0, 0xa0, 0x42, 0x07, 0xd0, 0xf7, 0x6c, + 0xa7, 0x42, 0x04, 0xd0, 0x01, 0x21, 0x02, 0x00, 0x23, 0x00, 0x08, 0x00, + 0xb8, 0x47, 0xf4, 0x6c, 0x00, 0x2c, 0x05, 0xd0, 0x00, 0x23, 0x80, 0x22, + 0x19, 0x00, 0x52, 0x00, 0x01, 0x20, 0xa0, 0x47, 0x28, 0x00, 0x09, 0xb0, + 0xf0, 0xbd, 0x25, 0x00, 0xf1, 0xe7, 0xc0, 0x46, 0xe9, 0x31, 0x00, 0x00, + 0xa8, 0xd8, 0xff, 0xff, 0xf8, 0xb5, 0x06, 0x00, 0x0c, 0x00, 0x01, 0xf0, + 0xcf, 0xf9, 0x05, 0x1e, 0x0c, 0xdb, 0x24, 0x01, 0xa4, 0xb2, 0x27, 0x00, + 0x10, 0x37, 0xbf, 0xb2, 0x21, 0x00, 0x01, 0x34, 0x30, 0x00, 0xa4, 0xb2, + 0xfe, 0xf7, 0x96, 0xfe, 0xbc, 0x42, 0xf7, 0xd1, 0x28, 0x00, 0xf8, 0xbd, + 0xf0, 0xb5, 0x05, 0x00, 0x0f, 0x00, 0x00, 0x24, 0xc3, 0x68, 0x87, 0xb0, + 0x03, 0x93, 0x03, 0x6a, 0x02, 0x93, 0xa2, 0xb2, 0x04, 0x92, 0x03, 0x9a, + 0x23, 0x03, 0xa2, 0x42, 0x01, 0xd1, 0x1e, 0x48, 0x35, 0xe0, 0x2a, 0x6a, + 0x14, 0x21, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x28, 0x00, + 0x00, 0x22, 0xfe, 0xf7, 0x84, 0xfe, 0x02, 0x99, 0x18, 0x4e, 0x0b, 0x00, + 0x1e, 0x33, 0x05, 0x93, 0x00, 0x23, 0xb4, 0x46, 0x1a, 0x00, 0x98, 0x42, + 0x0b, 0xd0, 0x01, 0x28, 0x13, 0xd9, 0x01, 0x34, 0x00, 0x28, 0x1c, 0xd1, + 0xdd, 0xe7, 0x08, 0x88, 0x00, 0x28, 0x06, 0xd1, 0x01, 0x32, 0x92, 0xb2, + 0x02, 0x31, 0x05, 0x98, 0x81, 0x42, 0xf6, 0xd1, 0x05, 0xe0, 0x60, 0x45, + 0x03, 0xd1, 0x01, 0x33, 0x9b, 0xb2, 0xbb, 0x42, 0xf4, 0xd9, 0xd1, 0x18, + 0x0f, 0x29, 0x0a, 0xd1, 0xbb, 0x42, 0x08, 0xd8, 0xeb, 0x6b, 0x04, 0x99, + 0x9a, 0x1a, 0xea, 0x63, 0x28, 0x00, 0xff, 0xf7, 0xa3, 0xff, 0x07, 0xb0, + 0xf0, 0xbd, 0x01, 0x34, 0xbd, 0xe7, 0xc0, 0x46, 0xd3, 0xd8, 0xff, 0xff, + 0xff, 0xff, 0x00, 0x00, 0xf7, 0xb5, 0x80, 0x22, 0x04, 0x6a, 0x52, 0x00, + 0x0b, 0x03, 0x00, 0x92, 0x14, 0x21, 0x00, 0x22, 0x01, 0x94, 0x05, 0x00, + 0x26, 0x00, 0xfe, 0xf7, 0x42, 0xfe, 0x00, 0x22, 0x23, 0x00, 0x1e, 0x36, + 0x11, 0x00, 0x0b, 0x4f, 0x90, 0x42, 0x0d, 0xd0, 0xab, 0x6b, 0x9a, 0x1a, + 0xeb, 0x6b, 0xaa, 0x63, 0x59, 0x1a, 0xe9, 0x63, 0xfe, 0xbd, 0x1c, 0x88, + 0xbc, 0x42, 0x02, 0xd0, 0x00, 0x2c, 0x04, 0xd1, 0x01, 0x31, 0x02, 0x33, + 0x9e, 0x42, 0xf6, 0xd1, 0xee, 0xe7, 0x01, 0x32, 0xf9, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xf0, 0xb5, 0x1d, 0x00, 0xc3, 0x68, 0x93, 0xb0, + 0x05, 0x93, 0x03, 0x6a, 0x04, 0x00, 0x0c, 0x93, 0x05, 0x9b, 0x0f, 0x00, + 0x08, 0x92, 0x03, 0x93, 0x29, 0x2b, 0x01, 0xd9, 0x29, 0x23, 0x03, 0x93, + 0x00, 0x26, 0x80, 0x22, 0x08, 0x9b, 0x52, 0x00, 0x1e, 0x60, 0xff, 0x21, + 0x60, 0x6a, 0x04, 0xf0, 0x56, 0xf8, 0x63, 0x6a, 0x02, 0x96, 0x06, 0x93, + 0x03, 0x9b, 0x06, 0x9a, 0x5b, 0x00, 0xd3, 0x18, 0x03, 0x22, 0x09, 0x93, + 0x03, 0x33, 0x93, 0x43, 0x0a, 0x93, 0x06, 0x9b, 0x0a, 0x9a, 0x3b, 0x60, + 0x6b, 0x42, 0x5d, 0x41, 0x32, 0x23, 0x6d, 0x42, 0x2b, 0x40, 0x0f, 0x93, + 0x03, 0x9b, 0x9b, 0x00, 0x9b, 0x18, 0x0e, 0x93, 0x6a, 0x46, 0x12, 0x89, + 0x02, 0x9b, 0x0d, 0x92, 0x05, 0x99, 0x02, 0x9a, 0x1b, 0x03, 0x8a, 0x42, + 0x01, 0xd1, 0x00, 0x20, 0x4f, 0xe0, 0x22, 0x6a, 0x14, 0x21, 0x01, 0x92, + 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x20, 0x00, 0x00, 0x22, 0xfe, 0xf7, + 0xde, 0xfd, 0x0c, 0x9b, 0x00, 0x25, 0x19, 0x00, 0x2f, 0x00, 0x1e, 0x31, + 0x3a, 0x4e, 0xa8, 0x42, 0x47, 0xd0, 0x01, 0x28, 0x3b, 0xd1, 0x0e, 0x26, + 0x6b, 0x46, 0x0e, 0xaa, 0xb6, 0x18, 0x02, 0x22, 0x1b, 0x89, 0x15, 0x21, + 0x1b, 0x03, 0x00, 0x92, 0xfe, 0x33, 0x01, 0x96, 0x00, 0x22, 0x20, 0x00, + 0xfe, 0xf7, 0xc5, 0xfd, 0x00, 0x28, 0x2a, 0xdb, 0x23, 0x1d, 0xda, 0x8f, + 0x33, 0x88, 0x9a, 0x42, 0x35, 0xd9, 0xd3, 0x1a, 0x05, 0x22, 0x57, 0x43, + 0x0f, 0x9a, 0x9b, 0xb2, 0x53, 0x43, 0x7d, 0x1b, 0xeb, 0x18, 0x07, 0x93, + 0x00, 0x23, 0x06, 0x99, 0x27, 0x4d, 0x03, 0x9a, 0x93, 0x42, 0x0b, 0xda, + 0x0a, 0x9e, 0x9a, 0x00, 0x92, 0x19, 0x0e, 0x88, 0x0b, 0x91, 0xae, 0x42, + 0x22, 0xd1, 0x6b, 0x46, 0x9b, 0x8e, 0x0b, 0x80, 0x07, 0x9b, 0x13, 0x60, + 0x08, 0x9b, 0x08, 0x9a, 0x1b, 0x68, 0x04, 0x93, 0x01, 0x33, 0x13, 0x60, + 0x02, 0x9b, 0x01, 0x33, 0x02, 0x93, 0x00, 0x28, 0xa4, 0xd0, 0x13, 0xb0, + 0xf0, 0xbd, 0x1a, 0x88, 0xb2, 0x42, 0xbe, 0xd0, 0x00, 0x2a, 0x05, 0xd1, + 0x01, 0x37, 0xbf, 0xb2, 0x02, 0x33, 0x99, 0x42, 0xf5, 0xd1, 0xb6, 0xe7, + 0x01, 0x35, 0xad, 0xb2, 0xf8, 0xe7, 0x9b, 0x1a, 0xdb, 0x43, 0xc7, 0xe7, + 0x0b, 0x99, 0x16, 0x68, 0x07, 0x9f, 0x02, 0x31, 0xbe, 0x42, 0x19, 0xda, + 0x03, 0x99, 0x09, 0x9d, 0x02, 0x39, 0x04, 0x91, 0x0e, 0x99, 0x04, 0x9e, + 0x02, 0x3d, 0x0f, 0x1f, 0xb3, 0x42, 0x04, 0xdd, 0x69, 0x46, 0x0b, 0x9b, + 0x89, 0x8e, 0x19, 0x80, 0xca, 0xe7, 0xae, 0x1e, 0x08, 0x39, 0x36, 0x88, + 0x09, 0x68, 0x2e, 0x80, 0x39, 0x60, 0x04, 0x99, 0x01, 0x39, 0x04, 0x91, + 0x39, 0x00, 0xea, 0xe7, 0x01, 0x33, 0xb0, 0xe7, 0xff, 0xff, 0x00, 0x00, + 0xf0, 0xb5, 0x05, 0x00, 0x03, 0x6a, 0x9b, 0xb0, 0x0f, 0x93, 0x43, 0x6a, + 0x0c, 0x00, 0x14, 0x22, 0x00, 0x21, 0x15, 0xa8, 0x0a, 0x93, 0x03, 0xf0, + 0x9e, 0xff, 0x2b, 0x8a, 0xa3, 0x42, 0x06, 0xd1, 0x60, 0x1c, 0xe9, 0x68, + 0x03, 0xf0, 0x64, 0xff, 0x00, 0x23, 0x29, 0x82, 0x6b, 0x61, 0x23, 0x01, + 0x01, 0x33, 0x9b, 0xb2, 0x11, 0x93, 0x0f, 0x9b, 0x24, 0x03, 0x1b, 0x19, + 0x10, 0x93, 0x00, 0x23, 0x08, 0x93, 0x8f, 0xe1, 0x0c, 0x9a, 0x10, 0x9b, + 0x14, 0x21, 0x9b, 0x1a, 0x0d, 0x93, 0x2b, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x28, 0x00, 0x0d, 0x9b, 0xfe, 0xf7, + 0x30, 0xfd, 0x04, 0x00, 0x00, 0x2c, 0x07, 0xd1, 0x07, 0x9b, 0x0e, 0x9a, + 0x9b, 0x1a, 0x7f, 0x2b, 0x02, 0xdc, 0x07, 0x9b, 0x0e, 0x2b, 0x01, 0xdd, + 0x3b, 0x00, 0x88, 0xe0, 0x07, 0x9b, 0x0c, 0x9a, 0x5b, 0x00, 0xd3, 0x5a, + 0x07, 0x9a, 0x09, 0x93, 0x11, 0x9b, 0x9b, 0x18, 0x9b, 0xb2, 0x15, 0xaa, + 0x08, 0x93, 0x13, 0x78, 0x01, 0x2b, 0x15, 0xd0, 0x00, 0x2b, 0x04, 0xd0, + 0x02, 0x2b, 0x00, 0xd1, 0x8f, 0xe0, 0x23, 0x00, 0x6d, 0xe0, 0x6b, 0x46, + 0x24, 0x21, 0x59, 0x5e, 0x3b, 0x00, 0x00, 0x29, 0x00, 0xdc, 0x66, 0xe0, + 0x6b, 0x46, 0x9b, 0x8c, 0x17, 0x74, 0x53, 0x80, 0x6b, 0x46, 0x1b, 0x8c, + 0x13, 0x81, 0xee, 0xe7, 0x52, 0x88, 0x09, 0x99, 0x3b, 0x00, 0x8a, 0x42, + 0x59, 0xd1, 0x05, 0x22, 0x08, 0x9b, 0x13, 0xae, 0x00, 0x92, 0x1b, 0x02, + 0x22, 0x00, 0x01, 0x96, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0xef, 0xfc, + 0x04, 0x1e, 0x2d, 0xdb, 0x73, 0x88, 0x00, 0x20, 0x68, 0x2b, 0x05, 0xd9, + 0x69, 0x3b, 0x18, 0x00, 0x7c, 0x21, 0x03, 0xf0, 0x75, 0xfe, 0x01, 0x30, + 0x15, 0xab, 0x9e, 0x88, 0x86, 0x42, 0x3d, 0xd1, 0x13, 0xab, 0x1a, 0x79, + 0x7f, 0x2a, 0x1e, 0xd9, 0x1a, 0x22, 0x0c, 0xa9, 0x52, 0x18, 0x02, 0x92, + 0x08, 0x9a, 0x00, 0x93, 0x01, 0x92, 0x00, 0x22, 0x09, 0x9b, 0x11, 0x00, + 0x28, 0x00, 0x01, 0xf0, 0x25, 0xfa, 0x04, 0x1e, 0x0c, 0xdb, 0x2b, 0x6a, + 0x00, 0x22, 0x01, 0x93, 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x14, 0x21, + 0x0d, 0x9b, 0x28, 0x00, 0xfe, 0xf7, 0xc1, 0xfc, 0x04, 0x1e, 0x0e, 0xda, + 0x20, 0x00, 0x1b, 0xb0, 0xf0, 0xbd, 0x08, 0x99, 0x28, 0x00, 0x01, 0xf0, + 0xdf, 0xf9, 0x04, 0x1e, 0xf6, 0xdb, 0x1a, 0x23, 0x0c, 0xaa, 0x9b, 0x18, + 0x01, 0x22, 0x52, 0x42, 0x1a, 0x80, 0x13, 0xab, 0x58, 0x88, 0x1a, 0x23, + 0x0c, 0xaa, 0x9b, 0x18, 0x1b, 0x88, 0x09, 0x93, 0x00, 0x2e, 0x1c, 0xd1, + 0x17, 0x30, 0x6a, 0x46, 0x0a, 0x9b, 0x92, 0x8c, 0x40, 0x00, 0x1a, 0x52, + 0x3b, 0x00, 0x07, 0x9a, 0x01, 0x32, 0x07, 0x92, 0x00, 0x2b, 0x00, 0xd0, + 0x6a, 0xe7, 0x0b, 0x9a, 0x01, 0x32, 0x0b, 0x92, 0x00, 0x2b, 0x6b, 0xd0, + 0x0e, 0x9b, 0x80, 0x33, 0x0e, 0x93, 0x0c, 0x9b, 0x01, 0x3b, 0xff, 0x3b, + 0x0c, 0x93, 0x00, 0x2c, 0x00, 0xd1, 0x2d, 0xe1, 0xca, 0xe7, 0x68, 0x28, + 0x01, 0xd8, 0x04, 0x30, 0xdf, 0xe7, 0x69, 0x38, 0x7c, 0x21, 0x03, 0xf0, + 0x99, 0xfe, 0x08, 0x1d, 0xd9, 0xe7, 0x09, 0x9b, 0x98, 0x4a, 0x99, 0x49, + 0x9a, 0x18, 0x92, 0xb2, 0x3b, 0x00, 0x8a, 0x42, 0xd7, 0xd8, 0x05, 0x22, + 0x08, 0x9b, 0x13, 0xae, 0x00, 0x92, 0x1b, 0x02, 0x22, 0x00, 0x01, 0x96, + 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x6d, 0xfc, 0x04, 0x1e, 0xab, 0xdb, + 0x33, 0x79, 0x7f, 0x2b, 0x2b, 0xd9, 0x1a, 0x23, 0x0c, 0xaa, 0x9b, 0x18, + 0x00, 0x22, 0x02, 0x93, 0x08, 0x9b, 0x00, 0x96, 0x01, 0x93, 0x11, 0x00, + 0x09, 0x9b, 0x28, 0x00, 0x01, 0xf0, 0xb2, 0xf9, 0x04, 0x1e, 0x00, 0xda, + 0x98, 0xe7, 0x00, 0x24, 0x0c, 0xab, 0x02, 0x94, 0x5b, 0x8b, 0x13, 0xa9, + 0x01, 0x93, 0x4b, 0x88, 0x03, 0x22, 0x00, 0x93, 0x28, 0x00, 0x09, 0x9b, + 0x01, 0xf0, 0x20, 0xfa, 0x2b, 0x6a, 0x22, 0x00, 0x01, 0x93, 0x80, 0x23, + 0x5b, 0x00, 0x00, 0x93, 0x14, 0x21, 0x0d, 0x9b, 0x28, 0x00, 0xfe, 0xf7, + 0x40, 0xfc, 0x04, 0x00, 0x00, 0x2c, 0x9b, 0xda, 0x7c, 0xe7, 0x08, 0x99, + 0x28, 0x00, 0x01, 0xf0, 0x5f, 0xf9, 0x04, 0x1e, 0xf6, 0xd1, 0x00, 0x21, + 0x08, 0x9b, 0x02, 0x91, 0x01, 0x93, 0x13, 0xab, 0x5b, 0x88, 0x02, 0x22, + 0x00, 0x93, 0x28, 0x00, 0x09, 0x9b, 0x01, 0xf0, 0xff, 0xf9, 0x87, 0xe7, + 0x00, 0x2c, 0x00, 0xd1, 0xcc, 0xe0, 0x65, 0xe7, 0x0b, 0x7c, 0x00, 0x2b, + 0x70, 0xd0, 0x07, 0x9b, 0x05, 0x22, 0xcb, 0x60, 0x01, 0x23, 0x0b, 0x70, + 0x08, 0x9b, 0x13, 0xaf, 0x00, 0x92, 0x1b, 0x02, 0x01, 0x97, 0x32, 0x00, + 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0x13, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0x50, 0xe7, 0x78, 0x88, 0x37, 0x00, 0x68, 0x28, 0x05, 0xd9, 0x69, 0x38, + 0x7c, 0x21, 0x03, 0xf0, 0x99, 0xfd, 0x01, 0x30, 0x87, 0xb2, 0x80, 0x23, + 0x15, 0xae, 0x71, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1a, 0x23, 0x0c, 0xaa, + 0x9b, 0x18, 0xb7, 0x80, 0x3a, 0x00, 0x00, 0x93, 0x28, 0x00, 0x00, 0x23, + 0x01, 0xf0, 0x2c, 0xf8, 0x56, 0x4b, 0x04, 0x00, 0x98, 0x42, 0x0c, 0xd1, + 0x31, 0x89, 0x28, 0x00, 0x01, 0xf0, 0x16, 0xf9, 0x04, 0x1e, 0x00, 0xda, + 0x2c, 0xe7, 0x00, 0x23, 0x33, 0x70, 0x00, 0x2c, 0x00, 0xd0, 0x27, 0xe7, + 0x71, 0xe0, 0x00, 0x28, 0x00, 0xda, 0x23, 0xe7, 0x6a, 0x6a, 0x0c, 0xab, + 0x5b, 0x8b, 0x01, 0x92, 0x80, 0x22, 0x52, 0x00, 0x00, 0x92, 0x1b, 0x02, + 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xfe, 0xf7, 0xd6, 0xfb, 0x04, 0x1e, + 0x00, 0xda, 0x13, 0xe7, 0x0a, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x13, 0xd4, + 0x5a, 0xb2, 0x00, 0x2a, 0x12, 0xda, 0x9a, 0x07, 0x12, 0xd4, 0x04, 0x22, + 0x1a, 0x40, 0x11, 0xd1, 0x0a, 0x9b, 0x99, 0x78, 0xdb, 0x78, 0x1b, 0x02, + 0x0b, 0x43, 0xbb, 0x42, 0x0c, 0xd1, 0x0c, 0xab, 0x5b, 0x8b, 0x07, 0x92, + 0xf3, 0x80, 0xd0, 0xe7, 0x39, 0x4c, 0xf9, 0xe6, 0x39, 0x4c, 0xf7, 0xe6, + 0x39, 0x4c, 0xf5, 0xe6, 0x39, 0x4c, 0xf3, 0xe6, 0x39, 0x4c, 0xf1, 0xe6, + 0x02, 0x22, 0x0a, 0x70, 0x07, 0x93, 0x38, 0xe0, 0x80, 0x22, 0x00, 0x26, + 0xcb, 0x68, 0x12, 0x02, 0x07, 0x93, 0x4b, 0x88, 0x0e, 0x70, 0x09, 0x93, + 0x1a, 0x43, 0xcb, 0x88, 0x89, 0x88, 0x68, 0x6a, 0x13, 0xaf, 0xb1, 0x42, + 0x0b, 0xd1, 0x00, 0x90, 0x04, 0x97, 0x03, 0x91, 0x02, 0x91, 0x01, 0x91, + 0x28, 0x00, 0x01, 0xf0, 0x93, 0xfa, 0x04, 0x00, 0xb0, 0x42, 0xa8, 0xda, + 0xd2, 0xe6, 0x01, 0x93, 0x02, 0x97, 0x13, 0x00, 0x00, 0x96, 0x02, 0x00, + 0x31, 0x00, 0x28, 0x00, 0x01, 0xf0, 0xe0, 0xf8, 0x04, 0x1e, 0x00, 0xda, + 0xc6, 0xe6, 0x02, 0x96, 0x3b, 0x88, 0x69, 0x6a, 0x01, 0x93, 0x0a, 0x9b, + 0x28, 0x00, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, 0x13, 0x43, 0x00, 0x93, + 0x32, 0x00, 0x09, 0x9b, 0x01, 0xf0, 0x4c, 0xf9, 0x8b, 0xe7, 0x03, 0x23, + 0x0b, 0x70, 0x15, 0xab, 0x1a, 0x78, 0x00, 0x24, 0x03, 0x2a, 0x00, 0xd1, + 0xae, 0xe6, 0x7f, 0x22, 0x01, 0x27, 0x1c, 0x74, 0x07, 0x9b, 0xdb, 0x17, + 0x13, 0x40, 0x07, 0x9a, 0x9b, 0x18, 0xdb, 0x11, 0x0b, 0x93, 0xdb, 0x01, + 0x0e, 0x93, 0x0b, 0x9b, 0x0f, 0x9a, 0x1b, 0x02, 0xd3, 0x1a, 0x0c, 0x93, + 0x0b, 0x9b, 0x00, 0x2b, 0x00, 0xdc, 0x19, 0xe6, 0x15, 0xa9, 0x0e, 0x78, + 0x01, 0x2e, 0xa7, 0xd0, 0x00, 0x2e, 0x00, 0xd1, 0x2c, 0xe7, 0x02, 0x2e, + 0xd9, 0xd0, 0x00, 0x23, 0x9e, 0xe7, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, + 0xfe, 0x7f, 0x00, 0x00, 0xee, 0xd8, 0xff, 0xff, 0xe4, 0xd8, 0xff, 0xff, + 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, + 0xe3, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0f, 0x26, 0xc3, 0x68, 0x87, 0xb0, + 0x5e, 0x43, 0x83, 0x6b, 0x04, 0x00, 0xf6, 0x1a, 0xc3, 0x6b, 0x1e, 0x3e, + 0xf5, 0x1a, 0x43, 0x6b, 0x0f, 0x00, 0x03, 0x2b, 0x04, 0xd9, 0xfb, 0x23, + 0x6b, 0x43, 0x00, 0x20, 0x8b, 0x42, 0x19, 0xdc, 0x38, 0x00, 0xfb, 0x21, + 0xfa, 0x30, 0x03, 0xf0, 0xb5, 0xfc, 0x02, 0x90, 0x86, 0x42, 0x44, 0xdb, + 0x05, 0x23, 0x01, 0x93, 0x6b, 0x1e, 0x2b, 0x43, 0xdb, 0x0f, 0x05, 0xaa, + 0x04, 0xa9, 0x20, 0x00, 0xff, 0xf7, 0xf2, 0xfc, 0x00, 0x28, 0x05, 0xdb, + 0x05, 0x98, 0x00, 0x28, 0x04, 0xd1, 0x02, 0x9b, 0xab, 0x42, 0x32, 0xda, + 0x07, 0xb0, 0xf0, 0xbd, 0x04, 0x9b, 0x01, 0x22, 0x1e, 0x88, 0x23, 0x00, + 0x40, 0x33, 0x1a, 0x70, 0x31, 0x00, 0x20, 0x00, 0x03, 0x93, 0xff, 0xf7, + 0xa1, 0xfd, 0x00, 0x23, 0x03, 0x9a, 0x13, 0x70, 0x98, 0x42, 0xed, 0xdb, + 0x31, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xaa, 0xfc, 0x00, 0x28, 0xe7, 0xdb, + 0x31, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x3e, 0xfc, 0x00, 0x28, 0xe1, 0xdb, + 0x0f, 0x22, 0xe3, 0x68, 0x53, 0x43, 0xa2, 0x6b, 0x9b, 0x1a, 0xe2, 0x6b, + 0x1e, 0x3b, 0x9b, 0x1a, 0x00, 0x2d, 0x01, 0xdc, 0x9d, 0x42, 0x04, 0xd0, + 0x01, 0x9a, 0x01, 0x3a, 0x01, 0x92, 0x00, 0x2a, 0x05, 0xd1, 0xfb, 0x22, + 0x53, 0x43, 0xbb, 0x42, 0xcc, 0xda, 0x05, 0x48, 0xca, 0xe7, 0x62, 0x6b, + 0x02, 0x2a, 0x03, 0xd9, 0xfb, 0x22, 0x5a, 0x43, 0xba, 0x42, 0xf2, 0xda, + 0x1d, 0x00, 0xb1, 0xe7, 0xef, 0xd8, 0xff, 0xff, 0xf7, 0xb5, 0x84, 0x68, + 0x07, 0x00, 0x01, 0x91, 0x15, 0x00, 0x1e, 0x00, 0x63, 0x1c, 0x17, 0xd0, + 0x33, 0x00, 0x94, 0x42, 0x10, 0xd9, 0xa4, 0x1a, 0xb4, 0x42, 0x00, 0xdd, + 0x34, 0x00, 0x23, 0x00, 0x01, 0x9a, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, + 0x47, 0xfd, 0x00, 0x28, 0x07, 0xdb, 0x01, 0x9a, 0x33, 0x1b, 0x12, 0x19, + 0x01, 0x92, 0x2d, 0x19, 0x00, 0x2b, 0x03, 0xdc, 0x30, 0x00, 0xfe, 0xbd, + 0x33, 0x00, 0xf9, 0xe7, 0x01, 0x9a, 0x29, 0x00, 0x38, 0x00, 0x01, 0xf0, + 0x7d, 0xfa, 0x00, 0x28, 0xf4, 0xda, 0xf4, 0xe7, 0x73, 0xb5, 0x01, 0xaa, + 0x05, 0x00, 0x02, 0xf0, 0x59, 0xfc, 0x04, 0x1e, 0x02, 0xda, 0x28, 0x63, + 0x20, 0x00, 0x76, 0xbd, 0x01, 0x9e, 0xb3, 0x8b, 0x9b, 0x06, 0xf9, 0xd4, + 0x33, 0x6a, 0x00, 0x2b, 0x04, 0xd1, 0x31, 0x00, 0x28, 0x00, 0xfe, 0xf7, + 0x29, 0xfb, 0x30, 0x62, 0x01, 0x98, 0x02, 0x6a, 0x00, 0x2a, 0xed, 0xd0, + 0x8a, 0x21, 0x56, 0x78, 0x49, 0x00, 0x71, 0x43, 0x6c, 0x6c, 0x14, 0x31, + 0x24, 0x69, 0x13, 0x8a, 0x61, 0x18, 0xd2, 0x68, 0xff, 0xf7, 0xb0, 0xff, + 0x04, 0x1e, 0x00, 0xda, 0x28, 0x63, 0x01, 0x9b, 0x28, 0x00, 0x19, 0x6a, + 0xfe, 0xf7, 0x34, 0xfb, 0xd8, 0xe7, 0x00, 0x00, 0xf7, 0xb5, 0x04, 0x00, + 0x1d, 0x00, 0x83, 0x6d, 0x17, 0x00, 0x01, 0x91, 0x60, 0x22, 0x00, 0x21, + 0x00, 0x93, 0x0a, 0x9e, 0x03, 0xf0, 0xb3, 0xfc, 0x0c, 0x22, 0x01, 0x99, + 0x20, 0x00, 0x03, 0xf0, 0xa5, 0xfc, 0x00, 0x9b, 0x08, 0x9a, 0xa3, 0x65, + 0x80, 0x23, 0x9b, 0x00, 0xe3, 0x60, 0x7b, 0x1c, 0xff, 0x33, 0x67, 0x62, + 0x23, 0x62, 0x00, 0x21, 0x28, 0x00, 0x03, 0xf0, 0xa0, 0xfc, 0x03, 0x22, + 0x2a, 0x40, 0x05, 0xd0, 0x04, 0x23, 0x9b, 0x1a, 0x08, 0x9a, 0xed, 0x18, + 0xd3, 0x1a, 0x08, 0x93, 0xa5, 0x62, 0x30, 0x21, 0x08, 0x98, 0x03, 0xf0, + 0xd9, 0xfb, 0x03, 0x22, 0x09, 0x9b, 0xe0, 0x62, 0x1a, 0x40, 0x05, 0xd0, + 0x04, 0x23, 0x9b, 0x1a, 0x09, 0x9a, 0xf6, 0x1a, 0xd2, 0x18, 0x09, 0x92, + 0x03, 0x23, 0x1e, 0x42, 0x00, 0xd0, 0x9e, 0x43, 0x80, 0x22, 0x09, 0x9b, + 0x92, 0x01, 0x63, 0x64, 0x33, 0x00, 0x96, 0x42, 0x00, 0xd9, 0x13, 0x00, + 0xa3, 0x64, 0x20, 0x00, 0xfe, 0xf7, 0x08, 0xfb, 0x07, 0x4b, 0x20, 0x00, + 0xe3, 0x65, 0x00, 0xf0, 0x83, 0xfd, 0x00, 0x28, 0x01, 0xda, 0x20, 0x63, + 0xfe, 0xbd, 0x0b, 0x9b, 0x00, 0x20, 0xe3, 0x64, 0x01, 0x23, 0x54, 0x34, + 0x23, 0x70, 0xf7, 0xe7, 0x15, 0x03, 0x09, 0x20, 0xf8, 0xb5, 0xc2, 0x6d, + 0x10, 0x4b, 0x04, 0x00, 0x9a, 0x42, 0x0c, 0xd1, 0x07, 0x00, 0x54, 0x37, + 0x3b, 0x78, 0x00, 0x2b, 0x07, 0xd0, 0x00, 0x26, 0x83, 0x6a, 0x1d, 0x1d, + 0xe3, 0x6a, 0xb3, 0x42, 0x02, 0xd8, 0x00, 0x23, 0x3b, 0x70, 0xf8, 0xbd, + 0x00, 0x23, 0xe9, 0x5e, 0x00, 0x29, 0x07, 0xd0, 0x20, 0x00, 0xff, 0xf7, + 0x5b, 0xff, 0x00, 0x23, 0xe9, 0x5e, 0x20, 0x00, 0x02, 0xf0, 0x98, 0xfb, + 0x01, 0x36, 0x30, 0x35, 0xea, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, + 0x00, 0x6b, 0x70, 0x47, 0x00, 0x23, 0x03, 0x63, 0x70, 0x47, 0x00, 0x00, + 0xf0, 0xb5, 0x87, 0xb0, 0x17, 0x00, 0x03, 0x93, 0xc2, 0x6d, 0x3f, 0x4b, + 0x05, 0x00, 0x0e, 0x00, 0x9a, 0x42, 0x04, 0xd0, 0x3d, 0x4c, 0x2c, 0x63, + 0x20, 0x00, 0x07, 0xb0, 0xf0, 0xbd, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, + 0x00, 0x2b, 0x01, 0xd1, 0x39, 0x4c, 0xf4, 0xe7, 0x08, 0x00, 0x03, 0xf0, + 0x32, 0xfc, 0x1f, 0x28, 0x01, 0xd9, 0x37, 0x4c, 0xed, 0xe7, 0x32, 0x00, + 0x05, 0xa9, 0x28, 0x00, 0x02, 0xf0, 0xf8, 0xfa, 0x00, 0x28, 0x02, 0xda, + 0x28, 0x63, 0x04, 0xb2, 0xe4, 0xe7, 0x04, 0xaa, 0x31, 0x00, 0x28, 0x00, + 0x01, 0xf0, 0xb2, 0xfe, 0x04, 0x00, 0x7b, 0x07, 0x34, 0xd4, 0x00, 0x28, + 0x24, 0xda, 0x05, 0x9b, 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, + 0x55, 0xfb, 0x2c, 0x63, 0x24, 0xb2, 0xd1, 0xe7, 0x00, 0x2c, 0xf4, 0xdb, + 0x02, 0xab, 0x19, 0x89, 0x03, 0x9b, 0x05, 0x9a, 0x00, 0x93, 0x28, 0x00, + 0x3b, 0x00, 0x01, 0xf0, 0x27, 0xf9, 0x04, 0x1e, 0xe9, 0xdb, 0xbb, 0x07, + 0x06, 0xd5, 0x00, 0x22, 0x05, 0x98, 0x11, 0x00, 0x01, 0xf0, 0xbe, 0xfe, + 0x04, 0x1e, 0xe0, 0xdb, 0x00, 0x22, 0x05, 0x9b, 0x9a, 0x61, 0x04, 0x24, + 0x1c, 0x5f, 0xb5, 0xe7, 0x00, 0x28, 0xe3, 0xd1, 0x44, 0x23, 0x3b, 0x40, + 0x44, 0x2b, 0xdf, 0xd1, 0x05, 0x9b, 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, + 0x02, 0xf0, 0x2a, 0xfb, 0x14, 0x4c, 0xa6, 0xe7, 0x00, 0x28, 0xf1, 0xd0, + 0x13, 0x4b, 0x9c, 0x42, 0xd0, 0xd1, 0x0a, 0x23, 0x02, 0xa9, 0x5b, 0x18, + 0x00, 0x22, 0x19, 0x00, 0x28, 0x00, 0x02, 0xf0, 0xfb, 0xf9, 0x04, 0x1e, + 0xbd, 0xdb, 0x02, 0xab, 0x59, 0x89, 0x04, 0xab, 0x01, 0x93, 0x01, 0x23, + 0x32, 0x00, 0x00, 0x93, 0x28, 0x00, 0x00, 0x23, 0x00, 0xf0, 0xf2, 0xff, + 0x04, 0x1e, 0xb0, 0xdb, 0x02, 0x23, 0x9f, 0x43, 0xb8, 0xe7, 0xc0, 0x46, + 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, 0xf0, 0xd8, 0xff, 0xff, + 0xcc, 0xd8, 0xff, 0xff, 0xd2, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xf7, 0xb5, 0x16, 0x00, 0x1c, 0x00, 0xc2, 0x6d, 0x29, 0x4b, 0x05, 0x00, + 0x0f, 0x00, 0x9a, 0x42, 0x03, 0xd0, 0x28, 0x4c, 0x2c, 0x63, 0x20, 0x00, + 0xfe, 0xbd, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, + 0x24, 0x4c, 0xf5, 0xe7, 0x01, 0xaa, 0x02, 0xf0, 0x01, 0xfb, 0x00, 0x28, + 0x05, 0xda, 0x04, 0x00, 0x28, 0x63, 0x21, 0x4b, 0x9c, 0x42, 0x0d, 0xd0, + 0xeb, 0xe7, 0x01, 0x9b, 0x9a, 0x8b, 0x12, 0x07, 0x01, 0xd4, 0x1e, 0x4c, + 0xe4, 0xe7, 0x9b, 0x68, 0x01, 0x33, 0x05, 0xd1, 0x00, 0x2c, 0x03, 0xdd, + 0x19, 0x4b, 0x2b, 0x63, 0x00, 0x24, 0xdc, 0xe7, 0x39, 0x00, 0x28, 0x00, + 0xff, 0xf7, 0x88, 0xfe, 0x01, 0x98, 0x81, 0x69, 0x83, 0x68, 0x0a, 0x19, + 0x9a, 0x42, 0x14, 0xd3, 0x5c, 0x1a, 0x00, 0x2c, 0xee, 0xdd, 0x33, 0x00, + 0x22, 0x00, 0x02, 0xf0, 0xa5, 0xf8, 0x0f, 0x4b, 0x98, 0x42, 0x06, 0xd1, + 0x20, 0x00, 0x01, 0x9a, 0x93, 0x69, 0x1b, 0x19, 0x93, 0x61, 0x04, 0x00, + 0xc1, 0xe7, 0x00, 0x28, 0x07, 0xda, 0x28, 0x63, 0xf9, 0xe7, 0x33, 0x00, + 0x22, 0x00, 0x02, 0xf0, 0x93, 0xf8, 0x00, 0x28, 0xc5, 0xdb, 0x01, 0x9a, + 0x93, 0x69, 0x1b, 0x19, 0x93, 0x61, 0xc2, 0xe7, 0x15, 0x03, 0x09, 0x20, + 0xd8, 0xd8, 0xff, 0xff, 0xf0, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xda, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x15, 0x00, 0x1e, 0x00, 0xc2, 0x6d, + 0x2d, 0x4b, 0x85, 0xb0, 0x04, 0x00, 0x0f, 0x00, 0x9a, 0x42, 0x03, 0xd0, + 0x2b, 0x48, 0x20, 0x63, 0x05, 0xb0, 0xf0, 0xbd, 0x03, 0x00, 0x54, 0x33, + 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x28, 0x48, 0xf5, 0xe7, 0x03, 0xaa, + 0x02, 0xf0, 0x9e, 0xfa, 0x00, 0x28, 0xf0, 0xdb, 0x39, 0x00, 0x20, 0x00, + 0xff, 0xf7, 0x3a, 0xfe, 0x03, 0x9f, 0xbb, 0x68, 0x5a, 0x1c, 0x00, 0xd1, + 0x00, 0x23, 0x01, 0x2e, 0x05, 0xd0, 0x02, 0x2e, 0x06, 0xd0, 0x00, 0x2d, + 0x06, 0xda, 0x1e, 0x48, 0xdf, 0xe7, 0xba, 0x69, 0xad, 0x18, 0xf8, 0xe7, + 0xed, 0x18, 0xf6, 0xe7, 0x9d, 0x42, 0x02, 0xdd, 0xbb, 0x61, 0x1a, 0x48, + 0xd5, 0xe7, 0x00, 0x26, 0xb5, 0x42, 0x0d, 0xdd, 0x68, 0x1e, 0xfb, 0x21, + 0x03, 0xf0, 0x52, 0xfa, 0x83, 0xb2, 0x68, 0x2b, 0x06, 0xd9, 0x18, 0x00, + 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0x4a, 0xfa, 0x01, 0x30, 0x86, 0xb2, + 0x3b, 0x8a, 0xb3, 0x42, 0x11, 0xd0, 0xf9, 0x88, 0x80, 0x23, 0x0a, 0x27, + 0x1b, 0x02, 0x6f, 0x44, 0x19, 0x43, 0x00, 0x97, 0x00, 0x23, 0x32, 0x00, + 0x20, 0x00, 0x00, 0xf0, 0xdd, 0xfc, 0x00, 0x28, 0xb3, 0xdb, 0x03, 0x9b, + 0x3a, 0x88, 0x1e, 0x82, 0xda, 0x81, 0x03, 0x9b, 0x28, 0x00, 0x9d, 0x61, + 0xac, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xc8, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x2a, 0x4b, 0xc2, 0x6d, 0x85, 0xb0, 0x05, 0x00, 0x0f, 0x00, + 0x9a, 0x42, 0x02, 0xd0, 0x27, 0x4c, 0x2c, 0x63, 0x3e, 0xe0, 0x03, 0x00, + 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x24, 0x4c, 0xf6, 0xe7, + 0x08, 0x00, 0x03, 0xf0, 0xda, 0xfa, 0x1f, 0x28, 0x01, 0xd9, 0x22, 0x4c, + 0xef, 0xe7, 0x00, 0x22, 0x03, 0xa9, 0x28, 0x00, 0x02, 0xf0, 0xa0, 0xf9, + 0x04, 0x1e, 0xe8, 0xdb, 0x0a, 0x26, 0x6e, 0x44, 0x32, 0x00, 0x39, 0x00, + 0x28, 0x00, 0x01, 0xf0, 0x5b, 0xfd, 0x04, 0x1e, 0x07, 0xd0, 0x03, 0x9b, + 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0x01, 0xfa, 0x00, 0x2c, + 0xd7, 0xdb, 0x00, 0x23, 0x31, 0x88, 0x03, 0x9a, 0x00, 0x93, 0x28, 0x00, + 0x00, 0xf0, 0xd8, 0xff, 0x04, 0x1e, 0x07, 0xd0, 0x03, 0x9b, 0x28, 0x00, + 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0xf0, 0xf9, 0x00, 0x2c, 0xc6, 0xdb, + 0x01, 0x22, 0x00, 0x21, 0x03, 0x98, 0x01, 0xf0, 0x69, 0xfd, 0x04, 0x1e, + 0x03, 0xd1, 0x00, 0x24, 0x20, 0x00, 0x05, 0xb0, 0xf0, 0xbd, 0x03, 0x9b, + 0x28, 0x00, 0x04, 0x21, 0x59, 0x5e, 0x02, 0xf0, 0xdd, 0xf9, 0x00, 0x2c, + 0xb3, 0xdb, 0xf2, 0xe7, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xcc, 0xd8, 0xff, 0xff, 0x0d, 0x4b, 0xc2, 0x6d, + 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x9a, 0x42, 0x02, 0xd0, 0x0b, 0x48, + 0x20, 0x63, 0x10, 0xe0, 0x03, 0x00, 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, + 0x01, 0xd1, 0x08, 0x48, 0xf6, 0xe7, 0xff, 0xf7, 0x7d, 0xfd, 0x00, 0x28, + 0xf2, 0xdb, 0x29, 0x00, 0x20, 0x00, 0x02, 0xf0, 0xb9, 0xf9, 0x00, 0x28, + 0xec, 0xdb, 0x70, 0xbd, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0x0e, 0x4b, 0xc2, 0x6d, 0x10, 0xb5, 0x04, 0x00, + 0x9a, 0x42, 0x02, 0xd0, 0x0c, 0x48, 0x20, 0x63, 0x10, 0xbd, 0x03, 0x00, + 0x54, 0x33, 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0x09, 0x48, 0xf6, 0xe7, + 0x00, 0x21, 0xfe, 0xf7, 0xe5, 0xfd, 0x20, 0x00, 0xff, 0xf7, 0x06, 0xf9, + 0x20, 0x00, 0xfe, 0xf7, 0x19, 0xfe, 0x20, 0x00, 0x00, 0xf0, 0x52, 0xfb, + 0xea, 0xe7, 0xc0, 0x46, 0x15, 0x03, 0x09, 0x20, 0xd8, 0xd8, 0xff, 0xff, + 0xf0, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x12, 0x01, 0x5c, 0x1c, 0x14, 0x19, + 0x05, 0x22, 0x85, 0xb0, 0xa4, 0xb2, 0x02, 0xad, 0x0f, 0x00, 0x00, 0x92, + 0x23, 0x02, 0x01, 0x95, 0x10, 0x32, 0x00, 0x21, 0x0a, 0x9e, 0xfd, 0xf7, + 0xde, 0xff, 0x00, 0x28, 0x1d, 0xdb, 0x2b, 0x88, 0xbb, 0x42, 0x1c, 0xd1, + 0x0b, 0x9a, 0x69, 0x88, 0x12, 0x88, 0x8a, 0x42, 0x17, 0xd1, 0x29, 0x79, + 0x7c, 0x20, 0x0d, 0x00, 0x85, 0x43, 0x80, 0x2d, 0x11, 0xd1, 0x1b, 0xb2, + 0x00, 0x2b, 0x03, 0xda, 0x4b, 0x06, 0x01, 0xd4, 0x00, 0x2a, 0x0a, 0xd0, + 0x30, 0x1e, 0x06, 0xd0, 0x30, 0x88, 0x00, 0x1b, 0x44, 0x42, 0x60, 0x41, + 0x03, 0x4c, 0x40, 0x42, 0x20, 0x40, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x48, + 0xfb, 0xe7, 0xc0, 0x46, 0xaa, 0xd8, 0xff, 0xff, 0x7f, 0xb5, 0x1d, 0x00, + 0x1b, 0x4b, 0x0c, 0x00, 0x9a, 0x42, 0x24, 0xd0, 0x13, 0x07, 0x25, 0xd0, + 0x80, 0x23, 0x9b, 0x01, 0x9a, 0x42, 0x23, 0xd8, 0x13, 0x02, 0x04, 0x21, + 0x62, 0x5e, 0x05, 0x21, 0x02, 0xae, 0x00, 0x91, 0x01, 0x96, 0x11, 0x31, + 0xfd, 0xf7, 0xa1, 0xff, 0x00, 0x28, 0x13, 0xdb, 0x33, 0x79, 0xda, 0x07, + 0x16, 0xd4, 0x5a, 0xb2, 0x00, 0x2a, 0x15, 0xda, 0x9a, 0x07, 0x15, 0xd4, + 0x5b, 0x07, 0x15, 0xd4, 0x06, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x11, 0xda, + 0x73, 0x88, 0xab, 0x42, 0x02, 0xd0, 0x09, 0x48, 0x00, 0xe0, 0x09, 0x48, + 0x04, 0xb0, 0x70, 0xbd, 0x08, 0x48, 0xfb, 0xe7, 0x08, 0x48, 0xf9, 0xe7, + 0x08, 0x48, 0xf7, 0xe7, 0x08, 0x48, 0xf5, 0xe7, 0x08, 0x48, 0xf3, 0xe7, + 0x08, 0x48, 0xf1, 0xe7, 0xff, 0xff, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, + 0xde, 0xd8, 0xff, 0xff, 0xdd, 0xd8, 0xff, 0xff, 0xdc, 0xd8, 0xff, 0xff, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0x12, 0x01, 0x30, 0xb5, 0x01, 0x33, 0xd3, 0x18, + 0x13, 0x4a, 0x8f, 0xb0, 0x89, 0x18, 0x13, 0x4a, 0x89, 0xb2, 0x9b, 0xb2, + 0x91, 0x42, 0x1b, 0xd8, 0x2e, 0x22, 0x02, 0xac, 0x00, 0x92, 0x1b, 0x02, + 0x01, 0x94, 0x00, 0x22, 0x15, 0x21, 0xfd, 0xf7, 0x56, 0xff, 0x00, 0x28, + 0x11, 0xdb, 0x65, 0x88, 0x00, 0x2d, 0x0d, 0xd1, 0x3d, 0x22, 0x23, 0x79, + 0x93, 0x43, 0xc0, 0x2b, 0x08, 0xd1, 0x15, 0x21, 0x12, 0x98, 0x69, 0x44, + 0x03, 0xf0, 0x99, 0xf9, 0x03, 0x00, 0x28, 0x00, 0x00, 0x2b, 0x00, 0xd0, + 0x03, 0x48, 0x0f, 0xb0, 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, + 0xfe, 0x7f, 0x00, 0x00, 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x05, 0x00, + 0x0c, 0x00, 0x21, 0x48, 0x01, 0x39, 0x89, 0xb2, 0x8f, 0xb0, 0x81, 0x42, + 0x01, 0xd9, 0x1f, 0x48, 0x27, 0xe0, 0x15, 0x99, 0x0e, 0x88, 0x14, 0x99, + 0x00, 0x29, 0x24, 0xd0, 0x21, 0xb2, 0x00, 0x29, 0x21, 0xda, 0x12, 0x01, + 0x01, 0x33, 0xd3, 0x18, 0x2e, 0x22, 0x9b, 0xb2, 0x02, 0xaf, 0x00, 0x92, + 0x1b, 0x02, 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x28, 0x00, 0xfd, 0xf7, + 0x18, 0xff, 0x00, 0x28, 0x0f, 0xdb, 0x7b, 0x88, 0x00, 0x2b, 0x0e, 0xd1, + 0x3d, 0x22, 0x3b, 0x79, 0x93, 0x43, 0xc0, 0x2b, 0x09, 0xd1, 0x15, 0x21, + 0x14, 0x98, 0x69, 0x44, 0x03, 0xf0, 0x5b, 0xf9, 0x00, 0x28, 0x02, 0xd1, + 0x0b, 0x48, 0x0f, 0xb0, 0xf0, 0xbd, 0x64, 0x04, 0x64, 0x0c, 0xa4, 0x1b, + 0xe3, 0x10, 0xff, 0x2b, 0xcd, 0xd8, 0x6a, 0x6a, 0xd2, 0x18, 0x07, 0x23, + 0x1c, 0x40, 0x06, 0x3b, 0xa3, 0x40, 0x11, 0x78, 0x0b, 0x43, 0x13, 0x70, + 0xc3, 0xe7, 0xc0, 0x46, 0xfd, 0xff, 0x00, 0x00, 0xaa, 0xd8, 0xff, 0xff, + 0xd9, 0xd8, 0xff, 0xff, 0x09, 0x4a, 0x91, 0x42, 0x06, 0xd1, 0x00, 0x2b, + 0x02, 0xd1, 0x43, 0x6b, 0x01, 0x33, 0x43, 0x63, 0x06, 0x48, 0x70, 0x47, + 0x00, 0x29, 0x03, 0xd1, 0xc3, 0x6b, 0x01, 0x33, 0xc3, 0x63, 0xf7, 0xe7, + 0x83, 0x6b, 0x01, 0x33, 0x83, 0x63, 0xf3, 0xe7, 0xff, 0xff, 0x00, 0x00, + 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x85, 0xb0, 0x01, 0x91, 0x02, 0x92, + 0x07, 0x89, 0x06, 0x00, 0x00, 0x25, 0x68, 0x2f, 0x06, 0xd9, 0x38, 0x00, + 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0x58, 0xf8, 0x01, 0x30, 0x85, 0xb2, + 0x74, 0x89, 0x00, 0x20, 0x68, 0x2c, 0x06, 0xd9, 0x20, 0x00, 0x7c, 0x21, + 0x69, 0x38, 0x03, 0xf0, 0x4d, 0xf8, 0x01, 0x30, 0x80, 0xb2, 0x01, 0x9b, + 0x9d, 0x42, 0x1c, 0xd8, 0x83, 0x42, 0x1a, 0xd8, 0x00, 0x2b, 0x1a, 0xd0, + 0x7c, 0x23, 0x01, 0x9a, 0x5a, 0x43, 0x13, 0x3a, 0x92, 0xb2, 0x9b, 0x18, + 0x01, 0x34, 0x9b, 0xb2, 0xa3, 0x42, 0x00, 0xdd, 0x23, 0x00, 0x9b, 0xb2, + 0x03, 0x93, 0x3c, 0x1c, 0x97, 0x42, 0x00, 0xd2, 0x14, 0x1c, 0xa4, 0xb2, + 0x25, 0x1d, 0x14, 0x4f, 0x6d, 0x00, 0x03, 0x9a, 0xa3, 0xb2, 0x9a, 0x42, + 0x04, 0xd8, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x9a, 0x69, 0x23, 0xe6, 0xe7, + 0x01, 0x9a, 0x00, 0x2a, 0x0c, 0xd1, 0x02, 0x9b, 0x5b, 0x19, 0xda, 0x8c, + 0x02, 0x35, 0xba, 0x42, 0xf1, 0xd0, 0x33, 0x89, 0x31, 0x68, 0xe3, 0x1a, + 0x5b, 0x00, 0x5a, 0x52, 0x01, 0x34, 0xe6, 0xe7, 0x29, 0x00, 0x68, 0x2b, + 0x06, 0xd9, 0x20, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x03, 0xf0, 0x94, 0xf8, + 0x04, 0x31, 0x49, 0x00, 0x02, 0x9b, 0x5a, 0x5a, 0xe8, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0x01, 0x00, 0x10, 0xb5, 0x21, 0x24, 0x03, 0x00, + 0x05, 0x48, 0x20, 0x31, 0x1a, 0x78, 0x00, 0x2a, 0x02, 0xd0, 0x01, 0x33, + 0x8b, 0x42, 0x00, 0xd1, 0x10, 0xbd, 0x60, 0x43, 0x50, 0x40, 0xf5, 0xe7, + 0x05, 0x15, 0x00, 0x00, 0x30, 0xb5, 0x1c, 0x00, 0x19, 0x4b, 0x85, 0xb0, + 0x9a, 0x42, 0x20, 0xd0, 0x13, 0x07, 0x21, 0xd0, 0x80, 0x23, 0x9b, 0x01, + 0x9a, 0x42, 0x1f, 0xd8, 0x13, 0x02, 0x00, 0x22, 0x8a, 0x5e, 0x05, 0x21, + 0x02, 0xad, 0x00, 0x91, 0x01, 0x95, 0x12, 0x31, 0xfd, 0xf7, 0x4d, 0xfe, + 0x00, 0x28, 0x0f, 0xdb, 0x2b, 0x79, 0xda, 0x07, 0x12, 0xd4, 0x5a, 0xb2, + 0x00, 0x2a, 0x11, 0xda, 0x9a, 0x07, 0x11, 0xd4, 0x5b, 0x07, 0x11, 0xd5, + 0x6b, 0x88, 0xa3, 0x42, 0x02, 0xd0, 0x09, 0x48, 0x00, 0xe0, 0x09, 0x48, + 0x05, 0xb0, 0x30, 0xbd, 0x08, 0x48, 0xfb, 0xe7, 0x08, 0x48, 0xf9, 0xe7, + 0x08, 0x48, 0xf7, 0xe7, 0x08, 0x48, 0xf5, 0xe7, 0x08, 0x48, 0xf3, 0xe7, + 0x08, 0x48, 0xf1, 0xe7, 0xff, 0xff, 0x00, 0x00, 0xe2, 0xd8, 0xff, 0xff, + 0xe1, 0xd8, 0xff, 0xff, 0xe0, 0xd8, 0xff, 0xff, 0xdf, 0xd8, 0xff, 0xff, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xe5, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0c, 0x00, 0x1f, 0x49, 0x06, 0x00, + 0x61, 0x18, 0x1f, 0x48, 0x8f, 0xb0, 0x89, 0xb2, 0x14, 0x9d, 0x81, 0x42, + 0x33, 0xd8, 0x01, 0x33, 0x12, 0x03, 0x1b, 0x02, 0x9b, 0x18, 0x2e, 0x22, + 0x02, 0xaf, 0x00, 0x92, 0x01, 0x97, 0x00, 0x22, 0x15, 0x21, 0x30, 0x00, + 0xfd, 0xf7, 0x03, 0xfe, 0x00, 0x28, 0x24, 0xd1, 0x7b, 0x88, 0x00, 0x2b, + 0x21, 0xd1, 0x79, 0x22, 0x3b, 0x79, 0x93, 0x43, 0x80, 0x2b, 0x1c, 0xd1, + 0xa8, 0x68, 0x00, 0x28, 0x08, 0xd0, 0x15, 0x21, 0x69, 0x44, 0x03, 0xf0, + 0x44, 0xf8, 0x00, 0x28, 0x02, 0xd1, 0x0d, 0x48, 0x0f, 0xb0, 0xf0, 0xbd, + 0x28, 0x88, 0x61, 0x04, 0x49, 0x0c, 0x81, 0x42, 0x0b, 0xd3, 0x6b, 0x88, + 0x8b, 0x42, 0x08, 0xd3, 0x08, 0x1a, 0x69, 0x68, 0x02, 0xf0, 0x72, 0xff, + 0x73, 0x6a, 0x18, 0x18, 0x03, 0x78, 0x01, 0x33, 0x03, 0x70, 0x04, 0x48, + 0xea, 0xe7, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, 0xfe, 0x7f, 0x00, 0x00, + 0xd9, 0xd8, 0xff, 0xff, 0xaa, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x15, 0x00, + 0x1e, 0x00, 0x95, 0xb0, 0x1a, 0x9f, 0x02, 0x90, 0x03, 0x91, 0x00, 0x2f, + 0x02, 0xd1, 0x38, 0x00, 0x15, 0xb0, 0xf0, 0xbd, 0x3c, 0x00, 0x40, 0x2f, + 0x00, 0xd9, 0x40, 0x24, 0x04, 0xab, 0x01, 0x93, 0x00, 0x94, 0x33, 0x00, + 0x03, 0x9a, 0x0b, 0x21, 0x02, 0x98, 0xfd, 0xf7, 0xb8, 0xfd, 0x00, 0x28, + 0xee, 0xdb, 0x04, 0xab, 0x01, 0x93, 0x00, 0x94, 0x2b, 0x00, 0x03, 0x9a, + 0x0f, 0x21, 0x02, 0x98, 0xfd, 0xf7, 0x11, 0xfe, 0x00, 0x28, 0xe3, 0xdb, + 0x3f, 0x1b, 0x36, 0x19, 0x2d, 0x19, 0xdc, 0xe7, 0xf0, 0xb5, 0x14, 0x00, + 0x0f, 0x22, 0x8d, 0xb0, 0x06, 0x93, 0x12, 0xab, 0x1b, 0x88, 0x06, 0x00, + 0x0b, 0x93, 0xc3, 0x68, 0x0f, 0x00, 0x5a, 0x43, 0x07, 0x92, 0x02, 0x6a, + 0x09, 0x92, 0x0e, 0x2c, 0x00, 0xdc, 0xa4, 0xe0, 0x01, 0x37, 0xbf, 0xb2, + 0xbb, 0x42, 0x51, 0xd9, 0x00, 0x24, 0x3b, 0x03, 0x03, 0x93, 0x07, 0x9b, + 0x00, 0x2b, 0x4f, 0xdd, 0x7f, 0x22, 0xe3, 0x17, 0x13, 0x40, 0x1b, 0x19, + 0xdb, 0x11, 0xda, 0x01, 0x05, 0x92, 0x09, 0x9a, 0x1b, 0x02, 0xd3, 0x1a, + 0x04, 0x93, 0x03, 0x9a, 0x09, 0x9b, 0x14, 0x21, 0x9b, 0x18, 0x04, 0x9a, + 0x30, 0x00, 0x9b, 0x1a, 0x0a, 0x93, 0x33, 0x6a, 0x00, 0x22, 0x01, 0x93, + 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, 0x0a, 0x9b, 0xfd, 0xf7, 0x6f, 0xfd, + 0x25, 0x00, 0x07, 0x9b, 0x02, 0x90, 0x08, 0x93, 0x08, 0x9b, 0x2c, 0x00, + 0x07, 0x93, 0x02, 0x9b, 0x00, 0x2b, 0x05, 0xd1, 0x05, 0x9b, 0xeb, 0x1a, + 0x7f, 0x2b, 0x01, 0xdc, 0x0e, 0x2d, 0x28, 0xdd, 0x05, 0x9b, 0x80, 0x33, + 0x05, 0x93, 0x04, 0x9b, 0x01, 0x3b, 0xff, 0x3b, 0x04, 0x93, 0x02, 0x9b, + 0x00, 0x2b, 0x02, 0xd1, 0x05, 0x9b, 0x80, 0x2b, 0xd1, 0xd1, 0x01, 0x37, + 0xf3, 0x68, 0xbf, 0xb2, 0x9f, 0x42, 0x55, 0xd2, 0x80, 0x22, 0x52, 0x01, + 0x94, 0x46, 0x03, 0x9b, 0x63, 0x44, 0x03, 0x93, 0x00, 0x24, 0x02, 0x9b, + 0xa3, 0x42, 0xb4, 0xd0, 0x02, 0x9b, 0x00, 0x2b, 0x06, 0xdb, 0x03, 0xe0, + 0x04, 0x24, 0x06, 0x9b, 0x1c, 0x40, 0x4d, 0xd0, 0x29, 0x4b, 0x02, 0x93, + 0x02, 0x98, 0x0d, 0xb0, 0xf0, 0xbd, 0x01, 0x22, 0x06, 0x9b, 0x13, 0x42, + 0x05, 0xd0, 0x04, 0x9a, 0x6b, 0x00, 0xd3, 0x5a, 0x0b, 0x9a, 0x93, 0x42, + 0x2f, 0xd1, 0x16, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x1f, 0x80, 0x17, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x1d, 0x60, 0x13, 0x9b, 0x00, 0x2b, 0xe7, 0xd0, + 0x02, 0x22, 0x06, 0x9b, 0x0b, 0x99, 0x13, 0x42, 0x02, 0xd1, 0x04, 0x9a, + 0x6b, 0x00, 0xd1, 0x5a, 0x15, 0x9b, 0x3a, 0x00, 0x01, 0x93, 0x14, 0x9b, + 0x30, 0x00, 0x00, 0x93, 0x13, 0x9c, 0x2b, 0x00, 0xa0, 0x47, 0x15, 0x4b, + 0xc3, 0x18, 0x01, 0x2b, 0x21, 0xd8, 0x14, 0x4b, 0x98, 0x42, 0x0c, 0xd1, + 0x33, 0x6a, 0x00, 0x22, 0x01, 0x93, 0x80, 0x23, 0x5b, 0x00, 0x00, 0x93, + 0x14, 0x21, 0x0a, 0x9b, 0x30, 0x00, 0xfd, 0xf7, 0xfe, 0xfc, 0x00, 0x28, + 0x11, 0xdb, 0x08, 0x9b, 0x01, 0x35, 0x01, 0x3b, 0x08, 0x93, 0x8b, 0xe7, + 0x04, 0x23, 0x06, 0x9a, 0x13, 0x40, 0xb7, 0xd1, 0x03, 0x93, 0x1f, 0x00, + 0xa8, 0xe7, 0x0b, 0x03, 0x03, 0x93, 0x5e, 0xe7, 0x03, 0x94, 0x27, 0x00, + 0x5b, 0xe7, 0x02, 0x90, 0xae, 0xe7, 0xc0, 0x46, 0xa8, 0xd8, 0xff, 0xff, + 0x57, 0x27, 0x00, 0x00, 0xa9, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x04, 0x00, + 0x0d, 0x03, 0x0f, 0x00, 0x80, 0x21, 0x85, 0xb0, 0x49, 0x01, 0xa3, 0x68, + 0x28, 0x00, 0x98, 0x47, 0x63, 0x6b, 0x22, 0x00, 0x01, 0x33, 0x63, 0x63, + 0x02, 0x26, 0x2b, 0x00, 0x42, 0x32, 0x01, 0x92, 0xfe, 0x33, 0x00, 0x96, + 0x00, 0x22, 0x19, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x2c, 0xfd, 0x00, 0x28, + 0x1a, 0xdb, 0xe3, 0x68, 0x0e, 0x22, 0xdb, 0x1b, 0x0d, 0x4f, 0x6a, 0x44, + 0x5f, 0x40, 0x2b, 0x00, 0x17, 0x80, 0xfc, 0x33, 0x01, 0x92, 0x00, 0x96, + 0x00, 0x22, 0x19, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x1a, 0xfd, 0x00, 0x28, + 0x08, 0xdb, 0x80, 0x22, 0x04, 0x34, 0xe3, 0x8f, 0x12, 0x02, 0x01, 0x33, + 0x9b, 0xb2, 0x93, 0x42, 0x02, 0xd0, 0xe3, 0x87, 0x05, 0xb0, 0xf0, 0xbd, + 0x00, 0x23, 0xfa, 0xe7, 0x29, 0x04, 0x00, 0x00, 0xf0, 0xb5, 0x00, 0x27, + 0x04, 0x00, 0x8b, 0xb0, 0x3b, 0x4d, 0x08, 0xab, 0x1f, 0x80, 0x07, 0x95, + 0x08, 0xae, 0x33, 0x88, 0xe2, 0x68, 0x93, 0x42, 0x24, 0xd3, 0x38, 0x4a, + 0x7b, 0x1b, 0x01, 0x35, 0x93, 0x42, 0x00, 0xdc, 0x7d, 0x1c, 0x23, 0x1d, + 0xad, 0xb2, 0xdd, 0x87, 0x07, 0x9b, 0x1a, 0x00, 0x31, 0x4b, 0x9a, 0x42, + 0x58, 0xd1, 0x00, 0x25, 0x09, 0xab, 0x05, 0x93, 0x30, 0x4b, 0x65, 0x63, + 0x01, 0x93, 0xa5, 0x63, 0x2b, 0x00, 0xe5, 0x63, 0x04, 0x96, 0x03, 0x95, + 0x02, 0x95, 0x00, 0x95, 0x2a, 0x00, 0x29, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0xd1, 0xfe, 0x2a, 0x4b, 0x98, 0x42, 0x41, 0xd1, 0x28, 0x00, 0x3f, 0xe0, + 0x1a, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, 0x1b, 0x03, + 0x00, 0x92, 0xfc, 0x33, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, 0xfd, 0xf7, + 0x66, 0xfc, 0x00, 0x28, 0x30, 0xdb, 0xe2, 0x68, 0x33, 0x88, 0xd1, 0x1a, + 0x1f, 0x4a, 0x4a, 0x40, 0x02, 0xa9, 0x49, 0x8b, 0x92, 0xb2, 0x91, 0x42, + 0x05, 0xd0, 0x07, 0x9a, 0x11, 0x00, 0x17, 0x4a, 0x91, 0x42, 0x20, 0xd1, + 0x07, 0x93, 0x02, 0x22, 0x1b, 0x03, 0x09, 0xae, 0x00, 0x92, 0xfe, 0x33, + 0x01, 0x96, 0x00, 0x22, 0x15, 0x21, 0x20, 0x00, 0xfd, 0xf7, 0x49, 0xfc, + 0x00, 0x28, 0x13, 0xdb, 0x33, 0x88, 0x0e, 0x4a, 0x93, 0x42, 0x09, 0xd0, + 0x1a, 0x1c, 0xab, 0x42, 0x00, 0xd9, 0x2a, 0x1c, 0x95, 0xb2, 0x1a, 0x1c, + 0xbb, 0x42, 0x00, 0xd2, 0x3a, 0x1c, 0x97, 0xb2, 0x08, 0xaa, 0x13, 0x88, + 0x01, 0x33, 0x13, 0x80, 0x96, 0xe7, 0x0a, 0x48, 0x0b, 0xb0, 0xf0, 0xbd, + 0x07, 0x99, 0x20, 0x00, 0xff, 0xf7, 0x4c, 0xff, 0x00, 0x28, 0xa0, 0xda, + 0xf6, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0xff, 0x7f, 0x00, 0x00, + 0xc9, 0x49, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, 0x29, 0x04, 0x00, 0x00, + 0xd7, 0xd8, 0xff, 0xff, 0x10, 0xb5, 0x86, 0xb0, 0x09, 0x9c, 0x00, 0x93, + 0x05, 0x94, 0x08, 0x9c, 0x01, 0x23, 0x04, 0x94, 0x00, 0x24, 0x03, 0x94, + 0x02, 0x94, 0x01, 0x94, 0xff, 0xf7, 0x68, 0xfe, 0x02, 0x4b, 0x98, 0x42, + 0x00, 0xd1, 0x02, 0x48, 0x06, 0xb0, 0x10, 0xbd, 0xa8, 0xd8, 0xff, 0xff, + 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x1e, 0x00, 0x03, 0x00, 0x85, 0xb0, + 0x03, 0x92, 0x40, 0x33, 0x0f, 0x00, 0x19, 0x78, 0x04, 0x00, 0x0a, 0x9d, + 0x00, 0x29, 0x0b, 0xd0, 0x01, 0x95, 0x00, 0x96, 0x12, 0x4b, 0x03, 0x9a, + 0x39, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xd4, 0xff, 0x00, 0x28, 0x10, 0xd0, + 0x05, 0xb0, 0xf0, 0xbd, 0x43, 0x6b, 0x01, 0x2b, 0xf0, 0xd8, 0xfe, 0xf7, + 0x49, 0xfd, 0x0c, 0x4b, 0x98, 0x42, 0x01, 0xd0, 0x00, 0x28, 0xf3, 0xdb, + 0x63, 0x6b, 0x01, 0x2b, 0xe6, 0xd8, 0x09, 0x48, 0xee, 0xe7, 0x33, 0x88, + 0x23, 0x82, 0x2b, 0x68, 0x01, 0x33, 0x63, 0x61, 0x2b, 0x68, 0x00, 0x2b, + 0xe6, 0xd1, 0x63, 0x6b, 0x01, 0x3b, 0x63, 0x63, 0xe2, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xd3, 0xd8, 0xff, 0xff, 0xef, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x1e, 0x27, 0x8b, 0xb0, 0x6f, 0x44, 0x07, 0xae, 0x3a, 0x80, + 0x33, 0x80, 0x04, 0x00, 0x0d, 0x00, 0xc2, 0x69, 0x01, 0x8b, 0x00, 0x20, + 0x83, 0x42, 0x00, 0xd0, 0x30, 0x00, 0x22, 0x26, 0x09, 0xab, 0x05, 0x93, + 0x0f, 0x4b, 0x6e, 0x44, 0x02, 0x90, 0x01, 0x93, 0x04, 0x96, 0x01, 0x23, + 0x03, 0x97, 0x00, 0x95, 0x20, 0x00, 0xff, 0xf7, 0x07, 0xfe, 0x0b, 0x4b, + 0x98, 0x42, 0x0f, 0xd0, 0x00, 0x28, 0x0b, 0xdb, 0x10, 0x9b, 0x31, 0x88, + 0x09, 0x9a, 0x00, 0x2b, 0x04, 0xd0, 0x0b, 0x01, 0x9b, 0x18, 0x10, 0x9d, + 0x01, 0x33, 0x2b, 0x80, 0x21, 0x83, 0xe2, 0x61, 0x0b, 0xb0, 0xf0, 0xbd, + 0x02, 0x48, 0xfb, 0xe7, 0xc5, 0x47, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x1e, 0x27, 0x8b, 0xb0, 0x6f, 0x44, + 0x07, 0xae, 0x3a, 0x80, 0x33, 0x80, 0x04, 0x00, 0x0d, 0x00, 0xc2, 0x69, + 0x01, 0x8b, 0x00, 0x20, 0x83, 0x42, 0x00, 0xd0, 0x30, 0x00, 0x22, 0x26, + 0x09, 0xab, 0x05, 0x93, 0x0f, 0x4b, 0x6e, 0x44, 0x02, 0x90, 0x01, 0x93, + 0x04, 0x96, 0x02, 0x23, 0x03, 0x97, 0x00, 0x95, 0x20, 0x00, 0xff, 0xf7, + 0xcf, 0xfd, 0x0b, 0x4b, 0x98, 0x42, 0x0f, 0xd0, 0x00, 0x28, 0x0b, 0xdb, + 0x10, 0x9b, 0x31, 0x88, 0x09, 0x9a, 0x00, 0x2b, 0x04, 0xd0, 0x0b, 0x01, + 0x9b, 0x18, 0x10, 0x9d, 0x01, 0x33, 0x2b, 0x80, 0x21, 0x83, 0xe2, 0x61, + 0x0b, 0xb0, 0xf0, 0xbd, 0x02, 0x48, 0xfb, 0xe7, 0xc5, 0x47, 0x00, 0x00, + 0xa8, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x0e, 0x27, + 0x12, 0x26, 0x89, 0xb0, 0x03, 0x93, 0x10, 0xab, 0x1b, 0x78, 0x15, 0x00, + 0x04, 0x93, 0x02, 0xab, 0xff, 0x18, 0x39, 0x80, 0xf6, 0x18, 0x07, 0xab, + 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x33, 0x00, 0x04, 0x00, 0xff, 0xf7, + 0x41, 0xff, 0x00, 0x28, 0x67, 0xdb, 0x33, 0x88, 0x07, 0x9a, 0x1b, 0x03, + 0x52, 0x00, 0x9b, 0x18, 0x02, 0x22, 0x01, 0x97, 0x00, 0x92, 0x04, 0x21, + 0x00, 0x22, 0x20, 0x00, 0xfd, 0xf7, 0x9b, 0xfb, 0x00, 0x28, 0x58, 0xdb, + 0x01, 0x22, 0xa3, 0x6b, 0x07, 0x21, 0x01, 0x33, 0xa3, 0x63, 0x2b, 0x79, + 0x20, 0x00, 0x93, 0x43, 0x2b, 0x71, 0x07, 0x9b, 0x9b, 0x18, 0x32, 0x88, + 0x1b, 0x02, 0x12, 0x03, 0x9b, 0x18, 0x05, 0x22, 0x01, 0x95, 0x00, 0x92, + 0x00, 0x22, 0xfd, 0xf7, 0x84, 0xfb, 0x00, 0x28, 0x41, 0xdb, 0x03, 0x9b, + 0x00, 0x2b, 0x13, 0xd0, 0x07, 0x9b, 0x32, 0x88, 0x01, 0x33, 0x12, 0x03, + 0x1b, 0x02, 0x9b, 0x18, 0x0f, 0x9a, 0x05, 0x33, 0x9b, 0x18, 0x03, 0x9a, + 0x07, 0x21, 0x01, 0x92, 0x0e, 0x9a, 0x20, 0x00, 0x00, 0x92, 0x00, 0x22, + 0xfd, 0xf7, 0x6d, 0xfb, 0x00, 0x28, 0x2a, 0xdb, 0x04, 0x9b, 0x00, 0x2b, + 0x1a, 0xd0, 0x02, 0x22, 0x2b, 0x79, 0x13, 0x42, 0x16, 0xd0, 0x93, 0x43, + 0x02, 0xa9, 0x10, 0x32, 0x2b, 0x71, 0x52, 0x18, 0x07, 0x9b, 0x12, 0x88, + 0x01, 0x33, 0x12, 0x03, 0x1b, 0x02, 0x9b, 0x18, 0x01, 0x22, 0x04, 0x35, + 0x00, 0x92, 0x04, 0x33, 0x01, 0x95, 0x00, 0x22, 0x07, 0x21, 0x20, 0x00, + 0xfd, 0xf7, 0x4f, 0xfb, 0x00, 0x28, 0x0c, 0xdb, 0x11, 0x9b, 0x00, 0x2b, + 0x09, 0xd0, 0x12, 0x23, 0x02, 0xaa, 0x9b, 0x18, 0x1b, 0x88, 0x07, 0x9a, + 0x1b, 0x01, 0xd3, 0x18, 0x11, 0x9a, 0x01, 0x33, 0x13, 0x80, 0x09, 0xb0, + 0xf0, 0xbd, 0x00, 0x00, 0x7f, 0xb5, 0x0e, 0x22, 0x00, 0x26, 0x0f, 0x23, + 0x0c, 0x00, 0x6a, 0x44, 0x16, 0x80, 0x01, 0x92, 0x02, 0x22, 0x0b, 0x40, + 0x11, 0x49, 0x00, 0x92, 0x5b, 0x18, 0x21, 0x09, 0x09, 0x03, 0x5b, 0x00, + 0x5b, 0x18, 0x32, 0x00, 0x31, 0x00, 0x05, 0x00, 0xfd, 0xf7, 0x27, 0xfb, + 0xb0, 0x42, 0x13, 0xdb, 0xeb, 0x6b, 0x0d, 0x22, 0x01, 0x33, 0xeb, 0x63, + 0xab, 0x6b, 0x6a, 0x44, 0x01, 0x3b, 0xab, 0x63, 0x7e, 0x23, 0x13, 0x70, + 0x01, 0x92, 0x01, 0x22, 0x24, 0x02, 0x00, 0x92, 0x23, 0x1d, 0x32, 0x00, + 0x03, 0x21, 0x28, 0x00, 0xfd, 0xf7, 0x11, 0xfb, 0x04, 0xb0, 0x70, 0xbd, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x89, 0xb0, 0x15, 0x00, 0x0e, 0xaa, + 0x03, 0x91, 0x02, 0xca, 0x12, 0x24, 0x12, 0x88, 0x02, 0x91, 0x04, 0x92, + 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x13, 0x80, 0x07, 0xab, 0x64, 0x18, + 0x01, 0x8a, 0x00, 0x93, 0x42, 0x69, 0x23, 0x00, 0x06, 0x00, 0x10, 0x9f, + 0xff, 0xf7, 0x8c, 0xfe, 0x00, 0x28, 0x5f, 0xdb, 0x24, 0x88, 0x07, 0x9b, + 0x24, 0x01, 0x1c, 0x19, 0x01, 0x34, 0xa4, 0xb2, 0x00, 0x2f, 0x00, 0xd0, + 0x3c, 0x80, 0x27, 0x02, 0x00, 0x2d, 0x1e, 0xd1, 0x80, 0x22, 0x04, 0x9b, + 0x52, 0x00, 0x1b, 0x02, 0x00, 0x92, 0x03, 0x99, 0x3a, 0x00, 0x30, 0x00, + 0xff, 0xf7, 0xa8, 0xfc, 0x00, 0x23, 0x02, 0x9d, 0x02, 0x93, 0x24, 0xe0, + 0x03, 0x22, 0x2b, 0x79, 0x04, 0x35, 0x93, 0x43, 0x2b, 0x70, 0x02, 0x3a, + 0x00, 0x92, 0x3b, 0x1d, 0x01, 0x95, 0x03, 0x9a, 0x07, 0x21, 0x30, 0x00, + 0xfd, 0xf7, 0xcb, 0xfa, 0x00, 0x28, 0x31, 0xda, 0x34, 0xe0, 0x01, 0x22, + 0x2b, 0x79, 0x10, 0x00, 0x59, 0x08, 0x93, 0x43, 0x92, 0x18, 0x13, 0x43, + 0x2b, 0x71, 0x80, 0x23, 0x88, 0x43, 0x5b, 0x00, 0x02, 0x90, 0x00, 0x93, + 0x01, 0x95, 0x3b, 0x00, 0x00, 0x22, 0x07, 0x21, 0x30, 0x00, 0xfd, 0xf7, + 0xb4, 0xfa, 0x00, 0x28, 0x1e, 0xdb, 0x0f, 0x23, 0x0f, 0x4a, 0x23, 0x40, + 0x9b, 0x18, 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, + 0x24, 0x09, 0x5b, 0x00, 0x24, 0x03, 0x00, 0x92, 0x1b, 0x19, 0x00, 0x22, + 0x04, 0x21, 0x30, 0x00, 0xfd, 0xf7, 0x9f, 0xfa, 0x00, 0x28, 0x09, 0xdb, + 0xb3, 0x6b, 0x01, 0x33, 0xb3, 0x63, 0x02, 0x9b, 0x00, 0x2b, 0xbd, 0xd1, + 0x04, 0x99, 0x30, 0x00, 0xff, 0xf7, 0x56, 0xff, 0x09, 0xb0, 0xf0, 0xbd, + 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xb5, 0x87, 0xb0, 0x04, 0x93, 0x0c, 0xab, + 0x1b, 0x88, 0x07, 0x00, 0x00, 0x93, 0x0d, 0xab, 0x1b, 0x88, 0x15, 0x00, + 0x03, 0x93, 0x04, 0x9b, 0x05, 0x91, 0x5b, 0x04, 0x5b, 0x0c, 0x02, 0x93, + 0x83, 0x6a, 0x1e, 0x1d, 0x00, 0x23, 0x34, 0x00, 0x01, 0x93, 0xfb, 0x6a, + 0x01, 0x9a, 0x93, 0x42, 0x08, 0xd8, 0x01, 0x2d, 0x00, 0xd8, 0x6e, 0xe0, + 0x3c, 0x6d, 0x00, 0x2c, 0x00, 0xd0, 0x6c, 0xe0, 0x07, 0xb0, 0xf0, 0xbd, + 0x43, 0x4a, 0x63, 0x88, 0x13, 0x40, 0x02, 0x9a, 0x93, 0x42, 0x38, 0xd1, + 0x00, 0x9b, 0x00, 0x2b, 0x2b, 0xd1, 0x02, 0x2d, 0x38, 0xd0, 0xa3, 0x8c, + 0x00, 0x2b, 0x30, 0xd0, 0x6b, 0x46, 0x9b, 0x89, 0x23, 0x81, 0x0e, 0x9b, + 0x00, 0x2b, 0x20, 0xd0, 0x0e, 0x9a, 0x63, 0x60, 0xe1, 0x69, 0x00, 0x9b, + 0x01, 0x32, 0x09, 0xd0, 0x0e, 0x9b, 0x00, 0x29, 0x06, 0xd0, 0xca, 0x68, + 0x0b, 0x8a, 0x9b, 0x18, 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd2, 0x13, 0x00, + 0x22, 0x69, 0x9a, 0x42, 0x00, 0xd9, 0x23, 0x61, 0x62, 0x69, 0x9a, 0x42, + 0x00, 0xd9, 0x63, 0x61, 0x00, 0x29, 0x06, 0xd0, 0xca, 0x68, 0x01, 0x33, + 0x9a, 0x42, 0x02, 0xd9, 0x38, 0x00, 0xfd, 0xf7, 0x91, 0xfa, 0xa3, 0x89, + 0x00, 0x9a, 0x93, 0x42, 0x05, 0xd1, 0x00, 0x23, 0x02, 0x2d, 0x01, 0xd0, + 0x6b, 0x46, 0x9b, 0x89, 0x63, 0x81, 0x01, 0x9b, 0x30, 0x34, 0x01, 0x33, + 0x01, 0x93, 0xae, 0xe7, 0x00, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x05, 0xd0, + 0xe1, 0x69, 0x00, 0x29, 0x02, 0xd0, 0x38, 0x00, 0xfd, 0xf7, 0x78, 0xfa, + 0x00, 0x23, 0x23, 0x80, 0x63, 0x80, 0xe2, 0xe7, 0x00, 0x22, 0xb3, 0x5e, + 0x00, 0x2b, 0x0c, 0xd0, 0xb0, 0x6a, 0x00, 0x28, 0x09, 0xd0, 0x17, 0x4a, + 0x73, 0x88, 0x13, 0x40, 0x02, 0x9a, 0x93, 0x42, 0x03, 0xd1, 0x05, 0x9a, + 0x00, 0x99, 0xff, 0xf7, 0xd1, 0xfa, 0x01, 0x34, 0x30, 0x36, 0xfb, 0x6a, + 0xa3, 0x42, 0xe9, 0xd8, 0x90, 0xe7, 0x00, 0x24, 0xf9, 0xe7, 0x00, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x8e, 0xe7, 0x6b, 0x46, 0x10, 0x22, 0x9b, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0x88, 0xe7, 0x00, 0x99, 0x01, 0x2d, 0x08, 0xd0, + 0x00, 0x2d, 0x0b, 0xd0, 0xeb, 0x1e, 0x01, 0x2b, 0x08, 0xd9, 0x29, 0x00, + 0x02, 0x2d, 0x00, 0xd0, 0x7c, 0xe7, 0x03, 0x9b, 0x02, 0x9a, 0x38, 0x00, + 0xa0, 0x47, 0x77, 0xe7, 0x01, 0x21, 0xf8, 0xe7, 0xff, 0x7f, 0xff, 0xff, + 0xf0, 0xb5, 0x16, 0x27, 0x97, 0xb0, 0x1c, 0xab, 0x1b, 0x78, 0x04, 0x00, + 0x06, 0x93, 0x02, 0xab, 0xff, 0x18, 0x39, 0x80, 0xfb, 0x21, 0x05, 0x92, + 0xfe, 0xf7, 0x34, 0xfe, 0x05, 0x1e, 0x65, 0xdb, 0x3a, 0x88, 0x34, 0x4b, + 0x20, 0x00, 0x13, 0x43, 0x3b, 0x80, 0x09, 0xab, 0x00, 0x93, 0x1a, 0x23, + 0x02, 0xaa, 0x9b, 0x18, 0x21, 0x8a, 0x62, 0x69, 0xff, 0xf7, 0x5c, 0xfd, + 0x05, 0x1e, 0x55, 0xdb, 0x02, 0xab, 0x5b, 0x8b, 0x09, 0x9a, 0x1b, 0x03, + 0x52, 0x00, 0x9b, 0x18, 0x02, 0x22, 0x01, 0x97, 0x00, 0x92, 0x04, 0x21, + 0x00, 0x22, 0x20, 0x00, 0xfd, 0xf7, 0xb5, 0xf9, 0x05, 0x1e, 0x45, 0xdb, + 0xa3, 0x6b, 0x0a, 0xae, 0x01, 0x33, 0xa3, 0x63, 0x3b, 0x88, 0x2d, 0x20, + 0x33, 0x80, 0x00, 0x23, 0x73, 0x80, 0xf8, 0x33, 0x33, 0x71, 0x6b, 0x46, + 0x19, 0x7e, 0x02, 0xab, 0x31, 0x73, 0x01, 0x21, 0x49, 0x42, 0x0c, 0x91, + 0x20, 0x22, 0x05, 0x99, 0xc0, 0x18, 0x02, 0xf0, 0x9b, 0xfb, 0x09, 0x98, + 0x07, 0x21, 0x43, 0x1c, 0x02, 0xa8, 0x42, 0x8b, 0x1b, 0x02, 0x12, 0x03, + 0x9b, 0x18, 0x2e, 0x22, 0x01, 0x96, 0x00, 0x92, 0x20, 0x00, 0x00, 0x22, + 0xfd, 0xf7, 0x8d, 0xf9, 0x05, 0x1e, 0x1d, 0xdb, 0x01, 0x21, 0x49, 0x42, + 0x3b, 0x88, 0x02, 0x91, 0x02, 0xa9, 0x4a, 0x8b, 0x09, 0x99, 0x12, 0x01, + 0x8a, 0x18, 0x01, 0x32, 0x92, 0xb2, 0x01, 0x92, 0x00, 0x22, 0x31, 0x00, + 0x00, 0x92, 0x20, 0x00, 0x01, 0x32, 0xff, 0xf7, 0xe9, 0xfe, 0x1d, 0x9b, + 0x00, 0x2b, 0x07, 0xd0, 0x02, 0xab, 0x5b, 0x8b, 0x09, 0x9a, 0x1b, 0x01, + 0xd3, 0x18, 0x1d, 0x9a, 0x01, 0x33, 0x13, 0x80, 0x28, 0x00, 0x17, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x00, 0x80, 0xff, 0xff, 0xf0, 0xb5, 0x89, 0xb0, + 0x05, 0x93, 0x80, 0x23, 0x0e, 0x9c, 0x1b, 0x02, 0x1a, 0x43, 0x06, 0x00, + 0x0f, 0x00, 0x04, 0x92, 0x00, 0x2c, 0x0e, 0xd1, 0x04, 0x21, 0x7a, 0x5e, + 0x41, 0x6a, 0x05, 0x9b, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, + 0x1b, 0x02, 0xea, 0x39, 0xfd, 0xf7, 0xeb, 0xf8, 0x05, 0x1e, 0x4e, 0xdb, + 0x74, 0x6a, 0x23, 0x79, 0xda, 0x07, 0x4d, 0xd4, 0x5a, 0xb2, 0x00, 0x2a, + 0x4c, 0xda, 0x9a, 0x07, 0x4c, 0xd4, 0x5b, 0x07, 0x4c, 0xd4, 0x63, 0x88, + 0x00, 0x2b, 0x4b, 0xd1, 0x0f, 0x9b, 0x00, 0x2b, 0x05, 0xd0, 0x20, 0x00, + 0x20, 0x22, 0x19, 0x00, 0x0d, 0x30, 0x02, 0xf0, 0x35, 0xfb, 0x11, 0x9b, + 0x00, 0x2b, 0x03, 0xd0, 0x23, 0x81, 0x11, 0x9b, 0x1b, 0x0c, 0x63, 0x81, + 0x39, 0x1e, 0x01, 0xd0, 0x04, 0x23, 0xf9, 0x5e, 0x16, 0x23, 0x02, 0xaa, + 0x9b, 0x18, 0x02, 0x93, 0x05, 0x9b, 0x22, 0x00, 0x01, 0x93, 0x00, 0x23, + 0x30, 0x00, 0x00, 0x93, 0x04, 0x9b, 0xff, 0xf7, 0x11, 0xfe, 0x05, 0x1e, + 0x1d, 0xd1, 0x02, 0xab, 0xd9, 0x8a, 0x12, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0x19, 0x80, 0x0e, 0x9a, 0x20, 0x89, 0x53, 0x42, 0x5a, 0x41, 0x63, 0x89, + 0x01, 0x91, 0x1b, 0x04, 0x03, 0x43, 0x02, 0x93, 0x63, 0x88, 0x92, 0x00, + 0x00, 0x93, 0x21, 0x00, 0x04, 0x9b, 0x30, 0x00, 0xff, 0xf7, 0x76, 0xfe, + 0x00, 0x2f, 0x04, 0xd0, 0x16, 0x23, 0x02, 0xaa, 0x9b, 0x18, 0x1b, 0x88, + 0xbb, 0x81, 0x28, 0x00, 0x09, 0xb0, 0xf0, 0xbd, 0x04, 0x4d, 0xfa, 0xe7, + 0x04, 0x4d, 0xf8, 0xe7, 0x04, 0x4d, 0xf6, 0xe7, 0x04, 0x4d, 0xf4, 0xe7, + 0x04, 0x4d, 0xf2, 0xe7, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x93, 0xb0, 0x03, 0x93, 0x0d, 0x00, 0x0b, 0x02, 0x14, 0x00, + 0x04, 0x21, 0x52, 0x5e, 0x2e, 0x21, 0x06, 0xae, 0x00, 0x91, 0x01, 0x96, + 0x18, 0x39, 0x07, 0x00, 0xfd, 0xf7, 0x73, 0xf8, 0x00, 0x28, 0x33, 0xdb, + 0x0f, 0x23, 0x2b, 0x40, 0x2a, 0x09, 0x01, 0x3b, 0x12, 0x03, 0x5b, 0x00, + 0x9b, 0x18, 0x0e, 0x22, 0x02, 0xa9, 0x52, 0x18, 0x01, 0x92, 0x02, 0x22, + 0x14, 0x21, 0x00, 0x92, 0x38, 0x00, 0x00, 0x22, 0xfd, 0xf7, 0x5f, 0xf8, + 0xa5, 0x81, 0x27, 0x60, 0xb3, 0x68, 0x6a, 0x46, 0xa3, 0x60, 0x00, 0x23, + 0x63, 0x61, 0x23, 0x82, 0x02, 0xab, 0xe5, 0x81, 0xdb, 0x89, 0x95, 0x89, + 0xe3, 0x80, 0xa5, 0x83, 0x32, 0x79, 0xd4, 0x07, 0x0f, 0xd4, 0x51, 0xb2, + 0x00, 0x29, 0x0f, 0xda, 0x02, 0x21, 0x0a, 0x42, 0x0e, 0xd1, 0x52, 0x07, + 0x0e, 0xd4, 0x1b, 0xb2, 0x00, 0x2b, 0x0b, 0xda, 0x73, 0x88, 0x00, 0x2b, + 0x02, 0xd0, 0x05, 0x48, 0x00, 0xe0, 0x05, 0x48, 0x13, 0xb0, 0xf0, 0xbd, + 0x04, 0x48, 0xfb, 0xe7, 0x04, 0x48, 0xf9, 0xe7, 0x04, 0x48, 0xf7, 0xe7, + 0xe3, 0xd8, 0xff, 0xff, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x95, 0xb0, + 0x0e, 0x93, 0x07, 0x68, 0x0d, 0x00, 0x0e, 0x99, 0x83, 0x68, 0x06, 0x00, + 0xfb, 0x31, 0x38, 0x00, 0x0f, 0x92, 0x06, 0x93, 0xfe, 0xf7, 0xe0, 0xfc, + 0x04, 0x1e, 0x00, 0xda, 0x0b, 0xe2, 0x06, 0x9b, 0x0a, 0x93, 0xab, 0x42, + 0x00, 0xd9, 0x0a, 0x95, 0x7b, 0x6a, 0xb2, 0x89, 0x06, 0x93, 0x10, 0xab, + 0x1a, 0x80, 0xfb, 0x21, 0x0a, 0x98, 0x02, 0xf0, 0x9d, 0xf9, 0xfb, 0x21, + 0x83, 0xb2, 0x0a, 0x98, 0x09, 0x93, 0x02, 0xf0, 0x1d, 0xfa, 0x4e, 0x4b, + 0x0c, 0x91, 0x0b, 0x93, 0x00, 0x23, 0x07, 0x93, 0x08, 0x93, 0x9c, 0x42, + 0x00, 0xd1, 0x2e, 0xe1, 0x0a, 0x9a, 0x08, 0x9b, 0x94, 0x46, 0x63, 0x44, + 0x09, 0x93, 0xb3, 0x60, 0x73, 0x61, 0x6b, 0x46, 0x9b, 0x8b, 0x10, 0xad, + 0x2a, 0x88, 0x33, 0x82, 0x07, 0x9b, 0xf2, 0x81, 0x00, 0x2b, 0x00, 0xd1, + 0x26, 0xe2, 0x31, 0x00, 0x38, 0x00, 0xff, 0xf7, 0x31, 0xf8, 0x00, 0x28, + 0x31, 0xdb, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfd, 0xf7, 0x3d, 0xf8, 0x00, 0x28, 0x22, 0xdb, 0x00, 0x22, 0x02, 0x92, + 0x2a, 0x88, 0x06, 0x98, 0x01, 0x92, 0xc2, 0x78, 0x81, 0x78, 0x12, 0x02, + 0x0a, 0x43, 0x00, 0x92, 0xf3, 0x88, 0x00, 0x22, 0x79, 0x6a, 0x38, 0x00, + 0xff, 0xf7, 0x9c, 0xfd, 0x1a, 0x21, 0x0a, 0xa8, 0x09, 0x18, 0x04, 0x91, + 0x00, 0x21, 0x09, 0x98, 0xb3, 0x89, 0xf2, 0x88, 0x03, 0x90, 0x02, 0x91, + 0x01, 0x91, 0x00, 0x91, 0x38, 0x00, 0x31, 0x00, 0xff, 0xf7, 0xb4, 0xfe, + 0x00, 0x28, 0x00, 0xdb, 0xa5, 0xe1, 0x04, 0x00, 0xa3, 0xe1, 0x1a, 0x20, + 0x03, 0x91, 0x0a, 0xac, 0x0b, 0x99, 0x00, 0x19, 0x04, 0x90, 0x02, 0x91, + 0x01, 0x91, 0x79, 0x6a, 0xb3, 0x89, 0xf2, 0x88, 0x00, 0x91, 0x31, 0x00, + 0x38, 0x00, 0xff, 0xf7, 0x9f, 0xfe, 0x11, 0xe1, 0x10, 0xad, 0x2a, 0x88, + 0x0b, 0x9b, 0x31, 0x00, 0x38, 0x00, 0xfe, 0xf7, 0xe3, 0xff, 0x04, 0x1e, + 0x00, 0xda, 0x88, 0xe1, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, + 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, + 0x38, 0x00, 0xfc, 0xf7, 0xee, 0xff, 0x04, 0x1e, 0x00, 0xda, 0x78, 0xe1, + 0x00, 0x24, 0x02, 0x94, 0x2a, 0x88, 0xf3, 0x88, 0x01, 0x92, 0x06, 0x9a, + 0x38, 0x00, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, 0x00, 0x92, + 0x79, 0x6a, 0x22, 0x00, 0xff, 0xf7, 0x4c, 0xfd, 0x1a, 0x21, 0x0a, 0xa8, + 0x09, 0x18, 0x04, 0x91, 0x0a, 0x98, 0x08, 0x99, 0xb3, 0x89, 0x09, 0x18, + 0xf2, 0x88, 0x03, 0x91, 0x02, 0x94, 0x01, 0x94, 0x00, 0x94, 0xc2, 0xe7, + 0xff, 0xff, 0x00, 0x00, 0xb3, 0x68, 0x58, 0x1e, 0xc6, 0x4b, 0x98, 0x42, + 0x0f, 0xd9, 0x08, 0x9b, 0x00, 0x2b, 0x0c, 0xd1, 0xfb, 0x21, 0x02, 0xf0, + 0xed, 0xf8, 0x7c, 0x21, 0x69, 0x38, 0x02, 0xf0, 0xe9, 0xf8, 0x07, 0x9b, + 0x01, 0x30, 0x80, 0xb2, 0x83, 0x42, 0x00, 0xd8, 0xfb, 0xe0, 0x80, 0x23, + 0xf1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x6b, 0x46, 0x9b, 0x8b, 0x12, 0xad, + 0x6b, 0x80, 0xf9, 0x23, 0x2b, 0x71, 0x10, 0xab, 0x29, 0x80, 0x03, 0x93, + 0x01, 0x23, 0x02, 0x93, 0x00, 0x23, 0x2a, 0x00, 0x01, 0x93, 0x00, 0x93, + 0x38, 0x00, 0xff, 0xf7, 0xe1, 0xfb, 0x04, 0x1e, 0x00, 0xda, 0x2a, 0xe1, + 0x80, 0x22, 0xff, 0x21, 0x52, 0x00, 0x78, 0x6a, 0x02, 0xf0, 0x7d, 0xf9, + 0x05, 0x22, 0x29, 0x00, 0x78, 0x6a, 0x02, 0xf0, 0x6f, 0xf9, 0x00, 0x22, + 0x02, 0x92, 0x0a, 0xaa, 0x12, 0x8b, 0xf3, 0x88, 0x01, 0x92, 0x07, 0x9a, + 0x38, 0x00, 0x00, 0x92, 0x79, 0x6a, 0x01, 0x22, 0xff, 0xf7, 0xf6, 0xfc, + 0x10, 0xab, 0x1b, 0x88, 0x0a, 0x9a, 0xf3, 0x81, 0x6b, 0x46, 0x9b, 0x8b, + 0x33, 0x82, 0x08, 0x9b, 0x9b, 0x18, 0x73, 0x61, 0xb3, 0x60, 0x07, 0x9b, + 0x0b, 0x93, 0x08, 0x9a, 0x0e, 0x9b, 0x0c, 0x99, 0x9b, 0x1a, 0xfb, 0x22, + 0x52, 0x1a, 0x0d, 0x92, 0x9a, 0x42, 0x00, 0xd9, 0x0d, 0x93, 0x0c, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0xfa, 0xe0, 0x6b, 0x46, 0x9b, 0x8c, 0x12, 0xaa, + 0xf1, 0x88, 0x53, 0x80, 0xfd, 0x23, 0x08, 0x98, 0x13, 0x71, 0x0f, 0x9b, + 0x49, 0x04, 0x49, 0x0c, 0x1b, 0x18, 0x11, 0xa8, 0x11, 0x80, 0x03, 0x90, + 0x01, 0x20, 0x02, 0x90, 0x0c, 0x98, 0x01, 0x90, 0x0d, 0x98, 0x00, 0x90, + 0x38, 0x00, 0xff, 0xf7, 0x93, 0xfb, 0x04, 0x1e, 0x00, 0xd0, 0xed, 0xe6, + 0x11, 0xab, 0x1d, 0x88, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x11, 0xe1, + 0x09, 0x9b, 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9d, 0x52, 0x0a, 0x9a, + 0x08, 0x9b, 0x9b, 0x18, 0x06, 0x9a, 0x13, 0x81, 0x1b, 0x0c, 0x53, 0x81, + 0x0d, 0x9a, 0x09, 0x98, 0x94, 0x46, 0x01, 0x30, 0x83, 0xb2, 0x09, 0x93, + 0x08, 0x9b, 0x63, 0x44, 0x08, 0x93, 0x00, 0x23, 0x0c, 0x93, 0x08, 0x9b, + 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd3, 0xcb, 0xe6, 0x00, 0x23, 0x07, 0x93, + 0x09, 0x9b, 0x68, 0x2b, 0x07, 0xd9, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x02, 0xf0, 0x50, 0xf8, 0x01, 0x30, 0x83, 0xb2, 0x07, 0x93, 0x0b, 0x9b, + 0x07, 0x9a, 0x93, 0x42, 0xa3, 0xd0, 0x08, 0x9b, 0x00, 0x2b, 0x2d, 0xd0, + 0x0b, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x0f, 0xe7, 0x08, 0x9b, 0x0a, 0x9a, + 0x99, 0x18, 0x06, 0x9b, 0x06, 0x9a, 0x19, 0x81, 0x0b, 0x0c, 0x53, 0x81, + 0x0a, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0xf2, 0xe6, 0x10, 0xad, 0x2a, 0x88, + 0x31, 0x00, 0x38, 0x00, 0xfe, 0xf7, 0xe8, 0xfe, 0x04, 0x1e, 0x00, 0xda, + 0x8d, 0xe0, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfc, 0xf7, 0xf3, 0xfe, 0x04, 0x1e, 0x00, 0xda, 0x7d, 0xe0, 0x08, 0x9b, + 0x0a, 0x9a, 0x9b, 0x18, 0xb3, 0x60, 0x73, 0x61, 0x07, 0x9b, 0x00, 0x2b, + 0x00, 0xd0, 0x1b, 0xe7, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x10, 0xab, + 0x1b, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, + 0xea, 0x39, 0x38, 0x00, 0xfc, 0xf7, 0x75, 0xfe, 0x04, 0x1e, 0x64, 0xdb, + 0x01, 0x22, 0x06, 0x9b, 0x1b, 0x79, 0x13, 0x42, 0x00, 0xd0, 0xe9, 0xe0, + 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xe7, 0xe0, 0x9a, 0x07, 0x00, 0xd5, + 0xe6, 0xe0, 0x5b, 0x07, 0x00, 0xd5, 0xe5, 0xe0, 0x06, 0x22, 0xb3, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0xe0, 0xe0, 0x06, 0x9b, 0x5b, 0x88, 0x0b, 0x93, + 0x00, 0x2b, 0x00, 0xd1, 0x43, 0xe7, 0x41, 0x4c, 0x47, 0xe0, 0x33, 0x8a, + 0x07, 0x9a, 0x93, 0x42, 0x34, 0xd1, 0x1e, 0x23, 0xf2, 0x89, 0x0a, 0xa9, + 0x5b, 0x18, 0x1a, 0x80, 0x1e, 0x25, 0x0a, 0xab, 0x04, 0x21, 0x72, 0x5e, + 0x79, 0x6a, 0xed, 0x18, 0x2b, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, + 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x38, 0x00, 0xfc, 0xf7, 0x3d, 0xfe, + 0x04, 0x1e, 0x2c, 0xdb, 0x01, 0x22, 0x06, 0x9b, 0x1b, 0x79, 0x13, 0x42, + 0x00, 0xd0, 0xb1, 0xe0, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xaf, 0xe0, + 0x9a, 0x07, 0x00, 0xd5, 0xae, 0xe0, 0x5b, 0x07, 0x00, 0xd5, 0xad, 0xe0, + 0x06, 0x22, 0xb3, 0x5e, 0x00, 0x2b, 0x00, 0xdb, 0xa8, 0xe0, 0x06, 0x9b, + 0x07, 0x9a, 0x5b, 0x88, 0x93, 0x42, 0xc8, 0xd1, 0x2a, 0x88, 0x10, 0xab, + 0x1a, 0x80, 0xfb, 0xe6, 0x80, 0x23, 0xf1, 0x88, 0x1b, 0x02, 0x19, 0x43, + 0x1e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, 0x00, 0x93, 0x07, 0x9a, 0x08, 0x9b, + 0x38, 0x00, 0xff, 0xf7, 0x45, 0xfa, 0x04, 0x1e, 0xc0, 0xda, 0x20, 0x00, + 0x15, 0xb0, 0xf0, 0xbd, 0x07, 0x9b, 0x00, 0x2b, 0x21, 0xd1, 0x09, 0x9b, + 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9a, 0x5a, 0x11, 0xab, 0x1a, 0x80, + 0x11, 0xad, 0x2a, 0x88, 0x31, 0x1d, 0x09, 0x9b, 0x38, 0x00, 0xfe, 0xf7, + 0x97, 0xff, 0x04, 0x1e, 0xe9, 0xdb, 0x2b, 0x88, 0x0c, 0x9a, 0x1b, 0x02, + 0x05, 0x33, 0x08, 0x98, 0x9b, 0x18, 0x04, 0x21, 0x72, 0x5e, 0x0f, 0x99, + 0x09, 0x18, 0x01, 0x91, 0x0d, 0x99, 0x38, 0x00, 0x00, 0x91, 0x07, 0x21, + 0xfc, 0xf7, 0x4b, 0xfe, 0xf7, 0xe6, 0x09, 0x9b, 0x19, 0x1d, 0x68, 0x2b, + 0x05, 0xd9, 0x09, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0xf4, 0xff, + 0x04, 0x31, 0x06, 0x9b, 0x49, 0x00, 0x5a, 0x5a, 0xd4, 0xe7, 0xc0, 0x46, + 0xf2, 0x66, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, 0x09, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x09, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0xe1, 0xff, 0x04, 0x31, 0x06, 0x9b, 0x49, 0x00, 0x5d, 0x52, 0xeb, 0xe6, + 0x0a, 0x9b, 0x00, 0x2b, 0x31, 0xd1, 0x69, 0x46, 0x06, 0x9b, 0x09, 0x8c, + 0x38, 0x00, 0x19, 0x81, 0x08, 0x9b, 0x06, 0x99, 0x1b, 0x0c, 0x4b, 0x81, + 0x0a, 0x9b, 0x31, 0x00, 0xfe, 0xf7, 0xfe, 0xfd, 0x00, 0x28, 0x00, 0xda, + 0xfd, 0xe5, 0x04, 0x21, 0x72, 0x5e, 0x79, 0x6a, 0x2b, 0x88, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xfa, 0x39, 0x38, 0x00, + 0xfc, 0xf7, 0x09, 0xfe, 0x00, 0x28, 0x00, 0xda, 0xed, 0xe5, 0x06, 0x9a, + 0xf3, 0x88, 0x11, 0x89, 0x52, 0x89, 0x38, 0x00, 0x12, 0x04, 0x0a, 0x43, + 0x02, 0x92, 0x2a, 0x88, 0x01, 0x92, 0x06, 0x9a, 0x52, 0x88, 0x00, 0x92, + 0x79, 0x6a, 0x04, 0x22, 0xff, 0xf7, 0x66, 0xfb, 0x81, 0xe7, 0x1a, 0x21, + 0x0a, 0xa8, 0x09, 0x18, 0x04, 0x91, 0x09, 0x99, 0xb3, 0x89, 0x03, 0x91, + 0x07, 0x99, 0xf2, 0x88, 0x02, 0x91, 0x01, 0x91, 0x79, 0x6a, 0xc6, 0xe5, + 0x03, 0x4c, 0x72, 0xe7, 0x03, 0x4c, 0x70, 0xe7, 0x03, 0x4c, 0x6e, 0xe7, + 0x03, 0x4c, 0x6c, 0xe7, 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, + 0xeb, 0xd8, 0xff, 0xff, 0xea, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x95, 0xb0, + 0x0d, 0x91, 0x19, 0x00, 0x05, 0x68, 0x07, 0x00, 0xfb, 0x31, 0x28, 0x00, + 0x0f, 0x92, 0x0e, 0x93, 0xfe, 0xf7, 0x2a, 0xfa, 0x04, 0x1e, 0x00, 0xda, + 0x6e, 0xe1, 0x6b, 0x6a, 0xfb, 0x21, 0x07, 0x93, 0xbb, 0x89, 0x0d, 0x98, + 0x0b, 0x93, 0x01, 0xf0, 0xed, 0xfe, 0xfb, 0x21, 0x83, 0xb2, 0x0d, 0x98, + 0x08, 0x93, 0x01, 0xf0, 0x6d, 0xff, 0x00, 0x23, 0x0a, 0x91, 0xc1, 0x4e, + 0x06, 0x93, 0x09, 0x93, 0x9c, 0x42, 0x00, 0xd1, 0x2c, 0xe1, 0x0d, 0x9a, + 0x09, 0x9b, 0x94, 0x46, 0x63, 0x44, 0x7b, 0x61, 0x6b, 0x46, 0x9b, 0x8d, + 0xfb, 0x81, 0x6b, 0x46, 0x1b, 0x8b, 0x3b, 0x82, 0x06, 0x9b, 0x00, 0x2b, + 0x00, 0xd1, 0xf4, 0xe1, 0x0b, 0x9a, 0x39, 0x00, 0x28, 0x00, 0xfe, 0xf7, + 0x83, 0xfd, 0x00, 0x28, 0x00, 0xda, 0xff, 0xe1, 0x04, 0x22, 0xb9, 0x5e, + 0x1e, 0x22, 0x00, 0x26, 0x0a, 0xa8, 0x12, 0x18, 0xfb, 0x88, 0x02, 0x92, + 0x0b, 0x9a, 0x00, 0x96, 0x01, 0x92, 0x28, 0x00, 0x07, 0x9a, 0xff, 0xf7, + 0x7f, 0xfa, 0x0a, 0xab, 0xda, 0x8b, 0x6b, 0x46, 0x1b, 0x8b, 0xfa, 0x81, + 0x3b, 0x82, 0xb0, 0x42, 0x00, 0xda, 0xe7, 0xe1, 0xfb, 0x88, 0x01, 0x92, + 0x07, 0x9a, 0x02, 0x96, 0x91, 0x78, 0xd2, 0x78, 0x28, 0x00, 0x12, 0x02, + 0x0a, 0x43, 0x00, 0x92, 0x07, 0x99, 0x32, 0x00, 0xff, 0xf7, 0xe6, 0xfa, + 0x1a, 0xe1, 0x00, 0x23, 0x06, 0x93, 0x33, 0x00, 0x0b, 0x9a, 0x39, 0x00, + 0x28, 0x00, 0xfe, 0xf7, 0x51, 0xfd, 0x04, 0x1e, 0x00, 0xda, 0x0f, 0xe1, + 0x04, 0x22, 0xb9, 0x5e, 0x1e, 0x22, 0x00, 0x26, 0x0a, 0xa8, 0x12, 0x18, + 0xfb, 0x88, 0x02, 0x92, 0x0b, 0x9a, 0x00, 0x96, 0x01, 0x92, 0x28, 0x00, + 0x07, 0x9a, 0xff, 0xf7, 0x4d, 0xfa, 0x04, 0x00, 0xb0, 0x42, 0x00, 0xda, + 0xfc, 0xe0, 0xfb, 0x88, 0x0a, 0xaa, 0x02, 0x96, 0xd2, 0x8b, 0x28, 0x00, + 0x01, 0x92, 0x07, 0x9a, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, + 0x00, 0x92, 0x07, 0x99, 0x32, 0x00, 0xff, 0xf7, 0xb7, 0xfa, 0x06, 0x9b, + 0xb3, 0x42, 0x29, 0xd1, 0x04, 0x21, 0x7a, 0x5e, 0x69, 0x6a, 0x0b, 0x9b, + 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, + 0x28, 0x00, 0xfc, 0xf7, 0xd2, 0xfc, 0x04, 0x1e, 0x00, 0xda, 0xd9, 0xe0, + 0x07, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x00, 0xd5, 0x94, 0xe1, 0x5a, 0xb2, + 0x00, 0x2a, 0x00, 0xdb, 0x92, 0xe1, 0x9a, 0x07, 0x00, 0xd5, 0x91, 0xe1, + 0x5b, 0x07, 0x00, 0xd5, 0x90, 0xe1, 0x06, 0x22, 0xbb, 0x5e, 0x00, 0x2b, + 0x00, 0xdb, 0x8b, 0xe1, 0x07, 0x9b, 0x5b, 0x88, 0x00, 0x2b, 0x39, 0xd0, + 0x73, 0x4c, 0xbf, 0xe0, 0x3b, 0x8a, 0x06, 0x9a, 0x93, 0x42, 0x00, 0xd0, + 0xbd, 0xe0, 0x1e, 0x23, 0xfa, 0x89, 0x0a, 0xa9, 0x5b, 0x18, 0x1a, 0x80, + 0x1e, 0x26, 0x04, 0x21, 0x7a, 0x5e, 0x0a, 0xab, 0x69, 0x6a, 0xf6, 0x18, + 0x33, 0x88, 0x01, 0x91, 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, + 0xea, 0x39, 0x28, 0x00, 0xfc, 0xf7, 0x9b, 0xfc, 0x04, 0x1e, 0x00, 0xda, + 0xa2, 0xe0, 0x07, 0x9b, 0x1b, 0x79, 0xda, 0x07, 0x00, 0xd5, 0x5d, 0xe1, + 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0x5b, 0xe1, 0x9a, 0x07, 0x00, 0xd5, + 0x5a, 0xe1, 0x5b, 0x07, 0x00, 0xd5, 0x59, 0xe1, 0x06, 0x22, 0xbb, 0x5e, + 0x00, 0x2b, 0x00, 0xdb, 0x54, 0xe1, 0x07, 0x9b, 0x06, 0x9a, 0x5b, 0x88, + 0x93, 0x42, 0xc7, 0xd1, 0x33, 0x88, 0x0b, 0x93, 0x6b, 0x46, 0x9b, 0x8d, + 0x0d, 0x9a, 0xfb, 0x81, 0x6b, 0x46, 0x1b, 0x8b, 0x3b, 0x82, 0x09, 0x9b, + 0x9b, 0x18, 0x7b, 0x61, 0x09, 0x9a, 0x0e, 0x9b, 0x0a, 0x99, 0x9b, 0x1a, + 0xfb, 0x22, 0x56, 0x1a, 0x9e, 0x42, 0x00, 0xd9, 0x1e, 0x00, 0x06, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x84, 0xe0, 0x08, 0x9b, 0x07, 0x9a, 0x17, 0x33, + 0x5b, 0x00, 0x9b, 0x5a, 0x0c, 0x93, 0x00, 0x23, 0x06, 0x93, 0x6b, 0x46, + 0x1b, 0x8c, 0x12, 0xaa, 0xf9, 0x88, 0x53, 0x80, 0xff, 0x23, 0x49, 0x04, + 0x13, 0x71, 0x0a, 0x9b, 0x49, 0x0c, 0x11, 0x80, 0x00, 0x2b, 0x00, 0xd0, + 0x82, 0xe0, 0xfb, 0x2e, 0x00, 0xd0, 0x7f, 0xe0, 0x09, 0x98, 0x0f, 0x9b, + 0x00, 0x96, 0x1b, 0x18, 0x11, 0xa8, 0x03, 0x90, 0x01, 0x20, 0x02, 0x90, + 0x0a, 0x98, 0x01, 0x90, 0x28, 0x00, 0xff, 0xf7, 0xe5, 0xf8, 0x0c, 0x99, + 0x28, 0x00, 0xff, 0xf7, 0x63, 0xf9, 0x04, 0x1e, 0x00, 0xd0, 0xea, 0xe6, + 0x11, 0xab, 0x1b, 0x88, 0x0a, 0x93, 0x06, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0xd7, 0xe0, 0x69, 0x46, 0x08, 0x9b, 0x07, 0x9a, 0x17, 0x33, 0x09, 0x8d, + 0x5b, 0x00, 0x99, 0x52, 0x08, 0x98, 0x01, 0x30, 0x83, 0xb2, 0x08, 0x93, + 0x09, 0x9b, 0x9b, 0x19, 0x09, 0x93, 0x00, 0x23, 0x06, 0x9e, 0x0a, 0x93, + 0x09, 0x9b, 0x0e, 0x9a, 0x93, 0x42, 0x00, 0xd3, 0xcd, 0xe6, 0x08, 0x9b, + 0x68, 0x2b, 0x00, 0xd8, 0xf5, 0xe0, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x01, 0xf0, 0xa4, 0xfd, 0x01, 0x30, 0x83, 0xb2, 0x06, 0x93, 0x9e, 0x42, + 0x9a, 0xd0, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd1, 0x54, 0xe7, 0x00, 0x2e, + 0x00, 0xd0, 0xf8, 0xe6, 0x1a, 0x21, 0x0a, 0xa8, 0x09, 0x18, 0xbb, 0x89, + 0xfa, 0x88, 0x03, 0x94, 0x02, 0x94, 0x01, 0x94, 0x04, 0x91, 0x69, 0x6a, + 0x28, 0x00, 0x00, 0x91, 0x39, 0x00, 0xff, 0xf7, 0xf5, 0xfa, 0x04, 0x1e, + 0x00, 0xdb, 0x3f, 0xe7, 0x20, 0x00, 0x15, 0xb0, 0xf0, 0xbd, 0x80, 0x23, + 0xf9, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x06, 0x9a, 0x00, 0x23, 0x28, 0x00, 0xff, 0xf7, 0x1a, 0xf8, + 0x04, 0x1e, 0x00, 0xdb, 0x36, 0xe7, 0xeb, 0xe7, 0x08, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x08, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0xef, 0xfd, 0x04, 0x31, 0x07, 0x9b, 0x49, 0x00, 0x5b, 0x5a, 0x0c, 0x93, + 0x73, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, 0xe3, 0xd8, 0xff, 0xff, + 0x39, 0x1d, 0x08, 0x9b, 0x0c, 0x9a, 0x28, 0x00, 0xfe, 0xf7, 0x64, 0xfd, + 0x04, 0x1e, 0xcf, 0xdb, 0x11, 0xab, 0xf9, 0x88, 0x03, 0x93, 0x00, 0x23, + 0x49, 0x04, 0x49, 0x0c, 0x02, 0x93, 0x01, 0x93, 0x00, 0x93, 0x12, 0xaa, + 0x28, 0x00, 0xff, 0xf7, 0x5d, 0xf8, 0x04, 0x1e, 0x00, 0xd0, 0x66, 0xe6, + 0x0a, 0x9b, 0x00, 0x2b, 0x2e, 0xd1, 0x0a, 0x9b, 0x98, 0x19, 0xfa, 0x28, + 0x3b, 0xd9, 0x0a, 0xab, 0x9b, 0x8b, 0x0a, 0x9a, 0x1b, 0x02, 0x05, 0x33, + 0x09, 0x98, 0x9b, 0x18, 0x04, 0x21, 0x7a, 0x5e, 0x0f, 0x99, 0x00, 0x96, + 0x09, 0x18, 0x01, 0x91, 0x28, 0x00, 0x07, 0x21, 0xfc, 0xf7, 0x01, 0xfc, + 0x04, 0x1e, 0x00, 0xd0, 0x4b, 0xe6, 0x02, 0x21, 0x12, 0xaa, 0x13, 0x79, + 0x28, 0x00, 0x8b, 0x43, 0x13, 0x71, 0x04, 0x21, 0x7a, 0x5e, 0x0a, 0xab, + 0x13, 0xa9, 0x9b, 0x8b, 0x01, 0x91, 0x01, 0x21, 0x1b, 0x02, 0x00, 0x91, + 0x04, 0x33, 0x06, 0x31, 0xfc, 0xf7, 0xeb, 0xfb, 0x04, 0x1e, 0x00, 0xd1, + 0x43, 0xe7, 0x34, 0xe6, 0x0a, 0xaa, 0x92, 0x8b, 0x0c, 0x9b, 0x04, 0x20, + 0x39, 0x5e, 0x0a, 0x98, 0x1b, 0x02, 0x12, 0x02, 0x00, 0x90, 0x05, 0x33, + 0x05, 0x32, 0x28, 0x00, 0xfe, 0xf7, 0xa4, 0xfd, 0x04, 0x1e, 0xc0, 0xd0, + 0x23, 0xe6, 0x0a, 0x9b, 0x0c, 0x9a, 0x05, 0x33, 0x12, 0x02, 0x9b, 0x19, + 0x9b, 0x18, 0x11, 0xaa, 0x12, 0x88, 0x0a, 0x99, 0x12, 0x02, 0x05, 0x32, + 0x52, 0x18, 0x04, 0x24, 0x39, 0x5f, 0xfb, 0x24, 0x20, 0x1a, 0x00, 0x90, + 0x92, 0x19, 0x28, 0x00, 0xfe, 0xf7, 0x8c, 0xfd, 0x04, 0x1e, 0xac, 0xd0, + 0x0b, 0xe6, 0x08, 0x9b, 0x19, 0x1d, 0x68, 0x2b, 0x05, 0xd9, 0x08, 0x98, + 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0x68, 0xfd, 0x04, 0x31, 0x6a, 0x46, + 0x07, 0x9b, 0x12, 0x8d, 0x49, 0x00, 0x5a, 0x52, 0x1e, 0xe7, 0x1a, 0x21, + 0x0a, 0xa8, 0x09, 0x18, 0xbb, 0x89, 0xfa, 0x88, 0x04, 0x91, 0x06, 0x99, + 0x28, 0x00, 0x03, 0x91, 0x02, 0x91, 0x01, 0x91, 0x69, 0x6a, 0x00, 0x91, + 0x39, 0x00, 0xff, 0xf7, 0x37, 0xfa, 0x00, 0x28, 0x00, 0xdb, 0x41, 0xe7, + 0x04, 0x00, 0x3f, 0xe7, 0x0d, 0x4c, 0x3d, 0xe7, 0x0d, 0x4c, 0x3b, 0xe7, + 0x0d, 0x4c, 0x39, 0xe7, 0x0d, 0x4c, 0x37, 0xe7, 0x09, 0x9a, 0x0e, 0x9b, + 0x0a, 0x99, 0x9b, 0x1a, 0xfb, 0x22, 0x56, 0x1a, 0x9e, 0x42, 0x00, 0xd8, + 0xbd, 0xe6, 0x1e, 0x00, 0xbb, 0xe6, 0x00, 0x2e, 0xf2, 0xd0, 0x09, 0x9b, + 0x00, 0x2b, 0x00, 0xd0, 0x0b, 0xe6, 0x06, 0x93, 0x3a, 0xe6, 0xc0, 0x46, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0x70, 0xb5, 0x88, 0xb0, 0x07, 0xab, 0x1a, 0x26, + 0x04, 0x00, 0x05, 0x93, 0x08, 0x00, 0x00, 0x23, 0x15, 0x00, 0x0f, 0x4a, + 0x6e, 0x44, 0x03, 0x93, 0x02, 0x90, 0x01, 0x92, 0x00, 0x93, 0x21, 0x8b, + 0x04, 0x96, 0xe2, 0x69, 0x20, 0x00, 0xfe, 0xf7, 0x55, 0xfd, 0x0a, 0x4b, + 0x98, 0x42, 0x0d, 0xd0, 0x00, 0x28, 0x09, 0xdb, 0x31, 0x88, 0x07, 0x9a, + 0x00, 0x2d, 0x03, 0xd0, 0x0b, 0x01, 0x9b, 0x18, 0x01, 0x33, 0x2b, 0x80, + 0x21, 0x83, 0xe2, 0x61, 0x08, 0xb0, 0x70, 0xbd, 0x02, 0x48, 0xfb, 0xe7, + 0xcd, 0x48, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, 0xee, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x83, 0x68, 0x93, 0xb0, 0x01, 0x3b, 0x04, 0x00, 0x0b, 0x91, + 0x07, 0x92, 0x06, 0x68, 0x03, 0x33, 0x00, 0xd8, 0xd6, 0xe0, 0x00, 0x25, + 0xaa, 0x42, 0x00, 0xd1, 0xde, 0xe0, 0x1a, 0x23, 0xa5, 0x89, 0x08, 0xaa, + 0xa7, 0x68, 0x9b, 0x18, 0x1d, 0x80, 0x00, 0x2f, 0x00, 0xd0, 0xd8, 0xe0, + 0x06, 0x97, 0x73, 0x6a, 0x08, 0x93, 0x07, 0x9b, 0x00, 0x2b, 0x13, 0xd0, + 0x0b, 0x9b, 0x00, 0x2b, 0x10, 0xd1, 0x10, 0xa9, 0xb8, 0x33, 0x0b, 0x70, + 0x01, 0x91, 0x01, 0x21, 0x2d, 0x02, 0x2b, 0x1d, 0x04, 0x20, 0x22, 0x5e, + 0x00, 0x91, 0x30, 0x00, 0x05, 0x31, 0xfc, 0xf7, 0x18, 0xfb, 0x05, 0x1e, + 0x00, 0xda, 0xbb, 0xe0, 0x9f, 0x4b, 0x0c, 0x93, 0x00, 0x23, 0x09, 0x93, + 0x0b, 0x9b, 0x9f, 0x42, 0x00, 0xd8, 0xfd, 0xe0, 0x06, 0x9b, 0x68, 0x2b, + 0x00, 0xd8, 0x14, 0xe2, 0x18, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0x31, 0xfc, 0x01, 0x30, 0x83, 0xb2, 0x0a, 0x93, 0x0a, 0x9a, 0x0c, 0x9b, + 0x93, 0x42, 0x00, 0xd1, 0x0e, 0xe2, 0x0c, 0x9b, 0x1a, 0x00, 0x92, 0x4b, + 0x9a, 0x42, 0x29, 0xd0, 0x08, 0xab, 0x5a, 0x8b, 0x21, 0x00, 0x0c, 0x9b, + 0x30, 0x00, 0xfe, 0xf7, 0xd5, 0xfa, 0x05, 0x1e, 0x00, 0xda, 0x93, 0xe0, + 0x08, 0xab, 0x59, 0x8b, 0x30, 0x00, 0xfe, 0xf7, 0xab, 0xff, 0x05, 0x1e, + 0x00, 0xda, 0x8b, 0xe0, 0x00, 0x21, 0x08, 0xaa, 0x02, 0x91, 0x52, 0x8b, + 0xe3, 0x88, 0x01, 0x92, 0x08, 0x9a, 0x90, 0x78, 0xd2, 0x78, 0x12, 0x02, + 0x02, 0x43, 0x00, 0x92, 0x30, 0x00, 0x02, 0x22, 0xff, 0xf7, 0x46, 0xf8, + 0x0c, 0x9b, 0x00, 0x2b, 0x04, 0xd0, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd1, + 0x82, 0xe0, 0xa7, 0x60, 0x0a, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0x8e, 0xe0, + 0xa2, 0x89, 0x1a, 0x33, 0x08, 0xa9, 0x5b, 0x18, 0x1a, 0x80, 0x04, 0x21, + 0x62, 0x5e, 0x71, 0x6a, 0x08, 0xab, 0x5b, 0x8b, 0x01, 0x91, 0x80, 0x21, + 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x30, 0x00, 0xfc, 0xf7, + 0x52, 0xfa, 0x05, 0x1e, 0x5a, 0xdb, 0x08, 0x9b, 0x1b, 0x79, 0xda, 0x07, + 0x00, 0xd5, 0xb0, 0xe1, 0x5a, 0xb2, 0x00, 0x2a, 0x00, 0xdb, 0xae, 0xe1, + 0x9a, 0x07, 0x00, 0xd5, 0xad, 0xe1, 0x5b, 0x07, 0x00, 0xd5, 0xac, 0xe1, + 0x06, 0x22, 0xa3, 0x5e, 0x00, 0x2b, 0x00, 0xdb, 0xa7, 0xe1, 0x08, 0x9b, + 0x0a, 0x9a, 0x5b, 0x88, 0x09, 0x93, 0x93, 0x42, 0x00, 0xd0, 0xa2, 0xe1, + 0x08, 0xab, 0x5b, 0x8b, 0x67, 0x61, 0xe3, 0x81, 0x6b, 0x46, 0x1b, 0x8d, + 0x23, 0x82, 0x00, 0x2a, 0x00, 0xd0, 0x65, 0xe0, 0x06, 0x9b, 0x08, 0x9a, + 0x17, 0x33, 0x5b, 0x00, 0xd3, 0x18, 0x1a, 0x88, 0x0d, 0x92, 0x01, 0x22, + 0x52, 0x42, 0x1a, 0x80, 0x00, 0x23, 0x0c, 0x93, 0x09, 0x93, 0x0b, 0x9b, + 0x21, 0x1d, 0x00, 0x2b, 0x07, 0xd0, 0x07, 0x9b, 0x00, 0x2b, 0x04, 0xd1, + 0x0b, 0x9b, 0xfb, 0x1a, 0xfa, 0x2b, 0x00, 0xd8, 0xa6, 0xe0, 0x06, 0x9b, + 0x0d, 0x9a, 0x30, 0x00, 0xfe, 0xf7, 0xaa, 0xfb, 0x4e, 0x4b, 0x98, 0x42, + 0x59, 0xd1, 0xfb, 0x21, 0x38, 0x00, 0x01, 0xf0, 0x1d, 0xfc, 0x00, 0x29, + 0x00, 0xd1, 0x89, 0xe0, 0x7f, 0x1a, 0x88, 0xe0, 0x07, 0x9b, 0x00, 0x2b, + 0x00, 0xd0, 0x28, 0xe7, 0xfb, 0x21, 0x30, 0x00, 0x49, 0x00, 0xfd, 0xf7, + 0xbb, 0xfe, 0x05, 0x1e, 0x00, 0xdb, 0x20, 0xe7, 0x28, 0x00, 0x13, 0xb0, + 0xf0, 0xbd, 0x78, 0x1e, 0xfb, 0x21, 0x01, 0xf0, 0x7f, 0xfb, 0x83, 0xb2, + 0x06, 0x93, 0x7b, 0x1c, 0x00, 0xd0, 0x1e, 0xe7, 0x00, 0x27, 0x1c, 0xe7, + 0x0f, 0xa9, 0x04, 0x91, 0x07, 0x99, 0xa3, 0x89, 0x02, 0x91, 0x01, 0x91, + 0x00, 0x91, 0xe2, 0x88, 0x03, 0x97, 0x21, 0x00, 0x30, 0x00, 0xff, 0xf7, + 0xd7, 0xf8, 0x05, 0x1e, 0x00, 0xdb, 0x6c, 0xe7, 0xe0, 0xe7, 0x80, 0x23, + 0xe1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x1a, 0x23, 0x08, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x0a, 0x9a, 0x00, 0x23, 0x30, 0x00, 0xfe, 0xf7, 0xfe, 0xfd, + 0x05, 0x1e, 0x00, 0xdb, 0x65, 0xe7, 0xcf, 0xe7, 0x06, 0x9b, 0x19, 0x1d, + 0x68, 0x2b, 0x05, 0xd9, 0x06, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, + 0xd3, 0xfb, 0x04, 0x31, 0x08, 0x9b, 0x49, 0x00, 0x59, 0x18, 0x0b, 0x88, + 0x0d, 0x93, 0x01, 0x23, 0x5b, 0x42, 0x0b, 0x80, 0x0a, 0x9b, 0x0c, 0x93, + 0x91, 0xe7, 0x00, 0x28, 0x2c, 0xd0, 0x20, 0x4b, 0x98, 0x42, 0xa0, 0xd0, + 0x08, 0xab, 0x5d, 0x8b, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd0, 0xcf, 0xe0, + 0x00, 0x2f, 0x00, 0xd0, 0xc4, 0xe0, 0x07, 0x9b, 0x00, 0x2b, 0x00, 0xd1, + 0xa7, 0xe0, 0x2a, 0x00, 0x3b, 0x00, 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, + 0xe1, 0xf9, 0x05, 0x1e, 0xa0, 0xdb, 0x08, 0xab, 0x59, 0x8b, 0x30, 0x00, + 0xfe, 0xf7, 0xb8, 0xfe, 0x05, 0x1e, 0x00, 0xda, 0x98, 0xe7, 0x02, 0x97, + 0x08, 0xaa, 0x52, 0x8b, 0xe3, 0x88, 0x01, 0x92, 0x00, 0x97, 0x02, 0x22, + 0x39, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0x58, 0xff, 0xa7, 0x60, 0x8b, 0xe7, + 0x0d, 0x99, 0x30, 0x00, 0xfe, 0xf7, 0xa4, 0xfe, 0x00, 0x28, 0x00, 0xd1, + 0x6f, 0xe7, 0xcd, 0xe7, 0xfb, 0x3f, 0x06, 0x98, 0xa7, 0x60, 0x01, 0x38, + 0x83, 0xb2, 0x67, 0x61, 0x06, 0x93, 0xc3, 0xe6, 0xff, 0xff, 0x00, 0x00, + 0xec, 0xd8, 0xff, 0xff, 0xe1, 0xd8, 0xff, 0xff, 0x06, 0x9b, 0x0d, 0x9a, + 0x30, 0x00, 0xfe, 0xf7, 0x03, 0xfb, 0x00, 0x28, 0xb8, 0xd1, 0x6a, 0x46, + 0xe1, 0x88, 0x12, 0x8b, 0x49, 0x04, 0x08, 0xab, 0x49, 0x0c, 0x5a, 0x84, + 0x19, 0x84, 0xff, 0x23, 0x24, 0x30, 0x08, 0xaa, 0x12, 0x18, 0x13, 0x70, + 0x08, 0xaa, 0xe1, 0x3b, 0x9b, 0x18, 0x03, 0x93, 0x07, 0x9b, 0x10, 0xaa, + 0x02, 0x93, 0x01, 0x93, 0x00, 0x93, 0x30, 0x00, 0xfe, 0xf7, 0xf0, 0xfd, + 0x00, 0x28, 0x9d, 0xd1, 0x0d, 0x9b, 0xfb, 0x21, 0x1b, 0x02, 0x05, 0x33, + 0x0a, 0x93, 0x0b, 0x98, 0x08, 0xab, 0xdd, 0x8b, 0x01, 0xf0, 0x56, 0xfb, + 0x2d, 0x02, 0x05, 0x35, 0x00, 0x91, 0x0a, 0x9b, 0x2a, 0x00, 0x07, 0x99, + 0x30, 0x00, 0xfe, 0xf7, 0x65, 0xfb, 0x00, 0x28, 0x00, 0xd0, 0x87, 0xe7, + 0x0d, 0x99, 0x30, 0x00, 0xfe, 0xf7, 0x56, 0xfe, 0x00, 0x28, 0x00, 0xd0, + 0x80, 0xe7, 0x24, 0x21, 0x02, 0x22, 0x08, 0xab, 0x5b, 0x18, 0x1b, 0x78, + 0x30, 0x00, 0x93, 0x43, 0x08, 0xaa, 0x52, 0x18, 0x13, 0x70, 0x04, 0x21, + 0x62, 0x5e, 0x08, 0xab, 0x11, 0xa9, 0xdb, 0x8b, 0x01, 0x91, 0x01, 0x21, + 0x1b, 0x02, 0x00, 0x91, 0x04, 0x33, 0x06, 0x31, 0xfc, 0xf7, 0x79, 0xf9, + 0x00, 0x28, 0x00, 0xd0, 0x66, 0xe7, 0x08, 0xab, 0xdd, 0x8b, 0x09, 0x9b, + 0x00, 0x2b, 0x09, 0xd1, 0x06, 0x98, 0x17, 0x30, 0x08, 0x9b, 0x40, 0x00, + 0x1d, 0x52, 0x0b, 0x9b, 0xa3, 0x60, 0x63, 0x61, 0x1f, 0x00, 0x57, 0xe7, + 0x06, 0x9b, 0x68, 0x2b, 0x02, 0xd8, 0x18, 0x00, 0x04, 0x30, 0xf1, 0xe7, + 0x06, 0x98, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0x0f, 0xfb, 0x08, 0x1d, + 0xea, 0xe7, 0x70, 0x6a, 0xd2, 0x22, 0x2e, 0x30, 0xff, 0x21, 0x01, 0xf0, + 0x3a, 0xfb, 0x0f, 0xab, 0x04, 0x93, 0x01, 0x23, 0xe2, 0x88, 0x5b, 0x42, + 0x03, 0x93, 0x02, 0x97, 0x01, 0x97, 0x73, 0x6a, 0x00, 0x93, 0x2b, 0x00, + 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0xde, 0xff, 0x05, 0x1e, 0x00, 0xdb, + 0x5a, 0xe7, 0xe7, 0xe6, 0x0f, 0xab, 0x04, 0x93, 0x09, 0x9b, 0xe2, 0x88, + 0x03, 0x97, 0x02, 0x93, 0x01, 0x93, 0xec, 0xe7, 0x2a, 0x00, 0x09, 0x9b, + 0x21, 0x00, 0x30, 0x00, 0xfe, 0xf7, 0x18, 0xf9, 0x05, 0x1e, 0x00, 0xda, + 0xd6, 0xe6, 0x00, 0x25, 0x04, 0x22, 0xa1, 0x5e, 0x10, 0xaa, 0x02, 0x92, + 0x08, 0xaa, 0x52, 0x8b, 0xe3, 0x88, 0x01, 0x92, 0x00, 0x95, 0x08, 0x9a, + 0x30, 0x00, 0xfe, 0xf7, 0x15, 0xfe, 0x05, 0x1e, 0x00, 0xda, 0xc5, 0xe6, + 0x00, 0x25, 0x08, 0xaa, 0x02, 0x95, 0x12, 0x8c, 0xe3, 0x88, 0x01, 0x92, + 0x08, 0x9a, 0x30, 0x00, 0x91, 0x78, 0xd2, 0x78, 0x12, 0x02, 0x0a, 0x43, + 0x00, 0x92, 0x08, 0x99, 0x2a, 0x00, 0xfe, 0xf7, 0x7f, 0xfe, 0x08, 0xab, + 0x1b, 0x8c, 0x0f, 0xa9, 0xe3, 0x81, 0x6b, 0x46, 0x9b, 0x8c, 0x67, 0x61, + 0x23, 0x82, 0xe2, 0x88, 0xa3, 0x89, 0x04, 0x91, 0x03, 0x97, 0x02, 0x95, + 0x01, 0x95, 0x00, 0x95, 0xb4, 0xe7, 0x0a, 0x4d, 0xa2, 0xe6, 0x0a, 0x4d, + 0xa0, 0xe6, 0x0a, 0x4d, 0x9e, 0xe6, 0x0a, 0x4d, 0x9c, 0xe6, 0x0a, 0x4d, + 0x9a, 0xe6, 0x00, 0x23, 0x0a, 0x93, 0x0c, 0x9b, 0x00, 0x2b, 0x00, 0xd0, + 0xf1, 0xe5, 0x5d, 0xe6, 0x0a, 0x9b, 0x09, 0x93, 0xc4, 0xe6, 0xc0, 0x46, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, 0xf0, 0xb5, 0x8f, 0xb0, + 0x07, 0x91, 0x08, 0x93, 0x03, 0x68, 0x04, 0x00, 0xfb, 0x21, 0x07, 0x98, + 0x04, 0x93, 0x0b, 0x92, 0x01, 0xf0, 0x00, 0xfa, 0x87, 0xb2, 0x00, 0x20, + 0x04, 0x9b, 0x5b, 0x6a, 0x06, 0x93, 0x07, 0x9b, 0x03, 0x93, 0x6b, 0x4b, + 0x05, 0x93, 0x0b, 0x9a, 0x07, 0x9b, 0x94, 0x46, 0x03, 0x9a, 0x63, 0x44, + 0x0a, 0x93, 0x93, 0x42, 0x3a, 0xd9, 0xe2, 0x6a, 0x00, 0x2a, 0x0c, 0xd0, + 0x13, 0x89, 0xbb, 0x42, 0x09, 0xd8, 0x51, 0x89, 0xb9, 0x42, 0x06, 0xd3, + 0xfb, 0x1a, 0x12, 0x68, 0x5b, 0x00, 0x9d, 0x5a, 0x00, 0x2d, 0x00, 0xd0, + 0x82, 0xe0, 0x68, 0x2f, 0x3d, 0xd9, 0x38, 0x00, 0x7c, 0x21, 0x69, 0x38, + 0x01, 0xf0, 0xd8, 0xf9, 0x05, 0x9b, 0x01, 0x30, 0x85, 0xb2, 0xab, 0x42, + 0x06, 0xd1, 0x38, 0x00, 0x7c, 0x21, 0x69, 0x38, 0x01, 0xf0, 0x54, 0xfa, + 0x04, 0x31, 0x1c, 0xe0, 0x23, 0x8a, 0xab, 0x42, 0x05, 0xd1, 0x0e, 0x23, + 0xe2, 0x89, 0x0a, 0xa9, 0x5b, 0x18, 0x1a, 0x80, 0x2c, 0xe0, 0x80, 0x23, + 0xe1, 0x88, 0x1b, 0x02, 0x19, 0x43, 0x0e, 0x23, 0x0a, 0xaa, 0x9b, 0x18, + 0x00, 0x93, 0x2a, 0x00, 0x00, 0x23, 0x04, 0x98, 0xfe, 0xf7, 0x5a, 0xfc, + 0x00, 0x28, 0x1d, 0xda, 0x0f, 0xb0, 0xf0, 0xbd, 0x39, 0x1d, 0x68, 0x2f, + 0xdb, 0xd8, 0x06, 0x9b, 0x49, 0x00, 0x5d, 0x5a, 0x4e, 0xe0, 0x45, 0x48, + 0xf4, 0xe7, 0x45, 0x48, 0xf2, 0xe7, 0x45, 0x48, 0xf0, 0xe7, 0x45, 0x48, + 0xee, 0xe7, 0x45, 0x48, 0xec, 0xe7, 0x45, 0x48, 0xea, 0xe7, 0x05, 0x9b, + 0x00, 0x2b, 0x38, 0xd0, 0x0e, 0x23, 0x00, 0x25, 0xa2, 0x89, 0x0a, 0xa9, + 0x5b, 0x18, 0x1a, 0x80, 0x0e, 0x26, 0x04, 0x21, 0x62, 0x5e, 0x04, 0x99, + 0x0a, 0xab, 0x49, 0x6a, 0xf6, 0x18, 0x33, 0x88, 0x05, 0x91, 0x01, 0x91, + 0x80, 0x21, 0x49, 0x00, 0x00, 0x91, 0x1b, 0x02, 0xea, 0x39, 0x04, 0x98, + 0xfb, 0xf7, 0xf3, 0xff, 0x00, 0x28, 0xcd, 0xdb, 0x01, 0x22, 0x06, 0x9b, + 0x1b, 0x79, 0x13, 0x42, 0xd1, 0xd1, 0x5a, 0xb2, 0x00, 0x2a, 0xd0, 0xda, + 0x9a, 0x07, 0xd0, 0xd4, 0x5b, 0x07, 0xd0, 0xd4, 0x06, 0x22, 0xa3, 0x5e, + 0x00, 0x2b, 0xcc, 0xda, 0x06, 0x9b, 0x9a, 0x78, 0xdb, 0x78, 0x1b, 0x02, + 0x13, 0x43, 0x05, 0x93, 0xab, 0x42, 0xc6, 0xd1, 0x03, 0x9b, 0x25, 0x82, + 0x63, 0x61, 0x33, 0x88, 0xe3, 0x81, 0x00, 0x2d, 0xb0, 0xd1, 0x3b, 0x00, + 0x06, 0x9a, 0x17, 0x33, 0x5b, 0x00, 0x9d, 0x5a, 0x00, 0x23, 0x05, 0x93, + 0xfb, 0x21, 0x03, 0x98, 0x01, 0xf0, 0xde, 0xf9, 0x0a, 0x9b, 0x03, 0x9a, + 0x09, 0x91, 0x9a, 0x1a, 0x03, 0x99, 0xa3, 0x68, 0x5b, 0x1a, 0x93, 0x42, + 0x00, 0xd9, 0x13, 0x00, 0xfb, 0x26, 0x09, 0x9a, 0xb6, 0x1a, 0x9e, 0x42, + 0x00, 0xd9, 0x1e, 0x00, 0x00, 0x2e, 0xa4, 0xd0, 0x21, 0x1d, 0x3b, 0x00, + 0x2a, 0x00, 0x04, 0x98, 0xfe, 0xf7, 0x4c, 0xf9, 0x00, 0x28, 0x00, 0xda, + 0x88, 0xe7, 0x09, 0x9b, 0x04, 0x21, 0x62, 0x5e, 0x08, 0x99, 0x2d, 0x02, + 0x05, 0x33, 0x01, 0x91, 0xeb, 0x18, 0x00, 0x96, 0x17, 0x21, 0x04, 0x98, + 0xfb, 0xf7, 0x9f, 0xff, 0x00, 0x28, 0x00, 0xda, 0x78, 0xe7, 0x08, 0x9b, + 0x01, 0x37, 0x9b, 0x19, 0x08, 0x93, 0x03, 0x9b, 0xbf, 0xb2, 0x9b, 0x19, + 0x03, 0x93, 0x63, 0x61, 0x2b, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0x00, 0x00, + 0xe4, 0xd8, 0xff, 0xff, 0xec, 0xd8, 0xff, 0xff, 0xeb, 0xd8, 0xff, 0xff, + 0xea, 0xd8, 0xff, 0xff, 0xe3, 0xd8, 0xff, 0xff, 0xed, 0xd8, 0xff, 0xff, + 0xf0, 0xb5, 0x0f, 0x23, 0x8d, 0xb0, 0x06, 0x91, 0x01, 0x21, 0x07, 0x92, + 0xc2, 0x68, 0x05, 0x00, 0x53, 0x43, 0x5b, 0x08, 0x09, 0xaa, 0x5b, 0x18, + 0x11, 0x80, 0x99, 0xb2, 0x1b, 0x04, 0x3c, 0xd4, 0x51, 0x80, 0x00, 0x23, + 0x53, 0x60, 0x07, 0x9b, 0x93, 0x60, 0x09, 0xac, 0x23, 0x88, 0x68, 0x6a, + 0x9c, 0x46, 0x62, 0x46, 0x63, 0x88, 0x9b, 0x1a, 0x80, 0x22, 0x12, 0x01, + 0x93, 0x42, 0x37, 0xdc, 0x80, 0x22, 0x00, 0x21, 0x52, 0x00, 0x01, 0xf0, + 0xa8, 0xf9, 0x00, 0x21, 0x07, 0x9b, 0x05, 0x91, 0x02, 0x93, 0x3d, 0x4b, + 0x04, 0x91, 0x01, 0x93, 0x03, 0x94, 0x0b, 0x00, 0x00, 0x91, 0x0a, 0x00, + 0x28, 0x00, 0xfe, 0xf7, 0xa9, 0xf9, 0x39, 0x4b, 0x98, 0x42, 0x01, 0xd0, + 0x00, 0x28, 0x12, 0xdb, 0x80, 0x26, 0x00, 0x22, 0x01, 0x23, 0x6f, 0x6a, + 0x76, 0x00, 0xbd, 0x5c, 0xff, 0x2d, 0x12, 0xd0, 0x00, 0x21, 0x28, 0x00, + 0x08, 0x41, 0x18, 0x40, 0x0a, 0xd1, 0x23, 0x88, 0xd2, 0x00, 0x59, 0x18, + 0x06, 0x9b, 0x8a, 0x18, 0x1a, 0x80, 0x0d, 0xb0, 0xf0, 0xbd, 0x2d, 0x4b, + 0x53, 0x80, 0xc0, 0xe7, 0x01, 0x31, 0x08, 0x29, 0xed, 0xd1, 0x01, 0x32, + 0xb2, 0x42, 0xe6, 0xd1, 0x29, 0x48, 0xf2, 0xe7, 0x62, 0x68, 0x00, 0x2a, + 0x1d, 0xd1, 0x09, 0xac, 0x22, 0x88, 0x63, 0x88, 0x00, 0x26, 0x9b, 0x1a, + 0x80, 0x22, 0x1b, 0x0a, 0x52, 0x00, 0x00, 0x21, 0x63, 0x60, 0x01, 0xf0, + 0x66, 0xf9, 0x22, 0x4b, 0x05, 0x96, 0x01, 0x93, 0x04, 0x96, 0x33, 0x00, + 0x03, 0x96, 0x02, 0x94, 0x00, 0x96, 0x32, 0x00, 0x31, 0x00, 0x28, 0x00, + 0xfe, 0xf7, 0x68, 0xf9, 0x18, 0x4b, 0x98, 0x42, 0x26, 0xd1, 0xa6, 0x60, + 0x9b, 0xe7, 0x00, 0x27, 0xff, 0x23, 0x39, 0x00, 0x46, 0x5c, 0x9e, 0x42, + 0x02, 0xd2, 0x33, 0x1e, 0x06, 0xd0, 0x0f, 0x00, 0x80, 0x26, 0x01, 0x31, + 0x76, 0x00, 0xb1, 0x42, 0xf4, 0xd1, 0x39, 0x00, 0x9a, 0x42, 0xcb, 0xd0, + 0x92, 0xb2, 0x51, 0x43, 0x61, 0x44, 0x89, 0xb2, 0x00, 0x2b, 0x03, 0xd1, + 0x06, 0x9a, 0x18, 0x00, 0x11, 0x80, 0xb6, 0xe7, 0x80, 0x23, 0x52, 0x18, + 0x92, 0xb2, 0x62, 0x80, 0x21, 0x80, 0x52, 0x1a, 0x1b, 0x01, 0x9a, 0x42, + 0xbd, 0xdc, 0x76, 0xe7, 0x00, 0x28, 0xaa, 0xdb, 0xa6, 0x60, 0x00, 0xd1, + 0x71, 0xe7, 0xa6, 0xe7, 0x31, 0x49, 0x00, 0x00, 0xa8, 0xd8, 0xff, 0xff, + 0xff, 0x7f, 0x00, 0x00, 0xef, 0xd8, 0xff, 0xff, 0x6d, 0x4b, 0x00, 0x00, + 0xf0, 0xb5, 0x85, 0xb0, 0x05, 0x00, 0x03, 0x91, 0x14, 0x00, 0x10, 0x1e, + 0x01, 0xd0, 0xfe, 0xf7, 0x57, 0xf8, 0xeb, 0x6a, 0xae, 0x6a, 0x02, 0x93, + 0x00, 0x2c, 0x07, 0xd0, 0x30, 0x23, 0x02, 0x99, 0x32, 0x1d, 0x4b, 0x43, + 0xf3, 0x18, 0x04, 0x33, 0x93, 0x42, 0x0e, 0xd1, 0x2a, 0x4a, 0x01, 0x23, + 0x01, 0x92, 0x00, 0x22, 0x31, 0x1d, 0x5b, 0x42, 0x00, 0x92, 0x02, 0x9f, + 0x00, 0x9a, 0xba, 0x42, 0x0e, 0xd1, 0x5a, 0x1c, 0x21, 0xd1, 0x25, 0x48, + 0x3b, 0xe0, 0x00, 0x27, 0xd1, 0x5f, 0x00, 0x29, 0x04, 0xd1, 0x91, 0x8c, + 0x01, 0x29, 0x01, 0xd9, 0x01, 0x39, 0x91, 0x84, 0x30, 0x32, 0xe3, 0xe7, + 0x00, 0x22, 0x8f, 0x5e, 0x00, 0x2f, 0x0a, 0xd1, 0x00, 0x2c, 0x02, 0xd0, + 0x0f, 0x6a, 0x87, 0x42, 0x0a, 0xd0, 0x8f, 0x8c, 0x01, 0x9a, 0x97, 0x42, + 0x01, 0xd2, 0x00, 0x9b, 0x01, 0x97, 0x00, 0x9a, 0x30, 0x31, 0x01, 0x32, + 0x00, 0x92, 0xd8, 0xe7, 0x00, 0x9b, 0x30, 0x22, 0x5a, 0x43, 0xb6, 0x18, + 0x00, 0x2c, 0x11, 0xd0, 0x72, 0x6a, 0x82, 0x42, 0x19, 0xd1, 0x31, 0x8d, + 0x00, 0x29, 0x16, 0xd0, 0xb2, 0x89, 0x10, 0x09, 0x28, 0x83, 0x0f, 0x20, + 0x02, 0x40, 0x01, 0x3a, 0xea, 0x61, 0x0c, 0x4a, 0x91, 0x42, 0x08, 0xd8, + 0x04, 0x31, 0x31, 0x85, 0x00, 0x20, 0x01, 0x33, 0xb3, 0x80, 0x03, 0x9b, + 0x1e, 0x60, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x22, 0x52, 0x42, 0x32, 0x85, + 0xf4, 0xe7, 0x04, 0x22, 0x70, 0x62, 0x32, 0x85, 0xf0, 0xe7, 0xc0, 0x46, + 0xff, 0xff, 0x00, 0x00, 0xe9, 0xd8, 0xff, 0xff, 0xfa, 0xff, 0x00, 0x00, + 0x00, 0x29, 0x10, 0xdd, 0x2c, 0x22, 0x83, 0x5e, 0x8b, 0x42, 0x0c, 0xdb, + 0x30, 0x23, 0x4b, 0x43, 0x81, 0x6a, 0x30, 0x3b, 0xc9, 0x18, 0x04, 0x22, + 0x8b, 0x5e, 0x00, 0x2b, 0x05, 0xd0, 0x00, 0x20, 0x88, 0x80, 0xc8, 0x62, + 0x70, 0x47, 0x02, 0x48, 0xfc, 0xe7, 0x02, 0x48, 0xfa, 0xe7, 0xc0, 0x46, + 0xe6, 0xd8, 0xff, 0xff, 0xe8, 0xd8, 0xff, 0xff, 0x10, 0xb5, 0x00, 0x29, + 0x11, 0xdd, 0x2c, 0x24, 0x03, 0x5f, 0x8b, 0x42, 0x0d, 0xdb, 0x30, 0x23, + 0x59, 0x43, 0x83, 0x6a, 0x30, 0x39, 0x59, 0x18, 0x11, 0x60, 0x04, 0x23, + 0xc8, 0x5e, 0x43, 0x42, 0x58, 0x41, 0x03, 0x4b, 0x40, 0x42, 0x18, 0x40, + 0x10, 0xbd, 0x02, 0x48, 0xfc, 0xe7, 0xc0, 0x46, 0xe8, 0xd8, 0xff, 0xff, + 0xe6, 0xd8, 0xff, 0xff, 0x03, 0x7d, 0x00, 0x2b, 0x04, 0xd1, 0x43, 0x75, + 0x83, 0x75, 0x83, 0x61, 0x01, 0x33, 0x03, 0x75, 0x70, 0x47, 0x7f, 0xb5, + 0xc3, 0x68, 0x02, 0xad, 0x04, 0x00, 0x0e, 0x00, 0x02, 0x91, 0x6a, 0x60, + 0x8b, 0x42, 0x03, 0xd1, 0x02, 0x8a, 0xab, 0x88, 0x9a, 0x42, 0x18, 0xd0, + 0x20, 0x00, 0x06, 0x22, 0x29, 0x00, 0x0c, 0x30, 0x01, 0xf0, 0x50, 0xf8, + 0x20, 0x68, 0x00, 0xf0, 0x8e, 0xf9, 0x6b, 0x79, 0x22, 0x7a, 0xe1, 0x79, + 0x00, 0x93, 0x20, 0x68, 0x00, 0x23, 0x00, 0xf0, 0x27, 0xfa, 0x20, 0x68, + 0x29, 0x79, 0x32, 0x00, 0x00, 0xf0, 0x52, 0xf9, 0x20, 0x68, 0x00, 0xf0, + 0x74, 0xf9, 0x7f, 0xbd, 0x70, 0xb5, 0x18, 0x26, 0x04, 0x00, 0xff, 0xf7, + 0xcb, 0xff, 0x33, 0x00, 0x08, 0x21, 0x20, 0x79, 0x0d, 0x4d, 0x43, 0x43, + 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0xc4, 0xfe, 0x33, 0x00, 0x08, 0x21, + 0xa0, 0x79, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0xbc, 0xfe, + 0x08, 0x21, 0x60, 0x79, 0x46, 0x43, 0xad, 0x19, 0x69, 0x56, 0x00, 0xf0, + 0xb5, 0xfe, 0x04, 0x4b, 0x20, 0x00, 0x06, 0xcb, 0xff, 0xf7, 0xb7, 0xff, + 0x70, 0xbd, 0xc0, 0x46, 0x20, 0x82, 0x00, 0x00, 0x34, 0x0c, 0x00, 0x20, + 0x07, 0xb5, 0x43, 0x7d, 0x00, 0x91, 0x01, 0x92, 0x00, 0x2b, 0x07, 0xd0, + 0x9a, 0x07, 0x0a, 0xd5, 0xef, 0xf3, 0x10, 0x83, 0x5a, 0x42, 0x53, 0x41, + 0x83, 0x75, 0x72, 0xb6, 0x00, 0x99, 0x01, 0x9a, 0xff, 0xf7, 0x9f, 0xff, + 0x07, 0xbd, 0xdb, 0x07, 0xf8, 0xd5, 0x83, 0x69, 0x01, 0x4a, 0x9b, 0xb2, + 0x93, 0x60, 0xf3, 0xe7, 0x00, 0x18, 0x00, 0x40, 0x10, 0xb5, 0x00, 0x68, + 0x00, 0xf0, 0x3e, 0xf9, 0x10, 0xbd, 0x00, 0x00, 0x10, 0x4a, 0x11, 0x4b, + 0x11, 0x49, 0x13, 0x60, 0x00, 0x23, 0x53, 0x71, 0x13, 0x71, 0x10, 0x4a, + 0x10, 0x48, 0x11, 0x60, 0x10, 0x49, 0xd3, 0x60, 0x91, 0x80, 0x09, 0x21, + 0x91, 0x71, 0x06, 0x39, 0x53, 0x74, 0x13, 0x74, 0x13, 0x75, 0xd3, 0x71, + 0x11, 0x72, 0x0c, 0x4a, 0x10, 0x60, 0x0c, 0x48, 0xd3, 0x60, 0x90, 0x80, + 0x1b, 0x20, 0x53, 0x74, 0x13, 0x74, 0x13, 0x75, 0x90, 0x71, 0xd3, 0x71, + 0x11, 0x72, 0x70, 0x47, 0x34, 0x0c, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, + 0x7c, 0x0e, 0x00, 0x20, 0xfc, 0x0b, 0x00, 0x20, 0x88, 0x0e, 0x00, 0x20, + 0x0a, 0x08, 0x00, 0x00, 0x18, 0x0c, 0x00, 0x20, 0x1d, 0x1a, 0x00, 0x00, + 0x10, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x05, 0xfb, 0x10, 0xbd, 0xc0, 0x46, + 0x3c, 0x0c, 0x00, 0x20, 0x13, 0xb5, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, + 0x3b, 0xf8, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, 0x37, 0xf8, 0x12, 0x49, + 0x12, 0x48, 0x00, 0xf0, 0x33, 0xf8, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, + 0x2f, 0xf8, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, 0x2b, 0xf8, 0x12, 0x4c, + 0x12, 0x49, 0x20, 0x00, 0x00, 0xf0, 0x26, 0xf8, 0x01, 0x23, 0x01, 0x93, + 0x02, 0x33, 0x00, 0x93, 0x0d, 0x22, 0x0b, 0x33, 0x21, 0x00, 0x0e, 0x48, + 0x00, 0xf0, 0x72, 0xfa, 0x13, 0xbd, 0xc0, 0x46, 0x00, 0x08, 0x00, 0x42, + 0x78, 0x0e, 0x00, 0x20, 0x00, 0x0c, 0x00, 0x42, 0x7c, 0x0e, 0x00, 0x20, + 0x00, 0x10, 0x00, 0x42, 0x80, 0x0e, 0x00, 0x20, 0x00, 0x14, 0x00, 0x42, + 0x84, 0x0e, 0x00, 0x20, 0x00, 0x18, 0x00, 0x42, 0x88, 0x0e, 0x00, 0x20, + 0x8c, 0x0e, 0x00, 0x20, 0x00, 0x1c, 0x00, 0x42, 0x3c, 0x0c, 0x00, 0x20, + 0x01, 0x60, 0x70, 0x47, 0x94, 0x46, 0xf0, 0xb5, 0x9e, 0x1e, 0x72, 0x1e, + 0x96, 0x41, 0x62, 0x46, 0x05, 0x68, 0x92, 0x07, 0x2f, 0x68, 0x36, 0x06, + 0x3a, 0x43, 0x32, 0x43, 0x2a, 0x60, 0x07, 0x25, 0x05, 0xac, 0x24, 0x78, + 0x00, 0x68, 0xa4, 0x01, 0x29, 0x40, 0x21, 0x43, 0x42, 0x68, 0x00, 0x24, + 0x02, 0x2b, 0x00, 0xd0, 0x5c, 0x03, 0x11, 0x43, 0x21, 0x43, 0x41, 0x60, + 0xf0, 0xbd, 0x30, 0xb5, 0xc0, 0x25, 0x03, 0x68, 0xad, 0x03, 0x1c, 0x68, + 0x12, 0x05, 0x2a, 0x40, 0x22, 0x43, 0xc0, 0x24, 0x09, 0x04, 0xa4, 0x02, + 0x21, 0x40, 0x11, 0x43, 0x19, 0x60, 0x03, 0x68, 0x5a, 0x68, 0x14, 0x43, + 0x5c, 0x60, 0x30, 0xbd, 0x01, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, + 0x13, 0x60, 0x03, 0x68, 0x1a, 0x68, 0xd2, 0x07, 0xfc, 0xd4, 0xda, 0x69, + 0xd2, 0x07, 0xf9, 0xd4, 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, 0x11, 0x68, + 0x0b, 0x43, 0x13, 0x60, 0x02, 0x68, 0xd3, 0x69, 0x9b, 0x07, 0xfc, 0xd4, + 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, 0x02, 0xd4, 0x1a, 0x7e, + 0x92, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0x00, 0x22, 0x03, 0x68, 0x5a, 0x83, + 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x40, 0x07, 0xc0, 0x0f, 0x70, 0x47, + 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x09, 0x70, 0x47, 0x80, 0x23, 0x02, 0x68, + 0x5b, 0x42, 0x11, 0x7e, 0x0b, 0x43, 0x13, 0x76, 0x70, 0x47, 0x03, 0x68, + 0x58, 0x8b, 0x80, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, + 0x51, 0x8b, 0x0b, 0x43, 0x53, 0x83, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, + 0xc0, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x8d, 0xc0, 0xb2, + 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, 0xfc, 0xd5, 0x89, 0xb2, + 0x01, 0x20, 0x19, 0x85, 0x70, 0x47, 0x01, 0x22, 0x03, 0x68, 0x9a, 0x75, + 0x70, 0x47, 0x01, 0x22, 0x03, 0x68, 0x1a, 0x75, 0x70, 0x47, 0x00, 0x00, + 0x70, 0xb5, 0x01, 0x26, 0x04, 0x68, 0x4b, 0x08, 0x33, 0x40, 0x31, 0x40, + 0x25, 0x68, 0x09, 0x07, 0x5b, 0x07, 0x0b, 0x43, 0x2b, 0x43, 0x23, 0x60, + 0x04, 0x68, 0x51, 0x00, 0x03, 0x48, 0x00, 0xf0, 0x2d, 0xfe, 0x01, 0x38, + 0xc0, 0xb2, 0x20, 0x73, 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x6c, 0xdc, 0x02, + 0x01, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, 0x03, 0x68, + 0x1a, 0x68, 0xd2, 0x07, 0xfc, 0xd4, 0xda, 0x69, 0xd2, 0x07, 0xf9, 0xd4, + 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, + 0x02, 0x68, 0xd3, 0x69, 0x9b, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, + 0xda, 0x69, 0x92, 0x07, 0xfc, 0xd4, 0x02, 0x21, 0x1a, 0x68, 0x8a, 0x43, + 0x1a, 0x60, 0x70, 0x47, 0x02, 0x68, 0x93, 0x6a, 0x5b, 0x0a, 0x5b, 0x02, + 0x19, 0x43, 0x91, 0x62, 0x03, 0x68, 0x1a, 0x7e, 0x52, 0x07, 0xfc, 0xd5, + 0x98, 0x6a, 0xc0, 0xb2, 0x70, 0x47, 0x00, 0x00, 0x03, 0x68, 0x21, 0x4a, + 0x30, 0xb5, 0x93, 0x42, 0x2f, 0xd0, 0x20, 0x4a, 0x93, 0x42, 0x2f, 0xd0, + 0x1f, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x2f, 0xd0, + 0x1e, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1e, 0x4a, 0x93, 0x42, 0x1f, 0xd1, + 0x0e, 0x23, 0x19, 0x22, 0x01, 0x21, 0x03, 0x25, 0x99, 0x40, 0x1b, 0x48, + 0xc0, 0x24, 0x01, 0x60, 0x99, 0x08, 0x2b, 0x40, 0xab, 0x40, 0xfc, 0x35, + 0x9d, 0x40, 0x89, 0x00, 0x09, 0x18, 0xa4, 0x00, 0x08, 0x59, 0xa8, 0x43, + 0xc0, 0x25, 0x9d, 0x40, 0x2b, 0x00, 0x03, 0x43, 0x0b, 0x51, 0x80, 0x23, + 0xdb, 0x01, 0x1a, 0x43, 0x11, 0x4b, 0x5a, 0x80, 0x5a, 0x78, 0x52, 0xb2, + 0x00, 0x2a, 0xfb, 0xdb, 0x30, 0xbd, 0x09, 0x23, 0x14, 0x22, 0xdd, 0xe7, + 0x0a, 0x23, 0x15, 0x22, 0xda, 0xe7, 0x0b, 0x23, 0x16, 0x22, 0xd7, 0xe7, + 0x0c, 0x23, 0x17, 0x22, 0xd4, 0xe7, 0x0d, 0x23, 0x18, 0x22, 0xd1, 0xe7, + 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, 0x00, 0x10, 0x00, 0x42, + 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, 0x00, 0x1c, 0x00, 0x42, + 0x00, 0xe1, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x40, 0xf8, 0xb5, 0x04, 0x00, + 0x0f, 0x00, 0x16, 0x00, 0x1d, 0x00, 0xff, 0xf7, 0xa5, 0xff, 0x20, 0x00, + 0xff, 0xf7, 0x04, 0xff, 0x1c, 0x21, 0xbb, 0x00, 0x0b, 0x40, 0x71, 0x07, + 0x22, 0x68, 0x09, 0x0c, 0x0b, 0x43, 0x13, 0x60, 0x84, 0x23, 0x22, 0x68, + 0x93, 0x75, 0x01, 0x2f, 0x1a, 0xd1, 0x10, 0x21, 0x01, 0x2e, 0x00, 0xd0, + 0x08, 0x39, 0x0c, 0x4b, 0x69, 0x43, 0x18, 0x68, 0xc0, 0x00, 0x00, 0xf0, + 0x83, 0xfd, 0x07, 0x22, 0x21, 0x68, 0x02, 0x40, 0x8b, 0x89, 0x52, 0x03, + 0xdb, 0x04, 0xdb, 0x0c, 0x13, 0x43, 0x8b, 0x81, 0x22, 0x68, 0x03, 0x04, + 0x90, 0x89, 0xdb, 0x0c, 0x40, 0x0b, 0x40, 0x03, 0x18, 0x43, 0x90, 0x81, + 0xf8, 0xbd, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, 0xf7, 0xb5, 0x06, 0x00, + 0x01, 0x93, 0x08, 0xab, 0x1f, 0x78, 0x0d, 0x00, 0x14, 0x00, 0xff, 0xf7, + 0x3f, 0xff, 0x30, 0x00, 0xff, 0xf7, 0x6a, 0xff, 0xc0, 0x22, 0x24, 0x05, + 0x92, 0x03, 0x14, 0x40, 0xba, 0x07, 0x0c, 0x27, 0x17, 0x43, 0x3c, 0x43, + 0xc0, 0x27, 0x07, 0x22, 0xbf, 0x02, 0x2d, 0x04, 0x33, 0x68, 0x3d, 0x40, + 0x25, 0x43, 0x1d, 0x60, 0x01, 0x9b, 0x31, 0x68, 0x13, 0x40, 0x1a, 0x00, + 0x80, 0x23, 0x9b, 0x02, 0x13, 0x43, 0x4b, 0x60, 0xf7, 0xbd, 0x01, 0x20, + 0x70, 0x47, 0x00, 0x00, 0x10, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, + 0x98, 0x47, 0x10, 0xbd, 0x13, 0x04, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, + 0xd9, 0x69, 0x9a, 0x69, 0x91, 0x42, 0x03, 0xd0, 0xdb, 0x69, 0xc0, 0x18, + 0x00, 0x7d, 0x70, 0x47, 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, 0x10, 0xb5, + 0x04, 0x00, 0x00, 0x69, 0xff, 0xf7, 0x96, 0xfe, 0x22, 0x00, 0x00, 0x23, + 0xfc, 0x32, 0x93, 0x61, 0xd3, 0x61, 0x86, 0x22, 0x92, 0x00, 0xa4, 0x18, + 0x63, 0x60, 0xa3, 0x60, 0x10, 0xbd, 0xf0, 0x20, 0x01, 0x40, 0x30, 0x39, + 0x48, 0x42, 0x48, 0x41, 0x70, 0x47, 0xf0, 0x23, 0x1b, 0x01, 0x19, 0x40, + 0x80, 0x23, 0x06, 0x20, 0x9b, 0x00, 0x99, 0x42, 0x0a, 0xd0, 0x01, 0x33, + 0xff, 0x33, 0x01, 0x30, 0x99, 0x42, 0x05, 0xd0, 0x80, 0x23, 0x02, 0x38, + 0x5b, 0x00, 0x99, 0x42, 0x00, 0xd0, 0x00, 0x20, 0x70, 0x47, 0x0f, 0x20, + 0x01, 0x40, 0x00, 0x20, 0x01, 0x29, 0x03, 0xd0, 0x02, 0x39, 0x48, 0x1e, + 0x81, 0x41, 0x48, 0x1c, 0x70, 0x47, 0x00, 0x00, 0x89, 0x23, 0xf0, 0xb5, + 0x18, 0x26, 0x85, 0xb0, 0x02, 0x91, 0x9b, 0x00, 0x04, 0x00, 0xc0, 0x5c, + 0x33, 0x00, 0x08, 0x21, 0x43, 0x43, 0x32, 0x4d, 0x17, 0x00, 0xeb, 0x18, + 0x59, 0x56, 0x00, 0xf0, 0x31, 0xfc, 0x30, 0x4b, 0x08, 0x21, 0xe0, 0x5c, + 0x33, 0x00, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x28, 0xfc, + 0x2c, 0x4b, 0xe2, 0x5c, 0x03, 0x93, 0x02, 0x2a, 0x09, 0xd1, 0x11, 0x33, + 0xe0, 0x5c, 0xff, 0x28, 0x05, 0xd0, 0x08, 0x21, 0x46, 0x43, 0xae, 0x19, + 0x71, 0x56, 0x00, 0xf0, 0x19, 0xfc, 0x8a, 0x26, 0xb6, 0x00, 0xa0, 0x5d, + 0xff, 0x28, 0x19, 0xd0, 0x01, 0x21, 0x00, 0xf0, 0x99, 0xfb, 0x18, 0x22, + 0xa3, 0x5d, 0x21, 0x49, 0x5a, 0x43, 0xab, 0x56, 0xad, 0x18, 0xdb, 0x01, + 0x58, 0x18, 0x8b, 0x21, 0x89, 0x00, 0x60, 0x50, 0x1d, 0x49, 0x01, 0x22, + 0x5b, 0x18, 0x8c, 0x21, 0x89, 0x00, 0x63, 0x50, 0x69, 0x68, 0x8a, 0x40, + 0x8d, 0x21, 0x89, 0x00, 0x62, 0x50, 0x1a, 0x60, 0x01, 0x22, 0x02, 0x9b, + 0x11, 0x00, 0x20, 0x69, 0xff, 0xf7, 0x0a, 0xff, 0x39, 0x00, 0x20, 0x00, + 0xff, 0xf7, 0x8f, 0xff, 0x39, 0x00, 0x05, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0x9e, 0xff, 0x39, 0x00, 0x06, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x7f, 0xff, + 0x33, 0x00, 0x00, 0x90, 0x29, 0x00, 0x20, 0x69, 0x01, 0x22, 0xff, 0xf7, + 0xd3, 0xfd, 0x0b, 0x4b, 0x20, 0x69, 0xe2, 0x5c, 0x03, 0x9b, 0xe1, 0x5c, + 0xff, 0xf7, 0xe9, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x06, 0xfe, 0x05, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x20, 0x82, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, + 0x27, 0x02, 0x00, 0x00, 0x18, 0x44, 0x00, 0x41, 0x14, 0x44, 0x00, 0x41, + 0x26, 0x02, 0x00, 0x00, 0x80, 0x22, 0x10, 0xb5, 0x04, 0x00, 0x52, 0x00, + 0x00, 0x21, 0x00, 0xf0, 0x32, 0xfd, 0x23, 0x00, 0x00, 0x22, 0xfc, 0x33, + 0x5a, 0x60, 0x20, 0x00, 0x9a, 0x60, 0x10, 0xbd, 0xf7, 0xb5, 0x1d, 0x00, + 0x08, 0xab, 0x1b, 0x78, 0x04, 0x00, 0x00, 0x93, 0x09, 0xab, 0x1b, 0x78, + 0x16, 0x00, 0x01, 0x93, 0x00, 0x23, 0x43, 0x60, 0xfa, 0x23, 0x9b, 0x00, + 0x83, 0x60, 0x11, 0x4b, 0x0f, 0x00, 0x08, 0x33, 0x03, 0x60, 0x14, 0x30, + 0xff, 0xf7, 0xdc, 0xff, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, + 0xd7, 0xff, 0x89, 0x23, 0x6a, 0x46, 0x9b, 0x00, 0x27, 0x61, 0xe6, 0x54, + 0x09, 0x4b, 0x12, 0x78, 0xe5, 0x54, 0x09, 0x4b, 0x20, 0x00, 0xe2, 0x54, + 0x6a, 0x46, 0x08, 0x4b, 0x12, 0x79, 0xe2, 0x54, 0x8a, 0x22, 0x29, 0x3b, + 0xff, 0x3b, 0x92, 0x00, 0xa3, 0x54, 0x10, 0x32, 0xa3, 0x54, 0xfe, 0xbd, + 0x80, 0x85, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, 0x26, 0x02, 0x00, 0x00, + 0x27, 0x02, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, 0x58, 0x68, 0x9b, 0x68, + 0xc0, 0x1a, 0x01, 0xd5, 0x01, 0x30, 0xff, 0x30, 0x70, 0x47, 0x10, 0xb5, + 0x04, 0x00, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0xf0, 0xff, + 0x00, 0x28, 0xf8, 0xd1, 0x20, 0x69, 0xff, 0xf7, 0xa4, 0xfd, 0x10, 0xbd, + 0x10, 0xb5, 0x14, 0x30, 0xff, 0xf7, 0xe6, 0xff, 0x10, 0xbd, 0x03, 0x00, + 0xfc, 0x33, 0x59, 0x68, 0x9a, 0x68, 0x91, 0x42, 0x04, 0xdb, 0x5a, 0x68, + 0x98, 0x68, 0x80, 0x1a, 0xff, 0x30, 0x70, 0x47, 0x98, 0x68, 0x5b, 0x68, + 0xc0, 0x1a, 0x01, 0x38, 0xf9, 0xe7, 0x10, 0xb5, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0xeb, 0xff, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x69, + 0xff, 0xf7, 0x9f, 0xfd, 0x00, 0x28, 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, + 0xaa, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x9c, 0xfd, 0x20, 0x69, 0xff, 0xf7, + 0x84, 0xfd, 0x00, 0x28, 0x20, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x9f, 0xfd, + 0x22, 0x00, 0xfc, 0x32, 0x93, 0x69, 0xd1, 0x69, 0x01, 0x33, 0xdb, 0xb2, + 0x8b, 0x42, 0x03, 0xd0, 0x91, 0x69, 0x61, 0x18, 0x08, 0x75, 0x93, 0x61, + 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, 0x20, 0x00, + 0x14, 0x30, 0xff, 0xf7, 0xc0, 0xff, 0x09, 0x28, 0x06, 0xdc, 0x8b, 0x23, + 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, 0x1a, 0x60, + 0x20, 0x69, 0xff, 0xf7, 0x79, 0xfd, 0x00, 0x28, 0x1a, 0xd0, 0x20, 0x00, + 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0x92, 0xff, 0x00, 0x28, 0x22, 0xd0, + 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x99, 0x68, 0x5a, 0x68, 0x91, 0x42, + 0x18, 0xd0, 0x8e, 0x21, 0x9a, 0x68, 0x49, 0x00, 0xa2, 0x18, 0x51, 0x5c, + 0x9a, 0x68, 0x01, 0x32, 0xd2, 0xb2, 0x9a, 0x60, 0xc9, 0xb2, 0x20, 0x69, + 0xff, 0xf7, 0x65, 0xfd, 0x20, 0x69, 0xff, 0xf7, 0x43, 0xfd, 0x00, 0x28, + 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x42, 0xfd, 0x20, 0x69, 0xff, 0xf7, + 0x32, 0xfd, 0x10, 0xbd, 0x01, 0x21, 0x49, 0x42, 0xec, 0xe7, 0x20, 0x69, + 0xff, 0xf7, 0x5f, 0xfd, 0xec, 0xe7, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x00, + 0x00, 0x69, 0x0d, 0x00, 0xff, 0xf7, 0x42, 0xfd, 0x00, 0x28, 0x3e, 0xd1, + 0xff, 0x26, 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x5a, 0x68, 0x99, 0x68, + 0x01, 0x32, 0x32, 0x40, 0x8a, 0x42, 0x23, 0xd1, 0xef, 0xf3, 0x10, 0x83, + 0xdb, 0x07, 0x10, 0xd4, 0x1e, 0x4b, 0x5b, 0x68, 0xdb, 0x05, 0xdb, 0x0d, + 0xed, 0xd0, 0x10, 0x3b, 0x5b, 0xb2, 0x00, 0x2b, 0x10, 0xda, 0x0f, 0x22, + 0x13, 0x40, 0x08, 0x3b, 0x9b, 0x08, 0x19, 0x4a, 0x9b, 0x00, 0x9b, 0x18, + 0x1b, 0x68, 0x20, 0x69, 0xff, 0xf7, 0x1e, 0xfd, 0x00, 0x28, 0xdc, 0xd0, + 0x20, 0x00, 0xff, 0xf7, 0x6a, 0xff, 0xd8, 0xe7, 0x9b, 0x08, 0xc0, 0x33, + 0x12, 0x4a, 0x9b, 0x00, 0x9b, 0x58, 0xf0, 0xe7, 0x5a, 0x68, 0x01, 0x32, + 0x16, 0x40, 0x9a, 0x68, 0x96, 0x42, 0x05, 0xd0, 0x8e, 0x21, 0x5a, 0x68, + 0x49, 0x00, 0xa2, 0x18, 0x55, 0x54, 0x5e, 0x60, 0x20, 0x69, 0xff, 0xf7, + 0x14, 0xfd, 0x01, 0x20, 0x70, 0xbd, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0x1c, 0xff, 0x00, 0x28, 0xb9, 0xd1, 0x29, 0x00, 0x20, 0x69, + 0xff, 0xf7, 0xff, 0xfc, 0xf1, 0xe7, 0xc0, 0x46, 0x00, 0xed, 0x00, 0xe0, + 0x1c, 0xed, 0x00, 0xe0, 0x00, 0xe1, 0x00, 0xe0, 0x03, 0x00, 0x70, 0xb5, + 0xfc, 0x33, 0xd9, 0x69, 0x9a, 0x69, 0x04, 0x00, 0x91, 0x42, 0x1a, 0xd0, + 0xda, 0x69, 0x82, 0x18, 0x15, 0x7d, 0xda, 0x69, 0x01, 0x32, 0xd2, 0xb2, + 0xda, 0x61, 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, + 0x20, 0x00, 0x14, 0x30, 0xff, 0xf7, 0x11, 0xff, 0x0a, 0x28, 0x06, 0xdd, + 0x8c, 0x23, 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, + 0x1a, 0x60, 0x28, 0x00, 0x70, 0xbd, 0x01, 0x25, 0x6d, 0x42, 0xe8, 0xe7, + 0xfe, 0xe7, 0x00, 0x00, 0x03, 0x4b, 0x10, 0xb5, 0x1b, 0x68, 0x00, 0x2b, + 0x00, 0xd0, 0x98, 0x47, 0x10, 0xbd, 0xc0, 0x46, 0x90, 0x0e, 0x00, 0x20, + 0x70, 0xb5, 0x0f, 0x49, 0x0f, 0x4c, 0xa1, 0x42, 0x04, 0xd1, 0x00, 0xf0, + 0x81, 0xf8, 0xfa, 0xf7, 0x27, 0xfe, 0xfe, 0xe7, 0x0c, 0x4d, 0x00, 0x23, + 0x8d, 0x42, 0xf6, 0xd0, 0xca, 0x18, 0xe8, 0x18, 0xa2, 0x42, 0x05, 0xd3, + 0x09, 0x4b, 0x82, 0x42, 0xef, 0xd0, 0x09, 0x49, 0x00, 0x22, 0x04, 0xe0, + 0x00, 0x68, 0x04, 0x33, 0x10, 0x60, 0xf1, 0xe7, 0x04, 0xc3, 0x8b, 0x42, + 0xfc, 0xd3, 0xe4, 0xe7, 0x00, 0x00, 0x00, 0x20, 0x30, 0x00, 0x00, 0x20, + 0xb8, 0x85, 0x00, 0x00, 0x30, 0x00, 0x00, 0x20, 0x98, 0x0e, 0x00, 0x20, + 0x10, 0xb5, 0x00, 0xf0, 0x58, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x00, 0xf0, + 0x49, 0xf8, 0x10, 0xbd, 0xf7, 0xb5, 0x13, 0x48, 0x01, 0x22, 0x84, 0x46, + 0x12, 0x49, 0x13, 0x4c, 0x8e, 0x68, 0x63, 0x68, 0x05, 0x68, 0x9b, 0x0e, + 0x13, 0x40, 0x01, 0x92, 0x88, 0x68, 0x62, 0x68, 0x01, 0x9f, 0x92, 0x0e, + 0x3a, 0x40, 0x67, 0x46, 0x3f, 0x68, 0x93, 0x42, 0x0e, 0xd1, 0xbd, 0x42, + 0x0c, 0xd1, 0x86, 0x42, 0x0a, 0xd3, 0x5b, 0x19, 0xfa, 0x25, 0x48, 0x68, + 0xad, 0x00, 0x86, 0x1b, 0x07, 0x48, 0x6b, 0x43, 0x70, 0x43, 0x00, 0x0d, + 0xc0, 0x18, 0xfe, 0xbd, 0x3d, 0x00, 0x13, 0x00, 0x06, 0x00, 0xe3, 0xe7, + 0x94, 0x0e, 0x00, 0x20, 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, + 0x55, 0x55, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x1e, 0x10, 0xd0, 0xff, 0xf7, + 0xcb, 0xff, 0x05, 0x00, 0x00, 0xf0, 0x1a, 0xf8, 0xff, 0xf7, 0xc6, 0xff, + 0x05, 0x4b, 0x40, 0x1b, 0x98, 0x42, 0xf7, 0xd9, 0xfa, 0x23, 0x01, 0x3c, + 0x9b, 0x00, 0xed, 0x18, 0x00, 0x2c, 0xf3, 0xd1, 0x70, 0xbd, 0xc0, 0x46, + 0xe7, 0x03, 0x00, 0x00, 0x10, 0xb5, 0x03, 0x4a, 0x13, 0x68, 0x01, 0x33, + 0x13, 0x60, 0x00, 0xf0, 0x4d, 0xfa, 0x10, 0xbd, 0x94, 0x0e, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, 0x1e, 0x22, 0x70, 0xb5, + 0x46, 0x48, 0x47, 0x49, 0x43, 0x68, 0x93, 0x43, 0x1c, 0x3a, 0x13, 0x43, + 0x43, 0x60, 0x08, 0x23, 0x8c, 0x69, 0x23, 0x43, 0x8b, 0x61, 0x43, 0x4c, + 0x43, 0x4b, 0x9c, 0x82, 0x9c, 0x8a, 0x14, 0x43, 0x9c, 0x82, 0xdc, 0x68, + 0x14, 0x42, 0xfc, 0xd0, 0x01, 0x24, 0x40, 0x4a, 0x14, 0x70, 0x15, 0x78, + 0x25, 0x42, 0x03, 0xd0, 0x55, 0x78, 0x6d, 0xb2, 0x00, 0x2d, 0xf8, 0xdb, + 0x01, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, + 0x39, 0x4c, 0x54, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, + 0x82, 0x24, 0xe4, 0x01, 0x54, 0x80, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x02, 0x24, 0x9c, 0x84, 0x0e, 0x34, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x31, 0x4c, 0xdc, 0x62, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x9d, 0x8c, 0x2e, 0x4c, 0x2c, 0x43, 0x9c, 0x84, 0x10, 0x24, + 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x02, 0x24, 0x9d, 0x8c, 0x80, 0x26, + 0x2c, 0x43, 0x9c, 0x84, 0x40, 0x24, 0xdd, 0x68, 0x35, 0x42, 0xfc, 0xd0, + 0xdd, 0x68, 0x25, 0x42, 0xf9, 0xd0, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x00, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x21, 0x4c, 0x54, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x1c, 0x6a, 0x1e, 0x4d, 0x2c, 0x40, 0x80, 0x25, 0x1c, 0x62, + 0x1c, 0x6a, 0xac, 0x43, 0x1c, 0x62, 0x03, 0x23, 0x93, 0x60, 0x1b, 0x4b, + 0x53, 0x60, 0x53, 0x78, 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x00, 0x23, + 0xff, 0x24, 0x0b, 0x72, 0x17, 0x4a, 0x4b, 0x72, 0x8b, 0x72, 0xcb, 0x72, + 0x16, 0x4b, 0x1a, 0x60, 0x16, 0x4b, 0x17, 0x4a, 0x1b, 0x68, 0x11, 0x68, + 0x9a, 0x06, 0x5b, 0x01, 0xc9, 0x0e, 0x23, 0x40, 0x52, 0x0f, 0x12, 0x02, + 0x0b, 0x43, 0x13, 0x43, 0x12, 0x4a, 0x13, 0x85, 0x80, 0x23, 0x42, 0x68, + 0x13, 0x43, 0x43, 0x60, 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x00, 0x04, 0x00, 0x40, 0x0c, 0x06, 0x00, 0x00, 0x00, 0x08, 0x00, 0x40, + 0x00, 0x0c, 0x00, 0x40, 0x01, 0x05, 0x01, 0x00, 0xb9, 0x05, 0xff, 0x7d, + 0x04, 0x0a, 0x00, 0x00, 0x00, 0x07, 0x03, 0x00, 0xff, 0xfc, 0xff, 0xff, + 0x03, 0x06, 0x01, 0x00, 0x00, 0x6c, 0xdc, 0x02, 0x00, 0x00, 0x00, 0x20, + 0x24, 0x60, 0x80, 0x00, 0x20, 0x60, 0x80, 0x00, 0x00, 0x40, 0x00, 0x42, + 0xfa, 0x21, 0x31, 0x4b, 0x10, 0xb5, 0x18, 0x68, 0x89, 0x00, 0x00, 0xf0, + 0xd5, 0xf9, 0x2f, 0x4b, 0x01, 0x38, 0x98, 0x42, 0x56, 0xd8, 0x2e, 0x49, + 0x2e, 0x4a, 0x48, 0x60, 0xc0, 0x20, 0x13, 0x6a, 0x00, 0x06, 0x1b, 0x02, + 0x1b, 0x0a, 0x03, 0x43, 0x13, 0x62, 0x00, 0x24, 0x07, 0x23, 0x8c, 0x60, + 0x0b, 0x60, 0x80, 0x21, 0x13, 0x6a, 0x09, 0x06, 0x1b, 0x02, 0x1b, 0x0a, + 0x0b, 0x43, 0x13, 0x62, 0xfc, 0x22, 0x25, 0x4b, 0x19, 0x6a, 0x0a, 0x43, + 0x1a, 0x62, 0xfc, 0x22, 0x19, 0x6a, 0x92, 0x01, 0x0a, 0x43, 0x1a, 0x62, + 0xa0, 0x22, 0x19, 0x6a, 0xd2, 0x02, 0x0a, 0x43, 0x1a, 0x62, 0x20, 0x00, + 0x00, 0x21, 0x01, 0x34, 0x00, 0xf0, 0x76, 0xf8, 0x0f, 0x2c, 0xf8, 0xd1, + 0x1b, 0x4b, 0x1c, 0x00, 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, + 0x19, 0x4a, 0x5a, 0x80, 0x19, 0x4b, 0x1a, 0x00, 0x59, 0x7e, 0xc9, 0x09, + 0x01, 0x29, 0xfb, 0xd0, 0xe4, 0x21, 0xc9, 0x00, 0x99, 0x80, 0x3f, 0x21, + 0xd9, 0x70, 0x53, 0x7e, 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0xc0, 0x23, + 0x00, 0x20, 0x5b, 0x01, 0x13, 0x61, 0x90, 0x70, 0x00, 0xf0, 0x24, 0xf8, + 0x63, 0x78, 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x0d, 0x4b, 0x0e, 0x4a, + 0x63, 0x80, 0xd3, 0x79, 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0x41, 0x23, + 0x53, 0x70, 0x10, 0xbd, 0xfe, 0xe7, 0xc0, 0x46, 0x00, 0x00, 0x00, 0x20, + 0xff, 0xff, 0xff, 0x00, 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, + 0x00, 0x04, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, 0x1e, 0x40, 0x00, 0x00, + 0x00, 0x40, 0x00, 0x42, 0x21, 0x40, 0x00, 0x00, 0x00, 0x48, 0x00, 0x42, + 0x16, 0x4a, 0x00, 0xb5, 0x13, 0x00, 0x51, 0x7e, 0xc9, 0x09, 0x01, 0x29, + 0xfb, 0xd0, 0x01, 0x38, 0x04, 0x28, 0x16, 0xd8, 0x19, 0x69, 0x12, 0x4a, + 0x0a, 0x40, 0x0f, 0x21, 0x1a, 0x61, 0x5a, 0x78, 0x8a, 0x43, 0x00, 0xf0, + 0x47, 0xf9, 0x03, 0x08, 0x06, 0x0b, 0x03, 0x00, 0x11, 0x00, 0x01, 0x22, + 0x0a, 0x43, 0x5a, 0x70, 0x00, 0xbd, 0x11, 0x00, 0x03, 0x22, 0xf9, 0xe7, + 0x11, 0x00, 0x02, 0x22, 0xf6, 0xe7, 0xf0, 0x23, 0x11, 0x69, 0x1b, 0x05, + 0x0b, 0x43, 0x0f, 0x21, 0x13, 0x61, 0x53, 0x78, 0x8b, 0x43, 0x19, 0x00, + 0x02, 0x23, 0x0b, 0x43, 0x53, 0x70, 0xeb, 0xe7, 0x00, 0x40, 0x00, 0x42, + 0xff, 0xff, 0xff, 0xf0, 0x18, 0x23, 0x30, 0xb5, 0x1d, 0x00, 0x04, 0x00, + 0x45, 0x43, 0x08, 0x20, 0x20, 0x4a, 0x55, 0x19, 0x28, 0x56, 0x01, 0x30, + 0x14, 0xd0, 0x03, 0x29, 0x12, 0xd8, 0x08, 0x00, 0x63, 0x43, 0xd1, 0x56, + 0xd3, 0x18, 0x00, 0xf0, 0x15, 0xf9, 0x02, 0x28, 0x0e, 0x1b, 0x58, 0x68, + 0xcb, 0x01, 0x02, 0x21, 0x18, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, + 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x30, 0xbd, 0x58, 0x68, + 0xcb, 0x01, 0x06, 0x21, 0x12, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, + 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x9a, 0x61, 0xf1, 0xe7, + 0x58, 0x68, 0xcb, 0x01, 0x06, 0x21, 0x0c, 0x4a, 0x9b, 0x18, 0x1a, 0x18, + 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x5a, 0x61, + 0xe4, 0xe7, 0x58, 0x68, 0xcb, 0x01, 0x02, 0x21, 0x05, 0x4a, 0x9b, 0x18, + 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x9a, 0x60, + 0xd8, 0xe7, 0xc0, 0x46, 0x20, 0x82, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x18, 0x23, 0xf0, 0xb5, 0x08, 0x24, 0x58, 0x43, 0x11, 0x4a, 0x13, 0x18, + 0x1c, 0x57, 0x01, 0x34, 0x1b, 0xd0, 0x01, 0x26, 0x35, 0x00, 0x5f, 0x68, + 0x83, 0x56, 0xbd, 0x40, 0x0d, 0x4a, 0xdb, 0x01, 0x9a, 0x18, 0x90, 0x68, + 0x05, 0x42, 0x0b, 0xd1, 0x0c, 0x00, 0x60, 0x1e, 0x84, 0x41, 0xd2, 0x19, + 0x40, 0x32, 0x10, 0x78, 0x34, 0x40, 0x03, 0x36, 0xa4, 0x00, 0xb0, 0x43, + 0x20, 0x43, 0x10, 0x70, 0x04, 0x4a, 0x9b, 0x18, 0x00, 0x29, 0x01, 0xd1, + 0x5d, 0x61, 0xf0, 0xbd, 0x9d, 0x61, 0xfc, 0xe7, 0x20, 0x82, 0x00, 0x00, + 0x00, 0x44, 0x00, 0x41, 0x18, 0x22, 0x42, 0x43, 0xf8, 0xb5, 0x2c, 0x4e, + 0x03, 0x00, 0xb2, 0x18, 0x12, 0x7a, 0x52, 0xb2, 0x14, 0x00, 0x01, 0x32, + 0x0e, 0xd0, 0x48, 0x1c, 0x00, 0x24, 0x0c, 0x28, 0x0a, 0xd8, 0x00, 0xf0, + 0x9f, 0xf8, 0x07, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x0b, + 0x0b, 0x0b, 0x0b, 0x00, 0x01, 0x24, 0x64, 0x42, 0x20, 0x00, 0xf8, 0xbd, + 0x09, 0x29, 0x05, 0xd1, 0x00, 0x21, 0x18, 0x00, 0xff, 0xf7, 0x66, 0xff, + 0x00, 0x24, 0xf5, 0xe7, 0x0a, 0x29, 0x01, 0xd1, 0x08, 0x39, 0xf6, 0xe7, + 0x00, 0x24, 0x0b, 0x29, 0xee, 0xd1, 0x0a, 0x39, 0x18, 0x00, 0xff, 0xf7, + 0x59, 0xff, 0xe9, 0xe7, 0x18, 0x22, 0x53, 0x43, 0xf2, 0x18, 0x55, 0x68, + 0x01, 0x20, 0x2c, 0x00, 0xf3, 0x56, 0x13, 0x4a, 0xdb, 0x01, 0x6e, 0x08, + 0x9b, 0x18, 0xc9, 0xb2, 0x04, 0x40, 0x9e, 0x19, 0x00, 0x2c, 0x0d, 0xd0, + 0x0f, 0x24, 0x30, 0x36, 0x32, 0x78, 0x09, 0x01, 0x22, 0x40, 0x11, 0x43, + 0xc9, 0xb2, 0x5b, 0x19, 0x31, 0x70, 0x40, 0x33, 0x1a, 0x78, 0x10, 0x43, + 0x18, 0x70, 0xd3, 0xe7, 0x32, 0x00, 0x0f, 0x27, 0x30, 0x32, 0x16, 0x78, + 0x5b, 0x19, 0xbe, 0x43, 0x31, 0x43, 0x11, 0x70, 0x40, 0x33, 0x1a, 0x78, + 0x10, 0x43, 0x18, 0x70, 0xbe, 0xe7, 0xc0, 0x46, 0x20, 0x82, 0x00, 0x00, + 0x00, 0x44, 0x00, 0x41, 0xf7, 0xb5, 0x06, 0x00, 0x0d, 0x00, 0x0c, 0x00, + 0x8b, 0x18, 0x01, 0x93, 0x01, 0x9b, 0x67, 0x1b, 0x9c, 0x42, 0x07, 0xd0, + 0x33, 0x68, 0x21, 0x78, 0x1b, 0x68, 0x30, 0x00, 0x98, 0x47, 0x01, 0x34, + 0x00, 0x28, 0xf3, 0xd1, 0x38, 0x00, 0xfe, 0xbd, 0x16, 0x4a, 0x10, 0xb5, + 0x13, 0x68, 0x59, 0x1c, 0x26, 0xd0, 0x01, 0x3b, 0x13, 0x60, 0x00, 0x2b, + 0x22, 0xd1, 0x72, 0xb6, 0x12, 0x4b, 0x13, 0x4a, 0x04, 0x33, 0x93, 0x42, + 0x13, 0xd9, 0x12, 0x4a, 0x01, 0x21, 0x10, 0x00, 0x14, 0x7d, 0x0c, 0x42, + 0xfc, 0xd0, 0x20, 0x21, 0x14, 0x8b, 0xff, 0x31, 0x9b, 0x08, 0x5b, 0x00, + 0x21, 0x43, 0x11, 0x83, 0xd3, 0x61, 0x0c, 0x4b, 0x13, 0x80, 0x01, 0x23, + 0x02, 0x7d, 0x1a, 0x42, 0xfc, 0xd0, 0xbf, 0xf3, 0x4f, 0x8f, 0x09, 0x4b, + 0x09, 0x4a, 0xda, 0x60, 0xbf, 0xf3, 0x4f, 0x8f, 0xc0, 0x46, 0xfd, 0xe7, + 0x10, 0xbd, 0xc0, 0x46, 0x04, 0x00, 0x00, 0x20, 0x00, 0x20, 0x00, 0x00, + 0x03, 0x02, 0x00, 0x00, 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, + 0x00, 0xed, 0x00, 0xe0, 0x04, 0x00, 0xfa, 0x05, 0x02, 0xb4, 0x71, 0x46, + 0x49, 0x08, 0x49, 0x00, 0x09, 0x5c, 0x49, 0x00, 0x8e, 0x44, 0x02, 0xbc, + 0x70, 0x47, 0xc0, 0x46, 0x00, 0x22, 0x43, 0x08, 0x8b, 0x42, 0x74, 0xd3, + 0x03, 0x09, 0x8b, 0x42, 0x5f, 0xd3, 0x03, 0x0a, 0x8b, 0x42, 0x44, 0xd3, + 0x03, 0x0b, 0x8b, 0x42, 0x28, 0xd3, 0x03, 0x0c, 0x8b, 0x42, 0x0d, 0xd3, + 0xff, 0x22, 0x09, 0x02, 0x12, 0xba, 0x03, 0x0c, 0x8b, 0x42, 0x02, 0xd3, + 0x12, 0x12, 0x09, 0x02, 0x65, 0xd0, 0x03, 0x0b, 0x8b, 0x42, 0x19, 0xd3, + 0x00, 0xe0, 0x09, 0x0a, 0xc3, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x03, + 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x03, + 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x03, + 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x03, + 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x02, + 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x02, + 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x02, + 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x02, + 0xc0, 0x1a, 0x52, 0x41, 0xcd, 0xd2, 0xc3, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0xcb, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0x8b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0x4b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0x0b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x08, 0x8b, 0x42, 0x01, 0xd3, + 0xcb, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x08, 0x8b, 0x42, 0x01, 0xd3, + 0x8b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x08, 0x8b, 0x42, 0x01, 0xd3, + 0x4b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x41, 0x1a, 0x00, 0xd2, 0x01, 0x46, + 0x52, 0x41, 0x10, 0x46, 0x70, 0x47, 0xff, 0xe7, 0x01, 0xb5, 0x00, 0x20, + 0x00, 0xf0, 0x06, 0xf8, 0x02, 0xbd, 0xc0, 0x46, 0x00, 0x29, 0xf7, 0xd0, + 0x76, 0xe7, 0x70, 0x47, 0x70, 0x47, 0xc0, 0x46, 0x70, 0xb5, 0x00, 0x26, + 0x0c, 0x4d, 0x0d, 0x4c, 0x64, 0x1b, 0xa4, 0x10, 0xa6, 0x42, 0x09, 0xd1, + 0x00, 0x26, 0x00, 0xf0, 0x4f, 0xf8, 0x0a, 0x4d, 0x0a, 0x4c, 0x64, 0x1b, + 0xa4, 0x10, 0xa6, 0x42, 0x05, 0xd1, 0x70, 0xbd, 0xb3, 0x00, 0xeb, 0x58, + 0x98, 0x47, 0x01, 0x36, 0xee, 0xe7, 0xb3, 0x00, 0xeb, 0x58, 0x98, 0x47, + 0x01, 0x36, 0xf2, 0xe7, 0x08, 0x00, 0x00, 0x20, 0x08, 0x00, 0x00, 0x20, + 0x08, 0x00, 0x00, 0x20, 0x24, 0x00, 0x00, 0x20, 0x00, 0x23, 0x10, 0xb5, + 0x9a, 0x42, 0x00, 0xd1, 0x10, 0xbd, 0xcc, 0x5c, 0xc4, 0x54, 0x01, 0x33, + 0xf8, 0xe7, 0x03, 0x00, 0x12, 0x18, 0x93, 0x42, 0x00, 0xd1, 0x70, 0x47, + 0x19, 0x70, 0x01, 0x33, 0xf9, 0xe7, 0x02, 0x78, 0x0b, 0x78, 0x00, 0x2a, + 0x03, 0xd0, 0x01, 0x30, 0x01, 0x31, 0x9a, 0x42, 0xf7, 0xd0, 0xd0, 0x1a, + 0x70, 0x47, 0x00, 0x23, 0xc2, 0x5c, 0x01, 0x33, 0x00, 0x2a, 0xfb, 0xd1, + 0x58, 0x1e, 0x70, 0x47, 0x30, 0xb5, 0x05, 0x00, 0x00, 0x2a, 0x00, 0xd1, + 0x30, 0xbd, 0x0c, 0x78, 0x01, 0x3a, 0x6b, 0x1c, 0x2c, 0x70, 0x01, 0x31, + 0x00, 0x2c, 0x05, 0xd1, 0x9a, 0x18, 0x9a, 0x42, 0xf4, 0xd0, 0x1c, 0x70, + 0x01, 0x33, 0xfa, 0xe7, 0x1d, 0x00, 0xed, 0xe7, 0xf8, 0xb5, 0xc0, 0x46, + 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, 0xf8, 0xb5, 0xc0, 0x46, + 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, 0x55, 0x50, 0x44, 0x41, + 0x54, 0x45, 0x2e, 0x42, 0x49, 0x4e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x10, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, + 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, + 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x04, + 0x00, 0x04, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x01, + 0x00, 0x01, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x13, 0x00, 0x01, 0x01, + 0x01, 0x01, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x05, + 0x00, 0x05, 0x0a, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x05, + 0x01, 0x05, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x02, 0x00, + 0x02, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, + 0x03, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x02, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x03, + 0x01, 0x03, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x10, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x11, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0a, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0b, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x05, 0x00, 0x01, 0x00, + 0x01, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x06, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x07, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x03, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x85, 0x73, 0x00, 0x00, 0x11, 0x7a, 0x00, 0x00, 0xab, 0x72, 0x00, 0x00, + 0x67, 0x72, 0x00, 0x00, 0x81, 0x72, 0x00, 0x00, 0x39, 0x74, 0x00, 0x00, + 0x49, 0x70, 0x00, 0x00, 0x39, 0x70, 0x00, 0x00, 0xcd, 0x70, 0x00, 0x00, + 0x63, 0x70, 0x00, 0x00, 0x33, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x40, 0x42, 0x0f, 0x00, 0xff, 0xff, 0xff, 0xff, 0xdd, 0x20, 0x00, 0x00, + 0x25, 0x22, 0x00, 0x00, 0x39, 0x22, 0x00, 0x00, 0xa5, 0x23, 0x00, 0x00, + 0x3d, 0x26, 0x00, 0x00, 0x41, 0x6c, 0x00, 0x00, 0xb5, 0x6c, 0x00, 0x00, + 0xb5, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 diff --git a/libraries/SNU/examples/Usage/Usage.ino b/libraries/SNU/examples/Usage/Usage.ino new file mode 100644 index 0000000..5f020ea --- /dev/null +++ b/libraries/SNU/examples/Usage/Usage.ino @@ -0,0 +1,106 @@ +/* + Usage + This example demonstrates how to use the SAMD SNU library to update a + sketch on an Arduino MKRWiFi1010 board using the board and nothing else. + It prints out the date and time the sketch was compiled at + to both Serial and Serial1. + + Arduino MKRWiFi1010 board + + Steps to update sketch via NINA WiFi/BT module: + + 1) Upload this sketch or another sketch that includes the SNU library + via #include + + 2) Update the sketch as desired. For this example the sketch prints out + the compiled date and time so no updates are needed. + + 3) In the IDE select: Sketch -> Export compiled Binary + + 4) Use WiFiStorage.download(url, "UPDATE.BIN") function to download the + new binary from a remote webserver. + + 5) Reboot the board; the update will be applied seamlessly + + created 14 December 2018 + by Martino Facchin +*/ + +/* + Include the SNU library + + This will add some code to the sketch before setup() is called + to check if the WiFi module is present and UPDATE.bin exists. + + If UPDATE.bin is present, the file is used to update the sketch + running on the board. After this UPDATE.bin is deleted from NINA memory. +*/ +#include +#include + +#include "arduino_secrets.h" +///////please enter your sensitive data in the Secret tab/arduino_secrets.h +/////// Wifi Settings /////// +char ssid[] = SECRET_SSID; // your network SSID (name) +char pass[] = SECRET_PASS; // your network password +char url[] = SECRET_OTA_URL; + +int status = WL_IDLE_STATUS; + +String message; + +void setup() { + Serial.begin(9600); + Serial1.begin(9600); + + // check for the presence of the shield: + if (WiFi.status() == WL_NO_SHIELD) { + Serial.println("WiFi shield not present"); + // don't continue: + while (true); + } + + // attempt to connect to Wifi network: + while ( status != WL_CONNECTED) { + Serial.print("Attempting to connect to SSID: "); + Serial.println(ssid); + // Connect to WPA/WPA2 network. Change this line if using open or WEP network: + status = WiFi.begin(ssid, pass); + } + + // wait a bit + delay(1000); + + message += "Sketch compile date and time: "; + message += __DATE__; + message += " "; + message += __TIME__; + + // print out the sketch compile date and time on the serial port + Serial.println(message); + Serial1.println(message); + + Serial.println("Type \"download\" in the Serial Monitor to start downloading the update"); +} + +void loop() { + String command = Serial.readStringUntil('\n'); + + if (command.indexOf("download") >= 0) { + + Serial.println("Downloading update file"); + WiFiStorage.download(url, "UPDATE.BIN"); + + WiFiStorageFile update = WiFiStorage.open("/fs/UPDATE.BIN"); + if (update.available()) { + Serial.println("Download complete, please restart or type \"restart\" to apply the update"); + Serial.println("Filesize: " + String(update.available())); + } else { + Serial.println("Download failed, please retry :("); + } + } + + if (command.indexOf("restart") >= 0) { + NVIC_SystemReset(); + } +} diff --git a/libraries/SNU/examples/Usage/arduino_secrets.h b/libraries/SNU/examples/Usage/arduino_secrets.h new file mode 100644 index 0000000..6b57ebd --- /dev/null +++ b/libraries/SNU/examples/Usage/arduino_secrets.h @@ -0,0 +1,3 @@ +#define SECRET_SSID "" +#define SECRET_PASS "" +#define SECRET_OTA_URL "http://downloads.arduino.cc/misc/WiFi1010_blinkRBG.bin" diff --git a/libraries/SNU/extras/NiNaBoot/NiNaBoot.ino b/libraries/SNU/extras/NiNaBoot/NiNaBoot.ino new file mode 100644 index 0000000..b966d81 --- /dev/null +++ b/libraries/SNU/extras/NiNaBoot/NiNaBoot.ino @@ -0,0 +1,320 @@ +/* + Copyright (c) 2017 Arduino LLC. 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 +*/ + +/************************************************************************************** + INCLUDE + **************************************************************************************/ + +#include +#include + +#include "lzss.h" + +#ifdef ARDUINO_SAMD_MKRVIDOR4000 +#include +#endif /* ARDUINO_SAMD_MKRVIDOR4000 */ + +#ifdef ARDUINO_SAMD_MKRVIDOR4000 +#define NINA_GPIO0 FPGA_NINA_GPIO0 +#define NINA_RESETN FPGA_SPIWIFI_RESET +#endif /* ARDUINO_SAMD_MKRVIDOR4000 */ + +/************************************************************************************** + DEFINE + **************************************************************************************/ + +#define SDU_START 0x2000 +#define SDU_SIZE 0x4000 + +#define SKETCH_START (uint32_t*)(SDU_START + SDU_SIZE) + +/************************************************************************************** + CONST + **************************************************************************************/ + +const char * UPDATE_FILE_NAME = "/fs/UPDATE.BIN"; +const char * UPDATE_FILE_NAME_LZSS = "/fs/UPDATE.BIN.LZSS"; + +static const uint32_t crc_table[256] = { + 0x00000000, 0x77073096, 0xee0e612c, 0x990951ba, 0x076dc419, 0x706af48f, 0xe963a535, 0x9e6495a3, + 0x0edb8832, 0x79dcb8a4, 0xe0d5e91e, 0x97d2d988, 0x09b64c2b, 0x7eb17cbd, 0xe7b82d07, 0x90bf1d91, + 0x1db71064, 0x6ab020f2, 0xf3b97148, 0x84be41de, 0x1adad47d, 0x6ddde4eb, 0xf4d4b551, 0x83d385c7, + 0x136c9856, 0x646ba8c0, 0xfd62f97a, 0x8a65c9ec, 0x14015c4f, 0x63066cd9, 0xfa0f3d63, 0x8d080df5, + 0x3b6e20c8, 0x4c69105e, 0xd56041e4, 0xa2677172, 0x3c03e4d1, 0x4b04d447, 0xd20d85fd, 0xa50ab56b, + 0x35b5a8fa, 0x42b2986c, 0xdbbbc9d6, 0xacbcf940, 0x32d86ce3, 0x45df5c75, 0xdcd60dcf, 0xabd13d59, + 0x26d930ac, 0x51de003a, 0xc8d75180, 0xbfd06116, 0x21b4f4b5, 0x56b3c423, 0xcfba9599, 0xb8bda50f, + 0x2802b89e, 0x5f058808, 0xc60cd9b2, 0xb10be924, 0x2f6f7c87, 0x58684c11, 0xc1611dab, 0xb6662d3d, + 0x76dc4190, 0x01db7106, 0x98d220bc, 0xefd5102a, 0x71b18589, 0x06b6b51f, 0x9fbfe4a5, 0xe8b8d433, + 0x7807c9a2, 0x0f00f934, 0x9609a88e, 0xe10e9818, 0x7f6a0dbb, 0x086d3d2d, 0x91646c97, 0xe6635c01, + 0x6b6b51f4, 0x1c6c6162, 0x856530d8, 0xf262004e, 0x6c0695ed, 0x1b01a57b, 0x8208f4c1, 0xf50fc457, + 0x65b0d9c6, 0x12b7e950, 0x8bbeb8ea, 0xfcb9887c, 0x62dd1ddf, 0x15da2d49, 0x8cd37cf3, 0xfbd44c65, + 0x4db26158, 0x3ab551ce, 0xa3bc0074, 0xd4bb30e2, 0x4adfa541, 0x3dd895d7, 0xa4d1c46d, 0xd3d6f4fb, + 0x4369e96a, 0x346ed9fc, 0xad678846, 0xda60b8d0, 0x44042d73, 0x33031de5, 0xaa0a4c5f, 0xdd0d7cc9, + 0x5005713c, 0x270241aa, 0xbe0b1010, 0xc90c2086, 0x5768b525, 0x206f85b3, 0xb966d409, 0xce61e49f, + 0x5edef90e, 0x29d9c998, 0xb0d09822, 0xc7d7a8b4, 0x59b33d17, 0x2eb40d81, 0xb7bd5c3b, 0xc0ba6cad, + 0xedb88320, 0x9abfb3b6, 0x03b6e20c, 0x74b1d29a, 0xead54739, 0x9dd277af, 0x04db2615, 0x73dc1683, + 0xe3630b12, 0x94643b84, 0x0d6d6a3e, 0x7a6a5aa8, 0xe40ecf0b, 0x9309ff9d, 0x0a00ae27, 0x7d079eb1, + 0xf00f9344, 0x8708a3d2, 0x1e01f268, 0x6906c2fe, 0xf762575d, 0x806567cb, 0x196c3671, 0x6e6b06e7, + 0xfed41b76, 0x89d32be0, 0x10da7a5a, 0x67dd4acc, 0xf9b9df6f, 0x8ebeeff9, 0x17b7be43, 0x60b08ed5, + 0xd6d6a3e8, 0xa1d1937e, 0x38d8c2c4, 0x4fdff252, 0xd1bb67f1, 0xa6bc5767, 0x3fb506dd, 0x48b2364b, + 0xd80d2bda, 0xaf0a1b4c, 0x36034af6, 0x41047a60, 0xdf60efc3, 0xa867df55, 0x316e8eef, 0x4669be79, + 0xcb61b38c, 0xbc66831a, 0x256fd2a0, 0x5268e236, 0xcc0c7795, 0xbb0b4703, 0x220216b9, 0x5505262f, + 0xc5ba3bbe, 0xb2bd0b28, 0x2bb45a92, 0x5cb36a04, 0xc2d7ffa7, 0xb5d0cf31, 0x2cd99e8b, 0x5bdeae1d, + 0x9b64c2b0, 0xec63f226, 0x756aa39c, 0x026d930a, 0x9c0906a9, 0xeb0e363f, 0x72076785, 0x05005713, + 0x95bf4a82, 0xe2b87a14, 0x7bb12bae, 0x0cb61b38, 0x92d28e9b, 0xe5d5be0d, 0x7cdcefb7, 0x0bdbdf21, + 0x86d3d2d4, 0xf1d4e242, 0x68ddb3f8, 0x1fda836e, 0x81be16cd, 0xf6b9265b, 0x6fb077e1, 0x18b74777, + 0x88085ae6, 0xff0f6a70, 0x66063bca, 0x11010b5c, 0x8f659eff, 0xf862ae69, 0x616bffd3, 0x166ccf45, + 0xa00ae278, 0xd70dd2ee, 0x4e048354, 0x3903b3c2, 0xa7672661, 0xd06016f7, 0x4969474d, 0x3e6e77db, + 0xaed16a4a, 0xd9d65adc, 0x40df0b66, 0x37d83bf0, 0xa9bcae53, 0xdebb9ec5, 0x47b2cf7f, 0x30b5ffe9, + 0xbdbdf21c, 0xcabac28a, 0x53b39330, 0x24b4a3a6, 0xbad03605, 0xcdd70693, 0x54de5729, 0x23d967bf, + 0xb3667a2e, 0xc4614ab8, 0x5d681b02, 0x2a6f2b94, 0xb40bbe37, 0xc30c8ea1, 0x5a05df1b, 0x2d02ef8d +}; + +/************************************************************************************** + FUNCTIONS + **************************************************************************************/ + +uint32_t crc_update(uint32_t crc, const void * data, size_t data_len) +{ + const unsigned char *d = (const unsigned char *)data; + unsigned int tbl_idx; + + while (data_len--) { + tbl_idx = (crc ^ *d) & 0xff; + crc = (crc_table[tbl_idx] ^ (crc >> 8)) & 0xffffffff; + d++; + } + + return crc & 0xffffffff; +} + +/************************************************************************************** + GLOBAL VARIABLES + **************************************************************************************/ + +FlashClass flash; + +// Initialize C library +extern "C" void __libc_init_array(void); + +/************************************************************************************** + MAIN + **************************************************************************************/ + +int main() { + init(); + + __libc_init_array(); + + delay(1); + +#if defined(ARDUINO_SAMD_MKRVIDOR4000) + FPGA.begin(); + /* NINA select SPI mode and enable (by setting RESETN = '1') */ + FPGA.pinMode (NINA_GPIO0, OUTPUT); + FPGA.digitalWrite(NINA_GPIO0, HIGH); + FPGA.pinMode (NINA_RESETN, OUTPUT); + FPGA.digitalWrite(NINA_RESETN, HIGH); +#elif defined(ARDUINO_SAMD_MKRWIFI1010) || defined(ARDUINO_SAMD_NANO_33_IOT) + /* NINA select SPI mode and enable (by setting RESETN = '1') */ + pinMode (NINA_GPIO0, OUTPUT); + digitalWrite(NINA_GPIO0, HIGH); + pinMode (NINA_RESETN, OUTPUT); + digitalWrite(NINA_RESETN, HIGH); +#endif + + String nina_fw_version; + + if (WiFi.status() == WL_NO_SHIELD) { + goto boot; + } + + nina_fw_version = WiFi.firmwareVersion(); + if (nina_fw_version < "1.4.1") { + goto boot; + } + + /* For UPDATE.BIN.LZSS - LZSS compressed binary files. */ + if (WiFiStorage.exists(UPDATE_FILE_NAME_LZSS)) + { + WiFiStorageFile update_file = WiFiStorage.open(UPDATE_FILE_NAME_LZSS); + + union HeaderVersion + { + struct __attribute__((packed)) + { + uint32_t header_version : 6; + uint32_t compression : 1; + uint32_t signature : 1; + uint32_t spare : 4; + uint32_t payload_target : 4; + uint32_t payload_major : 8; + uint32_t payload_minor : 8; + uint32_t payload_patch : 8; + uint32_t payload_build_num : 24; + } field; + uint8_t buf[sizeof(field)]; + static_assert(sizeof(buf) == 8, "Error: sizeof(HEADER.VERSION) != 8"); + }; + + union + { + struct __attribute__((packed)) + { + uint32_t len; + uint32_t crc32; + uint32_t magic_number; + HeaderVersion hdr_version; + } header; + uint8_t buf[sizeof(header)]; + static_assert(sizeof(buf) == 20, "Error: sizeof(HEADER) != 20"); + } ota_header; + uint32_t crc32, bytes_read; + uint8_t crc_buf[128]; + + /* Read the OTA header ... */ + update_file.read(ota_header.buf, sizeof(ota_header.buf)); + + /* ... and check first length ... */ + if (ota_header.header.len != (update_file.size() - sizeof(ota_header.header.len) - sizeof(ota_header.header.crc32))) { + update_file.close(); + update_file.erase(); + goto boot; + } + + /* ... and the CRC second ... rewind to start of CRC verified header ... */ + update_file.seek(sizeof(ota_header.header.len) + sizeof(ota_header.header.crc32)); + /* ... initialize CRC ... */ + crc32 = 0xFFFFFFFF; + /* ... and calculate over file ... */ + for(bytes_read = 0; + bytes_read < (ota_header.header.len - sizeof(crc_buf)); + bytes_read += sizeof(crc_buf)) + { + update_file.read(crc_buf, sizeof(crc_buf)); + crc32 = crc_update(crc32, crc_buf, sizeof(crc_buf)); + } + update_file.read(crc_buf, ota_header.header.len - bytes_read); + crc32 = crc_update(crc32, crc_buf, ota_header.header.len - bytes_read); + /* ... then finalise ... */ + crc32 ^= 0xFFFFFFFF; + /* ... and compare. */ + if (ota_header.header.crc32 != crc32) { + update_file.close(); + update_file.erase(); + goto boot; + } + + /* Thirdly verify via magic number if this application is intented for + * MKR WIFI 1010 or NANO 33 IOT. + */ +#if defined(ARDUINO_SAMD_MKRWIFI1010) + if (ota_header.header.magic_number != 0x23418054) /* 2341:8054 = VID/PID MKR WIFI 1010 */ + { + update_file.close(); + update_file.erase(); + goto boot; + } +#elif defined(ARDUINO_SAMD_NANO_33_IOT) + if (ota_header.header.magic_number != 0x23418057) /* 2341:8057 = VID/PID NANO 33 IOT */ + { + update_file.close(); + update_file.erase(); + goto boot; + } +#else + update_file.close(); + update_file.erase(); + goto boot; +#endif + + /* Rewind to start of LZSS compressed binary. */ + update_file.seek(sizeof(ota_header.buf)); + + /* Erase the complete flash starting from the SSU forward + * because we've got no possibility of knowing how large + * the decompressed binary will finally be. + */ + flash.erase((void*)SKETCH_START, 0x40000 - (uint32_t)SKETCH_START); + /* Initialize the lzss module with the data which + * it requires. + */ + uint32_t const LZSS_FILE_SIZE = update_file.size() - sizeof(ota_header.buf); + lzss_init(&update_file, (uint32_t)SKETCH_START, LZSS_FILE_SIZE); + /* During the process of decoding UPDATE.BIN.LZSS + * is decompressed and stored as UPDATE.BIN. + */ + lzss_decode(); + /* Write the data remaining in the write buffer to + * the file. + */ + lzss_flush(); + /* Delete UPDATE.BIN.LZSS because this update is complete. */ + update_file.close(); + update_file.erase(); + } + /* For UPDATE.BIN - uncompressed binary files. */ + else if (WiFiStorage.exists(UPDATE_FILE_NAME)) { + + WiFiStorageFile updateFile = WiFiStorage.open(UPDATE_FILE_NAME); + uint32_t updateSize = updateFile.size(); + bool updateFlashed = false; + + if (updateSize > SDU_SIZE) { + // skip the SDU section + updateFile.seek(SDU_SIZE); + updateSize -= SDU_SIZE; + + uint32_t flashAddress = (uint32_t)SKETCH_START; + + // erase the pages + flash.erase((void*)flashAddress, updateSize); + + uint8_t buffer[128]; + + // write the pages + for (uint32_t i = 0; i < updateSize; i += sizeof(buffer)) { + updateFile.read(buffer, sizeof(buffer)); + + flash.write((void*)flashAddress, buffer, sizeof(buffer)); + + flashAddress += sizeof(buffer); + } + + updateFlashed = true; + } + + updateFile.close(); + + if (updateFlashed) { + updateFile.erase(); + } + } + +boot: + // jump to the sketch + __set_MSP(*SKETCH_START); + + //Reset vector table address + SCB->VTOR = ((uint32_t)(SKETCH_START) & SCB_VTOR_TBLOFF_Msk); + + // address of Reset_Handler is written by the linker at the beginning of the .text section (see linker script) + uint32_t resetHandlerAddress = (uint32_t) * (SKETCH_START + 1); + // jump to reset handler + asm("bx %0"::"r"(resetHandlerAddress)); +} diff --git a/libraries/SNU/extras/NiNaBoot/build.sh b/libraries/SNU/extras/NiNaBoot/build.sh new file mode 100755 index 0000000..a174547 --- /dev/null +++ b/libraries/SNU/extras/NiNaBoot/build.sh @@ -0,0 +1,26 @@ +#!/bin/sh -x + +ARDUINO=arduino +SKETCH_NAME="NiNaBoot.ino" +SKETCH="$PWD/$SKETCH_NAME" +BUILD_PATH="$PWD/build" +OUTPUT_PATH="../../src/boot" + +if [[ "$OSTYPE" == "darwin"* ]]; then + ARDUINO="/Applications/Arduino.app/Contents/MacOS/Arduino" +fi + +buildSDUBootSketch() { + BOARD=$1 + DESTINATION=$2 + + $ARDUINO --verify --board $BOARD --preserve-temp-files --pref build.path="$BUILD_PATH" $SKETCH + cat "$BUILD_PATH/$SKETCH_NAME.bin" | xxd -include -len 0x4000 > $DESTINATION + rm -rf "$BUILD_PATH" +} + +mkdir -p "$OUTPUT_PATH" + +buildSDUBootSketch "arduino:samd:mkrwifi1010" "$OUTPUT_PATH/mkrwifi1010.h" +buildSDUBootSketch "arduino:samd:mkrvidor4000" "$OUTPUT_PATH/mkrvidor4000.h" +buildSDUBootSketch "arduino:samd:nano_33_iot" "$OUTPUT_PATH/nano33iot.h" diff --git a/libraries/SNU/extras/NiNaBoot/lzss.cpp b/libraries/SNU/extras/NiNaBoot/lzss.cpp new file mode 100644 index 0000000..f37b813 --- /dev/null +++ b/libraries/SNU/extras/NiNaBoot/lzss.cpp @@ -0,0 +1,219 @@ +/************************************************************************************** + INCLUDE + **************************************************************************************/ + +#include "lzss.h" + +#include +#include + +#include + +/************************************************************************************** + DEFINE + **************************************************************************************/ + +#define EI 11 /* typically 10..13 */ +#define EJ 4 /* typically 4..5 */ +#define P 1 /* If match length <= P then output one character */ +#define N (1 << EI) /* buffer size */ +#define F ((1 << EJ) + 1) /* lookahead buffer size */ + +#define LZSS_EOF (-1) + +#define FPUTC_BUF_SIZE (64) +#define FGETC_BUF_SIZE (64) + +/************************************************************************************** + GLOBAL VARIABLES + **************************************************************************************/ + +extern FlashClass flash; +extern const char * UPDATE_FILE_NAME_LZSS; + +static uint32_t SKETCH_START = 0; +static uint32_t LZSS_FILE_SIZE = 0; +static WiFiStorageFile * update_file = 0; + +int bit_buffer = 0, bit_mask = 128; +unsigned char buffer[N * 2]; + +static char write_buf[FPUTC_BUF_SIZE]; +static size_t write_buf_num_bytes = 0; +static size_t bytes_written_fputc = 0; +static size_t bytes_written_flash = 0; +static uint32_t flash_addr = 0; + +/************************************************************************************** + PUBLIC FUNCTIONS + **************************************************************************************/ + +void lzss_init(WiFiStorageFile * update_file_ptr, uint32_t const sketch_start, uint32_t const lzss_file_size) +{ + SKETCH_START = sketch_start; + flash_addr = sketch_start; + update_file = update_file_ptr; + LZSS_FILE_SIZE = lzss_file_size; +} + +void lzss_flush() +{ + bytes_written_fputc += write_buf_num_bytes; + + /* Only write to the flash once we've surpassed + * the SSU in the update binary. + */ + if (bytes_written_fputc > (SKETCH_START - 0x2000)) + { + flash.write((void*)flash_addr, write_buf, write_buf_num_bytes); + flash_addr += write_buf_num_bytes; + } + + write_buf_num_bytes = 0; +} + +/************************************************************************************** + PRIVATE FUNCTIONS + **************************************************************************************/ + +void lzss_fputc(int const c) +{ + /* Buffer the decompressed data into a buffer so + * we can perform block writes and don't need to + * write every byte singly on the flash (which + * wouldn't be possible anyway). + */ + write_buf[write_buf_num_bytes] = static_cast(c); + write_buf_num_bytes++; + + /* The write buffer is full of decompressed + * data, write it to the flash now. + */ + if (write_buf_num_bytes == FPUTC_BUF_SIZE) + lzss_flush(); +} + +int lzss_fgetc() +{ + static uint8_t read_buf[FGETC_BUF_SIZE]; + static size_t read_buf_pos = FGETC_BUF_SIZE; + static size_t bytes_read_fgetc = 0; + static size_t bytes_read_from_modem = 0; + + /* lzss_file_size is set within SSUBoot:main + * and contains the size of the LZSS file. Once + * all those bytes have been read its time to return + * LZSS_EOF in order to signal that the end of + * the file has been reached. + */ + if (bytes_read_fgetc == LZSS_FILE_SIZE) + return LZSS_EOF; + + /* If there is no data left to be read from the read buffer + * than read a new block and store it into the read buffer. + */ + if (read_buf_pos == FGETC_BUF_SIZE) + { + /* Read the next block from the flash memory. */ + bytes_read_from_modem += update_file->read(read_buf, FGETC_BUF_SIZE); + /* Reset the read buffer position. */ + read_buf_pos = 0; + } + + uint8_t const c = read_buf[read_buf_pos]; + read_buf_pos++; + bytes_read_fgetc++; + + return c; +} + +/************************************************************************************** + LZSS FUNCTIONS + **************************************************************************************/ + +void putbit1(void) +{ + bit_buffer |= bit_mask; + if ((bit_mask >>= 1) == 0) { + lzss_fputc(bit_buffer); + bit_buffer = 0; bit_mask = 128; + } +} + +void putbit0(void) +{ + if ((bit_mask >>= 1) == 0) { + lzss_fputc(bit_buffer); + bit_buffer = 0; bit_mask = 128; + } +} + +void output1(int c) +{ + int mask; + + putbit1(); + mask = 256; + while (mask >>= 1) { + if (c & mask) putbit1(); + else putbit0(); + } +} + +void output2(int x, int y) +{ + int mask; + + putbit0(); + mask = N; + while (mask >>= 1) { + if (x & mask) putbit1(); + else putbit0(); + } + mask = (1 << EJ); + while (mask >>= 1) { + if (y & mask) putbit1(); + else putbit0(); + } +} + +int getbit(int n) /* get n bits */ +{ + int i, x; + static int buf, mask = 0; + + x = 0; + for (i = 0; i < n; i++) { + if (mask == 0) { + if ((buf = lzss_fgetc()) == LZSS_EOF) return LZSS_EOF; + mask = 128; + } + x <<= 1; + if (buf & mask) x++; + mask >>= 1; + } + return x; +} + +void lzss_decode(void) +{ + int i, j, k, r, c; + + for (i = 0; i < N - F; i++) buffer[i] = ' '; + r = N - F; + while ((c = getbit(1)) != LZSS_EOF) { + if (c) { + if ((c = getbit(8)) == LZSS_EOF) break; + lzss_fputc(c); + buffer[r++] = c; r &= (N - 1); + } else { + if ((i = getbit(EI)) == LZSS_EOF) break; + if ((j = getbit(EJ)) == LZSS_EOF) break; + for (k = 0; k <= j + 1; k++) { + c = buffer[(i + k) & (N - 1)]; + lzss_fputc(c); + buffer[r++] = c; r &= (N - 1); + } + } + } +} diff --git a/libraries/SNU/extras/NiNaBoot/lzss.h b/libraries/SNU/extras/NiNaBoot/lzss.h new file mode 100644 index 0000000..a78787e --- /dev/null +++ b/libraries/SNU/extras/NiNaBoot/lzss.h @@ -0,0 +1,20 @@ +#ifndef SSU_LZSS_H_ +#define SSU_LZSS_H_ + +/************************************************************************************** + INCLUDE + **************************************************************************************/ + +#include + +#include + +/************************************************************************************** + FUNCTION DEFINITION + **************************************************************************************/ + +void lzss_init(WiFiStorageFile * update_file_ptr, uint32_t const sketch_start, uint32_t const lzss_file_size); +void lzss_decode(); +void lzss_flush(); + +#endif /* SSU_LZSS_H_ */ diff --git a/libraries/SNU/keywords.txt b/libraries/SNU/keywords.txt new file mode 100644 index 0000000..d30ea5c --- /dev/null +++ b/libraries/SNU/keywords.txt @@ -0,0 +1,17 @@ +####################################### +# Syntax Coloring Map For SNU +####################################### + +####################################### +# Datatypes (KEYWORD1) +####################################### + +SNU KEYWORD1 + +####################################### +# Methods and Functions (KEYWORD2) +####################################### + +####################################### +# Constants (LITERAL1) +####################################### diff --git a/libraries/SNU/library.properties b/libraries/SNU/library.properties new file mode 100644 index 0000000..06b85cd --- /dev/null +++ b/libraries/SNU/library.properties @@ -0,0 +1,9 @@ +name=SNU +version=1.0.2 +author=Arduino +maintainer=Arduino +sentence=Update the sketch on your board with NiNa W10 wifi module +paragraph=Requires a board with NiNa W10 module onboard +category=Other +url=http://www.arduino.cc/en/Reference/SNU +architectures=megaAVR, samd diff --git a/libraries/SNU/src/SNU.cpp b/libraries/SNU/src/SNU.cpp new file mode 100644 index 0000000..590b084 --- /dev/null +++ b/libraries/SNU/src/SNU.cpp @@ -0,0 +1,34 @@ +/* + Copyright (c) 2017 Arduino LLC. 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 +*/ + +#include + +#include "SNU.h" + +__attribute__ ((section(".sketch_boot"))) +unsigned char sduBoot[0x4000] = { +#if defined(ARDUINO_SAMD_MKRWIFI1010) + #include "boot/mkrwifi1010.h" +#elif defined(ARDUINO_SAMD_MKRVIDOR4000) + #include "boot/mkrvidor4000.h" +#elif defined(ARDUINO_SAMD_NANO_33_IOT) + #include "boot/nano33iot.h" +#else + #error "Unsupported board!" +#endif +}; diff --git a/libraries/SNU/src/SNU.h b/libraries/SNU/src/SNU.h new file mode 100644 index 0000000..40a0933 --- /dev/null +++ b/libraries/SNU/src/SNU.h @@ -0,0 +1,24 @@ +/* + Copyright (c) 2017 Arduino LLC. 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 _SFU_H_INCLUDED +#define _SFU_H_INCLUDED + +// nothing for now + +#endif diff --git a/libraries/SNU/src/boot/mkrvidor4000.h b/libraries/SNU/src/boot/mkrvidor4000.h new file mode 100644 index 0000000..a9926ce --- /dev/null +++ b/libraries/SNU/src/boot/mkrvidor4000.h @@ -0,0 +1,1366 @@ + 0x00, 0x80, 0x00, 0x20, 0x65, 0x42, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, + 0x4d, 0x42, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, + 0xb9, 0x42, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, + 0x4d, 0x42, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, 0x11, 0x42, 0x00, 0x00, + 0x4d, 0x42, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, 0x51, 0x42, 0x00, 0x00, + 0x4d, 0x42, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, + 0x4d, 0x42, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, + 0x51, 0x40, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, + 0x4d, 0x42, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, + 0x4d, 0x42, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, + 0x4d, 0x42, 0x00, 0x00, 0x4d, 0x42, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0xf0, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xe0, 0x68, 0x00, 0x00, 0x04, 0x4b, 0x10, 0xb5, 0x00, 0x2b, 0x03, 0xd0, + 0x03, 0x49, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x10, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x00, 0xf4, 0x00, 0x00, 0x20, 0xe0, 0x68, 0x00, 0x00, + 0x1f, 0xb5, 0x14, 0x00, 0x04, 0x22, 0x00, 0x23, 0x01, 0x92, 0x03, 0xaa, + 0x00, 0x92, 0x0a, 0x00, 0x01, 0x00, 0x63, 0x20, 0x03, 0x93, 0x00, 0xf0, + 0x25, 0xfc, 0x03, 0x98, 0x20, 0x60, 0xc0, 0x43, 0xc0, 0x0f, 0x40, 0xb2, + 0x04, 0xb0, 0x10, 0xbd, 0x13, 0xb5, 0x04, 0x00, 0x03, 0xf0, 0x20, 0xfe, + 0x01, 0xaa, 0xc1, 0xb2, 0x20, 0x00, 0xff, 0xf7, 0xe3, 0xff, 0xc3, 0x17, + 0x18, 0x1a, 0xc0, 0x0f, 0x16, 0xbd, 0xf0, 0xb5, 0x06, 0x68, 0x43, 0x68, + 0x85, 0xb0, 0x14, 0x00, 0xb2, 0x18, 0x05, 0x00, 0x03, 0x91, 0x9a, 0x42, + 0x03, 0xd9, 0x00, 0x24, 0x9e, 0x42, 0x10, 0xd2, 0x9c, 0x1b, 0xaf, 0x68, + 0x38, 0x00, 0x03, 0xf0, 0x05, 0xfe, 0x03, 0x9b, 0xc2, 0xb2, 0x00, 0x93, + 0x01, 0x94, 0x33, 0x00, 0x39, 0x00, 0x61, 0x20, 0x00, 0xf0, 0xf6, 0xfb, + 0x2b, 0x68, 0x1b, 0x19, 0x2b, 0x60, 0x20, 0x00, 0x05, 0xb0, 0xf0, 0xbd, + 0x70, 0xb5, 0x85, 0x68, 0x04, 0x00, 0x28, 0x00, 0x03, 0xf0, 0xf0, 0xfd, + 0x22, 0x1d, 0xc1, 0xb2, 0x28, 0x00, 0xff, 0xf7, 0xb3, 0xff, 0x60, 0x68, + 0x70, 0xbd, 0x37, 0xb5, 0x00, 0x24, 0x85, 0x68, 0x04, 0x60, 0x28, 0x00, + 0x03, 0xf0, 0xe2, 0xfd, 0x29, 0x00, 0xc2, 0xb2, 0x01, 0x94, 0x00, 0x94, + 0x23, 0x00, 0x62, 0x20, 0x00, 0xf0, 0xd4, 0xfb, 0x37, 0xbd, 0x00, 0x00, + 0xf0, 0xb5, 0x72, 0x4c, 0x02, 0x25, 0xa5, 0x44, 0x00, 0xaf, 0x02, 0xf0, + 0x8d, 0xf9, 0x03, 0xf0, 0xb9, 0xfc, 0x01, 0x20, 0x02, 0xf0, 0xb0, 0xf8, + 0x01, 0x21, 0x6d, 0x48, 0x01, 0xf0, 0x68, 0xfb, 0x03, 0x22, 0x6c, 0x49, + 0x21, 0x20, 0x01, 0xf0, 0x7d, 0xff, 0xfa, 0x20, 0x80, 0x00, 0x02, 0xf0, + 0xa3, 0xf8, 0x69, 0x4c, 0x69, 0x4e, 0x20, 0x00, 0x00, 0xf0, 0xf6, 0xfe, + 0x4a, 0x23, 0x7b, 0x63, 0x1a, 0x3b, 0xf9, 0x18, 0x03, 0x22, 0x20, 0x00, + 0x3e, 0x63, 0xbd, 0x63, 0x00, 0xf0, 0x08, 0xff, 0x30, 0x23, 0x4a, 0x22, + 0x62, 0x49, 0xf8, 0x18, 0x7a, 0x63, 0x49, 0x3a, 0x39, 0x63, 0xba, 0x63, + 0x01, 0x00, 0x52, 0x19, 0x20, 0x00, 0x00, 0xf0, 0xfb, 0xfe, 0x3e, 0x63, + 0x40, 0x26, 0xbd, 0x63, 0x2e, 0x35, 0x7b, 0x19, 0x19, 0x00, 0x03, 0x22, + 0x20, 0x00, 0x7e, 0x63, 0x00, 0xf0, 0xf0, 0xfe, 0x01, 0x22, 0x57, 0x49, + 0xba, 0x63, 0x39, 0x63, 0x02, 0x32, 0x79, 0x19, 0x20, 0x00, 0x7e, 0x63, + 0x00, 0xf0, 0xe6, 0xfe, 0x53, 0x49, 0x38, 0x1d, 0x03, 0xf0, 0x78, 0xfb, + 0x52, 0x48, 0x00, 0xf0, 0xdb, 0xf8, 0xff, 0x28, 0x32, 0xd0, 0x00, 0xf0, + 0xd3, 0xf8, 0x01, 0x00, 0x38, 0x1d, 0x03, 0xf0, 0x8c, 0xfb, 0x4e, 0x49, + 0x78, 0x19, 0x03, 0xf0, 0x69, 0xfb, 0x79, 0x19, 0x38, 0x1d, 0x03, 0xf0, + 0xac, 0xfb, 0x04, 0x00, 0x78, 0x19, 0x03, 0xf0, 0x19, 0xfb, 0x00, 0x2c, + 0x1e, 0xd1, 0x48, 0x4d, 0x28, 0x68, 0xff, 0xf7, 0x49, 0xff, 0x00, 0x28, + 0x42, 0xd0, 0x29, 0x68, 0x10, 0x25, 0x78, 0x19, 0x00, 0xf0, 0x0d, 0xf9, + 0x1c, 0x23, 0x2e, 0x00, 0x14, 0x22, 0xf9, 0x18, 0x78, 0x19, 0xff, 0xf7, + 0x48, 0xff, 0xb8, 0x19, 0xfd, 0x69, 0xff, 0xf7, 0x65, 0xff, 0x08, 0x38, + 0x85, 0x42, 0x17, 0xd0, 0x00, 0x23, 0x3b, 0x61, 0x10, 0x33, 0xf8, 0x18, + 0xff, 0xf7, 0x69, 0xff, 0xc0, 0x23, 0xdb, 0x01, 0x1a, 0x68, 0x82, 0xf3, + 0x08, 0x88, 0x37, 0x4a, 0x93, 0x60, 0x37, 0x4b, 0x1b, 0x68, 0x18, 0x47, + 0x38, 0x1d, 0x03, 0xf0, 0xeb, 0xfa, 0x00, 0x20, 0xbd, 0x46, 0x34, 0x4b, + 0x9d, 0x44, 0xf0, 0xbd, 0x08, 0x23, 0x3b, 0x61, 0xfa, 0x69, 0x13, 0x00, + 0x80, 0x3b, 0xa3, 0x42, 0x08, 0xd9, 0x30, 0x23, 0xf9, 0x18, 0x20, 0x3b, + 0x80, 0x22, 0xf8, 0x18, 0xff, 0xf7, 0x1b, 0xff, 0x80, 0x34, 0xf1, 0xe7, + 0x30, 0x23, 0xf9, 0x18, 0x20, 0x3b, 0x12, 0x1b, 0xf8, 0x18, 0xff, 0xf7, + 0x12, 0xff, 0xcf, 0xe7, 0x27, 0x4c, 0x20, 0x68, 0xff, 0xf7, 0x00, 0xff, + 0x00, 0x28, 0xcf, 0xd0, 0x21, 0x68, 0x1c, 0x24, 0x38, 0x19, 0x00, 0xf0, + 0xc4, 0xf8, 0x38, 0x19, 0xff, 0xf7, 0x24, 0xff, 0x80, 0x23, 0xdb, 0x01, + 0x98, 0x42, 0xc3, 0xd9, 0xc0, 0x21, 0xfb, 0x61, 0x1e, 0x4b, 0xc9, 0x01, + 0xc4, 0x18, 0x22, 0x00, 0x1d, 0x48, 0xc0, 0x25, 0x00, 0xf0, 0xe8, 0xfb, + 0x80, 0x26, 0xed, 0x01, 0x30, 0x23, 0x1c, 0x20, 0xf9, 0x18, 0x32, 0x00, + 0x38, 0x18, 0xff, 0xf7, 0xec, 0xfe, 0x30, 0x22, 0x33, 0x00, 0x29, 0x00, + 0xba, 0x18, 0x15, 0x48, 0x00, 0xf0, 0x88, 0xfb, 0x14, 0x4b, 0xeb, 0x18, + 0x80, 0x35, 0xa3, 0x42, 0xec, 0xd3, 0x00, 0x23, 0xfb, 0x61, 0x1c, 0x33, + 0x9d, 0xe7, 0xc0, 0x46, 0xcc, 0xfb, 0xff, 0xff, 0x10, 0x06, 0x00, 0x20, + 0x49, 0x2b, 0x00, 0x00, 0x5c, 0x11, 0x00, 0x20, 0x01, 0x00, 0x00, 0x02, + 0x02, 0x00, 0x00, 0x02, 0x15, 0x5e, 0x00, 0x00, 0x34, 0x01, 0x00, 0x20, + 0x10, 0x5e, 0x00, 0x00, 0x08, 0x00, 0x00, 0x20, 0x00, 0xed, 0x00, 0xe0, + 0x04, 0x60, 0x00, 0x00, 0x34, 0x04, 0x00, 0x00, 0x04, 0x00, 0x00, 0x20, + 0x00, 0xc0, 0xff, 0xff, 0x14, 0x01, 0x00, 0x20, 0x80, 0xa0, 0xff, 0xff, + 0x13, 0xb5, 0x00, 0x24, 0x06, 0x48, 0x23, 0x00, 0x22, 0x00, 0x21, 0x00, + 0x00, 0x94, 0x02, 0xf0, 0x27, 0xfa, 0x22, 0x00, 0x21, 0x00, 0x03, 0x48, + 0x00, 0xf0, 0x36, 0xfb, 0x13, 0xbd, 0xc0, 0x46, 0x0c, 0x01, 0x00, 0x20, + 0x14, 0x01, 0x00, 0x20, 0x07, 0xb5, 0x00, 0x21, 0x03, 0x48, 0x00, 0x91, + 0x0b, 0x00, 0x0a, 0x00, 0x02, 0xf0, 0x14, 0xfa, 0x07, 0xbd, 0xc0, 0x46, + 0x2c, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x00, 0xf0, 0x7f, 0xfa, 0x10, 0xbd, + 0x10, 0xb5, 0x00, 0xf0, 0x53, 0xfa, 0x10, 0xbd, 0x07, 0xb5, 0x00, 0x21, + 0x04, 0x48, 0x0b, 0x00, 0x0a, 0x00, 0x00, 0x91, 0x02, 0xf0, 0x00, 0xfa, + 0x02, 0x4b, 0x03, 0x4a, 0x1a, 0x60, 0x07, 0xbd, 0x38, 0x01, 0x00, 0x20, + 0x34, 0x01, 0x00, 0x20, 0x50, 0xc3, 0x00, 0x00, 0x00, 0x20, 0x70, 0x47, + 0x07, 0xb5, 0x00, 0x21, 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, + 0x02, 0xf0, 0xec, 0xf9, 0x07, 0xbd, 0xc0, 0x46, 0x40, 0x01, 0x00, 0x20, + 0x07, 0xb5, 0x00, 0x21, 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, + 0x02, 0xf0, 0xe0, 0xf9, 0x07, 0xbd, 0xc0, 0x46, 0x48, 0x01, 0x00, 0x20, + 0x07, 0xb5, 0x00, 0x21, 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, + 0x02, 0xf0, 0xd4, 0xf9, 0x07, 0xbd, 0xc0, 0x46, 0x50, 0x01, 0x00, 0x20, + 0x30, 0xb5, 0x85, 0xb0, 0x0c, 0x00, 0x05, 0x00, 0x03, 0xf0, 0x6a, 0xfc, + 0x04, 0x21, 0x00, 0x23, 0x01, 0x91, 0x03, 0xa9, 0xc2, 0xb2, 0x00, 0x91, + 0x63, 0x20, 0x29, 0x00, 0x03, 0x93, 0x00, 0xf0, 0x59, 0xfa, 0x03, 0x98, + 0x20, 0x60, 0xc0, 0x43, 0xc0, 0x0f, 0x05, 0xb0, 0x30, 0xbd, 0x10, 0xb5, + 0x04, 0x00, 0x00, 0x23, 0xa1, 0x60, 0x08, 0x00, 0x21, 0x1d, 0x23, 0x60, + 0x63, 0x60, 0xff, 0xf7, 0xdf, 0xff, 0x20, 0x00, 0x10, 0xbd, 0x00, 0x00, + 0x07, 0xb5, 0x00, 0x21, 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, + 0x02, 0xf0, 0xa4, 0xf9, 0x07, 0xbd, 0xc0, 0x46, 0x58, 0x01, 0x00, 0x20, + 0x07, 0xb5, 0x00, 0x21, 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, + 0x02, 0xf0, 0x98, 0xf9, 0x07, 0xbd, 0xc0, 0x46, 0x60, 0x01, 0x00, 0x20, + 0x10, 0xb5, 0x04, 0x00, 0x78, 0x22, 0x00, 0x21, 0x03, 0xf0, 0x4f, 0xfb, + 0x20, 0x00, 0x10, 0xbd, 0x10, 0xb5, 0x0c, 0x24, 0x4c, 0x43, 0x04, 0x19, + 0x20, 0x68, 0x00, 0x28, 0x05, 0xd0, 0x03, 0xf0, 0x31, 0xfb, 0x00, 0x23, + 0x63, 0x60, 0x23, 0x60, 0xa3, 0x60, 0x10, 0xbd, 0x70, 0xb5, 0x05, 0x00, + 0x00, 0x24, 0x21, 0x00, 0x28, 0x00, 0x01, 0x34, 0xff, 0xf7, 0xea, 0xff, + 0x0a, 0x2c, 0xf8, 0xd1, 0x28, 0x00, 0x70, 0xbd, 0x10, 0xb5, 0x05, 0x4c, + 0x20, 0x00, 0xff, 0xf7, 0xd9, 0xff, 0x04, 0x4a, 0x04, 0x49, 0x20, 0x00, + 0x03, 0xf0, 0x46, 0xfa, 0x10, 0xbd, 0xc0, 0x46, 0x68, 0x01, 0x00, 0x20, + 0x00, 0x00, 0x00, 0x20, 0x31, 0x25, 0x00, 0x00, 0x80, 0xb5, 0x0b, 0x4f, + 0x0b, 0x4b, 0xbd, 0x44, 0x00, 0x93, 0x01, 0x90, 0x00, 0x29, 0x04, 0xd0, + 0x02, 0x23, 0x01, 0x29, 0x02, 0xd0, 0x02, 0x91, 0x01, 0xe0, 0x01, 0x23, + 0x02, 0x93, 0x03, 0x22, 0x69, 0x46, 0x05, 0x48, 0x00, 0xf0, 0x44, 0xfd, + 0x80, 0x23, 0xdb, 0x00, 0x9d, 0x44, 0x80, 0xbd, 0x00, 0xfc, 0xff, 0xff, + 0x01, 0x00, 0x00, 0x02, 0x5c, 0x11, 0x00, 0x20, 0x80, 0xb5, 0x07, 0x4f, + 0x07, 0x4b, 0xbd, 0x44, 0x01, 0x90, 0x02, 0x91, 0x03, 0x22, 0x69, 0x46, + 0x05, 0x48, 0x00, 0x93, 0x00, 0xf0, 0x2e, 0xfd, 0x80, 0x23, 0xdb, 0x00, + 0x9d, 0x44, 0x80, 0xbd, 0x00, 0xfc, 0xff, 0xff, 0x02, 0x00, 0x00, 0x02, + 0x5c, 0x11, 0x00, 0x20, 0x80, 0xb5, 0x07, 0x4f, 0x07, 0x4b, 0xbd, 0x44, + 0x01, 0x90, 0x02, 0x22, 0x69, 0x46, 0x06, 0x48, 0x00, 0x93, 0x00, 0xf0, + 0x19, 0xfd, 0x80, 0x23, 0xdb, 0x00, 0x9d, 0x44, 0x80, 0xbd, 0xc0, 0x46, + 0x00, 0xfc, 0xff, 0xff, 0x03, 0x00, 0x00, 0x02, 0x5c, 0x11, 0x00, 0x20, + 0xf8, 0xb5, 0x01, 0x21, 0x28, 0x48, 0x01, 0xf0, 0x51, 0xf9, 0x28, 0x49, + 0x03, 0x22, 0x21, 0x20, 0x01, 0xf0, 0x66, 0xfd, 0xfa, 0x20, 0x80, 0x00, + 0x01, 0xf0, 0x8c, 0xfe, 0x24, 0x48, 0x00, 0xf0, 0xe1, 0xfc, 0x4b, 0x23, + 0x00, 0x24, 0x23, 0x4f, 0x23, 0x4a, 0x24, 0x4d, 0x24, 0x4e, 0x3b, 0x70, + 0x06, 0x3b, 0x13, 0x70, 0x23, 0x48, 0x05, 0x3b, 0x2b, 0x70, 0x34, 0x70, + 0x00, 0xf0, 0x22, 0xfe, 0x38, 0x78, 0x01, 0x21, 0xff, 0xf7, 0x92, 0xff, + 0x1b, 0x4b, 0x21, 0x00, 0x18, 0x78, 0xff, 0xf7, 0x8d, 0xff, 0x28, 0x78, + 0x01, 0x21, 0xff, 0xf7, 0x89, 0xff, 0x01, 0x21, 0x4a, 0x20, 0xff, 0xf7, + 0x85, 0xff, 0x01, 0x21, 0x4a, 0x20, 0xff, 0xf7, 0x9f, 0xff, 0x38, 0x78, + 0x01, 0x21, 0xff, 0xf7, 0x9b, 0xff, 0x31, 0x78, 0x28, 0x78, 0xff, 0xf7, + 0x97, 0xff, 0x0a, 0x20, 0x01, 0xf0, 0x5a, 0xfe, 0x31, 0x78, 0x01, 0x26, + 0x28, 0x78, 0x71, 0x40, 0xff, 0xf7, 0x8e, 0xff, 0x0e, 0x48, 0x01, 0xf0, + 0x51, 0xfe, 0x21, 0x00, 0x4a, 0x20, 0xff, 0xf7, 0x87, 0xff, 0x21, 0x00, + 0x4a, 0x20, 0xff, 0xf7, 0x65, 0xff, 0x0a, 0x4b, 0x1e, 0x70, 0xf8, 0xbd, + 0x10, 0x06, 0x00, 0x20, 0x49, 0x2b, 0x00, 0x00, 0x5c, 0x11, 0x00, 0x20, + 0x0e, 0x00, 0x00, 0x20, 0x0c, 0x00, 0x00, 0x20, 0x0d, 0x00, 0x00, 0x20, + 0xe0, 0x01, 0x00, 0x20, 0x60, 0x11, 0x00, 0x20, 0xee, 0x02, 0x00, 0x00, + 0xe1, 0x01, 0x00, 0x20, 0x13, 0xb5, 0x00, 0x24, 0x6b, 0x46, 0x5c, 0x71, + 0x1c, 0x71, 0x01, 0x9a, 0x0b, 0x49, 0x0c, 0x48, 0x00, 0xf0, 0xdc, 0xfd, + 0x0b, 0x4b, 0x21, 0x00, 0x18, 0x78, 0xff, 0xf7, 0x5d, 0xff, 0x01, 0xf0, + 0xeb, 0xfd, 0x04, 0x00, 0x08, 0x4b, 0x18, 0x78, 0xff, 0xf7, 0x6c, 0xff, + 0x01, 0x28, 0x04, 0xd0, 0x01, 0xf0, 0xe2, 0xfd, 0x00, 0x1b, 0x04, 0x28, + 0xf4, 0xd9, 0x13, 0xbd, 0x00, 0x12, 0x7a, 0x00, 0x60, 0x11, 0x00, 0x20, + 0x0e, 0x00, 0x00, 0x20, 0x0c, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x4b, + 0x01, 0x21, 0x18, 0x78, 0xff, 0xf7, 0x40, 0xff, 0x02, 0x48, 0x00, 0xf0, + 0xd3, 0xfd, 0x10, 0xbd, 0x0e, 0x00, 0x00, 0x20, 0x60, 0x11, 0x00, 0x20, + 0x07, 0xb5, 0x6b, 0x46, 0xd8, 0x71, 0xd9, 0x79, 0x02, 0x48, 0xc9, 0xb2, + 0x00, 0xf0, 0xda, 0xfd, 0x0e, 0xbd, 0xc0, 0x46, 0x60, 0x11, 0x00, 0x20, + 0x10, 0xb5, 0x03, 0x4b, 0x18, 0x78, 0xff, 0xf7, 0x3d, 0xff, 0x00, 0x28, + 0xf9, 0xd1, 0x10, 0xbd, 0x0c, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, + 0xff, 0x20, 0xff, 0xf7, 0xe5, 0xff, 0x20, 0x70, 0x10, 0xbd, 0x70, 0xb5, + 0x0c, 0x00, 0x05, 0x00, 0x08, 0x00, 0xff, 0xf7, 0xf3, 0xff, 0x20, 0x78, + 0x40, 0x1b, 0x43, 0x42, 0x58, 0x41, 0x70, 0xbd, 0x13, 0xb5, 0x6b, 0x46, + 0xdc, 0x1d, 0x00, 0x23, 0x20, 0x00, 0x23, 0x70, 0xff, 0xf7, 0xe6, 0xff, + 0x20, 0x78, 0x16, 0xbd, 0x70, 0xb5, 0x05, 0x00, 0x08, 0x4c, 0xff, 0xf7, + 0xf1, 0xff, 0xef, 0x28, 0x08, 0xd0, 0x01, 0x3c, 0x00, 0x2c, 0x01, 0xd0, + 0xa8, 0x42, 0xf6, 0xd1, 0x40, 0x1b, 0x43, 0x42, 0x58, 0x41, 0x70, 0xbd, + 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, 0xc0, 0x46, 0xe9, 0x03, 0x00, 0x00, + 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x00, 0x20, 0x16, 0x00, 0xff, 0xf7, + 0xb1, 0xff, 0x65, 0x19, 0xac, 0x42, 0x04, 0xd0, 0x20, 0x78, 0xff, 0xf7, + 0xab, 0xff, 0x01, 0x34, 0xf8, 0xe7, 0x01, 0x2e, 0x02, 0xd1, 0xee, 0x20, + 0xff, 0xf7, 0xa4, 0xff, 0x70, 0xbd, 0xf8, 0xb5, 0x05, 0x00, 0x08, 0x00, + 0x0e, 0x00, 0x17, 0x00, 0x2c, 0x00, 0xff, 0xf7, 0x9b, 0xff, 0x63, 0x1b, + 0x9e, 0x42, 0x04, 0xdd, 0x20, 0x78, 0xff, 0xf7, 0x95, 0xff, 0x01, 0x34, + 0xf7, 0xe7, 0x01, 0x2f, 0x02, 0xd1, 0xee, 0x20, 0xff, 0xf7, 0x8e, 0xff, + 0xf8, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0xff, 0x20, 0xff, 0xf7, 0x88, 0xff, + 0x00, 0x2c, 0x00, 0xd0, 0x20, 0x70, 0x10, 0xbd, 0xf0, 0xb5, 0x85, 0xb0, + 0x1f, 0x00, 0x02, 0xab, 0xdc, 0x1d, 0x00, 0x23, 0x05, 0x00, 0xe0, 0x20, + 0x01, 0x91, 0x16, 0x00, 0x23, 0x70, 0xff, 0xf7, 0xa9, 0xff, 0x00, 0x28, + 0x02, 0xd1, 0x00, 0x20, 0x05, 0xb0, 0xf0, 0xbd, 0x20, 0x00, 0xff, 0xf7, + 0x85, 0xff, 0x80, 0x22, 0x23, 0x78, 0x15, 0x43, 0xab, 0x42, 0xf4, 0xd1, + 0x20, 0x00, 0xff, 0xf7, 0x7d, 0xff, 0x23, 0x78, 0x01, 0x9a, 0x93, 0x42, + 0xed, 0xd1, 0x38, 0x00, 0xff, 0xf7, 0xd3, 0xff, 0x35, 0x00, 0x3a, 0x78, + 0xab, 0x1b, 0x9a, 0x42, 0x04, 0xdd, 0x28, 0x00, 0xff, 0xf7, 0x6e, 0xff, + 0x01, 0x35, 0xf6, 0xe7, 0x21, 0x00, 0xee, 0x20, 0xff, 0xf7, 0x6f, 0xff, + 0x01, 0x20, 0xdb, 0xe7, 0x70, 0xb5, 0x04, 0x00, 0xe0, 0x20, 0x0d, 0x00, + 0xff, 0xf7, 0x4a, 0xff, 0x7f, 0x20, 0x20, 0x40, 0xff, 0xf7, 0x46, 0xff, + 0x28, 0x00, 0xff, 0xf7, 0x43, 0xff, 0x00, 0x2d, 0x02, 0xd1, 0xee, 0x20, + 0xff, 0xf7, 0x3e, 0xff, 0x70, 0xbd, 0x00, 0x00, 0x12, 0x4b, 0x13, 0xb5, + 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0xff, 0xf7, 0x99, 0xfe, 0xff, 0xf7, + 0x3f, 0xff, 0xff, 0xf7, 0xfd, 0xfe, 0x00, 0x21, 0x20, 0x20, 0xff, 0xf7, + 0xdd, 0xff, 0xff, 0xf7, 0x1d, 0xff, 0xff, 0xf7, 0x35, 0xff, 0xff, 0xf7, + 0xf3, 0xfe, 0x6b, 0x46, 0x9c, 0x1d, 0xff, 0x23, 0x23, 0x70, 0x6b, 0x46, + 0x00, 0x22, 0x07, 0x33, 0x1a, 0x70, 0x01, 0x21, 0x22, 0x00, 0x20, 0x20, + 0xff, 0xf7, 0x96, 0xff, 0xff, 0xf7, 0x0a, 0xff, 0x20, 0x78, 0x16, 0xbd, + 0xe1, 0x01, 0x00, 0x20, 0x11, 0x4b, 0x13, 0xb5, 0x1b, 0x78, 0x00, 0x2b, + 0x01, 0xd1, 0xff, 0xf7, 0x71, 0xfe, 0xff, 0xf7, 0x17, 0xff, 0xff, 0xf7, + 0xd5, 0xfe, 0x00, 0x21, 0x37, 0x20, 0xff, 0xf7, 0xb5, 0xff, 0xff, 0xf7, + 0xf5, 0xfe, 0xff, 0xf7, 0x0d, 0xff, 0xff, 0xf7, 0xcb, 0xfe, 0x6b, 0x46, + 0x00, 0x22, 0x07, 0x4c, 0x07, 0x33, 0x1a, 0x70, 0x01, 0x21, 0x22, 0x00, + 0x37, 0x20, 0xff, 0xf7, 0x71, 0xff, 0xff, 0xf7, 0xe5, 0xfe, 0x20, 0x00, + 0x16, 0xbd, 0xc0, 0x46, 0xe1, 0x01, 0x00, 0x20, 0xec, 0x01, 0x00, 0x20, + 0xf0, 0xb5, 0x85, 0xb0, 0x01, 0x93, 0x29, 0x4b, 0x06, 0x00, 0x1b, 0x78, + 0x00, 0x91, 0x14, 0x00, 0x00, 0x2b, 0x01, 0xd1, 0xff, 0xf7, 0x44, 0xfe, + 0x35, 0x00, 0x60, 0x3d, 0x6f, 0x42, 0x6f, 0x41, 0x03, 0x37, 0xff, 0xf7, + 0xe5, 0xfe, 0xff, 0xf7, 0xa3, 0xfe, 0x39, 0x00, 0x30, 0x00, 0xff, 0xf7, + 0x83, 0xff, 0x00, 0x22, 0x04, 0x21, 0x01, 0xa8, 0xff, 0xf7, 0x2b, 0xff, + 0x00, 0x22, 0x04, 0x21, 0x0b, 0xa8, 0xff, 0xf7, 0x26, 0xff, 0x6a, 0x1e, + 0x95, 0x41, 0x21, 0x00, 0xea, 0xb2, 0x00, 0x98, 0xff, 0xf7, 0x1f, 0xff, + 0x60, 0x2e, 0x04, 0xd1, 0x01, 0x22, 0x0b, 0x99, 0x0a, 0x98, 0xff, 0xf7, + 0x03, 0xff, 0x0c, 0x34, 0xe4, 0x19, 0x03, 0x27, 0x25, 0x00, 0x3d, 0x40, + 0x03, 0xd0, 0xff, 0xf7, 0xdb, 0xfe, 0x01, 0x34, 0xf8, 0xe7, 0xff, 0xf7, + 0xa1, 0xfe, 0x0f, 0x24, 0xff, 0xf7, 0xb8, 0xfe, 0xff, 0xf7, 0x76, 0xfe, + 0x0e, 0x23, 0x6c, 0x44, 0x6b, 0x44, 0x1d, 0x70, 0x25, 0x70, 0x60, 0x2e, + 0x00, 0xd1, 0x0a, 0x93, 0x23, 0x00, 0x0a, 0x9a, 0x01, 0x21, 0x30, 0x00, + 0xff, 0xf7, 0x18, 0xff, 0xff, 0xf7, 0x8c, 0xfe, 0x00, 0x20, 0x20, 0x56, + 0x05, 0xb0, 0xf0, 0xbd, 0xe1, 0x01, 0x00, 0x20, 0x07, 0xb5, 0x00, 0x21, + 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, 0x01, 0xf0, 0x06, 0xff, + 0x07, 0xbd, 0xc0, 0x46, 0xe4, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x05, 0x4a, + 0x05, 0x49, 0x06, 0x48, 0x00, 0xf0, 0x10, 0xf8, 0x00, 0x22, 0x05, 0x4b, + 0x05, 0x49, 0x1a, 0x70, 0x5a, 0x54, 0x10, 0xbd, 0x01, 0x04, 0x00, 0x00, + 0x00, 0x5f, 0x00, 0x00, 0xf8, 0x05, 0x00, 0x20, 0xf2, 0x01, 0x00, 0x20, + 0x02, 0x04, 0x00, 0x00, 0x30, 0xb5, 0x09, 0x4d, 0x09, 0x4c, 0xab, 0x68, + 0x5b, 0x03, 0x5b, 0x0f, 0x9b, 0x00, 0x1c, 0x59, 0x04, 0x60, 0xab, 0x68, + 0x01, 0x61, 0x9b, 0xb2, 0x43, 0x60, 0x63, 0x43, 0xa4, 0x00, 0x83, 0x60, + 0xc4, 0x60, 0x42, 0x61, 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x00, 0x64, 0x00, 0x00, 0xf7, 0xb5, 0x80, 0x26, 0x1a, 0x4d, 0x01, 0x91, + 0x6f, 0x68, 0x03, 0x33, 0x3e, 0x43, 0x9b, 0x08, 0x6e, 0x60, 0x00, 0x2b, + 0x2b, 0xd0, 0x17, 0x4e, 0x2e, 0x80, 0x2e, 0x7d, 0xf1, 0x07, 0xfc, 0xd5, + 0x1e, 0x00, 0x07, 0x68, 0x99, 0x1b, 0xbf, 0x08, 0x8f, 0x42, 0x19, 0xd9, + 0x00, 0x2e, 0x17, 0xd0, 0xff, 0x21, 0x17, 0x78, 0x8c, 0x43, 0x3c, 0x43, + 0x0f, 0x49, 0x57, 0x78, 0x0c, 0x40, 0x3f, 0x02, 0x3c, 0x43, 0x97, 0x78, + 0x01, 0x3e, 0x39, 0x04, 0x0c, 0x4f, 0x27, 0x40, 0xd4, 0x78, 0xbf, 0xb2, + 0x0f, 0x43, 0x24, 0x06, 0x01, 0x99, 0x3c, 0x43, 0x10, 0xc1, 0x01, 0x91, + 0x04, 0x32, 0xe0, 0xe7, 0x07, 0x4b, 0x2b, 0x80, 0x2b, 0x7d, 0xdb, 0x07, + 0xfc, 0xd5, 0x33, 0x00, 0xd1, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, + 0x44, 0xa5, 0xff, 0xff, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, + 0x04, 0xa5, 0xff, 0xff, 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, + 0x1a, 0x80, 0x1a, 0x7d, 0xd2, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, + 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x04, 0x00, + 0x0d, 0x00, 0x16, 0x00, 0xe3, 0x68, 0x29, 0x00, 0x20, 0x00, 0xb3, 0x42, + 0x05, 0xd2, 0xff, 0xf7, 0xe7, 0xff, 0xe3, 0x68, 0xed, 0x18, 0xf6, 0x1a, + 0xf4, 0xe7, 0xff, 0xf7, 0xe1, 0xff, 0x70, 0xbd, 0x70, 0x47, 0x00, 0x00, + 0x10, 0xb5, 0x04, 0x48, 0x00, 0xf0, 0xaa, 0xfe, 0x01, 0x22, 0x03, 0x4b, + 0x52, 0x42, 0x1a, 0x60, 0x10, 0xbd, 0xc0, 0x46, 0x10, 0x06, 0x00, 0x20, + 0x10, 0x00, 0x00, 0x20, 0xf8, 0xb5, 0x05, 0x00, 0x0e, 0x00, 0x17, 0x00, + 0x00, 0x24, 0xbc, 0x42, 0x08, 0xd0, 0x2b, 0x68, 0x31, 0x5d, 0x1b, 0x68, + 0x28, 0x00, 0x98, 0x47, 0x00, 0x28, 0x01, 0xd0, 0x01, 0x34, 0xf4, 0xe7, + 0x20, 0x00, 0xf8, 0xbd, 0x70, 0x47, 0x03, 0x00, 0xfc, 0x33, 0x59, 0x6a, + 0x1a, 0x6a, 0x91, 0x42, 0x07, 0xd0, 0x5a, 0x6a, 0x80, 0x18, 0x5a, 0x6a, + 0x00, 0x7f, 0x01, 0x32, 0xd2, 0xb2, 0x5a, 0x62, 0x70, 0x47, 0x01, 0x20, + 0x40, 0x42, 0xfb, 0xe7, 0x03, 0x00, 0xfc, 0x33, 0x59, 0x6a, 0x1a, 0x6a, + 0x91, 0x42, 0x03, 0xd0, 0x5b, 0x6a, 0xc0, 0x18, 0x00, 0x7f, 0x70, 0x47, + 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, 0x70, 0xb5, 0x04, 0x00, 0x03, 0x7c, + 0x00, 0x20, 0x83, 0x42, 0x18, 0xd0, 0x88, 0x23, 0xff, 0x26, 0x9b, 0x00, + 0xe3, 0x18, 0x5d, 0x68, 0x9a, 0x68, 0x01, 0x35, 0x35, 0x40, 0x95, 0x42, + 0x0e, 0xd0, 0x5a, 0x68, 0x9d, 0x68, 0x01, 0x32, 0x32, 0x40, 0x01, 0x30, + 0xaa, 0x42, 0x07, 0xd0, 0x58, 0x68, 0x24, 0x18, 0x92, 0x20, 0x40, 0x00, + 0x21, 0x54, 0x24, 0x38, 0x5a, 0x60, 0xff, 0x38, 0x70, 0xbd, 0x03, 0x00, + 0xfc, 0x33, 0x18, 0x6a, 0x5b, 0x6a, 0xc0, 0x1a, 0x01, 0xd5, 0x01, 0x30, + 0xff, 0x30, 0x70, 0x47, 0xf7, 0xb5, 0x01, 0x93, 0xfa, 0x23, 0x80, 0x26, + 0x00, 0x25, 0x04, 0x00, 0x9b, 0x00, 0x83, 0x60, 0x13, 0x4b, 0x76, 0x00, + 0x08, 0x33, 0x0f, 0x00, 0x45, 0x60, 0x29, 0x00, 0x00, 0x92, 0x03, 0x60, + 0x32, 0x00, 0x1c, 0x30, 0x02, 0xf0, 0xb5, 0xff, 0x23, 0x00, 0x20, 0x00, + 0xfc, 0x33, 0x25, 0x30, 0x1d, 0x62, 0x32, 0x00, 0x5d, 0x62, 0x29, 0x00, + 0xff, 0x30, 0x02, 0xf0, 0xaa, 0xff, 0x88, 0x23, 0x9b, 0x00, 0xe3, 0x18, + 0x5d, 0x60, 0x9d, 0x60, 0x00, 0x9b, 0x04, 0x22, 0x63, 0x61, 0x01, 0x9b, + 0x67, 0x74, 0xa3, 0x61, 0x8e, 0x23, 0x9b, 0x00, 0x25, 0x74, 0x20, 0x00, + 0xe2, 0x54, 0xfe, 0xbd, 0x20, 0x64, 0x00, 0x00, 0x10, 0xb5, 0x0a, 0x23, + 0x09, 0x22, 0x01, 0x21, 0x0e, 0x48, 0xff, 0xf7, 0xc7, 0xff, 0x0c, 0x23, + 0x0b, 0x22, 0x02, 0x21, 0x0c, 0x48, 0xff, 0xf7, 0xc1, 0xff, 0x0e, 0x23, + 0x0d, 0x22, 0x03, 0x21, 0x0a, 0x48, 0xff, 0xf7, 0xbb, 0xff, 0x10, 0x23, + 0x0f, 0x22, 0x04, 0x21, 0x08, 0x48, 0xff, 0xf7, 0xb5, 0xff, 0x01, 0x22, + 0x52, 0x42, 0x13, 0x00, 0x00, 0x21, 0x06, 0x48, 0xff, 0xf7, 0xae, 0xff, + 0x10, 0xbd, 0xc0, 0x46, 0x50, 0x08, 0x00, 0x20, 0x8c, 0x0a, 0x00, 0x20, + 0xc8, 0x0c, 0x00, 0x20, 0x04, 0x0f, 0x00, 0x20, 0x14, 0x06, 0x00, 0x20, + 0x10, 0xb5, 0x64, 0x38, 0xff, 0xf7, 0x46, 0xfc, 0x10, 0xbd, 0x70, 0x47, + 0x10, 0xb5, 0x04, 0x00, 0x02, 0xf0, 0x7a, 0xfe, 0x20, 0x00, 0x10, 0xbd, + 0x70, 0xb5, 0x0d, 0x00, 0x04, 0x1d, 0x02, 0x21, 0x20, 0x00, 0x00, 0xf0, + 0xef, 0xfd, 0x0c, 0x21, 0x20, 0x00, 0x00, 0xf0, 0xeb, 0xfd, 0x29, 0x00, + 0x0a, 0x20, 0x00, 0xf0, 0x25, 0xff, 0x56, 0x22, 0xff, 0x32, 0x00, 0x23, + 0x90, 0x42, 0x04, 0xd1, 0x10, 0x21, 0x20, 0x00, 0x00, 0xf0, 0xde, 0xfd, + 0x01, 0x23, 0x18, 0x00, 0x70, 0xbd, 0x10, 0xb5, 0x01, 0x21, 0x04, 0x00, + 0xff, 0xf7, 0xe0, 0xff, 0x00, 0x28, 0x04, 0xd0, 0x20, 0x1d, 0x05, 0x21, + 0x00, 0xf0, 0xd0, 0xfd, 0x01, 0x20, 0x10, 0xbd, 0x70, 0xb5, 0x04, 0x21, + 0x04, 0x00, 0xff, 0xf7, 0xd3, 0xff, 0x00, 0x28, 0x17, 0xd0, 0x04, 0x34, + 0x05, 0x21, 0x20, 0x00, 0x9a, 0x26, 0x00, 0xf0, 0xc1, 0xfd, 0xff, 0x36, + 0x00, 0xf0, 0xc8, 0xfe, 0x01, 0x3e, 0x05, 0x00, 0x00, 0x2e, 0xf9, 0xd1, + 0x09, 0x21, 0x20, 0x00, 0x00, 0xf0, 0xb6, 0xfd, 0x02, 0x21, 0x20, 0x00, + 0x00, 0xf0, 0xb2, 0xfd, 0x28, 0x00, 0x45, 0x1e, 0xa8, 0x41, 0x70, 0xbd, + 0xf7, 0xb5, 0x05, 0x00, 0x0e, 0x21, 0x2e, 0x1d, 0xff, 0xf7, 0xb2, 0xff, + 0x05, 0x21, 0x30, 0x00, 0x00, 0xf0, 0xa4, 0xfd, 0x40, 0x20, 0x00, 0xf0, + 0xbb, 0xff, 0x09, 0x21, 0x30, 0x00, 0x00, 0xf0, 0x9d, 0xfd, 0x0c, 0x21, + 0x28, 0x00, 0xff, 0xf7, 0xa3, 0xff, 0x08, 0x27, 0x00, 0x24, 0x05, 0x21, + 0x30, 0x00, 0x00, 0xf0, 0x93, 0xfd, 0x00, 0x21, 0x04, 0x20, 0x00, 0xf0, + 0x5b, 0xff, 0x24, 0x09, 0x00, 0x07, 0x09, 0x21, 0x04, 0x43, 0x30, 0x00, + 0x00, 0xf0, 0x88, 0xfd, 0x01, 0x3f, 0x02, 0x21, 0x30, 0x00, 0x00, 0xf0, + 0x83, 0xfd, 0x00, 0x2f, 0xe9, 0xd1, 0x63, 0x03, 0x5b, 0x0d, 0x6e, 0x2b, + 0x3a, 0xd1, 0x01, 0x21, 0xe2, 0x0c, 0xd2, 0xb2, 0xaa, 0x60, 0xef, 0x60, + 0x08, 0x00, 0xeb, 0x68, 0x98, 0x40, 0x82, 0x42, 0x02, 0xdb, 0x01, 0x33, + 0xeb, 0x60, 0xf7, 0xe7, 0xff, 0x23, 0x00, 0x27, 0x1c, 0x40, 0x2c, 0x61, + 0x01, 0x93, 0xab, 0x68, 0xbb, 0x42, 0x25, 0xdd, 0x08, 0x23, 0x00, 0x24, + 0x00, 0x93, 0x05, 0x21, 0x30, 0x00, 0x00, 0xf0, 0x61, 0xfd, 0x00, 0x21, + 0x04, 0x20, 0x00, 0xf0, 0x29, 0xff, 0x24, 0x09, 0x00, 0x07, 0x09, 0x21, + 0x04, 0x43, 0x30, 0x00, 0x00, 0xf0, 0x56, 0xfd, 0x02, 0x21, 0x30, 0x00, + 0x00, 0xf0, 0x52, 0xfd, 0x00, 0x9b, 0x01, 0x3b, 0x00, 0x93, 0x00, 0x2b, + 0xe7, 0xd1, 0x01, 0x9a, 0xe3, 0x0c, 0x13, 0x40, 0x84, 0x2b, 0x03, 0xd1, + 0x64, 0x03, 0x64, 0x0d, 0x6e, 0x2c, 0x03, 0xd0, 0x01, 0x37, 0xd6, 0xe7, + 0x01, 0x27, 0x7f, 0x42, 0x38, 0x00, 0xfe, 0xbd, 0x70, 0xb5, 0x04, 0x00, + 0x0d, 0x00, 0x00, 0xf0, 0xbb, 0xfd, 0x00, 0x23, 0x20, 0x1d, 0x23, 0x71, + 0x01, 0x21, 0x00, 0xf0, 0x33, 0xfd, 0x00, 0x2d, 0x05, 0xd0, 0x20, 0x00, + 0xff, 0xf7, 0x53, 0xff, 0x64, 0x20, 0x01, 0xf0, 0x57, 0xfa, 0x20, 0x00, + 0xff, 0xf7, 0x5a, 0xff, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x70, 0xbd, + 0x20, 0x00, 0xff, 0xf7, 0x73, 0xff, 0x60, 0x61, 0x43, 0x1c, 0xf7, 0xd0, + 0x01, 0x23, 0x5b, 0x42, 0xa3, 0x61, 0x01, 0x20, 0xf3, 0xe7, 0x70, 0xb5, + 0x04, 0x00, 0xa3, 0x69, 0x0d, 0x00, 0x01, 0x20, 0x8b, 0x42, 0x19, 0xd0, + 0x0e, 0x21, 0x20, 0x00, 0xff, 0xf7, 0x18, 0xff, 0x00, 0x28, 0x13, 0xd0, + 0x26, 0x1d, 0x05, 0x21, 0x30, 0x00, 0x00, 0xf0, 0x07, 0xfd, 0x63, 0x69, + 0x20, 0x69, 0x59, 0x1c, 0x81, 0x40, 0xe3, 0x68, 0x29, 0x43, 0xc0, 0x18, + 0x00, 0xf0, 0x8e, 0xfe, 0x09, 0x21, 0x30, 0x00, 0x00, 0xf0, 0xfa, 0xfc, + 0x01, 0x20, 0xa5, 0x61, 0x70, 0xbd, 0x73, 0xb5, 0x01, 0x91, 0x00, 0x21, + 0x05, 0x00, 0x16, 0x00, 0x1c, 0x00, 0xff, 0xf7, 0xd6, 0xff, 0x00, 0x28, + 0x02, 0xd1, 0x01, 0x20, 0x40, 0x42, 0x76, 0xbd, 0x0c, 0x21, 0x28, 0x00, + 0xff, 0xf7, 0xf0, 0xfe, 0x00, 0x28, 0xf6, 0xd0, 0x05, 0x21, 0x28, 0x1d, + 0x00, 0xf0, 0xe0, 0xfc, 0x01, 0x9b, 0x04, 0x21, 0x9a, 0x00, 0x03, 0x23, + 0x01, 0xa8, 0x13, 0x43, 0x01, 0x93, 0x00, 0xf0, 0x19, 0xff, 0xa1, 0x00, + 0x30, 0x00, 0x00, 0xf0, 0x15, 0xff, 0x02, 0x20, 0x00, 0xf0, 0xea, 0xfe, + 0x20, 0x00, 0xe2, 0xe7, 0xf7, 0xb5, 0x01, 0x91, 0x00, 0x21, 0x05, 0x00, + 0x16, 0x00, 0x1c, 0x00, 0xff, 0xf7, 0xad, 0xff, 0x00, 0x28, 0x02, 0xd1, + 0x01, 0x20, 0x40, 0x42, 0xfe, 0xbd, 0x0c, 0x21, 0x28, 0x00, 0xff, 0xf7, + 0xc7, 0xfe, 0x00, 0x28, 0xf6, 0xd0, 0x2f, 0x1d, 0x05, 0x21, 0x38, 0x00, + 0x00, 0xf0, 0xb6, 0xfc, 0x01, 0x9b, 0x04, 0x21, 0x9a, 0x00, 0x03, 0x23, + 0x01, 0xa8, 0x13, 0x43, 0x01, 0x93, 0x00, 0xf0, 0xef, 0xfe, 0x01, 0x21, + 0x28, 0x00, 0xff, 0xf7, 0x90, 0xff, 0x00, 0x28, 0xe2, 0xd0, 0x0c, 0x21, + 0x28, 0x00, 0xff, 0xf7, 0xad, 0xfe, 0x00, 0x28, 0xdc, 0xd0, 0x05, 0x21, + 0x38, 0x00, 0x00, 0xf0, 0x9d, 0xfc, 0x04, 0x21, 0x30, 0x00, 0x00, 0xf0, + 0x2b, 0xff, 0x30, 0x00, 0xa1, 0x00, 0x00, 0xf0, 0x27, 0xff, 0x20, 0x00, + 0xd0, 0xe7, 0x00, 0x00, 0x06, 0x4b, 0x07, 0x48, 0x08, 0x33, 0x10, 0xb5, + 0x03, 0x60, 0x01, 0x23, 0x05, 0x4a, 0x5b, 0x42, 0x05, 0x49, 0x43, 0x61, + 0x02, 0xf0, 0x0c, 0xfd, 0x10, 0xbd, 0xc0, 0x46, 0x44, 0x64, 0x00, 0x00, + 0x40, 0x11, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0xe3, 0x2c, 0x00, 0x00, + 0x37, 0xb5, 0x0c, 0x4d, 0x00, 0x21, 0x28, 0x00, 0xff, 0xf7, 0x38, 0xff, + 0x00, 0x28, 0x10, 0xd0, 0x00, 0x24, 0x01, 0x23, 0x01, 0xaa, 0x21, 0x00, + 0x28, 0x00, 0x01, 0x94, 0xff, 0xf7, 0x75, 0xff, 0x01, 0x21, 0x1f, 0x20, + 0x01, 0xf0, 0x16, 0xfb, 0x1f, 0x20, 0x21, 0x00, 0x01, 0xf0, 0x5e, 0xfb, + 0x01, 0x20, 0x3e, 0xbd, 0x40, 0x11, 0x00, 0x20, 0x0b, 0x68, 0x37, 0xb5, + 0x15, 0x00, 0x00, 0x2b, 0x2a, 0xd0, 0x17, 0x4c, 0x13, 0x00, 0x20, 0x00, + 0x0a, 0x00, 0x00, 0x21, 0xff, 0xf7, 0x5d, 0xff, 0x85, 0x42, 0x21, 0xd1, + 0x01, 0x21, 0x1f, 0x20, 0x01, 0xf0, 0x48, 0xfb, 0x00, 0x21, 0x1f, 0x20, + 0x01, 0xf0, 0x44, 0xfb, 0x01, 0xf0, 0x3e, 0xf9, 0x05, 0x00, 0x01, 0xf0, + 0x3b, 0xf9, 0x0d, 0x4b, 0x40, 0x1b, 0x98, 0x42, 0x10, 0xd8, 0x01, 0x23, + 0x01, 0xaa, 0x00, 0x21, 0x20, 0x00, 0xff, 0xf7, 0x6d, 0xff, 0x01, 0x9b, + 0x00, 0x2b, 0xf0, 0xd1, 0x01, 0x33, 0x01, 0xaa, 0x19, 0x00, 0x20, 0x00, + 0xff, 0xf7, 0x64, 0xff, 0x01, 0x98, 0x3e, 0xbd, 0x01, 0x20, 0x40, 0x42, + 0xfb, 0xe7, 0xc0, 0x46, 0x40, 0x11, 0x00, 0x20, 0x87, 0x13, 0x00, 0x00, + 0x10, 0xb5, 0x13, 0x00, 0x14, 0x00, 0x0a, 0x48, 0x0a, 0x00, 0x00, 0x21, + 0xff, 0xf7, 0x29, 0xff, 0x84, 0x42, 0x09, 0xd1, 0x01, 0x21, 0x1f, 0x20, + 0x01, 0xf0, 0x14, 0xfb, 0x00, 0x21, 0x1f, 0x20, 0x01, 0xf0, 0x10, 0xfb, + 0x20, 0x00, 0x10, 0xbd, 0x01, 0x24, 0x64, 0x42, 0xfa, 0xe7, 0xc0, 0x46, + 0x40, 0x11, 0x00, 0x20, 0x10, 0xb5, 0x1c, 0x00, 0x02, 0x48, 0xff, 0xf7, + 0x3b, 0xff, 0x20, 0x00, 0x10, 0xbd, 0xc0, 0x46, 0x40, 0x11, 0x00, 0x20, + 0xf0, 0xb5, 0x17, 0x4c, 0x43, 0x1d, 0xa5, 0x44, 0x14, 0x00, 0xda, 0x7f, + 0x0d, 0x00, 0x00, 0x23, 0xff, 0x2a, 0x08, 0xd0, 0xff, 0x21, 0x83, 0x69, + 0x09, 0x04, 0x1b, 0x04, 0x12, 0x06, 0x0b, 0x40, 0x13, 0x43, 0x04, 0x22, + 0x13, 0x43, 0x22, 0x00, 0x29, 0x00, 0x02, 0xa8, 0x00, 0x93, 0x01, 0x94, + 0xe6, 0x1c, 0x02, 0xf0, 0x49, 0xfd, 0x0b, 0x4f, 0xb6, 0x08, 0xb2, 0x1c, + 0x69, 0x46, 0x38, 0x00, 0xff, 0xf7, 0x82, 0xff, 0x33, 0x00, 0x02, 0xaa, + 0x02, 0x21, 0x38, 0x00, 0xff, 0xf7, 0xce, 0xff, 0x22, 0x00, 0x02, 0xa9, + 0x28, 0x00, 0x02, 0xf0, 0x37, 0xfd, 0x03, 0x4b, 0x9d, 0x44, 0xf0, 0xbd, + 0xfc, 0xfb, 0xff, 0xff, 0x5c, 0x11, 0x00, 0x20, 0x04, 0x04, 0x00, 0x00, + 0x13, 0xb5, 0x03, 0x7f, 0x04, 0x00, 0x00, 0x2b, 0x37, 0xd1, 0x43, 0x77, + 0x83, 0x77, 0x03, 0x62, 0x01, 0x33, 0x03, 0x77, 0x80, 0x68, 0x43, 0x1c, + 0x30, 0xd1, 0x04, 0x21, 0x54, 0x30, 0xff, 0xf7, 0x05, 0xfa, 0xe0, 0x68, + 0x43, 0x1c, 0x35, 0xd1, 0x00, 0x21, 0x55, 0x30, 0xff, 0xf7, 0xfe, 0xf9, + 0x20, 0x69, 0x43, 0x1c, 0x3a, 0xd1, 0x04, 0x21, 0x53, 0x30, 0xff, 0xf7, + 0xf7, 0xf9, 0x60, 0x69, 0x43, 0x1c, 0x05, 0xd0, 0x0e, 0x28, 0x3d, 0xdc, + 0x8c, 0x30, 0x05, 0x21, 0xff, 0xf7, 0xa4, 0xfd, 0x63, 0x1d, 0xda, 0x7f, + 0xa1, 0x69, 0x00, 0x23, 0xff, 0x2a, 0x07, 0xd0, 0xff, 0x20, 0x0b, 0x04, + 0x00, 0x04, 0x12, 0x06, 0x03, 0x40, 0x13, 0x43, 0x01, 0x22, 0x13, 0x43, + 0x01, 0x91, 0x02, 0x22, 0x69, 0x46, 0x17, 0x48, 0x00, 0x93, 0xff, 0xf7, + 0x31, 0xff, 0x13, 0xbd, 0x0e, 0x28, 0x04, 0xdc, 0x8c, 0x30, 0x05, 0x21, + 0xff, 0xf7, 0x88, 0xfd, 0xcb, 0xe7, 0x03, 0x00, 0x0f, 0x3b, 0xa3, 0x60, + 0x76, 0x30, 0xf6, 0xe7, 0x0e, 0x28, 0x04, 0xdc, 0x8c, 0x30, 0x00, 0x21, + 0xff, 0xf7, 0x7c, 0xfd, 0xc6, 0xe7, 0x03, 0x00, 0x0f, 0x3b, 0xe3, 0x60, + 0x76, 0x30, 0xf6, 0xe7, 0x0e, 0x28, 0x04, 0xdc, 0x8c, 0x30, 0x05, 0x21, + 0xff, 0xf7, 0x70, 0xfd, 0xc1, 0xe7, 0x03, 0x00, 0x0f, 0x3b, 0x23, 0x61, + 0x76, 0x30, 0xf6, 0xe7, 0x03, 0x00, 0x0f, 0x3b, 0x63, 0x61, 0x76, 0x30, + 0xbd, 0xe7, 0xc0, 0x46, 0x5c, 0x11, 0x00, 0x20, 0x1f, 0xb5, 0x05, 0x30, + 0xc0, 0x7f, 0x00, 0x23, 0xff, 0x28, 0x07, 0xd0, 0xff, 0x23, 0x09, 0x04, + 0x1b, 0x04, 0x19, 0x40, 0x02, 0x23, 0x00, 0x06, 0x0b, 0x43, 0x03, 0x43, + 0x00, 0x93, 0x00, 0x23, 0x52, 0x00, 0x01, 0x92, 0x69, 0x46, 0x04, 0x22, + 0x03, 0x48, 0x02, 0x93, 0x03, 0x93, 0xff, 0xf7, 0xeb, 0xfe, 0x05, 0xb0, + 0x00, 0xbd, 0xc0, 0x46, 0x5c, 0x11, 0x00, 0x20, 0x1f, 0xb5, 0x14, 0x00, + 0x24, 0x0a, 0xe4, 0xb2, 0xd3, 0xb2, 0x0a, 0x00, 0x61, 0x42, 0x4c, 0x41, + 0x01, 0x68, 0xe4, 0xb2, 0x91, 0x42, 0x05, 0xd1, 0x41, 0x79, 0xa1, 0x42, + 0x02, 0xd1, 0x01, 0x79, 0x99, 0x42, 0x06, 0xd0, 0x02, 0x60, 0x03, 0x71, + 0x44, 0x71, 0x00, 0x94, 0x81, 0x69, 0xff, 0xf7, 0xc9, 0xff, 0x1f, 0xbd, + 0x10, 0xb5, 0x04, 0x00, 0xff, 0xf7, 0x5a, 0xff, 0x02, 0x4b, 0x20, 0x00, + 0x06, 0xcb, 0xff, 0xf7, 0xdd, 0xff, 0x10, 0xbd, 0x50, 0x12, 0x00, 0x20, + 0x07, 0xb5, 0x43, 0x7f, 0x00, 0x91, 0x01, 0x92, 0x00, 0x2b, 0x07, 0xd0, + 0x9a, 0x07, 0x0a, 0xd5, 0xef, 0xf3, 0x10, 0x83, 0x5a, 0x42, 0x53, 0x41, + 0x83, 0x77, 0x72, 0xb6, 0x00, 0x99, 0x01, 0x9a, 0xff, 0xf7, 0xc8, 0xff, + 0x07, 0xbd, 0xdb, 0x07, 0xf8, 0xd5, 0x03, 0x6a, 0x01, 0x4a, 0x9b, 0xb2, + 0x93, 0x60, 0xf3, 0xe7, 0x00, 0x18, 0x00, 0x40, 0x43, 0x7f, 0x00, 0x2b, + 0x05, 0xd0, 0x9a, 0x07, 0x04, 0xd5, 0x83, 0x7f, 0x00, 0x2b, 0x00, 0xd0, + 0x62, 0xb6, 0x70, 0x47, 0xdb, 0x07, 0xfc, 0xd5, 0x03, 0x6a, 0x02, 0x4a, + 0x9b, 0xb2, 0xd3, 0x60, 0xf7, 0xe7, 0xc0, 0x46, 0x00, 0x18, 0x00, 0x40, + 0x13, 0xb5, 0x6b, 0x46, 0xdc, 0x1d, 0xd9, 0x71, 0x01, 0x22, 0x21, 0x00, + 0xff, 0xf7, 0xe4, 0xfe, 0x20, 0x78, 0x16, 0xbd, 0x31, 0x4a, 0x32, 0x4b, + 0x30, 0xb5, 0x13, 0x60, 0x00, 0x23, 0x11, 0x21, 0x01, 0x20, 0x02, 0x24, + 0x14, 0x25, 0x53, 0x71, 0x13, 0x71, 0x2e, 0x4a, 0x91, 0x60, 0x04, 0x31, + 0xd1, 0x60, 0x03, 0x39, 0x11, 0x61, 0x09, 0x18, 0x50, 0x71, 0x13, 0x77, + 0x13, 0x60, 0x13, 0x71, 0x90, 0x61, 0x51, 0x61, 0x0e, 0x39, 0x05, 0x32, + 0xd1, 0x77, 0x27, 0x4a, 0x13, 0x60, 0x50, 0x71, 0x13, 0x71, 0x13, 0x77, + 0x95, 0x60, 0x94, 0x61, 0xd3, 0x60, 0x10, 0x61, 0x54, 0x61, 0x52, 0x18, + 0xd1, 0x77, 0x22, 0x4a, 0x24, 0x18, 0x13, 0x60, 0x50, 0x71, 0x13, 0x71, + 0x13, 0x77, 0x94, 0x61, 0x94, 0x60, 0x04, 0x34, 0xd4, 0x60, 0x03, 0x3c, + 0x14, 0x61, 0x51, 0x61, 0x52, 0x18, 0xd1, 0x77, 0x1b, 0x4a, 0x94, 0x61, + 0x02, 0x34, 0x94, 0x60, 0x02, 0x34, 0xd4, 0x60, 0x24, 0x18, 0x14, 0x61, + 0x24, 0x18, 0x13, 0x60, 0x50, 0x71, 0x13, 0x71, 0x13, 0x77, 0x54, 0x61, + 0x52, 0x18, 0xd1, 0x77, 0x14, 0x4a, 0x24, 0x18, 0x94, 0x60, 0x24, 0x18, + 0xd4, 0x60, 0x24, 0x18, 0x14, 0x61, 0x24, 0x18, 0x13, 0x60, 0x50, 0x71, + 0x13, 0x71, 0x13, 0x77, 0x91, 0x61, 0x54, 0x61, 0x52, 0x18, 0xd1, 0x77, + 0x0d, 0x4a, 0x13, 0x60, 0x50, 0x71, 0x13, 0x71, 0x13, 0x77, 0x93, 0x61, + 0x01, 0x3b, 0x93, 0x60, 0xd3, 0x60, 0x13, 0x61, 0x53, 0x61, 0x52, 0x18, + 0xd1, 0x77, 0x30, 0xbd, 0x50, 0x12, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, + 0x88, 0x11, 0x00, 0x20, 0xb0, 0x11, 0x00, 0x20, 0xd8, 0x11, 0x00, 0x20, + 0x00, 0x12, 0x00, 0x20, 0x28, 0x12, 0x00, 0x20, 0x60, 0x11, 0x00, 0x20, + 0x01, 0x20, 0x70, 0x47, 0x10, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, + 0x98, 0x47, 0x10, 0xbd, 0x13, 0x04, 0x00, 0x00, 0x8d, 0x23, 0x9b, 0x00, + 0xc3, 0x18, 0x59, 0x68, 0x9a, 0x68, 0x91, 0x42, 0x04, 0xdb, 0x5a, 0x68, + 0x98, 0x68, 0x80, 0x1a, 0xff, 0x30, 0x70, 0x47, 0x98, 0x68, 0x5b, 0x68, + 0xc0, 0x1a, 0x01, 0x38, 0xf9, 0xe7, 0x03, 0x00, 0xfc, 0x33, 0x99, 0x6b, + 0x5a, 0x6b, 0x91, 0x42, 0x03, 0xd0, 0x9b, 0x6b, 0x30, 0x30, 0xc0, 0x5c, + 0x70, 0x47, 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, 0x03, 0x68, 0x10, 0xb5, + 0x1b, 0x69, 0x04, 0x00, 0x98, 0x47, 0x00, 0x28, 0x0d, 0xd0, 0x23, 0x00, + 0xfc, 0x33, 0x99, 0x6b, 0x5a, 0x6b, 0x91, 0x42, 0x07, 0xd0, 0x9a, 0x6b, + 0x30, 0x34, 0xa0, 0x5c, 0x9a, 0x6b, 0x01, 0x32, 0xd2, 0xb2, 0x9a, 0x63, + 0x10, 0xbd, 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, 0x90, 0x23, 0x07, 0xb5, + 0x9b, 0x00, 0xc2, 0x5c, 0x00, 0x23, 0xff, 0x2a, 0x08, 0xd0, 0x03, 0x69, + 0xff, 0x20, 0x1b, 0x04, 0x00, 0x04, 0x12, 0x06, 0x03, 0x40, 0x13, 0x43, + 0x07, 0x22, 0x13, 0x43, 0x01, 0x91, 0x02, 0x22, 0x69, 0x46, 0x03, 0x48, + 0x00, 0x93, 0xff, 0xf7, 0xbb, 0xfd, 0x01, 0x20, 0x0e, 0xbd, 0xc0, 0x46, + 0x5c, 0x11, 0x00, 0x20, 0xf0, 0xb5, 0x07, 0x00, 0x2d, 0x4c, 0xfc, 0x37, + 0xa5, 0x44, 0x7c, 0x6b, 0xbb, 0x6b, 0x05, 0x00, 0xe4, 0x1a, 0x01, 0xd5, + 0x01, 0x34, 0xff, 0x34, 0x26, 0x1e, 0x4b, 0xd1, 0x90, 0x23, 0x9b, 0x00, + 0xea, 0x5c, 0x23, 0x00, 0xff, 0x2a, 0x08, 0xd0, 0xff, 0x21, 0x2b, 0x69, + 0x09, 0x04, 0x1b, 0x04, 0x12, 0x06, 0x0b, 0x40, 0x13, 0x43, 0x06, 0x22, + 0x13, 0x43, 0x01, 0x22, 0x69, 0x46, 0x20, 0x48, 0x00, 0x93, 0xff, 0xf7, + 0x93, 0xfd, 0x06, 0x1e, 0x34, 0xdd, 0x90, 0x23, 0x9b, 0x00, 0xea, 0x5c, + 0x00, 0x23, 0xff, 0x2a, 0x08, 0xd0, 0xff, 0x21, 0x2b, 0x69, 0x09, 0x04, + 0x1b, 0x04, 0x12, 0x06, 0x0b, 0x40, 0x13, 0x43, 0x05, 0x22, 0x13, 0x43, + 0x02, 0x22, 0x69, 0x46, 0x14, 0x48, 0x00, 0x93, 0x01, 0x96, 0xff, 0xf7, + 0x7b, 0xfd, 0x03, 0x21, 0xc2, 0x1c, 0xd3, 0x17, 0x0b, 0x40, 0x9b, 0x18, + 0x9b, 0x10, 0x02, 0xaa, 0x06, 0x00, 0x01, 0x33, 0x01, 0x39, 0x0d, 0x48, + 0xff, 0xf7, 0xc0, 0xfd, 0xff, 0x22, 0x30, 0x35, 0xb4, 0x42, 0x0d, 0xda, + 0x7b, 0x6b, 0xb9, 0x6b, 0x01, 0x33, 0x13, 0x40, 0x8b, 0x42, 0x05, 0xd0, + 0x20, 0x00, 0x68, 0x44, 0x79, 0x6b, 0x00, 0x7a, 0x68, 0x54, 0x7b, 0x63, + 0x01, 0x34, 0xef, 0xe7, 0x30, 0x00, 0x03, 0x4b, 0x9d, 0x44, 0xf0, 0xbd, + 0xfc, 0xfb, 0xff, 0xff, 0x5c, 0x11, 0x00, 0x20, 0x04, 0x04, 0x00, 0x00, + 0x90, 0x23, 0x10, 0xb5, 0x11, 0x4c, 0x9b, 0x00, 0xa5, 0x44, 0x14, 0x00, + 0xc2, 0x5c, 0x00, 0x23, 0xff, 0x2a, 0x08, 0xd0, 0x03, 0x69, 0xff, 0x20, + 0x1b, 0x04, 0x00, 0x04, 0x12, 0x06, 0x03, 0x40, 0x13, 0x43, 0x08, 0x22, + 0x13, 0x43, 0x22, 0x00, 0x02, 0xa8, 0x00, 0x93, 0x01, 0x94, 0x02, 0xf0, + 0xf9, 0xfa, 0xe2, 0x1c, 0x92, 0x08, 0x02, 0x32, 0x69, 0x46, 0x05, 0x48, + 0xff, 0xf7, 0x32, 0xfd, 0x20, 0x00, 0x80, 0x23, 0xdb, 0x00, 0x9d, 0x44, + 0x10, 0xbd, 0xc0, 0x46, 0x00, 0xfc, 0xff, 0xff, 0x5c, 0x11, 0x00, 0x20, + 0x8d, 0x23, 0x9b, 0x00, 0x07, 0xb5, 0xc2, 0x18, 0x53, 0x68, 0x91, 0x68, + 0x5b, 0x1a, 0x01, 0xd5, 0x01, 0x33, 0xff, 0x33, 0x00, 0x2b, 0xf7, 0xd1, + 0x90, 0x22, 0x92, 0x00, 0x81, 0x5c, 0xff, 0x29, 0x08, 0xd0, 0xff, 0x22, + 0x03, 0x69, 0x12, 0x04, 0x1b, 0x04, 0x13, 0x40, 0x0a, 0x06, 0x1a, 0x43, + 0x09, 0x23, 0x13, 0x43, 0x01, 0x22, 0x01, 0xa9, 0x02, 0x48, 0x01, 0x93, + 0xff, 0xf7, 0x08, 0xfd, 0x07, 0xbd, 0xc0, 0x46, 0x5c, 0x11, 0x00, 0x20, + 0xf7, 0xb5, 0x01, 0x93, 0xfa, 0x23, 0x80, 0x26, 0x00, 0x25, 0x04, 0x00, + 0x9b, 0x00, 0x83, 0x60, 0x17, 0x4b, 0x76, 0x00, 0x08, 0x33, 0x0f, 0x00, + 0x45, 0x60, 0x29, 0x00, 0x00, 0x92, 0x03, 0x60, 0x32, 0x00, 0x30, 0x30, + 0x02, 0xf0, 0xb9, 0xfa, 0x23, 0x00, 0x20, 0x00, 0xfc, 0x33, 0x39, 0x30, + 0x5d, 0x63, 0x32, 0x00, 0x9d, 0x63, 0x29, 0x00, 0xff, 0x30, 0x02, 0xf0, + 0xae, 0xfa, 0x8d, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x5d, 0x60, 0x9d, 0x60, + 0x00, 0x9b, 0x06, 0x22, 0x63, 0x61, 0x01, 0x9b, 0x27, 0x61, 0xa3, 0x61, + 0x08, 0x9b, 0x20, 0x00, 0xe3, 0x61, 0x09, 0x9b, 0x23, 0x62, 0x0a, 0x9b, + 0x63, 0x62, 0x0b, 0x9b, 0xa3, 0x62, 0x90, 0x23, 0x9b, 0x00, 0xe2, 0x54, + 0xfe, 0xbd, 0xc0, 0x46, 0x54, 0x64, 0x00, 0x00, 0x37, 0xb5, 0x05, 0x00, + 0x14, 0x00, 0x4b, 0x1c, 0x21, 0xd1, 0x05, 0x31, 0x4f, 0x20, 0xfe, 0xf7, + 0x69, 0xff, 0x63, 0x1c, 0x25, 0xd1, 0x00, 0x21, 0x50, 0x20, 0xfe, 0xf7, + 0x63, 0xff, 0x90, 0x23, 0x9b, 0x00, 0xea, 0x5c, 0x00, 0x23, 0xff, 0x2a, + 0x08, 0xd0, 0xff, 0x21, 0x2b, 0x69, 0x09, 0x04, 0x1b, 0x04, 0x12, 0x06, + 0x0b, 0x40, 0x13, 0x43, 0x01, 0x22, 0x13, 0x43, 0x00, 0x93, 0x00, 0x23, + 0x02, 0x22, 0x69, 0x46, 0x0c, 0x48, 0x01, 0x93, 0xff, 0xf7, 0xa4, 0xfc, + 0x37, 0xbd, 0x0e, 0x29, 0x05, 0xdc, 0x8c, 0x31, 0x08, 0x00, 0x04, 0x21, + 0xff, 0xf7, 0xfa, 0xfa, 0xd9, 0xe7, 0x76, 0x31, 0xf8, 0xe7, 0x20, 0x00, + 0x0e, 0x2c, 0x04, 0xdc, 0x8c, 0x30, 0x00, 0x21, 0xff, 0xf7, 0xf0, 0xfa, + 0xd5, 0xe7, 0x76, 0x30, 0xf9, 0xe7, 0xc0, 0x46, 0x5c, 0x11, 0x00, 0x20, + 0x1f, 0xb5, 0x90, 0x23, 0x9b, 0x00, 0xc4, 0x5c, 0x00, 0x23, 0xff, 0x2c, + 0x08, 0xd0, 0x03, 0x69, 0xff, 0x20, 0x1b, 0x04, 0x00, 0x04, 0x03, 0x40, + 0x02, 0x20, 0x24, 0x06, 0x23, 0x43, 0x03, 0x43, 0x02, 0x91, 0x03, 0x92, + 0x01, 0xa9, 0x03, 0x22, 0x02, 0x48, 0x01, 0x93, 0xff, 0xf7, 0x74, 0xfc, + 0x1f, 0xbd, 0xc0, 0x46, 0x5c, 0x11, 0x00, 0x20, 0x70, 0xb5, 0x0d, 0x00, + 0x16, 0x00, 0x04, 0x00, 0x82, 0x69, 0x41, 0x69, 0xff, 0xf7, 0x9e, 0xff, + 0x32, 0x00, 0x29, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xd7, 0xff, 0x70, 0xbd, + 0x90, 0x23, 0x07, 0xb5, 0x9b, 0x00, 0xc2, 0x5c, 0x00, 0x23, 0xff, 0x2a, + 0x08, 0xd0, 0xff, 0x21, 0x03, 0x69, 0x09, 0x04, 0x1b, 0x04, 0x12, 0x06, + 0x0b, 0x40, 0x13, 0x43, 0x03, 0x22, 0x13, 0x43, 0x01, 0x22, 0x01, 0xa9, + 0x02, 0x48, 0x01, 0x93, 0xff, 0xf7, 0x4c, 0xfc, 0x07, 0xbd, 0xc0, 0x46, + 0x5c, 0x11, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, 0xff, 0xf7, 0xe2, 0xff, + 0x22, 0x00, 0x00, 0x23, 0xfc, 0x32, 0x53, 0x63, 0x93, 0x63, 0x8d, 0x22, + 0x92, 0x00, 0xa4, 0x18, 0x63, 0x60, 0xa3, 0x60, 0x10, 0xbd, 0x00, 0x00, + 0x1f, 0xb5, 0x01, 0x24, 0x64, 0x42, 0x23, 0x00, 0x22, 0x00, 0x03, 0x94, + 0x02, 0x94, 0x01, 0x94, 0x00, 0x94, 0x00, 0x21, 0x30, 0x48, 0xff, 0xf7, + 0x27, 0xff, 0x03, 0x94, 0x02, 0x94, 0x01, 0x94, 0x00, 0x94, 0x10, 0x23, + 0x0f, 0x22, 0x01, 0x21, 0x2c, 0x48, 0xff, 0xf7, 0x1d, 0xff, 0x10, 0x23, + 0x01, 0x93, 0x1b, 0x19, 0x00, 0x93, 0x03, 0x94, 0x02, 0x94, 0x03, 0x33, + 0x11, 0x22, 0x02, 0x21, 0x27, 0x48, 0xff, 0xf7, 0x11, 0xff, 0x03, 0x94, + 0x02, 0x94, 0x01, 0x94, 0x00, 0x94, 0x14, 0x23, 0x13, 0x22, 0x03, 0x21, + 0x23, 0x48, 0xff, 0xf7, 0x07, 0xff, 0x11, 0x23, 0x03, 0x93, 0x01, 0x33, + 0x02, 0x93, 0x02, 0x33, 0x01, 0x93, 0x1b, 0x19, 0x00, 0x93, 0x15, 0x22, + 0x00, 0x23, 0x04, 0x21, 0x1d, 0x48, 0xff, 0xf7, 0xf9, 0xfe, 0x03, 0x94, + 0x02, 0x94, 0x01, 0x94, 0x00, 0x94, 0x02, 0x23, 0x01, 0x22, 0x05, 0x21, + 0x19, 0x48, 0xff, 0xf7, 0xef, 0xfe, 0x15, 0x23, 0x03, 0x93, 0x00, 0x23, + 0x02, 0x93, 0x02, 0x33, 0x01, 0x93, 0x1b, 0x19, 0x00, 0x93, 0x03, 0x22, + 0x03, 0x33, 0x06, 0x21, 0x13, 0x48, 0xff, 0xf7, 0xe1, 0xfe, 0x03, 0x94, + 0x02, 0x94, 0x01, 0x94, 0x00, 0x94, 0x06, 0x23, 0x05, 0x22, 0x07, 0x21, + 0x0f, 0x48, 0xff, 0xf7, 0xd7, 0xfe, 0x03, 0x23, 0x03, 0x93, 0x01, 0x33, + 0x02, 0x93, 0x02, 0x33, 0x01, 0x93, 0x1b, 0x19, 0x00, 0x93, 0x03, 0x33, + 0x07, 0x22, 0x19, 0x00, 0x09, 0x48, 0xff, 0xf7, 0xc9, 0xfe, 0x1f, 0xbd, + 0x58, 0x12, 0x00, 0x20, 0x9c, 0x14, 0x00, 0x20, 0xe0, 0x16, 0x00, 0x20, + 0x24, 0x19, 0x00, 0x20, 0x68, 0x1b, 0x00, 0x20, 0xac, 0x1d, 0x00, 0x20, + 0xf0, 0x1f, 0x00, 0x20, 0x34, 0x22, 0x00, 0x20, 0x78, 0x24, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x00, 0x73, 0xb5, 0x0e, 0x00, 0x00, 0xf0, 0xc0, 0xfb, + 0x08, 0x4d, 0x28, 0x00, 0xff, 0xf7, 0x94, 0xfb, 0x04, 0x00, 0x01, 0x28, + 0x08, 0xd1, 0x00, 0x2e, 0x06, 0xd0, 0x03, 0x23, 0x02, 0x00, 0x01, 0xa9, + 0x28, 0x00, 0x01, 0x93, 0xff, 0xf7, 0xdc, 0xfb, 0x20, 0x00, 0x76, 0xbd, + 0x5c, 0x11, 0x00, 0x20, 0xf8, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x0c, 0x26, + 0x20, 0x78, 0xa8, 0x42, 0x01, 0xd1, 0x00, 0x20, 0xf8, 0xbd, 0x10, 0x28, + 0x16, 0xd8, 0x02, 0xf0, 0x81, 0xf8, 0x09, 0x18, 0x4c, 0x1d, 0x2b, 0x32, + 0x37, 0x3e, 0x43, 0x4a, 0x51, 0x59, 0x60, 0x65, 0x6c, 0x71, 0x4a, 0x00, + 0x06, 0x27, 0x01, 0x20, 0x01, 0x3f, 0x00, 0xf0, 0xc5, 0xf8, 0x00, 0x2f, + 0xf9, 0xd1, 0x01, 0x23, 0x23, 0x70, 0x01, 0x3e, 0x00, 0x2e, 0xe1, 0xd1, + 0x01, 0x20, 0x40, 0x42, 0xe2, 0xe7, 0x00, 0x20, 0x00, 0xf0, 0xb8, 0xf8, + 0x02, 0x23, 0xf3, 0xe7, 0x09, 0x2d, 0x01, 0xd8, 0x01, 0x2d, 0x04, 0xd1, + 0x01, 0x20, 0x00, 0xf0, 0xaf, 0xf8, 0x0a, 0x23, 0xea, 0xe7, 0x00, 0x20, + 0x00, 0xf0, 0xaa, 0xf8, 0x04, 0x23, 0xe5, 0xe7, 0x05, 0x2d, 0x04, 0xd1, + 0x00, 0x20, 0x00, 0xf0, 0xa3, 0xf8, 0x05, 0x23, 0xde, 0xe7, 0x01, 0x20, + 0x00, 0xf0, 0x9e, 0xf8, 0x06, 0x23, 0xd9, 0xe7, 0x07, 0x2d, 0x0b, 0xd1, + 0x00, 0x20, 0x00, 0xf0, 0x97, 0xf8, 0x25, 0x70, 0xd3, 0xe7, 0x01, 0x20, + 0x00, 0xf0, 0x92, 0xf8, 0x08, 0x23, 0xcd, 0xe7, 0x05, 0x2d, 0xe7, 0xd0, + 0x01, 0x20, 0x00, 0xf0, 0x8b, 0xf8, 0x09, 0x23, 0xc6, 0xe7, 0x02, 0x2d, + 0xec, 0xd0, 0x01, 0x20, 0x00, 0xf0, 0x84, 0xf8, 0x03, 0x23, 0xbf, 0xe7, + 0x28, 0x00, 0x01, 0x2d, 0xe5, 0xd0, 0x00, 0x20, 0x00, 0xf0, 0x7c, 0xf8, + 0x0b, 0x23, 0xb7, 0xe7, 0x0c, 0x2d, 0x04, 0xd1, 0x00, 0x20, 0x00, 0xf0, + 0x75, 0xf8, 0x0c, 0x23, 0xb0, 0xe7, 0x01, 0x20, 0x00, 0xf0, 0x70, 0xf8, + 0x0d, 0x23, 0xab, 0xe7, 0x0e, 0x2d, 0xd1, 0xd0, 0x01, 0x20, 0x00, 0xf0, + 0x69, 0xf8, 0x10, 0x23, 0xa4, 0xe7, 0x01, 0x20, 0x00, 0xf0, 0x64, 0xf8, + 0x0f, 0x23, 0x9f, 0xe7, 0x0c, 0x2d, 0xf3, 0xd1, 0xe6, 0xe7, 0x00, 0x00, + 0xf8, 0xb5, 0x01, 0x25, 0x01, 0x21, 0x1c, 0x20, 0x00, 0xf0, 0x26, 0xfe, + 0x01, 0x21, 0x1b, 0x20, 0x00, 0xf0, 0x22, 0xfe, 0x00, 0x21, 0x1d, 0x20, + 0x00, 0xf0, 0x1e, 0xfe, 0x01, 0x21, 0x1a, 0x20, 0x00, 0xf0, 0x1a, 0xfe, + 0xa9, 0x22, 0x28, 0x00, 0xa8, 0x23, 0x1f, 0x4c, 0x92, 0x00, 0xa2, 0x58, + 0xa3, 0x26, 0x90, 0x40, 0x2a, 0x00, 0x9b, 0x00, 0xe3, 0x56, 0x1c, 0x49, + 0xdb, 0x01, 0x5b, 0x18, 0x58, 0x61, 0xa2, 0x23, 0xb6, 0x00, 0xa0, 0x59, + 0x9b, 0x00, 0x82, 0x40, 0xe3, 0x56, 0x9d, 0x27, 0xdb, 0x01, 0x5b, 0x18, + 0x5a, 0x61, 0x9c, 0x22, 0x92, 0x00, 0xa3, 0x56, 0xbf, 0x00, 0xdb, 0x01, + 0x5b, 0x18, 0x29, 0x00, 0xe0, 0x59, 0x81, 0x40, 0x11, 0x48, 0x59, 0x61, + 0x00, 0xf0, 0x66, 0xfa, 0x10, 0x4b, 0x0f, 0x48, 0x06, 0xcb, 0x00, 0xf0, + 0x89, 0xfa, 0xa2, 0x23, 0x9b, 0x00, 0xe2, 0x56, 0xa3, 0x59, 0x0d, 0x49, + 0xd2, 0x01, 0x9b, 0x18, 0x5b, 0x18, 0x1a, 0x78, 0x00, 0x20, 0xaa, 0x43, + 0x1a, 0x70, 0x9c, 0x22, 0x92, 0x00, 0xa2, 0x56, 0xe3, 0x59, 0xd2, 0x01, + 0x9b, 0x18, 0x5b, 0x18, 0x1a, 0x78, 0xaa, 0x43, 0x1a, 0x70, 0xf8, 0xbd, + 0x88, 0x64, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0xe0, 0x26, 0x00, 0x20, + 0xbc, 0x26, 0x00, 0x20, 0x40, 0x44, 0x00, 0x41, 0xa8, 0x22, 0xf0, 0xb5, + 0x11, 0x4b, 0x92, 0x00, 0x9a, 0x56, 0x11, 0x49, 0xd2, 0x01, 0x52, 0x18, + 0xa9, 0x21, 0x89, 0x00, 0x5c, 0x58, 0x01, 0x21, 0xa1, 0x40, 0x00, 0x28, + 0x14, 0xd0, 0x91, 0x61, 0x01, 0x21, 0xa3, 0x20, 0x0d, 0x00, 0xa2, 0x24, + 0x80, 0x00, 0x1f, 0x58, 0xa4, 0x00, 0xbd, 0x40, 0x1a, 0x57, 0x07, 0x4e, + 0xd2, 0x01, 0x92, 0x19, 0x55, 0x61, 0x1a, 0x57, 0x1b, 0x58, 0xd2, 0x01, + 0x99, 0x40, 0x92, 0x19, 0x91, 0x61, 0xf0, 0xbd, 0x51, 0x61, 0xe9, 0xe7, + 0x88, 0x64, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0x9c, 0x22, 0xf0, 0xb5, + 0x16, 0x4b, 0x92, 0x00, 0x99, 0x56, 0x01, 0x22, 0x9d, 0x20, 0x14, 0x00, + 0x80, 0x00, 0x18, 0x58, 0x13, 0x4d, 0x84, 0x40, 0xc9, 0x01, 0x49, 0x19, + 0x4c, 0x61, 0xa2, 0x24, 0xa4, 0x00, 0x19, 0x57, 0xa3, 0x20, 0xc9, 0x01, + 0x2e, 0x00, 0x49, 0x19, 0x15, 0x00, 0x80, 0x00, 0x1f, 0x58, 0xbd, 0x40, + 0x4d, 0x61, 0x15, 0x00, 0x18, 0x58, 0x19, 0x57, 0x85, 0x40, 0xc9, 0x01, + 0x89, 0x19, 0x8d, 0x61, 0xae, 0x21, 0x89, 0x00, 0x59, 0x56, 0xc9, 0x01, + 0x89, 0x19, 0x08, 0x6a, 0xaf, 0x21, 0x89, 0x00, 0x5b, 0x58, 0x9a, 0x40, + 0x10, 0x40, 0x42, 0x1e, 0x90, 0x41, 0xf0, 0xbd, 0x88, 0x64, 0x00, 0x00, + 0x00, 0x44, 0x00, 0x41, 0x9d, 0x23, 0xf7, 0xb5, 0x00, 0x22, 0x9b, 0x00, + 0x06, 0x00, 0x9c, 0x46, 0x10, 0x00, 0x01, 0x24, 0x01, 0x91, 0xb2, 0x42, + 0x41, 0xda, 0x9c, 0x21, 0x20, 0x4b, 0x89, 0x00, 0x5d, 0x56, 0x20, 0x49, + 0xed, 0x01, 0x6d, 0x18, 0x61, 0x46, 0x27, 0x00, 0x59, 0x58, 0x8f, 0x40, + 0x01, 0x99, 0x21, 0x42, 0x31, 0xd0, 0xaf, 0x61, 0x75, 0x1e, 0x95, 0x42, + 0x2b, 0xd0, 0xa2, 0x25, 0xad, 0x00, 0x5d, 0x57, 0xa3, 0x21, 0x17, 0x4f, + 0xed, 0x01, 0xed, 0x19, 0x27, 0x00, 0x89, 0x00, 0x59, 0x58, 0x8f, 0x40, + 0x6f, 0x61, 0xa2, 0x25, 0xa3, 0x21, 0xad, 0x00, 0x5d, 0x57, 0x11, 0x4f, + 0x89, 0x00, 0xed, 0x01, 0xed, 0x19, 0x5f, 0x58, 0x21, 0x00, 0xb9, 0x40, + 0xa9, 0x61, 0xae, 0x25, 0xad, 0x00, 0x5d, 0x57, 0x0b, 0x4f, 0xed, 0x01, + 0xed, 0x19, 0xaf, 0x27, 0x21, 0x00, 0xbf, 0x00, 0xdb, 0x59, 0x2d, 0x6a, + 0x99, 0x40, 0x0d, 0x40, 0x6b, 0x1e, 0x9d, 0x41, 0x95, 0x40, 0x01, 0x9b, + 0x28, 0x43, 0x5b, 0x08, 0x01, 0x93, 0x01, 0x32, 0xbd, 0xe7, 0x6f, 0x61, + 0xcc, 0xe7, 0xfe, 0xbd, 0x88, 0x64, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x9d, 0x23, 0x9b, 0x00, 0xf7, 0xb5, 0x9c, 0x46, 0x00, 0x24, 0x01, 0x25, + 0x84, 0x42, 0x2e, 0xda, 0x9c, 0x22, 0x17, 0x4b, 0x92, 0x00, 0x9a, 0x56, + 0x16, 0x4e, 0xd2, 0x01, 0x92, 0x19, 0x66, 0x46, 0x2f, 0x00, 0x9e, 0x59, + 0xb7, 0x40, 0x29, 0x42, 0x1f, 0xd0, 0x97, 0x61, 0x42, 0x1e, 0xa2, 0x42, + 0x19, 0xd0, 0xa2, 0x22, 0x92, 0x00, 0x9a, 0x56, 0x0e, 0x4f, 0xd2, 0x01, + 0xd6, 0x19, 0xa3, 0x27, 0x01, 0x96, 0x2e, 0x00, 0xbf, 0x00, 0xda, 0x59, + 0x49, 0x08, 0x96, 0x40, 0x32, 0x00, 0x01, 0x9e, 0x72, 0x61, 0xa2, 0x22, + 0x92, 0x00, 0x9a, 0x56, 0x06, 0x4e, 0xd2, 0x01, 0x92, 0x19, 0x2e, 0x00, + 0xdb, 0x59, 0x9e, 0x40, 0x96, 0x61, 0x01, 0x34, 0xd0, 0xe7, 0x57, 0x61, + 0xde, 0xe7, 0xf7, 0xbd, 0x88, 0x64, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x9d, 0x23, 0xf7, 0xb5, 0x00, 0x22, 0x9b, 0x00, 0x01, 0x90, 0x9c, 0x46, + 0x10, 0x00, 0x01, 0x24, 0x00, 0x91, 0x01, 0x9b, 0x9a, 0x42, 0x3c, 0xda, + 0x9c, 0x25, 0x1e, 0x4b, 0xad, 0x00, 0x5d, 0x57, 0x1d, 0x4e, 0x67, 0x46, + 0xed, 0x01, 0xad, 0x19, 0x26, 0x00, 0xdf, 0x59, 0x00, 0x99, 0xbe, 0x40, + 0x21, 0x42, 0x2c, 0xd0, 0xae, 0x61, 0xa2, 0x21, 0x89, 0x00, 0x5d, 0x56, + 0x16, 0x4e, 0xed, 0x01, 0xad, 0x19, 0xa3, 0x26, 0x27, 0x00, 0xb6, 0x00, + 0x99, 0x59, 0x8f, 0x40, 0xa2, 0x21, 0x6f, 0x61, 0x89, 0x00, 0x5d, 0x56, + 0x10, 0x4f, 0xed, 0x01, 0xed, 0x19, 0x39, 0x00, 0x27, 0x00, 0x9e, 0x59, + 0xb7, 0x40, 0xaf, 0x26, 0xaf, 0x61, 0xae, 0x25, 0xb6, 0x00, 0xad, 0x00, + 0x5d, 0x57, 0x9b, 0x59, 0x26, 0x00, 0x9e, 0x40, 0xed, 0x01, 0x6d, 0x18, + 0x2d, 0x6a, 0x35, 0x40, 0x6b, 0x1e, 0x9d, 0x41, 0x95, 0x40, 0x00, 0x9b, + 0x28, 0x43, 0x5b, 0x08, 0x00, 0x93, 0x01, 0x32, 0xc1, 0xe7, 0x6e, 0x61, + 0xd1, 0xe7, 0xfe, 0xbd, 0x88, 0x64, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0xf8, 0xb5, 0x00, 0x21, 0x04, 0x00, 0x1a, 0x20, 0x00, 0xf0, 0xda, 0xfc, + 0x01, 0x23, 0xa2, 0x26, 0xa3, 0x25, 0x00, 0x21, 0x9c, 0x46, 0x0c, 0x4a, + 0xb6, 0x00, 0xad, 0x00, 0xa1, 0x42, 0x11, 0xda, 0x93, 0x57, 0x0a, 0x4f, + 0xdb, 0x01, 0xdb, 0x19, 0x67, 0x46, 0x50, 0x59, 0x01, 0x31, 0x87, 0x40, + 0x5f, 0x61, 0x93, 0x57, 0x05, 0x4f, 0xdb, 0x01, 0xdb, 0x19, 0x67, 0x46, + 0x50, 0x59, 0x87, 0x40, 0x9f, 0x61, 0xeb, 0xe7, 0xf8, 0xbd, 0xc0, 0x46, + 0x88, 0x64, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0xf8, 0xb5, 0xa2, 0x25, + 0x22, 0x4c, 0xad, 0x00, 0x63, 0x57, 0x22, 0x4a, 0xdb, 0x01, 0x9b, 0x18, + 0x01, 0x22, 0xa3, 0x26, 0x9c, 0x46, 0x17, 0x00, 0xb6, 0x00, 0xa3, 0x59, + 0x9f, 0x40, 0x63, 0x46, 0x5f, 0x61, 0x65, 0x57, 0xa3, 0x59, 0xed, 0x01, + 0x1b, 0x4e, 0x5b, 0x19, 0x9b, 0x19, 0x1d, 0x78, 0x15, 0x43, 0x1d, 0x70, + 0x9c, 0x23, 0x9b, 0x00, 0xe5, 0x56, 0x04, 0x33, 0xe3, 0x58, 0xed, 0x01, + 0x5b, 0x19, 0x9b, 0x19, 0x1d, 0x78, 0x46, 0x18, 0x2a, 0x43, 0x05, 0x00, + 0x1a, 0x70, 0xae, 0x42, 0x05, 0xd0, 0x29, 0x78, 0x11, 0x48, 0x00, 0xf0, + 0xf5, 0xf8, 0x01, 0x35, 0xf7, 0xe7, 0xa2, 0x23, 0x01, 0x21, 0x9b, 0x00, + 0xe2, 0x56, 0x04, 0x33, 0xe3, 0x58, 0x0b, 0x48, 0xd2, 0x01, 0x9b, 0x18, + 0x1b, 0x18, 0x1a, 0x78, 0x8a, 0x43, 0x1a, 0x70, 0x9c, 0x23, 0x9b, 0x00, + 0xe2, 0x56, 0x04, 0x33, 0xe3, 0x58, 0xd2, 0x01, 0x9b, 0x18, 0x1b, 0x18, + 0x1a, 0x78, 0x8a, 0x43, 0x1a, 0x70, 0xf8, 0xbd, 0x88, 0x64, 0x00, 0x00, + 0x00, 0x44, 0x00, 0x41, 0x40, 0x44, 0x00, 0x41, 0xe0, 0x26, 0x00, 0x20, + 0xf8, 0xb5, 0x05, 0x00, 0xa2, 0x20, 0x23, 0x4c, 0x80, 0x00, 0x23, 0x56, + 0x22, 0x4a, 0xdb, 0x01, 0x9b, 0x18, 0x01, 0x22, 0xa3, 0x26, 0x9c, 0x46, + 0x17, 0x00, 0xb6, 0x00, 0xa3, 0x59, 0x9f, 0x40, 0x63, 0x46, 0x5f, 0x61, + 0x20, 0x56, 0xa3, 0x59, 0xc0, 0x01, 0x1c, 0x4e, 0x1b, 0x18, 0x9b, 0x19, + 0x18, 0x78, 0x10, 0x43, 0x18, 0x70, 0xae, 0x23, 0x9b, 0x00, 0xe0, 0x56, + 0x04, 0x33, 0xe3, 0x58, 0xc0, 0x01, 0x1b, 0x18, 0x9b, 0x19, 0x18, 0x78, + 0x6e, 0x18, 0x02, 0x43, 0x1a, 0x70, 0xb5, 0x42, 0x06, 0xd0, 0x00, 0x21, + 0x12, 0x48, 0x00, 0xf0, 0xa5, 0xf8, 0x28, 0x70, 0x01, 0x35, 0xf6, 0xe7, + 0xa2, 0x23, 0x01, 0x21, 0x9b, 0x00, 0xe2, 0x56, 0x04, 0x33, 0xe3, 0x58, + 0x0b, 0x48, 0xd2, 0x01, 0x9b, 0x18, 0x1b, 0x18, 0x1a, 0x78, 0x8a, 0x43, + 0x1a, 0x70, 0xae, 0x23, 0x9b, 0x00, 0xe2, 0x56, 0x04, 0x33, 0xe3, 0x58, + 0xd2, 0x01, 0x9b, 0x18, 0x1b, 0x18, 0x1a, 0x78, 0x8a, 0x43, 0x1a, 0x70, + 0xf8, 0xbd, 0xc0, 0x46, 0x88, 0x64, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x40, 0x44, 0x00, 0x41, 0xe0, 0x26, 0x00, 0x20, 0x03, 0x4b, 0x04, 0x4a, + 0x1a, 0x60, 0x01, 0x22, 0x5a, 0x71, 0x00, 0x22, 0x1a, 0x71, 0x70, 0x47, + 0xbc, 0x26, 0x00, 0x20, 0x00, 0x1b, 0xb7, 0x00, 0x03, 0x7d, 0x00, 0x2b, + 0x04, 0xd1, 0x43, 0x75, 0x83, 0x75, 0x83, 0x61, 0x01, 0x33, 0x03, 0x75, + 0x70, 0x47, 0x7f, 0xb5, 0xc3, 0x68, 0x02, 0xad, 0x04, 0x00, 0x0e, 0x00, + 0x02, 0x91, 0x6a, 0x60, 0x8b, 0x42, 0x03, 0xd1, 0x02, 0x8a, 0xab, 0x88, + 0x9a, 0x42, 0x18, 0xd0, 0x20, 0x00, 0x06, 0x22, 0x29, 0x00, 0x0c, 0x30, + 0x01, 0xf0, 0x54, 0xfe, 0x20, 0x68, 0x00, 0xf0, 0x10, 0xfe, 0x6b, 0x79, + 0x22, 0x7a, 0xe1, 0x79, 0x00, 0x93, 0x20, 0x68, 0x00, 0x23, 0x00, 0xf0, + 0xa9, 0xfe, 0x20, 0x68, 0x29, 0x79, 0x32, 0x00, 0x00, 0xf0, 0xd4, 0xfd, + 0x20, 0x68, 0x00, 0xf0, 0xf6, 0xfd, 0x7f, 0xbd, 0x70, 0xb5, 0x18, 0x26, + 0x04, 0x00, 0xff, 0xf7, 0xcb, 0xff, 0x33, 0x00, 0x08, 0x21, 0x20, 0x79, + 0x0d, 0x4d, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0xf8, 0xfb, + 0x33, 0x00, 0x08, 0x21, 0xa0, 0x79, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, + 0x00, 0xf0, 0xf0, 0xfb, 0x08, 0x21, 0x60, 0x79, 0x46, 0x43, 0xad, 0x19, + 0x69, 0x56, 0x00, 0xf0, 0xe9, 0xfb, 0x04, 0x4b, 0x20, 0x00, 0x06, 0xcb, + 0xff, 0xf7, 0xb7, 0xff, 0x70, 0xbd, 0xc0, 0x46, 0x88, 0x64, 0x00, 0x00, + 0xfc, 0x26, 0x00, 0x20, 0x07, 0xb5, 0x43, 0x7d, 0x00, 0x91, 0x01, 0x92, + 0x00, 0x2b, 0x07, 0xd0, 0x9a, 0x07, 0x0a, 0xd5, 0xef, 0xf3, 0x10, 0x83, + 0x5a, 0x42, 0x53, 0x41, 0x83, 0x75, 0x72, 0xb6, 0x00, 0x99, 0x01, 0x9a, + 0xff, 0xf7, 0x9f, 0xff, 0x07, 0xbd, 0xdb, 0x07, 0xf8, 0xd5, 0x83, 0x69, + 0x01, 0x4a, 0x9b, 0xb2, 0x93, 0x60, 0xf3, 0xe7, 0x00, 0x18, 0x00, 0x40, + 0x10, 0xb5, 0x00, 0x68, 0x00, 0xf0, 0xc0, 0xfd, 0x10, 0xbd, 0x00, 0x00, + 0x10, 0x4a, 0x11, 0x4b, 0x11, 0x49, 0x13, 0x60, 0x00, 0x23, 0x53, 0x71, + 0x13, 0x71, 0x10, 0x4a, 0x10, 0x48, 0x11, 0x60, 0x10, 0x49, 0xd3, 0x60, + 0x91, 0x80, 0x09, 0x21, 0x91, 0x71, 0x06, 0x39, 0x53, 0x74, 0x13, 0x74, + 0x13, 0x75, 0xd3, 0x71, 0x11, 0x72, 0x0c, 0x4a, 0x10, 0x60, 0x0c, 0x48, + 0xd3, 0x60, 0x90, 0x80, 0x1b, 0x20, 0x53, 0x74, 0x13, 0x74, 0x13, 0x75, + 0x90, 0x71, 0xd3, 0x71, 0x11, 0x72, 0x70, 0x47, 0xfc, 0x26, 0x00, 0x20, + 0x00, 0x09, 0x3d, 0x00, 0x44, 0x29, 0x00, 0x20, 0xc4, 0x26, 0x00, 0x20, + 0x48, 0x29, 0x00, 0x20, 0x0a, 0x08, 0x00, 0x00, 0xe0, 0x26, 0x00, 0x20, + 0x1d, 0x1a, 0x00, 0x00, 0x0f, 0x23, 0x05, 0x4a, 0x89, 0xb2, 0x18, 0x40, + 0x09, 0x02, 0x04, 0x4b, 0x01, 0x43, 0x10, 0x43, 0x99, 0x60, 0x58, 0x60, + 0x70, 0x47, 0xc0, 0x46, 0x00, 0x07, 0x0b, 0x00, 0x00, 0x0c, 0x00, 0x40, + 0x10, 0xb5, 0x07, 0x21, 0x1e, 0x20, 0x00, 0xf0, 0x75, 0xfb, 0x01, 0x21, + 0x00, 0x20, 0xff, 0xf7, 0xe7, 0xff, 0xfa, 0x20, 0x80, 0x00, 0x00, 0xf0, + 0x73, 0xf9, 0x10, 0xbd, 0x10, 0xb5, 0x02, 0x48, 0x01, 0xf0, 0x49, 0xfb, + 0x10, 0xbd, 0xc0, 0x46, 0x04, 0x27, 0x00, 0x20, 0x13, 0xb5, 0x12, 0x49, + 0x12, 0x48, 0x00, 0xf0, 0x9f, 0xfc, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, + 0x9b, 0xfc, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, 0x97, 0xfc, 0x12, 0x49, + 0x12, 0x48, 0x00, 0xf0, 0x93, 0xfc, 0x12, 0x49, 0x12, 0x48, 0x00, 0xf0, + 0x8f, 0xfc, 0x12, 0x4c, 0x12, 0x49, 0x20, 0x00, 0x00, 0xf0, 0x8a, 0xfc, + 0x01, 0x23, 0x01, 0x93, 0x02, 0x33, 0x00, 0x93, 0x0d, 0x22, 0x0b, 0x33, + 0x21, 0x00, 0x0e, 0x48, 0x01, 0xf0, 0xb6, 0xfa, 0x13, 0xbd, 0xc0, 0x46, + 0x00, 0x08, 0x00, 0x42, 0x40, 0x29, 0x00, 0x20, 0x00, 0x0c, 0x00, 0x42, + 0x44, 0x29, 0x00, 0x20, 0x00, 0x10, 0x00, 0x42, 0x48, 0x29, 0x00, 0x20, + 0x00, 0x14, 0x00, 0x42, 0x4c, 0x29, 0x00, 0x20, 0x00, 0x18, 0x00, 0x42, + 0x50, 0x29, 0x00, 0x20, 0x54, 0x29, 0x00, 0x20, 0x00, 0x1c, 0x00, 0x42, + 0x04, 0x27, 0x00, 0x20, 0xf7, 0xb5, 0x01, 0x92, 0x18, 0x22, 0x16, 0x24, + 0x42, 0x43, 0x3f, 0x4b, 0x07, 0x00, 0x9b, 0x18, 0x1c, 0x57, 0x00, 0x91, + 0x63, 0x1c, 0x6e, 0xd0, 0x10, 0x2c, 0x6c, 0xd0, 0x3b, 0x4b, 0x3c, 0x4e, + 0x1d, 0x68, 0x00, 0x2d, 0x27, 0xd1, 0x29, 0x00, 0x44, 0x22, 0x3a, 0x48, + 0x01, 0xf0, 0x4f, 0xfd, 0x29, 0x00, 0x44, 0x22, 0x38, 0x48, 0x01, 0xf0, + 0x4a, 0xfd, 0x10, 0x22, 0x37, 0x4b, 0x38, 0x49, 0x1d, 0x60, 0xca, 0x67, + 0xc0, 0x21, 0xc1, 0x20, 0x36, 0x4b, 0x49, 0x00, 0x5a, 0x50, 0x80, 0x00, + 0x19, 0x58, 0xff, 0x35, 0xa9, 0x43, 0x19, 0x50, 0x1a, 0x60, 0x33, 0x4b, + 0x33, 0x4a, 0x5a, 0x80, 0x02, 0x23, 0x32, 0x78, 0x13, 0x43, 0x33, 0x70, + 0x73, 0x78, 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0x01, 0x22, 0x26, 0x4b, + 0x1a, 0x60, 0x01, 0x25, 0xa5, 0x40, 0x73, 0x69, 0x00, 0x21, 0x2b, 0x43, + 0x73, 0x61, 0x38, 0x00, 0x00, 0xf0, 0xe0, 0xfa, 0x00, 0x9b, 0x00, 0x2b, + 0x31, 0xd0, 0x00, 0x27, 0x22, 0x4b, 0x20, 0x49, 0x9c, 0x46, 0x1b, 0x68, + 0xba, 0x00, 0xbb, 0x42, 0x1d, 0xd1, 0x60, 0x46, 0x01, 0x33, 0x03, 0x60, + 0x8d, 0x50, 0x1c, 0x4b, 0x00, 0x99, 0x99, 0x50, 0x07, 0x2c, 0x19, 0xdd, + 0x01, 0x23, 0x08, 0x3c, 0xa4, 0x00, 0x07, 0x21, 0xa1, 0x40, 0x15, 0x4a, + 0x9b, 0x00, 0x9b, 0x18, 0x9a, 0x69, 0x8a, 0x43, 0x9a, 0x61, 0x01, 0x9a, + 0x04, 0x2a, 0x12, 0xd8, 0x10, 0x00, 0x99, 0x69, 0x01, 0xf0, 0x22, 0xfc, + 0x0b, 0x12, 0x14, 0x16, 0x18, 0x00, 0x88, 0x58, 0xa8, 0x42, 0xe1, 0xd0, + 0x01, 0x37, 0xd9, 0xe7, 0xa4, 0x00, 0x00, 0x23, 0xe5, 0xe7, 0x05, 0x22, + 0xa2, 0x40, 0x0a, 0x43, 0x9a, 0x61, 0xad, 0xb2, 0xf5, 0x60, 0xf7, 0xbd, + 0x04, 0x22, 0xf7, 0xe7, 0x03, 0x22, 0xf5, 0xe7, 0x02, 0x22, 0xf3, 0xe7, + 0x01, 0x22, 0xf1, 0xe7, 0x88, 0x64, 0x00, 0x00, 0xe0, 0x29, 0x00, 0x20, + 0x00, 0x18, 0x00, 0x40, 0x9c, 0x29, 0x00, 0x20, 0x58, 0x29, 0x00, 0x20, + 0xe4, 0x29, 0x00, 0x20, 0x04, 0xe1, 0x00, 0xe0, 0x00, 0xe1, 0x00, 0xe0, + 0x00, 0x0c, 0x00, 0x40, 0x05, 0x40, 0x00, 0x00, 0xf8, 0xb5, 0x00, 0x24, + 0x09, 0x4b, 0x1b, 0x68, 0xa3, 0x42, 0x00, 0xd8, 0xf8, 0xbd, 0x08, 0x4e, + 0x08, 0x4f, 0xa5, 0x00, 0x33, 0x69, 0xea, 0x59, 0x1a, 0x42, 0x04, 0xd0, + 0x06, 0x4b, 0xeb, 0x58, 0x98, 0x47, 0xeb, 0x59, 0x33, 0x61, 0x01, 0x34, + 0xec, 0xe7, 0xc0, 0x46, 0xe4, 0x29, 0x00, 0x20, 0x00, 0x18, 0x00, 0x40, + 0x9c, 0x29, 0x00, 0x20, 0x58, 0x29, 0x00, 0x20, 0xfe, 0xe7, 0x00, 0x00, + 0x03, 0x4b, 0x10, 0xb5, 0x1b, 0x68, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, + 0x10, 0xbd, 0xc0, 0x46, 0xe8, 0x29, 0x00, 0x20, 0x70, 0xb5, 0x0f, 0x49, + 0x0f, 0x4c, 0xa1, 0x42, 0x04, 0xd1, 0x00, 0xf0, 0x89, 0xf8, 0xfd, 0xf7, + 0xa3, 0xff, 0xfe, 0xe7, 0x0c, 0x4d, 0x00, 0x23, 0x8d, 0x42, 0xf6, 0xd0, + 0xca, 0x18, 0xe8, 0x18, 0xa2, 0x42, 0x05, 0xd3, 0x09, 0x4b, 0x82, 0x42, + 0xef, 0xd0, 0x09, 0x49, 0x00, 0x22, 0x04, 0xe0, 0x00, 0x68, 0x04, 0x33, + 0x10, 0x60, 0xf1, 0xe7, 0x04, 0xc3, 0x8b, 0x42, 0xfc, 0xd3, 0xe4, 0xe7, + 0x00, 0x00, 0x00, 0x20, 0xf0, 0x00, 0x00, 0x20, 0xe4, 0x68, 0x00, 0x00, + 0xf0, 0x00, 0x00, 0x20, 0x1c, 0x30, 0x00, 0x20, 0x10, 0xb5, 0x00, 0xf0, + 0x60, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x00, 0xf0, 0x51, 0xf8, 0x10, 0xbd, + 0x01, 0x4b, 0x18, 0x68, 0x70, 0x47, 0xc0, 0x46, 0xec, 0x29, 0x00, 0x20, + 0xf7, 0xb5, 0x13, 0x48, 0x01, 0x22, 0x84, 0x46, 0x12, 0x49, 0x13, 0x4c, + 0x8e, 0x68, 0x63, 0x68, 0x05, 0x68, 0x9b, 0x0e, 0x13, 0x40, 0x01, 0x92, + 0x88, 0x68, 0x62, 0x68, 0x01, 0x9f, 0x92, 0x0e, 0x3a, 0x40, 0x67, 0x46, + 0x3f, 0x68, 0x93, 0x42, 0x0e, 0xd1, 0xbd, 0x42, 0x0c, 0xd1, 0x86, 0x42, + 0x0a, 0xd3, 0x5b, 0x19, 0xfa, 0x25, 0x48, 0x68, 0xad, 0x00, 0x86, 0x1b, + 0x07, 0x48, 0x6b, 0x43, 0x70, 0x43, 0x00, 0x0d, 0xc0, 0x18, 0xfe, 0xbd, + 0x3d, 0x00, 0x13, 0x00, 0x06, 0x00, 0xe3, 0xe7, 0xec, 0x29, 0x00, 0x20, + 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, 0x55, 0x55, 0x00, 0x00, + 0x70, 0xb5, 0x04, 0x1e, 0x10, 0xd0, 0xff, 0xf7, 0xcb, 0xff, 0x05, 0x00, + 0x00, 0xf0, 0x1c, 0xf8, 0xff, 0xf7, 0xc6, 0xff, 0x05, 0x4b, 0x40, 0x1b, + 0x98, 0x42, 0xf7, 0xd9, 0xfa, 0x23, 0x01, 0x3c, 0x9b, 0x00, 0xed, 0x18, + 0x00, 0x2c, 0xf3, 0xd1, 0x70, 0xbd, 0xc0, 0x46, 0xe7, 0x03, 0x00, 0x00, + 0x70, 0x47, 0x00, 0x00, 0x10, 0xb5, 0x03, 0x4a, 0x13, 0x68, 0x01, 0x33, + 0x13, 0x60, 0x00, 0xf0, 0xdd, 0xfa, 0x10, 0xbd, 0xec, 0x29, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, 0x1e, 0x22, 0x70, 0xb5, + 0x46, 0x48, 0x47, 0x49, 0x43, 0x68, 0x93, 0x43, 0x1c, 0x3a, 0x13, 0x43, + 0x43, 0x60, 0x08, 0x23, 0x8c, 0x69, 0x23, 0x43, 0x8b, 0x61, 0x43, 0x4c, + 0x43, 0x4b, 0x9c, 0x82, 0x9c, 0x8a, 0x14, 0x43, 0x9c, 0x82, 0xdc, 0x68, + 0x14, 0x42, 0xfc, 0xd0, 0x01, 0x24, 0x40, 0x4a, 0x14, 0x70, 0x15, 0x78, + 0x25, 0x42, 0x03, 0xd0, 0x55, 0x78, 0x6d, 0xb2, 0x00, 0x2d, 0xf8, 0xdb, + 0x01, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, + 0x39, 0x4c, 0x54, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, + 0x82, 0x24, 0xe4, 0x01, 0x54, 0x80, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x02, 0x24, 0x9c, 0x84, 0x0e, 0x34, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x31, 0x4c, 0xdc, 0x62, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x9d, 0x8c, 0x2e, 0x4c, 0x2c, 0x43, 0x9c, 0x84, 0x10, 0x24, + 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x02, 0x24, 0x9d, 0x8c, 0x80, 0x26, + 0x2c, 0x43, 0x9c, 0x84, 0x40, 0x24, 0xdd, 0x68, 0x35, 0x42, 0xfc, 0xd0, + 0xdd, 0x68, 0x25, 0x42, 0xf9, 0xd0, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x00, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x21, 0x4c, 0x54, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x1c, 0x6a, 0x1e, 0x4d, 0x2c, 0x40, 0x80, 0x25, 0x1c, 0x62, + 0x1c, 0x6a, 0xac, 0x43, 0x1c, 0x62, 0x03, 0x23, 0x93, 0x60, 0x1b, 0x4b, + 0x53, 0x60, 0x53, 0x78, 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x00, 0x23, + 0xff, 0x24, 0x0b, 0x72, 0x17, 0x4a, 0x4b, 0x72, 0x8b, 0x72, 0xcb, 0x72, + 0x16, 0x4b, 0x1a, 0x60, 0x16, 0x4b, 0x17, 0x4a, 0x1b, 0x68, 0x11, 0x68, + 0x9a, 0x06, 0x5b, 0x01, 0xc9, 0x0e, 0x23, 0x40, 0x52, 0x0f, 0x12, 0x02, + 0x0b, 0x43, 0x13, 0x43, 0x12, 0x4a, 0x13, 0x85, 0x80, 0x23, 0x42, 0x68, + 0x13, 0x43, 0x43, 0x60, 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x00, 0x04, 0x00, 0x40, 0x0c, 0x06, 0x00, 0x00, 0x00, 0x08, 0x00, 0x40, + 0x00, 0x0c, 0x00, 0x40, 0x01, 0x05, 0x01, 0x00, 0xb9, 0x05, 0xff, 0x7d, + 0x04, 0x0a, 0x00, 0x00, 0x00, 0x07, 0x03, 0x00, 0xff, 0xfc, 0xff, 0xff, + 0x03, 0x06, 0x01, 0x00, 0x00, 0x6c, 0xdc, 0x02, 0x14, 0x00, 0x00, 0x20, + 0x24, 0x60, 0x80, 0x00, 0x20, 0x60, 0x80, 0x00, 0x00, 0x40, 0x00, 0x42, + 0xfa, 0x21, 0x31, 0x4b, 0x10, 0xb5, 0x18, 0x68, 0x89, 0x00, 0x01, 0xf0, + 0x8d, 0xfa, 0x2f, 0x4b, 0x01, 0x38, 0x98, 0x42, 0x56, 0xd8, 0x2e, 0x49, + 0x2e, 0x4a, 0x48, 0x60, 0xc0, 0x20, 0x13, 0x6a, 0x00, 0x06, 0x1b, 0x02, + 0x1b, 0x0a, 0x03, 0x43, 0x13, 0x62, 0x00, 0x24, 0x07, 0x23, 0x8c, 0x60, + 0x0b, 0x60, 0x80, 0x21, 0x13, 0x6a, 0x09, 0x06, 0x1b, 0x02, 0x1b, 0x0a, + 0x0b, 0x43, 0x13, 0x62, 0xfc, 0x22, 0x25, 0x4b, 0x19, 0x6a, 0x0a, 0x43, + 0x1a, 0x62, 0xfc, 0x22, 0x19, 0x6a, 0x92, 0x01, 0x0a, 0x43, 0x1a, 0x62, + 0xa0, 0x22, 0x19, 0x6a, 0xd2, 0x02, 0x0a, 0x43, 0x1a, 0x62, 0x20, 0x00, + 0x00, 0x21, 0x01, 0x34, 0x00, 0xf0, 0x76, 0xf8, 0x0f, 0x2c, 0xf8, 0xd1, + 0x1b, 0x4b, 0x1c, 0x00, 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, + 0x19, 0x4a, 0x5a, 0x80, 0x19, 0x4b, 0x1a, 0x00, 0x59, 0x7e, 0xc9, 0x09, + 0x01, 0x29, 0xfb, 0xd0, 0xe4, 0x21, 0xc9, 0x00, 0x99, 0x80, 0x3f, 0x21, + 0xd9, 0x70, 0x53, 0x7e, 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0xc0, 0x23, + 0x00, 0x20, 0x5b, 0x01, 0x13, 0x61, 0x90, 0x70, 0x00, 0xf0, 0x24, 0xf8, + 0x63, 0x78, 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x0d, 0x4b, 0x0e, 0x4a, + 0x63, 0x80, 0xd3, 0x79, 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0x41, 0x23, + 0x53, 0x70, 0x10, 0xbd, 0xfe, 0xe7, 0xc0, 0x46, 0x14, 0x00, 0x00, 0x20, + 0xff, 0xff, 0xff, 0x00, 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, + 0x00, 0x04, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, 0x1e, 0x40, 0x00, 0x00, + 0x00, 0x40, 0x00, 0x42, 0x21, 0x40, 0x00, 0x00, 0x00, 0x48, 0x00, 0x42, + 0x16, 0x4a, 0x00, 0xb5, 0x13, 0x00, 0x51, 0x7e, 0xc9, 0x09, 0x01, 0x29, + 0xfb, 0xd0, 0x01, 0x38, 0x04, 0x28, 0x16, 0xd8, 0x19, 0x69, 0x12, 0x4a, + 0x0a, 0x40, 0x0f, 0x21, 0x1a, 0x61, 0x5a, 0x78, 0x8a, 0x43, 0x01, 0xf0, + 0xff, 0xf9, 0x03, 0x08, 0x06, 0x0b, 0x03, 0x00, 0x11, 0x00, 0x01, 0x22, + 0x0a, 0x43, 0x5a, 0x70, 0x00, 0xbd, 0x11, 0x00, 0x03, 0x22, 0xf9, 0xe7, + 0x11, 0x00, 0x02, 0x22, 0xf6, 0xe7, 0xf0, 0x23, 0x11, 0x69, 0x1b, 0x05, + 0x0b, 0x43, 0x0f, 0x21, 0x13, 0x61, 0x53, 0x78, 0x8b, 0x43, 0x19, 0x00, + 0x02, 0x23, 0x0b, 0x43, 0x53, 0x70, 0xeb, 0xe7, 0x00, 0x40, 0x00, 0x42, + 0xff, 0xff, 0xff, 0xf0, 0x18, 0x23, 0x30, 0xb5, 0x1d, 0x00, 0x04, 0x00, + 0x45, 0x43, 0x08, 0x20, 0x20, 0x4a, 0x55, 0x19, 0x28, 0x56, 0x01, 0x30, + 0x14, 0xd0, 0x03, 0x29, 0x12, 0xd8, 0x08, 0x00, 0x63, 0x43, 0xd1, 0x56, + 0xd3, 0x18, 0x01, 0xf0, 0xcd, 0xf9, 0x02, 0x28, 0x0e, 0x1b, 0x58, 0x68, + 0xcb, 0x01, 0x02, 0x21, 0x18, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, + 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x30, 0xbd, 0x58, 0x68, + 0xcb, 0x01, 0x06, 0x21, 0x12, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, + 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x9a, 0x61, 0xf1, 0xe7, + 0x58, 0x68, 0xcb, 0x01, 0x06, 0x21, 0x0c, 0x4a, 0x9b, 0x18, 0x1a, 0x18, + 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x5a, 0x61, + 0xe4, 0xe7, 0x58, 0x68, 0xcb, 0x01, 0x02, 0x21, 0x05, 0x4a, 0x9b, 0x18, + 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x9a, 0x60, + 0xd8, 0xe7, 0xc0, 0x46, 0x88, 0x64, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x18, 0x23, 0xf0, 0xb5, 0x08, 0x24, 0x58, 0x43, 0x11, 0x4a, 0x13, 0x18, + 0x1c, 0x57, 0x01, 0x34, 0x1b, 0xd0, 0x01, 0x26, 0x35, 0x00, 0x5f, 0x68, + 0x83, 0x56, 0xbd, 0x40, 0x0d, 0x4a, 0xdb, 0x01, 0x9a, 0x18, 0x90, 0x68, + 0x05, 0x42, 0x0b, 0xd1, 0x0c, 0x00, 0x60, 0x1e, 0x84, 0x41, 0xd2, 0x19, + 0x40, 0x32, 0x10, 0x78, 0x34, 0x40, 0x03, 0x36, 0xa4, 0x00, 0xb0, 0x43, + 0x20, 0x43, 0x10, 0x70, 0x04, 0x4a, 0x9b, 0x18, 0x00, 0x29, 0x01, 0xd1, + 0x5d, 0x61, 0xf0, 0xbd, 0x9d, 0x61, 0xfc, 0xe7, 0x88, 0x64, 0x00, 0x00, + 0x00, 0x44, 0x00, 0x41, 0x18, 0x22, 0x42, 0x43, 0xf8, 0xb5, 0x2c, 0x4e, + 0x03, 0x00, 0xb2, 0x18, 0x12, 0x7a, 0x52, 0xb2, 0x14, 0x00, 0x01, 0x32, + 0x0e, 0xd0, 0x48, 0x1c, 0x00, 0x24, 0x0c, 0x28, 0x0a, 0xd8, 0x01, 0xf0, + 0x57, 0xf9, 0x07, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x0b, + 0x0b, 0x0b, 0x0b, 0x00, 0x01, 0x24, 0x64, 0x42, 0x20, 0x00, 0xf8, 0xbd, + 0x09, 0x29, 0x05, 0xd1, 0x00, 0x21, 0x18, 0x00, 0xff, 0xf7, 0x66, 0xff, + 0x00, 0x24, 0xf5, 0xe7, 0x0a, 0x29, 0x01, 0xd1, 0x08, 0x39, 0xf6, 0xe7, + 0x00, 0x24, 0x0b, 0x29, 0xee, 0xd1, 0x0a, 0x39, 0x18, 0x00, 0xff, 0xf7, + 0x59, 0xff, 0xe9, 0xe7, 0x18, 0x22, 0x53, 0x43, 0xf2, 0x18, 0x55, 0x68, + 0x01, 0x20, 0x2c, 0x00, 0xf3, 0x56, 0x13, 0x4a, 0xdb, 0x01, 0x6e, 0x08, + 0x9b, 0x18, 0xc9, 0xb2, 0x04, 0x40, 0x9e, 0x19, 0x00, 0x2c, 0x0d, 0xd0, + 0x0f, 0x24, 0x30, 0x36, 0x32, 0x78, 0x09, 0x01, 0x22, 0x40, 0x11, 0x43, + 0xc9, 0xb2, 0x5b, 0x19, 0x31, 0x70, 0x40, 0x33, 0x1a, 0x78, 0x10, 0x43, + 0x18, 0x70, 0xd3, 0xe7, 0x32, 0x00, 0x0f, 0x27, 0x30, 0x32, 0x16, 0x78, + 0x5b, 0x19, 0xbe, 0x43, 0x31, 0x43, 0x11, 0x70, 0x40, 0x33, 0x1a, 0x78, + 0x10, 0x43, 0x18, 0x70, 0xbe, 0xe7, 0xc0, 0x46, 0x88, 0x64, 0x00, 0x00, + 0x00, 0x44, 0x00, 0x41, 0xf7, 0xb5, 0xc3, 0x1d, 0x01, 0x93, 0x00, 0x23, + 0x06, 0x00, 0x0d, 0x00, 0x04, 0x1d, 0x00, 0x93, 0x21, 0x78, 0x0a, 0x22, + 0x28, 0x00, 0x00, 0xf0, 0x81, 0xf8, 0x2e, 0x21, 0x07, 0x00, 0x28, 0x00, + 0x00, 0xf0, 0x47, 0xf8, 0x00, 0x9b, 0x3f, 0x18, 0xdb, 0x19, 0x00, 0x93, + 0x01, 0x9b, 0x01, 0x34, 0x9c, 0x42, 0xed, 0xd1, 0xf1, 0x79, 0x28, 0x00, + 0x0a, 0x22, 0x00, 0xf0, 0x6f, 0xf8, 0x00, 0x9b, 0x18, 0x18, 0xfe, 0xbd, + 0x30, 0xb5, 0x03, 0xac, 0x25, 0x78, 0x04, 0x4c, 0xc5, 0x71, 0x08, 0x34, + 0x04, 0x60, 0x01, 0x71, 0x42, 0x71, 0x83, 0x71, 0x30, 0xbd, 0xc0, 0x46, + 0xe8, 0x67, 0x00, 0x00, 0xf7, 0xb5, 0x06, 0x00, 0x0d, 0x00, 0x0c, 0x00, + 0x8b, 0x18, 0x01, 0x93, 0x01, 0x9b, 0x67, 0x1b, 0x9c, 0x42, 0x07, 0xd0, + 0x33, 0x68, 0x21, 0x78, 0x1b, 0x68, 0x30, 0x00, 0x98, 0x47, 0x01, 0x34, + 0x00, 0x28, 0xf3, 0xd1, 0x38, 0x00, 0xfe, 0xbd, 0x70, 0xb5, 0x04, 0x00, + 0x08, 0x00, 0x0d, 0x00, 0x01, 0xf0, 0x78, 0xfa, 0x23, 0x68, 0x02, 0x00, + 0x29, 0x00, 0x5b, 0x68, 0x20, 0x00, 0x98, 0x47, 0x70, 0xbd, 0x10, 0xb5, + 0x0b, 0x1e, 0x02, 0xd0, 0xff, 0xf7, 0xee, 0xff, 0x03, 0x00, 0x18, 0x00, + 0x10, 0xbd, 0x10, 0xb5, 0x03, 0x68, 0x1b, 0x68, 0x98, 0x47, 0x10, 0xbd, + 0xf0, 0xb5, 0x8b, 0xb0, 0x6b, 0x46, 0x15, 0x00, 0x00, 0x22, 0x05, 0x33, + 0x06, 0x00, 0xda, 0x77, 0x08, 0x00, 0x01, 0x2d, 0x00, 0xd8, 0x0a, 0x25, + 0x09, 0xac, 0x29, 0x00, 0x01, 0xf0, 0x2a, 0xf9, 0xca, 0xb2, 0x13, 0x00, + 0x37, 0x33, 0x07, 0x00, 0xdb, 0xb2, 0x09, 0x29, 0x02, 0xd8, 0x13, 0x00, + 0x30, 0x33, 0xdb, 0xb2, 0x01, 0x3c, 0x23, 0x70, 0x00, 0x2f, 0xee, 0xd1, + 0x21, 0x00, 0x30, 0x00, 0xff, 0xf7, 0xd1, 0xff, 0x0b, 0xb0, 0xf0, 0xbd, + 0x10, 0xb5, 0x00, 0x2a, 0x04, 0xd1, 0x03, 0x68, 0xc9, 0xb2, 0x1b, 0x68, + 0x98, 0x47, 0x10, 0xbd, 0xd2, 0xb2, 0xff, 0xf7, 0xd1, 0xff, 0xfa, 0xe7, + 0x10, 0xb5, 0xff, 0xf7, 0xf1, 0xff, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, + 0xff, 0xf7, 0x28, 0xfd, 0x01, 0x4b, 0x1c, 0x60, 0x10, 0xbd, 0xc0, 0x46, + 0x18, 0x00, 0x00, 0x20, 0x01, 0x22, 0x02, 0x4b, 0x52, 0x42, 0x1a, 0x60, + 0x70, 0x47, 0xc0, 0x46, 0x18, 0x00, 0x00, 0x20, 0x16, 0x4a, 0x10, 0xb5, + 0x13, 0x68, 0x59, 0x1c, 0x26, 0xd0, 0x01, 0x3b, 0x13, 0x60, 0x00, 0x2b, + 0x22, 0xd1, 0x72, 0xb6, 0x12, 0x4b, 0x13, 0x4a, 0x04, 0x33, 0x93, 0x42, + 0x13, 0xd9, 0x12, 0x4a, 0x01, 0x21, 0x10, 0x00, 0x14, 0x7d, 0x0c, 0x42, + 0xfc, 0xd0, 0x20, 0x21, 0x14, 0x8b, 0xff, 0x31, 0x9b, 0x08, 0x5b, 0x00, + 0x21, 0x43, 0x11, 0x83, 0xd3, 0x61, 0x0c, 0x4b, 0x13, 0x80, 0x01, 0x23, + 0x02, 0x7d, 0x1a, 0x42, 0xfc, 0xd0, 0xbf, 0xf3, 0x4f, 0x8f, 0x09, 0x4b, + 0x09, 0x4a, 0xda, 0x60, 0xbf, 0xf3, 0x4f, 0x8f, 0xc0, 0x46, 0xfd, 0xe7, + 0x10, 0xbd, 0xc0, 0x46, 0x18, 0x00, 0x00, 0x20, 0x00, 0x20, 0x00, 0x00, + 0x03, 0x02, 0x00, 0x00, 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, + 0x00, 0xed, 0x00, 0xe0, 0x04, 0x00, 0xfa, 0x05, 0x01, 0x60, 0x70, 0x47, + 0x94, 0x46, 0xf0, 0xb5, 0x9e, 0x1e, 0x72, 0x1e, 0x96, 0x41, 0x62, 0x46, + 0x05, 0x68, 0x92, 0x07, 0x2f, 0x68, 0x36, 0x06, 0x3a, 0x43, 0x32, 0x43, + 0x2a, 0x60, 0x07, 0x25, 0x05, 0xac, 0x24, 0x78, 0x00, 0x68, 0xa4, 0x01, + 0x29, 0x40, 0x21, 0x43, 0x42, 0x68, 0x00, 0x24, 0x02, 0x2b, 0x00, 0xd0, + 0x5c, 0x03, 0x11, 0x43, 0x21, 0x43, 0x41, 0x60, 0xf0, 0xbd, 0x30, 0xb5, + 0xc0, 0x25, 0x03, 0x68, 0xad, 0x03, 0x1c, 0x68, 0x12, 0x05, 0x2a, 0x40, + 0x22, 0x43, 0xc0, 0x24, 0x09, 0x04, 0xa4, 0x02, 0x21, 0x40, 0x11, 0x43, + 0x19, 0x60, 0x03, 0x68, 0x5a, 0x68, 0x14, 0x43, 0x5c, 0x60, 0x30, 0xbd, + 0x01, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, 0x03, 0x68, + 0x1a, 0x68, 0xd2, 0x07, 0xfc, 0xd4, 0xda, 0x69, 0xd2, 0x07, 0xf9, 0xd4, + 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, + 0x02, 0x68, 0xd3, 0x69, 0x9b, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, + 0x1a, 0x7e, 0xd2, 0x07, 0x02, 0xd4, 0x1a, 0x7e, 0x92, 0x07, 0xfc, 0xd5, + 0x70, 0x47, 0x00, 0x22, 0x03, 0x68, 0x5a, 0x83, 0x70, 0x47, 0x03, 0x68, + 0x18, 0x7e, 0x40, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, + 0xc0, 0x09, 0x70, 0x47, 0x80, 0x23, 0x02, 0x68, 0x5b, 0x42, 0x11, 0x7e, + 0x0b, 0x43, 0x13, 0x76, 0x70, 0x47, 0x03, 0x68, 0x58, 0x8b, 0x80, 0x07, + 0xc0, 0x0f, 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, 0x51, 0x8b, 0x0b, 0x43, + 0x53, 0x83, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x07, 0xc0, 0x0f, + 0x70, 0x47, 0x03, 0x68, 0x18, 0x8d, 0xc0, 0xb2, 0x70, 0x47, 0x03, 0x68, + 0x1a, 0x7e, 0xd2, 0x07, 0xfc, 0xd5, 0x89, 0xb2, 0x01, 0x20, 0x19, 0x85, + 0x70, 0x47, 0x01, 0x22, 0x03, 0x68, 0x9a, 0x75, 0x70, 0x47, 0x01, 0x22, + 0x03, 0x68, 0x1a, 0x75, 0x70, 0x47, 0x00, 0x00, 0x70, 0xb5, 0x01, 0x26, + 0x04, 0x68, 0x4b, 0x08, 0x33, 0x40, 0x31, 0x40, 0x25, 0x68, 0x09, 0x07, + 0x5b, 0x07, 0x0b, 0x43, 0x2b, 0x43, 0x23, 0x60, 0x04, 0x68, 0x51, 0x00, + 0x03, 0x48, 0x00, 0xf0, 0x97, 0xff, 0x01, 0x38, 0xc0, 0xb2, 0x20, 0x73, + 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x6c, 0xdc, 0x02, 0x01, 0x23, 0x02, 0x68, + 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, 0x03, 0x68, 0x1a, 0x68, 0xd2, 0x07, + 0xfc, 0xd4, 0xda, 0x69, 0xd2, 0x07, 0xf9, 0xd4, 0x70, 0x47, 0x02, 0x23, + 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, 0x02, 0x68, 0xd3, 0x69, + 0x9b, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, 0xda, 0x69, 0x92, 0x07, + 0xfc, 0xd4, 0x02, 0x21, 0x1a, 0x68, 0x8a, 0x43, 0x1a, 0x60, 0x70, 0x47, + 0x02, 0x68, 0x93, 0x6a, 0x5b, 0x0a, 0x5b, 0x02, 0x19, 0x43, 0x91, 0x62, + 0x03, 0x68, 0x1a, 0x7e, 0x52, 0x07, 0xfc, 0xd5, 0x98, 0x6a, 0xc0, 0xb2, + 0x70, 0x47, 0x00, 0x00, 0x03, 0x68, 0x21, 0x4a, 0x30, 0xb5, 0x93, 0x42, + 0x2f, 0xd0, 0x20, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1f, 0x4a, 0x93, 0x42, + 0x2f, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1e, 0x4a, 0x93, 0x42, + 0x2f, 0xd0, 0x1e, 0x4a, 0x93, 0x42, 0x1f, 0xd1, 0x0e, 0x23, 0x19, 0x22, + 0x01, 0x21, 0x03, 0x25, 0x99, 0x40, 0x1b, 0x48, 0xc0, 0x24, 0x01, 0x60, + 0x99, 0x08, 0x2b, 0x40, 0xab, 0x40, 0xfc, 0x35, 0x9d, 0x40, 0x89, 0x00, + 0x09, 0x18, 0xa4, 0x00, 0x08, 0x59, 0xa8, 0x43, 0xc0, 0x25, 0x9d, 0x40, + 0x2b, 0x00, 0x03, 0x43, 0x0b, 0x51, 0x80, 0x23, 0xdb, 0x01, 0x1a, 0x43, + 0x11, 0x4b, 0x5a, 0x80, 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, + 0x30, 0xbd, 0x09, 0x23, 0x14, 0x22, 0xdd, 0xe7, 0x0a, 0x23, 0x15, 0x22, + 0xda, 0xe7, 0x0b, 0x23, 0x16, 0x22, 0xd7, 0xe7, 0x0c, 0x23, 0x17, 0x22, + 0xd4, 0xe7, 0x0d, 0x23, 0x18, 0x22, 0xd1, 0xe7, 0x00, 0x08, 0x00, 0x42, + 0x00, 0x0c, 0x00, 0x42, 0x00, 0x10, 0x00, 0x42, 0x00, 0x14, 0x00, 0x42, + 0x00, 0x18, 0x00, 0x42, 0x00, 0x1c, 0x00, 0x42, 0x00, 0xe1, 0x00, 0xe0, + 0x00, 0x0c, 0x00, 0x40, 0xf8, 0xb5, 0x04, 0x00, 0x0f, 0x00, 0x16, 0x00, + 0x1d, 0x00, 0xff, 0xf7, 0xa5, 0xff, 0x20, 0x00, 0xff, 0xf7, 0x04, 0xff, + 0x1c, 0x21, 0xbb, 0x00, 0x0b, 0x40, 0x71, 0x07, 0x22, 0x68, 0x09, 0x0c, + 0x0b, 0x43, 0x13, 0x60, 0x84, 0x23, 0x22, 0x68, 0x93, 0x75, 0x01, 0x2f, + 0x1a, 0xd1, 0x10, 0x21, 0x01, 0x2e, 0x00, 0xd0, 0x08, 0x39, 0x0c, 0x4b, + 0x69, 0x43, 0x18, 0x68, 0xc0, 0x00, 0x00, 0xf0, 0xed, 0xfe, 0x07, 0x22, + 0x21, 0x68, 0x02, 0x40, 0x8b, 0x89, 0x52, 0x03, 0xdb, 0x04, 0xdb, 0x0c, + 0x13, 0x43, 0x8b, 0x81, 0x22, 0x68, 0x03, 0x04, 0x90, 0x89, 0xdb, 0x0c, + 0x40, 0x0b, 0x40, 0x03, 0x18, 0x43, 0x90, 0x81, 0xf8, 0xbd, 0xc0, 0x46, + 0x14, 0x00, 0x00, 0x20, 0xf7, 0xb5, 0x06, 0x00, 0x01, 0x93, 0x08, 0xab, + 0x1f, 0x78, 0x0d, 0x00, 0x14, 0x00, 0xff, 0xf7, 0x3f, 0xff, 0x30, 0x00, + 0xff, 0xf7, 0x6a, 0xff, 0xc0, 0x22, 0x24, 0x05, 0x92, 0x03, 0x14, 0x40, + 0xba, 0x07, 0x0c, 0x27, 0x17, 0x43, 0x3c, 0x43, 0xc0, 0x27, 0x07, 0x22, + 0xbf, 0x02, 0x2d, 0x04, 0x33, 0x68, 0x3d, 0x40, 0x25, 0x43, 0x1d, 0x60, + 0x01, 0x9b, 0x31, 0x68, 0x13, 0x40, 0x1a, 0x00, 0x80, 0x23, 0x9b, 0x02, + 0x13, 0x43, 0x4b, 0x60, 0xf7, 0xbd, 0x00, 0x20, 0x70, 0x47, 0x70, 0xb5, + 0x0f, 0x26, 0xcb, 0x1d, 0x01, 0x39, 0x02, 0x00, 0x32, 0x40, 0xd5, 0xb2, + 0x2c, 0x00, 0x00, 0x09, 0x30, 0x34, 0x09, 0x2a, 0x00, 0xdd, 0x07, 0x34, + 0x1c, 0x70, 0x01, 0x3b, 0x8b, 0x42, 0xf2, 0xd1, 0x70, 0xbd, 0x00, 0x00, + 0x10, 0xb5, 0x0c, 0x00, 0x0b, 0x4b, 0x18, 0x68, 0xff, 0xf7, 0xe7, 0xff, + 0x21, 0x00, 0x0a, 0x4b, 0x08, 0x31, 0x18, 0x68, 0xff, 0xf7, 0xe1, 0xff, + 0x21, 0x00, 0x08, 0x4b, 0x10, 0x31, 0x18, 0x68, 0xff, 0xf7, 0xdb, 0xff, + 0x21, 0x00, 0x06, 0x4b, 0x18, 0x31, 0x18, 0x68, 0xff, 0xf7, 0xd5, 0xff, + 0x20, 0x20, 0x10, 0xbd, 0x0c, 0xa0, 0x80, 0x00, 0x40, 0xa0, 0x80, 0x00, + 0x44, 0xa0, 0x80, 0x00, 0x48, 0xa0, 0x80, 0x00, 0x08, 0xb4, 0x02, 0x4b, + 0x9c, 0x46, 0x10, 0x38, 0x08, 0xbc, 0x60, 0x47, 0xd1, 0x4c, 0x00, 0x00, + 0x70, 0x47, 0x3f, 0x20, 0x70, 0x47, 0x13, 0xb5, 0x6b, 0x46, 0x02, 0x68, + 0xd9, 0x71, 0x07, 0x33, 0x54, 0x68, 0x19, 0x00, 0x01, 0x22, 0xa0, 0x47, + 0x16, 0xbd, 0x00, 0x00, 0x70, 0xb5, 0x0a, 0x26, 0x0b, 0x78, 0x92, 0xb0, + 0x6e, 0x44, 0x02, 0x33, 0x05, 0x00, 0x0b, 0x70, 0x3c, 0x22, 0x00, 0x21, + 0x30, 0x00, 0x00, 0xf0, 0x2a, 0xff, 0x39, 0x48, 0x01, 0xac, 0x06, 0x90, + 0x38, 0x48, 0x24, 0x21, 0x07, 0x90, 0x06, 0x20, 0x20, 0x77, 0x68, 0x46, + 0x36, 0x4a, 0xa1, 0x74, 0x22, 0x81, 0x36, 0x4a, 0x36, 0x4b, 0xa2, 0x81, + 0xfd, 0x3a, 0xff, 0x3a, 0x80, 0x18, 0xc1, 0x77, 0x68, 0x46, 0x23, 0x39, + 0x06, 0x30, 0xc1, 0x77, 0x68, 0x46, 0x07, 0x30, 0xc1, 0x77, 0x02, 0xa8, + 0xc1, 0x77, 0x07, 0x20, 0xf2, 0x77, 0x03, 0x26, 0x08, 0x31, 0x69, 0x44, + 0xc8, 0x77, 0x03, 0xa9, 0xce, 0x77, 0x10, 0x21, 0x2b, 0x36, 0x6e, 0x44, + 0x31, 0x70, 0x09, 0x26, 0x21, 0x85, 0x1f, 0x31, 0x69, 0x44, 0x0e, 0x70, + 0x0c, 0xa9, 0x05, 0x3e, 0x0e, 0x70, 0x33, 0x21, 0x23, 0x80, 0x02, 0x23, + 0x69, 0x44, 0x0b, 0x70, 0x06, 0x36, 0x0d, 0xa9, 0x0e, 0x70, 0x22, 0x49, + 0x35, 0x36, 0xa1, 0x86, 0x3b, 0x21, 0x6e, 0x44, 0x30, 0x70, 0x10, 0xa8, + 0x62, 0x74, 0xe2, 0x77, 0x02, 0x70, 0x3d, 0x32, 0x69, 0x44, 0x6a, 0x44, + 0x0b, 0x70, 0x13, 0x70, 0x40, 0x21, 0x00, 0x22, 0xe3, 0x70, 0x23, 0x71, + 0x63, 0x71, 0xa3, 0x73, 0x41, 0x33, 0x6b, 0x44, 0x21, 0x87, 0x19, 0x70, + 0x5a, 0x70, 0x2b, 0x7d, 0xc0, 0x39, 0xa3, 0x70, 0xa3, 0x72, 0x63, 0x77, + 0x01, 0x33, 0xdb, 0xb2, 0xa3, 0x77, 0x6a, 0x7d, 0x0b, 0x20, 0x0d, 0x00, + 0x68, 0x44, 0x15, 0x43, 0xc5, 0x77, 0x31, 0x20, 0x68, 0x44, 0x03, 0x70, + 0x3a, 0x23, 0x50, 0x1c, 0x6b, 0x44, 0x18, 0x70, 0x41, 0x23, 0x02, 0x32, + 0x0a, 0x43, 0x6b, 0x44, 0x1a, 0x70, 0x21, 0x00, 0x42, 0x22, 0x08, 0x48, + 0x00, 0xf0, 0xd8, 0xfa, 0x12, 0xb0, 0x70, 0xbd, 0x10, 0x01, 0x04, 0x24, + 0x02, 0x06, 0x05, 0x24, 0x09, 0x04, 0x00, 0x00, 0x01, 0x02, 0x00, 0x00, + 0x08, 0x0b, 0x00, 0x00, 0x07, 0x05, 0x00, 0x00, 0x58, 0x2a, 0x00, 0x20, + 0x08, 0xb4, 0x02, 0x4b, 0x9c, 0x46, 0x10, 0x38, 0x08, 0xbc, 0x60, 0x47, + 0x41, 0x4d, 0x00, 0x00, 0x70, 0xb5, 0x02, 0x7d, 0x0b, 0x79, 0x0c, 0x00, + 0x00, 0x25, 0x9a, 0x42, 0x0b, 0xd1, 0x0b, 0x78, 0x4e, 0x78, 0xa1, 0x2b, + 0x09, 0xd1, 0x21, 0x2e, 0x05, 0xd1, 0x07, 0x22, 0x1f, 0x49, 0x20, 0x48, + 0x00, 0xf0, 0xae, 0xfa, 0x01, 0x35, 0x28, 0x00, 0x70, 0xbd, 0x21, 0x2b, + 0xfb, 0xd1, 0x20, 0x2e, 0x2b, 0xd1, 0x07, 0x22, 0x19, 0x49, 0x1a, 0x48, + 0x00, 0xf0, 0xe4, 0xf9, 0x17, 0x4b, 0x1a, 0x78, 0x59, 0x78, 0x09, 0x02, + 0x11, 0x43, 0x9a, 0x78, 0x12, 0x04, 0x11, 0x43, 0xda, 0x78, 0x12, 0x06, + 0x0a, 0x43, 0x96, 0x21, 0xc9, 0x00, 0x8a, 0x42, 0x1d, 0xd1, 0xdb, 0x79, + 0xdb, 0x07, 0x1a, 0xd4, 0xfa, 0x20, 0xff, 0xf7, 0x1d, 0xfd, 0x00, 0x21, + 0x0d, 0x48, 0x00, 0xf0, 0xb3, 0xfa, 0x01, 0x25, 0x23, 0x2e, 0xd8, 0xd1, + 0xe3, 0x78, 0xa2, 0x78, 0x1b, 0x02, 0x13, 0x43, 0x09, 0x4a, 0x00, 0x21, + 0x07, 0x48, 0x13, 0x60, 0x00, 0xf0, 0xa6, 0xfa, 0xcd, 0xe7, 0x22, 0x2e, + 0xef, 0xd1, 0x8a, 0x78, 0x02, 0x4b, 0xda, 0x71, 0xd2, 0xe7, 0xff, 0xf7, + 0x0d, 0xfd, 0xe4, 0xe7, 0x20, 0x00, 0x00, 0x20, 0x58, 0x2a, 0x00, 0x20, + 0x1c, 0x00, 0x00, 0x20, 0x08, 0xb4, 0x02, 0x4b, 0x9c, 0x46, 0x10, 0x38, + 0x08, 0xbc, 0x60, 0x47, 0x6d, 0x4e, 0x00, 0x00, 0x10, 0xb5, 0x41, 0x7d, + 0x00, 0x6a, 0x01, 0x31, 0x00, 0xf0, 0xd8, 0xf8, 0x03, 0x4b, 0x1b, 0x68, + 0x01, 0x33, 0x5a, 0x1e, 0x93, 0x41, 0x18, 0x18, 0x10, 0xbd, 0xc0, 0x46, + 0x28, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x41, 0x7d, 0x00, 0x6a, 0x02, 0x31, + 0x00, 0xf0, 0xde, 0xf8, 0x10, 0xbd, 0x10, 0xb5, 0x41, 0x7d, 0x00, 0x6a, + 0x02, 0x31, 0x00, 0xf0, 0xa5, 0xf8, 0x10, 0xbd, 0x70, 0xb5, 0x0d, 0x00, + 0x41, 0x7d, 0x04, 0x00, 0x13, 0x00, 0x02, 0x31, 0x2a, 0x00, 0x00, 0x6a, + 0x00, 0xf0, 0x92, 0xf9, 0x00, 0x28, 0x01, 0xd1, 0x01, 0x23, 0x63, 0x60, + 0x70, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x05, 0x4c, 0x23, 0x68, 0x5a, 0x1c, + 0x04, 0xd1, 0x03, 0x68, 0x5b, 0x69, 0x98, 0x47, 0x03, 0x00, 0x20, 0x60, + 0x18, 0x00, 0x10, 0xbd, 0x28, 0x00, 0x00, 0x20, 0x07, 0x4a, 0x03, 0x00, + 0x10, 0x68, 0x10, 0xb5, 0x41, 0x1c, 0x03, 0xd0, 0x01, 0x23, 0x5b, 0x42, + 0x13, 0x60, 0x10, 0xbd, 0x59, 0x7d, 0x18, 0x6a, 0x01, 0x31, 0x00, 0xf0, + 0x1f, 0xf9, 0xf8, 0xe7, 0x28, 0x00, 0x00, 0x20, 0x70, 0x47, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x00, 0xfa, 0x23, 0x9b, 0x00, 0x10, 0xb5, 0x83, 0x60, + 0x0f, 0x4b, 0x00, 0x22, 0xc3, 0x82, 0x03, 0x00, 0x28, 0x33, 0x83, 0x61, + 0x0d, 0x4b, 0x04, 0x00, 0x42, 0x60, 0xc2, 0x61, 0x18, 0x00, 0x44, 0x33, + 0x23, 0x61, 0x08, 0x30, 0x63, 0x1d, 0x21, 0x62, 0x20, 0x60, 0xda, 0x77, + 0x83, 0x23, 0xa3, 0x62, 0x81, 0x3b, 0xe3, 0x62, 0x80, 0x33, 0x23, 0x63, + 0x00, 0xf0, 0x40, 0xf8, 0x21, 0x00, 0x10, 0x31, 0x00, 0xf0, 0x10, 0xf8, + 0x20, 0x00, 0x10, 0xbd, 0x03, 0x02, 0x00, 0x00, 0xf4, 0x67, 0x00, 0x00, + 0x10, 0xb5, 0x02, 0x49, 0x02, 0x48, 0xff, 0xf7, 0xd3, 0xff, 0x10, 0xbd, + 0x58, 0x2a, 0x00, 0x20, 0xf0, 0x29, 0x00, 0x20, 0xf0, 0xb5, 0x8c, 0x79, + 0x45, 0x78, 0x03, 0x00, 0x2a, 0x19, 0x00, 0x20, 0x07, 0x2a, 0x1f, 0xdc, + 0x5a, 0x68, 0x82, 0x42, 0x16, 0xd1, 0x59, 0x60, 0x1a, 0x78, 0xc8, 0x79, + 0x0a, 0x71, 0x12, 0x18, 0x4d, 0x71, 0x1a, 0x70, 0x00, 0x22, 0x0b, 0x4d, + 0xd0, 0xb2, 0x84, 0x42, 0x0f, 0xd9, 0x8f, 0x68, 0x58, 0x78, 0x96, 0x00, + 0xf7, 0x59, 0x86, 0x00, 0x01, 0x30, 0x77, 0x51, 0x01, 0x32, 0x58, 0x70, + 0xf2, 0xe7, 0x02, 0x00, 0xd0, 0x68, 0x00, 0x28, 0xfb, 0xd1, 0xd1, 0x60, + 0xe4, 0xe7, 0x01, 0x20, 0xf0, 0xbd, 0xc0, 0x46, 0x30, 0x2a, 0x00, 0x20, + 0x01, 0x21, 0x06, 0x4a, 0x10, 0xb5, 0x13, 0x68, 0x05, 0x48, 0x0b, 0x40, + 0x04, 0xd1, 0x80, 0x24, 0x64, 0x00, 0x04, 0x80, 0x43, 0x60, 0x11, 0x60, + 0x10, 0xbd, 0xc0, 0x46, 0x24, 0x2a, 0x00, 0x20, 0x28, 0x2a, 0x00, 0x20, + 0x0b, 0x4b, 0xca, 0xb2, 0x0b, 0x48, 0x89, 0x01, 0xc9, 0x18, 0x53, 0x01, + 0xc3, 0x18, 0x59, 0x61, 0x99, 0x69, 0x08, 0x32, 0x89, 0x0b, 0x89, 0x03, + 0x99, 0x61, 0x03, 0x68, 0x52, 0x01, 0x9a, 0x18, 0x02, 0x23, 0xd3, 0x71, + 0x51, 0x79, 0x82, 0x3b, 0x0b, 0x43, 0x53, 0x71, 0x70, 0x47, 0xc0, 0x46, + 0x80, 0x2a, 0x00, 0x20, 0x08, 0x2f, 0x00, 0x20, 0x08, 0x4b, 0x8a, 0x00, + 0xd0, 0x58, 0x10, 0xb5, 0x00, 0x28, 0x03, 0xd0, 0x03, 0x68, 0x9b, 0x68, + 0x98, 0x47, 0x10, 0xbd, 0xc9, 0xb2, 0x04, 0x4b, 0x49, 0x01, 0x59, 0x18, + 0x88, 0x68, 0x80, 0x04, 0x80, 0x0c, 0xf6, 0xe7, 0x5c, 0x2a, 0x00, 0x20, + 0x08, 0x2f, 0x00, 0x20, 0x10, 0xb5, 0x0c, 0x00, 0xff, 0xf7, 0xe6, 0xff, + 0x00, 0x28, 0x0c, 0xd0, 0x06, 0x4b, 0xe4, 0xb2, 0x1b, 0x68, 0x08, 0x34, + 0x64, 0x01, 0x1c, 0x19, 0x80, 0x23, 0x62, 0x79, 0x5b, 0x42, 0x13, 0x43, + 0x63, 0x71, 0x02, 0x23, 0xe3, 0x71, 0x10, 0xbd, 0x08, 0x2f, 0x00, 0x20, + 0xf0, 0xb5, 0x1c, 0x00, 0x2a, 0x4b, 0x85, 0xb0, 0x1b, 0x68, 0x07, 0x00, + 0x0d, 0x00, 0x02, 0x92, 0x00, 0x2b, 0x4a, 0xd0, 0x27, 0x4b, 0x8a, 0x00, + 0xd0, 0x58, 0x00, 0x28, 0x08, 0xd0, 0x03, 0x68, 0x22, 0x00, 0x5b, 0x68, + 0x02, 0x99, 0x98, 0x47, 0x04, 0x00, 0x20, 0x00, 0x05, 0xb0, 0xf0, 0xbd, + 0x38, 0x00, 0xff, 0xf7, 0xb9, 0xff, 0x84, 0x42, 0x04, 0xd9, 0x29, 0x00, + 0x38, 0x00, 0xff, 0xf7, 0xb3, 0xff, 0x04, 0x00, 0x01, 0x21, 0xeb, 0xb2, + 0x1b, 0x4e, 0x03, 0x93, 0x5b, 0x01, 0x01, 0x93, 0xf2, 0x18, 0x93, 0x68, + 0x9b, 0x0b, 0x9b, 0x03, 0x93, 0x60, 0x01, 0x9a, 0x33, 0x68, 0x02, 0x98, + 0x9b, 0x18, 0xff, 0x33, 0x5a, 0x7a, 0x0a, 0x43, 0x5a, 0x72, 0x14, 0x4b, + 0xa9, 0x01, 0xc9, 0x18, 0x22, 0x00, 0x00, 0xf0, 0xf7, 0xfc, 0x00, 0x2c, + 0xd7, 0xd0, 0x29, 0x00, 0x38, 0x00, 0xff, 0xf7, 0x93, 0xff, 0x00, 0x28, + 0xd1, 0xd1, 0x40, 0x21, 0x03, 0x9b, 0x32, 0x68, 0x08, 0x33, 0x5b, 0x01, + 0xd3, 0x18, 0x18, 0x79, 0x01, 0x43, 0x19, 0x71, 0x01, 0x21, 0xd9, 0x71, + 0x01, 0x9b, 0xd3, 0x18, 0xff, 0x33, 0x9a, 0x7a, 0x0a, 0x43, 0x9a, 0x72, + 0xbf, 0xe7, 0x01, 0x24, 0x64, 0x42, 0xbc, 0xe7, 0x04, 0x2f, 0x00, 0x20, + 0x5c, 0x2a, 0x00, 0x20, 0x08, 0x2f, 0x00, 0x20, 0x40, 0x2c, 0x00, 0x20, + 0x13, 0xb5, 0x6b, 0x46, 0xdc, 0x1d, 0x22, 0x00, 0x01, 0x23, 0xff, 0xf7, + 0x99, 0xff, 0x01, 0x28, 0x01, 0xd1, 0x20, 0x78, 0x16, 0xbd, 0x01, 0x20, + 0x40, 0x42, 0xfb, 0xe7, 0x70, 0xb5, 0xcb, 0xb2, 0x12, 0x4a, 0x13, 0x48, + 0x5c, 0x01, 0x89, 0x01, 0x89, 0x18, 0x02, 0x19, 0x51, 0x60, 0x91, 0x68, + 0x10, 0x4d, 0x08, 0x33, 0x0d, 0x40, 0x80, 0x21, 0x49, 0x03, 0x29, 0x43, + 0x40, 0x25, 0x91, 0x60, 0x91, 0x68, 0x89, 0x0b, 0x89, 0x03, 0x91, 0x60, + 0x01, 0x68, 0x5a, 0x01, 0x8a, 0x18, 0x16, 0x79, 0x35, 0x43, 0x15, 0x71, + 0x95, 0x79, 0x6d, 0x06, 0xfc, 0xd5, 0x5b, 0x01, 0xc9, 0x18, 0xcb, 0x79, + 0xdb, 0x07, 0xfc, 0xd5, 0x00, 0x19, 0x80, 0x68, 0xc0, 0xb2, 0x70, 0xbd, + 0x40, 0x2c, 0x00, 0x20, 0x08, 0x2f, 0x00, 0x20, 0xff, 0x3f, 0x00, 0xf0, + 0x70, 0xb5, 0x0d, 0x00, 0x00, 0x21, 0x14, 0x00, 0xff, 0xf7, 0xcc, 0xff, + 0xa0, 0x42, 0x00, 0xd9, 0x20, 0x00, 0x00, 0x23, 0x03, 0x49, 0xa3, 0x42, + 0x03, 0xd0, 0xca, 0x5c, 0xea, 0x54, 0x01, 0x33, 0xf9, 0xe7, 0x70, 0xbd, + 0x40, 0x2c, 0x00, 0x20, 0xf0, 0xb5, 0x1e, 0x00, 0x3a, 0x4b, 0x85, 0xb0, + 0x1b, 0x68, 0x0f, 0x00, 0x01, 0x92, 0x00, 0x2b, 0x35, 0xd0, 0x80, 0x23, + 0xdb, 0x01, 0x9e, 0x42, 0x31, 0xd8, 0x00, 0x25, 0x35, 0x4b, 0x8a, 0x01, + 0xd3, 0x18, 0x02, 0x93, 0x00, 0x2e, 0x2c, 0xd0, 0x33, 0x4b, 0x1b, 0x68, + 0x03, 0x93, 0xff, 0x23, 0x3b, 0x40, 0x1c, 0x00, 0x00, 0x93, 0x08, 0x34, + 0x03, 0x9b, 0x64, 0x01, 0x1c, 0x19, 0xa3, 0x79, 0xdb, 0x09, 0x21, 0xd0, + 0x2d, 0x4b, 0x2e, 0x49, 0x18, 0x68, 0x00, 0xf0, 0x93, 0xfb, 0x2d, 0x4b, + 0x17, 0x21, 0x58, 0x43, 0x00, 0xf0, 0x8e, 0xfb, 0x2b, 0x4b, 0xe2, 0x79, + 0x92, 0x07, 0x13, 0xd4, 0xda, 0x5d, 0x00, 0x2a, 0x01, 0xd1, 0x01, 0x38, + 0xf7, 0xd2, 0x01, 0x22, 0xda, 0x55, 0x00, 0x9b, 0x5a, 0x01, 0x21, 0x4b, + 0x9b, 0x18, 0x9a, 0x69, 0x92, 0x0b, 0x92, 0x03, 0x9a, 0x61, 0x01, 0x25, + 0x6d, 0x42, 0x28, 0x00, 0x05, 0xb0, 0xf0, 0xbd, 0x00, 0x22, 0x1f, 0x4b, + 0x34, 0x00, 0xda, 0x55, 0x3f, 0x2e, 0x09, 0xd9, 0x00, 0x9b, 0x40, 0x24, + 0x5a, 0x01, 0x17, 0x4b, 0x9b, 0x18, 0x80, 0x22, 0x99, 0x69, 0x12, 0x06, + 0x0a, 0x43, 0x9a, 0x61, 0x22, 0x00, 0x01, 0x99, 0x02, 0x98, 0x00, 0xf0, + 0x29, 0xfc, 0x00, 0x9b, 0xa1, 0x04, 0x5a, 0x01, 0x0f, 0x4b, 0x89, 0x0c, + 0x9b, 0x18, 0x02, 0x9a, 0x2d, 0x19, 0x5a, 0x61, 0x9a, 0x69, 0x36, 0x1b, + 0x92, 0x0b, 0x92, 0x03, 0x0a, 0x43, 0x9a, 0x61, 0x00, 0x9b, 0x03, 0x9a, + 0x08, 0x33, 0x5b, 0x01, 0xd3, 0x18, 0x02, 0x22, 0xda, 0x71, 0x59, 0x79, + 0x82, 0x3a, 0x0a, 0x43, 0x5a, 0x71, 0x01, 0x9b, 0x1b, 0x19, 0x01, 0x93, + 0x9a, 0xe7, 0xc0, 0x46, 0x04, 0x2f, 0x00, 0x20, 0x80, 0x2a, 0x00, 0x20, + 0x08, 0x2f, 0x00, 0x20, 0x14, 0x00, 0x00, 0x20, 0x40, 0x42, 0x0f, 0x00, + 0x70, 0x11, 0x01, 0x00, 0x78, 0x2a, 0x00, 0x20, 0x70, 0xb5, 0x0d, 0x00, + 0x1c, 0x00, 0x0d, 0x4b, 0xae, 0x01, 0xf6, 0x18, 0x11, 0x00, 0x30, 0x00, + 0x22, 0x00, 0x00, 0xf0, 0xf1, 0xfb, 0xed, 0xb2, 0x09, 0x49, 0x6d, 0x01, + 0x4d, 0x19, 0x6e, 0x61, 0xab, 0x69, 0x08, 0x4a, 0x20, 0x00, 0x13, 0x40, + 0xab, 0x61, 0xab, 0x69, 0xa2, 0x04, 0x9b, 0x0b, 0x92, 0x0c, 0x9b, 0x03, + 0x13, 0x43, 0xab, 0x61, 0x70, 0xbd, 0xc0, 0x46, 0x80, 0x2a, 0x00, 0x20, + 0x08, 0x2f, 0x00, 0x20, 0xff, 0x3f, 0x00, 0xf0, 0xf7, 0xb5, 0x10, 0x4b, + 0x01, 0x90, 0x1b, 0x78, 0x0f, 0x00, 0x15, 0x00, 0x00, 0x2b, 0x0c, 0xd1, + 0x0d, 0x4b, 0x16, 0x00, 0x1c, 0x78, 0x00, 0x2c, 0x09, 0xd0, 0x0c, 0x4e, + 0x0c, 0x48, 0x34, 0x88, 0x20, 0x18, 0x64, 0x19, 0x00, 0xf0, 0xc4, 0xfb, + 0x34, 0x80, 0x28, 0x00, 0xfe, 0xbd, 0x00, 0x2e, 0xfb, 0xd0, 0x3a, 0x19, + 0x33, 0x00, 0x00, 0x21, 0x01, 0x98, 0xff, 0xf7, 0xbd, 0xff, 0x24, 0x18, + 0x36, 0x1a, 0xf4, 0xe7, 0x00, 0x2e, 0x00, 0x20, 0x01, 0x2f, 0x00, 0x20, + 0x02, 0x2f, 0x00, 0x20, 0x01, 0x2e, 0x00, 0x20, 0xcb, 0xb2, 0x04, 0x49, + 0x5b, 0x01, 0xc9, 0x18, 0x8b, 0x69, 0x9b, 0x0b, 0x9b, 0x03, 0x8b, 0x61, + 0x70, 0x47, 0xc0, 0x46, 0x08, 0x2f, 0x00, 0x20, 0x01, 0x4b, 0x02, 0x4a, + 0x1a, 0x60, 0x70, 0x47, 0x08, 0x2f, 0x00, 0x20, 0x00, 0x50, 0x00, 0x41, + 0x01, 0x20, 0x70, 0x47, 0x10, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, + 0x98, 0x47, 0x10, 0xbd, 0x13, 0x04, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, + 0xd9, 0x69, 0x9a, 0x69, 0x91, 0x42, 0x03, 0xd0, 0xdb, 0x69, 0xc0, 0x18, + 0x00, 0x7d, 0x70, 0x47, 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, 0x10, 0xb5, + 0x04, 0x00, 0x00, 0x69, 0xff, 0xf7, 0xb6, 0xfa, 0x22, 0x00, 0x00, 0x23, + 0xfc, 0x32, 0x93, 0x61, 0xd3, 0x61, 0x86, 0x22, 0x92, 0x00, 0xa4, 0x18, + 0x63, 0x60, 0xa3, 0x60, 0x10, 0xbd, 0xf0, 0x20, 0x01, 0x40, 0x30, 0x39, + 0x48, 0x42, 0x48, 0x41, 0x70, 0x47, 0xf0, 0x23, 0x1b, 0x01, 0x19, 0x40, + 0x80, 0x23, 0x06, 0x20, 0x9b, 0x00, 0x99, 0x42, 0x0a, 0xd0, 0x01, 0x33, + 0xff, 0x33, 0x01, 0x30, 0x99, 0x42, 0x05, 0xd0, 0x80, 0x23, 0x02, 0x38, + 0x5b, 0x00, 0x99, 0x42, 0x00, 0xd0, 0x00, 0x20, 0x70, 0x47, 0x0f, 0x20, + 0x01, 0x40, 0x00, 0x20, 0x01, 0x29, 0x03, 0xd0, 0x02, 0x39, 0x48, 0x1e, + 0x81, 0x41, 0x48, 0x1c, 0x70, 0x47, 0x00, 0x00, 0x89, 0x23, 0xf0, 0xb5, + 0x18, 0x26, 0x85, 0xb0, 0x02, 0x91, 0x9b, 0x00, 0x04, 0x00, 0xc0, 0x5c, + 0x33, 0x00, 0x08, 0x21, 0x43, 0x43, 0x32, 0x4d, 0x17, 0x00, 0xeb, 0x18, + 0x59, 0x56, 0xff, 0xf7, 0x03, 0xf9, 0x30, 0x4b, 0x08, 0x21, 0xe0, 0x5c, + 0x33, 0x00, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, 0xff, 0xf7, 0xfa, 0xf8, + 0x2c, 0x4b, 0xe2, 0x5c, 0x03, 0x93, 0x02, 0x2a, 0x09, 0xd1, 0x11, 0x33, + 0xe0, 0x5c, 0xff, 0x28, 0x05, 0xd0, 0x08, 0x21, 0x46, 0x43, 0xae, 0x19, + 0x71, 0x56, 0xff, 0xf7, 0xeb, 0xf8, 0x8a, 0x26, 0xb6, 0x00, 0xa0, 0x5d, + 0xff, 0x28, 0x19, 0xd0, 0x01, 0x21, 0xff, 0xf7, 0x6b, 0xf8, 0x18, 0x22, + 0xa3, 0x5d, 0x21, 0x49, 0x5a, 0x43, 0xab, 0x56, 0xad, 0x18, 0xdb, 0x01, + 0x58, 0x18, 0x8b, 0x21, 0x89, 0x00, 0x60, 0x50, 0x1d, 0x49, 0x01, 0x22, + 0x5b, 0x18, 0x8c, 0x21, 0x89, 0x00, 0x63, 0x50, 0x69, 0x68, 0x8a, 0x40, + 0x8d, 0x21, 0x89, 0x00, 0x62, 0x50, 0x1a, 0x60, 0x01, 0x22, 0x02, 0x9b, + 0x11, 0x00, 0x20, 0x69, 0xff, 0xf7, 0x2a, 0xfb, 0x39, 0x00, 0x20, 0x00, + 0xff, 0xf7, 0x8f, 0xff, 0x39, 0x00, 0x05, 0x00, 0x20, 0x00, 0xff, 0xf7, + 0x9e, 0xff, 0x39, 0x00, 0x06, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x7f, 0xff, + 0x33, 0x00, 0x00, 0x90, 0x29, 0x00, 0x20, 0x69, 0x01, 0x22, 0xff, 0xf7, + 0xf3, 0xf9, 0x0b, 0x4b, 0x20, 0x69, 0xe2, 0x5c, 0x03, 0x9b, 0xe1, 0x5c, + 0xff, 0xf7, 0x09, 0xfa, 0x20, 0x69, 0xff, 0xf7, 0x26, 0xfa, 0x05, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x88, 0x64, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, + 0x27, 0x02, 0x00, 0x00, 0x18, 0x44, 0x00, 0x41, 0x14, 0x44, 0x00, 0x41, + 0x26, 0x02, 0x00, 0x00, 0x80, 0x22, 0x10, 0xb5, 0x04, 0x00, 0x52, 0x00, + 0x00, 0x21, 0x00, 0xf0, 0xd4, 0xfa, 0x23, 0x00, 0x00, 0x22, 0xfc, 0x33, + 0x5a, 0x60, 0x20, 0x00, 0x9a, 0x60, 0x10, 0xbd, 0xf7, 0xb5, 0x1d, 0x00, + 0x08, 0xab, 0x1b, 0x78, 0x04, 0x00, 0x00, 0x93, 0x09, 0xab, 0x1b, 0x78, + 0x16, 0x00, 0x01, 0x93, 0x00, 0x23, 0x43, 0x60, 0xfa, 0x23, 0x9b, 0x00, + 0x83, 0x60, 0x11, 0x4b, 0x0f, 0x00, 0x08, 0x33, 0x03, 0x60, 0x14, 0x30, + 0xff, 0xf7, 0xdc, 0xff, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, + 0xd7, 0xff, 0x89, 0x23, 0x6a, 0x46, 0x9b, 0x00, 0x27, 0x61, 0xe6, 0x54, + 0x09, 0x4b, 0x12, 0x78, 0xe5, 0x54, 0x09, 0x4b, 0x20, 0x00, 0xe2, 0x54, + 0x6a, 0x46, 0x08, 0x4b, 0x12, 0x79, 0xe2, 0x54, 0x8a, 0x22, 0x29, 0x3b, + 0xff, 0x3b, 0x92, 0x00, 0xa3, 0x54, 0x10, 0x32, 0xa3, 0x54, 0xfe, 0xbd, + 0x4c, 0x68, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, 0x26, 0x02, 0x00, 0x00, + 0x27, 0x02, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, 0x58, 0x68, 0x9b, 0x68, + 0xc0, 0x1a, 0x01, 0xd5, 0x01, 0x30, 0xff, 0x30, 0x70, 0x47, 0x10, 0xb5, + 0x04, 0x00, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0xf0, 0xff, + 0x00, 0x28, 0xf8, 0xd1, 0x20, 0x69, 0xff, 0xf7, 0xc4, 0xf9, 0x10, 0xbd, + 0x10, 0xb5, 0x14, 0x30, 0xff, 0xf7, 0xe6, 0xff, 0x10, 0xbd, 0x03, 0x00, + 0xfc, 0x33, 0x59, 0x68, 0x9a, 0x68, 0x91, 0x42, 0x04, 0xdb, 0x5a, 0x68, + 0x98, 0x68, 0x80, 0x1a, 0xff, 0x30, 0x70, 0x47, 0x98, 0x68, 0x5b, 0x68, + 0xc0, 0x1a, 0x01, 0x38, 0xf9, 0xe7, 0x10, 0xb5, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0xeb, 0xff, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x69, + 0xff, 0xf7, 0xbf, 0xf9, 0x00, 0x28, 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, + 0xca, 0xf9, 0x20, 0x69, 0xff, 0xf7, 0xbc, 0xf9, 0x20, 0x69, 0xff, 0xf7, + 0xa4, 0xf9, 0x00, 0x28, 0x20, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0xbf, 0xf9, + 0x22, 0x00, 0xfc, 0x32, 0x93, 0x69, 0xd1, 0x69, 0x01, 0x33, 0xdb, 0xb2, + 0x8b, 0x42, 0x03, 0xd0, 0x91, 0x69, 0x61, 0x18, 0x08, 0x75, 0x93, 0x61, + 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, 0x20, 0x00, + 0x14, 0x30, 0xff, 0xf7, 0xc0, 0xff, 0x09, 0x28, 0x06, 0xdc, 0x8b, 0x23, + 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, 0x1a, 0x60, + 0x20, 0x69, 0xff, 0xf7, 0x99, 0xf9, 0x00, 0x28, 0x1a, 0xd0, 0x20, 0x00, + 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0x92, 0xff, 0x00, 0x28, 0x22, 0xd0, + 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x99, 0x68, 0x5a, 0x68, 0x91, 0x42, + 0x18, 0xd0, 0x8e, 0x21, 0x9a, 0x68, 0x49, 0x00, 0xa2, 0x18, 0x51, 0x5c, + 0x9a, 0x68, 0x01, 0x32, 0xd2, 0xb2, 0x9a, 0x60, 0xc9, 0xb2, 0x20, 0x69, + 0xff, 0xf7, 0x85, 0xf9, 0x20, 0x69, 0xff, 0xf7, 0x63, 0xf9, 0x00, 0x28, + 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x62, 0xf9, 0x20, 0x69, 0xff, 0xf7, + 0x52, 0xf9, 0x10, 0xbd, 0x01, 0x21, 0x49, 0x42, 0xec, 0xe7, 0x20, 0x69, + 0xff, 0xf7, 0x7f, 0xf9, 0xec, 0xe7, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x00, + 0x00, 0x69, 0x0d, 0x00, 0xff, 0xf7, 0x62, 0xf9, 0x00, 0x28, 0x3e, 0xd1, + 0xff, 0x26, 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x5a, 0x68, 0x99, 0x68, + 0x01, 0x32, 0x32, 0x40, 0x8a, 0x42, 0x23, 0xd1, 0xef, 0xf3, 0x10, 0x83, + 0xdb, 0x07, 0x10, 0xd4, 0x1e, 0x4b, 0x5b, 0x68, 0xdb, 0x05, 0xdb, 0x0d, + 0xed, 0xd0, 0x10, 0x3b, 0x5b, 0xb2, 0x00, 0x2b, 0x10, 0xda, 0x0f, 0x22, + 0x13, 0x40, 0x08, 0x3b, 0x9b, 0x08, 0x19, 0x4a, 0x9b, 0x00, 0x9b, 0x18, + 0x1b, 0x68, 0x20, 0x69, 0xff, 0xf7, 0x3e, 0xf9, 0x00, 0x28, 0xdc, 0xd0, + 0x20, 0x00, 0xff, 0xf7, 0x6a, 0xff, 0xd8, 0xe7, 0x9b, 0x08, 0xc0, 0x33, + 0x12, 0x4a, 0x9b, 0x00, 0x9b, 0x58, 0xf0, 0xe7, 0x5a, 0x68, 0x01, 0x32, + 0x16, 0x40, 0x9a, 0x68, 0x96, 0x42, 0x05, 0xd0, 0x8e, 0x21, 0x5a, 0x68, + 0x49, 0x00, 0xa2, 0x18, 0x55, 0x54, 0x5e, 0x60, 0x20, 0x69, 0xff, 0xf7, + 0x34, 0xf9, 0x01, 0x20, 0x70, 0xbd, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0x1c, 0xff, 0x00, 0x28, 0xb9, 0xd1, 0x29, 0x00, 0x20, 0x69, + 0xff, 0xf7, 0x1f, 0xf9, 0xf1, 0xe7, 0xc0, 0x46, 0x00, 0xed, 0x00, 0xe0, + 0x1c, 0xed, 0x00, 0xe0, 0x00, 0xe1, 0x00, 0xe0, 0x03, 0x00, 0x70, 0xb5, + 0xfc, 0x33, 0xd9, 0x69, 0x9a, 0x69, 0x04, 0x00, 0x91, 0x42, 0x1a, 0xd0, + 0xda, 0x69, 0x82, 0x18, 0x15, 0x7d, 0xda, 0x69, 0x01, 0x32, 0xd2, 0xb2, + 0xda, 0x61, 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, + 0x20, 0x00, 0x14, 0x30, 0xff, 0xf7, 0x11, 0xff, 0x0a, 0x28, 0x06, 0xdd, + 0x8c, 0x23, 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, + 0x1a, 0x60, 0x28, 0x00, 0x70, 0xbd, 0x01, 0x25, 0x6d, 0x42, 0xe8, 0xe7, + 0x10, 0xb5, 0x04, 0x00, 0x00, 0x68, 0x00, 0xf0, 0x63, 0xf9, 0x20, 0x00, + 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x68, 0x00, 0x28, 0x01, 0xd0, + 0x00, 0xf0, 0x5a, 0xf9, 0x00, 0x23, 0x23, 0x60, 0xa3, 0x60, 0x63, 0x60, + 0x10, 0xbd, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x00, 0x68, 0x01, 0x31, + 0x00, 0xf0, 0x12, 0xfa, 0x03, 0x1e, 0x01, 0xd0, 0x01, 0x20, 0x28, 0xc4, + 0x70, 0xbd, 0x03, 0x68, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x2b, 0x04, 0xd0, + 0x43, 0x68, 0x8b, 0x42, 0x01, 0xd3, 0x01, 0x20, 0x10, 0xbd, 0x20, 0x00, + 0xff, 0xf7, 0xe7, 0xff, 0x00, 0x28, 0xf9, 0xd0, 0xa3, 0x68, 0x00, 0x2b, + 0xf5, 0xd1, 0x22, 0x68, 0x13, 0x70, 0xf2, 0xe7, 0x70, 0xb5, 0x0e, 0x00, + 0x11, 0x00, 0x04, 0x00, 0x15, 0x00, 0xff, 0xf7, 0xe4, 0xff, 0x00, 0x28, + 0x04, 0xd1, 0x20, 0x00, 0xff, 0xf7, 0xc7, 0xff, 0x20, 0x00, 0x70, 0xbd, + 0xa5, 0x60, 0x31, 0x00, 0x20, 0x68, 0x00, 0xf0, 0x0b, 0xfa, 0xf7, 0xe7, + 0x00, 0x23, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x03, 0x60, 0x43, 0x60, + 0x83, 0x60, 0x99, 0x42, 0x07, 0xd0, 0x08, 0x00, 0x00, 0xf0, 0x06, 0xfa, + 0x29, 0x00, 0x02, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xdb, 0xff, 0x20, 0x00, + 0x70, 0xbd, 0x70, 0xb5, 0x05, 0x00, 0x08, 0x00, 0x0c, 0x00, 0x00, 0xf0, + 0xf9, 0xf9, 0x21, 0x00, 0x02, 0x00, 0x28, 0x00, 0xff, 0xf7, 0xce, 0xff, + 0x70, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x29, 0x03, 0xd0, 0xff, 0xf7, + 0xee, 0xff, 0x20, 0x00, 0x10, 0xbd, 0xff, 0xf7, 0x96, 0xff, 0xfa, 0xe7, + 0x02, 0x68, 0x10, 0xb5, 0x0b, 0x68, 0x00, 0x2a, 0x13, 0xd0, 0x00, 0x2b, + 0x0c, 0xd1, 0x81, 0x68, 0x18, 0x00, 0x00, 0x29, 0x07, 0xd0, 0x10, 0x78, + 0x05, 0xe0, 0x89, 0x68, 0x10, 0x00, 0x00, 0x29, 0x01, 0xd0, 0x18, 0x78, + 0x40, 0x42, 0x10, 0xbd, 0x19, 0x00, 0x10, 0x00, 0x00, 0xf0, 0xbe, 0xf9, + 0xf9, 0xe7, 0x00, 0x2b, 0xf1, 0xd1, 0x18, 0x00, 0xf5, 0xe7, 0x10, 0xb5, + 0xff, 0xf7, 0xe0, 0xff, 0xc0, 0x0f, 0x10, 0xbd, 0x10, 0xb5, 0x00, 0xf0, + 0xd1, 0xf8, 0x10, 0xbd, 0x0b, 0x00, 0x10, 0xb5, 0x01, 0x00, 0x18, 0x00, + 0x00, 0xf0, 0x98, 0xf8, 0x10, 0xbd, 0x00, 0x00, 0x02, 0xb4, 0x71, 0x46, + 0x49, 0x08, 0x49, 0x00, 0x09, 0x5c, 0x49, 0x00, 0x8e, 0x44, 0x02, 0xbc, + 0x70, 0x47, 0xc0, 0x46, 0x00, 0x22, 0x43, 0x08, 0x8b, 0x42, 0x74, 0xd3, + 0x03, 0x09, 0x8b, 0x42, 0x5f, 0xd3, 0x03, 0x0a, 0x8b, 0x42, 0x44, 0xd3, + 0x03, 0x0b, 0x8b, 0x42, 0x28, 0xd3, 0x03, 0x0c, 0x8b, 0x42, 0x0d, 0xd3, + 0xff, 0x22, 0x09, 0x02, 0x12, 0xba, 0x03, 0x0c, 0x8b, 0x42, 0x02, 0xd3, + 0x12, 0x12, 0x09, 0x02, 0x65, 0xd0, 0x03, 0x0b, 0x8b, 0x42, 0x19, 0xd3, + 0x00, 0xe0, 0x09, 0x0a, 0xc3, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x03, + 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x03, + 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x03, + 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x03, + 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x02, + 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x02, + 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x02, + 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x02, + 0xc0, 0x1a, 0x52, 0x41, 0xcd, 0xd2, 0xc3, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0xcb, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0x8b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0x4b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0x0b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x08, 0x8b, 0x42, 0x01, 0xd3, + 0xcb, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x08, 0x8b, 0x42, 0x01, 0xd3, + 0x8b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x08, 0x8b, 0x42, 0x01, 0xd3, + 0x4b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x41, 0x1a, 0x00, 0xd2, 0x01, 0x46, + 0x52, 0x41, 0x10, 0x46, 0x70, 0x47, 0xff, 0xe7, 0x01, 0xb5, 0x00, 0x20, + 0x00, 0xf0, 0x06, 0xf8, 0x02, 0xbd, 0xc0, 0x46, 0x00, 0x29, 0xf7, 0xd0, + 0x76, 0xe7, 0x70, 0x47, 0x70, 0x47, 0xc0, 0x46, 0x10, 0xb5, 0x04, 0x00, + 0x04, 0x48, 0x13, 0x00, 0x00, 0x28, 0x04, 0xd0, 0x0a, 0x00, 0x02, 0x20, + 0x21, 0x00, 0x00, 0xe0, 0x00, 0xbf, 0x10, 0xbd, 0x00, 0x00, 0x00, 0x00, + 0x70, 0xb5, 0x00, 0x26, 0x0c, 0x4d, 0x0d, 0x4c, 0x64, 0x1b, 0xa4, 0x10, + 0xa6, 0x42, 0x09, 0xd1, 0x00, 0x26, 0x00, 0xf0, 0x51, 0xf9, 0x0a, 0x4d, + 0x0a, 0x4c, 0x64, 0x1b, 0xa4, 0x10, 0xa6, 0x42, 0x05, 0xd1, 0x70, 0xbd, + 0xb3, 0x00, 0xeb, 0x58, 0x98, 0x47, 0x01, 0x36, 0xee, 0xe7, 0xb3, 0x00, + 0xeb, 0x58, 0x98, 0x47, 0x01, 0x36, 0xf2, 0xe7, 0x90, 0x00, 0x00, 0x20, + 0x90, 0x00, 0x00, 0x20, 0x90, 0x00, 0x00, 0x20, 0xe8, 0x00, 0x00, 0x20, + 0x10, 0xb5, 0x03, 0x4b, 0x01, 0x00, 0x18, 0x68, 0x00, 0xf0, 0x16, 0xf8, + 0x10, 0xbd, 0xc0, 0x46, 0x2c, 0x00, 0x00, 0x20, 0x00, 0x23, 0x10, 0xb5, + 0x9a, 0x42, 0x00, 0xd1, 0x10, 0xbd, 0xcc, 0x5c, 0xc4, 0x54, 0x01, 0x33, + 0xf8, 0xe7, 0x03, 0x00, 0x12, 0x18, 0x93, 0x42, 0x00, 0xd1, 0x70, 0x47, + 0x19, 0x70, 0x01, 0x33, 0xf9, 0xe7, 0x00, 0x00, 0x70, 0xb5, 0x05, 0x00, + 0x00, 0x29, 0x10, 0xd0, 0x0c, 0x1f, 0x23, 0x68, 0x00, 0x2b, 0x00, 0xda, + 0xe4, 0x18, 0x28, 0x00, 0x00, 0xf0, 0xd1, 0xf8, 0x1d, 0x4a, 0x13, 0x68, + 0x00, 0x2b, 0x05, 0xd1, 0x63, 0x60, 0x14, 0x60, 0x28, 0x00, 0x00, 0xf0, + 0xc9, 0xf8, 0x70, 0xbd, 0xa3, 0x42, 0x09, 0xd9, 0x21, 0x68, 0x60, 0x18, + 0x83, 0x42, 0xf3, 0xd1, 0x18, 0x68, 0x5b, 0x68, 0x41, 0x18, 0x21, 0x60, + 0xee, 0xe7, 0x13, 0x00, 0x5a, 0x68, 0x00, 0x2a, 0x01, 0xd0, 0xa2, 0x42, + 0xf9, 0xd9, 0x19, 0x68, 0x58, 0x18, 0xa0, 0x42, 0x0b, 0xd1, 0x20, 0x68, + 0x09, 0x18, 0x58, 0x18, 0x19, 0x60, 0x82, 0x42, 0xe0, 0xd1, 0x10, 0x68, + 0x52, 0x68, 0x41, 0x18, 0x19, 0x60, 0x5a, 0x60, 0xda, 0xe7, 0xa0, 0x42, + 0x02, 0xd9, 0x0c, 0x23, 0x2b, 0x60, 0xd5, 0xe7, 0x21, 0x68, 0x60, 0x18, + 0x82, 0x42, 0x03, 0xd1, 0x10, 0x68, 0x52, 0x68, 0x41, 0x18, 0x21, 0x60, + 0x62, 0x60, 0x5c, 0x60, 0xca, 0xe7, 0xc0, 0x46, 0x0c, 0x30, 0x00, 0x20, + 0x03, 0x23, 0x70, 0xb5, 0xcd, 0x1c, 0x9d, 0x43, 0x08, 0x35, 0x06, 0x00, + 0x0c, 0x2d, 0x1e, 0xd2, 0x0c, 0x25, 0xa9, 0x42, 0x1d, 0xd8, 0x30, 0x00, + 0x00, 0xf0, 0x85, 0xf8, 0x25, 0x4a, 0x14, 0x68, 0x21, 0x00, 0x00, 0x29, + 0x19, 0xd1, 0x24, 0x4c, 0x23, 0x68, 0x00, 0x2b, 0x03, 0xd1, 0x30, 0x00, + 0x00, 0xf0, 0x4e, 0xf8, 0x20, 0x60, 0x29, 0x00, 0x30, 0x00, 0x00, 0xf0, + 0x49, 0xf8, 0x43, 0x1c, 0x2b, 0xd1, 0x0c, 0x23, 0x30, 0x00, 0x33, 0x60, + 0x00, 0xf0, 0x6e, 0xf8, 0x03, 0xe0, 0x00, 0x2d, 0xdf, 0xda, 0x0c, 0x23, + 0x33, 0x60, 0x00, 0x20, 0x70, 0xbd, 0x0b, 0x68, 0x5b, 0x1b, 0x19, 0xd4, + 0x0b, 0x2b, 0x03, 0xd9, 0x0b, 0x60, 0xcc, 0x18, 0x25, 0x60, 0x03, 0xe0, + 0x4b, 0x68, 0x8c, 0x42, 0x0d, 0xd1, 0x13, 0x60, 0x30, 0x00, 0x00, 0xf0, + 0x57, 0xf8, 0x20, 0x00, 0x07, 0x22, 0x0b, 0x30, 0x23, 0x1d, 0x90, 0x43, + 0xc3, 0x1a, 0xe7, 0xd0, 0x5a, 0x42, 0xe2, 0x50, 0xe4, 0xe7, 0x63, 0x60, + 0x0c, 0x00, 0xef, 0xe7, 0x0c, 0x00, 0x49, 0x68, 0xc3, 0xe7, 0x03, 0x23, + 0xc4, 0x1c, 0x9c, 0x43, 0xa0, 0x42, 0xe1, 0xd0, 0x21, 0x1a, 0x30, 0x00, + 0x00, 0xf0, 0x12, 0xf8, 0x43, 0x1c, 0xdb, 0xd1, 0xc7, 0xe7, 0xc0, 0x46, + 0x0c, 0x30, 0x00, 0x20, 0x10, 0x30, 0x00, 0x20, 0x10, 0xb5, 0x03, 0x4b, + 0x0a, 0x00, 0x01, 0x00, 0x18, 0x68, 0x00, 0xf0, 0x30, 0xf8, 0x10, 0xbd, + 0x2c, 0x00, 0x00, 0x20, 0x00, 0x23, 0x70, 0xb5, 0x06, 0x4c, 0x05, 0x00, + 0x08, 0x00, 0x23, 0x60, 0x00, 0xf0, 0x54, 0xf8, 0x43, 0x1c, 0x03, 0xd1, + 0x23, 0x68, 0x00, 0x2b, 0x00, 0xd0, 0x2b, 0x60, 0x70, 0xbd, 0xc0, 0x46, + 0x18, 0x30, 0x00, 0x20, 0x02, 0x78, 0x0b, 0x78, 0x00, 0x2a, 0x03, 0xd0, + 0x01, 0x30, 0x01, 0x31, 0x9a, 0x42, 0xf7, 0xd0, 0xd0, 0x1a, 0x70, 0x47, + 0x03, 0x00, 0x0a, 0x78, 0x01, 0x31, 0x1a, 0x70, 0x01, 0x33, 0x00, 0x2a, + 0xf9, 0xd1, 0x70, 0x47, 0x00, 0x23, 0xc2, 0x5c, 0x01, 0x33, 0x00, 0x2a, + 0xfb, 0xd1, 0x58, 0x1e, 0x70, 0x47, 0x70, 0x47, 0x70, 0x47, 0xf8, 0xb5, + 0x07, 0x00, 0x0d, 0x00, 0x16, 0x00, 0x00, 0x29, 0x05, 0xd1, 0x11, 0x00, + 0xff, 0xf7, 0x62, 0xff, 0x04, 0x00, 0x20, 0x00, 0xf8, 0xbd, 0x00, 0x2a, + 0x03, 0xd1, 0xff, 0xf7, 0x11, 0xff, 0x34, 0x00, 0xf7, 0xe7, 0x00, 0xf0, + 0x12, 0xf8, 0x2c, 0x00, 0xb0, 0x42, 0xf2, 0xd2, 0x31, 0x00, 0x38, 0x00, + 0xff, 0xf7, 0x50, 0xff, 0x04, 0x1e, 0xec, 0xd0, 0x29, 0x00, 0x32, 0x00, + 0xff, 0xf7, 0xee, 0xfe, 0x29, 0x00, 0x38, 0x00, 0xff, 0xf7, 0xfc, 0xfe, + 0xe3, 0xe7, 0x0b, 0x1f, 0x1b, 0x68, 0x18, 0x1f, 0x00, 0x2b, 0x01, 0xda, + 0x0b, 0x58, 0xc0, 0x18, 0x70, 0x47, 0x00, 0x00, 0x04, 0x4a, 0x13, 0x68, + 0x00, 0x2b, 0x00, 0xd1, 0x03, 0x4b, 0x18, 0x18, 0x10, 0x60, 0x18, 0x00, + 0x70, 0x47, 0xc0, 0x46, 0x14, 0x30, 0x00, 0x20, 0x1c, 0x30, 0x00, 0x20, + 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, + 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, + 0x31, 0x2e, 0x34, 0x2e, 0x31, 0x00, 0x2f, 0x66, 0x73, 0x2f, 0x55, 0x50, + 0x44, 0x41, 0x54, 0x45, 0x2e, 0x42, 0x49, 0x4e, 0x2e, 0x4c, 0x5a, 0x53, + 0x53, 0x00, 0x2f, 0x66, 0x73, 0x2f, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, + 0x2e, 0x42, 0x49, 0x4e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00 diff --git a/libraries/SNU/src/boot/mkrwifi1010.h b/libraries/SNU/src/boot/mkrwifi1010.h new file mode 100644 index 0000000..c43f925 --- /dev/null +++ b/libraries/SNU/src/boot/mkrwifi1010.h @@ -0,0 +1,1245 @@ + 0x00, 0x80, 0x00, 0x20, 0x41, 0x2f, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, + 0x29, 0x2f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, + 0x95, 0x2f, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, + 0x29, 0x2f, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, + 0x29, 0x2f, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, 0x2d, 0x2f, 0x00, 0x00, + 0x29, 0x2f, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, + 0x29, 0x2f, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, 0x79, 0x2e, 0x00, 0x00, + 0x69, 0x2e, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, + 0x29, 0x2f, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, + 0x29, 0x2f, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, + 0x29, 0x2f, 0x00, 0x00, 0x29, 0x2f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0xe0, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0x78, 0x59, 0x00, 0x00, 0x04, 0x4b, 0x10, 0xb5, 0x00, 0x2b, 0x03, 0xd0, + 0x03, 0x49, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x10, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x00, 0xe4, 0x00, 0x00, 0x20, 0x78, 0x59, 0x00, 0x00, + 0x1f, 0xb5, 0x14, 0x00, 0x04, 0x22, 0x00, 0x23, 0x01, 0x92, 0x03, 0xaa, + 0x00, 0x92, 0x0a, 0x00, 0x01, 0x00, 0x63, 0x20, 0x03, 0x93, 0x00, 0xf0, + 0xf1, 0xfc, 0x03, 0x98, 0x20, 0x60, 0xc0, 0x43, 0xc0, 0x0f, 0x40, 0xb2, + 0x04, 0xb0, 0x10, 0xbd, 0x13, 0xb5, 0x04, 0x00, 0x02, 0xf0, 0xe6, 0xfc, + 0x01, 0xaa, 0xc1, 0xb2, 0x20, 0x00, 0xff, 0xf7, 0xe3, 0xff, 0xc3, 0x17, + 0x18, 0x1a, 0xc0, 0x0f, 0x16, 0xbd, 0xf0, 0xb5, 0x06, 0x68, 0x43, 0x68, + 0x85, 0xb0, 0x14, 0x00, 0xb2, 0x18, 0x05, 0x00, 0x03, 0x91, 0x9a, 0x42, + 0x03, 0xd9, 0x00, 0x24, 0x9e, 0x42, 0x10, 0xd2, 0x9c, 0x1b, 0xaf, 0x68, + 0x38, 0x00, 0x02, 0xf0, 0xcb, 0xfc, 0x03, 0x9b, 0xc2, 0xb2, 0x00, 0x93, + 0x01, 0x94, 0x33, 0x00, 0x39, 0x00, 0x61, 0x20, 0x00, 0xf0, 0xc2, 0xfc, + 0x2b, 0x68, 0x1b, 0x19, 0x2b, 0x60, 0x20, 0x00, 0x05, 0xb0, 0xf0, 0xbd, + 0x70, 0xb5, 0x85, 0x68, 0x04, 0x00, 0x28, 0x00, 0x02, 0xf0, 0xb6, 0xfc, + 0x22, 0x1d, 0xc1, 0xb2, 0x28, 0x00, 0xff, 0xf7, 0xb3, 0xff, 0x60, 0x68, + 0x70, 0xbd, 0x37, 0xb5, 0x00, 0x24, 0x85, 0x68, 0x04, 0x60, 0x28, 0x00, + 0x02, 0xf0, 0xa8, 0xfc, 0x29, 0x00, 0xc2, 0xb2, 0x01, 0x94, 0x00, 0x94, + 0x23, 0x00, 0x62, 0x20, 0x00, 0xf0, 0xa0, 0xfc, 0x37, 0xbd, 0x00, 0x00, + 0x30, 0xb5, 0xff, 0x25, 0x06, 0x4c, 0x8a, 0x18, 0x91, 0x42, 0x08, 0xd0, + 0x0b, 0x78, 0x01, 0x31, 0x43, 0x40, 0x2b, 0x40, 0x9b, 0x00, 0x1b, 0x59, + 0x00, 0x0a, 0x58, 0x40, 0xf4, 0xe7, 0x30, 0xbd, 0x9c, 0x4b, 0x00, 0x00, + 0xf0, 0xb5, 0x0c, 0x24, 0xaf, 0xb0, 0x00, 0xaf, 0x00, 0xf0, 0xea, 0xff, + 0x02, 0xf0, 0x6e, 0xfb, 0x01, 0x20, 0x00, 0xf0, 0x0d, 0xff, 0x01, 0x21, + 0x1e, 0x20, 0x01, 0xf0, 0x8b, 0xf8, 0x01, 0x21, 0x1e, 0x20, 0x01, 0xf0, + 0xd3, 0xf8, 0x01, 0x21, 0x1f, 0x20, 0x01, 0xf0, 0x83, 0xf8, 0x01, 0x21, + 0x1f, 0x20, 0x01, 0xf0, 0xcb, 0xf8, 0x78, 0x49, 0x38, 0x19, 0x02, 0xf0, + 0x5f, 0xfa, 0x77, 0x48, 0x00, 0xf0, 0x20, 0xfa, 0xff, 0x28, 0x00, 0xd1, + 0x96, 0xe0, 0x00, 0xf0, 0x17, 0xfa, 0x08, 0x26, 0x30, 0x25, 0x01, 0x00, + 0x38, 0x19, 0x02, 0xf0, 0x70, 0xfa, 0xbb, 0x19, 0x70, 0x49, 0x58, 0x19, + 0x02, 0xf0, 0x4c, 0xfa, 0xbb, 0x19, 0x59, 0x19, 0x38, 0x19, 0x02, 0xf0, + 0x8e, 0xfa, 0xbb, 0x19, 0x04, 0x00, 0x58, 0x19, 0x02, 0xf0, 0xfa, 0xf9, + 0x00, 0x2c, 0x7d, 0xd1, 0x69, 0x4d, 0x28, 0x68, 0xff, 0xf7, 0x60, 0xff, + 0x00, 0x28, 0x00, 0xd1, 0x88, 0xe0, 0x29, 0x68, 0x08, 0x25, 0xb6, 0x19, + 0x7b, 0x19, 0x98, 0x19, 0x00, 0xf0, 0x47, 0xfa, 0x1c, 0x23, 0x79, 0x19, + 0x78, 0x19, 0xc9, 0x18, 0x14, 0x22, 0x80, 0x19, 0xff, 0xf7, 0x5b, 0xff, + 0x08, 0x23, 0xfb, 0x18, 0x98, 0x19, 0x7d, 0x6a, 0xff, 0xf7, 0x76, 0xff, + 0x08, 0x38, 0x85, 0x42, 0x06, 0xd0, 0x00, 0x23, 0xbb, 0x61, 0x10, 0x33, + 0x08, 0x22, 0xba, 0x18, 0xd0, 0x18, 0x55, 0xe0, 0x08, 0x23, 0x01, 0x25, + 0xbb, 0x61, 0x6d, 0x42, 0x7a, 0x6a, 0x13, 0x00, 0x80, 0x3b, 0xa3, 0x42, + 0x13, 0xd9, 0x08, 0x20, 0x30, 0x26, 0x3b, 0x18, 0x99, 0x19, 0x10, 0x23, + 0x38, 0x18, 0x80, 0x22, 0xc0, 0x18, 0xff, 0xf7, 0x38, 0xff, 0x08, 0x20, + 0x3b, 0x18, 0x80, 0x22, 0x28, 0x00, 0x99, 0x19, 0xff, 0xf7, 0x70, 0xff, + 0x80, 0x34, 0x05, 0x00, 0xe6, 0xe7, 0x08, 0x20, 0x30, 0x26, 0x3b, 0x18, + 0x99, 0x19, 0x10, 0x23, 0x38, 0x18, 0x12, 0x1b, 0xc0, 0x18, 0xff, 0xf7, + 0x24, 0xff, 0x08, 0x20, 0x7b, 0x6a, 0x1a, 0x1b, 0x3b, 0x18, 0x99, 0x19, + 0x28, 0x00, 0xff, 0xf7, 0x5b, 0xff, 0xc0, 0x43, 0xbb, 0x6a, 0x83, 0x42, + 0xc5, 0xd1, 0x3e, 0x4b, 0xfa, 0x6a, 0x9a, 0x42, 0xc1, 0xd1, 0xe8, 0x22, + 0xc0, 0x21, 0x14, 0x23, 0x08, 0x25, 0x10, 0x24, 0x92, 0x02, 0xc9, 0x01, + 0x39, 0x48, 0xbb, 0x61, 0x00, 0xf0, 0xc8, 0xfc, 0x7b, 0x19, 0x18, 0x19, + 0xff, 0xf7, 0x26, 0xff, 0xc0, 0x21, 0x02, 0x00, 0x7b, 0x19, 0x18, 0x19, + 0x14, 0x3a, 0xc9, 0x01, 0x00, 0xf0, 0x84, 0xf8, 0x00, 0xf0, 0x3a, 0xf9, + 0x00, 0xf0, 0x92, 0xf8, 0x00, 0x23, 0xbb, 0x61, 0x7b, 0x19, 0x18, 0x19, + 0xff, 0xf7, 0x21, 0xff, 0xc0, 0x23, 0xdb, 0x01, 0x1a, 0x68, 0x82, 0xf3, + 0x08, 0x88, 0x2b, 0x4a, 0x93, 0x60, 0x2b, 0x4b, 0x1b, 0x68, 0x18, 0x47, + 0x0c, 0x23, 0xf8, 0x18, 0x02, 0xf0, 0x6c, 0xf9, 0x00, 0x20, 0xbd, 0x46, + 0x2f, 0xb0, 0xf0, 0xbd, 0x26, 0x4c, 0x20, 0x68, 0xff, 0xf7, 0xd0, 0xfe, + 0x00, 0x28, 0xe7, 0xd0, 0x08, 0x25, 0x21, 0x68, 0x1c, 0x24, 0x7b, 0x19, + 0x18, 0x19, 0x00, 0xf0, 0xb8, 0xf9, 0x7b, 0x19, 0x18, 0x19, 0xff, 0xf7, + 0xf1, 0xfe, 0x80, 0x23, 0xdb, 0x01, 0x98, 0x42, 0xd8, 0xd9, 0xc0, 0x21, + 0x7b, 0x62, 0x1c, 0x4b, 0xc9, 0x01, 0xc4, 0x18, 0x22, 0x00, 0x16, 0x48, + 0xc0, 0x25, 0x00, 0xf0, 0x81, 0xfc, 0x80, 0x26, 0xed, 0x01, 0x08, 0x21, + 0x30, 0x23, 0x78, 0x18, 0xc1, 0x18, 0x1c, 0x20, 0x28, 0x3b, 0xfb, 0x18, + 0x32, 0x00, 0x18, 0x18, 0xff, 0xf7, 0xb5, 0xfe, 0x08, 0x21, 0x30, 0x22, + 0x79, 0x18, 0x33, 0x00, 0x8a, 0x18, 0x0b, 0x48, 0x29, 0x00, 0x00, 0xf0, + 0x1b, 0xfc, 0x0e, 0x4b, 0xeb, 0x18, 0x80, 0x35, 0x9c, 0x42, 0xe6, 0xd8, + 0x00, 0x23, 0x7b, 0x62, 0x1c, 0x33, 0x53, 0xe7, 0xa1, 0x4f, 0x00, 0x00, + 0xcc, 0x11, 0x00, 0x20, 0x9c, 0x4f, 0x00, 0x00, 0x08, 0x00, 0x00, 0x20, + 0x54, 0x80, 0x41, 0x23, 0x04, 0x01, 0x00, 0x20, 0x00, 0xed, 0x00, 0xe0, + 0x04, 0x60, 0x00, 0x00, 0x04, 0x00, 0x00, 0x20, 0x00, 0xc0, 0xff, 0xff, + 0x80, 0xa0, 0xff, 0xff, 0x13, 0xb5, 0x00, 0x24, 0x06, 0x48, 0x23, 0x00, + 0x22, 0x00, 0x21, 0x00, 0x00, 0x94, 0x01, 0xf0, 0x81, 0xf8, 0x22, 0x00, + 0x21, 0x00, 0x03, 0x48, 0x00, 0xf0, 0xd6, 0xfb, 0x13, 0xbd, 0xc0, 0x46, + 0xfc, 0x00, 0x00, 0x20, 0x04, 0x01, 0x00, 0x20, 0x04, 0x4b, 0x19, 0x60, + 0x04, 0x4b, 0x19, 0x60, 0x04, 0x4b, 0x18, 0x60, 0x04, 0x4b, 0x1a, 0x60, + 0x70, 0x47, 0xc0, 0x46, 0x2c, 0x01, 0x00, 0x20, 0x1c, 0x01, 0x00, 0x20, + 0x28, 0x01, 0x00, 0x20, 0x30, 0x01, 0x00, 0x20, 0x0c, 0x49, 0x70, 0xb5, + 0x0c, 0x4c, 0x0a, 0x68, 0x23, 0x68, 0x0c, 0x48, 0x9a, 0x18, 0x0a, 0x60, + 0x0b, 0x49, 0x09, 0x68, 0x09, 0x18, 0x8a, 0x42, 0x09, 0xd9, 0x0a, 0x4d, + 0x0a, 0x4a, 0x29, 0x68, 0x0a, 0x48, 0x00, 0xf0, 0xc3, 0xfb, 0x2b, 0x68, + 0x22, 0x68, 0x9b, 0x18, 0x2b, 0x60, 0x00, 0x23, 0x23, 0x60, 0x70, 0xbd, + 0x34, 0x01, 0x00, 0x20, 0x38, 0x01, 0x00, 0x20, 0x00, 0xe0, 0xff, 0xff, + 0x2c, 0x01, 0x00, 0x20, 0x1c, 0x01, 0x00, 0x20, 0x3c, 0x01, 0x00, 0x20, + 0x04, 0x01, 0x00, 0x20, 0x05, 0x4a, 0x06, 0x49, 0x13, 0x68, 0x10, 0xb5, + 0xc8, 0x54, 0x01, 0x33, 0x13, 0x60, 0x40, 0x2b, 0x01, 0xd1, 0xff, 0xf7, + 0xcd, 0xff, 0x10, 0xbd, 0x38, 0x01, 0x00, 0x20, 0x3c, 0x01, 0x00, 0x20, + 0xf0, 0xb5, 0x1e, 0x4b, 0x1e, 0x4f, 0x1b, 0x68, 0x3a, 0x68, 0x85, 0xb0, + 0x9a, 0x42, 0x32, 0xd0, 0x1c, 0x4d, 0x2e, 0x68, 0x40, 0x2e, 0x24, 0xd1, + 0x1b, 0x4b, 0x1c, 0x68, 0x23, 0x68, 0x02, 0x93, 0x02, 0x99, 0x63, 0x68, + 0x40, 0x31, 0x99, 0x42, 0x04, 0xd9, 0x02, 0x9a, 0x00, 0x26, 0x9a, 0x42, + 0x11, 0xd2, 0x9e, 0x1a, 0xa3, 0x68, 0x18, 0x00, 0x03, 0x93, 0x02, 0xf0, + 0xed, 0xfa, 0x13, 0x4b, 0xc2, 0xb2, 0x00, 0x93, 0x01, 0x96, 0x02, 0x9b, + 0x03, 0x99, 0x61, 0x20, 0x00, 0xf0, 0xe4, 0xfa, 0x23, 0x68, 0x9b, 0x19, + 0x23, 0x60, 0x0e, 0x4a, 0x13, 0x68, 0x9b, 0x19, 0x13, 0x60, 0x00, 0x23, + 0x2b, 0x60, 0x2b, 0x68, 0x09, 0x4a, 0xd0, 0x5c, 0x01, 0x33, 0x2b, 0x60, + 0x3b, 0x68, 0x01, 0x33, 0x3b, 0x60, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x20, + 0x40, 0x42, 0xfa, 0xe7, 0x30, 0x01, 0x00, 0x20, 0x7c, 0x01, 0x00, 0x20, + 0x0c, 0x00, 0x00, 0x20, 0x28, 0x01, 0x00, 0x20, 0x84, 0x01, 0x00, 0x20, + 0x80, 0x01, 0x00, 0x20, 0xf7, 0xb5, 0x00, 0x24, 0x26, 0x00, 0x01, 0x90, + 0x01, 0x9b, 0x9e, 0x42, 0x16, 0xda, 0x0c, 0x4d, 0x0c, 0x4f, 0x2b, 0x68, + 0x00, 0x2b, 0x06, 0xd1, 0xff, 0xf7, 0xa8, 0xff, 0x38, 0x60, 0x43, 0x1c, + 0x0d, 0xd0, 0x80, 0x23, 0x2b, 0x60, 0x2a, 0x68, 0x3b, 0x68, 0x64, 0x00, + 0x13, 0x40, 0x59, 0x1e, 0x8b, 0x41, 0x52, 0x10, 0xe4, 0x18, 0x2a, 0x60, + 0x01, 0x36, 0xe5, 0xe7, 0x20, 0x00, 0xfe, 0xbd, 0xc8, 0x01, 0x00, 0x20, + 0xc4, 0x01, 0x00, 0x20, 0xf7, 0xb5, 0x00, 0x24, 0x20, 0x22, 0x1e, 0x4d, + 0x1e, 0x4b, 0x2a, 0x55, 0x01, 0x34, 0x9c, 0x42, 0xfb, 0xd1, 0x01, 0x20, + 0xff, 0xf7, 0xd0, 0xff, 0x43, 0x1c, 0x30, 0xd0, 0x00, 0x28, 0x0c, 0xd0, + 0x08, 0x20, 0xff, 0xf7, 0xc9, 0xff, 0x06, 0x00, 0x43, 0x1c, 0x28, 0xd0, + 0xff, 0xf7, 0x6a, 0xff, 0x63, 0x1c, 0x2e, 0x55, 0x5c, 0x05, 0x64, 0x0d, + 0xeb, 0xe7, 0x0b, 0x20, 0xff, 0xf7, 0xbc, 0xff, 0x06, 0x00, 0x43, 0x1c, + 0x1b, 0xd0, 0x04, 0x20, 0xff, 0xf7, 0xb6, 0xff, 0x03, 0x00, 0x01, 0x90, + 0x01, 0x33, 0x14, 0xd0, 0x37, 0x00, 0x01, 0x9b, 0xba, 0x1b, 0x01, 0x33, + 0x93, 0x42, 0xd8, 0xdb, 0x7b, 0x05, 0x5b, 0x0d, 0xeb, 0x5c, 0x01, 0x37, + 0x18, 0x00, 0x00, 0x93, 0xff, 0xf7, 0x4a, 0xff, 0x6a, 0x46, 0x12, 0x78, + 0x63, 0x1c, 0x2a, 0x55, 0x5c, 0x05, 0x64, 0x0d, 0xeb, 0xe7, 0xf7, 0xbd, + 0xcc, 0x01, 0x00, 0x20, 0xef, 0x07, 0x00, 0x00, 0x07, 0xb5, 0x00, 0x21, + 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, 0x00, 0xf0, 0x72, 0xff, + 0x07, 0xbd, 0xc0, 0x46, 0x20, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x00, 0xf0, + 0x23, 0xfa, 0x10, 0xbd, 0x10, 0xb5, 0x00, 0xf0, 0xf7, 0xf9, 0x10, 0xbd, + 0x07, 0xb5, 0x00, 0x21, 0x04, 0x48, 0x0b, 0x00, 0x0a, 0x00, 0x00, 0x91, + 0x00, 0xf0, 0x5e, 0xff, 0x02, 0x4b, 0x03, 0x4a, 0x1a, 0x60, 0x07, 0xbd, + 0xd0, 0x11, 0x00, 0x20, 0xcc, 0x11, 0x00, 0x20, 0x50, 0xc3, 0x00, 0x00, + 0x07, 0xb5, 0x00, 0x21, 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, + 0x00, 0xf0, 0x4c, 0xff, 0x07, 0xbd, 0xc0, 0x46, 0xd8, 0x11, 0x00, 0x20, + 0x07, 0xb5, 0x00, 0x21, 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, + 0x00, 0xf0, 0x40, 0xff, 0x07, 0xbd, 0xc0, 0x46, 0xe0, 0x11, 0x00, 0x20, + 0x07, 0xb5, 0x00, 0x21, 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, + 0x00, 0xf0, 0x34, 0xff, 0x07, 0xbd, 0xc0, 0x46, 0xe8, 0x11, 0x00, 0x20, + 0x30, 0xb5, 0x85, 0xb0, 0x0c, 0x00, 0x05, 0x00, 0x02, 0xf0, 0x0a, 0xfa, + 0x04, 0x21, 0x00, 0x23, 0x01, 0x91, 0x03, 0xa9, 0xc2, 0xb2, 0x00, 0x91, + 0x63, 0x20, 0x29, 0x00, 0x03, 0x93, 0x00, 0xf0, 0xff, 0xf9, 0x03, 0x98, + 0x20, 0x60, 0xc0, 0x43, 0xc0, 0x0f, 0x05, 0xb0, 0x30, 0xbd, 0x10, 0xb5, + 0x04, 0x00, 0x00, 0x23, 0xa1, 0x60, 0x08, 0x00, 0x21, 0x1d, 0x23, 0x60, + 0x63, 0x60, 0xff, 0xf7, 0xdf, 0xff, 0x20, 0x00, 0x10, 0xbd, 0x00, 0x00, + 0x07, 0xb5, 0x00, 0x21, 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, + 0x00, 0xf0, 0x04, 0xff, 0x07, 0xbd, 0xc0, 0x46, 0xf0, 0x11, 0x00, 0x20, + 0x07, 0xb5, 0x00, 0x21, 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, + 0x00, 0xf0, 0xf8, 0xfe, 0x07, 0xbd, 0xc0, 0x46, 0xf8, 0x11, 0x00, 0x20, + 0x10, 0xb5, 0x04, 0x00, 0x78, 0x22, 0x00, 0x21, 0x02, 0xf0, 0xef, 0xf8, + 0x20, 0x00, 0x10, 0xbd, 0x10, 0xb5, 0x0c, 0x24, 0x4c, 0x43, 0x04, 0x19, + 0x20, 0x68, 0x00, 0x28, 0x05, 0xd0, 0x02, 0xf0, 0xd1, 0xf8, 0x00, 0x23, + 0x63, 0x60, 0x23, 0x60, 0xa3, 0x60, 0x10, 0xbd, 0x70, 0xb5, 0x05, 0x00, + 0x00, 0x24, 0x21, 0x00, 0x28, 0x00, 0x01, 0x34, 0xff, 0xf7, 0xea, 0xff, + 0x0a, 0x2c, 0xf8, 0xd1, 0x28, 0x00, 0x70, 0xbd, 0x10, 0xb5, 0x05, 0x4c, + 0x20, 0x00, 0xff, 0xf7, 0xd9, 0xff, 0x04, 0x4a, 0x04, 0x49, 0x20, 0x00, + 0x01, 0xf0, 0xe6, 0xff, 0x10, 0xbd, 0xc0, 0x46, 0x00, 0x12, 0x00, 0x20, + 0x00, 0x00, 0x00, 0x20, 0x7d, 0x27, 0x00, 0x00, 0xf8, 0xb5, 0x1c, 0x23, + 0x23, 0x4e, 0x24, 0x4f, 0x33, 0x70, 0x24, 0x4c, 0x07, 0x33, 0x3b, 0x70, + 0xbd, 0x33, 0x23, 0x70, 0x00, 0xf0, 0x4a, 0xfb, 0x21, 0x4d, 0xdf, 0x28, + 0x04, 0xd8, 0x01, 0x23, 0x2b, 0x70, 0x23, 0x78, 0xdb, 0x43, 0x23, 0x70, + 0x1e, 0x48, 0x00, 0xf0, 0xad, 0xfa, 0x30, 0x78, 0x01, 0x21, 0x00, 0xf0, + 0x93, 0xfd, 0x38, 0x78, 0x00, 0x21, 0x00, 0xf0, 0x8f, 0xfd, 0x20, 0x78, + 0x01, 0x21, 0x00, 0xf0, 0x8b, 0xfd, 0x01, 0x21, 0x1e, 0x20, 0x00, 0xf0, + 0x87, 0xfd, 0x01, 0x21, 0x1e, 0x20, 0x00, 0xf0, 0xcf, 0xfd, 0x30, 0x78, + 0x01, 0x21, 0x00, 0xf0, 0xcb, 0xfd, 0x29, 0x78, 0x20, 0x78, 0x00, 0xf0, + 0xc7, 0xfd, 0x0a, 0x20, 0x00, 0xf0, 0xf6, 0xfb, 0x29, 0x78, 0x01, 0x25, + 0x20, 0x78, 0x69, 0x40, 0x00, 0xf0, 0xbe, 0xfd, 0x0b, 0x48, 0x00, 0xf0, + 0xed, 0xfb, 0x00, 0x21, 0x1e, 0x20, 0x00, 0xf0, 0xb7, 0xfd, 0x00, 0x21, + 0x1e, 0x20, 0x00, 0xf0, 0x67, 0xfd, 0x07, 0x4b, 0x1d, 0x70, 0xf8, 0xbd, + 0x12, 0x00, 0x00, 0x20, 0x10, 0x00, 0x00, 0x20, 0x11, 0x00, 0x00, 0x20, + 0x78, 0x12, 0x00, 0x20, 0xc4, 0x16, 0x00, 0x20, 0xee, 0x02, 0x00, 0x00, + 0x79, 0x12, 0x00, 0x20, 0x13, 0xb5, 0x00, 0x24, 0x6b, 0x46, 0x5c, 0x71, + 0x1c, 0x71, 0x01, 0x9a, 0x0b, 0x49, 0x0c, 0x48, 0x00, 0xf0, 0x8a, 0xfa, + 0x0b, 0x4b, 0x21, 0x00, 0x18, 0x78, 0x00, 0xf0, 0x93, 0xfd, 0x00, 0xf0, + 0x8d, 0xfb, 0x04, 0x00, 0x08, 0x4b, 0x18, 0x78, 0x00, 0xf0, 0xb8, 0xfd, + 0x01, 0x28, 0x04, 0xd0, 0x00, 0xf0, 0x84, 0xfb, 0x00, 0x1b, 0x04, 0x28, + 0xf4, 0xd9, 0x13, 0xbd, 0x00, 0x12, 0x7a, 0x00, 0xc4, 0x16, 0x00, 0x20, + 0x12, 0x00, 0x00, 0x20, 0x10, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x4b, + 0x01, 0x21, 0x18, 0x78, 0x00, 0xf0, 0x76, 0xfd, 0x02, 0x48, 0x00, 0xf0, + 0x81, 0xfa, 0x10, 0xbd, 0x12, 0x00, 0x00, 0x20, 0xc4, 0x16, 0x00, 0x20, + 0x07, 0xb5, 0x6b, 0x46, 0xd8, 0x71, 0xd9, 0x79, 0x02, 0x48, 0xc9, 0xb2, + 0x00, 0xf0, 0x88, 0xfa, 0x0e, 0xbd, 0xc0, 0x46, 0xc4, 0x16, 0x00, 0x20, + 0x10, 0xb5, 0x03, 0x4b, 0x18, 0x78, 0x00, 0xf0, 0x89, 0xfd, 0x00, 0x28, + 0xf9, 0xd1, 0x10, 0xbd, 0x10, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, + 0xff, 0x20, 0xff, 0xf7, 0xe5, 0xff, 0x20, 0x70, 0x10, 0xbd, 0x70, 0xb5, + 0x0c, 0x00, 0x05, 0x00, 0x08, 0x00, 0xff, 0xf7, 0xf3, 0xff, 0x20, 0x78, + 0x40, 0x1b, 0x43, 0x42, 0x58, 0x41, 0x70, 0xbd, 0x13, 0xb5, 0x6b, 0x46, + 0xdc, 0x1d, 0x00, 0x23, 0x20, 0x00, 0x23, 0x70, 0xff, 0xf7, 0xe6, 0xff, + 0x20, 0x78, 0x16, 0xbd, 0x70, 0xb5, 0x05, 0x00, 0x08, 0x4c, 0xff, 0xf7, + 0xf1, 0xff, 0xef, 0x28, 0x08, 0xd0, 0x01, 0x3c, 0x00, 0x2c, 0x01, 0xd0, + 0xa8, 0x42, 0xf6, 0xd1, 0x40, 0x1b, 0x43, 0x42, 0x58, 0x41, 0x70, 0xbd, + 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, 0xc0, 0x46, 0xe9, 0x03, 0x00, 0x00, + 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x00, 0x20, 0x16, 0x00, 0xff, 0xf7, + 0xb1, 0xff, 0x65, 0x19, 0xac, 0x42, 0x04, 0xd0, 0x20, 0x78, 0xff, 0xf7, + 0xab, 0xff, 0x01, 0x34, 0xf8, 0xe7, 0x01, 0x2e, 0x02, 0xd1, 0xee, 0x20, + 0xff, 0xf7, 0xa4, 0xff, 0x70, 0xbd, 0xf8, 0xb5, 0x05, 0x00, 0x08, 0x00, + 0x0e, 0x00, 0x17, 0x00, 0x2c, 0x00, 0xff, 0xf7, 0x9b, 0xff, 0x63, 0x1b, + 0x9e, 0x42, 0x04, 0xdd, 0x20, 0x78, 0xff, 0xf7, 0x95, 0xff, 0x01, 0x34, + 0xf7, 0xe7, 0x01, 0x2f, 0x02, 0xd1, 0xee, 0x20, 0xff, 0xf7, 0x8e, 0xff, + 0xf8, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0xff, 0x20, 0xff, 0xf7, 0x88, 0xff, + 0x00, 0x2c, 0x00, 0xd0, 0x20, 0x70, 0x10, 0xbd, 0xf0, 0xb5, 0x85, 0xb0, + 0x1f, 0x00, 0x02, 0xab, 0xdc, 0x1d, 0x00, 0x23, 0x05, 0x00, 0xe0, 0x20, + 0x01, 0x91, 0x16, 0x00, 0x23, 0x70, 0xff, 0xf7, 0xa9, 0xff, 0x00, 0x28, + 0x02, 0xd1, 0x00, 0x20, 0x05, 0xb0, 0xf0, 0xbd, 0x20, 0x00, 0xff, 0xf7, + 0x85, 0xff, 0x80, 0x22, 0x23, 0x78, 0x15, 0x43, 0xab, 0x42, 0xf4, 0xd1, + 0x20, 0x00, 0xff, 0xf7, 0x7d, 0xff, 0x23, 0x78, 0x01, 0x9a, 0x93, 0x42, + 0xed, 0xd1, 0x38, 0x00, 0xff, 0xf7, 0xd3, 0xff, 0x35, 0x00, 0x3a, 0x78, + 0xab, 0x1b, 0x9a, 0x42, 0x04, 0xdd, 0x28, 0x00, 0xff, 0xf7, 0x6e, 0xff, + 0x01, 0x35, 0xf6, 0xe7, 0x21, 0x00, 0xee, 0x20, 0xff, 0xf7, 0x6f, 0xff, + 0x01, 0x20, 0xdb, 0xe7, 0x70, 0xb5, 0x04, 0x00, 0xe0, 0x20, 0x0d, 0x00, + 0xff, 0xf7, 0x4a, 0xff, 0x7f, 0x20, 0x20, 0x40, 0xff, 0xf7, 0x46, 0xff, + 0x28, 0x00, 0xff, 0xf7, 0x43, 0xff, 0x00, 0x2d, 0x02, 0xd1, 0xee, 0x20, + 0xff, 0xf7, 0x3e, 0xff, 0x70, 0xbd, 0x00, 0x00, 0x12, 0x4b, 0x13, 0xb5, + 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0xff, 0xf7, 0xa9, 0xfe, 0xff, 0xf7, + 0x3f, 0xff, 0xff, 0xf7, 0xfd, 0xfe, 0x00, 0x21, 0x20, 0x20, 0xff, 0xf7, + 0xdd, 0xff, 0xff, 0xf7, 0x1d, 0xff, 0xff, 0xf7, 0x35, 0xff, 0xff, 0xf7, + 0xf3, 0xfe, 0x6b, 0x46, 0x9c, 0x1d, 0xff, 0x23, 0x23, 0x70, 0x6b, 0x46, + 0x00, 0x22, 0x07, 0x33, 0x1a, 0x70, 0x01, 0x21, 0x22, 0x00, 0x20, 0x20, + 0xff, 0xf7, 0x96, 0xff, 0xff, 0xf7, 0x0a, 0xff, 0x20, 0x78, 0x16, 0xbd, + 0x79, 0x12, 0x00, 0x20, 0x11, 0x4b, 0x13, 0xb5, 0x1b, 0x78, 0x00, 0x2b, + 0x01, 0xd1, 0xff, 0xf7, 0x81, 0xfe, 0xff, 0xf7, 0x17, 0xff, 0xff, 0xf7, + 0xd5, 0xfe, 0x00, 0x21, 0x37, 0x20, 0xff, 0xf7, 0xb5, 0xff, 0xff, 0xf7, + 0xf5, 0xfe, 0xff, 0xf7, 0x0d, 0xff, 0xff, 0xf7, 0xcb, 0xfe, 0x6b, 0x46, + 0x00, 0x22, 0x07, 0x4c, 0x07, 0x33, 0x1a, 0x70, 0x01, 0x21, 0x22, 0x00, + 0x37, 0x20, 0xff, 0xf7, 0x71, 0xff, 0xff, 0xf7, 0xe5, 0xfe, 0x20, 0x00, + 0x16, 0xbd, 0xc0, 0x46, 0x79, 0x12, 0x00, 0x20, 0x84, 0x12, 0x00, 0x20, + 0xf0, 0xb5, 0x85, 0xb0, 0x01, 0x93, 0x29, 0x4b, 0x06, 0x00, 0x1b, 0x78, + 0x00, 0x91, 0x14, 0x00, 0x00, 0x2b, 0x01, 0xd1, 0xff, 0xf7, 0x54, 0xfe, + 0x35, 0x00, 0x60, 0x3d, 0x6f, 0x42, 0x6f, 0x41, 0x03, 0x37, 0xff, 0xf7, + 0xe5, 0xfe, 0xff, 0xf7, 0xa3, 0xfe, 0x39, 0x00, 0x30, 0x00, 0xff, 0xf7, + 0x83, 0xff, 0x00, 0x22, 0x04, 0x21, 0x01, 0xa8, 0xff, 0xf7, 0x2b, 0xff, + 0x00, 0x22, 0x04, 0x21, 0x0b, 0xa8, 0xff, 0xf7, 0x26, 0xff, 0x6a, 0x1e, + 0x95, 0x41, 0x21, 0x00, 0xea, 0xb2, 0x00, 0x98, 0xff, 0xf7, 0x1f, 0xff, + 0x60, 0x2e, 0x04, 0xd1, 0x01, 0x22, 0x0b, 0x99, 0x0a, 0x98, 0xff, 0xf7, + 0x03, 0xff, 0x0c, 0x34, 0xe4, 0x19, 0x03, 0x27, 0x25, 0x00, 0x3d, 0x40, + 0x03, 0xd0, 0xff, 0xf7, 0xdb, 0xfe, 0x01, 0x34, 0xf8, 0xe7, 0xff, 0xf7, + 0xa1, 0xfe, 0x0f, 0x24, 0xff, 0xf7, 0xb8, 0xfe, 0xff, 0xf7, 0x76, 0xfe, + 0x0e, 0x23, 0x6c, 0x44, 0x6b, 0x44, 0x1d, 0x70, 0x25, 0x70, 0x60, 0x2e, + 0x00, 0xd1, 0x0a, 0x93, 0x23, 0x00, 0x0a, 0x9a, 0x01, 0x21, 0x30, 0x00, + 0xff, 0xf7, 0x18, 0xff, 0xff, 0xf7, 0x8c, 0xfe, 0x00, 0x20, 0x20, 0x56, + 0x05, 0xb0, 0xf0, 0xbd, 0x79, 0x12, 0x00, 0x20, 0x07, 0xb5, 0x00, 0x21, + 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, 0x00, 0xf0, 0xc0, 0xfc, + 0x07, 0xbd, 0xc0, 0x46, 0x7c, 0x12, 0x00, 0x20, 0x10, 0xb5, 0x05, 0x4a, + 0x05, 0x49, 0x06, 0x48, 0x00, 0xf0, 0x10, 0xf8, 0x00, 0x22, 0x05, 0x4b, + 0x05, 0x49, 0x1a, 0x70, 0x5a, 0x54, 0x10, 0xbd, 0x01, 0x04, 0x00, 0x00, + 0x00, 0x50, 0x00, 0x00, 0x90, 0x16, 0x00, 0x20, 0x8a, 0x12, 0x00, 0x20, + 0x02, 0x04, 0x00, 0x00, 0x30, 0xb5, 0x09, 0x4d, 0x09, 0x4c, 0xab, 0x68, + 0x5b, 0x03, 0x5b, 0x0f, 0x9b, 0x00, 0x1c, 0x59, 0x04, 0x60, 0xab, 0x68, + 0x01, 0x61, 0x9b, 0xb2, 0x43, 0x60, 0x63, 0x43, 0xa4, 0x00, 0x83, 0x60, + 0xc4, 0x60, 0x42, 0x61, 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x00, 0x55, 0x00, 0x00, 0xf7, 0xb5, 0x80, 0x26, 0x1a, 0x4d, 0x01, 0x91, + 0x6f, 0x68, 0x03, 0x33, 0x3e, 0x43, 0x9b, 0x08, 0x6e, 0x60, 0x00, 0x2b, + 0x2b, 0xd0, 0x17, 0x4e, 0x2e, 0x80, 0x2e, 0x7d, 0xf1, 0x07, 0xfc, 0xd5, + 0x1e, 0x00, 0x07, 0x68, 0x99, 0x1b, 0xbf, 0x08, 0x8f, 0x42, 0x19, 0xd9, + 0x00, 0x2e, 0x17, 0xd0, 0xff, 0x21, 0x17, 0x78, 0x8c, 0x43, 0x3c, 0x43, + 0x0f, 0x49, 0x57, 0x78, 0x0c, 0x40, 0x3f, 0x02, 0x3c, 0x43, 0x97, 0x78, + 0x01, 0x3e, 0x39, 0x04, 0x0c, 0x4f, 0x27, 0x40, 0xd4, 0x78, 0xbf, 0xb2, + 0x0f, 0x43, 0x24, 0x06, 0x01, 0x99, 0x3c, 0x43, 0x10, 0xc1, 0x01, 0x91, + 0x04, 0x32, 0xe0, 0xe7, 0x07, 0x4b, 0x2b, 0x80, 0x2b, 0x7d, 0xdb, 0x07, + 0xfc, 0xd5, 0x33, 0x00, 0xd1, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, + 0x44, 0xa5, 0xff, 0xff, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, + 0x04, 0xa5, 0xff, 0xff, 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, + 0x1a, 0x80, 0x1a, 0x7d, 0xd2, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, + 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x04, 0x00, + 0x0d, 0x00, 0x16, 0x00, 0xe3, 0x68, 0x29, 0x00, 0x20, 0x00, 0xb3, 0x42, + 0x05, 0xd2, 0xff, 0xf7, 0xe7, 0xff, 0xe3, 0x68, 0xed, 0x18, 0xf6, 0x1a, + 0xf4, 0xe7, 0xff, 0xf7, 0xe1, 0xff, 0x70, 0xbd, 0x03, 0x7d, 0x00, 0x2b, + 0x04, 0xd1, 0x43, 0x75, 0x83, 0x75, 0x83, 0x61, 0x01, 0x33, 0x03, 0x75, + 0x70, 0x47, 0x7f, 0xb5, 0xc3, 0x68, 0x02, 0xad, 0x04, 0x00, 0x0e, 0x00, + 0x02, 0x91, 0x6a, 0x60, 0x8b, 0x42, 0x03, 0xd1, 0x02, 0x8a, 0xab, 0x88, + 0x9a, 0x42, 0x18, 0xd0, 0x20, 0x00, 0x06, 0x22, 0x29, 0x00, 0x0c, 0x30, + 0x01, 0xf0, 0x08, 0xfe, 0x20, 0x68, 0x00, 0xf0, 0x84, 0xfd, 0x6b, 0x79, + 0x22, 0x7a, 0xe1, 0x79, 0x00, 0x93, 0x20, 0x68, 0x00, 0x23, 0x00, 0xf0, + 0x1d, 0xfe, 0x20, 0x68, 0x29, 0x79, 0x32, 0x00, 0x00, 0xf0, 0x48, 0xfd, + 0x20, 0x68, 0x00, 0xf0, 0x6a, 0xfd, 0x7f, 0xbd, 0x70, 0xb5, 0x18, 0x26, + 0x04, 0x00, 0xff, 0xf7, 0xcb, 0xff, 0x33, 0x00, 0x08, 0x21, 0x20, 0x79, + 0x0d, 0x4d, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x6c, 0xfb, + 0x33, 0x00, 0x08, 0x21, 0xa0, 0x79, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, + 0x00, 0xf0, 0x64, 0xfb, 0x08, 0x21, 0x60, 0x79, 0x46, 0x43, 0xad, 0x19, + 0x69, 0x56, 0x00, 0xf0, 0x5d, 0xfb, 0x04, 0x4b, 0x20, 0x00, 0x06, 0xcb, + 0xff, 0xf7, 0xb7, 0xff, 0x70, 0xbd, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, + 0xe0, 0x16, 0x00, 0x20, 0x07, 0xb5, 0x43, 0x7d, 0x00, 0x91, 0x01, 0x92, + 0x00, 0x2b, 0x07, 0xd0, 0x9a, 0x07, 0x0a, 0xd5, 0xef, 0xf3, 0x10, 0x83, + 0x5a, 0x42, 0x53, 0x41, 0x83, 0x75, 0x72, 0xb6, 0x00, 0x99, 0x01, 0x9a, + 0xff, 0xf7, 0x9f, 0xff, 0x07, 0xbd, 0xdb, 0x07, 0xf8, 0xd5, 0x83, 0x69, + 0x01, 0x4a, 0x9b, 0xb2, 0x93, 0x60, 0xf3, 0xe7, 0x00, 0x18, 0x00, 0x40, + 0x43, 0x7d, 0x00, 0x2b, 0x05, 0xd0, 0x9a, 0x07, 0x04, 0xd5, 0x83, 0x7d, + 0x00, 0x2b, 0x00, 0xd0, 0x62, 0xb6, 0x70, 0x47, 0xdb, 0x07, 0xfc, 0xd5, + 0x83, 0x69, 0x02, 0x4a, 0x9b, 0xb2, 0xd3, 0x60, 0xf7, 0xe7, 0xc0, 0x46, + 0x00, 0x18, 0x00, 0x40, 0x10, 0xb5, 0x00, 0x68, 0x00, 0xf0, 0x20, 0xfd, + 0x10, 0xbd, 0x00, 0x00, 0x11, 0x4a, 0x12, 0x4b, 0x12, 0x49, 0x13, 0x60, + 0x00, 0x23, 0x53, 0x71, 0x13, 0x71, 0x11, 0x4a, 0x11, 0x60, 0x11, 0x49, + 0xd3, 0x60, 0x91, 0x80, 0x09, 0x21, 0x91, 0x71, 0x06, 0x39, 0x53, 0x74, + 0x13, 0x74, 0x13, 0x75, 0xd3, 0x71, 0x11, 0x72, 0x0c, 0x4a, 0xd3, 0x60, + 0x53, 0x74, 0x13, 0x74, 0x13, 0x75, 0x0b, 0x4b, 0xd1, 0x71, 0x13, 0x60, + 0x0a, 0x4b, 0x93, 0x80, 0x1d, 0x23, 0x93, 0x71, 0x1c, 0x3b, 0x13, 0x72, + 0x70, 0x47, 0xc0, 0x46, 0xe0, 0x16, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, + 0x64, 0x1b, 0x00, 0x20, 0xa8, 0x16, 0x00, 0x20, 0x0a, 0x08, 0x00, 0x00, + 0xc4, 0x16, 0x00, 0x20, 0x70, 0x1b, 0x00, 0x20, 0x1b, 0x1a, 0x00, 0x00, + 0x24, 0x20, 0x70, 0x47, 0x10, 0xb5, 0x02, 0x48, 0x01, 0xf0, 0x07, 0xfb, + 0x10, 0xbd, 0xc0, 0x46, 0xe8, 0x16, 0x00, 0x20, 0x10, 0xb5, 0x02, 0x48, + 0x01, 0xf0, 0xff, 0xfa, 0x10, 0xbd, 0xc0, 0x46, 0x24, 0x19, 0x00, 0x20, + 0x7f, 0xb5, 0x19, 0x49, 0x19, 0x48, 0x00, 0xf0, 0x11, 0xfc, 0x19, 0x49, + 0x19, 0x48, 0x00, 0xf0, 0x0d, 0xfc, 0x19, 0x49, 0x19, 0x48, 0x00, 0xf0, + 0x09, 0xfc, 0x19, 0x49, 0x19, 0x48, 0x00, 0xf0, 0x05, 0xfc, 0x19, 0x4c, + 0x19, 0x49, 0x20, 0x00, 0x00, 0xf0, 0x00, 0xfc, 0x18, 0x4e, 0x19, 0x49, + 0x30, 0x00, 0x00, 0xf0, 0xfb, 0xfb, 0x01, 0x25, 0x03, 0x23, 0x31, 0x00, + 0x01, 0x95, 0x00, 0x93, 0x0d, 0x22, 0x0b, 0x33, 0x14, 0x48, 0x01, 0xf0, + 0x6b, 0xfa, 0x1d, 0x23, 0x03, 0x93, 0x01, 0x3b, 0x02, 0x93, 0x1a, 0x3b, + 0x01, 0x93, 0x00, 0x95, 0x18, 0x33, 0x1b, 0x22, 0x21, 0x00, 0x0f, 0x48, + 0x01, 0xf0, 0x1a, 0xfa, 0x7f, 0xbd, 0xc0, 0x46, 0x00, 0x08, 0x00, 0x42, + 0x60, 0x1b, 0x00, 0x20, 0x00, 0x0c, 0x00, 0x42, 0x64, 0x1b, 0x00, 0x20, + 0x00, 0x10, 0x00, 0x42, 0x68, 0x1b, 0x00, 0x20, 0x00, 0x14, 0x00, 0x42, + 0x6c, 0x1b, 0x00, 0x20, 0x70, 0x1b, 0x00, 0x20, 0x00, 0x18, 0x00, 0x42, + 0x74, 0x1b, 0x00, 0x20, 0x00, 0x1c, 0x00, 0x42, 0xe8, 0x16, 0x00, 0x20, + 0x24, 0x19, 0x00, 0x20, 0xfe, 0xe7, 0x00, 0x00, 0x03, 0x4b, 0x10, 0xb5, + 0x1b, 0x68, 0x00, 0x2b, 0x00, 0xd0, 0x98, 0x47, 0x10, 0xbd, 0xc0, 0x46, + 0x78, 0x1b, 0x00, 0x20, 0x70, 0xb5, 0x0f, 0x49, 0x0f, 0x4c, 0xa1, 0x42, + 0x04, 0xd1, 0x00, 0xf0, 0x89, 0xf8, 0xff, 0xf7, 0x47, 0xf9, 0xfe, 0xe7, + 0x0c, 0x4d, 0x00, 0x23, 0x8d, 0x42, 0xf6, 0xd0, 0xca, 0x18, 0xe8, 0x18, + 0xa2, 0x42, 0x05, 0xd3, 0x09, 0x4b, 0x82, 0x42, 0xef, 0xd0, 0x09, 0x49, + 0x00, 0x22, 0x04, 0xe0, 0x00, 0x68, 0x04, 0x33, 0x10, 0x60, 0xf1, 0xe7, + 0x04, 0xc3, 0x8b, 0x42, 0xfc, 0xd3, 0xe4, 0xe7, 0x00, 0x00, 0x00, 0x20, + 0xe0, 0x00, 0x00, 0x20, 0x7c, 0x59, 0x00, 0x00, 0xe0, 0x00, 0x00, 0x20, + 0xac, 0x21, 0x00, 0x20, 0x10, 0xb5, 0x00, 0xf0, 0x60, 0xf8, 0x00, 0x28, + 0x01, 0xd1, 0x00, 0xf0, 0x51, 0xf8, 0x10, 0xbd, 0x01, 0x4b, 0x18, 0x68, + 0x70, 0x47, 0xc0, 0x46, 0x7c, 0x1b, 0x00, 0x20, 0xf7, 0xb5, 0x13, 0x48, + 0x01, 0x22, 0x84, 0x46, 0x12, 0x49, 0x13, 0x4c, 0x8e, 0x68, 0x63, 0x68, + 0x05, 0x68, 0x9b, 0x0e, 0x13, 0x40, 0x01, 0x92, 0x88, 0x68, 0x62, 0x68, + 0x01, 0x9f, 0x92, 0x0e, 0x3a, 0x40, 0x67, 0x46, 0x3f, 0x68, 0x93, 0x42, + 0x0e, 0xd1, 0xbd, 0x42, 0x0c, 0xd1, 0x86, 0x42, 0x0a, 0xd3, 0x5b, 0x19, + 0xfa, 0x25, 0x48, 0x68, 0xad, 0x00, 0x86, 0x1b, 0x07, 0x48, 0x6b, 0x43, + 0x70, 0x43, 0x00, 0x0d, 0xc0, 0x18, 0xfe, 0xbd, 0x3d, 0x00, 0x13, 0x00, + 0x06, 0x00, 0xe3, 0xe7, 0x7c, 0x1b, 0x00, 0x20, 0x10, 0xe0, 0x00, 0xe0, + 0x00, 0xed, 0x00, 0xe0, 0x55, 0x55, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x1e, + 0x10, 0xd0, 0xff, 0xf7, 0xcb, 0xff, 0x05, 0x00, 0x00, 0xf0, 0x1c, 0xf8, + 0xff, 0xf7, 0xc6, 0xff, 0x05, 0x4b, 0x40, 0x1b, 0x98, 0x42, 0xf7, 0xd9, + 0xfa, 0x23, 0x01, 0x3c, 0x9b, 0x00, 0xed, 0x18, 0x00, 0x2c, 0xf3, 0xd1, + 0x70, 0xbd, 0xc0, 0x46, 0xe7, 0x03, 0x00, 0x00, 0x70, 0x47, 0x00, 0x00, + 0x10, 0xb5, 0x03, 0x4a, 0x13, 0x68, 0x01, 0x33, 0x13, 0x60, 0x00, 0xf0, + 0xf5, 0xfa, 0x10, 0xbd, 0x7c, 0x1b, 0x00, 0x20, 0x70, 0x47, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x00, 0x1e, 0x22, 0x70, 0xb5, 0x46, 0x48, 0x47, 0x49, + 0x43, 0x68, 0x93, 0x43, 0x1c, 0x3a, 0x13, 0x43, 0x43, 0x60, 0x08, 0x23, + 0x8c, 0x69, 0x23, 0x43, 0x8b, 0x61, 0x43, 0x4c, 0x43, 0x4b, 0x9c, 0x82, + 0x9c, 0x8a, 0x14, 0x43, 0x9c, 0x82, 0xdc, 0x68, 0x14, 0x42, 0xfc, 0xd0, + 0x01, 0x24, 0x40, 0x4a, 0x14, 0x70, 0x15, 0x78, 0x25, 0x42, 0x03, 0xd0, + 0x55, 0x78, 0x6d, 0xb2, 0x00, 0x2d, 0xf8, 0xdb, 0x01, 0x24, 0x94, 0x60, + 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x39, 0x4c, 0x54, 0x60, + 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x82, 0x24, 0xe4, 0x01, + 0x54, 0x80, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x02, 0x24, + 0x9c, 0x84, 0x0e, 0x34, 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x31, 0x4c, + 0xdc, 0x62, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x9d, 0x8c, + 0x2e, 0x4c, 0x2c, 0x43, 0x9c, 0x84, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x02, 0x24, 0x9d, 0x8c, 0x80, 0x26, 0x2c, 0x43, 0x9c, 0x84, + 0x40, 0x24, 0xdd, 0x68, 0x35, 0x42, 0xfc, 0xd0, 0xdd, 0x68, 0x25, 0x42, + 0xf9, 0xd0, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x00, 0x24, + 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x21, 0x4c, + 0x54, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x1c, 0x6a, + 0x1e, 0x4d, 0x2c, 0x40, 0x80, 0x25, 0x1c, 0x62, 0x1c, 0x6a, 0xac, 0x43, + 0x1c, 0x62, 0x03, 0x23, 0x93, 0x60, 0x1b, 0x4b, 0x53, 0x60, 0x53, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x00, 0x23, 0xff, 0x24, 0x0b, 0x72, + 0x17, 0x4a, 0x4b, 0x72, 0x8b, 0x72, 0xcb, 0x72, 0x16, 0x4b, 0x1a, 0x60, + 0x16, 0x4b, 0x17, 0x4a, 0x1b, 0x68, 0x11, 0x68, 0x9a, 0x06, 0x5b, 0x01, + 0xc9, 0x0e, 0x23, 0x40, 0x52, 0x0f, 0x12, 0x02, 0x0b, 0x43, 0x13, 0x43, + 0x12, 0x4a, 0x13, 0x85, 0x80, 0x23, 0x42, 0x68, 0x13, 0x43, 0x43, 0x60, + 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, 0x00, 0x04, 0x00, 0x40, + 0x0c, 0x06, 0x00, 0x00, 0x00, 0x08, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, + 0x01, 0x05, 0x01, 0x00, 0xb9, 0x05, 0xff, 0x7d, 0x04, 0x0a, 0x00, 0x00, + 0x00, 0x07, 0x03, 0x00, 0xff, 0xfc, 0xff, 0xff, 0x03, 0x06, 0x01, 0x00, + 0x00, 0x6c, 0xdc, 0x02, 0x14, 0x00, 0x00, 0x20, 0x24, 0x60, 0x80, 0x00, + 0x20, 0x60, 0x80, 0x00, 0x00, 0x40, 0x00, 0x42, 0xfa, 0x21, 0x31, 0x4b, + 0x10, 0xb5, 0x18, 0x68, 0x89, 0x00, 0x01, 0xf0, 0xe5, 0xfa, 0x2f, 0x4b, + 0x01, 0x38, 0x98, 0x42, 0x56, 0xd8, 0x2e, 0x49, 0x2e, 0x4a, 0x48, 0x60, + 0xc0, 0x20, 0x13, 0x6a, 0x00, 0x06, 0x1b, 0x02, 0x1b, 0x0a, 0x03, 0x43, + 0x13, 0x62, 0x00, 0x24, 0x07, 0x23, 0x8c, 0x60, 0x0b, 0x60, 0x80, 0x21, + 0x13, 0x6a, 0x09, 0x06, 0x1b, 0x02, 0x1b, 0x0a, 0x0b, 0x43, 0x13, 0x62, + 0xfc, 0x22, 0x25, 0x4b, 0x19, 0x6a, 0x0a, 0x43, 0x1a, 0x62, 0xfc, 0x22, + 0x19, 0x6a, 0x92, 0x01, 0x0a, 0x43, 0x1a, 0x62, 0xa0, 0x22, 0x19, 0x6a, + 0xd2, 0x02, 0x0a, 0x43, 0x1a, 0x62, 0x20, 0x00, 0x00, 0x21, 0x01, 0x34, + 0x00, 0xf0, 0x76, 0xf8, 0x0f, 0x2c, 0xf8, 0xd1, 0x1b, 0x4b, 0x1c, 0x00, + 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, 0x19, 0x4a, 0x5a, 0x80, + 0x19, 0x4b, 0x1a, 0x00, 0x59, 0x7e, 0xc9, 0x09, 0x01, 0x29, 0xfb, 0xd0, + 0xe4, 0x21, 0xc9, 0x00, 0x99, 0x80, 0x3f, 0x21, 0xd9, 0x70, 0x53, 0x7e, + 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0xc0, 0x23, 0x00, 0x20, 0x5b, 0x01, + 0x13, 0x61, 0x90, 0x70, 0x00, 0xf0, 0x24, 0xf8, 0x63, 0x78, 0x5b, 0xb2, + 0x00, 0x2b, 0xfb, 0xdb, 0x0d, 0x4b, 0x0e, 0x4a, 0x63, 0x80, 0xd3, 0x79, + 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0x41, 0x23, 0x53, 0x70, 0x10, 0xbd, + 0xfe, 0xe7, 0xc0, 0x46, 0x14, 0x00, 0x00, 0x20, 0xff, 0xff, 0xff, 0x00, + 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, 0x00, 0x04, 0x00, 0x40, + 0x00, 0x0c, 0x00, 0x40, 0x1e, 0x40, 0x00, 0x00, 0x00, 0x40, 0x00, 0x42, + 0x21, 0x40, 0x00, 0x00, 0x00, 0x48, 0x00, 0x42, 0x16, 0x4a, 0x00, 0xb5, + 0x13, 0x00, 0x51, 0x7e, 0xc9, 0x09, 0x01, 0x29, 0xfb, 0xd0, 0x01, 0x38, + 0x04, 0x28, 0x16, 0xd8, 0x19, 0x69, 0x12, 0x4a, 0x0a, 0x40, 0x0f, 0x21, + 0x1a, 0x61, 0x5a, 0x78, 0x8a, 0x43, 0x01, 0xf0, 0x57, 0xfa, 0x03, 0x08, + 0x06, 0x0b, 0x03, 0x00, 0x11, 0x00, 0x01, 0x22, 0x0a, 0x43, 0x5a, 0x70, + 0x00, 0xbd, 0x11, 0x00, 0x03, 0x22, 0xf9, 0xe7, 0x11, 0x00, 0x02, 0x22, + 0xf6, 0xe7, 0xf0, 0x23, 0x11, 0x69, 0x1b, 0x05, 0x0b, 0x43, 0x0f, 0x21, + 0x13, 0x61, 0x53, 0x78, 0x8b, 0x43, 0x19, 0x00, 0x02, 0x23, 0x0b, 0x43, + 0x53, 0x70, 0xeb, 0xe7, 0x00, 0x40, 0x00, 0x42, 0xff, 0xff, 0xff, 0xf0, + 0x18, 0x23, 0x30, 0xb5, 0x1d, 0x00, 0x04, 0x00, 0x45, 0x43, 0x08, 0x20, + 0x20, 0x4a, 0x55, 0x19, 0x28, 0x56, 0x01, 0x30, 0x14, 0xd0, 0x03, 0x29, + 0x12, 0xd8, 0x08, 0x00, 0x63, 0x43, 0xd1, 0x56, 0xd3, 0x18, 0x01, 0xf0, + 0x25, 0xfa, 0x02, 0x28, 0x0e, 0x1b, 0x58, 0x68, 0xcb, 0x01, 0x02, 0x21, + 0x18, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, + 0x82, 0x40, 0x5a, 0x60, 0x30, 0xbd, 0x58, 0x68, 0xcb, 0x01, 0x06, 0x21, + 0x12, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, + 0x82, 0x40, 0x5a, 0x60, 0x9a, 0x61, 0xf1, 0xe7, 0x58, 0x68, 0xcb, 0x01, + 0x06, 0x21, 0x0c, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, + 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x5a, 0x61, 0xe4, 0xe7, 0x58, 0x68, + 0xcb, 0x01, 0x02, 0x21, 0x05, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, + 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x9a, 0x60, 0xd8, 0xe7, 0xc0, 0x46, + 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0x18, 0x23, 0xf0, 0xb5, + 0x08, 0x24, 0x58, 0x43, 0x11, 0x4a, 0x13, 0x18, 0x1c, 0x57, 0x01, 0x34, + 0x1b, 0xd0, 0x01, 0x26, 0x35, 0x00, 0x5f, 0x68, 0x83, 0x56, 0xbd, 0x40, + 0x0d, 0x4a, 0xdb, 0x01, 0x9a, 0x18, 0x90, 0x68, 0x05, 0x42, 0x0b, 0xd1, + 0x0c, 0x00, 0x60, 0x1e, 0x84, 0x41, 0xd2, 0x19, 0x40, 0x32, 0x10, 0x78, + 0x34, 0x40, 0x03, 0x36, 0xa4, 0x00, 0xb0, 0x43, 0x20, 0x43, 0x10, 0x70, + 0x04, 0x4a, 0x9b, 0x18, 0x00, 0x29, 0x01, 0xd1, 0x5d, 0x61, 0xf0, 0xbd, + 0x9d, 0x61, 0xfc, 0xe7, 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x18, 0x23, 0x10, 0xb5, 0x08, 0x24, 0x43, 0x43, 0x07, 0x49, 0x00, 0x20, + 0xca, 0x18, 0x14, 0x57, 0x01, 0x34, 0x08, 0xd0, 0x5b, 0x56, 0x05, 0x49, + 0xdb, 0x01, 0x5b, 0x18, 0x18, 0x6a, 0x53, 0x68, 0xd8, 0x40, 0x01, 0x23, + 0x18, 0x40, 0x10, 0xbd, 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x18, 0x22, 0x42, 0x43, 0xf8, 0xb5, 0x2c, 0x4e, 0x03, 0x00, 0xb2, 0x18, + 0x12, 0x7a, 0x52, 0xb2, 0x14, 0x00, 0x01, 0x32, 0x0e, 0xd0, 0x48, 0x1c, + 0x00, 0x24, 0x0c, 0x28, 0x0a, 0xd8, 0x01, 0xf0, 0x97, 0xf9, 0x07, 0x1f, + 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x0b, 0x0b, 0x0b, 0x0b, 0x00, + 0x01, 0x24, 0x64, 0x42, 0x20, 0x00, 0xf8, 0xbd, 0x09, 0x29, 0x05, 0xd1, + 0x00, 0x21, 0x18, 0x00, 0xff, 0xf7, 0x4e, 0xff, 0x00, 0x24, 0xf5, 0xe7, + 0x0a, 0x29, 0x01, 0xd1, 0x08, 0x39, 0xf6, 0xe7, 0x00, 0x24, 0x0b, 0x29, + 0xee, 0xd1, 0x0a, 0x39, 0x18, 0x00, 0xff, 0xf7, 0x41, 0xff, 0xe9, 0xe7, + 0x18, 0x22, 0x53, 0x43, 0xf2, 0x18, 0x55, 0x68, 0x01, 0x20, 0x2c, 0x00, + 0xf3, 0x56, 0x13, 0x4a, 0xdb, 0x01, 0x6e, 0x08, 0x9b, 0x18, 0xc9, 0xb2, + 0x04, 0x40, 0x9e, 0x19, 0x00, 0x2c, 0x0d, 0xd0, 0x0f, 0x24, 0x30, 0x36, + 0x32, 0x78, 0x09, 0x01, 0x22, 0x40, 0x11, 0x43, 0xc9, 0xb2, 0x5b, 0x19, + 0x31, 0x70, 0x40, 0x33, 0x1a, 0x78, 0x10, 0x43, 0x18, 0x70, 0xd3, 0xe7, + 0x32, 0x00, 0x0f, 0x27, 0x30, 0x32, 0x16, 0x78, 0x5b, 0x19, 0xbe, 0x43, + 0x31, 0x43, 0x11, 0x70, 0x40, 0x33, 0x1a, 0x78, 0x10, 0x43, 0x18, 0x70, + 0xbe, 0xe7, 0xc0, 0x46, 0x20, 0x55, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0xf7, 0xb5, 0xc3, 0x1d, 0x01, 0x93, 0x00, 0x23, 0x06, 0x00, 0x0d, 0x00, + 0x04, 0x1d, 0x00, 0x93, 0x21, 0x78, 0x0a, 0x22, 0x28, 0x00, 0x00, 0xf0, + 0x81, 0xf8, 0x2e, 0x21, 0x07, 0x00, 0x28, 0x00, 0x00, 0xf0, 0x47, 0xf8, + 0x00, 0x9b, 0x3f, 0x18, 0xdb, 0x19, 0x00, 0x93, 0x01, 0x9b, 0x01, 0x34, + 0x9c, 0x42, 0xed, 0xd1, 0xf1, 0x79, 0x28, 0x00, 0x0a, 0x22, 0x00, 0xf0, + 0x6f, 0xf8, 0x00, 0x9b, 0x18, 0x18, 0xfe, 0xbd, 0x30, 0xb5, 0x03, 0xac, + 0x25, 0x78, 0x04, 0x4c, 0xc5, 0x71, 0x08, 0x34, 0x04, 0x60, 0x01, 0x71, + 0x42, 0x71, 0x83, 0x71, 0x30, 0xbd, 0xc0, 0x46, 0x80, 0x58, 0x00, 0x00, + 0xf7, 0xb5, 0x06, 0x00, 0x0d, 0x00, 0x0c, 0x00, 0x8b, 0x18, 0x01, 0x93, + 0x01, 0x9b, 0x67, 0x1b, 0x9c, 0x42, 0x07, 0xd0, 0x33, 0x68, 0x21, 0x78, + 0x1b, 0x68, 0x30, 0x00, 0x98, 0x47, 0x01, 0x34, 0x00, 0x28, 0xf3, 0xd1, + 0x38, 0x00, 0xfe, 0xbd, 0x70, 0xb5, 0x04, 0x00, 0x08, 0x00, 0x0d, 0x00, + 0x01, 0xf0, 0xb8, 0xfa, 0x23, 0x68, 0x02, 0x00, 0x29, 0x00, 0x5b, 0x68, + 0x20, 0x00, 0x98, 0x47, 0x70, 0xbd, 0x10, 0xb5, 0x0b, 0x1e, 0x02, 0xd0, + 0xff, 0xf7, 0xee, 0xff, 0x03, 0x00, 0x18, 0x00, 0x10, 0xbd, 0x10, 0xb5, + 0x03, 0x68, 0x1b, 0x68, 0x98, 0x47, 0x10, 0xbd, 0xf0, 0xb5, 0x8b, 0xb0, + 0x6b, 0x46, 0x15, 0x00, 0x00, 0x22, 0x05, 0x33, 0x06, 0x00, 0xda, 0x77, + 0x08, 0x00, 0x01, 0x2d, 0x00, 0xd8, 0x0a, 0x25, 0x09, 0xac, 0x29, 0x00, + 0x01, 0xf0, 0x6a, 0xf9, 0xca, 0xb2, 0x13, 0x00, 0x37, 0x33, 0x07, 0x00, + 0xdb, 0xb2, 0x09, 0x29, 0x02, 0xd8, 0x13, 0x00, 0x30, 0x33, 0xdb, 0xb2, + 0x01, 0x3c, 0x23, 0x70, 0x00, 0x2f, 0xee, 0xd1, 0x21, 0x00, 0x30, 0x00, + 0xff, 0xf7, 0xd1, 0xff, 0x0b, 0xb0, 0xf0, 0xbd, 0x10, 0xb5, 0x00, 0x2a, + 0x04, 0xd1, 0x03, 0x68, 0xc9, 0xb2, 0x1b, 0x68, 0x98, 0x47, 0x10, 0xbd, + 0xd2, 0xb2, 0xff, 0xf7, 0xd1, 0xff, 0xfa, 0xe7, 0x10, 0xb5, 0xff, 0xf7, + 0xf1, 0xff, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0xff, 0xf7, 0x10, 0xfd, + 0x01, 0x4b, 0x1c, 0x60, 0x10, 0xbd, 0xc0, 0x46, 0x18, 0x00, 0x00, 0x20, + 0x01, 0x22, 0x02, 0x4b, 0x52, 0x42, 0x1a, 0x60, 0x70, 0x47, 0xc0, 0x46, + 0x18, 0x00, 0x00, 0x20, 0x16, 0x4a, 0x10, 0xb5, 0x13, 0x68, 0x59, 0x1c, + 0x26, 0xd0, 0x01, 0x3b, 0x13, 0x60, 0x00, 0x2b, 0x22, 0xd1, 0x72, 0xb6, + 0x12, 0x4b, 0x13, 0x4a, 0x04, 0x33, 0x93, 0x42, 0x13, 0xd9, 0x12, 0x4a, + 0x01, 0x21, 0x10, 0x00, 0x14, 0x7d, 0x0c, 0x42, 0xfc, 0xd0, 0x20, 0x21, + 0x14, 0x8b, 0xff, 0x31, 0x9b, 0x08, 0x5b, 0x00, 0x21, 0x43, 0x11, 0x83, + 0xd3, 0x61, 0x0c, 0x4b, 0x13, 0x80, 0x01, 0x23, 0x02, 0x7d, 0x1a, 0x42, + 0xfc, 0xd0, 0xbf, 0xf3, 0x4f, 0x8f, 0x09, 0x4b, 0x09, 0x4a, 0xda, 0x60, + 0xbf, 0xf3, 0x4f, 0x8f, 0xc0, 0x46, 0xfd, 0xe7, 0x10, 0xbd, 0xc0, 0x46, + 0x18, 0x00, 0x00, 0x20, 0x00, 0x20, 0x00, 0x00, 0x03, 0x02, 0x00, 0x00, + 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, 0x00, 0xed, 0x00, 0xe0, + 0x04, 0x00, 0xfa, 0x05, 0x01, 0x60, 0x70, 0x47, 0x94, 0x46, 0xf0, 0xb5, + 0x9e, 0x1e, 0x72, 0x1e, 0x96, 0x41, 0x62, 0x46, 0x05, 0x68, 0x92, 0x07, + 0x2f, 0x68, 0x36, 0x06, 0x3a, 0x43, 0x32, 0x43, 0x2a, 0x60, 0x07, 0x25, + 0x05, 0xac, 0x24, 0x78, 0x00, 0x68, 0xa4, 0x01, 0x29, 0x40, 0x21, 0x43, + 0x42, 0x68, 0x00, 0x24, 0x02, 0x2b, 0x00, 0xd0, 0x5c, 0x03, 0x11, 0x43, + 0x21, 0x43, 0x41, 0x60, 0xf0, 0xbd, 0x30, 0xb5, 0xc0, 0x25, 0x03, 0x68, + 0xad, 0x03, 0x1c, 0x68, 0x12, 0x05, 0x2a, 0x40, 0x22, 0x43, 0xc0, 0x24, + 0x09, 0x04, 0xa4, 0x02, 0x21, 0x40, 0x11, 0x43, 0x19, 0x60, 0x03, 0x68, + 0x5a, 0x68, 0x14, 0x43, 0x5c, 0x60, 0x30, 0xbd, 0x01, 0x23, 0x02, 0x68, + 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, 0x03, 0x68, 0x1a, 0x68, 0xd2, 0x07, + 0xfc, 0xd4, 0xda, 0x69, 0xd2, 0x07, 0xf9, 0xd4, 0x70, 0x47, 0x02, 0x23, + 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, 0x02, 0x68, 0xd3, 0x69, + 0x9b, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, + 0x02, 0xd4, 0x1a, 0x7e, 0x92, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0x00, 0x22, + 0x03, 0x68, 0x5a, 0x83, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x40, 0x07, + 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x09, 0x70, 0x47, + 0x80, 0x23, 0x02, 0x68, 0x5b, 0x42, 0x11, 0x7e, 0x0b, 0x43, 0x13, 0x76, + 0x70, 0x47, 0x03, 0x68, 0x58, 0x8b, 0x80, 0x07, 0xc0, 0x0f, 0x70, 0x47, + 0x02, 0x23, 0x02, 0x68, 0x51, 0x8b, 0x0b, 0x43, 0x53, 0x83, 0x70, 0x47, + 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, + 0x18, 0x8d, 0xc0, 0xb2, 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, + 0xfc, 0xd5, 0x89, 0xb2, 0x01, 0x20, 0x19, 0x85, 0x70, 0x47, 0x01, 0x22, + 0x03, 0x68, 0x9a, 0x75, 0x70, 0x47, 0x01, 0x22, 0x03, 0x68, 0x1a, 0x75, + 0x70, 0x47, 0x00, 0x00, 0x70, 0xb5, 0x01, 0x26, 0x04, 0x68, 0x4b, 0x08, + 0x33, 0x40, 0x31, 0x40, 0x25, 0x68, 0x09, 0x07, 0x5b, 0x07, 0x0b, 0x43, + 0x2b, 0x43, 0x23, 0x60, 0x04, 0x68, 0x51, 0x00, 0x03, 0x48, 0x00, 0xf0, + 0xd7, 0xff, 0x01, 0x38, 0xc0, 0xb2, 0x20, 0x73, 0x70, 0xbd, 0xc0, 0x46, + 0x00, 0x6c, 0xdc, 0x02, 0x01, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, + 0x13, 0x60, 0x03, 0x68, 0x1a, 0x68, 0xd2, 0x07, 0xfc, 0xd4, 0xda, 0x69, + 0xd2, 0x07, 0xf9, 0xd4, 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, 0x11, 0x68, + 0x0b, 0x43, 0x13, 0x60, 0x02, 0x68, 0xd3, 0x69, 0x9b, 0x07, 0xfc, 0xd4, + 0x70, 0x47, 0x03, 0x68, 0xda, 0x69, 0x92, 0x07, 0xfc, 0xd4, 0x02, 0x21, + 0x1a, 0x68, 0x8a, 0x43, 0x1a, 0x60, 0x70, 0x47, 0x02, 0x68, 0x93, 0x6a, + 0x5b, 0x0a, 0x5b, 0x02, 0x19, 0x43, 0x91, 0x62, 0x03, 0x68, 0x1a, 0x7e, + 0x52, 0x07, 0xfc, 0xd5, 0x98, 0x6a, 0xc0, 0xb2, 0x70, 0x47, 0x00, 0x00, + 0x03, 0x68, 0x21, 0x4a, 0x30, 0xb5, 0x93, 0x42, 0x2f, 0xd0, 0x20, 0x4a, + 0x93, 0x42, 0x2f, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1f, 0x4a, + 0x93, 0x42, 0x2f, 0xd0, 0x1e, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1e, 0x4a, + 0x93, 0x42, 0x1f, 0xd1, 0x0e, 0x23, 0x19, 0x22, 0x01, 0x21, 0x03, 0x25, + 0x99, 0x40, 0x1b, 0x48, 0xc0, 0x24, 0x01, 0x60, 0x99, 0x08, 0x2b, 0x40, + 0xab, 0x40, 0xfc, 0x35, 0x9d, 0x40, 0x89, 0x00, 0x09, 0x18, 0xa4, 0x00, + 0x08, 0x59, 0xa8, 0x43, 0xc0, 0x25, 0x9d, 0x40, 0x2b, 0x00, 0x03, 0x43, + 0x0b, 0x51, 0x80, 0x23, 0xdb, 0x01, 0x1a, 0x43, 0x11, 0x4b, 0x5a, 0x80, + 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, 0x30, 0xbd, 0x09, 0x23, + 0x14, 0x22, 0xdd, 0xe7, 0x0a, 0x23, 0x15, 0x22, 0xda, 0xe7, 0x0b, 0x23, + 0x16, 0x22, 0xd7, 0xe7, 0x0c, 0x23, 0x17, 0x22, 0xd4, 0xe7, 0x0d, 0x23, + 0x18, 0x22, 0xd1, 0xe7, 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, + 0x00, 0x10, 0x00, 0x42, 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, + 0x00, 0x1c, 0x00, 0x42, 0x00, 0xe1, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x40, + 0xf8, 0xb5, 0x04, 0x00, 0x0f, 0x00, 0x16, 0x00, 0x1d, 0x00, 0xff, 0xf7, + 0xa5, 0xff, 0x20, 0x00, 0xff, 0xf7, 0x04, 0xff, 0x1c, 0x21, 0xbb, 0x00, + 0x0b, 0x40, 0x71, 0x07, 0x22, 0x68, 0x09, 0x0c, 0x0b, 0x43, 0x13, 0x60, + 0x84, 0x23, 0x22, 0x68, 0x93, 0x75, 0x01, 0x2f, 0x1a, 0xd1, 0x10, 0x21, + 0x01, 0x2e, 0x00, 0xd0, 0x08, 0x39, 0x0c, 0x4b, 0x69, 0x43, 0x18, 0x68, + 0xc0, 0x00, 0x00, 0xf0, 0x2d, 0xff, 0x07, 0x22, 0x21, 0x68, 0x02, 0x40, + 0x8b, 0x89, 0x52, 0x03, 0xdb, 0x04, 0xdb, 0x0c, 0x13, 0x43, 0x8b, 0x81, + 0x22, 0x68, 0x03, 0x04, 0x90, 0x89, 0xdb, 0x0c, 0x40, 0x0b, 0x40, 0x03, + 0x18, 0x43, 0x90, 0x81, 0xf8, 0xbd, 0xc0, 0x46, 0x14, 0x00, 0x00, 0x20, + 0xf7, 0xb5, 0x06, 0x00, 0x01, 0x93, 0x08, 0xab, 0x1f, 0x78, 0x0d, 0x00, + 0x14, 0x00, 0xff, 0xf7, 0x3f, 0xff, 0x30, 0x00, 0xff, 0xf7, 0x6a, 0xff, + 0xc0, 0x22, 0x24, 0x05, 0x92, 0x03, 0x14, 0x40, 0xba, 0x07, 0x0c, 0x27, + 0x17, 0x43, 0x3c, 0x43, 0xc0, 0x27, 0x07, 0x22, 0xbf, 0x02, 0x2d, 0x04, + 0x33, 0x68, 0x3d, 0x40, 0x25, 0x43, 0x1d, 0x60, 0x01, 0x9b, 0x31, 0x68, + 0x13, 0x40, 0x1a, 0x00, 0x80, 0x23, 0x9b, 0x02, 0x13, 0x43, 0x4b, 0x60, + 0xf7, 0xbd, 0x00, 0x20, 0x70, 0x47, 0x70, 0xb5, 0x0f, 0x26, 0xcb, 0x1d, + 0x01, 0x39, 0x02, 0x00, 0x32, 0x40, 0xd5, 0xb2, 0x2c, 0x00, 0x00, 0x09, + 0x30, 0x34, 0x09, 0x2a, 0x00, 0xdd, 0x07, 0x34, 0x1c, 0x70, 0x01, 0x3b, + 0x8b, 0x42, 0xf2, 0xd1, 0x70, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x0c, 0x00, + 0x0b, 0x4b, 0x18, 0x68, 0xff, 0xf7, 0xe7, 0xff, 0x21, 0x00, 0x0a, 0x4b, + 0x08, 0x31, 0x18, 0x68, 0xff, 0xf7, 0xe1, 0xff, 0x21, 0x00, 0x08, 0x4b, + 0x10, 0x31, 0x18, 0x68, 0xff, 0xf7, 0xdb, 0xff, 0x21, 0x00, 0x06, 0x4b, + 0x18, 0x31, 0x18, 0x68, 0xff, 0xf7, 0xd5, 0xff, 0x20, 0x20, 0x10, 0xbd, + 0x0c, 0xa0, 0x80, 0x00, 0x40, 0xa0, 0x80, 0x00, 0x44, 0xa0, 0x80, 0x00, + 0x48, 0xa0, 0x80, 0x00, 0x08, 0xb4, 0x02, 0x4b, 0x9c, 0x46, 0x10, 0x38, + 0x08, 0xbc, 0x60, 0x47, 0xdd, 0x39, 0x00, 0x00, 0x70, 0x47, 0x3f, 0x20, + 0x70, 0x47, 0x13, 0xb5, 0x6b, 0x46, 0x02, 0x68, 0xd9, 0x71, 0x07, 0x33, + 0x54, 0x68, 0x19, 0x00, 0x01, 0x22, 0xa0, 0x47, 0x16, 0xbd, 0x00, 0x00, + 0x70, 0xb5, 0x0a, 0x26, 0x0b, 0x78, 0x92, 0xb0, 0x6e, 0x44, 0x02, 0x33, + 0x05, 0x00, 0x0b, 0x70, 0x3c, 0x22, 0x00, 0x21, 0x30, 0x00, 0x00, 0xf0, + 0x6a, 0xff, 0x39, 0x48, 0x01, 0xac, 0x06, 0x90, 0x38, 0x48, 0x24, 0x21, + 0x07, 0x90, 0x06, 0x20, 0x20, 0x77, 0x68, 0x46, 0x36, 0x4a, 0xa1, 0x74, + 0x22, 0x81, 0x36, 0x4a, 0x36, 0x4b, 0xa2, 0x81, 0xfd, 0x3a, 0xff, 0x3a, + 0x80, 0x18, 0xc1, 0x77, 0x68, 0x46, 0x23, 0x39, 0x06, 0x30, 0xc1, 0x77, + 0x68, 0x46, 0x07, 0x30, 0xc1, 0x77, 0x02, 0xa8, 0xc1, 0x77, 0x07, 0x20, + 0xf2, 0x77, 0x03, 0x26, 0x08, 0x31, 0x69, 0x44, 0xc8, 0x77, 0x03, 0xa9, + 0xce, 0x77, 0x10, 0x21, 0x2b, 0x36, 0x6e, 0x44, 0x31, 0x70, 0x09, 0x26, + 0x21, 0x85, 0x1f, 0x31, 0x69, 0x44, 0x0e, 0x70, 0x0c, 0xa9, 0x05, 0x3e, + 0x0e, 0x70, 0x33, 0x21, 0x23, 0x80, 0x02, 0x23, 0x69, 0x44, 0x0b, 0x70, + 0x06, 0x36, 0x0d, 0xa9, 0x0e, 0x70, 0x22, 0x49, 0x35, 0x36, 0xa1, 0x86, + 0x3b, 0x21, 0x6e, 0x44, 0x30, 0x70, 0x10, 0xa8, 0x62, 0x74, 0xe2, 0x77, + 0x02, 0x70, 0x3d, 0x32, 0x69, 0x44, 0x6a, 0x44, 0x0b, 0x70, 0x13, 0x70, + 0x40, 0x21, 0x00, 0x22, 0xe3, 0x70, 0x23, 0x71, 0x63, 0x71, 0xa3, 0x73, + 0x41, 0x33, 0x6b, 0x44, 0x21, 0x87, 0x19, 0x70, 0x5a, 0x70, 0x2b, 0x7d, + 0xc0, 0x39, 0xa3, 0x70, 0xa3, 0x72, 0x63, 0x77, 0x01, 0x33, 0xdb, 0xb2, + 0xa3, 0x77, 0x6a, 0x7d, 0x0b, 0x20, 0x0d, 0x00, 0x68, 0x44, 0x15, 0x43, + 0xc5, 0x77, 0x31, 0x20, 0x68, 0x44, 0x03, 0x70, 0x3a, 0x23, 0x50, 0x1c, + 0x6b, 0x44, 0x18, 0x70, 0x41, 0x23, 0x02, 0x32, 0x0a, 0x43, 0x6b, 0x44, + 0x1a, 0x70, 0x21, 0x00, 0x42, 0x22, 0x08, 0x48, 0x00, 0xf0, 0xd8, 0xfa, + 0x12, 0xb0, 0x70, 0xbd, 0x10, 0x01, 0x04, 0x24, 0x02, 0x06, 0x05, 0x24, + 0x09, 0x04, 0x00, 0x00, 0x01, 0x02, 0x00, 0x00, 0x08, 0x0b, 0x00, 0x00, + 0x07, 0x05, 0x00, 0x00, 0xe8, 0x1b, 0x00, 0x20, 0x08, 0xb4, 0x02, 0x4b, + 0x9c, 0x46, 0x10, 0x38, 0x08, 0xbc, 0x60, 0x47, 0x4d, 0x3a, 0x00, 0x00, + 0x70, 0xb5, 0x02, 0x7d, 0x0b, 0x79, 0x0c, 0x00, 0x00, 0x25, 0x9a, 0x42, + 0x0b, 0xd1, 0x0b, 0x78, 0x4e, 0x78, 0xa1, 0x2b, 0x09, 0xd1, 0x21, 0x2e, + 0x05, 0xd1, 0x07, 0x22, 0x1f, 0x49, 0x20, 0x48, 0x00, 0xf0, 0xae, 0xfa, + 0x01, 0x35, 0x28, 0x00, 0x70, 0xbd, 0x21, 0x2b, 0xfb, 0xd1, 0x20, 0x2e, + 0x2b, 0xd1, 0x07, 0x22, 0x19, 0x49, 0x1a, 0x48, 0x00, 0xf0, 0xe4, 0xf9, + 0x17, 0x4b, 0x1a, 0x78, 0x59, 0x78, 0x09, 0x02, 0x11, 0x43, 0x9a, 0x78, + 0x12, 0x04, 0x11, 0x43, 0xda, 0x78, 0x12, 0x06, 0x0a, 0x43, 0x96, 0x21, + 0xc9, 0x00, 0x8a, 0x42, 0x1d, 0xd1, 0xdb, 0x79, 0xdb, 0x07, 0x1a, 0xd4, + 0xfa, 0x20, 0xff, 0xf7, 0x1d, 0xfd, 0x00, 0x21, 0x0d, 0x48, 0x00, 0xf0, + 0xb3, 0xfa, 0x01, 0x25, 0x23, 0x2e, 0xd8, 0xd1, 0xe3, 0x78, 0xa2, 0x78, + 0x1b, 0x02, 0x13, 0x43, 0x09, 0x4a, 0x00, 0x21, 0x07, 0x48, 0x13, 0x60, + 0x00, 0xf0, 0xa6, 0xfa, 0xcd, 0xe7, 0x22, 0x2e, 0xef, 0xd1, 0x8a, 0x78, + 0x02, 0x4b, 0xda, 0x71, 0xd2, 0xe7, 0xff, 0xf7, 0x0d, 0xfd, 0xe4, 0xe7, + 0x20, 0x00, 0x00, 0x20, 0xe8, 0x1b, 0x00, 0x20, 0x1c, 0x00, 0x00, 0x20, + 0x08, 0xb4, 0x02, 0x4b, 0x9c, 0x46, 0x10, 0x38, 0x08, 0xbc, 0x60, 0x47, + 0x79, 0x3b, 0x00, 0x00, 0x10, 0xb5, 0x41, 0x7d, 0x00, 0x6a, 0x01, 0x31, + 0x00, 0xf0, 0xd8, 0xf8, 0x03, 0x4b, 0x1b, 0x68, 0x01, 0x33, 0x5a, 0x1e, + 0x93, 0x41, 0x18, 0x18, 0x10, 0xbd, 0xc0, 0x46, 0x28, 0x00, 0x00, 0x20, + 0x10, 0xb5, 0x41, 0x7d, 0x00, 0x6a, 0x02, 0x31, 0x00, 0xf0, 0xde, 0xf8, + 0x10, 0xbd, 0x10, 0xb5, 0x41, 0x7d, 0x00, 0x6a, 0x02, 0x31, 0x00, 0xf0, + 0xa5, 0xf8, 0x10, 0xbd, 0x70, 0xb5, 0x0d, 0x00, 0x41, 0x7d, 0x04, 0x00, + 0x13, 0x00, 0x02, 0x31, 0x2a, 0x00, 0x00, 0x6a, 0x00, 0xf0, 0x92, 0xf9, + 0x00, 0x28, 0x01, 0xd1, 0x01, 0x23, 0x63, 0x60, 0x70, 0xbd, 0x00, 0x00, + 0x10, 0xb5, 0x05, 0x4c, 0x23, 0x68, 0x5a, 0x1c, 0x04, 0xd1, 0x03, 0x68, + 0x5b, 0x69, 0x98, 0x47, 0x03, 0x00, 0x20, 0x60, 0x18, 0x00, 0x10, 0xbd, + 0x28, 0x00, 0x00, 0x20, 0x07, 0x4a, 0x03, 0x00, 0x10, 0x68, 0x10, 0xb5, + 0x41, 0x1c, 0x03, 0xd0, 0x01, 0x23, 0x5b, 0x42, 0x13, 0x60, 0x10, 0xbd, + 0x59, 0x7d, 0x18, 0x6a, 0x01, 0x31, 0x00, 0xf0, 0x1f, 0xf9, 0xf8, 0xe7, + 0x28, 0x00, 0x00, 0x20, 0x70, 0x47, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, + 0xfa, 0x23, 0x9b, 0x00, 0x10, 0xb5, 0x83, 0x60, 0x0f, 0x4b, 0x00, 0x22, + 0xc3, 0x82, 0x03, 0x00, 0x28, 0x33, 0x83, 0x61, 0x0d, 0x4b, 0x04, 0x00, + 0x42, 0x60, 0xc2, 0x61, 0x18, 0x00, 0x44, 0x33, 0x23, 0x61, 0x08, 0x30, + 0x63, 0x1d, 0x21, 0x62, 0x20, 0x60, 0xda, 0x77, 0x83, 0x23, 0xa3, 0x62, + 0x81, 0x3b, 0xe3, 0x62, 0x80, 0x33, 0x23, 0x63, 0x00, 0xf0, 0x40, 0xf8, + 0x21, 0x00, 0x10, 0x31, 0x00, 0xf0, 0x10, 0xf8, 0x20, 0x00, 0x10, 0xbd, + 0x03, 0x02, 0x00, 0x00, 0x8c, 0x58, 0x00, 0x00, 0x10, 0xb5, 0x02, 0x49, + 0x02, 0x48, 0xff, 0xf7, 0xd3, 0xff, 0x10, 0xbd, 0xe8, 0x1b, 0x00, 0x20, + 0x80, 0x1b, 0x00, 0x20, 0xf0, 0xb5, 0x8c, 0x79, 0x45, 0x78, 0x03, 0x00, + 0x2a, 0x19, 0x00, 0x20, 0x07, 0x2a, 0x1f, 0xdc, 0x5a, 0x68, 0x82, 0x42, + 0x16, 0xd1, 0x59, 0x60, 0x1a, 0x78, 0xc8, 0x79, 0x0a, 0x71, 0x12, 0x18, + 0x4d, 0x71, 0x1a, 0x70, 0x00, 0x22, 0x0b, 0x4d, 0xd0, 0xb2, 0x84, 0x42, + 0x0f, 0xd9, 0x8f, 0x68, 0x58, 0x78, 0x96, 0x00, 0xf7, 0x59, 0x86, 0x00, + 0x01, 0x30, 0x77, 0x51, 0x01, 0x32, 0x58, 0x70, 0xf2, 0xe7, 0x02, 0x00, + 0xd0, 0x68, 0x00, 0x28, 0xfb, 0xd1, 0xd1, 0x60, 0xe4, 0xe7, 0x01, 0x20, + 0xf0, 0xbd, 0xc0, 0x46, 0xc0, 0x1b, 0x00, 0x20, 0x01, 0x21, 0x06, 0x4a, + 0x10, 0xb5, 0x13, 0x68, 0x05, 0x48, 0x0b, 0x40, 0x04, 0xd1, 0x80, 0x24, + 0x64, 0x00, 0x04, 0x80, 0x43, 0x60, 0x11, 0x60, 0x10, 0xbd, 0xc0, 0x46, + 0xb4, 0x1b, 0x00, 0x20, 0xb8, 0x1b, 0x00, 0x20, 0x0b, 0x4b, 0xca, 0xb2, + 0x0b, 0x48, 0x89, 0x01, 0xc9, 0x18, 0x53, 0x01, 0xc3, 0x18, 0x59, 0x61, + 0x99, 0x69, 0x08, 0x32, 0x89, 0x0b, 0x89, 0x03, 0x99, 0x61, 0x03, 0x68, + 0x52, 0x01, 0x9a, 0x18, 0x02, 0x23, 0xd3, 0x71, 0x51, 0x79, 0x82, 0x3b, + 0x0b, 0x43, 0x53, 0x71, 0x70, 0x47, 0xc0, 0x46, 0x10, 0x1c, 0x00, 0x20, + 0x98, 0x20, 0x00, 0x20, 0x08, 0x4b, 0x8a, 0x00, 0xd0, 0x58, 0x10, 0xb5, + 0x00, 0x28, 0x03, 0xd0, 0x03, 0x68, 0x9b, 0x68, 0x98, 0x47, 0x10, 0xbd, + 0xc9, 0xb2, 0x04, 0x4b, 0x49, 0x01, 0x59, 0x18, 0x88, 0x68, 0x80, 0x04, + 0x80, 0x0c, 0xf6, 0xe7, 0xec, 0x1b, 0x00, 0x20, 0x98, 0x20, 0x00, 0x20, + 0x10, 0xb5, 0x0c, 0x00, 0xff, 0xf7, 0xe6, 0xff, 0x00, 0x28, 0x0c, 0xd0, + 0x06, 0x4b, 0xe4, 0xb2, 0x1b, 0x68, 0x08, 0x34, 0x64, 0x01, 0x1c, 0x19, + 0x80, 0x23, 0x62, 0x79, 0x5b, 0x42, 0x13, 0x43, 0x63, 0x71, 0x02, 0x23, + 0xe3, 0x71, 0x10, 0xbd, 0x98, 0x20, 0x00, 0x20, 0xf0, 0xb5, 0x1c, 0x00, + 0x2a, 0x4b, 0x85, 0xb0, 0x1b, 0x68, 0x07, 0x00, 0x0d, 0x00, 0x02, 0x92, + 0x00, 0x2b, 0x4a, 0xd0, 0x27, 0x4b, 0x8a, 0x00, 0xd0, 0x58, 0x00, 0x28, + 0x08, 0xd0, 0x03, 0x68, 0x22, 0x00, 0x5b, 0x68, 0x02, 0x99, 0x98, 0x47, + 0x04, 0x00, 0x20, 0x00, 0x05, 0xb0, 0xf0, 0xbd, 0x38, 0x00, 0xff, 0xf7, + 0xb9, 0xff, 0x84, 0x42, 0x04, 0xd9, 0x29, 0x00, 0x38, 0x00, 0xff, 0xf7, + 0xb3, 0xff, 0x04, 0x00, 0x01, 0x21, 0xeb, 0xb2, 0x1b, 0x4e, 0x03, 0x93, + 0x5b, 0x01, 0x01, 0x93, 0xf2, 0x18, 0x93, 0x68, 0x9b, 0x0b, 0x9b, 0x03, + 0x93, 0x60, 0x01, 0x9a, 0x33, 0x68, 0x02, 0x98, 0x9b, 0x18, 0xff, 0x33, + 0x5a, 0x7a, 0x0a, 0x43, 0x5a, 0x72, 0x14, 0x4b, 0xa9, 0x01, 0xc9, 0x18, + 0x22, 0x00, 0x00, 0xf0, 0x37, 0xfd, 0x00, 0x2c, 0xd7, 0xd0, 0x29, 0x00, + 0x38, 0x00, 0xff, 0xf7, 0x93, 0xff, 0x00, 0x28, 0xd1, 0xd1, 0x40, 0x21, + 0x03, 0x9b, 0x32, 0x68, 0x08, 0x33, 0x5b, 0x01, 0xd3, 0x18, 0x18, 0x79, + 0x01, 0x43, 0x19, 0x71, 0x01, 0x21, 0xd9, 0x71, 0x01, 0x9b, 0xd3, 0x18, + 0xff, 0x33, 0x9a, 0x7a, 0x0a, 0x43, 0x9a, 0x72, 0xbf, 0xe7, 0x01, 0x24, + 0x64, 0x42, 0xbc, 0xe7, 0x94, 0x20, 0x00, 0x20, 0xec, 0x1b, 0x00, 0x20, + 0x98, 0x20, 0x00, 0x20, 0xd0, 0x1d, 0x00, 0x20, 0x13, 0xb5, 0x6b, 0x46, + 0xdc, 0x1d, 0x22, 0x00, 0x01, 0x23, 0xff, 0xf7, 0x99, 0xff, 0x01, 0x28, + 0x01, 0xd1, 0x20, 0x78, 0x16, 0xbd, 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, + 0x70, 0xb5, 0xcb, 0xb2, 0x12, 0x4a, 0x13, 0x48, 0x5c, 0x01, 0x89, 0x01, + 0x89, 0x18, 0x02, 0x19, 0x51, 0x60, 0x91, 0x68, 0x10, 0x4d, 0x08, 0x33, + 0x0d, 0x40, 0x80, 0x21, 0x49, 0x03, 0x29, 0x43, 0x40, 0x25, 0x91, 0x60, + 0x91, 0x68, 0x89, 0x0b, 0x89, 0x03, 0x91, 0x60, 0x01, 0x68, 0x5a, 0x01, + 0x8a, 0x18, 0x16, 0x79, 0x35, 0x43, 0x15, 0x71, 0x95, 0x79, 0x6d, 0x06, + 0xfc, 0xd5, 0x5b, 0x01, 0xc9, 0x18, 0xcb, 0x79, 0xdb, 0x07, 0xfc, 0xd5, + 0x00, 0x19, 0x80, 0x68, 0xc0, 0xb2, 0x70, 0xbd, 0xd0, 0x1d, 0x00, 0x20, + 0x98, 0x20, 0x00, 0x20, 0xff, 0x3f, 0x00, 0xf0, 0x70, 0xb5, 0x0d, 0x00, + 0x00, 0x21, 0x14, 0x00, 0xff, 0xf7, 0xcc, 0xff, 0xa0, 0x42, 0x00, 0xd9, + 0x20, 0x00, 0x00, 0x23, 0x03, 0x49, 0xa3, 0x42, 0x03, 0xd0, 0xca, 0x5c, + 0xea, 0x54, 0x01, 0x33, 0xf9, 0xe7, 0x70, 0xbd, 0xd0, 0x1d, 0x00, 0x20, + 0xf0, 0xb5, 0x1e, 0x00, 0x3a, 0x4b, 0x85, 0xb0, 0x1b, 0x68, 0x0f, 0x00, + 0x01, 0x92, 0x00, 0x2b, 0x35, 0xd0, 0x80, 0x23, 0xdb, 0x01, 0x9e, 0x42, + 0x31, 0xd8, 0x00, 0x25, 0x35, 0x4b, 0x8a, 0x01, 0xd3, 0x18, 0x02, 0x93, + 0x00, 0x2e, 0x2c, 0xd0, 0x33, 0x4b, 0x1b, 0x68, 0x03, 0x93, 0xff, 0x23, + 0x3b, 0x40, 0x1c, 0x00, 0x00, 0x93, 0x08, 0x34, 0x03, 0x9b, 0x64, 0x01, + 0x1c, 0x19, 0xa3, 0x79, 0xdb, 0x09, 0x21, 0xd0, 0x2d, 0x4b, 0x2e, 0x49, + 0x18, 0x68, 0x00, 0xf0, 0xd3, 0xfb, 0x2d, 0x4b, 0x17, 0x21, 0x58, 0x43, + 0x00, 0xf0, 0xce, 0xfb, 0x2b, 0x4b, 0xe2, 0x79, 0x92, 0x07, 0x13, 0xd4, + 0xda, 0x5d, 0x00, 0x2a, 0x01, 0xd1, 0x01, 0x38, 0xf7, 0xd2, 0x01, 0x22, + 0xda, 0x55, 0x00, 0x9b, 0x5a, 0x01, 0x21, 0x4b, 0x9b, 0x18, 0x9a, 0x69, + 0x92, 0x0b, 0x92, 0x03, 0x9a, 0x61, 0x01, 0x25, 0x6d, 0x42, 0x28, 0x00, + 0x05, 0xb0, 0xf0, 0xbd, 0x00, 0x22, 0x1f, 0x4b, 0x34, 0x00, 0xda, 0x55, + 0x3f, 0x2e, 0x09, 0xd9, 0x00, 0x9b, 0x40, 0x24, 0x5a, 0x01, 0x17, 0x4b, + 0x9b, 0x18, 0x80, 0x22, 0x99, 0x69, 0x12, 0x06, 0x0a, 0x43, 0x9a, 0x61, + 0x22, 0x00, 0x01, 0x99, 0x02, 0x98, 0x00, 0xf0, 0x69, 0xfc, 0x00, 0x9b, + 0xa1, 0x04, 0x5a, 0x01, 0x0f, 0x4b, 0x89, 0x0c, 0x9b, 0x18, 0x02, 0x9a, + 0x2d, 0x19, 0x5a, 0x61, 0x9a, 0x69, 0x36, 0x1b, 0x92, 0x0b, 0x92, 0x03, + 0x0a, 0x43, 0x9a, 0x61, 0x00, 0x9b, 0x03, 0x9a, 0x08, 0x33, 0x5b, 0x01, + 0xd3, 0x18, 0x02, 0x22, 0xda, 0x71, 0x59, 0x79, 0x82, 0x3a, 0x0a, 0x43, + 0x5a, 0x71, 0x01, 0x9b, 0x1b, 0x19, 0x01, 0x93, 0x9a, 0xe7, 0xc0, 0x46, + 0x94, 0x20, 0x00, 0x20, 0x10, 0x1c, 0x00, 0x20, 0x98, 0x20, 0x00, 0x20, + 0x14, 0x00, 0x00, 0x20, 0x40, 0x42, 0x0f, 0x00, 0x70, 0x11, 0x01, 0x00, + 0x08, 0x1c, 0x00, 0x20, 0x70, 0xb5, 0x0d, 0x00, 0x1c, 0x00, 0x0d, 0x4b, + 0xae, 0x01, 0xf6, 0x18, 0x11, 0x00, 0x30, 0x00, 0x22, 0x00, 0x00, 0xf0, + 0x31, 0xfc, 0xed, 0xb2, 0x09, 0x49, 0x6d, 0x01, 0x4d, 0x19, 0x6e, 0x61, + 0xab, 0x69, 0x08, 0x4a, 0x20, 0x00, 0x13, 0x40, 0xab, 0x61, 0xab, 0x69, + 0xa2, 0x04, 0x9b, 0x0b, 0x92, 0x0c, 0x9b, 0x03, 0x13, 0x43, 0xab, 0x61, + 0x70, 0xbd, 0xc0, 0x46, 0x10, 0x1c, 0x00, 0x20, 0x98, 0x20, 0x00, 0x20, + 0xff, 0x3f, 0x00, 0xf0, 0xf7, 0xb5, 0x10, 0x4b, 0x01, 0x90, 0x1b, 0x78, + 0x0f, 0x00, 0x15, 0x00, 0x00, 0x2b, 0x0c, 0xd1, 0x0d, 0x4b, 0x16, 0x00, + 0x1c, 0x78, 0x00, 0x2c, 0x09, 0xd0, 0x0c, 0x4e, 0x0c, 0x48, 0x34, 0x88, + 0x20, 0x18, 0x64, 0x19, 0x00, 0xf0, 0x04, 0xfc, 0x34, 0x80, 0x28, 0x00, + 0xfe, 0xbd, 0x00, 0x2e, 0xfb, 0xd0, 0x3a, 0x19, 0x33, 0x00, 0x00, 0x21, + 0x01, 0x98, 0xff, 0xf7, 0xbd, 0xff, 0x24, 0x18, 0x36, 0x1a, 0xf4, 0xe7, + 0x90, 0x1f, 0x00, 0x20, 0x91, 0x20, 0x00, 0x20, 0x92, 0x20, 0x00, 0x20, + 0x91, 0x1f, 0x00, 0x20, 0xcb, 0xb2, 0x04, 0x49, 0x5b, 0x01, 0xc9, 0x18, + 0x8b, 0x69, 0x9b, 0x0b, 0x9b, 0x03, 0x8b, 0x61, 0x70, 0x47, 0xc0, 0x46, + 0x98, 0x20, 0x00, 0x20, 0x01, 0x4b, 0x02, 0x4a, 0x1a, 0x60, 0x70, 0x47, + 0x98, 0x20, 0x00, 0x20, 0x00, 0x50, 0x00, 0x41, 0x01, 0x20, 0x70, 0x47, + 0x10, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, 0x98, 0x47, 0x10, 0xbd, + 0x13, 0x04, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, 0xd9, 0x69, 0x9a, 0x69, + 0x91, 0x42, 0x03, 0xd0, 0xdb, 0x69, 0xc0, 0x18, 0x00, 0x7d, 0x70, 0x47, + 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x69, + 0xff, 0xf7, 0xb6, 0xfa, 0x22, 0x00, 0x00, 0x23, 0xfc, 0x32, 0x93, 0x61, + 0xd3, 0x61, 0x86, 0x22, 0x92, 0x00, 0xa4, 0x18, 0x63, 0x60, 0xa3, 0x60, + 0x10, 0xbd, 0xf0, 0x20, 0x01, 0x40, 0x30, 0x39, 0x48, 0x42, 0x48, 0x41, + 0x70, 0x47, 0xf0, 0x23, 0x1b, 0x01, 0x19, 0x40, 0x80, 0x23, 0x06, 0x20, + 0x9b, 0x00, 0x99, 0x42, 0x0a, 0xd0, 0x01, 0x33, 0xff, 0x33, 0x01, 0x30, + 0x99, 0x42, 0x05, 0xd0, 0x80, 0x23, 0x02, 0x38, 0x5b, 0x00, 0x99, 0x42, + 0x00, 0xd0, 0x00, 0x20, 0x70, 0x47, 0x0f, 0x20, 0x01, 0x40, 0x00, 0x20, + 0x01, 0x29, 0x03, 0xd0, 0x02, 0x39, 0x48, 0x1e, 0x81, 0x41, 0x48, 0x1c, + 0x70, 0x47, 0x00, 0x00, 0x89, 0x23, 0xf0, 0xb5, 0x18, 0x26, 0x85, 0xb0, + 0x02, 0x91, 0x9b, 0x00, 0x04, 0x00, 0xc0, 0x5c, 0x33, 0x00, 0x08, 0x21, + 0x43, 0x43, 0x32, 0x4d, 0x17, 0x00, 0xeb, 0x18, 0x59, 0x56, 0xff, 0xf7, + 0x03, 0xf9, 0x30, 0x4b, 0x08, 0x21, 0xe0, 0x5c, 0x33, 0x00, 0x43, 0x43, + 0xeb, 0x18, 0x59, 0x56, 0xff, 0xf7, 0xfa, 0xf8, 0x2c, 0x4b, 0xe2, 0x5c, + 0x03, 0x93, 0x02, 0x2a, 0x09, 0xd1, 0x11, 0x33, 0xe0, 0x5c, 0xff, 0x28, + 0x05, 0xd0, 0x08, 0x21, 0x46, 0x43, 0xae, 0x19, 0x71, 0x56, 0xff, 0xf7, + 0xeb, 0xf8, 0x8a, 0x26, 0xb6, 0x00, 0xa0, 0x5d, 0xff, 0x28, 0x19, 0xd0, + 0x01, 0x21, 0xff, 0xf7, 0x53, 0xf8, 0x18, 0x22, 0xa3, 0x5d, 0x21, 0x49, + 0x5a, 0x43, 0xab, 0x56, 0xad, 0x18, 0xdb, 0x01, 0x58, 0x18, 0x8b, 0x21, + 0x89, 0x00, 0x60, 0x50, 0x1d, 0x49, 0x01, 0x22, 0x5b, 0x18, 0x8c, 0x21, + 0x89, 0x00, 0x63, 0x50, 0x69, 0x68, 0x8a, 0x40, 0x8d, 0x21, 0x89, 0x00, + 0x62, 0x50, 0x1a, 0x60, 0x01, 0x22, 0x02, 0x9b, 0x11, 0x00, 0x20, 0x69, + 0xff, 0xf7, 0x2a, 0xfb, 0x39, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x8f, 0xff, + 0x39, 0x00, 0x05, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x9e, 0xff, 0x39, 0x00, + 0x06, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x7f, 0xff, 0x33, 0x00, 0x00, 0x90, + 0x29, 0x00, 0x20, 0x69, 0x01, 0x22, 0xff, 0xf7, 0xf3, 0xf9, 0x0b, 0x4b, + 0x20, 0x69, 0xe2, 0x5c, 0x03, 0x9b, 0xe1, 0x5c, 0xff, 0xf7, 0x09, 0xfa, + 0x20, 0x69, 0xff, 0xf7, 0x26, 0xfa, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, + 0x20, 0x55, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, 0x27, 0x02, 0x00, 0x00, + 0x18, 0x44, 0x00, 0x41, 0x14, 0x44, 0x00, 0x41, 0x26, 0x02, 0x00, 0x00, + 0x80, 0x22, 0x10, 0xb5, 0x04, 0x00, 0x52, 0x00, 0x00, 0x21, 0x00, 0xf0, + 0x14, 0xfb, 0x23, 0x00, 0x00, 0x22, 0xfc, 0x33, 0x5a, 0x60, 0x20, 0x00, + 0x9a, 0x60, 0x10, 0xbd, 0xf0, 0xb5, 0x85, 0xb0, 0x1d, 0x00, 0x0a, 0xab, + 0x1b, 0x78, 0x04, 0x00, 0x00, 0x93, 0x0b, 0xab, 0x1b, 0x78, 0x16, 0x00, + 0x01, 0x93, 0x0c, 0xab, 0x1b, 0x78, 0x0f, 0x00, 0x02, 0x93, 0x0d, 0xab, + 0x1b, 0x78, 0x03, 0x93, 0x00, 0x23, 0x43, 0x60, 0xfa, 0x23, 0x9b, 0x00, + 0x83, 0x60, 0x12, 0x4b, 0x08, 0x33, 0x03, 0x60, 0x14, 0x30, 0xff, 0xf7, + 0xd5, 0xff, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0xd0, 0xff, + 0x89, 0x23, 0x6a, 0x46, 0x9b, 0x00, 0x27, 0x61, 0xe6, 0x54, 0x0b, 0x4b, + 0x12, 0x78, 0xe5, 0x54, 0x0a, 0x4b, 0x20, 0x00, 0xe2, 0x54, 0x6a, 0x46, + 0x09, 0x4b, 0x12, 0x79, 0xe2, 0x54, 0x6a, 0x46, 0x12, 0x7a, 0x01, 0x33, + 0xe2, 0x54, 0x6a, 0x46, 0x12, 0x7b, 0x10, 0x33, 0xe2, 0x54, 0x05, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0xe4, 0x58, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, + 0x26, 0x02, 0x00, 0x00, 0x27, 0x02, 0x00, 0x00, 0xf7, 0xb5, 0x1d, 0x00, + 0x08, 0xab, 0x1b, 0x78, 0x04, 0x00, 0x00, 0x93, 0x09, 0xab, 0x1b, 0x78, + 0x16, 0x00, 0x01, 0x93, 0x00, 0x23, 0x43, 0x60, 0xfa, 0x23, 0x9b, 0x00, + 0x83, 0x60, 0x11, 0x4b, 0x0f, 0x00, 0x08, 0x33, 0x03, 0x60, 0x14, 0x30, + 0xff, 0xf7, 0x98, 0xff, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, + 0x93, 0xff, 0x89, 0x23, 0x6a, 0x46, 0x9b, 0x00, 0x27, 0x61, 0xe6, 0x54, + 0x09, 0x4b, 0x12, 0x78, 0xe5, 0x54, 0x09, 0x4b, 0x20, 0x00, 0xe2, 0x54, + 0x6a, 0x46, 0x08, 0x4b, 0x12, 0x79, 0xe2, 0x54, 0x8a, 0x22, 0x29, 0x3b, + 0xff, 0x3b, 0x92, 0x00, 0xa3, 0x54, 0x10, 0x32, 0xa3, 0x54, 0xfe, 0xbd, + 0xe4, 0x58, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, 0x26, 0x02, 0x00, 0x00, + 0x27, 0x02, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, 0x58, 0x68, 0x9b, 0x68, + 0xc0, 0x1a, 0x01, 0xd5, 0x01, 0x30, 0xff, 0x30, 0x70, 0x47, 0x10, 0xb5, + 0x04, 0x00, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0xf0, 0xff, + 0x00, 0x28, 0xf8, 0xd1, 0x20, 0x69, 0xff, 0xf7, 0x80, 0xf9, 0x10, 0xbd, + 0x10, 0xb5, 0x14, 0x30, 0xff, 0xf7, 0xe6, 0xff, 0x10, 0xbd, 0x03, 0x00, + 0xfc, 0x33, 0x59, 0x68, 0x9a, 0x68, 0x91, 0x42, 0x04, 0xdb, 0x5a, 0x68, + 0x98, 0x68, 0x80, 0x1a, 0xff, 0x30, 0x70, 0x47, 0x98, 0x68, 0x5b, 0x68, + 0xc0, 0x1a, 0x01, 0x38, 0xf9, 0xe7, 0x10, 0xb5, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0xeb, 0xff, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x69, + 0xff, 0xf7, 0x7b, 0xf9, 0x00, 0x28, 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, + 0x86, 0xf9, 0x20, 0x69, 0xff, 0xf7, 0x78, 0xf9, 0x20, 0x69, 0xff, 0xf7, + 0x60, 0xf9, 0x00, 0x28, 0x20, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x7b, 0xf9, + 0x22, 0x00, 0xfc, 0x32, 0x93, 0x69, 0xd1, 0x69, 0x01, 0x33, 0xdb, 0xb2, + 0x8b, 0x42, 0x03, 0xd0, 0x91, 0x69, 0x61, 0x18, 0x08, 0x75, 0x93, 0x61, + 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, 0x20, 0x00, + 0x14, 0x30, 0xff, 0xf7, 0xc0, 0xff, 0x09, 0x28, 0x06, 0xdc, 0x8b, 0x23, + 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, 0x1a, 0x60, + 0x20, 0x69, 0xff, 0xf7, 0x55, 0xf9, 0x00, 0x28, 0x1a, 0xd0, 0x20, 0x00, + 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0x92, 0xff, 0x00, 0x28, 0x22, 0xd0, + 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x99, 0x68, 0x5a, 0x68, 0x91, 0x42, + 0x18, 0xd0, 0x8e, 0x21, 0x9a, 0x68, 0x49, 0x00, 0xa2, 0x18, 0x51, 0x5c, + 0x9a, 0x68, 0x01, 0x32, 0xd2, 0xb2, 0x9a, 0x60, 0xc9, 0xb2, 0x20, 0x69, + 0xff, 0xf7, 0x41, 0xf9, 0x20, 0x69, 0xff, 0xf7, 0x1f, 0xf9, 0x00, 0x28, + 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x1e, 0xf9, 0x20, 0x69, 0xff, 0xf7, + 0x0e, 0xf9, 0x10, 0xbd, 0x01, 0x21, 0x49, 0x42, 0xec, 0xe7, 0x20, 0x69, + 0xff, 0xf7, 0x3b, 0xf9, 0xec, 0xe7, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x00, + 0x00, 0x69, 0x0d, 0x00, 0xff, 0xf7, 0x1e, 0xf9, 0x00, 0x28, 0x3e, 0xd1, + 0xff, 0x26, 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x5a, 0x68, 0x99, 0x68, + 0x01, 0x32, 0x32, 0x40, 0x8a, 0x42, 0x23, 0xd1, 0xef, 0xf3, 0x10, 0x83, + 0xdb, 0x07, 0x10, 0xd4, 0x1e, 0x4b, 0x5b, 0x68, 0xdb, 0x05, 0xdb, 0x0d, + 0xed, 0xd0, 0x10, 0x3b, 0x5b, 0xb2, 0x00, 0x2b, 0x10, 0xda, 0x0f, 0x22, + 0x13, 0x40, 0x08, 0x3b, 0x9b, 0x08, 0x19, 0x4a, 0x9b, 0x00, 0x9b, 0x18, + 0x1b, 0x68, 0x20, 0x69, 0xff, 0xf7, 0xfa, 0xf8, 0x00, 0x28, 0xdc, 0xd0, + 0x20, 0x00, 0xff, 0xf7, 0x6a, 0xff, 0xd8, 0xe7, 0x9b, 0x08, 0xc0, 0x33, + 0x12, 0x4a, 0x9b, 0x00, 0x9b, 0x58, 0xf0, 0xe7, 0x5a, 0x68, 0x01, 0x32, + 0x16, 0x40, 0x9a, 0x68, 0x96, 0x42, 0x05, 0xd0, 0x8e, 0x21, 0x5a, 0x68, + 0x49, 0x00, 0xa2, 0x18, 0x55, 0x54, 0x5e, 0x60, 0x20, 0x69, 0xff, 0xf7, + 0xf0, 0xf8, 0x01, 0x20, 0x70, 0xbd, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0x1c, 0xff, 0x00, 0x28, 0xb9, 0xd1, 0x29, 0x00, 0x20, 0x69, + 0xff, 0xf7, 0xdb, 0xf8, 0xf1, 0xe7, 0xc0, 0x46, 0x00, 0xed, 0x00, 0xe0, + 0x1c, 0xed, 0x00, 0xe0, 0x00, 0xe1, 0x00, 0xe0, 0x03, 0x00, 0x70, 0xb5, + 0xfc, 0x33, 0xd9, 0x69, 0x9a, 0x69, 0x04, 0x00, 0x91, 0x42, 0x1a, 0xd0, + 0xda, 0x69, 0x82, 0x18, 0x15, 0x7d, 0xda, 0x69, 0x01, 0x32, 0xd2, 0xb2, + 0xda, 0x61, 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, + 0x20, 0x00, 0x14, 0x30, 0xff, 0xf7, 0x11, 0xff, 0x0a, 0x28, 0x06, 0xdd, + 0x8c, 0x23, 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, + 0x1a, 0x60, 0x28, 0x00, 0x70, 0xbd, 0x01, 0x25, 0x6d, 0x42, 0xe8, 0xe7, + 0x10, 0xb5, 0x04, 0x00, 0x00, 0x68, 0x00, 0xf0, 0x5f, 0xf9, 0x20, 0x00, + 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x68, 0x00, 0x28, 0x01, 0xd0, + 0x00, 0xf0, 0x56, 0xf9, 0x00, 0x23, 0x23, 0x60, 0xa3, 0x60, 0x63, 0x60, + 0x10, 0xbd, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x00, 0x68, 0x01, 0x31, + 0x00, 0xf0, 0x0e, 0xfa, 0x03, 0x1e, 0x01, 0xd0, 0x01, 0x20, 0x28, 0xc4, + 0x70, 0xbd, 0x03, 0x68, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x2b, 0x04, 0xd0, + 0x43, 0x68, 0x8b, 0x42, 0x01, 0xd3, 0x01, 0x20, 0x10, 0xbd, 0x20, 0x00, + 0xff, 0xf7, 0xe7, 0xff, 0x00, 0x28, 0xf9, 0xd0, 0xa3, 0x68, 0x00, 0x2b, + 0xf5, 0xd1, 0x22, 0x68, 0x13, 0x70, 0xf2, 0xe7, 0x70, 0xb5, 0x0e, 0x00, + 0x11, 0x00, 0x04, 0x00, 0x15, 0x00, 0xff, 0xf7, 0xe4, 0xff, 0x00, 0x28, + 0x04, 0xd1, 0x20, 0x00, 0xff, 0xf7, 0xc7, 0xff, 0x20, 0x00, 0x70, 0xbd, + 0xa5, 0x60, 0x31, 0x00, 0x20, 0x68, 0x00, 0xf0, 0x07, 0xfa, 0xf7, 0xe7, + 0x00, 0x23, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x03, 0x60, 0x43, 0x60, + 0x83, 0x60, 0x99, 0x42, 0x07, 0xd0, 0x08, 0x00, 0x00, 0xf0, 0x02, 0xfa, + 0x29, 0x00, 0x02, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xdb, 0xff, 0x20, 0x00, + 0x70, 0xbd, 0x70, 0xb5, 0x05, 0x00, 0x08, 0x00, 0x0c, 0x00, 0x00, 0xf0, + 0xf5, 0xf9, 0x21, 0x00, 0x02, 0x00, 0x28, 0x00, 0xff, 0xf7, 0xce, 0xff, + 0x70, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x29, 0x03, 0xd0, 0xff, 0xf7, + 0xee, 0xff, 0x20, 0x00, 0x10, 0xbd, 0xff, 0xf7, 0x96, 0xff, 0xfa, 0xe7, + 0x02, 0x68, 0x10, 0xb5, 0x0b, 0x68, 0x00, 0x2a, 0x13, 0xd0, 0x00, 0x2b, + 0x0c, 0xd1, 0x81, 0x68, 0x18, 0x00, 0x00, 0x29, 0x07, 0xd0, 0x10, 0x78, + 0x05, 0xe0, 0x89, 0x68, 0x10, 0x00, 0x00, 0x29, 0x01, 0xd0, 0x18, 0x78, + 0x40, 0x42, 0x10, 0xbd, 0x19, 0x00, 0x10, 0x00, 0x00, 0xf0, 0xba, 0xf9, + 0xf9, 0xe7, 0x00, 0x2b, 0xf1, 0xd1, 0x18, 0x00, 0xf5, 0xe7, 0x10, 0xb5, + 0xff, 0xf7, 0xe0, 0xff, 0xc0, 0x0f, 0x10, 0xbd, 0x0b, 0x00, 0x10, 0xb5, + 0x01, 0x00, 0x18, 0x00, 0x00, 0xf0, 0x98, 0xf8, 0x10, 0xbd, 0x00, 0x00, + 0x02, 0xb4, 0x71, 0x46, 0x49, 0x08, 0x49, 0x00, 0x09, 0x5c, 0x49, 0x00, + 0x8e, 0x44, 0x02, 0xbc, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x22, 0x43, 0x08, + 0x8b, 0x42, 0x74, 0xd3, 0x03, 0x09, 0x8b, 0x42, 0x5f, 0xd3, 0x03, 0x0a, + 0x8b, 0x42, 0x44, 0xd3, 0x03, 0x0b, 0x8b, 0x42, 0x28, 0xd3, 0x03, 0x0c, + 0x8b, 0x42, 0x0d, 0xd3, 0xff, 0x22, 0x09, 0x02, 0x12, 0xba, 0x03, 0x0c, + 0x8b, 0x42, 0x02, 0xd3, 0x12, 0x12, 0x09, 0x02, 0x65, 0xd0, 0x03, 0x0b, + 0x8b, 0x42, 0x19, 0xd3, 0x00, 0xe0, 0x09, 0x0a, 0xc3, 0x0b, 0x8b, 0x42, + 0x01, 0xd3, 0xcb, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0b, 0x8b, 0x42, + 0x01, 0xd3, 0x8b, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0b, 0x8b, 0x42, + 0x01, 0xd3, 0x4b, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0b, 0x8b, 0x42, + 0x01, 0xd3, 0x0b, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x0a, 0x8b, 0x42, + 0x01, 0xd3, 0xcb, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0a, 0x8b, 0x42, + 0x01, 0xd3, 0x8b, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0a, 0x8b, 0x42, + 0x01, 0xd3, 0x4b, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0a, 0x8b, 0x42, + 0x01, 0xd3, 0x0b, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0xcd, 0xd2, 0xc3, 0x09, + 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x09, + 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x09, + 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x09, + 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x08, + 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x08, + 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x08, + 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x41, 0x1a, + 0x00, 0xd2, 0x01, 0x46, 0x52, 0x41, 0x10, 0x46, 0x70, 0x47, 0xff, 0xe7, + 0x01, 0xb5, 0x00, 0x20, 0x00, 0xf0, 0x06, 0xf8, 0x02, 0xbd, 0xc0, 0x46, + 0x00, 0x29, 0xf7, 0xd0, 0x76, 0xe7, 0x70, 0x47, 0x70, 0x47, 0xc0, 0x46, + 0x10, 0xb5, 0x04, 0x00, 0x04, 0x48, 0x13, 0x00, 0x00, 0x28, 0x04, 0xd0, + 0x0a, 0x00, 0x02, 0x20, 0x21, 0x00, 0x00, 0xe0, 0x00, 0xbf, 0x10, 0xbd, + 0x00, 0x00, 0x00, 0x00, 0x70, 0xb5, 0x00, 0x26, 0x0c, 0x4d, 0x0d, 0x4c, + 0x64, 0x1b, 0xa4, 0x10, 0xa6, 0x42, 0x09, 0xd1, 0x00, 0x26, 0x00, 0xf0, + 0x51, 0xf9, 0x0a, 0x4d, 0x0a, 0x4c, 0x64, 0x1b, 0xa4, 0x10, 0xa6, 0x42, + 0x05, 0xd1, 0x70, 0xbd, 0xb3, 0x00, 0xeb, 0x58, 0x98, 0x47, 0x01, 0x36, + 0xee, 0xe7, 0xb3, 0x00, 0xeb, 0x58, 0x98, 0x47, 0x01, 0x36, 0xf2, 0xe7, + 0x90, 0x00, 0x00, 0x20, 0x90, 0x00, 0x00, 0x20, 0x90, 0x00, 0x00, 0x20, + 0xd0, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x03, 0x4b, 0x01, 0x00, 0x18, 0x68, + 0x00, 0xf0, 0x16, 0xf8, 0x10, 0xbd, 0xc0, 0x46, 0x2c, 0x00, 0x00, 0x20, + 0x00, 0x23, 0x10, 0xb5, 0x9a, 0x42, 0x00, 0xd1, 0x10, 0xbd, 0xcc, 0x5c, + 0xc4, 0x54, 0x01, 0x33, 0xf8, 0xe7, 0x03, 0x00, 0x12, 0x18, 0x93, 0x42, + 0x00, 0xd1, 0x70, 0x47, 0x19, 0x70, 0x01, 0x33, 0xf9, 0xe7, 0x00, 0x00, + 0x70, 0xb5, 0x05, 0x00, 0x00, 0x29, 0x10, 0xd0, 0x0c, 0x1f, 0x23, 0x68, + 0x00, 0x2b, 0x00, 0xda, 0xe4, 0x18, 0x28, 0x00, 0x00, 0xf0, 0xd1, 0xf8, + 0x1d, 0x4a, 0x13, 0x68, 0x00, 0x2b, 0x05, 0xd1, 0x63, 0x60, 0x14, 0x60, + 0x28, 0x00, 0x00, 0xf0, 0xc9, 0xf8, 0x70, 0xbd, 0xa3, 0x42, 0x09, 0xd9, + 0x21, 0x68, 0x60, 0x18, 0x83, 0x42, 0xf3, 0xd1, 0x18, 0x68, 0x5b, 0x68, + 0x41, 0x18, 0x21, 0x60, 0xee, 0xe7, 0x13, 0x00, 0x5a, 0x68, 0x00, 0x2a, + 0x01, 0xd0, 0xa2, 0x42, 0xf9, 0xd9, 0x19, 0x68, 0x58, 0x18, 0xa0, 0x42, + 0x0b, 0xd1, 0x20, 0x68, 0x09, 0x18, 0x58, 0x18, 0x19, 0x60, 0x82, 0x42, + 0xe0, 0xd1, 0x10, 0x68, 0x52, 0x68, 0x41, 0x18, 0x19, 0x60, 0x5a, 0x60, + 0xda, 0xe7, 0xa0, 0x42, 0x02, 0xd9, 0x0c, 0x23, 0x2b, 0x60, 0xd5, 0xe7, + 0x21, 0x68, 0x60, 0x18, 0x82, 0x42, 0x03, 0xd1, 0x10, 0x68, 0x52, 0x68, + 0x41, 0x18, 0x21, 0x60, 0x62, 0x60, 0x5c, 0x60, 0xca, 0xe7, 0xc0, 0x46, + 0x9c, 0x21, 0x00, 0x20, 0x03, 0x23, 0x70, 0xb5, 0xcd, 0x1c, 0x9d, 0x43, + 0x08, 0x35, 0x06, 0x00, 0x0c, 0x2d, 0x1e, 0xd2, 0x0c, 0x25, 0xa9, 0x42, + 0x1d, 0xd8, 0x30, 0x00, 0x00, 0xf0, 0x85, 0xf8, 0x25, 0x4a, 0x14, 0x68, + 0x21, 0x00, 0x00, 0x29, 0x19, 0xd1, 0x24, 0x4c, 0x23, 0x68, 0x00, 0x2b, + 0x03, 0xd1, 0x30, 0x00, 0x00, 0xf0, 0x4e, 0xf8, 0x20, 0x60, 0x29, 0x00, + 0x30, 0x00, 0x00, 0xf0, 0x49, 0xf8, 0x43, 0x1c, 0x2b, 0xd1, 0x0c, 0x23, + 0x30, 0x00, 0x33, 0x60, 0x00, 0xf0, 0x6e, 0xf8, 0x03, 0xe0, 0x00, 0x2d, + 0xdf, 0xda, 0x0c, 0x23, 0x33, 0x60, 0x00, 0x20, 0x70, 0xbd, 0x0b, 0x68, + 0x5b, 0x1b, 0x19, 0xd4, 0x0b, 0x2b, 0x03, 0xd9, 0x0b, 0x60, 0xcc, 0x18, + 0x25, 0x60, 0x03, 0xe0, 0x4b, 0x68, 0x8c, 0x42, 0x0d, 0xd1, 0x13, 0x60, + 0x30, 0x00, 0x00, 0xf0, 0x57, 0xf8, 0x20, 0x00, 0x07, 0x22, 0x0b, 0x30, + 0x23, 0x1d, 0x90, 0x43, 0xc3, 0x1a, 0xe7, 0xd0, 0x5a, 0x42, 0xe2, 0x50, + 0xe4, 0xe7, 0x63, 0x60, 0x0c, 0x00, 0xef, 0xe7, 0x0c, 0x00, 0x49, 0x68, + 0xc3, 0xe7, 0x03, 0x23, 0xc4, 0x1c, 0x9c, 0x43, 0xa0, 0x42, 0xe1, 0xd0, + 0x21, 0x1a, 0x30, 0x00, 0x00, 0xf0, 0x12, 0xf8, 0x43, 0x1c, 0xdb, 0xd1, + 0xc7, 0xe7, 0xc0, 0x46, 0x9c, 0x21, 0x00, 0x20, 0xa0, 0x21, 0x00, 0x20, + 0x10, 0xb5, 0x03, 0x4b, 0x0a, 0x00, 0x01, 0x00, 0x18, 0x68, 0x00, 0xf0, + 0x30, 0xf8, 0x10, 0xbd, 0x2c, 0x00, 0x00, 0x20, 0x00, 0x23, 0x70, 0xb5, + 0x06, 0x4c, 0x05, 0x00, 0x08, 0x00, 0x23, 0x60, 0x00, 0xf0, 0x54, 0xf8, + 0x43, 0x1c, 0x03, 0xd1, 0x23, 0x68, 0x00, 0x2b, 0x00, 0xd0, 0x2b, 0x60, + 0x70, 0xbd, 0xc0, 0x46, 0xa8, 0x21, 0x00, 0x20, 0x02, 0x78, 0x0b, 0x78, + 0x00, 0x2a, 0x03, 0xd0, 0x01, 0x30, 0x01, 0x31, 0x9a, 0x42, 0xf7, 0xd0, + 0xd0, 0x1a, 0x70, 0x47, 0x03, 0x00, 0x0a, 0x78, 0x01, 0x31, 0x1a, 0x70, + 0x01, 0x33, 0x00, 0x2a, 0xf9, 0xd1, 0x70, 0x47, 0x00, 0x23, 0xc2, 0x5c, + 0x01, 0x33, 0x00, 0x2a, 0xfb, 0xd1, 0x58, 0x1e, 0x70, 0x47, 0x70, 0x47, + 0x70, 0x47, 0xf8, 0xb5, 0x07, 0x00, 0x0d, 0x00, 0x16, 0x00, 0x00, 0x29, + 0x05, 0xd1, 0x11, 0x00, 0xff, 0xf7, 0x62, 0xff, 0x04, 0x00, 0x20, 0x00, + 0xf8, 0xbd, 0x00, 0x2a, 0x03, 0xd1, 0xff, 0xf7, 0x11, 0xff, 0x34, 0x00, + 0xf7, 0xe7, 0x00, 0xf0, 0x12, 0xf8, 0x2c, 0x00, 0xb0, 0x42, 0xf2, 0xd2, + 0x31, 0x00, 0x38, 0x00, 0xff, 0xf7, 0x50, 0xff, 0x04, 0x1e, 0xec, 0xd0, + 0x29, 0x00, 0x32, 0x00, 0xff, 0xf7, 0xee, 0xfe, 0x29, 0x00, 0x38, 0x00, + 0xff, 0xf7, 0xfc, 0xfe, 0xe3, 0xe7, 0x0b, 0x1f, 0x1b, 0x68, 0x18, 0x1f, + 0x00, 0x2b, 0x01, 0xda, 0x0b, 0x58, 0xc0, 0x18, 0x70, 0x47, 0x00, 0x00, + 0x04, 0x4a, 0x13, 0x68, 0x00, 0x2b, 0x00, 0xd1, 0x03, 0x4b, 0x18, 0x18, + 0x10, 0x60, 0x18, 0x00, 0x70, 0x47, 0xc0, 0x46, 0xa4, 0x21, 0x00, 0x20, + 0xac, 0x21, 0x00, 0x20, 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, + 0x9e, 0x46, 0x70, 0x47, 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, + 0x9e, 0x46, 0x70, 0x47, 0x00, 0x00, 0x00, 0x00, 0x96, 0x30, 0x07, 0x77, + 0x2c, 0x61, 0x0e, 0xee, 0xba, 0x51, 0x09, 0x99, 0x19, 0xc4, 0x6d, 0x07, + 0x8f, 0xf4, 0x6a, 0x70, 0x35, 0xa5, 0x63, 0xe9, 0xa3, 0x95, 0x64, 0x9e, + 0x32, 0x88, 0xdb, 0x0e, 0xa4, 0xb8, 0xdc, 0x79, 0x1e, 0xe9, 0xd5, 0xe0, + 0x88, 0xd9, 0xd2, 0x97, 0x2b, 0x4c, 0xb6, 0x09, 0xbd, 0x7c, 0xb1, 0x7e, + 0x07, 0x2d, 0xb8, 0xe7, 0x91, 0x1d, 0xbf, 0x90, 0x64, 0x10, 0xb7, 0x1d, + 0xf2, 0x20, 0xb0, 0x6a, 0x48, 0x71, 0xb9, 0xf3, 0xde, 0x41, 0xbe, 0x84, + 0x7d, 0xd4, 0xda, 0x1a, 0xeb, 0xe4, 0xdd, 0x6d, 0x51, 0xb5, 0xd4, 0xf4, + 0xc7, 0x85, 0xd3, 0x83, 0x56, 0x98, 0x6c, 0x13, 0xc0, 0xa8, 0x6b, 0x64, + 0x7a, 0xf9, 0x62, 0xfd, 0xec, 0xc9, 0x65, 0x8a, 0x4f, 0x5c, 0x01, 0x14, + 0xd9, 0x6c, 0x06, 0x63, 0x63, 0x3d, 0x0f, 0xfa, 0xf5, 0x0d, 0x08, 0x8d, + 0xc8, 0x20, 0x6e, 0x3b, 0x5e, 0x10, 0x69, 0x4c, 0xe4, 0x41, 0x60, 0xd5, + 0x72, 0x71, 0x67, 0xa2, 0xd1, 0xe4, 0x03, 0x3c, 0x47, 0xd4, 0x04, 0x4b, + 0xfd, 0x85, 0x0d, 0xd2, 0x6b, 0xb5, 0x0a, 0xa5, 0xfa, 0xa8, 0xb5, 0x35, + 0x6c, 0x98, 0xb2, 0x42, 0xd6, 0xc9, 0xbb, 0xdb, 0x40, 0xf9, 0xbc, 0xac, + 0xe3, 0x6c, 0xd8, 0x32, 0x75, 0x5c, 0xdf, 0x45, 0xcf, 0x0d, 0xd6, 0xdc, + 0x59, 0x3d, 0xd1, 0xab, 0xac, 0x30, 0xd9, 0x26, 0x3a, 0x00, 0xde, 0x51, + 0x80, 0x51, 0xd7, 0xc8, 0x16, 0x61, 0xd0, 0xbf, 0xb5, 0xf4, 0xb4, 0x21, + 0x23, 0xc4, 0xb3, 0x56, 0x99, 0x95, 0xba, 0xcf, 0x0f, 0xa5, 0xbd, 0xb8, + 0x9e, 0xb8, 0x02, 0x28, 0x08, 0x88, 0x05, 0x5f, 0xb2, 0xd9, 0x0c, 0xc6, + 0x24, 0xe9, 0x0b, 0xb1, 0x87, 0x7c, 0x6f, 0x2f, 0x11, 0x4c, 0x68, 0x58, + 0xab, 0x1d, 0x61, 0xc1, 0x3d, 0x2d, 0x66, 0xb6, 0x90, 0x41, 0xdc, 0x76, + 0x06, 0x71, 0xdb, 0x01, 0xbc, 0x20, 0xd2, 0x98, 0x2a, 0x10, 0xd5, 0xef, + 0x89, 0x85, 0xb1, 0x71, 0x1f, 0xb5, 0xb6, 0x06, 0xa5, 0xe4, 0xbf, 0x9f, + 0x33, 0xd4, 0xb8, 0xe8, 0xa2, 0xc9, 0x07, 0x78, 0x34, 0xf9, 0x00, 0x0f, + 0x8e, 0xa8, 0x09, 0x96, 0x18, 0x98, 0x0e, 0xe1, 0xbb, 0x0d, 0x6a, 0x7f, + 0x2d, 0x3d, 0x6d, 0x08, 0x97, 0x6c, 0x64, 0x91, 0x01, 0x5c, 0x63, 0xe6, + 0xf4, 0x51, 0x6b, 0x6b, 0x62, 0x61, 0x6c, 0x1c, 0xd8, 0x30, 0x65, 0x85, + 0x4e, 0x00, 0x62, 0xf2, 0xed, 0x95, 0x06, 0x6c, 0x7b, 0xa5, 0x01, 0x1b, + 0xc1, 0xf4, 0x08, 0x82, 0x57, 0xc4, 0x0f, 0xf5, 0xc6, 0xd9, 0xb0, 0x65, + 0x50, 0xe9, 0xb7, 0x12, 0xea, 0xb8, 0xbe, 0x8b, 0x7c, 0x88, 0xb9, 0xfc, + 0xdf, 0x1d, 0xdd, 0x62, 0x49, 0x2d, 0xda, 0x15, 0xf3, 0x7c, 0xd3, 0x8c, + 0x65, 0x4c, 0xd4, 0xfb, 0x58, 0x61, 0xb2, 0x4d, 0xce, 0x51, 0xb5, 0x3a, + 0x74, 0x00, 0xbc, 0xa3, 0xe2, 0x30, 0xbb, 0xd4, 0x41, 0xa5, 0xdf, 0x4a, + 0xd7, 0x95, 0xd8, 0x3d, 0x6d, 0xc4, 0xd1, 0xa4, 0xfb, 0xf4, 0xd6, 0xd3, + 0x6a, 0xe9, 0x69, 0x43, 0xfc, 0xd9, 0x6e, 0x34, 0x46, 0x88, 0x67, 0xad, + 0xd0, 0xb8, 0x60, 0xda, 0x73, 0x2d, 0x04, 0x44, 0xe5, 0x1d, 0x03, 0x33, + 0x5f, 0x4c, 0x0a, 0xaa, 0xc9, 0x7c, 0x0d, 0xdd, 0x3c, 0x71, 0x05, 0x50, + 0xaa, 0x41, 0x02, 0x27, 0x10, 0x10, 0x0b, 0xbe, 0x86, 0x20, 0x0c, 0xc9, + 0x25, 0xb5, 0x68, 0x57, 0xb3, 0x85, 0x6f, 0x20, 0x09, 0xd4, 0x66, 0xb9, + 0x9f, 0xe4, 0x61, 0xce, 0x0e, 0xf9, 0xde, 0x5e, 0x98, 0xc9, 0xd9, 0x29, + 0x22, 0x98, 0xd0, 0xb0, 0xb4, 0xa8, 0xd7, 0xc7, 0x17, 0x3d, 0xb3, 0x59, + 0x81, 0x0d, 0xb4, 0x2e, 0x3b, 0x5c, 0xbd, 0xb7, 0xad, 0x6c, 0xba, 0xc0, + 0x20, 0x83, 0xb8, 0xed, 0xb6, 0xb3, 0xbf, 0x9a, 0x0c, 0xe2, 0xb6, 0x03, + 0x9a, 0xd2, 0xb1, 0x74, 0x39, 0x47, 0xd5, 0xea, 0xaf, 0x77, 0xd2, 0x9d, + 0x15, 0x26, 0xdb, 0x04, 0x83, 0x16, 0xdc, 0x73, 0x12, 0x0b, 0x63, 0xe3, + 0x84, 0x3b, 0x64, 0x94, 0x3e, 0x6a, 0x6d, 0x0d, 0xa8, 0x5a, 0x6a, 0x7a, + 0x0b, 0xcf, 0x0e, 0xe4, 0x9d, 0xff, 0x09, 0x93, 0x27, 0xae, 0x00, 0x0a, + 0xb1, 0x9e, 0x07, 0x7d, 0x44, 0x93, 0x0f, 0xf0, 0xd2, 0xa3, 0x08, 0x87, + 0x68, 0xf2, 0x01, 0x1e, 0xfe, 0xc2, 0x06, 0x69, 0x5d, 0x57, 0x62, 0xf7, + 0xcb, 0x67, 0x65, 0x80, 0x71, 0x36, 0x6c, 0x19, 0xe7, 0x06, 0x6b, 0x6e, + 0x76, 0x1b, 0xd4, 0xfe, 0xe0, 0x2b, 0xd3, 0x89, 0x5a, 0x7a, 0xda, 0x10, + 0xcc, 0x4a, 0xdd, 0x67, 0x6f, 0xdf, 0xb9, 0xf9, 0xf9, 0xef, 0xbe, 0x8e, + 0x43, 0xbe, 0xb7, 0x17, 0xd5, 0x8e, 0xb0, 0x60, 0xe8, 0xa3, 0xd6, 0xd6, + 0x7e, 0x93, 0xd1, 0xa1, 0xc4, 0xc2, 0xd8, 0x38, 0x52, 0xf2, 0xdf, 0x4f, + 0xf1, 0x67, 0xbb, 0xd1, 0x67, 0x57, 0xbc, 0xa6, 0xdd, 0x06, 0xb5, 0x3f, + 0x4b, 0x36, 0xb2, 0x48, 0xda, 0x2b, 0x0d, 0xd8, 0x4c, 0x1b, 0x0a, 0xaf, + 0xf6, 0x4a, 0x03, 0x36, 0x60, 0x7a, 0x04, 0x41, 0xc3, 0xef, 0x60, 0xdf, + 0x55, 0xdf, 0x67, 0xa8, 0xef, 0x8e, 0x6e, 0x31, 0x79, 0xbe, 0x69, 0x46, + 0x8c, 0xb3, 0x61, 0xcb, 0x1a, 0x83, 0x66, 0xbc, 0xa0, 0xd2, 0x6f, 0x25, + 0x36, 0xe2, 0x68, 0x52, 0x95, 0x77, 0x0c, 0xcc, 0x03, 0x47, 0x0b, 0xbb, + 0xb9, 0x16, 0x02, 0x22, 0x2f, 0x26, 0x05, 0x55, 0xbe, 0x3b, 0xba, 0xc5, + 0x28, 0x0b, 0xbd, 0xb2, 0x92, 0x5a, 0xb4, 0x2b, 0x04, 0x6a, 0xb3, 0x5c, + 0xa7, 0xff, 0xd7, 0xc2, 0x31, 0xcf, 0xd0, 0xb5, 0x8b, 0x9e, 0xd9, 0x2c, + 0x1d, 0xae, 0xde, 0x5b, 0xb0, 0xc2, 0x64, 0x9b, 0x26, 0xf2, 0x63, 0xec, + 0x9c, 0xa3, 0x6a, 0x75, 0x0a, 0x93, 0x6d, 0x02, 0xa9, 0x06, 0x09, 0x9c, + 0x3f, 0x36, 0x0e, 0xeb, 0x85, 0x67, 0x07, 0x72, 0x13, 0x57, 0x00, 0x05, + 0x82, 0x4a, 0xbf, 0x95, 0x14, 0x7a, 0xb8, 0xe2, 0xae, 0x2b, 0xb1, 0x7b, + 0x38, 0x1b, 0xb6, 0x0c, 0x9b, 0x8e, 0xd2, 0x92, 0x0d, 0xbe, 0xd5, 0xe5, + 0xb7, 0xef, 0xdc, 0x7c, 0x21, 0xdf, 0xdb, 0x0b, 0xd4, 0xd2, 0xd3, 0x86, + 0x42, 0xe2, 0xd4, 0xf1, 0xf8, 0xb3, 0xdd, 0x68, 0x6e, 0x83, 0xda, 0x1f, + 0xcd, 0x16, 0xbe, 0x81, 0x5b, 0x26, 0xb9, 0xf6, 0xe1, 0x77, 0xb0, 0x6f, + 0x77, 0x47, 0xb7, 0x18, 0xe6, 0x5a, 0x08, 0x88, 0x70, 0x6a, 0x0f, 0xff, + 0xca, 0x3b, 0x06, 0x66, 0x5c, 0x0b, 0x01, 0x11, 0xff, 0x9e, 0x65, 0x8f, + 0x69, 0xae, 0x62, 0xf8, 0xd3, 0xff, 0x6b, 0x61, 0x45, 0xcf, 0x6c, 0x16, + 0x78, 0xe2, 0x0a, 0xa0, 0xee, 0xd2, 0x0d, 0xd7, 0x54, 0x83, 0x04, 0x4e, + 0xc2, 0xb3, 0x03, 0x39, 0x61, 0x26, 0x67, 0xa7, 0xf7, 0x16, 0x60, 0xd0, + 0x4d, 0x47, 0x69, 0x49, 0xdb, 0x77, 0x6e, 0x3e, 0x4a, 0x6a, 0xd1, 0xae, + 0xdc, 0x5a, 0xd6, 0xd9, 0x66, 0x0b, 0xdf, 0x40, 0xf0, 0x3b, 0xd8, 0x37, + 0x53, 0xae, 0xbc, 0xa9, 0xc5, 0x9e, 0xbb, 0xde, 0x7f, 0xcf, 0xb2, 0x47, + 0xe9, 0xff, 0xb5, 0x30, 0x1c, 0xf2, 0xbd, 0xbd, 0x8a, 0xc2, 0xba, 0xca, + 0x30, 0x93, 0xb3, 0x53, 0xa6, 0xa3, 0xb4, 0x24, 0x05, 0x36, 0xd0, 0xba, + 0x93, 0x06, 0xd7, 0xcd, 0x29, 0x57, 0xde, 0x54, 0xbf, 0x67, 0xd9, 0x23, + 0x2e, 0x7a, 0x66, 0xb3, 0xb8, 0x4a, 0x61, 0xc4, 0x02, 0x1b, 0x68, 0x5d, + 0x94, 0x2b, 0x6f, 0x2a, 0x37, 0xbe, 0x0b, 0xb4, 0xa1, 0x8e, 0x0c, 0xc3, + 0x1b, 0xdf, 0x05, 0x5a, 0x8d, 0xef, 0x02, 0x2d, 0x31, 0x2e, 0x34, 0x2e, + 0x31, 0x00, 0x2f, 0x66, 0x73, 0x2f, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, + 0x2e, 0x42, 0x49, 0x4e, 0x2e, 0x4c, 0x5a, 0x53, 0x53, 0x00, 0x2f, 0x66, + 0x73, 0x2f, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x2e, 0x42, 0x49, 0x4e, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x10, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, + 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, + 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x04, + 0x00, 0x04, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x01, + 0x00, 0x01, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x13, 0x00, 0x01, 0x01, + 0x01, 0x01, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x05, + 0x00, 0x05, 0x0a, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x05, + 0x01, 0x05, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x02, 0x00, + 0x02, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, + 0x03, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x02, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x03, + 0x01, 0x03, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x10, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x11, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0a, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0b, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x05, 0x00, 0x01, 0x00, + 0x01, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x06, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x07, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x0f, 0x00, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x02, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x03, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xf5, 0x34, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x37, 0x3a, 0x00, 0x00, 0x6d, 0x3c, 0x00, 0x00, 0x33, 0x3a, 0x00, 0x00, + 0x51, 0x3c, 0x00, 0x00, 0x31, 0x3c, 0x00, 0x00, 0xa9, 0x3c, 0x00, 0x00, + 0x8d, 0x3c, 0x00, 0x00, 0x5f, 0x3c, 0x00, 0x00, 0x4d, 0x3a, 0x00, 0x00, + 0xb3, 0x39, 0x00, 0x00, 0x79, 0x3b, 0x00, 0x00, 0xdd, 0x39, 0x00, 0x00, + 0x31, 0x3a, 0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, + 0x21, 0x3c, 0x00, 0x00, 0x69, 0x3b, 0x00, 0x00, 0xcf, 0x3c, 0x00, 0x00, + 0xcd, 0x3c, 0x00, 0x00, 0x21, 0x3a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x4d, 0x45, 0x00, 0x00, 0x55, 0x35, 0x00, 0x00, + 0x73, 0x44, 0x00, 0x00, 0x2f, 0x44, 0x00, 0x00, 0x49, 0x44, 0x00, 0x00, + 0x01, 0x46, 0x00, 0x00, 0x89, 0x41, 0x00, 0x00, 0x79, 0x41, 0x00, 0x00, + 0x0d, 0x42, 0x00, 0x00, 0xa3, 0x41, 0x00, 0x00, 0x75, 0x41, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb6, 0x4f, 0x00, 0x00, + 0xa2, 0x4f, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x07, 0x05, 0x0a, 0x00, + 0x40, 0x42, 0x0f, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x00, 0xc2, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0xff, 0xff, 0xff, 0xff, + 0x30, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x38, 0x59, 0x00, 0x00, + 0x58, 0x59, 0x00, 0x00, 0x18, 0x59, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xdd, 0x20, 0x00, 0x00, 0x25, 0x24, 0x00, 0x00, + 0x45, 0x26, 0x00, 0x00, 0x6d, 0x26, 0x00, 0x00, 0x91, 0x26, 0x00, 0x00, + 0xa9, 0x26, 0x00, 0x00, 0xc1, 0x26, 0x00, 0x00, 0x21, 0x27, 0x00, 0x00, + 0x39, 0x27, 0x00, 0x00, 0x95, 0x27, 0x00, 0x00, 0xa9, 0x2b, 0x00, 0x00, + 0xc1, 0x2b, 0x00, 0x00, 0xfd, 0x2d, 0x00, 0x00, 0x89, 0x2e, 0x00, 0x00, + 0x25, 0x3d, 0x00, 0x00, 0x65, 0x41, 0x00, 0x00, 0xb5, 0x20, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 diff --git a/libraries/SNU/src/boot/nano33iot.h b/libraries/SNU/src/boot/nano33iot.h new file mode 100644 index 0000000..a85822e --- /dev/null +++ b/libraries/SNU/src/boot/nano33iot.h @@ -0,0 +1,1260 @@ + 0x00, 0x80, 0x00, 0x20, 0x6d, 0x2f, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, + 0x55, 0x2f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, + 0xc1, 0x2f, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, + 0x55, 0x2f, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, + 0x55, 0x2f, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, 0x59, 0x2f, 0x00, 0x00, + 0x55, 0x2f, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, + 0x89, 0x2e, 0x00, 0x00, 0x79, 0x2e, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, + 0x69, 0x2e, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, + 0x55, 0x2f, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, + 0x55, 0x2f, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, + 0x55, 0x2f, 0x00, 0x00, 0x55, 0x2f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0xd4, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0x30, 0x5a, 0x00, 0x00, 0x04, 0x4b, 0x10, 0xb5, 0x00, 0x2b, 0x03, 0xd0, + 0x03, 0x49, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x10, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x00, 0xd8, 0x00, 0x00, 0x20, 0x30, 0x5a, 0x00, 0x00, + 0x1f, 0xb5, 0x14, 0x00, 0x04, 0x22, 0x00, 0x23, 0x01, 0x92, 0x03, 0xaa, + 0x00, 0x92, 0x0a, 0x00, 0x01, 0x00, 0x63, 0x20, 0x03, 0x93, 0x00, 0xf0, + 0xf1, 0xfc, 0x03, 0x98, 0x20, 0x60, 0xc0, 0x43, 0xc0, 0x0f, 0x40, 0xb2, + 0x04, 0xb0, 0x10, 0xbd, 0x13, 0xb5, 0x04, 0x00, 0x02, 0xf0, 0x16, 0xfd, + 0x01, 0xaa, 0xc1, 0xb2, 0x20, 0x00, 0xff, 0xf7, 0xe3, 0xff, 0xc3, 0x17, + 0x18, 0x1a, 0xc0, 0x0f, 0x16, 0xbd, 0xf0, 0xb5, 0x06, 0x68, 0x43, 0x68, + 0x85, 0xb0, 0x14, 0x00, 0xb2, 0x18, 0x05, 0x00, 0x03, 0x91, 0x9a, 0x42, + 0x03, 0xd9, 0x00, 0x24, 0x9e, 0x42, 0x10, 0xd2, 0x9c, 0x1b, 0xaf, 0x68, + 0x38, 0x00, 0x02, 0xf0, 0xfb, 0xfc, 0x03, 0x9b, 0xc2, 0xb2, 0x00, 0x93, + 0x01, 0x94, 0x33, 0x00, 0x39, 0x00, 0x61, 0x20, 0x00, 0xf0, 0xc2, 0xfc, + 0x2b, 0x68, 0x1b, 0x19, 0x2b, 0x60, 0x20, 0x00, 0x05, 0xb0, 0xf0, 0xbd, + 0x70, 0xb5, 0x85, 0x68, 0x04, 0x00, 0x28, 0x00, 0x02, 0xf0, 0xe6, 0xfc, + 0x22, 0x1d, 0xc1, 0xb2, 0x28, 0x00, 0xff, 0xf7, 0xb3, 0xff, 0x60, 0x68, + 0x70, 0xbd, 0x37, 0xb5, 0x00, 0x24, 0x85, 0x68, 0x04, 0x60, 0x28, 0x00, + 0x02, 0xf0, 0xd8, 0xfc, 0x29, 0x00, 0xc2, 0xb2, 0x01, 0x94, 0x00, 0x94, + 0x23, 0x00, 0x62, 0x20, 0x00, 0xf0, 0xa0, 0xfc, 0x37, 0xbd, 0x00, 0x00, + 0x30, 0xb5, 0xff, 0x25, 0x06, 0x4c, 0x8a, 0x18, 0x91, 0x42, 0x08, 0xd0, + 0x0b, 0x78, 0x01, 0x31, 0x43, 0x40, 0x2b, 0x40, 0x9b, 0x00, 0x1b, 0x59, + 0x00, 0x0a, 0x58, 0x40, 0xf4, 0xe7, 0x30, 0xbd, 0xfc, 0x4b, 0x00, 0x00, + 0xf0, 0xb5, 0x0c, 0x24, 0xaf, 0xb0, 0x00, 0xaf, 0x01, 0xf0, 0x1a, 0xf8, + 0x02, 0xf0, 0x9e, 0xfb, 0x01, 0x20, 0x00, 0xf0, 0x23, 0xff, 0x01, 0x21, + 0x1a, 0x20, 0x01, 0xf0, 0xbb, 0xf8, 0x01, 0x21, 0x1a, 0x20, 0x01, 0xf0, + 0x03, 0xf9, 0x01, 0x21, 0x1b, 0x20, 0x01, 0xf0, 0xb3, 0xf8, 0x01, 0x21, + 0x1b, 0x20, 0x01, 0xf0, 0xfb, 0xf8, 0x78, 0x49, 0x38, 0x19, 0x02, 0xf0, + 0x8f, 0xfa, 0x77, 0x48, 0x00, 0xf0, 0x20, 0xfa, 0xff, 0x28, 0x00, 0xd1, + 0x96, 0xe0, 0x00, 0xf0, 0x17, 0xfa, 0x08, 0x26, 0x30, 0x25, 0x01, 0x00, + 0x38, 0x19, 0x02, 0xf0, 0xa0, 0xfa, 0xbb, 0x19, 0x70, 0x49, 0x58, 0x19, + 0x02, 0xf0, 0x7c, 0xfa, 0xbb, 0x19, 0x59, 0x19, 0x38, 0x19, 0x02, 0xf0, + 0xbe, 0xfa, 0xbb, 0x19, 0x04, 0x00, 0x58, 0x19, 0x02, 0xf0, 0x2a, 0xfa, + 0x00, 0x2c, 0x7d, 0xd1, 0x69, 0x4d, 0x28, 0x68, 0xff, 0xf7, 0x60, 0xff, + 0x00, 0x28, 0x00, 0xd1, 0x88, 0xe0, 0x29, 0x68, 0x08, 0x25, 0xb6, 0x19, + 0x7b, 0x19, 0x98, 0x19, 0x00, 0xf0, 0x47, 0xfa, 0x1c, 0x23, 0x79, 0x19, + 0x78, 0x19, 0xc9, 0x18, 0x14, 0x22, 0x80, 0x19, 0xff, 0xf7, 0x5b, 0xff, + 0x08, 0x23, 0xfb, 0x18, 0x98, 0x19, 0x7d, 0x6a, 0xff, 0xf7, 0x76, 0xff, + 0x08, 0x38, 0x85, 0x42, 0x06, 0xd0, 0x00, 0x23, 0xbb, 0x61, 0x10, 0x33, + 0x08, 0x22, 0xba, 0x18, 0xd0, 0x18, 0x55, 0xe0, 0x08, 0x23, 0x01, 0x25, + 0xbb, 0x61, 0x6d, 0x42, 0x7a, 0x6a, 0x13, 0x00, 0x80, 0x3b, 0xa3, 0x42, + 0x13, 0xd9, 0x08, 0x20, 0x30, 0x26, 0x3b, 0x18, 0x99, 0x19, 0x10, 0x23, + 0x38, 0x18, 0x80, 0x22, 0xc0, 0x18, 0xff, 0xf7, 0x38, 0xff, 0x08, 0x20, + 0x3b, 0x18, 0x80, 0x22, 0x28, 0x00, 0x99, 0x19, 0xff, 0xf7, 0x70, 0xff, + 0x80, 0x34, 0x05, 0x00, 0xe6, 0xe7, 0x08, 0x20, 0x30, 0x26, 0x3b, 0x18, + 0x99, 0x19, 0x10, 0x23, 0x38, 0x18, 0x12, 0x1b, 0xc0, 0x18, 0xff, 0xf7, + 0x24, 0xff, 0x08, 0x20, 0x7b, 0x6a, 0x1a, 0x1b, 0x3b, 0x18, 0x99, 0x19, + 0x28, 0x00, 0xff, 0xf7, 0x5b, 0xff, 0xc0, 0x43, 0xbb, 0x6a, 0x83, 0x42, + 0xc5, 0xd1, 0x3e, 0x4b, 0xfa, 0x6a, 0x9a, 0x42, 0xc1, 0xd1, 0xe8, 0x22, + 0xc0, 0x21, 0x14, 0x23, 0x08, 0x25, 0x10, 0x24, 0x92, 0x02, 0xc9, 0x01, + 0x39, 0x48, 0xbb, 0x61, 0x00, 0xf0, 0xc8, 0xfc, 0x7b, 0x19, 0x18, 0x19, + 0xff, 0xf7, 0x26, 0xff, 0xc0, 0x21, 0x02, 0x00, 0x7b, 0x19, 0x18, 0x19, + 0x14, 0x3a, 0xc9, 0x01, 0x00, 0xf0, 0x84, 0xf8, 0x00, 0xf0, 0x3a, 0xf9, + 0x00, 0xf0, 0x92, 0xf8, 0x00, 0x23, 0xbb, 0x61, 0x7b, 0x19, 0x18, 0x19, + 0xff, 0xf7, 0x21, 0xff, 0xc0, 0x23, 0xdb, 0x01, 0x1a, 0x68, 0x82, 0xf3, + 0x08, 0x88, 0x2b, 0x4a, 0x93, 0x60, 0x2b, 0x4b, 0x1b, 0x68, 0x18, 0x47, + 0x0c, 0x23, 0xf8, 0x18, 0x02, 0xf0, 0x9c, 0xf9, 0x00, 0x20, 0xbd, 0x46, + 0x2f, 0xb0, 0xf0, 0xbd, 0x26, 0x4c, 0x20, 0x68, 0xff, 0xf7, 0xd0, 0xfe, + 0x00, 0x28, 0xe7, 0xd0, 0x08, 0x25, 0x21, 0x68, 0x1c, 0x24, 0x7b, 0x19, + 0x18, 0x19, 0x00, 0xf0, 0xb8, 0xf9, 0x7b, 0x19, 0x18, 0x19, 0xff, 0xf7, + 0xf1, 0xfe, 0x80, 0x23, 0xdb, 0x01, 0x98, 0x42, 0xd8, 0xd9, 0xc0, 0x21, + 0x7b, 0x62, 0x1c, 0x4b, 0xc9, 0x01, 0xc4, 0x18, 0x22, 0x00, 0x16, 0x48, + 0xc0, 0x25, 0x00, 0xf0, 0x81, 0xfc, 0x80, 0x26, 0xed, 0x01, 0x08, 0x21, + 0x30, 0x23, 0x78, 0x18, 0xc1, 0x18, 0x1c, 0x20, 0x28, 0x3b, 0xfb, 0x18, + 0x32, 0x00, 0x18, 0x18, 0xff, 0xf7, 0xb5, 0xfe, 0x08, 0x21, 0x30, 0x22, + 0x79, 0x18, 0x33, 0x00, 0x8a, 0x18, 0x0b, 0x48, 0x29, 0x00, 0x00, 0xf0, + 0x1b, 0xfc, 0x0e, 0x4b, 0xeb, 0x18, 0x80, 0x35, 0x9c, 0x42, 0xe6, 0xd8, + 0x00, 0x23, 0x7b, 0x62, 0x1c, 0x33, 0x53, 0xe7, 0x01, 0x50, 0x00, 0x00, + 0xc0, 0x11, 0x00, 0x20, 0xfc, 0x4f, 0x00, 0x00, 0x08, 0x00, 0x00, 0x20, + 0x57, 0x80, 0x41, 0x23, 0xf8, 0x00, 0x00, 0x20, 0x00, 0xed, 0x00, 0xe0, + 0x04, 0x60, 0x00, 0x00, 0x04, 0x00, 0x00, 0x20, 0x00, 0xc0, 0xff, 0xff, + 0x80, 0xa0, 0xff, 0xff, 0x13, 0xb5, 0x00, 0x24, 0x06, 0x48, 0x23, 0x00, + 0x22, 0x00, 0x21, 0x00, 0x00, 0x94, 0x01, 0xf0, 0xb1, 0xf8, 0x22, 0x00, + 0x21, 0x00, 0x03, 0x48, 0x00, 0xf0, 0xd6, 0xfb, 0x13, 0xbd, 0xc0, 0x46, + 0xf0, 0x00, 0x00, 0x20, 0xf8, 0x00, 0x00, 0x20, 0x04, 0x4b, 0x19, 0x60, + 0x04, 0x4b, 0x19, 0x60, 0x04, 0x4b, 0x18, 0x60, 0x04, 0x4b, 0x1a, 0x60, + 0x70, 0x47, 0xc0, 0x46, 0x20, 0x01, 0x00, 0x20, 0x10, 0x01, 0x00, 0x20, + 0x1c, 0x01, 0x00, 0x20, 0x24, 0x01, 0x00, 0x20, 0x0c, 0x49, 0x70, 0xb5, + 0x0c, 0x4c, 0x0a, 0x68, 0x23, 0x68, 0x0c, 0x48, 0x9a, 0x18, 0x0a, 0x60, + 0x0b, 0x49, 0x09, 0x68, 0x09, 0x18, 0x8a, 0x42, 0x09, 0xd9, 0x0a, 0x4d, + 0x0a, 0x4a, 0x29, 0x68, 0x0a, 0x48, 0x00, 0xf0, 0xc3, 0xfb, 0x2b, 0x68, + 0x22, 0x68, 0x9b, 0x18, 0x2b, 0x60, 0x00, 0x23, 0x23, 0x60, 0x70, 0xbd, + 0x28, 0x01, 0x00, 0x20, 0x2c, 0x01, 0x00, 0x20, 0x00, 0xe0, 0xff, 0xff, + 0x20, 0x01, 0x00, 0x20, 0x10, 0x01, 0x00, 0x20, 0x30, 0x01, 0x00, 0x20, + 0xf8, 0x00, 0x00, 0x20, 0x05, 0x4a, 0x06, 0x49, 0x13, 0x68, 0x10, 0xb5, + 0xc8, 0x54, 0x01, 0x33, 0x13, 0x60, 0x40, 0x2b, 0x01, 0xd1, 0xff, 0xf7, + 0xcd, 0xff, 0x10, 0xbd, 0x2c, 0x01, 0x00, 0x20, 0x30, 0x01, 0x00, 0x20, + 0xf0, 0xb5, 0x1e, 0x4b, 0x1e, 0x4f, 0x1b, 0x68, 0x3a, 0x68, 0x85, 0xb0, + 0x9a, 0x42, 0x32, 0xd0, 0x1c, 0x4d, 0x2e, 0x68, 0x40, 0x2e, 0x24, 0xd1, + 0x1b, 0x4b, 0x1c, 0x68, 0x23, 0x68, 0x02, 0x93, 0x02, 0x99, 0x63, 0x68, + 0x40, 0x31, 0x99, 0x42, 0x04, 0xd9, 0x02, 0x9a, 0x00, 0x26, 0x9a, 0x42, + 0x11, 0xd2, 0x9e, 0x1a, 0xa3, 0x68, 0x18, 0x00, 0x03, 0x93, 0x02, 0xf0, + 0x1d, 0xfb, 0x13, 0x4b, 0xc2, 0xb2, 0x00, 0x93, 0x01, 0x96, 0x02, 0x9b, + 0x03, 0x99, 0x61, 0x20, 0x00, 0xf0, 0xe4, 0xfa, 0x23, 0x68, 0x9b, 0x19, + 0x23, 0x60, 0x0e, 0x4a, 0x13, 0x68, 0x9b, 0x19, 0x13, 0x60, 0x00, 0x23, + 0x2b, 0x60, 0x2b, 0x68, 0x09, 0x4a, 0xd0, 0x5c, 0x01, 0x33, 0x2b, 0x60, + 0x3b, 0x68, 0x01, 0x33, 0x3b, 0x60, 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x20, + 0x40, 0x42, 0xfa, 0xe7, 0x24, 0x01, 0x00, 0x20, 0x70, 0x01, 0x00, 0x20, + 0x0c, 0x00, 0x00, 0x20, 0x1c, 0x01, 0x00, 0x20, 0x78, 0x01, 0x00, 0x20, + 0x74, 0x01, 0x00, 0x20, 0xf7, 0xb5, 0x00, 0x24, 0x26, 0x00, 0x01, 0x90, + 0x01, 0x9b, 0x9e, 0x42, 0x16, 0xda, 0x0c, 0x4d, 0x0c, 0x4f, 0x2b, 0x68, + 0x00, 0x2b, 0x06, 0xd1, 0xff, 0xf7, 0xa8, 0xff, 0x38, 0x60, 0x43, 0x1c, + 0x0d, 0xd0, 0x80, 0x23, 0x2b, 0x60, 0x2a, 0x68, 0x3b, 0x68, 0x64, 0x00, + 0x13, 0x40, 0x59, 0x1e, 0x8b, 0x41, 0x52, 0x10, 0xe4, 0x18, 0x2a, 0x60, + 0x01, 0x36, 0xe5, 0xe7, 0x20, 0x00, 0xfe, 0xbd, 0xbc, 0x01, 0x00, 0x20, + 0xb8, 0x01, 0x00, 0x20, 0xf7, 0xb5, 0x00, 0x24, 0x20, 0x22, 0x1e, 0x4d, + 0x1e, 0x4b, 0x2a, 0x55, 0x01, 0x34, 0x9c, 0x42, 0xfb, 0xd1, 0x01, 0x20, + 0xff, 0xf7, 0xd0, 0xff, 0x43, 0x1c, 0x30, 0xd0, 0x00, 0x28, 0x0c, 0xd0, + 0x08, 0x20, 0xff, 0xf7, 0xc9, 0xff, 0x06, 0x00, 0x43, 0x1c, 0x28, 0xd0, + 0xff, 0xf7, 0x6a, 0xff, 0x63, 0x1c, 0x2e, 0x55, 0x5c, 0x05, 0x64, 0x0d, + 0xeb, 0xe7, 0x0b, 0x20, 0xff, 0xf7, 0xbc, 0xff, 0x06, 0x00, 0x43, 0x1c, + 0x1b, 0xd0, 0x04, 0x20, 0xff, 0xf7, 0xb6, 0xff, 0x03, 0x00, 0x01, 0x90, + 0x01, 0x33, 0x14, 0xd0, 0x37, 0x00, 0x01, 0x9b, 0xba, 0x1b, 0x01, 0x33, + 0x93, 0x42, 0xd8, 0xdb, 0x7b, 0x05, 0x5b, 0x0d, 0xeb, 0x5c, 0x01, 0x37, + 0x18, 0x00, 0x00, 0x93, 0xff, 0xf7, 0x4a, 0xff, 0x6a, 0x46, 0x12, 0x78, + 0x63, 0x1c, 0x2a, 0x55, 0x5c, 0x05, 0x64, 0x0d, 0xeb, 0xe7, 0xf7, 0xbd, + 0xc0, 0x01, 0x00, 0x20, 0xef, 0x07, 0x00, 0x00, 0x07, 0xb5, 0x00, 0x21, + 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, 0x00, 0xf0, 0xa2, 0xff, + 0x07, 0xbd, 0xc0, 0x46, 0x14, 0x01, 0x00, 0x20, 0x10, 0xb5, 0x00, 0xf0, + 0x23, 0xfa, 0x10, 0xbd, 0x10, 0xb5, 0x00, 0xf0, 0xf7, 0xf9, 0x10, 0xbd, + 0x07, 0xb5, 0x00, 0x21, 0x04, 0x48, 0x0b, 0x00, 0x0a, 0x00, 0x00, 0x91, + 0x00, 0xf0, 0x8e, 0xff, 0x02, 0x4b, 0x03, 0x4a, 0x1a, 0x60, 0x07, 0xbd, + 0xc4, 0x11, 0x00, 0x20, 0xc0, 0x11, 0x00, 0x20, 0x50, 0xc3, 0x00, 0x00, + 0x07, 0xb5, 0x00, 0x21, 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, + 0x00, 0xf0, 0x7c, 0xff, 0x07, 0xbd, 0xc0, 0x46, 0xcc, 0x11, 0x00, 0x20, + 0x07, 0xb5, 0x00, 0x21, 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, + 0x00, 0xf0, 0x70, 0xff, 0x07, 0xbd, 0xc0, 0x46, 0xd4, 0x11, 0x00, 0x20, + 0x07, 0xb5, 0x00, 0x21, 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, + 0x00, 0xf0, 0x64, 0xff, 0x07, 0xbd, 0xc0, 0x46, 0xdc, 0x11, 0x00, 0x20, + 0x30, 0xb5, 0x85, 0xb0, 0x0c, 0x00, 0x05, 0x00, 0x02, 0xf0, 0x3a, 0xfa, + 0x04, 0x21, 0x00, 0x23, 0x01, 0x91, 0x03, 0xa9, 0xc2, 0xb2, 0x00, 0x91, + 0x63, 0x20, 0x29, 0x00, 0x03, 0x93, 0x00, 0xf0, 0xff, 0xf9, 0x03, 0x98, + 0x20, 0x60, 0xc0, 0x43, 0xc0, 0x0f, 0x05, 0xb0, 0x30, 0xbd, 0x10, 0xb5, + 0x04, 0x00, 0x00, 0x23, 0xa1, 0x60, 0x08, 0x00, 0x21, 0x1d, 0x23, 0x60, + 0x63, 0x60, 0xff, 0xf7, 0xdf, 0xff, 0x20, 0x00, 0x10, 0xbd, 0x00, 0x00, + 0x07, 0xb5, 0x00, 0x21, 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, + 0x00, 0xf0, 0x34, 0xff, 0x07, 0xbd, 0xc0, 0x46, 0xe4, 0x11, 0x00, 0x20, + 0x07, 0xb5, 0x00, 0x21, 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, + 0x00, 0xf0, 0x28, 0xff, 0x07, 0xbd, 0xc0, 0x46, 0xec, 0x11, 0x00, 0x20, + 0x10, 0xb5, 0x04, 0x00, 0x78, 0x22, 0x00, 0x21, 0x02, 0xf0, 0x1f, 0xf9, + 0x20, 0x00, 0x10, 0xbd, 0x10, 0xb5, 0x0c, 0x24, 0x4c, 0x43, 0x04, 0x19, + 0x20, 0x68, 0x00, 0x28, 0x05, 0xd0, 0x02, 0xf0, 0x01, 0xf9, 0x00, 0x23, + 0x63, 0x60, 0x23, 0x60, 0xa3, 0x60, 0x10, 0xbd, 0x70, 0xb5, 0x05, 0x00, + 0x00, 0x24, 0x21, 0x00, 0x28, 0x00, 0x01, 0x34, 0xff, 0xf7, 0xea, 0xff, + 0x0a, 0x2c, 0xf8, 0xd1, 0x28, 0x00, 0x70, 0xbd, 0x10, 0xb5, 0x05, 0x4c, + 0x20, 0x00, 0xff, 0xf7, 0xd9, 0xff, 0x04, 0x4a, 0x04, 0x49, 0x20, 0x00, + 0x02, 0xf0, 0x16, 0xf8, 0x10, 0xbd, 0xc0, 0x46, 0xf4, 0x11, 0x00, 0x20, + 0x00, 0x00, 0x00, 0x20, 0x7d, 0x27, 0x00, 0x00, 0xf8, 0xb5, 0x18, 0x23, + 0x23, 0x4e, 0x24, 0x4f, 0x33, 0x70, 0x24, 0x4c, 0x04, 0x33, 0x3b, 0x70, + 0x01, 0x3b, 0x23, 0x70, 0x00, 0xf0, 0x4a, 0xfb, 0x21, 0x4d, 0x1a, 0x28, + 0x04, 0xd8, 0x01, 0x23, 0x2b, 0x70, 0x23, 0x78, 0xdb, 0x43, 0x23, 0x70, + 0x1e, 0x48, 0x00, 0xf0, 0xad, 0xfa, 0x30, 0x78, 0x01, 0x21, 0x00, 0xf0, + 0xc3, 0xfd, 0x38, 0x78, 0x00, 0x21, 0x00, 0xf0, 0xbf, 0xfd, 0x20, 0x78, + 0x01, 0x21, 0x00, 0xf0, 0xbb, 0xfd, 0x01, 0x21, 0x1a, 0x20, 0x00, 0xf0, + 0xb7, 0xfd, 0x01, 0x21, 0x1a, 0x20, 0x00, 0xf0, 0xff, 0xfd, 0x30, 0x78, + 0x01, 0x21, 0x00, 0xf0, 0xfb, 0xfd, 0x29, 0x78, 0x20, 0x78, 0x00, 0xf0, + 0xf7, 0xfd, 0x0a, 0x20, 0x00, 0xf0, 0x0c, 0xfc, 0x29, 0x78, 0x01, 0x25, + 0x20, 0x78, 0x69, 0x40, 0x00, 0xf0, 0xee, 0xfd, 0x0b, 0x48, 0x00, 0xf0, + 0x03, 0xfc, 0x00, 0x21, 0x1a, 0x20, 0x00, 0xf0, 0xe7, 0xfd, 0x00, 0x21, + 0x1a, 0x20, 0x00, 0xf0, 0x97, 0xfd, 0x07, 0x4b, 0x1d, 0x70, 0xf8, 0xbd, + 0x12, 0x00, 0x00, 0x20, 0x10, 0x00, 0x00, 0x20, 0x11, 0x00, 0x00, 0x20, + 0x6c, 0x12, 0x00, 0x20, 0xb8, 0x16, 0x00, 0x20, 0xee, 0x02, 0x00, 0x00, + 0x6d, 0x12, 0x00, 0x20, 0x13, 0xb5, 0x00, 0x24, 0x6b, 0x46, 0x5c, 0x71, + 0x1c, 0x71, 0x01, 0x9a, 0x0b, 0x49, 0x0c, 0x48, 0x00, 0xf0, 0x8a, 0xfa, + 0x0b, 0x4b, 0x21, 0x00, 0x18, 0x78, 0x00, 0xf0, 0xc3, 0xfd, 0x00, 0xf0, + 0xa3, 0xfb, 0x04, 0x00, 0x08, 0x4b, 0x18, 0x78, 0x00, 0xf0, 0xe8, 0xfd, + 0x01, 0x28, 0x04, 0xd0, 0x00, 0xf0, 0x9a, 0xfb, 0x00, 0x1b, 0x04, 0x28, + 0xf4, 0xd9, 0x13, 0xbd, 0x00, 0x12, 0x7a, 0x00, 0xb8, 0x16, 0x00, 0x20, + 0x12, 0x00, 0x00, 0x20, 0x10, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x4b, + 0x01, 0x21, 0x18, 0x78, 0x00, 0xf0, 0xa6, 0xfd, 0x02, 0x48, 0x00, 0xf0, + 0x81, 0xfa, 0x10, 0xbd, 0x12, 0x00, 0x00, 0x20, 0xb8, 0x16, 0x00, 0x20, + 0x07, 0xb5, 0x6b, 0x46, 0xd8, 0x71, 0xd9, 0x79, 0x02, 0x48, 0xc9, 0xb2, + 0x00, 0xf0, 0x88, 0xfa, 0x0e, 0xbd, 0xc0, 0x46, 0xb8, 0x16, 0x00, 0x20, + 0x10, 0xb5, 0x03, 0x4b, 0x18, 0x78, 0x00, 0xf0, 0xb9, 0xfd, 0x00, 0x28, + 0xf9, 0xd1, 0x10, 0xbd, 0x10, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, + 0xff, 0x20, 0xff, 0xf7, 0xe5, 0xff, 0x20, 0x70, 0x10, 0xbd, 0x70, 0xb5, + 0x0c, 0x00, 0x05, 0x00, 0x08, 0x00, 0xff, 0xf7, 0xf3, 0xff, 0x20, 0x78, + 0x40, 0x1b, 0x43, 0x42, 0x58, 0x41, 0x70, 0xbd, 0x13, 0xb5, 0x6b, 0x46, + 0xdc, 0x1d, 0x00, 0x23, 0x20, 0x00, 0x23, 0x70, 0xff, 0xf7, 0xe6, 0xff, + 0x20, 0x78, 0x16, 0xbd, 0x70, 0xb5, 0x05, 0x00, 0x08, 0x4c, 0xff, 0xf7, + 0xf1, 0xff, 0xef, 0x28, 0x08, 0xd0, 0x01, 0x3c, 0x00, 0x2c, 0x01, 0xd0, + 0xa8, 0x42, 0xf6, 0xd1, 0x40, 0x1b, 0x43, 0x42, 0x58, 0x41, 0x70, 0xbd, + 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, 0xc0, 0x46, 0xe9, 0x03, 0x00, 0x00, + 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x00, 0x20, 0x16, 0x00, 0xff, 0xf7, + 0xb1, 0xff, 0x65, 0x19, 0xac, 0x42, 0x04, 0xd0, 0x20, 0x78, 0xff, 0xf7, + 0xab, 0xff, 0x01, 0x34, 0xf8, 0xe7, 0x01, 0x2e, 0x02, 0xd1, 0xee, 0x20, + 0xff, 0xf7, 0xa4, 0xff, 0x70, 0xbd, 0xf8, 0xb5, 0x05, 0x00, 0x08, 0x00, + 0x0e, 0x00, 0x17, 0x00, 0x2c, 0x00, 0xff, 0xf7, 0x9b, 0xff, 0x63, 0x1b, + 0x9e, 0x42, 0x04, 0xdd, 0x20, 0x78, 0xff, 0xf7, 0x95, 0xff, 0x01, 0x34, + 0xf7, 0xe7, 0x01, 0x2f, 0x02, 0xd1, 0xee, 0x20, 0xff, 0xf7, 0x8e, 0xff, + 0xf8, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0xff, 0x20, 0xff, 0xf7, 0x88, 0xff, + 0x00, 0x2c, 0x00, 0xd0, 0x20, 0x70, 0x10, 0xbd, 0xf0, 0xb5, 0x85, 0xb0, + 0x1f, 0x00, 0x02, 0xab, 0xdc, 0x1d, 0x00, 0x23, 0x05, 0x00, 0xe0, 0x20, + 0x01, 0x91, 0x16, 0x00, 0x23, 0x70, 0xff, 0xf7, 0xa9, 0xff, 0x00, 0x28, + 0x02, 0xd1, 0x00, 0x20, 0x05, 0xb0, 0xf0, 0xbd, 0x20, 0x00, 0xff, 0xf7, + 0x85, 0xff, 0x80, 0x22, 0x23, 0x78, 0x15, 0x43, 0xab, 0x42, 0xf4, 0xd1, + 0x20, 0x00, 0xff, 0xf7, 0x7d, 0xff, 0x23, 0x78, 0x01, 0x9a, 0x93, 0x42, + 0xed, 0xd1, 0x38, 0x00, 0xff, 0xf7, 0xd3, 0xff, 0x35, 0x00, 0x3a, 0x78, + 0xab, 0x1b, 0x9a, 0x42, 0x04, 0xdd, 0x28, 0x00, 0xff, 0xf7, 0x6e, 0xff, + 0x01, 0x35, 0xf6, 0xe7, 0x21, 0x00, 0xee, 0x20, 0xff, 0xf7, 0x6f, 0xff, + 0x01, 0x20, 0xdb, 0xe7, 0x70, 0xb5, 0x04, 0x00, 0xe0, 0x20, 0x0d, 0x00, + 0xff, 0xf7, 0x4a, 0xff, 0x7f, 0x20, 0x20, 0x40, 0xff, 0xf7, 0x46, 0xff, + 0x28, 0x00, 0xff, 0xf7, 0x43, 0xff, 0x00, 0x2d, 0x02, 0xd1, 0xee, 0x20, + 0xff, 0xf7, 0x3e, 0xff, 0x70, 0xbd, 0x00, 0x00, 0x12, 0x4b, 0x13, 0xb5, + 0x1b, 0x78, 0x00, 0x2b, 0x01, 0xd1, 0xff, 0xf7, 0xa9, 0xfe, 0xff, 0xf7, + 0x3f, 0xff, 0xff, 0xf7, 0xfd, 0xfe, 0x00, 0x21, 0x20, 0x20, 0xff, 0xf7, + 0xdd, 0xff, 0xff, 0xf7, 0x1d, 0xff, 0xff, 0xf7, 0x35, 0xff, 0xff, 0xf7, + 0xf3, 0xfe, 0x6b, 0x46, 0x9c, 0x1d, 0xff, 0x23, 0x23, 0x70, 0x6b, 0x46, + 0x00, 0x22, 0x07, 0x33, 0x1a, 0x70, 0x01, 0x21, 0x22, 0x00, 0x20, 0x20, + 0xff, 0xf7, 0x96, 0xff, 0xff, 0xf7, 0x0a, 0xff, 0x20, 0x78, 0x16, 0xbd, + 0x6d, 0x12, 0x00, 0x20, 0x11, 0x4b, 0x13, 0xb5, 0x1b, 0x78, 0x00, 0x2b, + 0x01, 0xd1, 0xff, 0xf7, 0x81, 0xfe, 0xff, 0xf7, 0x17, 0xff, 0xff, 0xf7, + 0xd5, 0xfe, 0x00, 0x21, 0x37, 0x20, 0xff, 0xf7, 0xb5, 0xff, 0xff, 0xf7, + 0xf5, 0xfe, 0xff, 0xf7, 0x0d, 0xff, 0xff, 0xf7, 0xcb, 0xfe, 0x6b, 0x46, + 0x00, 0x22, 0x07, 0x4c, 0x07, 0x33, 0x1a, 0x70, 0x01, 0x21, 0x22, 0x00, + 0x37, 0x20, 0xff, 0xf7, 0x71, 0xff, 0xff, 0xf7, 0xe5, 0xfe, 0x20, 0x00, + 0x16, 0xbd, 0xc0, 0x46, 0x6d, 0x12, 0x00, 0x20, 0x78, 0x12, 0x00, 0x20, + 0xf0, 0xb5, 0x85, 0xb0, 0x01, 0x93, 0x29, 0x4b, 0x06, 0x00, 0x1b, 0x78, + 0x00, 0x91, 0x14, 0x00, 0x00, 0x2b, 0x01, 0xd1, 0xff, 0xf7, 0x54, 0xfe, + 0x35, 0x00, 0x60, 0x3d, 0x6f, 0x42, 0x6f, 0x41, 0x03, 0x37, 0xff, 0xf7, + 0xe5, 0xfe, 0xff, 0xf7, 0xa3, 0xfe, 0x39, 0x00, 0x30, 0x00, 0xff, 0xf7, + 0x83, 0xff, 0x00, 0x22, 0x04, 0x21, 0x01, 0xa8, 0xff, 0xf7, 0x2b, 0xff, + 0x00, 0x22, 0x04, 0x21, 0x0b, 0xa8, 0xff, 0xf7, 0x26, 0xff, 0x6a, 0x1e, + 0x95, 0x41, 0x21, 0x00, 0xea, 0xb2, 0x00, 0x98, 0xff, 0xf7, 0x1f, 0xff, + 0x60, 0x2e, 0x04, 0xd1, 0x01, 0x22, 0x0b, 0x99, 0x0a, 0x98, 0xff, 0xf7, + 0x03, 0xff, 0x0c, 0x34, 0xe4, 0x19, 0x03, 0x27, 0x25, 0x00, 0x3d, 0x40, + 0x03, 0xd0, 0xff, 0xf7, 0xdb, 0xfe, 0x01, 0x34, 0xf8, 0xe7, 0xff, 0xf7, + 0xa1, 0xfe, 0x0f, 0x24, 0xff, 0xf7, 0xb8, 0xfe, 0xff, 0xf7, 0x76, 0xfe, + 0x0e, 0x23, 0x6c, 0x44, 0x6b, 0x44, 0x1d, 0x70, 0x25, 0x70, 0x60, 0x2e, + 0x00, 0xd1, 0x0a, 0x93, 0x23, 0x00, 0x0a, 0x9a, 0x01, 0x21, 0x30, 0x00, + 0xff, 0xf7, 0x18, 0xff, 0xff, 0xf7, 0x8c, 0xfe, 0x00, 0x20, 0x20, 0x56, + 0x05, 0xb0, 0xf0, 0xbd, 0x6d, 0x12, 0x00, 0x20, 0x07, 0xb5, 0x00, 0x21, + 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, 0x00, 0xf0, 0xf0, 0xfc, + 0x07, 0xbd, 0xc0, 0x46, 0x70, 0x12, 0x00, 0x20, 0x10, 0xb5, 0x05, 0x4a, + 0x05, 0x49, 0x06, 0x48, 0x00, 0xf0, 0x10, 0xf8, 0x00, 0x22, 0x05, 0x4b, + 0x05, 0x49, 0x1a, 0x70, 0x5a, 0x54, 0x10, 0xbd, 0x01, 0x04, 0x00, 0x00, + 0x00, 0x51, 0x00, 0x00, 0x84, 0x16, 0x00, 0x20, 0x7e, 0x12, 0x00, 0x20, + 0x02, 0x04, 0x00, 0x00, 0x30, 0xb5, 0x09, 0x4d, 0x09, 0x4c, 0xab, 0x68, + 0x5b, 0x03, 0x5b, 0x0f, 0x9b, 0x00, 0x1c, 0x59, 0x04, 0x60, 0xab, 0x68, + 0x01, 0x61, 0x9b, 0xb2, 0x43, 0x60, 0x63, 0x43, 0xa4, 0x00, 0x83, 0x60, + 0xc4, 0x60, 0x42, 0x61, 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x00, 0x56, 0x00, 0x00, 0xf7, 0xb5, 0x80, 0x26, 0x1a, 0x4d, 0x01, 0x91, + 0x6f, 0x68, 0x03, 0x33, 0x3e, 0x43, 0x9b, 0x08, 0x6e, 0x60, 0x00, 0x2b, + 0x2b, 0xd0, 0x17, 0x4e, 0x2e, 0x80, 0x2e, 0x7d, 0xf1, 0x07, 0xfc, 0xd5, + 0x1e, 0x00, 0x07, 0x68, 0x99, 0x1b, 0xbf, 0x08, 0x8f, 0x42, 0x19, 0xd9, + 0x00, 0x2e, 0x17, 0xd0, 0xff, 0x21, 0x17, 0x78, 0x8c, 0x43, 0x3c, 0x43, + 0x0f, 0x49, 0x57, 0x78, 0x0c, 0x40, 0x3f, 0x02, 0x3c, 0x43, 0x97, 0x78, + 0x01, 0x3e, 0x39, 0x04, 0x0c, 0x4f, 0x27, 0x40, 0xd4, 0x78, 0xbf, 0xb2, + 0x0f, 0x43, 0x24, 0x06, 0x01, 0x99, 0x3c, 0x43, 0x10, 0xc1, 0x01, 0x91, + 0x04, 0x32, 0xe0, 0xe7, 0x07, 0x4b, 0x2b, 0x80, 0x2b, 0x7d, 0xdb, 0x07, + 0xfc, 0xd5, 0x33, 0x00, 0xd1, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, + 0x44, 0xa5, 0xff, 0xff, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, + 0x04, 0xa5, 0xff, 0xff, 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, + 0x1a, 0x80, 0x1a, 0x7d, 0xd2, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, + 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x04, 0x00, + 0x0d, 0x00, 0x16, 0x00, 0xe3, 0x68, 0x29, 0x00, 0x20, 0x00, 0xb3, 0x42, + 0x05, 0xd2, 0xff, 0xf7, 0xe7, 0xff, 0xe3, 0x68, 0xed, 0x18, 0xf6, 0x1a, + 0xf4, 0xe7, 0xff, 0xf7, 0xe1, 0xff, 0x70, 0xbd, 0x03, 0x7d, 0x00, 0x2b, + 0x04, 0xd1, 0x43, 0x75, 0x83, 0x75, 0x83, 0x61, 0x01, 0x33, 0x03, 0x75, + 0x70, 0x47, 0x7f, 0xb5, 0xc3, 0x68, 0x02, 0xad, 0x04, 0x00, 0x0e, 0x00, + 0x02, 0x91, 0x6a, 0x60, 0x8b, 0x42, 0x03, 0xd1, 0x02, 0x8a, 0xab, 0x88, + 0x9a, 0x42, 0x18, 0xd0, 0x20, 0x00, 0x06, 0x22, 0x29, 0x00, 0x0c, 0x30, + 0x01, 0xf0, 0x38, 0xfe, 0x20, 0x68, 0x00, 0xf0, 0xb4, 0xfd, 0x6b, 0x79, + 0x22, 0x7a, 0xe1, 0x79, 0x00, 0x93, 0x20, 0x68, 0x00, 0x23, 0x00, 0xf0, + 0x4d, 0xfe, 0x20, 0x68, 0x29, 0x79, 0x32, 0x00, 0x00, 0xf0, 0x78, 0xfd, + 0x20, 0x68, 0x00, 0xf0, 0x9a, 0xfd, 0x7f, 0xbd, 0x70, 0xb5, 0x18, 0x26, + 0x04, 0x00, 0xff, 0xf7, 0xcb, 0xff, 0x33, 0x00, 0x08, 0x21, 0x20, 0x79, + 0x0d, 0x4d, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x9c, 0xfb, + 0x33, 0x00, 0x08, 0x21, 0xa0, 0x79, 0x43, 0x43, 0xeb, 0x18, 0x59, 0x56, + 0x00, 0xf0, 0x94, 0xfb, 0x08, 0x21, 0x60, 0x79, 0x46, 0x43, 0xad, 0x19, + 0x69, 0x56, 0x00, 0xf0, 0x8d, 0xfb, 0x04, 0x4b, 0x20, 0x00, 0x06, 0xcb, + 0xff, 0xf7, 0xb7, 0xff, 0x70, 0xbd, 0xc0, 0x46, 0x20, 0x56, 0x00, 0x00, + 0xd4, 0x16, 0x00, 0x20, 0x07, 0xb5, 0x43, 0x7d, 0x00, 0x91, 0x01, 0x92, + 0x00, 0x2b, 0x07, 0xd0, 0x9a, 0x07, 0x0a, 0xd5, 0xef, 0xf3, 0x10, 0x83, + 0x5a, 0x42, 0x53, 0x41, 0x83, 0x75, 0x72, 0xb6, 0x00, 0x99, 0x01, 0x9a, + 0xff, 0xf7, 0x9f, 0xff, 0x07, 0xbd, 0xdb, 0x07, 0xf8, 0xd5, 0x83, 0x69, + 0x01, 0x4a, 0x9b, 0xb2, 0x93, 0x60, 0xf3, 0xe7, 0x00, 0x18, 0x00, 0x40, + 0x43, 0x7d, 0x00, 0x2b, 0x05, 0xd0, 0x9a, 0x07, 0x04, 0xd5, 0x83, 0x7d, + 0x00, 0x2b, 0x00, 0xd0, 0x62, 0xb6, 0x70, 0x47, 0xdb, 0x07, 0xfc, 0xd5, + 0x83, 0x69, 0x02, 0x4a, 0x9b, 0xb2, 0xd3, 0x60, 0xf7, 0xe7, 0xc0, 0x46, + 0x00, 0x18, 0x00, 0x40, 0x10, 0xb5, 0x00, 0x68, 0x00, 0xf0, 0x50, 0xfd, + 0x10, 0xbd, 0x00, 0x00, 0x11, 0x4a, 0x12, 0x4b, 0x12, 0x49, 0x13, 0x60, + 0x00, 0x23, 0x53, 0x71, 0x13, 0x71, 0x11, 0x4a, 0x11, 0x60, 0x11, 0x49, + 0xd3, 0x60, 0x91, 0x80, 0x0d, 0x21, 0x91, 0x71, 0x0a, 0x39, 0x53, 0x74, + 0x13, 0x74, 0x13, 0x75, 0xd3, 0x71, 0x11, 0x72, 0x0c, 0x4a, 0xd3, 0x60, + 0x53, 0x74, 0x13, 0x74, 0x13, 0x75, 0x0b, 0x4b, 0xd1, 0x71, 0x13, 0x60, + 0x0a, 0x4b, 0x93, 0x80, 0x19, 0x23, 0x93, 0x71, 0x18, 0x3b, 0x13, 0x72, + 0x70, 0x47, 0xc0, 0x46, 0xd4, 0x16, 0x00, 0x20, 0x00, 0x09, 0x3d, 0x00, + 0x94, 0x1d, 0x00, 0x20, 0x9c, 0x16, 0x00, 0x20, 0x0c, 0x0b, 0x00, 0x00, + 0xb8, 0x16, 0x00, 0x20, 0x98, 0x1d, 0x00, 0x20, 0x17, 0x16, 0x00, 0x00, + 0x21, 0x20, 0x70, 0x47, 0x10, 0xb5, 0x02, 0x48, 0x01, 0xf0, 0x37, 0xfb, + 0x10, 0xbd, 0xc0, 0x46, 0xdc, 0x16, 0x00, 0x20, 0x10, 0xb5, 0x02, 0x48, + 0x01, 0xf0, 0x2f, 0xfb, 0x10, 0xbd, 0xc0, 0x46, 0x18, 0x19, 0x00, 0x20, + 0x10, 0xb5, 0x02, 0x48, 0x01, 0xf0, 0x27, 0xfb, 0x10, 0xbd, 0xc0, 0x46, + 0x54, 0x1b, 0x00, 0x20, 0xf0, 0xb5, 0x1f, 0x49, 0x85, 0xb0, 0x1f, 0x48, + 0x00, 0xf0, 0x38, 0xfc, 0x1e, 0x49, 0x1f, 0x48, 0x00, 0xf0, 0x34, 0xfc, + 0x1e, 0x4d, 0x1f, 0x49, 0x28, 0x00, 0x00, 0xf0, 0x2f, 0xfc, 0x1e, 0x4e, + 0x1e, 0x49, 0x30, 0x00, 0x00, 0xf0, 0x2a, 0xfc, 0x1d, 0x49, 0x1e, 0x48, + 0x00, 0xf0, 0x26, 0xfc, 0x1d, 0x4f, 0x1e, 0x49, 0x38, 0x00, 0x00, 0xf0, + 0x21, 0xfc, 0x01, 0x24, 0x03, 0x23, 0x39, 0x00, 0x00, 0x93, 0x01, 0x94, + 0x23, 0x00, 0x00, 0x22, 0x19, 0x48, 0x01, 0xf0, 0x91, 0xfa, 0x00, 0x23, + 0x31, 0x00, 0x01, 0x93, 0x00, 0x94, 0x1d, 0x33, 0x1e, 0x22, 0x16, 0x48, + 0x01, 0xf0, 0x88, 0xfa, 0x19, 0x23, 0x03, 0x93, 0x01, 0x3b, 0x02, 0x93, + 0x16, 0x3b, 0x01, 0x93, 0x00, 0x94, 0x14, 0x33, 0x17, 0x22, 0x29, 0x00, + 0x10, 0x48, 0x01, 0xf0, 0x37, 0xfa, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, + 0x00, 0x08, 0x00, 0x42, 0x90, 0x1d, 0x00, 0x20, 0x00, 0x0c, 0x00, 0x42, + 0x94, 0x1d, 0x00, 0x20, 0x98, 0x1d, 0x00, 0x20, 0x00, 0x10, 0x00, 0x42, + 0x9c, 0x1d, 0x00, 0x20, 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, + 0xa0, 0x1d, 0x00, 0x20, 0xa4, 0x1d, 0x00, 0x20, 0x00, 0x1c, 0x00, 0x42, + 0xdc, 0x16, 0x00, 0x20, 0x18, 0x19, 0x00, 0x20, 0x54, 0x1b, 0x00, 0x20, + 0xfe, 0xe7, 0x00, 0x00, 0x03, 0x4b, 0x10, 0xb5, 0x1b, 0x68, 0x00, 0x2b, + 0x00, 0xd0, 0x98, 0x47, 0x10, 0xbd, 0xc0, 0x46, 0xa8, 0x1d, 0x00, 0x20, + 0x70, 0xb5, 0x0f, 0x49, 0x0f, 0x4c, 0xa1, 0x42, 0x04, 0xd1, 0x00, 0xf0, + 0x89, 0xf8, 0xff, 0xf7, 0x31, 0xf9, 0xfe, 0xe7, 0x0c, 0x4d, 0x00, 0x23, + 0x8d, 0x42, 0xf6, 0xd0, 0xca, 0x18, 0xe8, 0x18, 0xa2, 0x42, 0x05, 0xd3, + 0x09, 0x4b, 0x82, 0x42, 0xef, 0xd0, 0x09, 0x49, 0x00, 0x22, 0x04, 0xe0, + 0x00, 0x68, 0x04, 0x33, 0x10, 0x60, 0xf1, 0xe7, 0x04, 0xc3, 0x8b, 0x42, + 0xfc, 0xd3, 0xe4, 0xe7, 0x00, 0x00, 0x00, 0x20, 0xd4, 0x00, 0x00, 0x20, + 0x34, 0x5a, 0x00, 0x00, 0xd4, 0x00, 0x00, 0x20, 0xdc, 0x23, 0x00, 0x20, + 0x10, 0xb5, 0x00, 0xf0, 0x60, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x00, 0xf0, + 0x51, 0xf8, 0x10, 0xbd, 0x01, 0x4b, 0x18, 0x68, 0x70, 0x47, 0xc0, 0x46, + 0xac, 0x1d, 0x00, 0x20, 0xf7, 0xb5, 0x13, 0x48, 0x01, 0x22, 0x84, 0x46, + 0x12, 0x49, 0x13, 0x4c, 0x8e, 0x68, 0x63, 0x68, 0x05, 0x68, 0x9b, 0x0e, + 0x13, 0x40, 0x01, 0x92, 0x88, 0x68, 0x62, 0x68, 0x01, 0x9f, 0x92, 0x0e, + 0x3a, 0x40, 0x67, 0x46, 0x3f, 0x68, 0x93, 0x42, 0x0e, 0xd1, 0xbd, 0x42, + 0x0c, 0xd1, 0x86, 0x42, 0x0a, 0xd3, 0x5b, 0x19, 0xfa, 0x25, 0x48, 0x68, + 0xad, 0x00, 0x86, 0x1b, 0x07, 0x48, 0x6b, 0x43, 0x70, 0x43, 0x00, 0x0d, + 0xc0, 0x18, 0xfe, 0xbd, 0x3d, 0x00, 0x13, 0x00, 0x06, 0x00, 0xe3, 0xe7, + 0xac, 0x1d, 0x00, 0x20, 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, + 0x55, 0x55, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x1e, 0x10, 0xd0, 0xff, 0xf7, + 0xcb, 0xff, 0x05, 0x00, 0x00, 0xf0, 0x1c, 0xf8, 0xff, 0xf7, 0xc6, 0xff, + 0x05, 0x4b, 0x40, 0x1b, 0x98, 0x42, 0xf7, 0xd9, 0xfa, 0x23, 0x01, 0x3c, + 0x9b, 0x00, 0xed, 0x18, 0x00, 0x2c, 0xf3, 0xd1, 0x70, 0xbd, 0xc0, 0x46, + 0xe7, 0x03, 0x00, 0x00, 0x70, 0x47, 0x00, 0x00, 0x10, 0xb5, 0x03, 0x4a, + 0x13, 0x68, 0x01, 0x33, 0x13, 0x60, 0x00, 0xf0, 0x0f, 0xfb, 0x10, 0xbd, + 0xac, 0x1d, 0x00, 0x20, 0x70, 0x47, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, + 0x1e, 0x22, 0xf0, 0xb5, 0x50, 0x48, 0x51, 0x49, 0x43, 0x68, 0x51, 0x4d, + 0x93, 0x43, 0x1a, 0x00, 0x02, 0x23, 0x13, 0x43, 0x43, 0x60, 0x08, 0x23, + 0x8a, 0x69, 0x13, 0x43, 0xfe, 0x22, 0x8b, 0x61, 0x2b, 0x68, 0xd2, 0x03, + 0x9b, 0x02, 0x13, 0x40, 0x4a, 0x4a, 0x13, 0x43, 0x4a, 0x4a, 0x93, 0x61, + 0x13, 0x00, 0x04, 0x22, 0xdc, 0x68, 0x14, 0x42, 0xfc, 0xd0, 0x01, 0x24, + 0x47, 0x4a, 0x14, 0x70, 0x16, 0x78, 0x26, 0x42, 0x03, 0xd0, 0x56, 0x78, + 0x76, 0xb2, 0x00, 0x2e, 0xf8, 0xdb, 0x01, 0x24, 0x94, 0x60, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x41, 0x4c, 0x54, 0x60, 0x54, 0x78, + 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x82, 0x24, 0xe4, 0x01, 0x54, 0x80, + 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x02, 0x24, 0x9c, 0x84, + 0x0e, 0x34, 0xde, 0x68, 0x26, 0x42, 0xfc, 0xd0, 0x38, 0x4c, 0xdc, 0x62, + 0x10, 0x24, 0xde, 0x68, 0x26, 0x42, 0xfc, 0xd0, 0x2c, 0x68, 0xa4, 0x0e, + 0x3f, 0x2c, 0x00, 0xd1, 0x20, 0x3c, 0x9e, 0x6a, 0x33, 0x4f, 0xa4, 0x02, + 0x3e, 0x40, 0x34, 0x43, 0x9c, 0x62, 0x9c, 0x6a, 0x31, 0x4e, 0xa4, 0x0a, + 0xa4, 0x02, 0x34, 0x43, 0x9c, 0x62, 0x30, 0x4c, 0xdc, 0x62, 0x00, 0x24, + 0x9c, 0x84, 0x10, 0x34, 0xde, 0x68, 0x26, 0x42, 0xfc, 0xd0, 0x2d, 0x4c, + 0x9c, 0x84, 0x10, 0x24, 0xde, 0x68, 0x26, 0x42, 0xfc, 0xd0, 0x02, 0x24, + 0x9e, 0x8c, 0x34, 0x43, 0x9c, 0x84, 0x10, 0x24, 0xde, 0x68, 0x26, 0x42, + 0xfc, 0xd0, 0x00, 0x24, 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x24, 0x4c, 0x54, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, + 0xfb, 0xdb, 0x1c, 0x6a, 0x21, 0x4e, 0x34, 0x40, 0x80, 0x26, 0x1c, 0x62, + 0x1c, 0x6a, 0xb4, 0x43, 0x1c, 0x62, 0x03, 0x23, 0x93, 0x60, 0x1e, 0x4b, + 0x53, 0x60, 0x53, 0x78, 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x00, 0x23, + 0xff, 0x24, 0x0b, 0x72, 0x1a, 0x4a, 0x4b, 0x72, 0x8b, 0x72, 0xcb, 0x72, + 0x19, 0x4b, 0x1a, 0x60, 0x19, 0x4a, 0x2b, 0x68, 0x11, 0x68, 0x9a, 0x06, + 0x5b, 0x01, 0xc9, 0x0e, 0x23, 0x40, 0x52, 0x0f, 0x12, 0x02, 0x0b, 0x43, + 0x13, 0x43, 0x15, 0x4a, 0x13, 0x85, 0x80, 0x23, 0x42, 0x68, 0x13, 0x43, + 0x43, 0x60, 0xf0, 0xbd, 0x00, 0x40, 0x00, 0x41, 0x00, 0x04, 0x00, 0x40, + 0x24, 0x60, 0x80, 0x00, 0x06, 0x06, 0x00, 0x00, 0x00, 0x08, 0x00, 0x40, + 0x00, 0x0c, 0x00, 0x40, 0x01, 0x04, 0x01, 0x00, 0xb9, 0x05, 0xff, 0x7d, + 0xff, 0x03, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x80, 0xbb, 0x0a, 0x1c, + 0x24, 0x05, 0x00, 0x00, 0x00, 0x07, 0x03, 0x00, 0xff, 0xfc, 0xff, 0xff, + 0x03, 0x06, 0x01, 0x00, 0x00, 0x6c, 0xdc, 0x02, 0x14, 0x00, 0x00, 0x20, + 0x20, 0x60, 0x80, 0x00, 0x00, 0x40, 0x00, 0x42, 0xfa, 0x21, 0x31, 0x4b, + 0x10, 0xb5, 0x18, 0x68, 0x89, 0x00, 0x01, 0xf0, 0xe5, 0xfa, 0x2f, 0x4b, + 0x01, 0x38, 0x98, 0x42, 0x56, 0xd8, 0x2e, 0x49, 0x2e, 0x4a, 0x48, 0x60, + 0xc0, 0x20, 0x13, 0x6a, 0x00, 0x06, 0x1b, 0x02, 0x1b, 0x0a, 0x03, 0x43, + 0x13, 0x62, 0x00, 0x24, 0x07, 0x23, 0x8c, 0x60, 0x0b, 0x60, 0x80, 0x21, + 0x13, 0x6a, 0x09, 0x06, 0x1b, 0x02, 0x1b, 0x0a, 0x0b, 0x43, 0x13, 0x62, + 0xfc, 0x22, 0x25, 0x4b, 0x19, 0x6a, 0x0a, 0x43, 0x1a, 0x62, 0xfc, 0x22, + 0x19, 0x6a, 0x92, 0x01, 0x0a, 0x43, 0x1a, 0x62, 0xa0, 0x22, 0x19, 0x6a, + 0xd2, 0x02, 0x0a, 0x43, 0x1a, 0x62, 0x20, 0x00, 0x00, 0x21, 0x01, 0x34, + 0x00, 0xf0, 0x76, 0xf8, 0x1f, 0x2c, 0xf8, 0xd1, 0x1b, 0x4b, 0x1c, 0x00, + 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, 0x19, 0x4a, 0x5a, 0x80, + 0x19, 0x4b, 0x1a, 0x00, 0x59, 0x7e, 0xc9, 0x09, 0x01, 0x29, 0xfb, 0xd0, + 0xe4, 0x21, 0xc9, 0x00, 0x99, 0x80, 0x3f, 0x21, 0xd9, 0x70, 0x53, 0x7e, + 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0xc0, 0x23, 0x00, 0x20, 0x5b, 0x01, + 0x13, 0x61, 0x90, 0x70, 0x00, 0xf0, 0x24, 0xf8, 0x63, 0x78, 0x5b, 0xb2, + 0x00, 0x2b, 0xfb, 0xdb, 0x0d, 0x4b, 0x0e, 0x4a, 0x63, 0x80, 0xd3, 0x79, + 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0x41, 0x23, 0x53, 0x70, 0x10, 0xbd, + 0xfe, 0xe7, 0xc0, 0x46, 0x14, 0x00, 0x00, 0x20, 0xff, 0xff, 0xff, 0x00, + 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, 0x00, 0x04, 0x00, 0x40, + 0x00, 0x0c, 0x00, 0x40, 0x1e, 0x40, 0x00, 0x00, 0x00, 0x40, 0x00, 0x42, + 0x21, 0x40, 0x00, 0x00, 0x00, 0x48, 0x00, 0x42, 0x16, 0x4a, 0x00, 0xb5, + 0x13, 0x00, 0x51, 0x7e, 0xc9, 0x09, 0x01, 0x29, 0xfb, 0xd0, 0x01, 0x38, + 0x04, 0x28, 0x16, 0xd8, 0x19, 0x69, 0x12, 0x4a, 0x0a, 0x40, 0x0f, 0x21, + 0x1a, 0x61, 0x5a, 0x78, 0x8a, 0x43, 0x01, 0xf0, 0x57, 0xfa, 0x03, 0x08, + 0x06, 0x0b, 0x03, 0x00, 0x11, 0x00, 0x01, 0x22, 0x0a, 0x43, 0x5a, 0x70, + 0x00, 0xbd, 0x11, 0x00, 0x03, 0x22, 0xf9, 0xe7, 0x11, 0x00, 0x02, 0x22, + 0xf6, 0xe7, 0xf0, 0x23, 0x11, 0x69, 0x1b, 0x05, 0x0b, 0x43, 0x0f, 0x21, + 0x13, 0x61, 0x53, 0x78, 0x8b, 0x43, 0x19, 0x00, 0x02, 0x23, 0x0b, 0x43, + 0x53, 0x70, 0xeb, 0xe7, 0x00, 0x40, 0x00, 0x42, 0xff, 0xff, 0xff, 0xf0, + 0x18, 0x23, 0x30, 0xb5, 0x1d, 0x00, 0x04, 0x00, 0x45, 0x43, 0x08, 0x20, + 0x20, 0x4a, 0x55, 0x19, 0x28, 0x56, 0x01, 0x30, 0x14, 0xd0, 0x03, 0x29, + 0x12, 0xd8, 0x08, 0x00, 0x63, 0x43, 0xd1, 0x56, 0xd3, 0x18, 0x01, 0xf0, + 0x25, 0xfa, 0x02, 0x28, 0x0e, 0x1b, 0x58, 0x68, 0xcb, 0x01, 0x02, 0x21, + 0x18, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, + 0x82, 0x40, 0x5a, 0x60, 0x30, 0xbd, 0x58, 0x68, 0xcb, 0x01, 0x06, 0x21, + 0x12, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, + 0x82, 0x40, 0x5a, 0x60, 0x9a, 0x61, 0xf1, 0xe7, 0x58, 0x68, 0xcb, 0x01, + 0x06, 0x21, 0x0c, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, + 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x5a, 0x61, 0xe4, 0xe7, 0x58, 0x68, + 0xcb, 0x01, 0x02, 0x21, 0x05, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, + 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x9a, 0x60, 0xd8, 0xe7, 0xc0, 0x46, + 0x20, 0x56, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0x18, 0x23, 0xf0, 0xb5, + 0x08, 0x24, 0x58, 0x43, 0x11, 0x4a, 0x13, 0x18, 0x1c, 0x57, 0x01, 0x34, + 0x1b, 0xd0, 0x01, 0x26, 0x35, 0x00, 0x5f, 0x68, 0x83, 0x56, 0xbd, 0x40, + 0x0d, 0x4a, 0xdb, 0x01, 0x9a, 0x18, 0x90, 0x68, 0x05, 0x42, 0x0b, 0xd1, + 0x0c, 0x00, 0x60, 0x1e, 0x84, 0x41, 0xd2, 0x19, 0x40, 0x32, 0x10, 0x78, + 0x34, 0x40, 0x03, 0x36, 0xa4, 0x00, 0xb0, 0x43, 0x20, 0x43, 0x10, 0x70, + 0x04, 0x4a, 0x9b, 0x18, 0x00, 0x29, 0x01, 0xd1, 0x5d, 0x61, 0xf0, 0xbd, + 0x9d, 0x61, 0xfc, 0xe7, 0x20, 0x56, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x18, 0x23, 0x10, 0xb5, 0x08, 0x24, 0x43, 0x43, 0x07, 0x49, 0x00, 0x20, + 0xca, 0x18, 0x14, 0x57, 0x01, 0x34, 0x08, 0xd0, 0x5b, 0x56, 0x05, 0x49, + 0xdb, 0x01, 0x5b, 0x18, 0x18, 0x6a, 0x53, 0x68, 0xd8, 0x40, 0x01, 0x23, + 0x18, 0x40, 0x10, 0xbd, 0x20, 0x56, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x18, 0x22, 0x42, 0x43, 0xf8, 0xb5, 0x2c, 0x4e, 0x03, 0x00, 0xb2, 0x18, + 0x12, 0x7a, 0x52, 0xb2, 0x14, 0x00, 0x01, 0x32, 0x0e, 0xd0, 0x48, 0x1c, + 0x00, 0x24, 0x0c, 0x28, 0x0a, 0xd8, 0x01, 0xf0, 0x97, 0xf9, 0x07, 0x1f, + 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x0b, 0x0b, 0x0b, 0x0b, 0x00, + 0x01, 0x24, 0x64, 0x42, 0x20, 0x00, 0xf8, 0xbd, 0x09, 0x29, 0x05, 0xd1, + 0x00, 0x21, 0x18, 0x00, 0xff, 0xf7, 0x4e, 0xff, 0x00, 0x24, 0xf5, 0xe7, + 0x0a, 0x29, 0x01, 0xd1, 0x08, 0x39, 0xf6, 0xe7, 0x00, 0x24, 0x0b, 0x29, + 0xee, 0xd1, 0x0a, 0x39, 0x18, 0x00, 0xff, 0xf7, 0x41, 0xff, 0xe9, 0xe7, + 0x18, 0x22, 0x53, 0x43, 0xf2, 0x18, 0x55, 0x68, 0x01, 0x20, 0x2c, 0x00, + 0xf3, 0x56, 0x13, 0x4a, 0xdb, 0x01, 0x6e, 0x08, 0x9b, 0x18, 0xc9, 0xb2, + 0x04, 0x40, 0x9e, 0x19, 0x00, 0x2c, 0x0d, 0xd0, 0x0f, 0x24, 0x30, 0x36, + 0x32, 0x78, 0x09, 0x01, 0x22, 0x40, 0x11, 0x43, 0xc9, 0xb2, 0x5b, 0x19, + 0x31, 0x70, 0x40, 0x33, 0x1a, 0x78, 0x10, 0x43, 0x18, 0x70, 0xd3, 0xe7, + 0x32, 0x00, 0x0f, 0x27, 0x30, 0x32, 0x16, 0x78, 0x5b, 0x19, 0xbe, 0x43, + 0x31, 0x43, 0x11, 0x70, 0x40, 0x33, 0x1a, 0x78, 0x10, 0x43, 0x18, 0x70, + 0xbe, 0xe7, 0xc0, 0x46, 0x20, 0x56, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0xf7, 0xb5, 0xc3, 0x1d, 0x01, 0x93, 0x00, 0x23, 0x06, 0x00, 0x0d, 0x00, + 0x04, 0x1d, 0x00, 0x93, 0x21, 0x78, 0x0a, 0x22, 0x28, 0x00, 0x00, 0xf0, + 0x81, 0xf8, 0x2e, 0x21, 0x07, 0x00, 0x28, 0x00, 0x00, 0xf0, 0x47, 0xf8, + 0x00, 0x9b, 0x3f, 0x18, 0xdb, 0x19, 0x00, 0x93, 0x01, 0x9b, 0x01, 0x34, + 0x9c, 0x42, 0xed, 0xd1, 0xf1, 0x79, 0x28, 0x00, 0x0a, 0x22, 0x00, 0xf0, + 0x6f, 0xf8, 0x00, 0x9b, 0x18, 0x18, 0xfe, 0xbd, 0x30, 0xb5, 0x03, 0xac, + 0x25, 0x78, 0x04, 0x4c, 0xc5, 0x71, 0x08, 0x34, 0x04, 0x60, 0x01, 0x71, + 0x42, 0x71, 0x83, 0x71, 0x30, 0xbd, 0xc0, 0x46, 0x38, 0x59, 0x00, 0x00, + 0xf7, 0xb5, 0x06, 0x00, 0x0d, 0x00, 0x0c, 0x00, 0x8b, 0x18, 0x01, 0x93, + 0x01, 0x9b, 0x67, 0x1b, 0x9c, 0x42, 0x07, 0xd0, 0x33, 0x68, 0x21, 0x78, + 0x1b, 0x68, 0x30, 0x00, 0x98, 0x47, 0x01, 0x34, 0x00, 0x28, 0xf3, 0xd1, + 0x38, 0x00, 0xfe, 0xbd, 0x70, 0xb5, 0x04, 0x00, 0x08, 0x00, 0x0d, 0x00, + 0x01, 0xf0, 0xb8, 0xfa, 0x23, 0x68, 0x02, 0x00, 0x29, 0x00, 0x5b, 0x68, + 0x20, 0x00, 0x98, 0x47, 0x70, 0xbd, 0x10, 0xb5, 0x0b, 0x1e, 0x02, 0xd0, + 0xff, 0xf7, 0xee, 0xff, 0x03, 0x00, 0x18, 0x00, 0x10, 0xbd, 0x10, 0xb5, + 0x03, 0x68, 0x1b, 0x68, 0x98, 0x47, 0x10, 0xbd, 0xf0, 0xb5, 0x8b, 0xb0, + 0x6b, 0x46, 0x15, 0x00, 0x00, 0x22, 0x05, 0x33, 0x06, 0x00, 0xda, 0x77, + 0x08, 0x00, 0x01, 0x2d, 0x00, 0xd8, 0x0a, 0x25, 0x09, 0xac, 0x29, 0x00, + 0x01, 0xf0, 0x6a, 0xf9, 0xca, 0xb2, 0x13, 0x00, 0x37, 0x33, 0x07, 0x00, + 0xdb, 0xb2, 0x09, 0x29, 0x02, 0xd8, 0x13, 0x00, 0x30, 0x33, 0xdb, 0xb2, + 0x01, 0x3c, 0x23, 0x70, 0x00, 0x2f, 0xee, 0xd1, 0x21, 0x00, 0x30, 0x00, + 0xff, 0xf7, 0xd1, 0xff, 0x0b, 0xb0, 0xf0, 0xbd, 0x10, 0xb5, 0x00, 0x2a, + 0x04, 0xd1, 0x03, 0x68, 0xc9, 0xb2, 0x1b, 0x68, 0x98, 0x47, 0x10, 0xbd, + 0xd2, 0xb2, 0xff, 0xf7, 0xd1, 0xff, 0xfa, 0xe7, 0x10, 0xb5, 0xff, 0xf7, + 0xf1, 0xff, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0xff, 0xf7, 0xf6, 0xfc, + 0x01, 0x4b, 0x1c, 0x60, 0x10, 0xbd, 0xc0, 0x46, 0x18, 0x00, 0x00, 0x20, + 0x01, 0x22, 0x02, 0x4b, 0x52, 0x42, 0x1a, 0x60, 0x70, 0x47, 0xc0, 0x46, + 0x18, 0x00, 0x00, 0x20, 0x16, 0x4a, 0x10, 0xb5, 0x13, 0x68, 0x59, 0x1c, + 0x26, 0xd0, 0x01, 0x3b, 0x13, 0x60, 0x00, 0x2b, 0x22, 0xd1, 0x72, 0xb6, + 0x12, 0x4b, 0x13, 0x4a, 0x04, 0x33, 0x93, 0x42, 0x13, 0xd9, 0x12, 0x4a, + 0x01, 0x21, 0x10, 0x00, 0x14, 0x7d, 0x0c, 0x42, 0xfc, 0xd0, 0x20, 0x21, + 0x14, 0x8b, 0xff, 0x31, 0x9b, 0x08, 0x5b, 0x00, 0x21, 0x43, 0x11, 0x83, + 0xd3, 0x61, 0x0c, 0x4b, 0x13, 0x80, 0x01, 0x23, 0x02, 0x7d, 0x1a, 0x42, + 0xfc, 0xd0, 0xbf, 0xf3, 0x4f, 0x8f, 0x09, 0x4b, 0x09, 0x4a, 0xda, 0x60, + 0xbf, 0xf3, 0x4f, 0x8f, 0xc0, 0x46, 0xfd, 0xe7, 0x10, 0xbd, 0xc0, 0x46, + 0x18, 0x00, 0x00, 0x20, 0x00, 0x20, 0x00, 0x00, 0x03, 0x02, 0x00, 0x00, + 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, 0x00, 0xed, 0x00, 0xe0, + 0x04, 0x00, 0xfa, 0x05, 0x01, 0x60, 0x70, 0x47, 0x94, 0x46, 0xf0, 0xb5, + 0x9e, 0x1e, 0x72, 0x1e, 0x96, 0x41, 0x62, 0x46, 0x05, 0x68, 0x92, 0x07, + 0x2f, 0x68, 0x36, 0x06, 0x3a, 0x43, 0x32, 0x43, 0x2a, 0x60, 0x07, 0x25, + 0x05, 0xac, 0x24, 0x78, 0x00, 0x68, 0xa4, 0x01, 0x29, 0x40, 0x21, 0x43, + 0x42, 0x68, 0x00, 0x24, 0x02, 0x2b, 0x00, 0xd0, 0x5c, 0x03, 0x11, 0x43, + 0x21, 0x43, 0x41, 0x60, 0xf0, 0xbd, 0x30, 0xb5, 0xc0, 0x25, 0x03, 0x68, + 0xad, 0x03, 0x1c, 0x68, 0x12, 0x05, 0x2a, 0x40, 0x22, 0x43, 0xc0, 0x24, + 0x09, 0x04, 0xa4, 0x02, 0x21, 0x40, 0x11, 0x43, 0x19, 0x60, 0x03, 0x68, + 0x5a, 0x68, 0x14, 0x43, 0x5c, 0x60, 0x30, 0xbd, 0x01, 0x23, 0x02, 0x68, + 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, 0x03, 0x68, 0x1a, 0x68, 0xd2, 0x07, + 0xfc, 0xd4, 0xda, 0x69, 0xd2, 0x07, 0xf9, 0xd4, 0x70, 0x47, 0x02, 0x23, + 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, 0x02, 0x68, 0xd3, 0x69, + 0x9b, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, + 0x02, 0xd4, 0x1a, 0x7e, 0x92, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0x00, 0x22, + 0x03, 0x68, 0x5a, 0x83, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x40, 0x07, + 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x09, 0x70, 0x47, + 0x80, 0x23, 0x02, 0x68, 0x5b, 0x42, 0x11, 0x7e, 0x0b, 0x43, 0x13, 0x76, + 0x70, 0x47, 0x03, 0x68, 0x58, 0x8b, 0x80, 0x07, 0xc0, 0x0f, 0x70, 0x47, + 0x02, 0x23, 0x02, 0x68, 0x51, 0x8b, 0x0b, 0x43, 0x53, 0x83, 0x70, 0x47, + 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, + 0x18, 0x8d, 0xc0, 0xb2, 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, + 0xfc, 0xd5, 0x89, 0xb2, 0x01, 0x20, 0x19, 0x85, 0x70, 0x47, 0x01, 0x22, + 0x03, 0x68, 0x9a, 0x75, 0x70, 0x47, 0x01, 0x22, 0x03, 0x68, 0x1a, 0x75, + 0x70, 0x47, 0x00, 0x00, 0x70, 0xb5, 0x01, 0x26, 0x04, 0x68, 0x4b, 0x08, + 0x33, 0x40, 0x31, 0x40, 0x25, 0x68, 0x09, 0x07, 0x5b, 0x07, 0x0b, 0x43, + 0x2b, 0x43, 0x23, 0x60, 0x04, 0x68, 0x51, 0x00, 0x03, 0x48, 0x00, 0xf0, + 0xd7, 0xff, 0x01, 0x38, 0xc0, 0xb2, 0x20, 0x73, 0x70, 0xbd, 0xc0, 0x46, + 0x00, 0x6c, 0xdc, 0x02, 0x01, 0x23, 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, + 0x13, 0x60, 0x03, 0x68, 0x1a, 0x68, 0xd2, 0x07, 0xfc, 0xd4, 0xda, 0x69, + 0xd2, 0x07, 0xf9, 0xd4, 0x70, 0x47, 0x02, 0x23, 0x02, 0x68, 0x11, 0x68, + 0x0b, 0x43, 0x13, 0x60, 0x02, 0x68, 0xd3, 0x69, 0x9b, 0x07, 0xfc, 0xd4, + 0x70, 0x47, 0x03, 0x68, 0xda, 0x69, 0x92, 0x07, 0xfc, 0xd4, 0x02, 0x21, + 0x1a, 0x68, 0x8a, 0x43, 0x1a, 0x60, 0x70, 0x47, 0x02, 0x68, 0x93, 0x6a, + 0x5b, 0x0a, 0x5b, 0x02, 0x19, 0x43, 0x91, 0x62, 0x03, 0x68, 0x1a, 0x7e, + 0x52, 0x07, 0xfc, 0xd5, 0x98, 0x6a, 0xc0, 0xb2, 0x70, 0x47, 0x00, 0x00, + 0x03, 0x68, 0x21, 0x4a, 0x30, 0xb5, 0x93, 0x42, 0x2f, 0xd0, 0x20, 0x4a, + 0x93, 0x42, 0x2f, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1f, 0x4a, + 0x93, 0x42, 0x2f, 0xd0, 0x1e, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1e, 0x4a, + 0x93, 0x42, 0x1f, 0xd1, 0x0e, 0x23, 0x19, 0x22, 0x01, 0x21, 0x03, 0x25, + 0x99, 0x40, 0x1b, 0x48, 0xc0, 0x24, 0x01, 0x60, 0x99, 0x08, 0x2b, 0x40, + 0xab, 0x40, 0xfc, 0x35, 0x9d, 0x40, 0x89, 0x00, 0x09, 0x18, 0xa4, 0x00, + 0x08, 0x59, 0xa8, 0x43, 0xc0, 0x25, 0x9d, 0x40, 0x2b, 0x00, 0x03, 0x43, + 0x0b, 0x51, 0x80, 0x23, 0xdb, 0x01, 0x1a, 0x43, 0x11, 0x4b, 0x5a, 0x80, + 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, 0x30, 0xbd, 0x09, 0x23, + 0x14, 0x22, 0xdd, 0xe7, 0x0a, 0x23, 0x15, 0x22, 0xda, 0xe7, 0x0b, 0x23, + 0x16, 0x22, 0xd7, 0xe7, 0x0c, 0x23, 0x17, 0x22, 0xd4, 0xe7, 0x0d, 0x23, + 0x18, 0x22, 0xd1, 0xe7, 0x00, 0x08, 0x00, 0x42, 0x00, 0x0c, 0x00, 0x42, + 0x00, 0x10, 0x00, 0x42, 0x00, 0x14, 0x00, 0x42, 0x00, 0x18, 0x00, 0x42, + 0x00, 0x1c, 0x00, 0x42, 0x00, 0xe1, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x40, + 0xf8, 0xb5, 0x04, 0x00, 0x0f, 0x00, 0x16, 0x00, 0x1d, 0x00, 0xff, 0xf7, + 0xa5, 0xff, 0x20, 0x00, 0xff, 0xf7, 0x04, 0xff, 0x1c, 0x21, 0xbb, 0x00, + 0x0b, 0x40, 0x71, 0x07, 0x22, 0x68, 0x09, 0x0c, 0x0b, 0x43, 0x13, 0x60, + 0x84, 0x23, 0x22, 0x68, 0x93, 0x75, 0x01, 0x2f, 0x1a, 0xd1, 0x10, 0x21, + 0x01, 0x2e, 0x00, 0xd0, 0x08, 0x39, 0x0c, 0x4b, 0x69, 0x43, 0x18, 0x68, + 0xc0, 0x00, 0x00, 0xf0, 0x2d, 0xff, 0x07, 0x22, 0x21, 0x68, 0x02, 0x40, + 0x8b, 0x89, 0x52, 0x03, 0xdb, 0x04, 0xdb, 0x0c, 0x13, 0x43, 0x8b, 0x81, + 0x22, 0x68, 0x03, 0x04, 0x90, 0x89, 0xdb, 0x0c, 0x40, 0x0b, 0x40, 0x03, + 0x18, 0x43, 0x90, 0x81, 0xf8, 0xbd, 0xc0, 0x46, 0x14, 0x00, 0x00, 0x20, + 0xf7, 0xb5, 0x06, 0x00, 0x01, 0x93, 0x08, 0xab, 0x1f, 0x78, 0x0d, 0x00, + 0x14, 0x00, 0xff, 0xf7, 0x3f, 0xff, 0x30, 0x00, 0xff, 0xf7, 0x6a, 0xff, + 0xc0, 0x22, 0x24, 0x05, 0x92, 0x03, 0x14, 0x40, 0xba, 0x07, 0x0c, 0x27, + 0x17, 0x43, 0x3c, 0x43, 0xc0, 0x27, 0x07, 0x22, 0xbf, 0x02, 0x2d, 0x04, + 0x33, 0x68, 0x3d, 0x40, 0x25, 0x43, 0x1d, 0x60, 0x01, 0x9b, 0x31, 0x68, + 0x13, 0x40, 0x1a, 0x00, 0x80, 0x23, 0x9b, 0x02, 0x13, 0x43, 0x4b, 0x60, + 0xf7, 0xbd, 0x00, 0x20, 0x70, 0x47, 0x70, 0xb5, 0x0f, 0x26, 0xcb, 0x1d, + 0x01, 0x39, 0x02, 0x00, 0x32, 0x40, 0xd5, 0xb2, 0x2c, 0x00, 0x00, 0x09, + 0x30, 0x34, 0x09, 0x2a, 0x00, 0xdd, 0x07, 0x34, 0x1c, 0x70, 0x01, 0x3b, + 0x8b, 0x42, 0xf2, 0xd1, 0x70, 0xbd, 0x00, 0x00, 0x10, 0xb5, 0x0c, 0x00, + 0x0b, 0x4b, 0x18, 0x68, 0xff, 0xf7, 0xe7, 0xff, 0x21, 0x00, 0x0a, 0x4b, + 0x08, 0x31, 0x18, 0x68, 0xff, 0xf7, 0xe1, 0xff, 0x21, 0x00, 0x08, 0x4b, + 0x10, 0x31, 0x18, 0x68, 0xff, 0xf7, 0xdb, 0xff, 0x21, 0x00, 0x06, 0x4b, + 0x18, 0x31, 0x18, 0x68, 0xff, 0xf7, 0xd5, 0xff, 0x20, 0x20, 0x10, 0xbd, + 0x0c, 0xa0, 0x80, 0x00, 0x40, 0xa0, 0x80, 0x00, 0x44, 0xa0, 0x80, 0x00, + 0x48, 0xa0, 0x80, 0x00, 0x08, 0xb4, 0x02, 0x4b, 0x9c, 0x46, 0x10, 0x38, + 0x08, 0xbc, 0x60, 0x47, 0x3d, 0x3a, 0x00, 0x00, 0x70, 0x47, 0x3f, 0x20, + 0x70, 0x47, 0x13, 0xb5, 0x6b, 0x46, 0x02, 0x68, 0xd9, 0x71, 0x07, 0x33, + 0x54, 0x68, 0x19, 0x00, 0x01, 0x22, 0xa0, 0x47, 0x16, 0xbd, 0x00, 0x00, + 0x70, 0xb5, 0x0a, 0x26, 0x0b, 0x78, 0x92, 0xb0, 0x6e, 0x44, 0x02, 0x33, + 0x05, 0x00, 0x0b, 0x70, 0x3c, 0x22, 0x00, 0x21, 0x30, 0x00, 0x00, 0xf0, + 0x6a, 0xff, 0x39, 0x48, 0x01, 0xac, 0x06, 0x90, 0x38, 0x48, 0x24, 0x21, + 0x07, 0x90, 0x06, 0x20, 0x20, 0x77, 0x68, 0x46, 0x36, 0x4a, 0xa1, 0x74, + 0x22, 0x81, 0x36, 0x4a, 0x36, 0x4b, 0xa2, 0x81, 0xfd, 0x3a, 0xff, 0x3a, + 0x80, 0x18, 0xc1, 0x77, 0x68, 0x46, 0x23, 0x39, 0x06, 0x30, 0xc1, 0x77, + 0x68, 0x46, 0x07, 0x30, 0xc1, 0x77, 0x02, 0xa8, 0xc1, 0x77, 0x07, 0x20, + 0xf2, 0x77, 0x03, 0x26, 0x08, 0x31, 0x69, 0x44, 0xc8, 0x77, 0x03, 0xa9, + 0xce, 0x77, 0x10, 0x21, 0x2b, 0x36, 0x6e, 0x44, 0x31, 0x70, 0x09, 0x26, + 0x21, 0x85, 0x1f, 0x31, 0x69, 0x44, 0x0e, 0x70, 0x0c, 0xa9, 0x05, 0x3e, + 0x0e, 0x70, 0x33, 0x21, 0x23, 0x80, 0x02, 0x23, 0x69, 0x44, 0x0b, 0x70, + 0x06, 0x36, 0x0d, 0xa9, 0x0e, 0x70, 0x22, 0x49, 0x35, 0x36, 0xa1, 0x86, + 0x3b, 0x21, 0x6e, 0x44, 0x30, 0x70, 0x10, 0xa8, 0x62, 0x74, 0xe2, 0x77, + 0x02, 0x70, 0x3d, 0x32, 0x69, 0x44, 0x6a, 0x44, 0x0b, 0x70, 0x13, 0x70, + 0x40, 0x21, 0x00, 0x22, 0xe3, 0x70, 0x23, 0x71, 0x63, 0x71, 0xa3, 0x73, + 0x41, 0x33, 0x6b, 0x44, 0x21, 0x87, 0x19, 0x70, 0x5a, 0x70, 0x2b, 0x7d, + 0xc0, 0x39, 0xa3, 0x70, 0xa3, 0x72, 0x63, 0x77, 0x01, 0x33, 0xdb, 0xb2, + 0xa3, 0x77, 0x6a, 0x7d, 0x0b, 0x20, 0x0d, 0x00, 0x68, 0x44, 0x15, 0x43, + 0xc5, 0x77, 0x31, 0x20, 0x68, 0x44, 0x03, 0x70, 0x3a, 0x23, 0x50, 0x1c, + 0x6b, 0x44, 0x18, 0x70, 0x41, 0x23, 0x02, 0x32, 0x0a, 0x43, 0x6b, 0x44, + 0x1a, 0x70, 0x21, 0x00, 0x42, 0x22, 0x08, 0x48, 0x00, 0xf0, 0xd8, 0xfa, + 0x12, 0xb0, 0x70, 0xbd, 0x10, 0x01, 0x04, 0x24, 0x02, 0x06, 0x05, 0x24, + 0x09, 0x04, 0x00, 0x00, 0x01, 0x02, 0x00, 0x00, 0x08, 0x0b, 0x00, 0x00, + 0x07, 0x05, 0x00, 0x00, 0x18, 0x1e, 0x00, 0x20, 0x08, 0xb4, 0x02, 0x4b, + 0x9c, 0x46, 0x10, 0x38, 0x08, 0xbc, 0x60, 0x47, 0xad, 0x3a, 0x00, 0x00, + 0x70, 0xb5, 0x02, 0x7d, 0x0b, 0x79, 0x0c, 0x00, 0x00, 0x25, 0x9a, 0x42, + 0x0b, 0xd1, 0x0b, 0x78, 0x4e, 0x78, 0xa1, 0x2b, 0x09, 0xd1, 0x21, 0x2e, + 0x05, 0xd1, 0x07, 0x22, 0x1f, 0x49, 0x20, 0x48, 0x00, 0xf0, 0xae, 0xfa, + 0x01, 0x35, 0x28, 0x00, 0x70, 0xbd, 0x21, 0x2b, 0xfb, 0xd1, 0x20, 0x2e, + 0x2b, 0xd1, 0x07, 0x22, 0x19, 0x49, 0x1a, 0x48, 0x00, 0xf0, 0xe4, 0xf9, + 0x17, 0x4b, 0x1a, 0x78, 0x59, 0x78, 0x09, 0x02, 0x11, 0x43, 0x9a, 0x78, + 0x12, 0x04, 0x11, 0x43, 0xda, 0x78, 0x12, 0x06, 0x0a, 0x43, 0x96, 0x21, + 0xc9, 0x00, 0x8a, 0x42, 0x1d, 0xd1, 0xdb, 0x79, 0xdb, 0x07, 0x1a, 0xd4, + 0xfa, 0x20, 0xff, 0xf7, 0x1d, 0xfd, 0x00, 0x21, 0x0d, 0x48, 0x00, 0xf0, + 0xb3, 0xfa, 0x01, 0x25, 0x23, 0x2e, 0xd8, 0xd1, 0xe3, 0x78, 0xa2, 0x78, + 0x1b, 0x02, 0x13, 0x43, 0x09, 0x4a, 0x00, 0x21, 0x07, 0x48, 0x13, 0x60, + 0x00, 0xf0, 0xa6, 0xfa, 0xcd, 0xe7, 0x22, 0x2e, 0xef, 0xd1, 0x8a, 0x78, + 0x02, 0x4b, 0xda, 0x71, 0xd2, 0xe7, 0xff, 0xf7, 0x0d, 0xfd, 0xe4, 0xe7, + 0x20, 0x00, 0x00, 0x20, 0x18, 0x1e, 0x00, 0x20, 0x1c, 0x00, 0x00, 0x20, + 0x08, 0xb4, 0x02, 0x4b, 0x9c, 0x46, 0x10, 0x38, 0x08, 0xbc, 0x60, 0x47, + 0xd9, 0x3b, 0x00, 0x00, 0x10, 0xb5, 0x41, 0x7d, 0x00, 0x6a, 0x01, 0x31, + 0x00, 0xf0, 0xd8, 0xf8, 0x03, 0x4b, 0x1b, 0x68, 0x01, 0x33, 0x5a, 0x1e, + 0x93, 0x41, 0x18, 0x18, 0x10, 0xbd, 0xc0, 0x46, 0x28, 0x00, 0x00, 0x20, + 0x10, 0xb5, 0x41, 0x7d, 0x00, 0x6a, 0x02, 0x31, 0x00, 0xf0, 0xde, 0xf8, + 0x10, 0xbd, 0x10, 0xb5, 0x41, 0x7d, 0x00, 0x6a, 0x02, 0x31, 0x00, 0xf0, + 0xa5, 0xf8, 0x10, 0xbd, 0x70, 0xb5, 0x0d, 0x00, 0x41, 0x7d, 0x04, 0x00, + 0x13, 0x00, 0x02, 0x31, 0x2a, 0x00, 0x00, 0x6a, 0x00, 0xf0, 0x92, 0xf9, + 0x00, 0x28, 0x01, 0xd1, 0x01, 0x23, 0x63, 0x60, 0x70, 0xbd, 0x00, 0x00, + 0x10, 0xb5, 0x05, 0x4c, 0x23, 0x68, 0x5a, 0x1c, 0x04, 0xd1, 0x03, 0x68, + 0x5b, 0x69, 0x98, 0x47, 0x03, 0x00, 0x20, 0x60, 0x18, 0x00, 0x10, 0xbd, + 0x28, 0x00, 0x00, 0x20, 0x07, 0x4a, 0x03, 0x00, 0x10, 0x68, 0x10, 0xb5, + 0x41, 0x1c, 0x03, 0xd0, 0x01, 0x23, 0x5b, 0x42, 0x13, 0x60, 0x10, 0xbd, + 0x59, 0x7d, 0x18, 0x6a, 0x01, 0x31, 0x00, 0xf0, 0x1f, 0xf9, 0xf8, 0xe7, + 0x28, 0x00, 0x00, 0x20, 0x70, 0x47, 0x00, 0x20, 0x70, 0x47, 0x00, 0x00, + 0xfa, 0x23, 0x9b, 0x00, 0x10, 0xb5, 0x83, 0x60, 0x0f, 0x4b, 0x00, 0x22, + 0xc3, 0x82, 0x03, 0x00, 0x28, 0x33, 0x83, 0x61, 0x0d, 0x4b, 0x04, 0x00, + 0x42, 0x60, 0xc2, 0x61, 0x18, 0x00, 0x44, 0x33, 0x23, 0x61, 0x08, 0x30, + 0x63, 0x1d, 0x21, 0x62, 0x20, 0x60, 0xda, 0x77, 0x83, 0x23, 0xa3, 0x62, + 0x81, 0x3b, 0xe3, 0x62, 0x80, 0x33, 0x23, 0x63, 0x00, 0xf0, 0x40, 0xf8, + 0x21, 0x00, 0x10, 0x31, 0x00, 0xf0, 0x10, 0xf8, 0x20, 0x00, 0x10, 0xbd, + 0x03, 0x02, 0x00, 0x00, 0x44, 0x59, 0x00, 0x00, 0x10, 0xb5, 0x02, 0x49, + 0x02, 0x48, 0xff, 0xf7, 0xd3, 0xff, 0x10, 0xbd, 0x18, 0x1e, 0x00, 0x20, + 0xb0, 0x1d, 0x00, 0x20, 0xf0, 0xb5, 0x8c, 0x79, 0x45, 0x78, 0x03, 0x00, + 0x2a, 0x19, 0x00, 0x20, 0x07, 0x2a, 0x1f, 0xdc, 0x5a, 0x68, 0x82, 0x42, + 0x16, 0xd1, 0x59, 0x60, 0x1a, 0x78, 0xc8, 0x79, 0x0a, 0x71, 0x12, 0x18, + 0x4d, 0x71, 0x1a, 0x70, 0x00, 0x22, 0x0b, 0x4d, 0xd0, 0xb2, 0x84, 0x42, + 0x0f, 0xd9, 0x8f, 0x68, 0x58, 0x78, 0x96, 0x00, 0xf7, 0x59, 0x86, 0x00, + 0x01, 0x30, 0x77, 0x51, 0x01, 0x32, 0x58, 0x70, 0xf2, 0xe7, 0x02, 0x00, + 0xd0, 0x68, 0x00, 0x28, 0xfb, 0xd1, 0xd1, 0x60, 0xe4, 0xe7, 0x01, 0x20, + 0xf0, 0xbd, 0xc0, 0x46, 0xf0, 0x1d, 0x00, 0x20, 0x01, 0x21, 0x06, 0x4a, + 0x10, 0xb5, 0x13, 0x68, 0x05, 0x48, 0x0b, 0x40, 0x04, 0xd1, 0x80, 0x24, + 0x64, 0x00, 0x04, 0x80, 0x43, 0x60, 0x11, 0x60, 0x10, 0xbd, 0xc0, 0x46, + 0xe4, 0x1d, 0x00, 0x20, 0xe8, 0x1d, 0x00, 0x20, 0x0b, 0x4b, 0xca, 0xb2, + 0x0b, 0x48, 0x89, 0x01, 0xc9, 0x18, 0x53, 0x01, 0xc3, 0x18, 0x59, 0x61, + 0x99, 0x69, 0x08, 0x32, 0x89, 0x0b, 0x89, 0x03, 0x99, 0x61, 0x03, 0x68, + 0x52, 0x01, 0x9a, 0x18, 0x02, 0x23, 0xd3, 0x71, 0x51, 0x79, 0x82, 0x3b, + 0x0b, 0x43, 0x53, 0x71, 0x70, 0x47, 0xc0, 0x46, 0x40, 0x1e, 0x00, 0x20, + 0xc8, 0x22, 0x00, 0x20, 0x08, 0x4b, 0x8a, 0x00, 0xd0, 0x58, 0x10, 0xb5, + 0x00, 0x28, 0x03, 0xd0, 0x03, 0x68, 0x9b, 0x68, 0x98, 0x47, 0x10, 0xbd, + 0xc9, 0xb2, 0x04, 0x4b, 0x49, 0x01, 0x59, 0x18, 0x88, 0x68, 0x80, 0x04, + 0x80, 0x0c, 0xf6, 0xe7, 0x1c, 0x1e, 0x00, 0x20, 0xc8, 0x22, 0x00, 0x20, + 0x10, 0xb5, 0x0c, 0x00, 0xff, 0xf7, 0xe6, 0xff, 0x00, 0x28, 0x0c, 0xd0, + 0x06, 0x4b, 0xe4, 0xb2, 0x1b, 0x68, 0x08, 0x34, 0x64, 0x01, 0x1c, 0x19, + 0x80, 0x23, 0x62, 0x79, 0x5b, 0x42, 0x13, 0x43, 0x63, 0x71, 0x02, 0x23, + 0xe3, 0x71, 0x10, 0xbd, 0xc8, 0x22, 0x00, 0x20, 0xf0, 0xb5, 0x1c, 0x00, + 0x2a, 0x4b, 0x85, 0xb0, 0x1b, 0x68, 0x07, 0x00, 0x0d, 0x00, 0x02, 0x92, + 0x00, 0x2b, 0x4a, 0xd0, 0x27, 0x4b, 0x8a, 0x00, 0xd0, 0x58, 0x00, 0x28, + 0x08, 0xd0, 0x03, 0x68, 0x22, 0x00, 0x5b, 0x68, 0x02, 0x99, 0x98, 0x47, + 0x04, 0x00, 0x20, 0x00, 0x05, 0xb0, 0xf0, 0xbd, 0x38, 0x00, 0xff, 0xf7, + 0xb9, 0xff, 0x84, 0x42, 0x04, 0xd9, 0x29, 0x00, 0x38, 0x00, 0xff, 0xf7, + 0xb3, 0xff, 0x04, 0x00, 0x01, 0x21, 0xeb, 0xb2, 0x1b, 0x4e, 0x03, 0x93, + 0x5b, 0x01, 0x01, 0x93, 0xf2, 0x18, 0x93, 0x68, 0x9b, 0x0b, 0x9b, 0x03, + 0x93, 0x60, 0x01, 0x9a, 0x33, 0x68, 0x02, 0x98, 0x9b, 0x18, 0xff, 0x33, + 0x5a, 0x7a, 0x0a, 0x43, 0x5a, 0x72, 0x14, 0x4b, 0xa9, 0x01, 0xc9, 0x18, + 0x22, 0x00, 0x00, 0xf0, 0x37, 0xfd, 0x00, 0x2c, 0xd7, 0xd0, 0x29, 0x00, + 0x38, 0x00, 0xff, 0xf7, 0x93, 0xff, 0x00, 0x28, 0xd1, 0xd1, 0x40, 0x21, + 0x03, 0x9b, 0x32, 0x68, 0x08, 0x33, 0x5b, 0x01, 0xd3, 0x18, 0x18, 0x79, + 0x01, 0x43, 0x19, 0x71, 0x01, 0x21, 0xd9, 0x71, 0x01, 0x9b, 0xd3, 0x18, + 0xff, 0x33, 0x9a, 0x7a, 0x0a, 0x43, 0x9a, 0x72, 0xbf, 0xe7, 0x01, 0x24, + 0x64, 0x42, 0xbc, 0xe7, 0xc4, 0x22, 0x00, 0x20, 0x1c, 0x1e, 0x00, 0x20, + 0xc8, 0x22, 0x00, 0x20, 0x00, 0x20, 0x00, 0x20, 0x13, 0xb5, 0x6b, 0x46, + 0xdc, 0x1d, 0x22, 0x00, 0x01, 0x23, 0xff, 0xf7, 0x99, 0xff, 0x01, 0x28, + 0x01, 0xd1, 0x20, 0x78, 0x16, 0xbd, 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, + 0x70, 0xb5, 0xcb, 0xb2, 0x12, 0x4a, 0x13, 0x48, 0x5c, 0x01, 0x89, 0x01, + 0x89, 0x18, 0x02, 0x19, 0x51, 0x60, 0x91, 0x68, 0x10, 0x4d, 0x08, 0x33, + 0x0d, 0x40, 0x80, 0x21, 0x49, 0x03, 0x29, 0x43, 0x40, 0x25, 0x91, 0x60, + 0x91, 0x68, 0x89, 0x0b, 0x89, 0x03, 0x91, 0x60, 0x01, 0x68, 0x5a, 0x01, + 0x8a, 0x18, 0x16, 0x79, 0x35, 0x43, 0x15, 0x71, 0x95, 0x79, 0x6d, 0x06, + 0xfc, 0xd5, 0x5b, 0x01, 0xc9, 0x18, 0xcb, 0x79, 0xdb, 0x07, 0xfc, 0xd5, + 0x00, 0x19, 0x80, 0x68, 0xc0, 0xb2, 0x70, 0xbd, 0x00, 0x20, 0x00, 0x20, + 0xc8, 0x22, 0x00, 0x20, 0xff, 0x3f, 0x00, 0xf0, 0x70, 0xb5, 0x0d, 0x00, + 0x00, 0x21, 0x14, 0x00, 0xff, 0xf7, 0xcc, 0xff, 0xa0, 0x42, 0x00, 0xd9, + 0x20, 0x00, 0x00, 0x23, 0x03, 0x49, 0xa3, 0x42, 0x03, 0xd0, 0xca, 0x5c, + 0xea, 0x54, 0x01, 0x33, 0xf9, 0xe7, 0x70, 0xbd, 0x00, 0x20, 0x00, 0x20, + 0xf0, 0xb5, 0x1e, 0x00, 0x3a, 0x4b, 0x85, 0xb0, 0x1b, 0x68, 0x0f, 0x00, + 0x01, 0x92, 0x00, 0x2b, 0x35, 0xd0, 0x80, 0x23, 0xdb, 0x01, 0x9e, 0x42, + 0x31, 0xd8, 0x00, 0x25, 0x35, 0x4b, 0x8a, 0x01, 0xd3, 0x18, 0x02, 0x93, + 0x00, 0x2e, 0x2c, 0xd0, 0x33, 0x4b, 0x1b, 0x68, 0x03, 0x93, 0xff, 0x23, + 0x3b, 0x40, 0x1c, 0x00, 0x00, 0x93, 0x08, 0x34, 0x03, 0x9b, 0x64, 0x01, + 0x1c, 0x19, 0xa3, 0x79, 0xdb, 0x09, 0x21, 0xd0, 0x2d, 0x4b, 0x2e, 0x49, + 0x18, 0x68, 0x00, 0xf0, 0xd3, 0xfb, 0x2d, 0x4b, 0x17, 0x21, 0x58, 0x43, + 0x00, 0xf0, 0xce, 0xfb, 0x2b, 0x4b, 0xe2, 0x79, 0x92, 0x07, 0x13, 0xd4, + 0xda, 0x5d, 0x00, 0x2a, 0x01, 0xd1, 0x01, 0x38, 0xf7, 0xd2, 0x01, 0x22, + 0xda, 0x55, 0x00, 0x9b, 0x5a, 0x01, 0x21, 0x4b, 0x9b, 0x18, 0x9a, 0x69, + 0x92, 0x0b, 0x92, 0x03, 0x9a, 0x61, 0x01, 0x25, 0x6d, 0x42, 0x28, 0x00, + 0x05, 0xb0, 0xf0, 0xbd, 0x00, 0x22, 0x1f, 0x4b, 0x34, 0x00, 0xda, 0x55, + 0x3f, 0x2e, 0x09, 0xd9, 0x00, 0x9b, 0x40, 0x24, 0x5a, 0x01, 0x17, 0x4b, + 0x9b, 0x18, 0x80, 0x22, 0x99, 0x69, 0x12, 0x06, 0x0a, 0x43, 0x9a, 0x61, + 0x22, 0x00, 0x01, 0x99, 0x02, 0x98, 0x00, 0xf0, 0x69, 0xfc, 0x00, 0x9b, + 0xa1, 0x04, 0x5a, 0x01, 0x0f, 0x4b, 0x89, 0x0c, 0x9b, 0x18, 0x02, 0x9a, + 0x2d, 0x19, 0x5a, 0x61, 0x9a, 0x69, 0x36, 0x1b, 0x92, 0x0b, 0x92, 0x03, + 0x0a, 0x43, 0x9a, 0x61, 0x00, 0x9b, 0x03, 0x9a, 0x08, 0x33, 0x5b, 0x01, + 0xd3, 0x18, 0x02, 0x22, 0xda, 0x71, 0x59, 0x79, 0x82, 0x3a, 0x0a, 0x43, + 0x5a, 0x71, 0x01, 0x9b, 0x1b, 0x19, 0x01, 0x93, 0x9a, 0xe7, 0xc0, 0x46, + 0xc4, 0x22, 0x00, 0x20, 0x40, 0x1e, 0x00, 0x20, 0xc8, 0x22, 0x00, 0x20, + 0x14, 0x00, 0x00, 0x20, 0x40, 0x42, 0x0f, 0x00, 0x70, 0x11, 0x01, 0x00, + 0x38, 0x1e, 0x00, 0x20, 0x70, 0xb5, 0x0d, 0x00, 0x1c, 0x00, 0x0d, 0x4b, + 0xae, 0x01, 0xf6, 0x18, 0x11, 0x00, 0x30, 0x00, 0x22, 0x00, 0x00, 0xf0, + 0x31, 0xfc, 0xed, 0xb2, 0x09, 0x49, 0x6d, 0x01, 0x4d, 0x19, 0x6e, 0x61, + 0xab, 0x69, 0x08, 0x4a, 0x20, 0x00, 0x13, 0x40, 0xab, 0x61, 0xab, 0x69, + 0xa2, 0x04, 0x9b, 0x0b, 0x92, 0x0c, 0x9b, 0x03, 0x13, 0x43, 0xab, 0x61, + 0x70, 0xbd, 0xc0, 0x46, 0x40, 0x1e, 0x00, 0x20, 0xc8, 0x22, 0x00, 0x20, + 0xff, 0x3f, 0x00, 0xf0, 0xf7, 0xb5, 0x10, 0x4b, 0x01, 0x90, 0x1b, 0x78, + 0x0f, 0x00, 0x15, 0x00, 0x00, 0x2b, 0x0c, 0xd1, 0x0d, 0x4b, 0x16, 0x00, + 0x1c, 0x78, 0x00, 0x2c, 0x09, 0xd0, 0x0c, 0x4e, 0x0c, 0x48, 0x34, 0x88, + 0x20, 0x18, 0x64, 0x19, 0x00, 0xf0, 0x04, 0xfc, 0x34, 0x80, 0x28, 0x00, + 0xfe, 0xbd, 0x00, 0x2e, 0xfb, 0xd0, 0x3a, 0x19, 0x33, 0x00, 0x00, 0x21, + 0x01, 0x98, 0xff, 0xf7, 0xbd, 0xff, 0x24, 0x18, 0x36, 0x1a, 0xf4, 0xe7, + 0xc0, 0x21, 0x00, 0x20, 0xc1, 0x22, 0x00, 0x20, 0xc2, 0x22, 0x00, 0x20, + 0xc1, 0x21, 0x00, 0x20, 0xcb, 0xb2, 0x04, 0x49, 0x5b, 0x01, 0xc9, 0x18, + 0x8b, 0x69, 0x9b, 0x0b, 0x9b, 0x03, 0x8b, 0x61, 0x70, 0x47, 0xc0, 0x46, + 0xc8, 0x22, 0x00, 0x20, 0x01, 0x4b, 0x02, 0x4a, 0x1a, 0x60, 0x70, 0x47, + 0xc8, 0x22, 0x00, 0x20, 0x00, 0x50, 0x00, 0x41, 0x01, 0x20, 0x70, 0x47, + 0x10, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, 0x98, 0x47, 0x10, 0xbd, + 0x13, 0x04, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, 0xd9, 0x69, 0x9a, 0x69, + 0x91, 0x42, 0x03, 0xd0, 0xdb, 0x69, 0xc0, 0x18, 0x00, 0x7d, 0x70, 0x47, + 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x69, + 0xff, 0xf7, 0xb6, 0xfa, 0x22, 0x00, 0x00, 0x23, 0xfc, 0x32, 0x93, 0x61, + 0xd3, 0x61, 0x86, 0x22, 0x92, 0x00, 0xa4, 0x18, 0x63, 0x60, 0xa3, 0x60, + 0x10, 0xbd, 0xf0, 0x20, 0x01, 0x40, 0x30, 0x39, 0x48, 0x42, 0x48, 0x41, + 0x70, 0x47, 0xf0, 0x23, 0x1b, 0x01, 0x19, 0x40, 0x80, 0x23, 0x06, 0x20, + 0x9b, 0x00, 0x99, 0x42, 0x0a, 0xd0, 0x01, 0x33, 0xff, 0x33, 0x01, 0x30, + 0x99, 0x42, 0x05, 0xd0, 0x80, 0x23, 0x02, 0x38, 0x5b, 0x00, 0x99, 0x42, + 0x00, 0xd0, 0x00, 0x20, 0x70, 0x47, 0x0f, 0x20, 0x01, 0x40, 0x00, 0x20, + 0x01, 0x29, 0x03, 0xd0, 0x02, 0x39, 0x48, 0x1e, 0x81, 0x41, 0x48, 0x1c, + 0x70, 0x47, 0x00, 0x00, 0x89, 0x23, 0xf0, 0xb5, 0x18, 0x26, 0x85, 0xb0, + 0x02, 0x91, 0x9b, 0x00, 0x04, 0x00, 0xc0, 0x5c, 0x33, 0x00, 0x08, 0x21, + 0x43, 0x43, 0x32, 0x4d, 0x17, 0x00, 0xeb, 0x18, 0x59, 0x56, 0xff, 0xf7, + 0x03, 0xf9, 0x30, 0x4b, 0x08, 0x21, 0xe0, 0x5c, 0x33, 0x00, 0x43, 0x43, + 0xeb, 0x18, 0x59, 0x56, 0xff, 0xf7, 0xfa, 0xf8, 0x2c, 0x4b, 0xe2, 0x5c, + 0x03, 0x93, 0x02, 0x2a, 0x09, 0xd1, 0x11, 0x33, 0xe0, 0x5c, 0xff, 0x28, + 0x05, 0xd0, 0x08, 0x21, 0x46, 0x43, 0xae, 0x19, 0x71, 0x56, 0xff, 0xf7, + 0xeb, 0xf8, 0x8a, 0x26, 0xb6, 0x00, 0xa0, 0x5d, 0xff, 0x28, 0x19, 0xd0, + 0x01, 0x21, 0xff, 0xf7, 0x53, 0xf8, 0x18, 0x22, 0xa3, 0x5d, 0x21, 0x49, + 0x5a, 0x43, 0xab, 0x56, 0xad, 0x18, 0xdb, 0x01, 0x58, 0x18, 0x8b, 0x21, + 0x89, 0x00, 0x60, 0x50, 0x1d, 0x49, 0x01, 0x22, 0x5b, 0x18, 0x8c, 0x21, + 0x89, 0x00, 0x63, 0x50, 0x69, 0x68, 0x8a, 0x40, 0x8d, 0x21, 0x89, 0x00, + 0x62, 0x50, 0x1a, 0x60, 0x01, 0x22, 0x02, 0x9b, 0x11, 0x00, 0x20, 0x69, + 0xff, 0xf7, 0x2a, 0xfb, 0x39, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x8f, 0xff, + 0x39, 0x00, 0x05, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x9e, 0xff, 0x39, 0x00, + 0x06, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x7f, 0xff, 0x33, 0x00, 0x00, 0x90, + 0x29, 0x00, 0x20, 0x69, 0x01, 0x22, 0xff, 0xf7, 0xf3, 0xf9, 0x0b, 0x4b, + 0x20, 0x69, 0xe2, 0x5c, 0x03, 0x9b, 0xe1, 0x5c, 0xff, 0xf7, 0x09, 0xfa, + 0x20, 0x69, 0xff, 0xf7, 0x26, 0xfa, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, + 0x20, 0x56, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, 0x27, 0x02, 0x00, 0x00, + 0x18, 0x44, 0x00, 0x41, 0x14, 0x44, 0x00, 0x41, 0x26, 0x02, 0x00, 0x00, + 0x80, 0x22, 0x10, 0xb5, 0x04, 0x00, 0x52, 0x00, 0x00, 0x21, 0x00, 0xf0, + 0x14, 0xfb, 0x23, 0x00, 0x00, 0x22, 0xfc, 0x33, 0x5a, 0x60, 0x20, 0x00, + 0x9a, 0x60, 0x10, 0xbd, 0xf0, 0xb5, 0x85, 0xb0, 0x1d, 0x00, 0x0a, 0xab, + 0x1b, 0x78, 0x04, 0x00, 0x00, 0x93, 0x0b, 0xab, 0x1b, 0x78, 0x16, 0x00, + 0x01, 0x93, 0x0c, 0xab, 0x1b, 0x78, 0x0f, 0x00, 0x02, 0x93, 0x0d, 0xab, + 0x1b, 0x78, 0x03, 0x93, 0x00, 0x23, 0x43, 0x60, 0xfa, 0x23, 0x9b, 0x00, + 0x83, 0x60, 0x12, 0x4b, 0x08, 0x33, 0x03, 0x60, 0x14, 0x30, 0xff, 0xf7, + 0xd5, 0xff, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0xd0, 0xff, + 0x89, 0x23, 0x6a, 0x46, 0x9b, 0x00, 0x27, 0x61, 0xe6, 0x54, 0x0b, 0x4b, + 0x12, 0x78, 0xe5, 0x54, 0x0a, 0x4b, 0x20, 0x00, 0xe2, 0x54, 0x6a, 0x46, + 0x09, 0x4b, 0x12, 0x79, 0xe2, 0x54, 0x6a, 0x46, 0x12, 0x7a, 0x01, 0x33, + 0xe2, 0x54, 0x6a, 0x46, 0x12, 0x7b, 0x10, 0x33, 0xe2, 0x54, 0x05, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x9c, 0x59, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, + 0x26, 0x02, 0x00, 0x00, 0x27, 0x02, 0x00, 0x00, 0xf7, 0xb5, 0x1d, 0x00, + 0x08, 0xab, 0x1b, 0x78, 0x04, 0x00, 0x00, 0x93, 0x09, 0xab, 0x1b, 0x78, + 0x16, 0x00, 0x01, 0x93, 0x00, 0x23, 0x43, 0x60, 0xfa, 0x23, 0x9b, 0x00, + 0x83, 0x60, 0x11, 0x4b, 0x0f, 0x00, 0x08, 0x33, 0x03, 0x60, 0x14, 0x30, + 0xff, 0xf7, 0x98, 0xff, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, + 0x93, 0xff, 0x89, 0x23, 0x6a, 0x46, 0x9b, 0x00, 0x27, 0x61, 0xe6, 0x54, + 0x09, 0x4b, 0x12, 0x78, 0xe5, 0x54, 0x09, 0x4b, 0x20, 0x00, 0xe2, 0x54, + 0x6a, 0x46, 0x08, 0x4b, 0x12, 0x79, 0xe2, 0x54, 0x8a, 0x22, 0x29, 0x3b, + 0xff, 0x3b, 0x92, 0x00, 0xa3, 0x54, 0x10, 0x32, 0xa3, 0x54, 0xfe, 0xbd, + 0x9c, 0x59, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, 0x26, 0x02, 0x00, 0x00, + 0x27, 0x02, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, 0x58, 0x68, 0x9b, 0x68, + 0xc0, 0x1a, 0x01, 0xd5, 0x01, 0x30, 0xff, 0x30, 0x70, 0x47, 0x10, 0xb5, + 0x04, 0x00, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0xf0, 0xff, + 0x00, 0x28, 0xf8, 0xd1, 0x20, 0x69, 0xff, 0xf7, 0x80, 0xf9, 0x10, 0xbd, + 0x10, 0xb5, 0x14, 0x30, 0xff, 0xf7, 0xe6, 0xff, 0x10, 0xbd, 0x03, 0x00, + 0xfc, 0x33, 0x59, 0x68, 0x9a, 0x68, 0x91, 0x42, 0x04, 0xdb, 0x5a, 0x68, + 0x98, 0x68, 0x80, 0x1a, 0xff, 0x30, 0x70, 0x47, 0x98, 0x68, 0x5b, 0x68, + 0xc0, 0x1a, 0x01, 0x38, 0xf9, 0xe7, 0x10, 0xb5, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0xeb, 0xff, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x69, + 0xff, 0xf7, 0x7b, 0xf9, 0x00, 0x28, 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, + 0x86, 0xf9, 0x20, 0x69, 0xff, 0xf7, 0x78, 0xf9, 0x20, 0x69, 0xff, 0xf7, + 0x60, 0xf9, 0x00, 0x28, 0x20, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x7b, 0xf9, + 0x22, 0x00, 0xfc, 0x32, 0x93, 0x69, 0xd1, 0x69, 0x01, 0x33, 0xdb, 0xb2, + 0x8b, 0x42, 0x03, 0xd0, 0x91, 0x69, 0x61, 0x18, 0x08, 0x75, 0x93, 0x61, + 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, 0x20, 0x00, + 0x14, 0x30, 0xff, 0xf7, 0xc0, 0xff, 0x09, 0x28, 0x06, 0xdc, 0x8b, 0x23, + 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, 0x1a, 0x60, + 0x20, 0x69, 0xff, 0xf7, 0x55, 0xf9, 0x00, 0x28, 0x1a, 0xd0, 0x20, 0x00, + 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0x92, 0xff, 0x00, 0x28, 0x22, 0xd0, + 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x99, 0x68, 0x5a, 0x68, 0x91, 0x42, + 0x18, 0xd0, 0x8e, 0x21, 0x9a, 0x68, 0x49, 0x00, 0xa2, 0x18, 0x51, 0x5c, + 0x9a, 0x68, 0x01, 0x32, 0xd2, 0xb2, 0x9a, 0x60, 0xc9, 0xb2, 0x20, 0x69, + 0xff, 0xf7, 0x41, 0xf9, 0x20, 0x69, 0xff, 0xf7, 0x1f, 0xf9, 0x00, 0x28, + 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x1e, 0xf9, 0x20, 0x69, 0xff, 0xf7, + 0x0e, 0xf9, 0x10, 0xbd, 0x01, 0x21, 0x49, 0x42, 0xec, 0xe7, 0x20, 0x69, + 0xff, 0xf7, 0x3b, 0xf9, 0xec, 0xe7, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x00, + 0x00, 0x69, 0x0d, 0x00, 0xff, 0xf7, 0x1e, 0xf9, 0x00, 0x28, 0x3e, 0xd1, + 0xff, 0x26, 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x5a, 0x68, 0x99, 0x68, + 0x01, 0x32, 0x32, 0x40, 0x8a, 0x42, 0x23, 0xd1, 0xef, 0xf3, 0x10, 0x83, + 0xdb, 0x07, 0x10, 0xd4, 0x1e, 0x4b, 0x5b, 0x68, 0xdb, 0x05, 0xdb, 0x0d, + 0xed, 0xd0, 0x10, 0x3b, 0x5b, 0xb2, 0x00, 0x2b, 0x10, 0xda, 0x0f, 0x22, + 0x13, 0x40, 0x08, 0x3b, 0x9b, 0x08, 0x19, 0x4a, 0x9b, 0x00, 0x9b, 0x18, + 0x1b, 0x68, 0x20, 0x69, 0xff, 0xf7, 0xfa, 0xf8, 0x00, 0x28, 0xdc, 0xd0, + 0x20, 0x00, 0xff, 0xf7, 0x6a, 0xff, 0xd8, 0xe7, 0x9b, 0x08, 0xc0, 0x33, + 0x12, 0x4a, 0x9b, 0x00, 0x9b, 0x58, 0xf0, 0xe7, 0x5a, 0x68, 0x01, 0x32, + 0x16, 0x40, 0x9a, 0x68, 0x96, 0x42, 0x05, 0xd0, 0x8e, 0x21, 0x5a, 0x68, + 0x49, 0x00, 0xa2, 0x18, 0x55, 0x54, 0x5e, 0x60, 0x20, 0x69, 0xff, 0xf7, + 0xf0, 0xf8, 0x01, 0x20, 0x70, 0xbd, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0x1c, 0xff, 0x00, 0x28, 0xb9, 0xd1, 0x29, 0x00, 0x20, 0x69, + 0xff, 0xf7, 0xdb, 0xf8, 0xf1, 0xe7, 0xc0, 0x46, 0x00, 0xed, 0x00, 0xe0, + 0x1c, 0xed, 0x00, 0xe0, 0x00, 0xe1, 0x00, 0xe0, 0x03, 0x00, 0x70, 0xb5, + 0xfc, 0x33, 0xd9, 0x69, 0x9a, 0x69, 0x04, 0x00, 0x91, 0x42, 0x1a, 0xd0, + 0xda, 0x69, 0x82, 0x18, 0x15, 0x7d, 0xda, 0x69, 0x01, 0x32, 0xd2, 0xb2, + 0xda, 0x61, 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, + 0x20, 0x00, 0x14, 0x30, 0xff, 0xf7, 0x11, 0xff, 0x0a, 0x28, 0x06, 0xdd, + 0x8c, 0x23, 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, + 0x1a, 0x60, 0x28, 0x00, 0x70, 0xbd, 0x01, 0x25, 0x6d, 0x42, 0xe8, 0xe7, + 0x10, 0xb5, 0x04, 0x00, 0x00, 0x68, 0x00, 0xf0, 0x5f, 0xf9, 0x20, 0x00, + 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x68, 0x00, 0x28, 0x01, 0xd0, + 0x00, 0xf0, 0x56, 0xf9, 0x00, 0x23, 0x23, 0x60, 0xa3, 0x60, 0x63, 0x60, + 0x10, 0xbd, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x00, 0x68, 0x01, 0x31, + 0x00, 0xf0, 0x0e, 0xfa, 0x03, 0x1e, 0x01, 0xd0, 0x01, 0x20, 0x28, 0xc4, + 0x70, 0xbd, 0x03, 0x68, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x2b, 0x04, 0xd0, + 0x43, 0x68, 0x8b, 0x42, 0x01, 0xd3, 0x01, 0x20, 0x10, 0xbd, 0x20, 0x00, + 0xff, 0xf7, 0xe7, 0xff, 0x00, 0x28, 0xf9, 0xd0, 0xa3, 0x68, 0x00, 0x2b, + 0xf5, 0xd1, 0x22, 0x68, 0x13, 0x70, 0xf2, 0xe7, 0x70, 0xb5, 0x0e, 0x00, + 0x11, 0x00, 0x04, 0x00, 0x15, 0x00, 0xff, 0xf7, 0xe4, 0xff, 0x00, 0x28, + 0x04, 0xd1, 0x20, 0x00, 0xff, 0xf7, 0xc7, 0xff, 0x20, 0x00, 0x70, 0xbd, + 0xa5, 0x60, 0x31, 0x00, 0x20, 0x68, 0x00, 0xf0, 0x07, 0xfa, 0xf7, 0xe7, + 0x00, 0x23, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x03, 0x60, 0x43, 0x60, + 0x83, 0x60, 0x99, 0x42, 0x07, 0xd0, 0x08, 0x00, 0x00, 0xf0, 0x02, 0xfa, + 0x29, 0x00, 0x02, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xdb, 0xff, 0x20, 0x00, + 0x70, 0xbd, 0x70, 0xb5, 0x05, 0x00, 0x08, 0x00, 0x0c, 0x00, 0x00, 0xf0, + 0xf5, 0xf9, 0x21, 0x00, 0x02, 0x00, 0x28, 0x00, 0xff, 0xf7, 0xce, 0xff, + 0x70, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x29, 0x03, 0xd0, 0xff, 0xf7, + 0xee, 0xff, 0x20, 0x00, 0x10, 0xbd, 0xff, 0xf7, 0x96, 0xff, 0xfa, 0xe7, + 0x02, 0x68, 0x10, 0xb5, 0x0b, 0x68, 0x00, 0x2a, 0x13, 0xd0, 0x00, 0x2b, + 0x0c, 0xd1, 0x81, 0x68, 0x18, 0x00, 0x00, 0x29, 0x07, 0xd0, 0x10, 0x78, + 0x05, 0xe0, 0x89, 0x68, 0x10, 0x00, 0x00, 0x29, 0x01, 0xd0, 0x18, 0x78, + 0x40, 0x42, 0x10, 0xbd, 0x19, 0x00, 0x10, 0x00, 0x00, 0xf0, 0xba, 0xf9, + 0xf9, 0xe7, 0x00, 0x2b, 0xf1, 0xd1, 0x18, 0x00, 0xf5, 0xe7, 0x10, 0xb5, + 0xff, 0xf7, 0xe0, 0xff, 0xc0, 0x0f, 0x10, 0xbd, 0x0b, 0x00, 0x10, 0xb5, + 0x01, 0x00, 0x18, 0x00, 0x00, 0xf0, 0x98, 0xf8, 0x10, 0xbd, 0x00, 0x00, + 0x02, 0xb4, 0x71, 0x46, 0x49, 0x08, 0x49, 0x00, 0x09, 0x5c, 0x49, 0x00, + 0x8e, 0x44, 0x02, 0xbc, 0x70, 0x47, 0xc0, 0x46, 0x00, 0x22, 0x43, 0x08, + 0x8b, 0x42, 0x74, 0xd3, 0x03, 0x09, 0x8b, 0x42, 0x5f, 0xd3, 0x03, 0x0a, + 0x8b, 0x42, 0x44, 0xd3, 0x03, 0x0b, 0x8b, 0x42, 0x28, 0xd3, 0x03, 0x0c, + 0x8b, 0x42, 0x0d, 0xd3, 0xff, 0x22, 0x09, 0x02, 0x12, 0xba, 0x03, 0x0c, + 0x8b, 0x42, 0x02, 0xd3, 0x12, 0x12, 0x09, 0x02, 0x65, 0xd0, 0x03, 0x0b, + 0x8b, 0x42, 0x19, 0xd3, 0x00, 0xe0, 0x09, 0x0a, 0xc3, 0x0b, 0x8b, 0x42, + 0x01, 0xd3, 0xcb, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0b, 0x8b, 0x42, + 0x01, 0xd3, 0x8b, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0b, 0x8b, 0x42, + 0x01, 0xd3, 0x4b, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0b, 0x8b, 0x42, + 0x01, 0xd3, 0x0b, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x0a, 0x8b, 0x42, + 0x01, 0xd3, 0xcb, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0a, 0x8b, 0x42, + 0x01, 0xd3, 0x8b, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0a, 0x8b, 0x42, + 0x01, 0xd3, 0x4b, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0a, 0x8b, 0x42, + 0x01, 0xd3, 0x0b, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0xcd, 0xd2, 0xc3, 0x09, + 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x09, + 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x09, + 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x09, + 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x08, + 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x08, + 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x08, + 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x41, 0x1a, + 0x00, 0xd2, 0x01, 0x46, 0x52, 0x41, 0x10, 0x46, 0x70, 0x47, 0xff, 0xe7, + 0x01, 0xb5, 0x00, 0x20, 0x00, 0xf0, 0x06, 0xf8, 0x02, 0xbd, 0xc0, 0x46, + 0x00, 0x29, 0xf7, 0xd0, 0x76, 0xe7, 0x70, 0x47, 0x70, 0x47, 0xc0, 0x46, + 0x10, 0xb5, 0x04, 0x00, 0x04, 0x48, 0x13, 0x00, 0x00, 0x28, 0x04, 0xd0, + 0x0a, 0x00, 0x02, 0x20, 0x21, 0x00, 0x00, 0xe0, 0x00, 0xbf, 0x10, 0xbd, + 0x00, 0x00, 0x00, 0x00, 0x70, 0xb5, 0x00, 0x26, 0x0c, 0x4d, 0x0d, 0x4c, + 0x64, 0x1b, 0xa4, 0x10, 0xa6, 0x42, 0x09, 0xd1, 0x00, 0x26, 0x00, 0xf0, + 0x51, 0xf9, 0x0a, 0x4d, 0x0a, 0x4c, 0x64, 0x1b, 0xa4, 0x10, 0xa6, 0x42, + 0x05, 0xd1, 0x70, 0xbd, 0xb3, 0x00, 0xeb, 0x58, 0x98, 0x47, 0x01, 0x36, + 0xee, 0xe7, 0xb3, 0x00, 0xeb, 0x58, 0x98, 0x47, 0x01, 0x36, 0xf2, 0xe7, + 0x90, 0x00, 0x00, 0x20, 0x90, 0x00, 0x00, 0x20, 0x90, 0x00, 0x00, 0x20, + 0xd0, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x03, 0x4b, 0x01, 0x00, 0x18, 0x68, + 0x00, 0xf0, 0x16, 0xf8, 0x10, 0xbd, 0xc0, 0x46, 0x2c, 0x00, 0x00, 0x20, + 0x00, 0x23, 0x10, 0xb5, 0x9a, 0x42, 0x00, 0xd1, 0x10, 0xbd, 0xcc, 0x5c, + 0xc4, 0x54, 0x01, 0x33, 0xf8, 0xe7, 0x03, 0x00, 0x12, 0x18, 0x93, 0x42, + 0x00, 0xd1, 0x70, 0x47, 0x19, 0x70, 0x01, 0x33, 0xf9, 0xe7, 0x00, 0x00, + 0x70, 0xb5, 0x05, 0x00, 0x00, 0x29, 0x10, 0xd0, 0x0c, 0x1f, 0x23, 0x68, + 0x00, 0x2b, 0x00, 0xda, 0xe4, 0x18, 0x28, 0x00, 0x00, 0xf0, 0xd1, 0xf8, + 0x1d, 0x4a, 0x13, 0x68, 0x00, 0x2b, 0x05, 0xd1, 0x63, 0x60, 0x14, 0x60, + 0x28, 0x00, 0x00, 0xf0, 0xc9, 0xf8, 0x70, 0xbd, 0xa3, 0x42, 0x09, 0xd9, + 0x21, 0x68, 0x60, 0x18, 0x83, 0x42, 0xf3, 0xd1, 0x18, 0x68, 0x5b, 0x68, + 0x41, 0x18, 0x21, 0x60, 0xee, 0xe7, 0x13, 0x00, 0x5a, 0x68, 0x00, 0x2a, + 0x01, 0xd0, 0xa2, 0x42, 0xf9, 0xd9, 0x19, 0x68, 0x58, 0x18, 0xa0, 0x42, + 0x0b, 0xd1, 0x20, 0x68, 0x09, 0x18, 0x58, 0x18, 0x19, 0x60, 0x82, 0x42, + 0xe0, 0xd1, 0x10, 0x68, 0x52, 0x68, 0x41, 0x18, 0x19, 0x60, 0x5a, 0x60, + 0xda, 0xe7, 0xa0, 0x42, 0x02, 0xd9, 0x0c, 0x23, 0x2b, 0x60, 0xd5, 0xe7, + 0x21, 0x68, 0x60, 0x18, 0x82, 0x42, 0x03, 0xd1, 0x10, 0x68, 0x52, 0x68, + 0x41, 0x18, 0x21, 0x60, 0x62, 0x60, 0x5c, 0x60, 0xca, 0xe7, 0xc0, 0x46, + 0xcc, 0x23, 0x00, 0x20, 0x03, 0x23, 0x70, 0xb5, 0xcd, 0x1c, 0x9d, 0x43, + 0x08, 0x35, 0x06, 0x00, 0x0c, 0x2d, 0x1e, 0xd2, 0x0c, 0x25, 0xa9, 0x42, + 0x1d, 0xd8, 0x30, 0x00, 0x00, 0xf0, 0x85, 0xf8, 0x25, 0x4a, 0x14, 0x68, + 0x21, 0x00, 0x00, 0x29, 0x19, 0xd1, 0x24, 0x4c, 0x23, 0x68, 0x00, 0x2b, + 0x03, 0xd1, 0x30, 0x00, 0x00, 0xf0, 0x4e, 0xf8, 0x20, 0x60, 0x29, 0x00, + 0x30, 0x00, 0x00, 0xf0, 0x49, 0xf8, 0x43, 0x1c, 0x2b, 0xd1, 0x0c, 0x23, + 0x30, 0x00, 0x33, 0x60, 0x00, 0xf0, 0x6e, 0xf8, 0x03, 0xe0, 0x00, 0x2d, + 0xdf, 0xda, 0x0c, 0x23, 0x33, 0x60, 0x00, 0x20, 0x70, 0xbd, 0x0b, 0x68, + 0x5b, 0x1b, 0x19, 0xd4, 0x0b, 0x2b, 0x03, 0xd9, 0x0b, 0x60, 0xcc, 0x18, + 0x25, 0x60, 0x03, 0xe0, 0x4b, 0x68, 0x8c, 0x42, 0x0d, 0xd1, 0x13, 0x60, + 0x30, 0x00, 0x00, 0xf0, 0x57, 0xf8, 0x20, 0x00, 0x07, 0x22, 0x0b, 0x30, + 0x23, 0x1d, 0x90, 0x43, 0xc3, 0x1a, 0xe7, 0xd0, 0x5a, 0x42, 0xe2, 0x50, + 0xe4, 0xe7, 0x63, 0x60, 0x0c, 0x00, 0xef, 0xe7, 0x0c, 0x00, 0x49, 0x68, + 0xc3, 0xe7, 0x03, 0x23, 0xc4, 0x1c, 0x9c, 0x43, 0xa0, 0x42, 0xe1, 0xd0, + 0x21, 0x1a, 0x30, 0x00, 0x00, 0xf0, 0x12, 0xf8, 0x43, 0x1c, 0xdb, 0xd1, + 0xc7, 0xe7, 0xc0, 0x46, 0xcc, 0x23, 0x00, 0x20, 0xd0, 0x23, 0x00, 0x20, + 0x10, 0xb5, 0x03, 0x4b, 0x0a, 0x00, 0x01, 0x00, 0x18, 0x68, 0x00, 0xf0, + 0x30, 0xf8, 0x10, 0xbd, 0x2c, 0x00, 0x00, 0x20, 0x00, 0x23, 0x70, 0xb5, + 0x06, 0x4c, 0x05, 0x00, 0x08, 0x00, 0x23, 0x60, 0x00, 0xf0, 0x54, 0xf8, + 0x43, 0x1c, 0x03, 0xd1, 0x23, 0x68, 0x00, 0x2b, 0x00, 0xd0, 0x2b, 0x60, + 0x70, 0xbd, 0xc0, 0x46, 0xd8, 0x23, 0x00, 0x20, 0x02, 0x78, 0x0b, 0x78, + 0x00, 0x2a, 0x03, 0xd0, 0x01, 0x30, 0x01, 0x31, 0x9a, 0x42, 0xf7, 0xd0, + 0xd0, 0x1a, 0x70, 0x47, 0x03, 0x00, 0x0a, 0x78, 0x01, 0x31, 0x1a, 0x70, + 0x01, 0x33, 0x00, 0x2a, 0xf9, 0xd1, 0x70, 0x47, 0x00, 0x23, 0xc2, 0x5c, + 0x01, 0x33, 0x00, 0x2a, 0xfb, 0xd1, 0x58, 0x1e, 0x70, 0x47, 0x70, 0x47, + 0x70, 0x47, 0xf8, 0xb5, 0x07, 0x00, 0x0d, 0x00, 0x16, 0x00, 0x00, 0x29, + 0x05, 0xd1, 0x11, 0x00, 0xff, 0xf7, 0x62, 0xff, 0x04, 0x00, 0x20, 0x00, + 0xf8, 0xbd, 0x00, 0x2a, 0x03, 0xd1, 0xff, 0xf7, 0x11, 0xff, 0x34, 0x00, + 0xf7, 0xe7, 0x00, 0xf0, 0x12, 0xf8, 0x2c, 0x00, 0xb0, 0x42, 0xf2, 0xd2, + 0x31, 0x00, 0x38, 0x00, 0xff, 0xf7, 0x50, 0xff, 0x04, 0x1e, 0xec, 0xd0, + 0x29, 0x00, 0x32, 0x00, 0xff, 0xf7, 0xee, 0xfe, 0x29, 0x00, 0x38, 0x00, + 0xff, 0xf7, 0xfc, 0xfe, 0xe3, 0xe7, 0x0b, 0x1f, 0x1b, 0x68, 0x18, 0x1f, + 0x00, 0x2b, 0x01, 0xda, 0x0b, 0x58, 0xc0, 0x18, 0x70, 0x47, 0x00, 0x00, + 0x04, 0x4a, 0x13, 0x68, 0x00, 0x2b, 0x00, 0xd1, 0x03, 0x4b, 0x18, 0x18, + 0x10, 0x60, 0x18, 0x00, 0x70, 0x47, 0xc0, 0x46, 0xd4, 0x23, 0x00, 0x20, + 0xdc, 0x23, 0x00, 0x20, 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, + 0x9e, 0x46, 0x70, 0x47, 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, + 0x9e, 0x46, 0x70, 0x47, 0x00, 0x00, 0x00, 0x00, 0x96, 0x30, 0x07, 0x77, + 0x2c, 0x61, 0x0e, 0xee, 0xba, 0x51, 0x09, 0x99, 0x19, 0xc4, 0x6d, 0x07, + 0x8f, 0xf4, 0x6a, 0x70, 0x35, 0xa5, 0x63, 0xe9, 0xa3, 0x95, 0x64, 0x9e, + 0x32, 0x88, 0xdb, 0x0e, 0xa4, 0xb8, 0xdc, 0x79, 0x1e, 0xe9, 0xd5, 0xe0, + 0x88, 0xd9, 0xd2, 0x97, 0x2b, 0x4c, 0xb6, 0x09, 0xbd, 0x7c, 0xb1, 0x7e, + 0x07, 0x2d, 0xb8, 0xe7, 0x91, 0x1d, 0xbf, 0x90, 0x64, 0x10, 0xb7, 0x1d, + 0xf2, 0x20, 0xb0, 0x6a, 0x48, 0x71, 0xb9, 0xf3, 0xde, 0x41, 0xbe, 0x84, + 0x7d, 0xd4, 0xda, 0x1a, 0xeb, 0xe4, 0xdd, 0x6d, 0x51, 0xb5, 0xd4, 0xf4, + 0xc7, 0x85, 0xd3, 0x83, 0x56, 0x98, 0x6c, 0x13, 0xc0, 0xa8, 0x6b, 0x64, + 0x7a, 0xf9, 0x62, 0xfd, 0xec, 0xc9, 0x65, 0x8a, 0x4f, 0x5c, 0x01, 0x14, + 0xd9, 0x6c, 0x06, 0x63, 0x63, 0x3d, 0x0f, 0xfa, 0xf5, 0x0d, 0x08, 0x8d, + 0xc8, 0x20, 0x6e, 0x3b, 0x5e, 0x10, 0x69, 0x4c, 0xe4, 0x41, 0x60, 0xd5, + 0x72, 0x71, 0x67, 0xa2, 0xd1, 0xe4, 0x03, 0x3c, 0x47, 0xd4, 0x04, 0x4b, + 0xfd, 0x85, 0x0d, 0xd2, 0x6b, 0xb5, 0x0a, 0xa5, 0xfa, 0xa8, 0xb5, 0x35, + 0x6c, 0x98, 0xb2, 0x42, 0xd6, 0xc9, 0xbb, 0xdb, 0x40, 0xf9, 0xbc, 0xac, + 0xe3, 0x6c, 0xd8, 0x32, 0x75, 0x5c, 0xdf, 0x45, 0xcf, 0x0d, 0xd6, 0xdc, + 0x59, 0x3d, 0xd1, 0xab, 0xac, 0x30, 0xd9, 0x26, 0x3a, 0x00, 0xde, 0x51, + 0x80, 0x51, 0xd7, 0xc8, 0x16, 0x61, 0xd0, 0xbf, 0xb5, 0xf4, 0xb4, 0x21, + 0x23, 0xc4, 0xb3, 0x56, 0x99, 0x95, 0xba, 0xcf, 0x0f, 0xa5, 0xbd, 0xb8, + 0x9e, 0xb8, 0x02, 0x28, 0x08, 0x88, 0x05, 0x5f, 0xb2, 0xd9, 0x0c, 0xc6, + 0x24, 0xe9, 0x0b, 0xb1, 0x87, 0x7c, 0x6f, 0x2f, 0x11, 0x4c, 0x68, 0x58, + 0xab, 0x1d, 0x61, 0xc1, 0x3d, 0x2d, 0x66, 0xb6, 0x90, 0x41, 0xdc, 0x76, + 0x06, 0x71, 0xdb, 0x01, 0xbc, 0x20, 0xd2, 0x98, 0x2a, 0x10, 0xd5, 0xef, + 0x89, 0x85, 0xb1, 0x71, 0x1f, 0xb5, 0xb6, 0x06, 0xa5, 0xe4, 0xbf, 0x9f, + 0x33, 0xd4, 0xb8, 0xe8, 0xa2, 0xc9, 0x07, 0x78, 0x34, 0xf9, 0x00, 0x0f, + 0x8e, 0xa8, 0x09, 0x96, 0x18, 0x98, 0x0e, 0xe1, 0xbb, 0x0d, 0x6a, 0x7f, + 0x2d, 0x3d, 0x6d, 0x08, 0x97, 0x6c, 0x64, 0x91, 0x01, 0x5c, 0x63, 0xe6, + 0xf4, 0x51, 0x6b, 0x6b, 0x62, 0x61, 0x6c, 0x1c, 0xd8, 0x30, 0x65, 0x85, + 0x4e, 0x00, 0x62, 0xf2, 0xed, 0x95, 0x06, 0x6c, 0x7b, 0xa5, 0x01, 0x1b, + 0xc1, 0xf4, 0x08, 0x82, 0x57, 0xc4, 0x0f, 0xf5, 0xc6, 0xd9, 0xb0, 0x65, + 0x50, 0xe9, 0xb7, 0x12, 0xea, 0xb8, 0xbe, 0x8b, 0x7c, 0x88, 0xb9, 0xfc, + 0xdf, 0x1d, 0xdd, 0x62, 0x49, 0x2d, 0xda, 0x15, 0xf3, 0x7c, 0xd3, 0x8c, + 0x65, 0x4c, 0xd4, 0xfb, 0x58, 0x61, 0xb2, 0x4d, 0xce, 0x51, 0xb5, 0x3a, + 0x74, 0x00, 0xbc, 0xa3, 0xe2, 0x30, 0xbb, 0xd4, 0x41, 0xa5, 0xdf, 0x4a, + 0xd7, 0x95, 0xd8, 0x3d, 0x6d, 0xc4, 0xd1, 0xa4, 0xfb, 0xf4, 0xd6, 0xd3, + 0x6a, 0xe9, 0x69, 0x43, 0xfc, 0xd9, 0x6e, 0x34, 0x46, 0x88, 0x67, 0xad, + 0xd0, 0xb8, 0x60, 0xda, 0x73, 0x2d, 0x04, 0x44, 0xe5, 0x1d, 0x03, 0x33, + 0x5f, 0x4c, 0x0a, 0xaa, 0xc9, 0x7c, 0x0d, 0xdd, 0x3c, 0x71, 0x05, 0x50, + 0xaa, 0x41, 0x02, 0x27, 0x10, 0x10, 0x0b, 0xbe, 0x86, 0x20, 0x0c, 0xc9, + 0x25, 0xb5, 0x68, 0x57, 0xb3, 0x85, 0x6f, 0x20, 0x09, 0xd4, 0x66, 0xb9, + 0x9f, 0xe4, 0x61, 0xce, 0x0e, 0xf9, 0xde, 0x5e, 0x98, 0xc9, 0xd9, 0x29, + 0x22, 0x98, 0xd0, 0xb0, 0xb4, 0xa8, 0xd7, 0xc7, 0x17, 0x3d, 0xb3, 0x59, + 0x81, 0x0d, 0xb4, 0x2e, 0x3b, 0x5c, 0xbd, 0xb7, 0xad, 0x6c, 0xba, 0xc0, + 0x20, 0x83, 0xb8, 0xed, 0xb6, 0xb3, 0xbf, 0x9a, 0x0c, 0xe2, 0xb6, 0x03, + 0x9a, 0xd2, 0xb1, 0x74, 0x39, 0x47, 0xd5, 0xea, 0xaf, 0x77, 0xd2, 0x9d, + 0x15, 0x26, 0xdb, 0x04, 0x83, 0x16, 0xdc, 0x73, 0x12, 0x0b, 0x63, 0xe3, + 0x84, 0x3b, 0x64, 0x94, 0x3e, 0x6a, 0x6d, 0x0d, 0xa8, 0x5a, 0x6a, 0x7a, + 0x0b, 0xcf, 0x0e, 0xe4, 0x9d, 0xff, 0x09, 0x93, 0x27, 0xae, 0x00, 0x0a, + 0xb1, 0x9e, 0x07, 0x7d, 0x44, 0x93, 0x0f, 0xf0, 0xd2, 0xa3, 0x08, 0x87, + 0x68, 0xf2, 0x01, 0x1e, 0xfe, 0xc2, 0x06, 0x69, 0x5d, 0x57, 0x62, 0xf7, + 0xcb, 0x67, 0x65, 0x80, 0x71, 0x36, 0x6c, 0x19, 0xe7, 0x06, 0x6b, 0x6e, + 0x76, 0x1b, 0xd4, 0xfe, 0xe0, 0x2b, 0xd3, 0x89, 0x5a, 0x7a, 0xda, 0x10, + 0xcc, 0x4a, 0xdd, 0x67, 0x6f, 0xdf, 0xb9, 0xf9, 0xf9, 0xef, 0xbe, 0x8e, + 0x43, 0xbe, 0xb7, 0x17, 0xd5, 0x8e, 0xb0, 0x60, 0xe8, 0xa3, 0xd6, 0xd6, + 0x7e, 0x93, 0xd1, 0xa1, 0xc4, 0xc2, 0xd8, 0x38, 0x52, 0xf2, 0xdf, 0x4f, + 0xf1, 0x67, 0xbb, 0xd1, 0x67, 0x57, 0xbc, 0xa6, 0xdd, 0x06, 0xb5, 0x3f, + 0x4b, 0x36, 0xb2, 0x48, 0xda, 0x2b, 0x0d, 0xd8, 0x4c, 0x1b, 0x0a, 0xaf, + 0xf6, 0x4a, 0x03, 0x36, 0x60, 0x7a, 0x04, 0x41, 0xc3, 0xef, 0x60, 0xdf, + 0x55, 0xdf, 0x67, 0xa8, 0xef, 0x8e, 0x6e, 0x31, 0x79, 0xbe, 0x69, 0x46, + 0x8c, 0xb3, 0x61, 0xcb, 0x1a, 0x83, 0x66, 0xbc, 0xa0, 0xd2, 0x6f, 0x25, + 0x36, 0xe2, 0x68, 0x52, 0x95, 0x77, 0x0c, 0xcc, 0x03, 0x47, 0x0b, 0xbb, + 0xb9, 0x16, 0x02, 0x22, 0x2f, 0x26, 0x05, 0x55, 0xbe, 0x3b, 0xba, 0xc5, + 0x28, 0x0b, 0xbd, 0xb2, 0x92, 0x5a, 0xb4, 0x2b, 0x04, 0x6a, 0xb3, 0x5c, + 0xa7, 0xff, 0xd7, 0xc2, 0x31, 0xcf, 0xd0, 0xb5, 0x8b, 0x9e, 0xd9, 0x2c, + 0x1d, 0xae, 0xde, 0x5b, 0xb0, 0xc2, 0x64, 0x9b, 0x26, 0xf2, 0x63, 0xec, + 0x9c, 0xa3, 0x6a, 0x75, 0x0a, 0x93, 0x6d, 0x02, 0xa9, 0x06, 0x09, 0x9c, + 0x3f, 0x36, 0x0e, 0xeb, 0x85, 0x67, 0x07, 0x72, 0x13, 0x57, 0x00, 0x05, + 0x82, 0x4a, 0xbf, 0x95, 0x14, 0x7a, 0xb8, 0xe2, 0xae, 0x2b, 0xb1, 0x7b, + 0x38, 0x1b, 0xb6, 0x0c, 0x9b, 0x8e, 0xd2, 0x92, 0x0d, 0xbe, 0xd5, 0xe5, + 0xb7, 0xef, 0xdc, 0x7c, 0x21, 0xdf, 0xdb, 0x0b, 0xd4, 0xd2, 0xd3, 0x86, + 0x42, 0xe2, 0xd4, 0xf1, 0xf8, 0xb3, 0xdd, 0x68, 0x6e, 0x83, 0xda, 0x1f, + 0xcd, 0x16, 0xbe, 0x81, 0x5b, 0x26, 0xb9, 0xf6, 0xe1, 0x77, 0xb0, 0x6f, + 0x77, 0x47, 0xb7, 0x18, 0xe6, 0x5a, 0x08, 0x88, 0x70, 0x6a, 0x0f, 0xff, + 0xca, 0x3b, 0x06, 0x66, 0x5c, 0x0b, 0x01, 0x11, 0xff, 0x9e, 0x65, 0x8f, + 0x69, 0xae, 0x62, 0xf8, 0xd3, 0xff, 0x6b, 0x61, 0x45, 0xcf, 0x6c, 0x16, + 0x78, 0xe2, 0x0a, 0xa0, 0xee, 0xd2, 0x0d, 0xd7, 0x54, 0x83, 0x04, 0x4e, + 0xc2, 0xb3, 0x03, 0x39, 0x61, 0x26, 0x67, 0xa7, 0xf7, 0x16, 0x60, 0xd0, + 0x4d, 0x47, 0x69, 0x49, 0xdb, 0x77, 0x6e, 0x3e, 0x4a, 0x6a, 0xd1, 0xae, + 0xdc, 0x5a, 0xd6, 0xd9, 0x66, 0x0b, 0xdf, 0x40, 0xf0, 0x3b, 0xd8, 0x37, + 0x53, 0xae, 0xbc, 0xa9, 0xc5, 0x9e, 0xbb, 0xde, 0x7f, 0xcf, 0xb2, 0x47, + 0xe9, 0xff, 0xb5, 0x30, 0x1c, 0xf2, 0xbd, 0xbd, 0x8a, 0xc2, 0xba, 0xca, + 0x30, 0x93, 0xb3, 0x53, 0xa6, 0xa3, 0xb4, 0x24, 0x05, 0x36, 0xd0, 0xba, + 0x93, 0x06, 0xd7, 0xcd, 0x29, 0x57, 0xde, 0x54, 0xbf, 0x67, 0xd9, 0x23, + 0x2e, 0x7a, 0x66, 0xb3, 0xb8, 0x4a, 0x61, 0xc4, 0x02, 0x1b, 0x68, 0x5d, + 0x94, 0x2b, 0x6f, 0x2a, 0x37, 0xbe, 0x0b, 0xb4, 0xa1, 0x8e, 0x0c, 0xc3, + 0x1b, 0xdf, 0x05, 0x5a, 0x8d, 0xef, 0x02, 0x2d, 0x31, 0x2e, 0x34, 0x2e, + 0x31, 0x00, 0x2f, 0x66, 0x73, 0x2f, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, + 0x2e, 0x42, 0x49, 0x4e, 0x2e, 0x4c, 0x5a, 0x53, 0x53, 0x00, 0x2f, 0x66, + 0x73, 0x2f, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x2e, 0x42, 0x49, 0x4e, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, + 0x40, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x17, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x16, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x0a, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x00, 0x05, 0x00, 0x05, 0x0a, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x0b, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x01, 0x05, 0x01, 0x05, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x07, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x07, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x05, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x05, 0x00, 0x01, 0x00, 0x01, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x06, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x12, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x14, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x02, 0x00, 0x02, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x15, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x03, 0x00, 0x03, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x00, 0x02, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x13, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x01, 0x03, 0x01, 0x03, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x11, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x0a, 0x00, 0xff, 0xff, 0xff, 0xff, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0b, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x13, 0x00, 0x01, 0x01, 0x01, 0x01, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0a, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x12, 0x00, 0x00, 0x01, 0x00, 0x01, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x02, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x09, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x01, 0x04, 0x01, 0x04, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x09, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x11, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x0b, 0x00, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0c, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0d, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0e, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0f, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x1b, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x1c, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x16, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x00, 0x04, 0x00, 0x04, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x17, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0xff, 0x00, 0x01, 0x04, 0x01, 0x04, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x18, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x19, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x55, 0x35, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x97, 0x3a, 0x00, 0x00, 0xcd, 0x3c, 0x00, 0x00, + 0x93, 0x3a, 0x00, 0x00, 0xb1, 0x3c, 0x00, 0x00, 0x91, 0x3c, 0x00, 0x00, + 0x09, 0x3d, 0x00, 0x00, 0xed, 0x3c, 0x00, 0x00, 0xbf, 0x3c, 0x00, 0x00, + 0xad, 0x3a, 0x00, 0x00, 0x13, 0x3a, 0x00, 0x00, 0xd9, 0x3b, 0x00, 0x00, + 0x3d, 0x3a, 0x00, 0x00, 0x91, 0x3a, 0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, + 0x00, 0x00, 0x00, 0x00, 0x81, 0x3c, 0x00, 0x00, 0xc9, 0x3b, 0x00, 0x00, + 0x2f, 0x3d, 0x00, 0x00, 0x2d, 0x3d, 0x00, 0x00, 0x81, 0x3a, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xad, 0x45, 0x00, 0x00, + 0xb5, 0x35, 0x00, 0x00, 0xd3, 0x44, 0x00, 0x00, 0x8f, 0x44, 0x00, 0x00, + 0xa9, 0x44, 0x00, 0x00, 0x61, 0x46, 0x00, 0x00, 0xe9, 0x41, 0x00, 0x00, + 0xd9, 0x41, 0x00, 0x00, 0x6d, 0x42, 0x00, 0x00, 0x03, 0x42, 0x00, 0x00, + 0xd5, 0x41, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x16, 0x50, 0x00, 0x00, 0x02, 0x50, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, + 0x07, 0x05, 0x0a, 0x00, 0x40, 0x42, 0x0f, 0x00, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x00, 0xc2, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, + 0xff, 0xff, 0xff, 0xff, 0x30, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xf0, 0x59, 0x00, 0x00, 0x10, 0x5a, 0x00, 0x00, 0xd0, 0x59, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xdd, 0x20, 0x00, 0x00, + 0x25, 0x24, 0x00, 0x00, 0x45, 0x26, 0x00, 0x00, 0x6d, 0x26, 0x00, 0x00, + 0x91, 0x26, 0x00, 0x00, 0xa9, 0x26, 0x00, 0x00, 0xc1, 0x26, 0x00, 0x00, + 0x21, 0x27, 0x00, 0x00, 0x39, 0x27, 0x00, 0x00, 0x95, 0x27, 0x00, 0x00, + 0xa9, 0x2b, 0x00, 0x00, 0xc1, 0x2b, 0x00, 0x00, 0xfd, 0x2d, 0x00, 0x00, + 0x99, 0x2e, 0x00, 0x00, 0x85, 0x3d, 0x00, 0x00, 0xc5, 0x41, 0x00, 0x00, + 0xb5, 0x20, 0x00, 0x00 diff --git a/libraries/SPI/SPI.cpp b/libraries/SPI/SPI.cpp new file mode 100644 index 0000000..43a14f9 --- /dev/null +++ b/libraries/SPI/SPI.cpp @@ -0,0 +1,307 @@ +/* + * SPI Master library for Arduino Zero. + * Copyright (c) 2015 Arduino LLC + * + * 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 + */ + +#include "SPI.h" +#include +#include +#include + +#define SPI_IMODE_NONE 0 +#define SPI_IMODE_EXTINT 1 +#define SPI_IMODE_GLOBAL 2 + +//const SPISettings DEFAULT_SPI_SETTINGS = SPISettings(); + +static inline SercomDataOrder getBitOrder(SPISettings& settings) { + return (settings.getBitOrder() == MSBFIRST ? MSB_FIRST : LSB_FIRST); +} + +static inline SercomSpiClockMode getDataMode(SPISettings& settings) { + switch (settings.getDataMode()) + { + case SPI_MODE0: + return SERCOM_SPI_MODE_0; break; + case SPI_MODE1: + return SERCOM_SPI_MODE_1; break; + case SPI_MODE2: + return SERCOM_SPI_MODE_2; break; + case SPI_MODE3: + return SERCOM_SPI_MODE_3; break; + default: + return SERCOM_SPI_MODE_0; break; + } +} + +SPIClassSAMD::SPIClassSAMD(SERCOM *p_sercom, uint8_t uc_pinMISO, uint8_t uc_pinSCK, uint8_t uc_pinMOSI, SercomSpiTXPad PadTx, SercomRXPad PadRx) +: settings(0, MSBFIRST, SPI_MODE0) +{ + initialized = false; + assert(p_sercom != NULL); + _p_sercom = p_sercom; + + // pins + _uc_pinMiso = uc_pinMISO; + _uc_pinSCK = uc_pinSCK; + _uc_pinMosi = uc_pinMOSI; + + // SERCOM pads + _padTx=PadTx; + _padRx=PadRx; +} + +void SPIClassSAMD::begin() +{ + init(); + + // PIO init + pinPeripheral(_uc_pinMiso, g_APinDescription[_uc_pinMiso].ulPinType); + pinPeripheral(_uc_pinSCK, g_APinDescription[_uc_pinSCK].ulPinType); + pinPeripheral(_uc_pinMosi, g_APinDescription[_uc_pinMosi].ulPinType); + + config(DEFAULT_SPI_SETTINGS); +} + +void SPIClassSAMD::init() +{ + if (initialized) + return; + interruptMode = SPI_IMODE_NONE; + interruptSave = 0; + interruptMask = 0; + initialized = true; +} + +void SPIClassSAMD::config(SPISettings settings) +{ + if (this->settings != settings) { + this->settings = settings; + _p_sercom->disableSPI(); + + uint32_t clock_freq = settings.getClockFreq(); + if (clock_freq > SERCOM_FREQ_REF/SPI_MIN_CLOCK_DIVIDER) { + clock_freq = SERCOM_FREQ_REF/SPI_MIN_CLOCK_DIVIDER; + } + + _p_sercom->initSPI(_padTx, _padRx, SPI_CHAR_SIZE_8_BITS, getBitOrder(settings)); + _p_sercom->initSPIClock(getDataMode(settings), clock_freq); + + _p_sercom->enableSPI(); + } +} + +void SPIClassSAMD::end() +{ + _p_sercom->resetSPI(); + initialized = false; +} + +#ifndef interruptsStatus +#define interruptsStatus() __interruptsStatus() +static inline unsigned char __interruptsStatus(void) __attribute__((always_inline, unused)); +static inline unsigned char __interruptsStatus(void) +{ + // See http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0497a/CHDBIBGJ.html + return (__get_PRIMASK() ? 0 : 1); +} +#endif + +void SPIClassSAMD::usingInterrupt(int interruptNumber) +{ + if ((interruptNumber == NOT_AN_INTERRUPT) || (interruptNumber == EXTERNAL_INT_NMI)) + return; + + uint8_t irestore = interruptsStatus(); + noInterrupts(); + + if (interruptNumber >= EXTERNAL_NUM_INTERRUPTS) + interruptMode = SPI_IMODE_GLOBAL; + else + { + interruptMode |= SPI_IMODE_EXTINT; + interruptMask |= (1 << g_APinDescription[interruptNumber].ulExtInt); + } + + if (irestore) + interrupts(); +} + +void SPIClassSAMD::notUsingInterrupt(int interruptNumber) +{ + if ((interruptNumber == NOT_AN_INTERRUPT) || (interruptNumber == EXTERNAL_INT_NMI)) + return; + + if (interruptMode & SPI_IMODE_GLOBAL) + return; // can't go back, as there is no reference count + + uint8_t irestore = interruptsStatus(); + noInterrupts(); + + interruptMask &= ~(1 << g_APinDescription[interruptNumber].ulExtInt); + + if (interruptMask == 0) + interruptMode = SPI_IMODE_NONE; + + if (irestore) + interrupts(); +} + +void SPIClassSAMD::beginTransaction(SPISettings settings) +{ + if (interruptMode != SPI_IMODE_NONE) + { + if (interruptMode & SPI_IMODE_GLOBAL) + { + interruptSave = interruptsStatus(); + noInterrupts(); + } + else if (interruptMode & SPI_IMODE_EXTINT) + EIC->INTENCLR.reg = EIC_INTENCLR_EXTINT(interruptMask); + } + + config(settings); +} + +void SPIClassSAMD::endTransaction(void) +{ + if (interruptMode != SPI_IMODE_NONE) + { + if (interruptMode & SPI_IMODE_GLOBAL) + { + if (interruptSave) + interrupts(); + } + else if (interruptMode & SPI_IMODE_EXTINT) + EIC->INTENSET.reg = EIC_INTENSET_EXTINT(interruptMask); + } +} + +void SPIClassSAMD::setBitOrder(BitOrder order) +{ + if (order == LSBFIRST) { + _p_sercom->setDataOrderSPI(LSB_FIRST); + } else { + _p_sercom->setDataOrderSPI(MSB_FIRST); + } +} + +void SPIClassSAMD::setDataMode(uint8_t mode) +{ + switch (mode) + { + case SPI_MODE0: + _p_sercom->setClockModeSPI(SERCOM_SPI_MODE_0); + break; + + case SPI_MODE1: + _p_sercom->setClockModeSPI(SERCOM_SPI_MODE_1); + break; + + case SPI_MODE2: + _p_sercom->setClockModeSPI(SERCOM_SPI_MODE_2); + break; + + case SPI_MODE3: + _p_sercom->setClockModeSPI(SERCOM_SPI_MODE_3); + break; + + default: + break; + } +} + +void SPIClassSAMD::setClockDivider(uint8_t div) +{ + if (div < SPI_MIN_CLOCK_DIVIDER) { + _p_sercom->setBaudrateSPI(SPI_MIN_CLOCK_DIVIDER); + } else { + _p_sercom->setBaudrateSPI(div); + } +} + +byte SPIClassSAMD::transfer(uint8_t data) +{ + return _p_sercom->transferDataSPI(data); +} + +uint16_t SPIClassSAMD::transfer16(uint16_t data) { + union { uint16_t val; struct { uint8_t lsb; uint8_t msb; }; } t; + + t.val = data; + + if (_p_sercom->getDataOrderSPI() == LSB_FIRST) { + t.lsb = transfer(t.lsb); + t.msb = transfer(t.msb); + } else { + t.msb = transfer(t.msb); + t.lsb = transfer(t.lsb); + } + + return t.val; +} + +void SPIClassSAMD::transfer(void *buf, size_t count) +{ + uint8_t *buffer = reinterpret_cast(buf); + for (size_t i=0; i 0 + /* In case new variant doesn't define these macros, + * we put here the ones for Arduino Zero. + * + * These values should be different on some variants! + * + * The SPI PAD values can be found in cores/arduino/SERCOM.h: + * - SercomSpiTXPad + * - SercomRXPad + */ + #ifndef PERIPH_SPI + #define PERIPH_SPI sercom4 + #define PAD_SPI_TX SPI_PAD_2_SCK_3 + #define PAD_SPI_RX SERCOM_RX_PAD_0 + #endif // PERIPH_SPI + SPIClassSAMD SPI (&PERIPH_SPI, PIN_SPI_MISO, PIN_SPI_SCK, PIN_SPI_MOSI, PAD_SPI_TX, PAD_SPI_RX); +#endif +#if SPI_INTERFACES_COUNT > 1 + SPIClassSAMD SPI1(&PERIPH_SPI1, PIN_SPI1_MISO, PIN_SPI1_SCK, PIN_SPI1_MOSI, PAD_SPI1_TX, PAD_SPI1_RX); +#endif +#if SPI_INTERFACES_COUNT > 2 + SPIClassSAMD SPI2(&PERIPH_SPI2, PIN_SPI2_MISO, PIN_SPI2_SCK, PIN_SPI2_MOSI, PAD_SPI2_TX, PAD_SPI2_RX); +#endif +#if SPI_INTERFACES_COUNT > 3 + SPIClassSAMD SPI3(&PERIPH_SPI3, PIN_SPI3_MISO, PIN_SPI3_SCK, PIN_SPI3_MOSI, PAD_SPI3_TX, PAD_SPI3_RX); +#endif +#if SPI_INTERFACES_COUNT > 4 + SPIClassSAMD SPI4(&PERIPH_SPI4, PIN_SPI4_MISO, PIN_SPI4_SCK, PIN_SPI4_MOSI, PAD_SPI4_TX, PAD_SPI4_RX); +#endif +#if SPI_INTERFACES_COUNT > 5 + SPIClassSAMD SPI5(&PERIPH_SPI5, PIN_SPI5_MISO, PIN_SPI5_SCK, PIN_SPI5_MOSI, PAD_SPI5_TX, PAD_SPI5_RX); +#endif + diff --git a/libraries/SPI/SPI.h b/libraries/SPI/SPI.h new file mode 100644 index 0000000..b1184e4 --- /dev/null +++ b/libraries/SPI/SPI.h @@ -0,0 +1,123 @@ +/* + * SPI Master library for Arduino Zero. + * Copyright (c) 2015 Arduino LLC + * + * 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 _SPI_H_INCLUDED +#define _SPI_H_INCLUDED + +#include +#include + +// SPI_HAS_TRANSACTION means SPI has +// - beginTransaction() +// - endTransaction() +// - usingInterrupt() +// - SPISetting(clock, bitOrder, dataMode) +// #define SPI_HAS_TRANSACTION 1 +// Every core implementing arduino API has SPI transaction + +// SPI_HAS_NOTUSINGINTERRUPT means that SPI has notUsingInterrupt() method +#define SPI_HAS_NOTUSINGINTERRUPT 1 + +#if defined(ARDUINO_ARCH_SAMD) + // The datasheet specifies a typical SPI SCK period (tSCK) of 42 ns, + // see "Table 36-48. SPI Timing Characteristics and Requirements", + // which translates into a maximum SPI clock of 23.8 MHz. + // Conservatively, the divider is set for a 12 MHz maximum SPI clock. + #define SPI_MIN_CLOCK_DIVIDER (uint8_t)(1 + ((F_CPU - 1) / 12000000)) +#endif + +class SPIClassSAMD : public arduino::HardwareSPI { + public: + SPIClassSAMD(SERCOM *p_sercom, uint8_t uc_pinMISO, uint8_t uc_pinSCK, uint8_t uc_pinMOSI, SercomSpiTXPad, SercomRXPad); + + byte transfer(uint8_t data); + uint16_t transfer16(uint16_t data); + void transfer(void *buf, size_t count); + + // Transaction Functions + void usingInterrupt(int interruptNumber); + void notUsingInterrupt(int interruptNumber); + void beginTransaction(SPISettings settings); + void endTransaction(void); + + // SPI Configuration methods + void attachInterrupt(); + void detachInterrupt(); + + void begin(); + void end(); + + void setBitOrder(BitOrder order); + void setDataMode(uint8_t uc_mode); + void setClockDivider(uint8_t uc_div); + + private: + void init(); + void config(SPISettings settings); + + SERCOM *_p_sercom; + uint8_t _uc_pinMiso; + uint8_t _uc_pinMosi; + uint8_t _uc_pinSCK; + + SercomSpiTXPad _padTx; + SercomRXPad _padRx; + + SPISettings settings; + + bool initialized; + uint8_t interruptMode; + char interruptSave; + uint32_t interruptMask; +}; + +//#define SPIClass SPIClassSAMD + +#if SPI_INTERFACES_COUNT > 0 + extern SPIClassSAMD SPI; +#endif +#if SPI_INTERFACES_COUNT > 1 + extern SPIClassSAMD SPI1; +#endif +#if SPI_INTERFACES_COUNT > 2 + extern SPIClassSAMD SPI2; +#endif +#if SPI_INTERFACES_COUNT > 3 + extern SPIClassSAMD SPI3; +#endif +#if SPI_INTERFACES_COUNT > 4 + extern SPIClassSAMD SPI4; +#endif +#if SPI_INTERFACES_COUNT > 5 + extern SPIClassSAMD SPI5; +#endif + +// For compatibility with sketches designed for AVR @ 16 MHz +// New programs should use SPI.beginTransaction to set the SPI clock +#if F_CPU == 48000000 + #define SPI_CLOCK_DIV2 6 + #define SPI_CLOCK_DIV4 12 + #define SPI_CLOCK_DIV8 24 + #define SPI_CLOCK_DIV16 48 + #define SPI_CLOCK_DIV32 96 + #define SPI_CLOCK_DIV64 192 + #define SPI_CLOCK_DIV128 255 +#endif + +#endif diff --git a/libraries/SPI/examples/BarometricPressureSensor/BarometricPressureSensor.ino b/libraries/SPI/examples/BarometricPressureSensor/BarometricPressureSensor.ino new file mode 100644 index 0000000..8104fcb --- /dev/null +++ b/libraries/SPI/examples/BarometricPressureSensor/BarometricPressureSensor.ino @@ -0,0 +1,143 @@ +/* + SCP1000 Barometric Pressure Sensor Display + + Shows the output of a Barometric Pressure Sensor on a + Uses the SPI library. For details on the sensor, see: + http://www.sparkfun.com/commerce/product_info.php?products_id=8161 + http://www.vti.fi/en/support/obsolete_products/pressure_sensors/ + + This sketch adapted from Nathan Seidle's SCP1000 example for PIC: + http://www.sparkfun.com/datasheets/Sensors/SCP1000-Testing.zip + + Circuit: + SCP1000 sensor attached to pins 6, 7, 10 - 13: + DRDY: pin 6 + CSB: pin 7 + MOSI: pin 11 + MISO: pin 12 + SCK: pin 13 + + created 31 July 2010 + modified 14 August 2010 + by Tom Igoe + */ + +// the sensor communicates using SPI, so include the library: +#include + +//Sensor's memory register addresses: +const int PRESSURE = 0x1F; //3 most significant bits of pressure +const int PRESSURE_LSB = 0x20; //16 least significant bits of pressure +const int TEMPERATURE = 0x21; //16 bit temperature reading +const byte READ = 0b11111100; // SCP1000's read command +const byte WRITE = 0b00000010; // SCP1000's write command + +// pins used for the connection with the sensor +// the other you need are controlled by the SPI library): +const int dataReadyPin = 6; +const int chipSelectPin = 7; + +void setup() { + Serial.begin(9600); + + // start the SPI library: + SPI.begin(); + + // initalize the data ready and chip select pins: + pinMode(dataReadyPin, INPUT); + pinMode(chipSelectPin, OUTPUT); + + //Configure SCP1000 for low noise configuration: + writeRegister(0x02, 0x2D); + writeRegister(0x01, 0x03); + writeRegister(0x03, 0x02); + // give the sensor time to set up: + delay(100); +} + +void loop() { + //Select High Resolution Mode + writeRegister(0x03, 0x0A); + + // don't do anything until the data ready pin is high: + if (digitalRead(dataReadyPin) == HIGH) { + //Read the temperature data + int tempData = readRegister(0x21, 2); + + // convert the temperature to celsius and display it: + float realTemp = (float)tempData / 20.0; + Serial.print("Temp[C]="); + Serial.print(realTemp); + + + //Read the pressure data highest 3 bits: + byte pressure_data_high = readRegister(0x1F, 1); + pressure_data_high &= 0b00000111; //you only needs bits 2 to 0 + + //Read the pressure data lower 16 bits: + unsigned int pressure_data_low = readRegister(0x20, 2); + //combine the two parts into one 19-bit number: + long pressure = ((pressure_data_high << 16) | pressure_data_low) / 4; + + // display the temperature: + Serial.println("\tPressure [Pa]=" + String(pressure)); + } +} + +//Read from or write to register from the SCP1000: +unsigned int readRegister(byte thisRegister, int bytesToRead ) { + byte inByte = 0; // incoming byte from the SPI + unsigned int result = 0; // result to return + Serial.print(thisRegister, BIN); + Serial.print("\t"); + // SCP1000 expects the register name in the upper 6 bits + // of the byte. So shift the bits left by two bits: + thisRegister = thisRegister << 2; + // now combine the address and the command into one byte + byte dataToSend = thisRegister & READ; + Serial.println(thisRegister, BIN); + // take the chip select low to select the device: + digitalWrite(chipSelectPin, LOW); + // send the device the register you want to read: + SPI.transfer(dataToSend); + // send a value of 0 to read the first byte returned: + result = SPI.transfer(0x00); + // decrement the number of bytes left to read: + bytesToRead--; + // if you still have another byte to read: + if (bytesToRead > 0) { + // shift the first byte left, then get the second byte: + result = result << 8; + inByte = SPI.transfer(0x00); + // combine the byte you just got with the previous one: + result = result | inByte; + // decrement the number of bytes left to read: + bytesToRead--; + } + // take the chip select high to de-select: + digitalWrite(chipSelectPin, HIGH); + // return the result: + return(result); +} + + +//Sends a write command to SCP1000 + +void writeRegister(byte thisRegister, byte thisValue) { + + // SCP1000 expects the register address in the upper 6 bits + // of the byte. So shift the bits left by two bits: + thisRegister = thisRegister << 2; + // now combine the register address and the command into one byte: + byte dataToSend = thisRegister | WRITE; + + // take the chip select low to select the device: + digitalWrite(chipSelectPin, LOW); + + SPI.transfer(dataToSend); //Send register location + SPI.transfer(thisValue); //Send value to record into register + + // 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 new file mode 100644 index 0000000..a06f113 --- /dev/null +++ b/libraries/SPI/examples/DigitalPotControl/DigitalPotControl.ino @@ -0,0 +1,73 @@ +/* + Digital Pot Control + + This example controls an Analog Devices AD5206 digital potentiometer. + The AD5206 has 6 potentiometer channels. Each channel's pins are labeled + A - connect this to voltage + W - this is the pot's wiper, which changes when you set it + B - connect this to ground. + + The AD5206 is SPI-compatible,and to command it, you send two bytes, + one with the channel number (0 - 5) and one with the resistance value for the + channel (0 - 255). + + 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 + * CS - to digital pin 10 (SS pin) + * SDI - to digital pin 11 (MOSI pin) + * CLK - to digital pin 13 (SCK pin) + + created 10 Aug 2010 + by Tom Igoe + + Thanks to Heather Dewey-Hagborg for the original tutorial, 2005 + +*/ + + +// inslude the SPI library: +#include + + +// set pin 10 as the slave select for the digital pot: +const int slaveSelectPin = 10; + +void setup() { + // set the slaveSelectPin as an output: + pinMode (slaveSelectPin, OUTPUT); + // initialize SPI: + SPI.begin(); +} + +void loop() { + // go through the six channels of the digital pot: + for (int channel = 0; channel < 6; channel++) { + // change the resistance on this channel from min to max: + for (int level = 0; level < 255; level++) { + digitalPotWrite(channel, level); + delay(10); + } + // wait a second at the top: + delay(100); + // change the resistance on this channel from max to min: + for (int level = 0; level < 255; level++) { + digitalPotWrite(channel, 255 - level); + delay(10); + } + } + +} + +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: + SPI.transfer(address); + SPI.transfer(value); + delay(100); + // take the SS pin high to de-select the chip: + digitalWrite(slaveSelectPin, HIGH); +} diff --git a/libraries/SPI/keywords.txt b/libraries/SPI/keywords.txt new file mode 100644 index 0000000..47738f9 --- /dev/null +++ b/libraries/SPI/keywords.txt @@ -0,0 +1,31 @@ +####################################### +# Syntax Coloring Map SPI +####################################### + +####################################### +# Datatypes (KEYWORD1) +####################################### + +SPI KEYWORD1 + +####################################### +# Methods and Functions (KEYWORD2) +####################################### +begin KEYWORD2 +end KEYWORD2 +transfer KEYWORD2 +#setBitOrder KEYWORD2 +setDataMode KEYWORD2 +setClockDivider KEYWORD2 + + +####################################### +# Constants (LITERAL1) +####################################### +SPI_MODE0 LITERAL1 +SPI_MODE1 LITERAL1 +SPI_MODE2 LITERAL1 +SPI_MODE3 LITERAL1 + +SPI_CONTINUE LITERAL1 +SPI_LAST LITERAL1 diff --git a/libraries/SPI/library.properties b/libraries/SPI/library.properties new file mode 100644 index 0000000..6940f14 --- /dev/null +++ b/libraries/SPI/library.properties @@ -0,0 +1,9 @@ +name=SPI +version=1.0 +author=Jonathan BAUDIN, Thibaut VIARD, Arduino +maintainer=Arduino +sentence=Enables the communication with devices that use the Serial Peripheral Interface (SPI) Bus. Specific implementation for Arduino Zero. +paragraph= +category=Communication +url=http://www.arduino.cc/en/Reference/SPI +architectures=samd diff --git a/libraries/SSU/examples/SSU_HttpOta/SSU_HttpOta.ino b/libraries/SSU/examples/SSU_HttpOta/SSU_HttpOta.ino new file mode 100644 index 0000000..a7eaa67 --- /dev/null +++ b/libraries/SSU/examples/SSU_HttpOta/SSU_HttpOta.ino @@ -0,0 +1,227 @@ +/* + Small example sketch demonstrating how to perform OTA via HTTP/S + utilizing a MKRGSM 1400 and the storage on the integrated + SARA U-201 GSM module. + + Please, be careful because no verification is done on the + received OTA file, apart size verification of the transmitted + bytes using the HTTP Content-Length header. + + For production-grade OTA procedure you might want to implement + a content verification procedure using a CRC calculation + or an hash (eg. MD5 or SHA256) comparison. + + Circuit: + * MKR GSM 1400 board + * Antenna + * SIM card with a data plan + + Steps to update a sketch: + + 1) Create a new sketch or update an existing one to be updated over-the-air. + The sketch needs to contain also the code below for future OTAs. + The sketch must include the SSU library via + #include + + 2) In the IDE select: Sketch -> Export compiled Binary. + + 3) Open the location of the sketch (Sketch -> Show Sketch Folder) and upload + the .bin file to your HTTP/S server. + + 4) Upload this sketch after configuring the server, port and filename variables. + + The sketch will download the OTA file, store it into the U-201 storage, and + will reset the board to trigger the SSU update procedure. + + + created 25 June 2020 + by Giampaolo Mancini +*/ + +#include + +// This includes triggers the firmware update procedure +// in the bootloader after reset. +#include + +// Do not change! SSU will look for these files! +constexpr char UPDATE_FILE_NAME[] = "UPDATE.BIN"; +static constexpr char CHECK_FILE_NAME[] = "UPDATE.OK"; + +#include "arduino_secrets.h" +const char PINNUMBER[] = SECRET_PINNUMBER; +// APN data +const char GPRS_APN[] = SECRET_GPRS_APN; +const char GPRS_LOGIN[] = SECRET_GPRS_LOGIN; +const char GPRS_PASSWORD[] = SECRET_GPRS_PASSWORD; + +// Change to GSMClient for non-SSL/TLS connection. +// Not recommended. +GSMSSLClient client; +GPRS gprs; +GSM gsmAccess; + +GSMFileUtils fileUtils; + +bool isHeaderComplete = false; +String httpHeader; + +bool isDownloadComplete = false; +unsigned int fileSize = 0; +unsigned int totalWritten = 0; + +constexpr char server[] = "example.org"; +constexpr int port = 443; + +// Name of the new firmware file to be updated. +constexpr char filename[] = "update.bin"; + + +void setup() +{ + unsigned long timeout = millis(); + + Serial.begin(9600); + while (!Serial && millis() - timeout < 5000) + ; + + Serial.println("Starting OTA Update via HTTP and Arduino SSU."); + Serial.println(); + + bool connected = false; + + Serial.print("Connecting to cellular network... "); + while (!connected) { + if ((gsmAccess.begin(PINNUMBER) == GSM_READY) && (gprs.attachGPRS(GPRS_APN, GPRS_LOGIN, GPRS_PASSWORD) == GPRS_READY)) { + connected = true; + } else { + Serial.println("Not connected"); + delay(1000); + } + } + + Serial.println("Connected."); + Serial.println(); + + // Modem has already been initialized in the sketch: + // begin FileUtils without MODEM initialization. + fileUtils.begin(false); + + Serial.print("Connecting to "); + Serial.print(server); + Serial.print(":"); + Serial.print(port); + Serial.print("... "); + if (client.connect(server, port)) { + Serial.println("Connected."); + Serial.print("Downloading "); + Serial.println(filename); + Serial.print("... "); + // Make the HTTP request: + client.print("GET /"); + client.print(filename); + client.println(" HTTP/1.1"); + client.print("Host: "); + client.println(server); + client.println("Connection: close"); + client.println(); + } else { + Serial.println("Connection failed"); + } +} + +void loop() +{ + while (client.available()) { + // Skip the HTTP header + if (!isHeaderComplete) { + const char c = client.read(); + httpHeader += c; + if (httpHeader.endsWith("\r\n\r\n")) { + isHeaderComplete = true; + + // Get the size of the OTA file from the + // HTTP Content-Length header. + fileSize = getContentLength(); + + Serial.println(); + Serial.print("HTTP header complete. "); + Serial.print("OTA file size is "); + Serial.print(fileSize); + Serial.println(" bytes."); + if (fileSize == 0) { + Serial.println("Unable to get OTA file size."); + while (true) + ; + } + } + } else { + // Read the OTA file in len-bytes blocks to preserve RAM. + constexpr size_t len { 512 }; + char buf[len] { 0 }; + + // Read len bytes from HTTP client... + uint32_t read = client.readBytes(buf, len); + // and append them to the update file. + uint32_t written = fileUtils.appendFile(UPDATE_FILE_NAME, buf, read); + + if (written != read) { + Serial.println("Error while saving data."); + while (true) + ; + } + + // Update the received byte counter + totalWritten += written; + + // Check for full file received and stored + isDownloadComplete = totalWritten == fileSize; + + Serial.print("Received: "); + Serial.print(totalWritten); + Serial.print("/"); + Serial.println(fileSize); + } + } + if (isDownloadComplete) { + Serial.println(); + Serial.println("Download complete."); + Serial.println("Enabling checkpoint."); + Serial.println(); + + // Create the checkpoint file: will be removed by SSU + // after successful update. + auto status = fileUtils.downloadFile(CHECK_FILE_NAME, { 0 }, 1); + if (status != 1) { + Serial.println("Unable to create checkpoint file."); + while (true) + ; + } + + Serial.println("Resetting MCU in order to trigger SSU..."); + Serial.println(); + delay(500); + NVIC_SystemReset(); + } +} + +int getContentLength() +{ + const String contentLengthHeader = "Content-Length:"; + const auto contentLengthHeaderLen = contentLengthHeader.length(); + + auto indexContentLengthStart = httpHeader.indexOf(contentLengthHeader); + if (indexContentLengthStart < 0) { + Serial.println("Unable to find Content-Length header (Start)"); + return 0; + } + auto indexContentLengthStop = httpHeader.indexOf("\r\n", indexContentLengthStart); + if (indexContentLengthStart < 0) { + Serial.println("Unable to find Content-Length header (Stop)"); + return 0; + } + auto contentLength = httpHeader.substring(indexContentLengthStart + contentLengthHeaderLen + 1, indexContentLengthStop); + + contentLength.trim(); + return contentLength.toInt(); +} diff --git a/libraries/SSU/examples/SSU_HttpOta/arduino_secrets.h b/libraries/SSU/examples/SSU_HttpOta/arduino_secrets.h new file mode 100644 index 0000000..fa36edb --- /dev/null +++ b/libraries/SSU/examples/SSU_HttpOta/arduino_secrets.h @@ -0,0 +1,4 @@ +#define SECRET_PINNUMBER "" +#define SECRET_GPRS_APN "GPRS_APN" // replace your GPRS APN +#define SECRET_GPRS_LOGIN "login" // replace with your GPRS login +#define SECRET_GPRS_PASSWORD "password" // replace with your GPRS password \ No newline at end of file diff --git a/libraries/SSU/examples/SSU_LZSS_HttpOta/SSU_LZSS_HttpOta.ino b/libraries/SSU/examples/SSU_LZSS_HttpOta/SSU_LZSS_HttpOta.ino new file mode 100644 index 0000000..247bbb4 --- /dev/null +++ b/libraries/SSU/examples/SSU_LZSS_HttpOta/SSU_LZSS_HttpOta.ino @@ -0,0 +1,230 @@ +/* + Small example sketch demonstrating how to perform OTA via HTTP/S + utilizing a MKRGSM 1400 and the storage on the integrated + SARA U-201 GSM module. + + Please, be careful because no verification is done on the + received OTA file, apart size verification of the transmitted + bytes using the HTTP Content-Length header. + + For production-grade OTA procedure you might want to implement + a content verification procedure using a CRC calculation + or an hash (eg. MD5 or SHA256) comparison. + + Circuit: + * MKR GSM 1400 board + * Antenna + * SIM card with a data plan + + Steps to update a sketch: + + 1) Create a new sketch or update an existing one to be updated over-the-air. + The sketch needs to contain also the code below for future OTAs. + The sketch must include the SSU library via + #include + + 2) In the IDE select: Sketch -> Export compiled Binary. + + 3) Open the location of the sketch (Sketch -> Show Sketch Folder) and compress it + with a lzss tool + (eg. https://github.com/arduino-libraries/ArduinoIoTCloud/blob/master/extras/tools/lzss.py). + + 4) Upload the .lzss file to your HTTP/S server. + + 5) Upload this sketch after configuring the server, port and filename variables. + + The sketch will download the OTA file, store it into the U-201 storage, and + will reset the board to trigger the SSU update procedure. + + + created 25 June 2020 + by Giampaolo Mancini +*/ + +#include + +// This includes triggers the firmware update procedure +// in the bootloader after reset. +#include + +// Do not change! SSU will look for these files! +constexpr char UPDATE_FILE_NAME[] = "UPDATE.BIN.LZSS"; +static constexpr char CHECK_FILE_NAME[] = "UPDATE.OK"; + +#include "arduino_secrets.h" +const char PINNUMBER[] = SECRET_PINNUMBER; +// APN data +const char GPRS_APN[] = SECRET_GPRS_APN; +const char GPRS_LOGIN[] = SECRET_GPRS_LOGIN; +const char GPRS_PASSWORD[] = SECRET_GPRS_PASSWORD; + +// Change to GSMClient for non-SSL/TLS connection. +// Not recommended. +GSMSSLClient client; +GPRS gprs; +GSM gsmAccess; + +GSMFileUtils fileUtils; + +bool isHeaderComplete = false; +String httpHeader; + +bool isDownloadComplete = false; +unsigned int fileSize = 0; +unsigned int totalWritten = 0; + +constexpr char server[] = "example.org"; +constexpr int port = 443; + +// Name of the new firmware file to be updated. +constexpr char filename[] = "update.lzss"; + + +void setup() +{ + unsigned long timeout = millis(); + + Serial.begin(9600); + while (!Serial && millis() - timeout < 5000) + ; + + Serial.println("Starting OTA Update via HTTP and Arduino SSU."); + Serial.println(); + + bool connected = false; + + Serial.print("Connecting to cellular network... "); + while (!connected) { + if ((gsmAccess.begin(PINNUMBER) == GSM_READY) && (gprs.attachGPRS(GPRS_APN, GPRS_LOGIN, GPRS_PASSWORD) == GPRS_READY)) { + connected = true; + } else { + Serial.println("Not connected"); + delay(1000); + } + } + + Serial.println("Connected."); + Serial.println(); + + // Modem has already been initialized in the sketch: + // begin FileUtils without MODEM initialization. + fileUtils.begin(false); + + Serial.print("Connecting to "); + Serial.print(server); + Serial.print(":"); + Serial.print(port); + Serial.print("... "); + if (client.connect(server, port)) { + Serial.println("Connected."); + Serial.print("Downloading "); + Serial.println(filename); + Serial.print("... "); + // Make the HTTP request: + client.print("GET /"); + client.print(filename); + client.println(" HTTP/1.1"); + client.print("Host: "); + client.println(server); + client.println("Connection: close"); + client.println(); + } else { + Serial.println("Connection failed"); + } +} + +void loop() +{ + while (client.available()) { + // Skip the HTTP header + if (!isHeaderComplete) { + const char c = client.read(); + httpHeader += c; + if (httpHeader.endsWith("\r\n\r\n")) { + isHeaderComplete = true; + + // Get the size of the OTA file from the + // HTTP Content-Length header. + fileSize = getContentLength(); + + Serial.println(); + Serial.print("HTTP header complete. "); + Serial.print("OTA file size is "); + Serial.print(fileSize); + Serial.println(" bytes."); + if (fileSize == 0) { + Serial.println("Unable to get OTA file size."); + while (true) + ; + } + } + } else { + // Read the OTA file in len-bytes blocks to preserve RAM. + constexpr size_t len { 512 }; + char buf[len] { 0 }; + + // Read len bytes from HTTP client... + uint32_t read = client.readBytes(buf, len); + // and append them to the update file. + uint32_t written = fileUtils.appendFile(UPDATE_FILE_NAME, buf, read); + + if (written != read) { + Serial.println("Error while saving data."); + while (true) + ; + } + + // Update the received byte counter + totalWritten += written; + + // Check for full file received and stored + isDownloadComplete = totalWritten == fileSize; + + Serial.print("Received: "); + Serial.print(totalWritten); + Serial.print("/"); + Serial.println(fileSize); + } + } + if (isDownloadComplete) { + Serial.println(); + Serial.println("Download complete."); + Serial.println("Enabling checkpoint."); + Serial.println(); + + // Create the checkpoint file: will be removed by SSU + // after successful update. + auto status = fileUtils.downloadFile(CHECK_FILE_NAME, { 0 }, 1); + if (status != 1) { + Serial.println("Unable to create checkpoint file."); + while (true) + ; + } + + Serial.println("Resetting MCU in order to trigger SSU..."); + Serial.println(); + delay(500); + NVIC_SystemReset(); + } +} + +int getContentLength() +{ + const String contentLengthHeader = "Content-Length:"; + const auto contentLengthHeaderLen = contentLengthHeader.length(); + + auto indexContentLengthStart = httpHeader.indexOf(contentLengthHeader); + if (indexContentLengthStart < 0) { + Serial.println("Unable to find Content-Length header (Start)"); + return 0; + } + auto indexContentLengthStop = httpHeader.indexOf("\r\n", indexContentLengthStart); + if (indexContentLengthStart < 0) { + Serial.println("Unable to find Content-Length header (Stop)"); + return 0; + } + auto contentLength = httpHeader.substring(indexContentLengthStart + contentLengthHeaderLen + 1, indexContentLengthStop); + + contentLength.trim(); + return contentLength.toInt(); +} diff --git a/libraries/SSU/examples/SSU_LZSS_HttpOta/arduino_secrets.h b/libraries/SSU/examples/SSU_LZSS_HttpOta/arduino_secrets.h new file mode 100644 index 0000000..fa36edb --- /dev/null +++ b/libraries/SSU/examples/SSU_LZSS_HttpOta/arduino_secrets.h @@ -0,0 +1,4 @@ +#define SECRET_PINNUMBER "" +#define SECRET_GPRS_APN "GPRS_APN" // replace your GPRS APN +#define SECRET_GPRS_LOGIN "login" // replace with your GPRS login +#define SECRET_GPRS_PASSWORD "password" // replace with your GPRS password \ No newline at end of file diff --git a/libraries/SSU/examples/SSU_LoadBinary/Binary.h b/libraries/SSU/examples/SSU_LoadBinary/Binary.h new file mode 100644 index 0000000..e69de29 diff --git a/libraries/SSU/examples/SSU_LoadBinary/SSU_LoadBinary.ino b/libraries/SSU/examples/SSU_LoadBinary/SSU_LoadBinary.ino new file mode 100644 index 0000000..8acfff7 --- /dev/null +++ b/libraries/SSU/examples/SSU_LoadBinary/SSU_LoadBinary.ino @@ -0,0 +1,57 @@ +/************************************************************************************** + * INCLUDE + **************************************************************************************/ + + +#include + + +/************************************************************************************** + * CONSTANTS + **************************************************************************************/ + +static char const BINARY[] = + +{ + #include "Binary.h" +}; + + +GSMFileUtils fileUtils; + + +/************************************************************************************** + * SETUP/LOOP + **************************************************************************************/ + +void setup() { + Serial.begin(9600); + + unsigned long const start = millis(); + for(unsigned long now = millis(); !Serial && ((now - start) < 5000); now = millis()) { }; + + Serial.print("Accessing SARA U-201 Filesystem... "); + if(!fileUtils.begin()) { + Serial.println("failed."); + return; + + } + Serial.println("OK"); + Serial.print("Writing \"UPDATE.BIN\" ... "); + + uint32_t bytes_to_write = sizeof(BINARY); + auto bytes_written = fileUtils.downloadFile("UPDATE.BIN", BINARY, bytes_to_write); + + if(bytes_written != bytes_to_write) { + Serial.println("downloadFile failed.");return; + + } else { + Serial.print("OK ("); + Serial.print(bytes_written); + Serial.println(" bytes written)"); + } +} + +void loop() { + +} diff --git a/libraries/SSU/examples/SSU_Usage/SSU_Usage.ino b/libraries/SSU/examples/SSU_Usage/SSU_Usage.ino new file mode 100644 index 0000000..0183553 --- /dev/null +++ b/libraries/SSU/examples/SSU_Usage/SSU_Usage.ino @@ -0,0 +1,49 @@ +/* + Usage + This example demonstrates how to use the SAMD SSU library to update a + sketch on any Arduino MKR board via the storage on the SARA U-201 GSM module. + This sketch prints out the date and time the sketch was compiled. + Steps to update sketch: + 1) Upload this sketch or another sketch that includes the SSU library + via #include + 2) Update the sketch as desired. For this example the sketch prints out + the compiled date and time so no updates are needed. + 3) In the IDE select: Sketch -> Export compiled Binary + 4) Open the location of the sketch and convert the .bin file to a C byte array. + cat SKETCH.bin | xxd --include > Binary.h + 5) Copy Binary.h file from the sketch's folder to the SSU_LoadBinary sketch + and load it to the U-201 via SSU_LoadBinary sketch. +*/ + +/* + Include the SSU library + + This will add some code to the sketch before setup() is called + to check if UPDATE.BIN and UPDATE.OK are present on the storage of + the U-201 module. If this theck is positive UPDATE.BIN is used to update + the sketch running on the board. + After this UPDATE.BIN and UPDATE.OK are deleted from the flash. +*/ + + +#include + +void setup() +{ + Serial.begin(9600); + while (!Serial) { } + // wait a bit + delay(1000); + String message; + message += "Sketch compile date and time: "; + message += __DATE__; + message += " "; + message += __TIME__; + // print out the sketch compile date and time on the serial port + Serial.println(message); +} + +void loop() +{ + // add you own code here +} \ No newline at end of file diff --git a/libraries/SSU/extras/SSUBoot/SSUBoot.ino b/libraries/SSU/extras/SSUBoot/SSUBoot.ino new file mode 100644 index 0000000..1d9ef5c --- /dev/null +++ b/libraries/SSU/extras/SSUBoot/SSUBoot.ino @@ -0,0 +1,144 @@ +/* + Copyright (c) 2020 Arduino LLC. 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 +*/ + +/************************************************************************************** + INCLUDE + **************************************************************************************/ + +#include +#include + +#include "lzss.h" + +/************************************************************************************** + DEFINE + **************************************************************************************/ + +#define SSU_START 0x2000 +#define SSU_SIZE 0x8000 + +#define SKETCH_START (uint32_t*)(SSU_START + SSU_SIZE) + +/************************************************************************************** + GLOBAL CONSTANTS + **************************************************************************************/ + + const char * UPDATE_FILE_NAME = "UPDATE.BIN"; + const char * UPDATE_FILE_NAME_LZSS = "UPDATE.BIN.LZSS"; +static const char * CHECK_FILE_NAME = "UPDATE.OK"; + +/************************************************************************************** + GLOBAL VARIABLES + **************************************************************************************/ + +FlashClass mcu_flash; +GSMFileUtils fileUtils; + +/************************************************************************************** + FUNCTION DECLARATION + **************************************************************************************/ + +extern "C" void __libc_init_array(void); + +/************************************************************************************** + MAIN + **************************************************************************************/ + +int main() +{ + init(); + + __libc_init_array(); + + delay(1); + + constexpr size_t blockSize = 512; + + fileUtils.begin(); + + bool update_success = false; + + // Try to update only if update file + // has been download successfully. + if (fileUtils.listFile(CHECK_FILE_NAME) > 0) + { + /* This is for LZSS compressed binaries. */ + if (fileUtils.listFile(UPDATE_FILE_NAME_LZSS) > 0) + { + /* Erase the complete flash starting from the SSU forward + * because we've got no possibility of knowing how large + * the decompressed binary will finally be. + */ + mcu_flash.erase((void*)SKETCH_START, 0x40000 - (uint32_t)SKETCH_START); + /* Initialize the lzss module with the data which + * it requires. + */ + lzss_init((uint32_t)SKETCH_START); + /* During the process of decoding UPDATE.BIN.LZSS + * is decompressed and stored as UPDATE.BIN. + */ + lzss_decode(); + /* Write the data remaining in the write buffer to + * the file. + */ + lzss_flush(); + /* Signal a successul update. */ + update_success = true; + } + /* This is for uncompressed binaries. */ + else if (fileUtils.listFile(UPDATE_FILE_NAME) > 0) + { + uint32_t size = fileUtils.listFile(UPDATE_FILE_NAME); + size_t cycles = (size / blockSize) + 1; + + if (size > SSU_SIZE) { + size -= SSU_SIZE; + + /* Erase the MCU flash */ + uint32_t flash_address = (uint32_t)SKETCH_START; + mcu_flash.erase((void*)flash_address, size); + + for (auto i = 0; i < cycles; i++) { + uint8_t block[blockSize] { 0 }; + digitalWrite(LED_BUILTIN, LOW); + uint32_t read = fileUtils.readBlock(UPDATE_FILE_NAME, (i * blockSize) + SSU_SIZE, blockSize, block); + digitalWrite(LED_BUILTIN, HIGH); + mcu_flash.write((void*)flash_address, block, read); + flash_address += read; + } + update_success = true; + } + } + /* Clean up in case of success */ + if (update_success) { + fileUtils.deleteFile(UPDATE_FILE_NAME); + fileUtils.deleteFile(UPDATE_FILE_NAME_LZSS); + fileUtils.deleteFile(CHECK_FILE_NAME); + } + } + /* Jump to the sketch */ + __set_MSP(*SKETCH_START); + + /* Reset vector table address */ + SCB->VTOR = ((uint32_t)(SKETCH_START) & SCB_VTOR_TBLOFF_Msk); + + /* Address of Reset_Handler is written by the linker at the beginning of the .text section (see linker script) */ + uint32_t resetHandlerAddress = (uint32_t) * (SKETCH_START + 1); + /* Jump to reset handler */ + asm("bx %0"::"r"(resetHandlerAddress)); +} diff --git a/libraries/SSU/extras/SSUBoot/build.sh b/libraries/SSU/extras/SSUBoot/build.sh new file mode 100755 index 0000000..fe2d9ce --- /dev/null +++ b/libraries/SSU/extras/SSUBoot/build.sh @@ -0,0 +1,23 @@ +#!/bin/sh -x + +#Sara U201 +ARDUINO=arduino +SKETCH_NAME="SSUBoot.ino" +SKETCH="$PWD/$SKETCH_NAME" +BUILD_PATH="$PWD/build" +OUTPUT_PATH="../../src/boot" + +if [[ "$OSTYPE" == "darwin"* ]]; then + ARDUINO="/Applications/Arduino.app/Contents/MacOS/Arduino" +fi + +buildSSUBootSketch() { + BOARD=$1 + DESTINATION=$2 + + $ARDUINO --verify --board $BOARD --preserve-temp-files --pref build.path="$BUILD_PATH" $SKETCH + cat "$BUILD_PATH/$SKETCH_NAME.bin" | xxd -include > $DESTINATION + rm -rf "$BUILD_PATH" +} + +buildSSUBootSketch "arduino:samd:mkrgsm1400" "$OUTPUT_PATH/mkrgsm1400.h" diff --git a/libraries/SSU/extras/SSUBoot/lzss.cpp b/libraries/SSU/extras/SSUBoot/lzss.cpp new file mode 100644 index 0000000..d2a615c --- /dev/null +++ b/libraries/SSU/extras/SSUBoot/lzss.cpp @@ -0,0 +1,219 @@ +/************************************************************************************** + INCLUDE + **************************************************************************************/ + +#include "lzss.h" + +#include +#include + +#include +#include + +/************************************************************************************** + DEFINE + **************************************************************************************/ + +#define EI 11 /* typically 10..13 */ +#define EJ 4 /* typically 4..5 */ +#define P 1 /* If match length <= P then output one character */ +#define N (1 << EI) /* buffer size */ +#define F ((1 << EJ) + 1) /* lookahead buffer size */ + +#define LZSS_EOF (-1) + +#define FPUTC_BUF_SIZE (512) +#define FGETC_BUF_SIZE (512) + +/************************************************************************************** + GLOBAL VARIABLES + **************************************************************************************/ + +extern GSMFileUtils fileUtils; +extern FlashClass mcu_flash; +extern const char * UPDATE_FILE_NAME_LZSS; + +static uint32_t SKETCH_START = 0; +static uint32_t LZSS_FILE_SIZE = 0; + +int bit_buffer = 0, bit_mask = 128; +unsigned char buffer[N * 2]; + +static char write_buf[FPUTC_BUF_SIZE]; +static size_t write_buf_num_bytes = 0; +static size_t bytes_written_fputc = 0; +static size_t bytes_written_flash = 0; +static uint32_t flash_addr = 0; + +/************************************************************************************** + PUBLIC FUNCTIONS + **************************************************************************************/ + +void lzss_init(uint32_t const sketch_start) +{ + SKETCH_START = sketch_start; + flash_addr = sketch_start; + LZSS_FILE_SIZE = fileUtils.listFile(UPDATE_FILE_NAME_LZSS); +} + +void lzss_flush() +{ + bytes_written_fputc += write_buf_num_bytes; + + /* Only write to the flash once we've surpassed + * the SSU in the update binary. + */ + if (bytes_written_fputc > (SKETCH_START - 0x2000)) + { + mcu_flash.write((void*)flash_addr, write_buf, write_buf_num_bytes); + flash_addr += write_buf_num_bytes; + } + + write_buf_num_bytes = 0; +} + +/************************************************************************************** + PRIVATE FUNCTIONS + **************************************************************************************/ + +void lzss_fputc(int const c) +{ + /* Buffer the decompressed data into a buffer so + * we can perform block writes and don't need to + * write every byte singly on the flash (which + * wouldn't be possible anyway). + */ + write_buf[write_buf_num_bytes] = static_cast(c); + write_buf_num_bytes++; + + /* The write buffer is full of decompressed + * data, write it to the flash now. + */ + if (write_buf_num_bytes == FPUTC_BUF_SIZE) + lzss_flush(); +} + +int lzss_fgetc() +{ + static uint8_t read_buf[FGETC_BUF_SIZE]; + static size_t read_buf_pos = FGETC_BUF_SIZE; + static size_t bytes_read_fgetc = 0; + static size_t bytes_read_from_modem = 0; + + /* lzss_file_size is set within SSUBoot:main + * and contains the size of the LZSS file. Once + * all those bytes have been read its time to return + * LZSS_EOF in order to signal that the end of + * the file has been reached. + */ + if (bytes_read_fgetc == LZSS_FILE_SIZE) + return LZSS_EOF; + + /* If there is no data left to be read from the read buffer + * than read a new block and store it into the read buffer. + */ + if (read_buf_pos == FGETC_BUF_SIZE) + { + /* Read the next block from the flash memory. */ + bytes_read_from_modem += fileUtils.readBlock(UPDATE_FILE_NAME_LZSS, bytes_read_from_modem, FGETC_BUF_SIZE, read_buf); + /* Reset the read buffer position. */ + read_buf_pos = 0; + } + + uint8_t const c = read_buf[read_buf_pos]; + read_buf_pos++; + bytes_read_fgetc++; + + return c; +} + +/************************************************************************************** + LZSS FUNCTIONS + **************************************************************************************/ + +void putbit1(void) +{ + bit_buffer |= bit_mask; + if ((bit_mask >>= 1) == 0) { + lzss_fputc(bit_buffer); + bit_buffer = 0; bit_mask = 128; + } +} + +void putbit0(void) +{ + if ((bit_mask >>= 1) == 0) { + lzss_fputc(bit_buffer); + bit_buffer = 0; bit_mask = 128; + } +} + +void output1(int c) +{ + int mask; + + putbit1(); + mask = 256; + while (mask >>= 1) { + if (c & mask) putbit1(); + else putbit0(); + } +} + +void output2(int x, int y) +{ + int mask; + + putbit0(); + mask = N; + while (mask >>= 1) { + if (x & mask) putbit1(); + else putbit0(); + } + mask = (1 << EJ); + while (mask >>= 1) { + if (y & mask) putbit1(); + else putbit0(); + } +} + +int getbit(int n) /* get n bits */ +{ + int i, x; + static int buf, mask = 0; + + x = 0; + for (i = 0; i < n; i++) { + if (mask == 0) { + if ((buf = lzss_fgetc()) == LZSS_EOF) return LZSS_EOF; + mask = 128; + } + x <<= 1; + if (buf & mask) x++; + mask >>= 1; + } + return x; +} + +void lzss_decode(void) +{ + int i, j, k, r, c; + + for (i = 0; i < N - F; i++) buffer[i] = ' '; + r = N - F; + while ((c = getbit(1)) != LZSS_EOF) { + if (c) { + if ((c = getbit(8)) == LZSS_EOF) break; + lzss_fputc(c); + buffer[r++] = c; r &= (N - 1); + } else { + if ((i = getbit(EI)) == LZSS_EOF) break; + if ((j = getbit(EJ)) == LZSS_EOF) break; + for (k = 0; k <= j + 1; k++) { + c = buffer[(i + k) & (N - 1)]; + lzss_fputc(c); + buffer[r++] = c; r &= (N - 1); + } + } + } +} diff --git a/libraries/SSU/extras/SSUBoot/lzss.h b/libraries/SSU/extras/SSUBoot/lzss.h new file mode 100644 index 0000000..7796cda --- /dev/null +++ b/libraries/SSU/extras/SSUBoot/lzss.h @@ -0,0 +1,18 @@ +#ifndef SSU_LZSS_H_ +#define SSU_LZSS_H_ + +/************************************************************************************** + INCLUDE + **************************************************************************************/ + +#include + +/************************************************************************************** + FUNCTION DEFINITION + **************************************************************************************/ + +void lzss_init(uint32_t const sketch_start); +void lzss_decode(); +void lzss_flush(); + +#endif /* SSU_LZSS_H_ */ diff --git a/libraries/SSU/keywords.txt b/libraries/SSU/keywords.txt new file mode 100644 index 0000000..f5e40c5 --- /dev/null +++ b/libraries/SSU/keywords.txt @@ -0,0 +1,17 @@ +####################################### +# Syntax Coloring Map For SDU +####################################### + +####################################### +# Datatypes (KEYWORD1) +####################################### + +SSU KEYWORD1 + +####################################### +# Methods and Functions (KEYWORD2) +####################################### + +####################################### +# Constants (LITERAL1) +####################################### diff --git a/libraries/SSU/library.properties b/libraries/SSU/library.properties new file mode 100644 index 0000000..4dff471 --- /dev/null +++ b/libraries/SSU/library.properties @@ -0,0 +1,9 @@ +name=SSU +version=1.0.0 +author=Arduino +maintainer=Arduino +sentence=Update the sketch on your Arduino MKRGSM1400 from SARAU201 flash. +paragraph= +category=Other +url=https://www.arduino.cc/en/Reference/SSU +architectures=samd diff --git a/libraries/SSU/src/SSU.cpp b/libraries/SSU/src/SSU.cpp new file mode 100644 index 0000000..71731f7 --- /dev/null +++ b/libraries/SSU/src/SSU.cpp @@ -0,0 +1,30 @@ +/* + Copyright (c) 2020 Arduino LLC. 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 +*/ + +#include + +#include "SSU.h" + +__attribute__ ((section(".sketch_boot"))) +unsigned char SSU_BOOT[0x8000] = { +#if defined(ARDUINO_SAMD_MKRGSM1400) + #include "boot/mkrgsm1400.h" +#else + #error "Unsupported board!" +#endif +}; diff --git a/libraries/SSU/src/SSU.h b/libraries/SSU/src/SSU.h new file mode 100644 index 0000000..bfdf332 --- /dev/null +++ b/libraries/SSU/src/SSU.h @@ -0,0 +1,24 @@ +/* + Copyright (c) 2020 Arduino LLC. 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 _SSU_H_INCLUDED +#define _SSU_H_INCLUDED + +/* Nothing to do */ + +#endif /* _SSU_H_INCLUDED */ diff --git a/libraries/SSU/src/boot/mkrgsm1400.h b/libraries/SSU/src/boot/mkrgsm1400.h new file mode 100644 index 0000000..b0f89c9 --- /dev/null +++ b/libraries/SSU/src/boot/mkrgsm1400.h @@ -0,0 +1,2672 @@ + 0x00, 0x80, 0x00, 0x20, 0xc5, 0x43, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, + 0xad, 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, + 0x19, 0x44, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, + 0xad, 0x43, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, + 0xad, 0x43, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, 0xb1, 0x43, 0x00, 0x00, + 0xad, 0x43, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, + 0xad, 0x43, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, 0x4d, 0x2f, 0x00, 0x00, + 0x3d, 0x2f, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, + 0xad, 0x43, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, + 0xad, 0x43, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, + 0xad, 0x43, 0x00, 0x00, 0xad, 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x06, 0x4c, 0x23, 0x78, 0x00, 0x2b, 0x07, 0xd1, 0x05, 0x4b, + 0x00, 0x2b, 0x02, 0xd0, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x01, 0x23, + 0x23, 0x70, 0x10, 0xbd, 0x40, 0x02, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, + 0xf8, 0x9a, 0x00, 0x00, 0x04, 0x4b, 0x10, 0xb5, 0x00, 0x2b, 0x03, 0xd0, + 0x03, 0x49, 0x04, 0x48, 0x00, 0xe0, 0x00, 0xbf, 0x10, 0xbd, 0xc0, 0x46, + 0x00, 0x00, 0x00, 0x00, 0x44, 0x02, 0x00, 0x20, 0xf8, 0x9a, 0x00, 0x00, + 0x10, 0xb5, 0x04, 0x00, 0x04, 0x30, 0x01, 0xf0, 0x7f, 0xff, 0x20, 0x00, + 0x10, 0xbd, 0x00, 0x00, 0xf0, 0xb5, 0x7b, 0x4c, 0x10, 0x26, 0xa5, 0x44, + 0x08, 0x24, 0x02, 0xaf, 0x02, 0xf0, 0x96, 0xfa, 0x04, 0xf0, 0xc0, 0xfb, + 0x01, 0x20, 0x02, 0xf0, 0xb7, 0xf9, 0x76, 0x4d, 0x01, 0x21, 0x28, 0x00, + 0x00, 0xf0, 0x3e, 0xfb, 0x3b, 0x19, 0x98, 0x19, 0x73, 0x49, 0x01, 0xf0, + 0xad, 0xff, 0x3a, 0x19, 0x91, 0x19, 0x28, 0x00, 0x00, 0xf0, 0x6c, 0xfb, + 0x08, 0x23, 0xfb, 0x18, 0x04, 0x00, 0x98, 0x19, 0x01, 0xf0, 0x5a, 0xff, + 0x00, 0x2c, 0x51, 0xd0, 0x08, 0x24, 0x6c, 0x4b, 0x19, 0x68, 0x3b, 0x19, + 0x98, 0x19, 0x01, 0xf0, 0x99, 0xff, 0x3a, 0x19, 0x91, 0x19, 0x28, 0x00, + 0x00, 0xf0, 0x58, 0xfb, 0x08, 0x23, 0xfb, 0x18, 0x04, 0x00, 0x98, 0x19, + 0x01, 0xf0, 0x46, 0xff, 0x00, 0x2c, 0x4d, 0xd0, 0xd8, 0x22, 0xa0, 0x21, + 0x92, 0x02, 0x09, 0x02, 0x61, 0x48, 0x00, 0xf0, 0x7b, 0xfa, 0xa0, 0x20, + 0x00, 0x02, 0x00, 0xf0, 0xeb, 0xf8, 0x00, 0xf0, 0xa7, 0xf9, 0x00, 0xf0, + 0x07, 0xf9, 0x08, 0x26, 0x10, 0x25, 0x5c, 0x4b, 0x19, 0x68, 0xbb, 0x19, + 0x58, 0x19, 0x01, 0xf0, 0x75, 0xff, 0x55, 0x4c, 0xbb, 0x19, 0x59, 0x19, + 0x20, 0x00, 0x00, 0xf0, 0xe9, 0xfb, 0xbb, 0x19, 0x58, 0x19, 0x01, 0xf0, + 0x23, 0xff, 0x52, 0x4b, 0x19, 0x68, 0xbb, 0x19, 0x58, 0x19, 0x01, 0xf0, + 0x65, 0xff, 0xbb, 0x19, 0x59, 0x19, 0x20, 0x00, 0x00, 0xf0, 0xda, 0xfb, + 0xbb, 0x19, 0x58, 0x19, 0x01, 0xf0, 0x14, 0xff, 0xbb, 0x19, 0x49, 0x49, + 0x58, 0x19, 0x01, 0xf0, 0x57, 0xff, 0xbb, 0x19, 0x59, 0x19, 0x20, 0x00, + 0x00, 0xf0, 0xcc, 0xfb, 0xbb, 0x19, 0x58, 0x19, 0x01, 0xf0, 0x06, 0xff, + 0xa0, 0x23, 0x1b, 0x02, 0x1a, 0x68, 0x82, 0xf3, 0x08, 0x88, 0x44, 0x4a, + 0x93, 0x60, 0x44, 0x4b, 0x1b, 0x68, 0x18, 0x47, 0x00, 0x20, 0xbd, 0x46, + 0x87, 0x23, 0x9b, 0x00, 0x9d, 0x44, 0xf0, 0xbd, 0x08, 0x22, 0x10, 0x23, + 0x3c, 0x4e, 0xb8, 0x18, 0x31, 0x68, 0xc0, 0x18, 0x01, 0xf0, 0x36, 0xff, + 0x08, 0x22, 0x10, 0x23, 0xb9, 0x18, 0xc9, 0x18, 0x28, 0x00, 0x00, 0xf0, + 0xf3, 0xfa, 0x08, 0x22, 0x10, 0x23, 0xba, 0x18, 0x78, 0x60, 0xd0, 0x18, + 0x01, 0xf0, 0xe0, 0xfe, 0x7b, 0x68, 0x00, 0x2b, 0xd6, 0xd0, 0x08, 0x23, + 0x31, 0x68, 0x10, 0x26, 0xfa, 0x18, 0x90, 0x19, 0x01, 0xf0, 0x1e, 0xff, + 0x08, 0x23, 0xfa, 0x18, 0x91, 0x19, 0x28, 0x00, 0x00, 0xf0, 0xdc, 0xfa, + 0x08, 0x23, 0xfb, 0x18, 0x05, 0x00, 0x98, 0x19, 0x01, 0xf0, 0xca, 0xfe, + 0x80, 0x23, 0x1b, 0x02, 0x9d, 0x42, 0xbf, 0xd9, 0xa0, 0x21, 0x28, 0x4b, + 0x09, 0x02, 0xea, 0x18, 0x22, 0x48, 0x6d, 0x0a, 0x00, 0xf0, 0xfc, 0xf9, + 0x6b, 0x1c, 0xa0, 0x25, 0x3b, 0x60, 0x2d, 0x02, 0x3b, 0x68, 0x9c, 0x42, + 0x00, 0xd3, 0x80, 0xe7, 0x08, 0x22, 0x10, 0x23, 0xba, 0x18, 0xd6, 0x18, + 0x80, 0x22, 0x00, 0x21, 0x92, 0x00, 0x30, 0x00, 0x04, 0xf0, 0x7a, 0xfb, + 0x00, 0x21, 0x06, 0x20, 0x02, 0xf0, 0xc0, 0xfa, 0x16, 0x4b, 0x19, 0x68, + 0x0c, 0x23, 0xf8, 0x18, 0x01, 0xf0, 0xea, 0xfe, 0x22, 0x00, 0x80, 0x23, + 0x0c, 0x21, 0x40, 0x32, 0x52, 0x02, 0x79, 0x18, 0x9b, 0x00, 0x00, 0x96, + 0x0b, 0x48, 0x00, 0xf0, 0xd1, 0xfa, 0x0c, 0x23, 0x78, 0x60, 0xf8, 0x18, + 0x01, 0xf0, 0x92, 0xfe, 0x01, 0x21, 0x06, 0x20, 0x02, 0xf0, 0xa6, 0xfa, + 0x7b, 0x68, 0x29, 0x00, 0x32, 0x00, 0x07, 0x48, 0x00, 0xf0, 0x76, 0xf9, + 0x7b, 0x68, 0x01, 0x34, 0xed, 0x18, 0xc9, 0xe7, 0xdc, 0xfd, 0xff, 0xff, + 0x64, 0x02, 0x00, 0x20, 0x20, 0x8d, 0x00, 0x00, 0x08, 0x00, 0x00, 0x20, + 0x78, 0x02, 0x00, 0x20, 0x04, 0x00, 0x00, 0x20, 0x00, 0xed, 0x00, 0xe0, + 0x04, 0xa0, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x37, 0xb5, 0x00, 0x24, + 0x0b, 0x48, 0x23, 0x00, 0x22, 0x00, 0x21, 0x00, 0x00, 0x94, 0x00, 0xf0, + 0x87, 0xfe, 0x22, 0x00, 0x21, 0x00, 0x08, 0x48, 0x00, 0xf0, 0x3a, 0xf9, + 0x07, 0x4d, 0x21, 0x00, 0x28, 0x00, 0x00, 0xf0, 0xcf, 0xf9, 0x28, 0x00, + 0x05, 0x4a, 0x06, 0x49, 0x02, 0xf0, 0x4c, 0xfb, 0x37, 0xbd, 0xc0, 0x46, + 0x5c, 0x02, 0x00, 0x20, 0x78, 0x02, 0x00, 0x20, 0x64, 0x02, 0x00, 0x20, + 0x00, 0x00, 0x00, 0x20, 0xfd, 0x20, 0x00, 0x00, 0x1f, 0xb5, 0x0a, 0x4b, + 0x18, 0x60, 0x0a, 0x4b, 0x18, 0x60, 0x0a, 0x4b, 0x01, 0xa8, 0x19, 0x68, + 0x01, 0xf0, 0x8c, 0xfe, 0x01, 0xa9, 0x08, 0x48, 0x00, 0xf0, 0x4c, 0xfa, + 0x07, 0x4b, 0x18, 0x60, 0x01, 0xa8, 0x01, 0xf0, 0x3b, 0xfe, 0x05, 0xb0, + 0x00, 0xbd, 0xc0, 0x46, 0x9c, 0x02, 0x00, 0x20, 0x90, 0x02, 0x00, 0x20, + 0x08, 0x00, 0x00, 0x20, 0x64, 0x02, 0x00, 0x20, 0xa0, 0x02, 0x00, 0x20, + 0x0c, 0x49, 0x70, 0xb5, 0x0c, 0x4c, 0x0a, 0x68, 0x23, 0x68, 0x0c, 0x48, + 0x9a, 0x18, 0x0a, 0x60, 0x0b, 0x49, 0x09, 0x68, 0x09, 0x18, 0x8a, 0x42, + 0x09, 0xd9, 0x0a, 0x4d, 0x0a, 0x4a, 0x29, 0x68, 0x0a, 0x48, 0x00, 0xf0, + 0x09, 0xf9, 0x2b, 0x68, 0x22, 0x68, 0x9b, 0x18, 0x2b, 0x60, 0x00, 0x23, + 0x23, 0x60, 0x70, 0xbd, 0xa4, 0x02, 0x00, 0x20, 0xa8, 0x02, 0x00, 0x20, + 0x00, 0xe0, 0xff, 0xff, 0x9c, 0x02, 0x00, 0x20, 0x90, 0x02, 0x00, 0x20, + 0xac, 0x02, 0x00, 0x20, 0x78, 0x02, 0x00, 0x20, 0x06, 0x4a, 0x07, 0x49, + 0x13, 0x68, 0x10, 0xb5, 0xc8, 0x54, 0x01, 0x33, 0x13, 0x60, 0x80, 0x22, + 0x92, 0x00, 0x93, 0x42, 0x01, 0xd1, 0xff, 0xf7, 0xcb, 0xff, 0x10, 0xbd, + 0xa8, 0x02, 0x00, 0x20, 0xac, 0x02, 0x00, 0x20, 0xf0, 0xb5, 0x18, 0x4b, + 0x18, 0x4d, 0x1b, 0x68, 0x2a, 0x68, 0x87, 0xb0, 0x9a, 0x42, 0x25, 0xd0, + 0x80, 0x23, 0x16, 0x4c, 0x9b, 0x00, 0x27, 0x68, 0x9f, 0x42, 0x15, 0xd1, + 0x14, 0x4b, 0x03, 0xa8, 0x19, 0x68, 0x01, 0xf0, 0x29, 0xfe, 0x13, 0x4b, + 0x13, 0x4e, 0x00, 0x93, 0x32, 0x68, 0x3b, 0x00, 0x03, 0xa9, 0x12, 0x48, + 0x00, 0xf0, 0x12, 0xfa, 0x33, 0x68, 0x18, 0x18, 0x30, 0x60, 0x03, 0xa8, + 0x01, 0xf0, 0xd2, 0xfd, 0x00, 0x23, 0x23, 0x60, 0x23, 0x68, 0x0a, 0x4a, + 0xd0, 0x5c, 0x01, 0x33, 0x23, 0x60, 0x2b, 0x68, 0x01, 0x33, 0x2b, 0x60, + 0x07, 0xb0, 0xf0, 0xbd, 0x01, 0x20, 0x40, 0x42, 0xfa, 0xe7, 0xc0, 0x46, + 0xa0, 0x02, 0x00, 0x20, 0xac, 0x04, 0x00, 0x20, 0x0c, 0x00, 0x00, 0x20, + 0x08, 0x00, 0x00, 0x20, 0xb4, 0x04, 0x00, 0x20, 0xb0, 0x04, 0x00, 0x20, + 0x64, 0x02, 0x00, 0x20, 0xf7, 0xb5, 0x00, 0x24, 0x26, 0x00, 0x01, 0x90, + 0x01, 0x9b, 0x9e, 0x42, 0x16, 0xda, 0x0c, 0x4d, 0x0c, 0x4f, 0x2b, 0x68, + 0x00, 0x2b, 0x06, 0xd1, 0xff, 0xf7, 0xb2, 0xff, 0x38, 0x60, 0x43, 0x1c, + 0x0d, 0xd0, 0x80, 0x23, 0x2b, 0x60, 0x2a, 0x68, 0x3b, 0x68, 0x64, 0x00, + 0x13, 0x40, 0x59, 0x1e, 0x8b, 0x41, 0x52, 0x10, 0xe4, 0x18, 0x2a, 0x60, + 0x01, 0x36, 0xe5, 0xe7, 0x20, 0x00, 0xfe, 0xbd, 0xb8, 0x06, 0x00, 0x20, + 0xb4, 0x06, 0x00, 0x20, 0xf7, 0xb5, 0x00, 0x24, 0x20, 0x22, 0x1e, 0x4d, + 0x1e, 0x4b, 0x2a, 0x55, 0x01, 0x34, 0x9c, 0x42, 0xfb, 0xd1, 0x01, 0x20, + 0xff, 0xf7, 0xd0, 0xff, 0x43, 0x1c, 0x30, 0xd0, 0x00, 0x28, 0x0c, 0xd0, + 0x08, 0x20, 0xff, 0xf7, 0xc9, 0xff, 0x06, 0x00, 0x43, 0x1c, 0x28, 0xd0, + 0xff, 0xf7, 0x72, 0xff, 0x63, 0x1c, 0x2e, 0x55, 0x5c, 0x05, 0x64, 0x0d, + 0xeb, 0xe7, 0x0b, 0x20, 0xff, 0xf7, 0xbc, 0xff, 0x06, 0x00, 0x43, 0x1c, + 0x1b, 0xd0, 0x04, 0x20, 0xff, 0xf7, 0xb6, 0xff, 0x03, 0x00, 0x01, 0x90, + 0x01, 0x33, 0x14, 0xd0, 0x37, 0x00, 0x01, 0x9b, 0xba, 0x1b, 0x01, 0x33, + 0x93, 0x42, 0xd8, 0xdb, 0x7b, 0x05, 0x5b, 0x0d, 0xeb, 0x5c, 0x01, 0x37, + 0x18, 0x00, 0x00, 0x93, 0xff, 0xf7, 0x52, 0xff, 0x6a, 0x46, 0x12, 0x78, + 0x63, 0x1c, 0x2a, 0x55, 0x5c, 0x05, 0x64, 0x0d, 0xeb, 0xe7, 0xf7, 0xbd, + 0xbc, 0x06, 0x00, 0x20, 0xef, 0x07, 0x00, 0x00, 0x07, 0xb5, 0x00, 0x21, + 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, 0x00, 0xf0, 0x62, 0xfd, + 0x07, 0xbd, 0xc0, 0x46, 0x94, 0x02, 0x00, 0x20, 0x10, 0xb5, 0x05, 0x4a, + 0x05, 0x49, 0x06, 0x48, 0x00, 0xf0, 0x10, 0xf8, 0x00, 0x22, 0x05, 0x4b, + 0x05, 0x49, 0x1a, 0x70, 0x5a, 0x54, 0x10, 0xbd, 0x01, 0x04, 0x00, 0x00, + 0x00, 0x8e, 0x00, 0x00, 0xc0, 0x1a, 0x00, 0x20, 0xbc, 0x16, 0x00, 0x20, + 0x02, 0x04, 0x00, 0x00, 0x30, 0xb5, 0x09, 0x4d, 0x09, 0x4c, 0xab, 0x68, + 0x5b, 0x03, 0x5b, 0x0f, 0x9b, 0x00, 0x1c, 0x59, 0x04, 0x60, 0xab, 0x68, + 0x01, 0x61, 0x9b, 0xb2, 0x43, 0x60, 0x63, 0x43, 0xa4, 0x00, 0x83, 0x60, + 0xc4, 0x60, 0x42, 0x61, 0x30, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, + 0x00, 0x93, 0x00, 0x00, 0xf7, 0xb5, 0x80, 0x26, 0x1a, 0x4d, 0x01, 0x91, + 0x6f, 0x68, 0x03, 0x33, 0x3e, 0x43, 0x9b, 0x08, 0x6e, 0x60, 0x00, 0x2b, + 0x2b, 0xd0, 0x17, 0x4e, 0x2e, 0x80, 0x2e, 0x7d, 0xf1, 0x07, 0xfc, 0xd5, + 0x1e, 0x00, 0x07, 0x68, 0x99, 0x1b, 0xbf, 0x08, 0x8f, 0x42, 0x19, 0xd9, + 0x00, 0x2e, 0x17, 0xd0, 0xff, 0x21, 0x17, 0x78, 0x8c, 0x43, 0x3c, 0x43, + 0x0f, 0x49, 0x57, 0x78, 0x0c, 0x40, 0x3f, 0x02, 0x3c, 0x43, 0x97, 0x78, + 0x01, 0x3e, 0x39, 0x04, 0x0c, 0x4f, 0x27, 0x40, 0xd4, 0x78, 0xbf, 0xb2, + 0x0f, 0x43, 0x24, 0x06, 0x01, 0x99, 0x3c, 0x43, 0x10, 0xc1, 0x01, 0x91, + 0x04, 0x32, 0xe0, 0xe7, 0x07, 0x4b, 0x2b, 0x80, 0x2b, 0x7d, 0xdb, 0x07, + 0xfc, 0xd5, 0x33, 0x00, 0xd1, 0xe7, 0xf7, 0xbd, 0x00, 0x40, 0x00, 0x41, + 0x44, 0xa5, 0xff, 0xff, 0xff, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0xff, + 0x04, 0xa5, 0xff, 0xff, 0x04, 0x4b, 0x05, 0x4a, 0x49, 0x08, 0xd9, 0x61, + 0x1a, 0x80, 0x1a, 0x7d, 0xd2, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0xc0, 0x46, + 0x00, 0x40, 0x00, 0x41, 0x02, 0xa5, 0xff, 0xff, 0x70, 0xb5, 0x04, 0x00, + 0x0d, 0x00, 0x16, 0x00, 0xe3, 0x68, 0x29, 0x00, 0x20, 0x00, 0xb3, 0x42, + 0x05, 0xd2, 0xff, 0xf7, 0xe7, 0xff, 0xe3, 0x68, 0xed, 0x18, 0xf6, 0x1a, + 0xf4, 0xe7, 0xff, 0xf7, 0xe1, 0xff, 0x70, 0xbd, 0x07, 0xb5, 0x00, 0x21, + 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, 0x00, 0xf0, 0xc6, 0xfc, + 0x07, 0xbd, 0xc0, 0x46, 0xd8, 0x1a, 0x00, 0x20, 0x07, 0xb5, 0x00, 0x21, + 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, 0x00, 0xf0, 0xba, 0xfc, + 0x07, 0xbd, 0xc0, 0x46, 0xe0, 0x1a, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, + 0x8b, 0x68, 0x01, 0xf0, 0xf1, 0xfd, 0x20, 0x00, 0x10, 0xbd, 0x00, 0x00, + 0x00, 0x23, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x08, 0xc0, 0x03, 0x49, + 0x01, 0xf0, 0xd0, 0xfc, 0x25, 0x74, 0x20, 0x00, 0x70, 0xbd, 0xc0, 0x46, + 0x7a, 0x93, 0x00, 0x00, 0x30, 0xb5, 0x87, 0xb0, 0x16, 0x49, 0x05, 0x00, + 0x68, 0x46, 0x01, 0xf0, 0xc3, 0xfc, 0x15, 0x4c, 0x15, 0x49, 0x20, 0x00, + 0x00, 0xf0, 0xcc, 0xf9, 0x20, 0x00, 0x6a, 0x46, 0x13, 0x49, 0x00, 0xf0, + 0xd9, 0xfa, 0x02, 0x9b, 0x04, 0x00, 0x00, 0x2b, 0x16, 0xd0, 0x00, 0x28, + 0x0e, 0xd0, 0x0b, 0x22, 0x69, 0x46, 0x03, 0xa8, 0xff, 0xf7, 0xce, 0xff, + 0x03, 0xa8, 0x01, 0xf0, 0x05, 0xfe, 0x28, 0x1d, 0x03, 0xa9, 0x01, 0xf0, + 0xe6, 0xfc, 0x03, 0xa8, 0x01, 0xf0, 0x5c, 0xfc, 0x68, 0x46, 0x01, 0xf0, + 0x59, 0xfc, 0x20, 0x00, 0x07, 0xb0, 0x30, 0xbd, 0x01, 0x24, 0x64, 0x42, + 0xf6, 0xe7, 0xc0, 0x46, 0x7a, 0x93, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x20, + 0x31, 0x93, 0x00, 0x00, 0x88, 0x13, 0x00, 0x00, 0x30, 0xb5, 0x00, 0x24, + 0x85, 0xb0, 0x01, 0x1d, 0x05, 0x00, 0x01, 0xa8, 0x01, 0xf0, 0xd9, 0xfc, + 0x03, 0x9b, 0xa3, 0x42, 0x0c, 0xd0, 0x2c, 0x21, 0x01, 0xa8, 0x01, 0xf0, + 0x66, 0xfd, 0x01, 0x34, 0x43, 0x1c, 0x05, 0xd0, 0x42, 0x1c, 0x00, 0x21, + 0x01, 0xa8, 0x01, 0xf0, 0xb5, 0xfd, 0xf2, 0xe7, 0x2c, 0x60, 0x01, 0xa8, + 0x01, 0xf0, 0x2e, 0xfc, 0x05, 0xb0, 0x30, 0xbd, 0x70, 0xb5, 0x05, 0x00, + 0x00, 0x29, 0x03, 0xd0, 0x01, 0x21, 0x16, 0x48, 0x00, 0xf0, 0xe6, 0xfa, + 0x2b, 0x7c, 0x00, 0x2b, 0x0c, 0xd0, 0x13, 0x4c, 0x20, 0x00, 0x00, 0xf0, + 0x5f, 0xf9, 0x12, 0x49, 0x20, 0x00, 0x00, 0xf0, 0x6f, 0xf9, 0x00, 0x22, + 0x64, 0x21, 0x20, 0x00, 0x00, 0xf0, 0x7c, 0xfa, 0x01, 0xf0, 0x24, 0xfe, + 0x06, 0x00, 0x01, 0xf0, 0x21, 0xfe, 0x0c, 0x4b, 0x80, 0x1b, 0x98, 0x42, + 0x0e, 0xd8, 0x28, 0x00, 0xff, 0xf7, 0x86, 0xff, 0x04, 0x00, 0x01, 0x28, + 0x04, 0xd1, 0x28, 0x00, 0xff, 0xf7, 0xb8, 0xff, 0x20, 0x00, 0x70, 0xbd, + 0x02, 0x48, 0x00, 0xf0, 0x95, 0xf9, 0xea, 0xe7, 0x00, 0x20, 0xf8, 0xe7, + 0x00, 0x1b, 0x00, 0x20, 0x3f, 0x93, 0x00, 0x00, 0x0f, 0x27, 0x00, 0x00, + 0x30, 0xb5, 0x0d, 0x00, 0x87, 0xb0, 0x12, 0x49, 0x68, 0x46, 0x01, 0xf0, + 0x35, 0xfc, 0x11, 0x4c, 0x2a, 0x68, 0x20, 0x00, 0x10, 0x49, 0x00, 0xf0, + 0x61, 0xf9, 0x20, 0x00, 0x6a, 0x46, 0x64, 0x21, 0x00, 0xf0, 0x4a, 0xfa, + 0x00, 0x24, 0x01, 0x28, 0x0b, 0xd1, 0x0b, 0x22, 0x69, 0x46, 0x03, 0xa8, + 0xff, 0xf7, 0x42, 0xff, 0x03, 0xa8, 0x01, 0xf0, 0xa2, 0xfd, 0x04, 0x00, + 0x03, 0xa8, 0x01, 0xf0, 0xd3, 0xfb, 0x68, 0x46, 0x01, 0xf0, 0xd0, 0xfb, + 0x60, 0x08, 0x07, 0xb0, 0x30, 0xbd, 0xc0, 0x46, 0x7a, 0x93, 0x00, 0x00, + 0x00, 0x1b, 0x00, 0x20, 0x60, 0x93, 0x00, 0x00, 0xf0, 0xb5, 0x0e, 0x00, + 0x04, 0x00, 0x8f, 0xb0, 0x3e, 0x49, 0x05, 0xa8, 0x15, 0x00, 0x03, 0x93, + 0x01, 0xf0, 0x04, 0xfc, 0x31, 0x00, 0x0b, 0xa8, 0x01, 0xf0, 0x4f, 0xfc, + 0x0b, 0xa9, 0x20, 0x00, 0xff, 0xf7, 0xc0, 0xff, 0x00, 0x24, 0x07, 0x00, + 0x0b, 0xa8, 0x01, 0xf0, 0xaf, 0xfb, 0xa7, 0x42, 0x62, 0xd0, 0x03, 0x9a, + 0x34, 0x4f, 0x52, 0x00, 0x00, 0x92, 0x6b, 0x00, 0x38, 0x00, 0x32, 0x68, + 0x32, 0x49, 0x00, 0xf0, 0x1d, 0xf9, 0xfa, 0x21, 0x05, 0xaa, 0x89, 0x00, + 0x38, 0x00, 0x00, 0xf0, 0x05, 0xfa, 0x0a, 0x22, 0x05, 0xa9, 0x08, 0xa8, + 0xff, 0xf7, 0x00, 0xff, 0x2c, 0x21, 0x08, 0xa8, 0x01, 0xf0, 0xbf, 0xfc, + 0x08, 0xa9, 0x42, 0x1c, 0x05, 0x00, 0x0b, 0xa8, 0xff, 0xf7, 0xf6, 0xfe, + 0x0b, 0xa9, 0x08, 0xa8, 0x01, 0xf0, 0x2b, 0xfc, 0x0b, 0xa8, 0x01, 0xf0, + 0x87, 0xfb, 0x2c, 0x21, 0x08, 0xa8, 0x01, 0xf0, 0xae, 0xfc, 0x22, 0x00, + 0x03, 0x00, 0x2d, 0x18, 0x08, 0xa9, 0x0b, 0xa8, 0x01, 0xf0, 0xda, 0xfc, + 0x0b, 0xa8, 0x01, 0xf0, 0x44, 0xfd, 0xc4, 0x0f, 0x24, 0x18, 0x64, 0x10, + 0x0d, 0x35, 0x63, 0x00, 0x5b, 0x19, 0x14, 0x9f, 0x03, 0x93, 0x03, 0x9b, + 0x9d, 0x42, 0x1d, 0xd0, 0x29, 0x00, 0x05, 0xa8, 0x01, 0xf0, 0x78, 0xfc, + 0x06, 0x78, 0x69, 0x1c, 0x05, 0xa8, 0x01, 0xf0, 0x73, 0xfc, 0x33, 0x00, + 0x30, 0x3b, 0x02, 0x78, 0xdb, 0xb2, 0x39, 0x2e, 0x01, 0xd9, 0x37, 0x3e, + 0xf3, 0xb2, 0x16, 0x00, 0x30, 0x3e, 0xf6, 0xb2, 0x39, 0x2a, 0x01, 0xd9, + 0x37, 0x3a, 0xd6, 0xb2, 0x1b, 0x01, 0x33, 0x43, 0x3b, 0x70, 0x02, 0x35, + 0x01, 0x37, 0xde, 0xe7, 0x0b, 0xa8, 0x01, 0xf0, 0x4d, 0xfb, 0x08, 0xa8, + 0x01, 0xf0, 0x4a, 0xfb, 0x05, 0xa8, 0x01, 0xf0, 0x47, 0xfb, 0x20, 0x00, + 0x0f, 0xb0, 0xf0, 0xbd, 0x7a, 0x93, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x20, + 0x49, 0x93, 0x00, 0x00, 0x70, 0xb5, 0x0e, 0x00, 0x04, 0x00, 0x86, 0xb0, + 0x16, 0x49, 0x68, 0x46, 0x01, 0xf0, 0x7e, 0xfb, 0x31, 0x00, 0x03, 0xa8, + 0x01, 0xf0, 0xc9, 0xfb, 0x03, 0xa9, 0x20, 0x00, 0xff, 0xf7, 0x3a, 0xff, + 0x05, 0x00, 0x03, 0xa8, 0x01, 0xf0, 0x2a, 0xfb, 0x00, 0x2d, 0x06, 0xd1, + 0x00, 0x24, 0x68, 0x46, 0x01, 0xf0, 0x24, 0xfb, 0x20, 0x00, 0x06, 0xb0, + 0x70, 0xbd, 0x0b, 0x4d, 0x32, 0x68, 0x0b, 0x49, 0x28, 0x00, 0x00, 0xf0, + 0x95, 0xf8, 0x6a, 0x46, 0x64, 0x21, 0x28, 0x00, 0x00, 0xf0, 0x7e, 0xf9, + 0x00, 0x28, 0xeb, 0xd0, 0x20, 0x00, 0xff, 0xf7, 0x8f, 0xfe, 0x20, 0x00, + 0xff, 0xf7, 0xc4, 0xfe, 0x01, 0x24, 0xe4, 0xe7, 0x7a, 0x93, 0x00, 0x00, + 0x00, 0x1b, 0x00, 0x20, 0x20, 0x93, 0x00, 0x00, 0x07, 0xb5, 0x00, 0x21, + 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, 0x00, 0xf0, 0x1c, 0xfb, + 0x07, 0xbd, 0xc0, 0x46, 0xe8, 0x1a, 0x00, 0x20, 0x07, 0xb5, 0x00, 0x21, + 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, 0x00, 0xf0, 0x10, 0xfb, + 0x07, 0xbd, 0xc0, 0x46, 0xf0, 0x1a, 0x00, 0x20, 0x07, 0xb5, 0x00, 0x21, + 0x03, 0x48, 0x00, 0x91, 0x0b, 0x00, 0x0a, 0x00, 0x00, 0xf0, 0x04, 0xfb, + 0x07, 0xbd, 0xc0, 0x46, 0xf8, 0x1a, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, + 0x20, 0x30, 0x01, 0xf0, 0xdd, 0xfa, 0x20, 0x00, 0x10, 0xbd, 0x00, 0x00, + 0x70, 0xb5, 0x83, 0x60, 0x04, 0x9b, 0x06, 0x00, 0x00, 0x25, 0xc3, 0x60, + 0x01, 0x23, 0x04, 0x00, 0x20, 0x36, 0x42, 0x60, 0x05, 0x74, 0x45, 0x61, + 0x05, 0x76, 0xc3, 0x61, 0x01, 0x60, 0x30, 0x00, 0x04, 0x49, 0x01, 0xf0, + 0x0f, 0xfb, 0xe5, 0x62, 0x30, 0x00, 0x40, 0x21, 0x01, 0xf0, 0xe1, 0xfa, + 0x20, 0x00, 0x70, 0xbd, 0x7a, 0x93, 0x00, 0x00, 0x01, 0x4b, 0x02, 0x4a, + 0x1a, 0x60, 0x70, 0x47, 0x30, 0x1b, 0x00, 0x20, 0x44, 0x20, 0x00, 0x20, + 0x00, 0x21, 0xc3, 0x68, 0x10, 0xb5, 0x8b, 0x42, 0x04, 0xdb, 0x01, 0x74, + 0x18, 0x00, 0x01, 0xf0, 0xc5, 0xfe, 0x01, 0x21, 0x08, 0x00, 0x10, 0xbd, + 0x70, 0xb5, 0x03, 0x7c, 0x04, 0x00, 0x0d, 0x00, 0x00, 0x2b, 0x06, 0xd0, + 0xc0, 0x68, 0x00, 0x21, 0x01, 0xf0, 0xb8, 0xfe, 0x05, 0x20, 0x01, 0xf0, + 0xe5, 0xfc, 0x01, 0xf0, 0xad, 0xfc, 0x63, 0x69, 0xc0, 0x1a, 0x13, 0x28, + 0x03, 0xd8, 0x14, 0x23, 0x18, 0x1a, 0x01, 0xf0, 0xdb, 0xfc, 0x29, 0x00, + 0x20, 0x68, 0x00, 0xf0, 0xf1, 0xfa, 0x20, 0x68, 0x03, 0x68, 0xdb, 0x68, + 0x98, 0x47, 0x00, 0x23, 0x23, 0x76, 0xe3, 0x61, 0x70, 0xbd, 0x00, 0x00, + 0x0e, 0xb4, 0x10, 0xb5, 0x0a, 0x4c, 0x0b, 0x49, 0xa5, 0x44, 0x04, 0x00, + 0xff, 0xab, 0x18, 0x33, 0x04, 0xcb, 0x02, 0xa8, 0x01, 0x93, 0x04, 0xf0, + 0x99, 0xfd, 0x02, 0xa9, 0x20, 0x00, 0xff, 0xf7, 0xcb, 0xff, 0x05, 0x4b, + 0x9d, 0x44, 0x10, 0xbc, 0x08, 0xbc, 0x03, 0xb0, 0x18, 0x47, 0xc0, 0x46, + 0xf4, 0xfb, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0x0c, 0x04, 0x00, 0x00, + 0xf0, 0xb5, 0x04, 0x00, 0x87, 0xb0, 0x20, 0x68, 0x03, 0x68, 0x1b, 0x69, + 0x98, 0x47, 0x00, 0x28, 0x00, 0xd1, 0x92, 0xe0, 0x20, 0x68, 0x03, 0x68, + 0x5b, 0x69, 0x98, 0x47, 0x58, 0x4b, 0xc6, 0xb2, 0x18, 0x68, 0x00, 0x28, + 0x03, 0xd0, 0x03, 0x68, 0x31, 0x00, 0x1b, 0x68, 0x98, 0x47, 0x25, 0x00, + 0x20, 0x35, 0x31, 0x00, 0x28, 0x00, 0x01, 0xf0, 0x18, 0xfb, 0x27, 0x7e, + 0x01, 0x2f, 0x48, 0xd0, 0x50, 0x49, 0x68, 0x46, 0x01, 0xf0, 0x8c, 0xfa, + 0x69, 0x46, 0x28, 0x00, 0x01, 0xf0, 0x2d, 0xfb, 0x00, 0x26, 0xb0, 0x42, + 0x0d, 0xd0, 0x4c, 0x49, 0x03, 0xa8, 0x01, 0xf0, 0x81, 0xfa, 0x03, 0xa9, + 0x28, 0x00, 0x01, 0xf0, 0x2e, 0xfb, 0x46, 0x1e, 0xb0, 0x41, 0xc6, 0xb2, + 0x03, 0xa8, 0x01, 0xf0, 0x2f, 0xfa, 0x68, 0x46, 0x01, 0xf0, 0x2c, 0xfa, + 0x00, 0x2e, 0x06, 0xd0, 0x01, 0x23, 0x23, 0x76, 0x42, 0x49, 0x28, 0x00, + 0x01, 0xf0, 0xcd, 0xfa, 0xbd, 0xe7, 0x3f, 0x49, 0x03, 0xa8, 0x01, 0xf0, + 0x67, 0xfa, 0x03, 0xa9, 0x28, 0x00, 0x01, 0xf0, 0x14, 0xfb, 0x07, 0x00, + 0x03, 0xa8, 0x01, 0xf0, 0x17, 0xfa, 0x00, 0x2f, 0xaf, 0xd0, 0x28, 0x00, + 0x01, 0xf0, 0xb4, 0xfb, 0xa3, 0x6a, 0x00, 0x2b, 0xe6, 0xd0, 0x01, 0xf0, + 0x1f, 0xfc, 0x60, 0x61, 0x35, 0x4b, 0xb2, 0x00, 0xd0, 0x58, 0x00, 0x28, + 0x03, 0xd0, 0x03, 0x68, 0x29, 0x00, 0x1b, 0x68, 0x98, 0x47, 0x01, 0x36, + 0x0a, 0x2e, 0xf3, 0xd1, 0xd6, 0xe7, 0x0a, 0x2e, 0x97, 0xd1, 0x01, 0xf0, + 0x0d, 0xfc, 0x2e, 0x49, 0x60, 0x61, 0x03, 0xa8, 0x01, 0xf0, 0x3e, 0xfa, + 0x03, 0xa9, 0x28, 0x00, 0x01, 0xf0, 0x48, 0xfb, 0x06, 0x00, 0x03, 0xa8, + 0x01, 0xf0, 0xee, 0xf9, 0x73, 0x1c, 0x22, 0xd0, 0xe7, 0x61, 0xe3, 0x69, + 0x00, 0x2b, 0x82, 0xd0, 0x23, 0x7c, 0x00, 0x2b, 0x03, 0xd0, 0x01, 0x21, + 0xe0, 0x68, 0x01, 0xf0, 0xf9, 0xfd, 0xe3, 0x6a, 0x00, 0x2b, 0x0c, 0xd0, + 0x31, 0x00, 0x28, 0x00, 0x01, 0xf0, 0x76, 0xfb, 0x28, 0x00, 0x01, 0xf0, + 0x79, 0xfb, 0x29, 0x00, 0xe0, 0x6a, 0x01, 0xf0, 0x5a, 0xfa, 0x00, 0x23, + 0xe3, 0x62, 0x00, 0x23, 0x16, 0x49, 0x23, 0x76, 0x28, 0x00, 0x01, 0xf0, + 0x74, 0xfa, 0x07, 0xb0, 0xf0, 0xbd, 0x16, 0x49, 0x03, 0xa8, 0x01, 0xf0, + 0x0d, 0xfa, 0x03, 0xa9, 0x28, 0x00, 0x01, 0xf0, 0x17, 0xfb, 0x06, 0x00, + 0x03, 0xa8, 0x01, 0xf0, 0xbd, 0xf9, 0x73, 0x1c, 0x02, 0xd0, 0x02, 0x23, + 0xe3, 0x61, 0xcc, 0xe7, 0x0e, 0x49, 0x03, 0xa8, 0x01, 0xf0, 0xfc, 0xf9, + 0x03, 0xa9, 0x28, 0x00, 0x01, 0xf0, 0x06, 0xfb, 0x06, 0x00, 0x03, 0xa8, + 0x01, 0xf0, 0xac, 0xf9, 0x73, 0x1c, 0xbe, 0xd0, 0x03, 0x23, 0xed, 0xe7, + 0x30, 0x1b, 0x00, 0x20, 0x73, 0x93, 0x00, 0x00, 0x78, 0x93, 0x00, 0x00, + 0x7a, 0x93, 0x00, 0x00, 0x34, 0x1b, 0x00, 0x20, 0x76, 0x93, 0x00, 0x00, + 0x7b, 0x93, 0x00, 0x00, 0x83, 0x93, 0x00, 0x00, 0x70, 0xb5, 0xc2, 0x62, + 0x04, 0x00, 0x0e, 0x00, 0x01, 0xf0, 0xa4, 0xfb, 0x05, 0x00, 0x01, 0xf0, + 0xa1, 0xfb, 0x40, 0x1b, 0xb0, 0x42, 0x08, 0xd2, 0x20, 0x00, 0xff, 0xf7, + 0x21, 0xff, 0xe0, 0x69, 0x00, 0x28, 0xf4, 0xd0, 0x00, 0x23, 0xe3, 0x62, + 0x70, 0xbd, 0x00, 0x23, 0x20, 0x00, 0xe3, 0x62, 0x20, 0x30, 0x03, 0x49, + 0x01, 0xf0, 0x25, 0xfa, 0x01, 0x20, 0x40, 0x42, 0xf4, 0xe7, 0xc0, 0x46, + 0x7a, 0x93, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x00, 0x05, 0x49, 0xff, 0xf7, + 0xc7, 0xfe, 0x00, 0x22, 0x64, 0x21, 0x20, 0x00, 0xff, 0xf7, 0xd4, 0xff, + 0x01, 0x38, 0x43, 0x42, 0x58, 0x41, 0x10, 0xbd, 0x73, 0x93, 0x00, 0x00, + 0x70, 0xb5, 0x05, 0x00, 0x0e, 0x00, 0x01, 0xf0, 0x73, 0xfb, 0x04, 0x00, + 0x01, 0xf0, 0x70, 0xfb, 0x00, 0x1b, 0xb0, 0x42, 0x08, 0xd2, 0x28, 0x00, + 0xff, 0xf7, 0xe2, 0xff, 0x01, 0x28, 0x04, 0xd0, 0x64, 0x20, 0x01, 0xf0, + 0x9b, 0xfb, 0xf1, 0xe7, 0x00, 0x20, 0x70, 0xbd, 0x10, 0xb5, 0x07, 0x49, + 0x04, 0x00, 0xff, 0xf7, 0xa1, 0xfe, 0xfa, 0x21, 0x00, 0x22, 0x89, 0x00, + 0x20, 0x00, 0xff, 0xf7, 0xad, 0xff, 0x01, 0x38, 0x43, 0x42, 0x58, 0x41, + 0x10, 0xbd, 0xc0, 0x46, 0xa5, 0x93, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x00, + 0xe1, 0x23, 0x0d, 0x00, 0x61, 0x68, 0x00, 0x68, 0x5b, 0x02, 0x99, 0x42, + 0x00, 0xd9, 0x19, 0x00, 0x03, 0x68, 0xdb, 0x69, 0x98, 0x47, 0xa0, 0x68, + 0x00, 0x28, 0x1f, 0xdb, 0x00, 0x2d, 0x1d, 0xd0, 0x01, 0x21, 0x01, 0xf0, + 0xf5, 0xfc, 0x01, 0x21, 0xa0, 0x68, 0x01, 0xf0, 0x3d, 0xfd, 0x64, 0x20, + 0x01, 0xf0, 0x6a, 0xfb, 0x00, 0x21, 0xa0, 0x68, 0x01, 0xf0, 0x36, 0xfd, + 0x27, 0x49, 0x20, 0x00, 0xff, 0xf7, 0xb4, 0xff, 0x00, 0x28, 0x0f, 0xd0, + 0xe1, 0x23, 0x62, 0x68, 0x5b, 0x02, 0x9a, 0x42, 0x12, 0xd8, 0xe0, 0x68, + 0x00, 0x28, 0x2d, 0xda, 0x01, 0x20, 0x06, 0xe0, 0x1f, 0x49, 0x20, 0x00, + 0xff, 0xf7, 0xa4, 0xff, 0x00, 0x28, 0x01, 0xd1, 0x00, 0x20, 0x70, 0xbd, + 0x20, 0x00, 0xff, 0xf7, 0xb3, 0xff, 0x00, 0x28, 0xe2, 0xd1, 0xf7, 0xe7, + 0x19, 0x49, 0x20, 0x00, 0xff, 0xf7, 0x76, 0xfe, 0x00, 0x22, 0x64, 0x21, + 0x20, 0x00, 0xff, 0xf7, 0x5f, 0xff, 0x01, 0x28, 0xec, 0xd1, 0x20, 0x68, + 0x03, 0x68, 0x5b, 0x6a, 0x98, 0x47, 0x64, 0x20, 0x01, 0xf0, 0x36, 0xfb, + 0x20, 0x68, 0x61, 0x68, 0x03, 0x68, 0xdb, 0x69, 0x98, 0x47, 0x0d, 0x49, + 0x20, 0x00, 0xff, 0xf7, 0x7f, 0xff, 0x00, 0x28, 0xcf, 0xd1, 0xd9, 0xe7, + 0x01, 0x21, 0x01, 0xf0, 0xab, 0xfc, 0x20, 0x00, 0xff, 0xf7, 0x26, 0xfe, + 0x08, 0x49, 0x20, 0x00, 0xff, 0xf7, 0x2e, 0xfe, 0x00, 0x22, 0x64, 0x21, + 0x20, 0x00, 0xff, 0xf7, 0x3b, 0xff, 0x01, 0x38, 0x43, 0x42, 0x58, 0x41, + 0xc7, 0xe7, 0xc0, 0x46, 0x10, 0x27, 0x00, 0x00, 0x90, 0x93, 0x00, 0x00, + 0x9b, 0x93, 0x00, 0x00, 0x23, 0x23, 0xe1, 0x22, 0x13, 0xb5, 0x07, 0x4c, + 0x00, 0x93, 0x12, 0x03, 0x04, 0x3b, 0x06, 0x49, 0x20, 0x00, 0xff, 0xf7, + 0xe3, 0xfd, 0x05, 0x4a, 0x05, 0x49, 0x20, 0x00, 0x01, 0xf0, 0xaa, 0xfd, + 0x13, 0xbd, 0xc0, 0x46, 0x00, 0x1b, 0x00, 0x20, 0xf0, 0x1d, 0x00, 0x20, + 0x00, 0x00, 0x00, 0x20, 0x41, 0x2a, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x00, + 0x04, 0x4b, 0x54, 0x22, 0x08, 0x33, 0x08, 0xc0, 0x00, 0x21, 0x03, 0xf0, + 0x73, 0xfd, 0x20, 0x00, 0x10, 0xbd, 0xc0, 0x46, 0xb0, 0x93, 0x00, 0x00, + 0x10, 0xb5, 0x0c, 0x24, 0x4c, 0x43, 0x04, 0x19, 0x60, 0x68, 0x00, 0x28, + 0x05, 0xd0, 0x03, 0xf0, 0x2d, 0xfd, 0x00, 0x23, 0xa3, 0x60, 0x63, 0x60, + 0xe3, 0x60, 0x10, 0xbd, 0x70, 0xb5, 0x05, 0x00, 0x00, 0x24, 0x06, 0x4b, + 0x08, 0x33, 0x03, 0x60, 0x21, 0x00, 0x28, 0x00, 0x01, 0x34, 0xff, 0xf7, + 0xe7, 0xff, 0x07, 0x2c, 0xf8, 0xd1, 0x28, 0x00, 0x70, 0xbd, 0xc0, 0x46, + 0xb0, 0x93, 0x00, 0x00, 0x10, 0xb5, 0x04, 0x00, 0xff, 0xf7, 0xea, 0xff, + 0x20, 0x00, 0x01, 0xf0, 0xe6, 0xfa, 0x20, 0x00, 0x10, 0xbd, 0x00, 0x00, + 0x10, 0xb5, 0x05, 0x4c, 0x20, 0x00, 0xff, 0xf7, 0xc3, 0xff, 0x04, 0x4a, + 0x04, 0x49, 0x20, 0x00, 0x01, 0xf0, 0x5e, 0xfd, 0x10, 0xbd, 0xc0, 0x46, + 0x5c, 0x1b, 0x00, 0x20, 0x00, 0x00, 0x00, 0x20, 0xe1, 0x2e, 0x00, 0x00, + 0x10, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x79, 0xff, 0x10, 0xbd, 0xc0, 0x46, + 0xb4, 0x1b, 0x00, 0x20, 0x10, 0xb5, 0x02, 0x48, 0x00, 0xf0, 0x71, 0xff, + 0x10, 0xbd, 0xc0, 0x46, 0xf0, 0x1d, 0x00, 0x20, 0x7f, 0xb5, 0x19, 0x49, + 0x19, 0x48, 0x00, 0xf0, 0xef, 0xf8, 0x19, 0x49, 0x19, 0x48, 0x00, 0xf0, + 0xeb, 0xf8, 0x19, 0x49, 0x19, 0x48, 0x00, 0xf0, 0xe7, 0xf8, 0x19, 0x49, + 0x19, 0x48, 0x00, 0xf0, 0xe3, 0xf8, 0x19, 0x4c, 0x19, 0x49, 0x20, 0x00, + 0x00, 0xf0, 0xde, 0xf8, 0x18, 0x4e, 0x19, 0x49, 0x30, 0x00, 0x00, 0xf0, + 0xd9, 0xf8, 0x01, 0x25, 0x03, 0x23, 0x31, 0x00, 0x01, 0x95, 0x00, 0x93, + 0x0d, 0x22, 0x0b, 0x33, 0x14, 0x48, 0x00, 0xf0, 0xdd, 0xfe, 0x1d, 0x23, + 0x03, 0x93, 0x01, 0x3b, 0x02, 0x93, 0x1a, 0x3b, 0x01, 0x93, 0x00, 0x95, + 0x18, 0x33, 0x1b, 0x22, 0x21, 0x00, 0x0f, 0x48, 0x00, 0xf0, 0x8c, 0xfe, + 0x7f, 0xbd, 0xc0, 0x46, 0x00, 0x08, 0x00, 0x42, 0x2c, 0x20, 0x00, 0x20, + 0x00, 0x0c, 0x00, 0x42, 0x30, 0x20, 0x00, 0x20, 0x00, 0x10, 0x00, 0x42, + 0x34, 0x20, 0x00, 0x20, 0x00, 0x14, 0x00, 0x42, 0x38, 0x20, 0x00, 0x20, + 0x3c, 0x20, 0x00, 0x20, 0x00, 0x18, 0x00, 0x42, 0x40, 0x20, 0x00, 0x20, + 0x00, 0x1c, 0x00, 0x42, 0xb4, 0x1b, 0x00, 0x20, 0xf0, 0x1d, 0x00, 0x20, + 0xf7, 0xb5, 0xc3, 0x1d, 0x01, 0x93, 0x00, 0x23, 0x06, 0x00, 0x0d, 0x00, + 0x04, 0x1d, 0x00, 0x93, 0x21, 0x78, 0x0a, 0x22, 0x28, 0x00, 0x00, 0xf0, + 0x93, 0xf8, 0x2e, 0x21, 0x07, 0x00, 0x28, 0x00, 0x00, 0xf0, 0x47, 0xf8, + 0x00, 0x9b, 0x3f, 0x18, 0xdb, 0x19, 0x00, 0x93, 0x01, 0x9b, 0x01, 0x34, + 0x9c, 0x42, 0xed, 0xd1, 0xf1, 0x79, 0x28, 0x00, 0x0a, 0x22, 0x00, 0xf0, + 0x81, 0xf8, 0x00, 0x9b, 0x18, 0x18, 0xfe, 0xbd, 0x30, 0xb5, 0x03, 0xac, + 0x25, 0x78, 0x04, 0x4c, 0xc5, 0x71, 0x08, 0x34, 0x04, 0x60, 0x01, 0x71, + 0x42, 0x71, 0x83, 0x71, 0x30, 0xbd, 0xc0, 0x46, 0x20, 0x97, 0x00, 0x00, + 0xf7, 0xb5, 0x06, 0x00, 0x0d, 0x00, 0x0c, 0x00, 0x8b, 0x18, 0x01, 0x93, + 0x01, 0x9b, 0x67, 0x1b, 0x9c, 0x42, 0x07, 0xd0, 0x33, 0x68, 0x21, 0x78, + 0x1b, 0x68, 0x30, 0x00, 0x98, 0x47, 0x01, 0x34, 0x00, 0x28, 0xf3, 0xd1, + 0x38, 0x00, 0xfe, 0xbd, 0x70, 0xb5, 0x04, 0x00, 0x08, 0x00, 0x0d, 0x00, + 0x04, 0xf0, 0xd2, 0xf9, 0x23, 0x68, 0x02, 0x00, 0x29, 0x00, 0x5b, 0x68, + 0x20, 0x00, 0x98, 0x47, 0x70, 0xbd, 0x10, 0xb5, 0x0b, 0x1e, 0x02, 0xd0, + 0xff, 0xf7, 0xee, 0xff, 0x03, 0x00, 0x18, 0x00, 0x10, 0xbd, 0x10, 0xb5, + 0x03, 0x68, 0x1b, 0x68, 0x98, 0x47, 0x10, 0xbd, 0x10, 0xb5, 0x02, 0x49, + 0xff, 0xf7, 0xe2, 0xff, 0x10, 0xbd, 0xc0, 0x46, 0x78, 0x93, 0x00, 0x00, + 0x70, 0xb5, 0x04, 0x00, 0xff, 0xf7, 0xe7, 0xff, 0x05, 0x00, 0x20, 0x00, + 0xff, 0xf7, 0xf0, 0xff, 0x40, 0x19, 0x70, 0xbd, 0xf0, 0xb5, 0x8b, 0xb0, + 0x6b, 0x46, 0x15, 0x00, 0x00, 0x22, 0x05, 0x33, 0x06, 0x00, 0xda, 0x77, + 0x08, 0x00, 0x01, 0x2d, 0x00, 0xd8, 0x0a, 0x25, 0x09, 0xac, 0x29, 0x00, + 0x01, 0xf0, 0x0e, 0xfd, 0xca, 0xb2, 0x13, 0x00, 0x37, 0x33, 0x07, 0x00, + 0xdb, 0xb2, 0x09, 0x29, 0x02, 0xd8, 0x13, 0x00, 0x30, 0x33, 0xdb, 0xb2, + 0x01, 0x3c, 0x23, 0x70, 0x00, 0x2f, 0xee, 0xd1, 0x21, 0x00, 0x30, 0x00, + 0xff, 0xf7, 0xbf, 0xff, 0x0b, 0xb0, 0xf0, 0xbd, 0x10, 0xb5, 0x00, 0x2a, + 0x04, 0xd1, 0x03, 0x68, 0xc9, 0xb2, 0x1b, 0x68, 0x98, 0x47, 0x10, 0xbd, + 0xd2, 0xb2, 0xff, 0xf7, 0xd1, 0xff, 0xfa, 0xe7, 0x10, 0xb5, 0xff, 0xf7, + 0xf1, 0xff, 0x10, 0xbd, 0x01, 0x60, 0x70, 0x47, 0x94, 0x46, 0xf0, 0xb5, + 0x9e, 0x1e, 0x72, 0x1e, 0x96, 0x41, 0x62, 0x46, 0x05, 0x68, 0x92, 0x07, + 0x2f, 0x68, 0x36, 0x06, 0x3a, 0x43, 0x32, 0x43, 0x2a, 0x60, 0x07, 0x25, + 0x05, 0xac, 0x24, 0x78, 0x00, 0x68, 0xa4, 0x01, 0x29, 0x40, 0x21, 0x43, + 0x42, 0x68, 0x00, 0x24, 0x02, 0x2b, 0x00, 0xd0, 0x5c, 0x03, 0x11, 0x43, + 0x21, 0x43, 0x41, 0x60, 0xf0, 0xbd, 0x30, 0xb5, 0xc0, 0x25, 0x03, 0x68, + 0xad, 0x03, 0x1c, 0x68, 0x12, 0x05, 0x2a, 0x40, 0x22, 0x43, 0xc0, 0x24, + 0x09, 0x04, 0xa4, 0x02, 0x21, 0x40, 0x11, 0x43, 0x19, 0x60, 0x03, 0x68, + 0x5a, 0x68, 0x14, 0x43, 0x5c, 0x60, 0x30, 0xbd, 0x01, 0x23, 0x02, 0x68, + 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, 0x03, 0x68, 0x1a, 0x68, 0xd2, 0x07, + 0xfc, 0xd4, 0xda, 0x69, 0xd2, 0x07, 0xf9, 0xd4, 0x70, 0x47, 0x02, 0x23, + 0x02, 0x68, 0x11, 0x68, 0x0b, 0x43, 0x13, 0x60, 0x02, 0x68, 0xd3, 0x69, + 0x9b, 0x07, 0xfc, 0xd4, 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, + 0x02, 0xd4, 0x1a, 0x7e, 0x92, 0x07, 0xfc, 0xd5, 0x70, 0x47, 0x00, 0x22, + 0x03, 0x68, 0x5a, 0x83, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0x40, 0x07, + 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x09, 0x70, 0x47, + 0x80, 0x23, 0x02, 0x68, 0x5b, 0x42, 0x11, 0x7e, 0x0b, 0x43, 0x13, 0x76, + 0x70, 0x47, 0x03, 0x68, 0x58, 0x8b, 0x80, 0x07, 0xc0, 0x0f, 0x70, 0x47, + 0x02, 0x23, 0x02, 0x68, 0x51, 0x8b, 0x0b, 0x43, 0x53, 0x83, 0x70, 0x47, + 0x03, 0x68, 0x18, 0x7e, 0xc0, 0x07, 0xc0, 0x0f, 0x70, 0x47, 0x03, 0x68, + 0x18, 0x8d, 0xc0, 0xb2, 0x70, 0x47, 0x03, 0x68, 0x1a, 0x7e, 0xd2, 0x07, + 0xfc, 0xd5, 0x89, 0xb2, 0x01, 0x20, 0x19, 0x85, 0x70, 0x47, 0x01, 0x22, + 0x03, 0x68, 0x9a, 0x75, 0x70, 0x47, 0x01, 0x22, 0x03, 0x68, 0x1a, 0x75, + 0x70, 0x47, 0x00, 0x00, 0x03, 0x68, 0x21, 0x4a, 0x30, 0xb5, 0x93, 0x42, + 0x2f, 0xd0, 0x20, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1f, 0x4a, 0x93, 0x42, + 0x2f, 0xd0, 0x1f, 0x4a, 0x93, 0x42, 0x2f, 0xd0, 0x1e, 0x4a, 0x93, 0x42, + 0x2f, 0xd0, 0x1e, 0x4a, 0x93, 0x42, 0x1f, 0xd1, 0x0e, 0x23, 0x19, 0x22, + 0x01, 0x21, 0x03, 0x25, 0x99, 0x40, 0x1b, 0x48, 0xc0, 0x24, 0x01, 0x60, + 0x99, 0x08, 0x2b, 0x40, 0xab, 0x40, 0xfc, 0x35, 0x9d, 0x40, 0x89, 0x00, + 0x09, 0x18, 0xa4, 0x00, 0x08, 0x59, 0xa8, 0x43, 0xc0, 0x25, 0x9d, 0x40, + 0x2b, 0x00, 0x03, 0x43, 0x0b, 0x51, 0x80, 0x23, 0xdb, 0x01, 0x1a, 0x43, + 0x11, 0x4b, 0x5a, 0x80, 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, + 0x30, 0xbd, 0x09, 0x23, 0x14, 0x22, 0xdd, 0xe7, 0x0a, 0x23, 0x15, 0x22, + 0xda, 0xe7, 0x0b, 0x23, 0x16, 0x22, 0xd7, 0xe7, 0x0c, 0x23, 0x17, 0x22, + 0xd4, 0xe7, 0x0d, 0x23, 0x18, 0x22, 0xd1, 0xe7, 0x00, 0x08, 0x00, 0x42, + 0x00, 0x0c, 0x00, 0x42, 0x00, 0x10, 0x00, 0x42, 0x00, 0x14, 0x00, 0x42, + 0x00, 0x18, 0x00, 0x42, 0x00, 0x1c, 0x00, 0x42, 0x00, 0xe1, 0x00, 0xe0, + 0x00, 0x0c, 0x00, 0x40, 0xf8, 0xb5, 0x04, 0x00, 0x0f, 0x00, 0x16, 0x00, + 0x1d, 0x00, 0xff, 0xf7, 0xa5, 0xff, 0x20, 0x00, 0xff, 0xf7, 0x4a, 0xff, + 0x1c, 0x21, 0xbb, 0x00, 0x0b, 0x40, 0x71, 0x07, 0x22, 0x68, 0x09, 0x0c, + 0x0b, 0x43, 0x13, 0x60, 0x84, 0x23, 0x22, 0x68, 0x93, 0x75, 0x01, 0x2f, + 0x1a, 0xd1, 0x10, 0x21, 0x01, 0x2e, 0x00, 0xd0, 0x08, 0x39, 0x0c, 0x4b, + 0x69, 0x43, 0x18, 0x68, 0xc0, 0x00, 0x01, 0xf0, 0x65, 0xfb, 0x07, 0x22, + 0x21, 0x68, 0x02, 0x40, 0x8b, 0x89, 0x52, 0x03, 0xdb, 0x04, 0xdb, 0x0c, + 0x13, 0x43, 0x8b, 0x81, 0x22, 0x68, 0x03, 0x04, 0x90, 0x89, 0xdb, 0x0c, + 0x40, 0x0b, 0x40, 0x03, 0x18, 0x43, 0x90, 0x81, 0xf8, 0xbd, 0xc0, 0x46, + 0x20, 0x00, 0x00, 0x20, 0x00, 0x20, 0x70, 0x47, 0x70, 0xb5, 0x0f, 0x26, + 0xcb, 0x1d, 0x01, 0x39, 0x02, 0x00, 0x32, 0x40, 0xd5, 0xb2, 0x2c, 0x00, + 0x00, 0x09, 0x30, 0x34, 0x09, 0x2a, 0x00, 0xdd, 0x07, 0x34, 0x1c, 0x70, + 0x01, 0x3b, 0x8b, 0x42, 0xf2, 0xd1, 0x70, 0xbd, 0x10, 0xb5, 0x0c, 0x00, + 0x0b, 0x4b, 0x18, 0x68, 0xff, 0xf7, 0xe8, 0xff, 0x21, 0x00, 0x0a, 0x4b, + 0x08, 0x31, 0x18, 0x68, 0xff, 0xf7, 0xe2, 0xff, 0x21, 0x00, 0x08, 0x4b, + 0x10, 0x31, 0x18, 0x68, 0xff, 0xf7, 0xdc, 0xff, 0x21, 0x00, 0x06, 0x4b, + 0x18, 0x31, 0x18, 0x68, 0xff, 0xf7, 0xd6, 0xff, 0x20, 0x20, 0x10, 0xbd, + 0x0c, 0xa0, 0x80, 0x00, 0x40, 0xa0, 0x80, 0x00, 0x44, 0xa0, 0x80, 0x00, + 0x48, 0xa0, 0x80, 0x00, 0x08, 0xb4, 0x02, 0x4b, 0x9c, 0x46, 0x10, 0x38, + 0x08, 0xbc, 0x60, 0x47, 0x95, 0x33, 0x00, 0x00, 0x70, 0x47, 0x3f, 0x20, + 0x70, 0x47, 0x13, 0xb5, 0x6b, 0x46, 0x02, 0x68, 0xd9, 0x71, 0x07, 0x33, + 0x54, 0x68, 0x19, 0x00, 0x01, 0x22, 0xa0, 0x47, 0x16, 0xbd, 0x00, 0x00, + 0x70, 0xb5, 0x0a, 0x26, 0x0b, 0x78, 0x92, 0xb0, 0x6e, 0x44, 0x02, 0x33, + 0x05, 0x00, 0x0b, 0x70, 0x3c, 0x22, 0x00, 0x21, 0x30, 0x00, 0x03, 0xf0, + 0xc1, 0xfa, 0x39, 0x48, 0x01, 0xac, 0x06, 0x90, 0x38, 0x48, 0x24, 0x21, + 0x07, 0x90, 0x06, 0x20, 0x20, 0x77, 0x68, 0x46, 0x36, 0x4a, 0xa1, 0x74, + 0x22, 0x81, 0x36, 0x4a, 0x36, 0x4b, 0xa2, 0x81, 0xfd, 0x3a, 0xff, 0x3a, + 0x80, 0x18, 0xc1, 0x77, 0x68, 0x46, 0x23, 0x39, 0x06, 0x30, 0xc1, 0x77, + 0x68, 0x46, 0x07, 0x30, 0xc1, 0x77, 0x02, 0xa8, 0xc1, 0x77, 0x07, 0x20, + 0xf2, 0x77, 0x03, 0x26, 0x08, 0x31, 0x69, 0x44, 0xc8, 0x77, 0x03, 0xa9, + 0xce, 0x77, 0x10, 0x21, 0x2b, 0x36, 0x6e, 0x44, 0x31, 0x70, 0x09, 0x26, + 0x21, 0x85, 0x1f, 0x31, 0x69, 0x44, 0x0e, 0x70, 0x0c, 0xa9, 0x05, 0x3e, + 0x0e, 0x70, 0x33, 0x21, 0x23, 0x80, 0x02, 0x23, 0x69, 0x44, 0x0b, 0x70, + 0x06, 0x36, 0x0d, 0xa9, 0x0e, 0x70, 0x22, 0x49, 0x35, 0x36, 0xa1, 0x86, + 0x3b, 0x21, 0x6e, 0x44, 0x30, 0x70, 0x10, 0xa8, 0x62, 0x74, 0xe2, 0x77, + 0x02, 0x70, 0x3d, 0x32, 0x69, 0x44, 0x6a, 0x44, 0x0b, 0x70, 0x13, 0x70, + 0x40, 0x21, 0x00, 0x22, 0xe3, 0x70, 0x23, 0x71, 0x63, 0x71, 0xa3, 0x73, + 0x41, 0x33, 0x6b, 0x44, 0x21, 0x87, 0x19, 0x70, 0x5a, 0x70, 0x2b, 0x7d, + 0xc0, 0x39, 0xa3, 0x70, 0xa3, 0x72, 0x63, 0x77, 0x01, 0x33, 0xdb, 0xb2, + 0xa3, 0x77, 0x6a, 0x7d, 0x0b, 0x20, 0x0d, 0x00, 0x68, 0x44, 0x15, 0x43, + 0xc5, 0x77, 0x31, 0x20, 0x68, 0x44, 0x03, 0x70, 0x3a, 0x23, 0x50, 0x1c, + 0x6b, 0x44, 0x18, 0x70, 0x41, 0x23, 0x02, 0x32, 0x0a, 0x43, 0x6b, 0x44, + 0x1a, 0x70, 0x21, 0x00, 0x42, 0x22, 0x08, 0x48, 0x00, 0xf0, 0xd8, 0xfa, + 0x12, 0xb0, 0x70, 0xbd, 0x10, 0x01, 0x04, 0x24, 0x02, 0x06, 0x05, 0x24, + 0x09, 0x04, 0x00, 0x00, 0x01, 0x02, 0x00, 0x00, 0x08, 0x0b, 0x00, 0x00, + 0x07, 0x05, 0x00, 0x00, 0xac, 0x20, 0x00, 0x20, 0x08, 0xb4, 0x02, 0x4b, + 0x9c, 0x46, 0x10, 0x38, 0x08, 0xbc, 0x60, 0x47, 0x05, 0x34, 0x00, 0x00, + 0x70, 0xb5, 0x02, 0x7d, 0x0b, 0x79, 0x0c, 0x00, 0x00, 0x25, 0x9a, 0x42, + 0x0b, 0xd1, 0x0b, 0x78, 0x4e, 0x78, 0xa1, 0x2b, 0x09, 0xd1, 0x21, 0x2e, + 0x05, 0xd1, 0x07, 0x22, 0x1f, 0x49, 0x20, 0x48, 0x00, 0xf0, 0xae, 0xfa, + 0x01, 0x35, 0x28, 0x00, 0x70, 0xbd, 0x21, 0x2b, 0xfb, 0xd1, 0x20, 0x2e, + 0x2b, 0xd1, 0x07, 0x22, 0x19, 0x49, 0x1a, 0x48, 0x00, 0xf0, 0xe4, 0xf9, + 0x17, 0x4b, 0x1a, 0x78, 0x59, 0x78, 0x09, 0x02, 0x11, 0x43, 0x9a, 0x78, + 0x12, 0x04, 0x11, 0x43, 0xda, 0x78, 0x12, 0x06, 0x0a, 0x43, 0x96, 0x21, + 0xc9, 0x00, 0x8a, 0x42, 0x1d, 0xd1, 0xdb, 0x79, 0xdb, 0x07, 0x1a, 0xd4, + 0xfa, 0x20, 0x01, 0xf0, 0xdb, 0xf9, 0x00, 0x21, 0x0d, 0x48, 0x00, 0xf0, + 0xb3, 0xfa, 0x01, 0x25, 0x23, 0x2e, 0xd8, 0xd1, 0xe3, 0x78, 0xa2, 0x78, + 0x1b, 0x02, 0x13, 0x43, 0x09, 0x4a, 0x00, 0x21, 0x07, 0x48, 0x13, 0x60, + 0x00, 0xf0, 0xa6, 0xfa, 0xcd, 0xe7, 0x22, 0x2e, 0xef, 0xd1, 0x8a, 0x78, + 0x02, 0x4b, 0xda, 0x71, 0xd2, 0xe7, 0x01, 0xf0, 0xcb, 0xf9, 0xe4, 0xe7, + 0x14, 0x00, 0x00, 0x20, 0xac, 0x20, 0x00, 0x20, 0x10, 0x00, 0x00, 0x20, + 0x08, 0xb4, 0x02, 0x4b, 0x9c, 0x46, 0x10, 0x38, 0x08, 0xbc, 0x60, 0x47, + 0x31, 0x35, 0x00, 0x00, 0x10, 0xb5, 0x41, 0x7d, 0x00, 0x6a, 0x01, 0x31, + 0x00, 0xf0, 0xd8, 0xf8, 0x03, 0x4b, 0x1b, 0x68, 0x01, 0x33, 0x5a, 0x1e, + 0x93, 0x41, 0x18, 0x18, 0x10, 0xbd, 0xc0, 0x46, 0x1c, 0x00, 0x00, 0x20, + 0x10, 0xb5, 0x41, 0x7d, 0x00, 0x6a, 0x02, 0x31, 0x00, 0xf0, 0xde, 0xf8, + 0x10, 0xbd, 0x10, 0xb5, 0x41, 0x7d, 0x00, 0x6a, 0x02, 0x31, 0x00, 0xf0, + 0xa5, 0xf8, 0x10, 0xbd, 0x70, 0xb5, 0x0d, 0x00, 0x41, 0x7d, 0x04, 0x00, + 0x13, 0x00, 0x02, 0x31, 0x2a, 0x00, 0x00, 0x6a, 0x00, 0xf0, 0x92, 0xf9, + 0x00, 0x28, 0x01, 0xd1, 0x01, 0x23, 0x63, 0x60, 0x70, 0xbd, 0x00, 0x00, + 0x10, 0xb5, 0x05, 0x4c, 0x23, 0x68, 0x5a, 0x1c, 0x04, 0xd1, 0x03, 0x68, + 0x5b, 0x69, 0x98, 0x47, 0x03, 0x00, 0x20, 0x60, 0x18, 0x00, 0x10, 0xbd, + 0x1c, 0x00, 0x00, 0x20, 0x07, 0x4a, 0x03, 0x00, 0x10, 0x68, 0x10, 0xb5, + 0x41, 0x1c, 0x03, 0xd0, 0x01, 0x23, 0x5b, 0x42, 0x13, 0x60, 0x10, 0xbd, + 0x59, 0x7d, 0x18, 0x6a, 0x01, 0x31, 0x00, 0xf0, 0x1f, 0xf9, 0xf8, 0xe7, + 0x1c, 0x00, 0x00, 0x20, 0x70, 0x47, 0x00, 0x20, 0x70, 0x47, 0x70, 0x47, + 0xfa, 0x23, 0x9b, 0x00, 0x10, 0xb5, 0x83, 0x60, 0x0f, 0x4b, 0x00, 0x22, + 0xc3, 0x82, 0x03, 0x00, 0x28, 0x33, 0x83, 0x61, 0x0d, 0x4b, 0x04, 0x00, + 0x42, 0x60, 0xc2, 0x61, 0x18, 0x00, 0x44, 0x33, 0x23, 0x61, 0x08, 0x30, + 0x63, 0x1d, 0x21, 0x62, 0x20, 0x60, 0xda, 0x77, 0x83, 0x23, 0xa3, 0x62, + 0x81, 0x3b, 0xe3, 0x62, 0x80, 0x33, 0x23, 0x63, 0x00, 0xf0, 0x40, 0xf8, + 0x21, 0x00, 0x10, 0x31, 0x00, 0xf0, 0x10, 0xf8, 0x20, 0x00, 0x10, 0xbd, + 0x03, 0x02, 0x00, 0x00, 0x2c, 0x97, 0x00, 0x00, 0x10, 0xb5, 0x02, 0x49, + 0x02, 0x48, 0xff, 0xf7, 0xd3, 0xff, 0x10, 0xbd, 0xac, 0x20, 0x00, 0x20, + 0x44, 0x20, 0x00, 0x20, 0xf0, 0xb5, 0x8c, 0x79, 0x45, 0x78, 0x03, 0x00, + 0x2a, 0x19, 0x00, 0x20, 0x07, 0x2a, 0x1f, 0xdc, 0x5a, 0x68, 0x82, 0x42, + 0x16, 0xd1, 0x59, 0x60, 0x1a, 0x78, 0xc8, 0x79, 0x0a, 0x71, 0x12, 0x18, + 0x4d, 0x71, 0x1a, 0x70, 0x00, 0x22, 0x0b, 0x4d, 0xd0, 0xb2, 0x84, 0x42, + 0x0f, 0xd9, 0x8f, 0x68, 0x58, 0x78, 0x96, 0x00, 0xf7, 0x59, 0x86, 0x00, + 0x01, 0x30, 0x77, 0x51, 0x01, 0x32, 0x58, 0x70, 0xf2, 0xe7, 0x02, 0x00, + 0xd0, 0x68, 0x00, 0x28, 0xfb, 0xd1, 0xd1, 0x60, 0xe4, 0xe7, 0x01, 0x20, + 0xf0, 0xbd, 0xc0, 0x46, 0x84, 0x20, 0x00, 0x20, 0x01, 0x21, 0x06, 0x4a, + 0x10, 0xb5, 0x13, 0x68, 0x05, 0x48, 0x0b, 0x40, 0x04, 0xd1, 0x80, 0x24, + 0x64, 0x00, 0x04, 0x80, 0x43, 0x60, 0x11, 0x60, 0x10, 0xbd, 0xc0, 0x46, + 0x78, 0x20, 0x00, 0x20, 0x7c, 0x20, 0x00, 0x20, 0x0b, 0x4b, 0xca, 0xb2, + 0x0b, 0x48, 0x89, 0x01, 0xc9, 0x18, 0x53, 0x01, 0xc3, 0x18, 0x59, 0x61, + 0x99, 0x69, 0x08, 0x32, 0x89, 0x0b, 0x89, 0x03, 0x99, 0x61, 0x03, 0x68, + 0x52, 0x01, 0x9a, 0x18, 0x02, 0x23, 0xd3, 0x71, 0x51, 0x79, 0x82, 0x3b, + 0x0b, 0x43, 0x53, 0x71, 0x70, 0x47, 0xc0, 0x46, 0xd4, 0x20, 0x00, 0x20, + 0x5c, 0x25, 0x00, 0x20, 0x08, 0x4b, 0x8a, 0x00, 0xd0, 0x58, 0x10, 0xb5, + 0x00, 0x28, 0x03, 0xd0, 0x03, 0x68, 0x9b, 0x68, 0x98, 0x47, 0x10, 0xbd, + 0xc9, 0xb2, 0x04, 0x4b, 0x49, 0x01, 0x59, 0x18, 0x88, 0x68, 0x80, 0x04, + 0x80, 0x0c, 0xf6, 0xe7, 0xb0, 0x20, 0x00, 0x20, 0x5c, 0x25, 0x00, 0x20, + 0x10, 0xb5, 0x0c, 0x00, 0xff, 0xf7, 0xe6, 0xff, 0x00, 0x28, 0x0c, 0xd0, + 0x06, 0x4b, 0xe4, 0xb2, 0x1b, 0x68, 0x08, 0x34, 0x64, 0x01, 0x1c, 0x19, + 0x80, 0x23, 0x62, 0x79, 0x5b, 0x42, 0x13, 0x43, 0x63, 0x71, 0x02, 0x23, + 0xe3, 0x71, 0x10, 0xbd, 0x5c, 0x25, 0x00, 0x20, 0xf0, 0xb5, 0x1c, 0x00, + 0x2a, 0x4b, 0x85, 0xb0, 0x1b, 0x68, 0x07, 0x00, 0x0d, 0x00, 0x02, 0x92, + 0x00, 0x2b, 0x4a, 0xd0, 0x27, 0x4b, 0x8a, 0x00, 0xd0, 0x58, 0x00, 0x28, + 0x08, 0xd0, 0x03, 0x68, 0x22, 0x00, 0x5b, 0x68, 0x02, 0x99, 0x98, 0x47, + 0x04, 0x00, 0x20, 0x00, 0x05, 0xb0, 0xf0, 0xbd, 0x38, 0x00, 0xff, 0xf7, + 0xb9, 0xff, 0x84, 0x42, 0x04, 0xd9, 0x29, 0x00, 0x38, 0x00, 0xff, 0xf7, + 0xb3, 0xff, 0x04, 0x00, 0x01, 0x21, 0xeb, 0xb2, 0x1b, 0x4e, 0x03, 0x93, + 0x5b, 0x01, 0x01, 0x93, 0xf2, 0x18, 0x93, 0x68, 0x9b, 0x0b, 0x9b, 0x03, + 0x93, 0x60, 0x01, 0x9a, 0x33, 0x68, 0x02, 0x98, 0x9b, 0x18, 0xff, 0x33, + 0x5a, 0x7a, 0x0a, 0x43, 0x5a, 0x72, 0x14, 0x4b, 0xa9, 0x01, 0xc9, 0x18, + 0x22, 0x00, 0x03, 0xf0, 0x7b, 0xf8, 0x00, 0x2c, 0xd7, 0xd0, 0x29, 0x00, + 0x38, 0x00, 0xff, 0xf7, 0x93, 0xff, 0x00, 0x28, 0xd1, 0xd1, 0x40, 0x21, + 0x03, 0x9b, 0x32, 0x68, 0x08, 0x33, 0x5b, 0x01, 0xd3, 0x18, 0x18, 0x79, + 0x01, 0x43, 0x19, 0x71, 0x01, 0x21, 0xd9, 0x71, 0x01, 0x9b, 0xd3, 0x18, + 0xff, 0x33, 0x9a, 0x7a, 0x0a, 0x43, 0x9a, 0x72, 0xbf, 0xe7, 0x01, 0x24, + 0x64, 0x42, 0xbc, 0xe7, 0x58, 0x25, 0x00, 0x20, 0xb0, 0x20, 0x00, 0x20, + 0x5c, 0x25, 0x00, 0x20, 0x94, 0x22, 0x00, 0x20, 0x13, 0xb5, 0x6b, 0x46, + 0xdc, 0x1d, 0x22, 0x00, 0x01, 0x23, 0xff, 0xf7, 0x99, 0xff, 0x01, 0x28, + 0x01, 0xd1, 0x20, 0x78, 0x16, 0xbd, 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, + 0x70, 0xb5, 0xcb, 0xb2, 0x12, 0x4a, 0x13, 0x48, 0x5c, 0x01, 0x89, 0x01, + 0x89, 0x18, 0x02, 0x19, 0x51, 0x60, 0x91, 0x68, 0x10, 0x4d, 0x08, 0x33, + 0x0d, 0x40, 0x80, 0x21, 0x49, 0x03, 0x29, 0x43, 0x40, 0x25, 0x91, 0x60, + 0x91, 0x68, 0x89, 0x0b, 0x89, 0x03, 0x91, 0x60, 0x01, 0x68, 0x5a, 0x01, + 0x8a, 0x18, 0x16, 0x79, 0x35, 0x43, 0x15, 0x71, 0x95, 0x79, 0x6d, 0x06, + 0xfc, 0xd5, 0x5b, 0x01, 0xc9, 0x18, 0xcb, 0x79, 0xdb, 0x07, 0xfc, 0xd5, + 0x00, 0x19, 0x80, 0x68, 0xc0, 0xb2, 0x70, 0xbd, 0x94, 0x22, 0x00, 0x20, + 0x5c, 0x25, 0x00, 0x20, 0xff, 0x3f, 0x00, 0xf0, 0x70, 0xb5, 0x0d, 0x00, + 0x00, 0x21, 0x14, 0x00, 0xff, 0xf7, 0xcc, 0xff, 0xa0, 0x42, 0x00, 0xd9, + 0x20, 0x00, 0x00, 0x23, 0x03, 0x49, 0xa3, 0x42, 0x03, 0xd0, 0xca, 0x5c, + 0xea, 0x54, 0x01, 0x33, 0xf9, 0xe7, 0x70, 0xbd, 0x94, 0x22, 0x00, 0x20, + 0xf0, 0xb5, 0x1e, 0x00, 0x3a, 0x4b, 0x85, 0xb0, 0x1b, 0x68, 0x0f, 0x00, + 0x01, 0x92, 0x00, 0x2b, 0x35, 0xd0, 0x80, 0x23, 0xdb, 0x01, 0x9e, 0x42, + 0x31, 0xd8, 0x00, 0x25, 0x35, 0x4b, 0x8a, 0x01, 0xd3, 0x18, 0x02, 0x93, + 0x00, 0x2e, 0x2c, 0xd0, 0x33, 0x4b, 0x1b, 0x68, 0x03, 0x93, 0xff, 0x23, + 0x3b, 0x40, 0x1c, 0x00, 0x00, 0x93, 0x08, 0x34, 0x03, 0x9b, 0x64, 0x01, + 0x1c, 0x19, 0xa3, 0x79, 0xdb, 0x09, 0x21, 0xd0, 0x2d, 0x4b, 0x2e, 0x49, + 0x18, 0x68, 0x01, 0xf0, 0x31, 0xf8, 0x2d, 0x4b, 0x17, 0x21, 0x58, 0x43, + 0x01, 0xf0, 0x2c, 0xf8, 0x2b, 0x4b, 0xe2, 0x79, 0x92, 0x07, 0x13, 0xd4, + 0xda, 0x5d, 0x00, 0x2a, 0x01, 0xd1, 0x01, 0x38, 0xf7, 0xd2, 0x01, 0x22, + 0xda, 0x55, 0x00, 0x9b, 0x5a, 0x01, 0x21, 0x4b, 0x9b, 0x18, 0x9a, 0x69, + 0x92, 0x0b, 0x92, 0x03, 0x9a, 0x61, 0x01, 0x25, 0x6d, 0x42, 0x28, 0x00, + 0x05, 0xb0, 0xf0, 0xbd, 0x00, 0x22, 0x1f, 0x4b, 0x34, 0x00, 0xda, 0x55, + 0x3f, 0x2e, 0x09, 0xd9, 0x00, 0x9b, 0x40, 0x24, 0x5a, 0x01, 0x17, 0x4b, + 0x9b, 0x18, 0x80, 0x22, 0x99, 0x69, 0x12, 0x06, 0x0a, 0x43, 0x9a, 0x61, + 0x22, 0x00, 0x01, 0x99, 0x02, 0x98, 0x02, 0xf0, 0xad, 0xff, 0x00, 0x9b, + 0xa1, 0x04, 0x5a, 0x01, 0x0f, 0x4b, 0x89, 0x0c, 0x9b, 0x18, 0x02, 0x9a, + 0x2d, 0x19, 0x5a, 0x61, 0x9a, 0x69, 0x36, 0x1b, 0x92, 0x0b, 0x92, 0x03, + 0x0a, 0x43, 0x9a, 0x61, 0x00, 0x9b, 0x03, 0x9a, 0x08, 0x33, 0x5b, 0x01, + 0xd3, 0x18, 0x02, 0x22, 0xda, 0x71, 0x59, 0x79, 0x82, 0x3a, 0x0a, 0x43, + 0x5a, 0x71, 0x01, 0x9b, 0x1b, 0x19, 0x01, 0x93, 0x9a, 0xe7, 0xc0, 0x46, + 0x58, 0x25, 0x00, 0x20, 0xd4, 0x20, 0x00, 0x20, 0x5c, 0x25, 0x00, 0x20, + 0x20, 0x00, 0x00, 0x20, 0x40, 0x42, 0x0f, 0x00, 0x70, 0x11, 0x01, 0x00, + 0xcc, 0x20, 0x00, 0x20, 0x70, 0xb5, 0x0d, 0x00, 0x1c, 0x00, 0x0d, 0x4b, + 0xae, 0x01, 0xf6, 0x18, 0x11, 0x00, 0x30, 0x00, 0x22, 0x00, 0x02, 0xf0, + 0x75, 0xff, 0xed, 0xb2, 0x09, 0x49, 0x6d, 0x01, 0x4d, 0x19, 0x6e, 0x61, + 0xab, 0x69, 0x08, 0x4a, 0x20, 0x00, 0x13, 0x40, 0xab, 0x61, 0xab, 0x69, + 0xa2, 0x04, 0x9b, 0x0b, 0x92, 0x0c, 0x9b, 0x03, 0x13, 0x43, 0xab, 0x61, + 0x70, 0xbd, 0xc0, 0x46, 0xd4, 0x20, 0x00, 0x20, 0x5c, 0x25, 0x00, 0x20, + 0xff, 0x3f, 0x00, 0xf0, 0xf7, 0xb5, 0x10, 0x4b, 0x01, 0x90, 0x1b, 0x78, + 0x0f, 0x00, 0x15, 0x00, 0x00, 0x2b, 0x0c, 0xd1, 0x0d, 0x4b, 0x16, 0x00, + 0x1c, 0x78, 0x00, 0x2c, 0x09, 0xd0, 0x0c, 0x4e, 0x0c, 0x48, 0x34, 0x88, + 0x20, 0x18, 0x64, 0x19, 0x02, 0xf0, 0x48, 0xff, 0x34, 0x80, 0x28, 0x00, + 0xfe, 0xbd, 0x00, 0x2e, 0xfb, 0xd0, 0x3a, 0x19, 0x33, 0x00, 0x00, 0x21, + 0x01, 0x98, 0xff, 0xf7, 0xbd, 0xff, 0x24, 0x18, 0x36, 0x1a, 0xf4, 0xe7, + 0x54, 0x24, 0x00, 0x20, 0x55, 0x25, 0x00, 0x20, 0x56, 0x25, 0x00, 0x20, + 0x55, 0x24, 0x00, 0x20, 0xcb, 0xb2, 0x04, 0x49, 0x5b, 0x01, 0xc9, 0x18, + 0x8b, 0x69, 0x9b, 0x0b, 0x9b, 0x03, 0x8b, 0x61, 0x70, 0x47, 0xc0, 0x46, + 0x5c, 0x25, 0x00, 0x20, 0x01, 0x4b, 0x02, 0x4a, 0x1a, 0x60, 0x70, 0x47, + 0x5c, 0x25, 0x00, 0x20, 0x00, 0x50, 0x00, 0x41, 0x01, 0x20, 0x70, 0x47, + 0x10, 0xb5, 0x03, 0x68, 0x01, 0x4a, 0x1b, 0x6a, 0x98, 0x47, 0x10, 0xbd, + 0x13, 0x04, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, 0xd9, 0x69, 0x9a, 0x69, + 0x91, 0x42, 0x03, 0xd0, 0xdb, 0x69, 0xc0, 0x18, 0x00, 0x7d, 0x70, 0x47, + 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x69, + 0xff, 0xf7, 0x22, 0xfb, 0x22, 0x00, 0x00, 0x23, 0xfc, 0x32, 0x93, 0x61, + 0xd3, 0x61, 0x86, 0x22, 0x92, 0x00, 0xa4, 0x18, 0x63, 0x60, 0xa3, 0x60, + 0x10, 0xbd, 0xf0, 0x20, 0x01, 0x40, 0x30, 0x39, 0x48, 0x42, 0x48, 0x41, + 0x70, 0x47, 0xf0, 0x23, 0x1b, 0x01, 0x19, 0x40, 0x80, 0x23, 0x06, 0x20, + 0x9b, 0x00, 0x99, 0x42, 0x0a, 0xd0, 0x01, 0x33, 0xff, 0x33, 0x01, 0x30, + 0x99, 0x42, 0x05, 0xd0, 0x80, 0x23, 0x02, 0x38, 0x5b, 0x00, 0x99, 0x42, + 0x00, 0xd0, 0x00, 0x20, 0x70, 0x47, 0x0f, 0x20, 0x01, 0x40, 0x00, 0x20, + 0x01, 0x29, 0x03, 0xd0, 0x02, 0x39, 0x48, 0x1e, 0x81, 0x41, 0x48, 0x1c, + 0x70, 0x47, 0x00, 0x00, 0x89, 0x23, 0xf0, 0xb5, 0x18, 0x26, 0x85, 0xb0, + 0x02, 0x91, 0x9b, 0x00, 0x04, 0x00, 0xc0, 0x5c, 0x33, 0x00, 0x08, 0x21, + 0x43, 0x43, 0x32, 0x4d, 0x17, 0x00, 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, + 0x53, 0xfe, 0x30, 0x4b, 0x08, 0x21, 0xe0, 0x5c, 0x33, 0x00, 0x43, 0x43, + 0xeb, 0x18, 0x59, 0x56, 0x00, 0xf0, 0x4a, 0xfe, 0x2c, 0x4b, 0xe2, 0x5c, + 0x03, 0x93, 0x02, 0x2a, 0x09, 0xd1, 0x11, 0x33, 0xe0, 0x5c, 0xff, 0x28, + 0x05, 0xd0, 0x08, 0x21, 0x46, 0x43, 0xae, 0x19, 0x71, 0x56, 0x00, 0xf0, + 0x3b, 0xfe, 0x8a, 0x26, 0xb6, 0x00, 0xa0, 0x5d, 0xff, 0x28, 0x19, 0xd0, + 0x01, 0x21, 0x00, 0xf0, 0xbb, 0xfd, 0x18, 0x22, 0xa3, 0x5d, 0x21, 0x49, + 0x5a, 0x43, 0xab, 0x56, 0xad, 0x18, 0xdb, 0x01, 0x58, 0x18, 0x8b, 0x21, + 0x89, 0x00, 0x60, 0x50, 0x1d, 0x49, 0x01, 0x22, 0x5b, 0x18, 0x8c, 0x21, + 0x89, 0x00, 0x63, 0x50, 0x69, 0x68, 0x8a, 0x40, 0x8d, 0x21, 0x89, 0x00, + 0x62, 0x50, 0x1a, 0x60, 0x01, 0x22, 0x02, 0x9b, 0x11, 0x00, 0x20, 0x69, + 0xff, 0xf7, 0x50, 0xfb, 0x39, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x8f, 0xff, + 0x39, 0x00, 0x05, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x9e, 0xff, 0x39, 0x00, + 0x06, 0x00, 0x20, 0x00, 0xff, 0xf7, 0x7f, 0xff, 0x33, 0x00, 0x00, 0x90, + 0x29, 0x00, 0x20, 0x69, 0x01, 0x22, 0xff, 0xf7, 0x5f, 0xfa, 0x0b, 0x4b, + 0x20, 0x69, 0xe2, 0x5c, 0x03, 0x9b, 0xe1, 0x5c, 0xff, 0xf7, 0x75, 0xfa, + 0x20, 0x69, 0xff, 0xf7, 0x92, 0xfa, 0x05, 0xb0, 0xf0, 0xbd, 0xc0, 0x46, + 0xc0, 0x93, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, 0x27, 0x02, 0x00, 0x00, + 0x18, 0x44, 0x00, 0x41, 0x14, 0x44, 0x00, 0x41, 0x26, 0x02, 0x00, 0x00, + 0x80, 0x22, 0x10, 0xb5, 0x04, 0x00, 0x52, 0x00, 0x00, 0x21, 0x02, 0xf0, + 0x6b, 0xfe, 0x23, 0x00, 0x00, 0x22, 0xfc, 0x33, 0x5a, 0x60, 0x20, 0x00, + 0x9a, 0x60, 0x10, 0xbd, 0xf0, 0xb5, 0x85, 0xb0, 0x1d, 0x00, 0x0a, 0xab, + 0x1b, 0x78, 0x04, 0x00, 0x00, 0x93, 0x0b, 0xab, 0x1b, 0x78, 0x16, 0x00, + 0x01, 0x93, 0x0c, 0xab, 0x1b, 0x78, 0x0f, 0x00, 0x02, 0x93, 0x0d, 0xab, + 0x1b, 0x78, 0x03, 0x93, 0x00, 0x23, 0x43, 0x60, 0xfa, 0x23, 0x9b, 0x00, + 0x83, 0x60, 0x12, 0x4b, 0x08, 0x33, 0x03, 0x60, 0x14, 0x30, 0xff, 0xf7, + 0xd5, 0xff, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0xd0, 0xff, + 0x89, 0x23, 0x6a, 0x46, 0x9b, 0x00, 0x27, 0x61, 0xe6, 0x54, 0x0b, 0x4b, + 0x12, 0x78, 0xe5, 0x54, 0x0a, 0x4b, 0x20, 0x00, 0xe2, 0x54, 0x6a, 0x46, + 0x09, 0x4b, 0x12, 0x79, 0xe2, 0x54, 0x6a, 0x46, 0x12, 0x7a, 0x01, 0x33, + 0xe2, 0x54, 0x6a, 0x46, 0x12, 0x7b, 0x10, 0x33, 0xe2, 0x54, 0x05, 0xb0, + 0xf0, 0xbd, 0xc0, 0x46, 0x84, 0x97, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, + 0x26, 0x02, 0x00, 0x00, 0x27, 0x02, 0x00, 0x00, 0xf7, 0xb5, 0x1d, 0x00, + 0x08, 0xab, 0x1b, 0x78, 0x04, 0x00, 0x00, 0x93, 0x09, 0xab, 0x1b, 0x78, + 0x16, 0x00, 0x01, 0x93, 0x00, 0x23, 0x43, 0x60, 0xfa, 0x23, 0x9b, 0x00, + 0x83, 0x60, 0x11, 0x4b, 0x0f, 0x00, 0x08, 0x33, 0x03, 0x60, 0x14, 0x30, + 0xff, 0xf7, 0x98, 0xff, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, + 0x93, 0xff, 0x89, 0x23, 0x6a, 0x46, 0x9b, 0x00, 0x27, 0x61, 0xe6, 0x54, + 0x09, 0x4b, 0x12, 0x78, 0xe5, 0x54, 0x09, 0x4b, 0x20, 0x00, 0xe2, 0x54, + 0x6a, 0x46, 0x08, 0x4b, 0x12, 0x79, 0xe2, 0x54, 0x8a, 0x22, 0x29, 0x3b, + 0xff, 0x3b, 0x92, 0x00, 0xa3, 0x54, 0x10, 0x32, 0xa3, 0x54, 0xfe, 0xbd, + 0x84, 0x97, 0x00, 0x00, 0x25, 0x02, 0x00, 0x00, 0x26, 0x02, 0x00, 0x00, + 0x27, 0x02, 0x00, 0x00, 0x03, 0x00, 0xfc, 0x33, 0x58, 0x68, 0x9b, 0x68, + 0xc0, 0x1a, 0x01, 0xd5, 0x01, 0x30, 0xff, 0x30, 0x70, 0x47, 0x10, 0xb5, + 0x04, 0x00, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0xf0, 0xff, + 0x00, 0x28, 0xf8, 0xd1, 0x20, 0x69, 0xff, 0xf7, 0xec, 0xf9, 0x10, 0xbd, + 0x10, 0xb5, 0x14, 0x30, 0xff, 0xf7, 0xe6, 0xff, 0x10, 0xbd, 0x03, 0x00, + 0xfc, 0x33, 0x59, 0x68, 0x9a, 0x68, 0x91, 0x42, 0x04, 0xdb, 0x5a, 0x68, + 0x98, 0x68, 0x80, 0x1a, 0xff, 0x30, 0x70, 0x47, 0x98, 0x68, 0x5b, 0x68, + 0xc0, 0x1a, 0x01, 0x38, 0xf9, 0xe7, 0x10, 0xb5, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0xeb, 0xff, 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x69, + 0xff, 0xf7, 0xe7, 0xf9, 0x00, 0x28, 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, + 0xf2, 0xf9, 0x20, 0x69, 0xff, 0xf7, 0xe4, 0xf9, 0x20, 0x69, 0xff, 0xf7, + 0xcc, 0xf9, 0x00, 0x28, 0x20, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0xe7, 0xf9, + 0x22, 0x00, 0xfc, 0x32, 0x93, 0x69, 0xd1, 0x69, 0x01, 0x33, 0xdb, 0xb2, + 0x8b, 0x42, 0x03, 0xd0, 0x91, 0x69, 0x61, 0x18, 0x08, 0x75, 0x93, 0x61, + 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, 0x20, 0x00, + 0x14, 0x30, 0xff, 0xf7, 0xc0, 0xff, 0x09, 0x28, 0x06, 0xdc, 0x8b, 0x23, + 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, 0x1a, 0x60, + 0x20, 0x69, 0xff, 0xf7, 0xc1, 0xf9, 0x00, 0x28, 0x1a, 0xd0, 0x20, 0x00, + 0x1d, 0x30, 0xff, 0x30, 0xff, 0xf7, 0x92, 0xff, 0x00, 0x28, 0x22, 0xd0, + 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x99, 0x68, 0x5a, 0x68, 0x91, 0x42, + 0x18, 0xd0, 0x8e, 0x21, 0x9a, 0x68, 0x49, 0x00, 0xa2, 0x18, 0x51, 0x5c, + 0x9a, 0x68, 0x01, 0x32, 0xd2, 0xb2, 0x9a, 0x60, 0xc9, 0xb2, 0x20, 0x69, + 0xff, 0xf7, 0xad, 0xf9, 0x20, 0x69, 0xff, 0xf7, 0x8b, 0xf9, 0x00, 0x28, + 0x05, 0xd0, 0x20, 0x69, 0xff, 0xf7, 0x8a, 0xf9, 0x20, 0x69, 0xff, 0xf7, + 0x7a, 0xf9, 0x10, 0xbd, 0x01, 0x21, 0x49, 0x42, 0xec, 0xe7, 0x20, 0x69, + 0xff, 0xf7, 0xa7, 0xf9, 0xec, 0xe7, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x00, + 0x00, 0x69, 0x0d, 0x00, 0xff, 0xf7, 0x8a, 0xf9, 0x00, 0x28, 0x3e, 0xd1, + 0xff, 0x26, 0x86, 0x23, 0x9b, 0x00, 0xe3, 0x18, 0x5a, 0x68, 0x99, 0x68, + 0x01, 0x32, 0x32, 0x40, 0x8a, 0x42, 0x23, 0xd1, 0xef, 0xf3, 0x10, 0x83, + 0xdb, 0x07, 0x10, 0xd4, 0x1e, 0x4b, 0x5b, 0x68, 0xdb, 0x05, 0xdb, 0x0d, + 0xed, 0xd0, 0x10, 0x3b, 0x5b, 0xb2, 0x00, 0x2b, 0x10, 0xda, 0x0f, 0x22, + 0x13, 0x40, 0x08, 0x3b, 0x9b, 0x08, 0x19, 0x4a, 0x9b, 0x00, 0x9b, 0x18, + 0x1b, 0x68, 0x20, 0x69, 0xff, 0xf7, 0x66, 0xf9, 0x00, 0x28, 0xdc, 0xd0, + 0x20, 0x00, 0xff, 0xf7, 0x6a, 0xff, 0xd8, 0xe7, 0x9b, 0x08, 0xc0, 0x33, + 0x12, 0x4a, 0x9b, 0x00, 0x9b, 0x58, 0xf0, 0xe7, 0x5a, 0x68, 0x01, 0x32, + 0x16, 0x40, 0x9a, 0x68, 0x96, 0x42, 0x05, 0xd0, 0x8e, 0x21, 0x5a, 0x68, + 0x49, 0x00, 0xa2, 0x18, 0x55, 0x54, 0x5e, 0x60, 0x20, 0x69, 0xff, 0xf7, + 0x5c, 0xf9, 0x01, 0x20, 0x70, 0xbd, 0x20, 0x00, 0x1d, 0x30, 0xff, 0x30, + 0xff, 0xf7, 0x1c, 0xff, 0x00, 0x28, 0xb9, 0xd1, 0x29, 0x00, 0x20, 0x69, + 0xff, 0xf7, 0x47, 0xf9, 0xf1, 0xe7, 0xc0, 0x46, 0x00, 0xed, 0x00, 0xe0, + 0x1c, 0xed, 0x00, 0xe0, 0x00, 0xe1, 0x00, 0xe0, 0x03, 0x00, 0x70, 0xb5, + 0xfc, 0x33, 0xd9, 0x69, 0x9a, 0x69, 0x04, 0x00, 0x91, 0x42, 0x1a, 0xd0, + 0xda, 0x69, 0x82, 0x18, 0x15, 0x7d, 0xda, 0x69, 0x01, 0x32, 0xd2, 0xb2, + 0xda, 0x61, 0x8a, 0x23, 0x9b, 0x00, 0xe3, 0x5c, 0xff, 0x2b, 0x0c, 0xd0, + 0x20, 0x00, 0x14, 0x30, 0xff, 0xf7, 0x11, 0xff, 0x0a, 0x28, 0x06, 0xdd, + 0x8c, 0x23, 0x8d, 0x22, 0x9b, 0x00, 0x92, 0x00, 0xe3, 0x58, 0xa2, 0x58, + 0x1a, 0x60, 0x28, 0x00, 0x70, 0xbd, 0x01, 0x25, 0x6d, 0x42, 0xe8, 0xe7, + 0x10, 0xb5, 0x04, 0x00, 0x00, 0x68, 0x02, 0xf0, 0x91, 0xfc, 0x20, 0x00, + 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x68, 0x00, 0x28, 0x01, 0xd0, + 0x02, 0xf0, 0x88, 0xfc, 0x00, 0x23, 0x23, 0x60, 0xa3, 0x60, 0x63, 0x60, + 0x10, 0xbd, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x00, 0x68, 0x01, 0x31, + 0x03, 0xf0, 0xc2, 0xf9, 0x03, 0x1e, 0x01, 0xd0, 0x01, 0x20, 0x28, 0xc4, + 0x70, 0xbd, 0x03, 0x68, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x2b, 0x04, 0xd0, + 0x43, 0x68, 0x8b, 0x42, 0x01, 0xd3, 0x01, 0x20, 0x10, 0xbd, 0x20, 0x00, + 0xff, 0xf7, 0xe7, 0xff, 0x00, 0x28, 0xf9, 0xd0, 0xa3, 0x68, 0x00, 0x2b, + 0xf5, 0xd1, 0x22, 0x68, 0x13, 0x70, 0xf2, 0xe7, 0x70, 0xb5, 0x0e, 0x00, + 0x11, 0x00, 0x04, 0x00, 0x15, 0x00, 0xff, 0xf7, 0xe4, 0xff, 0x00, 0x28, + 0x04, 0xd1, 0x20, 0x00, 0xff, 0xf7, 0xc7, 0xff, 0x20, 0x00, 0x70, 0xbd, + 0xa5, 0x60, 0x31, 0x00, 0x20, 0x68, 0x03, 0xf0, 0xc9, 0xf9, 0xf7, 0xe7, + 0x00, 0x23, 0x70, 0xb5, 0x04, 0x00, 0x0d, 0x00, 0x03, 0x60, 0x43, 0x60, + 0x83, 0x60, 0x99, 0x42, 0x07, 0xd0, 0x08, 0x00, 0x03, 0xf0, 0xc4, 0xf9, + 0x29, 0x00, 0x02, 0x00, 0x20, 0x00, 0xff, 0xf7, 0xdb, 0xff, 0x20, 0x00, + 0x70, 0xbd, 0x70, 0xb5, 0x05, 0x00, 0x08, 0x00, 0x0c, 0x00, 0x03, 0xf0, + 0xb7, 0xf9, 0x21, 0x00, 0x02, 0x00, 0x28, 0x00, 0xff, 0xf7, 0xce, 0xff, + 0x70, 0xbd, 0x70, 0xb5, 0x05, 0x00, 0x00, 0x68, 0x0c, 0x00, 0x00, 0x28, + 0x0f, 0xd0, 0x09, 0x68, 0x00, 0x29, 0x0a, 0xd0, 0x6b, 0x68, 0xa2, 0x68, + 0x93, 0x42, 0x06, 0xd3, 0x03, 0xf0, 0x9a, 0xf9, 0xa3, 0x68, 0xab, 0x60, + 0x00, 0x23, 0xa3, 0x60, 0x70, 0xbd, 0x02, 0xf0, 0x19, 0xfc, 0x23, 0x68, + 0x2b, 0x60, 0x63, 0x68, 0x6b, 0x60, 0xa3, 0x68, 0xab, 0x60, 0x00, 0x23, + 0x23, 0x60, 0x63, 0x60, 0xf1, 0xe7, 0x10, 0xb5, 0x0b, 0x00, 0x04, 0x00, + 0x88, 0x42, 0x05, 0xd0, 0x09, 0x68, 0x00, 0x29, 0x04, 0xd0, 0x9a, 0x68, + 0xff, 0xf7, 0xa2, 0xff, 0x20, 0x00, 0x10, 0xbd, 0xff, 0xf7, 0x71, 0xff, + 0xfa, 0xe7, 0x00, 0x23, 0x10, 0xb5, 0x04, 0x00, 0x03, 0x60, 0x43, 0x60, + 0x83, 0x60, 0xff, 0xf7, 0xe8, 0xff, 0x20, 0x00, 0x10, 0xbd, 0x10, 0xb5, + 0x04, 0x00, 0x88, 0x42, 0x01, 0xd0, 0xff, 0xf7, 0xc0, 0xff, 0x20, 0x00, + 0x10, 0xbd, 0x10, 0xb5, 0x04, 0x00, 0x00, 0x29, 0x03, 0xd0, 0xff, 0xf7, + 0xac, 0xff, 0x20, 0x00, 0x10, 0xbd, 0xff, 0xf7, 0x54, 0xff, 0xfa, 0xe7, + 0xf8, 0xb5, 0x04, 0x00, 0x0f, 0x1e, 0x02, 0xd1, 0x00, 0x26, 0x30, 0x00, + 0xf8, 0xbd, 0x01, 0x26, 0x00, 0x2a, 0xfa, 0xd0, 0x83, 0x68, 0xd5, 0x18, + 0x29, 0x00, 0xff, 0xf7, 0x5c, 0xff, 0x00, 0x28, 0xf2, 0xd0, 0x23, 0x68, + 0xa2, 0x68, 0x39, 0x00, 0x98, 0x18, 0x03, 0xf0, 0x45, 0xf9, 0xa5, 0x60, + 0xeb, 0xe7, 0x07, 0xb5, 0x00, 0x22, 0x01, 0xab, 0x19, 0x70, 0x5a, 0x70, + 0x19, 0x00, 0x01, 0x32, 0xff, 0xf7, 0xde, 0xff, 0x0e, 0xbd, 0x70, 0xb5, + 0x83, 0x68, 0x8d, 0x68, 0x5c, 0x1b, 0x00, 0x23, 0x94, 0x42, 0x0c, 0xd3, + 0x00, 0x68, 0x98, 0x42, 0x09, 0xd0, 0x09, 0x68, 0x99, 0x42, 0x06, 0xd0, + 0x80, 0x18, 0x2a, 0x00, 0x03, 0xf0, 0x37, 0xf9, 0x43, 0x42, 0x43, 0x41, + 0xdb, 0xb2, 0x18, 0x00, 0x70, 0xbd, 0x83, 0x68, 0x10, 0xb5, 0x9c, 0x46, + 0x8b, 0x68, 0x00, 0x22, 0x9c, 0x45, 0x02, 0xd3, 0xff, 0xf7, 0xe1, 0xff, + 0x02, 0x00, 0x10, 0x00, 0x10, 0xbd, 0x10, 0xb5, 0x82, 0x68, 0x8c, 0x68, + 0x00, 0x23, 0xa2, 0x42, 0x0c, 0xd3, 0x00, 0x68, 0x98, 0x42, 0x09, 0xd0, + 0x09, 0x68, 0x99, 0x42, 0x06, 0xd0, 0x12, 0x1b, 0x80, 0x18, 0x03, 0xf0, + 0xfd, 0xf8, 0x43, 0x42, 0x43, 0x41, 0xdb, 0xb2, 0x18, 0x00, 0x10, 0xbd, + 0x83, 0x68, 0x8b, 0x42, 0x03, 0xd9, 0x03, 0x68, 0x58, 0x18, 0x00, 0x2b, + 0x02, 0xd1, 0x00, 0x23, 0x01, 0x48, 0x03, 0x70, 0x70, 0x47, 0xc0, 0x46, + 0x60, 0x26, 0x00, 0x20, 0x83, 0x68, 0x10, 0xb5, 0x93, 0x42, 0x07, 0xd9, + 0x04, 0x68, 0xa0, 0x18, 0x03, 0xf0, 0xd4, 0xf8, 0x00, 0x28, 0x01, 0xd0, + 0x00, 0x1b, 0x10, 0xbd, 0x01, 0x20, 0x40, 0x42, 0xfb, 0xe7, 0x10, 0xb5, + 0x00, 0x22, 0xff, 0xf7, 0xed, 0xff, 0x10, 0xbd, 0xf7, 0xb5, 0x15, 0x00, + 0x8a, 0x68, 0x0f, 0x00, 0x00, 0x2a, 0x1b, 0xd0, 0x83, 0x68, 0x00, 0x2b, + 0x18, 0xd0, 0x9a, 0x42, 0x16, 0xd8, 0xab, 0x42, 0x00, 0xd8, 0x5d, 0x1e, + 0x06, 0x68, 0x01, 0x24, 0x30, 0x00, 0x73, 0x19, 0x64, 0x42, 0x01, 0x93, + 0x01, 0x9b, 0x98, 0x42, 0x0c, 0xd8, 0x39, 0x68, 0x03, 0xf0, 0xfa, 0xf8, + 0x00, 0x28, 0x07, 0xd0, 0x83, 0x1b, 0xab, 0x42, 0x00, 0xd8, 0x1c, 0x00, + 0x01, 0x30, 0xf1, 0xe7, 0x01, 0x24, 0x64, 0x42, 0x20, 0x00, 0xfe, 0xbd, + 0x10, 0xb5, 0x83, 0x68, 0x8a, 0x68, 0x9a, 0x1a, 0xff, 0xf7, 0xd4, 0xff, + 0x10, 0xbd, 0x00, 0x00, 0xf7, 0xb5, 0x0e, 0x00, 0x01, 0x90, 0x14, 0x00, + 0x1d, 0x00, 0x9a, 0x42, 0x01, 0xd9, 0x2c, 0x00, 0x15, 0x00, 0x0c, 0x49, + 0x01, 0x98, 0xff, 0xf7, 0xdd, 0xfe, 0xb7, 0x68, 0xa7, 0x42, 0x0e, 0xd9, + 0xaf, 0x42, 0x00, 0xd9, 0x2f, 0x00, 0x00, 0x22, 0x33, 0x68, 0x01, 0x98, + 0xdb, 0x19, 0x1d, 0x78, 0x1a, 0x70, 0x33, 0x68, 0x19, 0x19, 0xff, 0xf7, + 0x2e, 0xff, 0x33, 0x68, 0xdd, 0x55, 0x01, 0x98, 0xfe, 0xbd, 0xc0, 0x46, + 0x7a, 0x93, 0x00, 0x00, 0x70, 0xb5, 0x85, 0x68, 0x04, 0x00, 0x8d, 0x42, + 0x13, 0xd9, 0x00, 0x2a, 0x11, 0xd0, 0x6b, 0x1a, 0x93, 0x42, 0x00, 0xd9, + 0x13, 0x00, 0x20, 0x68, 0xed, 0x1a, 0xcb, 0x18, 0xc3, 0x18, 0x6a, 0x1a, + 0x40, 0x18, 0xa5, 0x60, 0x19, 0x00, 0x03, 0xf0, 0x99, 0xf8, 0x00, 0x21, + 0x22, 0x68, 0xa3, 0x68, 0xd1, 0x54, 0x70, 0xbd, 0x01, 0x22, 0x10, 0xb5, + 0x52, 0x42, 0xff, 0xf7, 0xe1, 0xff, 0x10, 0xbd, 0xf8, 0xb5, 0x07, 0x68, + 0x06, 0x00, 0x00, 0x2f, 0x22, 0xd0, 0x84, 0x68, 0x00, 0x2c, 0x1f, 0xd0, + 0x3d, 0x00, 0x28, 0x78, 0x02, 0xf0, 0xc4, 0xfa, 0x00, 0x28, 0x01, 0xd0, + 0x01, 0x35, 0xf8, 0xe7, 0x01, 0x3c, 0x3c, 0x19, 0x20, 0x78, 0x02, 0xf0, + 0xbb, 0xfa, 0x00, 0x28, 0x03, 0xd0, 0xa5, 0x42, 0x01, 0xd8, 0x01, 0x3c, + 0xf6, 0xe7, 0x01, 0x34, 0x62, 0x1b, 0xb2, 0x60, 0xaf, 0x42, 0x03, 0xd2, + 0x29, 0x00, 0x38, 0x00, 0x02, 0xf0, 0xec, 0xfa, 0x00, 0x21, 0x32, 0x68, + 0xb3, 0x68, 0xd1, 0x54, 0xf8, 0xbd, 0x03, 0x68, 0x00, 0x20, 0x10, 0xb5, + 0x83, 0x42, 0x02, 0xd0, 0x18, 0x00, 0x02, 0xf0, 0x67, 0xfa, 0x10, 0xbd, + 0xfe, 0xe7, 0x00, 0x00, 0x03, 0x4b, 0x10, 0xb5, 0x1b, 0x68, 0x00, 0x2b, + 0x00, 0xd0, 0x98, 0x47, 0x10, 0xbd, 0xc0, 0x46, 0x64, 0x26, 0x00, 0x20, + 0x70, 0xb5, 0x0f, 0x49, 0x0f, 0x4c, 0xa1, 0x42, 0x04, 0xd1, 0x00, 0xf0, + 0x8b, 0xf8, 0xfd, 0xf7, 0x9b, 0xfe, 0xfe, 0xe7, 0x0c, 0x4d, 0x00, 0x23, + 0x8d, 0x42, 0xf6, 0xd0, 0xca, 0x18, 0xe8, 0x18, 0xa2, 0x42, 0x05, 0xd3, + 0x09, 0x4b, 0x82, 0x42, 0xef, 0xd0, 0x09, 0x49, 0x00, 0x22, 0x04, 0xe0, + 0x00, 0x68, 0x04, 0x33, 0x10, 0x60, 0xf1, 0xe7, 0x04, 0xc3, 0x8b, 0x42, + 0xfc, 0xd3, 0xe4, 0xe7, 0x00, 0x00, 0x00, 0x20, 0x40, 0x02, 0x00, 0x20, + 0xfc, 0x9a, 0x00, 0x00, 0x40, 0x02, 0x00, 0x20, 0x7c, 0x26, 0x00, 0x20, + 0x10, 0xb5, 0x00, 0xf0, 0x5e, 0xf8, 0x00, 0x28, 0x01, 0xd1, 0x00, 0xf0, + 0x4f, 0xf8, 0x10, 0xbd, 0x01, 0x4b, 0x18, 0x68, 0x70, 0x47, 0xc0, 0x46, + 0x68, 0x26, 0x00, 0x20, 0xf7, 0xb5, 0x13, 0x48, 0x01, 0x22, 0x84, 0x46, + 0x12, 0x49, 0x13, 0x4c, 0x8e, 0x68, 0x63, 0x68, 0x05, 0x68, 0x9b, 0x0e, + 0x13, 0x40, 0x01, 0x92, 0x88, 0x68, 0x62, 0x68, 0x01, 0x9f, 0x92, 0x0e, + 0x3a, 0x40, 0x67, 0x46, 0x3f, 0x68, 0x93, 0x42, 0x0e, 0xd1, 0xbd, 0x42, + 0x0c, 0xd1, 0x86, 0x42, 0x0a, 0xd3, 0x5b, 0x19, 0xfa, 0x25, 0x48, 0x68, + 0xad, 0x00, 0x86, 0x1b, 0x07, 0x48, 0x6b, 0x43, 0x70, 0x43, 0x00, 0x0d, + 0xc0, 0x18, 0xfe, 0xbd, 0x3d, 0x00, 0x13, 0x00, 0x06, 0x00, 0xe3, 0xe7, + 0x68, 0x26, 0x00, 0x20, 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, + 0x55, 0x55, 0x00, 0x00, 0x70, 0xb5, 0x04, 0x1e, 0x10, 0xd0, 0xff, 0xf7, + 0xcb, 0xff, 0x05, 0x00, 0x00, 0xf0, 0x1a, 0xf8, 0xff, 0xf7, 0xc6, 0xff, + 0x05, 0x4b, 0x40, 0x1b, 0x98, 0x42, 0xf7, 0xd9, 0xfa, 0x23, 0x01, 0x3c, + 0x9b, 0x00, 0xed, 0x18, 0x00, 0x2c, 0xf3, 0xd1, 0x70, 0xbd, 0xc0, 0x46, + 0xe7, 0x03, 0x00, 0x00, 0x10, 0xb5, 0x03, 0x4a, 0x13, 0x68, 0x01, 0x33, + 0x13, 0x60, 0x00, 0xf0, 0x4f, 0xfa, 0x10, 0xbd, 0x68, 0x26, 0x00, 0x20, + 0x70, 0x47, 0x00, 0x20, 0x70, 0x47, 0x10, 0xb5, 0x02, 0xf0, 0x26, 0xfa, + 0x10, 0xbd, 0x00, 0x00, 0x1e, 0x22, 0x70, 0xb5, 0x46, 0x48, 0x47, 0x49, + 0x43, 0x68, 0x93, 0x43, 0x1c, 0x3a, 0x13, 0x43, 0x43, 0x60, 0x08, 0x23, + 0x8c, 0x69, 0x23, 0x43, 0x8b, 0x61, 0x43, 0x4c, 0x43, 0x4b, 0x9c, 0x82, + 0x9c, 0x8a, 0x14, 0x43, 0x9c, 0x82, 0xdc, 0x68, 0x14, 0x42, 0xfc, 0xd0, + 0x01, 0x24, 0x40, 0x4a, 0x14, 0x70, 0x15, 0x78, 0x25, 0x42, 0x03, 0xd0, + 0x55, 0x78, 0x6d, 0xb2, 0x00, 0x2d, 0xf8, 0xdb, 0x01, 0x24, 0x94, 0x60, + 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x39, 0x4c, 0x54, 0x60, + 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x82, 0x24, 0xe4, 0x01, + 0x54, 0x80, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x02, 0x24, + 0x9c, 0x84, 0x0e, 0x34, 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x31, 0x4c, + 0xdc, 0x62, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x9d, 0x8c, + 0x2e, 0x4c, 0x2c, 0x43, 0x9c, 0x84, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, + 0xfc, 0xd0, 0x02, 0x24, 0x9d, 0x8c, 0x80, 0x26, 0x2c, 0x43, 0x9c, 0x84, + 0x40, 0x24, 0xdd, 0x68, 0x35, 0x42, 0xfc, 0xd0, 0xdd, 0x68, 0x25, 0x42, + 0xf9, 0xd0, 0x10, 0x24, 0xdd, 0x68, 0x25, 0x42, 0xfc, 0xd0, 0x00, 0x24, + 0x94, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x21, 0x4c, + 0x54, 0x60, 0x54, 0x78, 0x64, 0xb2, 0x00, 0x2c, 0xfb, 0xdb, 0x1c, 0x6a, + 0x1e, 0x4d, 0x2c, 0x40, 0x80, 0x25, 0x1c, 0x62, 0x1c, 0x6a, 0xac, 0x43, + 0x1c, 0x62, 0x03, 0x23, 0x93, 0x60, 0x1b, 0x4b, 0x53, 0x60, 0x53, 0x78, + 0x5b, 0xb2, 0x00, 0x2b, 0xfb, 0xdb, 0x00, 0x23, 0xff, 0x24, 0x0b, 0x72, + 0x17, 0x4a, 0x4b, 0x72, 0x8b, 0x72, 0xcb, 0x72, 0x16, 0x4b, 0x1a, 0x60, + 0x16, 0x4b, 0x17, 0x4a, 0x1b, 0x68, 0x11, 0x68, 0x9a, 0x06, 0x5b, 0x01, + 0xc9, 0x0e, 0x23, 0x40, 0x52, 0x0f, 0x12, 0x02, 0x0b, 0x43, 0x13, 0x43, + 0x12, 0x4a, 0x13, 0x85, 0x80, 0x23, 0x42, 0x68, 0x13, 0x43, 0x43, 0x60, + 0x70, 0xbd, 0xc0, 0x46, 0x00, 0x40, 0x00, 0x41, 0x00, 0x04, 0x00, 0x40, + 0x0c, 0x06, 0x00, 0x00, 0x00, 0x08, 0x00, 0x40, 0x00, 0x0c, 0x00, 0x40, + 0x01, 0x05, 0x01, 0x00, 0xb9, 0x05, 0xff, 0x7d, 0x04, 0x0a, 0x00, 0x00, + 0x00, 0x07, 0x03, 0x00, 0xff, 0xfc, 0xff, 0xff, 0x03, 0x06, 0x01, 0x00, + 0x00, 0x6c, 0xdc, 0x02, 0x20, 0x00, 0x00, 0x20, 0x24, 0x60, 0x80, 0x00, + 0x20, 0x60, 0x80, 0x00, 0x00, 0x40, 0x00, 0x42, 0xfa, 0x21, 0x31, 0x4b, + 0x10, 0xb5, 0x18, 0x68, 0x89, 0x00, 0x00, 0xf0, 0xdb, 0xf9, 0x2f, 0x4b, + 0x01, 0x38, 0x98, 0x42, 0x56, 0xd8, 0x2e, 0x49, 0x2e, 0x4a, 0x48, 0x60, + 0xc0, 0x20, 0x13, 0x6a, 0x00, 0x06, 0x1b, 0x02, 0x1b, 0x0a, 0x03, 0x43, + 0x13, 0x62, 0x00, 0x24, 0x07, 0x23, 0x8c, 0x60, 0x0b, 0x60, 0x80, 0x21, + 0x13, 0x6a, 0x09, 0x06, 0x1b, 0x02, 0x1b, 0x0a, 0x0b, 0x43, 0x13, 0x62, + 0xfc, 0x22, 0x25, 0x4b, 0x19, 0x6a, 0x0a, 0x43, 0x1a, 0x62, 0xfc, 0x22, + 0x19, 0x6a, 0x92, 0x01, 0x0a, 0x43, 0x1a, 0x62, 0xa0, 0x22, 0x19, 0x6a, + 0xd2, 0x02, 0x0a, 0x43, 0x1a, 0x62, 0x20, 0x00, 0x00, 0x21, 0x01, 0x34, + 0x00, 0xf0, 0x76, 0xf8, 0x0f, 0x2c, 0xf8, 0xd1, 0x1b, 0x4b, 0x1c, 0x00, + 0x5a, 0x78, 0x52, 0xb2, 0x00, 0x2a, 0xfb, 0xdb, 0x19, 0x4a, 0x5a, 0x80, + 0x19, 0x4b, 0x1a, 0x00, 0x59, 0x7e, 0xc9, 0x09, 0x01, 0x29, 0xfb, 0xd0, + 0xe4, 0x21, 0xc9, 0x00, 0x99, 0x80, 0x3f, 0x21, 0xd9, 0x70, 0x53, 0x7e, + 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0xc0, 0x23, 0x00, 0x20, 0x5b, 0x01, + 0x13, 0x61, 0x90, 0x70, 0x00, 0xf0, 0x24, 0xf8, 0x63, 0x78, 0x5b, 0xb2, + 0x00, 0x2b, 0xfb, 0xdb, 0x0d, 0x4b, 0x0e, 0x4a, 0x63, 0x80, 0xd3, 0x79, + 0xdb, 0x09, 0x01, 0x2b, 0xfb, 0xd0, 0x41, 0x23, 0x53, 0x70, 0x10, 0xbd, + 0xfe, 0xe7, 0xc0, 0x46, 0x20, 0x00, 0x00, 0x20, 0xff, 0xff, 0xff, 0x00, + 0x10, 0xe0, 0x00, 0xe0, 0x00, 0xed, 0x00, 0xe0, 0x00, 0x04, 0x00, 0x40, + 0x00, 0x0c, 0x00, 0x40, 0x1e, 0x40, 0x00, 0x00, 0x00, 0x40, 0x00, 0x42, + 0x21, 0x40, 0x00, 0x00, 0x00, 0x48, 0x00, 0x42, 0x16, 0x4a, 0x00, 0xb5, + 0x13, 0x00, 0x51, 0x7e, 0xc9, 0x09, 0x01, 0x29, 0xfb, 0xd0, 0x01, 0x38, + 0x04, 0x28, 0x16, 0xd8, 0x19, 0x69, 0x12, 0x4a, 0x0a, 0x40, 0x0f, 0x21, + 0x1a, 0x61, 0x5a, 0x78, 0x8a, 0x43, 0x00, 0xf0, 0x4d, 0xf9, 0x03, 0x08, + 0x06, 0x0b, 0x03, 0x00, 0x11, 0x00, 0x01, 0x22, 0x0a, 0x43, 0x5a, 0x70, + 0x00, 0xbd, 0x11, 0x00, 0x03, 0x22, 0xf9, 0xe7, 0x11, 0x00, 0x02, 0x22, + 0xf6, 0xe7, 0xf0, 0x23, 0x11, 0x69, 0x1b, 0x05, 0x0b, 0x43, 0x0f, 0x21, + 0x13, 0x61, 0x53, 0x78, 0x8b, 0x43, 0x19, 0x00, 0x02, 0x23, 0x0b, 0x43, + 0x53, 0x70, 0xeb, 0xe7, 0x00, 0x40, 0x00, 0x42, 0xff, 0xff, 0xff, 0xf0, + 0x18, 0x23, 0x30, 0xb5, 0x1d, 0x00, 0x04, 0x00, 0x45, 0x43, 0x08, 0x20, + 0x20, 0x4a, 0x55, 0x19, 0x28, 0x56, 0x01, 0x30, 0x14, 0xd0, 0x03, 0x29, + 0x12, 0xd8, 0x08, 0x00, 0x63, 0x43, 0xd1, 0x56, 0xd3, 0x18, 0x00, 0xf0, + 0x1b, 0xf9, 0x02, 0x28, 0x0e, 0x1b, 0x58, 0x68, 0xcb, 0x01, 0x02, 0x21, + 0x18, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, + 0x82, 0x40, 0x5a, 0x60, 0x30, 0xbd, 0x58, 0x68, 0xcb, 0x01, 0x06, 0x21, + 0x12, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, 0x01, 0x22, + 0x82, 0x40, 0x5a, 0x60, 0x9a, 0x61, 0xf1, 0xe7, 0x58, 0x68, 0xcb, 0x01, + 0x06, 0x21, 0x0c, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, 0x11, 0x70, + 0x01, 0x22, 0x82, 0x40, 0x5a, 0x60, 0x5a, 0x61, 0xe4, 0xe7, 0x58, 0x68, + 0xcb, 0x01, 0x02, 0x21, 0x05, 0x4a, 0x9b, 0x18, 0x1a, 0x18, 0x40, 0x32, + 0x11, 0x70, 0x01, 0x22, 0x82, 0x40, 0x9a, 0x60, 0xd8, 0xe7, 0xc0, 0x46, + 0xc0, 0x93, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, 0x18, 0x23, 0xf0, 0xb5, + 0x08, 0x24, 0x58, 0x43, 0x11, 0x4a, 0x13, 0x18, 0x1c, 0x57, 0x01, 0x34, + 0x1b, 0xd0, 0x01, 0x26, 0x35, 0x00, 0x5f, 0x68, 0x83, 0x56, 0xbd, 0x40, + 0x0d, 0x4a, 0xdb, 0x01, 0x9a, 0x18, 0x90, 0x68, 0x05, 0x42, 0x0b, 0xd1, + 0x0c, 0x00, 0x60, 0x1e, 0x84, 0x41, 0xd2, 0x19, 0x40, 0x32, 0x10, 0x78, + 0x34, 0x40, 0x03, 0x36, 0xa4, 0x00, 0xb0, 0x43, 0x20, 0x43, 0x10, 0x70, + 0x04, 0x4a, 0x9b, 0x18, 0x00, 0x29, 0x01, 0xd1, 0x5d, 0x61, 0xf0, 0xbd, + 0x9d, 0x61, 0xfc, 0xe7, 0xc0, 0x93, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x18, 0x22, 0x42, 0x43, 0xf8, 0xb5, 0x2c, 0x4e, 0x03, 0x00, 0xb2, 0x18, + 0x12, 0x7a, 0x52, 0xb2, 0x14, 0x00, 0x01, 0x32, 0x0e, 0xd0, 0x48, 0x1c, + 0x00, 0x24, 0x0c, 0x28, 0x0a, 0xd8, 0x00, 0xf0, 0xa5, 0xf8, 0x07, 0x1f, + 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x1f, 0x0b, 0x0b, 0x0b, 0x0b, 0x00, + 0x01, 0x24, 0x64, 0x42, 0x20, 0x00, 0xf8, 0xbd, 0x09, 0x29, 0x05, 0xd1, + 0x00, 0x21, 0x18, 0x00, 0xff, 0xf7, 0x66, 0xff, 0x00, 0x24, 0xf5, 0xe7, + 0x0a, 0x29, 0x01, 0xd1, 0x08, 0x39, 0xf6, 0xe7, 0x00, 0x24, 0x0b, 0x29, + 0xee, 0xd1, 0x0a, 0x39, 0x18, 0x00, 0xff, 0xf7, 0x59, 0xff, 0xe9, 0xe7, + 0x18, 0x22, 0x53, 0x43, 0xf2, 0x18, 0x55, 0x68, 0x01, 0x20, 0x2c, 0x00, + 0xf3, 0x56, 0x13, 0x4a, 0xdb, 0x01, 0x6e, 0x08, 0x9b, 0x18, 0xc9, 0xb2, + 0x04, 0x40, 0x9e, 0x19, 0x00, 0x2c, 0x0d, 0xd0, 0x0f, 0x24, 0x30, 0x36, + 0x32, 0x78, 0x09, 0x01, 0x22, 0x40, 0x11, 0x43, 0xc9, 0xb2, 0x5b, 0x19, + 0x31, 0x70, 0x40, 0x33, 0x1a, 0x78, 0x10, 0x43, 0x18, 0x70, 0xd3, 0xe7, + 0x32, 0x00, 0x0f, 0x27, 0x30, 0x32, 0x16, 0x78, 0x5b, 0x19, 0xbe, 0x43, + 0x31, 0x43, 0x11, 0x70, 0x40, 0x33, 0x1a, 0x78, 0x10, 0x43, 0x18, 0x70, + 0xbe, 0xe7, 0xc0, 0x46, 0xc0, 0x93, 0x00, 0x00, 0x00, 0x44, 0x00, 0x41, + 0x10, 0xb5, 0x04, 0x00, 0xfe, 0xf7, 0x9b, 0xfe, 0x01, 0x4b, 0x1c, 0x60, + 0x10, 0xbd, 0xc0, 0x46, 0x24, 0x00, 0x00, 0x20, 0x01, 0x22, 0x02, 0x4b, + 0x52, 0x42, 0x1a, 0x60, 0x70, 0x47, 0xc0, 0x46, 0x24, 0x00, 0x00, 0x20, + 0x16, 0x4a, 0x10, 0xb5, 0x13, 0x68, 0x59, 0x1c, 0x26, 0xd0, 0x01, 0x3b, + 0x13, 0x60, 0x00, 0x2b, 0x22, 0xd1, 0x72, 0xb6, 0x12, 0x4b, 0x13, 0x4a, + 0x04, 0x33, 0x93, 0x42, 0x13, 0xd9, 0x12, 0x4a, 0x01, 0x21, 0x10, 0x00, + 0x14, 0x7d, 0x0c, 0x42, 0xfc, 0xd0, 0x20, 0x21, 0x14, 0x8b, 0xff, 0x31, + 0x9b, 0x08, 0x5b, 0x00, 0x21, 0x43, 0x11, 0x83, 0xd3, 0x61, 0x0c, 0x4b, + 0x13, 0x80, 0x01, 0x23, 0x02, 0x7d, 0x1a, 0x42, 0xfc, 0xd0, 0xbf, 0xf3, + 0x4f, 0x8f, 0x09, 0x4b, 0x09, 0x4a, 0xda, 0x60, 0xbf, 0xf3, 0x4f, 0x8f, + 0xc0, 0x46, 0xfd, 0xe7, 0x10, 0xbd, 0xc0, 0x46, 0x24, 0x00, 0x00, 0x20, + 0x00, 0x20, 0x00, 0x00, 0x03, 0x02, 0x00, 0x00, 0x00, 0x40, 0x00, 0x41, + 0x02, 0xa5, 0xff, 0xff, 0x00, 0xed, 0x00, 0xe0, 0x04, 0x00, 0xfa, 0x05, + 0x0b, 0x00, 0x10, 0xb5, 0x01, 0x00, 0x18, 0x00, 0x01, 0xf0, 0x48, 0xff, + 0x10, 0xbd, 0x00, 0x00, 0x02, 0xb4, 0x71, 0x46, 0x49, 0x08, 0x49, 0x00, + 0x09, 0x5c, 0x49, 0x00, 0x8e, 0x44, 0x02, 0xbc, 0x70, 0x47, 0xc0, 0x46, + 0x00, 0x22, 0x43, 0x08, 0x8b, 0x42, 0x74, 0xd3, 0x03, 0x09, 0x8b, 0x42, + 0x5f, 0xd3, 0x03, 0x0a, 0x8b, 0x42, 0x44, 0xd3, 0x03, 0x0b, 0x8b, 0x42, + 0x28, 0xd3, 0x03, 0x0c, 0x8b, 0x42, 0x0d, 0xd3, 0xff, 0x22, 0x09, 0x02, + 0x12, 0xba, 0x03, 0x0c, 0x8b, 0x42, 0x02, 0xd3, 0x12, 0x12, 0x09, 0x02, + 0x65, 0xd0, 0x03, 0x0b, 0x8b, 0x42, 0x19, 0xd3, 0x00, 0xe0, 0x09, 0x0a, + 0xc3, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x03, 0xc0, 0x1a, 0x52, 0x41, + 0x83, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x03, 0xc0, 0x1a, 0x52, 0x41, + 0x43, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x03, 0xc0, 0x1a, 0x52, 0x41, + 0x03, 0x0b, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x03, 0xc0, 0x1a, 0x52, 0x41, + 0xc3, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x02, 0xc0, 0x1a, 0x52, 0x41, + 0x83, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x02, 0xc0, 0x1a, 0x52, 0x41, + 0x43, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x02, 0xc0, 0x1a, 0x52, 0x41, + 0x03, 0x0a, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x02, 0xc0, 0x1a, 0x52, 0x41, + 0xcd, 0xd2, 0xc3, 0x09, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x01, 0xc0, 0x1a, + 0x52, 0x41, 0x83, 0x09, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x01, 0xc0, 0x1a, + 0x52, 0x41, 0x43, 0x09, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x01, 0xc0, 0x1a, + 0x52, 0x41, 0x03, 0x09, 0x8b, 0x42, 0x01, 0xd3, 0x0b, 0x01, 0xc0, 0x1a, + 0x52, 0x41, 0xc3, 0x08, 0x8b, 0x42, 0x01, 0xd3, 0xcb, 0x00, 0xc0, 0x1a, + 0x52, 0x41, 0x83, 0x08, 0x8b, 0x42, 0x01, 0xd3, 0x8b, 0x00, 0xc0, 0x1a, + 0x52, 0x41, 0x43, 0x08, 0x8b, 0x42, 0x01, 0xd3, 0x4b, 0x00, 0xc0, 0x1a, + 0x52, 0x41, 0x41, 0x1a, 0x00, 0xd2, 0x01, 0x46, 0x52, 0x41, 0x10, 0x46, + 0x70, 0x47, 0xff, 0xe7, 0x01, 0xb5, 0x00, 0x20, 0x00, 0xf0, 0xf0, 0xf8, + 0x02, 0xbd, 0xc0, 0x46, 0x00, 0x29, 0xf7, 0xd0, 0x76, 0xe7, 0x70, 0x47, + 0x03, 0x46, 0x0b, 0x43, 0x7f, 0xd4, 0x00, 0x22, 0x43, 0x08, 0x8b, 0x42, + 0x74, 0xd3, 0x03, 0x09, 0x8b, 0x42, 0x5f, 0xd3, 0x03, 0x0a, 0x8b, 0x42, + 0x44, 0xd3, 0x03, 0x0b, 0x8b, 0x42, 0x28, 0xd3, 0x03, 0x0c, 0x8b, 0x42, + 0x0d, 0xd3, 0xff, 0x22, 0x09, 0x02, 0x12, 0xba, 0x03, 0x0c, 0x8b, 0x42, + 0x02, 0xd3, 0x12, 0x12, 0x09, 0x02, 0x65, 0xd0, 0x03, 0x0b, 0x8b, 0x42, + 0x19, 0xd3, 0x00, 0xe0, 0x09, 0x0a, 0xc3, 0x0b, 0x8b, 0x42, 0x01, 0xd3, + 0xcb, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0b, 0x8b, 0x42, 0x01, 0xd3, + 0x8b, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0b, 0x8b, 0x42, 0x01, 0xd3, + 0x4b, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0b, 0x8b, 0x42, 0x01, 0xd3, + 0x0b, 0x03, 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x0a, 0x8b, 0x42, 0x01, 0xd3, + 0xcb, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x0a, 0x8b, 0x42, 0x01, 0xd3, + 0x8b, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x0a, 0x8b, 0x42, 0x01, 0xd3, + 0x4b, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x0a, 0x8b, 0x42, 0x01, 0xd3, + 0x0b, 0x02, 0xc0, 0x1a, 0x52, 0x41, 0xcd, 0xd2, 0xc3, 0x09, 0x8b, 0x42, + 0x01, 0xd3, 0xcb, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x09, 0x8b, 0x42, + 0x01, 0xd3, 0x8b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x09, 0x8b, 0x42, + 0x01, 0xd3, 0x4b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x09, 0x8b, 0x42, + 0x01, 0xd3, 0x0b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x08, 0x8b, 0x42, + 0x01, 0xd3, 0xcb, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x08, 0x8b, 0x42, + 0x01, 0xd3, 0x8b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x08, 0x8b, 0x42, + 0x01, 0xd3, 0x4b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x41, 0x1a, 0x00, 0xd2, + 0x01, 0x46, 0x52, 0x41, 0x10, 0x46, 0x70, 0x47, 0x5d, 0xe0, 0xca, 0x0f, + 0x00, 0xd0, 0x49, 0x42, 0x03, 0x10, 0x00, 0xd3, 0x40, 0x42, 0x53, 0x40, + 0x00, 0x22, 0x9c, 0x46, 0x03, 0x09, 0x8b, 0x42, 0x2d, 0xd3, 0x03, 0x0a, + 0x8b, 0x42, 0x12, 0xd3, 0xfc, 0x22, 0x89, 0x01, 0x12, 0xba, 0x03, 0x0a, + 0x8b, 0x42, 0x0c, 0xd3, 0x89, 0x01, 0x92, 0x11, 0x8b, 0x42, 0x08, 0xd3, + 0x89, 0x01, 0x92, 0x11, 0x8b, 0x42, 0x04, 0xd3, 0x89, 0x01, 0x3a, 0xd0, + 0x92, 0x11, 0x00, 0xe0, 0x89, 0x09, 0xc3, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0xcb, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0x8b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x43, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0x4b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0x03, 0x09, 0x8b, 0x42, 0x01, 0xd3, + 0x0b, 0x01, 0xc0, 0x1a, 0x52, 0x41, 0xc3, 0x08, 0x8b, 0x42, 0x01, 0xd3, + 0xcb, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x83, 0x08, 0x8b, 0x42, 0x01, 0xd3, + 0x8b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0xd9, 0xd2, 0x43, 0x08, 0x8b, 0x42, + 0x01, 0xd3, 0x4b, 0x00, 0xc0, 0x1a, 0x52, 0x41, 0x41, 0x1a, 0x00, 0xd2, + 0x01, 0x46, 0x63, 0x46, 0x52, 0x41, 0x5b, 0x10, 0x10, 0x46, 0x01, 0xd3, + 0x40, 0x42, 0x00, 0x2b, 0x00, 0xd5, 0x49, 0x42, 0x70, 0x47, 0x63, 0x46, + 0x5b, 0x10, 0x00, 0xd3, 0x40, 0x42, 0x01, 0xb5, 0x00, 0x20, 0x00, 0xf0, + 0x05, 0xf8, 0x02, 0xbd, 0x00, 0x29, 0xf8, 0xd0, 0x16, 0xe7, 0x70, 0x47, + 0x70, 0x47, 0xc0, 0x46, 0x84, 0x46, 0x10, 0x1c, 0x62, 0x46, 0x8c, 0x46, + 0x19, 0x1c, 0x63, 0x46, 0x00, 0xe0, 0xc0, 0x46, 0x1f, 0xb5, 0x00, 0xf0, + 0xf1, 0xfe, 0x00, 0x28, 0x01, 0xd4, 0x00, 0x21, 0xc8, 0x42, 0x1f, 0xbd, + 0x10, 0xb5, 0x00, 0xf0, 0x49, 0xfe, 0x40, 0x42, 0x01, 0x30, 0x10, 0xbd, + 0x10, 0xb5, 0x00, 0xf0, 0xe3, 0xfe, 0x00, 0x28, 0x01, 0xdb, 0x00, 0x20, + 0x10, 0xbd, 0x01, 0x20, 0x10, 0xbd, 0xc0, 0x46, 0x10, 0xb5, 0x00, 0xf0, + 0xd9, 0xfe, 0x00, 0x28, 0x01, 0xdd, 0x00, 0x20, 0x10, 0xbd, 0x01, 0x20, + 0x10, 0xbd, 0xc0, 0x46, 0x10, 0xb5, 0x00, 0xf0, 0x6b, 0xfe, 0x00, 0x28, + 0x01, 0xdc, 0x00, 0x20, 0x10, 0xbd, 0x01, 0x20, 0x10, 0xbd, 0xc0, 0x46, + 0x10, 0xb5, 0x00, 0xf0, 0x61, 0xfe, 0x00, 0x28, 0x01, 0xda, 0x00, 0x20, + 0x10, 0xbd, 0x01, 0x20, 0x10, 0xbd, 0xc0, 0x46, 0xf0, 0xb5, 0x4f, 0x46, + 0x46, 0x46, 0xd6, 0x46, 0x0c, 0x00, 0x09, 0x03, 0xc0, 0xb5, 0x49, 0x0a, + 0x47, 0x0f, 0x5e, 0x00, 0x39, 0x43, 0x1f, 0x03, 0xdb, 0x0f, 0x9c, 0x46, + 0x65, 0x00, 0x7b, 0x0a, 0x57, 0x0f, 0x1f, 0x43, 0x6d, 0x0d, 0xe4, 0x0f, + 0x76, 0x0d, 0xa1, 0x46, 0xc0, 0x00, 0xb8, 0x46, 0xd2, 0x00, 0xab, 0x1b, + 0x64, 0x45, 0x7b, 0xd0, 0x00, 0x2b, 0x5f, 0xdd, 0x00, 0x2e, 0x00, 0xd0, + 0xa4, 0xe0, 0x3e, 0x00, 0x16, 0x43, 0x00, 0xd1, 0x12, 0xe1, 0x5e, 0x1e, + 0x00, 0x2e, 0x00, 0xd0, 0x9e, 0xe1, 0x87, 0x1a, 0x43, 0x46, 0xb8, 0x42, + 0x80, 0x41, 0x01, 0x25, 0xc9, 0x1a, 0x40, 0x42, 0x09, 0x1a, 0x0b, 0x02, + 0x00, 0xd4, 0x31, 0xe1, 0x49, 0x02, 0x4e, 0x0a, 0x00, 0x2e, 0x00, 0xd1, + 0x6e, 0xe1, 0x30, 0x00, 0x01, 0xf0, 0x28, 0xfd, 0x03, 0x00, 0x08, 0x3b, + 0x1f, 0x2b, 0x00, 0xdd, 0x61, 0xe1, 0x20, 0x22, 0x39, 0x00, 0xd2, 0x1a, + 0x9e, 0x40, 0xd1, 0x40, 0x9f, 0x40, 0x0e, 0x43, 0x9d, 0x42, 0x00, 0xdd, + 0x51, 0xe1, 0x5d, 0x1b, 0x6b, 0x1c, 0x1f, 0x2b, 0x00, 0xdd, 0x7c, 0xe1, + 0x20, 0x21, 0xc9, 0x1a, 0x3d, 0x00, 0x30, 0x00, 0x8f, 0x40, 0x88, 0x40, + 0xdd, 0x40, 0x79, 0x1e, 0x8f, 0x41, 0x31, 0x00, 0x07, 0x22, 0x28, 0x43, + 0xd9, 0x40, 0x00, 0x25, 0x07, 0x43, 0x3a, 0x40, 0x00, 0x2a, 0x09, 0xd0, + 0x0f, 0x23, 0x3b, 0x40, 0x04, 0x2b, 0x05, 0xd0, 0x3b, 0x1d, 0xbb, 0x42, + 0xbf, 0x41, 0x7f, 0x42, 0xc9, 0x19, 0x1f, 0x00, 0x0b, 0x02, 0x00, 0xd4, + 0x26, 0xe2, 0x6a, 0x1c, 0xc6, 0x4b, 0x55, 0x05, 0x6d, 0x0d, 0x9a, 0x42, + 0x00, 0xd1, 0x06, 0xe1, 0xc4, 0x4a, 0xff, 0x08, 0x0a, 0x40, 0x53, 0x07, + 0x52, 0x02, 0x3b, 0x43, 0x12, 0x0b, 0x8e, 0xe0, 0x00, 0x2b, 0x00, 0xd0, + 0xb8, 0xe0, 0x6b, 0x1c, 0x5b, 0x05, 0x5b, 0x0d, 0x01, 0x2b, 0x00, 0xdc, + 0x30, 0xe1, 0x87, 0x1a, 0x43, 0x46, 0xb8, 0x42, 0xb6, 0x41, 0xcb, 0x1a, + 0x76, 0x42, 0x9e, 0x1b, 0x33, 0x02, 0x00, 0xd5, 0x4c, 0xe1, 0x3b, 0x00, + 0x33, 0x43, 0xa1, 0xd1, 0x00, 0x22, 0x00, 0x24, 0x00, 0x25, 0x70, 0xe0, + 0x00, 0x2b, 0x00, 0xdc, 0xe5, 0xe0, 0x00, 0x2e, 0x00, 0xd1, 0x83, 0xe0, + 0xaf, 0x4e, 0xb5, 0x42, 0x60, 0xd0, 0x80, 0x26, 0x36, 0x04, 0x37, 0x43, + 0xb8, 0x46, 0x38, 0x2b, 0x00, 0xdc, 0x3e, 0xe1, 0x43, 0x46, 0x13, 0x43, + 0x1f, 0x00, 0x7a, 0x1e, 0x97, 0x41, 0x3f, 0x18, 0x87, 0x42, 0x80, 0x41, + 0x40, 0x42, 0x09, 0x18, 0x0b, 0x02, 0x00, 0xd4, 0xb0, 0xe0, 0xa4, 0x4b, + 0x01, 0x35, 0x9d, 0x42, 0x00, 0xd1, 0xc3, 0xe0, 0xa2, 0x4a, 0x7b, 0x08, + 0x0a, 0x40, 0x01, 0x21, 0x0f, 0x40, 0x1f, 0x43, 0x51, 0x08, 0xd3, 0x07, + 0x07, 0x22, 0x1f, 0x43, 0x3a, 0x40, 0x99, 0xe7, 0x9b, 0x4e, 0xb5, 0x42, + 0x38, 0xd0, 0x80, 0x26, 0x36, 0x04, 0x37, 0x43, 0xb8, 0x46, 0x38, 0x2b, + 0x00, 0xdd, 0xdc, 0xe0, 0x1f, 0x2b, 0x00, 0xdc, 0x30, 0xe1, 0x1e, 0x00, + 0x47, 0x46, 0x20, 0x3e, 0xf7, 0x40, 0xbc, 0x46, 0x20, 0x2b, 0x04, 0xd0, + 0x40, 0x26, 0xf3, 0x1a, 0x46, 0x46, 0x9e, 0x40, 0x32, 0x43, 0x17, 0x00, + 0x63, 0x46, 0x7a, 0x1e, 0x97, 0x41, 0x1f, 0x43, 0xcc, 0xe0, 0x00, 0x2b, + 0x00, 0xd1, 0x04, 0xe2, 0x43, 0x46, 0x13, 0x43, 0x00, 0xd1, 0x59, 0xe1, + 0x4b, 0x07, 0xc0, 0x08, 0x18, 0x43, 0x80, 0x23, 0xc9, 0x08, 0x1b, 0x03, + 0x19, 0x42, 0x08, 0xd0, 0x45, 0x46, 0xed, 0x08, 0x1d, 0x42, 0x04, 0xd1, + 0x43, 0x46, 0xd0, 0x08, 0x59, 0x07, 0x08, 0x43, 0x29, 0x00, 0x42, 0x0f, + 0xc9, 0x00, 0x7f, 0x4d, 0x11, 0x43, 0xc0, 0x00, 0x4b, 0x07, 0xca, 0x08, + 0x7c, 0x49, 0xc0, 0x08, 0x03, 0x43, 0x8d, 0x42, 0x68, 0xd0, 0x12, 0x03, + 0x6d, 0x05, 0x12, 0x0b, 0x6d, 0x0d, 0x00, 0x21, 0x12, 0x03, 0x18, 0x00, + 0x13, 0x0b, 0x0a, 0x0d, 0x12, 0x05, 0x1a, 0x43, 0x76, 0x4b, 0x2d, 0x05, + 0x13, 0x40, 0x2b, 0x43, 0x5b, 0x00, 0xe4, 0x07, 0x5b, 0x08, 0x23, 0x43, + 0x19, 0x00, 0x1c, 0xbc, 0x90, 0x46, 0x99, 0x46, 0xa2, 0x46, 0xf0, 0xbd, + 0x3e, 0x00, 0x16, 0x43, 0x12, 0xd0, 0x5e, 0x1e, 0x00, 0x2e, 0x00, 0xd0, + 0x00, 0xe1, 0x87, 0x18, 0x87, 0x42, 0x80, 0x41, 0x41, 0x44, 0x40, 0x42, + 0x09, 0x18, 0x01, 0x25, 0x0b, 0x02, 0x33, 0xd5, 0x02, 0x25, 0x85, 0xe7, + 0x64, 0x46, 0x33, 0x00, 0x41, 0x46, 0x10, 0x00, 0x1d, 0x00, 0xc7, 0xe7, + 0x00, 0x2d, 0x00, 0xd0, 0xda, 0xe0, 0x0c, 0x00, 0x04, 0x43, 0xf3, 0xd0, + 0x5c, 0x1c, 0x00, 0xd1, 0x9f, 0xe1, 0x5d, 0x4c, 0xa6, 0x42, 0x00, 0xd1, + 0x2f, 0xe1, 0xdb, 0x43, 0x38, 0x2b, 0x00, 0xdd, 0x66, 0xe1, 0x1f, 0x2b, + 0x00, 0xdd, 0x83, 0xe1, 0x20, 0x24, 0x05, 0x00, 0xe4, 0x1a, 0x0f, 0x00, + 0xdd, 0x40, 0xd9, 0x40, 0xa0, 0x40, 0x43, 0x46, 0xa7, 0x40, 0x5b, 0x1a, + 0x44, 0x1e, 0xa0, 0x41, 0x98, 0x46, 0x2f, 0x43, 0x38, 0x43, 0x17, 0x1a, + 0xba, 0x42, 0x92, 0x41, 0x43, 0x46, 0x52, 0x42, 0x99, 0x1a, 0x64, 0x46, + 0x35, 0x00, 0xca, 0xe6, 0x07, 0x22, 0x3a, 0x40, 0x00, 0x2a, 0x00, 0xd0, + 0xf6, 0xe6, 0x4b, 0x07, 0xca, 0x08, 0x48, 0x49, 0xff, 0x08, 0x3b, 0x43, + 0x8d, 0x42, 0x96, 0xd1, 0x19, 0x00, 0x11, 0x43, 0x00, 0xd1, 0x9e, 0xe1, + 0x80, 0x21, 0x09, 0x03, 0x0a, 0x43, 0x12, 0x03, 0x12, 0x0b, 0x41, 0x4d, + 0x8f, 0xe7, 0x15, 0x00, 0x00, 0x22, 0x00, 0x23, 0x8b, 0xe7, 0x00, 0x2b, + 0x00, 0xd0, 0xc7, 0xe0, 0x6b, 0x1c, 0x5f, 0x05, 0x7f, 0x0d, 0x01, 0x2f, + 0x00, 0xdc, 0xf1, 0xe0, 0x39, 0x4d, 0xab, 0x42, 0x00, 0xd1, 0xb9, 0xe0, + 0x85, 0x18, 0x0a, 0x00, 0x85, 0x42, 0x89, 0x41, 0x42, 0x44, 0x49, 0x42, + 0x51, 0x18, 0x07, 0x22, 0xcf, 0x07, 0x6d, 0x08, 0x2f, 0x43, 0x49, 0x08, + 0x3a, 0x40, 0x1d, 0x00, 0xc2, 0xe6, 0x07, 0x22, 0x30, 0x49, 0xed, 0x1a, + 0x31, 0x40, 0x3a, 0x40, 0xbc, 0xe6, 0x3e, 0x00, 0x28, 0x38, 0x86, 0x40, + 0x00, 0x27, 0x9f, 0xe6, 0x38, 0x00, 0x01, 0xf0, 0xb9, 0xfb, 0x20, 0x30, + 0x8e, 0xe6, 0x43, 0x46, 0x13, 0x43, 0x1f, 0x00, 0x7a, 0x1e, 0x97, 0x41, + 0xc7, 0x1b, 0xb8, 0x42, 0x80, 0x41, 0x40, 0x42, 0x09, 0x1a, 0x78, 0xe6, + 0x0e, 0x00, 0x3b, 0x00, 0x06, 0x43, 0x13, 0x43, 0x00, 0x2d, 0x61, 0xd1, + 0x00, 0x2e, 0x00, 0xd0, 0xf4, 0xe0, 0x00, 0x2b, 0x00, 0xd1, 0x1b, 0xe1, + 0x64, 0x46, 0x39, 0x00, 0x10, 0x00, 0x39, 0xe7, 0x1a, 0x4f, 0xbb, 0x42, + 0x7a, 0xd0, 0x33, 0x00, 0xff, 0xe6, 0x30, 0x00, 0x1f, 0x3d, 0xe8, 0x40, + 0x20, 0x2b, 0x03, 0xd0, 0x40, 0x21, 0xcb, 0x1a, 0x9e, 0x40, 0x37, 0x43, + 0x7b, 0x1e, 0x9f, 0x41, 0x07, 0x22, 0x07, 0x43, 0x3a, 0x40, 0x00, 0x21, + 0x00, 0x25, 0x89, 0xe7, 0x17, 0x1a, 0x43, 0x46, 0xba, 0x42, 0xb6, 0x41, + 0x59, 0x1a, 0x76, 0x42, 0x8e, 0x1b, 0x64, 0x46, 0x4e, 0xe6, 0x1f, 0x2b, + 0x00, 0xdd, 0xad, 0xe0, 0x20, 0x26, 0x47, 0x46, 0xf6, 0x1a, 0xb7, 0x40, + 0xb9, 0x46, 0x17, 0x00, 0xb2, 0x46, 0xdf, 0x40, 0x4e, 0x46, 0x3e, 0x43, + 0x37, 0x00, 0x56, 0x46, 0xb2, 0x40, 0x56, 0x1e, 0xb2, 0x41, 0x17, 0x43, + 0x42, 0x46, 0xda, 0x40, 0x89, 0x18, 0xae, 0xe6, 0xff, 0x07, 0x00, 0x00, + 0xff, 0xff, 0x7f, 0xff, 0xff, 0xff, 0x0f, 0x80, 0x20, 0x26, 0x47, 0x46, + 0xf6, 0x1a, 0xb7, 0x40, 0xb9, 0x46, 0x17, 0x00, 0xb2, 0x46, 0xdf, 0x40, + 0x4e, 0x46, 0x3e, 0x43, 0x37, 0x00, 0x56, 0x46, 0xb2, 0x40, 0x56, 0x1e, + 0xb2, 0x41, 0x17, 0x43, 0x42, 0x46, 0xda, 0x40, 0x89, 0x1a, 0x99, 0xe7, + 0x7f, 0x4c, 0xa6, 0x42, 0x5b, 0xd0, 0x80, 0x24, 0x24, 0x04, 0x5b, 0x42, + 0x21, 0x43, 0x27, 0xe7, 0x00, 0x2e, 0x0c, 0xd1, 0x00, 0x2b, 0x00, 0xd1, + 0xcb, 0xe0, 0x64, 0x46, 0x39, 0x00, 0x10, 0x00, 0x77, 0x4d, 0xd7, 0xe6, + 0x76, 0x4f, 0xbb, 0x42, 0x18, 0xd0, 0x33, 0x00, 0x75, 0xe6, 0x00, 0x2b, + 0x14, 0xd0, 0x4b, 0x07, 0xc0, 0x08, 0x18, 0x43, 0x80, 0x23, 0xc9, 0x08, + 0x1b, 0x03, 0x19, 0x42, 0x07, 0xd0, 0xfc, 0x08, 0x1c, 0x42, 0x04, 0xd1, + 0x79, 0x07, 0xd0, 0x08, 0x08, 0x43, 0xe1, 0x46, 0x21, 0x00, 0x4c, 0x46, + 0x42, 0x0f, 0xc9, 0x00, 0x11, 0x43, 0xc0, 0x00, 0x68, 0x4d, 0xb9, 0xe6, + 0x1d, 0x00, 0x00, 0x22, 0x00, 0x23, 0xc0, 0xe6, 0x00, 0x2d, 0x5b, 0xd1, + 0x0d, 0x00, 0x05, 0x43, 0x00, 0xd1, 0xe2, 0xe6, 0x5d, 0x1c, 0x00, 0xd1, + 0xb0, 0xe0, 0x61, 0x4d, 0xae, 0x42, 0x1f, 0xd0, 0xdb, 0x43, 0x38, 0x2b, + 0x71, 0xdc, 0x1f, 0x2b, 0x00, 0xdd, 0x96, 0xe0, 0x20, 0x25, 0x0f, 0x00, + 0xed, 0x1a, 0xaf, 0x40, 0xb9, 0x46, 0x07, 0x00, 0xaa, 0x46, 0xdf, 0x40, + 0x4d, 0x46, 0x3d, 0x43, 0x2f, 0x00, 0x55, 0x46, 0xa8, 0x40, 0xd9, 0x40, + 0x45, 0x1e, 0xa8, 0x41, 0x88, 0x44, 0x07, 0x43, 0xbf, 0x18, 0x97, 0x42, + 0x92, 0x41, 0x51, 0x42, 0x41, 0x44, 0x35, 0x00, 0x3a, 0xe6, 0x64, 0x46, + 0x35, 0x00, 0x41, 0x46, 0x10, 0x00, 0x85, 0xe6, 0x0b, 0x00, 0x03, 0x43, + 0x00, 0x2d, 0x00, 0xd0, 0x63, 0xe6, 0x00, 0x2b, 0xf5, 0xd0, 0x43, 0x46, + 0x13, 0x43, 0x00, 0xd1, 0x7a, 0xe6, 0x87, 0x18, 0x87, 0x42, 0x80, 0x41, + 0x07, 0x22, 0x41, 0x44, 0x40, 0x42, 0x09, 0x18, 0x3a, 0x40, 0x0b, 0x02, + 0x00, 0xd4, 0xd5, 0xe6, 0x43, 0x4b, 0x01, 0x35, 0x19, 0x40, 0xc9, 0xe5, + 0x38, 0x00, 0x69, 0xe6, 0x1e, 0x00, 0x47, 0x46, 0x20, 0x3e, 0xf7, 0x40, + 0xbc, 0x46, 0x20, 0x2b, 0x04, 0xd0, 0x40, 0x26, 0xf3, 0x1a, 0x46, 0x46, + 0x9e, 0x40, 0x32, 0x43, 0x17, 0x00, 0x63, 0x46, 0x7a, 0x1e, 0x97, 0x41, + 0x1f, 0x43, 0x02, 0xe6, 0x36, 0x4d, 0xae, 0x42, 0xca, 0xd0, 0x80, 0x25, + 0x2d, 0x04, 0x5b, 0x42, 0x29, 0x43, 0xa6, 0xe7, 0x08, 0x43, 0x41, 0x1e, + 0x88, 0x41, 0xa6, 0xe6, 0x00, 0x2b, 0x00, 0xd1, 0x48, 0xe6, 0x87, 0x1a, + 0x43, 0x46, 0xb8, 0x42, 0xb6, 0x41, 0xcb, 0x1a, 0x76, 0x42, 0x9e, 0x1b, + 0x33, 0x02, 0x4b, 0xd5, 0x17, 0x1a, 0x43, 0x46, 0xba, 0x42, 0x92, 0x41, + 0x59, 0x1a, 0x52, 0x42, 0x89, 0x1a, 0x07, 0x22, 0x64, 0x46, 0x3a, 0x40, + 0x92, 0xe5, 0x01, 0x43, 0x0f, 0x00, 0x79, 0x1e, 0x8f, 0x41, 0x9d, 0xe7, + 0x1c, 0x00, 0x0f, 0x00, 0x20, 0x3c, 0xe7, 0x40, 0x20, 0x2b, 0x03, 0xd0, + 0x40, 0x24, 0xe3, 0x1a, 0x99, 0x40, 0x08, 0x43, 0x41, 0x1e, 0x88, 0x41, + 0x38, 0x43, 0x7c, 0xe6, 0x00, 0x22, 0x00, 0x24, 0x25, 0xe6, 0x17, 0x1a, + 0x43, 0x46, 0xba, 0x42, 0x92, 0x41, 0x59, 0x1a, 0x52, 0x42, 0x89, 0x1a, + 0x64, 0x46, 0x35, 0x00, 0x43, 0xe5, 0x41, 0x46, 0x10, 0x00, 0x14, 0x4d, + 0x10, 0xe6, 0x80, 0x22, 0x00, 0x24, 0x12, 0x03, 0x80, 0xe6, 0x1d, 0x00, + 0x0f, 0x00, 0x20, 0x3d, 0xef, 0x40, 0xbc, 0x46, 0x20, 0x2b, 0x03, 0xd0, + 0x40, 0x25, 0xeb, 0x1a, 0x99, 0x40, 0x08, 0x43, 0x07, 0x00, 0x63, 0x46, + 0x78, 0x1e, 0x87, 0x41, 0x1f, 0x43, 0x69, 0xe7, 0x87, 0x18, 0x97, 0x42, + 0x9b, 0x41, 0x41, 0x44, 0x5b, 0x42, 0xc9, 0x18, 0x35, 0x00, 0xa3, 0xe5, + 0x3b, 0x00, 0x33, 0x43, 0xce, 0xd0, 0x07, 0x22, 0x31, 0x00, 0x3a, 0x40, + 0x52, 0xe6, 0x00, 0x23, 0x1a, 0x00, 0xf4, 0xe5, 0xff, 0x07, 0x00, 0x00, + 0xff, 0xff, 0x7f, 0xff, 0xf0, 0xb5, 0x57, 0x46, 0xde, 0x46, 0x4e, 0x46, + 0x45, 0x46, 0xe0, 0xb5, 0x83, 0x46, 0x07, 0x00, 0x0e, 0x03, 0x48, 0x00, + 0x85, 0xb0, 0x92, 0x46, 0x1c, 0x00, 0x36, 0x0b, 0x40, 0x0d, 0xcd, 0x0f, + 0x00, 0x28, 0x00, 0xd1, 0x9d, 0xe0, 0x95, 0x4b, 0x98, 0x42, 0x39, 0xd0, + 0x80, 0x23, 0xf6, 0x00, 0x1b, 0x04, 0x1e, 0x43, 0x92, 0x4a, 0x7b, 0x0f, + 0x33, 0x43, 0x99, 0x46, 0x94, 0x46, 0x03, 0x00, 0x63, 0x44, 0x00, 0x93, + 0x00, 0x23, 0x00, 0x26, 0xff, 0x00, 0x02, 0x93, 0x23, 0x03, 0x1b, 0x0b, + 0x98, 0x46, 0x63, 0x00, 0xe4, 0x0f, 0x52, 0x46, 0x5b, 0x0d, 0x01, 0x94, + 0x00, 0xd1, 0xb3, 0xe0, 0x86, 0x49, 0x8b, 0x42, 0x00, 0xd1, 0x9e, 0xe0, + 0x42, 0x46, 0xd1, 0x00, 0x80, 0x22, 0x12, 0x04, 0x0a, 0x43, 0x51, 0x46, + 0x49, 0x0f, 0x11, 0x43, 0x8b, 0x46, 0x81, 0x49, 0x52, 0x46, 0x8c, 0x46, + 0x00, 0x99, 0x63, 0x44, 0xcb, 0x1a, 0x00, 0x21, 0xd2, 0x00, 0x00, 0x93, + 0x2b, 0x00, 0x63, 0x40, 0x9a, 0x46, 0x0f, 0x2e, 0x00, 0xd9, 0x05, 0xe1, + 0x7a, 0x4b, 0xb6, 0x00, 0x9b, 0x59, 0x9f, 0x46, 0x5b, 0x46, 0x33, 0x43, + 0x99, 0x46, 0x00, 0xd0, 0xb8, 0xe0, 0x02, 0x23, 0x08, 0x26, 0x00, 0x27, + 0x00, 0x90, 0x02, 0x93, 0xca, 0xe7, 0xcb, 0x46, 0x3a, 0x00, 0x02, 0x99, + 0x01, 0x95, 0x01, 0x9b, 0x9a, 0x46, 0x02, 0x29, 0x27, 0xd0, 0x03, 0x29, + 0x00, 0xd1, 0x80, 0xe2, 0x01, 0x29, 0x44, 0xd0, 0x6d, 0x49, 0x00, 0x9b, + 0x8c, 0x46, 0x63, 0x44, 0x1c, 0x00, 0x00, 0x2c, 0x38, 0xdd, 0x53, 0x07, + 0x00, 0xd0, 0x13, 0xe2, 0xd2, 0x08, 0x5b, 0x46, 0xdb, 0x01, 0x09, 0xd5, + 0x59, 0x46, 0x67, 0x4b, 0x19, 0x40, 0x8b, 0x46, 0x80, 0x21, 0xc9, 0x00, + 0x8c, 0x46, 0x00, 0x9b, 0x63, 0x44, 0x1c, 0x00, 0x63, 0x4b, 0x9c, 0x42, + 0x07, 0xdc, 0x5b, 0x46, 0x64, 0x05, 0x5f, 0x07, 0x5b, 0x02, 0x17, 0x43, + 0x1b, 0x0b, 0x62, 0x0d, 0x02, 0xe0, 0x00, 0x23, 0x00, 0x27, 0x58, 0x4a, + 0x00, 0x21, 0x1b, 0x03, 0x1c, 0x0b, 0x0b, 0x0d, 0x1b, 0x05, 0x23, 0x43, + 0x14, 0x05, 0x5a, 0x4a, 0x38, 0x00, 0x13, 0x40, 0x1c, 0x43, 0x53, 0x46, + 0x64, 0x00, 0xdb, 0x07, 0x64, 0x08, 0x1c, 0x43, 0x21, 0x00, 0x05, 0xb0, + 0x3c, 0xbc, 0x90, 0x46, 0x99, 0x46, 0xa2, 0x46, 0xab, 0x46, 0xf0, 0xbd, + 0x01, 0x22, 0x52, 0x42, 0x01, 0x23, 0x1b, 0x1b, 0x38, 0x2b, 0x00, 0xdc, + 0xad, 0xe1, 0x00, 0x22, 0x00, 0x23, 0x00, 0x27, 0xdc, 0xe7, 0x5b, 0x46, + 0x33, 0x43, 0x99, 0x46, 0x5e, 0xd0, 0x00, 0x2e, 0x00, 0xd1, 0x8a, 0xe1, + 0x30, 0x00, 0x01, 0xf0, 0x8d, 0xf9, 0x03, 0x00, 0x0b, 0x3b, 0x1c, 0x2b, + 0x00, 0xdd, 0x7b, 0xe1, 0x1d, 0x22, 0xd3, 0x1a, 0x5a, 0x46, 0x01, 0x00, + 0xda, 0x40, 0x08, 0x39, 0x8e, 0x40, 0x13, 0x00, 0x5f, 0x46, 0x33, 0x43, + 0x99, 0x46, 0x8f, 0x40, 0x3f, 0x4b, 0x00, 0x26, 0x1b, 0x1a, 0x00, 0x93, + 0x00, 0x23, 0x02, 0x93, 0x52, 0xe7, 0x41, 0x46, 0x53, 0x46, 0x0b, 0x43, + 0x3b, 0x49, 0x9b, 0x46, 0x8c, 0x46, 0x00, 0x9b, 0x63, 0x44, 0x00, 0x93, + 0x5b, 0x46, 0x00, 0x2b, 0x3b, 0xd1, 0x02, 0x23, 0x00, 0x22, 0x1e, 0x43, + 0x02, 0x21, 0x61, 0xe7, 0x43, 0x46, 0x13, 0x43, 0x9b, 0x46, 0x37, 0xd0, + 0x43, 0x46, 0x00, 0x2b, 0x00, 0xd1, 0x62, 0xe1, 0x40, 0x46, 0x01, 0xf0, + 0x59, 0xf9, 0x03, 0x00, 0x0b, 0x3b, 0x1c, 0x2b, 0x00, 0xdd, 0x53, 0xe1, + 0x02, 0x00, 0x41, 0x46, 0x08, 0x3a, 0x91, 0x40, 0x88, 0x46, 0x1d, 0x21, + 0xcb, 0x1a, 0x51, 0x46, 0xd9, 0x40, 0x0b, 0x00, 0x41, 0x46, 0x0b, 0x43, + 0x9b, 0x46, 0x53, 0x46, 0x93, 0x40, 0x1a, 0x00, 0x00, 0x9b, 0x25, 0x49, + 0x9c, 0x46, 0x60, 0x44, 0x03, 0x00, 0x8c, 0x46, 0x63, 0x44, 0x00, 0x93, + 0x00, 0x21, 0x37, 0xe7, 0x03, 0x23, 0xb1, 0x46, 0x00, 0x90, 0x0c, 0x26, + 0x02, 0x93, 0x11, 0xe7, 0x00, 0x23, 0x00, 0x93, 0x01, 0x33, 0x04, 0x26, + 0x00, 0x27, 0x02, 0x93, 0x0a, 0xe7, 0x03, 0x23, 0xc3, 0x46, 0x1e, 0x43, + 0x03, 0x21, 0x25, 0xe7, 0x01, 0x33, 0x1e, 0x43, 0x00, 0x22, 0x01, 0x21, + 0x20, 0xe7, 0x00, 0x23, 0x9a, 0x46, 0x80, 0x23, 0x00, 0x27, 0x1b, 0x03, + 0x09, 0x4a, 0x61, 0xe7, 0x80, 0x23, 0x49, 0x46, 0x1b, 0x03, 0x19, 0x42, + 0x00, 0xd1, 0xe2, 0xe0, 0x59, 0x46, 0x19, 0x42, 0x00, 0xd0, 0xde, 0xe0, + 0x0b, 0x43, 0x1b, 0x03, 0x17, 0x00, 0x1b, 0x0b, 0xa2, 0x46, 0x01, 0x4a, + 0x50, 0xe7, 0xc0, 0x46, 0xff, 0x07, 0x00, 0x00, 0x01, 0xfc, 0xff, 0xff, + 0xb8, 0x97, 0x00, 0x00, 0xff, 0x03, 0x00, 0x00, 0xff, 0xff, 0xff, 0xfe, + 0xfe, 0x07, 0x00, 0x00, 0xff, 0xff, 0x0f, 0x80, 0x0d, 0xfc, 0xff, 0xff, + 0x01, 0xf8, 0xff, 0xff, 0xf3, 0x03, 0x00, 0x00, 0xd9, 0x45, 0x00, 0xd9, + 0xcb, 0xe0, 0x00, 0xd1, 0xc6, 0xe0, 0x3c, 0x00, 0x48, 0x46, 0x00, 0x27, + 0x00, 0x9b, 0x01, 0x3b, 0x00, 0x93, 0x5b, 0x46, 0x16, 0x0e, 0x1b, 0x02, + 0x1e, 0x43, 0x13, 0x02, 0x98, 0x46, 0x33, 0x04, 0x1b, 0x0c, 0x99, 0x46, + 0x31, 0x0c, 0x01, 0x91, 0xff, 0xf7, 0x4c, 0xfa, 0x4a, 0x46, 0x42, 0x43, + 0x0b, 0x04, 0x21, 0x0c, 0x05, 0x00, 0x19, 0x43, 0x8a, 0x42, 0x07, 0xd9, + 0x89, 0x19, 0x01, 0x3d, 0x8e, 0x42, 0x03, 0xd8, 0x8a, 0x42, 0x01, 0xd9, + 0x85, 0x1e, 0x89, 0x19, 0x88, 0x1a, 0x01, 0x99, 0xff, 0xf7, 0x38, 0xfa, + 0x09, 0x04, 0x8c, 0x46, 0x4a, 0x46, 0x21, 0x04, 0x64, 0x46, 0x42, 0x43, + 0x09, 0x0c, 0x03, 0x00, 0x21, 0x43, 0x8a, 0x42, 0x04, 0xd9, 0x89, 0x19, + 0x01, 0x3b, 0x8e, 0x42, 0x00, 0xd8, 0xf1, 0xe0, 0x2d, 0x04, 0x1d, 0x43, + 0xab, 0x46, 0x43, 0x46, 0x89, 0x1a, 0x42, 0x46, 0x28, 0x0c, 0x12, 0x04, + 0x1d, 0x0c, 0x5b, 0x46, 0x14, 0x0c, 0x22, 0x00, 0x1b, 0x04, 0x1b, 0x0c, + 0x5a, 0x43, 0x03, 0x94, 0x6b, 0x43, 0x44, 0x43, 0x02, 0x95, 0x68, 0x43, + 0x1b, 0x19, 0x15, 0x0c, 0xeb, 0x18, 0x9c, 0x42, 0x03, 0xd9, 0x80, 0x24, + 0x64, 0x02, 0xa4, 0x46, 0x60, 0x44, 0x1c, 0x0c, 0x15, 0x04, 0x1b, 0x04, + 0x2d, 0x0c, 0x20, 0x18, 0x5d, 0x19, 0x81, 0x42, 0x77, 0xd3, 0x73, 0xd0, + 0x0c, 0x1a, 0xa2, 0x4a, 0x7d, 0x1b, 0xaf, 0x42, 0xbf, 0x41, 0x94, 0x46, + 0x00, 0x9b, 0x7f, 0x42, 0x63, 0x44, 0xe0, 0x1b, 0x1c, 0x00, 0x86, 0x42, + 0x00, 0xd1, 0xdb, 0xe0, 0x01, 0x99, 0xff, 0xf7, 0xf1, 0xf9, 0x4a, 0x46, + 0x42, 0x43, 0x0b, 0x04, 0x29, 0x0c, 0x07, 0x00, 0x19, 0x43, 0x8a, 0x42, + 0x07, 0xd9, 0x89, 0x19, 0x01, 0x3f, 0x8e, 0x42, 0x03, 0xd8, 0x8a, 0x42, + 0x01, 0xd9, 0x87, 0x1e, 0x89, 0x19, 0x88, 0x1a, 0x01, 0x99, 0xff, 0xf7, + 0xdd, 0xf9, 0x09, 0x04, 0x4a, 0x46, 0x89, 0x46, 0x29, 0x04, 0x4d, 0x46, + 0x42, 0x43, 0x09, 0x0c, 0x03, 0x00, 0x29, 0x43, 0x8a, 0x42, 0x07, 0xd9, + 0x89, 0x19, 0x01, 0x3b, 0x8e, 0x42, 0x03, 0xd8, 0x8a, 0x42, 0x01, 0xd9, + 0x83, 0x1e, 0x89, 0x19, 0x3f, 0x04, 0x89, 0x1a, 0x3a, 0x00, 0x03, 0x9f, + 0x1a, 0x43, 0x38, 0x00, 0x13, 0x04, 0x1b, 0x0c, 0x58, 0x43, 0x81, 0x46, + 0x02, 0x98, 0x15, 0x0c, 0x6f, 0x43, 0x43, 0x43, 0x45, 0x43, 0x48, 0x46, + 0x00, 0x0c, 0x84, 0x46, 0xdb, 0x19, 0x63, 0x44, 0x9f, 0x42, 0x03, 0xd9, + 0x80, 0x20, 0x40, 0x02, 0x84, 0x46, 0x65, 0x44, 0x48, 0x46, 0x1f, 0x0c, + 0x00, 0x04, 0x1b, 0x04, 0x00, 0x0c, 0x7d, 0x19, 0x18, 0x18, 0xa9, 0x42, + 0x00, 0xd2, 0x84, 0xe0, 0x00, 0xd1, 0x7f, 0xe0, 0x01, 0x23, 0x1a, 0x43, + 0x57, 0xe6, 0x80, 0x23, 0x4a, 0x46, 0x1b, 0x03, 0x13, 0x43, 0x1b, 0x03, + 0x1b, 0x0b, 0xaa, 0x46, 0x6f, 0x4a, 0x6f, 0xe6, 0xba, 0x42, 0x00, 0xd9, + 0x35, 0xe7, 0x4b, 0x46, 0xdc, 0x07, 0x58, 0x08, 0x7b, 0x08, 0x1c, 0x43, + 0xff, 0x07, 0x34, 0xe7, 0x00, 0x24, 0xaf, 0x42, 0x89, 0xd2, 0x47, 0x44, + 0x47, 0x45, 0xa4, 0x41, 0x5b, 0x46, 0x64, 0x42, 0xa4, 0x19, 0x64, 0x18, + 0x01, 0x3b, 0xa6, 0x42, 0x1e, 0xd2, 0xa0, 0x42, 0x6d, 0xd8, 0x00, 0xd1, + 0xb6, 0xe0, 0x24, 0x1a, 0x9b, 0x46, 0x78, 0xe7, 0x03, 0x00, 0x5a, 0x46, + 0x28, 0x3b, 0x9a, 0x40, 0x00, 0x27, 0x91, 0x46, 0x88, 0xe6, 0x58, 0x46, + 0x01, 0xf0, 0x02, 0xf8, 0x20, 0x30, 0x72, 0xe6, 0x03, 0x00, 0x52, 0x46, + 0x28, 0x3b, 0x9a, 0x40, 0x93, 0x46, 0x00, 0x22, 0xb4, 0xe6, 0x50, 0x46, + 0x00, 0xf0, 0xf6, 0xff, 0x20, 0x30, 0x9a, 0xe6, 0xa6, 0x42, 0xe2, 0xd1, + 0xb8, 0x45, 0xdc, 0xd9, 0x34, 0x1a, 0x9b, 0x46, 0x59, 0xe7, 0x1f, 0x2b, + 0x65, 0xdc, 0x50, 0x4c, 0x00, 0x99, 0xa4, 0x46, 0x5c, 0x46, 0x61, 0x44, + 0x08, 0x00, 0x8c, 0x40, 0x11, 0x00, 0x82, 0x40, 0xd9, 0x40, 0x50, 0x1e, + 0x82, 0x41, 0x0c, 0x43, 0x14, 0x43, 0x5a, 0x46, 0xda, 0x40, 0x13, 0x00, + 0x62, 0x07, 0x09, 0xd0, 0x0f, 0x22, 0x22, 0x40, 0x04, 0x2a, 0x05, 0xd0, + 0x22, 0x00, 0x14, 0x1d, 0x94, 0x42, 0x89, 0x41, 0x49, 0x42, 0x5b, 0x18, + 0x1a, 0x02, 0x62, 0xd5, 0x01, 0x22, 0x00, 0x23, 0x00, 0x27, 0x0d, 0xe6, + 0x8a, 0x42, 0x00, 0xd8, 0x0a, 0xe7, 0x83, 0x1e, 0x89, 0x19, 0x07, 0xe7, + 0x0f, 0x23, 0x13, 0x40, 0x04, 0x2b, 0x00, 0xd1, 0xe6, 0xe5, 0x17, 0x1d, + 0x97, 0x42, 0x92, 0x41, 0x53, 0x42, 0x9b, 0x44, 0xfa, 0x08, 0xe0, 0xe5, + 0x00, 0x28, 0x00, 0xd1, 0xd7, 0xe5, 0x71, 0x18, 0x53, 0x1e, 0xb1, 0x42, + 0x27, 0xd3, 0xa9, 0x42, 0x15, 0xd3, 0x58, 0xd0, 0x1a, 0x00, 0x73, 0xe7, + 0x00, 0x2b, 0x00, 0xdc, 0x04, 0xe6, 0x01, 0x23, 0x00, 0x22, 0x9b, 0x44, + 0xcd, 0xe5, 0x02, 0x23, 0x47, 0x44, 0x47, 0x45, 0x89, 0x41, 0x5b, 0x42, + 0x9c, 0x46, 0x49, 0x42, 0x89, 0x19, 0x0c, 0x19, 0xe3, 0x44, 0x24, 0x1a, + 0x03, 0xe7, 0x43, 0x46, 0x5f, 0x00, 0x47, 0x45, 0x9b, 0x41, 0xb8, 0x46, + 0x5b, 0x42, 0x9e, 0x19, 0x02, 0x3a, 0x89, 0x19, 0xa9, 0x42, 0x00, 0xd0, + 0x54, 0xe7, 0x40, 0x45, 0x00, 0xd0, 0x51, 0xe7, 0xab, 0xe5, 0x1a, 0x00, + 0xf6, 0xe7, 0x1f, 0x21, 0x5f, 0x46, 0x49, 0x42, 0x0c, 0x1b, 0xe7, 0x40, + 0x20, 0x2b, 0x07, 0xd0, 0x1a, 0x49, 0x00, 0x9b, 0x8c, 0x46, 0x63, 0x44, + 0x18, 0x00, 0x5b, 0x46, 0x83, 0x40, 0x1a, 0x43, 0x50, 0x1e, 0x82, 0x41, + 0x3a, 0x43, 0x07, 0x27, 0x00, 0x23, 0x17, 0x40, 0x09, 0xd0, 0x0f, 0x21, + 0x00, 0x23, 0x11, 0x40, 0x14, 0x00, 0x04, 0x29, 0x95, 0xd1, 0x22, 0x00, + 0x5f, 0x07, 0x5b, 0x02, 0x1b, 0x0b, 0xd2, 0x08, 0x17, 0x43, 0x00, 0x22, + 0xa6, 0xe5, 0x80, 0x23, 0x59, 0x46, 0x1b, 0x03, 0x0b, 0x43, 0x1b, 0x03, + 0x17, 0x00, 0x1b, 0x0b, 0x06, 0x4a, 0x9d, 0xe5, 0xbd, 0x42, 0xb2, 0xd8, + 0x9b, 0x46, 0x00, 0x24, 0xbf, 0xe6, 0x80, 0x45, 0xb9, 0xd3, 0x1a, 0x00, + 0xc3, 0xe7, 0xc0, 0x46, 0xff, 0x03, 0x00, 0x00, 0xff, 0x07, 0x00, 0x00, + 0x1e, 0x04, 0x00, 0x00, 0x3e, 0x04, 0x00, 0x00, 0xf0, 0xb5, 0x4f, 0x46, + 0x46, 0x46, 0xd6, 0x46, 0x84, 0x46, 0xc0, 0xb5, 0x80, 0x46, 0x19, 0x4e, + 0x18, 0x03, 0x0f, 0x03, 0x4d, 0x00, 0x00, 0x0b, 0x5c, 0x00, 0x82, 0x46, + 0x3f, 0x0b, 0x6d, 0x0d, 0xc9, 0x0f, 0x91, 0x46, 0x64, 0x0d, 0xdb, 0x0f, + 0x01, 0x20, 0xb5, 0x42, 0x0a, 0xd0, 0xb4, 0x42, 0x03, 0xd0, 0xa5, 0x42, + 0x01, 0xd1, 0x57, 0x45, 0x0c, 0xd0, 0x1c, 0xbc, 0x90, 0x46, 0x99, 0x46, + 0xa2, 0x46, 0xf0, 0xbd, 0x66, 0x46, 0x3e, 0x43, 0xf7, 0xd1, 0xac, 0x42, + 0xf5, 0xd1, 0x54, 0x46, 0x14, 0x43, 0xf2, 0xd1, 0x01, 0x20, 0xc8, 0x45, + 0xef, 0xd1, 0x99, 0x42, 0x07, 0xd0, 0x00, 0x2d, 0xeb, 0xd1, 0x63, 0x46, + 0x1f, 0x43, 0x38, 0x00, 0x47, 0x1e, 0xb8, 0x41, 0xe5, 0xe7, 0x00, 0x20, + 0xe3, 0xe7, 0xc0, 0x46, 0xff, 0x07, 0x00, 0x00, 0xf0, 0xb5, 0x4f, 0x46, + 0x46, 0x46, 0xd6, 0x46, 0x4d, 0x00, 0xc0, 0xb5, 0x0e, 0x03, 0xc9, 0x0f, + 0x8a, 0x46, 0x2c, 0x49, 0x1f, 0x03, 0x5c, 0x00, 0x80, 0x46, 0x36, 0x0b, + 0x6d, 0x0d, 0x91, 0x46, 0x3f, 0x0b, 0x64, 0x0d, 0xdb, 0x0f, 0x8d, 0x42, + 0x1e, 0xd0, 0x8c, 0x42, 0x16, 0xd0, 0x00, 0x2d, 0x1e, 0xd1, 0x30, 0x43, + 0x84, 0x46, 0x00, 0x2c, 0x01, 0xd1, 0x3a, 0x43, 0x23, 0xd0, 0x62, 0x46, + 0x00, 0x2a, 0x1a, 0xd0, 0x9a, 0x45, 0x29, 0xd0, 0x51, 0x46, 0x02, 0x20, + 0x01, 0x39, 0x08, 0x40, 0x01, 0x38, 0x1c, 0xbc, 0x90, 0x46, 0x99, 0x46, + 0xa2, 0x46, 0xf0, 0xbd, 0x39, 0x00, 0x11, 0x43, 0xe5, 0xd0, 0x02, 0x20, + 0x40, 0x42, 0xf4, 0xe7, 0x30, 0x43, 0xfa, 0xd1, 0xac, 0x42, 0x0f, 0xd0, + 0x00, 0x2c, 0x0f, 0xd1, 0x3a, 0x43, 0xe7, 0xd0, 0x0c, 0xe0, 0x01, 0x22, + 0x01, 0x3b, 0x93, 0x43, 0x18, 0x00, 0x01, 0x30, 0xe5, 0xe7, 0x63, 0x46, + 0x00, 0x20, 0x00, 0x2b, 0xe1, 0xd0, 0xdb, 0xe7, 0x3a, 0x43, 0xe6, 0xd1, + 0x9a, 0x45, 0xd7, 0xd1, 0xa5, 0x42, 0xd5, 0xdc, 0xa5, 0x42, 0x05, 0xdb, + 0xbe, 0x42, 0xd1, 0xd8, 0x08, 0xd0, 0x00, 0x20, 0xbe, 0x42, 0xd2, 0xd2, + 0x50, 0x46, 0x01, 0x23, 0x01, 0x38, 0x98, 0x43, 0x01, 0x30, 0xcc, 0xe7, + 0xc8, 0x45, 0xc5, 0xd8, 0x00, 0x20, 0xc8, 0x45, 0xf4, 0xd3, 0xc6, 0xe7, + 0xff, 0x07, 0x00, 0x00, 0xf0, 0xb5, 0x4f, 0x46, 0x46, 0x46, 0xd6, 0x46, + 0x4d, 0x00, 0xc0, 0xb5, 0x0e, 0x03, 0xc9, 0x0f, 0x8a, 0x46, 0x2e, 0x49, + 0x1f, 0x03, 0x5c, 0x00, 0x80, 0x46, 0x36, 0x0b, 0x6d, 0x0d, 0x91, 0x46, + 0x3f, 0x0b, 0x64, 0x0d, 0xdb, 0x0f, 0x8d, 0x42, 0x18, 0xd0, 0x8c, 0x42, + 0x11, 0xd0, 0x00, 0x2d, 0x18, 0xd1, 0x30, 0x43, 0x84, 0x46, 0x00, 0x2c, + 0x1e, 0xd1, 0x3a, 0x43, 0x1c, 0xd1, 0x63, 0x46, 0x00, 0x20, 0x00, 0x2b, + 0x30, 0xd0, 0x51, 0x46, 0x02, 0x20, 0x01, 0x39, 0x08, 0x40, 0x01, 0x38, + 0x2a, 0xe0, 0x39, 0x00, 0x11, 0x43, 0xea, 0xd0, 0x02, 0x20, 0x25, 0xe0, + 0x30, 0x43, 0xfb, 0xd1, 0xac, 0x42, 0x26, 0xd0, 0x00, 0x2c, 0x26, 0xd1, + 0x3a, 0x43, 0x24, 0xd1, 0x51, 0x46, 0x02, 0x20, 0x01, 0x39, 0x08, 0x40, + 0x01, 0x38, 0x17, 0xe0, 0x62, 0x46, 0x00, 0x2a, 0x0f, 0xd0, 0x9a, 0x45, + 0xe1, 0xd1, 0xa5, 0x42, 0x05, 0xdb, 0xbe, 0x42, 0xdd, 0xd8, 0x19, 0xd0, + 0x00, 0x20, 0xbe, 0x42, 0x0a, 0xd2, 0x50, 0x46, 0x01, 0x23, 0x01, 0x38, + 0x98, 0x43, 0x01, 0x30, 0x04, 0xe0, 0x01, 0x22, 0x01, 0x3b, 0x93, 0x43, + 0x18, 0x00, 0x01, 0x30, 0x1c, 0xbc, 0x90, 0x46, 0x99, 0x46, 0xa2, 0x46, + 0xf0, 0xbd, 0x3a, 0x43, 0xd0, 0xd1, 0x9a, 0x45, 0xc5, 0xd1, 0xa5, 0x42, + 0xc3, 0xdc, 0xe0, 0xe7, 0xc8, 0x45, 0xc0, 0xd8, 0x00, 0x20, 0xc8, 0x45, + 0xe3, 0xd3, 0xed, 0xe7, 0xff, 0x07, 0x00, 0x00, 0xf0, 0xb5, 0x57, 0x46, + 0xde, 0x46, 0x4e, 0x46, 0x45, 0x46, 0xe0, 0xb5, 0x83, 0x46, 0x06, 0x00, + 0x0f, 0x03, 0x48, 0x00, 0x87, 0xb0, 0x92, 0x46, 0x1d, 0x00, 0x3f, 0x0b, + 0x40, 0x0d, 0xcc, 0x0f, 0x00, 0x28, 0x00, 0xd1, 0x6f, 0xe0, 0xde, 0x4b, + 0x98, 0x42, 0x38, 0xd0, 0x80, 0x23, 0xff, 0x00, 0x1b, 0x04, 0x1f, 0x43, + 0x73, 0x0f, 0x3b, 0x43, 0x01, 0x93, 0xda, 0x4b, 0x00, 0x27, 0x99, 0x46, + 0x00, 0x23, 0x9b, 0x46, 0xf6, 0x00, 0x81, 0x44, 0x2b, 0x03, 0x69, 0x00, + 0x1b, 0x0b, 0x52, 0x46, 0x98, 0x46, 0x49, 0x0d, 0xed, 0x0f, 0x00, 0x29, + 0x00, 0xd1, 0x85, 0xe0, 0xd0, 0x4b, 0x99, 0x42, 0x00, 0xd1, 0x73, 0xe0, + 0x43, 0x46, 0xda, 0x00, 0x80, 0x23, 0x1b, 0x04, 0x13, 0x43, 0x52, 0x46, + 0xcc, 0x48, 0x52, 0x0f, 0x84, 0x46, 0x13, 0x43, 0x52, 0x46, 0x00, 0x20, + 0x61, 0x44, 0xd2, 0x00, 0x89, 0x44, 0x21, 0x00, 0x69, 0x40, 0x00, 0x91, + 0x8c, 0x46, 0x01, 0x21, 0x49, 0x44, 0x8a, 0x46, 0x0f, 0x2f, 0x00, 0xd9, + 0x90, 0xe0, 0xc4, 0x49, 0xbf, 0x00, 0xcf, 0x59, 0xbf, 0x46, 0x5b, 0x46, + 0x3b, 0x43, 0x01, 0x93, 0x00, 0xd0, 0x6a, 0xe1, 0x02, 0x23, 0x08, 0x27, + 0x00, 0x26, 0x81, 0x46, 0x9b, 0x46, 0xc9, 0xe7, 0x32, 0x00, 0x58, 0x46, + 0x01, 0x9b, 0x61, 0x46, 0x00, 0x91, 0x02, 0x28, 0x00, 0xd1, 0x75, 0xe0, + 0x03, 0x28, 0x00, 0xd1, 0xfe, 0xe1, 0x01, 0x28, 0x00, 0xd0, 0x2c, 0xe1, + 0x00, 0x23, 0x00, 0x27, 0x00, 0x26, 0x00, 0x25, 0x3f, 0x03, 0x2a, 0x0d, + 0x3f, 0x0b, 0xb3, 0x48, 0x12, 0x05, 0x3a, 0x43, 0x02, 0x40, 0x1b, 0x05, + 0x13, 0x43, 0x00, 0x9a, 0x5b, 0x00, 0xd1, 0x07, 0x5b, 0x08, 0x0b, 0x43, + 0x30, 0x00, 0x19, 0x00, 0x07, 0xb0, 0x3c, 0xbc, 0x90, 0x46, 0x99, 0x46, + 0xa2, 0x46, 0xab, 0x46, 0xf0, 0xbd, 0x5b, 0x46, 0x3b, 0x43, 0x01, 0x93, + 0x00, 0xd1, 0x2f, 0xe1, 0x00, 0x2f, 0x00, 0xd1, 0xa5, 0xe1, 0x38, 0x00, + 0x00, 0xf0, 0xb0, 0xfd, 0x03, 0x00, 0x0b, 0x3b, 0x1c, 0x2b, 0x00, 0xdd, + 0x96, 0xe1, 0x1d, 0x22, 0xd3, 0x1a, 0x5a, 0x46, 0x01, 0x00, 0xda, 0x40, + 0x5e, 0x46, 0x08, 0x39, 0x8f, 0x40, 0x13, 0x00, 0x8e, 0x40, 0x3b, 0x43, + 0x01, 0x93, 0x9c, 0x4b, 0x00, 0x27, 0x1b, 0x1a, 0x99, 0x46, 0x00, 0x23, + 0x9b, 0x46, 0x7d, 0xe7, 0x41, 0x46, 0x53, 0x46, 0x0b, 0x43, 0x93, 0x49, + 0x8c, 0x46, 0xe1, 0x44, 0x00, 0x2b, 0x00, 0xd0, 0x1a, 0xe1, 0x02, 0x22, + 0x02, 0x20, 0x17, 0x43, 0x00, 0x22, 0x8c, 0xe7, 0x13, 0x43, 0x00, 0xd1, + 0x0d, 0xe1, 0x43, 0x46, 0x00, 0x2b, 0x00, 0xd1, 0x81, 0xe1, 0x40, 0x46, + 0x00, 0xf0, 0x80, 0xfd, 0x02, 0x00, 0x0b, 0x3a, 0x1c, 0x2a, 0x00, 0xdd, + 0x72, 0xe1, 0x01, 0x00, 0x43, 0x46, 0x08, 0x39, 0x8b, 0x40, 0x98, 0x46, + 0x1d, 0x23, 0x9a, 0x1a, 0x53, 0x46, 0xd3, 0x40, 0x1a, 0x00, 0x43, 0x46, + 0x13, 0x43, 0x52, 0x46, 0x8a, 0x40, 0x49, 0x46, 0x08, 0x1a, 0x82, 0x49, + 0x89, 0x46, 0x81, 0x44, 0x00, 0x20, 0x68, 0xe7, 0x7b, 0x4b, 0x00, 0x27, + 0x00, 0x26, 0x8e, 0xe7, 0x14, 0x0c, 0x12, 0x04, 0x12, 0x0c, 0x11, 0x00, + 0x37, 0x0c, 0x36, 0x04, 0x35, 0x0c, 0x79, 0x43, 0x28, 0x00, 0x8c, 0x46, + 0x2e, 0x00, 0x60, 0x43, 0x60, 0x44, 0x83, 0x46, 0x56, 0x43, 0x21, 0x00, + 0x30, 0x0c, 0x80, 0x46, 0x58, 0x46, 0x79, 0x43, 0x40, 0x44, 0x02, 0x91, + 0x84, 0x45, 0x06, 0xd9, 0x88, 0x46, 0x80, 0x21, 0x49, 0x02, 0x8c, 0x46, + 0xe0, 0x44, 0x41, 0x46, 0x02, 0x91, 0x36, 0x04, 0x01, 0x0c, 0x36, 0x0c, + 0x00, 0x04, 0x8b, 0x46, 0x81, 0x19, 0x1e, 0x0c, 0x1b, 0x04, 0x1b, 0x0c, + 0x03, 0x91, 0x19, 0x00, 0x79, 0x43, 0x8c, 0x46, 0x28, 0x00, 0x75, 0x43, + 0x65, 0x44, 0xa8, 0x46, 0x58, 0x43, 0x05, 0x0c, 0x45, 0x44, 0x77, 0x43, + 0xa9, 0x42, 0x03, 0xd9, 0x80, 0x21, 0x49, 0x02, 0x8c, 0x46, 0x67, 0x44, + 0x29, 0x0c, 0x8c, 0x46, 0x39, 0x00, 0x00, 0x04, 0x00, 0x0c, 0x2d, 0x04, + 0x2d, 0x18, 0x61, 0x44, 0xab, 0x44, 0x05, 0x91, 0x59, 0x46, 0x04, 0x91, + 0x01, 0x99, 0x0f, 0x04, 0x3f, 0x0c, 0x08, 0x0c, 0x39, 0x00, 0x51, 0x43, + 0x42, 0x43, 0x90, 0x46, 0x02, 0x00, 0x8c, 0x46, 0x09, 0x0c, 0x8b, 0x46, + 0x62, 0x43, 0x7c, 0x43, 0x44, 0x44, 0x5c, 0x44, 0xa0, 0x45, 0x03, 0xd9, + 0x80, 0x21, 0x49, 0x02, 0x88, 0x46, 0x42, 0x44, 0x21, 0x0c, 0x88, 0x46, + 0x61, 0x46, 0x09, 0x04, 0x09, 0x0c, 0x8c, 0x46, 0x39, 0x00, 0x59, 0x43, + 0x43, 0x43, 0x70, 0x43, 0x7e, 0x43, 0x0f, 0x0c, 0xf6, 0x18, 0x24, 0x04, + 0xbe, 0x19, 0x64, 0x44, 0x42, 0x44, 0x8c, 0x46, 0xb3, 0x42, 0x03, 0xd9, + 0x80, 0x23, 0x5b, 0x02, 0x98, 0x46, 0x40, 0x44, 0x02, 0x9b, 0x61, 0x46, + 0x98, 0x46, 0x04, 0x9b, 0x37, 0x04, 0x43, 0x44, 0x9b, 0x46, 0xab, 0x45, + 0xad, 0x41, 0x6b, 0x42, 0x0d, 0x04, 0x05, 0x99, 0x2d, 0x0c, 0x8c, 0x46, + 0x7f, 0x19, 0x67, 0x44, 0xfd, 0x18, 0xa8, 0x46, 0x5d, 0x46, 0x2d, 0x19, + 0xa5, 0x42, 0xa4, 0x41, 0x93, 0x46, 0x64, 0x42, 0xa4, 0x46, 0xc3, 0x44, + 0xdc, 0x44, 0x8f, 0x42, 0xbf, 0x41, 0x98, 0x45, 0x9b, 0x41, 0x93, 0x45, + 0x92, 0x41, 0xa4, 0x45, 0xa4, 0x41, 0x5b, 0x42, 0x7f, 0x42, 0x1f, 0x43, + 0x36, 0x0c, 0x52, 0x42, 0x64, 0x42, 0xbf, 0x19, 0x22, 0x43, 0xbf, 0x18, + 0x62, 0x46, 0x38, 0x18, 0x43, 0x02, 0xd2, 0x0d, 0x03, 0x99, 0x13, 0x43, + 0x6a, 0x02, 0x0a, 0x43, 0x50, 0x1e, 0x82, 0x41, 0x61, 0x46, 0xed, 0x0d, + 0x2a, 0x43, 0x4e, 0x02, 0x32, 0x43, 0xd9, 0x01, 0x00, 0xd4, 0xb3, 0xe0, + 0x01, 0x26, 0x50, 0x08, 0x32, 0x40, 0x02, 0x43, 0xde, 0x07, 0x32, 0x43, + 0x5b, 0x08, 0x22, 0x4c, 0x54, 0x44, 0x00, 0x2c, 0x62, 0xdd, 0x51, 0x07, + 0x09, 0xd0, 0x0f, 0x20, 0x10, 0x40, 0x04, 0x28, 0x05, 0xd0, 0x10, 0x1d, + 0x90, 0x42, 0x92, 0x41, 0x52, 0x42, 0x9b, 0x18, 0x02, 0x00, 0xd9, 0x01, + 0x04, 0xd5, 0x80, 0x24, 0x19, 0x48, 0xe4, 0x00, 0x03, 0x40, 0x54, 0x44, + 0x18, 0x48, 0x84, 0x42, 0x00, 0xdd, 0x27, 0xe7, 0x5e, 0x07, 0x5b, 0x02, + 0xd2, 0x08, 0x1f, 0x0b, 0x63, 0x05, 0x16, 0x43, 0x5b, 0x0d, 0xb2, 0xe6, + 0x00, 0x23, 0x99, 0x46, 0x01, 0x33, 0x04, 0x27, 0x00, 0x26, 0x9b, 0x46, + 0x64, 0xe6, 0x03, 0x23, 0x01, 0x97, 0x81, 0x46, 0x0c, 0x27, 0x9b, 0x46, + 0x5e, 0xe6, 0x01, 0x22, 0x01, 0x20, 0x17, 0x43, 0x00, 0x22, 0x76, 0xe6, + 0x03, 0x23, 0x03, 0x20, 0x1f, 0x43, 0x43, 0x46, 0x71, 0xe6, 0xc0, 0x46, + 0xff, 0x07, 0x00, 0x00, 0x01, 0xfc, 0xff, 0xff, 0xf8, 0x97, 0x00, 0x00, + 0xff, 0xff, 0x0f, 0x80, 0x0d, 0xfc, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, + 0xff, 0xff, 0xff, 0xfe, 0xfe, 0x07, 0x00, 0x00, 0x00, 0x23, 0x80, 0x27, + 0x00, 0x93, 0x3f, 0x03, 0x00, 0x26, 0x43, 0x4b, 0x83, 0xe6, 0x01, 0x9b, + 0x32, 0x00, 0xa4, 0x46, 0x58, 0x46, 0x70, 0xe6, 0xac, 0x46, 0x6e, 0xe6, + 0x80, 0x27, 0x01, 0x99, 0x3f, 0x03, 0x39, 0x42, 0x2d, 0xd0, 0x3b, 0x42, + 0x2b, 0xd1, 0x1f, 0x43, 0x3f, 0x03, 0x3f, 0x0b, 0x00, 0x95, 0x16, 0x00, + 0x38, 0x4b, 0x6e, 0xe6, 0x01, 0x25, 0x2d, 0x1b, 0x38, 0x2d, 0x00, 0xdd, + 0x66, 0xe6, 0x1f, 0x2d, 0x40, 0xdc, 0x35, 0x48, 0x1c, 0x00, 0x50, 0x44, + 0x16, 0x00, 0x82, 0x40, 0x84, 0x40, 0xee, 0x40, 0x50, 0x1e, 0x82, 0x41, + 0x34, 0x43, 0x14, 0x43, 0xeb, 0x40, 0x62, 0x07, 0x09, 0xd0, 0x0f, 0x22, + 0x22, 0x40, 0x04, 0x2a, 0x05, 0xd0, 0x22, 0x00, 0x14, 0x1d, 0x94, 0x42, + 0x80, 0x41, 0x40, 0x42, 0x1b, 0x18, 0x1a, 0x02, 0x3e, 0xd5, 0x01, 0x23, + 0x00, 0x27, 0x00, 0x26, 0x49, 0xe6, 0x80, 0x27, 0x01, 0x9b, 0x3f, 0x03, + 0x1f, 0x43, 0x3f, 0x03, 0x3f, 0x0b, 0x00, 0x94, 0x21, 0x4b, 0x40, 0xe6, + 0x03, 0x00, 0x5a, 0x46, 0x28, 0x3b, 0x9a, 0x40, 0x00, 0x26, 0x01, 0x92, + 0x6d, 0xe6, 0x58, 0x46, 0x00, 0xf0, 0x0a, 0xfc, 0x20, 0x30, 0x57, 0xe6, + 0x03, 0x00, 0x52, 0x46, 0x28, 0x3b, 0x9a, 0x40, 0x13, 0x00, 0x00, 0x22, + 0x93, 0xe6, 0x50, 0x46, 0x00, 0xf0, 0xfe, 0xfb, 0x20, 0x30, 0x7b, 0xe6, + 0xca, 0x46, 0x50, 0xe7, 0x1f, 0x20, 0x1e, 0x00, 0x40, 0x42, 0x04, 0x1b, + 0xe6, 0x40, 0x20, 0x2d, 0x03, 0xd0, 0x12, 0x4c, 0x54, 0x44, 0xa3, 0x40, + 0x1a, 0x43, 0x50, 0x1e, 0x82, 0x41, 0x32, 0x43, 0x07, 0x26, 0x00, 0x27, + 0x16, 0x40, 0x09, 0xd0, 0x0f, 0x20, 0x00, 0x23, 0x10, 0x40, 0x14, 0x00, + 0x04, 0x28, 0xb9, 0xd1, 0x22, 0x00, 0x5e, 0x07, 0x5b, 0x02, 0x1f, 0x0b, + 0xd2, 0x08, 0x16, 0x43, 0x00, 0x23, 0x06, 0xe6, 0x80, 0x27, 0x3f, 0x03, + 0x1f, 0x43, 0x3f, 0x03, 0x3f, 0x0b, 0x16, 0x00, 0x00, 0x4b, 0xfe, 0xe5, + 0xff, 0x07, 0x00, 0x00, 0x1e, 0x04, 0x00, 0x00, 0x3e, 0x04, 0x00, 0x00, + 0xf8, 0xb5, 0x57, 0x46, 0x4e, 0x46, 0x45, 0x46, 0xde, 0x46, 0x0c, 0x00, + 0x09, 0x03, 0xe0, 0xb5, 0x49, 0x0a, 0x46, 0x0f, 0x5f, 0x00, 0x31, 0x43, + 0x1e, 0x03, 0xdb, 0x0f, 0x76, 0x0a, 0x9b, 0x46, 0x53, 0x0f, 0x33, 0x43, + 0xc8, 0x4e, 0x65, 0x00, 0xc0, 0x00, 0xe4, 0x0f, 0xd2, 0x00, 0x6d, 0x0d, + 0xa2, 0x46, 0x81, 0x46, 0x7f, 0x0d, 0x9c, 0x46, 0x90, 0x46, 0xb7, 0x42, + 0x00, 0xd1, 0xb9, 0xe0, 0x5b, 0x46, 0x01, 0x26, 0x73, 0x40, 0x9b, 0x46, + 0xee, 0x1b, 0xa3, 0x45, 0x00, 0xd1, 0x83, 0xe0, 0x00, 0x2e, 0x63, 0xdd, + 0x00, 0x2f, 0x00, 0xd0, 0xb1, 0xe0, 0x63, 0x46, 0x13, 0x43, 0x00, 0xd1, + 0x23, 0xe1, 0x73, 0x1e, 0x00, 0x2b, 0x00, 0xd0, 0xba, 0xe1, 0x86, 0x1a, + 0x63, 0x46, 0xb0, 0x42, 0x80, 0x41, 0x01, 0x25, 0xc9, 0x1a, 0x40, 0x42, + 0x09, 0x1a, 0x0b, 0x02, 0x00, 0xd4, 0x47, 0xe1, 0x49, 0x02, 0x4b, 0x0a, + 0x98, 0x46, 0x43, 0x46, 0x00, 0x2b, 0x00, 0xd1, 0x89, 0xe1, 0x40, 0x46, + 0x00, 0xf0, 0x82, 0xfb, 0x03, 0x00, 0x08, 0x3b, 0x1f, 0x2b, 0x00, 0xdd, + 0x7c, 0xe1, 0x20, 0x22, 0x30, 0x00, 0xd2, 0x1a, 0x41, 0x46, 0xd0, 0x40, + 0x99, 0x40, 0x02, 0x00, 0x9e, 0x40, 0x0a, 0x43, 0x9d, 0x42, 0x00, 0xdd, + 0x6a, 0xe1, 0x5d, 0x1b, 0x6b, 0x1c, 0x1f, 0x2b, 0x00, 0xdd, 0x94, 0xe1, + 0x20, 0x21, 0x10, 0x00, 0x35, 0x00, 0xc9, 0x1a, 0x8e, 0x40, 0xda, 0x40, + 0x88, 0x40, 0xdd, 0x40, 0x71, 0x1e, 0x8e, 0x41, 0x11, 0x00, 0x07, 0x22, + 0x28, 0x43, 0x00, 0x25, 0x06, 0x43, 0x32, 0x40, 0x00, 0x2a, 0x09, 0xd0, + 0x0f, 0x23, 0x33, 0x40, 0x04, 0x2b, 0x05, 0xd0, 0x33, 0x1d, 0xb3, 0x42, + 0xb6, 0x41, 0x76, 0x42, 0x89, 0x19, 0x1e, 0x00, 0x0b, 0x02, 0x00, 0xd4, + 0x3d, 0xe2, 0x6a, 0x1c, 0x91, 0x4b, 0x55, 0x05, 0x6d, 0x0d, 0x9a, 0x42, + 0x00, 0xd1, 0x19, 0xe1, 0x8f, 0x4a, 0xf6, 0x08, 0x0a, 0x40, 0x57, 0x07, + 0x52, 0x02, 0x37, 0x43, 0x12, 0x0b, 0x9b, 0xe0, 0x00, 0x2e, 0x00, 0xd0, + 0xc5, 0xe0, 0x6e, 0x1c, 0x76, 0x05, 0x76, 0x0d, 0x01, 0x2e, 0x00, 0xdc, + 0x48, 0xe1, 0x67, 0x46, 0x86, 0x1a, 0xcb, 0x1b, 0xb0, 0x42, 0xbf, 0x41, + 0x7f, 0x42, 0xb8, 0x46, 0x1f, 0x00, 0x43, 0x46, 0xff, 0x1a, 0x3b, 0x00, + 0xb8, 0x46, 0x1b, 0x02, 0x00, 0xd5, 0x5f, 0xe1, 0x37, 0x43, 0x9a, 0xd1, + 0x00, 0x22, 0x00, 0x24, 0x00, 0x25, 0x79, 0xe0, 0x00, 0x2e, 0x00, 0xdc, + 0xfa, 0xe0, 0x00, 0x2f, 0x00, 0xd1, 0x8d, 0xe0, 0x78, 0x4b, 0x9d, 0x42, + 0x67, 0xd0, 0x80, 0x23, 0x67, 0x46, 0x1b, 0x04, 0x1f, 0x43, 0xbc, 0x46, + 0x38, 0x2e, 0x00, 0xdc, 0x52, 0xe1, 0x63, 0x46, 0x13, 0x43, 0x5a, 0x1e, + 0x93, 0x41, 0x1e, 0x18, 0x86, 0x42, 0x80, 0x41, 0x40, 0x42, 0x09, 0x18, + 0x0b, 0x02, 0x00, 0xd4, 0xbe, 0xe0, 0x6d, 0x4b, 0x01, 0x35, 0x9d, 0x42, + 0x00, 0xd1, 0xd2, 0xe0, 0x6b, 0x4a, 0x73, 0x08, 0x0a, 0x40, 0x01, 0x21, + 0x0e, 0x40, 0x1e, 0x43, 0x51, 0x08, 0xd3, 0x07, 0x07, 0x22, 0x1e, 0x43, + 0x32, 0x40, 0x95, 0xe7, 0x1e, 0x00, 0x16, 0x43, 0x00, 0xd0, 0x45, 0xe7, + 0x40, 0xe7, 0x62, 0x4b, 0x9d, 0x42, 0x3a, 0xd0, 0x80, 0x23, 0x67, 0x46, + 0x1b, 0x04, 0x1f, 0x43, 0xbc, 0x46, 0x38, 0x2e, 0x00, 0xdd, 0xeb, 0xe0, + 0x1f, 0x2e, 0x00, 0xdc, 0x3a, 0xe1, 0x33, 0x00, 0x67, 0x46, 0x20, 0x3b, + 0xdf, 0x40, 0x3b, 0x00, 0x20, 0x2e, 0x05, 0xd0, 0x40, 0x27, 0xbf, 0x1b, + 0x66, 0x46, 0xbe, 0x40, 0x32, 0x43, 0x90, 0x46, 0x46, 0x46, 0x72, 0x1e, + 0x96, 0x41, 0x33, 0x43, 0xda, 0xe0, 0x00, 0x2b, 0x00, 0xd1, 0x14, 0xe2, + 0x63, 0x46, 0x13, 0x43, 0x00, 0xd1, 0x68, 0xe1, 0x80, 0x23, 0x4e, 0x07, + 0xc0, 0x08, 0xc9, 0x08, 0x1b, 0x03, 0x06, 0x43, 0x19, 0x42, 0x08, 0xd0, + 0x60, 0x46, 0xc0, 0x08, 0x18, 0x42, 0x04, 0xd1, 0x63, 0x46, 0x01, 0x00, + 0xd2, 0x08, 0x5e, 0x07, 0x16, 0x43, 0xf3, 0x00, 0x99, 0x46, 0xc9, 0x00, + 0x72, 0x0f, 0x44, 0x4d, 0x11, 0x43, 0x4b, 0x46, 0xde, 0x08, 0x42, 0x4b, + 0x4f, 0x07, 0x37, 0x43, 0xca, 0x08, 0x9d, 0x42, 0x00, 0xd1, 0x6e, 0xe0, + 0x12, 0x03, 0x6d, 0x05, 0x12, 0x0b, 0x6d, 0x0d, 0x00, 0x21, 0x12, 0x03, + 0x13, 0x0b, 0x0a, 0x0d, 0x12, 0x05, 0x1a, 0x43, 0x3b, 0x4b, 0x2d, 0x05, + 0x13, 0x40, 0x2b, 0x43, 0x5b, 0x00, 0xe4, 0x07, 0x5b, 0x08, 0x23, 0x43, + 0x38, 0x00, 0x19, 0x00, 0x3c, 0xbc, 0x90, 0x46, 0x99, 0x46, 0xa2, 0x46, + 0xab, 0x46, 0xf8, 0xbd, 0x63, 0x46, 0x13, 0x43, 0x11, 0xd0, 0x73, 0x1e, + 0x00, 0x2b, 0x00, 0xd0, 0x07, 0xe1, 0x86, 0x18, 0x86, 0x42, 0x80, 0x41, + 0x61, 0x44, 0x40, 0x42, 0x09, 0x18, 0x01, 0x25, 0x0b, 0x02, 0x37, 0xd5, + 0x02, 0x25, 0x7b, 0xe7, 0x3e, 0x00, 0x61, 0x46, 0x91, 0x46, 0x35, 0x00, + 0xc5, 0xe7, 0x5c, 0x46, 0x00, 0x2d, 0x00, 0xd0, 0xe1, 0xe0, 0x0b, 0x00, + 0x03, 0x43, 0xf3, 0xd0, 0x73, 0x1c, 0x00, 0xd1, 0xac, 0xe1, 0x21, 0x4b, + 0x9f, 0x42, 0x00, 0xd1, 0x3a, 0xe1, 0xf3, 0x43, 0x38, 0x2b, 0x00, 0xdd, + 0x6f, 0xe1, 0x1f, 0x2b, 0x00, 0xdd, 0x8c, 0xe1, 0x20, 0x25, 0x0e, 0x00, + 0xed, 0x1a, 0xae, 0x40, 0xb0, 0x46, 0x06, 0x00, 0xaa, 0x46, 0xde, 0x40, + 0x45, 0x46, 0x35, 0x43, 0x2e, 0x00, 0x55, 0x46, 0xd9, 0x40, 0xa8, 0x40, + 0x63, 0x46, 0x45, 0x1e, 0xa8, 0x41, 0x5b, 0x1a, 0x9c, 0x46, 0x30, 0x43, + 0x16, 0x1a, 0xb2, 0x42, 0x92, 0x41, 0x63, 0x46, 0x52, 0x42, 0x99, 0x1a, + 0x3d, 0x00, 0xb4, 0xe6, 0x07, 0x22, 0x32, 0x40, 0x00, 0x2a, 0x00, 0xd0, + 0xe4, 0xe6, 0x0b, 0x4b, 0xf6, 0x08, 0x4f, 0x07, 0x37, 0x43, 0xca, 0x08, + 0x9d, 0x42, 0x00, 0xd0, 0x90, 0xe7, 0x3b, 0x00, 0x13, 0x43, 0x00, 0xd1, + 0xa6, 0xe1, 0x80, 0x23, 0x1b, 0x03, 0x1a, 0x43, 0x12, 0x03, 0x12, 0x0b, + 0x02, 0x4d, 0x89, 0xe7, 0x15, 0x00, 0x00, 0x22, 0x00, 0x27, 0x85, 0xe7, + 0xff, 0x07, 0x00, 0x00, 0xff, 0xff, 0x7f, 0xff, 0xff, 0xff, 0x0f, 0x80, + 0x00, 0x2e, 0x00, 0xd0, 0xc7, 0xe0, 0x6b, 0x1c, 0x5e, 0x05, 0x76, 0x0d, + 0x01, 0x2e, 0x00, 0xdc, 0xf0, 0xe0, 0xc8, 0x4d, 0xab, 0x42, 0x00, 0xd1, + 0xb9, 0xe0, 0x85, 0x18, 0x0a, 0x00, 0x85, 0x42, 0x89, 0x41, 0x62, 0x44, + 0x49, 0x42, 0x51, 0x18, 0x07, 0x22, 0xce, 0x07, 0x6d, 0x08, 0x2e, 0x43, + 0x49, 0x08, 0x32, 0x40, 0x1d, 0x00, 0xa9, 0xe6, 0xbf, 0x49, 0xed, 0x1a, + 0x11, 0x40, 0x07, 0x22, 0x32, 0x40, 0xa3, 0xe6, 0x32, 0x00, 0x28, 0x38, + 0x82, 0x40, 0x00, 0x26, 0x86, 0xe6, 0x30, 0x00, 0x00, 0xf0, 0xf8, 0xf9, + 0x20, 0x30, 0x73, 0xe6, 0x63, 0x46, 0x13, 0x43, 0x5a, 0x1e, 0x93, 0x41, + 0xc6, 0x1a, 0xb0, 0x42, 0x80, 0x41, 0x40, 0x42, 0x09, 0x1a, 0x5c, 0xe6, + 0x0e, 0x00, 0x67, 0x46, 0x06, 0x43, 0x17, 0x43, 0x00, 0x2d, 0x5e, 0xd1, + 0x00, 0x2e, 0x00, 0xd0, 0xf3, 0xe0, 0x00, 0x2f, 0x00, 0xd1, 0x1e, 0xe1, + 0x5c, 0x46, 0x61, 0x46, 0x91, 0x46, 0x2c, 0xe7, 0xa9, 0x4f, 0xbe, 0x42, + 0x7b, 0xd0, 0x1e, 0x00, 0xf1, 0xe6, 0x10, 0x00, 0x1f, 0x3d, 0xe8, 0x40, + 0x20, 0x2b, 0x03, 0xd0, 0x40, 0x21, 0xcb, 0x1a, 0x9a, 0x40, 0x16, 0x43, + 0x73, 0x1e, 0x9e, 0x41, 0x07, 0x22, 0x06, 0x43, 0x32, 0x40, 0x00, 0x21, + 0x00, 0x25, 0x83, 0xe7, 0x16, 0x1a, 0x63, 0x46, 0xb2, 0x42, 0x80, 0x41, + 0x59, 0x1a, 0x40, 0x42, 0x0b, 0x1a, 0x98, 0x46, 0x5c, 0x46, 0x32, 0xe6, + 0x1f, 0x2e, 0x00, 0xdd, 0xab, 0xe0, 0x20, 0x27, 0xbb, 0x1b, 0x9a, 0x46, + 0x63, 0x46, 0x57, 0x46, 0xbb, 0x40, 0x99, 0x46, 0x13, 0x00, 0x4f, 0x46, + 0xf3, 0x40, 0x1f, 0x43, 0x3b, 0x00, 0x57, 0x46, 0xba, 0x40, 0x57, 0x1e, + 0xba, 0x41, 0x13, 0x43, 0x62, 0x46, 0xf2, 0x40, 0x89, 0x18, 0x98, 0xe6, + 0x20, 0x27, 0xbb, 0x1b, 0x9a, 0x46, 0x63, 0x46, 0x57, 0x46, 0xbb, 0x40, + 0x99, 0x46, 0x13, 0x00, 0x4f, 0x46, 0xf3, 0x40, 0x1f, 0x43, 0x3b, 0x00, + 0x57, 0x46, 0xba, 0x40, 0x57, 0x1e, 0xba, 0x41, 0x13, 0x43, 0x62, 0x46, + 0xf2, 0x40, 0x89, 0x1a, 0x9c, 0xe7, 0x83, 0x4b, 0x9f, 0x42, 0x5f, 0xd0, + 0x80, 0x25, 0x2d, 0x04, 0x73, 0x42, 0x29, 0x43, 0x20, 0xe7, 0x00, 0x2e, + 0x0c, 0xd1, 0x00, 0x2f, 0x00, 0xd1, 0xd0, 0xe0, 0x5c, 0x46, 0x61, 0x46, + 0x91, 0x46, 0x7b, 0x4d, 0xcd, 0xe6, 0x7a, 0x4f, 0xbe, 0x42, 0x1c, 0xd0, + 0x1e, 0x00, 0x65, 0xe6, 0x00, 0x2f, 0x18, 0xd0, 0xc0, 0x08, 0x4e, 0x07, + 0x06, 0x43, 0x80, 0x20, 0xc9, 0x08, 0x00, 0x03, 0x01, 0x42, 0x08, 0xd0, + 0x63, 0x46, 0xdc, 0x08, 0x04, 0x42, 0x04, 0xd1, 0x21, 0x00, 0xda, 0x46, + 0xd2, 0x08, 0x5e, 0x07, 0x16, 0x43, 0xf3, 0x00, 0x99, 0x46, 0x01, 0x24, + 0x53, 0x46, 0xc9, 0x00, 0x72, 0x0f, 0x11, 0x43, 0x1c, 0x40, 0x6a, 0x4d, + 0xab, 0xe6, 0x1d, 0x00, 0x00, 0x22, 0x00, 0x27, 0xb4, 0xe6, 0x00, 0x2d, + 0x59, 0xd1, 0x0b, 0x00, 0x03, 0x43, 0x00, 0xd1, 0xd6, 0xe6, 0x73, 0x1c, + 0x00, 0xd1, 0xb2, 0xe0, 0x62, 0x4b, 0x9f, 0x42, 0x1e, 0xd0, 0xf3, 0x43, + 0x38, 0x2b, 0x6f, 0xdc, 0x1f, 0x2b, 0x00, 0xdd, 0x97, 0xe0, 0x20, 0x25, + 0x0e, 0x00, 0xed, 0x1a, 0xae, 0x40, 0xb0, 0x46, 0x06, 0x00, 0xaa, 0x46, + 0xde, 0x40, 0x45, 0x46, 0x35, 0x43, 0x2e, 0x00, 0x55, 0x46, 0xa8, 0x40, + 0xd9, 0x40, 0x45, 0x1e, 0xa8, 0x41, 0x8c, 0x44, 0x06, 0x43, 0xb6, 0x18, + 0x96, 0x42, 0x92, 0x41, 0x51, 0x42, 0x61, 0x44, 0x3d, 0x00, 0x25, 0xe6, + 0x3d, 0x00, 0x61, 0x46, 0x91, 0x46, 0x78, 0xe6, 0x0b, 0x00, 0x03, 0x43, + 0x00, 0x2d, 0x00, 0xd0, 0x55, 0xe6, 0x00, 0x2b, 0xf5, 0xd0, 0x63, 0x46, + 0x13, 0x43, 0x00, 0xd1, 0x6d, 0xe6, 0x86, 0x18, 0x86, 0x42, 0x80, 0x41, + 0x61, 0x44, 0x40, 0x42, 0x09, 0x18, 0x00, 0x22, 0x0b, 0x02, 0x00, 0xd4, + 0xd0, 0xe6, 0x46, 0x4b, 0x01, 0x35, 0x19, 0x40, 0xb2, 0xe5, 0xb1, 0x46, + 0x5d, 0xe6, 0x33, 0x00, 0x67, 0x46, 0x20, 0x3b, 0xdf, 0x40, 0x3b, 0x00, + 0x20, 0x2e, 0x05, 0xd0, 0x40, 0x27, 0xbf, 0x1b, 0x66, 0x46, 0xbe, 0x40, + 0x32, 0x43, 0x90, 0x46, 0x46, 0x46, 0x72, 0x1e, 0x96, 0x41, 0x33, 0x43, + 0xef, 0xe5, 0x39, 0x4b, 0x9f, 0x42, 0xcb, 0xd0, 0x80, 0x25, 0x2d, 0x04, + 0x73, 0x42, 0x29, 0x43, 0xa8, 0xe7, 0x08, 0x43, 0x41, 0x1e, 0x88, 0x41, + 0xa2, 0xe6, 0x00, 0x2f, 0x00, 0xd1, 0x3c, 0xe6, 0x63, 0x46, 0x86, 0x1a, + 0xcf, 0x1a, 0xb0, 0x42, 0x9b, 0x41, 0x5b, 0x42, 0xfb, 0x1a, 0x98, 0x46, + 0x1b, 0x02, 0x4e, 0xd5, 0x16, 0x1a, 0x63, 0x46, 0xb2, 0x42, 0x92, 0x41, + 0x59, 0x1a, 0x52, 0x42, 0x89, 0x1a, 0x5c, 0x46, 0x00, 0x22, 0x7b, 0xe5, + 0x01, 0x43, 0x0e, 0x00, 0x71, 0x1e, 0x8e, 0x41, 0x9f, 0xe7, 0x1d, 0x00, + 0x0e, 0x00, 0x20, 0x3d, 0xee, 0x40, 0xb0, 0x46, 0x20, 0x2b, 0x04, 0xd0, + 0x40, 0x25, 0xeb, 0x1a, 0x99, 0x40, 0x08, 0x43, 0x81, 0x46, 0x48, 0x46, + 0x43, 0x46, 0x41, 0x1e, 0x88, 0x41, 0x18, 0x43, 0x74, 0xe6, 0x00, 0x22, + 0x00, 0x24, 0x17, 0xe6, 0x16, 0x1a, 0x63, 0x46, 0xb2, 0x42, 0x92, 0x41, + 0x59, 0x1a, 0x52, 0x42, 0x89, 0x1a, 0x3d, 0x00, 0x25, 0xe5, 0x61, 0x46, + 0x91, 0x46, 0x15, 0x4d, 0x01, 0xe6, 0x80, 0x22, 0x00, 0x24, 0x12, 0x03, + 0x79, 0xe6, 0x1d, 0x00, 0x0e, 0x00, 0x20, 0x3d, 0xee, 0x40, 0xb0, 0x46, + 0x20, 0x2b, 0x04, 0xd0, 0x40, 0x25, 0xeb, 0x1a, 0x99, 0x40, 0x08, 0x43, + 0x81, 0x46, 0x4e, 0x46, 0x43, 0x46, 0x71, 0x1e, 0x8e, 0x41, 0x1e, 0x43, + 0x67, 0xe7, 0x86, 0x18, 0x96, 0x42, 0x9b, 0x41, 0x61, 0x44, 0x5b, 0x42, + 0xc9, 0x18, 0x3d, 0x00, 0x8c, 0xe5, 0x47, 0x46, 0x37, 0x43, 0xce, 0xd0, + 0x07, 0x22, 0x41, 0x46, 0x32, 0x40, 0x49, 0xe6, 0x00, 0x27, 0x3a, 0x00, + 0xe6, 0xe5, 0xc0, 0x46, 0xff, 0x07, 0x00, 0x00, 0xff, 0xff, 0x7f, 0xff, + 0x70, 0xb5, 0x0c, 0x4e, 0x0d, 0x03, 0x1c, 0x03, 0x49, 0x00, 0x5b, 0x00, + 0x2d, 0x0b, 0x49, 0x0d, 0x24, 0x0b, 0x5b, 0x0d, 0xb1, 0x42, 0x08, 0xd0, + 0x06, 0x49, 0x00, 0x20, 0x8b, 0x42, 0x03, 0xd1, 0x14, 0x43, 0x20, 0x00, + 0x44, 0x1e, 0xa0, 0x41, 0x70, 0xbd, 0x05, 0x43, 0x01, 0x20, 0x00, 0x2d, + 0xfa, 0xd1, 0xf1, 0xe7, 0xff, 0x07, 0x00, 0x00, 0x30, 0xb5, 0x14, 0x4d, + 0x0a, 0x03, 0x4b, 0x00, 0x12, 0x0b, 0x5b, 0x0d, 0xc9, 0x0f, 0x00, 0x24, + 0xab, 0x42, 0x11, 0xdd, 0x10, 0x4c, 0xa3, 0x42, 0x10, 0xdc, 0x80, 0x24, + 0x64, 0x03, 0x22, 0x43, 0x0e, 0x4c, 0xe4, 0x1a, 0x1f, 0x2c, 0x0c, 0xdd, + 0x0d, 0x48, 0xc3, 0x1a, 0xda, 0x40, 0x13, 0x00, 0x5c, 0x42, 0x00, 0x29, + 0x00, 0xd1, 0x1c, 0x00, 0x20, 0x00, 0x30, 0xbd, 0x09, 0x4b, 0xcc, 0x18, + 0xfa, 0xe7, 0x09, 0x4d, 0xe0, 0x40, 0xac, 0x46, 0x63, 0x44, 0x9a, 0x40, + 0x13, 0x00, 0x03, 0x43, 0xee, 0xe7, 0xc0, 0x46, 0xfe, 0x03, 0x00, 0x00, + 0x1d, 0x04, 0x00, 0x00, 0x33, 0x04, 0x00, 0x00, 0x13, 0x04, 0x00, 0x00, + 0xff, 0xff, 0xff, 0x7f, 0xed, 0xfb, 0xff, 0xff, 0x10, 0xb5, 0x04, 0x1e, + 0x25, 0xd0, 0x00, 0xf0, 0x2d, 0xf8, 0x14, 0x4b, 0x1b, 0x1a, 0x5b, 0x05, + 0x5b, 0x0d, 0x0a, 0x28, 0x12, 0xdd, 0x0b, 0x38, 0x84, 0x40, 0x00, 0x22, + 0x24, 0x03, 0x24, 0x0b, 0x00, 0x21, 0x10, 0x00, 0x24, 0x03, 0x0a, 0x0d, + 0x24, 0x0b, 0x12, 0x05, 0x22, 0x43, 0x0c, 0x4c, 0x1b, 0x05, 0x22, 0x40, + 0x13, 0x43, 0x5b, 0x00, 0x59, 0x08, 0x10, 0xbd, 0x02, 0x00, 0x21, 0x00, + 0x15, 0x32, 0x91, 0x40, 0x0a, 0x00, 0x0b, 0x21, 0x08, 0x1a, 0xc4, 0x40, + 0x24, 0x03, 0x24, 0x0b, 0xe6, 0xe7, 0x00, 0x23, 0x00, 0x24, 0x00, 0x22, + 0xe2, 0xe7, 0xc0, 0x46, 0x1e, 0x04, 0x00, 0x00, 0xff, 0xff, 0x0f, 0x80, + 0x1c, 0x21, 0x01, 0x23, 0x1b, 0x04, 0x98, 0x42, 0x01, 0xd3, 0x00, 0x0c, + 0x10, 0x39, 0x1b, 0x0a, 0x98, 0x42, 0x01, 0xd3, 0x00, 0x0a, 0x08, 0x39, + 0x1b, 0x09, 0x98, 0x42, 0x01, 0xd3, 0x00, 0x09, 0x04, 0x39, 0x02, 0xa2, + 0x10, 0x5c, 0x40, 0x18, 0x70, 0x47, 0xc0, 0x46, 0x04, 0x03, 0x02, 0x02, + 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x10, 0xb5, 0x0a, 0x22, 0x00, 0x21, 0x00, 0xf0, 0xa1, 0xfe, 0x10, 0xbd, + 0x10, 0xb5, 0x04, 0x00, 0x04, 0x48, 0x13, 0x00, 0x00, 0x28, 0x04, 0xd0, + 0x0a, 0x00, 0x02, 0x20, 0x21, 0x00, 0x00, 0xe0, 0x00, 0xbf, 0x10, 0xbd, + 0x00, 0x00, 0x00, 0x00, 0x70, 0xb5, 0x00, 0x26, 0x0c, 0x4d, 0x0d, 0x4c, + 0x64, 0x1b, 0xa4, 0x10, 0xa6, 0x42, 0x09, 0xd1, 0x00, 0x26, 0x02, 0xf0, + 0x29, 0xfa, 0x0a, 0x4d, 0x0a, 0x4c, 0x64, 0x1b, 0xa4, 0x10, 0xa6, 0x42, + 0x05, 0xd1, 0x70, 0xbd, 0xb3, 0x00, 0xeb, 0x58, 0x98, 0x47, 0x01, 0x36, + 0xee, 0xe7, 0xb3, 0x00, 0xeb, 0x58, 0x98, 0x47, 0x01, 0x36, 0xf2, 0xe7, + 0xf8, 0x01, 0x00, 0x20, 0xf8, 0x01, 0x00, 0x20, 0xf8, 0x01, 0x00, 0x20, + 0x30, 0x02, 0x00, 0x20, 0x10, 0xb5, 0x04, 0x00, 0x00, 0xf0, 0x08, 0xf8, + 0x08, 0x23, 0x00, 0x19, 0x40, 0x78, 0x18, 0x40, 0x10, 0xbd, 0xec, 0x30, + 0x00, 0x68, 0x70, 0x47, 0x04, 0x4b, 0x1b, 0x68, 0x1b, 0x6a, 0x00, 0x2b, + 0x00, 0xd1, 0x03, 0x4b, 0xec, 0x33, 0x18, 0x68, 0x70, 0x47, 0xc0, 0x46, + 0x28, 0x00, 0x00, 0x20, 0x8c, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x03, 0x4b, + 0x01, 0x00, 0x18, 0x68, 0x00, 0xf0, 0x8e, 0xf8, 0x10, 0xbd, 0xc0, 0x46, + 0x28, 0x00, 0x00, 0x20, 0x10, 0xb5, 0x03, 0x4b, 0x01, 0x00, 0x18, 0x68, + 0x00, 0xf0, 0x3a, 0xf8, 0x10, 0xbd, 0xc0, 0x46, 0x28, 0x00, 0x00, 0x20, + 0x82, 0xb0, 0x00, 0x29, 0x00, 0xd1, 0x01, 0xa9, 0x10, 0x1e, 0x06, 0xd0, + 0x00, 0x2b, 0x06, 0xd0, 0x13, 0x78, 0x0b, 0x60, 0x10, 0x78, 0x43, 0x1e, + 0x98, 0x41, 0x02, 0xb0, 0x70, 0x47, 0x02, 0x20, 0x40, 0x42, 0xfa, 0xe7, + 0x00, 0x23, 0x10, 0xb5, 0x9a, 0x42, 0x00, 0xd1, 0x10, 0xbd, 0xcc, 0x5c, + 0xc4, 0x54, 0x01, 0x33, 0xf8, 0xe7, 0x10, 0xb5, 0x88, 0x42, 0x02, 0xd9, + 0x8b, 0x18, 0x98, 0x42, 0x03, 0xd3, 0x00, 0x23, 0x07, 0xe0, 0x8b, 0x5c, + 0x83, 0x54, 0x01, 0x3a, 0xfb, 0xd2, 0x10, 0xbd, 0xcc, 0x5c, 0xc4, 0x54, + 0x01, 0x33, 0x9a, 0x42, 0xfa, 0xd1, 0xf8, 0xe7, 0x03, 0x00, 0x12, 0x18, + 0x93, 0x42, 0x00, 0xd1, 0x70, 0x47, 0x19, 0x70, 0x01, 0x33, 0xf9, 0xe7, + 0x70, 0xb5, 0x05, 0x00, 0x00, 0x29, 0x10, 0xd0, 0x0c, 0x1f, 0x23, 0x68, + 0x00, 0x2b, 0x00, 0xda, 0xe4, 0x18, 0x28, 0x00, 0x01, 0xf0, 0xd3, 0xfc, + 0x1d, 0x4a, 0x13, 0x68, 0x00, 0x2b, 0x05, 0xd1, 0x63, 0x60, 0x14, 0x60, + 0x28, 0x00, 0x01, 0xf0, 0xcb, 0xfc, 0x70, 0xbd, 0xa3, 0x42, 0x09, 0xd9, + 0x21, 0x68, 0x60, 0x18, 0x83, 0x42, 0xf3, 0xd1, 0x18, 0x68, 0x5b, 0x68, + 0x41, 0x18, 0x21, 0x60, 0xee, 0xe7, 0x13, 0x00, 0x5a, 0x68, 0x00, 0x2a, + 0x01, 0xd0, 0xa2, 0x42, 0xf9, 0xd9, 0x19, 0x68, 0x58, 0x18, 0xa0, 0x42, + 0x0b, 0xd1, 0x20, 0x68, 0x09, 0x18, 0x58, 0x18, 0x19, 0x60, 0x82, 0x42, + 0xe0, 0xd1, 0x10, 0x68, 0x52, 0x68, 0x41, 0x18, 0x19, 0x60, 0x5a, 0x60, + 0xda, 0xe7, 0xa0, 0x42, 0x02, 0xd9, 0x0c, 0x23, 0x2b, 0x60, 0xd5, 0xe7, + 0x21, 0x68, 0x60, 0x18, 0x82, 0x42, 0x03, 0xd1, 0x10, 0x68, 0x52, 0x68, + 0x41, 0x18, 0x21, 0x60, 0x62, 0x60, 0x5c, 0x60, 0xca, 0xe7, 0xc0, 0x46, + 0x6c, 0x26, 0x00, 0x20, 0x03, 0x23, 0x70, 0xb5, 0xcd, 0x1c, 0x9d, 0x43, + 0x08, 0x35, 0x06, 0x00, 0x0c, 0x2d, 0x1e, 0xd2, 0x0c, 0x25, 0xa9, 0x42, + 0x1d, 0xd8, 0x30, 0x00, 0x01, 0xf0, 0x87, 0xfc, 0x25, 0x4a, 0x14, 0x68, + 0x21, 0x00, 0x00, 0x29, 0x19, 0xd1, 0x24, 0x4c, 0x23, 0x68, 0x00, 0x2b, + 0x03, 0xd1, 0x30, 0x00, 0x00, 0xf0, 0xac, 0xfc, 0x20, 0x60, 0x29, 0x00, + 0x30, 0x00, 0x00, 0xf0, 0xa7, 0xfc, 0x43, 0x1c, 0x2b, 0xd1, 0x0c, 0x23, + 0x30, 0x00, 0x33, 0x60, 0x01, 0xf0, 0x70, 0xfc, 0x03, 0xe0, 0x00, 0x2d, + 0xdf, 0xda, 0x0c, 0x23, 0x33, 0x60, 0x00, 0x20, 0x70, 0xbd, 0x0b, 0x68, + 0x5b, 0x1b, 0x19, 0xd4, 0x0b, 0x2b, 0x03, 0xd9, 0x0b, 0x60, 0xcc, 0x18, + 0x25, 0x60, 0x03, 0xe0, 0x4b, 0x68, 0x8c, 0x42, 0x0d, 0xd1, 0x13, 0x60, + 0x30, 0x00, 0x01, 0xf0, 0x59, 0xfc, 0x20, 0x00, 0x07, 0x22, 0x0b, 0x30, + 0x23, 0x1d, 0x90, 0x43, 0xc3, 0x1a, 0xe7, 0xd0, 0x5a, 0x42, 0xe2, 0x50, + 0xe4, 0xe7, 0x63, 0x60, 0x0c, 0x00, 0xef, 0xe7, 0x0c, 0x00, 0x49, 0x68, + 0xc3, 0xe7, 0x03, 0x23, 0xc4, 0x1c, 0x9c, 0x43, 0xa0, 0x42, 0xe1, 0xd0, + 0x21, 0x1a, 0x30, 0x00, 0x00, 0xf0, 0x70, 0xfc, 0x43, 0x1c, 0xdb, 0xd1, + 0xc7, 0xe7, 0xc0, 0x46, 0x6c, 0x26, 0x00, 0x20, 0x70, 0x26, 0x00, 0x20, + 0xf0, 0xb5, 0x8b, 0xb0, 0x14, 0x00, 0x1d, 0x1e, 0x12, 0x99, 0x53, 0xda, + 0x80, 0x24, 0x24, 0x06, 0x1b, 0x19, 0x1d, 0x00, 0x14, 0x00, 0x2d, 0x23, + 0x0b, 0x70, 0x20, 0x23, 0x14, 0x9e, 0x03, 0x22, 0x9e, 0x43, 0x46, 0x2e, + 0x07, 0xd0, 0x33, 0x00, 0x45, 0x3b, 0x59, 0x42, 0x4b, 0x41, 0x10, 0x99, + 0x01, 0x3a, 0xcb, 0x18, 0x10, 0x93, 0x09, 0xab, 0x04, 0x93, 0x08, 0xab, + 0x03, 0x93, 0x13, 0x9b, 0x00, 0x92, 0x02, 0x93, 0x10, 0x9b, 0x22, 0x00, + 0x01, 0x93, 0x2b, 0x00, 0x00, 0xf0, 0x18, 0xfe, 0x07, 0x00, 0x47, 0x2e, + 0x02, 0xd1, 0x11, 0x9b, 0xdb, 0x07, 0x24, 0xd5, 0x10, 0x9b, 0xfb, 0x18, + 0x07, 0x93, 0x46, 0x2e, 0x14, 0xd1, 0x3b, 0x78, 0x30, 0x2b, 0x0c, 0xd1, + 0x00, 0x22, 0x00, 0x23, 0x20, 0x00, 0x29, 0x00, 0xfe, 0xf7, 0xd0, 0xf8, + 0x00, 0x28, 0x04, 0xd1, 0x01, 0x23, 0x10, 0x9a, 0x9b, 0x1a, 0x13, 0x9a, + 0x13, 0x60, 0x13, 0x9b, 0x07, 0x9a, 0x1b, 0x68, 0xd3, 0x18, 0x07, 0x93, + 0x00, 0x22, 0x00, 0x23, 0x20, 0x00, 0x29, 0x00, 0xfe, 0xf7, 0xbe, 0xf8, + 0x30, 0x22, 0x00, 0x28, 0x0d, 0xd0, 0x07, 0x9b, 0x09, 0x93, 0x38, 0x00, + 0x09, 0x9b, 0x15, 0x9a, 0xdb, 0x1b, 0x13, 0x60, 0x0b, 0xb0, 0xf0, 0xbd, + 0x00, 0x23, 0xaf, 0xe7, 0x59, 0x1c, 0x09, 0x91, 0x1a, 0x70, 0x09, 0x9b, + 0x07, 0x99, 0x8b, 0x42, 0xf8, 0xd3, 0xee, 0xe7, 0xf0, 0xb5, 0x83, 0x1c, + 0x85, 0xb0, 0x01, 0x93, 0x06, 0x00, 0x0c, 0x00, 0x02, 0x70, 0x2b, 0x23, + 0x00, 0x29, 0x01, 0xda, 0x2d, 0x23, 0x4c, 0x42, 0x73, 0x70, 0x09, 0x2c, + 0x22, 0xdd, 0x02, 0xab, 0xdd, 0x1d, 0x20, 0x00, 0x0a, 0x21, 0xfe, 0xf7, + 0x7d, 0xf8, 0x6f, 0x1e, 0x30, 0x31, 0x39, 0x70, 0x20, 0x00, 0x0a, 0x21, + 0xfd, 0xf7, 0x90, 0xff, 0x04, 0x00, 0x09, 0x28, 0x0b, 0xdc, 0x02, 0x3d, + 0x30, 0x34, 0x01, 0x9b, 0x2c, 0x70, 0x02, 0xaa, 0x07, 0x32, 0x18, 0x00, + 0xaa, 0x42, 0x04, 0xd8, 0x80, 0x1b, 0x05, 0xb0, 0xf0, 0xbd, 0x3d, 0x00, + 0xe3, 0xe7, 0x2a, 0x78, 0x01, 0x35, 0x1a, 0x70, 0x01, 0x33, 0xf0, 0xe7, + 0x30, 0x23, 0xe4, 0x18, 0xb3, 0x70, 0x30, 0x1d, 0xf4, 0x70, 0xef, 0xe7, + 0xf0, 0xb5, 0x95, 0xb0, 0x0c, 0x00, 0x0a, 0x92, 0x0b, 0x93, 0x1a, 0x9d, + 0x09, 0x90, 0x01, 0xf0, 0x7b, 0xfb, 0x03, 0x68, 0x18, 0x00, 0x0c, 0x93, + 0x00, 0xf0, 0xf0, 0xfb, 0x00, 0x23, 0x12, 0x93, 0x23, 0x68, 0x0e, 0x90, + 0x0d, 0x93, 0x0d, 0x99, 0x27, 0x7e, 0x2b, 0x68, 0x07, 0x22, 0xc9, 0x05, + 0x45, 0xd5, 0x9b, 0x18, 0x93, 0x43, 0x1a, 0x00, 0x08, 0x32, 0x2a, 0x60, + 0x1a, 0x68, 0x5b, 0x68, 0xa2, 0x64, 0xe3, 0x64, 0x01, 0x22, 0xe5, 0x6c, + 0xa6, 0x6c, 0x6b, 0x00, 0x5b, 0x08, 0x0f, 0x93, 0x52, 0x42, 0xac, 0x4b, + 0x30, 0x00, 0x0f, 0x99, 0xff, 0xf7, 0x50, 0xfd, 0x00, 0x28, 0x30, 0xd1, + 0x01, 0x22, 0xa8, 0x4b, 0x52, 0x42, 0x30, 0x00, 0x0f, 0x99, 0xfe, 0xf7, + 0x49, 0xf8, 0x00, 0x28, 0x27, 0xd1, 0x00, 0x22, 0x00, 0x23, 0x30, 0x00, + 0x29, 0x00, 0xfe, 0xf7, 0x37, 0xf8, 0x00, 0x28, 0x03, 0xd0, 0x23, 0x00, + 0x2d, 0x22, 0x43, 0x33, 0x1a, 0x70, 0x9f, 0x4d, 0x47, 0x2f, 0x00, 0xd8, + 0x9e, 0x4d, 0x03, 0x23, 0x00, 0x26, 0x0d, 0x9a, 0x23, 0x61, 0x01, 0x33, + 0x9a, 0x43, 0x22, 0x60, 0x0b, 0x9b, 0x13, 0xaa, 0x00, 0x93, 0x21, 0x00, + 0x0a, 0x9b, 0x09, 0x98, 0x00, 0xf0, 0xf4, 0xf9, 0x43, 0x1c, 0x00, 0xd0, + 0x93, 0xe0, 0x01, 0x20, 0x40, 0x42, 0x15, 0xb0, 0xf0, 0xbd, 0x07, 0x33, + 0xb8, 0xe7, 0x32, 0x00, 0x2b, 0x00, 0x30, 0x00, 0x29, 0x00, 0xff, 0xf7, + 0x17, 0xfd, 0x00, 0x28, 0x04, 0xd0, 0x8f, 0x4d, 0x47, 0x2f, 0xdc, 0xd8, + 0x8e, 0x4d, 0xda, 0xe7, 0x80, 0x23, 0x0d, 0x99, 0x62, 0x68, 0xdb, 0x00, + 0x0b, 0x43, 0x51, 0x1c, 0x43, 0xd1, 0x07, 0x32, 0x62, 0x60, 0x12, 0xaa, + 0x00, 0x21, 0x05, 0x92, 0x11, 0xaa, 0x03, 0x92, 0x23, 0x22, 0x23, 0x60, + 0x06, 0x91, 0x01, 0x93, 0x08, 0xa9, 0x63, 0x68, 0x52, 0x18, 0x02, 0x92, + 0x00, 0x93, 0x32, 0x00, 0x2b, 0x00, 0x04, 0x97, 0x09, 0x98, 0xff, 0xf7, + 0xd9, 0xfe, 0x20, 0x23, 0x3a, 0x00, 0x05, 0x00, 0x9a, 0x43, 0x47, 0x2a, + 0x07, 0xd1, 0x11, 0x9b, 0xda, 0x1c, 0x02, 0xdb, 0x62, 0x68, 0x93, 0x42, + 0x45, 0xdd, 0x02, 0x3f, 0xff, 0xb2, 0x11, 0x99, 0x65, 0x2f, 0x25, 0xd8, + 0x20, 0x00, 0x01, 0x39, 0x3a, 0x00, 0x50, 0x30, 0x11, 0x91, 0xff, 0xf7, + 0x25, 0xff, 0x12, 0x9a, 0x06, 0x00, 0x13, 0x18, 0x23, 0x61, 0x01, 0x2a, + 0x02, 0xdc, 0x22, 0x68, 0xd2, 0x07, 0x01, 0xd5, 0x01, 0x33, 0x23, 0x61, + 0x23, 0x23, 0x08, 0xaa, 0x9b, 0x18, 0x1b, 0x78, 0x00, 0x2b, 0x9b, 0xd0, + 0x23, 0x00, 0x2d, 0x22, 0x43, 0x33, 0x1a, 0x70, 0x96, 0xe7, 0x67, 0x2f, + 0x00, 0xd1, 0x76, 0xe1, 0x47, 0x2f, 0xb8, 0xd1, 0x00, 0x2a, 0xb6, 0xd1, + 0x01, 0x22, 0xb3, 0xe7, 0x66, 0x2f, 0x19, 0xd1, 0x63, 0x68, 0x00, 0x29, + 0x0c, 0xdd, 0x21, 0x61, 0x00, 0x2b, 0x02, 0xd1, 0x22, 0x68, 0xd2, 0x07, + 0x02, 0xd5, 0x01, 0x33, 0x5b, 0x18, 0x23, 0x61, 0x11, 0x9b, 0x00, 0x26, + 0xa3, 0x65, 0xd9, 0xe7, 0x00, 0x2b, 0x03, 0xd1, 0x01, 0x22, 0x21, 0x68, + 0x11, 0x42, 0x00, 0xd0, 0x9a, 0x1c, 0x22, 0x61, 0xf2, 0xe7, 0x67, 0x27, + 0x11, 0x9b, 0x12, 0x9a, 0x93, 0x42, 0x05, 0xdb, 0x22, 0x68, 0x23, 0x61, + 0xd2, 0x07, 0xe9, 0xd5, 0x01, 0x33, 0xe6, 0xe7, 0x01, 0x21, 0x00, 0x2b, + 0x01, 0xdc, 0x49, 0x18, 0xc9, 0x1a, 0x52, 0x18, 0xeb, 0xe7, 0x22, 0x68, + 0x53, 0x05, 0x08, 0xd4, 0x23, 0x69, 0x2a, 0x00, 0x0a, 0x99, 0x09, 0x98, + 0x0b, 0x9d, 0xa8, 0x47, 0x43, 0x1c, 0x29, 0xd1, 0x5f, 0xe7, 0x65, 0x2f, + 0x00, 0xd8, 0xe0, 0xe0, 0xa0, 0x6c, 0xe1, 0x6c, 0x00, 0x22, 0x00, 0x23, + 0xfd, 0xf7, 0x6c, 0xff, 0x00, 0x28, 0x34, 0xd0, 0x01, 0x23, 0x42, 0x4a, + 0x0a, 0x99, 0x09, 0x98, 0x0b, 0x9d, 0xa8, 0x47, 0x43, 0x1c, 0x00, 0xd1, + 0x4b, 0xe7, 0x11, 0x9b, 0x12, 0x9a, 0x93, 0x42, 0x02, 0xdb, 0x23, 0x68, + 0xdb, 0x07, 0x0d, 0xd5, 0x0b, 0x9d, 0x0e, 0x9b, 0x0c, 0x9a, 0x0a, 0x99, + 0x09, 0x98, 0xa8, 0x47, 0x00, 0x25, 0x43, 0x1c, 0x00, 0xd1, 0x3a, 0xe7, + 0x12, 0x9b, 0x01, 0x3b, 0xab, 0x42, 0x0a, 0xdc, 0x23, 0x68, 0x9b, 0x07, + 0x00, 0xd5, 0x08, 0xe1, 0x13, 0x9b, 0xe0, 0x68, 0x98, 0x42, 0x00, 0xdb, + 0x2f, 0xe7, 0x18, 0x00, 0x2d, 0xe7, 0x22, 0x00, 0x01, 0x23, 0x1a, 0x32, + 0x0a, 0x99, 0x09, 0x98, 0x0b, 0x9e, 0xb0, 0x47, 0x43, 0x1c, 0x00, 0xd1, + 0x21, 0xe7, 0x01, 0x35, 0xe4, 0xe7, 0x11, 0x9b, 0x00, 0x2b, 0x2d, 0xdc, + 0x01, 0x23, 0x26, 0x4a, 0x0a, 0x99, 0x09, 0x98, 0x0b, 0x9e, 0xb0, 0x47, + 0x43, 0x1c, 0x00, 0xd1, 0x13, 0xe7, 0x11, 0x9b, 0x00, 0x2b, 0x05, 0xd1, + 0x12, 0x9b, 0x00, 0x2b, 0x02, 0xd1, 0x23, 0x68, 0xdb, 0x07, 0xd3, 0xd5, + 0x0b, 0x9e, 0x0e, 0x9b, 0x0c, 0x9a, 0x0a, 0x99, 0x09, 0x98, 0xb0, 0x47, + 0x00, 0x26, 0x43, 0x1c, 0x00, 0xd1, 0x00, 0xe7, 0x11, 0x9b, 0x5b, 0x42, + 0xb3, 0x42, 0x01, 0xdc, 0x12, 0x9b, 0x92, 0xe7, 0x22, 0x00, 0x01, 0x23, + 0x1a, 0x32, 0x0a, 0x99, 0x09, 0x98, 0x0b, 0x9f, 0xb8, 0x47, 0x43, 0x1c, + 0x00, 0xd1, 0xf0, 0xe6, 0x01, 0x36, 0xed, 0xe7, 0xa3, 0x6d, 0x12, 0x9f, + 0x9f, 0x42, 0x00, 0xdd, 0x1f, 0x00, 0x00, 0x2f, 0x08, 0xdd, 0x3b, 0x00, + 0x2a, 0x00, 0x0a, 0x99, 0x09, 0x98, 0x0b, 0x9e, 0xb0, 0x47, 0x43, 0x1c, + 0x00, 0xd1, 0xde, 0xe6, 0x00, 0x23, 0x0d, 0x93, 0xfb, 0x43, 0xdb, 0x17, + 0x0f, 0x93, 0x18, 0xe0, 0xff, 0xff, 0xef, 0x7f, 0x46, 0x98, 0x00, 0x00, + 0x42, 0x98, 0x00, 0x00, 0x4e, 0x98, 0x00, 0x00, 0x4a, 0x98, 0x00, 0x00, + 0x3d, 0x93, 0x00, 0x00, 0x22, 0x00, 0x01, 0x23, 0x1a, 0x32, 0x0a, 0x99, + 0x09, 0x98, 0x0b, 0x9e, 0xb0, 0x47, 0x43, 0x1c, 0x00, 0xd1, 0xc2, 0xe6, + 0x0d, 0x9b, 0x01, 0x33, 0x0d, 0x93, 0x0f, 0x9b, 0xa6, 0x6d, 0x0d, 0x9a, + 0x3b, 0x40, 0xf3, 0x1a, 0x93, 0x42, 0xeb, 0xdc, 0x11, 0x9b, 0x12, 0x9a, + 0xad, 0x19, 0x93, 0x42, 0x10, 0xdb, 0x23, 0x68, 0xdb, 0x07, 0x0d, 0xd4, + 0x12, 0x9f, 0x11, 0x9b, 0xbe, 0x1b, 0xff, 0x1a, 0xb7, 0x42, 0x00, 0xdd, + 0x37, 0x00, 0x00, 0x2f, 0x0d, 0xdc, 0xfe, 0x43, 0xf3, 0x17, 0x00, 0x25, + 0x0c, 0x93, 0x1c, 0xe0, 0x0e, 0x9b, 0x0c, 0x9a, 0x0a, 0x99, 0x09, 0x98, + 0x0b, 0x9f, 0xb8, 0x47, 0x43, 0x1c, 0xe9, 0xd1, 0x99, 0xe6, 0x3b, 0x00, + 0x2a, 0x00, 0x0a, 0x99, 0x09, 0x98, 0x0b, 0x9d, 0xa8, 0x47, 0x43, 0x1c, + 0xe9, 0xd1, 0x90, 0xe6, 0x22, 0x00, 0x01, 0x23, 0x1a, 0x32, 0x0a, 0x99, + 0x09, 0x98, 0x0b, 0x9e, 0xb0, 0x47, 0x43, 0x1c, 0x00, 0xd1, 0x86, 0xe6, + 0x01, 0x35, 0x11, 0x9a, 0x12, 0x9b, 0x0c, 0x99, 0x9b, 0x1a, 0x3a, 0x00, + 0x0a, 0x40, 0x9b, 0x1a, 0xab, 0x42, 0xeb, 0xdc, 0x44, 0xe7, 0x12, 0x9b, + 0x01, 0x2b, 0x02, 0xdc, 0x01, 0x23, 0x1a, 0x42, 0x32, 0xd0, 0x01, 0x23, + 0x2a, 0x00, 0x0a, 0x99, 0x09, 0x98, 0x0b, 0x9f, 0xb8, 0x47, 0x43, 0x1c, + 0x00, 0xd1, 0x6c, 0xe6, 0x0e, 0x9b, 0x0c, 0x9a, 0x0a, 0x99, 0x09, 0x98, + 0x0b, 0x9f, 0x01, 0x35, 0xb8, 0x47, 0x43, 0x1c, 0x00, 0xd1, 0x62, 0xe6, + 0xa0, 0x6c, 0xe1, 0x6c, 0x12, 0x9b, 0x00, 0x22, 0x5f, 0x1e, 0x00, 0x23, + 0xfd, 0xf7, 0x70, 0xfe, 0x3b, 0x00, 0x00, 0x28, 0x14, 0xd0, 0x00, 0x25, + 0x0a, 0xe0, 0x22, 0x00, 0x01, 0x23, 0x1a, 0x32, 0x0a, 0x99, 0x09, 0x98, + 0x0b, 0x9f, 0xb8, 0x47, 0x43, 0x1c, 0x00, 0xd1, 0x4b, 0xe6, 0x01, 0x35, + 0x12, 0x9b, 0x01, 0x3b, 0xab, 0x42, 0xf0, 0xdc, 0x22, 0x00, 0x33, 0x00, + 0x50, 0x32, 0xdb, 0xe6, 0x2a, 0x00, 0x0a, 0x99, 0x09, 0x98, 0x0b, 0x9d, + 0xa8, 0x47, 0x43, 0x1c, 0xf4, 0xd1, 0x3a, 0xe6, 0x22, 0x00, 0x01, 0x23, + 0x19, 0x32, 0x0a, 0x99, 0x09, 0x98, 0x0b, 0x9e, 0xb0, 0x47, 0x43, 0x1c, + 0x00, 0xd1, 0x30, 0xe6, 0x01, 0x35, 0xe3, 0x68, 0x13, 0x9a, 0x9b, 0x1a, + 0xab, 0x42, 0xef, 0xdc, 0xf6, 0xe6, 0x00, 0x25, 0xf7, 0xe7, 0x00, 0x2a, + 0x00, 0xd1, 0x89, 0xe6, 0x00, 0x21, 0x06, 0x91, 0x12, 0xa9, 0x05, 0x91, + 0x11, 0xa9, 0x03, 0x91, 0x23, 0x21, 0x08, 0xa8, 0x09, 0x18, 0x23, 0x60, + 0x01, 0x93, 0x00, 0x92, 0x2b, 0x00, 0x04, 0x97, 0x02, 0x91, 0x32, 0x00, + 0x09, 0x98, 0xff, 0xf7, 0x1b, 0xfd, 0x05, 0x00, 0x45, 0xe6, 0xc0, 0x46, + 0xf7, 0xb5, 0x15, 0x00, 0x01, 0x93, 0x8a, 0x68, 0x0b, 0x69, 0x00, 0x90, + 0x0c, 0x00, 0x93, 0x42, 0x00, 0xda, 0x13, 0x00, 0x22, 0x00, 0x2b, 0x60, + 0x43, 0x32, 0x12, 0x78, 0x00, 0x2a, 0x01, 0xd0, 0x01, 0x33, 0x2b, 0x60, + 0x23, 0x68, 0x9b, 0x06, 0x02, 0xd5, 0x2b, 0x68, 0x02, 0x33, 0x2b, 0x60, + 0x06, 0x27, 0x23, 0x68, 0x1f, 0x40, 0x27, 0xd0, 0x23, 0x00, 0x43, 0x33, + 0x1b, 0x78, 0x5a, 0x1e, 0x93, 0x41, 0x22, 0x68, 0x92, 0x06, 0x30, 0xd4, + 0x22, 0x00, 0x01, 0x99, 0x43, 0x32, 0x00, 0x98, 0x08, 0x9e, 0xb0, 0x47, + 0x43, 0x1c, 0x25, 0xd0, 0x06, 0x23, 0x20, 0x68, 0x2a, 0x68, 0xe1, 0x68, + 0x03, 0x40, 0x00, 0x25, 0x04, 0x2b, 0x03, 0xd1, 0x8d, 0x1a, 0xeb, 0x43, + 0xdb, 0x17, 0x1d, 0x40, 0xa3, 0x68, 0x22, 0x69, 0x93, 0x42, 0x01, 0xdd, + 0x9b, 0x1a, 0xed, 0x18, 0x00, 0x27, 0xbd, 0x42, 0x20, 0xd1, 0x00, 0x20, + 0x10, 0xe0, 0x01, 0x37, 0xe3, 0x68, 0x2a, 0x68, 0x9b, 0x1a, 0xbb, 0x42, + 0xd2, 0xdd, 0x22, 0x00, 0x01, 0x23, 0x19, 0x32, 0x01, 0x99, 0x00, 0x98, + 0x08, 0x9e, 0xb0, 0x47, 0x43, 0x1c, 0xf0, 0xd1, 0x01, 0x20, 0x40, 0x42, + 0xfe, 0xbd, 0x30, 0x20, 0xe1, 0x18, 0x43, 0x31, 0x08, 0x70, 0x21, 0x00, + 0x5a, 0x1c, 0x45, 0x31, 0x09, 0x78, 0xa2, 0x18, 0x43, 0x32, 0x02, 0x33, + 0x11, 0x70, 0xc1, 0xe7, 0x22, 0x00, 0x01, 0x23, 0x1a, 0x32, 0x01, 0x99, + 0x00, 0x98, 0x08, 0x9e, 0xb0, 0x47, 0x43, 0x1c, 0xe6, 0xd0, 0x01, 0x37, + 0xd1, 0xe7, 0x00, 0x00, 0xf0, 0xb5, 0x89, 0xb0, 0x04, 0x92, 0x0a, 0x00, + 0x43, 0x32, 0x05, 0x93, 0x03, 0x90, 0x02, 0x92, 0x0a, 0x7e, 0x0c, 0x00, + 0x0e, 0x9b, 0x6e, 0x2a, 0x00, 0xd1, 0x86, 0xe0, 0x1f, 0xd8, 0x63, 0x2a, + 0x33, 0xd0, 0x08, 0xd8, 0x00, 0x2a, 0x00, 0xd1, 0x8c, 0xe0, 0x58, 0x2a, + 0x4d, 0xd0, 0x25, 0x00, 0x42, 0x35, 0x2a, 0x70, 0x30, 0xe0, 0x64, 0x2a, + 0x01, 0xd0, 0x69, 0x2a, 0xf7, 0xd1, 0x19, 0x68, 0x25, 0x68, 0x0a, 0x1d, + 0x28, 0x06, 0x29, 0xd5, 0x08, 0x68, 0x1a, 0x60, 0x00, 0x28, 0x03, 0xda, + 0x2d, 0x23, 0x02, 0x9a, 0x40, 0x42, 0x13, 0x70, 0x6b, 0x4e, 0x0a, 0x27, + 0x4f, 0xe0, 0x73, 0x2a, 0x74, 0xd0, 0x08, 0xd8, 0x6f, 0x2a, 0x1f, 0xd0, + 0x70, 0x2a, 0xe0, 0xd1, 0x20, 0x22, 0x09, 0x68, 0x0a, 0x43, 0x22, 0x60, + 0x03, 0xe0, 0x75, 0x2a, 0x16, 0xd0, 0x78, 0x2a, 0xd7, 0xd1, 0x22, 0x00, + 0x78, 0x21, 0x45, 0x32, 0x11, 0x70, 0x61, 0x4e, 0x22, 0xe0, 0x25, 0x00, + 0x1a, 0x68, 0x42, 0x35, 0x11, 0x1d, 0x19, 0x60, 0x13, 0x68, 0x2b, 0x70, + 0x01, 0x23, 0x65, 0xe0, 0x08, 0x68, 0x1a, 0x60, 0x69, 0x06, 0xd3, 0xd5, + 0x00, 0xb2, 0xd1, 0xe7, 0x19, 0x68, 0x25, 0x68, 0x08, 0x1d, 0x18, 0x60, + 0x08, 0x68, 0x2e, 0x06, 0x05, 0xd5, 0x54, 0x4e, 0x08, 0x27, 0x6f, 0x2a, + 0x1b, 0xd0, 0x0a, 0x27, 0x19, 0xe0, 0x6d, 0x06, 0xf7, 0xd5, 0x80, 0xb2, + 0xf5, 0xe7, 0x45, 0x31, 0x4e, 0x4e, 0x0a, 0x70, 0x18, 0x68, 0x22, 0x68, + 0x01, 0x1d, 0x00, 0x68, 0x19, 0x60, 0x15, 0x06, 0x21, 0xd5, 0xd3, 0x07, + 0x02, 0xd5, 0x20, 0x23, 0x1a, 0x43, 0x22, 0x60, 0x10, 0x27, 0x00, 0x28, + 0x03, 0xd1, 0x20, 0x23, 0x22, 0x68, 0x9a, 0x43, 0x22, 0x60, 0x23, 0x00, + 0x00, 0x22, 0x43, 0x33, 0x1a, 0x70, 0x63, 0x68, 0xa3, 0x60, 0x00, 0x2b, + 0x58, 0xdb, 0x04, 0x22, 0x21, 0x68, 0x91, 0x43, 0x21, 0x60, 0x00, 0x28, + 0x54, 0xd1, 0x02, 0x9d, 0x00, 0x2b, 0x5a, 0xd0, 0x25, 0x00, 0x33, 0x78, + 0x42, 0x35, 0x2b, 0x70, 0x55, 0xe0, 0x55, 0x06, 0xdb, 0xd5, 0x80, 0xb2, + 0xd9, 0xe7, 0x1a, 0x68, 0x0d, 0x68, 0x10, 0x1d, 0x49, 0x69, 0x18, 0x60, + 0x13, 0x68, 0x2e, 0x06, 0x01, 0xd5, 0x19, 0x60, 0x02, 0xe0, 0x6d, 0x06, + 0xfb, 0xd5, 0x19, 0x80, 0x00, 0x23, 0x02, 0x9d, 0x23, 0x61, 0x4f, 0xe0, + 0x1a, 0x68, 0x11, 0x1d, 0x19, 0x60, 0x15, 0x68, 0x00, 0x21, 0x62, 0x68, + 0x28, 0x00, 0x01, 0xf0, 0x27, 0xf8, 0x00, 0x28, 0x01, 0xd0, 0x40, 0x1b, + 0x60, 0x60, 0x63, 0x68, 0x23, 0x61, 0x00, 0x23, 0x02, 0x9a, 0x13, 0x70, + 0x3c, 0xe0, 0x23, 0x69, 0x2a, 0x00, 0x04, 0x99, 0x03, 0x98, 0x05, 0x9d, + 0xa8, 0x47, 0x43, 0x1c, 0x3e, 0xd0, 0x23, 0x68, 0x9b, 0x07, 0x15, 0xd4, + 0x07, 0x9b, 0xe0, 0x68, 0x98, 0x42, 0x39, 0xda, 0x18, 0x00, 0x37, 0xe0, + 0x22, 0x00, 0x01, 0x23, 0x19, 0x32, 0x04, 0x99, 0x03, 0x98, 0x05, 0x9e, + 0xb0, 0x47, 0x43, 0x1c, 0x2c, 0xd0, 0x01, 0x35, 0xe3, 0x68, 0x07, 0x9a, + 0x9b, 0x1a, 0xab, 0x42, 0xf0, 0xdc, 0xe9, 0xe7, 0x00, 0x25, 0xf7, 0xe7, + 0x00, 0x28, 0xad, 0xd0, 0x02, 0x9d, 0x39, 0x00, 0xfd, 0xf7, 0xd4, 0xfb, + 0x73, 0x5c, 0x01, 0x3d, 0x2b, 0x70, 0x00, 0x28, 0xf7, 0xd1, 0x08, 0x2f, + 0x09, 0xd1, 0x23, 0x68, 0xdb, 0x07, 0x06, 0xd5, 0x63, 0x68, 0x22, 0x69, + 0x93, 0x42, 0x02, 0xdc, 0x30, 0x23, 0x01, 0x3d, 0x2b, 0x70, 0x02, 0x9b, + 0x5b, 0x1b, 0x23, 0x61, 0x05, 0x9b, 0x07, 0xaa, 0x00, 0x93, 0x21, 0x00, + 0x04, 0x9b, 0x03, 0x98, 0xff, 0xf7, 0x94, 0xfe, 0x43, 0x1c, 0xb8, 0xd1, + 0x01, 0x20, 0x40, 0x42, 0x09, 0xb0, 0xf0, 0xbd, 0x52, 0x98, 0x00, 0x00, + 0x63, 0x98, 0x00, 0x00, 0x10, 0xb5, 0x03, 0x4b, 0x0a, 0x00, 0x01, 0x00, + 0x18, 0x68, 0x01, 0xf0, 0xc9, 0xfa, 0x10, 0xbd, 0x28, 0x00, 0x00, 0x20, + 0x00, 0x23, 0x70, 0xb5, 0x06, 0x4c, 0x05, 0x00, 0x08, 0x00, 0x23, 0x60, + 0x01, 0xf0, 0x86, 0xfc, 0x43, 0x1c, 0x03, 0xd1, 0x23, 0x68, 0x00, 0x2b, + 0x00, 0xd0, 0x2b, 0x60, 0x70, 0xbd, 0xc0, 0x46, 0x78, 0x26, 0x00, 0x20, + 0xc9, 0xb2, 0x03, 0x78, 0x00, 0x2b, 0x04, 0xd0, 0x8b, 0x42, 0x00, 0xd1, + 0x70, 0x47, 0x01, 0x30, 0xf7, 0xe7, 0x4b, 0x42, 0x59, 0x41, 0x49, 0x42, + 0x08, 0x40, 0xf7, 0xe7, 0x02, 0x78, 0x0b, 0x78, 0x00, 0x2a, 0x03, 0xd0, + 0x01, 0x30, 0x01, 0x31, 0x9a, 0x42, 0xf7, 0xd0, 0xd0, 0x1a, 0x70, 0x47, + 0x03, 0x00, 0x0a, 0x78, 0x01, 0x31, 0x1a, 0x70, 0x01, 0x33, 0x00, 0x2a, + 0xf9, 0xd1, 0x70, 0x47, 0x00, 0x23, 0xc2, 0x5c, 0x01, 0x33, 0x00, 0x2a, + 0xfb, 0xd1, 0x58, 0x1e, 0x70, 0x47, 0x00, 0x23, 0x30, 0xb5, 0x9a, 0x42, + 0x0a, 0xd0, 0x01, 0x3a, 0xc4, 0x5c, 0xcd, 0x5c, 0xac, 0x42, 0x04, 0xd1, + 0x93, 0x42, 0x02, 0xd0, 0x01, 0x33, 0x00, 0x2c, 0xf6, 0xd1, 0x63, 0x1b, + 0x18, 0x00, 0x30, 0xbd, 0x30, 0xb5, 0x05, 0x00, 0x00, 0x2a, 0x00, 0xd1, + 0x30, 0xbd, 0x0c, 0x78, 0x01, 0x3a, 0x6b, 0x1c, 0x2c, 0x70, 0x01, 0x31, + 0x00, 0x2c, 0x05, 0xd1, 0x9a, 0x18, 0x9a, 0x42, 0xf4, 0xd0, 0x1c, 0x70, + 0x01, 0x33, 0xfa, 0xe7, 0x1d, 0x00, 0xed, 0xe7, 0x10, 0xb5, 0x03, 0x78, + 0x00, 0x2b, 0x0f, 0xd1, 0x0b, 0x78, 0x5a, 0x42, 0x53, 0x41, 0x5b, 0x42, + 0x18, 0x40, 0x10, 0xbd, 0x00, 0x23, 0xca, 0x5c, 0x00, 0x2a, 0xfa, 0xd0, + 0xc4, 0x5c, 0x94, 0x42, 0x01, 0xd1, 0x01, 0x33, 0xf7, 0xe7, 0x01, 0x30, + 0x03, 0x78, 0x00, 0x2b, 0xf2, 0xd1, 0x18, 0x00, 0xef, 0xe7, 0x00, 0x00, + 0xf0, 0xb5, 0x1f, 0x00, 0x0e, 0x00, 0x87, 0xb0, 0x05, 0x90, 0x01, 0x91, + 0x02, 0x92, 0x0c, 0x98, 0x34, 0x78, 0xff, 0xf7, 0x12, 0xfa, 0x08, 0x22, + 0x00, 0x19, 0x43, 0x78, 0x75, 0x1c, 0x13, 0x40, 0x36, 0xd1, 0x2d, 0x2c, + 0x36, 0xd1, 0xb5, 0x1c, 0x74, 0x78, 0x01, 0x26, 0x00, 0x2f, 0x62, 0xd0, + 0x10, 0x2f, 0x09, 0xd1, 0x30, 0x2c, 0x07, 0xd1, 0x20, 0x22, 0x2b, 0x78, + 0x93, 0x43, 0x58, 0x2b, 0x54, 0xd1, 0x10, 0x27, 0x6c, 0x78, 0x02, 0x35, + 0x2d, 0x4b, 0x39, 0x00, 0xf3, 0x18, 0x18, 0x00, 0x03, 0x93, 0xfd, 0xf7, + 0x01, 0xfb, 0x04, 0x91, 0x01, 0x21, 0x00, 0x23, 0x49, 0x42, 0x02, 0x00, + 0x8c, 0x46, 0x18, 0x00, 0x21, 0x00, 0x30, 0x39, 0x09, 0x29, 0x1a, 0xd8, + 0x0c, 0x00, 0xa7, 0x42, 0x23, 0xdd, 0x59, 0x1c, 0x09, 0xd0, 0x63, 0x46, + 0x82, 0x42, 0x06, 0xd3, 0x02, 0xd1, 0x04, 0x99, 0xa1, 0x42, 0x02, 0xdb, + 0x01, 0x23, 0x78, 0x43, 0x20, 0x18, 0x2c, 0x78, 0x01, 0x35, 0xe9, 0xe7, + 0x2e, 0x00, 0xbc, 0xe7, 0x2b, 0x2c, 0x01, 0xd0, 0x1e, 0x00, 0xc7, 0xe7, + 0xb5, 0x1c, 0x74, 0x78, 0xfa, 0xe7, 0x21, 0x00, 0x41, 0x39, 0x19, 0x29, + 0x01, 0xd8, 0x37, 0x3c, 0xdf, 0xe7, 0x21, 0x00, 0x61, 0x39, 0x19, 0x29, + 0x01, 0xd8, 0x57, 0x3c, 0xd9, 0xe7, 0x5a, 0x1c, 0x08, 0xd1, 0x05, 0x9a, + 0x23, 0x33, 0x13, 0x60, 0x02, 0x9b, 0x03, 0x98, 0x00, 0x2b, 0x09, 0xd1, + 0x07, 0xb0, 0xf0, 0xbd, 0x00, 0x2e, 0x00, 0xd0, 0x40, 0x42, 0x02, 0x9a, + 0x00, 0x2a, 0xf7, 0xd0, 0x00, 0x2b, 0x01, 0xd0, 0x6b, 0x1e, 0x01, 0x93, + 0x02, 0x9b, 0x01, 0x9a, 0x1a, 0x60, 0xef, 0xe7, 0x30, 0x24, 0x00, 0x2f, + 0xaa, 0xd1, 0x08, 0x27, 0xa8, 0xe7, 0x30, 0x2c, 0x9e, 0xd0, 0x0a, 0x27, + 0xa4, 0xe7, 0xc0, 0x46, 0xff, 0xff, 0xff, 0x7f, 0x37, 0xb5, 0x13, 0x00, + 0x06, 0x4a, 0x05, 0x00, 0x10, 0x68, 0x04, 0x6a, 0x00, 0x2c, 0x00, 0xd1, + 0x04, 0x4c, 0x0a, 0x00, 0x00, 0x94, 0x29, 0x00, 0xff, 0xf7, 0x70, 0xff, + 0x3e, 0xbd, 0xc0, 0x46, 0x28, 0x00, 0x00, 0x20, 0x8c, 0x00, 0x00, 0x20, + 0x30, 0xb5, 0x14, 0x00, 0x9b, 0xb0, 0x05, 0x00, 0x1a, 0x00, 0x00, 0x2c, + 0x05, 0xda, 0x8b, 0x23, 0x03, 0x60, 0x01, 0x20, 0x40, 0x42, 0x1b, 0xb0, + 0x30, 0xbd, 0x82, 0x23, 0x68, 0x46, 0x9b, 0x00, 0x83, 0x81, 0x00, 0x23, + 0x00, 0x91, 0x04, 0x91, 0x9c, 0x42, 0x00, 0xd0, 0x63, 0x1e, 0x02, 0x93, + 0x05, 0x93, 0x01, 0x23, 0x69, 0x46, 0x5b, 0x42, 0xcb, 0x81, 0x28, 0x00, + 0x1e, 0x9b, 0x01, 0xf0, 0x1f, 0xfa, 0x43, 0x1c, 0x01, 0xda, 0x8b, 0x23, + 0x2b, 0x60, 0x00, 0x2c, 0xe3, 0xd0, 0x00, 0x23, 0x00, 0x9a, 0x13, 0x70, + 0xdf, 0xe7, 0x00, 0x00, 0x07, 0xb5, 0x00, 0x93, 0x13, 0x00, 0x0a, 0x00, + 0x01, 0x00, 0x02, 0x48, 0x00, 0x68, 0xff, 0xf7, 0xcb, 0xff, 0x0e, 0xbd, + 0x28, 0x00, 0x00, 0x20, 0x0b, 0x1e, 0x04, 0xd0, 0xff, 0x2a, 0x04, 0xd9, + 0x8a, 0x23, 0x03, 0x60, 0x8b, 0x3b, 0x18, 0x00, 0x70, 0x47, 0x0a, 0x70, + 0x01, 0x23, 0xfa, 0xe7, 0xf0, 0xb5, 0x03, 0x69, 0x0c, 0x69, 0x89, 0xb0, + 0x07, 0x00, 0x05, 0x91, 0x00, 0x26, 0xa3, 0x42, 0x65, 0xdb, 0x0b, 0x00, + 0x01, 0x3c, 0x14, 0x33, 0xa5, 0x00, 0x03, 0x93, 0x5b, 0x19, 0x04, 0x93, + 0x03, 0x00, 0x14, 0x33, 0x02, 0x93, 0x5d, 0x19, 0x04, 0x9b, 0x28, 0x68, + 0x1b, 0x68, 0x59, 0x1c, 0x01, 0x93, 0xfd, 0xf7, 0xb1, 0xf9, 0x01, 0x90, + 0xb0, 0x42, 0x29, 0xd0, 0x03, 0x9b, 0x02, 0x98, 0x9c, 0x46, 0x06, 0x96, + 0x62, 0x46, 0x08, 0xca, 0x94, 0x46, 0x01, 0x9a, 0x99, 0xb2, 0x51, 0x43, + 0x1b, 0x0c, 0x53, 0x43, 0x89, 0x19, 0x0a, 0x0c, 0x9b, 0x18, 0x07, 0x93, + 0x1e, 0x0c, 0x03, 0x68, 0x89, 0xb2, 0x9a, 0xb2, 0x06, 0x9b, 0xd2, 0x18, + 0x03, 0x68, 0x52, 0x1a, 0x19, 0x0c, 0x6b, 0x46, 0x9b, 0x8b, 0xcb, 0x1a, + 0x11, 0x14, 0x5b, 0x18, 0x19, 0x14, 0x92, 0xb2, 0x1b, 0x04, 0x1a, 0x43, + 0x04, 0x9b, 0x06, 0x91, 0x04, 0xc0, 0x63, 0x45, 0xdc, 0xd2, 0x2b, 0x68, + 0x00, 0x2b, 0x2d, 0xd0, 0x05, 0x99, 0x38, 0x00, 0x01, 0xf0, 0x48, 0xf8, + 0x00, 0x28, 0x1f, 0xdb, 0x00, 0x25, 0x01, 0x9b, 0x02, 0x98, 0x01, 0x33, + 0x03, 0x99, 0x01, 0x93, 0x02, 0x68, 0x08, 0xc9, 0x92, 0xb2, 0x55, 0x19, + 0x9a, 0xb2, 0xaa, 0x1a, 0x05, 0x68, 0x1b, 0x0c, 0x2d, 0x0c, 0xeb, 0x1a, + 0x15, 0x14, 0x5b, 0x19, 0x1d, 0x14, 0x92, 0xb2, 0x1b, 0x04, 0x13, 0x43, + 0x08, 0xc0, 0x04, 0x9b, 0x8b, 0x42, 0xeb, 0xd2, 0x02, 0x9a, 0xa3, 0x00, + 0xd3, 0x18, 0x1a, 0x68, 0x00, 0x2a, 0x11, 0xd0, 0x01, 0x9e, 0x30, 0x00, + 0x09, 0xb0, 0xf0, 0xbd, 0x2b, 0x68, 0x00, 0x2b, 0x04, 0xd1, 0x01, 0x3c, + 0x02, 0x9b, 0x04, 0x3d, 0xab, 0x42, 0xf7, 0xd3, 0x3c, 0x61, 0xcb, 0xe7, + 0x1a, 0x68, 0x00, 0x2a, 0x04, 0xd1, 0x01, 0x3c, 0x02, 0x9a, 0x04, 0x3b, + 0x9a, 0x42, 0xf7, 0xd3, 0x3c, 0x61, 0xe7, 0xe7, 0xf0, 0xb5, 0x16, 0x00, + 0x1f, 0x00, 0x44, 0x6a, 0x9b, 0xb0, 0x02, 0x90, 0x23, 0x9d, 0x06, 0x96, + 0x07, 0x97, 0x00, 0x2c, 0x08, 0xd1, 0x10, 0x20, 0xff, 0xf7, 0xc0, 0xf8, + 0x02, 0x9b, 0x58, 0x62, 0x44, 0x60, 0x84, 0x60, 0x04, 0x60, 0xc4, 0x60, + 0x02, 0x9b, 0x5b, 0x6a, 0x19, 0x68, 0x00, 0x29, 0x0b, 0xd0, 0x5a, 0x68, + 0x01, 0x23, 0x93, 0x40, 0x4a, 0x60, 0x8b, 0x60, 0x02, 0x98, 0x00, 0xf0, + 0x10, 0xfe, 0x00, 0x22, 0x02, 0x9b, 0x5b, 0x6a, 0x1a, 0x60, 0x00, 0x2f, + 0x20, 0xda, 0x01, 0x23, 0x2b, 0x60, 0x7b, 0x00, 0x5b, 0x08, 0x07, 0x93, + 0x07, 0x9c, 0xb2, 0x4b, 0x22, 0x00, 0x17, 0x93, 0x1a, 0x40, 0x9a, 0x42, + 0x17, 0xd1, 0xb0, 0x4b, 0x22, 0x9a, 0x13, 0x60, 0x06, 0x9b, 0x00, 0x2b, + 0x03, 0xd1, 0x24, 0x03, 0x01, 0xd1, 0x00, 0xf0, 0x87, 0xfd, 0xac, 0x4b, + 0x24, 0x9a, 0x08, 0x93, 0x00, 0x2a, 0x02, 0xd0, 0xaa, 0x4b, 0x24, 0x9a, + 0x13, 0x60, 0x08, 0x98, 0x1b, 0xb0, 0xf0, 0xbd, 0x00, 0x23, 0x2b, 0x60, + 0xe0, 0xe7, 0x06, 0x9e, 0x07, 0x9f, 0x00, 0x22, 0x00, 0x23, 0x30, 0x00, + 0x39, 0x00, 0xfd, 0xf7, 0x79, 0xfa, 0x05, 0x1e, 0x0b, 0xd0, 0x01, 0x23, + 0x22, 0x9a, 0x13, 0x60, 0xa0, 0x4b, 0x24, 0x9a, 0x08, 0x93, 0x00, 0x2a, + 0xe7, 0xd0, 0x9f, 0x4a, 0x24, 0x99, 0x0a, 0x60, 0xe3, 0xe7, 0x18, 0xab, + 0x01, 0x93, 0x19, 0xab, 0x00, 0x93, 0x32, 0x00, 0x3b, 0x00, 0x02, 0x98, + 0x01, 0xf0, 0x22, 0xf8, 0x63, 0x00, 0x03, 0x90, 0x5b, 0x0d, 0x74, 0xd0, + 0x3a, 0x03, 0x97, 0x4c, 0x12, 0x0b, 0x14, 0x43, 0x21, 0x00, 0x96, 0x4a, + 0x30, 0x00, 0x16, 0x95, 0x9e, 0x18, 0x00, 0x22, 0x94, 0x4b, 0xfe, 0xf7, + 0x17, 0xfc, 0x94, 0x4a, 0x94, 0x4b, 0xfe, 0xf7, 0xa1, 0xf9, 0x94, 0x4a, + 0x94, 0x4b, 0xfd, 0xf7, 0x77, 0xfa, 0x04, 0x00, 0x30, 0x00, 0x0d, 0x00, + 0x01, 0xf0, 0xf4, 0xf9, 0x91, 0x4a, 0x92, 0x4b, 0xfe, 0xf7, 0x94, 0xf9, + 0x02, 0x00, 0x0b, 0x00, 0x20, 0x00, 0x29, 0x00, 0xfd, 0xf7, 0x68, 0xfa, + 0x04, 0x00, 0x0d, 0x00, 0xfe, 0xf7, 0x60, 0xff, 0x00, 0x22, 0x07, 0x00, + 0x00, 0x23, 0x20, 0x00, 0x29, 0x00, 0xfd, 0xf7, 0x35, 0xfa, 0x00, 0x28, + 0x09, 0xd0, 0x38, 0x00, 0x01, 0xf0, 0xda, 0xf9, 0x2b, 0x00, 0x22, 0x00, + 0xfd, 0xf7, 0x26, 0xfa, 0x43, 0x42, 0x58, 0x41, 0x3f, 0x1a, 0x01, 0x23, + 0x14, 0x93, 0x16, 0x2f, 0x0d, 0xd8, 0x81, 0x49, 0xfb, 0x00, 0xc9, 0x18, + 0x08, 0x68, 0x49, 0x68, 0x06, 0x9a, 0x07, 0x9b, 0xfd, 0xf7, 0x30, 0xfa, + 0x00, 0x28, 0x46, 0xd0, 0x00, 0x23, 0x01, 0x3f, 0x14, 0x93, 0x18, 0x9b, + 0x9e, 0x1b, 0x00, 0x23, 0x0a, 0x93, 0x33, 0x00, 0x01, 0x3b, 0x0b, 0x93, + 0x04, 0xd5, 0x01, 0x23, 0x9b, 0x1b, 0x0a, 0x93, 0x00, 0x23, 0x0b, 0x93, + 0x00, 0x2f, 0x36, 0xdb, 0x0b, 0x9b, 0x11, 0x97, 0xdb, 0x19, 0x0b, 0x93, + 0x00, 0x23, 0x04, 0x93, 0x20, 0x9b, 0x01, 0x24, 0x09, 0x2b, 0x00, 0xd9, + 0x84, 0xe0, 0x05, 0x2b, 0x02, 0xdd, 0x00, 0x24, 0x04, 0x3b, 0x20, 0x93, + 0x20, 0x9b, 0x98, 0x1e, 0x03, 0x28, 0x00, 0xd9, 0x84, 0xe0, 0xfd, 0xf7, + 0x5b, 0xf8, 0x75, 0x77, 0x28, 0x6a, 0x18, 0x9b, 0x19, 0x9a, 0x9e, 0x18, + 0x65, 0x4b, 0xf2, 0x18, 0x20, 0x2a, 0x0f, 0xdd, 0x40, 0x23, 0x9b, 0x1a, + 0x9c, 0x40, 0x63, 0x4b, 0x06, 0x98, 0xf3, 0x18, 0xd8, 0x40, 0x20, 0x43, + 0xfe, 0xf7, 0x38, 0xff, 0x01, 0x23, 0x60, 0x4c, 0x01, 0x3e, 0x09, 0x19, + 0x16, 0x93, 0x7c, 0xe7, 0x20, 0x23, 0x06, 0x98, 0x9b, 0x1a, 0x98, 0x40, + 0xf2, 0xe7, 0x14, 0x90, 0xb9, 0xe7, 0x0a, 0x9b, 0xdb, 0x1b, 0x0a, 0x93, + 0x7b, 0x42, 0x04, 0x93, 0x00, 0x23, 0x11, 0x93, 0xc6, 0xe7, 0x01, 0x23, + 0x0d, 0x93, 0x21, 0x9b, 0x00, 0x2b, 0x59, 0xdd, 0x0c, 0x93, 0x09, 0x93, + 0x02, 0x9a, 0x55, 0x6a, 0x00, 0x22, 0x6a, 0x60, 0x04, 0x32, 0x10, 0x00, + 0x14, 0x30, 0x69, 0x68, 0x98, 0x42, 0x52, 0xd9, 0x02, 0x98, 0x00, 0xf0, + 0xdc, 0xfc, 0x02, 0x9b, 0x28, 0x60, 0x5b, 0x6a, 0x1b, 0x68, 0x08, 0x93, + 0x09, 0x9b, 0x0e, 0x2b, 0x00, 0xd9, 0x0a, 0xe1, 0x00, 0x2c, 0x00, 0xd1, + 0x07, 0xe1, 0x06, 0x9b, 0x07, 0x9c, 0x12, 0x93, 0x13, 0x94, 0x00, 0x2f, + 0x00, 0xdc, 0x89, 0xe0, 0x0f, 0x21, 0x3a, 0x00, 0x3e, 0x4b, 0x0a, 0x40, + 0xd2, 0x00, 0x9b, 0x18, 0x1d, 0x68, 0x5e, 0x68, 0x02, 0x23, 0x3c, 0x11, + 0x0e, 0x93, 0xe3, 0x06, 0x0b, 0xd5, 0x3d, 0x4b, 0x0c, 0x40, 0x1a, 0x6a, + 0x5b, 0x6a, 0x12, 0x98, 0x13, 0x99, 0xfd, 0xf7, 0xd1, 0xfc, 0x03, 0x23, + 0x06, 0x90, 0x07, 0x91, 0x0e, 0x93, 0x00, 0x23, 0x3a, 0xe0, 0x01, 0x23, + 0x0d, 0x93, 0x21, 0x9b, 0xfb, 0x18, 0x0c, 0x93, 0x01, 0x33, 0x09, 0x93, + 0x00, 0x2b, 0xbb, 0xdc, 0x01, 0x23, 0xb9, 0xe7, 0x00, 0x23, 0xb1, 0xe7, + 0x00, 0x23, 0xf1, 0xe7, 0x00, 0x23, 0x0d, 0x94, 0x20, 0x93, 0x01, 0x3b, + 0x00, 0x22, 0x0c, 0x93, 0x09, 0x93, 0x13, 0x33, 0x21, 0x92, 0xab, 0xe7, + 0x01, 0x23, 0x0d, 0x93, 0x02, 0x3b, 0xf5, 0xe7, 0x01, 0x23, 0x0c, 0x93, + 0x09, 0x93, 0x1a, 0x00, 0xf4, 0xe7, 0x01, 0x31, 0x69, 0x60, 0x52, 0x00, + 0xa3, 0xe7, 0x01, 0x23, 0x1c, 0x42, 0x0e, 0xd0, 0x0e, 0x9b, 0x21, 0x4a, + 0x01, 0x33, 0x0e, 0x93, 0x10, 0x9b, 0x28, 0x00, 0xdb, 0x00, 0x9b, 0x18, + 0x31, 0x00, 0x1a, 0x68, 0x5b, 0x68, 0xfe, 0xf7, 0x9f, 0xf8, 0x05, 0x00, + 0x0e, 0x00, 0x10, 0x9b, 0x64, 0x10, 0x01, 0x33, 0x10, 0x93, 0x00, 0x2c, + 0xe7, 0xd1, 0x06, 0x98, 0x07, 0x99, 0x2a, 0x00, 0x33, 0x00, 0xfd, 0xf7, + 0x87, 0xfc, 0x06, 0x90, 0x07, 0x91, 0x42, 0xe0, 0x00, 0x00, 0xf0, 0x7f, + 0x0f, 0x27, 0x00, 0x00, 0x7e, 0x99, 0x00, 0x00, 0x81, 0x99, 0x00, 0x00, + 0x3d, 0x93, 0x00, 0x00, 0x3e, 0x93, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x3f, + 0x01, 0xfc, 0xff, 0xff, 0x00, 0x00, 0xf8, 0x3f, 0x61, 0x43, 0x6f, 0x63, + 0xa7, 0x87, 0xd2, 0x3f, 0xb3, 0xc8, 0x60, 0x8b, 0x28, 0x8a, 0xc6, 0x3f, + 0xfb, 0x79, 0x9f, 0x50, 0x13, 0x44, 0xd3, 0x3f, 0xb0, 0x99, 0x00, 0x00, + 0x32, 0x04, 0x00, 0x00, 0x12, 0x04, 0x00, 0x00, 0x00, 0x00, 0x10, 0xfe, + 0x88, 0x99, 0x00, 0x00, 0x02, 0x23, 0x0e, 0x93, 0x00, 0x2f, 0x16, 0xd0, + 0x12, 0x98, 0x13, 0x99, 0x7c, 0x42, 0x0d, 0x33, 0x23, 0x40, 0xce, 0x4a, + 0xdb, 0x00, 0xd3, 0x18, 0x1a, 0x68, 0x5b, 0x68, 0xfe, 0xf7, 0x56, 0xf8, + 0x00, 0x23, 0x01, 0x26, 0x1d, 0x00, 0x06, 0x90, 0x07, 0x91, 0x24, 0x11, + 0x00, 0x2c, 0x00, 0xd0, 0x8c, 0xe0, 0x00, 0x2b, 0xb9, 0xd1, 0x14, 0x9b, + 0x00, 0x2b, 0x00, 0xd1, 0x96, 0xe0, 0x06, 0x9c, 0x07, 0x9d, 0x00, 0x22, + 0xc2, 0x4b, 0x20, 0x00, 0x29, 0x00, 0xfd, 0xf7, 0xf1, 0xf8, 0x00, 0x28, + 0x00, 0xd1, 0x8b, 0xe0, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xd1, 0x87, 0xe0, + 0x0c, 0x9b, 0x00, 0x2b, 0x41, 0xdd, 0xbc, 0x4b, 0x00, 0x22, 0x20, 0x00, + 0x29, 0x00, 0xfe, 0xf7, 0x2f, 0xf8, 0x0e, 0x9b, 0x06, 0x90, 0x07, 0x91, + 0x01, 0x33, 0x0e, 0x93, 0x0c, 0x9b, 0x7e, 0x1e, 0x0e, 0x98, 0x10, 0x93, + 0x01, 0xf0, 0x80, 0xf8, 0x06, 0x9a, 0x07, 0x9b, 0xfe, 0xf7, 0x20, 0xf8, + 0x00, 0x22, 0xb2, 0x4b, 0xfd, 0xf7, 0xf6, 0xf8, 0xb1, 0x4a, 0x0e, 0x90, + 0x0f, 0x91, 0x0e, 0x9c, 0x0f, 0x9d, 0x94, 0x46, 0x0f, 0x9b, 0x63, 0x44, + 0x15, 0x93, 0x1d, 0x00, 0x10, 0x9b, 0x00, 0x2b, 0x61, 0xd1, 0x06, 0x98, + 0x07, 0x99, 0x00, 0x22, 0xaa, 0x4b, 0xfe, 0xf7, 0x7b, 0xfa, 0x22, 0x00, + 0x15, 0x9b, 0x06, 0x90, 0x07, 0x91, 0xfd, 0xf7, 0xc9, 0xf8, 0x00, 0x28, + 0x00, 0xd0, 0xa8, 0xe2, 0xa5, 0x48, 0x0f, 0x99, 0x84, 0x46, 0x61, 0x44, + 0x0b, 0x00, 0x06, 0x98, 0x07, 0x99, 0x22, 0x00, 0xfd, 0xf7, 0xa8, 0xf8, + 0x00, 0x28, 0x00, 0xd0, 0x95, 0xe2, 0x12, 0x9b, 0x13, 0x9c, 0x06, 0x93, + 0x07, 0x94, 0x19, 0x9b, 0x00, 0x2b, 0x00, 0xda, 0x5c, 0xe1, 0x0e, 0x2f, + 0x00, 0xdd, 0x59, 0xe1, 0x93, 0x4b, 0xfa, 0x00, 0x9b, 0x18, 0x5c, 0x68, + 0x1b, 0x68, 0x04, 0x93, 0x05, 0x94, 0x21, 0x9b, 0x00, 0x2b, 0x00, 0xdb, + 0xd8, 0xe0, 0x09, 0x9b, 0x00, 0x2b, 0x00, 0xdd, 0xd4, 0xe0, 0x00, 0xd0, + 0x7d, 0xe2, 0x04, 0x98, 0x05, 0x99, 0x00, 0x22, 0x8e, 0x4b, 0xfd, 0xf7, + 0xd1, 0xff, 0x06, 0x9a, 0x07, 0x9b, 0xfd, 0xf7, 0x9d, 0xf8, 0x09, 0x9b, + 0x04, 0x93, 0x1e, 0x00, 0x00, 0x28, 0x00, 0xd0, 0x4f, 0xe2, 0x08, 0x9b, + 0x08, 0x9a, 0x5d, 0x1c, 0x31, 0x23, 0x01, 0x37, 0x13, 0x70, 0x4b, 0xe2, + 0x34, 0x42, 0x0a, 0xd0, 0x0e, 0x9b, 0x85, 0x4a, 0x01, 0x33, 0x0e, 0x93, + 0xeb, 0x00, 0x9b, 0x18, 0x1a, 0x68, 0x5b, 0x68, 0xfd, 0xf7, 0xb4, 0xff, + 0x33, 0x00, 0x64, 0x10, 0x01, 0x35, 0x5f, 0xe7, 0x3e, 0x00, 0x09, 0x9b, + 0x84, 0xe7, 0x10, 0x9b, 0x0d, 0x99, 0x5a, 0x1e, 0x74, 0x4b, 0xd2, 0x00, + 0x9b, 0x18, 0x1a, 0x68, 0x5b, 0x68, 0x00, 0x29, 0x49, 0xd0, 0x00, 0x20, + 0x78, 0x49, 0xfd, 0xf7, 0x95, 0xfb, 0x2b, 0x00, 0x22, 0x00, 0xfe, 0xf7, + 0x0d, 0xfa, 0x08, 0x9b, 0x0e, 0x90, 0x0f, 0x91, 0x15, 0x93, 0x06, 0x98, + 0x07, 0x99, 0xfe, 0xf7, 0x69, 0xfd, 0x04, 0x00, 0x00, 0xf0, 0xec, 0xff, + 0x02, 0x00, 0x0b, 0x00, 0x06, 0x98, 0x07, 0x99, 0xfe, 0xf7, 0xfc, 0xf9, + 0x15, 0x9b, 0x30, 0x34, 0x5d, 0x1c, 0x1c, 0x70, 0x0e, 0x9a, 0x0f, 0x9b, + 0x06, 0x90, 0x07, 0x91, 0xfd, 0xf7, 0x32, 0xf8, 0x00, 0x28, 0x6c, 0xd1, + 0x06, 0x9a, 0x07, 0x9b, 0x00, 0x20, 0x5e, 0x49, 0xfe, 0xf7, 0xea, 0xf9, + 0x0e, 0x9a, 0x0f, 0x9b, 0xfd, 0xf7, 0x26, 0xf8, 0x00, 0x28, 0x00, 0xd0, + 0xc3, 0xe0, 0x08, 0x9b, 0x10, 0x9a, 0xeb, 0x1a, 0x9a, 0x42, 0x00, 0xdc, + 0x77, 0xe7, 0x0e, 0x98, 0x0f, 0x99, 0x00, 0x22, 0x55, 0x4b, 0xfd, 0xf7, + 0x65, 0xff, 0x00, 0x22, 0x0e, 0x90, 0x0f, 0x91, 0x06, 0x98, 0x07, 0x99, + 0x51, 0x4b, 0xfd, 0xf7, 0x5d, 0xff, 0x15, 0x95, 0x06, 0x90, 0x07, 0x91, + 0xc1, 0xe7, 0x20, 0x00, 0x29, 0x00, 0xfd, 0xf7, 0x55, 0xff, 0x08, 0x9c, + 0x10, 0x9a, 0x23, 0x00, 0x94, 0x46, 0x0e, 0x90, 0x0f, 0x91, 0x63, 0x44, + 0x15, 0x93, 0x06, 0x98, 0x07, 0x99, 0xfe, 0xf7, 0x1f, 0xfd, 0x05, 0x00, + 0x00, 0xf0, 0xa2, 0xff, 0x0b, 0x00, 0x02, 0x00, 0x06, 0x98, 0x07, 0x99, + 0xfe, 0xf7, 0xb2, 0xf9, 0x30, 0x35, 0x15, 0x9b, 0x25, 0x70, 0x01, 0x34, + 0x06, 0x90, 0x07, 0x91, 0xa3, 0x42, 0x2a, 0xd1, 0x0e, 0x98, 0x0f, 0x99, + 0x08, 0x9a, 0x10, 0x9b, 0x94, 0x46, 0x63, 0x44, 0x00, 0x22, 0x1d, 0x00, + 0x3f, 0x4b, 0xfd, 0xf7, 0x07, 0xf8, 0x02, 0x00, 0x0b, 0x00, 0x06, 0x98, + 0x07, 0x99, 0xfc, 0xf7, 0xed, 0xff, 0x00, 0x28, 0x00, 0xd0, 0x76, 0xe0, + 0x0e, 0x9a, 0x0f, 0x9b, 0x00, 0x20, 0x38, 0x49, 0xfe, 0xf7, 0x90, 0xf9, + 0x02, 0x00, 0x0b, 0x00, 0x06, 0x98, 0x07, 0x99, 0xfc, 0xf7, 0xca, 0xff, + 0x00, 0x28, 0x00, 0xd1, 0x21, 0xe7, 0x6b, 0x1e, 0x1a, 0x78, 0x30, 0x2a, + 0x01, 0xd0, 0x37, 0x00, 0x3f, 0xe0, 0x1d, 0x00, 0xf7, 0xe7, 0x06, 0x98, + 0x07, 0x99, 0x00, 0x22, 0x26, 0x4b, 0xfd, 0xf7, 0x07, 0xff, 0x06, 0x90, + 0x07, 0x91, 0xb6, 0xe7, 0x08, 0x9e, 0x04, 0x9a, 0x05, 0x9b, 0x06, 0x98, + 0x07, 0x99, 0xfd, 0xf7, 0xf3, 0xfa, 0xfe, 0xf7, 0xd1, 0xfc, 0x04, 0x00, + 0x00, 0xf0, 0x54, 0xff, 0x04, 0x9a, 0x05, 0x9b, 0xfd, 0xf7, 0xf4, 0xfe, + 0x02, 0x00, 0x0b, 0x00, 0x06, 0x98, 0x07, 0x99, 0xfe, 0xf7, 0x60, 0xf9, + 0x23, 0x00, 0x30, 0x33, 0x33, 0x70, 0x09, 0x9a, 0x08, 0x9b, 0x75, 0x1c, + 0xeb, 0x1a, 0x9a, 0x42, 0x48, 0xd1, 0x02, 0x00, 0x0b, 0x00, 0xfc, 0xf7, + 0xbb, 0xff, 0x04, 0x9a, 0x05, 0x9b, 0x06, 0x90, 0x07, 0x91, 0xfc, 0xf7, + 0xa1, 0xff, 0x00, 0x28, 0x2a, 0xd1, 0x04, 0x9a, 0x05, 0x9b, 0x06, 0x98, + 0x07, 0x99, 0xfc, 0xf7, 0x7f, 0xff, 0x00, 0x28, 0x01, 0xd0, 0xe3, 0x07, + 0x20, 0xd4, 0x03, 0x99, 0x02, 0x98, 0x00, 0xf0, 0xdc, 0xfa, 0x00, 0x23, + 0x2b, 0x70, 0x22, 0x9b, 0x01, 0x37, 0x1f, 0x60, 0x24, 0x9b, 0x00, 0x2b, + 0x00, 0xd1, 0xe6, 0xe4, 0x1d, 0x60, 0xe4, 0xe4, 0xb0, 0x99, 0x00, 0x00, + 0x00, 0x00, 0xf0, 0x3f, 0x00, 0x00, 0x24, 0x40, 0x00, 0x00, 0x1c, 0x40, + 0x00, 0x00, 0xc0, 0xfc, 0x00, 0x00, 0x14, 0x40, 0x00, 0x00, 0xc0, 0x7c, + 0x88, 0x99, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x3f, 0x3e, 0x00, 0x6b, 0x1e, + 0x1a, 0x78, 0x39, 0x2a, 0x06, 0xd1, 0x08, 0x9a, 0x9a, 0x42, 0x07, 0xd1, + 0x30, 0x23, 0x13, 0x70, 0x13, 0x00, 0x01, 0x36, 0x1a, 0x78, 0x01, 0x32, + 0x1a, 0x70, 0x8c, 0xe7, 0x1d, 0x00, 0xee, 0xe7, 0x00, 0x22, 0xa4, 0x4b, + 0xfd, 0xf7, 0x98, 0xfe, 0x00, 0x22, 0x00, 0x23, 0x06, 0x90, 0x07, 0x91, + 0x2e, 0x00, 0xfc, 0xf7, 0x3d, 0xff, 0x00, 0x28, 0x8b, 0xd0, 0xbe, 0xe7, + 0x0d, 0x9a, 0x00, 0x2a, 0x00, 0xd1, 0xda, 0xe0, 0x20, 0x9a, 0x01, 0x2a, + 0x00, 0xdd, 0xbd, 0xe0, 0x16, 0x9a, 0x00, 0x2a, 0x00, 0xd1, 0xb5, 0xe0, + 0x98, 0x4a, 0x9b, 0x18, 0x04, 0x9d, 0x0a, 0x9c, 0x0a, 0x9a, 0x01, 0x21, + 0xd2, 0x18, 0x0a, 0x92, 0x0b, 0x9a, 0x02, 0x98, 0xd3, 0x18, 0x0b, 0x93, + 0x00, 0xf0, 0x25, 0xfb, 0x06, 0x00, 0x00, 0x2c, 0x0e, 0xdd, 0x0b, 0x9b, + 0x00, 0x2b, 0x0b, 0xdd, 0x0b, 0x9a, 0x23, 0x00, 0x94, 0x42, 0x00, 0xdd, + 0x13, 0x00, 0x0a, 0x9a, 0xe4, 0x1a, 0xd2, 0x1a, 0x0a, 0x92, 0x0b, 0x9a, + 0xd3, 0x1a, 0x0b, 0x93, 0x04, 0x9b, 0x00, 0x2b, 0x1f, 0xd0, 0x0d, 0x9b, + 0x00, 0x2b, 0x00, 0xd1, 0xaf, 0xe0, 0x00, 0x2d, 0x11, 0xd0, 0x31, 0x00, + 0x2a, 0x00, 0x02, 0x98, 0x00, 0xf0, 0x9e, 0xfb, 0x03, 0x9a, 0x01, 0x00, + 0x06, 0x00, 0x02, 0x98, 0x00, 0xf0, 0x08, 0xfb, 0x03, 0x99, 0x10, 0x90, + 0x02, 0x98, 0x00, 0xf0, 0x5a, 0xfa, 0x10, 0x9b, 0x03, 0x93, 0x04, 0x9b, + 0x5a, 0x1b, 0x04, 0xd0, 0x03, 0x99, 0x02, 0x98, 0x00, 0xf0, 0x8a, 0xfb, + 0x03, 0x90, 0x01, 0x21, 0x02, 0x98, 0x00, 0xf0, 0xec, 0xfa, 0x11, 0x9b, + 0x04, 0x90, 0x00, 0x2b, 0x00, 0xd1, 0xe3, 0xe1, 0x1a, 0x00, 0x01, 0x00, + 0x02, 0x98, 0x00, 0xf0, 0x7b, 0xfb, 0x20, 0x9b, 0x04, 0x90, 0x01, 0x2b, + 0x00, 0xdd, 0x82, 0xe0, 0x00, 0x25, 0x06, 0x9b, 0xab, 0x42, 0x0e, 0xd1, + 0x07, 0x9b, 0x1b, 0x03, 0xab, 0x42, 0x0a, 0xd1, 0x17, 0x9b, 0x07, 0x9a, + 0x13, 0x42, 0x06, 0xd0, 0x0a, 0x9b, 0x01, 0x35, 0x01, 0x33, 0x0a, 0x93, + 0x0b, 0x9b, 0x01, 0x33, 0x0b, 0x93, 0x11, 0x9b, 0x01, 0x20, 0x00, 0x2b, + 0x6c, 0xd1, 0x0b, 0x9b, 0x18, 0x18, 0x1f, 0x23, 0x18, 0x40, 0x7e, 0xd0, + 0x01, 0x33, 0x1b, 0x1a, 0x04, 0x2b, 0x70, 0xdd, 0x1c, 0x23, 0x18, 0x1a, + 0x0a, 0x9b, 0x24, 0x18, 0x1b, 0x18, 0x0a, 0x93, 0x0b, 0x9b, 0x1b, 0x18, + 0x0b, 0x93, 0x0a, 0x9b, 0x00, 0x2b, 0x05, 0xdd, 0x1a, 0x00, 0x03, 0x99, + 0x02, 0x98, 0x00, 0xf0, 0x97, 0xfb, 0x03, 0x90, 0x0b, 0x9b, 0x00, 0x2b, + 0x05, 0xdd, 0x1a, 0x00, 0x04, 0x99, 0x02, 0x98, 0x00, 0xf0, 0x8e, 0xfb, + 0x04, 0x90, 0x14, 0x9b, 0x00, 0x2b, 0x5e, 0xd0, 0x04, 0x99, 0x03, 0x98, + 0x00, 0xf0, 0xd8, 0xfb, 0x00, 0x28, 0x58, 0xda, 0x00, 0x23, 0x0a, 0x22, + 0x03, 0x99, 0x02, 0x98, 0x00, 0xf0, 0x0c, 0xfa, 0x0d, 0x9b, 0x01, 0x3f, + 0x03, 0x90, 0x00, 0x2b, 0x00, 0xd1, 0x90, 0xe1, 0x00, 0x23, 0x31, 0x00, + 0x0a, 0x22, 0x02, 0x98, 0x00, 0xf0, 0x00, 0xfa, 0x0c, 0x9b, 0x06, 0x00, + 0x00, 0x2b, 0x00, 0xdd, 0x88, 0xe0, 0x20, 0x9b, 0x02, 0x2b, 0x00, 0xdc, + 0x84, 0xe0, 0x44, 0xe0, 0x36, 0x23, 0x18, 0x9a, 0x9b, 0x1a, 0x47, 0xe7, + 0x09, 0x9b, 0x5d, 0x1e, 0x04, 0x9b, 0xab, 0x42, 0x08, 0xdb, 0x5d, 0x1b, + 0x09, 0x9b, 0x00, 0x2b, 0x0c, 0xda, 0x0a, 0x9b, 0x09, 0x9a, 0x9c, 0x1a, + 0x00, 0x23, 0x3b, 0xe7, 0x04, 0x9b, 0x04, 0x95, 0xea, 0x1a, 0x11, 0x9b, + 0x00, 0x25, 0x9b, 0x18, 0x11, 0x93, 0xef, 0xe7, 0x0a, 0x9c, 0x09, 0x9b, + 0x30, 0xe7, 0x04, 0x9d, 0x0a, 0x9c, 0x0d, 0x9e, 0x37, 0xe7, 0x04, 0x9a, + 0x64, 0xe7, 0x00, 0x25, 0x04, 0x9b, 0x04, 0x9a, 0x1b, 0x69, 0x10, 0x93, + 0x03, 0x33, 0x9b, 0x00, 0xd3, 0x18, 0x58, 0x68, 0x00, 0xf0, 0x06, 0xfa, + 0x20, 0x23, 0x18, 0x1a, 0x85, 0xe7, 0x04, 0x2b, 0x95, 0xd0, 0x0a, 0x9a, + 0x1c, 0x33, 0xd2, 0x18, 0x0a, 0x92, 0x0b, 0x9a, 0xe4, 0x18, 0xd3, 0x18, + 0x8c, 0xe7, 0x03, 0x00, 0xf5, 0xe7, 0x09, 0x9b, 0x00, 0x2b, 0x3d, 0xdc, + 0x20, 0x9b, 0x02, 0x2b, 0x3a, 0xdd, 0x09, 0x9b, 0x0c, 0x93, 0x0c, 0x9b, + 0x00, 0x2b, 0x0c, 0xd1, 0x04, 0x99, 0x05, 0x22, 0x02, 0x98, 0x00, 0xf0, + 0xa9, 0xf9, 0x04, 0x90, 0x01, 0x00, 0x03, 0x98, 0x00, 0xf0, 0x68, 0xfb, + 0x00, 0x28, 0x00, 0xdd, 0xaf, 0xe5, 0x21, 0x9b, 0x08, 0x9d, 0xdf, 0x43, + 0x00, 0x23, 0x09, 0x93, 0x04, 0x99, 0x02, 0x98, 0x00, 0xf0, 0x7f, 0xf9, + 0x00, 0x2e, 0x00, 0xd1, 0x9b, 0xe6, 0x09, 0x9b, 0x00, 0x2b, 0x05, 0xd0, + 0xb3, 0x42, 0x03, 0xd0, 0x19, 0x00, 0x02, 0x98, 0x00, 0xf0, 0x73, 0xf9, + 0x31, 0x00, 0x02, 0x98, 0x00, 0xf0, 0x6f, 0xf9, 0x8d, 0xe6, 0x10, 0x9b, + 0x04, 0x93, 0x1e, 0x00, 0xe1, 0xe7, 0x00, 0x23, 0xfa, 0xe7, 0x10, 0x9b, + 0x37, 0x00, 0x04, 0x93, 0x1e, 0x00, 0x8a, 0xe5, 0x00, 0x00, 0x24, 0x40, + 0x33, 0x04, 0x00, 0x00, 0x0d, 0x9b, 0x00, 0x2b, 0x00, 0xd1, 0xb2, 0xe0, + 0x09, 0x9b, 0x0c, 0x93, 0x00, 0x2c, 0x05, 0xdd, 0x31, 0x00, 0x22, 0x00, + 0x02, 0x98, 0x00, 0xf0, 0xdd, 0xfa, 0x06, 0x00, 0x30, 0x00, 0x00, 0x2d, + 0x11, 0xd0, 0x71, 0x68, 0x02, 0x98, 0x00, 0xf0, 0x12, 0xf9, 0x31, 0x00, + 0x04, 0x00, 0x33, 0x69, 0x0c, 0x31, 0x9a, 0x1c, 0x92, 0x00, 0x0c, 0x30, + 0xfe, 0xf7, 0x04, 0xfc, 0x01, 0x22, 0x21, 0x00, 0x02, 0x98, 0x00, 0xf0, + 0xc7, 0xfa, 0x09, 0x96, 0x06, 0x00, 0x08, 0x9b, 0x0a, 0x93, 0x04, 0x99, + 0x03, 0x98, 0xff, 0xf7, 0x7d, 0xfa, 0x09, 0x99, 0x0d, 0x90, 0x04, 0x00, + 0x03, 0x98, 0x00, 0xf0, 0x0b, 0xfb, 0x32, 0x00, 0x10, 0x90, 0x04, 0x99, + 0x02, 0x98, 0x00, 0xf0, 0x1f, 0xfb, 0x01, 0x23, 0x0b, 0x93, 0xc3, 0x68, + 0x30, 0x34, 0x05, 0x00, 0x00, 0x2b, 0x04, 0xd1, 0x01, 0x00, 0x03, 0x98, + 0x00, 0xf0, 0xfa, 0xfa, 0x0b, 0x90, 0x29, 0x00, 0x02, 0x98, 0x00, 0xf0, + 0x18, 0xf9, 0x0b, 0x9b, 0x20, 0x9a, 0x13, 0x43, 0x0e, 0xd1, 0x06, 0x9a, + 0x01, 0x33, 0x13, 0x42, 0x0a, 0xd1, 0x39, 0x2c, 0x26, 0xd0, 0x10, 0x9b, + 0x00, 0x2b, 0x01, 0xdd, 0x0d, 0x9c, 0x31, 0x34, 0x0a, 0x9b, 0x5d, 0x1c, + 0x1c, 0x70, 0x81, 0xe7, 0x10, 0x9b, 0x00, 0x2b, 0x07, 0xdb, 0x1d, 0x00, + 0x20, 0x9b, 0x1d, 0x43, 0x22, 0xd1, 0x01, 0x23, 0x06, 0x9a, 0x13, 0x42, + 0x1e, 0xd1, 0x0b, 0x9b, 0x00, 0x2b, 0xed, 0xdd, 0x03, 0x99, 0x01, 0x22, + 0x02, 0x98, 0x00, 0xf0, 0x7d, 0xfa, 0x04, 0x99, 0x03, 0x90, 0x00, 0xf0, + 0xcb, 0xfa, 0x00, 0x28, 0x02, 0xdc, 0xe1, 0xd1, 0xe3, 0x07, 0xdf, 0xd5, + 0x39, 0x2c, 0xdb, 0xd1, 0x0a, 0x9b, 0x0a, 0x9a, 0x5d, 0x1c, 0x39, 0x23, + 0x13, 0x70, 0x6b, 0x1e, 0x1a, 0x78, 0x39, 0x2a, 0x67, 0xd0, 0x01, 0x32, + 0x1a, 0x70, 0x57, 0xe7, 0x0a, 0x9b, 0x5d, 0x1c, 0x0b, 0x9b, 0x00, 0x2b, + 0x04, 0xdd, 0x39, 0x2c, 0xec, 0xd0, 0x01, 0x34, 0x0a, 0x9b, 0xc9, 0xe7, + 0x0a, 0x9b, 0x0c, 0x9a, 0x1c, 0x70, 0x08, 0x9b, 0xeb, 0x1a, 0x93, 0x42, + 0x3e, 0xd0, 0x00, 0x23, 0x0a, 0x22, 0x03, 0x99, 0x02, 0x98, 0x00, 0xf0, + 0xdd, 0xf8, 0x09, 0x9b, 0x03, 0x90, 0xb3, 0x42, 0x09, 0xd1, 0x00, 0x23, + 0x0a, 0x22, 0x09, 0x99, 0x02, 0x98, 0x00, 0xf0, 0xd3, 0xf8, 0x09, 0x90, + 0x06, 0x00, 0x0a, 0x95, 0x7d, 0xe7, 0x09, 0x99, 0x00, 0x23, 0x0a, 0x22, + 0x02, 0x98, 0x00, 0xf0, 0xc9, 0xf8, 0x00, 0x23, 0x09, 0x90, 0x0a, 0x22, + 0x31, 0x00, 0x02, 0x98, 0x00, 0xf0, 0xc2, 0xf8, 0xee, 0xe7, 0x09, 0x9b, + 0x0c, 0x93, 0x08, 0x9b, 0x06, 0x93, 0x04, 0x99, 0x03, 0x98, 0xff, 0xf7, + 0xe9, 0xf9, 0x06, 0x9b, 0x30, 0x30, 0x5d, 0x1c, 0x18, 0x70, 0x0c, 0x9a, + 0x08, 0x9b, 0x04, 0x00, 0xeb, 0x1a, 0x9a, 0x42, 0x08, 0xdd, 0x00, 0x23, + 0x0a, 0x22, 0x03, 0x99, 0x02, 0x98, 0x00, 0xf0, 0xa9, 0xf8, 0x06, 0x95, + 0x03, 0x90, 0xe8, 0xe7, 0x00, 0x23, 0x09, 0x93, 0x03, 0x99, 0x01, 0x22, + 0x02, 0x98, 0x00, 0xf0, 0x11, 0xfa, 0x04, 0x99, 0x03, 0x90, 0x00, 0xf0, + 0x5f, 0xfa, 0x00, 0x28, 0x9d, 0xdc, 0x01, 0xd1, 0xe3, 0x07, 0x9a, 0xd4, + 0x6b, 0x1e, 0x1a, 0x78, 0x30, 0x2a, 0x00, 0xd0, 0xf4, 0xe6, 0x1d, 0x00, + 0xf8, 0xe7, 0x08, 0x9a, 0x9a, 0x42, 0x03, 0xd1, 0x31, 0x23, 0x01, 0x37, + 0x13, 0x70, 0xeb, 0xe6, 0x1d, 0x00, 0x8a, 0xe7, 0x0b, 0x4b, 0x24, 0x9a, + 0x08, 0x93, 0x0b, 0x4b, 0x00, 0x2a, 0x01, 0xd0, 0xff, 0xf7, 0x77, 0xfa, + 0xff, 0xf7, 0x77, 0xfa, 0x20, 0x9b, 0x01, 0x2b, 0x00, 0xdc, 0x21, 0xe6, + 0x11, 0x9d, 0x01, 0x20, 0x35, 0xe6, 0x0c, 0x9b, 0x00, 0x2b, 0xb2, 0xdc, + 0x20, 0x9b, 0x02, 0x2b, 0xaf, 0xdd, 0xbc, 0xe6, 0x75, 0x99, 0x00, 0x00, + 0x7d, 0x99, 0x00, 0x00, 0x03, 0x4b, 0x1b, 0x68, 0x18, 0x6a, 0x00, 0x28, + 0x00, 0xd1, 0x02, 0x48, 0xf0, 0x30, 0x70, 0x47, 0x28, 0x00, 0x00, 0x20, + 0x8c, 0x00, 0x00, 0x20, 0xc9, 0xb2, 0x82, 0x18, 0x90, 0x42, 0x01, 0xd1, + 0x00, 0x20, 0x70, 0x47, 0x03, 0x78, 0x8b, 0x42, 0xfb, 0xd0, 0x01, 0x30, + 0xf6, 0xe7, 0x70, 0x47, 0x70, 0x47, 0x70, 0xb5, 0x46, 0x6a, 0x04, 0x00, + 0x0d, 0x00, 0x00, 0x2e, 0x07, 0xd1, 0x10, 0x20, 0xfe, 0xf7, 0xcc, 0xfa, + 0x60, 0x62, 0x46, 0x60, 0x86, 0x60, 0x06, 0x60, 0xc6, 0x60, 0x66, 0x6a, + 0xf3, 0x68, 0x00, 0x2b, 0x13, 0xd0, 0x63, 0x6a, 0xaa, 0x00, 0xdb, 0x68, + 0x9b, 0x18, 0x18, 0x68, 0x00, 0x28, 0x18, 0xd1, 0x01, 0x21, 0x0e, 0x00, + 0xae, 0x40, 0x72, 0x1d, 0x92, 0x00, 0x20, 0x00, 0x00, 0xf0, 0xc6, 0xfa, + 0x00, 0x28, 0x0c, 0xd0, 0x45, 0x60, 0x86, 0x60, 0x0d, 0xe0, 0x21, 0x22, + 0x04, 0x21, 0x20, 0x00, 0x00, 0xf0, 0xbc, 0xfa, 0x63, 0x6a, 0xf0, 0x60, + 0xdb, 0x68, 0x00, 0x2b, 0xe1, 0xd1, 0x00, 0x20, 0x70, 0xbd, 0x02, 0x68, + 0x1a, 0x60, 0x00, 0x23, 0x03, 0x61, 0xc3, 0x60, 0xf8, 0xe7, 0x70, 0xb5, + 0x44, 0x6a, 0x06, 0x00, 0x0d, 0x00, 0x00, 0x2c, 0x07, 0xd1, 0x10, 0x20, + 0xfe, 0xf7, 0x94, 0xfa, 0x70, 0x62, 0x44, 0x60, 0x84, 0x60, 0x04, 0x60, + 0xc4, 0x60, 0x00, 0x2d, 0x07, 0xd0, 0x73, 0x6a, 0x6a, 0x68, 0xdb, 0x68, + 0x92, 0x00, 0x9b, 0x18, 0x1a, 0x68, 0x2a, 0x60, 0x1d, 0x60, 0x70, 0xbd, + 0xf7, 0xb5, 0x1e, 0x00, 0x14, 0x23, 0x9c, 0x46, 0x07, 0x00, 0x0c, 0x00, + 0x00, 0x20, 0x0d, 0x69, 0x8c, 0x44, 0x63, 0x46, 0x1b, 0x68, 0x01, 0x30, + 0x99, 0xb2, 0x63, 0x46, 0x1b, 0x68, 0x51, 0x43, 0x1b, 0x0c, 0x53, 0x43, + 0x89, 0x19, 0x0e, 0x0c, 0x9b, 0x19, 0x89, 0xb2, 0x1e, 0x0c, 0x1b, 0x04, + 0x5b, 0x18, 0x61, 0x46, 0x08, 0xc1, 0x8c, 0x46, 0x85, 0x42, 0xea, 0xdc, + 0x00, 0x2e, 0x1b, 0xd0, 0xa3, 0x68, 0xab, 0x42, 0x12, 0xdc, 0x63, 0x68, + 0x38, 0x00, 0x59, 0x1c, 0xff, 0xf7, 0x87, 0xff, 0x21, 0x00, 0x23, 0x69, + 0x01, 0x90, 0x9a, 0x1c, 0x92, 0x00, 0x0c, 0x31, 0x0c, 0x30, 0xfe, 0xf7, + 0x79, 0xfa, 0x21, 0x00, 0x38, 0x00, 0xff, 0xf7, 0xb2, 0xff, 0x01, 0x9c, + 0x2b, 0x1d, 0x9b, 0x00, 0xe3, 0x18, 0x01, 0x35, 0x5e, 0x60, 0x25, 0x61, + 0x20, 0x00, 0xfe, 0xbd, 0x03, 0x00, 0x02, 0x0c, 0x00, 0x20, 0x82, 0x42, + 0x01, 0xd1, 0x1b, 0x04, 0x10, 0x30, 0x1a, 0x0e, 0x01, 0xd1, 0x08, 0x30, + 0x1b, 0x02, 0x1a, 0x0f, 0x01, 0xd1, 0x04, 0x30, 0x1b, 0x01, 0x9a, 0x0f, + 0x01, 0xd1, 0x02, 0x30, 0x9b, 0x00, 0x00, 0x2b, 0x03, 0xdb, 0x01, 0x30, + 0x5b, 0x00, 0x00, 0xd4, 0x20, 0x20, 0x70, 0x47, 0x07, 0x22, 0x03, 0x68, + 0x10, 0xb5, 0x01, 0x00, 0x1a, 0x40, 0x0d, 0xd0, 0x01, 0x24, 0x00, 0x20, + 0x23, 0x42, 0x05, 0xd1, 0x02, 0x30, 0x03, 0x42, 0x03, 0xd0, 0xe3, 0x40, + 0x20, 0x00, 0x0b, 0x60, 0x10, 0xbd, 0x9b, 0x08, 0x0b, 0x60, 0xfb, 0xe7, + 0x9c, 0xb2, 0x10, 0x00, 0x00, 0x2c, 0x01, 0xd1, 0x10, 0x20, 0x1b, 0x0c, + 0xda, 0xb2, 0x00, 0x2a, 0x01, 0xd1, 0x08, 0x30, 0x1b, 0x0a, 0x1a, 0x07, + 0x01, 0xd1, 0x04, 0x30, 0x1b, 0x09, 0x9a, 0x07, 0x01, 0xd1, 0x02, 0x30, + 0x9b, 0x08, 0xda, 0x07, 0xe8, 0xd4, 0x5b, 0x08, 0x01, 0xd0, 0x01, 0x30, + 0xe4, 0xe7, 0x20, 0x20, 0xe0, 0xe7, 0x10, 0xb5, 0x0c, 0x00, 0x01, 0x21, + 0xff, 0xf7, 0x23, 0xff, 0x01, 0x23, 0x44, 0x61, 0x03, 0x61, 0x10, 0xbd, + 0xf0, 0xb5, 0x0b, 0x69, 0x14, 0x00, 0x12, 0x69, 0x89, 0xb0, 0x0d, 0x00, + 0x93, 0x42, 0x01, 0xda, 0x25, 0x00, 0x0c, 0x00, 0x2f, 0x69, 0x26, 0x69, + 0x69, 0x68, 0xbb, 0x19, 0x02, 0x93, 0xab, 0x68, 0xba, 0x19, 0x93, 0x42, + 0x00, 0xda, 0x01, 0x31, 0xff, 0xf7, 0x09, 0xff, 0x02, 0x00, 0xbb, 0x19, + 0x14, 0x32, 0x9b, 0x00, 0xd3, 0x18, 0x9c, 0x46, 0x00, 0x21, 0x13, 0x00, + 0x04, 0x90, 0x63, 0x45, 0x1d, 0xd3, 0x14, 0x35, 0xbf, 0x00, 0xeb, 0x19, + 0x14, 0x34, 0xb6, 0x00, 0x05, 0x93, 0xa3, 0x19, 0x03, 0x95, 0x01, 0x94, + 0x07, 0x93, 0x07, 0x9b, 0x01, 0x99, 0x99, 0x42, 0x11, 0xd3, 0x02, 0x9b, + 0x00, 0x2b, 0x06, 0xdd, 0x04, 0x23, 0x5b, 0x42, 0x9c, 0x44, 0x63, 0x46, + 0x1b, 0x68, 0x00, 0x2b, 0x51, 0xd0, 0x04, 0x9b, 0x02, 0x9a, 0x18, 0x00, + 0x1a, 0x61, 0x09, 0xb0, 0xf0, 0xbd, 0x02, 0xc3, 0xdd, 0xe7, 0x01, 0x9b, + 0x1b, 0x68, 0x98, 0xb2, 0x00, 0x28, 0x1c, 0xd0, 0x15, 0x00, 0x00, 0x26, + 0x03, 0x9f, 0x02, 0xcf, 0x2c, 0x68, 0x8b, 0xb2, 0x43, 0x43, 0x09, 0x0c, + 0x41, 0x43, 0xa4, 0xb2, 0x1b, 0x19, 0x9b, 0x19, 0x0e, 0x00, 0x29, 0x68, + 0x06, 0x95, 0x09, 0x0c, 0x71, 0x18, 0x1e, 0x0c, 0x89, 0x19, 0x0e, 0x0c, + 0x9b, 0xb2, 0x09, 0x04, 0x0b, 0x43, 0x08, 0xc5, 0x05, 0x9b, 0xbb, 0x42, + 0xe7, 0xd8, 0x06, 0x9b, 0x5e, 0x60, 0x01, 0x9b, 0x1b, 0x68, 0x1d, 0x0c, + 0x1e, 0xd0, 0x10, 0x00, 0x00, 0x27, 0x13, 0x68, 0x03, 0x9e, 0x31, 0x68, + 0x04, 0x68, 0x89, 0xb2, 0x69, 0x43, 0x24, 0x0c, 0x09, 0x19, 0xc9, 0x19, + 0x0f, 0x04, 0x9b, 0xb2, 0x3b, 0x43, 0x03, 0x60, 0x80, 0xce, 0x43, 0x68, + 0x3f, 0x0c, 0x6f, 0x43, 0x9b, 0xb2, 0xfb, 0x18, 0x09, 0x0c, 0x5b, 0x18, + 0x05, 0x99, 0x06, 0x90, 0x1f, 0x0c, 0x04, 0x30, 0xb1, 0x42, 0xe6, 0xd8, + 0x06, 0x99, 0x4b, 0x60, 0x01, 0x9b, 0x04, 0x32, 0x04, 0x33, 0x01, 0x93, + 0x9f, 0xe7, 0x02, 0x9b, 0x01, 0x3b, 0x02, 0x93, 0x9f, 0xe7, 0x00, 0x00, + 0x03, 0x23, 0xf7, 0xb5, 0x13, 0x40, 0x05, 0x00, 0x0e, 0x00, 0x14, 0x00, + 0x00, 0x2b, 0x08, 0xd0, 0x22, 0x49, 0x01, 0x3b, 0x9a, 0x00, 0x52, 0x58, + 0x00, 0x23, 0x31, 0x00, 0xff, 0xf7, 0xd0, 0xfe, 0x06, 0x00, 0xa3, 0x10, + 0x01, 0x93, 0x36, 0xd0, 0x6c, 0x6a, 0x00, 0x2c, 0x07, 0xd1, 0x10, 0x20, + 0xfe, 0xf7, 0x4a, 0xf9, 0x68, 0x62, 0x44, 0x60, 0x84, 0x60, 0x04, 0x60, + 0xc4, 0x60, 0x6f, 0x6a, 0xbc, 0x68, 0x00, 0x2c, 0x07, 0xd1, 0x16, 0x49, + 0x28, 0x00, 0xff, 0xf7, 0x40, 0xff, 0x00, 0x23, 0x04, 0x00, 0xb8, 0x60, + 0x03, 0x60, 0x01, 0x22, 0x01, 0x9b, 0x13, 0x42, 0x0a, 0xd0, 0x31, 0x00, + 0x22, 0x00, 0x28, 0x00, 0xff, 0xf7, 0x3c, 0xff, 0x07, 0x00, 0x31, 0x00, + 0x28, 0x00, 0xff, 0xf7, 0x8e, 0xfe, 0x3e, 0x00, 0x01, 0x9b, 0x5b, 0x10, + 0x01, 0x93, 0x0c, 0xd0, 0x20, 0x68, 0x00, 0x28, 0x07, 0xd1, 0x22, 0x00, + 0x21, 0x00, 0x28, 0x00, 0xff, 0xf7, 0x2a, 0xff, 0x00, 0x23, 0x20, 0x60, + 0x03, 0x60, 0x04, 0x00, 0xdf, 0xe7, 0x30, 0x00, 0xfe, 0xbd, 0xc0, 0x46, + 0x78, 0x9a, 0x00, 0x00, 0x71, 0x02, 0x00, 0x00, 0xf0, 0xb5, 0x0d, 0x00, + 0x17, 0x00, 0x2b, 0x69, 0x54, 0x11, 0x85, 0xb0, 0xe3, 0x18, 0x01, 0x93, + 0x01, 0x33, 0x00, 0x93, 0x49, 0x68, 0xab, 0x68, 0x02, 0x90, 0x00, 0x9a, + 0x93, 0x42, 0x35, 0xdb, 0x02, 0x98, 0xff, 0xf7, 0x2a, 0xfe, 0x00, 0x23, + 0x02, 0x00, 0x06, 0x00, 0x19, 0x00, 0x14, 0x32, 0xa3, 0x42, 0x2e, 0xdb, + 0xe3, 0x43, 0xdb, 0x17, 0x1c, 0x40, 0x2b, 0x00, 0xa4, 0x00, 0x14, 0x19, + 0x2a, 0x69, 0x14, 0x33, 0x92, 0x00, 0x9a, 0x18, 0x94, 0x46, 0x1f, 0x22, + 0x17, 0x40, 0x24, 0xd0, 0x01, 0x32, 0xd2, 0x1b, 0x03, 0x92, 0x00, 0x22, + 0x19, 0x68, 0x20, 0x00, 0xb9, 0x40, 0x0a, 0x43, 0x04, 0xc4, 0x04, 0xcb, + 0x03, 0x99, 0xca, 0x40, 0x9c, 0x45, 0xf5, 0xd8, 0x42, 0x60, 0x00, 0x2a, + 0x02, 0xd0, 0x01, 0x9b, 0x02, 0x33, 0x00, 0x93, 0x00, 0x9b, 0x02, 0x98, + 0x01, 0x3b, 0x33, 0x61, 0x29, 0x00, 0xff, 0xf7, 0x32, 0xfe, 0x30, 0x00, + 0x05, 0xb0, 0xf0, 0xbd, 0x01, 0x31, 0x5b, 0x00, 0xc3, 0xe7, 0x98, 0x00, + 0x11, 0x50, 0x01, 0x33, 0xca, 0xe7, 0x04, 0xcb, 0x04, 0xc4, 0x9c, 0x45, + 0xfb, 0xd8, 0xe9, 0xe7, 0x0a, 0x69, 0x03, 0x69, 0x30, 0xb5, 0x9b, 0x1a, + 0x0d, 0xd1, 0x92, 0x00, 0x14, 0x30, 0x14, 0x31, 0x84, 0x18, 0x89, 0x18, + 0x04, 0x3c, 0x04, 0x39, 0x25, 0x68, 0x0a, 0x68, 0x95, 0x42, 0x04, 0xd0, + 0x01, 0x23, 0x95, 0x42, 0x04, 0xd3, 0x18, 0x00, 0x30, 0xbd, 0xa0, 0x42, + 0xf2, 0xd3, 0xfa, 0xe7, 0x5b, 0x42, 0xf8, 0xe7, 0xf0, 0xb5, 0x0d, 0x00, + 0x85, 0xb0, 0x07, 0x00, 0x11, 0x00, 0x28, 0x00, 0x14, 0x00, 0xff, 0xf7, + 0xdd, 0xff, 0x06, 0x1e, 0x08, 0xd1, 0x01, 0x00, 0x38, 0x00, 0xff, 0xf7, + 0xc2, 0xfd, 0x01, 0x23, 0x46, 0x61, 0x03, 0x61, 0x05, 0xb0, 0xf0, 0xbd, + 0x01, 0x23, 0x01, 0x93, 0x00, 0x28, 0x04, 0xdb, 0x23, 0x00, 0x2c, 0x00, + 0x1d, 0x00, 0x00, 0x23, 0x01, 0x93, 0x61, 0x68, 0x38, 0x00, 0xff, 0xf7, + 0xb0, 0xfd, 0x2f, 0x00, 0x00, 0x22, 0x01, 0x9b, 0x26, 0x69, 0xc3, 0x60, + 0x14, 0x34, 0xb3, 0x00, 0xe3, 0x18, 0x02, 0x93, 0x2b, 0x69, 0x14, 0x37, + 0x9b, 0x00, 0xfb, 0x18, 0x03, 0x93, 0x03, 0x00, 0x94, 0x46, 0x14, 0x33, + 0x20, 0xcc, 0x04, 0xcf, 0x01, 0x92, 0xaa, 0xb2, 0x94, 0x44, 0x6a, 0x46, + 0x61, 0x46, 0x92, 0x88, 0x2d, 0x0c, 0x8a, 0x1a, 0x01, 0x99, 0x09, 0x0c, + 0x69, 0x1a, 0x15, 0x14, 0x49, 0x19, 0x0d, 0x14, 0x92, 0xb2, 0x09, 0x04, + 0x0a, 0x43, 0x1a, 0x60, 0x03, 0x9a, 0xac, 0x46, 0x04, 0x33, 0xba, 0x42, + 0xe6, 0xd8, 0x02, 0x99, 0x1a, 0x00, 0x8c, 0x42, 0x05, 0xd3, 0x04, 0x3a, + 0x13, 0x68, 0x00, 0x2b, 0x0e, 0xd0, 0x06, 0x61, 0xbc, 0xe7, 0x04, 0xcc, + 0x91, 0xb2, 0x61, 0x44, 0x0d, 0x14, 0x12, 0x0c, 0x52, 0x19, 0x15, 0x14, + 0x89, 0xb2, 0x12, 0x04, 0x0a, 0x43, 0xac, 0x46, 0x04, 0xc3, 0xe8, 0xe7, + 0x01, 0x3e, 0xea, 0xe7, 0xf7, 0xb5, 0x1d, 0x00, 0x01, 0x21, 0x14, 0x00, + 0x08, 0x9f, 0xff, 0xf7, 0x66, 0xfd, 0x2b, 0x03, 0x6d, 0x00, 0x06, 0x00, + 0x1b, 0x0b, 0x6d, 0x0d, 0x24, 0xd1, 0x01, 0x93, 0x00, 0x2c, 0x27, 0xd0, + 0x68, 0x46, 0x00, 0x94, 0xff, 0xf7, 0x02, 0xfe, 0x00, 0x9c, 0x00, 0x28, + 0x1e, 0xd0, 0x01, 0x9b, 0x20, 0x21, 0x1a, 0x00, 0x09, 0x1a, 0x8a, 0x40, + 0xc3, 0x40, 0x22, 0x43, 0x72, 0x61, 0x01, 0x93, 0x01, 0x9c, 0xb4, 0x61, + 0x63, 0x1e, 0x9c, 0x41, 0x01, 0x34, 0x34, 0x61, 0x00, 0x2d, 0x18, 0xd0, + 0x12, 0x4b, 0xed, 0x18, 0x35, 0x23, 0x2d, 0x18, 0x3d, 0x60, 0x18, 0x1a, + 0x09, 0x9b, 0x18, 0x60, 0x30, 0x00, 0xfe, 0xbd, 0x80, 0x22, 0x52, 0x03, + 0x13, 0x43, 0xd6, 0xe7, 0x74, 0x61, 0xe7, 0xe7, 0x01, 0xa8, 0xff, 0xf7, + 0xdb, 0xfd, 0x01, 0x24, 0x01, 0x9b, 0x34, 0x61, 0x73, 0x61, 0x20, 0x30, + 0xe4, 0xe7, 0x07, 0x4b, 0xc0, 0x18, 0x07, 0x4b, 0x38, 0x60, 0xe3, 0x18, + 0x9b, 0x00, 0xf3, 0x18, 0x58, 0x69, 0xff, 0xf7, 0xb1, 0xfd, 0x64, 0x01, + 0x20, 0x1a, 0xdf, 0xe7, 0xcd, 0xfb, 0xff, 0xff, 0xce, 0xfb, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x3f, 0x4a, 0x43, 0x70, 0xb5, 0x11, 0x00, 0x14, 0x00, + 0xfe, 0xf7, 0x7c, 0xf8, 0x05, 0x1e, 0x03, 0xd0, 0x22, 0x00, 0x00, 0x21, + 0xfe, 0xf7, 0x24, 0xf8, 0x28, 0x00, 0x70, 0xbd, 0xf8, 0xb5, 0x07, 0x00, + 0x0d, 0x00, 0x16, 0x00, 0x00, 0x29, 0x05, 0xd1, 0x11, 0x00, 0xfe, 0xf7, + 0x6b, 0xf8, 0x04, 0x00, 0x20, 0x00, 0xf8, 0xbd, 0x00, 0x2a, 0x03, 0xd1, + 0xfe, 0xf7, 0x1a, 0xf8, 0x34, 0x00, 0xf7, 0xe7, 0x00, 0xf0, 0x72, 0xf9, + 0x2c, 0x00, 0xb0, 0x42, 0xf2, 0xd2, 0x31, 0x00, 0x38, 0x00, 0xfe, 0xf7, + 0x59, 0xf8, 0x04, 0x1e, 0xec, 0xd0, 0x29, 0x00, 0x32, 0x00, 0xfd, 0xf7, + 0xe5, 0xff, 0x29, 0x00, 0x38, 0x00, 0xfe, 0xf7, 0x05, 0xf8, 0xe3, 0xe7, + 0xf0, 0xb5, 0x8e, 0x68, 0x85, 0xb0, 0x07, 0x00, 0x0c, 0x00, 0x03, 0x92, + 0x01, 0x93, 0x9e, 0x42, 0x3c, 0xd8, 0x90, 0x23, 0x8a, 0x89, 0xdb, 0x00, + 0x1a, 0x42, 0x34, 0xd0, 0x03, 0x25, 0x09, 0x69, 0x23, 0x68, 0x5b, 0x1a, + 0x02, 0x93, 0x63, 0x69, 0x02, 0x98, 0x5d, 0x43, 0xeb, 0x0f, 0x5d, 0x19, + 0x01, 0x9b, 0x6d, 0x10, 0x01, 0x33, 0x1b, 0x18, 0xab, 0x42, 0x00, 0xd9, + 0x1d, 0x00, 0x53, 0x05, 0x32, 0xd5, 0x29, 0x00, 0x38, 0x00, 0xfe, 0xf7, + 0x29, 0xf8, 0x06, 0x1e, 0x09, 0xd1, 0x0c, 0x23, 0x3b, 0x60, 0x40, 0x23, + 0x01, 0x20, 0xa2, 0x89, 0x40, 0x42, 0x13, 0x43, 0xa3, 0x81, 0x05, 0xb0, + 0xf0, 0xbd, 0x02, 0x9a, 0x21, 0x69, 0xfd, 0xf7, 0xab, 0xff, 0xa3, 0x89, + 0x14, 0x4a, 0x1a, 0x40, 0x80, 0x23, 0x13, 0x43, 0xa3, 0x81, 0x02, 0x9b, + 0x26, 0x61, 0xf6, 0x18, 0x26, 0x60, 0x65, 0x61, 0x01, 0x9e, 0xed, 0x1a, + 0xa5, 0x60, 0x01, 0x9b, 0x9e, 0x42, 0x00, 0xd9, 0x01, 0x9e, 0x32, 0x00, + 0x03, 0x99, 0x20, 0x68, 0xfd, 0xf7, 0x9d, 0xff, 0xa3, 0x68, 0x00, 0x20, + 0x9b, 0x1b, 0xa3, 0x60, 0x23, 0x68, 0x9e, 0x19, 0x26, 0x60, 0xda, 0xe7, + 0x2a, 0x00, 0x38, 0x00, 0xff, 0xf7, 0x82, 0xff, 0x06, 0x1e, 0xe0, 0xd1, + 0x21, 0x69, 0x38, 0x00, 0xfd, 0xf7, 0xa6, 0xff, 0xc7, 0xe7, 0xc0, 0x46, + 0x7f, 0xfb, 0xff, 0xff, 0xf0, 0xb5, 0x9f, 0xb0, 0x02, 0x90, 0x05, 0x93, + 0x8b, 0x89, 0x0f, 0x00, 0x16, 0x00, 0x1b, 0x06, 0x11, 0xd5, 0x0b, 0x69, + 0x00, 0x2b, 0x0e, 0xd1, 0x40, 0x21, 0xfd, 0xf7, 0xdd, 0xff, 0x38, 0x60, + 0x38, 0x61, 0x00, 0x28, 0x05, 0xd1, 0x0c, 0x23, 0x02, 0x9a, 0x01, 0x38, + 0x13, 0x60, 0x1f, 0xb0, 0xf0, 0xbd, 0x40, 0x23, 0x7b, 0x61, 0x00, 0x23, + 0x06, 0xac, 0x63, 0x61, 0x20, 0x33, 0x63, 0x76, 0x10, 0x33, 0xa3, 0x76, + 0x35, 0x00, 0x2b, 0x78, 0x00, 0x2b, 0x01, 0xd0, 0x25, 0x2b, 0x46, 0xd1, + 0xab, 0x1b, 0x04, 0x93, 0x0c, 0xd0, 0x32, 0x00, 0x39, 0x00, 0x02, 0x98, + 0xff, 0xf7, 0x6e, 0xff, 0x43, 0x1c, 0x00, 0xd1, 0xae, 0xe0, 0x62, 0x69, + 0x04, 0x9b, 0x94, 0x46, 0x63, 0x44, 0x63, 0x61, 0x2b, 0x78, 0x00, 0x2b, + 0x00, 0xd1, 0xa5, 0xe0, 0x01, 0x22, 0x00, 0x23, 0x52, 0x42, 0x62, 0x60, + 0x02, 0xa9, 0x54, 0x32, 0x52, 0x18, 0x6e, 0x1c, 0x23, 0x60, 0xe3, 0x60, + 0xa3, 0x60, 0x13, 0x70, 0xa3, 0x65, 0x31, 0x78, 0x05, 0x22, 0x54, 0x48, + 0xff, 0xf7, 0x28, 0xfc, 0x75, 0x1c, 0x00, 0x28, 0x1f, 0xd1, 0x22, 0x68, + 0xd3, 0x06, 0x04, 0xd5, 0x53, 0x23, 0x02, 0xa9, 0x5b, 0x18, 0x20, 0x21, + 0x19, 0x70, 0x13, 0x07, 0x04, 0xd5, 0x53, 0x23, 0x02, 0xa9, 0x5b, 0x18, + 0x2b, 0x21, 0x19, 0x70, 0x33, 0x78, 0x2a, 0x2b, 0x16, 0xd0, 0x35, 0x00, + 0x00, 0x21, 0x0a, 0x20, 0xe3, 0x68, 0x2a, 0x78, 0x6e, 0x1c, 0x30, 0x3a, + 0x09, 0x2a, 0x4e, 0xd9, 0x00, 0x29, 0x18, 0xd0, 0x10, 0xe0, 0x01, 0x35, + 0xb1, 0xe7, 0x41, 0x4b, 0x22, 0x68, 0xc0, 0x1a, 0x01, 0x23, 0x83, 0x40, + 0x13, 0x43, 0x23, 0x60, 0x2e, 0x00, 0xce, 0xe7, 0x05, 0x9b, 0x19, 0x1d, + 0x1b, 0x68, 0x05, 0x91, 0x00, 0x2b, 0x01, 0xdb, 0x09, 0x93, 0x04, 0xe0, + 0x5b, 0x42, 0xe3, 0x60, 0x02, 0x23, 0x13, 0x43, 0x23, 0x60, 0x2b, 0x78, + 0x2e, 0x2b, 0x0a, 0xd1, 0x6b, 0x78, 0x2a, 0x2b, 0x35, 0xd1, 0x05, 0x9b, + 0x02, 0x35, 0x1a, 0x1d, 0x1b, 0x68, 0x05, 0x92, 0x00, 0x2b, 0x2b, 0xdb, + 0x07, 0x93, 0x30, 0x4e, 0x29, 0x78, 0x03, 0x22, 0x30, 0x00, 0xff, 0xf7, + 0xdb, 0xfb, 0x00, 0x28, 0x06, 0xd0, 0x40, 0x23, 0x80, 0x1b, 0x83, 0x40, + 0x22, 0x68, 0x01, 0x35, 0x13, 0x43, 0x23, 0x60, 0x29, 0x78, 0x06, 0x22, + 0x28, 0x48, 0x6e, 0x1c, 0x21, 0x76, 0xff, 0xf7, 0xcb, 0xfb, 0x00, 0x28, + 0x3c, 0xd0, 0x26, 0x4b, 0x00, 0x2b, 0x25, 0xd1, 0x07, 0x22, 0x05, 0x9b, + 0x07, 0x33, 0x93, 0x43, 0x08, 0x33, 0x05, 0x93, 0x63, 0x69, 0x03, 0x9a, + 0x9b, 0x18, 0x63, 0x61, 0x66, 0xe7, 0x43, 0x43, 0x01, 0x21, 0x9b, 0x18, + 0x35, 0x00, 0xa6, 0xe7, 0x01, 0x23, 0x5b, 0x42, 0xd0, 0xe7, 0x00, 0x23, + 0x0a, 0x20, 0x1a, 0x00, 0x01, 0x35, 0x63, 0x60, 0x29, 0x78, 0x6e, 0x1c, + 0x30, 0x39, 0x09, 0x29, 0x03, 0xd9, 0x00, 0x2b, 0xc5, 0xd0, 0x07, 0x92, + 0xc3, 0xe7, 0x42, 0x43, 0x01, 0x23, 0x52, 0x18, 0x35, 0x00, 0xf1, 0xe7, + 0x05, 0xab, 0x00, 0x93, 0x3a, 0x00, 0x11, 0x4b, 0x21, 0x00, 0x02, 0x98, + 0xfe, 0xf7, 0x08, 0xf8, 0x03, 0x90, 0x03, 0x9b, 0x01, 0x33, 0xd3, 0xd1, + 0xbb, 0x89, 0x0b, 0x98, 0x5b, 0x06, 0x00, 0xd4, 0x2f, 0xe7, 0x01, 0x20, + 0x40, 0x42, 0x2c, 0xe7, 0x05, 0xab, 0x00, 0x93, 0x3a, 0x00, 0x07, 0x4b, + 0x21, 0x00, 0x02, 0x98, 0xfe, 0xf7, 0xae, 0xfa, 0xea, 0xe7, 0xc0, 0x46, + 0x84, 0x9a, 0x00, 0x00, 0x8a, 0x9a, 0x00, 0x00, 0x8e, 0x9a, 0x00, 0x00, + 0x39, 0x6c, 0x00, 0x00, 0xa9, 0x89, 0x00, 0x00, 0x0b, 0x1f, 0x1b, 0x68, + 0x18, 0x1f, 0x00, 0x2b, 0x01, 0xda, 0x0b, 0x58, 0xc0, 0x18, 0x70, 0x47, + 0x70, 0xb5, 0x00, 0x28, 0x2d, 0xd0, 0xc3, 0x17, 0xc5, 0x18, 0x5d, 0x40, + 0xc4, 0x0f, 0x28, 0x00, 0xfd, 0xf7, 0xd8, 0xfd, 0x15, 0x4b, 0x1b, 0x1a, + 0x5b, 0x05, 0x5b, 0x0d, 0x0a, 0x28, 0x15, 0xdd, 0x0b, 0x38, 0x85, 0x40, + 0x00, 0x22, 0x2d, 0x03, 0x2d, 0x0b, 0x00, 0x21, 0x10, 0x00, 0x2d, 0x03, + 0x0a, 0x0d, 0x2d, 0x0b, 0x12, 0x05, 0x2a, 0x43, 0x0d, 0x4d, 0x1b, 0x05, + 0x2a, 0x40, 0x13, 0x43, 0x5b, 0x00, 0xe4, 0x07, 0x5b, 0x08, 0x23, 0x43, + 0x19, 0x00, 0x70, 0xbd, 0x02, 0x00, 0x29, 0x00, 0x15, 0x32, 0x91, 0x40, + 0x0a, 0x00, 0x0b, 0x21, 0x08, 0x1a, 0xc5, 0x40, 0x2d, 0x03, 0x2d, 0x0b, + 0xe3, 0xe7, 0x00, 0x24, 0x00, 0x23, 0x00, 0x25, 0x00, 0x22, 0xde, 0xe7, + 0x1e, 0x04, 0x00, 0x00, 0xff, 0xff, 0x0f, 0x80, 0x04, 0x4a, 0x13, 0x68, + 0x00, 0x2b, 0x00, 0xd1, 0x03, 0x4b, 0x18, 0x18, 0x10, 0x60, 0x18, 0x00, + 0x70, 0x47, 0xc0, 0x46, 0x74, 0x26, 0x00, 0x20, 0x7c, 0x26, 0x00, 0x20, + 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, + 0xf8, 0xb5, 0xc0, 0x46, 0xf8, 0xbc, 0x08, 0xbc, 0x9e, 0x46, 0x70, 0x47, + 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x2e, 0x4f, 0x4b, 0x00, 0x55, 0x50, + 0x44, 0x41, 0x54, 0x45, 0x2e, 0x42, 0x49, 0x4e, 0x2e, 0x4c, 0x5a, 0x53, + 0x53, 0x00, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x2e, 0x42, 0x49, 0x4e, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x20, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, + 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, + 0x41, 0x54, 0x2b, 0x55, 0x44, 0x45, 0x4c, 0x46, 0x49, 0x4c, 0x45, 0x3d, + 0x22, 0x25, 0x73, 0x22, 0x00, 0x41, 0x54, 0x2b, 0x55, 0x4c, 0x53, 0x54, + 0x46, 0x49, 0x4c, 0x45, 0x3d, 0x30, 0x00, 0x41, 0x54, 0x2b, 0x43, 0x4d, + 0x45, 0x45, 0x3d, 0x32, 0x00, 0x41, 0x54, 0x2b, 0x55, 0x52, 0x44, 0x42, + 0x4c, 0x4f, 0x43, 0x4b, 0x3d, 0x22, 0x25, 0x73, 0x22, 0x2c, 0x25, 0x64, + 0x2c, 0x25, 0x64, 0x00, 0x41, 0x54, 0x2b, 0x55, 0x4c, 0x53, 0x54, 0x46, + 0x49, 0x4c, 0x45, 0x3d, 0x32, 0x2c, 0x22, 0x25, 0x73, 0x22, 0x00, 0x41, + 0x54, 0x00, 0x4f, 0x4b, 0x0d, 0x0a, 0x00, 0x45, 0x52, 0x52, 0x4f, 0x52, + 0x0d, 0x0a, 0x00, 0x4e, 0x4f, 0x20, 0x43, 0x41, 0x52, 0x52, 0x49, 0x45, + 0x52, 0x0d, 0x0a, 0x00, 0x41, 0x54, 0x2b, 0x49, 0x50, 0x52, 0x3d, 0x25, + 0x6c, 0x64, 0x00, 0x41, 0x54, 0x2b, 0x55, 0x50, 0x53, 0x56, 0x3d, 0x33, + 0x00, 0x41, 0x54, 0x2b, 0x43, 0x46, 0x55, 0x4e, 0x3d, 0x31, 0x36, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe1, 0x2e, 0x00, 0x00, + 0x05, 0x2f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x04, + 0x00, 0x04, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x01, + 0x00, 0x01, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x13, 0x00, 0x01, 0x01, + 0x01, 0x01, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x05, + 0x00, 0x05, 0x0a, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x05, + 0x01, 0x05, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x02, 0x00, + 0x02, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x03, 0x00, + 0x03, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x02, + 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x13, 0x00, 0x00, 0x00, + 0x02, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xff, 0x00, 0x01, 0x03, + 0x01, 0x03, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x10, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x11, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x16, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0a, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0b, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x05, 0x00, 0x01, 0x00, + 0x01, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x06, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x07, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1b, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0x0f, 0x00, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x02, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x01, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, + 0x01, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x03, 0x00, 0x01, 0x04, + 0x01, 0x04, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xfd, 0x2f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xef, 0x33, 0x00, 0x00, 0x25, 0x36, 0x00, 0x00, 0xeb, 0x33, 0x00, 0x00, + 0x09, 0x36, 0x00, 0x00, 0xe9, 0x35, 0x00, 0x00, 0x61, 0x36, 0x00, 0x00, + 0x45, 0x36, 0x00, 0x00, 0x17, 0x36, 0x00, 0x00, 0x05, 0x34, 0x00, 0x00, + 0x6d, 0x33, 0x00, 0x00, 0x31, 0x35, 0x00, 0x00, 0x95, 0x33, 0x00, 0x00, + 0xe9, 0x33, 0x00, 0x00, 0xf0, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, + 0xd9, 0x35, 0x00, 0x00, 0x21, 0x35, 0x00, 0x00, 0x87, 0x36, 0x00, 0x00, + 0x85, 0x36, 0x00, 0x00, 0xd9, 0x33, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x05, 0x3f, 0x00, 0x00, 0x5d, 0x30, 0x00, 0x00, + 0x2b, 0x3e, 0x00, 0x00, 0xe7, 0x3d, 0x00, 0x00, 0x01, 0x3e, 0x00, 0x00, + 0xb9, 0x3f, 0x00, 0x00, 0x41, 0x3b, 0x00, 0x00, 0x31, 0x3b, 0x00, 0x00, + 0xc5, 0x3b, 0x00, 0x00, 0x5b, 0x3b, 0x00, 0x00, 0x2d, 0x3b, 0x00, 0x00, + 0x50, 0x56, 0x00, 0x00, 0xc2, 0x54, 0x00, 0x00, 0x06, 0x55, 0x00, 0x00, + 0x6a, 0x54, 0x00, 0x00, 0x06, 0x55, 0x00, 0x00, 0xf6, 0x55, 0x00, 0x00, + 0x06, 0x55, 0x00, 0x00, 0x6a, 0x54, 0x00, 0x00, 0xc2, 0x54, 0x00, 0x00, + 0xc2, 0x54, 0x00, 0x00, 0xf6, 0x55, 0x00, 0x00, 0x6a, 0x54, 0x00, 0x00, + 0x62, 0x54, 0x00, 0x00, 0x62, 0x54, 0x00, 0x00, 0x62, 0x54, 0x00, 0x00, + 0x04, 0x56, 0x00, 0x00, 0x78, 0x5d, 0x00, 0x00, 0x7a, 0x5c, 0x00, 0x00, + 0x7a, 0x5c, 0x00, 0x00, 0x98, 0x5f, 0x00, 0x00, 0x74, 0x5c, 0x00, 0x00, + 0x74, 0x5c, 0x00, 0x00, 0x80, 0x5f, 0x00, 0x00, 0x98, 0x5f, 0x00, 0x00, + 0x74, 0x5c, 0x00, 0x00, 0x80, 0x5f, 0x00, 0x00, 0x74, 0x5c, 0x00, 0x00, + 0x98, 0x5f, 0x00, 0x00, 0x8e, 0x5f, 0x00, 0x00, 0x8e, 0x5f, 0x00, 0x00, + 0x8e, 0x5f, 0x00, 0x00, 0x9c, 0x5f, 0x00, 0x00, 0x43, 0x00, 0x50, 0x4f, + 0x53, 0x49, 0x58, 0x00, 0x2e, 0x00, 0x49, 0x4e, 0x46, 0x00, 0x69, 0x6e, + 0x66, 0x00, 0x4e, 0x41, 0x4e, 0x00, 0x6e, 0x61, 0x6e, 0x00, 0x30, 0x31, + 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x41, 0x42, 0x43, 0x44, + 0x45, 0x46, 0x00, 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, + 0x39, 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, 0x00, 0x00, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x28, 0x28, 0x28, 0x28, 0x28, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x88, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, + 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x04, 0x04, 0x04, + 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x04, 0x10, 0x10, 0x10, 0x10, 0x10, + 0x10, 0x10, 0x41, 0x41, 0x41, 0x41, 0x41, 0x41, 0x01, 0x01, 0x01, 0x01, + 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, + 0x01, 0x01, 0x01, 0x01, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x42, 0x42, + 0x42, 0x42, 0x42, 0x42, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, + 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, + 0x10, 0x10, 0x10, 0x10, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x49, 0x6e, 0x66, 0x69, 0x6e, 0x69, 0x74, 0x79, 0x00, 0x4e, 0x61, + 0x4e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xe0, 0x37, + 0x79, 0xc3, 0x41, 0x43, 0x17, 0x6e, 0x05, 0xb5, 0xb5, 0xb8, 0x93, 0x46, + 0xf5, 0xf9, 0x3f, 0xe9, 0x03, 0x4f, 0x38, 0x4d, 0x32, 0x1d, 0x30, 0xf9, + 0x48, 0x77, 0x82, 0x5a, 0x3c, 0xbf, 0x73, 0x7f, 0xdd, 0x4f, 0x15, 0x75, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x3f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x24, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x59, 0x40, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x8f, 0x40, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x88, 0xc3, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x6a, 0xf8, 0x40, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x84, 0x2e, 0x41, 0x00, 0x00, 0x00, 0x00, + 0xd0, 0x12, 0x63, 0x41, 0x00, 0x00, 0x00, 0x00, 0x84, 0xd7, 0x97, 0x41, + 0x00, 0x00, 0x00, 0x00, 0x65, 0xcd, 0xcd, 0x41, 0x00, 0x00, 0x00, 0x20, + 0x5f, 0xa0, 0x02, 0x42, 0x00, 0x00, 0x00, 0xe8, 0x76, 0x48, 0x37, 0x42, + 0x00, 0x00, 0x00, 0xa2, 0x94, 0x1a, 0x6d, 0x42, 0x00, 0x00, 0x40, 0xe5, + 0x9c, 0x30, 0xa2, 0x42, 0x00, 0x00, 0x90, 0x1e, 0xc4, 0xbc, 0xd6, 0x42, + 0x00, 0x00, 0x34, 0x26, 0xf5, 0x6b, 0x0c, 0x43, 0x00, 0x80, 0xe0, 0x37, + 0x79, 0xc3, 0x41, 0x43, 0x00, 0xa0, 0xd8, 0x85, 0x57, 0x34, 0x76, 0x43, + 0x00, 0xc8, 0x4e, 0x67, 0x6d, 0xc1, 0xab, 0x43, 0x00, 0x3d, 0x91, 0x60, + 0xe4, 0x58, 0xe1, 0x43, 0x40, 0x8c, 0xb5, 0x78, 0x1d, 0xaf, 0x15, 0x44, + 0x50, 0xef, 0xe2, 0xd6, 0xe4, 0x1a, 0x4b, 0x44, 0x92, 0xd5, 0x4d, 0x06, + 0xcf, 0xf0, 0x80, 0x44, 0xf6, 0x4a, 0xe1, 0xc7, 0x02, 0x2d, 0xb5, 0x44, + 0xb4, 0x9d, 0xd9, 0x79, 0x43, 0x78, 0xea, 0x44, 0x05, 0x00, 0x00, 0x00, + 0x19, 0x00, 0x00, 0x00, 0x7d, 0x00, 0x00, 0x00, 0x23, 0x2d, 0x30, 0x2b, + 0x20, 0x00, 0x68, 0x6c, 0x4c, 0x00, 0x65, 0x66, 0x67, 0x45, 0x46, 0x47, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x3a, 0x8d, 0x00, 0x00, 0x2a, 0x8d, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, + 0xff, 0xff, 0xff, 0xff, 0x00, 0xc2, 0x01, 0x00, 0x00, 0x00, 0x08, 0x00, + 0xff, 0xff, 0xff, 0xff, 0x40, 0x42, 0x0f, 0x00, 0xff, 0xff, 0xff, 0xff, + 0x2c, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0xb8, 0x9a, 0x00, 0x00, + 0xd8, 0x9a, 0x00, 0x00, 0x98, 0x9a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x5d, 0x76, 0x00, 0x00, 0x45, 0x69, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x74, 0x98, 0x00, 0x00, 0x40, 0x98, 0x00, 0x00, 0x7a, 0x93, 0x00, 0x00, + 0x7a, 0x93, 0x00, 0x00, 0x7a, 0x93, 0x00, 0x00, 0x7a, 0x93, 0x00, 0x00, + 0x7a, 0x93, 0x00, 0x00, 0x7a, 0x93, 0x00, 0x00, 0x7a, 0x93, 0x00, 0x00, + 0x7a, 0x93, 0x00, 0x00, 0x7a, 0x93, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, + 0x01, 0x00, 0x41, 0x53, 0x43, 0x49, 0x49, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x41, 0x53, + 0x43, 0x49, 0x49, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xdd, 0x20, 0x00, 0x00, + 0x21, 0x23, 0x00, 0x00, 0x6d, 0x25, 0x00, 0x00, 0x85, 0x25, 0x00, 0x00, + 0xa5, 0x26, 0x00, 0x00, 0xbd, 0x26, 0x00, 0x00, 0xf9, 0x29, 0x00, 0x00, + 0x11, 0x2a, 0x00, 0x00, 0x29, 0x2a, 0x00, 0x00, 0x75, 0x2e, 0x00, 0x00, + 0x19, 0x2f, 0x00, 0x00, 0x5d, 0x2f, 0x00, 0x00, 0xdd, 0x36, 0x00, 0x00, + 0x1d, 0x3b, 0x00, 0x00, 0xb5, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 diff --git a/libraries/USBHost/examples/ADKTerminalTest/ADKTerminalTest.ino b/libraries/USBHost/examples/ADKTerminalTest/ADKTerminalTest.ino new file mode 100644 index 0000000..ea7509c --- /dev/null +++ b/libraries/USBHost/examples/ADKTerminalTest/ADKTerminalTest.ino @@ -0,0 +1,75 @@ +/* + Copyright (c) 2012 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 +*/ + +#define ARDUINO_MAIN +//#include "variant.h" +#include "Arduino.h" +#include +#include + + +USBHost usb; +ADK adk(&usb,"Arduino SA", + "Arduino_Terminal", + "Arduino Terminal for Android", + "1.0", + "http://labs.arduino.cc/uploads/ADK/ArduinoTerminal/ThibaultTerminal_ICS_0001.apk", + "1"); + +void setup(void) +{ + SERIAL_PORT_MONITOR.begin( 115200 ); + while (!SERIAL_PORT_MONITOR); // Wait for serial port to connect - used on Leonardo, Teensy and other boards with built-in USB CDC serial connection + SERIAL_PORT_MONITOR.println("\r\nADK demo start"); + + if (usb.Init() == -1) + SERIAL_PORT_MONITOR.println("OSC did not start."); + + delay(20); +} + +#define RCVSIZE 128 + +void loop(void) +{ + uint8_t buf[RCVSIZE]; + uint32_t nbread = 0; + char helloworld[] = "Hello World!\r\n"; + + usb.Task(); + + if( adk.isReady() == false ) { + return; + } + /* Write hello string to ADK */ + adk.SndData(strlen(helloworld), (uint8_t *)helloworld); + + delay(1000); + + /* Read data from ADK and print to UART */ + adk.RcvData((uint8_t *)&nbread, buf); + if (nbread > 0) + { + SERIAL_PORT_MONITOR.print("RCV: "); + for (uint32_t i = 0; i < nbread; ++i) + { + SERIAL_PORT_MONITOR.print((char)buf[i]); + } + SERIAL_PORT_MONITOR.print("\r\n"); + } +} diff --git a/libraries/USBHost/examples/KeyboardController/KeyboardController.ino b/libraries/USBHost/examples/KeyboardController/KeyboardController.ino new file mode 100644 index 0000000..f1b6463 --- /dev/null +++ b/libraries/USBHost/examples/KeyboardController/KeyboardController.ino @@ -0,0 +1,89 @@ +/* + Keyboard Controller Example + + Shows the output of a USB Keyboard connected to + the Native USB port on an Arduino Due Board. + + created 8 Oct 2012 + by Cristian Maglie + + https://www.arduino.cc/en/Tutorial/KeyboardController + + This sample code is part of the public domain. + */ + +// Require keyboard control library +#include + +// Initialize USB Controller +USBHost usb; + +// Attach keyboard controller to USB +KeyboardController keyboard(usb); + +void printKey(); + +// This function intercepts key press +void keyPressed() { + SERIAL_PORT_MONITOR.print("Pressed: "); + printKey(); +} + +// This function intercepts key release +void keyReleased() { + SERIAL_PORT_MONITOR.print("Released: "); + printKey(); +} + +void printKey() { + // getOemKey() returns the OEM-code associated with the key + SERIAL_PORT_MONITOR.print(" key:"); + SERIAL_PORT_MONITOR.print(keyboard.getOemKey()); + + // getModifiers() returns a bits field with the modifiers-keys + int mod = keyboard.getModifiers(); + SERIAL_PORT_MONITOR.print(" mod:"); + SERIAL_PORT_MONITOR.print(mod); + + SERIAL_PORT_MONITOR.print(" => "); + + if (mod & LeftCtrl) + SERIAL_PORT_MONITOR.print("L-Ctrl "); + if (mod & LeftShift) + SERIAL_PORT_MONITOR.print("L-Shift "); + if (mod & Alt) + SERIAL_PORT_MONITOR.print("Alt "); + if (mod & LeftCmd) + SERIAL_PORT_MONITOR.print("L-Cmd "); + if (mod & RightCtrl) + SERIAL_PORT_MONITOR.print("R-Ctrl "); + if (mod & RightShift) + SERIAL_PORT_MONITOR.print("R-Shift "); + if (mod & AltGr) + SERIAL_PORT_MONITOR.print("AltGr "); + if (mod & RightCmd) + SERIAL_PORT_MONITOR.print("R-Cmd "); + + // getKey() returns the ASCII translation of OEM key + // combined with modifiers. + SERIAL_PORT_MONITOR.write(keyboard.getKey()); + SERIAL_PORT_MONITOR.println(); +} + +void setup() +{ + SERIAL_PORT_MONITOR.begin( 115200 ); + while (!SERIAL_PORT_MONITOR); // Wait for serial port to connect - used on Leonardo, Teensy and other boards with built-in USB CDC serial connection + SERIAL_PORT_MONITOR.println("Keyboard Controller Program started"); + + if (usb.Init() == -1) + SERIAL_PORT_MONITOR.println("OSC did not start."); + + delay( 20 ); +} + +void loop() +{ + // Process USB tasks + usb.Task(); +} diff --git a/libraries/USBHost/examples/MouseController/MouseController.ino b/libraries/USBHost/examples/MouseController/MouseController.ino new file mode 100644 index 0000000..fd02d3e --- /dev/null +++ b/libraries/USBHost/examples/MouseController/MouseController.ino @@ -0,0 +1,97 @@ +/* + Mouse Controller Example + + Shows the output of a USB Mouse connected to + the Native USB port on an Arduino Due Board. + + created 8 Oct 2012 + by Cristian Maglie + + https://www.arduino.cc/en/Tutorial/MouseController + + This sample code is part of the public domain. + */ + +// Require mouse control library +#include + +// Initialize USB Controller +USBHost usb; + +// Attach mouse controller to USB +MouseController mouse(usb); + +// variables for mouse button states +bool leftButton = false; +bool middleButton = false; +bool rightButton = false; + +// This function intercepts mouse movements +void mouseMoved() { + SERIAL_PORT_MONITOR.print("Move: "); + SERIAL_PORT_MONITOR.print(mouse.getXChange()); + SERIAL_PORT_MONITOR.print(", "); + SERIAL_PORT_MONITOR.println(mouse.getYChange()); +} + +// This function intercepts mouse movements while a button is pressed +void mouseDragged() { + SERIAL_PORT_MONITOR.print("DRAG: "); + SERIAL_PORT_MONITOR.print(mouse.getXChange()); + SERIAL_PORT_MONITOR.print(", "); + SERIAL_PORT_MONITOR.println(mouse.getYChange()); +} + +// This function intercepts mouse button press +void mousePressed() { + SERIAL_PORT_MONITOR.print("Pressed: "); + if (mouse.getButton(LEFT_BUTTON)) { + SERIAL_PORT_MONITOR.print("L"); + leftButton = true; + } + if (mouse.getButton(MIDDLE_BUTTON)) { + SERIAL_PORT_MONITOR.print("M"); + middleButton = true; + } + if (mouse.getButton(RIGHT_BUTTON)) { + SERIAL_PORT_MONITOR.print("R"); + rightButton = true; + } + SERIAL_PORT_MONITOR.println(); +} + +// This function intercepts mouse button release +void mouseReleased() { + SERIAL_PORT_MONITOR.print("Released: "); + if (!mouse.getButton(LEFT_BUTTON) && leftButton == true) { + SERIAL_PORT_MONITOR.print("L"); + leftButton = false; + } + if (!mouse.getButton(MIDDLE_BUTTON) && middleButton == true) { + SERIAL_PORT_MONITOR.print("M"); + middleButton = false; + } + if (!mouse.getButton(RIGHT_BUTTON) && rightButton == true) { + SERIAL_PORT_MONITOR.print("R"); + rightButton = false; + } + SERIAL_PORT_MONITOR.println(); +} + +void setup() +{ + SERIAL_PORT_MONITOR.begin( 115200 ); + while (!SERIAL_PORT_MONITOR); // Wait for serial port to connect - used on Leonardo, Teensy and other boards with built-in USB CDC serial connection + SERIAL_PORT_MONITOR.println("Mouse Controller Program started"); + + if (usb.Init() == -1) + SERIAL_PORT_MONITOR.println("OSC did not start."); + + delay( 20 ); +} + +void loop() +{ + // Process USB tasks + usb.Task(); +} diff --git a/libraries/USBHost/examples/USB_desc/USB_desc.ino b/libraries/USBHost/examples/USB_desc/USB_desc.ino new file mode 100644 index 0000000..de9ab09 --- /dev/null +++ b/libraries/USBHost/examples/USB_desc/USB_desc.ino @@ -0,0 +1,389 @@ + + +#include "Arduino.h" +#include +#include "pgmstrings.h" +// Satisfy IDE, which only needs to see the include statment in the ino. +#ifdef dobogusinclude +#include +#endif + +USBHost usb; +//USBHub Hub1(&Usb); +//USBHub Hub2(&Usb); +//USBHub Hub3(&Usb); +//USBHub Hub4(&Usb); +//USBHub Hub5(&Usb); +//USBHub Hub6(&Usb); +//USBHub Hub7(&Usb); + +uint32_t next_time; + +void print_hex(int v, int num_places); +void printintfdescr( uint8_t* descr_ptr ); +byte getconfdescr( byte addr, byte conf ); +void printconfdescr( uint8_t* descr_ptr ); +void printunkdescr( uint8_t* descr_ptr ); +void printepdescr( uint8_t* descr_ptr ); +void printProgStr(const prog_char str[]); +void printHIDdescr( uint8_t* descr_ptr ); + +void PrintAllAddresses(UsbDeviceDefinition *pdev) +{ + UsbDeviceAddress adr; + adr.devAddress = pdev->address.devAddress; + SERIAL_PORT_MONITOR.print("\r\nAddr:"); + SERIAL_PORT_MONITOR.print(adr.devAddress, HEX); + SERIAL_PORT_MONITOR.print("("); + SERIAL_PORT_MONITOR.print(adr.bmHub, HEX); + SERIAL_PORT_MONITOR.print("."); + SERIAL_PORT_MONITOR.print(adr.bmParent, HEX); + SERIAL_PORT_MONITOR.print("."); + SERIAL_PORT_MONITOR.print(adr.bmAddress, HEX); + SERIAL_PORT_MONITOR.println(")"); +} + +void PrintAddress(uint8_t addr) +{ + UsbDeviceAddress adr; + adr.devAddress = addr; + SERIAL_PORT_MONITOR.print("\r\nADDR:\t"); + SERIAL_PORT_MONITOR.println(adr.devAddress,HEX); + SERIAL_PORT_MONITOR.print("DEV:\t"); + SERIAL_PORT_MONITOR.println(adr.bmAddress,HEX); + SERIAL_PORT_MONITOR.print("PRNT:\t"); + SERIAL_PORT_MONITOR.println(adr.bmParent,HEX); + SERIAL_PORT_MONITOR.print("HUB:\t"); + SERIAL_PORT_MONITOR.println(adr.bmHub,HEX); +} + +void setup() +{ + SERIAL_PORT_MONITOR.begin( 115200 ); + while (!Serial); // Wait for serial port to connect - used on Leonardo, Teensy and other boards with built-in USB CDC serial connection + SERIAL_PORT_MONITOR.println("Start USB Desc"); + + if (usb.Init() == -1) + SERIAL_PORT_MONITOR.println("OSC did not start."); + + delay( 20 ); + + next_time = millis() + 10000; +} + +byte getdevdescr( byte addr, byte &num_conf ); + +void PrintDescriptors(uint8_t addr) +{ + uint8_t rcode = 0; + byte num_conf = 0; + + rcode = getdevdescr( (byte)addr, num_conf ); + if( rcode ) + { + printProgStr(Gen_Error_str); + print_hex( rcode, 8 ); + } + SERIAL_PORT_MONITOR.print("\r\n"); + + for (int i=0; iaddress.devAddress, 8); + SERIAL_PORT_MONITOR.println("\r\n--"); + PrintDescriptors( pdev->address.devAddress ); +} + +void loop() +{ + usb.Task(); + + if( usb.getUsbTaskState() == USB_STATE_RUNNING ) + { + //if (millis() >= next_time) + { + usb.ForEachUsbDevice(&PrintAllDescriptors); + usb.ForEachUsbDevice(&PrintAllAddresses); + + while( 1 ); //stop + } + } +} + +byte getdevdescr( byte addr, byte &num_conf ) +{ + USB_DEVICE_DESCRIPTOR buf; + byte rcode; + rcode = usb.getDevDescr( addr, 0, 0x12, ( uint8_t *)&buf ); + if( rcode ) { + return( rcode ); + } + printProgStr(Dev_Header_str); + printProgStr(Dev_Length_str); + print_hex( buf.bLength, 8 ); + printProgStr(Dev_Type_str); + print_hex( buf.bDescriptorType, 8 ); + printProgStr(Dev_Version_str); + print_hex( buf.bcdUSB, 16 ); + printProgStr(Dev_Class_str); + print_hex( buf.bDeviceClass, 8 ); + printProgStr(Dev_Subclass_str); + print_hex( buf.bDeviceSubClass, 8 ); + printProgStr(Dev_Protocol_str); + print_hex( buf.bDeviceProtocol, 8 ); + printProgStr(Dev_Pktsize_str); + print_hex( buf.bMaxPacketSize0, 8 ); + printProgStr(Dev_Vendor_str); + print_hex( buf.idVendor, 16 ); + printProgStr(Dev_Product_str); + print_hex( buf.idProduct, 16 ); + printProgStr(Dev_Revision_str); + print_hex( buf.bcdDevice, 16 ); + printProgStr(Dev_Mfg_str); + print_hex( buf.iManufacturer, 8 ); + printProgStr(Dev_Prod_str); + print_hex( buf.iProduct, 8 ); + printProgStr(Dev_Serial_str); + print_hex( buf.iSerialNumber, 8 ); + printProgStr(Dev_Nconf_str); + print_hex( buf.bNumConfigurations, 8 ); + num_conf = buf.bNumConfigurations; + return( 0 ); +} + +void printhubdescr(uint8_t *descrptr, uint8_t addr) +{ + HubDescriptor *pHub = (HubDescriptor*) descrptr; + uint8_t len = *((uint8_t*)descrptr); + + printProgStr(PSTR("\r\n\r\nHub Descriptor:\r\n")); + printProgStr(PSTR("bDescLength:\t\t")); + SERIAL_PORT_MONITOR.println(pHub->bDescLength, HEX); + + printProgStr(PSTR("bDescriptorType:\t")); + SERIAL_PORT_MONITOR.println(pHub->bDescriptorType, HEX); + + printProgStr(PSTR("bNbrPorts:\t\t")); + SERIAL_PORT_MONITOR.println(pHub->bNbrPorts, HEX); + + printProgStr(PSTR("LogPwrSwitchMode:\t")); + SERIAL_PORT_MONITOR.println(pHub->LogPwrSwitchMode, BIN); + + printProgStr(PSTR("CompoundDevice:\t\t")); + SERIAL_PORT_MONITOR.println(pHub->CompoundDevice, BIN); + + printProgStr(PSTR("OverCurrentProtectMode:\t")); + SERIAL_PORT_MONITOR.println(pHub->OverCurrentProtectMode, BIN); + + printProgStr(PSTR("TTThinkTime:\t\t")); + SERIAL_PORT_MONITOR.println(pHub->TTThinkTime, BIN); + + printProgStr(PSTR("PortIndicatorsSupported:")); + SERIAL_PORT_MONITOR.println(pHub->PortIndicatorsSupported, BIN); + + printProgStr(PSTR("Reserved:\t\t")); + SERIAL_PORT_MONITOR.println(pHub->Reserved, HEX); + + printProgStr(PSTR("bPwrOn2PwrGood:\t\t")); + SERIAL_PORT_MONITOR.println(pHub->bPwrOn2PwrGood, HEX); + + printProgStr(PSTR("bHubContrCurrent:\t")); + SERIAL_PORT_MONITOR.println(pHub->bHubContrCurrent, HEX); + + for (uint8_t i=7; ibNbrPorts; i++) + // PrintHubPortStatus(&Usb, addr, i, 1); +} + +byte getconfdescr( byte addr, byte conf ) +{ + uint8_t buf[ BUFSIZE ]; + uint8_t* buf_ptr = buf; + byte rcode; + byte descr_length; + byte descr_type; + uint16_t total_length; + rcode = usb.getConfDescr( addr, 0, 4, conf, buf ); //get total length + LOBYTE( total_length ) = buf[ 2 ]; + HIBYTE( total_length ) = buf[ 3 ]; + if( total_length > sizeof(buf)) { //check if total length is larger than buffer + printProgStr(Conf_Trunc_str); + total_length = sizeof(buf); + } + rcode = usb.getConfDescr( addr, 0, total_length, conf, buf ); //get the whole descriptor + while( buf_ptr < buf + total_length ) { //parsing descriptors + descr_length = *( buf_ptr ); + descr_type = *( buf_ptr + 1 ); + switch( descr_type ) { + case( USB_DESCRIPTOR_CONFIGURATION ): + printconfdescr( buf_ptr ); + break; + case( USB_DESCRIPTOR_INTERFACE ): + printintfdescr( buf_ptr ); + break; + case( USB_DESCRIPTOR_ENDPOINT ): + printepdescr( buf_ptr ); + break; + case 0x21: // HID Descriptor + printHIDdescr( buf_ptr ); + break; + case 0x29: + printhubdescr( buf_ptr, addr ); + break; + default: + printunkdescr( buf_ptr ); + break; + }//switch( descr_type + buf_ptr = ( buf_ptr + descr_length ); //advance buffer pointer + }//while( buf_ptr <=... + return( 0 ); +} +/* prints hex numbers with leading zeroes */ +// copyright, Peter H Anderson, Baltimore, MD, Nov, '07 +// source: http://www.phanderson.com/arduino/arduino_display.html +void print_hex(int v, int num_places) +{ + int mask=0, n, num_nibbles, digit; + + for (n=1; n<=num_places; n++) { + mask = (mask << 1) | 0x0001; + } + v = v & mask; // truncate v to specified number of places + + num_nibbles = num_places / 4; + if ((num_places % 4) != 0) { + ++num_nibbles; + } + do { + digit = ((v >> (num_nibbles-1) * 4)) & 0x0f; + SERIAL_PORT_MONITOR.print(digit, HEX); + } + while(--num_nibbles); +} +/* function to print configuration descriptor */ +void printconfdescr( uint8_t* descr_ptr ) +{ + USB_CONFIGURATION_DESCRIPTOR* conf_ptr = ( USB_CONFIGURATION_DESCRIPTOR* )descr_ptr; + printProgStr(Conf_Header_str); + printProgStr(Conf_Totlen_str); + print_hex( conf_ptr->wTotalLength, 16 ); + printProgStr(Conf_Nint_str); + print_hex( conf_ptr->bNumInterfaces, 8 ); + printProgStr(Conf_Value_str); + print_hex( conf_ptr->bConfigurationValue, 8 ); + printProgStr(Conf_String_str); + print_hex( conf_ptr->iConfiguration, 8 ); + printProgStr(Conf_Attr_str); + print_hex( conf_ptr->bmAttributes, 8 ); + printProgStr(Conf_Pwr_str); + print_hex( conf_ptr->bMaxPower, 8 ); + return; +} +/* function to print interface descriptor */ +void printintfdescr( uint8_t* descr_ptr ) +{ + USB_INTERFACE_DESCRIPTOR* intf_ptr = ( USB_INTERFACE_DESCRIPTOR* )descr_ptr; + printProgStr(Int_Header_str); + printProgStr(Int_Number_str); + print_hex( intf_ptr->bInterfaceNumber, 8 ); + printProgStr(Int_Alt_str); + print_hex( intf_ptr->bAlternateSetting, 8 ); + printProgStr(Int_Endpoints_str); + print_hex( intf_ptr->bNumEndpoints, 8 ); + printProgStr(Int_Class_str); + print_hex( intf_ptr->bInterfaceClass, 8 ); + printProgStr(Int_Subclass_str); + print_hex( intf_ptr->bInterfaceSubClass, 8 ); + printProgStr(Int_Protocol_str); + print_hex( intf_ptr->bInterfaceProtocol, 8 ); + printProgStr(Int_String_str); + print_hex( intf_ptr->iInterface, 8 ); + return; +} + +/* function to print HID descriptor */ +void printHIDdescr( uint8_t* descr_ptr ) +{ + USB_HID_DESCRIPTOR* ep_ptr = ( USB_HID_DESCRIPTOR* )descr_ptr; + + printProgStr(PSTR("\r\n\r\nHID Descriptor:\r\n")); + printProgStr(PSTR("HID Class Release:\t")); + print_hex( ep_ptr->bcdHID, 16 ); + printProgStr(PSTR("\r\nCountry Code:\t\t")); + print_hex( ep_ptr->bCountryCode, 8 ); + printProgStr(PSTR("\r\nNumb Class Descriptor:\t")); + print_hex( ep_ptr->bNumDescriptors, 8 ); + printProgStr(PSTR("\r\nDescriptor Type:\t")); + if( ep_ptr->bDescrType == 0x22 ) + printProgStr(PSTR("REPORT DESCRIPTOR")); + else + print_hex( ep_ptr->bDescrType, 8 ); + printProgStr(PSTR("\r\nCSize Report Descr:\t")); + print_hex( ep_ptr->wDescriptorLength, 16 ); +} + +/* function to print endpoint descriptor */ +void printepdescr( uint8_t* descr_ptr ) +{ + uint8_t transfer_type; + + USB_ENDPOINT_DESCRIPTOR* ep_ptr = ( USB_ENDPOINT_DESCRIPTOR* )descr_ptr; + printProgStr(End_Header_str); + printProgStr(End_Address_str); + if( 0x80 & ep_ptr->bEndpointAddress ) printProgStr(PSTR("IN\t\t")); + else printProgStr(PSTR("OUT\t\t")); + print_hex( (ep_ptr->bEndpointAddress & 0xF), 8 ); + printProgStr(End_Attr_str); + transfer_type = ep_ptr->bmAttributes & bmUSB_TRANSFER_TYPE; + if( transfer_type == USB_TRANSFER_TYPE_INTERRUPT ) printProgStr(PSTR("INTERRUPT\t")); + else if( transfer_type == USB_TRANSFER_TYPE_BULK ) printProgStr(PSTR("BULK\t")); + else if( transfer_type == USB_TRANSFER_TYPE_ISOCHRONOUS ) printProgStr(PSTR("ISO\t")); + print_hex( ep_ptr->bmAttributes, 8 ); + printProgStr(End_Pktsize_str); + print_hex( ep_ptr->wMaxPacketSize, 16 ); + printProgStr(End_Interval_str); + print_hex( ep_ptr->bInterval, 8 ); + + return; +} +/*function to print unknown descriptor */ +void printunkdescr( uint8_t* descr_ptr ) +{ + byte length = *descr_ptr; + byte i; + printProgStr(Unk_Header_str); + printProgStr(Unk_Length_str); + print_hex( *descr_ptr, 8 ); + printProgStr(Unk_Type_str); + print_hex( *(descr_ptr + 1 ), 8 ); + printProgStr(Unk_Contents_str); + descr_ptr += 2; + for( i = 0; i < length; i++ ) { + print_hex( *descr_ptr, 8 ); + descr_ptr++; + } +} + + +/* Print a string from Program Memory directly to save RAM */ +void printProgStr(const prog_char str[]) +{ + char c; + if(!str) return; + while((c = pgm_read_byte(str++))) + SERIAL_PORT_MONITOR.print(c); +} diff --git a/libraries/USBHost/examples/USB_desc/pgmstrings.h b/libraries/USBHost/examples/USB_desc/pgmstrings.h new file mode 100644 index 0000000..bdb0077 --- /dev/null +++ b/libraries/USBHost/examples/USB_desc/pgmstrings.h @@ -0,0 +1,52 @@ +#if !defined(__PGMSTRINGS_H__) +#define __PGMSTRINGS_H__ + +#define LOBYTE(x) ((char*)(&(x)))[0] +#define HIBYTE(x) ((char*)(&(x)))[1] +#define BUFSIZE 256 //buffer size + + +/* Print strings in Program Memory */ +const char Gen_Error_str[] PROGMEM = "\r\nRequest error. Error code:\t"; +const char Dev_Header_str[] PROGMEM ="\r\nDevice descriptor: "; +const char Dev_Length_str[] PROGMEM ="\r\nDescriptor Length:\t"; +const char Dev_Type_str[] PROGMEM ="\r\nDescriptor type:\t"; +const char Dev_Version_str[] PROGMEM ="\r\nUSB version:\t\t"; +const char Dev_Class_str[] PROGMEM ="\r\nDevice class:\t\t"; +const char Dev_Subclass_str[] PROGMEM ="\r\nDevice Subclass:\t"; +const char Dev_Protocol_str[] PROGMEM ="\r\nDevice Protocol:\t"; +const char Dev_Pktsize_str[] PROGMEM ="\r\nMax.packet size:\t"; +const char Dev_Vendor_str[] PROGMEM ="\r\nVendor ID:\t\t"; +const char Dev_Product_str[] PROGMEM ="\r\nProduct ID:\t\t"; +const char Dev_Revision_str[] PROGMEM ="\r\nRevision ID:\t\t"; +const char Dev_Mfg_str[] PROGMEM ="\r\nMfg.string index:\t"; +const char Dev_Prod_str[] PROGMEM ="\r\nProd.string index:\t"; +const char Dev_Serial_str[] PROGMEM ="\r\nSerial number index:\t"; +const char Dev_Nconf_str[] PROGMEM ="\r\nNumber of conf.:\t"; +const char Conf_Trunc_str[] PROGMEM ="Total length truncated to 256 bytes"; +const char Conf_Header_str[] PROGMEM ="\r\nConfiguration descriptor:"; +const char Conf_Totlen_str[] PROGMEM ="\r\nTotal length:\t\t"; +const char Conf_Nint_str[] PROGMEM ="\r\nNum.intf:\t\t"; +const char Conf_Value_str[] PROGMEM ="\r\nConf.value:\t\t"; +const char Conf_String_str[] PROGMEM ="\r\nConf.string:\t\t"; +const char Conf_Attr_str[] PROGMEM ="\r\nAttr.:\t\t\t"; +const char Conf_Pwr_str[] PROGMEM ="\r\nMax.pwr:\t\t"; +const char Int_Header_str[] PROGMEM ="\r\n\r\nInterface descriptor:"; +const char Int_Number_str[] PROGMEM ="\r\nIntf.number:\t\t"; +const char Int_Alt_str[] PROGMEM ="\r\nAlt.:\t\t\t"; +const char Int_Endpoints_str[] PROGMEM ="\r\nEndpoints:\t\t"; +const char Int_Class_str[] PROGMEM ="\r\nIntf. Class:\t\t"; +const char Int_Subclass_str[] PROGMEM ="\r\nIntf. Subclass:\t\t"; +const char Int_Protocol_str[] PROGMEM ="\r\nIntf. Protocol:\t\t"; +const char Int_String_str[] PROGMEM ="\r\nIntf.string:\t\t"; +const char End_Header_str[] PROGMEM ="\r\n\r\nEndpoint descriptor:"; +const char End_Address_str[] PROGMEM ="\r\nEndpoint address:\t"; +const char End_Attr_str[] PROGMEM ="\r\nAttr.:\t\t\t"; +const char End_Pktsize_str[] PROGMEM ="\r\nMax.pkt size:\t\t"; +const char End_Interval_str[] PROGMEM ="\r\nPolling interval:\t"; +const char Unk_Header_str[] PROGMEM = "\r\nUnknown descriptor:"; +const char Unk_Length_str[] PROGMEM ="\r\nLength:\t\t"; +const char Unk_Type_str[] PROGMEM ="\r\nType:\t\t"; +const char Unk_Contents_str[] PROGMEM ="\r\nContents:\t"; + +#endif // __PGMSTRINGS_H__ \ No newline at end of file diff --git a/libraries/USBHost/keywords.txt b/libraries/USBHost/keywords.txt new file mode 100644 index 0000000..dded4dc --- /dev/null +++ b/libraries/USBHost/keywords.txt @@ -0,0 +1,35 @@ +####################################### +# Syntax Coloring Map For USBHost +####################################### + +####################################### +# Datatypes (KEYWORD1) +####################################### + +MouseController KEYWORD1 +USBHost KEYWORD1 +KeyboardController KEYWORD1 + +####################################### +# Methods and Functions (KEYWORD2) +####################################### + +Task KEYWORD2 +mouseMoved KEYWORD2 +mouseDragged KEYWORD2 +mousePressed KEYWORD2 +mouseReleased KEYWORD2 +getXChange KEYWORD2 +getYChange KEYWORD2 +getButton KEYWORD2 +keyPressed KEYWORD2 +keyReleased KEYWORD2 +getModifiers KEYWORD2 +getKey KEYWORD2 +getOemKey KEYWORD2 + + +####################################### +# Constants (LITERAL1) +####################################### + diff --git a/libraries/USBHost/library.properties b/libraries/USBHost/library.properties new file mode 100644 index 0000000..c1db890 --- /dev/null +++ b/libraries/USBHost/library.properties @@ -0,0 +1,9 @@ +name=USBHost +version=1.0 +author=Arduino +maintainer=Arduino +sentence=Allows the communication with USB peripherals like mice, keyboards, and thumbdrives. For Arduino MKR1000 and Zero. +paragraph=The USBHost library allows the board to appear as a USB host, enabling it to communicate with peripherals like USB mice and keyboards. USBHost does not support devices that are connected through USB hubs. This includes some keyboards that have an internal hub. +category=Other +url=https://www.arduino.cc/en/Reference/USBHost +architectures=samd diff --git a/libraries/USBHost/src/KeyboardController.cpp b/libraries/USBHost/src/KeyboardController.cpp new file mode 100644 index 0000000..70c769f --- /dev/null +++ b/libraries/USBHost/src/KeyboardController.cpp @@ -0,0 +1,40 @@ +/* + Copyright (c) 2012 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 + */ + +#include + +extern "C" { +void __keyboardControllerEmptyCallback() { } +} + +void keyPressed() __attribute__ ((weak, alias("__keyboardControllerEmptyCallback"))); +void keyReleased() __attribute__ ((weak, alias("__keyboardControllerEmptyCallback"))); + +void KeyboardController::OnKeyDown(uint8_t _mod, uint8_t _oemKey) { + modifiers = _mod; + keyOem = _oemKey; + key = OemToAscii(_mod, _oemKey); + keyPressed(); +} + +void KeyboardController::OnKeyUp(uint8_t _mod, uint8_t _oemKey) { + modifiers = _mod; + keyOem = _oemKey; + key = OemToAscii(_mod, _oemKey); + keyReleased(); +} diff --git a/libraries/USBHost/src/KeyboardController.h b/libraries/USBHost/src/KeyboardController.h new file mode 100644 index 0000000..e1b891b --- /dev/null +++ b/libraries/USBHost/src/KeyboardController.h @@ -0,0 +1,54 @@ +/* + Copyright (c) 2012 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 KEYBOARD_CONTROLLER_H +#define KEYBOARD_CONTROLLER_H + +#include + +enum KeyboardModifiers { + LeftCtrl = 1, + LeftShift = 2, + Alt = 4, + LeftCmd = 8, + RightCtrl = 16, + RightShift = 32, + AltGr = 64, + RightCmd = 128 +}; + +class KeyboardController : public KeyboardReportParser { +public: + KeyboardController(USBHost &usb) : hostKeyboard(&usb), key(0), keyOem(0), modifiers(0) { + hostKeyboard.SetReportParser(0, this); + }; + + uint8_t getKey() { return key; }; + uint8_t getModifiers() { return modifiers; }; + uint8_t getOemKey() { return keyOem; }; + +protected: + virtual void OnKeyDown(uint8_t mod, uint8_t key); + virtual void OnKeyUp(uint8_t mod, uint8_t key); + +private: + HIDBoot hostKeyboard; + uint8_t key, keyOem, modifiers; +}; + +#endif diff --git a/libraries/USBHost/src/MouseController.cpp b/libraries/USBHost/src/MouseController.cpp new file mode 100644 index 0000000..0912a03 --- /dev/null +++ b/libraries/USBHost/src/MouseController.cpp @@ -0,0 +1,83 @@ +/* + * Copyright (c) 2015 Arduino LLC. 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 + */ + +#include + +extern "C" { +void __mouseControllerEmptyCallback() { } +} + +void mouseClicked() __attribute__ ((weak, alias("__mouseControllerEmptyCallback"))); +void mouseDragged() __attribute__ ((weak, alias("__mouseControllerEmptyCallback"))); +void mouseMoved() __attribute__ ((weak, alias("__mouseControllerEmptyCallback"))); +void mousePressed() __attribute__ ((weak, alias("__mouseControllerEmptyCallback"))); +void mouseReleased() __attribute__ ((weak, alias("__mouseControllerEmptyCallback"))); + +int MouseController::getXChange() { + int r = dx; + dx = 0; + return r; +} + +int MouseController::getYChange() { + int r = dy; + dy = 0; + return r; +} + +void MouseController::OnMouseMove(MOUSEINFO *mi) { + dx += mi->dX; + dy += mi->dY; + if (buttons != 0) + mouseDragged(); + else + mouseMoved(); +} + +void MouseController::OnLeftButtonUp(MOUSEINFO * /* mi */) { + buttons &= ~LEFT_BUTTON; + mouseReleased(); + mouseClicked(); +} + +void MouseController::OnLeftButtonDown(MOUSEINFO * /* mi */) { + buttons |= LEFT_BUTTON; + mousePressed(); +} + +void MouseController::OnMiddleButtonUp(MOUSEINFO * /* mi */) { + buttons &= ~MIDDLE_BUTTON; + mouseReleased(); + mouseClicked(); +} + +void MouseController::OnMiddleButtonDown(MOUSEINFO * /* mi */) { + buttons |= MIDDLE_BUTTON; + mousePressed(); +} + +void MouseController::OnRightButtonUp(MOUSEINFO * /* mi */) { + buttons &= ~RIGHT_BUTTON; + mouseReleased(); + mouseClicked(); +} + +void MouseController::OnRightButtonDown(MOUSEINFO * /* mi */) { + buttons |= RIGHT_BUTTON; + mousePressed(); +} diff --git a/libraries/USBHost/src/MouseController.h b/libraries/USBHost/src/MouseController.h new file mode 100644 index 0000000..4c8c65e --- /dev/null +++ b/libraries/USBHost/src/MouseController.h @@ -0,0 +1,57 @@ +/* + Copyright (c) 2012 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 MOUSE_CONTROLLER_H +#define MOUSE_CONTROLLER_H + +#include + +enum MouseButton { + LEFT_BUTTON = 0x01, + MIDDLE_BUTTON = 0x02, + RIGHT_BUTTON = 0x04 +}; + +class MouseController : public MouseReportParser +{ +public: + MouseController(USBHost &usb) : hostMouse(&usb), dx(0), dy(0), buttons(0) { + hostMouse.SetReportParser(0, this); + }; + + bool getButton(MouseButton button) { return (buttons & button) == button; }; + int getXChange(); + int getYChange(); + // int getWheelChange(); // Not implemented + +protected: + virtual void OnMouseMove(MOUSEINFO *mi); + virtual void OnLeftButtonUp(MOUSEINFO *mi); + virtual void OnLeftButtonDown(MOUSEINFO *mi); + virtual void OnMiddleButtonUp(MOUSEINFO *mi); + virtual void OnMiddleButtonDown(MOUSEINFO *mi); + virtual void OnRightButtonUp(MOUSEINFO *mi); + virtual void OnRightButtonDown(MOUSEINFO *mi); + +private: + HIDBoot hostMouse; + int dx, dy; + int buttons; +}; + +#endif diff --git a/libraries/USBHost/src/Usb.cpp b/libraries/USBHost/src/Usb.cpp new file mode 100644 index 0000000..3b3b8b1 --- /dev/null +++ b/libraries/USBHost/src/Usb.cpp @@ -0,0 +1,872 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com +*/ +/* USB functions */ + +#include +#include "Arduino.h" +#include "Usb.h" + + +//#ifdef ARDUINO_SAMD_ZERO + +static uint32_t usb_error = 0; +static uint32_t usb_task_state = USB_DETACHED_SUBSTATE_INITIALIZE; + +/* constructor */ +USBHost::USBHost() : bmHubPre(0) { + // Set up state machine + usb_task_state = USB_DETACHED_SUBSTATE_INITIALIZE; //set up state machine +} + +/* Initialize data structures */ +uint32_t USBHost::Init() { + //devConfigIndex = 0; + // Init host stack + bmHubPre = 0; + UHD_Init(); + return 0; +} + +uint32_t USBHost::getUsbTaskState(void) { + return (usb_task_state); +} + +void USBHost::setUsbTaskState(uint32_t state) { + usb_task_state = state; +} + +uint32_t USBHost::getUsbErrorCode(void) { + return (usb_error); +} + +EpInfo* USBHost::getEpInfoEntry(uint32_t addr, uint32_t ep) { + UsbDeviceDefinition *p = addrPool.GetUsbDevicePtr(addr); + + if(!p || !p->epinfo) + return NULL; + + EpInfo *pep = p->epinfo; + + for (uint32_t i = 0; i < p->epcount; i++) { + if(pep->epAddr == ep) + return pep; + + pep++; + } + return NULL; +} + +/* set device table entry */ + +/* each device is different and has different number of endpoints. This function plugs endpoint record structure, defined in application, to devtable */ +uint32_t USBHost::setEpInfoEntry(uint32_t addr, uint32_t epcount, EpInfo* eprecord_ptr) { + if (!eprecord_ptr) + return USB_ERROR_INVALID_ARGUMENT; + + UsbDeviceDefinition *p = addrPool.GetUsbDevicePtr(addr); + + if(!p) + return USB_ERROR_ADDRESS_NOT_FOUND_IN_POOL; + + p->address.devAddress = addr; + p->epinfo = eprecord_ptr; + p->epcount = epcount; + + return 0; +} + +uint32_t USBHost::SetPipeAddress(uint32_t addr, uint32_t ep, EpInfo **ppep, uint32_t &nak_limit) { + UsbDeviceDefinition *p = addrPool.GetUsbDevicePtr(addr); + + if(!p) + return USB_ERROR_ADDRESS_NOT_FOUND_IN_POOL; + + if(!p->epinfo) + return USB_ERROR_EPINFO_IS_NULL; + + *ppep = getEpInfoEntry(addr, ep); + + if(!*ppep) + return USB_ERROR_EP_NOT_FOUND_IN_TBL; + + nak_limit = (0x0001UL << (((*ppep)->bmNakPower > USB_NAK_MAX_POWER ) ? USB_NAK_MAX_POWER : (*ppep)->bmNakPower)); + nak_limit--; + TRACE_USBHOST(printf(" => SetPipeAddress deviceEP=%lu configued as hostPIPE=%lu sending to address=%lu\r\n", ep, (*ppep)->epAddr, addr);) + /* + USBTRACE2("\r\nAddress: ", addr); + USBTRACE2(" EP: ", ep); + USBTRACE2(" NAK Power: ",(*ppep)->bmNakPower); + USBTRACE2(" NAK Limit: ", nak_limit); + USBTRACE("\r\n"); + */ + + // CTRL_PIPE.PDADDR: usb_pipe_table[pipe_num].HostDescBank[0].CTRL_PIPE.bit.PDADDR = addr + uhd_configure_address((*ppep)->epAddr, addr); // Set peripheral address + + return 0; +} + +/* Control transfer. Sets address, endpoint, fills control packet with necessary data, dispatches control packet, and initiates bulk IN transfer, */ +/* depending on request. Actual requests are defined as inlines */ +/* return codes: */ +/* 00 = success */ +/* 01-0f = non-zero HRSLT */ +uint32_t USBHost::ctrlReq(uint32_t addr, uint32_t ep, uint8_t bmReqType, uint8_t bRequest, uint8_t wValLo, uint8_t wValHi, + uint16_t wInd, uint16_t total, uint32_t nbytes, uint8_t* dataptr, USBReadParser *p) { + + uint32_t direction = 0; // Request direction, IN or OUT + uint32_t rcode; + SETUP_PKT setup_pkt; + + EpInfo *pep = NULL; + uint32_t nak_limit = 0; + + TRACE_USBHOST(printf(" => ctrlReq\r\n");) + + rcode = SetPipeAddress(addr, ep, &pep, nak_limit); + if(rcode) + return rcode; + + // Allocate Pipe0 with default 64 bytes size if not already initialized + rcode = UHD_Pipe0_Alloc(0, 64); + if (rcode) + { + TRACE_USBHOST(printf("/!\\ USBHost::ctrlReq : EP0 allocation error: %lu\r\n", rcode);) + //USBTRACE2("\n\rUSBHost::ctrlReq : EP0 allocation error: ", rcode"); + return rcode; + } + + // Determine request direction + direction = ((bmReqType & 0x80 ) > 0); + + /* fill in setup packet */ + setup_pkt.ReqType_u.bmRequestType = bmReqType; + setup_pkt.bRequest = bRequest; + setup_pkt.wVal_u.wValueLo = wValLo; + setup_pkt.wVal_u.wValueHi = wValHi; + setup_pkt.wIndex = wInd; + setup_pkt.wLength = total; + + UHD_Pipe_Write(pep->epAddr, sizeof(setup_pkt), (uint8_t *)&setup_pkt); //transfer to setup packet FIFO + + rcode = dispatchPkt(tokSETUP, ep, nak_limit); // Dispatch packet + + if (rcode) //return HRSLT if not zero + return ( rcode); + + if (dataptr != NULL) //data stage, if present + { + if (direction) // IN transfer + { + uint32_t left = total; + TRACE_USBHOST(printf(" => ctrlData IN\r\n");) + + pep->bmRcvToggle = 1; //bmRCVTOG1; + + // Bytes read into buffer + uint32_t read = nbytes; + + rcode = InTransfer(pep, nak_limit, (uint8_t*)&read, dataptr); + + if((rcode&USB_ERROR_DATATOGGLE) == USB_ERROR_DATATOGGLE) { + // yes, we flip it wrong here so that next time it is actually correct! + //pep->bmRcvToggle = (regRd(rHRSL) & bmSNDTOGRD) ? 0 : 1; + pep->bmRcvToggle = USB_HOST_DTGL(pep->epAddr); + //continue; + } + + if(rcode) { + //USBTRACE2("\n\rUSBHost::ctrlReq : in transfer: ", rcode"); + return rcode; + } + // Invoke callback function if inTransfer completed successfully and callback function pointer is specified + if(!rcode && p) + ((USBReadParser*)p)->Parse(read, dataptr, total - left); + } + else // OUT transfer + { + pep->bmSndToggle = 1; //bmSNDTOG1; + rcode = OutTransfer(pep, nak_limit, nbytes, dataptr); + } + if(rcode) //return error + return (rcode); + } + + // Status stage + UHD_Pipe_CountZero(pep->epAddr); + USB->HOST.HostPipe[pep->epAddr].PSTATUSSET.reg = USB_HOST_PSTATUSSET_DTGL; + return dispatchPkt((direction) ? tokOUTHS : tokINHS, pep->epAddr, nak_limit); //GET if direction +} + +/* IN transfer to arbitrary endpoint. Assumes PERADDR is set. Handles multiple packets if necessary. Transfers 'nbytes' bytes. */ +/* Keep sending INs and writes data to memory area pointed by 'data' */ + +/* rcode 0 if no errors. rcode 01-0f is relayed from dispatchPkt(). Rcode f0 means RCVDAVIRQ error, + fe USB xfer timeout */ +uint32_t USBHost::inTransfer(uint32_t addr, uint32_t ep, uint8_t *nbytesptr, uint8_t* data) { + EpInfo *pep = NULL; + uint32_t nak_limit = 0; + + uint32_t rcode = SetPipeAddress(addr, ep, &pep, nak_limit); + + if(rcode) { + USBTRACE3("(USB::InTransfer) SetAddress Failed ", rcode, 0x81); + USBTRACE3("(USB::InTransfer) addr requested ", addr, 0x81); + USBTRACE3("(USB::InTransfer) ep requested ", ep, 0x81); + return rcode; + } + return InTransfer(pep, nak_limit, nbytesptr, data); +} + +uint32_t USBHost::InTransfer(EpInfo *pep, uint32_t nak_limit, uint8_t *nbytesptr, uint8_t* data) { + uint32_t rcode = 0; + uint32_t pktsize = 0; + + uint32_t nbytes = *nbytesptr; + uint32_t maxpktsize = pep->maxPktSize; + + *nbytesptr = 0; + //set toggle value + if(pep->bmRcvToggle) + USB->HOST.HostPipe[pep->epAddr].PSTATUSSET.reg = USB_HOST_PSTATUSSET_DTGL; + else + USB->HOST.HostPipe[pep->epAddr].PSTATUSCLR.reg = USB_HOST_PSTATUSCLR_DTGL; + + usb_pipe_table[pep->epAddr].HostDescBank[0].ADDR.reg = (uint32_t)data; + + // use a 'break' to exit this loop + while (1) { + /* get pipe config from setting register */ + usb_pipe_table[pep->epAddr].HostDescBank[0].ADDR.reg += pktsize; + + rcode = dispatchPkt(tokIN, pep->epAddr, nak_limit); //IN packet to EP-'endpoint'. Function takes care of NAKS. + if(rcode == USB_ERROR_DATATOGGLE) { + // yes, we flip it wrong here so that next time it is actually correct! + //pep->bmRcvToggle = (regRd(rHRSL) & bmSNDTOGRD) ? 0 : 1; + pep->bmRcvToggle = USB_HOST_DTGL(pep->epAddr); + //set toggle value + if(pep->bmRcvToggle) + USB->HOST.HostPipe[pep->epAddr].PSTATUSSET.reg = USB_HOST_PSTATUSSET_DTGL; + else + USB->HOST.HostPipe[pep->epAddr].PSTATUSCLR.reg = USB_HOST_PSTATUSCLR_DTGL; + continue; + } + if(rcode) { + uhd_freeze_pipe(pep->epAddr); + //printf(">>>>>>>> Problem! dispatchPkt %2.2x\r\n", rcode); + return(rcode);// break; //should be 0, indicating ACK. Else return error code. + } + /* check for RCVDAVIRQ and generate error if not present */ + /* the only case when absence of RCVDAVIRQ makes sense is when toggle error occurred. Need to add handling for that */ + + pktsize = uhd_byte_count(pep->epAddr); // Number of received bytes + + USB->HOST.HostPipe[pep->epAddr].PSTATUSCLR.reg = USB_HOST_PSTATUSCLR_BK0RDY; + + //printf("Got %i bytes \r\n", pktsize); + // This would be OK, but... + //assert(pktsize <= nbytes); + if(pktsize > nbytes) { + // This can happen. Use of assert on Arduino locks up the Arduino. + // So I will trim the value, and hope for the best. + //printf(">>>>>>>> Problem! Wanted %i bytes but got %i.\r\n", nbytes, pktsize); + pktsize = nbytes; + } + + int16_t mem_left = (int16_t)nbytes - *((int16_t*)nbytesptr); + + if(mem_left < 0) + mem_left = 0; + + //data = bytesRd(rRCVFIFO, ((pktsize > mem_left) ? mem_left : pktsize), data); + + //regWr(rHIRQ, bmRCVDAVIRQ); // Clear the IRQ & free the buffer + *nbytesptr += pktsize;// add this packet's byte count to total transfer length + + /* The transfer is complete under two conditions: */ + /* 1. The device sent a short packet (L.T. maxPacketSize) */ + /* 2. 'nbytes' have been transferred. */ + if((pktsize < maxpktsize) || (*nbytesptr >= nbytes)) // have we transferred 'nbytes' bytes? + { + // Save toggle value + pep->bmRcvToggle = USB_HOST_DTGL(pep->epAddr); + //printf("\r\n"); + rcode = 0; + break; + } // if + } //while( 1 ) + uhd_freeze_pipe(pep->epAddr); + return ( rcode); +} + +/* OUT transfer to arbitrary endpoint. Handles multiple packets if necessary. Transfers 'nbytes' bytes. */ +/* Handles NAK bug per Maxim Application Note 4000 for single buffer transfer */ + +/* rcode 0 if no errors. rcode 01-0f is relayed from HRSL */ +uint32_t USBHost::outTransfer(uint32_t addr, uint32_t ep, uint32_t nbytes, uint8_t* data) { + EpInfo *pep = NULL; + uint32_t nak_limit = 0; + + uint32_t rcode = SetPipeAddress(addr, ep, &pep, nak_limit); + + if(rcode) + return rcode; + + return OutTransfer(pep, nak_limit, nbytes, data); +} + +uint32_t USBHost::OutTransfer(EpInfo *pep, uint32_t nak_limit, uint32_t nbytes, uint8_t *data) { + uint32_t rcode = 0, retry_count; + uint8_t *data_p = data; //local copy of the data pointer + uint32_t bytes_tosend, nak_count; + uint32_t bytes_left = nbytes; + uint8_t buf[64]; + uint8_t i; + + uint32_t maxpktsize = pep->maxPktSize; + + if(maxpktsize < 1 || maxpktsize > 64) + return USB_ERROR_INVALID_MAX_PKT_SIZE; + + for( i=0; ibmSndToggle) + USB->HOST.HostPipe[pep->epAddr].PSTATUSSET.reg = USB_HOST_PSTATUSSET_DTGL; + else + USB->HOST.HostPipe[pep->epAddr].PSTATUSCLR.reg = USB_HOST_PSTATUSCLR_DTGL; + + while(bytes_left) { + retry_count = 0; + nak_count = 0; + bytes_tosend = (bytes_left >= maxpktsize) ? maxpktsize : bytes_left; + UHD_Pipe_Write(pep->epAddr, bytes_tosend, buf); //filling output FIFO + + //set number of bytes + //dispatch packet + //wait for the completion IRQ + //clear IRQ + + rcode = dispatchPkt(tokOUT, pep->epAddr, nak_limit); + if (rcode) + { + switch(rcode) { + case USB_ERRORFLOW: + nak_count++; + if(nak_limit && (nak_count == nak_limit)) + goto breakout; + return ( rcode); + break; + case USB_ERRORTIMEOUT: + retry_count++; + if(retry_count == USB_RETRY_LIMIT) + goto breakout; + return ( rcode); + break; + case USB_ERROR_DATATOGGLE: + // yes, we flip it wrong here so that next time it is actually correct! + pep->bmSndToggle = USB_HOST_DTGL(pep->epAddr); + //set toggle value + if(pep->bmSndToggle) + USB->HOST.HostPipe[pep->epAddr].PSTATUSSET.reg = USB_HOST_PSTATUSSET_DTGL; + else + USB->HOST.HostPipe[pep->epAddr].PSTATUSCLR.reg = USB_HOST_PSTATUSCLR_DTGL; + break; + default: + goto breakout; + }//switch( rcode + } + + bytes_left -= bytes_tosend; + data_p += bytes_tosend; + }//while( bytes_left... +breakout: + + pep->bmSndToggle = USB_HOST_DTGL(pep->epAddr); + return ( rcode); //should be 0 in all cases +} + +/* dispatch USB packet. Assumes peripheral address is set and relevant buffer is loaded/empty */ +/* If NAK, tries to re-send up to nak_limit times */ +/* If nak_limit == 0, do not count NAKs, exit after timeout */ +/* If bus timeout, re-sends up to USB_RETRY_LIMIT times */ + +/* return codes 0x00-0x0f are HRSLT( 0x00 being success ), 0xff means timeout */ +uint32_t USBHost::dispatchPkt(uint32_t token, uint32_t epAddr, uint32_t nak_limit) { + uint32_t timeout = millis() + USB_XFER_TIMEOUT; + uint32_t nak_count = 0, retry_count=0; + uint32_t rcode = USB_ERROR_TRANSFER_TIMEOUT; + + TRACE_USBHOST(printf(" => dispatchPkt token=%lu pipe=%lu nak_limit=%lu\r\n", token, epAddr, nak_limit);) + + UHD_Pipe_Send(epAddr, token); //launch the transfer + + // Check timeout but don't hold timeout if VBUS is lost + while ((timeout > millis()) && (UHD_GetVBUSState() == UHD_STATE_CONNECTED)) + { + // Wait for transfer completion + if (UHD_Pipe_Is_Transfer_Complete(epAddr, token)) + { + return 0; + } + + //case hrNAK: + if((USB->HOST.HostPipe[epAddr].PINTFLAG.reg & USB_HOST_PINTFLAG_TRFAIL) ) { + USB->HOST.HostPipe[epAddr].PINTFLAG.reg = USB_HOST_PINTFLAG_TRFAIL; + nak_count++; + if(nak_limit && (nak_count == nak_limit)) { + rcode = USB_ERRORFLOW; + return (rcode); + } + } + + //case hrNAK: + if( (usb_pipe_table[epAddr].HostDescBank[0].STATUS_BK.reg & USB_ERRORFLOW ) ) { + nak_count++; + if(nak_limit && (nak_count == nak_limit)) { + rcode = USB_ERRORFLOW; + return (rcode); + } + } + + //case hrTIMEOUT: + if(usb_pipe_table[epAddr].HostDescBank[0].STATUS_PIPE.reg & USB_ERRORTIMEOUT) { + retry_count++; + if(retry_count == USB_RETRY_LIMIT) { + rcode = USB_ERRORTIMEOUT; + return (rcode); + } + } + + if( (usb_pipe_table[epAddr].HostDescBank[0].STATUS_PIPE.reg & USB_ERROR_DATATOGGLE ) ) { + rcode = USB_ERROR_DATATOGGLE; + return (rcode); + } + } + + return rcode; +} + +/* USB main task. Performs enumeration/cleanup */ +void USBHost::Task(void) //USB state machine +{ + uint32_t rcode = 0; + volatile uint32_t tmpdata = 0; + static uint32_t delay = 0; + //USB_DEVICE_DESCRIPTOR buf; + uint32_t lowspeed = 0; + + // Update USB task state on Vbus change + tmpdata = UHD_GetVBUSState(); + + /* modify USB task state if Vbus changed */ + switch (tmpdata) + { + case UHD_STATE_ERROR: //illegal state + usb_task_state = USB_DETACHED_SUBSTATE_ILLEGAL; + lowspeed = 0; + break; + + case UHD_STATE_DISCONNECTED: // Disconnected state + if ((usb_task_state & USB_STATE_MASK) != USB_STATE_DETACHED) + usb_task_state = USB_DETACHED_SUBSTATE_INITIALIZE; + lowspeed = 0; + break; + + case UHD_STATE_CONNECTED: // Attached state + if ((usb_task_state & USB_STATE_MASK) == USB_STATE_DETACHED) { + delay = millis() + USB_SETTLE_DELAY; + usb_task_state = USB_ATTACHED_SUBSTATE_SETTLE; + } + break; + }// switch( tmpdata + + // Poll connected devices (if required) + for (uint32_t i = 0; i < USB_NUMDEVICES; ++i) + if (devConfig[i]) + rcode = devConfig[i]->Poll(); + + // Perform USB enumeration stage and clean up + switch (usb_task_state) { + case USB_DETACHED_SUBSTATE_INITIALIZE: + TRACE_USBHOST(printf(" + USB_DETACHED_SUBSTATE_INITIALIZE\r\n");) + + // Init USB stack and driver + UHD_Init(); + + // Free all USB resources + for (uint32_t i = 0; i < USB_NUMDEVICES; ++i) + if (devConfig[i]) + rcode = devConfig[i]->Release(); + + usb_task_state = USB_DETACHED_SUBSTATE_WAIT_FOR_DEVICE; + break; + case USB_DETACHED_SUBSTATE_WAIT_FOR_DEVICE: //just sit here + // Nothing to do + break; + case USB_DETACHED_SUBSTATE_ILLEGAL: //just sit here + // Nothing to do + break; + case USB_ATTACHED_SUBSTATE_SETTLE: // Settle time for just attached device + if((long)(millis() - delay) >= 0L) + usb_task_state = USB_ATTACHED_SUBSTATE_RESET_DEVICE; + break; + case USB_ATTACHED_SUBSTATE_RESET_DEVICE: + TRACE_USBHOST(printf(" + USB_ATTACHED_SUBSTATE_RESET_DEVICE\r\n");) + UHD_BusReset(); //issue bus reset + usb_task_state = USB_ATTACHED_SUBSTATE_WAIT_RESET_COMPLETE; + break; + case USB_ATTACHED_SUBSTATE_WAIT_RESET_COMPLETE: + if (Is_uhd_reset_sent()) + { + TRACE_USBHOST(printf(" + USB_ATTACHED_SUBSTATE_WAIT_RESET_COMPLETE\r\n");) + + // Clear Bus Reset flag + uhd_ack_reset_sent(); + + // Enable Start Of Frame generation + uhd_enable_sof(); + + usb_task_state = USB_ATTACHED_SUBSTATE_WAIT_SOF; + + // Wait 20ms after Bus Reset (USB spec) + delay = millis() + 20; + } + break; + case USB_ATTACHED_SUBSTATE_WAIT_SOF: + // Wait for SOF received first + if (Is_uhd_sof()) + { + if (delay < millis()) + { + TRACE_USBHOST(printf(" + USB_ATTACHED_SUBSTATE_WAIT_SOF\r\n");) + + // 20ms waiting elapsed + usb_task_state = USB_STATE_CONFIGURING; + } + } + break; + case USB_STATE_CONFIGURING: + TRACE_USBHOST(printf(" + USB_STATE_CONFIGURING\r\n");) + rcode = Configuring(0, 0, lowspeed); + + if (rcode) { + TRACE_USBHOST(printf("/!\\ USBHost::Task : USB_STATE_CONFIGURING failed with code: %lu\r\n", rcode);) + if (rcode != USB_DEV_CONFIG_ERROR_DEVICE_INIT_INCOMPLETE) { + usb_error = rcode; + usb_task_state = USB_STATE_ERROR; + } + } + else { + usb_task_state = USB_STATE_RUNNING; + TRACE_USBHOST(printf(" + USB_STATE_RUNNING\r\n");) + } + break; + case USB_STATE_RUNNING: + break; + case USB_STATE_ERROR: + break; + } // switch( usb_task_state ) +} + +uint32_t USBHost::DefaultAddressing(uint32_t parent, uint32_t port, uint32_t lowspeed) { + //uint8_t buf[12]; + uint32_t rcode = 0; + UsbDeviceDefinition *p0 = NULL, *p = NULL; + + // Get pointer to pseudo device with address 0 assigned + p0 = addrPool.GetUsbDevicePtr(0); + + if(!p0) + return USB_ERROR_ADDRESS_NOT_FOUND_IN_POOL; + + if(!p0->epinfo) + return USB_ERROR_EPINFO_IS_NULL; + + p0->lowspeed = (lowspeed) ? 1 : 0; + + // Allocate new address according to device class + uint32_t bAddress = addrPool.AllocAddress(parent, 0, port); + + if(!bAddress) + return USB_ERROR_OUT_OF_ADDRESS_SPACE_IN_POOL; + + p = addrPool.GetUsbDevicePtr(bAddress); + + if(!p) + return USB_ERROR_ADDRESS_NOT_FOUND_IN_POOL; + + p->lowspeed = lowspeed; + + // Assign new address to the device + rcode = setAddr(0, 0, bAddress); + + if(rcode) { + TRACE_USBHOST(printf("/!\\ USBHost::DefaultAddressing : Set address failed with code: %lu\r\n", rcode);) + addrPool.FreeAddress(bAddress); + bAddress = 0; + return rcode; + } + return 0; +} + +uint32_t USBHost::AttemptConfig(uint32_t driver, uint32_t parent, uint32_t port, uint32_t lowspeed) { + //printf("AttemptConfig: parent = %i, port = %i\r\n", parent, port); + uint8_t retries = 0; + +again: + uint8_t rcode = devConfig[driver]->ConfigureDevice(parent, port, lowspeed); + if(rcode == USB_ERROR_CONFIG_REQUIRES_ADDITIONAL_RESET) { + if(parent == 0) { + // Send a bus reset on the root interface. + //regWr(rHCTL, bmBUSRST); //issue bus reset + UHD_BusReset(); + delay(102); // delay 102ms, compensate for clock inaccuracy. + } else { + // reset parent port + devConfig[parent]->ResetHubPort(port); + } + } else if(rcode != 0x00/*hrJERR*/ && retries < 3) { // Some devices returns this when plugged in - trying to initialize the device again usually works + delay(100); + retries++; + goto again; + } else if(rcode) + return rcode; + + rcode = devConfig[driver]->Init(parent, port, lowspeed); + if(rcode != 0x00/*hrJERR*/ && retries < 3) { // Some devices returns this when plugged in - trying to initialize the device again usually works + delay(100); + retries++; + goto again; + } + if(rcode) { + // Issue a bus reset, because the device may be in a limbo state + if(parent == 0) { + // Send a bus reset on the root interface. + //regWr(rHCTL, bmBUSRST); //issue bus reset + UHD_BusReset(); + delay(102); // delay 102ms, compensate for clock inaccuracy. + } else { + // reset parent port + devConfig[parent]->ResetHubPort(port); + } + } + return rcode; +} + +/* + * This is broken. We need to enumerate differently. + * It causes major problems with several devices if detected in an unexpected order. + * + * + * Oleg - I wouldn't do anything before the newly connected device is considered sane. + * i.e.(delays are not indicated for brevity): + * 1. reset + * 2. GetDevDescr(); + * 3a. If ACK, continue with allocating address, addressing, etc. + * 3b. Else reset again, count resets, stop at some number (5?). + * 4. When max.number of resets is reached, toggle power/fail + * If desired, this could be modified by performing two resets with GetDevDescr() in the middle - however, from my experience, if a device answers to GDD() + * it doesn't need to be reset again + * New steps proposal: + * 1: get address pool instance. exit on fail + * 2: pUsb->getDevDescr(0, 0, constBufSize, (uint8_t*)buf). exit on fail. + * 3: bus reset, 100ms delay + * 4: set address + * 5: pUsb->setEpInfoEntry(bAddress, 1, epInfo), exit on fail + * 6: while (configurations) { + * for(each configuration) { + * for (each driver) { + * 6a: Ask device if it likes configuration. Returns 0 on OK. + * If successful, the driver configured device. + * The driver now owns the endpoints, and takes over managing them. + * The following will need codes: + * Everything went well, instance consumed, exit with success. + * Instance already in use, ignore it, try next driver. + * Not a supported device, ignore it, try next driver. + * Not a supported configuration for this device, ignore it, try next driver. + * Could not configure device, fatal, exit with fail. + * } + * } + * } + * 7: for(each driver) { + * 7a: Ask device if it knows this VID/PID. Acts exactly like 6a, but using VID/PID + * 8: if we get here, no driver likes the device plugged in, so exit failure. + * + */ +uint32_t USBHost::Configuring(uint32_t parent, uint32_t port, uint32_t lowspeed) { + //uint32_t bAddress = 0; + //printf("Configuring: parent = %i, port = %i\r\n", parent, port); + uint32_t devConfigIndex; + uint32_t rcode = 0; + uint8_t buf[sizeof (USB_DEVICE_DESCRIPTOR)]; + USB_DEVICE_DESCRIPTOR *udd = reinterpret_cast(buf); + UsbDeviceDefinition *p = NULL; + EpInfo *oldep_ptr = NULL; + EpInfo epInfo; + + epInfo.epAddr = 0; + epInfo.maxPktSize = 8; + epInfo.bmSndToggle = 0; + epInfo.bmRcvToggle = 0; + epInfo.bmNakPower = USB_NAK_MAX_POWER; + + //delay(2000); + AddressPool &addrPool = GetAddressPool(); + // Get pointer to pseudo device with address 0 assigned + p = addrPool.GetUsbDevicePtr(0); + if(!p) { + //printf("Configuring error: USB_ERROR_ADDRESS_NOT_FOUND_IN_POOL\r\n"); + return USB_ERROR_ADDRESS_NOT_FOUND_IN_POOL; + } + + // Save old pointer to EP_RECORD of address 0 + oldep_ptr = p->epinfo; + + // Temporary assign new pointer to epInfo to p->epinfo in order to + // avoid toggle inconsistence + + p->epinfo = &epInfo; + + p->lowspeed = lowspeed; + // Get device descriptor + rcode = getDevDescr(0, 0, sizeof (USB_DEVICE_DESCRIPTOR), (uint8_t*)buf); + // The first GetDescriptor give us the endpoint 0 max packet size. + epInfo.maxPktSize = buf[7]; + // Restore p->epinfo + p->epinfo = oldep_ptr; + + if(rcode) { + //printf("Configuring error: Can't get USB_DEVICE_DESCRIPTOR\r\n"); + return rcode; + } + + // to-do? + // Allocate new address according to device class + //bAddress = addrPool.AllocAddress(parent, false, port); + + //if (!bAddress) + // return USB_ERROR_OUT_OF_ADDRESS_SPACE_IN_POOL; + uint16_t vid = udd->idVendor; + uint16_t pid = udd->idProduct; + uint8_t klass = udd->bDeviceClass; + + // Attempt to configure if VID/PID or device class matches with a driver + for(devConfigIndex = 0; devConfigIndex < USB_NUMDEVICES; devConfigIndex++) { + if(!devConfig[devConfigIndex]) continue; // no driver + if(devConfig[devConfigIndex]->GetAddress()) continue; // consumed + if(devConfig[devConfigIndex]->VIDPIDOK(vid, pid) || devConfig[devConfigIndex]->DEVCLASSOK(klass)) { + rcode = AttemptConfig(devConfigIndex, parent, port, lowspeed); + if(rcode != USB_DEV_CONFIG_ERROR_DEVICE_NOT_SUPPORTED) + break; + } + } + + if(devConfigIndex < USB_NUMDEVICES) { + return rcode; + } + + + // blindly attempt to configure + for(devConfigIndex = 0; devConfigIndex < USB_NUMDEVICES; devConfigIndex++) { + if(!devConfig[devConfigIndex]) continue; + if(devConfig[devConfigIndex]->GetAddress()) continue; // consumed + if(devConfig[devConfigIndex]->VIDPIDOK(vid, pid) || devConfig[devConfigIndex]->DEVCLASSOK(klass)) continue; // If this is true it means it must have returned USB_DEV_CONFIG_ERROR_DEVICE_NOT_SUPPORTED above + rcode = AttemptConfig(devConfigIndex, parent, port, lowspeed); + + //printf("ERROR ENUMERATING %2.2x\r\n", rcode); + if(!(rcode == USB_DEV_CONFIG_ERROR_DEVICE_NOT_SUPPORTED || rcode == USB_ERROR_CLASS_INSTANCE_ALREADY_IN_USE)) { + // in case of an error dev_index should be reset to 0 + // in order to start from the very beginning the + // next time the program gets here + //if (rcode != USB_DEV_CONFIG_ERROR_DEVICE_INIT_INCOMPLETE) + // devConfigIndex = 0; + return rcode; + } + } + // if we get here that means that the device class is not supported by any of registered classes + rcode = DefaultAddressing(parent, port, lowspeed); + + return rcode; +} + +uint32_t USBHost::ReleaseDevice(uint32_t addr) { + if(!addr) + return 0; + + for(uint32_t i = 0; i < USB_NUMDEVICES; i++) { + if(!devConfig[i]) continue; + if(devConfig[i]->GetAddress() == addr) + return devConfig[i]->Release(); + } + return 0; +} + +//get device descriptor + +uint32_t USBHost::getDevDescr(uint32_t addr, uint32_t ep, uint32_t nbytes, uint8_t* dataptr) { + return (ctrlReq(addr, ep, bmREQ_GET_DESCR, USB_REQUEST_GET_DESCRIPTOR, 0x00, USB_DESCRIPTOR_DEVICE, 0x0000, nbytes, nbytes, dataptr, 0)); +} +//get configuration descriptor + +uint32_t USBHost::getConfDescr(uint32_t addr, uint32_t ep, uint32_t nbytes, uint32_t conf, uint8_t* dataptr) { + return (ctrlReq(addr, ep, bmREQ_GET_DESCR, USB_REQUEST_GET_DESCRIPTOR, conf, USB_DESCRIPTOR_CONFIGURATION, 0x0000, nbytes, nbytes, dataptr, 0)); +} + +/* Requests Configuration Descriptor. Sends two Get Conf Descr requests. The first one gets the total length of all descriptors, then the second one requests this + total length. The length of the first request can be shorter ( 4 bytes ), however, there are devices which won't work unless this length is set to 9 */ +uint32_t USBHost::getConfDescr(uint32_t addr, uint32_t ep, uint32_t conf, USBReadParser *p) { + const uint32_t bufSize = 64; + uint8_t buf[bufSize]; + USB_CONFIGURATION_DESCRIPTOR *ucd = reinterpret_cast(buf); + + uint32_t ret = getConfDescr(addr, ep, 9, conf, buf); + + if(ret) + return ret; + + uint32_t total = ucd->wTotalLength; + + //USBTRACE2("\r\ntotal conf.size:", total); + + return (ctrlReq(addr, ep, bmREQ_GET_DESCR, USB_REQUEST_GET_DESCRIPTOR, conf, USB_DESCRIPTOR_CONFIGURATION, 0x0000, total, bufSize, buf, p)); +} + +//get string descriptor + +uint32_t USBHost::getStrDescr(uint32_t addr, uint32_t ep, uint32_t nbytes, uint32_t index, uint32_t langid, uint8_t* dataptr) { + return (ctrlReq(addr, ep, bmREQ_GET_DESCR, USB_REQUEST_GET_DESCRIPTOR, index, USB_DESCRIPTOR_STRING, langid, nbytes, nbytes, dataptr, 0)); +} +//set address + +uint32_t USBHost::setAddr(uint32_t oldaddr, uint32_t ep, uint32_t newaddr) { + uint32_t rcode = ctrlReq(oldaddr, ep, bmREQ_SET, USB_REQUEST_SET_ADDRESS, newaddr, 0x00, 0x0000, 0x0000, 0x0000, NULL, NULL); + //delay(2); //per USB 2.0 sect.9.2.6.3 + delay(300); // Older spec says you should wait at least 200ms + return rcode; + //return ( ctrlReq(oldaddr, ep, bmREQ_SET, USB_REQUEST_SET_ADDRESS, newaddr, 0x00, 0x0000, 0x0000, 0x0000, NULL, NULL)); +} +//set configuration + +uint32_t USBHost::setConf(uint32_t addr, uint32_t ep, uint32_t conf_value) { + return ( ctrlReq(addr, ep, bmREQ_SET, USB_REQUEST_SET_CONFIGURATION, conf_value, 0x00, 0x0000, 0x0000, 0x0000, NULL, NULL)); +} + +//#endif //ARDUINO_SAMD_ZERO diff --git a/libraries/USBHost/src/Usb.h b/libraries/USBHost/src/Usb.h new file mode 100644 index 0000000..919b835 --- /dev/null +++ b/libraries/USBHost/src/Usb.h @@ -0,0 +1,46 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com +*/ +/* USB functions */ + +#ifndef USB_H_INCLUDED +#define USB_H_INCLUDED +#define _usb_h_ + +#include + +//#include "Arduino.h" +#include "macros.h" +// None of these should ever be included by a driver, or a user's sketch. + +#include "variant.h" +#define USB_HOST_SERIAL SERIAL_PORT_MONITOR +#include "Print.h" +#include "printhex.h" +#include "message.h" +#include "hexdump.h" +#include "sink_parser.h" + +#include "address.h" + +#include "usb_ch9.h" +//#include "usbhost.h" +#include "UsbCore.h" +#include "parsetools.h" + +#include "confdescparser.h" + +#endif /* USB_H_INCLUDED */ diff --git a/libraries/USBHost/src/UsbCore.h b/libraries/USBHost/src/UsbCore.h new file mode 100644 index 0000000..f5368ce --- /dev/null +++ b/libraries/USBHost/src/UsbCore.h @@ -0,0 +1,292 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com + */ + +#if !defined(_usb_h_) || defined(USBCORE_H) +#error "Never include UsbCore.h directly; include Usb.h instead" +#else +#define USBCORE_H + +// Not used anymore? If anyone uses this, please let us know so that this may be +// moved to the proper place, settings.h. +//#define USB_METHODS_INLINE + +/* shield pins. First parameter - SS pin, second parameter - INT pin */ +#ifdef BOARD_BLACK_WIDDOW +typedef MAX3421e MAX3421E; // Black Widow +#elif defined(CORE_TEENSY) && (defined(__AVR_AT90USB646__) || defined(__AVR_AT90USB1286__)) +#if EXT_RAM +typedef MAX3421e MAX3421E; // Teensy++ 2.0 with XMEM2 +#else +typedef MAX3421e MAX3421E; // Teensy++ 1.0 and 2.0 +#endif +#elif defined(BOARD_MEGA_ADK) +typedef MAX3421e MAX3421E; // Arduino Mega ADK +#elif defined(ARDUINO_AVR_BALANDUINO) +typedef MAX3421e MAX3421E; // Balanduino +#else +//typedef MAX3421e MAX3421E; // Official Arduinos (UNO, Duemilanove, Mega, 2560, Leonardo, Due etc.) or Teensy 2.0 and 3.0 +#endif + +/* Common setup data constant combinations */ +#define bmREQ_GET_DESCR USB_SETUP_DEVICE_TO_HOST|USB_SETUP_TYPE_STANDARD|USB_SETUP_RECIPIENT_DEVICE //get descriptor request type +#define bmREQ_SET USB_SETUP_HOST_TO_DEVICE|USB_SETUP_TYPE_STANDARD|USB_SETUP_RECIPIENT_DEVICE //set request type for all but 'set feature' and 'set interface' +#define bmREQ_CL_GET_INTF USB_SETUP_DEVICE_TO_HOST|USB_SETUP_TYPE_CLASS|USB_SETUP_RECIPIENT_INTERFACE //get interface request type + +// D7 data transfer direction (0 - host-to-device, 1 - device-to-host) +// D6-5 Type (0- standard, 1 - class, 2 - vendor, 3 - reserved) +// D4-0 Recipient (0 - device, 1 - interface, 2 - endpoint, 3 - other, 4..31 - reserved) + +// USB Device Classes +#define USB_CLASS_USE_CLASS_INFO 0x00 // Use Class Info in the Interface Descriptors +#define USB_CLASS_AUDIO 0x01 // Audio +#define USB_CLASS_COM_AND_CDC_CTRL 0x02 // Communications and CDC Control +#define USB_CLASS_HID 0x03 // HID +#define USB_CLASS_PHYSICAL 0x05 // Physical +#define USB_CLASS_IMAGE 0x06 // Image +#define USB_CLASS_PRINTER 0x07 // Printer +#define USB_CLASS_MASS_STORAGE 0x08 // Mass Storage +#define USB_CLASS_HUB 0x09 // Hub +#define USB_CLASS_CDC_DATA 0x0a // CDC-Data +#define USB_CLASS_SMART_CARD 0x0b // Smart-Card +#define USB_CLASS_CONTENT_SECURITY 0x0d // Content Security +#define USB_CLASS_VIDEO 0x0e // Video +#define USB_CLASS_PERSONAL_HEALTH 0x0f // Personal Healthcare +#define USB_CLASS_DIAGNOSTIC_DEVICE 0xdc // Diagnostic Device +#define USB_CLASS_WIRELESS_CTRL 0xe0 // Wireless Controller +#define USB_CLASS_MISC 0xef // Miscellaneous +#define USB_CLASS_APP_SPECIFIC 0xfe // Application Specific +#define USB_CLASS_VENDOR_SPECIFIC 0xff // Vendor Specific + +// Additional Error Codes +#define USB_DEV_CONFIG_ERROR_DEVICE_NOT_SUPPORTED 0xD1 +#define USB_DEV_CONFIG_ERROR_DEVICE_INIT_INCOMPLETE 0xD2 +#define USB_ERROR_UNABLE_TO_REGISTER_DEVICE_CLASS 0xD3 +#define USB_ERROR_OUT_OF_ADDRESS_SPACE_IN_POOL 0xD4 +#define USB_ERROR_HUB_ADDRESS_OVERFLOW 0xD5 +#define USB_ERROR_ADDRESS_NOT_FOUND_IN_POOL 0xD6 +#define USB_ERROR_EPINFO_IS_NULL 0xD7 +#define USB_ERROR_INVALID_ARGUMENT 0xD8 +#define USB_ERROR_CLASS_INSTANCE_ALREADY_IN_USE 0xD9 +#define USB_ERROR_INVALID_MAX_PKT_SIZE 0xDA +#define USB_ERROR_EP_NOT_FOUND_IN_TBL 0xDB +#define USB_ERROR_CONFIG_REQUIRES_ADDITIONAL_RESET 0xE0 +#define USB_ERROR_FailGetDevDescr 0xE1 +#define USB_ERROR_FailSetDevTblEntry 0xE2 +#define USB_ERROR_FailGetConfDescr 0xE3 +#define USB_ERROR_TRANSFER_TIMEOUT 0xFF + +#define USB_XFER_TIMEOUT 10000 //30000 // (5000) USB transfer timeout in milliseconds, per section 9.2.6.1 of USB 2.0 spec +//#define USB_NAK_LIMIT 32000 //NAK limit for a transfer. 0 means NAKs are not counted +#define USB_RETRY_LIMIT 3 // 3 retry limit for a transfer +#define USB_SETTLE_DELAY 200 //settle delay in milliseconds + +#define USB_NUMDEVICES 16 //number of USB devices +//#define HUB_MAX_HUBS 7 // maximum number of hubs that can be attached to the host controller +#define HUB_PORT_RESET_DELAY 20 // hub port reset delay 10 ms recomended, can be up to 20 ms + +/* USB state machine states */ +#define USB_STATE_MASK 0xf0 + +#define USB_STATE_DETACHED 0x10 +#define USB_DETACHED_SUBSTATE_INITIALIZE 0x11 +#define USB_DETACHED_SUBSTATE_WAIT_FOR_DEVICE 0x12 +#define USB_DETACHED_SUBSTATE_ILLEGAL 0x13 +#define USB_ATTACHED_SUBSTATE_SETTLE 0x20 +#define USB_ATTACHED_SUBSTATE_RESET_DEVICE 0x30 +#define USB_ATTACHED_SUBSTATE_WAIT_RESET_COMPLETE 0x40 +#define USB_ATTACHED_SUBSTATE_WAIT_SOF 0x50 +#define USB_ATTACHED_SUBSTATE_WAIT_RESET 0x51 +#define USB_ATTACHED_SUBSTATE_GET_DEVICE_DESCRIPTOR_SIZE 0x60 +#define USB_STATE_ADDRESSING 0x70 +#define USB_STATE_CONFIGURING 0x80 +#define USB_STATE_RUNNING 0x90 +#define USB_STATE_ERROR 0xa0 + +class USBDeviceConfig { +public: + + virtual uint32_t Init(uint32_t /* parent */, uint32_t /* port */, uint32_t /* lowspeed */) { + return 0; + } + + virtual uint32_t ConfigureDevice(uint32_t /* parent */, uint32_t /* port */, uint32_t /* lowspeed */) { + return 0; + } + + virtual uint32_t Release() { + return 0; + } + + virtual uint32_t Poll() { + return 0; + } + + virtual uint32_t GetAddress() { + return 0; + } + + virtual void ResetHubPort(uint32_t /* port */) { + return; + } // Note used for hubs only! + + virtual uint32_t VIDPIDOK(uint32_t /* vid */, uint32_t /* pid */) { + return false; + } + + virtual uint32_t DEVCLASSOK(uint32_t /* klass */) { + return false; + } +}; + +/* USB Setup Packet Structure */ +typedef struct { + + union { // offset description + uint8_t bmRequestType; // 0 Bit-map of request type + + struct { + uint8_t recipient : 5; // Recipient of the request + uint8_t type : 2; // Type of request + uint8_t direction : 1; // Direction of data X-fer + }; + } ReqType_u; + uint8_t bRequest; // 1 Request + + union { + uint16_t wValue; // 2 Depends on bRequest + + struct { + uint8_t wValueLo; + uint8_t wValueHi; + }; + } wVal_u; + uint16_t wIndex; // 4 Depends on bRequest + uint16_t wLength; // 6 Depends on bRequest +} SETUP_PKT, *PSETUP_PKT; + + + +// Base class for incoming data parser + +class USBReadParser { +public: + virtual void Parse(const uint32_t len, const uint8_t *pbuf, const uint32_t &offset) = 0; +}; + +class USBHost { + AddressPoolImpl addrPool; + USBDeviceConfig* devConfig[USB_NUMDEVICES]; + uint8_t bmHubPre; + +public: + USBHost(void); + + void SetHubPreMask() { + //bmHubPre |= bmHUBPRE; + }; + + void ResetHubPreMask() { + //bmHubPre &= (~bmHUBPRE); + }; + + AddressPool& GetAddressPool() { + return (AddressPool&)addrPool; + }; + + uint32_t RegisterDeviceClass(USBDeviceConfig *pdev) { + for(uint8_t i = 0; i < USB_NUMDEVICES; i++) { + if(!devConfig[i]) { + devConfig[i] = pdev; + return 0; + } + } + return USB_ERROR_UNABLE_TO_REGISTER_DEVICE_CLASS; + }; + + void ForEachUsbDevice(UsbDeviceHandleFunc pfunc) { + addrPool.ForEachUsbDevice(pfunc); + }; + uint32_t getUsbTaskState(void); + void setUsbTaskState(uint32_t state); + uint32_t getUsbErrorCode(void); + + EpInfo* getEpInfoEntry(uint32_t addr, uint32_t ep); + uint32_t setEpInfoEntry(uint32_t addr, uint32_t epcount, EpInfo* eprecord_ptr); + + /* Control requests */ + uint32_t getDevDescr(uint32_t addr, uint32_t ep, uint32_t nbytes, uint8_t* dataptr); + uint32_t getConfDescr(uint32_t addr, uint32_t ep, uint32_t nbytes, uint32_t conf, uint8_t* dataptr); + + uint32_t getConfDescr(uint32_t addr, uint32_t ep, uint32_t conf, USBReadParser *p); + + uint32_t getStrDescr(uint32_t addr, uint32_t ep, uint32_t nbytes, uint32_t index, uint32_t langid, uint8_t* dataptr); + uint32_t setAddr(uint32_t oldaddr, uint32_t ep, uint32_t newaddr); + uint32_t setConf(uint32_t addr, uint32_t ep, uint32_t conf_value); + /**/ + uint32_t ctrlData(uint32_t addr, uint32_t ep, uint32_t nbytes, uint8_t* dataptr, uint32_t direction); + uint32_t ctrlStatus(uint32_t ep, uint32_t direction, uint32_t nak_limit); + uint32_t inTransfer(uint32_t addr, uint32_t ep, uint8_t *nbytesptr, uint8_t* data); + uint32_t outTransfer(uint32_t addr, uint32_t ep, uint32_t nbytes, uint8_t* data); + uint32_t dispatchPkt(uint32_t token, uint32_t ep, uint32_t nak_limit); + + void Task(void); + + uint32_t DefaultAddressing(uint32_t parent, uint32_t port, uint32_t lowspeed); + uint32_t Configuring(uint32_t parent, uint32_t port, uint32_t lowspeed); + uint32_t ReleaseDevice(uint32_t addr); + + uint32_t ctrlReq(uint32_t addr, uint32_t ep, uint8_t bmReqType, uint8_t bRequest, uint8_t wValLo, uint8_t wValHi, + uint16_t wInd, uint16_t total, uint32_t nbytes, uint8_t* dataptr, USBReadParser *p); + + uint32_t Init(); +private: + uint32_t SetPipeAddress(uint32_t addr, uint32_t ep, EpInfo **ppep, uint32_t &nak_limit); + uint32_t OutTransfer(EpInfo *pep, uint32_t nak_limit, uint32_t nbytes, uint8_t *data); + uint32_t InTransfer(EpInfo *pep, uint32_t nak_limit, uint8_t *nbytesptr, uint8_t *data); + uint32_t AttemptConfig(uint32_t driver, uint32_t parent, uint32_t port, uint32_t lowspeed); +}; + +#if 0 //defined(USB_METHODS_INLINE) +//get device descriptor + +inline uint8_t USBHost::getDevDescr(uint8_t addr, uint8_t ep, uint16_t nbytes, uint8_t* dataptr) { + return ( ctrlReq(addr, ep, bmREQ_GET_DESCR, USB_REQUEST_GET_DESCRIPTOR, 0x00, USB_DESCRIPTOR_DEVICE, 0x0000, nbytes, dataptr)); +} +//get configuration descriptor + +inline uint8_t USBHost::getConfDescr(uint8_t addr, uint8_t ep, uint16_t nbytes, uint8_t conf, uint8_t* dataptr) { + return ( ctrlReq(addr, ep, bmREQ_GET_DESCR, USB_REQUEST_GET_DESCRIPTOR, conf, USB_DESCRIPTOR_CONFIGURATION, 0x0000, nbytes, dataptr)); +} +//get string descriptor + +inline uint8_t USBHost::getStrDescr(uint8_t addr, uint8_t ep, uint16_t nuint8_ts, uint8_t index, uint16_t langid, uint8_t* dataptr) { + return ( ctrlReq(addr, ep, bmREQ_GET_DESCR, USB_REQUEST_GET_DESCRIPTOR, index, USB_DESCRIPTOR_STRING, langid, nuint8_ts, dataptr)); +} +//set address + +inline uint8_t USBHost::setAddr(uint8_t oldaddr, uint8_t ep, uint8_t newaddr) { + return ( ctrlReq(oldaddr, ep, bmREQ_SET, USB_REQUEST_SET_ADDRESS, newaddr, 0x00, 0x0000, 0x0000, NULL)); +} +//set configuration + +inline uint8_t USBHost::setConf(uint8_t addr, uint8_t ep, uint8_t conf_value) { + return ( ctrlReq(addr, ep, bmREQ_SET, USB_REQUEST_SET_CONFIGURATION, conf_value, 0x00, 0x0000, 0x0000, NULL)); +} + +#endif // defined(USB_METHODS_INLINE) + +#endif /* USBCORE_H */ diff --git a/libraries/USBHost/src/address.h b/libraries/USBHost/src/address.h new file mode 100644 index 0000000..a961082 --- /dev/null +++ b/libraries/USBHost/src/address.h @@ -0,0 +1,280 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com +*/ + +#if !defined(_usb_h_) || defined(ADDRESS_H_INCLUDED) +#error "Never include address.h directly; include Usb.h instead" +#else +#define ADDRESS_H_INCLUDED + +#include +#include + +/* NAK powers. To save space in endpoint data structure, amount of retries before giving up and returning 0x4 is stored in */ +/* bmNakPower as a power of 2. The actual nak_limit is then calculated as nak_limit = ( 2^bmNakPower - 1) */ +#define USB_NAK_MAX_POWER 15 //NAK binary order maximum value +#define USB_NAK_DEFAULT 14 //default 32K-1 NAKs before giving up +#define USB_NAK_NOWAIT 1 //Single NAK stops transfer +#define USB_NAK_NONAK 0 //Do not count NAKs, stop retrying after USB Timeout + +struct EpInfo { + uint32_t epAddr; // Endpoint address + uint32_t maxPktSize; // Maximum packet size + union { + uint8_t epAttribs; + + struct { + uint8_t bmSndToggle : 1; // Send toggle, when zero bmSNDTOG0, bmSNDTOG1 otherwise + uint8_t bmRcvToggle : 1; // Send toggle, when zero bmRCVTOG0, bmRCVTOG1 otherwise + uint8_t bmNakPower : 6; // Binary order for NAK_LIMIT value + }; + }; +}; + +// 7 6 5 4 3 2 1 0 +// --------------------------------- +// | | H | P | P | P | A | A | A | +// --------------------------------- +// +// H - if 1 the address is a hub address +// P - parent hub address +// A - device address / port number in case of hub +// + +struct UsbDeviceAddress { + union { + struct { + uint32_t bmAddress : 3; // device address/port number + uint32_t bmParent : 3; // parent hub address + uint32_t bmHub : 1; // hub flag + uint32_t bmReserved : 25; // reserved, must be zerro + }; + uint32_t devAddress; + }; +}; + +#define bmUSB_DEV_ADDR_ADDRESS 0x07 +#define bmUSB_DEV_ADDR_PARENT 0x38 +#define bmUSB_DEV_ADDR_HUB 0x40 + +struct UsbDeviceDefinition { + EpInfo *epinfo; // endpoint info pointer + UsbDeviceAddress address; + uint32_t epcount; // number of endpoints + uint32_t lowspeed; // indicates if a device is the low speed one + // uint8_t devclass; // device class +}; + +class AddressPool { +public: + virtual UsbDeviceDefinition* GetUsbDevicePtr(uint32_t addr) = 0; + virtual uint32_t AllocAddress(uint32_t parent, uint32_t is_hub = 0, uint32_t port = 0) = 0; + virtual void FreeAddress(uint32_t addr) = 0; +}; + +typedef void (*UsbDeviceHandleFunc)(UsbDeviceDefinition *pdev); + +#define ADDR_ERROR_INVALID_INDEX 0xFF +#define ADDR_ERROR_INVALID_ADDRESS 0xFF + +template +class AddressPoolImpl : public AddressPool { + EpInfo dev0ep; //Endpoint data structure used during enumeration for uninitialized device + + uint32_t hubCounter; // hub counter is kept + // in order to avoid hub address duplication + + UsbDeviceDefinition thePool[MAX_DEVICES_ALLOWED]; + + // Initializes address pool entry + + void InitEntry(uint32_t index) { + thePool[index].address.devAddress = 0; + thePool[index].epcount = 1; + thePool[index].lowspeed = 0; + thePool[index].epinfo = &dev0ep; + }; + + // Returns thePool index for a given address + + uint32_t FindAddressIndex(uint32_t address = 0) { + for (uint8_t i = 1; i < MAX_DEVICES_ALLOWED; i++) { + if(thePool[i].address.devAddress == address) + return i; + } + return 0; + }; + + // Returns thePool child index for a given parent + + uint32_t FindChildIndex(UsbDeviceAddress addr, uint32_t start = 1) { + for (uint32_t i = (start < 1 || start >= MAX_DEVICES_ALLOWED) ? 1 : start; i < MAX_DEVICES_ALLOWED; i++) { + if(thePool[i].address.bmParent == addr.bmAddress) + return i; + } + return 0; + }; + + // Frees address entry specified by index parameter + + void FreeAddressByIndex(uint32_t index) { + // Zero field is reserved and should not be affected + if(index == 0) + return; + + UsbDeviceAddress uda = thePool[index].address; + // If a hub was switched off all port addresses should be freed + if(uda.bmHub == 1) { + for (uint32_t i = 1; (i = FindChildIndex(uda, i));) + FreeAddressByIndex(i); + + // If the hub had the last allocated address, hubCounter should be decremented + if(hubCounter == uda.bmAddress) + hubCounter--; + } + InitEntry(index); + } + + // Initializes the whole address pool at once + + void InitAllAddresses() { + for (uint32_t i = 1; i < MAX_DEVICES_ALLOWED; i++) + InitEntry(i); + + hubCounter = 0; + }; + +public: + + AddressPoolImpl() : hubCounter(0) { + // Zero address is reserved + InitEntry(0); + + thePool[0].address.devAddress = 0; + thePool[0].epinfo = &dev0ep; + dev0ep.epAddr = 0; + dev0ep.maxPktSize = 8; + dev0ep.epAttribs = 0; //set DATA0/1 toggles to 0 + dev0ep.bmNakPower = USB_NAK_MAX_POWER; + + InitAllAddresses(); + }; + + // Returns a pointer to a specified address entry + + virtual UsbDeviceDefinition* GetUsbDevicePtr(uint32_t addr) { + if(!addr) + return thePool; + + uint32_t index = FindAddressIndex(addr); + + return (!index) ? NULL : thePool + index; + }; + + // Performs an operation specified by pfunc for each addressed device + + void ForEachUsbDevice(UsbDeviceHandleFunc pfunc) { + if(!pfunc) + return; + + for (uint32_t i = 1; i < MAX_DEVICES_ALLOWED; i++) + if(thePool[i].address.devAddress) + pfunc(thePool + i); + }; + + // Allocates new address + + virtual uint32_t AllocAddress(uint32_t parent, uint32_t is_hub = 0, uint32_t port = 0) { + /* if (parent != 0 && port == 0) + USB_HOST_SERIAL.println("PRT:0"); */ + UsbDeviceAddress _parent; + _parent.devAddress = parent; + if(_parent.bmReserved || port > 7) + //if(parent > 127 || port > 7) + return 0; + + if(is_hub && hubCounter == 7) + return 0; + + // finds first empty address entry starting from one + uint32_t index = FindAddressIndex(0); + + if(!index) // if empty entry is not found + return 0; + + if(_parent.devAddress == 0) { + if(is_hub) { + thePool[index].address.devAddress = 0x41; + hubCounter++; + } else + thePool[index].address.devAddress = 1; + + return thePool[index].address.devAddress; + } + + UsbDeviceAddress addr; + addr.devAddress = 0; // Ensure all bits are zero + addr.bmParent = _parent.bmAddress; + if(is_hub) { + addr.bmHub = 1; + addr.bmAddress = ++hubCounter; + } else { + addr.bmHub = 0; + addr.bmAddress = port; + } + thePool[index].address = addr; + /* + USB_HOST_SERIAL.print("Addr:"); + USB_HOST_SERIAL.print(addr.bmHub, HEX); + USB_HOST_SERIAL.print("."); + USB_HOST_SERIAL.print(addr.bmParent, HEX); + USB_HOST_SERIAL.print("."); + USB_HOST_SERIAL.println(addr.bmAddress, HEX); + */ + return thePool[index].address.devAddress; + }; + + // Empties pool entry + + virtual void FreeAddress(uint32_t addr) { + // if the root hub is disconnected all the addresses should be initialized + if(addr == 0x41) { + InitAllAddresses(); + return; + } + uint32_t index = FindAddressIndex(addr); + FreeAddressByIndex(index); + }; + + // Returns number of hubs attached + // It can be rather helpfull to find out if there are hubs attached than getting the exact number of hubs. + //uint32_t GetNumHubs() + //{ + // return hubCounter; + //}; + //uint32_t GetNumDevices() + //{ + // uint32_t counter = 0; + + // for (uint32_t i=1; iRegisterDeviceClass(this); //set devConfig[] entry + } +} + +uint32_t ADK::ConfigureDevice(uint32_t parent, uint32_t port, uint32_t lowspeed) { + return Init(parent, port, lowspeed); // Just call Init. Yes, really! +} + +/* Connection initialization of an Android phone */ +uint32_t ADK::Init(uint32_t parent, uint32_t port, uint32_t lowspeed) { + uint8_t buf[sizeof (USB_DEVICE_DESCRIPTOR)]; + USB_DEVICE_DESCRIPTOR * udd = reinterpret_cast(buf); + uint32_t rcode; + uint32_t num_of_conf; // number of configurations + UsbDeviceDefinition *p = NULL; + EpInfo *oldep_ptr = NULL; + + // get memory address of USB device address pool + AddressPool &addrPool = pUsb->GetAddressPool(); + + USBTRACE("\r\nADK Init"); + + // check if address has already been assigned to an instance + if(bAddress) { + USBTRACE("\r\nAddress in use"); + return USB_ERROR_CLASS_INSTANCE_ALREADY_IN_USE; + } + + // Get pointer to pseudo device with address 0 assigned + p = addrPool.GetUsbDevicePtr(0); + + if(!p) { + USBTRACE("\r\nAddress not found"); + return USB_ERROR_ADDRESS_NOT_FOUND_IN_POOL; + } + + if(!p->epinfo) { + USBTRACE("epinfo is null\r\n"); + return USB_ERROR_EPINFO_IS_NULL; + } + + // Save old pointer to EP_RECORD of address 0 + oldep_ptr = p->epinfo; + + // Temporary assign new pointer to epInfo to p->epinfo in order to avoid toggle inconsistence + p->epinfo = epInfo; + + p->lowspeed = lowspeed; + + // Get device descriptor GET_DESCRIPTOR + rcode = pUsb->getDevDescr(0, 0, sizeof(USB_DEVICE_DESCRIPTOR), (uint8_t*)buf); + + // Restore p->epinfo + p->epinfo = oldep_ptr; + + if(rcode) { + USBTRACE("\r\nGetDevDesc1 Error "); + goto FailGetDevDescr; + } + + // Reset + UHD_BusReset(); + while( Is_uhd_starting_reset() ) {} + + // Allocate new address according to device class + bAddress = addrPool.AllocAddress(parent, false, port); + if (!bAddress) + return USB_ERROR_OUT_OF_ADDRESS_SPACE_IN_POOL; + + + // Extract Max Packet Size from device descriptor + epInfo[0].maxPktSize = udd->bMaxPacketSize0; + + // Assign new address to the device SET_ADDRESS + rcode = pUsb->setAddr(0, 0, bAddress); + if(rcode) { + USBTRACE("\r\nsetAddr Error "); + p->lowspeed = false; + addrPool.FreeAddress(bAddress); + bAddress = 0; + TRACE_USBHOST(printf("ADK::Init : setAddr failed with rcode %lu\r\n", rcode);) + return rcode; + }//if (rcode... + + USBTRACE2("\r\nAddr:", bAddress); + // Spec says you should wait at least 200ms. + //delay(300); + + // Save old pointer to EP_RECORD of address 0 + oldep_ptr = p->epinfo; + // Temporary assign new pointer to epInfo to p->epinfo in order to avoid toggle inconsistence + p->epinfo = epInfo; + // Get device descriptor GET_DESCRIPTOR + rcode = pUsb->getDevDescr(bAddress, 0, sizeof(USB_DEVICE_DESCRIPTOR), (uint8_t*)buf); + // Restore p->epinfo + p->epinfo = oldep_ptr; + if (rcode) + { + USBTRACE("\r\nGetDevDesc2 Error "); + goto FailGetDevDescr; + } + + TRACE_USBHOST(printf("ADK::Init : device address is now %lu\r\n", bAddress);) + + p->lowspeed = false; + + //get pointer to assigned address record + p = addrPool.GetUsbDevicePtr(bAddress); + if(!p) { + return USB_ERROR_ADDRESS_NOT_FOUND_IN_POOL; + } + + p->lowspeed = lowspeed; + + // Assign epInfo to epinfo pointer - only EP0 is known + rcode = pUsb->setEpInfoEntry(bAddress, 1, epInfo); + if(rcode) { + goto FailSetDevTblEntry; + } + + //check if ADK device is already in accessory mode; if yes, configure and exit + if(udd->idVendor == ADK_VID && + (udd->idProduct == ADK_PID || udd->idProduct == ADB_PID)) { + USBTRACE("\r\nAcc.mode device detected"); + /* go through configurations, find first bulk-IN, bulk-OUT EP, fill epInfo and quit */ + num_of_conf = udd->bNumConfigurations; + + USBTRACE2("\r\nNC:",num_of_conf); + for (uint32_t i = 0; i < num_of_conf; i++) { + ConfigDescParser<0, 0, 0, 0> confDescrParser(this); + + delay(1); + rcode = pUsb->getConfDescr(bAddress, 0, i, &confDescrParser); + +#if defined(XOOM) + //added by Jaylen Scott Vanorden + if(rcode) { + TRACE_USBHOST(printf("ADK::Init : Got 1st bad code for config: %lu\r\n", rcode);) + + // Try once more + rcode = pUsb->getConfDescr(bAddress, 0, i, &confDescrParser); + } +#endif + if(rcode) { + goto FailGetConfDescr; + } + if(bNumEP > 2) { + break; + } + } // for (uint32_t i=0; isetEpInfoEntry(bAddress, 3, epInfo); + if(rcode) { + goto FailSetDevTblEntry; + } + } + + // Set Configuration Value + rcode = pUsb->setConf(bAddress, 0, bConfNum); + if(rcode) { + goto FailSetConfDescr; + } + /* print endpoint structure */ + + USBTRACE("\r\nEndpoint Structure:"); + USBTRACE("\r\nEP0:"); + USBTRACE2("\r\nAddr: ", epInfo[0].epAddr); + USBTRACE2("\r\nMax.pkt.size: ", epInfo[0].maxPktSize); + USBTRACE2("\r\nAttr: ", epInfo[0].epAttribs); + USBTRACE("\r\nEpout:"); + USBTRACE2("\r\nAddr: ", epInfo[epDataOutIndex].epAddr); + USBTRACE2("\r\nMax.pkt.size: ", epInfo[epDataOutIndex].maxPktSize); + USBTRACE2("\r\nAttr: ", epInfo[epDataOutIndex].epAttribs); + USBTRACE("\r\nEpin:"); + USBTRACE2("\r\nAddr: ", epInfo[epDataInIndex].epAddr); + USBTRACE2("\r\nMax.pkt.size: ", epInfo[epDataInIndex].maxPktSize); + USBTRACE2("\r\nAttr: ", epInfo[epDataInIndex].epAttribs); + + + USBTRACE("\r\nConfiguration successful"); + ready = true; + return 0; //successful configuration + }//if( buf->idVendor == ADK_VID... + + //probe device - get accessory protocol revision + { + uint32_t adkproto = 0; + delay(1); + //rcode = getProto((uint8_t*) & adkproto); // ADK_GETPROTO 0x33 + rcode = getProto((uint8_t*)buf); + +#if defined(XOOM) + //added by Jaylen Scott Vanorden + if(rcode) { + USBTRACE2("\r\nGot 1st bad code for proto: ", rcode); + // Try once more + rcode = getProto((uint8_t*) & adkproto); + } +#endif + if(rcode) { + goto FailGetProto; //init fails + } + adkproto = buf[0] | (buf[1]<<8); + USBTRACE2("\r\nADK protocol rev. ", adkproto); + } + + delay(100); + + //sending ID strings + // ADK_SENDSTR 0x34 + if( sendStr(ACCESSORY_STRING_MANUFACTURER, manufacturer) ) { + USBTRACE("\r\nPb ACCESSORY_STRING_MANUFACTURER"); } + delay(10); + if( sendStr(ACCESSORY_STRING_MODEL, model) ) { + USBTRACE("\r\nPb ACCESSORY_STRING_MODEL"); } + delay(10); + if( sendStr(ACCESSORY_STRING_DESCRIPTION, description) ) { + USBTRACE("\r\nPb ACCESSORY_STRING_DESCRIPTION"); } + delay(10); + if( sendStr(ACCESSORY_STRING_VERSION, version) ) { + USBTRACE("\r\nPb ACCESSORY_STRING_VERSION"); } + delay(10); + if( sendStr(ACCESSORY_STRING_URI, uri) ) { + USBTRACE("\r\nPb ACCESSORY_STRING_URI"); } + delay(10); + if( sendStr(ACCESSORY_STRING_SERIAL, serial) ) { + USBTRACE("\r\nPb ACCESSORY_STRING_SERIAL"); } + + delay(100); + + USBTRACE("\r\nSwitch to accessory mode"); + //switch to accessory mode + //the Android phone will reset + rcode = switchAcc(); + if(rcode) { + goto FailSwAcc; //init fails + } + rcode = USB_ERROR_CONFIG_REQUIRES_ADDITIONAL_RESET; + delay(100); // Give Android a chance to do its reset. This is a guess, and possibly could be lower. + goto SwAttempt; //switch to accessory mode attempted + + /* diagnostic messages */ +FailGetDevDescr: +#ifdef DEBUG_USB_HOST + NotifyFailGetDevDescr(rcode); + goto Fail; +#endif + +FailSetDevTblEntry: +#ifdef DEBUG_USB_HOST + NotifyFailSetDevTblEntry(rcode); + goto Fail; +#endif + +FailGetConfDescr: +#ifdef DEBUG_USB_HOST + NotifyFailGetConfDescr(rcode); + goto Fail; +#endif + +FailSetConfDescr: +#ifdef DEBUG_USB_HOST + NotifyFailSetConfDescr(rcode); + goto Fail; +#endif + +FailGetProto: +#ifdef DEBUG_USB_HOST + USBTRACE("\r\ngetProto:"); + goto Fail; +#endif + +FailSwAcc: +#ifdef DEBUG_USB_HOST + USBTRACE("\r\nswAcc:"); + goto Fail; +#endif + + //FailOnInit: + // USBTRACE("OnInit:"); + // goto Fail; + // +SwAttempt: +#ifdef DEBUG_USB_HOST + USBTRACE("\r\nAccessory mode switch attempt"); +Fail: +#endif + USBTRACE2("\r\nADK Init Failed, error code: ", rcode); + //NotifyFail(rcode); + Release(); + return rcode; +} + +/* Extracts bulk-IN and bulk-OUT endpoint information from config descriptor */ +void ADK::EndpointXtract(uint32_t conf, uint32_t /* iface */, uint32_t /* alt */, uint32_t /* proto */, const USB_ENDPOINT_DESCRIPTOR *pep) { + //ErrorMessage(PSTR("Conf.Val"), conf); + //ErrorMessage(PSTR("Iface Num"), iface); + //ErrorMessage(PSTR("Alt.Set"), alt); + + //added by Yuuichi Akagawa + if(bNumEP == 3) { + return; + } + + bConfNum = conf; + + if((pep->bmAttributes & 0x02) == 2) { + uint32_t index = ((pep->bEndpointAddress & 0x80) == 0x80) ? epDataInIndex : epDataOutIndex; + // Fill in the endpoint info structure + epInfo[index].epAddr = (pep->bEndpointAddress & 0x0F); + epInfo[index].maxPktSize = (uint8_t)pep->wMaxPacketSize; + epInfo[index].bmSndToggle = 0; + epInfo[index].bmRcvToggle = 0; + + bNumEP++; + + //PrintEndpointDescriptor(pep); + } +} + +/* Performs a cleanup after failed Init() attempt */ +uint32_t ADK::Release() { + pUsb->GetAddressPool().FreeAddress(bAddress); + + bNumEP = 1; //must have to be reset to 1 + + bAddress = 0; + ready = false; + return 0; +} + +uint32_t ADK::RcvData(uint8_t *bytes_rcvd, uint8_t *dataptr) { + USBTRACE2("\r\nAddr: ", bAddress ); + USBTRACE2("\r\nEP: ",epInfo[epDataInIndex].epAddr); + return pUsb->inTransfer(bAddress, epInfo[epDataInIndex].epAddr, bytes_rcvd, dataptr); +} + +uint32_t ADK::SndData(uint32_t nbytes, uint8_t *dataptr) { + return pUsb->outTransfer(bAddress, epInfo[epDataOutIndex].epAddr, nbytes, dataptr); +} + +void ADK::PrintEndpointDescriptor(const USB_ENDPOINT_DESCRIPTOR* ep_ptr) { + Notify(PSTR("Endpoint descriptor:"), 0x80); + Notify(PSTR("\r\nLength:\t\t"), 0x80); + PrintHex (ep_ptr->bLength, 0x80); + Notify(PSTR("\r\nType:\t\t"), 0x80); + PrintHex (ep_ptr->bDescriptorType, 0x80); + Notify(PSTR("\r\nAddress:\t"), 0x80); + PrintHex (ep_ptr->bEndpointAddress, 0x80); + Notify(PSTR("\r\nAttributes:\t"), 0x80); + PrintHex (ep_ptr->bmAttributes, 0x80); + Notify(PSTR("\r\nMaxPktSize:\t"), 0x80); + PrintHex (ep_ptr->wMaxPacketSize, 0x80); + Notify(PSTR("\r\nPoll Intrv:\t"), 0x80); + PrintHex (ep_ptr->bInterval, 0x80); + Notify(PSTR("\r\n"), 0x80); +} diff --git a/libraries/USBHost/src/adk.h b/libraries/USBHost/src/adk.h new file mode 100644 index 0000000..ffd22cf --- /dev/null +++ b/libraries/USBHost/src/adk.h @@ -0,0 +1,148 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com +*/ + +/* Google ADK interface support header */ + +#ifndef ADK_H_INCLUDED +#define ADK_H_INCLUDED + +#include +#include "Usb.h" +#include "hid.h" +#include "Arduino.h" + +// #define ADK_VID 0x18D1 +// #define ADK_PID 0x2D00 +// #define ADB_PID 0x2D01 + +// JCB +#define ADK_VID 0x04E8 +#define ADK_PID 0x685C +#define ADB_PID 0x685D + +#define XOOM //enables repeating getProto() and getConf() attempts + //necessary for slow devices such as Motorola XOOM + //defined by default, can be commented out to save memory + +/* requests */ + +#define ADK_GETPROTO 51 //check USB accessory protocol version 0x33 +#define ADK_SENDSTR 52 //send identifying string 0x34 +#define ADK_ACCSTART 53 //start device in accessory mode 0x35 + +#define bmREQ_ADK_GET USB_SETUP_DEVICE_TO_HOST|USB_SETUP_TYPE_VENDOR|USB_SETUP_RECIPIENT_DEVICE +#define bmREQ_ADK_SEND USB_SETUP_HOST_TO_DEVICE|USB_SETUP_TYPE_VENDOR|USB_SETUP_RECIPIENT_DEVICE + +#define ACCESSORY_STRING_MANUFACTURER 0 +#define ACCESSORY_STRING_MODEL 1 +#define ACCESSORY_STRING_DESCRIPTION 2 +#define ACCESSORY_STRING_VERSION 3 +#define ACCESSORY_STRING_URI 4 +#define ACCESSORY_STRING_SERIAL 5 + +#define ADK_MAX_ENDPOINTS 3 //endpoint 0, bulk_IN, bulk_OUT + +class ADK; + +class ADK : public USBDeviceConfig, public UsbConfigXtracter { +private: + /* ID strings */ + const char* manufacturer; + const char* model; + const char* description; + const char* version; + const char* uri; + const char* serial; + + /* ADK proprietary requests */ + uint32_t getProto(uint8_t* adkproto); + uint32_t sendStr(uint32_t index, const char* str); + uint32_t switchAcc(void); + +protected: + static const uint32_t epDataInIndex; // DataIn endpoint index + static const uint32_t epDataOutIndex; // DataOUT endpoint index + + /* Mandatory members */ + USBHost *pUsb; + uint32_t bAddress; // Device USB address + uint32_t bConfNum; // configuration number + + uint32_t bNumEP; // total number of EP in the configuration + uint32_t ready; + + /* Endpoint data structure */ + EpInfo epInfo[ADK_MAX_ENDPOINTS]; + + void PrintEndpointDescriptor(const USB_ENDPOINT_DESCRIPTOR* ep_ptr); + +public: + ADK(USBHost *pUsb, const char* manufacturer, + const char* model, + const char* description, + const char* version, + const char* uri, + const char* serial); + + // Methods for receiving and sending data + uint32_t RcvData(uint8_t *nbytesptr, uint8_t *dataptr); + uint32_t SndData(uint32_t nbytes, uint8_t *dataptr); + + + // USBDeviceConfig implementation + virtual uint32_t ConfigureDevice(uint32_t parent, uint32_t port, uint32_t lowspeed); + virtual uint32_t Init(uint32_t parent, uint32_t port, uint32_t lowspeed); + virtual uint32_t Release(); + + virtual uint32_t Poll() { + return 0; + }; + + virtual uint32_t GetAddress() { + return bAddress; + }; + + virtual uint32_t isReady() { + return ready; + }; + + virtual uint32_t VIDPIDOK(uint32_t vid, uint32_t pid) { + return (vid == ADK_VID && (pid == ADK_PID || pid == ADB_PID)); + }; + + //UsbConfigXtracter implementation + virtual void EndpointXtract(uint32_t conf, uint32_t iface, uint32_t alt, uint32_t proto, const USB_ENDPOINT_DESCRIPTOR *ep); +}; //class ADK : public USBDeviceConfig ... + +/* get ADK protocol version */ + +/* returns 2 bytes in *adkproto */ +inline uint32_t ADK::getProto(uint8_t* adkproto) { + return ( pUsb->ctrlReq(bAddress, 0, bmREQ_ADK_GET, ADK_GETPROTO, 0, 0, 0, 2, 2, adkproto, NULL)); +} + +/* send ADK string */ +inline uint32_t ADK::sendStr(uint32_t index, const char* str) { + return ( pUsb->ctrlReq(bAddress, 0, bmREQ_ADK_SEND, ADK_SENDSTR, 0, 0, index, strlen(str) + 1, strlen(str) + 1, (uint8_t*)str, NULL)); +} + +/* switch to accessory mode */ +inline uint32_t ADK::switchAcc(void) { + return ( pUsb->ctrlReq(bAddress, 0, bmREQ_ADK_SEND, ADK_ACCSTART, 0, 0, 0, 0, 0, NULL, NULL)); +} + +#endif /* ADK_H_INCLUDED */ diff --git a/libraries/USBHost/src/confdescparser.h b/libraries/USBHost/src/confdescparser.h new file mode 100644 index 0000000..4b2b41b --- /dev/null +++ b/libraries/USBHost/src/confdescparser.h @@ -0,0 +1,223 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com +*/ + +#if !defined(_usb_h_) || defined(__CONFDESCPARSER_H__) +#error "Never include confdescparser.h directly; include Usb.h instead" +#else + +#define __CONFDESCPARSER_H__ + +#include + +//#define TRACE_USBHOST(x) x +#define TRACE_USBHOST(x) + +class UsbConfigXtracter { +public: + //virtual void ConfigXtract(const USB_CONFIGURATION_DESCRIPTOR *conf) = 0; + //virtual void InterfaceXtract(uint32_t conf, const USB_INTERFACE_DESCRIPTOR *iface) = 0; + virtual void EndpointXtract(uint32_t conf, uint32_t iface, uint32_t alt, uint32_t proto, const USB_ENDPOINT_DESCRIPTOR *ep) = 0; +}; + +#define CP_MASK_COMPARE_CLASS 1 +#define CP_MASK_COMPARE_SUBCLASS 2 +#define CP_MASK_COMPARE_PROTOCOL 4 +#define CP_MASK_COMPARE_ALL 7 + +// Configuration Descriptor Parser Class Template + +template +class ConfigDescParser : public USBReadParser { + UsbConfigXtracter *theXtractor; + MultiValueBuffer theBuffer; + MultiByteValueParser valParser; + ByteSkipper theSkipper; + uint8_t varBuffer[16 /*sizeof(USB_CONFIGURATION_DESCRIPTOR)*/]; + + uint32_t stateParseDescr; // ParseDescriptor state + + uint32_t dscrLen; // Descriptor length + uint32_t dscrType; // Descriptor type + + bool isGoodInterface; // Apropriate interface flag + uint32_t confValue; // Configuration value + uint32_t protoValue; // Protocol value + uint32_t ifaceNumber; // Interface number + uint32_t ifaceAltSet; // Interface alternate settings + + bool UseOr; + bool ParseDescriptor(uint8_t **pp, uint32_t *pcntdn); + void PrintHidDescriptor(const USB_HID_DESCRIPTOR *pDesc); + +public: + + void SetOR(void) { + UseOr = true; + } + ConfigDescParser(UsbConfigXtracter *xtractor); + virtual void Parse(const uint32_t len, const uint8_t *pbuf, const uint32_t &offset); +}; + +template +ConfigDescParser::ConfigDescParser(UsbConfigXtracter *xtractor) : + theXtractor(xtractor), + stateParseDescr(0), + dscrLen(0), + dscrType(0), +UseOr(false) { + theBuffer.pValue = varBuffer; + valParser.Initialize(&theBuffer); + theSkipper.Initialize(&theBuffer); +}; + +template +void ConfigDescParser::Parse(const uint32_t len, const uint8_t *pbuf, const uint32_t & /* offset */) { + uint32_t cntdn = len; + uint8_t *p = (uint8_t*)pbuf; + + while (cntdn) + if(!ParseDescriptor(&p, &cntdn)) + return; +} + +/* Parser for the configuration descriptor. Takes values for class, subclass, protocol fields in interface descriptor and + compare masks for them. When the match is found, calls EndpointXtract passing buffer containing endpoint descriptor */ +template +bool ConfigDescParser::ParseDescriptor(uint8_t **pp, uint32_t *pcntdn) { + USB_CONFIGURATION_DESCRIPTOR* ucd = reinterpret_cast(varBuffer); + USB_INTERFACE_DESCRIPTOR* uid = reinterpret_cast(varBuffer); + switch(stateParseDescr) { + case 0: + theBuffer.valueSize = 2; + valParser.Initialize(&theBuffer); + stateParseDescr = 1; + case 1: + if(!valParser.Parse(pp, pcntdn)) + return false; + dscrLen = *((uint8_t*)theBuffer.pValue); + dscrType = *((uint8_t*)theBuffer.pValue + 1); + stateParseDescr = 2; + case 2: + // This is a sort of hack. Assuming that two bytes are all ready in the buffer + // the pointer is positioned two bytes ahead in order for the rest of descriptor + // to be read right after the size and the type fields. + // This should be used carefully. varBuffer should be used directly to handle data + // in the buffer. + theBuffer.pValue = varBuffer + 2; + stateParseDescr = 3; + case 3: + switch(dscrType) { + case USB_DESCRIPTOR_INTERFACE: + isGoodInterface = false; + case USB_DESCRIPTOR_CONFIGURATION: + theBuffer.valueSize = sizeof (USB_CONFIGURATION_DESCRIPTOR) - 2; + break; + case USB_DESCRIPTOR_ENDPOINT: + theBuffer.valueSize = sizeof (USB_ENDPOINT_DESCRIPTOR) - 2; + break; + case HID_DESCRIPTOR_HID: + theBuffer.valueSize = dscrLen - 2; + break; + } + valParser.Initialize(&theBuffer); + stateParseDescr = 4; + case 4: + switch(dscrType) { + case USB_DESCRIPTOR_CONFIGURATION: + if(!valParser.Parse(pp, pcntdn)) + return false; + confValue = ucd->bConfigurationValue; + break; + case USB_DESCRIPTOR_INTERFACE: + if(!valParser.Parse(pp, pcntdn)) + return false; + if((MASK & CP_MASK_COMPARE_CLASS) && uid->bInterfaceClass != CLASS_ID) + break; + if((MASK & CP_MASK_COMPARE_SUBCLASS) && uid->bInterfaceSubClass != SUBCLASS_ID) + break; + if(UseOr) { + if((!((MASK & CP_MASK_COMPARE_PROTOCOL) && uid->bInterfaceProtocol))) + break; + } else { + if((MASK & CP_MASK_COMPARE_PROTOCOL) && uid->bInterfaceProtocol != PROTOCOL_ID) + break; + } + isGoodInterface = true; + ifaceNumber = uid->bInterfaceNumber; + ifaceAltSet = uid->bAlternateSetting; + protoValue = uid->bInterfaceProtocol; + break; + case USB_DESCRIPTOR_ENDPOINT: + if(!valParser.Parse(pp, pcntdn)) + return false; + if(isGoodInterface) + if(theXtractor) + theXtractor->EndpointXtract(confValue, ifaceNumber, ifaceAltSet, protoValue, (USB_ENDPOINT_DESCRIPTOR*)varBuffer); + break; + //case HID_DESCRIPTOR_HID: + // if (!valParser.Parse(pp, pcntdn)) + // return false; + // PrintHidDescriptor((const USB_HID_DESCRIPTOR*)varBuffer); + // break; + default: + if(!theSkipper.Skip(pp, pcntdn, dscrLen - 2)) + return false; + } + theBuffer.pValue = varBuffer; + stateParseDescr = 0; + } + return true; +} + +template +void ConfigDescParser::PrintHidDescriptor(const USB_HID_DESCRIPTOR *pDesc) { + Notify(PSTR("\r\n\r\nHID Descriptor:\r\n"), 0x80); + Notify(PSTR("bDescLength:\t\t"), 0x80); + PrintHex (pDesc->bLength, 0x80); + + Notify(PSTR("\r\nbDescriptorType:\t"), 0x80); + PrintHex (pDesc->bDescriptorType, 0x80); + + Notify(PSTR("\r\nbcdHID:\t\t\t"), 0x80); + PrintHex (pDesc->bcdHID, 0x80); + + Notify(PSTR("\r\nbCountryCode:\t\t"), 0x80); + PrintHex (pDesc->bCountryCode, 0x80); + + Notify(PSTR("\r\nbNumDescriptors:\t"), 0x80); + PrintHex (pDesc->bNumDescriptors, 0x80); + + //Notify(PSTR("\r\nbDescrType:\t\t")); + //PrintHex(pDesc->bDescrType); + // + //Notify(PSTR("\r\nwDescriptorLength:\t")); + //PrintHex(pDesc->wDescriptorLength); + + for (uint32_t i = 0; i < pDesc->bNumDescriptors; i++) { + HID_CLASS_DESCRIPTOR_LEN_AND_TYPE *pLT = (HID_CLASS_DESCRIPTOR_LEN_AND_TYPE*)&(pDesc->bDescrType); + + Notify(PSTR("\r\nbDescrType:\t\t"), 0x80); + PrintHex (pLT[i].bDescrType, 0x80); + + Notify(PSTR("\r\nwDescriptorLength:\t"), 0x80); + PrintHex (pLT[i].wDescriptorLength, 0x80); + } + Notify(PSTR("\r\n"), 0x80); +} + + +#endif // __CONFDESCPARSER_H__ diff --git a/libraries/USBHost/src/hexdump.h b/libraries/USBHost/src/hexdump.h new file mode 100644 index 0000000..3818d85 --- /dev/null +++ b/libraries/USBHost/src/hexdump.h @@ -0,0 +1,61 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com + */ +#if !defined(_usb_h_) || defined(__HEXDUMP_H__) +#error "Never include hexdump.h directly; include Usb.h instead" +#else +#define __HEXDUMP_H__ + +extern int UsbDEBUGlvl; + +template +class HexDumper : public BASE_CLASS { + uint8_t byteCount; + OFFSET_TYPE byteTotal; + +public: + + HexDumper() : byteCount(0), byteTotal(0) { + }; + + void Initialize() { + byteCount = 0; + byteTotal = 0; + }; + + virtual void Parse(const LEN_TYPE len, const uint8_t *pbuf, const OFFSET_TYPE &offset); +}; + +template +void HexDumper::Parse(const LEN_TYPE len, const uint8_t *pbuf, const OFFSET_TYPE &offset) { + if(UsbDEBUGlvl >= 0x80) { // Fully bypass this block of code if we do not debug. + for(LEN_TYPE j = 0; j < len; j++, byteCount++, byteTotal++) { + if(!byteCount) { + PrintHex (byteTotal, 0x80); + E_Notify(PSTR(": "), 0x80); + } + PrintHex (pbuf[j], 0x80); + E_Notify(PSTR(" "), 0x80); + + if(byteCount == 15) { + E_Notify(PSTR("\r\n"), 0x80); + byteCount = 0xFF; + } + } + } +} + +#endif // __HEXDUMP_H__ diff --git a/libraries/USBHost/src/hid.cpp b/libraries/USBHost/src/hid.cpp new file mode 100644 index 0000000..40b08dd --- /dev/null +++ b/libraries/USBHost/src/hid.cpp @@ -0,0 +1,112 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com + */ + +#include "hid.h" + +//get HID report descriptor + +/* WRONG! Endpoint is _ALWAYS_ ZERO for HID! We want the _INTERFACE_ value here! +uint32_t HID::GetReportDescr(uint32_t ep, USBReadParser *parser) { + const uint8_t constBufLen = 64; + uint8_t buf[constBufLen]; + + uint8_t rcode = pUsb->ctrlReq(bAddress, ep, bmREQ_HIDREPORT, USB_REQUEST_GET_DESCRIPTOR, 0x00, + HID_DESCRIPTOR_REPORT, 0x0000, 128, constBufLen, buf, (USBReadParser*)parser); + + //return ((rcode != hrSTALL) ? rcode : 0); + return rcode; +} + */ +uint32_t HID::GetReportDescr(uint32_t wIndex, USBReadParser *parser) { + const uint8_t constBufLen = 128; + uint8_t buf[constBufLen]; + + uint8_t rcode = pUsb->ctrlReq(bAddress, 0x00, bmREQ_HIDREPORT, USB_REQUEST_GET_DESCRIPTOR, 0x00, + HID_DESCRIPTOR_REPORT, wIndex, 128, constBufLen, buf, (USBReadParser*)parser); + + //return ((rcode != hrSTALL) ? rcode : 0); + return rcode; +} + +//uint32_t HID::getHidDescr( uint8_t ep, uint16_t nbytes, uint8_t* dataptr ) +//{ +// return( pUsb->ctrlReq( bAddress, ep, bmREQ_GET_DESCR, USB_REQUEST_GET_DESCRIPTOR, 0x00, HID_DESCRIPTOR_HID, 0x0000, nbytes, dataptr )); +//} + +uint32_t HID::SetReport(uint32_t ep, uint32_t iface, uint32_t report_type, uint32_t report_id, uint32_t nbytes, uint8_t* dataptr) { + return ( pUsb->ctrlReq(bAddress, ep, bmREQ_HIDOUT, HID_REQUEST_SET_REPORT, report_id, report_type, iface, nbytes, nbytes, dataptr, NULL)); +} + +uint32_t HID::GetReport(uint32_t ep, uint32_t iface, uint32_t report_type, uint32_t report_id, uint32_t nbytes, uint8_t* dataptr) { + return ( pUsb->ctrlReq(bAddress, ep, bmREQ_HIDIN, HID_REQUEST_GET_REPORT, report_id, report_type, iface, nbytes, nbytes, dataptr, NULL)); +} + +uint32_t HID::GetIdle(uint32_t iface, uint32_t reportID, uint8_t* dataptr) { + return ( pUsb->ctrlReq(bAddress, 0, bmREQ_HIDIN, HID_REQUEST_GET_IDLE, reportID, 0, iface, 0x0001, 0x0001, dataptr, NULL)); +} + +uint32_t HID::SetIdle(uint32_t iface, uint32_t reportID, uint32_t duration) { + return ( pUsb->ctrlReq(bAddress, 0, bmREQ_HIDOUT, HID_REQUEST_SET_IDLE, reportID, duration, iface, 0x0000, 0x0000, NULL, NULL)); +} + +uint32_t HID::SetProtocol(uint32_t iface, uint32_t protocol) { + return ( pUsb->ctrlReq(bAddress, 0, bmREQ_HIDOUT, HID_REQUEST_SET_PROTOCOL, protocol, 0x00, iface, 0x0000, 0x0000, NULL, NULL)); +} + +uint32_t HID::GetProtocol(uint32_t iface, uint8_t* dataptr) { + return ( pUsb->ctrlReq(bAddress, 0, bmREQ_HIDIN, HID_REQUEST_GET_PROTOCOL, 0x00, 0x00, iface, 0x0001, 0x0001, dataptr, NULL)); +} + +void HID::PrintEndpointDescriptor(const USB_ENDPOINT_DESCRIPTOR* ep_ptr) { + Notify(PSTR("Endpoint descriptor:"), 0x80); + Notify(PSTR("\r\nLength:\t\t"), 0x80); + D_PrintHex (ep_ptr->bLength, 0x80); + Notify(PSTR("\r\nType:\t\t"), 0x80); + D_PrintHex (ep_ptr->bDescriptorType, 0x80); + Notify(PSTR("\r\nAddress:\t"), 0x80); + D_PrintHex (ep_ptr->bEndpointAddress, 0x80); + Notify(PSTR("\r\nAttributes:\t"), 0x80); + D_PrintHex (ep_ptr->bmAttributes, 0x80); + Notify(PSTR("\r\nMaxPktSize:\t"), 0x80); + D_PrintHex (ep_ptr->wMaxPacketSize, 0x80); + Notify(PSTR("\r\nPoll Intrv:\t"), 0x80); + D_PrintHex (ep_ptr->bInterval, 0x80); +} + +void HID::PrintHidDescriptor(const USB_HID_DESCRIPTOR *pDesc) { + Notify(PSTR("\r\n\r\nHID Descriptor:\r\n"), 0x80); + Notify(PSTR("bDescLength:\t\t"), 0x80); + D_PrintHex (pDesc->bLength, 0x80); + + Notify(PSTR("\r\nbDescriptorType:\t"), 0x80); + D_PrintHex (pDesc->bDescriptorType, 0x80); + + Notify(PSTR("\r\nbcdHID:\t\t\t"), 0x80); + D_PrintHex (pDesc->bcdHID, 0x80); + + Notify(PSTR("\r\nbCountryCode:\t\t"), 0x80); + D_PrintHex (pDesc->bCountryCode, 0x80); + + Notify(PSTR("\r\nbNumDescriptors:\t"), 0x80); + D_PrintHex (pDesc->bNumDescriptors, 0x80); + + Notify(PSTR("\r\nbDescrType:\t\t"), 0x80); + D_PrintHex (pDesc->bDescrType, 0x80); + + Notify(PSTR("\r\nwDescriptorLength:\t"), 0x80); + D_PrintHex (pDesc->wDescriptorLength, 0x80); +} diff --git a/libraries/USBHost/src/hid.h b/libraries/USBHost/src/hid.h new file mode 100644 index 0000000..ca697a5 --- /dev/null +++ b/libraries/USBHost/src/hid.h @@ -0,0 +1,183 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com +*/ +#if !defined(__HID_H__) +#define __HID_H__ + +#include "Usb.h" +#include "hidusagestr.h" + +#define MAX_REPORT_PARSERS 2 +#define HID_MAX_HID_CLASS_DESCRIPTORS 5 + +#define DATA_SIZE_MASK 0x03 +#define TYPE_MASK 0x0C +#define TAG_MASK 0xF0 + +#define DATA_SIZE_0 0x00 +#define DATA_SIZE_1 0x01 +#define DATA_SIZE_2 0x02 +#define DATA_SIZE_4 0x03 + +#define TYPE_MAIN 0x00 +#define TYPE_GLOBAL 0x04 +#define TYPE_LOCAL 0x08 + +#define TAG_MAIN_INPUT 0x80 +#define TAG_MAIN_OUTPUT 0x90 +#define TAG_MAIN_COLLECTION 0xA0 +#define TAG_MAIN_FEATURE 0xB0 +#define TAG_MAIN_ENDCOLLECTION 0xC0 + +#define TAG_GLOBAL_USAGEPAGE 0x00 +#define TAG_GLOBAL_LOGICALMIN 0x10 +#define TAG_GLOBAL_LOGICALMAX 0x20 +#define TAG_GLOBAL_PHYSMIN 0x30 +#define TAG_GLOBAL_PHYSMAX 0x40 +#define TAG_GLOBAL_UNITEXP 0x50 +#define TAG_GLOBAL_UNIT 0x60 +#define TAG_GLOBAL_REPORTSIZE 0x70 +#define TAG_GLOBAL_REPORTID 0x80 +#define TAG_GLOBAL_REPORTCOUNT 0x90 +#define TAG_GLOBAL_PUSH 0xA0 +#define TAG_GLOBAL_POP 0xB0 + +#define TAG_LOCAL_USAGE 0x00 +#define TAG_LOCAL_USAGEMIN 0x10 +#define TAG_LOCAL_USAGEMAX 0x20 + +/* HID requests */ +#define bmREQ_HIDOUT USB_SETUP_HOST_TO_DEVICE|USB_SETUP_TYPE_CLASS|USB_SETUP_RECIPIENT_INTERFACE +#define bmREQ_HIDIN USB_SETUP_DEVICE_TO_HOST|USB_SETUP_TYPE_CLASS|USB_SETUP_RECIPIENT_INTERFACE +#define bmREQ_HIDREPORT USB_SETUP_DEVICE_TO_HOST|USB_SETUP_TYPE_STANDARD|USB_SETUP_RECIPIENT_INTERFACE + +/* HID constants. Not part of chapter 9 */ +/* Class-Specific Requests */ +#define HID_REQUEST_GET_REPORT 0x01 +#define HID_REQUEST_GET_IDLE 0x02 +#define HID_REQUEST_GET_PROTOCOL 0x03 +#define HID_REQUEST_SET_REPORT 0x09 +#define HID_REQUEST_SET_IDLE 0x0A +#define HID_REQUEST_SET_PROTOCOL 0x0B + +/* Class Descriptor Types */ +#define HID_DESCRIPTOR_HID 0x21 +#define HID_DESCRIPTOR_REPORT 0x22 +#define HID_DESRIPTOR_PHY 0x23 + +/* Protocol Selection */ +#define HID_BOOT_PROTOCOL 0x00 +#define HID_RPT_PROTOCOL 0x01 + +/* HID Interface Class Code */ +#define HID_INTF 0x03 + +/* HID Interface Class SubClass Codes */ +#define HID_BOOT_INTF_SUBCLASS 0x01 + +/* HID Interface Class Protocol Codes */ +#define HID_PROTOCOL_NONE 0x00 +#define HID_PROTOCOL_KEYBOARD 0x01 +#define HID_PROTOCOL_MOUSE 0x02 + +#define HID_ITEM_TYPE_MAIN 0 +#define HID_ITEM_TYPE_GLOBAL 1 +#define HID_ITEM_TYPE_LOCAL 2 +#define HID_ITEM_TYPE_RESERVED 3 + +#define HID_LONG_ITEM_PREFIX 0xfe // Long item prefix value + +#define bmHID_MAIN_ITEM_TAG 0xfc // Main item tag mask + +#define bmHID_MAIN_ITEM_INPUT 0x80 // Main item Input tag value +#define bmHID_MAIN_ITEM_OUTPUT 0x90 // Main item Output tag value +#define bmHID_MAIN_ITEM_FEATURE 0xb0 // Main item Feature tag value +#define bmHID_MAIN_ITEM_COLLECTION 0xa0 // Main item Collection tag value +#define bmHID_MAIN_ITEM_END_COLLECTION 0xce // Main item End Collection tag value + +#define HID_MAIN_ITEM_COLLECTION_PHYSICAL 0 +#define HID_MAIN_ITEM_COLLECTION_APPLICATION 1 +#define HID_MAIN_ITEM_COLLECTION_LOGICAL 2 +#define HID_MAIN_ITEM_COLLECTION_REPORT 3 +#define HID_MAIN_ITEM_COLLECTION_NAMED_ARRAY 4 +#define HID_MAIN_ITEM_COLLECTION_USAGE_SWITCH 5 +#define HID_MAIN_ITEM_COLLECTION_USAGE_MODIFIER 6 + +struct HidItemPrefix { + uint8_t bSize : 2; + uint8_t bType : 2; + uint8_t bTag : 4; +}; + +struct MainItemIOFeature { + uint8_t bmIsConstantOrData : 1; + uint8_t bmIsArrayOrVariable : 1; + uint8_t bmIsRelativeOrAbsolute : 1; + uint8_t bmIsWrapOrNoWrap : 1; + uint8_t bmIsNonLonearOrLinear : 1; + uint8_t bmIsNoPreferedOrPrefered : 1; + uint8_t bmIsNullOrNoNull : 1; + uint8_t bmIsVolatileOrNonVolatile : 1; +}; + +class HID; + +class HIDReportParser { +public: + virtual void Parse(HID *hid, uint32_t is_rpt_id, uint32_t len, uint8_t *buf)= 0; +}; + +class HID : public USBDeviceConfig, public UsbConfigXtracter { +protected: + USBHost *pUsb; // USB class instance pointer + uint32_t bAddress; // address + +protected: + static const uint32_t epInterruptInIndex = 1; // InterruptIN endpoint index + static const uint32_t epInterruptOutIndex = 2; // InterruptOUT endpoint index + + static const uint32_t maxHidInterfaces = 3; + static const uint32_t maxEpPerInterface = 2; + static const uint32_t totalEndpoints = (maxHidInterfaces * maxEpPerInterface + 1); + + void PrintEndpointDescriptor(const USB_ENDPOINT_DESCRIPTOR* ep_ptr); + void PrintHidDescriptor(const USB_HID_DESCRIPTOR *pDesc); + + virtual HIDReportParser* GetReportParser(uint32_t id); + +public: + + HID(USBHost *pusb) : pUsb(pusb) { + }; + + const USBHost* GetUsb() { + return pUsb; + }; + virtual uint32_t SetReportParser(uint32_t id, HIDReportParser *prs); + + uint32_t SetProtocol(uint32_t iface, uint32_t protocol); + uint32_t GetProtocol(uint32_t iface, uint8_t* dataptr); + uint32_t GetIdle(uint32_t iface, uint32_t reportID, uint8_t* dataptr); + uint32_t SetIdle(uint32_t iface, uint32_t reportID, uint32_t duration); + + uint32_t GetReportDescr(uint32_t ep, USBReadParser *parser = NULL); + + uint32_t GetHidDescr(uint32_t ep, uint32_t nbytes, uint8_t* dataptr); + uint32_t GetReport(uint32_t ep, uint32_t iface, uint32_t report_type, uint32_t report_id, uint32_t nbytes, uint8_t* dataptr); + uint32_t SetReport(uint32_t ep, uint32_t iface, uint32_t report_type, uint32_t report_id, uint32_t nbytes, uint8_t* dataptr); +}; + +#endif // __HID_H__ diff --git a/libraries/USBHost/src/hidboot.cpp b/libraries/USBHost/src/hidboot.cpp new file mode 100644 index 0000000..f477d2c --- /dev/null +++ b/libraries/USBHost/src/hidboot.cpp @@ -0,0 +1,240 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com +*/ +#include "hidboot.h" + +void MouseReportParser::Parse(HID * /* hid */, uint32_t /* is_rpt_id */, uint32_t /* len */, uint8_t *buf) { + MOUSEINFO *pmi = (MOUSEINFO*)buf; + // Future: + // bool event; + +#if 0 + if (prevState.mouseInfo.bmLeftButton == 0 && pmi->bmLeftButton == 1) + OnLeftButtonDown(pmi); + + if (prevState.mouseInfo.bmLeftButton == 1 && pmi->bmLeftButton == 0) + OnLeftButtonUp(pmi); + + if (prevState.mouseInfo.bmRightButton == 0 && pmi->bmRightButton == 1) + OnRightButtonDown(pmi); + + if (prevState.mouseInfo.bmRightButton == 1 && pmi->bmRightButton == 0) + OnRightButtonUp(pmi); + + if (prevState.mouseInfo.bmMiddleButton == 0 && pmi->bmMiddleButton == 1) + OnMiddleButtonDown(pmi); + + if (prevState.mouseInfo.bmMiddleButton == 1 && pmi->bmMiddleButton == 0) + OnMiddleButtonUp(pmi); + + if (prevState.mouseInfo.dX != pmi->dX || prevState.mouseInfo.dY != pmi->dY) + OnMouseMove(pmi); + + if (len > sizeof (MOUSEINFO)) + for (uint32_t i = 0; ibmLeftButton ) { + if(pmi->bmLeftButton) { + OnLeftButtonDown(pmi); + } else { + OnLeftButtonUp(pmi); + } + // Future: + // event = true; + } + + if(prevState.mouseInfo.bmRightButton != pmi->bmRightButton) { + if(pmi->bmRightButton) { + OnRightButtonDown(pmi); + } else { + OnRightButtonUp(pmi); + } + // Future: + // event = true; + } + + if(prevState.mouseInfo.bmMiddleButton != pmi->bmMiddleButton) { + if(pmi->bmMiddleButton) { + OnMiddleButtonDown(pmi); + } else { + OnMiddleButtonUp(pmi); + } + // Future: + // event = true; + } + + // + // Scroll wheel(s), are not part of the spec, but we could support it. + // Logitech wireless keyboard and mouse combo reports scroll wheel in byte 4 + // We wouldn't even need to save this information. + //if(len > 3) { + //} + // + + // Mice only report motion when they actually move! + // Why not just pass the x/y values to simplify things?? + if(pmi->dX || pmi->dY) { + OnMouseMove(pmi); + // Future: + // event = true; + } + + // + // Future: + // Provide a callback that operates on the gathered events from above. + // + // if(event) OnMouse(); + // + + // Only the first byte matters (buttons). We do NOT need to save position info. + prevState.bInfo[0] = buf[0]; +#endif + +}; + +void KeyboardReportParser::Parse(HID *hid, uint32_t /* is_rpt_id */, uint32_t /* len */, uint8_t *buf) { + // On error - return + if (buf[2] == 1) + return; + + //KBDINFO *pki = (KBDINFO*)buf; + + // provide event for changed control key state + if (prevState.bInfo[0x00] != buf[0x00]) { + OnControlKeysChanged(prevState.bInfo[0x00], buf[0x00]); + } + + for (uint32_t i = 2; i < 8; i++) { + bool down = false; + bool up = false; + + for (uint8_t j = 2; j < 8; j++) { + if (buf[i] == prevState.bInfo[j] && buf[i] != 1) + down = true; + if (buf[j] == prevState.bInfo[i] && prevState.bInfo[i] != 1) + up = true; + } + if (!down) { + HandleLockingKeys(hid, buf[i]); + OnKeyDown(*buf, buf[i]); + } + if (!up) + OnKeyUp(prevState.bInfo[0], prevState.bInfo[i]); + } + for(uint32_t i = 0; i < 8; i++) + prevState.bInfo[i] = buf[i]; +}; + +uint8_t KeyboardReportParser::HandleLockingKeys(HID *hid, uint8_t key) { + uint8_t old_keys = kbdLockingKeys.bLeds; + + switch (key) { + case UHS_HID_BOOT_KEY_NUM_LOCK: + kbdLockingKeys.kbdLeds.bmNumLock = ~kbdLockingKeys.kbdLeds.bmNumLock; + break; + case UHS_HID_BOOT_KEY_CAPS_LOCK: + kbdLockingKeys.kbdLeds.bmCapsLock = ~kbdLockingKeys.kbdLeds.bmCapsLock; + break; + case UHS_HID_BOOT_KEY_SCROLL_LOCK: + kbdLockingKeys.kbdLeds.bmScrollLock = ~kbdLockingKeys.kbdLeds.bmScrollLock; + break; + } + + if (old_keys != kbdLockingKeys.bLeds && hid) + return (hid->SetReport(0, 0/*hid->GetIface()*/, 2, 0, 1, &kbdLockingKeys.bLeds)); + + return 0; +} + +const uint8_t KeyboardReportParser::numKeys[10] = { '!', '@', '#', '$', '%', '^', '&', '*', '(', ')'}; +const uint8_t KeyboardReportParser::symKeysUp[12] = { '_', '+', '{', '}', '|', '~', ':', '"', '~', '<', '>', '?'}; +const uint8_t KeyboardReportParser::symKeysLo[12] = { '-', '=', '[', ']', '\\', ' ', ';', '\'', '`', ',', '.', '/'}; +const uint8_t KeyboardReportParser::padKeys[5] = { '/', '*', '-', '+', 0x0d}; +#define VALUE_WITHIN(v,l,h) (((v)>=(l)) && ((v)<=(h))) +uint8_t KeyboardReportParser::OemToAscii(uint8_t mod, uint8_t key) { + uint8_t shift = (mod & 0x22); + uint8_t ctrl = (mod & 0x11); + + // [a-z] + if (VALUE_WITHIN(key, 0x04, 0x1d)) { + // [^a-^z] + if (ctrl) return (key - 3); + // Upper case letters + if ((kbdLockingKeys.kbdLeds.bmCapsLock == 0 && shift) || + (kbdLockingKeys.kbdLeds.bmCapsLock == 1 && shift == 0)) + return (key - 4 + 'A'); + + // Lower case letters + else + return (key - 4 + 'a'); + }// Numbers + else if (VALUE_WITHIN(key, 0x1e, 0x27)) { + if (ctrl && (key == 0x23)) return (0x1E); /* RS ^^ */ + if (shift) + return ((uint8_t)pgm_read_byte(&getNumKeys()[key - 0x1e])); + else + return ((key == UHS_HID_BOOT_KEY_ZERO) ? '0' : key - 0x1e + '1'); + }// Keypad Numbers + else if(VALUE_WITHIN(key, 0x59, 0x61)) { + if(kbdLockingKeys.kbdLeds.bmNumLock == 1) + return (key - 0x59 + '1'); + } else if(VALUE_WITHIN(key, 0x2d, 0x38)) { + if (ctrl) { + switch (key) { + case 0x2d: return (0x1f); /* US ^_ */ + case 0x2f: return (0x1b); /* ESC ^[ */ + case 0x30: return (0x1d); /* GS ^] */ + case 0x31: return (0x1c); /* FS ^\ */ + default: return (0x00); + } + } + return ((shift) ? (uint8_t)pgm_read_byte(&getSymKeysUp()[key - 0x2d]) : (uint8_t)pgm_read_byte(&getSymKeysLo()[key - 0x2d])); + } else if(VALUE_WITHIN(key, 0x54, 0x58)) + return (uint8_t)pgm_read_byte(&getPadKeys()[key - 0x54]); + else { + switch(key) { + case UHS_HID_BOOT_KEY_SPACE: return (0x20); + case UHS_HID_BOOT_KEY_ENTER: return (0x0d); + case UHS_HID_BOOT_KEY_ESCAPE: return (0x1b); + case UHS_HID_BOOT_KEY_DELETE: return (0x08); + case UHS_HID_BOOT_KEY_DELETE_FORWARD: return (0x7f); + case UHS_HID_BOOT_KEY_TAB: return (0x09); + case UHS_HID_BOOT_KEY_ZERO2: return ((kbdLockingKeys.kbdLeds.bmNumLock == 1) ? '0': 0); + case UHS_HID_BOOT_KEY_PERIOD: return ((kbdLockingKeys.kbdLeds.bmNumLock == 1) ? '.': 0); + } + } + return ( 0); +} + diff --git a/libraries/USBHost/src/hidboot.h b/libraries/USBHost/src/hidboot.h new file mode 100644 index 0000000..5046129 --- /dev/null +++ b/libraries/USBHost/src/hidboot.h @@ -0,0 +1,611 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com +*/ + +#ifndef HIDBOOT_H_INCLUDED +#define HIDBOOT_H_INCLUDED + +#include +#include "Usb.h" +#include "hid.h" +#include "Arduino.h" + +#define UHS_HID_BOOT_KEY_ZERO 0x27 +#define UHS_HID_BOOT_KEY_ENTER 0x28 +#define UHS_HID_BOOT_KEY_ESCAPE 0x29 +#define UHS_HID_BOOT_KEY_DELETE 0x2a // Backspace +#define UHS_HID_BOOT_KEY_DELETE_FORWARD 0x4C // Delete +#define UHS_HID_BOOT_KEY_TAB 0x2b +#define UHS_HID_BOOT_KEY_SPACE 0x2c +#define UHS_HID_BOOT_KEY_CAPS_LOCK 0x39 +#define UHS_HID_BOOT_KEY_SCROLL_LOCK 0x47 +#define UHS_HID_BOOT_KEY_NUM_LOCK 0x53 +#define UHS_HID_BOOT_KEY_ZERO2 0x62 +#define UHS_HID_BOOT_KEY_PERIOD 0x63 + +// Don't worry, GCC will optimize the result to a final value. +#define bitsEndpoints(p) ((((p) & HID_PROTOCOL_KEYBOARD)? 2 : 0) | (((p) & HID_PROTOCOL_MOUSE)? 1 : 0)) +#define totalEndpoints(p) ((bitsEndpoints(p) == 3) ? 3 : 2) +#define epMUL(p) ((((p) & HID_PROTOCOL_KEYBOARD)? 1 : 0) + (((p) & HID_PROTOCOL_MOUSE)? 1 : 0)) + +// Already defined in hid.h +// #define HID_MAX_HID_CLASS_DESCRIPTORS 5 + +struct MOUSEINFO { + + struct { + uint8_t bmLeftButton : 1; + uint8_t bmRightButton : 1; + uint8_t bmMiddleButton : 1; + uint8_t bmDummy : 5; + }; + int8_t dX; + int8_t dY; +}; + +class MouseReportParser : public HIDReportParser { + + union { + MOUSEINFO mouseInfo; + uint8_t bInfo[sizeof (MOUSEINFO)]; + } prevState; + +public: + virtual void Parse(HID *hid, uint32_t is_rpt_id, uint32_t len, uint8_t *buf); + +protected: + + virtual void OnMouseMove(MOUSEINFO *) { + }; + + virtual void OnLeftButtonUp(MOUSEINFO *) { + }; + + virtual void OnLeftButtonDown(MOUSEINFO *) { + }; + + virtual void OnRightButtonUp(MOUSEINFO *) { + }; + + virtual void OnRightButtonDown(MOUSEINFO *) { + }; + + virtual void OnMiddleButtonUp(MOUSEINFO *) { + }; + + virtual void OnMiddleButtonDown(MOUSEINFO *) { + }; +}; + +struct MODIFIERKEYS { + uint8_t bmLeftCtrl : 1; + uint8_t bmLeftShift : 1; + uint8_t bmLeftAlt : 1; + uint8_t bmLeftGUI : 1; + uint8_t bmRightCtrl : 1; + uint8_t bmRightShift : 1; + uint8_t bmRightAlt : 1; + uint8_t bmRightGUI : 1; +}; + +struct KBDINFO { + + struct { + uint8_t bmLeftCtrl : 1; + uint8_t bmLeftShift : 1; + uint8_t bmLeftAlt : 1; + uint8_t bmLeftGUI : 1; + uint8_t bmRightCtrl : 1; + uint8_t bmRightShift : 1; + uint8_t bmRightAlt : 1; + uint8_t bmRightGUI : 1; + }; + uint8_t bReserved; + uint8_t Keys[6]; +}; + +struct KBDLEDS { + uint8_t bmNumLock : 1; + uint8_t bmCapsLock : 1; + uint8_t bmScrollLock : 1; + uint8_t bmCompose : 1; + uint8_t bmKana : 1; + uint8_t bmReserved : 3; +}; + +class KeyboardReportParser : public HIDReportParser { + static const uint8_t numKeys[10]; + static const uint8_t symKeysUp[12]; + static const uint8_t symKeysLo[12]; + static const uint8_t padKeys[5]; + +protected: + + union { + KBDINFO kbdInfo; + uint8_t bInfo[sizeof (KBDINFO)]; + } prevState; + + union { + KBDLEDS kbdLeds; + uint8_t bLeds; + } kbdLockingKeys; + + uint8_t OemToAscii(uint8_t mod, uint8_t key); + +public: + + KeyboardReportParser() { + kbdLockingKeys.bLeds = 0; + }; + + virtual void Parse(HID *hid, uint32_t is_rpt_id, uint32_t len, uint8_t *buf); + +protected: + virtual uint8_t HandleLockingKeys(HID* hid, uint8_t key); + + virtual void OnControlKeysChanged(uint8_t /* before */, uint8_t /* after */) { + }; + + virtual void OnKeyDown(uint8_t /* mod */, uint8_t /* key */) { + }; + + virtual void OnKeyUp(uint8_t /* mod */, uint8_t /* key */) { + }; + + virtual const uint8_t *getNumKeys() { + return numKeys; + }; + + virtual const uint8_t *getSymKeysUp() { + return symKeysUp; + }; + + virtual const uint8_t *getSymKeysLo() { + return symKeysLo; + }; + + virtual const uint8_t *getPadKeys() { + return padKeys; + }; +}; + +template +class HIDBoot : public HID //public USBDeviceConfig, public UsbConfigXtracter +{ + EpInfo epInfo[totalEndpoints(BOOT_PROTOCOL)]; + HIDReportParser *pRptParser[epMUL(BOOT_PROTOCOL)]; + + uint32_t bConfNum; // configuration number + uint32_t bIfaceNum; // Interface Number + uint32_t bNumIface; // number of interfaces in the configuration + uint32_t bNumEP; // total number of EP in the configuration + + uint32_t qNextPollTime; // next poll time + uint32_t bPollEnable; // poll enable flag + uint32_t bInterval; // largest interval + + void Initialize(); + + virtual HIDReportParser* GetReportParser(uint32_t id) { + return pRptParser[id]; + }; + +public: + HIDBoot(USBHost *p); + + virtual uint32_t SetReportParser(uint32_t id, HIDReportParser *prs) { + pRptParser[id] = prs; + return true; + }; + + // USBDeviceConfig implementation + virtual uint32_t Init(uint32_t parent, uint32_t port, uint32_t lowspeed); + virtual uint32_t Release(); + virtual uint32_t Poll(); + + virtual uint32_t GetAddress() { + return bAddress; + }; + + // UsbConfigXtracter implementation + virtual void EndpointXtract(uint32_t conf, uint32_t iface, uint32_t alt, uint32_t proto, const USB_ENDPOINT_DESCRIPTOR *ep); +}; + +template +HIDBoot::HIDBoot(USBHost *p) : + HID(p), + qNextPollTime(0), + bPollEnable(false) { + Initialize(); + + for(int i = 0; i < epMUL(BOOT_PROTOCOL); i++) { + pRptParser[i] = NULL; + } + if(pUsb) + pUsb->RegisterDeviceClass(this); +} + +template +void HIDBoot::Initialize() { + for(int i = 0; i < totalEndpoints(BOOT_PROTOCOL); i++) { + epInfo[i].epAddr = 0; + epInfo[i].maxPktSize = (i) ? 0 : 8; + epInfo[i].bmSndToggle = 0; + epInfo[i].bmRcvToggle = 0; + epInfo[i].bmNakPower = (i) ? USB_NAK_NOWAIT : USB_NAK_MAX_POWER; + } + bNumEP = 1; + bNumIface = 0; + bConfNum = 0; +} + +template +uint32_t HIDBoot::Init(uint32_t parent, uint32_t port, uint32_t lowspeed) { + const uint8_t constBufSize = sizeof (USB_DEVICE_DESCRIPTOR); + + uint8_t buf[constBufSize]; + uint32_t rcode; + UsbDeviceDefinition *p = NULL; + EpInfo *oldep_ptr = NULL; + uint32_t len = 0; + //uint16_t cd_len = 0; + + uint32_t num_of_conf; // number of configurations + //uint32_t num_of_intf; // number of interfaces + + // Get memory address of USB device address pool + AddressPool &addrPool = pUsb->GetAddressPool(); + + USBTRACE("BM Init\r\n"); + //USBTRACE2("totalEndpoints:", (uint8_t) (totalEndpoints(BOOT_PROTOCOL))); + //USBTRACE2("epMUL:", epMUL(BOOT_PROTOCOL)); + + // Check if address has already been assigned to an instance + if(bAddress) + return USB_ERROR_CLASS_INSTANCE_ALREADY_IN_USE; + + bInterval = 0; + // Get pointer to pseudo device with address 0 assigned + p = addrPool.GetUsbDevicePtr(0); + + if(!p) + return USB_ERROR_ADDRESS_NOT_FOUND_IN_POOL; + + if(!p->epinfo) { + USBTRACE("epinfo\r\n"); + return USB_ERROR_EPINFO_IS_NULL; + } + + // Save old pointer to EP_RECORD of address 0 + oldep_ptr = p->epinfo; + + // Temporary assign new pointer to epInfo to p->epinfo in order to avoid toggle inconsistence + p->epinfo = epInfo; + + p->lowspeed = lowspeed; + // Get device descriptor GET_DESCRIPTOR + rcode = pUsb->getDevDescr(0, 0, /*8*/sizeof(USB_DEVICE_DESCRIPTOR), (uint8_t*)buf); + + if(!rcode) + len = (buf[0] > constBufSize) ? constBufSize : buf[0]; + + if(rcode) { + // Restore p->epinfo + p->epinfo = oldep_ptr; + + goto FailGetDevDescr; + } + + + // Restore p->epinfo + p->epinfo = oldep_ptr; + + + // Allocate new address according to device class + bAddress = addrPool.AllocAddress(parent, false, port); + if(!bAddress) + return USB_ERROR_OUT_OF_ADDRESS_SPACE_IN_POOL; + + // Extract Max Packet Size from the device descriptor + epInfo[0].maxPktSize = (uint8_t)((USB_DEVICE_DESCRIPTOR*)buf)->bMaxPacketSize0; + + // Assign new address to the device SET_ADDRESS + + rcode = pUsb->setAddr(0, 0, bAddress); + if(rcode) { + p->lowspeed = false; + addrPool.FreeAddress(bAddress); + bAddress = 0; + USBTRACE2("setAddr:", rcode); + return rcode; + } + //delay(2); //per USB 2.0 sect.9.2.6.3 + + // Save old pointer to EP_RECORD of address 0 + oldep_ptr = p->epinfo; + // Temporary assign new pointer to epInfo to p->epinfo in order to avoid toggle inconsistence + p->epinfo = epInfo; + // Get device descriptor GET_DESCRIPTOR + rcode = pUsb->getDevDescr(bAddress, 0, sizeof(USB_DEVICE_DESCRIPTOR), (uint8_t*)buf); + // Restore p->epinfo + p->epinfo = oldep_ptr; + if (rcode) + { + goto FailGetDevDescr; + } + + TRACE_USBHOST(printf("HIDBoot::Init : device address is now %lu\r\n", bAddress);) + + p->lowspeed = false; + + //get pointer to assigned address record + p = addrPool.GetUsbDevicePtr(bAddress); + + if(!p) + return USB_ERROR_ADDRESS_NOT_FOUND_IN_POOL; + + p->lowspeed = lowspeed; + + if(len) + rcode = pUsb->getDevDescr(bAddress, 0, len, (uint8_t*)buf); + + if(rcode) + goto FailGetDevDescr; + + num_of_conf = ((USB_DEVICE_DESCRIPTOR*)buf)->bNumConfigurations; + + USBTRACE2("NC:", num_of_conf); + + // GCC will optimize unused stuff away. + if((BOOT_PROTOCOL & (HID_PROTOCOL_KEYBOARD | HID_PROTOCOL_MOUSE)) == (HID_PROTOCOL_KEYBOARD | HID_PROTOCOL_MOUSE)) { + USBTRACE("HID_PROTOCOL_KEYBOARD AND MOUSE\r\n"); + ConfigDescParser< + USB_CLASS_HID, + HID_BOOT_INTF_SUBCLASS, + HID_PROTOCOL_KEYBOARD | HID_PROTOCOL_MOUSE, + CP_MASK_COMPARE_ALL > confDescrParser(this); + confDescrParser.SetOR(); // Use the OR variant. + for(uint32_t i = 0; i < num_of_conf; i++) { + pUsb->getConfDescr(bAddress, 0, i, &confDescrParser); + if(bNumEP == (uint8_t)(totalEndpoints(BOOT_PROTOCOL))) + break; + } + } else { + // GCC will optimize unused stuff away. + if(BOOT_PROTOCOL & HID_PROTOCOL_KEYBOARD) { + USBTRACE("HID_PROTOCOL_KEYBOARD\r\n"); + for(uint32_t i = 0; i < num_of_conf; i++) { + ConfigDescParser< + USB_CLASS_HID, + HID_BOOT_INTF_SUBCLASS, + HID_PROTOCOL_KEYBOARD, + CP_MASK_COMPARE_ALL> confDescrParserA(this); + + pUsb->getConfDescr(bAddress, 0, i, &confDescrParserA); + if(bNumEP == (uint8_t)(totalEndpoints(BOOT_PROTOCOL))) + break; + } + } + + // GCC will optimize unused stuff away. + if(BOOT_PROTOCOL & HID_PROTOCOL_MOUSE) { + USBTRACE("HID_PROTOCOL_MOUSE\r\n"); + for(uint32_t i = 0; i < num_of_conf; i++) { + ConfigDescParser< + USB_CLASS_HID, + HID_BOOT_INTF_SUBCLASS, + HID_PROTOCOL_MOUSE, + CP_MASK_COMPARE_ALL> confDescrParserB(this); + + pUsb->getConfDescr(bAddress, 0, i, &confDescrParserB); + if(bNumEP == ((uint8_t)(totalEndpoints(BOOT_PROTOCOL)))) + break; + + } + } + } + USBTRACE2("bNumEP:", bNumEP); + + if(bNumEP != (uint8_t)(totalEndpoints(BOOT_PROTOCOL))) { + rcode = USB_DEV_CONFIG_ERROR_DEVICE_NOT_SUPPORTED; + goto Fail; + } + + // Assign epInfo to epinfo pointer + rcode = pUsb->setEpInfoEntry(bAddress, bNumEP, epInfo); + //USBTRACE2("setEpInfoEntry returned ", rcode); + USBTRACE2("Cnf:", bConfNum); + + delay(1000); + + // Set Configuration Value + rcode = pUsb->setConf(bAddress, 0, bConfNum); + + if(rcode) + goto FailSetConfDescr; + + delay(1000); + + USBTRACE2("bIfaceNum:", bIfaceNum); + USBTRACE2("bNumIface:", bNumIface); + + // Yes, mouse wants SetProtocol and SetIdle too! + for(uint32_t i = 0; i < epMUL(BOOT_PROTOCOL); i++) { + USBTRACE2("\r\nInterface:", i); + rcode = SetProtocol(i, HID_BOOT_PROTOCOL); + if(rcode) goto FailSetProtocol; + USBTRACE2("PROTOCOL SET HID_BOOT rcode:", rcode); + rcode = SetIdle(i, 0, 0); + USBTRACE2("SET_IDLE rcode:", rcode); + // if(rcode) goto FailSetIdle; This can fail. + // Get the RPIPE and just throw it away. + SinkParser sink; + rcode = GetReportDescr(i, (USBReadParser *)&sink); + USBTRACE2("RPIPE rcode:", rcode); + } + + // Get RPIPE and throw it away. + + if(BOOT_PROTOCOL & HID_PROTOCOL_KEYBOARD) { + // Wake keyboard interface by twinkling up to 5 LEDs that are in the spec. + // kana, compose, scroll, caps, num + rcode = 0x20; // Reuse rcode. + while(rcode) { + rcode >>= 1; + // Ignore any error returned, we don't care if LED is not supported + SetReport(0, 0, 2, 0, 1, (uint8_t*)&rcode); // Eventually becomes zero (All off) + delay(25); + } + } + USBTRACE("BM configured\r\n"); + + bPollEnable = true; + return 0; + +FailGetDevDescr: +#ifdef DEBUG_USB_HOST + NotifyFailGetDevDescr(); + goto Fail; +#endif + + //FailSetDevTblEntry: + //#ifdef DEBUG_USB_HOST + // NotifyFailSetDevTblEntry(); + // goto Fail; + //#endif + + //FailGetConfDescr: + //#ifdef DEBUG_USB_HOST + // NotifyFailGetConfDescr(); + // goto Fail; + //#endif + +FailSetConfDescr: +#ifdef DEBUG_USB_HOST + NotifyFailSetConfDescr(); + goto Fail; +#endif + +FailSetProtocol: +#ifdef DEBUG_USB_HOST + USBTRACE("SetProto:"); + goto Fail; +#endif + + //FailSetIdle: + //#ifdef DEBUG_USB_HOST + // USBTRACE("SetIdle:"); + //#endif + +Fail: +#ifdef DEBUG_USB_HOST + NotifyFail(rcode); +#endif + Release(); + + return rcode; +} + +template +void HIDBoot::EndpointXtract(uint32_t conf, uint32_t iface, uint32_t /* alt */, uint32_t /* proto */, const USB_ENDPOINT_DESCRIPTOR *pep) { + // If the first configuration satisfies, the others are not considered. + //if(bNumEP > 1 && conf != bConfNum) + if(bNumEP == totalEndpoints(BOOT_PROTOCOL)) + return; + + bConfNum = conf; + bIfaceNum = iface; + + if((pep->bmAttributes & 0x03) == 3 && (pep->bEndpointAddress & 0x80) == 0x80) { + if(pep->bInterval > bInterval) bInterval = pep->bInterval; + + // Fill in the endpoint info structure + epInfo[bNumEP].epAddr = (pep->bEndpointAddress & 0x0F); + epInfo[bNumEP].maxPktSize = (uint8_t)pep->wMaxPacketSize; + epInfo[bNumEP].bmSndToggle = 0; + epInfo[bNumEP].bmRcvToggle = 0; + epInfo[bNumEP].bmNakPower = USB_NAK_NOWAIT; + bNumEP++; + + } +} + +template +uint32_t HIDBoot::Release() { + pUsb->GetAddressPool().FreeAddress(bAddress); + + bConfNum = 0; + bIfaceNum = 0; + bNumEP = 1; + bAddress = 0; + qNextPollTime = 0; + bPollEnable = false; + + return 0; +} + +template +uint32_t HIDBoot::Poll() { + uint32_t rcode = 0; + + if(bPollEnable && ((long)(millis() - qNextPollTime) >= 0L)) { + + // To-do: optimize manually, using the for loop only if needed. + for(int i = 0; i < epMUL(BOOT_PROTOCOL); i++) { + const uint16_t const_buff_len = 16; + uint8_t buf[const_buff_len]; + + USBTRACE3("(hidboot.h) i=", i, 0x81); + USBTRACE3("(hidboot.h) epInfo[epInterruptInIndex + i].epAddr=", epInfo[epInterruptInIndex + i].epAddr, 0x81); + USBTRACE3("(hidboot.h) epInfo[epInterruptInIndex + i].maxPktSize=", epInfo[epInterruptInIndex + i].maxPktSize, 0x81); + uint16_t read = (uint16_t)epInfo[epInterruptInIndex + i].maxPktSize; + UHD_Pipe_Alloc(bAddress, epInfo[epInterruptInIndex + i].epAddr, USB_HOST_PTYPE_BULK, USB_EP_DIR_IN, epInfo[epInterruptInIndex + i].maxPktSize, 0, USB_HOST_NB_BK_1); + rcode = pUsb->inTransfer(bAddress, epInfo[epInterruptInIndex + i].epAddr, (uint8_t*)&read, buf); + // SOME buggy dongles report extra keys (like sleep) using a 2 byte packet on the wrong endpoint. + // Since keyboard and mice must report at least 3 bytes, we ignore the extra data. + if(!rcode && read > 2) { + if(pRptParser[i]) + pRptParser[i]->Parse((HID*)this, 0, (uint8_t)read, buf); +#ifdef DEBUG_USB_HOST + // We really don't care about errors and anomalies unless we are debugging. + } else { + if(rcode != USB_ERRORFLOW) { + USBTRACE3("(hidboot.h) Poll:", rcode, 0x81); + } + if(!rcode && read) { + USBTRACE3("(hidboot.h) Strange read count: ", read, 0x80); + USBTRACE3("(hidboot.h) Interface:", i, 0x80); + } + } + + if(!rcode && read && (UsbDEBUGlvl > 0x7f)) { + for(uint8_t i = 0; i < read; i++) { + PrintHex (buf[i], 0x80); + USBTRACE1(" ", 0x80); + } + if(read) + USBTRACE1("\r\n", 0x80); +#endif + } + + } + qNextPollTime = millis() + bInterval; + } + return rcode; +} + +#endif /* HIDBOOT_H_INCLUDED */ diff --git a/libraries/USBHost/src/hidescriptorparser.cpp b/libraries/USBHost/src/hidescriptorparser.cpp new file mode 100644 index 0000000..3538743 --- /dev/null +++ b/libraries/USBHost/src/hidescriptorparser.cpp @@ -0,0 +1,1599 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com + */ + +#include "hidescriptorparser.h" + +const char * const ReportDescParserBase::usagePageTitles0[] PROGMEM = { + pstrUsagePageGenericDesktopControls, + pstrUsagePageSimulationControls, + pstrUsagePageVRControls, + pstrUsagePageSportControls, + pstrUsagePageGameControls, + pstrUsagePageGenericDeviceControls, + pstrUsagePageKeyboardKeypad, + pstrUsagePageLEDs, + pstrUsagePageButton, + pstrUsagePageOrdinal, + pstrUsagePageTelephone, + pstrUsagePageConsumer, + pstrUsagePageDigitizer, + pstrUsagePagePID, + pstrUsagePageUnicode +}; + +const char * const ReportDescParserBase::usagePageTitles1[] PROGMEM = { + pstrUsagePageBarCodeScanner, + pstrUsagePageScale, + pstrUsagePageMSRDevices, + pstrUsagePagePointOfSale, + pstrUsagePageCameraControl, + pstrUsagePageArcade +}; +const char * const ReportDescParserBase::genDesktopTitles0[] PROGMEM = { + pstrUsagePointer, + pstrUsageMouse, + pstrUsageJoystick, + pstrUsageGamePad, + pstrUsageKeyboard, + pstrUsageKeypad, + pstrUsageMultiAxisController, + pstrUsageTabletPCSystemControls + +}; +const char * const ReportDescParserBase::genDesktopTitles1[] PROGMEM = { + pstrUsageX, + pstrUsageY, + pstrUsageZ, + pstrUsageRx, + pstrUsageRy, + pstrUsageRz, + pstrUsageSlider, + pstrUsageDial, + pstrUsageWheel, + pstrUsageHatSwitch, + pstrUsageCountedBuffer, + pstrUsageByteCount, + pstrUsageMotionWakeup, + pstrUsageStart, + pstrUsageSelect, + pstrUsagePageReserved, + pstrUsageVx, + pstrUsageVy, + pstrUsageVz, + pstrUsageVbrx, + pstrUsageVbry, + pstrUsageVbrz, + pstrUsageVno, + pstrUsageFeatureNotification, + pstrUsageResolutionMultiplier +}; +const char * const ReportDescParserBase::genDesktopTitles2[] PROGMEM = { + pstrUsageSystemControl, + pstrUsageSystemPowerDown, + pstrUsageSystemSleep, + pstrUsageSystemWakeup, + pstrUsageSystemContextMenu, + pstrUsageSystemMainMenu, + pstrUsageSystemAppMenu, + pstrUsageSystemMenuHelp, + pstrUsageSystemMenuExit, + pstrUsageSystemMenuSelect, + pstrUsageSystemMenuRight, + pstrUsageSystemMenuLeft, + pstrUsageSystemMenuUp, + pstrUsageSystemMenuDown, + pstrUsageSystemColdRestart, + pstrUsageSystemWarmRestart, + pstrUsageDPadUp, + pstrUsageDPadDown, + pstrUsageDPadRight, + pstrUsageDPadLeft +}; +const char * const ReportDescParserBase::genDesktopTitles3[] PROGMEM = { + pstrUsageSystemDock, + pstrUsageSystemUndock, + pstrUsageSystemSetup, + pstrUsageSystemBreak, + pstrUsageSystemDebuggerBreak, + pstrUsageApplicationBreak, + pstrUsageApplicationDebuggerBreak, + pstrUsageSystemSpeakerMute, + pstrUsageSystemHibernate +}; +const char * const ReportDescParserBase::genDesktopTitles4[] PROGMEM = { + pstrUsageSystemDisplayInvert, + pstrUsageSystemDisplayInternal, + pstrUsageSystemDisplayExternal, + pstrUsageSystemDisplayBoth, + pstrUsageSystemDisplayDual, + pstrUsageSystemDisplayToggleIntExt, + pstrUsageSystemDisplaySwapPriSec, + pstrUsageSystemDisplayLCDAutoscale +}; +const char * const ReportDescParserBase::simuTitles0[] PROGMEM = { + pstrUsageFlightSimulationDevice, + pstrUsageAutomobileSimulationDevice, + pstrUsageTankSimulationDevice, + pstrUsageSpaceshipSimulationDevice, + pstrUsageSubmarineSimulationDevice, + pstrUsageSailingSimulationDevice, + pstrUsageMotocicleSimulationDevice, + pstrUsageSportsSimulationDevice, + pstrUsageAirplaneSimulationDevice, + pstrUsageHelicopterSimulationDevice, + pstrUsageMagicCarpetSimulationDevice, + pstrUsageBicycleSimulationDevice +}; +const char * const ReportDescParserBase::simuTitles1[] PROGMEM = { + pstrUsageFlightControlStick, + pstrUsageFlightStick, + pstrUsageCyclicControl, + pstrUsageCyclicTrim, + pstrUsageFlightYoke, + pstrUsageTrackControl +}; +const char * const ReportDescParserBase::simuTitles2[] PROGMEM = { + pstrUsageAileron, + pstrUsageAileronTrim, + pstrUsageAntiTorqueControl, + pstrUsageAutopilotEnable, + pstrUsageChaffRelease, + pstrUsageCollectiveControl, + pstrUsageDiveBrake, + pstrUsageElectronicCountermeasures, + pstrUsageElevator, + pstrUsageElevatorTrim, + pstrUsageRudder, + pstrUsageThrottle, + pstrUsageFlightCommunications, + pstrUsageFlareRelease, + pstrUsageLandingGear, + pstrUsageToeBrake, + pstrUsageTrigger, + pstrUsageWeaponsArm, + pstrUsageWeaponsSelect, + pstrUsageWingFlaps, + pstrUsageAccelerator, + pstrUsageBrake, + pstrUsageClutch, + pstrUsageShifter, + pstrUsageSteering, + pstrUsageTurretDirection, + pstrUsageBarrelElevation, + pstrUsageDivePlane, + pstrUsageBallast, + pstrUsageBicycleCrank, + pstrUsageHandleBars, + pstrUsageFrontBrake, + pstrUsageRearBrake +}; +const char * const ReportDescParserBase::vrTitles0[] PROGMEM = { + pstrUsageBelt, + pstrUsageBodySuit, + pstrUsageFlexor, + pstrUsageGlove, + pstrUsageHeadTracker, + pstrUsageHeadMountedDisplay, + pstrUsageHandTracker, + pstrUsageOculometer, + pstrUsageVest, + pstrUsageAnimatronicDevice +}; +const char * const ReportDescParserBase::vrTitles1[] PROGMEM = { + pstrUsageStereoEnable, + pstrUsageDisplayEnable +}; +const char * const ReportDescParserBase::sportsCtrlTitles0[] PROGMEM = { + pstrUsageBaseballBat, + pstrUsageGolfClub, + pstrUsageRowingMachine, + pstrUsageTreadmill +}; +const char * const ReportDescParserBase::sportsCtrlTitles1[] PROGMEM = { + pstrUsageOar, + pstrUsageSlope, + pstrUsageRate, + pstrUsageStickSpeed, + pstrUsageStickFaceAngle, + pstrUsageStickHeelToe, + pstrUsageStickFollowThough, + pstrUsageStickTempo, + pstrUsageStickType, + pstrUsageStickHeight +}; +const char * const ReportDescParserBase::sportsCtrlTitles2[] PROGMEM = { + pstrUsagePutter, + pstrUsage1Iron, + pstrUsage2Iron, + pstrUsage3Iron, + pstrUsage4Iron, + pstrUsage5Iron, + pstrUsage6Iron, + pstrUsage7Iron, + pstrUsage8Iron, + pstrUsage9Iron, + pstrUsage10Iron, + pstrUsage11Iron, + pstrUsageSandWedge, + pstrUsageLoftWedge, + pstrUsagePowerWedge, + pstrUsage1Wood, + pstrUsage3Wood, + pstrUsage5Wood, + pstrUsage7Wood, + pstrUsage9Wood +}; +const char * const ReportDescParserBase::gameTitles0[] PROGMEM = { + pstrUsage3DGameController, + pstrUsagePinballDevice, + pstrUsageGunDevice +}; +const char * const ReportDescParserBase::gameTitles1[] PROGMEM = { + pstrUsagePointOfView, + pstrUsageTurnRightLeft, + pstrUsagePitchForwardBackward, + pstrUsageRollRightLeft, + pstrUsageMoveRightLeft, + pstrUsageMoveForwardBackward, + pstrUsageMoveUpDown, + pstrUsageLeanRightLeft, + pstrUsageLeanForwardBackward, + pstrUsageHeightOfPOV, + pstrUsageFlipper, + pstrUsageSecondaryFlipper, + pstrUsageBump, + pstrUsageNewGame, + pstrUsageShootBall, + pstrUsagePlayer, + pstrUsageGunBolt, + pstrUsageGunClip, + pstrUsageGunSelector, + pstrUsageGunSingleShot, + pstrUsageGunBurst, + pstrUsageGunAutomatic, + pstrUsageGunSafety, + pstrUsageGamepadFireJump, + pstrUsageGamepadTrigger +}; +const char * const ReportDescParserBase::genDevCtrlTitles[] PROGMEM = { + pstrUsageBatteryStrength, + pstrUsageWirelessChannel, + pstrUsageWirelessID, + pstrUsageDiscoverWirelessControl, + pstrUsageSecurityCodeCharEntered, + pstrUsageSecurityCodeCharErased, + pstrUsageSecurityCodeCleared +}; +const char * const ReportDescParserBase::ledTitles[] PROGMEM = { + pstrUsageNumLock, + pstrUsageCapsLock, + pstrUsageScrollLock, + pstrUsageCompose, + pstrUsageKana, + pstrUsagePower, + pstrUsageShift, + pstrUsageDoNotDisturb, + pstrUsageMute, + pstrUsageToneEnable, + pstrUsageHighCutFilter, + pstrUsageLowCutFilter, + pstrUsageEqualizerEnable, + pstrUsageSoundFieldOn, + pstrUsageSurroundOn, + pstrUsageRepeat, + pstrUsageStereo, + pstrUsageSamplingRateDetect, + pstrUsageSpinning, + pstrUsageCAV, + pstrUsageCLV, + pstrUsageRecordingFormatDetect, + pstrUsageOffHook, + pstrUsageRing, + pstrUsageMessageWaiting, + pstrUsageDataMode, + pstrUsageBatteryOperation, + pstrUsageBatteryOK, + pstrUsageBatteryLow, + pstrUsageSpeaker, + pstrUsageHeadSet, + pstrUsageHold, + pstrUsageMicrophone, + pstrUsageCoverage, + pstrUsageNightMode, + pstrUsageSendCalls, + pstrUsageCallPickup, + pstrUsageConference, + pstrUsageStandBy, + pstrUsageCameraOn, + pstrUsageCameraOff, + pstrUsageOnLine, + pstrUsageOffLine, + pstrUsageBusy, + pstrUsageReady, + pstrUsagePaperOut, + pstrUsagePaperJam, + pstrUsageRemote, + pstrUsageForward, + pstrUsageReverse, + pstrUsageStop, + pstrUsageRewind, + pstrUsageFastForward, + pstrUsagePlay, + pstrUsagePause, + pstrUsageRecord, + pstrUsageError, + pstrUsageSelectedIndicator, + pstrUsageInUseIndicator, + pstrUsageMultiModeIndicator, + pstrUsageIndicatorOn, + pstrUsageIndicatorFlash, + pstrUsageIndicatorSlowBlink, + pstrUsageIndicatorFastBlink, + pstrUsageIndicatorOff, + pstrUsageFlashOnTime, + pstrUsageSlowBlinkOnTime, + pstrUsageSlowBlinkOffTime, + pstrUsageFastBlinkOnTime, + pstrUsageFastBlinkOffTime, + pstrUsageIndicatorColor, + pstrUsageIndicatorRed, + pstrUsageIndicatorGreen, + pstrUsageIndicatorAmber, + pstrUsageGenericIndicator, + pstrUsageSystemSuspend, + pstrUsageExternalPowerConnected +}; +const char * const ReportDescParserBase::telTitles0 [] PROGMEM = { + pstrUsagePhone, + pstrUsageAnsweringMachine, + pstrUsageMessageControls, + pstrUsageHandset, + pstrUsageHeadset, + pstrUsageTelephonyKeyPad, + pstrUsageProgrammableButton +}; +const char * const ReportDescParserBase::telTitles1 [] PROGMEM = { + pstrUsageHookSwitch, + pstrUsageFlash, + pstrUsageFeature, + pstrUsageHold, + pstrUsageRedial, + pstrUsageTransfer, + pstrUsageDrop, + pstrUsagePark, + pstrUsageForwardCalls, + pstrUsageAlternateFunction, + pstrUsageLine, + pstrUsageSpeakerPhone, + pstrUsageConference, + pstrUsageRingEnable, + pstrUsageRingSelect, + pstrUsagePhoneMute, + pstrUsageCallerID, + pstrUsageSend +}; +const char * const ReportDescParserBase::telTitles2 [] PROGMEM = { + pstrUsageSpeedDial, + pstrUsageStoreNumber, + pstrUsageRecallNumber, + pstrUsagePhoneDirectory +}; +const char * const ReportDescParserBase::telTitles3 [] PROGMEM = { + pstrUsageVoiceMail, + pstrUsageScreenCalls, + pstrUsageDoNotDisturb, + pstrUsageMessage, + pstrUsageAnswerOnOff +}; +const char * const ReportDescParserBase::telTitles4 [] PROGMEM = { + pstrUsageInsideDialTone, + pstrUsageOutsideDialTone, + pstrUsageInsideRingTone, + pstrUsageOutsideRingTone, + pstrUsagePriorityRingTone, + pstrUsageInsideRingback, + pstrUsagePriorityRingback, + pstrUsageLineBusyTone, + pstrUsageReorderTone, + pstrUsageCallWaitingTone, + pstrUsageConfirmationTone1, + pstrUsageConfirmationTone2, + pstrUsageTonesOff, + pstrUsageOutsideRingback, + pstrUsageRinger +}; +const char * const ReportDescParserBase::telTitles5 [] PROGMEM = { + pstrUsagePhoneKey0, + pstrUsagePhoneKey1, + pstrUsagePhoneKey2, + pstrUsagePhoneKey3, + pstrUsagePhoneKey4, + pstrUsagePhoneKey5, + pstrUsagePhoneKey6, + pstrUsagePhoneKey7, + pstrUsagePhoneKey8, + pstrUsagePhoneKey9, + pstrUsagePhoneKeyStar, + pstrUsagePhoneKeyPound, + pstrUsagePhoneKeyA, + pstrUsagePhoneKeyB, + pstrUsagePhoneKeyC, + pstrUsagePhoneKeyD +}; +const char * const ReportDescParserBase::consTitles0[] PROGMEM = { + pstrUsageConsumerControl, + pstrUsageNumericKeyPad, + pstrUsageProgrammableButton, + pstrUsageMicrophone, + pstrUsageHeadphone, + pstrUsageGraphicEqualizer +}; +const char * const ReportDescParserBase::consTitles1[] PROGMEM = { + pstrUsagePlus10, + pstrUsagePlus100, + pstrUsageAMPM +}; +const char * const ReportDescParserBase::consTitles2[] PROGMEM = { + pstrUsagePower, + pstrUsageReset, + pstrUsageSleep, + pstrUsageSleepAfter, + pstrUsageSleepMode, + pstrUsageIllumination, + pstrUsageFunctionButtons + +}; +const char * const ReportDescParserBase::consTitles3[] PROGMEM = { + pstrUsageMenu, + pstrUsageMenuPick, + pstrUsageMenuUp, + pstrUsageMenuDown, + pstrUsageMenuLeft, + pstrUsageMenuRight, + pstrUsageMenuEscape, + pstrUsageMenuValueIncrease, + pstrUsageMenuValueDecrease +}; +const char * const ReportDescParserBase::consTitles4[] PROGMEM = { + pstrUsageDataOnScreen, + pstrUsageClosedCaption, + pstrUsageClosedCaptionSelect, + pstrUsageVCRTV, + pstrUsageBroadcastMode, + pstrUsageSnapshot, + pstrUsageStill +}; +const char * const ReportDescParserBase::consTitles5[] PROGMEM = { + pstrUsageSelection, + pstrUsageAssignSelection, + pstrUsageModeStep, + pstrUsageRecallLast, + pstrUsageEnterChannel, + pstrUsageOrderMovie, + pstrUsageChannel, + pstrUsageMediaSelection, + pstrUsageMediaSelectComputer, + pstrUsageMediaSelectTV, + pstrUsageMediaSelectWWW, + pstrUsageMediaSelectDVD, + pstrUsageMediaSelectTelephone, + pstrUsageMediaSelectProgramGuide, + pstrUsageMediaSelectVideoPhone, + pstrUsageMediaSelectGames, + pstrUsageMediaSelectMessages, + pstrUsageMediaSelectCD, + pstrUsageMediaSelectVCR, + pstrUsageMediaSelectTuner, + pstrUsageQuit, + pstrUsageHelp, + pstrUsageMediaSelectTape, + pstrUsageMediaSelectCable, + pstrUsageMediaSelectSatellite, + pstrUsageMediaSelectSecurity, + pstrUsageMediaSelectHome, + pstrUsageMediaSelectCall, + pstrUsageChannelIncrement, + pstrUsageChannelDecrement, + pstrUsageMediaSelectSAP, + pstrUsagePageReserved, + pstrUsageVCRPlus, + pstrUsageOnce, + pstrUsageDaily, + pstrUsageWeekly, + pstrUsageMonthly +}; +const char * const ReportDescParserBase::consTitles6[] PROGMEM = { + pstrUsagePlay, + pstrUsagePause, + pstrUsageRecord, + pstrUsageFastForward, + pstrUsageRewind, + pstrUsageScanNextTrack, + pstrUsageScanPreviousTrack, + pstrUsageStop, + pstrUsageEject, + pstrUsageRandomPlay, + pstrUsageSelectDisk, + pstrUsageEnterDisk, + pstrUsageRepeat, + pstrUsageTracking, + pstrUsageTrackNormal, + pstrUsageSlowTracking, + pstrUsageFrameForward, + pstrUsageFrameBackwards, + pstrUsageMark, + pstrUsageClearMark, + pstrUsageRepeatFromMark, + pstrUsageReturnToMark, + pstrUsageSearchMarkForward, + pstrUsageSearchMarkBackwards, + pstrUsageCounterReset, + pstrUsageShowCounter, + pstrUsageTrackingIncrement, + pstrUsageTrackingDecrement, + pstrUsageStopEject, + pstrUsagePlayPause, + pstrUsagePlaySkip +}; +const char * const ReportDescParserBase::consTitles7[] PROGMEM = { + pstrUsageVolume, + pstrUsageBalance, + pstrUsageMute, + pstrUsageBass, + pstrUsageTreble, + pstrUsageBassBoost, + pstrUsageSurroundMode, + pstrUsageLoudness, + pstrUsageMPX, + pstrUsageVolumeIncrement, + pstrUsageVolumeDecrement +}; +const char * const ReportDescParserBase::consTitles8[] PROGMEM = { + pstrUsageSpeedSelect, + pstrUsagePlaybackSpeed, + pstrUsageStandardPlay, + pstrUsageLongPlay, + pstrUsageExtendedPlay, + pstrUsageSlow +}; +const char * const ReportDescParserBase::consTitles9[] PROGMEM = { + pstrUsageFanEnable, + pstrUsageFanSpeed, + pstrUsageLightEnable, + pstrUsageLightIlluminationLevel, + pstrUsageClimateControlEnable, + pstrUsageRoomTemperature, + pstrUsageSecurityEnable, + pstrUsageFireAlarm, + pstrUsagePoliceAlarm, + pstrUsageProximity, + pstrUsageMotion, + pstrUsageDuresAlarm, + pstrUsageHoldupAlarm, + pstrUsageMedicalAlarm +}; +const char * const ReportDescParserBase::consTitlesA[] PROGMEM = { + pstrUsageBalanceRight, + pstrUsageBalanceLeft, + pstrUsageBassIncrement, + pstrUsageBassDecrement, + pstrUsageTrebleIncrement, + pstrUsageTrebleDecrement +}; +const char * const ReportDescParserBase::consTitlesB[] PROGMEM = { + pstrUsageSpeakerSystem, + pstrUsageChannelLeft, + pstrUsageChannelRight, + pstrUsageChannelCenter, + pstrUsageChannelFront, + pstrUsageChannelCenterFront, + pstrUsageChannelSide, + pstrUsageChannelSurround, + pstrUsageChannelLowFreqEnhancement, + pstrUsageChannelTop, + pstrUsageChannelUnknown +}; +const char * const ReportDescParserBase::consTitlesC[] PROGMEM = { + pstrUsageSubChannel, + pstrUsageSubChannelIncrement, + pstrUsageSubChannelDecrement, + pstrUsageAlternateAudioIncrement, + pstrUsageAlternateAudioDecrement +}; +const char * const ReportDescParserBase::consTitlesD[] PROGMEM = { + pstrUsageApplicationLaunchButtons, + pstrUsageALLaunchButtonConfigTool, + pstrUsageALProgrammableButton, + pstrUsageALConsumerControlConfig, + pstrUsageALWordProcessor, + pstrUsageALTextEditor, + pstrUsageALSpreadsheet, + pstrUsageALGraphicsEditor, + pstrUsageALPresentationApp, + pstrUsageALDatabaseApp, + pstrUsageALEmailReader, + pstrUsageALNewsreader, + pstrUsageALVoicemail, + pstrUsageALContactsAddressBook, + pstrUsageALCalendarSchedule, + pstrUsageALTaskProjectManager, + pstrUsageALLogJournalTimecard, + pstrUsageALCheckbookFinance, + pstrUsageALCalculator, + pstrUsageALAVCapturePlayback, + pstrUsageALLocalMachineBrowser, + pstrUsageALLANWANBrow, + pstrUsageALInternetBrowser, + pstrUsageALRemoteNetISPConnect, + pstrUsageALNetworkConference, + pstrUsageALNetworkChat, + pstrUsageALTelephonyDialer, + pstrUsageALLogon, + pstrUsageALLogoff, + pstrUsageALLogonLogoff, + pstrUsageALTermLockScrSav, + pstrUsageALControlPannel, + pstrUsageALCommandLineProcessorRun, + pstrUsageALProcessTaskManager, + pstrUsageALSelectTaskApplication, + pstrUsageALNextTaskApplication, + pstrUsageALPreviousTaskApplication, + pstrUsageALPreemptiveHaltTaskApp, + pstrUsageALIntegratedHelpCenter, + pstrUsageALDocuments, + pstrUsageALThesaurus, + pstrUsageALDictionary, + pstrUsageALDesktop, + pstrUsageALSpellCheck, + pstrUsageALGrammarCheck, + pstrUsageALWirelessStatus, + pstrUsageALKeyboardLayout, + pstrUsageALVirusProtection, + pstrUsageALEncryption, + pstrUsageALScreenSaver, + pstrUsageALAlarms, + pstrUsageALClock, + pstrUsageALFileBrowser, + pstrUsageALPowerStatus, + pstrUsageALImageBrowser, + pstrUsageALAudioBrowser, + pstrUsageALMovieBrowser, + pstrUsageALDigitalRightsManager, + pstrUsageALDigitalWallet, + pstrUsagePageReserved, + pstrUsageALInstantMessaging, + pstrUsageALOEMFeaturesBrowser, + pstrUsageALOEMHelp, + pstrUsageALOnlineCommunity, + pstrUsageALEntertainmentContentBrow, + pstrUsageALOnlineShoppingBrowser, + pstrUsageALSmartCardInfoHelp, + pstrUsageALMarketMonitorFinBrowser, + pstrUsageALCustomCorpNewsBrowser, + pstrUsageALOnlineActivityBrowser, + pstrUsageALResearchSearchBrowser, + pstrUsageALAudioPlayer +}; +const char * const ReportDescParserBase::consTitlesE[] PROGMEM = { + pstrUsageGenericGUIAppControls, + pstrUsageACNew, + pstrUsageACOpen, + pstrUsageACClose, + pstrUsageACExit, + pstrUsageACMaximize, + pstrUsageACMinimize, + pstrUsageACSave, + pstrUsageACPrint, + pstrUsageACProperties, + pstrUsageACUndo, + pstrUsageACCopy, + pstrUsageACCut, + pstrUsageACPaste, + pstrUsageACSelectAll, + pstrUsageACFind, + pstrUsageACFindAndReplace, + pstrUsageACSearch, + pstrUsageACGoto, + pstrUsageACHome, + pstrUsageACBack, + pstrUsageACForward, + pstrUsageACStop, + pstrUsageACRefresh, + pstrUsageACPreviousLink, + pstrUsageACNextLink, + pstrUsageACBookmarks, + pstrUsageACHistory, + pstrUsageACSubscriptions, + pstrUsageACZoomIn, + pstrUsageACZoomOut, + pstrUsageACZoom, + pstrUsageACFullScreenView, + pstrUsageACNormalView, + pstrUsageACViewToggle, + pstrUsageACScrollUp, + pstrUsageACScrollDown, + pstrUsageACScroll, + pstrUsageACPanLeft, + pstrUsageACPanRight, + pstrUsageACPan, + pstrUsageACNewWindow, + pstrUsageACTileHoriz, + pstrUsageACTileVert, + pstrUsageACFormat, + pstrUsageACEdit, + pstrUsageACBold, + pstrUsageACItalics, + pstrUsageACUnderline, + pstrUsageACStrikethrough, + pstrUsageACSubscript, + pstrUsageACSuperscript, + pstrUsageACAllCaps, + pstrUsageACRotate, + pstrUsageACResize, + pstrUsageACFlipHorizontal, + pstrUsageACFlipVertical, + pstrUsageACMirrorHorizontal, + pstrUsageACMirrorVertical, + pstrUsageACFontSelect, + pstrUsageACFontColor, + pstrUsageACFontSize, + pstrUsageACJustifyLeft, + pstrUsageACJustifyCenterH, + pstrUsageACJustifyRight, + pstrUsageACJustifyBlockH, + pstrUsageACJustifyTop, + pstrUsageACJustifyCenterV, + pstrUsageACJustifyBottom, + pstrUsageACJustifyBlockV, + pstrUsageACIndentDecrease, + pstrUsageACIndentIncrease, + pstrUsageACNumberedList, + pstrUsageACRestartNumbering, + pstrUsageACBulletedList, + pstrUsageACPromote, + pstrUsageACDemote, + pstrUsageACYes, + pstrUsageACNo, + pstrUsageACCancel, + pstrUsageACCatalog, + pstrUsageACBuyChkout, + pstrUsageACAddToCart, + pstrUsageACExpand, + pstrUsageACExpandAll, + pstrUsageACCollapse, + pstrUsageACCollapseAll, + pstrUsageACPrintPreview, + pstrUsageACPasteSpecial, + pstrUsageACInsertMode, + pstrUsageACDelete, + pstrUsageACLock, + pstrUsageACUnlock, + pstrUsageACProtect, + pstrUsageACUnprotect, + pstrUsageACAttachComment, + pstrUsageACDeleteComment, + pstrUsageACViewComment, + pstrUsageACSelectWord, + pstrUsageACSelectSentence, + pstrUsageACSelectParagraph, + pstrUsageACSelectColumn, + pstrUsageACSelectRow, + pstrUsageACSelectTable, + pstrUsageACSelectObject, + pstrUsageACRedoRepeat, + pstrUsageACSort, + pstrUsageACSortAscending, + pstrUsageACSortDescending, + pstrUsageACFilter, + pstrUsageACSetClock, + pstrUsageACViewClock, + pstrUsageACSelectTimeZone, + pstrUsageACEditTimeZone, + pstrUsageACSetAlarm, + pstrUsageACClearAlarm, + pstrUsageACSnoozeAlarm, + pstrUsageACResetAlarm, + pstrUsageACSyncronize, + pstrUsageACSendReceive, + pstrUsageACSendTo, + pstrUsageACReply, + pstrUsageACReplyAll, + pstrUsageACForwardMessage, + pstrUsageACSend, + pstrUsageACAttachFile, + pstrUsageACUpload, + pstrUsageACDownload, + pstrUsageACSetBorders, + pstrUsageACInsertRow, + pstrUsageACInsertColumn, + pstrUsageACInsertFile, + pstrUsageACInsertPicture, + pstrUsageACInsertObject, + pstrUsageACInsertSymbol, + pstrUsageACSaveAndClose, + pstrUsageACRename, + pstrUsageACMerge, + pstrUsageACSplit, + pstrUsageACDistributeHorizontaly, + pstrUsageACDistributeVerticaly +}; +const char * const ReportDescParserBase::digitTitles0[] PROGMEM = { + pstrUsageDigitizer, + pstrUsagePen, + pstrUsageLightPen, + pstrUsageTouchScreen, + pstrUsageTouchPad, + pstrUsageWhiteBoard, + pstrUsageCoordinateMeasuringMachine, + pstrUsage3DDigitizer, + pstrUsageStereoPlotter, + pstrUsageArticulatedArm, + pstrUsageArmature, + pstrUsageMultiplePointDigitizer, + pstrUsageFreeSpaceWand +}; +const char * const ReportDescParserBase::digitTitles1[] PROGMEM = { + pstrUsageStylus, + pstrUsagePuck, + pstrUsageFinger + +}; +const char * const ReportDescParserBase::digitTitles2[] PROGMEM = { + pstrUsageTipPressure, + pstrUsageBarrelPressure, + pstrUsageInRange, + pstrUsageTouch, + pstrUsageUntouch, + pstrUsageTap, + pstrUsageQuality, + pstrUsageDataValid, + pstrUsageTransducerIndex, + pstrUsageTabletFunctionKeys, + pstrUsageProgramChangeKeys, + pstrUsageBatteryStrength, + pstrUsageInvert, + pstrUsageXTilt, + pstrUsageYTilt, + pstrUsageAzimuth, + pstrUsageAltitude, + pstrUsageTwist, + pstrUsageTipSwitch, + pstrUsageSecondaryTipSwitch, + pstrUsageBarrelSwitch, + pstrUsageEraser, + pstrUsageTabletPick +}; +const char * const ReportDescParserBase::aplphanumTitles0[] PROGMEM = { + pstrUsageAlphanumericDisplay, + pstrUsageBitmappedDisplay +}; +const char * const ReportDescParserBase::aplphanumTitles1[] PROGMEM = { + pstrUsageDisplayAttributesReport, + pstrUsageASCIICharacterSet, + pstrUsageDataReadBack, + pstrUsageFontReadBack, + pstrUsageDisplayControlReport, + pstrUsageClearDisplay, + pstrUsageDisplayEnable, + pstrUsageScreenSaverDelay, + pstrUsageScreenSaverEnable, + pstrUsageVerticalScroll, + pstrUsageHorizontalScroll, + pstrUsageCharacterReport, + pstrUsageDisplayData, + pstrUsageDisplayStatus, + pstrUsageStatusNotReady, + pstrUsageStatusReady, + pstrUsageErrorNotALoadableCharacter, + pstrUsageErrorFotDataCanNotBeRead, + pstrUsageCursorPositionReport, + pstrUsageRow, + pstrUsageColumn, + pstrUsageRows, + pstrUsageColumns, + pstrUsageCursorPixelPosition, + pstrUsageCursorMode, + pstrUsageCursorEnable, + pstrUsageCursorBlink, + pstrUsageFontReport, + pstrUsageFontData, + pstrUsageCharacterWidth, + pstrUsageCharacterHeight, + pstrUsageCharacterSpacingHorizontal, + pstrUsageCharacterSpacingVertical, + pstrUsageUnicodeCharset, + pstrUsageFont7Segment, + pstrUsage7SegmentDirectMap, + pstrUsageFont14Segment, + pstrUsage14SegmentDirectMap, + pstrUsageDisplayBrightness, + pstrUsageDisplayContrast, + pstrUsageCharacterAttribute, + pstrUsageAttributeReadback, + pstrUsageAttributeData, + pstrUsageCharAttributeEnhance, + pstrUsageCharAttributeUnderline, + pstrUsageCharAttributeBlink +}; +const char * const ReportDescParserBase::aplphanumTitles2[] PROGMEM = { + pstrUsageBitmapSizeX, + pstrUsageBitmapSizeY, + pstrUsagePageReserved, + pstrUsageBitDepthFormat, + pstrUsageDisplayOrientation, + pstrUsagePaletteReport, + pstrUsagePaletteDataSize, + pstrUsagePaletteDataOffset, + pstrUsagePaletteData, + pstrUsageBlitReport, + pstrUsageBlitRectangleX1, + pstrUsageBlitRectangleY1, + pstrUsageBlitRectangleX2, + pstrUsageBlitRectangleY2, + pstrUsageBlitData, + pstrUsageSoftButton, + pstrUsageSoftButtonID, + pstrUsageSoftButtonSide, + pstrUsageSoftButtonOffset1, + pstrUsageSoftButtonOffset2, + pstrUsageSoftButtonReport +}; +const char * const ReportDescParserBase::medInstrTitles0[] PROGMEM = { + pstrUsageVCRAcquisition, + pstrUsageFreezeThaw, + pstrUsageClipStore, + pstrUsageUpdate, + pstrUsageNext, + pstrUsageSave, + pstrUsagePrint, + pstrUsageMicrophoneEnable +}; +const char * const ReportDescParserBase::medInstrTitles1[] PROGMEM = { + pstrUsageCine, + pstrUsageTransmitPower, + pstrUsageVolume, + pstrUsageFocus, + pstrUsageDepth +}; +const char * const ReportDescParserBase::medInstrTitles2[] PROGMEM = { + pstrUsageSoftStepPrimary, + pstrUsageSoftStepSecondary +}; +const char * const ReportDescParserBase::medInstrTitles3[] PROGMEM = { + pstrUsageZoomSelect, + pstrUsageZoomAdjust, + pstrUsageSpectralDopplerModeSelect, + pstrUsageSpectralDopplerModeAdjust, + pstrUsageColorDopplerModeSelect, + pstrUsageColorDopplerModeAdjust, + pstrUsageMotionModeSelect, + pstrUsageMotionModeAdjust, + pstrUsage2DModeSelect, + pstrUsage2DModeAdjust +}; +const char * const ReportDescParserBase::medInstrTitles4[] PROGMEM = { + pstrUsageSoftControlSelect, + pstrUsageSoftControlAdjust +}; + +void ReportDescParserBase::Parse(const uint32_t len, const uint8_t *pbuf, const uint32_t & /* offset */) { + uint32_t cntdn = (uint32_t)len; + uint8_t *p = (uint8_t*)pbuf; + + + totalSize = 0; + + while(cntdn) { + //USB_HOST_SERIAL.println(""); + //PrintHex(offset + len - cntdn); + //USB_HOST_SERIAL.print(":"); + + ParseItem(&p, &cntdn); + + //if (ParseItem(&p, &cntdn)) + // return; + } + //USBTRACE2("Total:", totalSize); +} + +void ReportDescParserBase::PrintValue(uint8_t *p, uint8_t len) { + E_Notify(PSTR("("), 0x80); + for(; len; p++, len--) + PrintHex (*p, 0x80); + E_Notify(PSTR(")"), 0x80); +} + +void ReportDescParserBase::PrintByteValue(uint8_t data) { + E_Notify(PSTR("("), 0x80); + PrintHex (data, 0x80); + E_Notify(PSTR(")"), 0x80); +} + +void ReportDescParserBase::PrintItemTitle(uint8_t prefix) { + switch(prefix & (TYPE_MASK | TAG_MASK)) { + case (TYPE_GLOBAL | TAG_GLOBAL_PUSH): + E_Notify(PSTR("\r\nPush"), 0x80); + break; + case (TYPE_GLOBAL | TAG_GLOBAL_POP): + E_Notify(PSTR("\r\nPop"), 0x80); + break; + case (TYPE_GLOBAL | TAG_GLOBAL_USAGEPAGE): + E_Notify(PSTR("\r\nUsage Page"), 0x80); + break; + case (TYPE_GLOBAL | TAG_GLOBAL_LOGICALMIN): + E_Notify(PSTR("\r\nLogical Min"), 0x80); + break; + case (TYPE_GLOBAL | TAG_GLOBAL_LOGICALMAX): + E_Notify(PSTR("\r\nLogical Max"), 0x80); + break; + case (TYPE_GLOBAL | TAG_GLOBAL_PHYSMIN): + E_Notify(PSTR("\r\nPhysical Min"), 0x80); + break; + case (TYPE_GLOBAL | TAG_GLOBAL_PHYSMAX): + E_Notify(PSTR("\r\nPhysical Max"), 0x80); + break; + case (TYPE_GLOBAL | TAG_GLOBAL_UNITEXP): + E_Notify(PSTR("\r\nUnit Exp"), 0x80); + break; + case (TYPE_GLOBAL | TAG_GLOBAL_UNIT): + E_Notify(PSTR("\r\nUnit"), 0x80); + break; + case (TYPE_GLOBAL | TAG_GLOBAL_REPORTSIZE): + E_Notify(PSTR("\r\nReport Size"), 0x80); + break; + case (TYPE_GLOBAL | TAG_GLOBAL_REPORTCOUNT): + E_Notify(PSTR("\r\nReport Count"), 0x80); + break; + case (TYPE_GLOBAL | TAG_GLOBAL_REPORTID): + E_Notify(PSTR("\r\nReport Id"), 0x80); + break; + case (TYPE_LOCAL | TAG_LOCAL_USAGE): + E_Notify(PSTR("\r\nUsage"), 0x80); + break; + case (TYPE_LOCAL | TAG_LOCAL_USAGEMIN): + E_Notify(PSTR("\r\nUsage Min"), 0x80); + break; + case (TYPE_LOCAL | TAG_LOCAL_USAGEMAX): + E_Notify(PSTR("\r\nUsage Max"), 0x80); + break; + case (TYPE_MAIN | TAG_MAIN_COLLECTION): + E_Notify(PSTR("\r\nCollection"), 0x80); + break; + case (TYPE_MAIN | TAG_MAIN_ENDCOLLECTION): + E_Notify(PSTR("\r\nEnd Collection"), 0x80); + break; + case (TYPE_MAIN | TAG_MAIN_INPUT): + E_Notify(PSTR("\r\nInput"), 0x80); + break; + case (TYPE_MAIN | TAG_MAIN_OUTPUT): + E_Notify(PSTR("\r\nOutput"), 0x80); + break; + case (TYPE_MAIN | TAG_MAIN_FEATURE): + E_Notify(PSTR("\r\nFeature"), 0x80); + break; + } // switch (**pp & (TYPE_MASK | TAG_MASK)) +} + +uint8_t ReportDescParserBase::ParseItem(uint8_t **pp, uint32_t *pcntdn) { + //uint8_t ret = enErrorSuccess; + //reinterpret_cast<>(varBuffer); + switch(itemParseState) { + case 0: + if(**pp == HID_LONG_ITEM_PREFIX) + USBTRACE("\r\nLONG\r\n"); + else { + uint8_t size = ((**pp) & DATA_SIZE_MASK); + + itemPrefix = (**pp); + itemSize = 1 + ((size == DATA_SIZE_4) ? 4 : size); + + PrintItemTitle(itemPrefix); + } + (*pp)++; + (*pcntdn)--; + itemSize--; + itemParseState = 1; + + if(!itemSize) + break; + + if(!pcntdn) + return enErrorIncomplete; + case 1: + //USBTRACE2("\r\niSz:",itemSize); + + theBuffer.valueSize = itemSize; + valParser.Initialize(&theBuffer); + itemParseState = 2; + case 2: + if(!valParser.Parse(pp, pcntdn)) + return enErrorIncomplete; + itemParseState = 3; + case 3: + { + uint8_t data = *((uint8_t*)varBuffer); + + switch(itemPrefix & (TYPE_MASK | TAG_MASK)) { + case (TYPE_LOCAL | TAG_LOCAL_USAGE): + if(pfUsage) { + if(theBuffer.valueSize > 1) { + uint16_t* ui16 = reinterpret_cast(varBuffer); + pfUsage(*ui16); + } else + pfUsage(data); + } + break; + case (TYPE_GLOBAL | TAG_GLOBAL_REPORTSIZE): + rptSize = data; + PrintByteValue(data); + break; + case (TYPE_GLOBAL | TAG_GLOBAL_REPORTCOUNT): + rptCount = data; + PrintByteValue(data); + break; + case (TYPE_GLOBAL | TAG_GLOBAL_LOGICALMIN): + case (TYPE_GLOBAL | TAG_GLOBAL_LOGICALMAX): + case (TYPE_GLOBAL | TAG_GLOBAL_PHYSMIN): + case (TYPE_GLOBAL | TAG_GLOBAL_PHYSMAX): + case (TYPE_GLOBAL | TAG_GLOBAL_REPORTID): + case (TYPE_LOCAL | TAG_LOCAL_USAGEMIN): + case (TYPE_LOCAL | TAG_LOCAL_USAGEMAX): + case (TYPE_GLOBAL | TAG_GLOBAL_UNITEXP): + case (TYPE_GLOBAL | TAG_GLOBAL_UNIT): + PrintValue(varBuffer, theBuffer.valueSize); + break; + case (TYPE_GLOBAL | TAG_GLOBAL_PUSH): + case (TYPE_GLOBAL | TAG_GLOBAL_POP): + break; + case (TYPE_GLOBAL | TAG_GLOBAL_USAGEPAGE): + SetUsagePage(data); + PrintUsagePage(data); + PrintByteValue(data); + break; + case (TYPE_MAIN | TAG_MAIN_COLLECTION): + case (TYPE_MAIN | TAG_MAIN_ENDCOLLECTION): + switch(data) { + case 0x00: + E_Notify(PSTR(" Physical"), 0x80); + break; + case 0x01: + E_Notify(PSTR(" Application"), 0x80); + break; + case 0x02: + E_Notify(PSTR(" Logical"), 0x80); + break; + case 0x03: + E_Notify(PSTR(" Report"), 0x80); + break; + case 0x04: + E_Notify(PSTR(" Named Array"), 0x80); + break; + case 0x05: + E_Notify(PSTR(" Usage Switch"), 0x80); + break; + case 0x06: + E_Notify(PSTR(" Usage Modifier"), 0x80); + break; + default: + E_Notify(PSTR(" Vendor Defined("), 0x80); + PrintHex (data, 0x80); + E_Notify(PSTR(")"), 0x80); + } + break; + case (TYPE_MAIN | TAG_MAIN_INPUT): + case (TYPE_MAIN | TAG_MAIN_OUTPUT): + case (TYPE_MAIN | TAG_MAIN_FEATURE): + totalSize += (uint16_t)rptSize * (uint16_t)rptCount; + rptSize = 0; + rptCount = 0; + E_Notify(PSTR("("), 0x80); + PrintBin (data, 0x80); + E_Notify(PSTR(")"), 0x80); + break; + } // switch (**pp & (TYPE_MASK | TAG_MASK)) + } + } // switch (itemParseState) + itemParseState = 0; + return enErrorSuccess; +} + +ReportDescParserBase::UsagePageFunc ReportDescParserBase::usagePageFunctions[] /*PROGMEM*/ = { + &ReportDescParserBase::PrintGenericDesktopPageUsage, + &ReportDescParserBase::PrintSimulationControlsPageUsage, + &ReportDescParserBase::PrintVRControlsPageUsage, + &ReportDescParserBase::PrintSportsControlsPageUsage, + &ReportDescParserBase::PrintGameControlsPageUsage, + &ReportDescParserBase::PrintGenericDeviceControlsPageUsage, + NULL, // Keyboard/Keypad + &ReportDescParserBase::PrintLEDPageUsage, + &ReportDescParserBase::PrintButtonPageUsage, + &ReportDescParserBase::PrintOrdinalPageUsage, + &ReportDescParserBase::PrintTelephonyPageUsage, + &ReportDescParserBase::PrintConsumerPageUsage, + &ReportDescParserBase::PrintDigitizerPageUsage, + NULL, // Reserved + NULL, // PID + NULL // Unicode +}; + +void ReportDescParserBase::SetUsagePage(uint16_t page) { + pfUsage = NULL; + + if(VALUE_BETWEEN(page, 0x00, 0x11)) + pfUsage = (usagePageFunctions[page - 1]); + + // Dead code... + // + // pfUsage = (UsagePageFunc)pgm_read_pointer(usagePageFunctions[page - 1]); + //else if (page > 0x7f && page < 0x84) + // E_Notify(pstrUsagePageMonitor); + //else if (page > 0x83 && page < 0x8c) + // E_Notify(pstrUsagePagePower); + //else if (page > 0x8b && page < 0x92) + // E_Notify((char*)pgm_read_pointer(&usagePageTitles1[page - 0x8c])); + //else if (page > 0xfeff && page <= 0xffff) + // E_Notify(pstrUsagePageVendorDefined); + // + else + switch(page) { + case 0x14: + pfUsage = &ReportDescParserBase::PrintAlphanumDisplayPageUsage; + break; + case 0x40: + pfUsage = &ReportDescParserBase::PrintMedicalInstrumentPageUsage; + break; + } +} + +void ReportDescParserBase::PrintUsagePage(uint16_t page) { + const char * const * w; + E_Notify(pstrSpace, 0x80); + + output_if_between(page, 0x00, 0x11, w, E_Notify, usagePageTitles0, 0x80) + else output_if_between(page, 0x8b, 0x92, w, E_Notify, usagePageTitles1, 0x80) + else if(VALUE_BETWEEN(page, 0x7f, 0x84)) + E_Notify(pstrUsagePageMonitor, 0x80); + else if(VALUE_BETWEEN(page, 0x83, 0x8c)) + E_Notify(pstrUsagePagePower, 0x80); + else if(page > 0xfeff /* && page <= 0xffff */) + E_Notify(pstrUsagePageVendorDefined, 0x80); + else + switch(page) { + case 0x14: + E_Notify(pstrUsagePageAlphaNumericDisplay, 0x80); + break; + case 0x40: + E_Notify(pstrUsagePageMedicalInstruments, 0x80); + break; + default: + E_Notify(pstrUsagePageUndefined, 0x80); + } +} + +void ReportDescParserBase::PrintButtonPageUsage(uint16_t usage) { + E_Notify(pstrSpace, 0x80); + E_Notify(PSTR("Btn"), 0x80); + PrintHex (usage, 0x80); + E_Notify(PSTR("\r\n"), 0x80); + //USB_HOST_SERIAL.print(usage, HEX); +} + +void ReportDescParserBase::PrintOrdinalPageUsage(uint16_t usage) { + E_Notify(pstrSpace, 0x80); + E_Notify(PSTR("Inst"), 0x80); + // Sorry, HEX for now... + PrintHex (usage, 0x80); + E_Notify(PSTR("\r\n"), 0x80); + //USB_HOST_SERIAL.print(usage, DEC); +} + +void ReportDescParserBase::PrintGenericDesktopPageUsage(uint16_t usage) { + const char * const * w; + E_Notify(pstrSpace, 0x80); + + output_if_between(usage, 0x00, 0x0a, w, E_Notify, genDesktopTitles0, 0x80) + else output_if_between(usage, 0x2f, 0x49, w, E_Notify, genDesktopTitles1, 0x80) + else output_if_between(usage, 0x7f, 0x94, w, E_Notify, genDesktopTitles2, 0x80) + else output_if_between(usage, 0x9f, 0xa9, w, E_Notify, genDesktopTitles3, 0x80) + else output_if_between(usage, 0xaf, 0xb8, w, E_Notify, genDesktopTitles4, 0x80) + else E_Notify(pstrUsagePageUndefined, 0x80); +} + +void ReportDescParserBase::PrintSimulationControlsPageUsage(uint16_t usage) { + const char * const * w; + E_Notify(pstrSpace, 0x80); + + output_if_between(usage, 0x00, 0x0d, w, E_Notify, simuTitles0, 0x80) + else output_if_between(usage, 0x1f, 0x26, w, E_Notify, simuTitles1, 0x80) + else output_if_between(usage, 0xaf, 0xd1, w, E_Notify, simuTitles2, 0x80) + else E_Notify(pstrUsagePageUndefined, 0x80); +} + +void ReportDescParserBase::PrintVRControlsPageUsage(uint16_t usage) { + const char * const * w; + E_Notify(pstrSpace, 0x80); + + output_if_between(usage, 0x00, 0x0b, w, E_Notify, vrTitles0, 0x80) + else output_if_between(usage, 0x1f, 0x22, w, E_Notify, vrTitles1, 0x80) + else E_Notify(pstrUsagePageUndefined, 0x80); +} + +void ReportDescParserBase::PrintSportsControlsPageUsage(uint16_t usage) { + const char * const * w; + E_Notify(pstrSpace, 0x80); + + output_if_between(usage, 0x00, 0x05, w, E_Notify, sportsCtrlTitles0, 0x80) + else output_if_between(usage, 0x2f, 0x3a, w, E_Notify, sportsCtrlTitles1, 0x80) + else output_if_between(usage, 0x4f, 0x64, w, E_Notify, sportsCtrlTitles2, 0x80) + else E_Notify(pstrUsagePageUndefined, 0x80); +} + +void ReportDescParserBase::PrintGameControlsPageUsage(uint16_t usage) { + const char * const * w; + E_Notify(pstrSpace, 0x80); + + output_if_between(usage, 0x00, 0x04, w, E_Notify, gameTitles0, 0x80) + else output_if_between(usage, 0x1f, 0x3a, w, E_Notify, gameTitles1, 0x80) + else E_Notify(pstrUsagePageUndefined, 0x80); +} + +void ReportDescParserBase::PrintGenericDeviceControlsPageUsage(uint16_t usage) { + const char * const * w; + E_Notify(pstrSpace, 0x80); + + output_if_between(usage, 0x1f, 0x27, w, E_Notify, genDevCtrlTitles, 0x80) + else E_Notify(pstrUsagePageUndefined, 0x80); +} + +void ReportDescParserBase::PrintLEDPageUsage(uint16_t usage) { + const char * const * w; + E_Notify(pstrSpace, 0x80); + + output_if_between(usage, 0x00, 0x4e, w, E_Notify, ledTitles, 0x80) + else E_Notify(pstrUsagePageUndefined, 0x80); +} + +void ReportDescParserBase::PrintTelephonyPageUsage(uint16_t usage) { + const char * const * w; + E_Notify(pstrSpace, 0x80); + + output_if_between(usage, 0x00, 0x08, w, E_Notify, telTitles0, 0x80) + else output_if_between(usage, 0x1f, 0x32, w, E_Notify, telTitles1, 0x80) + else output_if_between(usage, 0x4f, 0x54, w, E_Notify, telTitles2, 0x80) + else output_if_between(usage, 0x6f, 0x75, w, E_Notify, telTitles3, 0x80) + else output_if_between(usage, 0x8f, 0x9f, w, E_Notify, telTitles4, 0x80) + else output_if_between(usage, 0xaf, 0xc0, w, E_Notify, telTitles5, 0x80) + else E_Notify(pstrUsagePageUndefined, 0x80); +} + +void ReportDescParserBase::PrintConsumerPageUsage(uint16_t usage) { + const char * const * w; + E_Notify(pstrSpace, 0x80); + + output_if_between(usage, 0x00, 0x07, w, E_Notify, consTitles0, 0x80) + else output_if_between(usage, 0x1f, 0x23, w, E_Notify, consTitles1, 0x80) + else output_if_between(usage, 0x2f, 0x37, w, E_Notify, consTitles2, 0x80) + else output_if_between(usage, 0x3f, 0x49, w, E_Notify, consTitles3, 0x80) + else output_if_between(usage, 0x5f, 0x67, w, E_Notify, consTitles4, 0x80) + else output_if_between(usage, 0x7f, 0xa5, w, E_Notify, consTitles5, 0x80) + else output_if_between(usage, 0xaf, 0xcf, w, E_Notify, consTitles6, 0x80) + else output_if_between(usage, 0xdf, 0xeb, w, E_Notify, consTitles7, 0x80) + else output_if_between(usage, 0xef, 0xf6, w, E_Notify, consTitles8, 0x80) + else output_if_between(usage, 0xff, 0x10e, w, E_Notify, consTitles9, 0x80) + else output_if_between(usage, 0x14f, 0x156, w, E_Notify, consTitlesA, 0x80) + else output_if_between(usage, 0x15f, 0x16b, w, E_Notify, consTitlesB, 0x80) + else output_if_between(usage, 0x16f, 0x175, w, E_Notify, consTitlesC, 0x80) + else output_if_between(usage, 0x17f, 0x1c8, w, E_Notify, consTitlesD, 0x80) + else output_if_between(usage, 0x1ff, 0x29d, w, E_Notify, consTitlesE, 0x80) + else E_Notify(pstrUsagePageUndefined, 0x80); +} + +void ReportDescParserBase::PrintDigitizerPageUsage(uint16_t usage) { + const char * const * w; + E_Notify(pstrSpace, 0x80); + + output_if_between(usage, 0x00, 0x0e, w, E_Notify, digitTitles0, 0x80) + else output_if_between(usage, 0x1f, 0x23, w, E_Notify, digitTitles1, 0x80) + else output_if_between(usage, 0x2f, 0x47, w, E_Notify, digitTitles2, 0x80) + else E_Notify(pstrUsagePageUndefined, 0x80); +} + +void ReportDescParserBase::PrintAlphanumDisplayPageUsage(uint16_t usage) { + const char * const * w; + E_Notify(pstrSpace, 0x80); + + output_if_between(usage, 0x00, 0x03, w, E_Notify, aplphanumTitles0, 0x80) + else output_if_between(usage, 0x1f, 0x4e, w, E_Notify, aplphanumTitles1, 0x80) + else output_if_between(usage, 0x7f, 0x96, w, E_Notify, digitTitles2, 0x80) + else E_Notify(pstrUsagePageUndefined, 0x80); +} + +void ReportDescParserBase::PrintMedicalInstrumentPageUsage(uint16_t usage) { + const char * const * w; + E_Notify(pstrSpace, 0x80); + + if(usage == 1) E_Notify(pstrUsageMedicalUltrasound, 0x80); + else if(usage == 0x70) + E_Notify(pstrUsageDepthGainCompensation, 0x80); + else output_if_between(usage, 0x1f, 0x28, w, E_Notify, medInstrTitles0, 0x80) + else output_if_between(usage, 0x3f, 0x45, w, E_Notify, medInstrTitles1, 0x80) + else output_if_between(usage, 0x5f, 0x62, w, E_Notify, medInstrTitles2, 0x80) + else output_if_between(usage, 0x7f, 0x8a, w, E_Notify, medInstrTitles3, 0x80) + else output_if_between(usage, 0x9f, 0xa2, w, E_Notify, medInstrTitles4, 0x80) + else E_Notify(pstrUsagePageUndefined, 0x80); +} + +uint8_t ReportDescParser2::ParseItem(uint8_t **pp, uint32_t *pcntdn) { + //uint8_t ret = enErrorSuccess; + + switch(itemParseState) { + case 0: + if(**pp == HID_LONG_ITEM_PREFIX) + USBTRACE("\r\nLONG\r\n"); + else { + uint8_t size = ((**pp) & DATA_SIZE_MASK); + itemPrefix = (**pp); + itemSize = 1 + ((size == DATA_SIZE_4) ? 4 : size); + } + (*pp)++; + (*pcntdn)--; + itemSize--; + itemParseState = 1; + + if(!itemSize) + break; + + if(!pcntdn) + return enErrorIncomplete; + case 1: + theBuffer.valueSize = itemSize; + valParser.Initialize(&theBuffer); + itemParseState = 2; + case 2: + if(!valParser.Parse(pp, pcntdn)) + return enErrorIncomplete; + itemParseState = 3; + case 3: + { + uint8_t data = *((uint8_t*)varBuffer); + + switch(itemPrefix & (TYPE_MASK | TAG_MASK)) { + case (TYPE_LOCAL | TAG_LOCAL_USAGE): + if(pfUsage) { + if(theBuffer.valueSize > 1) { + uint16_t* ui16 = reinterpret_cast(varBuffer); + pfUsage(*ui16); + } else + pfUsage(data); + } + break; + case (TYPE_GLOBAL | TAG_GLOBAL_REPORTSIZE): + rptSize = data; + break; + case (TYPE_GLOBAL | TAG_GLOBAL_REPORTCOUNT): + rptCount = data; + break; + case (TYPE_GLOBAL | TAG_GLOBAL_REPORTID): + rptId = data; + break; + case (TYPE_LOCAL | TAG_LOCAL_USAGEMIN): + useMin = data; + break; + case (TYPE_LOCAL | TAG_LOCAL_USAGEMAX): + useMax = data; + break; + case (TYPE_GLOBAL | TAG_GLOBAL_USAGEPAGE): + SetUsagePage(data); + break; + case (TYPE_MAIN | TAG_MAIN_OUTPUT): + case (TYPE_MAIN | TAG_MAIN_FEATURE): + rptSize = 0; + rptCount = 0; + useMin = 0; + useMax = 0; + break; + case (TYPE_MAIN | TAG_MAIN_INPUT): + OnInputItem(data); + + totalSize += (uint16_t)rptSize * (uint16_t)rptCount; + + rptSize = 0; + rptCount = 0; + useMin = 0; + useMax = 0; + break; + } // switch (**pp & (TYPE_MASK | TAG_MASK)) + } + } // switch (itemParseState) + itemParseState = 0; + return enErrorSuccess; +} + +void ReportDescParser2::OnInputItem(uint8_t itm) { + uint8_t byte_offset = (totalSize >> 3); // calculate offset to the next unhandled byte i = (int)(totalCount / 8); + uint32_t tmp = (byte_offset << 3); + uint8_t bit_offset = totalSize - tmp; // number of bits in the current byte already handled + uint8_t *p = pBuf + byte_offset; // current byte pointer + + if(bit_offset) + *p >>= bit_offset; + + uint8_t usage = useMin; + + bool print_usemin_usemax = ((useMin < useMax) && ((itm & 3) == 2) && pfUsage) ? true : false; + + uint8_t bits_of_byte = 8; + + // for each field in field array defined by rptCount + for(uint8_t field = 0; field < rptCount; field++, usage++) { + + union { + uint8_t bResult[4]; + uint16_t wResult[2]; + uint32_t dwResult; + } result; + + result.dwResult = 0; + uint8_t mask = 0; + + if(print_usemin_usemax) + pfUsage(usage); + + // bits_left - number of bits in the field(array of fields, depending on Report Count) left to process + // bits_of_byte - number of bits in current byte left to process + // bits_to_copy - number of bits to copy to result buffer + + // for each bit in a field + for(uint8_t bits_left = rptSize, bits_to_copy = 0; bits_left; + bits_left -= bits_to_copy) { + bits_to_copy = (bits_left > bits_of_byte) ? bits_of_byte : bits_left; + + result.dwResult <<= bits_to_copy; // Result buffer is shifted by the number of bits to be copied into it + + uint8_t val = *p; + + val >>= (8 - bits_of_byte); // Shift by the number of bits already processed + + mask = 0; + + for(uint8_t j = bits_to_copy; j; j--) { + mask <<= 1; + mask |= 1; + } + + result.bResult[0] = (result.bResult[0] | (val & mask)); + + bits_of_byte -= bits_to_copy; + + if(bits_of_byte < 1) { + bits_of_byte = 8; + p++; + } + } + PrintByteValue(result.dwResult); + } + E_Notify(PSTR("\r\n"), 0x80); +} + +void UniversalReportParser::Parse(HID *hid, uint32_t /* is_rpt_id */, uint32_t len, uint8_t *buf) { + ReportDescParser2 prs(len, buf); + + uint8_t ret = hid->GetReportDescr(0, &prs); + + if(ret) + ErrorMessage (PSTR("GetReportDescr-2"), ret); +} diff --git a/libraries/USBHost/src/hidescriptorparser.h b/libraries/USBHost/src/hidescriptorparser.h new file mode 100644 index 0000000..920b4ee --- /dev/null +++ b/libraries/USBHost/src/hidescriptorparser.h @@ -0,0 +1,173 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com + */ +#if !defined(__HIDDESCRIPTORPARSER_H__) +#define __HIDDESCRIPTORPARSER_H__ + +#include "hid.h" + +class ReportDescParserBase : public USBReadParser { +public: + typedef void (*UsagePageFunc)(uint16_t usage); + + static void PrintGenericDesktopPageUsage(uint16_t usage); + static void PrintSimulationControlsPageUsage(uint16_t usage); + static void PrintVRControlsPageUsage(uint16_t usage); + static void PrintSportsControlsPageUsage(uint16_t usage); + static void PrintGameControlsPageUsage(uint16_t usage); + static void PrintGenericDeviceControlsPageUsage(uint16_t usage); + static void PrintLEDPageUsage(uint16_t usage); + static void PrintButtonPageUsage(uint16_t usage); + static void PrintOrdinalPageUsage(uint16_t usage); + static void PrintTelephonyPageUsage(uint16_t usage); + static void PrintConsumerPageUsage(uint16_t usage); + static void PrintDigitizerPageUsage(uint16_t usage); + static void PrintAlphanumDisplayPageUsage(uint16_t usage); + static void PrintMedicalInstrumentPageUsage(uint16_t usage); + + static void PrintValue(uint8_t *p, uint8_t len); + static void PrintByteValue(uint8_t data); + + static void PrintItemTitle(uint8_t prefix); + + static const char * const usagePageTitles0[]; + static const char * const usagePageTitles1[]; + static const char * const genDesktopTitles0[]; + static const char * const genDesktopTitles1[]; + static const char * const genDesktopTitles2[]; + static const char * const genDesktopTitles3[]; + static const char * const genDesktopTitles4[]; + static const char * const simuTitles0[]; + static const char * const simuTitles1[]; + static const char * const simuTitles2[]; + static const char * const vrTitles0[]; + static const char * const vrTitles1[]; + static const char * const sportsCtrlTitles0[]; + static const char * const sportsCtrlTitles1[]; + static const char * const sportsCtrlTitles2[]; + static const char * const gameTitles0[]; + static const char * const gameTitles1[]; + static const char * const genDevCtrlTitles[]; + static const char * const ledTitles[]; + static const char * const telTitles0[]; + static const char * const telTitles1[]; + static const char * const telTitles2[]; + static const char * const telTitles3[]; + static const char * const telTitles4[]; + static const char * const telTitles5[]; + static const char * const consTitles0[]; + static const char * const consTitles1[]; + static const char * const consTitles2[]; + static const char * const consTitles3[]; + static const char * const consTitles4[]; + static const char * const consTitles5[]; + static const char * const consTitles6[]; + static const char * const consTitles7[]; + static const char * const consTitles8[]; + static const char * const consTitles9[]; + static const char * const consTitlesA[]; + static const char * const consTitlesB[]; + static const char * const consTitlesC[]; + static const char * const consTitlesD[]; + static const char * const consTitlesE[]; + static const char * const digitTitles0[]; + static const char * const digitTitles1[]; + static const char * const digitTitles2[]; + static const char * const aplphanumTitles0[]; + static const char * const aplphanumTitles1[]; + static const char * const aplphanumTitles2[]; + static const char * const medInstrTitles0[]; + static const char * const medInstrTitles1[]; + static const char * const medInstrTitles2[]; + static const char * const medInstrTitles3[]; + static const char * const medInstrTitles4[]; + +protected: + static UsagePageFunc usagePageFunctions[]; + + MultiValueBuffer theBuffer; + MultiByteValueParser valParser; + ByteSkipper theSkipper; + uint8_t varBuffer[sizeof (USB_CONFIGURATION_DESCRIPTOR)]; + + uint8_t itemParseState; // Item parser state variable + uint8_t itemSize; // Item size + uint8_t itemPrefix; // Item prefix (first byte) + uint8_t rptSize; // Report Size + uint8_t rptCount; // Report Count + + uint16_t totalSize; // Report size in bits + + virtual uint8_t ParseItem(uint8_t **pp, uint32_t *pcntdn); + + UsagePageFunc pfUsage; + + static void PrintUsagePage(uint16_t page); + void SetUsagePage(uint16_t page); + +public: + + ReportDescParserBase() : + itemParseState(0), + itemSize(0), + itemPrefix(0), + rptSize(0), + rptCount(0), + pfUsage(NULL) { + theBuffer.pValue = varBuffer; + valParser.Initialize(&theBuffer); + theSkipper.Initialize(&theBuffer); + }; + + virtual void Parse(const uint32_t len, const uint8_t *pbuf, const uint32_t &offset); + + enum { + enErrorSuccess = 0 + , enErrorIncomplete // value or record is partialy read in buffer + , enErrorBufferTooSmall + }; +}; + +class ReportDescParser : public ReportDescParserBase { +}; + +class ReportDescParser2 : public ReportDescParserBase { + uint8_t rptId; // Report ID + uint8_t useMin; // Usage Minimum + uint8_t useMax; // Usage Maximum + uint8_t fieldCount; // Number of field being currently processed + + void OnInputItem(uint8_t itm); // Method which is called every time Input item is found + + uint8_t *pBuf; // Report buffer pointer + uint8_t bLen; // Report length + +protected: + virtual uint8_t ParseItem(uint8_t **pp, uint32_t *pcntdn); + +public: + + ReportDescParser2(uint16_t len, uint8_t *pbuf) : + ReportDescParserBase(), rptId(0), useMin(0), useMax(0), fieldCount(0), pBuf(pbuf), bLen(len) { + }; +}; + +class UniversalReportParser : public HIDReportParser { +public: + virtual void Parse(HID *hid, uint32_t is_rpt_id, uint32_t len, uint8_t *buf); +}; + +#endif // __HIDDESCRIPTORPARSER_H__ diff --git a/libraries/USBHost/src/hiduniversal.cpp b/libraries/USBHost/src/hiduniversal.cpp new file mode 100644 index 0000000..7c6764b --- /dev/null +++ b/libraries/USBHost/src/hiduniversal.cpp @@ -0,0 +1,423 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com + */ + +#include "Arduino.h" +#include "hiduniversal.h" + +HIDUniversal::HIDUniversal(USBHost *p) : +HID(p), +qNextPollTime(0), +pollInterval(0), +bPollEnable(false), +bHasReportId(false) { + Initialize(); + + if(pUsb) + pUsb->RegisterDeviceClass(this); +} + +uint16_t HIDUniversal::GetHidClassDescrLen(uint8_t type, uint8_t num) { + for(uint8_t i = 0, n = 0; i < HID_MAX_HID_CLASS_DESCRIPTORS; i++) { + if(descrInfo[i].bDescrType == type) { + if(n == num) + return descrInfo[i].wDescriptorLength; + n++; + } + } + return 0; +} + +void HIDUniversal::Initialize() { + for(uint8_t i = 0; i < MAX_REPORT_PARSERS; i++) { + rptParsers[i].rptId = 0; + rptParsers[i].rptParser = NULL; + } + for(uint8_t i = 0; i < HID_MAX_HID_CLASS_DESCRIPTORS; i++) { + descrInfo[i].bDescrType = 0; + descrInfo[i].wDescriptorLength = 0; + } + for(uint8_t i = 0; i < maxHidInterfaces; i++) { + hidInterfaces[i].bmInterface = 0; + hidInterfaces[i].bmProtocol = 0; + + for(uint8_t j = 0; j < maxEpPerInterface; j++) + hidInterfaces[i].epIndex[j] = 0; + } + for(uint8_t i = 0; i < totalEndpoints; i++) { + epInfo[i].epAddr = 0; + epInfo[i].maxPktSize = (i) ? 0 : 8; + epInfo[i].bmSndToggle = 0; + epInfo[i].bmRcvToggle = 0; + epInfo[i].bmNakPower = (i) ? USB_NAK_NOWAIT : USB_NAK_MAX_POWER; + } + bNumEP = 1; + bNumIface = 0; + bConfNum = 0; + pollInterval = 0; + + ZeroMemory(constBuffLen, prevBuf); +} + +uint32_t HIDUniversal::SetReportParser(uint32_t id, HIDReportParser *prs) { + for(uint8_t i = 0; i < MAX_REPORT_PARSERS; i++) { + if(rptParsers[i].rptId == 0 && rptParsers[i].rptParser == NULL) { + rptParsers[i].rptId = id; + rptParsers[i].rptParser = prs; + return true; + } + } + return false; +} + +HIDReportParser* HIDUniversal::GetReportParser(uint32_t id) { + if(!bHasReportId) + return ((rptParsers[0].rptParser) ? rptParsers[0].rptParser : NULL); + + for(uint8_t i = 0; i < MAX_REPORT_PARSERS; i++) { + if(rptParsers[i].rptId == id) + return rptParsers[i].rptParser; + } + return NULL; +} + +uint8_t HIDUniversal::Init(uint8_t parent, uint8_t port, bool lowspeed) { + const uint8_t constBufSize = sizeof (USB_DEVICE_DESCRIPTOR); + + uint8_t buf[constBufSize]; + USB_DEVICE_DESCRIPTOR * udd = reinterpret_cast(buf); + uint8_t rcode; + UsbDeviceDefinition *p = NULL; + EpInfo *oldep_ptr = NULL; + uint8_t len = 0; + + uint8_t num_of_conf; // number of configurations + //uint8_t num_of_intf; // number of interfaces + + AddressPool &addrPool = pUsb->GetAddressPool(); + + USBTRACE("HU Init\r\n"); + + if(bAddress) + return USB_ERROR_CLASS_INSTANCE_ALREADY_IN_USE; + + // Get pointer to pseudo device with address 0 assigned + p = addrPool.GetUsbDevicePtr(0); + + if(!p) + return USB_ERROR_ADDRESS_NOT_FOUND_IN_POOL; + + if(!p->epinfo) { + USBTRACE("epinfo\r\n"); + return USB_ERROR_EPINFO_IS_NULL; + } + + // Save old pointer to EP_RECORD of address 0 + oldep_ptr = p->epinfo; + + // Temporary assign new pointer to epInfo to p->epinfo in order to avoid toggle inconsistence + p->epinfo = epInfo; + + p->lowspeed = lowspeed; + + // Get device descriptor + rcode = pUsb->getDevDescr(0, 0, 8, (uint8_t*)buf); + + if(!rcode) + len = (buf[0] > constBufSize) ? constBufSize : buf[0]; + + if(rcode) { + // Restore p->epinfo + p->epinfo = oldep_ptr; + + goto FailGetDevDescr; + } + + // Restore p->epinfo + p->epinfo = oldep_ptr; + + // Allocate new address according to device class + bAddress = addrPool.AllocAddress(parent, false, port); + + if(!bAddress) + return USB_ERROR_OUT_OF_ADDRESS_SPACE_IN_POOL; + + // Extract Max Packet Size from the device descriptor + epInfo[0].maxPktSize = udd->bMaxPacketSize0; + + // Assign new address to the device + rcode = pUsb->setAddr(0, 0, bAddress); + + if(rcode) { + p->lowspeed = false; + addrPool.FreeAddress(bAddress); + bAddress = 0; + USBTRACE2("setAddr:", rcode); + return rcode; + } + + //delay(2); //per USB 2.0 sect.9.2.6.3 + + USBTRACE2("Addr:", bAddress); + + p->lowspeed = false; + + p = addrPool.GetUsbDevicePtr(bAddress); + + if(!p) + return USB_ERROR_ADDRESS_NOT_FOUND_IN_POOL; + + p->lowspeed = lowspeed; + + if(len) + rcode = pUsb->getDevDescr(bAddress, 0, len, (uint8_t*)buf); + + if(rcode) + goto FailGetDevDescr; + + VID = udd->idVendor; // Can be used by classes that inherits this class to check the VID and PID of the connected device + PID = udd->idProduct; + + num_of_conf = udd->bNumConfigurations; + + // Assign epInfo to epinfo pointer + rcode = pUsb->setEpInfoEntry(bAddress, 1, epInfo); + + if(rcode) + goto FailSetDevTblEntry; + + USBTRACE2("NC:", num_of_conf); + + for(uint8_t i = 0; i < num_of_conf; i++) { + //HexDumper HexDump; + ConfigDescParser confDescrParser(this); + + //rcode = pUsb->getConfDescr(bAddress, 0, i, &HexDump); + rcode = pUsb->getConfDescr(bAddress, 0, i, &confDescrParser); + + if(rcode) + goto FailGetConfDescr; + + if(bNumEP > 1) + break; + } // for + + if(bNumEP < 2) + return USB_DEV_CONFIG_ERROR_DEVICE_NOT_SUPPORTED; + + // Assign epInfo to epinfo pointer + rcode = pUsb->setEpInfoEntry(bAddress, bNumEP, epInfo); + + USBTRACE2("Cnf:", bConfNum); + + // Set Configuration Value + rcode = pUsb->setConf(bAddress, 0, bConfNum); + + if(rcode) + goto FailSetConfDescr; + + for(uint8_t i = 0; i < bNumIface; i++) { + if(hidInterfaces[i].epIndex[epInterruptInIndex] == 0) + continue; + + rcode = SetIdle(hidInterfaces[i].bmInterface, 0, 0); + + if(rcode)/* && rcode != hrSTALL) */ + goto FailSetIdle; + } + + USBTRACE("HU configured\r\n"); + + OnInitSuccessful(); + + bPollEnable = true; + return 0; + +FailGetDevDescr: +#ifdef DEBUG_USB_HOST + NotifyFailGetDevDescr(); + goto Fail; +#endif + +FailSetDevTblEntry: +#ifdef DEBUG_USB_HOST + NotifyFailSetDevTblEntry(); + goto Fail; +#endif + +FailGetConfDescr: +#ifdef DEBUG_USB_HOST + NotifyFailGetConfDescr(); + goto Fail; +#endif + +FailSetConfDescr: +#ifdef DEBUG_USB_HOST + NotifyFailSetConfDescr(); + goto Fail; +#endif + + +FailSetIdle: +#ifdef DEBUG_USB_HOST + USBTRACE("SetIdle:"); +#endif + +#ifdef DEBUG_USB_HOST +Fail: + NotifyFail(rcode); +#endif + Release(); + return rcode; +} + +HIDUniversal::HIDInterface* HIDUniversal::FindInterface(uint8_t iface, uint8_t alt, uint8_t proto) { + for(uint8_t i = 0; i < bNumIface && i < maxHidInterfaces; i++) + if(hidInterfaces[i].bmInterface == iface && hidInterfaces[i].bmAltSet == alt + && hidInterfaces[i].bmProtocol == proto) + return hidInterfaces + i; + return NULL; +} + +void HIDUniversal::EndpointXtract(uint32_t conf, uint32_t iface, uint32_t alt, uint32_t proto, const USB_ENDPOINT_DESCRIPTOR *pep) { + // If the first configuration satisfies, the others are not concidered. + if(bNumEP > 1 && conf != bConfNum) + return; + + //ErrorMessage(PSTR("\r\nConf.Val"), conf); + //ErrorMessage(PSTR("Iface Num"), iface); + //ErrorMessage(PSTR("Alt.Set"), alt); + + bConfNum = conf; + + uint8_t index = 0; + HIDInterface *piface = FindInterface(iface, alt, proto); + + // Fill in interface structure in case of new interface + if(!piface) { + piface = hidInterfaces + bNumIface; + piface->bmInterface = iface; + piface->bmAltSet = alt; + piface->bmProtocol = proto; + bNumIface++; + } + + if((pep->bmAttributes & 0x03) == 3 && (pep->bEndpointAddress & 0x80) == 0x80) + index = epInterruptInIndex; + else + index = epInterruptOutIndex; + + if(index) { + // Fill in the endpoint info structure + epInfo[bNumEP].epAddr = (pep->bEndpointAddress & 0x0F); + epInfo[bNumEP].maxPktSize = (uint8_t)pep->wMaxPacketSize; + epInfo[bNumEP].bmSndToggle = 0; + epInfo[bNumEP].bmRcvToggle = 0; + epInfo[bNumEP].bmNakPower = USB_NAK_NOWAIT; + + // Fill in the endpoint index list + piface->epIndex[index] = bNumEP; //(pep->bEndpointAddress & 0x0F); + + if(pollInterval < pep->bInterval) // Set the polling interval as the largest polling interval obtained from endpoints + pollInterval = pep->bInterval; + + bNumEP++; + } + //PrintEndpointDescriptor(pep); +} + +uint32_t HIDUniversal::Release() { + pUsb->GetAddressPool().FreeAddress(bAddress); + + bNumEP = 1; + bAddress = 0; + qNextPollTime = 0; + bPollEnable = false; + return 0; +} + +bool HIDUniversal::BuffersIdentical(uint8_t len, uint8_t *buf1, uint8_t *buf2) { + for(uint8_t i = 0; i < len; i++) + if(buf1[i] != buf2[i]) + return false; + return true; +} + +void HIDUniversal::ZeroMemory(uint8_t len, uint8_t *buf) { + for(uint8_t i = 0; i < len; i++) + buf[i] = 0; +} + +void HIDUniversal::SaveBuffer(uint8_t len, uint8_t *src, uint8_t *dest) { + for(uint8_t i = 0; i < len; i++) + dest[i] = src[i]; +} + +uint32_t HIDUniversal::Poll() { + uint32_t rcode = 0; + + if(!bPollEnable) + return 0; + + if((long)(millis() - qNextPollTime) >= 0L) { + qNextPollTime = millis() + pollInterval; + + uint8_t buf[constBuffLen]; + + for(uint8_t i = 0; i < bNumIface; i++) { + uint8_t index = hidInterfaces[i].epIndex[epInterruptInIndex]; + uint16_t read = (uint8_t)epInfo[index].maxPktSize; + + ZeroMemory(constBuffLen, buf); + + uint8_t rcode = pUsb->inTransfer(bAddress, epInfo[index].epAddr, (uint8_t*)&read, buf); + + if(rcode) { + if(rcode != USB_ERRORFLOW/*hrNAK*/) + USBTRACE3("(hiduniversal.h) Poll:", rcode, 0x81); + return rcode; + } + + if(read > constBuffLen) + read = constBuffLen; + + bool identical = BuffersIdentical(read, buf, prevBuf); + + SaveBuffer(read, buf, prevBuf); + + if(identical) + return 0; +#if 0 + Notify(PSTR("\r\nBuf: "), 0x80); + + for(uint8_t i = 0; i < read; i++) { + D_PrintHex (buf[i], 0x80); + Notify(PSTR(" "), 0x80); + } + + Notify(PSTR("\r\n"), 0x80); +#endif + ParseHIDData(this, bHasReportId, (uint8_t)read, buf); + + HIDReportParser *prs = GetReportParser(((bHasReportId) ? *buf : 0)); + + if(prs) + prs->Parse(this, bHasReportId, (uint8_t)read, buf); + } + } + return rcode; +} diff --git a/libraries/USBHost/src/hiduniversal.h b/libraries/USBHost/src/hiduniversal.h new file mode 100644 index 0000000..3387619 --- /dev/null +++ b/libraries/USBHost/src/hiduniversal.h @@ -0,0 +1,105 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com + */ + +#if !defined(__HIDUNIVERSAL_H__) +#define __HIDUNIVERSAL_H__ + +#include "hid.h" +//#include "hidescriptorparser.h" + +class HIDUniversal : public HID { + + struct ReportParser { + uint8_t rptId; + HIDReportParser *rptParser; + } rptParsers[MAX_REPORT_PARSERS]; + + // HID class specific descriptor type and length info obtained from HID descriptor + HID_CLASS_DESCRIPTOR_LEN_AND_TYPE descrInfo[HID_MAX_HID_CLASS_DESCRIPTORS]; + + // Returns HID class specific descriptor length by its type and order number + uint16_t GetHidClassDescrLen(uint8_t type, uint8_t num); + + struct HIDInterface { + struct { + uint8_t bmInterface : 3; + uint8_t bmAltSet : 3; + uint8_t bmProtocol : 2; + }; + uint8_t epIndex[maxEpPerInterface]; + }; + + uint8_t bConfNum; // configuration number + uint8_t bNumIface; // number of interfaces in the configuration + uint8_t bNumEP; // total number of EP in the configuration + uint32_t qNextPollTime; // next poll time + uint8_t pollInterval; + bool bPollEnable; // poll enable flag + + static const uint16_t constBuffLen = 64; // event buffer length + uint8_t prevBuf[constBuffLen]; // previous event buffer + + void Initialize(); + HIDInterface* FindInterface(uint8_t iface, uint8_t alt, uint8_t proto); + + void ZeroMemory(uint8_t len, uint8_t *buf); + bool BuffersIdentical(uint8_t len, uint8_t *buf1, uint8_t *buf2); + void SaveBuffer(uint8_t len, uint8_t *src, uint8_t *dest); + +protected: + EpInfo epInfo[totalEndpoints]; + HIDInterface hidInterfaces[maxHidInterfaces]; + + bool bHasReportId; + + uint16_t PID, VID; // PID and VID of connected device + + // HID implementation + virtual HIDReportParser* GetReportParser(uint32_t id); + + virtual uint32_t OnInitSuccessful() { + return 0; + }; + + virtual void ParseHIDData(HID * /* hid */, bool /* is_rpt_id */, uint8_t /* len */, uint8_t * /* buf */) { + return; + }; + +public: + HIDUniversal(USBHost *p); + + // HID implementation + virtual uint32_t SetReportParser(uint32_t id, HIDReportParser *prs); + + // USBDeviceConfig implementation + virtual uint8_t Init(uint8_t parent, uint8_t port, bool lowspeed); + virtual uint32_t Release(); + virtual uint32_t Poll(); + + virtual uint32_t GetAddress() { + return bAddress; + }; + + virtual uint32_t isReady() { + return bPollEnable; + }; + + // UsbConfigXtracter implementation + virtual void EndpointXtract(uint32_t conf, uint32_t iface, uint32_t alt, uint32_t proto, const USB_ENDPOINT_DESCRIPTOR *ep); +}; + +#endif // __HIDUNIVERSAL_H__ diff --git a/libraries/USBHost/src/hidusagestr.h b/libraries/USBHost/src/hidusagestr.h new file mode 100644 index 0000000..71e5378 --- /dev/null +++ b/libraries/USBHost/src/hidusagestr.h @@ -0,0 +1,977 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com +*/ +#if !defined( __HIDUSAGESTR_H__) +#define __HIDUSAGESTR_H__ + +#include "Usb.h" + +const char pstrSpace [] PROGMEM = " "; +const char pstrCRLF [] PROGMEM = "\r\n"; +const char pstrSingleTab [] PROGMEM = "\t"; +const char pstrDoubleTab [] PROGMEM = "\t\t"; +const char pstrTripleTab [] PROGMEM = "\t\t\t"; + +// Usage Page String Titles +const char pstrUsagePageUndefined [] PROGMEM = "Undef"; +const char pstrUsagePageGenericDesktopControls [] PROGMEM = "Gen Desktop Ctrls"; +const char pstrUsagePageSimulationControls [] PROGMEM = "Simu Ctrls"; +const char pstrUsagePageVRControls [] PROGMEM = "VR Ctrls"; +const char pstrUsagePageSportControls [] PROGMEM = "Sport Ctrls"; +const char pstrUsagePageGameControls [] PROGMEM = "Game Ctrls"; +const char pstrUsagePageGenericDeviceControls [] PROGMEM = "Gen Dev Ctrls"; +const char pstrUsagePageKeyboardKeypad [] PROGMEM = "Kbrd/Keypad"; +const char pstrUsagePageLEDs [] PROGMEM = "LEDs"; +const char pstrUsagePageButton [] PROGMEM = "Button"; +const char pstrUsagePageOrdinal [] PROGMEM = "Ordinal"; +const char pstrUsagePageTelephone [] PROGMEM = "Tel"; +const char pstrUsagePageConsumer [] PROGMEM = "Consumer"; +const char pstrUsagePageDigitizer [] PROGMEM = "Digitizer"; +const char pstrUsagePagePID [] PROGMEM = "PID"; +const char pstrUsagePageUnicode [] PROGMEM = "Unicode"; +const char pstrUsagePageAlphaNumericDisplay [] PROGMEM = "Alpha Num Disp"; +const char pstrUsagePageMedicalInstruments [] PROGMEM = "Medical Instr"; +const char pstrUsagePageMonitor [] PROGMEM = "Monitor"; +const char pstrUsagePagePower [] PROGMEM = "Power"; +const char pstrUsagePageBarCodeScanner [] PROGMEM = "Bar Code Scan"; +const char pstrUsagePageScale [] PROGMEM = "Scale"; +const char pstrUsagePageMSRDevices [] PROGMEM = "Magn Stripe Read Dev"; +const char pstrUsagePagePointOfSale [] PROGMEM = "POS"; +const char pstrUsagePageCameraControl [] PROGMEM = "Cam Ctrl"; +const char pstrUsagePageArcade [] PROGMEM = "Arcade"; +const char pstrUsagePageReserved [] PROGMEM = "Reserved"; +const char pstrUsagePageVendorDefined [] PROGMEM = "Vendor Def"; + +// Generic Desktop Controls Page +const char pstrUsagePointer [] PROGMEM = "Pointer"; +const char pstrUsageMouse [] PROGMEM = "Mouse"; +const char pstrUsageJoystick [] PROGMEM = "Joystick"; +const char pstrUsageGamePad [] PROGMEM = "Game Pad"; +const char pstrUsageKeyboard [] PROGMEM = "Kbrd"; +const char pstrUsageKeypad [] PROGMEM = "Keypad"; +const char pstrUsageMultiAxisController [] PROGMEM = "Multi-axis Ctrl"; +const char pstrUsageTabletPCSystemControls [] PROGMEM = "Tablet PC Sys Ctrls"; +const char pstrUsageX [] PROGMEM = "X"; +const char pstrUsageY [] PROGMEM = "Y"; +const char pstrUsageZ [] PROGMEM = "Z"; +const char pstrUsageRx [] PROGMEM = "Rx"; +const char pstrUsageRy [] PROGMEM = "Ry"; +const char pstrUsageRz [] PROGMEM = "Rz"; +const char pstrUsageSlider [] PROGMEM = "Slider"; +const char pstrUsageDial [] PROGMEM = "Dial"; +const char pstrUsageWheel [] PROGMEM = "Wheel"; +const char pstrUsageHatSwitch [] PROGMEM = "Hat Switch"; +const char pstrUsageCountedBuffer [] PROGMEM = "Counted Buf"; +const char pstrUsageByteCount [] PROGMEM = "Byte Count"; +const char pstrUsageMotionWakeup [] PROGMEM = "Motion Wakeup"; +const char pstrUsageStart [] PROGMEM = "Start"; +const char pstrUsageSelect [] PROGMEM = "Sel"; +const char pstrUsageVx [] PROGMEM = "Vx"; +const char pstrUsageVy [] PROGMEM = "Vy"; +const char pstrUsageVz [] PROGMEM = "Vz"; +const char pstrUsageVbrx [] PROGMEM = "Vbrx"; +const char pstrUsageVbry [] PROGMEM = "Vbry"; +const char pstrUsageVbrz [] PROGMEM = "Vbrz"; +const char pstrUsageVno [] PROGMEM = "Vno"; +const char pstrUsageFeatureNotification [] PROGMEM = "Feature Notif"; +const char pstrUsageResolutionMultiplier [] PROGMEM = "Res Mult"; +const char pstrUsageSystemControl [] PROGMEM = "Sys Ctrl"; +const char pstrUsageSystemPowerDown [] PROGMEM = "Sys Pwr Down"; +const char pstrUsageSystemSleep [] PROGMEM = "Sys Sleep"; +const char pstrUsageSystemWakeup [] PROGMEM = "Sys Wakeup"; +const char pstrUsageSystemContextMenu [] PROGMEM = "Sys Context Menu"; +const char pstrUsageSystemMainMenu [] PROGMEM = "Sys Main Menu"; +const char pstrUsageSystemAppMenu [] PROGMEM = "Sys App Menu"; +const char pstrUsageSystemMenuHelp [] PROGMEM = "Sys Menu Help"; +const char pstrUsageSystemMenuExit [] PROGMEM = "Sys Menu Exit"; +const char pstrUsageSystemMenuSelect [] PROGMEM = "Sys Menu Select"; +const char pstrUsageSystemMenuRight [] PROGMEM = "Sys Menu Right"; +const char pstrUsageSystemMenuLeft [] PROGMEM = "Sys Menu Left"; +const char pstrUsageSystemMenuUp [] PROGMEM = "Sys Menu Up"; +const char pstrUsageSystemMenuDown [] PROGMEM = "Sys Menu Down"; +const char pstrUsageSystemColdRestart [] PROGMEM = "Sys Cold Restart"; +const char pstrUsageSystemWarmRestart [] PROGMEM = "Sys Warm Restart"; +const char pstrUsageDPadUp [] PROGMEM = "D-pad Up"; +const char pstrUsageDPadDown [] PROGMEM = "D-pad Down"; +const char pstrUsageDPadRight [] PROGMEM = "D-pad Right"; +const char pstrUsageDPadLeft [] PROGMEM = "D-pad Left"; +const char pstrUsageSystemDock [] PROGMEM = "Sys Dock"; +const char pstrUsageSystemUndock [] PROGMEM = "Sys Undock"; +const char pstrUsageSystemSetup [] PROGMEM = "Sys Setup"; +const char pstrUsageSystemBreak [] PROGMEM = "Sys Break"; +const char pstrUsageSystemDebuggerBreak [] PROGMEM = "Sys Dbg Brk"; +const char pstrUsageApplicationBreak [] PROGMEM = "App Break"; +const char pstrUsageApplicationDebuggerBreak [] PROGMEM = "App Dbg Brk"; +const char pstrUsageSystemSpeakerMute [] PROGMEM = "Sys Spk Mute"; +const char pstrUsageSystemHibernate [] PROGMEM = "Sys Hiber"; +const char pstrUsageSystemDisplayInvert [] PROGMEM = "Sys Disp Inv"; +const char pstrUsageSystemDisplayInternal [] PROGMEM = "Sys Disp Int"; +const char pstrUsageSystemDisplayExternal [] PROGMEM = "Sys Disp Ext"; +const char pstrUsageSystemDisplayBoth [] PROGMEM = "Sys Disp Both"; +const char pstrUsageSystemDisplayDual [] PROGMEM = "Sys Disp Dual"; +const char pstrUsageSystemDisplayToggleIntExt [] PROGMEM = "Sys Disp Tgl Int/Ext"; +const char pstrUsageSystemDisplaySwapPriSec [] PROGMEM = "Sys Disp Swap Pri/Sec"; +const char pstrUsageSystemDisplayLCDAutoscale [] PROGMEM = "Sys Disp LCD Autoscale"; + +// Simulation Controls Page +const char pstrUsageFlightSimulationDevice [] PROGMEM = "Flight Simu Dev"; +const char pstrUsageAutomobileSimulationDevice [] PROGMEM = "Auto Simu Dev"; +const char pstrUsageTankSimulationDevice [] PROGMEM = "Tank Simu Dev"; +const char pstrUsageSpaceshipSimulationDevice [] PROGMEM = "Space Simu Dev"; +const char pstrUsageSubmarineSimulationDevice [] PROGMEM = "Subm Simu Dev"; +const char pstrUsageSailingSimulationDevice [] PROGMEM = "Sail Simu Dev"; +const char pstrUsageMotocicleSimulationDevice [] PROGMEM = "Moto Simu Dev"; +const char pstrUsageSportsSimulationDevice [] PROGMEM = "Sport Simu Dev"; +const char pstrUsageAirplaneSimulationDevice [] PROGMEM = "Airp Simu Dev"; +const char pstrUsageHelicopterSimulationDevice [] PROGMEM = "Heli Simu Dev"; +const char pstrUsageMagicCarpetSimulationDevice [] PROGMEM = "Magic Carpet Simu Dev"; +const char pstrUsageBicycleSimulationDevice [] PROGMEM = "Bike Simu Dev"; +const char pstrUsageFlightControlStick [] PROGMEM = "Flight Ctrl Stick"; +const char pstrUsageFlightStick [] PROGMEM = "Flight Stick"; +const char pstrUsageCyclicControl [] PROGMEM = "Cyclic Ctrl"; +const char pstrUsageCyclicTrim [] PROGMEM = "Cyclic Trim"; +const char pstrUsageFlightYoke [] PROGMEM = "Flight Yoke"; +const char pstrUsageTrackControl [] PROGMEM = "Track Ctrl"; +const char pstrUsageAileron [] PROGMEM = "Aileron"; +const char pstrUsageAileronTrim [] PROGMEM = "Aileron Trim"; +const char pstrUsageAntiTorqueControl [] PROGMEM = "Anti-Torque Ctrl"; +const char pstrUsageAutopilotEnable [] PROGMEM = "Autopilot Enable"; +const char pstrUsageChaffRelease [] PROGMEM = "Chaff Release"; +const char pstrUsageCollectiveControl [] PROGMEM = "Collective Ctrl"; +const char pstrUsageDiveBrake [] PROGMEM = "Dive Brake"; +const char pstrUsageElectronicCountermeasures [] PROGMEM = "El Countermeasures"; +const char pstrUsageElevator [] PROGMEM = "Elevator"; +const char pstrUsageElevatorTrim [] PROGMEM = "Elevator Trim"; +const char pstrUsageRudder [] PROGMEM = "Rudder"; +const char pstrUsageThrottle [] PROGMEM = "Throttle"; +const char pstrUsageFlightCommunications [] PROGMEM = "Flight Comm"; +const char pstrUsageFlareRelease [] PROGMEM = "Flare Release"; +const char pstrUsageLandingGear [] PROGMEM = "Landing Gear"; +const char pstrUsageToeBrake [] PROGMEM = "Toe Brake"; +const char pstrUsageTrigger [] PROGMEM = "Trigger"; +const char pstrUsageWeaponsArm [] PROGMEM = "Weapons Arm"; +const char pstrUsageWeaponsSelect [] PROGMEM = "Weapons Sel"; +const char pstrUsageWingFlaps [] PROGMEM = "Wing Flaps"; +const char pstrUsageAccelerator [] PROGMEM = "Accel"; +const char pstrUsageBrake [] PROGMEM = "Brake"; +const char pstrUsageClutch [] PROGMEM = "Clutch"; +const char pstrUsageShifter [] PROGMEM = "Shifter"; +const char pstrUsageSteering [] PROGMEM = "Steering"; +const char pstrUsageTurretDirection [] PROGMEM = "Turret Dir"; +const char pstrUsageBarrelElevation [] PROGMEM = "Barrel Ele"; +const char pstrUsageDivePlane [] PROGMEM = "Dive Plane"; +const char pstrUsageBallast [] PROGMEM = "Ballast"; +const char pstrUsageBicycleCrank [] PROGMEM = "Bicycle Crank"; +const char pstrUsageHandleBars [] PROGMEM = "Handle Bars"; +const char pstrUsageFrontBrake [] PROGMEM = "Front Brake"; +const char pstrUsageRearBrake [] PROGMEM = "Rear Brake"; + +// VR Controls Page +const char pstrUsageBelt [] PROGMEM = "Belt"; +const char pstrUsageBodySuit [] PROGMEM = "Body Suit"; +const char pstrUsageFlexor [] PROGMEM = "Flexor"; +const char pstrUsageGlove [] PROGMEM = "Glove"; +const char pstrUsageHeadTracker [] PROGMEM = "Head Track"; +const char pstrUsageHeadMountedDisplay [] PROGMEM = "Head Disp"; +const char pstrUsageHandTracker [] PROGMEM = "Hand Track"; +const char pstrUsageOculometer [] PROGMEM = "Oculometer"; +const char pstrUsageVest [] PROGMEM = "Vest"; +const char pstrUsageAnimatronicDevice [] PROGMEM = "Animat Dev"; +const char pstrUsageStereoEnable [] PROGMEM = "Stereo Enbl"; +const char pstrUsageDisplayEnable [] PROGMEM = "Display Enbl"; + +// Sport Controls Page +const char pstrUsageBaseballBat [] PROGMEM = "Baseball Bat"; +const char pstrUsageGolfClub [] PROGMEM = "Golf Club"; +const char pstrUsageRowingMachine [] PROGMEM = "Rowing Mach"; +const char pstrUsageTreadmill [] PROGMEM = "Treadmill"; +const char pstrUsageOar [] PROGMEM = "Oar"; +const char pstrUsageSlope [] PROGMEM = "Slope"; +const char pstrUsageRate [] PROGMEM = "Rate"; +const char pstrUsageStickSpeed [] PROGMEM = "Stick Speed"; +const char pstrUsageStickFaceAngle [] PROGMEM = "Stick Face Ang"; +const char pstrUsageStickHeelToe [] PROGMEM = "Stick Heel/Toe"; +const char pstrUsageStickFollowThough [] PROGMEM = "Stick Flw Thru"; +const char pstrUsageStickTempo [] PROGMEM = "Stick Tempo"; +const char pstrUsageStickType [] PROGMEM = "Stick Type"; +const char pstrUsageStickHeight [] PROGMEM = "Stick Hght"; +const char pstrUsagePutter [] PROGMEM = "Putter"; +const char pstrUsage1Iron [] PROGMEM = "1 Iron"; +const char pstrUsage2Iron [] PROGMEM = "2 Iron"; +const char pstrUsage3Iron [] PROGMEM = "3 Iron"; +const char pstrUsage4Iron [] PROGMEM = "4 Iron"; +const char pstrUsage5Iron [] PROGMEM = "5 Iron"; +const char pstrUsage6Iron [] PROGMEM = "6 Iron"; +const char pstrUsage7Iron [] PROGMEM = "7 Iron"; +const char pstrUsage8Iron [] PROGMEM = "8 Iron"; +const char pstrUsage9Iron [] PROGMEM = "9 Iron"; +const char pstrUsage10Iron [] PROGMEM = "10 Iron"; +const char pstrUsage11Iron [] PROGMEM = "11 Iron"; +const char pstrUsageSandWedge [] PROGMEM = "Sand Wedge"; +const char pstrUsageLoftWedge [] PROGMEM = "Loft Wedge"; +const char pstrUsagePowerWedge [] PROGMEM = "Pwr Wedge"; +const char pstrUsage1Wood [] PROGMEM = "1 Wood"; +const char pstrUsage3Wood [] PROGMEM = "3 Wood"; +const char pstrUsage5Wood [] PROGMEM = "5 Wood"; +const char pstrUsage7Wood [] PROGMEM = "7 Wood"; +const char pstrUsage9Wood [] PROGMEM = "9 Wood"; + +// Game Controls Page +const char pstrUsage3DGameController [] PROGMEM = "3D Game Ctrl"; +const char pstrUsagePinballDevice [] PROGMEM = "Pinball Dev"; +const char pstrUsageGunDevice [] PROGMEM = "Gun Dev"; +const char pstrUsagePointOfView [] PROGMEM = "POV"; +const char pstrUsageTurnRightLeft [] PROGMEM = "Turn Right Left"; +const char pstrUsagePitchForwardBackward [] PROGMEM = "Pitch Fwd/Back"; +const char pstrUsageRollRightLeft [] PROGMEM = "Roll Right/Left"; +const char pstrUsageMoveRightLeft [] PROGMEM = "Move Right/Left"; +const char pstrUsageMoveForwardBackward [] PROGMEM = "Move Fwd/Back"; +const char pstrUsageMoveUpDown [] PROGMEM = "Move Up/Down"; +const char pstrUsageLeanRightLeft [] PROGMEM = "Lean Right/Left"; +const char pstrUsageLeanForwardBackward [] PROGMEM = "Lean Fwd/Back"; +const char pstrUsageHeightOfPOV [] PROGMEM = "Height of POV"; +const char pstrUsageFlipper [] PROGMEM = "Flipper"; +const char pstrUsageSecondaryFlipper [] PROGMEM = "Second Flipper"; +const char pstrUsageBump [] PROGMEM = "Bump"; +const char pstrUsageNewGame [] PROGMEM = "New Game"; +const char pstrUsageShootBall [] PROGMEM = "Shoot Ball"; +const char pstrUsagePlayer [] PROGMEM = "Player"; +const char pstrUsageGunBolt [] PROGMEM = "Gun Bolt"; +const char pstrUsageGunClip [] PROGMEM = "Gun Clip"; +const char pstrUsageGunSelector [] PROGMEM = "Gun Sel"; +const char pstrUsageGunSingleShot [] PROGMEM = "Gun Sngl Shot"; +const char pstrUsageGunBurst [] PROGMEM = "Gun Burst"; +const char pstrUsageGunAutomatic [] PROGMEM = "Gun Auto"; +const char pstrUsageGunSafety [] PROGMEM = "Gun Safety"; +const char pstrUsageGamepadFireJump [] PROGMEM = "Gamepad Fire/Jump"; +const char pstrUsageGamepadTrigger [] PROGMEM = "Gamepad Trig"; + +// Generic Device Controls Page +const char pstrUsageBatteryStrength [] PROGMEM = "Bat Strength"; +const char pstrUsageWirelessChannel [] PROGMEM = "Wireless Ch"; +const char pstrUsageWirelessID [] PROGMEM = "Wireless ID"; +const char pstrUsageDiscoverWirelessControl [] PROGMEM = "Discover Wireless Ctrl"; +const char pstrUsageSecurityCodeCharEntered [] PROGMEM = "Sec Code Char Entrd"; +const char pstrUsageSecurityCodeCharErased [] PROGMEM = "Sec Code Char Erased"; +const char pstrUsageSecurityCodeCleared [] PROGMEM = "Sec Code Cleared"; + +// LED Page +const char pstrUsageNumLock [] PROGMEM = "Num Lock"; +const char pstrUsageCapsLock [] PROGMEM = "Caps Lock"; +const char pstrUsageScrollLock [] PROGMEM = "Scroll Lock"; +const char pstrUsageCompose [] PROGMEM = "Compose"; +const char pstrUsageKana [] PROGMEM = "Kana"; +const char pstrUsagePower [] PROGMEM = "Pwr"; +const char pstrUsageShift [] PROGMEM = "Shift"; +const char pstrUsageDoNotDisturb [] PROGMEM = "DND"; +const char pstrUsageMute [] PROGMEM = "Mute"; +const char pstrUsageToneEnable [] PROGMEM = "Tone Enbl"; +const char pstrUsageHighCutFilter [] PROGMEM = "High Cut Fltr"; +const char pstrUsageLowCutFilter [] PROGMEM = "Low Cut Fltr"; +const char pstrUsageEqualizerEnable [] PROGMEM = "Eq Enbl"; +const char pstrUsageSoundFieldOn [] PROGMEM = "Sound Field On"; +const char pstrUsageSurroundOn [] PROGMEM = "Surround On"; +const char pstrUsageRepeat [] PROGMEM = "Repeat"; +const char pstrUsageStereo [] PROGMEM = "Stereo"; +const char pstrUsageSamplingRateDetect [] PROGMEM = "Smpl Rate Detect"; +const char pstrUsageSpinning [] PROGMEM = "Spinning"; +const char pstrUsageCAV [] PROGMEM = "CAV"; +const char pstrUsageCLV [] PROGMEM = "CLV"; +const char pstrUsageRecordingFormatDetect [] PROGMEM = "Rec Format Detect"; +const char pstrUsageOffHook [] PROGMEM = "Off Hook"; +const char pstrUsageRing [] PROGMEM = "Ring"; +const char pstrUsageMessageWaiting [] PROGMEM = "Msg Wait"; +const char pstrUsageDataMode [] PROGMEM = "Data Mode"; +const char pstrUsageBatteryOperation [] PROGMEM = "Bat Op"; +const char pstrUsageBatteryOK [] PROGMEM = "Bat OK"; +const char pstrUsageBatteryLow [] PROGMEM = "Bat Low"; +const char pstrUsageSpeaker [] PROGMEM = "Speaker"; +const char pstrUsageHeadSet [] PROGMEM = "Head Set"; +const char pstrUsageHold [] PROGMEM = "Hold"; +const char pstrUsageMicrophone [] PROGMEM = "Mic"; +const char pstrUsageCoverage [] PROGMEM = "Coverage"; +const char pstrUsageNightMode [] PROGMEM = "Night Mode"; +const char pstrUsageSendCalls [] PROGMEM = "Send Calls"; +const char pstrUsageCallPickup [] PROGMEM = "Call Pickup"; +const char pstrUsageConference [] PROGMEM = "Conf"; +const char pstrUsageStandBy [] PROGMEM = "Stand-by"; +const char pstrUsageCameraOn [] PROGMEM = "Cam On"; +const char pstrUsageCameraOff [] PROGMEM = "Cam Off"; +const char pstrUsageOnLine [] PROGMEM = "On-Line"; +const char pstrUsageOffLine [] PROGMEM = "Off-Line"; +const char pstrUsageBusy [] PROGMEM = "Busy"; +const char pstrUsageReady [] PROGMEM = "Ready"; +const char pstrUsagePaperOut [] PROGMEM = "Paper Out"; +const char pstrUsagePaperJam [] PROGMEM = "Paper Jam"; +const char pstrUsageRemote [] PROGMEM = "Remote"; +const char pstrUsageForward [] PROGMEM = "Fwd"; +const char pstrUsageReverse [] PROGMEM = "Rev"; +const char pstrUsageStop [] PROGMEM = "Stop"; +const char pstrUsageRewind [] PROGMEM = "Rewind"; +const char pstrUsageFastForward [] PROGMEM = "Fast Fwd"; +const char pstrUsagePlay [] PROGMEM = "Play"; +const char pstrUsagePause [] PROGMEM = "Pause"; +const char pstrUsageRecord [] PROGMEM = "Rec"; +const char pstrUsageError [] PROGMEM = "Error"; +const char pstrUsageSelectedIndicator [] PROGMEM = "Usage Sel Ind"; +const char pstrUsageInUseIndicator [] PROGMEM = "Usage In Use Ind"; +const char pstrUsageMultiModeIndicator [] PROGMEM = "Usage Multi Mode Ind"; +const char pstrUsageIndicatorOn [] PROGMEM = "Ind On"; +const char pstrUsageIndicatorFlash [] PROGMEM = "Ind Flash"; +const char pstrUsageIndicatorSlowBlink [] PROGMEM = "Ind Slow Blk"; +const char pstrUsageIndicatorFastBlink [] PROGMEM = "Ind Fast Blk"; +const char pstrUsageIndicatorOff [] PROGMEM = "Ind Off"; +const char pstrUsageFlashOnTime [] PROGMEM = "Flash On Time"; +const char pstrUsageSlowBlinkOnTime [] PROGMEM = "Slow Blk On Time"; +const char pstrUsageSlowBlinkOffTime [] PROGMEM = "Slow Blk Off Time"; +const char pstrUsageFastBlinkOnTime [] PROGMEM = "Fast Blk On Time"; +const char pstrUsageFastBlinkOffTime [] PROGMEM = "Fast Blk Off Time"; +const char pstrUsageIndicatorColor [] PROGMEM = "Usage Ind Color"; +const char pstrUsageIndicatorRed [] PROGMEM = "Ind Red"; +const char pstrUsageIndicatorGreen [] PROGMEM = "Ind Green"; +const char pstrUsageIndicatorAmber [] PROGMEM = "Ind Amber"; +const char pstrUsageGenericIndicator [] PROGMEM = "Gen Ind"; +const char pstrUsageSystemSuspend [] PROGMEM = "Sys Suspend"; +const char pstrUsageExternalPowerConnected [] PROGMEM = "Ext Pwr Conn"; + +// Telephony Usage Page +const char pstrUsagePhone [] PROGMEM = "Phone"; +const char pstrUsageAnsweringMachine [] PROGMEM = "Answ Mach"; +const char pstrUsageMessageControls [] PROGMEM = "Msg Ctrls"; +const char pstrUsageHandset [] PROGMEM = "Handset"; +const char pstrUsageHeadset [] PROGMEM = "Headset"; +const char pstrUsageTelephonyKeyPad [] PROGMEM = "Tel Key Pad"; +const char pstrUsageProgrammableButton [] PROGMEM = "Prog Button"; +const char pstrUsageHookSwitch [] PROGMEM = "Hook Sw"; +const char pstrUsageFlash [] PROGMEM = "Flash"; +const char pstrUsageFeature [] PROGMEM = "Feature"; +//const char pstrUsageHold [] PROGMEM = "Hold"; +const char pstrUsageRedial [] PROGMEM = "Redial"; +const char pstrUsageTransfer [] PROGMEM = "Transfer"; +const char pstrUsageDrop [] PROGMEM = "Drop"; +const char pstrUsagePark [] PROGMEM = "Park"; +const char pstrUsageForwardCalls [] PROGMEM = "Fwd Calls"; +const char pstrUsageAlternateFunction [] PROGMEM = "Alt Func"; +const char pstrUsageLine [] PROGMEM = "Line"; +const char pstrUsageSpeakerPhone [] PROGMEM = "Spk Phone"; +//const char pstrUsageConference [] PROGMEM = "Conference"; +const char pstrUsageRingEnable [] PROGMEM = "Ring Enbl"; +const char pstrUsageRingSelect [] PROGMEM = "Ring Sel"; +const char pstrUsagePhoneMute [] PROGMEM = "Phone Mute"; +const char pstrUsageCallerID [] PROGMEM = "Caller ID"; +const char pstrUsageSend [] PROGMEM = "Send"; +const char pstrUsageSpeedDial [] PROGMEM = "Speed Dial"; +const char pstrUsageStoreNumber [] PROGMEM = "Store Num"; +const char pstrUsageRecallNumber [] PROGMEM = "Recall Num"; +const char pstrUsagePhoneDirectory [] PROGMEM = "Phone Dir"; +const char pstrUsageVoiceMail [] PROGMEM = "Voice Mail"; +const char pstrUsageScreenCalls [] PROGMEM = "Screen Calls"; +//const char pstrUsageDoNotDisturb [] PROGMEM = "Do Not Disturb"; +const char pstrUsageMessage [] PROGMEM = "Msg"; +const char pstrUsageAnswerOnOff [] PROGMEM = "Answer On/Off"; +const char pstrUsageInsideDialTone [] PROGMEM = "Inside Dial Tone"; +const char pstrUsageOutsideDialTone [] PROGMEM = "Outside Dial Tone"; +const char pstrUsageInsideRingTone [] PROGMEM = "Inside Ring Tone"; +const char pstrUsageOutsideRingTone [] PROGMEM = "Outside Ring Tone"; +const char pstrUsagePriorityRingTone [] PROGMEM = "Prior Ring Tone"; +const char pstrUsageInsideRingback [] PROGMEM = "Inside Ringback"; +const char pstrUsagePriorityRingback [] PROGMEM = "Priority Ringback"; +const char pstrUsageLineBusyTone [] PROGMEM = "Ln Busy Tone"; +const char pstrUsageReorderTone [] PROGMEM = "Reorder Tone"; +const char pstrUsageCallWaitingTone [] PROGMEM = "Call Wait Tone"; +const char pstrUsageConfirmationTone1 [] PROGMEM = "Cnfrm Tone1"; +const char pstrUsageConfirmationTone2 [] PROGMEM = "Cnfrm Tone2"; +const char pstrUsageTonesOff [] PROGMEM = "Tones Off"; +const char pstrUsageOutsideRingback [] PROGMEM = "Outside Ringback"; +const char pstrUsageRinger [] PROGMEM = "Ringer"; +const char pstrUsagePhoneKey0 [] PROGMEM = "0"; +const char pstrUsagePhoneKey1 [] PROGMEM = "1"; +const char pstrUsagePhoneKey2 [] PROGMEM = "2"; +const char pstrUsagePhoneKey3 [] PROGMEM = "3"; +const char pstrUsagePhoneKey4 [] PROGMEM = "4"; +const char pstrUsagePhoneKey5 [] PROGMEM = "5"; +const char pstrUsagePhoneKey6 [] PROGMEM = "6"; +const char pstrUsagePhoneKey7 [] PROGMEM = "7"; +const char pstrUsagePhoneKey8 [] PROGMEM = "8"; +const char pstrUsagePhoneKey9 [] PROGMEM = "9"; +const char pstrUsagePhoneKeyStar [] PROGMEM = "*"; +const char pstrUsagePhoneKeyPound [] PROGMEM = "#"; +const char pstrUsagePhoneKeyA [] PROGMEM = "A"; +const char pstrUsagePhoneKeyB [] PROGMEM = "B"; +const char pstrUsagePhoneKeyC [] PROGMEM = "C"; +const char pstrUsagePhoneKeyD [] PROGMEM = "D"; + +// Consumer Usage Page +const char pstrUsageConsumerControl [] PROGMEM = "Consumer Ctrl"; +const char pstrUsageNumericKeyPad [] PROGMEM = "Num Key Pad"; +//const char pstrUsageProgrammableButton [] PROGMEM = "Prog Btn"; +//const char pstrUsageMicrophone [] PROGMEM = "Mic"; +const char pstrUsageHeadphone [] PROGMEM = "Headphone"; +const char pstrUsageGraphicEqualizer [] PROGMEM = "Graph Eq"; +const char pstrUsagePlus10 [] PROGMEM = "+10"; +const char pstrUsagePlus100 [] PROGMEM = "+100"; +const char pstrUsageAMPM [] PROGMEM = "AM/PM"; +//const char pstrUsagePower [] PROGMEM = "Pwr"; +const char pstrUsageReset [] PROGMEM = "Reset"; +const char pstrUsageSleep [] PROGMEM = "Sleep"; +const char pstrUsageSleepAfter [] PROGMEM = "Sleep After"; +const char pstrUsageSleepMode [] PROGMEM = "Sleep Mode"; +const char pstrUsageIllumination [] PROGMEM = "Illumin"; +const char pstrUsageFunctionButtons [] PROGMEM = "Func Btns"; +const char pstrUsageMenu [] PROGMEM = "Menu"; +const char pstrUsageMenuPick [] PROGMEM = "Menu Pick"; +const char pstrUsageMenuUp [] PROGMEM = "Menu Up"; +const char pstrUsageMenuDown [] PROGMEM = "Menu Down"; +const char pstrUsageMenuLeft [] PROGMEM = "Menu Left"; +const char pstrUsageMenuRight [] PROGMEM = "Menu Right"; +const char pstrUsageMenuEscape [] PROGMEM = "Menu Esc"; +const char pstrUsageMenuValueIncrease [] PROGMEM = "Menu Val Inc"; +const char pstrUsageMenuValueDecrease [] PROGMEM = "Menu Val Dec"; +const char pstrUsageDataOnScreen [] PROGMEM = "Data On Scr"; +const char pstrUsageClosedCaption [] PROGMEM = "Closed Cptn"; +const char pstrUsageClosedCaptionSelect [] PROGMEM = "Closed Cptn Sel"; +const char pstrUsageVCRTV [] PROGMEM = "VCR/TV"; +const char pstrUsageBroadcastMode [] PROGMEM = "Brdcast Mode"; +const char pstrUsageSnapshot [] PROGMEM = "Snapshot"; +const char pstrUsageStill [] PROGMEM = "Still"; +const char pstrUsageSelection [] PROGMEM = "Sel"; +const char pstrUsageAssignSelection [] PROGMEM = "Assign Sel"; +const char pstrUsageModeStep [] PROGMEM = "Mode Step"; +const char pstrUsageRecallLast [] PROGMEM = "Recall Last"; +const char pstrUsageEnterChannel [] PROGMEM = "Entr Channel"; +const char pstrUsageOrderMovie [] PROGMEM = "Ord Movie"; +const char pstrUsageChannel [] PROGMEM = "Channel"; +const char pstrUsageMediaSelection [] PROGMEM = "Med Sel"; +const char pstrUsageMediaSelectComputer [] PROGMEM = "Med Sel Comp"; +const char pstrUsageMediaSelectTV [] PROGMEM = "Med Sel TV"; +const char pstrUsageMediaSelectWWW [] PROGMEM = "Med Sel WWW"; +const char pstrUsageMediaSelectDVD [] PROGMEM = "Med Sel DVD"; +const char pstrUsageMediaSelectTelephone [] PROGMEM = "Med Sel Tel"; +const char pstrUsageMediaSelectProgramGuide [] PROGMEM = "Med Sel PG"; +const char pstrUsageMediaSelectVideoPhone [] PROGMEM = "Med Sel Vid"; +const char pstrUsageMediaSelectGames [] PROGMEM = "Med Sel Games"; +const char pstrUsageMediaSelectMessages [] PROGMEM = "Med Sel Msg"; +const char pstrUsageMediaSelectCD [] PROGMEM = "Med Sel CD"; +const char pstrUsageMediaSelectVCR [] PROGMEM = "Med Sel VCR"; +const char pstrUsageMediaSelectTuner [] PROGMEM = "Med Sel Tuner"; +const char pstrUsageQuit [] PROGMEM = "Quit"; +const char pstrUsageHelp [] PROGMEM = "Help"; +const char pstrUsageMediaSelectTape [] PROGMEM = "Med Sel Tape"; +const char pstrUsageMediaSelectCable [] PROGMEM = "Med Sel Cbl"; +const char pstrUsageMediaSelectSatellite [] PROGMEM = "Med Sel Sat"; +const char pstrUsageMediaSelectSecurity [] PROGMEM = "Med Sel Secur"; +const char pstrUsageMediaSelectHome [] PROGMEM = "Med Sel Home"; +const char pstrUsageMediaSelectCall [] PROGMEM = "Med Sel Call"; +const char pstrUsageChannelIncrement [] PROGMEM = "Ch Inc"; +const char pstrUsageChannelDecrement [] PROGMEM = "Ch Dec"; +const char pstrUsageMediaSelectSAP [] PROGMEM = "Med Sel SAP"; +const char pstrUsageVCRPlus [] PROGMEM = "VCR+"; +const char pstrUsageOnce [] PROGMEM = "Once"; +const char pstrUsageDaily [] PROGMEM = "Daily"; +const char pstrUsageWeekly [] PROGMEM = "Weekly"; +const char pstrUsageMonthly [] PROGMEM = "Monthly"; +//const char pstrUsagePlay [] PROGMEM = "Play"; +//const char pstrUsagePause [] PROGMEM = "Pause"; +//const char pstrUsageRecord [] PROGMEM = "Rec"; +//const char pstrUsageFastForward [] PROGMEM = "FF"; +//const char pstrUsageRewind [] PROGMEM = "Rewind"; +const char pstrUsageScanNextTrack [] PROGMEM = "Next Track"; +const char pstrUsageScanPreviousTrack [] PROGMEM = "Prev Track"; +//const char pstrUsageStop [] PROGMEM = "Stop"; +const char pstrUsageEject [] PROGMEM = "Eject"; +const char pstrUsageRandomPlay [] PROGMEM = "Random"; +const char pstrUsageSelectDisk [] PROGMEM = "Sel Disk"; +const char pstrUsageEnterDisk [] PROGMEM = "Ent Disk"; +//const char pstrUsageRepeat [] PROGMEM = "Repeat"; +const char pstrUsageTracking [] PROGMEM = "Tracking"; +const char pstrUsageTrackNormal [] PROGMEM = "Trk Norm"; +const char pstrUsageSlowTracking [] PROGMEM = "Slow Trk"; +const char pstrUsageFrameForward [] PROGMEM = "Frm Fwd"; +const char pstrUsageFrameBackwards [] PROGMEM = "Frm Back"; +const char pstrUsageMark [] PROGMEM = "Mark"; +const char pstrUsageClearMark [] PROGMEM = "Clr Mark"; +const char pstrUsageRepeatFromMark [] PROGMEM = "Rpt Mark"; +const char pstrUsageReturnToMark [] PROGMEM = "Ret to Mark"; +const char pstrUsageSearchMarkForward [] PROGMEM = "Search Mark Fwd"; +const char pstrUsageSearchMarkBackwards [] PROGMEM = "Search Mark Back"; +const char pstrUsageCounterReset [] PROGMEM = "Counter Reset"; +const char pstrUsageShowCounter [] PROGMEM = "Show Counter"; +const char pstrUsageTrackingIncrement [] PROGMEM = "Track Inc"; +const char pstrUsageTrackingDecrement [] PROGMEM = "Track Dec"; +const char pstrUsageStopEject [] PROGMEM = "Stop/Eject"; +const char pstrUsagePlayPause [] PROGMEM = "Play/Pause"; +const char pstrUsagePlaySkip [] PROGMEM = "Play/Skip"; +const char pstrUsageVolume [] PROGMEM = "Vol"; +const char pstrUsageBalance [] PROGMEM = "Balance"; +//const char pstrUsageMute [] PROGMEM = "Mute"; +const char pstrUsageBass [] PROGMEM = "Bass"; +const char pstrUsageTreble [] PROGMEM = "Treble"; +const char pstrUsageBassBoost [] PROGMEM = "Bass Boost"; +const char pstrUsageSurroundMode [] PROGMEM = "Surround"; +const char pstrUsageLoudness [] PROGMEM = "Loud"; +const char pstrUsageMPX [] PROGMEM = "MPX"; +const char pstrUsageVolumeIncrement [] PROGMEM = "Vol Inc"; +const char pstrUsageVolumeDecrement [] PROGMEM = "Vol Dec"; +const char pstrUsageSpeedSelect [] PROGMEM = "Speed"; +const char pstrUsagePlaybackSpeed [] PROGMEM = "Play Speed"; +const char pstrUsageStandardPlay [] PROGMEM = "Std Play"; +const char pstrUsageLongPlay [] PROGMEM = "Long Play"; +const char pstrUsageExtendedPlay [] PROGMEM = "Ext Play"; +const char pstrUsageSlow [] PROGMEM = "Slow"; +const char pstrUsageFanEnable [] PROGMEM = "Fan Enbl"; +const char pstrUsageFanSpeed [] PROGMEM = "Fan Speed"; +const char pstrUsageLightEnable [] PROGMEM = "Light Enbl"; +const char pstrUsageLightIlluminationLevel [] PROGMEM = "Light Illum Lev"; +const char pstrUsageClimateControlEnable [] PROGMEM = "Climate Enbl"; +const char pstrUsageRoomTemperature [] PROGMEM = "Room Temp"; +const char pstrUsageSecurityEnable [] PROGMEM = "Secur Enbl"; +const char pstrUsageFireAlarm [] PROGMEM = "Fire Alm"; +const char pstrUsagePoliceAlarm [] PROGMEM = "Police Alm"; +const char pstrUsageProximity [] PROGMEM = "Prox"; +const char pstrUsageMotion [] PROGMEM = "Motion"; +const char pstrUsageDuresAlarm [] PROGMEM = "Dures Alm"; +const char pstrUsageHoldupAlarm [] PROGMEM = "Holdup Alm"; +const char pstrUsageMedicalAlarm [] PROGMEM = "Med Alm"; +const char pstrUsageBalanceRight [] PROGMEM = "Balance Right"; +const char pstrUsageBalanceLeft [] PROGMEM = "Balance Left"; +const char pstrUsageBassIncrement [] PROGMEM = "Bass Inc"; +const char pstrUsageBassDecrement [] PROGMEM = "Bass Dec"; +const char pstrUsageTrebleIncrement [] PROGMEM = "Treble Inc"; +const char pstrUsageTrebleDecrement [] PROGMEM = "Treble Dec"; +const char pstrUsageSpeakerSystem [] PROGMEM = "Spk Sys"; +const char pstrUsageChannelLeft [] PROGMEM = "Ch Left"; +const char pstrUsageChannelRight [] PROGMEM = "Ch Right"; +const char pstrUsageChannelCenter [] PROGMEM = "Ch Center"; +const char pstrUsageChannelFront [] PROGMEM = "Ch Front"; +const char pstrUsageChannelCenterFront [] PROGMEM = "Ch Cntr Front"; +const char pstrUsageChannelSide [] PROGMEM = "Ch Side"; +const char pstrUsageChannelSurround [] PROGMEM = "Ch Surround"; +const char pstrUsageChannelLowFreqEnhancement [] PROGMEM = "Ch Low Freq Enh"; +const char pstrUsageChannelTop [] PROGMEM = "Ch Top"; +const char pstrUsageChannelUnknown [] PROGMEM = "Ch Unk"; +const char pstrUsageSubChannel [] PROGMEM = "Sub-ch"; +const char pstrUsageSubChannelIncrement [] PROGMEM = "Sub-ch Inc"; +const char pstrUsageSubChannelDecrement [] PROGMEM = "Sub-ch Dec"; +const char pstrUsageAlternateAudioIncrement [] PROGMEM = "Alt Aud Inc"; +const char pstrUsageAlternateAudioDecrement [] PROGMEM = "Alt Aud Dec"; +const char pstrUsageApplicationLaunchButtons [] PROGMEM = "App Launch Btns"; +const char pstrUsageALLaunchButtonConfigTool [] PROGMEM = "AL Launch Conf Tl"; +const char pstrUsageALProgrammableButton [] PROGMEM = "AL Pgm Btn"; +const char pstrUsageALConsumerControlConfig [] PROGMEM = "AL Cons Ctrl Cfg"; +const char pstrUsageALWordProcessor [] PROGMEM = "AL Word Proc"; +const char pstrUsageALTextEditor [] PROGMEM = "AL Txt Edtr"; +const char pstrUsageALSpreadsheet [] PROGMEM = "AL Sprdsheet"; +const char pstrUsageALGraphicsEditor [] PROGMEM = "AL Graph Edtr"; +const char pstrUsageALPresentationApp [] PROGMEM = "AL Present App"; +const char pstrUsageALDatabaseApp [] PROGMEM = "AL DB App"; +const char pstrUsageALEmailReader [] PROGMEM = "AL E-mail Rdr"; +const char pstrUsageALNewsreader [] PROGMEM = "AL Newsrdr"; +const char pstrUsageALVoicemail [] PROGMEM = "AL Voicemail"; +const char pstrUsageALContactsAddressBook [] PROGMEM = "AL Addr Book"; +const char pstrUsageALCalendarSchedule [] PROGMEM = "AL Clndr/Schdlr"; +const char pstrUsageALTaskProjectManager [] PROGMEM = "AL Task/Prj Mgr"; +const char pstrUsageALLogJournalTimecard [] PROGMEM = "AL Log/Jrnl/Tmcrd"; +const char pstrUsageALCheckbookFinance [] PROGMEM = "AL Chckbook/Fin"; +const char pstrUsageALCalculator [] PROGMEM = "AL Calc"; +const char pstrUsageALAVCapturePlayback [] PROGMEM = "AL A/V Capt/Play"; +const char pstrUsageALLocalMachineBrowser [] PROGMEM = "AL Loc Mach Brow"; +const char pstrUsageALLANWANBrow [] PROGMEM = "AL LAN/WAN Brow"; +const char pstrUsageALInternetBrowser [] PROGMEM = "AL I-net Brow"; +const char pstrUsageALRemoteNetISPConnect [] PROGMEM = "AL Rem Net Con"; +const char pstrUsageALNetworkConference [] PROGMEM = "AL Net Conf"; +const char pstrUsageALNetworkChat [] PROGMEM = "AL Net Chat"; +const char pstrUsageALTelephonyDialer [] PROGMEM = "AL Tel/Dial"; +const char pstrUsageALLogon [] PROGMEM = "AL Logon"; +const char pstrUsageALLogoff [] PROGMEM = "AL Logoff"; +const char pstrUsageALLogonLogoff [] PROGMEM = "AL Logon/Logoff"; +const char pstrUsageALTermLockScrSav [] PROGMEM = "AL Term Lock/Scr Sav"; +const char pstrUsageALControlPannel [] PROGMEM = "AL Ctrl Pan"; +const char pstrUsageALCommandLineProcessorRun [] PROGMEM = "AL Cmd/Run"; +const char pstrUsageALProcessTaskManager [] PROGMEM = "AL Task Mgr"; +const char pstrUsageALSelectTaskApplication [] PROGMEM = "AL Sel App"; +const char pstrUsageALNextTaskApplication [] PROGMEM = "AL Next App"; +const char pstrUsageALPreviousTaskApplication [] PROGMEM = "AL Prev App"; +const char pstrUsageALPreemptiveHaltTaskApp [] PROGMEM = "AL Prmpt Halt App"; +const char pstrUsageALIntegratedHelpCenter [] PROGMEM = "AL Hlp Cntr"; +const char pstrUsageALDocuments [] PROGMEM = "AL Docs"; +const char pstrUsageALThesaurus [] PROGMEM = "AL Thsrs"; +const char pstrUsageALDictionary [] PROGMEM = "AL Dict"; +const char pstrUsageALDesktop [] PROGMEM = "AL Desktop"; +const char pstrUsageALSpellCheck [] PROGMEM = "AL Spell Chk"; +const char pstrUsageALGrammarCheck [] PROGMEM = "AL Gram Chk"; +const char pstrUsageALWirelessStatus [] PROGMEM = "AL Wireless Sts"; +const char pstrUsageALKeyboardLayout [] PROGMEM = "AL Kbd Layout"; +const char pstrUsageALVirusProtection [] PROGMEM = "AL Vir Protect"; +const char pstrUsageALEncryption [] PROGMEM = "AL Encrypt"; +const char pstrUsageALScreenSaver [] PROGMEM = "AL Scr Sav"; +const char pstrUsageALAlarms [] PROGMEM = "AL Alarms"; +const char pstrUsageALClock [] PROGMEM = "AL Clock"; +const char pstrUsageALFileBrowser [] PROGMEM = "AL File Brow"; +const char pstrUsageALPowerStatus [] PROGMEM = "AL Pwr Sts"; +const char pstrUsageALImageBrowser [] PROGMEM = "AL Img Brow"; +const char pstrUsageALAudioBrowser [] PROGMEM = "AL Aud Brow"; +const char pstrUsageALMovieBrowser [] PROGMEM = "AL Mov Brow"; +const char pstrUsageALDigitalRightsManager [] PROGMEM = "AL Dig Rights Mgr"; +const char pstrUsageALDigitalWallet [] PROGMEM = "AL Dig Wallet"; +const char pstrUsageALInstantMessaging [] PROGMEM = "AL Inst Msg"; +const char pstrUsageALOEMFeaturesBrowser [] PROGMEM = "AL OEM Tips Brow"; +const char pstrUsageALOEMHelp [] PROGMEM = "AL OEM Hlp"; +const char pstrUsageALOnlineCommunity [] PROGMEM = "AL Online Com"; +const char pstrUsageALEntertainmentContentBrow [] PROGMEM = "AL Ent Cont Brow"; +const char pstrUsageALOnlineShoppingBrowser [] PROGMEM = "AL Online Shop Brow"; +const char pstrUsageALSmartCardInfoHelp [] PROGMEM = "AL SmartCard Inf"; +const char pstrUsageALMarketMonitorFinBrowser [] PROGMEM = "AL Market Brow"; +const char pstrUsageALCustomCorpNewsBrowser [] PROGMEM = "AL Cust Corp News Brow"; +const char pstrUsageALOnlineActivityBrowser [] PROGMEM = "AL Online Act Brow"; +const char pstrUsageALResearchSearchBrowser [] PROGMEM = "AL Search Brow"; +const char pstrUsageALAudioPlayer [] PROGMEM = "AL Aud Player"; +const char pstrUsageGenericGUIAppControls [] PROGMEM = "Gen GUI App Ctrl"; +const char pstrUsageACNew [] PROGMEM = "AC New"; +const char pstrUsageACOpen [] PROGMEM = "AC Open"; +const char pstrUsageACClose [] PROGMEM = "AC Close"; +const char pstrUsageACExit [] PROGMEM = "AC Exit"; +const char pstrUsageACMaximize [] PROGMEM = "AC Max"; +const char pstrUsageACMinimize [] PROGMEM = "AC Min"; +const char pstrUsageACSave [] PROGMEM = "AC Save"; +const char pstrUsageACPrint [] PROGMEM = "AC Print"; +const char pstrUsageACProperties [] PROGMEM = "AC Prop"; +const char pstrUsageACUndo [] PROGMEM = "AC Undo"; +const char pstrUsageACCopy [] PROGMEM = "AC Copy"; +const char pstrUsageACCut [] PROGMEM = "AC Cut"; +const char pstrUsageACPaste [] PROGMEM = "AC Paste"; +const char pstrUsageACSelectAll [] PROGMEM = "AC Sel All"; +const char pstrUsageACFind [] PROGMEM = "AC Find"; +const char pstrUsageACFindAndReplace [] PROGMEM = "AC Find/Replace"; +const char pstrUsageACSearch [] PROGMEM = "AC Search"; +const char pstrUsageACGoto [] PROGMEM = "AC Goto"; +const char pstrUsageACHome [] PROGMEM = "AC Home"; +const char pstrUsageACBack [] PROGMEM = "AC Back"; +const char pstrUsageACForward [] PROGMEM = "AC Fwd"; +const char pstrUsageACStop [] PROGMEM = "AC Stop"; +const char pstrUsageACRefresh [] PROGMEM = "AC Refresh"; +const char pstrUsageACPreviousLink [] PROGMEM = "AC Prev Link"; +const char pstrUsageACNextLink [] PROGMEM = "AC Next Link"; +const char pstrUsageACBookmarks [] PROGMEM = "AC Bkmarks"; +const char pstrUsageACHistory [] PROGMEM = "AC Hist"; +const char pstrUsageACSubscriptions [] PROGMEM = "AC Subscr"; +const char pstrUsageACZoomIn [] PROGMEM = "AC Zoom In"; +const char pstrUsageACZoomOut [] PROGMEM = "AC Zoom Out"; +const char pstrUsageACZoom [] PROGMEM = "AC Zoom"; +const char pstrUsageACFullScreenView [] PROGMEM = "AC Full Scr"; +const char pstrUsageACNormalView [] PROGMEM = "AC Norm View"; +const char pstrUsageACViewToggle [] PROGMEM = "AC View Tgl"; +const char pstrUsageACScrollUp [] PROGMEM = "AC Scroll Up"; +const char pstrUsageACScrollDown [] PROGMEM = "AC Scroll Down"; +const char pstrUsageACScroll [] PROGMEM = "AC Scroll"; +const char pstrUsageACPanLeft [] PROGMEM = "AC Pan Left"; +const char pstrUsageACPanRight [] PROGMEM = "AC Pan Right"; +const char pstrUsageACPan [] PROGMEM = "AC Pan"; +const char pstrUsageACNewWindow [] PROGMEM = "AC New Wnd"; +const char pstrUsageACTileHoriz [] PROGMEM = "AC Tile Horiz"; +const char pstrUsageACTileVert [] PROGMEM = "AC Tile Vert"; +const char pstrUsageACFormat [] PROGMEM = "AC Frmt"; +const char pstrUsageACEdit [] PROGMEM = "AC Edit"; +const char pstrUsageACBold [] PROGMEM = "AC Bold"; +const char pstrUsageACItalics [] PROGMEM = "AC Ital"; +const char pstrUsageACUnderline [] PROGMEM = "AC Under"; +const char pstrUsageACStrikethrough [] PROGMEM = "AC Strike"; +const char pstrUsageACSubscript [] PROGMEM = "AC Sub"; +const char pstrUsageACSuperscript [] PROGMEM = "AC Super"; +const char pstrUsageACAllCaps [] PROGMEM = "AC All Caps"; +const char pstrUsageACRotate [] PROGMEM = "AC Rotate"; +const char pstrUsageACResize [] PROGMEM = "AC Resize"; +const char pstrUsageACFlipHorizontal [] PROGMEM = "AC Flp H"; +const char pstrUsageACFlipVertical [] PROGMEM = "AC Flp V"; +const char pstrUsageACMirrorHorizontal [] PROGMEM = "AC Mir H"; +const char pstrUsageACMirrorVertical [] PROGMEM = "AC Mir V"; +const char pstrUsageACFontSelect [] PROGMEM = "AC Fnt Sel"; +const char pstrUsageACFontColor [] PROGMEM = "AC Fnt Clr"; +const char pstrUsageACFontSize [] PROGMEM = "AC Fnt Size"; +const char pstrUsageACJustifyLeft [] PROGMEM = "AC Just Left"; +const char pstrUsageACJustifyCenterH [] PROGMEM = "AC Just Cent H"; +const char pstrUsageACJustifyRight [] PROGMEM = "AC Just Right"; +const char pstrUsageACJustifyBlockH [] PROGMEM = "AC Just Block H"; +const char pstrUsageACJustifyTop [] PROGMEM = "AC Just Top"; +const char pstrUsageACJustifyCenterV [] PROGMEM = "AC Just Cent V"; +const char pstrUsageACJustifyBottom [] PROGMEM = "AC Just Bot"; +const char pstrUsageACJustifyBlockV [] PROGMEM = "AC Just Block V"; +const char pstrUsageACIndentDecrease [] PROGMEM = "AC Indent Dec"; +const char pstrUsageACIndentIncrease [] PROGMEM = "AC Indent Inc"; +const char pstrUsageACNumberedList [] PROGMEM = "AC Num List"; +const char pstrUsageACRestartNumbering [] PROGMEM = "AC Res Num"; +const char pstrUsageACBulletedList [] PROGMEM = "AC Blt List"; +const char pstrUsageACPromote [] PROGMEM = "AC Promote"; +const char pstrUsageACDemote [] PROGMEM = "AC Demote"; +const char pstrUsageACYes [] PROGMEM = "AC Yes"; +const char pstrUsageACNo [] PROGMEM = "AC No"; +const char pstrUsageACCancel [] PROGMEM = "AC Cancel"; +const char pstrUsageACCatalog [] PROGMEM = "AC Ctlg"; +const char pstrUsageACBuyChkout [] PROGMEM = "AC Buy"; +const char pstrUsageACAddToCart [] PROGMEM = "AC Add2Cart"; +const char pstrUsageACExpand [] PROGMEM = "AC Xpnd"; +const char pstrUsageACExpandAll [] PROGMEM = "AC Xpand All"; +const char pstrUsageACCollapse [] PROGMEM = "AC Collapse"; +const char pstrUsageACCollapseAll [] PROGMEM = "AC Collapse All"; +const char pstrUsageACPrintPreview [] PROGMEM = "AC Prn Prevw"; +const char pstrUsageACPasteSpecial [] PROGMEM = "AC Paste Spec"; +const char pstrUsageACInsertMode [] PROGMEM = "AC Ins Mode"; +const char pstrUsageACDelete [] PROGMEM = "AC Del"; +const char pstrUsageACLock [] PROGMEM = "AC Lock"; +const char pstrUsageACUnlock [] PROGMEM = "AC Unlock"; +const char pstrUsageACProtect [] PROGMEM = "AC Prot"; +const char pstrUsageACUnprotect [] PROGMEM = "AC Unprot"; +const char pstrUsageACAttachComment [] PROGMEM = "AC Attach Cmnt"; +const char pstrUsageACDeleteComment [] PROGMEM = "AC Del Cmnt"; +const char pstrUsageACViewComment [] PROGMEM = "AC View Cmnt"; +const char pstrUsageACSelectWord [] PROGMEM = "AC Sel Word"; +const char pstrUsageACSelectSentence [] PROGMEM = "AC Sel Sntc"; +const char pstrUsageACSelectParagraph [] PROGMEM = "AC Sel Para"; +const char pstrUsageACSelectColumn [] PROGMEM = "AC Sel Col"; +const char pstrUsageACSelectRow [] PROGMEM = "AC Sel Row"; +const char pstrUsageACSelectTable [] PROGMEM = "AC Sel Tbl"; +const char pstrUsageACSelectObject [] PROGMEM = "AC Sel Obj"; +const char pstrUsageACRedoRepeat [] PROGMEM = "AC Redo"; +const char pstrUsageACSort [] PROGMEM = "AC Sort"; +const char pstrUsageACSortAscending [] PROGMEM = "AC Sort Asc"; +const char pstrUsageACSortDescending [] PROGMEM = "AC Sort Desc"; +const char pstrUsageACFilter [] PROGMEM = "AC Filt"; +const char pstrUsageACSetClock [] PROGMEM = "AC Set Clk"; +const char pstrUsageACViewClock [] PROGMEM = "AC View Clk"; +const char pstrUsageACSelectTimeZone [] PROGMEM = "AC Sel Time Z"; +const char pstrUsageACEditTimeZone [] PROGMEM = "AC Edt Time Z"; +const char pstrUsageACSetAlarm [] PROGMEM = "AC Set Alm"; +const char pstrUsageACClearAlarm [] PROGMEM = "AC Clr Alm"; +const char pstrUsageACSnoozeAlarm [] PROGMEM = "AC Snz Alm"; +const char pstrUsageACResetAlarm [] PROGMEM = "AC Rst Alm"; +const char pstrUsageACSyncronize [] PROGMEM = "AC Sync"; +const char pstrUsageACSendReceive [] PROGMEM = "AC Snd/Rcv"; +const char pstrUsageACSendTo [] PROGMEM = "AC Snd To"; +const char pstrUsageACReply [] PROGMEM = "AC Reply"; +const char pstrUsageACReplyAll [] PROGMEM = "AC Reply All"; +const char pstrUsageACForwardMessage [] PROGMEM = "AC Fwd Msg"; +const char pstrUsageACSend [] PROGMEM = "AC Snd"; +const char pstrUsageACAttachFile [] PROGMEM = "AC Att File"; +const char pstrUsageACUpload [] PROGMEM = "AC Upld"; +const char pstrUsageACDownload [] PROGMEM = "AC Dnld"; +const char pstrUsageACSetBorders [] PROGMEM = "AC Set Brd"; +const char pstrUsageACInsertRow [] PROGMEM = "AC Ins Row"; +const char pstrUsageACInsertColumn [] PROGMEM = "AC Ins Col"; +const char pstrUsageACInsertFile [] PROGMEM = "AC Ins File"; +const char pstrUsageACInsertPicture [] PROGMEM = "AC Ins Pic"; +const char pstrUsageACInsertObject [] PROGMEM = "AC Ins Obj"; +const char pstrUsageACInsertSymbol [] PROGMEM = "AC Ins Sym"; +const char pstrUsageACSaveAndClose [] PROGMEM = "AC Sav&Cls"; +const char pstrUsageACRename [] PROGMEM = "AC Rename"; +const char pstrUsageACMerge [] PROGMEM = "AC Merge"; +const char pstrUsageACSplit [] PROGMEM = "AC Split"; +const char pstrUsageACDistributeHorizontaly [] PROGMEM = "AC Dist Hor"; +const char pstrUsageACDistributeVerticaly [] PROGMEM = "AC Dist Ver"; + +// Digitaizers +const char pstrUsageDigitizer [] PROGMEM = "Digitizer"; +const char pstrUsagePen [] PROGMEM = "Pen"; +const char pstrUsageLightPen [] PROGMEM = "Light Pen"; +const char pstrUsageTouchScreen [] PROGMEM = "Touch Scr"; +const char pstrUsageTouchPad [] PROGMEM = "Touch Pad"; +const char pstrUsageWhiteBoard [] PROGMEM = "White Brd"; +const char pstrUsageCoordinateMeasuringMachine [] PROGMEM = "Coord Meas Mach"; +const char pstrUsage3DDigitizer [] PROGMEM = "3D Dgtz"; +const char pstrUsageStereoPlotter [] PROGMEM = "Stereo Plot"; +const char pstrUsageArticulatedArm [] PROGMEM = "Art Arm"; +const char pstrUsageArmature [] PROGMEM = "Armature"; +const char pstrUsageMultiplePointDigitizer [] PROGMEM = "Multi Point Dgtz"; +const char pstrUsageFreeSpaceWand [] PROGMEM = "Free Space Wand"; +const char pstrUsageStylus [] PROGMEM = "Stylus"; +const char pstrUsagePuck [] PROGMEM = "Puck"; +const char pstrUsageFinger [] PROGMEM = "Finger"; +const char pstrUsageTipPressure [] PROGMEM = "Tip Press"; +const char pstrUsageBarrelPressure [] PROGMEM = "Brl Press"; +const char pstrUsageInRange [] PROGMEM = "In Range"; +const char pstrUsageTouch [] PROGMEM = "Touch"; +const char pstrUsageUntouch [] PROGMEM = "Untouch"; +const char pstrUsageTap [] PROGMEM = "Tap"; +const char pstrUsageQuality [] PROGMEM = "Qlty"; +const char pstrUsageDataValid [] PROGMEM = "Data Valid"; +const char pstrUsageTransducerIndex [] PROGMEM = "Transducer Ind"; +const char pstrUsageTabletFunctionKeys [] PROGMEM = "Tabl Func Keys"; +const char pstrUsageProgramChangeKeys [] PROGMEM = "Pgm Chng Keys"; +//const char pstrUsageBatteryStrength [] PROGMEM = "Bat Strength"; +const char pstrUsageInvert [] PROGMEM = "Invert"; +const char pstrUsageXTilt [] PROGMEM = "X Tilt"; +const char pstrUsageYTilt [] PROGMEM = "Y Tilt"; +const char pstrUsageAzimuth [] PROGMEM = "Azimuth"; +const char pstrUsageAltitude [] PROGMEM = "Altitude"; +const char pstrUsageTwist [] PROGMEM = "Twist"; +const char pstrUsageTipSwitch [] PROGMEM = "Tip Sw"; +const char pstrUsageSecondaryTipSwitch [] PROGMEM = "Scnd Tip Sw"; +const char pstrUsageBarrelSwitch [] PROGMEM = "Brl Sw"; +const char pstrUsageEraser [] PROGMEM = "Eraser"; +const char pstrUsageTabletPick [] PROGMEM = "Tbl Pick"; + +// Alphanumeric Display Page +const char pstrUsageAlphanumericDisplay [] PROGMEM = "Alphanum Disp"; +const char pstrUsageBitmappedDisplay [] PROGMEM = "Bmp Disp"; +const char pstrUsageDisplayAttributesReport [] PROGMEM = "Disp Attr Rpt"; +const char pstrUsageASCIICharacterSet [] PROGMEM = "ASCII chset"; +const char pstrUsageDataReadBack [] PROGMEM = "Data Rd Back"; +const char pstrUsageFontReadBack [] PROGMEM = "Fnt Rd Back"; +const char pstrUsageDisplayControlReport [] PROGMEM = "Disp Ctrl Rpt"; +const char pstrUsageClearDisplay [] PROGMEM = "Clr Disp"; +//const char pstrUsageDisplayEnable [] PROGMEM = "Disp Enbl"; +const char pstrUsageScreenSaverDelay [] PROGMEM = "Scr Sav Delay"; +const char pstrUsageScreenSaverEnable [] PROGMEM = "Scr Sav Enbl"; +const char pstrUsageVerticalScroll [] PROGMEM = "V Scroll"; +const char pstrUsageHorizontalScroll [] PROGMEM = "H Scroll"; +const char pstrUsageCharacterReport [] PROGMEM = "Char Rpt"; +const char pstrUsageDisplayData [] PROGMEM = "Disp Data"; +const char pstrUsageDisplayStatus [] PROGMEM = "Disp Stat"; +const char pstrUsageStatusNotReady [] PROGMEM = "Stat !Ready"; +const char pstrUsageStatusReady [] PROGMEM = "Stat Ready"; +const char pstrUsageErrorNotALoadableCharacter [] PROGMEM = "Err Not Ld Char"; +const char pstrUsageErrorFotDataCanNotBeRead [] PROGMEM = "Fnt Data Rd Err"; +const char pstrUsageCursorPositionReport [] PROGMEM = "Cur Pos Rpt"; +const char pstrUsageRow [] PROGMEM = "Row"; +const char pstrUsageColumn [] PROGMEM = "Col"; +const char pstrUsageRows [] PROGMEM = "Rows"; +const char pstrUsageColumns [] PROGMEM = "Cols"; +const char pstrUsageCursorPixelPosition [] PROGMEM = "Cur Pix Pos"; +const char pstrUsageCursorMode [] PROGMEM = "Cur Mode"; +const char pstrUsageCursorEnable [] PROGMEM = "Cur Enbl"; +const char pstrUsageCursorBlink [] PROGMEM = "Cur Blnk"; +const char pstrUsageFontReport [] PROGMEM = "Fnt Rpt"; +const char pstrUsageFontData [] PROGMEM = "Fnt Data"; +const char pstrUsageCharacterWidth [] PROGMEM = "Char Wdth"; +const char pstrUsageCharacterHeight [] PROGMEM = "Char Hght"; +const char pstrUsageCharacterSpacingHorizontal [] PROGMEM = "Char Space H"; +const char pstrUsageCharacterSpacingVertical [] PROGMEM = "Char Space V"; +const char pstrUsageUnicodeCharset [] PROGMEM = "Unicode Char"; +const char pstrUsageFont7Segment [] PROGMEM = "Fnt 7-seg"; +const char pstrUsage7SegmentDirectMap [] PROGMEM = "7-seg map"; +const char pstrUsageFont14Segment [] PROGMEM = "Fnt 14-seg"; +const char pstrUsage14SegmentDirectMap [] PROGMEM = "14-seg map"; +const char pstrUsageDisplayBrightness [] PROGMEM = "Disp Bright"; +const char pstrUsageDisplayContrast [] PROGMEM = "Disp Cntrst"; +const char pstrUsageCharacterAttribute [] PROGMEM = "Char Attr"; +const char pstrUsageAttributeReadback [] PROGMEM = "Attr Readbk"; +const char pstrUsageAttributeData [] PROGMEM = "Attr Data"; +const char pstrUsageCharAttributeEnhance [] PROGMEM = "Char Attr Enh"; +const char pstrUsageCharAttributeUnderline [] PROGMEM = "Char Attr Undl"; +const char pstrUsageCharAttributeBlink [] PROGMEM = "Char Attr Blnk"; +const char pstrUsageBitmapSizeX [] PROGMEM = "Bmp Size X"; +const char pstrUsageBitmapSizeY [] PROGMEM = "Bmp Size Y"; +const char pstrUsageBitDepthFormat [] PROGMEM = "Bit Dpth Fmt"; +const char pstrUsageDisplayOrientation [] PROGMEM = "Disp Ornt"; +const char pstrUsagePaletteReport [] PROGMEM = "Pal Rpt"; +const char pstrUsagePaletteDataSize [] PROGMEM = "Pal Data Size"; +const char pstrUsagePaletteDataOffset [] PROGMEM = "Pal Data Off"; +const char pstrUsagePaletteData [] PROGMEM = "Pal Data"; +const char pstrUsageBlitReport [] PROGMEM = "Blit Rpt"; +const char pstrUsageBlitRectangleX1 [] PROGMEM = "Blit Rect X1"; +const char pstrUsageBlitRectangleY1 [] PROGMEM = "Blit Rect Y1"; +const char pstrUsageBlitRectangleX2 [] PROGMEM = "Blit Rect X2"; +const char pstrUsageBlitRectangleY2 [] PROGMEM = "Blit Rect Y2"; +const char pstrUsageBlitData [] PROGMEM = "Blit Data"; +const char pstrUsageSoftButton [] PROGMEM = "Soft Btn"; +const char pstrUsageSoftButtonID [] PROGMEM = "Soft Btn ID"; +const char pstrUsageSoftButtonSide [] PROGMEM = "Soft Btn Side"; +const char pstrUsageSoftButtonOffset1 [] PROGMEM = "Soft Btn Off1"; +const char pstrUsageSoftButtonOffset2 [] PROGMEM = "Soft Btn Off2"; +const char pstrUsageSoftButtonReport [] PROGMEM = "Soft Btn Rpt"; + +// Medical Instrument Page +const char pstrUsageMedicalUltrasound [] PROGMEM = "Med Ultrasnd"; +const char pstrUsageVCRAcquisition [] PROGMEM = "VCR/Acq"; +const char pstrUsageFreezeThaw [] PROGMEM = "Freeze"; +const char pstrUsageClipStore [] PROGMEM = "Clip Store"; +const char pstrUsageUpdate [] PROGMEM = "Update"; +const char pstrUsageNext [] PROGMEM = "Next"; +const char pstrUsageSave [] PROGMEM = "Save"; +const char pstrUsagePrint [] PROGMEM = "Print"; +const char pstrUsageMicrophoneEnable [] PROGMEM = "Mic Enbl"; +const char pstrUsageCine [] PROGMEM = "Cine"; +const char pstrUsageTransmitPower [] PROGMEM = "Trans Pwr"; +//const char pstrUsageVolume [] PROGMEM = "Vol"; +const char pstrUsageFocus [] PROGMEM = "Focus"; +const char pstrUsageDepth [] PROGMEM = "Depth"; +const char pstrUsageSoftStepPrimary [] PROGMEM = "Soft Stp-Pri"; +const char pstrUsageSoftStepSecondary [] PROGMEM = "Soft Stp-Sec"; +const char pstrUsageDepthGainCompensation [] PROGMEM = "Dpth Gain Comp"; +const char pstrUsageZoomSelect [] PROGMEM = "Zoom Sel"; +const char pstrUsageZoomAdjust [] PROGMEM = "Zoom Adj"; +const char pstrUsageSpectralDopplerModeSelect [] PROGMEM = "Spec Dop Mode Sel"; +const char pstrUsageSpectralDopplerModeAdjust [] PROGMEM = "Spec Dop Mode Adj"; +const char pstrUsageColorDopplerModeSelect [] PROGMEM = "Color Dop Mode Sel"; +const char pstrUsageColorDopplerModeAdjust [] PROGMEM = "Color Dop Mode Adj"; +const char pstrUsageMotionModeSelect [] PROGMEM = "Motion Mode Sel"; +const char pstrUsageMotionModeAdjust [] PROGMEM = "Motion Mode Adj"; +const char pstrUsage2DModeSelect [] PROGMEM = "2D Mode Sel"; +const char pstrUsage2DModeAdjust [] PROGMEM = "2D Mode Adj"; +const char pstrUsageSoftControlSelect [] PROGMEM = "Soft Ctrl Sel"; +const char pstrUsageSoftControlAdjust [] PROGMEM = "Soft Ctrl Adj"; + +//extern const char *usagePageTitles0[15]; +//const char *usagePageTitles1[]; +//const char *genDesktopTitles0[]; +//const char *genDesktopTitles1[]; +//const char *genDesktopTitles2[]; +//const char *genDesktopTitles3[]; +//const char *genDesktopTitles4[]; +//const char *simuTitles0[]; +//const char *simuTitles1[]; +//const char *simuTitles2[]; +//const char *vrTitles0[]; +//const char *vrTitles1[]; +//const char *sportsCtrlTitles0[]; +//const char *sportsCtrlTitles1[]; +//const char *sportsCtrlTitles2[]; +//const char *gameTitles0[]; +//const char *gameTitles1[]; +//const char *genDevCtrlTitles[]; +//const char *ledTitles[]; +//const char *telTitles0[]; +//const char *telTitles1[]; +//const char *telTitles2[]; +//const char *telTitles3[]; +//const char *telTitles4[]; +//const char *telTitles5[]; +//const char *consTitles0[]; +//const char *consTitles1[]; +//const char *consTitles2[]; +//const char *consTitles3[]; +//const char *consTitles4[]; +//const char *consTitles5[]; +//const char *consTitles6[]; +//const char *consTitles7[]; +//const char *consTitles8[]; +//const char *consTitles9[]; +//const char *consTitlesA[]; +//const char *consTitlesB[]; +//const char *consTitlesC[]; +//const char *consTitlesD[]; +//const char *consTitlesE[]; +//const char *digitTitles0[]; +//const char *digitTitles1[]; +//const char *digitTitles2[]; +//const char *aplphanumTitles0[]; +//const char *aplphanumTitles1[]; +//const char *aplphanumTitles2[]; +//const char *medInstrTitles0[]; +//const char *medInstrTitles1[]; +//const char *medInstrTitles2[]; +//const char *medInstrTitles3[]; +//const char *medInstrTitles4[]; + +#endif //__HIDUSAGESTR_H__ diff --git a/libraries/USBHost/src/macros.h b/libraries/USBHost/src/macros.h new file mode 100644 index 0000000..5df3faf --- /dev/null +++ b/libraries/USBHost/src/macros.h @@ -0,0 +1,82 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com + */ + +#if !defined(_usb_h_) || defined(MACROS_H) +#error "Never include macros.h directly; include Usb.h instead" +#else +#define MACROS_H + +//////////////////////////////////////////////////////////////////////////////// +// HANDY MACROS +//////////////////////////////////////////////////////////////////////////////// + +#define VALUE_BETWEEN(v,l,h) (((v)>(l)) && ((v)<(h))) +#define VALUE_WITHIN(v,l,h) (((v)>=(l)) && ((v)<=(h))) +#define output_pgm_message(wa,fp,mp,el) wa = &mp, fp((char *)/*pgm_read_pointer*/(wa), el) +#define output_if_between(v,l,h,wa,fp,mp,el) if(VALUE_BETWEEN(v,l,h)) output_pgm_message(wa,fp,mp[v-(l+1)],el); + +#define SWAP(a, b) (((a) ^= (b)), ((b) ^= (a)), ((a) ^= (b))) +#ifndef __BYTE_GRABBING_DEFINED__ +#define __BYTE_GRABBING_DEFINED__ 1 +#ifdef BROKEN_OPTIMIZER_LITTLE_ENDIAN +// Note: Use this if your compiler generates horrible assembler! +#define BGRAB0(__usi__) (((uint8_t *)&(__usi__))[0]) +#define BGRAB1(__usi__) (((uint8_t *)&(__usi__))[1]) +#define BGRAB2(__usi__) (((uint8_t *)&(__usi__))[2]) +#define BGRAB3(__usi__) (((uint8_t *)&(__usi__))[3]) +#define BGRAB4(__usi__) (((uint8_t *)&(__usi__))[4]) +#define BGRAB5(__usi__) (((uint8_t *)&(__usi__))[5]) +#define BGRAB6(__usi__) (((uint8_t *)&(__usi__))[6]) +#define BGRAB7(__usi__) (((uint8_t *)&(__usi__))[7]) +#else +// Note: The cast alone to uint8_t is actually enough. +// GCC throws out the "& 0xff", and the size is no different. +// Some compilers need it. +#define BGRAB0(__usi__) ((uint8_t)((__usi__) & 0xff )) +#define BGRAB1(__usi__) ((uint8_t)(((__usi__) >> 8) & 0xff)) +#define BGRAB2(__usi__) ((uint8_t)(((__usi__) >> 16) & 0xff)) +#define BGRAB3(__usi__) ((uint8_t)(((__usi__) >> 24) & 0xff)) +#define BGRAB4(__usi__) ((uint8_t)(((__usi__) >> 32) & 0xff)) +#define BGRAB5(__usi__) ((uint8_t)(((__usi__) >> 40) & 0xff)) +#define BGRAB6(__usi__) ((uint8_t)(((__usi__) >> 48) & 0xff)) +#define BGRAB7(__usi__) ((uint8_t)(((__usi__) >> 56) & 0xff)) +#endif +#define BOVER1(__usi__) ((uint16_t)(__usi__) << 8) +#define BOVER2(__usi__) ((uint32_t)(__usi__) << 16) +#define BOVER3(__usi__) ((uint32_t)(__usi__) << 24) +#define BOVER4(__usi__) ((uint64_t)(__usi__) << 32) +#define BOVER5(__usi__) ((uint64_t)(__usi__) << 40) +#define BOVER6(__usi__) ((uint64_t)(__usi__) << 48) +#define BOVER7(__usi__) ((uint64_t)(__usi__) << 56) + +// These are the smallest and fastest ways I have found so far in pure C/C++. +#define BMAKE16(__usc1__,__usc0__) ((uint16_t)((uint16_t)(__usc0__) | (uint16_t)BOVER1(__usc1__))) +#define BMAKE32(__usc3__,__usc2__,__usc1__,__usc0__) ((uint32_t)((uint32_t)(__usc0__) | (uint32_t)BOVER1(__usc1__) | (uint32_t)BOVER2(__usc2__) | (uint32_t)BOVER3(__usc3__))) +#define BMAKE64(__usc7__,__usc6__,__usc5__,__usc4__,__usc3__,__usc2__,__usc1__,__usc0__) ((uint64_t)((uint64_t)__usc0__ | (uint64_t)BOVER1(__usc1__) | (uint64_t)BOVER2(__usc2__) | (uint64_t)BOVER3(__usc3__) | (uint64_t)BOVER4(__usc4__) | (uint64_t)BOVER5(__usc5__) | (uint64_t)BOVER6(__usc6__) | (uint64_t)BOVER1(__usc7__))) +#endif + +/* + * Debug macros: Strings are stored in progmem (flash) instead of RAM. + */ +#define USBTRACE(s) (Notify(PSTR(s), 0x80)) +#define USBTRACE1(s,l) (Notify(PSTR(s), l)) +#define USBTRACE2(s,r) (Notify(PSTR(s), 0x80), D_PrintHex((r), 0x80), Notify(PSTR("\r\n"), 0x80)) +#define USBTRACE3(s,r,l) (Notify(PSTR(s), l), D_PrintHex((r), l), Notify(PSTR("\r\n"), l)) + + +#endif /* MACROS_H */ + diff --git a/libraries/USBHost/src/message.cpp b/libraries/USBHost/src/message.cpp new file mode 100644 index 0000000..960a9fb --- /dev/null +++ b/libraries/USBHost/src/message.cpp @@ -0,0 +1,116 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com + */ + +#include "Usb.h" +// 0x80 is the default (i.e. trace) to turn off set this global to something lower. +// this allows for 126 other debugging levels. +// TO-DO: Allow assignment to a different serial port by software +int UsbDEBUGlvl = 0x80; + +void E_Notifyc(char c, int lvl) { + if(UsbDEBUGlvl < lvl) return; +#if defined(ARDUINO) && ARDUINO >=100 + USB_HOST_SERIAL.print(c); +#else + USB_HOST_SERIAL.print(c, BYTE); +#endif + //USB_HOST_SERIAL.flush(); +} + +void E_Notify(char const * msg, int lvl) { + if(UsbDEBUGlvl < lvl) return; + if(!msg) return; + char c; + + while((c = pgm_read_byte(msg++))) E_Notifyc(c, lvl); +} + +void E_NotifyStr(char const * msg, int lvl) { + if(UsbDEBUGlvl < lvl) return; + if(!msg) return; + char c; + + while((c = *msg++)) E_Notifyc(c, lvl); +} + +void E_Notify(uint8_t b, int lvl) { + if(UsbDEBUGlvl < lvl) return; +#if defined(ARDUINO) && ARDUINO >=100 + USB_HOST_SERIAL.print(b); +#else + USB_HOST_SERIAL.print(b, DEC); +#endif + //USB_HOST_SERIAL.flush(); +} + +void E_Notify(double d, int lvl) { + if(UsbDEBUGlvl < lvl) return; + USB_HOST_SERIAL.print(d); + //USB_HOST_SERIAL.flush(); +} + +#ifdef DEBUG_USB_HOST + +void NotifyFailGetDevDescr(void) { + Notify(PSTR("\r\ngetDevDescr "), 0x80); +} + +void NotifyFailSetDevTblEntry(void) { + Notify(PSTR("\r\nsetDevTblEn "), 0x80); +} + +void NotifyFailGetConfDescr(void) { + Notify(PSTR("\r\ngetConf "), 0x80); +} + +void NotifyFailSetConfDescr(void) { + Notify(PSTR("\r\nsetConf "), 0x80); +} + +void NotifyFailGetDevDescr(uint8_t reason) { + NotifyFailGetDevDescr(); + NotifyFail(reason); +} + +void NotifyFailSetDevTblEntry(uint8_t reason) { + NotifyFailSetDevTblEntry(); + NotifyFail(reason); + +} + +void NotifyFailGetConfDescr(uint8_t reason) { + NotifyFailGetConfDescr(); + NotifyFail(reason); +} + +void NotifyFailSetConfDescr(uint8_t reason) { + NotifyFailSetConfDescr(); + NotifyFail(reason); +} + +void NotifyFailUnknownDevice(uint16_t VID, uint16_t PID) { + Notify(PSTR("\r\nUnknown Device Connected - VID: "), 0x80); + D_PrintHex (VID, 0x80); + Notify(PSTR(" PID: "), 0x80); + D_PrintHex (PID, 0x80); +} + +void NotifyFail(uint8_t rcode) { + D_PrintHex (rcode, 0x80); + Notify(PSTR("\r\n"), 0x80); +} +#endif diff --git a/libraries/USBHost/src/message.h b/libraries/USBHost/src/message.h new file mode 100644 index 0000000..6144b56 --- /dev/null +++ b/libraries/USBHost/src/message.h @@ -0,0 +1,84 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com + */ +#if !defined(_usb_h_) || defined(__MESSAGE_H__) +#error "Never include message.h directly; include Usb.h instead" +#else +#define __MESSAGE_H__ + +extern int UsbDEBUGlvl; + +void E_Notify(char const * msg, int lvl); +void E_Notify(uint8_t b, int lvl); +void E_NotifyStr(char const * msg, int lvl); +void E_Notifyc(char c, int lvl); + +#ifdef DEBUG_USB_HOST +#define Notify E_Notify +#define NotifyStr E_NotifyStr +#define Notifyc E_Notifyc +void NotifyFailGetDevDescr(uint8_t reason); +void NotifyFailSetDevTblEntry(uint8_t reason); +void NotifyFailGetConfDescr(uint8_t reason); +void NotifyFailSetConfDescr(uint8_t reason); +void NotifyFailGetDevDescr(void); +void NotifyFailSetDevTblEntry(void); +void NotifyFailGetConfDescr(void); +void NotifyFailSetConfDescr(void); +void NotifyFailUnknownDevice(uint16_t VID, uint16_t PID); +void NotifyFail(uint8_t rcode); +#else +#define Notify(...) ((void)0) +#define NotifyStr(...) ((void)0) +#define Notifyc(...) ((void)0) +#define NotifyFailGetDevDescr(...) ((void)0) +#define NotifyFailSetDevTblEntry(...) ((void)0) +#define NotifyFailGetConfDescr(...) ((void)0) +#define NotifyFailGetDevDescr(...) ((void)0) +#define NotifyFailSetDevTblEntry(...) ((void)0) +#define NotifyFailGetConfDescr(...) ((void)0) +#define NotifyFailSetConfDescr(...) ((void)0) +#define NotifyFailUnknownDevice(...) ((void)0) +#define NotifyFail(...) ((void)0) +#endif + +#ifdef DEBUG_USB_HOST +template +void ErrorMessage(uint8_t level, char const * msg, ERROR_TYPE rcode = 0) { + Notify(msg, level); + Notify(PSTR(": "), level); + D_PrintHex (rcode, level); + Notify(PSTR("\r\n"), level); +} + +template +void ErrorMessage(char const * msg, ERROR_TYPE rcode = 0) { + Notify(msg, 0x80); + Notify(PSTR(": "), 0x80); + D_PrintHex (rcode, 0x80); + Notify(PSTR("\r\n"), 0x80); +} +#else +template +void ErrorMessage(uint8_t, char const *, ERROR_TYPE = 0) { +} + +template +void ErrorMessage(char const *, ERROR_TYPE = 0) { +} +#endif + +#endif // __MESSAGE_H__ diff --git a/libraries/USBHost/src/parsetools.cpp b/libraries/USBHost/src/parsetools.cpp new file mode 100644 index 0000000..00ca9e6 --- /dev/null +++ b/libraries/USBHost/src/parsetools.cpp @@ -0,0 +1,67 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com +*/ +#include "Usb.h" + +bool MultiByteValueParser::Parse(uint8_t **pp, uint32_t *pcntdn) { + if(!pBuf) { + Notify(PSTR("Buffer pointer is NULL!\r\n"), 0x80); + return false; + } + for (; countDown && (*pcntdn); countDown--, (*pcntdn)--, (*pp)++) + pBuf[valueSize - countDown] = (**pp); + + if(countDown) + return false; + + countDown = valueSize; + return true; +} + +bool PTPListParser::Parse(uint8_t **pp, uint32_t *pcntdn, PTP_ARRAY_EL_FUNC pf, const void *me) { + switch(nStage) { + case 0: + pBuf->valueSize = lenSize; + theParser.Initialize(pBuf); + nStage = 1; + + case 1: + if(!theParser.Parse(pp, pcntdn)) + return false; + + arLen = 0; + arLen = (pBuf->valueSize >= 4) ? *((uint32_t*)pBuf->pValue) : (uint32_t)(*((uint16_t*)pBuf->pValue)); + arLenCntdn = arLen; + nStage = 2; + + case 2: + pBuf->valueSize = valSize; + theParser.Initialize(pBuf); + nStage = 3; + + case 3: + for(; arLenCntdn; arLenCntdn--) { + if(!theParser.Parse(pp, pcntdn)) + return false; + + if(pf) + pf(pBuf, (arLen - arLenCntdn), me); + } + + nStage = 0; + } + return true; +} diff --git a/libraries/USBHost/src/parsetools.h b/libraries/USBHost/src/parsetools.h new file mode 100644 index 0000000..d463358 --- /dev/null +++ b/libraries/USBHost/src/parsetools.h @@ -0,0 +1,143 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com +*/ + +#if !defined(_usb_h_) || defined(__PARSETOOLS_H__) +#error "Never include parsetools.h directly; include Usb.h instead" +#else +#define __PARSETOOLS_H__ + +#include +//#include "Arduino.h" + +struct MultiValueBuffer { + uint8_t valueSize; + void *pValue; +}; + +class MultiByteValueParser { + uint8_t *pBuf; + uint32_t countDown; + uint32_t valueSize; + +public: + + MultiByteValueParser() : pBuf(NULL), countDown(0), valueSize(0) { + }; + + const uint8_t* GetBuffer() { + return pBuf; + }; + + void Initialize(MultiValueBuffer * const pbuf) { + pBuf = (uint8_t*)pbuf->pValue; + countDown = valueSize = pbuf->valueSize; + }; + + bool Parse(uint8_t **pp, uint32_t *pcntdn); +}; + +class ByteSkipper { + uint8_t *pBuf; + uint32_t nStage; + uint32_t countDown; + +public: + + ByteSkipper() : pBuf(NULL), nStage(0), countDown(0) { + }; + + void Initialize(MultiValueBuffer *pbuf) { + pBuf = (uint8_t*)pbuf->pValue; + countDown = 0; + }; + + bool Skip(uint8_t **pp, uint32_t *pcntdn, uint32_t bytes_to_skip) { + switch(nStage) { + case 0: + countDown = bytes_to_skip; + nStage++; + case 1: + for(; countDown && (*pcntdn); countDown--, (*pp)++, (*pcntdn)--); + + if(!countDown) + nStage = 0; + }; + return (!countDown); + }; +}; + +// Pointer to a callback function triggered for each element of PTP array when used with PTPArrayParser +typedef void (*PTP_ARRAY_EL_FUNC)(const MultiValueBuffer * const p, uint32_t count, const void *me); + +class PTPListParser { +public: + + enum ParseMode { + modeArray, modeRange/*, modeEnum*/ + }; + +private: + uint32_t nStage; + uint32_t enStage; + + uint32_t arLen; + uint32_t arLenCntdn; + + uint32_t lenSize; // size of the array length field in bytes + uint32_t valSize; // size of the array element in bytes + + MultiValueBuffer *pBuf; + + // The only parser for both size and array element parsing + MultiByteValueParser theParser; + + uint32_t /*ParseMode*/ prsMode; + +public: + + PTPListParser() : + nStage(0), + enStage(0), + arLen(0), + arLenCntdn(0), + lenSize(0), + valSize(0), + pBuf(NULL), + prsMode(modeArray) { + }; + + void Initialize(const uint32_t len_size, const uint32_t val_size, MultiValueBuffer * const p, const uint32_t mode = modeArray) { + pBuf = p; + lenSize = len_size; + valSize = val_size; + prsMode = mode; + + if(prsMode == modeRange) { + arLenCntdn = arLen = 3; + nStage = 2; + } else { + arLenCntdn = arLen = 0; + nStage = 0; + } + enStage = 0; + theParser.Initialize(p); + }; + + bool Parse(uint8_t **pp, uint32_t *pcntdn, PTP_ARRAY_EL_FUNC pf, const void *me = NULL); +}; + +#endif // __PARSETOOLS_H__ diff --git a/libraries/USBHost/src/printhex.h b/libraries/USBHost/src/printhex.h new file mode 100644 index 0000000..60dcd06 --- /dev/null +++ b/libraries/USBHost/src/printhex.h @@ -0,0 +1,91 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com + */ + +#if !defined(_usb_h_) || defined(__PRINTHEX_H__) +#error "Never include printhex.h directly; include Usb.h instead" +#else +#define __PRINTHEX_H__ + +#include + +void E_Notifyc(char c, int lvl); + +template +void PrintHex(T val, int lvl) { + int num_nibbles = sizeof (T) * 2; + + do { + char v = 48 + (((val >> (num_nibbles - 1) * 4)) & 0x0f); + if(v > 57) v += 7; + E_Notifyc(v, lvl); + } while(--num_nibbles); +} + +template +void PrintBin(T val, int lvl) { + for(T mask = (((T)1) << ((sizeof (T) << 3) - 1)); mask; mask >>= 1) + if(val & mask) + E_Notifyc('1', lvl); + else + E_Notifyc('0', lvl); +} + +template +void SerialPrintHex(T val) { + int num_nibbles = sizeof (T) * 2; + + do { + char v = 48 + (((val >> (num_nibbles - 1) * 4)) & 0x0f); + if(v > 57) v += 7; + USB_HOST_SERIAL.print(v); + } while(--num_nibbles); +} + +template +void PrintHex2(Print *prn, T val) { + T mask = (((T)1) << (((sizeof (T) << 1) - 1) << 2)); + + while(mask > 1) { + if(val < mask) + prn->print("0"); + + mask >>= 4; + } + prn->print((T)val, HEX); +} + +#ifdef DEBUG_USB_HOST +template void D_PrintHex(T val, int lvl) { + PrintHex (val, lvl); +} + +template +void D_PrintBin(T val, int lvl) { + PrintBin (val, lvl); +} +#else +template void D_PrintHex(T, int) { +} + +template +void D_PrintBin(T, int) { +} +#endif + + + +#endif // __PRINTHEX_H__ diff --git a/libraries/USBHost/src/sink_parser.h b/libraries/USBHost/src/sink_parser.h new file mode 100644 index 0000000..f1c7386 --- /dev/null +++ b/libraries/USBHost/src/sink_parser.h @@ -0,0 +1,41 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com + */ +#if !defined(_usb_h_) || defined(__SINK_PARSER_H__) +#error "Never include hexdump.h directly; include Usb.h instead" +#else +#define __SINK_PARSER_H__ + +extern int UsbDEBUGlvl; + +// This parser does absolutely nothing with the data, just swallows it. + +template +class SinkParser : public BASE_CLASS { +public: + + SinkParser() { + }; + + void Initialize() { + }; + + void Parse(const LEN_TYPE /* len */, const uint8_t * /* pbuf */, const OFFSET_TYPE & /* offset */) { + }; +}; + + +#endif // __HEXDUMP_H__ diff --git a/libraries/USBHost/src/usb_ch9.h b/libraries/USBHost/src/usb_ch9.h new file mode 100644 index 0000000..09dd94b --- /dev/null +++ b/libraries/USBHost/src/usb_ch9.h @@ -0,0 +1,174 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com +*/ + +#if !defined(_usb_h_) || defined(_ch9_h_) +#error "Never include usb_ch9.h directly; include Usb.h instead" +#else + +/* USB chapter 9 structures */ +#define _ch9_h_ + +#include + +/* Misc.USB constants */ +#define DEV_DESCR_LEN 18 //device descriptor length +#define CONF_DESCR_LEN 9 //configuration descriptor length +#define INTR_DESCR_LEN 9 //interface descriptor length +#define EP_DESCR_LEN 7 //endpoint descriptor length + +/* Standard Device Requests */ + +#define USB_REQUEST_GET_STATUS 0 // Standard Device Request - GET STATUS +#define USB_REQUEST_CLEAR_FEATURE 1 // Standard Device Request - CLEAR FEATURE +#define USB_REQUEST_SET_FEATURE 3 // Standard Device Request - SET FEATURE +#define USB_REQUEST_SET_ADDRESS 5 // Standard Device Request - SET ADDRESS +#define USB_REQUEST_GET_DESCRIPTOR 6 // Standard Device Request - GET DESCRIPTOR +#define USB_REQUEST_SET_DESCRIPTOR 7 // Standard Device Request - SET DESCRIPTOR +#define USB_REQUEST_GET_CONFIGURATION 8 // Standard Device Request - GET CONFIGURATION +#define USB_REQUEST_SET_CONFIGURATION 9 // Standard Device Request - SET CONFIGURATION +#define USB_REQUEST_GET_INTERFACE 10 // Standard Device Request - GET INTERFACE +#define USB_REQUEST_SET_INTERFACE 11 // Standard Device Request - SET INTERFACE +#define USB_REQUEST_SYNCH_FRAME 12 // Standard Device Request - SYNCH FRAME + +#define USB_FEATURE_ENDPOINT_HALT 0 // CLEAR/SET FEATURE - Endpoint Halt +#define USB_FEATURE_DEVICE_REMOTE_WAKEUP 1 // CLEAR/SET FEATURE - Device remote wake-up +#define USB_FEATURE_TEST_MODE 2 // CLEAR/SET FEATURE - Test mode + +/* Setup Data Constants */ + +#define USB_SETUP_HOST_TO_DEVICE 0x00 // Device Request bmRequestType transfer direction - host to device transfer +#define USB_SETUP_DEVICE_TO_HOST 0x80 // Device Request bmRequestType transfer direction - device to host transfer +#define USB_SETUP_TYPE_STANDARD 0x00 // Device Request bmRequestType type - standard +#define USB_SETUP_TYPE_CLASS 0x20 // Device Request bmRequestType type - class +#define USB_SETUP_TYPE_VENDOR 0x40 // Device Request bmRequestType type - vendor +#define USB_SETUP_RECIPIENT_DEVICE 0x00 // Device Request bmRequestType recipient - device +#define USB_SETUP_RECIPIENT_INTERFACE 0x01 // Device Request bmRequestType recipient - interface +#define USB_SETUP_RECIPIENT_ENDPOINT 0x02 // Device Request bmRequestType recipient - endpoint +#define USB_SETUP_RECIPIENT_OTHER 0x03 // Device Request bmRequestType recipient - other + +/* USB descriptors */ + +#define USB_DESCRIPTOR_DEVICE 0x01 // bDescriptorType for a Device Descriptor. +#define USB_DESCRIPTOR_CONFIGURATION 0x02 // bDescriptorType for a Configuration Descriptor. +#define USB_DESCRIPTOR_STRING 0x03 // bDescriptorType for a String Descriptor. +#define USB_DESCRIPTOR_INTERFACE 0x04 // bDescriptorType for an Interface Descriptor. +#define USB_DESCRIPTOR_ENDPOINT 0x05 // bDescriptorType for an Endpoint Descriptor. +#define USB_DESCRIPTOR_DEVICE_QUALIFIER 0x06 // bDescriptorType for a Device Qualifier. +#define USB_DESCRIPTOR_OTHER_SPEED 0x07 // bDescriptorType for a Other Speed Configuration. +#define USB_DESCRIPTOR_INTERFACE_POWER 0x08 // bDescriptorType for Interface Power. +#define USB_DESCRIPTOR_OTG 0x09 // bDescriptorType for an OTG Descriptor. + +#define HID_DESCRIPTOR_HID 0x21 + + + +/* OTG SET FEATURE Constants */ +#define OTG_FEATURE_B_HNP_ENABLE 3 // SET FEATURE OTG - Enable B device to perform HNP +#define OTG_FEATURE_A_HNP_SUPPORT 4 // SET FEATURE OTG - A device supports HNP +#define OTG_FEATURE_A_ALT_HNP_SUPPORT 5 // SET FEATURE OTG - Another port on the A device supports HNP + +/* USB Endpoint Transfer Types */ +#define USB_TRANSFER_TYPE_CONTROL 0x00 // Endpoint is a control endpoint. +#define USB_TRANSFER_TYPE_ISOCHRONOUS 0x01 // Endpoint is an isochronous endpoint. +#define USB_TRANSFER_TYPE_BULK 0x02 // Endpoint is a bulk endpoint. +#define USB_TRANSFER_TYPE_INTERRUPT 0x03 // Endpoint is an interrupt endpoint. +#define bmUSB_TRANSFER_TYPE 0x03 // bit mask to separate transfer type from ISO attributes + + +/* Standard Feature Selectors for CLEAR_FEATURE Requests */ +#define USB_FEATURE_ENDPOINT_STALL 0 // Endpoint recipient +#define USB_FEATURE_DEVICE_REMOTE_WAKEUP 1 // Device recipient +#define USB_FEATURE_TEST_MODE 2 // Device recipient + +_Pragma("pack(1)") + +/* descriptor data structures */ + +/* Device descriptor structure */ +typedef struct { + uint8_t bLength; // Length of this descriptor. + uint8_t bDescriptorType; // DEVICE descriptor type (USB_DESCRIPTOR_DEVICE). + uint16_t bcdUSB; // USB Spec Release Number (BCD). + uint8_t bDeviceClass; // Class code (assigned by the USB-IF). 0xFF-Vendor specific. + uint8_t bDeviceSubClass; // Subclass code (assigned by the USB-IF). + uint8_t bDeviceProtocol; // Protocol code (assigned by the USB-IF). 0xFF-Vendor specific. + uint8_t bMaxPacketSize0; // Maximum packet size for endpoint 0. + uint16_t idVendor; // Vendor ID (assigned by the USB-IF). + uint16_t idProduct; // Product ID (assigned by the manufacturer). + uint16_t bcdDevice; // Device release number (BCD). + uint8_t iManufacturer; // Index of String Descriptor describing the manufacturer. + uint8_t iProduct; // Index of String Descriptor describing the product. + uint8_t iSerialNumber; // Index of String Descriptor with the device's serial number. + uint8_t bNumConfigurations; // Number of possible configurations. +} USB_DEVICE_DESCRIPTOR; + +/* Configuration descriptor structure */ +typedef struct { + uint8_t bLength; // Length of this descriptor. + uint8_t bDescriptorType; // CONFIGURATION descriptor type (USB_DESCRIPTOR_CONFIGURATION). + uint16_t wTotalLength; // Total length of all descriptors for this configuration. + uint8_t bNumInterfaces; // Number of interfaces in this configuration. + uint8_t bConfigurationValue; // Value of this configuration (1 based). + uint8_t iConfiguration; // Index of String Descriptor describing the configuration. + uint8_t bmAttributes; // Configuration characteristics. + uint8_t bMaxPower; // Maximum power consumed by this configuration. +} USB_CONFIGURATION_DESCRIPTOR; + +/* Interface descriptor structure */ +typedef struct { + uint8_t bLength; // Length of this descriptor. + uint8_t bDescriptorType; // INTERFACE descriptor type (USB_DESCRIPTOR_INTERFACE). + uint8_t bInterfaceNumber; // Number of this interface (0 based). + uint8_t bAlternateSetting; // Value of this alternate interface setting. + uint8_t bNumEndpoints; // Number of endpoints in this interface. + uint8_t bInterfaceClass; // Class code (assigned by the USB-IF). 0xFF-Vendor specific. + uint8_t bInterfaceSubClass; // Subclass code (assigned by the USB-IF). + uint8_t bInterfaceProtocol; // Protocol code (assigned by the USB-IF). 0xFF-Vendor specific. + uint8_t iInterface; // Index of String Descriptor describing the interface. +} USB_INTERFACE_DESCRIPTOR; + +/* Endpoint descriptor structure */ +typedef struct { + uint8_t bLength; // Length of this descriptor. + uint8_t bDescriptorType; // ENDPOINT descriptor type (USB_DESCRIPTOR_ENDPOINT). + uint8_t bEndpointAddress; // Endpoint address. Bit 7 indicates direction (0=OUT, 1=IN). + uint8_t bmAttributes; // Endpoint transfer type. + uint16_t wMaxPacketSize; // Maximum packet size. + uint8_t bInterval; // Polling interval in frames. +} USB_ENDPOINT_DESCRIPTOR; + + +/* HID descriptor */ +typedef struct { + uint8_t bLength; + uint8_t bDescriptorType; + uint16_t bcdHID; // HID class specification release + uint8_t bCountryCode; + uint8_t bNumDescriptors; // Number of additional class specific descriptors + uint8_t bDescrType; // Type of class descriptor + uint16_t wDescriptorLength; // Total size of the Report descriptor +} USB_HID_DESCRIPTOR; + +typedef struct { + uint8_t bDescrType; // Type of class descriptor + uint16_t wDescriptorLength; // Total size of the Report descriptor +} HID_CLASS_DESCRIPTOR_LEN_AND_TYPE; + +_Pragma("pack()") + +#endif // _ch9_h_ + diff --git a/libraries/USBHost/src/usbhub.cpp b/libraries/USBHost/src/usbhub.cpp new file mode 100644 index 0000000..f79a60b --- /dev/null +++ b/libraries/USBHost/src/usbhub.cpp @@ -0,0 +1,428 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com + */ +#include "usbhub.h" +#include "api/Common.h" + +bool USBHub::bResetInitiated = false; + +USBHub::USBHub(USBHost *p) : +pUsb(p), +bAddress(0), +bNbrPorts(0), +//bInitState(0), +qNextPollTime(0), +bPollEnable(false) { + epInfo[0].epAddr = 0; + epInfo[0].maxPktSize = 8; + epInfo[0].bmSndToggle = 0; + epInfo[0].bmRcvToggle = 0; + epInfo[0].bmNakPower = USB_NAK_MAX_POWER; + + epInfo[1].epAddr = 1; + epInfo[1].maxPktSize = 8; //kludge + epInfo[1].bmSndToggle = 0; + epInfo[1].bmRcvToggle = 0; + epInfo[1].bmNakPower = USB_NAK_NOWAIT; + + if(pUsb) + pUsb->RegisterDeviceClass(this); +} + +uint32_t USBHub::Init(uint32_t parent, uint32_t port, uint32_t lowspeed) { + uint8_t buf[32]; + USB_DEVICE_DESCRIPTOR * udd = reinterpret_cast(buf); + HubDescriptor* hd = reinterpret_cast(buf); + USB_CONFIGURATION_DESCRIPTOR * ucd = reinterpret_cast(buf); + uint32_t rcode; + UsbDeviceDefinition *p = NULL; + EpInfo *oldep_ptr = NULL; + uint32_t len = 0; + uint32_t cd_len = 0; + + //USBTRACE("\r\nHub Init Start "); + //D_PrintHex (bInitState, 0x80); + + AddressPool &addrPool = pUsb->GetAddressPool(); + + //switch (bInitState) { + // case 0: + if(bAddress) + return USB_ERROR_CLASS_INSTANCE_ALREADY_IN_USE; + + // Get pointer to pseudo device with address 0 assigned + p = addrPool.GetUsbDevicePtr(0); + + if(!p) + return USB_ERROR_ADDRESS_NOT_FOUND_IN_POOL; + + if(!p->epinfo) + return USB_ERROR_EPINFO_IS_NULL; + + // Save old pointer to EP_RECORD of address 0 + oldep_ptr = p->epinfo; + + // Temporary assign new pointer to epInfo to p->epinfo in order to avoid toggle inconsistence + p->epinfo = epInfo; + + p->lowspeed = lowspeed; + + // Get device descriptor + rcode = pUsb->getDevDescr(0, 0, 8, (uint8_t*)buf); + + p->lowspeed = false; + + if(!rcode) + len = (buf[0] > 32) ? 32 : buf[0]; + + if(rcode) { + // Restore p->epinfo + p->epinfo = oldep_ptr; + return rcode; + } + + // Extract device class from device descriptor + // If device class is not a hub return + if(udd->bDeviceClass != 0x09) + return USB_DEV_CONFIG_ERROR_DEVICE_NOT_SUPPORTED; + + // Allocate new address according to device class + bAddress = addrPool.AllocAddress(parent, (udd->bDeviceClass == 0x09) ? true : false, port); + + if(!bAddress) + return USB_ERROR_OUT_OF_ADDRESS_SPACE_IN_POOL; + + // Extract Max Packet Size from the device descriptor + epInfo[0].maxPktSize = udd->bMaxPacketSize0; + + // Assign new address to the device + rcode = pUsb->setAddr(0, 0, bAddress); + + if(rcode) { + // Restore p->epinfo + p->epinfo = oldep_ptr; + addrPool.FreeAddress(bAddress); + bAddress = 0; + return rcode; + } + + //USBTRACE2("\r\nHub address: ", bAddress ); + + // Restore p->epinfo + p->epinfo = oldep_ptr; + + if(len) + rcode = pUsb->getDevDescr(bAddress, 0, len, (uint8_t*)buf); + + if(rcode) + goto FailGetDevDescr; + + // Assign epInfo to epinfo pointer + rcode = pUsb->setEpInfoEntry(bAddress, 2, epInfo); + + if(rcode) + goto FailSetDevTblEntry; + + // bInitState = 1; + + // case 1: + // Get hub descriptor + rcode = GetHubDescriptor(0, 8, buf); + + if(rcode) + goto FailGetHubDescr; + + // Save number of ports for future use + bNbrPorts = hd->bNbrPorts; + + // bInitState = 2; + + // case 2: + // Read configuration Descriptor in Order To Obtain Proper Configuration Value + rcode = pUsb->getConfDescr(bAddress, 0, 8, 0, buf); + + if(!rcode) { + cd_len = ucd->wTotalLength; + rcode = pUsb->getConfDescr(bAddress, 0, cd_len, 0, buf); + } + if(rcode) + goto FailGetConfDescr; + + // The following code is of no practical use in real life applications. + // It only intended for the usb protocol sniffer to properly parse hub-class requests. + { + uint8_t buf2[24]; + + rcode = pUsb->getConfDescr(bAddress, 0, buf[0], 0, buf2); + + if(rcode) + goto FailGetConfDescr; + } + + // Set Configuration Value + rcode = pUsb->setConf(bAddress, 0, buf[5]); + + if(rcode) + goto FailSetConfDescr; + + // bInitState = 3; + + // case 3: + // Power on all ports + for(uint32_t j = 1; j <= bNbrPorts; j++) + SetPortFeature(HUB_FEATURE_PORT_POWER, j, 0); //HubPortPowerOn(j); + + pUsb->SetHubPreMask(); + bPollEnable = true; + // bInitState = 0; + //} + //bInitState = 0; + //USBTRACE("...OK\r\n"); + return 0; + + // Oleg, No debugging?? -- xxxajk +FailGetDevDescr: + goto Fail; + +FailSetDevTblEntry: + goto Fail; + +FailGetHubDescr: + goto Fail; + +FailGetConfDescr: + goto Fail; + +FailSetConfDescr: + goto Fail; + +Fail: + USBTRACE("...FAIL\r\n"); + return rcode; +} + +uint32_t USBHub::Release() { + pUsb->GetAddressPool().FreeAddress(bAddress); + + if(bAddress == 0x41) + pUsb->SetHubPreMask(); + + bAddress = 0; + bNbrPorts = 0; + qNextPollTime = 0; + bPollEnable = false; + return 0; +} + +uint32_t USBHub::Poll() { + uint32_t rcode = 0; + + if(!bPollEnable) + return 0; + + if(((long)(millis() - qNextPollTime) >= 0L)) { + rcode = CheckHubStatus(); + qNextPollTime = millis() + 100; + } + return rcode; +} + +uint32_t USBHub::CheckHubStatus() { + uint32_t rcode; + uint8_t buf[8]; + uint32_t read = 1; + + rcode = pUsb->inTransfer(bAddress, 1, (uint8_t*)&read, buf); + + if(rcode) + return rcode; + + //if (buf[0] & 0x01) // Hub Status Change + //{ + // pUsb->PrintHubStatus(addr); + // rcode = GetHubStatus(1, 0, 1, 4, buf); + // if (rcode) + // { + // USB_HOST_SERIAL.print("GetHubStatus Error"); + // USB_HOST_SERIAL.println(rcode, HEX); + // return rcode; + // } + //} + for(uint32_t port = 1, mask = 0x02; port < 8; mask <<= 1, port++) { + if(buf[0] & mask) { + HubEvent evt; + evt.bmEvent = 0; + + rcode = GetPortStatus(port, 4, evt.evtBuff); + + if(rcode) + continue; + + rcode = PortStatusChange(port, evt); + + if(rcode == HUB_ERROR_PORT_HAS_BEEN_RESET) + return 0; + + if(rcode) + return rcode; + } + } // for + + for(uint32_t port = 1; port <= bNbrPorts; port++) { + HubEvent evt; + evt.bmEvent = 0; + + rcode = GetPortStatus(port, 4, evt.evtBuff); + + if(rcode) + continue; + + if((evt.bmStatus & bmHUB_PORT_STATE_CHECK_DISABLED) != bmHUB_PORT_STATE_DISABLED) + continue; + + // Emulate connection event for the port + evt.bmChange |= bmHUB_PORT_STATUS_C_PORT_CONNECTION; + + rcode = PortStatusChange(port, evt); + + if(rcode == HUB_ERROR_PORT_HAS_BEEN_RESET) + return 0; + + if(rcode) + return rcode; + } // for + return 0; +} + +void USBHub::ResetHubPort(uint32_t port) { + HubEvent evt; + evt.bmEvent = 0; + uint8_t rcode; + + ClearPortFeature(HUB_FEATURE_C_PORT_ENABLE, port, 0); + ClearPortFeature(HUB_FEATURE_C_PORT_CONNECTION, port, 0); + SetPortFeature(HUB_FEATURE_PORT_RESET, port, 0); + + + for(int i = 0; i < 3; i++) { + rcode = GetPortStatus(port, 4, evt.evtBuff); + if(rcode) break; // Some kind of error, bail. + if(evt.bmEvent == bmHUB_PORT_EVENT_RESET_COMPLETE || evt.bmEvent == bmHUB_PORT_EVENT_LS_RESET_COMPLETE) { + break; + } + delay(100); // simulate polling. + } + ClearPortFeature(HUB_FEATURE_C_PORT_RESET, port, 0); + ClearPortFeature(HUB_FEATURE_C_PORT_CONNECTION, port, 0); + delay(20); +} + +uint32_t USBHub::PortStatusChange(uint32_t port, HubEvent &evt) { + switch(evt.bmEvent) { + // Device connected event + case bmHUB_PORT_EVENT_CONNECT: + case bmHUB_PORT_EVENT_LS_CONNECT: + if(bResetInitiated) + return 0; + + ClearPortFeature(HUB_FEATURE_C_PORT_ENABLE, port, 0); + ClearPortFeature(HUB_FEATURE_C_PORT_CONNECTION, port, 0); + SetPortFeature(HUB_FEATURE_PORT_RESET, port, 0); + bResetInitiated = true; + return HUB_ERROR_PORT_HAS_BEEN_RESET; + + // Device disconnected event + case bmHUB_PORT_EVENT_DISCONNECT: + ClearPortFeature(HUB_FEATURE_C_PORT_ENABLE, port, 0); + ClearPortFeature(HUB_FEATURE_C_PORT_CONNECTION, port, 0); + bResetInitiated = false; + + UsbDeviceAddress a; + a.devAddress = 0; + a.bmHub = 0; + a.bmParent = bAddress; + a.bmAddress = port; + pUsb->ReleaseDevice(a.devAddress); + return 0; + + // Reset complete event + case bmHUB_PORT_EVENT_RESET_COMPLETE: + case bmHUB_PORT_EVENT_LS_RESET_COMPLETE: + ClearPortFeature(HUB_FEATURE_C_PORT_RESET, port, 0); + ClearPortFeature(HUB_FEATURE_C_PORT_CONNECTION, port, 0); + + delay(20); + + a.devAddress = bAddress; + + pUsb->Configuring(a.bmAddress, port, (evt.bmStatus & bmHUB_PORT_STATUS_PORT_LOW_SPEED)); + bResetInitiated = false; + break; + + } // switch (evt.bmEvent) + return 0; +} + +void PrintHubPortStatus(USBHub *hubptr, uint32_t /* addr */, uint32_t port, uint32_t print_changes) { + uint8_t rcode = 0; + HubEvent evt; + + rcode = hubptr->GetPortStatus(port, 4, evt.evtBuff); + + if(rcode) { + USB_HOST_SERIAL.println("ERROR!"); + return; + } + USB_HOST_SERIAL.print("\r\nPort "); + USB_HOST_SERIAL.println(port, DEC); + + USB_HOST_SERIAL.println("Status"); + USB_HOST_SERIAL.print("CONNECTION:\t"); + USB_HOST_SERIAL.println((evt.bmStatus & bmHUB_PORT_STATUS_PORT_CONNECTION) > 0, DEC); + USB_HOST_SERIAL.print("ENABLE:\t\t"); + USB_HOST_SERIAL.println((evt.bmStatus & bmHUB_PORT_STATUS_PORT_ENABLE) > 0, DEC); + USB_HOST_SERIAL.print("SUSPEND:\t"); + USB_HOST_SERIAL.println((evt.bmStatus & bmHUB_PORT_STATUS_PORT_SUSPEND) > 0, DEC); + USB_HOST_SERIAL.print("OVER_CURRENT:\t"); + USB_HOST_SERIAL.println((evt.bmStatus & bmHUB_PORT_STATUS_PORT_OVER_CURRENT) > 0, DEC); + USB_HOST_SERIAL.print("RESET:\t\t"); + USB_HOST_SERIAL.println((evt.bmStatus & bmHUB_PORT_STATUS_PORT_RESET) > 0, DEC); + USB_HOST_SERIAL.print("POWER:\t\t"); + USB_HOST_SERIAL.println((evt.bmStatus & bmHUB_PORT_STATUS_PORT_POWER) > 0, DEC); + USB_HOST_SERIAL.print("LOW_SPEED:\t"); + USB_HOST_SERIAL.println((evt.bmStatus & bmHUB_PORT_STATUS_PORT_LOW_SPEED) > 0, DEC); + USB_HOST_SERIAL.print("HIGH_SPEED:\t"); + USB_HOST_SERIAL.println((evt.bmStatus & bmHUB_PORT_STATUS_PORT_HIGH_SPEED) > 0, DEC); + USB_HOST_SERIAL.print("TEST:\t\t"); + USB_HOST_SERIAL.println((evt.bmStatus & bmHUB_PORT_STATUS_PORT_TEST) > 0, DEC); + USB_HOST_SERIAL.print("INDICATOR:\t"); + USB_HOST_SERIAL.println((evt.bmStatus & bmHUB_PORT_STATUS_PORT_INDICATOR) > 0, DEC); + + if(!print_changes) + return; + + USB_HOST_SERIAL.println("\r\nChange"); + USB_HOST_SERIAL.print("CONNECTION:\t"); + USB_HOST_SERIAL.println((evt.bmChange & bmHUB_PORT_STATUS_C_PORT_CONNECTION) > 0, DEC); + USB_HOST_SERIAL.print("ENABLE:\t\t"); + USB_HOST_SERIAL.println((evt.bmChange & bmHUB_PORT_STATUS_C_PORT_ENABLE) > 0, DEC); + USB_HOST_SERIAL.print("SUSPEND:\t"); + USB_HOST_SERIAL.println((evt.bmChange & bmHUB_PORT_STATUS_C_PORT_SUSPEND) > 0, DEC); + USB_HOST_SERIAL.print("OVER_CURRENT:\t"); + USB_HOST_SERIAL.println((evt.bmChange & bmHUB_PORT_STATUS_C_PORT_OVER_CURRENT) > 0, DEC); + USB_HOST_SERIAL.print("RESET:\t\t"); + USB_HOST_SERIAL.println((evt.bmChange & bmHUB_PORT_STATUS_C_PORT_RESET) > 0, DEC); +} diff --git a/libraries/USBHost/src/usbhub.h b/libraries/USBHost/src/usbhub.h new file mode 100644 index 0000000..a785f9a --- /dev/null +++ b/libraries/USBHost/src/usbhub.h @@ -0,0 +1,252 @@ +/* Copyright (C) 2011 Circuits At Home, LTD. All rights reserved. + +This software may be distributed and modified under the terms of the GNU +General Public License version 2 (GPL2) as published by the Free Software +Foundation and appearing in the file GPL2.TXT included in the packaging of +this file. Please note that GPL2 Section 2[b] requires that all works based +on this software must also be made publicly available under the terms of +the GPL2 ("Copyleft"). + +Contact information +------------------- + +Circuits At Home, LTD +Web : http://www.circuitsathome.com +e-mail : support@circuitsathome.com + */ +#if !defined(__USBHUB_H__) +#define __USBHUB_H__ + +#include "Usb.h" + +#define USB_DESCRIPTOR_HUB 0x09 // Hub descriptor type + +// Hub Requests +#define bmREQ_CLEAR_HUB_FEATURE USB_SETUP_HOST_TO_DEVICE|USB_SETUP_TYPE_CLASS|USB_SETUP_RECIPIENT_DEVICE +#define bmREQ_CLEAR_PORT_FEATURE USB_SETUP_HOST_TO_DEVICE|USB_SETUP_TYPE_CLASS|USB_SETUP_RECIPIENT_OTHER +#define bmREQ_CLEAR_TT_BUFFER USB_SETUP_HOST_TO_DEVICE|USB_SETUP_TYPE_CLASS|USB_SETUP_RECIPIENT_OTHER +#define bmREQ_GET_HUB_DESCRIPTOR USB_SETUP_DEVICE_TO_HOST|USB_SETUP_TYPE_CLASS|USB_SETUP_RECIPIENT_DEVICE +#define bmREQ_GET_HUB_STATUS USB_SETUP_DEVICE_TO_HOST|USB_SETUP_TYPE_CLASS|USB_SETUP_RECIPIENT_DEVICE +#define bmREQ_GET_PORT_STATUS USB_SETUP_DEVICE_TO_HOST|USB_SETUP_TYPE_CLASS|USB_SETUP_RECIPIENT_OTHER +#define bmREQ_RESET_TT USB_SETUP_HOST_TO_DEVICE|USB_SETUP_TYPE_CLASS|USB_SETUP_RECIPIENT_OTHER +#define bmREQ_SET_HUB_DESCRIPTOR USB_SETUP_HOST_TO_DEVICE|USB_SETUP_TYPE_CLASS|USB_SETUP_RECIPIENT_DEVICE +#define bmREQ_SET_HUB_FEATURE USB_SETUP_HOST_TO_DEVICE|USB_SETUP_TYPE_CLASS|USB_SETUP_RECIPIENT_DEVICE +#define bmREQ_SET_PORT_FEATURE USB_SETUP_HOST_TO_DEVICE|USB_SETUP_TYPE_CLASS|USB_SETUP_RECIPIENT_OTHER +#define bmREQ_GET_TT_STATE USB_SETUP_DEVICE_TO_HOST|USB_SETUP_TYPE_CLASS|USB_SETUP_RECIPIENT_OTHER +#define bmREQ_STOP_TT USB_SETUP_HOST_TO_DEVICE|USB_SETUP_TYPE_CLASS|USB_SETUP_RECIPIENT_OTHER + +// Hub Class Requests +#define HUB_REQUEST_CLEAR_TT_BUFFER 8 +#define HUB_REQUEST_RESET_TT 9 +#define HUB_REQUEST_GET_TT_STATE 10 +#define HUB_REQUEST_STOP_TT 11 + +// Hub Features +#define HUB_FEATURE_C_HUB_LOCAL_POWER 0 +#define HUB_FEATURE_C_HUB_OVER_CURRENT 1 +#define HUB_FEATURE_PORT_CONNECTION 0 +#define HUB_FEATURE_PORT_ENABLE 1 +#define HUB_FEATURE_PORT_SUSPEND 2 +#define HUB_FEATURE_PORT_OVER_CURRENT 3 +#define HUB_FEATURE_PORT_RESET 4 +#define HUB_FEATURE_PORT_POWER 8 +#define HUB_FEATURE_PORT_LOW_SPEED 9 +#define HUB_FEATURE_C_PORT_CONNECTION 16 +#define HUB_FEATURE_C_PORT_ENABLE 17 +#define HUB_FEATURE_C_PORT_SUSPEND 18 +#define HUB_FEATURE_C_PORT_OVER_CURRENT 19 +#define HUB_FEATURE_C_PORT_RESET 20 +#define HUB_FEATURE_PORT_TEST 21 +#define HUB_FEATURE_PORT_INDICATOR 22 + +// Hub Port Test Modes +#define HUB_PORT_TEST_MODE_J 1 +#define HUB_PORT_TEST_MODE_K 2 +#define HUB_PORT_TEST_MODE_SE0_NAK 3 +#define HUB_PORT_TEST_MODE_PACKET 4 +#define HUB_PORT_TEST_MODE_FORCE_ENABLE 5 + +// Hub Port Indicator Color +#define HUB_PORT_INDICATOR_AUTO 0 +#define HUB_PORT_INDICATOR_AMBER 1 +#define HUB_PORT_INDICATOR_GREEN 2 +#define HUB_PORT_INDICATOR_OFF 3 + +// Hub Port Status Bitmasks +#define bmHUB_PORT_STATUS_PORT_CONNECTION 0x0001 +#define bmHUB_PORT_STATUS_PORT_ENABLE 0x0002 +#define bmHUB_PORT_STATUS_PORT_SUSPEND 0x0004 +#define bmHUB_PORT_STATUS_PORT_OVER_CURRENT 0x0008 +#define bmHUB_PORT_STATUS_PORT_RESET 0x0010 +#define bmHUB_PORT_STATUS_PORT_POWER 0x0100 +#define bmHUB_PORT_STATUS_PORT_LOW_SPEED 0x0200 +#define bmHUB_PORT_STATUS_PORT_HIGH_SPEED 0x0400 +#define bmHUB_PORT_STATUS_PORT_TEST 0x0800 +#define bmHUB_PORT_STATUS_PORT_INDICATOR 0x1000 + +// Hub Port Status Change Bitmasks (used one byte instead of two) +#define bmHUB_PORT_STATUS_C_PORT_CONNECTION 0x0001 +#define bmHUB_PORT_STATUS_C_PORT_ENABLE 0x0002 +#define bmHUB_PORT_STATUS_C_PORT_SUSPEND 0x0004 +#define bmHUB_PORT_STATUS_C_PORT_OVER_CURRENT 0x0008 +#define bmHUB_PORT_STATUS_C_PORT_RESET 0x0010 + +// Hub Status Bitmasks (used one byte instead of two) +#define bmHUB_STATUS_LOCAL_POWER_SOURCE 0x01 +#define bmHUB_STATUS_OVER_CURRENT 0x12 + +// Hub Status Change Bitmasks (used one byte instead of two) +#define bmHUB_STATUS_C_LOCAL_POWER_SOURCE 0x01 +#define bmHUB_STATUS_C_OVER_CURRENT 0x12 + + +// Hub Port Configuring Substates +#define USB_STATE_HUB_PORT_CONFIGURING 0xb0 +#define USB_STATE_HUB_PORT_POWERED_OFF 0xb1 +#define USB_STATE_HUB_PORT_WAIT_FOR_POWER_GOOD 0xb2 +#define USB_STATE_HUB_PORT_DISCONNECTED 0xb3 +#define USB_STATE_HUB_PORT_DISABLED 0xb4 +#define USB_STATE_HUB_PORT_RESETTING 0xb5 +#define USB_STATE_HUB_PORT_ENABLED 0xb6 + +// Additional Error Codes +#define HUB_ERROR_PORT_HAS_BEEN_RESET 0xb1 + +// The bit mask to check for all necessary state bits +#define bmHUB_PORT_STATUS_ALL_MAIN ((0UL | bmHUB_PORT_STATUS_C_PORT_CONNECTION | bmHUB_PORT_STATUS_C_PORT_ENABLE | bmHUB_PORT_STATUS_C_PORT_SUSPEND | bmHUB_PORT_STATUS_C_PORT_RESET) << 16) | bmHUB_PORT_STATUS_PORT_POWER | bmHUB_PORT_STATUS_PORT_ENABLE | bmHUB_PORT_STATUS_PORT_CONNECTION | bmHUB_PORT_STATUS_PORT_SUSPEND) + +// Bit mask to check for DISABLED state in HubEvent::bmStatus field +#define bmHUB_PORT_STATE_CHECK_DISABLED (0x0000 | bmHUB_PORT_STATUS_PORT_POWER | bmHUB_PORT_STATUS_PORT_ENABLE | bmHUB_PORT_STATUS_PORT_CONNECTION | bmHUB_PORT_STATUS_PORT_SUSPEND) + +// Hub Port States +#define bmHUB_PORT_STATE_DISABLED (0x0000 | bmHUB_PORT_STATUS_PORT_POWER | bmHUB_PORT_STATUS_PORT_CONNECTION) + +// Hub Port Events +#define bmHUB_PORT_EVENT_CONNECT (((0UL | bmHUB_PORT_STATUS_C_PORT_CONNECTION) << 16) | bmHUB_PORT_STATUS_PORT_POWER | bmHUB_PORT_STATUS_PORT_CONNECTION) +#define bmHUB_PORT_EVENT_DISCONNECT (((0UL | bmHUB_PORT_STATUS_C_PORT_CONNECTION) << 16) | bmHUB_PORT_STATUS_PORT_POWER) +#define bmHUB_PORT_EVENT_RESET_COMPLETE (((0UL | bmHUB_PORT_STATUS_C_PORT_RESET) << 16) | bmHUB_PORT_STATUS_PORT_POWER | bmHUB_PORT_STATUS_PORT_ENABLE | bmHUB_PORT_STATUS_PORT_CONNECTION) + +#define bmHUB_PORT_EVENT_LS_CONNECT (((0UL | bmHUB_PORT_STATUS_C_PORT_CONNECTION) << 16) | bmHUB_PORT_STATUS_PORT_POWER | bmHUB_PORT_STATUS_PORT_CONNECTION | bmHUB_PORT_STATUS_PORT_LOW_SPEED) +#define bmHUB_PORT_EVENT_LS_RESET_COMPLETE (((0UL | bmHUB_PORT_STATUS_C_PORT_RESET) << 16) | bmHUB_PORT_STATUS_PORT_POWER | bmHUB_PORT_STATUS_PORT_ENABLE | bmHUB_PORT_STATUS_PORT_CONNECTION | bmHUB_PORT_STATUS_PORT_LOW_SPEED) +#define bmHUB_PORT_EVENT_LS_PORT_ENABLED (((0UL | bmHUB_PORT_STATUS_C_PORT_CONNECTION | bmHUB_PORT_STATUS_C_PORT_ENABLE) << 16) | bmHUB_PORT_STATUS_PORT_POWER | bmHUB_PORT_STATUS_PORT_ENABLE | bmHUB_PORT_STATUS_PORT_CONNECTION | bmHUB_PORT_STATUS_PORT_LOW_SPEED) + +struct HubDescriptor { + uint32_t bDescLength; // descriptor length + uint32_t bDescriptorType; // descriptor type + uint32_t bNbrPorts; // number of ports a hub equiped with + + struct { + uint32_t LogPwrSwitchMode : 2; + uint32_t CompoundDevice : 1; + uint32_t OverCurrentProtectMode : 2; + uint32_t TTThinkTime : 2; + uint32_t PortIndicatorsSupported : 1; + uint32_t Reserved : 24; + } __attribute__((packed)); + + uint32_t bPwrOn2PwrGood; + uint32_t bHubContrCurrent; +} __attribute__((packed)); + +struct HubEvent { + + union { + + struct { + uint32_t bmStatus; // port status bits + uint32_t bmChange; // port status change bits + } __attribute__((packed)); + uint32_t bmEvent; + uint8_t evtBuff[4]; + }; +} __attribute__((packed)); + +class USBHub : USBDeviceConfig { + static bool bResetInitiated; // True when reset is triggered + + USBHost *pUsb; // USB class instance pointer + + EpInfo epInfo[2]; // interrupt endpoint info structure + + uint32_t bAddress; // address + uint32_t bNbrPorts; // number of ports + // uint8_t bInitState; // initialization state variable + uint32_t qNextPollTime; // next poll time + uint32_t bPollEnable; // poll enable flag + + uint32_t CheckHubStatus(); + uint32_t PortStatusChange(uint32_t port, HubEvent &evt); + +public: + USBHub(USBHost *p); + + uint32_t ClearHubFeature(uint32_t fid); + uint32_t ClearPortFeature(uint32_t fid, uint32_t port, uint32_t sel = 0); + uint32_t GetHubDescriptor(uint32_t index, uint32_t nbytes, uint8_t *dataptr); + uint32_t GetHubStatus(uint32_t nbytes, uint8_t* dataptr); + uint32_t GetPortStatus(uint32_t port, uint32_t nbytes, uint8_t* dataptr); + uint32_t SetHubDescriptor(uint32_t port, uint32_t nbytes, uint8_t* dataptr); + uint32_t SetHubFeature(uint32_t fid); + uint32_t SetPortFeature(uint32_t fid, uint32_t port, uint32_t sel = 0); + + void PrintHubStatus(); + + virtual uint32_t Init(uint32_t parent, uint32_t port, uint32_t lowspeed); + virtual uint32_t Release(); + virtual uint32_t Poll(); + virtual void ResetHubPort(uint32_t port); + + virtual uint32_t GetAddress() { + return bAddress; + }; + + virtual uint32_t DEVCLASSOK(uint32_t klass) { + return (klass == 0x09); + } + +}; + +// Clear Hub Feature + +inline uint32_t USBHub::ClearHubFeature(uint32_t fid) { + return ( pUsb->ctrlReq(bAddress, 0, bmREQ_CLEAR_HUB_FEATURE, USB_REQUEST_CLEAR_FEATURE, fid, 0, 0, 0, 0, NULL, NULL)); +} +// Clear Port Feature + +inline uint32_t USBHub::ClearPortFeature(uint32_t fid, uint32_t port, uint32_t sel) { + return ( pUsb->ctrlReq(bAddress, 0, bmREQ_CLEAR_PORT_FEATURE, USB_REQUEST_CLEAR_FEATURE, fid, 0, ((0x0000 | port) | (sel << 8)), 0, 0, NULL, NULL)); +} +// Get Hub Descriptor + +inline uint32_t USBHub::GetHubDescriptor(uint32_t index, uint32_t nbytes, uint8_t *dataptr) { + return ( pUsb->ctrlReq(bAddress, 0, bmREQ_GET_HUB_DESCRIPTOR, USB_REQUEST_GET_DESCRIPTOR, index, 0x29, 0, nbytes, nbytes, dataptr, NULL)); +} +// Get Hub Status + +inline uint32_t USBHub::GetHubStatus(uint32_t nbytes, uint8_t* dataptr) { + return ( pUsb->ctrlReq(bAddress, 0, bmREQ_GET_HUB_STATUS, USB_REQUEST_GET_STATUS, 0, 0, 0x0000, nbytes, nbytes, dataptr, NULL)); +} +// Get Port Status + +inline uint32_t USBHub::GetPortStatus(uint32_t port, uint32_t nbytes, uint8_t* dataptr) { + return ( pUsb->ctrlReq(bAddress, 0, bmREQ_GET_PORT_STATUS, USB_REQUEST_GET_STATUS, 0, 0, port, nbytes, nbytes, dataptr, NULL)); +} +// Set Hub Descriptor + +inline uint32_t USBHub::SetHubDescriptor(uint32_t port, uint32_t nbytes, uint8_t* dataptr) { + return ( pUsb->ctrlReq(bAddress, 0, bmREQ_SET_HUB_DESCRIPTOR, USB_REQUEST_SET_DESCRIPTOR, 0, 0, port, nbytes, nbytes, dataptr, NULL)); +} +// Set Hub Feature + +inline uint32_t USBHub::SetHubFeature(uint32_t fid) { + return ( pUsb->ctrlReq(bAddress, 0, bmREQ_SET_HUB_FEATURE, USB_REQUEST_SET_FEATURE, fid, 0, 0, 0, 0, NULL, NULL)); +} +// Set Port Feature + +inline uint32_t USBHub::SetPortFeature(uint32_t fid, uint32_t port, uint32_t sel) { + return ( pUsb->ctrlReq(bAddress, 0, bmREQ_SET_PORT_FEATURE, USB_REQUEST_SET_FEATURE, fid, 0, (((0x0000 | sel) << 8) | port), 0, 0, NULL, NULL)); +} + +void PrintHubPortStatus(USBHost *usbptr, uint32_t addr, uint32_t port, uint32_t print_changes = false); + +#endif // __USBHUB_H__ diff --git a/libraries/Wire/Wire.cpp b/libraries/Wire/Wire.cpp new file mode 100644 index 0000000..bae7b9e --- /dev/null +++ b/libraries/Wire/Wire.cpp @@ -0,0 +1,338 @@ +/* + * TWI/I2C library for Arduino Zero + * Copyright (c) 2015 Arduino LLC. All rights 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 + */ + +extern "C" { +#include +} + +#include +#include + +#include "Wire.h" + +using namespace arduino; + +TwoWire::TwoWire(SERCOM * s, uint8_t pinSDA, uint8_t pinSCL) +{ + this->sercom = s; + this->_uc_pinSDA=pinSDA; + this->_uc_pinSCL=pinSCL; + transmissionBegun = false; +} + +void TwoWire::begin(void) { + //Master Mode + sercom->initMasterWIRE(TWI_CLOCK); + sercom->enableWIRE(); + + pinPeripheral(_uc_pinSDA, g_APinDescription[_uc_pinSDA].ulPinType); + pinPeripheral(_uc_pinSCL, g_APinDescription[_uc_pinSCL].ulPinType); +} + +void TwoWire::begin(uint8_t address, bool enableGeneralCall) { + //Slave mode + sercom->initSlaveWIRE(address, enableGeneralCall); + sercom->enableWIRE(); + + pinPeripheral(_uc_pinSDA, g_APinDescription[_uc_pinSDA].ulPinType); + pinPeripheral(_uc_pinSCL, g_APinDescription[_uc_pinSCL].ulPinType); +} + +void TwoWire::setClock(uint32_t baudrate) { + sercom->disableWIRE(); + sercom->initMasterWIRE(baudrate); + sercom->enableWIRE(); +} + +void TwoWire::end() { + sercom->disableWIRE(); +} + +size_t TwoWire::requestFrom(uint8_t address, size_t quantity, bool stopBit) +{ + if(quantity == 0) + { + return 0; + } + + size_t byteRead = 0; + + rxBuffer.clear(); + + if(sercom->startTransmissionWIRE(address, WIRE_READ_FLAG)) + { + // Read first data + rxBuffer.store_char(sercom->readDataWIRE()); + + bool busOwner; + // Connected to slave + for (byteRead = 1; byteRead < quantity && (busOwner = sercom->isBusOwnerWIRE()); ++byteRead) + { + sercom->prepareAckBitWIRE(); // Prepare Acknowledge + sercom->prepareCommandBitsWire(WIRE_MASTER_ACT_READ); // Prepare the ACK command for the slave + rxBuffer.store_char(sercom->readDataWIRE()); // Read data and send the ACK + } + sercom->prepareNackBitWIRE(); // Prepare NACK to stop slave transmission + //sercom->readDataWIRE(); // Clear data register to send NACK + + if (stopBit && busOwner) + { + sercom->prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); // Send Stop unless arbitration was lost + } + + if (!busOwner) + { + byteRead--; // because last read byte was garbage/invalid + } + } + + return byteRead; +} + +size_t TwoWire::requestFrom(uint8_t address, size_t quantity) +{ + return requestFrom(address, quantity, true); +} + +void TwoWire::beginTransmission(uint8_t address) { + // save address of target and clear buffer + txAddress = address; + txBuffer.clear(); + + transmissionBegun = true; +} + +// Errors: +// 0 : Success +// 1 : Data too long +// 2 : NACK on transmit of address +// 3 : NACK on transmit of data +// 4 : Other error +uint8_t TwoWire::endTransmission(bool stopBit) +{ + transmissionBegun = false ; + + // Start I2C transmission + if ( !sercom->startTransmissionWIRE( txAddress, WIRE_WRITE_FLAG ) ) + { + sercom->prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); + return 2 ; // Address error + } + + // Send all buffer + while( txBuffer.available() ) + { + // Trying to send data + if ( !sercom->sendDataMasterWIRE( txBuffer.read_char() ) ) + { + sercom->prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); + return 3 ; // Nack or error + } + } + + if (stopBit) + { + sercom->prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); + } + + return 0; +} + +uint8_t TwoWire::endTransmission() +{ + return endTransmission(true); +} + +size_t TwoWire::write(uint8_t ucData) +{ + // No writing, without begun transmission or a full buffer + if ( !transmissionBegun || txBuffer.isFull() ) + { + return 0 ; + } + + txBuffer.store_char( ucData ) ; + + return 1 ; +} + +size_t TwoWire::write(const uint8_t *data, size_t quantity) +{ + //Try to store all data + for(size_t i = 0; i < quantity; ++i) + { + //Return the number of data stored, when the buffer is full (if write return 0) + if(!write(data[i])) + return i; + } + + //All data stored + return quantity; +} + +int TwoWire::available(void) +{ + return rxBuffer.available(); +} + +int TwoWire::read(void) +{ + return rxBuffer.read_char(); +} + +int TwoWire::peek(void) +{ + return rxBuffer.peek(); +} + +void TwoWire::flush(void) +{ + // Do nothing, use endTransmission(..) to force + // data transfer. +} + +void TwoWire::onReceive(void(*function)(int)) +{ + onReceiveCallback = function; +} + +void TwoWire::onRequest(void(*function)(void)) +{ + onRequestCallback = function; +} + +void TwoWire::onService(void) +{ + if ( sercom->isSlaveWIRE() ) + { + if(sercom->isStopDetectedWIRE() || + (sercom->isAddressMatch() && sercom->isRestartDetectedWIRE() && !sercom->isMasterReadOperationWIRE())) //Stop or Restart detected + { + sercom->prepareAckBitWIRE(); + sercom->prepareCommandBitsWire(0x03); + + //Calling onReceiveCallback, if exists + if(onReceiveCallback) + { + onReceiveCallback(available()); + } + + rxBuffer.clear(); + } + else if(sercom->isAddressMatch()) //Address Match + { + sercom->prepareAckBitWIRE(); + sercom->prepareCommandBitsWire(0x03); + + if(sercom->isMasterReadOperationWIRE()) //Is a request ? + { + txBuffer.clear(); + + transmissionBegun = true; + + //Calling onRequestCallback, if exists + if(onRequestCallback) + { + onRequestCallback(); + } + } + } + else if(sercom->isDataReadyWIRE()) + { + if (sercom->isMasterReadOperationWIRE()) + { + uint8_t c = 0xff; + + if( txBuffer.available() ) { + c = txBuffer.read_char(); + } + + transmissionBegun = sercom->sendDataSlaveWIRE(c); + } else { //Received data + if (rxBuffer.isFull()) { + sercom->prepareNackBitWIRE(); + } else { + //Store data + rxBuffer.store_char(sercom->readDataWIRE()); + + sercom->prepareAckBitWIRE(); + } + + sercom->prepareCommandBitsWire(0x03); + } + } + } +} + +#if WIRE_INTERFACES_COUNT > 0 + /* In case new variant doesn't define these macros, + * we put here the ones for Arduino Zero. + * + * These values should be different on some variants! + */ + #ifndef PERIPH_WIRE + #define PERIPH_WIRE sercom3 + #define WIRE_IT_HANDLER SERCOM3_Handler + #endif // PERIPH_WIRE + arduino::TwoWire Wire(&PERIPH_WIRE, PIN_WIRE_SDA, PIN_WIRE_SCL); + + void WIRE_IT_HANDLER(void) { + Wire.onService(); + } +#endif + +#if WIRE_INTERFACES_COUNT > 1 + arduino::TwoWire Wire1(&PERIPH_WIRE1, PIN_WIRE1_SDA, PIN_WIRE1_SCL); + + void WIRE1_IT_HANDLER(void) { + Wire1.onService(); + } +#endif + +#if WIRE_INTERFACES_COUNT > 2 + arduino::TwoWire Wire2(&PERIPH_WIRE2, PIN_WIRE2_SDA, PIN_WIRE2_SCL); + + void WIRE2_IT_HANDLER(void) { + Wire2.onService(); + } +#endif + +#if WIRE_INTERFACES_COUNT > 3 + arduino::TwoWire Wire3(&PERIPH_WIRE3, PIN_WIRE3_SDA, PIN_WIRE3_SCL); + + void WIRE3_IT_HANDLER(void) { + Wire3.onService(); + } +#endif + +#if WIRE_INTERFACES_COUNT > 4 + arduino::TwoWire Wire4(&PERIPH_WIRE4, PIN_WIRE4_SDA, PIN_WIRE4_SCL); + + void WIRE4_IT_HANDLER(void) { + Wire4.onService(); + } +#endif + +#if WIRE_INTERFACES_COUNT > 5 + arduino::TwoWire Wire5(&PERIPH_WIRE5, PIN_WIRE5_SDA, PIN_WIRE5_SCL); + + void WIRE5_IT_HANDLER(void) { + Wire5.onService(); + } +#endif diff --git a/libraries/Wire/Wire.h b/libraries/Wire/Wire.h new file mode 100644 index 0000000..aea241b --- /dev/null +++ b/libraries/Wire/Wire.h @@ -0,0 +1,112 @@ +/* + * TWI/I2C library for Arduino Zero + * Copyright (c) 2015 Arduino LLC. All rights 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 TwoWire_h +#define TwoWire_h + +#include "api/HardwareI2C.h" +#include "variant.h" +#include "SERCOM.h" + + // WIRE_HAS_END means Wire has end() +#define WIRE_HAS_END 1 + +namespace arduino { + +class TwoWire : public HardwareI2C +{ + public: + TwoWire(SERCOM *s, uint8_t pinSDA, uint8_t pinSCL); + void begin(); + void begin(uint8_t address, bool enableGeneralCall); + void begin(uint8_t address) { + begin(address, false); + } + void end(); + void setClock(uint32_t); + + void beginTransmission(uint8_t); + uint8_t endTransmission(bool stopBit); + uint8_t endTransmission(void); + + size_t requestFrom(uint8_t address, size_t quantity, bool stopBit); + size_t requestFrom(uint8_t address, size_t quantity); + + size_t write(uint8_t data); + size_t write(const uint8_t * data, size_t quantity); + + virtual int available(void); + virtual int read(void); + virtual int peek(void); + virtual void flush(void); + void onReceive(void(*)(int)); + void onRequest(void(*)(void)); + + inline size_t write(unsigned long n) { return write((uint8_t)n); } + inline size_t write(long n) { return write((uint8_t)n); } + inline size_t write(unsigned int n) { return write((uint8_t)n); } + inline size_t write(int n) { return write((uint8_t)n); } + using Print::write; + + void onService(void); + + private: + SERCOM * sercom; + uint8_t _uc_pinSDA; + uint8_t _uc_pinSCL; + + bool transmissionBegun; + + // RX Buffer + arduino::RingBufferN<256> rxBuffer; + + //TX buffer + arduino::RingBufferN<256> txBuffer; + uint8_t txAddress; + + // Callback user functions + void (*onRequestCallback)(void); + void (*onReceiveCallback)(int); + + // TWI clock frequency + static const uint32_t TWI_CLOCK = 100000; +}; + +} + +#if WIRE_INTERFACES_COUNT > 0 + extern arduino::TwoWire Wire; +#endif +#if WIRE_INTERFACES_COUNT > 1 + extern arduino::TwoWire Wire1; +#endif +#if WIRE_INTERFACES_COUNT > 2 + extern arduino::TwoWire Wire2; +#endif +#if WIRE_INTERFACES_COUNT > 3 + extern arduino::TwoWire Wire3; +#endif +#if WIRE_INTERFACES_COUNT > 4 + extern arduino::TwoWire Wire4; +#endif +#if WIRE_INTERFACES_COUNT > 5 + extern arduino::TwoWire Wire5; +#endif + +#endif diff --git a/libraries/Wire/examples/SFRRanger_reader/SFRRanger_reader.ino b/libraries/Wire/examples/SFRRanger_reader/SFRRanger_reader.ino new file mode 100644 index 0000000..9c41c18 --- /dev/null +++ b/libraries/Wire/examples/SFRRanger_reader/SFRRanger_reader.ino @@ -0,0 +1,87 @@ +// I2C SRF10 or SRF08 Devantech Ultrasonic Ranger Finder +// by Nicholas Zambetti +// and James Tichenor + +// Demonstrates use of the Wire library reading data from the +// Devantech Utrasonic Rangers SFR08 and SFR10 + +// Created 29 April 2006 + +// This example code is in the public domain. + + +#include + +void setup() +{ + Wire.begin(); // join i2c bus (address optional for master) + Serial.begin(9600); // start serial communication at 9600bps +} + +int reading = 0; + +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 + 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 + // use 0x52 for ping microseconds + Wire.endTransmission(); // stop transmitting + + // step 2: wait for readings to happen + delay(70); // datasheet suggests at least 65 milliseconds + + // step 3: instruct sensor to return a particular echo reading + Wire.beginTransmission(112); // transmit to device #112 + Wire.write(byte(0x02)); // sets register pointer to echo #1 register (0x02) + Wire.endTransmission(); // stop transmitting + + // step 4: request reading from sensor + Wire.requestFrom(112, 2); // request 2 bytes from slave device #112 + + // step 5: receive reading from sensor + if(2 <= Wire.available()) // if two bytes were received + { + reading = Wire.read(); // receive high byte (overwrites previous reading) + reading = reading << 8; // shift high byte to be high 8 bits + reading |= Wire.read(); // receive low byte as lower 8 bits + Serial.println(reading); // print the reading + } + + delay(250); // wait a bit since people have to read the output :) +} + + +/* + +// The following code changes the address of a Devantech Ultrasonic Range Finder (SRF10 or SRF08) +// usage: changeAddress(0x70, 0xE6); + +void changeAddress(byte oldAddress, byte newAddress) +{ + Wire.beginTransmission(oldAddress); + Wire.write(byte(0x00)); + Wire.write(byte(0xA0)); + Wire.endTransmission(); + + Wire.beginTransmission(oldAddress); + Wire.write(byte(0x00)); + Wire.write(byte(0xAA)); + Wire.endTransmission(); + + Wire.beginTransmission(oldAddress); + Wire.write(byte(0x00)); + Wire.write(byte(0xA5)); + Wire.endTransmission(); + + Wire.beginTransmission(oldAddress); + Wire.write(byte(0x00)); + Wire.write(newAddress); + Wire.endTransmission(); +} + +*/ diff --git a/libraries/Wire/examples/digital_potentiometer/digital_potentiometer.ino b/libraries/Wire/examples/digital_potentiometer/digital_potentiometer.ino new file mode 100644 index 0000000..38da1c5 --- /dev/null +++ b/libraries/Wire/examples/digital_potentiometer/digital_potentiometer.ino @@ -0,0 +1,39 @@ +// I2C Digital Potentiometer +// by Nicholas Zambetti +// and Shawn Bonkowski + +// Demonstrates use of the Wire library +// Controls AD5171 digital potentiometer via I2C/TWI + +// Created 31 March 2006 + +// This example code is in the public domain. + +// This example code is in the public domain. + + +#include + +void setup() +{ + Wire.begin(); // join i2c bus (address optional for master) +} + +byte val = 0; + +void loop() +{ + Wire.beginTransmission(44); // transmit to device #44 (0x2c) + // device address is specified in datasheet + Wire.write(byte(0x00)); // sends instruction byte + Wire.write(val); // sends potentiometer value byte + Wire.endTransmission(); // stop transmitting + + val++; // increment value + if(val == 64) // if reached 64th position (max) + { + val = 0; // start over from lowest value + } + delay(500); +} + diff --git a/libraries/Wire/examples/master_reader/master_reader.ino b/libraries/Wire/examples/master_reader/master_reader.ino new file mode 100644 index 0000000..4124d7d --- /dev/null +++ b/libraries/Wire/examples/master_reader/master_reader.ino @@ -0,0 +1,32 @@ +// Wire Master Reader +// by Nicholas Zambetti + +// Demonstrates use of the Wire library +// Reads data from an I2C/TWI slave device +// Refer to the "Wire Slave Sender" example for use with this + +// Created 29 March 2006 + +// This example code is in the public domain. + + +#include + +void setup() +{ + Wire.begin(); // join i2c bus (address optional for master) + Serial.begin(9600); // start serial for output +} + +void loop() +{ + Wire.requestFrom(2, 6); // request 6 bytes from slave device #2 + + while(Wire.available()) // slave may send less than requested + { + char c = Wire.read(); // receive a byte as character + Serial.print(c); // print the character + } + + delay(500); +} diff --git a/libraries/Wire/examples/master_writer/master_writer.ino b/libraries/Wire/examples/master_writer/master_writer.ino new file mode 100644 index 0000000..ccaa036 --- /dev/null +++ b/libraries/Wire/examples/master_writer/master_writer.ino @@ -0,0 +1,31 @@ +// Wire Master Writer +// by Nicholas Zambetti + +// Demonstrates use of the Wire library +// Writes data to an I2C/TWI slave device +// Refer to the "Wire Slave Receiver" example for use with this + +// Created 29 March 2006 + +// This example code is in the public domain. + + +#include + +void setup() +{ + Wire.begin(); // join i2c bus (address optional for master) +} + +byte x = 0; + +void loop() +{ + Wire.beginTransmission(4); // transmit to device #4 + Wire.write("x is "); // sends five bytes + Wire.write(x); // sends one byte + Wire.endTransmission(); // stop transmitting + + x++; + delay(500); +} diff --git a/libraries/Wire/examples/slave_receiver/slave_receiver.ino b/libraries/Wire/examples/slave_receiver/slave_receiver.ino new file mode 100644 index 0000000..60dd4bd --- /dev/null +++ b/libraries/Wire/examples/slave_receiver/slave_receiver.ino @@ -0,0 +1,38 @@ +// Wire Slave Receiver +// by Nicholas Zambetti + +// Demonstrates use of the Wire library +// Receives data as an I2C/TWI slave device +// Refer to the "Wire Master Writer" example for use with this + +// Created 29 March 2006 + +// This example code is in the public domain. + + +#include + +void setup() +{ + Wire.begin(4); // join i2c bus with address #4 + Wire.onReceive(receiveEvent); // register event + Serial.begin(9600); // start serial for output +} + +void loop() +{ + delay(100); +} + +// function that executes whenever data is received from master +// this function is registered as an event, see setup() +void receiveEvent(int howMany) +{ + while(1 < Wire.available()) // loop through all but the last + { + char c = Wire.read(); // receive byte as a character + Serial.print(c); // print the character + } + int x = Wire.read(); // receive byte as an integer + Serial.println(x); // print the integer +} diff --git a/libraries/Wire/examples/slave_sender/slave_sender.ino b/libraries/Wire/examples/slave_sender/slave_sender.ino new file mode 100644 index 0000000..d3b238a --- /dev/null +++ b/libraries/Wire/examples/slave_sender/slave_sender.ino @@ -0,0 +1,32 @@ +// Wire Slave Sender +// by Nicholas Zambetti + +// Demonstrates use of the Wire library +// Sends data as an I2C/TWI slave device +// Refer to the "Wire Master Reader" example for use with this + +// Created 29 March 2006 + +// This example code is in the public domain. + + +#include + +void setup() +{ + Wire.begin(2); // join i2c bus with address #2 + Wire.onRequest(requestEvent); // register event +} + +void loop() +{ + delay(100); +} + +// function that executes whenever data is requested by master +// this function is registered as an event, see setup() +void requestEvent() +{ + Wire.write("hello "); // respond with message of 6 bytes + // as expected by master +} diff --git a/libraries/Wire/keywords.txt b/libraries/Wire/keywords.txt new file mode 100644 index 0000000..ba5a18d --- /dev/null +++ b/libraries/Wire/keywords.txt @@ -0,0 +1,26 @@ +####################################### +# Syntax Coloring Map For Wire +####################################### + +####################################### +# Datatypes (KEYWORD1) +####################################### + +Wire KEYWORD2 +Wire1 KEYWORD2 + +####################################### +# Methods and Functions (KEYWORD2) +####################################### + +begin KEYWORD2 +beginTransmission KEYWORD2 +endTransmission KEYWORD2 +requestFrom KEYWORD2 +onReceive KEYWORD2 +onRequest KEYWORD2 + +####################################### +# Constants (LITERAL1) +####################################### + diff --git a/libraries/Wire/library.properties b/libraries/Wire/library.properties new file mode 100644 index 0000000..d5b44ea --- /dev/null +++ b/libraries/Wire/library.properties @@ -0,0 +1,9 @@ +name=Wire +version=1.0 +author=Jonathan BAUDIN, Thibaut VIARD, Arduino +maintainer=Arduino +sentence=Allows the communication between devices or sensors connected via Two Wire Interface Bus. Specific implementation for Arduino Zero. +paragraph= +category=Communication +url=http://www.arduino.cc/en/Reference/Wire +architectures=samd diff --git a/platform.txt b/platform.txt index a1c150a..301bc3a 100644 --- a/platform.txt +++ b/platform.txt @@ -20,7 +20,7 @@ # https://github.com/arduino/Arduino/wiki/Arduino-IDE-1.5---3rd-party-Hardware-specification name=Mysensors SAMD (32-bits ARM Cortex-M0+) Boards -version=1.0.7 +version=1.1.0 # Compile variables # ----------------- diff --git a/post_install.bat b/post_install.bat new file mode 100644 index 0000000..73b9a24 --- /dev/null +++ b/post_install.bat @@ -0,0 +1,28 @@ +@echo off +set ARGS=/SE /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% +) + +@echo off +setlocal +for /f "tokens=4-5 delims=[.] " %%i in ('ver') do @(if %%i==Version (set VERSION=%%j) else (set VERSION=%%i)) +if %VERSION% GEQ 10 ( + exit /b 0 +) +endlocal + +REM dpinst /PATH has problems with relative paths, so use absolute path. +if "%PROCESSOR_ARCHITECTURE%" == "AMD64" ( + drivers\dpinst-amd64.exe /PATH %cd%\drivers\prewin10 %ARGS% +) ELSE IF "%PROCESSOR_ARCHITEW6432%" == "AMD64" ( + drivers\dpinst-amd64.exe /PATH %cd%\drivers\prewin10 %ARGS% +) ELSE ( + drivers\dpinst-x86.exe /PATH %cd%\drivers\prewin10 %ARGS% +) + +exit /b 0 diff --git a/programmers.txt b/programmers.txt new file mode 100644 index 0000000..20318a8 --- /dev/null +++ b/programmers.txt @@ -0,0 +1,46 @@ +# Copyright (c) 2014-2015 Arduino LLC. 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 + +edbg.name=Atmel EDBG +edbg.communication=USB +edbg.protocol=cmsis-dap.cfg +edbg.program.tool=openocd +edbg.program.tool.default=openocd +edbg.program.extra_params= +edbg.extra_params= + +atmel_ice.name=Atmel-ICE +atmel_ice.communication=USB +atmel_ice.protocol=cmsis-dap.cfg +atmel_ice.program.tool=openocd +atmel_ice.program.tool.default=openocd +atmel_ice.program.extra_params= +atmel_ice.extra_params= + +sam_ice.name=Atmel SAM-ICE +sam_ice.communication=USB +sam_ice.protocol=cmsis-dap.cfg +sam_ice.program.tool=openocd +sam_ice.program.tool.default=openocd +sam_ice.program.extra_params= +sam_ice.extra_params= + +jlink.name=Segger J-Link +jlink.communication=USB +jlink.protocol=jlink.cfg +jlink.program.tool=openocd +jlink.program.tool.default=openocd +jlink.extra_params=-c "transport select swd" diff --git a/variants/arduino_mzero/debug_scripts/variant.gdb b/variants/arduino_mzero/debug_scripts/variant.gdb new file mode 100755 index 0000000..3c37ffd --- /dev/null +++ b/variants/arduino_mzero/debug_scripts/variant.gdb @@ -0,0 +1,31 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +# Define 'reset' command +define reset + +info reg + +break main + +# End of 'reset' command +end + +target remote | openocd -c "interface cmsis-dap" -c "set CHIPNAME at91samd21g18" -f target/at91samdXX.cfg -c "gdb_port pipe; log_output openocd.log" diff --git a/variants/arduino_mzero/linker_scripts/gcc/flash_with_bootloader.ld b/variants/arduino_mzero/linker_scripts/gcc/flash_with_bootloader.ld new file mode 100755 index 0000000..b51e564 --- /dev/null +++ b/variants/arduino_mzero/linker_scripts/gcc/flash_with_bootloader.ld @@ -0,0 +1,198 @@ +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000+0x4000, LENGTH = 0x00040000-0x4000 + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.sketch_boot)) + + . = ALIGN(0x4000); + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(4); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM); + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/arduino_mzero/linker_scripts/gcc/flash_without_bootloader.ld b/variants/arduino_mzero/linker_scripts/gcc/flash_without_bootloader.ld new file mode 100755 index 0000000..bbb0931 --- /dev/null +++ b/variants/arduino_mzero/linker_scripts/gcc/flash_without_bootloader.ld @@ -0,0 +1,195 @@ +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 0x00040000 + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(4); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM) ; + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/arduino_mzero/openocd_scripts/arduino_zero.cfg b/variants/arduino_mzero/openocd_scripts/arduino_zero.cfg new file mode 100755 index 0000000..36c65c3 --- /dev/null +++ b/variants/arduino_mzero/openocd_scripts/arduino_zero.cfg @@ -0,0 +1,30 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +source [find interface/cmsis-dap.cfg] + +# chip name +set CHIPNAME at91samd21g18 +set ENDIAN little + +# choose a port here +set telnet_port 0 + +source [find target/at91samdXX.cfg] diff --git a/variants/arduino_mzero/pins_arduino.h b/variants/arduino_mzero/pins_arduino.h new file mode 100755 index 0000000..db0e40c --- /dev/null +++ b/variants/arduino_mzero/pins_arduino.h @@ -0,0 +1,21 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +// API compatibility +#include "variant.h" + diff --git a/variants/arduino_mzero/variant.cpp b/variants/arduino_mzero/variant.cpp new file mode 100644 index 0000000..e7adf35 --- /dev/null +++ b/variants/arduino_mzero/variant.cpp @@ -0,0 +1,223 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ +/* + * + * + Pin number + ZERO Board pin | PIN | Label/Name | Comments (* is for default peripheral in use) + * +------------+------------------+--------+-----------------+------------------------------ + * | | Digital Low | | | + * +------------+------------------+--------+-----------------+------------------------------ + * | 0 | 0 -> RX | PA11 | | EIC/EXTINT[11] ADC/AIN[19] PTC/X[3] *SERCOM0/PAD[3] SERCOM2/PAD[3] TCC1/WO[1] TCC0/WO[3] + * | 1 | 1 <- TX | PA10 | | EIC/EXTINT[10] ADC/AIN[18] PTC/X[2] *SERCOM0/PAD[2] TCC1/WO[0] TCC0/WO[2] + * | 2 | ~2 | PA08 | | EIC/NMI ADC/AIN[16] PTC/X[0] SERCOM0/PAD[0] SERCOM2/PAD[0] *TCC0/WO[0] TCC1/WO[2] + * | 3 | ~3 | PA09 | | EIC/EXTINT[9] ADC/AIN[17] PTC/X[1] SERCOM0/PAD[1] SERCOM2/PAD[1] *TCC0/WO[1] TCC1/WO[3] + * | 4 | ~4 | PA14 | | EIC/EXTINT[14] SERCOM2/PAD[2] SERCOM4/PAD[2] TC3/WO[0] *TCC0/WO[4] + * | 5 | ~5 | PA15 | | EIC/EXTINT[15] SERCOM2/PAD[3] SERCOM4/PAD[3] TC3/WO[1] *TCC0/WO[5] + * | 6 | ~6 | PA20 | | EIC/EXTINT[4] PTC/X[8] SERCOM5/PAD[2] SERCOM3/PAD[2] TC7/WO[0] *TCC0/WO[6] + * | 7 | ~7 | PA21 | | EIC/EXTINT[5] PTC/X[9] SERCOM5/PAD[3] SERCOM3/PAD[3] TC7/WO[1] *TCC0/WO[7] + * +------------+------------------+--------+-----------------+------------------------------ + * | | Digital High | | | + * +------------+------------------+--------+-----------------+------------------------------ + * | 8 | ~8 | PA06 | | EIC/EXTINT[6] PTC/Y[4] ADC/AIN[6] AC/AIN[2] SERCOM0/PAD[2] *TCC1/WO[0] + * | 9 | ~9 | PA07 | | EIC/EXTINT[7] PTC/Y[5] DC/AIN[7] AC/AIN[3] SERCOM0/PAD[3] *TCC1/WO[1] + * | 10 | ~10 | PA18 | | EIC/EXTINT[2] PTC/X[6] SERCOM1/PAD[2] SERCOM3/PAD[2] *TC3/WO[0] TCC0/WO[2] + * | 11 | ~11 | PA16 | | EIC/EXTINT[0] PTC/X[4] SERCOM1/PAD[0] SERCOM3/PAD[0] *TCC2/WO[0] TCC0/WO[6] + * | 12 | ~12 | PA19 | | EIC/EXTINT[3] PTC/X[7] SERCOM1/PAD[3] SERCOM3/PAD[3] *TC3/WO[1] TCC0/WO[3] + * | 13 | ~13 | PA17 | LED | EIC/EXTINT[1] PTC/X[5] SERCOM1/PAD[1] SERCOM3/PAD[1] *TCC2/WO[1] TCC0/WO[7] + * | 14 | GND | | | + * | 15 | AREF | PA03 | | *DAC/VREFP PTC/Y[1] + * | 16 | SDA | PA22 | | EIC/EXTINT[6] PTC/X[10] *SERCOM3/PAD[0] SERCOM5/PAD[0] TC4/WO[0] TCC0/WO[4] + * | 17 | SCL | PA23 | | EIC/EXTINT[7] PTC/X[11] *SERCOM3/PAD[1] SERCOM5/PAD[1] TC4/WO[1] TCC0/WO[5] + * +------------+------------------+--------+-----------------+------------------------------ + * | |SPI (Legacy ICSP) | | | + * +------------+------------------+--------+-----------------+------------------------------ + * | 18 | 1 | PA12 | MISO | EIC/EXTINT[12] SERCOM2/PAD[0] *SERCOM4/PAD[0] TCC2/WO[0] TCC0/WO[6] + * | 19 | 2 | | 5V0 | + * | 20 | 3 | PB11 | SCK | EIC/EXTINT[11] *SERCOM4/PAD[3] TC5/WO[1] TCC0/WO[5] + * | 21 | 4 | PB10 | MOSI | EIC/EXTINT[10] *SERCOM4/PAD[2] TC5/WO[0] TCC0/WO[4] + * | 22 | 5 | | RESET | + * | 23 | 6 | | GND | + * +------------+------------------+--------+-----------------+------------------------------ + * | | Analog Connector | | | + * +------------+------------------+--------+-----------------+------------------------------ + * | 24 | A0 | PA02 | | EIC/EXTINT[2] *ADC/AIN[0] PTC/Y[0] DAC/VOUT + * | 25 | A1 | PB08 | | EIC/EXTINT[8] *ADC/AIN[2] PTC/Y[14] SERCOM4/PAD[0] TC4/WO[0] + * | 26 | A2 | PB09 | | EIC/EXTINT[9] *ADC/AIN[3] PTC/Y[15] SERCOM4/PAD[1] TC4/WO[1] + * | 27 | A3 | PA04 | | EIC/EXTINT[4] *ADC/AIN[4] AC/AIN[0] PTC/Y[2] SERCOM0/PAD[0] TCC0/WO[0] + * | 28 | A4 | PA05 | | EIC/EXTINT[5] *ADC/AIN[5] AC/AIN[1] PTC/Y[5] SERCOM0/PAD[1] TCC0/WO[1] + * | 29 | A5 | PB02 | | EIC/EXTINT[2] *ADC/AIN[10] PTC/Y[8] SERCOM5/PAD[0] TC6/WO[0] + * +------------+------------------+--------+-----------------+------------------------------ + * | | LEDs | | | + * +------------+------------------+--------+-----------------+------------------------------ + * | 30 | | PB03 | RX | + * | 31 | | PA27 | TX | + * +------------+------------------+--------+-----------------+------------------------------ + * | | USB | | | + * +------------+------------------+--------+-----------------+------------------------------ + * | 32 | | PA28 | USB HOST ENABLE | + * | 33 | | PA24 | USB_NEGATIVE | USB/DM + * | 34 | | PA25 | USB_POSITIVE | USB/DP + * +------------+------------------+--------+-----------------+------------------------------ + * | | EDBG | | | + * +------------+------------------+--------+-----------------+------------------------------ + * | 35 | | PB22 | EDBG_UART TX | SERCOM5/PAD[2] + * | 36 | | PB23 | EDBG_UART RX | SERCOM5/PAD[3] + * +------------+------------------+--------+-----------------+------------------------------ + * | 37 | | PA22 | EDBG_SDA | SERCOM3/PAD[0] + * | 38 | | PA23 | EDBG_SCL | SERCOM3/PAD[1] + * +------------+------------------+--------+-----------------+------------------------------ + * | 39 | | PA19 | EDBG_MISO | SERCOM1/PAD[3] + * | 40 | | PA16 | EDBG_MOSI | SERCOM1/PAD[0] + * | 41 | | PA18 | EDBG_SS | SERCOM1/PAD[2] + * | 42 | | PA17 | EDBG_SCK | SERCOM1/PAD[1] + * +------------+------------------+--------+-----------------+------------------------------ + * | 43 | | PA13 | EDBG_GPIO0 | EIC/EXTINT[13] *TCC2/WO[1] TCC0/WO[7] + * | 44 | | PA21 | EDBG_GPIO1 | Pin 7 + * | 45 | | PA06 | EDBG_GPIO2 | Pin 8 + * | 46 | | PA07 | EDBG_GPIO3 | Pin 9 + * +------------+------------------+--------+-----------------+------------------------------ + * | |32.768KHz Crystal | | | + * +------------+------------------+--------+-----------------+------------------------------ + * | | | PA00 | XIN32 | EXTINT[0] SERCOM1/PAD[0] TCC2/WO[0] + * | | | PA01 | XOUT32 | EXTINT[1] SERCOM1/PAD[1] TCC2/WO[1] + * +------------+------------------+--------+-----------------+------------------------------ + */ + + +#include "variant.h" + +/* + * Pins descriptions + */ +const PinDescription g_APinDescription[]= +{ + // 0 .. 19 - Digital pins + // ---------------------- + // 0/1 - SERCOM/UART (Serial1) + { PORTA, 11, PIO_SERCOM, PIN_ATTR_DIGITAL, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_11 }, // RX: SERCOM0/PAD[3] + { PORTA, 10, PIO_SERCOM, PIN_ATTR_DIGITAL, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_10 }, // TX: SERCOM0/PAD[2] + + // 2..12 + { PORTA, 8, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM0_CH0, TCC0_CH0, EXTERNAL_INT_NONE }, // EXTERNAL_INT_NMI }, // TCC0/WO[0] + { PORTA, 9, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM0_CH1, TCC0_CH1, EXTERNAL_INT_9 }, // TCC0/WO[1] + { PORTA, 14, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM3_CH0, TC3_CH0, EXTERNAL_INT_14 }, // TC3/WO[0] + { PORTA, 15, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM3_CH1, TC3_CH1, EXTERNAL_INT_15 }, // TC3/WO[1] + { PORTA, 20, PIO_TIMER_ALT, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH6, TCC0_CH6, EXTERNAL_INT_4 }, // TCC0/WO[6] + { PORTA, 21, PIO_TIMER_ALT, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH7, TCC0_CH7, EXTERNAL_INT_5 }, // TCC0/WO[7] + { PORTA, 6, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM1_CH0, TCC1_CH0, EXTERNAL_INT_6 }, // TCC1/WO[0] + { PORTA, 7, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM1_CH1, TCC1_CH1, EXTERNAL_INT_7 }, // TCC1/WO[1] + { PORTA, 18, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM3_CH0, TC3_CH0, EXTERNAL_INT_2 }, // TC3/WO[0] + { PORTA, 16, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM2_CH0, TCC2_CH0, EXTERNAL_INT_0 }, // TCC2/WO[0] + { PORTA, 19, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM3_CH1, TC3_CH1, EXTERNAL_INT_3 }, // TC3/WO[1] + + // 13 (LED) + { PORTA, 17, PIO_PWM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM2_CH1, TCC2_CH1, EXTERNAL_INT_1 }, // TCC2/WO[1] + + // 14 (GND) + { NOT_A_PORT, 0, PIO_NOT_A_PIN, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + + // 15 (AREF) + { PORTA, 3, PIO_ANALOG, PIN_ATTR_ANALOG, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // DAC/VREFP + + // 16..17 I2C pins (SDA/SCL and also EDBG:SDA/SCL) + // ---------------------- + { PORTA, 22, PIO_SERCOM, PIN_ATTR_DIGITAL, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_6 }, // SDA: SERCOM3/PAD[0] + { PORTA, 23, PIO_SERCOM, PIN_ATTR_DIGITAL, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_7 }, // SCL: SERCOM3/PAD[1] + + // 18..23 - SPI pins (ICSP:MISO,SCK,MOSI) + // ---------------------- + { PORTA, 12, PIO_SERCOM_ALT, PIN_ATTR_DIGITAL, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_12 }, // MISO: SERCOM4/PAD[0] + { NOT_A_PORT, 0, PIO_NOT_A_PIN, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // 5V0 + { PORTB, 11, PIO_SERCOM_ALT, PIN_ATTR_DIGITAL, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_11 }, // SCK: SERCOM4/PAD[3] + { PORTB, 10, PIO_SERCOM_ALT, PIN_ATTR_DIGITAL, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_10 }, // MOSI: SERCOM4/PAD[2] + { NOT_A_PORT, 0, PIO_NOT_A_PIN, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // RESET + { NOT_A_PORT, 0, PIO_NOT_A_PIN, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // GND + + // 24..29 - Analog pins + // -------------------- + { PORTA, 2, PIO_ANALOG, PIN_ATTR_ANALOG, ADC_Channel0, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_2 }, // ADC/AIN[0] + { PORTB, 8, PIO_ANALOG, PIN_ATTR_ANALOG, ADC_Channel2, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_8 }, // ADC/AIN[2] + { PORTB, 9, PIO_ANALOG, PIN_ATTR_ANALOG, ADC_Channel3, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_9 }, // ADC/AIN[3] + { PORTA, 4, PIO_ANALOG, PIN_ATTR_ANALOG, ADC_Channel4, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_4 }, // ADC/AIN[4] + { PORTA, 5, PIO_ANALOG, PIN_ATTR_ANALOG, ADC_Channel5, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_5 }, // ADC/AIN[5] + { PORTB, 2, PIO_ANALOG, PIN_ATTR_ANALOG, ADC_Channel10, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_2 }, // ADC/AIN[10] + + // 30..31 - RX/TX LEDS (PB03/PA27) + // -------------------- + { PORTB, 3, PIO_OUTPUT, PIN_ATTR_DIGITAL, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // used as output only + { PORTA, 27, PIO_OUTPUT, PIN_ATTR_DIGITAL, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // used as output only + + // 32..34 - USB + // -------------------- + { PORTA, 28, PIO_COM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB Host enable + { PORTA, 24, PIO_COM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DM + { PORTA, 25, PIO_COM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DP + + // 35 .. 46 - EDBG + // ---------------------- + // 35/36 - EDBG/UART + { PORTB, 22, PIO_SERCOM_ALT, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // TX: SERCOM5/PAD[2] + { PORTB, 23, PIO_SERCOM_ALT, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // RX: SERCOM5/PAD[3] + + // 37/38 I2C (SDA/SCL and also EDBG:SDA/SCL) + { PORTA, 22, PIO_SERCOM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SDA: SERCOM3/PAD[0] + { PORTA, 23, PIO_SERCOM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCL: SERCOM3/PAD[1] + + // 39 .. 42 - EDBG/SPI + { PORTA, 19, PIO_SERCOM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MISO: SERCOM1/PAD[3] + { PORTA, 16, PIO_SERCOM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MOSI: SERCOM1/PAD[0] + { PORTA, 18, PIO_SERCOM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SS: SERCOM1/PAD[2] + { PORTA, 17, PIO_SERCOM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCK: SERCOM1/PAD[1] + + // 43 .. 46 - EDBG/Digital + { PORTA, 13, PIO_PWM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM), No_ADC_Channel, PWM0_CH5, NOT_ON_TIMER, EXTERNAL_INT_13 }, // EIC/EXTINT[13] *TCC2/WO[1] TCC0/WO[7] + { PORTA, 21, PIO_PWM_ALT, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM), No_ADC_Channel, PWM0_CH7, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // Pin 7 + { PORTA, 6, PIO_PWM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM), No_ADC_Channel, PWM1_CH0, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // Pin 8 + { PORTA, 7, PIO_PWM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM), No_ADC_Channel, PWM1_CH1, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // Pin 9 + + // ---------------------- + // 47 - Alternate use of A0 (DAC output) + { PORTA, 2, PIO_ANALOG, PIN_ATTR_ANALOG, DAC_Channel0, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_2 }, // DAC/VOUT +} ; + +extern "C" { + unsigned int PINCOUNT_fn() { + return (sizeof(g_APinDescription) / sizeof(g_APinDescription[0])); + } +} + +const void* g_apTCInstances[TCC_INST_NUM+TC_INST_NUM]={ TCC0, TCC1, TCC2, TC3, TC4, TC5 } ; + +// Multi-serial objects instantiation +SERCOM sercom0( SERCOM0 ) ; +SERCOM sercom1( SERCOM1 ) ; +SERCOM sercom2( SERCOM2 ) ; +SERCOM sercom3( SERCOM3 ) ; +SERCOM sercom4( SERCOM4 ) ; +SERCOM sercom5( SERCOM5 ) ; + +Uart Serial1( &sercom0, PIN_SERIAL1_RX, PIN_SERIAL1_TX, PAD_SERIAL1_RX, PAD_SERIAL1_TX ) ; +Uart Serial( &sercom5, PIN_SERIAL_RX, PIN_SERIAL_TX, PAD_SERIAL_RX, PAD_SERIAL_TX ) ; +void SERCOM0_Handler() +{ + Serial1.IrqHandler(); +} + +void SERCOM5_Handler() +{ + Serial.IrqHandler(); +} diff --git a/variants/arduino_mzero/variant.h b/variants/arduino_mzero/variant.h new file mode 100755 index 0000000..1958e17 --- /dev/null +++ b/variants/arduino_mzero/variant.h @@ -0,0 +1,223 @@ +/* + Copyright (c) 2014-2016 Arduino LLC. 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 _VARIANT_ARDUINO_ZERO_ +#define _VARIANT_ARDUINO_ZERO_ + +// The definitions here needs a SAMD core >=1.6.10 +#define ARDUINO_SAMD_VARIANT_COMPLIANCE 10610 + +/*---------------------------------------------------------------------------- + * Definitions + *----------------------------------------------------------------------------*/ + +/** Frequency of the board main oscillator */ +#define VARIANT_MAINOSC (32768ul) + +/** Master clock frequency */ +#define VARIANT_MCK (48000000ul) + +/*---------------------------------------------------------------------------- + * Headers + *----------------------------------------------------------------------------*/ + +#include "WVariant.h" + +#ifdef __cplusplus +#include "SERCOM.h" +#include "Uart.h" +#endif // __cplusplus + +#ifdef __cplusplus +extern "C" +{ +#endif // __cplusplus + +/*---------------------------------------------------------------------------- + * Pins + *----------------------------------------------------------------------------*/ + +// Number of pins defined in PinDescription array +#ifdef __cplusplus +extern "C" unsigned int PINCOUNT_fn(); +#endif +#define PINS_COUNT (PINCOUNT_fn()) +#define NUM_DIGITAL_PINS (19u) +#define NUM_ANALOG_INPUTS (5u) +#define NUM_ANALOG_OUTPUTS (1u) +#define analogInputToDigitalPin(p) ((p < 6u) ? (p) + 24u : -1) + +#define digitalPinToPort(P) ( &(PORT->Group[g_APinDescription[P].ulPort]) ) +#define digitalPinToBitMask(P) ( 1 << g_APinDescription[P].ulPin ) +//#define analogInPinToBit(P) ( ) +#define portOutputRegister(port) ( &(port->OUT.reg) ) +#define portInputRegister(port) ( &(port->IN.reg) ) +#define portModeRegister(port) ( &(port->DIR.reg) ) +#define digitalPinHasPWM(P) ( g_APinDescription[P].ulPWMChannel != NOT_ON_PWM || g_APinDescription[P].ulTCChannel != NOT_ON_TIMER ) + +/* + * digitalPinToTimer(..) is AVR-specific and is not defined for SAMD + * architecture. If you need to check if a pin supports PWM you must + * use digitalPinHasPWM(..). + * + * https://github.com/arduino/Arduino/issues/1833 + */ +// #define digitalPinToTimer(P) + +// LEDs +#define PIN_LED_13 (13u) +#define PIN_LED_RXL (30u) +#define PIN_LED_TXL (31u) +#define PIN_LED PIN_LED_13 +#define PIN_LED2 PIN_LED_RXL +#define PIN_LED3 PIN_LED_TXL +#define LED_BUILTIN PIN_LED_13 + +/* + * Analog pins + */ +#define PIN_A0 (24ul) +#define PIN_A1 (25ul) +#define PIN_A2 (26ul) +#define PIN_A3 (27ul) +#define PIN_A4 (28ul) +#define PIN_A5 (29ul) +#define PIN_DAC0 (24ul) + +static const uint8_t A0 = PIN_A0; +static const uint8_t A1 = PIN_A1; +static const uint8_t A2 = PIN_A2; +static const uint8_t A3 = PIN_A3; +static const uint8_t A4 = PIN_A4; +static const uint8_t A5 = PIN_A5; +static const uint8_t DAC0 = PIN_DAC0; +#define ADC_RESOLUTION 12 + + +/* + * Serial interfaces + */ +// Serial (EDBG) +#define PIN_SERIAL_RX (36ul) +#define PIN_SERIAL_TX (35ul) +#define PAD_SERIAL_TX (UART_TX_PAD_2) +#define PAD_SERIAL_RX (SERCOM_RX_PAD_3) + +// Serial1 +#define PIN_SERIAL1_RX (0ul) +#define PIN_SERIAL1_TX (1ul) +#define PAD_SERIAL1_TX (UART_TX_PAD_2) +#define PAD_SERIAL1_RX (SERCOM_RX_PAD_3) + +/* + * SPI Interfaces + */ +#define SPI_INTERFACES_COUNT 1 + +#define PIN_SPI_MISO (18u) +#define PIN_SPI_MOSI (21u) +#define PIN_SPI_SCK (20u) +#define PERIPH_SPI sercom4 +#define PAD_SPI_TX SPI_PAD_2_SCK_3 +#define PAD_SPI_RX SERCOM_RX_PAD_0 + +static const uint8_t SS = 14; //GND +static const uint8_t MOSI = PIN_SPI_MOSI; +static const uint8_t MISO = PIN_SPI_MISO; +static const uint8_t SCK = PIN_SPI_SCK; + +/* + * Wire Interfaces + */ +#define WIRE_INTERFACES_COUNT 1 + +#define PIN_WIRE_SDA (16u) +#define PIN_WIRE_SCL (17u) +#define PERIPH_WIRE sercom3 +#define WIRE_IT_HANDLER SERCOM3_Handler + +static const uint8_t SDA = PIN_WIRE_SDA; +static const uint8_t SCL = PIN_WIRE_SCL; + +/* + * USB + */ +#define PIN_USB_HOST_ENABLE (32ul) +#define PIN_USB_DM (33ul) +#define PIN_USB_DP (34ul) + +#ifdef __cplusplus +} +#endif + +/*---------------------------------------------------------------------------- + * Arduino objects - C++ only + *----------------------------------------------------------------------------*/ + +#ifdef __cplusplus + +/* ========================= + * ===== SERCOM DEFINITION + * ========================= +*/ +extern SERCOM sercom0; +extern SERCOM sercom1; +extern SERCOM sercom2; +extern SERCOM sercom3; +extern SERCOM sercom4; +extern SERCOM sercom5; + +extern Uart Serial; +extern Uart Serial1; + +#endif + +#ifdef __cplusplus +extern "C" { +#endif +unsigned int PINCOUNT_fn(); +#ifdef __cplusplus +} +#endif + +// These serial port names are intended to allow libraries and architecture-neutral +// sketches to automatically default to the correct port name for a particular type +// of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, +// the first hardware serial port whose RX/TX pins are not dedicated to another use. +// +// SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor +// +// SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial +// +// SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library +// +// SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. +// +// SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX +// pins are NOT connected to anything by default. +#define SERIAL_PORT_USBVIRTUAL SerialUSB +#define SERIAL_PORT_MONITOR Serial +// Serial has no physical pins broken out, so it's not listed as HARDWARE port +#define SERIAL_PORT_HARDWARE Serial1 +#define SERIAL_PORT_HARDWARE_OPEN Serial1 + +// Legacy way to describe serial port on pins 0-1 +#define Serial5 Serial1 + +#endif /* _VARIANT_ARDUINO_ZERO_ */ + diff --git a/variants/arduino_zero/debug_scripts/variant.gdb b/variants/arduino_zero/debug_scripts/variant.gdb new file mode 100644 index 0000000..3c37ffd --- /dev/null +++ b/variants/arduino_zero/debug_scripts/variant.gdb @@ -0,0 +1,31 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +# Define 'reset' command +define reset + +info reg + +break main + +# End of 'reset' command +end + +target remote | openocd -c "interface cmsis-dap" -c "set CHIPNAME at91samd21g18" -f target/at91samdXX.cfg -c "gdb_port pipe; log_output openocd.log" diff --git a/variants/arduino_zero/linker_scripts/gcc/flash_with_bootloader.ld b/variants/arduino_zero/linker_scripts/gcc/flash_with_bootloader.ld new file mode 100644 index 0000000..3579464 --- /dev/null +++ b/variants/arduino_zero/linker_scripts/gcc/flash_with_bootloader.ld @@ -0,0 +1,216 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000+0x2000, LENGTH = 0x00040000-0x2000 /* First 8KB used by bootloader */ + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.sketch_boot)) + + . = ALIGN(0x2000); + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(16); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM); + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/arduino_zero/linker_scripts/gcc/flash_without_bootloader.ld b/variants/arduino_zero/linker_scripts/gcc/flash_without_bootloader.ld new file mode 100644 index 0000000..ebeeee3 --- /dev/null +++ b/variants/arduino_zero/linker_scripts/gcc/flash_without_bootloader.ld @@ -0,0 +1,214 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 0x00040000 + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + * __ram_end__ + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(16); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM) ; + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/arduino_zero/openocd_scripts/arduino_zero.cfg b/variants/arduino_zero/openocd_scripts/arduino_zero.cfg new file mode 100644 index 0000000..36c65c3 --- /dev/null +++ b/variants/arduino_zero/openocd_scripts/arduino_zero.cfg @@ -0,0 +1,30 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +source [find interface/cmsis-dap.cfg] + +# chip name +set CHIPNAME at91samd21g18 +set ENDIAN little + +# choose a port here +set telnet_port 0 + +source [find target/at91samdXX.cfg] diff --git a/variants/arduino_zero/pins_arduino.h b/variants/arduino_zero/pins_arduino.h new file mode 100644 index 0000000..db0e40c --- /dev/null +++ b/variants/arduino_zero/pins_arduino.h @@ -0,0 +1,21 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +// API compatibility +#include "variant.h" + diff --git a/variants/arduino_zero/variant.cpp b/variants/arduino_zero/variant.cpp new file mode 100644 index 0000000..2bc8b4a --- /dev/null +++ b/variants/arduino_zero/variant.cpp @@ -0,0 +1,233 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ +/* + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * + Pin number + ZERO Board pin | PIN | Label/Name | Comments (* is for default peripheral in use) + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | Digital Low | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 0 | 0 -> RX | PA11 | | EIC/EXTINT[11] ADC/AIN[19] PTC/X[3] *SERCOM0/PAD[3] SERCOM2/PAD[3] TCC0/WO[3] TCC1/WO[1] + * | 1 | 1 <- TX | PA10 | | EIC/EXTINT[10] ADC/AIN[18] PTC/X[2] *SERCOM0/PAD[2] TCC0/WO[2] TCC1/WO[0] + * | 2 | 2 | PA14 | | EIC/EXTINT[14] SERCOM2/PAD[2] SERCOM4/PAD[2] TC3/WO[0] TCC0/WO[4] + * | 3 | ~3 | PA09 | | EIC/EXTINT[9] ADC/AIN[17] PTC/X[1] SERCOM0/PAD[1] SERCOM2/PAD[1] *TCC0/WO[1] TCC1/WO[3] + * | 4 | ~4 | PA08 | | EIC/NMI ADC/AIN[16] PTC/X[0] SERCOM0/PAD[0] SERCOM2/PAD[0] *TCC0/WO[0] TCC1/WO[2] + * | 5 | ~5 | PA15 | | EIC/EXTINT[15] SERCOM2/PAD[3] SERCOM4/PAD[3] *TC3/WO[1] TCC0/WO[5] + * | 6 | ~6 | PA20 | | EIC/EXTINT[4] PTC/X[8] SERCOM5/PAD[2] SERCOM3/PAD[2] *TCC0/WO[6] + * | 7 | 7 | PA21 | | EIC/EXTINT[5] PTC/X[9] SERCOM5/PAD[3] SERCOM3/PAD[3] TCC0/WO[7] + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | Digital High | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 8 | ~8 | PA06 | | EIC/EXTINT[6] ADC/AIN[6] AC/AIN[2] PTC/Y[4] SERCOM0/PAD[2] *TCC1/WO[0] + * | 9 | ~9 | PA07 | | EIC/EXTINT[7] ADC/AIN[7] AC/AIN[3] PTC/Y[5] SERCOM0/PAD[3] *TCC1/WO[1] + * | 10 | ~10 | PA18 | | EIC/EXTINT[2] PTC/X[6] +SERCOM1/PAD[2] SERCOM3/PAD[2] *TC3/WO[0] TCC0/WO[2] + * | 11 | ~11 | PA16 | | EIC/EXTINT[0] PTC/X[4] +SERCOM1/PAD[0] SERCOM3/PAD[0] *TCC2/WO[0] TCC0/WO[6] + * | 12 | ~12 | PA19 | | EIC/EXTINT[3] PTC/X[7] +SERCOM1/PAD[3] SERCOM3/PAD[3] TC3/WO[1] *TCC0/WO[3] + * | 13 | ~13 | PA17 | LED | EIC/EXTINT[1] PTC/X[5] +SERCOM1/PAD[1] SERCOM3/PAD[1] *TCC2/WO[1] TCC0/WO[7] + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | Analog Connector | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 14 | A0 | PA02 | A0 | EIC/EXTINT[2] *ADC/AIN[0] DAC/VOUT PTC/Y[0] + * | 15 | A1 | PB08 | A1 | EIC/EXTINT[8] *ADC/AIN[2] PTC/Y[14] SERCOM4/PAD[0] TC4/WO[0] + * | 16 | A2 | PB09 | A2 | EIC/EXTINT[9] *ADC/AIN[3] PTC/Y[15] SERCOM4/PAD[1] TC4/WO[1] + * | 17 | A3 | PA04 | A3 | EIC/EXTINT[4] *ADC/AIN[4] AC/AIN[0] PTC/Y[2] SERCOM0/PAD[0] TCC0/WO[0] + * | 18 | A4 | PA05 | A4 | EIC/EXTINT[5] *ADC/AIN[5] AC/AIN[1] PTC/Y[5] SERCOM0/PAD[1] TCC0/WO[1] + * | 19 | A5 | PB02 | A5 | EIC/EXTINT[2] *ADC/AIN[10] PTC/Y[8] SERCOM5/PAD[0] + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | Wire | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 20 | SDA | PA22 | SDA | EIC/EXTINT[6] PTC/X[10] *SERCOM3/PAD[0] SERCOM5/PAD[0] TC4/WO[0] TCC0/WO[4] + * | 21 | SCL | PA23 | SCL | EIC/EXTINT[7] PTC/X[11] *SERCOM3/PAD[1] SERCOM5/PAD[1] TC4/WO[1] TCC0/WO[5] + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | |SPI (Legacy ICSP) | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 22 | 1 | PA12 | MISO | EIC/EXTINT[12] SERCOM2/PAD[0] *SERCOM4/PAD[0] TCC2/WO[0] TCC0/WO[6] + * | | 2 | | 5V0 | + * | 23 | 4 | PB10 | MOSI | EIC/EXTINT[10] *SERCOM4/PAD[2] TC5/WO[0] TCC0/WO[4] + * | 24 | 3 | PB11 | SCK | EIC/EXTINT[11] *SERCOM4/PAD[3] TC5/WO[1] TCC0/WO[5] + * | | 5 | | RESET | + * | | 6 | | GND | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | LEDs | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 25 | | PB03 | RX | + * | 26 | | PA27 | TX | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | USB | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 27 | | PA28 | USB_HOST_ENABLE | EIC/EXTINT[8] + * | 28 | | PA24 | USB_NEGATIVE | *USB/DM + * | 29 | | PA25 | USB_POSITIVE | *USB/DP + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | EDBG | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 30 | | PB22 | EDBG_UART TX | *SERCOM5/PAD[2] + * | 31 | | PB23 | EDBG_UART RX | *SERCOM5/PAD[3] + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 32 | | PA22 | EDBG_SDA | Pin 20 (SDA) + * | 33 | | PA23 | EDBG_SCL | Pin 21 (SCL) + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 34 | | PA19 | EDBG_MISO | EIC/EXTINT[3] *SERCOM1/PAD[3] SERCOM3/PAD[3] TC3/WO[1] TCC0/WO[3] + * | 35 | | PA16 | EDBG_MOSI | EIC/EXTINT[0] *SERCOM1/PAD[0] SERCOM3/PAD[0] TCC2/WO[0] TCC0/WO[6] + * | 36 | | PA18 | EDBG_SS | EIC/EXTINT[2] *SERCOM1/PAD[2] SERCOM3/PAD[2] TC3/WO[0] TCC0/WO[2] + * | 37 | | PA17 | EDBG_SCK | EIC/EXTINT[1] *SERCOM1/PAD[1] SERCOM3/PAD[1] TCC2/WO[1] TCC0/WO[7] + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 38 | ATN | PA13 | EDBG_GPIO0 | EIC/EXTINT[13] SERCOM2/PAD[1] SERCOM4/PAD[1] *TCC2/WO[1] TCC0/WO[7] + * | 39 | | PA21 | EDBG_GPIO1 | Pin 7 + * | 40 | | PA06 | EDBG_GPIO2 | Pin 8 + * | 41 | | PA07 | EDBG_GPIO3 | Pin 9 + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | GND | | | + * | 42 | AREF | PA03 | | EIC/EXTINT[3] *[ADC|DAC]/VREFA ADC/AIN[1] PTC/Y[1] + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 43 | | PA02 | | Alternate use of A0 (DAC output) + * | 44 | | PA30 | | SWCLK, alternate use EXTINT[10] TCC1/WO[0] SERCOM1/PAD[2] + * | 45 | | PA31 | | SWDIO, alternate use EXTINT[11] TCC1/WO[1] SERCOM1/PAD[3] + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | |32.768KHz Crystal | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | | PA00 | XIN32 | EIC/EXTINT[0] SERCOM1/PAD[0] TCC2/WO[0] + * | | | PA01 | XOUT32 | EIC/EXTINT[1] SERCOM1/PAD[1] TCC2/WO[1] + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + */ + + +#include "variant.h" + +/* + * Pins descriptions + */ +const PinDescription g_APinDescription[]= +{ + // 0..13 - Digital pins + // ---------------------- + // 0/1 - SERCOM/UART (Serial1) + { PORTA, 11, PIO_SERCOM, (PIN_ATTR_DIGITAL), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_11 }, // RX: SERCOM0/PAD[3] + { PORTA, 10, PIO_SERCOM, (PIN_ATTR_DIGITAL), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_10 }, // TX: SERCOM0/PAD[2] + + // 2..12 + // Digital Low + { PORTA, 14, PIO_DIGITAL, (PIN_ATTR_DIGITAL), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_14 }, + { PORTA, 9, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM0_CH1, TCC0_CH1, EXTERNAL_INT_9 }, // TCC0/WO[1] + { PORTA, 8, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM0_CH0, TCC0_CH0, EXTERNAL_INT_NMI }, // TCC0/WO[0] + { PORTA, 15, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM3_CH1, TC3_CH1, EXTERNAL_INT_15 }, // TC3/WO[1] + { PORTA, 20, PIO_TIMER_ALT, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH6, TCC0_CH6, EXTERNAL_INT_4 }, // TCC0/WO[6] + { PORTA, 21, PIO_TIMER_ALT, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH7, TCC0_CH7, EXTERNAL_INT_5 }, // TCC0/WO[7] + + // Digital High + { PORTA, 6, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM1_CH0, TCC1_CH0, EXTERNAL_INT_6 }, // TCC1/WO[0] + { PORTA, 7, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM1_CH1, TCC1_CH1, EXTERNAL_INT_7 }, // TCC1/WO[1] + { PORTA, 18, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM3_CH0, TC3_CH0, EXTERNAL_INT_2 }, // TC3/WO[0] + { PORTA, 16, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM2_CH0, TCC2_CH0, EXTERNAL_INT_0 }, // TCC2/WO[0] + { PORTA, 19, PIO_TIMER_ALT, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH3, TCC0_CH3, EXTERNAL_INT_3 }, // TCC0/WO[3] + + // 13 (LED) + { PORTA, 17, PIO_PWM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM2_CH1, TCC2_CH1, EXTERNAL_INT_1 }, // TCC2/WO[1] + + // 14..19 - Analog pins + // -------------------- + { PORTA, 2, PIO_ANALOG, PIN_ATTR_ANALOG, ADC_Channel0, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_2 }, // ADC/AIN[0] + { PORTB, 8, PIO_ANALOG, (PIN_ATTR_PWM|PIN_ATTR_TIMER), ADC_Channel2, PWM4_CH0, TC4_CH0, EXTERNAL_INT_8 }, // ADC/AIN[2] + { PORTB, 9, PIO_ANALOG, (PIN_ATTR_PWM|PIN_ATTR_TIMER), ADC_Channel3, PWM4_CH1, TC4_CH1, EXTERNAL_INT_9 }, // ADC/AIN[3] + { PORTA, 4, PIO_ANALOG, 0, ADC_Channel4, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_4 }, // ADC/AIN[4] + { PORTA, 5, PIO_ANALOG, 0, ADC_Channel5, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_5 }, // ADC/AIN[5] + { PORTB, 2, PIO_ANALOG, 0, ADC_Channel10, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_2 }, // ADC/AIN[10] + + // 20..21 I2C pins (SDA/SCL and also EDBG:SDA/SCL) + // ---------------------- + { PORTA, 22, PIO_SERCOM, PIN_ATTR_DIGITAL, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_6 }, // SDA: SERCOM3/PAD[0] + { PORTA, 23, PIO_SERCOM, PIN_ATTR_DIGITAL, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_7 }, // SCL: SERCOM3/PAD[1] + + // 22..24 - SPI pins (ICSP:MISO,SCK,MOSI) + // ---------------------- + { PORTA, 12, PIO_SERCOM_ALT, PIN_ATTR_DIGITAL, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_12 }, // MISO: SERCOM4/PAD[0] + { PORTB, 10, PIO_SERCOM_ALT, PIN_ATTR_DIGITAL, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_10 }, // MOSI: SERCOM4/PAD[2] + { PORTB, 11, PIO_SERCOM_ALT, PIN_ATTR_DIGITAL, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_11 }, // SCK: SERCOM4/PAD[3] + + // 25..26 - RX/TX LEDS (PB03/PA27) + // -------------------- + { PORTB, 3, PIO_OUTPUT, PIN_ATTR_DIGITAL, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // used as output only + { PORTA, 27, PIO_OUTPUT, PIN_ATTR_DIGITAL, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // used as output only + + // 27..29 - USB + // -------------------- + { PORTA, 28, PIO_COM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB Host enable + { PORTA, 24, PIO_COM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DM + { PORTA, 25, PIO_COM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DP + + // 30..41 - EDBG + // ---------------------- + // 30/31 - EDBG/UART + { PORTB, 22, PIO_SERCOM_ALT, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // TX: SERCOM5/PAD[2] + { PORTB, 23, PIO_SERCOM_ALT, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // RX: SERCOM5/PAD[3] + + // 32/33 I2C (SDA/SCL and also EDBG:SDA/SCL) + { PORTA, 22, PIO_SERCOM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SDA: SERCOM3/PAD[0] + { PORTA, 23, PIO_SERCOM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCL: SERCOM3/PAD[1] + + // 34..37 - EDBG/SPI + { PORTA, 19, PIO_SERCOM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MISO: SERCOM1/PAD[3] + { PORTA, 16, PIO_SERCOM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MOSI: SERCOM1/PAD[0] + { PORTA, 18, PIO_SERCOM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SS: SERCOM1/PAD[2] + { PORTA, 17, PIO_SERCOM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCK: SERCOM1/PAD[1] + + // 38..41 - EDBG/Digital + { PORTA, 13, PIO_PWM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM), No_ADC_Channel, PWM0_CH5, NOT_ON_TIMER, EXTERNAL_INT_13 }, // EIC/EXTINT[13] *TCC2/WO[1] TCC0/WO[7] + { PORTA, 21, PIO_PWM_ALT, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM), No_ADC_Channel, PWM0_CH7, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // Pin 7 + { PORTA, 6, PIO_PWM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM), No_ADC_Channel, PWM1_CH0, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // Pin 8 + { PORTA, 7, PIO_PWM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM), No_ADC_Channel, PWM1_CH1, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // Pin 9 + + // 42 (AREF) + { PORTA, 3, PIO_ANALOG, PIN_ATTR_ANALOG, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // DAC/VREFP + + // ---------------------- + // 43..45 - Alternate use of A0 (DAC output), 44 SWCLK, 45, SWDIO + { PORTA, 2, PIO_ANALOG, PIN_ATTR_ANALOG, DAC_Channel0, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_2 }, // DAC/VOUT + { PORTA, 30, PIO_PWM, PIN_ATTR_DIGITAL|PIO_SERCOM, No_ADC_Channel, NOT_ON_PWM, TCC1_CH0, EXTERNAL_INT_10 }, // SWCLK + { PORTA, 31, PIO_PWM, PIN_ATTR_DIGITAL|PIO_SERCOM, No_ADC_Channel, NOT_ON_PWM, TCC1_CH1, EXTERNAL_INT_11 }, // SWDIO +} ; + +extern "C" { + unsigned int PINCOUNT_fn() { + return (sizeof(g_APinDescription) / sizeof(g_APinDescription[0])); + } +} + +const void* g_apTCInstances[TCC_INST_NUM+TC_INST_NUM]={ TCC0, TCC1, TCC2, TC3, TC4, TC5 } ; + +// Multi-serial objects instantiation +SERCOM sercom0( SERCOM0 ) ; +SERCOM sercom1( SERCOM1 ) ; +SERCOM sercom2( SERCOM2 ) ; +SERCOM sercom3( SERCOM3 ) ; +SERCOM sercom4( SERCOM4 ) ; +SERCOM sercom5( SERCOM5 ) ; + +Uart Serial1( &sercom0, PIN_SERIAL1_RX, PIN_SERIAL1_TX, PAD_SERIAL1_RX, PAD_SERIAL1_TX ) ; +Uart Serial( &sercom5, PIN_SERIAL_RX, PIN_SERIAL_TX, PAD_SERIAL_RX, PAD_SERIAL_TX ) ; +void SERCOM0_Handler() +{ + Serial1.IrqHandler(); +} + +void SERCOM5_Handler() +{ + Serial.IrqHandler(); +} + diff --git a/variants/arduino_zero/variant.h b/variants/arduino_zero/variant.h new file mode 100644 index 0000000..8d40f40 --- /dev/null +++ b/variants/arduino_zero/variant.h @@ -0,0 +1,234 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 _VARIANT_ARDUINO_ZERO_ +#define _VARIANT_ARDUINO_ZERO_ + +// The definitions here needs a SAMD core >=1.6.10 +#define ARDUINO_SAMD_VARIANT_COMPLIANCE 10610 + +/*---------------------------------------------------------------------------- + * Definitions + *----------------------------------------------------------------------------*/ + +/** Frequency of the board main oscillator */ +#define VARIANT_MAINOSC (32768ul) + +/** Master clock frequency */ +#define VARIANT_MCK (48000000ul) + +/*---------------------------------------------------------------------------- + * Headers + *----------------------------------------------------------------------------*/ + +#include "WVariant.h" + +#ifdef __cplusplus +#include "SERCOM.h" +#include "Uart.h" +#endif // __cplusplus + +#ifdef __cplusplus +extern "C" +{ +#endif // __cplusplus + +/*---------------------------------------------------------------------------- + * Pins + *----------------------------------------------------------------------------*/ + +// Number of pins defined in PinDescription array +#ifdef __cplusplus +extern "C" unsigned int PINCOUNT_fn(); +#endif +#define PINS_COUNT (PINCOUNT_fn()) +#define NUM_DIGITAL_PINS (20u) +#define NUM_ANALOG_INPUTS (6u) +#define NUM_ANALOG_OUTPUTS (1u) +#define analogInputToDigitalPin(p) ((p < 6u) ? (p) + 14u : -1) + +#define digitalPinToPort(P) ( &(PORT->Group[g_APinDescription[P].ulPort]) ) +#define digitalPinToBitMask(P) ( 1 << g_APinDescription[P].ulPin ) +//#define analogInPinToBit(P) ( ) +#define portOutputRegister(port) ( &(port->OUT.reg) ) +#define portInputRegister(port) ( &(port->IN.reg) ) +#define portModeRegister(port) ( &(port->DIR.reg) ) +#define digitalPinHasPWM(P) ( g_APinDescription[P].ulPWMChannel != NOT_ON_PWM || g_APinDescription[P].ulTCChannel != NOT_ON_TIMER ) + +/* + * digitalPinToTimer(..) is AVR-specific and is not defined for SAMD + * architecture. If you need to check if a pin supports PWM you must + * use digitalPinHasPWM(..). + * + * https://github.com/arduino/Arduino/issues/1833 + */ +// #define digitalPinToTimer(P) + +// LEDs +#define PIN_LED_13 (13u) +#define PIN_LED_RXL (25u) +#define PIN_LED_TXL (26u) +#define PIN_LED PIN_LED_13 +#define PIN_LED2 PIN_LED_RXL +#define PIN_LED3 PIN_LED_TXL +#define LED_BUILTIN PIN_LED_13 + +/* + * Analog pins + */ +#define PIN_A0 (14ul) +#define PIN_A1 (15ul) +#define PIN_A2 (16ul) +#define PIN_A3 (17ul) +#define PIN_A4 (18ul) +#define PIN_A5 (19ul) +#define PIN_DAC0 (14ul) + +static const uint8_t A0 = PIN_A0; +static const uint8_t A1 = PIN_A1; +static const uint8_t A2 = PIN_A2; +static const uint8_t A3 = PIN_A3; +static const uint8_t A4 = PIN_A4; +static const uint8_t A5 = PIN_A5; +static const uint8_t DAC0 = PIN_DAC0; +#define ADC_RESOLUTION 12 + +// Other pins +#define PIN_ATN (38ul) +static const uint8_t ATN = PIN_ATN; + +/* + * Serial interfaces + */ +// Serial (EDBG) +#define PIN_SERIAL_RX (31ul) +#define PIN_SERIAL_TX (30ul) +#define PAD_SERIAL_TX (UART_TX_PAD_2) +#define PAD_SERIAL_RX (SERCOM_RX_PAD_3) + +// Serial1 +#define PIN_SERIAL1_RX (0ul) +#define PIN_SERIAL1_TX (1ul) +#define PAD_SERIAL1_TX (UART_TX_PAD_2) +#define PAD_SERIAL1_RX (SERCOM_RX_PAD_3) + +/* + * SPI Interfaces + */ +#define SPI_INTERFACES_COUNT 1 + +#define PIN_SPI_MISO (22u) +#define PIN_SPI_MOSI (23u) +#define PIN_SPI_SCK (24u) +#define PERIPH_SPI sercom4 +#define PAD_SPI_TX SPI_PAD_2_SCK_3 +#define PAD_SPI_RX SERCOM_RX_PAD_0 + +static const uint8_t SS = PIN_A2 ; // SERCOM4 last PAD is present on A2 but HW SS isn't used. Set here only for reference. +static const uint8_t MOSI = PIN_SPI_MOSI ; +static const uint8_t MISO = PIN_SPI_MISO ; +static const uint8_t SCK = PIN_SPI_SCK ; + +/* + * Wire Interfaces + */ +#define WIRE_INTERFACES_COUNT 1 + +#define PIN_WIRE_SDA (20u) +#define PIN_WIRE_SCL (21u) +#define PERIPH_WIRE sercom3 +#define WIRE_IT_HANDLER SERCOM3_Handler + +static const uint8_t SDA = PIN_WIRE_SDA; +static const uint8_t SCL = PIN_WIRE_SCL; + +/* + * USB + */ +#define PIN_USB_HOST_ENABLE (27ul) +#define PIN_USB_DM (28ul) +#define PIN_USB_DP (29ul) + +/* + * I2S Interfaces + */ +#define I2S_INTERFACES_COUNT 1 + +#define I2S_DEVICE 0 +#define I2S_CLOCK_GENERATOR 3 +#define PIN_I2S_SD (9u) +#define PIN_I2S_SCK (1u) +#define PIN_I2S_FS (0u) + +#ifdef __cplusplus +} +#endif + +/*---------------------------------------------------------------------------- + * Arduino objects - C++ only + *----------------------------------------------------------------------------*/ + +#ifdef __cplusplus + +/* ========================= + * ===== SERCOM DEFINITION + * ========================= +*/ +extern SERCOM sercom0; +extern SERCOM sercom1; +extern SERCOM sercom2; +extern SERCOM sercom3; +extern SERCOM sercom4; +extern SERCOM sercom5; + +extern Uart Serial; +extern Uart Serial1; + +#endif + +#ifdef __cplusplus +extern "C" { +#endif +unsigned int PINCOUNT_fn(); +#ifdef __cplusplus +} +#endif + +// These serial port names are intended to allow libraries and architecture-neutral +// sketches to automatically default to the correct port name for a particular type +// of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, +// the first hardware serial port whose RX/TX pins are not dedicated to another use. +// +// SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor +// +// SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial +// +// SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library +// +// SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. +// +// SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX +// pins are NOT connected to anything by default. +#define SERIAL_PORT_USBVIRTUAL SerialUSB +#define SERIAL_PORT_MONITOR Serial +// Serial has no physical pins broken out, so it's not listed as HARDWARE port +#define SERIAL_PORT_HARDWARE Serial1 +#define SERIAL_PORT_HARDWARE_OPEN Serial1 + +#endif /* _VARIANT_ARDUINO_ZERO_ */ + diff --git a/variants/circuitplay/debug_scripts/variant.gdb b/variants/circuitplay/debug_scripts/variant.gdb new file mode 100644 index 0000000..3c37ffd --- /dev/null +++ b/variants/circuitplay/debug_scripts/variant.gdb @@ -0,0 +1,31 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +# Define 'reset' command +define reset + +info reg + +break main + +# End of 'reset' command +end + +target remote | openocd -c "interface cmsis-dap" -c "set CHIPNAME at91samd21g18" -f target/at91samdXX.cfg -c "gdb_port pipe; log_output openocd.log" diff --git a/variants/circuitplay/linker_scripts/gcc/flash_with_bootloader.ld b/variants/circuitplay/linker_scripts/gcc/flash_with_bootloader.ld new file mode 100644 index 0000000..3506186 --- /dev/null +++ b/variants/circuitplay/linker_scripts/gcc/flash_with_bootloader.ld @@ -0,0 +1,213 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000+0x2000, LENGTH = 0x00040000-0x2000 /* First 8KB used by bootloader */ + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(4); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM); + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/circuitplay/linker_scripts/gcc/flash_without_bootloader.ld b/variants/circuitplay/linker_scripts/gcc/flash_without_bootloader.ld new file mode 100644 index 0000000..749aa5f --- /dev/null +++ b/variants/circuitplay/linker_scripts/gcc/flash_without_bootloader.ld @@ -0,0 +1,214 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 0x00040000 + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + * __ram_end__ + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(4); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM) ; + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/circuitplay/openocd_scripts/arduino_zero.cfg b/variants/circuitplay/openocd_scripts/arduino_zero.cfg new file mode 100644 index 0000000..36c65c3 --- /dev/null +++ b/variants/circuitplay/openocd_scripts/arduino_zero.cfg @@ -0,0 +1,30 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +source [find interface/cmsis-dap.cfg] + +# chip name +set CHIPNAME at91samd21g18 +set ENDIAN little + +# choose a port here +set telnet_port 0 + +source [find target/at91samdXX.cfg] diff --git a/variants/circuitplay/pins_arduino.h b/variants/circuitplay/pins_arduino.h new file mode 100644 index 0000000..db0e40c --- /dev/null +++ b/variants/circuitplay/pins_arduino.h @@ -0,0 +1,21 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +// API compatibility +#include "variant.h" + diff --git a/variants/circuitplay/variant.cpp b/variants/circuitplay/variant.cpp new file mode 100644 index 0000000..d9e7b90 --- /dev/null +++ b/variants/circuitplay/variant.cpp @@ -0,0 +1,209 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ +/* + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * + Pin number + ZERO Board pin | PIN | Label/Name | Comments (* is for default peripheral in use) + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | Digital Low | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 0 | 0 -> RX | PA11 | | EIC/EXTINT[11] ADC/AIN[19] PTC/X[3] *SERCOM0/PAD[3] SERCOM2/PAD[3] TCC0/WO[3] TCC1/WO[1] + * | 1 | 1 <- TX | PA10 | | EIC/EXTINT[10] ADC/AIN[18] PTC/X[2] *SERCOM0/PAD[2] TCC0/WO[2] TCC1/WO[0] + * | 2 | 2 | PA14 | | EIC/EXTINT[14] SERCOM2/PAD[2] SERCOM4/PAD[2] TC3/WO[0] TCC0/WO[4] + * | 3 | ~3 | PA09 | | EIC/EXTINT[9] ADC/AIN[17] PTC/X[1] SERCOM0/PAD[1] SERCOM2/PAD[1] *TCC0/WO[1] TCC1/WO[3] + * | 4 | ~4 | PA08 | | EIC/NMI ADC/AIN[16] PTC/X[0] SERCOM0/PAD[0] SERCOM2/PAD[0] *TCC0/WO[0] TCC1/WO[2] + * | 5 | ~5 | PA15 | | EIC/EXTINT[15] SERCOM2/PAD[3] SERCOM4/PAD[3] *TC3/WO[1] TCC0/WO[5] + * | 6 | ~6 | PA20 | | EIC/EXTINT[4] PTC/X[8] SERCOM5/PAD[2] SERCOM3/PAD[2] *TCC0/WO[6] + * | 7 | 7 | PA21 | | EIC/EXTINT[5] PTC/X[9] SERCOM5/PAD[3] SERCOM3/PAD[3] TCC0/WO[7] + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | Digital High | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 8 | ~8 | PA06 | | EIC/EXTINT[6] ADC/AIN[6] AC/AIN[2] PTC/Y[4] SERCOM0/PAD[2] *TCC1/WO[0] + * | 9 | ~9 | PA07 | | EIC/EXTINT[7] ADC/AIN[7] AC/AIN[3] PTC/Y[5] SERCOM0/PAD[3] *TCC1/WO[1] + * | 10 | ~10 | PA18 | | EIC/EXTINT[2] PTC/X[6] +SERCOM1/PAD[2] SERCOM3/PAD[2] *TC3/WO[0] TCC0/WO[2] + * | 11 | ~11 | PA16 | | EIC/EXTINT[0] PTC/X[4] +SERCOM1/PAD[0] SERCOM3/PAD[0] *TCC2/WO[0] TCC0/WO[6] + * | 12 | ~12 | PA19 | | EIC/EXTINT[3] PTC/X[7] +SERCOM1/PAD[3] SERCOM3/PAD[3] TC3/WO[1] *TCC0/WO[3] + * | 13 | ~13 | PA17 | LED | EIC/EXTINT[1] PTC/X[5] +SERCOM1/PAD[1] SERCOM3/PAD[1] *TCC2/WO[1] TCC0/WO[7] + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | Analog Connector | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 14 | A0 | PA02 | A0 | EIC/EXTINT[2] *ADC/AIN[0] DAC/VOUT PTC/Y[0] + * | 15 | A1 | PB08 | A1 | EIC/EXTINT[8] *ADC/AIN[2] PTC/Y[14] SERCOM4/PAD[0] TC4/WO[0] + * | 16 | A2 | PB09 | A2 | EIC/EXTINT[9] *ADC/AIN[3] PTC/Y[15] SERCOM4/PAD[1] TC4/WO[1] + * | 17 | A3 | PA04 | A3 | EIC/EXTINT[4] *ADC/AIN[4] AC/AIN[0] PTC/Y[2] SERCOM0/PAD[0] TCC0/WO[0] + * | 18 | A4 | PA05 | A4 | EIC/EXTINT[5] *ADC/AIN[5] AC/AIN[1] PTC/Y[5] SERCOM0/PAD[1] TCC0/WO[1] + * | 19 | A5 | PB02 | A5 | EIC/EXTINT[2] *ADC/AIN[10] PTC/Y[8] SERCOM5/PAD[0] + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | Wire | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 20 | SDA | PA22 | SDA | EIC/EXTINT[6] PTC/X[10] *SERCOM3/PAD[0] SERCOM5/PAD[0] TC4/WO[0] TCC0/WO[4] + * | 21 | SCL | PA23 | SCL | EIC/EXTINT[7] PTC/X[11] *SERCOM3/PAD[1] SERCOM5/PAD[1] TC4/WO[1] TCC0/WO[5] + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | |SPI (Legacy ICSP) | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 22 | 1 | PA12 | MISO | EIC/EXTINT[12] SERCOM2/PAD[0] *SERCOM4/PAD[0] TCC2/WO[0] TCC0/WO[6] + * | | 2 | | 5V0 | + * | 23 | 4 | PB10 | MOSI | EIC/EXTINT[10] *SERCOM4/PAD[2] TC5/WO[0] TCC0/WO[4] + * | 24 | 3 | PB11 | SCK | EIC/EXTINT[11] *SERCOM4/PAD[3] TC5/WO[1] TCC0/WO[5] + * | | 5 | | RESET | + * | | 6 | | GND | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | LEDs | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 25 | | PB03 | RX | + * | 26 | | PA27 | TX | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | USB | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 27 | | PA28 | USB_HOST_ENABLE | EIC/EXTINT[8] + * | 28 | | PA24 | USB_NEGATIVE | *USB/DM + * | 29 | | PA25 | USB_POSITIVE | *USB/DP + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | EDBG | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 30 | | PB22 | EDBG_UART TX | *SERCOM5/PAD[2] + * | 31 | | PB23 | EDBG_UART RX | *SERCOM5/PAD[3] + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 32 | | PA22 | EDBG_SDA | Pin 20 (SDA) + * | 33 | | PA23 | EDBG_SCL | Pin 21 (SCL) + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 34 | | PA19 | EDBG_MISO | EIC/EXTINT[3] *SERCOM1/PAD[3] SERCOM3/PAD[3] TC3/WO[1] TCC0/WO[3] + * | 35 | | PA16 | EDBG_MOSI | EIC/EXTINT[0] *SERCOM1/PAD[0] SERCOM3/PAD[0] TCC2/WO[0] TCC0/WO[6] + * | 36 | | PA18 | EDBG_SS | EIC/EXTINT[2] *SERCOM1/PAD[2] SERCOM3/PAD[2] TC3/WO[0] TCC0/WO[2] + * | 37 | | PA17 | EDBG_SCK | EIC/EXTINT[1] *SERCOM1/PAD[1] SERCOM3/PAD[1] TCC2/WO[1] TCC0/WO[7] + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | 38 | ATN | PA13 | EDBG_GPIO0 | EIC/EXTINT[13] SERCOM2/PAD[1] SERCOM4/PAD[1] *TCC2/WO[1] TCC0/WO[7] + * | 39 | | PA21 | EDBG_GPIO1 | Pin 7 + * | 40 | | PA06 | EDBG_GPIO2 | Pin 8 + * | 41 | | PA07 | EDBG_GPIO3 | Pin 9 + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | GND | | | + * | 42 | AREF | PA03 | | EIC/EXTINT[3] *[ADC|DAC]/VREFA ADC/AIN[1] PTC/Y[1] + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | |32.768KHz Crystal | | | + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + * | | | PA00 | XIN32 | EIC/EXTINT[0] SERCOM1/PAD[0] TCC2/WO[0] + * | | | PA01 | XOUT32 | EIC/EXTINT[1] SERCOM1/PAD[1] TCC2/WO[1] + * +------------+------------------+--------+-----------------+-------------------------------------------------------------------------------------------------------- + */ + + +#include "variant.h" + +/* + * Pins descriptions + */ +const PinDescription g_APinDescription[]= +{ + // 0..13 - Digital pins + // ---------------------- + // 0/1 - SERCOM/UART (Serial1) + { PORTB, 9, PIO_SERCOM_ALT, (PIN_ATTR_PWM|PIN_ATTR_TIMER), ADC_Channel3, PWM4_CH1, TC4_CH1, EXTERNAL_INT_9 }, // GPIO 0 / A6 / UART RX + { PORTB, 8, PIO_SERCOM_ALT, (PIN_ATTR_PWM|PIN_ATTR_TIMER), ADC_Channel2, PWM4_CH0, TC4_CH0, EXTERNAL_INT_8 }, // GPIO 1 / A7 / UART TX + + // 2..12 + // Digital Low + { PORTB, 2, PIO_SERCOM_ALT, 0, ADC_Channel10, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_2 }, // GPIO D2 / A5 / SDA + { PORTB, 3, PIO_SERCOM_ALT, PIN_ATTR_DIGITAL, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_3 }, // GPIO D3 / A4 / SCL + { PORTA, 28, PIO_COM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_8 }, // GPIO D4 / Left Button + { PORTA, 14, PIO_DIGITAL, (PIN_ATTR_DIGITAL), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_14 }, // GPIO D5 / Right button + { PORTA, 5, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), ADC_Channel5, PWM0_CH1, TCC0_CH1, EXTERNAL_INT_5 }, // GPIO D6 / A1 + { PORTA, 15, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM3_CH1, TC3_CH1, EXTERNAL_INT_15 }, // GPIO D7 / Slide Switch + + // Digital High + { PORTB, 23, PIO_DIGITAL, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // GPIO D8 / NeoPixels + { PORTA, 6, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), ADC_Channel6, PWM1_CH0, TCC1_CH0, EXTERNAL_INT_6 }, // GPIO D9 / A2 + { PORTA, 7, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), ADC_Channel7, PWM1_CH1, TCC1_CH1, EXTERNAL_INT_7 }, // GPIO D10 / A3 + { PORTA, 30, PIO_DIGITAL, PIN_ATTR_DIGITAL, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // GPIO D11 / Speaker Shutdown + { PORTA, 2, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG), ADC_Channel0, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_2 }, // GPIO D12 / VOut / A0 + // 13 (LED) + { PORTA, 17, PIO_TIMER, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM2_CH1, TCC2_CH1, EXTERNAL_INT_1 }, // GPIO D13 / Red LED + + // 14..24 - Analog pins + // -------------------- + { PORTA, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG), ADC_Channel0, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_2 }, // A0 (Same as D12) + { PORTA, 5, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG), ADC_Channel5, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_5 }, // A1 (Same as D6) + { PORTA, 6, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER|PIN_ATTR_ANALOG), ADC_Channel6, PWM1_CH0, TCC1_CH0, EXTERNAL_INT_6 }, // A2 (Same as D9) + { PORTA, 7, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER|PIN_ATTR_ANALOG), ADC_Channel7, PWM1_CH1, TCC1_CH1, EXTERNAL_INT_7 }, // A3 (Same as D10 + { PORTB, 3, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG), ADC_Channel11, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // A4 (Same as D3) + { PORTB, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG), ADC_Channel10, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_2 }, // A5 (Same as D2) + { PORTB, 9, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG|PIN_ATTR_PWM|PIN_ATTR_TIMER), ADC_Channel3, PWM4_CH1, TC4_CH1, EXTERNAL_INT_9 }, // A6 (Same as D0) + { PORTB, 8, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG|PIN_ATTR_PWM|PIN_ATTR_TIMER), ADC_Channel2, PWM4_CH0, TC4_CH0, EXTERNAL_INT_8 }, // A7 (Same as D1) + + { PORTA, 11, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG), ADC_Channel19, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_11 }, // A8 / Light Sensor + { PORTA, 9, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER|PIN_ATTR_ANALOG), ADC_Channel17, PWM0_CH1, TCC0_CH1, EXTERNAL_INT_9 }, // A9 / Thermistor + { PORTA, 4, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG), ADC_Channel4, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_4 }, // A10 Proximity + + // GPIO 25 / IR Transmit + { PORTA, 23, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER), No_ADC_Channel, PWM4_CH1, TC4_CH1, EXTERNAL_INT_7 }, // GPIO D25 - IR Transmitter + // GPIO 26 / IR Remote in + { PORTA, 12, PIO_DIGITAL, PIN_ATTR_DIGITAL, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_12 }, // GPIO D26 - IR Receiver + + // GPIO 27 (LIS IRQ) + { PORTA, 13, PIO_PWM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM), No_ADC_Channel, PWM0_CH5, NOT_ON_TIMER, EXTERNAL_INT_13 }, // EIC/EXTINT[13] *TCC2/WO[1] TCC0/WO[7] + + // GPIO 28 & 29 internal I2C (original xtal pins) + { PORTA, 0, PIO_SERCOM_ALT, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // Internal SDA + { PORTA, 1, PIO_SERCOM_ALT, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // Internal SCL + + // GPIO 30, 31, 32 Internal SPI + { PORTA, 16, PIO_SERCOM_ALT, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MISO: SERCOM3/PAD[0] + { PORTA, 21, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM), No_ADC_Channel, PWM0_CH7, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCK: SERCOM3/PAD[3] + { PORTA, 20, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH6, TCC0_CH6, EXTERNAL_INT_4 }, // MOSI: SERCOM3/PAD[2] + + // GPIO 33 (Flash CS) + { PORTB, 22, PIO_DIGITAL, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + + // GPIO 34 (I2S SCK) + { PORTA, 10, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG), ADC_Channel18, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_10 }, + // GPIO 35 (I2S Datain) + { PORTA, 8, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER|PIN_ATTR_ANALOG), ADC_Channel16, PWM0_CH0, TCC0_CH0, EXTERNAL_INT_NMI }, + + + // 36..38 - USB + // -------------------- + { PORTA, 22, PIO_SERCOM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // GPIO 29 - Host USB (not used) + { PORTA, 24, PIO_COM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DM + { PORTA, 25, PIO_COM, PIN_ATTR_NONE, No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DP + +} ; + +extern "C" { + unsigned int PINCOUNT_fn() { + return (sizeof(g_APinDescription) / sizeof(g_APinDescription[0])); + } +} + +const void* g_apTCInstances[TCC_INST_NUM+TC_INST_NUM]={ TCC0, TCC1, TCC2, TC3, TC4, TC5 } ; + +// Multi-serial objects instantiation +SERCOM sercom0( SERCOM0 ) ; +SERCOM sercom1( SERCOM1 ) ; +SERCOM sercom2( SERCOM2 ) ; +SERCOM sercom3( SERCOM3 ) ; +SERCOM sercom4( SERCOM4 ) ; +SERCOM sercom5( SERCOM5 ) ; + +Uart Serial1( &sercom4, PIN_SERIAL1_RX, PIN_SERIAL1_TX, PAD_SERIAL1_RX, PAD_SERIAL1_TX ) ; + +void SERCOM4_Handler() +{ + Serial1.IrqHandler(); +} + diff --git a/variants/circuitplay/variant.h b/variants/circuitplay/variant.h new file mode 100644 index 0000000..6378296 --- /dev/null +++ b/variants/circuitplay/variant.h @@ -0,0 +1,215 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +#pragma once + +// The definitions here needs a SAMD core >=1.6.10 +#define ARDUINO_SAMD_VARIANT_COMPLIANCE 10610 + + +#include + +// General definitions +// ------------------- + +// Frequency of the board main oscillator +#define VARIANT_MAINOSC (32768ul) + +// Master clock frequency +#define VARIANT_MCK (48000000ul) + +// Pins +// ---- + +// Number of pins defined in PinDescription array +#ifdef __cplusplus +extern "C" unsigned int PINCOUNT_fn(); +#endif +#define PINS_COUNT (PINCOUNT_fn()) +#define NUM_DIGITAL_PINS (39u) +#define NUM_ANALOG_INPUTS (11u) +#define NUM_ANALOG_OUTPUTS (1u) + +// Low-level pin register query macros +// ----------------------------------- +#define digitalPinToPort(P) (&(PORT->Group[g_APinDescription[P].ulPort])) +#define digitalPinToBitMask(P) (1 << g_APinDescription[P].ulPin) +//#define analogInPinToBit(P) () +#define portOutputRegister(port) (&(port->OUT.reg)) +#define portInputRegister(port) (&(port->IN.reg)) +#define portModeRegister(port) (&(port->DIR.reg)) +#define digitalPinHasPWM(P) (g_APinDescription[P].ulPWMChannel != NOT_ON_PWM || g_APinDescription[P].ulTCChannel != NOT_ON_TIMER) +#define digitalPinToInterrupt(P) (g_APinDescription[P].ulExtInt) + +/* + * digitalPinToTimer(..) is AVR-specific and is not defined for SAMD + * architecture. If you need to check if a pin supports PWM you must + * use digitalPinHasPWM(..). + * + * https://github.com/arduino/Arduino/issues/1833 + */ +// #define digitalPinToTimer(P) + + +// LEDs +// ---- +#define PIN_LED_13 (13u) +#define PIN_LED PIN_LED_13 +#define LED_BUILTIN PIN_LED + + +//#define PIN_LED_RXL (25u) +//#define PIN_LED_TXL (26u) +//#define PIN_LED2 PIN_LED_RXL +//#define PIN_LED3 PIN_LED_TXL + +/* + * Analog pins + */ +#define PIN_A0 (14ul) +#define PIN_A1 (PIN_A0 + 1) +#define PIN_A2 (PIN_A0 + 2) +#define PIN_A3 (PIN_A0 + 3) +#define PIN_A4 (PIN_A0 + 4) +#define PIN_A5 (PIN_A0 + 5) +#define PIN_A6 (PIN_A0 + 6) +#define PIN_A7 (PIN_A0 + 7) +#define PIN_A8 (PIN_A0 + 8) +#define PIN_A9 (PIN_A0 + 9) +#define PIN_A10 (PIN_A0 + 10) + +#define PIN_DAC0 (PIN_A0) + + +static const uint8_t A0 = PIN_A0; +static const uint8_t A1 = PIN_A1; +static const uint8_t A2 = PIN_A2; +static const uint8_t A3 = PIN_A3; +static const uint8_t A4 = PIN_A4; +static const uint8_t A5 = PIN_A5; +static const uint8_t A6 = PIN_A6 ; +static const uint8_t A7 = PIN_A7 ; +static const uint8_t A8 = PIN_A8 ; +static const uint8_t A9 = PIN_A9 ; +static const uint8_t A10 = PIN_A10 ; +static const uint8_t DAC0 = PIN_DAC0; + +#define ADC_RESOLUTION 12 + +/* + * SPI Interfaces + */ +#define SPI_INTERFACES_COUNT 1 + +#define PIN_SPI_MISO (30u) +#define PIN_SPI_SCK (31u) +#define PIN_SPI_MOSI (32u) +#define PERIPH_SPI sercom3 +#define PAD_SPI_TX SPI_PAD_2_SCK_3 // MOSI / SCK +#define PAD_SPI_RX SERCOM_RX_PAD_0 // MISO + +static const uint8_t SS = 33 ; +static const uint8_t MOSI = PIN_SPI_MOSI ; +static const uint8_t MISO = PIN_SPI_MISO ; +static const uint8_t SCK = PIN_SPI_SCK ; + + +/* + * Wire Interfaces + */ +#define WIRE_INTERFACES_COUNT 2 + + // "external" public i2c interface +#define PIN_WIRE_SDA (2u) +#define PIN_WIRE_SCL (3u) +#define PERIPH_WIRE sercom5 +#define WIRE_IT_HANDLER SERCOM5_Handler +static const uint8_t SDA = PIN_WIRE_SDA; +static const uint8_t SCL = PIN_WIRE_SCL; + + // "internal" lis3dh i2c interface +#define PIN_WIRE1_SDA (28u) +#define PIN_WIRE1_SCL (29u) +#define PERIPH_WIRE1 sercom1 +#define WIRE1_IT_HANDLER SERCOM1_Handler +static const uint8_t SDA1 = PIN_WIRE1_SDA; +static const uint8_t SCL1 = PIN_WIRE1_SCL; + +// USB +// --- +#define PIN_USB_HOST_ENABLE (36ul) +#define PIN_USB_DM (37ul) +#define PIN_USB_DP (38ul) + +// I2S Interfaces +// -------------- +#define I2S_INTERFACES_COUNT 0 + +// Serial ports +// ------------ +#ifdef __cplusplus +#include "SERCOM.h" +#include "Uart.h" + +// Instances of SERCOM +extern SERCOM sercom0; +extern SERCOM sercom1; +extern SERCOM sercom2; +extern SERCOM sercom3; +extern SERCOM sercom4; +extern SERCOM sercom5; + +// Serial1 +extern Uart Serial1; +#define PIN_SERIAL1_RX (0ul) +#define PIN_SERIAL1_TX (1ul) +#define PAD_SERIAL1_TX (UART_TX_PAD_0) +#define PAD_SERIAL1_RX (SERCOM_RX_PAD_1) +#endif // __cplusplus + +#ifdef __cplusplus +extern "C" { +#endif +unsigned int PINCOUNT_fn(); +#ifdef __cplusplus +} +#endif + + +// These serial port names are intended to allow libraries and architecture-neutral +// sketches to automatically default to the correct port name for a particular type +// of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, +// the first hardware serial port whose RX/TX pins are not dedicated to another use. +// +// SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor +// +// SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial +// +// SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library +// +// SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. +// +// SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX +// pins are NOT connected to anything by default. +#define SERIAL_PORT_USBVIRTUAL SerialUSB +#define SERIAL_PORT_MONITOR SerialUSB +#define SERIAL_PORT_HARDWARE Serial1 +#define SERIAL_PORT_HARDWARE_OPEN Serial1 + +// Alias Serial to SerialUSB +#define Serial SerialUSB diff --git a/variants/mkr1000/debug_scripts/variant.gdb b/variants/mkr1000/debug_scripts/variant.gdb new file mode 100644 index 0000000..3c37ffd --- /dev/null +++ b/variants/mkr1000/debug_scripts/variant.gdb @@ -0,0 +1,31 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +# Define 'reset' command +define reset + +info reg + +break main + +# End of 'reset' command +end + +target remote | openocd -c "interface cmsis-dap" -c "set CHIPNAME at91samd21g18" -f target/at91samdXX.cfg -c "gdb_port pipe; log_output openocd.log" diff --git a/variants/mkr1000/linker_scripts/gcc/flash_with_bootloader.ld b/variants/mkr1000/linker_scripts/gcc/flash_with_bootloader.ld new file mode 100644 index 0000000..3579464 --- /dev/null +++ b/variants/mkr1000/linker_scripts/gcc/flash_with_bootloader.ld @@ -0,0 +1,216 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000+0x2000, LENGTH = 0x00040000-0x2000 /* First 8KB used by bootloader */ + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.sketch_boot)) + + . = ALIGN(0x2000); + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(16); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM); + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/mkr1000/linker_scripts/gcc/flash_without_bootloader.ld b/variants/mkr1000/linker_scripts/gcc/flash_without_bootloader.ld new file mode 100644 index 0000000..ebeeee3 --- /dev/null +++ b/variants/mkr1000/linker_scripts/gcc/flash_without_bootloader.ld @@ -0,0 +1,214 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 0x00040000 + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + * __ram_end__ + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(16); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM) ; + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/mkr1000/openocd_scripts/arduino_zero.cfg b/variants/mkr1000/openocd_scripts/arduino_zero.cfg new file mode 100644 index 0000000..36c65c3 --- /dev/null +++ b/variants/mkr1000/openocd_scripts/arduino_zero.cfg @@ -0,0 +1,30 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +source [find interface/cmsis-dap.cfg] + +# chip name +set CHIPNAME at91samd21g18 +set ENDIAN little + +# choose a port here +set telnet_port 0 + +source [find target/at91samdXX.cfg] diff --git a/variants/mkr1000/pins_arduino.h b/variants/mkr1000/pins_arduino.h new file mode 100644 index 0000000..db0e40c --- /dev/null +++ b/variants/mkr1000/pins_arduino.h @@ -0,0 +1,21 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +// API compatibility +#include "variant.h" + diff --git a/variants/mkr1000/variant.cpp b/variants/mkr1000/variant.cpp new file mode 100644 index 0000000..79c2d8e --- /dev/null +++ b/variants/mkr1000/variant.cpp @@ -0,0 +1,186 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +#include "variant.h" + +const PinDescription g_APinDescription[] = { + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 00 | D0 | PA22 | | *06 | | | X10 | | 3/00 | 5/00 |* TC4/0 | TCC0/4 | | GCLK_IO6 | + | 01 | D1 | PA23 | | *07 | | | X11 | | 3/01 | 5/01 |* TC4/1 | TCC0/5 | USB/SOF | GCLK_IO7 | + | 02 | D2 | PA10 | | 10 | *18 | | X02 | | 0/02 | 2/02 |*TCC1/0 | TCC0/2 | I2S/SCK0 | GCLK_IO4 | + | 03 | D3 | PA11 | | 11 | *19 | | X03 | | 0/03 | 2/03 |*TCC1/1 | TCC0/3 | I2S/FS0 | GCLK_IO5 | + | 04 | D4 | PB10 | | *10 | | | | | | 4/02 |* TC5/0 | TCC0/4 | I2S/MCK1 | GCLK_IO4 | + | 05 | D5 | PB11 | | *11 | | | | | | 4/03 |* TC5/1 | TCC0/5 | I2S/SCK1 | GCLK_IO5 | + | 06 | D6 | PA20 | | *04 | | | X08 | | 5/02 | 3/02 | |*TCC0/6 | I2S/SCK0 | GCLK_IO4 | + | 07 | D7 | PA21 | | *05 | | | X09 | | 5/03 | 3/03 | |*TCC0/7 | I2S/FS0 | GCLK_IO5 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 22, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM4_CH0, TC4_CH0, EXTERNAL_INT_6 }, + { PORTA, 23, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM4_CH1, TC4_CH1, EXTERNAL_INT_7 }, + { PORTA, 10, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel18, PWM1_CH0, TCC1_CH0, EXTERNAL_INT_NONE }, + { PORTA, 11, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel19, PWM1_CH1, TCC1_CH1, EXTERNAL_INT_NONE }, + { PORTB, 10, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM5_CH0, TC5_CH0, EXTERNAL_INT_10 }, + { PORTB, 11, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM5_CH1, TC5_CH1, EXTERNAL_INT_11 }, + { PORTA, 20, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH6, TCC0_CH6, EXTERNAL_INT_4 }, + { PORTA, 21, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH7, TCC0_CH7, EXTERNAL_INT_5 }, + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | SPI | | | | | | | | | | | | | | + | 08 | MOSI | PA16 | | *00 | | | X04 | | *1/00 | 3/00 |*TCC2/0 | TCC0/6 | | GCLK_IO2 | + | 09 | SCK | PA17 | | *01 | | | X05 | | *1/01 | 3/01 | TCC2/1 | TCC0/7 | | GCLK_IO3 | + | 10 | MISO | PA19 | | 03 | | | X07 | | *1/03 | 3/03 |* TC3/1 | TCC0/3 | I2S/SD0 | AC/CMP1 | + +------------+------------------+--------+-----------------+--------------------+-----+-----+---------+---------+--------+--------+----------+----------+ + | | Wire | | | | | | | | | | | | | | + | 11 | SDA | PA08 | | NMI | *16 | | X00 | | *0/00 | 2/00 | TCC0/0 | TCC1/2 | I2S/SD1 | | + | 12 | SCL | PA09 | | 09 | *17 | | X01 | | *0/01 | 2/01 | TCC0/1 | TCC1/3 | I2S/MCK0 | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | Serial1 | | | | | | | | | | | | | | + | 13 | RX | PB23 | | 07 | | | | | | *5/03 | | | | GCLK_IO1 | + | 14 | TX | PB22 | | 06 | | | | | | *5/02 | | | | GCLK_IO0 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + // DIPO=3 DOPO=0 + { PORTA, 16, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM2_CH0, TCC2_CH0, EXTERNAL_INT_0 }, // MOSI: SERCOM1/PAD[0] + { PORTA, 17, PIO_SERCOM, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_1 }, // SCK: SERCOM1/PAD[1] + { PORTA, 19, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM3_CH1, TC3_CH1, EXTERNAL_INT_NONE }, // MISO: SERCOM1/PAD[3] + + // PINOUT=0 + { PORTA, 8, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel16, PWM0_CH0, TCC0_CH0, EXTERNAL_INT_NMI }, // SDA: SERCOM4/PAD[0] + { PORTA, 9, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), ADC_Channel17, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCL: SERCOM4/PAD[1] + + // RXPO=3 TXPO=1 + { PORTB, 23, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // RX: SERCOM5/PAD[3] + { PORTB, 22, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // TX: SERCOM5/PAD[2] + + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 15 | A0 / DAC0 | PA02 | | 02 | *00 | | Y00 | OUT | | | | | | | + | 16 | A1 | PB02 | | *02 | *10 | | Y08 | | | 5/00 | | | | | + | 17 | A2 | PB03 | | *03 | *11 | | Y09 | | | 5/01 | | | | | + | 18 | A3 | PA04 | | 04 | *04 | 00 | Y02 | | | 0/00 |*TCC0/0 | | | | + | 19 | A4 | PA05 | | 05 | *05 | 01 | Y03 | | | 0/01 |*TCC0/1 | | | | + | 20 | A5 | PA06 | | 06 | *06 | 02 | Y04 | | | 0/02 | TCC1/0 | | | | + | 21 | A6 | PA07 | | 07 | *07 | 03 | Y05 | | | 0/03 | TCC1/1 | | I2S/SD0 | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG /*DAC*/ ), ADC_Channel0, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel10, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_2 }, + { PORTB, 3, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel11, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_3 }, + { PORTA, 4, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel4, PWM0_CH0, TCC0_CH0, EXTERNAL_INT_NONE }, + { PORTA, 5, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel5, PWM0_CH1, TCC0_CH1, EXTERNAL_INT_NONE }, + { PORTA, 6, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel6, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTA, 7, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel7, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | USB | | | | | | | | | | | | | | + | 22 | | PA24 | USB N | 12 | | | | | 3/02 | 5/02 | TC5/0 | TCC1/2 | USB/DM | | + | 23 | | PA25 | USB P | 13 | | | | | 3/03 | 5/03 | TC5/1 | TCC1/3 | USB/DP | | + | 24 | | PA18 | USB ID | 02 | | | X06 | | 1/02 | 3/02 | TC3/0 | TCC0/2 | | AC/CMP0 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 25 | AREF | PA03 | | 03 | 01 | | Y01 | | | | | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 24, PIO_COM, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DM + { PORTA, 25, PIO_COM, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DP + { PORTA, 18, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + + { PORTA, 3, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // DAC/VREFP + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | ATWINC1501B SPI | | | | | | | | | | | | | | + | 26 | | PA12 | WINC MOSI | 12 | | | | | *2/00 | 4/00 | TCC2/0 | TCC0/6 | | AC/CMP0 | + | 27 | | PA13 | WINC SCK | 13 | | | | | *2/01 | 4/01 | TCC2/1 | TCC0/7 | | AC/CMP1 | + | 28 | | PA14 | WINC SSN | 14 | | | | | 2/02 | 4/02 | TC3/0 | TCC0/4 | | GCLK_IO0 | + | 29 | | PA15 | WINC MISO | 15 | | | | | *2/03 | 4/03 | TC3/1 | TCC0/5 | | GCLK_IO1 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | ATWINC1501B PINS | | | | | | | | | | | | | | + | 30 | | PA27 | WINC RESETN_WIFI| 15 | | | | | | | | | | GCLK_IO0 | + | 31 | | PA28 | WINC CHIP_EN | 08 | | | | | | | | | | GCLK_IO0 | + | 32 | | PB08 | WINC WAKE | 08 | 02 | | Y14 | | | 4/00 | TC4/0 | | | | + | 33 | | PB09 | WINC IRQN | *09 | 03 | | Y15 | | | 4/01 | TC4/1 | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | 32768Hz Crystal | | | | | | | | | | | | | | + | 34 | | PA00 | XIN32 | 00 | | | | | | 1/00 | TCC2/0 | | | | + | 35 | | PA01 | XOUT32 | 01 | | | | | | 1/01 | TCC2/1 | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + // DIPO=3 DOPO=0 + { PORTA, 12, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MOSI: SERCOM4/PAD[0] + { PORTA, 13, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCK: SERCOM4/PAD[1] + { PORTA, 14, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SS: as GPIO + { PORTA, 15, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MISO: SERCOM4/PAD[3] + + { PORTA, 27, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTA, 28, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 8, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 9, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_9 }, + + { PORTA, 0, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTA, 1, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, +}; + +extern "C" { + unsigned int PINCOUNT_fn() { + return (sizeof(g_APinDescription) / sizeof(g_APinDescription[0])); + } +} + +const void* g_apTCInstances[TCC_INST_NUM + TC_INST_NUM]={ TCC0, TCC1, TCC2, TC3, TC4, TC5 }; + +// Multi-serial objects instantiation +SERCOM sercom0(SERCOM0); +SERCOM sercom1(SERCOM1); +SERCOM sercom2(SERCOM2); +SERCOM sercom3(SERCOM3); +SERCOM sercom4(SERCOM4); +SERCOM sercom5(SERCOM5); + +// Serial1 +Uart Serial1(&sercom5, PIN_SERIAL1_RX, PIN_SERIAL1_TX, PAD_SERIAL1_RX, PAD_SERIAL1_TX); + +void SERCOM5_Handler() +{ + Serial1.IrqHandler(); +} + diff --git a/variants/mkr1000/variant.h b/variants/mkr1000/variant.h new file mode 100644 index 0000000..31c5441 --- /dev/null +++ b/variants/mkr1000/variant.h @@ -0,0 +1,212 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +#pragma once + +// The definitions here needs a SAMD core >=1.6.10 +#define ARDUINO_SAMD_VARIANT_COMPLIANCE 10610 + +#include + +// General definitions +// ------------------- + +// Frequency of the board main oscillator +#define VARIANT_MAINOSC (32768ul) + +// Master clock frequency +#define VARIANT_MCK (48000000ul) + +// Pins +// ---- + +// Number of pins defined in PinDescription array +#ifdef __cplusplus +extern "C" unsigned int PINCOUNT_fn(); +#endif +#define PINS_COUNT (PINCOUNT_fn()) +#define NUM_DIGITAL_PINS (22u) +#define NUM_ANALOG_INPUTS (7u) +#define NUM_ANALOG_OUTPUTS (1u) +#define analogInputToDigitalPin(p) ((p < 7u) ? (p) + 15u : -1) + +// Low-level pin register query macros +// ----------------------------------- +#define digitalPinToPort(P) (&(PORT->Group[g_APinDescription[P].ulPort])) +#define digitalPinToBitMask(P) (1 << g_APinDescription[P].ulPin) +//#define analogInPinToBit(P) () +#define portOutputRegister(port) (&(port->OUT.reg)) +#define portInputRegister(port) (&(port->IN.reg)) +#define portModeRegister(port) (&(port->DIR.reg)) +#define digitalPinHasPWM(P) (g_APinDescription[P].ulPWMChannel != NOT_ON_PWM || g_APinDescription[P].ulTCChannel != NOT_ON_TIMER) + +/* + * digitalPinToTimer(..) is AVR-specific and is not defined for SAMD + * architecture. If you need to check if a pin supports PWM you must + * use digitalPinHasPWM(..). + * + * https://github.com/arduino/Arduino/issues/1833 + */ +// #define digitalPinToTimer(P) + +// LEDs +// ---- +#define PIN_LED (6u) +#define LED_BUILTIN PIN_LED + +// Analog pins +// ----------- +#define PIN_A0 (15u) +#define PIN_A1 (16u) +#define PIN_A2 (17u) +#define PIN_A3 (18u) +#define PIN_A4 (19u) +#define PIN_A5 (20u) +#define PIN_A6 (21u) +#define PIN_DAC0 (15u) + +static const uint8_t A0 = PIN_A0; +static const uint8_t A1 = PIN_A1; +static const uint8_t A2 = PIN_A2; +static const uint8_t A3 = PIN_A3; +static const uint8_t A4 = PIN_A4; +static const uint8_t A5 = PIN_A5; +static const uint8_t A6 = PIN_A6; +static const uint8_t DAC0 = PIN_DAC0; +#define ADC_RESOLUTION 12 + +// SPI Interfaces +// -------------- +#define SPI_INTERFACES_COUNT 2 + +// SPI +#define PIN_SPI_MISO (10u) +#define PIN_SPI_MOSI (8u) +#define PIN_SPI_SCK (9u) +#define PIN_SPI_SS (24u) +#define PERIPH_SPI sercom1 +#define PAD_SPI_TX SPI_PAD_0_SCK_1 +#define PAD_SPI_RX SERCOM_RX_PAD_3 +static const uint8_t SS = PIN_SPI_SS; // SPI Slave SS not used. Set here only for reference. +static const uint8_t MOSI = PIN_SPI_MOSI; +static const uint8_t MISO = PIN_SPI_MISO; +static const uint8_t SCK = PIN_SPI_SCK; + +// SPI1: Connected to WINC1501B +#define PIN_SPI1_MISO (29u) +#define PIN_SPI1_MOSI (26u) +#define PIN_SPI1_SCK (27u) +#define PIN_SPI1_SS (28u) +#define PERIPH_SPI1 sercom4 +#define PAD_SPI1_TX SPI_PAD_0_SCK_1 +#define PAD_SPI1_RX SERCOM_RX_PAD_3 +static const uint8_t SS1 = PIN_SPI1_SS; +static const uint8_t MOSI1 = PIN_SPI1_MOSI; +static const uint8_t MISO1 = PIN_SPI1_MISO; +static const uint8_t SCK1 = PIN_SPI1_SCK; + +// Wire Interfaces +// --------------- +#define WIRE_INTERFACES_COUNT 1 + +// Wire +#define PIN_WIRE_SDA (11u) +#define PIN_WIRE_SCL (12u) +#define PERIPH_WIRE sercom2 +#define WIRE_IT_HANDLER SERCOM2_Handler +static const uint8_t SDA = PIN_WIRE_SDA; +static const uint8_t SCL = PIN_WIRE_SCL; + +// USB +// --- +#define PIN_USB_DM (22ul) +#define PIN_USB_DP (23ul) +#define PIN_USB_HOST_ENABLE (24ul) + +// I2S Interfaces +// -------------- +#define I2S_INTERFACES_COUNT 1 + +#define I2S_DEVICE 0 +#define I2S_CLOCK_GENERATOR 3 +#define PIN_I2S_SD (PIN_A6) +#define PIN_I2S_SCK (2u) +#define PIN_I2S_FS (3u) + +// Needed for WINC1501B (WiFi101) library +// -------------------------------------- +#define WINC1501_RESET_PIN (30u) +#define WINC1501_CHIP_EN_PIN (31u) +#define WINC1501_INTN_PIN (33u) +#define WINC1501_SPI SPI1 +#define WINC1501_SPI_CS_PIN PIN_SPI1_SS + + +// Serial ports +// ------------ +#ifdef __cplusplus +#include "SERCOM.h" +#include "Uart.h" + +// Instances of SERCOM +extern SERCOM sercom0; +extern SERCOM sercom1; +extern SERCOM sercom2; +extern SERCOM sercom3; +extern SERCOM sercom4; +extern SERCOM sercom5; + +// Serial1 +extern Uart Serial1; +#define PIN_SERIAL1_RX (13ul) +#define PIN_SERIAL1_TX (14ul) +#define PAD_SERIAL1_TX (UART_TX_PAD_2) +#define PAD_SERIAL1_RX (SERCOM_RX_PAD_3) +#endif // __cplusplus + +#ifdef __cplusplus +extern "C" { +#endif +unsigned int PINCOUNT_fn(); +#ifdef __cplusplus +} +#endif + +// These serial port names are intended to allow libraries and architecture-neutral +// sketches to automatically default to the correct port name for a particular type +// of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, +// the first hardware serial port whose RX/TX pins are not dedicated to another use. +// +// SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor +// +// SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial +// +// SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library +// +// SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. +// +// SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX +// pins are NOT connected to anything by default. +#define SERIAL_PORT_USBVIRTUAL SerialUSB +#define SERIAL_PORT_MONITOR SerialUSB +#define SERIAL_PORT_HARDWARE Serial1 +#define SERIAL_PORT_HARDWARE_OPEN Serial1 + +// Alias Serial to SerialUSB +#define Serial SerialUSB + diff --git a/variants/mkrfox1200/debug_scripts/variant.gdb b/variants/mkrfox1200/debug_scripts/variant.gdb new file mode 100644 index 0000000..3c37ffd --- /dev/null +++ b/variants/mkrfox1200/debug_scripts/variant.gdb @@ -0,0 +1,31 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +# Define 'reset' command +define reset + +info reg + +break main + +# End of 'reset' command +end + +target remote | openocd -c "interface cmsis-dap" -c "set CHIPNAME at91samd21g18" -f target/at91samdXX.cfg -c "gdb_port pipe; log_output openocd.log" diff --git a/variants/mkrfox1200/linker_scripts/gcc/flash_with_bootloader.ld b/variants/mkrfox1200/linker_scripts/gcc/flash_with_bootloader.ld new file mode 100644 index 0000000..3579464 --- /dev/null +++ b/variants/mkrfox1200/linker_scripts/gcc/flash_with_bootloader.ld @@ -0,0 +1,216 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000+0x2000, LENGTH = 0x00040000-0x2000 /* First 8KB used by bootloader */ + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.sketch_boot)) + + . = ALIGN(0x2000); + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(16); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM); + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/mkrfox1200/linker_scripts/gcc/flash_without_bootloader.ld b/variants/mkrfox1200/linker_scripts/gcc/flash_without_bootloader.ld new file mode 100644 index 0000000..ebeeee3 --- /dev/null +++ b/variants/mkrfox1200/linker_scripts/gcc/flash_without_bootloader.ld @@ -0,0 +1,214 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 0x00040000 + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + * __ram_end__ + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(16); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM) ; + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/mkrfox1200/openocd_scripts/arduino_zero.cfg b/variants/mkrfox1200/openocd_scripts/arduino_zero.cfg new file mode 100644 index 0000000..36c65c3 --- /dev/null +++ b/variants/mkrfox1200/openocd_scripts/arduino_zero.cfg @@ -0,0 +1,30 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +source [find interface/cmsis-dap.cfg] + +# chip name +set CHIPNAME at91samd21g18 +set ENDIAN little + +# choose a port here +set telnet_port 0 + +source [find target/at91samdXX.cfg] diff --git a/variants/mkrfox1200/pins_arduino.h b/variants/mkrfox1200/pins_arduino.h new file mode 100644 index 0000000..db0e40c --- /dev/null +++ b/variants/mkrfox1200/pins_arduino.h @@ -0,0 +1,21 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +// API compatibility +#include "variant.h" + diff --git a/variants/mkrfox1200/variant.cpp b/variants/mkrfox1200/variant.cpp new file mode 100644 index 0000000..2c55ed0 --- /dev/null +++ b/variants/mkrfox1200/variant.cpp @@ -0,0 +1,184 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +#include "variant.h" + +const PinDescription g_APinDescription[] = { + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 00 | D0 | PA22 | | *06 | | | X10 | | 3/00 | 5/00 |* TC4/0 | TCC0/4 | | GCLK_IO6 | + | 01 | D1 | PA23 | | *07 | | | X11 | | 3/01 | 5/01 |* TC4/1 | TCC0/5 | USB/SOF | GCLK_IO7 | + | 02 | D2 | PA10 | | 10 | *18 | | X02 | | 0/02 | 2/02 |*TCC1/0 | TCC0/2 | I2S/SCK0 | GCLK_IO4 | + | 03 | D3 | PA11 | | 11 | *19 | | X03 | | 0/03 | 2/03 |*TCC1/1 | TCC0/3 | I2S/FS0 | GCLK_IO5 | + | 04 | D4 | PB10 | | *10 | | | | | | 4/02 |* TC5/0 | TCC0/4 | I2S/MCK1 | GCLK_IO4 | + | 05 | D5 | PB11 | | *11 | | | | | | 4/03 |* TC5/1 | TCC0/5 | I2S/SCK1 | GCLK_IO5 | + | 06 | D6 | PA20 | LED_BUILTIN | *04 | | | X08 | | 5/02 | 3/02 | |*TCC0/6 | I2S/SCK0 | GCLK_IO4 | + | 07 | D7 | PA21 | | *05 | | | X09 | | 5/03 | 3/03 | |*TCC0/7 | I2S/FS0 | GCLK_IO5 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 22, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM4_CH0, TC4_CH0, EXTERNAL_INT_6 }, + { PORTA, 23, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM4_CH1, TC4_CH1, EXTERNAL_INT_7 }, + { PORTA, 10, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel18, PWM1_CH0, TCC1_CH0, EXTERNAL_INT_NONE }, + { PORTA, 11, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel19, PWM1_CH1, TCC1_CH1, EXTERNAL_INT_NONE }, + { PORTB, 10, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM5_CH0, TC5_CH0, EXTERNAL_INT_10 }, + { PORTB, 11, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM5_CH1, TC5_CH1, EXTERNAL_INT_11 }, + { PORTA, 20, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH6, TCC0_CH6, EXTERNAL_INT_4 }, + { PORTA, 21, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH7, TCC0_CH7, EXTERNAL_INT_5 }, + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | SPI | | | | | | | | | | | | | | + | 08 | MOSI | PA16 | | *00 | | | X04 | | *1/00 | 3/00 |*TCC2/0 | TCC0/6 | | GCLK_IO2 | + | 09 | SCK | PA17 | | *01 | | | X05 | | *1/01 | 3/01 | TCC2/1 | TCC0/7 | | GCLK_IO3 | + | 10 | MISO | PA19 | | 03 | | | X07 | | *1/03 | 3/03 |* TC3/1 | TCC0/3 | I2S/SD0 | AC/CMP1 | + +------------+------------------+--------+-----------------+--------------------+-----+-----+---------+---------+--------+--------+----------+----------+ + | | Wire | | | | | | | | | | | | | | + | 11 | SDA | PA08 | | NMI | *16 | | X00 | | *0/00 | 2/00 | TCC0/0 | TCC1/2 | I2S/SD1 | | + | 12 | SCL | PA09 | | 09 | *17 | | X01 | | *0/01 | 2/01 | TCC0/1 | TCC1/3 | I2S/MCK0 | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | Serial1 | | | | | | | | | | | | | | + | 13 | RX | PB23 | | 07 | | | | | | *5/03 | | | | GCLK_IO1 | + | 14 | TX | PB22 | | 06 | | | | | | *5/02 | | | | GCLK_IO0 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + // DIPO=3 DOPO=0 + { PORTA, 16, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM2_CH0, TCC2_CH0, EXTERNAL_INT_0 }, // MOSI: SERCOM1/PAD[0] + { PORTA, 17, PIO_SERCOM, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_1 }, // SCK: SERCOM1/PAD[1] + { PORTA, 19, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM3_CH1, TC3_CH1, EXTERNAL_INT_NONE }, // MISO: SERCOM1/PAD[3] + + // PINOUT=0 + { PORTA, 8, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), ADC_Channel16, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NMI }, // SDA: SERCOM2/PAD[0] + { PORTA, 9, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), ADC_Channel17, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCL: SERCOM2/PAD[1] + + // RXPO=3 TXPO=1 + { PORTB, 23, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // RX: SERCOM5/PAD[3] + { PORTB, 22, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // TX: SERCOM5/PAD[2] + + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 15 | A0 / DAC0 | PA02 | | 02 | *00 | | Y00 | OUT | | | | | | | + | 16 | A1 | PB02 | | *02 | *10 | | Y08 | | | 5/00 | | | | | + | 17 | A2 | PB03 | | *03 | *11 | | Y09 | | | 5/01 | | | | | + | 18 | A3 | PA04 | | 04 | *04 | 00 | Y02 | | | 0/00 |*TCC0/0 | | | | + | 19 | A4 | PA05 | | 05 | *05 | 01 | Y03 | | | 0/01 |*TCC0/1 | | | | + | 20 | A5 | PA06 | | 06 | *06 | 02 | Y04 | | | 0/02 | TCC1/0 | | | | + | 21 | A6 | PA07 | | 07 | *07 | 03 | Y05 | | | 0/03 | TCC1/1 | | I2S/SD0 | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG /*DAC*/ ), ADC_Channel0, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel10, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_2 }, + { PORTB, 3, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel11, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_3 }, + { PORTA, 4, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel4, PWM0_CH0, TCC0_CH0, EXTERNAL_INT_NONE }, + { PORTA, 5, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel5, PWM0_CH1, TCC0_CH1, EXTERNAL_INT_NONE }, + { PORTA, 6, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel6, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTA, 7, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel7, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | USB | | | | | | | | | | | | | | + | 22 | | PA24 | USB N | 12 | | | | | 3/02 | 5/02 | TC5/0 | TCC1/2 | USB/DM | | + | 23 | | PA25 | USB P | 13 | | | | | 3/03 | 5/03 | TC5/1 | TCC1/3 | USB/DP | | + | 24 | | PA18 | USB ID | 02 | | | X06 | | 1/02 | 3/02 | TC3/0 | TCC0/2 | | AC/CMP0 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 25 | AREF | PA03 | | 03 | 01 | | Y01 | | | | | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 24, PIO_COM, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DM + { PORTA, 25, PIO_COM, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DP + { PORTA, 18, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + + { PORTA, 3, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // DAC/VREFP + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | SD SPI | | | | | | | | | | | | | | + | 26 | | PA12 | SIGFOX SCK | 12 | | | | | *2/00 | 4/00 | TCC2/0 | TCC0/6 | | AC/CMP0 | + | 27 | | PA13 | SIGFOX MOSI | 13 | | | | | *2/01 | 4/01 | TCC2/1 | TCC0/7 | | AC/CMP1 | + | 28 | | PA14 | SIGFOX SS | 14 | | | | | 2/02 | 4/02 | TC3/0 | TCC0/4 | | GCLK_IO0 | + | 29 | | PA15 | SIGFOX MISO | 15 | | | | | *2/03 | 4/03 | TC3/1 | TCC0/5 | | GCLK_IO1 | + | 30 | | PA27 | SIGFOX RES | 15 | | | | | | | | | | GCLK_IO0 | + | 31 | | PA28 | SIGFOX PWRON | 08 | | | | | | | | | | GCLK_IO0 | + | 32 | | PB08 | ADC_BATTERY | 08 | 02 | | Y14 | | | 4/00 | TC4/0 | | | | + | 33 | | PB09 | SIGFOX EVENT | *09 | 03 | | Y15 | | | 4/01 | TC4/1 | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | 32768Hz Crystal | | | | | | | | | | | | | | + | 34 | | PA00 | XIN32 | 00 | | | | | | 1/00 | TCC2/0 | | | | + | 35 | | PA01 | XOUT32 | 01 | | | | | | 1/01 | TCC2/1 | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + // DIPO=3 DOPO=0 + { PORTA, 12, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MOSI: SERCOM4/PAD[0] + { PORTA, 13, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCK: SERCOM4/PAD[1] + { PORTA, 14, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SS: as GPIO + { PORTA, 15, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MISO: SERCOM4/PAD[3] + { PORTA, 27, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + + { PORTA, 28, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 8, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG ), ADC_Channel2, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 9, PIO_ANALOG, (PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel3, PWM4_CH1, TC4_CH1, EXTERNAL_INT_9 }, + + { PORTA, 0, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTA, 1, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, +}; + +extern "C" { + unsigned int PINCOUNT_fn() { + return (sizeof(g_APinDescription) / sizeof(g_APinDescription[0])); + } +} + +const void* g_apTCInstances[TCC_INST_NUM + TC_INST_NUM]={ TCC0, TCC1, TCC2, TC3, TC4, TC5 }; + +// Multi-serial objects instantiation +SERCOM sercom0(SERCOM0); +SERCOM sercom1(SERCOM1); +SERCOM sercom2(SERCOM2); +SERCOM sercom3(SERCOM3); +SERCOM sercom4(SERCOM4); +SERCOM sercom5(SERCOM5); + +// Serial1 +Uart Serial1(&sercom5, PIN_SERIAL1_RX, PIN_SERIAL1_TX, PAD_SERIAL1_RX, PAD_SERIAL1_TX); + +void SERCOM5_Handler() +{ + Serial1.IrqHandler(); +} + diff --git a/variants/mkrfox1200/variant.h b/variants/mkrfox1200/variant.h new file mode 100644 index 0000000..ab74eca --- /dev/null +++ b/variants/mkrfox1200/variant.h @@ -0,0 +1,216 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +#pragma once + +// The definitions here needs a SAMD core >=1.6.10 +#define ARDUINO_SAMD_VARIANT_COMPLIANCE 10610 + +#include + +// General definitions +// ------------------- + +// Frequency of the board main oscillator +#define VARIANT_MAINOSC (32768ul) + +// Master clock frequency +#define VARIANT_MCK (48000000ul) + +// Pins +// ---- + +// Number of pins defined in PinDescription array +#ifdef __cplusplus +extern "C" unsigned int PINCOUNT_fn(); +#endif +#define PINS_COUNT (PINCOUNT_fn()) +#define NUM_DIGITAL_PINS (15u) +#define NUM_ANALOG_INPUTS (7u) +#define NUM_ANALOG_OUTPUTS (1u) + +// Low-level pin register query macros +// ----------------------------------- +#define digitalPinToPort(P) (&(PORT->Group[g_APinDescription[P].ulPort])) +#define digitalPinToBitMask(P) (1 << g_APinDescription[P].ulPin) +//#define analogInPinToBit(P) () +#define portOutputRegister(port) (&(port->OUT.reg)) +#define portInputRegister(port) (&(port->IN.reg)) +#define portModeRegister(port) (&(port->DIR.reg)) +#define digitalPinHasPWM(P) (g_APinDescription[P].ulPWMChannel != NOT_ON_PWM || g_APinDescription[P].ulTCChannel != NOT_ON_TIMER) + +/* + * digitalPinToTimer(..) is AVR-specific and is not defined for SAMD + * architecture. If you need to check if a pin supports PWM you must + * use digitalPinHasPWM(..). + * + * https://github.com/arduino/Arduino/issues/1833 + */ +// #define digitalPinToTimer(P) + +//Battery +#define ADC_BATTERY (32u) + +// LEDs +// ---- +#define PIN_LED (6u) +#define LED_BUILTIN PIN_LED + +// Analog pins +// ----------- +#define PIN_A0 (15u) +#define PIN_A1 (16u) +#define PIN_A2 (17u) +#define PIN_A3 (18u) +#define PIN_A4 (19u) +#define PIN_A5 (20u) +#define PIN_A6 (21u) +static const uint8_t A0 = PIN_A0; +static const uint8_t A1 = PIN_A1; +static const uint8_t A2 = PIN_A2; +static const uint8_t A3 = PIN_A3; +static const uint8_t A4 = PIN_A4; +static const uint8_t A5 = PIN_A5; +static const uint8_t A6 = PIN_A6; +#define ADC_RESOLUTION 12 + +// SPI Interfaces +// -------------- +#define SPI_INTERFACES_COUNT 2 + +// SPI +#define PIN_SPI_MISO (10u) +#define PIN_SPI_MOSI (8u) +#define PIN_SPI_SCK (9u) +#define PIN_SPI_SS (4u) +#define PERIPH_SPI sercom1 +#define PAD_SPI_TX SPI_PAD_0_SCK_1 +#define PAD_SPI_RX SERCOM_RX_PAD_3 + +static const uint8_t SS = PIN_SPI_SS; // SPI Slave SS not used. Set here only for reference. +static const uint8_t MOSI = PIN_SPI_MOSI; +static const uint8_t MISO = PIN_SPI_MISO; +static const uint8_t SCK = PIN_SPI_SCK; + +// SPI1: Connected to SIGFOX module +#define PIN_SPI1_MISO (29u) +#define PIN_SPI1_MOSI (26u) +#define PIN_SPI1_SCK (27u) +#define PIN_SPI1_SS (28u) +#define PIN_SIGFOX_RES (30u) +#define PIN_SIGFOX_PWRON (31u) +#define PIN_SIGFOX_EVENT (33u) +#define PERIPH_SPI1 sercom4 +#define PAD_SPI1_TX SPI_PAD_0_SCK_1 +#define PAD_SPI1_RX SERCOM_RX_PAD_3 +static const uint8_t SS1 = PIN_SPI1_SS; +static const uint8_t MOSI1 = PIN_SPI1_MOSI; +static const uint8_t MISO1 = PIN_SPI1_MISO; +static const uint8_t SCK1 = PIN_SPI1_SCK; + +// Needed for SIGFOX module library +#define SIGFOX_SPI SPI1 +#define SIGFOX_MISO_PIN PIN_SPI1_MISO +#define SIGFOX_MOSI_PIN PIN_SPI1_MOSI +#define SIGFOX_SCK_PIN PIN_SPI1_SCK +#define SIGFOX_SS_PIN PIN_SPI1_SS +#define SIGFOX_RES_PIN PIN_SIGFOX_RES +#define SIGFOX_PWRON_PIN PIN_SIGFOX_PWRON +#define SIGFOX_EVENT_PIN PIN_SIGFOX_EVENT + +// Wire Interfaces +// --------------- +#define WIRE_INTERFACES_COUNT 1 + +// Wire +#define PIN_WIRE_SDA (11u) +#define PIN_WIRE_SCL (12u) +#define PERIPH_WIRE sercom2 +#define WIRE_IT_HANDLER SERCOM2_Handler +static const uint8_t SDA = PIN_WIRE_SDA; +static const uint8_t SCL = PIN_WIRE_SCL; + +// USB +// --- +#define PIN_USB_DM (22ul) +#define PIN_USB_DP (23ul) +#define PIN_USB_HOST_ENABLE (24ul) + +// I2S Interfaces +// -------------- +#define I2S_INTERFACES_COUNT 1 + +#define I2S_DEVICE 0 +#define I2S_CLOCK_GENERATOR 3 +#define PIN_I2S_SD (PIN_A6) +#define PIN_I2S_SCK (2u) +#define PIN_I2S_FS (3u) + +// Serial ports +// ------------ +#ifdef __cplusplus +#include "SERCOM.h" +#include "Uart.h" + +// Instances of SERCOM +extern SERCOM sercom0; +extern SERCOM sercom1; +extern SERCOM sercom2; +extern SERCOM sercom3; +extern SERCOM sercom4; +extern SERCOM sercom5; + +// Serial1 +extern Uart Serial1; +#define PIN_SERIAL1_RX (13ul) +#define PIN_SERIAL1_TX (14ul) +#define PAD_SERIAL1_TX (UART_TX_PAD_2) +#define PAD_SERIAL1_RX (SERCOM_RX_PAD_3) +#endif // __cplusplus + +#ifdef __cplusplus +extern "C" { +#endif +unsigned int PINCOUNT_fn(); +#ifdef __cplusplus +} +#endif + +// These serial port names are intended to allow libraries and architecture-neutral +// sketches to automatically default to the correct port name for a particular type +// of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, +// the first hardware serial port whose RX/TX pins are not dedicated to another use. +// +// SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor +// +// SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial +// +// SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library +// +// SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. +// +// SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX +// pins are NOT connected to anything by default. +#define SERIAL_PORT_USBVIRTUAL SerialUSB +#define SERIAL_PORT_MONITOR SerialUSB +#define SERIAL_PORT_HARDWARE Serial1 +#define SERIAL_PORT_HARDWARE_OPEN Serial1 + +// Alias Serial to SerialUSB +#define Serial SerialUSB + diff --git a/variants/mkrgsm1400/debug_scripts/variant.gdb b/variants/mkrgsm1400/debug_scripts/variant.gdb new file mode 100644 index 0000000..3c37ffd --- /dev/null +++ b/variants/mkrgsm1400/debug_scripts/variant.gdb @@ -0,0 +1,31 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +# Define 'reset' command +define reset + +info reg + +break main + +# End of 'reset' command +end + +target remote | openocd -c "interface cmsis-dap" -c "set CHIPNAME at91samd21g18" -f target/at91samdXX.cfg -c "gdb_port pipe; log_output openocd.log" diff --git a/variants/mkrgsm1400/linker_scripts/gcc/flash_with_bootloader.ld b/variants/mkrgsm1400/linker_scripts/gcc/flash_with_bootloader.ld new file mode 100644 index 0000000..5c0dcb4 --- /dev/null +++ b/variants/mkrgsm1400/linker_scripts/gcc/flash_with_bootloader.ld @@ -0,0 +1,217 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000+0x2000, LENGTH = 0x00040000-0x2000 /* First 8KB used by bootloader */ + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.sketch_boot)) + + . = ALIGN(0x2000); + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(16); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM); + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/mkrgsm1400/linker_scripts/gcc/flash_without_bootloader.ld b/variants/mkrgsm1400/linker_scripts/gcc/flash_without_bootloader.ld new file mode 100644 index 0000000..ebeeee3 --- /dev/null +++ b/variants/mkrgsm1400/linker_scripts/gcc/flash_without_bootloader.ld @@ -0,0 +1,214 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 0x00040000 + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + * __ram_end__ + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(16); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM) ; + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/mkrgsm1400/openocd_scripts/arduino_zero.cfg b/variants/mkrgsm1400/openocd_scripts/arduino_zero.cfg new file mode 100644 index 0000000..36c65c3 --- /dev/null +++ b/variants/mkrgsm1400/openocd_scripts/arduino_zero.cfg @@ -0,0 +1,30 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +source [find interface/cmsis-dap.cfg] + +# chip name +set CHIPNAME at91samd21g18 +set ENDIAN little + +# choose a port here +set telnet_port 0 + +source [find target/at91samdXX.cfg] diff --git a/variants/mkrgsm1400/pins_arduino.h b/variants/mkrgsm1400/pins_arduino.h new file mode 100644 index 0000000..db0e40c --- /dev/null +++ b/variants/mkrgsm1400/pins_arduino.h @@ -0,0 +1,21 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +// API compatibility +#include "variant.h" + diff --git a/variants/mkrgsm1400/variant.cpp b/variants/mkrgsm1400/variant.cpp new file mode 100644 index 0000000..2b25934 --- /dev/null +++ b/variants/mkrgsm1400/variant.cpp @@ -0,0 +1,275 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +#include "variant.h" +#include "Arduino.h" + +const PinDescription g_APinDescription[] = { + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 00 | D0 | PA22 | | *06 | | | X10 | | 3/00 | 5/00 |* TC4/0 | TCC0/4 | | GCLK_IO6 | + | 01 | D1 | PA23 | | *07 | | | X11 | | 3/01 | 5/01 |* TC4/1 | TCC0/5 | USB/SOF | GCLK_IO7 | + | 02 | D2 | PA10 | | 10 | *18 | | X02 | | 0/02 | 2/02 |*TCC1/0 | TCC0/2 | I2S/SCK0 | GCLK_IO4 | + | 03 | D3 | PA11 | | 11 | *19 | | X03 | | 0/03 | 2/03 |*TCC1/1 | TCC0/3 | I2S/FS0 | GCLK_IO5 | + | 04 | D4 | PB10 | | *10 | | | | | | 4/02 |* TC5/0 | TCC0/4 | I2S/MCK1 | GCLK_IO4 | + | 05 | D5 | PB11 | | *11 | | | | | | 4/03 |* TC5/1 | TCC0/5 | I2S/SCK1 | GCLK_IO5 | + | 06 | D6 | PA20 | LED_BUILTIN | *04 | | | X08 | | 5/02 | 3/02 | |*TCC0/6 | I2S/SCK0 | GCLK_IO4 | + | 07 | D7 | PA21 | | *05 | | | X09 | | 5/03 | 3/03 | |*TCC0/7 | I2S/FS0 | GCLK_IO5 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 22, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM4_CH0, TC4_CH0, EXTERNAL_INT_6 }, + { PORTA, 23, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM4_CH1, TC4_CH1, EXTERNAL_INT_7 }, + { PORTA, 10, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel18, PWM1_CH0, TCC1_CH0, EXTERNAL_INT_NONE }, + { PORTA, 11, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel19, PWM1_CH1, TCC1_CH1, EXTERNAL_INT_NONE }, + { PORTB, 10, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM5_CH0, TC5_CH0, EXTERNAL_INT_10 }, + { PORTB, 11, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM5_CH1, TC5_CH1, EXTERNAL_INT_11 }, + { PORTA, 20, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH6, TCC0_CH6, EXTERNAL_INT_4 }, + { PORTA, 21, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH7, TCC0_CH7, EXTERNAL_INT_5 }, + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | SPI | | | | | | | | | | | | | | + | 08 | MOSI | PA16 | | *00 | | | X04 | | *1/00 | 3/00 |*TCC2/0 | TCC0/6 | | GCLK_IO2 | + | 09 | SCK | PA17 | | *01 | | | X05 | | *1/01 | 3/01 | TCC2/1 | TCC0/7 | | GCLK_IO3 | + | 10 | MISO | PA19 | | 03 | | | X07 | | *1/03 | 3/03 |* TC3/1 | TCC0/3 | I2S/SD0 | AC/CMP1 | + +------------+------------------+--------+-----------------+--------------------+-----+-----+---------+---------+--------+--------+----------+----------+ + | | Wire | | | | | | | | | | | | | | + | 11 | SDA | PA08 | | NMI | *16 | | X00 | | *0/00 | 2/00 | TCC0/0 | TCC1/2 | I2S/SD1 | | + | 12 | SCL | PA09 | | 09 | *17 | | X01 | | *0/01 | 2/01 | TCC0/1 | TCC1/3 | I2S/MCK0 | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | Serial1 | | | | | | | | | | | | | | + | 13 | RX | PB23 | | 07 | | | | | | *5/03 | | | | GCLK_IO1 | + | 14 | TX | PB22 | | 06 | | | | | | *5/02 | | | | GCLK_IO0 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + // DIPO=3 DOPO=0 + { PORTA, 16, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM2_CH0, TCC2_CH0, EXTERNAL_INT_0 }, // MOSI: SERCOM1/PAD[0] + { PORTA, 17, PIO_SERCOM, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_1 }, // SCK: SERCOM1/PAD[1] + { PORTA, 19, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM3_CH1, TC3_CH1, EXTERNAL_INT_NONE }, // MISO: SERCOM1/PAD[3] + + // PINOUT=0 + { PORTA, 8, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), ADC_Channel16, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NMI }, // SDA: SERCOM2/PAD[0] + { PORTA, 9, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), ADC_Channel17, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCL: SERCOM2/PAD[1] + + // RXPO=3 TXPO=1 + { PORTB, 23, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // RX: SERCOM5/PAD[3] + { PORTB, 22, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // TX: SERCOM5/PAD[2] + + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 15 | A0 / DAC0 | PA02 | | 02 | *00 | | Y00 | OUT | | | | | | | + | 16 | A1 | PB02 | | *02 | *10 | | Y08 | | | 5/00 | | | | | + | 17 | A2 | PB03 | | *03 | *11 | | Y09 | | | 5/01 | | | | | + | 18 | A3 | PA04 | | 04 | *04 | 00 | Y02 | | | 0/00 |*TCC0/0 | | | | + | 19 | A4 | PA05 | | 05 | *05 | 01 | Y03 | | | 0/01 |*TCC0/1 | | | | + | 20 | A5 | PA06 | | 06 | *06 | 02 | Y04 | | | 0/02 | TCC1/0 | | | | + | 21 | A6 | PA07 | | 07 | *07 | 03 | Y05 | | | 0/03 | TCC1/1 | | I2S/SD0 | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG /*DAC*/ ), ADC_Channel0, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel10, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_2 }, + { PORTB, 3, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel11, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_3 }, + { PORTA, 4, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel4, PWM0_CH0, TCC0_CH0, EXTERNAL_INT_NONE }, + { PORTA, 5, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel5, PWM0_CH1, TCC0_CH1, EXTERNAL_INT_NONE }, + { PORTA, 6, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel6, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTA, 7, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel7, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | USB | | | | | | | | | | | | | | + | 22 | | PA24 | USB N | 12 | | | | | 3/02 | 5/02 | TC5/0 | TCC1/2 | USB/DM | | + | 23 | | PA25 | USB P | 13 | | | | | 3/03 | 5/03 | TC5/1 | TCC1/3 | USB/DP | | + | 24 | | PA18 | USB ID | 02 | | | X06 | | 1/02 | 3/02 | TC3/0 | TCC0/2 | | AC/CMP0 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 25 | AREF | PA03 | | 03 | 01 | | Y01 | | | | | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 24, PIO_COM, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DM + { PORTA, 25, PIO_COM, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DP + { PORTA, 18, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + + { PORTA, 3, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // DAC/VREFP + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | SD SPI | | | | | | | | | | | | | | + | 26 | | PA12 | GSM_TX | 12 | | | | | *2/00 | 4/00 | TCC2/0 | TCC0/6 | | AC/CMP0 | + | 27 | | PA13 | GSM_RX | 13 | | | | | *2/01 | 4/01 | TCC2/1 | TCC0/7 | | AC/CMP1 | + | 28 | | PA14 | GSM_RTS | 14 | | | | | 2/02 | 4/02 | TC3/0 | TCC0/4 | | GCLK_IO0 | + | 29 | | PA15 | GSM_CTS | 15 | | | | | *2/03 | 4/03 | TC3/1 | TCC0/5 | | GCLK_IO1 | + | 30 | | PA27 | PMIC_IRQ | *15 | | | | | | | | | | GCLK_IO0 | + | 31 | | PB08 | GSM_RESETN | 08 | 02 | | Y14 | | | 4/00 | TC4/0 | | | | + | 32 | | PB09 | ADC_VBAT | *09 | 03 | | Y15 | | | 4/01 | TC4/1 | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | 32768Hz Crystal | | | | | | | | | | | | | | + | 33 | | PA00 | XIN32 | 00 | | | | | | 1/00 | TCC2/0 | | | | + | 34 | | PA01 | XOUT32 | 01 | | | | | | 1/01 | TCC2/1 | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 35 | | PA28 | GSM_DTR | 01 | | | | | | 1/01 | TCC2/1 | | | | ++------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ +*/ + // DIPO=3 DOPO=0 + { PORTA, 12, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MOSI: SERCOM4/PAD[0] + { PORTA, 13, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCK: SERCOM4/PAD[1] + { PORTA, 14, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SS: as GPIO + { PORTA, 15, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MISO: SERCOM4/PAD[3] + { PORTA, 27, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_15 }, + + { PORTB, 8, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG ), ADC_Channel2, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 9, PIO_ANALOG, (PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel3, PWM4_CH1, TC4_CH1, EXTERNAL_INT_9 }, + + { PORTA, 0, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTA, 1, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + + { PORTA, 28, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, +}; + +extern "C" { + unsigned int PINCOUNT_fn() { + return (sizeof(g_APinDescription) / sizeof(g_APinDescription[0])); + } +} + +const void* g_apTCInstances[TCC_INST_NUM + TC_INST_NUM]={ TCC0, TCC1, TCC2, TC3, TC4, TC5 }; + +// Multi-serial objects instantiation +SERCOM sercom0(SERCOM0); +SERCOM sercom1(SERCOM1); +SERCOM sercom2(SERCOM2); +SERCOM sercom3(SERCOM3); +SERCOM sercom4(SERCOM4); +SERCOM sercom5(SERCOM5); + +#if defined(USE_BQ24195L_PMIC) + +#include "wiring_private.h" + +#define PMIC_ADDRESS 0x6B +#define PMIC_REG01 0x01 +#define PMIC_REG07 0x07 + +#define PMIC_REG00 0x00 + +static inline void set_voltage_current_thresholds() { + PERIPH_WIRE.initMasterWIRE(100000); + PERIPH_WIRE.enableWIRE(); + pinPeripheral(PIN_WIRE_SDA, g_APinDescription[PIN_WIRE_SDA].ulPinType); + pinPeripheral(PIN_WIRE_SCL, g_APinDescription[PIN_WIRE_SCL].ulPinType); + + PERIPH_WIRE.startTransmissionWIRE( PMIC_ADDRESS, WIRE_WRITE_FLAG ); + PERIPH_WIRE.sendDataMasterWIRE(PMIC_REG00); + PERIPH_WIRE.sendDataMasterWIRE(0x07); // input voltage limit = 3.88V, input current limit = 3A + PERIPH_WIRE.prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); + + PERIPH_WIRE.disableWIRE(); +} + +static inline void enable_battery_charging() { + PERIPH_WIRE.initMasterWIRE(100000); + PERIPH_WIRE.enableWIRE(); + pinPeripheral(PIN_WIRE_SDA, g_APinDescription[PIN_WIRE_SDA].ulPinType); + pinPeripheral(PIN_WIRE_SCL, g_APinDescription[PIN_WIRE_SCL].ulPinType); + + PERIPH_WIRE.startTransmissionWIRE( PMIC_ADDRESS, WIRE_WRITE_FLAG ); + PERIPH_WIRE.sendDataMasterWIRE(PMIC_REG01); + PERIPH_WIRE.sendDataMasterWIRE(0x1B); // Charge Battery + Minimum System Voltage 3.5V + PERIPH_WIRE.prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); + + PERIPH_WIRE.disableWIRE(); +} + +static inline void disable_battery_fet(bool disabled) { + PERIPH_WIRE.initMasterWIRE(100000); + PERIPH_WIRE.enableWIRE(); + pinPeripheral(PIN_WIRE_SDA, g_APinDescription[PIN_WIRE_SDA].ulPinType); + pinPeripheral(PIN_WIRE_SCL, g_APinDescription[PIN_WIRE_SCL].ulPinType); + + PERIPH_WIRE.startTransmissionWIRE( PMIC_ADDRESS, WIRE_WRITE_FLAG ); + PERIPH_WIRE.sendDataMasterWIRE(PMIC_REG07); + // No D+/D– detection + Safety timer not slowed by 2X during input DPM or thermal regulation + + // BAT fet disabled/enabled + charge and bat fault INT + PERIPH_WIRE.sendDataMasterWIRE(0x0B | (disabled ? 0x20 : 0x00)); + PERIPH_WIRE.prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); + + PERIPH_WIRE.disableWIRE(); +} + +#endif + +void initVariant() { +#if defined(USE_BQ24195L_PMIC) + pinMode(ADC_BATTERY, OUTPUT); + digitalWrite(ADC_BATTERY, LOW); + delay(10); + pinMode(ADC_BATTERY, INPUT); + delay(100); + + bool batteryPresent = analogRead(ADC_BATTERY) > 600; + if (batteryPresent) { + enable_battery_charging(); + } + disable_battery_fet(!batteryPresent); + set_voltage_current_thresholds(); +#endif + + // put GSM modem in reset on start to conserve power if it's not used + pinMode(GSM_RESETN, OUTPUT); + digitalWrite(GSM_RESETN, HIGH); + + // set GSM DTR to LOW on start + pinMode(PIN_SERIAL2_DTR, OUTPUT); + digitalWrite(PIN_SERIAL2_DTR, LOW); +} + +// Serial1 +Uart Serial1(&sercom5, PIN_SERIAL1_RX, PIN_SERIAL1_TX, PAD_SERIAL1_RX, PAD_SERIAL1_TX); + +void SERCOM5_Handler() +{ + Serial1.IrqHandler(); +} + +// SerialGSM +Uart Serial2(&sercom4, PIN_SERIAL2_RX, PIN_SERIAL2_TX, PAD_SERIAL2_RX, PAD_SERIAL2_TX, PIN_SERIAL2_RTS, PIN_SERIAL2_CTS); + +void SERCOM4_Handler() +{ + Serial2.IrqHandler(); +} diff --git a/variants/mkrgsm1400/variant.h b/variants/mkrgsm1400/variant.h new file mode 100644 index 0000000..63a60af --- /dev/null +++ b/variants/mkrgsm1400/variant.h @@ -0,0 +1,213 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +#pragma once + +// The definitions here needs a SAMD core >=1.6.10 +#define ARDUINO_SAMD_VARIANT_COMPLIANCE 10610 + +#include + +// General definitions +// ------------------- + +// Frequency of the board main oscillator +#define VARIANT_MAINOSC (32768ul) + +// Master clock frequency +#define VARIANT_MCK (48000000ul) + +// Pins +// ---- + +// Number of pins defined in PinDescription array +#ifdef __cplusplus +extern "C" unsigned int PINCOUNT_fn(); +#endif +#define PINS_COUNT (PINCOUNT_fn()) +#define NUM_DIGITAL_PINS (15u) +#define NUM_ANALOG_INPUTS (7u) +#define NUM_ANALOG_OUTPUTS (1u) + +// Low-level pin register query macros +// ----------------------------------- +#define digitalPinToPort(P) (&(PORT->Group[g_APinDescription[P].ulPort])) +#define digitalPinToBitMask(P) (1 << g_APinDescription[P].ulPin) +//#define analogInPinToBit(P) () +#define portOutputRegister(port) (&(port->OUT.reg)) +#define portInputRegister(port) (&(port->IN.reg)) +#define portModeRegister(port) (&(port->DIR.reg)) +#define digitalPinHasPWM(P) (g_APinDescription[P].ulPWMChannel != NOT_ON_PWM || g_APinDescription[P].ulTCChannel != NOT_ON_TIMER) + +/* + * digitalPinToTimer(..) is AVR-specific and is not defined for SAMD + * architecture. If you need to check if a pin supports PWM you must + * use digitalPinHasPWM(..). + * + * https://github.com/arduino/Arduino/issues/1833 + */ +// #define digitalPinToTimer(P) + +//Battery +#define ADC_BATTERY (32u) + +//GSM +#define GSM_RTS (28u) +#define GSM_CTS (29u) +#define GSM_RESETN (31u) +#define GSM_DTR (35u) + +// LEDs +// ---- +#define PIN_LED (6u) +#define LED_BUILTIN PIN_LED + +// Analog pins +// ----------- +#define PIN_A0 (15u) +#define PIN_A1 (16u) +#define PIN_A2 (17u) +#define PIN_A3 (18u) +#define PIN_A4 (19u) +#define PIN_A5 (20u) +#define PIN_A6 (21u) +static const uint8_t A0 = PIN_A0; +static const uint8_t A1 = PIN_A1; +static const uint8_t A2 = PIN_A2; +static const uint8_t A3 = PIN_A3; +static const uint8_t A4 = PIN_A4; +static const uint8_t A5 = PIN_A5; +static const uint8_t A6 = PIN_A6; +#define ADC_RESOLUTION 12 + +// SPI Interfaces +// -------------- +#define SPI_INTERFACES_COUNT 1 + +// SPI +#define PIN_SPI_MISO (10u) +#define PIN_SPI_MOSI (8u) +#define PIN_SPI_SCK (9u) +#define PIN_SPI_SS (4u) +#define PERIPH_SPI sercom1 +#define PAD_SPI_TX SPI_PAD_0_SCK_1 +#define PAD_SPI_RX SERCOM_RX_PAD_3 + +static const uint8_t SS = PIN_SPI_SS; // SPI Slave SS not used. Set here only for reference. +static const uint8_t MOSI = PIN_SPI_MOSI; +static const uint8_t MISO = PIN_SPI_MISO; +static const uint8_t SCK = PIN_SPI_SCK; + +// Wire Interfaces +// --------------- +#define WIRE_INTERFACES_COUNT 1 + +// Wire +#define PIN_WIRE_SDA (11u) +#define PIN_WIRE_SCL (12u) +#define PERIPH_WIRE sercom2 +#define WIRE_IT_HANDLER SERCOM2_Handler +static const uint8_t SDA = PIN_WIRE_SDA; +static const uint8_t SCL = PIN_WIRE_SCL; + +// USB +// --- +#define PIN_USB_DM (22ul) +#define PIN_USB_DP (23ul) +#define PIN_USB_HOST_ENABLE (24ul) +#define PMIC_IRQ_PIN (30ul) + +// I2S Interfaces +// -------------- +#define I2S_INTERFACES_COUNT 1 + +#define I2S_DEVICE 0 +#define I2S_CLOCK_GENERATOR 3 +#define PIN_I2S_SD (PIN_A6) +#define PIN_I2S_SCK (2u) +#define PIN_I2S_FS (3u) + +// Serial ports +// ------------ +#ifdef __cplusplus +#include "SERCOM.h" +#include "Uart.h" + +// Instances of SERCOM +extern SERCOM sercom0; +extern SERCOM sercom1; +extern SERCOM sercom2; +extern SERCOM sercom3; +extern SERCOM sercom4; +extern SERCOM sercom5; + +// Serial1 +extern Uart Serial1; +#define PIN_SERIAL1_RX (13ul) +#define PIN_SERIAL1_TX (14ul) +#define PAD_SERIAL1_TX (UART_TX_PAD_2) +#define PAD_SERIAL1_RX (SERCOM_RX_PAD_3) + +// Serial2 - GSM +extern Uart Serial2; +#define PIN_SERIAL2_RX (27ul) +#define PIN_SERIAL2_TX (26ul) +#define PAD_SERIAL2_TX (UART_TX_RTS_CTS_PAD_0_2_3) +#define PAD_SERIAL2_RX (SERCOM_RX_PAD_1) +#define PIN_SERIAL2_RTS (28u) +#define PIN_SERIAL2_CTS (29u) +#define PIN_SERIAL2_DTR (35u) + +#endif // __cplusplus + +#ifdef __cplusplus +extern "C" { +#endif +unsigned int PINCOUNT_fn(); +#ifdef __cplusplus +} +#endif + +// These serial port names are intended to allow libraries and architecture-neutral +// sketches to automatically default to the correct port name for a particular type +// of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, +// the first hardware serial port whose RX/TX pins are not dedicated to another use. +// +// SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor +// +// SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial +// +// SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library +// +// SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. +// +// SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX +// pins are NOT connected to anything by default. +#define SERIAL_PORT_USBVIRTUAL SerialUSB +#define SERIAL_PORT_MONITOR SerialUSB +#define SERIAL_PORT_HARDWARE Serial1 +#define SERIAL_PORT_HARDWARE_OPEN Serial1 + +// Alias Serial to SerialUSB +#define Serial SerialUSB + +// Alias Serial2 to SerialGSM (useful in libraries) +#define SerialGSM Serial2 + +#define ARDUINO_GSM_COMPATIBILITY_WRAPPER +#define GSM_DEFAULT_STREAM SerialGSM \ No newline at end of file diff --git a/variants/mkrnb1500/debug_scripts/variant.gdb b/variants/mkrnb1500/debug_scripts/variant.gdb new file mode 100644 index 0000000..3c37ffd --- /dev/null +++ b/variants/mkrnb1500/debug_scripts/variant.gdb @@ -0,0 +1,31 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +# Define 'reset' command +define reset + +info reg + +break main + +# End of 'reset' command +end + +target remote | openocd -c "interface cmsis-dap" -c "set CHIPNAME at91samd21g18" -f target/at91samdXX.cfg -c "gdb_port pipe; log_output openocd.log" diff --git a/variants/mkrnb1500/linker_scripts/gcc/flash_with_bootloader.ld b/variants/mkrnb1500/linker_scripts/gcc/flash_with_bootloader.ld new file mode 100644 index 0000000..5c0dcb4 --- /dev/null +++ b/variants/mkrnb1500/linker_scripts/gcc/flash_with_bootloader.ld @@ -0,0 +1,217 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000+0x2000, LENGTH = 0x00040000-0x2000 /* First 8KB used by bootloader */ + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.sketch_boot)) + + . = ALIGN(0x2000); + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(16); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM); + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/mkrnb1500/linker_scripts/gcc/flash_without_bootloader.ld b/variants/mkrnb1500/linker_scripts/gcc/flash_without_bootloader.ld new file mode 100644 index 0000000..ebeeee3 --- /dev/null +++ b/variants/mkrnb1500/linker_scripts/gcc/flash_without_bootloader.ld @@ -0,0 +1,214 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 0x00040000 + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + * __ram_end__ + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(16); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM) ; + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/mkrnb1500/openocd_scripts/arduino_zero.cfg b/variants/mkrnb1500/openocd_scripts/arduino_zero.cfg new file mode 100644 index 0000000..36c65c3 --- /dev/null +++ b/variants/mkrnb1500/openocd_scripts/arduino_zero.cfg @@ -0,0 +1,30 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +source [find interface/cmsis-dap.cfg] + +# chip name +set CHIPNAME at91samd21g18 +set ENDIAN little + +# choose a port here +set telnet_port 0 + +source [find target/at91samdXX.cfg] diff --git a/variants/mkrnb1500/pins_arduino.h b/variants/mkrnb1500/pins_arduino.h new file mode 100644 index 0000000..db0e40c --- /dev/null +++ b/variants/mkrnb1500/pins_arduino.h @@ -0,0 +1,21 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +// API compatibility +#include "variant.h" + diff --git a/variants/mkrnb1500/variant.cpp b/variants/mkrnb1500/variant.cpp new file mode 100644 index 0000000..5e61669 --- /dev/null +++ b/variants/mkrnb1500/variant.cpp @@ -0,0 +1,279 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +#include "variant.h" +#include "Arduino.h" + +const PinDescription g_APinDescription[] = { + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 00 | D0 | PA22 | | *06 | | | X10 | | 3/00 | 5/00 |* TC4/0 | TCC0/4 | | GCLK_IO6 | + | 01 | D1 | PA23 | | *07 | | | X11 | | 3/01 | 5/01 |* TC4/1 | TCC0/5 | USB/SOF | GCLK_IO7 | + | 02 | D2 | PA10 | | 10 | *18 | | X02 | | 0/02 | 2/02 |*TCC1/0 | TCC0/2 | I2S/SCK0 | GCLK_IO4 | + | 03 | D3 | PA11 | | 11 | *19 | | X03 | | 0/03 | 2/03 |*TCC1/1 | TCC0/3 | I2S/FS0 | GCLK_IO5 | + | 04 | D4 | PB10 | | *10 | | | | | | 4/02 |* TC5/0 | TCC0/4 | I2S/MCK1 | GCLK_IO4 | + | 05 | D5 | PB11 | | *11 | | | | | | 4/03 |* TC5/1 | TCC0/5 | I2S/SCK1 | GCLK_IO5 | + | 06 | D6 | PA20 | LED_BUILTIN | *04 | | | X08 | | 5/02 | 3/02 | |*TCC0/6 | I2S/SCK0 | GCLK_IO4 | + | 07 | D7 | PA21 | | *05 | | | X09 | | 5/03 | 3/03 | |*TCC0/7 | I2S/FS0 | GCLK_IO5 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 22, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM4_CH0, TC4_CH0, EXTERNAL_INT_6 }, + { PORTA, 23, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM4_CH1, TC4_CH1, EXTERNAL_INT_7 }, + { PORTA, 10, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel18, PWM1_CH0, TCC1_CH0, EXTERNAL_INT_NONE }, + { PORTA, 11, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel19, PWM1_CH1, TCC1_CH1, EXTERNAL_INT_NONE }, + { PORTB, 10, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM5_CH0, TC5_CH0, EXTERNAL_INT_10 }, + { PORTB, 11, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM5_CH1, TC5_CH1, EXTERNAL_INT_11 }, + { PORTA, 20, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH6, TCC0_CH6, EXTERNAL_INT_4 }, + { PORTA, 21, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH7, TCC0_CH7, EXTERNAL_INT_5 }, + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | SPI | | | | | | | | | | | | | | + | 08 | MOSI | PA16 | | *00 | | | X04 | | *1/00 | 3/00 |*TCC2/0 | TCC0/6 | | GCLK_IO2 | + | 09 | SCK | PA17 | | *01 | | | X05 | | *1/01 | 3/01 | TCC2/1 | TCC0/7 | | GCLK_IO3 | + | 10 | MISO | PA19 | | 03 | | | X07 | | *1/03 | 3/03 |* TC3/1 | TCC0/3 | I2S/SD0 | AC/CMP1 | + +------------+------------------+--------+-----------------+--------------------+-----+-----+---------+---------+--------+--------+----------+----------+ + | | Wire | | | | | | | | | | | | | | + | 11 | SDA | PA08 | | NMI | *16 | | X00 | | *0/00 | 2/00 | TCC0/0 | TCC1/2 | I2S/SD1 | | + | 12 | SCL | PA09 | | 09 | *17 | | X01 | | *0/01 | 2/01 | TCC0/1 | TCC1/3 | I2S/MCK0 | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | Serial1 | | | | | | | | | | | | | | + | 13 | RX | PB23 | | 07 | | | | | | *5/03 | | | | GCLK_IO1 | + | 14 | TX | PB22 | | 06 | | | | | | *5/02 | | | | GCLK_IO0 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + // DIPO=3 DOPO=0 + { PORTA, 16, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM2_CH0, TCC2_CH0, EXTERNAL_INT_0 }, // MOSI: SERCOM1/PAD[0] + { PORTA, 17, PIO_SERCOM, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_1 }, // SCK: SERCOM1/PAD[1] + { PORTA, 19, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM3_CH1, TC3_CH1, EXTERNAL_INT_NONE }, // MISO: SERCOM1/PAD[3] + + // PINOUT=0 + { PORTA, 8, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), ADC_Channel16, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NMI }, // SDA: SERCOM2/PAD[0] + { PORTA, 9, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), ADC_Channel17, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCL: SERCOM2/PAD[1] + + // RXPO=3 TXPO=1 + { PORTB, 23, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // RX: SERCOM5/PAD[3] + { PORTB, 22, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // TX: SERCOM5/PAD[2] + + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 15 | A0 / DAC0 | PA02 | | 02 | *00 | | Y00 | OUT | | | | | | | + | 16 | A1 | PB02 | | *02 | *10 | | Y08 | | | 5/00 | | | | | + | 17 | A2 | PB03 | | *03 | *11 | | Y09 | | | 5/01 | | | | | + | 18 | A3 | PA04 | | 04 | *04 | 00 | Y02 | | | 0/00 |*TCC0/0 | | | | + | 19 | A4 | PA05 | | 05 | *05 | 01 | Y03 | | | 0/01 |*TCC0/1 | | | | + | 20 | A5 | PA06 | | 06 | *06 | 02 | Y04 | | | 0/02 | TCC1/0 | | | | + | 21 | A6 | PA07 | | 07 | *07 | 03 | Y05 | | | 0/03 | TCC1/1 | | I2S/SD0 | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG /*DAC*/ ), ADC_Channel0, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel10, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_2 }, + { PORTB, 3, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel11, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_3 }, + { PORTA, 4, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel4, PWM0_CH0, TCC0_CH0, EXTERNAL_INT_NONE }, + { PORTA, 5, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel5, PWM0_CH1, TCC0_CH1, EXTERNAL_INT_NONE }, + { PORTA, 6, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel6, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTA, 7, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel7, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | USB | | | | | | | | | | | | | | + | 22 | | PA24 | USB N | 12 | | | | | 3/02 | 5/02 | TC5/0 | TCC1/2 | USB/DM | | + | 23 | | PA25 | USB P | 13 | | | | | 3/03 | 5/03 | TC5/1 | TCC1/3 | USB/DP | | + | 24 | | PA18 | USB ID | 02 | | | X06 | | 1/02 | 3/02 | TC3/0 | TCC0/2 | | AC/CMP0 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 25 | AREF | PA03 | | 03 | 01 | | Y01 | | | | | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 24, PIO_COM, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DM + { PORTA, 25, PIO_COM, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DP + { PORTA, 18, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + + { PORTA, 3, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // DAC/VREFP + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | SD SPI | | | | | | | | | | | | | | + | 26 | | PA12 | GSM_TX | 12 | | | | | *2/00 | 4/00 | TCC2/0 | TCC0/6 | | AC/CMP0 | + | 27 | | PA13 | GSM_RX | 13 | | | | | *2/01 | 4/01 | TCC2/1 | TCC0/7 | | AC/CMP1 | + | 28 | | PA14 | GSM_RTS | 14 | | | | | 2/02 | 4/02 | TC3/0 | TCC0/4 | | GCLK_IO0 | + | 29 | | PA15 | GSM_CTS | 15 | | | | | *2/03 | 4/03 | TC3/1 | TCC0/5 | | GCLK_IO1 | + | 30 | | PA27 | PMIC_IRQ | *15 | | | | | | | | | | GCLK_IO0 | + | 31 | | PB08 | GSM_RESETN | 08 | 02 | | Y14 | | | 4/00 | TC4/0 | | | | + | 32 | | PB09 | ADC_VBAT | *09 | 03 | | Y15 | | | 4/01 | TC4/1 | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | 32768Hz Crystal | | | | | | | | | | | | | | + | 33 | | PA00 | XIN32 | 00 | | | | | | 1/00 | TCC2/0 | | | | + | 34 | | PA01 | XOUT32 | 01 | | | | | | 1/01 | TCC2/1 | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 35 | | PA28 | GSM_DTR | 01 | | | | | | 1/01 | TCC2/1 | | | | ++------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ +*/ + // DIPO=3 DOPO=0 + { PORTA, 12, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MOSI: SERCOM4/PAD[0] + { PORTA, 13, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCK: SERCOM4/PAD[1] + { PORTA, 14, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SS: as GPIO + { PORTA, 15, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MISO: SERCOM4/PAD[3] + { PORTA, 27, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_15 }, + + { PORTB, 8, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG ), ADC_Channel2, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 9, PIO_ANALOG, (PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel3, PWM4_CH1, TC4_CH1, EXTERNAL_INT_9 }, + + { PORTA, 0, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTA, 1, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + + { PORTA, 28, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, +}; + +const void* g_apTCInstances[TCC_INST_NUM + TC_INST_NUM]={ TCC0, TCC1, TCC2, TC3, TC4, TC5 }; + +extern "C" { + unsigned int PINCOUNT_fn() { + return (sizeof(g_APinDescription) / sizeof(g_APinDescription[0])); + } +} + +// Multi-serial objects instantiation +SERCOM sercom0(SERCOM0); +SERCOM sercom1(SERCOM1); +SERCOM sercom2(SERCOM2); +SERCOM sercom3(SERCOM3); +SERCOM sercom4(SERCOM4); +SERCOM sercom5(SERCOM5); + +#if defined(USE_BQ24195L_PMIC) + +#include "wiring_private.h" + +#define PMIC_ADDRESS 0x6B +#define PMIC_REG00 0x00 +#define PMIC_REG01 0x01 +#define PMIC_REG07 0x07 + +static inline void enable_battery_charging() { + PERIPH_WIRE.initMasterWIRE(100000); + PERIPH_WIRE.enableWIRE(); + pinPeripheral(PIN_WIRE_SDA, g_APinDescription[PIN_WIRE_SDA].ulPinType); + pinPeripheral(PIN_WIRE_SCL, g_APinDescription[PIN_WIRE_SCL].ulPinType); + + PERIPH_WIRE.startTransmissionWIRE( PMIC_ADDRESS, WIRE_WRITE_FLAG ); + PERIPH_WIRE.sendDataMasterWIRE(PMIC_REG01); + PERIPH_WIRE.sendDataMasterWIRE(0x1B); // Charge Battery + Minimum System Voltage 3.5V + PERIPH_WIRE.prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); + + PERIPH_WIRE.disableWIRE(); +} + +static inline void set_voltage_current_thresholds() { + PERIPH_WIRE.initMasterWIRE(100000); + PERIPH_WIRE.enableWIRE(); + pinPeripheral(PIN_WIRE_SDA, g_APinDescription[PIN_WIRE_SDA].ulPinType); + pinPeripheral(PIN_WIRE_SCL, g_APinDescription[PIN_WIRE_SCL].ulPinType); + + PERIPH_WIRE.startTransmissionWIRE( PMIC_ADDRESS, WIRE_WRITE_FLAG ); + PERIPH_WIRE.sendDataMasterWIRE(PMIC_REG00); + PERIPH_WIRE.sendDataMasterWIRE(0x06); // 3.880 V + 2A ILIM + PERIPH_WIRE.prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); + + PERIPH_WIRE.disableWIRE(); +} + +static inline void disable_battery_fet(bool disabled) { + PERIPH_WIRE.initMasterWIRE(100000); + PERIPH_WIRE.enableWIRE(); + pinPeripheral(PIN_WIRE_SDA, g_APinDescription[PIN_WIRE_SDA].ulPinType); + pinPeripheral(PIN_WIRE_SCL, g_APinDescription[PIN_WIRE_SCL].ulPinType); + + PERIPH_WIRE.startTransmissionWIRE( PMIC_ADDRESS, WIRE_WRITE_FLAG ); + PERIPH_WIRE.sendDataMasterWIRE(PMIC_REG07); + // No D+/D– detection + Safety timer not slowed by 2X during input DPM or thermal regulation + + // BAT fet disabled/enabled + charge and bat fault INT + PERIPH_WIRE.sendDataMasterWIRE(0x0B | (disabled ? 0x20 : 0x00)); + PERIPH_WIRE.prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); + + PERIPH_WIRE.disableWIRE(); +} + +#endif + +void initVariant() { +#if defined(USE_BQ24195L_PMIC) + pinMode(ADC_BATTERY, OUTPUT); + digitalWrite(ADC_BATTERY, LOW); + delay(10); + pinMode(ADC_BATTERY, INPUT); + delay(100); + + bool batteryPresent = analogRead(ADC_BATTERY) > 600; + if (batteryPresent) { + enable_battery_charging(); + } + disable_battery_fet(!batteryPresent); + set_voltage_current_thresholds(); +#endif + + // power off the module + pinMode(SARA_PWR_ON, OUTPUT); + digitalWrite(SARA_PWR_ON, LOW); + + // data sheet discourages use of SARA modem reset pin + // use may lead to irrecoverable state of modem + pinMode(SARA_RESETN, OUTPUT); + digitalWrite(SARA_RESETN, LOW); + + // set RTS to LOW + pinMode(SARA_RTS, OUTPUT); + digitalWrite(SARA_RTS, LOW); +} + +// Serial1 +Uart Serial1(&sercom5, PIN_SERIAL1_RX, PIN_SERIAL1_TX, PAD_SERIAL1_RX, PAD_SERIAL1_TX); + +void SERCOM5_Handler() +{ + Serial1.IrqHandler(); +} + +// SerialSARA +Uart Serial2(&sercom4, PIN_SERIAL2_RX, PIN_SERIAL2_TX, PAD_SERIAL2_RX, PAD_SERIAL2_TX); + +void SERCOM4_Handler() +{ + Serial2.IrqHandler(); +} diff --git a/variants/mkrnb1500/variant.h b/variants/mkrnb1500/variant.h new file mode 100644 index 0000000..8659928 --- /dev/null +++ b/variants/mkrnb1500/variant.h @@ -0,0 +1,203 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +#pragma once + +// The definitions here needs a SAMD core >=1.6.10 +#define ARDUINO_SAMD_VARIANT_COMPLIANCE 10610 + +#include + +// General definitions +// ------------------- + +// Frequency of the board main oscillator +#define VARIANT_MAINOSC (32768ul) + +// Master clock frequency +#define VARIANT_MCK (48000000ul) + +// Pins +// ---- + +// Number of pins defined in PinDescription array +#ifdef __cplusplus +extern "C" unsigned int PINCOUNT_fn(); +#endif +#define PINS_COUNT (PINCOUNT_fn()) +#define NUM_DIGITAL_PINS (15u) +#define NUM_ANALOG_INPUTS (7u) +#define NUM_ANALOG_OUTPUTS (1u) + +// Low-level pin register query macros +// ----------------------------------- +#define digitalPinToPort(P) (&(PORT->Group[g_APinDescription[P].ulPort])) +#define digitalPinToBitMask(P) (1 << g_APinDescription[P].ulPin) +//#define analogInPinToBit(P) () +#define portOutputRegister(port) (&(port->OUT.reg)) +#define portInputRegister(port) (&(port->IN.reg)) +#define portModeRegister(port) (&(port->DIR.reg)) +#define digitalPinHasPWM(P) (g_APinDescription[P].ulPWMChannel != NOT_ON_PWM || g_APinDescription[P].ulTCChannel != NOT_ON_TIMER) + +/* + * digitalPinToTimer(..) is AVR-specific and is not defined for SAMD + * architecture. If you need to check if a pin supports PWM you must + * use digitalPinHasPWM(..). + * + * https://github.com/arduino/Arduino/issues/1833 + */ +// #define digitalPinToTimer(P) + +//Battery +#define ADC_BATTERY (32u) + +//SARA +#define SARA_RTS (28u) +#define SARA_CTS (29u) +#define SARA_RESETN (31u) +#define SARA_DTR (-1) +#define SARA_PWR_ON (35u) + +// LEDs +// ---- +#define PIN_LED (6u) +#define LED_BUILTIN PIN_LED + +// Analog pins +// ----------- +#define PIN_A0 (15u) +#define PIN_A1 (16u) +#define PIN_A2 (17u) +#define PIN_A3 (18u) +#define PIN_A4 (19u) +#define PIN_A5 (20u) +#define PIN_A6 (21u) +static const uint8_t A0 = PIN_A0; +static const uint8_t A1 = PIN_A1; +static const uint8_t A2 = PIN_A2; +static const uint8_t A3 = PIN_A3; +static const uint8_t A4 = PIN_A4; +static const uint8_t A5 = PIN_A5; +static const uint8_t A6 = PIN_A6; +#define ADC_RESOLUTION 12 + +// SPI Interfaces +// -------------- +#define SPI_INTERFACES_COUNT 1 + +// SPI +#define PIN_SPI_MISO (10u) +#define PIN_SPI_MOSI (8u) +#define PIN_SPI_SCK (9u) +#define PIN_SPI_SS (4u) +#define PERIPH_SPI sercom1 +#define PAD_SPI_TX SPI_PAD_0_SCK_1 +#define PAD_SPI_RX SERCOM_RX_PAD_3 + +static const uint8_t SS = PIN_SPI_SS; // SPI Slave SS not used. Set here only for reference. +static const uint8_t MOSI = PIN_SPI_MOSI; +static const uint8_t MISO = PIN_SPI_MISO; +static const uint8_t SCK = PIN_SPI_SCK; + +// Wire Interfaces +// --------------- +#define WIRE_INTERFACES_COUNT 1 + +// Wire +#define PIN_WIRE_SDA (11u) +#define PIN_WIRE_SCL (12u) +#define PERIPH_WIRE sercom2 +#define WIRE_IT_HANDLER SERCOM2_Handler +static const uint8_t SDA = PIN_WIRE_SDA; +static const uint8_t SCL = PIN_WIRE_SCL; + +// USB +// --- +#define PIN_USB_DM (22ul) +#define PIN_USB_DP (23ul) +#define PIN_USB_HOST_ENABLE (24ul) +#define PMIC_IRQ_PIN (30ul) + + +// I2S Interfaces +// -------------- +#define I2S_INTERFACES_COUNT 1 + +#define I2S_DEVICE 0 +#define I2S_CLOCK_GENERATOR 3 +#define PIN_I2S_SD (PIN_A6) +#define PIN_I2S_SCK (2u) +#define PIN_I2S_FS (3u) + +// Serial ports +// ------------ +#ifdef __cplusplus +#include "SERCOM.h" +#include "Uart.h" + +// Instances of SERCOM +extern SERCOM sercom0; +extern SERCOM sercom1; +extern SERCOM sercom2; +extern SERCOM sercom3; +extern SERCOM sercom4; +extern SERCOM sercom5; + +// Serial1 +extern Uart Serial1; +#define PIN_SERIAL1_RX (13ul) +#define PIN_SERIAL1_TX (14ul) +#define PAD_SERIAL1_TX (UART_TX_PAD_2) +#define PAD_SERIAL1_RX (SERCOM_RX_PAD_3) + +// Serial2 - GSM +extern Uart Serial2; +#define PIN_SERIAL2_RX (27ul) +#define PIN_SERIAL2_TX (26ul) +#define PAD_SERIAL2_TX (UART_TX_PAD_0) +#define PAD_SERIAL2_RX (SERCOM_RX_PAD_1) +#define PIN_SERIAL2_RTS (28u) +#define PIN_SERIAL2_CTS (29u) + +#endif // __cplusplus + +// These serial port names are intended to allow libraries and architecture-neutral +// sketches to automatically default to the correct port name for a particular type +// of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, +// the first hardware serial port whose RX/TX pins are not dedicated to another use. +// +// SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor +// +// SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial +// +// SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library +// +// SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. +// +// SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX +// pins are NOT connected to anything by default. +#define SERIAL_PORT_USBVIRTUAL SerialUSB +#define SERIAL_PORT_MONITOR SerialUSB +#define SERIAL_PORT_HARDWARE Serial1 +#define SERIAL_PORT_HARDWARE_OPEN Serial1 + +// Alias Serial to SerialUSB +#define Serial SerialUSB + +// Alias Serial2 to SerialSARA (useful in libraries) +#define SerialSARA Serial2 diff --git a/variants/mkrvidor4000/clockout.c b/variants/mkrvidor4000/clockout.c new file mode 100644 index 0000000..e32fabb --- /dev/null +++ b/variants/mkrvidor4000/clockout.c @@ -0,0 +1,30 @@ +#include "variant.h" + +void clockout(uint32_t gclk, int32_t divisor) +{ + GCLK_GENDIV_Type gendiv = + { + .bit.DIV = divisor, // divider, linear or 2^(.DIV+1) + .bit.ID = gclk, // GCLK_GENERATOR_"gclk" + }; + GCLK->GENDIV.reg = gendiv.reg; + + // setup Clock Generator + GCLK_GENCTRL_Type genctrl = + { + .bit.RUNSTDBY = 0, // Run in Standby + .bit.DIVSEL = 0, // .DIV (above) Selection: 0=linear 1=powers of 2 + .bit.OE = 1, // Output Enable to observe on any port pin capable of outputting GCLK_IO["gclk"] + .bit.OOV = 0, // Output Off Value + .bit.IDC = 1, // Improve Duty Cycle + .bit.GENEN = 1, // enable this GCLK + //.bit.SRC = GCLK_SOURCE_OSC8M, + .bit.SRC = GCLK_SOURCE_DFLL48M, // select GCLK source + .bit.ID = gclk, // output GCLK_GENERATOR_"gclk" on GCLK_IO["gclk"] + }; + GCLK->GENCTRL.reg = genctrl.reg; + while ( GCLK->STATUS.reg & GCLK_STATUS_SYNCBUSY ) + { + /* Wait for synchronization */ + } +} diff --git a/variants/mkrvidor4000/debug_scripts/variant.gdb b/variants/mkrvidor4000/debug_scripts/variant.gdb new file mode 100644 index 0000000..3c37ffd --- /dev/null +++ b/variants/mkrvidor4000/debug_scripts/variant.gdb @@ -0,0 +1,31 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +# Define 'reset' command +define reset + +info reg + +break main + +# End of 'reset' command +end + +target remote | openocd -c "interface cmsis-dap" -c "set CHIPNAME at91samd21g18" -f target/at91samdXX.cfg -c "gdb_port pipe; log_output openocd.log" diff --git a/variants/mkrvidor4000/linker_scripts/gcc/flash_with_bootloader.ld b/variants/mkrvidor4000/linker_scripts/gcc/flash_with_bootloader.ld new file mode 100644 index 0000000..34ebeed --- /dev/null +++ b/variants/mkrvidor4000/linker_scripts/gcc/flash_with_bootloader.ld @@ -0,0 +1,223 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH_FPGA (r) : ORIGIN = 0x00040000, LENGTH = 0x00200000 + FLASH (rx) : ORIGIN = 0x00000000+0x2000, LENGTH = 0x00040000-0x2000 /* First 8KB used by bootloader */ + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.sketch_boot)) + + . = ALIGN(0x2000); + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .fpga_bitstream_section : + { + KEEP(*(.fpga_bitstream_signature)) + KEEP(*(.fpga_bitstream)) + } > FLASH_FPGA + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(16); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM); + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/mkrvidor4000/linker_scripts/gcc/flash_without_bootloader.ld b/variants/mkrvidor4000/linker_scripts/gcc/flash_without_bootloader.ld new file mode 100644 index 0000000..ebeeee3 --- /dev/null +++ b/variants/mkrvidor4000/linker_scripts/gcc/flash_without_bootloader.ld @@ -0,0 +1,214 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 0x00040000 + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + * __ram_end__ + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(16); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM) ; + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/mkrvidor4000/openocd_scripts/arduino_zero.cfg b/variants/mkrvidor4000/openocd_scripts/arduino_zero.cfg new file mode 100644 index 0000000..36c65c3 --- /dev/null +++ b/variants/mkrvidor4000/openocd_scripts/arduino_zero.cfg @@ -0,0 +1,30 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +source [find interface/cmsis-dap.cfg] + +# chip name +set CHIPNAME at91samd21g18 +set ENDIAN little + +# choose a port here +set telnet_port 0 + +source [find target/at91samdXX.cfg] diff --git a/variants/mkrvidor4000/pins_arduino.h b/variants/mkrvidor4000/pins_arduino.h new file mode 100644 index 0000000..db0e40c --- /dev/null +++ b/variants/mkrvidor4000/pins_arduino.h @@ -0,0 +1,21 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +// API compatibility +#include "variant.h" + diff --git a/variants/mkrvidor4000/variant.cpp b/variants/mkrvidor4000/variant.cpp new file mode 100644 index 0000000..3a4ece4 --- /dev/null +++ b/variants/mkrvidor4000/variant.cpp @@ -0,0 +1,258 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +#include "variant.h" +#include "Arduino.h" + +const PinDescription g_APinDescription[] = { + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 00 | D0 | PA22 | | *06 | | | X10 | | 3/00 | 5/00 |* TC4/0 | TCC0/4 | | GCLK_IO6 | + | 01 | D1 | PA23 | | *07 | | | X11 | | 3/01 | 5/01 |* TC4/1 | TCC0/5 | USB/SOF | GCLK_IO7 | + | 02 | D2 | PA10 | | 10 | *18 | | X02 | | 0/02 | 2/02 |*TCC1/0 | TCC0/2 | I2S/SCK0 | GCLK_IO4 | + | 03 | D3 | PA11 | | 11 | *19 | | X03 | | 0/03 | 2/03 |*TCC1/1 | TCC0/3 | I2S/FS0 | GCLK_IO5 | + | 04 | D4 | PB10 | | *10 | | | | | | 4/02 |* TC5/0 | TCC0/4 | I2S/MCK1 | GCLK_IO4 | + | 05 | D5 | PB11 | | *11 | | | | | | 4/03 |* TC5/1 | TCC0/5 | I2S/SCK1 | GCLK_IO5 | + | 06 | D6 | PA20 | | *04 | | | X08 | | 5/02 | 3/02 | |*TCC0/6 | I2S/SCK0 | GCLK_IO4 | + | 07 | D7 | PA21 | | *05 | | | X09 | | 5/03 | 3/03 | |*TCC0/7 | I2S/FS0 | GCLK_IO5 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 22, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM4_CH0, TC4_CH0, EXTERNAL_INT_6 }, + { PORTA, 23, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM4_CH1, TC4_CH1, EXTERNAL_INT_7 }, + { PORTA, 10, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel18, PWM1_CH0, TCC1_CH0, EXTERNAL_INT_NONE }, + { PORTA, 11, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel19, PWM1_CH1, TCC1_CH1, EXTERNAL_INT_NONE }, + { PORTB, 10, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM5_CH0, TC5_CH0, EXTERNAL_INT_10 }, + { PORTB, 11, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM5_CH1, TC5_CH1, EXTERNAL_INT_11 }, + { PORTA, 20, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH6, TCC0_CH6, EXTERNAL_INT_4 }, + { PORTA, 21, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH7, TCC0_CH7, EXTERNAL_INT_5 }, + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | SPI | | | | | | | | | | | | | | + | 08 | MOSI | PA16 | | *00 | | | X04 | | *1/00 | 3/00 |*TCC2/0 | TCC0/6 | | GCLK_IO2 | + | 09 | SCK | PA17 | | *01 | | | X05 | | *1/01 | 3/01 | TCC2/1 | TCC0/7 | | GCLK_IO3 | + | 10 | MISO | PA19 | | 03 | | | X07 | | *1/03 | 3/03 |* TC3/1 | TCC0/3 | I2S/SD0 | AC/CMP1 | + +------------+------------------+--------+-----------------+--------------------+-----+-----+---------+---------+--------+--------+----------+----------+ + | | Wire | | | | | | | | | | | | | | + | 11 | SDA | PA08 | | NMI | *16 | | X00 | | *0/00 | 2/00 | TCC0/0 | TCC1/2 | I2S/SD1 | | + | 12 | SCL | PA09 | | 09 | *17 | | X01 | | *0/01 | 2/01 | TCC0/1 | TCC1/3 | I2S/MCK0 | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | Serial1 | | | | | | | | | | | | | | + | 13 | RX | PB23 | | 07 | | | | | | *5/03 | | | | GCLK_IO1 | + | 14 | TX | PB22 | | 06 | | | | | | *5/02 | | | | GCLK_IO0 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + // DIPO=3 DOPO=0 + { PORTA, 16, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM2_CH0, TCC2_CH0, EXTERNAL_INT_0 }, // MOSI: SERCOM1/PAD[0] + { PORTA, 17, PIO_SERCOM, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_1 }, // SCK: SERCOM1/PAD[1] + { PORTA, 19, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM3_CH1, TC3_CH1, EXTERNAL_INT_NONE }, // MISO: SERCOM1/PAD[3] + + // PINOUT=0 + { PORTA, 8, PIO_SERCOM, (PIN_ATTR_DIGITAL ), ADC_Channel16, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NMI }, // SDA: SERCOM0/PAD[0] + { PORTA, 9, PIO_SERCOM, (PIN_ATTR_DIGITAL ), ADC_Channel17, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCL: SERCOM0/PAD[1] + + // RXPO=3 TXPO=1 + { PORTB, 23, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // RX: SERCOM5/PAD[3] + { PORTB, 22, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // TX: SERCOM5/PAD[2] + + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 15 | A0 / DAC0 | PA02 | | 02 | *00 | | Y00 | OUT | | | | | | | + | 16 | A1 | PB02 | | *02 | *10 | | Y08 | | | 5/00 | | | | | + | 17 | A2 | PB03 | | *03 | *11 | | Y09 | | | 5/01 | | | | | + | 18 | A3 | PA04 | | 04 | *04 | 00 | Y02 | | | 0/00 |*TCC0/0 | | | | + | 19 | A4 | PA05 | | 05 | *05 | 01 | Y03 | | | 0/01 |*TCC0/1 | | | | + | 20 | A5 | PA06 | | 06 | *06 | 02 | Y04 | | | 0/02 | TCC1/0 | | | | + | 21 | A6 | PA07 | | 07 | *07 | 03 | Y05 | | | 0/03 | TCC1/1 | | I2S/SD0 | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG /*DAC*/ ), ADC_Channel0, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel10, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_2 }, + { PORTB, 3, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel11, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_3 }, + { PORTA, 4, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel4, PWM0_CH0, TCC0_CH0, EXTERNAL_INT_NONE }, + { PORTA, 5, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel5, PWM0_CH1, TCC0_CH1, EXTERNAL_INT_NONE }, + { PORTA, 6, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel6, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTA, 7, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel7, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | USB | | | | | | | | | | | | | | + | 22 | | PA24 | USB N | 12 | | | | | 3/02 | 5/02 | TC5/0 | TCC1/2 | USB/DM | | + | 23 | | PA25 | USB P | 13 | | | | | 3/03 | 5/03 | TC5/1 | TCC1/3 | USB/DP | | + | 24 | | PA18 | USB ID | 02 | | | X06 | | 1/02 | 3/02 | TC3/0 | TCC0/2 | | AC/CMP0 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 25 | AREF | PA03 | | 03 | 01 | | Y01 | | | | | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 24, PIO_COM, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DM + { PORTA, 25, PIO_COM, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DP + { PORTA, 18, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + + { PORTA, 3, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // DAC/VREFP + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | FPGA | | | | | | | | | | | | | | + | 26 | | PA12 | FPGA TDI | 12 | | | | | *2/00 | 4/00 | TCC2/0 | TCC0/6 | | AC/CMP0 | + | 27 | | PA13 | FPGA TCK | 13 | | | | | *2/01 | 4/01 | TCC2/1 | TCC0/7 | | AC/CMP1 | + | 28 | | PA14 | FPGA TMS | 14 | | | | | 2/02 | 4/02 | TC3/0 | TCC0/4 | | GCLK_IO0 | + | 29 | | PA15 | FPGA TDO | 15 | | | | | *2/03 | 4/03 | TC3/1 | TCC0/5 | | GCLK_IO1 | + | 30 | | PA27 | FPGA CLK | 15 | | | | | | | | | | GCLK_IO0 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 31 | | PA28 | FPGA MB INT | 08 | | | | | | | | | | GCLK_IO0 | + | 32 | | PB08 | LED_RED_BUILTIN | 08 | 02 | | Y14 | | | 4/00 | TC4/0 | | | | + | 33 | | PB09 | SAM_INT_OUT | *09 | 03 | | Y15 | | | 4/01 | TC4/1 | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | 32768Hz Crystal | | | | | | | | | | | | | | + | 34 | | PA00 | XIN32 | 00 | | | | | | 1/00 | TCC2/0 | | | | + | 35 | | PA01 | XOUT32 | 01 | | | | | | 1/01 | TCC2/1 | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + // DIPO=3 DOPO=0 + { PORTA, 12, PIO_SERCOM, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MOSI: SERCOM2/PAD[0] + { PORTA, 13, PIO_SERCOM, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCK: SERCOM2/PAD[1] + { PORTA, 14, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SS: as GPIO + { PORTA, 15, PIO_SERCOM, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MISO: SERCOM2/PAD[3] + { PORTA, 27, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + + { PORTA, 28, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 8, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 9, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel3, PWM4_CH1, TC4_CH1, EXTERNAL_INT_9 }, + + { PORTA, 0, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTA, 1, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, +}; + +const void* g_apTCInstances[TCC_INST_NUM + TC_INST_NUM]={ TCC0, TCC1, TCC2, TC3, TC4, TC5 }; + +extern "C" { + unsigned int PINCOUNT_fn() { + return (sizeof(g_APinDescription) / sizeof(g_APinDescription[0])); + } +} + +#if defined(USE_BQ24195L_PMIC) + +#include "wiring_private.h" + +#define PMIC_ADDRESS 0x6B +#define PMIC_REG00 0x00 +#define PMIC_REG01 0x01 +#define PMIC_REG07 0x07 + +static inline void enable_battery_charging() { + PERIPH_WIRE.initMasterWIRE(100000); + PERIPH_WIRE.enableWIRE(); + pinPeripheral(PIN_WIRE_SDA, g_APinDescription[PIN_WIRE_SDA].ulPinType); + pinPeripheral(PIN_WIRE_SCL, g_APinDescription[PIN_WIRE_SCL].ulPinType); + + bool ret = PERIPH_WIRE.startTransmissionWIRE( PMIC_ADDRESS, WIRE_WRITE_FLAG ); + if (!ret) { + return; + } + PERIPH_WIRE.sendDataMasterWIRE(PMIC_REG01); + PERIPH_WIRE.sendDataMasterWIRE(0x1B); // Charge Battery + Minimum System Voltage 3.5V + PERIPH_WIRE.prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); + + PERIPH_WIRE.disableWIRE(); +} + +static inline void disable_battery_fet(bool disabled) { + PERIPH_WIRE.initMasterWIRE(100000); + PERIPH_WIRE.enableWIRE(); + pinPeripheral(PIN_WIRE_SDA, g_APinDescription[PIN_WIRE_SDA].ulPinType); + pinPeripheral(PIN_WIRE_SCL, g_APinDescription[PIN_WIRE_SCL].ulPinType); + + PERIPH_WIRE.startTransmissionWIRE( PMIC_ADDRESS, WIRE_WRITE_FLAG ); + PERIPH_WIRE.sendDataMasterWIRE(PMIC_REG07); + // No D+/D– detection + Safety timer not slowed by 2X during input DPM or thermal regulation + + // BAT fet disabled/enabled + charge and bat fault INT + PERIPH_WIRE.sendDataMasterWIRE(0x0B | (disabled ? 0x20 : 0x00)); + PERIPH_WIRE.prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); + + PERIPH_WIRE.startTransmissionWIRE( PMIC_ADDRESS, WIRE_WRITE_FLAG ); + PERIPH_WIRE.sendDataMasterWIRE(PMIC_REG00); + PERIPH_WIRE.sendDataMasterWIRE(0x6 | 0x30); + PERIPH_WIRE.prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); + + PERIPH_WIRE.disableWIRE(); +} + +#endif + +void initVariant() { +#if defined(USE_BQ24195L_PMIC) + enable_battery_charging(); +#endif + startFPGA(); +} + +void enableFpgaClock() { + // Will be called by the Vidor library begin() + pinPeripheral(30, PIO_AC_CLK); + clockout(0, 1); + delay(1000); +} + +void disableFpgaClock() { + // Will be called by the Vidor library end() + pinPeripheral(30, PIO_INPUT); + //clockout(0, 1); + delay(1000); +} + + __attribute__ ((weak)) void startFPGA() {}; + +// Multi-serial objects instantiation +SERCOM sercom0(SERCOM0); +SERCOM sercom1(SERCOM1); +SERCOM sercom2(SERCOM2); +SERCOM sercom3(SERCOM3); +SERCOM sercom4(SERCOM4); +SERCOM sercom5(SERCOM5); + +// Serial1 +Uart Serial1(&sercom5, PIN_SERIAL1_RX, PIN_SERIAL1_TX, PAD_SERIAL1_RX, PAD_SERIAL1_TX); + +void SERCOM5_Handler() +{ + Serial1.IrqHandler(); +} + diff --git a/variants/mkrvidor4000/variant.h b/variants/mkrvidor4000/variant.h new file mode 100644 index 0000000..17ffeef --- /dev/null +++ b/variants/mkrvidor4000/variant.h @@ -0,0 +1,201 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +#pragma once + +// The definitions here needs a SAMD core >=1.6.10 +#define ARDUINO_SAMD_VARIANT_COMPLIANCE 10610 + +#include + +// General definitions +// ------------------- + +// Frequency of the board main oscillator +#define VARIANT_MAINOSC (32768ul) + +// Master clock frequency +#define VARIANT_MCK (48000000ul) + +// Pins +// ---- + +// Number of pins defined in PinDescription array +#ifdef __cplusplus +extern "C" unsigned int PINCOUNT_fn(); +#endif +#define PINS_COUNT (PINCOUNT_fn()) +#define NUM_DIGITAL_PINS (15u) +#define NUM_ANALOG_INPUTS (7u) +#define NUM_ANALOG_OUTPUTS (1u) + +// Low-level pin register query macros +// ----------------------------------- +#define digitalPinToPort(P) (&(PORT->Group[g_APinDescription[P].ulPort])) +#define digitalPinToBitMask(P) (1 << g_APinDescription[P].ulPin) +//#define analogInPinToBit(P) () +#define portOutputRegister(port) (&(port->OUT.reg)) +#define portInputRegister(port) (&(port->IN.reg)) +#define portModeRegister(port) (&(port->DIR.reg)) +#define digitalPinHasPWM(P) (g_APinDescription[P].ulPWMChannel != NOT_ON_PWM || g_APinDescription[P].ulTCChannel != NOT_ON_TIMER) + +/* + * digitalPinToTimer(..) is AVR-specific and is not defined for SAMD + * architecture. If you need to check if a pin supports PWM you must + * use digitalPinHasPWM(..). + * + * https://github.com/arduino/Arduino/issues/1833 + */ +// #define digitalPinToTimer(P) + +// LEDs +// ---- +#define PIN_LED (32u) +#define LED_BUILTIN PIN_LED + +// Analog pins +// ----------- +#define PIN_A0 (15u) +#define PIN_A1 (16u) +#define PIN_A2 (17u) +#define PIN_A3 (18u) +#define PIN_A4 (19u) +#define PIN_A5 (20u) +#define PIN_A6 (21u) +static const uint8_t A0 = PIN_A0; +static const uint8_t A1 = PIN_A1; +static const uint8_t A2 = PIN_A2; +static const uint8_t A3 = PIN_A3; +static const uint8_t A4 = PIN_A4; +static const uint8_t A5 = PIN_A5; +static const uint8_t A6 = PIN_A6; +#define ADC_RESOLUTION 12 + +// SPI Interfaces +// -------------- +#define SPI_INTERFACES_COUNT 2 + +// SPI +#define PIN_SPI_MISO (10u) +#define PIN_SPI_MOSI (8u) +#define PIN_SPI_SCK (9u) +#define PIN_SPI_SS (4u) +#define PERIPH_SPI sercom1 +#define PAD_SPI_TX SPI_PAD_0_SCK_1 +#define PAD_SPI_RX SERCOM_RX_PAD_3 + +static const uint8_t SS = PIN_SPI_SS; // SPI Slave SS not used. Set here only for reference. +static const uint8_t MOSI = PIN_SPI_MOSI; +static const uint8_t MISO = PIN_SPI_MISO; +static const uint8_t SCK = PIN_SPI_SCK; + +// SPI1: Connected to FPGA JTAG +#define PIN_SPI1_MISO (29u) +#define PIN_SPI1_MOSI (26u) +#define PIN_SPI1_SCK (27u) +#define PIN_SPI1_SS (28u) +#define PERIPH_SPI1 sercom2 +#define PAD_SPI1_TX SPI_PAD_0_SCK_1 +#define PAD_SPI1_RX SERCOM_RX_PAD_3 +static const uint8_t SS1 = PIN_SPI1_SS; +static const uint8_t MOSI1 = PIN_SPI1_MOSI; +static const uint8_t MISO1 = PIN_SPI1_MISO; +static const uint8_t SCK1 = PIN_SPI1_SCK; + +// Wire Interfaces +// --------------- +#define WIRE_INTERFACES_COUNT 1 + +// Wire +#define PIN_WIRE_SDA (11u) +#define PIN_WIRE_SCL (12u) +#define PERIPH_WIRE sercom0 +#define WIRE_IT_HANDLER SERCOM0_Handler +static const uint8_t SDA = PIN_WIRE_SDA; +static const uint8_t SCL = PIN_WIRE_SCL; + +// USB +// --- +#define PIN_USB_DM (22ul) +#define PIN_USB_DP (23ul) +#define PIN_USB_HOST_ENABLE (24ul) + +// I2S Interfaces +// -------------- +#define I2S_INTERFACES_COUNT 1 + +#define I2S_DEVICE 0 +#define I2S_CLOCK_GENERATOR 3 +#define PIN_I2S_SD (PIN_A6) +#define PIN_I2S_SCK (2u) +#define PIN_I2S_FS (3u) + +// Serial ports +// ------------ +#ifdef __cplusplus +#include "SERCOM.h" +#include "Uart.h" + +// Instances of SERCOM +extern SERCOM sercom0; +extern SERCOM sercom1; +extern SERCOM sercom2; +extern SERCOM sercom3; +extern SERCOM sercom4; +extern SERCOM sercom5; + +// Serial1 +extern Uart Serial1; +#define PIN_SERIAL1_RX (13ul) +#define PIN_SERIAL1_TX (14ul) +#define PAD_SERIAL1_TX (UART_TX_PAD_2) +#define PAD_SERIAL1_RX (SERCOM_RX_PAD_3) +#endif // __cplusplus + +// These serial port names are intended to allow libraries and architecture-neutral +// sketches to automatically default to the correct port name for a particular type +// of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, +// the first hardware serial port whose RX/TX pins are not dedicated to another use. +// +// SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor +// +// SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial +// +// SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library +// +// SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. +// +// SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX +// pins are NOT connected to anything by default. +#define SERIAL_PORT_USBVIRTUAL SerialUSB +#define SERIAL_PORT_MONITOR SerialUSB +#define SERIAL_PORT_HARDWARE Serial1 +#define SERIAL_PORT_HARDWARE_OPEN Serial1 + +// Alias Serial to SerialUSB +#define Serial SerialUSB + +// FPGA-specific functions +#ifdef __cplusplus +extern "C" { +#endif +void clockout(uint32_t gclk, int32_t divisor); +void startFPGA(); +#ifdef __cplusplus +} +#endif \ No newline at end of file diff --git a/variants/mkrwan1300/debug_scripts/variant.gdb b/variants/mkrwan1300/debug_scripts/variant.gdb new file mode 100644 index 0000000..3c37ffd --- /dev/null +++ b/variants/mkrwan1300/debug_scripts/variant.gdb @@ -0,0 +1,31 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +# Define 'reset' command +define reset + +info reg + +break main + +# End of 'reset' command +end + +target remote | openocd -c "interface cmsis-dap" -c "set CHIPNAME at91samd21g18" -f target/at91samdXX.cfg -c "gdb_port pipe; log_output openocd.log" diff --git a/variants/mkrwan1300/linker_scripts/gcc/flash_with_bootloader.ld b/variants/mkrwan1300/linker_scripts/gcc/flash_with_bootloader.ld new file mode 100644 index 0000000..3579464 --- /dev/null +++ b/variants/mkrwan1300/linker_scripts/gcc/flash_with_bootloader.ld @@ -0,0 +1,216 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000+0x2000, LENGTH = 0x00040000-0x2000 /* First 8KB used by bootloader */ + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.sketch_boot)) + + . = ALIGN(0x2000); + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(16); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM); + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/mkrwan1300/linker_scripts/gcc/flash_without_bootloader.ld b/variants/mkrwan1300/linker_scripts/gcc/flash_without_bootloader.ld new file mode 100644 index 0000000..ebeeee3 --- /dev/null +++ b/variants/mkrwan1300/linker_scripts/gcc/flash_without_bootloader.ld @@ -0,0 +1,214 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 0x00040000 + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + * __ram_end__ + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(16); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM) ; + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/mkrwan1300/openocd_scripts/arduino_zero.cfg b/variants/mkrwan1300/openocd_scripts/arduino_zero.cfg new file mode 100644 index 0000000..36c65c3 --- /dev/null +++ b/variants/mkrwan1300/openocd_scripts/arduino_zero.cfg @@ -0,0 +1,30 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +source [find interface/cmsis-dap.cfg] + +# chip name +set CHIPNAME at91samd21g18 +set ENDIAN little + +# choose a port here +set telnet_port 0 + +source [find target/at91samdXX.cfg] diff --git a/variants/mkrwan1300/pins_arduino.h b/variants/mkrwan1300/pins_arduino.h new file mode 100644 index 0000000..db0e40c --- /dev/null +++ b/variants/mkrwan1300/pins_arduino.h @@ -0,0 +1,21 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +// API compatibility +#include "variant.h" + diff --git a/variants/mkrwan1300/variant.cpp b/variants/mkrwan1300/variant.cpp new file mode 100644 index 0000000..8e07454 --- /dev/null +++ b/variants/mkrwan1300/variant.cpp @@ -0,0 +1,281 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +#include "variant.h" + +const PinDescription g_APinDescription[] = { + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 00 | D0 | PA22 | | *06 | | | X10 | | 3/00 | 5/00 |* TC4/0 | TCC0/4 | | GCLK_IO6 | + | 01 | D1 | PA23 | | *07 | | | X11 | | 3/01 | 5/01 |* TC4/1 | TCC0/5 | USB/SOF | GCLK_IO7 | + | 02 | D2 | PA10 | | 10 | *18 | | X02 | | 0/02 | 2/02 |*TCC1/0 | TCC0/2 | I2S/SCK0 | GCLK_IO4 | + | 03 | D3 | PA11 | | 11 | *19 | | X03 | | 0/03 | 2/03 |*TCC1/1 | TCC0/3 | I2S/FS0 | GCLK_IO5 | + | 04 | D4 | PB10 | | *10 | | | | | | 4/02 |* TC5/0 | TCC0/4 | I2S/MCK1 | GCLK_IO4 | + | 05 | D5 | PB11 | | *11 | | | | | | 4/03 |* TC5/1 | TCC0/5 | I2S/SCK1 | GCLK_IO5 | + | 06 | D6 | PA20 | LED_BUILTIN | *04 | | | X08 | | 5/02 | 3/02 | |*TCC0/6 | I2S/SCK0 | GCLK_IO4 | + | 07 | D7 | PA21 | | *05 | | | X09 | | 5/03 | 3/03 | |*TCC0/7 | I2S/FS0 | GCLK_IO5 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 22, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM4_CH0, TC4_CH0, EXTERNAL_INT_6 }, + { PORTA, 23, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM4_CH1, TC4_CH1, EXTERNAL_INT_7 }, + { PORTA, 10, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel18, PWM1_CH0, TCC1_CH0, EXTERNAL_INT_NONE }, + { PORTA, 11, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel19, PWM1_CH1, TCC1_CH1, EXTERNAL_INT_NONE }, + { PORTB, 10, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM5_CH0, TC5_CH0, EXTERNAL_INT_10 }, + { PORTB, 11, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM5_CH1, TC5_CH1, EXTERNAL_INT_11 }, + { PORTA, 20, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH6, TCC0_CH6, EXTERNAL_INT_4 }, + { PORTA, 21, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH7, TCC0_CH7, EXTERNAL_INT_5 }, + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | SPI | | | | | | | | | | | | | | + | 08 | MOSI | PA16 | | *00 | | | X04 | | *1/00 | 3/00 |*TCC2/0 | TCC0/6 | | GCLK_IO2 | + | 09 | SCK | PA17 | | *01 | | | X05 | | *1/01 | 3/01 | TCC2/1 | TCC0/7 | | GCLK_IO3 | + | 10 | MISO | PA19 | | 03 | | | X07 | | *1/03 | 3/03 |* TC3/1 | TCC0/3 | I2S/SD0 | AC/CMP1 | + +------------+------------------+--------+-----------------+--------------------+-----+-----+---------+---------+--------+--------+----------+----------+ + | | Wire | | | | | | | | | | | | | | + | 11 | SDA | PA08 | | NMI | *16 | | X00 | | *0/00 | 2/00 | TCC0/0 | TCC1/2 | I2S/SD1 | | + | 12 | SCL | PA09 | | 09 | *17 | | X01 | | *0/01 | 2/01 | TCC0/1 | TCC1/3 | I2S/MCK0 | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | Serial1 | | | | | | | | | | | | | | + | 13 | RX | PB23 | | 07 | | | | | | *5/03 | | | | GCLK_IO1 | + | 14 | TX | PB22 | | 06 | | | | | | *5/02 | | | | GCLK_IO0 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + // DIPO=3 DOPO=0 + { PORTA, 16, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM2_CH0, TCC2_CH0, EXTERNAL_INT_0 }, // MOSI: SERCOM1/PAD[0] + { PORTA, 17, PIO_SERCOM, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_1 }, // SCK: SERCOM1/PAD[1] + { PORTA, 19, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM3_CH1, TC3_CH1, EXTERNAL_INT_NONE }, // MISO: SERCOM1/PAD[3] + + // PINOUT=0 + { PORTA, 8, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), ADC_Channel16, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NMI }, // SDA: SERCOM2/PAD[0] + { PORTA, 9, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), ADC_Channel17, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCL: SERCOM2/PAD[1] + + // RXPO=3 TXPO=1 + { PORTB, 23, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // RX: SERCOM5/PAD[3] + { PORTB, 22, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // TX: SERCOM5/PAD[2] + + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 15 | A0 / DAC0 | PA02 | | 02 | *00 | | Y00 | OUT | | | | | | | + | 16 | A1 | PB02 | | *02 | *10 | | Y08 | | | 5/00 | | | | | + | 17 | A2 | PB03 | | *03 | *11 | | Y09 | | | 5/01 | | | | | + | 18 | A3 | PA04 | | 04 | *04 | 00 | Y02 | | | 0/00 |*TCC0/0 | | | | + | 19 | A4 | PA05 | | 05 | *05 | 01 | Y03 | | | 0/01 |*TCC0/1 | | | | + | 20 | A5 | PA06 | | 06 | *06 | 02 | Y04 | | | 0/02 | TCC1/0 | | | | + | 21 | A6 | PA07 | | 07 | *07 | 03 | Y05 | | | 0/03 | TCC1/1 | | I2S/SD0 | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG /*DAC*/ ), ADC_Channel0, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel10, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_2 }, + { PORTB, 3, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel11, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_3 }, + { PORTA, 4, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel4, PWM0_CH0, TCC0_CH0, EXTERNAL_INT_NONE }, + { PORTA, 5, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel5, PWM0_CH1, TCC0_CH1, EXTERNAL_INT_NONE }, + { PORTA, 6, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel6, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTA, 7, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel7, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | USB | | | | | | | | | | | | | | + | 22 | | PA24 | USB N | 12 | | | | | 3/02 | 5/02 | TC5/0 | TCC1/2 | USB/DM | | + | 23 | | PA25 | USB P | 13 | | | | | 3/03 | 5/03 | TC5/1 | TCC1/3 | USB/DP | | + | 24 | | PA18 | USB ID | 02 | | | X06 | | 1/02 | 3/02 | TC3/0 | TCC0/2 | | AC/CMP0 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 25 | AREF | PA03 | | 03 | 01 | | Y01 | | | | | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 24, PIO_COM, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DM + { PORTA, 25, PIO_COM, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DP + { PORTA, 18, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + + { PORTA, 3, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // DAC/VREFP + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | SD SPI | | | | | | | | | | | | | | + | 26 | | PA12 | UART TX (MOSI) | 12 | | | | | 2/00 | *4/00 | TCC2/0 | TCC0/6 | | AC/CMP0 | + | 27 | | PA13 | (SCK) | 13 | | | | | 2/01 | *4/01 | TCC2/1 | TCC0/7 | | AC/CMP1 | + | 28 | | PA14 | (SSN) | 14 | | | | | 2/02 | 4/02 | TC3/0 | TCC0/4 | | GCLK_IO0 | + | 29 | | PA15 | UART RX (MISO) | 15 | | | | | 2/03 | *4/03 | TC3/1 | TCC0/5 | | GCLK_IO1 | + | 30 | | PA27 | MODULE RESETN | 15 | | | | | | | | | | GCLK_IO0 | + | 31 | | PA28 | UNUSED | 08 | | | | | | | | | | GCLK_IO0 | + | 32 | | PB08 | ADC_BATTERY | 08 | 02 | | Y14 | | | 4/00 | TC4/0 | | | | + | 33 | | PB09 | MODULE BOOT0 | *09 | 03 | | Y15 | | | 4/01 | TC4/1 | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | 32768Hz Crystal | | | | | | | | | | | | | | + | 34 | | PA00 | XIN32 | 00 | | | | | | 1/00 | TCC2/0 | | | | + | 35 | | PA01 | XOUT32 | 01 | | | | | | 1/01 | TCC2/1 | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | SPI1 | | | | | | | | | | | | | | + | 36 | MOSI | PA12 | | 12 | | | | | 2/00 | 4/00 | TCC2/0 | TCC0/6 | | AC/CMP0 | + | 37 | SCK | PA13 | | 13 | | | | | 2/01 | 4/01 | TCC2/1 | TCC0/7 | | AC/CMP1 | + | 38 | MISO | PA15 | | 15 | | | | | 2/03 | 4/03 | TCC3/1 | TCC0/5 | | GCLK_IO1 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 12, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MOSI: SERCOM4/PAD[0] + { PORTA, 13, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCK: SERCOM4/PAD[1] + { PORTA, 14, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SS: as GPIO + { PORTA, 15, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MISO: SERCOM4/PAD[3] + { PORTA, 27, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + + { PORTA, 28, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_8 }, + { PORTB, 8, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG ), ADC_Channel2, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 9, PIO_DIGITAL, (PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel3, PWM4_CH1, TC4_CH1, EXTERNAL_INT_9 }, + + { PORTA, 0, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTA, 1, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + + { PORTA, 12, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MOSI: SERCOM4/PAD[0] + { PORTA, 13, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCK: SERCOM4/PAD[1] + { PORTA, 15, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MISO: SERCOM4/PAD[3] +}; + +extern "C" { + unsigned int PINCOUNT_fn() { + return (sizeof(g_APinDescription) / sizeof(g_APinDescription[0])); + } +} + +const void* g_apTCInstances[TCC_INST_NUM + TC_INST_NUM]={ TCC0, TCC1, TCC2, TC3, TC4, TC5 }; + + +#if defined(USE_BQ24195L_PMIC) +#include "wiring_private.h" +#include "../Common.h" + +#define PMIC_ADDRESS 0x6B +#define PMIC_REG01 0x01 +#define PMIC_REG07 0x07 +#define PMIC_REG08 0x08 + +static inline void enable_battery_charging() { + + bool ret = PERIPH_WIRE.startTransmissionWIRE( PMIC_ADDRESS, WIRE_WRITE_FLAG ); + if (!ret) { + return; + } + PERIPH_WIRE.sendDataMasterWIRE(PMIC_REG01); + PERIPH_WIRE.sendDataMasterWIRE(0x1B); // Charge Battery + Minimum System Voltage 3.5V + PERIPH_WIRE.prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); +} + +static inline void disable_battery_charging() { + + bool ret = PERIPH_WIRE.startTransmissionWIRE( PMIC_ADDRESS, WIRE_WRITE_FLAG ); + if (!ret) { + return; + } + PERIPH_WIRE.sendDataMasterWIRE(PMIC_REG01); + PERIPH_WIRE.sendDataMasterWIRE(0x0B); // Charge Battery + Minimum System Voltage 3.5V + PERIPH_WIRE.prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); +} + +static inline void disable_battery_fet(bool disabled) { + + bool ret = PERIPH_WIRE.startTransmissionWIRE( PMIC_ADDRESS, WIRE_WRITE_FLAG ); + if (!ret) { + return; + } + PERIPH_WIRE.sendDataMasterWIRE(PMIC_REG07); + // No D+/D– detection + Safety timer not slowed by 2X during input DPM or thermal regulation + + // BAT fet disabled/enabled + charge and bat fault INT + PERIPH_WIRE.sendDataMasterWIRE(0x0B | (disabled ? 0x20 : 0x00)); + PERIPH_WIRE.prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); +} + +static inline bool is_battery_present() { + + bool ret = PERIPH_WIRE.startTransmissionWIRE( PMIC_ADDRESS, WIRE_WRITE_FLAG ); + if (!ret) { + return false; + } + PERIPH_WIRE.sendDataMasterWIRE(PMIC_REG08); + PERIPH_WIRE.prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); + + ret = PERIPH_WIRE.startTransmissionWIRE( PMIC_ADDRESS, WIRE_READ_FLAG ); + if (!ret) { + return false; + } + uint8_t res = PERIPH_WIRE.readDataWIRE(); + PERIPH_WIRE.prepareNackBitWIRE(); + PERIPH_WIRE.prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); + return ((res & 0b1000) != 0); +} + +void initVariant() { + PERIPH_WIRE.initMasterWIRE(100000); + PERIPH_WIRE.enableWIRE(); + pinPeripheral(PIN_WIRE_SDA, g_APinDescription[PIN_WIRE_SDA].ulPinType); + pinPeripheral(PIN_WIRE_SCL, g_APinDescription[PIN_WIRE_SCL].ulPinType); + + enable_battery_charging(); + //disable_battery_fet(false); + delay(100); + bool batteryPresent = is_battery_present(); + if (!batteryPresent) { + disable_battery_charging(); + } + + PERIPH_WIRE.disableWIRE(); +} +#endif + +// Multi-serial objects instantiation +SERCOM sercom0(SERCOM0); +SERCOM sercom1(SERCOM1); +SERCOM sercom2(SERCOM2); +SERCOM sercom3(SERCOM3); +SERCOM sercom4(SERCOM4); +SERCOM sercom5(SERCOM5); + +// Serial1 +Uart Serial1(&sercom5, PIN_SERIAL1_RX, PIN_SERIAL1_TX, PAD_SERIAL1_RX, PAD_SERIAL1_TX); + +void SERCOM5_Handler() +{ + Serial1.IrqHandler(); +} + +// SerialLoRa +Uart Serial2(&sercom4, PIN_SERIAL2_RX, PIN_SERIAL2_TX, PAD_SERIAL2_RX, PAD_SERIAL2_TX); + +void SERCOM4_Handler() +{ + Serial2.IrqHandler(); +} \ No newline at end of file diff --git a/variants/mkrwan1300/variant.h b/variants/mkrwan1300/variant.h new file mode 100644 index 0000000..f99cce7 --- /dev/null +++ b/variants/mkrwan1300/variant.h @@ -0,0 +1,226 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +#pragma once + +// The definitions here needs a SAMD core >=1.6.10 +#define ARDUINO_SAMD_VARIANT_COMPLIANCE 10610 + +#include + +// General definitions +// ------------------- + +// Frequency of the board main oscillator +#define VARIANT_MAINOSC (32768ul) + +// Master clock frequency +#define VARIANT_MCK (48000000ul) + +// Pins +// ---- + +// Number of pins defined in PinDescription array +#ifdef __cplusplus +extern "C" unsigned int PINCOUNT_fn(); +#endif +#define PINS_COUNT (PINCOUNT_fn()) +#define NUM_DIGITAL_PINS (15u) +#define NUM_ANALOG_INPUTS (7u) +#define NUM_ANALOG_OUTPUTS (1u) + +// Low-level pin register query macros +// ----------------------------------- +#define digitalPinToPort(P) (&(PORT->Group[g_APinDescription[P].ulPort])) +#define digitalPinToBitMask(P) (1 << g_APinDescription[P].ulPin) +//#define analogInPinToBit(P) () +#define portOutputRegister(port) (&(port->OUT.reg)) +#define portInputRegister(port) (&(port->IN.reg)) +#define portModeRegister(port) (&(port->DIR.reg)) +#define digitalPinHasPWM(P) (g_APinDescription[P].ulPWMChannel != NOT_ON_PWM || g_APinDescription[P].ulTCChannel != NOT_ON_TIMER) + +/* + * digitalPinToTimer(..) is AVR-specific and is not defined for SAMD + * architecture. If you need to check if a pin supports PWM you must + * use digitalPinHasPWM(..). + * + * https://github.com/arduino/Arduino/issues/1833 + */ +// #define digitalPinToTimer(P) + +//Battery +#define ADC_BATTERY (32u) + +// LEDs +// ---- +#define PIN_LED (6u) +#define LED_BUILTIN PIN_LED + +// LoRA module +#define LORA_RESET (30u) +#define LORA_BOOT0 (33u) + +// Analog pins +// ----------- +#define PIN_A0 (15u) +#define PIN_A1 (16u) +#define PIN_A2 (17u) +#define PIN_A3 (18u) +#define PIN_A4 (19u) +#define PIN_A5 (20u) +#define PIN_A6 (21u) +static const uint8_t A0 = PIN_A0; +static const uint8_t A1 = PIN_A1; +static const uint8_t A2 = PIN_A2; +static const uint8_t A3 = PIN_A3; +static const uint8_t A4 = PIN_A4; +static const uint8_t A5 = PIN_A5; +static const uint8_t A6 = PIN_A6; +#define ADC_RESOLUTION 12 + +// SPI Interfaces +// -------------- +#define SPI_INTERFACES_COUNT 2 + +// SPI +#define PIN_SPI_MISO (10u) +#define PIN_SPI_MOSI (8u) +#define PIN_SPI_SCK (9u) +#define PIN_SPI_SS (4u) +#define PERIPH_SPI sercom1 +#define PAD_SPI_TX SPI_PAD_0_SCK_1 +#define PAD_SPI_RX SERCOM_RX_PAD_3 + +static const uint8_t SS = PIN_SPI_SS; // SPI Slave SS not used. Set here only for reference. +static const uint8_t MOSI = PIN_SPI_MOSI; +static const uint8_t MISO = PIN_SPI_MISO; +static const uint8_t SCK = PIN_SPI_SCK; + +// SPI1 +#define PIN_SPI1_MISO (38u) +#define PIN_SPI1_MOSI (36u) +#define PIN_SPI1_SCK (37u) +#define LORA_IRQ_DUMB (28u) +#define PERIPH_SPI1 sercom4 +#define PAD_SPI1_TX SPI_PAD_0_SCK_1 +#define PAD_SPI1_RX SERCOM_RX_PAD_3 +static const uint8_t MOSI1 = PIN_SPI1_MOSI; +static const uint8_t MISO1 = PIN_SPI1_MISO; +static const uint8_t SCK1 = PIN_SPI1_SCK; + +// Wire Interfaces +// --------------- +#define WIRE_INTERFACES_COUNT 1 + +// Wire +#define PIN_WIRE_SDA (11u) +#define PIN_WIRE_SCL (12u) +#define PERIPH_WIRE sercom2 +#define WIRE_IT_HANDLER SERCOM2_Handler +static const uint8_t SDA = PIN_WIRE_SDA; +static const uint8_t SCL = PIN_WIRE_SCL; + +// USB +// --- +#define PIN_USB_DM (22ul) +#define PIN_USB_DP (23ul) +#define PIN_USB_HOST_ENABLE (24ul) + +// I2S Interfaces +// -------------- +#define I2S_INTERFACES_COUNT 1 + +#define I2S_DEVICE 0 +#define I2S_CLOCK_GENERATOR 3 +#define PIN_I2S_SD (PIN_A6) +#define PIN_I2S_SCK (2u) +#define PIN_I2S_FS (3u) + +// Serial ports +// ------------ +#ifdef __cplusplus +#include "SERCOM.h" +#include "Uart.h" + +// Instances of SERCOM +extern SERCOM sercom0; +extern SERCOM sercom1; +extern SERCOM sercom2; +extern SERCOM sercom3; +extern SERCOM sercom4; +extern SERCOM sercom5; + +// Serial1 +extern Uart Serial1; +#define PIN_SERIAL1_RX (13ul) +#define PIN_SERIAL1_TX (14ul) +#define PAD_SERIAL1_TX (UART_TX_PAD_2) +#define PAD_SERIAL1_RX (SERCOM_RX_PAD_3) + +// Serial2 +extern Uart Serial2; +#define PIN_SERIAL2_RX (29ul) +#define PIN_SERIAL2_TX (26ul) +#define PAD_SERIAL2_TX (UART_TX_PAD_0) +#define PAD_SERIAL2_RX (SERCOM_RX_PAD_3) + +#endif // __cplusplus + +#ifdef __cplusplus +extern "C" { +#endif +unsigned int PINCOUNT_fn(); +#ifdef __cplusplus +} +#endif + +// These serial port names are intended to allow libraries and architecture-neutral +// sketches to automatically default to the correct port name for a particular type +// of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, +// the first hardware serial port whose RX/TX pins are not dedicated to another use. +// +// SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor +// +// SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial +// +// SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library +// +// SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. +// +// SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX +// pins are NOT connected to anything by default. +#define SERIAL_PORT_USBVIRTUAL SerialUSB +#define SERIAL_PORT_MONITOR SerialUSB +#define SERIAL_PORT_HARDWARE Serial1 +#define SERIAL_PORT_HARDWARE_OPEN Serial1 + +// Alias Serial to SerialUSB +#define Serial SerialUSB + +// Alias SerialLoRA to Serial2 +#define SerialLoRa Serial2 + + +// MKRWAN1310 compatibility layer +#if defined(USE_BQ24195L_PMIC) +// ADC_BATTERY is not connected as an ADC but as the flash CS +#define FLASH_CS (32u) +#undef ADC_BATTERY +// PA28 is connected to IRQ capable PIN +#define LORA_IRQ (31u) +#endif \ No newline at end of file diff --git a/variants/mkrwifi1010/debug_scripts/variant.gdb b/variants/mkrwifi1010/debug_scripts/variant.gdb new file mode 100644 index 0000000..3c37ffd --- /dev/null +++ b/variants/mkrwifi1010/debug_scripts/variant.gdb @@ -0,0 +1,31 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +# Define 'reset' command +define reset + +info reg + +break main + +# End of 'reset' command +end + +target remote | openocd -c "interface cmsis-dap" -c "set CHIPNAME at91samd21g18" -f target/at91samdXX.cfg -c "gdb_port pipe; log_output openocd.log" diff --git a/variants/mkrwifi1010/linker_scripts/gcc/flash_with_bootloader.ld b/variants/mkrwifi1010/linker_scripts/gcc/flash_with_bootloader.ld new file mode 100644 index 0000000..5c0dcb4 --- /dev/null +++ b/variants/mkrwifi1010/linker_scripts/gcc/flash_with_bootloader.ld @@ -0,0 +1,217 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000+0x2000, LENGTH = 0x00040000-0x2000 /* First 8KB used by bootloader */ + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.sketch_boot)) + + . = ALIGN(0x2000); + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(16); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM); + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/mkrwifi1010/linker_scripts/gcc/flash_without_bootloader.ld b/variants/mkrwifi1010/linker_scripts/gcc/flash_without_bootloader.ld new file mode 100644 index 0000000..ebeeee3 --- /dev/null +++ b/variants/mkrwifi1010/linker_scripts/gcc/flash_without_bootloader.ld @@ -0,0 +1,214 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 0x00040000 + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + * __ram_end__ + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(16); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM) ; + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/mkrwifi1010/openocd_scripts/arduino_zero.cfg b/variants/mkrwifi1010/openocd_scripts/arduino_zero.cfg new file mode 100644 index 0000000..36c65c3 --- /dev/null +++ b/variants/mkrwifi1010/openocd_scripts/arduino_zero.cfg @@ -0,0 +1,30 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +source [find interface/cmsis-dap.cfg] + +# chip name +set CHIPNAME at91samd21g18 +set ENDIAN little + +# choose a port here +set telnet_port 0 + +source [find target/at91samdXX.cfg] diff --git a/variants/mkrwifi1010/pins_arduino.h b/variants/mkrwifi1010/pins_arduino.h new file mode 100644 index 0000000..db0e40c --- /dev/null +++ b/variants/mkrwifi1010/pins_arduino.h @@ -0,0 +1,21 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +// API compatibility +#include "variant.h" + diff --git a/variants/mkrwifi1010/variant.cpp b/variants/mkrwifi1010/variant.cpp new file mode 100644 index 0000000..eb146fa --- /dev/null +++ b/variants/mkrwifi1010/variant.cpp @@ -0,0 +1,258 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +#include "variant.h" +#include "Arduino.h" + +const PinDescription g_APinDescription[] = { + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 00 | D0 | PA22 | | *06 | | | X10 | | 3/00 | 5/00 |* TC4/0 | TCC0/4 | | GCLK_IO6 | + | 01 | D1 | PA23 | | *07 | | | X11 | | 3/01 | 5/01 |* TC4/1 | TCC0/5 | USB/SOF | GCLK_IO7 | + | 02 | D2 | PA10 | | 10 | *18 | | X02 | | 0/02 | 2/02 |*TCC1/0 | TCC0/2 | I2S/SCK0 | GCLK_IO4 | + | 03 | D3 | PA11 | | 11 | *19 | | X03 | | 0/03 | 2/03 |*TCC1/1 | TCC0/3 | I2S/FS0 | GCLK_IO5 | + | 04 | D4 | PB10 | | *10 | | | | | | 4/02 |* TC5/0 | TCC0/4 | I2S/MCK1 | GCLK_IO4 | + | 05 | D5 | PB11 | | *11 | | | | | | 4/03 |* TC5/1 | TCC0/5 | I2S/SCK1 | GCLK_IO5 | + | 06 | D6 | PA20 | LED_BUILTIN | *04 | | | X08 | | 5/02 | 3/02 | |*TCC0/6 | I2S/SCK0 | GCLK_IO4 | + | 07 | D7 | PA21 | | *05 | | | X09 | | 5/03 | 3/03 | |*TCC0/7 | I2S/FS0 | GCLK_IO5 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 22, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM4_CH0, TC4_CH0, EXTERNAL_INT_6 }, + { PORTA, 23, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM4_CH1, TC4_CH1, EXTERNAL_INT_7 }, + { PORTA, 10, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel18, PWM1_CH0, TCC1_CH0, EXTERNAL_INT_NONE }, + { PORTA, 11, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel19, PWM1_CH1, TCC1_CH1, EXTERNAL_INT_NONE }, + { PORTB, 10, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM5_CH0, TC5_CH0, EXTERNAL_INT_10 }, + { PORTB, 11, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM5_CH1, TC5_CH1, EXTERNAL_INT_11 }, + { PORTA, 20, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH6, TCC0_CH6, EXTERNAL_INT_4 }, + { PORTA, 21, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH7, TCC0_CH7, EXTERNAL_INT_5 }, + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | SPI | | | | | | | | | | | | | | + | 08 | MOSI | PA16 | | *00 | | | X04 | | *1/00 | 3/00 |*TCC2/0 | TCC0/6 | | GCLK_IO2 | + | 09 | SCK | PA17 | | *01 | | | X05 | | *1/01 | 3/01 | TCC2/1 | TCC0/7 | | GCLK_IO3 | + | 10 | MISO | PA19 | | 03 | | | X07 | | *1/03 | 3/03 |* TC3/1 | TCC0/3 | I2S/SD0 | AC/CMP1 | + +------------+------------------+--------+-----------------+--------------------+-----+-----+---------+---------+--------+--------+----------+----------+ + | | Wire | | | | | | | | | | | | | | + | 11 | SDA | PA08 | | NMI | *16 | | X00 | | *0/00 | 2/00 | TCC0/0 | TCC1/2 | I2S/SD1 | | + | 12 | SCL | PA09 | | 09 | *17 | | X01 | | *0/01 | 2/01 | TCC0/1 | TCC1/3 | I2S/MCK0 | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | Serial1 | | | | | | | | | | | | | | + | 13 | RX | PB23 | | 07 | | | | | | *5/03 | | | | GCLK_IO1 | + | 14 | TX | PB22 | | 06 | | | | | | *5/02 | | | | GCLK_IO0 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + // DIPO=3 DOPO=0 + { PORTA, 16, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM2_CH0, TCC2_CH0, EXTERNAL_INT_0 }, // MOSI: SERCOM1/PAD[0] + { PORTA, 17, PIO_SERCOM, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_1 }, // SCK: SERCOM1/PAD[1] + { PORTA, 19, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM3_CH1, TC3_CH1, EXTERNAL_INT_NONE }, // MISO: SERCOM1/PAD[3] + + // PINOUT=0 + { PORTA, 8, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), ADC_Channel16, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NMI }, // SDA: SERCOM2/PAD[0] + { PORTA, 9, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), ADC_Channel17, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCL: SERCOM2/PAD[1] + + // RXPO=3 TXPO=1 + { PORTB, 23, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // RX: SERCOM5/PAD[3] + { PORTB, 22, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // TX: SERCOM5/PAD[2] + + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 15 | A0 / DAC0 | PA02 | | 02 | *00 | | Y00 | OUT | | | | | | | + | 16 | A1 | PB02 | | *02 | *10 | | Y08 | | | 5/00 | | | | | + | 17 | A2 | PB03 | | *03 | *11 | | Y09 | | | 5/01 | | | | | + | 18 | A3 | PA04 | | 04 | *04 | 00 | Y02 | | | 0/00 |*TCC0/0 | | | | + | 19 | A4 | PA05 | | 05 | *05 | 01 | Y03 | | | 0/01 |*TCC0/1 | | | | + | 20 | A5 | PA06 | | 06 | *06 | 02 | Y04 | | | 0/02 | TCC1/0 | | | | + | 21 | A6 | PA07 | | 07 | *07 | 03 | Y05 | | | 0/03 | TCC1/1 | | I2S/SD0 | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG /*DAC*/ ), ADC_Channel0, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel10, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_2 }, + { PORTB, 3, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel11, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_3 }, + { PORTA, 4, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel4, PWM0_CH0, TCC0_CH0, EXTERNAL_INT_NONE }, + { PORTA, 5, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel5, PWM0_CH1, TCC0_CH1, EXTERNAL_INT_NONE }, + { PORTA, 6, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel6, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTA, 7, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel7, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | USB | | | | | | | | | | | | | | + | 22 | | PA24 | USB N | 12 | | | | | 3/02 | 5/02 | TC5/0 | TCC1/2 | USB/DM | | + | 23 | | PA25 | USB P | 13 | | | | | 3/03 | 5/03 | TC5/1 | TCC1/3 | USB/DP | | + | 24 | | PA18 | USB ID | 02 | | | X06 | | 1/02 | 3/02 | TC3/0 | TCC0/2 | | AC/CMP0 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 25 | AREF | PA03 | | 03 | 01 | | Y01 | | | | | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 24, PIO_COM, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DM + { PORTA, 25, PIO_COM, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DP + { PORTA, 18, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + + { PORTA, 3, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // DAC/VREFP + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | WiFi SPI | | | | | | | | | | | | | | + | 26 | | PA12 | NINA_MOSI | 12 | | | | | *2/00 | 4/00 | TCC2/0 | TCC0/6 | | AC/CMP0 | + | 27 | | PA13 | NINA_MISO | 13 | | | | | *2/01 | 4/01 | TCC2/1 | TCC0/7 | | AC/CMP1 | + | 28 | | PA14 | NINA_CS | 14 | | | | | 2/02 | 4/02 | TC3/0 | TCC0/4 | | GCLK_IO0 | + | 29 | | PA15 | NINA_SCK | 15 | | | | | *2/03 | 4/03 | TC3/1 | TCC0/5 | | GCLK_IO1 | + | 30 | | PA27 | NINA_GPIO0 | *15 | | | | | | | | | | GCLK_IO0 | + | 31 | | PB08 | NINA_RESETN | 08 | 02 | | Y14 | | | 4/00 | TC4/0 | | | | + | 32 | | PB09 | ADC_VBAT | *09 | 03 | | Y15 | | | 4/01 | TC4/1 | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | 32768Hz Crystal | | | | | | | | | | | | | | + | 33 | | PA00 | XIN32 | 00 | | | | | | 1/00 | TCC2/0 | | | | + | 34 | | PA01 | XOUT32 | 01 | | | | | | 1/01 | TCC2/1 | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 35 | | PA28 | NINA_ACK | 01 | | | | | | 1/01 | TCC2/1 | | | | ++------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ +*/ + // DIPO=3 DOPO=0 + { PORTA, 12, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MOSI: SERCOM4/PAD[0] + { PORTA, 13, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCK: SERCOM4/PAD[1] + { PORTA, 14, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SS: as GPIO + { PORTA, 15, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MISO: SERCOM4/PAD[3] + { PORTA, 27, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_15 }, + + { PORTB, 8, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG ), ADC_Channel2, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 9, PIO_ANALOG, (PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel3, PWM4_CH1, TC4_CH1, EXTERNAL_INT_9 }, + + { PORTA, 0, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTA, 1, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + + { PORTA, 28, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, +}; + +extern "C" { + unsigned int PINCOUNT_fn() { + return (sizeof(g_APinDescription) / sizeof(g_APinDescription[0])); + } +} + +const void* g_apTCInstances[TCC_INST_NUM + TC_INST_NUM]={ TCC0, TCC1, TCC2, TC3, TC4, TC5 }; + +// Multi-serial objects instantiation +SERCOM sercom0(SERCOM0); +SERCOM sercom1(SERCOM1); +SERCOM sercom2(SERCOM2); +SERCOM sercom3(SERCOM3); +SERCOM sercom4(SERCOM4); +SERCOM sercom5(SERCOM5); + +#if defined(USE_BQ24195L_PMIC) + +#include "wiring_private.h" + +#define PMIC_ADDRESS 0x6B +#define PMIC_REG01 0x01 +#define PMIC_REG07 0x07 + +static inline void enable_battery_charging() { + PERIPH_WIRE.initMasterWIRE(100000); + PERIPH_WIRE.enableWIRE(); + pinPeripheral(PIN_WIRE_SDA, g_APinDescription[PIN_WIRE_SDA].ulPinType); + pinPeripheral(PIN_WIRE_SCL, g_APinDescription[PIN_WIRE_SCL].ulPinType); + + PERIPH_WIRE.startTransmissionWIRE( PMIC_ADDRESS, WIRE_WRITE_FLAG ); + PERIPH_WIRE.sendDataMasterWIRE(PMIC_REG01); + PERIPH_WIRE.sendDataMasterWIRE(0x1B); // Charge Battery + Minimum System Voltage 3.5V + PERIPH_WIRE.prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); + + PERIPH_WIRE.disableWIRE(); +} + +static inline void disable_battery_fet(bool disabled) { + PERIPH_WIRE.initMasterWIRE(100000); + PERIPH_WIRE.enableWIRE(); + pinPeripheral(PIN_WIRE_SDA, g_APinDescription[PIN_WIRE_SDA].ulPinType); + pinPeripheral(PIN_WIRE_SCL, g_APinDescription[PIN_WIRE_SCL].ulPinType); + + PERIPH_WIRE.startTransmissionWIRE( PMIC_ADDRESS, WIRE_WRITE_FLAG ); + PERIPH_WIRE.sendDataMasterWIRE(PMIC_REG07); + // No D+/D– detection + Safety timer not slowed by 2X during input DPM or thermal regulation + + // BAT fet disabled/enabled + charge and bat fault INT + PERIPH_WIRE.sendDataMasterWIRE(0x0B | (disabled ? 0x20 : 0x00)); + PERIPH_WIRE.prepareCommandBitsWire(WIRE_MASTER_ACT_STOP); + + PERIPH_WIRE.disableWIRE(); +} + +#endif + +void initVariant() { +#if defined(USE_BQ24195L_PMIC) + pinMode(ADC_BATTERY, OUTPUT); + digitalWrite(ADC_BATTERY, LOW); + delay(10); + pinMode(ADC_BATTERY, INPUT); + delay(100); + + bool batteryPresent = analogRead(ADC_BATTERY) > 600; + if (batteryPresent) { + enable_battery_charging(); + } + disable_battery_fet(!batteryPresent); +#endif + + // NINA - SPI boot + pinMode(NINA_GPIO0, OUTPUT); + digitalWrite(NINA_GPIO0, HIGH); + + // disable NINA + pinMode(NINA_RESETN, OUTPUT); + digitalWrite(NINA_RESETN, HIGH); +} + +// Serial1 +Uart Serial1(&sercom5, PIN_SERIAL1_RX, PIN_SERIAL1_TX, PAD_SERIAL1_RX, PAD_SERIAL1_TX); + +void SERCOM5_Handler() +{ + Serial1.IrqHandler(); +} + +// Serial2 +Uart Serial2(&sercom4, PIN_SERIAL2_RX, PIN_SERIAL2_TX, PAD_SERIAL2_RX, PAD_SERIAL2_TX, PIN_SERIAL2_RTS, PIN_SERIAL2_CTS); + +void SERCOM4_Handler() +{ + Serial2.IrqHandler(); +} diff --git a/variants/mkrwifi1010/variant.h b/variants/mkrwifi1010/variant.h new file mode 100644 index 0000000..bd7645c --- /dev/null +++ b/variants/mkrwifi1010/variant.h @@ -0,0 +1,227 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +#pragma once + +// The definitions here needs a SAMD core >=1.6.10 +#define ARDUINO_SAMD_VARIANT_COMPLIANCE 10610 + +#include + +// General definitions +// ------------------- + +// Frequency of the board main oscillator +#define VARIANT_MAINOSC (32768ul) + +// Master clock frequency +#define VARIANT_MCK (48000000ul) + +// Pins +// ---- + +// Number of pins defined in PinDescription array +#ifdef __cplusplus +extern "C" unsigned int PINCOUNT_fn(); +#endif +#define PINS_COUNT (PINCOUNT_fn()) +#define NUM_DIGITAL_PINS (15u) +#define NUM_ANALOG_INPUTS (7u) +#define NUM_ANALOG_OUTPUTS (1u) + +// Low-level pin register query macros +// ----------------------------------- +#define digitalPinToPort(P) (&(PORT->Group[g_APinDescription[P].ulPort])) +#define digitalPinToBitMask(P) (1 << g_APinDescription[P].ulPin) +//#define analogInPinToBit(P) () +#define portOutputRegister(port) (&(port->OUT.reg)) +#define portInputRegister(port) (&(port->IN.reg)) +#define portModeRegister(port) (&(port->DIR.reg)) +#define digitalPinHasPWM(P) (g_APinDescription[P].ulPWMChannel != NOT_ON_PWM || g_APinDescription[P].ulTCChannel != NOT_ON_TIMER) + +/* + * digitalPinToTimer(..) is AVR-specific and is not defined for SAMD + * architecture. If you need to check if a pin supports PWM you must + * use digitalPinHasPWM(..). + * + * https://github.com/arduino/Arduino/issues/1833 + */ +// #define digitalPinToTimer(P) + +//Battery +#define ADC_BATTERY (32u) + +//NINA +#define NINA_GPIO0 (30u) +#define NINA_RESETN (31u) +#define NINA_ACK (35u) + +// LEDs +// ---- +#define PIN_LED (6u) +#define LED_BUILTIN PIN_LED + +// Analog pins +// ----------- +#define PIN_A0 (15u) +#define PIN_A1 (16u) +#define PIN_A2 (17u) +#define PIN_A3 (18u) +#define PIN_A4 (19u) +#define PIN_A5 (20u) +#define PIN_A6 (21u) +static const uint8_t A0 = PIN_A0; +static const uint8_t A1 = PIN_A1; +static const uint8_t A2 = PIN_A2; +static const uint8_t A3 = PIN_A3; +static const uint8_t A4 = PIN_A4; +static const uint8_t A5 = PIN_A5; +static const uint8_t A6 = PIN_A6; +#define ADC_RESOLUTION 12 + +// SPI Interfaces +// -------------- +#define SPI_INTERFACES_COUNT 2 + +// SPI +#define PIN_SPI_MISO (10u) +#define PIN_SPI_MOSI (8u) +#define PIN_SPI_SCK (9u) +#define PIN_SPI_SS (4u) +#define PERIPH_SPI sercom1 +#define PAD_SPI_TX SPI_PAD_0_SCK_1 +#define PAD_SPI_RX SERCOM_RX_PAD_3 + +static const uint8_t SS = PIN_SPI_SS; // SPI Slave SS not used. Set here only for reference. +static const uint8_t MOSI = PIN_SPI_MOSI; +static const uint8_t MISO = PIN_SPI_MISO; +static const uint8_t SCK = PIN_SPI_SCK; + +// SPI1 +#define PIN_SPI1_MISO (27u) +#define PIN_SPI1_MOSI (26u) +#define PIN_SPI1_SCK (29u) +#define PIN_SPI1_SS (28u) +#define PERIPH_SPI1 sercom4 +#define PAD_SPI1_TX SPI_PAD_0_SCK_3 +#define PAD_SPI1_RX SERCOM_RX_PAD_1 +static const uint8_t SS1 = PIN_SPI1_SS; +static const uint8_t MOSI1 = PIN_SPI1_MOSI; +static const uint8_t MISO1 = PIN_SPI1_MISO; +static const uint8_t SCK1 = PIN_SPI1_SCK; + +#define SPIWIFI_SS PIN_SPI1_SS +#define SPIWIFI_ACK NINA_ACK +#define SPIWIFI_RESET (~NINA_RESETN) // fixme! Inverted logic + + +// Wire Interfaces +// --------------- +#define WIRE_INTERFACES_COUNT 1 + +// Wire +#define PIN_WIRE_SDA (11u) +#define PIN_WIRE_SCL (12u) +#define PERIPH_WIRE sercom2 +#define WIRE_IT_HANDLER SERCOM2_Handler +static const uint8_t SDA = PIN_WIRE_SDA; +static const uint8_t SCL = PIN_WIRE_SCL; + +// USB +// --- +#define PIN_USB_DM (22ul) +#define PIN_USB_DP (23ul) +#define PIN_USB_HOST_ENABLE (24ul) + +// I2S Interfaces +// -------------- +#define I2S_INTERFACES_COUNT 1 + +#define I2S_DEVICE 0 +#define I2S_CLOCK_GENERATOR 3 +#define PIN_I2S_SD (PIN_A6) +#define PIN_I2S_SCK (2u) +#define PIN_I2S_FS (3u) + +// Serial ports +// ------------ +#ifdef __cplusplus +#include "SERCOM.h" +#include "Uart.h" + +// Instances of SERCOM +extern SERCOM sercom0; +extern SERCOM sercom1; +extern SERCOM sercom2; +extern SERCOM sercom3; +extern SERCOM sercom4; +extern SERCOM sercom5; + +// Serial1 +extern Uart Serial1; +#define PIN_SERIAL1_RX (13ul) +#define PIN_SERIAL1_TX (14ul) +#define PAD_SERIAL1_TX (UART_TX_PAD_2) +#define PAD_SERIAL1_RX (SERCOM_RX_PAD_3) + +// Serial2 +extern Uart Serial2; +#define PIN_SERIAL2_RX (27ul) +#define PIN_SERIAL2_TX (26ul) +#define PAD_SERIAL2_TX (UART_TX_RTS_CTS_PAD_0_2_3) +#define PAD_SERIAL2_RX (SERCOM_RX_PAD_1) +#define PIN_SERIAL2_RTS (28u) +#define PIN_SERIAL2_CTS (29u) + +#endif // __cplusplus + +#ifdef __cplusplus +extern "C" { +#endif +unsigned int PINCOUNT_fn(); +#ifdef __cplusplus +} +#endif + +// These serial port names are intended to allow libraries and architecture-neutral +// sketches to automatically default to the correct port name for a particular type +// of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, +// the first hardware serial port whose RX/TX pins are not dedicated to another use. +// +// SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor +// +// SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial +// +// SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library +// +// SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. +// +// SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX +// pins are NOT connected to anything by default. +#define SERIAL_PORT_USBVIRTUAL SerialUSB +#define SERIAL_PORT_MONITOR SerialUSB +#define SERIAL_PORT_HARDWARE Serial1 +#define SERIAL_PORT_HARDWARE_OPEN Serial1 + +// Alias Serial to SerialUSB +#define Serial SerialUSB + +// Alias Serial1 to SerialNina (useful in libraries) +#define SerialNina Serial1 + +#define SPIWIFI SPI1 diff --git a/variants/mkrzero/debug_scripts/variant.gdb b/variants/mkrzero/debug_scripts/variant.gdb new file mode 100644 index 0000000..3c37ffd --- /dev/null +++ b/variants/mkrzero/debug_scripts/variant.gdb @@ -0,0 +1,31 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +# Define 'reset' command +define reset + +info reg + +break main + +# End of 'reset' command +end + +target remote | openocd -c "interface cmsis-dap" -c "set CHIPNAME at91samd21g18" -f target/at91samdXX.cfg -c "gdb_port pipe; log_output openocd.log" diff --git a/variants/mkrzero/linker_scripts/gcc/flash_with_bootloader.ld b/variants/mkrzero/linker_scripts/gcc/flash_with_bootloader.ld new file mode 100644 index 0000000..3579464 --- /dev/null +++ b/variants/mkrzero/linker_scripts/gcc/flash_with_bootloader.ld @@ -0,0 +1,216 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000+0x2000, LENGTH = 0x00040000-0x2000 /* First 8KB used by bootloader */ + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.sketch_boot)) + + . = ALIGN(0x2000); + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(16); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM); + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/mkrzero/linker_scripts/gcc/flash_without_bootloader.ld b/variants/mkrzero/linker_scripts/gcc/flash_without_bootloader.ld new file mode 100644 index 0000000..ebeeee3 --- /dev/null +++ b/variants/mkrzero/linker_scripts/gcc/flash_without_bootloader.ld @@ -0,0 +1,214 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 0x00040000 + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + * __ram_end__ + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(16); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM) ; + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/mkrzero/openocd_scripts/arduino_zero.cfg b/variants/mkrzero/openocd_scripts/arduino_zero.cfg new file mode 100644 index 0000000..36c65c3 --- /dev/null +++ b/variants/mkrzero/openocd_scripts/arduino_zero.cfg @@ -0,0 +1,30 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +source [find interface/cmsis-dap.cfg] + +# chip name +set CHIPNAME at91samd21g18 +set ENDIAN little + +# choose a port here +set telnet_port 0 + +source [find target/at91samdXX.cfg] diff --git a/variants/mkrzero/pins_arduino.h b/variants/mkrzero/pins_arduino.h new file mode 100644 index 0000000..db0e40c --- /dev/null +++ b/variants/mkrzero/pins_arduino.h @@ -0,0 +1,21 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +// API compatibility +#include "variant.h" + diff --git a/variants/mkrzero/variant.cpp b/variants/mkrzero/variant.cpp new file mode 100644 index 0000000..51b9f3d --- /dev/null +++ b/variants/mkrzero/variant.cpp @@ -0,0 +1,185 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +#include "variant.h" + +const PinDescription g_APinDescription[] = { + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 00 | D0 | PA22 | | *06 | | | X10 | | 3/00 | 5/00 |* TC4/0 | TCC0/4 | | GCLK_IO6 | + | 01 | D1 | PA23 | | *07 | | | X11 | | 3/01 | 5/01 |* TC4/1 | TCC0/5 | USB/SOF | GCLK_IO7 | + | 02 | D2 | PA10 | | 10 | *18 | | X02 | | 0/02 | 2/02 |*TCC1/0 | TCC0/2 | I2S/SCK0 | GCLK_IO4 | + | 03 | D3 | PA11 | | 11 | *19 | | X03 | | 0/03 | 2/03 |*TCC1/1 | TCC0/3 | I2S/FS0 | GCLK_IO5 | + | 04 | D4 | PB10 | | *10 | | | | | | 4/02 |* TC5/0 | TCC0/4 | I2S/MCK1 | GCLK_IO4 | + | 05 | D5 | PB11 | | *11 | | | | | | 4/03 |* TC5/1 | TCC0/5 | I2S/SCK1 | GCLK_IO5 | + | 06 | D6 | PA20 | | *04 | | | X08 | | 5/02 | 3/02 | |*TCC0/6 | I2S/SCK0 | GCLK_IO4 | + | 07 | D7 | PA21 | | *05 | | | X09 | | 5/03 | 3/03 | |*TCC0/7 | I2S/FS0 | GCLK_IO5 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 22, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM4_CH0, TC4_CH0, EXTERNAL_INT_6 }, + { PORTA, 23, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM4_CH1, TC4_CH1, EXTERNAL_INT_7 }, + { PORTA, 10, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel18, PWM1_CH0, TCC1_CH0, EXTERNAL_INT_NONE }, + { PORTA, 11, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel19, PWM1_CH1, TCC1_CH1, EXTERNAL_INT_NONE }, + { PORTB, 10, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM5_CH0, TC5_CH0, EXTERNAL_INT_10 }, + { PORTB, 11, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM5_CH1, TC5_CH1, EXTERNAL_INT_11 }, + { PORTA, 20, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH6, TCC0_CH6, EXTERNAL_INT_4 }, + { PORTA, 21, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH7, TCC0_CH7, EXTERNAL_INT_5 }, + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | SPI | | | | | | | | | | | | | | + | 08 | MOSI | PA16 | | *00 | | | X04 | | *1/00 | 3/00 |*TCC2/0 | TCC0/6 | | GCLK_IO2 | + | 09 | SCK | PA17 | | *01 | | | X05 | | *1/01 | 3/01 | TCC2/1 | TCC0/7 | | GCLK_IO3 | + | 10 | MISO | PA19 | | 03 | | | X07 | | *1/03 | 3/03 |* TC3/1 | TCC0/3 | I2S/SD0 | AC/CMP1 | + +------------+------------------+--------+-----------------+--------------------+-----+-----+---------+---------+--------+--------+----------+----------+ + | | Wire | | | | | | | | | | | | | | + | 11 | SDA | PA08 | | NMI | *16 | | X00 | | *0/00 | 2/00 | TCC0/0 | TCC1/2 | I2S/SD1 | | + | 12 | SCL | PA09 | | 09 | *17 | | X01 | | *0/01 | 2/01 | TCC0/1 | TCC1/3 | I2S/MCK0 | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | Serial1 | | | | | | | | | | | | | | + | 13 | RX | PB23 | | 07 | | | | | | *5/03 | | | | GCLK_IO1 | + | 14 | TX | PB22 | | 06 | | | | | | *5/02 | | | | GCLK_IO0 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + // DIPO=3 DOPO=0 + { PORTA, 16, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM2_CH0, TCC2_CH0, EXTERNAL_INT_0 }, // MOSI: SERCOM1/PAD[0] + { PORTA, 17, PIO_SERCOM, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_1 }, // SCK: SERCOM1/PAD[1] + { PORTA, 19, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM3_CH1, TC3_CH1, EXTERNAL_INT_NONE }, // MISO: SERCOM1/PAD[3] + + // PINOUT=0 + { PORTA, 8, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), ADC_Channel16, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NMI }, // SDA: SERCOM2/PAD[0] + { PORTA, 9, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), ADC_Channel17, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCL: SERCOM2/PAD[1] + + // RXPO=3 TXPO=1 + { PORTB, 23, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // RX: SERCOM5/PAD[3] + { PORTB, 22, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // TX: SERCOM5/PAD[2] + + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 15 | A0 / DAC0 | PA02 | | 02 | *00 | | Y00 | OUT | | | | | | | + | 16 | A1 | PB02 | | *02 | *10 | | Y08 | | | 5/00 | | | | | + | 17 | A2 | PB03 | | *03 | *11 | | Y09 | | | 5/01 | | | | | + | 18 | A3 | PA04 | | 04 | *04 | 00 | Y02 | | | 0/00 |*TCC0/0 | | | | + | 19 | A4 | PA05 | | 05 | *05 | 01 | Y03 | | | 0/01 |*TCC0/1 | | | | + | 20 | A5 | PA06 | | 06 | *06 | 02 | Y04 | | | 0/02 | TCC1/0 | | | | + | 21 | A6 | PA07 | | 07 | *07 | 03 | Y05 | | | 0/03 | TCC1/1 | | I2S/SD0 | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG /*DAC*/ ), ADC_Channel0, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel10, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_2 }, + { PORTB, 3, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel11, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_3 }, + { PORTA, 4, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel4, PWM0_CH0, TCC0_CH0, EXTERNAL_INT_NONE }, + { PORTA, 5, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel5, PWM0_CH1, TCC0_CH1, EXTERNAL_INT_NONE }, + { PORTA, 6, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel6, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTA, 7, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel7, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | USB | | | | | | | | | | | | | | + | 22 | | PA24 | USB N | 12 | | | | | 3/02 | 5/02 | TC5/0 | TCC1/2 | USB/DM | | + | 23 | | PA25 | USB P | 13 | | | | | 3/03 | 5/03 | TC5/1 | TCC1/3 | USB/DP | | + | 24 | | PA18 | USB ID | 02 | | | X06 | | 1/02 | 3/02 | TC3/0 | TCC0/2 | | AC/CMP0 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 25 | AREF | PA03 | | 03 | 01 | | Y01 | | | | | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + { PORTA, 24, PIO_COM, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DM + { PORTA, 25, PIO_COM, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DP + { PORTA, 18, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + + { PORTA, 3, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // DAC/VREFP + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | MKR Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | SD SPI | | | | | | | | | | | | | | + | 26 | | PA12 | SD MOSI | 12 | | | | | *2/00 | 4/00 | TCC2/0 | TCC0/6 | | AC/CMP0 | + | 27 | | PA13 | SD SCK | 13 | | | | | *2/01 | 4/01 | TCC2/1 | TCC0/7 | | AC/CMP1 | + | 28 | | PA14 | SD SS | 14 | | | | | 2/02 | 4/02 | TC3/0 | TCC0/4 | | GCLK_IO0 | + | 29 | | PA15 | SD MISO | 15 | | | | | *2/03 | 4/03 | TC3/1 | TCC0/5 | | GCLK_IO1 | + | 30 | | PA27 | SD CD | 15 | | | | | | | | | | GCLK_IO0 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 31 | | PA28 | BOTTOM PAD | 08 | | | | | | | | | | GCLK_IO0 | + | 32 | | PB08 | LED_BUILTIN | 08 | 02 | | Y14 | | | 4/00 | TC4/0 | | | | + | 33 | | PB09 | ADC_BATTERY | *09 | 03 | | Y15 | | | 4/01 | TC4/1 | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | 32768Hz Crystal | | | | | | | | | | | | | | + | 34 | | PA00 | XIN32 | 00 | | | | | | 1/00 | TCC2/0 | | | | + | 35 | | PA01 | XOUT32 | 01 | | | | | | 1/01 | TCC2/1 | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ + // DIPO=3 DOPO=0 + { PORTA, 12, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MOSI: SERCOM4/PAD[0] + { PORTA, 13, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCK: SERCOM4/PAD[1] + { PORTA, 14, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SS: as GPIO + { PORTA, 15, PIO_SERCOM_ALT, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MISO: SERCOM4/PAD[3] + { PORTA, 27, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + + { PORTA, 28, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 8, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 9, PIO_ANALOG, (PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel3, PWM4_CH1, TC4_CH1, EXTERNAL_INT_9 }, + + { PORTA, 0, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTA, 1, PIO_DIGITAL, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, +}; + +extern "C" { + unsigned int PINCOUNT_fn() { + return (sizeof(g_APinDescription) / sizeof(g_APinDescription[0])); + } +} + +const void* g_apTCInstances[TCC_INST_NUM + TC_INST_NUM]={ TCC0, TCC1, TCC2, TC3, TC4, TC5 }; + +// Multi-serial objects instantiation +SERCOM sercom0(SERCOM0); +SERCOM sercom1(SERCOM1); +SERCOM sercom2(SERCOM2); +SERCOM sercom3(SERCOM3); +SERCOM sercom4(SERCOM4); +SERCOM sercom5(SERCOM5); + +// Serial1 +Uart Serial1(&sercom5, PIN_SERIAL1_RX, PIN_SERIAL1_TX, PAD_SERIAL1_RX, PAD_SERIAL1_TX); + +void SERCOM5_Handler() +{ + Serial1.IrqHandler(); +} + diff --git a/variants/mkrzero/variant.h b/variants/mkrzero/variant.h new file mode 100644 index 0000000..f622508 --- /dev/null +++ b/variants/mkrzero/variant.h @@ -0,0 +1,210 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +#pragma once + +// The definitions here needs a SAMD core >=1.6.10 +#define ARDUINO_SAMD_VARIANT_COMPLIANCE 10610 + +#include + +// General definitions +// ------------------- + +// Frequency of the board main oscillator +#define VARIANT_MAINOSC (32768ul) + +// Master clock frequency +#define VARIANT_MCK (48000000ul) + +// Pins +// ---- + +// Number of pins defined in PinDescription array +#ifdef __cplusplus +extern "C" unsigned int PINCOUNT_fn(); +#endif +#define PINS_COUNT (PINCOUNT_fn()) +#define NUM_DIGITAL_PINS (15u) +#define NUM_ANALOG_INPUTS (7u) +#define NUM_ANALOG_OUTPUTS (1u) + +// Low-level pin register query macros +// ----------------------------------- +#define digitalPinToPort(P) (&(PORT->Group[g_APinDescription[P].ulPort])) +#define digitalPinToBitMask(P) (1 << g_APinDescription[P].ulPin) +//#define analogInPinToBit(P) () +#define portOutputRegister(port) (&(port->OUT.reg)) +#define portInputRegister(port) (&(port->IN.reg)) +#define portModeRegister(port) (&(port->DIR.reg)) +#define digitalPinHasPWM(P) (g_APinDescription[P].ulPWMChannel != NOT_ON_PWM || g_APinDescription[P].ulTCChannel != NOT_ON_TIMER) + +/* + * digitalPinToTimer(..) is AVR-specific and is not defined for SAMD + * architecture. If you need to check if a pin supports PWM you must + * use digitalPinHasPWM(..). + * + * https://github.com/arduino/Arduino/issues/1833 + */ +// #define digitalPinToTimer(P) + +//Battery +#define ADC_BATTERY (33u) + +// LEDs +// ---- +#define PIN_LED (32u) +#define LED_BUILTIN PIN_LED + +// Analog pins +// ----------- +#define PIN_A0 (15u) +#define PIN_A1 (16u) +#define PIN_A2 (17u) +#define PIN_A3 (18u) +#define PIN_A4 (19u) +#define PIN_A5 (20u) +#define PIN_A6 (21u) +static const uint8_t A0 = PIN_A0; +static const uint8_t A1 = PIN_A1; +static const uint8_t A2 = PIN_A2; +static const uint8_t A3 = PIN_A3; +static const uint8_t A4 = PIN_A4; +static const uint8_t A5 = PIN_A5; +static const uint8_t A6 = PIN_A6; +#define ADC_RESOLUTION 12 + +// SPI Interfaces +// -------------- +#define SPI_INTERFACES_COUNT 2 + +// SPI +#define PIN_SPI_MISO (10u) +#define PIN_SPI_MOSI (8u) +#define PIN_SPI_SCK (9u) +#define PIN_SPI_SS (4u) +#define PERIPH_SPI sercom1 +#define PAD_SPI_TX SPI_PAD_0_SCK_1 +#define PAD_SPI_RX SERCOM_RX_PAD_3 + +static const uint8_t SS = PIN_SPI_SS; // SPI Slave SS not used. Set here only for reference. +static const uint8_t MOSI = PIN_SPI_MOSI; +static const uint8_t MISO = PIN_SPI_MISO; +static const uint8_t SCK = PIN_SPI_SCK; + +// SPI1: Connected to SD +#define PIN_SPI1_MISO (29u) +#define PIN_SPI1_MOSI (26u) +#define PIN_SPI1_SCK (27u) +#define PIN_SPI1_SS (28u) +#define PERIPH_SPI1 sercom4 +#define PAD_SPI1_TX SPI_PAD_0_SCK_1 +#define PAD_SPI1_RX SERCOM_RX_PAD_3 +static const uint8_t SS1 = PIN_SPI1_SS; +static const uint8_t MOSI1 = PIN_SPI1_MOSI; +static const uint8_t MISO1 = PIN_SPI1_MISO; +static const uint8_t SCK1 = PIN_SPI1_SCK; + +// Needed for SD library +#define SDCARD_SPI SPI1 +#define SDCARD_MISO_PIN PIN_SPI1_MISO +#define SDCARD_MOSI_PIN PIN_SPI1_MOSI +#define SDCARD_SCK_PIN PIN_SPI1_SCK +#define SDCARD_SS_PIN PIN_SPI1_SS + +// Wire Interfaces +// --------------- +#define WIRE_INTERFACES_COUNT 1 + +// Wire +#define PIN_WIRE_SDA (11u) +#define PIN_WIRE_SCL (12u) +#define PERIPH_WIRE sercom2 +#define WIRE_IT_HANDLER SERCOM2_Handler +static const uint8_t SDA = PIN_WIRE_SDA; +static const uint8_t SCL = PIN_WIRE_SCL; + +// USB +// --- +#define PIN_USB_DM (22ul) +#define PIN_USB_DP (23ul) +#define PIN_USB_HOST_ENABLE (24ul) + +// I2S Interfaces +// -------------- +#define I2S_INTERFACES_COUNT 1 + +#define I2S_DEVICE 0 +#define I2S_CLOCK_GENERATOR 3 +#define PIN_I2S_SD (PIN_A6) +#define PIN_I2S_SCK (2u) +#define PIN_I2S_FS (3u) + +// Serial ports +// ------------ +#ifdef __cplusplus +#include "SERCOM.h" +#include "Uart.h" + +// Instances of SERCOM +extern SERCOM sercom0; +extern SERCOM sercom1; +extern SERCOM sercom2; +extern SERCOM sercom3; +extern SERCOM sercom4; +extern SERCOM sercom5; + +// Serial1 +extern Uart Serial1; +#define PIN_SERIAL1_RX (13ul) +#define PIN_SERIAL1_TX (14ul) +#define PAD_SERIAL1_TX (UART_TX_PAD_2) +#define PAD_SERIAL1_RX (SERCOM_RX_PAD_3) +#endif // __cplusplus + +#ifdef __cplusplus +extern "C" { +#endif +unsigned int PINCOUNT_fn(); +#ifdef __cplusplus +} +#endif + +// These serial port names are intended to allow libraries and architecture-neutral +// sketches to automatically default to the correct port name for a particular type +// of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, +// the first hardware serial port whose RX/TX pins are not dedicated to another use. +// +// SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor +// +// SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial +// +// SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library +// +// SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. +// +// SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX +// pins are NOT connected to anything by default. +#define SERIAL_PORT_USBVIRTUAL SerialUSB +#define SERIAL_PORT_MONITOR SerialUSB +#define SERIAL_PORT_HARDWARE Serial1 +#define SERIAL_PORT_HARDWARE_OPEN Serial1 + +// Alias Serial to SerialUSB +#define Serial SerialUSB + diff --git a/variants/nano_33_iot/debug_scripts/variant.gdb b/variants/nano_33_iot/debug_scripts/variant.gdb new file mode 100644 index 0000000..3c37ffd --- /dev/null +++ b/variants/nano_33_iot/debug_scripts/variant.gdb @@ -0,0 +1,31 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +# Define 'reset' command +define reset + +info reg + +break main + +# End of 'reset' command +end + +target remote | openocd -c "interface cmsis-dap" -c "set CHIPNAME at91samd21g18" -f target/at91samdXX.cfg -c "gdb_port pipe; log_output openocd.log" diff --git a/variants/nano_33_iot/linker_scripts/gcc/flash_with_bootloader.ld b/variants/nano_33_iot/linker_scripts/gcc/flash_with_bootloader.ld new file mode 100644 index 0000000..d442744 --- /dev/null +++ b/variants/nano_33_iot/linker_scripts/gcc/flash_with_bootloader.ld @@ -0,0 +1,216 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000+0x2000, LENGTH = 0x00040000-0x2000 /* First 8KB used by bootloader */ + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.sketch_boot)) + . = ALIGN(0x2000); + + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(4); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM); + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/nano_33_iot/linker_scripts/gcc/flash_without_bootloader.ld b/variants/nano_33_iot/linker_scripts/gcc/flash_without_bootloader.ld new file mode 100644 index 0000000..749aa5f --- /dev/null +++ b/variants/nano_33_iot/linker_scripts/gcc/flash_without_bootloader.ld @@ -0,0 +1,214 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +/* Linker script to configure memory regions. + * Need modifying for a specific board. + * FLASH.ORIGIN: starting address of flash + * FLASH.LENGTH: length of flash + * RAM.ORIGIN: starting address of RAM bank 0 + * RAM.LENGTH: length of RAM bank 0 + */ +MEMORY +{ + FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 0x00040000 + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x00008000 +} + +/* Linker script to place sections and symbol values. Should be used together + * with other linker script that defines memory regions FLASH and RAM. + * It references following symbols, which must be defined in code: + * Reset_Handler : Entry of reset handler + * + * It defines following symbols, which code can use without definition: + * __exidx_start + * __exidx_end + * __copy_table_start__ + * __copy_table_end__ + * __zero_table_start__ + * __zero_table_end__ + * __etext + * __data_start__ + * __preinit_array_start + * __preinit_array_end + * __init_array_start + * __init_array_end + * __fini_array_start + * __fini_array_end + * __data_end__ + * __bss_start__ + * __bss_end__ + * __end__ + * end + * __HeapLimit + * __StackLimit + * __StackTop + * __stack + * __ram_end__ + */ +ENTRY(Reset_Handler) + +SECTIONS +{ + .text : + { + __text_start__ = .; + + KEEP(*(.isr_vector)) + *(.text*) + + KEEP(*(.init)) + KEEP(*(.fini)) + + /* .ctors */ + *crtbegin.o(.ctors) + *crtbegin?.o(.ctors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors) + *(SORT(.ctors.*)) + *(.ctors) + + /* .dtors */ + *crtbegin.o(.dtors) + *crtbegin?.o(.dtors) + *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors) + *(SORT(.dtors.*)) + *(.dtors) + + *(.rodata*) + + KEEP(*(.eh_frame*)) + } > FLASH + + .ARM.extab : + { + *(.ARM.extab* .gnu.linkonce.armextab.*) + } > FLASH + + __exidx_start = .; + .ARM.exidx : + { + *(.ARM.exidx* .gnu.linkonce.armexidx.*) + } > FLASH + __exidx_end = .; + + /* To copy multiple ROM to RAM sections, + * uncomment .copy.table section and, + * define __STARTUP_COPY_MULTIPLE in startup_ARMCMx.S */ + /* + .copy.table : + { + . = ALIGN(4); + __copy_table_start__ = .; + LONG (__etext) + LONG (__data_start__) + LONG (__data_end__ - __data_start__) + LONG (__etext2) + LONG (__data2_start__) + LONG (__data2_end__ - __data2_start__) + __copy_table_end__ = .; + } > FLASH + */ + + /* To clear multiple BSS sections, + * uncomment .zero.table section and, + * define __STARTUP_CLEAR_BSS_MULTIPLE in startup_ARMCMx.S */ + /* + .zero.table : + { + . = ALIGN(4); + __zero_table_start__ = .; + LONG (__bss_start__) + LONG (__bss_end__ - __bss_start__) + LONG (__bss2_start__) + LONG (__bss2_end__ - __bss2_start__) + __zero_table_end__ = .; + } > FLASH + */ + + __etext = .; + + .data : AT (__etext) + { + __data_start__ = .; + *(vtable) + *(.data*) + + . = ALIGN(4); + /* preinit data */ + PROVIDE_HIDDEN (__preinit_array_start = .); + KEEP(*(.preinit_array)) + PROVIDE_HIDDEN (__preinit_array_end = .); + + . = ALIGN(4); + /* init data */ + PROVIDE_HIDDEN (__init_array_start = .); + KEEP(*(SORT(.init_array.*))) + KEEP(*(.init_array)) + PROVIDE_HIDDEN (__init_array_end = .); + + + . = ALIGN(4); + /* finit data */ + PROVIDE_HIDDEN (__fini_array_start = .); + KEEP(*(SORT(.fini_array.*))) + KEEP(*(.fini_array)) + PROVIDE_HIDDEN (__fini_array_end = .); + + KEEP(*(.jcr*)) + . = ALIGN(4); + /* All data end */ + __data_end__ = .; + + } > RAM + + .bss : + { + . = ALIGN(4); + __bss_start__ = .; + *(.bss*) + *(COMMON) + . = ALIGN(4); + __bss_end__ = .; + } > RAM + + .heap (COPY): + { + __end__ = .; + PROVIDE(end = .); + *(.heap*) + __HeapLimit = .; + } > RAM + + /* .stack_dummy section doesn't contains any symbols. It is only + * used for linker to calculate size of stack sections, and assign + * values to stack symbols later */ + .stack_dummy (COPY): + { + *(.stack*) + } > RAM + + /* Set stack top to end of RAM, and stack limit move down by + * size of stack_dummy section */ + __StackTop = ORIGIN(RAM) + LENGTH(RAM) ; + __StackLimit = __StackTop - SIZEOF(.stack_dummy); + PROVIDE(__stack = __StackTop); + + __ram_end__ = ORIGIN(RAM) + LENGTH(RAM) -1 ; + + /* Check if data + heap + stack exceeds RAM limit */ + ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack") +} diff --git a/variants/nano_33_iot/openocd_scripts/arduino_zero.cfg b/variants/nano_33_iot/openocd_scripts/arduino_zero.cfg new file mode 100644 index 0000000..36c65c3 --- /dev/null +++ b/variants/nano_33_iot/openocd_scripts/arduino_zero.cfg @@ -0,0 +1,30 @@ +# +# Arduino Zero OpenOCD script. +# +# Copyright (c) 2014-2015 Arduino LLC. 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 +# + +source [find interface/cmsis-dap.cfg] + +# chip name +set CHIPNAME at91samd21g18 +set ENDIAN little + +# choose a port here +set telnet_port 0 + +source [find target/at91samdXX.cfg] diff --git a/variants/nano_33_iot/pins_arduino.h b/variants/nano_33_iot/pins_arduino.h new file mode 100644 index 0000000..db0e40c --- /dev/null +++ b/variants/nano_33_iot/pins_arduino.h @@ -0,0 +1,21 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +// API compatibility +#include "variant.h" + diff --git a/variants/nano_33_iot/variant.cpp b/variants/nano_33_iot/variant.cpp new file mode 100644 index 0000000..2dc4676 --- /dev/null +++ b/variants/nano_33_iot/variant.cpp @@ -0,0 +1,207 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + + +#include "variant.h" +#include "Arduino.h" + +/* + * Pins descriptions + */ +const PinDescription g_APinDescription[] = { +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | NANO Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | Digital Low | | | | | | | | | | | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 0 | 0 -> RX | PB23 | | 07 | | | | | | *5/03 | TC7/1 | | | GCLK_IO1 | + | 1 | 1 <- TX | PB22 | | 06 | | | | | | *5/02 | TC7/0 | | | GCLK_IO0 | + | 2 | ~D2 | PB10 | | *10 | | | | | | 4/02 |* TC5/0 | TCC0/4 | I2S/MCK1 | GCLK_IO4 | + | 3 | ~D3 | PB11 | | *11 | | | | | | 4/03 |* TC5/1 | TCC0/5 | I2S/SCK1 | GCLK_IO5 | + | 4 | D4 | PA07 | | 07 | *07 | 03 | Y05 | | | 0/03 |*TCC1/1 | | I2S/SD0 | | + | 5 | ~D5 | PA05 | | 05 | *05 | 01 | Y03 | | | 0/01 |*TCC0/1 | | | | + | 6 | ~D6 | PA04 | | 04 | *04 | 00 | Y02 | | | 0/00 |*TCC0/0 | | | | + | 7 | D7 | PA06 | | 06 | *06 | 02 | Y04 | | | 0/02 | TCC1/0 | | | | + +------------+------------------+--------+-----------------+------------------------------------------+---------+--------+------------------------------+ + | | Digital High | | | | | | | | | | | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 8 | D8 | PA18 | | 02 | | | X06 | | 1/02 | 3/02 | TC3/0 | TCC0/2 | | AC/CMP0 | + | 9 | ~D9 | PA20 | | *04 | | | X08 | | 5/02 | 3/02 | TC7/0 |*TCC0/6 | | GCLK_IO4 | + | 10 | ~D10 | PA21 | | *05 | | | X09 | | 5/03 | 3/02 | TC7/1 |*TCC0/7 | I2S/FS0 | GCLK_IO5 | + | 11 | ~D11 | PA16 | | *00 | | | X04 | | *1/00 | 3/00 |*TCC2/0 | TCC0/6 | | GCLK_IO2 | + | 12 | ~D12 | PA19 | | 03 | | | X07 | | *1/03 | 3/03 |* TC3/1 | TCC0/3 | I2S/SD0 | AC/CMP0 | + | 13 | D13 | PA17 | LED | 01 | | | X05 | | *1/01 | 3/01 | TCC2/1 | TCC0/7 | | GCLK_IO3 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ +*/ + // 0/1 - SERCOM/UART + { PORTB, 23, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // RX: SERCOM5/PAD[3] + { PORTB, 22, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // TX: SERCOM5/PAD[2] + // 2..7 + // Digital Low + { PORTB, 10, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM5_CH0, TC5_CH0, EXTERNAL_INT_10 }, + { PORTB, 11, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM5_CH1, TC5_CH1, EXTERNAL_INT_11 }, + { PORTA, 7, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel7, PWM1_CH1, TCC1_CH1, EXTERNAL_INT_NONE }, + { PORTA, 5, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel5, PWM0_CH1, TCC0_CH1, EXTERNAL_INT_NONE }, + { PORTA, 4, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel4, PWM0_CH0, TCC0_CH0, EXTERNAL_INT_NONE }, + { PORTA, 6, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), ADC_Channel6, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + // 8..12 + // Digital High + { PORTA, 18, PIO_DIGITAL, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTA, 20, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH6, TCC0_CH6, EXTERNAL_INT_4 }, + { PORTA, 21, PIO_DIGITAL, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), No_ADC_Channel, PWM0_CH7, TCC0_CH7, EXTERNAL_INT_5 }, + { PORTA, 16, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM2_CH0, TCC2_CH0, EXTERNAL_INT_0 }, // MOSI: SERCOM1/PAD[0] + { PORTA, 19, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM3_CH1, TC3_CH1, EXTERNAL_INT_NONE }, // MISO: SERCOM1/PAD[3] + // 13 (LED) + { PORTA, 17, PIO_SERCOM, (PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_1 }, // SCK: SERCOM1/PAD[1] +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | NANO Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | Analog Connector | | | | | | | | | | | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 14 | A0 | PA02 | A0 | 02 | *00 | | Y00 | OUT | | | | | | | + | 15 | A1 | PB02 | A1 | *02 | *10 | | Y08 | | | 5/00 | TC6/0 | | | | + | 16 | A2 | PA11 | A2 | 11 | *19 | | X03 | | 0/03 | 2/03 | TCC1/1 |*TCC0/3 | I2S/FS0 | GCLK_IO5 | + | 17 | A3 | PA10 | A3 | 10 | *18 | | X02 | | 0/02 | 2/02 | TCC1/0 |*TCC0/2 | I2S/SCK0 | GCLK_IO4 | + | 18 | A4 | PB08 | A4 SDA | 08 | *02 | | Y14 | | | *4/00 | TC4/0 | | | | + | 19 | A5 | PB09 | A5 SCL | *09 | *03 | | Y15 | | | *4/01 |* TC4/1 | | | | + | 20 | A6 | PA09 | A6 | 09 | *17 | | X01 | | 0/01 | 2/01 | TCC0/1 | TCC1/3 | I2S/MCK0 | | + | 21 | A7 | PB03 | A7 | *03 | *11 | | Y09 | | | 5/01 | TC6/1 | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ +*/ + // 14..21 - Analog pins + { PORTA, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG /*DAC*/ ), ADC_Channel0, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 2, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel10, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_2 }, + { PORTA, 11, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), ADC_Channel19, PWM0_CH3, TCC0_CH3, EXTERNAL_INT_NONE }, + { PORTA, 10, PIO_ANALOG, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER_ALT), ADC_Channel18, PWM0_CH2, TCC0_CH2, EXTERNAL_INT_NONE }, + { PORTB, 8, PIO_SERCOM_ALT, (PIN_ATTR_DIGITAL|PIN_ATTR_ANALOG ), ADC_Channel2, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SDA: SERCOM4/PAD[0] + { PORTB, 9, PIO_SERCOM_ALT, (PIN_ATTR_PWM|PIN_ATTR_TIMER ), ADC_Channel3, PWM4_CH1, TC4_CH1, EXTERNAL_INT_9 }, // SCL: SERCOM4/PAD[1] + + + { PORTA, 9, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel17, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTB, 3, PIO_ANALOG, (PIN_ATTR_DIGITAL ), ADC_Channel11, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_3 }, +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | NANO Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | |SPI (Legacy ICSP) | | | | | | | | | | | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 22 | 1 | PA12 | NINA_MOSI | 12 | | | | | *2/00 | 4/00 | TCC2/0 | TCC0/6 | | AC/CMP0 | + | 23 | 2 | PA13 | NINA_MISO | 13 | | | | | *2/01 | 4/01 | TCC2/1 | TCC0/7 | | AC/CMP1 | + | 24 | 4 | PA14 | NINA_CS | 14 | | | | | 2/02 | 4/02 | TC3/0 | TCC0/4 | | GCLK_IO0 | + | 25 | 3 | PA15 | NINA_SCK | 15 | | | | | *2/03 | 4/03 | TC3/1 | TCC0/5 | | GCLK_IO1 | + | 26 | | PA27 | NINA_GPIO0 | *15 | | | | | | | | | | GCLK_IO0 | + | 27 | | PA08 | NINA_RESETN | NMI | 16 | | X00 | | 0/00 | 2/00 | TCC0/0 | TCC1/2 | I2S/SD1 | | + | 28 | | PA28 | NINA_ACK | 08 | | | | | | | | | | GCLK_IO0 | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ +*/ + { PORTA, 12, PIO_SERCOM, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MOSI: SERCOM2/PAD[0] + { PORTA, 13, PIO_SERCOM, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // MISO: SERCOM2/PAD[1] + { PORTA, 14, PIO_DIGITAL,(PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SS: as GPIO + { PORTA, 15, PIO_SERCOM, (PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // SCK: SERCOM2/PAD[3] + { PORTA, 27, PIO_DIGITAL,(PIN_ATTR_NONE ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_15 }, + { PORTA, 8, PIO_DIGITAL,(PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + { PORTA, 28, PIO_DIGITAL,(PIN_ATTR_DIGITAL ), No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, + +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | NANO Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | | USB | | | | | | | | | | | | | | + | 29 | | PA22 | | *06 | | | X10 | | 3/00 | 5/00 |* TC4/0 | TCC0/4 | | GCLK_IO6 | + | 30 | | PA23 | | *07 | | | X11 | | 3/01 | 5/01 |* TC4/1 | TCC0/5 | USB/SOF | GCLK_IO7 | + | 31 | | PA24 | USB_N | 12 | | | | | 3/02 | 5/02 | TC5/0 | TCC1/2 | USB/DM | | + | 32 | | PA25 | USB_P | 13 | | | | | 3/03 | 5/03 | TC5/1 | TCC1/3 | USB/DP | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ +*/ + /* SerialNINA 29..30 */ + { PORTA, 22, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM4_CH0, TC4_CH0, EXTERNAL_INT_6 }, + { PORTA, 23, PIO_SERCOM, (PIN_ATTR_DIGITAL|PIN_ATTR_PWM|PIN_ATTR_TIMER ), No_ADC_Channel, PWM4_CH1, TC4_CH1, EXTERNAL_INT_7 }, + + // 31..32 - USB + { PORTA, 24, PIO_COM, PIN_ATTR_NONE , No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DM + { PORTA, 25, PIO_COM, PIN_ATTR_NONE , No_ADC_Channel, NOT_ON_PWM, NOT_ON_TIMER, EXTERNAL_INT_NONE }, // USB/DP +/* + +------------+------------------+--------+-----------------+--------+-----------------------+---------+---------+--------+--------+----------+----------+ + | Pin number | NANO Board pin | PIN | Notes | Peri.A | Peripheral B | Perip.C | Perip.D | Peri.E | Peri.F | Periph.G | Periph.H | + | | | | | EIC | ADC | AC | PTC | DAC | SERCOMx | SERCOMx | TCCx | TCCx | COM | AC/GLCK | + | | | | |(EXTINT)|(AIN)|(AIN)| | | (x/PAD) | (x/PAD) | (x/WO) | (x/WO) | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 33 | AREF | PA03 | | 03 | 01 | | Y01 | | | | | | | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + | 34 | | PA30 | | 10 | | | | | | 1/00 | | | SWCLK | | + | 35 | | PA31 | | 11 | | | | | | 1/03 | | | SWDIO | | + +------------+------------------+--------+-----------------+--------+-----+-----+-----+-----+---------+---------+--------+--------+----------+----------+ + */ +} ; + +extern "C" { + unsigned int PINCOUNT_fn() { + return (sizeof(g_APinDescription) / sizeof(g_APinDescription[0])); + } +} + +const void* g_apTCInstances[TCC_INST_NUM+TC_INST_NUM]={ TCC0, TCC1, TCC2, TC3, TC4, TC5 } ; + +void initVariant() { + // NINA - SPI boot + pinMode(NINA_GPIO0, OUTPUT); + digitalWrite(NINA_GPIO0, HIGH); + + // disable NINA + pinMode(NINA_RESETN, OUTPUT); + digitalWrite(NINA_RESETN, LOW); +} + +// Multi-serial objects instantiation +SERCOM sercom0( SERCOM0 ) ; +SERCOM sercom1( SERCOM1 ) ; +SERCOM sercom2( SERCOM2 ) ; +SERCOM sercom3( SERCOM3 ) ; +SERCOM sercom4( SERCOM4 ) ; +SERCOM sercom5( SERCOM5 ) ; + +Uart Serial1( &sercom5, PIN_SERIAL1_RX, PIN_SERIAL1_TX, PAD_SERIAL1_RX, PAD_SERIAL1_TX ) ; + +void SERCOM5_Handler() +{ + Serial1.IrqHandler(); +} + +Uart Serial2(&sercom3, PIN_SERIAL2_RX, PIN_SERIAL2_TX, PAD_SERIAL2_RX, PAD_SERIAL2_TX); + +void SERCOM3_Handler() +{ + Serial2.IrqHandler(); +} + +Uart SerialHCI(&sercom2, PIN_SERIALHCI_RX, PIN_SERIALHCI_TX, PAD_SERIALHCI_RX, PAD_SERIALHCI_TX, PIN_SERIALHCI_RTS, PIN_SERIALHCI_CTS); + +void SERCOM2_Handler() +{ + SerialHCI.IrqHandler(); +} diff --git a/variants/nano_33_iot/variant.h b/variants/nano_33_iot/variant.h new file mode 100644 index 0000000..3c2b89f --- /dev/null +++ b/variants/nano_33_iot/variant.h @@ -0,0 +1,240 @@ +/* + Copyright (c) 2014-2015 Arduino LLC. 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 +*/ + +#pragma once + +// The definitions here needs a SAMD core >=1.6.10 +#define ARDUINO_SAMD_VARIANT_COMPLIANCE 10610 + + +#include + +// General definitions +// ------------------- + +// Frequency of the board main oscillator +#define VARIANT_MAINOSC (32768ul) + +// Master clock frequency +#define VARIANT_MCK (48000000ul) + +// Pins +// ---- + +// Number of pins defined in PinDescription array +#ifdef __cplusplus +extern "C" unsigned int PINCOUNT_fn(); +#endif +#define PINS_COUNT (PINCOUNT_fn()) +#define NUM_DIGITAL_PINS (31u) +#define NUM_ANALOG_INPUTS (8u) +#define NUM_ANALOG_OUTPUTS (1u) + +// Low-level pin register query macros +// ----------------------------------- +#define digitalPinToPort(P) (&(PORT->Group[g_APinDescription[P].ulPort])) +#define digitalPinToBitMask(P) (1 << g_APinDescription[P].ulPin) +//#define analogInPinToBit(P) () +#define portOutputRegister(port) (&(port->OUT.reg)) +#define portInputRegister(port) (&(port->IN.reg)) +#define portModeRegister(port) (&(port->DIR.reg)) +#define digitalPinHasPWM(P) (g_APinDescription[P].ulPWMChannel != NOT_ON_PWM || g_APinDescription[P].ulTCChannel != NOT_ON_TIMER) + +/* + * digitalPinToTimer(..) is AVR-specific and is not defined for SAMD + * architecture. If you need to check if a pin supports PWM you must + * use digitalPinHasPWM(..). + * + * https://github.com/arduino/Arduino/issues/1833 + */ +// #define digitalPinToTimer(P) + + +// LEDs +// ---- +#define PIN_LED_13 (13u) +#define PIN_LED PIN_LED_13 +#define LED_BUILTIN PIN_LED + +//NINA +#define NINA_GPIO0 (26u) +#define NINA_RESETN (27u) +#define NINA_ACK (28u) + +//#define PIN_LED_RXL (25u) +//#define PIN_LED_TXL (26u) +//#define PIN_LED2 PIN_LED_RXL +//#define PIN_LED3 PIN_LED_TXL + +/* + * Analog pins + */ +#define PIN_A0 (14ul) +#define PIN_A1 (PIN_A0 + 1) +#define PIN_A2 (PIN_A0 + 2) +#define PIN_A3 (PIN_A0 + 3) +#define PIN_A4 (PIN_A0 + 4) +#define PIN_A5 (PIN_A0 + 5) +#define PIN_A6 (PIN_A0 + 6) +#define PIN_A7 (PIN_A0 + 7) + +#define PIN_DAC0 (PIN_A0) + + +static const uint8_t A0 = PIN_A0; +static const uint8_t A1 = PIN_A1; +static const uint8_t A2 = PIN_A2; +static const uint8_t A3 = PIN_A3; +static const uint8_t A4 = PIN_A4; +static const uint8_t A5 = PIN_A5; +static const uint8_t A6 = PIN_A6; +static const uint8_t A7 = PIN_A7; +static const uint8_t DAC0 = PIN_DAC0; + +#define ADC_RESOLUTION 12 + +/* + * SPI Interfaces + */ +#define SPI_INTERFACES_COUNT 2 + +#define PIN_SPI_MISO (12u) +#define PIN_SPI_SCK (13u) +#define PIN_SPI_MOSI (11u) +#define PIN_SPI_SS (10u) +#define PERIPH_SPI sercom1 +#define PAD_SPI_TX SPI_PAD_0_SCK_1 +#define PAD_SPI_RX SERCOM_RX_PAD_3 + +static const uint8_t SS = PIN_SPI_SS; // SPI Slave SS not used. Set here only for reference. +static const uint8_t MOSI = PIN_SPI_MOSI; +static const uint8_t MISO = PIN_SPI_MISO; +static const uint8_t SCK = PIN_SPI_SCK; + +// SPI1 +#define PIN_SPI1_MISO (23u) +#define PIN_SPI1_MOSI (22u) +#define PIN_SPI1_SCK (25u) +#define PIN_SPI1_SS (24u) +#define PERIPH_SPI1 sercom2 +#define PAD_SPI1_TX SPI_PAD_0_SCK_3 +#define PAD_SPI1_RX SERCOM_RX_PAD_1 +static const uint8_t SS1 = PIN_SPI1_SS; +static const uint8_t MOSI1 = PIN_SPI1_MOSI; +static const uint8_t MISO1 = PIN_SPI1_MISO; +static const uint8_t SCK1 = PIN_SPI1_SCK; + +#define SPIWIFI_SS PIN_SPI1_SS +#define SPIWIFI_ACK NINA_ACK +#define SPIWIFI_RESET NINA_RESETN + +/* + * Wire Interfaces + */ +#define WIRE_INTERFACES_COUNT 1 + + // "external" public i2c interface +#define PIN_WIRE_SDA (18u) +#define PIN_WIRE_SCL (19u) +#define PERIPH_WIRE sercom4 +#define WIRE_IT_HANDLER SERCOM4_Handler +static const uint8_t SDA = PIN_WIRE_SDA; +static const uint8_t SCL = PIN_WIRE_SCL; + +// USB +// --- +#define PIN_USB_DM (31ul) +#define PIN_USB_DP (32ul) + +// I2S Interfaces +// -------------- +#define I2S_INTERFACES_COUNT 1 + +#define I2S_DEVICE 0 +#define I2S_CLOCK_GENERATOR 3 + +#define PIN_I2S_SD (4u) +#define PIN_I2S_SCK (PIN_A3) +#define PIN_I2S_FS (PIN_A2) + +// Serial ports +// ------------ +#ifdef __cplusplus +#include "SERCOM.h" +#include "Uart.h" + +// Instances of SERCOM +extern SERCOM sercom0; +extern SERCOM sercom1; // spi +extern SERCOM sercom2; // spi nina +extern SERCOM sercom3; // serial2 +extern SERCOM sercom4; // wire +extern SERCOM sercom5; // serial1 + +// Serial1 +extern Uart Serial1; +#define PIN_SERIAL1_RX (0ul) +#define PIN_SERIAL1_TX (1ul) +#define PAD_SERIAL1_TX (UART_TX_PAD_2) +#define PAD_SERIAL1_RX (SERCOM_RX_PAD_3) + +// Serial1 +extern Uart Serial2; +#define PIN_SERIAL2_RX (30ul) +#define PIN_SERIAL2_TX (29ul) +#define PAD_SERIAL2_TX (UART_TX_PAD_0) +#define PAD_SERIAL2_RX (SERCOM_RX_PAD_1) + +extern Uart SerialHCI; +#define PIN_SERIALHCI_RX (23ul) +#define PIN_SERIALHCI_TX (22ul) +#define PAD_SERIALHCI_TX (UART_TX_RTS_CTS_PAD_0_2_3) +#define PAD_SERIALHCI_RX (SERCOM_RX_PAD_1) +#define PIN_SERIALHCI_RTS (24u) +#define PIN_SERIALHCI_CTS (25u) + +#endif // __cplusplus + + + +// These serial port names are intended to allow libraries and architecture-neutral +// sketches to automatically default to the correct port name for a particular type +// of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, +// the first hardware serial port whose RX/TX pins are not dedicated to another use. +// +// SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor +// +// SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial +// +// SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library +// +// SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. +// +// SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX +// pins are NOT connected to anything by default. +#define SERIAL_PORT_USBVIRTUAL SerialUSB +#define SERIAL_PORT_MONITOR SerialUSB +#define SERIAL_PORT_HARDWARE Serial1 +#define SERIAL_PORT_HARDWARE_OPEN Serial1 + +// Alias Serial1 to SerialNina (useful in libraries) +#define SerialNina Serial2 +#define SPIWIFI SPI1 + +// Alias Serial to SerialUSB +#define Serial SerialUSB